Brian-afk Posted June 9, 2021 Share Posted June 9, 2021 Hey guys ! I wanted to build a component where when we scroll text fades out and new text fades in .I am able to do this for two elements but I dont seem to understand when we have to apply the animation for the second text to fade out and a third text to fade in .(an example would be like in apple airpods website where new text fades in and out when we scrolll).I hope I get some help! This is what I have so far ,I actually saw this code in youtube and edited it! I just want the hi also to dissappear when we scroll and new text say something else also appear! See the Pen yLMqWYQ by brian-byju (@brian-byju) on CodePen Link to comment Share on other sites More sharing options...
Али К Posted June 9, 2021 Share Posted June 9, 2021 Hello @Brian-afk , welcome to greensock , here an example for the animation See the Pen 3ca556a8fa6b42ecbb6b181a011348aa by itsalimanuel (@itsalimanuel) on CodePen 1 Link to comment Share on other sites More sharing options...
Brian-afk Posted June 9, 2021 Author Share Posted June 9, 2021 Actually I dont want the text to like go down ! it should stay right there and just fade out and new text should come up at the same position as previously! Link to comment Share on other sites More sharing options...
Solution GreenSock Posted June 10, 2021 Solution Share Posted June 10, 2021 There are a LOT of ways you could set this up. Here's just one: See the Pen rNyZLdy?editors=0010 by GreenSock (@GreenSock) on CodePen Hopefully that gets you headed in the right direction. Good luck! 3 Link to comment Share on other sites More sharing options...
Brian-afk Posted June 10, 2021 Author Share Posted June 10, 2021 Thank you so much! I spent like 8 hours trying to find a solution to this ! and finally here I am! Glad I joined greensock! 1 Link to comment Share on other sites More sharing options...
Brian-afk Posted June 10, 2021 Author Share Posted June 10, 2021 ❤️ 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