Attenuation is a shadcn/ui theme built around a light violet primary color (#d3c9ee) with light purple accents (#e5c9ee). The light mode uses a neutral background (#ffffff). Dark mode keeps the light violet primary (#d3c9ee) on a neutral background (#040307).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #040307black |
| Foreground | #000000black | #fcfcfdwhite |
| Card | #fcfcfcsnow | #06050bblack |
| Card foreground | #000000black | #ffffffwhite |
| Popover | #ffffffwhite | #040307black |
| Popover foreground | #000000black | #fcfcfdwhite |
| Primary | #d3c9eethistle | #d3c9eethistle |
| Primary foreground | #332064midnightblue | #332064midnightblue |
| Secondary | #c9d2eegainsboro | #c9d2eegainsboro |
| Secondary foreground | #203064midnightblue | #203064midnightblue |
| Muted | #d2d6e5gainsboro | #1a1f2dblack |
| Muted foreground | #4a4c55darkslategray | #aaadb5darkgray |
| Accent | #e5c9eethistle | #e5c9eethistle |
| Accent foreground | #542064indigo | #542064indigo |
| Destructive | #872803saddlebrown | #fa5514orangered |
| Destructive foreground | #fed0bepeachpuff | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #d3c9eethistle | #d3c9eethistle |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 21.00:1 | AAA |
| Text on card | 20.54:1 | AAA |
| Primary button | 8.72:1 | AAA |
| Secondary button | 8.32:1 | AAA |
| Muted text | 5.90:1 | AA |
| Accent | 7.87:1 | AAA |
| Destructive | 6.41:1 | AA |
| Text on background | 20.04:1 | AAA |
| Text on card | 20.33:1 | AAA |
| Primary button | 8.72:1 | AAA |
| Secondary button | 8.32:1 | AAA |
| Muted text | 7.34:1 | AAA |
| Accent | 7.87:1 | AAA |
| Destructive | 3.28:1 | AA Large |
Paste this into your globals.css to use Attenuation in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0 0 0);
--muted: oklch(0.878 0.021 272.398);
--muted-foreground: oklch(0.418 0.014 272.269);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0 0 0);
--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.856 0.051 297.517);
--primary-foreground: oklch(0.311 0.113 290.538);
--secondary: oklch(0.865 0.04 272.127);
--secondary-foreground: oklch(0.327 0.094 268.178);
--accent: oklch(0.871 0.058 318.263);
--accent-foreground: oklch(0.354 0.122 317.483);
--destructive: oklch(0.421 0.136 37.934);
--destructive-foreground: oklch(0.892 0.057 42.684);
--ring: oklch(0.856 0.051 297.517);
--chart-1: oklch(0.856 0.051 297.517);
--chart-2: oklch(0.865 0.04 272.127);
--chart-3: oklch(0.871 0.058 318.263);
--chart-4: oklch(0.894 0.031 272.269);
--chart-5: oklch(0.853 0.054 297.45);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.104 0.015 298.475);
--foreground: oklch(0.991 0.002 298.539);
--muted: oklch(0.24 0.029 271.036);
--muted-foreground: oklch(0.748 0.012 272.479);
--popover: oklch(0.104 0.015 298.475);
--popover-foreground: oklch(0.991 0.002 298.539);
--card: oklch(0.119 0.017 298.449);
--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.856 0.051 297.517);
--primary-foreground: oklch(0.311 0.113 290.538);
--secondary: oklch(0.865 0.04 272.127);
--secondary-foreground: oklch(0.327 0.094 268.178);
--accent: oklch(0.871 0.058 318.263);
--accent-foreground: oklch(0.354 0.122 317.483);
--destructive: oklch(0.669 0.211 38.035);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.856 0.051 297.517);
--chart-1: oklch(0.856 0.051 297.517);
--chart-2: oklch(0.865 0.04 272.127);
--chart-3: oklch(0.871 0.058 318.263);
--chart-4: oklch(0.894 0.031 272.269);
--chart-5: oklch(0.853 0.054 297.45);
}