Attenuation is a shadcn/ui theme built around a muted light green primary color (#d9ddc5) with muted light indigo accents (#c9c5dd). The light mode uses a neutral background (#fdfefb). Dark mode keeps the muted light green primary (#d9ddc5) on a green-tinted background (#0d0e06).
| Token | Light | Dark |
|---|---|---|
| Background | #fdfefbwhite | #0d0e06black |
| Foreground | #0f1202black | #fdfdfcwhite |
| Card | #fbfcf7snow | #101208black |
| Card foreground | #0b0e02black | #ffffffwhite |
| Popover | #fbfcf7snow | #101208black |
| Popover foreground | #0b0e02black | #ffffffwhite |
| Primary | #d9ddc5lightgrey | #d9ddc5lightgrey |
| Primary foreground | #424729darkolivegreen | #424729darkolivegreen |
| Secondary | #c9c5ddthistle | #c9c5ddthistle |
| Secondary foreground | #2f2947darkslategray | #2f2947darkslategray |
| Muted | #d2cde9gainsboro | #1b1632black |
| Muted foreground | #58575cdimgray | #a4a3a8darkgray |
| Accent | #c9c5ddthistle | #c9c5ddthistle |
| Accent foreground | #2f2947darkslategray | #2f2947darkslategray |
| Destructive | #942d05saddlebrown | #f85616orangered |
| Destructive foreground | #fddbcebisque | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #d9ddc5lightgrey | #d9ddc5lightgrey |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 18.70:1 | AAA |
| Text on card | 18.96:1 | AAA |
| Primary button | 6.99:1 | AA |
| Secondary button | 8.17:1 | AAA |
| Muted text | 4.67:1 | AA |
| Accent | 8.17:1 | AAA |
| Destructive | 6.11:1 | AA |
| Text on background | 19.04:1 | AAA |
| Text on card | 18.91:1 | AAA |
| Primary button | 6.99:1 | AA |
| Secondary button | 8.17:1 | AAA |
| Muted text | 6.95:1 | AA |
| Accent | 8.17:1 | AAA |
| Destructive | 3.31:1 | AA Large |
Paste this into your globals.css to use Attenuation in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.995 0.003 114.885);
--foreground: oklch(0.174 0.034 117.355);
--muted: oklch(0.862 0.039 293.986);
--muted-foreground: oklch(0.458 0.009 294.472);
--popover: oklch(0.99 0.007 114.947);
--popover-foreground: oklch(0.155 0.029 116.445);
--card: oklch(0.99 0.007 114.947);
--card-foreground: oklch(0.155 0.029 116.445);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.889 0.034 115.52);
--primary-foreground: oklch(0.385 0.048 117.196);
--secondary: oklch(0.834 0.035 294.047);
--secondary-foreground: oklch(0.302 0.054 291.219);
--accent: oklch(0.834 0.035 294.047);
--accent-foreground: oklch(0.302 0.054 291.219);
--destructive: oklch(0.451 0.145 37.811);
--destructive-foreground: oklch(0.917 0.043 42.782);
--ring: oklch(0.889 0.034 115.52);
--chart-1: oklch(0.889 0.034 115.52);
--chart-2: oklch(0.834 0.035 294.047);
--chart-3: oklch(0.834 0.035 294.047);
--chart-4: oklch(0.862 0.029 294.205);
--chart-5: oklch(0.892 0.037 115.593);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.16 0.017 116.302);
--foreground: oklch(0.993 0.001 114.837);
--muted: oklch(0.222 0.053 289.789);
--muted-foreground: oklch(0.718 0.008 294.624);
--popover: oklch(0.175 0.02 116.809);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.175 0.02 116.809);
--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.889 0.034 115.52);
--primary-foreground: oklch(0.385 0.048 117.196);
--secondary: oklch(0.834 0.035 294.047);
--secondary-foreground: oklch(0.302 0.054 291.219);
--accent: oklch(0.834 0.035 294.047);
--accent-foreground: oklch(0.302 0.054 291.219);
--destructive: oklch(0.666 0.208 38.288);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.889 0.034 115.52);
--chart-1: oklch(0.889 0.034 115.52);
--chart-2: oklch(0.834 0.035 294.047);
--chart-3: oklch(0.834 0.035 294.047);
--chart-4: oklch(0.862 0.029 294.205);
--chart-5: oklch(0.892 0.037 115.593);
}