Jump to content
Search Community

ScrollTrigger pinned horizontal scroll end point

kodralex test
Moderator Tag

Go to solution Solved by Cassie,

Recommended Posts

I have a pinned horizontal scrolling section with panels of different widths. I'd like the pinned scrolling to finish (unpin) when the last panel (Part Six) is 32px from the left-hand edge of the view point. Is this possible?

 

I've reviewed all the documentation related to the ScrollTrigger end, and nothing is related to what I'm trying to do.

 

Thanks

See the Pen qBwMXOm by alexkodr (@alexkodr) on CodePen

Link to comment
Share on other sites

Thanks for replying and updating Cassie,

 

On your example the outer-wrap panel unpins once the 'part six' panel is 32px from the right edge of the viewport. Is it possible to change that to the left edge of the viewport? Like the attached image. So the last panel scrolls all the way from right to left and then the outer-wrap unpins.

gsap.jpg

Link to comment
Share on other sites

Amazing.

 

Thank you, Cassie. What you said makes sense. I'll spend some time dissecting your JS to better understand how you actually did that.

 

Once again, thank you. The community behind GSAP is fantastic; it helps so much with learning.

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