Replies: 3 comments 5 replies
-
Hey! You can do this but you have to set things up a little differently, see the documentation on this topic here: https://tailwindcss.com/docs/customizing-colors#using-css-variables |
Beta Was this translation helpful? Give feedback.
2 replies
-
I stumbled on this from search today, 2 years later. Would be really nice if we got a w/around. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Works in v4 <div class="[--accent:hotpink]">
<p class="text-(--accent)/50">Test</p>
</div> |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
It seems like CSS opacity is not supported when the color is obtained from a CSS variable. Here is an example you can copy/paste into Tailwind Play:
Beta Was this translation helpful? Give feedback.
All reactions