feat(documents): detail page with signers, watchers, activity, actions

Replaces the PR4 stub at /documents/[id] with the full Phase A detail
view: gradient header strip, status-aware action bar (Cancel /
Download / Email signatories), per-signer remind + copy-link, watcher
list with remove, and activity timeline. Adds the supporting endpoints
(cancel, compose-completion-email, watchers GET/POST/DELETE) and
listDocumentWatchers / addDocumentWatcher / removeDocumentWatcher
service helpers. The document GET now serves the aggregator shape
when ?detail=true.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Matt Ciaccio
2026-04-28 02:39:46 +02:00
parent 2a3fae4d6a
commit aa15807063
8 changed files with 568 additions and 16 deletions

View File

@@ -1,6 +1,4 @@
import Link from 'next/link';
import { Button } from '@/components/ui/button';
import { PageHeader } from '@/components/shared/page-header';
import { DocumentDetail } from '@/components/documents/document-detail';
interface PageProps {
params: Promise<{ portSlug: string; id: string }>;
@@ -8,17 +6,5 @@ interface PageProps {
export default async function DocumentDetailPage({ params }: PageProps) {
const { portSlug, id } = await params;
return (
<div className="flex flex-col gap-4">
<PageHeader
title="Document detail"
description={`Document ${id} — full detail view ships in PR5 of the Phase A rollout.`}
actions={
<Button asChild variant="outline">
<Link href={`/${portSlug}/documents`}>Back to documents</Link>
</Button>
}
/>
</div>
);
return <DocumentDetail documentId={id} portSlug={portSlug} />;
}