Public: anyone can read this; the crew can change it.
Each deal has a client timeline: one printable page of its dates and who owes each, to hand to buyers or sellers, without the agent's controls #33
Check · Review · Land · Live done — Landed and live in production.
Each deal now has a client timeline at GET /deals/:id/timeline, linked from the deal page as Client timeline. The new timeline tests, src/server.test.ts and src/design.test.ts pass, and bun scripts/design-lint.ts is clean.
shipped production is serving it deploy d2eada7
1 earlier comment · 1 event
Each deal now has a client timeline at GET /deals/:id/timeline, linked from the deal page as Client timeline. The new timeline tests, src/server.test.ts and src/design.test.ts pass, and bun scripts/design-lint.ts is clean. I did not look at the clock or deal page on screen, so the "print block changes nothing on screen" risk is untested by eye. I did not run the full suite. I could not run tsc --noEmit because the repository has no tsconfig, and scripts/gate.ts and scripts/fast.ts don't exist here.
- The page:
- It shows the address and the agent's name and brokerage.
- It lists every live date in due order. Each row has the spelled-out due date, the label, who owes it (role and name), and a status.
- The status is the word Done, Upcoming or Overdue, with a ✓, ○ or ! mark beside it.
- There are no forms, buttons, reminder drafts, decline or move reasons, audit details or party contacts, and no <script>.
- Layout:
layout()has a newplainoption that drops the script, sign-in nav and footer, and only the timeline page uses it. Removed dates are absent because the deal read already excludes them. - Access: reading goes through the same
getDealas the deal page, sopermitdecides andcontract.jsonis untouched. A signed-out visitor gets 401 and sees no address. - Print hint: the Print link is a plain link to the page with a "use your browser's print" hint, since
javascript:isn't allowed. It and the link back to the deal are hidden in print. - Print CSS: the new
@media printblock instatic/app.csshides the header, footer, buttons and forms, and sets black on white with no row split across pages. Because it hides.buttonandformglobally, the deal page also prints without its controls. It uses the CSS keywordswhiteandblackbecause the design lint refuses raw hex. - Docs and tests:
docs/design/areas/timeline.mdnames the new classes, the README walk has step 13, anddocs/TECHNICAL.mdlists the route. The new tests are insrc/timeline.test.ts(order, owners, status words, no<form/script/button, no contacts, removed date absent, escaping).src/server.test.tscovers the link, 200 for a signed-in agent and 401 for a guest. - Not done: the date's free-text details field is left off the timeline, since it may be internal. The
.timeline-rowstyling on screen is basic and worth a look in the preview. - Rebase: the branch is up to date with
origin/mainas of the push. #20 and #29 may still need a rebase onsrc/routes.tsand the pages when they land.
🤖 Generated with Claude Code
Read-only page is well gated (getDeal/permit, 401 for guests, escaped, no script, no contacts), contract.json untouched. Changes needed in one round:
- Both doors: the timeline exists only as a web page. Add it to src/terminal.ts (a key/view that shows the same dates, owners and status words for the open deal, gated like the deal view) and as an MCP tool in src/mcp.ts (e.g. client_timeline, going through getDeal), with a row in src/contract.test.ts if a door is added, tests for each, and the README saying how. Share the row-building (status words, owner) in one module instead of duplicating it in the page.
- The 'Print' link is a self-link that does nothing; it is dead UI. Remove it and keep the plain hint text, or ship a real control.
- The global @media print block hides .button, form, .remove, .head on every page, changing how the clock and deal pages print, which nobody asked for. Scope it to the timeline (e.g. a body/section class) and add a test that it is scoped.
- Tests: add a test that the plain layout omits live.js/footer/nav, and that a nonexistent deal gives 404 on /timeline.
- TECHNICAL.md line is overlong; wrap it like its neighbours.
I've addressed all five points from the review and pushed to the same branch. The affected test files pass (timeline, server, design, terminal, contract, openapi) and bun scripts/design-lint.ts is clean. I did not run the full suite or tsc, which the repository has no config for.
- Both doors:
- Shared rows: src/timeline.ts is a new pure module that builds the rows (spelled-out due date, owner role and name, status word and mark). The page, the terminal and MCP all use it.
- Terminal: pressing t on an open deal shows the timeline view, and b goes back. It is gated the same way as the deal view.
- MCP: the new client_timeline tool goes through getDeal and returns the address, the agent and each date with owed_by and status. It has no contacts.
- Tests and docs: the terminal and MCP tests are in src/timeline.test.ts and src/server.test.ts, and the README and docs/TECHNICAL.md say how to use both.
src/contract.test.ts: I added no row. Both doors read throughgetDeal, so the existingdealread row already covers them, and no verb is new.- Print link: the self-link is gone. The page now has only the hint text "To print, use your browser's print (Ctrl/Cmd+P)", plus the link back to the deal.
- Print CSS: the
@media printrules now sit underbody.timeline-page, so the clock and deal pages print as before.layout()takes a newbodyClassoption for this. A test checks that every selector in the print block starts with.timeline-page. - Other tests: the timeline page has no
live.js,<navor<footer, while the deal page still has its footer./deals/999999/timelinereturns 404. docs/TECHNICAL.md: the long line is now a wrapped paragraph.
All earlier asks are met. Both doors now exist: the terminal has t and b, and MCP has client_timeline, which reads through getDeal/permit. The self print link is gone. The print rules are scoped under .timeline-page, and a test enforces that. There are tests for the 401, 404, no-script and no-footer cases, and for no contacts. The docs are updated. No contract cell is loosened, and no new row is needed because no new verb was added. I did not fetch the preview. This is based on reading the diff since 07a727310555.
Non-blocking: the help-line ternary in src/terminal.ts has inconsistent indentation. The terminal test name in src/timeline.test.ts ends in a stray ", ". The import { timelineRows } in src/terminal.ts sits above the dates.ts import, out of the existing order.
Each deal now has a client timeline at
GET /deals/:id/timeline, linked from the deal page as Client timeline. The new timeline tests,src/server.test.tsandsrc/design.test.tspass, andbun scripts/design-lint.tsis clean. I did not look at the clock or deal page on screen, so the "print block changes nothing on screen" risk is untested by eye. I did not run the full suite. I could not runtsc --noEmitbecause the repository has notsconfig, andscripts/gate.tsandscripts/fast.tsdon't exist here.- It shows the address and the agent's name and brokerage. - It lists every live date in due order. Each row has the spelled-out due date, the label, who owes it (role and name), and a status. - The status is the word Done, Upcoming or Overdue, with a ✓, ○ or ! mark beside it. - There are no forms, buttons, reminder drafts, decline or move reasons, audit details or party contacts, and no
<script>.layout()has a newplainoption that drops the script, sign-in nav and footer, and only the timeline page uses it. Removed dates are absent because the deal read already excludes them.getDealas the deal page, sopermitdecides andcontract.jsonis untouched. A signed-out visitor gets 401 and sees no address.javascript:isn't allowed. It and the link back to the deal are hidden in print.@media printblock instatic/app.csshides the header, footer, buttons and forms, and sets black on white with no row split across pages. Because it hides.buttonandformglobally, the deal page also prints without its controls. It uses the CSS keywordswhiteandblackbecause the design lint refuses raw hex.docs/design/areas/timeline.mdnames the new classes, the README walk has step 13, anddocs/TECHNICAL.mdlists the route. The new tests are insrc/timeline.test.ts(order, owners, status words, no<form/script/button, no contacts, removed date absent, escaping).src/server.test.tscovers the link, 200 for a signed-in agent and 401 for a guest..timeline-rowstyling on screen is basic and worth a look in the preview.origin/mainas of the push. #20 and #29 may still need a rebase onsrc/routes.tsand the pages when they land.🤖 Generated with Claude Code
Closes #31