Jump to content
Search Community

Scrolltrigger containerAnimation starts to early

dave@friks.nl test
Moderator Tag

Recommended Posts

Dear GreenSock people,

 

I'm trying to understand and create Scrolltrigger's containerAnimations combined with vertical and horizontal scrolling. The problem i'm facing is that the containerAnimation (for the horizontal panels) fires immediately on the first panel so the animation is already completed when it gets pinned.

 

The markers are also gone for the horizontal part (they are floating somewhere on the bottom i think,  so i can't see whats happening exactly)

 

Can somebody make this clear to me? Thanks already!

 

See the Pen RwjBgVJ by Knerp (@Knerp) on CodePen

Link to comment
Share on other sites

Heya!

 

The assume the markers aren't visible because of ScrollSmoothers impact on fixed positioning - If that's true, maybe we can add something to reparent them or something.

For now - If I were you I'd just get everything working then add ScrollSmoother at the end. Then the markers are there for debugging.

With the markers there you can see that the first markers are already past the start point when the first panel comes into view, so the first animation's already fired. So either move the markers to start later, or fire the first panel animation on vertical scroll instead of horizontal - and the rest of the panels on horizontal.


See the Pen RwjBgVJ?editors=0010 by Knerp (@Knerp) on CodePen



Hope this helps!

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...