Jump to content
Search Community

scrollerTrigger really don´t understand pinning....

lennyvong test
Moderator Tag

Go to solution Solved by GreenSock,

Recommended Posts

Hello,
I'm starting to learn gsap and I can't do what I want to do at all...
I've been trying to pin the section with the "PINNING" for a long time now.
But I don't understand what I'm doing wrong to make my pin go through my "div" below...
I've looked at a lot of codepen and I can't figure it out...

Please help me, I've been stuck for a long time...

I would like that it passes to my divs of after at the end of the annimation of the "PINNING" and that this one does not overlap the content of below

See the Pen MWXrKyL by lennyvong (@lennyvong) on CodePen

Link to comment
Share on other sites

  • Solution

By default, if the parent element uses display: flex, then ScrollTrigger disables pinSpacing since flex sizing is handled very differently by the browser. So in your case, it looks like you want pinSpacing, so just enable it explicitly with pinSpacing: true

See the Pen MWXrego?editors=1010 by GreenSock (@GreenSock) on CodePen

 

Does that help? 

Link to comment
Share on other sites

13 hours ago, GreenSock said:

By default, if the parent element uses display: flex, then ScrollTrigger disables pinSpacing since flex sizing is handled very differently by the browser. So in your case, it looks like you want pinSpacing, so just enable it explicitly with pinSpacing: true

 

 

 

Does that help? 

Thank you so much !

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