Grim is a shadcn/ui theme built around a purple primary color (#82306a) with red accents (#823041). The light mode uses a neutral background (#fefbfd). Dark mode keeps the purple primary (#82306a) on a neutral background (#070306).
| Token | Light | Dark |
|---|---|---|
| Background | #fefbfdsnow | #070306black |
| Foreground | #150410black | #fdfcfdwhite |
| Card | #fefbfdsnow | #070306black |
| Card foreground | #150410black | #fdfcfdwhite |
| Popover | #fefbfdsnow | #070306black |
| Popover foreground | #150410black | #fdfcfdwhite |
| Primary | #82306apurple | #82306apurple |
| Primary foreground | #f8ecf5lavenderblush | #f8ecf5lavenderblush |
| Secondary | #723082rebeccapurple | #723082rebeccapurple |
| Secondary foreground | #f6ecf8whitesmoke | #f6ecf8whitesmoke |
| Muted | #ece8edlavender | #161217black |
| Muted foreground | #575757dimgray | #a8a8a8darkgray |
| Accent | #823041brown | #823041brown |
| Accent foreground | #f8eceflinen | #f8eceflinen |
| Destructive | #9d2301firebrick | #fe400borangered |
| Destructive foreground | #ffdbd1bisque | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #82306apurple | #82306apurple |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.31:1 | AAA |
| Text on card | 19.31:1 | AAA |
| Primary button | 7.07:1 | AAA |
| Secondary button | 7.41:1 | AAA |
| Muted text | 5.97:1 | AA |
| Accent | 7.42:1 | AAA |
| Destructive | 6.09:1 | AA |
| Text on background | 20.03:1 | AAA |
| Text on card | 20.03:1 | AAA |
| Primary button | 7.07:1 | AAA |
| Secondary button | 7.41:1 | AAA |
| Muted text | 7.79:1 | AAA |
| Accent | 7.42:1 | AAA |
| Destructive | 3.53:1 | AA Large |
Paste this into your globals.css to use Grim in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.991 0.005 335.956);
--foreground: oklch(0.148 0.041 339.463);
--muted: oklch(0.936 0.008 319.447);
--muted-foreground: oklch(0.456 0 180);
--popover: oklch(0.991 0.005 335.956);
--popover-foreground: oklch(0.148 0.041 339.463);
--card: oklch(0.991 0.005 335.956);
--card-foreground: oklch(0.148 0.041 339.463);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.447 0.132 341.153);
--primary-foreground: oklch(0.956 0.017 336.192);
--secondary: oklch(0.436 0.144 319.13);
--secondary-foreground: oklch(0.955 0.018 319.45);
--accent: oklch(0.432 0.114 11.008);
--accent-foreground: oklch(0.954 0.013 3.552);
--destructive: oklch(0.456 0.163 34.147);
--destructive-foreground: oklch(0.919 0.042 35.945);
--ring: oklch(0.447 0.132 341.153);
--chart-1: oklch(0.447 0.132 341.153);
--chart-2: oklch(0.436 0.144 319.13);
--chart-3: oklch(0.432 0.114 11.008);
--chart-4: oklch(0.462 0.154 319.118);
--chart-5: oklch(0.448 0.139 341.475);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.109 0.018 336.308);
--foreground: oklch(0.992 0.001 335.882);
--muted: oklch(0.189 0.012 319.46);
--muted-foreground: oklch(0.733 0 180);
--popover: oklch(0.109 0.018 336.308);
--popover-foreground: oklch(0.992 0.001 335.882);
--card: oklch(0.109 0.018 336.308);
--card-foreground: oklch(0.992 0.001 335.882);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.447 0.132 341.153);
--primary-foreground: oklch(0.956 0.017 336.192);
--secondary: oklch(0.436 0.144 319.13);
--secondary-foreground: oklch(0.955 0.018 319.45);
--accent: oklch(0.432 0.114 11.008);
--accent-foreground: oklch(0.954 0.013 3.552);
--destructive: oklch(0.654 0.231 33.943);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.447 0.132 341.153);
--chart-1: oklch(0.447 0.132 341.153);
--chart-2: oklch(0.436 0.144 319.13);
--chart-3: oklch(0.432 0.114 11.008);
--chart-4: oklch(0.462 0.154 319.118);
--chart-5: oklch(0.448 0.139 341.475);
}