Onset is a shadcn/ui theme built around a vivid light purple primary color (#f4cafc) with vivid light green accents (#d2fcca). The light mode uses a neutral background (#fdfbfe). Dark mode keeps the vivid light purple primary (#f4cafc) on a purple-tinted background (#0a050b).
| Token | Light | Dark |
|---|---|---|
| Background | #fdfbfewhite | #0a050bblack |
| Foreground | #110614black | #ffffffwhite |
| Card | #fcf7fdghostwhite | #0d060eblack |
| Card foreground | #0e0510black | #ffffffwhite |
| Popover | #fdfbfewhite | #0a050bblack |
| Popover foreground | #110614black | #ffffffwhite |
| Primary | #f4cafclavender | #f4cafclavender |
| Primary foreground | #76078dpurple | #76078dpurple |
| Secondary | #d2fccagainsboro | #d2fccagainsboro |
| Secondary foreground | #092c02black | #092c02black |
| Muted | #e1eddegainsboro | #152112black |
| Muted foreground | #414540darkslategray | #bbbfbasilver |
| Accent | #d2fccagainsboro | #d2fccagainsboro |
| Accent foreground | #092c02black | #092c02black |
| Destructive | #660e0bmaroon | #d91d17crimson |
| Destructive foreground | #f6aeaclightpink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #f4cafclavender | #f4cafclavender |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.27:1 | AAA |
| Text on card | 18.97:1 | AAA |
| Primary button | 6.71:1 | AA |
| Secondary button | 13.50:1 | AAA |
| Muted text | 8.06:1 | AAA |
| Accent | 13.50:1 | AAA |
| Destructive | 7.11:1 | AAA |
| Text on background | 20.25:1 | AAA |
| Text on card | 20.00:1 | AAA |
| Primary button | 6.71:1 | AA |
| Secondary button | 13.50:1 | AAA |
| Muted text | 8.97:1 | AAA |
| Accent | 13.50:1 | AAA |
| Destructive | 5.07:1 | AA |
Paste this into your globals.css to use Onset in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.991 0.004 320.538);
--foreground: oklch(0.148 0.035 321.068);
--muted: oklch(0.932 0.024 140.492);
--muted-foreground: oklch(0.384 0.011 140.489);
--popover: oklch(0.991 0.004 320.538);
--popover-foreground: oklch(0.148 0.035 321.068);
--card: oklch(0.982 0.008 320.544);
--card-foreground: oklch(0.136 0.031 321.415);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.89 0.081 320.664);
--primary-foreground: oklch(0.417 0.195 319.329);
--secondary: oklch(0.949 0.08 140.408);
--secondary-foreground: oklch(0.257 0.078 140.081);
--accent: oklch(0.949 0.08 140.408);
--accent-foreground: oklch(0.257 0.078 140.081);
--destructive: oklch(0.33 0.121 28.293);
--destructive-foreground: oklch(0.819 0.085 21.288);
--ring: oklch(0.89 0.081 320.664);
--chart-1: oklch(0.89 0.081 320.664);
--chart-2: oklch(0.949 0.08 140.408);
--chart-3: oklch(0.949 0.08 140.408);
--chart-4: oklch(0.962 0.058 140.44);
--chart-5: oklch(0.889 0.084 320.668);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.125 0.02 321.806);
--foreground: oklch(1 0 180);
--muted: oklch(0.231 0.033 140.349);
--muted-foreground: oklch(0.801 0.009 140.514);
--popover: oklch(0.125 0.02 321.806);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.138 0.023 321.163);
--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.89 0.081 320.664);
--primary-foreground: oklch(0.417 0.195 319.329);
--secondary: oklch(0.949 0.08 140.408);
--secondary-foreground: oklch(0.257 0.078 140.081);
--accent: oklch(0.949 0.08 140.408);
--accent-foreground: oklch(0.257 0.078 140.081);
--destructive: oklch(0.566 0.218 28.893);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.89 0.081 320.664);
--chart-1: oklch(0.89 0.081 320.664);
--chart-2: oklch(0.949 0.08 140.408);
--chart-3: oklch(0.949 0.08 140.408);
--chart-4: oklch(0.962 0.058 140.44);
--chart-5: oklch(0.889 0.084 320.668);
}