Closed TimonVS closed 9 years ago
grunt jshint :) also html expected is cross browser error prone, so we will look at the test anyway.
calulcation is wrong, inspect network traffic and you will see this. By using the same image i guess you didn't notice it. It also counts for the solution which is now also in this version.
<div class='demo-container-content-positioned-parent'>
<div afkl-lazy-image="//placehold.it/936x677/00a1de/ffffff" class='afkl-lazy-wrapper afkl-img-ratio-3-2 demo-container-content-positioned-child'></div>
</div>
<div class='demo-container-content-positioned-parent'>
<div afkl-lazy-image="//placehold.it/936x468/fc425b/ffffff" class='afkl-lazy-wrapper afkl-img-ratio-2-1 demo-container-content-positioned-child'></div>
</div>
<div class='demo-container-content-positioned-parent'>
<div afkl-lazy-image="//placehold.it/936x677/2df3d/ffffff" class='afkl-lazy-wrapper afkl-img-ratio-3-2 demo-container-content-positioned-child'></div>
</div>
Fix lazy loading images in a container to use the offset relative to the $container instead of the first positioned parent.
The unit test isn't nice.
Loading images needs attention
Fix lazy loading images in a container to use the offset relative to the $container instead of the first positioned parent.
The unit test isn't nice.