Adopt shared WebUI layout primitives
This commit is contained in:
@@ -1,3 +1,4 @@
|
|||||||
|
import { DescriptionList } from "@govoplan/core-webui";
|
||||||
import { Download, FileJson, Play, ShieldCheck } from "lucide-react";
|
import { Download, FileJson, Play, ShieldCheck } from "lucide-react";
|
||||||
import { useEffect, useMemo, useState } from "react";
|
import { useEffect, useMemo, useState } from "react";
|
||||||
import { ContentGrid, ActionToolbar,
|
import { ContentGrid, ActionToolbar,
|
||||||
@@ -234,26 +235,26 @@ function ProviderResult({ execution }: { execution: ProviderReportExecution }) {
|
|||||||
</ContentGrid>
|
</ContentGrid>
|
||||||
}
|
}
|
||||||
{details.length > 0 &&
|
{details.length > 0 &&
|
||||||
<dl className="detail-list">
|
<DescriptionList variant="inline">
|
||||||
{details.map((field) =>
|
{details.map((field) =>
|
||||||
<div key={field.path}>
|
<div key={field.path}>
|
||||||
<dt>{field.label}</dt>
|
<dt>{field.label}</dt>
|
||||||
<dd>{displayValue(pathValue(execution.result, field.path), field)}</dd>
|
<dd>{displayValue(pathValue(execution.result, field.path), field)}</dd>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</dl>
|
</DescriptionList>
|
||||||
}
|
}
|
||||||
</Card>
|
</Card>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
<Card title="Provenance">
|
<Card title="Provenance">
|
||||||
<dl className="detail-list">
|
<DescriptionList variant="inline">
|
||||||
<div><dt>Purpose</dt><dd>{execution.purpose}</dd></div>
|
<div><dt>Purpose</dt><dd>{execution.purpose}</dd></div>
|
||||||
<div><dt>Output hash</dt><dd title={execution.output_hash}>{shortHash(execution.output_hash)}</dd></div>
|
<div><dt>Output hash</dt><dd title={execution.output_hash}>{shortHash(execution.output_hash)}</dd></div>
|
||||||
<div><dt>Source revisions</dt><dd>{execution.source_revisions.length}</dd></div>
|
<div><dt>Source revisions</dt><dd>{execution.source_revisions.length}</dd></div>
|
||||||
<div><dt>Privacy transforms</dt><dd>{execution.privacy_transforms.join(", ")}</dd></div>
|
<div><dt>Privacy transforms</dt><dd>{execution.privacy_transforms.join(", ")}</dd></div>
|
||||||
<div><dt>Expires</dt><dd>{execution.expires_at ? formatDateTime(execution.expires_at) : "Policy managed"}</dd></div>
|
<div><dt>Expires</dt><dd>{execution.expires_at ? formatDateTime(execution.expires_at) : "Policy managed"}</dd></div>
|
||||||
</dl>
|
</DescriptionList>
|
||||||
</Card>
|
</Card>
|
||||||
</>
|
</>
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user