Add shared Icon primitive and controlled glyph vocabulary (Carbon, filled)

This commit is contained in:
2026-06-06 23:51:47 +03:00
parent af9ee1e4c0
commit 3e89d9a531
18 changed files with 587 additions and 77 deletions
@@ -110,6 +110,11 @@ states are part of the feature, not an afterthought (Carbon empty-states, GOV.UK
- **Wording** (NN/g #9, GOV.UK, Carbon content): plain language, **no error codes in the
user-facing line**, second person, name what stopped in the title, one or two sentences
in the body, never flippant.
- **Status carries a glyph, not only colour** (arch 09 §5.2 status set; Carbon notification
taxonomy). Error/warning/success/info surfaces (toasts, inline warnings) lead with the
**filled status icon**, coloured by severity — a redundant non-colour channel so severity
reads under colour-blindness (WCAG 1.4.1), with the triangle shape-coding warning apart
from the round error/success/info. Colour + icon + title together; never colour alone.
## 4. Recovery & data-safety contract
@@ -229,9 +234,9 @@ Not features to add later — the baseline every surface is built on.
- **Reduced motion is honored globally.** Animations/transitions are neutralized under
`prefers-reduced-motion` (`styles/base.css`); never gate meaning on motion.
- **Colour is never the sole signal** (WCAG; Carbon status pattern). Pair it with a label,
icon, shape, or text — a red toast border also has a title and an `alert` role; the
draft dot has a `title`/`aria-label`.
- **Colour is never the sole signal** (WCAG 1.4.1; Carbon status pattern). Pair it with a
label, icon, shape, or text — a toast carries a title, an `alert`/`status` role, **and a
filled status glyph** coloured by severity (§3); the draft dot has a `title`/`aria-label`.
- **Every control is labelled.** Icon-only buttons, toggles, and fields carry accessible
names so assistive tech can announce them.
- **A binary toggle exposes its state, not just its action.** A theme/on-off control is a