Decency is a shadcn/ui theme built around a purple primary color (#bd1fad) with muted light purple accents (#cdbccb). The light mode uses a neutral background (#fdfbfd). Dark mode keeps the purple primary (#bd1fad) on a neutral background (#000000).
| Token | Light | Dark |
|---|---|---|
| Background | #fdfbfdsnow | #000000black |
| Foreground | #040104black | #ffffffwhite |
| Card | #fcf8fbsnow | #030303black |
| Card foreground | #000000black | #ffffffwhite |
| Popover | #fdfbfdsnow | #000000black |
| Popover foreground | #040104black | #ffffffwhite |
| Primary | #bd1fadmediumvioletred | #bd1fadmediumvioletred |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #e0dcdfgainsboro | #343233darkslategray |
| Secondary foreground | #494148darkslategray | #cdcbcclightgrey |
| Muted | #eeddeclavender | #221120black |
| Muted foreground | #5b4859dimgray | #b7a4b5darkgray |
| Accent | #cdbccbthistle | #4c434bdarkslategray |
| Accent foreground | #312530darkslategray | #e2dfe2gainsboro |
| Destructive | #ad0e00darkred | #ff3b29orangered |
| Destructive foreground | #ffe3e0mistyrose | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #bd1fadmediumvioletred | #bd1fadmediumvioletred |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.24:1 | AAA |
| Text on card | 19.95:1 | AAA |
| Primary button | 5.31:1 | AA |
| Secondary button | 7.24:1 | AAA |
| Muted text | 6.43:1 | AA |
| Accent | 8.10:1 | AAA |
| Destructive | 6.07:1 | AA |
| Text on background | 21.00:1 | AAA |
| Text on card | 20.67:1 | AAA |
| Primary button | 5.31:1 | AA |
| Secondary button | 7.85:1 | AAA |
| Muted text | 7.69:1 | AAA |
| Accent | 7.18:1 | AAA |
| Destructive | 3.55:1 | AA Large |
Paste this into your globals.css to use Decency in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.991 0.003 328.628);
--foreground: oklch(0.085 0.023 330.084);
--muted: oklch(0.915 0.028 328.926);
--muted-foreground: oklch(0.428 0.038 329.536);
--popover: oklch(0.991 0.003 328.628);
--popover-foreground: oklch(0.085 0.023 330.084);
--card: oklch(0.983 0.006 328.664);
--card-foreground: oklch(0 0 0);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.56 0.234 333.057);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.898 0.006 328.672);
--secondary-foreground: oklch(0.385 0.017 329.058);
--accent: oklch(0.814 0.027 328.958);
--accent-foreground: oklch(0.284 0.026 329.566);
--destructive: oklch(0.475 0.189 30.329);
--destructive-foreground: oklch(0.938 0.031 23.934);
--ring: oklch(0.56 0.234 333.057);
--chart-1: oklch(0.56 0.234 333.057);
--chart-2: oklch(0.898 0.006 328.672);
--chart-3: oklch(0.814 0.027 328.958);
--chart-4: oklch(0.922 0.005 328.652);
--chart-5: oklch(0.565 0.239 333.174);
}
.dark {
--radius: 0.5rem;
--background: oklch(0 0 0);
--foreground: oklch(1 0 180);
--muted: oklch(0.209 0.04 330.528);
--muted-foreground: oklch(0.74 0.033 329.08);
--popover: oklch(0 0 0);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.092 0 180);
--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.56 0.234 333.057);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.32 0.002 328.667);
--secondary-foreground: oklch(0.845 0.002 328.615);
--accent: oklch(0.395 0.017 329.061);
--accent-foreground: oklch(0.906 0.006 328.665);
--destructive: oklch(0.653 0.233 29.857);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.56 0.234 333.057);
--chart-1: oklch(0.56 0.234 333.057);
--chart-2: oklch(0.32 0.002 328.667);
--chart-3: oklch(0.395 0.017 329.061);
--chart-4: oklch(0.35 0.002 328.669);
--chart-5: oklch(0.565 0.239 333.174);
}