papertrail/components/import/ImportStatusBadge.tsx
caelum0x 695a365ae4 feat: PaperTrail — enterprise evidence-verification platform
Multi-tenant platform (182 pages, 228 API routes, ~30 modules) built on a
deterministic verification core: clinical-trial claims checked against
ClinicalTrials.gov registered results and raw event counts (ARR/NNT/RR+CI
recomputed in code, oracle-tested), code-enforced exact-span grounding, and
multi-source cross-verification. Auth/RBAC/multi-tenancy, document processing
at scale (unpdf + Docling), agentic workflows, Claude Science connector,
compliance/audit, billing, public API, and more.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-08 07:21:22 +03:00

38 lines
1.2 KiB
TypeScript

import type { ImportBatchStatus, ImportRowStatus } from "@/lib/import/types";
// Small colored pill for batch/row status. Purely presentational.
const BATCH_STYLES: Record<ImportBatchStatus, string> = {
pending: "bg-paper text-ink/60 border-ink/10",
committing: "bg-amber-50 text-amber-700 border-amber-200",
committed: "bg-emerald-50 text-emerald-700 border-emerald-200",
failed: "bg-red-50 text-red-700 border-red-200",
};
const ROW_STYLES: Record<ImportRowStatus, string> = {
pending: "bg-paper text-ink/60 border-ink/10",
succeeded: "bg-emerald-50 text-emerald-700 border-emerald-200",
failed: "bg-red-50 text-red-700 border-red-200",
skipped: "bg-paper text-ink/40 border-ink/10",
};
export function BatchStatusBadge({ status }: { status: ImportBatchStatus }) {
return (
<span
className={`inline-flex items-center rounded-full border px-2 py-0.5 text-xs font-medium ${BATCH_STYLES[status]}`}
>
{status}
</span>
);
}
export function RowStatusBadge({ status }: { status: ImportRowStatus }) {
return (
<span
className={`inline-flex items-center rounded-full border px-2 py-0.5 text-xs font-medium ${ROW_STYLES[status]}`}
>
{status}
</span>
);
}