apostopher Posted October 13, 2021 Posted October 13, 2021 I'm trying to use scrollTrigger along with navigation links. when i load the page and click the navigation link (e.g panel 4) it correctly animates to panel 4. However if i click another link after that (e.g Panel 3) the scrollTrigger does not scroll correctly. when i click `panel 1` it animates to `panel 2`. I think i have configured the scroll trigger incorrectly. can someone pls help me? See the Pen jOLPzQG by apostopher (@apostopher) on CodePen.
Solution Cassie Posted October 13, 2021 Solution Posted October 13, 2021 Hi Apostopher Because of the layered pinning the calculated height of the target link is a bit off. If you do a calculation instead it works! Thanks for being part of club GreenSock ? See the Pen ExvjLrj?editors=1011 by GreenSock (@GreenSock) on CodePen. 1
apostopher Posted October 13, 2021 Author Posted October 13, 2021 18 minutes ago, Cassie said: Hi Apostopher Because of the layered pinning the calculated height of the target link is a bit off. If you do a calculation instead it work! Thanks for being part of club GreenSock ? Thanks a lot @Cassie 1
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