Over 10000 Themes for shadcn/ui available.
Explore themesWanna work with me?
Add 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 78% 77%;
--destructive-foreground: 14 78% 17%;
--success: 136 78% 77%;
--success-foreground: 136 78% 17%;
--warning: 53 78% 77%;
--warning-foreground: 53 78% 17%;
--info: 211 78% 77%;
--info-foreground: 211 78% 17%;
}
.dark {
--destructive: 14 78% 22%;
--destructive-foreground: 14 78% 82%;
--success: 118 78% 22%;
--success-foreground: 0 0% 100%;
--warning: 47 78% 22%;
--warning-foreground: 47 78% 82%;
--info: 205 78% 22%;
--info-foreground: 205 78% 82%;
}
}
Add new variants to your components.