Color tokens are named for their job, not their hue. Use them and light and dark themes work without extra code. Switch the theme in the header to see every value on this page update.
Surfaces
Backgrounds, from the page up through raised containers.
CanvasThe page background.
CardRaised containers: cards, dialogs, menus.
SubtleGrouped areas, such as table headers.
MutedHovered rows, inactive tracks.
Text
Use the highest contrast that fits the content's importance.
DefaultHeadings and body text.
MutedCaptions, helper text, metadata.
On fillText on strongly colored fills.
Borders
Dividers can be quiet. Control edges need to stay visible.
SubtleDividers and soft outlines.
StrongEdges that identify a control.
FocusKeyboard focus rings only.
Interactive
Aster's primary action is monochrome, so status colors keep their meaning.
PrimaryThe main action on a screen.
Primary hoverPrimary action while hovered.
Primary textLabel on the primary fill.
LinkInline text links.
Status
Each status pairs a surface with its text color. Always add a word or icon, because color alone isn't enough.
Success surfaceBackground for positive messages.
Success textText and icons for positive messages.
Warning surfaceBackground for cautions.
Warning textText and icons for cautions.
Critical surfaceBackground for errors.
Critical textErrors and destructive actions.
Info surfaceBackground for neutral notices.
Info textText and icons for neutral notices.
Active surfaceBackground for active items.
Active textText for active items.
Contrast
Calculated live from the current theme. Text needs 4.5:1, and controls and focus rings need 3:1.
Pairing
Ratio
Result
Default text on canvas
Muted text on canvas
Muted text on card
Primary label on primary fill
Success text on its surface
Warning text on its surface
Critical text on its surface
Info text on its surface
Active text on its surface
Focus ring on canvas
Control edge on card
Using color
Do
Use semantic tokens such as --as-semantic-color-text-default in all component and page styles.
Don't
Use primitive tokens or hex values. They won't follow the theme.