diff --git a/dist/min/tiny-slider.js b/dist/min/tiny-slider.js index 54e4ead4..59e10159 100644 --- a/dist/min/tiny-slider.js +++ b/dist/min/tiny-slider.js @@ -1,2 +1,2 @@ -var tns=function(){var t=window,Ti=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.msRequestAnimationFrame||function(t){return setTimeout(t,16)},e=window,Bi=e.cancelAnimationFrame||e.mozCancelAnimationFrame||function(t){clearTimeout(t)};function Ei(){for(var t,e,n,i=arguments[0]||{},a=1,r=arguments.length;a";return r.innerHTML=o,a.appendChild(r),n.appendChild(a),t=Math.abs(a.getBoundingClientRect().left-r.children[67].getBoundingClientRect().left)<2,n.fake?Ii(n,i):a.remove(),t}(),n),I=e.tMQ?ki(e.tMQ):Ni(e,"tMQ",(r=document,o=Li(),g=Di(o),x=r.createElement("div"),b=r.createElement("style"),C="@media all and (min-width:1px){.tns-mq-test{position:absolute}}",b.type="text/css",x.className="tns-mq-test",o.appendChild(b),o.appendChild(x),b.styleSheet?b.styleSheet.cssText=C:b.appendChild(r.createTextNode(C)),a=window.getComputedStyle?window.getComputedStyle(x).position:x.currentStyle.position,o.fake?Ii(o,g):x.remove(),"absolute"===a),n),A=e.tTf?ki(e.tTf):Ni(e,"tTf",Xi("transform"),n),T=e.t3D?ki(e.t3D):Ni(e,"t3D",function(t){if(!t)return!1;if(!window.getComputedStyle)return!1;var e,n=document,i=Li(),a=Di(i),r=n.createElement("p"),o=9-Xt&&(e=t);return e}:function(){return Et||V?Math.max(0,Qt-Math.ceil(Ct)):Qt-1},_t=fn(mn("startIndex")),Zt=_t,$t=0,te=mt?null:Jt(),ee=L.swipeAngle,ne=!ee||"?",ie=!1,ae=L.onInit,re=new Gi,oe=" tns-slider tns-"+L.mode,se=nt.id||(ft=window.tnsId,window.tnsId=ft?ft+1:1,"tns"+window.tnsId),ue=mn("disable"),le=!1,ce=L.freezable,fe=!(!ce||mt)&&Nn(),de=!1,ve={click:oi,keydown:function(t){switch((t=pi(t)).keyCode){case v:case h:case l:Oe.disabled||oi(t,-1);break;case m:case y:case c:Se.disabled||oi(t,1);break;case d:ri("first",t);break;case f:ri("last",t)}}},pe={click:function(t){ie&&ai();var e=(t=pi(t)).target||t.srcElement;for(;e!==We&&!zi(e,"data-nav");)e=e.parentNode;zi(e,"data-nav")&&ri(Fe=[].indexOf.call(Pe,e),t)},keydown:function(t){var e=D.activeElement;if(!zi(e,"data-nav"))return;var n=(t=pi(t)).keyCode,i=[].indexOf.call(Pe,e),a=qe.length,r=qe.indexOf(i);L.navContainer&&(a=ot,r=i);function o(t){return L.navContainer?t:qe[t]}switch(n){case v:case l:0"," animation"];if(Ae||Te)var en,nn={},an={},rn=!1,on=0,sn=$?function(t,e){return t.x-e.x}:function(t,e){return t.y-e.y};mt||cn(ue||fe),A&&(Kt=A,Ut="translate",T?(Ut+=$?"3d(":"3d(0px, ",Gt=$?", 0px, 0px)":", 0px)"):(Ut+=$?"X(":"Y(",Gt=")")),function(){F&&Ln();!function(){hn("gutter");tt.className="tns-outer",et.className="tns-inner",tt.id=se+"-ow",et.id=se+"-iw",kt&&(et.className+=" tns-ah");""===nt.id&&(nt.id=se);if(oe+=M||mt?" tns-subpixel":" tns-no-subpixel",oe+=w?" tns-calc":" tns-no-calc",oe+=" tns-"+L.axis,nt.className+=oe,V){var t=D.createElement("div");t.className="tns-ovh",tt.appendChild(t),t.appendChild(et)}else tt.appendChild(et);it.insertBefore(tt,nt),et.appendChild(nt)}();for(var t=0;t .tns-item","font-size:"+p.getComputedStyle(rt[0]).fontSize+";",Si(zt)),Oi(zt,"#"+se,"font-size:0;",Si(zt))):Hi(rt,function(t,e){var n;t.style.marginLeft=(n=e,w?w+"("+100*n+"% / "+Qt+")":100*n/Qt+"%")}));if(I){var i=yn(L.edgePadding,L.gutter,L.fixedWidth,L.speed);Oi(zt,"#"+se+"-iw",i,Si(zt)),V&&(i=$&&!mt?"width:"+gn(L.fixedWidth,L.gutter,L.items)+";":"",B&&(i+=wn(Tt)),Oi(zt,"#"+se,i,Si(zt))),i=$&&!mt?xn(L.fixedWidth,L.gutter,L.items):"",L.gutter&&(i+=bn(L.gutter)),V||(B&&(i+=wn(Tt)),k&&(i+=Mn(Tt))),i&&Oi(zt,"#"+se+" > .tns-item",i,Si(zt))}else{et.style.cssText=yn(gt,xt,yt),V&&$&&!mt&&(nt.style.width=gn(yt,xt,Ct));var i=$&&!mt?xn(yt,xt,Ct):"";xt&&(i+=bn(xt)),i&&Oi(zt,"#"+se+" > .tns-item",i,Si(zt))}if(F&&I)for(var a in F){a=parseInt(a);var r=F[a],i="",o="",s="",u="",l=mt?null:mn("items",a),c=mn("fixedWidth",a),f=mn("speed",a),d=mn("edgePadding",a),v=mn("gutter",a);("edgePadding"in r||"gutter"in r)&&(o="#"+se+"-iw{"+yn(d,v,c,f)+"}"),V&&$&&!mt&&("fixedWidth"in r||"items"in r||yt&&"gutter"in r)&&(s="width:"+gn(c,v,l)+";"),B&&"speed"in r&&(s+=wn(f)),s&&(s="#"+se+"{"+s+"}"),("fixedWidth"in r||yt&&"gutter"in r||!V&&"items"in r)&&(u+=xn(c,v,l)),"gutter"in r&&(u+=bn(v)),!V&&"speed"in r&&(B&&(u+=wn(f)),k&&(u+=Mn(f))),u&&(u="#"+se+" > .tns-item{"+u+"}"),(i=o+s+u)&&zt.insertRule("@media (min-width: "+a/16+"em) {"+i+"}",zt.cssRules.length)}})(),An()}();var un=Et?V?function(){var t=$t,e=te;t+=wt,e-=wt,gt?(t+=1,e-=1):yt&&bt%(yt+xt)&&(e-=1),Ft&&(e<_t?_t-=ot:_t=parseInt(i)&&t in F[i]&&(n=F[i][t]);return"slideBy"===t&&"page"===n&&(n=mn("items")),V||"slideBy"!==t&&"items"!==t||(n=Math.floor(n)),n}function yn(t,e,n,i){var a="";if(t){var r=t;e&&(r-=e),a=$?"margin: 0 "+r+"px 0 "+t+"px;":"margin: "+t+"px 0 "+r+"px 0;"}else if(e&&!n){var o="-"+e+"px";a="margin: 0 "+($?o+" 0 0":"0 "+o+" 0")+";"}return B&&i&&(a+=wn(i)),a}function gn(t,e,n){return t?(t+e)*Qt+"px":w?w+"("+100*Qt+"% / "+n+")":100*Qt/n+"%"}function xn(t,e,n){var i;if(t)i=t+e+"px";else{V||(n=Math.floor(n));var a=V?Qt:n;i=w?w+"(100% / "+a+")":100/a+"%"}return i="width:"+i,"inner"!==Q?i+";":i+" !important;"}function bn(t){var e="";!1!==t&&(e=($?"padding-":"margin-")+($?"right":"bottom")+": "+t+"px;");return e}function Cn(t,e){var n=t.substring(0,t.length-e).toLowerCase();return n&&(n="-"+n+"-"),n}function wn(t){return Cn(B,18)+"transition-duration:"+t/1e3+"s;"}function Mn(t){return Cn(k,17)+"animation-duration:"+t/1e3+"s;"}function An(){if(hn("autoHeight")||mt||!$){var t=nt.querySelectorAll("img");Hi(t,function(t){var e=t.src;e.indexOf("data:image")<0?(Ki(t,ke),t.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==",t.src=e):Pi(t,Ee)}),Ti(function(){zn(function(t){for(var e=[],n=0,i=t.length;n'+tn[0]+t+tn[1]+Rt[0]+""),Ze=tt.querySelector("[data-action]")),Ze&&Ki(Ze,{click:di}),St&&(ci(),Pt&&Ki(nt,he),Wt&&Ki(nt,me))}if(Ce){var e=V?Ft:0;if(We){qi(We,{"aria-label":"Carousel Pagination"}),Pe=We.children;for(var n=0;n';a='
'+a+"
",tt.insertAdjacentHTML("afterbegin",a),We=tt.querySelector(".tns-nav"),Pe=We.children}if(Mi(),B){var o=B.substring(0,B.length-18).toLowerCase(),s="transition: all "+Tt/1e3+"s";o&&(s="-"+o+"-"+s),Oi(zt,"[aria-controls^="+se+"-item]",s,Si(zt))}qi(Pe[Qe],{tabindex:"0","aria-selected":"true"}),Pi(Pe[Qe],Xe),Ki(We,pe)}be&&(De||Oe&&Se?(De&&(Oe=De.children[0],Se=De.children[1],qi(De,{"aria-label":"Carousel Navigation",tabindex:"0"}),qi(De.children,{"aria-controls":se,tabindex:"-1"})),qi(Oe,{"data-controls":"prev"}),qi(Se,{"data-controls":"next"})):(tt.insertAdjacentHTML("afterbegin",'
"),De=tt.querySelector(".tns-controls"),Oe=De.children[0],Se=De.children[1]),Ne=Xn(Oe),Le=Xn(Se),Un(),De?Ki(De,ve):(Ki(Oe,ve),Ki(Se,ve))),Dn()}function Bn(){if(V&&O){var t={};t[O]=ai,Ki(nt,t)}It&&Ki(nt,ge),Ot&&Ki(nt,xe),At&&Ki(D,ye),"inner"===Q?re.on("outerResized",function(){kn(),re.emit("innerLoaded",Ai())}):(F||yt||mt||kt||!$)&&Ki(p,{resize:En}),"outer"===Q?re.on("innerLoaded",Wn):kt&&!ue&&Wn(),Hn(),ue?Sn():fe&&On(),re.on("indexChanged",qn),"function"==typeof ae&&ae(Ai()),"inner"===Q&&re.emit("innerLoaded",Ai())}function En(t){Ti(function(){kn(pi(t))})}function kn(t){if(ut){"outer"===Q&&re.emit("outerResized",Ai(t)),st=vn();var e,n=Z,i=!1;F&&(Ln(),(e=n!==Z)&&re.emit("newBreakpointStart",Ai(t)));var a,r,o,s,u=Ct,l=ue,c=fe,f=At,d=Nt,v=Dt,p=It,h=Ot,m=St,y=Pt,g=Wt,x=_t;if(e){var b=yt,C=kt,w=Lt,M=Rt;if(!I)var A=xt,T=gt}if(At=mn("arrowKeys"),Nt=mn("controls"),Dt=mn("nav"),It=mn("touch"),Ot=mn("mouseDrag"),St=mn("autoplay"),Pt=mn("autoplayHoverPause"),Wt=mn("autoplayResetOnVisibility"),e&&(ue=mn("disable"),yt=mn("fixedWidth"),Tt=mn("speed"),kt=mn("autoHeight"),Lt=mn("controlsText"),Rt=mn("autoplayText"),Ht=mn("autoplayTimeout"),I||(gt=mn("edgePadding"),xt=mn("gutter"))),cn(ue),bt=pn(),$&&!mt||ue||(Qn(),$||(wi(),i=!0)),(yt||mt)&&(Xt=_n(),te=Jt()),(e||yt)&&(Ct=mn("items"),wt=mn("slideBy"),(r=Ct!==u)&&(yt||mt||(te=Jt()),un())),e&&ue!==l&&(ue?Sn():function(){if(!le)return;if(zt.disabled=!1,nt.className+=oe,$n(),Et)for(var t=Ft;t--;)V&&Qi(rt[t]),Qi(rt[Qt-t-1]);if(!V)for(var e=_t,n=_t+ot;e .tns-item",N,Si(zt))}kt&&Wn(),i&&($n(),Zt=_t)}e&&re.emit("newBreakpointEnd",Ai(t))}}function Nn(){return yt||mt?yt?(yt+xt)*ot<=bt+2*gt:(Et?lt[ot]:Jn())<=bt+2*gt:ot<=Ct}function Ln(){for(var t in Z=0,F)(t=parseInt(t))<=st&&(Z=t)}function Dn(){!St&&Ze&&Fi(Ze,L.autoplayButton),!Dt&&We&&Fi(We,L.navContainer),Nt||(De?Fi(De,L.controlsContainer):(Oe&&Fi(Oe,L.prevButton),Se&&Fi(Se,L.nextButton)))}function In(){St&&Ze&&Qi(Ze,L.autoplayButton),Dt&&We&&Qi(We,L.navContainer),Nt&&(De?Qi(De,L.controlsContainer):(Oe&&Qi(Oe,L.prevButton),Se&&Qi(Se,L.nextButton)))}function On(){if(!de){if(gt&&(et.style.margin="0px"),Ft)for(var t="tns-transparent",e=Ft;e--;)V&&Pi(rt[e],t),Pi(rt[Qt-e-1],t);Dn(),de=!0}}function Sn(){if(!le){if(zt.disabled=!0,nt.className=nt.className.replace(oe.substring(1),""),ji(nt,["style"]),Et)for(var t=Ft;t--;)V&&Fi(rt[t]),Fi(rt[Qt-t-1]);if($&&V||ji(et,["style"]),!V)for(var e=_t,n=_t+ot;e=lt[lt.length-1])_t=te;else for(var n=0;n=lt[n];)e>lt[_t=n]&&a<0&&(_t+=1),n++}ni(i,a),re.emit(mi(i)?"touchEnd":"dragEnd",Ai(i))}):(bi(),ne&&oi(i,0";return r.innerHTML=o,a.appendChild(r),n.appendChild(a),t=Math.abs(a.getBoundingClientRect().left-r.children[67].getBoundingClientRect().left)<2,n.fake?Ii(n,i):a.remove(),t}(),n),D=e.tMQ?Ni(e.tMQ):Bi(e,"tMQ",(r=document,o=Li(),x=Di(o),b=r.createElement("div"),w=r.createElement("style"),C="@media all and (min-width:1px){.tns-mq-test{position:absolute}}",w.type="text/css",b.className="tns-mq-test",o.appendChild(w),o.appendChild(b),w.styleSheet?w.styleSheet.cssText=C:w.appendChild(r.createTextNode(C)),a=window.getComputedStyle?window.getComputedStyle(b).position:b.currentStyle.position,o.fake?Ii(o,x):b.remove(),"absolute"===a),n),T=e.tTf?Ni(e.tTf):Bi(e,"tTf",Xi("transform"),n),E=e.t3D?Ni(e.t3D):Bi(e,"t3D",function(t){if(!t)return!1;if(!window.getComputedStyle)return!1;var e,n=document,i=Li(),a=Di(i),r=n.createElement("p"),o=9-Xt&&(e=t);return e}:function(){return kt||V?Math.max(0,Qt-Math.ceil(wt)):Qt-1},_t=fn(hn("startIndex")),Zt=_t,$t=0,te=ht?null:Jt(),ee=p.swipeAngle,ne=!ee||"?",ie=!1,ae=p.onInit,re=new Gi,oe=" tns-slider tns-"+p.mode,se=nt.id||(ft=window.tnsId,window.tnsId=ft?ft+1:1,"tns"+window.tnsId),ue=hn("disable"),le=!1,ce=p.freezable,fe=!(!ce||ht)&&Bn(),de=!1,ve={click:oi,keydown:function(t){switch((t=pi(t)).keyCode){case v:case h:case l:Oe.disabled||oi(t,-1);break;case y:case g:case c:Se.disabled||oi(t,1);break;case d:ri("first",t);break;case f:ri("last",t)}}},pe={click:function(t){ie&&ai();var e=(t=pi(t)).target||t.srcElement;for(;e!==We&&!zi(e,"data-nav");)e=e.parentNode;zi(e,"data-nav")&&ri(Fe=[].indexOf.call(Pe,e),t)},keydown:function(t){var e=L.activeElement;if(!zi(e,"data-nav"))return;var n=(t=pi(t)).keyCode,i=[].indexOf.call(Pe,e),a=qe.length,r=qe.indexOf(i);p.navContainer&&(a=ot,r=i);function o(t){return p.navContainer?t:qe[t]}switch(n){case v:case l:0"," animation"];if(Ae||Te)var en,nn={},an={},rn=!1,on=0,sn=$?function(t,e){return t.x-e.x}:function(t,e){return t.y-e.y};ht||cn(ue||fe),T&&(Kt=T,Ut="translate",E?(Ut+=$?"3d(":"3d(0px, ",Gt=$?", 0px, 0px)":", 0px)"):(Ut+=$?"X(":"Y(",Gt=")")),function(){F&&Ln();!function(){mn("gutter");tt.className="tns-outer",et.className="tns-inner",tt.id=se+"-ow",et.id=se+"-iw",Nt&&(et.className+=" tns-ah");""===nt.id&&(nt.id=se);if(oe+=A||ht?" tns-subpixel":" tns-no-subpixel",oe+=M?" tns-calc":" tns-no-calc",oe+=" tns-"+p.axis,nt.className+=oe,V){var t=L.createElement("div");t.className="tns-ovh",tt.appendChild(t),t.appendChild(et)}else tt.appendChild(et);it.insertBefore(tt,nt),et.appendChild(nt)}();for(var t=0;t .tns-item","font-size:"+m.getComputedStyle(rt[0]).fontSize+";",Si(zt)),Oi(zt,"#"+se,"font-size:0;",Si(zt))):Hi(rt,function(t,e){var n;t.style.marginLeft=(n=e,M?M+"("+100*n+"% / "+Qt+")":100*n/Qt+"%")}));if(D){var i=yn(p.edgePadding,p.gutter,p.fixedWidth,p.speed);Oi(zt,"#"+se+"-iw",i,Si(zt)),V&&(i=$&&!ht?"width:"+gn(p.fixedWidth,p.gutter,p.items)+";":"",k&&(i+=Cn(Tt)),Oi(zt,"#"+se,i,Si(zt))),i=$&&!ht?xn(p.fixedWidth,p.gutter,p.items):"",p.gutter&&(i+=bn(p.gutter)),V||(k&&(i+=Cn(Tt)),B&&(i+=Mn(Tt))),i&&Oi(zt,"#"+se+" > .tns-item",i,Si(zt))}else{et.style.cssText=yn(gt,xt,yt),V&&$&&!ht&&(nt.style.width=gn(yt,xt,wt));var i=$&&!ht?xn(yt,xt,wt):"";xt&&(i+=bn(xt)),i&&Oi(zt,"#"+se+" > .tns-item",i,Si(zt))}if(F&&D)for(var a in F){a=parseInt(a);var r=F[a],i="",o="",s="",u="",l=ht?null:hn("items",a),c=hn("fixedWidth",a),f=hn("speed",a),d=hn("edgePadding",a),v=hn("gutter",a);("edgePadding"in r||"gutter"in r)&&(o="#"+se+"-iw{"+yn(d,v,c,f)+"}"),V&&$&&!ht&&("fixedWidth"in r||"items"in r||yt&&"gutter"in r)&&(s="width:"+gn(c,v,l)+";"),k&&"speed"in r&&(s+=Cn(f)),s&&(s="#"+se+"{"+s+"}"),("fixedWidth"in r||yt&&"gutter"in r||!V&&"items"in r)&&(u+=xn(c,v,l)),"gutter"in r&&(u+=bn(v)),!V&&"speed"in r&&(k&&(u+=Cn(f)),B&&(u+=Mn(f))),u&&(u="#"+se+" > .tns-item{"+u+"}"),(i=o+s+u)&&zt.insertRule("@media (min-width: "+a/16+"em) {"+i+"}",zt.cssRules.length)}})(),An()}();var un=kt?V?function(){var t=$t,e=te;t+=Ct,e-=Ct,gt?(t+=1,e-=1):yt&&bt%(yt+xt)&&(e-=1),Ft&&(e<_t?_t-=ot:_t=parseInt(i)&&t in F[i]&&(n=F[i][t]);return"slideBy"===t&&"page"===n&&(n=hn("items")),V||"slideBy"!==t&&"items"!==t||(n=Math.floor(n)),n}function yn(t,e,n,i){var a="";if(t){var r=t;e&&(r-=e),a=$?"margin: 0 "+r+"px 0 "+t+"px;":"margin: "+t+"px 0 "+r+"px 0;"}else if(e&&!n){var o="-"+e+"px";a="margin: 0 "+($?o+" 0 0":"0 "+o+" 0")+";"}return k&&i&&(a+=Cn(i)),a}function gn(t,e,n){return t?(t+e)*Qt+"px":M?M+"("+100*Qt+"% / "+n+")":100*Qt/n+"%"}function xn(t,e,n){var i;if(t)i=t+e+"px";else{V||(n=Math.floor(n));var a=V?Qt:n;i=M?M+"(100% / "+a+")":100/a+"%"}return i="width:"+i,"inner"!==Q?i+";":i+" !important;"}function bn(t){var e="";!1!==t&&(e=($?"padding-":"margin-")+($?"right":"bottom")+": "+t+"px;");return e}function wn(t,e){var n=t.substring(0,t.length-e).toLowerCase();return n&&(n="-"+n+"-"),n}function Cn(t){return wn(k,18)+"transition-duration:"+t/1e3+"s;"}function Mn(t){return wn(B,17)+"animation-duration:"+t/1e3+"s;"}function An(){if(mn("autoHeight")||ht||!$){var t=nt.querySelectorAll("img");Hi(t,function(t){var e=t.src;e.indexOf("data:image")<0?(Ki(t,Ne),t.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==",t.src=e):Pi(t,ke)}),Ti(function(){zn(function(t){for(var e=[],n=0,i=t.length;n'+tn[0]+t+tn[1]+Rt[0]+""),Ze=tt.querySelector("[data-action]")),Ze&&Ki(Ze,{click:di}),St&&(ci(),Pt&&Ki(nt,me),Wt&&Ki(nt,he))}if(we){var e=V?Ft:0;if(We){qi(We,{"aria-label":"Carousel Pagination"}),Pe=We.children;for(var n=0;n';a='
'+a+"
",tt.insertAdjacentHTML("afterbegin",a),We=tt.querySelector(".tns-nav"),Pe=We.children}if(Mi(),k){var o=k.substring(0,k.length-18).toLowerCase(),s="transition: all "+Tt/1e3+"s";o&&(s="-"+o+"-"+s),Oi(zt,"[aria-controls^="+se+"-item]",s,Si(zt))}qi(Pe[Qe],{tabindex:"0","aria-selected":"true"}),Pi(Pe[Qe],Xe),Ki(We,pe)}be&&(De||Oe&&Se?(De&&(Oe=De.children[0],Se=De.children[1],qi(De,{"aria-label":"Carousel Navigation",tabindex:"0"}),qi(De.children,{"aria-controls":se,tabindex:"-1"})),qi(Oe,{"data-controls":"prev"}),qi(Se,{"data-controls":"next"})):(tt.insertAdjacentHTML("afterbegin",'
"),De=tt.querySelector(".tns-controls"),Oe=De.children[0],Se=De.children[1]),Be=Xn(Oe),Le=Xn(Se),Un(),De?Ki(De,ve):(Ki(Oe,ve),Ki(Se,ve))),Dn()}function En(){if(V&&O){var t={};t[O]=ai,Ki(nt,t)}It&&Ki(nt,ge),Ot&&Ki(nt,xe),At&&Ki(L,ye),"inner"===Q?re.on("outerResized",function(){Nn(),re.emit("innerLoaded",Ai())}):(F||yt||ht||Nt||!$)&&Ki(m,{resize:kn}),"outer"===Q?re.on("innerLoaded",Wn):Nt&&!ue&&Wn(),Hn(),ue?Sn():fe&&On(),re.on("indexChanged",qn),"function"==typeof ae&&ae(Ai()),"inner"===Q&&re.emit("innerLoaded",Ai())}function kn(t){Ti(function(){Nn(pi(t))})}function Nn(t){if(ut){"outer"===Q&&re.emit("outerResized",Ai(t)),st=vn();var e,n=Z,i=!1;F&&(Ln(),(e=n!==Z)&&re.emit("newBreakpointStart",Ai(t)));var a,r,o,s,u=wt,l=ue,c=fe,f=At,d=Bt,v=Dt,p=It,m=Ot,h=St,y=Pt,g=Wt,x=_t;if(e){var b=yt,w=Nt,C=Lt,M=Rt;if(!D)var A=xt,T=gt}if(At=hn("arrowKeys"),Bt=hn("controls"),Dt=hn("nav"),It=hn("touch"),Ot=hn("mouseDrag"),St=hn("autoplay"),Pt=hn("autoplayHoverPause"),Wt=hn("autoplayResetOnVisibility"),e&&(ue=hn("disable"),yt=hn("fixedWidth"),Tt=hn("speed"),Nt=hn("autoHeight"),Lt=hn("controlsText"),Rt=hn("autoplayText"),Ht=hn("autoplayTimeout"),D||(gt=hn("edgePadding"),xt=hn("gutter"))),cn(ue),bt=pn(),$&&!ht||ue||(Qn(),$||(Ci(),i=!0)),(yt||ht)&&(Xt=_n(),te=Jt()),(e||yt)&&(wt=hn("items"),Ct=hn("slideBy"),(r=wt!==u)&&(yt||ht||(te=Jt()),un())),e&&ue!==l&&(ue?Sn():function(){if(!le)return;if(zt.disabled=!1,nt.className+=oe,$n(),kt)for(var t=Ft;t--;)V&&Qi(rt[t]),Qi(rt[Qt-t-1]);if(!V)for(var e=_t,n=_t+ot;e .tns-item",B,Si(zt))}Nt&&Wn(),i&&($n(),Zt=_t)}e&&re.emit("newBreakpointEnd",Ai(t))}}function Bn(){return yt||ht?yt?(yt+xt)*ot<=bt+2*gt:(kt?lt[ot]:Jn())<=bt+2*gt:ot<=wt}function Ln(){for(var t in Z=0,F)(t=parseInt(t))<=st&&(Z=t)}function Dn(){!St&&Ze&&Fi(Ze),!Dt&&We&&Fi(We),Bt||(De?Fi(De):(Oe&&Fi(Oe),Se&&Fi(Se)))}function In(){St&&Ze&&Qi(Ze),Dt&&We&&Qi(We),Bt&&(De?Qi(De):(Oe&&Qi(Oe),Se&&Qi(Se)))}function On(){if(!de){if(gt&&(et.style.margin="0px"),Ft)for(var t="tns-transparent",e=Ft;e--;)V&&Pi(rt[e],t),Pi(rt[Qt-e-1],t);Dn(),de=!0}}function Sn(){if(!le){if(zt.disabled=!0,nt.className=nt.className.replace(oe.substring(1),""),ji(nt,["style"]),kt)for(var t=Ft;t--;)V&&Fi(rt[t]),Fi(rt[Qt-t-1]);if($&&V||ji(et,["style"]),!V)for(var e=_t,n=_t+ot;e=lt[lt.length-1])_t=te;else for(var n=0;n=lt[n];)e>lt[_t=n]&&a<0&&(_t+=1),n++}ni(i,a),re.emit(hi(i)?"touchEnd":"dragEnd",Ai(i))}):(bi(),ne&&oi(i,0= 0 ? JSON.parse(value) : value;\n}\n\nfunction setLocalStorage(storage, key, value, access) {\n if (access) { storage.setItem(key, value); }\n return value;\n}\n\nfunction getSlideId() {\n var id = window.tnsId;\n window.tnsId = !id ? 1 : id + 1;\n \n return 'tns' + window.tnsId;\n}\n\nfunction getBody () {\n var doc = document,\n body = doc.body;\n\n if (!body) {\n body = doc.createElement('body');\n body.fake = true;\n }\n\n return body;\n}\n\nvar docElement = document.documentElement;\n\nfunction setFakeBody (body) {\n var docOverflow = '';\n if (body.fake) {\n docOverflow = docElement.style.overflow;\n //avoid crashing IE8, if background image is used\n body.style.background = '';\n //Safari 5.13/5.1.4 OSX stops loading if ::-webkit-scrollbar is used and scrollbars are visible\n body.style.overflow = docElement.style.overflow = 'hidden';\n docElement.appendChild(body);\n }\n\n return docOverflow;\n}\n\nfunction resetFakeBody (body, docOverflow) {\n if (body.fake) {\n body.remove();\n docElement.style.overflow = docOverflow;\n // Trigger layout so kinetic scrolling isn't disabled in iOS6+\n // eslint-disable-next-line\n docElement.offsetHeight;\n }\n}\n\n// get css-calc \n\nfunction calc() {\n var doc = document, \n body = getBody(),\n docOverflow = setFakeBody(body),\n div = doc.createElement('div'), \n result = false;\n\n body.appendChild(div);\n try {\n var str = '(10px * 10)',\n vals = ['calc' + str, '-moz-calc' + str, '-webkit-calc' + str],\n val;\n for (var i = 0; i < 3; i++) {\n val = vals[i];\n div.style.width = val;\n if (div.offsetWidth === 100) { \n result = val.replace(str, ''); \n break;\n }\n }\n } catch (e) {}\n \n body.fake ? resetFakeBody(body, docOverflow) : div.remove();\n\n return result;\n}\n\n// get subpixel support value\n\nfunction percentageLayout() {\n // check subpixel layout supporting\n var doc = document,\n body = getBody(),\n docOverflow = setFakeBody(body),\n wrapper = doc.createElement('div'),\n outer = doc.createElement('div'),\n str = '',\n count = 70,\n perPage = 3,\n supported = false;\n\n wrapper.className = \"tns-t-subp2\";\n outer.className = \"tns-t-ct\";\n\n for (var i = 0; i < count; i++) {\n str += '
';\n }\n\n outer.innerHTML = str;\n wrapper.appendChild(outer);\n body.appendChild(wrapper);\n\n supported = Math.abs(wrapper.getBoundingClientRect().left - outer.children[count - perPage].getBoundingClientRect().left) < 2;\n\n body.fake ? resetFakeBody(body, docOverflow) : wrapper.remove();\n\n return supported;\n}\n\nfunction mediaquerySupport () {\n var doc = document,\n body = getBody(),\n docOverflow = setFakeBody(body),\n div = doc.createElement('div'),\n style = doc.createElement('style'),\n rule = '@media all and (min-width:1px){.tns-mq-test{position:absolute}}',\n position;\n\n style.type = 'text/css';\n div.className = 'tns-mq-test';\n\n body.appendChild(style);\n body.appendChild(div);\n\n if (style.styleSheet) {\n style.styleSheet.cssText = rule;\n } else {\n style.appendChild(doc.createTextNode(rule));\n }\n\n position = window.getComputedStyle ? window.getComputedStyle(div).position : div.currentStyle['position'];\n\n body.fake ? resetFakeBody(body, docOverflow) : div.remove();\n\n return position === \"absolute\";\n}\n\n// create and append style sheet\nfunction createStyleSheet (media) {\n // Create the