Jump to content
Search Community

mimoid-prog

Members
  • Posts

    3
  • Joined

  • Last visited

mimoid-prog's Achievements

  • Week One Done
  • One Month Later
  • One Year In

Recent Badges

1

Reputation

  1. Hello. I have a div with some texts and I looped this div infinitely which is working fine. But my problem is with changing the direction of marquee. When I do tl.reverse() it makes the reverse but the loop ends when it hits the beginning. How can I make it infinite even after the direction change? I know there is many posts about this topic but I still can't make it done.
  2. When you use smooth-scrollbar, React and GSAP ScrollTrigger in multiple React components all animations stop working. Firstly I thought it's Gatsby issue but the same thing happens for pure React. Everything works well if you don't use smooth-scrollbar, also everything works well when you use smooth-scrollbar and store all scrollTrigger animations in one useEffect. But when you move them to other components then all animations stop working. Try to use my codepen example. Animations don't work but when you comment out scrollTrigger object from the "Other" component then it starts to work.
  3. Hello, I have the very similar setup (Gatsby, ScrollTrigger and smooth-scrollbar) but the given solution doesnt work for me - I can see scroller-start and scroller-end markers following the scrolled screen but not the markers of the animated element. I can see markers of the animated element only if I add scroller property to it but then scroller-start and scroller-end dont follow the screen. Also I tried to make some console.logs inside this scrollTop function but it looks like it doesn't work too. useEffect(() => { const bodyScrollBar = Scrollbar.init(box.current) ScrollTrigger.scrollerProxy("body", { scrollTop(value) { if (arguments.length) { bodyScrollBar.scrollTop = value } console.log('test') return bodyScrollBar.scrollTop }, }) bodyScrollBar.addListener(ScrollTrigger.update) }, []) What could be my problem? @andsavu Would you like to share your code that is working for you? Thanks in advance
×
×
  • Create New...