Wire the matter-shell chrome into the live /matters/[id]
Story-1382 built MatterDetailHeader + MatterRightRail
in Storybook. This puts them on the live matter-detail
route against real MatterDetailView data, replacing the old
LiveMatterDetailPage header + summary. No faked data.
Composition
-
New client
LiveMatterShell= stickyMatterDetailHeader+[ main body | MatterRightRail ]. -
page.tsxdemo path is untouched; the live path now fetches onlymattersGateway.get()and renders the shell. The old heavy fetches (proceedings, related matters, documents, carry-forward, forums) and their bound actions were removed — nothing renders them now that the Brief body is blank. -
MatterDetailHeader.agentmade optional — the matter-type-lead agent is not in the payload, so the pill is omitted (not faked).
Data mapping — MatterDetailView → chrome
| Prop | Source |
|---|---|
| header matterRef / title / status | matter.matterRef / .title / .status (enum is identical, no map) |
| header proceedingCount · lens label | matter.proceedings.length · localized "All proceedings" |
| header agent | omitted (not in payload — follow-up) |
| rail caseRef / status / proceedingsCount | direct; lifecycle = status==="closed" ? closed : active |
| rail leadCounsel / forum | null → em-dash (team + per-proceeding forum not in payload — follow-up) |
Brief body — intentionally blank
Per the matter-shell design the tab bodies are TipTap surfaces built
later; for this PR the Brief body renders empty (the
old summary / operating-model / proceedings / related-matters /
carry-forward UI was removed from this route). Other tabs show a
localized placeholder. briefBody stays as the documented
seam for when the brief content lands.
Verification live
- New
MatterDetailkeys (allProceedings,tabPlaceholder) added to bothen.json+hi.json. (Caught + fixed an insert that first landed in the wrong namespace — the lens chip rendered the raw key until corrected.) - Verified live on
/matters/M-0004(LIVE DB): header (M-004 crumb · serif title · Discovery pill · ⌘K search · 7 tabs · "All proceedings 1 ▾" lens) + the Matter-administration rail (Lead counsel / Forum / Case ref em-dash, Status Discovery, Proceedings 1·manage, Open/close Active) + icon strip, with a blank Brief body. pnpm lint0 errors ·pnpm buildgreen · tokens only.
Out of scope (later PRs)
URL-driven tab routing; per-tab body content (sub-nav + TipTap); wiring the matter-type-lead agent, lead counsel, and per-proceeding forum once they land in the detail payload.
Files changed
6 file(s), +91 / -104 lines
| Path | Role | + | - |
|---|---|---|---|
| messages/en.json | Config | +2 | -0 |
| messages/hi.json | Config | +2 | -0 |
| src/app/[locale]/(workspace)/matters/[matterId]/page.tsx | App route | +9 | -80 |
| src/components/matter-detail/matter-detail-header.tsx | Component | +4 | -1 |
| src/components/matters/live-matter-shell.tsx | Component | +69 | -0 |
| tests/unit/matter-detail-route.test.tsx | Test | +5 | -23 |