How can I make color work with with opacity? #3327
Unanswered
iaminamcom
asked this question in
Help
Replies: 2 comments
-
A few months back I had a similar issue, and Adam Wathan pointed me to this example: https://github.com/adamwathan/tailwind-css-variable-text-opacity-demo It's essentially defining the colors as a callback that accepts opacity values. Unfortunately, this does not seem to be working on Tailwind v2. There is a pull request to fix it: #2919 so I'm still on v1.9 in the meantime. If there is a way to achieve what you're looking for in v2, I'd be interested as well. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Ok. Please don't forget to let me know. Thank you ❤️
…On Tue, Jan 12, 2021, 3:04 AM Nick Mazuk ***@***.***> wrote:
A few months back I had a similar issue
<#2399>, and Adam
Wathan pointed me to this example:
https://github.com/adamwathan/tailwind-css-variable-text-opacity-demo
It's essentially defining the colors as a callback that accepts opacity
values.
Unfortunately, this does not seem to be working on Tailwind v2
<#2927>. There is
a pull request to fix it: #2919
<#2919> so I'm still on
v1.9 in the meantime. If there is a way to achieve what you're looking for
in v2, I'd be interested as well.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#3327 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIJCHJRNND25G6YOTYXONTTSZNYV3ANCNFSM4V5GKNRA>
.
|
Beta Was this translation helpful? Give feedback.
0 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.
-
Hi
I want my custom color to work with opacity classes. Like I want to add custom border/background colors work with opacity. Currently we're doing like like
bg-black bg-opacity-10
to getbackground-color: rgba(0,0,0,. 3)
but what if we want to do that with custom color.FYI I did some try by setting variable property in alpha but never worked out.
Beta Was this translation helpful? Give feedback.
All reactions