Three defects the first sweep left behind, each caught by a rule the guard did not yet have. Statuses. RULES.md gives three; the tree had 25 values, and the free-text ones were carrying progress. "Implemented (wiring landed)" and "Ratified (rev. 2e). Rev. 2e adds the OpenTaskByPR lookup. Rev. 2d revised section 10..." were both changelogs living in the one field the other rules exempt. Every PRD now declares Draft, Approved or Finalised and nothing else; five that declared nothing now declare one. A revision number moves to **Revision:**, a pointer to the authoritative document to **Authority:**, and what a past revision changed to git. CLAUDE.md's citation of state-store-contract rev. 2e still resolves. Stale cross-references. "Supersedes the 2026-09-03 open question", "this bullet previously said", "an earlier draft of this document claimed" all point at text the reader cannot see, because it was replaced. A supersede marker survives only when it names a file, a section or a symbol that can be found. Temporal hedges. 100 uses of today, currently and right now across 31 files. Each dates its sentence to the day it was written: "[notify] today is one webhook URL, read in one place" stops being true the moment this design lands, while still reading as the premise it rests on. The header-field exemption was also too wide. "**Date:** 2026-09-03, Channel resolved 2026-09-22" smuggled a dated status into the one line the rules did not read; the exemption is now a Date holding only a date and a Status holding only one of the three.
103 lines
4.5 KiB
Markdown
103 lines
4.5 KiB
Markdown
# Dashboard port: what the agent delivers
|
|
|
|
**Status:** Approved
|
|
**Date:** 2026-09-20
|
|
**Beads:** `archie-core-tavn` (epic), `archie-core-ocfm` (navigation)
|
|
**Reads with:** `docs/prds/vue-migration-checklist.md` (the item-by-item),
|
|
`docs/prds/dashboard-navigation-groups.md` (the approved nav design)
|
|
|
|
This is the standard the port is held to. The checklist says what to port; this
|
|
says how, and what counts as done. It exists because the first attempt ported
|
|
the flat topbar verbatim and invented a palette, both of which had already been
|
|
decided elsewhere.
|
|
|
|
## The deliverable
|
|
|
|
The Preact dashboard, rebuilt in Vue 3 with shadcn-vue, feature complete
|
|
against the checklist, gate clean, with `ui/dist` rebuilt and committed in the
|
|
same commit as the source it was built from.
|
|
|
|
## Non-negotiables
|
|
|
|
- **Vue 3 + shadcn-vue (Reka UI, Tailwind v4, Lucide).** A component that
|
|
exists in shadcn-vue is not hand-rolled. Add it with the CLI
|
|
(`npx shadcn-vue@latest add <name>`), do not paste it in.
|
|
- **History routing.** `createWebHistory`, `base: "/"`. No hash routing.
|
|
`src/legacy-hash-redirect.ts` handles old `#/path` links and stays.
|
|
- **No test port.** 43 Preact test files are deliberately dropped.
|
|
`task test:ui` is a `vue-tsc` typecheck. Write a test when there is a real
|
|
failure to pin, not to re-assert a port.
|
|
- **Do not downgrade TypeScript.** The target is TS 7 native, not TS 5.
|
|
- **`ui/dist` is law.** Never hand-edit it, never omit it, never revert it.
|
|
- **`task check` is the gate.** Not an assembled substitute for it.
|
|
- **Beads, not markdown TODOs**, for anything that outlives the change.
|
|
- **Conventional commits**, scoped `feat(webui):`. Commit gate-clean work
|
|
without asking. Do not push without being told.
|
|
|
|
## Componentisation
|
|
|
|
One component, one job, one file. A surface is composed from named components,
|
|
not assembled inside a single large file. The topbar is the worked example and
|
|
the required shape:
|
|
|
|
```
|
|
components/topbar/
|
|
Topbar.vue composes the header, owns nothing else
|
|
Brand.vue Logo + BrandName, links to /
|
|
Logo.vue
|
|
BrandName.vue
|
|
Nav.vue reads the nav model, renders links and groups
|
|
NavTrigger.vue the shared top-level control, link or dropdown trigger
|
|
NavGroup.vue one dropdown
|
|
NavItem.vue one item inside a dropdown, with its tooltip
|
|
SearchBar.vue
|
|
SupportLink.vue
|
|
ThemeToggle.vue
|
|
ProfileDropdown.vue
|
|
```
|
|
|
|
The same rule applies to every page ported after it. If a file is doing the
|
|
work of four named things, it is four files. Data and behaviour that more than
|
|
one component needs lives in `src/lib/`, not passed down through a chain of
|
|
props.
|
|
|
|
## Ordering
|
|
|
|
Build the navigation restructure during the port, not after it. Porting the
|
|
flat eleven-item bar first and restructuring later means writing the topbar
|
|
twice and touching the Go route registry twice. The approved design is five
|
|
top-level items (Dashboard, Work, Agent, Events, System), items renamed because
|
|
their group carries the context, per-item descriptions shown as hover tooltips,
|
|
Configuration split into `/system/*`, `/settings` kept as a redirect, and Logs
|
|
finally given a nav entry.
|
|
|
|
## Design authority
|
|
|
|
- The approved documents win. Where a document decides something, implement it
|
|
rather than re-deciding it.
|
|
- **Do not invent a visual direction.** Palette, typography and density are the
|
|
maintainer's call. A palette change is its own request, never a side effect
|
|
of a port.
|
|
- Contrast is AA against every surface the foreground lands on, hover states
|
|
included. The corrected values (`--fg-subtle`, the dark
|
|
`--primary-foreground`) came from a measured failure and must survive.
|
|
- `color-scheme` follows the theme so the UA paints controls, scrollbars and
|
|
overscroll to match.
|
|
|
|
## Code style
|
|
|
|
Comment the non-obvious why: an invariant, a trap, a measurement, a contract
|
|
another file depends on. Do not narrate what the code plainly does, do not
|
|
explain a choice that was never in question, and do not write migration phase
|
|
history into a diff. That history belongs in the commit message.
|
|
|
|
## Done, per surface
|
|
|
|
1. Renders with real data against `task dev`, not just typechecks.
|
|
2. Keyboard reachable, focus visible, and the nav announces where you are.
|
|
3. Works at 1440x900 and at 720px wide, with nothing clipped and no horizontal
|
|
page scroll.
|
|
4. Empty, loading, failed and unconfigured (501) states all say something true.
|
|
A section that cannot load says so; it does not render blank.
|
|
5. `task check` passes, `ui/dist` rebuilt, committed together.
|