Components
- DialogModals and confirmations on the native
<dialog>, with focus returned and a safe default for destructive actions. - TabsThe APG tabs pattern with automatic or manual activation, and panels anywhere on the page.
- Segmented controlRadio-group semantics that look like buttons; form-associated through ElementInternals.
- Data tableA real table for dense numbers: grouped headers, sticky columns, announced sorting.
Principles
- Semantic HTML first; ARIA only to fill gaps. A native
<dialog>, a real<table>, form participation throughElementInternals. ARIA is added where HTML has no element for the job (tabs, radio groups that look like buttons). - Keyboard parity. Everything a mouse can do, a keyboard can — following the ARIA Authoring Practices keyboard models, tested in a real browser.
- Never colour alone. Up/down, selected, at-the-money: each also has text, shape or an icon.
- Tokens that are tested, not hoped. Contrast is computed against real backdrops; a failing pair fails the build.
- Respect the user's settings. Reduced motion, increased contrast, reduced transparency and Windows forced colours each change behaviour.
- Framework-free, React-friendly. Plain custom elements. React 19 uses them directly — properties, events and all.
Design tokens
Colour, type, spacing, radius, motion and focus tokens are CSS custom properties (--tai-*) generated from one source file. The app switches theme with <html data-theme>; without it, tokens follow the operating system. Each chip shows light (top-left) and dark (bottom-right).
-
--tai-color-fg#0E1A2B · #E7EBF3 -
--tai-color-fg-muted#475569 · #C3CAD7 -
--tai-color-fg-subtle#566174 · #9AA4B6 -
--tai-color-canvas#F3F6FB · #0F1218 -
--tai-color-surface#FFFFFF · #171B23 -
--tai-color-border-control#6F7B8F · #6B768A -
--tai-color-accent#1D4ED8 · #2563EB -
--tai-color-focus#1D4ED8 · #8AB4FF -
--tai-color-up#05694C · #34D399 -
--tai-color-down#B42318 · #F87171 -
--tai-color-danger#B42318 · #DC2626 -
--tai-color-highlight#FDE68A · #4A3B0A
Contrast, measured
“Glass” means the translucent surface composited over each reference backdrop — white, the top and the deepest blue of the homepage hero (light), or the graphite canvas, surface and panel (dark). The ratio shown is the worst case. The unit tests run the same calculation.