vanilla-lazyload
Advanced tools
Comparing version 10.16.2 to 10.17.0
@@ -5,2 +5,6 @@ # CHANGELOG | ||
#### 10.17.0 | ||
Added a new `thresholds` option that you can use when you need to have different thresholds for the scrolling area, so a single `threshold` option is not enough for your needs. Learn more in the API section of the [README](README.md) file. | ||
#### 10.16.2 | ||
@@ -7,0 +11,0 @@ |
@@ -10,2 +10,3 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; | ||
threshold: 300, | ||
thresholds: null, | ||
data_src: "src", | ||
@@ -320,4 +321,3 @@ data_srcset: "srcset", | ||
root: settings.container === document ? null : settings.container, | ||
rootMargin: settings.threshold + "px", | ||
threshold: 0 | ||
rootMargin: settings.thresholds || settings.threshold + "px" | ||
}; | ||
@@ -324,0 +324,0 @@ }; |
@@ -1,2 +0,2 @@ | ||
var _extends=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};define(function(){"use strict";function t(t){return t.filter(function(t){return!o(t)})}function e(t,e,n){!n&&o(t)||(O(e.callback_enter,t),C.indexOf(t.tagName)>-1&&(x(t,e),I(t,e.class_loading)),E(t,e),i(t),O(e.callback_set,t))}var n={elements_selector:"img",container:document,threshold:300,data_src:"src",data_srcset:"srcset",data_sizes:"sizes",class_loading:"loading",class_loaded:"loaded",class_error:"error",load_delay:0,callback_load:null,callback_error:null,callback_set:null,callback_enter:null,to_webp:!1},r=function(t){return _extends({},n,t)},s=function(t,e){return t.getAttribute("data-"+e)},a=function(t,e,n){var r="data-"+e;null!==n?t.setAttribute(r,n):t.removeAttribute(r)},i=function(t){return a(t,"was-processed","true")},o=function(t){return"true"===s(t,"was-processed")},c=function(t,e){return a(t,"ll-timeout",e)},l=function(t){return s(t,"ll-timeout")},u=function(t,e){var n,r=new t(e);try{n=new CustomEvent("LazyLoad::Initialized",{detail:{instance:r}})}catch(t){(n=document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized",!1,!1,{instance:r})}window.dispatchEvent(n)},d=function(t,e){return e?t.replace(/\.(jpe?g|png)/gi,".webp"):t},f="undefined"!=typeof window,_=f&&!("onscroll"in window)||/(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent),v=f&&"IntersectionObserver"in window,h=f&&"classList"in document.createElement("p"),m=f&&function(){var t=document.createElement("canvas");return!(!t.getContext||!t.getContext("2d"))&&0===t.toDataURL("image/webp").indexOf("data:image/webp")}(),g=function(t,e,n,r){for(var a,i=0;a=t.children[i];i+=1)if("SOURCE"===a.tagName){var o=s(a,n);b(a,e,o,r)}},b=function(t,e,n,r){n&&t.setAttribute(e,d(n,r))},p=function(t,e){var n=m&&e.to_webp,r=s(t,e.data_src);if(r){var a=d(r,n);t.style.backgroundImage='url("'+a+'")'}},w={IMG:function(t,e){var n=m&&e.to_webp,r=e.data_srcset,a=t.parentNode;a&&"PICTURE"===a.tagName&&g(a,"srcset",r,n);var i=s(t,e.data_sizes);b(t,"sizes",i);var o=s(t,r);b(t,"srcset",o,n);var c=s(t,e.data_src);b(t,"src",c,n)},IFRAME:function(t,e){var n=s(t,e.data_src);b(t,"src",n)},VIDEO:function(t,e){var n=e.data_src,r=s(t,n);g(t,"src",n),b(t,"src",r),t.load()}},E=function(t,e){var n=t.tagName,r=w[n];r?r(t,e):p(t,e)},I=function(t,e){h?t.classList.add(e):t.className+=(t.className?" ":"")+e},y=function(t,e){h?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\s+)"+e+"(\\s+|$)")," ").replace(/^\s+/,"").replace(/\s+$/,"")},O=function(t,e){t&&t(e)},A=function(t,e,n){t.addEventListener(e,n)},L=function(t,e,n){t.removeEventListener(e,n)},k=function(t,e,n){A(t,"load",e),A(t,"loadeddata",e),A(t,"error",n)},z=function(t,e,n){L(t,"load",e),L(t,"loadeddata",e),L(t,"error",n)},N=function(t,e,n){var r=e?n.class_loaded:n.class_error,s=e?n.callback_load:n.callback_error,a=t.target;y(a,n.class_loading),I(a,r),O(s,a)},x=function(t,e){var n=function n(s){N(s,!0,e),z(t,n,r)},r=function r(s){N(s,!1,e),z(t,n,r)};k(t,n,r)},C=["IMG","IFRAME","VIDEO"],R=function(t,n,r){e(t,r),n.unobserve(t)},M=function(t){var e=l(t);e&&(clearTimeout(e),c(t,null))},j=function(t,e,n){var r=n.load_delay,s=l(t);s||(s=setTimeout(function(){R(t,e,n),M(t)},r),c(t,s))},D=function(t){return t.isIntersecting||t.intersectionRatio>0},T=function(t){return{root:t.container===document?null:t.container,rootMargin:t.threshold+"px",threshold:0}},U=function(t,e){this._settings=r(t),this._setObserver(),this.update(e)};return U.prototype={_manageIntersection:function(t){var e=this._observer,n=this._settings,r=this._settings.load_delay,s=t.target;D(t)&&(r?j(s,e,n):R(s,e,n)),D(t)||M(s)},_onIntersection:function(e){e.forEach(this._manageIntersection.bind(this)),this._elements=t(this._elements)},_setObserver:function(){v&&(this._observer=new IntersectionObserver(this._onIntersection.bind(this),T(this._settings)))},loadAll:function(){var e=this;this._elements.forEach(function(t){e.load(t)}),this._elements=t(this._elements)},update:function(e){var n=this,r=this._settings,s=e||r.container.querySelectorAll(r.elements_selector);this._elements=t(Array.prototype.slice.call(s)),!_&&this._observer?this._elements.forEach(function(t){n._observer.observe(t)}):this.loadAll()},destroy:function(){var e=this;this._observer&&(t(this._elements).forEach(function(t){e._observer.unobserve(t)}),this._observer=null),this._elements=null,this._settings=null},load:function(t,n){e(t,this._settings,n)}},f&&function(t,e){if(e)if(e.length)for(var n,r=0;n=e[r];r+=1)u(t,n);else u(t,e)}(U,window.lazyLoadOptions),U}); | ||
var _extends=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};define(function(){"use strict";function t(t){return t.filter(function(t){return!o(t)})}function e(t,e,n){!n&&o(t)||(O(e.callback_enter,t),C.indexOf(t.tagName)>-1&&(x(t,e),I(t,e.class_loading)),E(t,e),i(t),O(e.callback_set,t))}var n={elements_selector:"img",container:document,threshold:300,thresholds:null,data_src:"src",data_srcset:"srcset",data_sizes:"sizes",class_loading:"loading",class_loaded:"loaded",class_error:"error",load_delay:0,callback_load:null,callback_error:null,callback_set:null,callback_enter:null,to_webp:!1},r=function(t){return _extends({},n,t)},s=function(t,e){return t.getAttribute("data-"+e)},a=function(t,e,n){var r="data-"+e;null!==n?t.setAttribute(r,n):t.removeAttribute(r)},i=function(t){return a(t,"was-processed","true")},o=function(t){return"true"===s(t,"was-processed")},c=function(t,e){return a(t,"ll-timeout",e)},l=function(t){return s(t,"ll-timeout")},u=function(t,e){var n,r=new t(e);try{n=new CustomEvent("LazyLoad::Initialized",{detail:{instance:r}})}catch(t){(n=document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized",!1,!1,{instance:r})}window.dispatchEvent(n)},d=function(t,e){return e?t.replace(/\.(jpe?g|png)/gi,".webp"):t},f="undefined"!=typeof window,_=f&&!("onscroll"in window)||/(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent),v=f&&"IntersectionObserver"in window,h=f&&"classList"in document.createElement("p"),m=f&&function(){var t=document.createElement("canvas");return!(!t.getContext||!t.getContext("2d"))&&0===t.toDataURL("image/webp").indexOf("data:image/webp")}(),g=function(t,e,n,r){for(var a,i=0;a=t.children[i];i+=1)if("SOURCE"===a.tagName){var o=s(a,n);b(a,e,o,r)}},b=function(t,e,n,r){n&&t.setAttribute(e,d(n,r))},p=function(t,e){var n=m&&e.to_webp,r=s(t,e.data_src);if(r){var a=d(r,n);t.style.backgroundImage='url("'+a+'")'}},w={IMG:function(t,e){var n=m&&e.to_webp,r=e.data_srcset,a=t.parentNode;a&&"PICTURE"===a.tagName&&g(a,"srcset",r,n);var i=s(t,e.data_sizes);b(t,"sizes",i);var o=s(t,r);b(t,"srcset",o,n);var c=s(t,e.data_src);b(t,"src",c,n)},IFRAME:function(t,e){var n=s(t,e.data_src);b(t,"src",n)},VIDEO:function(t,e){var n=e.data_src,r=s(t,n);g(t,"src",n),b(t,"src",r),t.load()}},E=function(t,e){var n=t.tagName,r=w[n];r?r(t,e):p(t,e)},I=function(t,e){h?t.classList.add(e):t.className+=(t.className?" ":"")+e},y=function(t,e){h?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\s+)"+e+"(\\s+|$)")," ").replace(/^\s+/,"").replace(/\s+$/,"")},O=function(t,e){t&&t(e)},A=function(t,e,n){t.addEventListener(e,n)},L=function(t,e,n){t.removeEventListener(e,n)},k=function(t,e,n){A(t,"load",e),A(t,"loadeddata",e),A(t,"error",n)},z=function(t,e,n){L(t,"load",e),L(t,"loadeddata",e),L(t,"error",n)},N=function(t,e,n){var r=e?n.class_loaded:n.class_error,s=e?n.callback_load:n.callback_error,a=t.target;y(a,n.class_loading),I(a,r),O(s,a)},x=function(t,e){var n=function n(s){N(s,!0,e),z(t,n,r)},r=function r(s){N(s,!1,e),z(t,n,r)};k(t,n,r)},C=["IMG","IFRAME","VIDEO"],R=function(t,n,r){e(t,r),n.unobserve(t)},M=function(t){var e=l(t);e&&(clearTimeout(e),c(t,null))},j=function(t,e,n){var r=n.load_delay,s=l(t);s||(s=setTimeout(function(){R(t,e,n),M(t)},r),c(t,s))},D=function(t){return t.isIntersecting||t.intersectionRatio>0},T=function(t){return{root:t.container===document?null:t.container,rootMargin:t.thresholds||t.threshold+"px"}},U=function(t,e){this._settings=r(t),this._setObserver(),this.update(e)};return U.prototype={_manageIntersection:function(t){var e=this._observer,n=this._settings,r=this._settings.load_delay,s=t.target;D(t)&&(r?j(s,e,n):R(s,e,n)),D(t)||M(s)},_onIntersection:function(e){e.forEach(this._manageIntersection.bind(this)),this._elements=t(this._elements)},_setObserver:function(){v&&(this._observer=new IntersectionObserver(this._onIntersection.bind(this),T(this._settings)))},loadAll:function(){var e=this;this._elements.forEach(function(t){e.load(t)}),this._elements=t(this._elements)},update:function(e){var n=this,r=this._settings,s=e||r.container.querySelectorAll(r.elements_selector);this._elements=t(Array.prototype.slice.call(s)),!_&&this._observer?this._elements.forEach(function(t){n._observer.observe(t)}):this.loadAll()},destroy:function(){var e=this;this._observer&&(t(this._elements).forEach(function(t){e._observer.unobserve(t)}),this._observer=null),this._elements=null,this._settings=null},load:function(t,n){e(t,this._settings,n)}},f&&function(t,e){if(e)if(e.length)for(var n,r=0;n=e[r];r+=1)u(t,n);else u(t,e)}(U,window.lazyLoadOptions),U}); | ||
//# sourceMappingURL=lazyload.amd.min.js.map |
@@ -5,2 +5,3 @@ const defaultSettings = { | ||
threshold: 300, | ||
thresholds: null, | ||
data_src: "src", | ||
@@ -322,4 +323,3 @@ data_srcset: "srcset", | ||
root: settings.container === document ? null : settings.container, | ||
rootMargin: settings.threshold + "px", | ||
threshold: 0 | ||
rootMargin: settings.thresholds || settings.threshold + "px" | ||
}); | ||
@@ -326,0 +326,0 @@ |
@@ -10,2 +10,3 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; | ||
threshold: 300, | ||
thresholds: null, | ||
data_src: "src", | ||
@@ -320,4 +321,3 @@ data_srcset: "srcset", | ||
root: settings.container === document ? null : settings.container, | ||
rootMargin: settings.threshold + "px", | ||
threshold: 0 | ||
rootMargin: settings.thresholds || settings.threshold + "px" | ||
}; | ||
@@ -324,0 +324,0 @@ }; |
@@ -1,2 +0,2 @@ | ||
var _extends=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},LazyLoad=function(){"use strict";function t(t){return t.filter(function(t){return!o(t)})}function e(t,e,n){!n&&o(t)||(L(e.callback_enter,t),C.indexOf(t.tagName)>-1&&(x(t,e),y(t,e.class_loading)),E(t,e),i(t),L(e.callback_set,t))}var n={elements_selector:"img",container:document,threshold:300,data_src:"src",data_srcset:"srcset",data_sizes:"sizes",class_loading:"loading",class_loaded:"loaded",class_error:"error",load_delay:0,callback_load:null,callback_error:null,callback_set:null,callback_enter:null,to_webp:!1},r=function(t){return _extends({},n,t)},s=function(t,e){return t.getAttribute("data-"+e)},a=function(t,e,n){var r="data-"+e;null!==n?t.setAttribute(r,n):t.removeAttribute(r)},i=function(t){return a(t,"was-processed","true")},o=function(t){return"true"===s(t,"was-processed")},c=function(t,e){return a(t,"ll-timeout",e)},l=function(t){return s(t,"ll-timeout")},u=function(t,e){var n,r=new t(e);try{n=new CustomEvent("LazyLoad::Initialized",{detail:{instance:r}})}catch(t){(n=document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized",!1,!1,{instance:r})}window.dispatchEvent(n)},d=function(t,e){return e?t.replace(/\.(jpe?g|png)/gi,".webp"):t},f="undefined"!=typeof window,_=f&&!("onscroll"in window)||/(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent),v=f&&"IntersectionObserver"in window,h=f&&"classList"in document.createElement("p"),m=f&&function(){var t=document.createElement("canvas");return!(!t.getContext||!t.getContext("2d"))&&0===t.toDataURL("image/webp").indexOf("data:image/webp")}(),g=function(t,e,n,r){for(var a,i=0;a=t.children[i];i+=1)if("SOURCE"===a.tagName){var o=s(a,n);b(a,e,o,r)}},b=function(t,e,n,r){n&&t.setAttribute(e,d(n,r))},p=function(t,e){var n=m&&e.to_webp,r=s(t,e.data_src);if(r){var a=d(r,n);t.style.backgroundImage='url("'+a+'")'}},w={IMG:function(t,e){var n=m&&e.to_webp,r=e.data_srcset,a=t.parentNode;a&&"PICTURE"===a.tagName&&g(a,"srcset",r,n);var i=s(t,e.data_sizes);b(t,"sizes",i);var o=s(t,r);b(t,"srcset",o,n);var c=s(t,e.data_src);b(t,"src",c,n)},IFRAME:function(t,e){var n=s(t,e.data_src);b(t,"src",n)},VIDEO:function(t,e){var n=e.data_src,r=s(t,n);g(t,"src",n),b(t,"src",r),t.load()}},E=function(t,e){var n=t.tagName,r=w[n];r?r(t,e):p(t,e)},y=function(t,e){h?t.classList.add(e):t.className+=(t.className?" ":"")+e},I=function(t,e){h?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\s+)"+e+"(\\s+|$)")," ").replace(/^\s+/,"").replace(/\s+$/,"")},L=function(t,e){t&&t(e)},O=function(t,e,n){t.addEventListener(e,n)},A=function(t,e,n){t.removeEventListener(e,n)},z=function(t,e,n){O(t,"load",e),O(t,"loadeddata",e),O(t,"error",n)},k=function(t,e,n){A(t,"load",e),A(t,"loadeddata",e),A(t,"error",n)},N=function(t,e,n){var r=e?n.class_loaded:n.class_error,s=e?n.callback_load:n.callback_error,a=t.target;I(a,n.class_loading),y(a,r),L(s,a)},x=function(t,e){var n=function n(s){N(s,!0,e),k(t,n,r)},r=function r(s){N(s,!1,e),k(t,n,r)};z(t,n,r)},C=["IMG","IFRAME","VIDEO"],R=function(t,n,r){e(t,r),n.unobserve(t)},M=function(t){var e=l(t);e&&(clearTimeout(e),c(t,null))},j=function(t,e,n){var r=n.load_delay,s=l(t);s||(s=setTimeout(function(){R(t,e,n),M(t)},r),c(t,s))},D=function(t){return t.isIntersecting||t.intersectionRatio>0},T=function(t){return{root:t.container===document?null:t.container,rootMargin:t.threshold+"px",threshold:0}},U=function(t,e){this._settings=r(t),this._setObserver(),this.update(e)};return U.prototype={_manageIntersection:function(t){var e=this._observer,n=this._settings,r=this._settings.load_delay,s=t.target;D(t)&&(r?j(s,e,n):R(s,e,n)),D(t)||M(s)},_onIntersection:function(e){e.forEach(this._manageIntersection.bind(this)),this._elements=t(this._elements)},_setObserver:function(){v&&(this._observer=new IntersectionObserver(this._onIntersection.bind(this),T(this._settings)))},loadAll:function(){var e=this;this._elements.forEach(function(t){e.load(t)}),this._elements=t(this._elements)},update:function(e){var n=this,r=this._settings,s=e||r.container.querySelectorAll(r.elements_selector);this._elements=t(Array.prototype.slice.call(s)),!_&&this._observer?this._elements.forEach(function(t){n._observer.observe(t)}):this.loadAll()},destroy:function(){var e=this;this._observer&&(t(this._elements).forEach(function(t){e._observer.unobserve(t)}),this._observer=null),this._elements=null,this._settings=null},load:function(t,n){e(t,this._settings,n)}},f&&function(t,e){if(e)if(e.length)for(var n,r=0;n=e[r];r+=1)u(t,n);else u(t,e)}(U,window.lazyLoadOptions),U}(); | ||
var _extends=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},LazyLoad=function(){"use strict";function t(t){return t.filter(function(t){return!i(t)})}function e(t,e,n){!n&&i(t)||(L(e.callback_enter,t),C.indexOf(t.tagName)>-1&&(x(t,e),y(t,e.class_loading)),E(t,e),o(t),L(e.callback_set,t))}var n={elements_selector:"img",container:document,threshold:300,thresholds:null,data_src:"src",data_srcset:"srcset",data_sizes:"sizes",class_loading:"loading",class_loaded:"loaded",class_error:"error",load_delay:0,callback_load:null,callback_error:null,callback_set:null,callback_enter:null,to_webp:!1},r=function(t){return _extends({},n,t)},s=function(t,e){return t.getAttribute("data-"+e)},a=function(t,e,n){var r="data-"+e;null!==n?t.setAttribute(r,n):t.removeAttribute(r)},o=function(t){return a(t,"was-processed","true")},i=function(t){return"true"===s(t,"was-processed")},c=function(t,e){return a(t,"ll-timeout",e)},l=function(t){return s(t,"ll-timeout")},u=function(t,e){var n,r=new t(e);try{n=new CustomEvent("LazyLoad::Initialized",{detail:{instance:r}})}catch(t){(n=document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized",!1,!1,{instance:r})}window.dispatchEvent(n)},d=function(t,e){return e?t.replace(/\.(jpe?g|png)/gi,".webp"):t},f="undefined"!=typeof window,_=f&&!("onscroll"in window)||/(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent),v=f&&"IntersectionObserver"in window,h=f&&"classList"in document.createElement("p"),m=f&&function(){var t=document.createElement("canvas");return!(!t.getContext||!t.getContext("2d"))&&0===t.toDataURL("image/webp").indexOf("data:image/webp")}(),g=function(t,e,n,r){for(var a,o=0;a=t.children[o];o+=1)if("SOURCE"===a.tagName){var i=s(a,n);b(a,e,i,r)}},b=function(t,e,n,r){n&&t.setAttribute(e,d(n,r))},p=function(t,e){var n=m&&e.to_webp,r=s(t,e.data_src);if(r){var a=d(r,n);t.style.backgroundImage='url("'+a+'")'}},w={IMG:function(t,e){var n=m&&e.to_webp,r=e.data_srcset,a=t.parentNode;a&&"PICTURE"===a.tagName&&g(a,"srcset",r,n);var o=s(t,e.data_sizes);b(t,"sizes",o);var i=s(t,r);b(t,"srcset",i,n);var c=s(t,e.data_src);b(t,"src",c,n)},IFRAME:function(t,e){var n=s(t,e.data_src);b(t,"src",n)},VIDEO:function(t,e){var n=e.data_src,r=s(t,n);g(t,"src",n),b(t,"src",r),t.load()}},E=function(t,e){var n=t.tagName,r=w[n];r?r(t,e):p(t,e)},y=function(t,e){h?t.classList.add(e):t.className+=(t.className?" ":"")+e},I=function(t,e){h?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\s+)"+e+"(\\s+|$)")," ").replace(/^\s+/,"").replace(/\s+$/,"")},L=function(t,e){t&&t(e)},O=function(t,e,n){t.addEventListener(e,n)},A=function(t,e,n){t.removeEventListener(e,n)},z=function(t,e,n){O(t,"load",e),O(t,"loadeddata",e),O(t,"error",n)},k=function(t,e,n){A(t,"load",e),A(t,"loadeddata",e),A(t,"error",n)},N=function(t,e,n){var r=e?n.class_loaded:n.class_error,s=e?n.callback_load:n.callback_error,a=t.target;I(a,n.class_loading),y(a,r),L(s,a)},x=function(t,e){var n=function n(s){N(s,!0,e),k(t,n,r)},r=function r(s){N(s,!1,e),k(t,n,r)};z(t,n,r)},C=["IMG","IFRAME","VIDEO"],R=function(t,n,r){e(t,r),n.unobserve(t)},M=function(t){var e=l(t);e&&(clearTimeout(e),c(t,null))},j=function(t,e,n){var r=n.load_delay,s=l(t);s||(s=setTimeout(function(){R(t,e,n),M(t)},r),c(t,s))},D=function(t){return t.isIntersecting||t.intersectionRatio>0},T=function(t){return{root:t.container===document?null:t.container,rootMargin:t.thresholds||t.threshold+"px"}},U=function(t,e){this._settings=r(t),this._setObserver(),this.update(e)};return U.prototype={_manageIntersection:function(t){var e=this._observer,n=this._settings,r=this._settings.load_delay,s=t.target;D(t)&&(r?j(s,e,n):R(s,e,n)),D(t)||M(s)},_onIntersection:function(e){e.forEach(this._manageIntersection.bind(this)),this._elements=t(this._elements)},_setObserver:function(){v&&(this._observer=new IntersectionObserver(this._onIntersection.bind(this),T(this._settings)))},loadAll:function(){var e=this;this._elements.forEach(function(t){e.load(t)}),this._elements=t(this._elements)},update:function(e){var n=this,r=this._settings,s=e||r.container.querySelectorAll(r.elements_selector);this._elements=t(Array.prototype.slice.call(s)),!_&&this._observer?this._elements.forEach(function(t){n._observer.observe(t)}):this.loadAll()},destroy:function(){var e=this;this._observer&&(t(this._elements).forEach(function(t){e._observer.unobserve(t)}),this._observer=null),this._elements=null,this._settings=null},load:function(t,n){e(t,this._settings,n)}},f&&function(t,e){if(e)if(e.length)for(var n,r=0;n=e[r];r+=1)u(t,n);else u(t,e)}(U,window.lazyLoadOptions),U}(); | ||
//# sourceMappingURL=lazyload.iife.min.js.map |
@@ -14,2 +14,3 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; | ||
threshold: 300, | ||
thresholds: null, | ||
data_src: "src", | ||
@@ -324,4 +325,3 @@ data_srcset: "srcset", | ||
root: settings.container === document ? null : settings.container, | ||
rootMargin: settings.threshold + "px", | ||
threshold: 0 | ||
rootMargin: settings.thresholds || settings.threshold + "px" | ||
}; | ||
@@ -328,0 +328,0 @@ }; |
@@ -1,2 +0,2 @@ | ||
var _extends=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};!function(t,e){"object"===("undefined"==typeof exports?"undefined":_typeof(exports))&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.LazyLoad=e()}(this,function(){"use strict";function t(t){return t.filter(function(t){return!i(t)})}function e(t,e,n){!n&&i(t)||(L(e.callback_enter,t),C.indexOf(t.tagName)>-1&&(N(t,e),E(t,e.class_loading)),w(t,e),a(t),L(e.callback_set,t))}var n={elements_selector:"img",container:document,threshold:300,data_src:"src",data_srcset:"srcset",data_sizes:"sizes",class_loading:"loading",class_loaded:"loaded",class_error:"error",load_delay:0,callback_load:null,callback_error:null,callback_set:null,callback_enter:null,to_webp:!1},r=function(t){return _extends({},n,t)},o=function(t,e){return t.getAttribute("data-"+e)},s=function(t,e,n){var r="data-"+e;null!==n?t.setAttribute(r,n):t.removeAttribute(r)},a=function(t){return s(t,"was-processed","true")},i=function(t){return"true"===o(t,"was-processed")},c=function(t,e){return s(t,"ll-timeout",e)},l=function(t){return o(t,"ll-timeout")},u=function(t,e){var n,r=new t(e);try{n=new CustomEvent("LazyLoad::Initialized",{detail:{instance:r}})}catch(t){(n=document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized",!1,!1,{instance:r})}window.dispatchEvent(n)},d=function(t,e){return e?t.replace(/\.(jpe?g|png)/gi,".webp"):t},f="undefined"!=typeof window,_=f&&!("onscroll"in window)||/(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent),v=f&&"IntersectionObserver"in window,m=f&&"classList"in document.createElement("p"),h=f&&function(){var t=document.createElement("canvas");return!(!t.getContext||!t.getContext("2d"))&&0===t.toDataURL("image/webp").indexOf("data:image/webp")}(),b=function(t,e,n,r){for(var s,a=0;s=t.children[a];a+=1)if("SOURCE"===s.tagName){var i=o(s,n);p(s,e,i,r)}},p=function(t,e,n,r){n&&t.setAttribute(e,d(n,r))},g=function(t,e){var n=h&&e.to_webp,r=o(t,e.data_src);if(r){var s=d(r,n);t.style.backgroundImage='url("'+s+'")'}},y={IMG:function(t,e){var n=h&&e.to_webp,r=e.data_srcset,s=t.parentNode;s&&"PICTURE"===s.tagName&&b(s,"srcset",r,n);var a=o(t,e.data_sizes);p(t,"sizes",a);var i=o(t,r);p(t,"srcset",i,n);var c=o(t,e.data_src);p(t,"src",c,n)},IFRAME:function(t,e){var n=o(t,e.data_src);p(t,"src",n)},VIDEO:function(t,e){var n=e.data_src,r=o(t,n);b(t,"src",n),p(t,"src",r),t.load()}},w=function(t,e){var n=t.tagName,r=y[n];r?r(t,e):g(t,e)},E=function(t,e){m?t.classList.add(e):t.className+=(t.className?" ":"")+e},I=function(t,e){m?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\s+)"+e+"(\\s+|$)")," ").replace(/^\s+/,"").replace(/\s+$/,"")},L=function(t,e){t&&t(e)},O=function(t,e,n){t.addEventListener(e,n)},x=function(t,e,n){t.removeEventListener(e,n)},A=function(t,e,n){O(t,"load",e),O(t,"loadeddata",e),O(t,"error",n)},z=function(t,e,n){x(t,"load",e),x(t,"loadeddata",e),x(t,"error",n)},k=function(t,e,n){var r=e?n.class_loaded:n.class_error,o=e?n.callback_load:n.callback_error,s=t.target;I(s,n.class_loading),E(s,r),L(o,s)},N=function(t,e){var n=function n(o){k(o,!0,e),z(t,n,r)},r=function r(o){k(o,!1,e),z(t,n,r)};A(t,n,r)},C=["IMG","IFRAME","VIDEO"],R=function(t,n,r){e(t,r),n.unobserve(t)},S=function(t){var e=l(t);e&&(clearTimeout(e),c(t,null))},M=function(t,e,n){var r=n.load_delay,o=l(t);o||(o=setTimeout(function(){R(t,e,n),S(t)},r),c(t,o))},j=function(t){return t.isIntersecting||t.intersectionRatio>0},D=function(t){return{root:t.container===document?null:t.container,rootMargin:t.threshold+"px",threshold:0}},T=function(t,e){this._settings=r(t),this._setObserver(),this.update(e)};return T.prototype={_manageIntersection:function(t){var e=this._observer,n=this._settings,r=this._settings.load_delay,o=t.target;j(t)&&(r?M(o,e,n):R(o,e,n)),j(t)||S(o)},_onIntersection:function(e){e.forEach(this._manageIntersection.bind(this)),this._elements=t(this._elements)},_setObserver:function(){v&&(this._observer=new IntersectionObserver(this._onIntersection.bind(this),D(this._settings)))},loadAll:function(){var e=this;this._elements.forEach(function(t){e.load(t)}),this._elements=t(this._elements)},update:function(e){var n=this,r=this._settings,o=e||r.container.querySelectorAll(r.elements_selector);this._elements=t(Array.prototype.slice.call(o)),!_&&this._observer?this._elements.forEach(function(t){n._observer.observe(t)}):this.loadAll()},destroy:function(){var e=this;this._observer&&(t(this._elements).forEach(function(t){e._observer.unobserve(t)}),this._observer=null),this._elements=null,this._settings=null},load:function(t,n){e(t,this._settings,n)}},f&&function(t,e){if(e)if(e.length)for(var n,r=0;n=e[r];r+=1)u(t,n);else u(t,e)}(T,window.lazyLoadOptions),T}); | ||
var _extends=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};!function(t,e){"object"===("undefined"==typeof exports?"undefined":_typeof(exports))&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.LazyLoad=e()}(this,function(){"use strict";function t(t){return t.filter(function(t){return!i(t)})}function e(t,e,n){!n&&i(t)||(L(e.callback_enter,t),C.indexOf(t.tagName)>-1&&(N(t,e),E(t,e.class_loading)),w(t,e),a(t),L(e.callback_set,t))}var n={elements_selector:"img",container:document,threshold:300,thresholds:null,data_src:"src",data_srcset:"srcset",data_sizes:"sizes",class_loading:"loading",class_loaded:"loaded",class_error:"error",load_delay:0,callback_load:null,callback_error:null,callback_set:null,callback_enter:null,to_webp:!1},r=function(t){return _extends({},n,t)},o=function(t,e){return t.getAttribute("data-"+e)},s=function(t,e,n){var r="data-"+e;null!==n?t.setAttribute(r,n):t.removeAttribute(r)},a=function(t){return s(t,"was-processed","true")},i=function(t){return"true"===o(t,"was-processed")},c=function(t,e){return s(t,"ll-timeout",e)},l=function(t){return o(t,"ll-timeout")},u=function(t,e){var n,r=new t(e);try{n=new CustomEvent("LazyLoad::Initialized",{detail:{instance:r}})}catch(t){(n=document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized",!1,!1,{instance:r})}window.dispatchEvent(n)},d=function(t,e){return e?t.replace(/\.(jpe?g|png)/gi,".webp"):t},f="undefined"!=typeof window,_=f&&!("onscroll"in window)||/(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent),v=f&&"IntersectionObserver"in window,m=f&&"classList"in document.createElement("p"),h=f&&function(){var t=document.createElement("canvas");return!(!t.getContext||!t.getContext("2d"))&&0===t.toDataURL("image/webp").indexOf("data:image/webp")}(),b=function(t,e,n,r){for(var s,a=0;s=t.children[a];a+=1)if("SOURCE"===s.tagName){var i=o(s,n);p(s,e,i,r)}},p=function(t,e,n,r){n&&t.setAttribute(e,d(n,r))},g=function(t,e){var n=h&&e.to_webp,r=o(t,e.data_src);if(r){var s=d(r,n);t.style.backgroundImage='url("'+s+'")'}},y={IMG:function(t,e){var n=h&&e.to_webp,r=e.data_srcset,s=t.parentNode;s&&"PICTURE"===s.tagName&&b(s,"srcset",r,n);var a=o(t,e.data_sizes);p(t,"sizes",a);var i=o(t,r);p(t,"srcset",i,n);var c=o(t,e.data_src);p(t,"src",c,n)},IFRAME:function(t,e){var n=o(t,e.data_src);p(t,"src",n)},VIDEO:function(t,e){var n=e.data_src,r=o(t,n);b(t,"src",n),p(t,"src",r),t.load()}},w=function(t,e){var n=t.tagName,r=y[n];r?r(t,e):g(t,e)},E=function(t,e){m?t.classList.add(e):t.className+=(t.className?" ":"")+e},I=function(t,e){m?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\s+)"+e+"(\\s+|$)")," ").replace(/^\s+/,"").replace(/\s+$/,"")},L=function(t,e){t&&t(e)},O=function(t,e,n){t.addEventListener(e,n)},x=function(t,e,n){t.removeEventListener(e,n)},A=function(t,e,n){O(t,"load",e),O(t,"loadeddata",e),O(t,"error",n)},z=function(t,e,n){x(t,"load",e),x(t,"loadeddata",e),x(t,"error",n)},k=function(t,e,n){var r=e?n.class_loaded:n.class_error,o=e?n.callback_load:n.callback_error,s=t.target;I(s,n.class_loading),E(s,r),L(o,s)},N=function(t,e){var n=function n(o){k(o,!0,e),z(t,n,r)},r=function r(o){k(o,!1,e),z(t,n,r)};A(t,n,r)},C=["IMG","IFRAME","VIDEO"],R=function(t,n,r){e(t,r),n.unobserve(t)},S=function(t){var e=l(t);e&&(clearTimeout(e),c(t,null))},M=function(t,e,n){var r=n.load_delay,o=l(t);o||(o=setTimeout(function(){R(t,e,n),S(t)},r),c(t,o))},j=function(t){return t.isIntersecting||t.intersectionRatio>0},D=function(t){return{root:t.container===document?null:t.container,rootMargin:t.thresholds||t.threshold+"px"}},T=function(t,e){this._settings=r(t),this._setObserver(),this.update(e)};return T.prototype={_manageIntersection:function(t){var e=this._observer,n=this._settings,r=this._settings.load_delay,o=t.target;j(t)&&(r?M(o,e,n):R(o,e,n)),j(t)||S(o)},_onIntersection:function(e){e.forEach(this._manageIntersection.bind(this)),this._elements=t(this._elements)},_setObserver:function(){v&&(this._observer=new IntersectionObserver(this._onIntersection.bind(this),D(this._settings)))},loadAll:function(){var e=this;this._elements.forEach(function(t){e.load(t)}),this._elements=t(this._elements)},update:function(e){var n=this,r=this._settings,o=e||r.container.querySelectorAll(r.elements_selector);this._elements=t(Array.prototype.slice.call(o)),!_&&this._observer?this._elements.forEach(function(t){n._observer.observe(t)}):this.loadAll()},destroy:function(){var e=this;this._observer&&(t(this._elements).forEach(function(t){e._observer.unobserve(t)}),this._observer=null),this._elements=null,this._settings=null},load:function(t,n){e(t,this._settings,n)}},f&&function(t,e){if(e)if(e.length)for(var n,r=0;n=e[r];r+=1)u(t,n);else u(t,e)}(T,window.lazyLoadOptions),T}); | ||
//# sourceMappingURL=lazyload.min.js.map |
{ | ||
"name": "vanilla-lazyload", | ||
"version": "10.16.2", | ||
"version": "10.17.0", | ||
"description": "A fast, lightweight script to load images as they enter the viewport. SEO friendly, it supports responsive images (both srcset + sizes and picture) and progressive JPEG", | ||
@@ -5,0 +5,0 @@ "main": "dist/lazyload.min.js", |
@@ -1,2 +0,2 @@ | ||
LazyLoad is a fast, lightweight and flexible script that _speeds up your web application_ by **loading images, video or iframes as they enter the viewport**. It's written in plain "vanilla" JavaScript, uses [Intersection Observers](https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API), and supports [responsive images](https://alistapart.com/article/responsive-images-in-practice). It's also SEO-friendly and it has some other [notable features](#notable-features). | ||
LazyLoad is a fast, lightweight and flexible script that _speeds up your web application_ by **loading images, video or iframes as they enter the viewport**. It's written in plain "vanilla" JavaScript, uses [Intersection Observers](https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API), and supports [responsive images](https://alistapart.com/article/responsive-images-in-practice). It's also SEO-friendly and it has some other [notable features](#-notable-features). | ||
@@ -28,3 +28,3 @@ ➡️ Jump to: [👨💻 Include the script](#-include-the-script) - [🥧 Recipes](#-recipes) - [📺 Demos](#-demos) - [😋 Tips & tricks](#-tips--tricks) - [🔌 API](#-api) - [😯 Notable features](#-notable-features) | ||
```html | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/vanilla-lazyload/10.16.2/lazyload.min.js"></script> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/vanilla-lazyload/10.17.0/lazyload.min.js"></script> | ||
``` | ||
@@ -49,3 +49,3 @@ | ||
var s = d.createElement("script"); | ||
var v = !("IntersectionObserver" in w) ? "8.15.2" : "10.16.2"; | ||
var v = !("IntersectionObserver" in w) ? "8.15.0" : "10.17.0"; | ||
s.async = true; // This includes the script as async. See the "recipes" section for more information about async loading of LazyLoad. | ||
@@ -76,3 +76,3 @@ s.src = "https://cdnjs.cloudflare.com/ajax/libs/vanilla-lazyload/" + v + "/lazyload.min.js"; | ||
```js | ||
var v = !("IntersectionObserver" in window) ? "8.15.2" : "10.16.2"; | ||
var v = !("IntersectionObserver" in window) ? "8.15.0" : "10.17.0"; | ||
define("vanilla-lazyLoad", ["https://cdnjs.cloudflare.com/ajax/libs/vanilla-lazyload/" + v + "/lazyload.amd.min.js"], function (LazyLoad) { | ||
@@ -98,3 +98,3 @@ return LazyLoad; | ||
``` | ||
npm install vanilla-lazyload@10.16.2 | ||
npm install vanilla-lazyload@10.17.0 | ||
``` | ||
@@ -203,3 +203,3 @@ | ||
[DEMO](http://verlok.github.io/lazyload/demos/single_container.html) - [SOURCE](https://github.com/verlok/lazyload/blob/master/demos/single_container.html) - [API](#-api) | ||
[DEMO](http://verlok.github.io/lazyload/demos/container_single.html) - [SOURCE](https://github.com/verlok/lazyload/blob/master/demos/container_single.html) - [API](#-api) | ||
@@ -247,3 +247,3 @@ ### Multiple scrolling panels | ||
[DEMO](http://verlok.github.io/lazyload/demos/multiple_container.html) - [SOURCE](https://github.com/verlok/lazyload/blob/master/demos/multiple_container.html) - [API](#-api) | ||
[DEMO](http://verlok.github.io/lazyload/demos/container_multiple.html) - [SOURCE](https://github.com/verlok/lazyload/blob/master/demos/container_multiple.html) - [API](#-api) | ||
@@ -723,19 +723,20 @@ ### Responsive images - img tag with srcset / sizes | ||
| Name | Meaning | Default value | | ||
| ------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | | ||
| `container` | The scrolling container, and the container of the elements in the `elements_selector` option. | `document` | | ||
| `elements_selector` | The string selector of the elements to load lazily, to be selected as descendants of the `container` object. For multiple elements, you can add the css selectors for the same followed by a comma. E.g.: `'iframe, img, .container_class'`. This will lazy load images for iframe and img elements along with the images/background images under `'container_class'` | `"img"` | | ||
| `threshold` | The distance out of the viewport, expressed in pixel, before which to start loading the images | `300` | | ||
| `data_src` | The name of the data attribute containing the original image source, excluding the `"data-"` part. E.g. if your data attribute is named `"data-src"`, just pass `"src"` | `"src"` | | ||
| `data_srcset` | The name of the data attribute containing the original image source set in either `img` and `source` tags, excluding the `"data-"` part. E.g. if your data attribute is named `"data-original-set"`, just pass `"original-set"` | `"srcset"` | | ||
| `data_sizes` | The name of the data attribute containing the sizes attribute to use, excluding the `"data-"` part. E.g. if your data attribute is named `"data-sizes"`, just pass `"sizes"` | `"sizes"` | | ||
| `class_loading` | The class applied to the elements while the loading is in progress. | `"loading"` | | ||
| `class_loaded` | The class applied to the elements when the loading is complete | `"loaded"` | | ||
| `class_error` | The class applied to the elements when the element causes an error | `"error"` | | ||
| `to_webp` | A boolean flag that activates the dynamic switch to WEBP feature. [More info](#switch-to-webp). | `false` | | ||
| `load_delay` | [**Available only in version 10.16.2-beta**] The time (in milliseconds) each image needs to stay inside the viewport before its loading begins. | `0` | | ||
| `callback_enter` | A function to be called when the DOM element enters the viewport. | `null` | | ||
| `callback_set` | A function to be called after the src of an image is set in the DOM. | `null` | | ||
| `callback_load` | A function to be called when an element was loaded. | `null` | | ||
| `callback_error` | A function to be called when an element triggers an error. | `null` | | ||
| Name | Meaning | Default value | | ||
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | | ||
| `container` | The scrolling container, and the container of the elements in the `elements_selector` option. | `document` | | ||
| `elements_selector` | The string selector of the elements to load lazily, to be selected as descendants of the `container` object. For multiple elements, you can add the css selectors for the same followed by a comma. E.g.: `'iframe, img, .container_class'`. This will lazy load images for iframe and img elements along with the images/background images under `'container_class'` | `"img"` | | ||
| `threshold` | A number of pixels representing the outer distance from of the scrolling area from which to start loading the elements. | `300` | | ||
| `thresholds` | Similar to `threshold`, but accepting multiple values and both `px` and `%` units. It maps directly to the `rootMargin` property of `IntersectionObserver` ([read more](https://developer.mozilla.org/en-US/docs/Web/API/IntersectionObserver/rootMargin)), so it must be a string with a syntax similar to the CSS `margin` property. You can use it when you need to have different thresholds for the scrolling area.<br>It overrides `threshold` when passed. Available only in version 10.x, it gracefully degrades to `threshold` on version 8.x. | `null` | | ||
| `data_src` | The name of the data attribute containing the original image source, excluding the `"data-"` part. E.g. if your data attribute is named `"data-src"`, just pass `"src"` | `"src"` | | ||
| `data_srcset` | The name of the data attribute containing the original image source set in either `img` and `source` tags, excluding the `"data-"` part. E.g. if your data attribute is named `"data-original-set"`, just pass `"original-set"` | `"srcset"` | | ||
| `data_sizes` | The name of the data attribute containing the sizes attribute to use, excluding the `"data-"` part. E.g. if your data attribute is named `"data-sizes"`, just pass `"sizes"` | `"sizes"` | | ||
| `class_loading` | The class applied to the elements while the loading is in progress. | `"loading"` | | ||
| `class_loaded` | The class applied to the elements when the loading is complete | `"loaded"` | | ||
| `class_error` | The class applied to the elements when the element causes an error | `"error"` | | ||
| `to_webp` | A boolean flag that activates the dynamic switch to WEBP feature. [More info](#switch-to-webp). | `false` | | ||
| `load_delay` | The time (in milliseconds) each image needs to stay inside the viewport before its loading begins. Available only in version 10.x, gracefully degrades on version 8.x | `0` | | ||
| `callback_enter` | A function to be called when the DOM element enters the viewport. | `null` | | ||
| `callback_set` | A function to be called after the src of an image is set in the DOM. | `null` | | ||
| `callback_load` | A function to be called when an element was loaded. | `null` | | ||
| `callback_error` | A function to be called when an element triggers an error. | `null` | | ||
@@ -742,0 +743,0 @@ ### Methods |
@@ -5,2 +5,3 @@ const defaultSettings = { | ||
threshold: 300, | ||
thresholds: null, | ||
data_src: "src", | ||
@@ -7,0 +8,0 @@ data_srcset: "srcset", |
@@ -8,4 +8,3 @@ /* entry.isIntersecting needs fallback because is null on some versions of MS Edge, and | ||
root: settings.container === document ? null : settings.container, | ||
rootMargin: settings.threshold + "px", | ||
threshold: 0 | ||
rootMargin: settings.thresholds || settings.threshold + "px" | ||
}); |
TODO | ||
==== | ||
* Callbacks demo can be merged with all others | ||
* Enter callback should: | ||
* be changed to "before set" instead of enter | ||
* be moved to the reveal function | ||
* accept a return value in order to change the url of the image | ||
* Missing documenation | ||
@@ -5,0 +10,0 @@ * Constructor takes a nodeset as 2nd parameter, see 10.2 release |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
1133737
157
2356
778