b is a shadcn/ui theme built around a yellow primary color (#6f7330) with muted light yellow accents (#d7d8cb). The light mode uses a neutral background (#ffffff). Dark mode keeps the yellow primary (#6f7330) on a yellow-tinted background (#0b0b04).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #0b0b04black |
| Foreground | #111202black | #fbfbf9snow |
| Card | #fcfcfcsnow | #0e0f05black |
| Card foreground | #0d0e02black | #fdfdfcwhite |
| Popover | #ffffffwhite | #0b0b04black |
| Popover foreground | #111202black | #fbfbf9snow |
| Primary | #6f7330darkolivegreen | #6f7330darkolivegreen |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #d7d8cblightgrey | #303121darkslategray |
| Secondary foreground | #3f4030darkslategray | #ccceb6silver |
| Muted | #f1f1efwhitesmoke | #10100eblack |
| Muted foreground | #4b4c38darkolivegreen | #c5c7b3silver |
| Accent | #d7d8cblightgrey | #303121darkslategray |
| Accent foreground | #3f4030darkslategray | #ccceb6silver |
| Destructive | #641702maroon | #e13405orangered |
| Destructive foreground | #fdb09blightsalmon | #ffffffwhite |
| Border | #ebecealinen | #252522darkslategray |
| Input | #ebecealinen | #252522darkslategray |
| Ring | #6f7330darkolivegreen | #6f7330darkolivegreen |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 18.89:1 | AAA |
| Text on card | 19.01:1 | AAA |
| Primary button | 5.03:1 | AA |
| Secondary button | 7.30:1 | AAA |
| Muted text | 7.75:1 | AAA |
| Accent | 7.30:1 | AAA |
| Destructive | 7.11:1 | AAA |
| Text on background | 19.02:1 | AAA |
| Text on card | 18.91:1 | AAA |
| Primary button | 5.03:1 | AA |
| Secondary button | 8.24:1 | AAA |
| Muted text | 11.03:1 | AAA |
| Accent | 8.24:1 | AAA |
| Destructive | 4.47:1 | AA Large |
Paste this into your globals.css to use b in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.177 0.034 112.37);
--muted: oklch(0.957 0.003 109.534);
--muted-foreground: oklch(0.41 0.032 110.879);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.177 0.034 112.37);
--card: oklch(0.992 0 161.565);
--card-foreground: oklch(0.157 0.029 111.994);
--border: oklch(0.941 0.003 109.532);
--input: oklch(0.941 0.003 109.532);
--primary: oklch(0.537 0.09 112.545);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.877 0.017 109.845);
--secondary-foreground: oklch(0.365 0.026 110.764);
--accent: oklch(0.877 0.017 109.845);
--accent-foreground: oklch(0.365 0.026 110.764);
--destructive: oklch(0.335 0.113 35.497);
--destructive-foreground: oklch(0.826 0.095 36.104);
--ring: oklch(0.537 0.09 112.545);
--chart-1: oklch(0.537 0.09 112.545);
--chart-2: oklch(0.877 0.017 109.845);
--chart-3: oklch(0.877 0.017 109.845);
--chart-4: oklch(0.897 0.014 109.776);
--chart-5: oklch(0.545 0.095 112.685);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.147 0.018 111.071);
--foreground: oklch(0.987 0.002 109.522);
--muted: oklch(0.174 0.004 109.939);
--muted-foreground: oklch(0.822 0.027 110.087);
--popover: oklch(0.147 0.018 111.071);
--popover-foreground: oklch(0.987 0.002 109.522);
--card: oklch(0.164 0.021 111.463);
--card-foreground: oklch(0.993 0.001 109.5);
--border: oklch(0.265 0.006 109.932);
--input: oklch(0.265 0.006 109.932);
--primary: oklch(0.537 0.09 112.545);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.307 0.028 111.111);
--secondary-foreground: oklch(0.844 0.033 110.201);
--accent: oklch(0.307 0.028 111.111);
--accent-foreground: oklch(0.844 0.033 110.201);
--destructive: oklch(0.594 0.213 33.654);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.537 0.09 112.545);
--chart-1: oklch(0.537 0.09 112.545);
--chart-2: oklch(0.307 0.028 111.111);
--chart-3: oklch(0.307 0.028 111.111);
--chart-4: oklch(0.342 0.032 111.167);
--chart-5: oklch(0.545 0.095 112.685);
}