Skip to main content
⌘K

Search

Search pages, pieces and blocks.

Colour

One warm grey scale, 50 to 990, and roles that point into it. Colour only ever means something: red is danger, green, amber and blue are status, cobalt says look here.

Scale
23 steps
Roles
38
Night ceiling
300 #e2e2e1

In a real piece

A booking card, as shipped. Hover a role to find it in the card.

15 roles, 1 accent, 3 status inks. Everything else is grey.

  • background#ffffff
  • card#ffffff
  • foreground#353535
  • muted-foreground#696968
  • primary#353535
  • primary-foreground#ffffff
  • secondary#efefee
  • muted#f8f8f7
  • selected#efefee
  • border#eaeae9
  • input#eaeae9
  • success-ink#00732b
  • warning-ink#904900
  • destructive-ink#bc0000
  • cobalt#2867f2
Ericeira, Saturday lessons
Sat 5 December, 2 students
New
Beginner, 9:00Confirmed€45.00
Improver, 11:00Pending€45.00
Private, 15:00Cancelled€90.00

Scale

The same 23 steps in Day and Night. A dot marks a step a role points to in the current mode. Click to copy.

Roles point into the scale. Hover a step to see which roles use it, in Day and in Night.

Roles

Use the role, never the step. Day and Night values are computed from globals.css; uses are class and var() references in src/components and src/app.

TokenJobDayNightUses
Surfaces
--backgroundThe page, and text on a dark fill#ffffff#1f1f1e82
--cardCards, the same as the page#ffffff#1f1f1e8
--popoverMenus, selects, tooltips: paper#ffffff#2b2b2b43
--sheetThe app panel inside App Shell#ffffff#1f1f1e5
--sidebarSidebars, set apart by a border only#ffffff#1f1f1e7
Text
--foregroundBody text, titles, icons#353535#e2e2e1173
--muted-foregroundHints, descriptions, secondary data#696968#adadac339
--primary-foregroundText on Primary#ffffff#1f1f1e24
Fills
--primaryThe one strong button per view#353535#e2e2e154
--secondarySecondary buttons, quiet badges#efefee#3535359
--mutedHover, tab lists, read-only fields#f8f8f7#2b2b2b99
--selectedSelected and pressed, a step above hover#efefee#35353535
--popover-accentHover inside a menu#f5f5f4#35353517
--popover-selectedChosen row inside a menu#efefee#40403f9
--trackEmpty part of Progress and Slider, Skeleton#efefee#35353515
--rangeFilled part of the Slider#353535#bebebd2
Edges and focus
--borderDividers, card and table edges#eaeae9#35353591
--inputField edges#eaeae9#35353554
--control-edgeQuiet edges on controls#cccccb#40403f13
--mark-edgeCheckbox, Radio, off Switch: 3:1#808080#7475745
--popover-borderThe paper edge#e2e2e1#40403f20
--ringKeyboard outline#353535#e2e2e157
--field-focusA focused field's edge#8e8e8d#7475743
--haloThe soft ring outside a focused fieldrgb(53 53 53 / 9%)rgb(226 226 225 / 9%)2
Status
--destructiveDanger: tints, edges, invalid rings#e7000b#ff6467146
--destructive-inkRed text on a red tint#bc0000#ff8a8a18
--successSuccess: dots, tints#06853c#67b4799
--success-inkGreen text on a green tint#00732b#7fcc903
--warningWarning: dots, tints#a35b00#cd924821
--warning-inkAmber text on an amber tint#904900#e6aa614
--infoInfo: dots, tints, text#0f71c0#65a4e46
--cobaltLook here, nothing is wrong: today, New#2867f2#6c9cfb11
Charts and overlay
--chart-1Series 1, lightest#8e8e8d#e2e2e17
--chart-2Series 2#747574#cccccb8
--chart-3Series 3#5e5e5d#adadac9
--chart-4Series 4#494948#8e8e8d6
--chart-5Series 5, strongest#353535#7475743
--scrimDims the page behind Dialog and Sheetrgb(25 25 24 / 10%)rgb(25 25 24 / 10%)6

Contrast

Computed from the shipped values for the pairs António actually puts together. Text needs 4.5:1, edges that carry meaning need 3:1.

PairTokensDayNightLevel
Body textforeground on background12.2612.72AAA
Hint on the pagemuted-foreground on background5.497.34AA
Hint on a hover fillmuted-foreground on muted5.176.30AA
Primary buttonprimary-foreground on primary12.2612.72AAA
Secondary buttonforeground on secondary10.669.46AAA
Menu rowforeground on popover12.2610.92AAA
Error messagedestructive-ink on background6.697.26AA
New tag, todaycobalt on background4.866.11AA
Info textinfo on background5.066.27AA
Checkbox edgemark-edge on background3.943.563:1 for edges
Focused field edgefield-focus on background3.273.563:1 for edges
Keyboard outlinering on background12.2612.723:1 for edges
Dividerborder on background1.201.34Decorative
Destructive badgedestructive-ink on destructive 10%5.626.35AA
Success badgesuccess-ink on success 10%5.277.28AA
Warning badgewarning-ink on warning 10%5.866.88AA

Do and don't

Colour is a signal. Spend it on the one thing that needs it.

Payment failed
Your card was declined. Nothing was charged.
DeclinedCard ending 4242
DoGrey does the layout. Red appears once, as ink on a tint, where the problem is.
Payment failed
Your card was declined. Nothing was charged.
DeclinedCard ending 4242
Don'tRed title, blue text, solid status fills and a cobalt button: four signals, none of them wins, and white on cobalt is not a role.

Rules

  1. 1Use the role token, never a scale step or a hex. Roles are what change in Night.
  2. 2One Primary per view. Everything else is Secondary, Ghost or Outline.
  3. 3Status text uses its -ink token on a 10 percent tint of its colour. Solid status fills are not part of the system.
  4. 4Cobalt is never a button and never an error. It marks today and new things, nothing else.