Typography scaling, zoom and rem-based sizing
Row heights, paddings and icons are expressed relative to font tokens, so the grid scales cleanly with browser zoom, user font-size settings and the typography token. It also reflows correctly at 400% zoom.
Planned. This page shows the specification from issue #205. The live example, source for every framework and the API reference replace it when the feature ships.
Live example
A grid with a mix of text, numbers and checkboxes at a 16px base font.
Expected behavior
All dimensions scale together, with no clipped text or overlapping icons. Virtualization recalculates row heights, and at 400% zoom horizontal scrolling of the grid is the only two-dimensional scroll.
Planned API surface
--war-font-size-base token--war-grid-font-size token--war-line-height-* tokensdensity optionAcceptance criteria
- Row height is computed from font and line-height tokens multiplied by the density factor (pending)
- Text is not clipped at any slider value (pending)
- The grid satisfies WCAG 1.4.4 Resize Text up to 200% (pending)
- At a 320 CSS px equivalent width, page content reflows and only the data table scrolls horizontally (the allowed exception) (pending)
- Text spacing overrides (WCAG 1.4.12) cause no loss of content (pending)