Turns the prior roadmap sketch into ordered, gated work packages (enforcement gates, FP/DDD consistency, CIBG fidelity, Storybook curriculum, a11y) from the 2026-07-02 showcase-hardening audit.
3.2 KiB
3.2 KiB
WP-13 — CIBG-gap register + hygiene + MDX
Status: todo Phase: 2 — CIBG fidelity
Why
User decision: hand-rolled token-bridge components are allowed only if explicitly marked as CIBG-gap extensions in code + Storybook, so every deviation from the design system is auditable. Plus two hygiene items from the audit: a dead wrapper to delete and the list-family rationale to document.
Read first
docs/architecture/0003-*.md(ADR-0003 — the token-bridge rationale this extends)- The audit's gap list (below)
Decisions (pre-made, don't relitigate)
- Marker format (header comment in the component):
// CIBG-GAP EXTENSION: <closest CIBG concept> — <why hand-rolled>plusparameters: { cibgGap: true }and a "CIBG-gap extension" line in the story description. - Keep all three list families — each maps a distinct CIBG pattern:
task-list→ Actieblok,application-list→ Aanvragen,choice-list→ Keuzelijst. Header comment in each names its pattern. Consolidation would blur exactly the design-system mapping this showcase demonstrates. - Delete
upload-status-banner(shared/ui/upload/upload-status-banner/): a 23-line near-identity wrapper overalertwith one consumer — inline<app-alert>there.
Files
Components to mark (closest CIBG concept in parens):
skeleton,spinner(Laadindicatie — no vendored class, verified)upload/suite (Bestand-upload)rich-text-editor(Tekstgebied)wizard-shell(Wizard; error summary → Foutmelding, if WP-11 marked it)confirmation(Bevestiging — verify: it wraps vendored classes; if so it needs no marker, only the pattern comment)debug-state(devtool, no CIBG concept)status-badge(deliberate custom, documented in code),card(.app-card),placeholder-chipPlus:- Delete
upload-status-banner+ its story; inline alert at its consumer - Header comments on
task-list/application-list/choice-list - New
src/docs/cibg-gaps.mdx— titleFoundations/CIBG Gap Register - ADR-0003 gets a cross-link to the register
Steps
- Add the marker to each gap component +
cibgGapstory parameter. - Delete the banner; migrate its one consumer; run its former story's states through the consumer's story if coverage would drop.
- Write the MDX register: a table (component → closest CIBG concept → why) + the rule "grep the vendored CSS before hand-rolling anything".
- Optional but cheap: a
check:cibg-gapsscript that greps markers and diffs against the MDX table, so the register can't silently rot — add tocheck:tokens' CI step if trivial, else note as skipped.
Acceptance criteria
- Every component with hand-rolled surface CSS either wraps vendored classes or
carries the marker (spot-check with a grep for
styles: [vs markers). - Register MDX complete, linked from ADR-0003.
upload-status-bannergone; consumer green; no story coverage lost.- List trio documented.
Verification
GREEN + npm run test-storybook:ci.
Out of scope
Rebuilding any gap component against the design system (they're sanctioned by decision).
Risks
Low — mostly annotation; the deletion is the only behavior-touching change.