PageSourceSearch

https://rockyvision.shop/static/index.js?1662537898

js rockyvision.shop collected 2026-10-07 14:51:52 UTC 197,611 bytes, 37 lines download raw bytes

1(()=>{var __create=Object.create;var __getProtoOf=Object.getPrototypeOf;var __defProp=Object.defineProperty;var __getOwnPropNames=Object.getOwnPropertyNames;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __hasOwnProp=Object.prototype.hasOwnProperty;function __accessProp(key){return this[key]}var __toESMCache_node;var __toESMCache_esm;var __toESM=(mod,isNodeMode,target)=>{var canCache=mod!=null&&typeof mod==="object";if(canCache){var cache=isNodeMode?__toESMCache_node??=new WeakMap:__toESMCache_esm??=new WeakMap;var cached=cache.get(mod);if(cached)return cached}target=mod!=null?__create(__getProtoOf(mod)):{};const to=isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:true}):target;for(let key of __getOwnPropNames(mod))if(!__hasOwnProp.call(to,key))__defProp(to,key,{get:__accessProp.bind(mod,key),enumerable:true});if(canCache)cache.set(mod,to);return to};var __toCommonJS=(from)=>{var entry=(__moduleCache??=new WeakMap).get(from),desc;if(entry)return entry;entry=__defProp({},"__esModule",{value:true});if(from&&typeof from==="object"||typeof from==="function"){for(var key of __getOwnPropNames(from))if(!__hasOwnProp.call(entry,key))__defProp(entry,key,{get:__accessProp.bind(from,key),enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable})}__moduleCache.set(from,entry);return entry};var __moduleCache;var __commonJS=(cb,mod)=>()=>(mod||cb((mod={exports:{}}).exports,mod),mod.exports);var __returnValue=(v)=>v;function __exportSetter(name,newValue){this[name]=__returnValue.bind(null,newValue)}var __export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:true,configurable:true,set:__exportSetter.bind(all,name)})};var __esm=(fn,res)=>()=>(fn&&(res=fn(fn=0)),res);var __require=((x)=>typeof require!=="undefined"?require:typeof Proxy!=="undefined"?new Proxy(x,{get:(a,b)=>(typeof require!=="undefined"?require:a)[b]}):x)(function(x){if(typeof require!=="undefined")return require.apply(this,arguments);throw Error('Dynamic require of "'+x+'" is not supported')});function transformRawPath(rawPath,a,b,c,d,tx,ty){var j=rawPath.length,segment,l,i,x,y;while(--j>-1){segment=rawPath[j];l=segment.length;for(i=0;i<l;i+=2){x=segment[i];y=segment[i+1];segment[i]=x*a+y*c+tx;segment[i+1]=x*b+y*d+ty}}rawPath._dirty=1;return rawPath}function arcToSegment(lastX,lastY,rx,ry,angle,largeArcFlag,sweepFlag,x,y){if(lastX===x&&lastY===y){return}rx=_abs(rx);ry=_abs(ry);var angleRad=angle%360*_DEG2RAD2,cosAngle=_cos2(angleRad),sinAngle=_sin2(angleRad),PI=Math.PI,TWOPI=PI*2,dx2=(lastX-x)/2,dy2=(lastY-y)/2,x1=cosAngle*dx2+sinAngle*dy2,y1=-sinAngle*dx2+cosAngle*dy2,x1_sq=x1*x1,y1_sq=y1*y1,radiiCheck=x1_sq/(rx*rx)+y1_sq/(ry*ry);if(radiiCheck>1){rx=_sqrt2(radiiCheck)*rx;ry=_sqrt2(radiiCheck)*ry}var rx_sq=rx*rx,ry_sq=ry*ry,sq=(rx_sq*ry_sq-rx_sq*y1_sq-ry_sq*x1_sq)/(rx_sq*y1_sq+ry_sq*x1_sq);if(sq<0){sq=0}var coef=(largeArcFlag===sweepFlag?-1:1)*_sqrt2(sq),cx1=coef*(rx*y1/ry),cy1=coef*-(ry*x1/rx),sx2=(lastX+x)/2,sy2=(lastY+y)/2,cx=sx2+(cosAngle*cx1-sinAngle*cy1),cy=sy2+(sinAngle*cx1+cosAngle*cy1),ux=(x1-cx1)/rx,uy=(y1-cy1)/ry,vx=(-x1-cx1)/rx,vy=(-y1-cy1)/ry,temp=ux*ux+uy*uy,angleStart=(uy<0?-1:1)*Math.acos(ux/_sqrt2(temp)),angleExtent=(ux*vy-uy*vx<0?-1:1)*Math.acos((ux*vx+uy*vy)/_sqrt2(temp*(vx*vx+vy*vy)));isNaN(angleExtent)&&(angleExtent=PI);if(!sweepFlag&&angleExtent>0){angleExtent-=TWOPI}else if(sweepFlag&&angleExtent<0){angleExtent+=TWOPI}angleStart%=TWOPI;angleExtent%=TWOPI;var segments=Math.ceil(_abs(angleExtent)/(TWOPI/4)),rawPath=[],angleIncrement=angleExtent/segments,controlLength=4/3*_sin2(angleIncrement/2)/(1+_cos2(angleIncrement/2)),ma=cosAngle*rx,mb=sinAngle*rx,mc=sinAngle*-ry,md=cosAngle*ry,i;for(i=0;i<segments;i++){angle=angleStart+i*angleIncrement;x1=_cos2(angle);y1=_sin2(angle);ux=_cos2(angle+=angleIncrement);uy=_sin2(angle);rawPath.push(x1-controlLength*y1,y1+controlLength*x1,ux+controlLength*uy,uy-controlLength*ux,ux,uy)}for(i=0;i<rawPath.length;i+=2){x1=rawPath[i];y1=rawPath[i+1];rawPath[i]=x1*ma+y1*mc+cx;rawPath[i+1]=x1*mb+y1*md+cy}rawPath[i-2]=x;rawPath[i-1]=y;return rawPath}function stringToRawPath(d){var a=(d+"").replace(_scientific,function(m){var n=+m;return n<0.0001&&n>-0.0001?0:n}).match(_svgPathExp)||[],path=[],relativeX=0,relativeY=0,twoThirds=2/3,elements=a.length,points=0,errorMessage="ERROR: malformed path: "+d,i,j,x,y,command,isRelative,segment,startX,startY,difX,difY,beziers,prevCommand,flag1,flag2,line=function line2(sx,sy,ex,ey){difX=(ex-sx)/3;difY=(ey-sy)/3;segment.push(sx+difX,sy+difY,ex-difX,ey-difY,ex,ey)};if(!d||!isNaN(a[0])||isNaN(a[1])){console.log(errorMessage);return path}for(i=0;i<elements;i++){prevCommand=command;if(isNaN(a[i])){command=a[i].toUpperCase();isRelative=command!==a[i]}else{i--}x=+a[i+1];y=+a[i+2];if(isRelative){x+=relativeX;y+=relativeY}if(!i){startX=x;startY=y}if(command==="M"){if(segment){if(segment.length<8){path.length-=1}else{points+=segment.length}}relativeX=startX=x;relativeY=startY=y;segment=[x,y];path.push(segment);i+=2;command="L"}else if(command==="C"){if(!segment){segment=[0,0]}if(!isRelative){relativeX=relativeY=0}segment.push(x,y,relativeX+a[i+3]*1,relativeY+a[i+4]*1,relativeX+=a[i+5]*1,relativeY+=a[i+6]*1);i+=6}else if(command==="S"){difX=relativeX;difY=relativeY;if(prevCommand==="C"||prevCommand==="S"){difX+=relativeX-segment[segment.length-4];difY+=relativeY-segment[segment.length-3]}if(!isRelative){relativeX=relativeY=0}segment.push(difX,difY,x,y,relativeX+=a[i+3]*1,relativeY+=a[i+4]*1);i+=4}else if(command==="Q"){difX=relativeX+(x-relativeX)*twoThirds;difY=relativeY+(y-relativeY)*twoThirds;if(!isRelative){relativeX=relativeY=0}relativeX+=a[i+3]*1;relativeY+=a[i+4]*1;segment.push(difX,difY,relativeX+(x-relativeX)*twoThirds,relativeY+(y-relativeY)*twoThirds,relativeX,relativeY);i+=4}else if(command==="T"){difX=relativeX-segment[segment.length-4];difY=relativeY-segment[segment.length-3];segment.push(relativeX+difX,relativeY+difY,x+(relativeX+difX*1.5-x)*twoThirds,y+(relativeY+difY*1.5-y)*twoThirds,relativeX=x,relativeY=y);i+=2}else if(command==="H"){line(relativeX,relativeY,relativeX=x,relativeY);i+=1}else if(command==="V"){line(relativeX,relativeY,relativeX,relativeY=x+(isRelative?relativeY-relativeX:0));i+=1}else if(command==="L"||command==="Z"){if(command==="Z"){x=startX;y=startY;segment.closed=true}if(command==="L"||_abs(relativeX-x)>0.5||_abs(relativeY-y)>0.5){line(relativeX,relativeY,x,y);if(command==="L"){i+=2}}relativeX=x;relativeY=y}else if(command==="A"){flag1=a[i+4];flag2=a[i+5];difX=a[i+6];difY=a[i+7];j=7;if(flag1.length>1){if(flag1.length<3){difY=difX;difX=flag2;j--}else{difY=flag2;difX=flag1.substr(2);j-=2}flag2=flag1.charAt(1);flag1=flag1.charAt(0)}beziers=arcToSegment(relativeX,relativeY,+a[i+1],+a[i+2],+a[i+3],+flag1,+flag2,(isRelative?relativeX:0)+difX*1,(isRelative?relativeY:0)+difY*1);i+=j;if(beziers){for(j=0;j<beziers.length;j++){segment.push(beziers[j])}}relativeX=segment[segment.length-2];relativeY=segment[segment.length-1]}else{console.log(errorMessage)}}i=segment.length;if(i<6){path.pop();i=0}else if(segment[0]===segment[i-2]&&segment[1]===segment[i-1]){segment.closed=true}path.totalPoints=points+i;return path}function rawPathToString(rawPath){if(_isNumber3(rawPath[0])){rawPath=[rawPath]}var result="",l=rawPath.length,sl,s,i,segment;for(s=0;s<l;s++){segment=rawPath[s];result+="M"+_round3(segment[0])+","+_round3(segment[1])+" C";sl=segment.length;for(i=2;i<sl;i++){result+=_round3(segment[i++])+","+_round3(segment[i++])+" "+_round3(segment[i++])+","+_round3(segment[i++])+" "+_round3(segment[i++])+","+_round3(segment[i])+" "}if(segment.closed){result+="z"}}return result}var _svgPathExp,_scientific,_DEG2RAD2,_RAD2DEG2,_sin2,_cos2,_abs,_sqrt2,_isNumber3=function _isNumber4(value){return typeof value==="number"},_roundingNum=1e5,_round3=function _round4(value){return Math.round(value*_roundingNum)/_roundingNum||0};var init_paths=__esm(()=>{/*!
2 * paths 3.6.0
3 * https://greensock.com
4 *
5 * Copyright 2008-2021, GreenSock. All rights reserved.
6 * Subject to the terms at https://greensock.com/standard-license or for
7 * Club GreenSock members, the agreement issued with that membership.
8 * @author: Jack Doyle, [email protected]
9*/_svgPathExp=/[achlmqstvz]|(-?\d*\.?\d*(?:e[\-+]?\d+)?)[0-9]/ig;_scientific=/[\+\-]?\d*\.?\d+e[\+\-]?\d+/ig;_DEG2RAD2=Math.PI/180;_RAD2DEG2=180/Math.PI;_sin2=Math.sin;_cos2=Math.cos;_abs=Math.abs;_sqrt2=Math.sqrt});var exports_CustomEase={};__export(exports_CustomEase,{default:()=>CustomEase,CustomEase:()=>CustomEase});class CustomEase{constructor(id,data,config3){_coreInitted2||_init
9Core3();this.id=id;_bonusValidated&&this.setData(data,config3)}setData(data,config3){config3=config3||{};data=data||"0,0,1,1";let values=data.match(_numExp2),closest=1,points=[],lookup=[],precision=config3.precision||1,fast=precision<=1,l,a1,a2,i,inc,j,point,prevPoint,p;this.data=data;if(_needsParsingExp.test(data)||~data.indexOf("M")&&data.indexOf("C")<0){values=stringToRawPath(data)[0]}l=values.length;if(l===4){values.unshift(0,0);values.push(1,1);l=8}else if((l-2)%6){throw"Invalid CustomEase"}if(+values[0]!==0||+values[l-2]!==1){_normalize(values,config3.height,config3.originY)}this.segment=values;for(i=2;i<l;i+=6){a1={x:+values[i-2],y:+values[i-1]};a2={x:+values[i+4],y:+values[i+5]};points.push(a1,a2);_bezierToPoints(a1.x,a1.y,+values[i],+values[i+1],+values[i+2],+values[i+3],a2.x,a2.y,1/(precision*200000),points,points.length-1)}l=points.length;for(i=0;i<l;i++){point=points[i];prevPoint=points[i-1]||point;if((point.x>prevPoint.x||prevPoint.y!==point.y&&prevPoint.x===point.x||point===prevPoint)&&point.x<=1){prevPoint.cx=point.x-prevPoint.x;prevPoint.cy=point.y-prevPoint.y;prevPoint.n=point;prevPoint.nx=point.x;if(fast&&i>1&&Math.abs(prevPoint.cy/prevPoint.cx-points[i-2].cy/points[i-2].cx)>2){fast=0}if(prevPoint.cx<closest){if(!prevPoint.cx){prevPoint.cx=0.001;if(i===l-1){prevPoint.x-=0.001;closest=Math.min(closest,0.001);fast=0}}else{closest=prevPoint.cx}}}else{points.splice(i--,1);l--}}l=1/closest+1|0;inc=1/l;j=0;point=points[0];if(fast){for(i=0;i<l;i++){p=i*inc;if(point.nx<p){point=points[++j]}a1=point.y+(p-point.x)/point.cx*point.cy;lookup[i]={x:p,cx:inc,y:a1,cy:0,nx:9};if(i){lookup[i-1].cy=a1-lookup[i-1].y}}lookup[l-1].cy=points[points.length-1].y-a1}else{for(i=0;i<l;i++){if(point.nx<i*inc){point=points[++j]}lookup[i]=point}if(j<points.length-1){lookup[i-1]=points[points.length-2]}}this.ease=(p2)=>{let point2=lookup[p2*l|0]||lookup[l-1];if(point2.nx<p2){point2=point2.n}return point2.y+(p2-point2.x)/point2.cx*point2.cy};this.ease.custom=this;this.id&&gsap2.registerEase(this.id,this.ease);return this}getSVGData(config3){return CustomEase.getSVGData(this,config3)}static create(id,data,config3){return new CustomEase(id,data,config3).ease}static register(core){gsap2=core;_initCore3()}static get(id){return gsap2.parseEase(id)}static getSVGData(ease,config3){config3=config3||{};let width=config3.width||100,height=config3.height||100,x=config3.x||0,y=(config3.y||0)+height,e=gsap2.utils.toArray(config3.path)[0],a,slope,i,inc,tx,ty,precision,threshold,prevX,prevY;if(config3.invert){height=-height;y=0}if(typeof ease==="string"){ease=gsap2.parseEase(ease)}if(ease.custom){ease=ease.custom}if(ease instanceof CustomEase){a=rawPathToString(transformRawPath([ease.segment],width,0,0,-height,x,y))}else{a=[x,y];precision=Math.max(5,(config3.precision||1)*200);inc=1/precision;precision+=2;threshold=5/precision;prevX=_round5(x+inc*width);prevY=_round5(y+ease(inc)*-height);slope=(prevY-y)/(prevX-x);for(i=2;i<precision;i++){tx=_round5(x+i*inc*width);ty=_round5(y+ease(i*inc)*-height);if(Math.abs((ty-prevY)/(tx-prevX)-slope)>threshold||i===precision-1){a.push(prevX,prevY);slope=(ty-prevY)/(tx-prevX)}prevX=tx;prevY=ty}a="M"+a.join(",")}e&&e.setAttribute("d",a);return a}}var gsap2,_coreInitted2,_getGSAP=()=>gsap2||typeof window!=="undefined"&&(gsap2=window.gsap)&&gsap2.registerPlugin&&gsap2,_initCore3=()=>{gsap2=_getGSAP();if(gsap2){gsap2.registerEase("_CE",CustomEase.create);_coreInitted2=1}else{console.warn("Please gsap.registerPlugin(CustomEase)")}},_bigNum3=100000000000000000000,_round5=(value)=>~~(value*1000+(value<0?-0.5:0.5))/1000,_bonusValidated=1,_numExp2,_needsParsingExp,_findMinimum=(values)=>{let l=values.length,min=_bigNum3,i;for(i=1;i<l;i+=6){+values[i]<min&&(min=+values[i])}return min},_normalize=(values,height,originY)=>{if(!originY&&originY!==0){originY=Math.max(+values[values.length-1],+values[1])}let tx=+values[0]*-1,ty=-originY,l=values.length,sx=1/(+values[l-2]+tx),sy=-height||(Math.abs(+values[l-1
9]-+values[1])<0.01*(+values[l-2]-+values[0])?_findMinimum(values)+ty:+values[l-1]+ty),i;if(sy){sy=1/sy}else{sy=-sx}for(i=0;i<l;i+=2){values[i]=(+values[i]+tx)*sx;values[i+1]=(+values[i+1]+ty)*sy}},_bezierToPoints=function(x1,y1,x2,y2,x3,y3,x4,y4,threshold,points,index){let x12=(x1+x2)/2,y12=(y1+y2)/2,x23=(x2+x3)/2,y23=(y2+y3)/2,x34=(x3+x4)/2,y34=(y3+y4)/2,x123=(x12+x23)/2,y123=(y12+y23)/2,x234=(x23+x34)/2,y234=(y23+y34)/2,x1234=(x123+x234)/2,y1234=(y123+y234)/2,dx=x4-x1,dy=y4-y1,d2=Math.abs((x2-x4)*dy-(y2-y4)*dx),d3=Math.abs((x3-x4)*dy-(y3-y4)*dx),length;if(!points){points=[{x:x1,y:y1},{x:x4,y:y4}];index=1}points.splice(index||points.length-1,0,{x:x1234,y:y1234});if((d2+d3)*(d2+d3)>threshold*(dx*dx+dy*dy)){length=points.length;_bezierToPoints(x1,y1,x12,y12,x123,y123,x1234,y1234,threshold,points,index);_bezierToPoints(x1234,y1234,x234,y234,x34,y34,x4,y4,threshold,points,index+1+(points.length-length))}return points};var init_CustomEase=__esm(()=>{init_paths();/*!
10 * CustomEase 3.5.1
11 * https://greensock.com
12 *
13 * @license Copyright 2008-2020, GreenSock. All rights reserved.
14 * Subject to the terms at https://greensock.com/standard-license or for
15 * Club GreenSock members, the agreement issued with that membership.
16 * @author: Jack Doyle, [email protected]
17*/_numExp2=/[-+=\.]*\d+[\.e\-\+]*\d*[e\-\+]*\d*/gi;_needsParsingExp=/[cLlsSaAhHvVtTqQ]/g;_getGSAP()&&gsap2.registerPlugin(CustomEase);CustomEase.version="3.5.1"});var require_types=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.TraceDirectionKey=exports.Direction=exports.Axis=undefined;var TraceDirectionKey;exports.TraceDirectionKey=TraceDirectionKey;(function(TraceDirectionKey2){TraceDirectionKey2["NEGATIVE"]="NEGATIVE";TraceDirectionKey2["POSITIVE"]="POSITIVE";TraceDirectionKey2["NONE"]="NONE"})(TraceDirectionKey||(exports.TraceDirectionKey=TraceDirectionKey={}));var Direction;exports.Direction=Direction;(function(Direction2){Direction2["TOP"]="TOP";Direction2["LEFT"]="LEFT";Direction2["RIGHT"]="RIGHT";Direction2["BOTTOM"]="BOTTOM";Direction2["NONE"]="NONE"})(Direction||(exports.Direction=Direction={}));var Axis;exports.Axis=Axis;(function(Axis2){Axis2["X"]="x";Axis2["Y"]="y"})(Axis||(exports.Axis=Axis={}))});var require_calculateDirection=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.calculateDirection=calculateDirection;var _types=require_types();function calculateDirection(trace){var direction;var negative=_types.TraceDirectionKey.NEGATIVE;var positive=_types.TraceDirectionKey.POSITIVE;var current=trace[trace.length-1];var previous=trace[trace.length-2]||0;if(trace.every(function(i){return i===0})){return _types.TraceDirectionKey.NONE}direction=current>previous?positive:negative;if(current===0){direction=previous<0?positive:negative}return direction}});var require_common=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.resolveAxisDirection=exports.getDirectionValue=exports.getDirectionKey=exports.getDifference=undefined;var _types=require_types();var getDirectionKey=function getDirectionKey2(){var object=arguments.length>0&&arguments[0]!==undefined?arguments[0]:{};var key=Object.keys(object).toString();switch(key){case _types.TraceDirectionKey.POSITIVE:return _types.TraceDirectionKey.POSITIVE;case _types.TraceDirectionKey.NEGATIVE:return _types.TraceDirectionKey.NEGATIVE;default:return _types.TraceDirectionKey.NONE}};exports.getDirectionKey=getDirectionKey;var getDirectionValue=function getDirectionValue2(){var values=arguments.length>0&&arguments[0]!==undefined?arguments[0]:[];return values[values.length-1]||0};exports.getDirectionValue=getDirectionValue;var getDifference=function getDifference2(){var x=arguments.length>0&&arguments[0]!==undefined?arguments[0]:0;var y=arguments.length>1&&arguments[1]!==undefined?arguments[1]:0;return Math.abs(x-y)};exports.getDifference=getDifference;var resolveAxisDirection=function resolveAxisDirection2(axis,key){var negative=_types.Direction.LEFT;var positive=_types.Direction.RIGHT;var direction=_types.Direction.NONE;if(axis===_types.Axis.Y){negative=_types.Direction.BOTTOM;positive=_types.Direction.TOP}if(key===_types.TraceDirectionKey.NEGATIVE){direction=negative}if(key===_types.TraceDirectionKey.POSITIVE){direction=positive}return direction};exports.resolveAxisDirection=resolveAxisDirection});var require_calculateDirectionDelta=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.calculateDirectionDelta=calculateDirectionDelta;var _types=require_types();var _common=require_common();function calculateDirectionDelta(traceDirections){var delta=arguments.length>1&&arguments[1]!==undefined?arguments[1]:0;var length=traceDirections.length;var i=length-1;var direction=_types.TraceDirectionKey.NONE;for(;i>=0;i--){var current=traceDirections[i];var currentKey=(0,_common.getDirectionKey)(current);var currentValue=(0,_common.getDirectionValue)(current[currentKey]);var prev=traceDirections[i-1]||{};var prevKey=(0,_common.getDirectionKey)(prev);var prevValue=(0,_common.getDirectionValue)(prev[prevKey]);var difference=(0,_common.getDifference)(currentValue,prevValue);if(difference>=delta){direction=currentKey;break}else{direction=prevKey}}return direction}});var require_calculateDuration=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.calculateDuration=calculateDuration;function calculateDuration(){var prevTime=arguments.length>0&&arguments[0]!==undefined?arguments[0]:0;var nextTime=arguments.length>1&&arguments[1]!==undefined?arguments[1]:0;return prevTime?nextTime-prevTime:0}});var require_calculateMovingPosition=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.calculateMovingPosition=calculateMovingPosition;function calculateMovingPosition(e){if("changedTouches"in e){var touches=e.changedTouches&&e.changedTouches[0];return{x:touches&&touches.clientX,y:touches&&touches.clientY}}return{x:e.clientX,y:e.clientY}}});var require_updateTrace=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.updateTrace=updateTrace;function updateTrace(trace,value){var last=trace[trace.length-1];if(last!==value){trace.push(value)}return trace}});var require_calculateTraceDirections=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.calculateTraceDirections=calculateTraceDirections;var _types=require_types();function _defineProperty(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value,enumerable:true,configurable:true,writable:true})}else{obj[key]=value}return obj}function calculateTraceDirections(){var trace=arguments.length>0&&arguments[0]!==undefined?arguments[0]:[];var ticks=[];var positive=_types.TraceDirectionKey.POSITIVE;var negative=_types.TraceDirectionKey.NEGATIVE;var i=0;var tick=[];var direction=_types.TraceDirectionKey.NONE;for(;i<trace.length;i++){var current=trace[i];var prev=trace[i-1];if(tick.length){var currentDirection=current>prev?positive:negative;if(direction===_types.TraceDirectionKey.NONE){direction=currentDirection}if(currentDirection===direction){tick.push(current)}else{ticks.push(_defineProperty({},direction,tick.slice()));tick=[];tick.push(current);direction=currentDirection}}else{if(current!==0){direction=current>0?positive:negative}tick.push(current)}}if(tick.length){ticks.push(_defineProperty({},direction,tick))}return ticks}});var require_resolveDirection=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.resolveDirection=resolveDirection;var _calculateDirection=require_calculateDirection();var _calculateTraceDirections=require_calculateTraceDirections();var _calculateDirectionDelta=require_calculateDirectionDelta();var _common=require_common();var _types=require_types();function resolveDirection(trace){var axis=arguments.length>1&&arguments[1]!==undefined?arguments[1]:_types.Axis.X;var directionDelta=arguments.length>2&&arguments[2]!==undefined?arguments[2]:0;if(directionDelta){var directions=(0,_calculateTraceDirections.calculateTraceDirections)(trace);var _direction=(0,_calculateDirectionDelta.calculateDirectionDelta)(directions,directionDelta);return(0,_common.resolveAxisDirection)(axis,_direction)}var direction=(0,_calculateDirection.calculateDirection)(trace);return(0,_common.resolveAxisDirection)(axis,direction)}});var require_calculateVelocity=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.calculateVelocity=calculateVelocity;function calculateVelocity(x,y,time){var magnitude=Math.sqrt(x*x+y*y);return magnitude/(time||1)}});var require_calculatePosition=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.calculatePosition=calculatePosition;var _updateTrace=require_updateTrace();var _resolveDirection=require_resolveDirection();var _calculateDuration=require_calculateDuration();var _calculateVelocity=require_calculateVelocity();var _types=require_types();function calculatePosition(state,options){var{start,x,y,traceX,traceY}=state;var{rotatePosition,directionDelta}=options;var deltaX=rotatePosition.x-x;var deltaY=y-rotatePosition.y;var absX=Math.abs(deltaX);var absY=Math.abs(deltaY);(0,_updateTrace.updateTrace)(traceX,deltaX);(0,_updateTrace.updateTrace)(traceY,deltaY);var directionX=(0,_resolveDirection.resolveDirection)(traceX,_types.Axis.X,directionDelta);var directionY=(0,_resolveDirection.resolveDirection)(traceY,_types.Axis.Y,directionDelta);var duration=(0,_calculateDuration.calculateDuration)(start,Date.now());var velocity=(0,_calculateVelocity.calculateVelocity)(absX,absY,duration);return{absX,absY,deltaX,deltaY,directionX,directionY,duration,positionX:rotatePosition.x,positionY:rotatePosition.y,velocity}}});var require_checkIsMoreThanSingleTouches=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.checkIsMoreThanSingleTouches=undefined;var checkIsMoreThanSingleTouches=function checkIsMoreThanSingleTouches2(e){return Boolean(e.touches&&e.touches.length>1)};exports.checkIsMoreThanSingleTouches=checkIsMoreThanSingleTouches});var require_createOptions=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.createOptions=createOptions;function createOptions(){var proxy=arguments.length>0&&arguments[0]!==undefined?arguments[0]:{};Object.defineProperty(proxy,"passive",{get:function get(){this.isPassiveSupported=true;return true},enumerable:true});return proxy}});var require_checkIsPassiveSupported=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.checkIsPassiveSupported=checkIsPassiveSupported;exports.noop=undefined;var _createOptions=require_createOptions();function checkIsPassiveSupported(isPassiveSupported){if(typeof isPassiveSupported==="boolean"){return isPassiveSupported}var proxy={isPassiveSupported};try{var options=(0,_createOptions.createOptions)(proxy);window.addEventListener("checkIsPassiveSupported",noop,options);window.removeEventListener("checkIsPassiveSupported",noop,options)}catch(err){}return proxy.isPassiveSupported}var noop=function noop2(){};exports.noop=noop});var require_checkIsTouchEventsSupported=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.checkIsTouchEventsSupported=undefined;function _typeof(obj){"@babel/helpers - typeof";return _typeof=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(obj2){return typeof obj2}:function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}var checkIsTouchEventsSupported=function checkIsTouchEventsSupported2(){return(typeof window==="undefined"?"undefined":_typeof(window))==="object"&&(("ontouchstart"in window)||Boolean(window.navigator.maxTouchPoints))};exports.checkIsTouchEventsSupported=checkIsTouchEventsSupported});var require_getInitialState=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.getInitialState=undefined;function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);
17enumerableOnly&&(symbols=symbols.filter(function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable})),keys.push.apply(keys,symbols)}return keys}function _objectSpread(target){for(var i=1;i<arguments.length;i++){var source=arguments[i]!=null?arguments[i]:{};i%2?ownKeys(Object(source),true).forEach(function(key){_defineProperty(target,key,source[key])}):Object.getOwnPropertyDescriptors?Object.defineProperties(target,Object.getOwnPropertyDescriptors(source)):ownKeys(Object(source)).forEach(function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key))})}return target}function _defineProperty(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value,enumerable:true,configurable:true,writable:true})}else{obj[key]=value}return obj}var getInitialState=function getInitialState2(){var options=arguments.length>0&&arguments[0]!==undefined?arguments[0]:{};return _objectSpread({x:0,y:0,start:0,isSwiping:false,traceX:[],traceY:[]},options)};exports.getInitialState=getInitialState});var require_getInitialProps=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.getInitialProps=undefined;function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);enumerableOnly&&(symbols=symbols.filter(function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable})),keys.push.apply(keys,symbols)}return keys}function _objectSpread(target){for(var i=1;i<arguments.length;i++){var source=arguments[i]!=null?arguments[i]:{};i%2?ownKeys(Object(source),true).forEach(function(key){_defineProperty(target,key,source[key])}):Object.getOwnPropertyDescriptors?Object.defineProperties(target,Object.getOwnPropertyDescriptors(source)):ownKeys(Object(source)).forEach(function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key))})}return target}function _defineProperty(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value,enumerable:true,configurable:true,writable:true})}else{obj[key]=value}return obj}var getInitialProps=function getInitialProps2(){var props=arguments.length>0&&arguments[0]!==undefined?arguments[0]:{};return _objectSpread({element:null,target:null,delta:10,directionDelta:0,rotationAngle:0,mouseTrackingEnabled:false,touchTrackingEnabled:true,preventDefaultTouchmoveEvent:false,preventTrackingOnMouseleave:false},props)};exports.getInitialProps=getInitialProps});var require_getOptions=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.getOptions=getOptions;function getOptions(){var isPassiveSupported=arguments.length>0&&arguments[0]!==undefined?arguments[0]:false;if(isPassiveSupported){return{passive:false}}return{}}});var require_rotateByAngle=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});exports.rotateByAngle=rotateByAngle;function rotateByAngle(position){var angle=arguments.length>1&&arguments[1]!==undefined?arguments[1]:0;if(angle===0){return position}var{x,y}=position;var angleInRadians=Math.PI/180*angle;var rotatedX=x*Math.cos(angleInRadians)+y*Math.sin(angleInRadians);var rotatedY=y*Math.cos(angleInRadians)-x*Math.sin(angleInRadians);return{x:rotatedX,y:rotatedY}}});var require_utils=__commonJS((exports)=>{Object.defineProperty(exports,"__esModule",{value:true});var _calculateDirection=require_calculateDirection();Object.keys(_calculateDirection).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_calculateDirection[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _calculateDirection[key]}})});var _calculateDirectionDelta=require_calculateDirectionDelta();Object.keys(_calculateDirectionDelta).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_calculateDirectionDelta[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _calculateDirectionDelta[key]}})});var _calculateDuration=require_calculateDuration();
17Object.keys(_calculateDuration).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_calculateDuration[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _calculateDuration[key]}})});var _calculateMovingPosition=require_calculateMovingPosition();Object.keys(_calculateMovingPosition).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_calculateMovingPosition[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _calculateMovingPosition[key]}})});var _calculatePosition=require_calculatePosition();Object.keys(_calculatePosition).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_calculatePosition[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _calculatePosition[key]}})});var _calculateTraceDirections=require_calculateTraceDirections();Object.keys(_calculateTraceDirections).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_calculateTraceDirections[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _calculateTraceDirections[key]}})});var _calculateVelocity=require_calculateVelocity();Object.keys(_calculateVelocity).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_calculateVelocity[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _calculateVelocity[key]}})});var _checkIsMoreThanSingleTouches=require_checkIsMoreThanSingleTouches();Object.keys(_checkIsMoreThanSingleTouches).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_checkIsMoreThanSingleTouches[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _checkIsMoreThanSingleTouches[key]}})});var _checkIsPassiveSupported=require_checkIsPassiveSupported();Object.keys(_checkIsPassiveSupported).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_checkIsPassiveSupported[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _checkIsPassiveSupported[key]}})});var _checkIsTouchEventsSupported=require_checkIsTouchEventsSupported();Object.keys(_checkIsTouchEventsSupported).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_checkIsTouchEventsSupported[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _checkIsTouchEventsSupported[key]}})});var _common=require_common();Object.keys(_common).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_common[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _common[key]}})});var _createOptions=require_createOptions();Object.keys(_createOptions).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_createOptions[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _createOptions[key]}})});var _getInitialState=require_getInitialState();Object.keys(_getInitialState).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_getInitialState[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _getInitialState[key]}})});var _getInitialProps=require_getInitialProps();Object.keys(_getInitialProps).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_getInitialProps[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _getInitialProps[key]}})});var _getOptions=require_getOptions();Object.keys(_getOptions).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_getOptions[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _getOptions[key]}})});var _resolveDirection=require_resolveDirection();
17Object.keys(_resolveDirection).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_resolveDirection[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _resolveDirection[key]}})});var _rotateByAngle=require_rotateByAngle();Object.keys(_rotateByAngle).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_rotateByAngle[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _rotateByAngle[key]}})});var _updateTrace=require_updateTrace();Object.keys(_updateTrace).forEach(function(key){if(key==="default"||key==="__esModule")return;if(key in exports&&exports[key]===_updateTrace[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _updateTrace[key]}})})});var require_lib=__commonJS((exports)=>{function _typeof(obj){"@babel/helpers - typeof";return _typeof=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(obj2){return typeof obj2}:function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}Object.defineProperty(exports,"__esModule",{value:true});var _exportNames={};exports["default"]=undefined;var Utils=_interopRequireWildcard(require_utils());var _types=require_types();Object.keys(_types).forEach(function(key){if(key==="default"||key==="__esModule")return;if(Object.prototype.hasOwnProperty.call(_exportNames,key))return;if(key in exports&&exports[key]===_types[key])return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _types[key]}})});function _getRequireWildcardCache(nodeInterop){if(typeof WeakMap!=="function")return null;var cacheBabelInterop=new WeakMap;var cacheNodeInterop=new WeakMap;return(_getRequireWildcardCache=function _getRequireWildcardCache2(nodeInterop2){return nodeInterop2?cacheNodeInterop:cacheBabelInterop})(nodeInterop)}function _interopRequireWildcard(obj,nodeInterop){if(!nodeInterop&&obj&&obj.__esModule){return obj}if(obj===null||_typeof(obj)!=="object"&&typeof obj!=="function"){return{default:obj}}var cache=_getRequireWildcardCache(nodeInterop);if(cache&&cache.has(obj)){return cache.get(obj)}var newObj={};var hasPropertyDescriptor=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var key in obj){if(key!=="default"&&Object.prototype.hasOwnProperty.call(obj,key)){var desc=hasPropertyDescriptor?Object.getOwnPropertyDescriptor(obj,key):null;if(desc&&(desc.get||desc.set)){Object.defineProperty(newObj,key,desc)}else{newObj[key]=obj[key]}}}newObj["default"]=obj;if(cache){cache.set(obj,newObj)}return newObj}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);Object.defineProperty(Constructor,"prototype",{writable:false});return Constructor}function _defineProperty(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value,enumerable:true,configurable:true,writable:true})}else{obj[key]=value}return obj}var VanillaSwipe=function(){function VanillaSwipe2(props){_classCallCheck(this,VanillaSwipe2);_defineProperty(this,"state",undefined);_defineProperty(this,"props",undefined);this.state=Utils.getInitialState();this.props=Utils.getInitialProps(props);this.handleSwipeStart=this.handleSwipeStart.bind(this);this.handleSwipeMove=this.handleSwipeMove.bind(this);this.handleSwipeEnd=this.handleSwipeEnd.bind(this);this.handleMouseDown=this.handleMouseDown.bind(this);this.handleMouseMove=this.handleMouseMove.bind(this);this.handleMouseUp=this.handleMouseUp.bind(this);this.handleMouseLeave=this.handleMouseLeave.bind(this)}_createClass(VanillaSwipe2,[{key:"init",value:function init4(){this.setupTouchListeners();this.setupMouseListeners()}},{key:"update",value:function update(props){var prevProps=this.props;var nextProps=Object.assign({},prevProps,props);if(prevProps.element!==nextProps.element||prevProps.target!==nextProps.target){this.destroy();this.props=nextProps;this.init();return}this.props=nextProps;if(prevProps.mouseTrackingEnabled!==nextProps.mouseTrackingEnabled||prevProps.preventTrackingOnMouseleave!==nextProps.preventTrackingOnMouseleave){this.cleanupMouseListeners();nextProps.mouseTrackingEnabled?this.setupMouseListeners():this.cleanupMouseListeners()}if(prevProps.touchTrackingEnabled!==nextProps.touchTrackingEnabled){this.cleanupTouchListeners();nextProps.touchTrackingEnabled?this.setupTouchListeners():this.cleanupTouchListeners()}}},{key:"destroy",value:function destroy(){this.cleanupMouseListeners();this.cleanupTouchListeners();this.state=Utils.getInitialState();this.props=Utils.getInitialProps()}},{key:"setupTouchListeners",value:function setupTouchListeners(){var _this$props=this.props,element=_this$props.element,target=_this$props.target,touchTrackingEnabled=_this$props.touchTrackingEnabled;if(element&&touchTrackingEnabled){var listener=target||element;var isPassiveSupported=Utils.checkIsPassiveSupported();var options=Utils.getOptions(isPassiveSupported);listener.addEventListener("touchstart",this.handleSwipeStart,options);listener.addEventListener("touchmove",this.handleSwipeMove,options);listener.addEventListener("touchend",this.handleSwipeEnd,options)}}},{key:"cleanupTouchListeners",value:function cleanupTouchListeners(){var _this$props2=this.props,element=_this$props2.element,target=_this$props2.target;var listener=target||element;if(listener){listener.removeEventListener("touchstart",this.handleSwipeStart);listener.removeEventListener("touchmove",this.handleSwipeMove);listener.removeEventListener("touchend",this.handleSwipeEnd)}}},{key:"setupMouseListeners",value:function setupMouseListeners(){var _this$props3=this.props,element=_this$props3.element,mouseTrackingEnabled=_this$props3.mouseTrackingEnabled,preventTrackingOnMouseleave=_this$props3.preventTrackingOnMouseleave;if(mouseTrackingEnabled&&element){element.addEventListener("mousedown",this.handleMouseDown);element.addEventListener("mousemove",this.handleMouseMove);element.addEventListener("mouseup",this.handleMouseUp);if(preventTrackingOnMouseleave){element.addEventListener("mouseleave",this.handleMouseLeave)}}}},{key:"cleanupMouseListeners",value:function cleanupMouseListeners(){var element=this.props.element;if(element){element.removeEventListener("mousedown",this.handleMouseDown);element.removeEventListener("mousemove",this.handleMouseMove);element.removeEventListener("mouseup",this.handleMouseUp);element.removeEventListener("mouseleave",this.handleMouseLeave)}}},{key:"getEventData",value:function getEventData(e){var options=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{directionDelta:0};var rotationAngle=this.props.rotationAngle;var directionDelta=options.directionDelta;var movingPosition=Utils.calculateMovingPosition(e);var rotatePosition=Utils.rotateByAngle(movingPosition,rotationAngle);return Utils.calculatePosition(this.state,{rotatePosition,directionDelta})}},{key:"handleSwipeStart",value:function handleSwipeStart(e){if(Utils.checkIsMoreThanSingleTouches(e))return;var rotationAngle=this.props.rotationAngle;var movingPosition=Utils.calculateMovingPosition(e);var _Utils$rotateByAngle=Utils.rotateByAngle(movingPosition,rotationAngle),x=_Utils$rotateByAngle.x,y=_Utils$rotateByAngle.y;this.state=Utils.getInitialState({isSwiping:false,start:Date.now(),x,y})}},{key:"handleSwipeMove",value:function handleSwipeMove(e){var _this$state=this.state,x=_this$state.x,y=_this$state.y,isSwiping=_this$state.isSwiping;if(!x||!y||Utils.checkIsMoreThanSingleTouches(e))return;var directionDelta=this.props.directionDelta||0;var _this$getEventData=this.getEventData(e,{directionDelta}),absX=_this$getEventData.absX,absY=_this$getEventData.absY,deltaX=_this$getEventData.deltaX,deltaY=_this$getEventData.deltaY,directionX=_this$getEventData.directionX,directionY=_this$getEventData.directionY,duration=_this$getEventData.duration,velocity=_this$getEventData.velocity;var _this$props4=this.props,delta=_this$props4.delta,preventDefaultTouchmoveEvent=_this$props4.preventDefaultTouchmoveEvent,onSwipeStart=_this$props4.onSwipeStart,onSwiping=_this$props4.onSwiping;if(e.cancelable&&preventDefaultTouchmoveEvent)e.preventDefault();if(absX<Number(delta)&&absY<Number(delta)&&!isSwiping)return;if(onSwipeStart&&!isSwiping){onSwipeStart(e,{deltaX,deltaY,absX,absY,directionX,directionY,duration,velocity})}this.state.isSwiping=true;if(onSwiping){onSwiping(e,{deltaX,deltaY,absX,absY,directionX,directionY,duration,velocity})}}},{key:"handleSwipeEnd",value:function handleSwipeEnd(e){var _this$props5=this.props,onSwiped=_this$props5.onSwiped,onTap=_this$props5.onTap;if(this.state.isSwiping){var directionDelta=this.props.directionDelta||0;var position=this.getEventData(e,{directionDelta});onSwiped&&onSwiped(e,position)}else{var _position=this.getEventData(e);onTap&&onTap(e,_position)}this.state=Utils.getInitialState()}},{key:"handleMouseDown",value:function handleMouseDown(e){var target=this.props.target;if(target){if(target===e.target){this.handleSwipeStart(e)}}else{this.handleSwipeStart(e)}}},{key:"handleMouseMove",value:function handleMouseMove(e){this.handleSwipeMove(e)}},{key:"handleMouseUp",value:function handleMouseUp(e){var isSwiping=this.state.isSwiping;var target=this.props.target;if(target){if(target===e.target||isSwiping){this.handleSwipeEnd(e)}}else{this.handleSwipeEnd(e)}}},{key:"handleMouseLeave",value:function handleMouseLeave(e){var isSwiping=this.state.isSwiping;if(isSwiping){this.handleSwipeEnd(e)}}}],[{key:"isTouchEventsSupported",value:function isTouchEventsSupported(){return Utils.checkIsTouchEventsSupported()}}]);return VanillaSwipe2}();exports["default"]=VanillaSwipe});var exports_signature={};__export(exports_signature,{printHallucinesSignature:()=>printHallucinesSignature});function printHallucinesSignature(){console.log(`
18%c Par IMPRNNCBL - https://imprnncbl.studio \uD83E\uDD18
19 \uD83D\uDC49 Design @crssrd - https://crssrd.com               
20 \uD83D\uDC49 Code @zouloux - https://zouloux.com               `,"background-color: black; padding: 16px; color: white; font-weight: bold; font-size: 12px")}var exports_recreation_shop={};__export(exports_recreation_shop,{isResponsiveMobile:()=>isResponsiveMobile,getCurrentPage:()=>getCurrentPage,getAppView:()=>getAppView});function selectorDefaults(containerOrSelector,selector){let container=containerOrSelector;if(selector==null){selector=containerOrSelector;container=document.documentElement}return[container,selector]}function $$(containerOrSelector,selector){const[c,s]=selectorDefaults(containerOrSelector,selector);const list=[];
20c.querySelectorAll(s).forEach((node,i)=>list[i]=node);return list}function $(containerOrSelector,selector){const[c,s]=selectorDefaults(containerOrSelector,selector);return c.querySelector(s)}function getParentWithClass(target,className){while(target!=document.body){if(!target||!target.parentElement)break;if(target.classList.contains(className))return target;target=target.parentElement}return null}function wire(element,events,connect,handler,options){const subWire=(eventName)=>connect?element.addEventListener(eventName,handler,options):element.removeEventListener(eventName,handler,options);Array.isArray(events)?events.map(subWire):subWire(events)}function defaultElement(elementOrSelector){return typeof elementOrSelector==="string"?$(elementOrSelector):elementOrSelector}function defaultScopedHandler(handler){let scope=null;if(Array.isArray(handler)){const scopeIndex=typeof handler[0]==="object"?0:1;scope=handler[scopeIndex];handler=handler[1-scopeIndex]}return[handler,scope]}function listen(one,elementOrSelector,events,scopedHandler,options){const element=defaultElement(elementOrSelector);const[handler,scope]=defaultScopedHandler(scopedHandler);if(!element)throw new Error(`Yadl.events // Element for event ${JSON.stringify(events)} is null`);function proxy(event){if(one)return wire(element,events,false,proxy,options);return scope?handler.apply(scope,[event]):handler(event)}wire(element,events,true,proxy,options);return()=>wire(element,events,false,proxy,options)}var onEvent=(elementOrSelector,events,handler,options)=>listen(false,elementOrSelector,events,handler,options);async function ready(){return new Promise((resolve)=>{if(document.readyState!=="loading")resolve();else document.addEventListener("DOMContentLoaded",resolve)})}function getComponentClass(component,before="",after=""){if(typeof component.name==="string"&&component.name!=="Function")return before+component.name+after;else if(component.constructor&&typeof component.constructor.name==="string"&&component.constructor.name!=="function")return before+component.constructor.name+after;else return before+"Component"+after}function defaultRef(component,selector,props){if(typeof selector!="string"&&!props){props=selector;selector=null}if(selector&&selector.indexOf("_")===0)selector=getComponentClass(component,".",selector);return[selector,props]}class DomComponent{props;base;constructor(base=null,props){this.base=base??$(getComponentClass(this,"."));this.props=props;window.setTimeout(()=>this.init(),0)}init(){}find(selector,events){const $element=$(this.base,defaultRef(this,selector)[0]);events&&this.addEventsToElement($element,events);return $element}multiFind(selector,events){const $elements=$$(this.base,defaultRef(this,selector)[0]);events&&$elements.map(($element)=>this.addEventsToElement($element,events));return $elements}ref(ComponentClass,selectorOrProps,props){const[s,p]=defaultRef(this,selectorOrProps,props);const selector=s||getComponentClass(ComponentClass,".");const $element=$(this.base,selector);if(!$element)throw new Error(`DomComponent.ref // Component with selector '${selector}' not found in ${getComponentClass(this)}.`);return new ComponentClass($element,p)}lazyRef(ComponentClass,selectorOrProps,props){const[s,p]=defaultRef(this,selectorOrProps,props);const selector=s||getComponentClass(ComponentClass,".");const $element=$(this.base,selector);if(!$element)return null;return new ComponentClass($element,p)}multiRef(ComponentClass,selectorOrProps,props){const[s,p]=defaultRef(this,selectorOrProps,props);const refs=[];$$(this.base,s||getComponentClass(ComponentClass,".")).map((el,i)=>refs.push(new ComponentClass(el,{index:i,...Array.isArray(p)&&i in p?p[i]:typeof p==="object"?p:typeof p==="function"?p(i,el):null})));return refs}_events=[];addEventsToElement($element,events){Object.keys(events).map((eventKey)=>this._events.push(onEvent($element,eventKey.split(" "),events[eventKey].bind(this))))}dispose(){this._events.map((event)=>event());delete this._events}}function setAttributes(element,attributes){Object.keys(attributes).map((key)=>{let value=attributes[key];if(value===true||value==="")value="";else if(value===false||value===null)return;element.setAttribute(key,value)})}function create(htmlOrTagName,attributes,styleProperties){let element;if(htmlOrTagName.indexOf("<")===-1)element=document.createElement(htmlOrTagName);else{const el=document.createElement("div");el.innerHTML=htmlOrTagName;element=el.firstElementChild}attributes&&setAttributes(element,attributes);styleProperties&&setStyle(element,styleProperties);return element}function setStyle(element,style){const elements=Array.isArray(element)?element:[element];elements.map((el)=>{Object.keys(style).map((property)=>{let value=null;switch(typeof style[property]){case"string":value=style[property];break;case"number":value=style[property];break;case"function":value=style[property](element,style);break}el.style[property]=value})})}var Cookey=(key,defaultValue)=>{key=Cookey.NAMESPACE+"$"+key;return(value)=>{if(value===undefined)return JSON.parse(localStorage.getItem(key))??defaultValue;else if(value===null)localStorage.removeItem(key);else localStorage.setItem(key,JSON.stringify(value))}};Cookey.NAMESPACE="cookey";var _gridCookey=Cookey("gridDebugVisible");var _keyboardListener;class GridDebug extends DomComponent{_visible;get visible(){return this._visible}init(){if(!this.base){this.base=create("div",{class:"GridDebug"});document.body.append(this.base)}this.setVisibility(_gridCookey()??0);_keyboardListener&&_keyboardListener();_keyboardListener=onEvent(document,"keyup",(e)=>{if(!e.ctrlKey||e.code!="KeyG")return;e.preventDefault();let newVisibility=this._visible+1;if(newVisibility>=3)newVisibility=0;this.setVisibility(newVisibility)})}setVisibility(visibility){console.log("GridDebug.setVisibility",visibility);this._visible=visibility;setStyle(this.base,{display:visibility>=1?"block":"none",opacity:visibility/2});_gridCookey(this._visible)}}function _assertThisInitialized(self){if(self===undefined){throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}return self}function _inheritsLoose(subClass,superClass){subClass.prototype=Object.create(superClass.prototype);subClass.prototype.constructor=subClass;subClass.__proto__=superClass}/*!
21 * GSAP 3.6.0
22 * https://greensock.com
23 *
24 * @license Copyright 2008-2021, GreenSock. All rights reserved.
25 * Subject to the terms at https://greensock.com/standard-license or for
26 * Club GreenSock members, the agreement issued with that membership.
27 * @author: Jack Doyle, [email protected]
28*/var _config={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}};var _defaults={duration:0.5,overwrite:false,delay:0};var _suppressOverwrites;var _bigNum=1e8;var _tinyNum=1/_bigNum;var _2PI=Math.PI*2;var _HALF_PI=_2PI/4;var _gsID=0;var _sqrt=Math.sqrt;var _cos=Math.cos;var _sin=Math.sin;var _isString=function _isString2(value){return typeof value==="string"};var _isFunction=function _isFunction2(value){return typeof value==="function"};var _isNumber=function _isNumber2(value){return typeof value==="number"};var _isUndefined=function _isUndefined2(value){return typeof value==="undefined"};var _isObject=function _isObject2(value){return typeof value==="object"};var _isNotFalse=function _isNotFalse2(value){return value!==false};var _windowExists=function _windowExists2(){return typeof window!=="undefined"};var _isFuncOrString=function _isFuncOrString2(value){return _isFunction(value)||_isString(value)};var _isTypedArray=typeof ArrayBuffer==="function"&&ArrayBuffer.isView||function(){};var _isArray=Array.isArray;var _strictNumExp=/(?:-?\.?\d|\.)+/gi;var _numExp=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g;var _numWithUnitExp=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g;var _complexStringNumExp=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi;var _relExp=/[+-]=-?[.\d]+/;var _delimitedValueExp=/[#\-+.]*\b[a-z\d-=+%.]+/gi;var _unitExp=/[\d.+\-=]+(?:e[-+]\d*)*/i;var _globalTimeline;var _win;var _coreInitted;var _doc;var _globals={};var _installScope={};var _coreReady;var _install=function _install2(scope){return(_installScope=_merge(scope,_globals))&&gsap};var _missingPlugin=function _missingPlugin2(property,value){return console.warn("Invalid property",property,"set to",value,"Missing plugin? gsap.registerPlugin()")};var _warn=function _warn2(message,suppress){return!suppress&&console.warn(message)};var _addGlobal=function _addGlobal2(name,obj){return name&&(_globals[name]=obj)&&_installScope&&(_installScope[name]=obj)||_globals};var _emptyFunc=function _emptyFunc2(){return 0};var _reservedProps={};var _lazyTweens=[];var _lazyLookup={};var _lastRenderedFrame;var _plugins={};var _effects={};var _nextGCFrame=30;var _harnessPlugins=[];var _callbackNames="";var _harness=function _harness2(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};var _getCache=function _getCache2(target){return target._gsap||_harness(toArray(target))[0]._gsap};var _getProperty=function _getProperty2(target,property,v){return(v=target[property])&&_isFunction(v)?target[property]():_isUndefined(v)&&target.getAttribute&&target.getAttribute(property)||v};
28var _forEachName=function _forEachName2(names,func){return(names=names.split(",")).forEach(func)||names};var _round=function _round2(value){return Math.round(value*1e5)/1e5||0};var _arrayContainsAny=function _arrayContainsAny2(toSearch,toFind){var l=toFind.length,i=0;for(;toSearch.indexOf(toFind[i])<0&&++i<l;){}return i<l};var _parseVars=function _parseVars2(params,type,parent){var isLegacy=_isNumber(params[1]),varsIndex=(isLegacy?2:1)+(type<2?0:1),vars=params[varsIndex],irVars;isLegacy&&(vars.duration=params[1]);vars.parent=parent;if(type){irVars=vars;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 vars};var _lazyRender=function _lazyRender2(){var l=_lazyTweens.length,a=_lazyTweens.slice(0),i,tween;_lazyLookup={};_lazyTweens.length=0;for(i=0;i<l;i++){tween=a[i];tween&&tween._lazy&&(tween.render(tween._lazy[0],tween._lazy[1],true)._lazy=0)}};var _lazySafeRender=function _lazySafeRender2(animation,time,suppressEvents,force){_lazyTweens.length&&_lazyRender();animation.render(time,suppressEvents,force);_lazyTweens.length&&_lazyRender()};var _numericIfPossible=function _numericIfPossible2(value){var n=parseFloat(value);return(n||n===0)&&(value+"").match(_delimitedValueExp).length<2?n:_isString(value)?value.trim():value};var _passThrough=function _passThrough2(p){return p};var _setDefaults=function _setDefaults2(obj,defaults){for(var p in defaults){p in obj||(obj[p]=defaults[p])}return obj};var _setKeyframeDefaults=function _setKeyframeDefaults2(obj,defaults){for(var p in defaults){p in obj||p==="duration"||p==="ease"||(obj[p]=defaults[p])}};var _merge=function _merge2(base,toMerge){for(var p in toMerge){base[p]=toMerge[p]}return base};var _mergeDeep=function _mergeDeep2(base,toMerge){for(var p in toMerge){p!=="__proto__"&&p!=="constructor"&&p!=="prototype"&&(base[p]=_isObject(toMerge[p])?_mergeDeep2(base[p]||(base[p]={}),toMerge[p]):toMerge[p])}return base};var _copyExcluding=function _copyExcluding2(obj,excluding){var copy={},p;for(p in obj){p in excluding||(copy[p]=obj[p])}return copy};var _inheritDefaults=function _inheritDefaults2(vars){var parent=vars.parent||_globalTimeline,func=vars.keyframes?_setKeyframeDefaults:_setDefaults;if(_isNotFalse(vars.inherit)){while(parent){func(vars,parent.vars.defaults);parent=parent.parent||parent._dp}}return vars};var _arraysMatch=function _arraysMatch2(a1,a2){var i=a1.length,match=i===a2.length;while(match&&i--&&a1[i]===a2[i]){}return i<0};var _addLinkedListItem=function _addLinkedListItem2(parent,child,firstProp,lastProp,sortBy){if(firstProp===undefined){firstProp="_first"}if(lastProp===undefined){lastProp="_last"}var prev=parent[lastProp],t;if(sortBy){t=child[sortBy];while(prev&&prev[sortBy]>t){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};var _removeLinkedListItem=function _removeLinkedListItem2(parent,child,firstProp,lastProp){if(firstProp===undefined){firstProp="_first"}if(lastProp===undefined){lastProp="_last"}var{_prev:prev,_next:next}=child;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};var _removeFromParent=function _removeFromParent2(child,onlyIfParentHasAutoRemove){child.parent&&(!onlyIfParentHasAutoRemove||child.parent.autoRemoveChildren)&&child.parent.remove(child);child._act=0};var _uncache=function _uncache2(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};var _recacheAncestors=function _recacheAncestors2(animation){var parent=animation.parent;while(parent&&parent.parent){parent._dirty=1;parent.totalDuration();parent=parent.parent}return animation};var _hasNoPausedAncestors=function _hasNoPausedAncestors2(animation){return!animation||animation._ts&&_hasNoPausedAncestors2(animation.parent)};var _elapsedCycleDuration=function _elapsedCycleDuration2(animation){return animation._repeat?_animationCycle(animation._tTime,animation=animation.duration()+animation._rDelay)*animation:0};var _animationCycle=function _animationCycle2(tTime,cycleDuration){var whole=Math.floor(tTime/=cycleDuration);return tTime&&whole===tTime?whole-1:whole};var _parentToChildTotalTime=function _parentToChildTotalTime2(parentTime,child){return(parentTime-child._start)*child._ts+(child._ts>=0?0:child._dirty?child.totalDuration():child._tDur)};var _setEnd=function _setEnd2(animation){return animation._end=_round(animation._start+(animation._tDur/Math.abs(animation._ts||animation._rts||_tinyNum)||0))};var _alignPlayhead=function _alignPlayhead2(animation,totalTime){var parent=animation._dp;if(parent&&parent.smoothChildTiming&&animation._ts){animation._start=_round(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};var _postAddChecks=function _postAddChecks2(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,true)}}if(_uncache(timeline,child)._dp&&timeline._initted&&timeline._time>=timeline._dur&&timeline._ts){if(timeline._dur<timeline.duration()){t=timeline;while(t._dp){t.rawTime()>=0&&t.totalTime(t._tTime);t=t._dp}}timeline._zTime=-_tinyNum}};
28var _addToTimeline=function _addToTimeline2(timeline,child,position,skipChecks){child.parent&&_removeFromParent(child);child._start=_round(position+child._delay);child._end=_round(child._start+(child.totalDuration()/Math.abs(child.timeScale())||0));_addLinkedListItem(timeline,child,"_first","_last",timeline._sort?"_start":0);timeline._recent=child;skipChecks||_postAddChecks(timeline,child);return timeline};var _scrollTrigger=function _scrollTrigger2(animation,trigger){return(_globals.ScrollTrigger||_missingPlugin("scrollTrigger",trigger))&&_globals.ScrollTrigger.create(trigger,animation)};var _attemptInitTween=function _attemptInitTween2(tween,totalTime,force,suppressEvents){_initTween(tween,totalTime);if(!tween._initted){return 1}if(!force&&tween._pt&&(tween._dur&&tween.vars.lazy!==false||!tween._dur&&tween.vars.lazy)&&_lastRenderedFrame!==_ticker.frame){_lazyTweens.push(tween);tween._lazy=[totalTime,suppressEvents];return 1}};var _parentPlayheadIsBeforeStart=function _parentPlayheadIsBeforeStart2(_ref){var parent=_ref.parent;return parent&&parent._ts&&parent._initted&&!parent._lock&&(parent.rawTime()<0||_parentPlayheadIsBeforeStart2(parent))};var _renderZeroDurationTween=function _renderZeroDurationTween2(tween,totalTime,suppressEvents,force){var prevRatio=tween.ratio,ratio=totalTime<0||!totalTime&&(!tween._start&&_parentPlayheadIsBeforeStart(tween)||(tween._ts<0||tween._dp._ts<0)&&tween.data!=="isFromStart"&&tween.data!=="isStart")?0:1,repeatDelay=tween._rDelay,tTime=0,pt,iteration,prevIteration;if(repeatDelay&&tween._repeat){tTime=_clamp(0,tween._tDur,totalTime);iteration=_animationCycle(tTime,repeatDelay);prevIteration=_animationCycle(tween._tTime,repeatDelay);tween._yoyo&&iteration&1&&(ratio=1-ratio);if(iteration!==prevIteration){prevRatio=1-ratio;tween.vars.repeatRefresh&&tween._initted&&tween.invalidate()}}if(ratio!==prevRatio||force||tween._zTime===_tinyNum||!totalTime&&tween._zTime){if(!tween._initted&&_attemptInitTween(tween,totalTime,force,suppressEvents)){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;suppressEvents||_callback(tween,"onStart");pt=tween._pt;while(pt){pt.r(ratio,pt.d);pt=pt._next}tween._startAt&&totalTime<0&&tween._startAt.render(totalTime,true,true);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){_callback(tween,ratio?"onComplete":"onReverseComplete",true);tween._prom&&tween._prom()}}}else if(!tween._zTime){tween._zTime=totalTime}};var _findNextPauseTween=function _findNextPauseTween2(animation,prevTime,time){var child;if(time>prevTime){child=animation._first;while(child&&child._start<=time){if(!child._dur&&child.data==="isPause"&&child._start>prevTime){return child}child=child._next}}else{child=animation._last;while(child&&child._start>=time){if(!child._dur&&child.data==="isPause"&&child._start<prevTime){return child}child=child._prev}}};var _setDuration=function _setDuration2(animation,duration,skipUncache,leavePlayhead){var repeat=animation._repeat,dur=_round(duration)||0,totalProgress=animation._tTime/animation._tDur;totalProgress&&!leavePlayhead&&(animation._time*=dur/animation._dur);animation._dur=dur;animation._tDur=!repeat?dur:repeat<0?10000000000:_round(dur*(repeat+1)+animation._rDelay*repeat);totalProgress&&!leavePlayhead?_alignPlayhead(animation,animation._tTime=animation._tDur*totalProgress):animation.parent&&_setEnd(animation);skipUncache||_uncache(animation.parent,animation);return animation};var _onUpdateTotalDuration=function _onUpdateTotalDuration2(animation){return animation instanceof Timeline?_uncache(animation):_setDuration(animation,animation._dur)};var _zeroPosition={_start:0,endTime:_emptyFunc};var _parsePosition=function _parsePosition2(animation,position){var labels=animation.labels,recent=animation._recent||_zeroPosition,clippedDuration=animation.duration()>=_bigNum?recent.endTime(false):animation._dur,i,offset;if(_isString(position)&&(isNaN(position)||(position in labels))){i=position.charAt(0);if(i==="<"||i===">"){return(i==="<"?recent._start:recent.endTime(recent._repeat>=0))+(parseFloat(position.substr(1))||0)}i=position.indexOf("=");if(i<0){position in labels||(labels[position]=clippedDuration);return labels[position]}offset=+(position.charAt(i-1)+position.substr(i+1));return i>1?_parsePosition2(animation,position.substr(0,i-1))+offset:clippedDuration+offset}return position==null?clippedDuration:+position};var _conditionalReturn=function _conditionalReturn2(value,func){return value||value===0?func(value):func};var _clamp=function _clamp2(min,max,value){return value<min?min:value>max?max:value};var getUnit=function getUnit2(value){if(typeof value!=="string"){return""}var v=_unitExp.exec(value);return v?value.substr(v.index+v[0].length):""};var clamp=function clamp2(min,max,value){return _conditionalReturn(value,function(v){return _clamp(min,max,v)})};var _slice=[].slice;var _isArrayLike=function _isArrayLike2(value,nonEmpty){return value&&_isObject(value)&&"length"in value&&(!nonEmpty&&!value.length||(value.length-1 
28in value)&&_isObject(value[0]))&&!value.nodeType&&value!==_win};var _flatten=function _flatten2(ar,leaveStrings,accumulator){if(accumulator===undefined){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};var toArray=function toArray2(value,leaveStrings){return _isString(value)&&!leaveStrings&&(_coreInitted||!_wake())?_slice.call(_doc.querySelectorAll(value),0):_isArray(value)?_flatten(value,leaveStrings):_isArrayLike(value)?_slice.call(value,0):value?[value]:[]};var shuffle=function shuffle2(a){return a.sort(function(){return 0.5-Math.random()})};var distribute=function distribute2(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:0.5,edges:0.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)&&wrapAt<l){}wrapAt--}distances=cache[l]=[];originX=ratios?Math.min(wrapAt,l)*ratioX-0.5:from%wrapAt;originY=ratios?l*ratioY/wrapAt-0.5:from/wrapAt|0;max=0;min=_bigNum;for(j=0;j<l;j++){x=j%wrapAt-originX;y=originY-(j/wrapAt|0);distances[j]=d=!axis?_sqrt(x*x+y*y):Math.abs(axis==="y"?y:x);d>max&&(max=d);d<min&&(min=d)}from==="random"&&shuffle(distances);distances.max=max-min;distances.min=min;distances.v=l=(parseFloat(vars.amount)||parseFloat(vars.each)*(wrapAt>l?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 _round(distances.b+(ease?ease(l):l)*distances.v)+distances.u}};var _roundModifier=function _roundModifier2(v){var p=v<1?Math.pow(10,(v+"").length-2):1;return function(raw){var n=Math.round(parseFloat(raw)/v)*v*p;return(n-n%1)/p+(_isNumber(raw)?0:getUnit(raw))}};var snap=function snap2(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(dx<min){min=dx;closest=i}}closest=!radius||min<=radius?snapTo[closest]:raw;return is2D||closest===raw||_isNumber(raw)?closest:closest+getUnit(raw)})};var random=function random2(min,max,roundingIncrement,returnFunction){return _conditionalReturn(_isArray(min)?!max:roundingIncrement===true?!!(roundingIncrement=0):!returnFunction,function(){return _isArray(min)?min[~~(Math.random()*min.length)]:(roundingIncrement=roundingIncrement||0.00001)&&(returnFunction=roundingIncrement<1?Math.pow(10,(roundingIncrement+"").length-2):1)&&Math.floor(Math.round((min-roundingIncrement/2+Math.random()*(max-min+roundingIncrement*0.99))/roundingIncrement)*roundingIncrement*returnFunction)/returnFunction})};var pipe=function pipe2(){for(var _len=arguments.length,functions=new Array(_len),_key=0;_key<_len;_key++){functions[_key]=arguments[_key]}return function(value){return functions.reduce(function(v,f){return f(v)},value)}};var unitize=function unitize2(func,unit){return function(value){return func(parseFloat(value))+(unit||getUnit(value))}};var normalize=function normalize2(min,max,value){return mapRange(min,max,0,1,value)};var _wrapArray=function _wrapArray2(a,wrapper,value){return _conditionalReturn(value,function(index){return a[~~wrapper(index)]})};var wrap=function wrap2(min,max,value){var range=max-min;return _isArray(min)?_wrapArray(min,wrap2(0,min.length),max):_conditionalReturn(value,function(value2){return(range+(value2-min)%range)%range+min})};var wrapYoyo=function wrapYoyo2(min,max,value){var range=max-min,total=range*2;return _isArray(min)?_wrapArray(min,wrapYoyo2(0,min.length-1),max):_conditionalReturn(value,function(value2){value2=(total+(value2-min)%total)%total||0;return min+(value2>range?total-value2:value2)})};var _replaceRandom=function _replaceRandom2(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]||0.00001);prev=end+1}return s+value.substr(prev,value.length-prev)};var mapRange=function mapRange2(inMin,inMax,outMin,outMax,value){var inRange=inMax-inMin,outRange=outMa
28x-outMin;return _conditionalReturn(value,function(value2){return outMin+((value2-inMin)/inRange*outRange||0)})};var interpolate=function interpolate2(start,end,progress,mutate){var func=isNaN(start+end)?0:function(p2){return(1-p2)*start+p2*end};if(!func){var isString=_isString(start),master={},p,i,interpolators,l,il;progress===true&&(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<l;i++){interpolators.push(interpolate2(start[i-1],start[i]))}l--;func=function func2(p2){p2*=l;var i2=Math.min(il,~~p2);return interpolators[i2](p2-i2)};progress=end}else if(!mutate){start=_merge(_isArray(start)?[]:{},start)}if(!interpolators){for(p in end){_addPropTween.call(master,start,p,"get",end[p])}func=function func2(p2){return _renderPropTweens(p2,master)||(isString?start.p:start)}}}return _conditionalReturn(progress,func)};var _getLabelInDirection=function _getLabelInDirection2(timeline,fromTime,backward){var labels=timeline.labels,min=_bigNum,p,distance,label;for(p in labels){distance=labels[p]-fromTime;if(distance<0===!!backward&&distance&&min>(distance=Math.abs(distance))){label=p;min=distance}}return label};var _callback=function _callback2(animation,type,executeLazyFirst){var v=animation.vars,callback=v[type],params,scope;if(!callback){return}params=v[type+"Params"];scope=v.callbackScope||animation;executeLazyFirst&&_lazyTweens.length&&_lazyRender();return params?callback.apply(scope,params):callback.call(scope)};var _interrupt=function _interrupt2(animation){_removeFromParent(animation);animation.progress()<1&&_callback(animation,"onInterrupt");return animation};var _quickTween;var _createPlugin=function _createPlugin2(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)};var _255=255;var _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]};var _hue=function _hue2(h,m1,m2){h=h<0?h+1:h>1?h-1:h;
28return(h*6<1?m1+(m2-m1)*h*6:h<0.5?m2:h*3<2?m1+(m2-m1)*(2/3-h)*6:m1)*_255+0.5|0};var splitColor=function splitColor2(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<=0.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<b?6:0):max===g?(b-r)/d+2:(r-g)/d+4;h*=60}a[0]=~~(h+0.5);a[1]=~~(s*100+0.5);a[2]=~~(l*100+0.5)}forceAlpha&&a.length<4&&(a[3]=1);return a};var _colorOrderData=function _colorOrderData2(v){var values=[],c=[],i=-1;v.split(_colorExp).forEach(function(v2){var a=v2.match(_numWithUnitExp)||[];values.push.apply(values,a);c.push(i+=a.length+1)});values.c=c;return values};var _formatColors=function _formatColors2(s,toHSL,orderMatchData){var result="",colors=(s+result).match(_colorExp),type=toHSL?"hsla(":"rgba(",i=0,c,shell,d,l;if(!colors){return s}colors=colors.map(function(color){return(color=splitColor(color,toHSL,1))&&type+(toHSL?color[0]+","+color[1]+"%,"+color[2]+"%,"+color[3]:color.join(","))+")"});if(orderMatchData){d=_colorOrderData(s);c=orderMatchData.c;if(c.join(result)!==d.c.join(result)){shell=s.replace(_colorExp,"1").split(_numWithUnitExp);l=shell.length-1;for(;i<l;i++){result+=shell[i]+(~c.indexOf(i)?colors.shift()||type+"0,0,0,0)":(d.length?d:colors.length?colors:orderMatchData).shift())}}}if(!shell){shell=s.split(_colorExp);l=shell.length-1;for(;i<l;i++){result+=shell[i]+colors[i]}}return result+shell[l]};var _colorExp=function(){var s="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3,4}){1,2}\\b",p;for(p in _colorLookup){s+="|"+p+"\\b"}return new RegExp(s+")","gi")}();var _hslExp=/hsl[a]?\(/;var _colorStringFilter=function _colorStringFilter2(a){var combined=a.join(" "),toHSL;_colorExp.lastIndex=0;if(_colorExp.test(combined)){toHSL=_hslExp.test(combined);a[1]=_formatColors(a[1],toHSL);a[0]=_formatColors(a[0],toHSL,_colorOrderData(a[1]));return true}};var _tickerActive;var _ticker=function(){var _getTime=Date.now,_lagThreshold=500,_adjustedLag=33,_startTime=_getTime(),_lastUpdate=_startTime,_gap=1000/240,_nextTime=_gap,_listeners=[],_id,_req,_raf,_self,_delta,_i,_tick=function _tick2(v){var elapsed=_getTime()-_lastUpdate,manual=v===true,overlap,dispatch,time,frame;elapsed>_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(_tick2));if(dispatch){for(_i=0;_i<_listeners.length;_i++){_listeners[_i](time,_delta,frame,v)}}};_self={time:0,frame:0,tick:function tick(){_tick(true)},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;
28(_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){_listeners.indexOf(callback)<0&&_listeners.push(callback);_wake()},remove:function remove(callback){var i;~(i=_listeners.indexOf(callback))&&_listeners.splice(i,1)&&_i>=i&&_i--},_listeners};return _self}();var _wake=function _wake2(){return!_tickerActive&&_ticker.wake()};var _easeMap={};var _customEaseExp=/^[\d.\-M][\d.\-,\s]/;var _quotesExp=/["']/g;var _parseObjectInString=function _parseObjectInString2(value){var obj={},split=value.substr(1,value.length-3).split(":"),key=split[0],i=1,l=split.length,index,val,parsedVal;for(;i<l;i++){val=split[i];index=i!==l-1?val.lastIndexOf(","):val.length;parsedVal=val.substr(0,index);obj[key]=isNaN(parsedVal)?parsedVal.replace(_quotesExp,"").trim():+parsedVal;key=val.substr(index+1).trim()}return obj};var _valueInParentheses=function _valueInParentheses2(value){var open=value.indexOf("(")+1,close=value.indexOf(")"),nested=value.indexOf("(",open);return value.substring(open,~nested&&nested<close?value.indexOf(")",close+1):close)};var _configEaseFromString=function _configEaseFromString2(name){var split=(name+"").split("("),ease=_easeMap[split[0]];return ease&&split.length>1&&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};var _invertEase=function _invertEase2(ease){return function(p){return 1-ease(1-p)}};var _propagateYoyoEase=function _propagateYoyoEase2(timeline,isYoyo){var child=timeline._first,ease;while(child){if(child instanceof Timeline){_propagateYoyoEase2(child,isYoyo)}else if(child.vars.yoyoEase&&(!child._yoyo||!child._repeat)&&child._yoyo!==isYoyo){if(child.timeline){_propagateYoyoEase2(child.timeline,isYoyo)}else{ease=child._ease;child._ease=child._yEase;child._yEase=ease;child._yoyo=isYoyo}}child=child._next}};var _parseEase=function _parseEase2(ease,defaultEase){return!ease?defaultEase:(_isFunction(ease)?ease:_easeMap[ease]||_configEaseFromString(ease))||defaultEase};var _insertEase=function _insertEase2(names,easeIn,easeOut,easeInOut){if(easeOut===undefined){easeOut=function easeOut2(p){return 1-easeIn(1-p)}}if(easeInOut===undefined){easeInOut=function easeInOut2(p){return p<0.5?easeIn(p*2)/2:1-easeIn((1-p)*2)/2}}var ease={easeIn,easeOut,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};var _easeInOutFromOut=function _easeInOutFromOut2(easeOut){return function(p){return p<0.5?(1-easeOut(1-p*2))/2:0.5+easeOut((p-0.5)*2)/2}};var _configElastic=function _configElastic2(type,amplitude,period){var p1=amplitude>=1?amplitude:1,p2=(period||(type?0.3:0.45))/(amplitude<1?amplitude:1),p3=p2/_2PI*(Math.asin(1/p1)||0),easeOut=function easeOut2(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(amplitude2,period2){return _configElastic2(type,amplitude2,period2)};return ease};var _configBack=function _configBack2(type,overshoot){if(overshoot===undefined){overshoot=1.70158}var easeOut=function easeOut2(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(overshoot2){return _configBack2(type,overshoot2)};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<0.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 easeOut2(p){return p<n1?n*p*p:p<n2?n*Math.pow(p-1.5/c,2)+0.75:p<n3?n*(
28p-=2.25/c)*p+0.9375:n*Math.pow(p-2.625/c,2)+0.984375};_insertEase("Bounce",function(p){return 1-easeOut(1-p)},easeOut)})(7.5625,2.75);_insertEase("Expo",function(p){return p?Math.pow(2,10*(p-1)):0});_insertEase("Circ",function(p){return-(_sqrt(1-p*p)-1)});_insertEase("Sine",function(p){return p===1?1:-_cos(p*_HALF_PI)+1});_insertEase("Back",_configBack("in"),_configBack("out"),_configBack());_easeMap.SteppedEase=_easeMap.steps=_globals.SteppedEase={config:function config(steps,immediateStart){if(steps===undefined){steps=1}var p1=1/steps,p2=steps+(immediateStart?0:1),p3=immediateStart?1:0,max=1-_tinyNum;return function(p){return((p2*_clamp(0,max,p)|0)+p3)*p1}}};_defaults.ease=_easeMap["quad.out"];_forEachName("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",function(name){return _callbackNames+=name+","+name+"Params,"});var GSCache=function GSCache2(target,harness){this.id=_gsID++;target._gsap=this;this.target=target;this.harness=harness;this.get=harness?harness.get:_getProperty;this.set=harness?harness.getSetter:_getSetter};var Animation=function(){function Animation2(vars,time){var parent=vars.parent||_globalTimeline;this.vars=vars;this._delay=+vars.delay||0;if(this._repeat=vars.repeat===Infinity?-2:vars.repeat||0){this._rDelay=vars.repeatDelay||0;this._yoyo=!!vars.yoyo||!!vars.yoyoEase}this._ts=1;_setDuration(this,+vars.duration,1,1);this.data=vars.data;_tickerActive||_ticker.wake();parent&&_addToTimeline(parent,this,time||time===0?time:parent._time,1);vars.reversed&&this.reverse();vars.paused&&this.paused(true)}var _proto=Animation2.prototype;_proto.delay=function delay(value){if(value||value===0){this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+value-this._delay);this._delay=value;return this}return this._delay};_proto.duration=function duration(value){return arguments.length?this.totalDuration(this._repeat>0?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){if(parent.parent._time!==parent._start+(parent._ts>=0?parent._tTime/parent._ts:(parent.totalDuration()-parent._tTime)/-parent._ts)){parent.totalTime(parent._tTime,true)}parent=parent.parent}if(!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&_totalTime<this._tDur||this._ts<0&&_totalTime>0||!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||(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;return _recacheAncestors(this.totalTime(_clamp(-this._delay,this._tDur,tTime),true))};_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&&(this._tTime-=_tinyNum)&&Math.abs(this._zTime)!==_tinyNum)}}return this};_proto.startTime=function startTime(value){if(arguments.length){this._start=value;var parent=this.parent||this._dp;
28parent&&(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)};_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.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 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){this._rDelay=value;return _onUpdateTotalDuration(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(false).paused(false)};_proto.reverse=function reverse(from,suppressEvents){from!=null&&this.seek(from||this.totalDuration(),suppressEvents);return this.reversed(true).paused(false)};_proto.pause=function pause(atTime,suppressEvents){atTime!=null&&this.seek(atTime,suppressEvents);return this.paused(true)};_proto.resume=function resume(){return this.paused(false)};_proto.reversed=function reversed(value){if(arguments.length){!!value!==this.reversed()&&this.timeScale(-this._rts||(value?-_tinyNum:0));return this}return this._rts<0};
28_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(true))>=start&&rawTime<this.endTime(true)-_tinyNum)};_proto.eventCallback=function eventCallback(type,callback,params){var vars=this.vars;if(arguments.length>1){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 _resolve2(){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 Animation2}();_setDefaults(Animation.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:false,parent:null,_initted:false,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-_tinyNum,_prom:0,_ps:false,_rts:1});var Timeline=function(_Animation){_inheritsLoose(Timeline2,_Animation);function Timeline2(vars,time){var _this;if(vars===undefined){vars={}}_this=_Animation.call(this,vars,time)||this;_this.labels={};_this.smoothChildTiming=!!vars.smoothChildTiming;_this.autoRemoveChildren=!!vars.autoRemoveChildren;_this._sort=_isNotFalse(vars.sortChildren);_this.parent&&_postAddChecks(_this.parent,_assertThisInitialized(_this));vars.scrollTrigger&&_scrollTrigger(_assertThisInitialized(_this),vars.scrollTrigger);return _this}var _proto2=Timeline2.prototype;_proto2.to=function to(targets,vars,position){new Tween(targets,_parseVars(arguments,0,this),_parsePosition(this,_isNumber(vars)?arguments[3]:position));return this};_proto2.from=function from(targets,vars,position){new Tween(targets,_parseVars(arguments,1,this),_parsePosition(this,_isNumber(vars)?arguments[3]:position));return this};_proto2.fromTo=function fromTo(targets,fromVars,toVars,position){new Tween(targets,_parseVars(arguments,2,this),_parsePosition(this,_isNumber(fromVars)?arguments[4]:position));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),_parsePosition(this,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=this!==_globalTimeline&&totalTime>tDur-_tinyNum&&totalTime>=0?tDur:totalTime<_tinyNum?0:totalTime,crossingStart=this._zTime<0!==totalTime<0&&(this._initted||!dur),time,child,next,iteration,cycleDuration,prevPaused,pauseTween,timeScale,prevStart,prevIteration,yoyo,isYoyo;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=_round(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<prevIteration&&(rewinding=!rewinding);prevTime=rewinding?0:dur;this._lock=1;this.render(prevTime||(isYoyo?0:_round(iteration*cycleDuration)),suppressEvents,!dur)._lock=0;!suppressEvents&&this.parent&&_callback(this,"onRepeat");this.vars.repeatRefresh&&!isYoyo&&(this.invalidate()._lock=1);
28if(prevTime!==this._time||prevPaused!==!this._ts){return this}dur=this._dur;tDur=this._tDur;if(doesWrap){this._lock=2;prevTime=rewinding?dur:-0.0001;this.render(prevTime,true);this.vars.repeatRefresh&&!isYoyo&&this.invalidate()}this._lock=0;if(!this._ts&&!prevPaused){return this}_propagateYoyoEase(this,isYoyo)}}if(this._hasPause&&!this._forcing&&this._lock<2){pauseTween=_findNextPauseTween(this,_round(prevTime),_round(time));if(pauseTween){tTime-=time-(time=pauseTween._start)}}this._tTime=tTime;this._time=time;this._act=!timeScale;if(!this._initted){this._onUpdate=this.vars.onUpdate;this._initted=1;this._zTime=totalTime;prevTime=0}!prevTime&&(time||!dur&&totalTime>=0)&&!suppressEvents&&_callback(this,"onStart");if(time>=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);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",true);if(tTime===tDur&&tDur>=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)){_callback(this,tTime===tDur?"onComplete":"onReverseComplete",true);this._prom&&!(tTime<tDur&&this.timeScale()>0)&&this._prom()}}}}}return this};_proto2.add=function add(child,position){var _this2=this;_isNumber(position)||(position=_parsePosition(this,position));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===undefined){nested=true}if(tweens===undefined){tweens=true}if(timelines===undefined){timelines=true}if(ignoreBeforeTime===undefined){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(true,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=_round(_ticker.time-(this._ts>0?_totalTime2/this._ts:(this.totalDuration()-_totalTime2)/-this._ts
28))}_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,tween=Tween.to(tl,_setDefaults({ease:"none",lazy:false,immediateRender:false,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();var duration=vars.duration||Math.abs((endTime-tl._time)/tl.timeScale());tween._dur!==duration&&_setDuration(tween,duration,0,1).render(tween._time,true,true);_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===undefined){afterTime=this._time}return _getLabelInDirection(this,_parsePosition(this,afterTime))};_proto2.previousLabel=function previousLabel(beforeTime){if(beforeTime===undefined){beforeTime=this._time}return _getLabelInDirection(this,_parsePosition(this,beforeTime),1)};_proto2.currentLabel=function currentLabel(value){return arguments.length?this.seek(value,true):this.previousLabel(this._time+_tinyNum)};_proto2.shiftChildren=function shiftChildren(amount,adjustLabels,ignoreBeforeTime){if(ignoreBeforeTime===undefined){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)};
28_proto2.invalidate=function invalidate(){var child=this._first;this._lock=0;while(child){child.invalidate();child=child._next}return _Animation.prototype.invalidate.call(this)};_proto2.clear=function clear(includeLabels){if(includeLabels===undefined){includeLabels=true}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,false,-Infinity);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};Timeline2.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 Timeline2}(Animation);_setDefaults(Timeline.prototype,{_lock:0,_hasPause:0,_forcing:0});var _addComplexStringPropTween=function _addComplexStringPropTween2(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)==="="?parseFloat(endNum.substr(2))*(endNum.charAt(0)==="-"?-1:1):parseFloat(endNum)-startNum,m:color&&color<4?Math.round:0};index=_complexStringNumExp.lastIndex}}pt.c=index<end.length?end.substring(index,end.length):"";pt.fp=funcParam;if(_relExp.test(end)||hasRandom){pt.e=0}this._pt=pt;return pt};var _addPropTween=function _addPropTween2(target,prop,start,end,index,targets,modifier,stringFilter,funcParam){_isFunction(end)&&(end=end(index||0,target,targets));var currentValue=target[prop],parsedStart=start!=="get"?start:!_isFunction(currentValue)?currentValue:funcParam?target[prop.indexOf("set")||!_isFunction(target["get"+prop.substr(3)])?prop:"get"+prop.substr(3)](funcParam):target[prop](),setter=!_isFunction(currentValue)?_setterPlain:funcParam?_setterFuncWithParam:_setterFunc,pt;if(_isString(end)){if(~end.indexOf("random(")){end=_replaceRandom(end)}if(end.charAt(1)==="="){end=parseFloat(parsedStart)+parseFloat(end.substr(2))*(end.charAt(0)==="-"?-1:1)+(getUnit(parsedStart)||0)}}if(parsedStart!==end){if(!isNaN(parsedStart*end)){pt=new PropTween(this._pt,target,prop,+parsedStart||0,end-(parsedStart||0),typeof currentValue==="boolean"?_renderBoolean:_renderPlain,0,setter);funcParam&&(pt.fp=funcParam);modifier&&pt.modifier(modifier,this,target);return this._pt=pt}!currentValue&&!(prop in target)&&_missingPlugin(prop,end);return _addComplexStringPropTween.call(this,target,prop,parsedStart,end,setter,stringFilter||_config.stringFilter,funcParam)}};var _processVars=function _processVars2(vars,index,target,targets,tween){_isFunction(vars)&&(vars=_parseFuncOrString(vars,tween,index,target,targets));if(!_isObject(vars)||vars.style&&vars.nodeType||_isArray(vars)||_isTypedArray(vars)){return _isString(vars)?_parseFuncOrString(vars,tween,index,target,targets):vars}var copy={},p;for(p in vars){copy[p]=_parseFuncOrString(vars[p],tween,index,target,targets)}return copy};var _checkPlugin=function _checkPlugin2(property,vars,tween,index,target,targets){var plugin,pt,ptLookup,i;if(_plugins[property]&&(plugin=new _plugins[property]).init(target,plugin.rawVars?vars[property]:_processVars(vars[property],index,target,targets,tween),tween,index,targets)!==false){tween._pt=pt=new PropTween(tween._pt,target,property,0,1,plugin.render,plugin,0,plugin.priority);if(tween!==_quickTween){ptLookup=tween._ptLookup[tween._targets.indexOf(target)];i=plugin._props.length;while(i--){ptLookup[plugin._props[i]]=pt}}}return plugin};var _overwritingTween;
28var _initTween=function _initTween2(tween,time){var vars=tween.vars,ease=vars.ease,startAt=vars.startAt,immediateRender=vars.immediateRender,lazy=vars.lazy,onUpdate=vars.onUpdate,onUpdateParams=vars.onUpdateParams,callbackScope=vars.callbackScope,runBackwards=vars.runBackwards,yoyoEase=vars.yoyoEase,keyframes=vars.keyframes,autoRevert=vars.autoRevert,dur=tween._dur,prevStartAt=tween._startAt,targets=tween._targets,parent=tween.parent,fullTargets=parent&&parent.data==="nested"?parent.parent._targets:targets,autoOverwrite=tween._overwrite==="auto"&&!_suppressOverwrites,tl=tween.timeline,cleanVars,i,p,pt,target,hasPriority,gsData,harness,plugin,ptLookup,index,harnessVars,overwritten;tl&&(!keyframes||!ease)&&(ease="none");tween._ease=_parseEase(ease,_defaults.ease);tween._yEase=yoyoEase?_invertEase(_parseEase(yoyoEase===true?ease:yoyoEase,_defaults.ease)):0;if(yoyoEase&&tween._yoyo&&!tween._repeat){yoyoEase=tween._yEase;tween._yEase=tween._ease;tween._ease=yoyoEase}if(!tl){harness=targets[0]?_getCache(targets[0]).harness:0;harnessVars=harness&&vars[harness.prop];cleanVars=_copyExcluding(vars,_reservedProps);prevStartAt&&prevStartAt.render(-1,true).kill();if(startAt){_removeFromParent(tween._startAt=Tween.set(targets,_setDefaults({data:"isStart",overwrite:false,parent,immediateRender:true,lazy:_isNotFalse(lazy),startAt:null,delay:0,onUpdate,onUpdateParams,callbackScope,stagger:0},startAt)));if(immediateRender){if(time>0){autoRevert||(tween._startAt=0)}else if(dur&&!(time<0&&prevStartAt)){time&&(tween._zTime=time);return}}}else if(runBackwards&&dur){if(prevStartAt){!autoRevert&&(tween._startAt=0)}else{time&&(immediateRender=false);p=_setDefaults({overwrite:false,data:"isFromStart",lazy:immediateRender&&_isNotFalse(lazy),immediateRender,stagger:0,parent},cleanVars);harnessVars&&(p[harness.prop]=harnessVars);_removeFromParent(tween._startAt=Tween.set(targets,p));if(!immediateRender){_initTween2(tween._startAt,_tinyNum)}else if(!time){return}}}tween._pt=0;lazy=dur&&_isNotFalse(lazy)||lazy&&!dur;for(i=0;i<targets.length;i++){target=targets[i];gsData=target._gsap||_harness(targets)[i]._gsap;tween._ptLookup[i]=ptLookup={};_lazyLookup[gsData.id]&&_lazyTweens.length&&_lazyRender();index=fullTargets===targets?i:fullTargets.indexOf(target);if(harness&&(plugin=new harness).init(target,harnessVars||cleanVars,tween,index,fullTargets)!==false){tween._pt=pt=new PropTween(tween._pt,target,plugin.name,0,1,plugin.render,plugin,0,plugin.priority);plugin._props.forEach(function(name){ptLookup[name]=pt});plugin.priority&&(hasPriority=1)}if(!harness||harnessVars){for(p in cleanVars){if(_plugins[p]&&(plugin=_checkPlugin(p,cleanVars,tween,index,target,fullTargets))){plugin.priority&&(hasPriority=1)}else{ptLookup[p]=pt=_addPropTween.call(tween,target,p,"get",cleanVars[p],index,fullTargets,0,vars.stringFilter)}}}tween._op&&tween._op[i]&&tween.kill(target,tween._op[i]);if(autoOverwrite&&tween._pt){_overwritingTween=tween;_globalTimeline.killTweensOf(target,ptLookup,tween.globalTime(0));overwritten=!tween.parent;_overwritingTween=0}tween._pt&&lazy&&(_lazyLookup[gsData.id]=1)}hasPriority&&_sortPropTweensByPriority(tween);tween._onInit&&tween._onInit(tween)}tween._from=!tl&&!!vars.runBackwards;tween._onUpdate=onUpdate;tween._initted=(!tween._op||tween._pt)&&!overwritten};var _addAliasesToVars=function _addAliasesToVars2(targets,vars){var harness=targets[0]?_getCache(targets[0]).harness:0,propertyAliases=harness&&harness.aliases,copy,p,i,aliases;if(!propertyAliases){return vars}copy=_merge({},vars);for(p in propertyAliases){if(p in copy){aliases=propertyAliases[p].split(",");i=aliases.length;while(i--){copy[aliases[i]]=copy[p]}}}return copy};var _parseFuncOrString=function _parseFuncOrString2(value,tween,i,target,targets){return _isFunction(value)?value.call(tween,i,target,targets):_isString(value)&&~value.indexOf("random(")?_replaceRandom(value):value};var _staggerTweenProps=_callbackNames+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase";var _staggerPropsToSkip=(_staggerTweenProps+",id,stagger,delay,duration,paused,scrollTrigger").split(",");var Tween=function(_Animation2){_inheritsLoose(Tween2,_Animation2);function Tween2(targets,vars,time,skipInherit){var _this3;if(typeof vars==="number"){time.duration=vars;vars=time;time=null}_this3=_Animation2.call(this,skipInherit?vars:_inheritDefaults(vars),time)||this;var _this3$vars=_this3.vars,duration=_this3$vars.duration,delay=_this3$vars.delay,immediateRender=_this3$vars.immediateRender,stagger=_this3$vars.stagger,overwrite=_this3$vars.over
28write,keyframes=_this3$vars.keyframes,defaults=_this3$vars.defaults,scrollTrigger=_this3$vars.scrollTrigger,yoyoEase=_this3$vars.yoyoEase,parent=_this3.parent,parsedTargets=(_isArray(targets)||_isTypedArray(targets)?_isNumber(targets[0]):("length"in vars))?[targets]:toArray(targets),tl,i,copy,l,p,curTarget,staggerFunc,staggerVarsToMerge;_this3._targets=parsedTargets.length?_harness(parsedTargets):_warn("GSAP target "+targets+" not found. https://greensock.com",!_config.nullTargetWarn)||[];_this3._ptLookup=[];_this3._overwrite=overwrite;if(keyframes||stagger||_isFuncOrString(duration)||_isFuncOrString(delay)){vars=_this3.vars;tl=_this3.timeline=new Timeline({data:"nested",defaults:defaults||{}});tl.kill();tl.parent=tl._dp=_assertThisInitialized(_this3);tl._start=0;if(keyframes){_setDefaults(tl.vars.defaults,{ease:"none"});keyframes.forEach(function(frame){return tl.to(parsedTargets,frame,">")})}else{l=parsedTargets.length;staggerFunc=stagger?distribute(stagger):_emptyFunc;if(_isObject(stagger)){for(p in stagger){if(~_staggerTweenProps.indexOf(p)){staggerVarsToMerge||(staggerVarsToMerge={});staggerVarsToMerge[p]=stagger[p]}}}for(i=0;i<l;i++){copy={};for(p in vars){if(_staggerPropsToSkip.indexOf(p)<0){copy[p]=vars[p]}}copy.stagger=0;yoyoEase&&(copy.yoyoEase=yoyoEase);staggerVarsToMerge&&_merge(copy,staggerVarsToMerge);curTarget=parsedTargets[i];copy.duration=+_parseFuncOrString(duration,_assertThisInitialized(_this3),i,curTarget,parsedTargets);copy.delay=(+_parseFuncOrString(delay,_assertThisInitialized(_this3),i,curTarget,parsedTargets)||0)-_this3._delay;if(!stagger&&l===1&&copy.delay){_this3._delay=delay=copy.delay;_this3._start+=delay;copy.delay=0}tl.to(curTarget,copy,staggerFunc(i,curTarget,parsedTargets))}tl.duration()?duration=delay=0:_this3.timeline=0}duration||_this3.duration(duration=tl.duration())}else{_this3.timeline=0}if(overwrite===true&&!_suppressOverwrites){_overwritingTween=_assertThisInitialized(_this3);_globalTimeline.killTweensOf(parsedTargets);_overwritingTween=0}parent&&_postAddChecks(parent,_assertThisInitialized(_this3));if(immediateRender||!duration&&!keyframes&&_this3._start===_round(parent._time)&&_isNotFalse(immediateRender)&&_hasNoPausedAncestors(_assertThisInitialized(_this3))&&parent.data!=="nested"){_this3._tTime=-_tinyNum;_this3.render(Math.max(0,-delay))}scrollTrigger&&_scrollTrigger(_assertThisInitialized(_this3),scrollTrigger);return _this3}var _proto3=Tween2.prototype;_proto3.render=function render(totalTime,suppressEvents,force){var prevTime=this._time,tDur=this._tDur,dur=this._dur,tTime=totalTime>tDur-_tinyNum&&totalTime>=0?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!==totalTime<0){time=tTime;timeline=this.timeline;if(this._repeat){cycleDuration=dur+this._rDelay;if(this._repeat<-1&&totalTime<0){return this.totalTime(cycleDuration*100+totalTime,suppressEvents,force)}time=_round(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){return this}if(iteration!==prevIteration){timeline&&this._yEase&&_propagateYoyoEase(timeline,isYoyo);if(this.vars.repeatRefresh&&!isYoyo&&!this._lock){this._lock=force=1;this.render(_round(cycleDuration*iteration),true).invalidate()._lock=0}}}if(!this._initted){if(_attemptInitTween(this,totalTime<0?totalTime:time,force,suppressEvents)){this._tTime=0;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}time&&!prevTime&&!suppressEvents&&_callback(this,"onStart");pt=this._pt;while(pt){pt.r(ratio,pt.d);pt=pt._next}timeline&&timeline.render(totalTime<0?totalTime:!time&&isYoyo?-_tinyNum:timeline._dur*ratio,suppressEvents,force)||this._startAt&&(this._zTime=totalTime);if(this._onUpdate&&!suppressEvents){totalTime<0&&this._startAt&&this._startAt.render(totalTime,true,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){totalTime<0&&this._startAt&&!this._onUpdate&&this._startAt.render(totalTime,true,true);(totalTime||!dur)&&(tTime===this._tDur&&this._ts>0||!tTime&&this._ts<0)&&_removeFromParent(this,1);if(!suppressEvents&&!(totalTime<0&&!prevTime)&&(tTime||prevTime)){_callback(this,tTime===tDur?"onComplete":"onReverseComplete",true);this._prom&&!(tTime<tDur&&this.timeScale()>0)&&this._prom()}}}return this};_proto3.targets=function targets(){return this._targets};
28_proto3.invalidate=function invalidate(){this._pt=this._op=this._startAt=this._onUpdate=this._lazy=this.ratio=0;this._ptLookup=[];this.timeline&&this.timeline.invalidate();return _Animation2.prototype.invalidate.call(this)};_proto3.kill=function kill(targets,vars){if(vars===undefined){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!==true)._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)===true){_removeLinkedListItem(this,pt,"_pt")}delete curLookup[p]}if(curOverwriteProps!=="all"){curOverwriteProps[p]=1}}}}this._initted&&!this._pt&&firstPT&&_interrupt(this);return this};Tween2.to=function to(targets,vars){return new Tween2(targets,vars,arguments[2])};Tween2.from=function from(targets,vars){return new Tween2(targets,_parseVars(arguments,1))};Tween2.delayedCall=function delayedCall(delay,callback,params,scope){return new Tween2(callback,0,{immediateRender:false,lazy:false,overwrite:false,delay,onComplete:callback,onReverseComplete:callback,onCompleteParams:params,onReverseCompleteParams:params,callbackScope:scope})};Tween2.fromTo=function fromTo(targets,fromVars,toVars){return new Tween2(targets,_parseVars(arguments,2))};Tween2.set=function set(targets,vars){vars.duration=0;vars.repeatDelay||(vars.repeat=0);return new Tween2(targets,vars)};Tween2.killTweensOf=function killTweensOf(targets,props,onlyActive){return _globalTimeline.killTweensOf(targets,props,onlyActive)};return Tween2}(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 _setterPlain2(target,property,value){return target[property]=value};var _setterFunc=function _setterFunc2(target,property,value){return target[property](value)};var _setterFuncWithParam=function _setterFuncWithParam2(target,property,value,data){return target[property](data.fp,value)};var _setterAttribute=function _setterAttribute2(target,property,value){return target.setAttribute(property,value)};var _getSetter=function _getSetter2(target,property){return _isFunction(target[property])?_setterFunc:_isUndefined(target[property])&&target.setAttribute?_setterAttribute:_setterPlain};var _renderPlain=function _renderPlain2(ratio,data){return data.set(data.t,data.p,Math.round((data.s+data.c*ratio)*1e4)/1e4,data)};var _renderBoolean=function _renderBoolean2(ratio,data){return data.set(data.t,data.p,!!(data.s+data.c*ratio),data)};var _renderComplexString=function _renderComplexString2(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)*1e4)/1e4)+s;pt=pt._next}s+=data.c}data.set(data.t,data.p,s,data)};var _renderPropTweens=function _renderPropTweens2(ratio,data){var pt=data._pt;while(pt){pt.r(ratio,pt.d);pt=pt._next}};var _addPluginModifier=function _addPluginModifier2(modifier,tween,target,property){var pt=this._pt,next;while(pt){next=pt._next;pt.p===property&&pt.modifier(modifier,tween,target);pt=next}};var _killPropTweensOf=function _killPropTweensOf2(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};var _setterWithModifier=function _setterWithModifier2(target,property,value,data){data.mSet(target,property,data.m.call(data.tween,value,data.mt),data)};var _sortPropTweensByPriority=function _sortPropTweensByPriority2(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 PropTween2(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=PropTween2.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 PropTween2}();_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:false,defaults:_defaults,autoRemoveChildren:true,id:"root",smoothChildTiming:true});_config.stringFilter=_colorStringFilter;var _gsap={registerPlugin:function registerPlugin(){for(var _len2=arguments.length,args=new Array(_len2),_key2=0;_key2<_len2;_key2++){args[_key2]=arguments[_key2]}
28args.forEach(function(config3){return _createPlugin(config3)})},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(property2,unit2,uncache2){return format((_plugins[property2]&&_plugins[property2].get||getter)(target,property2,unit2,uncache2))}: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 p2=new Plugin;_quickTween._pt=0;p2.init(target,unit?value+unit:value,_quickTween,0,[target]);p2.render(1,p2);_quickTween._pt&&_renderPropTweens(1,_quickTween)}:cache.set(target,p);return Plugin?setter:function(value){return setter(target,p,unit?value+unit:value,cache,1)}},isTweening:function isTweening(targets){return _globalTimeline.getTweensOf(targets,true).length>0},defaults:function defaults(value){value&&value.ease&&(value.ease=_parseEase(value.ease,_defaults.ease));return _mergeDeep(_defaults,value||{})},config:function config2(value){return _mergeDeep(_config,value||{})},registerEffect:function registerEffect(_ref2){var{name,effect,plugins,defaults:defaults2,extendTimeline}=_ref2;(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||{},defaults2),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===undefined){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},utils:{wrap,wrapYoyo,distribute,random,snap,normalize,getUnit,clamp,splitColor,toArray,mapRange,pipe,unitize,interpolate,shuffle},install:_install,effects:_effects,ticker:_ticker,updateRoot:Timeline.updateRoot,plugins:_plugins,globalTimeline:_globalTimeline,core:{PropTween,globals:_addGlobal,Tween,Timeline,Animation,getCache:_getCache,_removeLinkedListItem,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 _getPluginPropTween2(plugin,prop){var pt=plugin._pt;while(pt&&pt.p!==prop&&pt.op!==prop&&pt.fp!==prop){pt=pt._next}return pt};var _addModifiers=function _addModifiers2(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)}}}};var _buildModifierPlugin=function _buildModifierPlugin2(name,modifier){return{name,rawVars:1,init:function init(target,vars,tween){tween._onInit=function(tween2){var temp,p;if(_isString(vars)){temp={};_forEachName(vars,function(name2){return temp[name2]=1});vars=temp}if(modifier){temp={};for(p in vars){temp[p]=modifier(vars[p])}vars=temp}_addModifiers(tween2,vars)}}}};var gsap=_gsap.registerPlugin({name:"attr",init:function init(target,vars,tween,index,targets){var p,pt;for(p in vars){pt=this.add(target,"setAttribute",(target.getAttribute(p)||0)+"",vars[p],index,targets,0,0,p);pt&&(pt.op=p);this._props.push(p)}}},{name:"endArray",init:function init2(target,value){var i=value.length;while(i--){this.add(target,i,target[i]||0,value[i])}}}
28,_buildModifierPlugin("roundProps",_roundModifier),_buildModifierPlugin("modifiers"),_buildModifierPlugin("snap",snap))||_gsap;Tween.version=Timeline.version=gsap.version="3.6.0";_coreReady=1;if(_windowExists()){_wake()}var Power0=_easeMap.Power0;var Power1=_easeMap.Power1;var Power2=_easeMap.Power2;var Power3=_easeMap.Power3;var Power4=_easeMap.Power4;var Linear=_easeMap.Linear;var Quad=_easeMap.Quad;var Cubic=_easeMap.Cubic;var Quart=_easeMap.Quart;var Quint=_easeMap.Quint;var Strong=_easeMap.Strong;var Elastic=_easeMap.Elastic;var Back=_easeMap.Back;var SteppedEase=_easeMap.SteppedEase;var Bounce=_easeMap.Bounce;var Sine=_easeMap.Sine;var Expo=_easeMap.Expo;var Circ=_easeMap.Circ;/*!
29 * CSSPlugin 3.6.0
30 * https://greensock.com
31 *
32 * Copyright 2008-2021, GreenSock. All rights reserved.
33 * Subject to the terms at https://greensock.com/standard-license or for
34 * Club GreenSock members, the agreement issued with that membership.
35 * @author: Jack Doyle, [email protected]
36*/var _win2;var _doc2;var _docElement;var _pluginInitted;var _tempDiv;var _tempDivStyler;var _recentSetterPlugin;var _windowExists3=function _windowExists4(){return typeof window!=="undefined"};var _transformProps={};var _RAD2DEG=180/Math.PI;var _DEG2RAD=Math.PI/180;var _atan2=Math.atan2;var _bigNum2=1e8;var _capsExp=/([A-Z])/g;var _horizontalExp=/(?:left|right|width|margin|padding|x)/i;var _complexExp=/[\s,\(]\S/;var _propertyAliases={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"};var _renderCSSProp=function _renderCSSProp2(ratio,data){return data.set(data.t,data.p,Math.round((data.s+data.c*ratio)*1e4)/1e4+data.u,data)};var _renderPropWithEnd=function _renderPropWithEnd2(ratio,data){return data.set(data.t,data.p,ratio===1?data.e:Math.round((data.s+data.c*ratio)*1e4)/1e4+data.u,data)};var _renderCSSPropWithBeginning=function _renderCSSPropWithBeginning2(ratio,data){return data.set(data.t,data.p,ratio?Math.round((data.s+data.c*ratio)*1e4)/1e4+data.u:data.b,data)};var _renderRoundedCSSProp=function _renderRoundedCSSProp2(ratio,data){var value=data.s+data.c*ratio;data.set(data.t,data.p,~~(value+(value<0?-0.5:0.5))+data.u,data)};var _renderNonTweeningValue=function _renderNonTweeningValue2(ratio,data){return data.set(data.t,data.p,ratio?data.e:data.b,data)};var _renderNonTweeningValueOnlyAtEnd=function _renderNonTweeningValueOnlyAtEnd2(ratio,data){return data.set(data.t,data.p,ratio!==1?data.b:data.e,data)};var _setterCSSStyle=function _setterCSSStyle2(target,property,value){return target.style[property]=value};var _setterCSSProp=function _setterCSSProp2(target,property,value){return target.style.setProperty(property,value)};var _setterTransform=function _setterTransform2(target,property,value){return target._gsap[property]=value};var _setterScale=function _setterScale2(target,property,value){return target._gsap.scaleX=target._gsap.scaleY=value};var _setterScaleWithRender=function _setterScaleWithRender2(target,property,value,data,ratio){var cache=target._gsap;cache.scaleX=cache.scaleY=value;cache.renderTransform(ratio,cache)};var _setterTransformWithRender=function _setterTransformWithRender2(target,property,value,data,ratio){var cache=target._gsap;cache[property]=value;cache.renderTransform(ratio,cache)};var _transformProp="transform";var _transformOriginProp=_transformProp+"Origin";var _supports3D;var _createElement=function _createElement2(type,ns){var e=_doc2.createElementNS?_doc2.createElementNS((ns||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),type):_doc2.createElement(type);return e.style?e:_doc2.createElement(type)};var _getComputedProperty=function _getComputedProperty2(target,property,skipPrefixFallback){var cs=getComputedStyle(target);return cs[property]||cs.getPropertyValue(property.replace(_capsExp,"-$1").toLowerCase())||cs.getPropertyValue(property)||!skipPrefixFallback&&_getComputedProperty2(target,_checkPropPrefix(property)||property,1)||""};var _prefixes="O,Moz,ms,Ms,Webkit".split(",");var _checkPropPrefix=function _checkPropPrefix2(property,element,preferPrefix){var e=element||_tempDiv,s=e.style,i=5;if(property in s&&!preferPrefix){return property}property=property.charAt(0).toUpperCase()+property.substr(1);while(i--&&!(_prefixes[i]+property in s)){}return i<0?null:(i===3?"ms":i>=0?_prefixes[i]:"")+property};
36var _initCore=function _initCore2(){if(_windowExists3()&&window.document){_win2=window;_doc2=_win2.document;_docElement=_doc2.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");_pluginInitted=1}};var _getBBoxHack=function _getBBoxHack2(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=_getBBoxHack2}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};var _getAttributeFallbacks=function _getAttributeFallbacks2(target,attributesArray){var i=attributesArray.length;while(i--){if(target.hasAttribute(attributesArray[i])){return target.getAttribute(attributesArray[i])}}};var _getBBox=function _getBBox2(target){var bounds;try{bounds=target.getBBox()}catch(error){bounds=_getBBoxHack.call(target,true)}bounds&&(bounds.width||bounds.height)||target.getBBox===_getBBoxHack||(bounds=_getBBoxHack.call(target,true));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};var _isSVG=function _isSVG2(e){return!!(e.getCTM&&(!e.parentNode||e.ownerSVGElement)&&_getBBox(e))};var _removeProperty=function _removeProperty2(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)}}};var _addNonTweeningPT=function _addNonTweeningPT2(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};var _nonConvertibleUnits={deg:1,rad:1,turn:1};var _convertToUnit=function _convertToUnit2(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=_convertToUnit2(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===_doc2||!parent.appendChild){parent=_doc2.body}cache=parent._gsap;if(cache&&toPercent&&cache.width&&horizontal&&cache.time===_ticker.time){return _round(curValue/cache.width*amount)}else{(toPercent||curUnit==="%")&&(style.position=_getComputedProperty(target,"position"));parent===target&&(style.position="static");parent.appendChild(_tempDiv);px=_tempDiv[measureProperty];parent.removeChild(_tempDiv);style.position="absolute";
36if(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)};var _get=function _get2(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]:_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};var _tweenComplexCSSString=function _tweenComplexCSSString2(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,relative,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);relative=endValue.charAt(1)==="="?+(endValue.charAt(0)+"1"):0;if(relative){endValue=endValue.substr(2)}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:relative?relative*endNum:endNum-startNum,m:color&&color<4||prop==="zIndex"?Math.round:0}}}pt.c=index<end.length?end.substring(index,end.length):""}else{pt.r=prop==="display"&&end==="none"?_renderNonTweeningValueOnlyAtEnd:_renderNonTweeningValue}_relExp.test(end)&&(pt.e=0);this._pt=pt;return pt};var _keywordToPercent={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"};var _convertKeywordsToPercentages=function _convertKeywordsToPercentages2(value){var split=value.split(" "),x=split[0],y=split[1]||"50%";if(x==="top"||x==="bottom"||y==="left"||y==="right"){value=x;x=y;y=value}split[0]=_keywordToPercent[x]||x;split[1]=_keywordToPercent[y]||y;return split.join(" ")};var _renderClearProps=function _renderClearProps2(ratio,data){if(data.tween&&data.tween._time===data.tween._dur){var target=data.t,style=target.style,props=data.u,cache=target._gsap,prop,clearTransforms,i;if(props==="all"||props===true){style.cssText="";clearTransforms=1}else{props=props.split(",");i=props.length;while(--i>-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}}}};var _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}}};var _identity2DMatrix=[1,0,0,1,0,0];var _rotationalProperties={};var _isNullTransform=function _isNullTransform2(value){return value==="matrix(1, 0, 0, 1, 0, 0)"||value==="none"||!value};var _getComputedTransformMatrixAsArray=function _getComputedTransformMatrixAsArray2(target){var matrixString=_getComputedProperty(target,_transformProp);return _isNullTransform(matrixString)?_identity2DMatrix:matrixString.substr(7).match(_numExp).map(_round)};var _getMatrix=function _getMatrix2(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.nextSibling;_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>
366?[matrix[0],matrix[1],matrix[4],matrix[5],matrix[12],matrix[13]]:matrix};var _applySVGOrigin=function _applySVGOrigin2(target,origin,originIsAbsolute,smooth,matrixArray,pluginToAddPropTweensTo){var cache=target._gsap,matrix=matrixArray||_getMatrix(target,true),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!==false&&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)};var _parseTransform=function _parseTransform2(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",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));matrix=_getMatrix(target,cache.svg);if(cache.svg){t1=!cache.uncache&&target.getAttribute("data-svg-origin");_applySVGOrigin(target,t1||origin,!!t1||cache.originIsAbsolute,cache.smooth!==false,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.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}}cache.x=x-((cache.xPercent=x&&(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&&(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};var _firstTwoOnly=function _firstTwoOnly2(value){return(value=value.split(" "))[0]+" "+value[1]};var _addPxTranslate=function _addPxTranslate2(target,start,value){var unit=getUnit(start);return _round(parseFloat(start)+parseFloat(_convertToUnit(target,"x",value+"px",unit)))+unit};var _renderNon3DTransforms=function _renderNon3DTransforms2(ratio,cache){cache.z="0px";cache.rotationY=cache.rotationX="0deg";cache.force3D=0;_renderCSSTransforms(ratio,cache)};var _zeroDeg="0deg";var _zeroPx="0px";var _endParenthesis=") ";var _renderCSSTransforms=function _renderCSSTransforms2(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===true;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)"};var _renderSVGTransforms=function _renderSVGTransforms2(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,xOr
36igin=_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)};var _addRotationalPropTween=function _addRotationalPropTween2(plugin,target,property,startNum,endValue,relative){var cap=360,isString=_isString(endValue),endNum=parseFloat(endValue)*(isString&&~endValue.indexOf("rad")?_RAD2DEG:1),change=relative?endNum*relative: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*_bigNum2)%cap-~~(change/cap)*cap}else if(direction==="ccw"&&change>0){change=(change-cap*_bigNum2)%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};var _addRawTransformPTs=function _addRawTransformPTs2(plugin,transforms,target){var style=_tempDivStyler.style,startCache=target._gsap,exclude="perspective,force3D,transformOrigin,svgOrigin",endCache,p,startValue,endValue,startNum,endNum,startUnit,endUnit;style.cssText=getComputedStyle(target).cssText+";position:absolute;display:block;";style[_transformProp]=transforms;_doc2.body.appendChild(_tempDivStyler);endCache=_parseTransform(_tempDivStyler,1);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,startCache,p,startNum,endNum-startNum,_renderCSSProp);plugin._pt.u=endUnit||0;plugin._props.push(p)}}_doc2.body.removeChild(_tempDivStyler)};_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 init3(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;_pluginInitted||_initCore();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+="";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)}else if(type!=="undefined"){if(startAt&&p in startAt){startValue=typeof startAt[p]==="function"?startAt[p].call(tween,index,target,targets):startAt[p];p in _config.units&&!getUnit(startValue)&&(startValue+=_config.units[p]);(startValue+"").charAt(1)==="="&&(startValue=_get(target,p))}else{startValue=_get(target,p)}startNum=parseFloat(startValue);relative=type==="string"&&endValue.charAt(1)==="="?+(endValue.charAt(0)+"1"):0;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}_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){if(!transformPropTween){cache=target._gsap;cache.renderTransform&&!vars.parseTransform||_parseTransform(target,vars.parseTransform);smooth=vars.smoothOrigin!==false&&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",cache.scaleY,relative?relative*endNum:endNum-cache.scaleY);props.push("scaleY",p);p+="X"}else if(p==="transformOrigin"){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,endValue,relative);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?relative*endNum:endNum-startNum,!isTransformRelated&&(endUnit==="px"||p==="zIndex")&&vars.autoRound!==false?_renderRoundedCSSProp:_renderCSSProp);this._pt.u=endUnit||0;if(startUnit!==endUnit){this._pt.b=startValue;this._pt.r=_renderCSSPropWithBeginning}}else if(!(p in style)){if(p in target){this.add(target,p,target[p],endValue,index,targets)}else{_missingPlugin(p,endValue);continue}}else{_tweenComplexCSSString.call(this,target,p,startValue,endValue)}props.push(p)}}hasPriority&&_sortPropTweensByPriority(this)},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,_getMatrix}};gsap.utils.checkPrefix=_checkPropPrefix;(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;var TweenMaxWithCSS=gsapWithCSS.core.Tween;var _eases;function getCustomEase(key){return _eases[key]??null}function initCustomEases(eases){if(_eases)return;const{CustomEase:CustomEase2}=(init_CustomEase(),__toCommonJS(exports_CustomEase));gsapWithCSS.registerPlugin(CustomEase2);_eases={};Object.keys(eases).map((name)=>{const easeValue=eases[name];if(easeValue.substr(0,1)==="M"){_eases[name]=CustomEase2.create(name,easeValue)}else _eases[name]=easeValue})}var randomSymmetricRange=(max)=>Math.random()*max*2-max;function Signal(){let _listeners=[];const remove=(handler)=>_listeners=_listeners.filter((l)=>l[0]!==handler);function add(handler,once,callAtInit=false){_listeners.push([handler,once]);callAtInit&&handler.apply(null,Array.isArray(callAtInit)?callAtInit:null);return()=>remove(handler)}return{add(handler,callAtInit=false){return add(handler,false,callAtInit)},once(handler){return add(handler,true)},remove,dispatch:(...rest)=>_listeners.map((listener)=>{listener[1]&&remove(listener[0]);return listener[0](...rest)}),clear(){_listeners=[]},get listeners(){return _listeners.map((l)=>l[0])}}}function StateSignal(_state=null,_signal=Signal()){return{..._signal,get state(){return _state},add(handler,callAtInit=false){return _signal.add(handler,callAtInit===true?[_state]:false)},once(handler){return _signal.once(handler)},dispatch(state){const _oldState=_state;_state=state;
36return _signal.dispatch(state,_oldState)},clear(){_signal.clear();_state=null}}}var onHeaderStickyOpenedStateChanged=StateSignal();class Header extends DomComponent{init(){this.initSearch();this.initMobileMenu();this.initMenuScroll()}$sticky=this.find("_sticky");$menu=this.find("_menu");$hatRight=this.find("_hatRight");$searchButton=this.find(".SearchButton");$searchWidget=this.find("#search_widget");$searchForm=this.find("#search_widget form");$searchInput=this.find(".SearchInput");$searchClose=this.find(".SearchClose");_searchVisible=false;initSearch(){if(!this.$searchButton)return;onEvent(this.$searchButton,"click",this.searchButtonClicked.bind(this));onEvent(document,"click",this.anywhereClickedHandler.bind(this));onEvent(this.$searchInput,"keydown",this.keyboardEvent.bind(this));onEvent(this.$searchClose,"click",this.searchCloseClicked.bind(this));if(this.getSearchValue()&&!isResponsiveMobile())this._searchVisible=true;this.updateSearchVisibleState(0);onEvent(window,"resize",(event)=>{if(isResponsiveMobile()&&this._searchVisible){this._searchVisible=false;this.updateSearchVisibleState(0)}})}getSearchValue(){return this.$searchInput.value}searchButtonClicked(event){this._searchVisible=true;this.updateSearchVisibleState()}anywhereClickedHandler(event){if(!this._searchVisible)return;const parentSearch=getParentWithClass(event.target,"search-widget");if(parentSearch)return;if(this.getSearchValue())return;this.closeSearch()}searchCloseClicked(event){event.preventDefault();this.closeSearch()}keyboardEvent(event){if(!this._searchVisible)return;if(event.key=="Escape"){this.closeSearch(0.8)}}closeSearch(duration=1){if(!this._searchVisible)return;this._searchVisible=false;this.updateSearchVisibleState(duration)}updateSearchVisibleState(duration=1){gsapWithCSS.to(this.$searchForm,0.4*duration,{display:this._searchVisible?"block":"none",x:this._searchVisible?0:-50,y:"-34%",opacity:this._searchVisible?1:0,overwrite:true,ease:this._searchVisible?"power4.out":"power4.in",delay:this._searchVisible?duration*0.4:0,onStart:()=>{if(!this._searchVisible)return;gsapWithCSS.delayedCall(0.1,()=>this.$searchInput.focus())}});[...this.$hatRight.children].map((child,i)=>{if(child==this.$searchWidget)child=this.$searchButton;gsapWithCSS.to(child,0.3*duration,{autoAlpha:this._searchVisible?0:1,x:this._searchVisible?20:0,ease:this._searchVisible?"power4.in":"power4.out",overwrite:true,delay:(this._searchVisible?0:0.5*duration)+i/10})})}updateCartValue(dropAnimation=true,duration=1){let rollBackHeader=false;if(this._isHeaderSticky&&!this._isHeaderOpened){this._isHeaderOpened=true;this.updateHeaderOpenedState(0.75,true);rollBackHeader=true}const $cartIcon=$(".Header .cart-preview svg");const $cartCount=$(".Header .cart-products-count");const $cartSquare=$(".Header .cart-product-square");const fallDuration=duration*0.28;const preCountBounceDuration=duration*0.1;const preCartDuration=duration*0.15;const postCartDuration=duration*0.5;let cartCountDelay=rollBackHeader?0.4:0;if(dropAnimation){const fromPosition=randomSymmetricRange(8);gsapWithCSS.fromTo($cartSquare,fallDuration,{x:fromPosition*1.4,y:-100,autoAlpha:1,scale:1,rotation:-90-Math.random()*40},{x:0,y:0,scale:0.6,delay:cartCountDelay,rotation:30+Math.random()*30,ease:"linear"});gsapWithCSS.to($cartSquare,duration*0.05,{delay:cartCountDelay+fallDuration-duration*0.05,autoAlpha:0});gsapWithCSS.to($cartIcon,preCartDuration,{y:10,x:-fromPosition*0.6,rotation:fromPosition*0.4,delay:cartCountDelay+fallDuration,scaleY:1.1,scaleX:0.9,ease:"power3.out"});gsapWithCSS.to($cartIcon,postCartDuration+duration*0.4,{y:0,x:0,delay:cartCountDelay+fallDuration+preCartDuration,ease:getCustomEase("elasticBounceEase")});gsapWithCSS.to($cartIcon,postCartDuration+duration*0.3,{scaleX:1,rotation:0,delay:cartCountDelay+fallDuration+preCartDuration+duration*0.1,ease:getCustomEase("elasticBounceEase")});gsapWithCSS.to($cartIcon,postCartDuration+duration*0.2,{scaleY:1,delay:cartCountDelay+fallDuration+preCartDuration+duration*0.2,ease:getCustomEase("elasticBounceEase")});cartCountDelay+=fallDuration+preCartDuration+postCartDuration}gsapWithCSS.to($cartCount,preCountBounceDuration,{scale:1.3,delay:cartCountDelay});gsapWithCSS.to($cartCount,duration*0.6,{scale:1.01,force3D:true,ease:getCustomEase("elasticBounceEase"),delay:cartCountDelay+preCountBounceDuration,onStart:()=>{$cartCount.innerHTML=window["prestashop"].cart.products_count},onComplete:()=>{if(rollBackHeader&&!this._isOnPageTop&&this._isHeaderSticky&&this._isHeaderOpened){this._isHeaderOpened=false;gsapWithCSS.delayedCall(0.15,()=>{this.updateHeaderOpenedState(0.7,true)})}}})}$mobileMenu=this.find("_mobileMenu");$mobileMenuButtons=this.multiFind("_mobileButton");_mobileMenuOpened=false;
36initMobileMenu(){if(!this.$mobileMenuButtons)return;this.$mobileMenuButtons.map(($button,i)=>{onEvent($button,"click",this.menuButtonClickedHandler.bind(this,i))});onEvent(window,"resize",(event)=>{this.updateMobileMenuState(0)});this.updateMobileMenuState(0)}menuButtonClickedHandler(index,event){event.preventDefault();let newMobileMenuState=index===0;if(newMobileMenuState===this._mobileMenuOpened)return;this._mobileMenuOpened=newMobileMenuState;this.updateMobileMenuState()}updateMobileMenuState(duration=1){if(!this.$mobileMenu)return;if(!isResponsiveMobile())this._mobileMenuOpened=false;let delay=0;if(this._mobileMenuOpened){const menuPosition=gsapWithCSS.getProperty(this.$sticky,"y");if(menuPosition<-1){delay=0.3}this.updateStickyState(true,false);this.updateHeaderOpenedState(0.4)}this.$mobileMenuButtons.map(($button,i)=>{const isVisible=isResponsiveMobile()&&(i==0&&!this._mobileMenuOpened||i==1&&this._mobileMenuOpened);gsapWithCSS.to($button,duration*0.3,{display:isVisible?"block":"none",opacity:isVisible?1:0,scale:isVisible?1:i==1?0.5:1.5,ease:getCustomEase("smoothEase"),delay,overwrite:true})});const $menuElements=$$(this.$mobileMenu,".search-widget, .category, .cms-page");const closeDelay=$menuElements.length*0.035;gsapWithCSS.to(this.$mobileMenu,duration*(this._mobileMenuOpened?0.4:0.3),{display:this._mobileMenuOpened?"flex":"none",opacity:this._mobileMenuOpened?1:0,ease:getCustomEase("smoothEase"),delay:delay+(this._mobileMenuOpened?0:closeDelay),overwrite:true,onStart:()=>{gsapWithCSS.delayedCall(0.1,()=>{if(this._mobileMenuOpened)this.$mobileMenu.scrollTop=0})}});$menuElements.map(($element,i)=>{gsapWithCSS.to($element,duration*(this._mobileMenuOpened?0.3:0.1),{y:this._mobileMenuOpened?0:-30,opacity:this._mobileMenuOpened?1:0,ease:this._mobileMenuOpened?"power4.out":"power4.in",delay:delay+(!this._mobileMenuOpened?closeDelay-i*0.02:i*0.04),overwrite:true})})}_currentScrollPosition=0;_isOnPageTop=true;_isHeaderOpened=true;_isHeaderHovered=false;_isHeaderSticky=true;initMenuScroll(){if(!this.$mobileMenu)return;onEvent(window,"scroll",this.scrolledHandler.bind(this),{passive:false});onEvent($(this.$sticky,".Header_hat"),["mouseenter"],(event)=>{this._isHeaderHovered=true;this.updateHeaderHoverState()});onEvent(this.$sticky,["mouseleave"],(event)=>{this._isHeaderHovered=false;this.updateHeaderHoverState()});this.scrolledHandler()}scrolledHandler(event){if(this._mobileMenuOpened)return;const{scrollTop}=document.documentElement;const delta=scrollTop-this._currentScrollPosition;const threshold=delta<0?120:60;const startOffset=this.$sticky.clientHeight+30;const isOnPageTop=scrollTop<startOffset;if(isOnPageTop!=this._isOnPageTop){this._isOnPageTop=isOnPageTop;this.updateHeaderHoverState()}if(scrollTop<=2)this._isHeaderOpened=false;if(isOnPageTop&&!this._isHeaderOpened)this.updateStickyState(false);if(!isOnPageTop)this.updateStickyState(true);if(Math.abs(delta)>threshold){const newOpenedState=delta<=0&&this._isHeaderSticky;this._currentScrollPosition=scrollTop;if(newOpenedState!=this._isHeaderOpened){this._isHeaderOpened=newOpenedState;this.updateHeaderOpenedState();this.updateHeaderHoverState()}}}updateStickyState(newStickyState,refreshOpenedState=true){if(newStickyState==this._isHeaderSticky)return;this._isHeaderSticky=newStickyState;if(!this._isHeaderSticky){gsapWithCSS.killTweensOf(this.$sticky);gsapWithCSS.set(this.$sticky,{position:"relative",y:0});gsapWithCSS.set(this.base,{paddingTop:0})}else{gsapWithCSS.set(this.$sticky,{clearProps:"position"});gsapWithCSS.set(this.base,{clearProps:"paddingTop"});refreshOpenedState&&this.updateHeaderOpenedState(0)}}updateHeaderOpenedState(duration=1,noClass=false){const isOpened=this._isHeaderOpened||this._mobileMenuOpened;onHeaderStickyOpenedStateChanged.dispatch(isOpened);gsapWithCSS.to(this.$sticky,duration*(isOpened?0.6:0.3),{y:isOpened?-1:"-180%",ease:isOpened?"power4.out":"power4.in",overwrite:true});if(noClass)return;document.body.classList.toggle("headerIsOpened",isOpened)}updateHeaderHoverState(duration=1){const isMenuOut=this._isHeaderHovered||this._isOnPageTop;
36gsapWithCSS.to(this.$menu,duration*0.35,{y:isMenuOut?0:"-120%",ease:isMenuOut?"power4.out":"power4.in",overwrite:true})}}var _allStyle;var _currentCursor=null;var cursorAll=(cursor)=>{if(_currentCursor==cursor)return;_currentCursor=cursor;_allStyle&&_allStyle.remove();if(!cursor)return;_allStyle=create(`<style type="text/css">*{cursor:${cursor}}</style>`);document.body.append(_allStyle)};async function requestJSON(endpoint,formObject=null,returnJson=true){return new Promise(async(resolve,reject)=>{let body=null;if(formObject){body=new FormData;Object.keys(formObject).map((key)=>body.set(key,formObject[key]))}let response;try{response=await fetch(endpoint,{method:"POST",mode:"cors",credentials:"include",body});if(returnJson)response=await response.json()}catch(e){console.error(e);reject(e);return}resolve(response)})}async function updateWorkingState($target,state,disableFields=true,duration=1){return new Promise((resolve)=>{const inputs=[...$$($target,"input"),...$$($target,"button"),...$$($target,"textarea")];inputs.map(($input)=>{state&&disableFields?$input.setAttribute("disabled","disabled"):$input.removeAttribute("disabled")});cursorAll(state?"progress":null);gsapWithCSS.to($target,duration*0.25,{opacity:state?0.5:1,filter:state?"blur(3px)":"blur(0px)",pointerEvents:state?"none":null,ease:getCustomEase("aggressive"),overwrite:true,onComplete:()=>{!state&&gsapWithCSS.set($target,{filter:null});resolve()}})})}function trailing(source,add=true,char="/"){const hasTrailingSlash=source.lastIndexOf(char)==source.length-1;if(add&&!hasTrailingSlash){return source+char}else if(!add&&hasTrailingSlash){return source.substr(0,source.length-1)}else return source}class Footer extends DomComponent{$newsletterCombo=this.find("_newsletterForm");$newsletterInput=this.find("_newsletterInput");$newsletterMessage=this.find("_newsletterMessage");_isNewsletterWorking=false;init(){this.initNewsletter()}initNewsletter(){this.$newsletterCombo&&onEvent(this.$newsletterCombo,"submit",(event)=>{updateWorkingState(this.$newsletterCombo,true,false)})}async newsletterSubmit(event){event.preventDefault();if(this._isNewsletterWorking)return;this._isNewsletterWorking=true;this.$newsletterMessage.innerHTML="";this._isNewsletterWorking=true;await updateWorkingState(this.$newsletterCombo,true);const email=this.$newsletterInput.value;let endpoint=this.$newsletterCombo.getAttribute("action").split("#")[0];endpoint=trailing(endpoint,false)+"/module/ps_emailsubscription/subscription";console.log(endpoint);this.$newsletterInput.value;try{let response=await requestJSON(endpoint,{email,blockHookName:"displayFooterBefore",action:0},false);console.log(await response.text())}catch(e){}this._isNewsletterWorking=false;await updateWorkingState(this.$newsletterCombo,false)}}class Breadcrumb extends DomComponent{init(){}}class CategoryHeader extends DomComponent{init(){}}class ProductsTop extends DomComponent{init(){}}class ProductList extends DomComponent{init(){}}class AppView extends DomComponent{$header=this.ref(Header);$footer=this.ref(Footer);$breadcrumb=this.lazyRef(Breadcrumb);$categoryHeader=this.lazyRef(CategoryHeader);$productsTop=this.lazyRef(ProductsTop);$productsList=this.lazyRef(ProductList);init(){this.initForms()}initForms(){$$(".custom-checkbox").map(($checkboxContainer)=>{const $checkboxInput=$($checkboxContainer,"input");const $label=$($checkboxContainer,"label");if(!$label)return;onEvent($label,"click",(event)=>{event.preventDefault();$checkboxInput.click()})})}}class Product extends DomComponent{init(){}}var limitRange=(min,value,max)=>Math.max(min,Math.min(value,max));var import_vanilla_swipe=__toESM(require_lib(),1);var VanillaSwipeObj=import_vanilla_swipe.default.default;class HomePage extends DomComponent{$categories=this.multiFind("_categoryBlock");$productsByCategory=[];$navButtonsByCategory=[];init(){this.$productsByCategory=this.$categories.map(($category)=>{const $products=$$($category,".Product");return $products.map((p)=>new Product(p))});this.$categories.map(this.initCategory.bind(this))}getProductsOfCategory(categoryIndex){return this.$productsByCategory[categoryIndex]}getRandomizedSeed(seed){return Math.sin(seed*453845)/2+0.5}_currentProductIndexByCategory=[];initCategory($category,categoryIndex){const products=this.getProductsOfCategory(categoryIndex);products.map((product,productIndex)=>onEvent(product.base,"click",(e)=>this.productClickedHandler(e,categoryIndex,productIndex)));this.$navButtonsByCategory[categoryIndex]=[];$$($category,".Button-fatArrow").map(($button,buttonIndex)=>{this.$navButtonsByCategory[categoryIndex][buttonIndex]=$button;onEvent($button,"click",(e)=>this.navButtonClickedHandler(e,categoryIndex,buttonIndex))});this._currentProductIndexByCategory[categoryIndex]=0;this.placeProductsForCategory(categoryIndex,0);const VS=new VanillaSwipeObj({element:$($category,".HomePage_categoryBlockProducts"),onSwiping:function(e,data){if(Math.abs(data.deltaX)>Math.abs(data.deltaY))e.preventDefault()},onSwiped:(e,data)=>
36{if(Math.abs(data.deltaX)<=Math.abs(data.deltaY))return;e.preventDefault();if(data.directionX=="LEFT")this.navButtonClickedHandler(null,categoryIndex,1);if(data.directionX=="RIGHT")this.navButtonClickedHandler(null,categoryIndex,0)},delta:5,directionDelta:3,mouseTrackingEnabled:true});VS.init()}navButtonClickedHandler(event,categoryIndex,buttonIndex){event?.stopPropagation();const products=this.getProductsOfCategory(categoryIndex);let currentIndex=this._currentProductIndexByCategory[categoryIndex];const oldIndex=currentIndex;currentIndex+=buttonIndex==0?-1:1;currentIndex=limitRange(0,currentIndex,products.length-1);if(currentIndex==oldIndex)return;this._currentProductIndexByCategory[categoryIndex]=currentIndex;this.placeProductsForCategory(categoryIndex,1,"rough")}productClickedHandler(event,categoryIndex,productIndex){if(this._currentProductIndexByCategory[categoryIndex]==productIndex)return;this._currentProductIndexByCategory[categoryIndex]=productIndex;this.placeProductsForCategory(categoryIndex);event.preventDefault()}placeProductsForCategory(categoryIndex,duration=1,ease="smooth"){const products=this.getProductsOfCategory(categoryIndex);const currentProductIndex=this._currentProductIndexByCategory[categoryIndex];this.$navButtonsByCategory[categoryIndex].map(($button,buttonIndex)=>{$button.classList.toggle("Button-disabled",buttonIndex==0?currentProductIndex==0:currentProductIndex==products.length-1)});products.map((product,productIndex)=>{const seed=productIndex+categoryIndex*10;const productOffset=productIndex-currentProductIndex;const isSelected=productIndex==currentProductIndex;const isOnRight=productIndex>currentProductIndex;const isBehind=!isSelected&&!isOnRight;ease=ease=="smooth"?getCustomEase("aggressive"):"power3.out";const toggleClass=(isComplete,force=false)=>{if(!force&&isSelected&&!isComplete)return;if(!force&&!isSelected&&isComplete)return;product.base.classList.toggle("Product-hovers",isSelected)};const updateZIndex=(isComplete,isOnRight2,force=false)=>{if(!force&&isComplete&&!isOnRight2)return;if(!force&&!isComplete&&isOnRight2)return};const baseOffset=isResponsiveMobile()?60:80;const itemOffset=isResponsiveMobile()?2:10;gsapWithCSS.to(product.base,duration*0.6,{x:isOnRight?baseOffset+productOffset*itemOffset+"%":"-50%",y:"-50%",scale:isBehind?0.5:1,autoAlpha:isBehind?0:2,rotation:isSelected||!isOnRight?0:(this.getRandomizedSeed(seed)-0.5)*10,transformOrigin:"center center",display:isSelected||isOnRight?"flex":"none",ease,overwrite:true,onStart:()=>toggleClass(false),onComplete:()=>toggleClass(true)});gsapWithCSS.set(product.base,{zIndex:(isBehind?0:products.length+2-productIndex)+10,delay:isSelected?duration*0.6:0});if(duration===0)toggleClass(null,true);[$(product.base,".Product_title"),$(product.base,".Product_price")].map((toHide)=>{gsapWithCSS.to(toHide,duration*0.3,{autoAlpha:isSelected?1:0,ease,overwrite:true})})})}}function addMouseOrKeyboardClass(mouseClass="usingMouse",keyboardClass="usingKeyboard",target=null){let hasKeyboardClass=false;const handler=(event)=>{const{classList}=event.currentTarget;classList.toggle(mouseClass,event.type=="mousedown");const keyCode=event.keyCode;hasKeyboardClass=event.type=="keydown"&&(keyCode===9||hasKeyboardClass&&(keyCode==14||keyCode==32));classList.toggle(keyboardClass,hasKeyboardClass)};let listener;let destroyed=false;ready().then(()=>{if(destroyed)return;listener=onEvent(target??document.body,["mousedown","keydown"],handler)});return()=>{destroyed=true;listener&&listener()}}var vhPatch=()=>{function resized(){const vh=window.innerHeight*0.01;document.documentElement.style.setProperty("--vh",`${vh}px`)}window.addEventListener("resize",resized);resized()};function setAttributes2(element,attributes){Object.keys(attributes).map((key)=>{let value=attributes[key];if(value===true||value==="")value="";else if(value===false||value===null){element.removeAttribute(key);return}element.setAttribute(key,value)})}function setStyle2(element,style){const elements=Array.isArray(element)?element:[element];elements.map((el)=>{Object.keys(style).map((property)=>{let value=null;switch(typeof style[property]){case"string":value=style[property];break;case"number":value=style[property];break;case"function":value=style[property](element,style);break}el.style[property]=value})})}function element(htmlOrTagName,attributes,styleProperties){let element2;if(htmlOrTagName.indexOf("<")===-1)element2=document.createElement(htmlOrTagName);else{const el=document.createElement("div");el.innerHTML=htmlOrTagName;element2=el.firstElementChild}attributes&&setAttributes2(element2,attributes);styleProperties&&setStyle2(element2,styleProperties);return element2}function selectorDefaults2(containerOrSelector,selector){let container=containerOrSelector;if(selector==null){selector=containerOrSelector;container=document.documentElement}return[container,selector]}function findAll(containerOrSelector,selector){const[c,s]=selectorDefaults2(containerOrSelector,selector);return Array.from(c.querySelectorAll(s))}var import_vanilla_swipe2=__toESM(require_lib(),1);var VanillaSwipeObj2=import_vanilla_swipe2.default.default;class ProductSlideshow extends DomComponent{$slideshowImages=this.multiFind("_slideshowImage");$slideshowButtons=this.multiFind(".Button");_currentSlide=0;init(){this.$slideshowButtons.map(($button,i)=>{onEvent($button,"click",(event)=>this.slideshowButtonClickedHandler(event,i))});const VS=new VanillaSwipeObj2({element:this.base,onSwiping:function(e,data){if(Math.abs(data.deltaX)>Math.abs(data.deltaY))e.preventDefault()},onSwiped:(e,data)=>
36{if(Math.abs(data.deltaX)<=Math.abs(data.deltaY))return;e.preventDefault();if(data.directionX=="LEFT")this.slideshowButtonClickedHandler(null,1);if(data.directionX=="RIGHT")this.slideshowButtonClickedHandler(null,0)},delta:5,directionDelta:3,mouseTrackingEnabled:true});VS.init()}slideshowButtonClickedHandler(event,index){event?.preventDefault();this._currentSlide+=index==0?-1:1;this._currentSlide=limitRange(0,this._currentSlide,this.$slideshowImages.length-1);this.updateCurrentSlide()}updateCurrentSlide(duration=1){this.$slideshowImages.map(($image,i)=>{const selected=i==this._currentSlide;gsapWithCSS.to($image,duration*0.28,{display:"block",autoAlpha:selected?1:0,delay:selected?0:duration*0.05,ease:"linear"})});this.$slideshowButtons.map(($button,i)=>{$button.classList.toggle("Button-disabled",i==0?this._currentSlide==0:this._currentSlide==this.$slideshowImages.length-1)})}}var disabledButtonClass="Button-disabled";var cartAreaDisabledClass="ProductPage_cartArea-notAvailable";class ProductPage extends DomComponent{$slideshows=this.multiRef(ProductSlideshow);init(){this.initCart();this.initFAQ();this.initBuyBar();this.initVariants()}$cartForm=this.find("_cartForm");$cartArea=this.find("_cartArea");$addToCartButton=this.find("_cartAddButton");$cartQuantityButtons=this.multiFind("_cartQuantityButton");$cartQuantity=this.find("_cartQuantityInput");$priceContainer=this.find("_priceContainer");initCart(){onEvent(this.$cartForm,"submit",this.cartFormSubmit.bind(this));this.$cartQuantity&&this.$cartQuantityButtons.map(($button,index)=>{onEvent($button,"click",(e)=>this.cartQuantityButtonClicked(e,index))})}cartQuantityButtonClicked(event,index){event.preventDefault();event.stopPropagation();const currentValue=this.$cartQuantity.valueAsNumber;const max=parseInt(this.$cartQuantity.getAttribute("max"),10);if(currentValue<=1&&index==0)return;else if(currentValue>=max&&index==1)return;this.$cartQuantity.valueAsNumber+=index==0?-1:1}async cartFormSubmit(event){event.preventDefault();const quantity=this.$cartQuantity?this.$cartQuantity.valueAsNumber:1;const endpoint=this.$cartForm.getAttribute("action");const formData=new FormData(this.$cartForm);this.$addToCartButton.classList.toggle(disabledButtonClass,true);this.$buttonCopy&&updateWorkingState(this.$buttonCopy,true);await updateWorkingState(this.$cartForm,true);const requestBody={gty:quantity,add:"1",action:"update"};for(const key of formData.keys())requestBody[key]=formData.get(key);let response;try{response=await requestJSON(endpoint,requestBody,false);if(response.status!=200)throw response}catch(e){console.log("Error");console.error(e);return}finally{this.$addToCartButton.classList.toggle(disabledButtonClass,false);this.$buttonCopy&&updateWorkingState(this.$buttonCopy,false);await updateWorkingState(this.$cartForm,false)}this.buyButtonAddedAnimation(this.$addToCartButton);this.$buttonCopy&&this.buyButtonAddedAnimation(this.$buttonCopy);const{cart}=window["prestashop"];if(!("products_count"in cart))cart.products_count=0;cart.products_count+=quantity;getAppView().$header.updateCartValue()}buyButtonAddedAnimation($buyButton,duration=1){const $spans=$$($buyButton,"span");const ease=getCustomEase("aggressive");const delay=duration*2;const force3D=true;const notOne=1.01;gsapWithCSS.set($spans[1],{scaleX:2});duration*=0.4;gsapWithCSS.to($spans[0],duration,{autoAlpha:0,scaleX:0.5,force3D,ease});gsapWithCSS.to($spans[1],duration,{autoAlpha:1,scaleX:notOne,force3D,ease});gsapWithCSS.to($spans[0],duration,{autoAlpha:1,scaleX:notOne,force3D,ease,delay});gsapWithCSS.to($spans[1],duration,{autoAlpha:0,scaleX:2,force3D,ease,delay})}$faqBlocks=this.multiFind("_faqBlock");$faqBlockTitles=this.multiFind("_faqBlockTitle");$faqBlockArrow=this.multiFind("_faqBlockArrow");$faqBlockContents=this.multiFind("_faqBlockContent");_currentFaqBlockIndex=-1;initFAQ(){this.$faqBlocks.map(($faqBlock,index)=>{onEvent(this.$faqBlockTitles[index],"click",(e)=>this.faqBlockClicked(e,index));onEvent(this.$faqBlockArrow[index],"click",(e)=>this.faqBlockClicked(e,index))})}faqBlockClicked(event,faqBlockIndex){event.preventDefault();this._currentFaqBlockIndex=faqBlockIndex==this._currentFaqBlockIndex?-1:faqBlockIndex;this.updateFaqBlockState()}updateFaqBlockState(duration=1){this.$faqBlockContents.map(($content,index)=>{const isSelected=this._currentFaqBlockIndex==index;gsapWithCSS.to($content,duration*0.44,{height:isSelected?"auto":0,marginBottom:isSelected?"1rem":0,autoAlpha:isSelected?1:0,ease:getCustomEase("aggressive"),overwrite:true});gsapWithCSS.to(this.$faqBlockArrow[index],duration*0.44,{rotation:isSelected?90:0,ease:getCustomEase("aggressive"),overwrite:true})})}$buyBar=this.find("_buyBar");$buyBarTitle=this.find("_buyBarTitle");
36$buyBarColumns=this.multiFind("_buyBarColumn");$buttonCopy;$cms=this.find("_cms");_isBuyBarVisible=false;initBuyBar(){let noBuyBar=this.find("_variants").children.length>0||this.find("_cartArea-notAvailable");if(noBuyBar){this.$buyBar.remove();return}if(this.$buyBarColumns[1].children.length>0)return;this.$buyBarTitle.innerHTML=this.find(".ProductPage_title").innerHTML;const $priceCopy=element(this.$priceContainer.outerHTML);this.$buttonCopy=element(this.$addToCartButton.outerHTML);this.$buyBarColumns[1].appendChild($priceCopy);this.$buyBarColumns[1].appendChild(this.$buttonCopy);onEvent(this.$buttonCopy,"click",this.cartFormSubmit.bind(this));onEvent(window,"scroll",this.buyBarWindowScrolled.bind(this));this.buyBarWindowScrolled(null);onHeaderStickyOpenedStateChanged.add(()=>{this.buyBarWindowScrolled(null)})}buyBarWindowScrolled(event){const addToCartButtonRect=this.$addToCartButton.getBoundingClientRect();const bottomRect=this.$cms.getBoundingClientRect();const buyBarVisible=(window.innerHeight>=900||!onHeaderStickyOpenedStateChanged.state)&&addToCartButtonRect.bottom<0&&bottomRect.bottom+300>window.innerHeight;if(this._isBuyBarVisible==buyBarVisible)return;this._isBuyBarVisible=buyBarVisible;this.updateBuyBarVisibility(this._isBuyBarVisible)}updateBuyBarVisibility(state,duration=1){gsapWithCSS.to(this.$buyBar,duration*0.8,{y:state?0:"200%",ease:getCustomEase("aggressive"),overwrite:true})}initVariants(){const $variantsContainer=this.find("_variants");findAll($variantsContainer,"select, input[type=radio]").forEach(($input)=>{onEvent($input,"change",(event)=>{this.ajaxUpdate()})})}async ajaxUpdate(){let endpoint=window["prestashop"].urls.base_url+"index.php?";const formData=new FormData(this.$cartForm);const requestBody={controller:"product",qty:"1"};for(const key of formData.keys())requestBody[key]=formData.get(key);const params=new URLSearchParams(requestBody);endpoint+=params.toString();this.$addToCartButton.classList.toggle(disabledButtonClass,true);updateWorkingState(this.$priceContainer,true);await updateWorkingState(this.$cartForm,true);let response;try{response=await requestJSON(endpoint,{quickview:0,ajax:1,action:"refresh",quantity_wanted:1})}catch(e){console.log("Error");console.error(e);return}if(response&&"product_add_to_cart"in response){const addToCartSection=this.parseJSONFromTemplate(response.product_add_to_cart);const isAvailable=addToCartSection.availability=="available"||addToCartSection.availability=="last_remaining_items";this.$cartArea.classList.toggle(cartAreaDisabledClass,!isAvailable);this.find("_cartMessage").innerHTML=addToCartSection.message}if(response&&"product_prices"in response)this.$priceContainer.innerHTML=response.product_prices;this.$addToCartButton.classList.toggle(disabledButtonClass,false);updateWorkingState(this.$priceContainer,false);await updateWorkingState(this.$cartForm,false)}parseJSONFromTemplate(string){const lines=string.split(`
37`).filter((line)=>{return line.indexOf("<!--")!==0&&line.length>0});const buffer=lines.join("");return JSON.parse(buffer)}}class CMSPage extends DomComponent{init(){}}async function doShakeAnimation(target,shakes=3,duration=0.04,distance=5){const shake=(target2,direction,duration2)=>new Promise((resolve)=>gsapWithCSS.to(target2,duration2,{x:direction*distance,ease:"power3.inOut",onComplete:resolve}));const totalShakes=Math.floor(shakes*2+1);for(let i=0;i<totalShakes;i++)await shake(target,i==totalShakes-1?0:i%2?-1:1,duration)}var debounceDelay=0.3;class CartPage extends DomComponent{$getProducts=()=>this.multiFind("_product");$getColumns=()=>this.find("_columns");$getPromoCombo=()=>this.find("_promoCombo");$getQuantityInput=($product)=>$($product,".CartPage_productQuantityInput");$getDeleteButton=($product)=>$($product,".CartPage_productActionDelete");init(){this.initActions()}_debounceQuantityTimeout;_isWorking=false;_productQuantities={};_promoErrors=null;initActions(){this.$getProducts().map(($product,productIndex)=>{const $input=this.$getQuantityInput($product);this._productQuantities[productIndex]=$input.valueAsNumber;onEvent($input,"change",(event)=>{this.sanitizeInputValue($input);this.ajaxUpdateQuantity(productIndex)});$$($product,".CartPage_productQuantityButton").map(($button,buttonIndex)=>{onEvent($button,"click",(event)=>{event.preventDefault();if(this._isWorking)return;this.sanitizeInputValue($input,buttonIndex==0?-1:1);this.debounceQuantity(productIndex)})});onEvent(this.$getDeleteButton($product),"click",(event)=>{event.preventDefault();this.ajaxDeleteProduct(productIndex)})});const $promoCombo=this.$getPromoCombo();$promoCombo&&onEvent($promoCombo,"submit",(event)=>{event.preventDefault();this.ajaxAddPromoCode()});this.multiFind("_promoDelete").map(($promoDelete,promoIndex)=>{onEvent($promoDelete,"click",(event)=>{event.preventDefault();this.ajaxRemovePromoCode(promoIndex)})})}sanitizeInputValue($input,offset=0){let value=$input.valueAsNumber;value=limitRange(1,value+offset,99);$input.value=value+""}debounceQuantity(productIndex){clearTimeout(this._debounceQuantityTimeout);this._debounceQuantityTimeout=setTimeout(()=>{this._debounceQuantityTimeout=null;this.ajaxUpdateQuantity(productIndex)},debounceDelay*1000)}ajaxUpdateQuantity(productIndex){return this.ajaxRequest(()=>{return new Promise(async(resolve,reject)=>{const $product=this.$getProducts()[productIndex];const $input=this.$getQuantityInput($product);const updateEndpoint=$input.getAttribute("data-update-url");const oldValue=this._productQuantities[productIndex];const newValue=$input.valueAsNumber;if(oldValue==newValue)return resolve();const direction=newValue>oldValue;let response;try{response=await requestJSON(updateEndpoint,{ajax:1,qty:Math.abs(newValue-oldValue),action:"update",op:direction?"up":"down"})}catch(e){return reject(e)}resolve()})})}ajaxDeleteProduct(productIndex){return this.ajaxRequest(()=>{return new Promise(async(resolve,reject)=>{this.resetState();const $product=this.$getProducts()[productIndex];const $deleteButton=this.$getDeleteButton($product);const deleteEndpoint=$deleteButton.getAttribute("href");let response;try{await requestJSON(deleteEndpoint,{ajax:1,action:"update"})}catch(e){return reject(e)}resolve()})})}ajaxAddPromoCode(){return this.ajaxRequest(()=>{return new Promise(async(resolve,reject)=>{this.resetState();const $promoCombo=this.$getPromoCombo();const $promoToken=$($promoCombo,".CartPage_promoToken");const $promoInput=$($promoCombo,".CartPage_promoInput");const promoEndpoint=$promoCombo.getAttribute("action");let response;try{response=await requestJSON(promoEndpoint,{ajax:1,action:"update",discount_name:$promoInput.value,token:$promoToken.value,addDiscount:1})}catch(e){return reject(e)}if(response.hasError)this._promoErrors=response.errors;resolve()})})}ajaxRemovePromoCode(promoIndex){return this.ajaxRequest(()=>{return new Promise(async(resolve,reject)=>{this.resetState();const $promoDelete=this.multiFind("_promoDelete")[promoIndex];const endpoint=$promoDelete.getAttribute("href");let response;
37try{response=await requestJSON(endpoint,null,false)}catch(e){return reject(e)}resolve()})})}async ajaxRequest(handler){await updateWorkingState(this.$getColumns(),true);let hadErrors=false;try{await handler()}catch(e){hadErrors=true;console.error(e);return}if(!hadErrors)await this.ajaxUpdate();await updateWorkingState(this.$getColumns(),false);if(Array.isArray(this._promoErrors)){gsapWithCSS.delayedCall(0.2,()=>doShakeAnimation(this.$getPromoCombo(),5));const errorLines=this._promoErrors.map((promo)=>`<span>${promo}</span>`);const $promoErrors=this.find("_promoErrors");if($promoErrors)$promoErrors.innerHTML=errorLines.join("<br/>")}}async ajaxUpdate(){const endpoint=window["prestashop"].urls.current_url.split("?")[0]+"?ajax=1&action=refresh";let response;try{response=await requestJSON(endpoint)}catch(e){return}$("#cart_detailed").innerHTML=response.cart_detailed;$("#cart_detailed_totals").innerHTML=response.cart_detailed_totals;let total=0;this.$getProducts().map(($product)=>{total+=this.$getQuantityInput($product).valueAsNumber});window["prestashop"].cart.products_count=total;setStyle2(this.find("_summary"),{display:total==0?"none":"block"});getAppView().$header.updateCartValue(false);this.initActions()}resetState(){this._promoErrors=null;const $promoErrors=this.find("_promoErrors");if($promoErrors)this.find("_promoErrors").innerHTML=""}}class ContactPage extends DomComponent{$form=this.find("_form");init(){}async formSubmitHandler(event){}}class NotFoundPage extends DomComponent{init(){}}class AddressCard extends DomComponent{$input=this.find("_radioInput");$deleteButton=this.find("_deleteButton");
37init(){if(this.$deleteButton){onEvent(this.$deleteButton,"click",(event)=>{const result=confirm("Êtes-vous sûr ?");if(!result)event.preventDefault()})}}}class AuthenticationPage extends DomComponent{init(){if(!this.base)this.base=document.body;this.multiRef(AddressCard)}}var promises=(()=>({}));var{setTimeout:setTimeout2,clearTimeout:clearTimeout2,setInterval:setInterval2,setImmediate,clearInterval,clearImmediate}=globalThis;class CheckoutPage extends DomComponent{$addressCards=this.lazyRef(AddressCard);$loader=this.find(".loading");$paymentConfirmation=this.find("#payment-confirmation");init(){this.initSwitchableTabLinks();this.initStepsAccordion();this.initStripeLoader();this.initAboTransporterFix()}initAboTransporterFix(){let $aboDeliverySlice=$$("#delivery_option_227");if($aboDeliverySlice.length===0)$aboDeliverySlice=$$("#delivery_option_206");const $parent=$$(".CheckoutPage_deliveryItem")[0];const isFirst2=$parent&&$parent.firstElementChild===$aboDeliverySlice[0]?.parentElement;if($aboDeliverySlice.length===0||!isFirst2)return;$aboDeliverySlice[0].click();$$(".CheckoutPage_deliveryItem").map((el)=>{if(el.contains($aboDeliverySlice[0]))return;el.remove()})}initStripeLoader(){let $paymentForm;let updatePaymentForm=()=>$paymentForm=$$("#js-stripe-payment-element")[0];const showPaymentForm=async()=>{await gsapWithCSS.to(this.$loader,{duration:0.3,opacity:0,delay:0.3});this.$loader.remove();updatePaymentForm();gsapWithCSS.set([$paymentForm,this.$paymentConfirmation],{display:"block"});gsapWithCSS.to([$paymentForm,this.$paymentConfirmation],{duration:0.3,delay:0.4,opacity:1})};let interval=setInterval(()=>{updatePaymentForm();if($paymentForm){clearInterval(interval);showPaymentForm()}},500)}$switchableTabs=this.multiFind("_switchableTab");$switchableTabLinks=this.multiFind("_switchableTabLink");initSwitchableTabLinks(){this.$switchableTabLinks.map(($link)=>{onEvent($link,"click",(event)=>{event.preventDefault();const link=$link.dataset.link.toLowerCase();const $selectedTab=this.$switchableTabs.find(($tab)=>{return $tab.dataset.tabId.toLowerCase()==link});this.selectTab($selectedTab)})});this.$switchableTabs.map(($tab,i)=>{const notifications=$$($tab,".Notifications");if(i!=0&&notifications.length>0){this.selectTab($tab)}})}selectTab($tab){this.$switchableTabs.map(($currentTab)=>{$currentTab.classList.toggle("CheckoutPage_switchableTab-hidden",$currentTab!=$tab)})}$steps=this.multiFind("_step");$stepEditButtons=this.multiFind("_stepTitleEdit");initStepsAccordion(){this.$stepEditButtons.map(($edit,buttonIndex)=>{onEvent($edit,"click",(event)=>{event.preventDefault();this.$steps.map(($step,stepIndex)=>{$step.classList.toggle("CheckoutPage_step-current",buttonIndex==stepIndex)});this.$stepEditButtons.map(($edit2,afterButtonIndex)=>{if(afterButtonIndex>=buttonIndex&&afterButtonIndex>1)$edit2.remove()})})})}}initCustomEases({smoothEase:"M0,0 C0.358,0 0.339,0.229 0.42,0.434 0.494,0.622 0.536,1 1,1",aggressive:"M0,0 C0.238,0 0.204,0.407 0.286,0.608 0.418,0.934 0.59,1 1,1",elasticBounceEase:"elastic.out(1.2, 0.4)"});vhPatch();addMouseOrKeyboardClass();window["replaceOriginalSource"]=function(target){target.parentElement.removeChild(target.parentElement.getElementsByTagName("source")[0])};__toCommonJS(exports_signature).printHallucinesSignature();var isResponsiveMobile=()=>{return window.innerWidth<768};var pagesClassesByID={index:HomePage,product:ProductPage,cms:CMSPage,cart:CartPage,contact:ContactPage,pagenotfound:NotFoundPage,authentication:AuthenticationPage,password:AuthenticationPage,checkout:CheckoutPage};var appView;var getAppView=()=>appView;var page;var getCurrentPage=()=>page;ready().then(async()=>{appView=new AppView;new GridDebug;const{id}=document.body;page=id in pagesClassesByID?new pagesClassesByID[id]:null});})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.