Closed Redani closed 7 years ago
It's possible now! :)
You'll need to use the $.smoothScroll()
method and pass in a "relative string" for the pixel amount (for example, "+=60px"
). More info is now in the readme and on the main demo page.
Let me know if you run into any problems or have additional questions.
Hi @kswedberg, thanks so much for your reply and apologies for the delay. Cool, that's very nice of you, i'll try it out as soon as I can and will let you know if I run into any problems ;) Cheers
No problem, @Redani. If it works for you, would you mind closing this issue? Thanks!
Hi, I have just tried to make it work but didn't succeed :/ here is my code:
$(document).on("click", "ul.to_scroll > li a.down", function() {
$.smoothScroll('+=' + $("ul.to_scroll").height());
});
it scrolls the whole page!
Also is there a callback function that could trigger when the scrolling reaches the end?
Thanks
Not sure why it's not working for you. Can you give me a URL to look at?
As for the callback function, use afterScroll
:
$.smoothScroll({
afterScroll: function() {
console.log('hello!')
}
}, '+=' + $("ul.to_scroll").height());
Closing this due to inactivity.
Hi, and thanks for this lovely plugin :)
Is it possible to scroll repeatedly X pixels? just like shown on this fiddle: http://jsfiddle.net/xEFq5/13/
thanks