Using group-hover with a css child selector #13309
-
I am using tailwind together with ReactJS. In my application I am using a shared
I am able to use this component wherever I want, but I am not able to touch this component! My task now is to add a specific hover style to this button. So I have tried the following implementation:
Unfortunately this isn't working. All the documentation I could find only described that I have to set the |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hi @janhoeck, This should do the trick: https://play.tailwindcss.com/g4y7m49VFw :) <button class="group [&:hover_span]:text-red-200">
<span>Child</span>
</button> Cheers, |
Beta Was this translation helpful? Give feedback.
Hi @janhoeck,
This should do the trick: https://play.tailwindcss.com/g4y7m49VFw :)
Cheers,
Andy