Chocolate is a shadcn/ui theme built around a muted deep yellow primary color (#0b0b09) with muted deep green accents (#0a0b09). The light mode uses a neutral background (#fefefb). Dark mode keeps the muted deep yellow primary (#0b0b09) on a neutral background (#030302).
| Token | Light | Dark |
|---|---|---|
| Background | #fefefbwhite | #030302black |
| Foreground | #040401black | #ffffffwhite |
| Card | #fefefbwhite | #030302black |
| Card foreground | #040401black | #ffffffwhite |
| Popover | #fefefbwhite | #030302black |
| Popover foreground | #040401black | #ffffffwhite |
| Primary | #0b0b09black | #0b0b09black |
| Primary foreground | #acab9adarkgray | #acab9adarkgray |
| Secondary | #0b0a09black | #0b0a09black |
| Secondary foreground | #aca29adarkgray | #aca29adarkgray |
| Muted | #ece2d9antiquewhite | #261b13black |
| Muted foreground | #4d4a47darkslategray | #b8b5b2silver |
| Accent | #0a0b09black | #0a0b09black |
| Accent foreground | #a4ac9adarkgray | #a4ac9adarkgray |
| Destructive | #be430efirebrick | #da4d10chocolate |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #0b0b09black | #0b0b09black |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.26:1 | AAA |
| Text on card | 20.26:1 | AAA |
| Primary button | 8.47:1 | AAA |
| Secondary button | 7.89:1 | AAA |
| Muted text | 6.90:1 | AA |
| Accent | 8.39:1 | AAA |
| Destructive | 5.26:1 | AA |
| Text on background | 20.60:1 | AAA |
| Text on card | 20.60:1 | AAA |
| Primary button | 8.47:1 | AAA |
| Secondary button | 7.89:1 | AAA |
| Muted text | 8.24:1 | AAA |
| Accent | 8.39:1 | AAA |
| Destructive | 4.15:1 | AA Large |
Paste this into your globals.css to use Chocolate in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.995 0.003 104.027);
--foreground: oklch(0.106 0.017 107.168);
--muted: oklch(0.919 0.016 61.957);
--muted-foreground: oklch(0.41 0.006 61.993);
--popover: oklch(0.995 0.003 104.027);
--popover-foreground: oklch(0.106 0.017 107.168);
--card: oklch(0.995 0.003 104.027);
--card-foreground: oklch(0.106 0.017 107.168);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.149 0.004 104.456);
--primary-foreground: oklch(0.739 0.024 104.524);
--secondary: oklch(0.146 0.003 62.649);
--secondary-foreground: oklch(0.719 0.017 61.882);
--accent: oklch(0.149 0.005 126.658);
--accent-foreground: oklch(0.734 0.027 126.916);
--destructive: oklch(0.549 0.168 39.308);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.149 0.004 104.456);
--chart-1: oklch(0.149 0.004 104.456);
--chart-2: oklch(0.146 0.003 62.649);
--chart-3: oklch(0.149 0.005 126.658);
--chart-4: oklch(0.182 0.005 61.857);
--chart-5: oklch(0.151 0.005 104.597);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.098 0.008 105.618);
--foreground: oklch(1 0 180);
--muted: oklch(0.233 0.023 60.631);
--muted-foreground: oklch(0.774 0.005 62.103);
--popover: oklch(0.098 0.008 105.618);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.098 0.008 105.618);
--card-foreground: oklch(1 0 180);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.149 0.004 104.456);
--primary-foreground: oklch(0.739 0.024 104.524);
--secondary: oklch(0.146 0.003 62.649);
--secondary-foreground: oklch(0.719 0.017 61.882);
--accent: oklch(0.149 0.005 126.658);
--accent-foreground: oklch(0.734 0.027 126.916);
--destructive: oklch(0.608 0.187 39.102);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.149 0.004 104.456);
--chart-1: oklch(0.149 0.004 104.456);
--chart-2: oklch(0.146 0.003 62.649);
--chart-3: oklch(0.149 0.005 126.658);
--chart-4: oklch(0.182 0.005 61.857);
--chart-5: oklch(0.151 0.005 104.597);
}