docs: bring every document current — runbook gains D16 go-live knobs, delivery stamps on all executed specs/plans, 14-SPEC delivery note, README doc table

- DEPLOY-HQ.md §6b: share.base_url (required for quote follow-up emails),
  quote.followup.policy manual/auto, dated reminder_schedule cadences,
  employee accounts + account-owner assignment at go-live
- STATUS/README/CLAUDE already at 293 tests; specs/plans now carry their
  DELIVERED/EXECUTED stamps so the archive reads honestly

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
feat/client-detail-redesign
Thomas Joise 5 days ago
parent 7862452989
commit 418555179b

@ -26,6 +26,11 @@ document and conversation we've had with them.
- **Reports**, a **Dashboard**, an **append-only audit log** (every mutation), an **APEX
importer** for the initial 300-client load, and a **scheduler** (runs on boot + every 6h:
reminders, bounce polling, AWS cost pull).
- **A redesigned ops UI (2026-07-17)** — warm light/dark theme with a teal accent, grouped
sidebar with a live reminder badge, a **Ctrl-K command palette** (client search, pages,
actions), and a **Client 360** with tabbed sections and a 12-month **relationship-pulse
ribbon**; phone-usable drawer layout. Spec:
`docs/superpowers/specs/2026-07-17-hq-console-redesign-design.md`.
## Build state (start here)
@ -54,6 +59,8 @@ runbook (server, HTTPS, backups, Gmail/AWS/import wiring, the Postgres switch) i
| Doc | What it covers |
|-----|----------------|
| [docs/14-SPEC-HQ-CONSOLE.md](docs/14-SPEC-HQ-CONSOLE.md) | The console spec: shape, data model, features, delivery sequence (D15) |
| [docs/superpowers/specs/2026-07-17-quote-to-close-funnel-design.md](docs/superpowers/specs/2026-07-17-quote-to-close-funnel-design.md) | The delivered D16 funnel slice — employees, pipeline, escalating reminders, convert/supersede, module roster |
| [docs/superpowers/specs/2026-07-17-hq-console-redesign-design.md](docs/superpowers/specs/2026-07-17-hq-console-redesign-design.md) | The delivered warm ops-console UI redesign |
| [docs/11-ADMIN-SUPPORT-CONSOLE.md](docs/11-ADMIN-SUPPORT-CONSOLE.md) | The vendor-side HQ / support console this app implements |
| [docs/07-DB-AND-CONFIG.md](docs/07-DB-AND-CONFIG.md) | Everything-in-DB design (messages, plans, settings) and the local DB engine analysis |
| [docs/06-DECISIONS.md](docs/06-DECISIONS.md) | Founder decisions, including D15 (build HQ early) and the Postgres call |

@ -207,3 +207,26 @@ convert+issue → post-commit email), proforma `POST /documents/:id/supersede`,
`dN` milestone escalation (d7/d15/d30 from the dated schedule, F7 highest-only
catch-up), and the module → client roster (`GET /modules/:id/clients` + CSV export +
owner/manager Notify-all with per-recipient audit). Suite at 293 tests / 57 files.
## D17 — HQ console visual redesign: warm ops-console (2026-07-17)
Founder-approved spec in `superpowers/specs/2026-07-17-hq-console-redesign-design.md`
(delivered same day; adversarial multi-agent review + fixes recorded there). Decisions
locked with it:
- **Direction: "Direction A v2 discipline wearing the H-04 warm palette."** Synthesised
from the two most recent design artifacts (the chosen Claude-Design "Direction A v2"
system and the H-04 Client 360 mockup): warm paper neutrals (`#FAFAF7`/`#E7E5DE`/
`#1A1A17`), flat border-defined surfaces, shadows only on overlays.
- **Teal is the default accent; primary buttons are ink, not accent.** Accent colour is
reserved for *state* (active nav, chips, links, focus). The 6 previous accents stay
switchable; dark mode is warm-tinted with explicit per-accent dark values.
- **Mono/sans split.** JetBrains Mono for machine data (codes, doc numbers, GSTINs, ids);
Inter with tabular numerals for money. Uppercase micro-labels never below 11px (WCAG).
- **Ctrl-K command palette over more nav.** Client search + pages + actions in one
keyboard-first overlay (generic `CommandPalette` in `@sims/ui`; AND-term matcher).
- **Client 360 = record header + KPI row + relationship-pulse ribbon + deep-linkable
tabs** — the ribbon plots documents / payments / interactions / AMC on one 12-month
axis from data the page already loads (no chart lib, no new endpoints).
- **UI-only slice.** No backend/schema changes; `@sims/ui` stays generic (no router or
icon deps — `lucide-react` lives in `apps/hq-web` only). Known deferred: server-side
"outstanding ₹" figure for the Client 360 KPI row (client-side paise math is banned).

