Add bg-current-xxx and text-current-xxx #2013
Replies: 2 comments 1 reply
-
I don't think this is possible, because Tailwind can't make features that CSS doesn't support. I would imagine that /* already does this (simplified) */
background-color: #whatever200;
/* new stuff */
--bg-current: blue;
--blue-100: #whatever100;
--blue-200: #whatever200;
/* ... */
--blue-900: #whatever900; and background-color: var(--var(--bg-current)-900); which is not valid syntax. Do you expect another way for this to work? |
Beta Was this translation helpful? Give feedback.
-
This is possible and already shared it with Adam a while ago on Twitter when (guessing) they started working on the alpha colors update (haven't been able to keep up with GitHub notifications for the past few months lol). I think you'll have to rewrite all the color dependent plugins if you wanna take full advantage though, so it's definitely not the solution you were expecting. Sorry about that haha Please share your take on it if you ever implement it 🙏 |
Beta Was this translation helpful? Give feedback.
-
It would be a helpful feature to all multiple elements to change their current background or text color on hover or focus even if they're all different colors.
Beta Was this translation helpful? Give feedback.
All reactions