Melon is a shadcn/ui theme built around a green primary color (#1daf1d) with neutral gray accents (#d4d9d4). The light mode uses a neutral background (#f7fcf7). Dark mode keeps the green primary (#1daf1d) on a neutral background (#000000).
| Token | Light | Dark |
|---|---|---|
| Background | #f7fcf7mintcream | #000000black |
| Foreground | #010901black | #f6f9f6whitesmoke |
| Card | #f4fbf4whitesmoke | #030303black |
| Card foreground | #010401black | #f9fbf9mintcream |
| Popover | #f7fcf7mintcream | #000000black |
| Popover foreground | #010901black | #f6f9f6whitesmoke |
| Primary | #1daf1dforestgreen | #1daf1dforestgreen |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #d4d9d4lightgrey | #131613black |
| Secondary foreground | #3a413adarkslategray | #a8b3a8darkgray |
| Muted | #d9ddd9gainsboro | #222622black |
| Muted foreground | #495549darkslategray | #aab6aadarkgray |
| Accent | #d4d9d4lightgrey | #131613black |
| Accent foreground | #3a413adarkslategray | #a8b3a8darkgray |
| Destructive | #b03f03saddlebrown | #fc6e22tomato |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #1daf1dforestgreen | #1daf1dforestgreen |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.49:1 | AAA |
| Text on card | 19.56:1 | AAA |
| Primary button | 2.90:1 | Fail |
| Secondary button | 7.32:1 | AAA |
| Muted text | 5.72:1 | AA |
| Accent | 7.32:1 | AAA |
| Destructive | 5.89:1 | AA |
| Text on background | 19.79:1 | AAA |
| Text on card | 19.88:1 | AAA |
| Primary button | 2.90:1 | Fail |
| Secondary button | 8.41:1 | AAA |
| Muted text | 7.31:1 | AAA |
| Accent | 8.41:1 | AAA |
| Destructive | 7.38:1 | AAA |
Paste this into your globals.css to use Melon in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.987 0.008 145.513);
--foreground: oklch(0.124 0.033 143.298);
--muted: oklch(0.894 0.007 145.514);
--muted-foreground: oklch(0.436 0.026 145.113);
--popover: oklch(0.987 0.008 145.513);
--popover-foreground: oklch(0.124 0.033 143.298);
--card: oklch(0.981 0.012 145.48);
--card-foreground: oklch(0.098 0.026 143.298);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.658 0.212 142.682);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.879 0.008 145.503);
--secondary-foreground: oklch(0.365 0.016 145.243);
--accent: oklch(0.879 0.008 145.503);
--accent-foreground: oklch(0.365 0.016 145.243);
--destructive: oklch(0.521 0.158 41.241);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.658 0.212 142.682);
--chart-1: oklch(0.658 0.212 142.682);
--chart-2: oklch(0.879 0.008 145.503);
--chart-3: oklch(0.879 0.008 145.503);
--chart-4: oklch(0.902 0.007 145.519);
--chart-5: oklch(0.666 0.217 142.646);
}
.dark {
--radius: 0.5rem;
--background: oklch(0 0 0);
--foreground: oklch(0.979 0.005 145.534);
--muted: oklch(0.262 0.01 145.282);
--muted-foreground: oklch(0.764 0.023 145.349);
--popover: oklch(0 0 0);
--popover-foreground: oklch(0.979 0.005 145.534);
--card: oklch(0.092 0 180);
--card-foreground: oklch(0.986 0.004 145.549);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.658 0.212 142.682);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.195 0.007 145.293);
--secondary-foreground: oklch(0.755 0.021 145.368);
--accent: oklch(0.195 0.007 145.293);
--accent-foreground: oklch(0.755 0.021 145.368);
--destructive: oklch(0.702 0.191 43.995);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.658 0.212 142.682);
--chart-1: oklch(0.658 0.212 142.682);
--chart-2: oklch(0.195 0.007 145.293);
--chart-3: oklch(0.195 0.007 145.293);
--chart-4: oklch(0.229 0.009 145.258);
--chart-5: oklch(0.666 0.217 142.646);
}