Width is a shadcn/ui theme built around a light green primary color (#c2f2b0) with light violet accents (#e1b0f2). The light mode uses a neutral background (#fcfefb). Dark mode keeps the light green primary (#c2f2b0) on a neutral background (#000000).
| Token | Light | Dark |
|---|---|---|
| Background | #fcfefbwhite | #000000black |
| Foreground | #020501black | #ffffffwhite |
| Card | #f8fdf7mintcream | #030303black |
| Card foreground | #000000black | #ffffffwhite |
| Popover | #f8fdf7mintcream | #030303black |
| Popover foreground | #000000black | #ffffffwhite |
| Primary | #c2f2b0palegoldenrod | #c2f2b0palegoldenrod |
| Primary foreground | #030901black | #030901black |
| Secondary | #e1b0f2plum | #e1b0f2plum |
| Secondary foreground | #4b1060indigo | #4b1060indigo |
| Muted | #e8d8eelavender | #211127black |
| Muted foreground | #47394cdarkslategray | #c1b3c6silver |
| Accent | #e1b0f2plum | #e1b0f2plum |
| Accent foreground | #4b1060indigo | #4b1060indigo |
| Destructive | #bc1c10firebrick | #ed3d31crimson |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #c2f2b0palegoldenrod | #c2f2b0palegoldenrod |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.20:1 | AAA |
| Text on card | 20.41:1 | AAA |
| Primary button | 15.93:1 | AAA |
| Secondary button | 7.57:1 | AAA |
| Muted text | 7.90:1 | AAA |
| Accent | 7.57:1 | AAA |
| Destructive | 6.36:1 | AA |
| Text on background | 21.00:1 | AAA |
| Text on card | 20.67:1 | AAA |
| Primary button | 15.93:1 | AAA |
| Secondary button | 7.57:1 | AAA |
| Muted text | 8.96:1 | AAA |
| Accent | 7.57:1 | AAA |
| Destructive | 3.95:1 | AA Large |
Paste this into your globals.css to use Width in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.995 0.005 137.201);
--foreground: oklch(0.102 0.024 134.834);
--muted: oklch(0.901 0.035 317.101);
--muted-foreground: oklch(0.367 0.036 316.962);
--popover: oklch(0.989 0.01 137.213);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.989 0.01 137.213);
--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.911 0.101 137.495);
--primary-foreground: oklch(0.127 0.027 135.059);
--secondary: oklch(0.823 0.104 316.889);
--secondary-foreground: oklch(0.318 0.137 314.841);
--accent: oklch(0.823 0.104 316.889);
--accent-foreground: oklch(0.318 0.137 314.841);
--destructive: oklch(0.51 0.194 29.667);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.911 0.101 137.495);
--chart-1: oklch(0.911 0.101 137.495);
--chart-2: oklch(0.823 0.104 316.889);
--chart-3: oklch(0.823 0.104 316.889);
--chart-4: oklch(0.852 0.087 316.954);
--chart-5: oklch(0.914 0.105 137.51);
}
.dark {
--radius: 0.5rem;
--background: oklch(0 0 0);
--foreground: oklch(1 0 180);
--muted: oklch(0.211 0.048 316.552);
--muted-foreground: oklch(0.785 0.03 317.103);
--popover: oklch(0.092 0 180);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.092 0 180);
--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.911 0.101 137.495);
--primary-foreground: oklch(0.127 0.027 135.059);
--secondary: oklch(0.823 0.104 316.889);
--secondary-foreground: oklch(0.318 0.137 314.841);
--accent: oklch(0.823 0.104 316.889);
--accent-foreground: oklch(0.318 0.137 314.841);
--destructive: oklch(0.625 0.214 28.902);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.911 0.101 137.495);
--chart-1: oklch(0.911 0.101 137.495);
--chart-2: oklch(0.823 0.104 316.889);
--chart-3: oklch(0.823 0.104 316.889);
--chart-4: oklch(0.852 0.087 316.954);
--chart-5: oklch(0.914 0.105 137.51);
}