Over 10000 Themes for shadcn/ui available.
Explore themesAdd the colors to your config file. (Nested under theme ➡︎ extend ➡︎ colors). Just search for destructive in your current config and insert it below.
tailwind.config.js
destructive: {
DEFAULT: "hsl(var(--destructive))",
foreground: "hsl(var(--destructive-foreground))",
},
success: {
DEFAULT: "hsl(var(--success))",
foreground: "hsl(var(--success-foreground))",
},
warning: {
DEFAULT: "hsl(var(--warning))",
foreground: "hsl(var(--warning-foreground))",
},
info: {
DEFAULT: "hsl(var(--info))",
foreground: "hsl(var(--info-foreground))",
}
globals.css
@layer base {
:root {
--destructive: 14 94% 76%;
--destructive-foreground: 14 94% 16%;
--success: 142 94% 76%;
--success-foreground: 142 94% 16%;
--warning: 46 94% 76%;
--warning-foreground: 46 94% 16%;
--info: 201 94% 76%;
--info-foreground: 201 94% 16%;
}
.dark {
--destructive: 3 94% 11%;
--destructive-foreground: 3 94% 71%;
--success: 158 94% 11%;
--success-foreground: 158 94% 51%;
--warning: 53 94% 11%;
--warning-foreground: 53 94% 51%;
--info: 215 94% 11%;
--info-foreground: 215 94% 71%;
}
}
Add new variants to your components.