Striking is a shadcn/ui theme built around a violet primary color (#7b4f92) with muted light violet accents (#e0d8e4). The light mode uses a neutral background (#ffffff). Dark mode keeps the violet primary (#7b4f92) on a violet-tinted background (#09040b).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #09040bblack |
| Foreground | #0d0212black | #ffffffwhite |
| Card | #ffffffwhite | #09040bblack |
| Card foreground | #0d0212black | #ffffffwhite |
| Popover | #ffffffwhite | #09040bblack |
| Popover foreground | #0d0212black | #ffffffwhite |
| Primary | #7b4f92rebeccapurple | #7b4f92rebeccapurple |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #e0d8e4gainsboro | #261e29darkslategray |
| Secondary foreground | #493851darkslategray | #c0b2c7silver |
| Muted | #e4d7eagainsboro | #221528black |
| Muted foreground | #504356darkslategray | #b6a9bcdarkgray |
| Accent | #e0d8e4gainsboro | #261e29darkslategray |
| Accent foreground | #493851darkslategray | #c0b2c7silver |
| Destructive | #86260esaddlebrown | #d03b16firebrick |
| Destructive foreground | #fad5ccbisque | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #7b4f92rebeccapurple | #7b4f92rebeccapurple |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.29:1 | AAA |
| Text on card | 20.29:1 | AAA |
| Primary button | 6.23:1 | AA |
| Secondary button | 7.67:1 | AAA |
| Muted text | 6.66:1 | AA |
| Accent | 7.67:1 | AAA |
| Destructive | 6.73:1 | AA |
| Text on background | 20.31:1 | AAA |
| Text on card | 20.31:1 | AAA |
| Primary button | 6.23:1 | AA |
| Secondary button | 8.03:1 | AAA |
| Muted text | 7.78:1 | AAA |
| Accent | 8.03:1 | AAA |
| Destructive | 4.87:1 | AA |
Paste this into your globals.css to use Striking in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.127 0.044 315.404);
--muted: oklch(0.895 0.029 314.67);
--muted-foreground: oklch(0.404 0.034 314.417);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.127 0.044 315.404);
--card: oklch(1 0 180);
--card-foreground: oklch(0.127 0.044 315.404);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.504 0.114 313.605);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.892 0.018 314.727);
--secondary-foreground: oklch(0.371 0.047 314.206);
--accent: oklch(0.892 0.018 314.727);
--accent-foreground: oklch(0.371 0.047 314.206);
--destructive: oklch(0.417 0.135 34.573);
--destructive-foreground: oklch(0.902 0.043 34.328);
--ring: oklch(0.504 0.114 313.605);
--chart-1: oklch(0.504 0.114 313.605);
--chart-2: oklch(0.892 0.018 314.727);
--chart-3: oklch(0.892 0.018 314.727);
--chart-4: oklch(0.917 0.014 314.753);
--chart-5: oklch(0.501 0.125 313.446);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.122 0.022 316.292);
--foreground: oklch(1 0 180);
--muted: oklch(0.222 0.04 313.9);
--muted-foreground: oklch(0.752 0.029 314.638);
--popover: oklch(0.122 0.022 316.292);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.122 0.022 316.292);
--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.504 0.114 313.605);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.249 0.024 314.359);
--secondary-foreground: oklch(0.782 0.033 314.619);
--accent: oklch(0.249 0.024 314.359);
--accent-foreground: oklch(0.782 0.033 314.619);
--destructive: oklch(0.571 0.191 34.272);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.504 0.114 313.605);
--chart-1: oklch(0.504 0.114 313.605);
--chart-2: oklch(0.249 0.024 314.359);
--chart-3: oklch(0.249 0.024 314.359);
--chart-4: oklch(0.279 0.028 314.333);
--chart-5: oklch(0.501 0.125 313.446);
}