Jump to content
Search Community

Multiple hidden texts reveal if in view

ainzon test
Moderator Tag

Go to solution Solved by ainzon,

Recommended Posts

Hi there,

 

I just started to work with GSAP and trying to animate some texts. fade-in / fade-in-left etc. animations are working fine.

 

Now I try to reveal hidden texts when passing the scroll point. So I use ScrollTrigger as well.

 

I think that the major problem here is, that on initialising the code the former position of the following texts is saved so when I scroll to the first one - the other reveal as well. Is there a way to recalculate after the first action is fired?

 

Thanks in advance!

 

Edit:

The Codepen here is not working always - but if you open it on codepen it works.

 

I also appreciate any tipps how to optimize the gsap js-code.

See the Pen MWOmQVM by boris-andraschko (@boris-andraschko) on CodePen

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.
×
×
  • Create New...