fix: stack preparation overview fields on small screens
This commit is contained in:
@@ -26,17 +26,17 @@ function Overview({tenders,now}) {
|
||||
{vault.loading&&<p role="status" className="text-xs">Belge durumu kontrol ediliyor…</p>}
|
||||
{vault.error&&<p role="alert" className="text-xs text-red-700">Belge durumu doğrulanamadı: {vault.error}</p>}
|
||||
{!tenders.length ? <p className="text-sm">İhaleyi takibe alın veya hazırlık görevi açın; dosyası burada görünsün.</p> :
|
||||
<div className="overflow-x-auto"><table className="w-full text-sm min-w-[700px]">
|
||||
<thead><tr className="text-left border-b"><th className="p-2">İhale</th><th className="p-2">Sorumlu</th><th className="p-2">Belge eksikleri</th><th className="p-2">Sıradaki kontrol</th></tr></thead>
|
||||
<tbody>{tenders.map(tender=>{
|
||||
<div><table role="table" className="block md:table w-full text-sm table-fixed">
|
||||
<thead role="rowgroup" className="sr-only md:not-sr-only md:table-header-group"><tr role="row" className="text-left border-b"><th role="columnheader" scope="col" className="p-2">İhale</th><th role="columnheader" scope="col" className="p-2">Sorumlu</th><th role="columnheader" scope="col" className="p-2">Belge eksikleri</th><th role="columnheader" scope="col" className="p-2">Sıradaki kontrol</th></tr></thead>
|
||||
<tbody role="rowgroup" className="block md:table-row-group">{tenders.map(tender=>{
|
||||
const summary=preparationSummary(tender,{...vault,healthPortfolio:userProfile.scrapedCapabilities?.healthPortfolio || []},now);
|
||||
return <tr key={tender.id} className="border-b align-top">
|
||||
<td className="p-2"><button onClick={()=>open(tender,'source')} className="text-blue-800 underline text-left">{tender.ikn} · {tender.baslik}</button><p className="text-xs mt-1">{summary.issues.length ? `${summary.issues.length} kontrol eksik` : 'Kayıtlı kontroller tamam; son kontrol gerekli'}</p></td>
|
||||
<td className="p-2">{summary.owner}</td>
|
||||
<td className="p-2"><details><summary className="cursor-pointer">{summary.documentIssues.length ? `${summary.documentIssues.length} belge kontrolü` : 'Kayıtlı belgelerde eksik bulunmadı'}</summary>
|
||||
return <tr role="row" key={tender.id} className="block md:table-row border rounded-lg mb-3 md:mb-0 md:rounded-none md:border-0 md:border-b align-top [overflow-wrap:anywhere]">
|
||||
<td role="cell" className="block md:table-cell p-2"><span aria-hidden="true" className="block md:hidden text-xs font-bold mb-1">İhale</span><button onClick={()=>open(tender,'source')} className="text-blue-800 underline text-left">{tender.ikn} · {tender.baslik}</button><p className="text-xs mt-1">{summary.issues.length ? `${summary.issues.length} kontrol eksik` : 'Kayıtlı kontroller tamam; son kontrol gerekli'}</p></td>
|
||||
<td role="cell" className="block md:table-cell p-2"><span aria-hidden="true" className="block md:hidden text-xs font-bold mb-1">Sorumlu</span>{summary.owner}</td>
|
||||
<td role="cell" className="block md:table-cell p-2"><span aria-hidden="true" className="block md:hidden text-xs font-bold mb-1">Belge eksikleri</span><details><summary className="cursor-pointer">{summary.documentIssues.length ? `${summary.documentIssues.length} belge kontrolü` : 'Kayıtlı belgelerde eksik bulunmadı'}</summary>
|
||||
<ul className="space-y-2 mt-2">{summary.documentIssues.map((text,i)=><li key={i}><button onClick={()=>open(tender,'checks')} className="text-blue-800 underline text-left">{text}</button></li>)}</ul>
|
||||
</details></td>
|
||||
<td className="p-2"><button onClick={()=>open(tender,summary.next.target)} className="text-blue-800 underline text-left">{summary.next.text}</button>
|
||||
<td role="cell" className="block md:table-cell p-2"><span aria-hidden="true" className="block md:hidden text-xs font-bold mb-1">Sıradaki kontrol</span><button onClick={()=>open(tender,summary.next.target)} className="text-blue-800 underline text-left">{summary.next.text}</button>
|
||||
<details className="mt-2"><summary className="cursor-pointer text-xs">Tüm eksikleri göster</summary><ul className="space-y-2 mt-2">{summary.issues.map((item,i)=><li key={i}><button onClick={()=>open(tender,item.target)} className="text-blue-800 underline text-left">{item.text}</button></li>)}</ul></details>
|
||||
</td>
|
||||
</tr>;
|
||||
|
||||
Reference in New Issue
Block a user