Candy is a shadcn/ui theme built around a muted purple primary color (#b681ab) with muted purple accents (#cda7c5). The light mode uses a neutral background (#fefbfd). Dark mode keeps the muted purple primary (#b681ab) on a purple-tinted background (#0b040a).
| Token | Light | Dark |
|---|---|---|
| Background | #fefbfdsnow | #0b040ablack |
| Foreground | #12020fblack | #f8f7f8whitesmoke |
| Card | #fdf7fcsnow | #0f060dblack |
| Card foreground | #0e020bblack | #faf9fasnow |
| Popover | #fefbfdsnow | #0b040ablack |
| Popover foreground | #12020fblack | #f8f7f8whitesmoke |
| Primary | #b681abrosybrown | #b681abrosybrown |
| Primary foreground | #030203black | #030203black |
| Secondary | #dac8d6thistle | #242424darkslategray |
| Secondary foreground | #432d3edarkslategray | #bdbdbdsilver |
| Muted | #ead7e6gainsboro | #281515black |
| Muted foreground | #6c5a69dimgray | #a59393rosybrown |
| Accent | #cda7c5silver | #3d3333darkslategray |
| Accent foreground | #2a1826black | #d5cdcdlightgrey |
| Destructive | #a83e05saddlebrown | #ed5807orangered |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #b681abrosybrown | #b681abrosybrown |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.61:1 | AAA |
| Text on card | 19.23:1 | AAA |
| Primary button | 6.61:1 | AA |
| Secondary button | 7.85:1 | AAA |
| Muted text | 4.65:1 | AA |
| Accent | 7.90:1 | AAA |
| Destructive | 6.23:1 | AA |
| Text on background | 18.95:1 | AAA |
| Text on card | 19.04:1 | AAA |
| Primary button | 6.61:1 | AA |
| Secondary button | 8.29:1 | AAA |
| Muted text | 5.94:1 | AA |
| Accent | 7.80:1 | AAA |
| Destructive | 3.49:1 | AA Large |
Paste this into your globals.css to use Candy in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.991 0.005 332.69);
--foreground: oklch(0.134 0.043 335.505);
--muted: oklch(0.899 0.028 333.088);
--muted-foreground: oklch(0.492 0.031 333.576);
--popover: oklch(0.991 0.005 332.69);
--popover-foreground: oklch(0.134 0.043 335.505);
--card: oklch(0.982 0.009 332.764);
--card-foreground: oklch(0.12 0.038 334.511);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.669 0.087 334.509);
--primary-foreground: oklch(0.089 0.008 333.018);
--secondary: oklch(0.852 0.028 333.12);
--secondary-foreground: oklch(0.33 0.043 334.528);
--accent: oklch(0.772 0.061 333.783);
--accent-foreground: oklch(0.239 0.039 334.944);
--destructive: oklch(0.507 0.151 41.764);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.669 0.087 334.509);
--chart-1: oklch(0.669 0.087 334.509);
--chart-2: oklch(0.852 0.028 333.12);
--chart-3: oklch(0.772 0.061 333.783);
--chart-4: oklch(0.877 0.023 333.023);
--chart-5: oklch(0.668 0.097 334.71);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.125 0.021 333.416);
--foreground: oklch(0.976 0.002 332.653);
--muted: oklch(0.223 0.03 19.73);
--muted-foreground: oklch(0.678 0.021 17.692);
--popover: oklch(0.125 0.021 333.416);
--popover-foreground: oklch(0.976 0.002 332.653);
--card: oklch(0.139 0.024 334.388);
--card-foreground: oklch(0.984 0.002 332.64);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.669 0.087 334.509);
--primary-foreground: oklch(0.089 0.008 333.018);
--secondary: oklch(0.259 0 167.471);
--secondary-foreground: oklch(0.797 0 180);
--accent: oklch(0.332 0.015 17.907);
--accent-foreground: oklch(0.855 0.009 17.336);
--destructive: oklch(0.651 0.198 40.963);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.669 0.087 334.509);
--chart-1: oklch(0.669 0.087 334.509);
--chart-2: oklch(0.259 0 167.471);
--chart-3: oklch(0.332 0.015 17.907);
--chart-4: oklch(0.29 0 180);
--chart-5: oklch(0.668 0.097 334.71);
}