Share Posted May 7, 2022 Hello im trying to make the section marquee to be pin and animate the box to without adding space or overlap other section is this possible? See the Pen YzewNXX by lolong94 (@lolong94) on CodePen Link to comment Share on other sites More sharing options...
Share Posted May 7, 2022 Hello @digitalfrci It sure is possible, but you would have to wrap all the content that could be visible at any point and pin that wrapper instead. See the Pen yLveMJm by akapowl (@akapowl) on CodePen Also, if you are going to have ScrollTriggers on other elements within that wrapper, you would then have to set the pinnedContainer property on those subsequent ScrollTriggers to have their positions be calculated where you'd expect them to be. I hope that will help - happy scrolling! pinnedContainer Element | String - If your ScrollTrigger's trigger/endTrigger element is INSIDE an element that gets pinned by another ScrollTrigger (pretty uncommon), that would cause the start/end positions to be thrown off by however long that pin lasts, so you can set the pinnedContainer to that parent/container element to have ScrollTrigger calculate those offsets accordingly. Again, this is very rarely needed. (added in 3.7.0) 3 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