Contributor is a shadcn/ui theme built around a neutral gray primary color (#3a3836) with neutral gray accents (#38363a). The light mode uses a neutral background (#fefcfb). Dark mode keeps the neutral gray primary (#3a3836) on a neutral background (#080502).
| Token | Light | Dark |
|---|---|---|
| Background | #fefcfbsnow | #080502black |
| Foreground | #0d0702black | #fdfcfcsnow |
| Card | #fdfaf7snow | #0c0703black |
| Card foreground | #090501black | #ffffffwhite |
| Popover | #fefcfbsnow | #080502black |
| Popover foreground | #0d0702black | #fdfcfcsnow |
| Primary | #3a3836darkslategray | #3a3836darkslategray |
| Primary foreground | #d3d1cflightgrey | #d3d1cflightgrey |
| Secondary | #363a38darkslategray | #363a38darkslategray |
| Secondary foreground | #cfd3d1lightgrey | #cfd3d1lightgrey |
| Muted | #d3ded8gainsboro | #212c26darkslategray |
| Muted foreground | #5c7065dimgray | #8fa398darkseagreen |
| Accent | #38363adarkslategray | #38363adarkslategray |
| Accent foreground | #d1cfd3lightgrey | #d1cfd3lightgrey |
| Destructive | #aa420esaddlebrown | #ee6f2ftomato |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #3a3836darkslategray | #3a3836darkslategray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.61:1 | AAA |
| Text on card | 19.46:1 | AAA |
| Primary button | 7.67:1 | AAA |
| Secondary button | 7.61:1 | AAA |
| Muted text | 3.84:1 | AA Large |
| Accent | 7.74:1 | AAA |
| Destructive | 6.02:1 | AA |
| Text on background | 19.87:1 | AAA |
| Text on card | 20.04:1 | AAA |
| Primary button | 7.67:1 | AAA |
| Secondary button | 7.61:1 | AAA |
| Muted text | 5.43:1 | AA |
| Accent | 7.74:1 | AAA |
| Destructive | 6.95:1 | AA |
Paste this into your globals.css to use Contributor in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.993 0.002 60.252);
--foreground: oklch(0.135 0.02 70.296);
--muted: oklch(0.891 0.014 161.421);
--muted-foreground: oklch(0.526 0.03 160.338);
--popover: oklch(0.993 0.002 60.252);
--popover-foreground: oklch(0.135 0.02 70.296);
--card: oklch(0.985 0.005 60.22);
--card-foreground: oklch(0.118 0.017 71.44);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.342 0.005 60.087);
--primary-foreground: oklch(0.861 0.003 60.233);
--secondary: oklch(0.345 0.007 161.274);
--secondary-foreground: oklch(0.863 0.005 161.671);
--accent: oklch(0.336 0.008 305.415);
--accent-foreground: oklch(0.858 0.005 305.657);
--destructive: oklch(0.514 0.148 41.912);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.342 0.005 60.087);
--chart-1: oklch(0.342 0.005 60.087);
--chart-2: oklch(0.345 0.007 161.274);
--chart-3: oklch(0.336 0.008 305.415);
--chart-4: oklch(0.374 0.008 161.261);
--chart-5: oklch(0.342 0.009 59.938);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.117 0.013 68.787);
--foreground: oklch(0.993 0.001 60.267);
--muted: oklch(0.279 0.019 160.094);
--muted-foreground: oklch(0.697 0.028 160.788);
--popover: oklch(0.117 0.013 68.787);
--popover-foreground: oklch(0.993 0.001 60.267);
--card: oklch(0.134 0.015 68.215);
--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.342 0.005 60.087);
--primary-foreground: oklch(0.861 0.003 60.233);
--secondary: oklch(0.345 0.007 161.274);
--secondary-foreground: oklch(0.863 0.005 161.671);
--accent: oklch(0.336 0.008 305.415);
--accent-foreground: oklch(0.858 0.005 305.657);
--destructive: oklch(0.685 0.174 44.122);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.342 0.005 60.087);
--chart-1: oklch(0.342 0.005 60.087);
--chart-2: oklch(0.345 0.007 161.274);
--chart-3: oklch(0.336 0.008 305.415);
--chart-4: oklch(0.374 0.008 161.261);
--chart-5: oklch(0.342 0.009 59.938);
}