Clay

  • Themes
  • light
  • dark

Warm paper, graphite ink and a single clay dot per screen.

Values come from the @feugene/granularity-tokens package

On this page

Specimen

RoleLightDark
--gr-bg#faf9f5#262624
--gr-card#ffffff#30302e
--gr-fg#141413#faf9f5
--gr-muted-fg#5e5d59#b0aea5
--gr-primary#d97757#d97757
--gr-accent#f6e8e0#46352d
The same markup in an island of each mode: the only difference is the pair on the subtree.

What it is for

Reading, editors, assistants — screens where the text matters most and the interface steps back. Warm surfaces and graphite ink take the chill off product themes, and the single warm accent shows what the screen was opened for. The theme is a copy of slate (theme:copy), not an heir: a language of its own, every value is its own, and edits to Slate do not reach it. A new token of the component package reaches Clay not silently but as a doctor finding, and its author decides the value.

Rules of use

  • The main button of an area is tone="neutral": a graphite fill, light in the dark mode. The clay primary is an accent, not every action.
  • One clay per screen: the thing the screen was opened for. Two clay buttons side by side argue with each other, and the accent stops being an accent.
  • Tone lives in the fill and the label; borders are warm gray. secondary and outline of any tone share one border — graphite at 15 % and 30 %.
  • Under the pointer the fill moves away from the label color: under a graphite label it lightens, under a light one it darkens. Contrast only grows on hover. The exception is the main button: its fill is already at the edge of the scale, so it moves toward the middle — graphite lightens, paper darkens.
  • A button does not move and does not glow: no shadows, loading is light running over the label, not a spinner, a button group is a tray (the theme’s component defaults, componentDefaults).
  • Only what lies above the page casts a shadow: a popover panel and a toast — 8/24, a dialog — 16/48. A card is a white sheet with a hairline border, without a shadow.
  • Quiet defaults: tabs as a line, badges with the semi radius, a path through «/», an avatar — initials on paper without a random color, progress — a graphite bar without a border.
  • As with any theme of the package: text color comes from -text, the border of a toggle control is --gr-control-brd.

Modes

ModePurpose
lightthe default mode: warm paper, graphite ink, a white card sheet over the page
darkwarm graphite instead of black; the main button inverts — a light fill with a graphite label; clay stays clay

Pairs on the root

The user's choice stores the mode name, and the root gets the pair of the theme and the mode. Nobody writes the pair by hand: the build's manifest provides it.

Identifier
clay
ModeSchemePair on the root
light · defaultlightdata-theme="clay-light"
darkdarkdata-theme="clay-dark"

Roles

The value of each role in every mode, and the contrast where it means something.

Surface roles

TokenLightDarkContrast
--gr-bg--gr-bg#faf9f5#262624
--gr-fg--gr-fg#141413#faf9f517.50 / 14.39against --gr-bg
--gr-card--gr-card#ffffff#30302e
--gr-card-fg--gr-card-fg#141413#faf9f518.43 / 12.55against --gr-card
--gr-popover--gr-popover#ffffff#30302e
--gr-popover-fg--gr-popover-fg#141413#faf9f518.43 / 12.55against --gr-popover
--gr-muted--gr-muted#f0eee6#3a3a37
--gr-muted-fg--gr-muted-fg#5e5d59#b0aea55.67 / 5.13against --gr-muted
--gr-secondary--gr-secondary#e8e6dc#3a3a37
--gr-secondary-fg--gr-secondary-fg#3d3d3a#d1cfc58.71 / 7.30against --gr-secondary
--gr-overlay-bg--gr-overlay-bgrgb(28 27 24 / 0.45)rgb(10 10 9 / 0.6)
--gr-brd--gr-brd#d9d8d5#42423f
--gr-brd-strong--gr-brd-strong#b8b7b4#5f5e5a
--gr-input--gr-input#82817e#878681
--gr-input-hover--gr-input-hover#565553#afaea8
--gr-input-focus-brd--gr-input-focus-brdvar(--gr-ring)var(--gr-ring)
--gr-input-readonly-bg--gr-input-readonly-bgtransparenttransparent
--gr-input-readonly-brd--gr-input-readonly-brdvar(--gr-brd)var(--gr-brd)
--gr-control-brd--gr-control-brd#82817e#878681
--gr-control-brd-hover--gr-control-brd-hover#565553#afaea8
--gr-ring--gr-ring#2a78d6#6aa3e8

