Rosemary is a shadcn/ui theme built around a light green primary color (#f7fbe4) with muted light green accents (#d8dcc1). The light mode uses a neutral background (#fdfdfc). Dark mode keeps the light green primary (#f7fbe4) on a neutral background (#070802).
| Token | Light | Dark |
|---|---|---|
| Background | #fdfdfcwhite | #070802black |
| Foreground | #000000black | #fbfcf8snow |
| Card | #fdfdfcwhite | #070802black |
| Card foreground | #000000black | #fbfcf8snow |
| Popover | #fdfdfcwhite | #070802black |
| Popover foreground | #000000black | #fbfcf8snow |
| Primary | #f7fbe4oldlace | #f7fbe4oldlace |
| Primary foreground | #363e09darkolivegreen | #363e09darkolivegreen |
| Secondary | #e7e9ddgainsboro | #232518black |
| Secondary foreground | #1a1c12black | #c1c6a9silver |
| Muted | #e6e9d8gainsboro | #242716black |
| Muted foreground | #565a44darkolivegreen | #b7bba5darkgray |
| Accent | #d8dcc1lightgrey | #3d4224darkslategray |
| Accent foreground | #404527darkolivegreen | #d6dbbdlightgrey |
| Destructive | #6a250cmaroon | #e96535tomato |
| Destructive foreground | #f6c3b1lightpink | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #f7fbe4oldlace | #f7fbe4oldlace |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.66:1 | AAA |
| Text on card | 20.66:1 | AAA |
| Primary button | 10.76:1 | AAA |
| Secondary button | 13.98:1 | AAA |
| Muted text | 5.78:1 | AA |
| Accent | 7.11:1 | AAA |
| Destructive | 7.12:1 | AAA |
| Text on background | 19.52:1 | AAA |
| Text on card | 19.52:1 | AAA |
| Primary button | 10.76:1 | AAA |
| Secondary button | 8.86:1 | AAA |
| Muted text | 7.72:1 | AAA |
| Accent | 7.37:1 | AAA |
| Destructive | 6.35:1 | AA |
Paste this into your globals.css to use Rosemary in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.994 0.002 114.109);
--foreground: oklch(0 0 0);
--muted: oklch(0.927 0.023 114.526);
--muted-foreground: oklch(0.458 0.035 115.475);
--popover: oklch(0.994 0.002 114.109);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.994 0.002 114.109);
--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.98 0.03 114.64);
--primary-foreground: oklch(0.346 0.074 118.893);
--secondary: oklch(0.928 0.015 114.368);
--secondary-foreground: oklch(0.22 0.017 115.53);
--accent: oklch(0.884 0.037 114.834);
--accent-foreground: oklch(0.376 0.048 116.479);
--destructive: oklch(0.363 0.105 38.721);
--destructive-foreground: oklch(0.859 0.064 40.92);
--ring: oklch(0.98 0.03 114.64);
--chart-1: oklch(0.98 0.03 114.64);
--chart-2: oklch(0.928 0.015 114.368);
--chart-3: oklch(0.884 0.037 114.834);
--chart-4: oklch(0.948 0.011 114.28);
--chart-5: oklch(0.981 0.031 114.662);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.129 0.017 114.839);
--foreground: oklch(0.988 0.004 114.147);
--muted: oklch(0.265 0.03 116.204);
--muted-foreground: oklch(0.783 0.031 114.796);
--popover: oklch(0.129 0.017 114.839);
--popover-foreground: oklch(0.988 0.004 114.147);
--card: oklch(0.129 0.017 114.839);
--card-foreground: oklch(0.988 0.004 114.147);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.98 0.03 114.64);
--primary-foreground: oklch(0.346 0.074 118.893);
--secondary: oklch(0.257 0.022 115.665);
--secondary-foreground: oklch(0.815 0.039 114.96);
--accent: oklch(0.365 0.047 116.529);
--accent-foreground: oklch(0.879 0.04 114.909);
--destructive: oklch(0.663 0.175 39.449);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.98 0.03 114.64);
--chart-1: oklch(0.98 0.03 114.64);
--chart-2: oklch(0.257 0.022 115.665);
--chart-3: oklch(0.365 0.047 116.529);
--chart-4: oklch(0.293 0.027 115.759);
--chart-5: oklch(0.981 0.031 114.662);
}