Yam is a shadcn/ui theme built around a neutral gray primary color (#e2e2df) with neutral gray accents (#dfdfe2). The light mode uses a neutral background (#ffffff). Dark mode keeps the neutral gray primary (#e2e2df) on a green-tinted background (#0a0b04).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #0a0b04black |
| Foreground | #080901black | #fdfdfcwhite |
| Card | #ffffffwhite | #0a0b04black |
| Card foreground | #080901black | #fdfdfcwhite |
| Popover | #ffffffwhite | #0a0b04black |
| Popover foreground | #080901black | #fdfdfcwhite |
| Primary | #e2e2dfgainsboro | #e2e2dfgainsboro |
| Primary foreground | #4a4c43darkslategray | #4a4c43darkslategray |
| Secondary | #dfdfe2gainsboro | #dfdfe2gainsboro |
| Secondary foreground | #45434cdarkslategray | #45434cdarkslategray |
| Muted | #efeef7whitesmoke | #0a0811black |
| Muted foreground | #616066dimgray | #9a999fdarkgray |
| Accent | #dfdfe2gainsboro | #dfdfe2gainsboro |
| Accent foreground | #45434cdarkslategray | #45434cdarkslategray |
| Destructive | #953404saddlebrown | #f96115orangered |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #e2e2dfgainsboro | #e2e2dfgainsboro |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.00:1 | AAA |
| Text on card | 20.00:1 | AAA |
| Primary button | 6.72:1 | AA |
| Secondary button | 7.29:1 | AAA |
| Muted text | 5.39:1 | AA |
| Accent | 7.29:1 | AAA |
| Destructive | 7.55:1 | AAA |
| Text on background | 19.40:1 | AAA |
| Text on card | 19.40:1 | AAA |
| Primary button | 6.72:1 | AA |
| Secondary button | 7.29:1 | AAA |
| Muted text | 7.03:1 | AAA |
| Accent | 7.29:1 | AAA |
| Destructive | 6.75:1 | AA |
Paste this into your globals.css to use Yam in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.133 0.023 115.048);
--muted: oklch(0.952 0.013 293.817);
--muted-foreground: oklch(0.494 0.009 293.707);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.133 0.023 115.048);
--card: oklch(1 0 180);
--card-foreground: oklch(0.133 0.023 115.048);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.912 0.005 114.167);
--primary-foreground: oklch(0.411 0.014 114.699);
--secondary: oklch(0.904 0.005 293.963);
--secondary-foreground: oklch(0.388 0.014 293.364);
--accent: oklch(0.904 0.005 293.963);
--accent-foreground: oklch(0.388 0.014 293.364);
--destructive: oklch(0.461 0.14 40.828);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.912 0.005 114.167);
--chart-1: oklch(0.912 0.005 114.167);
--chart-2: oklch(0.904 0.005 293.963);
--chart-3: oklch(0.904 0.005 293.963);
--chart-4: oklch(0.928 0.004 293.991);
--chart-5: oklch(0.914 0.007 114.217);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.146 0.017 114.922);
--foreground: oklch(0.994 0.002 114.098);
--muted: oklch(0.142 0.021 291.68);
--muted-foreground: oklch(0.684 0.009 293.828);
--popover: oklch(0.146 0.017 114.922);
--popover-foreground: oklch(0.994 0.002 114.098);
--card: oklch(0.146 0.017 114.922);
--card-foreground: oklch(0.994 0.002 114.098);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.912 0.005 114.167);
--primary-foreground: oklch(0.411 0.014 114.699);
--secondary: oklch(0.904 0.005 293.963);
--secondary-foreground: oklch(0.388 0.014 293.364);
--accent: oklch(0.904 0.005 293.963);
--accent-foreground: oklch(0.388 0.014 293.364);
--destructive: oklch(0.681 0.2 41.419);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.912 0.005 114.167);
--chart-1: oklch(0.912 0.005 114.167);
--chart-2: oklch(0.904 0.005 293.963);
--chart-3: oklch(0.904 0.005 293.963);
--chart-4: oklch(0.928 0.004 293.991);
--chart-5: oklch(0.914 0.007 114.217);
}