Comments (10)
Could you post your code? I think I can understand the problem better if I can see your setup. If you are using autoscrolling to scroll the content, there are different callbacks for when the left or right limit has been reached.
http://www.smoothdivscroll.com/callbacks.html#autoScrollingLeftLimitReached
http://www.smoothdivscroll.com/callbacks.html#autoScrollingRightLimitReached
But I guess that wasn't the problem in this case?
from smooth-div-scroll.
Indeed, I don't use autoscroll.
The main callback I needed was scrollerRightLimitReached, triggered by mouse wheel or touch slide.
If I set the option :
$("#makeMeScrollable").SmoothDivScroll({
hotSpotScrolling: false
});
the callback scrollerRightLimitReached is ignored :
$("#makeMeScrollable").SmoothDivScroll({
hotSpotScrolling: false,
scrollerRightLimitReached : function() {
console.log("right end is reached");
}
});
In your code, this callback is triggered in a loop concerning hotspot.
:)
from smooth-div-scroll.
Ah! I see.
This is because mousewheel and touch scrolling has been added on much later and I haven't updated the callbacks. I'll look into this!
from smooth-div-scroll.
And if you move your callback, it would be nice to implement a scrollerRightLimitSoon : almost the same, but triggered before the end is reached. It will allow to refill the content before the user realise it, and make the scroll look infinite.
:)
Thanks !
from smooth-div-scroll.
That callback could also be used for lazyload implementation could it not?
from smooth-div-scroll.
if by lazyload you mean loading just before it's necessary, that's my point ;)
from smooth-div-scroll.
This is a new feature and I understand that it could be very useful. I will add these two items to my list of requested features:
- Make the plugin trigger scrollerRightLimitReached/scrollerLeftLimitReached with mousewheel and touch scrolling as well (bugfix).
- Add new callbacks that is triggered when the scroller reaches a certain point (preferably user defined in pixels) before the left or right end of the scroller (new feature).
from smooth-div-scroll.
Well, I made my first fork (I hope I did it properly) for the callback before the end is reached.
You can see the reasult plugged into a drupal here : http://circulart.fr/liste-des-artistes
:)
from smooth-div-scroll.
Yes, your fork looks good!
The only problem is that I have a working copy of the code that is not published here on GitHub (yet) and there are many other changes in that. So I will probably not merge but nevertheless it was great to see your implementation and I think I will use it!
from smooth-div-scroll.
Apparently callbacks still aren't working in the current version... Any plans on fixing them?
from smooth-div-scroll.
Related Issues (20)
- jScrollPane and Smooth Div Scroll
- Click to center image function not working in scroll gallery HOT 1
- How to change horizontal scroll to vertical scroll in Smooth Div Scoll HOT 2
- Responsive Height
- scroll stopping when mouse out from left and right icons
- I've used this as a navbar on mobile devices and it's worked great until recently...
- Wrong setting when using kinetic.js
- Uncaught TypeError: Cannot read property 'show' of undefined HOT 2
- HTML5 Validation Messages Not Displayed
- Enable vertical Page-Scrolling HOT 4
- Can we use this plugin in commercial website? Is it free? Thanks. HOT 1
- pauseOnHover option when autoScrollingMode: "always" is applied HOT 1
- Still cannot click on href on touchscreens HOT 1
- The last div doesn't show up
- When touch scrolling is enabled, links within an individual block aren't clickable
- Auto Scroll Speed when Mouse approaches ARROWS
- jQuery 3 broke plugin... HOT 2
- Uncaught TypeError: $(...).smoothDivScroll is not a function HOT 1
- Uncaught TypeError: $(...).smoothDivScroll is not a function HOT 1
- Can possible to provide React integration example
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-div-scroll.