Jump to content
Search Community

remove Pin spacing under final section

Jameshofton test
Moderator Tag

Go to solution Solved by Jameshofton,

Recommended Posts

Hi, 

 

I am have gone through lots of other peoples posts to see if i can find a solution and some of them have helped me get closer to what i need. I was hoping for some help if possible.  

 

I have 4 sections, each with a lottie file in.  They reach a section, it pins until the end of the lottie animation and then moved onto the next one.   I did have it all 100% View port height, but the client did not like that.   I have created a version in Codepen,  so you can see the code.  

 

I would really appreciate any help, tips to solve this. 

CleanShot 2024-03-22 at 13.12.39@2x.jpg

See the Pen eYoWdBR by jameshofton (@jameshofton) on CodePen

Link to comment
Share on other sites

Hi,

 

One solution is to wrap the lotties section and the next one in a common parent and pin that one:

See the Pen ExJmWdp by GreenSock (@GreenSock) on CodePen

 

The other solution is to create two ScrollTrigger instances to pin both sections at the same time for each lottie section and use pinSpacing false for the looties wrapper:

See the Pen ZEZeLmL by GreenSock (@GreenSock) on CodePen

 

Hopefully this helps.

Happy Tweening!

  • Like 1
Link to comment
Share on other sites

  • Solution
15 hours ago, Rodrigo said:

Hi,

 

One solution is to wrap the lotties section and the next one in a common parent and pin that one:

 

 

 

The other solution is to create two ScrollTrigger instances to pin both sections at the same time for each lottie section and use pinSpacing false for the looties wrapper:

 

 

 

Hopefully this helps.

Happy Tweening!

Thanks so much for your reply,  i will go through it on Monday wen back at work.  I really appreciate you taking the time to reply to me.  

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