Centimeter is a shadcn/ui theme built around a vivid yellow primary color (#edf25a) with neutral gray accents (#cfd0ce). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid yellow primary (#edf25a) on a neutral background (#000000).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #000000black |
| Foreground | #040401black | #f8f8f6whitesmoke |
| Card | #ffffffwhite | #000000black |
| Card foreground | #040401black | #f8f8f6whitesmoke |
| Popover | #ffffffwhite | #000000black |
| Popover foreground | #040401black | #f8f8f6whitesmoke |
| Primary | #edf25akhaki | #edf25akhaki |
| Primary foreground | #171802black | #171802black |
| Secondary | #cfd0celightgrey | #2f2f27darkslategray |
| Secondary foreground | #373734darkslategray | #c9cabfsilver |
| Muted | #f0f0ealinen | #14150fblack |
| Muted foreground | #5c5d51dimgray | #aeaea2darkgray |
| Accent | #cfd0celightgrey | #2f2f27darkslategray |
| Accent foreground | #373734darkslategray | #c9cabfsilver |
| Destructive | #682b08saddlebrown | #ec6618chocolate |
| Destructive foreground | #f8c7aanavajowhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #edf25akhaki | #edf25akhaki |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.52:1 | AAA |
| Text on card | 20.52:1 | AAA |
| Primary button | 14.88:1 | AAA |
| Secondary button | 7.69:1 | AAA |
| Muted text | 5.83:1 | AA |
| Accent | 7.69:1 | AAA |
| Destructive | 7.07:1 | AAA |
| Text on background | 19.74:1 | AAA |
| Text on card | 19.74:1 | AAA |
| Primary button | 14.88:1 | AAA |
| Secondary button | 8.12:1 | AAA |
| Muted text | 8.21:1 | AAA |
| Accent | 8.12:1 | AAA |
| Destructive | 6.47:1 | AA |
Paste this into your globals.css to use Centimeter in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.104 0.015 109.945);
--muted: oklch(0.953 0.007 108.077);
--muted-foreground: oklch(0.473 0.019 108.662);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.104 0.015 109.945);
--card: oklch(1 0 180);
--card-foreground: oklch(0.104 0.015 109.945);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.929 0.17 111.116);
--primary-foreground: oklch(0.2 0.04 111.139);
--secondary: oklch(0.856 0.003 107.996);
--secondary-foreground: oklch(0.334 0.004 108.142);
--accent: oklch(0.856 0.003 107.996);
--accent-foreground: oklch(0.334 0.004 108.142);
--destructive: oklch(0.37 0.097 45.648);
--destructive-foreground: oklch(0.865 0.068 51.573);
--ring: oklch(0.929 0.17 111.116);
--chart-1: oklch(0.929 0.17 111.116);
--chart-2: oklch(0.856 0.003 107.996);
--chart-3: oklch(0.856 0.003 107.996);
--chart-4: oklch(0.879 0.002 107.986);
--chart-5: oklch(0.936 0.174 111.173);
}
.dark {
--radius: 0.5rem;
--background: oklch(0 0 0);
--foreground: oklch(0.98 0.003 107.989);
--muted: oklch(0.191 0.01 108.914);
--muted-foreground: oklch(0.748 0.017 108.354);
--popover: oklch(0 0 0);
--popover-foreground: oklch(0.98 0.003 107.989);
--card: oklch(0 0 0);
--card-foreground: oklch(0.98 0.003 107.989);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.929 0.17 111.116);
--primary-foreground: oklch(0.2 0.04 111.139);
--secondary: oklch(0.303 0.014 108.746);
--secondary-foreground: oklch(0.835 0.014 108.255);
--accent: oklch(0.303 0.014 108.746);
--accent-foreground: oklch(0.835 0.014 108.255);
--destructive: oklch(0.668 0.184 44.46);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.929 0.17 111.116);
--chart-1: oklch(0.929 0.17 111.116);
--chart-2: oklch(0.303 0.014 108.746);
--chart-3: oklch(0.303 0.014 108.746);
--chart-4: oklch(0.336 0.016 108.774);
--chart-5: oklch(0.936 0.174 111.173);
}