From 29557f06e0a8e8bf76cf55f47592a271d2291d6d Mon Sep 17 00:00:00 2001 From: Chandler Copeland Date: Fri, 3 Apr 2026 16:31:04 -0600 Subject: [PATCH] feat(16-04): render N/M signed badge in DocumentsTable Status column - Extend DocumentRow type with optional signedCount, totalSigners, hasMultipleSigners - Render badge after StatusBadge only for multi-signer Sent documents (D-11, D-12, D-13) - Badge: inline-flex items-center px-2 py-0.5 rounded-full text-xs font-medium bg-blue-50 text-blue-700 ml-1.5 - Shows '{N}/{M} signed' text from server-computed token counts - No badge for single-signer or fully-signed documents --- .../src/app/portal/_components/DocumentsTable.tsx | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/teressa-copeland-homes/src/app/portal/_components/DocumentsTable.tsx b/teressa-copeland-homes/src/app/portal/_components/DocumentsTable.tsx index 0e7b7b5..6ad43d2 100644 --- a/teressa-copeland-homes/src/app/portal/_components/DocumentsTable.tsx +++ b/teressa-copeland-homes/src/app/portal/_components/DocumentsTable.tsx @@ -9,6 +9,9 @@ type DocumentRow = { sentAt: Date | null; signedAt: Date | null; clientId: string; + signedCount?: number | null; + totalSigners?: number | null; + hasMultipleSigners?: boolean; }; type Props = { rows: DocumentRow[]; showClientColumn?: boolean }; @@ -62,6 +65,11 @@ export function DocumentsTable({ rows, showClientColumn = true }: Props) { )} + {row.hasMultipleSigners && row.status === "Sent" && row.totalSigners != null && row.totalSigners > 0 && ( + + {row.signedCount ?? 0}/{row.totalSigners} signed + + )} {row.sentAt