idiotWu / smooth-scrollbar

Customizable, Extendable, and High-Performance JavaScript-Based Scrollbar Solution.
https://idiotwu.github.io/smooth-scrollbar/
MIT License
3.32k stars 384 forks source link

Didnt work with GSAP, or Scrollmagic (Greensock TweenMax) #177

Closed skhtml closed 6 years ago

skhtml commented 6 years ago

Thanks for awesome code, you guys making this internet better :)

clmsftsw commented 4 years ago

How did you solve the issue?

skhtml commented 4 years ago

Yes: You just need to call scrollMagic scene.refresh();

var controllerMain = new ScrollMagic.Controller(); var promoWrapperAnimScene = new ScrollMagic.Scene({triggerElement: ".promo-sections-wrapper", triggerHook: 1, duration: promoWrapperHeight}) .setTween(".js_Fill", 1, {height: "100%", ease: Linear.easeNone}) .addTo(controllerMain); scrollbar.addListener(function (s) { promoWrapperAnimScene.refresh(); });