Legislature is a shadcn/ui theme built around a light purple primary color (#dfb3e0) with neutral gray accents (#d4cece). The light mode uses a neutral background (#ffffff). Dark mode keeps the light purple primary (#dfb3e0) on a purple-tinted background (#0b050b).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #0b050bblack |
| Foreground | #0c030cblack | #faf9fbghostwhite |
| Card | #fcfcfcsnow | #0e060eblack |
| Card foreground | #080208black | #fdfcfdwhite |
| Popover | #ffffffwhite | #0b050bblack |
| Popover foreground | #0c030cblack | #faf9fbghostwhite |
| Primary | #dfb3e0thistle | #dfb3e0thistle |
| Primary foreground | #441c45darkslategray | #441c45darkslategray |
| Secondary | #dededegainsboro | #161216black |
| Secondary foreground | #454545darkslategray | #b5a5b6darkgray |
| Muted | #e6e0e0gainsboro | #1f191fblack |
| Muted foreground | #675b5bdimgray | #a498a4darkgray |
| Accent | #d4cecelightgrey | #332433darkslategray |
| Accent foreground | #3c3434darkslategray | #cfbacfthistle |
| Destructive | #af1e0efirebrick | #ed3621orangered |
| Destructive foreground | #fef2f1seashell | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #dfb3e0thistle | #dfb3e0thistle |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.31:1 | AAA |
| Text on card | 20.09:1 | AAA |
| Primary button | 7.78:1 | AAA |
| Secondary button | 7.11:1 | AAA |
| Muted text | 4.99:1 | AA |
| Accent | 7.79:1 | AAA |
| Destructive | 6.38:1 | AA |
| Text on background | 19.26:1 | AAA |
| Text on card | 19.50:1 | AAA |
| Primary button | 7.78:1 | AAA |
| Secondary button | 7.94:1 | AAA |
| Muted text | 6.24:1 | AA |
| Accent | 8.06:1 | AAA |
| Destructive | 4.08:1 | AA Large |
Paste this into your globals.css to use Legislature in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.124 0.03 326.689);
--muted: oklch(0.912 0.006 17.269);
--muted-foreground: oklch(0.483 0.015 17.688);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.124 0.03 326.689);
--card: oklch(0.992 0 161.565);
--card-foreground: oklch(0.108 0.026 326.724);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.82 0.079 325.737);
--primary-foreground: oklch(0.303 0.086 326.808);
--secondary: oklch(0.9 0 188.746);
--secondary-foreground: oklch(0.39 0 165.964);
--accent: oklch(0.856 0.007 17.296);
--accent-foreground: oklch(0.334 0.011 17.727);
--destructive: oklch(0.486 0.181 30.519);
--destructive-foreground: oklch(0.97 0.013 25.101);
--ring: oklch(0.82 0.079 325.737);
--chart-1: oklch(0.82 0.079 325.737);
--chart-2: oklch(0.9 0 188.746);
--chart-3: oklch(0.856 0.007 17.296);
--chart-4: oklch(0.923 0 153.435);
--chart-5: oklch(0.819 0.084 325.78);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.127 0.02 326.227);
--foreground: oklch(0.984 0.002 325.115);
--muted: oklch(0.223 0.014 325.512);
--muted-foreground: oklch(0.694 0.021 325.311);
--popover: oklch(0.127 0.02 326.227);
--popover-foreground: oklch(0.984 0.002 325.115);
--card: oklch(0.14 0.023 326.206);
--card-foreground: oklch(0.992 0.001 325.108);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.82 0.079 325.737);
--primary-foreground: oklch(0.303 0.086 326.808);
--secondary: oklch(0.191 0.01 325.467);
--secondary-foreground: oklch(0.741 0.029 325.371);
--accent: oklch(0.283 0.035 325.918);
--accent-foreground: oklch(0.812 0.037 325.412);
--destructive: oklch(0.618 0.221 30.469);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.82 0.079 325.737);
--chart-1: oklch(0.82 0.079 325.737);
--chart-2: oklch(0.191 0.01 325.467);
--chart-3: oklch(0.283 0.035 325.918);
--chart-4: oklch(0.223 0.014 325.512);
--chart-5: oklch(0.819 0.084 325.78);
}