/*! * Name : Just Another Parallax [Jarallax] * Version : 1.7.1 * Author : _nK https://nkdev.info * GitHub : https://github.com/nk-o/jarallax */ (function(d){function w(){x=d.innerWidth||document.documentElement.clientWidth;g=d.innerHeight||document.documentElement.clientHeight}function q(b,a,c){b.addEventListener?b.addEventListener(a,c):b.attachEvent("on"+a,function(){c.call(b)})}function r(b){d.requestAnimationFrame(function(){"scroll"!==b.type&&w();for(var a=0,c=k.length;af||1f||1this.options.speed?e-this.options.speed* n:e+this.options.speed*(1-n),d.transform="scale("+e+") translate3d(0, 0, 0)";if("scroll"===this.options.type||"scroll-opacity"===this.options.type)e=this.parallaxScrollDistance*p,t&&this.options.enableTransform?(this.parentWithTransform&&(e-=c),d.transform="translate3d(0, "+e+"px, 0)"):this.image.useImgTag?d.top=e+"px":(this.bgPosVerticalCenter&&(e+=this.bgPosVerticalCenter),d.backgroundPosition="50% "+e+"px"),d.position=v?"absolute":"fixed";this.css(this.image.$item,d);this.options.onScroll&&this.options.onScroll.call(this, {section:a,beforeTop:b,beforeTopEnd:f,afterTop:h,beforeBottom:k,beforeBottomEnd:m,afterBottom:l,visiblePercent:n,fromViewportCenter:p})}}};q(d,"scroll",r);q(d,"resize",r);q(d,"orientationchange",r);q(d,"load",r);var u=function(b){if("object"===typeof HTMLElement?b instanceof HTMLElement:b&&"object"===typeof b&&null!==b&&1===b.nodeType&&"string"===typeof b.nodeName)b=[b];var a=arguments[1],c=Array.prototype.slice.call(arguments,2),e=b.length,d=0,f;for(d;d