(function(global,factory){typeof exports==='object'&&typeof module!=='undefined'?factory(exports):typeof define==='function'&&define.amd?define(['exports'],factory):(global=global||self,factory(global.window=global.window||{}))}(this,(function(exports){'use strict';function _inheritsLoose(subClass,superClass){subClass.prototype=Object.create(superClass.prototype);subClass.prototype.constructor=subClass;subClass.__proto__=superClass} function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn't been initialised - super() hasn't been called")} return self}/*! * GSAP 3.11.3 * https://greensock.com * * @license Copyright 2008-2022, GreenSock. All rights reserved. * Subject to the terms at https://greensock.com/standard-license or for * Club GreenSock members, the agreement issued with that membership. * @author: Jack Doyle, jack@greensock.com */ var _config={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},_defaults={duration:.5,overwrite:!1,delay:0},_suppressOverwrites,_reverting,_context,_bigNum=1e8,_tinyNum=1/_bigNum,_2PI=Math.PI*2,_HALF_PI=_2PI/4,_gsID=0,_sqrt=Math.sqrt,_cos=Math.cos,_sin=Math.sin,_isString=function _isString(value){return typeof value==="string"},_isFunction=function _isFunction(value){return typeof value==="function"},_isNumber=function _isNumber(value){return typeof value==="number"},_isUndefined=function _isUndefined(value){return typeof value==="undefined"},_isObject=function _isObject(value){return typeof value==="object"},_isNotFalse=function _isNotFalse(value){return value!==!1},_windowExists=function _windowExists(){return typeof window!=="undefined"},_isFuncOrString=function _isFuncOrString(value){return _isFunction(value)||_isString(value)},_isTypedArray=typeof ArrayBuffer==="function"&&ArrayBuffer.isView||function(){},_isArray=Array.isArray,_strictNumExp=/(?:-?\.?\d|\.)+/gi,_numExp=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,_numWithUnitExp=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,_complexStringNumExp=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,_relExp=/[+-]=-?[.\d]+/,_delimitedValueExp=/[^,'"\[\]\s]+/gi,_unitExp=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,_globalTimeline,_win,_coreInitted,_doc,_globals={},_installScope={},_coreReady,_install=function _install(scope){return(_installScope=_merge(scope,_globals))&&gsap},_missingPlugin=function _missingPlugin(property,value){return console.warn("Invalid property",property,"set to",value,"Missing plugin? gsap.registerPlugin()")},_warn=function _warn(message,suppress){return!suppress&&console.warn(message)},_addGlobal=function _addGlobal(name,obj){return name&&(_globals[name]=obj)&&_installScope&&(_installScope[name]=obj)||_globals},_emptyFunc=function _emptyFunc(){return 0},_startAtRevertConfig={suppressEvents:!0,isStart:!0,kill:!1},_revertConfigNoKill={suppressEvents:!0,kill:!1},_revertConfig={suppressEvents:!0},_reservedProps={},_lazyTweens=[],_lazyLookup={},_lastRenderedFrame,_plugins={},_effects={},_nextGCFrame=30,_harnessPlugins=[],_callbackNames="",_harness=function _harness(targets){var target=targets[0],harnessPlugin,i;_isObject(target)||_isFunction(target)||(targets=[targets]);if(!(harnessPlugin=(target._gsap||{}).harness)){i=_harnessPlugins.length;while(i--&&!_harnessPlugins[i].targetTest(target)){} harnessPlugin=_harnessPlugins[i]} i=targets.length;while(i--){targets[i]&&(targets[i]._gsap||(targets[i]._gsap=new GSCache(targets[i],harnessPlugin)))||targets.splice(i,1)} return targets},_getCache=function _getCache(target){return target._gsap||_harness(toArray(target))[0]._gsap},_getProperty=function _getProperty(target,property,v){return(v=target[property])&&_isFunction(v)?target[property]():_isUndefined(v)&&target.getAttribute&&target.getAttribute(property)||v},_forEachName=function _forEachName(names,func){return(names=names.split(",")).forEach(func)||names},_round=function _round(value){return Math.round(value*100000)/100000||0},_roundPrecise=function _roundPrecise(value){return Math.round(value*10000000)/10000000||0},_parseRelative=function _parseRelative(start,value){var operator=value.charAt(0),end=parseFloat(value.substr(2));start=parseFloat(start);return operator==="+"?start+end:operator==="-"?start-end:operator==="*"?start*end:start/end},_arrayContainsAny=function _arrayContainsAny(toSearch,toFind){var l=toFind.length,i=0;for(;toSearch.indexOf(toFind[i])<0&&++it){prev=prev._prev}} if(prev){child._next=prev._next;prev._next=child}else{child._next=parent[firstProp];parent[firstProp]=child} if(child._next){child._next._prev=child}else{parent[lastProp]=child} child._prev=prev;child.parent=child._dp=parent;return child},_removeLinkedListItem=function _removeLinkedListItem(parent,child,firstProp,lastProp){if(firstProp===void 0){firstProp="_first"} if(lastProp===void 0){lastProp="_last"} var prev=child._prev,next=child._next;if(prev){prev._next=next}else if(parent[firstProp]===child){parent[firstProp]=next} if(next){next._prev=prev}else if(parent[lastProp]===child){parent[lastProp]=prev} child._next=child._prev=child.parent=null},_removeFromParent=function _removeFromParent(child,onlyIfParentHasAutoRemove){child.parent&&(!onlyIfParentHasAutoRemove||child.parent.autoRemoveChildren)&&child.parent.remove(child);child._act=0},_uncache=function _uncache(animation,child){if(animation&&(!child||child._end>animation._dur||child._start<0)){var a=animation;while(a){a._dirty=1;a=a.parent}} return animation},_recacheAncestors=function _recacheAncestors(animation){var parent=animation.parent;while(parent&&parent.parent){parent._dirty=1;parent.totalDuration();parent=parent.parent} return animation},_rewindStartAt=function _rewindStartAt(tween,totalTime,suppressEvents,force){return tween._startAt&&(_reverting?tween._startAt.revert(_revertConfigNoKill):tween.vars.immediateRender&&!tween.vars.autoRevert||tween._startAt.render(totalTime,!0,force))},_hasNoPausedAncestors=function _hasNoPausedAncestors(animation){return!animation||animation._ts&&_hasNoPausedAncestors(animation.parent)},_elapsedCycleDuration=function _elapsedCycleDuration(animation){return animation._repeat?_animationCycle(animation._tTime,animation=animation.duration()+animation._rDelay)*animation:0},_animationCycle=function _animationCycle(tTime,cycleDuration){var whole=Math.floor(tTime/=cycleDuration);return tTime&&whole===tTime?whole-1:whole},_parentToChildTotalTime=function _parentToChildTotalTime(parentTime,child){return(parentTime-child._start)*child._ts+(child._ts>=0?0:child._dirty?child.totalDuration():child._tDur)},_setEnd=function _setEnd(animation){return animation._end=_roundPrecise(animation._start+(animation._tDur/Math.abs(animation._ts||animation._rts||_tinyNum)||0))},_alignPlayhead=function _alignPlayhead(animation,totalTime){var parent=animation._dp;if(parent&&parent.smoothChildTiming&&animation._ts){animation._start=_roundPrecise(parent._time-(animation._ts>0?totalTime/animation._ts:((animation._dirty?animation.totalDuration():animation._tDur)-totalTime)/-animation._ts));_setEnd(animation);parent._dirty||_uncache(parent,animation)} return animation},_postAddChecks=function _postAddChecks(timeline,child){var t;if(child._time||child._initted&&!child._dur){t=_parentToChildTotalTime(timeline.rawTime(),child);if(!child._dur||_clamp(0,child.totalDuration(),t)-child._tTime>_tinyNum){child.render(t,!0)}} if(_uncache(timeline,child)._dp&&timeline._initted&&timeline._time>=timeline._dur&&timeline._ts){if(timeline._dur=0&&t.totalTime(t._tTime);t=t._dp}} timeline._zTime=-_tinyNum}},_addToTimeline=function _addToTimeline(timeline,child,position,skipChecks){child.parent&&_removeFromParent(child);child._start=_roundPrecise((_isNumber(position)?position:position||timeline!==_globalTimeline?_parsePosition(timeline,position,child):timeline._time)+child._delay);child._end=_roundPrecise(child._start+(child.totalDuration()/Math.abs(child.timeScale())||0));_addLinkedListItem(timeline,child,"_first","_last",timeline._sort?"_start":0);_isFromOrFromStart(child)||(timeline._recent=child);skipChecks||_postAddChecks(timeline,child);timeline._ts<0&&_alignPlayhead(timeline,timeline._tTime);return timeline},_scrollTrigger=function _scrollTrigger(animation,trigger){return(_globals.ScrollTrigger||_missingPlugin("scrollTrigger",trigger))&&_globals.ScrollTrigger.create(trigger,animation)},_attemptInitTween=function _attemptInitTween(tween,time,force,suppressEvents,tTime){_initTween(tween,time,tTime);if(!tween._initted){return 1} if(!force&&tween._pt&&!_reverting&&(tween._dur&&tween.vars.lazy!==!1||!tween._dur&&tween.vars.lazy)&&_lastRenderedFrame!==_ticker.frame){_lazyTweens.push(tween);tween._lazy=[tTime,suppressEvents];return 1}},_parentPlayheadIsBeforeStart=function _parentPlayheadIsBeforeStart(_ref){var parent=_ref.parent;return parent&&parent._ts&&parent._initted&&!parent._lock&&(parent.rawTime()<0||_parentPlayheadIsBeforeStart(parent))},_isFromOrFromStart=function _isFromOrFromStart(_ref2){var data=_ref2.data;return data==="isFromStart"||data==="isStart"},_renderZeroDurationTween=function _renderZeroDurationTween(tween,totalTime,suppressEvents,force){var prevRatio=tween.ratio,ratio=totalTime<0||!totalTime&&(!tween._start&&_parentPlayheadIsBeforeStart(tween)&&!(!tween._initted&&_isFromOrFromStart(tween))||(tween._ts<0||tween._dp._ts<0)&&!_isFromOrFromStart(tween))?0:1,repeatDelay=tween._rDelay,tTime=0,pt,iteration,prevIteration;if(repeatDelay&&tween._repeat){tTime=_clamp(0,tween._tDur,totalTime);iteration=_animationCycle(tTime,repeatDelay);tween._yoyo&&iteration&1&&(ratio=1-ratio);if(iteration!==_animationCycle(tween._tTime,repeatDelay)){prevRatio=1-ratio;tween.vars.repeatRefresh&&tween._initted&&tween.invalidate()}} if(ratio!==prevRatio||_reverting||force||tween._zTime===_tinyNum||!totalTime&&tween._zTime){if(!tween._initted&&_attemptInitTween(tween,totalTime,force,suppressEvents,tTime)){return} prevIteration=tween._zTime;tween._zTime=totalTime||(suppressEvents?_tinyNum:0);suppressEvents||(suppressEvents=totalTime&&!prevIteration);tween.ratio=ratio;tween._from&&(ratio=1-ratio);tween._time=0;tween._tTime=tTime;pt=tween._pt;while(pt){pt.r(ratio,pt.d);pt=pt._next} totalTime<0&&_rewindStartAt(tween,totalTime,suppressEvents,!0);tween._onUpdate&&!suppressEvents&&_callback(tween,"onUpdate");tTime&&tween._repeat&&!suppressEvents&&tween.parent&&_callback(tween,"onRepeat");if((totalTime>=tween._tDur||totalTime<0)&&tween.ratio===ratio){ratio&&_removeFromParent(tween,1);if(!suppressEvents&&!_reverting){_callback(tween,ratio?"onComplete":"onReverseComplete",!0);tween._prom&&tween._prom()}}}else if(!tween._zTime){tween._zTime=totalTime}},_findNextPauseTween=function _findNextPauseTween(animation,prevTime,time){var child;if(time>prevTime){child=animation._first;while(child&&child._start<=time){if(child.data==="isPause"&&child._start>prevTime){return child} child=child._next}}else{child=animation._last;while(child&&child._start>=time){if(child.data==="isPause"&&child._start0&&!leavePlayhead&&_alignPlayhead(animation,animation._tTime=animation._tDur*totalProgress);animation.parent&&_setEnd(animation);skipUncache||_uncache(animation.parent,animation);return animation},_onUpdateTotalDuration=function _onUpdateTotalDuration(animation){return animation instanceof Timeline?_uncache(animation):_setDuration(animation,animation._dur)},_zeroPosition={_start:0,endTime:_emptyFunc,totalDuration:_emptyFunc},_parsePosition=function _parsePosition(animation,position,percentAnimation){var labels=animation.labels,recent=animation._recent||_zeroPosition,clippedDuration=animation.duration()>=_bigNum?recent.endTime(!1):animation._dur,i,offset,isPercent;if(_isString(position)&&(isNaN(position)||position in labels)){offset=position.charAt(0);isPercent=position.substr(-1)==="%";i=position.indexOf("=");if(offset==="<"||offset===">"){i>=0&&(position=position.replace(/=/,""));return(offset==="<"?recent._start:recent.endTime(recent._repeat>=0))+(parseFloat(position.substr(1))||0)*(isPercent?(i<0?recent:percentAnimation).totalDuration()/100:1)} if(i<0){position in labels||(labels[position]=clippedDuration);return labels[position]} offset=parseFloat(position.charAt(i-1)+position.substr(i+1));if(isPercent&&percentAnimation){offset=offset/100*(_isArray(percentAnimation)?percentAnimation[0]:percentAnimation).totalDuration()} return i>1?_parsePosition(animation,position.substr(0,i-1),percentAnimation)+offset:clippedDuration+offset} return position==null?clippedDuration:+position},_createTweenType=function _createTweenType(type,params,timeline){var isLegacy=_isNumber(params[1]),varsIndex=(isLegacy?2:1)+(type<2?0:1),vars=params[varsIndex],irVars,parent;isLegacy&&(vars.duration=params[1]);vars.parent=timeline;if(type){irVars=vars;parent=timeline;while(parent&&!("immediateRender" in irVars)){irVars=parent.vars.defaults||{};parent=_isNotFalse(parent.vars.inherit)&&parent.parent} vars.immediateRender=_isNotFalse(irVars.immediateRender);type<2?vars.runBackwards=1:vars.startAt=params[varsIndex-1]} return new Tween(params[0],vars,params[varsIndex+1])},_conditionalReturn=function _conditionalReturn(value,func){return value||value===0?func(value):func},_clamp=function _clamp(min,max,value){return valuemax?max:value},getUnit=function getUnit(value,v){return!_isString(value)||!(v=_unitExp.exec(value))?"":v[1]},clamp=function clamp(min,max,value){return _conditionalReturn(value,function(v){return _clamp(min,max,v)})},_slice=[].slice,_isArrayLike=function _isArrayLike(value,nonEmpty){return value&&_isObject(value)&&"length" in value&&(!nonEmpty&&!value.length||value.length-1 in value&&_isObject(value[0]))&&!value.nodeType&&value!==_win},_flatten=function _flatten(ar,leaveStrings,accumulator){if(accumulator===void 0){accumulator=[]} return ar.forEach(function(value){var _accumulator;return _isString(value)&&!leaveStrings||_isArrayLike(value,1)?(_accumulator=accumulator).push.apply(_accumulator,toArray(value)):accumulator.push(value)})||accumulator},toArray=function toArray(value,scope,leaveStrings){return _context&&!scope&&_context.selector?_context.selector(value):_isString(value)&&!leaveStrings&&(_coreInitted||!_wake())?_slice.call((scope||_doc).querySelectorAll(value),0):_isArray(value)?_flatten(value,leaveStrings):_isArrayLike(value)?_slice.call(value,0):value?[value]:[]},selector=function selector(value){value=toArray(value)[0]||_warn("Invalid scope")||{};return function(v){var el=value.current||value.nativeElement||value;return toArray(v,el.querySelectorAll?el:el===value?_warn("Invalid scope")||_doc.createElement("div"):value)}},shuffle=function shuffle(a){return a.sort(function(){return.5-Math.random()})},distribute=function distribute(v){if(_isFunction(v)){return v} var vars=_isObject(v)?v:{each:v},ease=_parseEase(vars.ease),from=vars.from||0,base=parseFloat(vars.base)||0,cache={},isDecimal=from>0&&from<1,ratios=isNaN(from)||isDecimal,axis=vars.axis,ratioX=from,ratioY=from;if(_isString(from)){ratioX=ratioY={center:.5,edges:.5,end:1}[from]||0}else if(!isDecimal&&ratios){ratioX=from[0];ratioY=from[1]} return function(i,target,a){var l=(a||vars).length,distances=cache[l],originX,originY,x,y,d,j,max,min,wrapAt;if(!distances){wrapAt=vars.grid==="auto"?0:(vars.grid||[1,_bigNum])[1];if(!wrapAt){max=-_bigNum;while(max<(max=a[wrapAt++].getBoundingClientRect().left)&&wrapAtmax&&(max=d);dl?l-1:!axis?Math.max(wrapAt,l/wrapAt):axis==="y"?l/wrapAt:wrapAt)||0)*(from==="edges"?-1:1);distances.b=l<0?base-l:base;distances.u=getUnit(vars.amount||vars.each)||0;ease=ease&&l<0?_invertEase(ease):ease} l=(distances[i]-distances.min)/distances.max||0;return _roundPrecise(distances.b+(ease?ease(l):l)*distances.v)+distances.u}},_roundModifier=function _roundModifier(v){var p=Math.pow(10,((v+"").split(".")[1]||"").length);return function(raw){var n=_roundPrecise(Math.round(parseFloat(raw)/v)*v*p);return(n-n%1)/p+(_isNumber(raw)?0:getUnit(raw))}},snap=function snap(snapTo,value){var isArray=_isArray(snapTo),radius,is2D;if(!isArray&&_isObject(snapTo)){radius=isArray=snapTo.radius||_bigNum;if(snapTo.values){snapTo=toArray(snapTo.values);if(is2D=!_isNumber(snapTo[0])){radius*=radius}}else{snapTo=_roundModifier(snapTo.increment)}} return _conditionalReturn(value,!isArray?_roundModifier(snapTo):_isFunction(snapTo)?function(raw){is2D=snapTo(raw);return Math.abs(is2D-raw)<=radius?is2D:raw}:function(raw){var x=parseFloat(is2D?raw.x:raw),y=parseFloat(is2D?raw.y:0),min=_bigNum,closest=0,i=snapTo.length,dx,dy;while(i--){if(is2D){dx=snapTo[i].x-x;dy=snapTo[i].y-y;dx=dx*dx+dy*dy}else{dx=Math.abs(snapTo[i]-x)} if(dxrange?total-value:value)})},_replaceRandom=function _replaceRandom(value){var prev=0,s="",i,nums,end,isArray;while(~(i=value.indexOf("random(",prev))){end=value.indexOf(")",i);isArray=value.charAt(i+7)==="[";nums=value.substr(i+7,end-i-7).match(isArray?_delimitedValueExp:_strictNumExp);s+=value.substr(prev,i-prev)+random(isArray?nums:+nums[0],isArray?0:+nums[1],+nums[2]||1e-5);prev=end+1} return s+value.substr(prev,value.length-prev)},mapRange=function mapRange(inMin,inMax,outMin,outMax,value){var inRange=inMax-inMin,outRange=outMax-outMin;return _conditionalReturn(value,function(value){return outMin+((value-inMin)/inRange*outRange||0)})},interpolate=function interpolate(start,end,progress,mutate){var func=isNaN(start+end)?0:function(p){return(1-p)*start+p*end};if(!func){var isString=_isString(start),master={},p,i,interpolators,l,il;progress===!0&&(mutate=1)&&(progress=null);if(isString){start={p:start};end={p:end}}else if(_isArray(start)&&!_isArray(end)){interpolators=[];l=start.length;il=l-2;for(i=1;i(distance=Math.abs(distance))){label=p;min=distance}} return label},_callback=function _callback(animation,type,executeLazyFirst){var v=animation.vars,callback=v[type],prevContext=_context,context=animation._ctx,params,scope,result;if(!callback){return} params=v[type+"Params"];scope=v.callbackScope||animation;executeLazyFirst&&_lazyTweens.length&&_lazyRender();context&&(_context=context);result=params?callback.apply(scope,params):callback.call(scope);_context=prevContext;return result},_interrupt=function _interrupt(animation){_removeFromParent(animation);animation.scrollTrigger&&animation.scrollTrigger.kill(!!_reverting);animation.progress()<1&&_callback(animation,"onInterrupt");return animation},_quickTween,_createPlugin=function _createPlugin(config){config=!config.name&&config["default"]||config;var name=config.name,isFunc=_isFunction(config),Plugin=name&&!isFunc&&config.init?function(){this._props=[]}:config,instanceDefaults={init:_emptyFunc,render:_renderPropTweens,add:_addPropTween,kill:_killPropTweensOf,modifier:_addPluginModifier,rawVars:0},statics={targetTest:0,get:0,getSetter:_getSetter,aliases:{},register:0};_wake();if(config!==Plugin){if(_plugins[name]){return} _setDefaults(Plugin,_setDefaults(_copyExcluding(config,instanceDefaults),statics));_merge(Plugin.prototype,_merge(instanceDefaults,_copyExcluding(config,statics)));_plugins[Plugin.prop=name]=Plugin;if(config.targetTest){_harnessPlugins.push(Plugin);_reservedProps[name]=1} name=(name==="css"?"CSS":name.charAt(0).toUpperCase()+name.substr(1))+"Plugin"} _addGlobal(name,Plugin);config.register&&config.register(gsap,Plugin,PropTween)},_255=255,_colorLookup={aqua:[0,_255,_255],lime:[0,_255,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,_255],navy:[0,0,128],white:[_255,_255,_255],olive:[128,128,0],yellow:[_255,_255,0],orange:[_255,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[_255,0,0],pink:[_255,192,203],cyan:[0,_255,_255],transparent:[_255,_255,_255,0]},_hue=function _hue(h,m1,m2){h+=h<0?1:h>1?-1:0;return(h*6<1?m1+(m2-m1)*h*6:h<.5?m2:h*3<2?m1+(m2-m1)*(2/3-h)*6:m1)*_255+.5|0},splitColor=function splitColor(v,toHSL,forceAlpha){var a=!v?_colorLookup.black:_isNumber(v)?[v>>16,v>>8&_255,v&_255]:0,r,g,b,h,s,l,max,min,d,wasHSL;if(!a){if(v.substr(-1)===","){v=v.substr(0,v.length-1)} if(_colorLookup[v]){a=_colorLookup[v]}else if(v.charAt(0)==="#"){if(v.length<6){r=v.charAt(1);g=v.charAt(2);b=v.charAt(3);v="#"+r+r+g+g+b+b+(v.length===5?v.charAt(4)+v.charAt(4):"")} if(v.length===9){a=parseInt(v.substr(1,6),16);return[a>>16,a>>8&_255,a&_255,parseInt(v.substr(7),16)/255]} v=parseInt(v.substr(1),16);a=[v>>16,v>>8&_255,v&_255]}else if(v.substr(0,3)==="hsl"){a=wasHSL=v.match(_strictNumExp);if(!toHSL){h=+a[0]%360/360;s=+a[1]/100;l=+a[2]/100;g=l<=.5?l*(s+1):l+s-l*s;r=l*2-g;a.length>3&&(a[3]*=1);a[0]=_hue(h+1/3,r,g);a[1]=_hue(h,r,g);a[2]=_hue(h-1/3,r,g)}else if(~v.indexOf("=")){a=v.match(_numExp);forceAlpha&&a.length<4&&(a[3]=1);return a}}else{a=v.match(_strictNumExp)||_colorLookup.transparent} a=a.map(Number)} if(toHSL&&!wasHSL){r=a[0]/_255;g=a[1]/_255;b=a[2]/_255;max=Math.max(r,g,b);min=Math.min(r,g,b);l=(max+min)/2;if(max===min){h=s=0}else{d=max-min;s=l>0.5?d/(2-max-min):d/(max+min);h=max===r?(g-b)/d+(g_lagThreshold&&(_startTime+=elapsed-_adjustedLag);_lastUpdate+=elapsed;time=_lastUpdate-_startTime;overlap=time-_nextTime;if(overlap>0||manual){frame=++_self.frame;_delta=time-_self.time*1000;_self.time=time=time/1000;_nextTime+=overlap+(overlap>=_gap?4:_gap-overlap);dispatch=1} manual||(_id=_req(_tick));if(dispatch){for(_i=0;_i<_listeners.length;_i++){_listeners[_i](time,_delta,frame,v)}}};_self={time:0,frame:0,tick:function tick(){_tick(!0)},deltaRatio:function deltaRatio(fps){return _delta/(1000/(fps||60))},wake:function wake(){if(_coreReady){if(!_coreInitted&&_windowExists()){_win=_coreInitted=window;_doc=_win.document||{};_globals.gsap=gsap;(_win.gsapVersions||(_win.gsapVersions=[])).push(gsap.version);_install(_installScope||_win.GreenSockGlobals||!_win.gsap&&_win||{});_raf=_win.requestAnimationFrame} _id&&_self.sleep();_req=_raf||function(f){return setTimeout(f,_nextTime-_self.time*1000+1|0)};_tickerActive=1;_tick(2)}},sleep:function sleep(){(_raf?_win.cancelAnimationFrame:clearTimeout)(_id);_tickerActive=0;_req=_emptyFunc},lagSmoothing:function lagSmoothing(threshold,adjustedLag){_lagThreshold=threshold||1/_tinyNum;_adjustedLag=Math.min(adjustedLag,_lagThreshold,0)},fps:function fps(_fps){_gap=1000/(_fps||240);_nextTime=_self.time*1000+_gap},add:function add(callback,once,prioritize){var func=once?function(t,d,f,v){callback(t,d,f,v);_self.remove(func)}:callback;_self.remove(callback);_listeners[prioritize?"unshift":"push"](func);_wake();return func},remove:function remove(callback,i){~(i=_listeners.indexOf(callback))&&_listeners.splice(i,1)&&_i>=i&&_i--},_listeners:_listeners};return _self}(),_wake=function _wake(){return!_tickerActive&&_ticker.wake()},_easeMap={},_customEaseExp=/^[\d.\-M][\d.\-,\s]/,_quotesExp=/["']/g,_parseObjectInString=function _parseObjectInString(value){var obj={},split=value.substr(1,value.length-3).split(":"),key=split[0],i=1,l=split.length,index,val,parsedVal;for(;i1&&ease.config?ease.config.apply(null,~name.indexOf("{")?[_parseObjectInString(split[1])]:_valueInParentheses(name).split(",").map(_numericIfPossible)):_easeMap._CE&&_customEaseExp.test(name)?_easeMap._CE("",name):ease},_invertEase=function _invertEase(ease){return function(p){return 1-ease(1-p)}},_propagateYoyoEase=function _propagateYoyoEase(timeline,isYoyo){var child=timeline._first,ease;while(child){if(child instanceof Timeline){_propagateYoyoEase(child,isYoyo)}else if(child.vars.yoyoEase&&(!child._yoyo||!child._repeat)&&child._yoyo!==isYoyo){if(child.timeline){_propagateYoyoEase(child.timeline,isYoyo)}else{ease=child._ease;child._ease=child._yEase;child._yEase=ease;child._yoyo=isYoyo}} child=child._next}},_parseEase=function _parseEase(ease,defaultEase){return!ease?defaultEase:(_isFunction(ease)?ease:_easeMap[ease]||_configEaseFromString(ease))||defaultEase},_insertEase=function _insertEase(names,easeIn,easeOut,easeInOut){if(easeOut===void 0){easeOut=function easeOut(p){return 1-easeIn(1-p)}} if(easeInOut===void 0){easeInOut=function easeInOut(p){return p<.5?easeIn(p*2)/2:1-easeIn((1-p)*2)/2}} var ease={easeIn:easeIn,easeOut:easeOut,easeInOut:easeInOut},lowercaseName;_forEachName(names,function(name){_easeMap[name]=_globals[name]=ease;_easeMap[lowercaseName=name.toLowerCase()]=easeOut;for(var p in ease){_easeMap[lowercaseName+(p==="easeIn"?".in":p==="easeOut"?".out":".inOut")]=_easeMap[name+"."+p]=ease[p]}});return ease},_easeInOutFromOut=function _easeInOutFromOut(easeOut){return function(p){return p<.5?(1-easeOut(1-p*2))/2:.5+easeOut((p-.5)*2)/2}},_configElastic=function _configElastic(type,amplitude,period){var p1=amplitude>=1?amplitude:1,p2=(period||(type?.3:.45))/(amplitude<1?amplitude:1),p3=p2/_2PI*(Math.asin(1/p1)||0),easeOut=function easeOut(p){return p===1?1:p1*Math.pow(2,-10*p)*_sin((p-p3)*p2)+1},ease=type==="out"?easeOut:type==="in"?function(p){return 1-easeOut(1-p)}:_easeInOutFromOut(easeOut);p2=_2PI/p2;ease.config=function(amplitude,period){return _configElastic(type,amplitude,period)};return ease},_configBack=function _configBack(type,overshoot){if(overshoot===void 0){overshoot=1.70158} var easeOut=function easeOut(p){return p?--p*p*((overshoot+1)*p+overshoot)+1:0},ease=type==="out"?easeOut:type==="in"?function(p){return 1-easeOut(1-p)}:_easeInOutFromOut(easeOut);ease.config=function(overshoot){return _configBack(type,overshoot)};return ease};_forEachName("Linear,Quad,Cubic,Quart,Quint,Strong",function(name,i){var power=i<5?i+1:i;_insertEase(name+",Power"+(power-1),i?function(p){return Math.pow(p,power)}:function(p){return p},function(p){return 1-Math.pow(1-p,power)},function(p){return p<.5?Math.pow(p*2,power)/2:1-Math.pow((1-p)*2,power)/2})});_easeMap.Linear.easeNone=_easeMap.none=_easeMap.Linear.easeIn;_insertEase("Elastic",_configElastic("in"),_configElastic("out"),_configElastic());(function(n,c){var n1=1/c,n2=2*n1,n3=2.5*n1,easeOut=function easeOut(p){return p0?value+(value+this._rDelay)*this._repeat:value):this.totalDuration()&&this._dur};_proto.totalDuration=function totalDuration(value){if(!arguments.length){return this._tDur} this._dirty=0;return _setDuration(this,this._repeat<0?value:(value-this._repeat*this._rDelay)/(this._repeat+1))};_proto.totalTime=function totalTime(_totalTime,suppressEvents){_wake();if(!arguments.length){return this._tTime} var parent=this._dp;if(parent&&parent.smoothChildTiming&&this._ts){_alignPlayhead(this,_totalTime);!parent._dp||parent.parent||_postAddChecks(parent,this);while(parent&&parent.parent){if(parent.parent._time!==parent._start+(parent._ts>=0?parent._tTime/parent._ts:(parent.totalDuration()-parent._tTime)/-parent._ts)){parent.totalTime(parent._tTime,!0)} parent=parent.parent} if(!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&_totalTime0||!this._tDur&&!_totalTime)){_addToTimeline(this._dp,this,this._start-this._delay)}} if(this._tTime!==_totalTime||!this._dur&&!suppressEvents||this._initted&&Math.abs(this._zTime)===_tinyNum||!_totalTime&&!this._initted&&(this.add||this._ptLookup)){this._ts||(this._pTime=_totalTime);_lazySafeRender(this,_totalTime,suppressEvents)} return this};_proto.time=function time(value,suppressEvents){return arguments.length?this.totalTime(Math.min(this.totalDuration(),value+_elapsedCycleDuration(this))%(this._dur+this._rDelay)||(value?this._dur:0),suppressEvents):this._time};_proto.totalProgress=function totalProgress(value,suppressEvents){return arguments.length?this.totalTime(this.totalDuration()*value,suppressEvents):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.ratio};_proto.progress=function progress(value,suppressEvents){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&!(this.iteration()&1)?1-value:value)+_elapsedCycleDuration(this),suppressEvents):this.duration()?Math.min(1,this._time/this._dur):this.ratio};_proto.iteration=function iteration(value,suppressEvents){var cycleDuration=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(value-1)*cycleDuration,suppressEvents):this._repeat?_animationCycle(this._tTime,cycleDuration)+1:1};_proto.timeScale=function timeScale(value){if(!arguments.length){return this._rts===-_tinyNum?0:this._rts} if(this._rts===value){return this} var tTime=this.parent&&this._ts?_parentToChildTotalTime(this.parent._time,this):this._tTime;this._rts=+value||0;this._ts=this._ps||value===-_tinyNum?0:this._rts;this.totalTime(_clamp(-this._delay,this._tDur,tTime),!0);_setEnd(this);return _recacheAncestors(this)};_proto.paused=function paused(value){if(!arguments.length){return this._ps} if(this._ps!==value){this._ps=value;if(value){this._pTime=this._tTime||Math.max(-this._delay,this.rawTime());this._ts=this._act=0}else{_wake();this._ts=this._rts;this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,this.progress()===1&&Math.abs(this._zTime)!==_tinyNum&&(this._tTime-=_tinyNum))}} return this};_proto.startTime=function startTime(value){if(arguments.length){this._start=value;var parent=this.parent||this._dp;parent&&(parent._sort||!this.parent)&&_addToTimeline(parent,this,value-this._delay);return this} return this._start};_proto.endTime=function endTime(includeRepeats){return this._start+(_isNotFalse(includeRepeats)?this.totalDuration():this.duration())/Math.abs(this._ts||1)};_proto.rawTime=function rawTime(wrapRepeats){var parent=this.parent||this._dp;return!parent?this._tTime:wrapRepeats&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):!this._ts?this._tTime:_parentToChildTotalTime(parent.rawTime(wrapRepeats),this)};_proto.revert=function revert(config){if(config===void 0){config=_revertConfig} var prevIsReverting=_reverting;_reverting=config;if(this._initted||this._startAt){this.timeline&&this.timeline.revert(config);this.totalTime(-0.01,config.suppressEvents)} this.data!=="nested"&&config.kill!==!1&&this.kill();_reverting=prevIsReverting;return this};_proto.globalTime=function globalTime(rawTime){var animation=this,time=arguments.length?rawTime:animation.rawTime();while(animation){time=animation._start+time/(animation._ts||1);animation=animation._dp} return!this.parent&&this.vars.immediateRender?-1:time};_proto.repeat=function repeat(value){if(arguments.length){this._repeat=value===Infinity?-2:value;return _onUpdateTotalDuration(this)} return this._repeat===-2?Infinity:this._repeat};_proto.repeatDelay=function repeatDelay(value){if(arguments.length){var time=this._time;this._rDelay=value;_onUpdateTotalDuration(this);return time?this.time(time):this} return this._rDelay};_proto.yoyo=function yoyo(value){if(arguments.length){this._yoyo=value;return this} return this._yoyo};_proto.seek=function seek(position,suppressEvents){return this.totalTime(_parsePosition(this,position),_isNotFalse(suppressEvents))};_proto.restart=function restart(includeDelay,suppressEvents){return this.play().totalTime(includeDelay?-this._delay:0,_isNotFalse(suppressEvents))};_proto.play=function play(from,suppressEvents){from!=null&&this.seek(from,suppressEvents);return this.reversed(!1).paused(!1)};_proto.reverse=function reverse(from,suppressEvents){from!=null&&this.seek(from||this.totalDuration(),suppressEvents);return this.reversed(!0).paused(!1)};_proto.pause=function pause(atTime,suppressEvents){atTime!=null&&this.seek(atTime,suppressEvents);return this.paused(!0)};_proto.resume=function resume(){return this.paused(!1)};_proto.reversed=function reversed(value){if(arguments.length){!!value!==this.reversed()&&this.timeScale(-this._rts||(value?-_tinyNum:0));return this} return this._rts<0};_proto.invalidate=function invalidate(){this._initted=this._act=0;this._zTime=-_tinyNum;return this};_proto.isActive=function isActive(){var parent=this.parent||this._dp,start=this._start,rawTime;return!!(!parent||this._ts&&this._initted&&parent.isActive()&&(rawTime=parent.rawTime(!0))>=start&&rawTime1){if(!callback){delete vars[type]}else{vars[type]=callback;params&&(vars[type+"Params"]=params);type==="onUpdate"&&(this._onUpdate=callback)} return this} return vars[type]};_proto.then=function then(onFulfilled){var self=this;return new Promise(function(resolve){var f=_isFunction(onFulfilled)?onFulfilled:_passThrough,_resolve=function _resolve(){var _then=self.then;self.then=null;_isFunction(f)&&(f=f(self))&&(f.then||f===self)&&(self.then=_then);resolve(f);self.then=_then};if(self._initted&&self.totalProgress()===1&&self._ts>=0||!self._tTime&&self._ts<0){_resolve()}else{self._prom=_resolve}})};_proto.kill=function kill(){_interrupt(this)};return Animation}();_setDefaults(Animation.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-_tinyNum,_prom:0,_ps:!1,_rts:1});var Timeline=function(_Animation){_inheritsLoose(Timeline,_Animation);function Timeline(vars,position){var _this;if(vars===void 0){vars={}} _this=_Animation.call(this,vars)||this;_this.labels={};_this.smoothChildTiming=!!vars.smoothChildTiming;_this.autoRemoveChildren=!!vars.autoRemoveChildren;_this._sort=_isNotFalse(vars.sortChildren);_globalTimeline&&_addToTimeline(vars.parent||_globalTimeline,_assertThisInitialized(_this),position);vars.reversed&&_this.reverse();vars.paused&&_this.paused(!0);vars.scrollTrigger&&_scrollTrigger(_assertThisInitialized(_this),vars.scrollTrigger);return _this} var _proto2=Timeline.prototype;_proto2.to=function to(targets,vars,position){_createTweenType(0,arguments,this);return this};_proto2.from=function from(targets,vars,position){_createTweenType(1,arguments,this);return this};_proto2.fromTo=function fromTo(targets,fromVars,toVars,position){_createTweenType(2,arguments,this);return this};_proto2.set=function set(targets,vars,position){vars.duration=0;vars.parent=this;_inheritDefaults(vars).repeatDelay||(vars.repeat=0);vars.immediateRender=!!vars.immediateRender;new Tween(targets,vars,_parsePosition(this,position),1);return this};_proto2.call=function call(callback,params,position){return _addToTimeline(this,Tween.delayedCall(0,callback,params),position)};_proto2.staggerTo=function staggerTo(targets,duration,vars,stagger,position,onCompleteAll,onCompleteAllParams){vars.duration=duration;vars.stagger=vars.stagger||stagger;vars.onComplete=onCompleteAll;vars.onCompleteParams=onCompleteAllParams;vars.parent=this;new Tween(targets,vars,_parsePosition(this,position));return this};_proto2.staggerFrom=function staggerFrom(targets,duration,vars,stagger,position,onCompleteAll,onCompleteAllParams){vars.runBackwards=1;_inheritDefaults(vars).immediateRender=_isNotFalse(vars.immediateRender);return this.staggerTo(targets,duration,vars,stagger,position,onCompleteAll,onCompleteAllParams)};_proto2.staggerFromTo=function staggerFromTo(targets,duration,fromVars,toVars,stagger,position,onCompleteAll,onCompleteAllParams){toVars.startAt=fromVars;_inheritDefaults(toVars).immediateRender=_isNotFalse(toVars.immediateRender);return this.staggerTo(targets,duration,toVars,stagger,position,onCompleteAll,onCompleteAllParams)};_proto2.render=function render(totalTime,suppressEvents,force){var prevTime=this._time,tDur=this._dirty?this.totalDuration():this._tDur,dur=this._dur,tTime=totalTime<=0?0:_roundPrecise(totalTime),crossingStart=this._zTime<0!==totalTime<0&&(this._initted||!dur),time,child,next,iteration,cycleDuration,prevPaused,pauseTween,timeScale,prevStart,prevIteration,yoyo,isYoyo;this!==_globalTimeline&&tTime>tDur&&totalTime>=0&&(tTime=tDur);if(tTime!==this._tTime||force||crossingStart){if(prevTime!==this._time&&dur){tTime+=this._time-prevTime;totalTime+=this._time-prevTime} time=tTime;prevStart=this._start;timeScale=this._ts;prevPaused=!timeScale;if(crossingStart){dur||(prevTime=this._zTime);(totalTime||!suppressEvents)&&(this._zTime=totalTime)} if(this._repeat){yoyo=this._yoyo;cycleDuration=dur+this._rDelay;if(this._repeat<-1&&totalTime<0){return this.totalTime(cycleDuration*100+totalTime,suppressEvents,force)} time=_roundPrecise(tTime%cycleDuration);if(tTime===tDur){iteration=this._repeat;time=dur}else{iteration=~~(tTime/cycleDuration);if(iteration&&iteration===tTime/cycleDuration){time=dur;iteration--} time>dur&&(time=dur)} prevIteration=_animationCycle(this._tTime,cycleDuration);!prevTime&&this._tTime&&prevIteration!==iteration&&(prevIteration=iteration);if(yoyo&&iteration&1){time=dur-time;isYoyo=1} if(iteration!==prevIteration&&!this._lock){var rewinding=yoyo&&prevIteration&1,doesWrap=rewinding===(yoyo&&iteration&1);iteration=prevTime&&totalTime>=0){child=this._first;while(child){next=child._next;if((child._act||time>=child._start)&&child._ts&&pauseTween!==child){if(child.parent!==this){return this.render(totalTime,suppressEvents,force)} child.render(child._ts>0?(time-child._start)*child._ts:(child._dirty?child.totalDuration():child._tDur)+(time-child._start)*child._ts,suppressEvents,force);if(time!==this._time||!this._ts&&!prevPaused){pauseTween=0;next&&(tTime+=this._zTime=-_tinyNum);break}} child=next}}else{child=this._last;var adjustedTime=totalTime<0?totalTime:time;while(child){next=child._prev;if((child._act||adjustedTime<=child._end)&&child._ts&&pauseTween!==child){if(child.parent!==this){return this.render(totalTime,suppressEvents,force)} child.render(child._ts>0?(adjustedTime-child._start)*child._ts:(child._dirty?child.totalDuration():child._tDur)+(adjustedTime-child._start)*child._ts,suppressEvents,force||_reverting&&(child._initted||child._startAt));if(time!==this._time||!this._ts&&!prevPaused){pauseTween=0;next&&(tTime+=this._zTime=adjustedTime?-_tinyNum:_tinyNum);break}} child=next}} if(pauseTween&&!suppressEvents){this.pause();pauseTween.render(time>=prevTime?0:-_tinyNum)._zTime=time>=prevTime?1:-1;if(this._ts){this._start=prevStart;_setEnd(this);return this.render(totalTime,suppressEvents,force)}} this._onUpdate&&!suppressEvents&&_callback(this,"onUpdate",!0);if(tTime===tDur&&this._tTime>=this.totalDuration()||!tTime&&prevTime)if(prevStart===this._start||Math.abs(timeScale)!==Math.abs(this._ts))if(!this._lock){(totalTime||!dur)&&(tTime===tDur&&this._ts>0||!tTime&&this._ts<0)&&_removeFromParent(this,1);if(!suppressEvents&&!(totalTime<0&&!prevTime)&&(tTime||prevTime||!tDur)){_callback(this,tTime===tDur&&totalTime>=0?"onComplete":"onReverseComplete",!0);this._prom&&!(tTime0)&&this._prom()}}} return this};_proto2.add=function add(child,position){var _this2=this;_isNumber(position)||(position=_parsePosition(this,position,child));if(!(child instanceof Animation)){if(_isArray(child)){child.forEach(function(obj){return _this2.add(obj,position)});return this} if(_isString(child)){return this.addLabel(child,position)} if(_isFunction(child)){child=Tween.delayedCall(0,child)}else{return this}} return this!==child?_addToTimeline(this,child,position):this};_proto2.getChildren=function getChildren(nested,tweens,timelines,ignoreBeforeTime){if(nested===void 0){nested=!0} if(tweens===void 0){tweens=!0} if(timelines===void 0){timelines=!0} if(ignoreBeforeTime===void 0){ignoreBeforeTime=-_bigNum} var a=[],child=this._first;while(child){if(child._start>=ignoreBeforeTime){if(child instanceof Tween){tweens&&a.push(child)}else{timelines&&a.push(child);nested&&a.push.apply(a,child.getChildren(!0,tweens,timelines))}} child=child._next} return a};_proto2.getById=function getById(id){var animations=this.getChildren(1,1,1),i=animations.length;while(i--){if(animations[i].vars.id===id){return animations[i]}}};_proto2.remove=function remove(child){if(_isString(child)){return this.removeLabel(child)} if(_isFunction(child)){return this.killTweensOf(child)} _removeLinkedListItem(this,child);if(child===this._recent){this._recent=this._last} return _uncache(this)};_proto2.totalTime=function totalTime(_totalTime2,suppressEvents){if(!arguments.length){return this._tTime} this._forcing=1;if(!this._dp&&this._ts){this._start=_roundPrecise(_ticker.time-(this._ts>0?_totalTime2/this._ts:(this.totalDuration()-_totalTime2)/-this._ts))} _Animation.prototype.totalTime.call(this,_totalTime2,suppressEvents);this._forcing=0;return this};_proto2.addLabel=function addLabel(label,position){this.labels[label]=_parsePosition(this,position);return this};_proto2.removeLabel=function removeLabel(label){delete this.labels[label];return this};_proto2.addPause=function addPause(position,callback,params){var t=Tween.delayedCall(0,callback||_emptyFunc,params);t.data="isPause";this._hasPause=1;return _addToTimeline(this,t,_parsePosition(this,position))};_proto2.removePause=function removePause(position){var child=this._first;position=_parsePosition(this,position);while(child){if(child._start===position&&child.data==="isPause"){_removeFromParent(child)} child=child._next}};_proto2.killTweensOf=function killTweensOf(targets,props,onlyActive){var tweens=this.getTweensOf(targets,onlyActive),i=tweens.length;while(i--){_overwritingTween!==tweens[i]&&tweens[i].kill(targets,props)} return this};_proto2.getTweensOf=function getTweensOf(targets,onlyActive){var a=[],parsedTargets=toArray(targets),child=this._first,isGlobalTime=_isNumber(onlyActive),children;while(child){if(child instanceof Tween){if(_arrayContainsAny(child._targets,parsedTargets)&&(isGlobalTime?(!_overwritingTween||child._initted&&child._ts)&&child.globalTime(0)<=onlyActive&&child.globalTime(child.totalDuration())>onlyActive:!onlyActive||child.isActive())){a.push(child)}}else if((children=child.getTweensOf(parsedTargets,onlyActive)).length){a.push.apply(a,children)} child=child._next} return a};_proto2.tweenTo=function tweenTo(position,vars){vars=vars||{};var tl=this,endTime=_parsePosition(tl,position),_vars=vars,startAt=_vars.startAt,_onStart=_vars.onStart,onStartParams=_vars.onStartParams,immediateRender=_vars.immediateRender,initted,tween=Tween.to(tl,_setDefaults({ease:vars.ease||"none",lazy:!1,immediateRender:!1,time:endTime,overwrite:"auto",duration:vars.duration||Math.abs((endTime-(startAt&&"time" in startAt?startAt.time:tl._time))/tl.timeScale())||_tinyNum,onStart:function onStart(){tl.pause();if(!initted){var duration=vars.duration||Math.abs((endTime-(startAt&&"time" in startAt?startAt.time:tl._time))/tl.timeScale());tween._dur!==duration&&_setDuration(tween,duration,0,1).render(tween._time,!0,!0);initted=1} _onStart&&_onStart.apply(tween,onStartParams||[])}},vars));return immediateRender?tween.render(0):tween};_proto2.tweenFromTo=function tweenFromTo(fromPosition,toPosition,vars){return this.tweenTo(toPosition,_setDefaults({startAt:{time:_parsePosition(this,fromPosition)}},vars))};_proto2.recent=function recent(){return this._recent};_proto2.nextLabel=function nextLabel(afterTime){if(afterTime===void 0){afterTime=this._time} return _getLabelInDirection(this,_parsePosition(this,afterTime))};_proto2.previousLabel=function previousLabel(beforeTime){if(beforeTime===void 0){beforeTime=this._time} return _getLabelInDirection(this,_parsePosition(this,beforeTime),1)};_proto2.currentLabel=function currentLabel(value){return arguments.length?this.seek(value,!0):this.previousLabel(this._time+_tinyNum)};_proto2.shiftChildren=function shiftChildren(amount,adjustLabels,ignoreBeforeTime){if(ignoreBeforeTime===void 0){ignoreBeforeTime=0} var child=this._first,labels=this.labels,p;while(child){if(child._start>=ignoreBeforeTime){child._start+=amount;child._end+=amount} child=child._next} if(adjustLabels){for(p in labels){if(labels[p]>=ignoreBeforeTime){labels[p]+=amount}}} return _uncache(this)};_proto2.invalidate=function invalidate(soft){var child=this._first;this._lock=0;while(child){child.invalidate(soft);child=child._next} return _Animation.prototype.invalidate.call(this,soft)};_proto2.clear=function clear(includeLabels){if(includeLabels===void 0){includeLabels=!0} var child=this._first,next;while(child){next=child._next;this.remove(child);child=next} this._dp&&(this._time=this._tTime=this._pTime=0);includeLabels&&(this.labels={});return _uncache(this)};_proto2.totalDuration=function totalDuration(value){var max=0,self=this,child=self._last,prevStart=_bigNum,prev,start,parent;if(arguments.length){return self.timeScale((self._repeat<0?self.duration():self.totalDuration())/(self.reversed()?-value:value))} if(self._dirty){parent=self.parent;while(child){prev=child._prev;child._dirty&&child.totalDuration();start=child._start;if(start>prevStart&&self._sort&&child._ts&&!self._lock){self._lock=1;_addToTimeline(self,child,start-child._delay,1)._lock=0}else{prevStart=start} if(start<0&&child._ts){max-=start;if(!parent&&!self._dp||parent&&parent.smoothChildTiming){self._start+=start/self._ts;self._time-=start;self._tTime-=start} self.shiftChildren(-start,!1,-1e999);prevStart=0} child._end>max&&child._ts&&(max=child._end);child=prev} _setDuration(self,self===_globalTimeline&&self._time>max?self._time:max,1,1);self._dirty=0} return self._tDur};Timeline.updateRoot=function updateRoot(time){if(_globalTimeline._ts){_lazySafeRender(_globalTimeline,_parentToChildTotalTime(time,_globalTimeline));_lastRenderedFrame=_ticker.frame} if(_ticker.frame>=_nextGCFrame){_nextGCFrame+=_config.autoSleep||120;var child=_globalTimeline._first;if(!child||!child._ts)if(_config.autoSleep&&_ticker._listeners.length<2){while(child&&!child._ts){child=child._next} child||_ticker.sleep()}}};return Timeline}(Animation);_setDefaults(Timeline.prototype,{_lock:0,_hasPause:0,_forcing:0});var _addComplexStringPropTween=function _addComplexStringPropTween(target,prop,start,end,setter,stringFilter,funcParam){var pt=new PropTween(this._pt,target,prop,0,1,_renderComplexString,null,setter),index=0,matchIndex=0,result,startNums,color,endNum,chunk,startNum,hasRandom,a;pt.b=start;pt.e=end;start+="";end+="";if(hasRandom=~end.indexOf("random(")){end=_replaceRandom(end)} if(stringFilter){a=[start,end];stringFilter(a,target,prop);start=a[0];end=a[1]} startNums=start.match(_complexStringNumExp)||[];while(result=_complexStringNumExp.exec(end)){endNum=result[0];chunk=end.substring(index,result.index);if(color){color=(color+1)%5}else if(chunk.substr(-5)==="rgba("){color=1} if(endNum!==startNums[matchIndex++]){startNum=parseFloat(startNums[matchIndex-1])||0;pt._pt={_next:pt._pt,p:chunk||matchIndex===1?chunk:",",s:startNum,c:endNum.charAt(1)==="="?_parseRelative(startNum,endNum)-startNum:parseFloat(endNum)-startNum,m:color&&color<4?Math.round:0};index=_complexStringNumExp.lastIndex}} pt.c=index")});tl.duration()}else{copy={};for(p in keyframes){p==="ease"||p==="easeEach"||_parseKeyframe(p,keyframes[p],copy,keyframes.easeEach)} for(p in copy){a=copy[p].sort(function(a,b){return a.t-b.t});time=0;for(i=0;itDur-_tinyNum&&!isNegative?tDur:totalTime<_tinyNum?0:totalTime,time,pt,iteration,cycleDuration,prevIteration,isYoyo,ratio,timeline,yoyoEase;if(!dur){_renderZeroDurationTween(this,totalTime,suppressEvents,force)}else if(tTime!==this._tTime||!totalTime||force||!this._initted&&this._tTime||this._startAt&&this._zTime<0!==isNegative){time=tTime;timeline=this.timeline;if(this._repeat){cycleDuration=dur+this._rDelay;if(this._repeat<-1&&isNegative){return this.totalTime(cycleDuration*100+totalTime,suppressEvents,force)} time=_roundPrecise(tTime%cycleDuration);if(tTime===tDur){iteration=this._repeat;time=dur}else{iteration=~~(tTime/cycleDuration);if(iteration&&iteration===tTime/cycleDuration){time=dur;iteration--} time>dur&&(time=dur)} isYoyo=this._yoyo&&iteration&1;if(isYoyo){yoyoEase=this._yEase;time=dur-time} prevIteration=_animationCycle(this._tTime,cycleDuration);if(time===prevTime&&!force&&this._initted){this._tTime=tTime;return this} if(iteration!==prevIteration){timeline&&this._yEase&&_propagateYoyoEase(timeline,isYoyo);if(this.vars.repeatRefresh&&!isYoyo&&!this._lock){this._lock=force=1;this.render(_roundPrecise(cycleDuration*iteration),!0).invalidate()._lock=0}}} if(!this._initted){if(_attemptInitTween(this,isNegative?totalTime:time,force,suppressEvents,tTime)){this._tTime=0;return this} if(prevTime!==this._time){return this} if(dur!==this._dur){return this.render(totalTime,suppressEvents,force)}} this._tTime=tTime;this._time=time;if(!this._act&&this._ts){this._act=1;this._lazy=0} this.ratio=ratio=(yoyoEase||this._ease)(time/dur);if(this._from){this.ratio=ratio=1-ratio} if(time&&!prevTime&&!suppressEvents){_callback(this,"onStart");if(this._tTime!==tTime){return this}} pt=this._pt;while(pt){pt.r(ratio,pt.d);pt=pt._next} timeline&&timeline.render(totalTime<0?totalTime:!time&&isYoyo?-_tinyNum:timeline._dur*timeline._ease(time/this._dur),suppressEvents,force)||this._startAt&&(this._zTime=totalTime);if(this._onUpdate&&!suppressEvents){isNegative&&_rewindStartAt(this,totalTime,suppressEvents,force);_callback(this,"onUpdate")} this._repeat&&iteration!==prevIteration&&this.vars.onRepeat&&!suppressEvents&&this.parent&&_callback(this,"onRepeat");if((tTime===this._tDur||!tTime)&&this._tTime===tTime){isNegative&&!this._onUpdate&&_rewindStartAt(this,totalTime,!0,!0);(totalTime||!dur)&&(tTime===this._tDur&&this._ts>0||!tTime&&this._ts<0)&&_removeFromParent(this,1);if(!suppressEvents&&!(isNegative&&!prevTime)&&(tTime||prevTime||isYoyo)){_callback(this,tTime===tDur?"onComplete":"onReverseComplete",!0);this._prom&&!(tTime0)&&this._prom()}}} return this};_proto3.targets=function targets(){return this._targets};_proto3.invalidate=function invalidate(soft){(!soft||!this.vars.runBackwards)&&(this._startAt=0);this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0;this._ptLookup=[];this.timeline&&this.timeline.invalidate(soft);return _Animation2.prototype.invalidate.call(this,soft)};_proto3.resetTo=function resetTo(property,value,start,startIsRelative){_tickerActive||_ticker.wake();this._ts||this.play();var time=Math.min(this._dur,(this._dp._time-this._start)*this._ts),ratio;this._initted||_initTween(this,time);ratio=this._ease(time/this._dur);if(_updatePropTweens(this,property,value,start,startIsRelative,ratio,time)){return this.resetTo(property,value,start,startIsRelative)} _alignPlayhead(this,0);this.parent||_addLinkedListItem(this._dp,this,"_first","_last",this._dp._sort?"_start":0);return this.render(0)};_proto3.kill=function kill(targets,vars){if(vars===void 0){vars="all"} if(!targets&&(!vars||vars==="all")){this._lazy=this._pt=0;return this.parent?_interrupt(this):this} if(this.timeline){var tDur=this.timeline.totalDuration();this.timeline.killTweensOf(targets,vars,_overwritingTween&&_overwritingTween.vars.overwrite!==!0)._first||_interrupt(this);this.parent&&tDur!==this.timeline.totalDuration()&&_setDuration(this,this._dur*this.timeline._tDur/tDur,0,1);return this} var parsedTargets=this._targets,killingTargets=targets?toArray(targets):parsedTargets,propTweenLookup=this._ptLookup,firstPT=this._pt,overwrittenProps,curLookup,curOverwriteProps,props,p,pt,i;if((!vars||vars==="all")&&_arraysMatch(parsedTargets,killingTargets)){vars==="all"&&(this._pt=0);return _interrupt(this)} overwrittenProps=this._op=this._op||[];if(vars!=="all"){if(_isString(vars)){p={};_forEachName(vars,function(name){return p[name]=1});vars=p} vars=_addAliasesToVars(parsedTargets,vars)} i=parsedTargets.length;while(i--){if(~killingTargets.indexOf(parsedTargets[i])){curLookup=propTweenLookup[i];if(vars==="all"){overwrittenProps[i]=vars;props=curLookup;curOverwriteProps={}}else{curOverwriteProps=overwrittenProps[i]=overwrittenProps[i]||{};props=vars} for(p in props){pt=curLookup&&curLookup[p];if(pt){if(!("kill" in pt.d)||pt.d.kill(p)===!0){_removeLinkedListItem(this,pt,"_pt")} delete curLookup[p]} if(curOverwriteProps!=="all"){curOverwriteProps[p]=1}}}} this._initted&&!this._pt&&firstPT&&_interrupt(this);return this};Tween.to=function to(targets,vars){return new Tween(targets,vars,arguments[2])};Tween.from=function from(targets,vars){return _createTweenType(1,arguments)};Tween.delayedCall=function delayedCall(delay,callback,params,scope){return new Tween(callback,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:delay,onComplete:callback,onReverseComplete:callback,onCompleteParams:params,onReverseCompleteParams:params,callbackScope:scope})};Tween.fromTo=function fromTo(targets,fromVars,toVars){return _createTweenType(2,arguments)};Tween.set=function set(targets,vars){vars.duration=0;vars.repeatDelay||(vars.repeat=0);return new Tween(targets,vars)};Tween.killTweensOf=function killTweensOf(targets,props,onlyActive){return _globalTimeline.killTweensOf(targets,props,onlyActive)};return Tween}(Animation);_setDefaults(Tween.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0});_forEachName("staggerTo,staggerFrom,staggerFromTo",function(name){Tween[name]=function(){var tl=new Timeline(),params=_slice.call(arguments,0);params.splice(name==="staggerFromTo"?5:4,0,0);return tl[name].apply(tl,params)}});var _setterPlain=function _setterPlain(target,property,value){return target[property]=value},_setterFunc=function _setterFunc(target,property,value){return target[property](value)},_setterFuncWithParam=function _setterFuncWithParam(target,property,value,data){return target[property](data.fp,value)},_setterAttribute=function _setterAttribute(target,property,value){return target.setAttribute(property,value)},_getSetter=function _getSetter(target,property){return _isFunction(target[property])?_setterFunc:_isUndefined(target[property])&&target.setAttribute?_setterAttribute:_setterPlain},_renderPlain=function _renderPlain(ratio,data){return data.set(data.t,data.p,Math.round((data.s+data.c*ratio)*1000000)/1000000,data)},_renderBoolean=function _renderBoolean(ratio,data){return data.set(data.t,data.p,!!(data.s+data.c*ratio),data)},_renderComplexString=function _renderComplexString(ratio,data){var pt=data._pt,s="";if(!ratio&&data.b){s=data.b}else if(ratio===1&&data.e){s=data.e}else{while(pt){s=pt.p+(pt.m?pt.m(pt.s+pt.c*ratio):Math.round((pt.s+pt.c*ratio)*10000)/10000)+s;pt=pt._next} s+=data.c} data.set(data.t,data.p,s,data)},_renderPropTweens=function _renderPropTweens(ratio,data){var pt=data._pt;while(pt){pt.r(ratio,pt.d);pt=pt._next}},_addPluginModifier=function _addPluginModifier(modifier,tween,target,property){var pt=this._pt,next;while(pt){next=pt._next;pt.p===property&&pt.modifier(modifier,tween,target);pt=next}},_killPropTweensOf=function _killPropTweensOf(property){var pt=this._pt,hasNonDependentRemaining,next;while(pt){next=pt._next;if(pt.p===property&&!pt.op||pt.op===property){_removeLinkedListItem(this,pt,"_pt")}else if(!pt.dep){hasNonDependentRemaining=1} pt=next} return!hasNonDependentRemaining},_setterWithModifier=function _setterWithModifier(target,property,value,data){data.mSet(target,property,data.m.call(data.tween,value,data.mt),data)},_sortPropTweensByPriority=function _sortPropTweensByPriority(parent){var pt=parent._pt,next,pt2,first,last;while(pt){next=pt._next;pt2=first;while(pt2&&pt2.pr>pt.pr){pt2=pt2._next} if(pt._prev=pt2?pt2._prev:last){pt._prev._next=pt}else{first=pt} if(pt._next=pt2){pt2._prev=pt}else{last=pt} pt=next} parent._pt=first};var PropTween=function(){function PropTween(next,target,prop,start,change,renderer,data,setter,priority){this.t=target;this.s=start;this.c=change;this.p=prop;this.r=renderer||_renderPlain;this.d=data||this;this.set=setter||_setterPlain;this.pr=priority||0;this._next=next;if(next){next._prev=this}} var _proto4=PropTween.prototype;_proto4.modifier=function modifier(func,tween,target){this.mSet=this.mSet||this.set;this.set=_setterWithModifier;this.m=func;this.mt=target;this.tween=tween};return PropTween}();_forEachName(_callbackNames+"parent,duration,ease,delay,overwrite,runBackwards,startAt,yoyo,immediateRender,repeat,repeatDelay,data,paused,reversed,lazy,callbackScope,stringFilter,id,yoyoEase,stagger,inherit,repeatRefresh,keyframes,autoRevert,scrollTrigger",function(name){return _reservedProps[name]=1});_globals.TweenMax=_globals.TweenLite=Tween;_globals.TimelineLite=_globals.TimelineMax=Timeline;_globalTimeline=new Timeline({sortChildren:!1,defaults:_defaults,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0});_config.stringFilter=_colorStringFilter;var _media=[],_listeners={},_emptyArray=[],_lastMediaTime=0,_dispatch=function _dispatch(type){return(_listeners[type]||_emptyArray).map(function(f){return f()})},_onMediaChange=function _onMediaChange(){var time=Date.now(),matches=[];if(time-_lastMediaTime>2){_dispatch("matchMediaInit");_media.forEach(function(c){var queries=c.queries,conditions=c.conditions,match,p,anyMatch,toggled;for(p in queries){match=_win.matchMedia(queries[p]).matches;match&&(anyMatch=1);if(match!==conditions[p]){conditions[p]=match;toggled=1}} if(toggled){c.revert();anyMatch&&matches.push(c)}});_dispatch("matchMediaRevert");matches.forEach(function(c){return c.onMatch(c)});_lastMediaTime=time;_dispatch("matchMedia")}};var Context=function(){function Context(func,scope){this.selector=scope&&selector(scope);this.data=[];this._r=[];this.isReverted=!1;func&&this.add(func)} var _proto5=Context.prototype;_proto5.add=function add(name,func,scope){if(_isFunction(name)){scope=func;func=name;name=_isFunction} var self=this,f=function f(){var prev=_context,prevSelector=self.selector,result;prev&&prev!==self&&prev.data.push(self);scope&&(self.selector=selector(scope));_context=self;result=func.apply(self,arguments);_isFunction(result)&&self._r.push(result);_context=prev;self.selector=prevSelector;self.isReverted=!1;return result};self.last=f;return name===_isFunction?f(self):name?self[name]=f:f};_proto5.ignore=function ignore(func){var prev=_context;_context=null;func(this);_context=prev};_proto5.getTweens=function getTweens(){var a=[];this.data.forEach(function(e){return e instanceof Context?a.push.apply(a,e.getTweens()):e instanceof Tween&&!(e.parent&&e.parent.data==="nested")&&a.push(e)});return a};_proto5.clear=function clear(){this._r.length=this.data.length=0};_proto5.kill=function kill(revert,matchMedia){var _this4=this;if(revert){var tweens=this.getTweens();this.data.forEach(function(t){if(t.data==="isFlip"){t.revert();t.getChildren(!0,!0,!1).forEach(function(tween){return tweens.splice(tweens.indexOf(tween),1)})}});tweens.map(function(t){return{g:t.globalTime(0),t:t}}).sort(function(a,b){return b.g-a.g||-1}).forEach(function(o){return o.t.revert(revert)});this.data.forEach(function(e){return!(e instanceof Animation)&&e.revert&&e.revert(revert)});this._r.forEach(function(f){return f(revert,_this4)});this.isReverted=!0}else{this.data.forEach(function(e){return e.kill&&e.kill()})} this.clear();if(matchMedia){var i=_media.indexOf(this);!!~i&&_media.splice(i,1)}};_proto5.revert=function revert(config){this.kill(config||{})};return Context}();var MatchMedia=function(){function MatchMedia(scope){this.contexts=[];this.scope=scope} var _proto6=MatchMedia.prototype;_proto6.add=function add(conditions,func,scope){_isObject(conditions)||(conditions={matches:conditions});var context=new Context(0,scope||this.scope),cond=context.conditions={},mq,p,active;this.contexts.push(context);func=context.add("onMatch",func);context.queries=conditions;for(p in conditions){if(p==="all"){active=1}else{mq=_win.matchMedia(conditions[p]);if(mq){_media.indexOf(context)<0&&_media.push(context);(cond[p]=mq.matches)&&(active=1);mq.addListener?mq.addListener(_onMediaChange):mq.addEventListener("change",_onMediaChange)}}} active&&func(context);return this};_proto6.revert=function revert(config){this.kill(config||{})};_proto6.kill=function kill(revert){this.contexts.forEach(function(c){return c.kill(revert,!0)})};return MatchMedia}();var _gsap={registerPlugin:function registerPlugin(){for(var _len2=arguments.length,args=new Array(_len2),_key2=0;_key2<_len2;_key2++){args[_key2]=arguments[_key2]} args.forEach(function(config){return _createPlugin(config)})},timeline:function timeline(vars){return new Timeline(vars)},getTweensOf:function getTweensOf(targets,onlyActive){return _globalTimeline.getTweensOf(targets,onlyActive)},getProperty:function getProperty(target,property,unit,uncache){_isString(target)&&(target=toArray(target)[0]);var getter=_getCache(target||{}).get,format=unit?_passThrough:_numericIfPossible;unit==="native"&&(unit="");return!target?target:!property?function(property,unit,uncache){return format((_plugins[property]&&_plugins[property].get||getter)(target,property,unit,uncache))}:format((_plugins[property]&&_plugins[property].get||getter)(target,property,unit,uncache))},quickSetter:function quickSetter(target,property,unit){target=toArray(target);if(target.length>1){var setters=target.map(function(t){return gsap.quickSetter(t,property,unit)}),l=setters.length;return function(value){var i=l;while(i--){setters[i](value)}}} target=target[0]||{};var Plugin=_plugins[property],cache=_getCache(target),p=cache.harness&&(cache.harness.aliases||{})[property]||property,setter=Plugin?function(value){var p=new Plugin();_quickTween._pt=0;p.init(target,unit?value+unit:value,_quickTween,0,[target]);p.render(1,p);_quickTween._pt&&_renderPropTweens(1,_quickTween)}:cache.set(target,p);return Plugin?setter:function(value){return setter(target,p,unit?value+unit:value,cache,1)}},quickTo:function quickTo(target,property,vars){var _merge2;var tween=gsap.to(target,_merge((_merge2={},_merge2[property]="+=0.1",_merge2.paused=!0,_merge2),vars||{})),func=function func(value,start,startIsRelative){return tween.resetTo(property,value,start,startIsRelative)};func.tween=tween;return func},isTweening:function isTweening(targets){return _globalTimeline.getTweensOf(targets,!0).length>0},defaults:function defaults(value){value&&value.ease&&(value.ease=_parseEase(value.ease,_defaults.ease));return _mergeDeep(_defaults,value||{})},config:function config(value){return _mergeDeep(_config,value||{})},registerEffect:function registerEffect(_ref3){var name=_ref3.name,effect=_ref3.effect,plugins=_ref3.plugins,defaults=_ref3.defaults,extendTimeline=_ref3.extendTimeline;(plugins||"").split(",").forEach(function(pluginName){return pluginName&&!_plugins[pluginName]&&!_globals[pluginName]&&_warn(name+" effect requires "+pluginName+" plugin.")});_effects[name]=function(targets,vars,tl){return effect(toArray(targets),_setDefaults(vars||{},defaults),tl)};if(extendTimeline){Timeline.prototype[name]=function(targets,vars,position){return this.add(_effects[name](targets,_isObject(vars)?vars:(position=vars)&&{},this),position)}}},registerEase:function registerEase(name,ease){_easeMap[name]=_parseEase(ease)},parseEase:function parseEase(ease,defaultEase){return arguments.length?_parseEase(ease,defaultEase):_easeMap},getById:function getById(id){return _globalTimeline.getById(id)},exportRoot:function exportRoot(vars,includeDelayedCalls){if(vars===void 0){vars={}} var tl=new Timeline(vars),child,next;tl.smoothChildTiming=_isNotFalse(vars.smoothChildTiming);_globalTimeline.remove(tl);tl._dp=0;tl._time=tl._tTime=_globalTimeline._time;child=_globalTimeline._first;while(child){next=child._next;if(includeDelayedCalls||!(!child._dur&&child instanceof Tween&&child.vars.onComplete===child._targets[0])){_addToTimeline(tl,child,child._start-child._delay)} child=next} _addToTimeline(_globalTimeline,tl,0);return tl},context:function context(func,scope){return func?new Context(func,scope):_context},matchMedia:function matchMedia(scope){return new MatchMedia(scope)},matchMediaRefresh:function matchMediaRefresh(){return _media.forEach(function(c){var cond=c.conditions,found,p;for(p in cond){if(cond[p]){cond[p]=!1;found=1}} found&&c.revert()})||_onMediaChange()},addEventListener:function addEventListener(type,callback){var a=_listeners[type]||(_listeners[type]=[]);~a.indexOf(callback)||a.push(callback)},removeEventListener:function removeEventListener(type,callback){var a=_listeners[type],i=a&&a.indexOf(callback);i>=0&&a.splice(i,1)},utils:{wrap:wrap,wrapYoyo:wrapYoyo,distribute:distribute,random:random,snap:snap,normalize:normalize,getUnit:getUnit,clamp:clamp,splitColor:splitColor,toArray:toArray,selector:selector,mapRange:mapRange,pipe:pipe,unitize:unitize,interpolate:interpolate,shuffle:shuffle},install:_install,effects:_effects,ticker:_ticker,updateRoot:Timeline.updateRoot,plugins:_plugins,globalTimeline:_globalTimeline,core:{PropTween:PropTween,globals:_addGlobal,Tween:Tween,Timeline:Timeline,Animation:Animation,getCache:_getCache,_removeLinkedListItem:_removeLinkedListItem,reverting:function reverting(){return _reverting},context:function context(toAdd){if(toAdd&&_context){_context.data.push(toAdd);toAdd._ctx=_context} return _context},suppressOverwrites:function suppressOverwrites(value){return _suppressOverwrites=value}}};_forEachName("to,from,fromTo,delayedCall,set,killTweensOf",function(name){return _gsap[name]=Tween[name]});_ticker.add(Timeline.updateRoot);_quickTween=_gsap.to({},{duration:0});var _getPluginPropTween=function _getPluginPropTween(plugin,prop){var pt=plugin._pt;while(pt&&pt.p!==prop&&pt.op!==prop&&pt.fp!==prop){pt=pt._next} return pt},_addModifiers=function _addModifiers(tween,modifiers){var targets=tween._targets,p,i,pt;for(p in modifiers){i=targets.length;while(i--){pt=tween._ptLookup[i][p];if(pt&&(pt=pt.d)){if(pt._pt){pt=_getPluginPropTween(pt,p)} pt&&pt.modifier&&pt.modifier(modifiers[p],tween,targets[i],p)}}}},_buildModifierPlugin=function _buildModifierPlugin(name,modifier){return{name:name,rawVars:1,init:function init(target,vars,tween){tween._onInit=function(tween){var temp,p;if(_isString(vars)){temp={};_forEachName(vars,function(name){return temp[name]=1});vars=temp} if(modifier){temp={};for(p in vars){temp[p]=modifier(vars[p])} vars=temp} _addModifiers(tween,vars)}}}};var gsap=_gsap.registerPlugin({name:"attr",init:function init(target,vars,tween,index,targets){var p,pt,v;this.tween=tween;for(p in vars){v=target.getAttribute(p)||"";pt=this.add(target,"setAttribute",(v||0)+"",vars[p],index,targets,0,0,p);pt.op=p;pt.b=v;this._props.push(p)}},render:function render(ratio,data){var pt=data._pt;while(pt){_reverting?pt.set(pt.t,pt.p,pt.b,pt):pt.r(ratio,pt.d);pt=pt._next}}},{name:"endArray",init:function init(target,value){var i=value.length;while(i--){this.add(target,i,target[i]||0,value[i],0,0,0,0,0,1)}}},_buildModifierPlugin("roundProps",_roundModifier),_buildModifierPlugin("modifiers"),_buildModifierPlugin("snap",snap))||_gsap;Tween.version=Timeline.version=gsap.version="3.11.3";_coreReady=1;_windowExists()&&_wake();var Power0=_easeMap.Power0,Power1=_easeMap.Power1,Power2=_easeMap.Power2,Power3=_easeMap.Power3,Power4=_easeMap.Power4,Linear=_easeMap.Linear,Quad=_easeMap.Quad,Cubic=_easeMap.Cubic,Quart=_easeMap.Quart,Quint=_easeMap.Quint,Strong=_easeMap.Strong,Elastic=_easeMap.Elastic,Back=_easeMap.Back,SteppedEase=_easeMap.SteppedEase,Bounce=_easeMap.Bounce,Sine=_easeMap.Sine,Expo=_easeMap.Expo,Circ=_easeMap.Circ;var _win$1,_doc$1,_docElement,_pluginInitted,_tempDiv,_tempDivStyler,_recentSetterPlugin,_reverting$1,_windowExists$1=function _windowExists(){return typeof window!=="undefined"},_transformProps={},_RAD2DEG=180/Math.PI,_DEG2RAD=Math.PI/180,_atan2=Math.atan2,_bigNum$1=1e8,_capsExp=/([A-Z])/g,_horizontalExp=/(left|right|width|margin|padding|x)/i,_complexExp=/[\s,\(]\S/,_propertyAliases={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},_renderCSSProp=function _renderCSSProp(ratio,data){return data.set(data.t,data.p,Math.round((data.s+data.c*ratio)*10000)/10000+data.u,data)},_renderPropWithEnd=function _renderPropWithEnd(ratio,data){return data.set(data.t,data.p,ratio===1?data.e:Math.round((data.s+data.c*ratio)*10000)/10000+data.u,data)},_renderCSSPropWithBeginning=function _renderCSSPropWithBeginning(ratio,data){return data.set(data.t,data.p,ratio?Math.round((data.s+data.c*ratio)*10000)/10000+data.u:data.b,data)},_renderRoundedCSSProp=function _renderRoundedCSSProp(ratio,data){var value=data.s+data.c*ratio;data.set(data.t,data.p,~~(value+(value<0?-.5:.5))+data.u,data)},_renderNonTweeningValue=function _renderNonTweeningValue(ratio,data){return data.set(data.t,data.p,ratio?data.e:data.b,data)},_renderNonTweeningValueOnlyAtEnd=function _renderNonTweeningValueOnlyAtEnd(ratio,data){return data.set(data.t,data.p,ratio!==1?data.b:data.e,data)},_setterCSSStyle=function _setterCSSStyle(target,property,value){return target.style[property]=value},_setterCSSProp=function _setterCSSProp(target,property,value){return target.style.setProperty(property,value)},_setterTransform=function _setterTransform(target,property,value){return target._gsap[property]=value},_setterScale=function _setterScale(target,property,value){return target._gsap.scaleX=target._gsap.scaleY=value},_setterScaleWithRender=function _setterScaleWithRender(target,property,value,data,ratio){var cache=target._gsap;cache.scaleX=cache.scaleY=value;cache.renderTransform(ratio,cache)},_setterTransformWithRender=function _setterTransformWithRender(target,property,value,data,ratio){var cache=target._gsap;cache[property]=value;cache.renderTransform(ratio,cache)},_transformProp="transform",_transformOriginProp=_transformProp+"Origin",_saveStyle=function _saveStyle(property,isNotCSS){var _this=this;var target=this.target,style=target.style;if(property in _transformProps){this.tfm=this.tfm||{};if(property!=="transform"){property=_propertyAliases[property]||property;~property.indexOf(",")?property.split(",").forEach(function(a){return _this.tfm[a]=_get(target,a)}):this.tfm[property]=target._gsap.x?target._gsap[property]:_get(target,property)} if(this.props.indexOf(_transformProp)>=0){return} if(target._gsap.svg){this.svgo=target.getAttribute("data-svg-origin");this.props.push(_transformOriginProp,isNotCSS,"")} property=_transformProp}(style||isNotCSS)&&this.props.push(property,isNotCSS,style[property])},_removeIndependentTransforms=function _removeIndependentTransforms(style){if(style.translate){style.removeProperty("translate");style.removeProperty("scale");style.removeProperty("rotate")}},_revertStyle=function _revertStyle(){var props=this.props,target=this.target,style=target.style,cache=target._gsap,i,p;for(i=0;i=0?_prefixes[i]:"")+property},_initCore=function _initCore(){if(_windowExists$1()&&window.document){_win$1=window;_doc$1=_win$1.document;_docElement=_doc$1.documentElement;_tempDiv=_createElement("div")||{style:{}};_tempDivStyler=_createElement("div");_transformProp=_checkPropPrefix(_transformProp);_transformOriginProp=_transformProp+"Origin";_tempDiv.style.cssText="border-width:0;line-height:0;position:absolute;padding:0";_supports3D=!!_checkPropPrefix("perspective");_reverting$1=gsap.core.reverting;_pluginInitted=1}},_getBBoxHack=function _getBBoxHack(swapIfPossible){var svg=_createElement("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),oldParent=this.parentNode,oldSibling=this.nextSibling,oldCSS=this.style.cssText,bbox;_docElement.appendChild(svg);svg.appendChild(this);this.style.display="block";if(swapIfPossible){try{bbox=this.getBBox();this._gsapBBox=this.getBBox;this.getBBox=_getBBoxHack}catch(e){}}else if(this._gsapBBox){bbox=this._gsapBBox()} if(oldParent){if(oldSibling){oldParent.insertBefore(this,oldSibling)}else{oldParent.appendChild(this)}} _docElement.removeChild(svg);this.style.cssText=oldCSS;return bbox},_getAttributeFallbacks=function _getAttributeFallbacks(target,attributesArray){var i=attributesArray.length;while(i--){if(target.hasAttribute(attributesArray[i])){return target.getAttribute(attributesArray[i])}}},_getBBox=function _getBBox(target){var bounds;try{bounds=target.getBBox()}catch(error){bounds=_getBBoxHack.call(target,!0)} bounds&&(bounds.width||bounds.height)||target.getBBox===_getBBoxHack||(bounds=_getBBoxHack.call(target,!0));return bounds&&!bounds.width&&!bounds.x&&!bounds.y?{x:+_getAttributeFallbacks(target,["x","cx","x1"])||0,y:+_getAttributeFallbacks(target,["y","cy","y1"])||0,width:0,height:0}:bounds},_isSVG=function _isSVG(e){return!!(e.getCTM&&(!e.parentNode||e.ownerSVGElement)&&_getBBox(e))},_removeProperty=function _removeProperty(target,property){if(property){var style=target.style;if(property in _transformProps&&property!==_transformOriginProp){property=_transformProp} if(style.removeProperty){if(property.substr(0,2)==="ms"||property.substr(0,6)==="webkit"){property="-"+property} style.removeProperty(property.replace(_capsExp,"-$1").toLowerCase())}else{style.removeAttribute(property)}}},_addNonTweeningPT=function _addNonTweeningPT(plugin,target,property,beginning,end,onlySetAtEnd){var pt=new PropTween(plugin._pt,target,property,0,1,onlySetAtEnd?_renderNonTweeningValueOnlyAtEnd:_renderNonTweeningValue);plugin._pt=pt;pt.b=beginning;pt.e=end;plugin._props.push(property);return pt},_nonConvertibleUnits={deg:1,rad:1,turn:1},_nonStandardLayouts={grid:1,flex:1},_convertToUnit=function _convertToUnit(target,property,value,unit){var curValue=parseFloat(value)||0,curUnit=(value+"").trim().substr((curValue+"").length)||"px",style=_tempDiv.style,horizontal=_horizontalExp.test(property),isRootSVG=target.tagName.toLowerCase()==="svg",measureProperty=(isRootSVG?"client":"offset")+(horizontal?"Width":"Height"),amount=100,toPixels=unit==="px",toPercent=unit==="%",px,parent,cache,isSVG;if(unit===curUnit||!curValue||_nonConvertibleUnits[unit]||_nonConvertibleUnits[curUnit]){return curValue} curUnit!=="px"&&!toPixels&&(curValue=_convertToUnit(target,property,value,"px"));isSVG=target.getCTM&&_isSVG(target);if((toPercent||curUnit==="%")&&(_transformProps[property]||~property.indexOf("adius"))){px=isSVG?target.getBBox()[horizontal?"width":"height"]:target[measureProperty];return _round(toPercent?curValue/px*amount:curValue/100*px)} style[horizontal?"width":"height"]=amount+(toPixels?curUnit:unit);parent=~property.indexOf("adius")||unit==="em"&&target.appendChild&&!isRootSVG?target:target.parentNode;if(isSVG){parent=(target.ownerSVGElement||{}).parentNode} if(!parent||parent===_doc$1||!parent.appendChild){parent=_doc$1.body} cache=parent._gsap;if(cache&&toPercent&&cache.width&&horizontal&&cache.time===_ticker.time&&!cache.uncache){return _round(curValue/cache.width*amount)}else{(toPercent||curUnit==="%")&&!_nonStandardLayouts[_getComputedProperty(parent,"display")]&&(style.position=_getComputedProperty(target,"position"));parent===target&&(style.position="static");parent.appendChild(_tempDiv);px=_tempDiv[measureProperty];parent.removeChild(_tempDiv);style.position="absolute";if(horizontal&&toPercent){cache=_getCache(parent);cache.time=_ticker.time;cache.width=parent[measureProperty]}} return _round(toPixels?px*curValue/amount:px&&curValue?amount/px*curValue:0)},_get=function _get(target,property,unit,uncache){var value;_pluginInitted||_initCore();if(property in _propertyAliases&&property!=="transform"){property=_propertyAliases[property];if(~property.indexOf(",")){property=property.split(",")[0]}} if(_transformProps[property]&&property!=="transform"){value=_parseTransform(target,uncache);value=property!=="transformOrigin"?value[property]:value.svg?value.origin:_firstTwoOnly(_getComputedProperty(target,_transformOriginProp))+" "+value.zOrigin+"px"}else{value=target.style[property];if(!value||value==="auto"||uncache||~(value+"").indexOf("calc(")){value=_specialProps[property]&&_specialProps[property](target,property,unit)||_getComputedProperty(target,property)||_getProperty(target,property)||(property==="opacity"?1:0)}} return unit&&!~(value+"").trim().indexOf(" ")?_convertToUnit(target,property,value,unit)+unit:value},_tweenComplexCSSString=function _tweenComplexCSSString(target,prop,start,end){if(!start||start==="none"){var p=_checkPropPrefix(prop,target,1),s=p&&_getComputedProperty(target,p,1);if(s&&s!==start){prop=p;start=s}else if(prop==="borderColor"){start=_getComputedProperty(target,"borderTopColor")}} var pt=new PropTween(this._pt,target.style,prop,0,1,_renderComplexString),index=0,matchIndex=0,a,result,startValues,startNum,color,startValue,endValue,endNum,chunk,endUnit,startUnit,endValues;pt.b=start;pt.e=end;start+="";end+="";if(end==="auto"){target.style[prop]=end;end=_getComputedProperty(target,prop)||end;target.style[prop]=start} a=[start,end];_colorStringFilter(a);start=a[0];end=a[1];startValues=start.match(_numWithUnitExp)||[];endValues=end.match(_numWithUnitExp)||[];if(endValues.length){while(result=_numWithUnitExp.exec(end)){endValue=result[0];chunk=end.substring(index,result.index);if(color){color=(color+1)%5}else if(chunk.substr(-5)==="rgba("||chunk.substr(-5)==="hsla("){color=1} if(endValue!==(startValue=startValues[matchIndex++]||"")){startNum=parseFloat(startValue)||0;startUnit=startValue.substr((startNum+"").length);endValue.charAt(1)==="="&&(endValue=_parseRelative(startNum,endValue)+startUnit);endNum=parseFloat(endValue);endUnit=endValue.substr((endNum+"").length);index=_numWithUnitExp.lastIndex-endUnit.length;if(!endUnit){endUnit=endUnit||_config.units[prop]||startUnit;if(index===end.length){end+=endUnit;pt.e+=endUnit}} if(startUnit!==endUnit){startNum=_convertToUnit(target,prop,startValue,endUnit)||0} pt._pt={_next:pt._pt,p:chunk||matchIndex===1?chunk:",",s:startNum,c:endNum-startNum,m:color&&color<4||prop==="zIndex"?Math.round:0}}} pt.c=index-1){prop=props[i];if(_transformProps[prop]){clearTransforms=1;prop=prop==="transformOrigin"?_transformOriginProp:_transformProp} _removeProperty(target,prop)}} if(clearTransforms){_removeProperty(target,_transformProp);if(cache){cache.svg&&target.removeAttribute("transform");_parseTransform(target,1);cache.uncache=1;_removeIndependentTransforms(style)}}}},_specialProps={clearProps:function clearProps(plugin,target,property,endValue,tween){if(tween.data!=="isFromStart"){var pt=plugin._pt=new PropTween(plugin._pt,target,property,0,0,_renderClearProps);pt.u=endValue;pt.pr=-10;pt.tween=tween;plugin._props.push(property);return 1}}},_identity2DMatrix=[1,0,0,1,0,0],_rotationalProperties={},_isNullTransform=function _isNullTransform(value){return value==="matrix(1, 0, 0, 1, 0, 0)"||value==="none"||!value},_getComputedTransformMatrixAsArray=function _getComputedTransformMatrixAsArray(target){var matrixString=_getComputedProperty(target,_transformProp);return _isNullTransform(matrixString)?_identity2DMatrix:matrixString.substr(7).match(_numExp).map(_round)},_getMatrix=function _getMatrix(target,force2D){var cache=target._gsap||_getCache(target),style=target.style,matrix=_getComputedTransformMatrixAsArray(target),parent,nextSibling,temp,addedToDOM;if(cache.svg&&target.getAttribute("transform")){temp=target.transform.baseVal.consolidate().matrix;matrix=[temp.a,temp.b,temp.c,temp.d,temp.e,temp.f];return matrix.join(",")==="1,0,0,1,0,0"?_identity2DMatrix:matrix}else if(matrix===_identity2DMatrix&&!target.offsetParent&&target!==_docElement&&!cache.svg){temp=style.display;style.display="block";parent=target.parentNode;if(!parent||!target.offsetParent){addedToDOM=1;nextSibling=target.nextElementSibling;_docElement.appendChild(target)} matrix=_getComputedTransformMatrixAsArray(target);temp?style.display=temp:_removeProperty(target,"display");if(addedToDOM){nextSibling?parent.insertBefore(target,nextSibling):parent?parent.appendChild(target):_docElement.removeChild(target)}} return force2D&&matrix.length>6?[matrix[0],matrix[1],matrix[4],matrix[5],matrix[12],matrix[13]]:matrix},_applySVGOrigin=function _applySVGOrigin(target,origin,originIsAbsolute,smooth,matrixArray,pluginToAddPropTweensTo){var cache=target._gsap,matrix=matrixArray||_getMatrix(target,!0),xOriginOld=cache.xOrigin||0,yOriginOld=cache.yOrigin||0,xOffsetOld=cache.xOffset||0,yOffsetOld=cache.yOffset||0,a=matrix[0],b=matrix[1],c=matrix[2],d=matrix[3],tx=matrix[4],ty=matrix[5],originSplit=origin.split(" "),xOrigin=parseFloat(originSplit[0])||0,yOrigin=parseFloat(originSplit[1])||0,bounds,determinant,x,y;if(!originIsAbsolute){bounds=_getBBox(target);xOrigin=bounds.x+(~originSplit[0].indexOf("%")?xOrigin/100*bounds.width:xOrigin);yOrigin=bounds.y+(~(originSplit[1]||originSplit[0]).indexOf("%")?yOrigin/100*bounds.height:yOrigin)}else if(matrix!==_identity2DMatrix&&(determinant=a*d-b*c)){x=xOrigin*(d/determinant)+yOrigin*(-c/determinant)+(c*ty-d*tx)/determinant;y=xOrigin*(-b/determinant)+yOrigin*(a/determinant)-(a*ty-b*tx)/determinant;xOrigin=x;yOrigin=y} if(smooth||smooth!==!1&&cache.smooth){tx=xOrigin-xOriginOld;ty=yOrigin-yOriginOld;cache.xOffset=xOffsetOld+(tx*a+ty*c)-tx;cache.yOffset=yOffsetOld+(tx*b+ty*d)-ty}else{cache.xOffset=cache.yOffset=0} cache.xOrigin=xOrigin;cache.yOrigin=yOrigin;cache.smooth=!!smooth;cache.origin=origin;cache.originIsAbsolute=!!originIsAbsolute;target.style[_transformOriginProp]="0px 0px";if(pluginToAddPropTweensTo){_addNonTweeningPT(pluginToAddPropTweensTo,cache,"xOrigin",xOriginOld,xOrigin);_addNonTweeningPT(pluginToAddPropTweensTo,cache,"yOrigin",yOriginOld,yOrigin);_addNonTweeningPT(pluginToAddPropTweensTo,cache,"xOffset",xOffsetOld,cache.xOffset);_addNonTweeningPT(pluginToAddPropTweensTo,cache,"yOffset",yOffsetOld,cache.yOffset)} target.setAttribute("data-svg-origin",xOrigin+" "+yOrigin)},_parseTransform=function _parseTransform(target,uncache){var cache=target._gsap||new GSCache(target);if("x" in cache&&!uncache&&!cache.uncache){return cache} var style=target.style,invertedScaleX=cache.scaleX<0,px="px",deg="deg",cs=getComputedStyle(target),origin=_getComputedProperty(target,_transformOriginProp)||"0",x,y,z,scaleX,scaleY,rotation,rotationX,rotationY,skewX,skewY,perspective,xOrigin,yOrigin,matrix,angle,cos,sin,a,b,c,d,a12,a22,t1,t2,t3,a13,a23,a33,a42,a43,a32;x=y=z=rotation=rotationX=rotationY=skewX=skewY=perspective=0;scaleX=scaleY=1;cache.svg=!!(target.getCTM&&_isSVG(target));if(cs.translate){if(cs.translate!=="none"||cs.scale!=="none"||cs.rotate!=="none"){style[_transformProp]=(cs.translate!=="none"?"translate3d("+(cs.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+(cs.rotate!=="none"?"rotate("+cs.rotate+") ":"")+(cs.scale!=="none"?"scale("+cs.scale.split(" ").join(",")+") ":"")+(cs[_transformProp]!=="none"?cs[_transformProp]:"")} style.scale=style.rotate=style.translate="none"} matrix=_getMatrix(target,cache.svg);if(cache.svg){if(cache.uncache){t2=target.getBBox();origin=cache.xOrigin-t2.x+"px "+(cache.yOrigin-t2.y)+"px";t1=""}else{t1=!uncache&&target.getAttribute("data-svg-origin")} _applySVGOrigin(target,t1||origin,!!t1||cache.originIsAbsolute,cache.smooth!==!1,matrix)} xOrigin=cache.xOrigin||0;yOrigin=cache.yOrigin||0;if(matrix!==_identity2DMatrix){a=matrix[0];b=matrix[1];c=matrix[2];d=matrix[3];x=a12=matrix[4];y=a22=matrix[5];if(matrix.length===6){scaleX=Math.sqrt(a*a+b*b);scaleY=Math.sqrt(d*d+c*c);rotation=a||b?_atan2(b,a)*_RAD2DEG:0;skewX=c||d?_atan2(c,d)*_RAD2DEG+rotation:0;skewX&&(scaleY*=Math.abs(Math.cos(skewX*_DEG2RAD)));if(cache.svg){x-=xOrigin-(xOrigin*a+yOrigin*c);y-=yOrigin-(xOrigin*b+yOrigin*d)}}else{a32=matrix[6];a42=matrix[7];a13=matrix[8];a23=matrix[9];a33=matrix[10];a43=matrix[11];x=matrix[12];y=matrix[13];z=matrix[14];angle=_atan2(a32,a33);rotationX=angle*_RAD2DEG;if(angle){cos=Math.cos(-angle);sin=Math.sin(-angle);t1=a12*cos+a13*sin;t2=a22*cos+a23*sin;t3=a32*cos+a33*sin;a13=a12*-sin+a13*cos;a23=a22*-sin+a23*cos;a33=a32*-sin+a33*cos;a43=a42*-sin+a43*cos;a12=t1;a22=t2;a32=t3} angle=_atan2(-c,a33);rotationY=angle*_RAD2DEG;if(angle){cos=Math.cos(-angle);sin=Math.sin(-angle);t1=a*cos-a13*sin;t2=b*cos-a23*sin;t3=c*cos-a33*sin;a43=d*sin+a43*cos;a=t1;b=t2;c=t3} angle=_atan2(b,a);rotation=angle*_RAD2DEG;if(angle){cos=Math.cos(angle);sin=Math.sin(angle);t1=a*cos+b*sin;t2=a12*cos+a22*sin;b=b*cos-a*sin;a22=a22*cos-a12*sin;a=t1;a12=t2} if(rotationX&&Math.abs(rotationX)+Math.abs(rotation)>359.9){rotationX=rotation=0;rotationY=180-rotationY} scaleX=_round(Math.sqrt(a*a+b*b+c*c));scaleY=_round(Math.sqrt(a22*a22+a32*a32));angle=_atan2(a12,a22);skewX=Math.abs(angle)>0.0002?angle*_RAD2DEG:0;perspective=a43?1/(a43<0?-a43:a43):0} if(cache.svg){t1=target.getAttribute("transform");cache.forceCSS=target.setAttribute("transform","")||!_isNullTransform(_getComputedProperty(target,_transformProp));t1&&target.setAttribute("transform",t1)}} if(Math.abs(skewX)>90&&Math.abs(skewX)<270){if(invertedScaleX){scaleX*=-1;skewX+=rotation<=0?180:-180;rotation+=rotation<=0?180:-180}else{scaleY*=-1;skewX+=skewX<=0?180:-180}} uncache=uncache||cache.uncache;cache.x=x-((cache.xPercent=x&&(!uncache&&cache.xPercent||(Math.round(target.offsetWidth/2)===Math.round(-x)?-50:0)))?target.offsetWidth*cache.xPercent/100:0)+px;cache.y=y-((cache.yPercent=y&&(!uncache&&cache.yPercent||(Math.round(target.offsetHeight/2)===Math.round(-y)?-50:0)))?target.offsetHeight*cache.yPercent/100:0)+px;cache.z=z+px;cache.scaleX=_round(scaleX);cache.scaleY=_round(scaleY);cache.rotation=_round(rotation)+deg;cache.rotationX=_round(rotationX)+deg;cache.rotationY=_round(rotationY)+deg;cache.skewX=skewX+deg;cache.skewY=skewY+deg;cache.transformPerspective=perspective+px;if(cache.zOrigin=parseFloat(origin.split(" ")[2])||0){style[_transformOriginProp]=_firstTwoOnly(origin)} cache.xOffset=cache.yOffset=0;cache.force3D=_config.force3D;cache.renderTransform=cache.svg?_renderSVGTransforms:_supports3D?_renderCSSTransforms:_renderNon3DTransforms;cache.uncache=0;return cache},_firstTwoOnly=function _firstTwoOnly(value){return(value=value.split(" "))[0]+" "+value[1]},_addPxTranslate=function _addPxTranslate(target,start,value){var unit=getUnit(start);return _round(parseFloat(start)+parseFloat(_convertToUnit(target,"x",value+"px",unit)))+unit},_renderNon3DTransforms=function _renderNon3DTransforms(ratio,cache){cache.z="0px";cache.rotationY=cache.rotationX="0deg";cache.force3D=0;_renderCSSTransforms(ratio,cache)},_zeroDeg="0deg",_zeroPx="0px",_endParenthesis=") ",_renderCSSTransforms=function _renderCSSTransforms(ratio,cache){var _ref=cache||this,xPercent=_ref.xPercent,yPercent=_ref.yPercent,x=_ref.x,y=_ref.y,z=_ref.z,rotation=_ref.rotation,rotationY=_ref.rotationY,rotationX=_ref.rotationX,skewX=_ref.skewX,skewY=_ref.skewY,scaleX=_ref.scaleX,scaleY=_ref.scaleY,transformPerspective=_ref.transformPerspective,force3D=_ref.force3D,target=_ref.target,zOrigin=_ref.zOrigin,transforms="",use3D=force3D==="auto"&&ratio&&ratio!==1||force3D===!0;if(zOrigin&&(rotationX!==_zeroDeg||rotationY!==_zeroDeg)){var angle=parseFloat(rotationY)*_DEG2RAD,a13=Math.sin(angle),a33=Math.cos(angle),cos;angle=parseFloat(rotationX)*_DEG2RAD;cos=Math.cos(angle);x=_addPxTranslate(target,x,a13*cos*-zOrigin);y=_addPxTranslate(target,y,-Math.sin(angle)*-zOrigin);z=_addPxTranslate(target,z,a33*cos*-zOrigin+zOrigin)} if(transformPerspective!==_zeroPx){transforms+="perspective("+transformPerspective+_endParenthesis} if(xPercent||yPercent){transforms+="translate("+xPercent+"%, "+yPercent+"%) "} if(use3D||x!==_zeroPx||y!==_zeroPx||z!==_zeroPx){transforms+=z!==_zeroPx||use3D?"translate3d("+x+", "+y+", "+z+") ":"translate("+x+", "+y+_endParenthesis} if(rotation!==_zeroDeg){transforms+="rotate("+rotation+_endParenthesis} if(rotationY!==_zeroDeg){transforms+="rotateY("+rotationY+_endParenthesis} if(rotationX!==_zeroDeg){transforms+="rotateX("+rotationX+_endParenthesis} if(skewX!==_zeroDeg||skewY!==_zeroDeg){transforms+="skew("+skewX+", "+skewY+_endParenthesis} if(scaleX!==1||scaleY!==1){transforms+="scale("+scaleX+", "+scaleY+_endParenthesis} target.style[_transformProp]=transforms||"translate(0, 0)"},_renderSVGTransforms=function _renderSVGTransforms(ratio,cache){var _ref2=cache||this,xPercent=_ref2.xPercent,yPercent=_ref2.yPercent,x=_ref2.x,y=_ref2.y,rotation=_ref2.rotation,skewX=_ref2.skewX,skewY=_ref2.skewY,scaleX=_ref2.scaleX,scaleY=_ref2.scaleY,target=_ref2.target,xOrigin=_ref2.xOrigin,yOrigin=_ref2.yOrigin,xOffset=_ref2.xOffset,yOffset=_ref2.yOffset,forceCSS=_ref2.forceCSS,tx=parseFloat(x),ty=parseFloat(y),a11,a21,a12,a22,temp;rotation=parseFloat(rotation);skewX=parseFloat(skewX);skewY=parseFloat(skewY);if(skewY){skewY=parseFloat(skewY);skewX+=skewY;rotation+=skewY} if(rotation||skewX){rotation*=_DEG2RAD;skewX*=_DEG2RAD;a11=Math.cos(rotation)*scaleX;a21=Math.sin(rotation)*scaleX;a12=Math.sin(rotation-skewX)*-scaleY;a22=Math.cos(rotation-skewX)*scaleY;if(skewX){skewY*=_DEG2RAD;temp=Math.tan(skewX-skewY);temp=Math.sqrt(1+temp*temp);a12*=temp;a22*=temp;if(skewY){temp=Math.tan(skewY);temp=Math.sqrt(1+temp*temp);a11*=temp;a21*=temp}} a11=_round(a11);a21=_round(a21);a12=_round(a12);a22=_round(a22)}else{a11=scaleX;a22=scaleY;a21=a12=0} if(tx&&!~(x+"").indexOf("px")||ty&&!~(y+"").indexOf("px")){tx=_convertToUnit(target,"x",x,"px");ty=_convertToUnit(target,"y",y,"px")} if(xOrigin||yOrigin||xOffset||yOffset){tx=_round(tx+xOrigin-(xOrigin*a11+yOrigin*a12)+xOffset);ty=_round(ty+yOrigin-(xOrigin*a21+yOrigin*a22)+yOffset)} if(xPercent||yPercent){temp=target.getBBox();tx=_round(tx+xPercent/100*temp.width);ty=_round(ty+yPercent/100*temp.height)} temp="matrix("+a11+","+a21+","+a12+","+a22+","+tx+","+ty+")";target.setAttribute("transform",temp);forceCSS&&(target.style[_transformProp]=temp)},_addRotationalPropTween=function _addRotationalPropTween(plugin,target,property,startNum,endValue){var cap=360,isString=_isString(endValue),endNum=parseFloat(endValue)*(isString&&~endValue.indexOf("rad")?_RAD2DEG:1),change=endNum-startNum,finalValue=startNum+change+"deg",direction,pt;if(isString){direction=endValue.split("_")[1];if(direction==="short"){change%=cap;if(change!==change%(cap/2)){change+=change<0?cap:-cap}} if(direction==="cw"&&change<0){change=(change+cap*_bigNum$1)%cap-~~(change/cap)*cap}else if(direction==="ccw"&&change>0){change=(change-cap*_bigNum$1)%cap-~~(change/cap)*cap}} plugin._pt=pt=new PropTween(plugin._pt,target,property,startNum,change,_renderPropWithEnd);pt.e=finalValue;pt.u="deg";plugin._props.push(property);return pt},_assign=function _assign(target,source){for(var p in source){target[p]=source[p]} return target},_addRawTransformPTs=function _addRawTransformPTs(plugin,transforms,target){var startCache=_assign({},target._gsap),exclude="perspective,force3D,transformOrigin,svgOrigin",style=target.style,endCache,p,startValue,endValue,startNum,endNum,startUnit,endUnit;if(startCache.svg){startValue=target.getAttribute("transform");target.setAttribute("transform","");style[_transformProp]=transforms;endCache=_parseTransform(target,1);_removeProperty(target,_transformProp);target.setAttribute("transform",startValue)}else{startValue=getComputedStyle(target)[_transformProp];style[_transformProp]=transforms;endCache=_parseTransform(target,1);style[_transformProp]=startValue} for(p in _transformProps){startValue=startCache[p];endValue=endCache[p];if(startValue!==endValue&&exclude.indexOf(p)<0){startUnit=getUnit(startValue);endUnit=getUnit(endValue);startNum=startUnit!==endUnit?_convertToUnit(target,p,startValue,endUnit):parseFloat(startValue);endNum=parseFloat(endValue);plugin._pt=new PropTween(plugin._pt,endCache,p,startNum,endNum-startNum,_renderCSSProp);plugin._pt.u=endUnit||0;plugin._props.push(p)}} _assign(endCache,startCache)};_forEachName("padding,margin,Width,Radius",function(name,index){var t="Top",r="Right",b="Bottom",l="Left",props=(index<3?[t,r,b,l]:[t+l,t+r,b+r,b+l]).map(function(side){return index<2?name+side:"border"+side+name});_specialProps[index>1?"border"+name:name]=function(plugin,target,property,endValue,tween){var a,vars;if(arguments.length<4){a=props.map(function(prop){return _get(plugin,prop,property)});vars=a.join(" ");return vars.split(a[0]).length===5?a[0]:vars} a=(endValue+"").split(" ");vars={};props.forEach(function(prop,i){return vars[prop]=a[i]=a[i]||a[(i-1)/2|0]});plugin.init(target,vars,tween)}});var CSSPlugin={name:"css",register:_initCore,targetTest:function targetTest(target){return target.style&&target.nodeType},init:function init(target,vars,tween,index,targets){var props=this._props,style=target.style,startAt=tween.vars.startAt,startValue,endValue,endNum,startNum,type,specialProp,p,startUnit,endUnit,relative,isTransformRelated,transformPropTween,cache,smooth,hasPriority,inlineProps;_pluginInitted||_initCore();this.styles=this.styles||_getStyleSaver(target);inlineProps=this.styles.props;this.tween=tween;for(p in vars){if(p==="autoRound"){continue} endValue=vars[p];if(_plugins[p]&&_checkPlugin(p,vars,tween,index,target,targets)){continue} type=typeof endValue;specialProp=_specialProps[p];if(type==="function"){endValue=endValue.call(tween,index,target,targets);type=typeof endValue} if(type==="string"&&~endValue.indexOf("random(")){endValue=_replaceRandom(endValue)} if(specialProp){specialProp(this,target,p,endValue,tween)&&(hasPriority=1)}else if(p.substr(0,2)==="--"){startValue=(getComputedStyle(target).getPropertyValue(p)+"").trim();endValue+="";_colorExp.lastIndex=0;if(!_colorExp.test(startValue)){startUnit=getUnit(startValue);endUnit=getUnit(endValue)} endUnit?startUnit!==endUnit&&(startValue=_convertToUnit(target,p,startValue,endUnit)+endUnit):startUnit&&(endValue+=startUnit);this.add(style,"setProperty",startValue,endValue,index,targets,0,0,p);props.push(p);inlineProps.push(p,0,style[p])}else if(type!=="undefined"){if(startAt&&p in startAt){startValue=typeof startAt[p]==="function"?startAt[p].call(tween,index,target,targets):startAt[p];_isString(startValue)&&~startValue.indexOf("random(")&&(startValue=_replaceRandom(startValue));getUnit(startValue+"")||(startValue+=_config.units[p]||getUnit(_get(target,p))||"");(startValue+"").charAt(1)==="="&&(startValue=_get(target,p))}else{startValue=_get(target,p)} startNum=parseFloat(startValue);relative=type==="string"&&endValue.charAt(1)==="="&&endValue.substr(0,2);relative&&(endValue=endValue.substr(2));endNum=parseFloat(endValue);if(p in _propertyAliases){if(p==="autoAlpha"){if(startNum===1&&_get(target,"visibility")==="hidden"&&endNum){startNum=0} inlineProps.push("visibility",0,style.visibility);_addNonTweeningPT(this,style,"visibility",startNum?"inherit":"hidden",endNum?"inherit":"hidden",!endNum)} if(p!=="scale"&&p!=="transform"){p=_propertyAliases[p];~p.indexOf(",")&&(p=p.split(",")[0])}} isTransformRelated=p in _transformProps;if(isTransformRelated){this.styles.save(p);if(!transformPropTween){cache=target._gsap;cache.renderTransform&&!vars.parseTransform||_parseTransform(target,vars.parseTransform);smooth=vars.smoothOrigin!==!1&&cache.smooth;transformPropTween=this._pt=new PropTween(this._pt,style,_transformProp,0,1,cache.renderTransform,cache,0,-1);transformPropTween.dep=1} if(p==="scale"){this._pt=new PropTween(this._pt,cache,"scaleY",startNum,(relative?_parseRelative(startNum,relative+endNum):endNum)-startNum||0,_renderCSSProp);this._pt.u=0;props.push("scaleY",p);p+="X"}else if(p==="transformOrigin"){inlineProps.push(_transformOriginProp,0,style[_transformOriginProp]);endValue=_convertKeywordsToPercentages(endValue);if(cache.svg){_applySVGOrigin(target,endValue,0,smooth,0,this)}else{endUnit=parseFloat(endValue.split(" ")[2])||0;endUnit!==cache.zOrigin&&_addNonTweeningPT(this,cache,"zOrigin",cache.zOrigin,endUnit);_addNonTweeningPT(this,style,p,_firstTwoOnly(startValue),_firstTwoOnly(endValue))} continue}else if(p==="svgOrigin"){_applySVGOrigin(target,endValue,1,smooth,0,this);continue}else if(p in _rotationalProperties){_addRotationalPropTween(this,cache,p,startNum,relative?_parseRelative(startNum,relative+endValue):endValue);continue}else if(p==="smoothOrigin"){_addNonTweeningPT(this,cache,"smooth",cache.smooth,endValue);continue}else if(p==="force3D"){cache[p]=endValue;continue}else if(p==="transform"){_addRawTransformPTs(this,endValue,target);continue}}else if(!(p in style)){p=_checkPropPrefix(p)||p} if(isTransformRelated||(endNum||endNum===0)&&(startNum||startNum===0)&&!_complexExp.test(endValue)&&p in style){startUnit=(startValue+"").substr((startNum+"").length);endNum||(endNum=0);endUnit=getUnit(endValue)||(p in _config.units?_config.units[p]:startUnit);startUnit!==endUnit&&(startNum=_convertToUnit(target,p,startValue,endUnit));this._pt=new PropTween(this._pt,isTransformRelated?cache:style,p,startNum,(relative?_parseRelative(startNum,relative+endNum):endNum)-startNum,!isTransformRelated&&(endUnit==="px"||p==="zIndex")&&vars.autoRound!==!1?_renderRoundedCSSProp:_renderCSSProp);this._pt.u=endUnit||0;if(startUnit!==endUnit&&endUnit!=="%"){this._pt.b=startValue;this._pt.r=_renderCSSPropWithBeginning}}else if(!(p in style)){if(p in target){this.add(target,p,startValue||target[p],relative?relative+endValue:endValue,index,targets)}else{_missingPlugin(p,endValue);continue}}else{_tweenComplexCSSString.call(this,target,p,startValue,relative?relative+endValue:endValue)} isTransformRelated||(p in style?inlineProps.push(p,0,style[p]):inlineProps.push(p,1,startValue||target[p]));props.push(p)}} hasPriority&&_sortPropTweensByPriority(this)},render:function render(ratio,data){if(data.tween._time||!_reverting$1()){var pt=data._pt;while(pt){pt.r(ratio,pt.d);pt=pt._next}}else{data.styles.revert()}},get:_get,aliases:_propertyAliases,getSetter:function getSetter(target,property,plugin){var p=_propertyAliases[property];p&&p.indexOf(",")<0&&(property=p);return property in _transformProps&&property!==_transformOriginProp&&(target._gsap.x||_get(target,"x"))?plugin&&_recentSetterPlugin===plugin?property==="scale"?_setterScale:_setterTransform:(_recentSetterPlugin=plugin||{})&&(property==="scale"?_setterScaleWithRender:_setterTransformWithRender):target.style&&!_isUndefined(target.style[property])?_setterCSSStyle:~property.indexOf("-")?_setterCSSProp:_getSetter(target,property)},core:{_removeProperty:_removeProperty,_getMatrix:_getMatrix}};gsap.utils.checkPrefix=_checkPropPrefix;gsap.core.getStyleSaver=_getStyleSaver;(function(positionAndScale,rotation,others,aliases){var all=_forEachName(positionAndScale+","+rotation+","+others,function(name){_transformProps[name]=1});_forEachName(rotation,function(name){_config.units[name]="deg";_rotationalProperties[name]=1});_propertyAliases[all[13]]=positionAndScale+","+rotation;_forEachName(aliases,function(name){var split=name.split(":");_propertyAliases[split[1]]=all[split[0]]})})("x,y,z,scale,scaleX,scaleY,xPercent,yPercent","rotation,rotationX,rotationY,skewX,skewY","transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective","0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY");_forEachName("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(name){_config.units[name]="px"});gsap.registerPlugin(CSSPlugin);var gsapWithCSS=gsap.registerPlugin(CSSPlugin)||gsap,TweenMaxWithCSS=gsapWithCSS.core.Tween;exports.Back=Back;exports.Bounce=Bounce;exports.CSSPlugin=CSSPlugin;exports.Circ=Circ;exports.Cubic=Cubic;exports.Elastic=Elastic;exports.Expo=Expo;exports.Linear=Linear;exports.Power0=Power0;exports.Power1=Power1;exports.Power2=Power2;exports.Power3=Power3;exports.Power4=Power4;exports.Quad=Quad;exports.Quart=Quart;exports.Quint=Quint;exports.Sine=Sine;exports.SteppedEase=SteppedEase;exports.Strong=Strong;exports.TimelineLite=Timeline;exports.TimelineMax=Timeline;exports.TweenLite=Tween;exports.TweenMax=TweenMaxWithCSS;exports.default=gsapWithCSS;exports.gsap=gsapWithCSS;if(typeof(window)==='undefined'||window!==exports){Object.defineProperty(exports,'__esModule',{value:!0})}else{delete window.default}})));(function(window,$){"use strict";var counter=0,$headCache=$('head'),oldBigText=window.BigText,oldjQueryMethod=$.fn.bigtext,BigText={DEBUG_MODE:!1,DEFAULT_MIN_FONT_SIZE_PX:null,DEFAULT_MAX_FONT_SIZE_PX:528,GLOBAL_STYLE_ID:'bigtext-style',STYLE_ID:'bigtext-id',LINE_CLASS_PREFIX:'bigtext-line',EXEMPT_CLASS:'bigtext-exempt',noConflict:function(restore){if(restore){$.fn.bigtext=oldjQueryMethod;window.BigText=oldBigText} return BigText},supports:{wholeNumberFontSizeOnly:(function(){if(!('getComputedStyle' in window)){return!0} var test=$('
').css({position:'absolute','font-size':'14.1px'}).insertBefore($('script').eq(0)),computedStyle=window.getComputedStyle(test[0],null);var ret=computedStyle&&computedStyle.getPropertyValue('font-size')==='14px';test.remove();return ret})()},init:function(){if(!$('#'+BigText.GLOBAL_STYLE_ID).length){$headCache.append(BigText.generateStyleTag(BigText.GLOBAL_STYLE_ID,['.bigtext * { white-space: nowrap; } .bigtext > * { display: block; }','.bigtext .'+BigText.EXEMPT_CLASS+', .bigtext .'+BigText.EXEMPT_CLASS+' * { white-space: normal; }']))}},bindResize:function(eventName,resizeFunction){var timeoutId;$(window).off(eventName).on(eventName,function(){if(timeoutId){clearTimeout(timeoutId)} timeoutId=setTimeout(resizeFunction,100)})},getStyleId:function(id){return BigText.STYLE_ID+'-'+id},generateStyleTag:function(id,css){return $('').attr('id',id)},clearCss:function(id){var styleId=BigText.getStyleId(id);$('#'+styleId).remove()},generateCss:function(id,linesFontSizes,lineWordSpacings,minFontSizes){var css=[];BigText.clearCss(id);for(var j=0,k=linesFontSizes.length;j=maxWidth){$line.css(property,'');if(width===maxWidth){return{match:'exact',size:parseFloat((parseFloat(size)-0.1).toFixed(3))}} var under=maxWidth-previousWidth,over=width-maxWidth;return{match:'estimate',size:parseFloat((parseFloat(size)-(property==='word-spacing'&&previousWidth&&(overmaxFontSize){newFontSize=maxFontSize;break outer} lineMax=BigText.testLineDimensions($line,maxWidth,'font-size',newFontSize+j*intervals[m],intervals[m],'px',lineMax);if(typeof lineMax!=='number'){newFontSize=lineMax.size;if(lineMax.match==='exact'){break outer} break inner}}} ratios.push(maxWidth/newFontSize);if(newFontSize>maxFontSize){fontSizes.push(maxFontSize);minFontSizes.push(!1)}else if(!!minFontSize&&newFontSize
";this.core.outer.addClass('lg-has-thumb');if(this.settings.appendThumbnailsTo==='.lg-components'){this.core.$lgComponents.append(html)}else{this.core.outer.append(html)} this.$thumbOuter=this.core.outer.find('.lg-thumb-outer').first();this.$lgThumb=this.core.outer.find('.lg-thumb').first();if(this.settings.animateThumb){this.core.outer.find('.lg-thumb').css('transition-duration',this.core.settings.speed+'ms').css('width',this.thumbTotalWidth+'px').css('position','relative')} this.setThumbItemHtml(this.core.galleryItems)};Thumbnail.prototype.enableThumbDrag=function(){var _this=this;var thumbDragUtils={cords:{startX:0,endX:0,},isMoved:!1,newTranslateX:0,startTime:new Date(),endTime:new Date(),touchMoveTime:0,};var isDragging=!1;this.$thumbOuter.addClass('lg-grab');this.core.outer.find('.lg-thumb').first().on('mousedown.lg.thumb',function(e){if(_this.thumbTotalWidth>_this.thumbOuterWidth){e.preventDefault();thumbDragUtils.cords.startX=e.pageX;thumbDragUtils.startTime=new Date();_this.thumbClickable=!1;isDragging=!0;_this.core.outer.get().scrollLeft+=1;_this.core.outer.get().scrollLeft-=1;_this.$thumbOuter.removeClass('lg-grab').addClass('lg-grabbing')}});this.$LG(window).on("mousemove.lg.thumb.global"+this.core.lgId,function(e){if(!_this.core.lgOpened) return;if(isDragging){thumbDragUtils.cords.endX=e.pageX;thumbDragUtils=_this.onThumbTouchMove(thumbDragUtils)}});this.$LG(window).on("mouseup.lg.thumb.global"+this.core.lgId,function(){if(!_this.core.lgOpened) return;if(thumbDragUtils.isMoved){thumbDragUtils=_this.onThumbTouchEnd(thumbDragUtils)}else{_this.thumbClickable=!0} if(isDragging){isDragging=!1;_this.$thumbOuter.removeClass('lg-grabbing').addClass('lg-grab')}})};Thumbnail.prototype.enableThumbSwipe=function(){var _this=this;var thumbDragUtils={cords:{startX:0,endX:0,},isMoved:!1,newTranslateX:0,startTime:new Date(),endTime:new Date(),touchMoveTime:0,};this.$lgThumb.on('touchstart.lg',function(e){if(_this.thumbTotalWidth>_this.thumbOuterWidth){e.preventDefault();thumbDragUtils.cords.startX=e.targetTouches[0].pageX;_this.thumbClickable=!1;thumbDragUtils.startTime=new Date()}});this.$lgThumb.on('touchmove.lg',function(e){if(_this.thumbTotalWidth>_this.thumbOuterWidth){e.preventDefault();thumbDragUtils.cords.endX=e.targetTouches[0].pageX;thumbDragUtils=_this.onThumbTouchMove(thumbDragUtils)}});this.$lgThumb.on('touchend.lg',function(){if(thumbDragUtils.isMoved){thumbDragUtils=_this.onThumbTouchEnd(thumbDragUtils)}else{_this.thumbClickable=!0}})};Thumbnail.prototype.rebuildThumbnails=function(){var _this=this;this.$thumbOuter.addClass('lg-rebuilding-thumbnails');setTimeout(function(){_this.thumbTotalWidth=_this.core.galleryItems.length*(_this.settings.thumbWidth+_this.settings.thumbMargin);_this.$lgThumb.css('width',_this.thumbTotalWidth+'px');_this.$lgThumb.empty();_this.setThumbItemHtml(_this.core.galleryItems);_this.animateThumb(_this.core.index)},50);setTimeout(function(){_this.$thumbOuter.removeClass('lg-rebuilding-thumbnails')},200)};Thumbnail.prototype.setTranslate=function(value){this.$lgThumb.css('transform','translate3d(-'+value+'px, 0px, 0px)')};Thumbnail.prototype.getPossibleTransformX=function(left){if(left>this.thumbTotalWidth-this.thumbOuterWidth){left=this.thumbTotalWidth-this.thumbOuterWidth} if(left<0){left=0} return left};Thumbnail.prototype.animateThumb=function(index){this.$lgThumb.css('transition-duration',this.core.settings.speed+'ms');if(this.settings.animateThumb){var position=0;switch(this.settings.currentPagerPosition){case 'left':position=0;break;case 'middle':position=this.thumbOuterWidth/2-this.settings.thumbWidth/2;break;case 'right':position=this.thumbOuterWidth-this.settings.thumbWidth} this.translateX=(this.settings.thumbWidth+this.settings.thumbMargin)*index-1-position;if(this.translateX>this.thumbTotalWidth-this.thumbOuterWidth){this.translateX=this.thumbTotalWidth-this.thumbOuterWidth} if(this.translateX<0){this.translateX=0} this.setTranslate(this.translateX)}};Thumbnail.prototype.onThumbTouchMove=function(thumbDragUtils){thumbDragUtils.newTranslateX=this.translateX;thumbDragUtils.isMoved=!0;thumbDragUtils.touchMoveTime=new Date().valueOf();thumbDragUtils.newTranslateX-=thumbDragUtils.cords.endX-thumbDragUtils.cords.startX;thumbDragUtils.newTranslateX=this.getPossibleTransformX(thumbDragUtils.newTranslateX);this.setTranslate(thumbDragUtils.newTranslateX);this.$thumbOuter.addClass('lg-dragging');return thumbDragUtils};Thumbnail.prototype.onThumbTouchEnd=function(thumbDragUtils){thumbDragUtils.isMoved=!1;thumbDragUtils.endTime=new Date();this.$thumbOuter.removeClass('lg-dragging');var touchDuration=thumbDragUtils.endTime.valueOf()-thumbDragUtils.startTime.valueOf();var distanceXnew=thumbDragUtils.cords.endX-thumbDragUtils.cords.startX;var speedX=Math.abs(distanceXnew)/touchDuration;if(speedX>0.15&&thumbDragUtils.endTime.valueOf()-thumbDragUtils.touchMoveTime<30){speedX+=1;if(speedX>2){speedX+=1} speedX=speedX+speedX*(Math.abs(distanceXnew)/this.thumbOuterWidth);this.$lgThumb.css('transition-duration',Math.min(speedX-1,2)+'settings');distanceXnew=distanceXnew*speedX;this.translateX=this.getPossibleTransformX(this.translateX-distanceXnew);this.setTranslate(this.translateX)}else{this.translateX=thumbDragUtils.newTranslateX} if(Math.abs(thumbDragUtils.cords.endX-thumbDragUtils.cords.startX)\n \n "};Thumbnail.prototype.getThumbItemHtml=function(items){var thumbList='';for(var i=0;i');this.core.outer.find('.lg-toggle-thumb').first().on('click.lg',function(){_this.core.outer.toggleClass('lg-components-open')})}};Thumbnail.prototype.thumbKeyPress=function(){var _this=this;this.$LG(window).on("keydown.lg.thumb.global"+this.core.lgId,function(e){if(!_this.core.lgOpened||!_this.settings.toggleThumb) return;if(e.keyCode===38){e.preventDefault();_this.core.outer.addClass('lg-components-open')}else if(e.keyCode===40){e.preventDefault();_this.core.outer.removeClass('lg-components-open')}})};Thumbnail.prototype.destroy=function(){if(this.settings.thumbnail){this.$LG(window).off(".lg.thumb.global"+this.core.lgId);this.core.LGel.off('.lg.thumb');this.core.LGel.off('.thumb');this.$thumbOuter.remove();this.core.outer.removeClass('lg-has-thumb')}};return Thumbnail}());return Thumbnail}))); /*! * lightgallery | 2.5.0 | June 13th 2022 * http://www.lightgalleryjs.com/ * Copyright (c) 2020 Sachin Neravath; * @license GPLv3 */ (function(global,factory){typeof exports==='object'&&typeof module!=='undefined'?module.exports=factory():typeof define==='function'&&define.amd?define(factory):(global=typeof globalThis!=='undefined'?globalThis:global||self,global.lgVideo=factory())}(this,(function(){'use strict';/*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */ var __assign=function(){__assign=Object.assign||function __assign(t){for(var s,i=1,n=arguments.length;i";var tag=document.createElement('script');tag.src="http://www.youtube.com/player_api";var firstScriptTag=document.getElementsByTagName('script')[0];firstScriptTag.parentNode.insertBefore(tag,firstScriptTag);var ytIframeplayer,setMute=muted==='yes'?0:100;window.onYouTubePlayerAPIReady=function(){ytIframeplayer=new YT.Player(videoId,{videoId:videoInfo.youtube[1],events:{'onReady':function(event){event.target.setVolume(setMute)}}})}}else if(videoInfo.vimeo){var videoId='lg-vimeo'+index;videoInfo.autoplay=autoplay;videoInfo.muted=muted;var playerParams=getVimeoURLParams(this.settings.vimeoPlayerParams,videoInfo);var data_video='';if(autoplay!==''){data_video=' data-autoplay="'+(autoplay==='yes'?1:0)+'"'} video=""}else if(videoInfo.wistia){var wistiaId='lg-wistia'+index;var playerParams=param(this.settings.wistiaPlayerParams);playerParams=playerParams?'?'+playerParams:'';video=""}else if(videoInfo.html5){var html5VideoMarkup='';for(var i=0;i"} if(html5Video.tracks){var _loop_1=function(i){var trackAttributes='';var track=html5Video.tracks[i];Object.keys(track||{}).forEach(function(key){trackAttributes+=key+"=\""+track[key]+"\" "});html5VideoMarkup+=""};for(var i=0;i\n "+html5VideoMarkup+"\n Your browser does not support HTML5 video.\n "} return video};Video.prototype.appendVideos=function(el,videoParams){var _a;var videoHtml=this.getVideoHtml(videoParams.src,videoParams.addClass,videoParams.index,videoParams.html5Video,videoParams.autoplay,videoParams.muted);el.find('.lg-video-cont').append(videoHtml);var $videoElement=el.find('.lg-video-object').first();if(videoParams.html5Video){$videoElement.on('mousedown.lg.video',function(e){e.stopPropagation()})} if(this.settings.videojs&&((_a=this.core.galleryItems[videoParams.index].__slideVideoInfo)===null||_a===void 0?void 0:_a.html5)){try{return videojs($videoElement.get(),this.settings.videojsOptions)}catch(e){console.warn('lightGallery:- Make sure you have included videojs')}}};Video.prototype.gotoNextSlideOnVideoEnd=function(src,index){var _this=this;var $videoElement=this.core.getSlideItem(index).find('.lg-video-object').first();var videoInfo=this.core.galleryItems[index].__slideVideoInfo||{};if(this.settings.gotoNextSlideOnVideoEnd){if(videoInfo.html5){$videoElement.on('ended',function(){_this.core.goToNextSlide()})}else if(videoInfo.vimeo){try{new Vimeo.Player($videoElement.get()).on('ended',function(){_this.core.goToNextSlide()})}catch(e){console.warn('lightGallery:- Make sure you have included //github.com/vimeo/player.js')}}else if(videoInfo.wistia){try{window._wq=window._wq||[];window._wq.push({id:$videoElement.attr('id'),onReady:function(video){video.bind('end',function(){_this.core.goToNextSlide()})},})}catch(e){console.warn('lightGallery:- Make sure you have included //fast.wistia.com/assets/external/E-v1.js')}}}};Video.prototype.controlVideo=function(index,action){var $videoElement=this.core.getSlideItem(index).find('.lg-video-object').first();var videoInfo=this.core.galleryItems[index].__slideVideoInfo||{};if(!$videoElement.get()) return;if(videoInfo.youtube){try{$videoElement.get().contentWindow.postMessage("{\"event\":\"command\",\"func\":\""+action+"Video\",\"args\":\"\"}",'*')}catch(e){console.warn("lightGallery:- "+e)}}else if(videoInfo.vimeo){try{new Vimeo.Player($videoElement.get())[action]()}catch(e){console.warn('lightGallery:- Make sure you have included //github.com/vimeo/player.js')}}else if(videoInfo.html5){if(this.settings.videojs){try{videojs($videoElement.get())[action]()}catch(e){console.warn('lightGallery:- Make sure you have included videojs')}}else{$videoElement.get()[action]()}}else if(videoInfo.wistia){try{window._wq=window._wq||[];window._wq.push({id:$videoElement.attr('id'),onReady:function(video){video[action]()},})}catch(e){console.warn('lightGallery:- Make sure you have included //fast.wistia.com/assets/external/E-v1.js')}}};Video.prototype.loadVideoOnPosterClick=function($el,forcePlay){var _this=this;if(!$el.hasClass('lg-video-loaded')){if(!$el.hasClass('lg-has-video')){$el.addClass('lg-has-video');var _html=void 0;var _src=this.core.galleryItems[this.core.index].src;var video=this.core.galleryItems[this.core.index].video;if(video){_html=typeof video==='string'?JSON.parse(video):video} var videoJsPlayer_1=this.appendVideos($el,{src:_src,addClass:'',index:this.core.index,html5Video:_html,});this.gotoNextSlideOnVideoEnd(_src,this.core.index);var $tempImg=$el.find('.lg-object').first().get();$el.find('.lg-video-cont').first().append($tempImg);$el.addClass('lg-video-loading');videoJsPlayer_1&&videoJsPlayer_1.ready(function(){videoJsPlayer_1.on('loadedmetadata',function(){_this.onVideoLoadAfterPosterClick($el,_this.core.index)})});$el.find('.lg-video-object').first().on('load.lg error.lg loadedmetadata.lg',function(){setTimeout(function(){_this.onVideoLoadAfterPosterClick($el,_this.core.index)},50)})}else{this.playVideo(this.core.index)}}else if(forcePlay){this.playVideo(this.core.index)}};Video.prototype.onVideoLoadAfterPosterClick=function($el,index){$el.addClass('lg-video-loaded');this.playVideo(index)};Video.prototype.destroy=function(){this.core.LGel.off('.lg.video');this.core.LGel.off('.video')};return Video}());return Video}))); /*! @vimeo/player v2.17.1 | (c) 2022 Vimeo | MIT License | https://github.com/vimeo/player.js */ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):((e="undefined"!=typeof globalThis?globalThis:e||self).Vimeo=e.Vimeo||{},e.Vimeo.Player=t())}(this,function(){"use strict";function r(e,t){for(var n=0;n1||cache.items.merge;widths[iterator]=!grid?this._items[iterator].width():width*merge} this._widths=widths}},{filter:['items','settings'],run:function(){var clones=[],items=this._items,settings=this.settings,view=Math.max(settings.items*2,4),size=Math.ceil(items.length/2)*2,repeat=settings.loop&&items.length?settings.rewind?view:Math.max(view,size):0,append='',prepend='';repeat/=2;while(repeat--){clones.push(this.normalize(clones.length/2,!0));append=append+items[clones[clones.length-1]][0].outerHTML;clones.push(this.normalize(items.length-1-(clones.length-1)/2,!0));prepend=items[clones[clones.length-1]][0].outerHTML+prepend} this._clones=clones;$(append).addClass('cloned').appendTo(this.$stage);$(prepend).addClass('cloned').prependTo(this.$stage)}},{filter:['width','items','settings'],run:function(){var rtl=this.settings.rtl?1:-1,size=this._clones.length+this._items.length,iterator=-1,previous=0,current=0,coordinates=[];while(++iterator0)?41:(this._width*this.settings.stagePadding)/200,padding=stagePadding,coordinates=this._coordinates,css={'width':Math.ceil(Math.abs(coordinates[coordinates.length-1]))+padding*2,'padding-left':padding||'','padding-right':padding||''};this.$stage.css(css)}},{filter:['width','items','settings'],run:function(cache){var iterator=this._coordinates.length,grid=!this.settings.autoWidth,items=this.$stage.children();if(grid&&cache.items.merge){while(iterator--){cache.css.width=this._widths[this.relative(iterator)];items.eq(iterator).css(cache.css)}}else if(grid){cache.css.width=cache.items.width;items.css(cache.css)}}},{filter:['items'],run:function(){this._coordinates.length<1&&this.$stage.removeAttr('style')}},{filter:['width','items','settings'],run:function(cache){cache.current=cache.current?this.$stage.children().index(cache.current):0;cache.current=Math.max(this.minimum(),Math.min(this.maximum(),cache.current));this.reset(cache.current)}},{filter:['position'],run:function(){this.animate(this.coordinates(this._current))}},{filter:['width','position','items','settings'],run:function(){var stagePadding=(this._width<480&&this.settings.stagePadding>0)?41:(this._width*this.settings.stagePadding)/200,rtl=this.settings.rtl?1:-1,padding=this.settings.stagePadding*2,begin=this.coordinates(this.current())+padding,end=begin+this.width()*rtl,inner,outer,matches=[],i,n;for(i=0,n=this._coordinates.length;i',end)))||(this.op(outer,'<',begin)&&this.op(outer,'>',end))){matches.push(i)}} this.$stage.children('.active').removeClass('active');this.$stage.children(':eq('+matches.join('), :eq(')+')').addClass('active');if(this.settings.center){this.$stage.children('.center').removeClass('center');this.$stage.children().eq(this.current()).addClass('center')}}}];Owl.prototype.initialize=function(){this.enter('initializing');this.trigger('initialize');this.$element.toggleClass(this.settings.rtlClass,this.settings.rtl);if(this.settings.autoWidth&&!this.is('pre-loading')){var imgs,nestedSelector,width;imgs=this.$element.find('img');nestedSelector=this.settings.nestedItemSelector?'.'+this.settings.nestedItemSelector:undefined;width=this.$element.children(nestedSelector).width();if(imgs.length&&width<=0){this.preloadAutoWidthImages(imgs)}} this.$element.addClass(this.options.loadingClass);this.$stage=$('<'+this.settings.stageElement+' class="'+this.settings.stageClass+'"/>').wrap('
');this.$element.append(this.$stage.parent());this.replace(this.$element.children().not(this.$stage.parent()));if(this.$element.is(':visible')){this.refresh()}else{this.invalidate('width')} this.$element.removeClass(this.options.loadingClass).addClass(this.options.loadedClass);this.registerEventHandlers();this.leave('initializing');this.trigger('initialized')};Owl.prototype.setup=function(){var viewport=this.viewport(),overwrites=this.options.responsive,match=-1,settings=null;if(!overwrites){settings=$.extend({},this.options)}else{$.each(overwrites,function(breakpoint){if(breakpoint<=viewport&&breakpoint>match){match=Number(breakpoint)}});settings=$.extend({},this.options,overwrites[match]);delete settings.responsive;if(settings.responsiveClass){this.$element.attr('class',this.$element.attr('class').replace(new RegExp('('+this.options.responsiveClass+'-)\\S+\\s','g'),'$1'+match))}} if(this.settings===null||this._breakpoint!==match){this.trigger('change',{property:{name:'settings',value:settings}});this._breakpoint=match;this.settings=settings;this.invalidate('settings');this.trigger('changed',{property:{name:'settings',value:this.settings}})}};Owl.prototype.optionsLogic=function(){if(this.settings.autoWidth){this.settings.stagePadding=!1;this.settings.merge=!1}};Owl.prototype.prepare=function(item,index){var event=this.trigger('prepare',{content:item});if(!event.data){event.data=$('<'+this.settings.itemElement+'/>').addClass(this.options.itemClass).attr('data-index',index+1).append(item)} this.trigger('prepared',{content:event.data});return event.data};Owl.prototype.update=function(){var i=0,n=this._pipe.length,filter=$.proxy(function(p){return this[p]},this._invalidated),cache={};while(i0){this._pipe[i].run(cache)} i++} this._invalidated={};!this.is('valid')&&this.enter('valid')};Owl.prototype.width=function(dimension){dimension=dimension||Owl.Width.Default;var stagePadding=(this._width<480&&this.settings.stagePadding>0)?41:(this._width*this.settings.stagePadding)/200;switch(dimension){case Owl.Width.Inner:case Owl.Width.Outer:return this._width;default:return this._width-stagePadding*2+this.settings.margin}};Owl.prototype.refresh=function(){this.enter('refreshing');this.trigger('refresh');this.setup();this.optionsLogic();this.$element.addClass(this.options.refreshClass);this.update();this.$element.removeClass(this.options.refreshClass);this.leave('refreshing');this.trigger('refreshed')};Owl.prototype.onThrottledResize=function(){window.clearTimeout(this.resizeTimer);this.resizeTimer=window.setTimeout(this._handlers.onResize,this.settings.responsiveRefreshRate)};Owl.prototype.onResize=function(){if(!this._items.length){return!1} if(this._width===this.$element.width()){return!1} if(!this.$element.is(':visible')){return!1} this.enter('resizing');if(this.trigger('resize').isDefaultPrevented()){this.leave('resizing');return!1} this.invalidate('width');this.refresh();this.leave('resizing');this.trigger('resized')};Owl.prototype.registerEventHandlers=function(){if($.support.transition){this.$stage.on($.support.transition.end+'.owl.core',$.proxy(this.onTransitionEnd,this))} if(this.settings.responsive!==!1){this.on(window,'resize',this._handlers.onThrottledResize)} if(this.settings.mouseDrag){this.$element.addClass(this.options.dragClass);this.$stage.on('mousedown.owl.core',$.proxy(this.onDragStart,this));this.$stage.on('dragstart.owl.core selectstart.owl.core',function(){return!1})} if(this.settings.touchDrag){this.$stage.on('touchstart.owl.core',$.proxy(this.onDragStart,this));this.$stage.on('touchcancel.owl.core',$.proxy(this.onDragEnd,this))}};Owl.prototype.onDragStart=function(event){var stage=null;if(event.which===3){return} if($.support.transform){stage=this.$stage.css('transform').replace(/.*\(|\)| /g,'').split(',');stage={x:stage[stage.length===16?12:4],y:stage[stage.length===16?13:5]}}else{stage=this.$stage.position();stage={x:this.settings.rtl?stage.left+this.$stage.width()-this.width()+this.settings.margin:stage.left,y:stage.top}} if(this.is('animating')){$.support.transform?this.animate(stage.x):this.$stage.stop() this.invalidate('position')} this.$element.toggleClass(this.options.grabClass,event.type==='mousedown');this.speed(0);this._drag.time=new Date().getTime();this._drag.target=$(event.target);this._drag.stage.start=stage;this._drag.stage.current=stage;this._drag.pointer=this.pointer(event);$(document).on('mouseup.owl.core touchend.owl.core',$.proxy(this.onDragEnd,this));$(document).one('mousemove.owl.core touchmove.owl.core',$.proxy(function(event){var delta=this.difference(this._drag.pointer,this.pointer(event));$(document).on('mousemove.owl.core touchmove.owl.core',$.proxy(this.onDragMove,this));if(Math.abs(delta.x)0^this.settings.rtl?'left':'right';$(document).off('.owl.core');this.$element.removeClass(this.options.grabClass);if(delta.x!==0&&this.is('dragging')||!this.is('valid')){this.speed(this.settings.dragEndSpeed||this.settings.smartSpeed);this.current(this.closest(stage.x,delta.x!==0?direction:this._drag.direction));this.invalidate('position');this.update();this._drag.direction=direction;if(Math.abs(delta.x)>3||new Date().getTime()-this._drag.time>300){this._drag.target.one('click.owl.core',function(){return!1})}} if(!this.is('dragging')){return} this.leave('dragging');this.trigger('dragged')};Owl.prototype.closest=function(coordinate,direction){var position=-1,pull=30,width=this.width(),coordinates=this.coordinates();if(!this.settings.freeDrag){$.each(coordinates,$.proxy(function(index,value){if(coordinate>value-pull&&coordinate',coordinates[index+1]||value-width)){position=direction==='left'?index+1:index} return position===-1},this))} if(!this.settings.loop){if(this.op(coordinate,'>',coordinates[this.minimum()])){position=coordinate=this.minimum()}else if(this.op(coordinate,'<',coordinates[this.maximum()])){position=coordinate=this.maximum()}} return position};Owl.prototype.animate=function(coordinate){var animate=this.speed()>0;this.is('animating')&&this.onTransitionEnd();if(animate){this.enter('animating');this.trigger('translate')} if($.support.transform3d&&$.support.transition){this.$stage.css({transform:'translate3d('+coordinate+'px,0px,0px)',transition:(this.speed()/1000)+'s'})}else if(animate){this.$stage.animate({left:coordinate+'px'},this.speed(),this.settings.fallbackEasing,$.proxy(this.onTransitionEnd,this))}else{this.$stage.css({left:coordinate+'px'})}};Owl.prototype.is=function(state){return this._states.current[state]&&this._states.current[state]>0};Owl.prototype.current=function(position){if(position===undefined){return this._current} if(this._items.length===0){return undefined} position=this.normalize(position);if(this._current!==position){var event=this.trigger('change',{property:{name:'position',value:position}});if(event.data!==undefined){position=this.normalize(event.data)} this._current=position;this.invalidate('position');this.trigger('changed',{property:{name:'position',value:this._current}})} return this._current};Owl.prototype.invalidate=function(part){if($.type(part)==='string'){this._invalidated[part]=!0;this.is('valid')&&this.leave('valid')} return $.map(this._invalidated,function(v,i){return i})};Owl.prototype.reset=function(position){position=this.normalize(position);if(position===undefined){return} this._speed=0;this._current=position;this.suppress(['translate','translated']);this.animate(this.coordinates(position));this.release(['translate','translated'])};Owl.prototype.normalize=function(position,relative){var n=this._items.length,m=relative?0:this._clones.length;if(!$.isNumeric(position)||n<1){position=undefined}else if(position<0||position>=n+m){position=((position-m/2)%n+n)%n+m/2} return position};Owl.prototype.relative=function(position){position-=this._clones.length/2;return this.normalize(position,!0)};Owl.prototype.maximum=function(relative){var settings=this.settings,maximum=this._coordinates.length,boundary=Math.abs(this._coordinates[maximum-1])-this._width,i=-1,j;if(settings.loop){maximum=this._clones.length/2+this._items.length-1}else if(settings.autoWidth||settings.merge){while(maximum-i>1){Math.abs(this._coordinates[j=maximum+i>>1])0)-(distance<0),items=this._items.length,minimum=this.minimum(),maximum=this.maximum();if(this.settings.loop){if(!this.settings.rewind&&Math.abs(distance)>items/2){distance+=direction*-1*items} position=current+distance;revert=((position-minimum)%items+items)%items+minimum;if(revert!==position&&revert-distance<=maximum&&revert-distance>0){current=revert-distance;position=revert;this.reset(current)}}else if(this.settings.rewind){maximum+=1;position=(position%maximum+maximum)%maximum}else{position=Math.max(minimum,Math.min(maximum,position))} this.speed(this.duration(current,position,speed));this.current(position);if(this.$element.is(':visible')){this.update()}};Owl.prototype.next=function(speed){speed=speed||!1;this.to(this.relative(this.current())+1,speed)};Owl.prototype.prev=function(speed){speed=speed||!1;this.to(this.relative(this.current())-1,speed)};Owl.prototype.onTransitionEnd=function(event){if(event!==undefined){event.stopPropagation();if((event.target||event.srcElement||event.originalTarget)!==this.$stage.get(0)){return!1}} this.leave('animating');this.trigger('translated')};Owl.prototype.viewport=function(){var width;if(this.options.responsiveBaseElement!==window){width=$(this.options.responsiveBaseElement).width()}else if(window.innerWidth){width=window.innerWidth}else if(document.documentElement&&document.documentElement.clientWidth){width=document.documentElement.clientWidth}else{throw 'Can not detect viewport width.'} return width};Owl.prototype.replace=function(content){this.$stage.empty();this._items=[];if(content){content=(content instanceof jQuery)?content:$(content)} if(this.settings.nestedItemSelector){content=content.find('.'+this.settings.nestedItemSelector)} content.filter(function(){return this.nodeType===1}).each($.proxy(function(index,item){item=this.prepare(item,index);this.$stage.append(item);this._items.push(item);this._mergers.push(item.find('[data-merge]').addBack('[data-merge]').attr('data-merge')*1||1)},this));this.reset($.isNumeric(this.settings.startPosition)?this.settings.startPosition:0);this.invalidate('items')};Owl.prototype.add=function(content,position){var current=this.relative(this._current);position=position===undefined?this._items.length:this.normalize(position,!0);content=content instanceof jQuery?content:$(content);this.trigger('add',{content:content,position:position});content=this.prepare(content,this._items[current].index());if(this._items.length===0||position===this._items.length){this._items.length===0&&this.$stage.append(content);this._items.length!==0&&this._items[position-1].after(content);this._items.push(content);this._mergers.push(content.find('[data-merge]').andSelf('[data-merge]').attr('data-merge')*1||1)}else{this._items[position].before(content);this._items.splice(position,0,content);this._mergers.splice(position,0,content.find('[data-merge]').andSelf('[data-merge]').attr('data-merge')*1||1)} this._items[current]&&this.reset(this._items[current].index());this.invalidate('items');this.trigger('added',{content:content,position:position})};Owl.prototype.remove=function(position){position=this.normalize(position,!0);if(position===undefined){return} this.trigger('remove',{content:this._items[position],position:position});this._items[position].remove();this._items.splice(position,1);this._mergers.splice(position,1);this.invalidate('items');this.trigger('removed',{content:null,position:position})};Owl.prototype.preloadAutoWidthImages=function(images){images.each($.proxy(function(i,element){this.enter('pre-loading');element=$(element);$(new Image()).one('load',$.proxy(function(e){element.attr('src',e.target.src);element.css('opacity',1);this.leave('pre-loading');!this.is('pre-loading')&&!this.is('initializing')&&this.refresh()},this)).attr('src',element.attr('src')||element.attr('data-src')||element.attr('data-src-retina'))},this))};Owl.prototype.destroy=function(){this.$element.off('.owl.core');this.$stage.off('.owl.core');$(document).off('.owl.core');if(this.settings.responsive!==!1){window.clearTimeout(this.resizeTimer);this.off(window,'resize',this._handlers.onThrottledResize)} for(var i in this._plugins){this._plugins[i].destroy()} this.$stage.children('.cloned').remove();this.$stage.unwrap();this.$stage.children().contents().unwrap();this.$stage.children().unwrap();this.$element.removeClass(this.options.refreshClass).removeClass(this.options.loadingClass).removeClass(this.options.loadedClass).removeClass(this.options.rtlClass).removeClass(this.options.dragClass).removeClass(this.options.grabClass).attr('class',this.$element.attr('class').replace(new RegExp(this.options.responsiveClass+'-\\S+\\s','g'),'')).removeData('owl.carousel')};Owl.prototype.op=function(a,o,b){var rtl=this.settings.rtl;switch(o){case '<':return rtl?a>b:a':return rtl?ab;case '>=':return rtl?a<=b:a>=b;case '<=':return rtl?a>=b:a<=b;default:break}};Owl.prototype.on=function(element,event,listener,capture){if(element.addEventListener){element.addEventListener(event,listener,capture)}else if(element.attachEvent){element.attachEvent('on'+event,listener)}};Owl.prototype.off=function(element,event,listener,capture){if(element.removeEventListener){element.removeEventListener(event,listener,capture)}else if(element.detachEvent){element.detachEvent('on'+event,listener)}};Owl.prototype.trigger=function(name,data,namespace,state,enter){var status={item:{count:this._items.length,index:this.current()}},handler=$.camelCase($.grep(['on',name,namespace],function(v){return v}).join('-').toLowerCase()),event=$.Event([name,'owl',namespace||'carousel'].join('.').toLowerCase(),$.extend({relatedTarget:this},status,data));if(!this._supress[name]){$.each(this._plugins,function(name,plugin){if(plugin.onTrigger){plugin.onTrigger(event)}});this.register({type:Owl.Type.Event,name:name});this.$element.trigger(event);if(this.settings&&typeof this.settings[handler]==='function'){this.settings[handler].call(this,event)}} return event};Owl.prototype.enter=function(name){$.each([name].concat(this._states.tags[name]||[]),$.proxy(function(i,name){if(this._states.current[name]===undefined){this._states.current[name]=0} this._states.current[name]++},this))};Owl.prototype.leave=function(name){$.each([name].concat(this._states.tags[name]||[]),$.proxy(function(i,name){this._states.current[name]--},this))};Owl.prototype.register=function(object){if(object.type===Owl.Type.Event){if(!$.event.special[object.name]){$.event.special[object.name]={}} if(!$.event.special[object.name].owl){var _default=$.event.special[object.name]._default;$.event.special[object.name]._default=function(e){if(_default&&_default.apply&&(!e.namespace||e.namespace.indexOf('owl')===-1)){return _default.apply(this,arguments)} return e.namespace&&e.namespace.indexOf('owl')>-1};$.event.special[object.name].owl=!0}}else if(object.type===Owl.Type.State){if(!this._states.tags[object.name]){this._states.tags[object.name]=object.tags}else{this._states.tags[object.name]=this._states.tags[object.name].concat(object.tags)} this._states.tags[object.name]=$.grep(this._states.tags[object.name],$.proxy(function(tag,i){return $.inArray(tag,this._states.tags[object.name])===i},this))}};Owl.prototype.suppress=function(events){$.each(events,$.proxy(function(index,event){this._supress[event]=!0},this))};Owl.prototype.release=function(events){$.each(events,$.proxy(function(index,event){delete this._supress[event]},this))};Owl.prototype.pointer=function(event){var result={x:null,y:null};event=event.originalEvent||event||window.event;event=event.touches&&event.touches.length?event.touches[0]:event.changedTouches&&event.changedTouches.length?event.changedTouches[0]:event;if(event.pageX){result.x=event.pageX;result.y=event.pageY}else{result.x=event.clientX;result.y=event.clientY} return result};Owl.prototype.difference=function(first,second){return{x:first.x-second.x,y:first.y-second.y}};$.fn.owlCarousel=function(option){var args=Array.prototype.slice.call(arguments,1);return this.each(function(){var $this=$(this),data=$this.data('owl.carousel');if(!data){data=new Owl(this,typeof option=='object'&&option);$this.data('owl.carousel',data);$.each(['next','prev','to','destroy','refresh','replace','add','remove'],function(i,event){data.register({type:Owl.Type.Event,name:event});data.$element.on(event+'.owl.carousel.core',$.proxy(function(e){if(e.namespace&&e.relatedTarget!==this){this.suppress([event]);data[event].apply(this,[].slice.call(arguments,1));this.release([event])}},data))})} if(typeof option=='string'&&option.charAt(0)!=='_'){data[option].apply(data,args)}})};$.fn.owlCarousel.Constructor=Owl})(window.Zepto||window.jQuery,window,document); /** * AutoRefresh Plugin * @version 2.0.0-beta.3 * @author Artus Kolanowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){var AutoRefresh=function(carousel){this._core=carousel;this._interval=null;this._visible=null;this._handlers={'initialized.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.autoRefresh){this.watch()}},this)};this._core.options=$.extend({},AutoRefresh.Defaults,this._core.options);this._core.$element.on(this._handlers)};AutoRefresh.Defaults={autoRefresh:!0,autoRefreshInterval:500};AutoRefresh.prototype.watch=function(){if(this._interval){return} this._visible=this._core.$element.is(':visible');this._interval=window.setInterval($.proxy(this.refresh,this),this._core.settings.autoRefreshInterval)};AutoRefresh.prototype.refresh=function(){if(this._core.$element.is(':visible')===this._visible){return} this._visible=!this._visible;this._core.$element.toggleClass('owl-hidden',!this._visible);this._visible&&(this._core.invalidate('width')&&this._core.refresh())};AutoRefresh.prototype.destroy=function(){var handler,property;window.clearInterval(this._interval);for(handler in this._handlers){this._core.$element.off(handler,this._handlers[handler])} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};$.fn.owlCarousel.Constructor.Plugins.AutoRefresh=AutoRefresh})(window.Zepto||window.jQuery,window,document); /** * Lazy Plugin * @version 2.0.0-beta.3 * @author Bartosz Wojciechowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){var Lazy=function(carousel){this._core=carousel;this._loaded=[];this._handlers={'initialized.owl.carousel change.owl.carousel':$.proxy(function(e){if(!e.namespace){return} if(!this._core.settings||!this._core.settings.lazyLoad){return} if((e.property&&e.property.name=='position')||e.type=='initialized'){var settings=this._core.settings,n=(settings.center&&Math.ceil(settings.items/2)||settings.items),i=((settings.center&&n*-1)||0),position=((e.property&&e.property.value)||this._core.current())+i,clones=this._core.clones().length,load=$.proxy(function(i,v){this.load(v)},this);while(i++-1){return} $elements.each($.proxy(function(index,element){var $element=$(element),image,url=(window.devicePixelRatio>1&&$element.attr('data-src-retina'))||$element.attr('data-src');this._core.trigger('load',{element:$element,url:url},'lazy');if($element.is('img')){$element.one('load.owl.lazy',$.proxy(function(){$element.css('opacity',1);this._core.trigger('loaded',{element:$element,url:url},'lazy')},this)).attr('src',url)}else{image=new Image();image.onload=$.proxy(function(){$element.css({'background-image':'url('+url+')','opacity':'1'});this._core.trigger('loaded',{element:$element,url:url},'lazy')},this);image.src=url}},this));this._loaded.push($item.get(0))} Lazy.prototype.destroy=function(){var handler,property;for(handler in this.handlers){this._core.$element.off(handler,this.handlers[handler])} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};$.fn.owlCarousel.Constructor.Plugins.Lazy=Lazy})(window.Zepto||window.jQuery,window,document); /** * AutoHeight Plugin * @version 2.0.0-beta.3 * @author Bartosz Wojciechowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){var AutoHeight=function(carousel){this._core=carousel;this._handlers={'initialized.owl.carousel refreshed.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.autoHeight){this.update()}},this),'changed.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.autoHeight&&e.property.name=='position'){this.update()}},this),'loaded.owl.lazy':$.proxy(function(e){if(e.namespace&&this._core.settings.autoHeight&&e.element.closest('.'+this._core.settings.itemClass).index()===this._core.current()){this.update()}},this)};this._core.options=$.extend({},AutoHeight.Defaults,this._core.options);this._core.$element.on(this._handlers)};AutoHeight.Defaults={autoHeight:!1,autoHeightClass:'owl-height'};AutoHeight.prototype.update=function(){var start=this._core._current,end=start+this._core.settings.items,visible=this._core.$stage.children().toArray().slice(start,end);heights=[],maxheight=0;$.each(visible,function(index,item){heights.push($(item).height())});maxheight=Math.max.apply(null,heights);this._core.$stage.parent().height(maxheight).addClass(this._core.settings.autoHeightClass)};AutoHeight.prototype.destroy=function(){var handler,property;for(handler in this._handlers){this._core.$element.off(handler,this._handlers[handler])} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};$.fn.owlCarousel.Constructor.Plugins.AutoHeight=AutoHeight})(window.Zepto||window.jQuery,window,document); /** * Video Plugin * @version 2.0.0-beta.3 * @author Bartosz Wojciechowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){var Video=function(carousel){this._core=carousel;this._videos={};this._playing=null;this._handlers={'initialized.owl.carousel':$.proxy(function(e){if(e.namespace){this._core.register({type:'state',name:'playing',tags:['interacting']})}},this),'resize.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.video&&this.isInFullScreen()){e.preventDefault()}},this),'refreshed.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.is('resizing')){this._core.$stage.find('.cloned .owl-video-frame').remove()}},this),'changed.owl.carousel':$.proxy(function(e){if(e.namespace&&e.property.name==='position'&&this._playing){this.stop()}},this),'prepared.owl.carousel':$.proxy(function(e){if(!e.namespace){return} var $element=$(e.content).find('.owl-video');if($element.length){$element.css('display','none');this.fetch($element,$(e.content))}},this)};this._core.options=$.extend({},Video.Defaults,this._core.options);this._core.$element.on(this._handlers);this._core.$element.on('click.owl.video','.owl-video-play-icon',$.proxy(function(e){this.play(e)},this))};Video.Defaults={video:!1,videoHeight:!1,videoWidth:!1};Video.prototype.fetch=function(target,item){var type=target.attr('data-vimeo-id')?'vimeo':'youtube',id=target.attr('data-vimeo-id')||target.attr('data-youtube-id'),width=target.attr('data-width')||this._core.settings.videoWidth,height=target.attr('data-height')||this._core.settings.videoHeight,url=target.attr('href');if(url){id=url.match(/(http:|https:|)\/\/(player.|www.)?(vimeo\.com|youtu(be\.com|\.be|be\.googleapis\.com))\/(video\/|embed\/|watch\?v=|v\/)?([A-Za-z0-9._%-]*)(\&\S+)?/);if(id[3].indexOf('youtu')>-1){type='youtube'}else if(id[3].indexOf('vimeo')>-1){type='vimeo'}else{throw new Error('Video URL not supported.')} id=id[6]}else{throw new Error('Missing video URL.')} this._videos[url]={type:type,id:id,width:width,height:height};item.attr('data-video',url);this.thumbnail(target,this._videos[url])};Video.prototype.thumbnail=function(target,video){var tnLink,icon,path,dimensions=video.width&&video.height?'style="width:'+video.width+'px;height:'+video.height+'px;"':'',customTn=target.find('img'),srcType='src',lazyClass='',settings=this._core.settings,create=function(path){icon='
';if(settings.lazyLoad){tnLink='
'}else{tnLink='
'} target.after(tnLink);target.after(icon)};target.wrap('
');if(this._core.settings.lazyLoad){srcType='data-src';lazyClass='owl-lazy'} if(customTn.length){create(customTn.attr(srcType));customTn.remove();return!1} if(video.type==='youtube'){path="//img.youtube.com/vi/"+video.id+"/hqdefault.jpg";create(path)}else if(video.type==='vimeo'){$.ajax({type:'GET',url:'//vimeo.com/api/v2/video/'+video.id+'.json',jsonp:'callback',dataType:'jsonp',success:function(data){path=data[0].thumbnail_large;create(path)}})}};Video.prototype.stop=function(){this._core.trigger('stop',null,'video');this._playing.find('.owl-video-frame').remove();this._playing.removeClass('owl-video-playing');this._playing=null;this._core.leave('playing');this._core.trigger('stopped',null,'video')};Video.prototype.play=function(event){var target=$(event.target),item=target.closest('.'+this._core.settings.itemClass),video=this._videos[item.attr('data-video')],width=video.width||'100%',height=video.height||this._core.$stage.height(),html;if(this._playing){return} this._core.enter('playing');this._core.trigger('play',null,'video');item=this._core.items(this._core.relative(item.index()));this._core.reset(item.index());if(video.type==='youtube'){html=''}else if(video.type==='vimeo'){html=''} $('
'+html+'
').insertAfter(item.find('.owl-video'));this._playing=item.addClass('owl-video-playing')};Video.prototype.isInFullScreen=function(){var element=document.fullscreenElement||document.mozFullScreenElement||document.webkitFullscreenElement;return element&&$(element).parent().hasClass('owl-video-frame')};Video.prototype.destroy=function(){var handler,property;this._core.$element.off('click.owl.video');for(handler in this._handlers){this._core.$element.off(handler,this._handlers[handler])} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};$.fn.owlCarousel.Constructor.Plugins.Video=Video})(window.Zepto||window.jQuery,window,document); /** * Animate Plugin * @version 2.0.0-beta.3 * @author Bartosz Wojciechowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){var Animate=function(scope){this.core=scope;this.core.options=$.extend({},Animate.Defaults,this.core.options);this.swapping=!0;this.previous=undefined;this.next=undefined;this.handlers={'change.owl.carousel':$.proxy(function(e){if(e.namespace&&e.property.name=='position'){this.previous=this.core.current();this.next=e.property.value}},this),'drag.owl.carousel dragged.owl.carousel translated.owl.carousel':$.proxy(function(e){if(e.namespace){this.swapping=e.type=='translated'}},this),'translate.owl.carousel':$.proxy(function(e){if(e.namespace&&this.swapping&&(this.core.options.animateOut||this.core.options.animateIn)){this.swap()}},this)};this.core.$element.on(this.handlers)};Animate.Defaults={animateOut:!1,animateIn:!1};Animate.prototype.swap=function(){if(this.core.settings.items!==1){return} if(!$.support.animation||!$.support.transition){return} this.core.speed(0);var left,clear=$.proxy(this.clear,this),previous=this.core.$stage.children().eq(this.previous),next=this.core.$stage.children().eq(this.next),incoming=this.core.settings.animateIn,outgoing=this.core.settings.animateOut;if(this.core.current()===this.previous){return} if(outgoing){left=this.core.coordinates(this.previous)-this.core.coordinates(this.next);previous.css({'left':left+'px'}).addClass('animated owl-animated-out').addClass(outgoing).on($.support.animation.end,clear)} if(incoming){next.addClass('animated owl-animated-in').addClass(incoming).on($.support.animation.end,clear)}};Animate.prototype.clear=function(e){if($(e.target).hasClass('animated')){$(e.target).css({'left':''}).removeClass('animated owl-animated-out owl-animated-in').removeClass(this.core.settings.animateIn).removeClass(this.core.settings.animateOut);this.core.onTransitionEnd()}};Animate.prototype.destroy=function(){var handler,property;for(handler in this.handlers){this.core.$element.off(handler,this.handlers[handler])} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};$.fn.owlCarousel.Constructor.Plugins.Animate=Animate})(window.Zepto||window.jQuery,window,document); /** * Autoplay Plugin * @version 2.0.0-beta.3 * @author Bartosz Wojciechowski * @author Artus Kolanowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){var Autoplay=function(carousel){this._core=carousel;this._interval=null;this._paused=!1;this._handlers={'changed.owl.carousel':$.proxy(function(e){if(e.namespace&&e.property.name==='settings'){if(this._core.settings.autoplay){this.play()}else{this.stop()}}},this),'initialized.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.autoplay){this.play()}},this),'play.owl.autoplay':$.proxy(function(e,t,s){if(e.namespace){this.play(t,s)}},this),'stop.owl.autoplay':$.proxy(function(e){if(e.namespace){this.stop()}},this),'mouseover.owl.autoplay':$.proxy(function(){if(this._core.settings.autoplayHoverPause&&this._core.is('rotating')){this.pause()}},this),'mouseleave.owl.autoplay':$.proxy(function(){if(this._core.settings.autoplayHoverPause&&this._core.is('rotating')){this.play()}},this)};this._core.$element.on(this._handlers);this._core.options=$.extend({},Autoplay.Defaults,this._core.options)};Autoplay.Defaults={autoplay:!1,autoplayTimeout:5000,autoplayHoverPause:!1,autoplaySpeed:!1};Autoplay.prototype.play=function(timeout,speed){this._paused=!1;if(this._core.is('rotating')){return} this._core.enter('rotating');this._interval=window.setInterval($.proxy(function(){if(this._paused||this._core.is('busy')||this._core.is('interacting')||document.hidden){return} this._core.next(speed||this._core.settings.autoplaySpeed)},this),timeout||this._core.settings.autoplayTimeout)};Autoplay.prototype.stop=function(){if(!this._core.is('rotating')){return} window.clearInterval(this._interval);this._core.leave('rotating')};Autoplay.prototype.pause=function(){if(!this._core.is('rotating')){return} this._paused=!0};Autoplay.prototype.destroy=function(){var handler,property;this.stop();for(handler in this._handlers){this._core.$element.off(handler,this._handlers[handler])} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};$.fn.owlCarousel.Constructor.Plugins.autoplay=Autoplay})(window.Zepto||window.jQuery,window,document); /** * Navigation Plugin * @version 2.0.0-beta.3 * @author Artus Kolanowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){'use strict';var Navigation=function(carousel){this._core=carousel;this._initialized=!1;this._pages=[];this._controls={};this._templates=[];this.$element=this._core.$element;this._overrides={next:this._core.next,prev:this._core.prev,to:this._core.to};this._handlers={'prepared.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.dotsData){this._templates.push('
'+$(e.content).find('[data-dot]').andSelf('[data-dot]').attr('data-dot')+'
')}},this),'added.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.dotsData){this._templates.splice(e.position,0,this._templates.pop())}},this),'remove.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.dotsData){this._templates.splice(e.position,1)}},this),'changed.owl.carousel':$.proxy(function(e){if(e.namespace&&e.property.name=='position'){this.draw()}},this),'initialized.owl.carousel':$.proxy(function(e){if(e.namespace&&!this._initialized){this._core.trigger('initialize',null,'navigation');this.initialize();this.update();this.draw();this._initialized=!0;this._core.trigger('initialized',null,'navigation')}},this),'refreshed.owl.carousel':$.proxy(function(e){if(e.namespace&&this._initialized){this._core.trigger('refresh',null,'navigation');this.update();this.draw();this._core.trigger('refreshed',null,'navigation')}},this)};this._core.options=$.extend({},Navigation.Defaults,this._core.options);this.$element.on(this._handlers)};Navigation.Defaults={nav:!1,navText:['prev','next'],navSpeed:!1,navElement:'div',navContainer:!1,navContainerClass:'owl-nav',navClass:['owl-prev','owl-next'],slideBy:1,dotClass:'owl-dot',dotsClass:'owl-dots',dots:!0,dotsEach:!1,dotsData:!1,dotsSpeed:!1,dotsContainer:!1};Navigation.prototype.initialize=function(){var override,settings=this._core.settings;this._controls.$relative=(settings.navContainer?$(settings.navContainer):$('
').addClass(settings.navContainerClass).appendTo(this.$element)).addClass('disabled');this._controls.$previous=$('<'+settings.navElement+'>').addClass(settings.navClass[0]).html(settings.navText[0]).prependTo(this._controls.$relative).on('click',$.proxy(function(e){this.prev(settings.navSpeed)},this));this._controls.$next=$('<'+settings.navElement+'>').addClass(settings.navClass[1]).html(settings.navText[1]).appendTo(this._controls.$relative).on('click',$.proxy(function(e){this.next(settings.navSpeed)},this));if(!settings.dotsData){this._templates=[$('
').addClass(settings.dotClass).append($('')).prop('outerHTML')]} this._controls.$absolute=(settings.dotsContainer?$(settings.dotsContainer):$('
').addClass(settings.dotsClass).appendTo(this.$element)).addClass('disabled');this._controls.$absolute.on('click','div',$.proxy(function(e){var index=$(e.target).parent().is(this._controls.$absolute)?$(e.target).index():$(e.target).parent().index();e.preventDefault();this.to(index,settings.dotsSpeed)},this));for(override in this._overrides){this._core[override]=$.proxy(this[override],this)}};Navigation.prototype.destroy=function(){var handler,control,property,override;for(handler in this._handlers){this.$element.off(handler,this._handlers[handler])} for(control in this._controls){this._controls[control].remove()} for(override in this.overides){this._core[override]=this._overrides[override]} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};Navigation.prototype.update=function(){var i,j,k,lower=this._core.clones().length/2,upper=lower+this._core.items().length,maximum=this._core.maximum(!0),settings=this._core.settings,size=settings.center||settings.autoWidth||settings.dotsData?1:settings.dotsEach||settings.items;if(settings.slideBy!=='page'){settings.slideBy=Math.min(settings.slideBy,settings.items)} if(settings.dots||settings.slideBy=='page'){this._pages=[];for(i=lower,j=0,k=0;i=size||j===0){this._pages.push({start:Math.min(maximum,i-lower),end:i-lower+size-1});if(Math.min(maximum,i-lower)===maximum){break} j=0,++k} j+=this._core.mergers(this._core.relative(i))}}};Navigation.prototype.draw=function(){var difference,settings=this._core.settings,disabled=this._core.items().length<=settings.items,index=this._core.relative(this._core.current()),loop=settings.loop||settings.rewind;this._controls.$relative.toggleClass('disabled',!settings.nav||disabled);if(settings.nav){this._controls.$previous.toggleClass('disabled',!loop&&index<=this._core.minimum(!0));this._controls.$next.toggleClass('disabled',!loop&&index>=this._core.maximum(!0))} this._controls.$absolute.toggleClass('disabled',!settings.dots||disabled);if(settings.dots){difference=this._pages.length-this._controls.$absolute.children().length;if(settings.dotsData&&difference!==0){this._controls.$absolute.html(this._templates.join(''))}else if(difference>0){this._controls.$absolute.append(new Array(difference+1).join(this._templates[0]))}else if(difference<0){this._controls.$absolute.children().slice(difference).remove()} this._controls.$absolute.find('.active').removeClass('active');this._controls.$absolute.children().eq($.inArray(this.current(),this._pages)).addClass('active')}};Navigation.prototype.onTrigger=function(event){var settings=this._core.settings;event.page={index:$.inArray(this.current(),this._pages),count:this._pages.length,size:settings&&(settings.center||settings.autoWidth||settings.dotsData?1:settings.dotsEach||settings.items)}};Navigation.prototype.current=function(){var current=this._core.relative(this._core.current());return $.grep(this._pages,$.proxy(function(page,index){return page.start<=current&&page.end>=current},this)).pop()};Navigation.prototype.getPosition=function(successor){var position,length,settings=this._core.settings;if(settings.slideBy=='page'){position=$.inArray(this.current(),this._pages);length=this._pages.length;successor?++position:--position;position=this._pages[((position%length)+length)%length].start}else{position=this._core.relative(this._core.current());length=this._core.items().length;successor?position+=settings.slideBy:position-=settings.slideBy} return position};Navigation.prototype.next=function(speed){$.proxy(this._overrides.to,this._core)(this.getPosition(!0),speed)};Navigation.prototype.prev=function(speed){$.proxy(this._overrides.to,this._core)(this.getPosition(!1),speed)};Navigation.prototype.to=function(position,speed,standard){var length;if(!standard){length=this._pages.length;$.proxy(this._overrides.to,this._core)(this._pages[((position%length)+length)%length].start,speed)}else{$.proxy(this._overrides.to,this._core)(position,speed)}};$.fn.owlCarousel.Constructor.Plugins.Navigation=Navigation})(window.Zepto||window.jQuery,window,document); /** * Hash Plugin * @version 2.0.0-beta.3 * @author Artus Kolanowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){'use strict';var Hash=function(carousel){this._core=carousel;this._hashes={};this.$element=this._core.$element;this._handlers={'initialized.owl.carousel':$.proxy(function(e){if(e.namespace&&this._core.settings.startPosition==='URLHash'){$(window).trigger('hashchange.owl.navigation')}},this),'prepared.owl.carousel':$.proxy(function(e){if(e.namespace){var hash=$(e.content).find('[data-hash]').addBack('[data-hash]').attr('data-hash');if(!hash){return} this._hashes[hash]=e.content}},this),'changed.owl.carousel':$.proxy(function(e){if(e.namespace&&e.property.name==='position'){var current=this._core.items(this._core.relative(this._core.current())),hash=$.map(this._hashes,function(item,hash){return item===current?hash:null}).join();if(!hash||window.location.hash.slice(1)===hash){return} window.location.hash=hash}},this)};this._core.options=$.extend({},Hash.Defaults,this._core.options);this.$element.on(this._handlers)};Hash.Defaults={URLhashListener:!1};Hash.prototype.destroy=function(){var handler,property;$(window).off('hashchange.owl.navigation');for(handler in this._handlers){this._core.$element.off(handler,this._handlers[handler])} for(property in Object.getOwnPropertyNames(this)){typeof this[property]!='function'&&(this[property]=null)}};$.fn.owlCarousel.Constructor.Plugins.Hash=Hash})(window.Zepto||window.jQuery,window,document); /** * Support Plugin * * @version 2.0.0-beta.3 * @author Vivid Planet Software GmbH * @author Artus Kolanowski * @license The MIT License (MIT) */ ;(function($,window,document,undefined){var style=$('').get(0).style,prefixes='Webkit Moz O ms'.split(' '),events={transition:{end:{WebkitTransition:'webkitTransitionEnd',MozTransition:'transitionend',OTransition:'oTransitionEnd',transition:'transitionend'}},animation:{end:{WebkitAnimation:'webkitAnimationEnd',MozAnimation:'animationend',OAnimation:'oAnimationEnd',animation:'animationend'}}},tests={csstransforms:function(){return!!test('transform')},csstransforms3d:function(){return!!test('perspective')},csstransitions:function(){return!!test('transition')},cssanimations:function(){return!!test('animation')}};function test(property,prefixed){var result=!1,upper=property.charAt(0).toUpperCase()+property.slice(1);$.each((property+' '+prefixes.join(upper+' ')+upper).split(' '),function(i,property){if(style[property]!==undefined){result=prefixed?property:!0;return!1}});return result} function prefixed(property){return test(property,!0)} if(tests.csstransitions()){$.support.transition=new String(prefixed('transition')) $.support.transition.end=events.transition.end[$.support.transition]} if(tests.cssanimations()){$.support.animation=new String(prefixed('animation')) $.support.animation.end=events.animation.end[$.support.animation]} if(tests.csstransforms()){$.support.transform=new String(prefixed('transform'));$.support.transform3d=tests.csstransforms3d()}})(window.Zepto||window.jQuery,window,document);(function(window,document,undefined){var absPos=function(element){var offsetLeft,offsetTop;offsetLeft=offsetTop=0;if(element.offsetParent){do{offsetLeft+=element.offsetLeft;offsetTop+=element.offsetTop}while(element=element.offsetParent);} return[offsetLeft,offsetTop]};var ProgressCircle=function(params){this.canvas=params.canvas;this.minRadius=params.minRadius||15;this.arcWidth=params.arcWidth||5;this.gapWidth=params.gapWidth||3;this.centerX=params.centerX||this.canvas.width/2;this.centerY=params.centerY||this.canvas.height/2;this.infoLineLength=params.infoLineLength||60;this.horizLineLength=params.horizLineLength||10;this.infoLineAngleInterval=params.infoLineAngleInterval||Math.PI/8;this.infoLineBaseAngle=params.infoLineBaseAngle||Math.PI/6;this.context=this.canvas.getContext('2d');this.width=this.canvas.width;this.height=this.canvas.height;this.circles=[];this.runningCount=0};ProgressCircle.prototype={constructor:ProgressCircle,addEntry:function(params){this.circles.push(new Circle({canvas:this.canvas,context:this.context,centerX:this.centerX,centerY:this.centerY,innerRadius:this.minRadius+this.circles.length*(this.gapWidth+this.arcWidth),arcWidth:this.arcWidth,infoLineLength:this.infoLineLength,horizLineLength:this.horizLineLength,id:this.circles.length,fillColor:params.fillColor,outlineColor:params.outlineColor,progressListener:params.progressListener,infoListener:params.infoListener,infoLineAngle:this.infoLineBaseAngle+this.circles.length*this.infoLineAngleInterval,}));return this},start:function(interval){var self=this;this.timer=setInterval(function(){self._update()},interval||33);return this},stop:function(){clearTimeout(this.timer)},_update:function(){this._clear();this.circles.forEach(function(circle,idx,array){circle.update()});return this},_clear:function(){this.context.clearRect(0,0,this.canvas.width,this.canvas.height);return this},};var Circle=function(params){this.id=params.id;this.canvas=params.canvas;this.context=params.context;this.centerX=params.centerX;this.centerY=params.centerY;this.arcWidth=params.arcWidth;this.innerRadius=params.innerRadius||0;this.fillColor=params.fillColor||'#fff';this.outlineColor=params.outlineColor||this.fillColor;this.progressListener=params.progressListener;this.infoLineLength=params.infoLineLength||250;this.horizLineLength=params.horizLineLength||50;this.infoListener=params.infoListener;this.infoLineAngle=params.infoLineAngle;this.outerRadius=this.innerRadius+this.arcWidth;if(!this.infoListener)return;var angle=this.infoLineAngle,arcDistance=(this.innerRadius+this.outerRadius)/2,sinA=Math.sin(angle),cosA=Math.cos(angle);this.infoLineStartX=this.centerX+sinA*arcDistance;this.infoLineStartY=this.centerY-cosA*arcDistance;this.infoLineMidX=this.centerX+sinA*this.infoLineLength;this.infoLineMidY=this.centerY-cosA*this.infoLineLength;this.infoLineEndX=this.infoLineMidX+(sinA<0?-this.horizLineLength:this.horizLineLength);this.infoLineEndY=this.infoLineMidY;var infoText=document.createElement('div'),style=infoText.style;style.color=this.fillColor;style.position='absolute';style.left=this.infoLineEndX+absPos(this.canvas)[0]+'px';infoText.className='ProgressCircleInfo';infoText.id='progress_circle_info_'+this.id;document.body.appendChild(infoText);this.infoText=infoText};Circle.prototype={constructor:Circle,update:function(){this.progress=this.progressListener();this._draw();if(this.infoListener){this.info=this.infoListener();this._drawInfo()}},_draw:function(){var ctx=this.context,ANGLE_OFFSET=-Math.PI/2,startAngle=0+ANGLE_OFFSET,endAngle=startAngle+this.progress*Math.PI*2,x=this.centerX,y=this.centerY,innerRadius=this.innerRadius-this.arcWidth-1,outerRadius=this.outerRadius-this.arcWidth-1;if(innerRadius<0) return;ctx.fillStyle=this.fillColor;ctx.strokeStyle=this.outlineColor;ctx.beginPath();ctx.arc(x,y,innerRadius,startAngle,endAngle,!1);ctx.arc(x,y,outerRadius,endAngle,startAngle,!0);ctx.closePath();ctx.stroke();ctx.fill();return this},_drawInfo:function(){var pointList,lineHeight;pointList=[[this.infoLineStartX,this.infoLineStartY],[this.infoLineMidX,this.infoLineMidY],[this.infoLineEndX,this.infoLineEndY],];this._drawSegments(pointList,!1);this.infoText.innerHTML=this.info;lineHeight=this.infoText.offsetHeight;this.infoText.style.top=this.infoLineEndY+absPos(this.canvas)[1]-lineHeight/2+'px';return this},_drawSegments:function(pointList,close){var ctx=this.context;ctx.beginPath();ctx.moveTo(pointList[0][0],pointList[0][1]);for(var i=1;i=this.value){this.circle.stop();this.animated=!0;this.$label.html(this.label_value+this.options.units);return this._progress_v} this._progress_v+=0.01;if(!isNaN(this.label_value)){var label_value=this._progress_v/this.value*this.label_value;var val=Math.round(label_value)+this.options.units;this.$label.html(val)}else this.$label.html(this.label_value+this.options.units);return this._progress_v},animate:function(){if(this.animated!==!0){this.circle.addEntry({fillColor:this.color,progressListener:$.proxy(this.setProgress,this)}).start(10)}},setWayPoint:function(){if(typeof $.fn.waypoint!=='undefined'&&!UNCODE.isMobile){this.$el.waypoint($.proxy(this.animate,this),{offset:'85%'})}else{this.animate()}}};$.fn.vcChat=function(option,value){return this.each(function(){var $this=$(this),data=$this.data('vc_chart'),options=typeof option==='object'?option:{color:$this.data('pie-color'),units:$this.data('pie-units')};if(typeof option=='undefined')$this.data('vc_chart',(data=new VcChart(this,options)));if(typeof option=='string')data[option](value)})};if(typeof window.vc_pieChart!=='function'){window.vc_pieChart=function(){$('.vc_pie_chart:visible:not(.vc_ready)').vcChat()}} $(document).ready(function(){!window.vc_iframe&&vc_pieChart();$('.nav-tabs a').on('shown.bs.tab',function(e){var $cont=$(e.target).closest('.tab-container'),$active=$('.tab-pane.active',$cont);$('.vc_pie_chart:not(.vc_ready)',$active).vcChat()});$('.panel-collapse').on('shown.bs.collapse',function(e){$('.vc_pie_chart:not(.vc_ready)',e.target).vcChat()})})})(window.jQuery);function uncode_progress_bar(){jQuery.each(jQuery('.vc_progress_bar'),function(index,val){if(UNCODE.isUnmodalOpen&&!val.closest('#unmodal-content')){return} if(!UNCODE.isMobile){new Waypoint({context:UNCODE.isUnmodalOpen?document.getElementById('unmodal-content'):window,element:val,handler:function(){var element=jQuery(this.element);element.find('.vc_single_bar').each(function(index){var $this=jQuery(this),bar=$this.find('.vc_bar'),val=bar.data('percentage-value');setTimeout(function(){bar.css({"width":val+'%'})},index*200)})},offset:'80%'})}else{var element=jQuery(val);element.find('.vc_single_bar').each(function(index){var $this=jQuery(this),bar=$this.find('.vc_bar'),val=bar.data('percentage-value');setTimeout(function(){bar.css({"width":val+'%'})},index*200)})}})};uncode_progress_bar(); /*! * jquery.counterup.js 1.0 * * Copyright 2013, Benjamin Intal http://gambit.ph @bfintal * Released under the GPL v2 License * * Date: Nov 26, 2013 */ (function($){"use strict";$.fn.counterUp=function(options){var settings=$.extend({'time':400,'delay':10},options);return this.each(function(){var $this=$(this);var $settings=settings;var counterUpper=function(){var nums=[];var divisions=$settings.time/$settings.delay;var numReal=$this.attr('data-val'),num=numReal;var isComma=/[0-9]+,[0-9]+/.test(num);num=num.replace(/,/g,'');var isInt=/^[0-9]+$/.test(num);var isFloat=/^[0-9]+\.[0-9]+$/.test(num);var decimalPlaces=isFloat?(num.split('.')[1]||[]).length:0;for(var i=divisions;i>=1;i--){var newNum=parseInt(num/divisions*i);if(isFloat){newNum=parseFloat(num/divisions*i).toFixed(decimalPlaces)} if(isComma){while(/(\d+)(\d{3})/.test(newNum.toString())){newNum=newNum.toString().replace(/(\d+)(\d{3})/,'$1'+','+'$2')}} nums.unshift(newNum)} nums.push(numReal);$this.data('counterup-nums',nums);$this.text('0');var f=function(){if($this.data('counterup-nums')!=null){$this.text($this.data('counterup-nums').shift());if($this.data('counterup-nums').length){setTimeout($this.data('counterup-func'),$settings.delay)}else{delete $this.data('counterup-nums');$this.data('counterup-nums',null);$this.data('counterup-func',null)}}};$this.data('counterup-func',f);setTimeout($this.data('counterup-func'),$settings.delay)};new Waypoint({context:UNCODE.isUnmodalOpen?document.getElementById('unmodal-content'):window,element:this,handler:function(){counterUpper();if(!UNCODE.isUnmodalOpen){this.destroy()}},offset:'100%'})})}})(jQuery); /*! * The Final Countdown for jQuery v2.2.0 (http://hilios.github.io/jQuery.countdown/) * Copyright (c) 2016 Edson Hilios * * Permission is hereby granted, free of charge, to any person obtaining a copy of * this software and associated documentation files (the "Software"), to deal in * the Software without restriction, including without limitation the rights to * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of * the Software, and to permit persons to whom the Software is furnished to do so, * subject to the following conditions: * * The above copyright notice and this permission notice shall be included in all * copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ (function(factory){"use strict";if(typeof define==="function"&&define.amd){define(["jquery"],factory)}else{factory(jQuery)}})(function($){"use strict";var instances=[],matchers=[],defaultOptions={precision:100,elapse:!1,defer:!1};matchers.push(/^[0-9]*$/.source);matchers.push(/([0-9]{1,2}\/){2}[0-9]{4}( [0-9]{1,2}(:[0-9]{2}){2})?/.source);matchers.push(/[0-9]{4}([\/\-][0-9]{1,2}){2}( [0-9]{1,2}(:[0-9]{2}){2})?/.source);matchers=new RegExp(matchers.join("|"));function parseDateString(dateString){if(dateString instanceof Date){return dateString} if(String(dateString).match(matchers)){if(String(dateString).match(/^[0-9]*$/)){dateString=Number(dateString)} if(String(dateString).match(/\-/)){dateString=String(dateString).replace(/\-/g,"index.html")} return new Date(dateString)}else{throw new Error("Couldn't cast `"+dateString+"` to a date object.")}} var DIRECTIVE_KEY_MAP={Y:"years",m:"months",n:"daysToMonth",d:"daysToWeek",w:"weeks",W:"weeksToMonth",H:"hours",M:"minutes",S:"seconds",D:"totalDays",I:"totalHours",N:"totalMinutes",T:"totalSeconds"};function escapedRegExp(str){var sanitize=str.toString().replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1");return new RegExp(sanitize)} function strftime(offsetObject){return function(format){var directives=format.match(/%(-|!)?[A-Z]{1}(:[^;]+;)?/gi);if(directives){for(var i=0,len=directives.length;i1){return plural}else{return singular}} var Countdown=function(el,finalDate,options){this.el=el;this.$el=$(el);this.interval=null;this.offset={};this.options=$.extend({},defaultOptions);this.instanceNumber=instances.length;instances.push(this);this.$el.data("countdown-instance",this.instanceNumber);if(options){if(typeof options==="function"){this.$el.on("update.countdown",options);this.$el.on("stoped.countdown",options);this.$el.on("finish.countdown",options)}else{this.options=$.extend({},defaultOptions,options)}} this.setFinalDate(finalDate);if(this.options.defer===!1){this.start()}};$.extend(Countdown.prototype,{start:function(){if(this.interval!==null){clearInterval(this.interval)} var self=this;this.update();this.interval=setInterval(function(){self.update.call(self)},this.options.precision)},stop:function(){clearInterval(this.interval);this.interval=null;this.dispatchEvent("stoped")},toggle:function(){if(this.interval){this.stop()}else{this.start()}},pause:function(){this.stop()},resume:function(){this.start()},remove:function(){this.stop.call(this);instances[this.instanceNumber]=null;delete this.$el.data().countdownInstance},setFinalDate:function(value){this.finalDate=parseDateString(value)},update:function(){if(this.$el.closest("html").length===0){this.remove();return} var hasEventsAttached=$._data(this.el,"events")!==undefined,now=new Date(),newTotalSecsLeft;newTotalSecsLeft=this.finalDate.getTime()-now.getTime();newTotalSecsLeft=Math.ceil(newTotalSecsLeft/1e3);newTotalSecsLeft=!this.options.elapse&&newTotalSecsLeft<0?0:Math.abs(newTotalSecsLeft);if(this.totalSecsLeft===newTotalSecsLeft||!hasEventsAttached){return}else{this.totalSecsLeft=newTotalSecsLeft} this.elapsed=now>=this.finalDate;this.offset={seconds:this.totalSecsLeft%60,minutes:Math.floor(this.totalSecsLeft/60)%60,hours:Math.floor(this.totalSecsLeft/60/60)%24,days:Math.floor(this.totalSecsLeft/60/60/24)%7,daysToWeek:Math.floor(this.totalSecsLeft/60/60/24)%7,daysToMonth:Math.floor(this.totalSecsLeft/60/60/24%30.4368),weeks:Math.floor(this.totalSecsLeft/60/60/24/7),weeksToMonth:Math.floor(this.totalSecsLeft/60/60/24/7)%4,months:Math.floor(this.totalSecsLeft/60/60/24/30.4368),years:Math.abs(this.finalDate.getFullYear()-now.getFullYear()),totalDays:Math.floor(this.totalSecsLeft/60/60/24),totalHours:Math.floor(this.totalSecsLeft/60/60),totalMinutes:Math.floor(this.totalSecsLeft/60),totalSeconds:this.totalSecsLeft};if(!this.options.elapse&&this.totalSecsLeft===0){this.stop();this.dispatchEvent("finish")}else{this.dispatchEvent("update")}},dispatchEvent:function(eventName){var event=$.Event(eventName+".countdown");event.finalDate=this.finalDate;event.elapsed=this.elapsed;event.offset=$.extend({},this.offset);event.strftime=strftime(this.offset);this.$el.trigger(event)}});$.fn.countdown=function(){var argumentsArray=Array.prototype.slice.call(arguments,0);return this.each(function(){var instanceNumber=$(this).data("countdown-instance");if(instanceNumber!==undefined){var instance=instances[instanceNumber],method=argumentsArray[0];if(Countdown.prototype.hasOwnProperty(method)){instance[method].apply(instance,argumentsArray.slice(1))}else if(String(method).match(/^[$A-Z_][0-9A-Z_$]*$/i)===null){instance.setFinalDate.call(instance,method);instance.start()}else{$.error("Method %s does not exist on jQuery.countdown".replace(/\%s/gi,method))}}else{new Countdown(this,argumentsArray[0],argumentsArray[1])}})}});!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.Share=e()}}(function(){var define,module,exports;function getStyles(config){};var ShareUtils;if((!("classList" in document.documentElement))&&Object.defineProperty&&typeof HTMLElement!=="undefined"){Object.defineProperty(HTMLElement.prototype,"classList",{get:function(){var ret,self,update;update=function(fn){return function(value){var classes,index;classes=self.className.split(/\s+/);index=classes.indexOf(value);fn(classes,index,value);self.className=classes.join(" ")}};self=this;ret={add:update(function(classes,index,value){~index||classes.push(value)}),remove:update(function(classes,index){~index&&classes.splice(index,1)}),toggle:update(function(classes,index,value){if(~index){classes.splice(index,1)}else{classes.push(value)}}),contains:function(value){return!!~self.className.split(/\s+/).indexOf(value)},item:function(i){return self.className.split(/\s+/)[i]||null}};Object.defineProperty(ret,"length",{get:function(){return self.className.split(/\s+/).length}});return ret}})} String.prototype.to_rfc3986=function(){var tmp;tmp=encodeURIComponent(this);return tmp.replace(/[!'()*]/g,function(c){return"%"+c.charCodeAt(0).toString(16)})};ShareUtils=(function(){function ShareUtils(){} ShareUtils.prototype.extend=function(to,from,overwrite){var hasProp,prop;for(prop in from){hasProp=to[prop]!==undefined;if(hasProp&&typeof from[prop]==="object"){this.extend(to[prop],from[prop],overwrite)}else{if(overwrite||!hasProp){to[prop]=from[prop]}}}};ShareUtils.prototype.hide=function(el){return el.style.display="none"};ShareUtils.prototype.show=function(el){return el.style.display="block"};ShareUtils.prototype.has_class=function(el,class_name){return el.classList.contains(class_name)};ShareUtils.prototype.add_class=function(el,class_name){return el.classList.add(class_name)};ShareUtils.prototype.remove_class=function(el,class_name){return el.classList.remove(class_name)};ShareUtils.prototype.is_encoded=function(str){str=str.to_rfc3986();return decodeURIComponent(str)!==str};ShareUtils.prototype.encode=function(str){if(typeof str==="undefined"||this.is_encoded(str)){return str}else{return str.to_rfc3986()}};ShareUtils.prototype.popup=function(url,params){var k,popup,qs,v;if(params==null){params={}} popup={width:500,height:350};popup.top=(screen.height/2)-(popup.height/2);popup.left=(screen.width/2)-(popup.width/2);qs=((function(){var _results;_results=[];for(k in params){v=params[k];_results.push(""+k+"="+(this.encode(v)))} return _results}).call(this)).join('&');if(qs){qs="?"+qs} return window.open(url+qs,'targetWindow',"toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,left="+popup.left+",top="+popup.top+",width="+popup.width+",height="+popup.height)};return ShareUtils})();var Share,__hasProp={}.hasOwnProperty,__extends=function(child,parent){for(var key in parent){if(__hasProp.call(parent,key))child[key]=parent[key]}function ctor(){this.constructor=child}ctor.prototype=parent.prototype;child.prototype=new ctor();child.__super__=parent.prototype;return child};Share=(function(_super){__extends(Share,_super);function Share(element,options){this.element=element;this.el={head:document.getElementsByTagName('head')[0],body:document.getElementsByTagName('body')[0]};this.config={enabled_networks:0,protocol:['http','https'].indexOf(window.location.href.split(':')[0])===-1?'https://':'//',url:window.location.href.replace("&","%26"),caption:null,title:this.default_title(),image:this.default_image(),description:this.default_description(),ui:{flyout:'top center',button_text:'Share',button_font:!0,icon_font:!0},networks:{twitter:{enabled:!0,url:null,title:null,description:null},facebook:{enabled:!0,load_sdk:!0,url:null,app_id:null,title:null,caption:null,description:null,image:null},pinterest:{enabled:!0,url:null,image:null,description:null},reddit:{enabled:!0,url:null,title:null},linkedin:{enabled:!0,url:null,title:null,description:null},xing:{enabled:!0,url:null,title:null,image:null,description:null},whatsapp:{enabled:!0,title:null,url:null},email:{enabled:!0,title:null,description:null,url:null}}};this.setup(element,options);return this} Share.prototype.setup=function(element,opts){var index,instance,instances,_i,_len;instances=document.querySelectorAll(element);this.extend(this.config,opts,!0);this.set_global_configuration();this.normalize_network_configuration();if(this.config.ui.icon_font){this.inject_icons()} if(this.config.ui.button_font){this.inject_fonts()} if(this.config.networks.facebook.enabled&&this.config.networks.facebook.load_sdk){this.inject_facebook_sdk()} for(index=_i=0,_len=instances.length;_i<_len;index=++_i){instance=instances[index];this.setup_instance(element,index)}};Share.prototype.setup_instance=function(element,index){var button,instance,label,network,networks,_i,_len,_results,_this=this;instance=document.querySelectorAll(element)[index];this.hide(instance);this.add_class(instance,"sharer-"+index);instance=document.querySelectorAll(element)[index];this.inject_css(instance);this.inject_html(instance);this.show(instance);label=instance.getElementsByTagName("label")[0];button=instance.getElementsByClassName("social")[0];networks=instance.getElementsByTagName('li');this.add_class(button,"networks-"+this.config.enabled_networks);label.addEventListener("click",function(){return _this.event_toggle(button)});_this=this;_results=[];for(index=_i=0,_len=networks.length;_i<_len;index=++_i){network=networks[index];_results.push(network.addEventListener("click",function(){_this.event_network(instance,this);return _this.event_close(button)}))} return _results};Share.prototype.event_toggle=function(button){if(this.has_class(button,"active")){return this.event_close(button)}else{return this.event_open(button)}};Share.prototype.event_open=function(button){if(this.has_class(button,"load")){this.remove_class(button,"load")} return this.add_class(button,"active")};Share.prototype.event_close=function(button){return this.remove_class(button,"active")};Share.prototype.event_network=function(instance,network){var name;name=network.getAttribute("data-network");this.hook("before",name,instance);this["network_"+name]();return this.hook("after",name,instance)};Share.prototype.open=function(){return this["public"]("open")};Share.prototype.close=function(){return this["public"]("close")};Share.prototype.toggle=function(){return this["public"]("toggle")};Share.prototype["public"]=function(action){var button,index,instance,_i,_len,_ref,_results;_ref=document.querySelectorAll(this.element);_results=[];for(index=_i=0,_len=_ref.length;_i<_len;index=++_i){instance=_ref[index];button=instance.getElementsByClassName("social")[0];_results.push(this["event_"+action](button))} return _results};Share.prototype.network_facebook=function(){if(this.config.networks.facebook.load_sdk){if(!window.FB){return console.error("The Facebook JS SDK hasn't loaded yet.")} return FB.ui({method:'feed',name:this.config.networks.facebook.title,link:this.config.networks.facebook.url,picture:this.config.networks.facebook.image,caption:this.config.networks.facebook.caption,description:this.config.networks.facebook.description})}else{return this.popup('https://www.facebook.com/sharer/sharer.php',{u:this.config.networks.facebook.url})}};Share.prototype.network_twitter=function(){return this.popup('https://twitter.com/intent/tweet',{text:this.config.networks.twitter.title,url:this.config.networks.twitter.url})};Share.prototype.network_pinterest=function(){return this.popup('https://www.pinterest.com/pin/create/button',{url:this.config.networks.pinterest.url,media:this.config.networks.pinterest.image,description:this.config.networks.pinterest.description})};Share.prototype.network_linkedin=function(){return this.popup('https://www.linkedin.com/shareArticle',{url:this.config.networks.linkedin.url,title:this.config.networks.linkedin.title,summary:this.config.networks.linkedin.description})} Share.prototype.network_xing=function(){return this.popup('https://www.xing.com/spi/shares/new',{url:this.config.networks.xing.url,image:this.config.networks.xing.image,title:this.config.networks.xing.title,summary:this.config.networks.xing.description})} Share.prototype.network_whatsapp=function(){return this.popup('https://api.whatsapp.com/send',{text:this.config.networks.whatsapp.title+'%20'+this.config.networks.whatsapp.url,})} Share.prototype.network_email=function(){return this.popup('mailto:',{subject:this.config.networks.email.title,body:this.config.networks.email.url+'%0A%0A'+this.config.networks.email.description,})};Share.prototype.inject_icons=function(){};Share.prototype.inject_fonts=function(){};Share.prototype.inject_stylesheet=function(url){var link;if(!this.el.head.querySelector("link[href=\""+url+"\"]")){link=document.createElement("link");link.setAttribute("rel","stylesheet");link.setAttribute("href",url);return this.el.head.appendChild(link)}};Share.prototype.inject_css=function(instance){var css,meta,selector,style;selector="."+(instance.getAttribute('class').split(" ").join("."));if(!this.el.head.querySelector("meta[name='sharer"+selector+"']")){this.config.selector=selector;css=getStyles(this.config);style=document.createElement("style");style.type="text/css";if(style.styleSheet){style.styleSheet.cssText=css}else{style.appendChild(document.createTextNode(css))} this.el.head.appendChild(style);delete this.config.selector;meta=document.createElement("meta");meta.setAttribute("name","sharer"+selector);return this.el.head.appendChild(meta)}};Share.prototype.inject_html=function(instance){return instance.innerHTML=""};Share.prototype.inject_facebook_sdk=function(){var fb_root,script;if(!window.FB&&this.config.networks.facebook.app_id&&!this.el.body.querySelector('#fb-root')){script=document.createElement("script");script.text="window.fbAsyncInit=function(){FB.init({appId:'"+this.config.networks.facebook.app_id+"',status:true,xfbml:true})};(function(e,t,n){var r,i=e.getElementsByTagName(t)[0];if(e.getElementById(n)){return}r=e.createElement(t);r.id=n;r.src='"+this.config.protocol+"connect.facebook.net/en_US/all.js';i.parentNode.insertBefore(r,i)})(document,'script','facebook-jssdk')";fb_root=document.createElement("div");fb_root.id="fb-root";this.el.body.appendChild(fb_root);return this.el.body.appendChild(script)}};Share.prototype.hook=function(type,network,instance){var fn,opts;fn=this.config.networks[network][type];if(typeof fn==="function"){opts=fn.call(this.config.networks[network],instance);if(opts!==void 0){opts=this.normalize_filter_config_updates(opts);this.extend(this.config.networks[network],opts,!0);this.normalize_network_configuration()}}};Share.prototype.default_title=function(){var content;if(content=document.querySelector('meta[property="og:title"]')||document.querySelector('meta[name="twitter:title"]')){return encodeURIComponent(content.getAttribute('content'))}else if(content=document.querySelector('title')){return encodeURIComponent(content.innerText)}};Share.prototype.default_image=function(){var content;if(content=document.querySelector('meta[property="og:image"]')||document.querySelector('meta[name="twitter:image"]')){return content.getAttribute('content')}};Share.prototype.default_description=function(){var content;if(content=document.querySelector('meta[property="og:description"]')||document.querySelector('meta[name="twitter:description"]')||document.querySelector('meta[name="description"]')){return encodeURIComponent(content.getAttribute('content'))}else{return''}};Share.prototype.set_global_configuration=function(){var display,network,option,options,_ref,_results;_ref=this.config.networks;_results=[];for(network in _ref){options=_ref[network];for(option in options){if(this.config.networks[network][option]==null){this.config.networks[network][option]=this.config[option]}} if(this.config.networks[network].enabled){display='block';this.config.enabled_networks+=1}else{display='none'} _results.push(this.config.networks[network].display=display)} return _results};Share.prototype.normalize_network_configuration=function(){if(!this.config.networks.facebook.app_id){this.config.networks.facebook.load_sdk=!1} if(!this.is_encoded(this.config.networks.twitter.description)){this.config.networks.twitter.description=encodeURIComponent(this.config.networks.twitter.description)} if(typeof this.config.networks.facebook.app_id==='number'){return this.config.networks.facebook.app_id=this.config.networks.facebook.app_id.toString()}};Share.prototype.normalize_filter_config_updates=function(opts){if(this.config.networks.facebook.app_id!==opts.app_id){console.warn("You are unable to change the Facebook app_id after the button has been initialized. Please-in-out update your Facebook filters accordingly.");delete opts.app_id} if(this.config.networks.facebook.load_sdk!==opts.load_sdk){console.warn("You are unable to change the Facebook load_sdk option after the button has been initialized. Please-in-out update your Facebook filters accordingly.");delete opts.app_id} return opts};return Share})(ShareUtils);return Share});(function(){var $,win;$=this.jQuery||window.jQuery;win=$(window);$.fn.stick_in_parent=function(opts){var doc,elm,enable_bottoming,fn,i,inner_scrolling,len,manual_spacer,offset_top,outer_width,parent_selector,recalc_every,sticky_class;if(opts==null){opts={}} sticky_class=opts.sticky_class,inner_scrolling=opts.inner_scrolling,recalc_every=opts.recalc_every,parent_selector=opts.parent,offset_top=opts.offset_top,manual_spacer=opts.spacer,enable_bottoming=opts.bottoming;if(offset_top==null){offset_top=0} if(parent_selector==null){parent_selector=void 0} if(inner_scrolling==null){inner_scrolling=!0} if(sticky_class==null){sticky_class="is_stuck"} doc=$(document);if(enable_bottoming==null){enable_bottoming=!0} outer_width=function(el){var _el,computed,w;if(window.getComputedStyle){_el=el[0];computed=window.getComputedStyle(el[0]);w=parseFloat(computed.getPropertyValue("width"))+parseFloat(computed.getPropertyValue("margin-left"))+parseFloat(computed.getPropertyValue("margin-right"));if(computed.getPropertyValue("box-sizing")!=="border-box"){w+=parseFloat(computed.getPropertyValue("border-left-width"))+parseFloat(computed.getPropertyValue("border-right-width"))+parseFloat(computed.getPropertyValue("padding-left"))+parseFloat(computed.getPropertyValue("padding-right"))} return w}else{return el.outerWidth(!0)}};fn=function(elm,padding_bottom,parent_top,parent_height,top,height,el_float,detached){var bottomed,detach,fixed,last_pos,last_scroll_height,offset,parent,recalc,recalc_and_tick,recalc_counter,spacer,tick;if(elm.data("sticky_kit")){return} elm.data("sticky_kit",!0);last_scroll_height=doc.height();parent=elm.parent();if(parent_selector!=null){parent=parent.closest(parent_selector)} if(!parent.length){throw "failed to find stick parent"} fixed=!1;bottomed=!1;spacer=manual_spacer!=null?manual_spacer&&elm.closest(manual_spacer):$("
");if(spacer){spacer.css('position',elm.css('position'))} recalc=function(){var border_top,padding_top,restore;if(detached){return} last_scroll_height=doc.height();border_top=parseInt(parent.css("border-top-width"),10);padding_top=parseInt(parent.css("padding-top"),10);padding_bottom=parseInt(parent.css("padding-bottom"),10);parent_top=parent.offset().top+border_top+padding_top;parent_height=parent.height();if(fixed){fixed=!1;bottomed=!1;if(manual_spacer==null){elm.insertAfter(spacer);spacer.detach()} elm.css({position:"",top:"",width:"",bottom:""}).removeClass(sticky_class);restore=!0} top=elm.offset().top-(parseInt(elm.css("margin-top"),10)||0)-offset_top;height=elm.outerHeight(!0);el_float=elm.css("float");if(spacer){spacer.css({width:outer_width(elm),height:height,display:elm.css("display"),"vertical-align":elm.css("vertical-align"),"float":el_float})} if(restore){return tick()}};recalc();if(height===parent_height){return} last_pos=void 0;offset=offset_top;recalc_counter=recalc_every;tick=function(){var css,delta,recalced,scroll,will_bottom,win_height;if(detached){return} recalced=!1;if(recalc_counter!=null){recalc_counter-=1;if(recalc_counter<=0){recalc_counter=recalc_every;recalc();recalced=!0}} if(!recalced&&doc.height()!==last_scroll_height){recalc();recalced=!0} scroll=win.scrollTop();if(last_pos!=null){delta=scroll-last_pos} last_pos=scroll;if(fixed){if(enable_bottoming){will_bottom=scroll+height+offset>parent_height+parent_top;if(bottomed&&!will_bottom){bottomed=!1;elm.css({position:"fixed",bottom:"",top:offset}).trigger("sticky_kit:unbottom")}} if(scrollwin_height){if(!bottomed){offset-=delta;offset=Math.max(win_height-height,offset);offset=Math.min(offset_top,offset);if(fixed){elm.css({top:offset+"px"})}}}}}else{if(scroll>top){fixed=!0;css={position:"fixed",top:offset};css.width=elm.css("box-sizing")==="border-box"?elm.outerWidth()+"px":elm.width()+"px";elm.css(css).addClass(sticky_class);if(manual_spacer==null){elm.after(spacer);if(el_float==="left"||el_float==="right"){spacer.append(elm)}} elm.trigger("sticky_kit:stick")}} if(fixed&&enable_bottoming){if(will_bottom==null){will_bottom=scroll+height+offset>parent_height+parent_top} if(!bottomed&&will_bottom){bottomed=!0;if(parent.css("position")==="static"){parent.css({position:"relative"})} return elm.css({position:"absolute",bottom:padding_bottom,top:"auto"}).trigger("sticky_kit:bottom")}}};recalc_and_tick=function(){recalc();return tick()};detach=function(){detached=!0;win.off("touchmove",tick);win.off("scroll",tick);win.off("resize",recalc_and_tick);$(document.body).off("sticky_kit:recalc",recalc_and_tick);elm.off("sticky_kit:detach",detach);elm.removeData("sticky_kit");elm.css({position:"",bottom:"",top:"",width:""});parent.position("position","");if(fixed){if(manual_spacer==null){if(el_float==="left"||el_float==="right"){elm.insertAfter(spacer)} spacer.remove()} return elm.removeClass(sticky_class)}};win.on("touchmove",tick);win.on("scroll",tick);win.on("resize",recalc_and_tick);$(document.body).on("sticky_kit:recalc",recalc_and_tick);elm.on("sticky_kit:detach",detach);return setTimeout(tick,0)};for(i=0,len=this.length;i [data-tab-history], .panel-title.active [data-tab-history]').each(function(){var $activeTabElement=jQuery(this);var selector=getTabSelector($activeTabElement);if(selector){var tabGroup=getTabGroup($activeTabElement);if(tabGroup){newState=createNewHistoryState(newState||history.state,tabGroup,selector)}}});if(newState){history.replaceState(newState,'',null)}} function createNewHistoryState(existingState,tabGroup,selector){var newState=jQuery.extend(!0,{},existingState,{bootstrapTabHistory:{}});newState.bootstrapTabHistory[tabGroup]=selector;return newState} function getTabGroup($tab){return parseTruthyAttributeValue($tab.data('tab-history'))} function getTabSelector($tab){return $tab.data('target')||$tab.attr('href')} function onShownTab(shownEvt){if(!showingTabsBasedOnState){var $activatedTab=jQuery(shownEvt.target);if($activatedTab.hasClass('panel-collapse')) $activatedTab=$activatedTab.closest('.panel').find('a');var selector=getTabSelector($activatedTab);if(selector){var tabGroup=getTabGroup($activatedTab);if(tabGroup){var historyChanger=$activatedTab.data('tab-history-changer')||BootstrapTabHistory.options.defaultChanger;var newState=createNewHistoryState(history.state,tabGroup,selector);var updateURL=(function($activatedTab){if(selector[0]==='#'){var elementUpdateURLOption=parseTruthyAttributeValue($activatedTab.data('tab-history-update-url'));if(elementUpdateURLOption===undefined){return BootstrapTabHistory.options.defaultUpdateURL}else{return elementUpdateURLOption}}else{return!1}})($activatedTab);switch(historyChanger){case 'push':history.pushState(newState,'',updateURL?selector:null);break;case 'replace':history.replaceState(newState,'',updateURL?selector:null);break;default:throw new Error('Unknown tab-history-changer: '+historyChanger)}}}}} function onPopState(){var bootstrapTabHistory=history.state&&history.state.bootstrapTabHistory;if(bootstrapTabHistory){showTabsBasedOnState(bootstrapTabHistory)}} function parseTruthyAttributeValue(value){if(value){return value}else if(value===''){return!0}else{return value}} function showTabsBasedOnAnchor(){if(BootstrapTabHistory.options.showTabsBasedOnAnchor){var anchor=window.location&&window.location.hash;if(anchor){var $tabElement=showTabForSelector(anchor);if($tabElement&&window.addEventListener&&window.removeEventListener){var anchorYOffset=(function($tabElement){var elementSetting=$tabElement.data('tab-history-anchor-y-offset');if(elementSetting===undefined){return BootstrapTabHistory.options.defaultAnchorYOffset}else{return elementSetting}})($tabElement);if(anchorYOffset||anchorYOffset===0){var scrollListener=function resetAnchorScroll(){window.removeEventListener('scroll',scrollListener);window.scrollTo(0,anchorYOffset)};window.addEventListener('scroll',scrollListener)}}}}} function showTabForSelector(selector){var $tabElement=(function(selector){var $ret=null;jQuery('[data-toggle="tab"], [data-toggle="pill"], [data-toggle="collapse"]').each(function(){var $potentialTab=jQuery(this);if(($potentialTab.attr('href')===selector||$potentialTab.data('target')===selector)&&getTabGroup($potentialTab)){$ret=$potentialTab;return!1}else{return null}});return $ret})(selector);if($tabElement){if(!$tabElement.parent().hasClass('active')){$tabElement.trigger('click')}} return $tabElement} function showTabsBasedOnState(bootstrapTabHistory){showingTabsBasedOnState=!0;try{for(var k in bootstrapTabHistory){if(bootstrapTabHistory.hasOwnProperty(k)){showTabForSelector(bootstrapTabHistory[k])}}}finally{showingTabsBasedOnState=!1}}})(); /*! * justifiedGallery - v3.8.1 * http://miromannino.github.io/Justified-Gallery/ * Copyright (c) 2020 Miro Mannino * Licensed under the MIT license. */ (function(factory){if(typeof define==='function'&&define.amd){define(['jquery'],factory)}else if(typeof module==='object'&&module.exports){module.exports=function(root,jQuery){if(jQuery===undefined){if(typeof window!=='undefined'){jQuery=require('jquery')}else{jQuery=require('jquery')(root)}} factory(jQuery);return jQuery}}else{factory(jQuery)}}(function($){var JustifiedGallery=function($gallery,settings){this.settings=settings;this.checkSettings();this.imgAnalyzerTimeout=null;this.entries=null;this.buildingRow={entriesBuff:[],width:0,height:0,aspectRatio:0};this.lastFetchedEntry=null;this.lastAnalyzedIndex=-1;this.yield={every:2,flushed:0};this.border=settings.border>=0?settings.border:settings.margins;this.maxRowHeight=this.retrieveMaxRowHeight();this.suffixRanges=this.retrieveSuffixRanges();this.offY=this.border;this.rows=0;this.spinner={phase:0,timeSlot:150,$el:$('
'),intervalId:null};this.scrollBarOn=!1;this.checkWidthIntervalId=null;this.galleryWidth=$gallery.width();this.$gallery=$gallery};JustifiedGallery.prototype.getSuffix=function(width,height){var longestSide,i;longestSide=(width>height)?width:height;for(i=0;i .jg-caption');return $caption.length===0?null:$caption};JustifiedGallery.prototype.displayEntry=function($entry,x,y,imgWidth,imgHeight,rowHeight){$entry.width(imgWidth);$entry.height(Math.floor(rowHeight));$entry.css('top',Math.floor(y));$entry.css('left',x);var $image=this.imgFromEntry($entry);if($image!==null){$image.css('width',imgWidth);$image.css('height',imgHeight);$image.css('margin-left',-imgWidth/2);$image.css('margin-top',-imgHeight/2);var imageSrc=$image.data('jg-207.html');if(imageSrc){imageSrc=this.newSrc(imageSrc,imgWidth,imgHeight,$image[0]);$image.one('error',function(){this.resetImgSrc($image)});var loadNewImage=function(){$image.attr('src',imageSrc)};if($entry.data('jg.loaded')==='skipped'&&imageSrc){this.onImageEvent(imageSrc,(function(){this.showImg($entry,loadNewImage);$entry.data('jg.loaded',!0)}).bind(this))}else{this.showImg($entry,loadNewImage)}}}else{this.showImg($entry)} this.displayEntryCaption($entry)};JustifiedGallery.prototype.displayEntryCaption=function($entry){var $image=this.imgFromEntry($entry);if($image!==null&&this.settings.captions){var $imgCaption=this.captionFromEntry($entry);if($imgCaption===null){var caption=$image.attr('alt');if(!this.isValidCaption(caption))caption=$entry.attr('title');if(this.isValidCaption(caption)){$imgCaption=$('
'+caption+'
');$entry.append($imgCaption);$entry.data('jg.createdCaption',!0)}} if($imgCaption!==null){if(!this.settings.cssAnimation)$imgCaption.stop().fadeTo(0,this.settings.captionSettings.nonVisibleOpacity);this.addCaptionEventsHandlers($entry)}}else{this.removeCaptionEventsHandlers($entry)}};JustifiedGallery.prototype.isValidCaption=function(caption){return(typeof caption!=='undefined'&&caption.length>0)};JustifiedGallery.prototype.onEntryMouseEnterForCaption=function(eventObject){var $caption=this.captionFromEntry($(eventObject.currentTarget));if(this.settings.cssAnimation){$caption.addClass('jg-caption-visible').removeClass('jg-caption-hidden')}else{$caption.stop().fadeTo(this.settings.captionSettings.animationDuration,this.settings.captionSettings.visibleOpacity)}};JustifiedGallery.prototype.onEntryMouseLeaveForCaption=function(eventObject){var $caption=this.captionFromEntry($(eventObject.currentTarget));if(this.settings.cssAnimation){$caption.removeClass('jg-caption-visible').removeClass('jg-caption-hidden')}else{$caption.stop().fadeTo(this.settings.captionSettings.animationDuration,this.settings.captionSettings.nonVisibleOpacity)}};JustifiedGallery.prototype.addCaptionEventsHandlers=function($entry){var captionMouseEvents=$entry.data('jg.captionMouseEvents');if(typeof captionMouseEvents==='undefined'){captionMouseEvents={mouseenter:$.proxy(this.onEntryMouseEnterForCaption,this),mouseleave:$.proxy(this.onEntryMouseLeaveForCaption,this)};$entry.on('mouseenter',undefined,undefined,captionMouseEvents.mouseenter);$entry.on('mouseleave',undefined,undefined,captionMouseEvents.mouseleave);$entry.data('jg.captionMouseEvents',captionMouseEvents)}};JustifiedGallery.prototype.removeCaptionEventsHandlers=function($entry){var captionMouseEvents=$entry.data('jg.captionMouseEvents');if(typeof captionMouseEvents!=='undefined'){$entry.off('mouseenter',undefined,captionMouseEvents.mouseenter);$entry.off('mouseleave',undefined,captionMouseEvents.mouseleave);$entry.removeData('jg.captionMouseEvents')}};JustifiedGallery.prototype.clearBuildingRow=function(){this.buildingRow.entriesBuff=[];this.buildingRow.aspectRatio=0;this.buildingRow.width=0};JustifiedGallery.prototype.prepareBuildingRow=function(isLastRow,hiddenRow){var i,$entry,imgAspectRatio,newImgW,newImgH,justify=!0;var minHeight=0;var availableWidth=this.galleryWidth-2*this.border-((this.buildingRow.entriesBuff.length-1)*this.settings.margins);var rowHeight=Math.floor(availableWidth/this.buildingRow.aspectRatio);var defaultRowHeight=this.settings.rowHeight;var justifiable=this.buildingRow.width/availableWidth>this.settings.justifyThreshold;if(hiddenRow||(isLastRow&&this.settings.lastRow==='hide'&&!justifiable)){for(i=0;i img, > a > img').fadeTo(0,0)}} return-1} if(isLastRow&&!justifiable&&this.settings.lastRow!=='justify'&&this.settings.lastRow!=='hide'){justify=!1;if(this.rows>0){defaultRowHeight=(this.offY-this.border-this.settings.margins*this.rows)/this.rows;justify=defaultRowHeight*this.buildingRow.aspectRatio/availableWidth>this.settings.justifyThreshold}} for(i=0;inewImgH)minHeight=newImgH} this.buildingRow.height=minHeight;return justify};JustifiedGallery.prototype.flushRow=function(isLastRow,hiddenRow){var settings=this.settings;var $entry,buildingRowRes,offX=this.border,i;buildingRowRes=this.prepareBuildingRow(isLastRow,hiddenRow);if(hiddenRow||(isLastRow&&settings.lastRow==='hide'&&buildingRowRes===-1)){this.clearBuildingRow();return} if(this.maxRowHeight){if(this.maxRowHeightthis.settings.refreshSensitivity){this.galleryWidth=galleryWidth;this.rewind();this.rememberGalleryHeight();this.startImgAnalyzer(!0)}},this),this.settings.refreshTime)};JustifiedGallery.prototype.isSpinnerActive=function(){return this.spinner.intervalId!==null};JustifiedGallery.prototype.getSpinnerHeight=function(){return this.spinner.$el.innerHeight()};JustifiedGallery.prototype.stopLoadingSpinnerAnimation=function(){clearInterval(this.spinner.intervalId);this.spinner.intervalId=null;this.setGalleryTempHeight(this.$gallery.height()-this.getSpinnerHeight());this.spinner.$el.detach()};JustifiedGallery.prototype.startLoadingSpinnerAnimation=function(){var spinnerContext=this.spinner;var $spinnerPoints=spinnerContext.$el.find('span');clearInterval(spinnerContext.intervalId);this.$gallery.append(spinnerContext.$el);this.setGalleryTempHeight(this.offY+this.buildingRow.height+this.getSpinnerHeight());spinnerContext.intervalId=setInterval(function(){if(spinnerContext.phase<$spinnerPoints.length){$spinnerPoints.eq(spinnerContext.phase).fadeTo(spinnerContext.timeSlot,1)}else{$spinnerPoints.eq(spinnerContext.phase-$spinnerPoints.length).fadeTo(spinnerContext.timeSlot,0)} spinnerContext.phase=(spinnerContext.phase+1)%($spinnerPoints.length*2)},spinnerContext.timeSlot)};JustifiedGallery.prototype.rewind=function(){this.lastFetchedEntry=null;this.lastAnalyzedIndex=-1;this.offY=this.border;this.rows=0;this.clearBuildingRow()};JustifiedGallery.prototype.getSelectorWithoutSpinner=function(){return this.settings.selector+', div:not(.jg-spinner)'};JustifiedGallery.prototype.getAllEntries=function(){var selector=this.getSelectorWithoutSpinner();return this.$gallery.children(selector).toArray()};JustifiedGallery.prototype.updateEntries=function(norewind){var newEntries;if(norewind&&this.lastFetchedEntry!=null){var selector=this.getSelectorWithoutSpinner();newEntries=$(this.lastFetchedEntry).nextAll(selector).toArray()}else{this.entries=[];newEntries=this.getAllEntries()} if(newEntries.length>0){if($.isFunction(this.settings.sort)){newEntries=this.sortArray(newEntries)}else if(this.settings.randomize){newEntries=this.shuffleArray(newEntries)} this.lastFetchedEntry=newEntries[newEntries.length-1];if(this.settings.filter){newEntries=this.filterArray(newEntries)}else{this.resetFilters(newEntries)}} this.entries=this.entries.concat(newEntries);return!0};JustifiedGallery.prototype.insertToGallery=function(entries){var that=this;$.each(entries,function(){$(this).appendTo(that.$gallery)})};JustifiedGallery.prototype.shuffleArray=function(a){var i,j,temp;for(i=a.length-1;i>0;i--){j=Math.floor(Math.random()*(i+1));temp=a[i];a[i]=a[j];a[j]=temp} this.insertToGallery(a);return a};JustifiedGallery.prototype.sortArray=function(a){a.sort(this.settings.sort);this.insertToGallery(a);return a};JustifiedGallery.prototype.resetFilters=function(a){for(var i=0;i0&&this.rows===this.settings.maxRowsCount);if(++this.yield.flushed>=this.yield.every){this.startImgAnalyzer(isForResize);return}}}else if($entry.data('jg.loaded')!=='error'){return}} if(this.buildingRow.entriesBuff.length>0){this.flushRow(!0,this.settings.maxRowsCount>0&&this.rows===this.settings.maxRowsCount)} if(this.isSpinnerActive()){this.stopLoadingSpinnerAnimation()} this.stopImgAnalyzerStarter();this.setGalleryFinalHeight(this.galleryHeightToSet);this.settings.triggerEvent.call(this,isForResize?'jg.resize':'jg.complete')};JustifiedGallery.prototype.stopImgAnalyzerStarter=function(){this.yield.flushed=0;if(this.imgAnalyzerTimeout!==null){clearTimeout(this.imgAnalyzerTimeout);this.imgAnalyzerTimeout=null}};JustifiedGallery.prototype.startImgAnalyzer=function(isForResize){var that=this;this.stopImgAnalyzerStarter();this.imgAnalyzerTimeout=setTimeout(function(){that.analyzeImages(isForResize)},0.001)};JustifiedGallery.prototype.onImageEvent=function(imageSrc,onLoad,onError){if(!onLoad&&!onError)return;var memImage=new Image();var $memImage=$(memImage);if(onLoad){$memImage.one('load',function(){$memImage.off('load error');onLoad(memImage)})} if(onError){$memImage.one('error',function(){$memImage.off('load error');onError(memImage)})} memImage.src=imageSrc};JustifiedGallery.prototype.init=function(){var imagesToLoad=!1,skippedImages=!1,that=this;$.each(this.entries,function(index,entry){var $entry=$(entry);var $image=that.imgFromEntry($entry);$entry.addClass('jg-entry');if($entry.data('jg.loaded')!==!0&&$entry.data('jg.loaded')!=='skipped'){if(that.settings.rel!==null)$entry.attr('rel',that.settings.rel);if(that.settings.target!==null)$entry.attr('target',that.settings.target);if($image!==null){var imageSrc=that.extractImgSrcFromImage($image);if(that.settings.waitThumbnailsLoad===!1||!imageSrc){var width=parseFloat($image.attr('width'));var height=parseFloat($image.attr('height'));if($image.prop('tagName')==='svg'){width=parseFloat($image[0].getBBox().width);height=parseFloat($image[0].getBBox().height)} if(!isNaN(width)&&!isNaN(height)){$entry.data('jg.width',width);$entry.data('jg.height',height);$entry.data('jg.loaded','skipped');skippedImages=!0;that.startImgAnalyzer(!1);return!0}} $entry.data('jg.loaded',!1);imagesToLoad=!0;if(!that.isSpinnerActive())that.startLoadingSpinnerAnimation();that.onImageEvent(imageSrc,function(loadImg){$entry.data('jg.width',loadImg.width);$entry.data('jg.height',loadImg.height);$entry.data('jg.loaded',!0);that.startImgAnalyzer(!1)},function(){$entry.data('jg.loaded','error');that.startImgAnalyzer(!1)})}else{$entry.data('jg.loaded',!0);$entry.data('jg.width',$entry.width()|parseFloat($entry.css('width'))|1);$entry.data('jg.height',$entry.height()|parseFloat($entry.css('height'))|1)}}});if(!imagesToLoad&&!skippedImages)this.startImgAnalyzer(!1);this.checkWidth()};JustifiedGallery.prototype.checkOrConvertNumber=function(settingContainer,settingName){if($.type(settingContainer[settingName])==='string'){settingContainer[settingName]=parseFloat(settingContainer[settingName])} if($.type(settingContainer[settingName])==='number'){if(isNaN(settingContainer[settingName]))throw 'invalid number for '+settingName}else{throw settingName+' must be a number'}};JustifiedGallery.prototype.checkSizeRangesSuffixes=function(){if($.type(this.settings.sizeRangeSuffixes)!=='object'){throw 'sizeRangeSuffixes must be defined and must be an object'} var suffixRanges=[];for(var rangeIdx in this.settings.sizeRangeSuffixes){if(this.settings.sizeRangeSuffixes.hasOwnProperty(rangeIdx))suffixRanges.push(rangeIdx)} var newSizeRngSuffixes={0:''};for(var i=0;i1){throw 'justifyThreshold must be in the interval [0,1]'} if($.type(this.settings.cssAnimation)!=='boolean'){throw 'cssAnimation must be a boolean'} if($.type(this.settings.captions)!=='boolean')throw 'captions must be a boolean';this.checkOrConvertNumber(this.settings.captionSettings,'animationDuration');this.checkOrConvertNumber(this.settings.captionSettings,'visibleOpacity');if(this.settings.captionSettings.visibleOpacity<0||this.settings.captionSettings.visibleOpacity>1){throw 'captionSettings.visibleOpacity must be in the interval [0, 1]'} this.checkOrConvertNumber(this.settings.captionSettings,'nonVisibleOpacity');if(this.settings.captionSettings.nonVisibleOpacity<0||this.settings.captionSettings.nonVisibleOpacity>1){throw 'captionSettings.nonVisibleOpacity must be in the interval [0, 1]'} this.checkOrConvertNumber(this.settings,'imagesAnimationDuration');this.checkOrConvertNumber(this.settings,'refreshTime');this.checkOrConvertNumber(this.settings,'refreshSensitivity');if($.type(this.settings.randomize)!=='boolean')throw 'randomize must be a boolean';if($.type(this.settings.selector)!=='string')throw 'selector must be a string';if(this.settings.sort!==!1&&!$.isFunction(this.settings.sort)){throw 'sort must be false or a comparison function'} if(this.settings.filter!==!1&&!$.isFunction(this.settings.filter)&&$.type(this.settings.filter)!=='string'){throw 'filter must be false, a string or a filter function'}};JustifiedGallery.prototype.retrieveSuffixRanges=function(){var suffixRanges=[];for(var rangeIdx in this.settings.sizeRangeSuffixes){if(this.settings.sizeRangeSuffixes.hasOwnProperty(rangeIdx))suffixRanges.push(parseInt(rangeIdx,10))} suffixRanges.sort(function(a,b){return a>b?1:a=0?this.settings.border:this.settings.margins;this.maxRowHeight=this.retrieveMaxRowHeight();this.suffixRanges=this.retrieveSuffixRanges()};JustifiedGallery.prototype.defaults={sizeRangeSuffixes:{},thumbnailPath:undefined,rowHeight:120,maxRowHeight:!1,maxRowsCount:0,margins:1,border:-1,lastRow:'nojustify',justifyThreshold:0.90,waitThumbnailsLoad:!0,captions:!0,cssAnimation:!0,imagesAnimationDuration:500,captionSettings:{animationDuration:500,visibleOpacity:0.7,nonVisibleOpacity:0.0},rel:null,target:null,extension:/\.[^.\\/]+$/,refreshTime:200,refreshSensitivity:0,randomize:!1,rtl:!1,sort:!1,filter:!1,selector:'a',imgSelector:'> img, > a > img, > svg, > a > svg',triggerEvent:function(event){this.$gallery.trigger(event)}};$.fn.justifiedGallery=function(arg){return this.each(function(index,gallery){var $gallery=$(gallery);$gallery.addClass('justified-gallery');var controller=$gallery.data('jg.controller');if(typeof controller==='undefined'){if(typeof arg!=='undefined'&&arg!==null&&$.type(arg)!=='object'){if(arg==='destroy')return;throw 'The argument must be an object'} controller=new JustifiedGallery($gallery,$.extend({},JustifiedGallery.prototype.defaults,arg));$gallery.data('jg.controller',controller)}else if(arg==='norewind'){}else if(arg==='destroy'){controller.destroy();return}else{controller.updateSettings(arg);controller.rewind()} if(!controller.updateEntries(arg==='norewind'))return;controller.init()})}})); /*! * Customized version of iScroll.js 0.0.1 * It fixes bugs affecting its integration with fullpage.js */ /*! iScroll v5.2.0 ~ (c) 2008-2016 Matteo Spinelli ~ http://cubiq.org/license */ (function(window,document,Math){var rAF=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(callback){window.setTimeout(callback,1000/60)};var utils=(function(){var me={};var _elementStyle=document.createElement('div').style;var _vendor=(function(){var vendors=['t','webkitT','MozT','msT','OT'],transform,i=0,l=vendors.length;for(;i0){destination=wrapperSize?wrapperSize/2.5*(speed/8):0;distance=Math.abs(current)+destination;duration=distance/speed} return{destination:Math.round(destination),duration:duration}};var _transform=_prefixStyle('transform');me.extend(me,{hasTransform:_transform!==!1,hasPerspective:_prefixStyle('perspective')in _elementStyle,hasTouch:'ontouchstart' in window,hasPointer:!!(window.PointerEvent||window.MSPointerEvent),hasTransition:_prefixStyle('transition')in _elementStyle});me.isBadAndroid=(function(){var appVersion=window.navigator.appVersion;if(/Android/.test(appVersion)&&!(/Chrome\/\d/.test(appVersion))){var safariVersion=appVersion.match(/Safari\/(\d+.\d)/);if(safariVersion&&typeof safariVersion==="object"&&safariVersion.length>=2){return parseFloat(safariVersion[1])<535.19}else{return!0}}else{return!1}})();me.extend(me.style={},{transform:_transform,transitionTimingFunction:_prefixStyle('transitionTimingFunction'),transitionDuration:_prefixStyle('transitionDuration'),transitionDelay:_prefixStyle('transitionDelay'),transformOrigin:_prefixStyle('transformOrigin')});me.hasClass=function(e,c){var re=new RegExp("(^|\\s)"+c+"(\\s|$)");return re.test(e.className)};me.addClass=function(e,c){if(me.hasClass(e,c)){return} var newclass=e.className.split(' ');newclass.push(c);e.className=newclass.join(' ')};me.removeClass=function(e,c){if(!me.hasClass(e,c)){return} var re=new RegExp("(^|\\s)"+c+"(\\s|$)",'g');e.className=e.className.replace(re,' ')};me.offset=function(el){var left=-el.offsetLeft,top=-el.offsetTop;while(el=el.offsetParent){left-=el.offsetLeft;top-=el.offsetTop} return{left:left,top:top}};me.preventDefaultException=function(el,exceptions){for(var i in exceptions){if(exceptions[i].test(el[i])){return!0}} return!1};me.extend(me.eventType={},{touchstart:1,touchmove:1,touchend:1,mousedown:2,mousemove:2,mouseup:2,pointerdown:3,pointermove:3,pointerup:3,MSPointerDown:3,MSPointerMove:3,MSPointerUp:3});me.extend(me.ease={},{quadratic:{style:'cubic-bezier(0.25, 0.46, 0.45, 0.94)',fn:function(k){return k*(2-k)}},circular:{style:'cubic-bezier(0.1, 0.57, 0.1, 1)',fn:function(k){return Math.sqrt(1-(--k*k))}},back:{style:'cubic-bezier(0.175, 0.885, 0.32, 1.275)',fn:function(k){var b=4;return(k=k-1)*k*((b+1)*k+b)+1}},bounce:{style:'',fn:function(k){if((k/=1)<(1/2.75)){return 7.5625*k*k}else if(k<(2/2.75)){return 7.5625*(k-=(1.5/2.75))*k+0.75}else if(k<(2.5/2.75)){return 7.5625*(k-=(2.25/2.75))*k+0.9375}else{return 7.5625*(k-=(2.625/2.75))*k+0.984375}}},elastic:{style:'',fn:function(k){var f=0.22,e=0.4;if(k===0){return 0} if(k==1){return 1} return(e*Math.pow(2,-10*k)*Math.sin((k-f/4)*(2*Math.PI)/f)+1)}}});me.tap=function(e,eventName){var ev=document.createEvent('Event');ev.initEvent(eventName,!0,!0);ev.pageX=e.pageX;ev.pageY=e.pageY;e.target.dispatchEvent(ev)};me.click=function(e){var target=e.target,ev;if(!(/(SELECT|INPUT|TEXTAREA)/i).test(target.tagName)){ev=document.createEvent(window.MouseEvent?'MouseEvents':'Event');ev.initEvent('click',!0,!0);ev.view=e.view||window;ev.detail=1;ev.screenX=target.screenX||0;ev.screenY=target.screenY||0;ev.clientX=target.clientX||0;ev.clientY=target.clientY||0;ev.ctrlKey=!!e.ctrlKey;ev.altKey=!!e.altKey;ev.shiftKey=!!e.shiftKey;ev.metaKey=!!e.metaKey;ev.button=0;ev.relatedTarget=null;ev._constructed=!0;target.dispatchEvent(ev)}};return me})();function IScroll(el,options){this.wrapper=typeof el=='string'?document.querySelector(el):el;this.scroller=this.wrapper.children[0];this.scrollerStyle=this.scroller.style;this.options={resizeScrollbars:!0,mouseWheelSpeed:20,snapThreshold:0.334,disablePointer:!utils.hasPointer,disableTouch:utils.hasPointer||!utils.hasTouch,disableMouse:utils.hasPointer||utils.hasTouch,startX:0,startY:0,scrollY:!0,directionLockThreshold:5,momentum:!0,bounce:!0,bounceTime:600,bounceEasing:'',preventDefault:!0,preventDefaultException:{tagName:/^(INPUT|TEXTAREA|BUTTON|SELECT|LABEL)$/},HWCompositing:!0,useTransition:!0,useTransform:!0,bindToWrapper:typeof window.onmousedown==="undefined"};for(var i in options){this.options[i]=options[i]} this.translateZ=this.options.HWCompositing&&utils.hasPerspective?' translateZ(0)':'';this.options.useTransition=utils.hasTransition&&this.options.useTransition;this.options.useTransform=utils.hasTransform&&this.options.useTransform;this.options.eventPassthrough=this.options.eventPassthrough===!0?'vertical':this.options.eventPassthrough;this.options.preventDefault=!this.options.eventPassthrough&&this.options.preventDefault;this.options.scrollY=this.options.eventPassthrough=='vertical'?!1:this.options.scrollY;this.options.scrollX=this.options.eventPassthrough=='horizontal'?!1:this.options.scrollX;this.options.freeScroll=this.options.freeScroll&&!this.options.eventPassthrough;this.options.directionLockThreshold=this.options.eventPassthrough?0:this.options.directionLockThreshold;this.options.bounceEasing=typeof this.options.bounceEasing=='string'?utils.ease[this.options.bounceEasing]||utils.ease.circular:this.options.bounceEasing;this.options.resizePolling=this.options.resizePolling===undefined?60:this.options.resizePolling;if(this.options.tap===!0){this.options.tap='tap'} if(!this.options.useTransition&&!this.options.useTransform){if(!(/relative|absolute/i).test(this.scrollerStyle.position)){this.scrollerStyle.position="relative"}} if(this.options.shrinkScrollbars=='scale'){this.options.useTransition=!1} this.options.invertWheelDirection=this.options.invertWheelDirection?-1:1;this.x=0;this.y=0;this.directionX=0;this.directionY=0;this._events={};this._init();this.refresh();this.scrollTo(this.options.startX,this.options.startY);this.enable()} IScroll.prototype={version:'5.2.0',_init:function(){this._initEvents();if(this.options.scrollbars||this.options.indicators){this._initIndicators()} if(this.options.mouseWheel){this._initWheel()} if(this.options.snap){this._initSnap()} if(this.options.keyBindings){this._initKeys()}},destroy:function(){this._initEvents(!0);clearTimeout(this.resizeTimeout);this.resizeTimeout=null;this._execEvent('destroy')},_transitionEnd:function(e){if(e.target!=this.scroller||!this.isInTransition){return} this._transitionTime();if(!this.resetPosition(this.options.bounceTime)){this.isInTransition=!1;this._execEvent('scrollEnd')}},_start:function(e){if(utils.eventType[e.type]!=1){var button;if(!e.which){button=(e.button<2)?0:((e.button==4)?1:2)}else{button=e.button} if(button!==0){return}} if(!this.enabled||(this.initiated&&utils.eventType[e.type]!==this.initiated)){return} if(this.options.preventDefault&&!utils.isBadAndroid&&!utils.preventDefaultException(e.target,this.options.preventDefaultException)){e.preventDefault()} var point=e.touches?e.touches[0]:e,pos;this.initiated=utils.eventType[e.type];this.moved=!1;this.distX=0;this.distY=0;this.directionX=0;this.directionY=0;this.directionLocked=0;this.startTime=utils.getTime();if(this.options.useTransition&&this.isInTransition){this._transitionTime();this.isInTransition=!1;pos=this.getComputedPosition();this._translate(Math.round(pos.x),Math.round(pos.y));this._execEvent('scrollEnd')}else if(!this.options.useTransition&&this.isAnimating){this.isAnimating=!1;this._execEvent('scrollEnd')} this.startX=this.x;this.startY=this.y;this.absStartX=this.x;this.absStartY=this.y;this.pointX=point.pageX;this.pointY=point.pageY;this._execEvent('beforeScrollStart')},_move:function(e){if(!this.enabled||utils.eventType[e.type]!==this.initiated){return} if(this.options.preventDefault){e.preventDefault()} var point=e.touches?e.touches[0]:e,deltaX=point.pageX-this.pointX,deltaY=point.pageY-this.pointY,timestamp=utils.getTime(),newX,newY,absDistX,absDistY;this.pointX=point.pageX;this.pointY=point.pageY;this.distX+=deltaX;this.distY+=deltaY;absDistX=Math.abs(this.distX);absDistY=Math.abs(this.distY);if(timestamp-this.endTime>300&&(absDistX<10&&absDistY<10)){return} if(!this.directionLocked&&!this.options.freeScroll){if(absDistX>absDistY+this.options.directionLockThreshold){this.directionLocked='h'}else if(absDistY>=absDistX+this.options.directionLockThreshold){this.directionLocked='v'}else{this.directionLocked='n'}} if(this.directionLocked=='h'){if(this.options.eventPassthrough=='vertical'){e.preventDefault()}else if(this.options.eventPassthrough=='horizontal'){this.initiated=!1;return} deltaY=0}else if(this.directionLocked=='v'){if(this.options.eventPassthrough=='horizontal'){e.preventDefault()}else if(this.options.eventPassthrough=='vertical'){this.initiated=!1;return} deltaX=0} deltaX=this.hasHorizontalScroll?deltaX:0;deltaY=this.hasVerticalScroll?deltaY:0;newX=this.x+deltaX;newY=this.y+deltaY;if(newX>0||newX0?0:this.maxScrollX} if(newY>0||newY0?0:this.maxScrollY} this.directionX=deltaX>0?-1:deltaX<0?1:0;this.directionY=deltaY>0?-1:deltaY<0?1:0;if(!this.moved){this._execEvent('scrollStart')} this.moved=!0;this._translate(newX,newY);if(timestamp-this.startTime>300){this.startTime=timestamp;this.startX=this.x;this.startY=this.y}},_end:function(e){if(!this.enabled||utils.eventType[e.type]!==this.initiated){return} if(this.options.preventDefault&&!utils.preventDefaultException(e.target,this.options.preventDefaultException)){e.preventDefault()} var point=e.changedTouches?e.changedTouches[0]:e,momentumX,momentumY,duration=utils.getTime()-this.startTime,newX=Math.round(this.x),newY=Math.round(this.y),distanceX=Math.abs(newX-this.startX),distanceY=Math.abs(newY-this.startY),time=0,easing='';this.isInTransition=0;this.initiated=0;this.endTime=utils.getTime();if(this.resetPosition(this.options.bounceTime)){return} this.scrollTo(newX,newY);if(!this.moved){if(this.options.tap){utils.tap(e,this.options.tap)} if(this.options.click){utils.click(e)} this._execEvent('scrollCancel');return} if(this._events.flick&&duration<200&&distanceX<100&&distanceY<100){this._execEvent('flick');return} if(this.options.momentum&&duration<300){momentumX=this.hasHorizontalScroll?utils.momentum(this.x,this.startX,duration,this.maxScrollX,this.options.bounce?this.wrapperWidth:0,this.options.deceleration):{destination:newX,duration:0};momentumY=this.hasVerticalScroll?utils.momentum(this.y,this.startY,duration,this.maxScrollY,this.options.bounce?this.wrapperHeight:0,this.options.deceleration):{destination:newY,duration:0};newX=momentumX.destination;newY=momentumY.destination;time=Math.max(momentumX.duration,momentumY.duration);this.isInTransition=1} if(this.options.snap){var snap=this._nearestSnap(newX,newY);this.currentPage=snap;time=this.options.snapSpeed||Math.max(Math.max(Math.min(Math.abs(newX-snap.x),1000),Math.min(Math.abs(newY-snap.y),1000)),300);newX=snap.x;newY=snap.y;this.directionX=0;this.directionY=0;easing=this.options.bounceEasing} if(newX!=this.x||newY!=this.y){if(newX>0||newX0||newY0){x=0}else if(this.x0){y=0}else if(this.y-1){this._events[type].splice(index,1)}},_execEvent:function(type){if(!this._events[type]){return} var i=0,l=this._events[type].length;if(!l){return} for(;i0;var transitionType=this.options.useTransition&&easing.style;if(!time||transitionType){if(transitionType){this._transitionTimingFunction(easing.style);this._transitionTime(time)} this._translate(x,y)}else{this._animate(x,y,time,easing.fn)}},scrollToElement:function(el,time,offsetX,offsetY,easing){el=el.nodeType?el:this.scroller.querySelector(el);if(!el){return} var pos=utils.offset(el);pos.left-=this.wrapperOffset.left;pos.top-=this.wrapperOffset.top;if(offsetX===!0){offsetX=Math.round(el.offsetWidth/2-this.wrapper.offsetWidth/2)} if(offsetY===!0){offsetY=Math.round(el.offsetHeight/2-this.wrapper.offsetHeight/2)} pos.left-=offsetX||0;pos.top-=offsetY||0;pos.left=pos.left>0?0:pos.left0?0:pos.top-1) return!1;if(this.options.useTransform){this.scrollerStyle[utils.style.transform]='translate('+x+'px,'+y+'px)'+this.translateZ}else{x=Math.round(x);y=Math.round(y);this.scrollerStyle.left=x+'px';this.scrollerStyle.top=y+'px'} this.x=x;this.y=y;if(this.indicators){for(var i=this.indicators.length;i--;){this.indicators[i].updatePosition()}} var uncodevent=new CustomEvent('fp-slide-scroll');window.dispatchEvent(uncodevent)},_initEvents:function(remove){var eventType=remove?utils.removeEvent:utils.addEvent,target=this.options.bindToWrapper?this.wrapper:window;eventType(window,'orientationchange',this);eventType(window,'resize',this);if(this.options.click){eventType(this.wrapper,'click',this,!0)} if(!this.options.disableMouse){eventType(this.wrapper,'mousedown',this);eventType(target,'mousemove',this);eventType(target,'mousecancel',this);eventType(target,'mouseup',this)} if(utils.hasPointer&&!this.options.disablePointer){eventType(this.wrapper,utils.prefixPointerEvent('pointerdown'),this);eventType(target,utils.prefixPointerEvent('pointermove'),this);eventType(target,utils.prefixPointerEvent('pointercancel'),this);eventType(target,utils.prefixPointerEvent('pointerup'),this)} if(utils.hasTouch&&!this.options.disableTouch){eventType(this.wrapper,'touchstart',this);eventType(target,'touchmove',this);eventType(target,'touchcancel',this);eventType(target,'touchend',this)} eventType(this.scroller,'transitionend',this);eventType(this.scroller,'webkitTransitionEnd',this);eventType(this.scroller,'oTransitionEnd',this);eventType(this.scroller,'MSTransitionEnd',this)},getComputedPosition:function(){var matrix=window.getComputedStyle(this.scroller,null),x,y;if(this.options.useTransform){matrix=matrix[utils.style.transform].split(')')[0].split(', ');x=+(matrix[12]||matrix[4]);y=+(matrix[13]||matrix[5])}else{x=+matrix.left.replace(/[^-\d.]/g,'');y=+matrix.top.replace(/[^-\d.]/g,'')} return{x:x,y:y}},_initIndicators:function(){var interactive=this.options.interactiveScrollbars,customStyle=typeof this.options.scrollbars!='string',indicators=[],indicator;var that=this;this.indicators=[];if(this.options.scrollbars){if(this.options.scrollY){indicator={el:createDefaultScrollbar('v',interactive,this.options.scrollbars),interactive:interactive,defaultScrollbars:!0,customStyle:customStyle,resize:this.options.resizeScrollbars,shrink:this.options.shrinkScrollbars,fade:this.options.fadeScrollbars,listenX:!1};this.wrapper.appendChild(indicator.el);indicators.push(indicator)} if(this.options.scrollX){indicator={el:createDefaultScrollbar('h',interactive,this.options.scrollbars),interactive:interactive,defaultScrollbars:!0,customStyle:customStyle,resize:this.options.resizeScrollbars,shrink:this.options.shrinkScrollbars,fade:this.options.fadeScrollbars,listenY:!1};this.wrapper.appendChild(indicator.el);indicators.push(indicator)}} if(this.options.indicators){indicators=indicators.concat(this.options.indicators)} for(var i=indicators.length;i--;){this.indicators.push(new Indicator(this,indicators[i]))} function _indicatorsMap(fn){if(that.indicators){for(var i=that.indicators.length;i--;){fn.call(that.indicators[i])}}} if(this.options.fadeScrollbars){this.on('scrollEnd',function(){_indicatorsMap(function(){this.fade()})});this.on('scrollCancel',function(){_indicatorsMap(function(){this.fade()})});this.on('scrollStart',function(){_indicatorsMap(function(){this.fade(1)})});this.on('beforeScrollStart',function(){_indicatorsMap(function(){this.fade(1,!0)})})} this.on('refresh',function(){_indicatorsMap(function(){this.refresh()})});this.on('destroy',function(){_indicatorsMap(function(){this.destroy()});delete this.indicators})},_initWheel:function(){utils.addEvent(this.wrapper,'wheel',this);utils.addEvent(this.wrapper,'mousewheel',this);utils.addEvent(this.wrapper,'DOMMouseScroll',this);this.on('destroy',function(){clearTimeout(this.wheelTimeout);this.wheelTimeout=null;utils.removeEvent(this.wrapper,'wheel',this);utils.removeEvent(this.wrapper,'mousewheel',this);utils.removeEvent(this.wrapper,'DOMMouseScroll',this)})},_wheel:function(e){if(!this.enabled){return} var wheelDeltaX,wheelDeltaY,newX,newY,that=this;if(this.wheelTimeout===undefined){that._execEvent('scrollStart')} clearTimeout(this.wheelTimeout);this.wheelTimeout=setTimeout(function(){if(!that.options.snap){that._execEvent('scrollEnd')} that.wheelTimeout=undefined},400);if('deltaX' in e){if(e.deltaMode===1){wheelDeltaX=-e.deltaX*this.options.mouseWheelSpeed;wheelDeltaY=-e.deltaY*this.options.mouseWheelSpeed}else{wheelDeltaX=-e.deltaX;wheelDeltaY=-e.deltaY}}else if('wheelDeltaX' in e){wheelDeltaX=e.wheelDeltaX/120*this.options.mouseWheelSpeed;wheelDeltaY=e.wheelDeltaY/120*this.options.mouseWheelSpeed}else if('wheelDelta' in e){wheelDeltaX=wheelDeltaY=e.wheelDelta/120*this.options.mouseWheelSpeed}else if('detail' in e){wheelDeltaX=wheelDeltaY=-e.detail/3*this.options.mouseWheelSpeed}else{return} wheelDeltaX*=this.options.invertWheelDirection;wheelDeltaY*=this.options.invertWheelDirection;if(!this.hasVerticalScroll){wheelDeltaX=wheelDeltaY;wheelDeltaY=0} if(this.options.snap){newX=this.currentPage.pageX;newY=this.currentPage.pageY;if(wheelDeltaX>0){newX--}else if(wheelDeltaX<0){newX++} if(wheelDeltaY>0){newY--}else if(wheelDeltaY<0){newY++} this.goToPage(newX,newY);return} newX=this.x+Math.round(this.hasHorizontalScroll?wheelDeltaX:0);newY=this.y+Math.round(this.hasVerticalScroll?wheelDeltaY:0);this.directionX=wheelDeltaX>0?-1:wheelDeltaX<0?1:0;this.directionY=wheelDeltaY>0?-1:wheelDeltaY<0?1:0;if(newX>0){newX=0}else if(newX0){newY=0}else if(newY-this.scrollerWidth){this.pages[i]=[];l=0;y=0;while(y>-this.scrollerHeight){this.pages[i][l]={x:Math.max(x,this.maxScrollX),y:Math.max(y,this.maxScrollY),width:stepX,height:stepY,cx:x-cx,cy:y-cy};y-=stepY;l++} x-=stepX;i++}}else{el=this.options.snap;l=el.length;n=-1;for(;ithis.maxScrollX){m++}}} this.goToPage(this.currentPage.pageX||0,this.currentPage.pageY||0,0);if(this.options.snapThreshold%1===0){this.snapThresholdX=this.options.snapThreshold;this.snapThresholdY=this.options.snapThreshold}else{this.snapThresholdX=Math.round(this.pages[this.currentPage.pageX][this.currentPage.pageY].width*this.options.snapThreshold);this.snapThresholdY=Math.round(this.pages[this.currentPage.pageX][this.currentPage.pageY].height*this.options.snapThreshold)}});this.on('flick',function(){var time=this.options.snapSpeed||Math.max(Math.max(Math.min(Math.abs(this.x-this.startX),1000),Math.min(Math.abs(this.y-this.startY),1000)),300);this.goToPage(this.currentPage.pageX+this.directionX,this.currentPage.pageY+this.directionY,time)})},_nearestSnap:function(x,y){if(!this.pages.length){return{x:0,y:0,pageX:0,pageY:0}} var i=0,l=this.pages.length,m=0;if(Math.abs(x-this.absStartX)0){x=0}else if(x0){y=0}else if(y=this.pages[i][0].cx){x=this.pages[i][0].x;break}} l=this.pages[i].length;for(;m=this.pages[0][m].cy){y=this.pages[0][m].y;break}} if(i==this.currentPage.pageX){i+=this.directionX;if(i<0){i=0}else if(i>=this.pages.length){i=this.pages.length-1} x=this.pages[i][0].x} if(m==this.currentPage.pageY){m+=this.directionY;if(m<0){m=0}else if(m>=this.pages[0].length){m=this.pages[0].length-1} y=this.pages[0][m].y} return{x:x,y:y,pageX:i,pageY:m}},goToPage:function(x,y,time,easing){easing=easing||this.options.bounceEasing;if(x>=this.pages.length){x=this.pages.length-1}else if(x<0){x=0} if(y>=this.pages[x].length){y=this.pages[x].length-1}else if(y<0){y=0} var posX=this.pages[x][y].x,posY=this.pages[x][y].y;time=time===undefined?this.options.snapSpeed||Math.max(Math.max(Math.min(Math.abs(posX-this.x),1000),Math.min(Math.abs(posY-this.y),1000)),300):time;this.currentPage={x:posX,y:posY,pageX:x,pageY:y};this.scrollTo(posX,posY,time,easing)},next:function(time,easing){var x=this.currentPage.pageX,y=this.currentPage.pageY;x++;if(x>=this.pages.length&&this.hasVerticalScroll){x=0;y++} this.goToPage(x,y,time,easing)},prev:function(time,easing){var x=this.currentPage.pageX,y=this.currentPage.pageY;x--;if(x<0&&this.hasVerticalScroll){x=0;y--} this.goToPage(x,y,time,easing)},_initKeys:function(e){var keys={pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40};var i;if(typeof this.options.keyBindings=='object'){for(i in this.options.keyBindings){if(typeof this.options.keyBindings[i]=='string'){this.options.keyBindings[i]=this.options.keyBindings[i].toUpperCase().charCodeAt(0)}}}else{this.options.keyBindings={}} for(i in keys){this.options.keyBindings[i]=this.options.keyBindings[i]||keys[i]} utils.addEvent(window,'keydown',this);this.on('destroy',function(){utils.removeEvent(window,'keydown',this)})},_key:function(e){if(!this.enabled){return} var snap=this.options.snap,newX=snap?this.currentPage.pageX:this.x,newY=snap?this.currentPage.pageY:this.y,now=utils.getTime(),prevTime=this.keyTime||0,acceleration=0.250,pos;if(this.options.useTransition&&this.isInTransition){pos=this.getComputedPosition();this._translate(Math.round(pos.x),Math.round(pos.y));this.isInTransition=!1} this.keyAcceleration=now-prevTime<200?Math.min(this.keyAcceleration+acceleration,50):0;switch(e.keyCode){case this.options.keyBindings.pageUp:if(this.hasHorizontalScroll&&!this.hasVerticalScroll){newX+=snap?1:this.wrapperWidth}else{newY+=snap?1:this.wrapperHeight} break;case this.options.keyBindings.pageDown:if(this.hasHorizontalScroll&&!this.hasVerticalScroll){newX-=snap?1:this.wrapperWidth}else{newY-=snap?1:this.wrapperHeight} break;case this.options.keyBindings.end:newX=snap?this.pages.length-1:this.maxScrollX;newY=snap?this.pages[0].length-1:this.maxScrollY;break;case this.options.keyBindings.home:newX=0;newY=0;break;case this.options.keyBindings.left:newX+=snap?-1:5+this.keyAcceleration>>0;break;case this.options.keyBindings.up:newY+=snap?1:5+this.keyAcceleration>>0;break;case this.options.keyBindings.right:newX-=snap?-1:5+this.keyAcceleration>>0;break;case this.options.keyBindings.down:newY-=snap?1:5+this.keyAcceleration>>0;break;default:return} if(snap){this.goToPage(newX,newY);return} if(newX>0){newX=0;this.keyAcceleration=0}else if(newX0){newY=0;this.keyAcceleration=0}else if(newY=destTime){that.isAnimating=!1;that._translate(destX,destY);if(!that.resetPosition(that.options.bounceTime)){that._execEvent('scrollEnd')} return} now=(now-startTime)/duration;easing=easingFn(now);newX=(destX-startX)*easing+startX;newY=(destY-startY)*easing+startY;that._translate(newX,newY);if(that.isAnimating){rAF(step)}} this.isAnimating=!0;step()},handleEvent:function(e){switch(e.type){case 'touchstart':case 'pointerdown':case 'MSPointerDown':case 'mousedown':this._start(e);break;case 'touchmove':case 'pointermove':case 'MSPointerMove':case 'mousemove':this._move(e);break;case 'touchend':case 'pointerup':case 'MSPointerUp':case 'mouseup':case 'touchcancel':case 'pointercancel':case 'MSPointerCancel':case 'mousecancel':this._end(e);break;case 'orientationchange':case 'resize':this._resize();break;case 'transitionend':case 'webkitTransitionEnd':case 'oTransitionEnd':case 'MSTransitionEnd':this._transitionEnd(e);break;case 'wheel':case 'DOMMouseScroll':case 'mousewheel':this._wheel(e);break;case 'keydown':this._key(e);break;case 'click':if(this.enabled&&!e._constructed){e.preventDefault();e.stopPropagation()} break}}};function createDefaultScrollbar(direction,interactive,type){var scrollbar=document.createElement('div'),indicator=document.createElement('div');if(type===!0){scrollbar.style.cssText='position:absolute;z-index:9999';indicator.style.cssText='-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;position:absolute;background:rgba(0,0,0,0.5);border:1px solid rgba(255,255,255,0.9);border-radius:3px'} indicator.className='iScrollIndicator';if(direction=='h'){if(type===!0){scrollbar.style.cssText+=';height:7px;left:2px;right:2px;bottom:0';indicator.style.height='100%'} scrollbar.className='iScrollHorizontalScrollbar'}else{if(type===!0){scrollbar.style.cssText+=';width:7px;bottom:2px;top:2px;right:1px';indicator.style.width='100%'} scrollbar.className='iScrollVerticalScrollbar'} scrollbar.style.cssText+=';overflow:hidden';if(!interactive){scrollbar.style.pointerEvents='none'} scrollbar.appendChild(indicator);return scrollbar} function Indicator(scroller,options){this.wrapper=typeof options.el=='string'?document.querySelector(options.el):options.el;this.wrapperStyle=this.wrapper.style;this.indicator=this.wrapper.children[0];this.indicatorStyle=this.indicator.style;this.scroller=scroller;this.options={listenX:!0,listenY:!0,interactive:!1,resize:!0,defaultScrollbars:!1,shrink:!1,fade:!1,speedRatioX:0,speedRatioY:0};for(var i in options){this.options[i]=options[i]} this.sizeRatioX=1;this.sizeRatioY=1;this.maxPosX=0;this.maxPosY=0;if(this.options.interactive){if(!this.options.disableTouch){utils.addEvent(this.indicator,'touchstart',this);utils.addEvent(window,'touchend',this)} if(!this.options.disablePointer){utils.addEvent(this.indicator,utils.prefixPointerEvent('pointerdown'),this);utils.addEvent(window,utils.prefixPointerEvent('pointerup'),this)} if(!this.options.disableMouse){utils.addEvent(this.indicator,'mousedown',this);utils.addEvent(window,'mouseup',this)}} if(this.options.fade){this.wrapperStyle[utils.style.transform]=this.scroller.translateZ;var durationProp=utils.style.transitionDuration;if(!durationProp){return} this.wrapperStyle[durationProp]=utils.isBadAndroid?'0.0001ms':'0ms';var self=this;if(utils.isBadAndroid){rAF(function(){if(self.wrapperStyle[durationProp]==='0.0001ms'){self.wrapperStyle[durationProp]='0s'}})} this.wrapperStyle.opacity='0'}} Indicator.prototype={handleEvent:function(e){switch(e.type){case 'touchstart':case 'pointerdown':case 'MSPointerDown':case 'mousedown':this._start(e);break;case 'touchmove':case 'pointermove':case 'MSPointerMove':case 'mousemove':this._move(e);break;case 'touchend':case 'pointerup':case 'MSPointerUp':case 'mouseup':case 'touchcancel':case 'pointercancel':case 'MSPointerCancel':case 'mousecancel':this._end(e);break}},destroy:function(){if(this.options.fadeScrollbars){clearTimeout(this.fadeTimeout);this.fadeTimeout=null} if(this.options.interactive){utils.removeEvent(this.indicator,'touchstart',this);utils.removeEvent(this.indicator,utils.prefixPointerEvent('pointerdown'),this);utils.removeEvent(this.indicator,'mousedown',this);utils.removeEvent(window,'touchmove',this);utils.removeEvent(window,utils.prefixPointerEvent('pointermove'),this);utils.removeEvent(window,'mousemove',this);utils.removeEvent(window,'touchend',this);utils.removeEvent(window,utils.prefixPointerEvent('pointerup'),this);utils.removeEvent(window,'mouseup',this)} if(this.options.defaultScrollbars){this.wrapper.parentNode.removeChild(this.wrapper)}},_start:function(e){var point=e.touches?e.touches[0]:e;e.preventDefault();e.stopPropagation();this.transitionTime();this.initiated=!0;this.moved=!1;this.lastPointX=point.pageX;this.lastPointY=point.pageY;this.startTime=utils.getTime();if(!this.options.disableTouch){utils.addEvent(window,'touchmove',this)} if(!this.options.disablePointer){utils.addEvent(window,utils.prefixPointerEvent('pointermove'),this)} if(!this.options.disableMouse){utils.addEvent(window,'mousemove',this)} this.scroller._execEvent('beforeScrollStart')},_move:function(e){var point=e.touches?e.touches[0]:e,deltaX,deltaY,newX,newY,timestamp=utils.getTime();if(!this.moved){this.scroller._execEvent('scrollStart')} this.moved=!0;deltaX=point.pageX-this.lastPointX;this.lastPointX=point.pageX;deltaY=point.pageY-this.lastPointY;this.lastPointY=point.pageY;newX=this.x+deltaX;newY=this.y+deltaY;this._pos(newX,newY);e.preventDefault();e.stopPropagation()},_end:function(e){if(!this.initiated){return} this.initiated=!1;e.preventDefault();e.stopPropagation();utils.removeEvent(window,'touchmove',this);utils.removeEvent(window,utils.prefixPointerEvent('pointermove'),this);utils.removeEvent(window,'mousemove',this);if(this.scroller.options.snap){var snap=this.scroller._nearestSnap(this.scroller.x,this.scroller.y);var time=this.options.snapSpeed||Math.max(Math.max(Math.min(Math.abs(this.scroller.x-snap.x),1000),Math.min(Math.abs(this.scroller.y-snap.y),1000)),300);if(this.scroller.x!=snap.x||this.scroller.y!=snap.y){this.scroller.directionX=0;this.scroller.directionY=0;this.scroller.currentPage=snap;this.scroller.scrollTo(snap.x,snap.y,time,this.scroller.options.bounceEasing)}} if(this.moved){this.scroller._execEvent('scrollEnd')}},transitionTime:function(time){time=time||0;var durationProp=utils.style.transitionDuration;if(!durationProp){return} this.indicatorStyle[durationProp]=time+'ms';if(!time&&utils.isBadAndroid){this.indicatorStyle[durationProp]='0.0001ms';var self=this;rAF(function(){if(self.indicatorStyle[durationProp]==='0.0001ms'){self.indicatorStyle[durationProp]='0s'}})}},transitionTimingFunction:function(easing){this.indicatorStyle[utils.style.transitionTimingFunction]=easing},refresh:function(){this.transitionTime();if(this.options.listenX&&!this.options.listenY){this.indicatorStyle.display=this.scroller.hasHorizontalScroll?'block':'none'}else if(this.options.listenY&&!this.options.listenX){this.indicatorStyle.display=this.scroller.hasVerticalScroll?'block':'none'}else{this.indicatorStyle.display=this.scroller.hasHorizontalScroll||this.scroller.hasVerticalScroll?'block':'none'} if(this.scroller.hasHorizontalScroll&&this.scroller.hasVerticalScroll){utils.addClass(this.wrapper,'iScrollBothScrollbars');utils.removeClass(this.wrapper,'iScrollLoneScrollbar');if(this.options.defaultScrollbars&&this.options.customStyle){if(this.options.listenX){this.wrapper.style.right='8px'}else{this.wrapper.style.bottom='8px'}}}else{utils.removeClass(this.wrapper,'iScrollBothScrollbars');utils.addClass(this.wrapper,'iScrollLoneScrollbar');if(this.options.defaultScrollbars&&this.options.customStyle){if(this.options.listenX){this.wrapper.style.right='2px'}else{this.wrapper.style.bottom='2px'}}} var r=this.wrapper.offsetHeight;if(this.options.listenX){this.wrapperWidth=this.wrapper.clientWidth;if(this.options.resize){this.indicatorWidth=Math.max(Math.round(this.wrapperWidth*this.wrapperWidth/(this.scroller.scrollerWidth||this.wrapperWidth||1)),8);this.indicatorStyle.width=this.indicatorWidth+'px'}else{this.indicatorWidth=this.indicator.clientWidth} this.maxPosX=this.wrapperWidth-this.indicatorWidth;if(this.options.shrink=='clip'){this.minBoundaryX=-this.indicatorWidth+8;this.maxBoundaryX=this.wrapperWidth-8}else{this.minBoundaryX=0;this.maxBoundaryX=this.maxPosX} this.sizeRatioX=this.options.speedRatioX||(this.scroller.maxScrollX&&(this.maxPosX/this.scroller.maxScrollX))} if(this.options.listenY){this.wrapperHeight=this.wrapper.clientHeight;if(this.options.resize){this.indicatorHeight=Math.max(Math.round(this.wrapperHeight*this.wrapperHeight/(this.scroller.scrollerHeight||this.wrapperHeight||1)),8);this.indicatorStyle.height=this.indicatorHeight+'px'}else{this.indicatorHeight=this.indicator.clientHeight} this.maxPosY=this.wrapperHeight-this.indicatorHeight;if(this.options.shrink=='clip'){this.minBoundaryY=-this.indicatorHeight+8;this.maxBoundaryY=this.wrapperHeight-8}else{this.minBoundaryY=0;this.maxBoundaryY=this.maxPosY} this.maxPosY=this.wrapperHeight-this.indicatorHeight;this.sizeRatioY=this.options.speedRatioY||(this.scroller.maxScrollY&&(this.maxPosY/this.scroller.maxScrollY))} this.updatePosition()},updatePosition:function(){var x=this.options.listenX&&Math.round(this.sizeRatioX*this.scroller.x)||0,y=this.options.listenY&&Math.round(this.sizeRatioY*this.scroller.y)||0;if(!this.options.ignoreBoundaries){if(xthis.maxBoundaryX){if(this.options.shrink=='scale'){this.width=Math.max(this.indicatorWidth-(x-this.maxPosX),8);this.indicatorStyle.width=this.width+'px';x=this.maxPosX+this.indicatorWidth-this.width}else{x=this.maxBoundaryX}}else if(this.options.shrink=='scale'&&this.width!=this.indicatorWidth){this.width=this.indicatorWidth;this.indicatorStyle.width=this.width+'px'} if(ythis.maxBoundaryY){if(this.options.shrink=='scale'){this.height=Math.max(this.indicatorHeight-(y-this.maxPosY)*3,8);this.indicatorStyle.height=this.height+'px';y=this.maxPosY+this.indicatorHeight-this.height}else{y=this.maxBoundaryY}}else if(this.options.shrink=='scale'&&this.height!=this.indicatorHeight){this.height=this.indicatorHeight;this.indicatorStyle.height=this.height+'px'}} this.x=x;this.y=y;if(this.scroller.options.useTransform){this.indicatorStyle[utils.style.transform]='translate('+x+'px,'+y+'px)'+this.scroller.translateZ}else{this.indicatorStyle.left=x+'px';this.indicatorStyle.top=y+'px'}},_pos:function(x,y){if(x<0){x=0}else if(x>this.maxPosX){x=this.maxPosX} if(y<0){y=0}else if(y>this.maxPosY){y=this.maxPosY} x=this.options.listenX?Math.round(x/this.sizeRatioX):this.scroller.x;y=this.options.listenY?Math.round(y/this.sizeRatioY):this.scroller.y;this.scroller.scrollTo(x,y)},fade:function(val,hold){if(hold&&!this.visible){return} clearTimeout(this.fadeTimeout);this.fadeTimeout=null;var time=val?250:500,delay=val?0:300;val=val?'1':'0';this.wrapperStyle[utils.style.transitionDuration]=time+'ms';this.fadeTimeout=setTimeout((function(val){this.wrapperStyle.opacity=val;this.visible=+val}).bind(this,val),delay)}};IScroll.utils=utils;if(typeof module!='undefined'&&module.exports){module.exports=IScroll}else if(typeof define=='function'&&define.amd){define(function(){return IScroll})}else{window.IScroll=IScroll}})(window,document,Math); /*! * fullPage 2.9.4 * https://github.com/alvarotrigo/fullPage.js * @license MIT licensed * * Copyright (C) 2015 alvarotrigo.com - A project by Alvaro Trigo */ (function(global,factory){'use strict';if(typeof define==='function'&&define.amd){define(['jquery'],function($){return factory($,global,global.document,global.Math)})}else if(typeof exports==="object"&&exports){module.exports=factory(require('jquery'),global,global.document,global.Math)}else{factory(jQuery,global,global.document,global.Math)}})(typeof window!=='undefined'?window:this,function($,window,document,Math,undefined){'use strict';var WRAPPER='fullpage-wrapper';var WRAPPER_SEL='.'+WRAPPER;var SCROLLABLE='fp-scrollable';var SCROLLABLE_SEL='.'+SCROLLABLE;var RESPONSIVE='fp-responsive';var NO_TRANSITION='fp-notransition';var DESTROYED='fp-destroyed';var ENABLED='fp-enabled';var VIEWING_PREFIX='fp-viewing';var ACTIVE='active';var ACTIVE_SEL='.'+ACTIVE;var COMPLETELY='fp-completely';var COMPLETELY_SEL='.'+COMPLETELY;var SECTION_DEFAULT_SEL='.section';var SECTION='fp-section';var SECTION_SEL='.'+SECTION;var SECTION_ACTIVE_SEL=SECTION_SEL+ACTIVE_SEL;var SECTION_FIRST_SEL=SECTION_SEL+':first';var SECTION_LAST_SEL=SECTION_SEL+':last';var TABLE_CELL='fp-tableCell';var TABLE_CELL_SEL='.'+TABLE_CELL;var AUTO_HEIGHT='fp-auto-height';var AUTO_HEIGHT_SEL='.fp-auto-height';var NORMAL_SCROLL='fp-normal-scroll';var NORMAL_SCROLL_SEL='.fp-normal-scroll';var SECTION_NAV='fp-nav';var SECTION_NAV_SEL='#'+SECTION_NAV;var SECTION_NAV_TOOLTIP='fp-tooltip';var SECTION_NAV_TOOLTIP_SEL='.'+SECTION_NAV_TOOLTIP;var SHOW_ACTIVE_TOOLTIP='fp-show-active';var SLIDE_DEFAULT_SEL='.slide';var SLIDE='fp-slide';var SLIDE_SEL='.'+SLIDE;var SLIDE_ACTIVE_SEL=SLIDE_SEL+ACTIVE_SEL;var SLIDES_WRAPPER='fp-slides';var SLIDES_WRAPPER_SEL='.'+SLIDES_WRAPPER;var SLIDES_CONTAINER='fp-slidesContainer';var SLIDES_CONTAINER_SEL='.'+SLIDES_CONTAINER;var TABLE='fp-table';var SLIDES_NAV='fp-slidesNav';var SLIDES_NAV_SEL='.'+SLIDES_NAV;var SLIDES_NAV_LINK_SEL=SLIDES_NAV_SEL+' a';var SLIDES_ARROW='fp-controlArrow';var SLIDES_ARROW_SEL='.'+SLIDES_ARROW;var SLIDES_PREV='fp-prev';var SLIDES_PREV_SEL='.'+SLIDES_PREV;var SLIDES_ARROW_PREV=SLIDES_ARROW+' '+SLIDES_PREV;var SLIDES_ARROW_PREV_SEL=SLIDES_ARROW_SEL+SLIDES_PREV_SEL;var SLIDES_NEXT='fp-next';var SLIDES_NEXT_SEL='.'+SLIDES_NEXT;var SLIDES_ARROW_NEXT=SLIDES_ARROW+' '+SLIDES_NEXT;var SLIDES_ARROW_NEXT_SEL=SLIDES_ARROW_SEL+SLIDES_NEXT_SEL;var $window=$(window);var $document=$(document);var iscrollOptions={scrollbars:!0,mouseWheel:!0,hideScrollbars:!1,fadeScrollbars:!1,disableMouse:!0,interactiveScrollbars:!0,bounce:!1,};$.fn.fullpage=function(options){if($('html').hasClass(ENABLED)){displayWarnings();return} var $htmlBody=$('html, body');var $body=$('body');var FP=$.fn.fullpage;options=$.extend({menu:!1,anchors:[],lockAnchors:!1,navigation:!1,navigationPosition:'right',navigationTooltips:[],showActiveTooltip:!1,slidesNavigation:!1,slidesNavPosition:'bottom',scrollBar:!1,hybrid:!1,css3:!0,scrollingSpeed:700,autoScrolling:!0,fitToSection:!0,fitToSectionDelay:1000,easing:'easeInOutCubic',easingcss3:'ease',loopBottom:!1,loopTop:!1,loopHorizontal:!0,continuousVertical:!1,continuousHorizontal:!1,scrollHorizontally:!1,interlockedSlides:!1,dragAndMove:!1,offsetSections:!1,resetSliders:!1,fadingEffect:!1,normalScrollElements:null,scrollOverflow:!1,scrollOverflowReset:!1,scrollOverflowHandler:iscrollHandler,scrollOverflowOptions:null,touchSensitivity:5,normalScrollElementTouchThreshold:5,bigSectionsDestination:null,keyboardScrolling:!0,animateAnchor:!0,recordHistory:!0,controlArrows:!0,controlArrowColor:'#fff',verticalCentered:!0,sectionsColor:[],paddingTop:0,paddingBottom:0,fixedElements:null,responsive:0,responsiveWidth:0,responsiveHeight:0,responsiveSlides:!1,parallax:!1,parallaxOptions:{type:'reveal',percentage:62,property:'translate'},sectionSelector:SECTION_DEFAULT_SEL,slideSelector:SLIDE_DEFAULT_SEL,afterLoad:null,onLeave:null,afterRender:null,afterResize:null,afterReBuild:null,afterSlideLoad:null,onSlideLeave:null,afterResponsive:null,lazyLoading:!0},options);var slideMoving=!1;var isTouchDevice=navigator.userAgent.match(/(iPhone|iPod|iPad|Android|playbook|silk|BlackBerry|BB10|Windows Phone|Tizen|Bada|webOS|IEMobile|Opera Mini)/);var isTouch=(('ontouchstart' in window)||(navigator.msMaxTouchPoints>0)||(navigator.maxTouchPoints));var container=$(this);var windowsHeight=$window.height();var isResizing=!1;var isWindowFocused=!0;var lastScrolledDestiny;var lastScrolledSlide;var canScroll=!0;var scrollings=[];var controlPressed;var startingSection;var isScrollAllowed={};isScrollAllowed.m={'up':!0,'down':!0,'left':!0,'right':!0};isScrollAllowed.k=$.extend(!0,{},isScrollAllowed.m);var MSPointer=getMSPointer();var events={touchmove:'ontouchmove' in window?'touchmove':MSPointer.move,touchstart:'ontouchstart' in window?'touchstart':MSPointer.down};var g_supportsPassive=!1;try{var opts=Object.defineProperty({},'passive',{get:function(){g_supportsPassive=!0}});window.addEventListener("testPassive",null,opts);window.removeEventListener("testPassive",null,opts)}catch(e){} var resizeId;var afterSectionLoadsId;var afterSlideLoadsId;var scrollId;var scrollId2;var keydownId;var originals=$.extend(!0,{},options);var $masthead=$('#masthead');var hideMenu=!$('body').hasClass('vmenu')&&$('body').hasClass('uncode-fp-menu-hide')?!0:!1;var menuHeight=$masthead.hasClass('menu-transparent')||hideMenu?0:UNCODE.menuHeight;var bodyBorder=UNCODE.bodyBorder;var adminBarHeight=UNCODE.adminBarHeight;displayWarnings();iscrollOptions.click=isTouch;iscrollOptions=$.extend(iscrollOptions,options.scrollOverflowOptions);$.extend($.easing,{easeInOutCubic:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t+b;return c/2*((t-=2)*t*t+2)+b}});function setAutoScrolling(value,type){if(!value){silentScroll(0)} setVariableState('autoScrolling',value,type);var element=$(SECTION_ACTIVE_SEL);if(options.autoScrolling&&!options.scrollBar){$htmlBody.css({'overflow':'hidden !important','height':'100%'});container.css({'-ms-touch-action':'none','touch-action':'none'});if(element.length){silentScroll(element.position().top)}}else{$htmlBody.css({'overflow':'visible !important','height':'initial'});container.css({'-ms-touch-action':'','touch-action':''});if(element.length){$htmlBody.scrollTop(element.position().top)}}} function setRecordHistory(value,type){setVariableState('recordHistory',value,type)} function setScrollingSpeed(value,type){setVariableState('scrollingSpeed',value,type)} function setFitToSection(value,type){setVariableState('fitToSection',value,type)} function setLockAnchors(value){options.lockAnchors=value} function setMouseWheelScrolling(value){if(value){addMouseWheelHandler();addMiddleWheelHandler()}else{removeMouseWheelHandler();removeMiddleWheelHandler()}} function setAllowScrolling(value,directions){if(typeof directions!=='undefined'){directions=directions.replace(/ /g,'').split(',');$.each(directions,function(index,direction){setIsScrollAllowed(value,direction,'m')})}else if(value){setMouseWheelScrolling(!0);addTouchHandler()}else{setMouseWheelScrolling(!1);removeTouchHandler()}} function setKeyboardScrolling(value,directions){if(typeof directions!=='undefined'){directions=directions.replace(/ /g,'').split(',');$.each(directions,function(index,direction){setIsScrollAllowed(value,direction,'k')})}else{options.keyboardScrolling=value}} function moveSectionUp(){var prev=$(SECTION_ACTIVE_SEL).prev(SECTION_SEL);if(!prev.length&&(options.loopTop||options.continuousVertical)){prev=$(SECTION_SEL).last()} if(prev.length){scrollPage(prev,null,!0)}} function moveSectionDown(){var next=$(SECTION_ACTIVE_SEL).next(SECTION_SEL);if(!next.length&&(options.loopBottom||options.continuousVertical)){next=$(SECTION_SEL).first()} if(next.length){scrollPage(next,null,!1)}} function silentMoveTo(sectionAnchor,slideAnchor){setScrollingSpeed(0,'internal');moveTo(sectionAnchor,slideAnchor);setScrollingSpeed(originals.scrollingSpeed,'internal')} function moveTo(sectionAnchor,slideAnchor){var destiny=getSectionByAnchor(sectionAnchor);if(typeof slideAnchor!=='undefined'){scrollPageAndSlide(sectionAnchor,slideAnchor)}else if(destiny.length>0){scrollPage(destiny)}} function moveSlideRight(section){moveSlide('right',section)} function moveSlideLeft(section){moveSlide('left',section)} function reBuild(resizing){if(container.hasClass(DESTROYED)){return} isResizing=!0;windowsHeight=$window.height();$(SECTION_SEL).each(function(){var slidesWrap=$(this).find(SLIDES_WRAPPER_SEL);var slides=$(this).find(SLIDE_SEL);if(options.verticalCentered){$(this).find(TABLE_CELL_SEL).css('height',getTableHeight($(this))+'px')} $(this).css('height',windowsHeight+'px');if(options.scrollOverflow){if(slides.length){slides.each(function(){createScrollBar($(this))})}else{createScrollBar($(this))}} if(slides.length>1){landscapeScroll(slidesWrap,slidesWrap.find(SLIDE_ACTIVE_SEL))}});var activeSection=$(SECTION_ACTIVE_SEL);var sectionIndex=activeSection.index(SECTION_SEL);if(sectionIndex){silentMoveTo(sectionIndex+1)} isResizing=!1;$.isFunction(options.afterResize)&&resizing&&options.afterResize.call(container,getTableHeight());$.isFunction(options.afterReBuild)&&!resizing&&options.afterReBuild.call(container)} function setResponsive(active){var isResponsive=$body.hasClass(RESPONSIVE);if(active){if(!isResponsive){setAutoScrolling(!1,'internal');setFitToSection(!1,'internal');$(SECTION_NAV_SEL).hide();$body.addClass(RESPONSIVE);$.isFunction(options.afterResponsive)&&options.afterResponsive.call(container,active)}}else if(isResponsive){setAutoScrolling(originals.autoScrolling,'internal');setFitToSection(originals.autoScrolling,'internal');$(SECTION_NAV_SEL).show();$body.removeClass(RESPONSIVE);$.isFunction(options.afterResponsive)&&options.afterResponsive.call(container,active)}} if($(this).length){FP.setAutoScrolling=setAutoScrolling;FP.setRecordHistory=setRecordHistory;FP.setScrollingSpeed=setScrollingSpeed;FP.setFitToSection=setFitToSection;FP.setLockAnchors=setLockAnchors;FP.setMouseWheelScrolling=setMouseWheelScrolling;FP.setAllowScrolling=setAllowScrolling;FP.setKeyboardScrolling=setKeyboardScrolling;FP.moveSectionUp=moveSectionUp;FP.moveSectionDown=moveSectionDown;FP.silentMoveTo=silentMoveTo;FP.moveTo=moveTo;FP.moveSlideRight=moveSlideRight;FP.moveSlideLeft=moveSlideLeft;FP.fitToSection=fitToSection;FP.reBuild=reBuild;FP.setResponsive=setResponsive;FP.destroy=destroy;init();bindEvents()} function init(){if(options.css3){options.css3=support3d()} options.scrollBar=options.scrollBar||options.hybrid;setOptionsFromDOM();prepareDom();setAllowScrolling(!0);setAutoScrolling(options.autoScrolling,'internal');responsive();setBodyClass()} function bindEvents(){$window.on('hashchange',hashChangeHandler).blur(blurHandler).resize(resizeHandler);$document.keydown(keydownHandler).keyup(keyUpHandler).on('click touchstart',SECTION_NAV_SEL+' a',sectionBulletHandler).on('click touchstart',SLIDES_NAV_LINK_SEL,slideBulletHandler).on('click',SECTION_NAV_TOOLTIP_SEL,tooltipTextHandler);$(SECTION_SEL).on('click touchstart',SLIDES_ARROW_SEL,slideArrowHandler);if(options.normalScrollElements){$document.on('mouseenter',options.normalScrollElements,function(){setMouseWheelScrolling(!1)});$document.on('mouseleave',options.normalScrollElements,function(){setMouseWheelScrolling(!0)})}} function setOptionsFromDOM(){var sections=container.find(options.sectionSelector);if(!options.anchors.length){options.anchors=sections.filter('[data-anchor]').map(function(){return $(this).data('anchor').toString()}).get()} if(!options.navigationTooltips.length){options.navigationTooltips=sections.filter('[data-tooltip]').map(function(){return $(this).data('tooltip').toString()}).get()}} function prepareDom(){container.css({'height':'100%','position':'relative'});container.addClass(WRAPPER);$('html').addClass(ENABLED);windowsHeight=$window.height();container.removeClass(DESTROYED);addInternalSelectors();$(SECTION_SEL).each(function(index){var section=$(this);var slides=section.find(SLIDE_SEL);var numSlides=slides.length;styleSection(section,index);styleMenu(section,index);if(numSlides>0){styleSlides(section,slides,numSlides)}else{if(options.verticalCentered){addTableClass(section)}}});if(options.fixedElements&&options.css3){$(options.fixedElements).appendTo($body)} if(options.navigation){addVerticalNavigation()} enableYoutubeAPI();if(options.scrollOverflow){if(document.readyState==='complete'){createScrollBarHandler()} $window.on('load',createScrollBarHandler)}else{afterRenderActions()}} function styleSlides(section,slides,numSlides){var sliderWidth=numSlides*100;var slideWidth=100/numSlides;slides.wrapAll('
');slides.parent().wrap('
');section.find(SLIDES_CONTAINER_SEL).css('width',sliderWidth+'%');if(numSlides>1){if(options.controlArrows){createSlideArrows(section)} if(options.slidesNavigation){addSlidesNavigation(section,numSlides)}} slides.each(function(index){$(this).css('width',slideWidth+'%');if(options.verticalCentered){addTableClass($(this))}});var startingSlide=section.find(SLIDE_ACTIVE_SEL);if(startingSlide.length&&($(SECTION_ACTIVE_SEL).index(SECTION_SEL)!==0||($(SECTION_ACTIVE_SEL).index(SECTION_SEL)===0&&startingSlide.index()!==0))){silentLandscapeScroll(startingSlide,'internal')}else{slides.eq(0).addClass(ACTIVE)}} function styleSection(section,index){if(!index&&$(SECTION_ACTIVE_SEL).length===0){section.addClass(ACTIVE)} startingSection=$(SECTION_ACTIVE_SEL);section.css('height',windowsHeight+'px');if(options.paddingTop){section.css('padding-top',options.paddingTop)} if(options.paddingBottom){section.css('padding-bottom',options.paddingBottom)} if(typeof options.sectionsColor[index]!=='undefined'){section.css('background-color',options.sectionsColor[index])} if(typeof options.anchors[index]!=='undefined'){section.attr('data-anchor',options.anchors[index])}} function styleMenu(section,index){if(typeof options.anchors[index]!=='undefined'){if(section.hasClass(ACTIVE)){activateMenuAndNav(options.anchors[index],index)}} if(options.menu&&options.css3&&$(options.menu).closest(WRAPPER_SEL).length){$(options.menu).appendTo($body)}} function addInternalSelectors(){container.find(options.sectionSelector).addClass(SECTION);container.find(options.slideSelector).addClass(SLIDE)} function createSlideArrows(section){section.find(SLIDES_WRAPPER_SEL).after('
');if(options.controlArrowColor!='#fff'){section.find(SLIDES_ARROW_NEXT_SEL).css('border-color','transparent transparent transparent '+options.controlArrowColor);section.find(SLIDES_ARROW_PREV_SEL).css('border-color','transparent '+options.controlArrowColor+' transparent transparent')} if(!options.loopHorizontal){section.find(SLIDES_ARROW_PREV_SEL).hide()}} function addVerticalNavigation(){$body.append('
    ');var nav=$(SECTION_NAV_SEL);nav.addClass(function(){return options.showActiveTooltip?SHOW_ACTIVE_TOOLTIP+' '+options.navigationPosition:options.navigationPosition});for(var i=0;i<$(SECTION_SEL).length;i++){var link='';if(options.anchors.length){link=options.anchors[i]} var li='
  • ';var tooltip=options.navigationTooltips[i];if(typeof tooltip!=='undefined'&&tooltip!==''){li+='
    '+tooltip+'
    '} li+='
  • ';nav.find('ul').append(li)} $(SECTION_NAV_SEL).css('margin-top','-'+($(SECTION_NAV_SEL).height()/2)+'px');$(SECTION_NAV_SEL).find('li').eq($(SECTION_ACTIVE_SEL).index(SECTION_SEL)).find('a').addClass(ACTIVE)} function createScrollBarHandler(){$(SECTION_SEL).each(function(){var slides=$(this).find(SLIDE_SEL);if(slides.length){slides.each(function(){createScrollBar($(this))})}else{createScrollBar($(this))}});afterRenderActions()} function enableYoutubeAPI(){container.find('iframe[src*="youtube.com/embed/"]').each(function(){addURLParam($(this),'enablejsapi=1')})} function addURLParam(element,newParam){var originalSrc=element.attr('src');element.attr('src',originalSrc+getUrlParamSign(originalSrc)+newParam)} function getUrlParamSign(url){return(!/\?/.test(url))?'?':'&'} function afterRenderActions(){var section=$(SECTION_ACTIVE_SEL);section.addClass(COMPLETELY);if(options.scrollOverflowHandler.afterRender){options.scrollOverflowHandler.afterRender(section)} lazyLoad(section);playMedia(section);options.scrollOverflowHandler.afterLoad();if(isDestinyTheStartingSection()){$.isFunction(options.afterLoad)&&options.afterLoad.call(section,section.data('anchor'),(section.index(SECTION_SEL)+1))} $.isFunction(options.afterRender)&&options.afterRender.call(container,getTableHeight())} function isDestinyTheStartingSection(){var anchors=window.location.hash.replace('#','').split('index.html');var destinationSection=getSectionByAnchor(decodeURIComponent(anchors[0]));return!destinationSection.length||destinationSection.length&&destinationSection.index()===startingSection.index()} var isScrolling=!1;var lastScroll=0;function scrollHandler(){var currentSection;if(!options.autoScrolling||options.scrollBar){var currentScroll=$window.scrollTop();var scrollDirection=getScrollDirection(currentScroll);var visibleSectionIndex=0;var screen_mid=currentScroll+($window.height()/2.0);var isAtBottom=$body.height()-$window.height()===currentScroll;var sections=document.querySelectorAll(SECTION_SEL);if(isAtBottom){visibleSectionIndex=sections.length-1}else if(!currentScroll){visibleSectionIndex=0}else{for(var i=0;i=($window.scrollTop()+$window.height())} return top<=$window.scrollTop()} function getScrollDirection(currentScroll){var direction=currentScroll>lastScroll?'down':'up';lastScroll=currentScroll;previousDestTop=currentScroll;return direction} function scrolling(type,scrollable){if(!isScrollAllowed.m[type]){return} var check=(type==='down')?'bottom':'top';var scrollSection=(type==='down')?moveSectionDown:moveSectionUp;if(scrollable.length>0){if(options.scrollOverflowHandler.isScrolled(check,scrollable)){scrollSection()}else{return!0}}else{scrollSection()}} function preventBouncing(event){var e=event.originalEvent;if(!checkParentForNormalScrollElement(event.target)&&options.autoScrolling&&isReallyTouch(e)&&isScrollAllowed.m.up){event.preventDefault()}} var touchStartY=0;var touchStartX=0;var touchEndY=0;var touchEndX=0;function touchMoveHandler(event){var e=event.originalEvent;var activeSection=$(e.target).closest(SECTION_SEL);if(!checkParentForNormalScrollElement(event.target)&&isReallyTouch(e)){if(options.autoScrolling){event.preventDefault()} var scrollable=options.scrollOverflowHandler.scrollable(activeSection);var touchEvents=getEventsPage(e);touchEndY=touchEvents.y;touchEndX=touchEvents.x;if(activeSection.find(SLIDES_WRAPPER_SEL).length&&Math.abs(touchStartX-touchEndX)>(Math.abs(touchStartY-touchEndY))){if(!slideMoving&&Math.abs(touchStartX-touchEndX)>($window.outerWidth()/100*options.touchSensitivity)){if(touchStartX>touchEndX){if(isScrollAllowed.m.right){moveSlideRight(activeSection)}}else{if(isScrollAllowed.m.left){moveSlideLeft(activeSection)}}}}else if(options.autoScrolling&&canScroll){if(Math.abs(touchStartY-touchEndY)>($window.height()/100*options.touchSensitivity)){if(touchStartY>touchEndY){scrolling('down',scrollable)}else if(touchEndY>touchStartY){scrolling('up',scrollable)}}}}} function checkParentForNormalScrollElement(el,hop){hop=hop||0;var parent=$(el).parent();if(hop149){scrollings.shift()} scrollings.push(Math.abs(value));if(options.scrollBar){e.preventDefault?e.preventDefault():e.returnValue=!1} var activeSection=$(SECTION_ACTIVE_SEL);var scrollable=options.scrollOverflowHandler.scrollable(activeSection);var timeDiff=curTime-prevTime;prevTime=curTime;if(timeDiff>200){scrollings=[]} if(canScroll){var averageEnd=getAverage(scrollings,10);var averageMiddle=getAverage(scrollings,70);var isAccelerating=averageEnd>=averageMiddle;if(isAccelerating&&isScrollingVertically){if(delta<0){scrolling('down',scrollable)}else{scrolling('up',scrollable)}}} return!1} if(options.fitToSection){$htmlBody.stop()}} function moveSlide(direction,section){var activeSection=typeof section==='undefined'?$(SECTION_ACTIVE_SEL):section;var slides=activeSection.find(SLIDES_WRAPPER_SEL);var numSlides=slides.find(SLIDE_SEL).length;if(!slides.length||slideMoving||numSlides<2){return} var currentSlide=slides.find(SLIDE_ACTIVE_SEL);var destiny=null;if(direction==='left'){destiny=currentSlide.prev(SLIDE_SEL)}else{destiny=currentSlide.next(SLIDE_SEL)} if(!destiny.length){if(!options.loopHorizontal)return;if(direction==='left'){destiny=currentSlide.siblings(':last')}else{destiny=currentSlide.siblings(':first')}} slideMoving=!0;landscapeScroll(slides,destiny,direction)} function keepSlidesPosition(){$(SLIDE_ACTIVE_SEL).each(function(){silentLandscapeScroll($(this),'internal')})} var previousDestTop=0;function getDestinationPosition(element){var elemPosition=element.position();var position=elemPosition.top;var isScrollingDown=elemPosition.top>previousDestTop;var sectionBottom=position-windowsHeight+element.outerHeight();var bigSectionsDestination=options.bigSectionsDestination;var containerH=container.outerHeight();var containerPosition=container.offset();if(!$masthead.hasClass('menu-transparent')&&$('body').hasClass('uncode-fp-menu-shrink')&&!element.is(':first-child')) position+=18;if((containerH+menuHeight+bodyBorder+adminBarHeight-windowsHeight)-1){e.preventDefault()} controlPressed=e.ctrlKey;keydownId=setTimeout(function(){onkeydown(e)},150)}} function tooltipTextHandler(){$(this).prev().trigger('click')} function keyUpHandler(e){if(isWindowFocused){controlPressed=e.ctrlKey}} function mouseDownHandler(e){if(e.which==2){oldPageY=e.pageY;container.on('mousemove',mouseMoveHandler)}} function mouseUpHandler(e){if(e.which==2){container.off('mousemove')}} function slideArrowHandler(){var section=$(this).closest(SECTION_SEL);if($(this).hasClass(SLIDES_PREV)){if(isScrollAllowed.m.left){moveSlideLeft(section)}}else{if(isScrollAllowed.m.right){moveSlideRight(section)}}} function blurHandler(){isWindowFocused=!1;controlPressed=!1} function sectionBulletHandler(e){e.preventDefault();var index=$(this).parent().index();scrollPage($(SECTION_SEL).eq(index))} function slideBulletHandler(e){e.preventDefault();var slides=$(this).closest(SECTION_SEL).find(SLIDES_WRAPPER_SEL);var destiny=slides.find(SLIDE_SEL).eq($(this).closest('li').index());landscapeScroll(slides,destiny)} function onkeydown(e){var shiftPressed=e.shiftKey;if(!canScroll&&[37,39].indexOf(e.which)<0){return} switch(e.which){case 38:case 33:if(isScrollAllowed.k.up){moveSectionUp()} break;case 32:if(shiftPressed&&isScrollAllowed.k.up){moveSectionUp();break} case 40:case 34:if(isScrollAllowed.k.down){moveSectionDown()} break;case 36:if(isScrollAllowed.k.up){moveTo(1)} break;case 35:if(isScrollAllowed.k.down){moveTo($(SECTION_SEL).length)} break;case 37:if(isScrollAllowed.k.left){moveSlideLeft()} break;case 39:if(isScrollAllowed.k.right){moveSlideRight()} break;default:return}} var oldPageY=0;function mouseMoveHandler(e){if(canScroll){if(e.pageYoldPageY&&isScrollAllowed.m.down){moveSectionDown()}} oldPageY=e.pageY} function landscapeScroll(slides,destiny,direction){var section=slides.closest(SECTION_SEL);var v={slides:slides,destiny:destiny,direction:direction,destinyPos:destiny.position(),slideIndex:destiny.index(),section:section,sectionIndex:section.index(SECTION_SEL),anchorLink:section.data('anchor'),slidesNav:section.find(SLIDES_NAV_SEL),slideAnchor:getAnchor(destiny),prevSlide:section.find(SLIDE_ACTIVE_SEL),prevSlideIndex:section.find(SLIDE_ACTIVE_SEL).index(),localIsResizing:isResizing};v.xMovement=getXmovement(v.prevSlideIndex,v.slideIndex);v.direction=v.direction?v.direction:v.xMovement;if(!v.localIsResizing){canScroll=!1} if(options.onSlideLeave){if(!v.localIsResizing&&v.xMovement!=='none'){if($.isFunction(options.onSlideLeave)){if(options.onSlideLeave.call(v.prevSlide,v.anchorLink,(v.sectionIndex+1),v.prevSlideIndex,v.xMovement,v.slideIndex)===!1){slideMoving=!1;return}}}} destiny.addClass(ACTIVE).siblings().removeClass(ACTIVE);if(!v.localIsResizing){stopMedia(v.prevSlide);lazyLoad(destiny)} if(!options.loopHorizontal&&options.controlArrows){section.find(SLIDES_ARROW_PREV_SEL).toggle(v.slideIndex!==0);section.find(SLIDES_ARROW_NEXT_SEL).toggle(!destiny.is(':last-child'))} if(section.hasClass(ACTIVE)&&!v.localIsResizing){setState(v.slideIndex,v.slideAnchor,v.anchorLink,v.sectionIndex)} performHorizontalMove(slides,v,!0)} function afterSlideLoads(v){activeSlidesNavigation(v.slidesNav,v.slideIndex);if(!v.localIsResizing){$.isFunction(options.afterSlideLoad)&&options.afterSlideLoad.call(v.destiny,v.anchorLink,(v.sectionIndex+1),v.slideAnchor,v.slideIndex);canScroll=!0;playMedia(v.destiny)} slideMoving=!1} function performHorizontalMove(slides,v,fireCallback){var destinyPos=v.destinyPos;if(options.css3){var translate3d='translate3d(-'+Math.round(destinyPos.left)+'px, 0px, 0px)';addAnimation(slides.find(SLIDES_CONTAINER_SEL)).css(getTransforms(translate3d),v);afterSlideLoadsId=setTimeout(function(){fireCallback&&afterSlideLoads(v)},options.scrollingSpeed,options.easing)}else{slides.animate({scrollLeft:Math.round(destinyPos.left)},options.scrollingSpeed,options.easing,function(){fireCallback&&afterSlideLoads(v)})}} function activeSlidesNavigation(slidesNav,slideIndex){slidesNav.find(ACTIVE_SEL).removeClass(ACTIVE);slidesNav.find('li').eq(slideIndex).find('a').addClass(ACTIVE)} var previousHeight=windowsHeight;function resizeHandler(){responsive();if(isTouchDevice){var activeElement=$(document.activeElement);if(!activeElement.is('textarea')&&!activeElement.is('input')&&!activeElement.is('select')){var currentHeight=$window.height();if(Math.abs(currentHeight-previousHeight)>(20*Math.max(previousHeight,currentHeight)/100)){reBuild(!0);previousHeight=currentHeight}}}else{clearTimeout(resizeId);resizeId=setTimeout(function(){reBuild(!0)},350)}} function responsive(){var widthLimit=options.responsive||options.responsiveWidth;var heightLimit=options.responsiveHeight;var isBreakingPointWidth=widthLimit&&$window.outerWidth()toIndex){return'up'} return'down'} function getXmovement(fromIndex,toIndex){if(fromIndex==toIndex){return'none'} if(fromIndex>toIndex){return'left'} return'right'} function createScrollBar(element){if(element.hasClass('fp-noscroll'))return;element.css('overflow','hidden');var scrollOverflowHandler=options.scrollOverflowHandler;var wrap=scrollOverflowHandler.wrapContent();var section=element.closest(SECTION_SEL);var scrollable=scrollOverflowHandler.scrollable(element);var contentHeight;if(scrollable.length){contentHeight=scrollOverflowHandler.scrollHeight(element)}else{contentHeight=element.get(0).scrollHeight;if(options.verticalCentered){contentHeight=element.find(TABLE_CELL_SEL).get(0).scrollHeight}} var scrollHeight=windowsHeight-parseInt(section.css('padding-bottom'))-parseInt(section.css('padding-top'));if(contentHeight>scrollHeight){if(scrollable.length){scrollOverflowHandler.update(element,scrollHeight)}else{if(options.verticalCentered){element.find(TABLE_CELL_SEL).wrapInner(wrap)}else{element.wrapInner(wrap)} scrollOverflowHandler.create(element,scrollHeight)}}else{scrollOverflowHandler.remove(element)} element.css('overflow','')} function addTableClass(element){if(!element.hasClass(TABLE)){element.addClass(TABLE).wrapInner('
    ')}} function getTableHeight(element){var sectionHeight=windowsHeight;if(options.paddingTop||options.paddingBottom){var section=element;if(!section.hasClass(SECTION)){section=element.closest(SECTION_SEL)} var paddings=parseInt(section.css('padding-top'))+parseInt(section.css('padding-bottom'));sectionHeight=(windowsHeight-paddings)} return sectionHeight} function transformContainer(translate3d,animated){if(animated){addAnimation(container)}else{removeAnimation(container)} container.css(getTransforms(translate3d));setTimeout(function(){container.removeClass(NO_TRANSITION)},10)} function getSectionByAnchor(sectionAnchor){if(!sectionAnchor)return[];var section=container.find(SECTION_SEL+'[data-anchor="'+sectionAnchor+'"]');if(!section.length){section=$(SECTION_SEL).eq(sectionAnchor-1)} return section} function getSlideByAnchor(slideAnchor,section){var slides=section.find(SLIDES_WRAPPER_SEL);var slide=slides.find(SLIDE_SEL+'[data-anchor="'+slideAnchor+'"]');if(!slide.length){slide=slides.find(SLIDE_SEL).eq(slideAnchor)} return slide} function scrollPageAndSlide(destiny,slide){var section=getSectionByAnchor(destiny);if(!section.length)return;if(typeof slide==='undefined'){slide=0} if(destiny!==lastScrolledDestiny&&!section.hasClass(ACTIVE)){scrollPage(section,function(){scrollSlider(section,slide)})}else{scrollSlider(section,slide)}} function scrollSlider(section,slideAnchor){if(typeof slideAnchor!=='undefined'){var slides=section.find(SLIDES_WRAPPER_SEL);var destiny=getSlideByAnchor(slideAnchor,section);if(destiny.length){landscapeScroll(slides,destiny)}}} function addSlidesNavigation(section,numSlides){section.append('
      ');var nav=section.find(SLIDES_NAV_SEL);nav.addClass(options.slidesNavPosition);for(var i=0;i')} nav.css('margin-left','-'+(nav.width()/2)+'px');nav.find('li').first().find('a').addClass(ACTIVE)} function setState(slideIndex,slideAnchor,anchorLink,sectionIndex){var sectionHash='';if(options.anchors.length&&!options.lockAnchors){if(slideIndex){if(typeof anchorLink!=='undefined'){sectionHash=anchorLink} if(typeof slideAnchor==='undefined'){slideAnchor=slideIndex} lastScrolledSlide=slideAnchor;setUrlHash(sectionHash+'/'+slideAnchor)}else if(typeof slideIndex!=='undefined'){lastScrolledSlide=slideAnchor;setUrlHash(anchorLink)}else{setUrlHash(anchorLink)}} setBodyClass()} function setUrlHash(url){if(typeof SiteParameters.slide_footer!='undefined'&&url==SiteParameters.slide_footer) return!1;if(options.recordHistory){location.hash=url}else{return!1}} function getAnchor(element){var anchor=element.data('anchor');var index=element.index();if(typeof anchor==='undefined'){anchor=index} return anchor} function setBodyClass(){var section=$(SECTION_ACTIVE_SEL);var slide=section.find(SLIDE_ACTIVE_SEL);var sectionAnchor=getAnchor(section);var slideAnchor=getAnchor(slide);var text=String(sectionAnchor);if(slide.length){text=text+'-'+slideAnchor} text=text.replace('index.html','-').replace('#','');var classRe=new RegExp('\\b\\s?'+VIEWING_PREFIX+'-[^\\s]+\\b',"g");$body[0].className=$body[0].className.replace(classRe,'');$body.addClass(VIEWING_PREFIX+'-'+text)} function support3d(){var el=document.createElement('p'),has3d,transforms={'webkitTransform':'-webkit-transform','OTransform':'-o-transform','msTransform':'-ms-transform','MozTransform':'-moz-transform','transform':'transform'};document.body.insertBefore(el,null);for(var t in transforms){if(el.style[t]!==undefined){el.style[t]='translate3d(1px,1px,1px)';has3d=window.getComputedStyle(el).getPropertyValue(transforms[t])}} document.body.removeChild(el);return(has3d!==undefined&&has3d.length>0&&has3d!=='none')} function removeMouseWheelHandler(){if(document.addEventListener){document.removeEventListener('mousewheel',MouseWheelHandler,!1);document.removeEventListener('wheel',MouseWheelHandler,!1);document.removeEventListener('MozMousePixelScroll',MouseWheelHandler,!1)}else{document.detachEvent('onmousewheel',MouseWheelHandler)}} function addMouseWheelHandler(){var prefix='';var _addEventListener;if(window.addEventListener){_addEventListener="addEventListener"}else{_addEventListener="attachEvent";prefix='on'} var support='onwheel' in document.createElement('div')?'wheel':document.onmousewheel!==undefined?'mousewheel':'DOMMouseScroll';var passiveEvent=g_supportsPassive?{passive:!1}:!1;if(support=='DOMMouseScroll'){document[_addEventListener](prefix+'MozMousePixelScroll',MouseWheelHandler,passiveEvent)}else{document[_addEventListener](prefix+support,MouseWheelHandler,passiveEvent)}} function addMiddleWheelHandler(){container.on('mousedown',mouseDownHandler).on('mouseup',mouseUpHandler)} function removeMiddleWheelHandler(){container.off('mousedown',mouseDownHandler).off('mouseup',mouseUpHandler)} function addTouchHandler(){if(isTouchDevice||isTouch){if(options.autoScrolling){$body.off(events.touchmove).on(events.touchmove,preventBouncing)} $(WRAPPER_SEL).off(events.touchstart).on(events.touchstart,touchStartHandler).off(events.touchmove).on(events.touchmove,touchMoveHandler)}} function removeTouchHandler(){if(isTouchDevice||isTouch){$(WRAPPER_SEL).off(events.touchstart).off(events.touchmove)}} function getMSPointer(){var pointer;if(window.PointerEvent){pointer={down:'pointerdown',move:'pointermove'}}else{pointer={down:'MSPointerDown',move:'MSPointerMove'}} return pointer} function getEventsPage(e){var events=[];events.y=(typeof e.pageY!=='undefined'&&(e.pageY||e.pageX)?e.pageY:e.touches[0].pageY);events.x=(typeof e.pageX!=='undefined'&&(e.pageY||e.pageX)?e.pageX:e.touches[0].pageX);if(isTouch&&isReallyTouch(e)&&options.scrollBar){events.y=e.touches[0].pageY;events.x=e.touches[0].pageX} return events} function silentLandscapeScroll(activeSlide,noCallbacks){setScrollingSpeed(0,'internal');if(typeof noCallbacks!=='undefined'){isResizing=!0} landscapeScroll(activeSlide.closest(SLIDES_WRAPPER_SEL),activeSlide);if(typeof noCallbacks!=='undefined'){isResizing=!1} setScrollingSpeed(originals.scrollingSpeed,'internal')} function silentScroll(top){var roundedTop=Math.round(top);if(options.css3&&options.autoScrolling&&!options.scrollBar){var translate3d='translate3d(0px, -'+roundedTop+'px, 0px)';transformContainer(translate3d,!1)}else if(options.autoScrolling&&!options.scrollBar){container.css('top',-roundedTop)}else{$htmlBody.scrollTop(roundedTop)}} function getTransforms(translate3d){return{'-webkit-transform':translate3d,'-moz-transform':translate3d,'-ms-transform':translate3d,'transform':translate3d}} function setIsScrollAllowed(value,direction,type){switch(direction){case 'up':isScrollAllowed[type].up=value;break;case 'down':isScrollAllowed[type].down=value;break;case 'left':isScrollAllowed[type].left=value;break;case 'right':isScrollAllowed[type].right=value;break;case 'all':if(type=='m'){setAllowScrolling(value)}else{setKeyboardScrolling(value)}}} function destroy(all){setAutoScrolling(!1,'internal');setAllowScrolling(!1);setKeyboardScrolling(!1);container.addClass(DESTROYED);clearTimeout(afterSlideLoadsId);clearTimeout(afterSectionLoadsId);clearTimeout(resizeId);clearTimeout(scrollId);clearTimeout(scrollId2);$window.off('scroll',scrollHandler).off('hashchange',hashChangeHandler).off('resize',resizeHandler);$document.off('click touchstart',SECTION_NAV_SEL+' a').off('mouseenter',SECTION_NAV_SEL+' li').off('mouseleave',SECTION_NAV_SEL+' li').off('click touchstart',SLIDES_NAV_LINK_SEL).off('mouseover',options.normalScrollElements).off('mouseout',options.normalScrollElements);$(SECTION_SEL).off('click touchstart',SLIDES_ARROW_SEL);clearTimeout(afterSlideLoadsId);clearTimeout(afterSectionLoadsId);if(all){destroyStructure()}} function destroyStructure(){silentScroll(0);container.find('img[data-src], source[data-src], audio[data-src], iframe[data-src]').each(function(){setSrc($(this),'src')});container.find('img[data-srcset]').each(function(){setSrc($(this),'srcset')});$(SECTION_NAV_SEL+', '+SLIDES_NAV_SEL+', '+SLIDES_ARROW_SEL).remove();$(SECTION_SEL).css({'height':'','background-color':'','padding':''});$(SLIDE_SEL).css({'width':''});container.css({'height':'','position':'','-ms-touch-action':'','touch-action':''});$htmlBody.css({'overflow':'','height':''});$('html').removeClass(ENABLED);$body.removeClass(RESPONSIVE);$.each($body.get(0).className.split(/\s+/),function(index,className){if(className.indexOf(VIEWING_PREFIX)===0){$body.removeClass(className)}});$(SECTION_SEL+', '+SLIDE_SEL).each(function(){options.scrollOverflowHandler.remove($(this));$(this).removeClass(TABLE+' '+ACTIVE)});removeAnimation(container);container.find(TABLE_CELL_SEL+', '+SLIDES_CONTAINER_SEL+', '+SLIDES_WRAPPER_SEL).each(function(){$(this).replaceWith(this.childNodes)});container.css({'-webkit-transition':'none','transition':'none'});$htmlBody.scrollTop(0);var usedSelectors=[SECTION,SLIDE,SLIDES_CONTAINER];$.each(usedSelectors,function(index,value){$('.'+value).removeClass(value)})} function setVariableState(variable,value,type){options[variable]=value;if(type!=='internal'){originals[variable]=value}} function displayWarnings(){var extensions=['fadingEffect','continuousHorizontal','scrollHorizontally','interlockedSlides','resetSliders','responsiveSlides','offsetSections','dragAndMove','scrollOverflowReset','parallax'];$.each(extensions,function(index,extension){if(options[extension]){showError('warn','fullpage.js extensions require jquery.fullpage.extensions.min.js file instead of the usual jquery.fullpage.js. Requested: '+extension)}});$.each(options.anchors,function(index,name){var nameAttr=$document.find('[name]').filter(function(){return $(this).attr('name')&&$(this).attr('name').toLowerCase()==name.toLowerCase()});var idAttr=$document.find('[id]').filter(function(){return $(this).attr('id')&&$(this).attr('id').toLowerCase()==name.toLowerCase()});if(idAttr.length||nameAttr.length){showError('error','data-anchor tags can not have the same value as any `id` element on the site (or `name` element for IE).');idAttr.length&&showError('error','"'+name+'" is is being used by another element `id` property');nameAttr.length&&showError('error','"'+name+'" is is being used by another element `name` property')}})} function showError(type,text){console&&console[type]&&console[type]('fullPage: '+text)}};if(typeof IScroll!=='undefined'){IScroll.prototype.wheelOn=function(){this.wrapper.addEventListener('wheel',this);this.wrapper.addEventListener('mousewheel',this);this.wrapper.addEventListener('DOMMouseScroll',this)};IScroll.prototype.wheelOff=function(){this.wrapper.removeEventListener('wheel',this);this.wrapper.removeEventListener('mousewheel',this);this.wrapper.removeEventListener('DOMMouseScroll',this)}} var iscrollHandler={refreshId:null,iScrollInstances:[],toggleWheel:function(value){var scrollable=$(SECTION_ACTIVE_SEL).find(SCROLLABLE_SEL);scrollable.each(function(){var iScrollInstance=$(this).data('iscrollInstance');if(typeof iScrollInstance!=='undefined'&&iScrollInstance){if(value){iScrollInstance.wheelOn()}else{iScrollInstance.wheelOff()}}})},onLeave:function(){iscrollHandler.toggleWheel(!1)},beforeLeave:function(){iscrollHandler.onLeave()},afterLoad:function(){iscrollHandler.toggleWheel(!0)},create:function(element,scrollHeight){var scrollable=element.find(SCROLLABLE_SEL);scrollable.height(scrollHeight);scrollable.each(function(){var $this=$(this);var iScrollInstance=$this.data('iscrollInstance');if(iScrollInstance){$.each(iscrollHandler.iScrollInstances,function(){$(this).destroy()})} iScrollInstance=new IScroll($this.get(0),iscrollOptions);iscrollHandler.iScrollInstances.push(iScrollInstance);iScrollInstance.wheelOff();$this.data('iscrollInstance',iScrollInstance)})},isScrolled:function(type,scrollable){var scroller=scrollable.data('iscrollInstance');if(!scroller){return!0} var uncode_body_borders=parseFloat($('.body-borders').attr('data-border'))||0;if(type==='top'){return scroller.y>=0&&!scrollable.scrollTop()}else if(type==='bottom'){return(0-scroller.y)+scrollable.scrollTop()+1+(uncode_body_borders*2)+scrollable.innerHeight()>=scrollable[0].scrollHeight}},scrollable:function(activeSection){if(activeSection.find(SLIDES_WRAPPER_SEL).length){return activeSection.find(SLIDE_ACTIVE_SEL).find(SCROLLABLE_SEL)} return activeSection.find(SCROLLABLE_SEL)},scrollHeight:function(element){return element.find(SCROLLABLE_SEL).children().first().get(0).scrollHeight},remove:function(element){var scrollable=element.find(SCROLLABLE_SEL);if(scrollable.length){var iScrollInstance=scrollable.data('iscrollInstance');iScrollInstance.destroy();scrollable.data('iscrollInstance',null)} element.find(SCROLLABLE_SEL).children().first().children().first().unwrap().unwrap()},update:function(element,scrollHeight){clearTimeout(iscrollHandler.refreshId);iscrollHandler.refreshId=setTimeout(function(){$.each(iscrollHandler.iScrollInstances,function(){$(this).get(0).refresh()})},150);element.find(SCROLLABLE_SEL).css('height',scrollHeight+'px').parent().css('height',scrollHeight+'px')},wrapContent:function(){return'
      '}}});(function(global,factory){typeof exports==='object'&&typeof module!=='undefined'?factory(exports):typeof define==='function'&&define.amd?define(['exports'],factory):(global=global||self,factory(global.window=global.window||{}))}(this,(function(exports){'use strict';/*! * ScrollTrigger 3.8.0 * https://greensock.com * * @license Copyright 2008-2021, GreenSock. All rights reserved. * Subject to the terms at https://greensock.com/standard-license or for * Club GreenSock members, the agreement issued with that membership. * @author: Jack Doyle, jack@greensock.com */ var gsap,_coreInitted,_win,_doc,_docEl,_body,_root,_resizeDelay,_raf,_request,_toArray,_clamp,_time2,_syncInterval,_refreshing,_pointerIsDown,_transformProp,_i,_prevWidth,_prevHeight,_autoRefresh,_sort,_suppressOverwrites,_ignoreResize,_limitCallbacks,_startup=1,_proxies=[],_scrollers=[],_getTime=Date.now,_time1=_getTime(),_lastScrollTime=0,_enabled=1,_passThrough=function _passThrough(v){return v},_getTarget=function _getTarget(t){return _toArray(t)[0]||(_isString(t)?console.warn("Element not found:",t):null)},_round=function _round(value){return Math.round(value*100000)/100000||0},_windowExists=function _windowExists(){return typeof window!=="undefined"},_getGSAP=function _getGSAP(){return gsap||_windowExists()&&(gsap=window.gsap)&&gsap.registerPlugin&&gsap},_isViewport=function _isViewport(e){return!!~_root.indexOf(e)},_getProxyProp=function _getProxyProp(element,property){return~_proxies.indexOf(element)&&_proxies[_proxies.indexOf(element)+1][property]},_getScrollFunc=function _getScrollFunc(element,_ref){var s=_ref.s,sc=_ref.sc;var i=_scrollers.indexOf(element),offset=sc===_vertical.sc?1:2;!~i&&(i=_scrollers.push(element)-1);return _scrollers[i+offset]||(_scrollers[i+offset]=_getProxyProp(element,s)||(_isViewport(element)?sc:function(value){return arguments.length?element[s]=value:element[s]}))},_getBoundsFunc=function _getBoundsFunc(element){return _getProxyProp(element,"getBoundingClientRect")||(_isViewport(element)?function(){_winOffsets.width=_win.innerWidth;_winOffsets.height=_win.innerHeight;return _winOffsets}:function(){return _getBounds(element)})},_getSizeFunc=function _getSizeFunc(scroller,isViewport,_ref2){var d=_ref2.d,d2=_ref2.d2,a=_ref2.a;return(a=_getProxyProp(scroller,"getBoundingClientRect"))?function(){return a()[d]}:function(){return(isViewport?_win["inner"+d2]:scroller["client"+d2])||0}},_getOffsetsFunc=function _getOffsetsFunc(element,isViewport){return!isViewport||~_proxies.indexOf(element)?_getBoundsFunc(element):function(){return _winOffsets}},_maxScroll=function _maxScroll(element,_ref3){var s=_ref3.s,d2=_ref3.d2,d=_ref3.d,a=_ref3.a;return(s="scroll"+d2)&&(a=_getProxyProp(element,s))?a()-_getBoundsFunc(element)()[d]:_isViewport(element)?(_body[s]||_docEl[s])-(_win["inner"+d2]||_docEl["client"+d2]||_body["client"+d2]):element[s]-element["offset"+d2]},_iterateAutoRefresh=function _iterateAutoRefresh(func,events){for(var i=0;i<_autoRefresh.length;i+=3){(!events||~events.indexOf(_autoRefresh[i+1]))&&func(_autoRefresh[i],_autoRefresh[i+1],_autoRefresh[i+2])}},_isString=function _isString(value){return typeof value==="string"},_isFunction=function _isFunction(value){return typeof value==="function"},_isNumber=function _isNumber(value){return typeof value==="number"},_isObject=function _isObject(value){return typeof value==="object"},_callIfFunc=function _callIfFunc(value){return _isFunction(value)&&value()},_combineFunc=function _combineFunc(f1,f2){return function(){var result1=_callIfFunc(f1),result2=_callIfFunc(f2);return function(){_callIfFunc(result1);_callIfFunc(result2)}}},_endAnimation=function _endAnimation(animation,reversed,pause){return animation&&animation.progress(reversed?0:1)&&pause&&animation.pause()},_callback=function _callback(self,func){var result=func(self);result&&result.totalTime&&(self.callbackAnimation=result)},_abs=Math.abs,_scrollLeft="scrollLeft",_scrollTop="scrollTop",_left="left",_top="top",_right="right",_bottom="bottom",_width="width",_height="height",_Right="Right",_Left="Left",_Top="Top",_Bottom="Bottom",_padding="padding",_margin="margin",_Width="Width",_Height="Height",_px="px",_horizontal={s:_scrollLeft,p:_left,p2:_Left,os:_right,os2:_Right,d:_width,d2:_Width,a:"x",sc:function sc(value){return arguments.length?_win.scrollTo(value,_vertical.sc()):_win.pageXOffset||_doc[_scrollLeft]||_docEl[_scrollLeft]||_body[_scrollLeft]||0}},_vertical={s:_scrollTop,p:_top,p2:_Top,os:_bottom,os2:_Bottom,d:_height,d2:_Height,a:"y",op:_horizontal,sc:function sc(value){return arguments.length?_win.scrollTo(_horizontal.sc(),value):_win.pageYOffset||_doc[_scrollTop]||_docEl[_scrollTop]||_body[_scrollTop]||0}},_getComputedStyle=function _getComputedStyle(element){return _win.getComputedStyle(element)},_makePositionable=function _makePositionable(element){var position=_getComputedStyle(element).position;element.style.position=position==="absolute"||position==="fixed"?position:"relative"},_setDefaults=function _setDefaults(obj,defaults){for(var p in defaults){p in obj||(obj[p]=defaults[p])} return obj},_getBounds=function _getBounds(element,withoutTransforms){var tween=withoutTransforms&&_getComputedStyle(element)[_transformProp]!=="matrix(1, 0, 0, 1, 0, 0)"&&gsap.to(element,{x:0,y:0,xPercent:0,yPercent:0,rotation:0,rotationX:0,rotationY:0,scale:1,skewX:0,skewY:0}).progress(1),bounds=element.getBoundingClientRect();tween&&tween.progress(0).kill();return bounds},_getSize=function _getSize(element,_ref4){var d2=_ref4.d2;return element["offset"+d2]||element["client"+d2]||0},_getLabelRatioArray=function _getLabelRatioArray(timeline){var a=[],labels=timeline.labels,duration=timeline.duration(),p;for(p in labels){a.push(labels[p]/duration)} return a},_getClosestLabel=function _getClosestLabel(animation){return function(value){return gsap.utils.snap(_getLabelRatioArray(animation),value)}},_snapDirectional=function _snapDirectional(snapIncrementOrArray){var snap=gsap.utils.snap(snapIncrementOrArray),a=Array.isArray(snapIncrementOrArray)&&snapIncrementOrArray.slice(0).sort(function(a,b){return a-b});return a?function(value,direction){var i;if(!direction){return snap(value)} if(direction>0){value-=1e-4;for(i=0;i=value){return a[i]}} return a[i-1]}else{i=a.length;value+=1e-4;while(i--){if(a[i]<=value){return a[i]}}} return a[0]}:function(value,direction){var snapped=snap(value);return!direction||Math.abs(snapped-value)<0.001||snapped-value<0===direction<0?snapped:snap(direction<0?value-snapIncrementOrArray:value+snapIncrementOrArray)}},_getLabelAtDirection=function _getLabelAtDirection(timeline){return function(value,st){return _snapDirectional(_getLabelRatioArray(timeline))(value,st.direction)}},_multiListener=function _multiListener(func,element,types,callback){return types.split(",").forEach(function(type){return func(element,type,callback)})},_addListener=function _addListener(element,type,func){return element.addEventListener(type,func,{passive:!0})},_removeListener=function _removeListener(element,type,func){return element.removeEventListener(type,func)},_markerDefaults={startColor:"green",endColor:"red",indent:0,fontSize:"16px",fontWeight:"normal"},_defaults={toggleActions:"play",anticipatePin:0},_keywords={top:0,left:0,center:0.5,bottom:1,right:1},_offsetToPx=function _offsetToPx(value,size){if(_isString(value)){var eqIndex=value.indexOf("="),relative=~eqIndex?+(value.charAt(eqIndex-1)+1)*parseFloat(value.substr(eqIndex+1)):0;if(~eqIndex){value.indexOf("%")>eqIndex&&(relative*=size/100);value=value.substr(0,eqIndex-1)} value=relative+(value in _keywords?_keywords[value]*size:~value.indexOf("%")?parseFloat(value)*size/100:parseFloat(value)||0)} return value},_createMarker=function _createMarker(type,name,container,direction,_ref5,offset,matchWidthEl,containerAnimation){var startColor=_ref5.startColor,endColor=_ref5.endColor,fontSize=_ref5.fontSize,indent=_ref5.indent,fontWeight=_ref5.fontWeight;var e=_doc.createElement("div"),useFixedPosition=_isViewport(container)||_getProxyProp(container,"pinType")==="fixed",isScroller=type.indexOf("scroller")!==-1,parent=useFixedPosition?_body:container,isStart=type.indexOf("start")!==-1,color=isStart?startColor:endColor,css="border-color:"+color+";font-size:"+fontSize+";color:"+color+";font-weight:"+fontWeight+";pointer-events:none;white-space:nowrap;font-family:sans-serif,Arial;z-index:1000;padding:4px 8px;border-width:0;border-style:solid;";css+="position:"+((isScroller||containerAnimation)&&useFixedPosition?"fixed;":"absolute;");(isScroller||containerAnimation||!useFixedPosition)&&(css+=(direction===_vertical?_right:_bottom)+":"+(offset+parseFloat(indent))+"px;");matchWidthEl&&(css+="box-sizing:border-box;text-align:left;width:"+matchWidthEl.offsetWidth+"px;");e._isStart=isStart;e.setAttribute("class","gsap-marker-"+type+(name?" marker-"+name:""));e.style.cssText=css;e.innerText=name||name===0?type+"-"+name:type;parent.children[0]?parent.insertBefore(e,parent.children[0]):parent.appendChild(e);e._offset=e["offset"+direction.op.d2];_positionMarker(e,0,direction,isStart);return e},_positionMarker=function _positionMarker(marker,start,direction,flipped){var vars={display:"block"},side=direction[flipped?"os2":"p2"],oppositeSide=direction[flipped?"p2":"os2"];marker._isFlipped=flipped;vars[direction.a+"Percent"]=flipped?-100:0;vars[direction.a]=flipped?"1px":0;vars["border"+side+_Width]=1;vars["border"+oppositeSide+_Width]=0;vars[direction.p]=start+"px";gsap.set(marker,vars)},_triggers=[],_ids={},_sync=function _sync(){return _getTime()-_lastScrollTime>20&&_updateAll()},_onScroll=function _onScroll(){var time=_getTime();if(_lastScrollTime!==time){_updateAll();_lastScrollTime||_dispatch("scrollStart");_lastScrollTime=time}else if(!_request){_request=_raf(_updateAll)}},_onResize=function _onResize(){return!_refreshing&&!_ignoreResize&&!_doc.fullscreenElement&&_resizeDelay.restart(!0)},_listeners={},_emptyArray=[],_media=[],_creatingMedia,_lastMediaTick,_onMediaChange=function _onMediaChange(e){var tick=gsap.ticker.frame,matches=[],i=0,index;if(_lastMediaTick!==tick||_startup){_revertAll();for(;i<_media.length;i+=4){index=_win.matchMedia(_media[i]).matches;if(index!==_media[i+3]){_media[i+3]=index;index?matches.push(i):_revertAll(1,_media[i])||_isFunction(_media[i+2])&&_media[i+2]()}} _revertRecorded();for(i=0;i=50,scroll=l&&_triggers[0].scroll();_direction=_lastScroll>scroll?-1:1;_lastScroll=scroll;if(recordVelocity){if(_lastScrollTime&&!_pointerIsDown&&time-_lastScrollTime>200){_lastScrollTime=0;_dispatch("scrollEnd")} _time2=_time1;_time1=time} if(_direction<0){_i=l;while(_i-->0){_triggers[_i]&&_triggers[_i].update(0,recordVelocity)} _direction=1}else{for(_i=0;_i20);scrollerSize-=scrollerSize-globalOffset}else if(markerScroller){_positionMarker(markerScroller,scrollerSize,direction,!0)} if(marker){var position=value+scrollerSize,isStart=marker._isStart;p1="scroll"+direction.d2;_positionMarker(marker,position,direction,isStart&&position>20||!isStart&&(useFixedPosition?Math.max(_body[p1],_docEl[p1]):marker.parentNode[p1])<=position+1);if(useFixedPosition){scrollerBounds=_getBounds(markerScroller);useFixedPosition&&(marker.style[direction.op.p]=scrollerBounds[direction.op.p]-direction.op.m-marker._offset+_px)}} if(containerAnimation&&element){p1=_getBounds(element);containerAnimation.seek(scrollerMax);p2=_getBounds(element);containerAnimation._caScrollDist=p1[direction.p]-p2[direction.p];value=value/containerAnimation._caScrollDist*scrollerMax} containerAnimation&&containerAnimation.seek(time);return containerAnimation?value:Math.round(value)},_prefixExp=/(?:webkit|moz|length|cssText|inset)/i,_reparent=function _reparent(element,parent,top,left){if(element.parentNode!==parent){var style=element.style,p,cs;if(parent===_body){element._stOrig=style.cssText;cs=_getComputedStyle(element);for(p in cs){if(!+p&&!_prefixExp.test(p)&&cs[p]&&typeof style[p]==="string"&&p!=="0"){style[p]=cs[p]}} style.top=top;style.left=left}else{style.cssText=element._stOrig} gsap.core.getCache(element).uncache=1;parent.appendChild(element)}},_getTweenCreator=function _getTweenCreator(scroller,direction){var getScroll=_getScrollFunc(scroller,direction),prop="_scroll"+direction.p2,lastScroll1,lastScroll2,getTween=function getTween(scrollTo,vars,initialValue,change1,change2){var tween=getTween.tween,onComplete=vars.onComplete,modifiers={};tween&&tween.kill();lastScroll1=Math.round(initialValue);vars[prop]=scrollTo;vars.modifiers=modifiers;modifiers[prop]=function(value){value=_round(getScroll());if(value!==lastScroll1&&value!==lastScroll2&&Math.abs(value-lastScroll1)>2){tween.kill();getTween.tween=0}else{value=initialValue+change1*tween.ratio+change2*tween.ratio*tween.ratio} lastScroll2=lastScroll1;return lastScroll1=_round(value)};vars.onComplete=function(){getTween.tween=0;onComplete&&onComplete.call(tween)};tween=getTween.tween=gsap.to(scroller,vars);return tween};scroller[prop]=getScroll;scroller.addEventListener("wheel",function(){return getTween.tween&&getTween.tween.kill()&&(getTween.tween=0)},{passive:!0});return getTween};_horizontal.op=_vertical;var ScrollTrigger=function(){function ScrollTrigger(vars,animation){_coreInitted||ScrollTrigger.register(gsap)||console.warn("Please gsap.registerPlugin(ScrollTrigger)");this.init(vars,animation)} var _proto=ScrollTrigger.prototype;_proto.init=function init(vars,animation){this.progress=this.start=0;this.vars&&this.kill(1);if(!_enabled){this.update=this.refresh=this.kill=_passThrough;return} vars=_setDefaults(_isString(vars)||_isNumber(vars)||vars.nodeType?{trigger:vars}:vars,_defaults);var _vars=vars,onUpdate=_vars.onUpdate,toggleClass=_vars.toggleClass,id=_vars.id,onToggle=_vars.onToggle,onRefresh=_vars.onRefresh,scrub=_vars.scrub,trigger=_vars.trigger,pin=_vars.pin,pinSpacing=_vars.pinSpacing,invalidateOnRefresh=_vars.invalidateOnRefresh,anticipatePin=_vars.anticipatePin,onScrubComplete=_vars.onScrubComplete,onSnapComplete=_vars.onSnapComplete,once=_vars.once,snap=_vars.snap,pinReparent=_vars.pinReparent,pinSpacer=_vars.pinSpacer,containerAnimation=_vars.containerAnimation,fastScrollEnd=_vars.fastScrollEnd,preventOverlaps=_vars.preventOverlaps,direction=vars.horizontal||vars.containerAnimation&&vars.horizontal!==!1?_horizontal:_vertical,isToggle=!scrub&&scrub!==0,scroller=_getTarget(vars.scroller||_win),scrollerCache=gsap.core.getCache(scroller),isViewport=_isViewport(scroller),useFixedPosition=("pinType" in vars?vars.pinType:_getProxyProp(scroller,"pinType")||isViewport&&"fixed")==="fixed",callbacks=[vars.onEnter,vars.onLeave,vars.onEnterBack,vars.onLeaveBack],toggleActions=isToggle&&vars.toggleActions.split(" "),markers="markers" in vars?vars.markers:_defaults.markers,borderWidth=isViewport?0:parseFloat(_getComputedStyle(scroller)["border"+direction.p2+_Width])||0,self=this,onRefreshInit=vars.onRefreshInit&&function(){return vars.onRefreshInit(self)},getScrollerSize=_getSizeFunc(scroller,isViewport,direction),getScrollerOffsets=_getOffsetsFunc(scroller,isViewport),lastSnap=0,scrollFunc=_getScrollFunc(scroller,direction),tweenTo,pinCache,snapFunc,scroll1,scroll2,start,end,markerStart,markerEnd,markerStartTrigger,markerEndTrigger,markerVars,change,pinOriginalState,pinActiveState,pinState,spacer,offset,pinGetter,pinSetter,pinStart,pinChange,spacingStart,spacerState,markerStartSetter,markerEndSetter,cs,snap1,snap2,scrubTween,scrubSmooth,snapDurClamp,snapDelayedCall,prevProgress,prevScroll,prevAnimProgress,caMarkerSetter;self.media=_creatingMedia;anticipatePin*=45;self.scroller=scroller;self.scroll=containerAnimation?containerAnimation.time.bind(containerAnimation):scrollFunc;scroll1=scrollFunc();self.vars=vars;animation=animation||vars.animation;"refreshPriority" in vars&&(_sort=1);scrollerCache.tweenScroll=scrollerCache.tweenScroll||{top:_getTweenCreator(scroller,_vertical),left:_getTweenCreator(scroller,_horizontal)};self.tweenTo=tweenTo=scrollerCache.tweenScroll[direction.p];if(animation){animation.vars.lazy=!1;animation._initted||animation.vars.immediateRender!==!1&&vars.immediateRender!==!1&&animation.render(0,!0,!0);self.animation=animation.pause();animation.scrollTrigger=self;scrubSmooth=_isNumber(scrub)&&scrub;scrubSmooth&&(scrubTween=gsap.to(animation,{ease:"power3",duration:scrubSmooth,onComplete:function onComplete(){return onScrubComplete&&onScrubComplete(self)}}));snap1=0;id||(id=animation.vars.id)} _triggers.push(self);if(snap){if(!_isObject(snap)||snap.push){snap={snapTo:snap}} "scrollBehavior" in _body.style&&gsap.set(isViewport?[_body,_docEl]:scroller,{scrollBehavior:"auto"});snapFunc=_isFunction(snap.snapTo)?snap.snapTo:snap.snapTo==="labels"?_getClosestLabel(animation):snap.snapTo==="labelsDirectional"?_getLabelAtDirection(animation):snap.directional!==!1?function(value,st){return _snapDirectional(snap.snapTo)(value,st.direction)}:gsap.utils.snap(snap.snapTo);snapDurClamp=snap.duration||{min:0.1,max:2};snapDurClamp=_isObject(snapDurClamp)?_clamp(snapDurClamp.min,snapDurClamp.max):_clamp(snapDurClamp,snapDurClamp);snapDelayedCall=gsap.delayedCall(snap.delay||scrubSmooth/2||0.1,function(){if(Math.abs(self.getVelocity())<10&&!_pointerIsDown&&lastSnap!==scrollFunc()){var totalProgress=animation&&!isToggle?animation.totalProgress():self.progress,velocity=(totalProgress-snap2)/(_getTime()-_time2)*1000||0,change1=gsap.utils.clamp(-self.progress,1-self.progress,_abs(velocity/2)*velocity/0.185),naturalEnd=self.progress+(snap.inertia===!1?0:change1),endValue=_clamp(0,1,snapFunc(naturalEnd,self)),scroll=scrollFunc(),endScroll=Math.round(start+endValue*change),_snap=snap,onStart=_snap.onStart,_onInterrupt=_snap.onInterrupt,_onComplete=_snap.onComplete,tween=tweenTo.tween;if(scroll<=end&&scroll>=start&&endScroll!==scroll){if(tween&&!tween._initted&&tween.data<=_abs(endScroll-scroll)){return} if(snap.inertia===!1){change1=endValue-self.progress} tweenTo(endScroll,{duration:snapDurClamp(_abs(Math.max(_abs(naturalEnd-totalProgress),_abs(endValue-totalProgress))*0.185/velocity/0.05||0)),ease:snap.ease||"power3",data:_abs(endScroll-scroll),onInterrupt:function onInterrupt(){return snapDelayedCall.restart(!0)&&_onInterrupt&&_onInterrupt(self)},onComplete:function onComplete(){lastSnap=scrollFunc();snap1=snap2=animation&&!isToggle?animation.totalProgress():self.progress;onSnapComplete&&onSnapComplete(self);_onComplete&&_onComplete(self)}},scroll,change1*change,endScroll-scroll-change1*change);onStart&&onStart(self,tweenTo.tween)}}else if(self.isActive){snapDelayedCall.restart(!0)}}).pause()} id&&(_ids[id]=self);trigger=self.trigger=_getTarget(trigger||pin);pin=pin===!0?trigger:_getTarget(pin);_isString(toggleClass)&&(toggleClass={targets:trigger,className:toggleClass});if(pin){pinSpacing===!1||pinSpacing===_margin||(pinSpacing=!pinSpacing&&_getComputedStyle(pin.parentNode).display==="flex"?!1:_padding);self.pin=pin;vars.force3D!==!1&&gsap.set(pin,{force3D:!0});pinCache=gsap.core.getCache(pin);if(!pinCache.spacer){if(pinSpacer){pinSpacer=_getTarget(pinSpacer);pinSpacer&&!pinSpacer.nodeType&&(pinSpacer=pinSpacer.current||pinSpacer.nativeElement);pinCache.spacerIsNative=!!pinSpacer;pinSpacer&&(pinCache.spacerState=_getState(pinSpacer))} pinCache.spacer=spacer=pinSpacer||_doc.createElement("div");spacer.classList.add("pin-spacer");id&&spacer.classList.add("pin-spacer-"+id);pinCache.pinState=pinOriginalState=_getState(pin)}else{pinOriginalState=pinCache.pinState} self.spacer=spacer=pinCache.spacer;cs=_getComputedStyle(pin);spacingStart=cs[pinSpacing+direction.os2];pinGetter=gsap.getProperty(pin);pinSetter=gsap.quickSetter(pin,direction.a,_px);_swapPinIn(pin,spacer,cs);pinState=_getState(pin)} if(markers){markerVars=_isObject(markers)?_setDefaults(markers,_markerDefaults):_markerDefaults;markerStartTrigger=_createMarker("scroller-start",id,scroller,direction,markerVars,0);markerEndTrigger=_createMarker("scroller-end",id,scroller,direction,markerVars,0,markerStartTrigger);offset=markerStartTrigger["offset"+direction.op.d2];markerStart=_createMarker("start",id,scroller,direction,markerVars,offset,0,containerAnimation);markerEnd=_createMarker("end",id,scroller,direction,markerVars,offset,0,containerAnimation);containerAnimation&&(caMarkerSetter=gsap.quickSetter([markerStart,markerEnd],direction.a,_px));if(!useFixedPosition&&!(_proxies.length&&_getProxyProp(scroller,"fixedMarkers")===!0)){_makePositionable(isViewport?_body:scroller);gsap.set([markerStartTrigger,markerEndTrigger],{force3D:!0});markerStartSetter=gsap.quickSetter(markerStartTrigger,direction.a,_px);markerEndSetter=gsap.quickSetter(markerEndTrigger,direction.a,_px)}} if(containerAnimation){var oldOnUpdate=containerAnimation.vars.onUpdate,oldParams=containerAnimation.vars.onUpdateParams;containerAnimation.eventCallback("onUpdate",function(){self.update(0,0,1);oldOnUpdate&&oldOnUpdate.apply(oldParams||[])})} self.previous=function(){return _triggers[_triggers.indexOf(self)-1]};self.next=function(){return _triggers[_triggers.indexOf(self)+1]};self.revert=function(revert){var r=revert!==!1||!self.enabled,prevRefreshing=_refreshing;if(r!==self.isReverted){if(r){self.scroll.rec||(self.scroll.rec=scrollFunc());prevScroll=Math.max(scrollFunc(),self.scroll.rec||0);prevProgress=self.progress;prevAnimProgress=animation&&animation.progress()} markerStart&&[markerStart,markerEnd,markerStartTrigger,markerEndTrigger].forEach(function(m){return m.style.display=r?"none":"block"});r&&(_refreshing=1);self.update(r);_refreshing=prevRefreshing;pin&&(r?_swapPinOut(pin,spacer,pinOriginalState):(!pinReparent||!self.isActive)&&_swapPinIn(pin,spacer,_getComputedStyle(pin),spacerState));self.isReverted=r}};self.refresh=function(soft,force){if((_refreshing||!self.enabled)&&!force){return} if(pin&&soft&&_lastScrollTime){_addListener(ScrollTrigger,"scrollEnd",_softRefresh);return} _refreshing=1;scrubTween&&scrubTween.pause();invalidateOnRefresh&&animation&&animation.progress(0).invalidate();self.isReverted||self.revert();var size=getScrollerSize(),scrollerBounds=getScrollerOffsets(),max=containerAnimation?containerAnimation.duration():_maxScroll(scroller,direction),offset=0,otherPinOffset=0,parsedEnd=vars.end,parsedEndTrigger=vars.endTrigger||trigger,parsedStart=vars.start||(vars.start===0||!trigger?0:pin?"0 0":"0 100%"),pinnedContainer=vars.pinnedContainer&&_getTarget(vars.pinnedContainer),triggerIndex=trigger&&Math.max(0,_triggers.indexOf(self))||0,i=triggerIndex,cs,bounds,scroll,isVertical,override,curTrigger,curPin,oppositeScroll,initted,revertedPins;while(i--){curTrigger=_triggers[i];curTrigger.end||curTrigger.refresh(0,1)||(_refreshing=1);curPin=curTrigger.pin;if(curPin&&(curPin===trigger||curPin===pin)&&!curTrigger.isReverted){revertedPins||(revertedPins=[]);revertedPins.unshift(curTrigger);curTrigger.revert()}} _isFunction(parsedStart)&&(parsedStart=parsedStart(self));start=_parsePosition(parsedStart,trigger,size,direction,scrollFunc(),markerStart,markerStartTrigger,self,scrollerBounds,borderWidth,useFixedPosition,max,containerAnimation)||(pin?-0.001:0);_isFunction(parsedEnd)&&(parsedEnd=parsedEnd(self));if(_isString(parsedEnd)&&!parsedEnd.indexOf("+=")){if(~parsedEnd.indexOf(" ")){parsedEnd=(_isString(parsedStart)?parsedStart.split(" ")[0]:"")+parsedEnd}else{offset=_offsetToPx(parsedEnd.substr(2),size);parsedEnd=_isString(parsedStart)?parsedStart:start+offset;parsedEndTrigger=trigger}} end=Math.max(start,_parsePosition(parsedEnd||(parsedEndTrigger?"100% 0":max),parsedEndTrigger,size,direction,scrollFunc()+offset,markerEnd,markerEndTrigger,self,scrollerBounds,borderWidth,useFixedPosition,max,containerAnimation))||-0.001;change=end-start||(start-=0.01)&&0.001;offset=0;i=triggerIndex;while(i--){curTrigger=_triggers[i];curPin=curTrigger.pin;if(curPin&&curTrigger.start-curTrigger._pinPush1&&((isViewport?_body:scroller).style["overflow-"+direction.a]="scroll");_swapPinIn(pin,spacer,cs);pinState=_getState(pin);bounds=_getBounds(pin,!0);oppositeScroll=useFixedPosition&&_getScrollFunc(scroller,isVertical?_horizontal:_vertical)();if(pinSpacing){spacerState=[pinSpacing+direction.os2,change+otherPinOffset+_px];spacerState.t=spacer;i=pinSpacing===_padding?_getSize(pin,direction)+change+otherPinOffset:0;i&&spacerState.push(direction.d,i+_px);_setState(spacerState);useFixedPosition&&scrollFunc(prevScroll)} if(useFixedPosition){override={top:bounds.top+(isVertical?scroll-start:oppositeScroll)+_px,left:bounds.left+(isVertical?oppositeScroll:scroll-start)+_px,boxSizing:"border-box",position:"fixed"};override[_width]=override["max"+_Width]=Math.ceil(bounds.width)+_px;override[_height]=override["max"+_Height]=Math.ceil(bounds.height)+_px;override[_margin]=override[_margin+_Top]=override[_margin+_Right]=override[_margin+_Bottom]=override[_margin+_Left]="0";override[_padding]=cs[_padding];override[_padding+_Top]=cs[_padding+_Top];override[_padding+_Right]=cs[_padding+_Right];override[_padding+_Bottom]=cs[_padding+_Bottom];override[_padding+_Left]=cs[_padding+_Left];pinActiveState=_copyState(pinOriginalState,override,pinReparent)} if(animation){initted=animation._initted;_suppressOverwrites(1);animation.render(animation.duration(),!0,!0);pinChange=pinGetter(direction.a)-pinStart+change+otherPinOffset;change!==pinChange&&pinActiveState.splice(pinActiveState.length-2,2);animation.render(0,!0,!0);initted||animation.invalidate();_suppressOverwrites(0)}else{pinChange=change}}else if(trigger&&scrollFunc()&&!containerAnimation){bounds=trigger.parentNode;while(bounds&&bounds!==_body){if(bounds._pinOffset){start-=bounds._pinOffset;end-=bounds._pinOffset} bounds=bounds.parentNode}} revertedPins&&revertedPins.forEach(function(t){return t.revert(!1)});self.start=start;self.end=end;scroll1=scroll2=scrollFunc();if(!containerAnimation){scroll10?_triggers.slice(0,i).reverse():_triggers.slice(i+1);return _isString(name)?a.filter(function(t){return t.vars.preventOverlaps===name}):a};self.update=function(reset,recordVelocity,forceFake){if(containerAnimation&&!forceFake&&!reset){return} var scroll=self.scroll(),p=reset?0:(scroll-start)/change,clipped=p<0?0:p>1?1:p||0,prevProgress=self.progress,isActive,wasActive,toggleState,action,stateChanged,toggled,isAtMax,isTakingAction;if(recordVelocity){scroll2=scroll1;scroll1=containerAnimation?scrollFunc():scroll;if(snap){snap2=snap1;snap1=animation&&!isToggle?animation.totalProgress():clipped}} anticipatePin&&!clipped&&pin&&!_refreshing&&!_startup&&_lastScrollTime&&startprevProgress?1:-1;self.progress=clipped;if(stateChanged&&!_refreshing){toggleState=clipped&&!prevProgress?0:clipped===1?1:prevProgress===1?2:3;if(isToggle){action=!toggled&&toggleActions[toggleState+1]!=="none"&&toggleActions[toggleState+1]||toggleActions[toggleState];isTakingAction=animation&&(action==="complete"||action==="reset"||action in animation)}} preventOverlaps&&toggled&&(isTakingAction||scrub||!animation)&&(_isFunction(preventOverlaps)?preventOverlaps(self):self.getTrailing(preventOverlaps).forEach(function(t){return t.endAnimation()}));if(!isToggle){if(scrubTween&&!_refreshing&&!_startup){scrubTween.vars.totalProgress=clipped;scrubTween.invalidate().restart()}else if(animation){animation.totalProgress(clipped,!!_refreshing)}} if(pin){reset&&pinSpacing&&(spacer.style[pinSpacing+direction.os2]=spacingStart);if(!useFixedPosition){pinSetter(pinStart+pinChange*clipped)}else if(stateChanged){isAtMax=!reset&&clipped>prevProgress&&end+1>scroll&&scroll+1>=_maxScroll(scroller,direction);if(pinReparent){if(!reset&&(isActive||isAtMax)){var bounds=_getBounds(pin,!0),_offset=scroll-start;_reparent(pin,_body,bounds.top+(direction===_vertical?_offset:0)+_px,bounds.left+(direction===_vertical?0:_offset)+_px)}else{_reparent(pin,spacer)}} _setState(isActive||isAtMax?pinActiveState:pinState);pinChange!==change&&clipped<1&&isActive||pinSetter(pinStart+(clipped===1&&!isAtMax?pinChange:0))}} snap&&!tweenTo.tween&&!_refreshing&&!_startup&&snapDelayedCall.restart(!0);toggleClass&&(toggled||once&&clipped&&(clipped<1||!_limitCallbacks))&&_toArray(toggleClass.targets).forEach(function(el){return el.classList[isActive||once?"add":"remove"](toggleClass.className)});onUpdate&&!isToggle&&!reset&&onUpdate(self);if(stateChanged&&!_refreshing){if(isToggle){if(isTakingAction){if(action==="complete"){animation.pause().totalProgress(1)}else if(action==="reset"){animation.restart(!0).pause()}else if(action==="restart"){animation.restart(!0)}else{animation[action]()}} onUpdate&&onUpdate(self)} if(toggled||!_limitCallbacks){onToggle&&toggled&&_callback(self,onToggle);callbacks[toggleState]&&_callback(self,callbacks[toggleState]);once&&(clipped===1?self.kill(!1,1):callbacks[toggleState]=0);if(!toggled){toggleState=clipped===1?1:3;callbacks[toggleState]&&_callback(self,callbacks[toggleState])}} if(fastScrollEnd&&!isActive&&Math.abs(self.getVelocity())>(_isNumber(fastScrollEnd)?fastScrollEnd:2500)){_endAnimation(self.callbackAnimation);scrubTween?scrubTween.progress(1):_endAnimation(animation,!clipped,1)}}else if(isToggle&&onUpdate&&!_refreshing){onUpdate(self)}} if(markerEndSetter){var n=containerAnimation?scroll/containerAnimation.duration()*(containerAnimation._caScrollDist||0):scroll;markerStartSetter(n+(markerStartTrigger._isFlipped?1:0));markerEndSetter(n)} caMarkerSetter&&caMarkerSetter(-scroll/containerAnimation.duration()*(containerAnimation._caScrollDist||0))};self.enable=function(reset,refresh){if(!self.enabled){self.enabled=!0;_addListener(scroller,"resize",_onResize);_addListener(scroller,"scroll",_onScroll);onRefreshInit&&_addListener(ScrollTrigger,"refreshInit",onRefreshInit);if(reset!==!1){self.progress=prevProgress=0;scroll1=scroll2=lastSnap=scrollFunc()} refresh!==!1&&self.refresh()}};self.getTween=function(snap){return snap&&tweenTo?tweenTo.tween:scrubTween};self.disable=function(reset,allowAnimation){if(self.enabled){reset!==!1&&self.revert();self.enabled=self.isActive=!1;allowAnimation||scrubTween&&scrubTween.pause();prevScroll=0;pinCache&&(pinCache.uncache=1);onRefreshInit&&_removeListener(ScrollTrigger,"refreshInit",onRefreshInit);if(snapDelayedCall){snapDelayedCall.pause();tweenTo.tween&&tweenTo.tween.kill()&&(tweenTo.tween=0)} if(!isViewport){var i=_triggers.length;while(i--){if(_triggers[i].scroller===scroller&&_triggers[i]!==self){return}} _removeListener(scroller,"resize",_onResize);_removeListener(scroller,"scroll",_onScroll)}}};self.kill=function(revert,allowAnimation){self.disable(revert,allowAnimation);scrubTween&&scrubTween.kill();id&&delete _ids[id];var i=_triggers.indexOf(self);_triggers.splice(i,1);i===_i&&_direction>0&&_i--;i=0;_triggers.forEach(function(t){return t.scroller===self.scroller&&(i=1)});i||(self.scroll.rec=0);if(animation){animation.scrollTrigger=null;revert&&animation.render(-1);allowAnimation||animation.kill()} markerStart&&[markerStart,markerEnd,markerStartTrigger,markerEndTrigger].forEach(function(m){return m.parentNode&&m.parentNode.removeChild(m)});if(pin){pinCache&&(pinCache.uncache=1);i=0;_triggers.forEach(function(t){return t.pin===pin&&i++});i||(pinCache.spacer=0)}};self.enable(!1,!1);!animation||!animation.add||change?self.refresh():gsap.delayedCall(0.01,function(){return start||end||self.refresh()})&&(change=0.01)&&(start=end=0)};ScrollTrigger.register=function register(core){if(!_coreInitted){gsap=core||_getGSAP();if(_windowExists()&&window.document){_win=window;_doc=document;_docEl=_doc.documentElement;_body=_doc.body} if(gsap){_toArray=gsap.utils.toArray;_clamp=gsap.utils.clamp;_suppressOverwrites=gsap.core.suppressOverwrites||_passThrough;gsap.core.globals("ScrollTrigger",ScrollTrigger);if(_body){_raf=_win.requestAnimationFrame||function(f){return setTimeout(f,16)};_addListener(_win,"wheel",_onScroll);_root=[_win,_doc,_docEl,_body];_addListener(_doc,"scroll",_onScroll);var bodyStyle=_body.style,border=bodyStyle.borderTopStyle,bounds;bodyStyle.borderTopStyle="solid";bounds=_getBounds(_body);_vertical.m=Math.round(bounds.top+_vertical.sc())||0;_horizontal.m=Math.round(bounds.left+_horizontal.sc())||0;border?bodyStyle.borderTopStyle=border:bodyStyle.removeProperty("border-top-style");_syncInterval=setInterval(_sync,200);gsap.delayedCall(0.5,function(){return _startup=0});_addListener(_doc,"touchcancel",_passThrough);_addListener(_body,"touchstart",_passThrough);_multiListener(_addListener,_doc,"pointerdown,touchstart,mousedown",function(){return _pointerIsDown=1});_multiListener(_addListener,_doc,"pointerup,touchend,mouseup",function(){return _pointerIsDown=0});_transformProp=gsap.utils.checkPrefix("transform");_stateProps.push(_transformProp);_coreInitted=_getTime();_resizeDelay=gsap.delayedCall(0.2,_refreshAll).pause();_autoRefresh=[_doc,"visibilitychange",function(){var w=_win.innerWidth,h=_win.innerHeight;if(_doc.hidden){_prevWidth=w;_prevHeight=h}else if(_prevWidth!==w||_prevHeight!==h){_onResize()}},_doc,"DOMContentLoaded",_refreshAll,_win,"load",function(){return _lastScrollTime||_refreshAll()},_win,"resize",_onResize];_iterateAutoRefresh(_addListener)}}} return _coreInitted};ScrollTrigger.defaults=function defaults(config){for(var p in config){_defaults[p]=config[p]}};ScrollTrigger.kill=function kill(){_enabled=0;_triggers.slice(0).forEach(function(trigger){return trigger.kill(1)})};ScrollTrigger.config=function config(vars){"limitCallbacks" in vars&&(_limitCallbacks=!!vars.limitCallbacks);var ms=vars.syncInterval;ms&&clearInterval(_syncInterval)||(_syncInterval=ms)&&setInterval(_sync,ms);if("autoRefreshEvents" in vars){_iterateAutoRefresh(_removeListener)||_iterateAutoRefresh(_addListener,vars.autoRefreshEvents||"none");_ignoreResize=(vars.autoRefreshEvents+"").indexOf("resize")===-1}};ScrollTrigger.scrollerProxy=function scrollerProxy(target,vars){var t=_getTarget(target),i=_scrollers.indexOf(t),isViewport=_isViewport(t);if(~i){_scrollers.splice(i,isViewport?6:2)} isViewport?_proxies.unshift(_win,vars,_body,vars,_docEl,vars):_proxies.unshift(t,vars)};ScrollTrigger.matchMedia=function matchMedia(vars){var mq,p,i,func,result;for(p in vars){i=_media.indexOf(p);func=vars[p];_creatingMedia=p;if(p==="all"){func()}else{mq=_win.matchMedia(p);if(mq){mq.matches&&(result=func());if(~i){_media[i+1]=_combineFunc(_media[i+1],func);_media[i+2]=_combineFunc(_media[i+2],result)}else{i=_media.length;_media.push(p,func,result);mq.addListener?mq.addListener(_onMediaChange):mq.addEventListener("change",_onMediaChange)} _media[i+3]=mq.matches}} _creatingMedia=0} return _media};ScrollTrigger.clearMatchMedia=function clearMatchMedia(query){query||(_media.length=0);query=_media.indexOf(query);query>=0&&_media.splice(query,4)};ScrollTrigger.isInViewport=function isInViewport(element,ratio,horizontal){var bounds=(_isString(element)?_getTarget(element):element).getBoundingClientRect(),offset=bounds[horizontal?_width:_height]*ratio||0;return horizontal?bounds.right-offset>0&&bounds.left+offset<_win.innerWidth:bounds.bottom-offset>0&&bounds.top+offset<_win.innerHeight};ScrollTrigger.positionInViewport=function positionInViewport(element,referencePoint,horizontal){_isString(element)&&(element=_getTarget(element));var bounds=element.getBoundingClientRect(),size=bounds[horizontal?_width:_height],offset=referencePoint==null?size/2:referencePoint in _keywords?_keywords[referencePoint]*size:~referencePoint.indexOf("%")?parseFloat(referencePoint)*size/100:parseFloat(referencePoint)||0;return horizontal?(bounds.left+offset)/_win.innerWidth:(bounds.top+offset)/_win.innerHeight};return ScrollTrigger}();ScrollTrigger.version="3.8.0";ScrollTrigger.saveStyles=function(targets){return targets?_toArray(targets).forEach(function(target){if(target&&target.style){var i=_savedStyles.indexOf(target);i>=0&&_savedStyles.splice(i,5);_savedStyles.push(target,target.style.cssText,target.getBBox&&target.getAttribute("transform"),gsap.core.getCache(target),_creatingMedia)}}):_savedStyles};ScrollTrigger.revert=function(soft,media){return _revertAll(!soft,media)};ScrollTrigger.create=function(vars,animation){return new ScrollTrigger(vars,animation)};ScrollTrigger.refresh=function(safe){return safe?_onResize():(_coreInitted||ScrollTrigger.register())&&_refreshAll(!0)};ScrollTrigger.update=_updateAll;ScrollTrigger.clearScrollMemory=_clearScrollMemory;ScrollTrigger.maxScroll=function(element,horizontal){return _maxScroll(element,horizontal?_horizontal:_vertical)};ScrollTrigger.getScrollFunc=function(element,horizontal){return _getScrollFunc(_getTarget(element),horizontal?_horizontal:_vertical)};ScrollTrigger.getById=function(id){return _ids[id]};ScrollTrigger.getAll=function(){return _triggers.slice(0)};ScrollTrigger.isScrolling=function(){return!!_lastScrollTime};ScrollTrigger.snapDirectional=_snapDirectional;ScrollTrigger.addEventListener=function(type,callback){var a=_listeners[type]||(_listeners[type]=[]);~a.indexOf(callback)||a.push(callback)};ScrollTrigger.removeEventListener=function(type,callback){var a=_listeners[type],i=a&&a.indexOf(callback);i>=0&&a.splice(i,1)};ScrollTrigger.batch=function(targets,vars){var result=[],varsCopy={},interval=vars.interval||0.016,batchMax=vars.batchMax||1e9,proxyCallback=function proxyCallback(type,callback){var elements=[],triggers=[],delay=gsap.delayedCall(interval,function(){callback(elements,triggers);elements=[];triggers=[]}).pause();return function(self){elements.length||delay.restart(!0);elements.push(self.trigger);triggers.push(self);batchMax<=elements.length&&delay.progress(1)}},p;for(p in vars){varsCopy[p]=p.substr(0,2)==="on"&&_isFunction(vars[p])&&p!=="onRefreshInit"?proxyCallback(p,vars[p]):vars[p]} if(_isFunction(batchMax)){batchMax=batchMax();_addListener(ScrollTrigger,"refresh",function(){return batchMax=vars.batchMax()})} _toArray(targets).forEach(function(target){var config={};for(p in varsCopy){config[p]=varsCopy[p]} config.trigger=target;result.push(ScrollTrigger.create(config))});return result};ScrollTrigger.sort=function(func){return _triggers.sort(func||function(a,b){return(a.vars.refreshPriority||0)*-1e6+a.start-(b.start+(b.vars.refreshPriority||0)*-1e6)})};_getGSAP()&&gsap.registerPlugin(ScrollTrigger);exports.ScrollTrigger=ScrollTrigger;exports.default=ScrollTrigger;Object.defineProperty(exports,'__esModule',{value:!0})})));+function($){'use strict';var Collapse=function(element,options){this.$element=$(element) this.options=$.extend({},Collapse.DEFAULTS,options) this.transitioning=null if(this.options.parent)this.$parent=$(this.options.parent) if(this.options.toggle)this.toggle()} Collapse.DEFAULTS={toggle:!0} Collapse.prototype.dimension=function(){var hasWidth=this.$element.hasClass('width') return hasWidth?'width':'height'} Collapse.prototype.show=function(){if(this.transitioning||this.$element.hasClass('in'))return var startEvent=$.Event('show.bs.collapse') this.$element.trigger(startEvent) if(startEvent.isDefaultPrevented())return var actives=this.$parent&&this.$parent.find('> .panel > .in') if(actives&&actives.length){var hasData=actives.data('bs.collapse') if(hasData&&hasData.transitioning)return var parentNoToggle=this.$parent.data('no-toggle') if(!parentNoToggle){actives.collapse('hide')} hasData||actives.data('bs.collapse',null)} var dimension=this.dimension() this.$element.removeClass('collapse').addClass('collapsing')[dimension](0) this.transitioning=1 var complete=function(e){if(e&&e.target!=this.$element[0])return this.$element.removeClass('collapsing').addClass('collapse in')[dimension]('auto') this.transitioning=0 this.$element.trigger('shown.bs.collapse')} if(!$.support.transition)return complete.call(this) var scrollSize=$.camelCase(['scroll',dimension].join('-')) this.$element.one($.support.transition.end,$.proxy(complete,this)).emulateTransitionEnd(350)[dimension](this.$element[0][scrollSize])} Collapse.prototype.hide=function(){if(this.transitioning||!this.$element.hasClass('in'))return var startEvent=$.Event('hide.bs.collapse') this.$element.trigger(startEvent) if(startEvent.isDefaultPrevented())return var dimension=this.dimension() this.$element[dimension](this.$element[dimension]())[0].offsetHeight this.$element.addClass('collapsing').removeClass('collapse').removeClass('in') this.transitioning=1 var complete=function(e){if(e&&e.target!=this.$element[0])return this.transitioning=0 this.$element.trigger('hidden.bs.collapse').removeClass('collapsing').addClass('collapse')} if(!$.support.transition)return complete.call(this) this.$element[dimension](0).one($.support.transition.end,$.proxy(complete,this)).emulateTransitionEnd(350)} Collapse.prototype.toggle=function(){this[this.$element.hasClass('in')?'hide':'show']()} var old=$.fn.collapse $.fn.collapse=function(option){return this.each(function(){var $this=$(this) var data=$this.data('bs.collapse') var options=$.extend({},Collapse.DEFAULTS,$this.data(),typeof option=='object'&&option) if(!data&&options.toggle&&option=='show')option=!option if(!data)$this.data('bs.collapse',(data=new Collapse(this,options))) if(typeof option=='string')data[option]()})} $.fn.collapse.Constructor=Collapse $.fn.collapse.noConflict=function(){$.fn.collapse=old return this} $(document).on('click.bs.collapse.data-api','[data-toggle="collapse"]',function(e){var $this=$(this),href var target=$this.attr('data-target')||e.preventDefault()||(href=$this.attr('href'))&&href.replace(/.*(?=#[^\s]+$)/,'') var _target=href.replace(/^#/,"");if($('[data-id="'+_target+'"]').length){var $target=$('[data-id="'+_target+'"]')}else{var $target=$(target)} var data=$target.data('bs.collapse') var option=data?'toggle':$this.data() var parent=$this.attr('data-parent') var $parent=parent&&$(parent) if(!data||!data.transitioning){if($parent)$parent.find('[data-toggle="collapse"][data-parent="'+parent+'"]').not($this).addClass('collapsed') $this[$target.hasClass('in')?'addClass':'removeClass']('collapsed')} $target.collapse(option)})}(jQuery);+function($){'use strict';var Tab=function(element){this.element=$(element)} Tab.prototype.show=function(){var $this=this.element var $ul=$this.closest('ul:not(.dropdown-menu)') var selector=$this.data('target') if(!selector){selector=$this.attr('href') selector=selector&&selector.replace(/.*(?=#[^\s]*$)/,'')} if($this.parent('li').hasClass('active'))return var previous=$ul.find('.active:last a')[0] var e=$.Event('show.bs.tab',{relatedTarget:previous}) $this.trigger(e) if(e.isDefaultPrevented())return var _target=selector.replace(/^#/,"");if($('[data-id="'+_target+'"]').length) var $target=$('[data-id="'+_target+'"]') else var $target=$(selector) this.activate($this.parent('li'),$ul) this.activate($target,$target.parent(),function(){$this.trigger({type:'shown.bs.tab',relatedTarget:previous})})} Tab.prototype.activate=function(element,container,callback){var $active=container.find('> .active').add(container.find('> .active > .active')) var transition=callback&&$.support.transition&&$active.hasClass('fade') function next(){$active.removeClass('active').find('> .dropdown-menu > .active').removeClass('active') $active.find('.tab-excerpt').slideUp();element.addClass('active') $('.tab-excerpt',element).slideDown();element[0].offsetWidth element.add($active).addClass('in') if(element.parent('.dropdown-menu')){element.closest('li.dropdown').addClass('active')} if(!element.is('li')){element.closest('.tab-content').find('> .active').not(element).removeClass('active')} callback&&callback()} transition?$active.one($.support.transition.end,next).emulateTransitionEnd(150):next() $active.removeClass('in')} var old=$.fn.tab $.fn.tab=function(option){return this.each(function(){var $this=$(this) var data=$this.data('bs.tab') if(!data)$this.data('bs.tab',(data=new Tab(this))) if(typeof option=='string')data[option]()})} $.fn.tab.Constructor=Tab $.fn.tab.noConflict=function(){$.fn.tab=old return this} $(document).on('click.bs.tab.data-api','[data-toggle="tab"], [data-toggle="pill"]',function(e){e.preventDefault() $(this).tab('show')})}(jQuery);+function($){'use strict';var Tooltip=function(element,options){this.type=this.options=this.enabled=this.timeout=this.hoverState=this.$element=null this.init('tooltip',element,options)} Tooltip.DEFAULTS={animation:!0,placement:'top',selector:!1,template:'',trigger:'hover focus',title:'',delay:0,html:!1,container:!1,viewport:{selector:'body',padding:0}} Tooltip.prototype.init=function(type,element,options){this.enabled=!0 this.type=type this.$element=$(element) this.options=this.getOptions(options) this.$viewport=this.options.viewport&&$(this.options.viewport.selector||this.options.viewport) var triggers=this.options.trigger.split(' ') for(var i=triggers.length;i--;){var trigger=triggers[i] if(trigger=='click'){this.$element.on('click.'+this.type,this.options.selector,$.proxy(this.toggle,this))}else if(trigger!='manual'){var eventIn=trigger=='hover'?'mouseenter':'focusin' var eventOut=trigger=='hover'?'mouseleave':'focusout' this.$element.on(eventIn+'.'+this.type,this.options.selector,$.proxy(this.enter,this)) this.$element.on(eventOut+'.'+this.type,this.options.selector,$.proxy(this.leave,this))}} this.options.selector?(this._options=$.extend({},this.options,{trigger:'manual',selector:''})):this.fixTitle()} Tooltip.prototype.getDefaults=function(){return Tooltip.DEFAULTS} Tooltip.prototype.getOptions=function(options){options=$.extend({},this.getDefaults(),this.$element.data(),options) if(options.delay&&typeof options.delay=='number'){options.delay={show:options.delay,hide:options.delay}} return options} Tooltip.prototype.getDelegateOptions=function(){var options={} var defaults=this.getDefaults() this._options&&$.each(this._options,function(key,value){if(defaults[key]!=value)options[key]=value}) return options} Tooltip.prototype.enter=function(obj){var self=obj instanceof this.constructor?obj:$(obj.currentTarget)[this.type](this.getDelegateOptions()).data('bs.'+this.type) clearTimeout(self.timeout) self.hoverState='in' if(!self.options.delay||!self.options.delay.show)return self.show() self.timeout=setTimeout(function(){if(self.hoverState=='in')self.show()},self.options.delay.show)} Tooltip.prototype.leave=function(obj){var self=obj instanceof this.constructor?obj:$(obj.currentTarget)[this.type](this.getDelegateOptions()).data('bs.'+this.type) clearTimeout(self.timeout) self.hoverState='out' if(!self.options.delay||!self.options.delay.hide)return self.hide() self.timeout=setTimeout(function(){if(self.hoverState=='out')self.hide()},self.options.delay.hide)} Tooltip.prototype.show=function(){var e=$.Event('show.bs.'+this.type) if(this.hasContent()&&this.enabled){this.$element.trigger(e) if(e.isDefaultPrevented())return var that=this;var $tip=this.tip() this.setContent() if(this.options.animation)$tip.addClass('fade') var placement=typeof this.options.placement=='function'?this.options.placement.call(this,$tip[0],this.$element[0]):this.options.placement var autoToken=/\s?auto?\s?/i var autoPlace=autoToken.test(placement) if(autoPlace)placement=placement.replace(autoToken,'')||'top' $tip.detach().css({top:0,left:0,display:'block'}).addClass(placement) this.options.container?$tip.appendTo($(document).find(this.options.container)):$tip.insertAfter(this.$element) var pos=this.getPosition() var actualWidth=$tip[0].offsetWidth var actualHeight=$tip[0].offsetHeight if(autoPlace){var orgPlacement=placement var $parent=this.$element.parent() var parentDim=this.getPosition($parent) placement=placement=='bottom'&&pos.top+pos.height+actualHeight-parentDim.scroll>parentDim.height?'top':placement=='top'&&pos.top-parentDim.scroll-actualHeight<0?'bottom':placement=='right'&&pos.right+actualWidth>parentDim.width?'left':placement=='left'&&pos.left-actualWidthviewportDimensions.top+viewportDimensions.height){delta.top=viewportDimensions.top+viewportDimensions.height-bottomEdgeOffset}}else{var leftEdgeOffset=pos.left-viewportPadding var rightEdgeOffset=pos.left+viewportPadding+actualWidth if(leftEdgeOffsetviewportDimensions.width){delta.left=viewportDimensions.left+viewportDimensions.width-rightEdgeOffset}} return delta} Tooltip.prototype.getTitle=function(){var title var $e=this.$element var o=this.options title=$e.attr('data-original-title')||(typeof o.title=='function'?o.title.call($e[0]):o.title) return title} Tooltip.prototype.tip=function(){return this.$tip=this.$tip||$(this.options.template)} Tooltip.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find('.tooltip-arrow')} Tooltip.prototype.validate=function(){if(!this.$element[0].parentNode){this.hide() this.$element=null this.options=null}} Tooltip.prototype.enable=function(){this.enabled=!0} Tooltip.prototype.disable=function(){this.enabled=!1} Tooltip.prototype.toggleEnabled=function(){this.enabled=!this.enabled} Tooltip.prototype.toggle=function(e){var self=e?$(e.currentTarget)[this.type](this.getDelegateOptions()).data('bs.'+this.type):this self.tip().hasClass('in')?self.leave(self):self.enter(self)} Tooltip.prototype.destroy=function(){clearTimeout(this.timeout) this.hide().$element.off('.'+this.type).removeData('bs.'+this.type)} var old=$.fn.tooltip $.fn.tooltip=function(option){return this.each(function(){var $this=$(this) var data=$this.data('bs.tooltip') var options=typeof option=='object'&&option if(!data&&option=='destroy')return if(!data)$this.data('bs.tooltip',(data=new Tooltip(this,options))) if(typeof option=='string')data[option]()})} $.fn.tooltip.Constructor=Tooltip $.fn.tooltip.noConflict=function(){$.fn.tooltip=old return this}}(jQuery);+function($){'use strict';function transitionEnd(){var el=document.createElement('bootstrap') var transEndEventNames={WebkitTransition:'webkitTransitionEnd',MozTransition:'transitionend',OTransition:'oTransitionEnd otransitionend',transition:'transitionend'} for(var name in transEndEventNames){if(el.style[name]!==undefined){return{end:transEndEventNames[name]}}} return!1} $.fn.emulateTransitionEnd=function(duration){var called=!1,$el=this $(this).one($.support.transition.end,function(){called=!0}) var callback=function(){if(!called)$($el).trigger($.support.transition.end)} setTimeout(callback,duration) return this} $(function(){$.support.transition=transitionEnd()})}(jQuery);(function(root,factory){if(typeof define==='function'&&define.amd){define([],factory)}else if(typeof module==='object'&&module.exports){module.exports=factory()}else{root.Rellax=factory()}}(typeof window!=="undefined"?window:global,function(){var Rellax=function(el,options){"use strict";var self=Object.create(Rellax.prototype);var posY=0;var screenY=0;var posX=0;var screenX=0;var blocks=[];var pause=!0;var loop=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame||function(callback){return setTimeout(callback,1000/60)};var loopId=null;var supportsPassive=!1;try{var opts=Object.defineProperty({},'passive',{get:function(){supportsPassive=!0}});window.addEventListener("testPassive",null,opts);window.removeEventListener("testPassive",null,opts)}catch(e){} var clearLoop=window.cancelAnimationFrame||window.mozCancelAnimationFrame||clearTimeout;var transformProp=window.transformProp||(function(){var testEl=document.createElement('div');if(testEl.style.transform===null){var vendors=['Webkit','Moz','ms'];for(var vendor in vendors){if(testEl.style[vendors[vendor]+'Transform']!==undefined){return vendors[vendor]+'Transform'}}} return'transform'})();self.options={speed:-2,verticalSpeed:null,horizontalSpeed:null,breakpoints:[576,768,1201],center:!1,wrapper:null,relativeToWrapper:!1,round:!0,vertical:!0,horizontal:!1,verticalScrollAxis:"y",horizontalScrollAxis:"x",callback:function(){},};if(options){Object.keys(options).forEach(function(key){self.options[key]=options[key]})} function validateCustomBreakpoints(){if(self.options.breakpoints.length===3&&Array.isArray(self.options.breakpoints)){var isAscending=!0;var isNumerical=!0;var lastVal;self.options.breakpoints.forEach(function(i){if(typeof i!=='number')isNumerical=!1;if(lastVal!==null){if(i0){self.elems=elements}else{console.warn("Rellax: The elements you're trying to select don't exist.");return} if(self.options.wrapper){if(!self.options.wrapper.nodeType){var wrapper=document.querySelector(self.options.wrapper);if(wrapper){self.options.wrapper=wrapper}else{console.warn("Rellax: The wrapper you're trying to use doesn't exist.");return}}} var currentBreakpoint;var getCurrentBreakpoint=function(w){var bp=self.options.breakpoints;if(w=bp[0]&&w=bp[1]&&w=blocks[i].max?blocks[i].max:positionY} if(self.options.horizontal&&!self.options.vertical){positionX=positionX>=blocks[i].max?blocks[i].max:positionX}} if(blocks[i].maxY!=null){positionY=positionY>=blocks[i].maxY?blocks[i].maxY:positionY} if(blocks[i].maxX!=null){positionX=positionX>=blocks[i].maxX?blocks[i].maxX:positionX} var zindex=blocks[i].zindex;var translate='translate3d('+(self.options.horizontal?positionX:'0')+'px,'+(self.options.vertical?positionY:'0')+'px,'+zindex+'px) '+blocks[i].transform;self.elems[i].style[transformProp]=translate} self.options.callback(positions)};self.destroy=function(){for(var i=0;i=this.duration){throw new Error('Vivus [constructor]: delay must be shorter than duration')}};Vivus.prototype.setCallback=function(callback){if(!!callback&&callback.constructor!==Function){throw new Error('Vivus [constructor]: "callback" parameter must be a function')} this.callback=callback||function(){}};Vivus.prototype.mapping=function(){var i,paths,path,pAttrs,pathObj,totalLength,lengthMeter,timePoint;timePoint=totalLength=lengthMeter=0;paths=this.el.querySelectorAll('path');for(i=0;i1?paths.length-1:1);if(this.reverseStack){this.map.reverse()} for(i=0;i=this.frameLength){this.stop();this.currentFrame=this.frameLength;this.trace();if(this.selfDestroy){this.destroy()}}else{this.trace();this.handle=requestAnimFrame(function(){self.drawer()});return} this.callback(this);if(this.instanceCallback){this.instanceCallback(this);this.instanceCallback=null}};Vivus.prototype.trace=function(){var i,progress,path,currentFrame;currentFrame=this.animTimingFunction(this.currentFrame/this.frameLength)*this.frameLength;for(i=0;i=scrolled};Vivus.prototype.getViewportH=function(){var client=this.docElem.clientHeight,inner=window.innerHeight;if(client=0)?output:defaultValue};if(typeof define==='function'&&define.amd){define([],function(){return Vivus})}else if(typeof exports==='object'){module.exports=Vivus}else{window.Vivus=Vivus}}());!function(){"use strict";var r=.5*(Math.sqrt(3)-1),e=(3-Math.sqrt(3))/6,t=1/6,a=(Math.sqrt(5)-1)/4,o=(5-Math.sqrt(5))/20;function i(r){var e;e="function"==typeof r?r:r?function(){var r=0,e=0,t=0,a=1,o=(i=4022871197,function(r){r=r.toString();for(var e=0;e>>0,i=(t*=i)>>>0,i+=4294967296*(t-=i)}return 2.3283064365386963e-10*(i>>>0)});var i;r=o(" "),e=o(" "),t=o(" ");for(var n=0;nc?(o=1,i=0):(o=0,i=1);var y=m-o+e,w=c-i+e,g=m-1+2*e,A=c-1+2*e,x=255&d,q=255&p,D=.5-m*m-c*c;if(D>=0){var S=3*n[x+f[q]];v=(D*=D)*D*(s[S]*m+s[S+1]*c)}var U=.5-y*y-w*w;if(U>=0){var b=3*n[x+o+f[q+i]];h=(U*=U)*U*(s[b]*y+s[b+1]*w)}var F=.5-g*g-A*A;if(F>=0){var N=3*n[x+1+f[q+1]];l=(F*=F)*F*(s[N]*g+s[N+1]*A)}return 70*(v+h+l)},noise3D:function(r,e,a){var o,i,n,f,s,v,h,l,u,d,p=this.permMod12,M=this.perm,m=this.grad3,c=(r+e+a)*(1/3),y=Math.floor(r+c),w=Math.floor(e+c),g=Math.floor(a+c),A=(y+w+g)*t,x=r-(y-A),q=e-(w-A),D=a-(g-A);x>=q?q>=D?(s=1,v=0,h=0,l=1,u=1,d=0):x>=D?(s=1,v=0,h=0,l=1,u=0,d=1):(s=0,v=0,h=1,l=1,u=0,d=1):qT?k++:z++,P>_?k++:B++,P>j?k++:E++,T>_?z++:B++,T>j?z++:E++,_>j?B++:E++;var G=P-(l=k>=3?1:0)+o,H=T-(u=z>=3?1:0)+o,I=_-(d=B>=3?1:0)+o,J=j-(p=E>=3?1:0)+o,K=P-(M=k>=2?1:0)+2*o,L=T-(m=z>=2?1:0)+2*o,O=_-(c=B>=2?1:0)+2*o,Q=j-(y=E>=2?1:0)+2*o,R=P-(w=k>=1?1:0)+3*o,V=T-(g=z>=1?1:0)+3*o,W=_-(A=B>=1?1:0)+3*o,X=j-(x=E>=1?1:0)+3*o,Y=P-1+4*o,Z=T-1+4*o,$=_-1+4*o,rr=j-1+4*o,er=255&U,tr=255&b,ar=255&F,or=255&N,ir=.6-P*P-T*T-_*_-j*j;if(ir<0)n=0;else{var nr=q[er+q[tr+q[ar+q[or]]]]%32*4;n=(ir*=ir)*ir*(D[nr]*P+D[nr+1]*T+D[nr+2]*_+D[nr+3]*j)}var fr=.6-G*G-H*H-I*I-J*J;if(fr<0)f=0;else{var sr=q[er+l+q[tr+u+q[ar+d+q[or+p]]]]%32*4;f=(fr*=fr)*fr*(D[sr]*G+D[sr+1]*H+D[sr+2]*I+D[sr+3]*J)}var vr=.6-K*K-L*L-O*O-Q*Q;if(vr<0)s=0;else{var hr=q[er+M+q[tr+m+q[ar+c+q[or+y]]]]%32*4;s=(vr*=vr)*vr*(D[hr]*K+D[hr+1]*L+D[hr+2]*O+D[hr+3]*Q)}var lr=.6-R*R-V*V-W*W-X*X;if(lr<0)v=0;else{var ur=q[er+w+q[tr+g+q[ar+A+q[or+x]]]]%32*4;v=(lr*=lr)*lr*(D[ur]*R+D[ur+1]*V+D[ur+2]*W+D[ur+3]*X)}var dr=.6-Y*Y-Z*Z-$*$-rr*rr;if(dr<0)h=0;else{var pr=q[er+1+q[tr+1+q[ar+1+q[or+1]]]]%32*4;h=(dr*=dr)*dr*(D[pr]*Y+D[pr+1]*Z+D[pr+2]*$+D[pr+3]*rr)}return 27*(n+f+s+v+h)}},i._buildPermutationTable=n,"undefined"!=typeof define&&define.amd&&define(function(){return i}),"undefined"!=typeof exports?exports.SimplexNoise=i:"undefined"!=typeof window&&(window.SimplexNoise=i),"undefined"!=typeof module&&(module.exports=i)}() ;