tubalmartin / riloadr

Riloadr - A cross-browser framework-independent responsive images loader written in Javascript.
MIT License
646 stars 41 forks source link

belowfold only works vertically? #7

Closed sswany closed 11 years ago

sswany commented 12 years ago

I'm using Riloadr in conjunction with jScrollPane for a horizontally scrolling gallery and the defer: 'belowfold' option does not stop images from being loaded until they near the viewport. Using the onload call, it seems to load all of them at once.

Is this expected behavior?

tubalmartin commented 12 years ago

Yes, Riloadr's belowfold defer mode only works vertically.

The load defer mode will load all images that belong to a group when the windows is loaded.

So, yes, that is the expected behaviour.

thisispete commented 12 years ago

would be nice if belowfold worked in any direction

similar to https://github.com/sebarmeli/JAIL/blob/master/src/jail.js

determines if the images are in the viewport, this is nice when you deep link to the bottom of the page and scroll up, or have a horizontal scroll.

tubalmartin commented 11 years ago

Indeed a nice suggestion, I'll consider implementing it.

tubalmartin commented 11 years ago

Version 1.4.0 is out and includes this feature, check it out and spread the word ;)

Thanks for your feedback!