Comments (17)
Hey, did u figure it out please? if yes, pls let me know
from smooth-scrolling.
from smooth-scrolling.
Sorry for the delay in answering here.
I've uploaded a new demo which uses GSAP ScrollTrigger: c5dffd6
It should work on both native: true
and native: false
versions. Basically ScrollTrigger needs to know which property is the scrollTop value within the module (scroll.vars.target
or scroll.vars.current
) and a method to tell ScrollTrigger to update.
To run the demo examples, simply clone/download the repository and start http-server
within the root folder on your terminal. Let me know if that helps and if you're having any issues!
from smooth-scrolling.
from smooth-scrolling.
from smooth-scrolling.
from smooth-scrolling.
Hey @ashehzadgec,
Thanks for providing an update on the demo. Good catch. Your solution fixed it, thanks!
I am not sure what the issue is when you "pin elements making the position fixed"?
I've added some code to the demo. Please not that this is a bit of a hack, but again the markers are here just for development purposes. Make sure you remove this code once you go live. I'm basically just moving GSAP's markers inside of the section since there is no scrolling on the element with native: false
, so they wouldn't update position once you start scrolling.
Again, sorry about the delay in answering. Happy to hear this helped and you're enjoying the module!
from smooth-scrolling.
from smooth-scrolling.
from smooth-scrolling.
Hey, seems like we can just completely drop the callback
function like the demo they sent. Not sure what is still wrong with this demo? What are you trying to achieve by pinning elements?
from smooth-scrolling.
from smooth-scrolling.
from smooth-scrolling.
from smooth-scrolling.
I also want to use GSAP ScrollTrigger with pin: true option with this library.
from smooth-scrolling.
Hey guys, I haven't had the chance to look it up as I'm currently busy with client work. I'll have a look when I get the chance.
from smooth-scrolling.
from smooth-scrolling.
from smooth-scrolling.
Related Issues (20)
- Horizontal scroll demos not working HOT 2
- (Parallax demo) vs-scrollbar-smooth and vs-scrollbar-parallax got different scroll position after smooth.scrollTo
- Build version including parallax HOT 4
- Empty space at page bottom when transitioning page HOT 2
- Has the latest version been published to NPM? HOT 2
- scrollTo() after resize HOT 2
- Cannot find module 'babelify'
- Next.js Compatibility HOT 2
- Immediately set the scroll position HOT 2
- Scroll event on container not working
- Hiding the scroll thumb when content doesn't extend beyond viewport. HOT 4
- Scrolling section responsive
- Uncaught TypeError: Class constructor Smooth cannot be invoked without 'new' HOT 1
- Error when building HOT 1
- StickySidebar with Smooth-Scroll
- Use native touch scrolling? HOT 6
- Smooth.resize() when using native gives error. HOT 1
- Custom easing function? HOT 1
- Horizontal scroll demo with both Y and X scrolling HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from smooth-scrolling.