Diplomacy is a shadcn/ui theme built around a near-black primary color (#212022) with near-black accents (#222220). The light mode uses a neutral background (#f9f8fc). Dark mode keeps the near-black primary (#212022) on a violet-tinted background (#080410).
| Token | Light | Dark |
|---|---|---|
| Background | #f9f8fcghostwhite | #080410black |
| Foreground | #020104black | #f6f4fawhitesmoke |
| Card | #f6f4fbghostwhite | #0a0514black |
| Card foreground | #000000black | #f9f8fcghostwhite |
| Popover | #f6f4fbghostwhite | #0a0514black |
| Popover foreground | #000000black | #f9f8fcghostwhite |
| Primary | #212022black | #212022black |
| Primary foreground | #b9b7bdsilver | #b9b7bdsilver |
| Secondary | #222220black | #222220black |
| Secondary foreground | #bbbdb7silver | #bbbdb7silver |
| Muted | #e4ead6gainsboro | #222915black |
| Muted foreground | #4d5341darkolivegreen | #b8beacsilver |
| Accent | #222220black | #222220black |
| Accent foreground | #bbbdb7silver | #bbbdb7silver |
| Destructive | #981206darkred | #f51e0ared |
| Destructive foreground | #fdd6d3mistyrose | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #212022black | #212022black |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.65:1 | AAA |
| Text on card | 19.25:1 | AAA |
| Primary button | 8.18:1 | AAA |
| Secondary button | 8.37:1 | AAA |
| Muted text | 6.50:1 | AA |
| Accent | 8.37:1 | AAA |
| Destructive | 6.49:1 | AA |
| Text on background | 18.56:1 | AAA |
| Text on card | 18.98:1 | AAA |
| Primary button | 8.18:1 | AAA |
| Secondary button | 8.37:1 | AAA |
| Muted text | 7.89:1 | AAA |
| Accent | 8.37:1 | AAA |
| Destructive | 4.14:1 | AA Large |
Paste this into your globals.css to use Diplomacy in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.98 0.006 300.665);
--foreground: oklch(0.081 0.015 301.099);
--muted: oklch(0.928 0.028 121.261);
--muted-foreground: oklch(0.431 0.029 121.903);
--popover: oklch(0.971 0.009 300.612);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.971 0.009 300.612);
--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.245 0.005 300.424);
--primary-foreground: oklch(0.784 0.008 300.601);
--secondary: oklch(0.252 0.005 121.098);
--secondary-foreground: oklch(0.795 0.008 120.931);
--accent: oklch(0.252 0.005 121.098);
--accent-foreground: oklch(0.795 0.008 120.931);
--destructive: oklch(0.434 0.167 30.158);
--destructive-foreground: oklch(0.909 0.044 24.114);
--ring: oklch(0.245 0.005 300.424);
--chart-1: oklch(0.245 0.005 300.424);
--chart-2: oklch(0.252 0.005 121.098);
--chart-3: oklch(0.252 0.005 121.098);
--chart-4: oklch(0.285 0.006 121.118);
--chart-5: oklch(0.242 0.009 300.156);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.125 0.03 299.674);
--foreground: oklch(0.971 0.008 300.63);
--muted: oklch(0.267 0.036 123.166);
--muted-foreground: oklch(0.792 0.025 121.297);
--popover: oklch(0.135 0.035 298.052);
--popover-foreground: oklch(0.981 0.005 300.677);
--card: oklch(0.135 0.035 298.052);
--card-foreground: oklch(0.981 0.005 300.677);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.245 0.005 300.424);
--primary-foreground: oklch(0.784 0.008 300.601);
--secondary: oklch(0.252 0.005 121.098);
--secondary-foreground: oklch(0.795 0.008 120.931);
--accent: oklch(0.252 0.005 121.098);
--accent-foreground: oklch(0.795 0.008 120.931);
--destructive: oklch(0.617 0.242 30.039);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.245 0.005 300.424);
--chart-1: oklch(0.245 0.005 300.424);
--chart-2: oklch(0.252 0.005 121.098);
--chart-3: oklch(0.252 0.005 121.098);
--chart-4: oklch(0.285 0.006 121.118);
--chart-5: oklch(0.242 0.009 300.156);
}