Nora Posted August 15, 2022 Share Posted August 15, 2022 is it possible to make a text take 4 duration to appeared but 1 duration to disappeared? See the Pen mdxGdxQ by nora10 (@nora10) on CodePen Link to comment Share on other sites More sharing options...
Cassie Posted August 15, 2022 Share Posted August 15, 2022 Hey there. Sure! You can use the callbacks to trigger an animation instead of toggle Actions. That will give you more control over differing entrance and exit animations. for example - something like this. ScrollTrigger.create({ onToggle: (self) => { gsap.to(element, { opacity: self.isActive ? 1 : 0, duration: self.isActive ? 4 : 1 }) }, }) 1 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now