Color switch with v4? Primary palette? #16290
Unanswered
subproject22
asked this question in
Help
Replies: 1 comment 2 replies
-
The CSS variables defined in @theme {
--color-primary: red;
}
@layer theme {
[data-theme="dark"] {
--color-primary: green;
}
} |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Can't figurate new config.
Let's say I want to have
--color-primary-*
styles, and I need to switch colors (between shipped Tailwind colors). Is it even possible? Weird but I can't figure out. Would be nice to have an example. The only way I found is having data-attr and manually defying all colors with attr selector...Is there more elegant way?Beta Was this translation helpful? Give feedback.
All reactions