Colorful is a shadcn/ui theme built around a muted indigo primary color (#8c80b7) with muted green accents (#abb780). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted indigo primary (#8c80b7) on a neutral background (#020204).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #020204black |
| Foreground | #060212black | #fcfcfdwhite |
| Card | #fcfcfcsnow | #040307black |
| Card foreground | #04020eblack | #ffffffwhite |
| Popover | #ffffffwhite | #020204black |
| Popover foreground | #060212black | #fcfcfdwhite |
| Primary | #8c80b7lightslategray | #8c80b7lightslategray |
| Primary foreground | #000000black | #000000black |
| Secondary | #abb780darkkhaki | #abb780darkkhaki |
| Secondary foreground | #030302black | #030302black |
| Muted | #e2e4ddgainsboro | #21221bblack |
| Muted foreground | #505440darkolivegreen | #bbbfabsilver |
| Accent | #abb780darkkhaki | #abb780darkkhaki |
| Accent foreground | #030302black | #030302black |
| Destructive | #7e2f01saddlebrown | #e85702orangered |
| Destructive foreground | #fecfb3peachpuff | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #8c80b7lightslategray | #8c80b7lightslategray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.48:1 | AAA |
| Text on card | 20.14:1 | AAA |
| Primary button | 5.87:1 | AA |
| Secondary button | 9.68:1 | AAA |
| Muted text | 6.09:1 | AA |
| Accent | 9.68:1 | AAA |
| Destructive | 6.43:1 | AA |
| Text on background | 20.25:1 | AAA |
| Text on card | 20.54:1 | AAA |
| Primary button | 5.87:1 | AA |
| Secondary button | 9.68:1 | AAA |
| Muted text | 8.53:1 | AAA |
| Accent | 9.68:1 | AAA |
| Destructive | 3.62:1 | AA Large |
Paste this into your globals.css to use Colorful in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.113 0.042 293.18);
--muted: oklch(0.915 0.009 116.512);
--muted-foreground: oklch(0.437 0.033 117.721);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.113 0.042 293.18);
--card: oklch(0.992 0 161.565);
--card-foreground: oklch(0.102 0.036 294.507);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.631 0.083 293.813);
--primary-foreground: oklch(0 0 0);
--secondary: oklch(0.757 0.077 118.205);
--secondary-foreground: oklch(0.097 0.007 116.57);
--accent: oklch(0.757 0.077 118.205);
--accent-foreground: oklch(0.097 0.007 116.57);
--destructive: oklch(0.414 0.12 43.553);
--destructive-foreground: oklch(0.888 0.065 51.645);
--ring: oklch(0.631 0.083 293.813);
--chart-1: oklch(0.631 0.083 293.813);
--chart-2: oklch(0.757 0.077 118.205);
--chart-3: oklch(0.757 0.077 118.205);
--chart-4: oklch(0.776 0.071 118.009);
--chart-5: oklch(0.625 0.092 293.491);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.083 0.011 295.87);
--foreground: oklch(0.991 0.002 296.292);
--muted: oklch(0.248 0.013 117.252);
--muted-foreground: oklch(0.797 0.029 116.991);
--popover: oklch(0.083 0.011 295.87);
--popover-foreground: oklch(0.991 0.002 296.292);
--card: oklch(0.104 0.014 295.87);
--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.631 0.083 293.813);
--primary-foreground: oklch(0 0 0);
--secondary: oklch(0.757 0.077 118.205);
--secondary-foreground: oklch(0.097 0.007 116.57);
--accent: oklch(0.757 0.077 118.205);
--accent-foreground: oklch(0.097 0.007 116.57);
--destructive: oklch(0.641 0.195 41.534);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.631 0.083 293.813);
--chart-1: oklch(0.631 0.083 293.813);
--chart-2: oklch(0.757 0.077 118.205);
--chart-3: oklch(0.757 0.077 118.205);
--chart-4: oklch(0.776 0.071 118.009);
--chart-5: oklch(0.625 0.092 293.491);
}