fania Posted January 16, 2021 Share Posted January 16, 2021 Hello, new member here. Been using your library for a long time =) First time trying out a horizontal site, finally got a request to do one. So using ScrollTrigger for this functionality. Basically trying to replicate the examples in this post -> https://greensock.com/forums/topic/24309-scrolltrigger-horizontal-scrolling/. However, its not quite working right. I have 4 divs inside the container. These divs are set to 100% width ( may need to use pixels, let me know ) When I run, it works... I see the first "section" div, it scrolls but the other divs are hidden. When I inspect, the container has overflow set to hidden, which explains why the rest of the divs are not visible. When I disable overflow, all the sections show up and works fine. I curious on what I'm doing wrong here, when I inspect the code in this post, the container does not have overflow set at all, but on mine it does. Any help would be appreciated. Code Pen Example Looked at the line where it actually sets overflow: hidden --- ScrollTrigger.js Line 896 pin.firstChild && !_maxScroll(pin, direction) && (pin.style.overflow = "hidden"); // protects from collapsing margins! Thank you! See the Pen ExgGvEZ?editors=0100 by lavoe2k (@lavoe2k) on CodePen Link to comment Share on other sites More sharing options...
Solution fania Posted January 16, 2021 Author Solution Share Posted January 16, 2021 So I got it working now. I was using GSAP 3.4.2, realized that the examples I was looking at used the latest and greatest 3.6.0. As soon as I updated the package, issue went away. 1 Link to comment Share on other sites More sharing options...
GreenSock Posted January 16, 2021 Share Posted January 16, 2021 Yep, that was resolved already as you discovered. Thanks for letting us know. Happy scrolling! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now