Cheery is a shadcn/ui theme built around a green primary color (#8cb351) with violet accents (#7851b3). The light mode uses a neutral background (#fbfdf7). Dark mode keeps the green primary (#8cb351) on a neutral background (#060802).
| Token | Light | Dark |
|---|---|---|
| Background | #fbfdf7snow | #060802black |
| Foreground | #000000black | #f8f8f6whitesmoke |
| Card | #f8fcf2floralwhite | #080c04black |
| Card foreground | #000000black | #fafbf9snow |
| Popover | #fbfdf7snow | #060802black |
| Popover foreground | #000000black | #f8f8f6whitesmoke |
| Primary | #8cb351yellowgreen | #8cb351yellowgreen |
| Primary foreground | #1e2711black | #1e2711black |
| Secondary | #7851b3slateblue | #7851b3slateblue |
| Secondary foreground | #ffffffwhite | #ffffffwhite |
| Muted | #d6cbe7thistle | #231834midnightblue |
| Muted foreground | #50485bdarkslategray | #aba4b7darkgray |
| Accent | #7851b3slateblue | #7851b3slateblue |
| Accent foreground | #ffffffwhite | #ffffffwhite |
| Destructive | #7c1a09maroon | #f04628orangered |
| Destructive foreground | #fac6bcpink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #8cb351yellowgreen | #8cb351yellowgreen |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.50:1 | AAA |
| Text on card | 20.26:1 | AAA |
| Primary button | 6.39:1 | AA |
| Secondary button | 5.77:1 | AA |
| Muted text | 5.60:1 | AA |
| Accent | 5.77:1 | AA |
| Destructive | 6.90:1 | AA |
| Text on background | 18.94:1 | AAA |
| Text on card | 19.01:1 | AAA |
| Primary button | 6.39:1 | AA |
| Secondary button | 5.77:1 | AA |
| Muted text | 6.93:1 | AA |
| Accent | 5.77:1 | AA |
| Destructive | 3.73:1 | AA Large |
Paste this into your globals.css to use Cheery in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.991 0.009 124.479);
--foreground: oklch(0 0 0);
--muted: oklch(0.859 0.039 303.688);
--muted-foreground: oklch(0.416 0.034 303.186);
--popover: oklch(0.991 0.009 124.479);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.986 0.014 124.548);
--card-foreground: oklch(0 0 0);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.716 0.134 127.571);
--primary-foreground: oklch(0.258 0.04 126.858);
--secondary: oklch(0.525 0.15 299.689);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.525 0.15 299.689);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.385 0.135 32.213);
--destructive-foreground: oklch(0.869 0.062 29.893);
--ring: oklch(0.716 0.134 127.571);
--chart-1: oklch(0.716 0.134 127.571);
--chart-2: oklch(0.525 0.15 299.689);
--chart-3: oklch(0.525 0.15 299.689);
--chart-4: oklch(0.554 0.141 300.332);
--chart-5: oklch(0.725 0.142 127.808);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.127 0.018 123.669);
--foreground: oklch(0.979 0.003 124.385);
--muted: oklch(0.24 0.053 300.957);
--muted-foreground: oklch(0.73 0.029 303.773);
--popover: oklch(0.127 0.018 123.669);
--popover-foreground: oklch(0.979 0.003 124.385);
--card: oklch(0.146 0.021 123.903);
--card-foreground: oklch(0.986 0.002 124.371);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.716 0.134 127.571);
--primary-foreground: oklch(0.258 0.04 126.858);
--secondary: oklch(0.525 0.15 299.689);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.525 0.15 299.689);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.638 0.211 32.368);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.716 0.134 127.571);
--chart-1: oklch(0.716 0.134 127.571);
--chart-2: oklch(0.525 0.15 299.689);
--chart-3: oklch(0.525 0.15 299.689);
--chart-4: oklch(0.554 0.141 300.332);
--chart-5: oklch(0.725 0.142 127.808);
}