Jump to content
Search Community

gsap scrollmagic swipes issue

codi test
Moderator Tag

Go to solution Solved by PointC,

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

  • Solution

Hi codi  :)

 

I know you sent me a private message about this, but I'm putting the answer in the forum in case others run into this issue. 

 

If your pinned section was 100% height, the way you have structured the document would work. But you have a section that has a max-height of 650 so you have to make a small change. You need to wrap the entire collection of divs that follow the desired pinned section into a master and use that as your triggerElement and setPin targets. Here's a fork of your pen that works correctly:

 

See the Pen WRLEwp by PointC (@PointC) on CodePen

 

I've also added the script for the debug indicators so you can better see what's happening.

 

Happy tweening.

:)

  • Like 1
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...