Discord Theme is a shadcn/ui theme built around a near-white primary color (#ffffff) with muted deep indigo accents (#41414e). The light mode uses an indigo-tinted background (#1e1e24). Dark mode keeps the near-white primary (#ffffff) on an indigo-tinted background (#1e1e24).
| Token | Light | Dark |
|---|---|---|
| Background | #1e1e24black | #1e1e24black |
| Foreground | #c0cad8lightsteelblue | #c0cad8lightsteelblue |
| Card | #1a1a1fblack | #1a1a1fblack |
| Card foreground | #d0d7e2gainsboro | #d0d7e2gainsboro |
| Popover | #17171cblack | #17171cblack |
| Popover foreground | #e0e5eblavender | #e0e5eblavender |
| Primary | #ffffffwhite | #ffffffwhite |
| Primary foreground | #333333darkslategray | #333333darkslategray |
| Secondary | #404040darkslategray | #404040darkslategray |
| Secondary foreground | #d9d9d9gainsboro | #d9d9d9gainsboro |
| Muted | #262631darkslategray | #262631darkslategray |
| Muted foreground | #a1a1b5darkgray | #a1a1b5darkgray |
| Accent | #41414edarkslategray | #41414edarkslategray |
| Accent foreground | #dedee3gainsboro | #dedee3gainsboro |
| Destructive | #f0412dtomato | #f0412dtomato |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #2e2e2edarkslategray | #2e2e2edarkslategray |
| Input | #363636darkslategray | #363636darkslategray |
| Ring | #ffffffwhite | #ffffffwhite |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 9.99:1 | AAA |
| Text on card | 12.02:1 | AAA |
| Primary button | 12.63:1 | AAA |
| Secondary button | 7.37:1 | AAA |
| Muted text | 5.89:1 | AA |
| Accent | 7.49:1 | AAA |
| Destructive | 3.81:1 | AA Large |
| Text on background | 9.99:1 | AAA |
| Text on card | 12.02:1 | AAA |
| Primary button | 12.63:1 | AAA |
| Secondary button | 7.37:1 | AAA |
| Muted text | 5.89:1 | AA |
| Accent | 7.49:1 | AAA |
| Destructive | 3.81:1 | AA Large |
Paste this into your globals.css to use Discord Theme in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.238 0.011 285.508);
--foreground: oklch(0.836 0.022 256.74);
--muted: oklch(0.274 0.019 285.067);
--muted-foreground: oklch(0.715 0.029 285.64);
--popover: oklch(0.208 0.009 285.588);
--popover-foreground: oklch(0.919 0.011 256.697);
--card: oklch(0.218 0.01 285.558);
--card-foreground: oklch(0.877 0.016 256.719);
--border: oklch(0.301 0 189.462);
--input: oklch(0.331 0 180);
--primary: oklch(1 0 180);
--primary-foreground: oklch(0.321 0 180);
--secondary: oklch(0.371 0 168.69);
--secondary-foreground: oklch(0.885 0 180);
--accent: oklch(0.38 0.022 285.32);
--accent-foreground: oklch(0.901 0.007 286.249);
--destructive: oklch(0.634 0.215 30.272);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(1 0 180);
--chart-1: oklch(1 0 180);
--chart-2: oklch(0.371 0 168.69);
--chart-3: oklch(0.38 0.022 285.32);
--chart-4: oklch(0.399 0 180);
--chart-5: oklch(1 0 180);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.238 0.011 285.508);
--foreground: oklch(0.836 0.022 256.74);
--muted: oklch(0.274 0.019 285.067);
--muted-foreground: oklch(0.715 0.029 285.64);
--popover: oklch(0.208 0.009 285.588);
--popover-foreground: oklch(0.919 0.011 256.697);
--card: oklch(0.218 0.01 285.558);
--card-foreground: oklch(0.877 0.016 256.719);
--border: oklch(0.301 0 189.462);
--input: oklch(0.331 0 180);
--primary: oklch(1 0 180);
--primary-foreground: oklch(0.321 0 180);
--secondary: oklch(0.371 0 168.69);
--secondary-foreground: oklch(0.885 0 180);
--accent: oklch(0.38 0.022 285.32);
--accent-foreground: oklch(0.901 0.007 286.249);
--destructive: oklch(0.634 0.215 30.272);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(1 0 180);
--chart-1: oklch(1 0 180);
--chart-2: oklch(0.371 0 168.69);
--chart-3: oklch(0.38 0.022 285.32);
--chart-4: oklch(0.399 0 180);
--chart-5: oklch(1 0 180);
}