Jump to content
Search Community

scottyak

Members
  • Posts

    3
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

scottyak's Achievements

  1. Yes, that's perfect, thanks! I figured that would add pin spacing under the element and make the section longer than I wanted, but I guess not. Thanks again!
  2. https://codepen.io/scottyak/pen/NWmjpod Just trying to have the section title stay pinned to the top of the element while the section is in view. Is there a better way to do this?
  3. I'd like to use the progress from a ScrollTrigger instance to update the value for a tween (in this case, pushing a title element down within a pinned element). I tried the below, I can get the progress un on Update, but I'm not sure how to apply it to the tween: let el = document.querySelector(".section-title"); gsap.to(el, { y: () => self.progress * (window.innerHeight * 3), ease: 'none', scrollTrigger: { trigger: ".col-left", start: "top top", end: "bottom bottom", onUpdate: (self) => console.log(self.progress), scrub: true, } });
×
×
  • Create New...