diff --git a/CLAUDE.md b/CLAUDE.md index a49f758..75fbedc 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -199,9 +199,14 @@ atomic layer it is (a context organism doesn't get its own `Organisms/` bucket). **token bridge** mapping the app's `--rhc-*` token vocabulary onto CIBG/`--bs-*` values (so components keep referencing tokens). System-font stack (licensed RO/Rijks fonts not shipped). See ADR-0003. - Scenario toggle (**dev-only**, not wired in prod builds): `?scenario=slow|loading|empty|error` - on data pages (`scenario.interceptor.ts`) to see every async state. + on data pages (`scenario.interceptor.ts`) to see every async state — sticky per tab + (change it via a full navigation, not an in-app link). Hand-written `fetch`/XHR calls + (uploads, `/brief/preview`, `/admin/org-template/*/preview`, `/brief/reveal-bignummer`) + bypass the interceptor. - Dev role stand-in (**dev-only**): `?role=drafter|approver|admin` (or the `⚙ state` dev panel). - Roles, how to switch, and what each unlocks: `docs/reference/roles-and-access.md`. + Roles, how to switch, and what each unlocks: `docs/reference/roles-and-access.md`. `admin` + unlocks the capability-gated pages: `/brief/huisstijl` (org-template editor), + `/beheer/stamdata`, `/beheer/zaken`, `/beheer/audit`, `/beheer/functies`. - Prettier; `.editorconfig`. tsconfig: `noImplicitReturns`, `noPropertyAccessFromIndexSignature`, `noFallthroughCasesInSwitch`, `isolatedModules`. - **Enforced, not just hoped-for:** `npm run lint` (`eslint.config.mjs`) fails the build diff --git a/docs/README.md b/docs/README.md index 9d74c84..512cec6 100644 --- a/docs/README.md +++ b/docs/README.md @@ -43,4 +43,5 @@ condensed, cross-linked curriculum. | [backlog/README.md](project/backlog/README.md) | The work-package backlog index (WP-01…WP-48) — the live tracker. | | [prd/0001-mijn-aanvragen-en-wizardstatus.md](project/prd/0001-mijn-aanvragen-en-wizardstatus.md) | PRD — "Mijn aanvragen": running wizards, application status, document preview. | | [prd/0002-attribute-based-access-control.md](project/prd/0002-attribute-based-access-control.md) | PRD — attribute-based access control in the UI. | +| [prd/0003-brief-v2-demo-script.md](project/prd/0003-brief-v2-demo-script.md) | Demo script — Brief v2 scenarios mapped to a URL + click path (WP-28). | | [SHOWCASE-ROADMAP.md](project/SHOWCASE-ROADMAP.md) | Superseded roadmap (absorbed into `project/backlog/`) — kept for history. | diff --git a/docs/project/backlog/README.md b/docs/project/backlog/README.md index 91d94a7..46ca692 100644 --- a/docs/project/backlog/README.md +++ b/docs/project/backlog/README.md @@ -78,7 +78,7 @@ for its existing violations, so every WP ends green. | [WP-25](WP-25-letter-preview-html.md) | Server-rendered letter preview (HTML; PDF deferred) | 6 · Brief v2 | done | | [WP-26](WP-26-org-template-editor.md) | Admin org-template editor | 6 · Brief v2 | done | | [WP-27](WP-27-brief-ux-layer.md) | Brief UX layer (undo/redo, standaardbrief, diff) | 6 · Brief v2 | done | -| [WP-28](WP-28-brief-v2-demo-polish.md) | Brief v2 demo polish (scenarios, e2e, docs) | 6 · Brief v2 | todo | +| [WP-28](WP-28-brief-v2-demo-polish.md) | Brief v2 demo polish (scenarios, e2e, docs) | 6 · Brief v2 | done | | [WP-29](WP-29-stamdata-beheer-editor.md) | Stamdata beheer editor (low-code, PR-emitting) | follow-on · ADR-0004 | done | | [WP-30](WP-30-ci-perf-followups.md) | CI performance follow-ups (node_modules cache, runner image, path filters) | follow-on · CI/infra | todo | | [WP-31](WP-31-shared-store-helpers.md) | Shared store helpers (ActionState/SaveState, history, debounced-save, RemoteData) | 7 · refinements | done | diff --git a/docs/project/backlog/WP-28-brief-v2-demo-polish.md b/docs/project/backlog/WP-28-brief-v2-demo-polish.md index 6ec3ffb..9867eb3 100644 --- a/docs/project/backlog/WP-28-brief-v2-demo-polish.md +++ b/docs/project/backlog/WP-28-brief-v2-demo-polish.md @@ -1,6 +1,6 @@ # WP-28 — Brief v2 demo polish (scenarios, e2e, docs) -Status: todo +Status: done (pending commit; `npm run e2e` unverified in this dev sandbox — see Deviations) Phase: 6 — Brief v2 (edit-on-the-letter, org templates, server-rendered preview) ## Why @@ -45,12 +45,53 @@ that keep CLAUDE.md and the backlog truthful. ## Acceptance criteria -- [ ] Every kept PRD §12 scenario has a working URL + click path in the script +- [x] Every kept PRD §12 scenario has a working URL + click path in the script (walked manually once). -- [ ] `npm run e2e` green, including the new spec. -- [ ] Full GREEN; backlog README statuses correct; CLAUDE.md mentions +- [ ] `npm run e2e` green, including the new spec — **not verified in this dev + sandbox**; see Deviations. +- [x] Full GREEN; backlog README statuses correct; CLAUDE.md mentions `?role=admin` and `/brief/huisstijl`. +## Deviations / notes (as built) + +- **No Brief v2 PRD was ever committed.** WP-23..27 cite "PRD Brief v2 §N" throughout, + but `docs/project/prd/` never held such a file — it only ever existed as chat + context. The demo script (`docs/project/prd/0003-brief-v2-demo-script.md`) is + written directly against the shipped code instead of translating an external §12 + scenario list, and says so up top. +- **`?scenario=` does not reach every endpoint.** `/brief/preview`, + `/admin/org-template/{id}/preview` and `/brief/reveal-bignummer` are hand-written + `fetch` calls (same seam as uploads, deliberately `.ExcludeFromDescription()`'d) and + bypass `scenarioInterceptor`. The demo script and CLAUDE.md now say so explicitly. +- **Canvas authoring moved.** The original "drafter composes on the canvas" framing + predates commit `ba32e3d` ("brief v3 — besluit-driven guided drafting"): + `LetterCanvasComponent.editableRegions` no longer has a `'content'` mode. The + drafter now works through `BehandelSchermComponent` (case header + stepper + + `app-besluit-panel` + `app-letter-editor`), with the canvas as a read-only preview + in a modal. The demo script and e2e spec follow that path. +- **`passage-picker` is dead code** — superseded by `besluit-panel`'s guided + drafting, no consumer left besides its own story. Flagged with a comment on the + component rather than deleted in this WP (out of scope for a demo-polish pass). +- **Story gaps were state gaps, not component gaps** — every component already had a + co-located story. Added: `letter-composer` `RejectionDiff` + `AlleenLezen` (WP-27's + diff view and the pure-viewer notice had no story), `letter-canvas` + + `org-template-editor` `MetLogo` (WP-26's logo letterhead had no story), and + `org-template-editor` `LogoUploadFout` (the upload-rejection branch had no story). +- **Org templates have no reset endpoint** — the e2e spec's admin section restores + the org-template draft it edits (rollback + republish) instead of relying on a + reset, so repeated runs don't drift the seeded "BIG-register" template. +- **`npm run e2e` could not be verified green in this dev sandbox** — both the new + `brief-v2.spec.ts` and the pre-existing, untouched `smoke.spec.ts` fail here at + the same kind of step (clicking a CIBG-styled radio's `