Jump to content
GreenSock

NickWoodward

Tailwind hidden class overrides autoAlpha?

Go to solution Solved by Trapti,

Recommended Posts

Was just wondering if anyone had any experience using Tailwind with gsap?

Maybe I've made a mistake (because all of my searches have come across the opposite problem - *not* being able to override inline styles), but I can't seem to get gsap's autoAlpha style to take precedent over tailwind's hidden class. Is this the expected behaviour?


Thanks!

 

 

See the Pen JjBEZXM by nwoodward (@nwoodward) on CodePen

Link to comment
Share on other sites

  • Solution

Tailwind's 'hidden' class sets the 'display: none' property. GSAP 'autoAlpha' sets 'visibility' and 'opacity' property. Basically you are dealing with two diff properties so how will they override. 

  • Like 4
Link to comment
Share on other sites

😄 This is why I shouldn't ask questions after a long day, must have confused visibility:hidden with hidden.

Thanks!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×