I set up horizontal scrolling animation with 3 sections and 4 text elements above it.
As the link anchor don’t works well with the animation I would like to set up an event that progress the timeline when clicked on menu text element .
So each menu element would progress the animation to different time of the animation.
If anybody would know how to do that , let me know
Thank you for help
Hey Bricksforge is saving all timeline instances here:
Then, you can use native gsap methods to set the progress.
Thank you so much for help .
That solved everything .
Have a nice day.
Only problem I found out is that when I update the progress with the menu buttons and then scroll up or down the progress get bugged by the scroll trigger or reseted back to 0.
I will try to found out myself , but if you would have any fast solution that would be perfect .
Could you try to refresh the scrollTrigger after running some custom progress changes?
I added the scroll trigger refresh after the animation to each section is completed.
What it did is it returned the timeline to start.
Was it correct from my side?
Hmm… could you try to deactivate the gsap scrollsmoother or change it to lenis? Does this change the behavior?
I hope you had nice weekend.
I turned off the gsap scroll and tried also lenis.
Both times it always return to the last scrolled position and don’t update the scroll trigger.
I was think of creating different solution with each button scroll certain amount so the scroll trigger would be also updated .
I don’t want to take too much of your time , so if you need we can drop this post .