Charter is a shadcn/ui theme built around a muted light orange primary color (#dcd0cb) with muted light cyan accents (#cbd7dc). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted light orange primary (#dcd0cb) on a neutral background (#080402).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #080402black |
| Foreground | #040201black | #fbf9f9snow |
| Card | #fcfcfcsnow | #0c0603black |
| Card foreground | #000000black | #fdfcfcsnow |
| Popover | #ffffffwhite | #080402black |
| Popover foreground | #040201black | #fbf9f9snow |
| Primary | #dcd0cblightgrey | #dcd0cblightgrey |
| Primary foreground | #463630darkslategray | #463630darkslategray |
| Secondary | #cbd7dclightgrey | #cbd7dclightgrey |
| Secondary foreground | #303f46darkslategray | #303f46darkslategray |
| Muted | #e8ecedlavender | #121617black |
| Muted foreground | #3f4f55darkslategray | #aabac0silver |
| Accent | #cbd7dclightgrey | #cbd7dclightgrey |
| Accent foreground | #303f46darkslategray | #303f46darkslategray |
| Destructive | #7a210bmaroon | #ec4b22orangered |
| Destructive foreground | #f9c9bdpink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #dcd0cblightgrey | #dcd0cblightgrey |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.70:1 | AAA |
| Text on card | 20.54:1 | AAA |
| Primary button | 7.61:1 | AAA |
| Secondary button | 7.44:1 | AAA |
| Muted text | 7.16:1 | AAA |
| Accent | 7.44:1 | AAA |
| Destructive | 6.89:1 | AA |
| Text on background | 19.47:1 | AAA |
| Text on card | 19.67:1 | AAA |
| Primary button | 7.61:1 | AAA |
| Secondary button | 7.44:1 | AAA |
| Muted text | 9.12:1 | AAA |
| Accent | 7.44:1 | AAA |
| Destructive | 3.76:1 | AA Large |
Paste this into your globals.css to use Charter in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.09 0.01 50.589);
--muted: oklch(0.94 0.005 223.183);
--muted-foreground: oklch(0.415 0.023 223.859);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.09 0.01 50.589);
--card: oklch(0.992 0 161.565);
--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.866 0.015 42.983);
--primary-foreground: oklch(0.348 0.025 42.64);
--secondary: oklch(0.872 0.014 223.305);
--secondary-foreground: oklch(0.358 0.023 224.067);
--accent: oklch(0.872 0.014 223.305);
--accent-foreground: oklch(0.358 0.023 224.067);
--destructive: oklch(0.389 0.127 34.487);
--destructive-foreground: oklch(0.876 0.057 34.379);
--ring: oklch(0.866 0.015 42.983);
--chart-1: oklch(0.866 0.015 42.983);
--chart-2: oklch(0.872 0.014 223.305);
--chart-3: oklch(0.872 0.014 223.305);
--chart-4: oklch(0.895 0.012 223.267);
--chart-5: oklch(0.866 0.017 42.962);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.113 0.013 50.761);
--foreground: oklch(0.984 0.002 43.111);
--muted: oklch(0.195 0.007 223.568);
--muted-foreground: oklch(0.778 0.02 223.414);
--popover: oklch(0.113 0.013 50.761);
--popover-foreground: oklch(0.984 0.002 43.111);
--card: oklch(0.129 0.015 50.422);
--card-foreground: oklch(0.992 0.001 43.121);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.866 0.015 42.983);
--primary-foreground: oklch(0.348 0.025 42.64);
--secondary: oklch(0.872 0.014 223.305);
--secondary-foreground: oklch(0.358 0.023 224.067);
--accent: oklch(0.872 0.014 223.305);
--accent-foreground: oklch(0.358 0.023 224.067);
--destructive: oklch(0.635 0.204 34.613);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.866 0.015 42.983);
--chart-1: oklch(0.866 0.015 42.983);
--chart-2: oklch(0.872 0.014 223.305);
--chart-3: oklch(0.872 0.014 223.305);
--chart-4: oklch(0.895 0.012 223.267);
--chart-5: oklch(0.866 0.017 42.962);
}