@ -153,6 +153,16 @@ nothing is dropped. HQ-1's headline is the founder's stated top pain: documents
**HQ-1.5 (immediate follow-up to HQ-1):** per-module quote-content blocks and pack
pick-lists (SMS 50k / 1L style) in the composer and on the PDF (spec §2 module bullet).
**Delivered beyond this phasing (2026-07-17, D16 — the quote-to-close funnel slice):**
employee management with owner/manager/staff roles, account-owner routing on clients, the
cross-client Pipeline chase-list (derived stages, no new pipeline storage), escalating
quote follow-up reminders (owner nudge + client email at dated 3/7/14 offsets), invoice
overdue escalation at dated d7/d15/d30 milestones, one-click proforma→invoice
convert-and-send, proforma supersede, and the module→client roster with Notify-all and
CSV export — plus the warm ops-console UI redesign. Spec:
`superpowers/specs/2026-07-17-quote-to-close-funnel-design.md`; record: D16 in
[06-DECISIONS.md](06-DECISIONS.md); current state: `../STATUS.md`.
## 7. Non-goals (v1)
Dealer portal; impersonation; client-facing portal; WhatsApp sending (email first — the

@ -74,6 +74,24 @@ Do a **restore drill** once: copy a backup to a scratch box and boot the app aga
- **Your 300 clients**: export `clients.csv` + `invoices.csv` from APEX into `import-drop/`,
then run the importer (verification report first, `--commit` after you approve).
## 6b. Funnel slice knobs (D16 — set these at go-live)
- **`share.base_url` setting** (required before quote follow-ups can email): set it to the
public origin, e.g. `https://hq.yourdomain.com`, via the settings API or a one-line SQL
insert into `setting`. The escalating quote follow-up **refuses to send** without it —
a client email carrying a dead relative link is worse than no email.
- **`quote.followup.policy` setting**: `manual` (default — nudges queue on the dashboard
and a person clicks Send) or `auto` (client emails go out unattended after each daily
scan). Start on `manual`; flip to `auto` once the letter text has been seen in anger.
- **Reminder cadences are dated rows**, not env vars: `reminder_schedule` ships seeded with
`quote_followup` at 3/7/14 days and `invoice_overdue` at 7/15/30 days past invoice date.
To change a cadence (or the follow-up email wording), insert a **new dated row**
effective from a business date, no release, no restart.
- **Employee accounts**: after first boot, open **Employees** (owner-only nav) and create
the real manager/staff logins. Staff see only their own pipeline and reminder queue;
owner/manager see everything. Deactivating someone kills their session immediately.
- **Account owners**: assign an owner on each client (Client 360 → Account owner) so
leads route to the right person's queue; unassigned rows stay visible to owner/manager.
## 7. The Postgres switch (before or at go-live)
Decision D15 locks Postgres as the production engine. It is a **dedicated engineering task,
not a config flag** — the repositories move from synchronous SQLite to async Postgres

@ -1,4 +1,5 @@
# HQ-1 — Internal Ops Console Implementation Plan
> **STATUS: DELIVERED (HQ-1, 2026-07).** Kept as the design/task record; current state lives in STATUS.md.
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.

@ -1,4 +1,5 @@
# HQ-3a — AWS Cost Attribution, Reports, Receipts & Company Profile Implementation Plan
> **STATUS: DELIVERED (HQ-3a, 2026-07).** Kept as the design/task record; current state lives in STATUS.md.
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking. Every task is a full TDD loop: write the failing test verbatim → run it to watch it fail → write the implementation → run it to green → commit. No task depends on code a later task writes.

@ -1,4 +1,5 @@
# Live Document Preview — Implementation Plan (HQ console)
> **STATUS: DELIVERED (2026-07-13).** Kept as the design/task record; current state lives in STATUS.md.
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking. **Server tasks (17) are full TDD loops:** write the failing test verbatim → run it to watch it fail → write the implementation → run it to green → `npm run typecheck` → commit. **Frontend tasks (813) cannot be unit-tested** (they are iframe/layout/matchMedia/upload UI) — each ends with an explicit **browser-verification** step against the live app instead of a vitest step, still committing on completion. No task depends on code a later task writes.

@ -1,5 +1,8 @@
# HQ Console Redesign Implementation Plan
> **STATUS: EXECUTED 2026-07-17.** All 14 tasks landed and the §8 verification pass was
> recorded (commit `062ddd0`); kept for the task-level rationale and rollback reference.
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
**Goal:** Restyle the HQ console into the approved warm ops-console design (spec: `docs/superpowers/specs/2026-07-17-hq-console-redesign-design.md`) — warm palette + teal accent, grouped sidebar, Ctrl+K palette, upgraded tables/states, and a Client 360 with a 12-month relationship-pulse ribbon.

@ -1,4 +1,5 @@
# Live Document Preview — Design (HQ console)
> **STATUS: DELIVERED (2026-07-13).** Kept as the design/task record; current state lives in STATUS.md.
**Status:** approved (founder, 2026-07-13, via ultracode design panel + brainstorm).
**Origin:** spec [14-SPEC-HQ-CONSOLE.md](../../14-SPEC-HQ-CONSOLE.md) §3 already promised a

@ -1,4 +1,5 @@
# Quotation Polish + Share/Download — Design
> **STATUS: DELIVERED (2026-07-13).** Kept as the design/task record; current state lives in STATUS.md.
**Status:** approved in principle (founder, 2026-07-13). Sequenced to run **after** the
live-preview build (wf live-preview) lands, so it builds on the finished `templates.ts`

@ -1,5 +1,10 @@
# HQ Console Redesign — Design Spec
> **STATUS: DELIVERED 2026-07-17.** All 14 plan tasks landed (warm token system, grouped
> sidebar shell + Ctrl-K palette, new primitives, every page restyled incl. Client 360
> tabs + relationship-pulse ribbon and split-panel login); verification recorded in
> commit `062ddd0` and the suite has stayed green since (293 tests at last count).
*Approved direction: "system upgrade" — Direction A v2's system discipline wearing H-04's
warm palette. Sources reviewed: `admin_design_v2.html` (a Claude Design handoff tar; the
chosen "Direction A v2" system), `H-04 Client 360 (timeline ribbon).html`, `Tecnostac

@ -1,5 +1,10 @@
# HQ Console — Growth Features Spec (Employee Foundation, Pipeline, Escalating Reminders, Module Roster, Convert/Supersede)
> **STATUS: DELIVERED 2026-07-17.** All ten phases of PART B landed the same day
> (phases 16 + review fixes via the build swarm; 710 in the second pass), verified
> at 293 tests / 57 files with a live boot smoke. Delivery record: D16 in
> `docs/06-DECISIONS.md`; current capabilities: `STATUS.md`.
*Final merged spec. Reconciles the combined WS1WS5 design against the simplicity, house-rules, and completeness critiques. Where critics conflicted I took the simplest option that breaks no locked decision and no hard rule. Every deviation is flagged inline.*
---

Loading…
Cancel
Save