Jump to content
Search Community

Sovai

Premium
  • Posts

    5
  • Joined

  • Last visited

About Sovai

Sovai's Achievements

  1. Sovai

    How to seek fromTo

    Hi @mvaneijgen, I have another issue where I cannot figure it out. if the scroll container not long enough, the scroll snap not scale the element all the way to zero. please see the example below https://codepen.io/sovai/pen/gOQBpve Do you have any idea?
  2. Sovai

    How to seek fromTo

    Hi @mvaneijgen, that's exactly what I want. Once again, thank you very much
  3. Sovai

    How to seek fromTo

    Here's an example of what m trying to achieve scroll-scale.mp4
  4. Sovai

    How to seek fromTo

    Hi @mvaneijgen, thank you for your reply. However, my goal is on the onEnd() function here function onEnd() { if(direction === 1) { // scale the element all the way to 0 tl.to(el, {scale: 0, width: 0, height: 0, duration: 1}); } else if(direction === -1) { // scale the element all the way to 1 tl.to(el, {scale: 1, width: '300px', height: '300px', duration: 1}); } } for example, when I scroll down and release, the element will check the scroll position then scale the element based on scroll direction (to full size or zero) Here's what I tried to do so far https://codepen.io/sovai/pen/oNQPKJX
  5. Sovai

    How to seek fromTo

    Hi, I'm new to gsap. I am trying to make this scale animation using scrollTrigger. I want the element #chart to scale 1 to 0 or 0 to 1 based on scroll position. if use pause in the middle of scrolling (scrollEnd) I want to check scroll direction and set the scale of #chart to full or zero. I try to use this tl.progress(1, false); to seek the animation to full or 0 but seems its not working. Pls share your thoughts! thanks
×
×
  • Create New...