From a8e19482eb480528eeeb59d0620643e72ef3ce7e Mon Sep 17 00:00:00 2001 From: Todd Motto Date: Mon, 2 Dec 2013 22:54:58 +0000 Subject: [PATCH] Update v1.4.0 --- dist/echo.js | 2 ++ dist/echo.min.js | 2 +- src/echo.js | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/dist/echo.js b/dist/echo.js index dfed500..16002a1 100644 --- a/dist/echo.js +++ b/dist/echo.js @@ -41,6 +41,8 @@ window.Echo = (function (window, document, undefined) { store.push(nodes[i]); } + _throttle(); + if (document.addEventListener) { window.addEventListener('scroll', _throttle, false); } else { diff --git a/dist/echo.min.js b/dist/echo.min.js index d7cfeb9..51f8a39 100644 --- a/dist/echo.min.js +++ b/dist/echo.min.js @@ -5,4 +5,4 @@ * by Todd Motto: http://toddmotto.com * Copyright. MIT licensed. */ -window.Echo=function(a,b){"use strict";var c,d,e,f=[],g=function(d){var e=d.getBoundingClientRect();return(e.top>=0&&e.left>=0&&e.top)<=(a.innerHeight||b.documentElement.clientHeight)+parseInt(c)},h=function(){for(var a=f.length;a--;){var b=f[a];g(b)&&(b.src=b.getAttribute("data-echo"),f.splice(a,1))}},i=function(){clearTimeout(e),e=setTimeout(h,d)},j=function(e){var g=b.querySelectorAll("[data-echo]"),h=e||{};c=h.offset||0,d=h.throttle||250;for(var j=0;j=0&&e.left>=0&&e.top)<=(a.innerHeight||b.documentElement.clientHeight)+parseInt(c)},h=function(){for(var a=f.length;a--;){var b=f[a];g(b)&&(b.src=b.getAttribute("data-echo"),f.splice(a,1))}},i=function(){clearTimeout(e),e=setTimeout(h,d)},j=function(e){var g=b.querySelectorAll("[data-echo]"),h=e||{};c=h.offset||0,d=h.throttle||250;for(var j=0;j