Generate feedback colors (success, warning, error, and info) for shadcn/ui
Go to generatorUsed by 4k+ developers. Want me to build your product next? Let's work together.
Hero is a shadcn/ui theme built around a vivid green primary color (#caf11e) with muted light green accents (#d9ddcb). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid green primary (#caf11e) on a green-tinted background (#0a0b04).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #0a0b04black |
| Foreground | #0a0c04black | #f9faf5whitesmoke |
| Card | #ffffffwhite | #0a0b04black |
| Card foreground | #0a0c04black | #f9faf5whitesmoke |
| Popover | #ffffffwhite | #0a0b04black |
| Popover foreground | #0a0c04black | #f9faf5whitesmoke |
| Primary | #caf11egreenyellow | #caf11egreenyellow |
| Primary foreground | #343e04darkgreen | #343e04darkgreen |
| Secondary | #e5e7dfgainsboro | #1c1d1bblack |
| Secondary foreground | #515440darkolivegreen | #b6b7b4silver |
| Muted | #e8edd4beige | #262b12black |
| Muted foreground | #4a4d3ddarkslategray | #bfc2b2silver |
| Accent | #d9ddcblightgrey | #34362bdarkslategray |
| Accent foreground | #42472edarkslategray | #ced0c3lightgrey |
| Destructive | #901604darkred | #f93c1forangered |
| Destructive foreground | #fecfc8pink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #caf11egreenyellow | #caf11egreenyellow |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.67:1 | AAA |
| Text on card | 19.67:1 | AAA |
| Primary button | 8.74:1 | AAA |
| Secondary button | 6.25:1 | AA |
| Muted text | 7.21:1 | AAA |
| Accent | 6.96:1 | AA |
| Destructive | 6.48:1 | AA |
| Text on background | 18.84:1 | AAA |
| Text on card | 18.84:1 | AAA |
| Primary button | 8.74:1 | AAA |
| Secondary button | 8.41:1 | AAA |
| Muted text | 8.06:1 | AAA |
| Accent | 7.83:1 | AAA |
| Destructive | 3.67:1 | AA Large |
Paste this into your globals.css to use Hero in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.148 0.02 115.814);
--muted: oklch(0.935 0.033 115.47);
--muted-foreground: oklch(0.413 0.027 116.025);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.148 0.02 115.814);
--card: oklch(1 0 180);
--card-foreground: oklch(0.148 0.02 115.814);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.898 0.21 120.904);
--primary-foreground: oklch(0.343 0.078 120.235);
--secondary: oklch(0.924 0.011 115.035);
--secondary-foreground: oklch(0.437 0.033 116.22);
--accent: oklch(0.889 0.025 115.336);
--accent-foreground: oklch(0.386 0.04 116.752);
--destructive: oklch(0.422 0.158 31.52);
--destructive-foreground: oklch(0.894 0.053 28.356);
--ring: oklch(0.898 0.21 120.904);
--chart-1: oklch(0.898 0.21 120.904);
--chart-2: oklch(0.924 0.011 115.035);
--chart-3: oklch(0.889 0.025 115.336);
--chart-4: oklch(0.945 0.008 114.974);
--chart-5: oklch(0.907 0.214 121.062);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.145 0.017 115.508);
--foreground: oklch(0.982 0.006 114.935);
--muted: oklch(0.277 0.041 117.716);
--muted-foreground: oklch(0.808 0.023 115.348);
--popover: oklch(0.145 0.017 115.508);
--popover-foreground: oklch(0.982 0.006 114.935);
--card: oklch(0.145 0.017 115.508);
--card-foreground: oklch(0.982 0.006 114.935);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.898 0.21 120.904);
--primary-foreground: oklch(0.343 0.078 120.235);
--secondary: oklch(0.228 0.002 114.997);
--secondary-foreground: oklch(0.777 0.004 114.923);
--accent: oklch(0.328 0.02 115.952);
--accent-foreground: oklch(0.852 0.018 115.206);
--destructive: oklch(0.644 0.228 31.617);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.898 0.21 120.904);
--chart-1: oklch(0.898 0.21 120.904);
--chart-2: oklch(0.228 0.002 114.997);
--chart-3: oklch(0.328 0.02 115.952);
--chart-4: oklch(0.261 0.003 115.011);
--chart-5: oklch(0.907 0.214 121.062);
}