State roles

TokenLightDarkContrast
--gr-disabled-bg--gr-disabled-bg#f0eee6#353532
--gr-disabled-fg--gr-disabled-fg#9c9a92#73726c
--gr-disabled-brd--gr-disabled-brdvar(--gr-disabled-bg)var(--gr-disabled-bg)
--gr-invalid-brd--gr-invalid-brdvar(--gr-danger)var(--gr-danger)
--gr-invalid-ring--gr-invalid-ringvar(--gr-danger)var(--gr-danger)
--gr-invalid-text--gr-invalid-textvar(--gr-danger-text)var(--gr-danger-text)7.13 / 7.48against --gr-bg

Action roles

TokenLightDarkContrast
--gr-primary--gr-primary#d97757#d97757
--gr-primary-fg--gr-primary-fg#141413#1414135.90 / 5.90against --gr-primary
--gr-accent--gr-accent#f6e8e0#46352d
--gr-accent-fg--gr-accent-fg#973f22#e6a37f5.75 / 5.48against --gr-accent
--gr-selected--gr-selectedvar(--gr-fg)var(--gr-fg)
--gr-selected-fg--gr-selected-fgvar(--gr-bg)var(--gr-bg)17.50 / 14.39against --gr-selected
--gr-selected-hover--gr-selected-hover#3d3d3a#d1cfc5

Status roles

TokenLightDarkContrast
--gr-success--gr-success#788c5d#8a9e6d
--gr-success-light--gr-success-light#e9ebe1#35382e
--gr-success-fg--gr-success-fg#141413#1414135.01 / 6.31against --gr-success
--gr-primary-text--gr-primary-text#973f22#e6a37f6.54 / 7.15against --gr-bg
--gr-success-text--gr-success-text#4f5e3b#b2c09a6.65 / 7.87against --gr-bg
--gr-warning--gr-warning#c9a82d#c9a82d
--gr-warning-light--gr-warning-light#f4eedb#433d26
--gr-warning-fg--gr-warning-fg#141413#1414138.01 / 8.01against --gr-warning
--gr-warning-text--gr-warning-text#6f5a14#dcc0676.33 / 8.50against --gr-bg
--gr-danger--gr-danger#b8433a#e3585a
--gr-danger-light--gr-danger-light#f1e1dd#482f2e
--gr-danger-fg--gr-danger-fg#faf9f5#1414135.11 / 5.10against --gr-danger
--gr-danger-text--gr-danger-text#9c2a34#f5a0977.13 / 7.48against --gr-bg
--gr-info--gr-info#2268bf#6aa3e8
--gr-info-light--gr-info-light#dfe8f1#323c47
--gr-info-fg--gr-info-fg#faf9f5#1414135.25 / 7.04against --gr-info
--gr-info-text--gr-info-text#1c57a0#a1c1ec6.83 / 8.20against --gr-bg
--gr-slate--gr-slate#4d4c48#9c9a92
--gr-slate-light--gr-slate-light#e4e3df#3b3b38
--gr-slate-fg--gr-slate-fg#faf9f5#1414138.16 / 6.54against --gr-slate
--gr-slate-text--gr-slate-text#4d4c48#c2c0b68.16 / 8.31against --gr-bg
--gr-azure--gr-azure#5b9fb6#5b9fb6
--gr-azure-light--gr-azure-light#e5eded#303c3e
--gr-azure-fg--gr-azure-fg#141413#1414136.21 / 6.21against --gr-azure
--gr-azure-text--gr-azure-text#2e6270#a3cbd86.44 / 8.73against --gr-bg

Solid fill roles

