Skip to main content

Design system

The tokens, the layout slots, the accessibility contracts every component keeps and what the lint checks. To see the colours, type scale and spacing drawn in both themes, with their contrast ratios, open Design tokens, visually.

This page is built from DESIGN.md in the repository, which is where it is edited.

At a glance​

The document is long, so the site gives each section its own page. A section that is still long is cut into numbered parts.

About this document​

The map is the hero and the chrome recedes. MapCairn is calm, neutral and precise, with grouped controls, a floating search pill and a bottom sheet, in the way people already expect from a good maps app. Light and dark are equally polished. The target is WCAG 2.2 AA, built in from the first component.

Tokens live in packages/theme/src/tokens.css.ts. Components may only use tokens, so an off-scale value fails typecheck, and a lint test is the backstop for raw literals.