TokenLightDarkContrast
--gr-primary-solid--gr-primary-solidvar(--gr-primary)var(--gr-primary)
--gr-primary-solid-hover--gr-primary-solid-hovervar(--gr-primary-hover)var(--gr-primary-hover)
--gr-primary-solid-active--gr-primary-solid-activevar(--gr-primary-active)var(--gr-primary-active)
--gr-primary-solid-fg--gr-primary-solid-fgvar(--gr-primary-fg)var(--gr-primary-fg)5.90 / 5.90against --gr-primary-solid
--gr-success-solid--gr-success-solidvar(--gr-success)#8a9e6d
--gr-success-solid-hover--gr-success-solid-hovervar(--gr-success-hover)#97aa7a
--gr-success-solid-active--gr-success-solid-activevar(--gr-success-active)#a3b587
--gr-success-solid-fg--gr-success-solid-fgvar(--gr-success-fg)var(--gr-success-fg)5.01 / 6.31against --gr-success-solid
--gr-warning-solid--gr-warning-solidvar(--gr-warning)var(--gr-warning)
--gr-warning-solid-hover--gr-warning-solid-hovervar(--gr-warning-hover)var(--gr-warning-hover)
--gr-warning-solid-active--gr-warning-solid-activevar(--gr-warning-active)var(--gr-warning-active)
--gr-warning-solid-fg--gr-warning-solid-fgvar(--gr-warning-fg)var(--gr-warning-fg)8.01 / 8.01against --gr-warning-solid
--gr-danger-solid--gr-danger-solidvar(--gr-danger)#b8433a
--gr-danger-solid-hover--gr-danger-solid-hovervar(--gr-danger-hover)#a93c34
--gr-danger-solid-active--gr-danger-solid-activevar(--gr-danger-active)#99352e
--gr-danger-solid-fg--gr-danger-solid-fgvar(--gr-danger-fg)#faf9f55.11 / 5.11against --gr-danger-solid
--gr-info-solid--gr-info-solidvar(--gr-info)#2268bf
--gr-info-solid-hover--gr-info-solid-hovervar(--gr-info-hover)#1f5fae
--gr-info-solid-active--gr-info-solid-activevar(--gr-info-active)#1b559c
--gr-info-solid-fg--gr-info-solid-fgvar(--gr-info-fg)#faf9f55.25 / 5.25against --gr-info-solid
--gr-slate-solid--gr-slate-solidvar(--gr-slate)#5e5d59
--gr-slate-solid-hover--gr-slate-solid-hovervar(--gr-slate-hover)#575653
--gr-slate-solid-active--gr-slate-solid-activevar(--gr-slate-active)#53524e
--gr-slate-solid-fg--gr-slate-solid-fgvar(--gr-slate-fg)#faf9f58.16 / 6.26against --gr-slate-solid
--gr-azure-solid--gr-azure-solidvar(--gr-azure)var(--gr-azure)
--gr-azure-solid-hover--gr-azure-solid-hovervar(--gr-azure-hover)var(--gr-azure-hover)
--gr-azure-solid-active--gr-azure-solid-activevar(--gr-azure-active)var(--gr-azure-active)
--gr-azure-solid-fg--gr-azure-solid-fgvar(--gr-azure-fg)var(--gr-azure-fg)6.21 / 6.21against --gr-azure-solid

Data visualization roles

TokenLightDark
--gr-chart-1--gr-chart-1#c05b36#e0895f
--gr-chart-2--gr-chart-2#5f7a1c#9dbb6a
--gr-chart-3--gr-chart-3#2f68b8#6fa2e2
--gr-chart-4--gr-chart-4#a8407a#d684b4
--gr-chart-5--gr-chart-5#0d7d8c#4fb8ac

Elevation

TokenLightDark
--gr-shadow-1--gr-shadow-10 1px 2px rgba(28, 27, 24, 0.08)0 1px 2px rgba(0, 0, 0, 0.45)
--gr-shadow-2--gr-shadow-20 8px 24px rgba(28, 27, 24, 0.13)0 8px 24px rgba(0, 0, 0, 0.55)
--gr-shadow-3--gr-shadow-30 16px 48px rgba(28, 27, 24, 0.18)0 16px 48px rgba(0, 0, 0, 0.65)