chbim-plugins 0.1.8 → 0.1.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/chbim-plugins.js +1182 -1182
- package/chbim-plugins.umd.cjs +21 -21
- package/package.json +1 -1
package/chbim-plugins.umd.cjs
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Club GreenSock members, the software agreement that was issued with your membership.
|
|
11
11
|
*
|
|
12
12
|
* @author: Jack Doyle, jack@greensock.com
|
|
13
|
-
**/var ln=typeof module<"u"&&module.exports&&typeof global<"u"?global:globalThis||window;(ln._gsQueue||(ln._gsQueue=[])).push(function(){ln._gsDefine("TweenMax",["core.Animation","core.SimpleTimeline","TweenLite"],function(x,a,o){var c=function(E){var P,w=[],M=E.length;for(P=0;P!==M;w.push(E[P++]));return w},f=function(E,P,w){var M,R,C=E.cycle;for(M in C)R=C[M],E[M]=typeof R=="function"?R(w,P[w]):R[w%R.length];delete E.cycle},u=function(E,P,w){o.call(this,E,P,w),this._cycle=0,this._yoyo=this.vars.yoyo===!0||!!this.vars.yoyoEase,this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._repeat&&this._uncache(!0),this.render=u.prototype.render},m=1e-10,g=o._internals,v=g.isSelector,S=g.isArray,b=u.prototype=o.to({},.1,{}),O=[];u.version="2.0.2",b.constructor=u,b.kill()._gc=!1,u.killTweensOf=u.killDelayedCallsTo=o.killTweensOf,u.getTweensOf=o.getTweensOf,u.lagSmoothing=o.lagSmoothing,u.ticker=o.ticker,u.render=o.render,b.invalidate=function(){return this._yoyo=this.vars.yoyo===!0||!!this.vars.yoyoEase,this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._yoyoEase=null,this._uncache(!0),o.prototype.invalidate.call(this)},b.updateTo=function(E,P){var w,M=this.ratio,R=this.vars.immediateRender||E.immediateRender;P&&this._startTime<this._timeline._time&&(this._startTime=this._timeline._time,this._uncache(!1),this._gc?this._enabled(!0,!1):this._timeline.insert(this,this._startTime-this._delay));for(w in E)this.vars[w]=E[w];if(this._initted||R){if(P)this._initted=!1,R&&this.render(0,!0,!0);else if(this._gc&&this._enabled(!0,!1),this._notifyPluginsOfEnabled&&this._firstPT&&o._onPluginEvent("_onDisable",this),this._time/this._duration>.998){var C=this._totalTime;this.render(0,!0,!1),this._initted=!1,this.render(C,!0,!1)}else if(this._initted=!1,this._init(),this._time>0||R)for(var U,F=1/(1-M),X=this._firstPT;X;)U=X.s+X.c,X.c*=F,X.s=U-X.c,X=X._next}return this},b.render=function(E,P,w){this._initted||this._duration===0&&this.vars.repeat&&this.invalidate();var M,R,C,U,F,X,K,Z,ct,Rt=this._dirty?this.totalDuration():this._totalDuration,tt=this._time,_t=this._totalTime,G=this._cycle,Pt=this._duration,Et=this._rawPrevTime;if(E>=Rt-1e-7&&E>=0?(this._totalTime=Rt,this._cycle=this._repeat,this._yoyo&&1&this._cycle?(this._time=0,this.ratio=this._ease._calcEnd?this._ease.getRatio(0):0):(this._time=Pt,this.ratio=this._ease._calcEnd?this._ease.getRatio(1):1),this._reversed||(M=!0,R="onComplete",w=w||this._timeline.autoRemoveChildren),Pt===0&&(this._initted||!this.vars.lazy||w)&&(this._startTime===this._timeline._duration&&(E=0),(0>Et||0>=E&&E>=-1e-7||Et===m&&this.data!=="isPause")&&Et!==E&&(w=!0,Et>m&&(R="onReverseComplete")),this._rawPrevTime=Z=!P||E||Et===E?E:m)):1e-7>E?(this._totalTime=this._time=this._cycle=0,this.ratio=this._ease._calcEnd?this._ease.getRatio(0):0,(_t!==0||Pt===0&&Et>0)&&(R="onReverseComplete",M=this._reversed),0>E&&(this._active=!1,Pt===0&&(this._initted||!this.vars.lazy||w)&&(Et>=0&&(w=!0),this._rawPrevTime=Z=!P||E||Et===E?E:m)),this._initted||(w=!0)):(this._totalTime=this._time=E,this._repeat!==0&&(U=Pt+this._repeatDelay,this._cycle=this._totalTime/U>>0,this._cycle!==0&&this._cycle===this._totalTime/U&&E>=_t&&this._cycle--,this._time=this._totalTime-this._cycle*U,this._yoyo&&1&this._cycle&&(this._time=Pt-this._time,ct=this._yoyoEase||this.vars.yoyoEase,ct&&(this._yoyoEase||(ct!==!0||this._initted?this._yoyoEase=ct=ct===!0?this._ease:ct instanceof Ease?ct:Ease.map[ct]:(ct=this.vars.ease,this._yoyoEase=ct=ct?ct instanceof Ease?ct:typeof ct=="function"?new Ease(ct,this.vars.easeParams):Ease.map[ct]||o.defaultEase:o.defaultEase)),this.ratio=ct?1-ct.getRatio((Pt-this._time)/Pt):0)),this._time>Pt?this._time=Pt:this._time<0&&(this._time=0)),this._easeType&&!ct?(F=this._time/Pt,X=this._easeType,K=this._easePower,(X===1||X===3&&F>=.5)&&(F=1-F),X===3&&(F*=2),K===1?F*=F:K===2?F*=F*F:K===3?F*=F*F*F:K===4&&(F*=F*F*F*F),X===1?this.ratio=1-F:X===2?this.ratio=F:this._time/Pt<.5?this.ratio=F/2:this.ratio=1-F/2):ct||(this.ratio=this._ease.getRatio(this._time/Pt))),tt===this._time&&!w&&G===this._cycle)return void(_t!==this._totalTime&&this._onUpdate&&(P||this._callback("onUpdate")));if(!this._initted){if(this._init(),!this._initted||this._gc)return;if(!w&&this._firstPT&&(this.vars.lazy!==!1&&this._duration||this.vars.lazy&&!this._duration))return this._time=tt,this._totalTime=_t,this._rawPrevTime=Et,this._cycle=G,g.lazyTweens.push(this),void(this._lazy=[E,P]);!this._time||M||ct?M&&this._ease._calcEnd&&!ct&&(this.ratio=this._ease.getRatio(this._time===0?0:1)):this.ratio=this._ease.getRatio(this._time/Pt)}for(this._lazy!==!1&&(this._lazy=!1),this._active||!this._paused&&this._time!==tt&&E>=0&&(this._active=!0),_t===0&&(this._initted===2&&E>0&&this._init(),this._startAt&&(E>=0?this._startAt.render(E,!0,w):R||(R="_dummyGS")),this.vars.onStart&&(this._totalTime!==0||Pt===0)&&(P||this._callback("onStart"))),C=this._firstPT;C;)C.f?C.t[C.p](C.c*this.ratio+C.s):C.t[C.p]=C.c*this.ratio+C.s,C=C._next;this._onUpdate&&(0>E&&this._startAt&&this._startTime&&this._startAt.render(E,!0,w),P||(this._totalTime!==_t||R)&&this._callback("onUpdate")),this._cycle!==G&&(P||this._gc||this.vars.onRepeat&&this._callback("onRepeat")),R&&(!this._gc||w)&&(0>E&&this._startAt&&!this._onUpdate&&this._startTime&&this._startAt.render(E,!0,w),M&&(this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!P&&this.vars[R]&&this._callback(R),Pt===0&&this._rawPrevTime===m&&Z!==m&&(this._rawPrevTime=0))},u.to=function(E,P,w){return new u(E,P,w)},u.from=function(E,P,w){return w.runBackwards=!0,w.immediateRender=w.immediateRender!=0,new u(E,P,w)},u.fromTo=function(E,P,w,M){return M.startAt=w,M.immediateRender=M.immediateRender!=0&&w.immediateRender!=0,new u(E,P,M)},u.staggerTo=u.allTo=function(E,P,w,M,R,C,U){M=M||0;var F,X,K,Z,ct=0,Rt=[],tt=function(){w.onComplete&&w.onComplete.apply(w.onCompleteScope||this,arguments),R.apply(U||w.callbackScope||this,C||O)},_t=w.cycle,G=w.startAt&&w.startAt.cycle;for(S(E)||(typeof E=="string"&&(E=o.selector(E)||E),v(E)&&(E=c(E))),E=E||[],0>M&&(E=c(E),E.reverse(),M*=-1),F=E.length-1,K=0;F>=K;K++){X={};for(Z in w)X[Z]=w[Z];if(_t&&(f(X,E,K),X.duration!=null&&(P=X.duration,delete X.duration)),G){G=X.startAt={};for(Z in w.startAt)G[Z]=w.startAt[Z];f(X.startAt,E,K)}X.delay=ct+(X.delay||0),K===F&&R&&(X.onComplete=tt),Rt[K]=new u(E[K],P,X),ct+=M}return Rt},u.staggerFrom=u.allFrom=function(E,P,w,M,R,C,U){return w.runBackwards=!0,w.immediateRender=w.immediateRender!=0,u.staggerTo(E,P,w,M,R,C,U)},u.staggerFromTo=u.allFromTo=function(E,P,w,M,R,C,U,F){return M.startAt=w,M.immediateRender=M.immediateRender!=0&&w.immediateRender!=0,u.staggerTo(E,P,M,R,C,U,F)},u.delayedCall=function(E,P,w,M,R){return new u(P,0,{delay:E,onComplete:P,onCompleteParams:w,callbackScope:M,onReverseComplete:P,onReverseCompleteParams:w,immediateRender:!1,useFrames:R,overwrite:0})},u.set=function(E,P){return new u(E,0,P)},u.isTweening=function(E){return o.getTweensOf(E,!0).length>0};var k=function(E,P){for(var w=[],M=0,R=E._first;R;)R instanceof o?w[M++]=R:(P&&(w[M++]=R),w=w.concat(k(R,P)),M=w.length),R=R._next;return w},I=u.getAllTweens=function(E){return k(x._rootTimeline,E).concat(k(x._rootFramesTimeline,E))};u.killAll=function(E,P,w,M){P==null&&(P=!0),w==null&&(w=!0);var R,C,U,F=I(M!=0),X=F.length,K=P&&w&&M;for(U=0;X>U;U++)C=F[U],(K||C instanceof a||(R=C.target===C.vars.onComplete)&&w||P&&!R)&&(E?C.totalTime(C._reversed?0:C.totalDuration()):C._enabled(!1,!1))},u.killChildTweensOf=function(E,P){if(E!=null){var w,M,R,C,U,F=g.tweenLookup;if(typeof E=="string"&&(E=o.selector(E)||E),v(E)&&(E=c(E)),S(E))for(C=E.length;--C>-1;)u.killChildTweensOf(E[C],P);else{w=[];for(R in F)for(M=F[R].target.parentNode;M;)M===E&&(w=w.concat(F[R].tweens)),M=M.parentNode;for(U=w.length,C=0;U>C;C++)P&&w[C].totalTime(w[C].totalDuration()),w[C]._enabled(!1,!1)}}};var N=function(E,P,w,M){P=P!==!1,w=w!==!1,M=M!==!1;for(var R,C,U=I(M),F=P&&w&&M,X=U.length;--X>-1;)C=U[X],(F||C instanceof a||(R=C.target===C.vars.onComplete)&&w||P&&!R)&&C.paused(E)};return u.pauseAll=function(E,P,w){N(!0,E,P,w)},u.resumeAll=function(E,P,w){N(!1,E,P,w)},u.globalTimeScale=function(E){var P=x._rootTimeline,w=o.ticker.time;return arguments.length?(E=E||m,P._startTime=w-(w-P._startTime)*P._timeScale/E,P=x._rootFramesTimeline,w=o.ticker.frame,P._startTime=w-(w-P._startTime)*P._timeScale/E,P._timeScale=x._rootTimeline._timeScale=E,E):P._timeScale},b.progress=function(E,P){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&1&this._cycle?1-E:E)+this._cycle*(this._duration+this._repeatDelay),P):this._time/this.duration()},b.totalProgress=function(E,P){return arguments.length?this.totalTime(this.totalDuration()*E,P):this._totalTime/this.totalDuration()},b.time=function(E,P){return arguments.length?(this._dirty&&this.totalDuration(),E>this._duration&&(E=this._duration),this._yoyo&&1&this._cycle?E=this._duration-E+this._cycle*(this._duration+this._repeatDelay):this._repeat!==0&&(E+=this._cycle*(this._duration+this._repeatDelay)),this.totalTime(E,P)):this._time},b.duration=function(E){return arguments.length?x.prototype.duration.call(this,E):this._duration},b.totalDuration=function(E){return arguments.length?this._repeat===-1?this:this.duration((E-this._repeat*this._repeatDelay)/(this._repeat+1)):(this._dirty&&(this._totalDuration=this._repeat===-1?999999999999:this._duration*(this._repeat+1)+this._repeatDelay*this._repeat,this._dirty=!1),this._totalDuration)},b.repeat=function(E){return arguments.length?(this._repeat=E,this._uncache(!0)):this._repeat},b.repeatDelay=function(E){return arguments.length?(this._repeatDelay=E,this._uncache(!0)):this._repeatDelay},b.yoyo=function(E){return arguments.length?(this._yoyo=E,this):this._yoyo},u},!0),ln._gsDefine("TimelineLite",["core.Animation","core.SimpleTimeline","TweenLite"],function(x,a,o){var c=function(w){a.call(this,w),this._labels={},this.autoRemoveChildren=this.vars.autoRemoveChildren===!0,this.smoothChildTiming=this.vars.smoothChildTiming===!0,this._sortChildren=!0,this._onUpdate=this.vars.onUpdate;var M,R,C=this.vars;for(R in C)M=C[R],v(M)&&M.join("").indexOf("{self}")!==-1&&(C[R]=this._swapSelfInParams(M));v(C.tweens)&&this.add(C.tweens,0,C.align,C.stagger)},f=1e-10,u=o._internals,m=c._internals={},g=u.isSelector,v=u.isArray,S=u.lazyTweens,b=u.lazyRender,O=ln._gsDefine.globals,k=function(w){var M,R={};for(M in w)R[M]=w[M];return R},I=function(w,M,R){var C,U,F=w.cycle;for(C in F)U=F[C],w[C]=typeof U=="function"?U(R,M[R]):U[R%U.length];delete w.cycle},N=m.pauseCallback=function(){},E=function(w){var M,R=[],C=w.length;for(M=0;M!==C;R.push(w[M++]));return R},P=c.prototype=new a;return c.version="2.0.2",P.constructor=c,P.kill()._gc=P._forcingPlayhead=P._hasPause=!1,P.to=function(w,M,R,C){var U=R.repeat&&O.TweenMax||o;return M?this.add(new U(w,M,R),C):this.set(w,R,C)},P.from=function(w,M,R,C){return this.add((R.repeat&&O.TweenMax||o).from(w,M,R),C)},P.fromTo=function(w,M,R,C,U){var F=C.repeat&&O.TweenMax||o;return M?this.add(F.fromTo(w,M,R,C),U):this.set(w,C,U)},P.staggerTo=function(w,M,R,C,U,F,X,K){var Z,ct,Rt=new c({onComplete:F,onCompleteParams:X,callbackScope:K,smoothChildTiming:this.smoothChildTiming}),tt=R.cycle;for(typeof w=="string"&&(w=o.selector(w)||w),w=w||[],g(w)&&(w=E(w)),C=C||0,0>C&&(w=E(w),w.reverse(),C*=-1),ct=0;ct<w.length;ct++)Z=k(R),Z.startAt&&(Z.startAt=k(Z.startAt),Z.startAt.cycle&&I(Z.startAt,w,ct)),tt&&(I(Z,w,ct),Z.duration!=null&&(M=Z.duration,delete Z.duration)),Rt.to(w[ct],M,Z,ct*C);return this.add(Rt,U)},P.staggerFrom=function(w,M,R,C,U,F,X,K){return R.immediateRender=R.immediateRender!=0,R.runBackwards=!0,this.staggerTo(w,M,R,C,U,F,X,K)},P.staggerFromTo=function(w,M,R,C,U,F,X,K,Z){return C.startAt=R,C.immediateRender=C.immediateRender!=0&&R.immediateRender!=0,this.staggerTo(w,M,C,U,F,X,K,Z)},P.call=function(w,M,R,C){return this.add(o.delayedCall(0,w,M,R),C)},P.set=function(w,M,R){return R=this._parseTimeOrLabel(R,0,!0),M.immediateRender==null&&(M.immediateRender=R===this._time&&!this._paused),this.add(new o(w,0,M),R)},c.exportRoot=function(w,M){w=w||{},w.smoothChildTiming==null&&(w.smoothChildTiming=!0);var R,C,U,F,X=new c(w),K=X._timeline;for(M==null&&(M=!0),K._remove(X,!0),X._startTime=0,X._rawPrevTime=X._time=X._totalTime=K._time,U=K._first;U;)F=U._next,M&&U instanceof o&&U.target===U.vars.onComplete||(C=U._startTime-U._delay,0>C&&(R=1),X.add(U,C)),U=F;return K.add(X,0),R&&X.totalDuration(),X},P.add=function(w,M,R,C){var U,F,X,K,Z,ct;if(typeof M!="number"&&(M=this._parseTimeOrLabel(M,0,!0,w)),!(w instanceof x)){if(w instanceof Array||w&&w.push&&v(w)){for(R=R||"normal",C=C||0,U=M,F=w.length,X=0;F>X;X++)v(K=w[X])&&(K=new c({tweens:K})),this.add(K,U),typeof K!="string"&&typeof K!="function"&&(R==="sequence"?U=K._startTime+K.totalDuration()/K._timeScale:R==="start"&&(K._startTime-=K.delay())),U+=C;return this._uncache(!0)}if(typeof w=="string")return this.addLabel(w,M);if(typeof w!="function")throw"Cannot add "+w+" into the timeline; it is not a tween, timeline, function, or string.";w=o.delayedCall(0,w)}if(a.prototype.add.call(this,w,M),w._time&&(U=Math.max(0,Math.min(w.totalDuration(),(this.rawTime()-w._startTime)*w._timeScale)),Math.abs(U-w._totalTime)>1e-5&&w.render(U,!1,!1)),(this._gc||this._time===this._duration)&&!this._paused&&this._duration<this.duration())for(Z=this,ct=Z.rawTime()>w._startTime;Z._timeline;)ct&&Z._timeline.smoothChildTiming?Z.totalTime(Z._totalTime,!0):Z._gc&&Z._enabled(!0,!1),Z=Z._timeline;return this},P.remove=function(w){if(w instanceof x){this._remove(w,!1);var M=w._timeline=w.vars.useFrames?x._rootFramesTimeline:x._rootTimeline;return w._startTime=(w._paused?w._pauseTime:M._time)-(w._reversed?w.totalDuration()-w._totalTime:w._totalTime)/w._timeScale,this}if(w instanceof Array||w&&w.push&&v(w)){for(var R=w.length;--R>-1;)this.remove(w[R]);return this}return typeof w=="string"?this.removeLabel(w):this.kill(null,w)},P._remove=function(w,M){a.prototype._remove.call(this,w,M);var R=this._last;return R?this._time>this.duration()&&(this._time=this._duration,this._totalTime=this._totalDuration):this._time=this._totalTime=this._duration=this._totalDuration=0,this},P.append=function(w,M){return this.add(w,this._parseTimeOrLabel(null,M,!0,w))},P.insert=P.insertMultiple=function(w,M,R,C){return this.add(w,M||0,R,C)},P.appendMultiple=function(w,M,R,C){return this.add(w,this._parseTimeOrLabel(null,M,!0,w),R,C)},P.addLabel=function(w,M){return this._labels[w]=this._parseTimeOrLabel(M),this},P.addPause=function(w,M,R,C){var U=o.delayedCall(0,N,R,C||this);return U.vars.onComplete=U.vars.onReverseComplete=M,U.data="isPause",this._hasPause=!0,this.add(U,w)},P.removeLabel=function(w){return delete this._labels[w],this},P.getLabelTime=function(w){return this._labels[w]!=null?this._labels[w]:-1},P._parseTimeOrLabel=function(w,M,R,C){var U,F;if(C instanceof x&&C.timeline===this)this.remove(C);else if(C&&(C instanceof Array||C.push&&v(C)))for(F=C.length;--F>-1;)C[F]instanceof x&&C[F].timeline===this&&this.remove(C[F]);if(U=typeof w!="number"||M?this.duration()>99999999999?this.recent().endTime(!1):this._duration:0,typeof M=="string")return this._parseTimeOrLabel(M,R&&typeof w=="number"&&this._labels[M]==null?w-U:0,R);if(M=M||0,typeof w!="string"||!isNaN(w)&&this._labels[w]==null)w==null&&(w=U);else{if(F=w.indexOf("="),F===-1)return this._labels[w]==null?R?this._labels[w]=U+M:M:this._labels[w]+M;M=parseInt(w.charAt(F-1)+"1",10)*Number(w.substr(F+1)),w=F>1?this._parseTimeOrLabel(w.substr(0,F-1),0,R):U}return Number(w)+M},P.seek=function(w,M){return this.totalTime(typeof w=="number"?w:this._parseTimeOrLabel(w),M!==!1)},P.stop=function(){return this.paused(!0)},P.gotoAndPlay=function(w,M){return this.play(w,M)},P.gotoAndStop=function(w,M){return this.pause(w,M)},P.render=function(w,M,R){this._gc&&this._enabled(!0,!1);var C,U,F,X,K,Z,ct,Rt=this._time,tt=this._dirty?this.totalDuration():this._totalDuration,_t=this._startTime,G=this._timeScale,Pt=this._paused;if(Rt!==this._time&&(w+=this._time-Rt),w>=tt-1e-7&&w>=0)this._totalTime=this._time=tt,this._reversed||this._hasPausedChild()||(U=!0,X="onComplete",K=!!this._timeline.autoRemoveChildren,this._duration===0&&(0>=w&&w>=-1e-7||this._rawPrevTime<0||this._rawPrevTime===f)&&this._rawPrevTime!==w&&this._first&&(K=!0,this._rawPrevTime>f&&(X="onReverseComplete"))),this._rawPrevTime=this._duration||!M||w||this._rawPrevTime===w?w:f,w=tt+1e-4;else if(1e-7>w)if(this._totalTime=this._time=0,(Rt!==0||this._duration===0&&this._rawPrevTime!==f&&(this._rawPrevTime>0||0>w&&this._rawPrevTime>=0))&&(X="onReverseComplete",U=this._reversed),0>w)this._active=!1,this._timeline.autoRemoveChildren&&this._reversed?(K=U=!0,X="onReverseComplete"):this._rawPrevTime>=0&&this._first&&(K=!0),this._rawPrevTime=w;else{if(this._rawPrevTime=this._duration||!M||w||this._rawPrevTime===w?w:f,w===0&&U)for(C=this._first;C&&C._startTime===0;)C._duration||(U=!1),C=C._next;w=0,this._initted||(K=!0)}else{if(this._hasPause&&!this._forcingPlayhead&&!M){if(w>=Rt)for(C=this._first;C&&C._startTime<=w&&!Z;)C._duration||C.data!=="isPause"||C.ratio||C._startTime===0&&this._rawPrevTime===0||(Z=C),C=C._next;else for(C=this._last;C&&C._startTime>=w&&!Z;)C._duration||C.data==="isPause"&&C._rawPrevTime>0&&(Z=C),C=C._prev;Z&&(this._time=w=Z._startTime,this._totalTime=w+this._cycle*(this._totalDuration+this._repeatDelay))}this._totalTime=this._time=this._rawPrevTime=w}if(this._time!==Rt&&this._first||R||K||Z){if(this._initted||(this._initted=!0),this._active||!this._paused&&this._time!==Rt&&w>0&&(this._active=!0),Rt===0&&this.vars.onStart&&(this._time===0&&this._duration||M||this._callback("onStart")),ct=this._time,ct>=Rt)for(C=this._first;C&&(F=C._next,ct===this._time&&(!this._paused||Pt));)(C._active||C._startTime<=ct&&!C._paused&&!C._gc)&&(Z===C&&this.pause(),C._reversed?C.render((C._dirty?C.totalDuration():C._totalDuration)-(w-C._startTime)*C._timeScale,M,R):C.render((w-C._startTime)*C._timeScale,M,R)),C=F;else for(C=this._last;C&&(F=C._prev,ct===this._time&&(!this._paused||Pt));){if(C._active||C._startTime<=Rt&&!C._paused&&!C._gc){if(Z===C){for(Z=C._prev;Z&&Z.endTime()>this._time;)Z.render(Z._reversed?Z.totalDuration()-(w-Z._startTime)*Z._timeScale:(w-Z._startTime)*Z._timeScale,M,R),Z=Z._prev;Z=null,this.pause()}C._reversed?C.render((C._dirty?C.totalDuration():C._totalDuration)-(w-C._startTime)*C._timeScale,M,R):C.render((w-C._startTime)*C._timeScale,M,R)}C=F}this._onUpdate&&(M||(S.length&&b(),this._callback("onUpdate"))),X&&(this._gc||(_t===this._startTime||G!==this._timeScale)&&(this._time===0||tt>=this.totalDuration())&&(U&&(S.length&&b(),this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!M&&this.vars[X]&&this._callback(X)))}},P._hasPausedChild=function(){for(var w=this._first;w;){if(w._paused||w instanceof c&&w._hasPausedChild())return!0;w=w._next}return!1},P.getChildren=function(w,M,R,C){C=C||-9999999999;for(var U=[],F=this._first,X=0;F;)F._startTime<C||(F instanceof o?M!==!1&&(U[X++]=F):(R!==!1&&(U[X++]=F),w!==!1&&(U=U.concat(F.getChildren(!0,M,R)),X=U.length))),F=F._next;return U},P.getTweensOf=function(w,M){var R,C,U=this._gc,F=[],X=0;for(U&&this._enabled(!0,!0),R=o.getTweensOf(w),C=R.length;--C>-1;)(R[C].timeline===this||M&&this._contains(R[C]))&&(F[X++]=R[C]);return U&&this._enabled(!1,!0),F},P.recent=function(){return this._recent},P._contains=function(w){for(var M=w.timeline;M;){if(M===this)return!0;M=M.timeline}return!1},P.shiftChildren=function(w,M,R){R=R||0;for(var C,U=this._first,F=this._labels;U;)U._startTime>=R&&(U._startTime+=w),U=U._next;if(M)for(C in F)F[C]>=R&&(F[C]+=w);return this._uncache(!0)},P._kill=function(w,M){if(!w&&!M)return this._enabled(!1,!1);for(var R=M?this.getTweensOf(M):this.getChildren(!0,!0,!1),C=R.length,U=!1;--C>-1;)R[C]._kill(w,M)&&(U=!0);return U},P.clear=function(w){var M=this.getChildren(!1,!0,!0),R=M.length;for(this._time=this._totalTime=0;--R>-1;)M[R]._enabled(!1,!1);return w!==!1&&(this._labels={}),this._uncache(!0)},P.invalidate=function(){for(var w=this._first;w;)w.invalidate(),w=w._next;return x.prototype.invalidate.call(this)},P._enabled=function(w,M){if(w===this._gc)for(var R=this._first;R;)R._enabled(w,!0),R=R._next;return a.prototype._enabled.call(this,w,M)},P.totalTime=function(w,M,R){this._forcingPlayhead=!0;var C=x.prototype.totalTime.apply(this,arguments);return this._forcingPlayhead=!1,C},P.duration=function(w){return arguments.length?(this.duration()!==0&&w!==0&&this.timeScale(this._duration/w),this):(this._dirty&&this.totalDuration(),this._duration)},P.totalDuration=function(w){if(!arguments.length){if(this._dirty){for(var M,R,C=0,U=this._last,F=999999999999;U;)M=U._prev,U._dirty&&U.totalDuration(),U._startTime>F&&this._sortChildren&&!U._paused&&!this._calculatingDuration?(this._calculatingDuration=1,this.add(U,U._startTime-U._delay),this._calculatingDuration=0):F=U._startTime,U._startTime<0&&!U._paused&&(C-=U._startTime,this._timeline.smoothChildTiming&&(this._startTime+=U._startTime/this._timeScale,this._time-=U._startTime,this._totalTime-=U._startTime,this._rawPrevTime-=U._startTime),this.shiftChildren(-U._startTime,!1,-9999999999),F=0),R=U._startTime+U._totalDuration/U._timeScale,R>C&&(C=R),U=M;this._duration=this._totalDuration=C,this._dirty=!1}return this._totalDuration}return w&&this.totalDuration()?this.timeScale(this._totalDuration/w):this},P.paused=function(w){if(!w)for(var M=this._first,R=this._time;M;)M._startTime===R&&M.data==="isPause"&&(M._rawPrevTime=0),M=M._next;return x.prototype.paused.apply(this,arguments)},P.usesFrames=function(){for(var w=this._timeline;w._timeline;)w=w._timeline;return w===x._rootFramesTimeline},P.rawTime=function(w){return w&&(this._paused||this._repeat&&this.time()>0&&this.totalProgress()<1)?this._totalTime%(this._duration+this._repeatDelay):this._paused?this._totalTime:(this._timeline.rawTime(w)-this._startTime)*this._timeScale},c},!0),ln._gsDefine("TimelineMax",["TimelineLite","TweenLite","easing.Ease"],function(x,a,o){var c=function(O){x.call(this,O),this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._cycle=0,this._yoyo=this.vars.yoyo===!0,this._dirty=!0},f=1e-10,u=a._internals,m=u.lazyTweens,g=u.lazyRender,v=ln._gsDefine.globals,S=new o(null,null,1,0),b=c.prototype=new x;return b.constructor=c,b.kill()._gc=!1,c.version="2.0.2",b.invalidate=function(){return this._yoyo=this.vars.yoyo===!0,this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._uncache(!0),x.prototype.invalidate.call(this)},b.addCallback=function(O,k,I,N){return this.add(a.delayedCall(0,O,I,N),k)},b.removeCallback=function(O,k){if(O)if(k==null)this._kill(null,O);else for(var I=this.getTweensOf(O,!1),N=I.length,E=this._parseTimeOrLabel(k);--N>-1;)I[N]._startTime===E&&I[N]._enabled(!1,!1);return this},b.removePause=function(O){return this.removeCallback(x._internals.pauseCallback,O)},b.tweenTo=function(O,k){k=k||{};var I,N,E,P={ease:S,useFrames:this.usesFrames(),immediateRender:!1,lazy:!1},w=k.repeat&&v.TweenMax||a;for(N in k)P[N]=k[N];return P.time=this._parseTimeOrLabel(O),I=Math.abs(Number(P.time)-this._time)/this._timeScale||.001,E=new w(this,I,P),P.onStart=function(){E.target.paused(!0),E.vars.time===E.target.time()||I!==E.duration()||E.isFromTo||E.duration(Math.abs(E.vars.time-E.target.time())/E.target._timeScale).render(E.time(),!0,!0),k.onStart&&k.onStart.apply(k.onStartScope||k.callbackScope||E,k.onStartParams||[])},E},b.tweenFromTo=function(O,k,I){I=I||{},O=this._parseTimeOrLabel(O),I.startAt={onComplete:this.seek,onCompleteParams:[O],callbackScope:this},I.immediateRender=I.immediateRender!==!1;var N=this.tweenTo(k,I);return N.isFromTo=1,N.duration(Math.abs(N.vars.time-O)/this._timeScale||.001)},b.render=function(O,k,I){this._gc&&this._enabled(!0,!1);var N,E,P,w,M,R,C,U,F=this._time,X=this._dirty?this.totalDuration():this._totalDuration,K=this._duration,Z=this._totalTime,ct=this._startTime,Rt=this._timeScale,tt=this._rawPrevTime,_t=this._paused,G=this._cycle;if(F!==this._time&&(O+=this._time-F),O>=X-1e-7&&O>=0)this._locked||(this._totalTime=X,this._cycle=this._repeat),this._reversed||this._hasPausedChild()||(E=!0,w="onComplete",M=!!this._timeline.autoRemoveChildren,this._duration===0&&(0>=O&&O>=-1e-7||0>tt||tt===f)&&tt!==O&&this._first&&(M=!0,tt>f&&(w="onReverseComplete"))),this._rawPrevTime=this._duration||!k||O||this._rawPrevTime===O?O:f,this._yoyo&&1&this._cycle?this._time=O=0:(this._time=K,O=K+1e-4);else if(1e-7>O)if(this._locked||(this._totalTime=this._cycle=0),this._time=0,(F!==0||K===0&&tt!==f&&(tt>0||0>O&&tt>=0)&&!this._locked)&&(w="onReverseComplete",E=this._reversed),0>O)this._active=!1,this._timeline.autoRemoveChildren&&this._reversed?(M=E=!0,w="onReverseComplete"):tt>=0&&this._first&&(M=!0),this._rawPrevTime=O;else{if(this._rawPrevTime=K||!k||O||this._rawPrevTime===O?O:f,O===0&&E)for(N=this._first;N&&N._startTime===0;)N._duration||(E=!1),N=N._next;O=0,this._initted||(M=!0)}else if(K===0&&0>tt&&(M=!0),this._time=this._rawPrevTime=O,this._locked||(this._totalTime=O,this._repeat!==0&&(R=K+this._repeatDelay,this._cycle=this._totalTime/R>>0,this._cycle!==0&&this._cycle===this._totalTime/R&&O>=Z&&this._cycle--,this._time=this._totalTime-this._cycle*R,this._yoyo&&1&this._cycle&&(this._time=K-this._time),this._time>K?(this._time=K,O=K+1e-4):this._time<0?this._time=O=0:O=this._time)),this._hasPause&&!this._forcingPlayhead&&!k){if(O=this._time,O>=F||this._repeat&&G!==this._cycle)for(N=this._first;N&&N._startTime<=O&&!C;)N._duration||N.data!=="isPause"||N.ratio||N._startTime===0&&this._rawPrevTime===0||(C=N),N=N._next;else for(N=this._last;N&&N._startTime>=O&&!C;)N._duration||N.data==="isPause"&&N._rawPrevTime>0&&(C=N),N=N._prev;C&&C._startTime<K&&(this._time=O=C._startTime,this._totalTime=O+this._cycle*(this._totalDuration+this._repeatDelay))}if(this._cycle!==G&&!this._locked){var Pt=this._yoyo&&(1&G)!==0,Et=Pt===(this._yoyo&&(1&this._cycle)!==0),At=this._totalTime,ce=this._cycle,re=this._rawPrevTime,Ft=this._time;if(this._totalTime=G*K,this._cycle<G?Pt=!Pt:this._totalTime+=K,this._time=F,this._rawPrevTime=K===0?tt-1e-4:tt,this._cycle=G,this._locked=!0,F=Pt?0:K,this.render(F,k,K===0),k||this._gc||this.vars.onRepeat&&(this._cycle=ce,this._locked=!1,this._callback("onRepeat")),F!==this._time||(Et&&(this._cycle=G,this._locked=!0,F=Pt?K+1e-4:-1e-4,this.render(F,!0,!1)),this._locked=!1,this._paused&&!_t))return;this._time=Ft,this._totalTime=At,this._cycle=ce,this._rawPrevTime=re}if(!(this._time!==F&&this._first||I||M||C))return void(Z!==this._totalTime&&this._onUpdate&&(k||this._callback("onUpdate")));if(this._initted||(this._initted=!0),this._active||!this._paused&&this._totalTime!==Z&&O>0&&(this._active=!0),Z===0&&this.vars.onStart&&(this._totalTime===0&&this._totalDuration||k||this._callback("onStart")),U=this._time,U>=F)for(N=this._first;N&&(P=N._next,U===this._time&&(!this._paused||_t));)(N._active||N._startTime<=this._time&&!N._paused&&!N._gc)&&(C===N&&this.pause(),N._reversed?N.render((N._dirty?N.totalDuration():N._totalDuration)-(O-N._startTime)*N._timeScale,k,I):N.render((O-N._startTime)*N._timeScale,k,I)),N=P;else for(N=this._last;N&&(P=N._prev,U===this._time&&(!this._paused||_t));){if(N._active||N._startTime<=F&&!N._paused&&!N._gc){if(C===N){for(C=N._prev;C&&C.endTime()>this._time;)C.render(C._reversed?C.totalDuration()-(O-C._startTime)*C._timeScale:(O-C._startTime)*C._timeScale,k,I),C=C._prev;C=null,this.pause()}N._reversed?N.render((N._dirty?N.totalDuration():N._totalDuration)-(O-N._startTime)*N._timeScale,k,I):N.render((O-N._startTime)*N._timeScale,k,I)}N=P}this._onUpdate&&(k||(m.length&&g(),this._callback("onUpdate"))),w&&(this._locked||this._gc||(ct===this._startTime||Rt!==this._timeScale)&&(this._time===0||X>=this.totalDuration())&&(E&&(m.length&&g(),this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!k&&this.vars[w]&&this._callback(w)))},b.getActive=function(O,k,I){O==null&&(O=!0),k==null&&(k=!0),I==null&&(I=!1);var N,E,P=[],w=this.getChildren(O,k,I),M=0,R=w.length;for(N=0;R>N;N++)E=w[N],E.isActive()&&(P[M++]=E);return P},b.getLabelAfter=function(O){O||O!==0&&(O=this._time);var k,I=this.getLabelsArray(),N=I.length;for(k=0;N>k;k++)if(I[k].time>O)return I[k].name;return null},b.getLabelBefore=function(O){O==null&&(O=this._time);for(var k=this.getLabelsArray(),I=k.length;--I>-1;)if(k[I].time<O)return k[I].name;return null},b.getLabelsArray=function(){var O,k=[],I=0;for(O in this._labels)k[I++]={time:this._labels[O],name:O};return k.sort(function(N,E){return N.time-E.time}),k},b.invalidate=function(){return this._locked=!1,x.prototype.invalidate.call(this)},b.progress=function(O,k){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&1&this._cycle?1-O:O)+this._cycle*(this._duration+this._repeatDelay),k):this._time/this.duration()||0},b.totalProgress=function(O,k){return arguments.length?this.totalTime(this.totalDuration()*O,k):this._totalTime/this.totalDuration()||0},b.totalDuration=function(O){return arguments.length?this._repeat!==-1&&O?this.timeScale(this.totalDuration()/O):this:(this._dirty&&(x.prototype.totalDuration.call(this),this._totalDuration=this._repeat===-1?999999999999:this._duration*(this._repeat+1)+this._repeatDelay*this._repeat),this._totalDuration)},b.time=function(O,k){return arguments.length?(this._dirty&&this.totalDuration(),O>this._duration&&(O=this._duration),this._yoyo&&1&this._cycle?O=this._duration-O+this._cycle*(this._duration+this._repeatDelay):this._repeat!==0&&(O+=this._cycle*(this._duration+this._repeatDelay)),this.totalTime(O,k)):this._time},b.repeat=function(O){return arguments.length?(this._repeat=O,this._uncache(!0)):this._repeat},b.repeatDelay=function(O){return arguments.length?(this._repeatDelay=O,this._uncache(!0)):this._repeatDelay},b.yoyo=function(O){return arguments.length?(this._yoyo=O,this):this._yoyo},b.currentLabel=function(O){return arguments.length?this.seek(O,!0):this.getLabelBefore(this._time+1e-8)},c},!0),function(){var x=180/Math.PI,a=[],o=[],c=[],f={},u=ln._gsDefine.globals,m=function(w,M,R,C){R===C&&(R=C-(C-M)/1e6),w===M&&(M=w+(R-w)/1e6),this.a=w,this.b=M,this.c=R,this.d=C,this.da=C-w,this.ca=R-w,this.ba=M-w},g=",x,y,z,left,top,right,bottom,marginTop,marginLeft,marginRight,marginBottom,paddingLeft,paddingTop,paddingRight,paddingBottom,backgroundPosition,backgroundPosition_y,",v=function(w,M,R,C){var U={a:w},F={},X={},K={c:C},Z=(w+M)/2,ct=(M+R)/2,Rt=(R+C)/2,tt=(Z+ct)/2,_t=(ct+Rt)/2,G=(_t-tt)/8;return U.b=Z+(w-Z)/4,F.b=tt+G,U.c=F.a=(U.b+F.b)/2,F.c=X.a=(tt+_t)/2,X.b=_t-G,K.b=Rt+(C-Rt)/4,X.c=K.a=(X.b+K.b)/2,[U,F,X,K]},S=function(w,M,R,C,U){var F,X,K,Z,ct,Rt,tt,_t,G,Pt,Et,At,ce,re=w.length-1,Ft=0,It=w[0].a;for(F=0;re>F;F++)ct=w[Ft],X=ct.a,K=ct.d,Z=w[Ft+1].d,U?(Et=a[F],At=o[F],ce=(At+Et)*M*.25/(C?.5:c[F]||.5),Rt=K-(K-X)*(C?.5*M:Et!==0?ce/Et:0),tt=K+(Z-K)*(C?.5*M:At!==0?ce/At:0),_t=K-(Rt+((tt-Rt)*(3*Et/(Et+At)+.5)/4||0))):(Rt=K-(K-X)*M*.5,tt=K+(Z-K)*M*.5,_t=K-(Rt+tt)/2),Rt+=_t,tt+=_t,ct.c=G=Rt,F!==0?ct.b=It:ct.b=It=ct.a+.6*(ct.c-ct.a),ct.da=K-X,ct.ca=G-X,ct.ba=It-X,R?(Pt=v(X,It,G,K),w.splice(Ft,1,Pt[0],Pt[1],Pt[2],Pt[3]),Ft+=4):Ft++,It=tt;ct=w[Ft],ct.b=It,ct.c=It+.4*(ct.d-It),ct.da=ct.d-ct.a,ct.ca=ct.c-ct.a,ct.ba=It-ct.a,R&&(Pt=v(ct.a,It,ct.c,ct.d),w.splice(Ft,1,Pt[0],Pt[1],Pt[2],Pt[3]))},b=function(w,M,R,C){var U,F,X,K,Z,ct,Rt=[];if(C)for(w=[C].concat(w),F=w.length;--F>-1;)typeof(ct=w[F][M])=="string"&&ct.charAt(1)==="="&&(w[F][M]=C[M]+Number(ct.charAt(0)+ct.substr(2)));if(U=w.length-2,0>U)return Rt[0]=new m(w[0][M],0,0,w[0][M]),Rt;for(F=0;U>F;F++)X=w[F][M],K=w[F+1][M],Rt[F]=new m(X,0,0,K),R&&(Z=w[F+2][M],a[F]=(a[F]||0)+(K-X)*(K-X),o[F]=(o[F]||0)+(Z-K)*(Z-K));return Rt[F]=new m(w[F][M],0,0,w[F+1][M]),Rt},O=function(w,M,R,C,U,F){var X,K,Z,ct,Rt,tt,_t,G,Pt={},Et=[],At=F||w[0];U=typeof U=="string"?","+U+",":g,M==null&&(M=1);for(K in w[0])Et.push(K);if(w.length>1){for(G=w[w.length-1],_t=!0,X=Et.length;--X>-1;)if(K=Et[X],Math.abs(At[K]-G[K])>.05){_t=!1;break}_t&&(w=w.concat(),F&&w.unshift(F),w.push(w[1]),F=w[w.length-3])}for(a.length=o.length=c.length=0,X=Et.length;--X>-1;)K=Et[X],f[K]=U.indexOf(","+K+",")!==-1,Pt[K]=b(w,K,f[K],F);for(X=a.length;--X>-1;)a[X]=Math.sqrt(a[X]),o[X]=Math.sqrt(o[X]);if(!C){for(X=Et.length;--X>-1;)if(f[K])for(Z=Pt[Et[X]],tt=Z.length-1,ct=0;tt>ct;ct++)Rt=Z[ct+1].da/o[ct]+Z[ct].da/a[ct]||0,c[ct]=(c[ct]||0)+Rt*Rt;for(X=c.length;--X>-1;)c[X]=Math.sqrt(c[X])}for(X=Et.length,ct=R?4:1;--X>-1;)K=Et[X],Z=Pt[K],S(Z,M,R,C,f[K]),_t&&(Z.splice(0,ct),Z.splice(Z.length-ct,ct));return Pt},k=function(w,M,R){M=M||"soft";var C,U,F,X,K,Z,ct,Rt,tt,_t,G,Pt={},Et=M==="cubic"?3:2,At=M==="soft",ce=[];if(At&&R&&(w=[R].concat(w)),w==null||w.length<Et+1)throw"invalid Bezier data";for(tt in w[0])ce.push(tt);for(Z=ce.length;--Z>-1;){for(tt=ce[Z],Pt[tt]=K=[],_t=0,Rt=w.length,ct=0;Rt>ct;ct++)C=R==null?w[ct][tt]:typeof(G=w[ct][tt])=="string"&&G.charAt(1)==="="?R[tt]+Number(G.charAt(0)+G.substr(2)):Number(G),At&&ct>1&&Rt-1>ct&&(K[_t++]=(C+K[_t-2])/2),K[_t++]=C;for(Rt=_t-Et+1,_t=0,ct=0;Rt>ct;ct+=Et)C=K[ct],U=K[ct+1],F=K[ct+2],X=Et===2?0:K[ct+3],K[_t++]=G=Et===3?new m(C,U,F,X):new m(C,(2*U+C)/3,(2*U+F)/3,F);K.length=_t}return Pt},I=function(w,M,R){for(var C,U,F,X,K,Z,ct,Rt,tt,_t,G,Pt=1/R,Et=w.length;--Et>-1;)for(_t=w[Et],F=_t.a,X=_t.d-F,K=_t.c-F,Z=_t.b-F,C=U=0,Rt=1;R>=Rt;Rt++)ct=Pt*Rt,tt=1-ct,C=U-(U=(ct*ct*X+3*tt*(ct*K+tt*Z))*ct),G=Et*R+Rt-1,M[G]=(M[G]||0)+C*C},N=function(w,M){M=M>>0||6;var R,C,U,F,X=[],K=[],Z=0,ct=0,Rt=M-1,tt=[],_t=[];for(R in w)I(w[R],X,M);for(U=X.length,C=0;U>C;C++)Z+=Math.sqrt(X[C]),F=C%M,_t[F]=Z,F===Rt&&(ct+=Z,F=C/M>>0,tt[F]=_t,K[F]=ct,Z=0,_t=[]);return{length:ct,lengths:K,segments:tt}},E=ln._gsDefine.plugin({propName:"bezier",priority:-1,version:"1.3.8",API:2,global:!0,init:function(w,M,R){this._target=w,M instanceof Array&&(M={values:M}),this._func={},this._mod={},this._props=[],this._timeRes=M.timeResolution==null?6:parseInt(M.timeResolution,10);var C,U,F,X,K,Z=M.values||[],ct={},Rt=Z[0],tt=M.autoRotate||R.vars.orientToBezier;this._autoRotate=tt?tt instanceof Array?tt:[["x","y","rotation",tt===!0?0:Number(tt)||0]]:null;for(C in Rt)this._props.push(C);for(F=this._props.length;--F>-1;)C=this._props[F],this._overwriteProps.push(C),U=this._func[C]=typeof w[C]=="function",ct[C]=U?w[C.indexOf("set")||typeof w["get"+C.substr(3)]!="function"?C:"get"+C.substr(3)]():parseFloat(w[C]),K||ct[C]!==Z[0][C]&&(K=ct);if(this._beziers=M.type!=="cubic"&&M.type!=="quadratic"&&M.type!=="soft"?O(Z,isNaN(M.curviness)?1:M.curviness,!1,M.type==="thruBasic",M.correlate,K):k(Z,M.type,ct),this._segCount=this._beziers[C].length,this._timeRes){var _t=N(this._beziers,this._timeRes);this._length=_t.length,this._lengths=_t.lengths,this._segments=_t.segments,this._l1=this._li=this._s1=this._si=0,this._l2=this._lengths[0],this._curSeg=this._segments[0],this._s2=this._curSeg[0],this._prec=1/this._curSeg.length}if(tt=this._autoRotate)for(this._initialRotations=[],tt[0]instanceof Array||(this._autoRotate=tt=[tt]),F=tt.length;--F>-1;){for(X=0;3>X;X++)C=tt[F][X],this._func[C]=typeof w[C]=="function"?w[C.indexOf("set")||typeof w["get"+C.substr(3)]!="function"?C:"get"+C.substr(3)]:!1;C=tt[F][2],this._initialRotations[F]=(this._func[C]?this._func[C].call(this._target):this._target[C])||0,this._overwriteProps.push(C)}return this._startRatio=R.vars.runBackwards?1:0,!0},set:function(w){var M,R,C,U,F,X,K,Z,ct,Rt,tt=this._segCount,_t=this._func,G=this._target,Pt=w!==this._startRatio;if(this._timeRes){if(ct=this._lengths,Rt=this._curSeg,w*=this._length,C=this._li,w>this._l2&&tt-1>C){for(Z=tt-1;Z>C&&(this._l2=ct[++C])<=w;);this._l1=ct[C-1],this._li=C,this._curSeg=Rt=this._segments[C],this._s2=Rt[this._s1=this._si=0]}else if(w<this._l1&&C>0){for(;C>0&&(this._l1=ct[--C])>=w;);C===0&&w<this._l1?this._l1=0:C++,this._l2=ct[C],this._li=C,this._curSeg=Rt=this._segments[C],this._s1=Rt[(this._si=Rt.length-1)-1]||0,this._s2=Rt[this._si]}if(M=C,w-=this._l1,C=this._si,w>this._s2&&C<Rt.length-1){for(Z=Rt.length-1;Z>C&&(this._s2=Rt[++C])<=w;);this._s1=Rt[C-1],this._si=C}else if(w<this._s1&&C>0){for(;C>0&&(this._s1=Rt[--C])>=w;);C===0&&w<this._s1?this._s1=0:C++,this._s2=Rt[C],this._si=C}X=(C+(w-this._s1)/(this._s2-this._s1))*this._prec||0}else M=0>w?0:w>=1?tt-1:tt*w>>0,X=(w-M*(1/tt))*tt;for(R=1-X,C=this._props.length;--C>-1;)U=this._props[C],F=this._beziers[U][M],K=(X*X*F.da+3*R*(X*F.ca+R*F.ba))*X+F.a,this._mod[U]&&(K=this._mod[U](K,G)),_t[U]?G[U](K):G[U]=K;if(this._autoRotate){var Et,At,ce,re,Ft,It,Nt,Pe=this._autoRotate;for(C=Pe.length;--C>-1;)U=Pe[C][2],It=Pe[C][3]||0,Nt=Pe[C][4]===!0?1:x,F=this._beziers[Pe[C][0]],Et=this._beziers[Pe[C][1]],F&&Et&&(F=F[M],Et=Et[M],At=F.a+(F.b-F.a)*X,re=F.b+(F.c-F.b)*X,At+=(re-At)*X,re+=(F.c+(F.d-F.c)*X-re)*X,ce=Et.a+(Et.b-Et.a)*X,Ft=Et.b+(Et.c-Et.b)*X,ce+=(Ft-ce)*X,Ft+=(Et.c+(Et.d-Et.c)*X-Ft)*X,K=Pt?Math.atan2(Ft-ce,re-At)*Nt+It:this._initialRotations[C],this._mod[U]&&(K=this._mod[U](K,G)),_t[U]?G[U](K):G[U]=K)}}}),P=E.prototype;E.bezierThrough=O,E.cubicToQuadratic=v,E._autoCSS=!0,E.quadraticToCubic=function(w,M,R){return new m(w,(2*M+w)/3,(2*M+R)/3,R)},E._cssRegister=function(){var w=u.CSSPlugin;if(w){var M=w._internals,R=M._parseToProxy,C=M._setPluginRatio,U=M.CSSPropTween;M._registerComplexSpecialProp("bezier",{parser:function(F,X,K,Z,ct,Rt){X instanceof Array&&(X={values:X}),Rt=new E;var tt,_t,G,Pt=X.values,Et=Pt.length-1,At=[],ce={};if(0>Et)return ct;for(tt=0;Et>=tt;tt++)G=R(F,Pt[tt],Z,ct,Rt,Et!==tt),At[tt]=G.end;for(_t in X)ce[_t]=X[_t];return ce.values=At,ct=new U(F,"bezier",0,0,G.pt,2),ct.data=G,ct.plugin=Rt,ct.setRatio=C,ce.autoRotate===0&&(ce.autoRotate=!0),!ce.autoRotate||ce.autoRotate instanceof Array||(tt=ce.autoRotate===!0?0:Number(ce.autoRotate),ce.autoRotate=G.end.left!=null?[["left","top","rotation",tt,!1]]:G.end.x!=null?[["x","y","rotation",tt,!1]]:!1),ce.autoRotate&&(Z._transform||Z._enableTransforms(!1),G.autoRotate=Z._target._gsTransform,G.proxy.rotation=G.autoRotate.rotation||0,Z._overwriteProps.push("rotation")),Rt._onInitTween(G.proxy,ce,Z._tween),ct}})}},P._mod=function(w){for(var M,R=this._overwriteProps,C=R.length;--C>-1;)M=w[R[C]],M&&typeof M=="function"&&(this._mod[R[C]]=M)},P._kill=function(w){var M,R,C=this._props;for(M in this._beziers)if(M in w)for(delete this._beziers[M],delete this._func[M],R=C.length;--R>-1;)C[R]===M&&C.splice(R,1);if(C=this._autoRotate)for(R=C.length;--R>-1;)w[C[R][2]]&&C.splice(R,1);return this._super._kill.call(this,w)}}(),ln._gsDefine("plugins.CSSPlugin",["plugins.TweenPlugin","TweenLite"],function(x,a){var o,c,f,u,m=function(){x.call(this,"css"),this._overwriteProps.length=0,this.setRatio=m.prototype.setRatio},g=ln._gsDefine.globals,v={},S=m.prototype=new x("css");S.constructor=m,m.version="2.0.2",m.API=2,m.defaultTransformPerspective=0,m.defaultSkewType="compensated",m.defaultSmoothOrigin=!0,S="px",m.suffixMap={top:S,right:S,bottom:S,left:S,width:S,height:S,fontSize:S,padding:S,margin:S,perspective:S,lineHeight:""};var b,O,k,I,N,E,P,w,M=/(?:\-|\.|\b)(\d|\.|e\-)+/g,R=/(?:\d|\-\d|\.\d|\-\.\d|\+=\d|\-=\d|\+=.\d|\-=\.\d)+/g,C=/(?:\+=|\-=|\-|\b)[\d\-\.]+[a-zA-Z0-9]*(?:%|\b)/gi,U=/(?![+-]?\d*\.?\d+|[+-]|e[+-]\d+)[^0-9]/g,F=/(?:\d|\-|\+|=|#|\.)*/g,X=/opacity *= *([^)]*)/i,K=/opacity:([^;]*)/i,Z=/alpha\(opacity *=.+?\)/i,ct=/^(rgb|hsl)/,Rt=/([A-Z])/g,tt=/-([a-z])/gi,_t=/(^(?:url\(\"|url\())|(?:(\"\))$|\)$)/gi,G=function(V,et){return et.toUpperCase()},Pt=/(?:Left|Right|Width)/i,Et=/(M11|M12|M21|M22)=[\d\-\.e]+/gi,At=/progid\:DXImageTransform\.Microsoft\.Matrix\(.+?\)/i,ce=/,(?=[^\)]*(?:\(|$))/gi,re=/[\s,\(]/i,Ft=Math.PI/180,It=180/Math.PI,Nt={},Pe={style:{}},pe=ln.document||{createElement:function(){return Pe}},Wt=function(V,et){return pe.createElementNS?pe.createElementNS(et||"http://www.w3.org/1999/xhtml",V):pe.createElement(V)},$e=Wt("div"),Si=Wt("img"),Oe=m._internals={_specialProps:v},Ge=(ln.navigator||{}).userAgent||"",pi=function(){var V=Ge.indexOf("Android"),et=Wt("a");return k=Ge.indexOf("Safari")!==-1&&Ge.indexOf("Chrome")===-1&&(V===-1||parseFloat(Ge.substr(V+8,2))>3),N=k&&parseFloat(Ge.substr(Ge.indexOf("Version/")+8,2))<6,I=Ge.indexOf("Firefox")!==-1,(/MSIE ([0-9]{1,}[\.0-9]{0,})/.exec(Ge)||/Trident\/.*rv:([0-9]{1,}[\.0-9]{0,})/.exec(Ge))&&(E=parseFloat(RegExp.$1)),et?(et.style.cssText="top:1px;opacity:.55;",/^0.55/.test(et.style.opacity)):!1}(),Di=function(V){return X.test(typeof V=="string"?V:(V.currentStyle?V.currentStyle.filter:V.style.filter)||"")?parseFloat(RegExp.$1)/100:1},mn=function(V){ln.console},Qi="",W="",Jt=function(V,et){et=et||$e;var lt,at,j=et.style;if(j[V]!==void 0)return V;for(V=V.charAt(0).toUpperCase()+V.substr(1),lt=["O","Moz","ms","Ms","Webkit"],at=5;--at>-1&&j[lt[at]+V]===void 0;);return at>=0?(W=at===3?"ms":lt[at],Qi="-"+W.toLowerCase()+"-",W+V):null},jt=(typeof window<"u"?window:pe.defaultView||{getComputedStyle:function(){}}).getComputedStyle,dt=m.getStyle=function(V,et,lt,at,j){var St;return pi||et!=="opacity"?(!at&&V.style[et]?St=V.style[et]:(lt=lt||jt(V))?St=lt[et]||lt.getPropertyValue(et)||lt.getPropertyValue(et.replace(Rt,"-$1").toLowerCase()):V.currentStyle&&(St=V.currentStyle[et]),j==null||St&&St!=="none"&&St!=="auto"&&St!=="auto auto"?St:j):Di(V)},pt=Oe.convertToPixels=function(V,et,lt,at,j){if(at==="px"||!at&&et!=="lineHeight")return lt;if(at==="auto"||!lt)return 0;var St,ht,Ot,Gt=Pt.test(et),zt=V,Mt=$e.style,he=0>lt,se=lt===1;if(he&&(lt=-lt),se&&(lt*=100),et!=="lineHeight"||at)if(at==="%"&&et.indexOf("border")!==-1)St=lt/100*(Gt?V.clientWidth:V.clientHeight);else{if(Mt.cssText="border:0 solid red;position:"+dt(V,"position")+";line-height:0;",at!=="%"&&zt.appendChild&&at.charAt(0)!=="v"&&at!=="rem")Mt[Gt?"borderLeftWidth":"borderTopWidth"]=lt+at;else{if(zt=V.parentNode||pe.body,dt(zt,"display").indexOf("flex")!==-1&&(Mt.position="absolute"),ht=zt._gsCache,Ot=a.ticker.frame,ht&&Gt&&ht.time===Ot)return ht.width*lt/100;Mt[Gt?"width":"height"]=lt+at}zt.appendChild($e),St=parseFloat($e[Gt?"offsetWidth":"offsetHeight"]),zt.removeChild($e),Gt&&at==="%"&&m.cacheWidths!==!1&&(ht=zt._gsCache=zt._gsCache||{},ht.time=Ot,ht.width=St/lt*100),St!==0||j||(St=pt(V,et,lt,at,!0))}else ht=jt(V).lineHeight,V.style.lineHeight=lt,St=parseFloat(jt(V).lineHeight),V.style.lineHeight=ht;return se&&(St/=100),he?-St:St},Dt=Oe.calculateOffset=function(V,et,lt){if(dt(V,"position",lt)!=="absolute")return 0;var at=et==="left"?"Left":"Top",j=dt(V,"margin"+at,lt);return V["offset"+at]-(pt(V,et,parseFloat(j),j.replace(F,""))||0)},ie=function(V,et){var lt,at,j,St={};if(et=et||jt(V,null))if(lt=et.length)for(;--lt>-1;)j=et[lt],(j.indexOf("-transform")===-1||ra===j)&&(St[j.replace(tt,G)]=et.getPropertyValue(j));else for(lt in et)(lt.indexOf("Transform")===-1||Mn===lt)&&(St[lt]=et[lt]);else if(et=V.currentStyle||V.style)for(lt in et)typeof lt=="string"&&St[lt]===void 0&&(St[lt.replace(tt,G)]=et[lt]);return pi||(St.opacity=Di(V)),at=uo(V,et,!1),St.rotation=at.rotation,St.skewX=at.skewX,St.scaleX=at.scaleX,St.scaleY=at.scaleY,St.x=at.x,St.y=at.y,vr&&(St.z=at.z,St.rotationX=at.rotationX,St.rotationY=at.rotationY,St.scaleZ=at.scaleZ),St.filters&&delete St.filters,St},Kt=function(V,et,lt,at,j){var St,ht,Ot,Gt={},zt=V.style;for(ht in lt)ht!=="cssText"&&ht!=="length"&&isNaN(ht)&&(et[ht]!==(St=lt[ht])||j&&j[ht])&&ht.indexOf("Origin")===-1&&(typeof St=="number"||typeof St=="string")&&(Gt[ht]=St!=="auto"||ht!=="left"&&ht!=="top"?St!==""&&St!=="auto"&&St!=="none"||typeof et[ht]!="string"||et[ht].replace(U,"")===""?St:0:Dt(V,ht),zt[ht]!==void 0&&(Ot=new ni(zt,ht,zt[ht],Ot)));if(at)for(ht in at)ht!=="className"&&(Gt[ht]=at[ht]);return{difs:Gt,firstMPT:Ot}},z={width:["Left","Right"],height:["Top","Bottom"]},Q=["marginLeft","marginRight","marginTop","marginBottom"],st=function(V,et,lt){if((V.nodeName+"").toLowerCase()==="svg")return(lt||jt(V))[et]||0;if(V.getCTM&&Wl(V))return V.getBBox()[et]||0;var at=parseFloat(et==="width"?V.offsetWidth:V.offsetHeight),j=z[et],St=j.length;for(lt=lt||jt(V,null);--St>-1;)at-=parseFloat(dt(V,"padding"+j[St],lt,!0))||0,at-=parseFloat(dt(V,"border"+j[St]+"Width",lt,!0))||0;return at},nt=function(V,et){if(V==="contain"||V==="auto"||V==="auto auto")return V+" ";(V==null||V==="")&&(V="0 0");var lt,at=V.split(" "),j=V.indexOf("left")!==-1?"0%":V.indexOf("right")!==-1?"100%":at[0],St=V.indexOf("top")!==-1?"0%":V.indexOf("bottom")!==-1?"100%":at[1];if(at.length>3&&!et){for(at=V.split(", ").join(",").split(","),V=[],lt=0;lt<at.length;lt++)V.push(nt(at[lt]));return V.join(",")}return St==null?St=j==="center"?"50%":"0":St==="center"&&(St="50%"),(j==="center"||isNaN(parseFloat(j))&&(j+"").indexOf("=")===-1)&&(j="50%"),V=j+" "+St+(at.length>2?" "+at[2]:""),et&&(et.oxp=j.indexOf("%")!==-1,et.oyp=St.indexOf("%")!==-1,et.oxr=j.charAt(1)==="=",et.oyr=St.charAt(1)==="=",et.ox=parseFloat(j.replace(U,"")),et.oy=parseFloat(St.replace(U,"")),et.v=V),et||V},vt=function(V,et){return typeof V=="function"&&(V=V(w,P)),typeof V=="string"&&V.charAt(1)==="="?parseInt(V.charAt(0)+"1",10)*parseFloat(V.substr(2)):parseFloat(V)-parseFloat(et)||0},Ut=function(V,et){typeof V=="function"&&(V=V(w,P));var lt=typeof V=="string"&&V.charAt(1)==="=";return typeof V=="string"&&V.charAt(V.length-2)==="v"&&(V=(lt?V.substr(0,2):0)+window["inner"+(V.substr(-2)==="vh"?"Height":"Width")]*(parseFloat(lt?V.substr(2):V)/100)),V==null?et:lt?parseInt(V.charAt(0)+"1",10)*parseFloat(V.substr(2))+et:parseFloat(V)||0},qt=function(V,et,lt,at){var j,St,ht,Ot,Gt,zt=1e-6;return typeof V=="function"&&(V=V(w,P)),V==null?Ot=et:typeof V=="number"?Ot=V:(j=360,St=V.split("_"),Gt=V.charAt(1)==="=",ht=(Gt?parseInt(V.charAt(0)+"1",10)*parseFloat(St[0].substr(2)):parseFloat(St[0]))*(V.indexOf("rad")===-1?1:It)-(Gt?0:et),St.length&&(at&&(at[lt]=et+ht),V.indexOf("short")!==-1&&(ht%=j,ht!==ht%(j/2)&&(ht=0>ht?ht+j:ht-j)),V.indexOf("_cw")!==-1&&0>ht?ht=(ht+9999999999*j)%j-(ht/j|0)*j:V.indexOf("ccw")!==-1&&ht>0&&(ht=(ht-9999999999*j)%j-(ht/j|0)*j)),Ot=et+ht),zt>Ot&&Ot>-zt&&(Ot=0),Ot},Xt={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],fuchsia:[255,0,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]},Ne=function(V,et,lt){return V=0>V?V+1:V>1?V-1:V,255*(1>6*V?et+(lt-et)*V*6:.5>V?lt:2>3*V?et+(lt-et)*(2/3-V)*6:et)+.5|0},Ie=m.parseColor=function(V,et){var lt,at,j,St,ht,Ot,Gt,zt,Mt,he,se;if(V)if(typeof V=="number")lt=[V>>16,V>>8&255,255&V];else{if(V.charAt(V.length-1)===","&&(V=V.substr(0,V.length-1)),Xt[V])lt=Xt[V];else if(V.charAt(0)==="#")V.length===4&&(at=V.charAt(1),j=V.charAt(2),St=V.charAt(3),V="#"+at+at+j+j+St+St),V=parseInt(V.substr(1),16),lt=[V>>16,V>>8&255,255&V];else if(V.substr(0,3)==="hsl")if(lt=se=V.match(M),et){if(V.indexOf("=")!==-1)return V.match(R)}else ht=Number(lt[0])%360/360,Ot=Number(lt[1])/100,Gt=Number(lt[2])/100,j=.5>=Gt?Gt*(Ot+1):Gt+Ot-Gt*Ot,at=2*Gt-j,lt.length>3&&(lt[3]=Number(lt[3])),lt[0]=Ne(ht+1/3,at,j),lt[1]=Ne(ht,at,j),lt[2]=Ne(ht-1/3,at,j);else lt=V.match(M)||Xt.transparent;lt[0]=Number(lt[0]),lt[1]=Number(lt[1]),lt[2]=Number(lt[2]),lt.length>3&&(lt[3]=Number(lt[3]))}else lt=Xt.black;return et&&!se&&(at=lt[0]/255,j=lt[1]/255,St=lt[2]/255,zt=Math.max(at,j,St),Mt=Math.min(at,j,St),Gt=(zt+Mt)/2,zt===Mt?ht=Ot=0:(he=zt-Mt,Ot=Gt>.5?he/(2-zt-Mt):he/(zt+Mt),ht=zt===at?(j-St)/he+(St>j?6:0):zt===j?(St-at)/he+2:(at-j)/he+4,ht*=60),lt[0]=ht+.5|0,lt[1]=100*Ot+.5|0,lt[2]=100*Gt+.5|0),lt},me=function(V,et){var lt,at,j,St=V.match(we)||[],ht=0,Ot="";if(!St.length)return V;for(lt=0;lt<St.length;lt++)at=St[lt],j=V.substr(ht,V.indexOf(at,ht)-ht),ht+=j.length+at.length,at=Ie(at,et),at.length===3&&at.push(1),Ot+=j+(et?"hsla("+at[0]+","+at[1]+"%,"+at[2]+"%,"+at[3]:"rgba("+at.join(","))+")";return Ot+V.substr(ht)},we="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3}){1,2}\\b";for(S in Xt)we+="|"+S+"\\b";we=new RegExp(we+")","gi"),m.colorStringFilter=function(V){var et,lt=V[0]+" "+V[1];we.test(lt)&&(et=lt.indexOf("hsl(")!==-1||lt.indexOf("hsla(")!==-1,V[0]=me(V[0],et),V[1]=me(V[1],et)),we.lastIndex=0},a.defaultStringFilter||(a.defaultStringFilter=m.colorStringFilter);var yi=function(V,et,lt,at){if(V==null)return function(se){return se};var j,St=et?(V.match(we)||[""])[0]:"",ht=V.split(St).join("").match(C)||[],Ot=V.substr(0,V.indexOf(ht[0])),Gt=V.charAt(V.length-1)===")"?")":"",zt=V.indexOf(" ")!==-1?" ":",",Mt=ht.length,he=Mt>0?ht[0].replace(M,""):"";return Mt?j=et?function(se){var te,ye,ue,je;if(typeof se=="number")se+=he;else if(at&&ce.test(se)){for(je=se.replace(ce,"|").split("|"),ue=0;ue<je.length;ue++)je[ue]=j(je[ue]);return je.join(",")}if(te=(se.match(we)||[St])[0],ye=se.split(te).join("").match(C)||[],ue=ye.length,Mt>ue--)for(;++ue<Mt;)ye[ue]=lt?ye[(ue-1)/2|0]:ht[ue];return Ot+ye.join(zt)+zt+te+Gt+(se.indexOf("inset")!==-1?" inset":"")}:function(se){var te,ye,ue;if(typeof se=="number")se+=he;else if(at&&ce.test(se)){for(ye=se.replace(ce,"|").split("|"),ue=0;ue<ye.length;ue++)ye[ue]=j(ye[ue]);return ye.join(",")}if(te=se.match(C)||[],ue=te.length,Mt>ue--)for(;++ue<Mt;)te[ue]=lt?te[(ue-1)/2|0]:ht[ue];return Ot+te.join(zt)+Gt}:function(se){return se}},Ei=function(V){return V=V.split(","),function(et,lt,at,j,St,ht,Ot){var Gt,zt=(lt+"").split(" ");for(Ot={},Gt=0;4>Gt;Gt++)Ot[V[Gt]]=zt[Gt]=zt[Gt]||zt[(Gt-1)/2>>0];return j.parse(et,Ot,St,ht)}},ni=(Oe._setPluginRatio=function(V){this.plugin.setRatio(V);for(var et,lt,at,j,St,ht=this.data,Ot=ht.proxy,Gt=ht.firstMPT,zt=1e-6;Gt;)et=Ot[Gt.v],Gt.r?et=Gt.r(et):zt>et&&et>-zt&&(et=0),Gt.t[Gt.p]=et,Gt=Gt._next;if(ht.autoRotate&&(ht.autoRotate.rotation=ht.mod?ht.mod.call(this._tween,Ot.rotation,this.t,this._tween):Ot.rotation),V===1||V===0)for(Gt=ht.firstMPT,St=V===1?"e":"b";Gt;){if(lt=Gt.t,lt.type){if(lt.type===1){for(j=lt.xs0+lt.s+lt.xs1,at=1;at<lt.l;at++)j+=lt["xn"+at]+lt["xs"+(at+1)];lt[St]=j}}else lt[St]=lt.s+lt.xs0;Gt=Gt._next}},function(V,et,lt,at,j){this.t=V,this.p=et,this.v=lt,this.r=j,at&&(at._prev=this,this._next=at)}),bi=(Oe._parseToProxy=function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he=at,se={},te={},ye=lt._transform,ue=Nt;for(lt._transform=null,Nt=et,at=Mt=lt.parse(V,et,at,j),Nt=ue,St&&(lt._transform=ye,he&&(he._prev=null,he._prev&&(he._prev._next=null)));at&&at!==he;){if(at.type<=1&&(Ot=at.p,te[Ot]=at.s+at.c,se[Ot]=at.s,St||(zt=new ni(at,"s",Ot,zt,at.r),at.c=0),at.type===1))for(ht=at.l;--ht>0;)Gt="xn"+ht,Ot=at.p+"_"+Gt,te[Ot]=at.data[Gt],se[Ot]=at[Gt],St||(zt=new ni(at,Gt,Ot,zt,at.rxp[Gt]));at=at._next}return{proxy:se,end:te,firstMPT:zt,pt:Mt}},Oe.CSSPropTween=function(V,et,lt,at,j,St,ht,Ot,Gt,zt,Mt){this.t=V,this.p=et,this.s=lt,this.c=at,this.n=ht||et,V instanceof bi||u.push(this.n),this.r=Ot&&(typeof Ot=="function"?Ot:Math.round),this.type=St||0,Gt&&(this.pr=Gt,o=!0),this.b=zt===void 0?lt:zt,this.e=Mt===void 0?lt+at:Mt,j&&(this._next=j,j._prev=this)}),qr=function(V,et,lt,at,j,St){var ht=new bi(V,et,lt,at-lt,j,-1,St);return ht.b=lt,ht.e=ht.xs0=at,ht},sr=m.parseComplex=function(V,et,lt,at,j,St,ht,Ot,Gt,zt){lt=lt||St||"",typeof at=="function"&&(at=at(w,P)),ht=new bi(V,et,0,0,ht,zt?2:1,null,!1,Ot,lt,at),at+="",j&&we.test(at+lt)&&(at=[lt,at],m.colorStringFilter(at),lt=at[0],at=at[1]);var Mt,he,se,te,ye,ue,je,He,ci,Be,_e,Fe,fe,mi=lt.split(", ").join(",").split(" "),Le=at.split(", ").join(",").split(" "),xe=mi.length,Re=b!==!1;for((at.indexOf(",")!==-1||lt.indexOf(",")!==-1)&&((at+lt).indexOf("rgb")!==-1||(at+lt).indexOf("hsl")!==-1?(mi=mi.join(" ").replace(ce,", ").split(" "),Le=Le.join(" ").replace(ce,", ").split(" ")):(mi=mi.join(" ").split(",").join(", ").split(" "),Le=Le.join(" ").split(",").join(", ").split(" ")),xe=mi.length),xe!==Le.length&&(mi=(St||"").split(" "),xe=mi.length),ht.plugin=Gt,ht.setRatio=zt,we.lastIndex=0,Mt=0;xe>Mt;Mt++)if(te=mi[Mt],ye=Le[Mt]+"",He=parseFloat(te),He||He===0)ht.appendXtra("",He,vt(ye,He),ye.replace(R,""),Re&&ye.indexOf("px")!==-1?Math.round:!1,!0);else if(j&&we.test(te))Fe=ye.indexOf(")")+1,Fe=")"+(Fe?ye.substr(Fe):""),fe=ye.indexOf("hsl")!==-1&&pi,Be=ye,te=Ie(te,fe),ye=Ie(ye,fe),ci=te.length+ye.length>6,ci&&!pi&&ye[3]===0?(ht["xs"+ht.l]+=ht.l?" transparent":"transparent",ht.e=ht.e.split(Le[Mt]).join("transparent")):(pi||(ci=!1),fe?ht.appendXtra(Be.substr(0,Be.indexOf("hsl"))+(ci?"hsla(":"hsl("),te[0],vt(ye[0],te[0]),",",!1,!0).appendXtra("",te[1],vt(ye[1],te[1]),"%,",!1).appendXtra("",te[2],vt(ye[2],te[2]),ci?"%,":"%"+Fe,!1):ht.appendXtra(Be.substr(0,Be.indexOf("rgb"))+(ci?"rgba(":"rgb("),te[0],ye[0]-te[0],",",Math.round,!0).appendXtra("",te[1],ye[1]-te[1],",",Math.round).appendXtra("",te[2],ye[2]-te[2],ci?",":Fe,Math.round),ci&&(te=te.length<4?1:te[3],ht.appendXtra("",te,(ye.length<4?1:ye[3])-te,Fe,!1))),we.lastIndex=0;else if(ue=te.match(M)){if(je=ye.match(R),!je||je.length!==ue.length)return ht;for(se=0,he=0;he<ue.length;he++)_e=ue[he],Be=te.indexOf(_e,se),ht.appendXtra(te.substr(se,Be-se),Number(_e),vt(je[he],_e),"",Re&&te.substr(Be+_e.length,2)==="px"?Math.round:!1,he===0),se=Be+_e.length;ht["xs"+ht.l]+=te.substr(se)}else ht["xs"+ht.l]+=ht.l||ht["xs"+ht.l]?" "+ye:ye;if(at.indexOf("=")!==-1&&ht.data){for(Fe=ht.xs0+ht.data.s,Mt=1;Mt<ht.l;Mt++)Fe+=ht["xs"+Mt]+ht.data["xn"+Mt];ht.e=Fe+ht["xs"+Mt]}return ht.l||(ht.type=-1,ht.xs0=ht.e),ht.xfirst||ht},sn=9;for(S=bi.prototype,S.l=S.pr=0;--sn>0;)S["xn"+sn]=0,S["xs"+sn]="";S.xs0="",S._next=S._prev=S.xfirst=S.data=S.plugin=S.setRatio=S.rxp=null,S.appendXtra=function(V,et,lt,at,j,St){var ht=this,Ot=ht.l;return ht["xs"+Ot]+=St&&(Ot||ht["xs"+Ot])?" "+V:V||"",lt||Ot===0||ht.plugin?(ht.l++,ht.type=ht.setRatio?2:1,ht["xs"+ht.l]=at||"",Ot>0?(ht.data["xn"+Ot]=et+lt,ht.rxp["xn"+Ot]=j,ht["xn"+Ot]=et,ht.plugin||(ht.xfirst=new bi(ht,"xn"+Ot,et,lt,ht.xfirst||ht,0,ht.n,j,ht.pr),ht.xfirst.xs0=0),ht):(ht.data={s:et+lt},ht.rxp={},ht.s=et,ht.c=lt,ht.r=j,ht)):(ht["xs"+Ot]+=et+(at||""),ht)};var Ao=function(V,et){et=et||{},this.p=et.prefix&&Jt(V)||V,v[V]=v[this.p]=this,this.format=et.formatter||yi(et.defaultValue,et.color,et.collapsible,et.multi),et.parser&&(this.parse=et.parser),this.clrs=et.color,this.multi=et.multi,this.keyword=et.keyword,this.dflt=et.defaultValue,this.pr=et.priority||0},zi=Oe._registerComplexSpecialProp=function(V,et,lt){typeof et!="object"&&(et={parser:lt});var at,j=V.split(","),St=et.defaultValue;for(lt=lt||[St],at=0;at<j.length;at++)et.prefix=at===0&&et.prefix,et.defaultValue=lt[at]||St,new Ao(j[at],et)},Yo=Oe._registerPluginProp=function(V){if(!v[V]){var et=V.charAt(0).toUpperCase()+V.substr(1)+"Plugin";zi(V,{parser:function(lt,at,j,St,ht,Ot,Gt){var zt=g.com.greensock.plugins[et];return zt?(zt._cssRegister(),v[j].parse(lt,at,j,St,ht,Ot,Gt)):(mn("Error: "+et+" js file not loaded."),ht)}})}};S=Ao.prototype,S.parseComplex=function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he,se=this.keyword;if(this.multi&&(ce.test(lt)||ce.test(et)?(Ot=et.replace(ce,"|").split("|"),Gt=lt.replace(ce,"|").split("|")):se&&(Ot=[et],Gt=[lt])),Gt){for(zt=Gt.length>Ot.length?Gt.length:Ot.length,ht=0;zt>ht;ht++)et=Ot[ht]=Ot[ht]||this.dflt,lt=Gt[ht]=Gt[ht]||this.dflt,se&&(Mt=et.indexOf(se),he=lt.indexOf(se),Mt!==he&&(he===-1?Ot[ht]=Ot[ht].split(se).join(""):Mt===-1&&(Ot[ht]+=" "+se)));et=Ot.join(", "),lt=Gt.join(", ")}return sr(V,this.p,et,lt,this.clrs,this.dflt,at,this.pr,j,St)},S.parse=function(V,et,lt,at,j,St,ht){return this.parseComplex(V.style,this.format(dt(V,this.p,f,!1,this.dflt)),this.format(et),j,St)},m.registerSpecialProp=function(V,et,lt){zi(V,{parser:function(at,j,St,ht,Ot,Gt,zt){var Mt=new bi(at,St,0,0,Ot,2,St,!1,lt);return Mt.plugin=Gt,Mt.setRatio=et(at,j,ht._tween,St),Mt},priority:lt})},m.useSVGTransformAttr=!0;var ao,Hl="scaleX,scaleY,scaleZ,x,y,z,skewX,skewY,rotation,rotationX,rotationY,perspective,xPercent,yPercent".split(","),Mn=Jt("transform"),ra=Qi+"transform",vs=Jt("transformOrigin"),vr=Jt("perspective")!==null,oa=Oe.Transform=function(){this.perspective=parseFloat(m.defaultTransformPerspective)||0,this.force3D=m.defaultForce3D!==!1&&vr?m.defaultForce3D||"auto":!1},Za=ln.SVGElement,Vl=function(V,et,lt){var at,j=pe.createElementNS("http://www.w3.org/2000/svg",V),St=/([a-z])([A-Z])/g;for(at in lt)j.setAttributeNS(null,at.replace(St,"$1-$2").toLowerCase(),lt[at]);return et.appendChild(j),j},lo=pe.documentElement||{},Oh=function(){var V,et,lt,at=E||/Android/i.test(Ge)&&!ln.chrome;return pe.createElementNS&&!at&&(V=Vl("svg",lo),et=Vl("rect",V,{width:100,height:50,x:100}),lt=et.getBoundingClientRect().width,et.style[vs]="50% 50%",et.style[Mn]="scaleX(0.5)",at=lt===et.getBoundingClientRect().width&&!(I&&vr),lo.removeChild(V)),at}(),sa=function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he,se,te,ye,ue,je,He,ci,Be,_e=V._gsTransform,Fe=la(V,!0);_e&&(ci=_e.xOrigin,Be=_e.yOrigin),(!at||(ht=at.split(" ")).length<2)&&(se=V.getBBox(),se.x===0&&se.y===0&&se.width+se.height===0&&(se={x:parseFloat(V.hasAttribute("x")?V.getAttribute("x"):V.hasAttribute("cx")?V.getAttribute("cx"):0)||0,y:parseFloat(V.hasAttribute("y")?V.getAttribute("y"):V.hasAttribute("cy")?V.getAttribute("cy"):0)||0,width:0,height:0}),et=nt(et).split(" "),ht=[(et[0].indexOf("%")!==-1?parseFloat(et[0])/100*se.width:parseFloat(et[0]))+se.x,(et[1].indexOf("%")!==-1?parseFloat(et[1])/100*se.height:parseFloat(et[1]))+se.y]),lt.xOrigin=zt=parseFloat(ht[0]),lt.yOrigin=Mt=parseFloat(ht[1]),at&&Fe!==aa&&(he=Fe[0],se=Fe[1],te=Fe[2],ye=Fe[3],ue=Fe[4],je=Fe[5],He=he*ye-se*te,He&&(Ot=zt*(ye/He)+Mt*(-te/He)+(te*je-ye*ue)/He,Gt=zt*(-se/He)+Mt*(he/He)-(he*je-se*ue)/He,zt=lt.xOrigin=ht[0]=Ot,Mt=lt.yOrigin=ht[1]=Gt)),_e&&(St&&(lt.xOffset=_e.xOffset,lt.yOffset=_e.yOffset,_e=lt),j||j!==!1&&m.defaultSmoothOrigin!==!1?(Ot=zt-ci,Gt=Mt-Be,_e.xOffset+=Ot*Fe[0]+Gt*Fe[2]-Ot,_e.yOffset+=Ot*Fe[1]+Gt*Fe[3]-Gt):_e.xOffset=_e.yOffset=0),St||V.setAttribute("data-svg-origin",ht.join(" "))},Ja=function(V){var et,lt=Wt("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),at=this.parentNode,j=this.nextSibling,St=this.style.cssText;if(lo.appendChild(lt),lt.appendChild(this),this.style.display="block",V)try{et=this.getBBox(),this._originalGetBBox=this.getBBox,this.getBBox=Ja}catch{}else this._originalGetBBox&&(et=this._originalGetBBox());return j?at.insertBefore(this,j):at.appendChild(this),lo.removeChild(lt),this.style.cssText=St,et},ho=function(V){try{return V.getBBox()}catch{return Ja.call(V,!0)}},Wl=function(V){return!(!Za||!V.getCTM||V.parentNode&&!V.ownerSVGElement||!ho(V))},aa=[1,0,0,1,0,0],la=function(V,et){var lt,at,j,St,ht,Ot,Gt=V._gsTransform||new oa,zt=1e5,Mt=V.style;if(Mn?at=dt(V,ra,null,!0):V.currentStyle&&(at=V.currentStyle.filter.match(Et),at=at&&at.length===4?[at[0].substr(4),Number(at[2].substr(4)),Number(at[1].substr(4)),at[3].substr(4),Gt.x||0,Gt.y||0].join(","):""),lt=!at||at==="none"||at==="matrix(1, 0, 0, 1, 0, 0)",!Mn||!(Ot=!jt(V)||jt(V).display==="none")&&V.parentNode||(Ot&&(St=Mt.display,Mt.display="block"),V.parentNode||(ht=1,lo.appendChild(V)),at=dt(V,ra,null,!0),lt=!at||at==="none"||at==="matrix(1, 0, 0, 1, 0, 0)",St?Mt.display=St:Ot&&ys(Mt,"display"),ht&&lo.removeChild(V)),(Gt.svg||V.getCTM&&Wl(V))&&(lt&&(Mt[Mn]+"").indexOf("matrix")!==-1&&(at=Mt[Mn],lt=0),j=V.getAttribute("transform"),lt&&j&&(j=V.transform.baseVal.consolidate().matrix,at="matrix("+j.a+","+j.b+","+j.c+","+j.d+","+j.e+","+j.f+")",lt=0)),lt)return aa;for(j=(at||"").match(M)||[],sn=j.length;--sn>-1;)St=Number(j[sn]),j[sn]=(ht=St-(St|=0))?(ht*zt+(0>ht?-.5:.5)|0)/zt+St:St;return et&&j.length>6?[j[0],j[1],j[4],j[5],j[12],j[13]]:j},uo=Oe.getTransform=function(V,et,lt,at){if(V._gsTransform&<&&!at)return V._gsTransform;var j,St,ht,Ot,Gt,zt,Mt=lt?V._gsTransform||new oa:new oa,he=Mt.scaleX<0,se=2e-5,te=1e5,ye=vr&&(parseFloat(dt(V,vs,et,!1,"0 0 0").split(" ")[2])||Mt.zOrigin)||0,ue=parseFloat(m.defaultTransformPerspective)||0;if(Mt.svg=!(!V.getCTM||!Wl(V)),Mt.svg&&(sa(V,dt(V,vs,et,!1,"50% 50%")+"",Mt,V.getAttribute("data-svg-origin")),ao=m.useSVGTransformAttr||Oh),j=la(V),j!==aa){if(j.length===16){var je,He,ci,Be,_e,Fe=j[0],fe=j[1],mi=j[2],Le=j[3],xe=j[4],Re=j[5],Sn=j[6],Xn=j[7],ki=j[8],Bi=j[9],Hi=j[10],nn=j[12],rn=j[13],un=j[14],cn=j[11],Gi=Math.atan2(Sn,Hi);Mt.zOrigin&&(un=-Mt.zOrigin,nn=ki*un-j[12],rn=Bi*un-j[13],un=Hi*un+Mt.zOrigin-j[14]),Mt.rotationX=Gi*It,Gi&&(Be=Math.cos(-Gi),_e=Math.sin(-Gi),je=xe*Be+ki*_e,He=Re*Be+Bi*_e,ci=Sn*Be+Hi*_e,ki=xe*-_e+ki*Be,Bi=Re*-_e+Bi*Be,Hi=Sn*-_e+Hi*Be,cn=Xn*-_e+cn*Be,xe=je,Re=He,Sn=ci),Gi=Math.atan2(-mi,Hi),Mt.rotationY=Gi*It,Gi&&(Be=Math.cos(-Gi),_e=Math.sin(-Gi),je=Fe*Be-ki*_e,He=fe*Be-Bi*_e,ci=mi*Be-Hi*_e,Bi=fe*_e+Bi*Be,Hi=mi*_e+Hi*Be,cn=Le*_e+cn*Be,Fe=je,fe=He,mi=ci),Gi=Math.atan2(fe,Fe),Mt.rotation=Gi*It,Gi&&(Be=Math.cos(Gi),_e=Math.sin(Gi),je=Fe*Be+fe*_e,He=xe*Be+Re*_e,ci=ki*Be+Bi*_e,fe=fe*Be-Fe*_e,Re=Re*Be-xe*_e,Bi=Bi*Be-ki*_e,Fe=je,xe=He,ki=ci),Mt.rotationX&&Math.abs(Mt.rotationX)+Math.abs(Mt.rotation)>359.9&&(Mt.rotationX=Mt.rotation=0,Mt.rotationY=180-Mt.rotationY),Gi=Math.atan2(xe,Re),Mt.scaleX=(Math.sqrt(Fe*Fe+fe*fe+mi*mi)*te+.5|0)/te,Mt.scaleY=(Math.sqrt(Re*Re+Sn*Sn)*te+.5|0)/te,Mt.scaleZ=(Math.sqrt(ki*ki+Bi*Bi+Hi*Hi)*te+.5|0)/te,Fe/=Mt.scaleX,xe/=Mt.scaleY,fe/=Mt.scaleX,Re/=Mt.scaleY,Math.abs(Gi)>se?(Mt.skewX=Gi*It,xe=0,Mt.skewType!=="simple"&&(Mt.scaleY*=1/Math.cos(Gi))):Mt.skewX=0,Mt.perspective=cn?1/(0>cn?-cn:cn):0,Mt.x=nn,Mt.y=rn,Mt.z=un,Mt.svg&&(Mt.x-=Mt.xOrigin-(Mt.xOrigin*Fe-Mt.yOrigin*xe),Mt.y-=Mt.yOrigin-(Mt.yOrigin*fe-Mt.xOrigin*Re))}else if(!vr||at||!j.length||Mt.x!==j[4]||Mt.y!==j[5]||!Mt.rotationX&&!Mt.rotationY){var Ni=j.length>=6,ji=Ni?j[0]:1,gi=j[1]||0,co=j[2]||0,Fn=Ni?j[3]:1;Mt.x=j[4]||0,Mt.y=j[5]||0,ht=Math.sqrt(ji*ji+gi*gi),Ot=Math.sqrt(Fn*Fn+co*co),Gt=ji||gi?Math.atan2(gi,ji)*It:Mt.rotation||0,zt=co||Fn?Math.atan2(co,Fn)*It+Gt:Mt.skewX||0,Mt.scaleX=ht,Mt.scaleY=Ot,Mt.rotation=Gt,Mt.skewX=zt,vr&&(Mt.rotationX=Mt.rotationY=Mt.z=0,Mt.perspective=ue,Mt.scaleZ=1),Mt.svg&&(Mt.x-=Mt.xOrigin-(Mt.xOrigin*ji+Mt.yOrigin*co),Mt.y-=Mt.yOrigin-(Mt.xOrigin*gi+Mt.yOrigin*Fn))}Math.abs(Mt.skewX)>90&&Math.abs(Mt.skewX)<270&&(he?(Mt.scaleX*=-1,Mt.skewX+=Mt.rotation<=0?180:-180,Mt.rotation+=Mt.rotation<=0?180:-180):(Mt.scaleY*=-1,Mt.skewX+=Mt.skewX<=0?180:-180)),Mt.zOrigin=ye;for(St in Mt)Mt[St]<se&&Mt[St]>-se&&(Mt[St]=0)}return lt&&(V._gsTransform=Mt,Mt.svg&&(ao&&V.style[Mn]?a.delayedCall(.001,function(){ys(V.style,Mn)}):!ao&&V.getAttribute("transform")&&a.delayedCall(.001,function(){V.removeAttribute("transform")}))),Mt},jl=function(V){var et,lt,at=this.data,j=-at.rotation*Ft,St=j+at.skewX*Ft,ht=1e5,Ot=(Math.cos(j)*at.scaleX*ht|0)/ht,Gt=(Math.sin(j)*at.scaleX*ht|0)/ht,zt=(Math.sin(St)*-at.scaleY*ht|0)/ht,Mt=(Math.cos(St)*at.scaleY*ht|0)/ht,he=this.t.style,se=this.t.currentStyle;if(se){lt=Gt,Gt=-zt,zt=-lt,et=se.filter,he.filter="";var te,ye,ue=this.t.offsetWidth,je=this.t.offsetHeight,He=se.position!=="absolute",ci="progid:DXImageTransform.Microsoft.Matrix(M11="+Ot+", M12="+Gt+", M21="+zt+", M22="+Mt,Be=at.x+ue*at.xPercent/100,_e=at.y+je*at.yPercent/100;if(at.ox!=null&&(te=(at.oxp?ue*at.ox*.01:at.ox)-ue/2,ye=(at.oyp?je*at.oy*.01:at.oy)-je/2,Be+=te-(te*Ot+ye*Gt),_e+=ye-(te*zt+ye*Mt)),He?(te=ue/2,ye=je/2,ci+=", Dx="+(te-(te*Ot+ye*Gt)+Be)+", Dy="+(ye-(te*zt+ye*Mt)+_e)+")"):ci+=", sizingMethod='auto expand')",et.indexOf("DXImageTransform.Microsoft.Matrix(")!==-1?he.filter=et.replace(At,ci):he.filter=ci+" "+et,(V===0||V===1)&&Ot===1&&Gt===0&&zt===0&&Mt===1&&(He&&ci.indexOf("Dx=0, Dy=0")===-1||X.test(et)&&parseFloat(RegExp.$1)!==100||et.indexOf(et.indexOf("Alpha"))===-1&&he.removeAttribute("filter")),!He){var Fe,fe,mi,Le=8>E?1:-1;for(te=at.ieOffsetX||0,ye=at.ieOffsetY||0,at.ieOffsetX=Math.round((ue-((0>Ot?-Ot:Ot)*ue+(0>Gt?-Gt:Gt)*je))/2+Be),at.ieOffsetY=Math.round((je-((0>Mt?-Mt:Mt)*je+(0>zt?-zt:zt)*ue))/2+_e),sn=0;4>sn;sn++)fe=Q[sn],Fe=se[fe],lt=Fe.indexOf("px")!==-1?parseFloat(Fe):pt(this.t,fe,parseFloat(Fe),Fe.replace(F,""))||0,mi=lt!==at[fe]?2>sn?-at.ieOffsetX:-at.ieOffsetY:2>sn?te-at.ieOffsetX:ye-at.ieOffsetY,he[fe]=(at[fe]=Math.round(lt-mi*(sn===0||sn===2?1:Le)))+"px"}}},Ih=Oe.set3DTransformRatio=Oe.setTransformRatio=function(V){var et,lt,at,j,St,ht,Ot,Gt,zt,Mt,he,se,te,ye,ue,je,He,ci,Be,_e,Fe,fe,mi,Le=this.data,xe=this.t.style,Re=Le.rotation,Sn=Le.rotationX,Xn=Le.rotationY,ki=Le.scaleX,Bi=Le.scaleY,Hi=Le.scaleZ,nn=Le.x,rn=Le.y,un=Le.z,cn=Le.svg,Gi=Le.perspective,Ni=Le.force3D,ji=Le.skewY,gi=Le.skewX;if(ji&&(gi+=ji,Re+=ji),((V===1||V===0)&&Ni==="auto"&&(this.tween._totalTime===this.tween._totalDuration||!this.tween._totalTime)||!Ni)&&!un&&!Gi&&!Xn&&!Sn&&Hi===1||ao&&cn||!vr)return void(Re||gi||cn?(Re*=Ft,fe=gi*Ft,mi=1e5,lt=Math.cos(Re)*ki,St=Math.sin(Re)*ki,at=Math.sin(Re-fe)*-Bi,ht=Math.cos(Re-fe)*Bi,fe&&Le.skewType==="simple"&&(et=Math.tan(fe-ji*Ft),et=Math.sqrt(1+et*et),at*=et,ht*=et,ji&&(et=Math.tan(ji*Ft),et=Math.sqrt(1+et*et),lt*=et,St*=et)),cn&&(nn+=Le.xOrigin-(Le.xOrigin*lt+Le.yOrigin*at)+Le.xOffset,rn+=Le.yOrigin-(Le.xOrigin*St+Le.yOrigin*ht)+Le.yOffset,ao&&(Le.xPercent||Le.yPercent)&&(ue=this.t.getBBox(),nn+=.01*Le.xPercent*ue.width,rn+=.01*Le.yPercent*ue.height),ue=1e-6,ue>nn&&nn>-ue&&(nn=0),ue>rn&&rn>-ue&&(rn=0)),Be=(lt*mi|0)/mi+","+(St*mi|0)/mi+","+(at*mi|0)/mi+","+(ht*mi|0)/mi+","+nn+","+rn+")",cn&&ao?this.t.setAttribute("transform","matrix("+Be):xe[Mn]=(Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) matrix(":"matrix(")+Be):xe[Mn]=(Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) matrix(":"matrix(")+ki+",0,0,"+Bi+","+nn+","+rn+")");if(I&&(ue=1e-4,ue>ki&&ki>-ue&&(ki=Hi=2e-5),ue>Bi&&Bi>-ue&&(Bi=Hi=2e-5),!Gi||Le.z||Le.rotationX||Le.rotationY||(Gi=0)),Re||gi)Re*=Ft,je=lt=Math.cos(Re),He=St=Math.sin(Re),gi&&(Re-=gi*Ft,je=Math.cos(Re),He=Math.sin(Re),Le.skewType==="simple"&&(et=Math.tan((gi-ji)*Ft),et=Math.sqrt(1+et*et),je*=et,He*=et,Le.skewY&&(et=Math.tan(ji*Ft),et=Math.sqrt(1+et*et),lt*=et,St*=et))),at=-He,ht=je;else{if(!(Xn||Sn||Hi!==1||Gi||cn))return void(xe[Mn]=(Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) translate3d(":"translate3d(")+nn+"px,"+rn+"px,"+un+"px)"+(ki!==1||Bi!==1?" scale("+ki+","+Bi+")":""));lt=ht=1,at=St=0}Mt=1,j=Ot=Gt=zt=he=se=0,te=Gi?-1/Gi:0,ye=Le.zOrigin,ue=1e-6,_e=",",Fe="0",Re=Xn*Ft,Re&&(je=Math.cos(Re),He=Math.sin(Re),Gt=-He,he=te*-He,j=lt*He,Ot=St*He,Mt=je,te*=je,lt*=je,St*=je),Re=Sn*Ft,Re&&(je=Math.cos(Re),He=Math.sin(Re),et=at*je+j*He,ci=ht*je+Ot*He,zt=Mt*He,se=te*He,j=at*-He+j*je,Ot=ht*-He+Ot*je,Mt*=je,te*=je,at=et,ht=ci),Hi!==1&&(j*=Hi,Ot*=Hi,Mt*=Hi,te*=Hi),Bi!==1&&(at*=Bi,ht*=Bi,zt*=Bi,se*=Bi),ki!==1&&(lt*=ki,St*=ki,Gt*=ki,he*=ki),(ye||cn)&&(ye&&(nn+=j*-ye,rn+=Ot*-ye,un+=Mt*-ye+ye),cn&&(nn+=Le.xOrigin-(Le.xOrigin*lt+Le.yOrigin*at)+Le.xOffset,rn+=Le.yOrigin-(Le.xOrigin*St+Le.yOrigin*ht)+Le.yOffset),ue>nn&&nn>-ue&&(nn=Fe),ue>rn&&rn>-ue&&(rn=Fe),ue>un&&un>-ue&&(un=0)),Be=Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) matrix3d(":"matrix3d(",Be+=(ue>lt&<>-ue?Fe:lt)+_e+(ue>St&&St>-ue?Fe:St)+_e+(ue>Gt&&Gt>-ue?Fe:Gt),Be+=_e+(ue>he&&he>-ue?Fe:he)+_e+(ue>at&&at>-ue?Fe:at)+_e+(ue>ht&&ht>-ue?Fe:ht),Sn||Xn||Hi!==1?(Be+=_e+(ue>zt&&zt>-ue?Fe:zt)+_e+(ue>se&&se>-ue?Fe:se)+_e+(ue>j&&j>-ue?Fe:j),Be+=_e+(ue>Ot&&Ot>-ue?Fe:Ot)+_e+(ue>Mt&&Mt>-ue?Fe:Mt)+_e+(ue>te&&te>-ue?Fe:te)+_e):Be+=",0,0,0,0,1,0,",Be+=nn+_e+rn+_e+un+_e+(Gi?1+-un/Gi:1)+")",xe[Mn]=Be};S=oa.prototype,S.x=S.y=S.z=S.skewX=S.skewY=S.rotation=S.rotationX=S.rotationY=S.zOrigin=S.xPercent=S.yPercent=S.xOffset=S.yOffset=0,S.scaleX=S.scaleY=S.scaleZ=1,zi("transform,scale,scaleX,scaleY,scaleZ,x,y,z,rotation,rotationX,rotationY,rotationZ,skewX,skewY,shortRotation,shortRotationX,shortRotationY,shortRotationZ,transformOrigin,svgOrigin,transformPerspective,directionalRotation,parseTransform,force3D,skewType,xPercent,yPercent,smoothOrigin",{parser:function(V,et,lt,at,j,St,ht){if(at._lastParsedTransform===ht)return j;at._lastParsedTransform=ht;var Ot,Gt=ht.scale&&typeof ht.scale=="function"?ht.scale:0;typeof ht[lt]=="function"&&(Ot=ht[lt],ht[lt]=et),Gt&&(ht.scale=Gt(w,V));var zt,Mt,he,se,te,ye,ue,je,He,ci=V._gsTransform,Be=V.style,_e=1e-6,Fe=Hl.length,fe=ht,mi={},Le="transformOrigin",xe=uo(V,f,!0,fe.parseTransform),Re=fe.transform&&(typeof fe.transform=="function"?fe.transform(w,P):fe.transform);if(xe.skewType=fe.skewType||xe.skewType||m.defaultSkewType,at._transform=xe,"rotationZ"in fe&&(fe.rotation=fe.rotationZ),Re&&typeof Re=="string"&&Mn)Mt=$e.style,Mt[Mn]=Re,Mt.display="block",Mt.position="absolute",Re.indexOf("%")!==-1&&(Mt.width=dt(V,"width"),Mt.height=dt(V,"height")),pe.body.appendChild($e),zt=uo($e,null,!1),xe.skewType==="simple"&&(zt.scaleY*=Math.cos(zt.skewX*Ft)),xe.svg&&(ye=xe.xOrigin,ue=xe.yOrigin,zt.x-=xe.xOffset,zt.y-=xe.yOffset,(fe.transformOrigin||fe.svgOrigin)&&(Re={},sa(V,nt(fe.transformOrigin),Re,fe.svgOrigin,fe.smoothOrigin,!0),ye=Re.xOrigin,ue=Re.yOrigin,zt.x-=Re.xOffset-xe.xOffset,zt.y-=Re.yOffset-xe.yOffset),(ye||ue)&&(je=la($e,!0),zt.x-=ye-(ye*je[0]+ue*je[2]),zt.y-=ue-(ye*je[1]+ue*je[3]))),pe.body.removeChild($e),zt.perspective||(zt.perspective=xe.perspective),fe.xPercent!=null&&(zt.xPercent=Ut(fe.xPercent,xe.xPercent)),fe.yPercent!=null&&(zt.yPercent=Ut(fe.yPercent,xe.yPercent));else if(typeof fe=="object"){if(zt={scaleX:Ut(fe.scaleX!=null?fe.scaleX:fe.scale,xe.scaleX),scaleY:Ut(fe.scaleY!=null?fe.scaleY:fe.scale,xe.scaleY),scaleZ:Ut(fe.scaleZ,xe.scaleZ),x:Ut(fe.x,xe.x),y:Ut(fe.y,xe.y),z:Ut(fe.z,xe.z),xPercent:Ut(fe.xPercent,xe.xPercent),yPercent:Ut(fe.yPercent,xe.yPercent),perspective:Ut(fe.transformPerspective,xe.perspective)},te=fe.directionalRotation,te!=null)if(typeof te=="object")for(Mt in te)fe[Mt]=te[Mt];else fe.rotation=te;typeof fe.x=="string"&&fe.x.indexOf("%")!==-1&&(zt.x=0,zt.xPercent=Ut(fe.x,xe.xPercent)),typeof fe.y=="string"&&fe.y.indexOf("%")!==-1&&(zt.y=0,zt.yPercent=Ut(fe.y,xe.yPercent)),zt.rotation=qt("rotation"in fe?fe.rotation:"shortRotation"in fe?fe.shortRotation+"_short":xe.rotation,xe.rotation,"rotation",mi),vr&&(zt.rotationX=qt("rotationX"in fe?fe.rotationX:"shortRotationX"in fe?fe.shortRotationX+"_short":xe.rotationX||0,xe.rotationX,"rotationX",mi),zt.rotationY=qt("rotationY"in fe?fe.rotationY:"shortRotationY"in fe?fe.shortRotationY+"_short":xe.rotationY||0,xe.rotationY,"rotationY",mi)),zt.skewX=qt(fe.skewX,xe.skewX),zt.skewY=qt(fe.skewY,xe.skewY)}for(vr&&fe.force3D!=null&&(xe.force3D=fe.force3D,se=!0),he=xe.force3D||xe.z||xe.rotationX||xe.rotationY||zt.z||zt.rotationX||zt.rotationY||zt.perspective,he||fe.scale==null||(zt.scaleZ=1);--Fe>-1;)He=Hl[Fe],Re=zt[He]-xe[He],(Re>_e||-_e>Re||fe[He]!=null||Nt[He]!=null)&&(se=!0,j=new bi(xe,He,xe[He],Re,j),He in mi&&(j.e=mi[He]),j.xs0=0,j.plugin=St,at._overwriteProps.push(j.n));return Re=fe.transformOrigin,xe.svg&&(Re||fe.svgOrigin)&&(ye=xe.xOffset,ue=xe.yOffset,sa(V,nt(Re),zt,fe.svgOrigin,fe.smoothOrigin),j=qr(xe,"xOrigin",(ci?xe:zt).xOrigin,zt.xOrigin,j,Le),j=qr(xe,"yOrigin",(ci?xe:zt).yOrigin,zt.yOrigin,j,Le),(ye!==xe.xOffset||ue!==xe.yOffset)&&(j=qr(xe,"xOffset",ci?ye:xe.xOffset,xe.xOffset,j,Le),j=qr(xe,"yOffset",ci?ue:xe.yOffset,xe.yOffset,j,Le)),Re="0px 0px"),(Re||vr&&he&&xe.zOrigin)&&(Mn?(se=!0,He=vs,Re=(Re||dt(V,He,f,!1,"50% 50%"))+"",j=new bi(Be,He,0,0,j,-1,Le),j.b=Be[He],j.plugin=St,vr?(Mt=xe.zOrigin,Re=Re.split(" "),xe.zOrigin=(Re.length>2&&(Mt===0||Re[2]!=="0px")?parseFloat(Re[2]):Mt)||0,j.xs0=j.e=Re[0]+" "+(Re[1]||"50%")+" 0px",j=new bi(xe,"zOrigin",0,0,j,-1,j.n),j.b=Mt,j.xs0=j.e=xe.zOrigin):j.xs0=j.e=Re):nt(Re+"",xe)),se&&(at._transformType=xe.svg&&ao||!he&&this._transformType!==3?2:3),Ot&&(ht[lt]=Ot),Gt&&(ht.scale=Gt),j},prefix:!0}),zi("boxShadow",{defaultValue:"0px 0px 0px 0px #999",prefix:!0,color:!0,multi:!0,keyword:"inset"}),zi("borderRadius",{defaultValue:"0px",parser:function(V,et,lt,at,j,St){et=this.format(et);var ht,Ot,Gt,zt,Mt,he,se,te,ye,ue,je,He,ci,Be,_e,Fe,fe=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],mi=V.style;for(ye=parseFloat(V.offsetWidth),ue=parseFloat(V.offsetHeight),ht=et.split(" "),Ot=0;Ot<fe.length;Ot++)this.p.indexOf("border")&&(fe[Ot]=Jt(fe[Ot])),Mt=zt=dt(V,fe[Ot],f,!1,"0px"),Mt.indexOf(" ")!==-1&&(zt=Mt.split(" "),Mt=zt[0],zt=zt[1]),he=Gt=ht[Ot],se=parseFloat(Mt),He=Mt.substr((se+"").length),ci=he.charAt(1)==="=",ci?(te=parseInt(he.charAt(0)+"1",10),he=he.substr(2),te*=parseFloat(he),je=he.substr((te+"").length-(0>te?1:0))||""):(te=parseFloat(he),je=he.substr((te+"").length)),je===""&&(je=c[lt]||He),je!==He&&(Be=pt(V,"borderLeft",se,He),_e=pt(V,"borderTop",se,He),je==="%"?(Mt=Be/ye*100+"%",zt=_e/ue*100+"%"):je==="em"?(Fe=pt(V,"borderLeft",1,"em"),Mt=Be/Fe+"em",zt=_e/Fe+"em"):(Mt=Be+"px",zt=_e+"px"),ci&&(he=parseFloat(Mt)+te+je,Gt=parseFloat(zt)+te+je)),j=sr(mi,fe[Ot],Mt+" "+zt,he+" "+Gt,!1,"0px",j);return j},prefix:!0,formatter:yi("0px 0px 0px 0px",!1,!0)}),zi("borderBottomLeftRadius,borderBottomRightRadius,borderTopLeftRadius,borderTopRightRadius",{defaultValue:"0px",parser:function(V,et,lt,at,j,St){return sr(V.style,lt,this.format(dt(V,lt,f,!1,"0px 0px")),this.format(et),!1,"0px",j)},prefix:!0,formatter:yi("0px 0px",!1,!0)}),zi("backgroundPosition",{defaultValue:"0 0",parser:function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he,se="background-position",te=f||jt(V,null),ye=this.format((te?E?te.getPropertyValue(se+"-x")+" "+te.getPropertyValue(se+"-y"):te.getPropertyValue(se):V.currentStyle.backgroundPositionX+" "+V.currentStyle.backgroundPositionY)||"0 0"),ue=this.format(et);if(ye.indexOf("%")!==-1!=(ue.indexOf("%")!==-1)&&ue.split(",").length<2&&(he=dt(V,"backgroundImage").replace(_t,""),he&&he!=="none")){for(ht=ye.split(" "),Ot=ue.split(" "),Si.setAttribute("src",he),Gt=2;--Gt>-1;)ye=ht[Gt],zt=ye.indexOf("%")!==-1,zt!==(Ot[Gt].indexOf("%")!==-1)&&(Mt=Gt===0?V.offsetWidth-Si.width:V.offsetHeight-Si.height,ht[Gt]=zt?parseFloat(ye)/100*Mt+"px":parseFloat(ye)/Mt*100+"%");ye=ht.join(" ")}return this.parseComplex(V.style,ye,ue,j,St)},formatter:nt}),zi("backgroundSize",{defaultValue:"0 0",formatter:function(V){return V+="",V.substr(0,2)==="co"?V:nt(V.indexOf(" ")===-1?V+" "+V:V)}}),zi("perspective",{defaultValue:"0px",prefix:!0}),zi("perspectiveOrigin",{defaultValue:"50% 50%",prefix:!0}),zi("transformStyle",{prefix:!0}),zi("backfaceVisibility",{prefix:!0}),zi("userSelect",{prefix:!0}),zi("margin",{parser:Ei("marginTop,marginRight,marginBottom,marginLeft")}),zi("padding",{parser:Ei("paddingTop,paddingRight,paddingBottom,paddingLeft")}),zi("clip",{defaultValue:"rect(0px,0px,0px,0px)",parser:function(V,et,lt,at,j,St){var ht,Ot,Gt;return 9>E?(Ot=V.currentStyle,Gt=8>E?" ":",",ht="rect("+Ot.clipTop+Gt+Ot.clipRight+Gt+Ot.clipBottom+Gt+Ot.clipLeft+")",et=this.format(et).split(",").join(Gt)):(ht=this.format(dt(V,this.p,f,!1,this.dflt)),et=this.format(et)),this.parseComplex(V.style,ht,et,j,St)}}),zi("textShadow",{defaultValue:"0px 0px 0px #999",color:!0,multi:!0}),zi("autoRound,strictUnits",{parser:function(V,et,lt,at,j){return j}}),zi("border",{defaultValue:"0px solid #000",parser:function(V,et,lt,at,j,St){var ht=dt(V,"borderTopWidth",f,!1,"0px"),Ot=this.format(et).split(" "),Gt=Ot[0].replace(F,"");return Gt!=="px"&&(ht=parseFloat(ht)/pt(V,"borderTopWidth",1,Gt)+Gt),this.parseComplex(V.style,this.format(ht+" "+dt(V,"borderTopStyle",f,!1,"solid")+" "+dt(V,"borderTopColor",f,!1,"#000")),Ot.join(" "),j,St)},color:!0,formatter:function(V){var et=V.split(" ");return et[0]+" "+(et[1]||"solid")+" "+(V.match(we)||["#000"])[0]}}),zi("borderWidth",{parser:Ei("borderTopWidth,borderRightWidth,borderBottomWidth,borderLeftWidth")}),zi("float,cssFloat,styleFloat",{parser:function(V,et,lt,at,j,St){var ht=V.style,Ot="cssFloat"in ht?"cssFloat":"styleFloat";return new bi(ht,Ot,0,0,j,-1,lt,!1,0,ht[Ot],et)}});var Dh=function(V){var et,lt=this.t,at=lt.filter||dt(this.data,"filter")||"",j=this.s+this.c*V|0;j===100&&(at.indexOf("atrix(")===-1&&at.indexOf("radient(")===-1&&at.indexOf("oader(")===-1?(lt.removeAttribute("filter"),et=!dt(this.data,"filter")):(lt.filter=at.replace(Z,""),et=!0)),et||(this.xn1&&(lt.filter=at=at||"alpha(opacity="+j+")"),at.indexOf("pacity")===-1?j===0&&this.xn1||(lt.filter=at+" alpha(opacity="+j+")"):lt.filter=at.replace(X,"opacity="+j))};zi("opacity,alpha,autoAlpha",{defaultValue:"1",parser:function(V,et,lt,at,j,St){var ht=parseFloat(dt(V,"opacity",f,!1,"1")),Ot=V.style,Gt=lt==="autoAlpha";return typeof et=="string"&&et.charAt(1)==="="&&(et=(et.charAt(0)==="-"?-1:1)*parseFloat(et.substr(2))+ht),Gt&&ht===1&&dt(V,"visibility",f)==="hidden"&&et!==0&&(ht=0),pi?j=new bi(Ot,"opacity",ht,et-ht,j):(j=new bi(Ot,"opacity",100*ht,100*(et-ht),j),j.xn1=Gt?1:0,Ot.zoom=1,j.type=2,j.b="alpha(opacity="+j.s+")",j.e="alpha(opacity="+(j.s+j.c)+")",j.data=V,j.plugin=St,j.setRatio=Dh),Gt&&(j=new bi(Ot,"visibility",0,0,j,-1,null,!1,0,ht!==0?"inherit":"hidden",et===0?"hidden":"inherit"),j.xs0="inherit",at._overwriteProps.push(j.n),at._overwriteProps.push(lt)),j}});var ys=function(V,et){et&&(V.removeProperty?((et.substr(0,2)==="ms"||et.substr(0,6)==="webkit")&&(et="-"+et),V.removeProperty(et.replace(Rt,"-$1").toLowerCase())):V.removeAttribute(et))},_s=function(V){if(this.t._gsClassPT=this,V===1||V===0){this.t.setAttribute("class",V===0?this.b:this.e);for(var et=this.data,lt=this.t.style;et;)et.v?lt[et.p]=et.v:ys(lt,et.p),et=et._next;V===1&&this.t._gsClassPT===this&&(this.t._gsClassPT=null)}else this.t.getAttribute("class")!==this.e&&this.t.setAttribute("class",this.e)};zi("className",{parser:function(V,et,lt,at,j,St,ht){var Ot,Gt,zt,Mt,he,se=V.getAttribute("class")||"",te=V.style.cssText;if(j=at._classNamePT=new bi(V,lt,0,0,j,2),j.setRatio=_s,j.pr=-11,o=!0,j.b=se,Gt=ie(V,f),zt=V._gsClassPT){for(Mt={},he=zt.data;he;)Mt[he.p]=1,he=he._next;zt.setRatio(1)}return V._gsClassPT=j,j.e=et.charAt(1)!=="="?et:se.replace(new RegExp("(?:\\s|^)"+et.substr(2)+"(?![\\w-])"),"")+(et.charAt(0)==="+"?" "+et.substr(2):""),V.setAttribute("class",j.e),Ot=Kt(V,Gt,ie(V),ht,Mt),V.setAttribute("class",se),j.data=Ot.firstMPT,V.style.cssText=te,j=j.xfirst=at.parse(V,Ot.difs,j,St)}});var Xl=function(V){if((V===1||V===0)&&this.data._totalTime===this.data._totalDuration&&this.data.data!=="isFromStart"){var et,lt,at,j,St,ht=this.t.style,Ot=v.transform.parse;if(this.e==="all")ht.cssText="",j=!0;else for(et=this.e.split(" ").join("").split(","),at=et.length;--at>-1;)lt=et[at],v[lt]&&(v[lt].parse===Ot?j=!0:lt=lt==="transformOrigin"?vs:v[lt].p),ys(ht,lt);j&&(ys(ht,Mn),St=this.t._gsTransform,St&&(St.svg&&(this.t.removeAttribute("data-svg-origin"),this.t.removeAttribute("transform")),delete this.t._gsTransform))}};for(zi("clearProps",{parser:function(V,et,lt,at,j){return j=new bi(V,lt,0,0,j,2),j.setRatio=Xl,j.e=et,j.pr=-10,j.data=at._tween,o=!0,j}}),S="bezier,throwProps,physicsProps,physics2D".split(","),sn=S.length;sn--;)Yo(S[sn]);S=m.prototype,S._firstPT=S._lastParsedTransform=S._transform=null,S._onInitTween=function(V,et,lt,at){if(!V.nodeType)return!1;this._target=P=V,this._tween=lt,this._vars=et,w=at,b=et.autoRound,o=!1,c=et.suffixMap||m.suffixMap,f=jt(V,""),u=this._overwriteProps;var j,St,ht,Ot,Gt,zt,Mt,he,se,te=V.style;if(O&&te.zIndex===""&&(j=dt(V,"zIndex",f),(j==="auto"||j==="")&&this._addLazySet(te,"zIndex",0)),typeof et=="string"&&(Ot=te.cssText,j=ie(V,f),te.cssText=Ot+";"+et,j=Kt(V,j,ie(V)).difs,!pi&&K.test(et)&&(j.opacity=parseFloat(RegExp.$1)),et=j,te.cssText=Ot),et.className?this._firstPT=St=v.className.parse(V,et.className,"className",this,null,null,et):this._firstPT=St=this.parse(V,et,null),this._transformType){for(se=this._transformType===3,Mn?k&&(O=!0,te.zIndex===""&&(Mt=dt(V,"zIndex",f),(Mt==="auto"||Mt==="")&&this._addLazySet(te,"zIndex",0)),N&&this._addLazySet(te,"WebkitBackfaceVisibility",this._vars.WebkitBackfaceVisibility||(se?"visible":"hidden"))):te.zoom=1,ht=St;ht&&ht._next;)ht=ht._next;he=new bi(V,"transform",0,0,null,2),this._linkCSSP(he,null,ht),he.setRatio=Mn?Ih:jl,he.data=this._transform||uo(V,f,!0),he.tween=lt,he.pr=-1,u.pop()}if(o){for(;St;){for(zt=St._next,ht=Ot;ht&&ht.pr>St.pr;)ht=ht._next;(St._prev=ht?ht._prev:Gt)?St._prev._next=St:Ot=St,(St._next=ht)?ht._prev=St:Gt=St,St=zt}this._firstPT=Ot}return!0},S.parse=function(V,et,lt,at){var j,St,ht,Ot,Gt,zt,Mt,he,se,te,ye=V.style;for(j in et){if(zt=et[j],typeof zt=="function"&&(zt=zt(w,P)),St=v[j])lt=St.parse(V,zt,j,this,lt,at,et);else{if(j.substr(0,2)==="--"){this._tween._propLookup[j]=this._addTween.call(this._tween,V.style,"setProperty",jt(V).getPropertyValue(j)+"",zt+"",j,!1,j);continue}Gt=dt(V,j,f)+"",se=typeof zt=="string",j==="color"||j==="fill"||j==="stroke"||j.indexOf("Color")!==-1||se&&ct.test(zt)?(se||(zt=Ie(zt),zt=(zt.length>3?"rgba(":"rgb(")+zt.join(",")+")"),lt=sr(ye,j,Gt,zt,!0,"transparent",lt,0,at)):se&&re.test(zt)?lt=sr(ye,j,Gt,zt,!0,null,lt,0,at):(ht=parseFloat(Gt),Mt=ht||ht===0?Gt.substr((ht+"").length):"",(Gt===""||Gt==="auto")&&(j==="width"||j==="height"?(ht=st(V,j,f),Mt="px"):j==="left"||j==="top"?(ht=Dt(V,j,f),Mt="px"):(ht=j!=="opacity"?0:1,Mt="")),te=se&&zt.charAt(1)==="=",te?(Ot=parseInt(zt.charAt(0)+"1",10),zt=zt.substr(2),Ot*=parseFloat(zt),he=zt.replace(F,"")):(Ot=parseFloat(zt),he=se?zt.replace(F,""):""),he===""&&(he=j in c?c[j]:Mt),zt=Ot||Ot===0?(te?Ot+ht:Ot)+he:et[j],Mt!==he&&(he!==""||j==="lineHeight")&&(Ot||Ot===0)&&ht&&(ht=pt(V,j,ht,Mt),he==="%"?(ht/=pt(V,j,100,"%")/100,et.strictUnits!==!0&&(Gt=ht+"%")):he==="em"||he==="rem"||he==="vw"||he==="vh"?ht/=pt(V,j,1,he):he!=="px"&&(Ot=pt(V,j,Ot,he),he="px"),te&&(Ot||Ot===0)&&(zt=Ot+ht+he)),te&&(Ot+=ht),!ht&&ht!==0||!Ot&&Ot!==0?ye[j]!==void 0&&(zt||zt+""!="NaN"&&zt!=null)?(lt=new bi(ye,j,Ot||ht||0,0,lt,-1,j,!1,0,Gt,zt),lt.xs0=zt!=="none"||j!=="display"&&j.indexOf("Style")===-1?zt:Gt):mn("invalid "+j+" tween value: "+et[j]):(lt=new bi(ye,j,ht,Ot-ht,lt,0,j,b!==!1&&(he==="px"||j==="zIndex"),0,Gt,zt),lt.xs0=he))}at&<&&!lt.plugin&&(lt.plugin=at)}return lt},S.setRatio=function(V){var et,lt,at,j=this._firstPT,St=1e-6;if(V!==1||this._tween._time!==this._tween._duration&&this._tween._time!==0)if(V||this._tween._time!==this._tween._duration&&this._tween._time!==0||this._tween._rawPrevTime===-1e-6)for(;j;){if(et=j.c*V+j.s,j.r?et=j.r(et):St>et&&et>-St&&(et=0),j.type)if(j.type===1)if(at=j.l,at===2)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2;else if(at===3)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2+j.xn2+j.xs3;else if(at===4)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2+j.xn2+j.xs3+j.xn3+j.xs4;else if(at===5)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2+j.xn2+j.xs3+j.xn3+j.xs4+j.xn4+j.xs5;else{for(lt=j.xs0+et+j.xs1,at=1;at<j.l;at++)lt+=j["xn"+at]+j["xs"+(at+1)];j.t[j.p]=lt}else j.type===-1?j.t[j.p]=j.xs0:j.setRatio&&j.setRatio(V);else j.t[j.p]=et+j.xs0;j=j._next}else for(;j;)j.type!==2?j.t[j.p]=j.b:j.setRatio(V),j=j._next;else for(;j;){if(j.type!==2)if(j.r&&j.type!==-1)if(et=j.r(j.s+j.c),j.type){if(j.type===1){for(at=j.l,lt=j.xs0+et+j.xs1,at=1;at<j.l;at++)lt+=j["xn"+at]+j["xs"+(at+1)];j.t[j.p]=lt}}else j.t[j.p]=et+j.xs0;else j.t[j.p]=j.e;else j.setRatio(V);j=j._next}},S._enableTransforms=function(V){this._transform=this._transform||uo(this._target,f,!0),this._transformType=this._transform.svg&&ao||!V&&this._transformType!==3?2:3};var ql=function(V){this.t[this.p]=this.e,this.data._linkCSSP(this,this._next,null,!0)};S._addLazySet=function(V,et,lt){var at=this._firstPT=new bi(V,et,0,0,this._firstPT,2);at.e=lt,at.setRatio=ql,at.data=this},S._linkCSSP=function(V,et,lt,at){return V&&(et&&(et._prev=V),V._next&&(V._next._prev=V._prev),V._prev?V._prev._next=V._next:this._firstPT===V&&(this._firstPT=V._next,at=!0),lt?lt._next=V:at||this._firstPT!==null||(this._firstPT=V),V._next=et,V._prev=lt),V},S._mod=function(V){for(var et=this._firstPT;et;)typeof V[et.p]=="function"&&(et.r=V[et.p]),et=et._next},S._kill=function(V){var et,lt,at,j=V;if(V.autoAlpha||V.alpha){j={};for(lt in V)j[lt]=V[lt];j.opacity=1,j.autoAlpha&&(j.visibility=1)}for(V.className&&(et=this._classNamePT)&&(at=et.xfirst,at&&at._prev?this._linkCSSP(at._prev,et._next,at._prev._prev):at===this._firstPT&&(this._firstPT=et._next),et._next&&this._linkCSSP(et._next,et._next._next,at._prev),this._classNamePT=null),et=this._firstPT;et;)et.plugin&&et.plugin!==lt&&et.plugin._kill&&(et.plugin._kill(V),lt=et.plugin),et=et._next;return x.prototype._kill.call(this,j)};var Yr=function(V,et,lt){var at,j,St,ht;if(V.slice)for(j=V.length;--j>-1;)Yr(V[j],et,lt);else for(at=V.childNodes,j=at.length;--j>-1;)St=at[j],ht=St.type,St.style&&(et.push(ie(St)),lt&<.push(St)),ht!==1&&ht!==9&&ht!==11||!St.childNodes.length||Yr(St,et,lt)};return m.cascadeTo=function(V,et,lt){var at,j,St,ht,Ot=a.to(V,et,lt),Gt=[Ot],zt=[],Mt=[],he=[],se=a._internals.reservedProps;for(V=Ot._targets||Ot.target,Yr(V,zt,he),Ot.render(et,!0,!0),Yr(V,Mt),Ot.render(0,!0,!0),Ot._enabled(!0),at=he.length;--at>-1;)if(j=Kt(he[at],zt[at],Mt[at]),j.firstMPT){j=j.difs;for(St in lt)se[St]&&(j[St]=lt[St]);ht={};for(St in j)ht[St]=zt[at][St];Gt.push(a.fromTo(he[at],et,ht,j))}return Gt},x.activate([m]),m},!0),function(){var x=ln._gsDefine.plugin({propName:"roundProps",version:"1.7.0",priority:-1,API:2,init:function(f,u,m){return this._tween=m,!0}}),a=function(f){var u=1>f?Math.pow(10,(f+"").length-2):1;return function(m){return(Math.round(m/f)*f*u|0)/u}},o=function(f,u){for(;f;)f.f||f.blob||(f.m=u||Math.round),f=f._next},c=x.prototype;c._onInitAllProps=function(){var f,u,m,g,v=this._tween,S=v.vars.roundProps,b={},O=v._propLookup.roundProps;if(typeof S!="object"||S.push)for(typeof S=="string"&&(S=S.split(",")),m=S.length;--m>-1;)b[S[m]]=Math.round;else for(g in S)b[g]=a(S[g]);for(g in b)for(f=v._firstPT;f;)u=f._next,f.pg?f.t._mod(b):f.n===g&&(f.f===2&&f.t?o(f.t._firstPT,b[g]):(this._add(f.t,g,f.s,f.c,b[g]),u&&(u._prev=f._prev),f._prev?f._prev._next=u:v._firstPT===f&&(v._firstPT=u),f._next=f._prev=null,v._propLookup[g]=O)),f=u;return!1},c._add=function(f,u,m,g,v){this._addTween(f,u,m,m+g,u,v||Math.round),this._overwriteProps.push(u)}}(),function(){ln._gsDefine.plugin({propName:"attr",API:2,version:"0.6.1",init:function(x,a,o,c){var f,u;if(typeof x.setAttribute!="function")return!1;for(f in a)u=a[f],typeof u=="function"&&(u=u(c,x)),this._addTween(x,"setAttribute",x.getAttribute(f)+"",u+"",f,!1,f),this._overwriteProps.push(f);return!0}})}(),ln._gsDefine.plugin({propName:"directionalRotation",version:"0.3.1",API:2,init:function(x,a,o,c){typeof a!="object"&&(a={rotation:a}),this.finals={};var f,u,m,g,v,S,b=a.useRadians===!0?2*Math.PI:360,O=1e-6;for(f in a)f!=="useRadians"&&(g=a[f],typeof g=="function"&&(g=g(c,x)),S=(g+"").split("_"),u=S[0],m=parseFloat(typeof x[f]!="function"?x[f]:x[f.indexOf("set")||typeof x["get"+f.substr(3)]!="function"?f:"get"+f.substr(3)]()),g=this.finals[f]=typeof u=="string"&&u.charAt(1)==="="?m+parseInt(u.charAt(0)+"1",10)*Number(u.substr(2)):Number(u)||0,v=g-m,S.length&&(u=S.join("_"),u.indexOf("short")!==-1&&(v%=b,v!==v%(b/2)&&(v=0>v?v+b:v-b)),u.indexOf("_cw")!==-1&&0>v?v=(v+9999999999*b)%b-(v/b|0)*b:u.indexOf("ccw")!==-1&&v>0&&(v=(v-9999999999*b)%b-(v/b|0)*b)),(v>O||-O>v)&&(this._addTween(x,f,m,m+v,f),this._overwriteProps.push(f)));return!0},set:function(x){var a;if(x!==1)this._super.setRatio.call(this,x);else for(a=this._firstPT;a;)a.f?a.t[a.p](this.finals[a.p]):a.t[a.p]=this.finals[a.p],a=a._next}})._autoCSS=!0,ln._gsDefine("easing.Back",["easing.Ease"],function(x){var a,o,c,f,u=ln.GreenSockGlobals||ln,m=u.com.greensock,g=2*Math.PI,v=Math.PI/2,S=m._class,b=function(M,R){var C=S("easing."+M,function(){},!0),U=C.prototype=new x;return U.constructor=C,U.getRatio=R,C},O=x.register||function(){},k=function(M,R,C,U,F){var X=S("easing."+M,{easeOut:new R,easeIn:new C,easeInOut:new U},!0);return O(X,M),X},I=function(M,R,C){this.t=M,this.v=R,C&&(this.next=C,C.prev=this,this.c=C.v-R,this.gap=C.t-M)},N=function(M,R){var C=S("easing."+M,function(F){this._p1=F||F===0?F:1.70158,this._p2=1.525*this._p1},!0),U=C.prototype=new x;return U.constructor=C,U.getRatio=R,U.config=function(F){return new C(F)},C},E=k("Back",N("BackOut",function(M){return(M-=1)*M*((this._p1+1)*M+this._p1)+1}),N("BackIn",function(M){return M*M*((this._p1+1)*M-this._p1)}),N("BackInOut",function(M){return(M*=2)<1?.5*M*M*((this._p2+1)*M-this._p2):.5*((M-=2)*M*((this._p2+1)*M+this._p2)+2)})),P=S("easing.SlowMo",function(M,R,C){R=R||R===0?R:.7,M==null?M=.7:M>1&&(M=1),this._p=M!==1?R:0,this._p1=(1-M)/2,this._p2=M,this._p3=this._p1+this._p2,this._calcEnd=C===!0},!0),w=P.prototype=new x;return w.constructor=P,w.getRatio=function(M){var R=M+(.5-M)*this._p;return M<this._p1?this._calcEnd?1-(M=1-M/this._p1)*M:R-(M=1-M/this._p1)*M*M*M*R:M>this._p3?this._calcEnd?M===1?0:1-(M=(M-this._p3)/this._p1)*M:R+(M-R)*(M=(M-this._p3)/this._p1)*M*M*M:this._calcEnd?1:R},P.ease=new P(.7,.7),w.config=P.config=function(M,R,C){return new P(M,R,C)},a=S("easing.SteppedEase",function(M,R){M=M||1,this._p1=1/M,this._p2=M+(R?0:1),this._p3=R?1:0},!0),w=a.prototype=new x,w.constructor=a,w.getRatio=function(M){return 0>M?M=0:M>=1&&(M=.999999999),((this._p2*M|0)+this._p3)*this._p1},w.config=a.config=function(M,R){return new a(M,R)},o=S("easing.ExpoScaleEase",function(M,R,C){this._p1=Math.log(R/M),this._p2=R-M,this._p3=M,this._ease=C},!0),w=o.prototype=new x,w.constructor=o,w.getRatio=function(M){return this._ease&&(M=this._ease.getRatio(M)),(this._p3*Math.exp(this._p1*M)-this._p3)/this._p2},w.config=o.config=function(M,R,C){return new o(M,R,C)},c=S("easing.RoughEase",function(M){M=M||{};for(var R,C,U,F,X,K,Z=M.taper||"none",ct=[],Rt=0,tt=0|(M.points||20),_t=tt,G=M.randomize!==!1,Pt=M.clamp===!0,Et=M.template instanceof x?M.template:null,At=typeof M.strength=="number"?.4*M.strength:.4;--_t>-1;)R=G?Math.random():1/tt*_t,C=Et?Et.getRatio(R):R,Z==="none"?U=At:Z==="out"?(F=1-R,U=F*F*At):Z==="in"?U=R*R*At:.5>R?(F=2*R,U=F*F*.5*At):(F=2*(1-R),U=F*F*.5*At),G?C+=Math.random()*U-.5*U:_t%2?C+=.5*U:C-=.5*U,Pt&&(C>1?C=1:0>C&&(C=0)),ct[Rt++]={x:R,y:C};for(ct.sort(function(ce,re){return ce.x-re.x}),K=new I(1,1,null),_t=tt;--_t>-1;)X=ct[_t],K=new I(X.x,X.y,K);this._prev=new I(0,0,K.t!==0?K:K.next)},!0),w=c.prototype=new x,w.constructor=c,w.getRatio=function(M){var R=this._prev;if(M>R.t){for(;R.next&&M>=R.t;)R=R.next;R=R.prev}else for(;R.prev&&M<=R.t;)R=R.prev;return this._prev=R,R.v+(M-R.t)/R.gap*R.c},w.config=function(M){return new c(M)},c.ease=new c,k("Bounce",b("BounceOut",function(M){return 1/2.75>M?7.5625*M*M:2/2.75>M?7.5625*(M-=1.5/2.75)*M+.75:2.5/2.75>M?7.5625*(M-=2.25/2.75)*M+.9375:7.5625*(M-=2.625/2.75)*M+.984375}),b("BounceIn",function(M){return(M=1-M)<1/2.75?1-7.5625*M*M:2/2.75>M?1-(7.5625*(M-=1.5/2.75)*M+.75):2.5/2.75>M?1-(7.5625*(M-=2.25/2.75)*M+.9375):1-(7.5625*(M-=2.625/2.75)*M+.984375)}),b("BounceInOut",function(M){var R=.5>M;return M=R?1-2*M:2*M-1,M=1/2.75>M?7.5625*M*M:2/2.75>M?7.5625*(M-=1.5/2.75)*M+.75:2.5/2.75>M?7.5625*(M-=2.25/2.75)*M+.9375:7.5625*(M-=2.625/2.75)*M+.984375,R?.5*(1-M):.5*M+.5})),k("Circ",b("CircOut",function(M){return Math.sqrt(1-(M-=1)*M)}),b("CircIn",function(M){return-(Math.sqrt(1-M*M)-1)}),b("CircInOut",function(M){return(M*=2)<1?-.5*(Math.sqrt(1-M*M)-1):.5*(Math.sqrt(1-(M-=2)*M)+1)})),f=function(M,R,C){var U=S("easing."+M,function(X,K){this._p1=X>=1?X:1,this._p2=(K||C)/(1>X?X:1),this._p3=this._p2/g*(Math.asin(1/this._p1)||0),this._p2=g/this._p2},!0),F=U.prototype=new x;return F.constructor=U,F.getRatio=R,F.config=function(X,K){return new U(X,K)},U},k("Elastic",f("ElasticOut",function(M){return this._p1*Math.pow(2,-10*M)*Math.sin((M-this._p3)*this._p2)+1},.3),f("ElasticIn",function(M){return-(this._p1*Math.pow(2,10*(M-=1))*Math.sin((M-this._p3)*this._p2))},.3),f("ElasticInOut",function(M){return(M*=2)<1?-.5*(this._p1*Math.pow(2,10*(M-=1))*Math.sin((M-this._p3)*this._p2)):this._p1*Math.pow(2,-10*(M-=1))*Math.sin((M-this._p3)*this._p2)*.5+1},.45)),k("Expo",b("ExpoOut",function(M){return 1-Math.pow(2,-10*M)}),b("ExpoIn",function(M){return Math.pow(2,10*(M-1))-.001}),b("ExpoInOut",function(M){return(M*=2)<1?.5*Math.pow(2,10*(M-1)):.5*(2-Math.pow(2,-10*(M-1)))})),k("Sine",b("SineOut",function(M){return Math.sin(M*v)}),b("SineIn",function(M){return-Math.cos(M*v)+1}),b("SineInOut",function(M){return-.5*(Math.cos(Math.PI*M)-1)})),S("easing.EaseLookup",{find:function(M){return x.map[M]}},!0),O(u.SlowMo,"SlowMo","ease,"),O(c,"RoughEase","ease,"),O(a,"SteppedEase","ease,"),E},!0)}),ln._gsDefine&&ln._gsQueue.pop()(),function(x,a){var o={},c=x.document,f=x.GreenSockGlobals=x.GreenSockGlobals||x,u=f[a];if(u)return typeof module<"u"&&module.exports&&(module.exports=u),u;var m,g,v,S,b,O=function(z){var Q,st=z.split("."),nt=f;for(Q=0;Q<st.length;Q++)nt[st[Q]]=nt=nt[st[Q]]||{};return nt},k=O("com.greensock"),I=1e-10,N=function(z){var Q,st=[],nt=z.length;for(Q=0;Q!==nt;st.push(z[Q++]));return st},E=function(){},P=function(){var z=Object.prototype.toString,Q=z.call([]);return function(st){return st!=null&&(st instanceof Array||typeof st=="object"&&!!st.push&&z.call(st)===Q)}}(),w={},M=function(z,Q,st,nt){this.sc=w[z]?w[z].sc:[],w[z]=this,this.gsClass=null,this.func=st;var vt=[];this.check=function(Ut){for(var qt,Xt,Ne,Ie,me=Q.length,we=me;--me>-1;)(qt=w[Q[me]]||new M(Q[me],[])).gsClass?(vt[me]=qt.gsClass,we--):Ut&&qt.sc.push(this);if(we===0&&st){if(Xt=("com.greensock."+z).split("."),Ne=Xt.pop(),Ie=O(Xt.join("."))[Ne]=this.gsClass=st.apply(st,vt),nt)if(f[Ne]=o[Ne]=Ie,typeof module<"u"&&module.exports)if(z===a){module.exports=o[a]=Ie;for(me in o)Ie[me]=o[me]}else o[a]&&(o[a][Ne]=Ie);else typeof define=="function"&&define.amd&&define((x.GreenSockAMDPath?x.GreenSockAMDPath+"/":"")+z.split(".").pop(),[],function(){return Ie});for(me=0;me<this.sc.length;me++)this.sc[me].check()}},this.check(!0)},R=x._gsDefine=function(z,Q,st,nt){return new M(z,Q,st,nt)},C=k._class=function(z,Q,st){return Q=Q||function(){},R(z,[],function(){return Q},st),Q};R.globals=f;var U=[0,0,1,1],F=C("easing.Ease",function(z,Q,st,nt){this._func=z,this._type=st||0,this._power=nt||0,this._params=Q?U.concat(Q):U},!0),X=F.map={},K=F.register=function(z,Q,st,nt){for(var vt,Ut,qt,Xt,Ne=Q.split(","),Ie=Ne.length,me=(st||"easeIn,easeOut,easeInOut").split(",");--Ie>-1;)for(Ut=Ne[Ie],vt=nt?C("easing."+Ut,null,!0):k.easing[Ut]||{},qt=me.length;--qt>-1;)Xt=me[qt],X[Ut+"."+Xt]=X[Xt+Ut]=vt[Xt]=z.getRatio?z:z[Xt]||new z};for(v=F.prototype,v._calcEnd=!1,v.getRatio=function(z){if(this._func)return this._params[0]=z,this._func.apply(null,this._params);var Q=this._type,st=this._power,nt=Q===1?1-z:Q===2?z:.5>z?2*z:2*(1-z);return st===1?nt*=nt:st===2?nt*=nt*nt:st===3?nt*=nt*nt*nt:st===4&&(nt*=nt*nt*nt*nt),Q===1?1-nt:Q===2?nt:.5>z?nt/2:1-nt/2},m=["Linear","Quad","Cubic","Quart","Quint,Strong"],g=m.length;--g>-1;)v=m[g]+",Power"+g,K(new F(null,null,1,g),v,"easeOut",!0),K(new F(null,null,2,g),v,"easeIn"+(g===0?",easeNone":"")),K(new F(null,null,3,g),v,"easeInOut");X.linear=k.easing.Linear.easeIn,X.swing=k.easing.Quad.easeInOut;var Z=C("events.EventDispatcher",function(z){this._listeners={},this._eventTarget=z||this});v=Z.prototype,v.addEventListener=function(z,Q,st,nt,vt){vt=vt||0;var Ut,qt,Xt=this._listeners[z],Ne=0;for(this!==S||b||S.wake(),Xt==null&&(this._listeners[z]=Xt=[]),qt=Xt.length;--qt>-1;)Ut=Xt[qt],Ut.c===Q&&Ut.s===st?Xt.splice(qt,1):Ne===0&&Ut.pr<vt&&(Ne=qt+1);Xt.splice(Ne,0,{c:Q,s:st,up:nt,pr:vt})},v.removeEventListener=function(z,Q){var st,nt=this._listeners[z];if(nt){for(st=nt.length;--st>-1;)if(nt[st].c===Q)return void nt.splice(st,1)}},v.dispatchEvent=function(z){var Q,st,nt,vt=this._listeners[z];if(vt)for(Q=vt.length,Q>1&&(vt=vt.slice(0)),st=this._eventTarget;--Q>-1;)nt=vt[Q],nt&&(nt.up?nt.c.call(nt.s||st,{type:z,target:st}):nt.c.call(nt.s||st))};var ct=x.requestAnimationFrame,Rt=x.cancelAnimationFrame,tt=Date.now||function(){return new Date().getTime()},_t=tt();for(m=["ms","moz","webkit","o"],g=m.length;--g>-1&&!ct;)ct=x[m[g]+"RequestAnimationFrame"],Rt=x[m[g]+"CancelAnimationFrame"]||x[m[g]+"CancelRequestAnimationFrame"];C("Ticker",function(z,Q){var st,nt,vt,Ut,qt,Xt=this,Ne=tt(),Ie=Q!==!1&&ct?"auto":!1,me=500,we=33,yi="tick",Ei=function(ni){var bi,qr,sr=tt()-_t;sr>me&&(Ne+=sr-we),_t+=sr,Xt.time=(_t-Ne)/1e3,bi=Xt.time-qt,(!st||bi>0||ni===!0)&&(Xt.frame++,qt+=bi+(bi>=Ut?.004:Ut-bi),qr=!0),ni!==!0&&(vt=nt(Ei)),qr&&Xt.dispatchEvent(yi)};Z.call(Xt),Xt.time=Xt.frame=0,Xt.tick=function(){Ei(!0)},Xt.lagSmoothing=function(ni,bi){return arguments.length?(me=ni||1/I,void(we=Math.min(bi,me,0))):1/I>me},Xt.sleep=function(){vt!=null&&(Ie&&Rt?Rt(vt):clearTimeout(vt),nt=E,vt=null,Xt===S&&(b=!1))},Xt.wake=function(ni){vt!==null?Xt.sleep():ni?Ne+=-_t+(_t=tt()):Xt.frame>10&&(_t=tt()-me+5),nt=st===0?E:Ie&&ct?ct:function(bi){return setTimeout(bi,1e3*(qt-Xt.time)+1|0)},Xt===S&&(b=!0),Ei(2)},Xt.fps=function(ni){return arguments.length?(st=ni,Ut=1/(st||60),qt=this.time+Ut,void Xt.wake()):st},Xt.useRAF=function(ni){return arguments.length?(Xt.sleep(),Ie=ni,void Xt.fps(st)):Ie},Xt.fps(z),setTimeout(function(){Ie==="auto"&&Xt.frame<5&&(c||{}).visibilityState!=="hidden"&&Xt.useRAF(!1)},1500)}),v=k.Ticker.prototype=new k.events.EventDispatcher,v.constructor=k.Ticker;var G=C("core.Animation",function(z,Q){if(this.vars=Q=Q||{},this._duration=this._totalDuration=z||0,this._delay=Number(Q.delay)||0,this._timeScale=1,this._active=Q.immediateRender===!0,this.data=Q.data,this._reversed=Q.reversed===!0,W){b||S.wake();var st=this.vars.useFrames?Qi:W;st.add(this,st._time),this.vars.paused&&this.paused(!0)}});S=G.ticker=new k.Ticker,v=G.prototype,v._dirty=v._gc=v._initted=v._paused=!1,v._totalTime=v._time=0,v._rawPrevTime=-1,v._next=v._last=v._onUpdate=v._timeline=v.timeline=null,v._paused=!1;var Pt=function(){b&&tt()-_t>2e3&&((c||{}).visibilityState!=="hidden"||!S.lagSmoothing())&&S.wake();var z=setTimeout(Pt,2e3);z.unref&&z.unref()};Pt(),v.play=function(z,Q){return z!=null&&this.seek(z,Q),this.reversed(!1).paused(!1)},v.pause=function(z,Q){return z!=null&&this.seek(z,Q),this.paused(!0)},v.resume=function(z,Q){return z!=null&&this.seek(z,Q),this.paused(!1)},v.seek=function(z,Q){return this.totalTime(Number(z),Q!==!1)},v.restart=function(z,Q){return this.reversed(!1).paused(!1).totalTime(z?-this._delay:0,Q!==!1,!0)},v.reverse=function(z,Q){return z!=null&&this.seek(z||this.totalDuration(),Q),this.reversed(!0).paused(!1)},v.render=function(z,Q,st){},v.invalidate=function(){return this._time=this._totalTime=0,this._initted=this._gc=!1,this._rawPrevTime=-1,(this._gc||!this.timeline)&&this._enabled(!0),this},v.isActive=function(){var z,Q=this._timeline,st=this._startTime;return!Q||!this._gc&&!this._paused&&Q.isActive()&&(z=Q.rawTime(!0))>=st&&z<st+this.totalDuration()/this._timeScale-1e-7},v._enabled=function(z,Q){return b||S.wake(),this._gc=!z,this._active=this.isActive(),Q!==!0&&(z&&!this.timeline?this._timeline.add(this,this._startTime-this._delay):!z&&this.timeline&&this._timeline._remove(this,!0)),!1},v._kill=function(z,Q){return this._enabled(!1,!1)},v.kill=function(z,Q){return this._kill(z,Q),this},v._uncache=function(z){for(var Q=z?this:this.timeline;Q;)Q._dirty=!0,Q=Q.timeline;return this},v._swapSelfInParams=function(z){for(var Q=z.length,st=z.concat();--Q>-1;)z[Q]==="{self}"&&(st[Q]=this);return st},v._callback=function(z){var Q=this.vars,st=Q[z],nt=Q[z+"Params"],vt=Q[z+"Scope"]||Q.callbackScope||this,Ut=nt?nt.length:0;switch(Ut){case 0:st.call(vt);break;case 1:st.call(vt,nt[0]);break;case 2:st.call(vt,nt[0],nt[1]);break;default:st.apply(vt,nt)}},v.eventCallback=function(z,Q,st,nt){if((z||"").substr(0,2)==="on"){var vt=this.vars;if(arguments.length===1)return vt[z];Q==null?delete vt[z]:(vt[z]=Q,vt[z+"Params"]=P(st)&&st.join("").indexOf("{self}")!==-1?this._swapSelfInParams(st):st,vt[z+"Scope"]=nt),z==="onUpdate"&&(this._onUpdate=Q)}return this},v.delay=function(z){return arguments.length?(this._timeline.smoothChildTiming&&this.startTime(this._startTime+z-this._delay),this._delay=z,this):this._delay},v.duration=function(z){return arguments.length?(this._duration=this._totalDuration=z,this._uncache(!0),this._timeline.smoothChildTiming&&this._time>0&&this._time<this._duration&&z!==0&&this.totalTime(this._totalTime*(z/this._duration),!0),this):(this._dirty=!1,this._duration)},v.totalDuration=function(z){return this._dirty=!1,arguments.length?this.duration(z):this._totalDuration},v.time=function(z,Q){return arguments.length?(this._dirty&&this.totalDuration(),this.totalTime(z>this._duration?this._duration:z,Q)):this._time},v.totalTime=function(z,Q,st){if(b||S.wake(),!arguments.length)return this._totalTime;if(this._timeline){if(0>z&&!st&&(z+=this.totalDuration()),this._timeline.smoothChildTiming){this._dirty&&this.totalDuration();var nt=this._totalDuration,vt=this._timeline;if(z>nt&&!st&&(z=nt),this._startTime=(this._paused?this._pauseTime:vt._time)-(this._reversed?nt-z:z)/this._timeScale,vt._dirty||this._uncache(!1),vt._timeline)for(;vt._timeline;)vt._timeline._time!==(vt._startTime+vt._totalTime)/vt._timeScale&&vt.totalTime(vt._totalTime,!0),vt=vt._timeline}this._gc&&this._enabled(!0,!1),(this._totalTime!==z||this._duration===0)&&(Ft.length&&jt(),this.render(z,Q,!1),Ft.length&&jt())}return this},v.progress=v.totalProgress=function(z,Q){var st=this.duration();return arguments.length?this.totalTime(st*z,Q):st?this._time/st:this.ratio},v.startTime=function(z){return arguments.length?(z!==this._startTime&&(this._startTime=z,this.timeline&&this.timeline._sortChildren&&this.timeline.add(this,z-this._delay)),this):this._startTime},v.endTime=function(z){return this._startTime+(z!=0?this.totalDuration():this.duration())/this._timeScale},v.timeScale=function(z){if(!arguments.length)return this._timeScale;var Q,st;for(z=z||I,this._timeline&&this._timeline.smoothChildTiming&&(Q=this._pauseTime,st=Q||Q===0?Q:this._timeline.totalTime(),this._startTime=st-(st-this._startTime)*this._timeScale/z),this._timeScale=z,st=this.timeline;st&&st.timeline;)st._dirty=!0,st.totalDuration(),st=st.timeline;return this},v.reversed=function(z){return arguments.length?(z!=this._reversed&&(this._reversed=z,this.totalTime(this._timeline&&!this._timeline.smoothChildTiming?this.totalDuration()-this._totalTime:this._totalTime,!0)),this):this._reversed},v.paused=function(z){if(!arguments.length)return this._paused;var Q,st,nt=this._timeline;return z!=this._paused&&nt&&(b||z||S.wake(),Q=nt.rawTime(),st=Q-this._pauseTime,!z&&nt.smoothChildTiming&&(this._startTime+=st,this._uncache(!1)),this._pauseTime=z?Q:null,this._paused=z,this._active=this.isActive(),!z&&st!==0&&this._initted&&this.duration()&&(Q=nt.smoothChildTiming?this._totalTime:(Q-this._startTime)/this._timeScale,this.render(Q,Q===this._totalTime,!0))),this._gc&&!z&&this._enabled(!0,!1),this};var Et=C("core.SimpleTimeline",function(z){G.call(this,0,z),this.autoRemoveChildren=this.smoothChildTiming=!0});v=Et.prototype=new G,v.constructor=Et,v.kill()._gc=!1,v._first=v._last=v._recent=null,v._sortChildren=!1,v.add=v.insert=function(z,Q,st,nt){var vt,Ut;if(z._startTime=Number(Q||0)+z._delay,z._paused&&this!==z._timeline&&(z._pauseTime=this.rawTime()-(z._timeline.rawTime()-z._pauseTime)),z.timeline&&z.timeline._remove(z,!0),z.timeline=z._timeline=this,z._gc&&z._enabled(!0,!0),vt=this._last,this._sortChildren)for(Ut=z._startTime;vt&&vt._startTime>Ut;)vt=vt._prev;return vt?(z._next=vt._next,vt._next=z):(z._next=this._first,this._first=z),z._next?z._next._prev=z:this._last=z,z._prev=vt,this._recent=z,this._timeline&&this._uncache(!0),this},v._remove=function(z,Q){return z.timeline===this&&(Q||z._enabled(!1,!0),z._prev?z._prev._next=z._next:this._first===z&&(this._first=z._next),z._next?z._next._prev=z._prev:this._last===z&&(this._last=z._prev),z._next=z._prev=z.timeline=null,z===this._recent&&(this._recent=this._last),this._timeline&&this._uncache(!0)),this},v.render=function(z,Q,st){var nt,vt=this._first;for(this._totalTime=this._time=this._rawPrevTime=z;vt;)nt=vt._next,(vt._active||z>=vt._startTime&&!vt._paused&&!vt._gc)&&(vt._reversed?vt.render((vt._dirty?vt.totalDuration():vt._totalDuration)-(z-vt._startTime)*vt._timeScale,Q,st):vt.render((z-vt._startTime)*vt._timeScale,Q,st)),vt=nt},v.rawTime=function(){return b||S.wake(),this._totalTime};var At=C("TweenLite",function(z,Q,st){if(G.call(this,Q,st),this.render=At.prototype.render,z==null)throw"Cannot tween a null target.";this.target=z=typeof z!="string"?z:At.selector(z)||z;var nt,vt,Ut,qt=z.jquery||z.length&&z!==x&&z[0]&&(z[0]===x||z[0].nodeType&&z[0].style&&!z.nodeType),Xt=this.vars.overwrite;if(this._overwrite=Xt=Xt==null?mn[At.defaultOverwrite]:typeof Xt=="number"?Xt>>0:mn[Xt],(qt||z instanceof Array||z.push&&P(z))&&typeof z[0]!="number")for(this._targets=Ut=N(z),this._propLookup=[],this._siblings=[],nt=0;nt<Ut.length;nt++)vt=Ut[nt],vt?typeof vt!="string"?vt.length&&vt!==x&&vt[0]&&(vt[0]===x||vt[0].nodeType&&vt[0].style&&!vt.nodeType)?(Ut.splice(nt--,1),this._targets=Ut=Ut.concat(N(vt))):(this._siblings[nt]=dt(vt,this,!1),Xt===1&&this._siblings[nt].length>1&&Dt(vt,this,null,1,this._siblings[nt])):(vt=Ut[nt--]=At.selector(vt),typeof vt=="string"&&Ut.splice(nt+1,1)):Ut.splice(nt--,1);else this._propLookup={},this._siblings=dt(z,this,!1),Xt===1&&this._siblings.length>1&&Dt(z,this,null,1,this._siblings);(this.vars.immediateRender||Q===0&&this._delay===0&&this.vars.immediateRender!==!1)&&(this._time=-I,this.render(Math.min(0,-this._delay)))},!0),ce=function(z){return z&&z.length&&z!==x&&z[0]&&(z[0]===x||z[0].nodeType&&z[0].style&&!z.nodeType)},re=function(z,Q){var st,nt={};for(st in z)Di[st]||st in Q&&st!=="transform"&&st!=="x"&&st!=="y"&&st!=="width"&&st!=="height"&&st!=="className"&&st!=="border"||!(!Oe[st]||Oe[st]&&Oe[st]._autoCSS)||(nt[st]=z[st],delete z[st]);z.css=nt};v=At.prototype=new G,v.constructor=At,v.kill()._gc=!1,v.ratio=0,v._firstPT=v._targets=v._overwrittenProps=v._startAt=null,v._notifyPluginsOfEnabled=v._lazy=!1,At.version="2.0.2",At.defaultEase=v._ease=new F(null,null,1,1),At.defaultOverwrite="auto",At.ticker=S,At.autoSleep=120,At.lagSmoothing=function(z,Q){S.lagSmoothing(z,Q)},At.selector=x.$||x.jQuery||function(z){var Q=x.$||x.jQuery;return Q?(At.selector=Q,Q(z)):(c||(c=x.document),c?c.querySelectorAll?c.querySelectorAll(z):c.getElementById(z.charAt(0)==="#"?z.substr(1):z):z)};var Ft=[],It={},Nt=/(?:(-|-=|\+=)?\d*\.?\d*(?:e[\-+]?\d+)?)[0-9]/gi,Pe=/[\+-]=-?[\.\d]/,pe=function(z){for(var Q,st=this._firstPT,nt=1e-6;st;)Q=st.blob?z===1&&this.end!=null?this.end:z?this.join(""):this.start:st.c*z+st.s,st.m?Q=st.m.call(this._tween,Q,this._target||st.t,this._tween):nt>Q&&Q>-nt&&!st.blob&&(Q=0),st.f?st.fp?st.t[st.p](st.fp,Q):st.t[st.p](Q):st.t[st.p]=Q,st=st._next},Wt=function(z,Q,st,nt){var vt,Ut,qt,Xt,Ne,Ie,me,we=[],yi=0,Ei="",ni=0;for(we.start=z,we.end=Q,z=we[0]=z+"",Q=we[1]=Q+"",st&&(st(we),z=we[0],Q=we[1]),we.length=0,vt=z.match(Nt)||[],Ut=Q.match(Nt)||[],nt&&(nt._next=null,nt.blob=1,we._firstPT=we._applyPT=nt),Ne=Ut.length,Xt=0;Ne>Xt;Xt++)me=Ut[Xt],Ie=Q.substr(yi,Q.indexOf(me,yi)-yi),Ei+=Ie||!Xt?Ie:",",yi+=Ie.length,ni?ni=(ni+1)%5:Ie.substr(-5)==="rgba("&&(ni=1),me===vt[Xt]||vt.length<=Xt?Ei+=me:(Ei&&(we.push(Ei),Ei=""),qt=parseFloat(vt[Xt]),we.push(qt),we._firstPT={_next:we._firstPT,t:we,p:we.length-1,s:qt,c:(me.charAt(1)==="="?parseInt(me.charAt(0)+"1",10)*parseFloat(me.substr(2)):parseFloat(me)-qt)||0,f:0,m:ni&&4>ni?Math.round:0}),yi+=me.length;return Ei+=Q.substr(yi),Ei&&we.push(Ei),we.setRatio=pe,Pe.test(Q)&&(we.end=null),we},$e=function(z,Q,st,nt,vt,Ut,qt,Xt,Ne){typeof nt=="function"&&(nt=nt(Ne||0,z));var Ie,me=typeof z[Q],we=me!=="function"?"":Q.indexOf("set")||typeof z["get"+Q.substr(3)]!="function"?Q:"get"+Q.substr(3),yi=st!=="get"?st:we?qt?z[we](qt):z[we]():z[Q],Ei=typeof nt=="string"&&nt.charAt(1)==="=",ni={t:z,p:Q,s:yi,f:me==="function",pg:0,n:vt||Q,m:Ut?typeof Ut=="function"?Ut:Math.round:0,pr:0,c:Ei?parseInt(nt.charAt(0)+"1",10)*parseFloat(nt.substr(2)):parseFloat(nt)-yi||0};return(typeof yi!="number"||typeof nt!="number"&&!Ei)&&(qt||isNaN(yi)||!Ei&&isNaN(nt)||typeof yi=="boolean"||typeof nt=="boolean"?(ni.fp=qt,Ie=Wt(yi,Ei?parseFloat(ni.s)+ni.c+(ni.s+"").replace(/[0-9\-\.]/g,""):nt,Xt||At.defaultStringFilter,ni),ni={t:Ie,p:"setRatio",s:0,c:1,f:2,pg:0,n:vt||Q,pr:0,m:0}):(ni.s=parseFloat(yi),Ei||(ni.c=parseFloat(nt)-ni.s||0))),ni.c?((ni._next=this._firstPT)&&(ni._next._prev=ni),this._firstPT=ni,ni):void 0},Si=At._internals={isArray:P,isSelector:ce,lazyTweens:Ft,blobDif:Wt},Oe=At._plugins={},Ge=Si.tweenLookup={},pi=0,Di=Si.reservedProps={ease:1,delay:1,overwrite:1,onComplete:1,onCompleteParams:1,onCompleteScope:1,useFrames:1,runBackwards:1,startAt:1,onUpdate:1,onUpdateParams:1,onUpdateScope:1,onStart:1,onStartParams:1,onStartScope:1,onReverseComplete:1,onReverseCompleteParams:1,onReverseCompleteScope:1,onRepeat:1,onRepeatParams:1,onRepeatScope:1,easeParams:1,yoyo:1,immediateRender:1,repeat:1,repeatDelay:1,data:1,paused:1,reversed:1,autoCSS:1,lazy:1,onOverwrite:1,callbackScope:1,stringFilter:1,id:1,yoyoEase:1},mn={none:0,all:1,auto:2,concurrent:3,allOnStart:4,preexisting:5,true:1,false:0},Qi=G._rootFramesTimeline=new Et,W=G._rootTimeline=new Et,Jt=30,jt=Si.lazyRender=function(){var z,Q=Ft.length;for(It={};--Q>-1;)z=Ft[Q],z&&z._lazy!==!1&&(z.render(z._lazy[0],z._lazy[1],!0),z._lazy=!1);Ft.length=0};W._startTime=S.time,Qi._startTime=S.frame,W._active=Qi._active=!0,setTimeout(jt,1),G._updateRoot=At.render=function(){var z,Q,st;if(Ft.length&&jt(),W.render((S.time-W._startTime)*W._timeScale,!1,!1),Qi.render((S.frame-Qi._startTime)*Qi._timeScale,!1,!1),Ft.length&&jt(),S.frame>=Jt){Jt=S.frame+(parseInt(At.autoSleep,10)||120);for(st in Ge){for(Q=Ge[st].tweens,z=Q.length;--z>-1;)Q[z]._gc&&Q.splice(z,1);Q.length===0&&delete Ge[st]}if(st=W._first,(!st||st._paused)&&At.autoSleep&&!Qi._first&&S._listeners.tick.length===1){for(;st&&st._paused;)st=st._next;st||S.sleep()}}},S.addEventListener("tick",G._updateRoot);var dt=function(z,Q,st){var nt,vt,Ut=z._gsTweenID;if(Ge[Ut||(z._gsTweenID=Ut="t"+pi++)]||(Ge[Ut]={target:z,tweens:[]}),Q&&(nt=Ge[Ut].tweens,nt[vt=nt.length]=Q,st))for(;--vt>-1;)nt[vt]===Q&&nt.splice(vt,1);return Ge[Ut].tweens},pt=function(z,Q,st,nt){var vt,Ut,qt=z.vars.onOverwrite;return qt&&(vt=qt(z,Q,st,nt)),qt=At.onOverwrite,qt&&(Ut=qt(z,Q,st,nt)),vt!==!1&&Ut!==!1},Dt=function(z,Q,st,nt,vt){var Ut,qt,Xt,Ne;if(nt===1||nt>=4){for(Ne=vt.length,Ut=0;Ne>Ut;Ut++)if((Xt=vt[Ut])!==Q)Xt._gc||Xt._kill(null,z,Q)&&(qt=!0);else if(nt===5)break;return qt}var Ie,me=Q._startTime+I,we=[],yi=0,Ei=Q._duration===0;for(Ut=vt.length;--Ut>-1;)(Xt=vt[Ut])===Q||Xt._gc||Xt._paused||(Xt._timeline!==Q._timeline?(Ie=Ie||ie(Q,0,Ei),ie(Xt,Ie,Ei)===0&&(we[yi++]=Xt)):Xt._startTime<=me&&Xt._startTime+Xt.totalDuration()/Xt._timeScale>me&&((Ei||!Xt._initted)&&me-Xt._startTime<=2e-10||(we[yi++]=Xt)));for(Ut=yi;--Ut>-1;)if(Xt=we[Ut],Ne=Xt._firstPT,nt===2&&Xt._kill(st,z,Q)&&(qt=!0),nt!==2||!Xt._firstPT&&Xt._initted&&Ne){if(nt!==2&&!pt(Xt,Q))continue;Xt._enabled(!1,!1)&&(qt=!0)}return qt},ie=function(z,Q,st){for(var nt=z._timeline,vt=nt._timeScale,Ut=z._startTime;nt._timeline;){if(Ut+=nt._startTime,vt*=nt._timeScale,nt._paused)return-100;nt=nt._timeline}return Ut/=vt,Ut>Q?Ut-Q:st&&Ut===Q||!z._initted&&2*I>Ut-Q?I:(Ut+=z.totalDuration()/z._timeScale/vt)>Q+I?0:Ut-Q-I};v._init=function(){var z,Q,st,nt,vt,Ut,qt=this.vars,Xt=this._overwrittenProps,Ne=this._duration,Ie=!!qt.immediateRender,me=qt.ease;if(qt.startAt){this._startAt&&(this._startAt.render(-1,!0),this._startAt.kill()),vt={};for(nt in qt.startAt)vt[nt]=qt.startAt[nt];if(vt.data="isStart",vt.overwrite=!1,vt.immediateRender=!0,vt.lazy=Ie&&qt.lazy!==!1,vt.startAt=vt.delay=null,vt.onUpdate=qt.onUpdate,vt.onUpdateParams=qt.onUpdateParams,vt.onUpdateScope=qt.onUpdateScope||qt.callbackScope||this,this._startAt=At.to(this.target||{},0,vt),Ie){if(this._time>0)this._startAt=null;else if(Ne!==0)return}}else if(qt.runBackwards&&Ne!==0)if(this._startAt)this._startAt.render(-1,!0),this._startAt.kill(),this._startAt=null;else{this._time!==0&&(Ie=!1),st={};for(nt in qt)Di[nt]&&nt!=="autoCSS"||(st[nt]=qt[nt]);if(st.overwrite=0,st.data="isFromStart",st.lazy=Ie&&qt.lazy!==!1,st.immediateRender=Ie,this._startAt=At.to(this.target,0,st),Ie){if(this._time===0)return}else this._startAt._init(),this._startAt._enabled(!1),this.vars.immediateRender&&(this._startAt=null)}if(this._ease=me=me?me instanceof F?me:typeof me=="function"?new F(me,qt.easeParams):X[me]||At.defaultEase:At.defaultEase,qt.easeParams instanceof Array&&me.config&&(this._ease=me.config.apply(me,qt.easeParams)),this._easeType=this._ease._type,this._easePower=this._ease._power,this._firstPT=null,this._targets)for(Ut=this._targets.length,z=0;Ut>z;z++)this._initProps(this._targets[z],this._propLookup[z]={},this._siblings[z],Xt?Xt[z]:null,z)&&(Q=!0);else Q=this._initProps(this.target,this._propLookup,this._siblings,Xt,0);if(Q&&At._onPluginEvent("_onInitAllProps",this),Xt&&(this._firstPT||typeof this.target!="function"&&this._enabled(!1,!1)),qt.runBackwards)for(st=this._firstPT;st;)st.s+=st.c,st.c=-st.c,st=st._next;this._onUpdate=qt.onUpdate,this._initted=!0},v._initProps=function(z,Q,st,nt,vt){var Ut,qt,Xt,Ne,Ie,me;if(z==null)return!1;It[z._gsTweenID]&&jt(),this.vars.css||z.style&&z!==x&&z.nodeType&&Oe.css&&this.vars.autoCSS!==!1&&re(this.vars,z);for(Ut in this.vars)if(me=this.vars[Ut],Di[Ut])me&&(me instanceof Array||me.push&&P(me))&&me.join("").indexOf("{self}")!==-1&&(this.vars[Ut]=me=this._swapSelfInParams(me,this));else if(Oe[Ut]&&(Ne=new Oe[Ut])._onInitTween(z,this.vars[Ut],this,vt)){for(this._firstPT=Ie={_next:this._firstPT,t:Ne,p:"setRatio",s:0,c:1,f:1,n:Ut,pg:1,pr:Ne._priority,m:0},qt=Ne._overwriteProps.length;--qt>-1;)Q[Ne._overwriteProps[qt]]=this._firstPT;(Ne._priority||Ne._onInitAllProps)&&(Xt=!0),(Ne._onDisable||Ne._onEnable)&&(this._notifyPluginsOfEnabled=!0),Ie._next&&(Ie._next._prev=Ie)}else Q[Ut]=$e.call(this,z,Ut,"get",me,Ut,0,null,this.vars.stringFilter,vt);return nt&&this._kill(nt,z)?this._initProps(z,Q,st,nt,vt):this._overwrite>1&&this._firstPT&&st.length>1&&Dt(z,this,Q,this._overwrite,st)?(this._kill(Q,z),this._initProps(z,Q,st,nt,vt)):(this._firstPT&&(this.vars.lazy!==!1&&this._duration||this.vars.lazy&&!this._duration)&&(It[z._gsTweenID]=!0),Xt)},v.render=function(z,Q,st){var nt,vt,Ut,qt,Xt=this._time,Ne=this._duration,Ie=this._rawPrevTime;if(z>=Ne-1e-7&&z>=0)this._totalTime=this._time=Ne,this.ratio=this._ease._calcEnd?this._ease.getRatio(1):1,this._reversed||(nt=!0,vt="onComplete",st=st||this._timeline.autoRemoveChildren),Ne===0&&(this._initted||!this.vars.lazy||st)&&(this._startTime===this._timeline._duration&&(z=0),(0>Ie||0>=z&&z>=-1e-7||Ie===I&&this.data!=="isPause")&&Ie!==z&&(st=!0,Ie>I&&(vt="onReverseComplete")),this._rawPrevTime=qt=!Q||z||Ie===z?z:I);else if(1e-7>z)this._totalTime=this._time=0,this.ratio=this._ease._calcEnd?this._ease.getRatio(0):0,(Xt!==0||Ne===0&&Ie>0)&&(vt="onReverseComplete",nt=this._reversed),0>z&&(this._active=!1,Ne===0&&(this._initted||!this.vars.lazy||st)&&(Ie>=0&&(Ie!==I||this.data!=="isPause")&&(st=!0),this._rawPrevTime=qt=!Q||z||Ie===z?z:I)),(!this._initted||this._startAt&&this._startAt.progress())&&(st=!0);else if(this._totalTime=this._time=z,this._easeType){var me=z/Ne,we=this._easeType,yi=this._easePower;(we===1||we===3&&me>=.5)&&(me=1-me),we===3&&(me*=2),yi===1?me*=me:yi===2?me*=me*me:yi===3?me*=me*me*me:yi===4&&(me*=me*me*me*me),we===1?this.ratio=1-me:we===2?this.ratio=me:.5>z/Ne?this.ratio=me/2:this.ratio=1-me/2}else this.ratio=this._ease.getRatio(z/Ne);if(this._time!==Xt||st){if(!this._initted){if(this._init(),!this._initted||this._gc)return;if(!st&&this._firstPT&&(this.vars.lazy!==!1&&this._duration||this.vars.lazy&&!this._duration))return this._time=this._totalTime=Xt,this._rawPrevTime=Ie,Ft.push(this),void(this._lazy=[z,Q]);this._time&&!nt?this.ratio=this._ease.getRatio(this._time/Ne):nt&&this._ease._calcEnd&&(this.ratio=this._ease.getRatio(this._time===0?0:1))}for(this._lazy!==!1&&(this._lazy=!1),this._active||!this._paused&&this._time!==Xt&&z>=0&&(this._active=!0),Xt===0&&(this._startAt&&(z>=0?this._startAt.render(z,!0,st):vt||(vt="_dummyGS")),this.vars.onStart&&(this._time!==0||Ne===0)&&(Q||this._callback("onStart"))),Ut=this._firstPT;Ut;)Ut.f?Ut.t[Ut.p](Ut.c*this.ratio+Ut.s):Ut.t[Ut.p]=Ut.c*this.ratio+Ut.s,Ut=Ut._next;this._onUpdate&&(0>z&&this._startAt&&z!==-1e-4&&this._startAt.render(z,!0,st),Q||(this._time!==Xt||nt||st)&&this._callback("onUpdate")),vt&&(!this._gc||st)&&(0>z&&this._startAt&&!this._onUpdate&&z!==-1e-4&&this._startAt.render(z,!0,st),nt&&(this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!Q&&this.vars[vt]&&this._callback(vt),Ne===0&&this._rawPrevTime===I&&qt!==I&&(this._rawPrevTime=0))}},v._kill=function(z,Q,st){if(z==="all"&&(z=null),z==null&&(Q==null||Q===this.target))return this._lazy=!1,this._enabled(!1,!1);Q=typeof Q!="string"?Q||this._targets||this.target:At.selector(Q)||Q;var nt,vt,Ut,qt,Xt,Ne,Ie,me,we,yi=st&&this._time&&st._startTime===this._startTime&&this._timeline===st._timeline,Ei=this._firstPT;if((P(Q)||ce(Q))&&typeof Q[0]!="number")for(nt=Q.length;--nt>-1;)this._kill(z,Q[nt],st)&&(Ne=!0);else{if(this._targets){for(nt=this._targets.length;--nt>-1;)if(Q===this._targets[nt]){Xt=this._propLookup[nt]||{},this._overwrittenProps=this._overwrittenProps||[],vt=this._overwrittenProps[nt]=z?this._overwrittenProps[nt]||{}:"all";break}}else{if(Q!==this.target)return!1;Xt=this._propLookup,vt=this._overwrittenProps=z?this._overwrittenProps||{}:"all"}if(Xt){if(Ie=z||Xt,me=z!==vt&&vt!=="all"&&z!==Xt&&(typeof z!="object"||!z._tempKill),st&&(At.onOverwrite||this.vars.onOverwrite)){for(Ut in Ie)Xt[Ut]&&(we||(we=[]),we.push(Ut));if((we||!z)&&!pt(this,st,Q,we))return!1}for(Ut in Ie)(qt=Xt[Ut])&&(yi&&(qt.f?qt.t[qt.p](qt.s):qt.t[qt.p]=qt.s,Ne=!0),qt.pg&&qt.t._kill(Ie)&&(Ne=!0),qt.pg&&qt.t._overwriteProps.length!==0||(qt._prev?qt._prev._next=qt._next:qt===this._firstPT&&(this._firstPT=qt._next),qt._next&&(qt._next._prev=qt._prev),qt._next=qt._prev=null),delete Xt[Ut]),me&&(vt[Ut]=1);!this._firstPT&&this._initted&&Ei&&this._enabled(!1,!1)}}return Ne},v.invalidate=function(){return this._notifyPluginsOfEnabled&&At._onPluginEvent("_onDisable",this),this._firstPT=this._overwrittenProps=this._startAt=this._onUpdate=null,this._notifyPluginsOfEnabled=this._active=this._lazy=!1,this._propLookup=this._targets?{}:[],G.prototype.invalidate.call(this),this.vars.immediateRender&&(this._time=-I,this.render(Math.min(0,-this._delay))),this},v._enabled=function(z,Q){if(b||S.wake(),z&&this._gc){var st,nt=this._targets;if(nt)for(st=nt.length;--st>-1;)this._siblings[st]=dt(nt[st],this,!0);else this._siblings=dt(this.target,this,!0)}return G.prototype._enabled.call(this,z,Q),this._notifyPluginsOfEnabled&&this._firstPT?At._onPluginEvent(z?"_onEnable":"_onDisable",this):!1},At.to=function(z,Q,st){return new At(z,Q,st)},At.from=function(z,Q,st){return st.runBackwards=!0,st.immediateRender=st.immediateRender!=0,new At(z,Q,st)},At.fromTo=function(z,Q,st,nt){return nt.startAt=st,nt.immediateRender=nt.immediateRender!=0&&st.immediateRender!=0,new At(z,Q,nt)},At.delayedCall=function(z,Q,st,nt,vt){return new At(Q,0,{delay:z,onComplete:Q,onCompleteParams:st,callbackScope:nt,onReverseComplete:Q,onReverseCompleteParams:st,immediateRender:!1,lazy:!1,useFrames:vt,overwrite:0})},At.set=function(z,Q){return new At(z,0,Q)},At.getTweensOf=function(z,Q){if(z==null)return[];z=typeof z!="string"?z:At.selector(z)||z;var st,nt,vt,Ut;if((P(z)||ce(z))&&typeof z[0]!="number"){for(st=z.length,nt=[];--st>-1;)nt=nt.concat(At.getTweensOf(z[st],Q));for(st=nt.length;--st>-1;)for(Ut=nt[st],vt=st;--vt>-1;)Ut===nt[vt]&&nt.splice(st,1)}else if(z._gsTweenID)for(nt=dt(z).concat(),st=nt.length;--st>-1;)(nt[st]._gc||Q&&!nt[st].isActive())&&nt.splice(st,1);return nt||[]},At.killTweensOf=At.killDelayedCallsTo=function(z,Q,st){typeof Q=="object"&&(st=Q,Q=!1);for(var nt=At.getTweensOf(z,Q),vt=nt.length;--vt>-1;)nt[vt]._kill(st,z)};var Kt=C("plugins.TweenPlugin",function(z,Q){this._overwriteProps=(z||"").split(","),this._propName=this._overwriteProps[0],this._priority=Q||0,this._super=Kt.prototype},!0);if(v=Kt.prototype,Kt.version="1.19.0",Kt.API=2,v._firstPT=null,v._addTween=$e,v.setRatio=pe,v._kill=function(z){var Q,st=this._overwriteProps,nt=this._firstPT;if(z[this._propName]!=null)this._overwriteProps=[];else for(Q=st.length;--Q>-1;)z[st[Q]]!=null&&st.splice(Q,1);for(;nt;)z[nt.n]!=null&&(nt._next&&(nt._next._prev=nt._prev),nt._prev?(nt._prev._next=nt._next,nt._prev=null):this._firstPT===nt&&(this._firstPT=nt._next)),nt=nt._next;return!1},v._mod=v._roundProps=function(z){for(var Q,st=this._firstPT;st;)Q=z[this._propName]||st.n!=null&&z[st.n.split(this._propName+"_").join("")],Q&&typeof Q=="function"&&(st.f===2?st.t._applyPT.m=Q:st.m=Q),st=st._next},At._onPluginEvent=function(z,Q){var st,nt,vt,Ut,qt,Xt=Q._firstPT;if(z==="_onInitAllProps"){for(;Xt;){for(qt=Xt._next,nt=vt;nt&&nt.pr>Xt.pr;)nt=nt._next;(Xt._prev=nt?nt._prev:Ut)?Xt._prev._next=Xt:vt=Xt,(Xt._next=nt)?nt._prev=Xt:Ut=Xt,Xt=qt}Xt=Q._firstPT=vt}for(;Xt;)Xt.pg&&typeof Xt.t[z]=="function"&&Xt.t[z]()&&(st=!0),Xt=Xt._next;return st},Kt.activate=function(z){for(var Q=z.length;--Q>-1;)z[Q].API===Kt.API&&(Oe[new z[Q]()._propName]=z[Q]);return!0},R.plugin=function(z){if(!(z&&z.propName&&z.init&&z.API))throw"illegal plugin definition.";var Q,st=z.propName,nt=z.priority||0,vt=z.overwriteProps,Ut={init:"_onInitTween",set:"setRatio",kill:"_kill",round:"_mod",mod:"_mod",initAll:"_onInitAllProps"},qt=C("plugins."+st.charAt(0).toUpperCase()+st.substr(1)+"Plugin",function(){Kt.call(this,st,nt),this._overwriteProps=vt||[]},z.global===!0),Xt=qt.prototype=new Kt(st);Xt.constructor=qt,qt.API=z.API;for(Q in Ut)typeof z[Q]=="function"&&(Xt[Ut[Q]]=z[Q]);return qt.version=z.version,Kt.activate([qt]),qt},m=x._gsQueue){for(g=0;g<m.length;g++)m[g]();for(v in w)w[v].func||x.console.log("GSAP encountered missing dependency: "+v)}b=!1}(typeof module<"u"&&module.exports&&typeof global<"u"?global:globalThis||window,"TweenMax");const $p={class:"modal-background"},Kp=["innerHTML"],Qp={name:"MapModali"},Sf=oi.defineComponent({...Qp,props:{},setup(x,{expose:a}){const o=oi.ref(""),c=oi.ref(""),f=m=>{c.value=m,o.value="five"},u=()=>{o.value=o.value+" out"};return oi.onMounted(()=>{}),a({text:c,show:f,hide:u}),(m,g)=>(oi.openBlock(),oi.createElementBlock("div",{id:"modal-container",class:oi.normalizeClass(o.value),onClick:u},[oi.createElementVNode("div",$p,[oi.createElementVNode("div",{class:"modal",onClick:g[0]||(g[0]=v=>{v.stopPropagation()})},[oi.createElementVNode("p",{style:{"white-space":"pre-line","line-height":"1",margin:"0",color:"#fff"},innerHTML:c.value},null,8,Kp)])])],2))}}),A1="",tm={class:"bim_background_plate"},em={class:"content"},im=oi.createElementVNode("canvas",{class:"landscape"},null,-1),nm={class:"content__title"},rm=oi.createElementVNode("div",{class:"overlay"},null,-1),om={name:"BimBackgroundPlate"},Ef=oi.defineComponent({...om,setup(x){const a=()=>{let f=`
|
|
13
|
+
**/var ln=typeof module<"u"&&module.exports&&typeof global<"u"?global:globalThis||window;(ln._gsQueue||(ln._gsQueue=[])).push(function(){ln._gsDefine("TweenMax",["core.Animation","core.SimpleTimeline","TweenLite"],function(x,a,o){var c=function(E){var P,w=[],M=E.length;for(P=0;P!==M;w.push(E[P++]));return w},f=function(E,P,w){var M,R,C=E.cycle;for(M in C)R=C[M],E[M]=typeof R=="function"?R(w,P[w]):R[w%R.length];delete E.cycle},u=function(E,P,w){o.call(this,E,P,w),this._cycle=0,this._yoyo=this.vars.yoyo===!0||!!this.vars.yoyoEase,this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._repeat&&this._uncache(!0),this.render=u.prototype.render},m=1e-10,g=o._internals,v=g.isSelector,S=g.isArray,b=u.prototype=o.to({},.1,{}),O=[];u.version="2.0.2",b.constructor=u,b.kill()._gc=!1,u.killTweensOf=u.killDelayedCallsTo=o.killTweensOf,u.getTweensOf=o.getTweensOf,u.lagSmoothing=o.lagSmoothing,u.ticker=o.ticker,u.render=o.render,b.invalidate=function(){return this._yoyo=this.vars.yoyo===!0||!!this.vars.yoyoEase,this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._yoyoEase=null,this._uncache(!0),o.prototype.invalidate.call(this)},b.updateTo=function(E,P){var w,M=this.ratio,R=this.vars.immediateRender||E.immediateRender;P&&this._startTime<this._timeline._time&&(this._startTime=this._timeline._time,this._uncache(!1),this._gc?this._enabled(!0,!1):this._timeline.insert(this,this._startTime-this._delay));for(w in E)this.vars[w]=E[w];if(this._initted||R){if(P)this._initted=!1,R&&this.render(0,!0,!0);else if(this._gc&&this._enabled(!0,!1),this._notifyPluginsOfEnabled&&this._firstPT&&o._onPluginEvent("_onDisable",this),this._time/this._duration>.998){var C=this._totalTime;this.render(0,!0,!1),this._initted=!1,this.render(C,!0,!1)}else if(this._initted=!1,this._init(),this._time>0||R)for(var U,N=1/(1-M),X=this._firstPT;X;)U=X.s+X.c,X.c*=N,X.s=U-X.c,X=X._next}return this},b.render=function(E,P,w){this._initted||this._duration===0&&this.vars.repeat&&this.invalidate();var M,R,C,U,N,X,J,Z,ct,Rt=this._dirty?this.totalDuration():this._totalDuration,tt=this._time,_t=this._totalTime,G=this._cycle,Pt=this._duration,Et=this._rawPrevTime;if(E>=Rt-1e-7&&E>=0?(this._totalTime=Rt,this._cycle=this._repeat,this._yoyo&&1&this._cycle?(this._time=0,this.ratio=this._ease._calcEnd?this._ease.getRatio(0):0):(this._time=Pt,this.ratio=this._ease._calcEnd?this._ease.getRatio(1):1),this._reversed||(M=!0,R="onComplete",w=w||this._timeline.autoRemoveChildren),Pt===0&&(this._initted||!this.vars.lazy||w)&&(this._startTime===this._timeline._duration&&(E=0),(0>Et||0>=E&&E>=-1e-7||Et===m&&this.data!=="isPause")&&Et!==E&&(w=!0,Et>m&&(R="onReverseComplete")),this._rawPrevTime=Z=!P||E||Et===E?E:m)):1e-7>E?(this._totalTime=this._time=this._cycle=0,this.ratio=this._ease._calcEnd?this._ease.getRatio(0):0,(_t!==0||Pt===0&&Et>0)&&(R="onReverseComplete",M=this._reversed),0>E&&(this._active=!1,Pt===0&&(this._initted||!this.vars.lazy||w)&&(Et>=0&&(w=!0),this._rawPrevTime=Z=!P||E||Et===E?E:m)),this._initted||(w=!0)):(this._totalTime=this._time=E,this._repeat!==0&&(U=Pt+this._repeatDelay,this._cycle=this._totalTime/U>>0,this._cycle!==0&&this._cycle===this._totalTime/U&&E>=_t&&this._cycle--,this._time=this._totalTime-this._cycle*U,this._yoyo&&1&this._cycle&&(this._time=Pt-this._time,ct=this._yoyoEase||this.vars.yoyoEase,ct&&(this._yoyoEase||(ct!==!0||this._initted?this._yoyoEase=ct=ct===!0?this._ease:ct instanceof Ease?ct:Ease.map[ct]:(ct=this.vars.ease,this._yoyoEase=ct=ct?ct instanceof Ease?ct:typeof ct=="function"?new Ease(ct,this.vars.easeParams):Ease.map[ct]||o.defaultEase:o.defaultEase)),this.ratio=ct?1-ct.getRatio((Pt-this._time)/Pt):0)),this._time>Pt?this._time=Pt:this._time<0&&(this._time=0)),this._easeType&&!ct?(N=this._time/Pt,X=this._easeType,J=this._easePower,(X===1||X===3&&N>=.5)&&(N=1-N),X===3&&(N*=2),J===1?N*=N:J===2?N*=N*N:J===3?N*=N*N*N:J===4&&(N*=N*N*N*N),X===1?this.ratio=1-N:X===2?this.ratio=N:this._time/Pt<.5?this.ratio=N/2:this.ratio=1-N/2):ct||(this.ratio=this._ease.getRatio(this._time/Pt))),tt===this._time&&!w&&G===this._cycle)return void(_t!==this._totalTime&&this._onUpdate&&(P||this._callback("onUpdate")));if(!this._initted){if(this._init(),!this._initted||this._gc)return;if(!w&&this._firstPT&&(this.vars.lazy!==!1&&this._duration||this.vars.lazy&&!this._duration))return this._time=tt,this._totalTime=_t,this._rawPrevTime=Et,this._cycle=G,g.lazyTweens.push(this),void(this._lazy=[E,P]);!this._time||M||ct?M&&this._ease._calcEnd&&!ct&&(this.ratio=this._ease.getRatio(this._time===0?0:1)):this.ratio=this._ease.getRatio(this._time/Pt)}for(this._lazy!==!1&&(this._lazy=!1),this._active||!this._paused&&this._time!==tt&&E>=0&&(this._active=!0),_t===0&&(this._initted===2&&E>0&&this._init(),this._startAt&&(E>=0?this._startAt.render(E,!0,w):R||(R="_dummyGS")),this.vars.onStart&&(this._totalTime!==0||Pt===0)&&(P||this._callback("onStart"))),C=this._firstPT;C;)C.f?C.t[C.p](C.c*this.ratio+C.s):C.t[C.p]=C.c*this.ratio+C.s,C=C._next;this._onUpdate&&(0>E&&this._startAt&&this._startTime&&this._startAt.render(E,!0,w),P||(this._totalTime!==_t||R)&&this._callback("onUpdate")),this._cycle!==G&&(P||this._gc||this.vars.onRepeat&&this._callback("onRepeat")),R&&(!this._gc||w)&&(0>E&&this._startAt&&!this._onUpdate&&this._startTime&&this._startAt.render(E,!0,w),M&&(this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!P&&this.vars[R]&&this._callback(R),Pt===0&&this._rawPrevTime===m&&Z!==m&&(this._rawPrevTime=0))},u.to=function(E,P,w){return new u(E,P,w)},u.from=function(E,P,w){return w.runBackwards=!0,w.immediateRender=w.immediateRender!=0,new u(E,P,w)},u.fromTo=function(E,P,w,M){return M.startAt=w,M.immediateRender=M.immediateRender!=0&&w.immediateRender!=0,new u(E,P,M)},u.staggerTo=u.allTo=function(E,P,w,M,R,C,U){M=M||0;var N,X,J,Z,ct=0,Rt=[],tt=function(){w.onComplete&&w.onComplete.apply(w.onCompleteScope||this,arguments),R.apply(U||w.callbackScope||this,C||O)},_t=w.cycle,G=w.startAt&&w.startAt.cycle;for(S(E)||(typeof E=="string"&&(E=o.selector(E)||E),v(E)&&(E=c(E))),E=E||[],0>M&&(E=c(E),E.reverse(),M*=-1),N=E.length-1,J=0;N>=J;J++){X={};for(Z in w)X[Z]=w[Z];if(_t&&(f(X,E,J),X.duration!=null&&(P=X.duration,delete X.duration)),G){G=X.startAt={};for(Z in w.startAt)G[Z]=w.startAt[Z];f(X.startAt,E,J)}X.delay=ct+(X.delay||0),J===N&&R&&(X.onComplete=tt),Rt[J]=new u(E[J],P,X),ct+=M}return Rt},u.staggerFrom=u.allFrom=function(E,P,w,M,R,C,U){return w.runBackwards=!0,w.immediateRender=w.immediateRender!=0,u.staggerTo(E,P,w,M,R,C,U)},u.staggerFromTo=u.allFromTo=function(E,P,w,M,R,C,U,N){return M.startAt=w,M.immediateRender=M.immediateRender!=0&&w.immediateRender!=0,u.staggerTo(E,P,M,R,C,U,N)},u.delayedCall=function(E,P,w,M,R){return new u(P,0,{delay:E,onComplete:P,onCompleteParams:w,callbackScope:M,onReverseComplete:P,onReverseCompleteParams:w,immediateRender:!1,useFrames:R,overwrite:0})},u.set=function(E,P){return new u(E,0,P)},u.isTweening=function(E){return o.getTweensOf(E,!0).length>0};var k=function(E,P){for(var w=[],M=0,R=E._first;R;)R instanceof o?w[M++]=R:(P&&(w[M++]=R),w=w.concat(k(R,P)),M=w.length),R=R._next;return w},I=u.getAllTweens=function(E){return k(x._rootTimeline,E).concat(k(x._rootFramesTimeline,E))};u.killAll=function(E,P,w,M){P==null&&(P=!0),w==null&&(w=!0);var R,C,U,N=I(M!=0),X=N.length,J=P&&w&&M;for(U=0;X>U;U++)C=N[U],(J||C instanceof a||(R=C.target===C.vars.onComplete)&&w||P&&!R)&&(E?C.totalTime(C._reversed?0:C.totalDuration()):C._enabled(!1,!1))},u.killChildTweensOf=function(E,P){if(E!=null){var w,M,R,C,U,N=g.tweenLookup;if(typeof E=="string"&&(E=o.selector(E)||E),v(E)&&(E=c(E)),S(E))for(C=E.length;--C>-1;)u.killChildTweensOf(E[C],P);else{w=[];for(R in N)for(M=N[R].target.parentNode;M;)M===E&&(w=w.concat(N[R].tweens)),M=M.parentNode;for(U=w.length,C=0;U>C;C++)P&&w[C].totalTime(w[C].totalDuration()),w[C]._enabled(!1,!1)}}};var F=function(E,P,w,M){P=P!==!1,w=w!==!1,M=M!==!1;for(var R,C,U=I(M),N=P&&w&&M,X=U.length;--X>-1;)C=U[X],(N||C instanceof a||(R=C.target===C.vars.onComplete)&&w||P&&!R)&&C.paused(E)};return u.pauseAll=function(E,P,w){F(!0,E,P,w)},u.resumeAll=function(E,P,w){F(!1,E,P,w)},u.globalTimeScale=function(E){var P=x._rootTimeline,w=o.ticker.time;return arguments.length?(E=E||m,P._startTime=w-(w-P._startTime)*P._timeScale/E,P=x._rootFramesTimeline,w=o.ticker.frame,P._startTime=w-(w-P._startTime)*P._timeScale/E,P._timeScale=x._rootTimeline._timeScale=E,E):P._timeScale},b.progress=function(E,P){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&1&this._cycle?1-E:E)+this._cycle*(this._duration+this._repeatDelay),P):this._time/this.duration()},b.totalProgress=function(E,P){return arguments.length?this.totalTime(this.totalDuration()*E,P):this._totalTime/this.totalDuration()},b.time=function(E,P){return arguments.length?(this._dirty&&this.totalDuration(),E>this._duration&&(E=this._duration),this._yoyo&&1&this._cycle?E=this._duration-E+this._cycle*(this._duration+this._repeatDelay):this._repeat!==0&&(E+=this._cycle*(this._duration+this._repeatDelay)),this.totalTime(E,P)):this._time},b.duration=function(E){return arguments.length?x.prototype.duration.call(this,E):this._duration},b.totalDuration=function(E){return arguments.length?this._repeat===-1?this:this.duration((E-this._repeat*this._repeatDelay)/(this._repeat+1)):(this._dirty&&(this._totalDuration=this._repeat===-1?999999999999:this._duration*(this._repeat+1)+this._repeatDelay*this._repeat,this._dirty=!1),this._totalDuration)},b.repeat=function(E){return arguments.length?(this._repeat=E,this._uncache(!0)):this._repeat},b.repeatDelay=function(E){return arguments.length?(this._repeatDelay=E,this._uncache(!0)):this._repeatDelay},b.yoyo=function(E){return arguments.length?(this._yoyo=E,this):this._yoyo},u},!0),ln._gsDefine("TimelineLite",["core.Animation","core.SimpleTimeline","TweenLite"],function(x,a,o){var c=function(w){a.call(this,w),this._labels={},this.autoRemoveChildren=this.vars.autoRemoveChildren===!0,this.smoothChildTiming=this.vars.smoothChildTiming===!0,this._sortChildren=!0,this._onUpdate=this.vars.onUpdate;var M,R,C=this.vars;for(R in C)M=C[R],v(M)&&M.join("").indexOf("{self}")!==-1&&(C[R]=this._swapSelfInParams(M));v(C.tweens)&&this.add(C.tweens,0,C.align,C.stagger)},f=1e-10,u=o._internals,m=c._internals={},g=u.isSelector,v=u.isArray,S=u.lazyTweens,b=u.lazyRender,O=ln._gsDefine.globals,k=function(w){var M,R={};for(M in w)R[M]=w[M];return R},I=function(w,M,R){var C,U,N=w.cycle;for(C in N)U=N[C],w[C]=typeof U=="function"?U(R,M[R]):U[R%U.length];delete w.cycle},F=m.pauseCallback=function(){},E=function(w){var M,R=[],C=w.length;for(M=0;M!==C;R.push(w[M++]));return R},P=c.prototype=new a;return c.version="2.0.2",P.constructor=c,P.kill()._gc=P._forcingPlayhead=P._hasPause=!1,P.to=function(w,M,R,C){var U=R.repeat&&O.TweenMax||o;return M?this.add(new U(w,M,R),C):this.set(w,R,C)},P.from=function(w,M,R,C){return this.add((R.repeat&&O.TweenMax||o).from(w,M,R),C)},P.fromTo=function(w,M,R,C,U){var N=C.repeat&&O.TweenMax||o;return M?this.add(N.fromTo(w,M,R,C),U):this.set(w,C,U)},P.staggerTo=function(w,M,R,C,U,N,X,J){var Z,ct,Rt=new c({onComplete:N,onCompleteParams:X,callbackScope:J,smoothChildTiming:this.smoothChildTiming}),tt=R.cycle;for(typeof w=="string"&&(w=o.selector(w)||w),w=w||[],g(w)&&(w=E(w)),C=C||0,0>C&&(w=E(w),w.reverse(),C*=-1),ct=0;ct<w.length;ct++)Z=k(R),Z.startAt&&(Z.startAt=k(Z.startAt),Z.startAt.cycle&&I(Z.startAt,w,ct)),tt&&(I(Z,w,ct),Z.duration!=null&&(M=Z.duration,delete Z.duration)),Rt.to(w[ct],M,Z,ct*C);return this.add(Rt,U)},P.staggerFrom=function(w,M,R,C,U,N,X,J){return R.immediateRender=R.immediateRender!=0,R.runBackwards=!0,this.staggerTo(w,M,R,C,U,N,X,J)},P.staggerFromTo=function(w,M,R,C,U,N,X,J,Z){return C.startAt=R,C.immediateRender=C.immediateRender!=0&&R.immediateRender!=0,this.staggerTo(w,M,C,U,N,X,J,Z)},P.call=function(w,M,R,C){return this.add(o.delayedCall(0,w,M,R),C)},P.set=function(w,M,R){return R=this._parseTimeOrLabel(R,0,!0),M.immediateRender==null&&(M.immediateRender=R===this._time&&!this._paused),this.add(new o(w,0,M),R)},c.exportRoot=function(w,M){w=w||{},w.smoothChildTiming==null&&(w.smoothChildTiming=!0);var R,C,U,N,X=new c(w),J=X._timeline;for(M==null&&(M=!0),J._remove(X,!0),X._startTime=0,X._rawPrevTime=X._time=X._totalTime=J._time,U=J._first;U;)N=U._next,M&&U instanceof o&&U.target===U.vars.onComplete||(C=U._startTime-U._delay,0>C&&(R=1),X.add(U,C)),U=N;return J.add(X,0),R&&X.totalDuration(),X},P.add=function(w,M,R,C){var U,N,X,J,Z,ct;if(typeof M!="number"&&(M=this._parseTimeOrLabel(M,0,!0,w)),!(w instanceof x)){if(w instanceof Array||w&&w.push&&v(w)){for(R=R||"normal",C=C||0,U=M,N=w.length,X=0;N>X;X++)v(J=w[X])&&(J=new c({tweens:J})),this.add(J,U),typeof J!="string"&&typeof J!="function"&&(R==="sequence"?U=J._startTime+J.totalDuration()/J._timeScale:R==="start"&&(J._startTime-=J.delay())),U+=C;return this._uncache(!0)}if(typeof w=="string")return this.addLabel(w,M);if(typeof w!="function")throw"Cannot add "+w+" into the timeline; it is not a tween, timeline, function, or string.";w=o.delayedCall(0,w)}if(a.prototype.add.call(this,w,M),w._time&&(U=Math.max(0,Math.min(w.totalDuration(),(this.rawTime()-w._startTime)*w._timeScale)),Math.abs(U-w._totalTime)>1e-5&&w.render(U,!1,!1)),(this._gc||this._time===this._duration)&&!this._paused&&this._duration<this.duration())for(Z=this,ct=Z.rawTime()>w._startTime;Z._timeline;)ct&&Z._timeline.smoothChildTiming?Z.totalTime(Z._totalTime,!0):Z._gc&&Z._enabled(!0,!1),Z=Z._timeline;return this},P.remove=function(w){if(w instanceof x){this._remove(w,!1);var M=w._timeline=w.vars.useFrames?x._rootFramesTimeline:x._rootTimeline;return w._startTime=(w._paused?w._pauseTime:M._time)-(w._reversed?w.totalDuration()-w._totalTime:w._totalTime)/w._timeScale,this}if(w instanceof Array||w&&w.push&&v(w)){for(var R=w.length;--R>-1;)this.remove(w[R]);return this}return typeof w=="string"?this.removeLabel(w):this.kill(null,w)},P._remove=function(w,M){a.prototype._remove.call(this,w,M);var R=this._last;return R?this._time>this.duration()&&(this._time=this._duration,this._totalTime=this._totalDuration):this._time=this._totalTime=this._duration=this._totalDuration=0,this},P.append=function(w,M){return this.add(w,this._parseTimeOrLabel(null,M,!0,w))},P.insert=P.insertMultiple=function(w,M,R,C){return this.add(w,M||0,R,C)},P.appendMultiple=function(w,M,R,C){return this.add(w,this._parseTimeOrLabel(null,M,!0,w),R,C)},P.addLabel=function(w,M){return this._labels[w]=this._parseTimeOrLabel(M),this},P.addPause=function(w,M,R,C){var U=o.delayedCall(0,F,R,C||this);return U.vars.onComplete=U.vars.onReverseComplete=M,U.data="isPause",this._hasPause=!0,this.add(U,w)},P.removeLabel=function(w){return delete this._labels[w],this},P.getLabelTime=function(w){return this._labels[w]!=null?this._labels[w]:-1},P._parseTimeOrLabel=function(w,M,R,C){var U,N;if(C instanceof x&&C.timeline===this)this.remove(C);else if(C&&(C instanceof Array||C.push&&v(C)))for(N=C.length;--N>-1;)C[N]instanceof x&&C[N].timeline===this&&this.remove(C[N]);if(U=typeof w!="number"||M?this.duration()>99999999999?this.recent().endTime(!1):this._duration:0,typeof M=="string")return this._parseTimeOrLabel(M,R&&typeof w=="number"&&this._labels[M]==null?w-U:0,R);if(M=M||0,typeof w!="string"||!isNaN(w)&&this._labels[w]==null)w==null&&(w=U);else{if(N=w.indexOf("="),N===-1)return this._labels[w]==null?R?this._labels[w]=U+M:M:this._labels[w]+M;M=parseInt(w.charAt(N-1)+"1",10)*Number(w.substr(N+1)),w=N>1?this._parseTimeOrLabel(w.substr(0,N-1),0,R):U}return Number(w)+M},P.seek=function(w,M){return this.totalTime(typeof w=="number"?w:this._parseTimeOrLabel(w),M!==!1)},P.stop=function(){return this.paused(!0)},P.gotoAndPlay=function(w,M){return this.play(w,M)},P.gotoAndStop=function(w,M){return this.pause(w,M)},P.render=function(w,M,R){this._gc&&this._enabled(!0,!1);var C,U,N,X,J,Z,ct,Rt=this._time,tt=this._dirty?this.totalDuration():this._totalDuration,_t=this._startTime,G=this._timeScale,Pt=this._paused;if(Rt!==this._time&&(w+=this._time-Rt),w>=tt-1e-7&&w>=0)this._totalTime=this._time=tt,this._reversed||this._hasPausedChild()||(U=!0,X="onComplete",J=!!this._timeline.autoRemoveChildren,this._duration===0&&(0>=w&&w>=-1e-7||this._rawPrevTime<0||this._rawPrevTime===f)&&this._rawPrevTime!==w&&this._first&&(J=!0,this._rawPrevTime>f&&(X="onReverseComplete"))),this._rawPrevTime=this._duration||!M||w||this._rawPrevTime===w?w:f,w=tt+1e-4;else if(1e-7>w)if(this._totalTime=this._time=0,(Rt!==0||this._duration===0&&this._rawPrevTime!==f&&(this._rawPrevTime>0||0>w&&this._rawPrevTime>=0))&&(X="onReverseComplete",U=this._reversed),0>w)this._active=!1,this._timeline.autoRemoveChildren&&this._reversed?(J=U=!0,X="onReverseComplete"):this._rawPrevTime>=0&&this._first&&(J=!0),this._rawPrevTime=w;else{if(this._rawPrevTime=this._duration||!M||w||this._rawPrevTime===w?w:f,w===0&&U)for(C=this._first;C&&C._startTime===0;)C._duration||(U=!1),C=C._next;w=0,this._initted||(J=!0)}else{if(this._hasPause&&!this._forcingPlayhead&&!M){if(w>=Rt)for(C=this._first;C&&C._startTime<=w&&!Z;)C._duration||C.data!=="isPause"||C.ratio||C._startTime===0&&this._rawPrevTime===0||(Z=C),C=C._next;else for(C=this._last;C&&C._startTime>=w&&!Z;)C._duration||C.data==="isPause"&&C._rawPrevTime>0&&(Z=C),C=C._prev;Z&&(this._time=w=Z._startTime,this._totalTime=w+this._cycle*(this._totalDuration+this._repeatDelay))}this._totalTime=this._time=this._rawPrevTime=w}if(this._time!==Rt&&this._first||R||J||Z){if(this._initted||(this._initted=!0),this._active||!this._paused&&this._time!==Rt&&w>0&&(this._active=!0),Rt===0&&this.vars.onStart&&(this._time===0&&this._duration||M||this._callback("onStart")),ct=this._time,ct>=Rt)for(C=this._first;C&&(N=C._next,ct===this._time&&(!this._paused||Pt));)(C._active||C._startTime<=ct&&!C._paused&&!C._gc)&&(Z===C&&this.pause(),C._reversed?C.render((C._dirty?C.totalDuration():C._totalDuration)-(w-C._startTime)*C._timeScale,M,R):C.render((w-C._startTime)*C._timeScale,M,R)),C=N;else for(C=this._last;C&&(N=C._prev,ct===this._time&&(!this._paused||Pt));){if(C._active||C._startTime<=Rt&&!C._paused&&!C._gc){if(Z===C){for(Z=C._prev;Z&&Z.endTime()>this._time;)Z.render(Z._reversed?Z.totalDuration()-(w-Z._startTime)*Z._timeScale:(w-Z._startTime)*Z._timeScale,M,R),Z=Z._prev;Z=null,this.pause()}C._reversed?C.render((C._dirty?C.totalDuration():C._totalDuration)-(w-C._startTime)*C._timeScale,M,R):C.render((w-C._startTime)*C._timeScale,M,R)}C=N}this._onUpdate&&(M||(S.length&&b(),this._callback("onUpdate"))),X&&(this._gc||(_t===this._startTime||G!==this._timeScale)&&(this._time===0||tt>=this.totalDuration())&&(U&&(S.length&&b(),this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!M&&this.vars[X]&&this._callback(X)))}},P._hasPausedChild=function(){for(var w=this._first;w;){if(w._paused||w instanceof c&&w._hasPausedChild())return!0;w=w._next}return!1},P.getChildren=function(w,M,R,C){C=C||-9999999999;for(var U=[],N=this._first,X=0;N;)N._startTime<C||(N instanceof o?M!==!1&&(U[X++]=N):(R!==!1&&(U[X++]=N),w!==!1&&(U=U.concat(N.getChildren(!0,M,R)),X=U.length))),N=N._next;return U},P.getTweensOf=function(w,M){var R,C,U=this._gc,N=[],X=0;for(U&&this._enabled(!0,!0),R=o.getTweensOf(w),C=R.length;--C>-1;)(R[C].timeline===this||M&&this._contains(R[C]))&&(N[X++]=R[C]);return U&&this._enabled(!1,!0),N},P.recent=function(){return this._recent},P._contains=function(w){for(var M=w.timeline;M;){if(M===this)return!0;M=M.timeline}return!1},P.shiftChildren=function(w,M,R){R=R||0;for(var C,U=this._first,N=this._labels;U;)U._startTime>=R&&(U._startTime+=w),U=U._next;if(M)for(C in N)N[C]>=R&&(N[C]+=w);return this._uncache(!0)},P._kill=function(w,M){if(!w&&!M)return this._enabled(!1,!1);for(var R=M?this.getTweensOf(M):this.getChildren(!0,!0,!1),C=R.length,U=!1;--C>-1;)R[C]._kill(w,M)&&(U=!0);return U},P.clear=function(w){var M=this.getChildren(!1,!0,!0),R=M.length;for(this._time=this._totalTime=0;--R>-1;)M[R]._enabled(!1,!1);return w!==!1&&(this._labels={}),this._uncache(!0)},P.invalidate=function(){for(var w=this._first;w;)w.invalidate(),w=w._next;return x.prototype.invalidate.call(this)},P._enabled=function(w,M){if(w===this._gc)for(var R=this._first;R;)R._enabled(w,!0),R=R._next;return a.prototype._enabled.call(this,w,M)},P.totalTime=function(w,M,R){this._forcingPlayhead=!0;var C=x.prototype.totalTime.apply(this,arguments);return this._forcingPlayhead=!1,C},P.duration=function(w){return arguments.length?(this.duration()!==0&&w!==0&&this.timeScale(this._duration/w),this):(this._dirty&&this.totalDuration(),this._duration)},P.totalDuration=function(w){if(!arguments.length){if(this._dirty){for(var M,R,C=0,U=this._last,N=999999999999;U;)M=U._prev,U._dirty&&U.totalDuration(),U._startTime>N&&this._sortChildren&&!U._paused&&!this._calculatingDuration?(this._calculatingDuration=1,this.add(U,U._startTime-U._delay),this._calculatingDuration=0):N=U._startTime,U._startTime<0&&!U._paused&&(C-=U._startTime,this._timeline.smoothChildTiming&&(this._startTime+=U._startTime/this._timeScale,this._time-=U._startTime,this._totalTime-=U._startTime,this._rawPrevTime-=U._startTime),this.shiftChildren(-U._startTime,!1,-9999999999),N=0),R=U._startTime+U._totalDuration/U._timeScale,R>C&&(C=R),U=M;this._duration=this._totalDuration=C,this._dirty=!1}return this._totalDuration}return w&&this.totalDuration()?this.timeScale(this._totalDuration/w):this},P.paused=function(w){if(!w)for(var M=this._first,R=this._time;M;)M._startTime===R&&M.data==="isPause"&&(M._rawPrevTime=0),M=M._next;return x.prototype.paused.apply(this,arguments)},P.usesFrames=function(){for(var w=this._timeline;w._timeline;)w=w._timeline;return w===x._rootFramesTimeline},P.rawTime=function(w){return w&&(this._paused||this._repeat&&this.time()>0&&this.totalProgress()<1)?this._totalTime%(this._duration+this._repeatDelay):this._paused?this._totalTime:(this._timeline.rawTime(w)-this._startTime)*this._timeScale},c},!0),ln._gsDefine("TimelineMax",["TimelineLite","TweenLite","easing.Ease"],function(x,a,o){var c=function(O){x.call(this,O),this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._cycle=0,this._yoyo=this.vars.yoyo===!0,this._dirty=!0},f=1e-10,u=a._internals,m=u.lazyTweens,g=u.lazyRender,v=ln._gsDefine.globals,S=new o(null,null,1,0),b=c.prototype=new x;return b.constructor=c,b.kill()._gc=!1,c.version="2.0.2",b.invalidate=function(){return this._yoyo=this.vars.yoyo===!0,this._repeat=this.vars.repeat||0,this._repeatDelay=this.vars.repeatDelay||0,this._uncache(!0),x.prototype.invalidate.call(this)},b.addCallback=function(O,k,I,F){return this.add(a.delayedCall(0,O,I,F),k)},b.removeCallback=function(O,k){if(O)if(k==null)this._kill(null,O);else for(var I=this.getTweensOf(O,!1),F=I.length,E=this._parseTimeOrLabel(k);--F>-1;)I[F]._startTime===E&&I[F]._enabled(!1,!1);return this},b.removePause=function(O){return this.removeCallback(x._internals.pauseCallback,O)},b.tweenTo=function(O,k){k=k||{};var I,F,E,P={ease:S,useFrames:this.usesFrames(),immediateRender:!1,lazy:!1},w=k.repeat&&v.TweenMax||a;for(F in k)P[F]=k[F];return P.time=this._parseTimeOrLabel(O),I=Math.abs(Number(P.time)-this._time)/this._timeScale||.001,E=new w(this,I,P),P.onStart=function(){E.target.paused(!0),E.vars.time===E.target.time()||I!==E.duration()||E.isFromTo||E.duration(Math.abs(E.vars.time-E.target.time())/E.target._timeScale).render(E.time(),!0,!0),k.onStart&&k.onStart.apply(k.onStartScope||k.callbackScope||E,k.onStartParams||[])},E},b.tweenFromTo=function(O,k,I){I=I||{},O=this._parseTimeOrLabel(O),I.startAt={onComplete:this.seek,onCompleteParams:[O],callbackScope:this},I.immediateRender=I.immediateRender!==!1;var F=this.tweenTo(k,I);return F.isFromTo=1,F.duration(Math.abs(F.vars.time-O)/this._timeScale||.001)},b.render=function(O,k,I){this._gc&&this._enabled(!0,!1);var F,E,P,w,M,R,C,U,N=this._time,X=this._dirty?this.totalDuration():this._totalDuration,J=this._duration,Z=this._totalTime,ct=this._startTime,Rt=this._timeScale,tt=this._rawPrevTime,_t=this._paused,G=this._cycle;if(N!==this._time&&(O+=this._time-N),O>=X-1e-7&&O>=0)this._locked||(this._totalTime=X,this._cycle=this._repeat),this._reversed||this._hasPausedChild()||(E=!0,w="onComplete",M=!!this._timeline.autoRemoveChildren,this._duration===0&&(0>=O&&O>=-1e-7||0>tt||tt===f)&&tt!==O&&this._first&&(M=!0,tt>f&&(w="onReverseComplete"))),this._rawPrevTime=this._duration||!k||O||this._rawPrevTime===O?O:f,this._yoyo&&1&this._cycle?this._time=O=0:(this._time=J,O=J+1e-4);else if(1e-7>O)if(this._locked||(this._totalTime=this._cycle=0),this._time=0,(N!==0||J===0&&tt!==f&&(tt>0||0>O&&tt>=0)&&!this._locked)&&(w="onReverseComplete",E=this._reversed),0>O)this._active=!1,this._timeline.autoRemoveChildren&&this._reversed?(M=E=!0,w="onReverseComplete"):tt>=0&&this._first&&(M=!0),this._rawPrevTime=O;else{if(this._rawPrevTime=J||!k||O||this._rawPrevTime===O?O:f,O===0&&E)for(F=this._first;F&&F._startTime===0;)F._duration||(E=!1),F=F._next;O=0,this._initted||(M=!0)}else if(J===0&&0>tt&&(M=!0),this._time=this._rawPrevTime=O,this._locked||(this._totalTime=O,this._repeat!==0&&(R=J+this._repeatDelay,this._cycle=this._totalTime/R>>0,this._cycle!==0&&this._cycle===this._totalTime/R&&O>=Z&&this._cycle--,this._time=this._totalTime-this._cycle*R,this._yoyo&&1&this._cycle&&(this._time=J-this._time),this._time>J?(this._time=J,O=J+1e-4):this._time<0?this._time=O=0:O=this._time)),this._hasPause&&!this._forcingPlayhead&&!k){if(O=this._time,O>=N||this._repeat&&G!==this._cycle)for(F=this._first;F&&F._startTime<=O&&!C;)F._duration||F.data!=="isPause"||F.ratio||F._startTime===0&&this._rawPrevTime===0||(C=F),F=F._next;else for(F=this._last;F&&F._startTime>=O&&!C;)F._duration||F.data==="isPause"&&F._rawPrevTime>0&&(C=F),F=F._prev;C&&C._startTime<J&&(this._time=O=C._startTime,this._totalTime=O+this._cycle*(this._totalDuration+this._repeatDelay))}if(this._cycle!==G&&!this._locked){var Pt=this._yoyo&&(1&G)!==0,Et=Pt===(this._yoyo&&(1&this._cycle)!==0),At=this._totalTime,ce=this._cycle,re=this._rawPrevTime,Ft=this._time;if(this._totalTime=G*J,this._cycle<G?Pt=!Pt:this._totalTime+=J,this._time=N,this._rawPrevTime=J===0?tt-1e-4:tt,this._cycle=G,this._locked=!0,N=Pt?0:J,this.render(N,k,J===0),k||this._gc||this.vars.onRepeat&&(this._cycle=ce,this._locked=!1,this._callback("onRepeat")),N!==this._time||(Et&&(this._cycle=G,this._locked=!0,N=Pt?J+1e-4:-1e-4,this.render(N,!0,!1)),this._locked=!1,this._paused&&!_t))return;this._time=Ft,this._totalTime=At,this._cycle=ce,this._rawPrevTime=re}if(!(this._time!==N&&this._first||I||M||C))return void(Z!==this._totalTime&&this._onUpdate&&(k||this._callback("onUpdate")));if(this._initted||(this._initted=!0),this._active||!this._paused&&this._totalTime!==Z&&O>0&&(this._active=!0),Z===0&&this.vars.onStart&&(this._totalTime===0&&this._totalDuration||k||this._callback("onStart")),U=this._time,U>=N)for(F=this._first;F&&(P=F._next,U===this._time&&(!this._paused||_t));)(F._active||F._startTime<=this._time&&!F._paused&&!F._gc)&&(C===F&&this.pause(),F._reversed?F.render((F._dirty?F.totalDuration():F._totalDuration)-(O-F._startTime)*F._timeScale,k,I):F.render((O-F._startTime)*F._timeScale,k,I)),F=P;else for(F=this._last;F&&(P=F._prev,U===this._time&&(!this._paused||_t));){if(F._active||F._startTime<=N&&!F._paused&&!F._gc){if(C===F){for(C=F._prev;C&&C.endTime()>this._time;)C.render(C._reversed?C.totalDuration()-(O-C._startTime)*C._timeScale:(O-C._startTime)*C._timeScale,k,I),C=C._prev;C=null,this.pause()}F._reversed?F.render((F._dirty?F.totalDuration():F._totalDuration)-(O-F._startTime)*F._timeScale,k,I):F.render((O-F._startTime)*F._timeScale,k,I)}F=P}this._onUpdate&&(k||(m.length&&g(),this._callback("onUpdate"))),w&&(this._locked||this._gc||(ct===this._startTime||Rt!==this._timeScale)&&(this._time===0||X>=this.totalDuration())&&(E&&(m.length&&g(),this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!k&&this.vars[w]&&this._callback(w)))},b.getActive=function(O,k,I){O==null&&(O=!0),k==null&&(k=!0),I==null&&(I=!1);var F,E,P=[],w=this.getChildren(O,k,I),M=0,R=w.length;for(F=0;R>F;F++)E=w[F],E.isActive()&&(P[M++]=E);return P},b.getLabelAfter=function(O){O||O!==0&&(O=this._time);var k,I=this.getLabelsArray(),F=I.length;for(k=0;F>k;k++)if(I[k].time>O)return I[k].name;return null},b.getLabelBefore=function(O){O==null&&(O=this._time);for(var k=this.getLabelsArray(),I=k.length;--I>-1;)if(k[I].time<O)return k[I].name;return null},b.getLabelsArray=function(){var O,k=[],I=0;for(O in this._labels)k[I++]={time:this._labels[O],name:O};return k.sort(function(F,E){return F.time-E.time}),k},b.invalidate=function(){return this._locked=!1,x.prototype.invalidate.call(this)},b.progress=function(O,k){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&1&this._cycle?1-O:O)+this._cycle*(this._duration+this._repeatDelay),k):this._time/this.duration()||0},b.totalProgress=function(O,k){return arguments.length?this.totalTime(this.totalDuration()*O,k):this._totalTime/this.totalDuration()||0},b.totalDuration=function(O){return arguments.length?this._repeat!==-1&&O?this.timeScale(this.totalDuration()/O):this:(this._dirty&&(x.prototype.totalDuration.call(this),this._totalDuration=this._repeat===-1?999999999999:this._duration*(this._repeat+1)+this._repeatDelay*this._repeat),this._totalDuration)},b.time=function(O,k){return arguments.length?(this._dirty&&this.totalDuration(),O>this._duration&&(O=this._duration),this._yoyo&&1&this._cycle?O=this._duration-O+this._cycle*(this._duration+this._repeatDelay):this._repeat!==0&&(O+=this._cycle*(this._duration+this._repeatDelay)),this.totalTime(O,k)):this._time},b.repeat=function(O){return arguments.length?(this._repeat=O,this._uncache(!0)):this._repeat},b.repeatDelay=function(O){return arguments.length?(this._repeatDelay=O,this._uncache(!0)):this._repeatDelay},b.yoyo=function(O){return arguments.length?(this._yoyo=O,this):this._yoyo},b.currentLabel=function(O){return arguments.length?this.seek(O,!0):this.getLabelBefore(this._time+1e-8)},c},!0),function(){var x=180/Math.PI,a=[],o=[],c=[],f={},u=ln._gsDefine.globals,m=function(w,M,R,C){R===C&&(R=C-(C-M)/1e6),w===M&&(M=w+(R-w)/1e6),this.a=w,this.b=M,this.c=R,this.d=C,this.da=C-w,this.ca=R-w,this.ba=M-w},g=",x,y,z,left,top,right,bottom,marginTop,marginLeft,marginRight,marginBottom,paddingLeft,paddingTop,paddingRight,paddingBottom,backgroundPosition,backgroundPosition_y,",v=function(w,M,R,C){var U={a:w},N={},X={},J={c:C},Z=(w+M)/2,ct=(M+R)/2,Rt=(R+C)/2,tt=(Z+ct)/2,_t=(ct+Rt)/2,G=(_t-tt)/8;return U.b=Z+(w-Z)/4,N.b=tt+G,U.c=N.a=(U.b+N.b)/2,N.c=X.a=(tt+_t)/2,X.b=_t-G,J.b=Rt+(C-Rt)/4,X.c=J.a=(X.b+J.b)/2,[U,N,X,J]},S=function(w,M,R,C,U){var N,X,J,Z,ct,Rt,tt,_t,G,Pt,Et,At,ce,re=w.length-1,Ft=0,It=w[0].a;for(N=0;re>N;N++)ct=w[Ft],X=ct.a,J=ct.d,Z=w[Ft+1].d,U?(Et=a[N],At=o[N],ce=(At+Et)*M*.25/(C?.5:c[N]||.5),Rt=J-(J-X)*(C?.5*M:Et!==0?ce/Et:0),tt=J+(Z-J)*(C?.5*M:At!==0?ce/At:0),_t=J-(Rt+((tt-Rt)*(3*Et/(Et+At)+.5)/4||0))):(Rt=J-(J-X)*M*.5,tt=J+(Z-J)*M*.5,_t=J-(Rt+tt)/2),Rt+=_t,tt+=_t,ct.c=G=Rt,N!==0?ct.b=It:ct.b=It=ct.a+.6*(ct.c-ct.a),ct.da=J-X,ct.ca=G-X,ct.ba=It-X,R?(Pt=v(X,It,G,J),w.splice(Ft,1,Pt[0],Pt[1],Pt[2],Pt[3]),Ft+=4):Ft++,It=tt;ct=w[Ft],ct.b=It,ct.c=It+.4*(ct.d-It),ct.da=ct.d-ct.a,ct.ca=ct.c-ct.a,ct.ba=It-ct.a,R&&(Pt=v(ct.a,It,ct.c,ct.d),w.splice(Ft,1,Pt[0],Pt[1],Pt[2],Pt[3]))},b=function(w,M,R,C){var U,N,X,J,Z,ct,Rt=[];if(C)for(w=[C].concat(w),N=w.length;--N>-1;)typeof(ct=w[N][M])=="string"&&ct.charAt(1)==="="&&(w[N][M]=C[M]+Number(ct.charAt(0)+ct.substr(2)));if(U=w.length-2,0>U)return Rt[0]=new m(w[0][M],0,0,w[0][M]),Rt;for(N=0;U>N;N++)X=w[N][M],J=w[N+1][M],Rt[N]=new m(X,0,0,J),R&&(Z=w[N+2][M],a[N]=(a[N]||0)+(J-X)*(J-X),o[N]=(o[N]||0)+(Z-J)*(Z-J));return Rt[N]=new m(w[N][M],0,0,w[N+1][M]),Rt},O=function(w,M,R,C,U,N){var X,J,Z,ct,Rt,tt,_t,G,Pt={},Et=[],At=N||w[0];U=typeof U=="string"?","+U+",":g,M==null&&(M=1);for(J in w[0])Et.push(J);if(w.length>1){for(G=w[w.length-1],_t=!0,X=Et.length;--X>-1;)if(J=Et[X],Math.abs(At[J]-G[J])>.05){_t=!1;break}_t&&(w=w.concat(),N&&w.unshift(N),w.push(w[1]),N=w[w.length-3])}for(a.length=o.length=c.length=0,X=Et.length;--X>-1;)J=Et[X],f[J]=U.indexOf(","+J+",")!==-1,Pt[J]=b(w,J,f[J],N);for(X=a.length;--X>-1;)a[X]=Math.sqrt(a[X]),o[X]=Math.sqrt(o[X]);if(!C){for(X=Et.length;--X>-1;)if(f[J])for(Z=Pt[Et[X]],tt=Z.length-1,ct=0;tt>ct;ct++)Rt=Z[ct+1].da/o[ct]+Z[ct].da/a[ct]||0,c[ct]=(c[ct]||0)+Rt*Rt;for(X=c.length;--X>-1;)c[X]=Math.sqrt(c[X])}for(X=Et.length,ct=R?4:1;--X>-1;)J=Et[X],Z=Pt[J],S(Z,M,R,C,f[J]),_t&&(Z.splice(0,ct),Z.splice(Z.length-ct,ct));return Pt},k=function(w,M,R){M=M||"soft";var C,U,N,X,J,Z,ct,Rt,tt,_t,G,Pt={},Et=M==="cubic"?3:2,At=M==="soft",ce=[];if(At&&R&&(w=[R].concat(w)),w==null||w.length<Et+1)throw"invalid Bezier data";for(tt in w[0])ce.push(tt);for(Z=ce.length;--Z>-1;){for(tt=ce[Z],Pt[tt]=J=[],_t=0,Rt=w.length,ct=0;Rt>ct;ct++)C=R==null?w[ct][tt]:typeof(G=w[ct][tt])=="string"&&G.charAt(1)==="="?R[tt]+Number(G.charAt(0)+G.substr(2)):Number(G),At&&ct>1&&Rt-1>ct&&(J[_t++]=(C+J[_t-2])/2),J[_t++]=C;for(Rt=_t-Et+1,_t=0,ct=0;Rt>ct;ct+=Et)C=J[ct],U=J[ct+1],N=J[ct+2],X=Et===2?0:J[ct+3],J[_t++]=G=Et===3?new m(C,U,N,X):new m(C,(2*U+C)/3,(2*U+N)/3,N);J.length=_t}return Pt},I=function(w,M,R){for(var C,U,N,X,J,Z,ct,Rt,tt,_t,G,Pt=1/R,Et=w.length;--Et>-1;)for(_t=w[Et],N=_t.a,X=_t.d-N,J=_t.c-N,Z=_t.b-N,C=U=0,Rt=1;R>=Rt;Rt++)ct=Pt*Rt,tt=1-ct,C=U-(U=(ct*ct*X+3*tt*(ct*J+tt*Z))*ct),G=Et*R+Rt-1,M[G]=(M[G]||0)+C*C},F=function(w,M){M=M>>0||6;var R,C,U,N,X=[],J=[],Z=0,ct=0,Rt=M-1,tt=[],_t=[];for(R in w)I(w[R],X,M);for(U=X.length,C=0;U>C;C++)Z+=Math.sqrt(X[C]),N=C%M,_t[N]=Z,N===Rt&&(ct+=Z,N=C/M>>0,tt[N]=_t,J[N]=ct,Z=0,_t=[]);return{length:ct,lengths:J,segments:tt}},E=ln._gsDefine.plugin({propName:"bezier",priority:-1,version:"1.3.8",API:2,global:!0,init:function(w,M,R){this._target=w,M instanceof Array&&(M={values:M}),this._func={},this._mod={},this._props=[],this._timeRes=M.timeResolution==null?6:parseInt(M.timeResolution,10);var C,U,N,X,J,Z=M.values||[],ct={},Rt=Z[0],tt=M.autoRotate||R.vars.orientToBezier;this._autoRotate=tt?tt instanceof Array?tt:[["x","y","rotation",tt===!0?0:Number(tt)||0]]:null;for(C in Rt)this._props.push(C);for(N=this._props.length;--N>-1;)C=this._props[N],this._overwriteProps.push(C),U=this._func[C]=typeof w[C]=="function",ct[C]=U?w[C.indexOf("set")||typeof w["get"+C.substr(3)]!="function"?C:"get"+C.substr(3)]():parseFloat(w[C]),J||ct[C]!==Z[0][C]&&(J=ct);if(this._beziers=M.type!=="cubic"&&M.type!=="quadratic"&&M.type!=="soft"?O(Z,isNaN(M.curviness)?1:M.curviness,!1,M.type==="thruBasic",M.correlate,J):k(Z,M.type,ct),this._segCount=this._beziers[C].length,this._timeRes){var _t=F(this._beziers,this._timeRes);this._length=_t.length,this._lengths=_t.lengths,this._segments=_t.segments,this._l1=this._li=this._s1=this._si=0,this._l2=this._lengths[0],this._curSeg=this._segments[0],this._s2=this._curSeg[0],this._prec=1/this._curSeg.length}if(tt=this._autoRotate)for(this._initialRotations=[],tt[0]instanceof Array||(this._autoRotate=tt=[tt]),N=tt.length;--N>-1;){for(X=0;3>X;X++)C=tt[N][X],this._func[C]=typeof w[C]=="function"?w[C.indexOf("set")||typeof w["get"+C.substr(3)]!="function"?C:"get"+C.substr(3)]:!1;C=tt[N][2],this._initialRotations[N]=(this._func[C]?this._func[C].call(this._target):this._target[C])||0,this._overwriteProps.push(C)}return this._startRatio=R.vars.runBackwards?1:0,!0},set:function(w){var M,R,C,U,N,X,J,Z,ct,Rt,tt=this._segCount,_t=this._func,G=this._target,Pt=w!==this._startRatio;if(this._timeRes){if(ct=this._lengths,Rt=this._curSeg,w*=this._length,C=this._li,w>this._l2&&tt-1>C){for(Z=tt-1;Z>C&&(this._l2=ct[++C])<=w;);this._l1=ct[C-1],this._li=C,this._curSeg=Rt=this._segments[C],this._s2=Rt[this._s1=this._si=0]}else if(w<this._l1&&C>0){for(;C>0&&(this._l1=ct[--C])>=w;);C===0&&w<this._l1?this._l1=0:C++,this._l2=ct[C],this._li=C,this._curSeg=Rt=this._segments[C],this._s1=Rt[(this._si=Rt.length-1)-1]||0,this._s2=Rt[this._si]}if(M=C,w-=this._l1,C=this._si,w>this._s2&&C<Rt.length-1){for(Z=Rt.length-1;Z>C&&(this._s2=Rt[++C])<=w;);this._s1=Rt[C-1],this._si=C}else if(w<this._s1&&C>0){for(;C>0&&(this._s1=Rt[--C])>=w;);C===0&&w<this._s1?this._s1=0:C++,this._s2=Rt[C],this._si=C}X=(C+(w-this._s1)/(this._s2-this._s1))*this._prec||0}else M=0>w?0:w>=1?tt-1:tt*w>>0,X=(w-M*(1/tt))*tt;for(R=1-X,C=this._props.length;--C>-1;)U=this._props[C],N=this._beziers[U][M],J=(X*X*N.da+3*R*(X*N.ca+R*N.ba))*X+N.a,this._mod[U]&&(J=this._mod[U](J,G)),_t[U]?G[U](J):G[U]=J;if(this._autoRotate){var Et,At,ce,re,Ft,It,Nt,Pe=this._autoRotate;for(C=Pe.length;--C>-1;)U=Pe[C][2],It=Pe[C][3]||0,Nt=Pe[C][4]===!0?1:x,N=this._beziers[Pe[C][0]],Et=this._beziers[Pe[C][1]],N&&Et&&(N=N[M],Et=Et[M],At=N.a+(N.b-N.a)*X,re=N.b+(N.c-N.b)*X,At+=(re-At)*X,re+=(N.c+(N.d-N.c)*X-re)*X,ce=Et.a+(Et.b-Et.a)*X,Ft=Et.b+(Et.c-Et.b)*X,ce+=(Ft-ce)*X,Ft+=(Et.c+(Et.d-Et.c)*X-Ft)*X,J=Pt?Math.atan2(Ft-ce,re-At)*Nt+It:this._initialRotations[C],this._mod[U]&&(J=this._mod[U](J,G)),_t[U]?G[U](J):G[U]=J)}}}),P=E.prototype;E.bezierThrough=O,E.cubicToQuadratic=v,E._autoCSS=!0,E.quadraticToCubic=function(w,M,R){return new m(w,(2*M+w)/3,(2*M+R)/3,R)},E._cssRegister=function(){var w=u.CSSPlugin;if(w){var M=w._internals,R=M._parseToProxy,C=M._setPluginRatio,U=M.CSSPropTween;M._registerComplexSpecialProp("bezier",{parser:function(N,X,J,Z,ct,Rt){X instanceof Array&&(X={values:X}),Rt=new E;var tt,_t,G,Pt=X.values,Et=Pt.length-1,At=[],ce={};if(0>Et)return ct;for(tt=0;Et>=tt;tt++)G=R(N,Pt[tt],Z,ct,Rt,Et!==tt),At[tt]=G.end;for(_t in X)ce[_t]=X[_t];return ce.values=At,ct=new U(N,"bezier",0,0,G.pt,2),ct.data=G,ct.plugin=Rt,ct.setRatio=C,ce.autoRotate===0&&(ce.autoRotate=!0),!ce.autoRotate||ce.autoRotate instanceof Array||(tt=ce.autoRotate===!0?0:Number(ce.autoRotate),ce.autoRotate=G.end.left!=null?[["left","top","rotation",tt,!1]]:G.end.x!=null?[["x","y","rotation",tt,!1]]:!1),ce.autoRotate&&(Z._transform||Z._enableTransforms(!1),G.autoRotate=Z._target._gsTransform,G.proxy.rotation=G.autoRotate.rotation||0,Z._overwriteProps.push("rotation")),Rt._onInitTween(G.proxy,ce,Z._tween),ct}})}},P._mod=function(w){for(var M,R=this._overwriteProps,C=R.length;--C>-1;)M=w[R[C]],M&&typeof M=="function"&&(this._mod[R[C]]=M)},P._kill=function(w){var M,R,C=this._props;for(M in this._beziers)if(M in w)for(delete this._beziers[M],delete this._func[M],R=C.length;--R>-1;)C[R]===M&&C.splice(R,1);if(C=this._autoRotate)for(R=C.length;--R>-1;)w[C[R][2]]&&C.splice(R,1);return this._super._kill.call(this,w)}}(),ln._gsDefine("plugins.CSSPlugin",["plugins.TweenPlugin","TweenLite"],function(x,a){var o,c,f,u,m=function(){x.call(this,"css"),this._overwriteProps.length=0,this.setRatio=m.prototype.setRatio},g=ln._gsDefine.globals,v={},S=m.prototype=new x("css");S.constructor=m,m.version="2.0.2",m.API=2,m.defaultTransformPerspective=0,m.defaultSkewType="compensated",m.defaultSmoothOrigin=!0,S="px",m.suffixMap={top:S,right:S,bottom:S,left:S,width:S,height:S,fontSize:S,padding:S,margin:S,perspective:S,lineHeight:""};var b,O,k,I,F,E,P,w,M=/(?:\-|\.|\b)(\d|\.|e\-)+/g,R=/(?:\d|\-\d|\.\d|\-\.\d|\+=\d|\-=\d|\+=.\d|\-=\.\d)+/g,C=/(?:\+=|\-=|\-|\b)[\d\-\.]+[a-zA-Z0-9]*(?:%|\b)/gi,U=/(?![+-]?\d*\.?\d+|[+-]|e[+-]\d+)[^0-9]/g,N=/(?:\d|\-|\+|=|#|\.)*/g,X=/opacity *= *([^)]*)/i,J=/opacity:([^;]*)/i,Z=/alpha\(opacity *=.+?\)/i,ct=/^(rgb|hsl)/,Rt=/([A-Z])/g,tt=/-([a-z])/gi,_t=/(^(?:url\(\"|url\())|(?:(\"\))$|\)$)/gi,G=function(V,et){return et.toUpperCase()},Pt=/(?:Left|Right|Width)/i,Et=/(M11|M12|M21|M22)=[\d\-\.e]+/gi,At=/progid\:DXImageTransform\.Microsoft\.Matrix\(.+?\)/i,ce=/,(?=[^\)]*(?:\(|$))/gi,re=/[\s,\(]/i,Ft=Math.PI/180,It=180/Math.PI,Nt={},Pe={style:{}},pe=ln.document||{createElement:function(){return Pe}},Wt=function(V,et){return pe.createElementNS?pe.createElementNS(et||"http://www.w3.org/1999/xhtml",V):pe.createElement(V)},$e=Wt("div"),Si=Wt("img"),Oe=m._internals={_specialProps:v},Ge=(ln.navigator||{}).userAgent||"",pi=function(){var V=Ge.indexOf("Android"),et=Wt("a");return k=Ge.indexOf("Safari")!==-1&&Ge.indexOf("Chrome")===-1&&(V===-1||parseFloat(Ge.substr(V+8,2))>3),F=k&&parseFloat(Ge.substr(Ge.indexOf("Version/")+8,2))<6,I=Ge.indexOf("Firefox")!==-1,(/MSIE ([0-9]{1,}[\.0-9]{0,})/.exec(Ge)||/Trident\/.*rv:([0-9]{1,}[\.0-9]{0,})/.exec(Ge))&&(E=parseFloat(RegExp.$1)),et?(et.style.cssText="top:1px;opacity:.55;",/^0.55/.test(et.style.opacity)):!1}(),Di=function(V){return X.test(typeof V=="string"?V:(V.currentStyle?V.currentStyle.filter:V.style.filter)||"")?parseFloat(RegExp.$1)/100:1},mn=function(V){ln.console},Qi="",W="",Jt=function(V,et){et=et||$e;var lt,at,j=et.style;if(j[V]!==void 0)return V;for(V=V.charAt(0).toUpperCase()+V.substr(1),lt=["O","Moz","ms","Ms","Webkit"],at=5;--at>-1&&j[lt[at]+V]===void 0;);return at>=0?(W=at===3?"ms":lt[at],Qi="-"+W.toLowerCase()+"-",W+V):null},jt=(typeof window<"u"?window:pe.defaultView||{getComputedStyle:function(){}}).getComputedStyle,dt=m.getStyle=function(V,et,lt,at,j){var St;return pi||et!=="opacity"?(!at&&V.style[et]?St=V.style[et]:(lt=lt||jt(V))?St=lt[et]||lt.getPropertyValue(et)||lt.getPropertyValue(et.replace(Rt,"-$1").toLowerCase()):V.currentStyle&&(St=V.currentStyle[et]),j==null||St&&St!=="none"&&St!=="auto"&&St!=="auto auto"?St:j):Di(V)},pt=Oe.convertToPixels=function(V,et,lt,at,j){if(at==="px"||!at&&et!=="lineHeight")return lt;if(at==="auto"||!lt)return 0;var St,ht,Ot,Gt=Pt.test(et),zt=V,Mt=$e.style,he=0>lt,se=lt===1;if(he&&(lt=-lt),se&&(lt*=100),et!=="lineHeight"||at)if(at==="%"&&et.indexOf("border")!==-1)St=lt/100*(Gt?V.clientWidth:V.clientHeight);else{if(Mt.cssText="border:0 solid red;position:"+dt(V,"position")+";line-height:0;",at!=="%"&&zt.appendChild&&at.charAt(0)!=="v"&&at!=="rem")Mt[Gt?"borderLeftWidth":"borderTopWidth"]=lt+at;else{if(zt=V.parentNode||pe.body,dt(zt,"display").indexOf("flex")!==-1&&(Mt.position="absolute"),ht=zt._gsCache,Ot=a.ticker.frame,ht&&Gt&&ht.time===Ot)return ht.width*lt/100;Mt[Gt?"width":"height"]=lt+at}zt.appendChild($e),St=parseFloat($e[Gt?"offsetWidth":"offsetHeight"]),zt.removeChild($e),Gt&&at==="%"&&m.cacheWidths!==!1&&(ht=zt._gsCache=zt._gsCache||{},ht.time=Ot,ht.width=St/lt*100),St!==0||j||(St=pt(V,et,lt,at,!0))}else ht=jt(V).lineHeight,V.style.lineHeight=lt,St=parseFloat(jt(V).lineHeight),V.style.lineHeight=ht;return se&&(St/=100),he?-St:St},Dt=Oe.calculateOffset=function(V,et,lt){if(dt(V,"position",lt)!=="absolute")return 0;var at=et==="left"?"Left":"Top",j=dt(V,"margin"+at,lt);return V["offset"+at]-(pt(V,et,parseFloat(j),j.replace(N,""))||0)},ie=function(V,et){var lt,at,j,St={};if(et=et||jt(V,null))if(lt=et.length)for(;--lt>-1;)j=et[lt],(j.indexOf("-transform")===-1||ra===j)&&(St[j.replace(tt,G)]=et.getPropertyValue(j));else for(lt in et)(lt.indexOf("Transform")===-1||Mn===lt)&&(St[lt]=et[lt]);else if(et=V.currentStyle||V.style)for(lt in et)typeof lt=="string"&&St[lt]===void 0&&(St[lt.replace(tt,G)]=et[lt]);return pi||(St.opacity=Di(V)),at=uo(V,et,!1),St.rotation=at.rotation,St.skewX=at.skewX,St.scaleX=at.scaleX,St.scaleY=at.scaleY,St.x=at.x,St.y=at.y,vr&&(St.z=at.z,St.rotationX=at.rotationX,St.rotationY=at.rotationY,St.scaleZ=at.scaleZ),St.filters&&delete St.filters,St},Kt=function(V,et,lt,at,j){var St,ht,Ot,Gt={},zt=V.style;for(ht in lt)ht!=="cssText"&&ht!=="length"&&isNaN(ht)&&(et[ht]!==(St=lt[ht])||j&&j[ht])&&ht.indexOf("Origin")===-1&&(typeof St=="number"||typeof St=="string")&&(Gt[ht]=St!=="auto"||ht!=="left"&&ht!=="top"?St!==""&&St!=="auto"&&St!=="none"||typeof et[ht]!="string"||et[ht].replace(U,"")===""?St:0:Dt(V,ht),zt[ht]!==void 0&&(Ot=new ni(zt,ht,zt[ht],Ot)));if(at)for(ht in at)ht!=="className"&&(Gt[ht]=at[ht]);return{difs:Gt,firstMPT:Ot}},z={width:["Left","Right"],height:["Top","Bottom"]},Q=["marginLeft","marginRight","marginTop","marginBottom"],st=function(V,et,lt){if((V.nodeName+"").toLowerCase()==="svg")return(lt||jt(V))[et]||0;if(V.getCTM&&Wl(V))return V.getBBox()[et]||0;var at=parseFloat(et==="width"?V.offsetWidth:V.offsetHeight),j=z[et],St=j.length;for(lt=lt||jt(V,null);--St>-1;)at-=parseFloat(dt(V,"padding"+j[St],lt,!0))||0,at-=parseFloat(dt(V,"border"+j[St]+"Width",lt,!0))||0;return at},nt=function(V,et){if(V==="contain"||V==="auto"||V==="auto auto")return V+" ";(V==null||V==="")&&(V="0 0");var lt,at=V.split(" "),j=V.indexOf("left")!==-1?"0%":V.indexOf("right")!==-1?"100%":at[0],St=V.indexOf("top")!==-1?"0%":V.indexOf("bottom")!==-1?"100%":at[1];if(at.length>3&&!et){for(at=V.split(", ").join(",").split(","),V=[],lt=0;lt<at.length;lt++)V.push(nt(at[lt]));return V.join(",")}return St==null?St=j==="center"?"50%":"0":St==="center"&&(St="50%"),(j==="center"||isNaN(parseFloat(j))&&(j+"").indexOf("=")===-1)&&(j="50%"),V=j+" "+St+(at.length>2?" "+at[2]:""),et&&(et.oxp=j.indexOf("%")!==-1,et.oyp=St.indexOf("%")!==-1,et.oxr=j.charAt(1)==="=",et.oyr=St.charAt(1)==="=",et.ox=parseFloat(j.replace(U,"")),et.oy=parseFloat(St.replace(U,"")),et.v=V),et||V},vt=function(V,et){return typeof V=="function"&&(V=V(w,P)),typeof V=="string"&&V.charAt(1)==="="?parseInt(V.charAt(0)+"1",10)*parseFloat(V.substr(2)):parseFloat(V)-parseFloat(et)||0},Ut=function(V,et){typeof V=="function"&&(V=V(w,P));var lt=typeof V=="string"&&V.charAt(1)==="=";return typeof V=="string"&&V.charAt(V.length-2)==="v"&&(V=(lt?V.substr(0,2):0)+window["inner"+(V.substr(-2)==="vh"?"Height":"Width")]*(parseFloat(lt?V.substr(2):V)/100)),V==null?et:lt?parseInt(V.charAt(0)+"1",10)*parseFloat(V.substr(2))+et:parseFloat(V)||0},qt=function(V,et,lt,at){var j,St,ht,Ot,Gt,zt=1e-6;return typeof V=="function"&&(V=V(w,P)),V==null?Ot=et:typeof V=="number"?Ot=V:(j=360,St=V.split("_"),Gt=V.charAt(1)==="=",ht=(Gt?parseInt(V.charAt(0)+"1",10)*parseFloat(St[0].substr(2)):parseFloat(St[0]))*(V.indexOf("rad")===-1?1:It)-(Gt?0:et),St.length&&(at&&(at[lt]=et+ht),V.indexOf("short")!==-1&&(ht%=j,ht!==ht%(j/2)&&(ht=0>ht?ht+j:ht-j)),V.indexOf("_cw")!==-1&&0>ht?ht=(ht+9999999999*j)%j-(ht/j|0)*j:V.indexOf("ccw")!==-1&&ht>0&&(ht=(ht-9999999999*j)%j-(ht/j|0)*j)),Ot=et+ht),zt>Ot&&Ot>-zt&&(Ot=0),Ot},Xt={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],fuchsia:[255,0,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]},Ne=function(V,et,lt){return V=0>V?V+1:V>1?V-1:V,255*(1>6*V?et+(lt-et)*V*6:.5>V?lt:2>3*V?et+(lt-et)*(2/3-V)*6:et)+.5|0},Ie=m.parseColor=function(V,et){var lt,at,j,St,ht,Ot,Gt,zt,Mt,he,se;if(V)if(typeof V=="number")lt=[V>>16,V>>8&255,255&V];else{if(V.charAt(V.length-1)===","&&(V=V.substr(0,V.length-1)),Xt[V])lt=Xt[V];else if(V.charAt(0)==="#")V.length===4&&(at=V.charAt(1),j=V.charAt(2),St=V.charAt(3),V="#"+at+at+j+j+St+St),V=parseInt(V.substr(1),16),lt=[V>>16,V>>8&255,255&V];else if(V.substr(0,3)==="hsl")if(lt=se=V.match(M),et){if(V.indexOf("=")!==-1)return V.match(R)}else ht=Number(lt[0])%360/360,Ot=Number(lt[1])/100,Gt=Number(lt[2])/100,j=.5>=Gt?Gt*(Ot+1):Gt+Ot-Gt*Ot,at=2*Gt-j,lt.length>3&&(lt[3]=Number(lt[3])),lt[0]=Ne(ht+1/3,at,j),lt[1]=Ne(ht,at,j),lt[2]=Ne(ht-1/3,at,j);else lt=V.match(M)||Xt.transparent;lt[0]=Number(lt[0]),lt[1]=Number(lt[1]),lt[2]=Number(lt[2]),lt.length>3&&(lt[3]=Number(lt[3]))}else lt=Xt.black;return et&&!se&&(at=lt[0]/255,j=lt[1]/255,St=lt[2]/255,zt=Math.max(at,j,St),Mt=Math.min(at,j,St),Gt=(zt+Mt)/2,zt===Mt?ht=Ot=0:(he=zt-Mt,Ot=Gt>.5?he/(2-zt-Mt):he/(zt+Mt),ht=zt===at?(j-St)/he+(St>j?6:0):zt===j?(St-at)/he+2:(at-j)/he+4,ht*=60),lt[0]=ht+.5|0,lt[1]=100*Ot+.5|0,lt[2]=100*Gt+.5|0),lt},me=function(V,et){var lt,at,j,St=V.match(we)||[],ht=0,Ot="";if(!St.length)return V;for(lt=0;lt<St.length;lt++)at=St[lt],j=V.substr(ht,V.indexOf(at,ht)-ht),ht+=j.length+at.length,at=Ie(at,et),at.length===3&&at.push(1),Ot+=j+(et?"hsla("+at[0]+","+at[1]+"%,"+at[2]+"%,"+at[3]:"rgba("+at.join(","))+")";return Ot+V.substr(ht)},we="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3}){1,2}\\b";for(S in Xt)we+="|"+S+"\\b";we=new RegExp(we+")","gi"),m.colorStringFilter=function(V){var et,lt=V[0]+" "+V[1];we.test(lt)&&(et=lt.indexOf("hsl(")!==-1||lt.indexOf("hsla(")!==-1,V[0]=me(V[0],et),V[1]=me(V[1],et)),we.lastIndex=0},a.defaultStringFilter||(a.defaultStringFilter=m.colorStringFilter);var yi=function(V,et,lt,at){if(V==null)return function(se){return se};var j,St=et?(V.match(we)||[""])[0]:"",ht=V.split(St).join("").match(C)||[],Ot=V.substr(0,V.indexOf(ht[0])),Gt=V.charAt(V.length-1)===")"?")":"",zt=V.indexOf(" ")!==-1?" ":",",Mt=ht.length,he=Mt>0?ht[0].replace(M,""):"";return Mt?j=et?function(se){var te,ye,ue,je;if(typeof se=="number")se+=he;else if(at&&ce.test(se)){for(je=se.replace(ce,"|").split("|"),ue=0;ue<je.length;ue++)je[ue]=j(je[ue]);return je.join(",")}if(te=(se.match(we)||[St])[0],ye=se.split(te).join("").match(C)||[],ue=ye.length,Mt>ue--)for(;++ue<Mt;)ye[ue]=lt?ye[(ue-1)/2|0]:ht[ue];return Ot+ye.join(zt)+zt+te+Gt+(se.indexOf("inset")!==-1?" inset":"")}:function(se){var te,ye,ue;if(typeof se=="number")se+=he;else if(at&&ce.test(se)){for(ye=se.replace(ce,"|").split("|"),ue=0;ue<ye.length;ue++)ye[ue]=j(ye[ue]);return ye.join(",")}if(te=se.match(C)||[],ue=te.length,Mt>ue--)for(;++ue<Mt;)te[ue]=lt?te[(ue-1)/2|0]:ht[ue];return Ot+te.join(zt)+Gt}:function(se){return se}},Ei=function(V){return V=V.split(","),function(et,lt,at,j,St,ht,Ot){var Gt,zt=(lt+"").split(" ");for(Ot={},Gt=0;4>Gt;Gt++)Ot[V[Gt]]=zt[Gt]=zt[Gt]||zt[(Gt-1)/2>>0];return j.parse(et,Ot,St,ht)}},ni=(Oe._setPluginRatio=function(V){this.plugin.setRatio(V);for(var et,lt,at,j,St,ht=this.data,Ot=ht.proxy,Gt=ht.firstMPT,zt=1e-6;Gt;)et=Ot[Gt.v],Gt.r?et=Gt.r(et):zt>et&&et>-zt&&(et=0),Gt.t[Gt.p]=et,Gt=Gt._next;if(ht.autoRotate&&(ht.autoRotate.rotation=ht.mod?ht.mod.call(this._tween,Ot.rotation,this.t,this._tween):Ot.rotation),V===1||V===0)for(Gt=ht.firstMPT,St=V===1?"e":"b";Gt;){if(lt=Gt.t,lt.type){if(lt.type===1){for(j=lt.xs0+lt.s+lt.xs1,at=1;at<lt.l;at++)j+=lt["xn"+at]+lt["xs"+(at+1)];lt[St]=j}}else lt[St]=lt.s+lt.xs0;Gt=Gt._next}},function(V,et,lt,at,j){this.t=V,this.p=et,this.v=lt,this.r=j,at&&(at._prev=this,this._next=at)}),bi=(Oe._parseToProxy=function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he=at,se={},te={},ye=lt._transform,ue=Nt;for(lt._transform=null,Nt=et,at=Mt=lt.parse(V,et,at,j),Nt=ue,St&&(lt._transform=ye,he&&(he._prev=null,he._prev&&(he._prev._next=null)));at&&at!==he;){if(at.type<=1&&(Ot=at.p,te[Ot]=at.s+at.c,se[Ot]=at.s,St||(zt=new ni(at,"s",Ot,zt,at.r),at.c=0),at.type===1))for(ht=at.l;--ht>0;)Gt="xn"+ht,Ot=at.p+"_"+Gt,te[Ot]=at.data[Gt],se[Ot]=at[Gt],St||(zt=new ni(at,Gt,Ot,zt,at.rxp[Gt]));at=at._next}return{proxy:se,end:te,firstMPT:zt,pt:Mt}},Oe.CSSPropTween=function(V,et,lt,at,j,St,ht,Ot,Gt,zt,Mt){this.t=V,this.p=et,this.s=lt,this.c=at,this.n=ht||et,V instanceof bi||u.push(this.n),this.r=Ot&&(typeof Ot=="function"?Ot:Math.round),this.type=St||0,Gt&&(this.pr=Gt,o=!0),this.b=zt===void 0?lt:zt,this.e=Mt===void 0?lt+at:Mt,j&&(this._next=j,j._prev=this)}),qr=function(V,et,lt,at,j,St){var ht=new bi(V,et,lt,at-lt,j,-1,St);return ht.b=lt,ht.e=ht.xs0=at,ht},sr=m.parseComplex=function(V,et,lt,at,j,St,ht,Ot,Gt,zt){lt=lt||St||"",typeof at=="function"&&(at=at(w,P)),ht=new bi(V,et,0,0,ht,zt?2:1,null,!1,Ot,lt,at),at+="",j&&we.test(at+lt)&&(at=[lt,at],m.colorStringFilter(at),lt=at[0],at=at[1]);var Mt,he,se,te,ye,ue,je,He,ci,Be,_e,Fe,fe,mi=lt.split(", ").join(",").split(" "),Le=at.split(", ").join(",").split(" "),xe=mi.length,Re=b!==!1;for((at.indexOf(",")!==-1||lt.indexOf(",")!==-1)&&((at+lt).indexOf("rgb")!==-1||(at+lt).indexOf("hsl")!==-1?(mi=mi.join(" ").replace(ce,", ").split(" "),Le=Le.join(" ").replace(ce,", ").split(" ")):(mi=mi.join(" ").split(",").join(", ").split(" "),Le=Le.join(" ").split(",").join(", ").split(" ")),xe=mi.length),xe!==Le.length&&(mi=(St||"").split(" "),xe=mi.length),ht.plugin=Gt,ht.setRatio=zt,we.lastIndex=0,Mt=0;xe>Mt;Mt++)if(te=mi[Mt],ye=Le[Mt]+"",He=parseFloat(te),He||He===0)ht.appendXtra("",He,vt(ye,He),ye.replace(R,""),Re&&ye.indexOf("px")!==-1?Math.round:!1,!0);else if(j&&we.test(te))Fe=ye.indexOf(")")+1,Fe=")"+(Fe?ye.substr(Fe):""),fe=ye.indexOf("hsl")!==-1&&pi,Be=ye,te=Ie(te,fe),ye=Ie(ye,fe),ci=te.length+ye.length>6,ci&&!pi&&ye[3]===0?(ht["xs"+ht.l]+=ht.l?" transparent":"transparent",ht.e=ht.e.split(Le[Mt]).join("transparent")):(pi||(ci=!1),fe?ht.appendXtra(Be.substr(0,Be.indexOf("hsl"))+(ci?"hsla(":"hsl("),te[0],vt(ye[0],te[0]),",",!1,!0).appendXtra("",te[1],vt(ye[1],te[1]),"%,",!1).appendXtra("",te[2],vt(ye[2],te[2]),ci?"%,":"%"+Fe,!1):ht.appendXtra(Be.substr(0,Be.indexOf("rgb"))+(ci?"rgba(":"rgb("),te[0],ye[0]-te[0],",",Math.round,!0).appendXtra("",te[1],ye[1]-te[1],",",Math.round).appendXtra("",te[2],ye[2]-te[2],ci?",":Fe,Math.round),ci&&(te=te.length<4?1:te[3],ht.appendXtra("",te,(ye.length<4?1:ye[3])-te,Fe,!1))),we.lastIndex=0;else if(ue=te.match(M)){if(je=ye.match(R),!je||je.length!==ue.length)return ht;for(se=0,he=0;he<ue.length;he++)_e=ue[he],Be=te.indexOf(_e,se),ht.appendXtra(te.substr(se,Be-se),Number(_e),vt(je[he],_e),"",Re&&te.substr(Be+_e.length,2)==="px"?Math.round:!1,he===0),se=Be+_e.length;ht["xs"+ht.l]+=te.substr(se)}else ht["xs"+ht.l]+=ht.l||ht["xs"+ht.l]?" "+ye:ye;if(at.indexOf("=")!==-1&&ht.data){for(Fe=ht.xs0+ht.data.s,Mt=1;Mt<ht.l;Mt++)Fe+=ht["xs"+Mt]+ht.data["xn"+Mt];ht.e=Fe+ht["xs"+Mt]}return ht.l||(ht.type=-1,ht.xs0=ht.e),ht.xfirst||ht},sn=9;for(S=bi.prototype,S.l=S.pr=0;--sn>0;)S["xn"+sn]=0,S["xs"+sn]="";S.xs0="",S._next=S._prev=S.xfirst=S.data=S.plugin=S.setRatio=S.rxp=null,S.appendXtra=function(V,et,lt,at,j,St){var ht=this,Ot=ht.l;return ht["xs"+Ot]+=St&&(Ot||ht["xs"+Ot])?" "+V:V||"",lt||Ot===0||ht.plugin?(ht.l++,ht.type=ht.setRatio?2:1,ht["xs"+ht.l]=at||"",Ot>0?(ht.data["xn"+Ot]=et+lt,ht.rxp["xn"+Ot]=j,ht["xn"+Ot]=et,ht.plugin||(ht.xfirst=new bi(ht,"xn"+Ot,et,lt,ht.xfirst||ht,0,ht.n,j,ht.pr),ht.xfirst.xs0=0),ht):(ht.data={s:et+lt},ht.rxp={},ht.s=et,ht.c=lt,ht.r=j,ht)):(ht["xs"+Ot]+=et+(at||""),ht)};var Ao=function(V,et){et=et||{},this.p=et.prefix&&Jt(V)||V,v[V]=v[this.p]=this,this.format=et.formatter||yi(et.defaultValue,et.color,et.collapsible,et.multi),et.parser&&(this.parse=et.parser),this.clrs=et.color,this.multi=et.multi,this.keyword=et.keyword,this.dflt=et.defaultValue,this.pr=et.priority||0},zi=Oe._registerComplexSpecialProp=function(V,et,lt){typeof et!="object"&&(et={parser:lt});var at,j=V.split(","),St=et.defaultValue;for(lt=lt||[St],at=0;at<j.length;at++)et.prefix=at===0&&et.prefix,et.defaultValue=lt[at]||St,new Ao(j[at],et)},Yo=Oe._registerPluginProp=function(V){if(!v[V]){var et=V.charAt(0).toUpperCase()+V.substr(1)+"Plugin";zi(V,{parser:function(lt,at,j,St,ht,Ot,Gt){var zt=g.com.greensock.plugins[et];return zt?(zt._cssRegister(),v[j].parse(lt,at,j,St,ht,Ot,Gt)):(mn("Error: "+et+" js file not loaded."),ht)}})}};S=Ao.prototype,S.parseComplex=function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he,se=this.keyword;if(this.multi&&(ce.test(lt)||ce.test(et)?(Ot=et.replace(ce,"|").split("|"),Gt=lt.replace(ce,"|").split("|")):se&&(Ot=[et],Gt=[lt])),Gt){for(zt=Gt.length>Ot.length?Gt.length:Ot.length,ht=0;zt>ht;ht++)et=Ot[ht]=Ot[ht]||this.dflt,lt=Gt[ht]=Gt[ht]||this.dflt,se&&(Mt=et.indexOf(se),he=lt.indexOf(se),Mt!==he&&(he===-1?Ot[ht]=Ot[ht].split(se).join(""):Mt===-1&&(Ot[ht]+=" "+se)));et=Ot.join(", "),lt=Gt.join(", ")}return sr(V,this.p,et,lt,this.clrs,this.dflt,at,this.pr,j,St)},S.parse=function(V,et,lt,at,j,St,ht){return this.parseComplex(V.style,this.format(dt(V,this.p,f,!1,this.dflt)),this.format(et),j,St)},m.registerSpecialProp=function(V,et,lt){zi(V,{parser:function(at,j,St,ht,Ot,Gt,zt){var Mt=new bi(at,St,0,0,Ot,2,St,!1,lt);return Mt.plugin=Gt,Mt.setRatio=et(at,j,ht._tween,St),Mt},priority:lt})},m.useSVGTransformAttr=!0;var ao,Hl="scaleX,scaleY,scaleZ,x,y,z,skewX,skewY,rotation,rotationX,rotationY,perspective,xPercent,yPercent".split(","),Mn=Jt("transform"),ra=Qi+"transform",vs=Jt("transformOrigin"),vr=Jt("perspective")!==null,oa=Oe.Transform=function(){this.perspective=parseFloat(m.defaultTransformPerspective)||0,this.force3D=m.defaultForce3D!==!1&&vr?m.defaultForce3D||"auto":!1},Za=ln.SVGElement,Vl=function(V,et,lt){var at,j=pe.createElementNS("http://www.w3.org/2000/svg",V),St=/([a-z])([A-Z])/g;for(at in lt)j.setAttributeNS(null,at.replace(St,"$1-$2").toLowerCase(),lt[at]);return et.appendChild(j),j},lo=pe.documentElement||{},Oh=function(){var V,et,lt,at=E||/Android/i.test(Ge)&&!ln.chrome;return pe.createElementNS&&!at&&(V=Vl("svg",lo),et=Vl("rect",V,{width:100,height:50,x:100}),lt=et.getBoundingClientRect().width,et.style[vs]="50% 50%",et.style[Mn]="scaleX(0.5)",at=lt===et.getBoundingClientRect().width&&!(I&&vr),lo.removeChild(V)),at}(),sa=function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he,se,te,ye,ue,je,He,ci,Be,_e=V._gsTransform,Fe=la(V,!0);_e&&(ci=_e.xOrigin,Be=_e.yOrigin),(!at||(ht=at.split(" ")).length<2)&&(se=V.getBBox(),se.x===0&&se.y===0&&se.width+se.height===0&&(se={x:parseFloat(V.hasAttribute("x")?V.getAttribute("x"):V.hasAttribute("cx")?V.getAttribute("cx"):0)||0,y:parseFloat(V.hasAttribute("y")?V.getAttribute("y"):V.hasAttribute("cy")?V.getAttribute("cy"):0)||0,width:0,height:0}),et=nt(et).split(" "),ht=[(et[0].indexOf("%")!==-1?parseFloat(et[0])/100*se.width:parseFloat(et[0]))+se.x,(et[1].indexOf("%")!==-1?parseFloat(et[1])/100*se.height:parseFloat(et[1]))+se.y]),lt.xOrigin=zt=parseFloat(ht[0]),lt.yOrigin=Mt=parseFloat(ht[1]),at&&Fe!==aa&&(he=Fe[0],se=Fe[1],te=Fe[2],ye=Fe[3],ue=Fe[4],je=Fe[5],He=he*ye-se*te,He&&(Ot=zt*(ye/He)+Mt*(-te/He)+(te*je-ye*ue)/He,Gt=zt*(-se/He)+Mt*(he/He)-(he*je-se*ue)/He,zt=lt.xOrigin=ht[0]=Ot,Mt=lt.yOrigin=ht[1]=Gt)),_e&&(St&&(lt.xOffset=_e.xOffset,lt.yOffset=_e.yOffset,_e=lt),j||j!==!1&&m.defaultSmoothOrigin!==!1?(Ot=zt-ci,Gt=Mt-Be,_e.xOffset+=Ot*Fe[0]+Gt*Fe[2]-Ot,_e.yOffset+=Ot*Fe[1]+Gt*Fe[3]-Gt):_e.xOffset=_e.yOffset=0),St||V.setAttribute("data-svg-origin",ht.join(" "))},Ja=function(V){var et,lt=Wt("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),at=this.parentNode,j=this.nextSibling,St=this.style.cssText;if(lo.appendChild(lt),lt.appendChild(this),this.style.display="block",V)try{et=this.getBBox(),this._originalGetBBox=this.getBBox,this.getBBox=Ja}catch{}else this._originalGetBBox&&(et=this._originalGetBBox());return j?at.insertBefore(this,j):at.appendChild(this),lo.removeChild(lt),this.style.cssText=St,et},ho=function(V){try{return V.getBBox()}catch{return Ja.call(V,!0)}},Wl=function(V){return!(!Za||!V.getCTM||V.parentNode&&!V.ownerSVGElement||!ho(V))},aa=[1,0,0,1,0,0],la=function(V,et){var lt,at,j,St,ht,Ot,Gt=V._gsTransform||new oa,zt=1e5,Mt=V.style;if(Mn?at=dt(V,ra,null,!0):V.currentStyle&&(at=V.currentStyle.filter.match(Et),at=at&&at.length===4?[at[0].substr(4),Number(at[2].substr(4)),Number(at[1].substr(4)),at[3].substr(4),Gt.x||0,Gt.y||0].join(","):""),lt=!at||at==="none"||at==="matrix(1, 0, 0, 1, 0, 0)",!Mn||!(Ot=!jt(V)||jt(V).display==="none")&&V.parentNode||(Ot&&(St=Mt.display,Mt.display="block"),V.parentNode||(ht=1,lo.appendChild(V)),at=dt(V,ra,null,!0),lt=!at||at==="none"||at==="matrix(1, 0, 0, 1, 0, 0)",St?Mt.display=St:Ot&&ys(Mt,"display"),ht&&lo.removeChild(V)),(Gt.svg||V.getCTM&&Wl(V))&&(lt&&(Mt[Mn]+"").indexOf("matrix")!==-1&&(at=Mt[Mn],lt=0),j=V.getAttribute("transform"),lt&&j&&(j=V.transform.baseVal.consolidate().matrix,at="matrix("+j.a+","+j.b+","+j.c+","+j.d+","+j.e+","+j.f+")",lt=0)),lt)return aa;for(j=(at||"").match(M)||[],sn=j.length;--sn>-1;)St=Number(j[sn]),j[sn]=(ht=St-(St|=0))?(ht*zt+(0>ht?-.5:.5)|0)/zt+St:St;return et&&j.length>6?[j[0],j[1],j[4],j[5],j[12],j[13]]:j},uo=Oe.getTransform=function(V,et,lt,at){if(V._gsTransform&<&&!at)return V._gsTransform;var j,St,ht,Ot,Gt,zt,Mt=lt?V._gsTransform||new oa:new oa,he=Mt.scaleX<0,se=2e-5,te=1e5,ye=vr&&(parseFloat(dt(V,vs,et,!1,"0 0 0").split(" ")[2])||Mt.zOrigin)||0,ue=parseFloat(m.defaultTransformPerspective)||0;if(Mt.svg=!(!V.getCTM||!Wl(V)),Mt.svg&&(sa(V,dt(V,vs,et,!1,"50% 50%")+"",Mt,V.getAttribute("data-svg-origin")),ao=m.useSVGTransformAttr||Oh),j=la(V),j!==aa){if(j.length===16){var je,He,ci,Be,_e,Fe=j[0],fe=j[1],mi=j[2],Le=j[3],xe=j[4],Re=j[5],Sn=j[6],Xn=j[7],ki=j[8],Bi=j[9],Hi=j[10],nn=j[12],rn=j[13],un=j[14],cn=j[11],Gi=Math.atan2(Sn,Hi);Mt.zOrigin&&(un=-Mt.zOrigin,nn=ki*un-j[12],rn=Bi*un-j[13],un=Hi*un+Mt.zOrigin-j[14]),Mt.rotationX=Gi*It,Gi&&(Be=Math.cos(-Gi),_e=Math.sin(-Gi),je=xe*Be+ki*_e,He=Re*Be+Bi*_e,ci=Sn*Be+Hi*_e,ki=xe*-_e+ki*Be,Bi=Re*-_e+Bi*Be,Hi=Sn*-_e+Hi*Be,cn=Xn*-_e+cn*Be,xe=je,Re=He,Sn=ci),Gi=Math.atan2(-mi,Hi),Mt.rotationY=Gi*It,Gi&&(Be=Math.cos(-Gi),_e=Math.sin(-Gi),je=Fe*Be-ki*_e,He=fe*Be-Bi*_e,ci=mi*Be-Hi*_e,Bi=fe*_e+Bi*Be,Hi=mi*_e+Hi*Be,cn=Le*_e+cn*Be,Fe=je,fe=He,mi=ci),Gi=Math.atan2(fe,Fe),Mt.rotation=Gi*It,Gi&&(Be=Math.cos(Gi),_e=Math.sin(Gi),je=Fe*Be+fe*_e,He=xe*Be+Re*_e,ci=ki*Be+Bi*_e,fe=fe*Be-Fe*_e,Re=Re*Be-xe*_e,Bi=Bi*Be-ki*_e,Fe=je,xe=He,ki=ci),Mt.rotationX&&Math.abs(Mt.rotationX)+Math.abs(Mt.rotation)>359.9&&(Mt.rotationX=Mt.rotation=0,Mt.rotationY=180-Mt.rotationY),Gi=Math.atan2(xe,Re),Mt.scaleX=(Math.sqrt(Fe*Fe+fe*fe+mi*mi)*te+.5|0)/te,Mt.scaleY=(Math.sqrt(Re*Re+Sn*Sn)*te+.5|0)/te,Mt.scaleZ=(Math.sqrt(ki*ki+Bi*Bi+Hi*Hi)*te+.5|0)/te,Fe/=Mt.scaleX,xe/=Mt.scaleY,fe/=Mt.scaleX,Re/=Mt.scaleY,Math.abs(Gi)>se?(Mt.skewX=Gi*It,xe=0,Mt.skewType!=="simple"&&(Mt.scaleY*=1/Math.cos(Gi))):Mt.skewX=0,Mt.perspective=cn?1/(0>cn?-cn:cn):0,Mt.x=nn,Mt.y=rn,Mt.z=un,Mt.svg&&(Mt.x-=Mt.xOrigin-(Mt.xOrigin*Fe-Mt.yOrigin*xe),Mt.y-=Mt.yOrigin-(Mt.yOrigin*fe-Mt.xOrigin*Re))}else if(!vr||at||!j.length||Mt.x!==j[4]||Mt.y!==j[5]||!Mt.rotationX&&!Mt.rotationY){var Ni=j.length>=6,ji=Ni?j[0]:1,gi=j[1]||0,co=j[2]||0,Fn=Ni?j[3]:1;Mt.x=j[4]||0,Mt.y=j[5]||0,ht=Math.sqrt(ji*ji+gi*gi),Ot=Math.sqrt(Fn*Fn+co*co),Gt=ji||gi?Math.atan2(gi,ji)*It:Mt.rotation||0,zt=co||Fn?Math.atan2(co,Fn)*It+Gt:Mt.skewX||0,Mt.scaleX=ht,Mt.scaleY=Ot,Mt.rotation=Gt,Mt.skewX=zt,vr&&(Mt.rotationX=Mt.rotationY=Mt.z=0,Mt.perspective=ue,Mt.scaleZ=1),Mt.svg&&(Mt.x-=Mt.xOrigin-(Mt.xOrigin*ji+Mt.yOrigin*co),Mt.y-=Mt.yOrigin-(Mt.xOrigin*gi+Mt.yOrigin*Fn))}Math.abs(Mt.skewX)>90&&Math.abs(Mt.skewX)<270&&(he?(Mt.scaleX*=-1,Mt.skewX+=Mt.rotation<=0?180:-180,Mt.rotation+=Mt.rotation<=0?180:-180):(Mt.scaleY*=-1,Mt.skewX+=Mt.skewX<=0?180:-180)),Mt.zOrigin=ye;for(St in Mt)Mt[St]<se&&Mt[St]>-se&&(Mt[St]=0)}return lt&&(V._gsTransform=Mt,Mt.svg&&(ao&&V.style[Mn]?a.delayedCall(.001,function(){ys(V.style,Mn)}):!ao&&V.getAttribute("transform")&&a.delayedCall(.001,function(){V.removeAttribute("transform")}))),Mt},jl=function(V){var et,lt,at=this.data,j=-at.rotation*Ft,St=j+at.skewX*Ft,ht=1e5,Ot=(Math.cos(j)*at.scaleX*ht|0)/ht,Gt=(Math.sin(j)*at.scaleX*ht|0)/ht,zt=(Math.sin(St)*-at.scaleY*ht|0)/ht,Mt=(Math.cos(St)*at.scaleY*ht|0)/ht,he=this.t.style,se=this.t.currentStyle;if(se){lt=Gt,Gt=-zt,zt=-lt,et=se.filter,he.filter="";var te,ye,ue=this.t.offsetWidth,je=this.t.offsetHeight,He=se.position!=="absolute",ci="progid:DXImageTransform.Microsoft.Matrix(M11="+Ot+", M12="+Gt+", M21="+zt+", M22="+Mt,Be=at.x+ue*at.xPercent/100,_e=at.y+je*at.yPercent/100;if(at.ox!=null&&(te=(at.oxp?ue*at.ox*.01:at.ox)-ue/2,ye=(at.oyp?je*at.oy*.01:at.oy)-je/2,Be+=te-(te*Ot+ye*Gt),_e+=ye-(te*zt+ye*Mt)),He?(te=ue/2,ye=je/2,ci+=", Dx="+(te-(te*Ot+ye*Gt)+Be)+", Dy="+(ye-(te*zt+ye*Mt)+_e)+")"):ci+=", sizingMethod='auto expand')",et.indexOf("DXImageTransform.Microsoft.Matrix(")!==-1?he.filter=et.replace(At,ci):he.filter=ci+" "+et,(V===0||V===1)&&Ot===1&&Gt===0&&zt===0&&Mt===1&&(He&&ci.indexOf("Dx=0, Dy=0")===-1||X.test(et)&&parseFloat(RegExp.$1)!==100||et.indexOf(et.indexOf("Alpha"))===-1&&he.removeAttribute("filter")),!He){var Fe,fe,mi,Le=8>E?1:-1;for(te=at.ieOffsetX||0,ye=at.ieOffsetY||0,at.ieOffsetX=Math.round((ue-((0>Ot?-Ot:Ot)*ue+(0>Gt?-Gt:Gt)*je))/2+Be),at.ieOffsetY=Math.round((je-((0>Mt?-Mt:Mt)*je+(0>zt?-zt:zt)*ue))/2+_e),sn=0;4>sn;sn++)fe=Q[sn],Fe=se[fe],lt=Fe.indexOf("px")!==-1?parseFloat(Fe):pt(this.t,fe,parseFloat(Fe),Fe.replace(N,""))||0,mi=lt!==at[fe]?2>sn?-at.ieOffsetX:-at.ieOffsetY:2>sn?te-at.ieOffsetX:ye-at.ieOffsetY,he[fe]=(at[fe]=Math.round(lt-mi*(sn===0||sn===2?1:Le)))+"px"}}},Ih=Oe.set3DTransformRatio=Oe.setTransformRatio=function(V){var et,lt,at,j,St,ht,Ot,Gt,zt,Mt,he,se,te,ye,ue,je,He,ci,Be,_e,Fe,fe,mi,Le=this.data,xe=this.t.style,Re=Le.rotation,Sn=Le.rotationX,Xn=Le.rotationY,ki=Le.scaleX,Bi=Le.scaleY,Hi=Le.scaleZ,nn=Le.x,rn=Le.y,un=Le.z,cn=Le.svg,Gi=Le.perspective,Ni=Le.force3D,ji=Le.skewY,gi=Le.skewX;if(ji&&(gi+=ji,Re+=ji),((V===1||V===0)&&Ni==="auto"&&(this.tween._totalTime===this.tween._totalDuration||!this.tween._totalTime)||!Ni)&&!un&&!Gi&&!Xn&&!Sn&&Hi===1||ao&&cn||!vr)return void(Re||gi||cn?(Re*=Ft,fe=gi*Ft,mi=1e5,lt=Math.cos(Re)*ki,St=Math.sin(Re)*ki,at=Math.sin(Re-fe)*-Bi,ht=Math.cos(Re-fe)*Bi,fe&&Le.skewType==="simple"&&(et=Math.tan(fe-ji*Ft),et=Math.sqrt(1+et*et),at*=et,ht*=et,ji&&(et=Math.tan(ji*Ft),et=Math.sqrt(1+et*et),lt*=et,St*=et)),cn&&(nn+=Le.xOrigin-(Le.xOrigin*lt+Le.yOrigin*at)+Le.xOffset,rn+=Le.yOrigin-(Le.xOrigin*St+Le.yOrigin*ht)+Le.yOffset,ao&&(Le.xPercent||Le.yPercent)&&(ue=this.t.getBBox(),nn+=.01*Le.xPercent*ue.width,rn+=.01*Le.yPercent*ue.height),ue=1e-6,ue>nn&&nn>-ue&&(nn=0),ue>rn&&rn>-ue&&(rn=0)),Be=(lt*mi|0)/mi+","+(St*mi|0)/mi+","+(at*mi|0)/mi+","+(ht*mi|0)/mi+","+nn+","+rn+")",cn&&ao?this.t.setAttribute("transform","matrix("+Be):xe[Mn]=(Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) matrix(":"matrix(")+Be):xe[Mn]=(Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) matrix(":"matrix(")+ki+",0,0,"+Bi+","+nn+","+rn+")");if(I&&(ue=1e-4,ue>ki&&ki>-ue&&(ki=Hi=2e-5),ue>Bi&&Bi>-ue&&(Bi=Hi=2e-5),!Gi||Le.z||Le.rotationX||Le.rotationY||(Gi=0)),Re||gi)Re*=Ft,je=lt=Math.cos(Re),He=St=Math.sin(Re),gi&&(Re-=gi*Ft,je=Math.cos(Re),He=Math.sin(Re),Le.skewType==="simple"&&(et=Math.tan((gi-ji)*Ft),et=Math.sqrt(1+et*et),je*=et,He*=et,Le.skewY&&(et=Math.tan(ji*Ft),et=Math.sqrt(1+et*et),lt*=et,St*=et))),at=-He,ht=je;else{if(!(Xn||Sn||Hi!==1||Gi||cn))return void(xe[Mn]=(Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) translate3d(":"translate3d(")+nn+"px,"+rn+"px,"+un+"px)"+(ki!==1||Bi!==1?" scale("+ki+","+Bi+")":""));lt=ht=1,at=St=0}Mt=1,j=Ot=Gt=zt=he=se=0,te=Gi?-1/Gi:0,ye=Le.zOrigin,ue=1e-6,_e=",",Fe="0",Re=Xn*Ft,Re&&(je=Math.cos(Re),He=Math.sin(Re),Gt=-He,he=te*-He,j=lt*He,Ot=St*He,Mt=je,te*=je,lt*=je,St*=je),Re=Sn*Ft,Re&&(je=Math.cos(Re),He=Math.sin(Re),et=at*je+j*He,ci=ht*je+Ot*He,zt=Mt*He,se=te*He,j=at*-He+j*je,Ot=ht*-He+Ot*je,Mt*=je,te*=je,at=et,ht=ci),Hi!==1&&(j*=Hi,Ot*=Hi,Mt*=Hi,te*=Hi),Bi!==1&&(at*=Bi,ht*=Bi,zt*=Bi,se*=Bi),ki!==1&&(lt*=ki,St*=ki,Gt*=ki,he*=ki),(ye||cn)&&(ye&&(nn+=j*-ye,rn+=Ot*-ye,un+=Mt*-ye+ye),cn&&(nn+=Le.xOrigin-(Le.xOrigin*lt+Le.yOrigin*at)+Le.xOffset,rn+=Le.yOrigin-(Le.xOrigin*St+Le.yOrigin*ht)+Le.yOffset),ue>nn&&nn>-ue&&(nn=Fe),ue>rn&&rn>-ue&&(rn=Fe),ue>un&&un>-ue&&(un=0)),Be=Le.xPercent||Le.yPercent?"translate("+Le.xPercent+"%,"+Le.yPercent+"%) matrix3d(":"matrix3d(",Be+=(ue>lt&<>-ue?Fe:lt)+_e+(ue>St&&St>-ue?Fe:St)+_e+(ue>Gt&&Gt>-ue?Fe:Gt),Be+=_e+(ue>he&&he>-ue?Fe:he)+_e+(ue>at&&at>-ue?Fe:at)+_e+(ue>ht&&ht>-ue?Fe:ht),Sn||Xn||Hi!==1?(Be+=_e+(ue>zt&&zt>-ue?Fe:zt)+_e+(ue>se&&se>-ue?Fe:se)+_e+(ue>j&&j>-ue?Fe:j),Be+=_e+(ue>Ot&&Ot>-ue?Fe:Ot)+_e+(ue>Mt&&Mt>-ue?Fe:Mt)+_e+(ue>te&&te>-ue?Fe:te)+_e):Be+=",0,0,0,0,1,0,",Be+=nn+_e+rn+_e+un+_e+(Gi?1+-un/Gi:1)+")",xe[Mn]=Be};S=oa.prototype,S.x=S.y=S.z=S.skewX=S.skewY=S.rotation=S.rotationX=S.rotationY=S.zOrigin=S.xPercent=S.yPercent=S.xOffset=S.yOffset=0,S.scaleX=S.scaleY=S.scaleZ=1,zi("transform,scale,scaleX,scaleY,scaleZ,x,y,z,rotation,rotationX,rotationY,rotationZ,skewX,skewY,shortRotation,shortRotationX,shortRotationY,shortRotationZ,transformOrigin,svgOrigin,transformPerspective,directionalRotation,parseTransform,force3D,skewType,xPercent,yPercent,smoothOrigin",{parser:function(V,et,lt,at,j,St,ht){if(at._lastParsedTransform===ht)return j;at._lastParsedTransform=ht;var Ot,Gt=ht.scale&&typeof ht.scale=="function"?ht.scale:0;typeof ht[lt]=="function"&&(Ot=ht[lt],ht[lt]=et),Gt&&(ht.scale=Gt(w,V));var zt,Mt,he,se,te,ye,ue,je,He,ci=V._gsTransform,Be=V.style,_e=1e-6,Fe=Hl.length,fe=ht,mi={},Le="transformOrigin",xe=uo(V,f,!0,fe.parseTransform),Re=fe.transform&&(typeof fe.transform=="function"?fe.transform(w,P):fe.transform);if(xe.skewType=fe.skewType||xe.skewType||m.defaultSkewType,at._transform=xe,"rotationZ"in fe&&(fe.rotation=fe.rotationZ),Re&&typeof Re=="string"&&Mn)Mt=$e.style,Mt[Mn]=Re,Mt.display="block",Mt.position="absolute",Re.indexOf("%")!==-1&&(Mt.width=dt(V,"width"),Mt.height=dt(V,"height")),pe.body.appendChild($e),zt=uo($e,null,!1),xe.skewType==="simple"&&(zt.scaleY*=Math.cos(zt.skewX*Ft)),xe.svg&&(ye=xe.xOrigin,ue=xe.yOrigin,zt.x-=xe.xOffset,zt.y-=xe.yOffset,(fe.transformOrigin||fe.svgOrigin)&&(Re={},sa(V,nt(fe.transformOrigin),Re,fe.svgOrigin,fe.smoothOrigin,!0),ye=Re.xOrigin,ue=Re.yOrigin,zt.x-=Re.xOffset-xe.xOffset,zt.y-=Re.yOffset-xe.yOffset),(ye||ue)&&(je=la($e,!0),zt.x-=ye-(ye*je[0]+ue*je[2]),zt.y-=ue-(ye*je[1]+ue*je[3]))),pe.body.removeChild($e),zt.perspective||(zt.perspective=xe.perspective),fe.xPercent!=null&&(zt.xPercent=Ut(fe.xPercent,xe.xPercent)),fe.yPercent!=null&&(zt.yPercent=Ut(fe.yPercent,xe.yPercent));else if(typeof fe=="object"){if(zt={scaleX:Ut(fe.scaleX!=null?fe.scaleX:fe.scale,xe.scaleX),scaleY:Ut(fe.scaleY!=null?fe.scaleY:fe.scale,xe.scaleY),scaleZ:Ut(fe.scaleZ,xe.scaleZ),x:Ut(fe.x,xe.x),y:Ut(fe.y,xe.y),z:Ut(fe.z,xe.z),xPercent:Ut(fe.xPercent,xe.xPercent),yPercent:Ut(fe.yPercent,xe.yPercent),perspective:Ut(fe.transformPerspective,xe.perspective)},te=fe.directionalRotation,te!=null)if(typeof te=="object")for(Mt in te)fe[Mt]=te[Mt];else fe.rotation=te;typeof fe.x=="string"&&fe.x.indexOf("%")!==-1&&(zt.x=0,zt.xPercent=Ut(fe.x,xe.xPercent)),typeof fe.y=="string"&&fe.y.indexOf("%")!==-1&&(zt.y=0,zt.yPercent=Ut(fe.y,xe.yPercent)),zt.rotation=qt("rotation"in fe?fe.rotation:"shortRotation"in fe?fe.shortRotation+"_short":xe.rotation,xe.rotation,"rotation",mi),vr&&(zt.rotationX=qt("rotationX"in fe?fe.rotationX:"shortRotationX"in fe?fe.shortRotationX+"_short":xe.rotationX||0,xe.rotationX,"rotationX",mi),zt.rotationY=qt("rotationY"in fe?fe.rotationY:"shortRotationY"in fe?fe.shortRotationY+"_short":xe.rotationY||0,xe.rotationY,"rotationY",mi)),zt.skewX=qt(fe.skewX,xe.skewX),zt.skewY=qt(fe.skewY,xe.skewY)}for(vr&&fe.force3D!=null&&(xe.force3D=fe.force3D,se=!0),he=xe.force3D||xe.z||xe.rotationX||xe.rotationY||zt.z||zt.rotationX||zt.rotationY||zt.perspective,he||fe.scale==null||(zt.scaleZ=1);--Fe>-1;)He=Hl[Fe],Re=zt[He]-xe[He],(Re>_e||-_e>Re||fe[He]!=null||Nt[He]!=null)&&(se=!0,j=new bi(xe,He,xe[He],Re,j),He in mi&&(j.e=mi[He]),j.xs0=0,j.plugin=St,at._overwriteProps.push(j.n));return Re=fe.transformOrigin,xe.svg&&(Re||fe.svgOrigin)&&(ye=xe.xOffset,ue=xe.yOffset,sa(V,nt(Re),zt,fe.svgOrigin,fe.smoothOrigin),j=qr(xe,"xOrigin",(ci?xe:zt).xOrigin,zt.xOrigin,j,Le),j=qr(xe,"yOrigin",(ci?xe:zt).yOrigin,zt.yOrigin,j,Le),(ye!==xe.xOffset||ue!==xe.yOffset)&&(j=qr(xe,"xOffset",ci?ye:xe.xOffset,xe.xOffset,j,Le),j=qr(xe,"yOffset",ci?ue:xe.yOffset,xe.yOffset,j,Le)),Re="0px 0px"),(Re||vr&&he&&xe.zOrigin)&&(Mn?(se=!0,He=vs,Re=(Re||dt(V,He,f,!1,"50% 50%"))+"",j=new bi(Be,He,0,0,j,-1,Le),j.b=Be[He],j.plugin=St,vr?(Mt=xe.zOrigin,Re=Re.split(" "),xe.zOrigin=(Re.length>2&&(Mt===0||Re[2]!=="0px")?parseFloat(Re[2]):Mt)||0,j.xs0=j.e=Re[0]+" "+(Re[1]||"50%")+" 0px",j=new bi(xe,"zOrigin",0,0,j,-1,j.n),j.b=Mt,j.xs0=j.e=xe.zOrigin):j.xs0=j.e=Re):nt(Re+"",xe)),se&&(at._transformType=xe.svg&&ao||!he&&this._transformType!==3?2:3),Ot&&(ht[lt]=Ot),Gt&&(ht.scale=Gt),j},prefix:!0}),zi("boxShadow",{defaultValue:"0px 0px 0px 0px #999",prefix:!0,color:!0,multi:!0,keyword:"inset"}),zi("borderRadius",{defaultValue:"0px",parser:function(V,et,lt,at,j,St){et=this.format(et);var ht,Ot,Gt,zt,Mt,he,se,te,ye,ue,je,He,ci,Be,_e,Fe,fe=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],mi=V.style;for(ye=parseFloat(V.offsetWidth),ue=parseFloat(V.offsetHeight),ht=et.split(" "),Ot=0;Ot<fe.length;Ot++)this.p.indexOf("border")&&(fe[Ot]=Jt(fe[Ot])),Mt=zt=dt(V,fe[Ot],f,!1,"0px"),Mt.indexOf(" ")!==-1&&(zt=Mt.split(" "),Mt=zt[0],zt=zt[1]),he=Gt=ht[Ot],se=parseFloat(Mt),He=Mt.substr((se+"").length),ci=he.charAt(1)==="=",ci?(te=parseInt(he.charAt(0)+"1",10),he=he.substr(2),te*=parseFloat(he),je=he.substr((te+"").length-(0>te?1:0))||""):(te=parseFloat(he),je=he.substr((te+"").length)),je===""&&(je=c[lt]||He),je!==He&&(Be=pt(V,"borderLeft",se,He),_e=pt(V,"borderTop",se,He),je==="%"?(Mt=Be/ye*100+"%",zt=_e/ue*100+"%"):je==="em"?(Fe=pt(V,"borderLeft",1,"em"),Mt=Be/Fe+"em",zt=_e/Fe+"em"):(Mt=Be+"px",zt=_e+"px"),ci&&(he=parseFloat(Mt)+te+je,Gt=parseFloat(zt)+te+je)),j=sr(mi,fe[Ot],Mt+" "+zt,he+" "+Gt,!1,"0px",j);return j},prefix:!0,formatter:yi("0px 0px 0px 0px",!1,!0)}),zi("borderBottomLeftRadius,borderBottomRightRadius,borderTopLeftRadius,borderTopRightRadius",{defaultValue:"0px",parser:function(V,et,lt,at,j,St){return sr(V.style,lt,this.format(dt(V,lt,f,!1,"0px 0px")),this.format(et),!1,"0px",j)},prefix:!0,formatter:yi("0px 0px",!1,!0)}),zi("backgroundPosition",{defaultValue:"0 0",parser:function(V,et,lt,at,j,St){var ht,Ot,Gt,zt,Mt,he,se="background-position",te=f||jt(V,null),ye=this.format((te?E?te.getPropertyValue(se+"-x")+" "+te.getPropertyValue(se+"-y"):te.getPropertyValue(se):V.currentStyle.backgroundPositionX+" "+V.currentStyle.backgroundPositionY)||"0 0"),ue=this.format(et);if(ye.indexOf("%")!==-1!=(ue.indexOf("%")!==-1)&&ue.split(",").length<2&&(he=dt(V,"backgroundImage").replace(_t,""),he&&he!=="none")){for(ht=ye.split(" "),Ot=ue.split(" "),Si.setAttribute("src",he),Gt=2;--Gt>-1;)ye=ht[Gt],zt=ye.indexOf("%")!==-1,zt!==(Ot[Gt].indexOf("%")!==-1)&&(Mt=Gt===0?V.offsetWidth-Si.width:V.offsetHeight-Si.height,ht[Gt]=zt?parseFloat(ye)/100*Mt+"px":parseFloat(ye)/Mt*100+"%");ye=ht.join(" ")}return this.parseComplex(V.style,ye,ue,j,St)},formatter:nt}),zi("backgroundSize",{defaultValue:"0 0",formatter:function(V){return V+="",V.substr(0,2)==="co"?V:nt(V.indexOf(" ")===-1?V+" "+V:V)}}),zi("perspective",{defaultValue:"0px",prefix:!0}),zi("perspectiveOrigin",{defaultValue:"50% 50%",prefix:!0}),zi("transformStyle",{prefix:!0}),zi("backfaceVisibility",{prefix:!0}),zi("userSelect",{prefix:!0}),zi("margin",{parser:Ei("marginTop,marginRight,marginBottom,marginLeft")}),zi("padding",{parser:Ei("paddingTop,paddingRight,paddingBottom,paddingLeft")}),zi("clip",{defaultValue:"rect(0px,0px,0px,0px)",parser:function(V,et,lt,at,j,St){var ht,Ot,Gt;return 9>E?(Ot=V.currentStyle,Gt=8>E?" ":",",ht="rect("+Ot.clipTop+Gt+Ot.clipRight+Gt+Ot.clipBottom+Gt+Ot.clipLeft+")",et=this.format(et).split(",").join(Gt)):(ht=this.format(dt(V,this.p,f,!1,this.dflt)),et=this.format(et)),this.parseComplex(V.style,ht,et,j,St)}}),zi("textShadow",{defaultValue:"0px 0px 0px #999",color:!0,multi:!0}),zi("autoRound,strictUnits",{parser:function(V,et,lt,at,j){return j}}),zi("border",{defaultValue:"0px solid #000",parser:function(V,et,lt,at,j,St){var ht=dt(V,"borderTopWidth",f,!1,"0px"),Ot=this.format(et).split(" "),Gt=Ot[0].replace(N,"");return Gt!=="px"&&(ht=parseFloat(ht)/pt(V,"borderTopWidth",1,Gt)+Gt),this.parseComplex(V.style,this.format(ht+" "+dt(V,"borderTopStyle",f,!1,"solid")+" "+dt(V,"borderTopColor",f,!1,"#000")),Ot.join(" "),j,St)},color:!0,formatter:function(V){var et=V.split(" ");return et[0]+" "+(et[1]||"solid")+" "+(V.match(we)||["#000"])[0]}}),zi("borderWidth",{parser:Ei("borderTopWidth,borderRightWidth,borderBottomWidth,borderLeftWidth")}),zi("float,cssFloat,styleFloat",{parser:function(V,et,lt,at,j,St){var ht=V.style,Ot="cssFloat"in ht?"cssFloat":"styleFloat";return new bi(ht,Ot,0,0,j,-1,lt,!1,0,ht[Ot],et)}});var Dh=function(V){var et,lt=this.t,at=lt.filter||dt(this.data,"filter")||"",j=this.s+this.c*V|0;j===100&&(at.indexOf("atrix(")===-1&&at.indexOf("radient(")===-1&&at.indexOf("oader(")===-1?(lt.removeAttribute("filter"),et=!dt(this.data,"filter")):(lt.filter=at.replace(Z,""),et=!0)),et||(this.xn1&&(lt.filter=at=at||"alpha(opacity="+j+")"),at.indexOf("pacity")===-1?j===0&&this.xn1||(lt.filter=at+" alpha(opacity="+j+")"):lt.filter=at.replace(X,"opacity="+j))};zi("opacity,alpha,autoAlpha",{defaultValue:"1",parser:function(V,et,lt,at,j,St){var ht=parseFloat(dt(V,"opacity",f,!1,"1")),Ot=V.style,Gt=lt==="autoAlpha";return typeof et=="string"&&et.charAt(1)==="="&&(et=(et.charAt(0)==="-"?-1:1)*parseFloat(et.substr(2))+ht),Gt&&ht===1&&dt(V,"visibility",f)==="hidden"&&et!==0&&(ht=0),pi?j=new bi(Ot,"opacity",ht,et-ht,j):(j=new bi(Ot,"opacity",100*ht,100*(et-ht),j),j.xn1=Gt?1:0,Ot.zoom=1,j.type=2,j.b="alpha(opacity="+j.s+")",j.e="alpha(opacity="+(j.s+j.c)+")",j.data=V,j.plugin=St,j.setRatio=Dh),Gt&&(j=new bi(Ot,"visibility",0,0,j,-1,null,!1,0,ht!==0?"inherit":"hidden",et===0?"hidden":"inherit"),j.xs0="inherit",at._overwriteProps.push(j.n),at._overwriteProps.push(lt)),j}});var ys=function(V,et){et&&(V.removeProperty?((et.substr(0,2)==="ms"||et.substr(0,6)==="webkit")&&(et="-"+et),V.removeProperty(et.replace(Rt,"-$1").toLowerCase())):V.removeAttribute(et))},_s=function(V){if(this.t._gsClassPT=this,V===1||V===0){this.t.setAttribute("class",V===0?this.b:this.e);for(var et=this.data,lt=this.t.style;et;)et.v?lt[et.p]=et.v:ys(lt,et.p),et=et._next;V===1&&this.t._gsClassPT===this&&(this.t._gsClassPT=null)}else this.t.getAttribute("class")!==this.e&&this.t.setAttribute("class",this.e)};zi("className",{parser:function(V,et,lt,at,j,St,ht){var Ot,Gt,zt,Mt,he,se=V.getAttribute("class")||"",te=V.style.cssText;if(j=at._classNamePT=new bi(V,lt,0,0,j,2),j.setRatio=_s,j.pr=-11,o=!0,j.b=se,Gt=ie(V,f),zt=V._gsClassPT){for(Mt={},he=zt.data;he;)Mt[he.p]=1,he=he._next;zt.setRatio(1)}return V._gsClassPT=j,j.e=et.charAt(1)!=="="?et:se.replace(new RegExp("(?:\\s|^)"+et.substr(2)+"(?![\\w-])"),"")+(et.charAt(0)==="+"?" "+et.substr(2):""),V.setAttribute("class",j.e),Ot=Kt(V,Gt,ie(V),ht,Mt),V.setAttribute("class",se),j.data=Ot.firstMPT,V.style.cssText=te,j=j.xfirst=at.parse(V,Ot.difs,j,St)}});var Xl=function(V){if((V===1||V===0)&&this.data._totalTime===this.data._totalDuration&&this.data.data!=="isFromStart"){var et,lt,at,j,St,ht=this.t.style,Ot=v.transform.parse;if(this.e==="all")ht.cssText="",j=!0;else for(et=this.e.split(" ").join("").split(","),at=et.length;--at>-1;)lt=et[at],v[lt]&&(v[lt].parse===Ot?j=!0:lt=lt==="transformOrigin"?vs:v[lt].p),ys(ht,lt);j&&(ys(ht,Mn),St=this.t._gsTransform,St&&(St.svg&&(this.t.removeAttribute("data-svg-origin"),this.t.removeAttribute("transform")),delete this.t._gsTransform))}};for(zi("clearProps",{parser:function(V,et,lt,at,j){return j=new bi(V,lt,0,0,j,2),j.setRatio=Xl,j.e=et,j.pr=-10,j.data=at._tween,o=!0,j}}),S="bezier,throwProps,physicsProps,physics2D".split(","),sn=S.length;sn--;)Yo(S[sn]);S=m.prototype,S._firstPT=S._lastParsedTransform=S._transform=null,S._onInitTween=function(V,et,lt,at){if(!V.nodeType)return!1;this._target=P=V,this._tween=lt,this._vars=et,w=at,b=et.autoRound,o=!1,c=et.suffixMap||m.suffixMap,f=jt(V,""),u=this._overwriteProps;var j,St,ht,Ot,Gt,zt,Mt,he,se,te=V.style;if(O&&te.zIndex===""&&(j=dt(V,"zIndex",f),(j==="auto"||j==="")&&this._addLazySet(te,"zIndex",0)),typeof et=="string"&&(Ot=te.cssText,j=ie(V,f),te.cssText=Ot+";"+et,j=Kt(V,j,ie(V)).difs,!pi&&J.test(et)&&(j.opacity=parseFloat(RegExp.$1)),et=j,te.cssText=Ot),et.className?this._firstPT=St=v.className.parse(V,et.className,"className",this,null,null,et):this._firstPT=St=this.parse(V,et,null),this._transformType){for(se=this._transformType===3,Mn?k&&(O=!0,te.zIndex===""&&(Mt=dt(V,"zIndex",f),(Mt==="auto"||Mt==="")&&this._addLazySet(te,"zIndex",0)),F&&this._addLazySet(te,"WebkitBackfaceVisibility",this._vars.WebkitBackfaceVisibility||(se?"visible":"hidden"))):te.zoom=1,ht=St;ht&&ht._next;)ht=ht._next;he=new bi(V,"transform",0,0,null,2),this._linkCSSP(he,null,ht),he.setRatio=Mn?Ih:jl,he.data=this._transform||uo(V,f,!0),he.tween=lt,he.pr=-1,u.pop()}if(o){for(;St;){for(zt=St._next,ht=Ot;ht&&ht.pr>St.pr;)ht=ht._next;(St._prev=ht?ht._prev:Gt)?St._prev._next=St:Ot=St,(St._next=ht)?ht._prev=St:Gt=St,St=zt}this._firstPT=Ot}return!0},S.parse=function(V,et,lt,at){var j,St,ht,Ot,Gt,zt,Mt,he,se,te,ye=V.style;for(j in et){if(zt=et[j],typeof zt=="function"&&(zt=zt(w,P)),St=v[j])lt=St.parse(V,zt,j,this,lt,at,et);else{if(j.substr(0,2)==="--"){this._tween._propLookup[j]=this._addTween.call(this._tween,V.style,"setProperty",jt(V).getPropertyValue(j)+"",zt+"",j,!1,j);continue}Gt=dt(V,j,f)+"",se=typeof zt=="string",j==="color"||j==="fill"||j==="stroke"||j.indexOf("Color")!==-1||se&&ct.test(zt)?(se||(zt=Ie(zt),zt=(zt.length>3?"rgba(":"rgb(")+zt.join(",")+")"),lt=sr(ye,j,Gt,zt,!0,"transparent",lt,0,at)):se&&re.test(zt)?lt=sr(ye,j,Gt,zt,!0,null,lt,0,at):(ht=parseFloat(Gt),Mt=ht||ht===0?Gt.substr((ht+"").length):"",(Gt===""||Gt==="auto")&&(j==="width"||j==="height"?(ht=st(V,j,f),Mt="px"):j==="left"||j==="top"?(ht=Dt(V,j,f),Mt="px"):(ht=j!=="opacity"?0:1,Mt="")),te=se&&zt.charAt(1)==="=",te?(Ot=parseInt(zt.charAt(0)+"1",10),zt=zt.substr(2),Ot*=parseFloat(zt),he=zt.replace(N,"")):(Ot=parseFloat(zt),he=se?zt.replace(N,""):""),he===""&&(he=j in c?c[j]:Mt),zt=Ot||Ot===0?(te?Ot+ht:Ot)+he:et[j],Mt!==he&&(he!==""||j==="lineHeight")&&(Ot||Ot===0)&&ht&&(ht=pt(V,j,ht,Mt),he==="%"?(ht/=pt(V,j,100,"%")/100,et.strictUnits!==!0&&(Gt=ht+"%")):he==="em"||he==="rem"||he==="vw"||he==="vh"?ht/=pt(V,j,1,he):he!=="px"&&(Ot=pt(V,j,Ot,he),he="px"),te&&(Ot||Ot===0)&&(zt=Ot+ht+he)),te&&(Ot+=ht),!ht&&ht!==0||!Ot&&Ot!==0?ye[j]!==void 0&&(zt||zt+""!="NaN"&&zt!=null)?(lt=new bi(ye,j,Ot||ht||0,0,lt,-1,j,!1,0,Gt,zt),lt.xs0=zt!=="none"||j!=="display"&&j.indexOf("Style")===-1?zt:Gt):mn("invalid "+j+" tween value: "+et[j]):(lt=new bi(ye,j,ht,Ot-ht,lt,0,j,b!==!1&&(he==="px"||j==="zIndex"),0,Gt,zt),lt.xs0=he))}at&<&&!lt.plugin&&(lt.plugin=at)}return lt},S.setRatio=function(V){var et,lt,at,j=this._firstPT,St=1e-6;if(V!==1||this._tween._time!==this._tween._duration&&this._tween._time!==0)if(V||this._tween._time!==this._tween._duration&&this._tween._time!==0||this._tween._rawPrevTime===-1e-6)for(;j;){if(et=j.c*V+j.s,j.r?et=j.r(et):St>et&&et>-St&&(et=0),j.type)if(j.type===1)if(at=j.l,at===2)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2;else if(at===3)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2+j.xn2+j.xs3;else if(at===4)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2+j.xn2+j.xs3+j.xn3+j.xs4;else if(at===5)j.t[j.p]=j.xs0+et+j.xs1+j.xn1+j.xs2+j.xn2+j.xs3+j.xn3+j.xs4+j.xn4+j.xs5;else{for(lt=j.xs0+et+j.xs1,at=1;at<j.l;at++)lt+=j["xn"+at]+j["xs"+(at+1)];j.t[j.p]=lt}else j.type===-1?j.t[j.p]=j.xs0:j.setRatio&&j.setRatio(V);else j.t[j.p]=et+j.xs0;j=j._next}else for(;j;)j.type!==2?j.t[j.p]=j.b:j.setRatio(V),j=j._next;else for(;j;){if(j.type!==2)if(j.r&&j.type!==-1)if(et=j.r(j.s+j.c),j.type){if(j.type===1){for(at=j.l,lt=j.xs0+et+j.xs1,at=1;at<j.l;at++)lt+=j["xn"+at]+j["xs"+(at+1)];j.t[j.p]=lt}}else j.t[j.p]=et+j.xs0;else j.t[j.p]=j.e;else j.setRatio(V);j=j._next}},S._enableTransforms=function(V){this._transform=this._transform||uo(this._target,f,!0),this._transformType=this._transform.svg&&ao||!V&&this._transformType!==3?2:3};var ql=function(V){this.t[this.p]=this.e,this.data._linkCSSP(this,this._next,null,!0)};S._addLazySet=function(V,et,lt){var at=this._firstPT=new bi(V,et,0,0,this._firstPT,2);at.e=lt,at.setRatio=ql,at.data=this},S._linkCSSP=function(V,et,lt,at){return V&&(et&&(et._prev=V),V._next&&(V._next._prev=V._prev),V._prev?V._prev._next=V._next:this._firstPT===V&&(this._firstPT=V._next,at=!0),lt?lt._next=V:at||this._firstPT!==null||(this._firstPT=V),V._next=et,V._prev=lt),V},S._mod=function(V){for(var et=this._firstPT;et;)typeof V[et.p]=="function"&&(et.r=V[et.p]),et=et._next},S._kill=function(V){var et,lt,at,j=V;if(V.autoAlpha||V.alpha){j={};for(lt in V)j[lt]=V[lt];j.opacity=1,j.autoAlpha&&(j.visibility=1)}for(V.className&&(et=this._classNamePT)&&(at=et.xfirst,at&&at._prev?this._linkCSSP(at._prev,et._next,at._prev._prev):at===this._firstPT&&(this._firstPT=et._next),et._next&&this._linkCSSP(et._next,et._next._next,at._prev),this._classNamePT=null),et=this._firstPT;et;)et.plugin&&et.plugin!==lt&&et.plugin._kill&&(et.plugin._kill(V),lt=et.plugin),et=et._next;return x.prototype._kill.call(this,j)};var Yr=function(V,et,lt){var at,j,St,ht;if(V.slice)for(j=V.length;--j>-1;)Yr(V[j],et,lt);else for(at=V.childNodes,j=at.length;--j>-1;)St=at[j],ht=St.type,St.style&&(et.push(ie(St)),lt&<.push(St)),ht!==1&&ht!==9&&ht!==11||!St.childNodes.length||Yr(St,et,lt)};return m.cascadeTo=function(V,et,lt){var at,j,St,ht,Ot=a.to(V,et,lt),Gt=[Ot],zt=[],Mt=[],he=[],se=a._internals.reservedProps;for(V=Ot._targets||Ot.target,Yr(V,zt,he),Ot.render(et,!0,!0),Yr(V,Mt),Ot.render(0,!0,!0),Ot._enabled(!0),at=he.length;--at>-1;)if(j=Kt(he[at],zt[at],Mt[at]),j.firstMPT){j=j.difs;for(St in lt)se[St]&&(j[St]=lt[St]);ht={};for(St in j)ht[St]=zt[at][St];Gt.push(a.fromTo(he[at],et,ht,j))}return Gt},x.activate([m]),m},!0),function(){var x=ln._gsDefine.plugin({propName:"roundProps",version:"1.7.0",priority:-1,API:2,init:function(f,u,m){return this._tween=m,!0}}),a=function(f){var u=1>f?Math.pow(10,(f+"").length-2):1;return function(m){return(Math.round(m/f)*f*u|0)/u}},o=function(f,u){for(;f;)f.f||f.blob||(f.m=u||Math.round),f=f._next},c=x.prototype;c._onInitAllProps=function(){var f,u,m,g,v=this._tween,S=v.vars.roundProps,b={},O=v._propLookup.roundProps;if(typeof S!="object"||S.push)for(typeof S=="string"&&(S=S.split(",")),m=S.length;--m>-1;)b[S[m]]=Math.round;else for(g in S)b[g]=a(S[g]);for(g in b)for(f=v._firstPT;f;)u=f._next,f.pg?f.t._mod(b):f.n===g&&(f.f===2&&f.t?o(f.t._firstPT,b[g]):(this._add(f.t,g,f.s,f.c,b[g]),u&&(u._prev=f._prev),f._prev?f._prev._next=u:v._firstPT===f&&(v._firstPT=u),f._next=f._prev=null,v._propLookup[g]=O)),f=u;return!1},c._add=function(f,u,m,g,v){this._addTween(f,u,m,m+g,u,v||Math.round),this._overwriteProps.push(u)}}(),function(){ln._gsDefine.plugin({propName:"attr",API:2,version:"0.6.1",init:function(x,a,o,c){var f,u;if(typeof x.setAttribute!="function")return!1;for(f in a)u=a[f],typeof u=="function"&&(u=u(c,x)),this._addTween(x,"setAttribute",x.getAttribute(f)+"",u+"",f,!1,f),this._overwriteProps.push(f);return!0}})}(),ln._gsDefine.plugin({propName:"directionalRotation",version:"0.3.1",API:2,init:function(x,a,o,c){typeof a!="object"&&(a={rotation:a}),this.finals={};var f,u,m,g,v,S,b=a.useRadians===!0?2*Math.PI:360,O=1e-6;for(f in a)f!=="useRadians"&&(g=a[f],typeof g=="function"&&(g=g(c,x)),S=(g+"").split("_"),u=S[0],m=parseFloat(typeof x[f]!="function"?x[f]:x[f.indexOf("set")||typeof x["get"+f.substr(3)]!="function"?f:"get"+f.substr(3)]()),g=this.finals[f]=typeof u=="string"&&u.charAt(1)==="="?m+parseInt(u.charAt(0)+"1",10)*Number(u.substr(2)):Number(u)||0,v=g-m,S.length&&(u=S.join("_"),u.indexOf("short")!==-1&&(v%=b,v!==v%(b/2)&&(v=0>v?v+b:v-b)),u.indexOf("_cw")!==-1&&0>v?v=(v+9999999999*b)%b-(v/b|0)*b:u.indexOf("ccw")!==-1&&v>0&&(v=(v-9999999999*b)%b-(v/b|0)*b)),(v>O||-O>v)&&(this._addTween(x,f,m,m+v,f),this._overwriteProps.push(f)));return!0},set:function(x){var a;if(x!==1)this._super.setRatio.call(this,x);else for(a=this._firstPT;a;)a.f?a.t[a.p](this.finals[a.p]):a.t[a.p]=this.finals[a.p],a=a._next}})._autoCSS=!0,ln._gsDefine("easing.Back",["easing.Ease"],function(x){var a,o,c,f,u=ln.GreenSockGlobals||ln,m=u.com.greensock,g=2*Math.PI,v=Math.PI/2,S=m._class,b=function(M,R){var C=S("easing."+M,function(){},!0),U=C.prototype=new x;return U.constructor=C,U.getRatio=R,C},O=x.register||function(){},k=function(M,R,C,U,N){var X=S("easing."+M,{easeOut:new R,easeIn:new C,easeInOut:new U},!0);return O(X,M),X},I=function(M,R,C){this.t=M,this.v=R,C&&(this.next=C,C.prev=this,this.c=C.v-R,this.gap=C.t-M)},F=function(M,R){var C=S("easing."+M,function(N){this._p1=N||N===0?N:1.70158,this._p2=1.525*this._p1},!0),U=C.prototype=new x;return U.constructor=C,U.getRatio=R,U.config=function(N){return new C(N)},C},E=k("Back",F("BackOut",function(M){return(M-=1)*M*((this._p1+1)*M+this._p1)+1}),F("BackIn",function(M){return M*M*((this._p1+1)*M-this._p1)}),F("BackInOut",function(M){return(M*=2)<1?.5*M*M*((this._p2+1)*M-this._p2):.5*((M-=2)*M*((this._p2+1)*M+this._p2)+2)})),P=S("easing.SlowMo",function(M,R,C){R=R||R===0?R:.7,M==null?M=.7:M>1&&(M=1),this._p=M!==1?R:0,this._p1=(1-M)/2,this._p2=M,this._p3=this._p1+this._p2,this._calcEnd=C===!0},!0),w=P.prototype=new x;return w.constructor=P,w.getRatio=function(M){var R=M+(.5-M)*this._p;return M<this._p1?this._calcEnd?1-(M=1-M/this._p1)*M:R-(M=1-M/this._p1)*M*M*M*R:M>this._p3?this._calcEnd?M===1?0:1-(M=(M-this._p3)/this._p1)*M:R+(M-R)*(M=(M-this._p3)/this._p1)*M*M*M:this._calcEnd?1:R},P.ease=new P(.7,.7),w.config=P.config=function(M,R,C){return new P(M,R,C)},a=S("easing.SteppedEase",function(M,R){M=M||1,this._p1=1/M,this._p2=M+(R?0:1),this._p3=R?1:0},!0),w=a.prototype=new x,w.constructor=a,w.getRatio=function(M){return 0>M?M=0:M>=1&&(M=.999999999),((this._p2*M|0)+this._p3)*this._p1},w.config=a.config=function(M,R){return new a(M,R)},o=S("easing.ExpoScaleEase",function(M,R,C){this._p1=Math.log(R/M),this._p2=R-M,this._p3=M,this._ease=C},!0),w=o.prototype=new x,w.constructor=o,w.getRatio=function(M){return this._ease&&(M=this._ease.getRatio(M)),(this._p3*Math.exp(this._p1*M)-this._p3)/this._p2},w.config=o.config=function(M,R,C){return new o(M,R,C)},c=S("easing.RoughEase",function(M){M=M||{};for(var R,C,U,N,X,J,Z=M.taper||"none",ct=[],Rt=0,tt=0|(M.points||20),_t=tt,G=M.randomize!==!1,Pt=M.clamp===!0,Et=M.template instanceof x?M.template:null,At=typeof M.strength=="number"?.4*M.strength:.4;--_t>-1;)R=G?Math.random():1/tt*_t,C=Et?Et.getRatio(R):R,Z==="none"?U=At:Z==="out"?(N=1-R,U=N*N*At):Z==="in"?U=R*R*At:.5>R?(N=2*R,U=N*N*.5*At):(N=2*(1-R),U=N*N*.5*At),G?C+=Math.random()*U-.5*U:_t%2?C+=.5*U:C-=.5*U,Pt&&(C>1?C=1:0>C&&(C=0)),ct[Rt++]={x:R,y:C};for(ct.sort(function(ce,re){return ce.x-re.x}),J=new I(1,1,null),_t=tt;--_t>-1;)X=ct[_t],J=new I(X.x,X.y,J);this._prev=new I(0,0,J.t!==0?J:J.next)},!0),w=c.prototype=new x,w.constructor=c,w.getRatio=function(M){var R=this._prev;if(M>R.t){for(;R.next&&M>=R.t;)R=R.next;R=R.prev}else for(;R.prev&&M<=R.t;)R=R.prev;return this._prev=R,R.v+(M-R.t)/R.gap*R.c},w.config=function(M){return new c(M)},c.ease=new c,k("Bounce",b("BounceOut",function(M){return 1/2.75>M?7.5625*M*M:2/2.75>M?7.5625*(M-=1.5/2.75)*M+.75:2.5/2.75>M?7.5625*(M-=2.25/2.75)*M+.9375:7.5625*(M-=2.625/2.75)*M+.984375}),b("BounceIn",function(M){return(M=1-M)<1/2.75?1-7.5625*M*M:2/2.75>M?1-(7.5625*(M-=1.5/2.75)*M+.75):2.5/2.75>M?1-(7.5625*(M-=2.25/2.75)*M+.9375):1-(7.5625*(M-=2.625/2.75)*M+.984375)}),b("BounceInOut",function(M){var R=.5>M;return M=R?1-2*M:2*M-1,M=1/2.75>M?7.5625*M*M:2/2.75>M?7.5625*(M-=1.5/2.75)*M+.75:2.5/2.75>M?7.5625*(M-=2.25/2.75)*M+.9375:7.5625*(M-=2.625/2.75)*M+.984375,R?.5*(1-M):.5*M+.5})),k("Circ",b("CircOut",function(M){return Math.sqrt(1-(M-=1)*M)}),b("CircIn",function(M){return-(Math.sqrt(1-M*M)-1)}),b("CircInOut",function(M){return(M*=2)<1?-.5*(Math.sqrt(1-M*M)-1):.5*(Math.sqrt(1-(M-=2)*M)+1)})),f=function(M,R,C){var U=S("easing."+M,function(X,J){this._p1=X>=1?X:1,this._p2=(J||C)/(1>X?X:1),this._p3=this._p2/g*(Math.asin(1/this._p1)||0),this._p2=g/this._p2},!0),N=U.prototype=new x;return N.constructor=U,N.getRatio=R,N.config=function(X,J){return new U(X,J)},U},k("Elastic",f("ElasticOut",function(M){return this._p1*Math.pow(2,-10*M)*Math.sin((M-this._p3)*this._p2)+1},.3),f("ElasticIn",function(M){return-(this._p1*Math.pow(2,10*(M-=1))*Math.sin((M-this._p3)*this._p2))},.3),f("ElasticInOut",function(M){return(M*=2)<1?-.5*(this._p1*Math.pow(2,10*(M-=1))*Math.sin((M-this._p3)*this._p2)):this._p1*Math.pow(2,-10*(M-=1))*Math.sin((M-this._p3)*this._p2)*.5+1},.45)),k("Expo",b("ExpoOut",function(M){return 1-Math.pow(2,-10*M)}),b("ExpoIn",function(M){return Math.pow(2,10*(M-1))-.001}),b("ExpoInOut",function(M){return(M*=2)<1?.5*Math.pow(2,10*(M-1)):.5*(2-Math.pow(2,-10*(M-1)))})),k("Sine",b("SineOut",function(M){return Math.sin(M*v)}),b("SineIn",function(M){return-Math.cos(M*v)+1}),b("SineInOut",function(M){return-.5*(Math.cos(Math.PI*M)-1)})),S("easing.EaseLookup",{find:function(M){return x.map[M]}},!0),O(u.SlowMo,"SlowMo","ease,"),O(c,"RoughEase","ease,"),O(a,"SteppedEase","ease,"),E},!0)}),ln._gsDefine&&ln._gsQueue.pop()(),function(x,a){var o={},c=x.document,f=x.GreenSockGlobals=x.GreenSockGlobals||x,u=f[a];if(u)return typeof module<"u"&&module.exports&&(module.exports=u),u;var m,g,v,S,b,O=function(z){var Q,st=z.split("."),nt=f;for(Q=0;Q<st.length;Q++)nt[st[Q]]=nt=nt[st[Q]]||{};return nt},k=O("com.greensock"),I=1e-10,F=function(z){var Q,st=[],nt=z.length;for(Q=0;Q!==nt;st.push(z[Q++]));return st},E=function(){},P=function(){var z=Object.prototype.toString,Q=z.call([]);return function(st){return st!=null&&(st instanceof Array||typeof st=="object"&&!!st.push&&z.call(st)===Q)}}(),w={},M=function(z,Q,st,nt){this.sc=w[z]?w[z].sc:[],w[z]=this,this.gsClass=null,this.func=st;var vt=[];this.check=function(Ut){for(var qt,Xt,Ne,Ie,me=Q.length,we=me;--me>-1;)(qt=w[Q[me]]||new M(Q[me],[])).gsClass?(vt[me]=qt.gsClass,we--):Ut&&qt.sc.push(this);if(we===0&&st){if(Xt=("com.greensock."+z).split("."),Ne=Xt.pop(),Ie=O(Xt.join("."))[Ne]=this.gsClass=st.apply(st,vt),nt)if(f[Ne]=o[Ne]=Ie,typeof module<"u"&&module.exports)if(z===a){module.exports=o[a]=Ie;for(me in o)Ie[me]=o[me]}else o[a]&&(o[a][Ne]=Ie);else typeof define=="function"&&define.amd&&define((x.GreenSockAMDPath?x.GreenSockAMDPath+"/":"")+z.split(".").pop(),[],function(){return Ie});for(me=0;me<this.sc.length;me++)this.sc[me].check()}},this.check(!0)},R=x._gsDefine=function(z,Q,st,nt){return new M(z,Q,st,nt)},C=k._class=function(z,Q,st){return Q=Q||function(){},R(z,[],function(){return Q},st),Q};R.globals=f;var U=[0,0,1,1],N=C("easing.Ease",function(z,Q,st,nt){this._func=z,this._type=st||0,this._power=nt||0,this._params=Q?U.concat(Q):U},!0),X=N.map={},J=N.register=function(z,Q,st,nt){for(var vt,Ut,qt,Xt,Ne=Q.split(","),Ie=Ne.length,me=(st||"easeIn,easeOut,easeInOut").split(",");--Ie>-1;)for(Ut=Ne[Ie],vt=nt?C("easing."+Ut,null,!0):k.easing[Ut]||{},qt=me.length;--qt>-1;)Xt=me[qt],X[Ut+"."+Xt]=X[Xt+Ut]=vt[Xt]=z.getRatio?z:z[Xt]||new z};for(v=N.prototype,v._calcEnd=!1,v.getRatio=function(z){if(this._func)return this._params[0]=z,this._func.apply(null,this._params);var Q=this._type,st=this._power,nt=Q===1?1-z:Q===2?z:.5>z?2*z:2*(1-z);return st===1?nt*=nt:st===2?nt*=nt*nt:st===3?nt*=nt*nt*nt:st===4&&(nt*=nt*nt*nt*nt),Q===1?1-nt:Q===2?nt:.5>z?nt/2:1-nt/2},m=["Linear","Quad","Cubic","Quart","Quint,Strong"],g=m.length;--g>-1;)v=m[g]+",Power"+g,J(new N(null,null,1,g),v,"easeOut",!0),J(new N(null,null,2,g),v,"easeIn"+(g===0?",easeNone":"")),J(new N(null,null,3,g),v,"easeInOut");X.linear=k.easing.Linear.easeIn,X.swing=k.easing.Quad.easeInOut;var Z=C("events.EventDispatcher",function(z){this._listeners={},this._eventTarget=z||this});v=Z.prototype,v.addEventListener=function(z,Q,st,nt,vt){vt=vt||0;var Ut,qt,Xt=this._listeners[z],Ne=0;for(this!==S||b||S.wake(),Xt==null&&(this._listeners[z]=Xt=[]),qt=Xt.length;--qt>-1;)Ut=Xt[qt],Ut.c===Q&&Ut.s===st?Xt.splice(qt,1):Ne===0&&Ut.pr<vt&&(Ne=qt+1);Xt.splice(Ne,0,{c:Q,s:st,up:nt,pr:vt})},v.removeEventListener=function(z,Q){var st,nt=this._listeners[z];if(nt){for(st=nt.length;--st>-1;)if(nt[st].c===Q)return void nt.splice(st,1)}},v.dispatchEvent=function(z){var Q,st,nt,vt=this._listeners[z];if(vt)for(Q=vt.length,Q>1&&(vt=vt.slice(0)),st=this._eventTarget;--Q>-1;)nt=vt[Q],nt&&(nt.up?nt.c.call(nt.s||st,{type:z,target:st}):nt.c.call(nt.s||st))};var ct=x.requestAnimationFrame,Rt=x.cancelAnimationFrame,tt=Date.now||function(){return new Date().getTime()},_t=tt();for(m=["ms","moz","webkit","o"],g=m.length;--g>-1&&!ct;)ct=x[m[g]+"RequestAnimationFrame"],Rt=x[m[g]+"CancelAnimationFrame"]||x[m[g]+"CancelRequestAnimationFrame"];C("Ticker",function(z,Q){var st,nt,vt,Ut,qt,Xt=this,Ne=tt(),Ie=Q!==!1&&ct?"auto":!1,me=500,we=33,yi="tick",Ei=function(ni){var bi,qr,sr=tt()-_t;sr>me&&(Ne+=sr-we),_t+=sr,Xt.time=(_t-Ne)/1e3,bi=Xt.time-qt,(!st||bi>0||ni===!0)&&(Xt.frame++,qt+=bi+(bi>=Ut?.004:Ut-bi),qr=!0),ni!==!0&&(vt=nt(Ei)),qr&&Xt.dispatchEvent(yi)};Z.call(Xt),Xt.time=Xt.frame=0,Xt.tick=function(){Ei(!0)},Xt.lagSmoothing=function(ni,bi){return arguments.length?(me=ni||1/I,void(we=Math.min(bi,me,0))):1/I>me},Xt.sleep=function(){vt!=null&&(Ie&&Rt?Rt(vt):clearTimeout(vt),nt=E,vt=null,Xt===S&&(b=!1))},Xt.wake=function(ni){vt!==null?Xt.sleep():ni?Ne+=-_t+(_t=tt()):Xt.frame>10&&(_t=tt()-me+5),nt=st===0?E:Ie&&ct?ct:function(bi){return setTimeout(bi,1e3*(qt-Xt.time)+1|0)},Xt===S&&(b=!0),Ei(2)},Xt.fps=function(ni){return arguments.length?(st=ni,Ut=1/(st||60),qt=this.time+Ut,void Xt.wake()):st},Xt.useRAF=function(ni){return arguments.length?(Xt.sleep(),Ie=ni,void Xt.fps(st)):Ie},Xt.fps(z),setTimeout(function(){Ie==="auto"&&Xt.frame<5&&(c||{}).visibilityState!=="hidden"&&Xt.useRAF(!1)},1500)}),v=k.Ticker.prototype=new k.events.EventDispatcher,v.constructor=k.Ticker;var G=C("core.Animation",function(z,Q){if(this.vars=Q=Q||{},this._duration=this._totalDuration=z||0,this._delay=Number(Q.delay)||0,this._timeScale=1,this._active=Q.immediateRender===!0,this.data=Q.data,this._reversed=Q.reversed===!0,W){b||S.wake();var st=this.vars.useFrames?Qi:W;st.add(this,st._time),this.vars.paused&&this.paused(!0)}});S=G.ticker=new k.Ticker,v=G.prototype,v._dirty=v._gc=v._initted=v._paused=!1,v._totalTime=v._time=0,v._rawPrevTime=-1,v._next=v._last=v._onUpdate=v._timeline=v.timeline=null,v._paused=!1;var Pt=function(){b&&tt()-_t>2e3&&((c||{}).visibilityState!=="hidden"||!S.lagSmoothing())&&S.wake();var z=setTimeout(Pt,2e3);z.unref&&z.unref()};Pt(),v.play=function(z,Q){return z!=null&&this.seek(z,Q),this.reversed(!1).paused(!1)},v.pause=function(z,Q){return z!=null&&this.seek(z,Q),this.paused(!0)},v.resume=function(z,Q){return z!=null&&this.seek(z,Q),this.paused(!1)},v.seek=function(z,Q){return this.totalTime(Number(z),Q!==!1)},v.restart=function(z,Q){return this.reversed(!1).paused(!1).totalTime(z?-this._delay:0,Q!==!1,!0)},v.reverse=function(z,Q){return z!=null&&this.seek(z||this.totalDuration(),Q),this.reversed(!0).paused(!1)},v.render=function(z,Q,st){},v.invalidate=function(){return this._time=this._totalTime=0,this._initted=this._gc=!1,this._rawPrevTime=-1,(this._gc||!this.timeline)&&this._enabled(!0),this},v.isActive=function(){var z,Q=this._timeline,st=this._startTime;return!Q||!this._gc&&!this._paused&&Q.isActive()&&(z=Q.rawTime(!0))>=st&&z<st+this.totalDuration()/this._timeScale-1e-7},v._enabled=function(z,Q){return b||S.wake(),this._gc=!z,this._active=this.isActive(),Q!==!0&&(z&&!this.timeline?this._timeline.add(this,this._startTime-this._delay):!z&&this.timeline&&this._timeline._remove(this,!0)),!1},v._kill=function(z,Q){return this._enabled(!1,!1)},v.kill=function(z,Q){return this._kill(z,Q),this},v._uncache=function(z){for(var Q=z?this:this.timeline;Q;)Q._dirty=!0,Q=Q.timeline;return this},v._swapSelfInParams=function(z){for(var Q=z.length,st=z.concat();--Q>-1;)z[Q]==="{self}"&&(st[Q]=this);return st},v._callback=function(z){var Q=this.vars,st=Q[z],nt=Q[z+"Params"],vt=Q[z+"Scope"]||Q.callbackScope||this,Ut=nt?nt.length:0;switch(Ut){case 0:st.call(vt);break;case 1:st.call(vt,nt[0]);break;case 2:st.call(vt,nt[0],nt[1]);break;default:st.apply(vt,nt)}},v.eventCallback=function(z,Q,st,nt){if((z||"").substr(0,2)==="on"){var vt=this.vars;if(arguments.length===1)return vt[z];Q==null?delete vt[z]:(vt[z]=Q,vt[z+"Params"]=P(st)&&st.join("").indexOf("{self}")!==-1?this._swapSelfInParams(st):st,vt[z+"Scope"]=nt),z==="onUpdate"&&(this._onUpdate=Q)}return this},v.delay=function(z){return arguments.length?(this._timeline.smoothChildTiming&&this.startTime(this._startTime+z-this._delay),this._delay=z,this):this._delay},v.duration=function(z){return arguments.length?(this._duration=this._totalDuration=z,this._uncache(!0),this._timeline.smoothChildTiming&&this._time>0&&this._time<this._duration&&z!==0&&this.totalTime(this._totalTime*(z/this._duration),!0),this):(this._dirty=!1,this._duration)},v.totalDuration=function(z){return this._dirty=!1,arguments.length?this.duration(z):this._totalDuration},v.time=function(z,Q){return arguments.length?(this._dirty&&this.totalDuration(),this.totalTime(z>this._duration?this._duration:z,Q)):this._time},v.totalTime=function(z,Q,st){if(b||S.wake(),!arguments.length)return this._totalTime;if(this._timeline){if(0>z&&!st&&(z+=this.totalDuration()),this._timeline.smoothChildTiming){this._dirty&&this.totalDuration();var nt=this._totalDuration,vt=this._timeline;if(z>nt&&!st&&(z=nt),this._startTime=(this._paused?this._pauseTime:vt._time)-(this._reversed?nt-z:z)/this._timeScale,vt._dirty||this._uncache(!1),vt._timeline)for(;vt._timeline;)vt._timeline._time!==(vt._startTime+vt._totalTime)/vt._timeScale&&vt.totalTime(vt._totalTime,!0),vt=vt._timeline}this._gc&&this._enabled(!0,!1),(this._totalTime!==z||this._duration===0)&&(Ft.length&&jt(),this.render(z,Q,!1),Ft.length&&jt())}return this},v.progress=v.totalProgress=function(z,Q){var st=this.duration();return arguments.length?this.totalTime(st*z,Q):st?this._time/st:this.ratio},v.startTime=function(z){return arguments.length?(z!==this._startTime&&(this._startTime=z,this.timeline&&this.timeline._sortChildren&&this.timeline.add(this,z-this._delay)),this):this._startTime},v.endTime=function(z){return this._startTime+(z!=0?this.totalDuration():this.duration())/this._timeScale},v.timeScale=function(z){if(!arguments.length)return this._timeScale;var Q,st;for(z=z||I,this._timeline&&this._timeline.smoothChildTiming&&(Q=this._pauseTime,st=Q||Q===0?Q:this._timeline.totalTime(),this._startTime=st-(st-this._startTime)*this._timeScale/z),this._timeScale=z,st=this.timeline;st&&st.timeline;)st._dirty=!0,st.totalDuration(),st=st.timeline;return this},v.reversed=function(z){return arguments.length?(z!=this._reversed&&(this._reversed=z,this.totalTime(this._timeline&&!this._timeline.smoothChildTiming?this.totalDuration()-this._totalTime:this._totalTime,!0)),this):this._reversed},v.paused=function(z){if(!arguments.length)return this._paused;var Q,st,nt=this._timeline;return z!=this._paused&&nt&&(b||z||S.wake(),Q=nt.rawTime(),st=Q-this._pauseTime,!z&&nt.smoothChildTiming&&(this._startTime+=st,this._uncache(!1)),this._pauseTime=z?Q:null,this._paused=z,this._active=this.isActive(),!z&&st!==0&&this._initted&&this.duration()&&(Q=nt.smoothChildTiming?this._totalTime:(Q-this._startTime)/this._timeScale,this.render(Q,Q===this._totalTime,!0))),this._gc&&!z&&this._enabled(!0,!1),this};var Et=C("core.SimpleTimeline",function(z){G.call(this,0,z),this.autoRemoveChildren=this.smoothChildTiming=!0});v=Et.prototype=new G,v.constructor=Et,v.kill()._gc=!1,v._first=v._last=v._recent=null,v._sortChildren=!1,v.add=v.insert=function(z,Q,st,nt){var vt,Ut;if(z._startTime=Number(Q||0)+z._delay,z._paused&&this!==z._timeline&&(z._pauseTime=this.rawTime()-(z._timeline.rawTime()-z._pauseTime)),z.timeline&&z.timeline._remove(z,!0),z.timeline=z._timeline=this,z._gc&&z._enabled(!0,!0),vt=this._last,this._sortChildren)for(Ut=z._startTime;vt&&vt._startTime>Ut;)vt=vt._prev;return vt?(z._next=vt._next,vt._next=z):(z._next=this._first,this._first=z),z._next?z._next._prev=z:this._last=z,z._prev=vt,this._recent=z,this._timeline&&this._uncache(!0),this},v._remove=function(z,Q){return z.timeline===this&&(Q||z._enabled(!1,!0),z._prev?z._prev._next=z._next:this._first===z&&(this._first=z._next),z._next?z._next._prev=z._prev:this._last===z&&(this._last=z._prev),z._next=z._prev=z.timeline=null,z===this._recent&&(this._recent=this._last),this._timeline&&this._uncache(!0)),this},v.render=function(z,Q,st){var nt,vt=this._first;for(this._totalTime=this._time=this._rawPrevTime=z;vt;)nt=vt._next,(vt._active||z>=vt._startTime&&!vt._paused&&!vt._gc)&&(vt._reversed?vt.render((vt._dirty?vt.totalDuration():vt._totalDuration)-(z-vt._startTime)*vt._timeScale,Q,st):vt.render((z-vt._startTime)*vt._timeScale,Q,st)),vt=nt},v.rawTime=function(){return b||S.wake(),this._totalTime};var At=C("TweenLite",function(z,Q,st){if(G.call(this,Q,st),this.render=At.prototype.render,z==null)throw"Cannot tween a null target.";this.target=z=typeof z!="string"?z:At.selector(z)||z;var nt,vt,Ut,qt=z.jquery||z.length&&z!==x&&z[0]&&(z[0]===x||z[0].nodeType&&z[0].style&&!z.nodeType),Xt=this.vars.overwrite;if(this._overwrite=Xt=Xt==null?mn[At.defaultOverwrite]:typeof Xt=="number"?Xt>>0:mn[Xt],(qt||z instanceof Array||z.push&&P(z))&&typeof z[0]!="number")for(this._targets=Ut=F(z),this._propLookup=[],this._siblings=[],nt=0;nt<Ut.length;nt++)vt=Ut[nt],vt?typeof vt!="string"?vt.length&&vt!==x&&vt[0]&&(vt[0]===x||vt[0].nodeType&&vt[0].style&&!vt.nodeType)?(Ut.splice(nt--,1),this._targets=Ut=Ut.concat(F(vt))):(this._siblings[nt]=dt(vt,this,!1),Xt===1&&this._siblings[nt].length>1&&Dt(vt,this,null,1,this._siblings[nt])):(vt=Ut[nt--]=At.selector(vt),typeof vt=="string"&&Ut.splice(nt+1,1)):Ut.splice(nt--,1);else this._propLookup={},this._siblings=dt(z,this,!1),Xt===1&&this._siblings.length>1&&Dt(z,this,null,1,this._siblings);(this.vars.immediateRender||Q===0&&this._delay===0&&this.vars.immediateRender!==!1)&&(this._time=-I,this.render(Math.min(0,-this._delay)))},!0),ce=function(z){return z&&z.length&&z!==x&&z[0]&&(z[0]===x||z[0].nodeType&&z[0].style&&!z.nodeType)},re=function(z,Q){var st,nt={};for(st in z)Di[st]||st in Q&&st!=="transform"&&st!=="x"&&st!=="y"&&st!=="width"&&st!=="height"&&st!=="className"&&st!=="border"||!(!Oe[st]||Oe[st]&&Oe[st]._autoCSS)||(nt[st]=z[st],delete z[st]);z.css=nt};v=At.prototype=new G,v.constructor=At,v.kill()._gc=!1,v.ratio=0,v._firstPT=v._targets=v._overwrittenProps=v._startAt=null,v._notifyPluginsOfEnabled=v._lazy=!1,At.version="2.0.2",At.defaultEase=v._ease=new N(null,null,1,1),At.defaultOverwrite="auto",At.ticker=S,At.autoSleep=120,At.lagSmoothing=function(z,Q){S.lagSmoothing(z,Q)},At.selector=x.$||x.jQuery||function(z){var Q=x.$||x.jQuery;return Q?(At.selector=Q,Q(z)):(c||(c=x.document),c?c.querySelectorAll?c.querySelectorAll(z):c.getElementById(z.charAt(0)==="#"?z.substr(1):z):z)};var Ft=[],It={},Nt=/(?:(-|-=|\+=)?\d*\.?\d*(?:e[\-+]?\d+)?)[0-9]/gi,Pe=/[\+-]=-?[\.\d]/,pe=function(z){for(var Q,st=this._firstPT,nt=1e-6;st;)Q=st.blob?z===1&&this.end!=null?this.end:z?this.join(""):this.start:st.c*z+st.s,st.m?Q=st.m.call(this._tween,Q,this._target||st.t,this._tween):nt>Q&&Q>-nt&&!st.blob&&(Q=0),st.f?st.fp?st.t[st.p](st.fp,Q):st.t[st.p](Q):st.t[st.p]=Q,st=st._next},Wt=function(z,Q,st,nt){var vt,Ut,qt,Xt,Ne,Ie,me,we=[],yi=0,Ei="",ni=0;for(we.start=z,we.end=Q,z=we[0]=z+"",Q=we[1]=Q+"",st&&(st(we),z=we[0],Q=we[1]),we.length=0,vt=z.match(Nt)||[],Ut=Q.match(Nt)||[],nt&&(nt._next=null,nt.blob=1,we._firstPT=we._applyPT=nt),Ne=Ut.length,Xt=0;Ne>Xt;Xt++)me=Ut[Xt],Ie=Q.substr(yi,Q.indexOf(me,yi)-yi),Ei+=Ie||!Xt?Ie:",",yi+=Ie.length,ni?ni=(ni+1)%5:Ie.substr(-5)==="rgba("&&(ni=1),me===vt[Xt]||vt.length<=Xt?Ei+=me:(Ei&&(we.push(Ei),Ei=""),qt=parseFloat(vt[Xt]),we.push(qt),we._firstPT={_next:we._firstPT,t:we,p:we.length-1,s:qt,c:(me.charAt(1)==="="?parseInt(me.charAt(0)+"1",10)*parseFloat(me.substr(2)):parseFloat(me)-qt)||0,f:0,m:ni&&4>ni?Math.round:0}),yi+=me.length;return Ei+=Q.substr(yi),Ei&&we.push(Ei),we.setRatio=pe,Pe.test(Q)&&(we.end=null),we},$e=function(z,Q,st,nt,vt,Ut,qt,Xt,Ne){typeof nt=="function"&&(nt=nt(Ne||0,z));var Ie,me=typeof z[Q],we=me!=="function"?"":Q.indexOf("set")||typeof z["get"+Q.substr(3)]!="function"?Q:"get"+Q.substr(3),yi=st!=="get"?st:we?qt?z[we](qt):z[we]():z[Q],Ei=typeof nt=="string"&&nt.charAt(1)==="=",ni={t:z,p:Q,s:yi,f:me==="function",pg:0,n:vt||Q,m:Ut?typeof Ut=="function"?Ut:Math.round:0,pr:0,c:Ei?parseInt(nt.charAt(0)+"1",10)*parseFloat(nt.substr(2)):parseFloat(nt)-yi||0};return(typeof yi!="number"||typeof nt!="number"&&!Ei)&&(qt||isNaN(yi)||!Ei&&isNaN(nt)||typeof yi=="boolean"||typeof nt=="boolean"?(ni.fp=qt,Ie=Wt(yi,Ei?parseFloat(ni.s)+ni.c+(ni.s+"").replace(/[0-9\-\.]/g,""):nt,Xt||At.defaultStringFilter,ni),ni={t:Ie,p:"setRatio",s:0,c:1,f:2,pg:0,n:vt||Q,pr:0,m:0}):(ni.s=parseFloat(yi),Ei||(ni.c=parseFloat(nt)-ni.s||0))),ni.c?((ni._next=this._firstPT)&&(ni._next._prev=ni),this._firstPT=ni,ni):void 0},Si=At._internals={isArray:P,isSelector:ce,lazyTweens:Ft,blobDif:Wt},Oe=At._plugins={},Ge=Si.tweenLookup={},pi=0,Di=Si.reservedProps={ease:1,delay:1,overwrite:1,onComplete:1,onCompleteParams:1,onCompleteScope:1,useFrames:1,runBackwards:1,startAt:1,onUpdate:1,onUpdateParams:1,onUpdateScope:1,onStart:1,onStartParams:1,onStartScope:1,onReverseComplete:1,onReverseCompleteParams:1,onReverseCompleteScope:1,onRepeat:1,onRepeatParams:1,onRepeatScope:1,easeParams:1,yoyo:1,immediateRender:1,repeat:1,repeatDelay:1,data:1,paused:1,reversed:1,autoCSS:1,lazy:1,onOverwrite:1,callbackScope:1,stringFilter:1,id:1,yoyoEase:1},mn={none:0,all:1,auto:2,concurrent:3,allOnStart:4,preexisting:5,true:1,false:0},Qi=G._rootFramesTimeline=new Et,W=G._rootTimeline=new Et,Jt=30,jt=Si.lazyRender=function(){var z,Q=Ft.length;for(It={};--Q>-1;)z=Ft[Q],z&&z._lazy!==!1&&(z.render(z._lazy[0],z._lazy[1],!0),z._lazy=!1);Ft.length=0};W._startTime=S.time,Qi._startTime=S.frame,W._active=Qi._active=!0,setTimeout(jt,1),G._updateRoot=At.render=function(){var z,Q,st;if(Ft.length&&jt(),W.render((S.time-W._startTime)*W._timeScale,!1,!1),Qi.render((S.frame-Qi._startTime)*Qi._timeScale,!1,!1),Ft.length&&jt(),S.frame>=Jt){Jt=S.frame+(parseInt(At.autoSleep,10)||120);for(st in Ge){for(Q=Ge[st].tweens,z=Q.length;--z>-1;)Q[z]._gc&&Q.splice(z,1);Q.length===0&&delete Ge[st]}if(st=W._first,(!st||st._paused)&&At.autoSleep&&!Qi._first&&S._listeners.tick.length===1){for(;st&&st._paused;)st=st._next;st||S.sleep()}}},S.addEventListener("tick",G._updateRoot);var dt=function(z,Q,st){var nt,vt,Ut=z._gsTweenID;if(Ge[Ut||(z._gsTweenID=Ut="t"+pi++)]||(Ge[Ut]={target:z,tweens:[]}),Q&&(nt=Ge[Ut].tweens,nt[vt=nt.length]=Q,st))for(;--vt>-1;)nt[vt]===Q&&nt.splice(vt,1);return Ge[Ut].tweens},pt=function(z,Q,st,nt){var vt,Ut,qt=z.vars.onOverwrite;return qt&&(vt=qt(z,Q,st,nt)),qt=At.onOverwrite,qt&&(Ut=qt(z,Q,st,nt)),vt!==!1&&Ut!==!1},Dt=function(z,Q,st,nt,vt){var Ut,qt,Xt,Ne;if(nt===1||nt>=4){for(Ne=vt.length,Ut=0;Ne>Ut;Ut++)if((Xt=vt[Ut])!==Q)Xt._gc||Xt._kill(null,z,Q)&&(qt=!0);else if(nt===5)break;return qt}var Ie,me=Q._startTime+I,we=[],yi=0,Ei=Q._duration===0;for(Ut=vt.length;--Ut>-1;)(Xt=vt[Ut])===Q||Xt._gc||Xt._paused||(Xt._timeline!==Q._timeline?(Ie=Ie||ie(Q,0,Ei),ie(Xt,Ie,Ei)===0&&(we[yi++]=Xt)):Xt._startTime<=me&&Xt._startTime+Xt.totalDuration()/Xt._timeScale>me&&((Ei||!Xt._initted)&&me-Xt._startTime<=2e-10||(we[yi++]=Xt)));for(Ut=yi;--Ut>-1;)if(Xt=we[Ut],Ne=Xt._firstPT,nt===2&&Xt._kill(st,z,Q)&&(qt=!0),nt!==2||!Xt._firstPT&&Xt._initted&&Ne){if(nt!==2&&!pt(Xt,Q))continue;Xt._enabled(!1,!1)&&(qt=!0)}return qt},ie=function(z,Q,st){for(var nt=z._timeline,vt=nt._timeScale,Ut=z._startTime;nt._timeline;){if(Ut+=nt._startTime,vt*=nt._timeScale,nt._paused)return-100;nt=nt._timeline}return Ut/=vt,Ut>Q?Ut-Q:st&&Ut===Q||!z._initted&&2*I>Ut-Q?I:(Ut+=z.totalDuration()/z._timeScale/vt)>Q+I?0:Ut-Q-I};v._init=function(){var z,Q,st,nt,vt,Ut,qt=this.vars,Xt=this._overwrittenProps,Ne=this._duration,Ie=!!qt.immediateRender,me=qt.ease;if(qt.startAt){this._startAt&&(this._startAt.render(-1,!0),this._startAt.kill()),vt={};for(nt in qt.startAt)vt[nt]=qt.startAt[nt];if(vt.data="isStart",vt.overwrite=!1,vt.immediateRender=!0,vt.lazy=Ie&&qt.lazy!==!1,vt.startAt=vt.delay=null,vt.onUpdate=qt.onUpdate,vt.onUpdateParams=qt.onUpdateParams,vt.onUpdateScope=qt.onUpdateScope||qt.callbackScope||this,this._startAt=At.to(this.target||{},0,vt),Ie){if(this._time>0)this._startAt=null;else if(Ne!==0)return}}else if(qt.runBackwards&&Ne!==0)if(this._startAt)this._startAt.render(-1,!0),this._startAt.kill(),this._startAt=null;else{this._time!==0&&(Ie=!1),st={};for(nt in qt)Di[nt]&&nt!=="autoCSS"||(st[nt]=qt[nt]);if(st.overwrite=0,st.data="isFromStart",st.lazy=Ie&&qt.lazy!==!1,st.immediateRender=Ie,this._startAt=At.to(this.target,0,st),Ie){if(this._time===0)return}else this._startAt._init(),this._startAt._enabled(!1),this.vars.immediateRender&&(this._startAt=null)}if(this._ease=me=me?me instanceof N?me:typeof me=="function"?new N(me,qt.easeParams):X[me]||At.defaultEase:At.defaultEase,qt.easeParams instanceof Array&&me.config&&(this._ease=me.config.apply(me,qt.easeParams)),this._easeType=this._ease._type,this._easePower=this._ease._power,this._firstPT=null,this._targets)for(Ut=this._targets.length,z=0;Ut>z;z++)this._initProps(this._targets[z],this._propLookup[z]={},this._siblings[z],Xt?Xt[z]:null,z)&&(Q=!0);else Q=this._initProps(this.target,this._propLookup,this._siblings,Xt,0);if(Q&&At._onPluginEvent("_onInitAllProps",this),Xt&&(this._firstPT||typeof this.target!="function"&&this._enabled(!1,!1)),qt.runBackwards)for(st=this._firstPT;st;)st.s+=st.c,st.c=-st.c,st=st._next;this._onUpdate=qt.onUpdate,this._initted=!0},v._initProps=function(z,Q,st,nt,vt){var Ut,qt,Xt,Ne,Ie,me;if(z==null)return!1;It[z._gsTweenID]&&jt(),this.vars.css||z.style&&z!==x&&z.nodeType&&Oe.css&&this.vars.autoCSS!==!1&&re(this.vars,z);for(Ut in this.vars)if(me=this.vars[Ut],Di[Ut])me&&(me instanceof Array||me.push&&P(me))&&me.join("").indexOf("{self}")!==-1&&(this.vars[Ut]=me=this._swapSelfInParams(me,this));else if(Oe[Ut]&&(Ne=new Oe[Ut])._onInitTween(z,this.vars[Ut],this,vt)){for(this._firstPT=Ie={_next:this._firstPT,t:Ne,p:"setRatio",s:0,c:1,f:1,n:Ut,pg:1,pr:Ne._priority,m:0},qt=Ne._overwriteProps.length;--qt>-1;)Q[Ne._overwriteProps[qt]]=this._firstPT;(Ne._priority||Ne._onInitAllProps)&&(Xt=!0),(Ne._onDisable||Ne._onEnable)&&(this._notifyPluginsOfEnabled=!0),Ie._next&&(Ie._next._prev=Ie)}else Q[Ut]=$e.call(this,z,Ut,"get",me,Ut,0,null,this.vars.stringFilter,vt);return nt&&this._kill(nt,z)?this._initProps(z,Q,st,nt,vt):this._overwrite>1&&this._firstPT&&st.length>1&&Dt(z,this,Q,this._overwrite,st)?(this._kill(Q,z),this._initProps(z,Q,st,nt,vt)):(this._firstPT&&(this.vars.lazy!==!1&&this._duration||this.vars.lazy&&!this._duration)&&(It[z._gsTweenID]=!0),Xt)},v.render=function(z,Q,st){var nt,vt,Ut,qt,Xt=this._time,Ne=this._duration,Ie=this._rawPrevTime;if(z>=Ne-1e-7&&z>=0)this._totalTime=this._time=Ne,this.ratio=this._ease._calcEnd?this._ease.getRatio(1):1,this._reversed||(nt=!0,vt="onComplete",st=st||this._timeline.autoRemoveChildren),Ne===0&&(this._initted||!this.vars.lazy||st)&&(this._startTime===this._timeline._duration&&(z=0),(0>Ie||0>=z&&z>=-1e-7||Ie===I&&this.data!=="isPause")&&Ie!==z&&(st=!0,Ie>I&&(vt="onReverseComplete")),this._rawPrevTime=qt=!Q||z||Ie===z?z:I);else if(1e-7>z)this._totalTime=this._time=0,this.ratio=this._ease._calcEnd?this._ease.getRatio(0):0,(Xt!==0||Ne===0&&Ie>0)&&(vt="onReverseComplete",nt=this._reversed),0>z&&(this._active=!1,Ne===0&&(this._initted||!this.vars.lazy||st)&&(Ie>=0&&(Ie!==I||this.data!=="isPause")&&(st=!0),this._rawPrevTime=qt=!Q||z||Ie===z?z:I)),(!this._initted||this._startAt&&this._startAt.progress())&&(st=!0);else if(this._totalTime=this._time=z,this._easeType){var me=z/Ne,we=this._easeType,yi=this._easePower;(we===1||we===3&&me>=.5)&&(me=1-me),we===3&&(me*=2),yi===1?me*=me:yi===2?me*=me*me:yi===3?me*=me*me*me:yi===4&&(me*=me*me*me*me),we===1?this.ratio=1-me:we===2?this.ratio=me:.5>z/Ne?this.ratio=me/2:this.ratio=1-me/2}else this.ratio=this._ease.getRatio(z/Ne);if(this._time!==Xt||st){if(!this._initted){if(this._init(),!this._initted||this._gc)return;if(!st&&this._firstPT&&(this.vars.lazy!==!1&&this._duration||this.vars.lazy&&!this._duration))return this._time=this._totalTime=Xt,this._rawPrevTime=Ie,Ft.push(this),void(this._lazy=[z,Q]);this._time&&!nt?this.ratio=this._ease.getRatio(this._time/Ne):nt&&this._ease._calcEnd&&(this.ratio=this._ease.getRatio(this._time===0?0:1))}for(this._lazy!==!1&&(this._lazy=!1),this._active||!this._paused&&this._time!==Xt&&z>=0&&(this._active=!0),Xt===0&&(this._startAt&&(z>=0?this._startAt.render(z,!0,st):vt||(vt="_dummyGS")),this.vars.onStart&&(this._time!==0||Ne===0)&&(Q||this._callback("onStart"))),Ut=this._firstPT;Ut;)Ut.f?Ut.t[Ut.p](Ut.c*this.ratio+Ut.s):Ut.t[Ut.p]=Ut.c*this.ratio+Ut.s,Ut=Ut._next;this._onUpdate&&(0>z&&this._startAt&&z!==-1e-4&&this._startAt.render(z,!0,st),Q||(this._time!==Xt||nt||st)&&this._callback("onUpdate")),vt&&(!this._gc||st)&&(0>z&&this._startAt&&!this._onUpdate&&z!==-1e-4&&this._startAt.render(z,!0,st),nt&&(this._timeline.autoRemoveChildren&&this._enabled(!1,!1),this._active=!1),!Q&&this.vars[vt]&&this._callback(vt),Ne===0&&this._rawPrevTime===I&&qt!==I&&(this._rawPrevTime=0))}},v._kill=function(z,Q,st){if(z==="all"&&(z=null),z==null&&(Q==null||Q===this.target))return this._lazy=!1,this._enabled(!1,!1);Q=typeof Q!="string"?Q||this._targets||this.target:At.selector(Q)||Q;var nt,vt,Ut,qt,Xt,Ne,Ie,me,we,yi=st&&this._time&&st._startTime===this._startTime&&this._timeline===st._timeline,Ei=this._firstPT;if((P(Q)||ce(Q))&&typeof Q[0]!="number")for(nt=Q.length;--nt>-1;)this._kill(z,Q[nt],st)&&(Ne=!0);else{if(this._targets){for(nt=this._targets.length;--nt>-1;)if(Q===this._targets[nt]){Xt=this._propLookup[nt]||{},this._overwrittenProps=this._overwrittenProps||[],vt=this._overwrittenProps[nt]=z?this._overwrittenProps[nt]||{}:"all";break}}else{if(Q!==this.target)return!1;Xt=this._propLookup,vt=this._overwrittenProps=z?this._overwrittenProps||{}:"all"}if(Xt){if(Ie=z||Xt,me=z!==vt&&vt!=="all"&&z!==Xt&&(typeof z!="object"||!z._tempKill),st&&(At.onOverwrite||this.vars.onOverwrite)){for(Ut in Ie)Xt[Ut]&&(we||(we=[]),we.push(Ut));if((we||!z)&&!pt(this,st,Q,we))return!1}for(Ut in Ie)(qt=Xt[Ut])&&(yi&&(qt.f?qt.t[qt.p](qt.s):qt.t[qt.p]=qt.s,Ne=!0),qt.pg&&qt.t._kill(Ie)&&(Ne=!0),qt.pg&&qt.t._overwriteProps.length!==0||(qt._prev?qt._prev._next=qt._next:qt===this._firstPT&&(this._firstPT=qt._next),qt._next&&(qt._next._prev=qt._prev),qt._next=qt._prev=null),delete Xt[Ut]),me&&(vt[Ut]=1);!this._firstPT&&this._initted&&Ei&&this._enabled(!1,!1)}}return Ne},v.invalidate=function(){return this._notifyPluginsOfEnabled&&At._onPluginEvent("_onDisable",this),this._firstPT=this._overwrittenProps=this._startAt=this._onUpdate=null,this._notifyPluginsOfEnabled=this._active=this._lazy=!1,this._propLookup=this._targets?{}:[],G.prototype.invalidate.call(this),this.vars.immediateRender&&(this._time=-I,this.render(Math.min(0,-this._delay))),this},v._enabled=function(z,Q){if(b||S.wake(),z&&this._gc){var st,nt=this._targets;if(nt)for(st=nt.length;--st>-1;)this._siblings[st]=dt(nt[st],this,!0);else this._siblings=dt(this.target,this,!0)}return G.prototype._enabled.call(this,z,Q),this._notifyPluginsOfEnabled&&this._firstPT?At._onPluginEvent(z?"_onEnable":"_onDisable",this):!1},At.to=function(z,Q,st){return new At(z,Q,st)},At.from=function(z,Q,st){return st.runBackwards=!0,st.immediateRender=st.immediateRender!=0,new At(z,Q,st)},At.fromTo=function(z,Q,st,nt){return nt.startAt=st,nt.immediateRender=nt.immediateRender!=0&&st.immediateRender!=0,new At(z,Q,nt)},At.delayedCall=function(z,Q,st,nt,vt){return new At(Q,0,{delay:z,onComplete:Q,onCompleteParams:st,callbackScope:nt,onReverseComplete:Q,onReverseCompleteParams:st,immediateRender:!1,lazy:!1,useFrames:vt,overwrite:0})},At.set=function(z,Q){return new At(z,0,Q)},At.getTweensOf=function(z,Q){if(z==null)return[];z=typeof z!="string"?z:At.selector(z)||z;var st,nt,vt,Ut;if((P(z)||ce(z))&&typeof z[0]!="number"){for(st=z.length,nt=[];--st>-1;)nt=nt.concat(At.getTweensOf(z[st],Q));for(st=nt.length;--st>-1;)for(Ut=nt[st],vt=st;--vt>-1;)Ut===nt[vt]&&nt.splice(st,1)}else if(z._gsTweenID)for(nt=dt(z).concat(),st=nt.length;--st>-1;)(nt[st]._gc||Q&&!nt[st].isActive())&&nt.splice(st,1);return nt||[]},At.killTweensOf=At.killDelayedCallsTo=function(z,Q,st){typeof Q=="object"&&(st=Q,Q=!1);for(var nt=At.getTweensOf(z,Q),vt=nt.length;--vt>-1;)nt[vt]._kill(st,z)};var Kt=C("plugins.TweenPlugin",function(z,Q){this._overwriteProps=(z||"").split(","),this._propName=this._overwriteProps[0],this._priority=Q||0,this._super=Kt.prototype},!0);if(v=Kt.prototype,Kt.version="1.19.0",Kt.API=2,v._firstPT=null,v._addTween=$e,v.setRatio=pe,v._kill=function(z){var Q,st=this._overwriteProps,nt=this._firstPT;if(z[this._propName]!=null)this._overwriteProps=[];else for(Q=st.length;--Q>-1;)z[st[Q]]!=null&&st.splice(Q,1);for(;nt;)z[nt.n]!=null&&(nt._next&&(nt._next._prev=nt._prev),nt._prev?(nt._prev._next=nt._next,nt._prev=null):this._firstPT===nt&&(this._firstPT=nt._next)),nt=nt._next;return!1},v._mod=v._roundProps=function(z){for(var Q,st=this._firstPT;st;)Q=z[this._propName]||st.n!=null&&z[st.n.split(this._propName+"_").join("")],Q&&typeof Q=="function"&&(st.f===2?st.t._applyPT.m=Q:st.m=Q),st=st._next},At._onPluginEvent=function(z,Q){var st,nt,vt,Ut,qt,Xt=Q._firstPT;if(z==="_onInitAllProps"){for(;Xt;){for(qt=Xt._next,nt=vt;nt&&nt.pr>Xt.pr;)nt=nt._next;(Xt._prev=nt?nt._prev:Ut)?Xt._prev._next=Xt:vt=Xt,(Xt._next=nt)?nt._prev=Xt:Ut=Xt,Xt=qt}Xt=Q._firstPT=vt}for(;Xt;)Xt.pg&&typeof Xt.t[z]=="function"&&Xt.t[z]()&&(st=!0),Xt=Xt._next;return st},Kt.activate=function(z){for(var Q=z.length;--Q>-1;)z[Q].API===Kt.API&&(Oe[new z[Q]()._propName]=z[Q]);return!0},R.plugin=function(z){if(!(z&&z.propName&&z.init&&z.API))throw"illegal plugin definition.";var Q,st=z.propName,nt=z.priority||0,vt=z.overwriteProps,Ut={init:"_onInitTween",set:"setRatio",kill:"_kill",round:"_mod",mod:"_mod",initAll:"_onInitAllProps"},qt=C("plugins."+st.charAt(0).toUpperCase()+st.substr(1)+"Plugin",function(){Kt.call(this,st,nt),this._overwriteProps=vt||[]},z.global===!0),Xt=qt.prototype=new Kt(st);Xt.constructor=qt,qt.API=z.API;for(Q in Ut)typeof z[Q]=="function"&&(Xt[Ut[Q]]=z[Q]);return qt.version=z.version,Kt.activate([qt]),qt},m=x._gsQueue){for(g=0;g<m.length;g++)m[g]();for(v in w)w[v].func||x.console.log("GSAP encountered missing dependency: "+v)}b=!1}(typeof module<"u"&&module.exports&&typeof global<"u"?global:globalThis||window,"TweenMax");const $p={class:"modal-background"},Kp=["innerHTML"],Qp={name:"MapModali"},Sf=oi.defineComponent({...Qp,props:{},setup(x,{expose:a}){const o=oi.ref(""),c=oi.ref(""),f=m=>{c.value=m,o.value="five"},u=()=>{o.value=o.value+" out"};return oi.onMounted(()=>{}),a({text:c,show:f,hide:u}),(m,g)=>(oi.openBlock(),oi.createElementBlock("div",{id:"modal-container",class:oi.normalizeClass(o.value),onClick:u},[oi.createElementVNode("div",$p,[oi.createElementVNode("div",{class:"modal",onClick:g[0]||(g[0]=v=>{v.stopPropagation()})},[oi.createElementVNode("p",{style:{"white-space":"pre-line","line-height":"1",margin:"0",color:"#fff"},innerHTML:c.value},null,8,Kp)])])],2))}}),A1="",tm={class:"bim_background_plate"},em={class:"content"},im=oi.createElementVNode("canvas",{class:"landscape"},null,-1),nm={class:"content__title"},rm=oi.createElementVNode("div",{class:"overlay"},null,-1),om={name:"BimBackgroundPlate"},Ef=oi.defineComponent({...om,setup(x){const a=()=>{let f=`
|
|
14
14
|
vec3 mod289(vec3 x)
|
|
15
15
|
{
|
|
16
16
|
return x - floor(x * (1.0 / 289.0)) * 289.0;
|
|
@@ -248,21 +248,21 @@
|
|
|
248
248
|
float fogFactor = smoothstep( fogNear, fogFar, fogDepth );
|
|
249
249
|
gl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );
|
|
250
250
|
#endif
|
|
251
|
-
}`;var m=document.querySelector(".landscape"),g=window.innerWidth,v=window.innerHeight,S,b,O,k,I={x:0,y:0,xDamped:0,yDamped:0},N=typeof window.orientation<"u";E();function E(){P(),w(),M(),F(),N?window.addEventListener("touchmove",U,{passive:!1}):window.addEventListener("mousemove",U),window.addEventListener("resize",C),C()}function P(){S=new THREE.Scene;var Z=new THREE.Color(3355443);S.background=Z,S.fog=new THREE.Fog(Z,0,400),R(),O=new THREE.PerspectiveCamera(60,g/v,.1,1e4),O.position.y=8,O.position.z=4;let ct=new THREE.AmbientLight(16777215,1);S.add(ct),b=new THREE.WebGLRenderer({canvas:m,antialias:!0}),b.setPixelRatio=devicePixelRatio,b.setSize(g,v)}function w(){var Z=new THREE.PlaneBufferGeometry(100,400,400,400),ct={time:{type:"f",value:0},scroll:{type:"f",value:0},distortCenter:{type:"f",value:.1},roadWidth:{type:"f",value:.5},pallete:{type:"t",value:null},speed:{type:"f",value:3},maxHeight:{type:"f",value:10},color:new THREE.Color(1,1,1)},Rt=new THREE.ShaderMaterial({uniforms:THREE.UniformsUtils.merge([THREE.ShaderLib.basic.uniforms,ct]),vertexShader:f,fragmentShader:u,wireframe:!1,fog:!0});k=new THREE.Mesh(Z,Rt),k.position.z=-180,k.rotation.x=-Math.PI/2,S.add(k)}function M(){new THREE.TextureLoader().load("",function(Z){k.material.uniforms.pallete.value=Z,k.material.needsUpdate=!0})}function R(){R=new THREE.Sky,R.scale.setScalar(45e4),R.material.uniforms.turbidity.value=13,R.material.uniforms.rayleigh.value=1.2,R.material.uniforms.luminance.value=1,R.material.uniforms.mieCoefficient.value=.1,R.material.uniforms.mieDirectionalG.value=.58,S.add(R);let Z=new THREE.Mesh(new THREE.SphereBufferGeometry(2e4,16,8),new THREE.MeshBasicMaterial({color:16777215}));Z.visible=!1,S.add(Z);var ct=Math.PI*-.002,Rt=2*Math.PI*-.25;Z.position.x=4e5*Math.cos(Rt),Z.position.y=4e5*Math.sin(Rt)*Math.sin(ct),Z.position.z=4e5*Math.sin(Rt)*Math.cos(ct),R.material.uniforms.sunPosition.value.copy(Z.position)}function C(){g=window.innerWidth,v=window.innerHeight,O.aspect=g/v,O.updateProjectionMatrix(),b.setSize(g,v)}function U(Z){Z.preventDefault();var ct,Rt;Z.type=="mousemove"?(ct=Z.clientX,Rt=Z.clientY):(ct=Z.changedTouches[0].clientX,Rt=Z.changedTouches[0].clientY),I.x=ct,I.y=Rt}function F(){requestAnimationFrame(F),I.xDamped=K(I.xDamped,I.x,.1),I.yDamped=K(I.yDamped,I.y,.1);var Z=performance.now()*.001;k.material.uniforms.time.value=Z,k.material.uniforms.scroll.value=Z+X(I.yDamped,0,v,0,4),k.material.uniforms.distortCenter.value=Math.sin(Z)*.1,k.material.uniforms.roadWidth.value=X(I.xDamped,0,g,1,4.5),O.position.y=X(I.yDamped,0,v,4,11),b.render(S,O)}function X(Z,ct,Rt,tt,_t){return tt+(_t-tt)*((Z-ct)/(Rt-ct))}function K(Z,ct,Rt){return(1-Rt)*Z+Rt*ct}},o=()=>{const f=document.querySelector(".overlay"),u=document.querySelector(".content__title");charming(u);const m=Array.from(u.querySelectorAll("span"));TweenMax.to(f,2,{ease:Quad.easeOut,opacity:0}),TweenMax.set(m,{opacity:0}),TweenMax.staggerTo(m,1.5,{ease:Expo.easeOut,startAt:{rotationX:-100,z:-1e3},opacity:1,rotationX:0,z:0},.1)},c=()=>{a(),o()};return oi.onMounted(()=>{c()}),(f,u)=>(oi.openBlock(),oi.createElementBlock("div",tm,[oi.createElementVNode("div",em,[im,oi.createElementVNode("h2",nm,[oi.renderSlot(f.$slots,"default")])]),rm]))}}),P1="";(function(x,a){typeof Pi=="object"&&typeof module<"u"?a(Pi):typeof define=="function"&&define.amd?define(["exports"],a):a(x.THREE={})})(window,function(x){function a(){}function o(t,e){this.x=t||0,this.y=e||0}function c(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],0<arguments.length}function f(t,e,i,n){this._x=t||0,this._y=e||0,this._z=i||0,this._w=n!==void 0?n:1}function u(t,e,i){this.x=t||0,this.y=e||0,this.z=i||0}function m(){this.elements=[1,0,0,0,1,0,0,0,1],0<arguments.length}function g(t,e,i,n,s,l,d,p,_,T){Object.defineProperty(this,"id",{value:Us++}),this.uuid=di.generateUUID(),this.name="",this.image=t!==void 0?t:g.DEFAULT_IMAGE,this.mipmaps=[],this.mapping=e!==void 0?e:g.DEFAULT_MAPPING,this.wrapS=i!==void 0?i:1001,this.wrapT=n!==void 0?n:1001,this.magFilter=s!==void 0?s:1006,this.minFilter=l!==void 0?l:1008,this.anisotropy=_!==void 0?_:1,this.format=d!==void 0?d:1023,this.type=p!==void 0?p:1009,this.offset=new o(0,0),this.repeat=new o(1,1),this.center=new o(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new m,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=T!==void 0?T:3e3,this.version=0,this.onUpdate=null}function v(t,e,i,n){this.x=t||0,this.y=e||0,this.z=i||0,this.w=n!==void 0?n:1}function S(t,e,i){this.width=t,this.height=e,this.scissor=new v(0,0,t,e),this.scissorTest=!1,this.viewport=new v(0,0,t,e),i=i||{},i.minFilter===void 0&&(i.minFilter=1006),this.texture=new g(void 0,void 0,i.wrapS,i.wrapT,i.magFilter,i.minFilter,i.format,i.type,i.anisotropy,i.encoding),this.texture.generateMipmaps=i.generateMipmaps!==void 0?i.generateMipmaps:!0,this.depthBuffer=i.depthBuffer!==void 0?i.depthBuffer:!0,this.stencilBuffer=i.stencilBuffer!==void 0?i.stencilBuffer:!0,this.depthTexture=i.depthTexture!==void 0?i.depthTexture:null}function b(t,e,i){S.call(this,t,e,i),this.activeMipMapLevel=this.activeCubeFace=0}function O(t,e,i,n,s,l,d,p,_,T,A,L){g.call(this,null,l,d,p,_,T,n,s,A,L),this.image={data:t,width:e,height:i},this.magFilter=_!==void 0?_:1003,this.minFilter=T!==void 0?T:1003,this.flipY=this.generateMipmaps=!1,this.unpackAlignment=1}function k(t,e){this.min=t!==void 0?t:new u(1/0,1/0,1/0),this.max=e!==void 0?e:new u(-1/0,-1/0,-1/0)}function I(t,e){this.center=t!==void 0?t:new u,this.radius=e!==void 0?e:0}function N(t,e){this.normal=t!==void 0?t:new u(1,0,0),this.constant=e!==void 0?e:0}function E(t,e,i,n,s,l){this.planes=[t!==void 0?t:new N,e!==void 0?e:new N,i!==void 0?i:new N,n!==void 0?n:new N,s!==void 0?s:new N,l!==void 0?l:new N]}function P(t,e,i){return e===void 0&&i===void 0?this.set(t):this.setRGB(t,e,i)}function w(){function t(s,l){i!==!1&&(n(s,l),e.requestAnimationFrame(t))}var e=null,i=!1,n=null;return{start:function(){i!==!0&&n!==null&&(e.requestAnimationFrame(t),i=!0)},stop:function(){i=!1},setAnimationLoop:function(s){n=s},setContext:function(s){e=s}}}function M(t){function e(n,s){var l=n.array,d=n.dynamic?35048:35044,p=t.createBuffer();return t.bindBuffer(s,p),t.bufferData(s,l,d),n.onUploadCallback(),s=5126,l instanceof Float32Array?s=5126:l instanceof Float64Array||(l instanceof Uint16Array?s=5123:l instanceof Int16Array?s=5122:l instanceof Uint32Array?s=5125:l instanceof Int32Array?s=5124:l instanceof Int8Array?s=5120:l instanceof Uint8Array&&(s=5121)),{buffer:p,type:s,bytesPerElement:l.BYTES_PER_ELEMENT,version:n.version}}var i=new WeakMap;return{get:function(n){return n.isInterleavedBufferAttribute&&(n=n.data),i.get(n)},remove:function(n){n.isInterleavedBufferAttribute&&(n=n.data);var s=i.get(n);s&&(t.deleteBuffer(s.buffer),i.delete(n))},update:function(n,s){n.isInterleavedBufferAttribute&&(n=n.data);var l=i.get(n);if(l===void 0)i.set(n,e(n,s));else if(l.version<n.version){var d=n,p=d.array,_=d.updateRange;t.bindBuffer(s,l.buffer),d.dynamic===!1?t.bufferData(s,p,35044):_.count===-1?t.bufferSubData(s,0,p):_.count===0||(t.bufferSubData(s,_.offset*p.BYTES_PER_ELEMENT,p.subarray(_.offset,_.offset+_.count)),_.count=-1),l.version=n.version}}}}function R(t,e,i,n,s,l){this.a=t,this.b=e,this.c=i,this.normal=n&&n.isVector3?n:new u,this.vertexNormals=Array.isArray(n)?n:[],this.color=s&&s.isColor?s:new P,this.vertexColors=Array.isArray(s)?s:[],this.materialIndex=l!==void 0?l:0}function C(t,e,i,n){this._x=t||0,this._y=e||0,this._z=i||0,this._order=n||C.DefaultOrder}function U(){this.mask=1}function F(){Object.defineProperty(this,"id",{value:qc++}),this.uuid=di.generateUUID(),this.name="",this.type="Object3D",this.parent=null,this.children=[],this.up=F.DefaultUp.clone();var t=new u,e=new C,i=new f,n=new u(1,1,1);e.onChange(function(){i.setFromEuler(e,!1)}),i.onChange(function(){e.setFromQuaternion(i,void 0,!1)}),Object.defineProperties(this,{position:{configurable:!0,enumerable:!0,value:t},rotation:{configurable:!0,enumerable:!0,value:e},quaternion:{configurable:!0,enumerable:!0,value:i},scale:{configurable:!0,enumerable:!0,value:n},modelViewMatrix:{value:new c},normalMatrix:{value:new m}}),this.matrix=new c,this.matrixWorld=new c,this.matrixAutoUpdate=F.DefaultMatrixAutoUpdate,this.matrixWorldNeedsUpdate=!1,this.layers=new U,this.visible=!0,this.receiveShadow=this.castShadow=!1,this.frustumCulled=!0,this.renderOrder=0,this.userData={}}function X(){Object.defineProperty(this,"id",{value:Yc+=2}),this.uuid=di.generateUUID(),this.name="",this.type="Geometry",this.vertices=[],this.colors=[],this.faces=[],this.faceVertexUvs=[[]],this.morphTargets=[],this.morphNormals=[],this.skinWeights=[],this.skinIndices=[],this.lineDistances=[],this.boundingSphere=this.boundingBox=null,this.groupsNeedUpdate=this.lineDistancesNeedUpdate=this.colorsNeedUpdate=this.normalsNeedUpdate=this.uvsNeedUpdate=this.verticesNeedUpdate=this.elementsNeedUpdate=!1}function K(t,e,i){if(Array.isArray(t))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");this.name="",this.array=t,this.itemSize=e,this.count=t!==void 0?t.length/e:0,this.normalized=i===!0,this.dynamic=!1,this.updateRange={offset:0,count:-1},this.version=0}function Z(t,e,i){K.call(this,new Int8Array(t),e,i)}function ct(t,e,i){K.call(this,new Uint8Array(t),e,i)}function Rt(t,e,i){K.call(this,new Uint8ClampedArray(t),e,i)}function tt(t,e,i){K.call(this,new Int16Array(t),e,i)}function _t(t,e,i){K.call(this,new Uint16Array(t),e,i)}function G(t,e,i){K.call(this,new Int32Array(t),e,i)}function Pt(t,e,i){K.call(this,new Uint32Array(t),e,i)}function Et(t,e,i){K.call(this,new Float32Array(t),e,i)}function At(t,e,i){K.call(this,new Float64Array(t),e,i)}function ce(){this.vertices=[],this.normals=[],this.colors=[],this.uvs=[],this.uvs2=[],this.groups=[],this.morphTargets={},this.skinWeights=[],this.skinIndices=[],this.boundingSphere=this.boundingBox=null,this.groupsNeedUpdate=this.uvsNeedUpdate=this.colorsNeedUpdate=this.normalsNeedUpdate=this.verticesNeedUpdate=!1}function re(t){if(t.length===0)return-1/0;for(var e=t[0],i=1,n=t.length;i<n;++i)t[i]>e&&(e=t[i]);return e}function Ft(){Object.defineProperty(this,"id",{value:Zc+=2}),this.uuid=di.generateUUID(),this.name="",this.type="BufferGeometry",this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingSphere=this.boundingBox=null,this.drawRange={start:0,count:1/0},this.userData={}}function It(t,e,i,n,s,l){X.call(this),this.type="BoxGeometry",this.parameters={width:t,height:e,depth:i,widthSegments:n,heightSegments:s,depthSegments:l},this.fromBufferGeometry(new Nt(t,e,i,n,s,l)),this.mergeVertices()}function Nt(t,e,i,n,s,l){function d(q,J,rt,xt,gt,Ct,wt,Vt,$,ot,kt){var ee=Ct/$,$t=wt/ot,Yt=Ct/2,Te=wt/2,ge=Vt/2;wt=$+1;var De=ot+1,be=Ct=0,ae,We,Qe=new u;for(We=0;We<De;We++){var fi=We*$t-Te;for(ae=0;ae<wt;ae++)Qe[q]=(ae*ee-Yt)*xt,Qe[J]=fi*gt,Qe[rt]=ge,T.push(Qe.x,Qe.y,Qe.z),Qe[q]=0,Qe[J]=0,Qe[rt]=0<Vt?1:-1,A.push(Qe.x,Qe.y,Qe.z),L.push(ae/$),L.push(1-We/ot),Ct+=1}for(We=0;We<ot;We++)for(ae=0;ae<$;ae++)q=B+ae+wt*(We+1),J=B+(ae+1)+wt*(We+1),rt=B+(ae+1)+wt*We,_.push(B+ae+wt*We,q,rt),_.push(q,J,rt),be+=6;p.addGroup(H,be,kt),H+=be,B+=Ct}Ft.call(this),this.type="BoxBufferGeometry",this.parameters={width:t,height:e,depth:i,widthSegments:n,heightSegments:s,depthSegments:l};var p=this;t=t||1,e=e||1,i=i||1,n=Math.floor(n)||1,s=Math.floor(s)||1,l=Math.floor(l)||1;var _=[],T=[],A=[],L=[],B=0,H=0;d("z","y","x",-1,-1,i,e,t,l,s,0),d("z","y","x",1,-1,i,e,-t,l,s,1),d("x","z","y",1,1,t,i,e,n,l,2),d("x","z","y",1,-1,t,i,-e,n,l,3),d("x","y","z",1,-1,t,e,i,n,s,4),d("x","y","z",-1,-1,t,e,-i,n,s,5),this.setIndex(_),this.addAttribute("position",new Et(T,3)),this.addAttribute("normal",new Et(A,3)),this.addAttribute("uv",new Et(L,2))}function Pe(t,e,i,n){X.call(this),this.type="PlaneGeometry",this.parameters={width:t,height:e,widthSegments:i,heightSegments:n},this.fromBufferGeometry(new pe(t,e,i,n)),this.mergeVertices()}function pe(t,e,i,n){Ft.call(this),this.type="PlaneBufferGeometry",this.parameters={width:t,height:e,widthSegments:i,heightSegments:n},t=t||1,e=e||1;var s=t/2,l=e/2;i=Math.floor(i)||1,n=Math.floor(n)||1;var d=i+1,p=n+1,_=t/i,T=e/n,A=[],L=[],B=[],H=[];for(t=0;t<p;t++){var q=t*T-l;for(e=0;e<d;e++)L.push(e*_-s,-q,0),B.push(0,0,1),H.push(e/i),H.push(1-t/n)}for(t=0;t<n;t++)for(e=0;e<i;e++)s=e+d*(t+1),l=e+1+d*(t+1),p=e+1+d*t,A.push(e+d*t,s,p),A.push(s,l,p);this.setIndex(A),this.addAttribute("position",new Et(L,3)),this.addAttribute("normal",new Et(B,3)),this.addAttribute("uv",new Et(H,2))}function Wt(){Object.defineProperty(this,"id",{value:zu++}),this.uuid=di.generateUUID(),this.name="",this.type="Material",this.lights=this.fog=!0,this.blending=1,this.side=0,this.flatShading=!1,this.vertexColors=0,this.opacity=1,this.transparent=!1,this.blendSrc=204,this.blendDst=205,this.blendEquation=100,this.blendEquationAlpha=this.blendDstAlpha=this.blendSrcAlpha=null,this.depthFunc=3,this.depthWrite=this.depthTest=!0,this.clippingPlanes=null,this.clipShadows=this.clipIntersection=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetUnits=this.polygonOffsetFactor=0,this.dithering=!1,this.alphaTest=0,this.premultipliedAlpha=!1,this.visible=!0,this.userData={},this.needsUpdate=!0}function $e(t){Wt.call(this),this.type="ShaderMaterial",this.defines={},this.uniforms={},this.vertexShader=`void main() {
|
|
251
|
+
}`;var m=document.querySelector(".landscape"),g=window.innerWidth,v=window.innerHeight,S,b,O,k,I={x:0,y:0,xDamped:0,yDamped:0},F=typeof window.orientation<"u";E();function E(){P(),w(),M(),N(),F?window.addEventListener("touchmove",U,{passive:!1}):window.addEventListener("mousemove",U),window.addEventListener("resize",C),C()}function P(){S=new THREE.Scene;var Z=new THREE.Color(3355443);S.background=Z,S.fog=new THREE.Fog(Z,0,400),R(),O=new THREE.PerspectiveCamera(60,g/v,.1,1e4),O.position.y=8,O.position.z=4;let ct=new THREE.AmbientLight(16777215,1);S.add(ct),b=new THREE.WebGLRenderer({canvas:m,antialias:!0}),b.setPixelRatio=devicePixelRatio,b.setSize(g,v)}function w(){var Z=new THREE.PlaneBufferGeometry(100,400,400,400),ct={time:{type:"f",value:0},scroll:{type:"f",value:0},distortCenter:{type:"f",value:.1},roadWidth:{type:"f",value:.5},pallete:{type:"t",value:null},speed:{type:"f",value:3},maxHeight:{type:"f",value:10},color:new THREE.Color(1,1,1)},Rt=new THREE.ShaderMaterial({uniforms:THREE.UniformsUtils.merge([THREE.ShaderLib.basic.uniforms,ct]),vertexShader:f,fragmentShader:u,wireframe:!1,fog:!0});k=new THREE.Mesh(Z,Rt),k.position.z=-180,k.rotation.x=-Math.PI/2,S.add(k)}function M(){new THREE.TextureLoader().load("",function(Z){k.material.uniforms.pallete.value=Z,k.material.needsUpdate=!0})}function R(){R=new THREE.Sky,R.scale.setScalar(45e4),R.material.uniforms.turbidity.value=13,R.material.uniforms.rayleigh.value=1.2,R.material.uniforms.luminance.value=1,R.material.uniforms.mieCoefficient.value=.1,R.material.uniforms.mieDirectionalG.value=.58,S.add(R);let Z=new THREE.Mesh(new THREE.SphereBufferGeometry(2e4,16,8),new THREE.MeshBasicMaterial({color:16777215}));Z.visible=!1,S.add(Z);var ct=Math.PI*-.002,Rt=2*Math.PI*-.25;Z.position.x=4e5*Math.cos(Rt),Z.position.y=4e5*Math.sin(Rt)*Math.sin(ct),Z.position.z=4e5*Math.sin(Rt)*Math.cos(ct),R.material.uniforms.sunPosition.value.copy(Z.position)}function C(){g=window.innerWidth,v=window.innerHeight,O.aspect=g/v,O.updateProjectionMatrix(),b.setSize(g,v)}function U(Z){Z.preventDefault();var ct,Rt;Z.type=="mousemove"?(ct=Z.clientX,Rt=Z.clientY):(ct=Z.changedTouches[0].clientX,Rt=Z.changedTouches[0].clientY),I.x=ct,I.y=Rt}function N(){requestAnimationFrame(N),I.xDamped=J(I.xDamped,I.x,.1),I.yDamped=J(I.yDamped,I.y,.1);var Z=performance.now()*.001;k.material.uniforms.time.value=Z,k.material.uniforms.scroll.value=Z+X(I.yDamped,0,v,0,4),k.material.uniforms.distortCenter.value=Math.sin(Z)*.1,k.material.uniforms.roadWidth.value=X(I.xDamped,0,g,1,4.5),O.position.y=X(I.yDamped,0,v,4,11),b.render(S,O)}function X(Z,ct,Rt,tt,_t){return tt+(_t-tt)*((Z-ct)/(Rt-ct))}function J(Z,ct,Rt){return(1-Rt)*Z+Rt*ct}},o=()=>{const f=document.querySelector(".overlay"),u=document.querySelector(".content__title");charming(u);const m=Array.from(u.querySelectorAll("span"));TweenMax.to(f,2,{ease:Quad.easeOut,opacity:0}),TweenMax.set(m,{opacity:0}),TweenMax.staggerTo(m,1.5,{ease:Expo.easeOut,startAt:{rotationX:-100,z:-1e3},opacity:1,rotationX:0,z:0},.1)},c=()=>{a(),o()};return oi.onMounted(()=>{c()}),(f,u)=>(oi.openBlock(),oi.createElementBlock("div",tm,[oi.createElementVNode("div",em,[im,oi.createElementVNode("h2",nm,[oi.renderSlot(f.$slots,"default")])]),rm]))}}),P1="";(function(x,a){typeof Pi=="object"&&typeof module<"u"?a(Pi):typeof define=="function"&&define.amd?define(["exports"],a):a(x.THREE={})})(window,function(x){function a(){}function o(t,e){this.x=t||0,this.y=e||0}function c(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],0<arguments.length}function f(t,e,i,n){this._x=t||0,this._y=e||0,this._z=i||0,this._w=n!==void 0?n:1}function u(t,e,i){this.x=t||0,this.y=e||0,this.z=i||0}function m(){this.elements=[1,0,0,0,1,0,0,0,1],0<arguments.length}function g(t,e,i,n,s,l,d,p,_,T){Object.defineProperty(this,"id",{value:Us++}),this.uuid=di.generateUUID(),this.name="",this.image=t!==void 0?t:g.DEFAULT_IMAGE,this.mipmaps=[],this.mapping=e!==void 0?e:g.DEFAULT_MAPPING,this.wrapS=i!==void 0?i:1001,this.wrapT=n!==void 0?n:1001,this.magFilter=s!==void 0?s:1006,this.minFilter=l!==void 0?l:1008,this.anisotropy=_!==void 0?_:1,this.format=d!==void 0?d:1023,this.type=p!==void 0?p:1009,this.offset=new o(0,0),this.repeat=new o(1,1),this.center=new o(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new m,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=T!==void 0?T:3e3,this.version=0,this.onUpdate=null}function v(t,e,i,n){this.x=t||0,this.y=e||0,this.z=i||0,this.w=n!==void 0?n:1}function S(t,e,i){this.width=t,this.height=e,this.scissor=new v(0,0,t,e),this.scissorTest=!1,this.viewport=new v(0,0,t,e),i=i||{},i.minFilter===void 0&&(i.minFilter=1006),this.texture=new g(void 0,void 0,i.wrapS,i.wrapT,i.magFilter,i.minFilter,i.format,i.type,i.anisotropy,i.encoding),this.texture.generateMipmaps=i.generateMipmaps!==void 0?i.generateMipmaps:!0,this.depthBuffer=i.depthBuffer!==void 0?i.depthBuffer:!0,this.stencilBuffer=i.stencilBuffer!==void 0?i.stencilBuffer:!0,this.depthTexture=i.depthTexture!==void 0?i.depthTexture:null}function b(t,e,i){S.call(this,t,e,i),this.activeMipMapLevel=this.activeCubeFace=0}function O(t,e,i,n,s,l,d,p,_,T,A,L){g.call(this,null,l,d,p,_,T,n,s,A,L),this.image={data:t,width:e,height:i},this.magFilter=_!==void 0?_:1003,this.minFilter=T!==void 0?T:1003,this.flipY=this.generateMipmaps=!1,this.unpackAlignment=1}function k(t,e){this.min=t!==void 0?t:new u(1/0,1/0,1/0),this.max=e!==void 0?e:new u(-1/0,-1/0,-1/0)}function I(t,e){this.center=t!==void 0?t:new u,this.radius=e!==void 0?e:0}function F(t,e){this.normal=t!==void 0?t:new u(1,0,0),this.constant=e!==void 0?e:0}function E(t,e,i,n,s,l){this.planes=[t!==void 0?t:new F,e!==void 0?e:new F,i!==void 0?i:new F,n!==void 0?n:new F,s!==void 0?s:new F,l!==void 0?l:new F]}function P(t,e,i){return e===void 0&&i===void 0?this.set(t):this.setRGB(t,e,i)}function w(){function t(s,l){i!==!1&&(n(s,l),e.requestAnimationFrame(t))}var e=null,i=!1,n=null;return{start:function(){i!==!0&&n!==null&&(e.requestAnimationFrame(t),i=!0)},stop:function(){i=!1},setAnimationLoop:function(s){n=s},setContext:function(s){e=s}}}function M(t){function e(n,s){var l=n.array,d=n.dynamic?35048:35044,p=t.createBuffer();return t.bindBuffer(s,p),t.bufferData(s,l,d),n.onUploadCallback(),s=5126,l instanceof Float32Array?s=5126:l instanceof Float64Array||(l instanceof Uint16Array?s=5123:l instanceof Int16Array?s=5122:l instanceof Uint32Array?s=5125:l instanceof Int32Array?s=5124:l instanceof Int8Array?s=5120:l instanceof Uint8Array&&(s=5121)),{buffer:p,type:s,bytesPerElement:l.BYTES_PER_ELEMENT,version:n.version}}var i=new WeakMap;return{get:function(n){return n.isInterleavedBufferAttribute&&(n=n.data),i.get(n)},remove:function(n){n.isInterleavedBufferAttribute&&(n=n.data);var s=i.get(n);s&&(t.deleteBuffer(s.buffer),i.delete(n))},update:function(n,s){n.isInterleavedBufferAttribute&&(n=n.data);var l=i.get(n);if(l===void 0)i.set(n,e(n,s));else if(l.version<n.version){var d=n,p=d.array,_=d.updateRange;t.bindBuffer(s,l.buffer),d.dynamic===!1?t.bufferData(s,p,35044):_.count===-1?t.bufferSubData(s,0,p):_.count===0||(t.bufferSubData(s,_.offset*p.BYTES_PER_ELEMENT,p.subarray(_.offset,_.offset+_.count)),_.count=-1),l.version=n.version}}}}function R(t,e,i,n,s,l){this.a=t,this.b=e,this.c=i,this.normal=n&&n.isVector3?n:new u,this.vertexNormals=Array.isArray(n)?n:[],this.color=s&&s.isColor?s:new P,this.vertexColors=Array.isArray(s)?s:[],this.materialIndex=l!==void 0?l:0}function C(t,e,i,n){this._x=t||0,this._y=e||0,this._z=i||0,this._order=n||C.DefaultOrder}function U(){this.mask=1}function N(){Object.defineProperty(this,"id",{value:qc++}),this.uuid=di.generateUUID(),this.name="",this.type="Object3D",this.parent=null,this.children=[],this.up=N.DefaultUp.clone();var t=new u,e=new C,i=new f,n=new u(1,1,1);e.onChange(function(){i.setFromEuler(e,!1)}),i.onChange(function(){e.setFromQuaternion(i,void 0,!1)}),Object.defineProperties(this,{position:{configurable:!0,enumerable:!0,value:t},rotation:{configurable:!0,enumerable:!0,value:e},quaternion:{configurable:!0,enumerable:!0,value:i},scale:{configurable:!0,enumerable:!0,value:n},modelViewMatrix:{value:new c},normalMatrix:{value:new m}}),this.matrix=new c,this.matrixWorld=new c,this.matrixAutoUpdate=N.DefaultMatrixAutoUpdate,this.matrixWorldNeedsUpdate=!1,this.layers=new U,this.visible=!0,this.receiveShadow=this.castShadow=!1,this.frustumCulled=!0,this.renderOrder=0,this.userData={}}function X(){Object.defineProperty(this,"id",{value:Yc+=2}),this.uuid=di.generateUUID(),this.name="",this.type="Geometry",this.vertices=[],this.colors=[],this.faces=[],this.faceVertexUvs=[[]],this.morphTargets=[],this.morphNormals=[],this.skinWeights=[],this.skinIndices=[],this.lineDistances=[],this.boundingSphere=this.boundingBox=null,this.groupsNeedUpdate=this.lineDistancesNeedUpdate=this.colorsNeedUpdate=this.normalsNeedUpdate=this.uvsNeedUpdate=this.verticesNeedUpdate=this.elementsNeedUpdate=!1}function J(t,e,i){if(Array.isArray(t))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");this.name="",this.array=t,this.itemSize=e,this.count=t!==void 0?t.length/e:0,this.normalized=i===!0,this.dynamic=!1,this.updateRange={offset:0,count:-1},this.version=0}function Z(t,e,i){J.call(this,new Int8Array(t),e,i)}function ct(t,e,i){J.call(this,new Uint8Array(t),e,i)}function Rt(t,e,i){J.call(this,new Uint8ClampedArray(t),e,i)}function tt(t,e,i){J.call(this,new Int16Array(t),e,i)}function _t(t,e,i){J.call(this,new Uint16Array(t),e,i)}function G(t,e,i){J.call(this,new Int32Array(t),e,i)}function Pt(t,e,i){J.call(this,new Uint32Array(t),e,i)}function Et(t,e,i){J.call(this,new Float32Array(t),e,i)}function At(t,e,i){J.call(this,new Float64Array(t),e,i)}function ce(){this.vertices=[],this.normals=[],this.colors=[],this.uvs=[],this.uvs2=[],this.groups=[],this.morphTargets={},this.skinWeights=[],this.skinIndices=[],this.boundingSphere=this.boundingBox=null,this.groupsNeedUpdate=this.uvsNeedUpdate=this.colorsNeedUpdate=this.normalsNeedUpdate=this.verticesNeedUpdate=!1}function re(t){if(t.length===0)return-1/0;for(var e=t[0],i=1,n=t.length;i<n;++i)t[i]>e&&(e=t[i]);return e}function Ft(){Object.defineProperty(this,"id",{value:Zc+=2}),this.uuid=di.generateUUID(),this.name="",this.type="BufferGeometry",this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingSphere=this.boundingBox=null,this.drawRange={start:0,count:1/0},this.userData={}}function It(t,e,i,n,s,l){X.call(this),this.type="BoxGeometry",this.parameters={width:t,height:e,depth:i,widthSegments:n,heightSegments:s,depthSegments:l},this.fromBufferGeometry(new Nt(t,e,i,n,s,l)),this.mergeVertices()}function Nt(t,e,i,n,s,l){function d(q,$,rt,xt,gt,Ct,wt,Vt,K,ot,kt){var ee=Ct/K,$t=wt/ot,Yt=Ct/2,Te=wt/2,ge=Vt/2;wt=K+1;var De=ot+1,be=Ct=0,ae,We,Qe=new u;for(We=0;We<De;We++){var fi=We*$t-Te;for(ae=0;ae<wt;ae++)Qe[q]=(ae*ee-Yt)*xt,Qe[$]=fi*gt,Qe[rt]=ge,T.push(Qe.x,Qe.y,Qe.z),Qe[q]=0,Qe[$]=0,Qe[rt]=0<Vt?1:-1,A.push(Qe.x,Qe.y,Qe.z),L.push(ae/K),L.push(1-We/ot),Ct+=1}for(We=0;We<ot;We++)for(ae=0;ae<K;ae++)q=B+ae+wt*(We+1),$=B+(ae+1)+wt*(We+1),rt=B+(ae+1)+wt*We,_.push(B+ae+wt*We,q,rt),_.push(q,$,rt),be+=6;p.addGroup(H,be,kt),H+=be,B+=Ct}Ft.call(this),this.type="BoxBufferGeometry",this.parameters={width:t,height:e,depth:i,widthSegments:n,heightSegments:s,depthSegments:l};var p=this;t=t||1,e=e||1,i=i||1,n=Math.floor(n)||1,s=Math.floor(s)||1,l=Math.floor(l)||1;var _=[],T=[],A=[],L=[],B=0,H=0;d("z","y","x",-1,-1,i,e,t,l,s,0),d("z","y","x",1,-1,i,e,-t,l,s,1),d("x","z","y",1,1,t,i,e,n,l,2),d("x","z","y",1,-1,t,i,-e,n,l,3),d("x","y","z",1,-1,t,e,i,n,s,4),d("x","y","z",-1,-1,t,e,-i,n,s,5),this.setIndex(_),this.addAttribute("position",new Et(T,3)),this.addAttribute("normal",new Et(A,3)),this.addAttribute("uv",new Et(L,2))}function Pe(t,e,i,n){X.call(this),this.type="PlaneGeometry",this.parameters={width:t,height:e,widthSegments:i,heightSegments:n},this.fromBufferGeometry(new pe(t,e,i,n)),this.mergeVertices()}function pe(t,e,i,n){Ft.call(this),this.type="PlaneBufferGeometry",this.parameters={width:t,height:e,widthSegments:i,heightSegments:n},t=t||1,e=e||1;var s=t/2,l=e/2;i=Math.floor(i)||1,n=Math.floor(n)||1;var d=i+1,p=n+1,_=t/i,T=e/n,A=[],L=[],B=[],H=[];for(t=0;t<p;t++){var q=t*T-l;for(e=0;e<d;e++)L.push(e*_-s,-q,0),B.push(0,0,1),H.push(e/i),H.push(1-t/n)}for(t=0;t<n;t++)for(e=0;e<i;e++)s=e+d*(t+1),l=e+1+d*(t+1),p=e+1+d*t,A.push(e+d*t,s,p),A.push(s,l,p);this.setIndex(A),this.addAttribute("position",new Et(L,3)),this.addAttribute("normal",new Et(B,3)),this.addAttribute("uv",new Et(H,2))}function Wt(){Object.defineProperty(this,"id",{value:zu++}),this.uuid=di.generateUUID(),this.name="",this.type="Material",this.lights=this.fog=!0,this.blending=1,this.side=0,this.flatShading=!1,this.vertexColors=0,this.opacity=1,this.transparent=!1,this.blendSrc=204,this.blendDst=205,this.blendEquation=100,this.blendEquationAlpha=this.blendDstAlpha=this.blendSrcAlpha=null,this.depthFunc=3,this.depthWrite=this.depthTest=!0,this.clippingPlanes=null,this.clipShadows=this.clipIntersection=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetUnits=this.polygonOffsetFactor=0,this.dithering=!1,this.alphaTest=0,this.premultipliedAlpha=!1,this.visible=!0,this.userData={},this.needsUpdate=!0}function $e(t){Wt.call(this),this.type="ShaderMaterial",this.defines={},this.uniforms={},this.vertexShader=`void main() {
|
|
252
252
|
gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );
|
|
253
253
|
}`,this.fragmentShader=`void main() {
|
|
254
254
|
gl_FragColor = vec4( 1.0, 0.0, 0.0, 1.0 );
|
|
255
|
-
}`,this.linewidth=1,this.wireframe=!1,this.wireframeLinewidth=1,this.morphNormals=this.morphTargets=this.skinning=this.clipping=this.lights=this.fog=!1,this.extensions={derivatives:!1,fragDepth:!1,drawBuffers:!1,shaderTextureLOD:!1},this.defaultAttributeValues={color:[1,1,1],uv:[0,0],uv2:[0,0]},this.index0AttributeName=void 0,this.uniformsNeedUpdate=!1,t!==void 0&&(t.attributes,this.setValues(t))}function Si(t,e){this.origin=t!==void 0?t:new u,this.direction=e!==void 0?e:new u}function Oe(t,e,i){this.a=t!==void 0?t:new u,this.b=e!==void 0?e:new u,this.c=i!==void 0?i:new u}function Ge(t){Wt.call(this),this.type="MeshBasicMaterial",this.color=new P(16777215),this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.envMap=this.alphaMap=this.specularMap=null,this.combine=0,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.lights=this.morphTargets=this.skinning=!1,this.setValues(t)}function pi(t,e){F.call(this),this.type="Mesh",this.geometry=t!==void 0?t:new Ft,this.material=e!==void 0?e:new Ge({color:16777215*Math.random()}),this.drawMode=0,this.updateMorphTargets()}function Di(t,e,i,n){function s(T,A){e.buffers.color.setClear(T.r,T.g,T.b,A,n)}var l=new P(0),d=0,p,_;return{getClearColor:function(){return l},setClearColor:function(T,A){l.set(T),d=A!==void 0?A:1,s(l,d)},getClearAlpha:function(){return d},setClearAlpha:function(T){d=T,s(l,d)},render:function(T,A,L,B){A=A.background,A===null?s(l,d):A&&A.isColor&&(s(A,1),B=!0),(t.autoClear||B)&&t.clear(t.autoClearColor,t.autoClearDepth,t.autoClearStencil),A&&(A.isCubeTexture||A.isWebGLRenderTargetCube)?(_===void 0&&(_=new pi(new Nt(1,1,1),new $e({type:"BackgroundCubeMaterial",uniforms:Bn.clone(wo.cube.uniforms),vertexShader:wo.cube.vertexShader,fragmentShader:wo.cube.fragmentShader,side:1,depthTest:!0,depthWrite:!1,fog:!1})),_.geometry.removeAttribute("normal"),_.geometry.removeAttribute("uv"),_.onBeforeRender=function(H,q,J){this.matrixWorld.copyPosition(J.matrixWorld)},i.update(_)),_.material.uniforms.tCube.value=A.isWebGLRenderTargetCube?A.texture:A,_.material.uniforms.tFlip.value=A.isWebGLRenderTargetCube?1:-1,T.push(_,_.geometry,_.material,0,null)):A&&A.isTexture&&(p===void 0&&(p=new pi(new pe(2,2),new $e({type:"BackgroundMaterial",uniforms:Bn.clone(wo.background.uniforms),vertexShader:wo.background.vertexShader,fragmentShader:wo.background.fragmentShader,side:0,depthTest:!0,depthWrite:!1,fog:!1})),p.geometry.removeAttribute("normal"),i.update(p)),p.material.uniforms.t2D.value=A,A.matrixAutoUpdate===!0&&A.updateMatrix(),p.material.uniforms.uvTransform.value.copy(A.matrix),T.push(p,p.geometry,p.material,0,null))}}}function mn(t,e,i,n){var s;this.setMode=function(l){s=l},this.render=function(l,d){t.drawArrays(s,l,d),i.update(d,s)},this.renderInstances=function(l,d,p){if(n.isWebGL2)var _=t;else if(_=e.get("ANGLE_instanced_arrays"),_===null)return;_[n.isWebGL2?"drawArraysInstanced":"drawArraysInstancedANGLE"](s,d,p,l.maxInstancedCount),i.update(p,s,l.maxInstancedCount)}}function Qi(t,e,i){function n(xt){if(xt==="highp"){if(0<t.getShaderPrecisionFormat(35633,36338).precision&&0<t.getShaderPrecisionFormat(35632,36338).precision)return"highp";xt="mediump"}return xt==="mediump"&&0<t.getShaderPrecisionFormat(35633,36337).precision&&0<t.getShaderPrecisionFormat(35632,36337).precision?"mediump":"lowp"}var s,l=typeof WebGL2RenderingContext<"u"&&t instanceof WebGL2RenderingContext,d=i.precision!==void 0?i.precision:"highp",p=n(d);p!==d&&(d=p),i=i.logarithmicDepthBuffer===!0,p=t.getParameter(34930);var _=t.getParameter(35660),T=t.getParameter(3379),A=t.getParameter(34076),L=t.getParameter(34921),B=t.getParameter(36347),H=t.getParameter(36348),q=t.getParameter(36349),J=0<_,rt=l||!!e.get("OES_texture_float");return{isWebGL2:l,getMaxAnisotropy:function(){if(s!==void 0)return s;var xt=e.get("EXT_texture_filter_anisotropic");return s=xt!==null?t.getParameter(xt.MAX_TEXTURE_MAX_ANISOTROPY_EXT):0},getMaxPrecision:n,precision:d,logarithmicDepthBuffer:i,maxTextures:p,maxVertexTextures:_,maxTextureSize:T,maxCubemapSize:A,maxAttributes:L,maxVertexUniforms:B,maxVaryings:H,maxFragmentUniforms:q,vertexTextures:J,floatFragmentTextures:rt,floatVertexTextures:J&&rt}}function W(){function t(){T.value!==n&&(T.value=n,T.needsUpdate=0<s),i.numPlanes=s,i.numIntersection=0}function e(A,L,B,H){var q=A!==null?A.length:0,J=null;if(q!==0){if(J=T.value,H!==!0||J===null)for(H=B+4*q,L=L.matrixWorldInverse,_.getNormalMatrix(L),(J===null||J.length<H)&&(J=new Float32Array(H)),H=0;H!==q;++H,B+=4)p.copy(A[H]).applyMatrix4(L,_),p.normal.toArray(J,B),J[B+3]=p.constant;T.value=J,T.needsUpdate=!0}return i.numPlanes=q,J}var i=this,n=null,s=0,l=!1,d=!1,p=new N,_=new m,T={value:null,needsUpdate:!1};this.uniform=T,this.numIntersection=this.numPlanes=0,this.init=function(A,L,B){var H=A.length!==0||L||s!==0||l;return l=L,n=e(A,B,0),s=A.length,H},this.beginShadows=function(){d=!0,e(null)},this.endShadows=function(){d=!1,t()},this.setState=function(A,L,B,H,q,J){if(!l||A===null||A.length===0||d&&!B)d?e(null):t();else{B=d?0:s;var rt=4*B,xt=q.clippingState||null;for(T.value=xt,xt=e(A,H,rt,J),A=0;A!==rt;++A)xt[A]=n[A];q.clippingState=xt,this.numIntersection=L?this.numPlanes:0,this.numPlanes+=B}}}function Jt(t){var e={};return{get:function(i){if(e[i]!==void 0)return e[i];switch(i){case"WEBGL_depth_texture":var n=t.getExtension("WEBGL_depth_texture")||t.getExtension("MOZ_WEBGL_depth_texture")||t.getExtension("WEBKIT_WEBGL_depth_texture");break;case"EXT_texture_filter_anisotropic":n=t.getExtension("EXT_texture_filter_anisotropic")||t.getExtension("MOZ_EXT_texture_filter_anisotropic")||t.getExtension("WEBKIT_EXT_texture_filter_anisotropic");break;case"WEBGL_compressed_texture_s3tc":n=t.getExtension("WEBGL_compressed_texture_s3tc")||t.getExtension("MOZ_WEBGL_compressed_texture_s3tc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");break;case"WEBGL_compressed_texture_pvrtc":n=t.getExtension("WEBGL_compressed_texture_pvrtc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");break;default:n=t.getExtension(i)}return e[i]=n}}}function jt(t,e,i){function n(d){var p=d.target;d=s[p.id],d.index!==null&&e.remove(d.index);for(var _ in d.attributes)e.remove(d.attributes[_]);p.removeEventListener("dispose",n),delete s[p.id],(_=l[d.id])&&(e.remove(_),delete l[d.id]),i.memory.geometries--}var s={},l={};return{get:function(d,p){var _=s[p.id];return _||(p.addEventListener("dispose",n),p.isBufferGeometry?_=p:p.isGeometry&&(p._bufferGeometry===void 0&&(p._bufferGeometry=new Ft().setFromObject(d)),_=p._bufferGeometry),s[p.id]=_,i.memory.geometries++,_)},update:function(d){var p=d.index,_=d.attributes;p!==null&&e.update(p,34963);for(var T in _)e.update(_[T],34962);d=d.morphAttributes;for(T in d){p=d[T],_=0;for(var A=p.length;_<A;_++)e.update(p[_],34962)}},getWireframeAttribute:function(d){var p=l[d.id];if(p)return p;p=[];var _=d.index,T=d.attributes;if(_!==null){_=_.array,T=0;for(var A=_.length;T<A;T+=3){var L=_[T+0],B=_[T+1],H=_[T+2];p.push(L,B,B,H,H,L)}}else for(_=T.position.array,T=0,A=_.length/3-1;T<A;T+=3)L=T+0,B=T+1,H=T+2,p.push(L,B,B,H,H,L);return p=new(65535<re(p)?Pt:_t)(p,1),e.update(p,34963),l[d.id]=p}}}function dt(t,e,i,n){var s,l,d;this.setMode=function(p){s=p},this.setIndex=function(p){l=p.type,d=p.bytesPerElement},this.render=function(p,_){t.drawElements(s,_,l,p*d),i.update(_,s)},this.renderInstances=function(p,_,T){if(n.isWebGL2)var A=t;else if(A=e.get("ANGLE_instanced_arrays"),A===null)return;A[n.isWebGL2?"drawElementsInstanced":"drawElementsInstancedANGLE"](s,T,l,_*d,p.maxInstancedCount),i.update(T,s,p.maxInstancedCount)}}function pt(t){var e={frame:0,calls:0,triangles:0,points:0,lines:0};return{memory:{geometries:0,textures:0},render:e,programs:null,autoReset:!0,reset:function(){e.frame++,e.calls=0,e.triangles=0,e.points=0,e.lines=0},update:function(i,n,s){switch(s=s||1,e.calls++,n){case 4:e.triangles+=i/3*s;break;case 5:case 6:e.triangles+=s*(i-2);break;case 1:e.lines+=i/2*s;break;case 3:e.lines+=s*(i-1);break;case 2:e.lines+=s*i;break;case 0:e.points+=s*i;break;default:}}}}function Dt(t,e){return Math.abs(e[1])-Math.abs(t[1])}function ie(t){var e={},i=new Float32Array(8);return{update:function(n,s,l,d){var p=n.morphTargetInfluences,_=p.length;if(n=e[s.id],n===void 0){n=[];for(var T=0;T<_;T++)n[T]=[T,0];e[s.id]=n}var A=l.morphTargets&&s.morphAttributes.position;for(l=l.morphNormals&&s.morphAttributes.normal,T=0;T<_;T++){var L=n[T];L[1]!==0&&(A&&s.removeAttribute("morphTarget"+T),l&&s.removeAttribute("morphNormal"+T))}for(T=0;T<_;T++)L=n[T],L[0]=T,L[1]=p[T];for(n.sort(Dt),T=0;8>T;T++){if((L=n[T])&&(p=L[0],_=L[1])){A&&s.addAttribute("morphTarget"+T,A[p]),l&&s.addAttribute("morphNormal"+T,l[p]),i[T]=_;continue}i[T]=0}d.getUniforms().setValue(t,"morphTargetInfluences",i)}}}function Kt(t,e){var i={};return{update:function(n){var s=e.render.frame,l=n.geometry,d=t.get(n,l);return i[d.id]!==s&&(l.isGeometry&&d.updateFromObject(n),t.update(d),i[d.id]=s),d},dispose:function(){i={}}}}function z(t,e,i,n,s,l,d,p,_,T){t=t!==void 0?t:[],g.call(this,t,e!==void 0?e:301,i,n,s,l,d,p,_,T),this.flipY=!1}function Q(t,e,i,n){g.call(this,null),this.image={data:t,width:e,height:i,depth:n},this.minFilter=this.magFilter=1003,this.flipY=this.generateMipmaps=!1}function st(t,e,i){var n=t[0];if(0>=n||0<n)return t;var s=e*i,l=ah[s];if(l===void 0&&(l=new Float32Array(s),ah[s]=l),e!==0)for(n.toArray(l,0),n=1,s=0;n!==e;++n)s+=i,t[n].toArray(l,s);return l}function nt(t,e){if(t.length!==e.length)return!1;for(var i=0,n=t.length;i<n;i++)if(t[i]!==e[i])return!1;return!0}function vt(t,e){for(var i=0,n=e.length;i<n;i++)t[i]=e[i]}function Ut(t,e){var i=Ra[e];i===void 0&&(i=new Int32Array(e),Ra[e]=i);for(var n=0;n!==e;++n)i[n]=t.allocTextureUnit();return i}function qt(t,e){var i=this.cache;i[0]!==e&&(t.uniform1f(this.addr,e),i[0]=e)}function Xt(t,e){var i=this.cache;i[0]!==e&&(t.uniform1i(this.addr,e),i[0]=e)}function Ne(t,e){var i=this.cache;e.x!==void 0?(i[0]!==e.x||i[1]!==e.y)&&(t.uniform2f(this.addr,e.x,e.y),i[0]=e.x,i[1]=e.y):nt(i,e)||(t.uniform2fv(this.addr,e),vt(i,e))}function Ie(t,e){var i=this.cache;e.x!==void 0?(i[0]!==e.x||i[1]!==e.y||i[2]!==e.z)&&(t.uniform3f(this.addr,e.x,e.y,e.z),i[0]=e.x,i[1]=e.y,i[2]=e.z):e.r!==void 0?(i[0]!==e.r||i[1]!==e.g||i[2]!==e.b)&&(t.uniform3f(this.addr,e.r,e.g,e.b),i[0]=e.r,i[1]=e.g,i[2]=e.b):nt(i,e)||(t.uniform3fv(this.addr,e),vt(i,e))}function me(t,e){var i=this.cache;e.x!==void 0?(i[0]!==e.x||i[1]!==e.y||i[2]!==e.z||i[3]!==e.w)&&(t.uniform4f(this.addr,e.x,e.y,e.z,e.w),i[0]=e.x,i[1]=e.y,i[2]=e.z,i[3]=e.w):nt(i,e)||(t.uniform4fv(this.addr,e),vt(i,e))}function we(t,e){var i=this.cache,n=e.elements;n===void 0?nt(i,e)||(t.uniformMatrix2fv(this.addr,!1,e),vt(i,e)):nt(i,n)||(Yh.set(n),t.uniformMatrix2fv(this.addr,!1,Yh),vt(i,n))}function yi(t,e){var i=this.cache,n=e.elements;n===void 0?nt(i,e)||(t.uniformMatrix3fv(this.addr,!1,e),vt(i,e)):nt(i,n)||(Bu.set(n),t.uniformMatrix3fv(this.addr,!1,Bu),vt(i,n))}function Ei(t,e){var i=this.cache,n=e.elements;n===void 0?nt(i,e)||(t.uniformMatrix4fv(this.addr,!1,e),vt(i,e)):nt(i,n)||(wl.set(n),t.uniformMatrix4fv(this.addr,!1,wl),vt(i,n))}function ni(t,e,i){var n=this.cache,s=i.allocTextureUnit();n[0]!==s&&(t.uniform1i(this.addr,s),n[0]=s),i.setTexture2D(e||qh,s)}function bi(t,e,i){var n=this.cache,s=i.allocTextureUnit();n[0]!==s&&(t.uniform1i(this.addr,s),n[0]=s),i.setTexture3D(e||Jc,s)}function qr(t,e,i){var n=this.cache,s=i.allocTextureUnit();n[0]!==s&&(t.uniform1i(this.addr,s),n[0]=s),i.setTextureCube(e||ku,s)}function sr(t,e){var i=this.cache;nt(i,e)||(t.uniform2iv(this.addr,e),vt(i,e))}function sn(t,e){var i=this.cache;nt(i,e)||(t.uniform3iv(this.addr,e),vt(i,e))}function Ao(t,e){var i=this.cache;nt(i,e)||(t.uniform4iv(this.addr,e),vt(i,e))}function zi(t){switch(t){case 5126:return qt;case 35664:return Ne;case 35665:return Ie;case 35666:return me;case 35674:return we;case 35675:return yi;case 35676:return Ei;case 35678:case 36198:return ni;case 35679:return bi;case 35680:return qr;case 5124:case 35670:return Xt;case 35667:case 35671:return sr;case 35668:case 35672:return sn;case 35669:case 35673:return Ao}}function Yo(t,e){var i=this.cache;nt(i,e)||(t.uniform1fv(this.addr,e),vt(i,e))}function ao(t,e){var i=this.cache;nt(i,e)||(t.uniform1iv(this.addr,e),vt(i,e))}function Hl(t,e){var i=this.cache;e=st(e,this.size,2),nt(i,e)||(t.uniform2fv(this.addr,e),this.updateCache(e))}function Mn(t,e){var i=this.cache;e=st(e,this.size,3),nt(i,e)||(t.uniform3fv(this.addr,e),this.updateCache(e))}function ra(t,e){var i=this.cache;e=st(e,this.size,4),nt(i,e)||(t.uniform4fv(this.addr,e),this.updateCache(e))}function vs(t,e){var i=this.cache;e=st(e,this.size,4),nt(i,e)||(t.uniformMatrix2fv(this.addr,!1,e),this.updateCache(e))}function vr(t,e){var i=this.cache;e=st(e,this.size,9),nt(i,e)||(t.uniformMatrix3fv(this.addr,!1,e),this.updateCache(e))}function oa(t,e){var i=this.cache;e=st(e,this.size,16),nt(i,e)||(t.uniformMatrix4fv(this.addr,!1,e),this.updateCache(e))}function Za(t,e,i){var n=this.cache,s=e.length,l=Ut(i,s);for(nt(n,l)===!1&&(t.uniform1iv(this.addr,l),vt(n,l)),t=0;t!==s;++t)i.setTexture2D(e[t]||qh,l[t])}function Vl(t,e,i){var n=this.cache,s=e.length,l=Ut(i,s);for(nt(n,l)===!1&&(t.uniform1iv(this.addr,l),vt(n,l)),t=0;t!==s;++t)i.setTextureCube(e[t]||ku,l[t])}function lo(t){switch(t){case 5126:return Yo;case 35664:return Hl;case 35665:return Mn;case 35666:return ra;case 35674:return vs;case 35675:return vr;case 35676:return oa;case 35678:return Za;case 35680:return Vl;case 5124:case 35670:return ao;case 35667:case 35671:return sr;case 35668:case 35672:return sn;case 35669:case 35673:return Ao}}function Oh(t,e,i){this.id=t,this.addr=i,this.cache=[],this.setValue=zi(e.type)}function sa(t,e,i){this.id=t,this.addr=i,this.cache=[],this.size=e.size,this.setValue=lo(e.type)}function Ja(t){this.id=t,this.seq=[],this.map={}}function ho(t,e,i){this.seq=[],this.map={},this.renderer=i,i=t.getProgramParameter(e,35718);for(var n=0;n<i;++n){var s=t.getActiveUniform(e,n),l=t.getUniformLocation(e,s.name),d=this,p=s.name,_=p.length;for(Zh.lastIndex=0;;){var T=Zh.exec(p),A=Zh.lastIndex,L=T[1],B=T[3];if(T[2]==="]"&&(L|=0),B===void 0||B==="["&&A+2===_){p=d,s=B===void 0?new Oh(L,s,l):new sa(L,s,l),p.seq.push(s),p.map[s.id]=s;break}else B=d.map[L],B===void 0&&(B=new Ja(L),L=d,d=B,L.seq.push(d),L.map[d.id]=d),d=B}}}function Wl(t){t=t.split(`
|
|
255
|
+
}`,this.linewidth=1,this.wireframe=!1,this.wireframeLinewidth=1,this.morphNormals=this.morphTargets=this.skinning=this.clipping=this.lights=this.fog=!1,this.extensions={derivatives:!1,fragDepth:!1,drawBuffers:!1,shaderTextureLOD:!1},this.defaultAttributeValues={color:[1,1,1],uv:[0,0],uv2:[0,0]},this.index0AttributeName=void 0,this.uniformsNeedUpdate=!1,t!==void 0&&(t.attributes,this.setValues(t))}function Si(t,e){this.origin=t!==void 0?t:new u,this.direction=e!==void 0?e:new u}function Oe(t,e,i){this.a=t!==void 0?t:new u,this.b=e!==void 0?e:new u,this.c=i!==void 0?i:new u}function Ge(t){Wt.call(this),this.type="MeshBasicMaterial",this.color=new P(16777215),this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.envMap=this.alphaMap=this.specularMap=null,this.combine=0,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.lights=this.morphTargets=this.skinning=!1,this.setValues(t)}function pi(t,e){N.call(this),this.type="Mesh",this.geometry=t!==void 0?t:new Ft,this.material=e!==void 0?e:new Ge({color:16777215*Math.random()}),this.drawMode=0,this.updateMorphTargets()}function Di(t,e,i,n){function s(T,A){e.buffers.color.setClear(T.r,T.g,T.b,A,n)}var l=new P(0),d=0,p,_;return{getClearColor:function(){return l},setClearColor:function(T,A){l.set(T),d=A!==void 0?A:1,s(l,d)},getClearAlpha:function(){return d},setClearAlpha:function(T){d=T,s(l,d)},render:function(T,A,L,B){A=A.background,A===null?s(l,d):A&&A.isColor&&(s(A,1),B=!0),(t.autoClear||B)&&t.clear(t.autoClearColor,t.autoClearDepth,t.autoClearStencil),A&&(A.isCubeTexture||A.isWebGLRenderTargetCube)?(_===void 0&&(_=new pi(new Nt(1,1,1),new $e({type:"BackgroundCubeMaterial",uniforms:Bn.clone(wo.cube.uniforms),vertexShader:wo.cube.vertexShader,fragmentShader:wo.cube.fragmentShader,side:1,depthTest:!0,depthWrite:!1,fog:!1})),_.geometry.removeAttribute("normal"),_.geometry.removeAttribute("uv"),_.onBeforeRender=function(H,q,$){this.matrixWorld.copyPosition($.matrixWorld)},i.update(_)),_.material.uniforms.tCube.value=A.isWebGLRenderTargetCube?A.texture:A,_.material.uniforms.tFlip.value=A.isWebGLRenderTargetCube?1:-1,T.push(_,_.geometry,_.material,0,null)):A&&A.isTexture&&(p===void 0&&(p=new pi(new pe(2,2),new $e({type:"BackgroundMaterial",uniforms:Bn.clone(wo.background.uniforms),vertexShader:wo.background.vertexShader,fragmentShader:wo.background.fragmentShader,side:0,depthTest:!0,depthWrite:!1,fog:!1})),p.geometry.removeAttribute("normal"),i.update(p)),p.material.uniforms.t2D.value=A,A.matrixAutoUpdate===!0&&A.updateMatrix(),p.material.uniforms.uvTransform.value.copy(A.matrix),T.push(p,p.geometry,p.material,0,null))}}}function mn(t,e,i,n){var s;this.setMode=function(l){s=l},this.render=function(l,d){t.drawArrays(s,l,d),i.update(d,s)},this.renderInstances=function(l,d,p){if(n.isWebGL2)var _=t;else if(_=e.get("ANGLE_instanced_arrays"),_===null)return;_[n.isWebGL2?"drawArraysInstanced":"drawArraysInstancedANGLE"](s,d,p,l.maxInstancedCount),i.update(p,s,l.maxInstancedCount)}}function Qi(t,e,i){function n(xt){if(xt==="highp"){if(0<t.getShaderPrecisionFormat(35633,36338).precision&&0<t.getShaderPrecisionFormat(35632,36338).precision)return"highp";xt="mediump"}return xt==="mediump"&&0<t.getShaderPrecisionFormat(35633,36337).precision&&0<t.getShaderPrecisionFormat(35632,36337).precision?"mediump":"lowp"}var s,l=typeof WebGL2RenderingContext<"u"&&t instanceof WebGL2RenderingContext,d=i.precision!==void 0?i.precision:"highp",p=n(d);p!==d&&(d=p),i=i.logarithmicDepthBuffer===!0,p=t.getParameter(34930);var _=t.getParameter(35660),T=t.getParameter(3379),A=t.getParameter(34076),L=t.getParameter(34921),B=t.getParameter(36347),H=t.getParameter(36348),q=t.getParameter(36349),$=0<_,rt=l||!!e.get("OES_texture_float");return{isWebGL2:l,getMaxAnisotropy:function(){if(s!==void 0)return s;var xt=e.get("EXT_texture_filter_anisotropic");return s=xt!==null?t.getParameter(xt.MAX_TEXTURE_MAX_ANISOTROPY_EXT):0},getMaxPrecision:n,precision:d,logarithmicDepthBuffer:i,maxTextures:p,maxVertexTextures:_,maxTextureSize:T,maxCubemapSize:A,maxAttributes:L,maxVertexUniforms:B,maxVaryings:H,maxFragmentUniforms:q,vertexTextures:$,floatFragmentTextures:rt,floatVertexTextures:$&&rt}}function W(){function t(){T.value!==n&&(T.value=n,T.needsUpdate=0<s),i.numPlanes=s,i.numIntersection=0}function e(A,L,B,H){var q=A!==null?A.length:0,$=null;if(q!==0){if($=T.value,H!==!0||$===null)for(H=B+4*q,L=L.matrixWorldInverse,_.getNormalMatrix(L),($===null||$.length<H)&&($=new Float32Array(H)),H=0;H!==q;++H,B+=4)p.copy(A[H]).applyMatrix4(L,_),p.normal.toArray($,B),$[B+3]=p.constant;T.value=$,T.needsUpdate=!0}return i.numPlanes=q,$}var i=this,n=null,s=0,l=!1,d=!1,p=new F,_=new m,T={value:null,needsUpdate:!1};this.uniform=T,this.numIntersection=this.numPlanes=0,this.init=function(A,L,B){var H=A.length!==0||L||s!==0||l;return l=L,n=e(A,B,0),s=A.length,H},this.beginShadows=function(){d=!0,e(null)},this.endShadows=function(){d=!1,t()},this.setState=function(A,L,B,H,q,$){if(!l||A===null||A.length===0||d&&!B)d?e(null):t();else{B=d?0:s;var rt=4*B,xt=q.clippingState||null;for(T.value=xt,xt=e(A,H,rt,$),A=0;A!==rt;++A)xt[A]=n[A];q.clippingState=xt,this.numIntersection=L?this.numPlanes:0,this.numPlanes+=B}}}function Jt(t){var e={};return{get:function(i){if(e[i]!==void 0)return e[i];switch(i){case"WEBGL_depth_texture":var n=t.getExtension("WEBGL_depth_texture")||t.getExtension("MOZ_WEBGL_depth_texture")||t.getExtension("WEBKIT_WEBGL_depth_texture");break;case"EXT_texture_filter_anisotropic":n=t.getExtension("EXT_texture_filter_anisotropic")||t.getExtension("MOZ_EXT_texture_filter_anisotropic")||t.getExtension("WEBKIT_EXT_texture_filter_anisotropic");break;case"WEBGL_compressed_texture_s3tc":n=t.getExtension("WEBGL_compressed_texture_s3tc")||t.getExtension("MOZ_WEBGL_compressed_texture_s3tc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");break;case"WEBGL_compressed_texture_pvrtc":n=t.getExtension("WEBGL_compressed_texture_pvrtc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");break;default:n=t.getExtension(i)}return e[i]=n}}}function jt(t,e,i){function n(d){var p=d.target;d=s[p.id],d.index!==null&&e.remove(d.index);for(var _ in d.attributes)e.remove(d.attributes[_]);p.removeEventListener("dispose",n),delete s[p.id],(_=l[d.id])&&(e.remove(_),delete l[d.id]),i.memory.geometries--}var s={},l={};return{get:function(d,p){var _=s[p.id];return _||(p.addEventListener("dispose",n),p.isBufferGeometry?_=p:p.isGeometry&&(p._bufferGeometry===void 0&&(p._bufferGeometry=new Ft().setFromObject(d)),_=p._bufferGeometry),s[p.id]=_,i.memory.geometries++,_)},update:function(d){var p=d.index,_=d.attributes;p!==null&&e.update(p,34963);for(var T in _)e.update(_[T],34962);d=d.morphAttributes;for(T in d){p=d[T],_=0;for(var A=p.length;_<A;_++)e.update(p[_],34962)}},getWireframeAttribute:function(d){var p=l[d.id];if(p)return p;p=[];var _=d.index,T=d.attributes;if(_!==null){_=_.array,T=0;for(var A=_.length;T<A;T+=3){var L=_[T+0],B=_[T+1],H=_[T+2];p.push(L,B,B,H,H,L)}}else for(_=T.position.array,T=0,A=_.length/3-1;T<A;T+=3)L=T+0,B=T+1,H=T+2,p.push(L,B,B,H,H,L);return p=new(65535<re(p)?Pt:_t)(p,1),e.update(p,34963),l[d.id]=p}}}function dt(t,e,i,n){var s,l,d;this.setMode=function(p){s=p},this.setIndex=function(p){l=p.type,d=p.bytesPerElement},this.render=function(p,_){t.drawElements(s,_,l,p*d),i.update(_,s)},this.renderInstances=function(p,_,T){if(n.isWebGL2)var A=t;else if(A=e.get("ANGLE_instanced_arrays"),A===null)return;A[n.isWebGL2?"drawElementsInstanced":"drawElementsInstancedANGLE"](s,T,l,_*d,p.maxInstancedCount),i.update(T,s,p.maxInstancedCount)}}function pt(t){var e={frame:0,calls:0,triangles:0,points:0,lines:0};return{memory:{geometries:0,textures:0},render:e,programs:null,autoReset:!0,reset:function(){e.frame++,e.calls=0,e.triangles=0,e.points=0,e.lines=0},update:function(i,n,s){switch(s=s||1,e.calls++,n){case 4:e.triangles+=i/3*s;break;case 5:case 6:e.triangles+=s*(i-2);break;case 1:e.lines+=i/2*s;break;case 3:e.lines+=s*(i-1);break;case 2:e.lines+=s*i;break;case 0:e.points+=s*i;break;default:}}}}function Dt(t,e){return Math.abs(e[1])-Math.abs(t[1])}function ie(t){var e={},i=new Float32Array(8);return{update:function(n,s,l,d){var p=n.morphTargetInfluences,_=p.length;if(n=e[s.id],n===void 0){n=[];for(var T=0;T<_;T++)n[T]=[T,0];e[s.id]=n}var A=l.morphTargets&&s.morphAttributes.position;for(l=l.morphNormals&&s.morphAttributes.normal,T=0;T<_;T++){var L=n[T];L[1]!==0&&(A&&s.removeAttribute("morphTarget"+T),l&&s.removeAttribute("morphNormal"+T))}for(T=0;T<_;T++)L=n[T],L[0]=T,L[1]=p[T];for(n.sort(Dt),T=0;8>T;T++){if((L=n[T])&&(p=L[0],_=L[1])){A&&s.addAttribute("morphTarget"+T,A[p]),l&&s.addAttribute("morphNormal"+T,l[p]),i[T]=_;continue}i[T]=0}d.getUniforms().setValue(t,"morphTargetInfluences",i)}}}function Kt(t,e){var i={};return{update:function(n){var s=e.render.frame,l=n.geometry,d=t.get(n,l);return i[d.id]!==s&&(l.isGeometry&&d.updateFromObject(n),t.update(d),i[d.id]=s),d},dispose:function(){i={}}}}function z(t,e,i,n,s,l,d,p,_,T){t=t!==void 0?t:[],g.call(this,t,e!==void 0?e:301,i,n,s,l,d,p,_,T),this.flipY=!1}function Q(t,e,i,n){g.call(this,null),this.image={data:t,width:e,height:i,depth:n},this.minFilter=this.magFilter=1003,this.flipY=this.generateMipmaps=!1}function st(t,e,i){var n=t[0];if(0>=n||0<n)return t;var s=e*i,l=ah[s];if(l===void 0&&(l=new Float32Array(s),ah[s]=l),e!==0)for(n.toArray(l,0),n=1,s=0;n!==e;++n)s+=i,t[n].toArray(l,s);return l}function nt(t,e){if(t.length!==e.length)return!1;for(var i=0,n=t.length;i<n;i++)if(t[i]!==e[i])return!1;return!0}function vt(t,e){for(var i=0,n=e.length;i<n;i++)t[i]=e[i]}function Ut(t,e){var i=Ra[e];i===void 0&&(i=new Int32Array(e),Ra[e]=i);for(var n=0;n!==e;++n)i[n]=t.allocTextureUnit();return i}function qt(t,e){var i=this.cache;i[0]!==e&&(t.uniform1f(this.addr,e),i[0]=e)}function Xt(t,e){var i=this.cache;i[0]!==e&&(t.uniform1i(this.addr,e),i[0]=e)}function Ne(t,e){var i=this.cache;e.x!==void 0?(i[0]!==e.x||i[1]!==e.y)&&(t.uniform2f(this.addr,e.x,e.y),i[0]=e.x,i[1]=e.y):nt(i,e)||(t.uniform2fv(this.addr,e),vt(i,e))}function Ie(t,e){var i=this.cache;e.x!==void 0?(i[0]!==e.x||i[1]!==e.y||i[2]!==e.z)&&(t.uniform3f(this.addr,e.x,e.y,e.z),i[0]=e.x,i[1]=e.y,i[2]=e.z):e.r!==void 0?(i[0]!==e.r||i[1]!==e.g||i[2]!==e.b)&&(t.uniform3f(this.addr,e.r,e.g,e.b),i[0]=e.r,i[1]=e.g,i[2]=e.b):nt(i,e)||(t.uniform3fv(this.addr,e),vt(i,e))}function me(t,e){var i=this.cache;e.x!==void 0?(i[0]!==e.x||i[1]!==e.y||i[2]!==e.z||i[3]!==e.w)&&(t.uniform4f(this.addr,e.x,e.y,e.z,e.w),i[0]=e.x,i[1]=e.y,i[2]=e.z,i[3]=e.w):nt(i,e)||(t.uniform4fv(this.addr,e),vt(i,e))}function we(t,e){var i=this.cache,n=e.elements;n===void 0?nt(i,e)||(t.uniformMatrix2fv(this.addr,!1,e),vt(i,e)):nt(i,n)||(Yh.set(n),t.uniformMatrix2fv(this.addr,!1,Yh),vt(i,n))}function yi(t,e){var i=this.cache,n=e.elements;n===void 0?nt(i,e)||(t.uniformMatrix3fv(this.addr,!1,e),vt(i,e)):nt(i,n)||(Bu.set(n),t.uniformMatrix3fv(this.addr,!1,Bu),vt(i,n))}function Ei(t,e){var i=this.cache,n=e.elements;n===void 0?nt(i,e)||(t.uniformMatrix4fv(this.addr,!1,e),vt(i,e)):nt(i,n)||(wl.set(n),t.uniformMatrix4fv(this.addr,!1,wl),vt(i,n))}function ni(t,e,i){var n=this.cache,s=i.allocTextureUnit();n[0]!==s&&(t.uniform1i(this.addr,s),n[0]=s),i.setTexture2D(e||qh,s)}function bi(t,e,i){var n=this.cache,s=i.allocTextureUnit();n[0]!==s&&(t.uniform1i(this.addr,s),n[0]=s),i.setTexture3D(e||Jc,s)}function qr(t,e,i){var n=this.cache,s=i.allocTextureUnit();n[0]!==s&&(t.uniform1i(this.addr,s),n[0]=s),i.setTextureCube(e||ku,s)}function sr(t,e){var i=this.cache;nt(i,e)||(t.uniform2iv(this.addr,e),vt(i,e))}function sn(t,e){var i=this.cache;nt(i,e)||(t.uniform3iv(this.addr,e),vt(i,e))}function Ao(t,e){var i=this.cache;nt(i,e)||(t.uniform4iv(this.addr,e),vt(i,e))}function zi(t){switch(t){case 5126:return qt;case 35664:return Ne;case 35665:return Ie;case 35666:return me;case 35674:return we;case 35675:return yi;case 35676:return Ei;case 35678:case 36198:return ni;case 35679:return bi;case 35680:return qr;case 5124:case 35670:return Xt;case 35667:case 35671:return sr;case 35668:case 35672:return sn;case 35669:case 35673:return Ao}}function Yo(t,e){var i=this.cache;nt(i,e)||(t.uniform1fv(this.addr,e),vt(i,e))}function ao(t,e){var i=this.cache;nt(i,e)||(t.uniform1iv(this.addr,e),vt(i,e))}function Hl(t,e){var i=this.cache;e=st(e,this.size,2),nt(i,e)||(t.uniform2fv(this.addr,e),this.updateCache(e))}function Mn(t,e){var i=this.cache;e=st(e,this.size,3),nt(i,e)||(t.uniform3fv(this.addr,e),this.updateCache(e))}function ra(t,e){var i=this.cache;e=st(e,this.size,4),nt(i,e)||(t.uniform4fv(this.addr,e),this.updateCache(e))}function vs(t,e){var i=this.cache;e=st(e,this.size,4),nt(i,e)||(t.uniformMatrix2fv(this.addr,!1,e),this.updateCache(e))}function vr(t,e){var i=this.cache;e=st(e,this.size,9),nt(i,e)||(t.uniformMatrix3fv(this.addr,!1,e),this.updateCache(e))}function oa(t,e){var i=this.cache;e=st(e,this.size,16),nt(i,e)||(t.uniformMatrix4fv(this.addr,!1,e),this.updateCache(e))}function Za(t,e,i){var n=this.cache,s=e.length,l=Ut(i,s);for(nt(n,l)===!1&&(t.uniform1iv(this.addr,l),vt(n,l)),t=0;t!==s;++t)i.setTexture2D(e[t]||qh,l[t])}function Vl(t,e,i){var n=this.cache,s=e.length,l=Ut(i,s);for(nt(n,l)===!1&&(t.uniform1iv(this.addr,l),vt(n,l)),t=0;t!==s;++t)i.setTextureCube(e[t]||ku,l[t])}function lo(t){switch(t){case 5126:return Yo;case 35664:return Hl;case 35665:return Mn;case 35666:return ra;case 35674:return vs;case 35675:return vr;case 35676:return oa;case 35678:return Za;case 35680:return Vl;case 5124:case 35670:return ao;case 35667:case 35671:return sr;case 35668:case 35672:return sn;case 35669:case 35673:return Ao}}function Oh(t,e,i){this.id=t,this.addr=i,this.cache=[],this.setValue=zi(e.type)}function sa(t,e,i){this.id=t,this.addr=i,this.cache=[],this.size=e.size,this.setValue=lo(e.type)}function Ja(t){this.id=t,this.seq=[],this.map={}}function ho(t,e,i){this.seq=[],this.map={},this.renderer=i,i=t.getProgramParameter(e,35718);for(var n=0;n<i;++n){var s=t.getActiveUniform(e,n),l=t.getUniformLocation(e,s.name),d=this,p=s.name,_=p.length;for(Zh.lastIndex=0;;){var T=Zh.exec(p),A=Zh.lastIndex,L=T[1],B=T[3];if(T[2]==="]"&&(L|=0),B===void 0||B==="["&&A+2===_){p=d,s=B===void 0?new Oh(L,s,l):new sa(L,s,l),p.seq.push(s),p.map[s.id]=s;break}else B=d.map[L],B===void 0&&(B=new Ja(L),L=d,d=B,L.seq.push(d),L.map[d.id]=d),d=B}}}function Wl(t){t=t.split(`
|
|
256
256
|
`);for(var e=0;e<t.length;e++)t[e]=e+1+": "+t[e];return t.join(`
|
|
257
257
|
`)}function aa(t,e,i){var n=t.createShader(e);return t.shaderSource(n,i),t.compileShader(n),t.getShaderParameter(n,35713),t.getShaderInfoLog(n),n}function la(t){switch(t){case 3e3:return["Linear","( value )"];case 3001:return["sRGB","( value )"];case 3002:return["RGBE","( value )"];case 3004:return["RGBM","( value, 7.0 )"];case 3005:return["RGBM","( value, 16.0 )"];case 3006:return["RGBD","( value, 256.0 )"];case 3007:return["Gamma","( value, float( GAMMA_FACTOR ) )"];default:throw Error("unsupported encoding: "+t)}}function uo(t,e){return e=la(e),"vec4 "+t+"( vec4 value ) { return "+e[0]+"ToLinear"+e[1]+"; }"}function jl(t,e){return e=la(e),"vec4 "+t+"( vec4 value ) { return LinearTo"+e[0]+e[1]+"; }"}function Ih(t,e){switch(e){case 1:e="Linear";break;case 2:e="Reinhard";break;case 3:e="Uncharted2";break;case 4:e="OptimizedCineon";break;default:throw Error("unsupported toneMapping: "+e)}return"vec3 "+t+"( vec3 color ) { return "+e+"ToneMapping( color ); }"}function Dh(t,e,i){return t=t||{},[t.derivatives||e.envMapCubeUV||e.bumpMap||e.normalMap&&!e.objectSpaceNormalMap||e.flatShading?"#extension GL_OES_standard_derivatives : enable":"",(t.fragDepth||e.logarithmicDepthBuffer)&&i.get("EXT_frag_depth")?"#extension GL_EXT_frag_depth : enable":"",t.drawBuffers&&i.get("WEBGL_draw_buffers")?"#extension GL_EXT_draw_buffers : require":"",(t.shaderTextureLOD||e.envMap)&&i.get("EXT_shader_texture_lod")?"#extension GL_EXT_shader_texture_lod : enable":""].filter(_s).join(`
|
|
258
258
|
`)}function ys(t){var e=[],i;for(i in t){var n=t[i];n!==!1&&e.push("#define "+i+" "+n)}return e.join(`
|
|
259
|
-
`)}function _s(t){return t!==""}function Xl(t,e){return t.replace(/NUM_DIR_LIGHTS/g,e.numDirLights).replace(/NUM_SPOT_LIGHTS/g,e.numSpotLights).replace(/NUM_RECT_AREA_LIGHTS/g,e.numRectAreaLights).replace(/NUM_POINT_LIGHTS/g,e.numPointLights).replace(/NUM_HEMI_LIGHTS/g,e.numHemiLights)}function ql(t,e){return t.replace(/NUM_CLIPPING_PLANES/g,e.numClippingPlanes).replace(/UNION_CLIPPING_PLANES/g,e.numClippingPlanes-e.numClipIntersection)}function Yr(t){return t.replace(/^[ \t]*#include +<([\w\d./]+)>/gm,function(e,i){if(e=Ci[i],e===void 0)throw Error("Can not resolve #include <"+i+">");return Yr(e)})}function V(t){return t.replace(/#pragma unroll_loop[\s]+?for \( int i = (\d+); i < (\d+); i \+\+ \) \{([\s\S]+?)(?=\})\}/g,function(e,i,n,s){for(e="",i=parseInt(i);i<parseInt(n);i++)e+=s.replace(/\[ i \]/g,"[ "+i+" ]");return e})}function et(t,e,i,n,s,l,d){var p=t.context,_=n.defines,T=s.vertexShader,A=s.fragmentShader,L="SHADOWMAP_TYPE_BASIC";l.shadowMapType===1?L="SHADOWMAP_TYPE_PCF":l.shadowMapType===2&&(L="SHADOWMAP_TYPE_PCF_SOFT");var B="ENVMAP_TYPE_CUBE",H="ENVMAP_MODE_REFLECTION",q="ENVMAP_BLENDING_MULTIPLY";if(l.envMap){switch(n.envMap.mapping){case 301:case 302:B="ENVMAP_TYPE_CUBE";break;case 306:case 307:B="ENVMAP_TYPE_CUBE_UV";break;case 303:case 304:B="ENVMAP_TYPE_EQUIREC";break;case 305:B="ENVMAP_TYPE_SPHERE"}switch(n.envMap.mapping){case 302:case 304:H="ENVMAP_MODE_REFRACTION"}switch(n.combine){case 0:q="ENVMAP_BLENDING_MULTIPLY";break;case 1:q="ENVMAP_BLENDING_MIX";break;case 2:q="ENVMAP_BLENDING_ADD"}}var
|
|
259
|
+
`)}function _s(t){return t!==""}function Xl(t,e){return t.replace(/NUM_DIR_LIGHTS/g,e.numDirLights).replace(/NUM_SPOT_LIGHTS/g,e.numSpotLights).replace(/NUM_RECT_AREA_LIGHTS/g,e.numRectAreaLights).replace(/NUM_POINT_LIGHTS/g,e.numPointLights).replace(/NUM_HEMI_LIGHTS/g,e.numHemiLights)}function ql(t,e){return t.replace(/NUM_CLIPPING_PLANES/g,e.numClippingPlanes).replace(/UNION_CLIPPING_PLANES/g,e.numClippingPlanes-e.numClipIntersection)}function Yr(t){return t.replace(/^[ \t]*#include +<([\w\d./]+)>/gm,function(e,i){if(e=Ci[i],e===void 0)throw Error("Can not resolve #include <"+i+">");return Yr(e)})}function V(t){return t.replace(/#pragma unroll_loop[\s]+?for \( int i = (\d+); i < (\d+); i \+\+ \) \{([\s\S]+?)(?=\})\}/g,function(e,i,n,s){for(e="",i=parseInt(i);i<parseInt(n);i++)e+=s.replace(/\[ i \]/g,"[ "+i+" ]");return e})}function et(t,e,i,n,s,l,d){var p=t.context,_=n.defines,T=s.vertexShader,A=s.fragmentShader,L="SHADOWMAP_TYPE_BASIC";l.shadowMapType===1?L="SHADOWMAP_TYPE_PCF":l.shadowMapType===2&&(L="SHADOWMAP_TYPE_PCF_SOFT");var B="ENVMAP_TYPE_CUBE",H="ENVMAP_MODE_REFLECTION",q="ENVMAP_BLENDING_MULTIPLY";if(l.envMap){switch(n.envMap.mapping){case 301:case 302:B="ENVMAP_TYPE_CUBE";break;case 306:case 307:B="ENVMAP_TYPE_CUBE_UV";break;case 303:case 304:B="ENVMAP_TYPE_EQUIREC";break;case 305:B="ENVMAP_TYPE_SPHERE"}switch(n.envMap.mapping){case 302:case 304:H="ENVMAP_MODE_REFRACTION"}switch(n.combine){case 0:q="ENVMAP_BLENDING_MULTIPLY";break;case 1:q="ENVMAP_BLENDING_MIX";break;case 2:q="ENVMAP_BLENDING_ADD"}}var $=0<t.gammaFactor?t.gammaFactor:1,rt=d.isWebGL2?"":Dh(n.extensions,l,e),xt=ys(_),gt=p.createProgram();n.isRawShaderMaterial?(_=[xt].filter(_s).join(`
|
|
260
260
|
`),0<_.length&&(_+=`
|
|
261
261
|
`),e=[rt,xt].filter(_s).join(`
|
|
262
262
|
`),0<e.length&&(e+=`
|
|
263
|
-
`)):(_=["precision "+l.precision+" float;","precision "+l.precision+" int;","#define SHADER_NAME "+s.name,xt,l.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "
|
|
263
|
+
`)):(_=["precision "+l.precision+" float;","precision "+l.precision+" int;","#define SHADER_NAME "+s.name,xt,l.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+$,"#define MAX_BONES "+l.maxBones,l.useFog&&l.fog?"#define USE_FOG":"",l.useFog&&l.fogExp?"#define FOG_EXP2":"",l.map?"#define USE_MAP":"",l.envMap?"#define USE_ENVMAP":"",l.envMap?"#define "+H:"",l.lightMap?"#define USE_LIGHTMAP":"",l.aoMap?"#define USE_AOMAP":"",l.emissiveMap?"#define USE_EMISSIVEMAP":"",l.bumpMap?"#define USE_BUMPMAP":"",l.normalMap?"#define USE_NORMALMAP":"",l.normalMap&&l.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",l.displacementMap&&l.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",l.specularMap?"#define USE_SPECULARMAP":"",l.roughnessMap?"#define USE_ROUGHNESSMAP":"",l.metalnessMap?"#define USE_METALNESSMAP":"",l.alphaMap?"#define USE_ALPHAMAP":"",l.vertexColors?"#define USE_COLOR":"",l.flatShading?"#define FLAT_SHADED":"",l.skinning?"#define USE_SKINNING":"",l.useVertexTexture?"#define BONE_TEXTURE":"",l.morphTargets?"#define USE_MORPHTARGETS":"",l.morphNormals&&l.flatShading===!1?"#define USE_MORPHNORMALS":"",l.doubleSided?"#define DOUBLE_SIDED":"",l.flipSided?"#define FLIP_SIDED":"",l.shadowMapEnabled?"#define USE_SHADOWMAP":"",l.shadowMapEnabled?"#define "+L:"",l.sizeAttenuation?"#define USE_SIZEATTENUATION":"",l.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",l.logarithmicDepthBuffer&&(d.isWebGL2||e.get("EXT_frag_depth"))?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","attribute vec3 position;","attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_COLOR"," attribute vec3 color;","#endif","#ifdef USE_MORPHTARGETS"," attribute vec3 morphTarget0;"," attribute vec3 morphTarget1;"," attribute vec3 morphTarget2;"," attribute vec3 morphTarget3;"," #ifdef USE_MORPHNORMALS"," attribute vec3 morphNormal0;"," attribute vec3 morphNormal1;"," attribute vec3 morphNormal2;"," attribute vec3 morphNormal3;"," #else"," attribute vec3 morphTarget4;"," attribute vec3 morphTarget5;"," attribute vec3 morphTarget6;"," attribute vec3 morphTarget7;"," #endif","#endif","#ifdef USE_SKINNING"," attribute vec4 skinIndex;"," attribute vec4 skinWeight;","#endif",`
|
|
264
264
|
`].filter(_s).join(`
|
|
265
|
-
`),e=[rt,"precision "+l.precision+" float;","precision "+l.precision+" int;","#define SHADER_NAME "+s.name,xt,l.alphaTest?"#define ALPHATEST "+l.alphaTest+(l.alphaTest%1?"":".0"):"","#define GAMMA_FACTOR "
|
|
265
|
+
`),e=[rt,"precision "+l.precision+" float;","precision "+l.precision+" int;","#define SHADER_NAME "+s.name,xt,l.alphaTest?"#define ALPHATEST "+l.alphaTest+(l.alphaTest%1?"":".0"):"","#define GAMMA_FACTOR "+$,l.useFog&&l.fog?"#define USE_FOG":"",l.useFog&&l.fogExp?"#define FOG_EXP2":"",l.map?"#define USE_MAP":"",l.envMap?"#define USE_ENVMAP":"",l.envMap?"#define "+B:"",l.envMap?"#define "+H:"",l.envMap?"#define "+q:"",l.lightMap?"#define USE_LIGHTMAP":"",l.aoMap?"#define USE_AOMAP":"",l.emissiveMap?"#define USE_EMISSIVEMAP":"",l.bumpMap?"#define USE_BUMPMAP":"",l.normalMap?"#define USE_NORMALMAP":"",l.normalMap&&l.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",l.specularMap?"#define USE_SPECULARMAP":"",l.roughnessMap?"#define USE_ROUGHNESSMAP":"",l.metalnessMap?"#define USE_METALNESSMAP":"",l.alphaMap?"#define USE_ALPHAMAP":"",l.vertexColors?"#define USE_COLOR":"",l.gradientMap?"#define USE_GRADIENTMAP":"",l.flatShading?"#define FLAT_SHADED":"",l.doubleSided?"#define DOUBLE_SIDED":"",l.flipSided?"#define FLIP_SIDED":"",l.shadowMapEnabled?"#define USE_SHADOWMAP":"",l.shadowMapEnabled?"#define "+L:"",l.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",l.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",l.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",l.logarithmicDepthBuffer&&(d.isWebGL2||e.get("EXT_frag_depth"))?"#define USE_LOGDEPTHBUF_EXT":"",l.envMap&&(d.isWebGL2||e.get("EXT_shader_texture_lod"))?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;",l.toneMapping!==0?"#define TONE_MAPPING":"",l.toneMapping!==0?Ci.tonemapping_pars_fragment:"",l.toneMapping!==0?Ih("toneMapping",l.toneMapping):"",l.dithering?"#define DITHERING":"",l.outputEncoding||l.mapEncoding||l.matcapEncoding||l.envMapEncoding||l.emissiveMapEncoding?Ci.encodings_pars_fragment:"",l.mapEncoding?uo("mapTexelToLinear",l.mapEncoding):"",l.matcapEncoding?uo("matcapTexelToLinear",l.matcapEncoding):"",l.envMapEncoding?uo("envMapTexelToLinear",l.envMapEncoding):"",l.emissiveMapEncoding?uo("emissiveMapTexelToLinear",l.emissiveMapEncoding):"",l.outputEncoding?jl("linearToOutputTexel",l.outputEncoding):"",l.depthPacking?"#define DEPTH_PACKING "+n.depthPacking:"",`
|
|
266
266
|
`].filter(_s).join(`
|
|
267
267
|
`)),T=Yr(T),T=Xl(T,l),T=ql(T,l),A=Yr(A),A=Xl(A,l),A=ql(A,l),T=V(T),A=V(A),d.isWebGL2&&!n.isRawShaderMaterial&&(d=!1,L=/^\s*#version\s+300\s+es\s*\n/,n.isShaderMaterial&&T.match(L)!==null&&A.match(L)!==null&&(d=!0,T=T.replace(L,""),A=A.replace(L,"")),_=`#version 300 es
|
|
268
268
|
|
|
@@ -282,7 +282,7 @@
|
|
|
282
282
|
#define texture2DProjGradEXT textureProjGrad
|
|
283
283
|
#define textureCubeGradEXT textureGrad`].join(`
|
|
284
284
|
`)+`
|
|
285
|
-
`+e),A=e+A,T=aa(p,35633,_+T),A=aa(p,35632,A),p.attachShader(gt,T),p.attachShader(gt,A),n.index0AttributeName!==void 0?p.bindAttribLocation(gt,0,n.index0AttributeName):l.morphTargets===!0&&p.bindAttribLocation(gt,0,"position"),p.linkProgram(gt),l=p.getProgramInfoLog(gt).trim(),d=p.getShaderInfoLog(T).trim(),L=p.getShaderInfoLog(A).trim(),H=B=!0,p.getProgramParameter(gt,35714)===!1?B=!1:l!==""||(d===""||L==="")&&(H=!1),H&&(this.diagnostics={runnable:B,material:n,programLog:l,vertexShader:{log:d,prefix:_},fragmentShader:{log:L,prefix:e}}),p.deleteShader(T),p.deleteShader(A);var Ct;this.getUniforms=function(){return Ct===void 0&&(Ct=new ho(p,gt,t)),Ct};var wt;return this.getAttributes=function(){if(wt===void 0){for(var Vt={},$=p.getProgramParameter(gt,35721),ot=0;ot<$;ot++){var kt=p.getActiveAttrib(gt,ot).name;Vt[kt]=p.getAttribLocation(gt,kt)}wt=Vt}return wt},this.destroy=function(){p.deleteProgram(gt),this.program=void 0},Object.defineProperties(this,{uniforms:{get:function(){return this.getUniforms()}},attributes:{get:function(){return this.getAttributes()}}}),this.name=s.name,this.id=Bo++,this.code=i,this.usedTimes=1,this.program=gt,this.vertexShader=T,this.fragmentShader=A,this}function lt(t,e,i){function n(p,_){if(p)p.isTexture?T=p.encoding:p.isWebGLRenderTarget&&(T=p.texture.encoding);else var T=3e3;return T===3e3&&_&&(T=3007),T}var s=[],l={MeshDepthMaterial:"depth",MeshDistanceMaterial:"distanceRGBA",MeshNormalMaterial:"normal",MeshBasicMaterial:"basic",MeshLambertMaterial:"lambert",MeshPhongMaterial:"phong",MeshToonMaterial:"phong",MeshStandardMaterial:"physical",MeshPhysicalMaterial:"physical",MeshMatcapMaterial:"matcap",LineBasicMaterial:"basic",LineDashedMaterial:"dashed",PointsMaterial:"points",ShadowMaterial:"shadow",SpriteMaterial:"sprite"},d="precision supportsVertexTextures map mapEncoding matcapEncoding envMap envMapMode envMapEncoding lightMap aoMap emissiveMap emissiveMapEncoding bumpMap normalMap objectSpaceNormalMap displacementMap specularMap roughnessMap metalnessMap gradientMap alphaMap combine vertexColors fog useFog fogExp flatShading sizeAttenuation logarithmicDepthBuffer skinning maxBones useVertexTexture morphTargets morphNormals maxMorphTargets maxMorphNormals premultipliedAlpha numDirLights numPointLights numSpotLights numHemiLights numRectAreaLights shadowMapEnabled shadowMapType toneMapping physicallyCorrectLights alphaTest doubleSided flipSided numClippingPlanes numClipIntersection depthPacking dithering".split(" ");this.getParameters=function(p,_,T,A,L,B,H){var q=l[p.type];if(H.isSkinnedMesh){var J=H.skeleton.bones;if(i.floatVertexTextures)J=1024;else{var rt=Math.min(Math.floor((i.maxVertexUniforms-20)/4),J.length);rt<J.length?J=0:J=rt}}else J=0;rt=i.precision,p.precision!==null&&(rt=i.getMaxPrecision(p.precision),p.precision);var xt=t.getRenderTarget();return{shaderID:q,precision:rt,supportsVertexTextures:i.vertexTextures,outputEncoding:n(xt?xt.texture:null,t.gammaOutput),map:!!p.map,mapEncoding:n(p.map,t.gammaInput),matcap:!!p.matcap,matcapEncoding:n(p.matcap,t.gammaInput),envMap:!!p.envMap,envMapMode:p.envMap&&p.envMap.mapping,envMapEncoding:n(p.envMap,t.gammaInput),envMapCubeUV:!!p.envMap&&(p.envMap.mapping===306||p.envMap.mapping===307),lightMap:!!p.lightMap,aoMap:!!p.aoMap,emissiveMap:!!p.emissiveMap,emissiveMapEncoding:n(p.emissiveMap,t.gammaInput),bumpMap:!!p.bumpMap,normalMap:!!p.normalMap,objectSpaceNormalMap:p.normalMapType===1,displacementMap:!!p.displacementMap,roughnessMap:!!p.roughnessMap,metalnessMap:!!p.metalnessMap,specularMap:!!p.specularMap,alphaMap:!!p.alphaMap,gradientMap:!!p.gradientMap,combine:p.combine,vertexColors:p.vertexColors,fog:!!A,useFog:p.fog,fogExp:A&&A.isFogExp2,flatShading:p.flatShading,sizeAttenuation:p.sizeAttenuation,logarithmicDepthBuffer:i.logarithmicDepthBuffer,skinning:p.skinning&&0<J,maxBones:J,useVertexTexture:i.floatVertexTextures,morphTargets:p.morphTargets,morphNormals:p.morphNormals,maxMorphTargets:t.maxMorphTargets,maxMorphNormals:t.maxMorphNormals,numDirLights:_.directional.length,numPointLights:_.point.length,numSpotLights:_.spot.length,numRectAreaLights:_.rectArea.length,numHemiLights:_.hemi.length,numClippingPlanes:L,numClipIntersection:B,dithering:p.dithering,shadowMapEnabled:t.shadowMap.enabled&&H.receiveShadow&&0<T.length,shadowMapType:t.shadowMap.type,toneMapping:t.toneMapping,physicallyCorrectLights:t.physicallyCorrectLights,premultipliedAlpha:p.premultipliedAlpha,alphaTest:p.alphaTest,doubleSided:p.side===2,flipSided:p.side===1,depthPacking:p.depthPacking!==void 0?p.depthPacking:!1}},this.getProgramCode=function(p,_){var T=[];if(_.shaderID?T.push(_.shaderID):(T.push(p.fragmentShader),T.push(p.vertexShader)),p.defines!==void 0)for(var A in p.defines)T.push(A),T.push(p.defines[A]);for(A=0;A<d.length;A++)T.push(_[d[A]]);return T.push(p.onBeforeCompile.toString()),T.push(t.gammaOutput),T.push(t.gammaFactor),T.join()},this.acquireProgram=function(p,_,T,A){for(var L,B=0,H=s.length;B<H;B++){var q=s[B];if(q.code===A){L=q,++L.usedTimes;break}}return L===void 0&&(L=new et(t,e,A,p,_,T,i),s.push(L)),L},this.releaseProgram=function(p){if(--p.usedTimes===0){var _=s.indexOf(p);s[_]=s[s.length-1],s.pop(),p.destroy()}},this.programs=s}function at(){var t=new WeakMap;return{get:function(e){var i=t.get(e);return i===void 0&&(i={},t.set(e,i)),i},remove:function(e){t.delete(e)},update:function(e,i,n){t.get(e)[i]=n},dispose:function(){t=new WeakMap}}}function j(t,e){return t.renderOrder!==e.renderOrder?t.renderOrder-e.renderOrder:t.program&&e.program&&t.program!==e.program?t.program.id-e.program.id:t.material.id!==e.material.id?t.material.id-e.material.id:t.z!==e.z?t.z-e.z:t.id-e.id}function St(t,e){return t.renderOrder!==e.renderOrder?t.renderOrder-e.renderOrder:t.z!==e.z?e.z-t.z:t.id-e.id}function ht(){var t=[],e=0,i=[],n=[];return{opaque:i,transparent:n,init:function(){e=0,i.length=0,n.length=0},push:function(s,l,d,p,_){var T=t[e];T===void 0?(T={id:s.id,object:s,geometry:l,material:d,program:d.program,renderOrder:s.renderOrder,z:p,group:_},t[e]=T):(T.id=s.id,T.object=s,T.geometry=l,T.material=d,T.program=d.program,T.renderOrder=s.renderOrder,T.z=p,T.group=_),(d.transparent===!0?n:i).push(T),e++},sort:function(){1<i.length&&i.sort(j),1<n.length&&n.sort(St)}}}function Ot(){var t={};return{get:function(e,i){return e=e.id+","+i.id,i=t[e],i===void 0&&(i=new ht,t[e]=i),i},dispose:function(){t={}}}}function Gt(){var t={};return{get:function(e){if(t[e.id]!==void 0)return t[e.id];switch(e.type){case"DirectionalLight":var i={direction:new u,color:new P,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new o};break;case"SpotLight":i={position:new u,direction:new u,color:new P,distance:0,coneCos:0,penumbraCos:0,decay:0,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new o};break;case"PointLight":i={position:new u,color:new P,distance:0,decay:0,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new o,shadowCameraNear:1,shadowCameraFar:1e3};break;case"HemisphereLight":i={direction:new u,skyColor:new P,groundColor:new P};break;case"RectAreaLight":i={color:new P,position:new u,halfWidth:new u,halfHeight:new u}}return t[e.id]=i}}}function zt(){var t=new Gt,e={id:Jh++,hash:{stateID:-1,directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,shadowsLength:-1},ambient:[0,0,0],directional:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],point:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[]},i=new u,n=new c,s=new c;return{setup:function(l,d,p){var _=0,T=0,A=0,L=0,B=0,H=0,q=0,J=0;p=p.matrixWorldInverse;for(var rt=0,xt=l.length;rt<xt;rt++){var gt=l[rt],Ct=gt.color,wt=gt.intensity,Vt=gt.distance,$=gt.shadow&>.shadow.map?gt.shadow.map.texture:null;if(gt.isAmbientLight)_+=Ct.r*wt,T+=Ct.g*wt,A+=Ct.b*wt;else if(gt.isDirectionalLight){var ot=t.get(gt);ot.color.copy(gt.color).multiplyScalar(gt.intensity),ot.direction.setFromMatrixPosition(gt.matrixWorld),i.setFromMatrixPosition(gt.target.matrixWorld),ot.direction.sub(i),ot.direction.transformDirection(p),(ot.shadow=gt.castShadow)&&(Ct=gt.shadow,ot.shadowBias=Ct.bias,ot.shadowRadius=Ct.radius,ot.shadowMapSize=Ct.mapSize),e.directionalShadowMap[L]=$,e.directionalShadowMatrix[L]=gt.shadow.matrix,e.directional[L]=ot,L++}else gt.isSpotLight?(ot=t.get(gt),ot.position.setFromMatrixPosition(gt.matrixWorld),ot.position.applyMatrix4(p),ot.color.copy(Ct).multiplyScalar(wt),ot.distance=Vt,ot.direction.setFromMatrixPosition(gt.matrixWorld),i.setFromMatrixPosition(gt.target.matrixWorld),ot.direction.sub(i),ot.direction.transformDirection(p),ot.coneCos=Math.cos(gt.angle),ot.penumbraCos=Math.cos(gt.angle*(1-gt.penumbra)),ot.decay=gt.decay,(ot.shadow=gt.castShadow)&&(Ct=gt.shadow,ot.shadowBias=Ct.bias,ot.shadowRadius=Ct.radius,ot.shadowMapSize=Ct.mapSize),e.spotShadowMap[H]=$,e.spotShadowMatrix[H]=gt.shadow.matrix,e.spot[H]=ot,H++):gt.isRectAreaLight?(ot=t.get(gt),ot.color.copy(Ct).multiplyScalar(wt),ot.position.setFromMatrixPosition(gt.matrixWorld),ot.position.applyMatrix4(p),s.identity(),n.copy(gt.matrixWorld),n.premultiply(p),s.extractRotation(n),ot.halfWidth.set(.5*gt.width,0,0),ot.halfHeight.set(0,.5*gt.height,0),ot.halfWidth.applyMatrix4(s),ot.halfHeight.applyMatrix4(s),e.rectArea[q]=ot,q++):gt.isPointLight?(ot=t.get(gt),ot.position.setFromMatrixPosition(gt.matrixWorld),ot.position.applyMatrix4(p),ot.color.copy(gt.color).multiplyScalar(gt.intensity),ot.distance=gt.distance,ot.decay=gt.decay,(ot.shadow=gt.castShadow)&&(Ct=gt.shadow,ot.shadowBias=Ct.bias,ot.shadowRadius=Ct.radius,ot.shadowMapSize=Ct.mapSize,ot.shadowCameraNear=Ct.camera.near,ot.shadowCameraFar=Ct.camera.far),e.pointShadowMap[B]=$,e.pointShadowMatrix[B]=gt.shadow.matrix,e.point[B]=ot,B++):gt.isHemisphereLight&&(ot=t.get(gt),ot.direction.setFromMatrixPosition(gt.matrixWorld),ot.direction.transformDirection(p),ot.direction.normalize(),ot.skyColor.copy(gt.color).multiplyScalar(wt),ot.groundColor.copy(gt.groundColor).multiplyScalar(wt),e.hemi[J]=ot,J++)}e.ambient[0]=_,e.ambient[1]=T,e.ambient[2]=A,e.directional.length=L,e.spot.length=H,e.rectArea.length=q,e.point.length=B,e.hemi.length=J,e.hash.stateID=e.id,e.hash.directionalLength=L,e.hash.pointLength=B,e.hash.spotLength=H,e.hash.rectAreaLength=q,e.hash.hemiLength=J,e.hash.shadowsLength=d.length},state:e}}function Mt(){var t=new zt,e=[],i=[];return{init:function(){e.length=0,i.length=0},state:{lightsArray:e,shadowsArray:i,lights:t},setupLights:function(n){t.setup(e,i,n)},pushLight:function(n){e.push(n)},pushShadow:function(n){i.push(n)}}}function he(){var t={};return{get:function(e,i){if(t[e.id]===void 0){var n=new Mt;t[e.id]={},t[e.id][i.id]=n}else t[e.id][i.id]===void 0?(n=new Mt,t[e.id][i.id]=n):n=t[e.id][i.id];return n},dispose:function(){t={}}}}function se(t){Wt.call(this),this.type="MeshDepthMaterial",this.depthPacking=3200,this.morphTargets=this.skinning=!1,this.displacementMap=this.alphaMap=this.map=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.lights=this.fog=!1,this.setValues(t)}function te(t){Wt.call(this),this.type="MeshDistanceMaterial",this.referencePosition=new u,this.nearDistance=1,this.farDistance=1e3,this.morphTargets=this.skinning=!1,this.displacementMap=this.alphaMap=this.map=null,this.displacementScale=1,this.displacementBias=0,this.lights=this.fog=!1,this.setValues(t)}function ye(t,e,i){function n($,ot,kt,ee,$t,Yt){var Te=$.geometry,ge=L,De=$.customDepthMaterial;return kt&&(ge=B,De=$.customDistanceMaterial),De?ge=De:(De=!1,ot.morphTargets&&(Te&&Te.isBufferGeometry?De=Te.morphAttributes&&Te.morphAttributes.position&&0<Te.morphAttributes.position.length:Te&&Te.isGeometry&&(De=Te.morphTargets&&0<Te.morphTargets.length)),$.isSkinnedMesh&&ot.skinning,$=$.isSkinnedMesh&&ot.skinning,Te=0,De&&(Te|=1),$&&(Te|=2),ge=ge[Te]),t.localClippingEnabled&&ot.clipShadows===!0&&ot.clippingPlanes.length!==0&&(Te=ge.uuid,De=ot.uuid,$=H[Te],$===void 0&&($={},H[Te]=$),Te=$[De],Te===void 0&&(Te=ge.clone(),$[De]=Te),ge=Te),ge.visible=ot.visible,ge.wireframe=ot.wireframe,ge.side=ot.shadowSide!=null?ot.shadowSide:q[ot.side],ge.clipShadows=ot.clipShadows,ge.clippingPlanes=ot.clippingPlanes,ge.clipIntersection=ot.clipIntersection,ge.wireframeLinewidth=ot.wireframeLinewidth,ge.linewidth=ot.linewidth,kt&&ge.isMeshDistanceMaterial&&(ge.referencePosition.copy(ee),ge.nearDistance=$t,ge.farDistance=Yt),ge}function s($,ot,kt,ee){if($.visible!==!1){if($.layers.test(ot.layers)&&($.isMesh||$.isLine||$.isPoints)&&$.castShadow&&(!$.frustumCulled||l.intersectsObject($))){$.modelViewMatrix.multiplyMatrices(kt.matrixWorldInverse,$.matrixWorld);var $t=e.update($),Yt=$.material;if(Array.isArray(Yt))for(var Te=$t.groups,ge=0,De=Te.length;ge<De;ge++){var be=Te[ge],ae=Yt[be.materialIndex];ae&&ae.visible&&(ae=n($,ae,ee,A,kt.near,kt.far),t.renderBufferDirect(kt,null,$t,ae,$,be))}else Yt.visible&&(ae=n($,Yt,ee,A,kt.near,kt.far),t.renderBufferDirect(kt,null,$t,ae,$,null))}for($=$.children,$t=0,Yt=$.length;$t<Yt;$t++)s($[$t],ot,kt,ee)}}var l=new E,d=new c,p=new o,_=new o(i,i),T=new u,A=new u,L=Array(4),B=Array(4),H={},q={0:1,1:0,2:2},J=[new u(1,0,0),new u(-1,0,0),new u(0,0,1),new u(0,0,-1),new u(0,1,0),new u(0,-1,0)],rt=[new u(0,1,0),new u(0,1,0),new u(0,1,0),new u(0,1,0),new u(0,0,1),new u(0,0,-1)],xt=[new v,new v,new v,new v,new v,new v];for(i=0;i!==4;++i){var gt=(i&1)!==0,Ct=(i&2)!==0,wt=new se({depthPacking:3201,morphTargets:gt,skinning:Ct});L[i]=wt,gt=new te({morphTargets:gt,skinning:Ct}),B[i]=gt}var Vt=this;this.enabled=!1,this.autoUpdate=!0,this.needsUpdate=!1,this.type=1,this.render=function($,ot,kt){if(Vt.enabled!==!1&&(Vt.autoUpdate!==!1||Vt.needsUpdate!==!1)&&$.length!==0){var ee=t.state;ee.disable(3042),ee.buffers.color.setClear(1,1,1,1),ee.buffers.depth.setTest(!0),ee.setScissorTest(!1);for(var $t,Yt=0,Te=$.length;Yt<Te;Yt++){var ge=$[Yt];$t=ge.shadow;var De=ge&&ge.isPointLight;if($t!==void 0){var be=$t.camera;if(p.copy($t.mapSize),p.min(_),De){var ae=p.x,We=p.y;xt[0].set(2*ae,We,ae,We),xt[1].set(0,We,ae,We),xt[2].set(3*ae,We,ae,We),xt[3].set(ae,We,ae,We),xt[4].set(3*ae,0,ae,We),xt[5].set(ae,0,ae,We),p.x*=4,p.y*=2}for($t.map===null&&($t.map=new S(p.x,p.y,{minFilter:1003,magFilter:1003,format:1023}),$t.map.texture.name=ge.name+".shadowMap",be.updateProjectionMatrix()),$t.isSpotLightShadow&&$t.update(ge),ae=$t.map,We=$t.matrix,A.setFromMatrixPosition(ge.matrixWorld),be.position.copy(A),De?($t=6,We.makeTranslation(-A.x,-A.y,-A.z)):($t=1,T.setFromMatrixPosition(ge.target.matrixWorld),be.lookAt(T),be.updateMatrixWorld(),We.set(.5,0,0,.5,0,.5,0,.5,0,0,.5,.5,0,0,0,1),We.multiply(be.projectionMatrix),We.multiply(be.matrixWorldInverse)),t.setRenderTarget(ae),t.clear(),ge=0;ge<$t;ge++)De&&(T.copy(be.position),T.add(J[ge]),be.up.copy(rt[ge]),be.lookAt(T),be.updateMatrixWorld(),ee.viewport(xt[ge])),d.multiplyMatrices(be.projectionMatrix,be.matrixWorldInverse),l.setFromMatrix(d),s(ot,kt,be,De)}}Vt.needsUpdate=!1}}}function ue(t,e,i,n){function s(Ht,Ye,ei){var Wi=new Uint8Array(4),Ae=t.createTexture();for(t.bindTexture(Ht,Ae),t.texParameteri(Ht,10241,9728),t.texParameteri(Ht,10240,9728),Ht=0;Ht<ei;Ht++)t.texImage2D(Ye+Ht,0,6408,1,1,0,6408,5121,Wi);return Ae}function l(Ht,Ye){xt[Ht]=1,gt[Ht]===0&&(t.enableVertexAttribArray(Ht),gt[Ht]=1),Ct[Ht]!==Ye&&((n.isWebGL2?t:e.get("ANGLE_instanced_arrays"))[n.isWebGL2?"vertexAttribDivisor":"vertexAttribDivisorANGLE"](Ht,Ye),Ct[Ht]=Ye)}function d(Ht){wt[Ht]!==!0&&(t.enable(Ht),wt[Ht]=!0)}function p(Ht){wt[Ht]!==!1&&(t.disable(Ht),wt[Ht]=!1)}function _(Ht,Ye,ei,Wi,Ae,Xe,ri,Li){if(Ht===0)ot&&(p(3042),ot=!1);else if(ot||(d(3042),ot=!0),Ht!==5){if(Ht!==kt||Li!==be){if((ee!==100||Te!==100)&&(t.blendEquation(32774),Te=ee=100),Li)switch(Ht){case 1:t.blendFuncSeparate(1,771,1,771);break;case 2:t.blendFunc(1,1);break;case 3:t.blendFuncSeparate(0,0,769,771);break;case 4:t.blendFuncSeparate(0,768,0,770);break;default:}else switch(Ht){case 1:t.blendFuncSeparate(770,771,1,771);break;case 2:t.blendFunc(770,1);break;case 3:t.blendFunc(0,769);break;case 4:t.blendFunc(0,768);break;default:}De=ge=Yt=$t=null,kt=Ht,be=Li}}else Ae=Ae||Ye,Xe=Xe||ei,ri=ri||Wi,(Ye!==ee||Ae!==Te)&&(t.blendEquationSeparate(i.convert(Ye),i.convert(Ae)),ee=Ye,Te=Ae),(ei!==$t||Wi!==Yt||Xe!==ge||ri!==De)&&(t.blendFuncSeparate(i.convert(ei),i.convert(Wi),i.convert(Xe),i.convert(ri)),$t=ei,Yt=Wi,ge=Xe,De=ri),kt=Ht,be=null}function T(Ht){ae!==Ht&&(Ht?t.frontFace(2304):t.frontFace(2305),ae=Ht)}function A(Ht){Ht!==0?(d(2884),Ht!==We&&(Ht===1?t.cullFace(1029):Ht===2?t.cullFace(1028):t.cullFace(1032))):p(2884),We=Ht}function L(Ht,Ye,ei){Ht?(d(32823),(fi!==Ye||Cn!==ei)&&(t.polygonOffset(Ye,ei),fi=Ye,Cn=ei)):p(32823)}function B(Ht){Ht===void 0&&(Ht=33984+_n-1),Vi!==Ht&&(t.activeTexture(Ht),Vi=Ht)}var H=new function(){var Ht=!1,Ye=new v,ei=null,Wi=new v(0,0,0,0);return{setMask:function(Ae){ei===Ae||Ht||(t.colorMask(Ae,Ae,Ae,Ae),ei=Ae)},setLocked:function(Ae){Ht=Ae},setClear:function(Ae,Xe,ri,Li,Ai){Ai===!0&&(Ae*=Li,Xe*=Li,ri*=Li),Ye.set(Ae,Xe,ri,Li),Wi.equals(Ye)===!1&&(t.clearColor(Ae,Xe,ri,Li),Wi.copy(Ye))},reset:function(){Ht=!1,ei=null,Wi.set(-1,0,0,0)}}},q=new function(){var Ht=!1,Ye=null,ei=null,Wi=null;return{setTest:function(Ae){Ae?d(2929):p(2929)},setMask:function(Ae){Ye===Ae||Ht||(t.depthMask(Ae),Ye=Ae)},setFunc:function(Ae){if(ei!==Ae){if(Ae)switch(Ae){case 0:t.depthFunc(512);break;case 1:t.depthFunc(519);break;case 2:t.depthFunc(513);break;case 3:t.depthFunc(515);break;case 4:t.depthFunc(514);break;case 5:t.depthFunc(518);break;case 6:t.depthFunc(516);break;case 7:t.depthFunc(517);break;default:t.depthFunc(515)}else t.depthFunc(515);ei=Ae}},setLocked:function(Ae){Ht=Ae},setClear:function(Ae){Wi!==Ae&&(t.clearDepth(Ae),Wi=Ae)},reset:function(){Ht=!1,Wi=ei=Ye=null}}},J=new function(){var Ht=!1,Ye=null,ei=null,Wi=null,Ae=null,Xe=null,ri=null,Li=null,Ai=null;return{setTest:function(ne){ne?d(2960):p(2960)},setMask:function(ne){Ye===ne||Ht||(t.stencilMask(ne),Ye=ne)},setFunc:function(ne,ii,Je){(ei!==ne||Wi!==ii||Ae!==Je)&&(t.stencilFunc(ne,ii,Je),ei=ne,Wi=ii,Ae=Je)},setOp:function(ne,ii,Je){(Xe!==ne||ri!==ii||Li!==Je)&&(t.stencilOp(ne,ii,Je),Xe=ne,ri=ii,Li=Je)},setLocked:function(ne){Ht=ne},setClear:function(ne){Ai!==ne&&(t.clearStencil(ne),Ai=ne)},reset:function(){Ht=!1,Ai=Li=ri=Xe=Ae=Wi=ei=Ye=null}}},rt=t.getParameter(34921),xt=new Uint8Array(rt),gt=new Uint8Array(rt),Ct=new Uint8Array(rt),wt={},Vt=null,$=null,ot=null,kt=null,ee=null,$t=null,Yt=null,Te=null,ge=null,De=null,be=!1,ae=null,We=null,Qe=null,fi=null,Cn=null,_n=t.getParameter(35661),qi=!1;rt=0,rt=t.getParameter(7938),rt.indexOf("WebGL")!==-1?(rt=parseFloat(/^WebGL ([0-9])/.exec(rt)[1]),qi=1<=rt):rt.indexOf("OpenGL ES")!==-1&&(rt=parseFloat(/^OpenGL ES ([0-9])/.exec(rt)[1]),qi=2<=rt);var Vi=null,on={},An=new v,Ce=new v,ti={};return ti[3553]=s(3553,3553,1),ti[34067]=s(34067,34069,6),H.setClear(0,0,0,1),q.setClear(1),J.setClear(0),d(2929),q.setFunc(3),T(!1),A(1),d(2884),_(0),{buffers:{color:H,depth:q,stencil:J},initAttributes:function(){for(var Ht=0,Ye=xt.length;Ht<Ye;Ht++)xt[Ht]=0},enableAttribute:function(Ht){l(Ht,0)},enableAttributeAndDivisor:l,disableUnusedAttributes:function(){for(var Ht=0,Ye=gt.length;Ht!==Ye;++Ht)gt[Ht]!==xt[Ht]&&(t.disableVertexAttribArray(Ht),gt[Ht]=0)},enable:d,disable:p,getCompressedTextureFormats:function(){if(Vt===null&&(Vt=[],e.get("WEBGL_compressed_texture_pvrtc")||e.get("WEBGL_compressed_texture_s3tc")||e.get("WEBGL_compressed_texture_etc1")||e.get("WEBGL_compressed_texture_astc")))for(var Ht=t.getParameter(34467),Ye=0;Ye<Ht.length;Ye++)Vt.push(Ht[Ye]);return Vt},useProgram:function(Ht){return $!==Ht?(t.useProgram(Ht),$=Ht,!0):!1},setBlending:_,setMaterial:function(Ht,Ye){Ht.side===2?p(2884):d(2884);var ei=Ht.side===1;Ye&&(ei=!ei),T(ei),Ht.blending===1&&Ht.transparent===!1?_(0):_(Ht.blending,Ht.blendEquation,Ht.blendSrc,Ht.blendDst,Ht.blendEquationAlpha,Ht.blendSrcAlpha,Ht.blendDstAlpha,Ht.premultipliedAlpha),q.setFunc(Ht.depthFunc),q.setTest(Ht.depthTest),q.setMask(Ht.depthWrite),H.setMask(Ht.colorWrite),L(Ht.polygonOffset,Ht.polygonOffsetFactor,Ht.polygonOffsetUnits)},setFlipSided:T,setCullFace:A,setLineWidth:function(Ht){Ht!==Qe&&(qi&&t.lineWidth(Ht),Qe=Ht)},setPolygonOffset:L,setScissorTest:function(Ht){Ht?d(3089):p(3089)},activeTexture:B,bindTexture:function(Ht,Ye){Vi===null&&B();var ei=on[Vi];ei===void 0&&(ei={type:void 0,texture:void 0},on[Vi]=ei),(ei.type!==Ht||ei.texture!==Ye)&&(t.bindTexture(Ht,Ye||ti[Ht]),ei.type=Ht,ei.texture=Ye)},compressedTexImage2D:function(){try{t.compressedTexImage2D.apply(t,arguments)}catch{}},texImage2D:function(){try{t.texImage2D.apply(t,arguments)}catch{}},texImage3D:function(){try{t.texImage3D.apply(t,arguments)}catch{}},scissor:function(Ht){An.equals(Ht)===!1&&(t.scissor(Ht.x,Ht.y,Ht.z,Ht.w),An.copy(Ht))},viewport:function(Ht){Ce.equals(Ht)===!1&&(t.viewport(Ht.x,Ht.y,Ht.z,Ht.w),Ce.copy(Ht))},reset:function(){for(var Ht=0;Ht<gt.length;Ht++)gt[Ht]===1&&(t.disableVertexAttribArray(Ht),gt[Ht]=0);wt={},Vi=Vt=null,on={},We=ae=kt=$=null,H.reset(),q.reset(),J.reset()}}}function je(t,e,i,n,s,l,d){function p($,ot){if($.width>ot||$.height>ot){if("data"in $)return;ot/=Math.max($.width,$.height);var kt=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");return kt.width=Math.floor($.width*ot),kt.height=Math.floor($.height*ot),kt.getContext("2d").drawImage($,0,0,$.width,$.height,0,0,kt.width,kt.height),kt}return $}function _($){return di.isPowerOfTwo($.width)&&di.isPowerOfTwo($.height)}function T($,ot){return $.generateMipmaps&&ot&&$.minFilter!==1003&&$.minFilter!==1006}function A($,ot,kt,ee){t.generateMipmap($),n.get(ot).__maxMipLevel=Math.log(Math.max(kt,ee))*Math.LOG2E}function L($,ot){if(!s.isWebGL2)return $;if($===6403){if(ot===5126)return 33326;if(ot===5131)return 33325;if(ot===5121)return 33321}if($===6407){if(ot===5126)return 34837;if(ot===5131)return 34843;if(ot===5121)return 32849}if($===6408){if(ot===5126)return 34836;if(ot===5131)return 34842;if(ot===5121)return 32856}return $}function B($){return $===1003||$===1004||$===1005?9728:9729}function H($){$=$.target,$.removeEventListener("dispose",H);t:{var ot=n.get($);if($.image&&ot.__image__webglTextureCube)t.deleteTexture(ot.__image__webglTextureCube);else{if(ot.__webglInit===void 0)break t;t.deleteTexture(ot.__webglTexture)}n.remove($)}$.isVideoTexture&&delete wt[$.id],d.memory.textures--}function q($){$=$.target,$.removeEventListener("dispose",q);var ot=n.get($),kt=n.get($.texture);if($){if(kt.__webglTexture!==void 0&&t.deleteTexture(kt.__webglTexture),$.depthTexture&&$.depthTexture.dispose(),$.isWebGLRenderTargetCube)for(kt=0;6>kt;kt++)t.deleteFramebuffer(ot.__webglFramebuffer[kt]),ot.__webglDepthbuffer&&t.deleteRenderbuffer(ot.__webglDepthbuffer[kt]);else t.deleteFramebuffer(ot.__webglFramebuffer),ot.__webglDepthbuffer&&t.deleteRenderbuffer(ot.__webglDepthbuffer);n.remove($.texture),n.remove($)}d.memory.textures--}function J($,ot){var kt=n.get($);if($.isVideoTexture){var ee=$.id,$t=d.render.frame;wt[ee]!==$t&&(wt[ee]=$t,$.update())}if(0<$.version&&kt.__version!==$.version&&(ee=$.image,ee!==void 0)){if(ee.complete!==!1){xt(kt,$,ot);return}}i.activeTexture(33984+ot),i.bindTexture(3553,kt.__webglTexture)}function rt($,ot,kt){kt?(t.texParameteri($,10242,l.convert(ot.wrapS)),t.texParameteri($,10243,l.convert(ot.wrapT)),t.texParameteri($,10240,l.convert(ot.magFilter)),t.texParameteri($,10241,l.convert(ot.minFilter))):(t.texParameteri($,10242,33071),t.texParameteri($,10243,33071),ot.wrapS===1001&&ot.wrapT,t.texParameteri($,10240,B(ot.magFilter)),t.texParameteri($,10241,B(ot.minFilter)),ot.minFilter!==1003&&ot.minFilter),!(kt=e.get("EXT_texture_filter_anisotropic"))||ot.type===1015&&e.get("OES_texture_float_linear")===null||ot.type===1016&&(s.isWebGL2||e.get("OES_texture_half_float_linear"))===null||!(1<ot.anisotropy||n.get(ot).__currentAnisotropy)||(t.texParameterf($,kt.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(ot.anisotropy,s.getMaxAnisotropy())),n.get(ot).__currentAnisotropy=ot.anisotropy)}function xt($,ot,kt){var ee=ot.isDataTexture3D?32879:3553;$.__webglInit===void 0&&($.__webglInit=!0,ot.addEventListener("dispose",H),$.__webglTexture=t.createTexture(),d.memory.textures++),i.activeTexture(33984+kt),i.bindTexture(ee,$.__webglTexture),t.pixelStorei(37440,ot.flipY),t.pixelStorei(37441,ot.premultiplyAlpha),t.pixelStorei(3317,ot.unpackAlignment),kt=p(ot.image,s.maxTextureSize);var $t=s.isWebGL2?!1:ot.wrapS!==1001||ot.wrapT!==1001||ot.minFilter!==1003&&ot.minFilter!==1006;$t&&_(kt)===!1&&(kt instanceof HTMLImageElement||kt instanceof HTMLCanvasElement||kt instanceof ImageBitmap)&&(Vt===void 0&&(Vt=document.createElementNS("http://www.w3.org/1999/xhtml","canvas")),Vt.width=di.floorPowerOfTwo(kt.width),Vt.height=di.floorPowerOfTwo(kt.height),Vt.getContext("2d").drawImage(kt,0,0,Vt.width,Vt.height),kt=Vt),$t=_(kt);var Yt=l.convert(ot.format),Te=l.convert(ot.type),ge=L(Yt,Te);rt(ee,ot,$t);var De=ot.mipmaps;if(ot.isDepthTexture){if(ge=6402,ot.type===1015){if(!s.isWebGL2)throw Error("Float Depth Texture only supported in WebGL2.0");ge=36012}else s.isWebGL2&&(ge=33189);ot.format===1026&&ge===6402&&ot.type!==1012&&ot.type!==1014&&(ot.type=1012,Te=l.convert(ot.type)),ot.format===1027&&(ge=34041,ot.type!==1020&&(ot.type=1020,Te=l.convert(ot.type))),i.texImage2D(3553,0,ge,kt.width,kt.height,0,Yt,Te,null)}else if(ot.isDataTexture)if(0<De.length&&$t){for(var be=0,ae=De.length;be<ae;be++)ee=De[be],i.texImage2D(3553,be,ge,ee.width,ee.height,0,Yt,Te,ee.data);ot.generateMipmaps=!1,$.__maxMipLevel=De.length-1}else i.texImage2D(3553,0,ge,kt.width,kt.height,0,Yt,Te,kt.data),$.__maxMipLevel=0;else if(ot.isCompressedTexture){for(be=0,ae=De.length;be<ae;be++)ee=De[be],ot.format!==1023&&ot.format!==1022?-1<i.getCompressedTextureFormats().indexOf(Yt)&&i.compressedTexImage2D(3553,be,ge,ee.width,ee.height,0,ee.data):i.texImage2D(3553,be,ge,ee.width,ee.height,0,Yt,Te,ee.data);$.__maxMipLevel=De.length-1}else if(ot.isDataTexture3D)i.texImage3D(32879,0,ge,kt.width,kt.height,kt.depth,0,Yt,Te,kt.data),$.__maxMipLevel=0;else if(0<De.length&&$t){for(be=0,ae=De.length;be<ae;be++)ee=De[be],i.texImage2D(3553,be,ge,Yt,Te,ee);ot.generateMipmaps=!1,$.__maxMipLevel=De.length-1}else i.texImage2D(3553,0,ge,Yt,Te,kt),$.__maxMipLevel=0;T(ot,$t)&&A(3553,ot,kt.width,kt.height),$.__version=ot.version,ot.onUpdate&&ot.onUpdate(ot)}function gt($,ot,kt,ee){var $t=l.convert(ot.texture.format),Yt=l.convert(ot.texture.type),Te=L($t,Yt);i.texImage2D(ee,0,Te,ot.width,ot.height,0,$t,Yt,null),t.bindFramebuffer(36160,$),t.framebufferTexture2D(36160,kt,ee,n.get(ot.texture).__webglTexture,0),t.bindFramebuffer(36160,null)}function Ct($,ot){t.bindRenderbuffer(36161,$),ot.depthBuffer&&!ot.stencilBuffer?(t.renderbufferStorage(36161,33189,ot.width,ot.height),t.framebufferRenderbuffer(36160,36096,36161,$)):ot.depthBuffer&&ot.stencilBuffer?(t.renderbufferStorage(36161,34041,ot.width,ot.height),t.framebufferRenderbuffer(36160,33306,36161,$)):t.renderbufferStorage(36161,32854,ot.width,ot.height),t.bindRenderbuffer(36161,null)}var wt={},Vt;this.setTexture2D=J,this.setTexture3D=function($,ot){var kt=n.get($);0<$.version&&kt.__version!==$.version?xt(kt,$,ot):(i.activeTexture(33984+ot),i.bindTexture(32879,kt.__webglTexture))},this.setTextureCube=function($,ot){var kt=n.get($);if($.image.length===6)if(0<$.version&&kt.__version!==$.version){kt.__image__webglTextureCube||($.addEventListener("dispose",H),kt.__image__webglTextureCube=t.createTexture(),d.memory.textures++),i.activeTexture(33984+ot),i.bindTexture(34067,kt.__image__webglTextureCube),t.pixelStorei(37440,$.flipY),ot=$&&$.isCompressedTexture;for(var ee=$.image[0]&&$.image[0].isDataTexture,$t=[],Yt=0;6>Yt;Yt++)$t[Yt]=ot||ee?ee?$.image[Yt].image:$.image[Yt]:p($.image[Yt],s.maxCubemapSize);var Te=$t[0],ge=_(Te),De=l.convert($.format),be=l.convert($.type),ae=L(De,be);for(rt(34067,$,ge),Yt=0;6>Yt;Yt++)if(ot)for(var We,Qe=$t[Yt].mipmaps,fi=0,Cn=Qe.length;fi<Cn;fi++)We=Qe[fi],$.format!==1023&&$.format!==1022?-1<i.getCompressedTextureFormats().indexOf(De)&&i.compressedTexImage2D(34069+Yt,fi,ae,We.width,We.height,0,We.data):i.texImage2D(34069+Yt,fi,ae,We.width,We.height,0,De,be,We.data);else ee?i.texImage2D(34069+Yt,0,ae,$t[Yt].width,$t[Yt].height,0,De,be,$t[Yt].data):i.texImage2D(34069+Yt,0,ae,De,be,$t[Yt]);kt.__maxMipLevel=ot?Qe.length-1:0,T($,ge)&&A(34067,$,Te.width,Te.height),kt.__version=$.version,$.onUpdate&&$.onUpdate($)}else i.activeTexture(33984+ot),i.bindTexture(34067,kt.__image__webglTextureCube)},this.setTextureCubeDynamic=function($,ot){i.activeTexture(33984+ot),i.bindTexture(34067,n.get($).__webglTexture)},this.setupRenderTarget=function($){var ot=n.get($),kt=n.get($.texture);$.addEventListener("dispose",q),kt.__webglTexture=t.createTexture(),d.memory.textures++;var ee=$.isWebGLRenderTargetCube===!0,$t=_($);if(ee){ot.__webglFramebuffer=[];for(var Yt=0;6>Yt;Yt++)ot.__webglFramebuffer[Yt]=t.createFramebuffer()}else ot.__webglFramebuffer=t.createFramebuffer();if(ee){for(i.bindTexture(34067,kt.__webglTexture),rt(34067,$.texture,$t),Yt=0;6>Yt;Yt++)gt(ot.__webglFramebuffer[Yt],$,36064,34069+Yt);T($.texture,$t)&&A(34067,$.texture,$.width,$.height),i.bindTexture(34067,null)}else i.bindTexture(3553,kt.__webglTexture),rt(3553,$.texture,$t),gt(ot.__webglFramebuffer,$,36064,3553),T($.texture,$t)&&A(3553,$.texture,$.width,$.height),i.bindTexture(3553,null);if($.depthBuffer){if(ot=n.get($),kt=$.isWebGLRenderTargetCube===!0,$.depthTexture){if(kt)throw Error("target.depthTexture not supported in Cube render targets");if($&&$.isWebGLRenderTargetCube)throw Error("Depth Texture with cube render targets is not supported");if(t.bindFramebuffer(36160,ot.__webglFramebuffer),!$.depthTexture||!$.depthTexture.isDepthTexture)throw Error("renderTarget.depthTexture must be an instance of THREE.DepthTexture");if(n.get($.depthTexture).__webglTexture&&$.depthTexture.image.width===$.width&&$.depthTexture.image.height===$.height||($.depthTexture.image.width=$.width,$.depthTexture.image.height=$.height,$.depthTexture.needsUpdate=!0),J($.depthTexture,0),ot=n.get($.depthTexture).__webglTexture,$.depthTexture.format===1026)t.framebufferTexture2D(36160,36096,3553,ot,0);else if($.depthTexture.format===1027)t.framebufferTexture2D(36160,33306,3553,ot,0);else throw Error("Unknown depthTexture format")}else if(kt)for(ot.__webglDepthbuffer=[],kt=0;6>kt;kt++)t.bindFramebuffer(36160,ot.__webglFramebuffer[kt]),ot.__webglDepthbuffer[kt]=t.createRenderbuffer(),Ct(ot.__webglDepthbuffer[kt],$);else t.bindFramebuffer(36160,ot.__webglFramebuffer),ot.__webglDepthbuffer=t.createRenderbuffer(),Ct(ot.__webglDepthbuffer,$);t.bindFramebuffer(36160,null)}},this.updateRenderTargetMipmap=function($){var ot=$.texture,kt=_($);if(T(ot,kt)){kt=$.isWebGLRenderTargetCube?34067:3553;var ee=n.get(ot).__webglTexture;i.bindTexture(kt,ee),A(kt,ot,$.width,$.height),i.bindTexture(kt,null)}}}function He(t,e,i){return{convert:function(n){if(n===1e3)return 10497;if(n===1001)return 33071;if(n===1002)return 33648;if(n===1003)return 9728;if(n===1004)return 9984;if(n===1005)return 9986;if(n===1006)return 9729;if(n===1007)return 9985;if(n===1008)return 9987;if(n===1009)return 5121;if(n===1017)return 32819;if(n===1018)return 32820;if(n===1019)return 33635;if(n===1010)return 5120;if(n===1011)return 5122;if(n===1012)return 5123;if(n===1013)return 5124;if(n===1014)return 5125;if(n===1015)return 5126;if(n===1016){if(i.isWebGL2)return 5131;var s=e.get("OES_texture_half_float");if(s!==null)return s.HALF_FLOAT_OES}if(n===1021)return 6406;if(n===1022)return 6407;if(n===1023)return 6408;if(n===1024)return 6409;if(n===1025)return 6410;if(n===1026)return 6402;if(n===1027)return 34041;if(n===1028)return 6403;if(n===100)return 32774;if(n===101)return 32778;if(n===102)return 32779;if(n===200)return 0;if(n===201)return 1;if(n===202)return 768;if(n===203)return 769;if(n===204)return 770;if(n===205)return 771;if(n===206)return 772;if(n===207)return 773;if(n===208)return 774;if(n===209)return 775;if(n===210)return 776;if((n===33776||n===33777||n===33778||n===33779)&&(s=e.get("WEBGL_compressed_texture_s3tc"),s!==null)){if(n===33776)return s.COMPRESSED_RGB_S3TC_DXT1_EXT;if(n===33777)return s.COMPRESSED_RGBA_S3TC_DXT1_EXT;if(n===33778)return s.COMPRESSED_RGBA_S3TC_DXT3_EXT;if(n===33779)return s.COMPRESSED_RGBA_S3TC_DXT5_EXT}if((n===35840||n===35841||n===35842||n===35843)&&(s=e.get("WEBGL_compressed_texture_pvrtc"),s!==null)){if(n===35840)return s.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;if(n===35841)return s.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;if(n===35842)return s.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;if(n===35843)return s.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG}if(n===36196&&(s=e.get("WEBGL_compressed_texture_etc1"),s!==null))return s.COMPRESSED_RGB_ETC1_WEBGL;if((n===37808||n===37809||n===37810||n===37811||n===37812||n===37813||n===37814||n===37815||n===37816||n===37817||n===37818||n===37819||n===37820||n===37821)&&(s=e.get("WEBGL_compressed_texture_astc"),s!==null))return n;if(n===103||n===104){if(i.isWebGL2){if(n===103)return 32775;if(n===104)return 32776}if(s=e.get("EXT_blend_minmax"),s!==null){if(n===103)return s.MIN_EXT;if(n===104)return s.MAX_EXT}}if(n===1020){if(i.isWebGL2)return 34042;if(s=e.get("WEBGL_depth_texture"),s!==null)return s.UNSIGNED_INT_24_8_WEBGL}return 0}}}function ci(){F.call(this),this.type="Group"}function Be(){F.call(this),this.type="Camera",this.matrixWorldInverse=new c,this.projectionMatrix=new c,this.projectionMatrixInverse=new c}function _e(t,e,i,n){Be.call(this),this.type="PerspectiveCamera",this.fov=t!==void 0?t:50,this.zoom=1,this.near=i!==void 0?i:.1,this.far=n!==void 0?n:2e3,this.focus=10,this.aspect=e!==void 0?e:1,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}function Fe(t){_e.call(this),this.cameras=t||[]}function fe(t,e,i){ls.setFromMatrixPosition(e.matrixWorld),wr.setFromMatrixPosition(i.matrixWorld);var n=ls.distanceTo(wr),s=e.projectionMatrix.elements,l=i.projectionMatrix.elements,d=s[14]/(s[10]-1);i=s[14]/(s[10]+1);var p=(s[9]+1)/s[5],_=(s[9]-1)/s[5],T=(s[8]-1)/s[0],A=(l[8]+1)/l[0];s=d*T,l=d*A,A=n/(-T+A),T=A*-T,e.matrixWorld.decompose(t.position,t.quaternion,t.scale),t.translateX(T),t.translateZ(A),t.matrixWorld.compose(t.position,t.quaternion,t.scale),t.matrixWorldInverse.getInverse(t.matrixWorld),e=d+A,d=i+A,t.projectionMatrix.makePerspective(s-T,l+(n-T),p*i/d*e,_*i/d*e,e,d)}function mi(t){function e(){return s!==null&&s.isPresenting===!0}function i(){if(e()){var $=s.getEyeParameters("left"),ot=$.renderWidth*A;$=$.renderHeight*A,Ct=t.getPixelRatio(),gt=t.getSize(),t.setDrawingBufferSize(2*ot,$,1),Vt.start()}else n.enabled&&t.setDrawingBufferSize(gt.width,gt.height,Ct),Vt.stop()}var n=this,s=null,l=null,d=null,p=[],_=new c,T=new c,A=1,L="stage";typeof window<"u"&&"VRFrameData"in window&&(l=new window.VRFrameData,window.addEventListener("vrdisplaypresentchange",i,!1));var B=new c,H=new f,q=new u,J=new _e;J.bounds=new v(0,0,.5,1),J.layers.enable(1);var rt=new _e;rt.bounds=new v(.5,0,.5,1),rt.layers.enable(2);var xt=new Fe([J,rt]);xt.layers.enable(1),xt.layers.enable(2);var gt,Ct,wt=[];this.enabled=!1,this.getController=function($){var ot=p[$];return ot===void 0&&(ot=new ci,ot.matrixAutoUpdate=!1,ot.visible=!1,p[$]=ot),ot},this.getDevice=function(){return s},this.setDevice=function($){$!==void 0&&(s=$),Vt.setContext($)},this.setFramebufferScaleFactor=function($){A=$},this.setFrameOfReferenceType=function($){L=$},this.setPoseTarget=function($){$!==void 0&&(d=$)},this.getCamera=function($){var ot=L==="stage"?1.6:0;if(s===null)return $.position.set(0,ot,0),$;if(s.depthNear=$.near,s.depthFar=$.far,s.getFrameData(l),L==="stage"){var kt=s.stageParameters;kt?_.fromArray(kt.sittingToStandingTransform):_.makeTranslation(0,ot,0)}if(ot=l.pose,kt=d!==null?d:$,kt.matrix.copy(_),kt.matrix.decompose(kt.position,kt.quaternion,kt.scale),ot.orientation!==null&&(H.fromArray(ot.orientation),kt.quaternion.multiply(H)),ot.position!==null&&(H.setFromRotationMatrix(_),q.fromArray(ot.position),q.applyQuaternion(H),kt.position.add(q)),kt.updateMatrixWorld(),s.isPresenting===!1)return $;J.near=$.near,rt.near=$.near,J.far=$.far,rt.far=$.far,J.matrixWorldInverse.fromArray(l.leftViewMatrix),rt.matrixWorldInverse.fromArray(l.rightViewMatrix),T.getInverse(_),L==="stage"&&(J.matrixWorldInverse.multiply(T),rt.matrixWorldInverse.multiply(T)),$=kt.parent,$!==null&&(B.getInverse($.matrixWorld),J.matrixWorldInverse.multiply(B),rt.matrixWorldInverse.multiply(B)),J.matrixWorld.getInverse(J.matrixWorldInverse),rt.matrixWorld.getInverse(rt.matrixWorldInverse),J.projectionMatrix.fromArray(l.leftProjectionMatrix),rt.projectionMatrix.fromArray(l.rightProjectionMatrix),fe(xt,J,rt),$=s.getLayers(),$.length&&($=$[0],$.leftBounds!==null&&$.leftBounds.length===4&&J.bounds.fromArray($.leftBounds),$.rightBounds!==null&&$.rightBounds.length===4&&rt.bounds.fromArray($.rightBounds));t:for($=0;$<p.length;$++){ot=p[$];e:{kt=$;for(var ee=navigator.getGamepads&&navigator.getGamepads(),$t=0,Yt=0,Te=ee.length;$t<Te;$t++){var ge=ee[$t];if(ge&&(ge.id==="Daydream Controller"||ge.id==="Gear VR Controller"||ge.id==="Oculus Go Controller"||ge.id==="OpenVR Gamepad"||ge.id.startsWith("Oculus Touch")||ge.id.startsWith("Spatial Controller"))){if(Yt===kt){kt=ge;break e}Yt++}}kt=void 0}if(kt!==void 0&&kt.pose!==void 0){if(kt.pose===null)break t;ee=kt.pose,ee.hasPosition===!1&&ot.position.set(.2,-.6,-.05),ee.position!==null&&ot.position.fromArray(ee.position),ee.orientation!==null&&ot.quaternion.fromArray(ee.orientation),ot.matrix.compose(ot.position,ot.quaternion,ot.scale),ot.matrix.premultiply(_),ot.matrix.decompose(ot.position,ot.quaternion,ot.scale),ot.matrixWorldNeedsUpdate=!0,ot.visible=!0,ee=kt.id==="Daydream Controller"?0:1,wt[$]!==kt.buttons[ee].pressed&&(wt[$]=kt.buttons[ee].pressed,wt[$]===!0?ot.dispatchEvent({type:"selectstart"}):(ot.dispatchEvent({type:"selectend"}),ot.dispatchEvent({type:"select"})))}else ot.visible=!1}return xt},this.getStandingMatrix=function(){return _},this.isPresenting=e;var Vt=new w;this.setAnimationLoop=function($){Vt.setAnimationLoop($)},this.submitFrame=function(){e()&&s.submitFrame()},this.dispose=function(){typeof window<"u"&&window.removeEventListener("vrdisplaypresentchange",i)}}function Le(t){function e(){return p!==null&&T!==null}function i(Ct){var wt=B[H.indexOf(Ct.inputSource)];wt&&wt.dispatchEvent({type:Ct.type})}function n(){t.setFramebuffer(null),gt.stop()}function s(Ct,wt){wt===null?Ct.matrixWorld.copy(Ct.matrix):Ct.matrixWorld.multiplyMatrices(wt.matrixWorld,Ct.matrix),Ct.matrixWorldInverse.getInverse(Ct.matrixWorld)}var l=t.context,d=null,p=null,_=1,T=null,A="stage",L=null,B=[],H=[],q=new _e;q.layers.enable(1),q.viewport=new v;var J=new _e;J.layers.enable(2),J.viewport=new v;var rt=new Fe([q,J]);rt.layers.enable(1),rt.layers.enable(2),this.enabled=!1,this.getController=function(Ct){var wt=B[Ct];return wt===void 0&&(wt=new ci,wt.matrixAutoUpdate=!1,wt.visible=!1,B[Ct]=wt),wt},this.getDevice=function(){return d},this.setDevice=function(Ct){Ct!==void 0&&(d=Ct),Ct instanceof XRDevice&&l.setCompatibleXRDevice(Ct)},this.setFramebufferScaleFactor=function(Ct){_=Ct},this.setFrameOfReferenceType=function(Ct){A=Ct},this.setSession=function(Ct){p=Ct,p!==null&&(p.addEventListener("select",i),p.addEventListener("selectstart",i),p.addEventListener("selectend",i),p.addEventListener("end",n),p.baseLayer=new XRWebGLLayer(p,l,{framebufferScaleFactor:_}),p.requestFrameOfReference(A).then(function(wt){T=wt,t.setFramebuffer(p.baseLayer.framebuffer),gt.setContext(p),gt.start()}),H=p.getInputSources(),p.addEventListener("inputsourceschange",function(){H=p.getInputSources();for(var wt=0;wt<B.length;wt++)B[wt].userData.inputSource=H[wt]}))},this.getCamera=function(Ct){if(e()){var wt=Ct.parent,Vt=rt.cameras;s(rt,wt);for(var $=0;$<Vt.length;$++)s(Vt[$],wt);for(Ct.matrixWorld.copy(rt.matrixWorld),Ct=Ct.children,$=0,wt=Ct.length;$<wt;$++)Ct[$].updateMatrixWorld(!0);return fe(rt,q,J),rt}return Ct},this.isPresenting=e;var xt=null,gt=new w;gt.setAnimationLoop(function(Ct,wt){if(L=wt.getDevicePose(T),L!==null)for(var Vt=p.baseLayer,$=wt.views,ot=0;ot<$.length;ot++){var kt=$[ot],ee=Vt.getViewport(kt),$t=L.getViewMatrix(kt),Yt=rt.cameras[ot];Yt.matrix.fromArray($t).getInverse(Yt.matrix),Yt.projectionMatrix.fromArray(kt.projectionMatrix),Yt.viewport.set(ee.x,ee.y,ee.width,ee.height),ot===0&&rt.matrix.copy(Yt.matrix)}for(ot=0;ot<B.length;ot++){if(Vt=B[ot],($=H[ot])&&($=wt.getInputPose($,T),$!==null)){"targetRay"in $?Vt.matrix.elements=$.targetRay.transformMatrix:"pointerMatrix"in $&&(Vt.matrix.elements=$.pointerMatrix),Vt.matrix.decompose(Vt.position,Vt.rotation,Vt.scale),Vt.visible=!0;continue}Vt.visible=!1}xt&&xt(Ct)}),this.setAnimationLoop=function(Ct){xt=Ct},this.dispose=function(){},this.getStandingMatrix=function(){return new THREE.Matrix4},this.submitFrame=function(){}}function xe(t){var e;function i(){ii=new Jt(ne),Je=new Qi(ne,ii,t),Je.isWebGL2||(ii.get("WEBGL_depth_texture"),ii.get("OES_texture_float"),ii.get("OES_texture_half_float"),ii.get("OES_texture_half_float_linear"),ii.get("OES_standard_derivatives"),ii.get("OES_element_index_uint"),ii.get("ANGLE_instanced_arrays")),ii.get("OES_texture_float_linear"),In=new He(ne,ii,Je),li=new ue(ne,ii,In,Je),li.scissor(qi.copy(Ye).multiplyScalar(ti)),li.viewport(_n.copy(Ht).multiplyScalar(ti)),xn=new pt,Pn=new at,No=new je(ne,ii,li,Pn,Je,In,xn),Ia=new M(ne),Kh=new jt(ne,Ia,xn),Da=new Kt(Kh,xn),Qh=new ie(ne),Hs=new lt(Yt,ii,Je),El=new Ot,Vs=new he,us=new Di(Yt,li,Da,$),tu=new mn(ne,ii,xn,Je),er=new dt(ne,ii,xn,Je),xn.programs=Hs.programs,Yt.context=ne,Yt.capabilities=Je,Yt.extensions=ii,Yt.properties=Pn,Yt.renderLists=El,Yt.state=li,Yt.info=xn}function n(ft){ft.preventDefault(),Te=!0}function s(){Te=!1,i()}function l(ft){ft=ft.target,ft.removeEventListener("dispose",l),d(ft),Pn.remove(ft)}function d(ft){var Tt=Pn.get(ft).program;ft.program=void 0,Tt!==void 0&&Hs.releaseProgram(Tt)}function p(ft,Tt){ft.render(function(mt){Yt.renderBufferImmediate(mt,Tt)})}function _(ft,Tt,mt){if(ft.visible!==!1){if(ft.layers.test(Tt.layers)){if(ft.isLight)$t.pushLight(ft),ft.castShadow&&$t.pushShadow(ft);else if(ft.isSprite){if(!ft.frustumCulled||Wi.intersectsSprite(ft)){mt&&Ai.setFromMatrixPosition(ft.matrixWorld).applyMatrix4(Li);var Me=Da.update(ft),ze=ft.material;ee.push(ft,Me,ze,Ai.z,null)}}else if(ft.isImmediateRenderObject)mt&&Ai.setFromMatrixPosition(ft.matrixWorld).applyMatrix4(Li),ee.push(ft,null,ft.material,Ai.z,null);else if((ft.isMesh||ft.isLine||ft.isPoints)&&(ft.isSkinnedMesh&&ft.skeleton.update(),!ft.frustumCulled||Wi.intersectsObject(ft)))if(mt&&Ai.setFromMatrixPosition(ft.matrixWorld).applyMatrix4(Li),Me=Da.update(ft),ze=ft.material,Array.isArray(ze))for(var Ve=Me.groups,Se=0,Ke=Ve.length;Se<Ke;Se++){var Oi=Ve[Se],$i=ze[Oi.materialIndex];$i&&$i.visible&&ee.push(ft,Me,$i,Ai.z,Oi)}else ze.visible&&ee.push(ft,Me,ze,Ai.z,null)}for(ft=ft.children,Se=0,Ke=ft.length;Se<Ke;Se++)_(ft[Se],Tt,mt)}}function T(ft,Tt,mt,Me){for(var ze=0,Ve=ft.length;ze<Ve;ze++){var Se=ft[ze],Ke=Se.object,Oi=Se.geometry,$i=Me===void 0?Se.material:Me;if(Se=Se.group,mt.isArrayCamera){Cn=mt;for(var ve=mt.cameras,Tr=0,Nn=ve.length;Tr<Nn;Tr++){var an=ve[Tr];if(Ke.layers.test(an.layers)){if("viewport"in an)li.viewport(_n.copy(an.viewport));else{var pr=an.bounds;li.viewport(_n.set(pr.x*An,pr.y*Ce,pr.z*An,pr.w*Ce).multiplyScalar(ti))}$t.setupLights(an),A(Ke,Tt,an,Oi,$i,Se)}}}else Cn=null,A(Ke,Tt,mt,Oi,$i,Se)}}function A(ft,Tt,mt,Me,ze,Ve){if(ft.onBeforeRender(Yt,Tt,mt,Me,ze,Ve),$t=Vs.get(Tt,Cn||mt),ft.modelViewMatrix.multiplyMatrices(mt.matrixWorldInverse,ft.matrixWorld),ft.normalMatrix.getNormalMatrix(ft.modelViewMatrix),ft.isImmediateRenderObject){li.setMaterial(ze);var Se=B(mt,Tt.fog,ze,ft);We=e=null,Qe=!1,p(ft,Se)}else Yt.renderBufferDirect(mt,Tt.fog,Me,ze,ft,Ve);ft.onAfterRender(Yt,Tt,mt,Me,ze,Ve),$t=Vs.get(Tt,Cn||mt)}function L(ft,Tt,mt){var Me=Pn.get(ft),ze=$t.state.lights,Ve=Me.lightsHash,Se=ze.state.hash;mt=Hs.getParameters(ft,ze.state,$t.state.shadowsArray,Tt,Ae.numPlanes,Ae.numIntersection,mt);var Ke=Hs.getProgramCode(ft,mt),Oi=Me.program,$i=!0;if(Oi===void 0)ft.addEventListener("dispose",l);else if(Oi.code!==Ke)d(ft);else{if(Ve.stateID!==Se.stateID||Ve.directionalLength!==Se.directionalLength||Ve.pointLength!==Se.pointLength||Ve.spotLength!==Se.spotLength||Ve.rectAreaLength!==Se.rectAreaLength||Ve.hemiLength!==Se.hemiLength||Ve.shadowsLength!==Se.shadowsLength)Ve.stateID=Se.stateID,Ve.directionalLength=Se.directionalLength,Ve.pointLength=Se.pointLength,Ve.spotLength=Se.spotLength,Ve.rectAreaLength=Se.rectAreaLength,Ve.hemiLength=Se.hemiLength,Ve.shadowsLength=Se.shadowsLength;else if(mt.shaderID!==void 0)return;$i=!1}if($i&&(mt.shaderID?(Ke=wo[mt.shaderID],Me.shader={name:ft.type,uniforms:Bn.clone(Ke.uniforms),vertexShader:Ke.vertexShader,fragmentShader:Ke.fragmentShader}):Me.shader={name:ft.type,uniforms:ft.uniforms,vertexShader:ft.vertexShader,fragmentShader:ft.fragmentShader},ft.onBeforeCompile(Me.shader,Yt),Ke=Hs.getProgramCode(ft,mt),Oi=Hs.acquireProgram(ft,Me.shader,mt,Ke),Me.program=Oi,ft.program=Oi),mt=Oi.getAttributes(),ft.morphTargets)for(Ke=ft.numSupportedMorphTargets=0;Ke<Yt.maxMorphTargets;Ke++)0<=mt["morphTarget"+Ke]&&ft.numSupportedMorphTargets++;if(ft.morphNormals)for(Ke=ft.numSupportedMorphNormals=0;Ke<Yt.maxMorphNormals;Ke++)0<=mt["morphNormal"+Ke]&&ft.numSupportedMorphNormals++;mt=Me.shader.uniforms,(!ft.isShaderMaterial&&!ft.isRawShaderMaterial||ft.clipping===!0)&&(Me.numClippingPlanes=Ae.numPlanes,Me.numIntersection=Ae.numIntersection,mt.clippingPlanes=Ae.uniform),Me.fog=Tt,Ve===void 0&&(Me.lightsHash=Ve={}),Ve.stateID=Se.stateID,Ve.directionalLength=Se.directionalLength,Ve.pointLength=Se.pointLength,Ve.spotLength=Se.spotLength,Ve.rectAreaLength=Se.rectAreaLength,Ve.hemiLength=Se.hemiLength,Ve.shadowsLength=Se.shadowsLength,ft.lights&&(mt.ambientLightColor.value=ze.state.ambient,mt.directionalLights.value=ze.state.directional,mt.spotLights.value=ze.state.spot,mt.rectAreaLights.value=ze.state.rectArea,mt.pointLights.value=ze.state.point,mt.hemisphereLights.value=ze.state.hemi,mt.directionalShadowMap.value=ze.state.directionalShadowMap,mt.directionalShadowMatrix.value=ze.state.directionalShadowMatrix,mt.spotShadowMap.value=ze.state.spotShadowMap,mt.spotShadowMatrix.value=ze.state.spotShadowMatrix,mt.pointShadowMap.value=ze.state.pointShadowMap,mt.pointShadowMatrix.value=ze.state.pointShadowMatrix),ft=Me.program.getUniforms(),ft=ho.seqWithValue(ft.seq,mt),Me.uniformsList=ft}function B(ft,Tt,mt,Me){on=0;var ze=Pn.get(mt),Ve=ze.lightsHash,Se=$t.state.lights.state.hash;Xe&&(ri||ft!==fi)&&Ae.setState(mt.clippingPlanes,mt.clipIntersection,mt.clipShadows,ft,ze,ft===fi&&mt.id===ae),mt.needsUpdate===!1&&(ze.program===void 0||mt.fog&&ze.fog!==Tt?mt.needsUpdate=!0:(!mt.lights||Ve.stateID===Se.stateID&&Ve.directionalLength===Se.directionalLength&&Ve.pointLength===Se.pointLength&&Ve.spotLength===Se.spotLength&&Ve.rectAreaLength===Se.rectAreaLength&&Ve.hemiLength===Se.hemiLength&&Ve.shadowsLength===Se.shadowsLength)&&(ze.numClippingPlanes===void 0||ze.numClippingPlanes===Ae.numPlanes&&ze.numIntersection===Ae.numIntersection)||(mt.needsUpdate=!0)),mt.needsUpdate&&(L(mt,Tt,Me),mt.needsUpdate=!1);var Ke=!1,Oi=!1,$i=!1;Ve=ze.program,Se=Ve.getUniforms();var ve=ze.shader.uniforms;if(li.useProgram(Ve.program)&&($i=Oi=Ke=!0),mt.id!==ae&&(ae=mt.id,Oi=!0),(Ke||fi!==ft)&&(Se.setValue(ne,"projectionMatrix",ft.projectionMatrix),Je.logarithmicDepthBuffer&&Se.setValue(ne,"logDepthBufFC",2/(Math.log(ft.far+1)/Math.LN2)),fi!==ft&&(fi=ft,$i=Oi=!0),(mt.isShaderMaterial||mt.isMeshPhongMaterial||mt.isMeshStandardMaterial||mt.envMap)&&(Ke=Se.map.cameraPosition,Ke!==void 0&&Ke.setValue(ne,Ai.setFromMatrixPosition(ft.matrixWorld))),(mt.isMeshPhongMaterial||mt.isMeshLambertMaterial||mt.isMeshBasicMaterial||mt.isMeshStandardMaterial||mt.isShaderMaterial||mt.skinning)&&Se.setValue(ne,"viewMatrix",ft.matrixWorldInverse)),mt.skinning&&(Se.setOptional(ne,Me,"bindMatrix"),Se.setOptional(ne,Me,"bindMatrixInverse"),ft=Me.skeleton))if(Ke=ft.bones,Je.floatVertexTextures){if(ft.boneTexture===void 0){Ke=Math.sqrt(4*Ke.length),Ke=di.ceilPowerOfTwo(Ke),Ke=Math.max(Ke,4);var Tr=new Float32Array(Ke*Ke*4);Tr.set(ft.boneMatrices);var Nn=new O(Tr,Ke,Ke,1023,1015);Nn.needsUpdate=!0,ft.boneMatrices=Tr,ft.boneTexture=Nn,ft.boneTextureSize=Ke}Se.setValue(ne,"boneTexture",ft.boneTexture),Se.setValue(ne,"boneTextureSize",ft.boneTextureSize)}else Se.setOptional(ne,ft,"boneMatrices");return Oi&&(Se.setValue(ne,"toneMappingExposure",Yt.toneMappingExposure),Se.setValue(ne,"toneMappingWhitePoint",Yt.toneMappingWhitePoint),mt.lights&&(Oi=$i,ve.ambientLightColor.needsUpdate=Oi,ve.directionalLights.needsUpdate=Oi,ve.pointLights.needsUpdate=Oi,ve.spotLights.needsUpdate=Oi,ve.rectAreaLights.needsUpdate=Oi,ve.hemisphereLights.needsUpdate=Oi),Tt&&mt.fog&&(ve.fogColor.value=Tt.color,Tt.isFog?(ve.fogNear.value=Tt.near,ve.fogFar.value=Tt.far):Tt.isFogExp2&&(ve.fogDensity.value=Tt.density)),mt.isMeshBasicMaterial?H(ve,mt):mt.isMeshLambertMaterial?(H(ve,mt),mt.emissiveMap&&(ve.emissiveMap.value=mt.emissiveMap)):mt.isMeshPhongMaterial?(H(ve,mt),mt.isMeshToonMaterial?(q(ve,mt),mt.gradientMap&&(ve.gradientMap.value=mt.gradientMap)):q(ve,mt)):mt.isMeshStandardMaterial?(H(ve,mt),mt.isMeshPhysicalMaterial?(J(ve,mt),ve.reflectivity.value=mt.reflectivity,ve.clearCoat.value=mt.clearCoat,ve.clearCoatRoughness.value=mt.clearCoatRoughness):J(ve,mt)):mt.isMeshMatcapMaterial?(H(ve,mt),mt.matcap&&(ve.matcap.value=mt.matcap),mt.bumpMap&&(ve.bumpMap.value=mt.bumpMap,ve.bumpScale.value=mt.bumpScale,mt.side===1&&(ve.bumpScale.value*=-1)),mt.normalMap&&(ve.normalMap.value=mt.normalMap,ve.normalScale.value.copy(mt.normalScale),mt.side===1&&ve.normalScale.value.negate()),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias)):mt.isMeshDepthMaterial?(H(ve,mt),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias)):mt.isMeshDistanceMaterial?(H(ve,mt),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias),ve.referencePosition.value.copy(mt.referencePosition),ve.nearDistance.value=mt.nearDistance,ve.farDistance.value=mt.farDistance):mt.isMeshNormalMaterial?(H(ve,mt),mt.bumpMap&&(ve.bumpMap.value=mt.bumpMap,ve.bumpScale.value=mt.bumpScale,mt.side===1&&(ve.bumpScale.value*=-1)),mt.normalMap&&(ve.normalMap.value=mt.normalMap,ve.normalScale.value.copy(mt.normalScale),mt.side===1&&ve.normalScale.value.negate()),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias)):mt.isLineBasicMaterial?(ve.diffuse.value=mt.color,ve.opacity.value=mt.opacity,mt.isLineDashedMaterial&&(ve.dashSize.value=mt.dashSize,ve.totalSize.value=mt.dashSize+mt.gapSize,ve.scale.value=mt.scale)):mt.isPointsMaterial?(ve.diffuse.value=mt.color,ve.opacity.value=mt.opacity,ve.size.value=mt.size*ti,ve.scale.value=.5*Ce,ve.map.value=mt.map,mt.map!==null&&(mt.map.matrixAutoUpdate===!0&&mt.map.updateMatrix(),ve.uvTransform.value.copy(mt.map.matrix))):mt.isSpriteMaterial?(ve.diffuse.value=mt.color,ve.opacity.value=mt.opacity,ve.rotation.value=mt.rotation,ve.map.value=mt.map,mt.map!==null&&(mt.map.matrixAutoUpdate===!0&&mt.map.updateMatrix(),ve.uvTransform.value.copy(mt.map.matrix))):mt.isShadowMaterial&&(ve.color.value=mt.color,ve.opacity.value=mt.opacity),ve.ltc_1!==void 0&&(ve.ltc_1.value=qe.LTC_1),ve.ltc_2!==void 0&&(ve.ltc_2.value=qe.LTC_2),ho.upload(ne,ze.uniformsList,ve,Yt)),mt.isShaderMaterial&&mt.uniformsNeedUpdate===!0&&(ho.upload(ne,ze.uniformsList,ve,Yt),mt.uniformsNeedUpdate=!1),mt.isSpriteMaterial&&Se.setValue(ne,"center",Me.center),Se.setValue(ne,"modelViewMatrix",Me.modelViewMatrix),Se.setValue(ne,"normalMatrix",Me.normalMatrix),Se.setValue(ne,"modelMatrix",Me.matrixWorld),Ve}function H(ft,Tt){if(ft.opacity.value=Tt.opacity,Tt.color&&(ft.diffuse.value=Tt.color),Tt.emissive&&ft.emissive.value.copy(Tt.emissive).multiplyScalar(Tt.emissiveIntensity),Tt.map&&(ft.map.value=Tt.map),Tt.alphaMap&&(ft.alphaMap.value=Tt.alphaMap),Tt.specularMap&&(ft.specularMap.value=Tt.specularMap),Tt.envMap&&(ft.envMap.value=Tt.envMap,ft.flipEnvMap.value=Tt.envMap&&Tt.envMap.isCubeTexture?-1:1,ft.reflectivity.value=Tt.reflectivity,ft.refractionRatio.value=Tt.refractionRatio,ft.maxMipLevel.value=Pn.get(Tt.envMap).__maxMipLevel),Tt.lightMap&&(ft.lightMap.value=Tt.lightMap,ft.lightMapIntensity.value=Tt.lightMapIntensity),Tt.aoMap&&(ft.aoMap.value=Tt.aoMap,ft.aoMapIntensity.value=Tt.aoMapIntensity),Tt.map)var mt=Tt.map;else Tt.specularMap?mt=Tt.specularMap:Tt.displacementMap?mt=Tt.displacementMap:Tt.normalMap?mt=Tt.normalMap:Tt.bumpMap?mt=Tt.bumpMap:Tt.roughnessMap?mt=Tt.roughnessMap:Tt.metalnessMap?mt=Tt.metalnessMap:Tt.alphaMap?mt=Tt.alphaMap:Tt.emissiveMap&&(mt=Tt.emissiveMap);mt!==void 0&&(mt.isWebGLRenderTarget&&(mt=mt.texture),mt.matrixAutoUpdate===!0&&mt.updateMatrix(),ft.uvTransform.value.copy(mt.matrix))}function q(ft,Tt){ft.specular.value=Tt.specular,ft.shininess.value=Math.max(Tt.shininess,1e-4),Tt.emissiveMap&&(ft.emissiveMap.value=Tt.emissiveMap),Tt.bumpMap&&(ft.bumpMap.value=Tt.bumpMap,ft.bumpScale.value=Tt.bumpScale,Tt.side===1&&(ft.bumpScale.value*=-1)),Tt.normalMap&&(ft.normalMap.value=Tt.normalMap,ft.normalScale.value.copy(Tt.normalScale),Tt.side===1&&ft.normalScale.value.negate()),Tt.displacementMap&&(ft.displacementMap.value=Tt.displacementMap,ft.displacementScale.value=Tt.displacementScale,ft.displacementBias.value=Tt.displacementBias)}function J(ft,Tt){ft.roughness.value=Tt.roughness,ft.metalness.value=Tt.metalness,Tt.roughnessMap&&(ft.roughnessMap.value=Tt.roughnessMap),Tt.metalnessMap&&(ft.metalnessMap.value=Tt.metalnessMap),Tt.emissiveMap&&(ft.emissiveMap.value=Tt.emissiveMap),Tt.bumpMap&&(ft.bumpMap.value=Tt.bumpMap,ft.bumpScale.value=Tt.bumpScale,Tt.side===1&&(ft.bumpScale.value*=-1)),Tt.normalMap&&(ft.normalMap.value=Tt.normalMap,ft.normalScale.value.copy(Tt.normalScale),Tt.side===1&&ft.normalScale.value.negate()),Tt.displacementMap&&(ft.displacementMap.value=Tt.displacementMap,ft.displacementScale.value=Tt.displacementScale,ft.displacementBias.value=Tt.displacementBias),Tt.envMap&&(ft.envMapIntensity.value=Tt.envMapIntensity)}t=t||{};var rt=t.canvas!==void 0?t.canvas:document.createElementNS("http://www.w3.org/1999/xhtml","canvas"),xt=t.context!==void 0?t.context:null,gt=t.alpha!==void 0?t.alpha:!1,Ct=t.depth!==void 0?t.depth:!0,wt=t.stencil!==void 0?t.stencil:!0,Vt=t.antialias!==void 0?t.antialias:!1,$=t.premultipliedAlpha!==void 0?t.premultipliedAlpha:!0,ot=t.preserveDrawingBuffer!==void 0?t.preserveDrawingBuffer:!1,kt=t.powerPreference!==void 0?t.powerPreference:"default",ee=null,$t=null;this.domElement=rt,this.context=null,this.sortObjects=this.autoClearStencil=this.autoClearDepth=this.autoClearColor=this.autoClear=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.physicallyCorrectLights=this.gammaOutput=this.gammaInput=!1,this.toneMappingWhitePoint=this.toneMappingExposure=this.toneMapping=1,this.maxMorphTargets=8,this.maxMorphNormals=4;var Yt=this,Te=!1,ge=null,De=null,be=null,ae=-1,We=e=null,Qe=!1,fi=null,Cn=null,_n=new v,qi=new v,Vi=null,on=0,An=rt.width,Ce=rt.height,ti=1,Ht=new v(0,0,An,Ce),Ye=new v(0,0,An,Ce),ei=!1,Wi=new E,Ae=new W,Xe=!1,ri=!1,Li=new c,Ai=new u;try{gt={alpha:gt,depth:Ct,stencil:wt,antialias:Vt,premultipliedAlpha:$,preserveDrawingBuffer:ot,powerPreference:kt},rt.addEventListener("webglcontextlost",n,!1),rt.addEventListener("webglcontextrestored",s,!1);var ne=xt||rt.getContext("webgl",gt)||rt.getContext("experimental-webgl",gt);if(ne===null)throw rt.getContext("webgl")!==null?Error("Error creating WebGL context with your selected attributes."):Error("Error creating WebGL context.");ne.getShaderPrecisionFormat===void 0&&(ne.getShaderPrecisionFormat=function(){return{rangeMin:1,rangeMax:1,precision:1}})}catch{}var ii,Je,li,xn,Pn,No,Ia,Kh,Da,Hs,El,Vs,us,Qh,tu,er,In;i();var So=null;typeof navigator<"u"&&(So="xr"in navigator?new Le(Yt):new mi(Yt)),this.vr=So;var Gu=new ye(Yt,Da,Je.maxTextureSize);this.shadowMap=Gu,this.getContext=function(){return ne},this.getContextAttributes=function(){return ne.getContextAttributes()},this.forceContextLoss=function(){var ft=ii.get("WEBGL_lose_context");ft&&ft.loseContext()},this.forceContextRestore=function(){var ft=ii.get("WEBGL_lose_context");ft&&ft.restoreContext()},this.getPixelRatio=function(){return ti},this.setPixelRatio=function(ft){ft!==void 0&&(ti=ft,this.setSize(An,Ce,!1))},this.getSize=function(){return{width:An,height:Ce}},this.setSize=function(ft,Tt,mt){So.isPresenting()||(An=ft,Ce=Tt,rt.width=ft*ti,rt.height=Tt*ti,mt!==!1&&(rt.style.width=ft+"px",rt.style.height=Tt+"px"),this.setViewport(0,0,ft,Tt))},this.getDrawingBufferSize=function(){return{width:An*ti,height:Ce*ti}},this.setDrawingBufferSize=function(ft,Tt,mt){An=ft,Ce=Tt,ti=mt,rt.width=ft*mt,rt.height=Tt*mt,this.setViewport(0,0,ft,Tt)},this.getCurrentViewport=function(){return _n},this.setViewport=function(ft,Tt,mt,Me){Ht.set(ft,Ce-Tt-Me,mt,Me),li.viewport(_n.copy(Ht).multiplyScalar(ti))},this.setScissor=function(ft,Tt,mt,Me){Ye.set(ft,Ce-Tt-Me,mt,Me),li.scissor(qi.copy(Ye).multiplyScalar(ti))},this.setScissorTest=function(ft){li.setScissorTest(ei=ft)},this.getClearColor=function(){return us.getClearColor()},this.setClearColor=function(){us.setClearColor.apply(us,arguments)},this.getClearAlpha=function(){return us.getClearAlpha()},this.setClearAlpha=function(){us.setClearAlpha.apply(us,arguments)},this.clear=function(ft,Tt,mt){var Me=0;(ft===void 0||ft)&&(Me|=16384),(Tt===void 0||Tt)&&(Me|=256),(mt===void 0||mt)&&(Me|=1024),ne.clear(Me)},this.clearColor=function(){this.clear(!0,!1,!1)},this.clearDepth=function(){this.clear(!1,!0,!1)},this.clearStencil=function(){this.clear(!1,!1,!0)},this.dispose=function(){rt.removeEventListener("webglcontextlost",n,!1),rt.removeEventListener("webglcontextrestored",s,!1),El.dispose(),Vs.dispose(),Pn.dispose(),Da.dispose(),So.dispose(),Fo.stop()},this.renderBufferImmediate=function(ft,Tt){li.initAttributes();var mt=Pn.get(ft);ft.hasPositions&&!mt.position&&(mt.position=ne.createBuffer()),ft.hasNormals&&!mt.normal&&(mt.normal=ne.createBuffer()),ft.hasUvs&&!mt.uv&&(mt.uv=ne.createBuffer()),ft.hasColors&&!mt.color&&(mt.color=ne.createBuffer()),Tt=Tt.getAttributes(),ft.hasPositions&&(ne.bindBuffer(34962,mt.position),ne.bufferData(34962,ft.positionArray,35048),li.enableAttribute(Tt.position),ne.vertexAttribPointer(Tt.position,3,5126,!1,0,0)),ft.hasNormals&&(ne.bindBuffer(34962,mt.normal),ne.bufferData(34962,ft.normalArray,35048),li.enableAttribute(Tt.normal),ne.vertexAttribPointer(Tt.normal,3,5126,!1,0,0)),ft.hasUvs&&(ne.bindBuffer(34962,mt.uv),ne.bufferData(34962,ft.uvArray,35048),li.enableAttribute(Tt.uv),ne.vertexAttribPointer(Tt.uv,2,5126,!1,0,0)),ft.hasColors&&(ne.bindBuffer(34962,mt.color),ne.bufferData(34962,ft.colorArray,35048),li.enableAttribute(Tt.color),ne.vertexAttribPointer(Tt.color,3,5126,!1,0,0)),li.disableUnusedAttributes(),ne.drawArrays(4,0,ft.count),ft.count=0},this.renderBufferDirect=function(ft,Tt,mt,Me,ze,Ve){var Se=ze.isMesh&&0>ze.normalMatrix.determinant();li.setMaterial(Me,Se);var Ke=B(ft,Tt,Me,ze),Oi=!1;(e!==mt.id||We!==Ke.id||Qe!==(Me.wireframe===!0))&&(e=mt.id,We=Ke.id,Qe=Me.wireframe===!0,Oi=!0),ze.morphTargetInfluences&&(Qh.update(ze,mt,Me,Ke),Oi=!0),Se=mt.index;var $i=mt.attributes.position;if(Tt=1,Me.wireframe===!0&&(Se=Kh.getWireframeAttribute(mt),Tt=2),ft=tu,Se!==null){var ve=Ia.get(Se);ft=er,ft.setIndex(ve)}if(Oi){if(!(mt&&mt.isInstancedBufferGeometry&!Je.isWebGL2&&ii.get("ANGLE_instanced_arrays")===null)){li.initAttributes(),Oi=mt.attributes,Ke=Ke.getAttributes();var Tr=Me.defaultAttributeValues;for(ir in Ke){var Nn=Ke[ir];if(0<=Nn){var an=Oi[ir];if(an!==void 0){var pr=an.normalized,eu=an.itemSize,Eo=Ia.get(an);if(Eo!==void 0){var iu=Eo.buffer,dh=Eo.type;if(Eo=Eo.bytesPerElement,an.isInterleavedBufferAttribute){var ka=an.data,Hu=ka.stride;an=an.offset,ka&&ka.isInstancedInterleavedBuffer?(li.enableAttributeAndDivisor(Nn,ka.meshPerAttribute),mt.maxInstancedCount===void 0&&(mt.maxInstancedCount=ka.meshPerAttribute*ka.count)):li.enableAttribute(Nn),ne.bindBuffer(34962,iu),ne.vertexAttribPointer(Nn,eu,dh,pr,Hu*Eo,an*Eo)}else an.isInstancedBufferAttribute?(li.enableAttributeAndDivisor(Nn,an.meshPerAttribute),mt.maxInstancedCount===void 0&&(mt.maxInstancedCount=an.meshPerAttribute*an.count)):li.enableAttribute(Nn),ne.bindBuffer(34962,iu),ne.vertexAttribPointer(Nn,eu,dh,pr,0,0)}}else if(Tr!==void 0&&(pr=Tr[ir],pr!==void 0))switch(pr.length){case 2:ne.vertexAttrib2fv(Nn,pr);break;case 3:ne.vertexAttrib3fv(Nn,pr);break;case 4:ne.vertexAttrib4fv(Nn,pr);break;default:ne.vertexAttrib1fv(Nn,pr)}}}li.disableUnusedAttributes()}Se!==null&&ne.bindBuffer(34963,ve.buffer)}ve=1/0,Se!==null?ve=Se.count:$i!==void 0&&(ve=$i.count),Se=mt.drawRange.start*Tt,$i=Ve!==null?Ve.start*Tt:0;var ir=Math.max(Se,$i);if(Ve=Math.max(0,Math.min(ve,Se+mt.drawRange.count*Tt,$i+(Ve!==null?Ve.count*Tt:1/0))-1-ir+1),Ve!==0){if(ze.isMesh)if(Me.wireframe===!0)li.setLineWidth(Me.wireframeLinewidth*(De===null?ti:1)),ft.setMode(1);else switch(ze.drawMode){case 0:ft.setMode(4);break;case 1:ft.setMode(5);break;case 2:ft.setMode(6)}else ze.isLine?(Me=Me.linewidth,Me===void 0&&(Me=1),li.setLineWidth(Me*(De===null?ti:1)),ze.isLineSegments?ft.setMode(1):ze.isLineLoop?ft.setMode(2):ft.setMode(3)):ze.isPoints?ft.setMode(0):ze.isSprite&&ft.setMode(4);mt&&mt.isInstancedBufferGeometry?0<mt.maxInstancedCount&&ft.renderInstances(mt,ir,Ve):ft.render(ir,Ve)}},this.compile=function(ft,Tt){$t=Vs.get(ft,Tt),$t.init(),ft.traverse(function(mt){mt.isLight&&($t.pushLight(mt),mt.castShadow&&$t.pushShadow(mt))}),$t.setupLights(Tt),ft.traverse(function(mt){if(mt.material)if(Array.isArray(mt.material))for(var Me=0;Me<mt.material.length;Me++)L(mt.material[Me],ft.fog,mt);else L(mt.material,ft.fog,mt)})};var za=null,Fo=new w;Fo.setAnimationLoop(function(ft){So.isPresenting()||za&&za(ft)}),typeof window<"u"&&Fo.setContext(window),this.setAnimationLoop=function(ft){za=ft,So.setAnimationLoop(ft),Fo.start()},this.render=function(ft,Tt,mt,Me){if(!(!Tt||!Tt.isCamera)){if(!Te){We=e=null,Qe=!1,ae=-1,fi=null,ft.autoUpdate===!0&&ft.updateMatrixWorld(),Tt.parent===null&&Tt.updateMatrixWorld(),So.enabled&&(Tt=So.getCamera(Tt)),$t=Vs.get(ft,Tt),$t.init(),ft.onBeforeRender(Yt,ft,Tt,mt),Li.multiplyMatrices(Tt.projectionMatrix,Tt.matrixWorldInverse),Wi.setFromMatrix(Li),ri=this.localClippingEnabled,Xe=Ae.init(this.clippingPlanes,ri,Tt),ee=El.get(ft,Tt),ee.init(),_(ft,Tt,Yt.sortObjects),Yt.sortObjects===!0&&ee.sort(),Xe&&Ae.beginShadows(),Gu.render($t.state.shadowsArray,ft,Tt),$t.setupLights(Tt),Xe&&Ae.endShadows(),this.info.autoReset&&this.info.reset(),mt===void 0&&(mt=null),this.setRenderTarget(mt),us.render(ee,ft,Tt,Me),Me=ee.opaque;var ze=ee.transparent;if(ft.overrideMaterial){var Ve=ft.overrideMaterial;Me.length&&T(Me,ft,Tt,Ve),ze.length&&T(ze,ft,Tt,Ve)}else Me.length&&T(Me,ft,Tt),ze.length&&T(ze,ft,Tt);mt&&No.updateRenderTargetMipmap(mt),li.buffers.depth.setTest(!0),li.buffers.depth.setMask(!0),li.buffers.color.setMask(!0),li.setPolygonOffset(!1),ft.onAfterRender(Yt,ft,Tt),So.enabled&&So.submitFrame(),$t=ee=null}}},this.allocTextureUnit=function(){var ft=on;return ft>=Je.maxTextures,on+=1,ft},this.setTexture2D=function(){var ft=!1;return function(Tt,mt){Tt&&Tt.isWebGLRenderTarget&&(ft||(ft=!0),Tt=Tt.texture),No.setTexture2D(Tt,mt)}}(),this.setTexture3D=function(){return function(ft,Tt){No.setTexture3D(ft,Tt)}}(),this.setTexture=function(){var ft=!1;return function(Tt,mt){ft||(ft=!0),No.setTexture2D(Tt,mt)}}(),this.setTextureCube=function(){var ft=!1;return function(Tt,mt){Tt&&Tt.isWebGLRenderTargetCube&&(ft||(ft=!0),Tt=Tt.texture),Tt&&Tt.isCubeTexture||Array.isArray(Tt.image)&&Tt.image.length===6?No.setTextureCube(Tt,mt):No.setTextureCubeDynamic(Tt,mt)}}(),this.setFramebuffer=function(ft){ge=ft},this.getRenderTarget=function(){return De},this.setRenderTarget=function(ft){(De=ft)&&Pn.get(ft).__webglFramebuffer===void 0&&No.setupRenderTarget(ft);var Tt=ge,mt=!1;ft?(Tt=Pn.get(ft).__webglFramebuffer,ft.isWebGLRenderTargetCube&&(Tt=Tt[ft.activeCubeFace],mt=!0),_n.copy(ft.viewport),qi.copy(ft.scissor),Vi=ft.scissorTest):(_n.copy(Ht).multiplyScalar(ti),qi.copy(Ye).multiplyScalar(ti),Vi=ei),be!==Tt&&(ne.bindFramebuffer(36160,Tt),be=Tt),li.viewport(_n),li.scissor(qi),li.setScissorTest(Vi),mt&&(mt=Pn.get(ft.texture),ne.framebufferTexture2D(36160,36064,34069+ft.activeCubeFace,mt.__webglTexture,ft.activeMipMapLevel))},this.readRenderTargetPixels=function(ft,Tt,mt,Me,ze,Ve){if(ft&&ft.isWebGLRenderTarget){var Se=Pn.get(ft).__webglFramebuffer;if(Se){var Ke=!1;Se!==be&&(ne.bindFramebuffer(36160,Se),Ke=!0);try{var Oi=ft.texture,$i=Oi.format,ve=Oi.type;$i!==1023&&In.convert($i)!==ne.getParameter(35739)||(ve===1009||In.convert(ve)===ne.getParameter(35738)||ve===1015&&(Je.isWebGL2||ii.get("OES_texture_float")||ii.get("WEBGL_color_buffer_float"))||ve===1016&&(Je.isWebGL2?ii.get("EXT_color_buffer_float"):ii.get("EXT_color_buffer_half_float")))&&ne.checkFramebufferStatus(36160)===36053&&0<=Tt&&Tt<=ft.width-Me&&0<=mt&&mt<=ft.height-ze&&ne.readPixels(Tt,mt,Me,ze,In.convert($i),In.convert(ve),Ve)}finally{Ke&&ne.bindFramebuffer(36160,be)}}}},this.copyFramebufferToTexture=function(ft,Tt,mt){var Me=Tt.image.width,ze=Tt.image.height,Ve=In.convert(Tt.format);this.setTexture2D(Tt,0),ne.copyTexImage2D(3553,mt||0,Ve,ft.x,ft.y,Me,ze,0)},this.copyTextureToTexture=function(ft,Tt,mt,Me){var ze=Tt.image.width,Ve=Tt.image.height,Se=In.convert(mt.format),Ke=In.convert(mt.type);this.setTexture2D(mt,0),Tt.isDataTexture?ne.texSubImage2D(3553,Me||0,ft.x,ft.y,ze,Ve,Se,Ke,Tt.image.data):ne.texSubImage2D(3553,Me||0,ft.x,ft.y,Se,Ke,Tt.image)}}function Re(t,e){this.name="",this.color=new P(t),this.density=e!==void 0?e:25e-5}function Sn(t,e,i){this.name="",this.color=new P(t),this.near=e!==void 0?e:1,this.far=i!==void 0?i:1e3}function Xn(){F.call(this),this.type="Scene",this.overrideMaterial=this.fog=this.background=null,this.autoUpdate=!0}function ki(t,e){this.array=t,this.stride=e,this.count=t!==void 0?t.length/e:0,this.dynamic=!1,this.updateRange={offset:0,count:-1},this.version=0}function Bi(t,e,i,n){this.data=t,this.itemSize=e,this.offset=i,this.normalized=n===!0}function Hi(t){Wt.call(this),this.type="SpriteMaterial",this.color=new P(16777215),this.map=null,this.rotation=0,this.sizeAttenuation=!0,this.lights=!1,this.transparent=!0,this.setValues(t)}function nn(t){if(F.call(this),this.type="Sprite",Oa===void 0){Oa=new Ft;var e=new Float32Array([-.5,-.5,0,0,0,.5,-.5,0,1,0,.5,.5,0,1,1,-.5,.5,0,0,1]);e=new ki(e,5),Oa.setIndex([0,1,2,0,2,3]),Oa.addAttribute("position",new Bi(e,3,0,!1)),Oa.addAttribute("uv",new Bi(e,2,3,!1))}this.geometry=Oa,this.material=t!==void 0?t:new Hi,this.center=new o(.5,.5)}function rn(){F.call(this),this.type="LOD",Object.defineProperties(this,{levels:{enumerable:!0,value:[]}})}function un(t,e){if(t=t||[],this.bones=t.slice(0),this.boneMatrices=new Float32Array(16*this.bones.length),e===void 0)this.calculateInverses();else if(this.bones.length===e.length)this.boneInverses=e.slice(0);else for(this.boneInverses=[],t=0,e=this.bones.length;t<e;t++)this.boneInverses.push(new c)}function cn(){F.call(this),this.type="Bone"}function Gi(t,e){pi.call(this,t,e),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new c,this.bindMatrixInverse=new c,t=this.initBones(),t=new un(t),this.bind(t,this.matrixWorld),this.normalizeSkinWeights()}function Ni(t){Wt.call(this),this.type="LineBasicMaterial",this.color=new P(16777215),this.linewidth=1,this.linejoin=this.linecap="round",this.lights=!1,this.setValues(t)}function ji(t,e,i){F.call(this),this.type="Line",this.geometry=t!==void 0?t:new Ft,this.material=e!==void 0?e:new Ni({color:16777215*Math.random()})}function gi(t,e){ji.call(this,t,e),this.type="LineSegments"}function co(t,e){ji.call(this,t,e),this.type="LineLoop"}function Fn(t){Wt.call(this),this.type="PointsMaterial",this.color=new P(16777215),this.map=null,this.size=1,this.sizeAttenuation=!0,this.lights=this.morphTargets=!1,this.setValues(t)}function ha(t,e){F.call(this),this.type="Points",this.geometry=t!==void 0?t:new Ft,this.material=e!==void 0?e:new Fn({color:16777215*Math.random()})}function zh(t,e,i,n,s,l,d,p,_){g.call(this,t,e,i,n,s,l,d,p,_),this.generateMipmaps=!1}function Zo(t,e,i,n,s,l,d,p,_,T,A,L){g.call(this,null,l,d,p,_,T,n,s,A,L),this.image={width:e,height:i},this.mipmaps=t,this.generateMipmaps=this.flipY=!1}function $a(t,e,i,n,s,l,d,p,_){g.call(this,t,e,i,n,s,l,d,p,_),this.needsUpdate=!0}function Ka(t,e,i,n,s,l,d,p,_,T){if(T=T!==void 0?T:1026,T!==1026&&T!==1027)throw Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");i===void 0&&T===1026&&(i=1012),i===void 0&&T===1027&&(i=1020),g.call(this,null,n,s,l,d,p,T,i,_),this.image={width:t,height:e},this.magFilter=d!==void 0?d:1003,this.minFilter=p!==void 0?p:1003,this.generateMipmaps=this.flipY=!1}function ua(t){Ft.call(this),this.type="WireframeGeometry";var e=[],i,n,s,l=[0,0],d={},p=["a","b","c"];if(t&&t.isGeometry){var _=t.faces,T=0;for(n=_.length;T<n;T++){var A=_[T];for(i=0;3>i;i++){var L=A[p[i]],B=A[p[(i+1)%3]];l[0]=Math.min(L,B),l[1]=Math.max(L,B),L=l[0]+","+l[1],d[L]===void 0&&(d[L]={index1:l[0],index2:l[1]})}}for(L in d)T=d[L],p=t.vertices[T.index1],e.push(p.x,p.y,p.z),p=t.vertices[T.index2],e.push(p.x,p.y,p.z)}else if(t&&t.isBufferGeometry)if(p=new u,t.index!==null){_=t.attributes.position,A=t.index;var H=t.groups;for(H.length===0&&(H=[{start:0,count:A.count,materialIndex:0}]),t=0,s=H.length;t<s;++t)for(T=H[t],i=T.start,n=T.count,T=i,n=i+n;T<n;T+=3)for(i=0;3>i;i++)L=A.getX(T+i),B=A.getX(T+(i+1)%3),l[0]=Math.min(L,B),l[1]=Math.max(L,B),L=l[0]+","+l[1],d[L]===void 0&&(d[L]={index1:l[0],index2:l[1]});for(L in d)T=d[L],p.fromBufferAttribute(_,T.index1),e.push(p.x,p.y,p.z),p.fromBufferAttribute(_,T.index2),e.push(p.x,p.y,p.z)}else for(_=t.attributes.position,T=0,n=_.count/3;T<n;T++)for(i=0;3>i;i++)d=3*T+i,p.fromBufferAttribute(_,d),e.push(p.x,p.y,p.z),d=3*T+(i+1)%3,p.fromBufferAttribute(_,d),e.push(p.x,p.y,p.z);this.addAttribute("position",new Et(e,3))}function Qa(t,e,i){X.call(this),this.type="ParametricGeometry",this.parameters={func:t,slices:e,stacks:i},this.fromBufferGeometry(new ca(t,e,i)),this.mergeVertices()}function ca(t,e,i){Ft.call(this),this.type="ParametricBufferGeometry",this.parameters={func:t,slices:e,stacks:i};var n=[],s=[],l=[],d=[],p=new u,_=new u,T=new u,A=new u,L=new u,B,H;3>t.length;var q=e+1;for(B=0;B<=i;B++){var J=B/i;for(H=0;H<=e;H++){var rt=H/e;t(rt,J,_),s.push(_.x,_.y,_.z),0<=rt-1e-5?(t(rt-1e-5,J,T),A.subVectors(_,T)):(t(rt+1e-5,J,T),A.subVectors(T,_)),0<=J-1e-5?(t(rt,J-1e-5,T),L.subVectors(_,T)):(t(rt,J+1e-5,T),L.subVectors(T,_)),p.crossVectors(A,L).normalize(),l.push(p.x,p.y,p.z),d.push(rt,J)}}for(B=0;B<i;B++)for(H=0;H<e;H++)t=B*q+H+1,p=(B+1)*q+H+1,_=(B+1)*q+H,n.push(B*q+H,t,_),n.push(t,p,_);this.setIndex(n),this.addAttribute("position",new Et(s,3)),this.addAttribute("normal",new Et(l,3)),this.addAttribute("uv",new Et(d,2))}function Xi(t,e,i,n){X.call(this),this.type="PolyhedronGeometry",this.parameters={vertices:t,indices:e,radius:i,detail:n},this.fromBufferGeometry(new xi(t,e,i,n)),this.mergeVertices()}function xi(t,e,i,n){function s(T){p.push(T.x,T.y,T.z)}function l(T,A){T*=3,A.x=t[T+0],A.y=t[T+1],A.z=t[T+2]}function d(T,A,L,B){0>B&&T.x===1&&(_[A]=T.x-1),L.x===0&&L.z===0&&(_[A]=B/2/Math.PI+.5)}Ft.call(this),this.type="PolyhedronBufferGeometry",this.parameters={vertices:t,indices:e,radius:i,detail:n},i=i||1,n=n||0;var p=[],_=[];(function(T){for(var A=new u,L=new u,B=new u,H=0;H<e.length;H+=3){l(e[H+0],A),l(e[H+1],L),l(e[H+2],B);var q,J,rt=A,xt=L,gt=B,Ct=Math.pow(2,T),wt=[];for(J=0;J<=Ct;J++){wt[J]=[];var Vt=rt.clone().lerp(gt,J/Ct),$=xt.clone().lerp(gt,J/Ct),ot=Ct-J;for(q=0;q<=ot;q++)wt[J][q]=q===0&&J===Ct?Vt:Vt.clone().lerp($,q/ot)}for(J=0;J<Ct;J++)for(q=0;q<2*(Ct-J)-1;q++)rt=Math.floor(q/2),q%2===0?(s(wt[J][rt+1]),s(wt[J+1][rt]),s(wt[J][rt])):(s(wt[J][rt+1]),s(wt[J+1][rt+1]),s(wt[J+1][rt]))}})(n),function(T){for(var A=new u,L=0;L<p.length;L+=3)A.x=p[L+0],A.y=p[L+1],A.z=p[L+2],A.normalize().multiplyScalar(T),p[L+0]=A.x,p[L+1]=A.y,p[L+2]=A.z}(i),function(){for(var T=new u,A=0;A<p.length;A+=3)T.x=p[A+0],T.y=p[A+1],T.z=p[A+2],_.push(Math.atan2(T.z,-T.x)/2/Math.PI+.5,1-(Math.atan2(-T.y,Math.sqrt(T.x*T.x+T.z*T.z))/Math.PI+.5));T=new u,A=new u;for(var L=new u,B=new u,H=new o,q=new o,J=new o,rt=0,xt=0;rt<p.length;rt+=9,xt+=6){T.set(p[rt+0],p[rt+1],p[rt+2]),A.set(p[rt+3],p[rt+4],p[rt+5]),L.set(p[rt+6],p[rt+7],p[rt+8]),H.set(_[xt+0],_[xt+1]),q.set(_[xt+2],_[xt+3]),J.set(_[xt+4],_[xt+5]),B.copy(T).add(A).add(L).divideScalar(3);var gt=Math.atan2(B.z,-B.x);d(H,xt+0,T,gt),d(q,xt+2,A,gt),d(J,xt+4,L,gt)}for(T=0;T<_.length;T+=6)A=_[T+0],L=_[T+2],B=_[T+4],H=Math.min(A,L,B),.9<Math.max(A,L,B)&&.1>H&&(.2>A&&(_[T+0]+=1),.2>L&&(_[T+2]+=1),.2>B&&(_[T+4]+=1))}(),this.addAttribute("position",new Et(p,3)),this.addAttribute("normal",new Et(p.slice(),3)),this.addAttribute("uv",new Et(_,2)),n===0?this.computeVertexNormals():this.normalizeNormals()}function tl(t,e){X.call(this),this.type="TetrahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new fa(t,e)),this.mergeVertices()}function fa(t,e){xi.call(this,[1,1,1,-1,-1,1,-1,1,-1,1,-1,-1],[2,1,0,0,3,2,1,3,0,2,3,1],t,e),this.type="TetrahedronBufferGeometry",this.parameters={radius:t,detail:e}}function el(t,e){X.call(this),this.type="OctahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new xs(t,e)),this.mergeVertices()}function xs(t,e){xi.call(this,[1,0,0,-1,0,0,0,1,0,0,-1,0,0,0,1,0,0,-1],[0,2,4,0,4,3,0,3,5,0,5,2,1,2,5,1,5,3,1,3,4,1,4,2],t,e),this.type="OctahedronBufferGeometry",this.parameters={radius:t,detail:e}}function il(t,e){X.call(this),this.type="IcosahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new da(t,e)),this.mergeVertices()}function da(t,e){var i=(1+Math.sqrt(5))/2;xi.call(this,[-1,i,0,1,i,0,-1,-i,0,1,-i,0,0,-1,i,0,1,i,0,-1,-i,0,1,-i,i,0,-1,i,0,1,-i,0,-1,-i,0,1],[0,11,5,0,5,1,0,1,7,0,7,10,0,10,11,1,5,9,5,11,4,11,10,2,10,7,6,7,1,8,3,9,4,3,4,2,3,2,6,3,6,8,3,8,9,4,9,5,2,4,11,6,2,10,8,6,7,9,8,1],t,e),this.type="IcosahedronBufferGeometry",this.parameters={radius:t,detail:e}}function pa(t,e){X.call(this),this.type="DodecahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new ma(t,e)),this.mergeVertices()}function ma(t,e){var i=(1+Math.sqrt(5))/2,n=1/i;xi.call(this,[-1,-1,-1,-1,-1,1,-1,1,-1,-1,1,1,1,-1,-1,1,-1,1,1,1,-1,1,1,1,0,-n,-i,0,-n,i,0,n,-i,0,n,i,-n,-i,0,-n,i,0,n,-i,0,n,i,0,-i,0,-n,i,0,-n,-i,0,n,i,0,n],[3,11,7,3,7,15,3,15,13,7,19,17,7,17,6,7,6,15,17,4,8,17,8,10,17,10,6,8,0,16,8,16,2,8,2,10,0,12,1,0,1,18,0,18,16,6,10,2,6,2,13,6,13,15,2,16,18,2,18,3,2,3,13,18,1,9,18,9,11,18,11,3,4,14,12,4,12,0,4,0,8,11,9,5,11,5,19,11,19,7,19,5,14,19,14,4,19,4,17,1,12,14,1,14,5,1,5,9],t,e),this.type="DodecahedronBufferGeometry",this.parameters={radius:t,detail:e}}function gn(t,e,i,n,s,l){X.call(this),this.type="TubeGeometry",this.parameters={path:t,tubularSegments:e,radius:i,radialSegments:n,closed:s},t=new Jo(t,e,i,n,s),this.tangents=t.tangents,this.normals=t.normals,this.binormals=t.binormals,this.fromBufferGeometry(t),this.mergeVertices()}function Jo(t,e,i,n,s){function l(xt){A=t.getPointAt(xt/e,A);var gt=d.normals[xt];for(xt=d.binormals[xt],B=0;B<=n;B++){var Ct=B/n*Math.PI*2,wt=Math.sin(Ct);Ct=-Math.cos(Ct),_.x=Ct*gt.x+wt*xt.x,_.y=Ct*gt.y+wt*xt.y,_.z=Ct*gt.z+wt*xt.z,_.normalize(),q.push(_.x,_.y,_.z),p.x=A.x+i*_.x,p.y=A.y+i*_.y,p.z=A.z+i*_.z,H.push(p.x,p.y,p.z)}}Ft.call(this),this.type="TubeBufferGeometry",this.parameters={path:t,tubularSegments:e,radius:i,radialSegments:n,closed:s},e=e||64,i=i||1,n=n||8,s=s||!1;var d=t.computeFrenetFrames(e,s);this.tangents=d.tangents,this.normals=d.normals,this.binormals=d.binormals;var p=new u,_=new u,T=new o,A=new u,L,B,H=[],q=[],J=[],rt=[];for(L=0;L<e;L++)l(L);for(l(s===!1?e:0),L=0;L<=e;L++)for(B=0;B<=n;B++)T.x=L/e,T.y=B/n,J.push(T.x,T.y);(function(){for(B=1;B<=e;B++)for(L=1;L<=n;L++){var xt=(n+1)*B+(L-1),gt=(n+1)*B+L,Ct=(n+1)*(B-1)+L;rt.push((n+1)*(B-1)+(L-1),xt,Ct),rt.push(xt,gt,Ct)}})(),this.setIndex(rt),this.addAttribute("position",new Et(H,3)),this.addAttribute("normal",new Et(q,3)),this.addAttribute("uv",new Et(J,2))}function Zr(t,e,i,n,s,l,d){X.call(this),this.type="TorusKnotGeometry",this.parameters={radius:t,tube:e,tubularSegments:i,radialSegments:n,p:s,q:l},this.fromBufferGeometry(new ws(t,e,i,n,s,l)),this.mergeVertices()}function ws(t,e,i,n,s,l){function d($,ot,kt,ee,$t){var Yt=Math.sin($);ot=kt/ot*$,kt=Math.cos(ot),$t.x=ee*(2+kt)*.5*Math.cos($),$t.y=ee*(2+kt)*Yt*.5,$t.z=ee*Math.sin(ot)*.5}Ft.call(this),this.type="TorusKnotBufferGeometry",this.parameters={radius:t,tube:e,tubularSegments:i,radialSegments:n,p:s,q:l},t=t||1,e=e||.4,i=Math.floor(i)||64,n=Math.floor(n)||8,s=s||2,l=l||3;var p=[],_=[],T=[],A=[],L,B=new u,H=new u,q=new u,J=new u,rt=new u,xt=new u,gt=new u;for(L=0;L<=i;++L){var Ct=L/i*s*Math.PI*2;for(d(Ct,s,l,t,q),d(Ct+.01,s,l,t,J),xt.subVectors(J,q),gt.addVectors(J,q),rt.crossVectors(xt,gt),gt.crossVectors(rt,xt),rt.normalize(),gt.normalize(),Ct=0;Ct<=n;++Ct){var wt=Ct/n*Math.PI*2,Vt=-e*Math.cos(wt);wt=e*Math.sin(wt),B.x=q.x+(Vt*gt.x+wt*rt.x),B.y=q.y+(Vt*gt.y+wt*rt.y),B.z=q.z+(Vt*gt.z+wt*rt.z),_.push(B.x,B.y,B.z),H.subVectors(B,q).normalize(),T.push(H.x,H.y,H.z),A.push(L/i),A.push(Ct/n)}}for(Ct=1;Ct<=i;Ct++)for(L=1;L<=n;L++)t=(n+1)*Ct+(L-1),e=(n+1)*Ct+L,s=(n+1)*(Ct-1)+L,p.push((n+1)*(Ct-1)+(L-1),t,s),p.push(t,e,s);this.setIndex(p),this.addAttribute("position",new Et(_,3)),this.addAttribute("normal",new Et(T,3)),this.addAttribute("uv",new Et(A,2))}function Ts(t,e,i,n,s){X.call(this),this.type="TorusGeometry",this.parameters={radius:t,tube:e,radialSegments:i,tubularSegments:n,arc:s},this.fromBufferGeometry(new Un(t,e,i,n,s)),this.mergeVertices()}function Un(t,e,i,n,s){Ft.call(this),this.type="TorusBufferGeometry",this.parameters={radius:t,tube:e,radialSegments:i,tubularSegments:n,arc:s},t=t||1,e=e||.4,i=Math.floor(i)||8,n=Math.floor(n)||6,s=s||2*Math.PI;var l=[],d=[],p=[],_=[],T=new u,A=new u,L=new u,B,H;for(B=0;B<=i;B++)for(H=0;H<=n;H++){var q=H/n*s,J=B/i*Math.PI*2;A.x=(t+e*Math.cos(J))*Math.cos(q),A.y=(t+e*Math.cos(J))*Math.sin(q),A.z=e*Math.sin(J),d.push(A.x,A.y,A.z),T.x=t*Math.cos(q),T.y=t*Math.sin(q),L.subVectors(A,T).normalize(),p.push(L.x,L.y,L.z),_.push(H/n),_.push(B/i)}for(B=1;B<=i;B++)for(H=1;H<=n;H++)t=(n+1)*(B-1)+H-1,e=(n+1)*(B-1)+H,s=(n+1)*B+H,l.push((n+1)*B+H-1,t,s),l.push(t,e,s);this.setIndex(l),this.addAttribute("position",new Et(d,3)),this.addAttribute("normal",new Et(p,3)),this.addAttribute("uv",new Et(_,2))}function kh(t,e,i,n,s){for(var l,d=0,p=e,_=i-n;p<i;p+=n)d+=(t[_]-t[p])*(t[p+1]+t[_+1]),_=p;if(s===0<d)for(s=e;s<i;s+=n)l=Jl(s,t[s],t[s+1],l);else for(s=i-n;s>=e;s-=n)l=Jl(s,t[s],t[s+1],l);return l&&Ms(l,l.next)&&(Yi(l),l=l.next),l}function ga(t,e){if(!t)return t;e||(e=t);do{var i=!1;if(t.steiner||!Ms(t,t.next)&&Ji(t.prev,t,t.next)!==0)t=t.next;else{if(Yi(t),t=e=t.prev,t===t.next)break;i=!0}}while(i||t!==e);return e}function va(t,e,i,n,s,l,d){if(t){if(!d&&l){var p=t,_=p;do _.z===null&&(_.z=Yl(_.x,_.y,n,s,l)),_.prevZ=_.prev,_=_.nextZ=_.next;while(_!==p);_.prevZ.nextZ=null,_.prevZ=null,p=_;var T,A,L,B,H=1;do{_=p;var q=p=null;for(A=0;_;){A++;var J=_;for(T=L=0;T<H&&(L++,J=J.nextZ,J);T++);for(B=H;0<L||0<B&&J;)L!==0&&(B===0||!J||_.z<=J.z)?(T=_,_=_.nextZ,L--):(T=J,J=J.nextZ,B--),q?q.nextZ=T:p=T,T.prevZ=q,q=T;_=J}q.nextZ=null,H*=2}while(1<A)}for(p=t;t.prev!==t.next;){if(_=t.prev,J=t.next,l)t:{q=t,B=n;var rt=s,xt=l;if(A=q.prev,L=q,H=q.next,0<=Ji(A,L,H))q=!1;else{var gt=A.x>L.x?A.x>H.x?A.x:H.x:L.x>H.x?L.x:H.x,Ct=A.y>L.y?A.y>H.y?A.y:H.y:L.y>H.y?L.y:H.y;for(T=Yl(A.x<L.x?A.x<H.x?A.x:H.x:L.x<H.x?L.x:H.x,A.y<L.y?A.y<H.y?A.y:H.y:L.y<H.y?L.y:H.y,B,rt,xt),B=Yl(gt,Ct,B,rt,xt),rt=q.nextZ;rt&&rt.z<=B;){if(rt!==q.prev&&rt!==q.next&&Zl(A.x,A.y,L.x,L.y,H.x,H.y,rt.x,rt.y)&&0<=Ji(rt.prev,rt,rt.next)){q=!1;break t}rt=rt.nextZ}for(rt=q.prevZ;rt&&rt.z>=T;){if(rt!==q.prev&&rt!==q.next&&Zl(A.x,A.y,L.x,L.y,H.x,H.y,rt.x,rt.y)&&0<=Ji(rt.prev,rt,rt.next)){q=!1;break t}rt=rt.prevZ}q=!0}}else t:if(q=t,A=q.prev,L=q,H=q.next,0<=Ji(A,L,H))q=!1;else{for(T=q.next.next;T!==q.prev;){if(Zl(A.x,A.y,L.x,L.y,H.x,H.y,T.x,T.y)&&0<=Ji(T.prev,T,T.next)){q=!1;break t}T=T.next}q=!0}if(q)e.push(_.i/i),e.push(t.i/i),e.push(J.i/i),Yi(t),p=t=J.next;else if(t=J,t===p){if(!d)va(ga(t),e,i,n,s,l,1);else if(d===1){d=e,p=i,_=t;do J=_.prev,q=_.next.next,!Ms(J,q)&&Bh(J,_,_.next,q)&&Rr(J,q)&&Rr(q,J)&&(d.push(J.i/p),d.push(_.i/p),d.push(q.i/p),Yi(_),Yi(_.next),_=t=q),_=_.next;while(_!==t);t=_,va(t,e,i,n,s,l,2)}else if(d===2)t:{d=t;do{for(p=d.next.next;p!==d.prev;){if(_=d.i!==p.i){if(_=d,J=p,q=_.next.i!==J.i&&_.prev.i!==J.i){e:{q=_;do{if(q.i!==_.i&&q.next.i!==_.i&&q.i!==J.i&&q.next.i!==J.i&&Bh(q,q.next,_,J)){q=!0;break e}q=q.next}while(q!==_);q=!1}q=!q}if(q=q&&Rr(_,J)&&Rr(J,_)){q=_,A=!1,L=(_.x+J.x)/2,J=(_.y+J.y)/2;do q.y>J!=q.next.y>J&&q.next.y!==q.y&&L<(q.next.x-q.x)*(J-q.y)/(q.next.y-q.y)+q.x&&(A=!A),q=q.next;while(q!==_);q=A}_=q}if(_){t=nl(d,p),d=ga(d,d.next),t=ga(t,t.next),va(d,e,i,n,s,l),va(t,e,i,n,s,l);break t}p=p.next}d=d.next}while(d!==t)}break}}}}function Su(t,e){return t.x-e.x}function Eu(t,e){var i=e,n=t.x,s=t.y,l=-1/0;do{if(s<=i.y&&s>=i.next.y&&i.next.y!==i.y){var d=i.x+(s-i.y)*(i.next.x-i.x)/(i.next.y-i.y);if(d<=n&&d>l){if(l=d,d===n){if(s===i.y)return i;if(s===i.next.y)return i.next}var p=i.x<i.next.x?i:i.next}}i=i.next}while(i!==e);if(!p)return null;if(n===l)return p.prev;e=p,d=p.x;var _=p.y,T=1/0;for(i=p.next;i!==e;){if(n>=i.x&&i.x>=d&&n!==i.x&&Zl(s<_?n:l,s,d,_,s<_?l:n,s,i.x,i.y)){var A=Math.abs(s-i.y)/(n-i.x);(A<T||A===T&&i.x>p.x)&&Rr(i,t)&&(p=i,T=A)}i=i.next}return p}function Yl(t,e,i,n,s){return t=32767*(t-i)*s,e=32767*(e-n)*s,t=(t|t<<8)&16711935,t=(t|t<<4)&252645135,t=(t|t<<2)&858993459,e=(e|e<<8)&16711935,e=(e|e<<4)&252645135,e=(e|e<<2)&858993459,(t|t<<1)&1431655765|((e|e<<1)&1431655765)<<1}function yr(t){var e=t,i=t;do e.x<i.x&&(i=e),e=e.next;while(e!==t);return i}function Zl(t,e,i,n,s,l,d,p){return 0<=(s-d)*(e-p)-(t-d)*(l-p)&&0<=(t-d)*(n-p)-(i-d)*(e-p)&&0<=(i-d)*(l-p)-(s-d)*(n-p)}function Ji(t,e,i){return(e.y-t.y)*(i.x-e.x)-(e.x-t.x)*(i.y-e.y)}function Ms(t,e){return t.x===e.x&&t.y===e.y}function Bh(t,e,i,n){return Ms(t,e)&&Ms(i,n)||Ms(t,n)&&Ms(i,e)?!0:0<Ji(t,e,i)!=0<Ji(t,e,n)&&0<Ji(i,n,t)!=0<Ji(i,n,e)}function Rr(t,e){return 0>Ji(t.prev,t,t.next)?0<=Ji(t,e,t.next)&&0<=Ji(t,t.prev,e):0>Ji(t,e,t.prev)||0>Ji(t,t.next,e)}function nl(t,e){var i=new fo(t.i,t.x,t.y),n=new fo(e.i,e.x,e.y),s=t.next,l=e.prev;return t.next=e,e.prev=t,i.next=s,s.prev=i,n.next=i,i.prev=n,l.next=n,n.prev=l,n}function Jl(t,e,i,n){return t=new fo(t,e,i),n?(t.next=n.next,t.prev=n,n.next.prev=t,n.next=t):(t.prev=t,t.next=t),t}function Yi(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function fo(t,e,i){this.i=t,this.x=e,this.y=i,this.nextZ=this.prevZ=this.z=this.next=this.prev=null,this.steiner=!1}function $l(t){var e=t.length;2<e&&t[e-1].equals(t[0])&&t.pop()}function bu(t,e){for(var i=0;i<e.length;i++)t.push(e[i].x),t.push(e[i].y)}function Po(t,e){X.call(this),this.type="ExtrudeGeometry",this.parameters={shapes:t,options:e},this.fromBufferGeometry(new po(t,e)),this.mergeVertices()}function po(t,e){function i(_){function T(Xe,ri,Li){return ri.clone().multiplyScalar(Li).add(Xe)}function A(Xe,ri,Li){var Ai=Xe.x-ri.x,ne=Xe.y-ri.y,ii=Li.x-Xe.x,Je=Li.y-Xe.y,li=Ai*Ai+ne*ne;if(Math.abs(Ai*Je-ne*ii)>Number.EPSILON){var xn=Math.sqrt(li),Pn=Math.sqrt(ii*ii+Je*Je);if(li=ri.x-ne/xn,ri=ri.y+Ai/xn,Je=((Li.x-Je/Pn-li)*Je-(Li.y+ii/Pn-ri)*ii)/(Ai*Je-ne*ii),ii=li+Ai*Je-Xe.x,Ai=ri+ne*Je-Xe.y,ne=ii*ii+Ai*Ai,2>=ne)return new o(ii,Ai);ne=Math.sqrt(ne/2)}else Xe=!1,Ai>Number.EPSILON?ii>Number.EPSILON&&(Xe=!0):Ai<-Number.EPSILON?ii<-Number.EPSILON&&(Xe=!0):Math.sign(ne)===Math.sign(Je)&&(Xe=!0),Xe?(ii=-ne,ne=Math.sqrt(li)):(ii=Ai,Ai=ne,ne=Math.sqrt(li/2));return new o(ii/ne,Ai/ne)}function L(Xe,ri){for(Ce=Xe.length;0<=--Ce;){var Li=Ce,Ai=Ce-1;0>Ai&&(Ai=Xe.length-1);var ne,ii=gt+2*ot;for(ne=0;ne<ii;ne++){var Je=Vi*ne,li=Vi*(ne+1),xn=ri+Ai+Je,Pn=ri+Ai+li;li=ri+Li+li,q(ri+Li+Je),q(xn),q(li),q(xn),q(Pn),q(li),Je=s.length/3,Je=ee.generateSideWallUV(n,s,Je-6,Je-3,Je-2,Je-1),J(Je[0]),J(Je[1]),J(Je[3]),J(Je[1]),J(Je[2]),J(Je[3])}}}function B(Xe,ri,Li){rt.push(Xe),rt.push(ri),rt.push(Li)}function H(Xe,ri,Li){q(Xe),q(ri),q(Li),Xe=s.length/3,Xe=ee.generateTopUV(n,s,Xe-3,Xe-2,Xe-1),J(Xe[0]),J(Xe[1]),J(Xe[2])}function q(Xe){s.push(rt[3*Xe]),s.push(rt[3*Xe+1]),s.push(rt[3*Xe+2])}function J(Xe){l.push(Xe.x),l.push(Xe.y)}var rt=[],xt=e.curveSegments!==void 0?e.curveSegments:12,gt=e.steps!==void 0?e.steps:1,Ct=e.depth!==void 0?e.depth:100,wt=e.bevelEnabled!==void 0?e.bevelEnabled:!0,Vt=e.bevelThickness!==void 0?e.bevelThickness:6,$=e.bevelSize!==void 0?e.bevelSize:Vt-2,ot=e.bevelSegments!==void 0?e.bevelSegments:3,kt=e.extrudePath,ee=e.UVGenerator!==void 0?e.UVGenerator:Tl;e.amount!==void 0&&(Ct=e.amount);var $t=!1;if(kt){var Yt=kt.getSpacedPoints(gt);$t=!0,wt=!1;var Te=kt.computeFrenetFrames(gt,!1),ge=new u,De=new u,be=new u}wt||($=Vt=ot=0);var ae;xt=_.extractPoints(xt),_=xt.shape;var We=xt.holes;if(!To.isClockWise(_)){_=_.reverse();var Qe=0;for(ae=We.length;Qe<ae;Qe++){var fi=We[Qe];To.isClockWise(fi)&&(We[Qe]=fi.reverse())}}var Cn=To.triangulateShape(_,We),_n=_;for(Qe=0,ae=We.length;Qe<ae;Qe++)fi=We[Qe],_=_.concat(fi);var qi,Vi=_.length,on,An=Cn.length;xt=[];var Ce=0,ti=_n.length,Ht=ti-1;for(qi=Ce+1;Ce<ti;Ce++,Ht++,qi++)Ht===ti&&(Ht=0),qi===ti&&(qi=0),xt[Ce]=A(_n[Ce],_n[Ht],_n[qi]);kt=[];var Ye=xt.concat();for(Qe=0,ae=We.length;Qe<ae;Qe++){fi=We[Qe];var ei=[];for(Ce=0,ti=fi.length,Ht=ti-1,qi=Ce+1;Ce<ti;Ce++,Ht++,qi++)Ht===ti&&(Ht=0),qi===ti&&(qi=0),ei[Ce]=A(fi[Ce],fi[Ht],fi[qi]);kt.push(ei),Ye=Ye.concat(ei)}for(Ht=0;Ht<ot;Ht++){ti=Ht/ot;var Wi=Vt*Math.cos(ti*Math.PI/2);for(qi=$*Math.sin(ti*Math.PI/2),Ce=0,ti=_n.length;Ce<ti;Ce++){var Ae=T(_n[Ce],xt[Ce],qi);B(Ae.x,Ae.y,-Wi)}for(Qe=0,ae=We.length;Qe<ae;Qe++)for(fi=We[Qe],ei=kt[Qe],Ce=0,ti=fi.length;Ce<ti;Ce++)Ae=T(fi[Ce],ei[Ce],qi),B(Ae.x,Ae.y,-Wi)}for(qi=$,Ce=0;Ce<Vi;Ce++)Ae=wt?T(_[Ce],Ye[Ce],qi):_[Ce],$t?(De.copy(Te.normals[0]).multiplyScalar(Ae.x),ge.copy(Te.binormals[0]).multiplyScalar(Ae.y),be.copy(Yt[0]).add(De).add(ge),B(be.x,be.y,be.z)):B(Ae.x,Ae.y,0);for(ti=1;ti<=gt;ti++)for(Ce=0;Ce<Vi;Ce++)Ae=wt?T(_[Ce],Ye[Ce],qi):_[Ce],$t?(De.copy(Te.normals[ti]).multiplyScalar(Ae.x),ge.copy(Te.binormals[ti]).multiplyScalar(Ae.y),be.copy(Yt[ti]).add(De).add(ge),B(be.x,be.y,be.z)):B(Ae.x,Ae.y,Ct/gt*ti);for(Ht=ot-1;0<=Ht;Ht--){for(ti=Ht/ot,Wi=Vt*Math.cos(ti*Math.PI/2),qi=$*Math.sin(ti*Math.PI/2),Ce=0,ti=_n.length;Ce<ti;Ce++)Ae=T(_n[Ce],xt[Ce],qi),B(Ae.x,Ae.y,Ct+Wi);for(Qe=0,ae=We.length;Qe<ae;Qe++)for(fi=We[Qe],ei=kt[Qe],Ce=0,ti=fi.length;Ce<ti;Ce++)Ae=T(fi[Ce],ei[Ce],qi),$t?B(Ae.x,Ae.y+Yt[gt-1].y,Yt[gt-1].x+Wi):B(Ae.x,Ae.y,Ct+Wi)}(function(){var Xe=s.length/3;if(wt){var ri=0*Vi;for(Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[2]+ri,on[1]+ri,on[0]+ri);for(ri=Vi*(gt+2*ot),Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[0]+ri,on[1]+ri,on[2]+ri)}else{for(Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[2],on[1],on[0]);for(Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[0]+Vi*gt,on[1]+Vi*gt,on[2]+Vi*gt)}n.addGroup(Xe,s.length/3-Xe,0)})(),function(){var Xe=s.length/3,ri=0;for(L(_n,ri),ri+=_n.length,Qe=0,ae=We.length;Qe<ae;Qe++)fi=We[Qe],L(fi,ri),ri+=fi.length;n.addGroup(Xe,s.length/3-Xe,1)}()}Ft.call(this),this.type="ExtrudeBufferGeometry",this.parameters={shapes:t,options:e},t=Array.isArray(t)?t:[t];for(var n=this,s=[],l=[],d=0,p=t.length;d<p;d++)i(t[d]);this.addAttribute("position",new Et(s,3)),this.addAttribute("uv",new Et(l,2)),this.computeVertexNormals()}function Cu(t,e,i){if(i.shapes=[],Array.isArray(t))for(var n=0,s=t.length;n<s;n++)i.shapes.push(t[n].uuid);else i.shapes.push(t.uuid);return e.extrudePath!==void 0&&(i.options.extrudePath=e.extrudePath.toJSON()),i}function rl(t,e){X.call(this),this.type="TextGeometry",this.parameters={text:t,parameters:e},this.fromBufferGeometry(new Ss(t,e)),this.mergeVertices()}function Ss(t,e){e=e||{};var i=e.font;if(!i||!i.isFont)return new X;t=i.generateShapes(t,e.size),e.depth=e.height!==void 0?e.height:50,e.bevelThickness===void 0&&(e.bevelThickness=10),e.bevelSize===void 0&&(e.bevelSize=8),e.bevelEnabled===void 0&&(e.bevelEnabled=!1),po.call(this,t,e),this.type="TextBufferGeometry"}function $o(t,e,i,n,s,l,d){X.call(this),this.type="SphereGeometry",this.parameters={radius:t,widthSegments:e,heightSegments:i,phiStart:n,phiLength:s,thetaStart:l,thetaLength:d},this.fromBufferGeometry(new Or(t,e,i,n,s,l,d)),this.mergeVertices()}function Or(t,e,i,n,s,l,d){Ft.call(this),this.type="SphereBufferGeometry",this.parameters={radius:t,widthSegments:e,heightSegments:i,phiStart:n,phiLength:s,thetaStart:l,thetaLength:d},t=t||1,e=Math.max(3,Math.floor(e)||8),i=Math.max(2,Math.floor(i)||6),n=n!==void 0?n:0,s=s!==void 0?s:2*Math.PI,l=l!==void 0?l:0,d=d!==void 0?d:Math.PI;var p=l+d,_,T,A=0,L=[],B=new u,H=new u,q=[],J=[],rt=[],xt=[];for(T=0;T<=i;T++){var gt=[],Ct=T/i;for(_=0;_<=e;_++){var wt=_/e;B.x=-t*Math.cos(n+wt*s)*Math.sin(l+Ct*d),B.y=t*Math.cos(l+Ct*d),B.z=t*Math.sin(n+wt*s)*Math.sin(l+Ct*d),J.push(B.x,B.y,B.z),H.set(B.x,B.y,B.z).normalize(),rt.push(H.x,H.y,H.z),xt.push(wt,1-Ct),gt.push(A++)}L.push(gt)}for(T=0;T<i;T++)for(_=0;_<e;_++)t=L[T][_+1],n=L[T][_],s=L[T+1][_],d=L[T+1][_+1],(T!==0||0<l)&&q.push(t,n,d),(T!==i-1||p<Math.PI)&&q.push(n,s,d);this.setIndex(q),this.addAttribute("position",new Et(J,3)),this.addAttribute("normal",new Et(rt,3)),this.addAttribute("uv",new Et(xt,2))}function ol(t,e,i,n,s,l){X.call(this),this.type="RingGeometry",this.parameters={innerRadius:t,outerRadius:e,thetaSegments:i,phiSegments:n,thetaStart:s,thetaLength:l},this.fromBufferGeometry(new Es(t,e,i,n,s,l)),this.mergeVertices()}function Es(t,e,i,n,s,l){Ft.call(this),this.type="RingBufferGeometry",this.parameters={innerRadius:t,outerRadius:e,thetaSegments:i,phiSegments:n,thetaStart:s,thetaLength:l},t=t||.5,e=e||1,s=s!==void 0?s:0,l=l!==void 0?l:2*Math.PI,i=i!==void 0?Math.max(3,i):8,n=n!==void 0?Math.max(1,n):1;var d=[],p=[],_=[],T=[],A=t,L=(e-t)/n,B=new u,H=new o,q,J;for(q=0;q<=n;q++){for(J=0;J<=i;J++)t=s+J/i*l,B.x=A*Math.cos(t),B.y=A*Math.sin(t),p.push(B.x,B.y,B.z),_.push(0,0,1),H.x=(B.x/e+1)/2,H.y=(B.y/e+1)/2,T.push(H.x,H.y);A+=L}for(q=0;q<n;q++)for(e=q*(i+1),J=0;J<i;J++)t=J+e,s=t+i+1,l=t+i+2,A=t+1,d.push(t,s,A),d.push(s,l,A);this.setIndex(d),this.addAttribute("position",new Et(p,3)),this.addAttribute("normal",new Et(_,3)),this.addAttribute("uv",new Et(T,2))}function ya(t,e,i,n){X.call(this),this.type="LatheGeometry",this.parameters={points:t,segments:e,phiStart:i,phiLength:n},this.fromBufferGeometry(new Ko(t,e,i,n)),this.mergeVertices()}function Ko(t,e,i,n){Ft.call(this),this.type="LatheBufferGeometry",this.parameters={points:t,segments:e,phiStart:i,phiLength:n},e=Math.floor(e)||12,i=i||0,n=n||2*Math.PI,n=di.clamp(n,0,2*Math.PI);var s=[],l=[],d=[],p=1/e,_=new u,T=new o,A;for(A=0;A<=e;A++){var L=i+A*p*n,B=Math.sin(L),H=Math.cos(L);for(L=0;L<=t.length-1;L++)_.x=t[L].x*B,_.y=t[L].y,_.z=t[L].x*H,l.push(_.x,_.y,_.z),T.x=A/e,T.y=L/(t.length-1),d.push(T.x,T.y)}for(A=0;A<e;A++)for(L=0;L<t.length-1;L++)i=L+A*t.length,p=i+t.length,_=i+t.length+1,T=i+1,s.push(i,p,T),s.push(p,_,T);if(this.setIndex(s),this.addAttribute("position",new Et(l,3)),this.addAttribute("uv",new Et(d,2)),this.computeVertexNormals(),n===2*Math.PI)for(n=this.attributes.normal.array,s=new u,l=new u,d=new u,i=e*t.length*3,L=A=0;A<t.length;A++,L+=3)s.x=n[L+0],s.y=n[L+1],s.z=n[L+2],l.x=n[i+L+0],l.y=n[i+L+1],l.z=n[i+L+2],d.addVectors(s,l).normalize(),n[L+0]=n[i+L+0]=d.x,n[L+1]=n[i+L+1]=d.y,n[L+2]=n[i+L+2]=d.z}function Lo(t,e){X.call(this),this.type="ShapeGeometry",typeof e=="object"&&(e=e.curveSegments),this.parameters={shapes:t,curveSegments:e},this.fromBufferGeometry(new Qo(t,e)),this.mergeVertices()}function Qo(t,e){function i(A){var L,B=s.length/3;A=A.extractPoints(e);var H=A.shape,q=A.holes;if(To.isClockWise(H)===!1)for(H=H.reverse(),A=0,L=q.length;A<L;A++){var J=q[A];To.isClockWise(J)===!0&&(q[A]=J.reverse())}var rt=To.triangulateShape(H,q);for(A=0,L=q.length;A<L;A++)J=q[A],H=H.concat(J);for(A=0,L=H.length;A<L;A++)J=H[A],s.push(J.x,J.y,0),l.push(0,0,1),d.push(J.x,J.y);for(A=0,L=rt.length;A<L;A++)H=rt[A],n.push(H[0]+B,H[1]+B,H[2]+B),_+=3}Ft.call(this),this.type="ShapeBufferGeometry",this.parameters={shapes:t,curveSegments:e},e=e||12;var n=[],s=[],l=[],d=[],p=0,_=0;if(Array.isArray(t)===!1)i(t);else for(var T=0;T<t.length;T++)i(t[T]),this.addGroup(p,_,T),p+=_,_=0;this.setIndex(n),this.addAttribute("position",new Et(s,3)),this.addAttribute("normal",new Et(l,3)),this.addAttribute("uv",new Et(d,2))}function Au(t,e){if(e.shapes=[],Array.isArray(t))for(var i=0,n=t.length;i<n;i++)e.shapes.push(t[i].uuid);else e.shapes.push(t.uuid);return e}function ts(t,e){Ft.call(this),this.type="EdgesGeometry",this.parameters={thresholdAngle:e};var i=[];e=Math.cos(di.DEG2RAD*(e!==void 0?e:1));var n=[0,0],s={},l=["a","b","c"];if(t.isBufferGeometry){var d=new X;d.fromBufferGeometry(t)}else d=t.clone();d.mergeVertices(),d.computeFaceNormals(),t=d.vertices,d=d.faces;for(var p=0,_=d.length;p<_;p++)for(var T=d[p],A=0;3>A;A++){var L=T[l[A]],B=T[l[(A+1)%3]];n[0]=Math.min(L,B),n[1]=Math.max(L,B),L=n[0]+","+n[1],s[L]===void 0?s[L]={index1:n[0],index2:n[1],face1:p,face2:void 0}:s[L].face2=p}for(L in s)n=s[L],(n.face2===void 0||d[n.face1].normal.dot(d[n.face2].normal)<=e)&&(l=t[n.index1],i.push(l.x,l.y,l.z),l=t[n.index2],i.push(l.x,l.y,l.z));this.addAttribute("position",new Et(i,3))}function Ro(t,e,i,n,s,l,d,p){X.call(this),this.type="CylinderGeometry",this.parameters={radiusTop:t,radiusBottom:e,height:i,radialSegments:n,heightSegments:s,openEnded:l,thetaStart:d,thetaLength:p},this.fromBufferGeometry(new Oo(t,e,i,n,s,l,d,p)),this.mergeVertices()}function Oo(t,e,i,n,s,l,d,p){function _(gt){var Ct,wt=new o,Vt=new u,$=0,ot=gt===!0?t:e,kt=gt===!0?1:-1,ee=q;for(Ct=1;Ct<=n;Ct++)L.push(0,rt*kt,0),B.push(0,kt,0),H.push(.5,.5),q++;var $t=q;for(Ct=0;Ct<=n;Ct++){var Yt=Ct/n*p+d,Te=Math.cos(Yt);Yt=Math.sin(Yt),Vt.x=ot*Yt,Vt.y=rt*kt,Vt.z=ot*Te,L.push(Vt.x,Vt.y,Vt.z),B.push(0,kt,0),wt.x=.5*Te+.5,wt.y=.5*Yt*kt+.5,H.push(wt.x,wt.y),q++}for(Ct=0;Ct<n;Ct++)wt=ee+Ct,Vt=$t+Ct,gt===!0?A.push(Vt,Vt+1,wt):A.push(Vt+1,Vt,wt),$+=3;T.addGroup(xt,$,gt===!0?1:2),xt+=$}Ft.call(this),this.type="CylinderBufferGeometry",this.parameters={radiusTop:t,radiusBottom:e,height:i,radialSegments:n,heightSegments:s,openEnded:l,thetaStart:d,thetaLength:p};var T=this;t=t!==void 0?t:1,e=e!==void 0?e:1,i=i||1,n=Math.floor(n)||8,s=Math.floor(s)||1,l=l!==void 0?l:!1,d=d!==void 0?d:0,p=p!==void 0?p:2*Math.PI;var A=[],L=[],B=[],H=[],q=0,J=[],rt=i/2,xt=0;(function(){var gt,Ct,wt=new u,Vt=new u,$=0,ot=(e-t)/i;for(Ct=0;Ct<=s;Ct++){var kt=[],ee=Ct/s,$t=ee*(e-t)+t;for(gt=0;gt<=n;gt++){var Yt=gt/n,Te=Yt*p+d,ge=Math.sin(Te);Te=Math.cos(Te),Vt.x=$t*ge,Vt.y=-ee*i+rt,Vt.z=$t*Te,L.push(Vt.x,Vt.y,Vt.z),wt.set(ge,ot,Te).normalize(),B.push(wt.x,wt.y,wt.z),H.push(Yt,1-ee),kt.push(q++)}J.push(kt)}for(gt=0;gt<n;gt++)for(Ct=0;Ct<s;Ct++)wt=J[Ct+1][gt],Vt=J[Ct+1][gt+1],ot=J[Ct][gt+1],A.push(J[Ct][gt],wt,ot),A.push(wt,Vt,ot),$+=6;T.addGroup(xt,$,0),xt+=$})(),l===!1&&(0<t&&_(!0),0<e&&_(!1)),this.setIndex(A),this.addAttribute("position",new Et(L,3)),this.addAttribute("normal",new Et(B,3)),this.addAttribute("uv",new Et(H,2))}function _a(t,e,i,n,s,l,d){Ro.call(this,0,t,e,i,n,s,l,d),this.type="ConeGeometry",this.parameters={radius:t,height:e,radialSegments:i,heightSegments:n,openEnded:s,thetaStart:l,thetaLength:d}}function Gn(t,e,i,n,s,l,d){Oo.call(this,0,t,e,i,n,s,l,d),this.type="ConeBufferGeometry",this.parameters={radius:t,height:e,radialSegments:i,heightSegments:n,openEnded:s,thetaStart:l,thetaLength:d}}function bs(t,e,i,n){X.call(this),this.type="CircleGeometry",this.parameters={radius:t,segments:e,thetaStart:i,thetaLength:n},this.fromBufferGeometry(new mo(t,e,i,n)),this.mergeVertices()}function mo(t,e,i,n){Ft.call(this),this.type="CircleBufferGeometry",this.parameters={radius:t,segments:e,thetaStart:i,thetaLength:n},t=t||1,e=e!==void 0?Math.max(3,e):8,i=i!==void 0?i:0,n=n!==void 0?n:2*Math.PI;var s=[],l=[],d=[],p=[],_,T=new u,A=new o;l.push(0,0,0),d.push(0,0,1),p.push(.5,.5);var L=0;for(_=3;L<=e;L++,_+=3){var B=i+L/e*n;T.x=t*Math.cos(B),T.y=t*Math.sin(B),l.push(T.x,T.y,T.z),d.push(0,0,1),A.x=(l[_]/t+1)/2,A.y=(l[_+1]/t+1)/2,p.push(A.x,A.y)}for(_=1;_<=e;_++)s.push(_,_+1,0);this.setIndex(s),this.addAttribute("position",new Et(l,3)),this.addAttribute("normal",new Et(d,3)),this.addAttribute("uv",new Et(p,2))}function es(t){Wt.call(this),this.type="ShadowMaterial",this.color=new P(0),this.transparent=!0,this.setValues(t)}function Cs(t){$e.call(this,t),this.type="RawShaderMaterial"}function go(t){Wt.call(this),this.defines={STANDARD:""},this.type="MeshStandardMaterial",this.color=new P(16777215),this.metalness=this.roughness=.5,this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new P(0),this.emissiveIntensity=1,this.bumpMap=this.emissiveMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.envMap=this.alphaMap=this.metalnessMap=this.roughnessMap=null,this.envMapIntensity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t)}function As(t){go.call(this),this.defines={PHYSICAL:""},this.type="MeshPhysicalMaterial",this.reflectivity=.5,this.clearCoatRoughness=this.clearCoat=0,this.setValues(t)}function Jr(t){Wt.call(this),this.type="MeshPhongMaterial",this.color=new P(16777215),this.specular=new P(1118481),this.shininess=30,this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new P(0),this.emissiveIntensity=1,this.bumpMap=this.emissiveMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.envMap=this.alphaMap=this.specularMap=null,this.combine=0,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t)}function Ps(t){Jr.call(this),this.defines={TOON:""},this.type="MeshToonMaterial",this.gradientMap=null,this.setValues(t)}function Ls(t){Wt.call(this),this.type="MeshNormalMaterial",this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.morphNormals=this.morphTargets=this.skinning=this.lights=this.fog=!1,this.setValues(t)}function Ir(t){Wt.call(this),this.type="MeshLambertMaterial",this.color=new P(16777215),this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new P(0),this.emissiveIntensity=1,this.envMap=this.alphaMap=this.specularMap=this.emissiveMap=null,this.combine=0,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t)}function Rs(t){if(Wt.call(this),this.defines={MATCAP:""},this.type="MeshMatcapMaterial",this.color=new P(16777215),this.bumpMap=this.map=this.matcap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.lights=this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t),this.matcap===null){t=document.createElement("canvas"),t.width=1,t.height=1;var e=t.getContext("2d");e.fillStyle="#fff",e.fillRect(0,0,1,1),this.matcap=new THREE.CanvasTexture(t)}}function Os(t){Ni.call(this),this.type="LineDashedMaterial",this.scale=1,this.dashSize=3,this.gapSize=1,this.setValues(t)}function $n(t,e,i,n){this.parameterPositions=t,this._cachedIndex=0,this.resultBuffer=n!==void 0?n:new e.constructor(i),this.sampleValues=e,this.valueSize=i}function sl(t,e,i,n){$n.call(this,t,e,i,n),this._offsetNext=this._weightNext=this._offsetPrev=this._weightPrev=-0}function Dr(t,e,i,n){$n.call(this,t,e,i,n)}function Is(t,e,i,n){$n.call(this,t,e,i,n)}function Hn(t,e,i,n){if(t===void 0)throw Error("THREE.KeyframeTrack: track name is undefined");if(e===void 0||e.length===0)throw Error("THREE.KeyframeTrack: no keyframes in track named "+t);this.name=t,this.times=Yn.convertArray(e,this.TimeBufferType),this.values=Yn.convertArray(i,this.ValueBufferType),this.setInterpolation(n||this.DefaultInterpolation)}function Kl(t,e,i){Hn.call(this,t,e,i)}function Ql(t,e,i,n){Hn.call(this,t,e,i,n)}function $r(t,e,i,n){Hn.call(this,t,e,i,n)}function ar(t,e,i,n){$n.call(this,t,e,i,n)}function xa(t,e,i,n){Hn.call(this,t,e,i,n)}function th(t,e,i,n){Hn.call(this,t,e,i,n)}function wa(t,e,i,n){Hn.call(this,t,e,i,n)}function _r(t,e,i){this.name=t,this.tracks=i,this.duration=e!==void 0?e:-1,this.uuid=di.generateUUID(),0>this.duration&&this.resetDuration()}function jc(t){switch(t.toLowerCase()){case"scalar":case"double":case"float":case"number":case"integer":return $r;case"vector":case"vector2":case"vector3":case"vector4":return wa;case"color":return Ql;case"quaternion":return xa;case"bool":case"boolean":return Kl;case"string":return th}throw Error("THREE.KeyframeTrack: Unsupported typeName: "+t)}function Xc(t){if(t.type===void 0)throw Error("THREE.KeyframeTrack: track type undefined, can not parse");var e=jc(t.type);if(t.times===void 0){var i=[],n=[];Yn.flattenJSON(t.keys,i,n,"value"),t.times=i,t.values=n}return e.parse!==void 0?e.parse(t):new e(t.name,t.times,t.values,t.interpolation)}function is(t,e,i){var n=this,s=!1,l=0,d=0,p=void 0;this.onStart=void 0,this.onLoad=t,this.onProgress=e,this.onError=i,this.itemStart=function(_){d++,s===!1&&n.onStart!==void 0&&n.onStart(_,l,d),s=!0},this.itemEnd=function(_){l++,n.onProgress!==void 0&&n.onProgress(_,l,d),l===d&&(s=!1,n.onLoad!==void 0)&&n.onLoad()},this.itemError=function(_){n.onError!==void 0&&n.onError(_)},this.resolveURL=function(_){return p?p(_):_},this.setURLModifier=function(_){return p=_,this}}function Lt(t){this.manager=t!==void 0?t:tr}function Qt(t){this.manager=t!==void 0?t:tr}function Zt(t){this.manager=t!==void 0?t:tr,this._parser=null}function Ue(t){this.manager=t!==void 0?t:tr,this._parser=null}function ai(t){this.manager=t!==void 0?t:tr}function Fi(t){this.manager=t!==void 0?t:tr}function fn(t){this.manager=t!==void 0?t:tr}function Ee(){this.type="Curve",this.arcLengthDivisions=200}function Kn(t,e,i,n,s,l,d,p){Ee.call(this),this.type="EllipseCurve",this.aX=t||0,this.aY=e||0,this.xRadius=i||1,this.yRadius=n||1,this.aStartAngle=s||0,this.aEndAngle=l||2*Math.PI,this.aClockwise=d||!1,this.aRotation=p||0}function Ta(t,e,i,n,s,l){Kn.call(this,t,e,i,i,n,s,l),this.type="ArcCurve"}function lr(){var t=0,e=0,i=0,n=0;return{initCatmullRom:function(s,l,d,p,_){s=_*(d-s),p=_*(p-l),t=l,e=s,i=-3*l+3*d-2*s-p,n=2*l-2*d+s+p},initNonuniformCatmullRom:function(s,l,d,p,_,T,A){s=((l-s)/_-(d-s)/(_+T)+(d-l)/T)*T,p=((d-l)/T-(p-l)/(T+A)+(p-d)/A)*T,t=l,e=s,i=-3*l+3*d-2*s-p,n=2*l-2*d+s+p},calc:function(s){var l=s*s;return t+e*s+i*l+n*l*s}}}function On(t,e,i,n){Ee.call(this),this.type="CatmullRomCurve3",this.points=t||[],this.closed=e||!1,this.curveType=i||"centripetal",this.tension=n||.5}function Pu(t,e,i,n,s){e=.5*(n-e),s=.5*(s-i);var l=t*t;return(2*i-2*n+e+s)*t*l+(-3*i+3*n-2*e-s)*l+e*t+i}function vo(t,e,i,n){var s=1-t;return s*s*e+2*(1-t)*t*i+t*t*n}function ns(t,e,i,n,s){var l=1-t,d=1-t;return l*l*l*e+3*d*d*t*i+3*(1-t)*t*t*n+t*t*t*s}function hr(t,e,i,n){Ee.call(this),this.type="CubicBezierCurve",this.v0=t||new o,this.v1=e||new o,this.v2=i||new o,this.v3=n||new o}function Ti(t,e,i,n){Ee.call(this),this.type="CubicBezierCurve3",this.v0=t||new u,this.v1=e||new u,this.v2=i||new u,this.v3=n||new u}function ur(t,e){Ee.call(this),this.type="LineCurve",this.v1=t||new o,this.v2=e||new o}function zr(t,e){Ee.call(this),this.type="LineCurve3",this.v1=t||new u,this.v2=e||new u}function cr(t,e,i){Ee.call(this),this.type="QuadraticBezierCurve",this.v0=t||new o,this.v1=e||new o,this.v2=i||new o}function yo(t,e,i){Ee.call(this),this.type="QuadraticBezierCurve3",this.v0=t||new u,this.v1=e||new u,this.v2=i||new u}function Kr(t){Ee.call(this),this.type="SplineCurve",this.points=t||[]}function Io(){Ee.call(this),this.type="CurvePath",this.curves=[],this.autoClose=!1}function fr(t){Io.call(this),this.type="Path",this.currentPoint=new o,t&&this.setFromPoints(t)}function Qn(t){fr.call(this,t),this.uuid=di.generateUUID(),this.type="Shape",this.holes=[]}function tn(t,e){F.call(this),this.type="Light",this.color=new P(t),this.intensity=e!==void 0?e:1,this.receiveShadow=void 0}function al(t,e,i){tn.call(this,t,i),this.type="HemisphereLight",this.castShadow=void 0,this.position.copy(F.DefaultUp),this.updateMatrix(),this.groundColor=new P(e)}function _o(t){this.camera=t,this.bias=0,this.radius=1,this.mapSize=new o(512,512),this.map=null,this.matrix=new c}function ll(){_o.call(this,new _e(50,1,.5,500))}function hl(t,e,i,n,s,l){tn.call(this,t,e),this.type="SpotLight",this.position.copy(F.DefaultUp),this.updateMatrix(),this.target=new F,Object.defineProperty(this,"power",{get:function(){return this.intensity*Math.PI},set:function(d){this.intensity=d/Math.PI}}),this.distance=i!==void 0?i:0,this.angle=n!==void 0?n:Math.PI/3,this.penumbra=s!==void 0?s:0,this.decay=l!==void 0?l:1,this.shadow=new ll}function Ds(t,e,i,n){tn.call(this,t,e),this.type="PointLight",Object.defineProperty(this,"power",{get:function(){return 4*this.intensity*Math.PI},set:function(s){this.intensity=s/(4*Math.PI)}}),this.distance=i!==void 0?i:0,this.decay=n!==void 0?n:1,this.shadow=new _o(new _e(90,1,.5,500))}function Ma(t,e,i,n,s,l){Be.call(this),this.type="OrthographicCamera",this.zoom=1,this.view=null,this.left=t!==void 0?t:-1,this.right=e!==void 0?e:1,this.top=i!==void 0?i:1,this.bottom=n!==void 0?n:-1,this.near=s!==void 0?s:.1,this.far=l!==void 0?l:2e3,this.updateProjectionMatrix()}function rs(){_o.call(this,new Ma(-5,5,5,-5,.5,500))}function xo(t,e){tn.call(this,t,e),this.type="DirectionalLight",this.position.copy(F.DefaultUp),this.updateMatrix(),this.target=new F,this.shadow=new rs}function zs(t,e){tn.call(this,t,e),this.type="AmbientLight",this.castShadow=void 0}function eh(t,e,i,n){tn.call(this,t,e),this.type="RectAreaLight",this.width=i!==void 0?i:10,this.height=n!==void 0?n:10}function ih(t){this.manager=t!==void 0?t:tr,this.textures={}}function Nh(t){this.manager=t!==void 0?t:tr}function Do(){}function ks(t){typeof t=="boolean"&&(t=void 0),this.manager=t!==void 0?t:tr,this.withCredentials=!1}function ul(t){this.manager=t!==void 0?t:tr,this.resourcePath=""}function Fh(t){typeof createImageBitmap>"u",typeof fetch>"u",this.manager=t!==void 0?t:tr,this.options=void 0}function nh(){this.type="ShapePath",this.color=new P,this.subPaths=[],this.currentPath=null}function Uh(t){this.type="Font",this.data=t}function Lu(t){this.manager=t!==void 0?t:tr}function vn(t){this.manager=t!==void 0?t:tr}function Vn(){this.type="StereoCamera",this.aspect=1,this.eyeSep=.064,this.cameraL=new _e,this.cameraL.layers.enable(1),this.cameraL.matrixAutoUpdate=!1,this.cameraR=new _e,this.cameraR.layers.enable(2),this.cameraR.matrixAutoUpdate=!1}function cl(t,e,i,n){F.call(this),this.type="CubeCamera";var s=new _e(90,1,t,e);s.up.set(0,-1,0),s.lookAt(new u(1,0,0)),this.add(s);var l=new _e(90,1,t,e);l.up.set(0,-1,0),l.lookAt(new u(-1,0,0)),this.add(l);var d=new _e(90,1,t,e);d.up.set(0,0,1),d.lookAt(new u(0,1,0)),this.add(d);var p=new _e(90,1,t,e);p.up.set(0,0,-1),p.lookAt(new u(0,-1,0)),this.add(p);var _=new _e(90,1,t,e);_.up.set(0,-1,0),_.lookAt(new u(0,0,1)),this.add(_);var T=new _e(90,1,t,e);T.up.set(0,-1,0),T.lookAt(new u(0,0,-1)),this.add(T),n=n||{format:1022,magFilter:1006,minFilter:1006},this.renderTarget=new b(i,i,n),this.renderTarget.texture.name="CubeCamera",this.update=function(A,L){this.parent===null&&this.updateMatrixWorld();var B=this.renderTarget,H=B.texture.generateMipmaps;B.texture.generateMipmaps=!1,B.activeCubeFace=0,A.render(L,s,B),B.activeCubeFace=1,A.render(L,l,B),B.activeCubeFace=2,A.render(L,d,B),B.activeCubeFace=3,A.render(L,p,B),B.activeCubeFace=4,A.render(L,_,B),B.texture.generateMipmaps=H,B.activeCubeFace=5,A.render(L,T,B),A.setRenderTarget(null)},this.clear=function(A,L,B,H){for(var q=this.renderTarget,J=0;6>J;J++)q.activeCubeFace=J,A.setRenderTarget(q),A.clear(L,B,H);A.setRenderTarget(null)}}function Gh(t){this.autoStart=t!==void 0?t:!0,this.elapsedTime=this.oldTime=this.startTime=0,this.running=!1}function rh(){F.call(this),this.type="AudioListener",this.context=$h.getContext(),this.gain=this.context.createGain(),this.gain.connect(this.context.destination),this.filter=null,this.timeDelta=0}function Sa(t){F.call(this),this.type="Audio",this.listener=t,this.context=t.context,this.gain=this.context.createGain(),this.gain.connect(t.getInput()),this.autoplay=!1,this.buffer=null,this.loop=!1,this.offset=this.startTime=0,this.playbackRate=1,this.isPlaying=!1,this.hasPlaybackControl=!0,this.sourceType="empty",this.filters=[]}function fl(t){Sa.call(this,t),this.panner=this.context.createPanner(),this.panner.connect(this.gain)}function Bs(t,e){this.analyser=t.context.createAnalyser(),this.analyser.fftSize=e!==void 0?e:2048,this.data=new Uint8Array(this.analyser.frequencyBinCount),t.getOutput().connect(this.analyser)}function dl(t,e,i){switch(this.binding=t,this.valueSize=i,t=Float64Array,e){case"quaternion":e=this._slerp;break;case"string":case"bool":t=Array,e=this._select;break;default:e=this._lerp}this.buffer=new t(4*i),this._mixBufferRegion=e,this.referenceCount=this.useCount=this.cumulativeWeight=0}function Ns(t,e,i){i=i||En.parseTrackName(e),this._targetGroup=t,this._bindings=t.subscribe_(e,i)}function En(t,e,i){this.path=e,this.parsedPath=i||En.parseTrackName(e),this.node=En.findNode(t,this.parsedPath.nodeName)||t,this.rootNode=t}function Ea(){this.uuid=di.generateUUID(),this._objects=Array.prototype.slice.call(arguments),this.nCachedObjects_=0;var t={};this._indicesByUUID=t;for(var e=0,i=arguments.length;e!==i;++e)t[arguments[e].uuid]=e;this._paths=[],this._parsedPaths=[],this._bindings=[],this._bindingsIndicesByPath={};var n=this;this.stats={objects:{get total(){return n._objects.length},get inUse(){return this.total-n.nCachedObjects_}},get bindingsPerObject(){return n._bindings.length}}}function pl(t,e,i){this._mixer=t,this._clip=e,this._localRoot=i||null,t=e.tracks,e=t.length,i=Array(e);for(var n={endingStart:2400,endingEnd:2400},s=0;s!==e;++s){var l=t[s].createInterpolant(null);i[s]=l,l.settings=n}this._interpolantSettings=n,this._interpolants=i,this._propertyBindings=Array(e),this._weightInterpolant=this._timeScaleInterpolant=this._byClipCacheIndex=this._cacheIndex=null,this.loop=2201,this._loopCount=-1,this._startTime=null,this.time=0,this._effectiveWeight=this.weight=this._effectiveTimeScale=this.timeScale=1,this.repetitions=1/0,this.paused=!1,this.enabled=!0,this.clampWhenFinished=!1,this.zeroSlopeAtEnd=this.zeroSlopeAtStart=!0}function os(t){this._root=t,this._initMemoryManager(),this.time=this._accuIndex=0,this.timeScale=1}function oh(t,e){typeof t=="string"&&(t=e),this.value=t}function Hh(){Ft.call(this),this.type="InstancedBufferGeometry",this.maxInstancedCount=void 0}function Vh(t,e,i){ki.call(this,t,e),this.meshPerAttribute=i||1}function Wh(t,e,i,n){typeof i=="number"&&(n=i,i=!1),K.call(this,t,e,i),this.meshPerAttribute=n||1}function Ru(t,e,i,n){this.ray=new Si(t,e),this.near=i||0,this.far=n||1/0,this.params={Mesh:{},Line:{},LOD:{},Points:{threshold:1},Sprite:{}},Object.defineProperties(this.params,{PointCloud:{get:function(){return this.Points}}})}function ml(t,e){return t.distance-e.distance}function Fs(t,e,i,n){if(t.visible!==!1&&(t.raycast(e,i),n===!0)){t=t.children,n=0;for(var s=t.length;n<s;n++)Fs(t[n],e,i,!0)}}function jh(t,e,i){return this.radius=t!==void 0?t:1,this.phi=e!==void 0?e:0,this.theta=i!==void 0?i:0,this}function it(t,e,i){return this.radius=t!==void 0?t:1,this.theta=e!==void 0?e:0,this.y=i!==void 0?i:0,this}function ss(t,e){this.min=t!==void 0?t:new o(1/0,1/0),this.max=e!==void 0?e:new o(-1/0,-1/0)}function ba(t,e){this.start=t!==void 0?t:new u,this.end=e!==void 0?e:new u}function qn(t){F.call(this),this.material=t,this.render=function(){}}function _i(t,e,i,n){this.object=t,this.size=e!==void 0?e:1,t=i!==void 0?i:16711680,n=n!==void 0?n:1,e=0,(i=this.object.geometry)&&i.isGeometry?e=3*i.faces.length:i&&i.isBufferGeometry&&(e=i.attributes.normal.count),i=new Ft,e=new Et(6*e,3),i.addAttribute("position",e),gi.call(this,i,new Ni({color:t,linewidth:n})),this.matrixAutoUpdate=!1,this.update()}function Ca(t,e){F.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=e,t=new Ft,e=[0,0,0,0,0,1,0,0,0,1,0,1,0,0,0,-1,0,1,0,0,0,0,1,1,0,0,0,0,-1,1];for(var i=0,n=1;32>i;i++,n++){var s=i/32*Math.PI*2,l=n/32*Math.PI*2;e.push(Math.cos(s),Math.sin(s),1,Math.cos(l),Math.sin(l),1)}t.addAttribute("position",new Et(e,3)),e=new Ni({fog:!1}),this.cone=new gi(t,e),this.add(this.cone),this.update()}function Ou(t){var e=[];t&&t.isBone&&e.push(t);for(var i=0;i<t.children.length;i++)e.push.apply(e,Ou(t.children[i]));return e}function Aa(t){for(var e=Ou(t),i=new Ft,n=[],s=[],l=new P(0,0,1),d=new P(0,1,0),p=0;p<e.length;p++){var _=e[p];_.parent&&_.parent.isBone&&(n.push(0,0,0),n.push(0,0,0),s.push(l.r,l.g,l.b),s.push(d.r,d.g,d.b))}i.addAttribute("position",new Et(n,3)),i.addAttribute("color",new Et(s,3)),n=new Ni({vertexColors:2,depthTest:!1,depthWrite:!1,transparent:!0}),gi.call(this,i,n),this.root=t,this.bones=e,this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1}function kr(t,e,i){this.light=t,this.light.updateMatrixWorld(),this.color=i,t=new Or(e,4,2),e=new Ge({wireframe:!0,fog:!1}),pi.call(this,t,e),this.matrix=this.light.matrixWorld,this.matrixAutoUpdate=!1,this.update()}function Pa(t,e){F.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=e,t=new Ni({fog:!1}),e=new Ft,e.addAttribute("position",new K(new Float32Array(15),3)),this.line=new ji(e,t),this.add(this.line),this.update()}function La(t,e,i){F.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=i,t=new xs(e),t.rotateY(.5*Math.PI),this.material=new Ge({wireframe:!0,fog:!1}),this.color===void 0&&(this.material.vertexColors=2),e=t.getAttribute("position"),e=new Float32Array(3*e.count),t.addAttribute("color",new K(e,3)),this.add(new pi(t,this.material)),this.update()}function gl(t,e,i,n){t=t||10,e=e||10,i=new P(i!==void 0?i:4473924),n=new P(n!==void 0?n:8947848);var s=e/2,l=t/e,d=t/2;t=[];for(var p=[],_=0,T=0,A=-d;_<=e;_++,A+=l){t.push(-d,0,A,d,0,A),t.push(A,0,-d,A,0,d);var L=_===s?i:n;L.toArray(p,T),T+=3,L.toArray(p,T),T+=3,L.toArray(p,T),T+=3,L.toArray(p,T),T+=3}e=new Ft,e.addAttribute("position",new Et(t,3)),e.addAttribute("color",new Et(p,3)),i=new Ni({vertexColors:2}),gi.call(this,e,i)}function sh(t,e,i,n,s,l){t=t||10,e=e||16,i=i||8,n=n||64,s=new P(s!==void 0?s:4473924),l=new P(l!==void 0?l:8947848);var d=[],p=[],_;for(_=0;_<=e;_++){var T=_/e*2*Math.PI,A=Math.sin(T)*t;T=Math.cos(T)*t,d.push(0,0,0),d.push(A,0,T);var L=_&1?s:l;p.push(L.r,L.g,L.b),p.push(L.r,L.g,L.b)}for(_=0;_<=i;_++){L=_&1?s:l;var B=t-t/i*_;for(e=0;e<n;e++)T=e/n*2*Math.PI,A=Math.sin(T)*B,T=Math.cos(T)*B,d.push(A,0,T),p.push(L.r,L.g,L.b),T=(e+1)/n*2*Math.PI,A=Math.sin(T)*B,T=Math.cos(T)*B,d.push(A,0,T),p.push(L.r,L.g,L.b)}t=new Ft,t.addAttribute("position",new Et(d,3)),t.addAttribute("color",new Et(p,3)),d=new Ni({vertexColors:2}),gi.call(this,t,d)}function vl(t,e,i,n){this.object=t,this.size=e!==void 0?e:1,t=i!==void 0?i:16776960,n=n!==void 0?n:1,e=0,(i=this.object.geometry)&&i.isGeometry&&(e=i.faces.length),i=new Ft,e=new Et(6*e,3),i.addAttribute("position",e),gi.call(this,i,new Ni({color:t,linewidth:n})),this.matrixAutoUpdate=!1,this.update()}function dr(t,e,i){F.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=i,e===void 0&&(e=1),t=new Ft,t.addAttribute("position",new Et([-e,e,0,e,e,0,e,-e,0,-e,-e,0,-e,e,0],3)),e=new Ni({fog:!1}),this.lightPlane=new ji(t,e),this.add(this.lightPlane),t=new Ft,t.addAttribute("position",new Et([0,0,0,0,0,1],3)),this.targetLine=new ji(t,e),this.add(this.targetLine),this.update()}function yl(t){function e(H,q,J){i(H,J),i(q,J)}function i(H,q){l.push(0,0,0),d.push(q.r,q.g,q.b),p[H]===void 0&&(p[H]=[]),p[H].push(l.length/3-1)}var n=new Ft,s=new Ni({color:16777215,vertexColors:1}),l=[],d=[],p={},_=new P(16755200),T=new P(16711680),A=new P(43775),L=new P(16777215),B=new P(3355443);e("n1","n2",_),e("n2","n4",_),e("n4","n3",_),e("n3","n1",_),e("f1","f2",_),e("f2","f4",_),e("f4","f3",_),e("f3","f1",_),e("n1","f1",_),e("n2","f2",_),e("n3","f3",_),e("n4","f4",_),e("p","n1",T),e("p","n2",T),e("p","n3",T),e("p","n4",T),e("u1","u2",A),e("u2","u3",A),e("u3","u1",A),e("c","t",L),e("p","c",B),e("cn1","cn2",B),e("cn3","cn4",B),e("cf1","cf2",B),e("cf3","cf4",B),n.addAttribute("position",new Et(l,3)),n.addAttribute("color",new Et(d,3)),gi.call(this,n,s),this.camera=t,this.camera.updateProjectionMatrix&&this.camera.updateProjectionMatrix(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.pointMap=p,this.update()}function zo(t,e){this.object=t,e===void 0&&(e=16776960),t=new Uint16Array([0,1,1,2,2,3,3,0,4,5,5,6,6,7,7,4,0,4,1,5,2,6,3,7]);var i=new Float32Array(24),n=new Ft;n.setIndex(new K(t,1)),n.addAttribute("position",new K(i,3)),gi.call(this,n,new Ni({color:e})),this.matrixAutoUpdate=!1,this.update()}function _l(t,e){this.type="Box3Helper",this.box=t,t=e!==void 0?e:16776960,e=new Uint16Array([0,1,1,2,2,3,3,0,4,5,5,6,6,7,7,4,0,4,1,5,2,6,3,7]);var i=new Ft;i.setIndex(new K(e,1)),i.addAttribute("position",new Et([1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,-1,-1,1,-1,-1,-1,-1,1,-1,-1],3)),gi.call(this,i,new Ni({color:t})),this.geometry.computeBoundingSphere()}function xl(t,e,i){this.type="PlaneHelper",this.plane=t,this.size=e===void 0?1:e,t=i!==void 0?i:16776960,e=new Ft,e.addAttribute("position",new Et([1,-1,1,-1,1,1,-1,-1,1,1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,0,0,1,0,0,0],3)),e.computeBoundingSphere(),ji.call(this,e,new Ni({color:t})),e=new Ft,e.addAttribute("position",new Et([1,1,1,-1,1,1,-1,-1,1,1,1,1,-1,-1,1,1,-1,1],3)),e.computeBoundingSphere(),this.add(new pi(e,new Ge({color:t,opacity:.2,transparent:!0,depthWrite:!1})))}function ko(t,e,i,n,s,l){F.call(this),t===void 0&&(t=new THREE.Vector3(0,0,1)),e===void 0&&(e=new THREE.Vector3(0,0,0)),i===void 0&&(i=1),n===void 0&&(n=16776960),s===void 0&&(s=.2*i),l===void 0&&(l=.2*s),fh===void 0&&(fh=new Ft,fh.addAttribute("position",new Et([0,0,0,0,1,0],3)),Sl=new Oo(0,.5,1,5,1),Sl.translate(0,-.5,0)),this.position.copy(e),this.line=new ji(fh,new Ni({color:n})),this.line.matrixAutoUpdate=!1,this.add(this.line),this.cone=new pi(Sl,new Ge({color:n})),this.cone.matrixAutoUpdate=!1,this.add(this.cone),this.setDirection(t),this.setLength(i,s,l)}function xr(t){t=t||1;var e=[0,0,0,t,0,0,0,0,0,0,t,0,0,0,0,0,0,t];t=new Ft,t.addAttribute("position",new Et(e,3)),t.addAttribute("color",new Et([1,0,0,1,.6,0,0,1,0,.6,1,0,0,0,1,0,.6,1],3)),e=new Ni({vertexColors:2}),gi.call(this,t,e)}function Iu(t){On.call(this,t),this.type="catmullrom",this.closed=!0}function Du(t){On.call(this,t),this.type="catmullrom"}function Xh(t){On.call(this,t),this.type="catmullrom"}Number.EPSILON===void 0&&(Number.EPSILON=Math.pow(2,-52)),Number.isInteger===void 0&&(Number.isInteger=function(t){return typeof t=="number"&&isFinite(t)&&Math.floor(t)===t}),Math.sign===void 0&&(Math.sign=function(t){return 0>t?-1:0<t?1:+t}),!("name"in Function.prototype)&&Object.defineProperty(Function.prototype,"name",{get:function(){return this.toString().match(/^\s*function\s*([^\(\s]*)/)[1]}}),Object.assign===void 0&&function(){Object.assign=function(t){if(t==null)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;i<arguments.length;i++){var n=arguments[i];if(n!=null)for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(e[s]=n[s])}return e}}(),Object.assign(a.prototype,{addEventListener:function(t,e){this._listeners===void 0&&(this._listeners={});var i=this._listeners;i[t]===void 0&&(i[t]=[]),i[t].indexOf(e)===-1&&i[t].push(e)},hasEventListener:function(t,e){if(this._listeners===void 0)return!1;var i=this._listeners;return i[t]!==void 0&&i[t].indexOf(e)!==-1},removeEventListener:function(t,e){this._listeners!==void 0&&(t=this._listeners[t],t!==void 0&&(e=t.indexOf(e),e!==-1&&t.splice(e,1)))},dispatchEvent:function(t){if(this._listeners!==void 0){var e=this._listeners[t.type];if(e!==void 0){t.target=this,e=e.slice(0);for(var i=0,n=e.length;i<n;i++)e[i].call(this,t)}}}});var di={DEG2RAD:Math.PI/180,RAD2DEG:180/Math.PI,generateUUID:function(){for(var t=[],e=0;256>e;e++)t[e]=(16>e?"0":"")+e.toString(16);return function(){var i=4294967295*Math.random()|0,n=4294967295*Math.random()|0,s=4294967295*Math.random()|0,l=4294967295*Math.random()|0;return(t[i&255]+t[i>>8&255]+t[i>>16&255]+t[i>>24&255]+"-"+t[n&255]+t[n>>8&255]+"-"+t[n>>16&15|64]+t[n>>24&255]+"-"+t[s&63|128]+t[s>>8&255]+"-"+t[s>>16&255]+t[s>>24&255]+t[l&255]+t[l>>8&255]+t[l>>16&255]+t[l>>24&255]).toUpperCase()}}(),clamp:function(t,e,i){return Math.max(e,Math.min(i,t))},euclideanModulo:function(t,e){return(t%e+e)%e},mapLinear:function(t,e,i,n,s){return n+(t-e)*(s-n)/(i-e)},lerp:function(t,e,i){return(1-i)*t+i*e},smoothstep:function(t,e,i){return t<=e?0:t>=i?1:(t=(t-e)/(i-e),t*t*(3-2*t))},smootherstep:function(t,e,i){return t<=e?0:t>=i?1:(t=(t-e)/(i-e),t*t*t*(t*(6*t-15)+10))},randInt:function(t,e){return t+Math.floor(Math.random()*(e-t+1))},randFloat:function(t,e){return t+Math.random()*(e-t)},randFloatSpread:function(t){return t*(.5-Math.random())},degToRad:function(t){return t*di.DEG2RAD},radToDeg:function(t){return t*di.RAD2DEG},isPowerOfTwo:function(t){return(t&t-1)===0&&t!==0},ceilPowerOfTwo:function(t){return Math.pow(2,Math.ceil(Math.log(t)/Math.LN2))},floorPowerOfTwo:function(t){return Math.pow(2,Math.floor(Math.log(t)/Math.LN2))}};Object.defineProperties(o.prototype,{width:{get:function(){return this.x},set:function(t){this.x=t}},height:{get:function(){return this.y},set:function(t){this.y=t}}}),Object.assign(o.prototype,{isVector2:!0,set:function(t,e){return this.x=t,this.y=e,this},setScalar:function(t){return this.y=this.x=t,this},setX:function(t){return this.x=t,this},setY:function(t){return this.y=t,this},setComponent:function(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;default:throw Error("index is out of range: "+t)}return this},getComponent:function(t){switch(t){case 0:return this.x;case 1:return this.y;default:throw Error("index is out of range: "+t)}},clone:function(){return new this.constructor(this.x,this.y)},copy:function(t){return this.x=t.x,this.y=t.y,this},add:function(t,e){return e!==void 0?this.addVectors(t,e):(this.x+=t.x,this.y+=t.y,this)},addScalar:function(t){return this.x+=t,this.y+=t,this},addVectors:function(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this},addScaledVector:function(t,e){return this.x+=t.x*e,this.y+=t.y*e,this},sub:function(t,e){return e!==void 0?this.subVectors(t,e):(this.x-=t.x,this.y-=t.y,this)},subScalar:function(t){return this.x-=t,this.y-=t,this},subVectors:function(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this},multiply:function(t){return this.x*=t.x,this.y*=t.y,this},multiplyScalar:function(t){return this.x*=t,this.y*=t,this},divide:function(t){return this.x/=t.x,this.y/=t.y,this},divideScalar:function(t){return this.multiplyScalar(1/t)},applyMatrix3:function(t){var e=this.x,i=this.y;return t=t.elements,this.x=t[0]*e+t[3]*i+t[6],this.y=t[1]*e+t[4]*i+t[7],this},min:function(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this},max:function(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this},clamp:function(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this},clampScalar:function(){var t=new o,e=new o;return function(i,n){return t.set(i,i),e.set(n,n),this.clamp(t,e)}}(),clampLength:function(t,e){var i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(t,Math.min(e,i)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},roundToZero:function(){return this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x),this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y),this},negate:function(){return this.x=-this.x,this.y=-this.y,this},dot:function(t){return this.x*t.x+this.y*t.y},cross:function(t){return this.x*t.y-this.y*t.x},lengthSq:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)},normalize:function(){return this.divideScalar(this.length()||1)},angle:function(){var t=Math.atan2(this.y,this.x);return 0>t&&(t+=2*Math.PI),t},distanceTo:function(t){return Math.sqrt(this.distanceToSquared(t))},distanceToSquared:function(t){var e=this.x-t.x;return t=this.y-t.y,e*e+t*t},manhattanDistanceTo:function(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)},setLength:function(t){return this.normalize().multiplyScalar(t)},lerp:function(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this},lerpVectors:function(t,e,i){return this.subVectors(e,t).multiplyScalar(i).add(t)},equals:function(t){return t.x===this.x&&t.y===this.y},fromArray:function(t,e){return e===void 0&&(e=0),this.x=t[e],this.y=t[e+1],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.x,t[e+1]=this.y,t},fromBufferAttribute:function(t,e,i){return this.x=t.getX(e),this.y=t.getY(e),this},rotateAround:function(t,e){var i=Math.cos(e);e=Math.sin(e);var n=this.x-t.x,s=this.y-t.y;return this.x=n*i-s*e+t.x,this.y=n*e+s*i+t.y,this}}),Object.assign(c.prototype,{isMatrix4:!0,set:function(t,e,i,n,s,l,d,p,_,T,A,L,B,H,q,J){var rt=this.elements;return rt[0]=t,rt[4]=e,rt[8]=i,rt[12]=n,rt[1]=s,rt[5]=l,rt[9]=d,rt[13]=p,rt[2]=_,rt[6]=T,rt[10]=A,rt[14]=L,rt[3]=B,rt[7]=H,rt[11]=q,rt[15]=J,this},identity:function(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this},clone:function(){return new c().fromArray(this.elements)},copy:function(t){var e=this.elements;return t=t.elements,e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],this},copyPosition:function(t){var e=this.elements;return t=t.elements,e[12]=t[12],e[13]=t[13],e[14]=t[14],this},extractBasis:function(t,e,i){return t.setFromMatrixColumn(this,0),e.setFromMatrixColumn(this,1),i.setFromMatrixColumn(this,2),this},makeBasis:function(t,e,i){return this.set(t.x,e.x,i.x,0,t.y,e.y,i.y,0,t.z,e.z,i.z,0,0,0,0,1),this},extractRotation:function(){var t=new u;return function(e){var i=this.elements,n=e.elements,s=1/t.setFromMatrixColumn(e,0).length(),l=1/t.setFromMatrixColumn(e,1).length();return e=1/t.setFromMatrixColumn(e,2).length(),i[0]=n[0]*s,i[1]=n[1]*s,i[2]=n[2]*s,i[3]=0,i[4]=n[4]*l,i[5]=n[5]*l,i[6]=n[6]*l,i[7]=0,i[8]=n[8]*e,i[9]=n[9]*e,i[10]=n[10]*e,i[11]=0,i[12]=0,i[13]=0,i[14]=0,i[15]=1,this}}(),makeRotationFromEuler:function(t){t&&t.isEuler;var e=this.elements,i=t.x,n=t.y,s=t.z,l=Math.cos(i);i=Math.sin(i);var d=Math.cos(n);n=Math.sin(n);var p=Math.cos(s);if(s=Math.sin(s),t.order==="XYZ"){t=l*p;var _=l*s,T=i*p,A=i*s;e[0]=d*p,e[4]=-d*s,e[8]=n,e[1]=_+T*n,e[5]=t-A*n,e[9]=-i*d,e[2]=A-t*n,e[6]=T+_*n,e[10]=l*d}else t.order==="YXZ"?(t=d*p,_=d*s,T=n*p,A=n*s,e[0]=t+A*i,e[4]=T*i-_,e[8]=l*n,e[1]=l*s,e[5]=l*p,e[9]=-i,e[2]=_*i-T,e[6]=A+t*i,e[10]=l*d):t.order==="ZXY"?(t=d*p,_=d*s,T=n*p,A=n*s,e[0]=t-A*i,e[4]=-l*s,e[8]=T+_*i,e[1]=_+T*i,e[5]=l*p,e[9]=A-t*i,e[2]=-l*n,e[6]=i,e[10]=l*d):t.order==="ZYX"?(t=l*p,_=l*s,T=i*p,A=i*s,e[0]=d*p,e[4]=T*n-_,e[8]=t*n+A,e[1]=d*s,e[5]=A*n+t,e[9]=_*n-T,e[2]=-n,e[6]=i*d,e[10]=l*d):t.order==="YZX"?(t=l*d,_=l*n,T=i*d,A=i*n,e[0]=d*p,e[4]=A-t*s,e[8]=T*s+_,e[1]=s,e[5]=l*p,e[9]=-i*p,e[2]=-n*p,e[6]=_*s+T,e[10]=t-A*s):t.order==="XZY"&&(t=l*d,_=l*n,T=i*d,A=i*n,e[0]=d*p,e[4]=-s,e[8]=n*p,e[1]=t*s+A,e[5]=l*p,e[9]=_*s-T,e[2]=T*s-_,e[6]=i*p,e[10]=A*s+t);return e[3]=0,e[7]=0,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,this},makeRotationFromQuaternion:function(){var t=new u(0,0,0),e=new u(1,1,1);return function(i){return this.compose(t,i,e)}}(),lookAt:function(){var t=new u,e=new u,i=new u;return function(n,s,l){var d=this.elements;return i.subVectors(n,s),i.lengthSq()===0&&(i.z=1),i.normalize(),t.crossVectors(l,i),t.lengthSq()===0&&(Math.abs(l.z)===1?i.x+=1e-4:i.z+=1e-4,i.normalize(),t.crossVectors(l,i)),t.normalize(),e.crossVectors(i,t),d[0]=t.x,d[4]=e.x,d[8]=i.x,d[1]=t.y,d[5]=e.y,d[9]=i.y,d[2]=t.z,d[6]=e.z,d[10]=i.z,this}}(),multiply:function(t,e){return e!==void 0?this.multiplyMatrices(t,e):this.multiplyMatrices(this,t)},premultiply:function(t){return this.multiplyMatrices(t,this)},multiplyMatrices:function(t,e){var i=t.elements,n=e.elements;e=this.elements,t=i[0];var s=i[4],l=i[8],d=i[12],p=i[1],_=i[5],T=i[9],A=i[13],L=i[2],B=i[6],H=i[10],q=i[14],J=i[3],rt=i[7],xt=i[11];i=i[15];var gt=n[0],Ct=n[4],wt=n[8],Vt=n[12],$=n[1],ot=n[5],kt=n[9],ee=n[13],$t=n[2],Yt=n[6],Te=n[10],ge=n[14],De=n[3],be=n[7],ae=n[11];return n=n[15],e[0]=t*gt+s*$+l*$t+d*De,e[4]=t*Ct+s*ot+l*Yt+d*be,e[8]=t*wt+s*kt+l*Te+d*ae,e[12]=t*Vt+s*ee+l*ge+d*n,e[1]=p*gt+_*$+T*$t+A*De,e[5]=p*Ct+_*ot+T*Yt+A*be,e[9]=p*wt+_*kt+T*Te+A*ae,e[13]=p*Vt+_*ee+T*ge+A*n,e[2]=L*gt+B*$+H*$t+q*De,e[6]=L*Ct+B*ot+H*Yt+q*be,e[10]=L*wt+B*kt+H*Te+q*ae,e[14]=L*Vt+B*ee+H*ge+q*n,e[3]=J*gt+rt*$+xt*$t+i*De,e[7]=J*Ct+rt*ot+xt*Yt+i*be,e[11]=J*wt+rt*kt+xt*Te+i*ae,e[15]=J*Vt+rt*ee+xt*ge+i*n,this},multiplyScalar:function(t){var e=this.elements;return e[0]*=t,e[4]*=t,e[8]*=t,e[12]*=t,e[1]*=t,e[5]*=t,e[9]*=t,e[13]*=t,e[2]*=t,e[6]*=t,e[10]*=t,e[14]*=t,e[3]*=t,e[7]*=t,e[11]*=t,e[15]*=t,this},applyToBufferAttribute:function(){var t=new u;return function(e){for(var i=0,n=e.count;i<n;i++)t.x=e.getX(i),t.y=e.getY(i),t.z=e.getZ(i),t.applyMatrix4(this),e.setXYZ(i,t.x,t.y,t.z);return e}}(),determinant:function(){var t=this.elements,e=t[0],i=t[4],n=t[8],s=t[12],l=t[1],d=t[5],p=t[9],_=t[13],T=t[2],A=t[6],L=t[10],B=t[14];return t[3]*(+s*p*A-n*_*A-s*d*L+i*_*L+n*d*B-i*p*B)+t[7]*(+e*p*B-e*_*L+s*l*L-n*l*B+n*_*T-s*p*T)+t[11]*(+e*_*A-e*d*B-s*l*A+i*l*B+s*d*T-i*_*T)+t[15]*(-n*d*T-e*p*A+e*d*L+n*l*A-i*l*L+i*p*T)},transpose:function(){var t=this.elements,e=t[1];return t[1]=t[4],t[4]=e,e=t[2],t[2]=t[8],t[8]=e,e=t[6],t[6]=t[9],t[9]=e,e=t[3],t[3]=t[12],t[12]=e,e=t[7],t[7]=t[13],t[13]=e,e=t[11],t[11]=t[14],t[14]=e,this},setPosition:function(t){var e=this.elements;return e[12]=t.x,e[13]=t.y,e[14]=t.z,this},getInverse:function(t,e){var i=this.elements,n=t.elements;t=n[0];var s=n[1],l=n[2],d=n[3],p=n[4],_=n[5],T=n[6],A=n[7],L=n[8],B=n[9],H=n[10],q=n[11],J=n[12],rt=n[13],xt=n[14];n=n[15];var gt=B*xt*A-rt*H*A+rt*T*q-_*xt*q-B*T*n+_*H*n,Ct=J*H*A-L*xt*A-J*T*q+p*xt*q+L*T*n-p*H*n,wt=L*rt*A-J*B*A+J*_*q-p*rt*q-L*_*n+p*B*n,Vt=J*B*T-L*rt*T-J*_*H+p*rt*H+L*_*xt-p*B*xt,$=t*gt+s*Ct+l*wt+d*Vt;if($===0){if(e===!0)throw Error("THREE.Matrix4: .getInverse() can't invert matrix, determinant is 0");return this.identity()}return e=1/$,i[0]=gt*e,i[1]=(rt*H*d-B*xt*d-rt*l*q+s*xt*q+B*l*n-s*H*n)*e,i[2]=(_*xt*d-rt*T*d+rt*l*A-s*xt*A-_*l*n+s*T*n)*e,i[3]=(B*T*d-_*H*d-B*l*A+s*H*A+_*l*q-s*T*q)*e,i[4]=Ct*e,i[5]=(L*xt*d-J*H*d+J*l*q-t*xt*q-L*l*n+t*H*n)*e,i[6]=(J*T*d-p*xt*d-J*l*A+t*xt*A+p*l*n-t*T*n)*e,i[7]=(p*H*d-L*T*d+L*l*A-t*H*A-p*l*q+t*T*q)*e,i[8]=wt*e,i[9]=(J*B*d-L*rt*d-J*s*q+t*rt*q+L*s*n-t*B*n)*e,i[10]=(p*rt*d-J*_*d+J*s*A-t*rt*A-p*s*n+t*_*n)*e,i[11]=(L*_*d-p*B*d-L*s*A+t*B*A+p*s*q-t*_*q)*e,i[12]=Vt*e,i[13]=(L*rt*l-J*B*l+J*s*H-t*rt*H-L*s*xt+t*B*xt)*e,i[14]=(J*_*l-p*rt*l-J*s*T+t*rt*T+p*s*xt-t*_*xt)*e,i[15]=(p*B*l-L*_*l+L*s*T-t*B*T-p*s*H+t*_*H)*e,this},scale:function(t){var e=this.elements,i=t.x,n=t.y;return t=t.z,e[0]*=i,e[4]*=n,e[8]*=t,e[1]*=i,e[5]*=n,e[9]*=t,e[2]*=i,e[6]*=n,e[10]*=t,e[3]*=i,e[7]*=n,e[11]*=t,this},getMaxScaleOnAxis:function(){var t=this.elements;return Math.sqrt(Math.max(t[0]*t[0]+t[1]*t[1]+t[2]*t[2],t[4]*t[4]+t[5]*t[5]+t[6]*t[6],t[8]*t[8]+t[9]*t[9]+t[10]*t[10]))},makeTranslation:function(t,e,i){return this.set(1,0,0,t,0,1,0,e,0,0,1,i,0,0,0,1),this},makeRotationX:function(t){var e=Math.cos(t);return t=Math.sin(t),this.set(1,0,0,0,0,e,-t,0,0,t,e,0,0,0,0,1),this},makeRotationY:function(t){var e=Math.cos(t);return t=Math.sin(t),this.set(e,0,t,0,0,1,0,0,-t,0,e,0,0,0,0,1),this},makeRotationZ:function(t){var e=Math.cos(t);return t=Math.sin(t),this.set(e,-t,0,0,t,e,0,0,0,0,1,0,0,0,0,1),this},makeRotationAxis:function(t,e){var i=Math.cos(e);e=Math.sin(e);var n=1-i,s=t.x,l=t.y;t=t.z;var d=n*s,p=n*l;return this.set(d*s+i,d*l-e*t,d*t+e*l,0,d*l+e*t,p*l+i,p*t-e*s,0,d*t-e*l,p*t+e*s,n*t*t+i,0,0,0,0,1),this},makeScale:function(t,e,i){return this.set(t,0,0,0,0,e,0,0,0,0,i,0,0,0,0,1),this},makeShear:function(t,e,i){return this.set(1,e,i,0,t,1,i,0,t,e,1,0,0,0,0,1),this},compose:function(t,e,i){var n=this.elements,s=e._x,l=e._y,d=e._z,p=e._w,_=s+s,T=l+l,A=d+d;e=s*_;var L=s*T;s*=A;var B=l*T;l*=A,d*=A,_*=p,T*=p,p*=A,A=i.x;var H=i.y;return i=i.z,n[0]=(1-(B+d))*A,n[1]=(L+p)*A,n[2]=(s-T)*A,n[3]=0,n[4]=(L-p)*H,n[5]=(1-(e+d))*H,n[6]=(l+_)*H,n[7]=0,n[8]=(s+T)*i,n[9]=(l-_)*i,n[10]=(1-(e+B))*i,n[11]=0,n[12]=t.x,n[13]=t.y,n[14]=t.z,n[15]=1,this},decompose:function(){var t=new u,e=new c;return function(i,n,s){var l=this.elements,d=t.set(l[0],l[1],l[2]).length(),p=t.set(l[4],l[5],l[6]).length(),_=t.set(l[8],l[9],l[10]).length();0>this.determinant()&&(d=-d),i.x=l[12],i.y=l[13],i.z=l[14],e.copy(this),i=1/d,l=1/p;var T=1/_;return e.elements[0]*=i,e.elements[1]*=i,e.elements[2]*=i,e.elements[4]*=l,e.elements[5]*=l,e.elements[6]*=l,e.elements[8]*=T,e.elements[9]*=T,e.elements[10]*=T,n.setFromRotationMatrix(e),s.x=d,s.y=p,s.z=_,this}}(),makePerspective:function(t,e,i,n,s,l){var d=this.elements;return d[0]=2*s/(e-t),d[4]=0,d[8]=(e+t)/(e-t),d[12]=0,d[1]=0,d[5]=2*s/(i-n),d[9]=(i+n)/(i-n),d[13]=0,d[2]=0,d[6]=0,d[10]=-(l+s)/(l-s),d[14]=-2*l*s/(l-s),d[3]=0,d[7]=0,d[11]=-1,d[15]=0,this},makeOrthographic:function(t,e,i,n,s,l){var d=this.elements,p=1/(e-t),_=1/(i-n),T=1/(l-s);return d[0]=2*p,d[4]=0,d[8]=0,d[12]=-((e+t)*p),d[1]=0,d[5]=2*_,d[9]=0,d[13]=-((i+n)*_),d[2]=0,d[6]=0,d[10]=-2*T,d[14]=-((l+s)*T),d[3]=0,d[7]=0,d[11]=0,d[15]=1,this},equals:function(t){var e=this.elements;t=t.elements;for(var i=0;16>i;i++)if(e[i]!==t[i])return!1;return!0},fromArray:function(t,e){e===void 0&&(e=0);for(var i=0;16>i;i++)this.elements[i]=t[i+e];return this},toArray:function(t,e){t===void 0&&(t=[]),e===void 0&&(e=0);var i=this.elements;return t[e]=i[0],t[e+1]=i[1],t[e+2]=i[2],t[e+3]=i[3],t[e+4]=i[4],t[e+5]=i[5],t[e+6]=i[6],t[e+7]=i[7],t[e+8]=i[8],t[e+9]=i[9],t[e+10]=i[10],t[e+11]=i[11],t[e+12]=i[12],t[e+13]=i[13],t[e+14]=i[14],t[e+15]=i[15],t}}),Object.assign(f,{slerp:function(t,e,i,n){return i.copy(t).slerp(e,n)},slerpFlat:function(t,e,i,n,s,l,d){var p=i[n+0],_=i[n+1],T=i[n+2];i=i[n+3],n=s[l+0];var A=s[l+1],L=s[l+2];if(s=s[l+3],i!==s||p!==n||_!==A||T!==L){l=1-d;var B=p*n+_*A+T*L+i*s,H=0<=B?1:-1,q=1-B*B;q>Number.EPSILON&&(q=Math.sqrt(q),B=Math.atan2(q,B*H),l=Math.sin(l*B)/q,d=Math.sin(d*B)/q),H*=d,p=p*l+n*H,_=_*l+A*H,T=T*l+L*H,i=i*l+s*H,l===1-d&&(d=1/Math.sqrt(p*p+_*_+T*T+i*i),p*=d,_*=d,T*=d,i*=d)}t[e]=p,t[e+1]=_,t[e+2]=T,t[e+3]=i}}),Object.defineProperties(f.prototype,{x:{get:function(){return this._x},set:function(t){this._x=t,this.onChangeCallback()}},y:{get:function(){return this._y},set:function(t){this._y=t,this.onChangeCallback()}},z:{get:function(){return this._z},set:function(t){this._z=t,this.onChangeCallback()}},w:{get:function(){return this._w},set:function(t){this._w=t,this.onChangeCallback()}}}),Object.assign(f.prototype,{isQuaternion:!0,set:function(t,e,i,n){return this._x=t,this._y=e,this._z=i,this._w=n,this.onChangeCallback(),this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._w)},copy:function(t){return this._x=t.x,this._y=t.y,this._z=t.z,this._w=t.w,this.onChangeCallback(),this},setFromEuler:function(t,e){if(!t||!t.isEuler)throw Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");var i=t._x,n=t._y,s=t._z;t=t.order;var l=Math.cos,d=Math.sin,p=l(i/2),_=l(n/2);return l=l(s/2),i=d(i/2),n=d(n/2),s=d(s/2),t==="XYZ"?(this._x=i*_*l+p*n*s,this._y=p*n*l-i*_*s,this._z=p*_*s+i*n*l,this._w=p*_*l-i*n*s):t==="YXZ"?(this._x=i*_*l+p*n*s,this._y=p*n*l-i*_*s,this._z=p*_*s-i*n*l,this._w=p*_*l+i*n*s):t==="ZXY"?(this._x=i*_*l-p*n*s,this._y=p*n*l+i*_*s,this._z=p*_*s+i*n*l,this._w=p*_*l-i*n*s):t==="ZYX"?(this._x=i*_*l-p*n*s,this._y=p*n*l+i*_*s,this._z=p*_*s-i*n*l,this._w=p*_*l+i*n*s):t==="YZX"?(this._x=i*_*l+p*n*s,this._y=p*n*l+i*_*s,this._z=p*_*s-i*n*l,this._w=p*_*l-i*n*s):t==="XZY"&&(this._x=i*_*l-p*n*s,this._y=p*n*l-i*_*s,this._z=p*_*s+i*n*l,this._w=p*_*l+i*n*s),e!==!1&&this.onChangeCallback(),this},setFromAxisAngle:function(t,e){e/=2;var i=Math.sin(e);return this._x=t.x*i,this._y=t.y*i,this._z=t.z*i,this._w=Math.cos(e),this.onChangeCallback(),this},setFromRotationMatrix:function(t){var e=t.elements,i=e[0];t=e[4];var n=e[8],s=e[1],l=e[5],d=e[9],p=e[2],_=e[6];e=e[10];var T=i+l+e;return 0<T?(i=.5/Math.sqrt(T+1),this._w=.25/i,this._x=(_-d)*i,this._y=(n-p)*i,this._z=(s-t)*i):i>l&&i>e?(i=2*Math.sqrt(1+i-l-e),this._w=(_-d)/i,this._x=.25*i,this._y=(t+s)/i,this._z=(n+p)/i):l>e?(i=2*Math.sqrt(1+l-i-e),this._w=(n-p)/i,this._x=(t+s)/i,this._y=.25*i,this._z=(d+_)/i):(i=2*Math.sqrt(1+e-i-l),this._w=(s-t)/i,this._x=(n+p)/i,this._y=(d+_)/i,this._z=.25*i),this.onChangeCallback(),this},setFromUnitVectors:function(){var t=new u,e;return function(i,n){return t===void 0&&(t=new u),e=i.dot(n)+1,1e-6>e?(e=0,Math.abs(i.x)>Math.abs(i.z)?t.set(-i.y,i.x,0):t.set(0,-i.z,i.y)):t.crossVectors(i,n),this._x=t.x,this._y=t.y,this._z=t.z,this._w=e,this.normalize()}}(),angleTo:function(t){return 2*Math.acos(Math.abs(di.clamp(this.dot(t),-1,1)))},rotateTowards:function(t,e){var i=this.angleTo(t);return i===0?this:(this.slerp(t,Math.min(1,e/i)),this)},inverse:function(){return this.conjugate()},conjugate:function(){return this._x*=-1,this._y*=-1,this._z*=-1,this.onChangeCallback(),this},dot:function(t){return this._x*t._x+this._y*t._y+this._z*t._z+this._w*t._w},lengthSq:function(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w},length:function(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)},normalize:function(){var t=this.length();return t===0?(this._z=this._y=this._x=0,this._w=1):(t=1/t,this._x*=t,this._y*=t,this._z*=t,this._w*=t),this.onChangeCallback(),this},multiply:function(t,e){return e!==void 0?this.multiplyQuaternions(t,e):this.multiplyQuaternions(this,t)},premultiply:function(t){return this.multiplyQuaternions(t,this)},multiplyQuaternions:function(t,e){var i=t._x,n=t._y,s=t._z;t=t._w;var l=e._x,d=e._y,p=e._z;return e=e._w,this._x=i*e+t*l+n*p-s*d,this._y=n*e+t*d+s*l-i*p,this._z=s*e+t*p+i*d-n*l,this._w=t*e-i*l-n*d-s*p,this.onChangeCallback(),this},slerp:function(t,e){if(e===0)return this;if(e===1)return this.copy(t);var i=this._x,n=this._y,s=this._z,l=this._w,d=l*t._w+i*t._x+n*t._y+s*t._z;if(0>d?(this._w=-t._w,this._x=-t._x,this._y=-t._y,this._z=-t._z,d=-d):this.copy(t),1<=d)return this._w=l,this._x=i,this._y=n,this._z=s,this;if(t=1-d*d,t<=Number.EPSILON)return d=1-e,this._w=d*l+e*this._w,this._x=d*i+e*this._x,this._y=d*n+e*this._y,this._z=d*s+e*this._z,this.normalize();t=Math.sqrt(t);var p=Math.atan2(t,d);return d=Math.sin((1-e)*p)/t,e=Math.sin(e*p)/t,this._w=l*d+this._w*e,this._x=i*d+this._x*e,this._y=n*d+this._y*e,this._z=s*d+this._z*e,this.onChangeCallback(),this},equals:function(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._w===this._w},fromArray:function(t,e){return e===void 0&&(e=0),this._x=t[e],this._y=t[e+1],this._z=t[e+2],this._w=t[e+3],this.onChangeCallback(),this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this._x,t[e+1]=this._y,t[e+2]=this._z,t[e+3]=this._w,t},onChange:function(t){return this.onChangeCallback=t,this},onChangeCallback:function(){}}),Object.assign(u.prototype,{isVector3:!0,set:function(t,e,i){return this.x=t,this.y=e,this.z=i,this},setScalar:function(t){return this.z=this.y=this.x=t,this},setX:function(t){return this.x=t,this},setY:function(t){return this.y=t,this},setZ:function(t){return this.z=t,this},setComponent:function(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;case 2:this.z=e;break;default:throw Error("index is out of range: "+t)}return this},getComponent:function(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw Error("index is out of range: "+t)}},clone:function(){return new this.constructor(this.x,this.y,this.z)},copy:function(t){return this.x=t.x,this.y=t.y,this.z=t.z,this},add:function(t,e){return e!==void 0?this.addVectors(t,e):(this.x+=t.x,this.y+=t.y,this.z+=t.z,this)},addScalar:function(t){return this.x+=t,this.y+=t,this.z+=t,this},addVectors:function(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this.z=t.z+e.z,this},addScaledVector:function(t,e){return this.x+=t.x*e,this.y+=t.y*e,this.z+=t.z*e,this},sub:function(t,e){return e!==void 0?this.subVectors(t,e):(this.x-=t.x,this.y-=t.y,this.z-=t.z,this)},subScalar:function(t){return this.x-=t,this.y-=t,this.z-=t,this},subVectors:function(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this.z=t.z-e.z,this},multiply:function(t,e){return e!==void 0?this.multiplyVectors(t,e):(this.x*=t.x,this.y*=t.y,this.z*=t.z,this)},multiplyScalar:function(t){return this.x*=t,this.y*=t,this.z*=t,this},multiplyVectors:function(t,e){return this.x=t.x*e.x,this.y=t.y*e.y,this.z=t.z*e.z,this},applyEuler:function(){var t=new f;return function(e){return e&&e.isEuler,this.applyQuaternion(t.setFromEuler(e))}}(),applyAxisAngle:function(){var t=new f;return function(e,i){return this.applyQuaternion(t.setFromAxisAngle(e,i))}}(),applyMatrix3:function(t){var e=this.x,i=this.y,n=this.z;return t=t.elements,this.x=t[0]*e+t[3]*i+t[6]*n,this.y=t[1]*e+t[4]*i+t[7]*n,this.z=t[2]*e+t[5]*i+t[8]*n,this},applyMatrix4:function(t){var e=this.x,i=this.y,n=this.z;t=t.elements;var s=1/(t[3]*e+t[7]*i+t[11]*n+t[15]);return this.x=(t[0]*e+t[4]*i+t[8]*n+t[12])*s,this.y=(t[1]*e+t[5]*i+t[9]*n+t[13])*s,this.z=(t[2]*e+t[6]*i+t[10]*n+t[14])*s,this},applyQuaternion:function(t){var e=this.x,i=this.y,n=this.z,s=t.x,l=t.y,d=t.z;t=t.w;var p=t*e+l*n-d*i,_=t*i+d*e-s*n,T=t*n+s*i-l*e;return e=-s*e-l*i-d*n,this.x=p*t+e*-s+_*-d-T*-l,this.y=_*t+e*-l+T*-s-p*-d,this.z=T*t+e*-d+p*-l-_*-s,this},project:function(t){return this.applyMatrix4(t.matrixWorldInverse).applyMatrix4(t.projectionMatrix)},unproject:function(){var t=new c;return function(e){return this.applyMatrix4(t.getInverse(e.projectionMatrix)).applyMatrix4(e.matrixWorld)}}(),transformDirection:function(t){var e=this.x,i=this.y,n=this.z;return t=t.elements,this.x=t[0]*e+t[4]*i+t[8]*n,this.y=t[1]*e+t[5]*i+t[9]*n,this.z=t[2]*e+t[6]*i+t[10]*n,this.normalize()},divide:function(t){return this.x/=t.x,this.y/=t.y,this.z/=t.z,this},divideScalar:function(t){return this.multiplyScalar(1/t)},min:function(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.z=Math.min(this.z,t.z),this},max:function(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this.z=Math.max(this.z,t.z),this},clamp:function(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this.z=Math.max(t.z,Math.min(e.z,this.z)),this},clampScalar:function(){var t=new u,e=new u;return function(i,n){return t.set(i,i,i),e.set(n,n,n),this.clamp(t,e)}}(),clampLength:function(t,e){var i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(t,Math.min(e,i)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this},roundToZero:function(){return this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x),this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y),this.z=0>this.z?Math.ceil(this.z):Math.floor(this.z),this},negate:function(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this},dot:function(t){return this.x*t.x+this.y*t.y+this.z*t.z},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)},normalize:function(){return this.divideScalar(this.length()||1)},setLength:function(t){return this.normalize().multiplyScalar(t)},lerp:function(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this.z+=(t.z-this.z)*e,this},lerpVectors:function(t,e,i){return this.subVectors(e,t).multiplyScalar(i).add(t)},cross:function(t,e){return e!==void 0?this.crossVectors(t,e):this.crossVectors(this,t)},crossVectors:function(t,e){var i=t.x,n=t.y;t=t.z;var s=e.x,l=e.y;return e=e.z,this.x=n*e-t*l,this.y=t*s-i*e,this.z=i*l-n*s,this},projectOnVector:function(t){var e=t.dot(this)/t.lengthSq();return this.copy(t).multiplyScalar(e)},projectOnPlane:function(){var t=new u;return function(e){return t.copy(this).projectOnVector(e),this.sub(t)}}(),reflect:function(){var t=new u;return function(e){return this.sub(t.copy(e).multiplyScalar(2*this.dot(e)))}}(),angleTo:function(t){return t=this.dot(t)/Math.sqrt(this.lengthSq()*t.lengthSq()),Math.acos(di.clamp(t,-1,1))},distanceTo:function(t){return Math.sqrt(this.distanceToSquared(t))},distanceToSquared:function(t){var e=this.x-t.x,i=this.y-t.y;return t=this.z-t.z,e*e+i*i+t*t},manhattanDistanceTo:function(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)+Math.abs(this.z-t.z)},setFromSpherical:function(t){return this.setFromSphericalCoords(t.radius,t.phi,t.theta)},setFromSphericalCoords:function(t,e,i){var n=Math.sin(e)*t;return this.x=n*Math.sin(i),this.y=Math.cos(e)*t,this.z=n*Math.cos(i),this},setFromCylindrical:function(t){return this.setFromCylindricalCoords(t.radius,t.theta,t.y)},setFromCylindricalCoords:function(t,e,i){return this.x=t*Math.sin(e),this.y=i,this.z=t*Math.cos(e),this},setFromMatrixPosition:function(t){return t=t.elements,this.x=t[12],this.y=t[13],this.z=t[14],this},setFromMatrixScale:function(t){var e=this.setFromMatrixColumn(t,0).length(),i=this.setFromMatrixColumn(t,1).length();return t=this.setFromMatrixColumn(t,2).length(),this.x=e,this.y=i,this.z=t,this},setFromMatrixColumn:function(t,e){return this.fromArray(t.elements,4*e)},equals:function(t){return t.x===this.x&&t.y===this.y&&t.z===this.z},fromArray:function(t,e){return e===void 0&&(e=0),this.x=t[e],this.y=t[e+1],this.z=t[e+2],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.x,t[e+1]=this.y,t[e+2]=this.z,t},fromBufferAttribute:function(t,e,i){return this.x=t.getX(e),this.y=t.getY(e),this.z=t.getZ(e),this}}),Object.assign(m.prototype,{isMatrix3:!0,set:function(t,e,i,n,s,l,d,p,_){var T=this.elements;return T[0]=t,T[1]=n,T[2]=d,T[3]=e,T[4]=s,T[5]=p,T[6]=i,T[7]=l,T[8]=_,this},identity:function(){return this.set(1,0,0,0,1,0,0,0,1),this},clone:function(){return new this.constructor().fromArray(this.elements)},copy:function(t){var e=this.elements;return t=t.elements,e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],this},setFromMatrix4:function(t){return t=t.elements,this.set(t[0],t[4],t[8],t[1],t[5],t[9],t[2],t[6],t[10]),this},applyToBufferAttribute:function(){var t=new u;return function(e){for(var i=0,n=e.count;i<n;i++)t.x=e.getX(i),t.y=e.getY(i),t.z=e.getZ(i),t.applyMatrix3(this),e.setXYZ(i,t.x,t.y,t.z);return e}}(),multiply:function(t){return this.multiplyMatrices(this,t)},premultiply:function(t){return this.multiplyMatrices(t,this)},multiplyMatrices:function(t,e){var i=t.elements,n=e.elements;e=this.elements,t=i[0];var s=i[3],l=i[6],d=i[1],p=i[4],_=i[7],T=i[2],A=i[5];i=i[8];var L=n[0],B=n[3],H=n[6],q=n[1],J=n[4],rt=n[7],xt=n[2],gt=n[5];return n=n[8],e[0]=t*L+s*q+l*xt,e[3]=t*B+s*J+l*gt,e[6]=t*H+s*rt+l*n,e[1]=d*L+p*q+_*xt,e[4]=d*B+p*J+_*gt,e[7]=d*H+p*rt+_*n,e[2]=T*L+A*q+i*xt,e[5]=T*B+A*J+i*gt,e[8]=T*H+A*rt+i*n,this},multiplyScalar:function(t){var e=this.elements;return e[0]*=t,e[3]*=t,e[6]*=t,e[1]*=t,e[4]*=t,e[7]*=t,e[2]*=t,e[5]*=t,e[8]*=t,this},determinant:function(){var t=this.elements,e=t[0],i=t[1],n=t[2],s=t[3],l=t[4],d=t[5],p=t[6],_=t[7];return t=t[8],e*l*t-e*d*_-i*s*t+i*d*p+n*s*_-n*l*p},getInverse:function(t,e){t&&t.isMatrix4;var i=t.elements;t=this.elements;var n=i[0],s=i[1],l=i[2],d=i[3],p=i[4],_=i[5],T=i[6],A=i[7];i=i[8];var L=i*p-_*A,B=_*T-i*d,H=A*d-p*T,q=n*L+s*B+l*H;if(q===0){if(e===!0)throw Error("THREE.Matrix3: .getInverse() can't invert matrix, determinant is 0");return this.identity()}return e=1/q,t[0]=L*e,t[1]=(l*A-i*s)*e,t[2]=(_*s-l*p)*e,t[3]=B*e,t[4]=(i*n-l*T)*e,t[5]=(l*d-_*n)*e,t[6]=H*e,t[7]=(s*T-A*n)*e,t[8]=(p*n-s*d)*e,this},transpose:function(){var t=this.elements,e=t[1];return t[1]=t[3],t[3]=e,e=t[2],t[2]=t[6],t[6]=e,e=t[5],t[5]=t[7],t[7]=e,this},getNormalMatrix:function(t){return this.setFromMatrix4(t).getInverse(this).transpose()},transposeIntoArray:function(t){var e=this.elements;return t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8],this},setUvTransform:function(t,e,i,n,s,l,d){var p=Math.cos(s);s=Math.sin(s),this.set(i*p,i*s,-i*(p*l+s*d)+l+t,-n*s,n*p,-n*(-s*l+p*d)+d+e,0,0,1)},scale:function(t,e){var i=this.elements;return i[0]*=t,i[3]*=t,i[6]*=t,i[1]*=e,i[4]*=e,i[7]*=e,this},rotate:function(t){var e=Math.cos(t);t=Math.sin(t);var i=this.elements,n=i[0],s=i[3],l=i[6],d=i[1],p=i[4],_=i[7];return i[0]=e*n+t*d,i[3]=e*s+t*p,i[6]=e*l+t*_,i[1]=-t*n+e*d,i[4]=-t*s+e*p,i[7]=-t*l+e*_,this},translate:function(t,e){var i=this.elements;return i[0]+=t*i[2],i[3]+=t*i[5],i[6]+=t*i[8],i[1]+=e*i[2],i[4]+=e*i[5],i[7]+=e*i[8],this},equals:function(t){var e=this.elements;t=t.elements;for(var i=0;9>i;i++)if(e[i]!==t[i])return!1;return!0},fromArray:function(t,e){e===void 0&&(e=0);for(var i=0;9>i;i++)this.elements[i]=t[i+e];return this},toArray:function(t,e){t===void 0&&(t=[]),e===void 0&&(e=0);var i=this.elements;return t[e]=i[0],t[e+1]=i[1],t[e+2]=i[2],t[e+3]=i[3],t[e+4]=i[4],t[e+5]=i[5],t[e+6]=i[6],t[e+7]=i[7],t[e+8]=i[8],t}});var as={getDataURL:function(t){if(typeof HTMLCanvasElement>"u")return t.src;if(t instanceof HTMLCanvasElement)var e=t;else{e=document.createElementNS("http://www.w3.org/1999/xhtml","canvas"),e.width=t.width,e.height=t.height;var i=e.getContext("2d");t instanceof ImageData?i.putImageData(t,0,0):i.drawImage(t,0,0,t.width,t.height)}return 2048<e.width||2048<e.height?e.toDataURL("image/jpeg",.6):e.toDataURL("image/png")}},Us=0;g.DEFAULT_IMAGE=void 0,g.DEFAULT_MAPPING=300,g.prototype=Object.assign(Object.create(a.prototype),{constructor:g,isTexture:!0,updateMatrix:function(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.name=t.name,this.image=t.image,this.mipmaps=t.mipmaps.slice(0),this.mapping=t.mapping,this.wrapS=t.wrapS,this.wrapT=t.wrapT,this.magFilter=t.magFilter,this.minFilter=t.minFilter,this.anisotropy=t.anisotropy,this.format=t.format,this.type=t.type,this.offset.copy(t.offset),this.repeat.copy(t.repeat),this.center.copy(t.center),this.rotation=t.rotation,this.matrixAutoUpdate=t.matrixAutoUpdate,this.matrix.copy(t.matrix),this.generateMipmaps=t.generateMipmaps,this.premultiplyAlpha=t.premultiplyAlpha,this.flipY=t.flipY,this.unpackAlignment=t.unpackAlignment,this.encoding=t.encoding,this},toJSON:function(t){var e=t===void 0||typeof t=="string";if(!e&&t.textures[this.uuid]!==void 0)return t.textures[this.uuid];var i={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY};if(this.image!==void 0){var n=this.image;if(n.uuid===void 0&&(n.uuid=di.generateUUID()),!e&&t.images[n.uuid]===void 0){if(Array.isArray(n))for(var s=[],l=0,d=n.length;l<d;l++)s.push(as.getDataURL(n[l]));else s=as.getDataURL(n);t.images[n.uuid]={uuid:n.uuid,url:s}}i.image=n.uuid}return e||(t.textures[this.uuid]=i),i},dispose:function(){this.dispatchEvent({type:"dispose"})},transformUv:function(t){if(this.mapping!==300)return t;if(t.applyMatrix3(this.matrix),0>t.x||1<t.x)switch(this.wrapS){case 1e3:t.x-=Math.floor(t.x);break;case 1001:t.x=0>t.x?0:1;break;case 1002:t.x=Math.abs(Math.floor(t.x)%2)===1?Math.ceil(t.x)-t.x:t.x-Math.floor(t.x)}if(0>t.y||1<t.y)switch(this.wrapT){case 1e3:t.y-=Math.floor(t.y);break;case 1001:t.y=0>t.y?0:1;break;case 1002:t.y=Math.abs(Math.floor(t.y)%2)===1?Math.ceil(t.y)-t.y:t.y-Math.floor(t.y)}return this.flipY&&(t.y=1-t.y),t}}),Object.defineProperty(g.prototype,"needsUpdate",{set:function(t){t===!0&&this.version++}}),Object.assign(v.prototype,{isVector4:!0,set:function(t,e,i,n){return this.x=t,this.y=e,this.z=i,this.w=n,this},setScalar:function(t){return this.w=this.z=this.y=this.x=t,this},setX:function(t){return this.x=t,this},setY:function(t){return this.y=t,this},setZ:function(t){return this.z=t,this},setW:function(t){return this.w=t,this},setComponent:function(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;case 2:this.z=e;break;case 3:this.w=e;break;default:throw Error("index is out of range: "+t)}return this},getComponent:function(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw Error("index is out of range: "+t)}},clone:function(){return new this.constructor(this.x,this.y,this.z,this.w)},copy:function(t){return this.x=t.x,this.y=t.y,this.z=t.z,this.w=t.w!==void 0?t.w:1,this},add:function(t,e){return e!==void 0?this.addVectors(t,e):(this.x+=t.x,this.y+=t.y,this.z+=t.z,this.w+=t.w,this)},addScalar:function(t){return this.x+=t,this.y+=t,this.z+=t,this.w+=t,this},addVectors:function(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this.z=t.z+e.z,this.w=t.w+e.w,this},addScaledVector:function(t,e){return this.x+=t.x*e,this.y+=t.y*e,this.z+=t.z*e,this.w+=t.w*e,this},sub:function(t,e){return e!==void 0?this.subVectors(t,e):(this.x-=t.x,this.y-=t.y,this.z-=t.z,this.w-=t.w,this)},subScalar:function(t){return this.x-=t,this.y-=t,this.z-=t,this.w-=t,this},subVectors:function(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this.z=t.z-e.z,this.w=t.w-e.w,this},multiplyScalar:function(t){return this.x*=t,this.y*=t,this.z*=t,this.w*=t,this},applyMatrix4:function(t){var e=this.x,i=this.y,n=this.z,s=this.w;return t=t.elements,this.x=t[0]*e+t[4]*i+t[8]*n+t[12]*s,this.y=t[1]*e+t[5]*i+t[9]*n+t[13]*s,this.z=t[2]*e+t[6]*i+t[10]*n+t[14]*s,this.w=t[3]*e+t[7]*i+t[11]*n+t[15]*s,this},divideScalar:function(t){return this.multiplyScalar(1/t)},setAxisAngleFromQuaternion:function(t){this.w=2*Math.acos(t.w);var e=Math.sqrt(1-t.w*t.w);return 1e-4>e?(this.x=1,this.z=this.y=0):(this.x=t.x/e,this.y=t.y/e,this.z=t.z/e),this},setAxisAngleFromRotationMatrix:function(t){t=t.elements;var e=t[0],i=t[4],n=t[8],s=t[1],l=t[5],d=t[9],p=t[2],_=t[6],T=t[10];return .01>Math.abs(i-s)&&.01>Math.abs(n-p)&&.01>Math.abs(d-_)?.1>Math.abs(i+s)&&.1>Math.abs(n+p)&&.1>Math.abs(d+_)&&.1>Math.abs(e+l+T-3)?(this.set(1,0,0,0),this):(t=Math.PI,e=(e+1)/2,l=(l+1)/2,T=(T+1)/2,i=(i+s)/4,n=(n+p)/4,d=(d+_)/4,e>l&&e>T?.01>e?(_=0,i=p=.707106781):(_=Math.sqrt(e),p=i/_,i=n/_):l>T?.01>l?(_=.707106781,p=0,i=.707106781):(p=Math.sqrt(l),_=i/p,i=d/p):.01>T?(p=_=.707106781,i=0):(i=Math.sqrt(T),_=n/i,p=d/i),this.set(_,p,i,t),this):(t=Math.sqrt((_-d)*(_-d)+(n-p)*(n-p)+(s-i)*(s-i)),.001>Math.abs(t)&&(t=1),this.x=(_-d)/t,this.y=(n-p)/t,this.z=(s-i)/t,this.w=Math.acos((e+l+T-1)/2),this)},min:function(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.z=Math.min(this.z,t.z),this.w=Math.min(this.w,t.w),this},max:function(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this.z=Math.max(this.z,t.z),this.w=Math.max(this.w,t.w),this},clamp:function(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this.z=Math.max(t.z,Math.min(e.z,this.z)),this.w=Math.max(t.w,Math.min(e.w,this.w)),this},clampScalar:function(){var t,e;return function(i,n){return t===void 0&&(t=new v,e=new v),t.set(i,i,i,i),e.set(n,n,n,n),this.clamp(t,e)}}(),clampLength:function(t,e){var i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(t,Math.min(e,i)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this.w=Math.floor(this.w),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this.w=Math.ceil(this.w),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this.w=Math.round(this.w),this},roundToZero:function(){return this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x),this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y),this.z=0>this.z?Math.ceil(this.z):Math.floor(this.z),this.w=0>this.w?Math.ceil(this.w):Math.floor(this.w),this},negate:function(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this.w=-this.w,this},dot:function(t){return this.x*t.x+this.y*t.y+this.z*t.z+this.w*t.w},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)},normalize:function(){return this.divideScalar(this.length()||1)},setLength:function(t){return this.normalize().multiplyScalar(t)},lerp:function(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this.z+=(t.z-this.z)*e,this.w+=(t.w-this.w)*e,this},lerpVectors:function(t,e,i){return this.subVectors(e,t).multiplyScalar(i).add(t)},equals:function(t){return t.x===this.x&&t.y===this.y&&t.z===this.z&&t.w===this.w},fromArray:function(t,e){return e===void 0&&(e=0),this.x=t[e],this.y=t[e+1],this.z=t[e+2],this.w=t[e+3],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.x,t[e+1]=this.y,t[e+2]=this.z,t[e+3]=this.w,t},fromBufferAttribute:function(t,e,i){return this.x=t.getX(e),this.y=t.getY(e),this.z=t.getZ(e),this.w=t.getW(e),this}}),S.prototype=Object.assign(Object.create(a.prototype),{constructor:S,isWebGLRenderTarget:!0,setSize:function(t,e){(this.width!==t||this.height!==e)&&(this.width=t,this.height=e,this.dispose()),this.viewport.set(0,0,t,e),this.scissor.set(0,0,t,e)},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.width=t.width,this.height=t.height,this.viewport.copy(t.viewport),this.texture=t.texture.clone(),this.depthBuffer=t.depthBuffer,this.stencilBuffer=t.stencilBuffer,this.depthTexture=t.depthTexture,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),b.prototype=Object.create(S.prototype),b.prototype.constructor=b,b.prototype.isWebGLRenderTargetCube=!0,O.prototype=Object.create(g.prototype),O.prototype.constructor=O,O.prototype.isDataTexture=!0,Object.assign(k.prototype,{isBox3:!0,set:function(t,e){return this.min.copy(t),this.max.copy(e),this},setFromArray:function(t){for(var e=1/0,i=1/0,n=1/0,s=-1/0,l=-1/0,d=-1/0,p=0,_=t.length;p<_;p+=3){var T=t[p],A=t[p+1],L=t[p+2];T<e&&(e=T),A<i&&(i=A),L<n&&(n=L),T>s&&(s=T),A>l&&(l=A),L>d&&(d=L)}return this.min.set(e,i,n),this.max.set(s,l,d),this},setFromBufferAttribute:function(t){for(var e=1/0,i=1/0,n=1/0,s=-1/0,l=-1/0,d=-1/0,p=0,_=t.count;p<_;p++){var T=t.getX(p),A=t.getY(p),L=t.getZ(p);T<e&&(e=T),A<i&&(i=A),L<n&&(n=L),T>s&&(s=T),A>l&&(l=A),L>d&&(d=L)}return this.min.set(e,i,n),this.max.set(s,l,d),this},setFromPoints:function(t){this.makeEmpty();for(var e=0,i=t.length;e<i;e++)this.expandByPoint(t[e]);return this},setFromCenterAndSize:function(){var t=new u;return function(e,i){return i=t.copy(i).multiplyScalar(.5),this.min.copy(e).sub(i),this.max.copy(e).add(i),this}}(),setFromObject:function(t){return this.makeEmpty(),this.expandByObject(t)},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.min.copy(t.min),this.max.copy(t.max),this},makeEmpty:function(){return this.min.x=this.min.y=this.min.z=1/0,this.max.x=this.max.y=this.max.z=-1/0,this},isEmpty:function(){return this.max.x<this.min.x||this.max.y<this.min.y||this.max.z<this.min.z},getCenter:function(t){return t===void 0&&(t=new u),this.isEmpty()?t.set(0,0,0):t.addVectors(this.min,this.max).multiplyScalar(.5)},getSize:function(t){return t===void 0&&(t=new u),this.isEmpty()?t.set(0,0,0):t.subVectors(this.max,this.min)},expandByPoint:function(t){return this.min.min(t),this.max.max(t),this},expandByVector:function(t){return this.min.sub(t),this.max.add(t),this},expandByScalar:function(t){return this.min.addScalar(-t),this.max.addScalar(t),this},expandByObject:function(){function t(l){var d=l.geometry;if(d!==void 0){if(d.isGeometry)for(d=d.vertices,i=0,n=d.length;i<n;i++)s.copy(d[i]),s.applyMatrix4(l.matrixWorld),e.expandByPoint(s);else if(d.isBufferGeometry&&(d=d.attributes.position,d!==void 0))for(i=0,n=d.count;i<n;i++)s.fromBufferAttribute(d,i).applyMatrix4(l.matrixWorld),e.expandByPoint(s)}}var e,i,n,s=new u;return function(l){return e=this,l.updateMatrixWorld(!0),l.traverse(t),this}}(),containsPoint:function(t){return!(t.x<this.min.x||t.x>this.max.x||t.y<this.min.y||t.y>this.max.y||t.z<this.min.z||t.z>this.max.z)},containsBox:function(t){return this.min.x<=t.min.x&&t.max.x<=this.max.x&&this.min.y<=t.min.y&&t.max.y<=this.max.y&&this.min.z<=t.min.z&&t.max.z<=this.max.z},getParameter:function(t,e){return e===void 0&&(e=new u),e.set((t.x-this.min.x)/(this.max.x-this.min.x),(t.y-this.min.y)/(this.max.y-this.min.y),(t.z-this.min.z)/(this.max.z-this.min.z))},intersectsBox:function(t){return!(t.max.x<this.min.x||t.min.x>this.max.x||t.max.y<this.min.y||t.min.y>this.max.y||t.max.z<this.min.z||t.min.z>this.max.z)},intersectsSphere:function(){var t=new u;return function(e){return this.clampPoint(e.center,t),t.distanceToSquared(e.center)<=e.radius*e.radius}}(),intersectsPlane:function(t){if(0<t.normal.x)var e=t.normal.x*this.min.x,i=t.normal.x*this.max.x;else e=t.normal.x*this.max.x,i=t.normal.x*this.min.x;return 0<t.normal.y?(e+=t.normal.y*this.min.y,i+=t.normal.y*this.max.y):(e+=t.normal.y*this.max.y,i+=t.normal.y*this.min.y),0<t.normal.z?(e+=t.normal.z*this.min.z,i+=t.normal.z*this.max.z):(e+=t.normal.z*this.max.z,i+=t.normal.z*this.min.z),e<=-t.constant&&i>=-t.constant},intersectsTriangle:function(){function t(L){var B,H=0;for(B=L.length-3;H<=B;H+=3){p.fromArray(L,H);var q=T.x*Math.abs(p.x)+T.y*Math.abs(p.y)+T.z*Math.abs(p.z),J=e.dot(p),rt=i.dot(p),xt=n.dot(p);if(Math.max(-Math.max(J,rt,xt),Math.min(J,rt,xt))>q)return!1}return!0}var e=new u,i=new u,n=new u,s=new u,l=new u,d=new u,p=new u,_=new u,T=new u,A=new u;return function(L){return this.isEmpty()||(this.getCenter(_),T.subVectors(this.max,_),e.subVectors(L.a,_),i.subVectors(L.b,_),n.subVectors(L.c,_),s.subVectors(i,e),l.subVectors(n,i),d.subVectors(e,n),L=[0,-s.z,s.y,0,-l.z,l.y,0,-d.z,d.y,s.z,0,-s.x,l.z,0,-l.x,d.z,0,-d.x,-s.y,s.x,0,-l.y,l.x,0,-d.y,d.x,0],!t(L))||(L=[1,0,0,0,1,0,0,0,1],!t(L))?!1:(A.crossVectors(s,l),L=[A.x,A.y,A.z],t(L))}}(),clampPoint:function(t,e){return e===void 0&&(e=new u),e.copy(t).clamp(this.min,this.max)},distanceToPoint:function(){var t=new u;return function(e){return t.copy(e).clamp(this.min,this.max).sub(e).length()}}(),getBoundingSphere:function(){var t=new u;return function(e){return e===void 0&&(e=new I),this.getCenter(e.center),e.radius=.5*this.getSize(t).length(),e}}(),intersect:function(t){return this.min.max(t.min),this.max.min(t.max),this.isEmpty()&&this.makeEmpty(),this},union:function(t){return this.min.min(t.min),this.max.max(t.max),this},applyMatrix4:function(){var t=[new u,new u,new u,new u,new u,new u,new u,new u];return function(e){return this.isEmpty()?this:(t[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(e),t[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(e),t[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(e),t[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(e),t[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(e),t[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(e),t[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(e),t[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(e),this.setFromPoints(t),this)}}(),translate:function(t){return this.min.add(t),this.max.add(t),this},equals:function(t){return t.min.equals(this.min)&&t.max.equals(this.max)}}),Object.assign(I.prototype,{set:function(t,e){return this.center.copy(t),this.radius=e,this},setFromPoints:function(){var t=new k;return function(e,i){var n=this.center;i!==void 0?n.copy(i):t.setFromPoints(e).getCenter(n);for(var s=i=0,l=e.length;s<l;s++)i=Math.max(i,n.distanceToSquared(e[s]));return this.radius=Math.sqrt(i),this}}(),clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.center.copy(t.center),this.radius=t.radius,this},empty:function(){return 0>=this.radius},containsPoint:function(t){return t.distanceToSquared(this.center)<=this.radius*this.radius},distanceToPoint:function(t){return t.distanceTo(this.center)-this.radius},intersectsSphere:function(t){var e=this.radius+t.radius;return t.center.distanceToSquared(this.center)<=e*e},intersectsBox:function(t){return t.intersectsSphere(this)},intersectsPlane:function(t){return Math.abs(t.distanceToPoint(this.center))<=this.radius},clampPoint:function(t,e){var i=this.center.distanceToSquared(t);return e===void 0&&(e=new u),e.copy(t),i>this.radius*this.radius&&(e.sub(this.center).normalize(),e.multiplyScalar(this.radius).add(this.center)),e},getBoundingBox:function(t){return t===void 0&&(t=new k),t.set(this.center,this.center),t.expandByScalar(this.radius),t},applyMatrix4:function(t){return this.center.applyMatrix4(t),this.radius*=t.getMaxScaleOnAxis(),this},translate:function(t){return this.center.add(t),this},equals:function(t){return t.center.equals(this.center)&&t.radius===this.radius}}),Object.assign(N.prototype,{set:function(t,e){return this.normal.copy(t),this.constant=e,this},setComponents:function(t,e,i,n){return this.normal.set(t,e,i),this.constant=n,this},setFromNormalAndCoplanarPoint:function(t,e){return this.normal.copy(t),this.constant=-e.dot(this.normal),this},setFromCoplanarPoints:function(){var t=new u,e=new u;return function(i,n,s){return n=t.subVectors(s,n).cross(e.subVectors(i,n)).normalize(),this.setFromNormalAndCoplanarPoint(n,i),this}}(),clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.normal.copy(t.normal),this.constant=t.constant,this},normalize:function(){var t=1/this.normal.length();return this.normal.multiplyScalar(t),this.constant*=t,this},negate:function(){return this.constant*=-1,this.normal.negate(),this},distanceToPoint:function(t){return this.normal.dot(t)+this.constant},distanceToSphere:function(t){return this.distanceToPoint(t.center)-t.radius},projectPoint:function(t,e){return e===void 0&&(e=new u),e.copy(this.normal).multiplyScalar(-this.distanceToPoint(t)).add(t)},intersectLine:function(){var t=new u;return function(e,i){i===void 0&&(i=new u);var n=e.delta(t),s=this.normal.dot(n);if(s===0){if(this.distanceToPoint(e.start)===0)return i.copy(e.start)}else if(s=-(e.start.dot(this.normal)+this.constant)/s,!(0>s||1<s))return i.copy(n).multiplyScalar(s).add(e.start)}}(),intersectsLine:function(t){var e=this.distanceToPoint(t.start);return t=this.distanceToPoint(t.end),0>e&&0<t||0>t&&0<e},intersectsBox:function(t){return t.intersectsPlane(this)},intersectsSphere:function(t){return t.intersectsPlane(this)},coplanarPoint:function(t){return t===void 0&&(t=new u),t.copy(this.normal).multiplyScalar(-this.constant)},applyMatrix4:function(){var t=new u,e=new m;return function(i,n){return n=n||e.getNormalMatrix(i),i=this.coplanarPoint(t).applyMatrix4(i),n=this.normal.applyMatrix3(n).normalize(),this.constant=-i.dot(n),this}}(),translate:function(t){return this.constant-=t.dot(this.normal),this},equals:function(t){return t.normal.equals(this.normal)&&t.constant===this.constant}}),Object.assign(E.prototype,{set:function(t,e,i,n,s,l){var d=this.planes;return d[0].copy(t),d[1].copy(e),d[2].copy(i),d[3].copy(n),d[4].copy(s),d[5].copy(l),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){for(var e=this.planes,i=0;6>i;i++)e[i].copy(t.planes[i]);return this},setFromMatrix:function(t){var e=this.planes,i=t.elements;t=i[0];var n=i[1],s=i[2],l=i[3],d=i[4],p=i[5],_=i[6],T=i[7],A=i[8],L=i[9],B=i[10],H=i[11],q=i[12],J=i[13],rt=i[14];return i=i[15],e[0].setComponents(l-t,T-d,H-A,i-q).normalize(),e[1].setComponents(l+t,T+d,H+A,i+q).normalize(),e[2].setComponents(l+n,T+p,H+L,i+J).normalize(),e[3].setComponents(l-n,T-p,H-L,i-J).normalize(),e[4].setComponents(l-s,T-_,H-B,i-rt).normalize(),e[5].setComponents(l+s,T+_,H+B,i+rt).normalize(),this},intersectsObject:function(){var t=new I;return function(e){var i=e.geometry;return i.boundingSphere===null&&i.computeBoundingSphere(),t.copy(i.boundingSphere).applyMatrix4(e.matrixWorld),this.intersectsSphere(t)}}(),intersectsSprite:function(){var t=new I;return function(e){return t.center.set(0,0,0),t.radius=.7071067811865476,t.applyMatrix4(e.matrixWorld),this.intersectsSphere(t)}}(),intersectsSphere:function(t){var e=this.planes,i=t.center;t=-t.radius;for(var n=0;6>n;n++)if(e[n].distanceToPoint(i)<t)return!1;return!0},intersectsBox:function(){var t=new u;return function(e){for(var i=this.planes,n=0;6>n;n++){var s=i[n];if(t.x=0<s.normal.x?e.max.x:e.min.x,t.y=0<s.normal.y?e.max.y:e.min.y,t.z=0<s.normal.z?e.max.z:e.min.z,0>s.distanceToPoint(t))return!1}return!0}}(),containsPoint:function(t){for(var e=this.planes,i=0;6>i;i++)if(0>e[i].distanceToPoint(t))return!1;return!0}});var Ci={alphamap_fragment:`#ifdef USE_ALPHAMAP
|
|
285
|
+
`+e),A=e+A,T=aa(p,35633,_+T),A=aa(p,35632,A),p.attachShader(gt,T),p.attachShader(gt,A),n.index0AttributeName!==void 0?p.bindAttribLocation(gt,0,n.index0AttributeName):l.morphTargets===!0&&p.bindAttribLocation(gt,0,"position"),p.linkProgram(gt),l=p.getProgramInfoLog(gt).trim(),d=p.getShaderInfoLog(T).trim(),L=p.getShaderInfoLog(A).trim(),H=B=!0,p.getProgramParameter(gt,35714)===!1?B=!1:l!==""||(d===""||L==="")&&(H=!1),H&&(this.diagnostics={runnable:B,material:n,programLog:l,vertexShader:{log:d,prefix:_},fragmentShader:{log:L,prefix:e}}),p.deleteShader(T),p.deleteShader(A);var Ct;this.getUniforms=function(){return Ct===void 0&&(Ct=new ho(p,gt,t)),Ct};var wt;return this.getAttributes=function(){if(wt===void 0){for(var Vt={},K=p.getProgramParameter(gt,35721),ot=0;ot<K;ot++){var kt=p.getActiveAttrib(gt,ot).name;Vt[kt]=p.getAttribLocation(gt,kt)}wt=Vt}return wt},this.destroy=function(){p.deleteProgram(gt),this.program=void 0},Object.defineProperties(this,{uniforms:{get:function(){return this.getUniforms()}},attributes:{get:function(){return this.getAttributes()}}}),this.name=s.name,this.id=Bo++,this.code=i,this.usedTimes=1,this.program=gt,this.vertexShader=T,this.fragmentShader=A,this}function lt(t,e,i){function n(p,_){if(p)p.isTexture?T=p.encoding:p.isWebGLRenderTarget&&(T=p.texture.encoding);else var T=3e3;return T===3e3&&_&&(T=3007),T}var s=[],l={MeshDepthMaterial:"depth",MeshDistanceMaterial:"distanceRGBA",MeshNormalMaterial:"normal",MeshBasicMaterial:"basic",MeshLambertMaterial:"lambert",MeshPhongMaterial:"phong",MeshToonMaterial:"phong",MeshStandardMaterial:"physical",MeshPhysicalMaterial:"physical",MeshMatcapMaterial:"matcap",LineBasicMaterial:"basic",LineDashedMaterial:"dashed",PointsMaterial:"points",ShadowMaterial:"shadow",SpriteMaterial:"sprite"},d="precision supportsVertexTextures map mapEncoding matcapEncoding envMap envMapMode envMapEncoding lightMap aoMap emissiveMap emissiveMapEncoding bumpMap normalMap objectSpaceNormalMap displacementMap specularMap roughnessMap metalnessMap gradientMap alphaMap combine vertexColors fog useFog fogExp flatShading sizeAttenuation logarithmicDepthBuffer skinning maxBones useVertexTexture morphTargets morphNormals maxMorphTargets maxMorphNormals premultipliedAlpha numDirLights numPointLights numSpotLights numHemiLights numRectAreaLights shadowMapEnabled shadowMapType toneMapping physicallyCorrectLights alphaTest doubleSided flipSided numClippingPlanes numClipIntersection depthPacking dithering".split(" ");this.getParameters=function(p,_,T,A,L,B,H){var q=l[p.type];if(H.isSkinnedMesh){var $=H.skeleton.bones;if(i.floatVertexTextures)$=1024;else{var rt=Math.min(Math.floor((i.maxVertexUniforms-20)/4),$.length);rt<$.length?$=0:$=rt}}else $=0;rt=i.precision,p.precision!==null&&(rt=i.getMaxPrecision(p.precision),p.precision);var xt=t.getRenderTarget();return{shaderID:q,precision:rt,supportsVertexTextures:i.vertexTextures,outputEncoding:n(xt?xt.texture:null,t.gammaOutput),map:!!p.map,mapEncoding:n(p.map,t.gammaInput),matcap:!!p.matcap,matcapEncoding:n(p.matcap,t.gammaInput),envMap:!!p.envMap,envMapMode:p.envMap&&p.envMap.mapping,envMapEncoding:n(p.envMap,t.gammaInput),envMapCubeUV:!!p.envMap&&(p.envMap.mapping===306||p.envMap.mapping===307),lightMap:!!p.lightMap,aoMap:!!p.aoMap,emissiveMap:!!p.emissiveMap,emissiveMapEncoding:n(p.emissiveMap,t.gammaInput),bumpMap:!!p.bumpMap,normalMap:!!p.normalMap,objectSpaceNormalMap:p.normalMapType===1,displacementMap:!!p.displacementMap,roughnessMap:!!p.roughnessMap,metalnessMap:!!p.metalnessMap,specularMap:!!p.specularMap,alphaMap:!!p.alphaMap,gradientMap:!!p.gradientMap,combine:p.combine,vertexColors:p.vertexColors,fog:!!A,useFog:p.fog,fogExp:A&&A.isFogExp2,flatShading:p.flatShading,sizeAttenuation:p.sizeAttenuation,logarithmicDepthBuffer:i.logarithmicDepthBuffer,skinning:p.skinning&&0<$,maxBones:$,useVertexTexture:i.floatVertexTextures,morphTargets:p.morphTargets,morphNormals:p.morphNormals,maxMorphTargets:t.maxMorphTargets,maxMorphNormals:t.maxMorphNormals,numDirLights:_.directional.length,numPointLights:_.point.length,numSpotLights:_.spot.length,numRectAreaLights:_.rectArea.length,numHemiLights:_.hemi.length,numClippingPlanes:L,numClipIntersection:B,dithering:p.dithering,shadowMapEnabled:t.shadowMap.enabled&&H.receiveShadow&&0<T.length,shadowMapType:t.shadowMap.type,toneMapping:t.toneMapping,physicallyCorrectLights:t.physicallyCorrectLights,premultipliedAlpha:p.premultipliedAlpha,alphaTest:p.alphaTest,doubleSided:p.side===2,flipSided:p.side===1,depthPacking:p.depthPacking!==void 0?p.depthPacking:!1}},this.getProgramCode=function(p,_){var T=[];if(_.shaderID?T.push(_.shaderID):(T.push(p.fragmentShader),T.push(p.vertexShader)),p.defines!==void 0)for(var A in p.defines)T.push(A),T.push(p.defines[A]);for(A=0;A<d.length;A++)T.push(_[d[A]]);return T.push(p.onBeforeCompile.toString()),T.push(t.gammaOutput),T.push(t.gammaFactor),T.join()},this.acquireProgram=function(p,_,T,A){for(var L,B=0,H=s.length;B<H;B++){var q=s[B];if(q.code===A){L=q,++L.usedTimes;break}}return L===void 0&&(L=new et(t,e,A,p,_,T,i),s.push(L)),L},this.releaseProgram=function(p){if(--p.usedTimes===0){var _=s.indexOf(p);s[_]=s[s.length-1],s.pop(),p.destroy()}},this.programs=s}function at(){var t=new WeakMap;return{get:function(e){var i=t.get(e);return i===void 0&&(i={},t.set(e,i)),i},remove:function(e){t.delete(e)},update:function(e,i,n){t.get(e)[i]=n},dispose:function(){t=new WeakMap}}}function j(t,e){return t.renderOrder!==e.renderOrder?t.renderOrder-e.renderOrder:t.program&&e.program&&t.program!==e.program?t.program.id-e.program.id:t.material.id!==e.material.id?t.material.id-e.material.id:t.z!==e.z?t.z-e.z:t.id-e.id}function St(t,e){return t.renderOrder!==e.renderOrder?t.renderOrder-e.renderOrder:t.z!==e.z?e.z-t.z:t.id-e.id}function ht(){var t=[],e=0,i=[],n=[];return{opaque:i,transparent:n,init:function(){e=0,i.length=0,n.length=0},push:function(s,l,d,p,_){var T=t[e];T===void 0?(T={id:s.id,object:s,geometry:l,material:d,program:d.program,renderOrder:s.renderOrder,z:p,group:_},t[e]=T):(T.id=s.id,T.object=s,T.geometry=l,T.material=d,T.program=d.program,T.renderOrder=s.renderOrder,T.z=p,T.group=_),(d.transparent===!0?n:i).push(T),e++},sort:function(){1<i.length&&i.sort(j),1<n.length&&n.sort(St)}}}function Ot(){var t={};return{get:function(e,i){return e=e.id+","+i.id,i=t[e],i===void 0&&(i=new ht,t[e]=i),i},dispose:function(){t={}}}}function Gt(){var t={};return{get:function(e){if(t[e.id]!==void 0)return t[e.id];switch(e.type){case"DirectionalLight":var i={direction:new u,color:new P,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new o};break;case"SpotLight":i={position:new u,direction:new u,color:new P,distance:0,coneCos:0,penumbraCos:0,decay:0,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new o};break;case"PointLight":i={position:new u,color:new P,distance:0,decay:0,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new o,shadowCameraNear:1,shadowCameraFar:1e3};break;case"HemisphereLight":i={direction:new u,skyColor:new P,groundColor:new P};break;case"RectAreaLight":i={color:new P,position:new u,halfWidth:new u,halfHeight:new u}}return t[e.id]=i}}}function zt(){var t=new Gt,e={id:Jh++,hash:{stateID:-1,directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,shadowsLength:-1},ambient:[0,0,0],directional:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],point:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[]},i=new u,n=new c,s=new c;return{setup:function(l,d,p){var _=0,T=0,A=0,L=0,B=0,H=0,q=0,$=0;p=p.matrixWorldInverse;for(var rt=0,xt=l.length;rt<xt;rt++){var gt=l[rt],Ct=gt.color,wt=gt.intensity,Vt=gt.distance,K=gt.shadow&>.shadow.map?gt.shadow.map.texture:null;if(gt.isAmbientLight)_+=Ct.r*wt,T+=Ct.g*wt,A+=Ct.b*wt;else if(gt.isDirectionalLight){var ot=t.get(gt);ot.color.copy(gt.color).multiplyScalar(gt.intensity),ot.direction.setFromMatrixPosition(gt.matrixWorld),i.setFromMatrixPosition(gt.target.matrixWorld),ot.direction.sub(i),ot.direction.transformDirection(p),(ot.shadow=gt.castShadow)&&(Ct=gt.shadow,ot.shadowBias=Ct.bias,ot.shadowRadius=Ct.radius,ot.shadowMapSize=Ct.mapSize),e.directionalShadowMap[L]=K,e.directionalShadowMatrix[L]=gt.shadow.matrix,e.directional[L]=ot,L++}else gt.isSpotLight?(ot=t.get(gt),ot.position.setFromMatrixPosition(gt.matrixWorld),ot.position.applyMatrix4(p),ot.color.copy(Ct).multiplyScalar(wt),ot.distance=Vt,ot.direction.setFromMatrixPosition(gt.matrixWorld),i.setFromMatrixPosition(gt.target.matrixWorld),ot.direction.sub(i),ot.direction.transformDirection(p),ot.coneCos=Math.cos(gt.angle),ot.penumbraCos=Math.cos(gt.angle*(1-gt.penumbra)),ot.decay=gt.decay,(ot.shadow=gt.castShadow)&&(Ct=gt.shadow,ot.shadowBias=Ct.bias,ot.shadowRadius=Ct.radius,ot.shadowMapSize=Ct.mapSize),e.spotShadowMap[H]=K,e.spotShadowMatrix[H]=gt.shadow.matrix,e.spot[H]=ot,H++):gt.isRectAreaLight?(ot=t.get(gt),ot.color.copy(Ct).multiplyScalar(wt),ot.position.setFromMatrixPosition(gt.matrixWorld),ot.position.applyMatrix4(p),s.identity(),n.copy(gt.matrixWorld),n.premultiply(p),s.extractRotation(n),ot.halfWidth.set(.5*gt.width,0,0),ot.halfHeight.set(0,.5*gt.height,0),ot.halfWidth.applyMatrix4(s),ot.halfHeight.applyMatrix4(s),e.rectArea[q]=ot,q++):gt.isPointLight?(ot=t.get(gt),ot.position.setFromMatrixPosition(gt.matrixWorld),ot.position.applyMatrix4(p),ot.color.copy(gt.color).multiplyScalar(gt.intensity),ot.distance=gt.distance,ot.decay=gt.decay,(ot.shadow=gt.castShadow)&&(Ct=gt.shadow,ot.shadowBias=Ct.bias,ot.shadowRadius=Ct.radius,ot.shadowMapSize=Ct.mapSize,ot.shadowCameraNear=Ct.camera.near,ot.shadowCameraFar=Ct.camera.far),e.pointShadowMap[B]=K,e.pointShadowMatrix[B]=gt.shadow.matrix,e.point[B]=ot,B++):gt.isHemisphereLight&&(ot=t.get(gt),ot.direction.setFromMatrixPosition(gt.matrixWorld),ot.direction.transformDirection(p),ot.direction.normalize(),ot.skyColor.copy(gt.color).multiplyScalar(wt),ot.groundColor.copy(gt.groundColor).multiplyScalar(wt),e.hemi[$]=ot,$++)}e.ambient[0]=_,e.ambient[1]=T,e.ambient[2]=A,e.directional.length=L,e.spot.length=H,e.rectArea.length=q,e.point.length=B,e.hemi.length=$,e.hash.stateID=e.id,e.hash.directionalLength=L,e.hash.pointLength=B,e.hash.spotLength=H,e.hash.rectAreaLength=q,e.hash.hemiLength=$,e.hash.shadowsLength=d.length},state:e}}function Mt(){var t=new zt,e=[],i=[];return{init:function(){e.length=0,i.length=0},state:{lightsArray:e,shadowsArray:i,lights:t},setupLights:function(n){t.setup(e,i,n)},pushLight:function(n){e.push(n)},pushShadow:function(n){i.push(n)}}}function he(){var t={};return{get:function(e,i){if(t[e.id]===void 0){var n=new Mt;t[e.id]={},t[e.id][i.id]=n}else t[e.id][i.id]===void 0?(n=new Mt,t[e.id][i.id]=n):n=t[e.id][i.id];return n},dispose:function(){t={}}}}function se(t){Wt.call(this),this.type="MeshDepthMaterial",this.depthPacking=3200,this.morphTargets=this.skinning=!1,this.displacementMap=this.alphaMap=this.map=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.lights=this.fog=!1,this.setValues(t)}function te(t){Wt.call(this),this.type="MeshDistanceMaterial",this.referencePosition=new u,this.nearDistance=1,this.farDistance=1e3,this.morphTargets=this.skinning=!1,this.displacementMap=this.alphaMap=this.map=null,this.displacementScale=1,this.displacementBias=0,this.lights=this.fog=!1,this.setValues(t)}function ye(t,e,i){function n(K,ot,kt,ee,$t,Yt){var Te=K.geometry,ge=L,De=K.customDepthMaterial;return kt&&(ge=B,De=K.customDistanceMaterial),De?ge=De:(De=!1,ot.morphTargets&&(Te&&Te.isBufferGeometry?De=Te.morphAttributes&&Te.morphAttributes.position&&0<Te.morphAttributes.position.length:Te&&Te.isGeometry&&(De=Te.morphTargets&&0<Te.morphTargets.length)),K.isSkinnedMesh&&ot.skinning,K=K.isSkinnedMesh&&ot.skinning,Te=0,De&&(Te|=1),K&&(Te|=2),ge=ge[Te]),t.localClippingEnabled&&ot.clipShadows===!0&&ot.clippingPlanes.length!==0&&(Te=ge.uuid,De=ot.uuid,K=H[Te],K===void 0&&(K={},H[Te]=K),Te=K[De],Te===void 0&&(Te=ge.clone(),K[De]=Te),ge=Te),ge.visible=ot.visible,ge.wireframe=ot.wireframe,ge.side=ot.shadowSide!=null?ot.shadowSide:q[ot.side],ge.clipShadows=ot.clipShadows,ge.clippingPlanes=ot.clippingPlanes,ge.clipIntersection=ot.clipIntersection,ge.wireframeLinewidth=ot.wireframeLinewidth,ge.linewidth=ot.linewidth,kt&&ge.isMeshDistanceMaterial&&(ge.referencePosition.copy(ee),ge.nearDistance=$t,ge.farDistance=Yt),ge}function s(K,ot,kt,ee){if(K.visible!==!1){if(K.layers.test(ot.layers)&&(K.isMesh||K.isLine||K.isPoints)&&K.castShadow&&(!K.frustumCulled||l.intersectsObject(K))){K.modelViewMatrix.multiplyMatrices(kt.matrixWorldInverse,K.matrixWorld);var $t=e.update(K),Yt=K.material;if(Array.isArray(Yt))for(var Te=$t.groups,ge=0,De=Te.length;ge<De;ge++){var be=Te[ge],ae=Yt[be.materialIndex];ae&&ae.visible&&(ae=n(K,ae,ee,A,kt.near,kt.far),t.renderBufferDirect(kt,null,$t,ae,K,be))}else Yt.visible&&(ae=n(K,Yt,ee,A,kt.near,kt.far),t.renderBufferDirect(kt,null,$t,ae,K,null))}for(K=K.children,$t=0,Yt=K.length;$t<Yt;$t++)s(K[$t],ot,kt,ee)}}var l=new E,d=new c,p=new o,_=new o(i,i),T=new u,A=new u,L=Array(4),B=Array(4),H={},q={0:1,1:0,2:2},$=[new u(1,0,0),new u(-1,0,0),new u(0,0,1),new u(0,0,-1),new u(0,1,0),new u(0,-1,0)],rt=[new u(0,1,0),new u(0,1,0),new u(0,1,0),new u(0,1,0),new u(0,0,1),new u(0,0,-1)],xt=[new v,new v,new v,new v,new v,new v];for(i=0;i!==4;++i){var gt=(i&1)!==0,Ct=(i&2)!==0,wt=new se({depthPacking:3201,morphTargets:gt,skinning:Ct});L[i]=wt,gt=new te({morphTargets:gt,skinning:Ct}),B[i]=gt}var Vt=this;this.enabled=!1,this.autoUpdate=!0,this.needsUpdate=!1,this.type=1,this.render=function(K,ot,kt){if(Vt.enabled!==!1&&(Vt.autoUpdate!==!1||Vt.needsUpdate!==!1)&&K.length!==0){var ee=t.state;ee.disable(3042),ee.buffers.color.setClear(1,1,1,1),ee.buffers.depth.setTest(!0),ee.setScissorTest(!1);for(var $t,Yt=0,Te=K.length;Yt<Te;Yt++){var ge=K[Yt];$t=ge.shadow;var De=ge&&ge.isPointLight;if($t!==void 0){var be=$t.camera;if(p.copy($t.mapSize),p.min(_),De){var ae=p.x,We=p.y;xt[0].set(2*ae,We,ae,We),xt[1].set(0,We,ae,We),xt[2].set(3*ae,We,ae,We),xt[3].set(ae,We,ae,We),xt[4].set(3*ae,0,ae,We),xt[5].set(ae,0,ae,We),p.x*=4,p.y*=2}for($t.map===null&&($t.map=new S(p.x,p.y,{minFilter:1003,magFilter:1003,format:1023}),$t.map.texture.name=ge.name+".shadowMap",be.updateProjectionMatrix()),$t.isSpotLightShadow&&$t.update(ge),ae=$t.map,We=$t.matrix,A.setFromMatrixPosition(ge.matrixWorld),be.position.copy(A),De?($t=6,We.makeTranslation(-A.x,-A.y,-A.z)):($t=1,T.setFromMatrixPosition(ge.target.matrixWorld),be.lookAt(T),be.updateMatrixWorld(),We.set(.5,0,0,.5,0,.5,0,.5,0,0,.5,.5,0,0,0,1),We.multiply(be.projectionMatrix),We.multiply(be.matrixWorldInverse)),t.setRenderTarget(ae),t.clear(),ge=0;ge<$t;ge++)De&&(T.copy(be.position),T.add($[ge]),be.up.copy(rt[ge]),be.lookAt(T),be.updateMatrixWorld(),ee.viewport(xt[ge])),d.multiplyMatrices(be.projectionMatrix,be.matrixWorldInverse),l.setFromMatrix(d),s(ot,kt,be,De)}}Vt.needsUpdate=!1}}}function ue(t,e,i,n){function s(Ht,Ye,ei){var Wi=new Uint8Array(4),Ae=t.createTexture();for(t.bindTexture(Ht,Ae),t.texParameteri(Ht,10241,9728),t.texParameteri(Ht,10240,9728),Ht=0;Ht<ei;Ht++)t.texImage2D(Ye+Ht,0,6408,1,1,0,6408,5121,Wi);return Ae}function l(Ht,Ye){xt[Ht]=1,gt[Ht]===0&&(t.enableVertexAttribArray(Ht),gt[Ht]=1),Ct[Ht]!==Ye&&((n.isWebGL2?t:e.get("ANGLE_instanced_arrays"))[n.isWebGL2?"vertexAttribDivisor":"vertexAttribDivisorANGLE"](Ht,Ye),Ct[Ht]=Ye)}function d(Ht){wt[Ht]!==!0&&(t.enable(Ht),wt[Ht]=!0)}function p(Ht){wt[Ht]!==!1&&(t.disable(Ht),wt[Ht]=!1)}function _(Ht,Ye,ei,Wi,Ae,Xe,ri,Li){if(Ht===0)ot&&(p(3042),ot=!1);else if(ot||(d(3042),ot=!0),Ht!==5){if(Ht!==kt||Li!==be){if((ee!==100||Te!==100)&&(t.blendEquation(32774),Te=ee=100),Li)switch(Ht){case 1:t.blendFuncSeparate(1,771,1,771);break;case 2:t.blendFunc(1,1);break;case 3:t.blendFuncSeparate(0,0,769,771);break;case 4:t.blendFuncSeparate(0,768,0,770);break;default:}else switch(Ht){case 1:t.blendFuncSeparate(770,771,1,771);break;case 2:t.blendFunc(770,1);break;case 3:t.blendFunc(0,769);break;case 4:t.blendFunc(0,768);break;default:}De=ge=Yt=$t=null,kt=Ht,be=Li}}else Ae=Ae||Ye,Xe=Xe||ei,ri=ri||Wi,(Ye!==ee||Ae!==Te)&&(t.blendEquationSeparate(i.convert(Ye),i.convert(Ae)),ee=Ye,Te=Ae),(ei!==$t||Wi!==Yt||Xe!==ge||ri!==De)&&(t.blendFuncSeparate(i.convert(ei),i.convert(Wi),i.convert(Xe),i.convert(ri)),$t=ei,Yt=Wi,ge=Xe,De=ri),kt=Ht,be=null}function T(Ht){ae!==Ht&&(Ht?t.frontFace(2304):t.frontFace(2305),ae=Ht)}function A(Ht){Ht!==0?(d(2884),Ht!==We&&(Ht===1?t.cullFace(1029):Ht===2?t.cullFace(1028):t.cullFace(1032))):p(2884),We=Ht}function L(Ht,Ye,ei){Ht?(d(32823),(fi!==Ye||Cn!==ei)&&(t.polygonOffset(Ye,ei),fi=Ye,Cn=ei)):p(32823)}function B(Ht){Ht===void 0&&(Ht=33984+_n-1),Vi!==Ht&&(t.activeTexture(Ht),Vi=Ht)}var H=new function(){var Ht=!1,Ye=new v,ei=null,Wi=new v(0,0,0,0);return{setMask:function(Ae){ei===Ae||Ht||(t.colorMask(Ae,Ae,Ae,Ae),ei=Ae)},setLocked:function(Ae){Ht=Ae},setClear:function(Ae,Xe,ri,Li,Ai){Ai===!0&&(Ae*=Li,Xe*=Li,ri*=Li),Ye.set(Ae,Xe,ri,Li),Wi.equals(Ye)===!1&&(t.clearColor(Ae,Xe,ri,Li),Wi.copy(Ye))},reset:function(){Ht=!1,ei=null,Wi.set(-1,0,0,0)}}},q=new function(){var Ht=!1,Ye=null,ei=null,Wi=null;return{setTest:function(Ae){Ae?d(2929):p(2929)},setMask:function(Ae){Ye===Ae||Ht||(t.depthMask(Ae),Ye=Ae)},setFunc:function(Ae){if(ei!==Ae){if(Ae)switch(Ae){case 0:t.depthFunc(512);break;case 1:t.depthFunc(519);break;case 2:t.depthFunc(513);break;case 3:t.depthFunc(515);break;case 4:t.depthFunc(514);break;case 5:t.depthFunc(518);break;case 6:t.depthFunc(516);break;case 7:t.depthFunc(517);break;default:t.depthFunc(515)}else t.depthFunc(515);ei=Ae}},setLocked:function(Ae){Ht=Ae},setClear:function(Ae){Wi!==Ae&&(t.clearDepth(Ae),Wi=Ae)},reset:function(){Ht=!1,Wi=ei=Ye=null}}},$=new function(){var Ht=!1,Ye=null,ei=null,Wi=null,Ae=null,Xe=null,ri=null,Li=null,Ai=null;return{setTest:function(ne){ne?d(2960):p(2960)},setMask:function(ne){Ye===ne||Ht||(t.stencilMask(ne),Ye=ne)},setFunc:function(ne,ii,Je){(ei!==ne||Wi!==ii||Ae!==Je)&&(t.stencilFunc(ne,ii,Je),ei=ne,Wi=ii,Ae=Je)},setOp:function(ne,ii,Je){(Xe!==ne||ri!==ii||Li!==Je)&&(t.stencilOp(ne,ii,Je),Xe=ne,ri=ii,Li=Je)},setLocked:function(ne){Ht=ne},setClear:function(ne){Ai!==ne&&(t.clearStencil(ne),Ai=ne)},reset:function(){Ht=!1,Ai=Li=ri=Xe=Ae=Wi=ei=Ye=null}}},rt=t.getParameter(34921),xt=new Uint8Array(rt),gt=new Uint8Array(rt),Ct=new Uint8Array(rt),wt={},Vt=null,K=null,ot=null,kt=null,ee=null,$t=null,Yt=null,Te=null,ge=null,De=null,be=!1,ae=null,We=null,Qe=null,fi=null,Cn=null,_n=t.getParameter(35661),qi=!1;rt=0,rt=t.getParameter(7938),rt.indexOf("WebGL")!==-1?(rt=parseFloat(/^WebGL ([0-9])/.exec(rt)[1]),qi=1<=rt):rt.indexOf("OpenGL ES")!==-1&&(rt=parseFloat(/^OpenGL ES ([0-9])/.exec(rt)[1]),qi=2<=rt);var Vi=null,on={},An=new v,Ce=new v,ti={};return ti[3553]=s(3553,3553,1),ti[34067]=s(34067,34069,6),H.setClear(0,0,0,1),q.setClear(1),$.setClear(0),d(2929),q.setFunc(3),T(!1),A(1),d(2884),_(0),{buffers:{color:H,depth:q,stencil:$},initAttributes:function(){for(var Ht=0,Ye=xt.length;Ht<Ye;Ht++)xt[Ht]=0},enableAttribute:function(Ht){l(Ht,0)},enableAttributeAndDivisor:l,disableUnusedAttributes:function(){for(var Ht=0,Ye=gt.length;Ht!==Ye;++Ht)gt[Ht]!==xt[Ht]&&(t.disableVertexAttribArray(Ht),gt[Ht]=0)},enable:d,disable:p,getCompressedTextureFormats:function(){if(Vt===null&&(Vt=[],e.get("WEBGL_compressed_texture_pvrtc")||e.get("WEBGL_compressed_texture_s3tc")||e.get("WEBGL_compressed_texture_etc1")||e.get("WEBGL_compressed_texture_astc")))for(var Ht=t.getParameter(34467),Ye=0;Ye<Ht.length;Ye++)Vt.push(Ht[Ye]);return Vt},useProgram:function(Ht){return K!==Ht?(t.useProgram(Ht),K=Ht,!0):!1},setBlending:_,setMaterial:function(Ht,Ye){Ht.side===2?p(2884):d(2884);var ei=Ht.side===1;Ye&&(ei=!ei),T(ei),Ht.blending===1&&Ht.transparent===!1?_(0):_(Ht.blending,Ht.blendEquation,Ht.blendSrc,Ht.blendDst,Ht.blendEquationAlpha,Ht.blendSrcAlpha,Ht.blendDstAlpha,Ht.premultipliedAlpha),q.setFunc(Ht.depthFunc),q.setTest(Ht.depthTest),q.setMask(Ht.depthWrite),H.setMask(Ht.colorWrite),L(Ht.polygonOffset,Ht.polygonOffsetFactor,Ht.polygonOffsetUnits)},setFlipSided:T,setCullFace:A,setLineWidth:function(Ht){Ht!==Qe&&(qi&&t.lineWidth(Ht),Qe=Ht)},setPolygonOffset:L,setScissorTest:function(Ht){Ht?d(3089):p(3089)},activeTexture:B,bindTexture:function(Ht,Ye){Vi===null&&B();var ei=on[Vi];ei===void 0&&(ei={type:void 0,texture:void 0},on[Vi]=ei),(ei.type!==Ht||ei.texture!==Ye)&&(t.bindTexture(Ht,Ye||ti[Ht]),ei.type=Ht,ei.texture=Ye)},compressedTexImage2D:function(){try{t.compressedTexImage2D.apply(t,arguments)}catch{}},texImage2D:function(){try{t.texImage2D.apply(t,arguments)}catch{}},texImage3D:function(){try{t.texImage3D.apply(t,arguments)}catch{}},scissor:function(Ht){An.equals(Ht)===!1&&(t.scissor(Ht.x,Ht.y,Ht.z,Ht.w),An.copy(Ht))},viewport:function(Ht){Ce.equals(Ht)===!1&&(t.viewport(Ht.x,Ht.y,Ht.z,Ht.w),Ce.copy(Ht))},reset:function(){for(var Ht=0;Ht<gt.length;Ht++)gt[Ht]===1&&(t.disableVertexAttribArray(Ht),gt[Ht]=0);wt={},Vi=Vt=null,on={},We=ae=kt=K=null,H.reset(),q.reset(),$.reset()}}}function je(t,e,i,n,s,l,d){function p(K,ot){if(K.width>ot||K.height>ot){if("data"in K)return;ot/=Math.max(K.width,K.height);var kt=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");return kt.width=Math.floor(K.width*ot),kt.height=Math.floor(K.height*ot),kt.getContext("2d").drawImage(K,0,0,K.width,K.height,0,0,kt.width,kt.height),kt}return K}function _(K){return di.isPowerOfTwo(K.width)&&di.isPowerOfTwo(K.height)}function T(K,ot){return K.generateMipmaps&&ot&&K.minFilter!==1003&&K.minFilter!==1006}function A(K,ot,kt,ee){t.generateMipmap(K),n.get(ot).__maxMipLevel=Math.log(Math.max(kt,ee))*Math.LOG2E}function L(K,ot){if(!s.isWebGL2)return K;if(K===6403){if(ot===5126)return 33326;if(ot===5131)return 33325;if(ot===5121)return 33321}if(K===6407){if(ot===5126)return 34837;if(ot===5131)return 34843;if(ot===5121)return 32849}if(K===6408){if(ot===5126)return 34836;if(ot===5131)return 34842;if(ot===5121)return 32856}return K}function B(K){return K===1003||K===1004||K===1005?9728:9729}function H(K){K=K.target,K.removeEventListener("dispose",H);t:{var ot=n.get(K);if(K.image&&ot.__image__webglTextureCube)t.deleteTexture(ot.__image__webglTextureCube);else{if(ot.__webglInit===void 0)break t;t.deleteTexture(ot.__webglTexture)}n.remove(K)}K.isVideoTexture&&delete wt[K.id],d.memory.textures--}function q(K){K=K.target,K.removeEventListener("dispose",q);var ot=n.get(K),kt=n.get(K.texture);if(K){if(kt.__webglTexture!==void 0&&t.deleteTexture(kt.__webglTexture),K.depthTexture&&K.depthTexture.dispose(),K.isWebGLRenderTargetCube)for(kt=0;6>kt;kt++)t.deleteFramebuffer(ot.__webglFramebuffer[kt]),ot.__webglDepthbuffer&&t.deleteRenderbuffer(ot.__webglDepthbuffer[kt]);else t.deleteFramebuffer(ot.__webglFramebuffer),ot.__webglDepthbuffer&&t.deleteRenderbuffer(ot.__webglDepthbuffer);n.remove(K.texture),n.remove(K)}d.memory.textures--}function $(K,ot){var kt=n.get(K);if(K.isVideoTexture){var ee=K.id,$t=d.render.frame;wt[ee]!==$t&&(wt[ee]=$t,K.update())}if(0<K.version&&kt.__version!==K.version&&(ee=K.image,ee!==void 0)){if(ee.complete!==!1){xt(kt,K,ot);return}}i.activeTexture(33984+ot),i.bindTexture(3553,kt.__webglTexture)}function rt(K,ot,kt){kt?(t.texParameteri(K,10242,l.convert(ot.wrapS)),t.texParameteri(K,10243,l.convert(ot.wrapT)),t.texParameteri(K,10240,l.convert(ot.magFilter)),t.texParameteri(K,10241,l.convert(ot.minFilter))):(t.texParameteri(K,10242,33071),t.texParameteri(K,10243,33071),ot.wrapS===1001&&ot.wrapT,t.texParameteri(K,10240,B(ot.magFilter)),t.texParameteri(K,10241,B(ot.minFilter)),ot.minFilter!==1003&&ot.minFilter),!(kt=e.get("EXT_texture_filter_anisotropic"))||ot.type===1015&&e.get("OES_texture_float_linear")===null||ot.type===1016&&(s.isWebGL2||e.get("OES_texture_half_float_linear"))===null||!(1<ot.anisotropy||n.get(ot).__currentAnisotropy)||(t.texParameterf(K,kt.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(ot.anisotropy,s.getMaxAnisotropy())),n.get(ot).__currentAnisotropy=ot.anisotropy)}function xt(K,ot,kt){var ee=ot.isDataTexture3D?32879:3553;K.__webglInit===void 0&&(K.__webglInit=!0,ot.addEventListener("dispose",H),K.__webglTexture=t.createTexture(),d.memory.textures++),i.activeTexture(33984+kt),i.bindTexture(ee,K.__webglTexture),t.pixelStorei(37440,ot.flipY),t.pixelStorei(37441,ot.premultiplyAlpha),t.pixelStorei(3317,ot.unpackAlignment),kt=p(ot.image,s.maxTextureSize);var $t=s.isWebGL2?!1:ot.wrapS!==1001||ot.wrapT!==1001||ot.minFilter!==1003&&ot.minFilter!==1006;$t&&_(kt)===!1&&(kt instanceof HTMLImageElement||kt instanceof HTMLCanvasElement||kt instanceof ImageBitmap)&&(Vt===void 0&&(Vt=document.createElementNS("http://www.w3.org/1999/xhtml","canvas")),Vt.width=di.floorPowerOfTwo(kt.width),Vt.height=di.floorPowerOfTwo(kt.height),Vt.getContext("2d").drawImage(kt,0,0,Vt.width,Vt.height),kt=Vt),$t=_(kt);var Yt=l.convert(ot.format),Te=l.convert(ot.type),ge=L(Yt,Te);rt(ee,ot,$t);var De=ot.mipmaps;if(ot.isDepthTexture){if(ge=6402,ot.type===1015){if(!s.isWebGL2)throw Error("Float Depth Texture only supported in WebGL2.0");ge=36012}else s.isWebGL2&&(ge=33189);ot.format===1026&&ge===6402&&ot.type!==1012&&ot.type!==1014&&(ot.type=1012,Te=l.convert(ot.type)),ot.format===1027&&(ge=34041,ot.type!==1020&&(ot.type=1020,Te=l.convert(ot.type))),i.texImage2D(3553,0,ge,kt.width,kt.height,0,Yt,Te,null)}else if(ot.isDataTexture)if(0<De.length&&$t){for(var be=0,ae=De.length;be<ae;be++)ee=De[be],i.texImage2D(3553,be,ge,ee.width,ee.height,0,Yt,Te,ee.data);ot.generateMipmaps=!1,K.__maxMipLevel=De.length-1}else i.texImage2D(3553,0,ge,kt.width,kt.height,0,Yt,Te,kt.data),K.__maxMipLevel=0;else if(ot.isCompressedTexture){for(be=0,ae=De.length;be<ae;be++)ee=De[be],ot.format!==1023&&ot.format!==1022?-1<i.getCompressedTextureFormats().indexOf(Yt)&&i.compressedTexImage2D(3553,be,ge,ee.width,ee.height,0,ee.data):i.texImage2D(3553,be,ge,ee.width,ee.height,0,Yt,Te,ee.data);K.__maxMipLevel=De.length-1}else if(ot.isDataTexture3D)i.texImage3D(32879,0,ge,kt.width,kt.height,kt.depth,0,Yt,Te,kt.data),K.__maxMipLevel=0;else if(0<De.length&&$t){for(be=0,ae=De.length;be<ae;be++)ee=De[be],i.texImage2D(3553,be,ge,Yt,Te,ee);ot.generateMipmaps=!1,K.__maxMipLevel=De.length-1}else i.texImage2D(3553,0,ge,Yt,Te,kt),K.__maxMipLevel=0;T(ot,$t)&&A(3553,ot,kt.width,kt.height),K.__version=ot.version,ot.onUpdate&&ot.onUpdate(ot)}function gt(K,ot,kt,ee){var $t=l.convert(ot.texture.format),Yt=l.convert(ot.texture.type),Te=L($t,Yt);i.texImage2D(ee,0,Te,ot.width,ot.height,0,$t,Yt,null),t.bindFramebuffer(36160,K),t.framebufferTexture2D(36160,kt,ee,n.get(ot.texture).__webglTexture,0),t.bindFramebuffer(36160,null)}function Ct(K,ot){t.bindRenderbuffer(36161,K),ot.depthBuffer&&!ot.stencilBuffer?(t.renderbufferStorage(36161,33189,ot.width,ot.height),t.framebufferRenderbuffer(36160,36096,36161,K)):ot.depthBuffer&&ot.stencilBuffer?(t.renderbufferStorage(36161,34041,ot.width,ot.height),t.framebufferRenderbuffer(36160,33306,36161,K)):t.renderbufferStorage(36161,32854,ot.width,ot.height),t.bindRenderbuffer(36161,null)}var wt={},Vt;this.setTexture2D=$,this.setTexture3D=function(K,ot){var kt=n.get(K);0<K.version&&kt.__version!==K.version?xt(kt,K,ot):(i.activeTexture(33984+ot),i.bindTexture(32879,kt.__webglTexture))},this.setTextureCube=function(K,ot){var kt=n.get(K);if(K.image.length===6)if(0<K.version&&kt.__version!==K.version){kt.__image__webglTextureCube||(K.addEventListener("dispose",H),kt.__image__webglTextureCube=t.createTexture(),d.memory.textures++),i.activeTexture(33984+ot),i.bindTexture(34067,kt.__image__webglTextureCube),t.pixelStorei(37440,K.flipY),ot=K&&K.isCompressedTexture;for(var ee=K.image[0]&&K.image[0].isDataTexture,$t=[],Yt=0;6>Yt;Yt++)$t[Yt]=ot||ee?ee?K.image[Yt].image:K.image[Yt]:p(K.image[Yt],s.maxCubemapSize);var Te=$t[0],ge=_(Te),De=l.convert(K.format),be=l.convert(K.type),ae=L(De,be);for(rt(34067,K,ge),Yt=0;6>Yt;Yt++)if(ot)for(var We,Qe=$t[Yt].mipmaps,fi=0,Cn=Qe.length;fi<Cn;fi++)We=Qe[fi],K.format!==1023&&K.format!==1022?-1<i.getCompressedTextureFormats().indexOf(De)&&i.compressedTexImage2D(34069+Yt,fi,ae,We.width,We.height,0,We.data):i.texImage2D(34069+Yt,fi,ae,We.width,We.height,0,De,be,We.data);else ee?i.texImage2D(34069+Yt,0,ae,$t[Yt].width,$t[Yt].height,0,De,be,$t[Yt].data):i.texImage2D(34069+Yt,0,ae,De,be,$t[Yt]);kt.__maxMipLevel=ot?Qe.length-1:0,T(K,ge)&&A(34067,K,Te.width,Te.height),kt.__version=K.version,K.onUpdate&&K.onUpdate(K)}else i.activeTexture(33984+ot),i.bindTexture(34067,kt.__image__webglTextureCube)},this.setTextureCubeDynamic=function(K,ot){i.activeTexture(33984+ot),i.bindTexture(34067,n.get(K).__webglTexture)},this.setupRenderTarget=function(K){var ot=n.get(K),kt=n.get(K.texture);K.addEventListener("dispose",q),kt.__webglTexture=t.createTexture(),d.memory.textures++;var ee=K.isWebGLRenderTargetCube===!0,$t=_(K);if(ee){ot.__webglFramebuffer=[];for(var Yt=0;6>Yt;Yt++)ot.__webglFramebuffer[Yt]=t.createFramebuffer()}else ot.__webglFramebuffer=t.createFramebuffer();if(ee){for(i.bindTexture(34067,kt.__webglTexture),rt(34067,K.texture,$t),Yt=0;6>Yt;Yt++)gt(ot.__webglFramebuffer[Yt],K,36064,34069+Yt);T(K.texture,$t)&&A(34067,K.texture,K.width,K.height),i.bindTexture(34067,null)}else i.bindTexture(3553,kt.__webglTexture),rt(3553,K.texture,$t),gt(ot.__webglFramebuffer,K,36064,3553),T(K.texture,$t)&&A(3553,K.texture,K.width,K.height),i.bindTexture(3553,null);if(K.depthBuffer){if(ot=n.get(K),kt=K.isWebGLRenderTargetCube===!0,K.depthTexture){if(kt)throw Error("target.depthTexture not supported in Cube render targets");if(K&&K.isWebGLRenderTargetCube)throw Error("Depth Texture with cube render targets is not supported");if(t.bindFramebuffer(36160,ot.__webglFramebuffer),!K.depthTexture||!K.depthTexture.isDepthTexture)throw Error("renderTarget.depthTexture must be an instance of THREE.DepthTexture");if(n.get(K.depthTexture).__webglTexture&&K.depthTexture.image.width===K.width&&K.depthTexture.image.height===K.height||(K.depthTexture.image.width=K.width,K.depthTexture.image.height=K.height,K.depthTexture.needsUpdate=!0),$(K.depthTexture,0),ot=n.get(K.depthTexture).__webglTexture,K.depthTexture.format===1026)t.framebufferTexture2D(36160,36096,3553,ot,0);else if(K.depthTexture.format===1027)t.framebufferTexture2D(36160,33306,3553,ot,0);else throw Error("Unknown depthTexture format")}else if(kt)for(ot.__webglDepthbuffer=[],kt=0;6>kt;kt++)t.bindFramebuffer(36160,ot.__webglFramebuffer[kt]),ot.__webglDepthbuffer[kt]=t.createRenderbuffer(),Ct(ot.__webglDepthbuffer[kt],K);else t.bindFramebuffer(36160,ot.__webglFramebuffer),ot.__webglDepthbuffer=t.createRenderbuffer(),Ct(ot.__webglDepthbuffer,K);t.bindFramebuffer(36160,null)}},this.updateRenderTargetMipmap=function(K){var ot=K.texture,kt=_(K);if(T(ot,kt)){kt=K.isWebGLRenderTargetCube?34067:3553;var ee=n.get(ot).__webglTexture;i.bindTexture(kt,ee),A(kt,ot,K.width,K.height),i.bindTexture(kt,null)}}}function He(t,e,i){return{convert:function(n){if(n===1e3)return 10497;if(n===1001)return 33071;if(n===1002)return 33648;if(n===1003)return 9728;if(n===1004)return 9984;if(n===1005)return 9986;if(n===1006)return 9729;if(n===1007)return 9985;if(n===1008)return 9987;if(n===1009)return 5121;if(n===1017)return 32819;if(n===1018)return 32820;if(n===1019)return 33635;if(n===1010)return 5120;if(n===1011)return 5122;if(n===1012)return 5123;if(n===1013)return 5124;if(n===1014)return 5125;if(n===1015)return 5126;if(n===1016){if(i.isWebGL2)return 5131;var s=e.get("OES_texture_half_float");if(s!==null)return s.HALF_FLOAT_OES}if(n===1021)return 6406;if(n===1022)return 6407;if(n===1023)return 6408;if(n===1024)return 6409;if(n===1025)return 6410;if(n===1026)return 6402;if(n===1027)return 34041;if(n===1028)return 6403;if(n===100)return 32774;if(n===101)return 32778;if(n===102)return 32779;if(n===200)return 0;if(n===201)return 1;if(n===202)return 768;if(n===203)return 769;if(n===204)return 770;if(n===205)return 771;if(n===206)return 772;if(n===207)return 773;if(n===208)return 774;if(n===209)return 775;if(n===210)return 776;if((n===33776||n===33777||n===33778||n===33779)&&(s=e.get("WEBGL_compressed_texture_s3tc"),s!==null)){if(n===33776)return s.COMPRESSED_RGB_S3TC_DXT1_EXT;if(n===33777)return s.COMPRESSED_RGBA_S3TC_DXT1_EXT;if(n===33778)return s.COMPRESSED_RGBA_S3TC_DXT3_EXT;if(n===33779)return s.COMPRESSED_RGBA_S3TC_DXT5_EXT}if((n===35840||n===35841||n===35842||n===35843)&&(s=e.get("WEBGL_compressed_texture_pvrtc"),s!==null)){if(n===35840)return s.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;if(n===35841)return s.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;if(n===35842)return s.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;if(n===35843)return s.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG}if(n===36196&&(s=e.get("WEBGL_compressed_texture_etc1"),s!==null))return s.COMPRESSED_RGB_ETC1_WEBGL;if((n===37808||n===37809||n===37810||n===37811||n===37812||n===37813||n===37814||n===37815||n===37816||n===37817||n===37818||n===37819||n===37820||n===37821)&&(s=e.get("WEBGL_compressed_texture_astc"),s!==null))return n;if(n===103||n===104){if(i.isWebGL2){if(n===103)return 32775;if(n===104)return 32776}if(s=e.get("EXT_blend_minmax"),s!==null){if(n===103)return s.MIN_EXT;if(n===104)return s.MAX_EXT}}if(n===1020){if(i.isWebGL2)return 34042;if(s=e.get("WEBGL_depth_texture"),s!==null)return s.UNSIGNED_INT_24_8_WEBGL}return 0}}}function ci(){N.call(this),this.type="Group"}function Be(){N.call(this),this.type="Camera",this.matrixWorldInverse=new c,this.projectionMatrix=new c,this.projectionMatrixInverse=new c}function _e(t,e,i,n){Be.call(this),this.type="PerspectiveCamera",this.fov=t!==void 0?t:50,this.zoom=1,this.near=i!==void 0?i:.1,this.far=n!==void 0?n:2e3,this.focus=10,this.aspect=e!==void 0?e:1,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}function Fe(t){_e.call(this),this.cameras=t||[]}function fe(t,e,i){ls.setFromMatrixPosition(e.matrixWorld),wr.setFromMatrixPosition(i.matrixWorld);var n=ls.distanceTo(wr),s=e.projectionMatrix.elements,l=i.projectionMatrix.elements,d=s[14]/(s[10]-1);i=s[14]/(s[10]+1);var p=(s[9]+1)/s[5],_=(s[9]-1)/s[5],T=(s[8]-1)/s[0],A=(l[8]+1)/l[0];s=d*T,l=d*A,A=n/(-T+A),T=A*-T,e.matrixWorld.decompose(t.position,t.quaternion,t.scale),t.translateX(T),t.translateZ(A),t.matrixWorld.compose(t.position,t.quaternion,t.scale),t.matrixWorldInverse.getInverse(t.matrixWorld),e=d+A,d=i+A,t.projectionMatrix.makePerspective(s-T,l+(n-T),p*i/d*e,_*i/d*e,e,d)}function mi(t){function e(){return s!==null&&s.isPresenting===!0}function i(){if(e()){var K=s.getEyeParameters("left"),ot=K.renderWidth*A;K=K.renderHeight*A,Ct=t.getPixelRatio(),gt=t.getSize(),t.setDrawingBufferSize(2*ot,K,1),Vt.start()}else n.enabled&&t.setDrawingBufferSize(gt.width,gt.height,Ct),Vt.stop()}var n=this,s=null,l=null,d=null,p=[],_=new c,T=new c,A=1,L="stage";typeof window<"u"&&"VRFrameData"in window&&(l=new window.VRFrameData,window.addEventListener("vrdisplaypresentchange",i,!1));var B=new c,H=new f,q=new u,$=new _e;$.bounds=new v(0,0,.5,1),$.layers.enable(1);var rt=new _e;rt.bounds=new v(.5,0,.5,1),rt.layers.enable(2);var xt=new Fe([$,rt]);xt.layers.enable(1),xt.layers.enable(2);var gt,Ct,wt=[];this.enabled=!1,this.getController=function(K){var ot=p[K];return ot===void 0&&(ot=new ci,ot.matrixAutoUpdate=!1,ot.visible=!1,p[K]=ot),ot},this.getDevice=function(){return s},this.setDevice=function(K){K!==void 0&&(s=K),Vt.setContext(K)},this.setFramebufferScaleFactor=function(K){A=K},this.setFrameOfReferenceType=function(K){L=K},this.setPoseTarget=function(K){K!==void 0&&(d=K)},this.getCamera=function(K){var ot=L==="stage"?1.6:0;if(s===null)return K.position.set(0,ot,0),K;if(s.depthNear=K.near,s.depthFar=K.far,s.getFrameData(l),L==="stage"){var kt=s.stageParameters;kt?_.fromArray(kt.sittingToStandingTransform):_.makeTranslation(0,ot,0)}if(ot=l.pose,kt=d!==null?d:K,kt.matrix.copy(_),kt.matrix.decompose(kt.position,kt.quaternion,kt.scale),ot.orientation!==null&&(H.fromArray(ot.orientation),kt.quaternion.multiply(H)),ot.position!==null&&(H.setFromRotationMatrix(_),q.fromArray(ot.position),q.applyQuaternion(H),kt.position.add(q)),kt.updateMatrixWorld(),s.isPresenting===!1)return K;$.near=K.near,rt.near=K.near,$.far=K.far,rt.far=K.far,$.matrixWorldInverse.fromArray(l.leftViewMatrix),rt.matrixWorldInverse.fromArray(l.rightViewMatrix),T.getInverse(_),L==="stage"&&($.matrixWorldInverse.multiply(T),rt.matrixWorldInverse.multiply(T)),K=kt.parent,K!==null&&(B.getInverse(K.matrixWorld),$.matrixWorldInverse.multiply(B),rt.matrixWorldInverse.multiply(B)),$.matrixWorld.getInverse($.matrixWorldInverse),rt.matrixWorld.getInverse(rt.matrixWorldInverse),$.projectionMatrix.fromArray(l.leftProjectionMatrix),rt.projectionMatrix.fromArray(l.rightProjectionMatrix),fe(xt,$,rt),K=s.getLayers(),K.length&&(K=K[0],K.leftBounds!==null&&K.leftBounds.length===4&&$.bounds.fromArray(K.leftBounds),K.rightBounds!==null&&K.rightBounds.length===4&&rt.bounds.fromArray(K.rightBounds));t:for(K=0;K<p.length;K++){ot=p[K];e:{kt=K;for(var ee=navigator.getGamepads&&navigator.getGamepads(),$t=0,Yt=0,Te=ee.length;$t<Te;$t++){var ge=ee[$t];if(ge&&(ge.id==="Daydream Controller"||ge.id==="Gear VR Controller"||ge.id==="Oculus Go Controller"||ge.id==="OpenVR Gamepad"||ge.id.startsWith("Oculus Touch")||ge.id.startsWith("Spatial Controller"))){if(Yt===kt){kt=ge;break e}Yt++}}kt=void 0}if(kt!==void 0&&kt.pose!==void 0){if(kt.pose===null)break t;ee=kt.pose,ee.hasPosition===!1&&ot.position.set(.2,-.6,-.05),ee.position!==null&&ot.position.fromArray(ee.position),ee.orientation!==null&&ot.quaternion.fromArray(ee.orientation),ot.matrix.compose(ot.position,ot.quaternion,ot.scale),ot.matrix.premultiply(_),ot.matrix.decompose(ot.position,ot.quaternion,ot.scale),ot.matrixWorldNeedsUpdate=!0,ot.visible=!0,ee=kt.id==="Daydream Controller"?0:1,wt[K]!==kt.buttons[ee].pressed&&(wt[K]=kt.buttons[ee].pressed,wt[K]===!0?ot.dispatchEvent({type:"selectstart"}):(ot.dispatchEvent({type:"selectend"}),ot.dispatchEvent({type:"select"})))}else ot.visible=!1}return xt},this.getStandingMatrix=function(){return _},this.isPresenting=e;var Vt=new w;this.setAnimationLoop=function(K){Vt.setAnimationLoop(K)},this.submitFrame=function(){e()&&s.submitFrame()},this.dispose=function(){typeof window<"u"&&window.removeEventListener("vrdisplaypresentchange",i)}}function Le(t){function e(){return p!==null&&T!==null}function i(Ct){var wt=B[H.indexOf(Ct.inputSource)];wt&&wt.dispatchEvent({type:Ct.type})}function n(){t.setFramebuffer(null),gt.stop()}function s(Ct,wt){wt===null?Ct.matrixWorld.copy(Ct.matrix):Ct.matrixWorld.multiplyMatrices(wt.matrixWorld,Ct.matrix),Ct.matrixWorldInverse.getInverse(Ct.matrixWorld)}var l=t.context,d=null,p=null,_=1,T=null,A="stage",L=null,B=[],H=[],q=new _e;q.layers.enable(1),q.viewport=new v;var $=new _e;$.layers.enable(2),$.viewport=new v;var rt=new Fe([q,$]);rt.layers.enable(1),rt.layers.enable(2),this.enabled=!1,this.getController=function(Ct){var wt=B[Ct];return wt===void 0&&(wt=new ci,wt.matrixAutoUpdate=!1,wt.visible=!1,B[Ct]=wt),wt},this.getDevice=function(){return d},this.setDevice=function(Ct){Ct!==void 0&&(d=Ct),Ct instanceof XRDevice&&l.setCompatibleXRDevice(Ct)},this.setFramebufferScaleFactor=function(Ct){_=Ct},this.setFrameOfReferenceType=function(Ct){A=Ct},this.setSession=function(Ct){p=Ct,p!==null&&(p.addEventListener("select",i),p.addEventListener("selectstart",i),p.addEventListener("selectend",i),p.addEventListener("end",n),p.baseLayer=new XRWebGLLayer(p,l,{framebufferScaleFactor:_}),p.requestFrameOfReference(A).then(function(wt){T=wt,t.setFramebuffer(p.baseLayer.framebuffer),gt.setContext(p),gt.start()}),H=p.getInputSources(),p.addEventListener("inputsourceschange",function(){H=p.getInputSources();for(var wt=0;wt<B.length;wt++)B[wt].userData.inputSource=H[wt]}))},this.getCamera=function(Ct){if(e()){var wt=Ct.parent,Vt=rt.cameras;s(rt,wt);for(var K=0;K<Vt.length;K++)s(Vt[K],wt);for(Ct.matrixWorld.copy(rt.matrixWorld),Ct=Ct.children,K=0,wt=Ct.length;K<wt;K++)Ct[K].updateMatrixWorld(!0);return fe(rt,q,$),rt}return Ct},this.isPresenting=e;var xt=null,gt=new w;gt.setAnimationLoop(function(Ct,wt){if(L=wt.getDevicePose(T),L!==null)for(var Vt=p.baseLayer,K=wt.views,ot=0;ot<K.length;ot++){var kt=K[ot],ee=Vt.getViewport(kt),$t=L.getViewMatrix(kt),Yt=rt.cameras[ot];Yt.matrix.fromArray($t).getInverse(Yt.matrix),Yt.projectionMatrix.fromArray(kt.projectionMatrix),Yt.viewport.set(ee.x,ee.y,ee.width,ee.height),ot===0&&rt.matrix.copy(Yt.matrix)}for(ot=0;ot<B.length;ot++){if(Vt=B[ot],(K=H[ot])&&(K=wt.getInputPose(K,T),K!==null)){"targetRay"in K?Vt.matrix.elements=K.targetRay.transformMatrix:"pointerMatrix"in K&&(Vt.matrix.elements=K.pointerMatrix),Vt.matrix.decompose(Vt.position,Vt.rotation,Vt.scale),Vt.visible=!0;continue}Vt.visible=!1}xt&&xt(Ct)}),this.setAnimationLoop=function(Ct){xt=Ct},this.dispose=function(){},this.getStandingMatrix=function(){return new THREE.Matrix4},this.submitFrame=function(){}}function xe(t){var e;function i(){ii=new Jt(ne),Je=new Qi(ne,ii,t),Je.isWebGL2||(ii.get("WEBGL_depth_texture"),ii.get("OES_texture_float"),ii.get("OES_texture_half_float"),ii.get("OES_texture_half_float_linear"),ii.get("OES_standard_derivatives"),ii.get("OES_element_index_uint"),ii.get("ANGLE_instanced_arrays")),ii.get("OES_texture_float_linear"),In=new He(ne,ii,Je),li=new ue(ne,ii,In,Je),li.scissor(qi.copy(Ye).multiplyScalar(ti)),li.viewport(_n.copy(Ht).multiplyScalar(ti)),xn=new pt,Pn=new at,No=new je(ne,ii,li,Pn,Je,In,xn),Ia=new M(ne),Kh=new jt(ne,Ia,xn),Da=new Kt(Kh,xn),Qh=new ie(ne),Hs=new lt(Yt,ii,Je),El=new Ot,Vs=new he,us=new Di(Yt,li,Da,K),tu=new mn(ne,ii,xn,Je),er=new dt(ne,ii,xn,Je),xn.programs=Hs.programs,Yt.context=ne,Yt.capabilities=Je,Yt.extensions=ii,Yt.properties=Pn,Yt.renderLists=El,Yt.state=li,Yt.info=xn}function n(ft){ft.preventDefault(),Te=!0}function s(){Te=!1,i()}function l(ft){ft=ft.target,ft.removeEventListener("dispose",l),d(ft),Pn.remove(ft)}function d(ft){var Tt=Pn.get(ft).program;ft.program=void 0,Tt!==void 0&&Hs.releaseProgram(Tt)}function p(ft,Tt){ft.render(function(mt){Yt.renderBufferImmediate(mt,Tt)})}function _(ft,Tt,mt){if(ft.visible!==!1){if(ft.layers.test(Tt.layers)){if(ft.isLight)$t.pushLight(ft),ft.castShadow&&$t.pushShadow(ft);else if(ft.isSprite){if(!ft.frustumCulled||Wi.intersectsSprite(ft)){mt&&Ai.setFromMatrixPosition(ft.matrixWorld).applyMatrix4(Li);var Me=Da.update(ft),ze=ft.material;ee.push(ft,Me,ze,Ai.z,null)}}else if(ft.isImmediateRenderObject)mt&&Ai.setFromMatrixPosition(ft.matrixWorld).applyMatrix4(Li),ee.push(ft,null,ft.material,Ai.z,null);else if((ft.isMesh||ft.isLine||ft.isPoints)&&(ft.isSkinnedMesh&&ft.skeleton.update(),!ft.frustumCulled||Wi.intersectsObject(ft)))if(mt&&Ai.setFromMatrixPosition(ft.matrixWorld).applyMatrix4(Li),Me=Da.update(ft),ze=ft.material,Array.isArray(ze))for(var Ve=Me.groups,Se=0,Ke=Ve.length;Se<Ke;Se++){var Oi=Ve[Se],$i=ze[Oi.materialIndex];$i&&$i.visible&&ee.push(ft,Me,$i,Ai.z,Oi)}else ze.visible&&ee.push(ft,Me,ze,Ai.z,null)}for(ft=ft.children,Se=0,Ke=ft.length;Se<Ke;Se++)_(ft[Se],Tt,mt)}}function T(ft,Tt,mt,Me){for(var ze=0,Ve=ft.length;ze<Ve;ze++){var Se=ft[ze],Ke=Se.object,Oi=Se.geometry,$i=Me===void 0?Se.material:Me;if(Se=Se.group,mt.isArrayCamera){Cn=mt;for(var ve=mt.cameras,Tr=0,Nn=ve.length;Tr<Nn;Tr++){var an=ve[Tr];if(Ke.layers.test(an.layers)){if("viewport"in an)li.viewport(_n.copy(an.viewport));else{var pr=an.bounds;li.viewport(_n.set(pr.x*An,pr.y*Ce,pr.z*An,pr.w*Ce).multiplyScalar(ti))}$t.setupLights(an),A(Ke,Tt,an,Oi,$i,Se)}}}else Cn=null,A(Ke,Tt,mt,Oi,$i,Se)}}function A(ft,Tt,mt,Me,ze,Ve){if(ft.onBeforeRender(Yt,Tt,mt,Me,ze,Ve),$t=Vs.get(Tt,Cn||mt),ft.modelViewMatrix.multiplyMatrices(mt.matrixWorldInverse,ft.matrixWorld),ft.normalMatrix.getNormalMatrix(ft.modelViewMatrix),ft.isImmediateRenderObject){li.setMaterial(ze);var Se=B(mt,Tt.fog,ze,ft);We=e=null,Qe=!1,p(ft,Se)}else Yt.renderBufferDirect(mt,Tt.fog,Me,ze,ft,Ve);ft.onAfterRender(Yt,Tt,mt,Me,ze,Ve),$t=Vs.get(Tt,Cn||mt)}function L(ft,Tt,mt){var Me=Pn.get(ft),ze=$t.state.lights,Ve=Me.lightsHash,Se=ze.state.hash;mt=Hs.getParameters(ft,ze.state,$t.state.shadowsArray,Tt,Ae.numPlanes,Ae.numIntersection,mt);var Ke=Hs.getProgramCode(ft,mt),Oi=Me.program,$i=!0;if(Oi===void 0)ft.addEventListener("dispose",l);else if(Oi.code!==Ke)d(ft);else{if(Ve.stateID!==Se.stateID||Ve.directionalLength!==Se.directionalLength||Ve.pointLength!==Se.pointLength||Ve.spotLength!==Se.spotLength||Ve.rectAreaLength!==Se.rectAreaLength||Ve.hemiLength!==Se.hemiLength||Ve.shadowsLength!==Se.shadowsLength)Ve.stateID=Se.stateID,Ve.directionalLength=Se.directionalLength,Ve.pointLength=Se.pointLength,Ve.spotLength=Se.spotLength,Ve.rectAreaLength=Se.rectAreaLength,Ve.hemiLength=Se.hemiLength,Ve.shadowsLength=Se.shadowsLength;else if(mt.shaderID!==void 0)return;$i=!1}if($i&&(mt.shaderID?(Ke=wo[mt.shaderID],Me.shader={name:ft.type,uniforms:Bn.clone(Ke.uniforms),vertexShader:Ke.vertexShader,fragmentShader:Ke.fragmentShader}):Me.shader={name:ft.type,uniforms:ft.uniforms,vertexShader:ft.vertexShader,fragmentShader:ft.fragmentShader},ft.onBeforeCompile(Me.shader,Yt),Ke=Hs.getProgramCode(ft,mt),Oi=Hs.acquireProgram(ft,Me.shader,mt,Ke),Me.program=Oi,ft.program=Oi),mt=Oi.getAttributes(),ft.morphTargets)for(Ke=ft.numSupportedMorphTargets=0;Ke<Yt.maxMorphTargets;Ke++)0<=mt["morphTarget"+Ke]&&ft.numSupportedMorphTargets++;if(ft.morphNormals)for(Ke=ft.numSupportedMorphNormals=0;Ke<Yt.maxMorphNormals;Ke++)0<=mt["morphNormal"+Ke]&&ft.numSupportedMorphNormals++;mt=Me.shader.uniforms,(!ft.isShaderMaterial&&!ft.isRawShaderMaterial||ft.clipping===!0)&&(Me.numClippingPlanes=Ae.numPlanes,Me.numIntersection=Ae.numIntersection,mt.clippingPlanes=Ae.uniform),Me.fog=Tt,Ve===void 0&&(Me.lightsHash=Ve={}),Ve.stateID=Se.stateID,Ve.directionalLength=Se.directionalLength,Ve.pointLength=Se.pointLength,Ve.spotLength=Se.spotLength,Ve.rectAreaLength=Se.rectAreaLength,Ve.hemiLength=Se.hemiLength,Ve.shadowsLength=Se.shadowsLength,ft.lights&&(mt.ambientLightColor.value=ze.state.ambient,mt.directionalLights.value=ze.state.directional,mt.spotLights.value=ze.state.spot,mt.rectAreaLights.value=ze.state.rectArea,mt.pointLights.value=ze.state.point,mt.hemisphereLights.value=ze.state.hemi,mt.directionalShadowMap.value=ze.state.directionalShadowMap,mt.directionalShadowMatrix.value=ze.state.directionalShadowMatrix,mt.spotShadowMap.value=ze.state.spotShadowMap,mt.spotShadowMatrix.value=ze.state.spotShadowMatrix,mt.pointShadowMap.value=ze.state.pointShadowMap,mt.pointShadowMatrix.value=ze.state.pointShadowMatrix),ft=Me.program.getUniforms(),ft=ho.seqWithValue(ft.seq,mt),Me.uniformsList=ft}function B(ft,Tt,mt,Me){on=0;var ze=Pn.get(mt),Ve=ze.lightsHash,Se=$t.state.lights.state.hash;Xe&&(ri||ft!==fi)&&Ae.setState(mt.clippingPlanes,mt.clipIntersection,mt.clipShadows,ft,ze,ft===fi&&mt.id===ae),mt.needsUpdate===!1&&(ze.program===void 0||mt.fog&&ze.fog!==Tt?mt.needsUpdate=!0:(!mt.lights||Ve.stateID===Se.stateID&&Ve.directionalLength===Se.directionalLength&&Ve.pointLength===Se.pointLength&&Ve.spotLength===Se.spotLength&&Ve.rectAreaLength===Se.rectAreaLength&&Ve.hemiLength===Se.hemiLength&&Ve.shadowsLength===Se.shadowsLength)&&(ze.numClippingPlanes===void 0||ze.numClippingPlanes===Ae.numPlanes&&ze.numIntersection===Ae.numIntersection)||(mt.needsUpdate=!0)),mt.needsUpdate&&(L(mt,Tt,Me),mt.needsUpdate=!1);var Ke=!1,Oi=!1,$i=!1;Ve=ze.program,Se=Ve.getUniforms();var ve=ze.shader.uniforms;if(li.useProgram(Ve.program)&&($i=Oi=Ke=!0),mt.id!==ae&&(ae=mt.id,Oi=!0),(Ke||fi!==ft)&&(Se.setValue(ne,"projectionMatrix",ft.projectionMatrix),Je.logarithmicDepthBuffer&&Se.setValue(ne,"logDepthBufFC",2/(Math.log(ft.far+1)/Math.LN2)),fi!==ft&&(fi=ft,$i=Oi=!0),(mt.isShaderMaterial||mt.isMeshPhongMaterial||mt.isMeshStandardMaterial||mt.envMap)&&(Ke=Se.map.cameraPosition,Ke!==void 0&&Ke.setValue(ne,Ai.setFromMatrixPosition(ft.matrixWorld))),(mt.isMeshPhongMaterial||mt.isMeshLambertMaterial||mt.isMeshBasicMaterial||mt.isMeshStandardMaterial||mt.isShaderMaterial||mt.skinning)&&Se.setValue(ne,"viewMatrix",ft.matrixWorldInverse)),mt.skinning&&(Se.setOptional(ne,Me,"bindMatrix"),Se.setOptional(ne,Me,"bindMatrixInverse"),ft=Me.skeleton))if(Ke=ft.bones,Je.floatVertexTextures){if(ft.boneTexture===void 0){Ke=Math.sqrt(4*Ke.length),Ke=di.ceilPowerOfTwo(Ke),Ke=Math.max(Ke,4);var Tr=new Float32Array(Ke*Ke*4);Tr.set(ft.boneMatrices);var Nn=new O(Tr,Ke,Ke,1023,1015);Nn.needsUpdate=!0,ft.boneMatrices=Tr,ft.boneTexture=Nn,ft.boneTextureSize=Ke}Se.setValue(ne,"boneTexture",ft.boneTexture),Se.setValue(ne,"boneTextureSize",ft.boneTextureSize)}else Se.setOptional(ne,ft,"boneMatrices");return Oi&&(Se.setValue(ne,"toneMappingExposure",Yt.toneMappingExposure),Se.setValue(ne,"toneMappingWhitePoint",Yt.toneMappingWhitePoint),mt.lights&&(Oi=$i,ve.ambientLightColor.needsUpdate=Oi,ve.directionalLights.needsUpdate=Oi,ve.pointLights.needsUpdate=Oi,ve.spotLights.needsUpdate=Oi,ve.rectAreaLights.needsUpdate=Oi,ve.hemisphereLights.needsUpdate=Oi),Tt&&mt.fog&&(ve.fogColor.value=Tt.color,Tt.isFog?(ve.fogNear.value=Tt.near,ve.fogFar.value=Tt.far):Tt.isFogExp2&&(ve.fogDensity.value=Tt.density)),mt.isMeshBasicMaterial?H(ve,mt):mt.isMeshLambertMaterial?(H(ve,mt),mt.emissiveMap&&(ve.emissiveMap.value=mt.emissiveMap)):mt.isMeshPhongMaterial?(H(ve,mt),mt.isMeshToonMaterial?(q(ve,mt),mt.gradientMap&&(ve.gradientMap.value=mt.gradientMap)):q(ve,mt)):mt.isMeshStandardMaterial?(H(ve,mt),mt.isMeshPhysicalMaterial?($(ve,mt),ve.reflectivity.value=mt.reflectivity,ve.clearCoat.value=mt.clearCoat,ve.clearCoatRoughness.value=mt.clearCoatRoughness):$(ve,mt)):mt.isMeshMatcapMaterial?(H(ve,mt),mt.matcap&&(ve.matcap.value=mt.matcap),mt.bumpMap&&(ve.bumpMap.value=mt.bumpMap,ve.bumpScale.value=mt.bumpScale,mt.side===1&&(ve.bumpScale.value*=-1)),mt.normalMap&&(ve.normalMap.value=mt.normalMap,ve.normalScale.value.copy(mt.normalScale),mt.side===1&&ve.normalScale.value.negate()),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias)):mt.isMeshDepthMaterial?(H(ve,mt),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias)):mt.isMeshDistanceMaterial?(H(ve,mt),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias),ve.referencePosition.value.copy(mt.referencePosition),ve.nearDistance.value=mt.nearDistance,ve.farDistance.value=mt.farDistance):mt.isMeshNormalMaterial?(H(ve,mt),mt.bumpMap&&(ve.bumpMap.value=mt.bumpMap,ve.bumpScale.value=mt.bumpScale,mt.side===1&&(ve.bumpScale.value*=-1)),mt.normalMap&&(ve.normalMap.value=mt.normalMap,ve.normalScale.value.copy(mt.normalScale),mt.side===1&&ve.normalScale.value.negate()),mt.displacementMap&&(ve.displacementMap.value=mt.displacementMap,ve.displacementScale.value=mt.displacementScale,ve.displacementBias.value=mt.displacementBias)):mt.isLineBasicMaterial?(ve.diffuse.value=mt.color,ve.opacity.value=mt.opacity,mt.isLineDashedMaterial&&(ve.dashSize.value=mt.dashSize,ve.totalSize.value=mt.dashSize+mt.gapSize,ve.scale.value=mt.scale)):mt.isPointsMaterial?(ve.diffuse.value=mt.color,ve.opacity.value=mt.opacity,ve.size.value=mt.size*ti,ve.scale.value=.5*Ce,ve.map.value=mt.map,mt.map!==null&&(mt.map.matrixAutoUpdate===!0&&mt.map.updateMatrix(),ve.uvTransform.value.copy(mt.map.matrix))):mt.isSpriteMaterial?(ve.diffuse.value=mt.color,ve.opacity.value=mt.opacity,ve.rotation.value=mt.rotation,ve.map.value=mt.map,mt.map!==null&&(mt.map.matrixAutoUpdate===!0&&mt.map.updateMatrix(),ve.uvTransform.value.copy(mt.map.matrix))):mt.isShadowMaterial&&(ve.color.value=mt.color,ve.opacity.value=mt.opacity),ve.ltc_1!==void 0&&(ve.ltc_1.value=qe.LTC_1),ve.ltc_2!==void 0&&(ve.ltc_2.value=qe.LTC_2),ho.upload(ne,ze.uniformsList,ve,Yt)),mt.isShaderMaterial&&mt.uniformsNeedUpdate===!0&&(ho.upload(ne,ze.uniformsList,ve,Yt),mt.uniformsNeedUpdate=!1),mt.isSpriteMaterial&&Se.setValue(ne,"center",Me.center),Se.setValue(ne,"modelViewMatrix",Me.modelViewMatrix),Se.setValue(ne,"normalMatrix",Me.normalMatrix),Se.setValue(ne,"modelMatrix",Me.matrixWorld),Ve}function H(ft,Tt){if(ft.opacity.value=Tt.opacity,Tt.color&&(ft.diffuse.value=Tt.color),Tt.emissive&&ft.emissive.value.copy(Tt.emissive).multiplyScalar(Tt.emissiveIntensity),Tt.map&&(ft.map.value=Tt.map),Tt.alphaMap&&(ft.alphaMap.value=Tt.alphaMap),Tt.specularMap&&(ft.specularMap.value=Tt.specularMap),Tt.envMap&&(ft.envMap.value=Tt.envMap,ft.flipEnvMap.value=Tt.envMap&&Tt.envMap.isCubeTexture?-1:1,ft.reflectivity.value=Tt.reflectivity,ft.refractionRatio.value=Tt.refractionRatio,ft.maxMipLevel.value=Pn.get(Tt.envMap).__maxMipLevel),Tt.lightMap&&(ft.lightMap.value=Tt.lightMap,ft.lightMapIntensity.value=Tt.lightMapIntensity),Tt.aoMap&&(ft.aoMap.value=Tt.aoMap,ft.aoMapIntensity.value=Tt.aoMapIntensity),Tt.map)var mt=Tt.map;else Tt.specularMap?mt=Tt.specularMap:Tt.displacementMap?mt=Tt.displacementMap:Tt.normalMap?mt=Tt.normalMap:Tt.bumpMap?mt=Tt.bumpMap:Tt.roughnessMap?mt=Tt.roughnessMap:Tt.metalnessMap?mt=Tt.metalnessMap:Tt.alphaMap?mt=Tt.alphaMap:Tt.emissiveMap&&(mt=Tt.emissiveMap);mt!==void 0&&(mt.isWebGLRenderTarget&&(mt=mt.texture),mt.matrixAutoUpdate===!0&&mt.updateMatrix(),ft.uvTransform.value.copy(mt.matrix))}function q(ft,Tt){ft.specular.value=Tt.specular,ft.shininess.value=Math.max(Tt.shininess,1e-4),Tt.emissiveMap&&(ft.emissiveMap.value=Tt.emissiveMap),Tt.bumpMap&&(ft.bumpMap.value=Tt.bumpMap,ft.bumpScale.value=Tt.bumpScale,Tt.side===1&&(ft.bumpScale.value*=-1)),Tt.normalMap&&(ft.normalMap.value=Tt.normalMap,ft.normalScale.value.copy(Tt.normalScale),Tt.side===1&&ft.normalScale.value.negate()),Tt.displacementMap&&(ft.displacementMap.value=Tt.displacementMap,ft.displacementScale.value=Tt.displacementScale,ft.displacementBias.value=Tt.displacementBias)}function $(ft,Tt){ft.roughness.value=Tt.roughness,ft.metalness.value=Tt.metalness,Tt.roughnessMap&&(ft.roughnessMap.value=Tt.roughnessMap),Tt.metalnessMap&&(ft.metalnessMap.value=Tt.metalnessMap),Tt.emissiveMap&&(ft.emissiveMap.value=Tt.emissiveMap),Tt.bumpMap&&(ft.bumpMap.value=Tt.bumpMap,ft.bumpScale.value=Tt.bumpScale,Tt.side===1&&(ft.bumpScale.value*=-1)),Tt.normalMap&&(ft.normalMap.value=Tt.normalMap,ft.normalScale.value.copy(Tt.normalScale),Tt.side===1&&ft.normalScale.value.negate()),Tt.displacementMap&&(ft.displacementMap.value=Tt.displacementMap,ft.displacementScale.value=Tt.displacementScale,ft.displacementBias.value=Tt.displacementBias),Tt.envMap&&(ft.envMapIntensity.value=Tt.envMapIntensity)}t=t||{};var rt=t.canvas!==void 0?t.canvas:document.createElementNS("http://www.w3.org/1999/xhtml","canvas"),xt=t.context!==void 0?t.context:null,gt=t.alpha!==void 0?t.alpha:!1,Ct=t.depth!==void 0?t.depth:!0,wt=t.stencil!==void 0?t.stencil:!0,Vt=t.antialias!==void 0?t.antialias:!1,K=t.premultipliedAlpha!==void 0?t.premultipliedAlpha:!0,ot=t.preserveDrawingBuffer!==void 0?t.preserveDrawingBuffer:!1,kt=t.powerPreference!==void 0?t.powerPreference:"default",ee=null,$t=null;this.domElement=rt,this.context=null,this.sortObjects=this.autoClearStencil=this.autoClearDepth=this.autoClearColor=this.autoClear=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.physicallyCorrectLights=this.gammaOutput=this.gammaInput=!1,this.toneMappingWhitePoint=this.toneMappingExposure=this.toneMapping=1,this.maxMorphTargets=8,this.maxMorphNormals=4;var Yt=this,Te=!1,ge=null,De=null,be=null,ae=-1,We=e=null,Qe=!1,fi=null,Cn=null,_n=new v,qi=new v,Vi=null,on=0,An=rt.width,Ce=rt.height,ti=1,Ht=new v(0,0,An,Ce),Ye=new v(0,0,An,Ce),ei=!1,Wi=new E,Ae=new W,Xe=!1,ri=!1,Li=new c,Ai=new u;try{gt={alpha:gt,depth:Ct,stencil:wt,antialias:Vt,premultipliedAlpha:K,preserveDrawingBuffer:ot,powerPreference:kt},rt.addEventListener("webglcontextlost",n,!1),rt.addEventListener("webglcontextrestored",s,!1);var ne=xt||rt.getContext("webgl",gt)||rt.getContext("experimental-webgl",gt);if(ne===null)throw rt.getContext("webgl")!==null?Error("Error creating WebGL context with your selected attributes."):Error("Error creating WebGL context.");ne.getShaderPrecisionFormat===void 0&&(ne.getShaderPrecisionFormat=function(){return{rangeMin:1,rangeMax:1,precision:1}})}catch{}var ii,Je,li,xn,Pn,No,Ia,Kh,Da,Hs,El,Vs,us,Qh,tu,er,In;i();var So=null;typeof navigator<"u"&&(So="xr"in navigator?new Le(Yt):new mi(Yt)),this.vr=So;var Gu=new ye(Yt,Da,Je.maxTextureSize);this.shadowMap=Gu,this.getContext=function(){return ne},this.getContextAttributes=function(){return ne.getContextAttributes()},this.forceContextLoss=function(){var ft=ii.get("WEBGL_lose_context");ft&&ft.loseContext()},this.forceContextRestore=function(){var ft=ii.get("WEBGL_lose_context");ft&&ft.restoreContext()},this.getPixelRatio=function(){return ti},this.setPixelRatio=function(ft){ft!==void 0&&(ti=ft,this.setSize(An,Ce,!1))},this.getSize=function(){return{width:An,height:Ce}},this.setSize=function(ft,Tt,mt){So.isPresenting()||(An=ft,Ce=Tt,rt.width=ft*ti,rt.height=Tt*ti,mt!==!1&&(rt.style.width=ft+"px",rt.style.height=Tt+"px"),this.setViewport(0,0,ft,Tt))},this.getDrawingBufferSize=function(){return{width:An*ti,height:Ce*ti}},this.setDrawingBufferSize=function(ft,Tt,mt){An=ft,Ce=Tt,ti=mt,rt.width=ft*mt,rt.height=Tt*mt,this.setViewport(0,0,ft,Tt)},this.getCurrentViewport=function(){return _n},this.setViewport=function(ft,Tt,mt,Me){Ht.set(ft,Ce-Tt-Me,mt,Me),li.viewport(_n.copy(Ht).multiplyScalar(ti))},this.setScissor=function(ft,Tt,mt,Me){Ye.set(ft,Ce-Tt-Me,mt,Me),li.scissor(qi.copy(Ye).multiplyScalar(ti))},this.setScissorTest=function(ft){li.setScissorTest(ei=ft)},this.getClearColor=function(){return us.getClearColor()},this.setClearColor=function(){us.setClearColor.apply(us,arguments)},this.getClearAlpha=function(){return us.getClearAlpha()},this.setClearAlpha=function(){us.setClearAlpha.apply(us,arguments)},this.clear=function(ft,Tt,mt){var Me=0;(ft===void 0||ft)&&(Me|=16384),(Tt===void 0||Tt)&&(Me|=256),(mt===void 0||mt)&&(Me|=1024),ne.clear(Me)},this.clearColor=function(){this.clear(!0,!1,!1)},this.clearDepth=function(){this.clear(!1,!0,!1)},this.clearStencil=function(){this.clear(!1,!1,!0)},this.dispose=function(){rt.removeEventListener("webglcontextlost",n,!1),rt.removeEventListener("webglcontextrestored",s,!1),El.dispose(),Vs.dispose(),Pn.dispose(),Da.dispose(),So.dispose(),Fo.stop()},this.renderBufferImmediate=function(ft,Tt){li.initAttributes();var mt=Pn.get(ft);ft.hasPositions&&!mt.position&&(mt.position=ne.createBuffer()),ft.hasNormals&&!mt.normal&&(mt.normal=ne.createBuffer()),ft.hasUvs&&!mt.uv&&(mt.uv=ne.createBuffer()),ft.hasColors&&!mt.color&&(mt.color=ne.createBuffer()),Tt=Tt.getAttributes(),ft.hasPositions&&(ne.bindBuffer(34962,mt.position),ne.bufferData(34962,ft.positionArray,35048),li.enableAttribute(Tt.position),ne.vertexAttribPointer(Tt.position,3,5126,!1,0,0)),ft.hasNormals&&(ne.bindBuffer(34962,mt.normal),ne.bufferData(34962,ft.normalArray,35048),li.enableAttribute(Tt.normal),ne.vertexAttribPointer(Tt.normal,3,5126,!1,0,0)),ft.hasUvs&&(ne.bindBuffer(34962,mt.uv),ne.bufferData(34962,ft.uvArray,35048),li.enableAttribute(Tt.uv),ne.vertexAttribPointer(Tt.uv,2,5126,!1,0,0)),ft.hasColors&&(ne.bindBuffer(34962,mt.color),ne.bufferData(34962,ft.colorArray,35048),li.enableAttribute(Tt.color),ne.vertexAttribPointer(Tt.color,3,5126,!1,0,0)),li.disableUnusedAttributes(),ne.drawArrays(4,0,ft.count),ft.count=0},this.renderBufferDirect=function(ft,Tt,mt,Me,ze,Ve){var Se=ze.isMesh&&0>ze.normalMatrix.determinant();li.setMaterial(Me,Se);var Ke=B(ft,Tt,Me,ze),Oi=!1;(e!==mt.id||We!==Ke.id||Qe!==(Me.wireframe===!0))&&(e=mt.id,We=Ke.id,Qe=Me.wireframe===!0,Oi=!0),ze.morphTargetInfluences&&(Qh.update(ze,mt,Me,Ke),Oi=!0),Se=mt.index;var $i=mt.attributes.position;if(Tt=1,Me.wireframe===!0&&(Se=Kh.getWireframeAttribute(mt),Tt=2),ft=tu,Se!==null){var ve=Ia.get(Se);ft=er,ft.setIndex(ve)}if(Oi){if(!(mt&&mt.isInstancedBufferGeometry&!Je.isWebGL2&&ii.get("ANGLE_instanced_arrays")===null)){li.initAttributes(),Oi=mt.attributes,Ke=Ke.getAttributes();var Tr=Me.defaultAttributeValues;for(ir in Ke){var Nn=Ke[ir];if(0<=Nn){var an=Oi[ir];if(an!==void 0){var pr=an.normalized,eu=an.itemSize,Eo=Ia.get(an);if(Eo!==void 0){var iu=Eo.buffer,dh=Eo.type;if(Eo=Eo.bytesPerElement,an.isInterleavedBufferAttribute){var ka=an.data,Hu=ka.stride;an=an.offset,ka&&ka.isInstancedInterleavedBuffer?(li.enableAttributeAndDivisor(Nn,ka.meshPerAttribute),mt.maxInstancedCount===void 0&&(mt.maxInstancedCount=ka.meshPerAttribute*ka.count)):li.enableAttribute(Nn),ne.bindBuffer(34962,iu),ne.vertexAttribPointer(Nn,eu,dh,pr,Hu*Eo,an*Eo)}else an.isInstancedBufferAttribute?(li.enableAttributeAndDivisor(Nn,an.meshPerAttribute),mt.maxInstancedCount===void 0&&(mt.maxInstancedCount=an.meshPerAttribute*an.count)):li.enableAttribute(Nn),ne.bindBuffer(34962,iu),ne.vertexAttribPointer(Nn,eu,dh,pr,0,0)}}else if(Tr!==void 0&&(pr=Tr[ir],pr!==void 0))switch(pr.length){case 2:ne.vertexAttrib2fv(Nn,pr);break;case 3:ne.vertexAttrib3fv(Nn,pr);break;case 4:ne.vertexAttrib4fv(Nn,pr);break;default:ne.vertexAttrib1fv(Nn,pr)}}}li.disableUnusedAttributes()}Se!==null&&ne.bindBuffer(34963,ve.buffer)}ve=1/0,Se!==null?ve=Se.count:$i!==void 0&&(ve=$i.count),Se=mt.drawRange.start*Tt,$i=Ve!==null?Ve.start*Tt:0;var ir=Math.max(Se,$i);if(Ve=Math.max(0,Math.min(ve,Se+mt.drawRange.count*Tt,$i+(Ve!==null?Ve.count*Tt:1/0))-1-ir+1),Ve!==0){if(ze.isMesh)if(Me.wireframe===!0)li.setLineWidth(Me.wireframeLinewidth*(De===null?ti:1)),ft.setMode(1);else switch(ze.drawMode){case 0:ft.setMode(4);break;case 1:ft.setMode(5);break;case 2:ft.setMode(6)}else ze.isLine?(Me=Me.linewidth,Me===void 0&&(Me=1),li.setLineWidth(Me*(De===null?ti:1)),ze.isLineSegments?ft.setMode(1):ze.isLineLoop?ft.setMode(2):ft.setMode(3)):ze.isPoints?ft.setMode(0):ze.isSprite&&ft.setMode(4);mt&&mt.isInstancedBufferGeometry?0<mt.maxInstancedCount&&ft.renderInstances(mt,ir,Ve):ft.render(ir,Ve)}},this.compile=function(ft,Tt){$t=Vs.get(ft,Tt),$t.init(),ft.traverse(function(mt){mt.isLight&&($t.pushLight(mt),mt.castShadow&&$t.pushShadow(mt))}),$t.setupLights(Tt),ft.traverse(function(mt){if(mt.material)if(Array.isArray(mt.material))for(var Me=0;Me<mt.material.length;Me++)L(mt.material[Me],ft.fog,mt);else L(mt.material,ft.fog,mt)})};var za=null,Fo=new w;Fo.setAnimationLoop(function(ft){So.isPresenting()||za&&za(ft)}),typeof window<"u"&&Fo.setContext(window),this.setAnimationLoop=function(ft){za=ft,So.setAnimationLoop(ft),Fo.start()},this.render=function(ft,Tt,mt,Me){if(!(!Tt||!Tt.isCamera)){if(!Te){We=e=null,Qe=!1,ae=-1,fi=null,ft.autoUpdate===!0&&ft.updateMatrixWorld(),Tt.parent===null&&Tt.updateMatrixWorld(),So.enabled&&(Tt=So.getCamera(Tt)),$t=Vs.get(ft,Tt),$t.init(),ft.onBeforeRender(Yt,ft,Tt,mt),Li.multiplyMatrices(Tt.projectionMatrix,Tt.matrixWorldInverse),Wi.setFromMatrix(Li),ri=this.localClippingEnabled,Xe=Ae.init(this.clippingPlanes,ri,Tt),ee=El.get(ft,Tt),ee.init(),_(ft,Tt,Yt.sortObjects),Yt.sortObjects===!0&&ee.sort(),Xe&&Ae.beginShadows(),Gu.render($t.state.shadowsArray,ft,Tt),$t.setupLights(Tt),Xe&&Ae.endShadows(),this.info.autoReset&&this.info.reset(),mt===void 0&&(mt=null),this.setRenderTarget(mt),us.render(ee,ft,Tt,Me),Me=ee.opaque;var ze=ee.transparent;if(ft.overrideMaterial){var Ve=ft.overrideMaterial;Me.length&&T(Me,ft,Tt,Ve),ze.length&&T(ze,ft,Tt,Ve)}else Me.length&&T(Me,ft,Tt),ze.length&&T(ze,ft,Tt);mt&&No.updateRenderTargetMipmap(mt),li.buffers.depth.setTest(!0),li.buffers.depth.setMask(!0),li.buffers.color.setMask(!0),li.setPolygonOffset(!1),ft.onAfterRender(Yt,ft,Tt),So.enabled&&So.submitFrame(),$t=ee=null}}},this.allocTextureUnit=function(){var ft=on;return ft>=Je.maxTextures,on+=1,ft},this.setTexture2D=function(){var ft=!1;return function(Tt,mt){Tt&&Tt.isWebGLRenderTarget&&(ft||(ft=!0),Tt=Tt.texture),No.setTexture2D(Tt,mt)}}(),this.setTexture3D=function(){return function(ft,Tt){No.setTexture3D(ft,Tt)}}(),this.setTexture=function(){var ft=!1;return function(Tt,mt){ft||(ft=!0),No.setTexture2D(Tt,mt)}}(),this.setTextureCube=function(){var ft=!1;return function(Tt,mt){Tt&&Tt.isWebGLRenderTargetCube&&(ft||(ft=!0),Tt=Tt.texture),Tt&&Tt.isCubeTexture||Array.isArray(Tt.image)&&Tt.image.length===6?No.setTextureCube(Tt,mt):No.setTextureCubeDynamic(Tt,mt)}}(),this.setFramebuffer=function(ft){ge=ft},this.getRenderTarget=function(){return De},this.setRenderTarget=function(ft){(De=ft)&&Pn.get(ft).__webglFramebuffer===void 0&&No.setupRenderTarget(ft);var Tt=ge,mt=!1;ft?(Tt=Pn.get(ft).__webglFramebuffer,ft.isWebGLRenderTargetCube&&(Tt=Tt[ft.activeCubeFace],mt=!0),_n.copy(ft.viewport),qi.copy(ft.scissor),Vi=ft.scissorTest):(_n.copy(Ht).multiplyScalar(ti),qi.copy(Ye).multiplyScalar(ti),Vi=ei),be!==Tt&&(ne.bindFramebuffer(36160,Tt),be=Tt),li.viewport(_n),li.scissor(qi),li.setScissorTest(Vi),mt&&(mt=Pn.get(ft.texture),ne.framebufferTexture2D(36160,36064,34069+ft.activeCubeFace,mt.__webglTexture,ft.activeMipMapLevel))},this.readRenderTargetPixels=function(ft,Tt,mt,Me,ze,Ve){if(ft&&ft.isWebGLRenderTarget){var Se=Pn.get(ft).__webglFramebuffer;if(Se){var Ke=!1;Se!==be&&(ne.bindFramebuffer(36160,Se),Ke=!0);try{var Oi=ft.texture,$i=Oi.format,ve=Oi.type;$i!==1023&&In.convert($i)!==ne.getParameter(35739)||(ve===1009||In.convert(ve)===ne.getParameter(35738)||ve===1015&&(Je.isWebGL2||ii.get("OES_texture_float")||ii.get("WEBGL_color_buffer_float"))||ve===1016&&(Je.isWebGL2?ii.get("EXT_color_buffer_float"):ii.get("EXT_color_buffer_half_float")))&&ne.checkFramebufferStatus(36160)===36053&&0<=Tt&&Tt<=ft.width-Me&&0<=mt&&mt<=ft.height-ze&&ne.readPixels(Tt,mt,Me,ze,In.convert($i),In.convert(ve),Ve)}finally{Ke&&ne.bindFramebuffer(36160,be)}}}},this.copyFramebufferToTexture=function(ft,Tt,mt){var Me=Tt.image.width,ze=Tt.image.height,Ve=In.convert(Tt.format);this.setTexture2D(Tt,0),ne.copyTexImage2D(3553,mt||0,Ve,ft.x,ft.y,Me,ze,0)},this.copyTextureToTexture=function(ft,Tt,mt,Me){var ze=Tt.image.width,Ve=Tt.image.height,Se=In.convert(mt.format),Ke=In.convert(mt.type);this.setTexture2D(mt,0),Tt.isDataTexture?ne.texSubImage2D(3553,Me||0,ft.x,ft.y,ze,Ve,Se,Ke,Tt.image.data):ne.texSubImage2D(3553,Me||0,ft.x,ft.y,Se,Ke,Tt.image)}}function Re(t,e){this.name="",this.color=new P(t),this.density=e!==void 0?e:25e-5}function Sn(t,e,i){this.name="",this.color=new P(t),this.near=e!==void 0?e:1,this.far=i!==void 0?i:1e3}function Xn(){N.call(this),this.type="Scene",this.overrideMaterial=this.fog=this.background=null,this.autoUpdate=!0}function ki(t,e){this.array=t,this.stride=e,this.count=t!==void 0?t.length/e:0,this.dynamic=!1,this.updateRange={offset:0,count:-1},this.version=0}function Bi(t,e,i,n){this.data=t,this.itemSize=e,this.offset=i,this.normalized=n===!0}function Hi(t){Wt.call(this),this.type="SpriteMaterial",this.color=new P(16777215),this.map=null,this.rotation=0,this.sizeAttenuation=!0,this.lights=!1,this.transparent=!0,this.setValues(t)}function nn(t){if(N.call(this),this.type="Sprite",Oa===void 0){Oa=new Ft;var e=new Float32Array([-.5,-.5,0,0,0,.5,-.5,0,1,0,.5,.5,0,1,1,-.5,.5,0,0,1]);e=new ki(e,5),Oa.setIndex([0,1,2,0,2,3]),Oa.addAttribute("position",new Bi(e,3,0,!1)),Oa.addAttribute("uv",new Bi(e,2,3,!1))}this.geometry=Oa,this.material=t!==void 0?t:new Hi,this.center=new o(.5,.5)}function rn(){N.call(this),this.type="LOD",Object.defineProperties(this,{levels:{enumerable:!0,value:[]}})}function un(t,e){if(t=t||[],this.bones=t.slice(0),this.boneMatrices=new Float32Array(16*this.bones.length),e===void 0)this.calculateInverses();else if(this.bones.length===e.length)this.boneInverses=e.slice(0);else for(this.boneInverses=[],t=0,e=this.bones.length;t<e;t++)this.boneInverses.push(new c)}function cn(){N.call(this),this.type="Bone"}function Gi(t,e){pi.call(this,t,e),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new c,this.bindMatrixInverse=new c,t=this.initBones(),t=new un(t),this.bind(t,this.matrixWorld),this.normalizeSkinWeights()}function Ni(t){Wt.call(this),this.type="LineBasicMaterial",this.color=new P(16777215),this.linewidth=1,this.linejoin=this.linecap="round",this.lights=!1,this.setValues(t)}function ji(t,e,i){N.call(this),this.type="Line",this.geometry=t!==void 0?t:new Ft,this.material=e!==void 0?e:new Ni({color:16777215*Math.random()})}function gi(t,e){ji.call(this,t,e),this.type="LineSegments"}function co(t,e){ji.call(this,t,e),this.type="LineLoop"}function Fn(t){Wt.call(this),this.type="PointsMaterial",this.color=new P(16777215),this.map=null,this.size=1,this.sizeAttenuation=!0,this.lights=this.morphTargets=!1,this.setValues(t)}function ha(t,e){N.call(this),this.type="Points",this.geometry=t!==void 0?t:new Ft,this.material=e!==void 0?e:new Fn({color:16777215*Math.random()})}function zh(t,e,i,n,s,l,d,p,_){g.call(this,t,e,i,n,s,l,d,p,_),this.generateMipmaps=!1}function Zo(t,e,i,n,s,l,d,p,_,T,A,L){g.call(this,null,l,d,p,_,T,n,s,A,L),this.image={width:e,height:i},this.mipmaps=t,this.generateMipmaps=this.flipY=!1}function $a(t,e,i,n,s,l,d,p,_){g.call(this,t,e,i,n,s,l,d,p,_),this.needsUpdate=!0}function Ka(t,e,i,n,s,l,d,p,_,T){if(T=T!==void 0?T:1026,T!==1026&&T!==1027)throw Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");i===void 0&&T===1026&&(i=1012),i===void 0&&T===1027&&(i=1020),g.call(this,null,n,s,l,d,p,T,i,_),this.image={width:t,height:e},this.magFilter=d!==void 0?d:1003,this.minFilter=p!==void 0?p:1003,this.generateMipmaps=this.flipY=!1}function ua(t){Ft.call(this),this.type="WireframeGeometry";var e=[],i,n,s,l=[0,0],d={},p=["a","b","c"];if(t&&t.isGeometry){var _=t.faces,T=0;for(n=_.length;T<n;T++){var A=_[T];for(i=0;3>i;i++){var L=A[p[i]],B=A[p[(i+1)%3]];l[0]=Math.min(L,B),l[1]=Math.max(L,B),L=l[0]+","+l[1],d[L]===void 0&&(d[L]={index1:l[0],index2:l[1]})}}for(L in d)T=d[L],p=t.vertices[T.index1],e.push(p.x,p.y,p.z),p=t.vertices[T.index2],e.push(p.x,p.y,p.z)}else if(t&&t.isBufferGeometry)if(p=new u,t.index!==null){_=t.attributes.position,A=t.index;var H=t.groups;for(H.length===0&&(H=[{start:0,count:A.count,materialIndex:0}]),t=0,s=H.length;t<s;++t)for(T=H[t],i=T.start,n=T.count,T=i,n=i+n;T<n;T+=3)for(i=0;3>i;i++)L=A.getX(T+i),B=A.getX(T+(i+1)%3),l[0]=Math.min(L,B),l[1]=Math.max(L,B),L=l[0]+","+l[1],d[L]===void 0&&(d[L]={index1:l[0],index2:l[1]});for(L in d)T=d[L],p.fromBufferAttribute(_,T.index1),e.push(p.x,p.y,p.z),p.fromBufferAttribute(_,T.index2),e.push(p.x,p.y,p.z)}else for(_=t.attributes.position,T=0,n=_.count/3;T<n;T++)for(i=0;3>i;i++)d=3*T+i,p.fromBufferAttribute(_,d),e.push(p.x,p.y,p.z),d=3*T+(i+1)%3,p.fromBufferAttribute(_,d),e.push(p.x,p.y,p.z);this.addAttribute("position",new Et(e,3))}function Qa(t,e,i){X.call(this),this.type="ParametricGeometry",this.parameters={func:t,slices:e,stacks:i},this.fromBufferGeometry(new ca(t,e,i)),this.mergeVertices()}function ca(t,e,i){Ft.call(this),this.type="ParametricBufferGeometry",this.parameters={func:t,slices:e,stacks:i};var n=[],s=[],l=[],d=[],p=new u,_=new u,T=new u,A=new u,L=new u,B,H;3>t.length;var q=e+1;for(B=0;B<=i;B++){var $=B/i;for(H=0;H<=e;H++){var rt=H/e;t(rt,$,_),s.push(_.x,_.y,_.z),0<=rt-1e-5?(t(rt-1e-5,$,T),A.subVectors(_,T)):(t(rt+1e-5,$,T),A.subVectors(T,_)),0<=$-1e-5?(t(rt,$-1e-5,T),L.subVectors(_,T)):(t(rt,$+1e-5,T),L.subVectors(T,_)),p.crossVectors(A,L).normalize(),l.push(p.x,p.y,p.z),d.push(rt,$)}}for(B=0;B<i;B++)for(H=0;H<e;H++)t=B*q+H+1,p=(B+1)*q+H+1,_=(B+1)*q+H,n.push(B*q+H,t,_),n.push(t,p,_);this.setIndex(n),this.addAttribute("position",new Et(s,3)),this.addAttribute("normal",new Et(l,3)),this.addAttribute("uv",new Et(d,2))}function Xi(t,e,i,n){X.call(this),this.type="PolyhedronGeometry",this.parameters={vertices:t,indices:e,radius:i,detail:n},this.fromBufferGeometry(new xi(t,e,i,n)),this.mergeVertices()}function xi(t,e,i,n){function s(T){p.push(T.x,T.y,T.z)}function l(T,A){T*=3,A.x=t[T+0],A.y=t[T+1],A.z=t[T+2]}function d(T,A,L,B){0>B&&T.x===1&&(_[A]=T.x-1),L.x===0&&L.z===0&&(_[A]=B/2/Math.PI+.5)}Ft.call(this),this.type="PolyhedronBufferGeometry",this.parameters={vertices:t,indices:e,radius:i,detail:n},i=i||1,n=n||0;var p=[],_=[];(function(T){for(var A=new u,L=new u,B=new u,H=0;H<e.length;H+=3){l(e[H+0],A),l(e[H+1],L),l(e[H+2],B);var q,$,rt=A,xt=L,gt=B,Ct=Math.pow(2,T),wt=[];for($=0;$<=Ct;$++){wt[$]=[];var Vt=rt.clone().lerp(gt,$/Ct),K=xt.clone().lerp(gt,$/Ct),ot=Ct-$;for(q=0;q<=ot;q++)wt[$][q]=q===0&&$===Ct?Vt:Vt.clone().lerp(K,q/ot)}for($=0;$<Ct;$++)for(q=0;q<2*(Ct-$)-1;q++)rt=Math.floor(q/2),q%2===0?(s(wt[$][rt+1]),s(wt[$+1][rt]),s(wt[$][rt])):(s(wt[$][rt+1]),s(wt[$+1][rt+1]),s(wt[$+1][rt]))}})(n),function(T){for(var A=new u,L=0;L<p.length;L+=3)A.x=p[L+0],A.y=p[L+1],A.z=p[L+2],A.normalize().multiplyScalar(T),p[L+0]=A.x,p[L+1]=A.y,p[L+2]=A.z}(i),function(){for(var T=new u,A=0;A<p.length;A+=3)T.x=p[A+0],T.y=p[A+1],T.z=p[A+2],_.push(Math.atan2(T.z,-T.x)/2/Math.PI+.5,1-(Math.atan2(-T.y,Math.sqrt(T.x*T.x+T.z*T.z))/Math.PI+.5));T=new u,A=new u;for(var L=new u,B=new u,H=new o,q=new o,$=new o,rt=0,xt=0;rt<p.length;rt+=9,xt+=6){T.set(p[rt+0],p[rt+1],p[rt+2]),A.set(p[rt+3],p[rt+4],p[rt+5]),L.set(p[rt+6],p[rt+7],p[rt+8]),H.set(_[xt+0],_[xt+1]),q.set(_[xt+2],_[xt+3]),$.set(_[xt+4],_[xt+5]),B.copy(T).add(A).add(L).divideScalar(3);var gt=Math.atan2(B.z,-B.x);d(H,xt+0,T,gt),d(q,xt+2,A,gt),d($,xt+4,L,gt)}for(T=0;T<_.length;T+=6)A=_[T+0],L=_[T+2],B=_[T+4],H=Math.min(A,L,B),.9<Math.max(A,L,B)&&.1>H&&(.2>A&&(_[T+0]+=1),.2>L&&(_[T+2]+=1),.2>B&&(_[T+4]+=1))}(),this.addAttribute("position",new Et(p,3)),this.addAttribute("normal",new Et(p.slice(),3)),this.addAttribute("uv",new Et(_,2)),n===0?this.computeVertexNormals():this.normalizeNormals()}function tl(t,e){X.call(this),this.type="TetrahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new fa(t,e)),this.mergeVertices()}function fa(t,e){xi.call(this,[1,1,1,-1,-1,1,-1,1,-1,1,-1,-1],[2,1,0,0,3,2,1,3,0,2,3,1],t,e),this.type="TetrahedronBufferGeometry",this.parameters={radius:t,detail:e}}function el(t,e){X.call(this),this.type="OctahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new xs(t,e)),this.mergeVertices()}function xs(t,e){xi.call(this,[1,0,0,-1,0,0,0,1,0,0,-1,0,0,0,1,0,0,-1],[0,2,4,0,4,3,0,3,5,0,5,2,1,2,5,1,5,3,1,3,4,1,4,2],t,e),this.type="OctahedronBufferGeometry",this.parameters={radius:t,detail:e}}function il(t,e){X.call(this),this.type="IcosahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new da(t,e)),this.mergeVertices()}function da(t,e){var i=(1+Math.sqrt(5))/2;xi.call(this,[-1,i,0,1,i,0,-1,-i,0,1,-i,0,0,-1,i,0,1,i,0,-1,-i,0,1,-i,i,0,-1,i,0,1,-i,0,-1,-i,0,1],[0,11,5,0,5,1,0,1,7,0,7,10,0,10,11,1,5,9,5,11,4,11,10,2,10,7,6,7,1,8,3,9,4,3,4,2,3,2,6,3,6,8,3,8,9,4,9,5,2,4,11,6,2,10,8,6,7,9,8,1],t,e),this.type="IcosahedronBufferGeometry",this.parameters={radius:t,detail:e}}function pa(t,e){X.call(this),this.type="DodecahedronGeometry",this.parameters={radius:t,detail:e},this.fromBufferGeometry(new ma(t,e)),this.mergeVertices()}function ma(t,e){var i=(1+Math.sqrt(5))/2,n=1/i;xi.call(this,[-1,-1,-1,-1,-1,1,-1,1,-1,-1,1,1,1,-1,-1,1,-1,1,1,1,-1,1,1,1,0,-n,-i,0,-n,i,0,n,-i,0,n,i,-n,-i,0,-n,i,0,n,-i,0,n,i,0,-i,0,-n,i,0,-n,-i,0,n,i,0,n],[3,11,7,3,7,15,3,15,13,7,19,17,7,17,6,7,6,15,17,4,8,17,8,10,17,10,6,8,0,16,8,16,2,8,2,10,0,12,1,0,1,18,0,18,16,6,10,2,6,2,13,6,13,15,2,16,18,2,18,3,2,3,13,18,1,9,18,9,11,18,11,3,4,14,12,4,12,0,4,0,8,11,9,5,11,5,19,11,19,7,19,5,14,19,14,4,19,4,17,1,12,14,1,14,5,1,5,9],t,e),this.type="DodecahedronBufferGeometry",this.parameters={radius:t,detail:e}}function gn(t,e,i,n,s,l){X.call(this),this.type="TubeGeometry",this.parameters={path:t,tubularSegments:e,radius:i,radialSegments:n,closed:s},t=new Jo(t,e,i,n,s),this.tangents=t.tangents,this.normals=t.normals,this.binormals=t.binormals,this.fromBufferGeometry(t),this.mergeVertices()}function Jo(t,e,i,n,s){function l(xt){A=t.getPointAt(xt/e,A);var gt=d.normals[xt];for(xt=d.binormals[xt],B=0;B<=n;B++){var Ct=B/n*Math.PI*2,wt=Math.sin(Ct);Ct=-Math.cos(Ct),_.x=Ct*gt.x+wt*xt.x,_.y=Ct*gt.y+wt*xt.y,_.z=Ct*gt.z+wt*xt.z,_.normalize(),q.push(_.x,_.y,_.z),p.x=A.x+i*_.x,p.y=A.y+i*_.y,p.z=A.z+i*_.z,H.push(p.x,p.y,p.z)}}Ft.call(this),this.type="TubeBufferGeometry",this.parameters={path:t,tubularSegments:e,radius:i,radialSegments:n,closed:s},e=e||64,i=i||1,n=n||8,s=s||!1;var d=t.computeFrenetFrames(e,s);this.tangents=d.tangents,this.normals=d.normals,this.binormals=d.binormals;var p=new u,_=new u,T=new o,A=new u,L,B,H=[],q=[],$=[],rt=[];for(L=0;L<e;L++)l(L);for(l(s===!1?e:0),L=0;L<=e;L++)for(B=0;B<=n;B++)T.x=L/e,T.y=B/n,$.push(T.x,T.y);(function(){for(B=1;B<=e;B++)for(L=1;L<=n;L++){var xt=(n+1)*B+(L-1),gt=(n+1)*B+L,Ct=(n+1)*(B-1)+L;rt.push((n+1)*(B-1)+(L-1),xt,Ct),rt.push(xt,gt,Ct)}})(),this.setIndex(rt),this.addAttribute("position",new Et(H,3)),this.addAttribute("normal",new Et(q,3)),this.addAttribute("uv",new Et($,2))}function Zr(t,e,i,n,s,l,d){X.call(this),this.type="TorusKnotGeometry",this.parameters={radius:t,tube:e,tubularSegments:i,radialSegments:n,p:s,q:l},this.fromBufferGeometry(new ws(t,e,i,n,s,l)),this.mergeVertices()}function ws(t,e,i,n,s,l){function d(K,ot,kt,ee,$t){var Yt=Math.sin(K);ot=kt/ot*K,kt=Math.cos(ot),$t.x=ee*(2+kt)*.5*Math.cos(K),$t.y=ee*(2+kt)*Yt*.5,$t.z=ee*Math.sin(ot)*.5}Ft.call(this),this.type="TorusKnotBufferGeometry",this.parameters={radius:t,tube:e,tubularSegments:i,radialSegments:n,p:s,q:l},t=t||1,e=e||.4,i=Math.floor(i)||64,n=Math.floor(n)||8,s=s||2,l=l||3;var p=[],_=[],T=[],A=[],L,B=new u,H=new u,q=new u,$=new u,rt=new u,xt=new u,gt=new u;for(L=0;L<=i;++L){var Ct=L/i*s*Math.PI*2;for(d(Ct,s,l,t,q),d(Ct+.01,s,l,t,$),xt.subVectors($,q),gt.addVectors($,q),rt.crossVectors(xt,gt),gt.crossVectors(rt,xt),rt.normalize(),gt.normalize(),Ct=0;Ct<=n;++Ct){var wt=Ct/n*Math.PI*2,Vt=-e*Math.cos(wt);wt=e*Math.sin(wt),B.x=q.x+(Vt*gt.x+wt*rt.x),B.y=q.y+(Vt*gt.y+wt*rt.y),B.z=q.z+(Vt*gt.z+wt*rt.z),_.push(B.x,B.y,B.z),H.subVectors(B,q).normalize(),T.push(H.x,H.y,H.z),A.push(L/i),A.push(Ct/n)}}for(Ct=1;Ct<=i;Ct++)for(L=1;L<=n;L++)t=(n+1)*Ct+(L-1),e=(n+1)*Ct+L,s=(n+1)*(Ct-1)+L,p.push((n+1)*(Ct-1)+(L-1),t,s),p.push(t,e,s);this.setIndex(p),this.addAttribute("position",new Et(_,3)),this.addAttribute("normal",new Et(T,3)),this.addAttribute("uv",new Et(A,2))}function Ts(t,e,i,n,s){X.call(this),this.type="TorusGeometry",this.parameters={radius:t,tube:e,radialSegments:i,tubularSegments:n,arc:s},this.fromBufferGeometry(new Un(t,e,i,n,s)),this.mergeVertices()}function Un(t,e,i,n,s){Ft.call(this),this.type="TorusBufferGeometry",this.parameters={radius:t,tube:e,radialSegments:i,tubularSegments:n,arc:s},t=t||1,e=e||.4,i=Math.floor(i)||8,n=Math.floor(n)||6,s=s||2*Math.PI;var l=[],d=[],p=[],_=[],T=new u,A=new u,L=new u,B,H;for(B=0;B<=i;B++)for(H=0;H<=n;H++){var q=H/n*s,$=B/i*Math.PI*2;A.x=(t+e*Math.cos($))*Math.cos(q),A.y=(t+e*Math.cos($))*Math.sin(q),A.z=e*Math.sin($),d.push(A.x,A.y,A.z),T.x=t*Math.cos(q),T.y=t*Math.sin(q),L.subVectors(A,T).normalize(),p.push(L.x,L.y,L.z),_.push(H/n),_.push(B/i)}for(B=1;B<=i;B++)for(H=1;H<=n;H++)t=(n+1)*(B-1)+H-1,e=(n+1)*(B-1)+H,s=(n+1)*B+H,l.push((n+1)*B+H-1,t,s),l.push(t,e,s);this.setIndex(l),this.addAttribute("position",new Et(d,3)),this.addAttribute("normal",new Et(p,3)),this.addAttribute("uv",new Et(_,2))}function kh(t,e,i,n,s){for(var l,d=0,p=e,_=i-n;p<i;p+=n)d+=(t[_]-t[p])*(t[p+1]+t[_+1]),_=p;if(s===0<d)for(s=e;s<i;s+=n)l=Jl(s,t[s],t[s+1],l);else for(s=i-n;s>=e;s-=n)l=Jl(s,t[s],t[s+1],l);return l&&Ms(l,l.next)&&(Yi(l),l=l.next),l}function ga(t,e){if(!t)return t;e||(e=t);do{var i=!1;if(t.steiner||!Ms(t,t.next)&&Ji(t.prev,t,t.next)!==0)t=t.next;else{if(Yi(t),t=e=t.prev,t===t.next)break;i=!0}}while(i||t!==e);return e}function va(t,e,i,n,s,l,d){if(t){if(!d&&l){var p=t,_=p;do _.z===null&&(_.z=Yl(_.x,_.y,n,s,l)),_.prevZ=_.prev,_=_.nextZ=_.next;while(_!==p);_.prevZ.nextZ=null,_.prevZ=null,p=_;var T,A,L,B,H=1;do{_=p;var q=p=null;for(A=0;_;){A++;var $=_;for(T=L=0;T<H&&(L++,$=$.nextZ,$);T++);for(B=H;0<L||0<B&&$;)L!==0&&(B===0||!$||_.z<=$.z)?(T=_,_=_.nextZ,L--):(T=$,$=$.nextZ,B--),q?q.nextZ=T:p=T,T.prevZ=q,q=T;_=$}q.nextZ=null,H*=2}while(1<A)}for(p=t;t.prev!==t.next;){if(_=t.prev,$=t.next,l)t:{q=t,B=n;var rt=s,xt=l;if(A=q.prev,L=q,H=q.next,0<=Ji(A,L,H))q=!1;else{var gt=A.x>L.x?A.x>H.x?A.x:H.x:L.x>H.x?L.x:H.x,Ct=A.y>L.y?A.y>H.y?A.y:H.y:L.y>H.y?L.y:H.y;for(T=Yl(A.x<L.x?A.x<H.x?A.x:H.x:L.x<H.x?L.x:H.x,A.y<L.y?A.y<H.y?A.y:H.y:L.y<H.y?L.y:H.y,B,rt,xt),B=Yl(gt,Ct,B,rt,xt),rt=q.nextZ;rt&&rt.z<=B;){if(rt!==q.prev&&rt!==q.next&&Zl(A.x,A.y,L.x,L.y,H.x,H.y,rt.x,rt.y)&&0<=Ji(rt.prev,rt,rt.next)){q=!1;break t}rt=rt.nextZ}for(rt=q.prevZ;rt&&rt.z>=T;){if(rt!==q.prev&&rt!==q.next&&Zl(A.x,A.y,L.x,L.y,H.x,H.y,rt.x,rt.y)&&0<=Ji(rt.prev,rt,rt.next)){q=!1;break t}rt=rt.prevZ}q=!0}}else t:if(q=t,A=q.prev,L=q,H=q.next,0<=Ji(A,L,H))q=!1;else{for(T=q.next.next;T!==q.prev;){if(Zl(A.x,A.y,L.x,L.y,H.x,H.y,T.x,T.y)&&0<=Ji(T.prev,T,T.next)){q=!1;break t}T=T.next}q=!0}if(q)e.push(_.i/i),e.push(t.i/i),e.push($.i/i),Yi(t),p=t=$.next;else if(t=$,t===p){if(!d)va(ga(t),e,i,n,s,l,1);else if(d===1){d=e,p=i,_=t;do $=_.prev,q=_.next.next,!Ms($,q)&&Bh($,_,_.next,q)&&Rr($,q)&&Rr(q,$)&&(d.push($.i/p),d.push(_.i/p),d.push(q.i/p),Yi(_),Yi(_.next),_=t=q),_=_.next;while(_!==t);t=_,va(t,e,i,n,s,l,2)}else if(d===2)t:{d=t;do{for(p=d.next.next;p!==d.prev;){if(_=d.i!==p.i){if(_=d,$=p,q=_.next.i!==$.i&&_.prev.i!==$.i){e:{q=_;do{if(q.i!==_.i&&q.next.i!==_.i&&q.i!==$.i&&q.next.i!==$.i&&Bh(q,q.next,_,$)){q=!0;break e}q=q.next}while(q!==_);q=!1}q=!q}if(q=q&&Rr(_,$)&&Rr($,_)){q=_,A=!1,L=(_.x+$.x)/2,$=(_.y+$.y)/2;do q.y>$!=q.next.y>$&&q.next.y!==q.y&&L<(q.next.x-q.x)*($-q.y)/(q.next.y-q.y)+q.x&&(A=!A),q=q.next;while(q!==_);q=A}_=q}if(_){t=nl(d,p),d=ga(d,d.next),t=ga(t,t.next),va(d,e,i,n,s,l),va(t,e,i,n,s,l);break t}p=p.next}d=d.next}while(d!==t)}break}}}}function Su(t,e){return t.x-e.x}function Eu(t,e){var i=e,n=t.x,s=t.y,l=-1/0;do{if(s<=i.y&&s>=i.next.y&&i.next.y!==i.y){var d=i.x+(s-i.y)*(i.next.x-i.x)/(i.next.y-i.y);if(d<=n&&d>l){if(l=d,d===n){if(s===i.y)return i;if(s===i.next.y)return i.next}var p=i.x<i.next.x?i:i.next}}i=i.next}while(i!==e);if(!p)return null;if(n===l)return p.prev;e=p,d=p.x;var _=p.y,T=1/0;for(i=p.next;i!==e;){if(n>=i.x&&i.x>=d&&n!==i.x&&Zl(s<_?n:l,s,d,_,s<_?l:n,s,i.x,i.y)){var A=Math.abs(s-i.y)/(n-i.x);(A<T||A===T&&i.x>p.x)&&Rr(i,t)&&(p=i,T=A)}i=i.next}return p}function Yl(t,e,i,n,s){return t=32767*(t-i)*s,e=32767*(e-n)*s,t=(t|t<<8)&16711935,t=(t|t<<4)&252645135,t=(t|t<<2)&858993459,e=(e|e<<8)&16711935,e=(e|e<<4)&252645135,e=(e|e<<2)&858993459,(t|t<<1)&1431655765|((e|e<<1)&1431655765)<<1}function yr(t){var e=t,i=t;do e.x<i.x&&(i=e),e=e.next;while(e!==t);return i}function Zl(t,e,i,n,s,l,d,p){return 0<=(s-d)*(e-p)-(t-d)*(l-p)&&0<=(t-d)*(n-p)-(i-d)*(e-p)&&0<=(i-d)*(l-p)-(s-d)*(n-p)}function Ji(t,e,i){return(e.y-t.y)*(i.x-e.x)-(e.x-t.x)*(i.y-e.y)}function Ms(t,e){return t.x===e.x&&t.y===e.y}function Bh(t,e,i,n){return Ms(t,e)&&Ms(i,n)||Ms(t,n)&&Ms(i,e)?!0:0<Ji(t,e,i)!=0<Ji(t,e,n)&&0<Ji(i,n,t)!=0<Ji(i,n,e)}function Rr(t,e){return 0>Ji(t.prev,t,t.next)?0<=Ji(t,e,t.next)&&0<=Ji(t,t.prev,e):0>Ji(t,e,t.prev)||0>Ji(t,t.next,e)}function nl(t,e){var i=new fo(t.i,t.x,t.y),n=new fo(e.i,e.x,e.y),s=t.next,l=e.prev;return t.next=e,e.prev=t,i.next=s,s.prev=i,n.next=i,i.prev=n,l.next=n,n.prev=l,n}function Jl(t,e,i,n){return t=new fo(t,e,i),n?(t.next=n.next,t.prev=n,n.next.prev=t,n.next=t):(t.prev=t,t.next=t),t}function Yi(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function fo(t,e,i){this.i=t,this.x=e,this.y=i,this.nextZ=this.prevZ=this.z=this.next=this.prev=null,this.steiner=!1}function $l(t){var e=t.length;2<e&&t[e-1].equals(t[0])&&t.pop()}function bu(t,e){for(var i=0;i<e.length;i++)t.push(e[i].x),t.push(e[i].y)}function Po(t,e){X.call(this),this.type="ExtrudeGeometry",this.parameters={shapes:t,options:e},this.fromBufferGeometry(new po(t,e)),this.mergeVertices()}function po(t,e){function i(_){function T(Xe,ri,Li){return ri.clone().multiplyScalar(Li).add(Xe)}function A(Xe,ri,Li){var Ai=Xe.x-ri.x,ne=Xe.y-ri.y,ii=Li.x-Xe.x,Je=Li.y-Xe.y,li=Ai*Ai+ne*ne;if(Math.abs(Ai*Je-ne*ii)>Number.EPSILON){var xn=Math.sqrt(li),Pn=Math.sqrt(ii*ii+Je*Je);if(li=ri.x-ne/xn,ri=ri.y+Ai/xn,Je=((Li.x-Je/Pn-li)*Je-(Li.y+ii/Pn-ri)*ii)/(Ai*Je-ne*ii),ii=li+Ai*Je-Xe.x,Ai=ri+ne*Je-Xe.y,ne=ii*ii+Ai*Ai,2>=ne)return new o(ii,Ai);ne=Math.sqrt(ne/2)}else Xe=!1,Ai>Number.EPSILON?ii>Number.EPSILON&&(Xe=!0):Ai<-Number.EPSILON?ii<-Number.EPSILON&&(Xe=!0):Math.sign(ne)===Math.sign(Je)&&(Xe=!0),Xe?(ii=-ne,ne=Math.sqrt(li)):(ii=Ai,Ai=ne,ne=Math.sqrt(li/2));return new o(ii/ne,Ai/ne)}function L(Xe,ri){for(Ce=Xe.length;0<=--Ce;){var Li=Ce,Ai=Ce-1;0>Ai&&(Ai=Xe.length-1);var ne,ii=gt+2*ot;for(ne=0;ne<ii;ne++){var Je=Vi*ne,li=Vi*(ne+1),xn=ri+Ai+Je,Pn=ri+Ai+li;li=ri+Li+li,q(ri+Li+Je),q(xn),q(li),q(xn),q(Pn),q(li),Je=s.length/3,Je=ee.generateSideWallUV(n,s,Je-6,Je-3,Je-2,Je-1),$(Je[0]),$(Je[1]),$(Je[3]),$(Je[1]),$(Je[2]),$(Je[3])}}}function B(Xe,ri,Li){rt.push(Xe),rt.push(ri),rt.push(Li)}function H(Xe,ri,Li){q(Xe),q(ri),q(Li),Xe=s.length/3,Xe=ee.generateTopUV(n,s,Xe-3,Xe-2,Xe-1),$(Xe[0]),$(Xe[1]),$(Xe[2])}function q(Xe){s.push(rt[3*Xe]),s.push(rt[3*Xe+1]),s.push(rt[3*Xe+2])}function $(Xe){l.push(Xe.x),l.push(Xe.y)}var rt=[],xt=e.curveSegments!==void 0?e.curveSegments:12,gt=e.steps!==void 0?e.steps:1,Ct=e.depth!==void 0?e.depth:100,wt=e.bevelEnabled!==void 0?e.bevelEnabled:!0,Vt=e.bevelThickness!==void 0?e.bevelThickness:6,K=e.bevelSize!==void 0?e.bevelSize:Vt-2,ot=e.bevelSegments!==void 0?e.bevelSegments:3,kt=e.extrudePath,ee=e.UVGenerator!==void 0?e.UVGenerator:Tl;e.amount!==void 0&&(Ct=e.amount);var $t=!1;if(kt){var Yt=kt.getSpacedPoints(gt);$t=!0,wt=!1;var Te=kt.computeFrenetFrames(gt,!1),ge=new u,De=new u,be=new u}wt||(K=Vt=ot=0);var ae;xt=_.extractPoints(xt),_=xt.shape;var We=xt.holes;if(!To.isClockWise(_)){_=_.reverse();var Qe=0;for(ae=We.length;Qe<ae;Qe++){var fi=We[Qe];To.isClockWise(fi)&&(We[Qe]=fi.reverse())}}var Cn=To.triangulateShape(_,We),_n=_;for(Qe=0,ae=We.length;Qe<ae;Qe++)fi=We[Qe],_=_.concat(fi);var qi,Vi=_.length,on,An=Cn.length;xt=[];var Ce=0,ti=_n.length,Ht=ti-1;for(qi=Ce+1;Ce<ti;Ce++,Ht++,qi++)Ht===ti&&(Ht=0),qi===ti&&(qi=0),xt[Ce]=A(_n[Ce],_n[Ht],_n[qi]);kt=[];var Ye=xt.concat();for(Qe=0,ae=We.length;Qe<ae;Qe++){fi=We[Qe];var ei=[];for(Ce=0,ti=fi.length,Ht=ti-1,qi=Ce+1;Ce<ti;Ce++,Ht++,qi++)Ht===ti&&(Ht=0),qi===ti&&(qi=0),ei[Ce]=A(fi[Ce],fi[Ht],fi[qi]);kt.push(ei),Ye=Ye.concat(ei)}for(Ht=0;Ht<ot;Ht++){ti=Ht/ot;var Wi=Vt*Math.cos(ti*Math.PI/2);for(qi=K*Math.sin(ti*Math.PI/2),Ce=0,ti=_n.length;Ce<ti;Ce++){var Ae=T(_n[Ce],xt[Ce],qi);B(Ae.x,Ae.y,-Wi)}for(Qe=0,ae=We.length;Qe<ae;Qe++)for(fi=We[Qe],ei=kt[Qe],Ce=0,ti=fi.length;Ce<ti;Ce++)Ae=T(fi[Ce],ei[Ce],qi),B(Ae.x,Ae.y,-Wi)}for(qi=K,Ce=0;Ce<Vi;Ce++)Ae=wt?T(_[Ce],Ye[Ce],qi):_[Ce],$t?(De.copy(Te.normals[0]).multiplyScalar(Ae.x),ge.copy(Te.binormals[0]).multiplyScalar(Ae.y),be.copy(Yt[0]).add(De).add(ge),B(be.x,be.y,be.z)):B(Ae.x,Ae.y,0);for(ti=1;ti<=gt;ti++)for(Ce=0;Ce<Vi;Ce++)Ae=wt?T(_[Ce],Ye[Ce],qi):_[Ce],$t?(De.copy(Te.normals[ti]).multiplyScalar(Ae.x),ge.copy(Te.binormals[ti]).multiplyScalar(Ae.y),be.copy(Yt[ti]).add(De).add(ge),B(be.x,be.y,be.z)):B(Ae.x,Ae.y,Ct/gt*ti);for(Ht=ot-1;0<=Ht;Ht--){for(ti=Ht/ot,Wi=Vt*Math.cos(ti*Math.PI/2),qi=K*Math.sin(ti*Math.PI/2),Ce=0,ti=_n.length;Ce<ti;Ce++)Ae=T(_n[Ce],xt[Ce],qi),B(Ae.x,Ae.y,Ct+Wi);for(Qe=0,ae=We.length;Qe<ae;Qe++)for(fi=We[Qe],ei=kt[Qe],Ce=0,ti=fi.length;Ce<ti;Ce++)Ae=T(fi[Ce],ei[Ce],qi),$t?B(Ae.x,Ae.y+Yt[gt-1].y,Yt[gt-1].x+Wi):B(Ae.x,Ae.y,Ct+Wi)}(function(){var Xe=s.length/3;if(wt){var ri=0*Vi;for(Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[2]+ri,on[1]+ri,on[0]+ri);for(ri=Vi*(gt+2*ot),Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[0]+ri,on[1]+ri,on[2]+ri)}else{for(Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[2],on[1],on[0]);for(Ce=0;Ce<An;Ce++)on=Cn[Ce],H(on[0]+Vi*gt,on[1]+Vi*gt,on[2]+Vi*gt)}n.addGroup(Xe,s.length/3-Xe,0)})(),function(){var Xe=s.length/3,ri=0;for(L(_n,ri),ri+=_n.length,Qe=0,ae=We.length;Qe<ae;Qe++)fi=We[Qe],L(fi,ri),ri+=fi.length;n.addGroup(Xe,s.length/3-Xe,1)}()}Ft.call(this),this.type="ExtrudeBufferGeometry",this.parameters={shapes:t,options:e},t=Array.isArray(t)?t:[t];for(var n=this,s=[],l=[],d=0,p=t.length;d<p;d++)i(t[d]);this.addAttribute("position",new Et(s,3)),this.addAttribute("uv",new Et(l,2)),this.computeVertexNormals()}function Cu(t,e,i){if(i.shapes=[],Array.isArray(t))for(var n=0,s=t.length;n<s;n++)i.shapes.push(t[n].uuid);else i.shapes.push(t.uuid);return e.extrudePath!==void 0&&(i.options.extrudePath=e.extrudePath.toJSON()),i}function rl(t,e){X.call(this),this.type="TextGeometry",this.parameters={text:t,parameters:e},this.fromBufferGeometry(new Ss(t,e)),this.mergeVertices()}function Ss(t,e){e=e||{};var i=e.font;if(!i||!i.isFont)return new X;t=i.generateShapes(t,e.size),e.depth=e.height!==void 0?e.height:50,e.bevelThickness===void 0&&(e.bevelThickness=10),e.bevelSize===void 0&&(e.bevelSize=8),e.bevelEnabled===void 0&&(e.bevelEnabled=!1),po.call(this,t,e),this.type="TextBufferGeometry"}function $o(t,e,i,n,s,l,d){X.call(this),this.type="SphereGeometry",this.parameters={radius:t,widthSegments:e,heightSegments:i,phiStart:n,phiLength:s,thetaStart:l,thetaLength:d},this.fromBufferGeometry(new Or(t,e,i,n,s,l,d)),this.mergeVertices()}function Or(t,e,i,n,s,l,d){Ft.call(this),this.type="SphereBufferGeometry",this.parameters={radius:t,widthSegments:e,heightSegments:i,phiStart:n,phiLength:s,thetaStart:l,thetaLength:d},t=t||1,e=Math.max(3,Math.floor(e)||8),i=Math.max(2,Math.floor(i)||6),n=n!==void 0?n:0,s=s!==void 0?s:2*Math.PI,l=l!==void 0?l:0,d=d!==void 0?d:Math.PI;var p=l+d,_,T,A=0,L=[],B=new u,H=new u,q=[],$=[],rt=[],xt=[];for(T=0;T<=i;T++){var gt=[],Ct=T/i;for(_=0;_<=e;_++){var wt=_/e;B.x=-t*Math.cos(n+wt*s)*Math.sin(l+Ct*d),B.y=t*Math.cos(l+Ct*d),B.z=t*Math.sin(n+wt*s)*Math.sin(l+Ct*d),$.push(B.x,B.y,B.z),H.set(B.x,B.y,B.z).normalize(),rt.push(H.x,H.y,H.z),xt.push(wt,1-Ct),gt.push(A++)}L.push(gt)}for(T=0;T<i;T++)for(_=0;_<e;_++)t=L[T][_+1],n=L[T][_],s=L[T+1][_],d=L[T+1][_+1],(T!==0||0<l)&&q.push(t,n,d),(T!==i-1||p<Math.PI)&&q.push(n,s,d);this.setIndex(q),this.addAttribute("position",new Et($,3)),this.addAttribute("normal",new Et(rt,3)),this.addAttribute("uv",new Et(xt,2))}function ol(t,e,i,n,s,l){X.call(this),this.type="RingGeometry",this.parameters={innerRadius:t,outerRadius:e,thetaSegments:i,phiSegments:n,thetaStart:s,thetaLength:l},this.fromBufferGeometry(new Es(t,e,i,n,s,l)),this.mergeVertices()}function Es(t,e,i,n,s,l){Ft.call(this),this.type="RingBufferGeometry",this.parameters={innerRadius:t,outerRadius:e,thetaSegments:i,phiSegments:n,thetaStart:s,thetaLength:l},t=t||.5,e=e||1,s=s!==void 0?s:0,l=l!==void 0?l:2*Math.PI,i=i!==void 0?Math.max(3,i):8,n=n!==void 0?Math.max(1,n):1;var d=[],p=[],_=[],T=[],A=t,L=(e-t)/n,B=new u,H=new o,q,$;for(q=0;q<=n;q++){for($=0;$<=i;$++)t=s+$/i*l,B.x=A*Math.cos(t),B.y=A*Math.sin(t),p.push(B.x,B.y,B.z),_.push(0,0,1),H.x=(B.x/e+1)/2,H.y=(B.y/e+1)/2,T.push(H.x,H.y);A+=L}for(q=0;q<n;q++)for(e=q*(i+1),$=0;$<i;$++)t=$+e,s=t+i+1,l=t+i+2,A=t+1,d.push(t,s,A),d.push(s,l,A);this.setIndex(d),this.addAttribute("position",new Et(p,3)),this.addAttribute("normal",new Et(_,3)),this.addAttribute("uv",new Et(T,2))}function ya(t,e,i,n){X.call(this),this.type="LatheGeometry",this.parameters={points:t,segments:e,phiStart:i,phiLength:n},this.fromBufferGeometry(new Ko(t,e,i,n)),this.mergeVertices()}function Ko(t,e,i,n){Ft.call(this),this.type="LatheBufferGeometry",this.parameters={points:t,segments:e,phiStart:i,phiLength:n},e=Math.floor(e)||12,i=i||0,n=n||2*Math.PI,n=di.clamp(n,0,2*Math.PI);var s=[],l=[],d=[],p=1/e,_=new u,T=new o,A;for(A=0;A<=e;A++){var L=i+A*p*n,B=Math.sin(L),H=Math.cos(L);for(L=0;L<=t.length-1;L++)_.x=t[L].x*B,_.y=t[L].y,_.z=t[L].x*H,l.push(_.x,_.y,_.z),T.x=A/e,T.y=L/(t.length-1),d.push(T.x,T.y)}for(A=0;A<e;A++)for(L=0;L<t.length-1;L++)i=L+A*t.length,p=i+t.length,_=i+t.length+1,T=i+1,s.push(i,p,T),s.push(p,_,T);if(this.setIndex(s),this.addAttribute("position",new Et(l,3)),this.addAttribute("uv",new Et(d,2)),this.computeVertexNormals(),n===2*Math.PI)for(n=this.attributes.normal.array,s=new u,l=new u,d=new u,i=e*t.length*3,L=A=0;A<t.length;A++,L+=3)s.x=n[L+0],s.y=n[L+1],s.z=n[L+2],l.x=n[i+L+0],l.y=n[i+L+1],l.z=n[i+L+2],d.addVectors(s,l).normalize(),n[L+0]=n[i+L+0]=d.x,n[L+1]=n[i+L+1]=d.y,n[L+2]=n[i+L+2]=d.z}function Lo(t,e){X.call(this),this.type="ShapeGeometry",typeof e=="object"&&(e=e.curveSegments),this.parameters={shapes:t,curveSegments:e},this.fromBufferGeometry(new Qo(t,e)),this.mergeVertices()}function Qo(t,e){function i(A){var L,B=s.length/3;A=A.extractPoints(e);var H=A.shape,q=A.holes;if(To.isClockWise(H)===!1)for(H=H.reverse(),A=0,L=q.length;A<L;A++){var $=q[A];To.isClockWise($)===!0&&(q[A]=$.reverse())}var rt=To.triangulateShape(H,q);for(A=0,L=q.length;A<L;A++)$=q[A],H=H.concat($);for(A=0,L=H.length;A<L;A++)$=H[A],s.push($.x,$.y,0),l.push(0,0,1),d.push($.x,$.y);for(A=0,L=rt.length;A<L;A++)H=rt[A],n.push(H[0]+B,H[1]+B,H[2]+B),_+=3}Ft.call(this),this.type="ShapeBufferGeometry",this.parameters={shapes:t,curveSegments:e},e=e||12;var n=[],s=[],l=[],d=[],p=0,_=0;if(Array.isArray(t)===!1)i(t);else for(var T=0;T<t.length;T++)i(t[T]),this.addGroup(p,_,T),p+=_,_=0;this.setIndex(n),this.addAttribute("position",new Et(s,3)),this.addAttribute("normal",new Et(l,3)),this.addAttribute("uv",new Et(d,2))}function Au(t,e){if(e.shapes=[],Array.isArray(t))for(var i=0,n=t.length;i<n;i++)e.shapes.push(t[i].uuid);else e.shapes.push(t.uuid);return e}function ts(t,e){Ft.call(this),this.type="EdgesGeometry",this.parameters={thresholdAngle:e};var i=[];e=Math.cos(di.DEG2RAD*(e!==void 0?e:1));var n=[0,0],s={},l=["a","b","c"];if(t.isBufferGeometry){var d=new X;d.fromBufferGeometry(t)}else d=t.clone();d.mergeVertices(),d.computeFaceNormals(),t=d.vertices,d=d.faces;for(var p=0,_=d.length;p<_;p++)for(var T=d[p],A=0;3>A;A++){var L=T[l[A]],B=T[l[(A+1)%3]];n[0]=Math.min(L,B),n[1]=Math.max(L,B),L=n[0]+","+n[1],s[L]===void 0?s[L]={index1:n[0],index2:n[1],face1:p,face2:void 0}:s[L].face2=p}for(L in s)n=s[L],(n.face2===void 0||d[n.face1].normal.dot(d[n.face2].normal)<=e)&&(l=t[n.index1],i.push(l.x,l.y,l.z),l=t[n.index2],i.push(l.x,l.y,l.z));this.addAttribute("position",new Et(i,3))}function Ro(t,e,i,n,s,l,d,p){X.call(this),this.type="CylinderGeometry",this.parameters={radiusTop:t,radiusBottom:e,height:i,radialSegments:n,heightSegments:s,openEnded:l,thetaStart:d,thetaLength:p},this.fromBufferGeometry(new Oo(t,e,i,n,s,l,d,p)),this.mergeVertices()}function Oo(t,e,i,n,s,l,d,p){function _(gt){var Ct,wt=new o,Vt=new u,K=0,ot=gt===!0?t:e,kt=gt===!0?1:-1,ee=q;for(Ct=1;Ct<=n;Ct++)L.push(0,rt*kt,0),B.push(0,kt,0),H.push(.5,.5),q++;var $t=q;for(Ct=0;Ct<=n;Ct++){var Yt=Ct/n*p+d,Te=Math.cos(Yt);Yt=Math.sin(Yt),Vt.x=ot*Yt,Vt.y=rt*kt,Vt.z=ot*Te,L.push(Vt.x,Vt.y,Vt.z),B.push(0,kt,0),wt.x=.5*Te+.5,wt.y=.5*Yt*kt+.5,H.push(wt.x,wt.y),q++}for(Ct=0;Ct<n;Ct++)wt=ee+Ct,Vt=$t+Ct,gt===!0?A.push(Vt,Vt+1,wt):A.push(Vt+1,Vt,wt),K+=3;T.addGroup(xt,K,gt===!0?1:2),xt+=K}Ft.call(this),this.type="CylinderBufferGeometry",this.parameters={radiusTop:t,radiusBottom:e,height:i,radialSegments:n,heightSegments:s,openEnded:l,thetaStart:d,thetaLength:p};var T=this;t=t!==void 0?t:1,e=e!==void 0?e:1,i=i||1,n=Math.floor(n)||8,s=Math.floor(s)||1,l=l!==void 0?l:!1,d=d!==void 0?d:0,p=p!==void 0?p:2*Math.PI;var A=[],L=[],B=[],H=[],q=0,$=[],rt=i/2,xt=0;(function(){var gt,Ct,wt=new u,Vt=new u,K=0,ot=(e-t)/i;for(Ct=0;Ct<=s;Ct++){var kt=[],ee=Ct/s,$t=ee*(e-t)+t;for(gt=0;gt<=n;gt++){var Yt=gt/n,Te=Yt*p+d,ge=Math.sin(Te);Te=Math.cos(Te),Vt.x=$t*ge,Vt.y=-ee*i+rt,Vt.z=$t*Te,L.push(Vt.x,Vt.y,Vt.z),wt.set(ge,ot,Te).normalize(),B.push(wt.x,wt.y,wt.z),H.push(Yt,1-ee),kt.push(q++)}$.push(kt)}for(gt=0;gt<n;gt++)for(Ct=0;Ct<s;Ct++)wt=$[Ct+1][gt],Vt=$[Ct+1][gt+1],ot=$[Ct][gt+1],A.push($[Ct][gt],wt,ot),A.push(wt,Vt,ot),K+=6;T.addGroup(xt,K,0),xt+=K})(),l===!1&&(0<t&&_(!0),0<e&&_(!1)),this.setIndex(A),this.addAttribute("position",new Et(L,3)),this.addAttribute("normal",new Et(B,3)),this.addAttribute("uv",new Et(H,2))}function _a(t,e,i,n,s,l,d){Ro.call(this,0,t,e,i,n,s,l,d),this.type="ConeGeometry",this.parameters={radius:t,height:e,radialSegments:i,heightSegments:n,openEnded:s,thetaStart:l,thetaLength:d}}function Gn(t,e,i,n,s,l,d){Oo.call(this,0,t,e,i,n,s,l,d),this.type="ConeBufferGeometry",this.parameters={radius:t,height:e,radialSegments:i,heightSegments:n,openEnded:s,thetaStart:l,thetaLength:d}}function bs(t,e,i,n){X.call(this),this.type="CircleGeometry",this.parameters={radius:t,segments:e,thetaStart:i,thetaLength:n},this.fromBufferGeometry(new mo(t,e,i,n)),this.mergeVertices()}function mo(t,e,i,n){Ft.call(this),this.type="CircleBufferGeometry",this.parameters={radius:t,segments:e,thetaStart:i,thetaLength:n},t=t||1,e=e!==void 0?Math.max(3,e):8,i=i!==void 0?i:0,n=n!==void 0?n:2*Math.PI;var s=[],l=[],d=[],p=[],_,T=new u,A=new o;l.push(0,0,0),d.push(0,0,1),p.push(.5,.5);var L=0;for(_=3;L<=e;L++,_+=3){var B=i+L/e*n;T.x=t*Math.cos(B),T.y=t*Math.sin(B),l.push(T.x,T.y,T.z),d.push(0,0,1),A.x=(l[_]/t+1)/2,A.y=(l[_+1]/t+1)/2,p.push(A.x,A.y)}for(_=1;_<=e;_++)s.push(_,_+1,0);this.setIndex(s),this.addAttribute("position",new Et(l,3)),this.addAttribute("normal",new Et(d,3)),this.addAttribute("uv",new Et(p,2))}function es(t){Wt.call(this),this.type="ShadowMaterial",this.color=new P(0),this.transparent=!0,this.setValues(t)}function Cs(t){$e.call(this,t),this.type="RawShaderMaterial"}function go(t){Wt.call(this),this.defines={STANDARD:""},this.type="MeshStandardMaterial",this.color=new P(16777215),this.metalness=this.roughness=.5,this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new P(0),this.emissiveIntensity=1,this.bumpMap=this.emissiveMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.envMap=this.alphaMap=this.metalnessMap=this.roughnessMap=null,this.envMapIntensity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t)}function As(t){go.call(this),this.defines={PHYSICAL:""},this.type="MeshPhysicalMaterial",this.reflectivity=.5,this.clearCoatRoughness=this.clearCoat=0,this.setValues(t)}function Jr(t){Wt.call(this),this.type="MeshPhongMaterial",this.color=new P(16777215),this.specular=new P(1118481),this.shininess=30,this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new P(0),this.emissiveIntensity=1,this.bumpMap=this.emissiveMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.envMap=this.alphaMap=this.specularMap=null,this.combine=0,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t)}function Ps(t){Jr.call(this),this.defines={TOON:""},this.type="MeshToonMaterial",this.gradientMap=null,this.setValues(t)}function Ls(t){Wt.call(this),this.type="MeshNormalMaterial",this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.morphNormals=this.morphTargets=this.skinning=this.lights=this.fog=!1,this.setValues(t)}function Ir(t){Wt.call(this),this.type="MeshLambertMaterial",this.color=new P(16777215),this.lightMap=this.map=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new P(0),this.emissiveIntensity=1,this.envMap=this.alphaMap=this.specularMap=this.emissiveMap=null,this.combine=0,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinejoin=this.wireframeLinecap="round",this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t)}function Rs(t){if(Wt.call(this),this.defines={MATCAP:""},this.type="MeshMatcapMaterial",this.color=new P(16777215),this.bumpMap=this.map=this.matcap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=0,this.normalScale=new o(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.lights=this.morphNormals=this.morphTargets=this.skinning=!1,this.setValues(t),this.matcap===null){t=document.createElement("canvas"),t.width=1,t.height=1;var e=t.getContext("2d");e.fillStyle="#fff",e.fillRect(0,0,1,1),this.matcap=new THREE.CanvasTexture(t)}}function Os(t){Ni.call(this),this.type="LineDashedMaterial",this.scale=1,this.dashSize=3,this.gapSize=1,this.setValues(t)}function $n(t,e,i,n){this.parameterPositions=t,this._cachedIndex=0,this.resultBuffer=n!==void 0?n:new e.constructor(i),this.sampleValues=e,this.valueSize=i}function sl(t,e,i,n){$n.call(this,t,e,i,n),this._offsetNext=this._weightNext=this._offsetPrev=this._weightPrev=-0}function Dr(t,e,i,n){$n.call(this,t,e,i,n)}function Is(t,e,i,n){$n.call(this,t,e,i,n)}function Hn(t,e,i,n){if(t===void 0)throw Error("THREE.KeyframeTrack: track name is undefined");if(e===void 0||e.length===0)throw Error("THREE.KeyframeTrack: no keyframes in track named "+t);this.name=t,this.times=Yn.convertArray(e,this.TimeBufferType),this.values=Yn.convertArray(i,this.ValueBufferType),this.setInterpolation(n||this.DefaultInterpolation)}function Kl(t,e,i){Hn.call(this,t,e,i)}function Ql(t,e,i,n){Hn.call(this,t,e,i,n)}function $r(t,e,i,n){Hn.call(this,t,e,i,n)}function ar(t,e,i,n){$n.call(this,t,e,i,n)}function xa(t,e,i,n){Hn.call(this,t,e,i,n)}function th(t,e,i,n){Hn.call(this,t,e,i,n)}function wa(t,e,i,n){Hn.call(this,t,e,i,n)}function _r(t,e,i){this.name=t,this.tracks=i,this.duration=e!==void 0?e:-1,this.uuid=di.generateUUID(),0>this.duration&&this.resetDuration()}function jc(t){switch(t.toLowerCase()){case"scalar":case"double":case"float":case"number":case"integer":return $r;case"vector":case"vector2":case"vector3":case"vector4":return wa;case"color":return Ql;case"quaternion":return xa;case"bool":case"boolean":return Kl;case"string":return th}throw Error("THREE.KeyframeTrack: Unsupported typeName: "+t)}function Xc(t){if(t.type===void 0)throw Error("THREE.KeyframeTrack: track type undefined, can not parse");var e=jc(t.type);if(t.times===void 0){var i=[],n=[];Yn.flattenJSON(t.keys,i,n,"value"),t.times=i,t.values=n}return e.parse!==void 0?e.parse(t):new e(t.name,t.times,t.values,t.interpolation)}function is(t,e,i){var n=this,s=!1,l=0,d=0,p=void 0;this.onStart=void 0,this.onLoad=t,this.onProgress=e,this.onError=i,this.itemStart=function(_){d++,s===!1&&n.onStart!==void 0&&n.onStart(_,l,d),s=!0},this.itemEnd=function(_){l++,n.onProgress!==void 0&&n.onProgress(_,l,d),l===d&&(s=!1,n.onLoad!==void 0)&&n.onLoad()},this.itemError=function(_){n.onError!==void 0&&n.onError(_)},this.resolveURL=function(_){return p?p(_):_},this.setURLModifier=function(_){return p=_,this}}function Lt(t){this.manager=t!==void 0?t:tr}function Qt(t){this.manager=t!==void 0?t:tr}function Zt(t){this.manager=t!==void 0?t:tr,this._parser=null}function Ue(t){this.manager=t!==void 0?t:tr,this._parser=null}function ai(t){this.manager=t!==void 0?t:tr}function Fi(t){this.manager=t!==void 0?t:tr}function fn(t){this.manager=t!==void 0?t:tr}function Ee(){this.type="Curve",this.arcLengthDivisions=200}function Kn(t,e,i,n,s,l,d,p){Ee.call(this),this.type="EllipseCurve",this.aX=t||0,this.aY=e||0,this.xRadius=i||1,this.yRadius=n||1,this.aStartAngle=s||0,this.aEndAngle=l||2*Math.PI,this.aClockwise=d||!1,this.aRotation=p||0}function Ta(t,e,i,n,s,l){Kn.call(this,t,e,i,i,n,s,l),this.type="ArcCurve"}function lr(){var t=0,e=0,i=0,n=0;return{initCatmullRom:function(s,l,d,p,_){s=_*(d-s),p=_*(p-l),t=l,e=s,i=-3*l+3*d-2*s-p,n=2*l-2*d+s+p},initNonuniformCatmullRom:function(s,l,d,p,_,T,A){s=((l-s)/_-(d-s)/(_+T)+(d-l)/T)*T,p=((d-l)/T-(p-l)/(T+A)+(p-d)/A)*T,t=l,e=s,i=-3*l+3*d-2*s-p,n=2*l-2*d+s+p},calc:function(s){var l=s*s;return t+e*s+i*l+n*l*s}}}function On(t,e,i,n){Ee.call(this),this.type="CatmullRomCurve3",this.points=t||[],this.closed=e||!1,this.curveType=i||"centripetal",this.tension=n||.5}function Pu(t,e,i,n,s){e=.5*(n-e),s=.5*(s-i);var l=t*t;return(2*i-2*n+e+s)*t*l+(-3*i+3*n-2*e-s)*l+e*t+i}function vo(t,e,i,n){var s=1-t;return s*s*e+2*(1-t)*t*i+t*t*n}function ns(t,e,i,n,s){var l=1-t,d=1-t;return l*l*l*e+3*d*d*t*i+3*(1-t)*t*t*n+t*t*t*s}function hr(t,e,i,n){Ee.call(this),this.type="CubicBezierCurve",this.v0=t||new o,this.v1=e||new o,this.v2=i||new o,this.v3=n||new o}function Ti(t,e,i,n){Ee.call(this),this.type="CubicBezierCurve3",this.v0=t||new u,this.v1=e||new u,this.v2=i||new u,this.v3=n||new u}function ur(t,e){Ee.call(this),this.type="LineCurve",this.v1=t||new o,this.v2=e||new o}function zr(t,e){Ee.call(this),this.type="LineCurve3",this.v1=t||new u,this.v2=e||new u}function cr(t,e,i){Ee.call(this),this.type="QuadraticBezierCurve",this.v0=t||new o,this.v1=e||new o,this.v2=i||new o}function yo(t,e,i){Ee.call(this),this.type="QuadraticBezierCurve3",this.v0=t||new u,this.v1=e||new u,this.v2=i||new u}function Kr(t){Ee.call(this),this.type="SplineCurve",this.points=t||[]}function Io(){Ee.call(this),this.type="CurvePath",this.curves=[],this.autoClose=!1}function fr(t){Io.call(this),this.type="Path",this.currentPoint=new o,t&&this.setFromPoints(t)}function Qn(t){fr.call(this,t),this.uuid=di.generateUUID(),this.type="Shape",this.holes=[]}function tn(t,e){N.call(this),this.type="Light",this.color=new P(t),this.intensity=e!==void 0?e:1,this.receiveShadow=void 0}function al(t,e,i){tn.call(this,t,i),this.type="HemisphereLight",this.castShadow=void 0,this.position.copy(N.DefaultUp),this.updateMatrix(),this.groundColor=new P(e)}function _o(t){this.camera=t,this.bias=0,this.radius=1,this.mapSize=new o(512,512),this.map=null,this.matrix=new c}function ll(){_o.call(this,new _e(50,1,.5,500))}function hl(t,e,i,n,s,l){tn.call(this,t,e),this.type="SpotLight",this.position.copy(N.DefaultUp),this.updateMatrix(),this.target=new N,Object.defineProperty(this,"power",{get:function(){return this.intensity*Math.PI},set:function(d){this.intensity=d/Math.PI}}),this.distance=i!==void 0?i:0,this.angle=n!==void 0?n:Math.PI/3,this.penumbra=s!==void 0?s:0,this.decay=l!==void 0?l:1,this.shadow=new ll}function Ds(t,e,i,n){tn.call(this,t,e),this.type="PointLight",Object.defineProperty(this,"power",{get:function(){return 4*this.intensity*Math.PI},set:function(s){this.intensity=s/(4*Math.PI)}}),this.distance=i!==void 0?i:0,this.decay=n!==void 0?n:1,this.shadow=new _o(new _e(90,1,.5,500))}function Ma(t,e,i,n,s,l){Be.call(this),this.type="OrthographicCamera",this.zoom=1,this.view=null,this.left=t!==void 0?t:-1,this.right=e!==void 0?e:1,this.top=i!==void 0?i:1,this.bottom=n!==void 0?n:-1,this.near=s!==void 0?s:.1,this.far=l!==void 0?l:2e3,this.updateProjectionMatrix()}function rs(){_o.call(this,new Ma(-5,5,5,-5,.5,500))}function xo(t,e){tn.call(this,t,e),this.type="DirectionalLight",this.position.copy(N.DefaultUp),this.updateMatrix(),this.target=new N,this.shadow=new rs}function zs(t,e){tn.call(this,t,e),this.type="AmbientLight",this.castShadow=void 0}function eh(t,e,i,n){tn.call(this,t,e),this.type="RectAreaLight",this.width=i!==void 0?i:10,this.height=n!==void 0?n:10}function ih(t){this.manager=t!==void 0?t:tr,this.textures={}}function Nh(t){this.manager=t!==void 0?t:tr}function Do(){}function ks(t){typeof t=="boolean"&&(t=void 0),this.manager=t!==void 0?t:tr,this.withCredentials=!1}function ul(t){this.manager=t!==void 0?t:tr,this.resourcePath=""}function Fh(t){typeof createImageBitmap>"u",typeof fetch>"u",this.manager=t!==void 0?t:tr,this.options=void 0}function nh(){this.type="ShapePath",this.color=new P,this.subPaths=[],this.currentPath=null}function Uh(t){this.type="Font",this.data=t}function Lu(t){this.manager=t!==void 0?t:tr}function vn(t){this.manager=t!==void 0?t:tr}function Vn(){this.type="StereoCamera",this.aspect=1,this.eyeSep=.064,this.cameraL=new _e,this.cameraL.layers.enable(1),this.cameraL.matrixAutoUpdate=!1,this.cameraR=new _e,this.cameraR.layers.enable(2),this.cameraR.matrixAutoUpdate=!1}function cl(t,e,i,n){N.call(this),this.type="CubeCamera";var s=new _e(90,1,t,e);s.up.set(0,-1,0),s.lookAt(new u(1,0,0)),this.add(s);var l=new _e(90,1,t,e);l.up.set(0,-1,0),l.lookAt(new u(-1,0,0)),this.add(l);var d=new _e(90,1,t,e);d.up.set(0,0,1),d.lookAt(new u(0,1,0)),this.add(d);var p=new _e(90,1,t,e);p.up.set(0,0,-1),p.lookAt(new u(0,-1,0)),this.add(p);var _=new _e(90,1,t,e);_.up.set(0,-1,0),_.lookAt(new u(0,0,1)),this.add(_);var T=new _e(90,1,t,e);T.up.set(0,-1,0),T.lookAt(new u(0,0,-1)),this.add(T),n=n||{format:1022,magFilter:1006,minFilter:1006},this.renderTarget=new b(i,i,n),this.renderTarget.texture.name="CubeCamera",this.update=function(A,L){this.parent===null&&this.updateMatrixWorld();var B=this.renderTarget,H=B.texture.generateMipmaps;B.texture.generateMipmaps=!1,B.activeCubeFace=0,A.render(L,s,B),B.activeCubeFace=1,A.render(L,l,B),B.activeCubeFace=2,A.render(L,d,B),B.activeCubeFace=3,A.render(L,p,B),B.activeCubeFace=4,A.render(L,_,B),B.texture.generateMipmaps=H,B.activeCubeFace=5,A.render(L,T,B),A.setRenderTarget(null)},this.clear=function(A,L,B,H){for(var q=this.renderTarget,$=0;6>$;$++)q.activeCubeFace=$,A.setRenderTarget(q),A.clear(L,B,H);A.setRenderTarget(null)}}function Gh(t){this.autoStart=t!==void 0?t:!0,this.elapsedTime=this.oldTime=this.startTime=0,this.running=!1}function rh(){N.call(this),this.type="AudioListener",this.context=$h.getContext(),this.gain=this.context.createGain(),this.gain.connect(this.context.destination),this.filter=null,this.timeDelta=0}function Sa(t){N.call(this),this.type="Audio",this.listener=t,this.context=t.context,this.gain=this.context.createGain(),this.gain.connect(t.getInput()),this.autoplay=!1,this.buffer=null,this.loop=!1,this.offset=this.startTime=0,this.playbackRate=1,this.isPlaying=!1,this.hasPlaybackControl=!0,this.sourceType="empty",this.filters=[]}function fl(t){Sa.call(this,t),this.panner=this.context.createPanner(),this.panner.connect(this.gain)}function Bs(t,e){this.analyser=t.context.createAnalyser(),this.analyser.fftSize=e!==void 0?e:2048,this.data=new Uint8Array(this.analyser.frequencyBinCount),t.getOutput().connect(this.analyser)}function dl(t,e,i){switch(this.binding=t,this.valueSize=i,t=Float64Array,e){case"quaternion":e=this._slerp;break;case"string":case"bool":t=Array,e=this._select;break;default:e=this._lerp}this.buffer=new t(4*i),this._mixBufferRegion=e,this.referenceCount=this.useCount=this.cumulativeWeight=0}function Ns(t,e,i){i=i||En.parseTrackName(e),this._targetGroup=t,this._bindings=t.subscribe_(e,i)}function En(t,e,i){this.path=e,this.parsedPath=i||En.parseTrackName(e),this.node=En.findNode(t,this.parsedPath.nodeName)||t,this.rootNode=t}function Ea(){this.uuid=di.generateUUID(),this._objects=Array.prototype.slice.call(arguments),this.nCachedObjects_=0;var t={};this._indicesByUUID=t;for(var e=0,i=arguments.length;e!==i;++e)t[arguments[e].uuid]=e;this._paths=[],this._parsedPaths=[],this._bindings=[],this._bindingsIndicesByPath={};var n=this;this.stats={objects:{get total(){return n._objects.length},get inUse(){return this.total-n.nCachedObjects_}},get bindingsPerObject(){return n._bindings.length}}}function pl(t,e,i){this._mixer=t,this._clip=e,this._localRoot=i||null,t=e.tracks,e=t.length,i=Array(e);for(var n={endingStart:2400,endingEnd:2400},s=0;s!==e;++s){var l=t[s].createInterpolant(null);i[s]=l,l.settings=n}this._interpolantSettings=n,this._interpolants=i,this._propertyBindings=Array(e),this._weightInterpolant=this._timeScaleInterpolant=this._byClipCacheIndex=this._cacheIndex=null,this.loop=2201,this._loopCount=-1,this._startTime=null,this.time=0,this._effectiveWeight=this.weight=this._effectiveTimeScale=this.timeScale=1,this.repetitions=1/0,this.paused=!1,this.enabled=!0,this.clampWhenFinished=!1,this.zeroSlopeAtEnd=this.zeroSlopeAtStart=!0}function os(t){this._root=t,this._initMemoryManager(),this.time=this._accuIndex=0,this.timeScale=1}function oh(t,e){typeof t=="string"&&(t=e),this.value=t}function Hh(){Ft.call(this),this.type="InstancedBufferGeometry",this.maxInstancedCount=void 0}function Vh(t,e,i){ki.call(this,t,e),this.meshPerAttribute=i||1}function Wh(t,e,i,n){typeof i=="number"&&(n=i,i=!1),J.call(this,t,e,i),this.meshPerAttribute=n||1}function Ru(t,e,i,n){this.ray=new Si(t,e),this.near=i||0,this.far=n||1/0,this.params={Mesh:{},Line:{},LOD:{},Points:{threshold:1},Sprite:{}},Object.defineProperties(this.params,{PointCloud:{get:function(){return this.Points}}})}function ml(t,e){return t.distance-e.distance}function Fs(t,e,i,n){if(t.visible!==!1&&(t.raycast(e,i),n===!0)){t=t.children,n=0;for(var s=t.length;n<s;n++)Fs(t[n],e,i,!0)}}function jh(t,e,i){return this.radius=t!==void 0?t:1,this.phi=e!==void 0?e:0,this.theta=i!==void 0?i:0,this}function it(t,e,i){return this.radius=t!==void 0?t:1,this.theta=e!==void 0?e:0,this.y=i!==void 0?i:0,this}function ss(t,e){this.min=t!==void 0?t:new o(1/0,1/0),this.max=e!==void 0?e:new o(-1/0,-1/0)}function ba(t,e){this.start=t!==void 0?t:new u,this.end=e!==void 0?e:new u}function qn(t){N.call(this),this.material=t,this.render=function(){}}function _i(t,e,i,n){this.object=t,this.size=e!==void 0?e:1,t=i!==void 0?i:16711680,n=n!==void 0?n:1,e=0,(i=this.object.geometry)&&i.isGeometry?e=3*i.faces.length:i&&i.isBufferGeometry&&(e=i.attributes.normal.count),i=new Ft,e=new Et(6*e,3),i.addAttribute("position",e),gi.call(this,i,new Ni({color:t,linewidth:n})),this.matrixAutoUpdate=!1,this.update()}function Ca(t,e){N.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=e,t=new Ft,e=[0,0,0,0,0,1,0,0,0,1,0,1,0,0,0,-1,0,1,0,0,0,0,1,1,0,0,0,0,-1,1];for(var i=0,n=1;32>i;i++,n++){var s=i/32*Math.PI*2,l=n/32*Math.PI*2;e.push(Math.cos(s),Math.sin(s),1,Math.cos(l),Math.sin(l),1)}t.addAttribute("position",new Et(e,3)),e=new Ni({fog:!1}),this.cone=new gi(t,e),this.add(this.cone),this.update()}function Ou(t){var e=[];t&&t.isBone&&e.push(t);for(var i=0;i<t.children.length;i++)e.push.apply(e,Ou(t.children[i]));return e}function Aa(t){for(var e=Ou(t),i=new Ft,n=[],s=[],l=new P(0,0,1),d=new P(0,1,0),p=0;p<e.length;p++){var _=e[p];_.parent&&_.parent.isBone&&(n.push(0,0,0),n.push(0,0,0),s.push(l.r,l.g,l.b),s.push(d.r,d.g,d.b))}i.addAttribute("position",new Et(n,3)),i.addAttribute("color",new Et(s,3)),n=new Ni({vertexColors:2,depthTest:!1,depthWrite:!1,transparent:!0}),gi.call(this,i,n),this.root=t,this.bones=e,this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1}function kr(t,e,i){this.light=t,this.light.updateMatrixWorld(),this.color=i,t=new Or(e,4,2),e=new Ge({wireframe:!0,fog:!1}),pi.call(this,t,e),this.matrix=this.light.matrixWorld,this.matrixAutoUpdate=!1,this.update()}function Pa(t,e){N.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=e,t=new Ni({fog:!1}),e=new Ft,e.addAttribute("position",new J(new Float32Array(15),3)),this.line=new ji(e,t),this.add(this.line),this.update()}function La(t,e,i){N.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=i,t=new xs(e),t.rotateY(.5*Math.PI),this.material=new Ge({wireframe:!0,fog:!1}),this.color===void 0&&(this.material.vertexColors=2),e=t.getAttribute("position"),e=new Float32Array(3*e.count),t.addAttribute("color",new J(e,3)),this.add(new pi(t,this.material)),this.update()}function gl(t,e,i,n){t=t||10,e=e||10,i=new P(i!==void 0?i:4473924),n=new P(n!==void 0?n:8947848);var s=e/2,l=t/e,d=t/2;t=[];for(var p=[],_=0,T=0,A=-d;_<=e;_++,A+=l){t.push(-d,0,A,d,0,A),t.push(A,0,-d,A,0,d);var L=_===s?i:n;L.toArray(p,T),T+=3,L.toArray(p,T),T+=3,L.toArray(p,T),T+=3,L.toArray(p,T),T+=3}e=new Ft,e.addAttribute("position",new Et(t,3)),e.addAttribute("color",new Et(p,3)),i=new Ni({vertexColors:2}),gi.call(this,e,i)}function sh(t,e,i,n,s,l){t=t||10,e=e||16,i=i||8,n=n||64,s=new P(s!==void 0?s:4473924),l=new P(l!==void 0?l:8947848);var d=[],p=[],_;for(_=0;_<=e;_++){var T=_/e*2*Math.PI,A=Math.sin(T)*t;T=Math.cos(T)*t,d.push(0,0,0),d.push(A,0,T);var L=_&1?s:l;p.push(L.r,L.g,L.b),p.push(L.r,L.g,L.b)}for(_=0;_<=i;_++){L=_&1?s:l;var B=t-t/i*_;for(e=0;e<n;e++)T=e/n*2*Math.PI,A=Math.sin(T)*B,T=Math.cos(T)*B,d.push(A,0,T),p.push(L.r,L.g,L.b),T=(e+1)/n*2*Math.PI,A=Math.sin(T)*B,T=Math.cos(T)*B,d.push(A,0,T),p.push(L.r,L.g,L.b)}t=new Ft,t.addAttribute("position",new Et(d,3)),t.addAttribute("color",new Et(p,3)),d=new Ni({vertexColors:2}),gi.call(this,t,d)}function vl(t,e,i,n){this.object=t,this.size=e!==void 0?e:1,t=i!==void 0?i:16776960,n=n!==void 0?n:1,e=0,(i=this.object.geometry)&&i.isGeometry&&(e=i.faces.length),i=new Ft,e=new Et(6*e,3),i.addAttribute("position",e),gi.call(this,i,new Ni({color:t,linewidth:n})),this.matrixAutoUpdate=!1,this.update()}function dr(t,e,i){N.call(this),this.light=t,this.light.updateMatrixWorld(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.color=i,e===void 0&&(e=1),t=new Ft,t.addAttribute("position",new Et([-e,e,0,e,e,0,e,-e,0,-e,-e,0,-e,e,0],3)),e=new Ni({fog:!1}),this.lightPlane=new ji(t,e),this.add(this.lightPlane),t=new Ft,t.addAttribute("position",new Et([0,0,0,0,0,1],3)),this.targetLine=new ji(t,e),this.add(this.targetLine),this.update()}function yl(t){function e(H,q,$){i(H,$),i(q,$)}function i(H,q){l.push(0,0,0),d.push(q.r,q.g,q.b),p[H]===void 0&&(p[H]=[]),p[H].push(l.length/3-1)}var n=new Ft,s=new Ni({color:16777215,vertexColors:1}),l=[],d=[],p={},_=new P(16755200),T=new P(16711680),A=new P(43775),L=new P(16777215),B=new P(3355443);e("n1","n2",_),e("n2","n4",_),e("n4","n3",_),e("n3","n1",_),e("f1","f2",_),e("f2","f4",_),e("f4","f3",_),e("f3","f1",_),e("n1","f1",_),e("n2","f2",_),e("n3","f3",_),e("n4","f4",_),e("p","n1",T),e("p","n2",T),e("p","n3",T),e("p","n4",T),e("u1","u2",A),e("u2","u3",A),e("u3","u1",A),e("c","t",L),e("p","c",B),e("cn1","cn2",B),e("cn3","cn4",B),e("cf1","cf2",B),e("cf3","cf4",B),n.addAttribute("position",new Et(l,3)),n.addAttribute("color",new Et(d,3)),gi.call(this,n,s),this.camera=t,this.camera.updateProjectionMatrix&&this.camera.updateProjectionMatrix(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.pointMap=p,this.update()}function zo(t,e){this.object=t,e===void 0&&(e=16776960),t=new Uint16Array([0,1,1,2,2,3,3,0,4,5,5,6,6,7,7,4,0,4,1,5,2,6,3,7]);var i=new Float32Array(24),n=new Ft;n.setIndex(new J(t,1)),n.addAttribute("position",new J(i,3)),gi.call(this,n,new Ni({color:e})),this.matrixAutoUpdate=!1,this.update()}function _l(t,e){this.type="Box3Helper",this.box=t,t=e!==void 0?e:16776960,e=new Uint16Array([0,1,1,2,2,3,3,0,4,5,5,6,6,7,7,4,0,4,1,5,2,6,3,7]);var i=new Ft;i.setIndex(new J(e,1)),i.addAttribute("position",new Et([1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,-1,-1,1,-1,-1,-1,-1,1,-1,-1],3)),gi.call(this,i,new Ni({color:t})),this.geometry.computeBoundingSphere()}function xl(t,e,i){this.type="PlaneHelper",this.plane=t,this.size=e===void 0?1:e,t=i!==void 0?i:16776960,e=new Ft,e.addAttribute("position",new Et([1,-1,1,-1,1,1,-1,-1,1,1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,0,0,1,0,0,0],3)),e.computeBoundingSphere(),ji.call(this,e,new Ni({color:t})),e=new Ft,e.addAttribute("position",new Et([1,1,1,-1,1,1,-1,-1,1,1,1,1,-1,-1,1,1,-1,1],3)),e.computeBoundingSphere(),this.add(new pi(e,new Ge({color:t,opacity:.2,transparent:!0,depthWrite:!1})))}function ko(t,e,i,n,s,l){N.call(this),t===void 0&&(t=new THREE.Vector3(0,0,1)),e===void 0&&(e=new THREE.Vector3(0,0,0)),i===void 0&&(i=1),n===void 0&&(n=16776960),s===void 0&&(s=.2*i),l===void 0&&(l=.2*s),fh===void 0&&(fh=new Ft,fh.addAttribute("position",new Et([0,0,0,0,1,0],3)),Sl=new Oo(0,.5,1,5,1),Sl.translate(0,-.5,0)),this.position.copy(e),this.line=new ji(fh,new Ni({color:n})),this.line.matrixAutoUpdate=!1,this.add(this.line),this.cone=new pi(Sl,new Ge({color:n})),this.cone.matrixAutoUpdate=!1,this.add(this.cone),this.setDirection(t),this.setLength(i,s,l)}function xr(t){t=t||1;var e=[0,0,0,t,0,0,0,0,0,0,t,0,0,0,0,0,0,t];t=new Ft,t.addAttribute("position",new Et(e,3)),t.addAttribute("color",new Et([1,0,0,1,.6,0,0,1,0,.6,1,0,0,0,1,0,.6,1],3)),e=new Ni({vertexColors:2}),gi.call(this,t,e)}function Iu(t){On.call(this,t),this.type="catmullrom",this.closed=!0}function Du(t){On.call(this,t),this.type="catmullrom"}function Xh(t){On.call(this,t),this.type="catmullrom"}Number.EPSILON===void 0&&(Number.EPSILON=Math.pow(2,-52)),Number.isInteger===void 0&&(Number.isInteger=function(t){return typeof t=="number"&&isFinite(t)&&Math.floor(t)===t}),Math.sign===void 0&&(Math.sign=function(t){return 0>t?-1:0<t?1:+t}),!("name"in Function.prototype)&&Object.defineProperty(Function.prototype,"name",{get:function(){return this.toString().match(/^\s*function\s*([^\(\s]*)/)[1]}}),Object.assign===void 0&&function(){Object.assign=function(t){if(t==null)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;i<arguments.length;i++){var n=arguments[i];if(n!=null)for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(e[s]=n[s])}return e}}(),Object.assign(a.prototype,{addEventListener:function(t,e){this._listeners===void 0&&(this._listeners={});var i=this._listeners;i[t]===void 0&&(i[t]=[]),i[t].indexOf(e)===-1&&i[t].push(e)},hasEventListener:function(t,e){if(this._listeners===void 0)return!1;var i=this._listeners;return i[t]!==void 0&&i[t].indexOf(e)!==-1},removeEventListener:function(t,e){this._listeners!==void 0&&(t=this._listeners[t],t!==void 0&&(e=t.indexOf(e),e!==-1&&t.splice(e,1)))},dispatchEvent:function(t){if(this._listeners!==void 0){var e=this._listeners[t.type];if(e!==void 0){t.target=this,e=e.slice(0);for(var i=0,n=e.length;i<n;i++)e[i].call(this,t)}}}});var di={DEG2RAD:Math.PI/180,RAD2DEG:180/Math.PI,generateUUID:function(){for(var t=[],e=0;256>e;e++)t[e]=(16>e?"0":"")+e.toString(16);return function(){var i=4294967295*Math.random()|0,n=4294967295*Math.random()|0,s=4294967295*Math.random()|0,l=4294967295*Math.random()|0;return(t[i&255]+t[i>>8&255]+t[i>>16&255]+t[i>>24&255]+"-"+t[n&255]+t[n>>8&255]+"-"+t[n>>16&15|64]+t[n>>24&255]+"-"+t[s&63|128]+t[s>>8&255]+"-"+t[s>>16&255]+t[s>>24&255]+t[l&255]+t[l>>8&255]+t[l>>16&255]+t[l>>24&255]).toUpperCase()}}(),clamp:function(t,e,i){return Math.max(e,Math.min(i,t))},euclideanModulo:function(t,e){return(t%e+e)%e},mapLinear:function(t,e,i,n,s){return n+(t-e)*(s-n)/(i-e)},lerp:function(t,e,i){return(1-i)*t+i*e},smoothstep:function(t,e,i){return t<=e?0:t>=i?1:(t=(t-e)/(i-e),t*t*(3-2*t))},smootherstep:function(t,e,i){return t<=e?0:t>=i?1:(t=(t-e)/(i-e),t*t*t*(t*(6*t-15)+10))},randInt:function(t,e){return t+Math.floor(Math.random()*(e-t+1))},randFloat:function(t,e){return t+Math.random()*(e-t)},randFloatSpread:function(t){return t*(.5-Math.random())},degToRad:function(t){return t*di.DEG2RAD},radToDeg:function(t){return t*di.RAD2DEG},isPowerOfTwo:function(t){return(t&t-1)===0&&t!==0},ceilPowerOfTwo:function(t){return Math.pow(2,Math.ceil(Math.log(t)/Math.LN2))},floorPowerOfTwo:function(t){return Math.pow(2,Math.floor(Math.log(t)/Math.LN2))}};Object.defineProperties(o.prototype,{width:{get:function(){return this.x},set:function(t){this.x=t}},height:{get:function(){return this.y},set:function(t){this.y=t}}}),Object.assign(o.prototype,{isVector2:!0,set:function(t,e){return this.x=t,this.y=e,this},setScalar:function(t){return this.y=this.x=t,this},setX:function(t){return this.x=t,this},setY:function(t){return this.y=t,this},setComponent:function(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;default:throw Error("index is out of range: "+t)}return this},getComponent:function(t){switch(t){case 0:return this.x;case 1:return this.y;default:throw Error("index is out of range: "+t)}},clone:function(){return new this.constructor(this.x,this.y)},copy:function(t){return this.x=t.x,this.y=t.y,this},add:function(t,e){return e!==void 0?this.addVectors(t,e):(this.x+=t.x,this.y+=t.y,this)},addScalar:function(t){return this.x+=t,this.y+=t,this},addVectors:function(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this},addScaledVector:function(t,e){return this.x+=t.x*e,this.y+=t.y*e,this},sub:function(t,e){return e!==void 0?this.subVectors(t,e):(this.x-=t.x,this.y-=t.y,this)},subScalar:function(t){return this.x-=t,this.y-=t,this},subVectors:function(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this},multiply:function(t){return this.x*=t.x,this.y*=t.y,this},multiplyScalar:function(t){return this.x*=t,this.y*=t,this},divide:function(t){return this.x/=t.x,this.y/=t.y,this},divideScalar:function(t){return this.multiplyScalar(1/t)},applyMatrix3:function(t){var e=this.x,i=this.y;return t=t.elements,this.x=t[0]*e+t[3]*i+t[6],this.y=t[1]*e+t[4]*i+t[7],this},min:function(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this},max:function(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this},clamp:function(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this},clampScalar:function(){var t=new o,e=new o;return function(i,n){return t.set(i,i),e.set(n,n),this.clamp(t,e)}}(),clampLength:function(t,e){var i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(t,Math.min(e,i)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},roundToZero:function(){return this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x),this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y),this},negate:function(){return this.x=-this.x,this.y=-this.y,this},dot:function(t){return this.x*t.x+this.y*t.y},cross:function(t){return this.x*t.y-this.y*t.x},lengthSq:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)},normalize:function(){return this.divideScalar(this.length()||1)},angle:function(){var t=Math.atan2(this.y,this.x);return 0>t&&(t+=2*Math.PI),t},distanceTo:function(t){return Math.sqrt(this.distanceToSquared(t))},distanceToSquared:function(t){var e=this.x-t.x;return t=this.y-t.y,e*e+t*t},manhattanDistanceTo:function(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)},setLength:function(t){return this.normalize().multiplyScalar(t)},lerp:function(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this},lerpVectors:function(t,e,i){return this.subVectors(e,t).multiplyScalar(i).add(t)},equals:function(t){return t.x===this.x&&t.y===this.y},fromArray:function(t,e){return e===void 0&&(e=0),this.x=t[e],this.y=t[e+1],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.x,t[e+1]=this.y,t},fromBufferAttribute:function(t,e,i){return this.x=t.getX(e),this.y=t.getY(e),this},rotateAround:function(t,e){var i=Math.cos(e);e=Math.sin(e);var n=this.x-t.x,s=this.y-t.y;return this.x=n*i-s*e+t.x,this.y=n*e+s*i+t.y,this}}),Object.assign(c.prototype,{isMatrix4:!0,set:function(t,e,i,n,s,l,d,p,_,T,A,L,B,H,q,$){var rt=this.elements;return rt[0]=t,rt[4]=e,rt[8]=i,rt[12]=n,rt[1]=s,rt[5]=l,rt[9]=d,rt[13]=p,rt[2]=_,rt[6]=T,rt[10]=A,rt[14]=L,rt[3]=B,rt[7]=H,rt[11]=q,rt[15]=$,this},identity:function(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this},clone:function(){return new c().fromArray(this.elements)},copy:function(t){var e=this.elements;return t=t.elements,e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],this},copyPosition:function(t){var e=this.elements;return t=t.elements,e[12]=t[12],e[13]=t[13],e[14]=t[14],this},extractBasis:function(t,e,i){return t.setFromMatrixColumn(this,0),e.setFromMatrixColumn(this,1),i.setFromMatrixColumn(this,2),this},makeBasis:function(t,e,i){return this.set(t.x,e.x,i.x,0,t.y,e.y,i.y,0,t.z,e.z,i.z,0,0,0,0,1),this},extractRotation:function(){var t=new u;return function(e){var i=this.elements,n=e.elements,s=1/t.setFromMatrixColumn(e,0).length(),l=1/t.setFromMatrixColumn(e,1).length();return e=1/t.setFromMatrixColumn(e,2).length(),i[0]=n[0]*s,i[1]=n[1]*s,i[2]=n[2]*s,i[3]=0,i[4]=n[4]*l,i[5]=n[5]*l,i[6]=n[6]*l,i[7]=0,i[8]=n[8]*e,i[9]=n[9]*e,i[10]=n[10]*e,i[11]=0,i[12]=0,i[13]=0,i[14]=0,i[15]=1,this}}(),makeRotationFromEuler:function(t){t&&t.isEuler;var e=this.elements,i=t.x,n=t.y,s=t.z,l=Math.cos(i);i=Math.sin(i);var d=Math.cos(n);n=Math.sin(n);var p=Math.cos(s);if(s=Math.sin(s),t.order==="XYZ"){t=l*p;var _=l*s,T=i*p,A=i*s;e[0]=d*p,e[4]=-d*s,e[8]=n,e[1]=_+T*n,e[5]=t-A*n,e[9]=-i*d,e[2]=A-t*n,e[6]=T+_*n,e[10]=l*d}else t.order==="YXZ"?(t=d*p,_=d*s,T=n*p,A=n*s,e[0]=t+A*i,e[4]=T*i-_,e[8]=l*n,e[1]=l*s,e[5]=l*p,e[9]=-i,e[2]=_*i-T,e[6]=A+t*i,e[10]=l*d):t.order==="ZXY"?(t=d*p,_=d*s,T=n*p,A=n*s,e[0]=t-A*i,e[4]=-l*s,e[8]=T+_*i,e[1]=_+T*i,e[5]=l*p,e[9]=A-t*i,e[2]=-l*n,e[6]=i,e[10]=l*d):t.order==="ZYX"?(t=l*p,_=l*s,T=i*p,A=i*s,e[0]=d*p,e[4]=T*n-_,e[8]=t*n+A,e[1]=d*s,e[5]=A*n+t,e[9]=_*n-T,e[2]=-n,e[6]=i*d,e[10]=l*d):t.order==="YZX"?(t=l*d,_=l*n,T=i*d,A=i*n,e[0]=d*p,e[4]=A-t*s,e[8]=T*s+_,e[1]=s,e[5]=l*p,e[9]=-i*p,e[2]=-n*p,e[6]=_*s+T,e[10]=t-A*s):t.order==="XZY"&&(t=l*d,_=l*n,T=i*d,A=i*n,e[0]=d*p,e[4]=-s,e[8]=n*p,e[1]=t*s+A,e[5]=l*p,e[9]=_*s-T,e[2]=T*s-_,e[6]=i*p,e[10]=A*s+t);return e[3]=0,e[7]=0,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,this},makeRotationFromQuaternion:function(){var t=new u(0,0,0),e=new u(1,1,1);return function(i){return this.compose(t,i,e)}}(),lookAt:function(){var t=new u,e=new u,i=new u;return function(n,s,l){var d=this.elements;return i.subVectors(n,s),i.lengthSq()===0&&(i.z=1),i.normalize(),t.crossVectors(l,i),t.lengthSq()===0&&(Math.abs(l.z)===1?i.x+=1e-4:i.z+=1e-4,i.normalize(),t.crossVectors(l,i)),t.normalize(),e.crossVectors(i,t),d[0]=t.x,d[4]=e.x,d[8]=i.x,d[1]=t.y,d[5]=e.y,d[9]=i.y,d[2]=t.z,d[6]=e.z,d[10]=i.z,this}}(),multiply:function(t,e){return e!==void 0?this.multiplyMatrices(t,e):this.multiplyMatrices(this,t)},premultiply:function(t){return this.multiplyMatrices(t,this)},multiplyMatrices:function(t,e){var i=t.elements,n=e.elements;e=this.elements,t=i[0];var s=i[4],l=i[8],d=i[12],p=i[1],_=i[5],T=i[9],A=i[13],L=i[2],B=i[6],H=i[10],q=i[14],$=i[3],rt=i[7],xt=i[11];i=i[15];var gt=n[0],Ct=n[4],wt=n[8],Vt=n[12],K=n[1],ot=n[5],kt=n[9],ee=n[13],$t=n[2],Yt=n[6],Te=n[10],ge=n[14],De=n[3],be=n[7],ae=n[11];return n=n[15],e[0]=t*gt+s*K+l*$t+d*De,e[4]=t*Ct+s*ot+l*Yt+d*be,e[8]=t*wt+s*kt+l*Te+d*ae,e[12]=t*Vt+s*ee+l*ge+d*n,e[1]=p*gt+_*K+T*$t+A*De,e[5]=p*Ct+_*ot+T*Yt+A*be,e[9]=p*wt+_*kt+T*Te+A*ae,e[13]=p*Vt+_*ee+T*ge+A*n,e[2]=L*gt+B*K+H*$t+q*De,e[6]=L*Ct+B*ot+H*Yt+q*be,e[10]=L*wt+B*kt+H*Te+q*ae,e[14]=L*Vt+B*ee+H*ge+q*n,e[3]=$*gt+rt*K+xt*$t+i*De,e[7]=$*Ct+rt*ot+xt*Yt+i*be,e[11]=$*wt+rt*kt+xt*Te+i*ae,e[15]=$*Vt+rt*ee+xt*ge+i*n,this},multiplyScalar:function(t){var e=this.elements;return e[0]*=t,e[4]*=t,e[8]*=t,e[12]*=t,e[1]*=t,e[5]*=t,e[9]*=t,e[13]*=t,e[2]*=t,e[6]*=t,e[10]*=t,e[14]*=t,e[3]*=t,e[7]*=t,e[11]*=t,e[15]*=t,this},applyToBufferAttribute:function(){var t=new u;return function(e){for(var i=0,n=e.count;i<n;i++)t.x=e.getX(i),t.y=e.getY(i),t.z=e.getZ(i),t.applyMatrix4(this),e.setXYZ(i,t.x,t.y,t.z);return e}}(),determinant:function(){var t=this.elements,e=t[0],i=t[4],n=t[8],s=t[12],l=t[1],d=t[5],p=t[9],_=t[13],T=t[2],A=t[6],L=t[10],B=t[14];return t[3]*(+s*p*A-n*_*A-s*d*L+i*_*L+n*d*B-i*p*B)+t[7]*(+e*p*B-e*_*L+s*l*L-n*l*B+n*_*T-s*p*T)+t[11]*(+e*_*A-e*d*B-s*l*A+i*l*B+s*d*T-i*_*T)+t[15]*(-n*d*T-e*p*A+e*d*L+n*l*A-i*l*L+i*p*T)},transpose:function(){var t=this.elements,e=t[1];return t[1]=t[4],t[4]=e,e=t[2],t[2]=t[8],t[8]=e,e=t[6],t[6]=t[9],t[9]=e,e=t[3],t[3]=t[12],t[12]=e,e=t[7],t[7]=t[13],t[13]=e,e=t[11],t[11]=t[14],t[14]=e,this},setPosition:function(t){var e=this.elements;return e[12]=t.x,e[13]=t.y,e[14]=t.z,this},getInverse:function(t,e){var i=this.elements,n=t.elements;t=n[0];var s=n[1],l=n[2],d=n[3],p=n[4],_=n[5],T=n[6],A=n[7],L=n[8],B=n[9],H=n[10],q=n[11],$=n[12],rt=n[13],xt=n[14];n=n[15];var gt=B*xt*A-rt*H*A+rt*T*q-_*xt*q-B*T*n+_*H*n,Ct=$*H*A-L*xt*A-$*T*q+p*xt*q+L*T*n-p*H*n,wt=L*rt*A-$*B*A+$*_*q-p*rt*q-L*_*n+p*B*n,Vt=$*B*T-L*rt*T-$*_*H+p*rt*H+L*_*xt-p*B*xt,K=t*gt+s*Ct+l*wt+d*Vt;if(K===0){if(e===!0)throw Error("THREE.Matrix4: .getInverse() can't invert matrix, determinant is 0");return this.identity()}return e=1/K,i[0]=gt*e,i[1]=(rt*H*d-B*xt*d-rt*l*q+s*xt*q+B*l*n-s*H*n)*e,i[2]=(_*xt*d-rt*T*d+rt*l*A-s*xt*A-_*l*n+s*T*n)*e,i[3]=(B*T*d-_*H*d-B*l*A+s*H*A+_*l*q-s*T*q)*e,i[4]=Ct*e,i[5]=(L*xt*d-$*H*d+$*l*q-t*xt*q-L*l*n+t*H*n)*e,i[6]=($*T*d-p*xt*d-$*l*A+t*xt*A+p*l*n-t*T*n)*e,i[7]=(p*H*d-L*T*d+L*l*A-t*H*A-p*l*q+t*T*q)*e,i[8]=wt*e,i[9]=($*B*d-L*rt*d-$*s*q+t*rt*q+L*s*n-t*B*n)*e,i[10]=(p*rt*d-$*_*d+$*s*A-t*rt*A-p*s*n+t*_*n)*e,i[11]=(L*_*d-p*B*d-L*s*A+t*B*A+p*s*q-t*_*q)*e,i[12]=Vt*e,i[13]=(L*rt*l-$*B*l+$*s*H-t*rt*H-L*s*xt+t*B*xt)*e,i[14]=($*_*l-p*rt*l-$*s*T+t*rt*T+p*s*xt-t*_*xt)*e,i[15]=(p*B*l-L*_*l+L*s*T-t*B*T-p*s*H+t*_*H)*e,this},scale:function(t){var e=this.elements,i=t.x,n=t.y;return t=t.z,e[0]*=i,e[4]*=n,e[8]*=t,e[1]*=i,e[5]*=n,e[9]*=t,e[2]*=i,e[6]*=n,e[10]*=t,e[3]*=i,e[7]*=n,e[11]*=t,this},getMaxScaleOnAxis:function(){var t=this.elements;return Math.sqrt(Math.max(t[0]*t[0]+t[1]*t[1]+t[2]*t[2],t[4]*t[4]+t[5]*t[5]+t[6]*t[6],t[8]*t[8]+t[9]*t[9]+t[10]*t[10]))},makeTranslation:function(t,e,i){return this.set(1,0,0,t,0,1,0,e,0,0,1,i,0,0,0,1),this},makeRotationX:function(t){var e=Math.cos(t);return t=Math.sin(t),this.set(1,0,0,0,0,e,-t,0,0,t,e,0,0,0,0,1),this},makeRotationY:function(t){var e=Math.cos(t);return t=Math.sin(t),this.set(e,0,t,0,0,1,0,0,-t,0,e,0,0,0,0,1),this},makeRotationZ:function(t){var e=Math.cos(t);return t=Math.sin(t),this.set(e,-t,0,0,t,e,0,0,0,0,1,0,0,0,0,1),this},makeRotationAxis:function(t,e){var i=Math.cos(e);e=Math.sin(e);var n=1-i,s=t.x,l=t.y;t=t.z;var d=n*s,p=n*l;return this.set(d*s+i,d*l-e*t,d*t+e*l,0,d*l+e*t,p*l+i,p*t-e*s,0,d*t-e*l,p*t+e*s,n*t*t+i,0,0,0,0,1),this},makeScale:function(t,e,i){return this.set(t,0,0,0,0,e,0,0,0,0,i,0,0,0,0,1),this},makeShear:function(t,e,i){return this.set(1,e,i,0,t,1,i,0,t,e,1,0,0,0,0,1),this},compose:function(t,e,i){var n=this.elements,s=e._x,l=e._y,d=e._z,p=e._w,_=s+s,T=l+l,A=d+d;e=s*_;var L=s*T;s*=A;var B=l*T;l*=A,d*=A,_*=p,T*=p,p*=A,A=i.x;var H=i.y;return i=i.z,n[0]=(1-(B+d))*A,n[1]=(L+p)*A,n[2]=(s-T)*A,n[3]=0,n[4]=(L-p)*H,n[5]=(1-(e+d))*H,n[6]=(l+_)*H,n[7]=0,n[8]=(s+T)*i,n[9]=(l-_)*i,n[10]=(1-(e+B))*i,n[11]=0,n[12]=t.x,n[13]=t.y,n[14]=t.z,n[15]=1,this},decompose:function(){var t=new u,e=new c;return function(i,n,s){var l=this.elements,d=t.set(l[0],l[1],l[2]).length(),p=t.set(l[4],l[5],l[6]).length(),_=t.set(l[8],l[9],l[10]).length();0>this.determinant()&&(d=-d),i.x=l[12],i.y=l[13],i.z=l[14],e.copy(this),i=1/d,l=1/p;var T=1/_;return e.elements[0]*=i,e.elements[1]*=i,e.elements[2]*=i,e.elements[4]*=l,e.elements[5]*=l,e.elements[6]*=l,e.elements[8]*=T,e.elements[9]*=T,e.elements[10]*=T,n.setFromRotationMatrix(e),s.x=d,s.y=p,s.z=_,this}}(),makePerspective:function(t,e,i,n,s,l){var d=this.elements;return d[0]=2*s/(e-t),d[4]=0,d[8]=(e+t)/(e-t),d[12]=0,d[1]=0,d[5]=2*s/(i-n),d[9]=(i+n)/(i-n),d[13]=0,d[2]=0,d[6]=0,d[10]=-(l+s)/(l-s),d[14]=-2*l*s/(l-s),d[3]=0,d[7]=0,d[11]=-1,d[15]=0,this},makeOrthographic:function(t,e,i,n,s,l){var d=this.elements,p=1/(e-t),_=1/(i-n),T=1/(l-s);return d[0]=2*p,d[4]=0,d[8]=0,d[12]=-((e+t)*p),d[1]=0,d[5]=2*_,d[9]=0,d[13]=-((i+n)*_),d[2]=0,d[6]=0,d[10]=-2*T,d[14]=-((l+s)*T),d[3]=0,d[7]=0,d[11]=0,d[15]=1,this},equals:function(t){var e=this.elements;t=t.elements;for(var i=0;16>i;i++)if(e[i]!==t[i])return!1;return!0},fromArray:function(t,e){e===void 0&&(e=0);for(var i=0;16>i;i++)this.elements[i]=t[i+e];return this},toArray:function(t,e){t===void 0&&(t=[]),e===void 0&&(e=0);var i=this.elements;return t[e]=i[0],t[e+1]=i[1],t[e+2]=i[2],t[e+3]=i[3],t[e+4]=i[4],t[e+5]=i[5],t[e+6]=i[6],t[e+7]=i[7],t[e+8]=i[8],t[e+9]=i[9],t[e+10]=i[10],t[e+11]=i[11],t[e+12]=i[12],t[e+13]=i[13],t[e+14]=i[14],t[e+15]=i[15],t}}),Object.assign(f,{slerp:function(t,e,i,n){return i.copy(t).slerp(e,n)},slerpFlat:function(t,e,i,n,s,l,d){var p=i[n+0],_=i[n+1],T=i[n+2];i=i[n+3],n=s[l+0];var A=s[l+1],L=s[l+2];if(s=s[l+3],i!==s||p!==n||_!==A||T!==L){l=1-d;var B=p*n+_*A+T*L+i*s,H=0<=B?1:-1,q=1-B*B;q>Number.EPSILON&&(q=Math.sqrt(q),B=Math.atan2(q,B*H),l=Math.sin(l*B)/q,d=Math.sin(d*B)/q),H*=d,p=p*l+n*H,_=_*l+A*H,T=T*l+L*H,i=i*l+s*H,l===1-d&&(d=1/Math.sqrt(p*p+_*_+T*T+i*i),p*=d,_*=d,T*=d,i*=d)}t[e]=p,t[e+1]=_,t[e+2]=T,t[e+3]=i}}),Object.defineProperties(f.prototype,{x:{get:function(){return this._x},set:function(t){this._x=t,this.onChangeCallback()}},y:{get:function(){return this._y},set:function(t){this._y=t,this.onChangeCallback()}},z:{get:function(){return this._z},set:function(t){this._z=t,this.onChangeCallback()}},w:{get:function(){return this._w},set:function(t){this._w=t,this.onChangeCallback()}}}),Object.assign(f.prototype,{isQuaternion:!0,set:function(t,e,i,n){return this._x=t,this._y=e,this._z=i,this._w=n,this.onChangeCallback(),this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._w)},copy:function(t){return this._x=t.x,this._y=t.y,this._z=t.z,this._w=t.w,this.onChangeCallback(),this},setFromEuler:function(t,e){if(!t||!t.isEuler)throw Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");var i=t._x,n=t._y,s=t._z;t=t.order;var l=Math.cos,d=Math.sin,p=l(i/2),_=l(n/2);return l=l(s/2),i=d(i/2),n=d(n/2),s=d(s/2),t==="XYZ"?(this._x=i*_*l+p*n*s,this._y=p*n*l-i*_*s,this._z=p*_*s+i*n*l,this._w=p*_*l-i*n*s):t==="YXZ"?(this._x=i*_*l+p*n*s,this._y=p*n*l-i*_*s,this._z=p*_*s-i*n*l,this._w=p*_*l+i*n*s):t==="ZXY"?(this._x=i*_*l-p*n*s,this._y=p*n*l+i*_*s,this._z=p*_*s+i*n*l,this._w=p*_*l-i*n*s):t==="ZYX"?(this._x=i*_*l-p*n*s,this._y=p*n*l+i*_*s,this._z=p*_*s-i*n*l,this._w=p*_*l+i*n*s):t==="YZX"?(this._x=i*_*l+p*n*s,this._y=p*n*l+i*_*s,this._z=p*_*s-i*n*l,this._w=p*_*l-i*n*s):t==="XZY"&&(this._x=i*_*l-p*n*s,this._y=p*n*l-i*_*s,this._z=p*_*s+i*n*l,this._w=p*_*l+i*n*s),e!==!1&&this.onChangeCallback(),this},setFromAxisAngle:function(t,e){e/=2;var i=Math.sin(e);return this._x=t.x*i,this._y=t.y*i,this._z=t.z*i,this._w=Math.cos(e),this.onChangeCallback(),this},setFromRotationMatrix:function(t){var e=t.elements,i=e[0];t=e[4];var n=e[8],s=e[1],l=e[5],d=e[9],p=e[2],_=e[6];e=e[10];var T=i+l+e;return 0<T?(i=.5/Math.sqrt(T+1),this._w=.25/i,this._x=(_-d)*i,this._y=(n-p)*i,this._z=(s-t)*i):i>l&&i>e?(i=2*Math.sqrt(1+i-l-e),this._w=(_-d)/i,this._x=.25*i,this._y=(t+s)/i,this._z=(n+p)/i):l>e?(i=2*Math.sqrt(1+l-i-e),this._w=(n-p)/i,this._x=(t+s)/i,this._y=.25*i,this._z=(d+_)/i):(i=2*Math.sqrt(1+e-i-l),this._w=(s-t)/i,this._x=(n+p)/i,this._y=(d+_)/i,this._z=.25*i),this.onChangeCallback(),this},setFromUnitVectors:function(){var t=new u,e;return function(i,n){return t===void 0&&(t=new u),e=i.dot(n)+1,1e-6>e?(e=0,Math.abs(i.x)>Math.abs(i.z)?t.set(-i.y,i.x,0):t.set(0,-i.z,i.y)):t.crossVectors(i,n),this._x=t.x,this._y=t.y,this._z=t.z,this._w=e,this.normalize()}}(),angleTo:function(t){return 2*Math.acos(Math.abs(di.clamp(this.dot(t),-1,1)))},rotateTowards:function(t,e){var i=this.angleTo(t);return i===0?this:(this.slerp(t,Math.min(1,e/i)),this)},inverse:function(){return this.conjugate()},conjugate:function(){return this._x*=-1,this._y*=-1,this._z*=-1,this.onChangeCallback(),this},dot:function(t){return this._x*t._x+this._y*t._y+this._z*t._z+this._w*t._w},lengthSq:function(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w},length:function(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)},normalize:function(){var t=this.length();return t===0?(this._z=this._y=this._x=0,this._w=1):(t=1/t,this._x*=t,this._y*=t,this._z*=t,this._w*=t),this.onChangeCallback(),this},multiply:function(t,e){return e!==void 0?this.multiplyQuaternions(t,e):this.multiplyQuaternions(this,t)},premultiply:function(t){return this.multiplyQuaternions(t,this)},multiplyQuaternions:function(t,e){var i=t._x,n=t._y,s=t._z;t=t._w;var l=e._x,d=e._y,p=e._z;return e=e._w,this._x=i*e+t*l+n*p-s*d,this._y=n*e+t*d+s*l-i*p,this._z=s*e+t*p+i*d-n*l,this._w=t*e-i*l-n*d-s*p,this.onChangeCallback(),this},slerp:function(t,e){if(e===0)return this;if(e===1)return this.copy(t);var i=this._x,n=this._y,s=this._z,l=this._w,d=l*t._w+i*t._x+n*t._y+s*t._z;if(0>d?(this._w=-t._w,this._x=-t._x,this._y=-t._y,this._z=-t._z,d=-d):this.copy(t),1<=d)return this._w=l,this._x=i,this._y=n,this._z=s,this;if(t=1-d*d,t<=Number.EPSILON)return d=1-e,this._w=d*l+e*this._w,this._x=d*i+e*this._x,this._y=d*n+e*this._y,this._z=d*s+e*this._z,this.normalize();t=Math.sqrt(t);var p=Math.atan2(t,d);return d=Math.sin((1-e)*p)/t,e=Math.sin(e*p)/t,this._w=l*d+this._w*e,this._x=i*d+this._x*e,this._y=n*d+this._y*e,this._z=s*d+this._z*e,this.onChangeCallback(),this},equals:function(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._w===this._w},fromArray:function(t,e){return e===void 0&&(e=0),this._x=t[e],this._y=t[e+1],this._z=t[e+2],this._w=t[e+3],this.onChangeCallback(),this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this._x,t[e+1]=this._y,t[e+2]=this._z,t[e+3]=this._w,t},onChange:function(t){return this.onChangeCallback=t,this},onChangeCallback:function(){}}),Object.assign(u.prototype,{isVector3:!0,set:function(t,e,i){return this.x=t,this.y=e,this.z=i,this},setScalar:function(t){return this.z=this.y=this.x=t,this},setX:function(t){return this.x=t,this},setY:function(t){return this.y=t,this},setZ:function(t){return this.z=t,this},setComponent:function(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;case 2:this.z=e;break;default:throw Error("index is out of range: "+t)}return this},getComponent:function(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw Error("index is out of range: "+t)}},clone:function(){return new this.constructor(this.x,this.y,this.z)},copy:function(t){return this.x=t.x,this.y=t.y,this.z=t.z,this},add:function(t,e){return e!==void 0?this.addVectors(t,e):(this.x+=t.x,this.y+=t.y,this.z+=t.z,this)},addScalar:function(t){return this.x+=t,this.y+=t,this.z+=t,this},addVectors:function(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this.z=t.z+e.z,this},addScaledVector:function(t,e){return this.x+=t.x*e,this.y+=t.y*e,this.z+=t.z*e,this},sub:function(t,e){return e!==void 0?this.subVectors(t,e):(this.x-=t.x,this.y-=t.y,this.z-=t.z,this)},subScalar:function(t){return this.x-=t,this.y-=t,this.z-=t,this},subVectors:function(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this.z=t.z-e.z,this},multiply:function(t,e){return e!==void 0?this.multiplyVectors(t,e):(this.x*=t.x,this.y*=t.y,this.z*=t.z,this)},multiplyScalar:function(t){return this.x*=t,this.y*=t,this.z*=t,this},multiplyVectors:function(t,e){return this.x=t.x*e.x,this.y=t.y*e.y,this.z=t.z*e.z,this},applyEuler:function(){var t=new f;return function(e){return e&&e.isEuler,this.applyQuaternion(t.setFromEuler(e))}}(),applyAxisAngle:function(){var t=new f;return function(e,i){return this.applyQuaternion(t.setFromAxisAngle(e,i))}}(),applyMatrix3:function(t){var e=this.x,i=this.y,n=this.z;return t=t.elements,this.x=t[0]*e+t[3]*i+t[6]*n,this.y=t[1]*e+t[4]*i+t[7]*n,this.z=t[2]*e+t[5]*i+t[8]*n,this},applyMatrix4:function(t){var e=this.x,i=this.y,n=this.z;t=t.elements;var s=1/(t[3]*e+t[7]*i+t[11]*n+t[15]);return this.x=(t[0]*e+t[4]*i+t[8]*n+t[12])*s,this.y=(t[1]*e+t[5]*i+t[9]*n+t[13])*s,this.z=(t[2]*e+t[6]*i+t[10]*n+t[14])*s,this},applyQuaternion:function(t){var e=this.x,i=this.y,n=this.z,s=t.x,l=t.y,d=t.z;t=t.w;var p=t*e+l*n-d*i,_=t*i+d*e-s*n,T=t*n+s*i-l*e;return e=-s*e-l*i-d*n,this.x=p*t+e*-s+_*-d-T*-l,this.y=_*t+e*-l+T*-s-p*-d,this.z=T*t+e*-d+p*-l-_*-s,this},project:function(t){return this.applyMatrix4(t.matrixWorldInverse).applyMatrix4(t.projectionMatrix)},unproject:function(){var t=new c;return function(e){return this.applyMatrix4(t.getInverse(e.projectionMatrix)).applyMatrix4(e.matrixWorld)}}(),transformDirection:function(t){var e=this.x,i=this.y,n=this.z;return t=t.elements,this.x=t[0]*e+t[4]*i+t[8]*n,this.y=t[1]*e+t[5]*i+t[9]*n,this.z=t[2]*e+t[6]*i+t[10]*n,this.normalize()},divide:function(t){return this.x/=t.x,this.y/=t.y,this.z/=t.z,this},divideScalar:function(t){return this.multiplyScalar(1/t)},min:function(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.z=Math.min(this.z,t.z),this},max:function(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this.z=Math.max(this.z,t.z),this},clamp:function(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this.z=Math.max(t.z,Math.min(e.z,this.z)),this},clampScalar:function(){var t=new u,e=new u;return function(i,n){return t.set(i,i,i),e.set(n,n,n),this.clamp(t,e)}}(),clampLength:function(t,e){var i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(t,Math.min(e,i)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this},roundToZero:function(){return this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x),this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y),this.z=0>this.z?Math.ceil(this.z):Math.floor(this.z),this},negate:function(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this},dot:function(t){return this.x*t.x+this.y*t.y+this.z*t.z},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)},normalize:function(){return this.divideScalar(this.length()||1)},setLength:function(t){return this.normalize().multiplyScalar(t)},lerp:function(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this.z+=(t.z-this.z)*e,this},lerpVectors:function(t,e,i){return this.subVectors(e,t).multiplyScalar(i).add(t)},cross:function(t,e){return e!==void 0?this.crossVectors(t,e):this.crossVectors(this,t)},crossVectors:function(t,e){var i=t.x,n=t.y;t=t.z;var s=e.x,l=e.y;return e=e.z,this.x=n*e-t*l,this.y=t*s-i*e,this.z=i*l-n*s,this},projectOnVector:function(t){var e=t.dot(this)/t.lengthSq();return this.copy(t).multiplyScalar(e)},projectOnPlane:function(){var t=new u;return function(e){return t.copy(this).projectOnVector(e),this.sub(t)}}(),reflect:function(){var t=new u;return function(e){return this.sub(t.copy(e).multiplyScalar(2*this.dot(e)))}}(),angleTo:function(t){return t=this.dot(t)/Math.sqrt(this.lengthSq()*t.lengthSq()),Math.acos(di.clamp(t,-1,1))},distanceTo:function(t){return Math.sqrt(this.distanceToSquared(t))},distanceToSquared:function(t){var e=this.x-t.x,i=this.y-t.y;return t=this.z-t.z,e*e+i*i+t*t},manhattanDistanceTo:function(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)+Math.abs(this.z-t.z)},setFromSpherical:function(t){return this.setFromSphericalCoords(t.radius,t.phi,t.theta)},setFromSphericalCoords:function(t,e,i){var n=Math.sin(e)*t;return this.x=n*Math.sin(i),this.y=Math.cos(e)*t,this.z=n*Math.cos(i),this},setFromCylindrical:function(t){return this.setFromCylindricalCoords(t.radius,t.theta,t.y)},setFromCylindricalCoords:function(t,e,i){return this.x=t*Math.sin(e),this.y=i,this.z=t*Math.cos(e),this},setFromMatrixPosition:function(t){return t=t.elements,this.x=t[12],this.y=t[13],this.z=t[14],this},setFromMatrixScale:function(t){var e=this.setFromMatrixColumn(t,0).length(),i=this.setFromMatrixColumn(t,1).length();return t=this.setFromMatrixColumn(t,2).length(),this.x=e,this.y=i,this.z=t,this},setFromMatrixColumn:function(t,e){return this.fromArray(t.elements,4*e)},equals:function(t){return t.x===this.x&&t.y===this.y&&t.z===this.z},fromArray:function(t,e){return e===void 0&&(e=0),this.x=t[e],this.y=t[e+1],this.z=t[e+2],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.x,t[e+1]=this.y,t[e+2]=this.z,t},fromBufferAttribute:function(t,e,i){return this.x=t.getX(e),this.y=t.getY(e),this.z=t.getZ(e),this}}),Object.assign(m.prototype,{isMatrix3:!0,set:function(t,e,i,n,s,l,d,p,_){var T=this.elements;return T[0]=t,T[1]=n,T[2]=d,T[3]=e,T[4]=s,T[5]=p,T[6]=i,T[7]=l,T[8]=_,this},identity:function(){return this.set(1,0,0,0,1,0,0,0,1),this},clone:function(){return new this.constructor().fromArray(this.elements)},copy:function(t){var e=this.elements;return t=t.elements,e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],this},setFromMatrix4:function(t){return t=t.elements,this.set(t[0],t[4],t[8],t[1],t[5],t[9],t[2],t[6],t[10]),this},applyToBufferAttribute:function(){var t=new u;return function(e){for(var i=0,n=e.count;i<n;i++)t.x=e.getX(i),t.y=e.getY(i),t.z=e.getZ(i),t.applyMatrix3(this),e.setXYZ(i,t.x,t.y,t.z);return e}}(),multiply:function(t){return this.multiplyMatrices(this,t)},premultiply:function(t){return this.multiplyMatrices(t,this)},multiplyMatrices:function(t,e){var i=t.elements,n=e.elements;e=this.elements,t=i[0];var s=i[3],l=i[6],d=i[1],p=i[4],_=i[7],T=i[2],A=i[5];i=i[8];var L=n[0],B=n[3],H=n[6],q=n[1],$=n[4],rt=n[7],xt=n[2],gt=n[5];return n=n[8],e[0]=t*L+s*q+l*xt,e[3]=t*B+s*$+l*gt,e[6]=t*H+s*rt+l*n,e[1]=d*L+p*q+_*xt,e[4]=d*B+p*$+_*gt,e[7]=d*H+p*rt+_*n,e[2]=T*L+A*q+i*xt,e[5]=T*B+A*$+i*gt,e[8]=T*H+A*rt+i*n,this},multiplyScalar:function(t){var e=this.elements;return e[0]*=t,e[3]*=t,e[6]*=t,e[1]*=t,e[4]*=t,e[7]*=t,e[2]*=t,e[5]*=t,e[8]*=t,this},determinant:function(){var t=this.elements,e=t[0],i=t[1],n=t[2],s=t[3],l=t[4],d=t[5],p=t[6],_=t[7];return t=t[8],e*l*t-e*d*_-i*s*t+i*d*p+n*s*_-n*l*p},getInverse:function(t,e){t&&t.isMatrix4;var i=t.elements;t=this.elements;var n=i[0],s=i[1],l=i[2],d=i[3],p=i[4],_=i[5],T=i[6],A=i[7];i=i[8];var L=i*p-_*A,B=_*T-i*d,H=A*d-p*T,q=n*L+s*B+l*H;if(q===0){if(e===!0)throw Error("THREE.Matrix3: .getInverse() can't invert matrix, determinant is 0");return this.identity()}return e=1/q,t[0]=L*e,t[1]=(l*A-i*s)*e,t[2]=(_*s-l*p)*e,t[3]=B*e,t[4]=(i*n-l*T)*e,t[5]=(l*d-_*n)*e,t[6]=H*e,t[7]=(s*T-A*n)*e,t[8]=(p*n-s*d)*e,this},transpose:function(){var t=this.elements,e=t[1];return t[1]=t[3],t[3]=e,e=t[2],t[2]=t[6],t[6]=e,e=t[5],t[5]=t[7],t[7]=e,this},getNormalMatrix:function(t){return this.setFromMatrix4(t).getInverse(this).transpose()},transposeIntoArray:function(t){var e=this.elements;return t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8],this},setUvTransform:function(t,e,i,n,s,l,d){var p=Math.cos(s);s=Math.sin(s),this.set(i*p,i*s,-i*(p*l+s*d)+l+t,-n*s,n*p,-n*(-s*l+p*d)+d+e,0,0,1)},scale:function(t,e){var i=this.elements;return i[0]*=t,i[3]*=t,i[6]*=t,i[1]*=e,i[4]*=e,i[7]*=e,this},rotate:function(t){var e=Math.cos(t);t=Math.sin(t);var i=this.elements,n=i[0],s=i[3],l=i[6],d=i[1],p=i[4],_=i[7];return i[0]=e*n+t*d,i[3]=e*s+t*p,i[6]=e*l+t*_,i[1]=-t*n+e*d,i[4]=-t*s+e*p,i[7]=-t*l+e*_,this},translate:function(t,e){var i=this.elements;return i[0]+=t*i[2],i[3]+=t*i[5],i[6]+=t*i[8],i[1]+=e*i[2],i[4]+=e*i[5],i[7]+=e*i[8],this},equals:function(t){var e=this.elements;t=t.elements;for(var i=0;9>i;i++)if(e[i]!==t[i])return!1;return!0},fromArray:function(t,e){e===void 0&&(e=0);for(var i=0;9>i;i++)this.elements[i]=t[i+e];return this},toArray:function(t,e){t===void 0&&(t=[]),e===void 0&&(e=0);var i=this.elements;return t[e]=i[0],t[e+1]=i[1],t[e+2]=i[2],t[e+3]=i[3],t[e+4]=i[4],t[e+5]=i[5],t[e+6]=i[6],t[e+7]=i[7],t[e+8]=i[8],t}});var as={getDataURL:function(t){if(typeof HTMLCanvasElement>"u")return t.src;if(t instanceof HTMLCanvasElement)var e=t;else{e=document.createElementNS("http://www.w3.org/1999/xhtml","canvas"),e.width=t.width,e.height=t.height;var i=e.getContext("2d");t instanceof ImageData?i.putImageData(t,0,0):i.drawImage(t,0,0,t.width,t.height)}return 2048<e.width||2048<e.height?e.toDataURL("image/jpeg",.6):e.toDataURL("image/png")}},Us=0;g.DEFAULT_IMAGE=void 0,g.DEFAULT_MAPPING=300,g.prototype=Object.assign(Object.create(a.prototype),{constructor:g,isTexture:!0,updateMatrix:function(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.name=t.name,this.image=t.image,this.mipmaps=t.mipmaps.slice(0),this.mapping=t.mapping,this.wrapS=t.wrapS,this.wrapT=t.wrapT,this.magFilter=t.magFilter,this.minFilter=t.minFilter,this.anisotropy=t.anisotropy,this.format=t.format,this.type=t.type,this.offset.copy(t.offset),this.repeat.copy(t.repeat),this.center.copy(t.center),this.rotation=t.rotation,this.matrixAutoUpdate=t.matrixAutoUpdate,this.matrix.copy(t.matrix),this.generateMipmaps=t.generateMipmaps,this.premultiplyAlpha=t.premultiplyAlpha,this.flipY=t.flipY,this.unpackAlignment=t.unpackAlignment,this.encoding=t.encoding,this},toJSON:function(t){var e=t===void 0||typeof t=="string";if(!e&&t.textures[this.uuid]!==void 0)return t.textures[this.uuid];var i={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY};if(this.image!==void 0){var n=this.image;if(n.uuid===void 0&&(n.uuid=di.generateUUID()),!e&&t.images[n.uuid]===void 0){if(Array.isArray(n))for(var s=[],l=0,d=n.length;l<d;l++)s.push(as.getDataURL(n[l]));else s=as.getDataURL(n);t.images[n.uuid]={uuid:n.uuid,url:s}}i.image=n.uuid}return e||(t.textures[this.uuid]=i),i},dispose:function(){this.dispatchEvent({type:"dispose"})},transformUv:function(t){if(this.mapping!==300)return t;if(t.applyMatrix3(this.matrix),0>t.x||1<t.x)switch(this.wrapS){case 1e3:t.x-=Math.floor(t.x);break;case 1001:t.x=0>t.x?0:1;break;case 1002:t.x=Math.abs(Math.floor(t.x)%2)===1?Math.ceil(t.x)-t.x:t.x-Math.floor(t.x)}if(0>t.y||1<t.y)switch(this.wrapT){case 1e3:t.y-=Math.floor(t.y);break;case 1001:t.y=0>t.y?0:1;break;case 1002:t.y=Math.abs(Math.floor(t.y)%2)===1?Math.ceil(t.y)-t.y:t.y-Math.floor(t.y)}return this.flipY&&(t.y=1-t.y),t}}),Object.defineProperty(g.prototype,"needsUpdate",{set:function(t){t===!0&&this.version++}}),Object.assign(v.prototype,{isVector4:!0,set:function(t,e,i,n){return this.x=t,this.y=e,this.z=i,this.w=n,this},setScalar:function(t){return this.w=this.z=this.y=this.x=t,this},setX:function(t){return this.x=t,this},setY:function(t){return this.y=t,this},setZ:function(t){return this.z=t,this},setW:function(t){return this.w=t,this},setComponent:function(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;case 2:this.z=e;break;case 3:this.w=e;break;default:throw Error("index is out of range: "+t)}return this},getComponent:function(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw Error("index is out of range: "+t)}},clone:function(){return new this.constructor(this.x,this.y,this.z,this.w)},copy:function(t){return this.x=t.x,this.y=t.y,this.z=t.z,this.w=t.w!==void 0?t.w:1,this},add:function(t,e){return e!==void 0?this.addVectors(t,e):(this.x+=t.x,this.y+=t.y,this.z+=t.z,this.w+=t.w,this)},addScalar:function(t){return this.x+=t,this.y+=t,this.z+=t,this.w+=t,this},addVectors:function(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this.z=t.z+e.z,this.w=t.w+e.w,this},addScaledVector:function(t,e){return this.x+=t.x*e,this.y+=t.y*e,this.z+=t.z*e,this.w+=t.w*e,this},sub:function(t,e){return e!==void 0?this.subVectors(t,e):(this.x-=t.x,this.y-=t.y,this.z-=t.z,this.w-=t.w,this)},subScalar:function(t){return this.x-=t,this.y-=t,this.z-=t,this.w-=t,this},subVectors:function(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this.z=t.z-e.z,this.w=t.w-e.w,this},multiplyScalar:function(t){return this.x*=t,this.y*=t,this.z*=t,this.w*=t,this},applyMatrix4:function(t){var e=this.x,i=this.y,n=this.z,s=this.w;return t=t.elements,this.x=t[0]*e+t[4]*i+t[8]*n+t[12]*s,this.y=t[1]*e+t[5]*i+t[9]*n+t[13]*s,this.z=t[2]*e+t[6]*i+t[10]*n+t[14]*s,this.w=t[3]*e+t[7]*i+t[11]*n+t[15]*s,this},divideScalar:function(t){return this.multiplyScalar(1/t)},setAxisAngleFromQuaternion:function(t){this.w=2*Math.acos(t.w);var e=Math.sqrt(1-t.w*t.w);return 1e-4>e?(this.x=1,this.z=this.y=0):(this.x=t.x/e,this.y=t.y/e,this.z=t.z/e),this},setAxisAngleFromRotationMatrix:function(t){t=t.elements;var e=t[0],i=t[4],n=t[8],s=t[1],l=t[5],d=t[9],p=t[2],_=t[6],T=t[10];return .01>Math.abs(i-s)&&.01>Math.abs(n-p)&&.01>Math.abs(d-_)?.1>Math.abs(i+s)&&.1>Math.abs(n+p)&&.1>Math.abs(d+_)&&.1>Math.abs(e+l+T-3)?(this.set(1,0,0,0),this):(t=Math.PI,e=(e+1)/2,l=(l+1)/2,T=(T+1)/2,i=(i+s)/4,n=(n+p)/4,d=(d+_)/4,e>l&&e>T?.01>e?(_=0,i=p=.707106781):(_=Math.sqrt(e),p=i/_,i=n/_):l>T?.01>l?(_=.707106781,p=0,i=.707106781):(p=Math.sqrt(l),_=i/p,i=d/p):.01>T?(p=_=.707106781,i=0):(i=Math.sqrt(T),_=n/i,p=d/i),this.set(_,p,i,t),this):(t=Math.sqrt((_-d)*(_-d)+(n-p)*(n-p)+(s-i)*(s-i)),.001>Math.abs(t)&&(t=1),this.x=(_-d)/t,this.y=(n-p)/t,this.z=(s-i)/t,this.w=Math.acos((e+l+T-1)/2),this)},min:function(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.z=Math.min(this.z,t.z),this.w=Math.min(this.w,t.w),this},max:function(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this.z=Math.max(this.z,t.z),this.w=Math.max(this.w,t.w),this},clamp:function(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this.z=Math.max(t.z,Math.min(e.z,this.z)),this.w=Math.max(t.w,Math.min(e.w,this.w)),this},clampScalar:function(){var t,e;return function(i,n){return t===void 0&&(t=new v,e=new v),t.set(i,i,i,i),e.set(n,n,n,n),this.clamp(t,e)}}(),clampLength:function(t,e){var i=this.length();return this.divideScalar(i||1).multiplyScalar(Math.max(t,Math.min(e,i)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this.w=Math.floor(this.w),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this.w=Math.ceil(this.w),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this.w=Math.round(this.w),this},roundToZero:function(){return this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x),this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y),this.z=0>this.z?Math.ceil(this.z):Math.floor(this.z),this.w=0>this.w?Math.ceil(this.w):Math.floor(this.w),this},negate:function(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this.w=-this.w,this},dot:function(t){return this.x*t.x+this.y*t.y+this.z*t.z+this.w*t.w},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)},normalize:function(){return this.divideScalar(this.length()||1)},setLength:function(t){return this.normalize().multiplyScalar(t)},lerp:function(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this.z+=(t.z-this.z)*e,this.w+=(t.w-this.w)*e,this},lerpVectors:function(t,e,i){return this.subVectors(e,t).multiplyScalar(i).add(t)},equals:function(t){return t.x===this.x&&t.y===this.y&&t.z===this.z&&t.w===this.w},fromArray:function(t,e){return e===void 0&&(e=0),this.x=t[e],this.y=t[e+1],this.z=t[e+2],this.w=t[e+3],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.x,t[e+1]=this.y,t[e+2]=this.z,t[e+3]=this.w,t},fromBufferAttribute:function(t,e,i){return this.x=t.getX(e),this.y=t.getY(e),this.z=t.getZ(e),this.w=t.getW(e),this}}),S.prototype=Object.assign(Object.create(a.prototype),{constructor:S,isWebGLRenderTarget:!0,setSize:function(t,e){(this.width!==t||this.height!==e)&&(this.width=t,this.height=e,this.dispose()),this.viewport.set(0,0,t,e),this.scissor.set(0,0,t,e)},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.width=t.width,this.height=t.height,this.viewport.copy(t.viewport),this.texture=t.texture.clone(),this.depthBuffer=t.depthBuffer,this.stencilBuffer=t.stencilBuffer,this.depthTexture=t.depthTexture,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),b.prototype=Object.create(S.prototype),b.prototype.constructor=b,b.prototype.isWebGLRenderTargetCube=!0,O.prototype=Object.create(g.prototype),O.prototype.constructor=O,O.prototype.isDataTexture=!0,Object.assign(k.prototype,{isBox3:!0,set:function(t,e){return this.min.copy(t),this.max.copy(e),this},setFromArray:function(t){for(var e=1/0,i=1/0,n=1/0,s=-1/0,l=-1/0,d=-1/0,p=0,_=t.length;p<_;p+=3){var T=t[p],A=t[p+1],L=t[p+2];T<e&&(e=T),A<i&&(i=A),L<n&&(n=L),T>s&&(s=T),A>l&&(l=A),L>d&&(d=L)}return this.min.set(e,i,n),this.max.set(s,l,d),this},setFromBufferAttribute:function(t){for(var e=1/0,i=1/0,n=1/0,s=-1/0,l=-1/0,d=-1/0,p=0,_=t.count;p<_;p++){var T=t.getX(p),A=t.getY(p),L=t.getZ(p);T<e&&(e=T),A<i&&(i=A),L<n&&(n=L),T>s&&(s=T),A>l&&(l=A),L>d&&(d=L)}return this.min.set(e,i,n),this.max.set(s,l,d),this},setFromPoints:function(t){this.makeEmpty();for(var e=0,i=t.length;e<i;e++)this.expandByPoint(t[e]);return this},setFromCenterAndSize:function(){var t=new u;return function(e,i){return i=t.copy(i).multiplyScalar(.5),this.min.copy(e).sub(i),this.max.copy(e).add(i),this}}(),setFromObject:function(t){return this.makeEmpty(),this.expandByObject(t)},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.min.copy(t.min),this.max.copy(t.max),this},makeEmpty:function(){return this.min.x=this.min.y=this.min.z=1/0,this.max.x=this.max.y=this.max.z=-1/0,this},isEmpty:function(){return this.max.x<this.min.x||this.max.y<this.min.y||this.max.z<this.min.z},getCenter:function(t){return t===void 0&&(t=new u),this.isEmpty()?t.set(0,0,0):t.addVectors(this.min,this.max).multiplyScalar(.5)},getSize:function(t){return t===void 0&&(t=new u),this.isEmpty()?t.set(0,0,0):t.subVectors(this.max,this.min)},expandByPoint:function(t){return this.min.min(t),this.max.max(t),this},expandByVector:function(t){return this.min.sub(t),this.max.add(t),this},expandByScalar:function(t){return this.min.addScalar(-t),this.max.addScalar(t),this},expandByObject:function(){function t(l){var d=l.geometry;if(d!==void 0){if(d.isGeometry)for(d=d.vertices,i=0,n=d.length;i<n;i++)s.copy(d[i]),s.applyMatrix4(l.matrixWorld),e.expandByPoint(s);else if(d.isBufferGeometry&&(d=d.attributes.position,d!==void 0))for(i=0,n=d.count;i<n;i++)s.fromBufferAttribute(d,i).applyMatrix4(l.matrixWorld),e.expandByPoint(s)}}var e,i,n,s=new u;return function(l){return e=this,l.updateMatrixWorld(!0),l.traverse(t),this}}(),containsPoint:function(t){return!(t.x<this.min.x||t.x>this.max.x||t.y<this.min.y||t.y>this.max.y||t.z<this.min.z||t.z>this.max.z)},containsBox:function(t){return this.min.x<=t.min.x&&t.max.x<=this.max.x&&this.min.y<=t.min.y&&t.max.y<=this.max.y&&this.min.z<=t.min.z&&t.max.z<=this.max.z},getParameter:function(t,e){return e===void 0&&(e=new u),e.set((t.x-this.min.x)/(this.max.x-this.min.x),(t.y-this.min.y)/(this.max.y-this.min.y),(t.z-this.min.z)/(this.max.z-this.min.z))},intersectsBox:function(t){return!(t.max.x<this.min.x||t.min.x>this.max.x||t.max.y<this.min.y||t.min.y>this.max.y||t.max.z<this.min.z||t.min.z>this.max.z)},intersectsSphere:function(){var t=new u;return function(e){return this.clampPoint(e.center,t),t.distanceToSquared(e.center)<=e.radius*e.radius}}(),intersectsPlane:function(t){if(0<t.normal.x)var e=t.normal.x*this.min.x,i=t.normal.x*this.max.x;else e=t.normal.x*this.max.x,i=t.normal.x*this.min.x;return 0<t.normal.y?(e+=t.normal.y*this.min.y,i+=t.normal.y*this.max.y):(e+=t.normal.y*this.max.y,i+=t.normal.y*this.min.y),0<t.normal.z?(e+=t.normal.z*this.min.z,i+=t.normal.z*this.max.z):(e+=t.normal.z*this.max.z,i+=t.normal.z*this.min.z),e<=-t.constant&&i>=-t.constant},intersectsTriangle:function(){function t(L){var B,H=0;for(B=L.length-3;H<=B;H+=3){p.fromArray(L,H);var q=T.x*Math.abs(p.x)+T.y*Math.abs(p.y)+T.z*Math.abs(p.z),$=e.dot(p),rt=i.dot(p),xt=n.dot(p);if(Math.max(-Math.max($,rt,xt),Math.min($,rt,xt))>q)return!1}return!0}var e=new u,i=new u,n=new u,s=new u,l=new u,d=new u,p=new u,_=new u,T=new u,A=new u;return function(L){return this.isEmpty()||(this.getCenter(_),T.subVectors(this.max,_),e.subVectors(L.a,_),i.subVectors(L.b,_),n.subVectors(L.c,_),s.subVectors(i,e),l.subVectors(n,i),d.subVectors(e,n),L=[0,-s.z,s.y,0,-l.z,l.y,0,-d.z,d.y,s.z,0,-s.x,l.z,0,-l.x,d.z,0,-d.x,-s.y,s.x,0,-l.y,l.x,0,-d.y,d.x,0],!t(L))||(L=[1,0,0,0,1,0,0,0,1],!t(L))?!1:(A.crossVectors(s,l),L=[A.x,A.y,A.z],t(L))}}(),clampPoint:function(t,e){return e===void 0&&(e=new u),e.copy(t).clamp(this.min,this.max)},distanceToPoint:function(){var t=new u;return function(e){return t.copy(e).clamp(this.min,this.max).sub(e).length()}}(),getBoundingSphere:function(){var t=new u;return function(e){return e===void 0&&(e=new I),this.getCenter(e.center),e.radius=.5*this.getSize(t).length(),e}}(),intersect:function(t){return this.min.max(t.min),this.max.min(t.max),this.isEmpty()&&this.makeEmpty(),this},union:function(t){return this.min.min(t.min),this.max.max(t.max),this},applyMatrix4:function(){var t=[new u,new u,new u,new u,new u,new u,new u,new u];return function(e){return this.isEmpty()?this:(t[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(e),t[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(e),t[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(e),t[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(e),t[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(e),t[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(e),t[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(e),t[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(e),this.setFromPoints(t),this)}}(),translate:function(t){return this.min.add(t),this.max.add(t),this},equals:function(t){return t.min.equals(this.min)&&t.max.equals(this.max)}}),Object.assign(I.prototype,{set:function(t,e){return this.center.copy(t),this.radius=e,this},setFromPoints:function(){var t=new k;return function(e,i){var n=this.center;i!==void 0?n.copy(i):t.setFromPoints(e).getCenter(n);for(var s=i=0,l=e.length;s<l;s++)i=Math.max(i,n.distanceToSquared(e[s]));return this.radius=Math.sqrt(i),this}}(),clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.center.copy(t.center),this.radius=t.radius,this},empty:function(){return 0>=this.radius},containsPoint:function(t){return t.distanceToSquared(this.center)<=this.radius*this.radius},distanceToPoint:function(t){return t.distanceTo(this.center)-this.radius},intersectsSphere:function(t){var e=this.radius+t.radius;return t.center.distanceToSquared(this.center)<=e*e},intersectsBox:function(t){return t.intersectsSphere(this)},intersectsPlane:function(t){return Math.abs(t.distanceToPoint(this.center))<=this.radius},clampPoint:function(t,e){var i=this.center.distanceToSquared(t);return e===void 0&&(e=new u),e.copy(t),i>this.radius*this.radius&&(e.sub(this.center).normalize(),e.multiplyScalar(this.radius).add(this.center)),e},getBoundingBox:function(t){return t===void 0&&(t=new k),t.set(this.center,this.center),t.expandByScalar(this.radius),t},applyMatrix4:function(t){return this.center.applyMatrix4(t),this.radius*=t.getMaxScaleOnAxis(),this},translate:function(t){return this.center.add(t),this},equals:function(t){return t.center.equals(this.center)&&t.radius===this.radius}}),Object.assign(F.prototype,{set:function(t,e){return this.normal.copy(t),this.constant=e,this},setComponents:function(t,e,i,n){return this.normal.set(t,e,i),this.constant=n,this},setFromNormalAndCoplanarPoint:function(t,e){return this.normal.copy(t),this.constant=-e.dot(this.normal),this},setFromCoplanarPoints:function(){var t=new u,e=new u;return function(i,n,s){return n=t.subVectors(s,n).cross(e.subVectors(i,n)).normalize(),this.setFromNormalAndCoplanarPoint(n,i),this}}(),clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.normal.copy(t.normal),this.constant=t.constant,this},normalize:function(){var t=1/this.normal.length();return this.normal.multiplyScalar(t),this.constant*=t,this},negate:function(){return this.constant*=-1,this.normal.negate(),this},distanceToPoint:function(t){return this.normal.dot(t)+this.constant},distanceToSphere:function(t){return this.distanceToPoint(t.center)-t.radius},projectPoint:function(t,e){return e===void 0&&(e=new u),e.copy(this.normal).multiplyScalar(-this.distanceToPoint(t)).add(t)},intersectLine:function(){var t=new u;return function(e,i){i===void 0&&(i=new u);var n=e.delta(t),s=this.normal.dot(n);if(s===0){if(this.distanceToPoint(e.start)===0)return i.copy(e.start)}else if(s=-(e.start.dot(this.normal)+this.constant)/s,!(0>s||1<s))return i.copy(n).multiplyScalar(s).add(e.start)}}(),intersectsLine:function(t){var e=this.distanceToPoint(t.start);return t=this.distanceToPoint(t.end),0>e&&0<t||0>t&&0<e},intersectsBox:function(t){return t.intersectsPlane(this)},intersectsSphere:function(t){return t.intersectsPlane(this)},coplanarPoint:function(t){return t===void 0&&(t=new u),t.copy(this.normal).multiplyScalar(-this.constant)},applyMatrix4:function(){var t=new u,e=new m;return function(i,n){return n=n||e.getNormalMatrix(i),i=this.coplanarPoint(t).applyMatrix4(i),n=this.normal.applyMatrix3(n).normalize(),this.constant=-i.dot(n),this}}(),translate:function(t){return this.constant-=t.dot(this.normal),this},equals:function(t){return t.normal.equals(this.normal)&&t.constant===this.constant}}),Object.assign(E.prototype,{set:function(t,e,i,n,s,l){var d=this.planes;return d[0].copy(t),d[1].copy(e),d[2].copy(i),d[3].copy(n),d[4].copy(s),d[5].copy(l),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){for(var e=this.planes,i=0;6>i;i++)e[i].copy(t.planes[i]);return this},setFromMatrix:function(t){var e=this.planes,i=t.elements;t=i[0];var n=i[1],s=i[2],l=i[3],d=i[4],p=i[5],_=i[6],T=i[7],A=i[8],L=i[9],B=i[10],H=i[11],q=i[12],$=i[13],rt=i[14];return i=i[15],e[0].setComponents(l-t,T-d,H-A,i-q).normalize(),e[1].setComponents(l+t,T+d,H+A,i+q).normalize(),e[2].setComponents(l+n,T+p,H+L,i+$).normalize(),e[3].setComponents(l-n,T-p,H-L,i-$).normalize(),e[4].setComponents(l-s,T-_,H-B,i-rt).normalize(),e[5].setComponents(l+s,T+_,H+B,i+rt).normalize(),this},intersectsObject:function(){var t=new I;return function(e){var i=e.geometry;return i.boundingSphere===null&&i.computeBoundingSphere(),t.copy(i.boundingSphere).applyMatrix4(e.matrixWorld),this.intersectsSphere(t)}}(),intersectsSprite:function(){var t=new I;return function(e){return t.center.set(0,0,0),t.radius=.7071067811865476,t.applyMatrix4(e.matrixWorld),this.intersectsSphere(t)}}(),intersectsSphere:function(t){var e=this.planes,i=t.center;t=-t.radius;for(var n=0;6>n;n++)if(e[n].distanceToPoint(i)<t)return!1;return!0},intersectsBox:function(){var t=new u;return function(e){for(var i=this.planes,n=0;6>n;n++){var s=i[n];if(t.x=0<s.normal.x?e.max.x:e.min.x,t.y=0<s.normal.y?e.max.y:e.min.y,t.z=0<s.normal.z?e.max.z:e.min.z,0>s.distanceToPoint(t))return!1}return!0}}(),containsPoint:function(t){for(var e=this.planes,i=0;6>i;i++)if(0>e[i].distanceToPoint(t))return!1;return!0}});var Ci={alphamap_fragment:`#ifdef USE_ALPHAMAP
|
|
286
286
|
diffuseColor.a *= texture2D( alphaMap, vUv ).g;
|
|
287
287
|
#endif
|
|
288
288
|
`,alphamap_pars_fragment:`#ifdef USE_ALPHAMAP
|
|
@@ -2567,21 +2567,21 @@ void main() {
|
|
|
2567
2567
|
#include <clipping_planes_vertex>
|
|
2568
2568
|
#include <fog_vertex>
|
|
2569
2569
|
}
|
|
2570
|
-
`},Bn={merge:function(t){for(var e={},i=0;i<t.length;i++){var n=this.clone(t[i]),s;for(s in n)e[s]=n[s]}return e},clone:function(t){var e={},i;for(i in t){e[i]={};for(var n in t[i]){var s=t[i][n];s&&(s.isColor||s.isMatrix3||s.isMatrix4||s.isVector2||s.isVector3||s.isVector4||s.isTexture)?e[i][n]=s.clone():Array.isArray(s)?e[i][n]=s.slice():e[i][n]=s}}return e}},Qr={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Object.assign(P.prototype,{isColor:!0,r:1,g:1,b:1,set:function(t){return t&&t.isColor?this.copy(t):typeof t=="number"?this.setHex(t):typeof t=="string"&&this.setStyle(t),this},setScalar:function(t){return this.b=this.g=this.r=t,this},setHex:function(t){return t=Math.floor(t),this.r=(t>>16&255)/255,this.g=(t>>8&255)/255,this.b=(t&255)/255,this},setRGB:function(t,e,i){return this.r=t,this.g=e,this.b=i,this},setHSL:function(){function t(e,i,n){return 0>n&&(n+=1),1<n&&--n,n<1/6?e+6*(i-e)*n:.5>n?i:n<2/3?e+6*(i-e)*(2/3-n):e}return function(e,i,n){return e=di.euclideanModulo(e,1),i=di.clamp(i,0,1),n=di.clamp(n,0,1),i===0?this.r=this.g=this.b=n:(i=.5>=n?n*(1+i):n+i-n*i,n=2*n-i,this.r=t(n,i,e+1/3),this.g=t(n,i,e),this.b=t(n,i,e-1/3)),this}}(),setStyle:function(t){function e(d){d!==void 0&&1>parseFloat(d)}var i;if(i=/^((?:rgb|hsl)a?)\(\s*([^\)]*)\)/.exec(t)){var n=i[2];switch(i[1]){case"rgb":case"rgba":if(i=/^(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(n))return this.r=Math.min(255,parseInt(i[1],10))/255,this.g=Math.min(255,parseInt(i[2],10))/255,this.b=Math.min(255,parseInt(i[3],10))/255,e(i[5]),this;if(i=/^(\d+)%\s*,\s*(\d+)%\s*,\s*(\d+)%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(n))return this.r=Math.min(100,parseInt(i[1],10))/100,this.g=Math.min(100,parseInt(i[2],10))/100,this.b=Math.min(100,parseInt(i[3],10))/100,e(i[5]),this;break;case"hsl":case"hsla":if(i=/^([0-9]*\.?[0-9]+)\s*,\s*(\d+)%\s*,\s*(\d+)%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(n)){n=parseFloat(i[1])/360;var s=parseInt(i[2],10)/100,l=parseInt(i[3],10)/100;return e(i[5]),this.setHSL(n,s,l)}}}else if(i=/^#([A-Fa-f0-9]+)$/.exec(t)){if(i=i[1],n=i.length,n===3)return this.r=parseInt(i.charAt(0)+i.charAt(0),16)/255,this.g=parseInt(i.charAt(1)+i.charAt(1),16)/255,this.b=parseInt(i.charAt(2)+i.charAt(2),16)/255,this;if(n===6)return this.r=parseInt(i.charAt(0)+i.charAt(1),16)/255,this.g=parseInt(i.charAt(2)+i.charAt(3),16)/255,this.b=parseInt(i.charAt(4)+i.charAt(5),16)/255,this}return t&&0<t.length&&(i=Qr[t],i!==void 0&&this.setHex(i)),this},clone:function(){return new this.constructor(this.r,this.g,this.b)},copy:function(t){return this.r=t.r,this.g=t.g,this.b=t.b,this},copyGammaToLinear:function(t,e){return e===void 0&&(e=2),this.r=Math.pow(t.r,e),this.g=Math.pow(t.g,e),this.b=Math.pow(t.b,e),this},copyLinearToGamma:function(t,e){return e===void 0&&(e=2),e=0<e?1/e:1,this.r=Math.pow(t.r,e),this.g=Math.pow(t.g,e),this.b=Math.pow(t.b,e),this},convertGammaToLinear:function(t){return this.copyGammaToLinear(this,t),this},convertLinearToGamma:function(t){return this.copyLinearToGamma(this,t),this},copySRGBToLinear:function(){function t(e){return .04045>e?.0773993808*e:Math.pow(.9478672986*e+.0521327014,2.4)}return function(e){return this.r=t(e.r),this.g=t(e.g),this.b=t(e.b),this}}(),copyLinearToSRGB:function(){function t(e){return .0031308>e?12.92*e:1.055*Math.pow(e,.41666)-.055}return function(e){return this.r=t(e.r),this.g=t(e.g),this.b=t(e.b),this}}(),convertSRGBToLinear:function(){return this.copySRGBToLinear(this),this},convertLinearToSRGB:function(){return this.copyLinearToSRGB(this),this},getHex:function(){return 255*this.r<<16^255*this.g<<8^255*this.b<<0},getHexString:function(){return("000000"+this.getHex().toString(16)).slice(-6)},getHSL:function(t){t===void 0&&(t={h:0,s:0,l:0});var e=this.r,i=this.g,n=this.b,s=Math.max(e,i,n),l=Math.min(e,i,n),d,p=(l+s)/2;if(l===s)l=d=0;else{var _=s-l;switch(l=.5>=p?_/(s+l):_/(2-s-l),s){case e:d=(i-n)/_+(i<n?6:0);break;case i:d=(n-e)/_+2;break;case n:d=(e-i)/_+4}d/=6}return t.h=d,t.s=l,t.l=p,t},getStyle:function(){return"rgb("+(255*this.r|0)+","+(255*this.g|0)+","+(255*this.b|0)+")"},offsetHSL:function(){var t={};return function(e,i,n){return this.getHSL(t),t.h+=e,t.s+=i,t.l+=n,this.setHSL(t.h,t.s,t.l),this}}(),add:function(t){return this.r+=t.r,this.g+=t.g,this.b+=t.b,this},addColors:function(t,e){return this.r=t.r+e.r,this.g=t.g+e.g,this.b=t.b+e.b,this},addScalar:function(t){return this.r+=t,this.g+=t,this.b+=t,this},sub:function(t){return this.r=Math.max(0,this.r-t.r),this.g=Math.max(0,this.g-t.g),this.b=Math.max(0,this.b-t.b),this},multiply:function(t){return this.r*=t.r,this.g*=t.g,this.b*=t.b,this},multiplyScalar:function(t){return this.r*=t,this.g*=t,this.b*=t,this},lerp:function(t,e){return this.r+=(t.r-this.r)*e,this.g+=(t.g-this.g)*e,this.b+=(t.b-this.b)*e,this},lerpHSL:function(){var t={h:0,s:0,l:0},e={h:0,s:0,l:0};return function(i,n){this.getHSL(t),i.getHSL(e),i=di.lerp(t.h,e.h,n);var s=di.lerp(t.s,e.s,n);return n=di.lerp(t.l,e.l,n),this.setHSL(i,s,n),this}}(),equals:function(t){return t.r===this.r&&t.g===this.g&&t.b===this.b},fromArray:function(t,e){return e===void 0&&(e=0),this.r=t[e],this.g=t[e+1],this.b=t[e+2],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.r,t[e+1]=this.g,t[e+2]=this.b,t},toJSON:function(){return this.getHex()}});var qe={common:{diffuse:{value:new P(15658734)},opacity:{value:1},map:{value:null},uvTransform:{value:new m},alphaMap:{value:null}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new o(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new P(16777215)}},lights:{ambientLightColor:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}}},points:{diffuse:{value:new P(15658734)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},uvTransform:{value:new m}},sprite:{diffuse:{value:new P(15658734)},opacity:{value:1},center:{value:new o(.5,.5)},rotation:{value:0},map:{value:null},uvTransform:{value:new m}}},wo={basic:{uniforms:Bn.merge([qe.common,qe.specularmap,qe.envmap,qe.aomap,qe.lightmap,qe.fog]),vertexShader:Ci.meshbasic_vert,fragmentShader:Ci.meshbasic_frag},lambert:{uniforms:Bn.merge([qe.common,qe.specularmap,qe.envmap,qe.aomap,qe.lightmap,qe.emissivemap,qe.fog,qe.lights,{emissive:{value:new P(0)}}]),vertexShader:Ci.meshlambert_vert,fragmentShader:Ci.meshlambert_frag},phong:{uniforms:Bn.merge([qe.common,qe.specularmap,qe.envmap,qe.aomap,qe.lightmap,qe.emissivemap,qe.bumpmap,qe.normalmap,qe.displacementmap,qe.gradientmap,qe.fog,qe.lights,{emissive:{value:new P(0)},specular:{value:new P(1118481)},shininess:{value:30}}]),vertexShader:Ci.meshphong_vert,fragmentShader:Ci.meshphong_frag},standard:{uniforms:Bn.merge([qe.common,qe.envmap,qe.aomap,qe.lightmap,qe.emissivemap,qe.bumpmap,qe.normalmap,qe.displacementmap,qe.roughnessmap,qe.metalnessmap,qe.fog,qe.lights,{emissive:{value:new P(0)},roughness:{value:.5},metalness:{value:.5},envMapIntensity:{value:1}}]),vertexShader:Ci.meshphysical_vert,fragmentShader:Ci.meshphysical_frag},matcap:{uniforms:Bn.merge([qe.common,qe.bumpmap,qe.normalmap,qe.displacementmap,qe.fog,{matcap:{value:null}}]),vertexShader:Ci.meshmatcap_vert,fragmentShader:Ci.meshmatcap_frag},points:{uniforms:Bn.merge([qe.points,qe.fog]),vertexShader:Ci.points_vert,fragmentShader:Ci.points_frag},dashed:{uniforms:Bn.merge([qe.common,qe.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:Ci.linedashed_vert,fragmentShader:Ci.linedashed_frag},depth:{uniforms:Bn.merge([qe.common,qe.displacementmap]),vertexShader:Ci.depth_vert,fragmentShader:Ci.depth_frag},normal:{uniforms:Bn.merge([qe.common,qe.bumpmap,qe.normalmap,qe.displacementmap,{opacity:{value:1}}]),vertexShader:Ci.normal_vert,fragmentShader:Ci.normal_frag},sprite:{uniforms:Bn.merge([qe.sprite,qe.fog]),vertexShader:Ci.sprite_vert,fragmentShader:Ci.sprite_frag},background:{uniforms:{uvTransform:{value:new m},t2D:{value:null}},vertexShader:Ci.background_vert,fragmentShader:Ci.background_frag},cube:{uniforms:{tCube:{value:null},tFlip:{value:-1},opacity:{value:1}},vertexShader:Ci.cube_vert,fragmentShader:Ci.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:Ci.equirect_vert,fragmentShader:Ci.equirect_frag},distanceRGBA:{uniforms:Bn.merge([qe.common,qe.displacementmap,{referencePosition:{value:new u},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:Ci.distanceRGBA_vert,fragmentShader:Ci.distanceRGBA_frag},shadow:{uniforms:Bn.merge([qe.lights,qe.fog,{color:{value:new P(0)},opacity:{value:1}}]),vertexShader:Ci.shadow_vert,fragmentShader:Ci.shadow_frag}};wo.physical={uniforms:Bn.merge([wo.standard.uniforms,{clearCoat:{value:0},clearCoatRoughness:{value:0}}]),vertexShader:Ci.meshphysical_vert,fragmentShader:Ci.meshphysical_frag},Object.assign(R.prototype,{clone:function(){return new this.constructor().copy(this)},copy:function(t){this.a=t.a,this.b=t.b,this.c=t.c,this.normal.copy(t.normal),this.color.copy(t.color),this.materialIndex=t.materialIndex;for(var e=0,i=t.vertexNormals.length;e<i;e++)this.vertexNormals[e]=t.vertexNormals[e].clone();for(e=0,i=t.vertexColors.length;e<i;e++)this.vertexColors[e]=t.vertexColors[e].clone();return this}}),C.RotationOrders="XYZ YZX ZXY XZY YXZ ZYX".split(" "),C.DefaultOrder="XYZ",Object.defineProperties(C.prototype,{x:{get:function(){return this._x},set:function(t){this._x=t,this.onChangeCallback()}},y:{get:function(){return this._y},set:function(t){this._y=t,this.onChangeCallback()}},z:{get:function(){return this._z},set:function(t){this._z=t,this.onChangeCallback()}},order:{get:function(){return this._order},set:function(t){this._order=t,this.onChangeCallback()}}}),Object.assign(C.prototype,{isEuler:!0,set:function(t,e,i,n){return this._x=t,this._y=e,this._z=i,this._order=n||this._order,this.onChangeCallback(),this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._order)},copy:function(t){return this._x=t._x,this._y=t._y,this._z=t._z,this._order=t._order,this.onChangeCallback(),this},setFromRotationMatrix:function(t,e,i){var n=di.clamp,s=t.elements;t=s[0];var l=s[4],d=s[8],p=s[1],_=s[5],T=s[9],A=s[2],L=s[6];return s=s[10],e=e||this._order,e==="XYZ"?(this._y=Math.asin(n(d,-1,1)),.99999>Math.abs(d)?(this._x=Math.atan2(-T,s),this._z=Math.atan2(-l,t)):(this._x=Math.atan2(L,_),this._z=0)):e==="YXZ"?(this._x=Math.asin(-n(T,-1,1)),.99999>Math.abs(T)?(this._y=Math.atan2(d,s),this._z=Math.atan2(p,_)):(this._y=Math.atan2(-A,t),this._z=0)):e==="ZXY"?(this._x=Math.asin(n(L,-1,1)),.99999>Math.abs(L)?(this._y=Math.atan2(-A,s),this._z=Math.atan2(-l,_)):(this._y=0,this._z=Math.atan2(p,t))):e==="ZYX"?(this._y=Math.asin(-n(A,-1,1)),.99999>Math.abs(A)?(this._x=Math.atan2(L,s),this._z=Math.atan2(p,t)):(this._x=0,this._z=Math.atan2(-l,_))):e==="YZX"?(this._z=Math.asin(n(p,-1,1)),.99999>Math.abs(p)?(this._x=Math.atan2(-T,_),this._y=Math.atan2(-A,t)):(this._x=0,this._y=Math.atan2(d,s))):e==="XZY"&&(this._z=Math.asin(-n(l,-1,1)),.99999>Math.abs(l)?(this._x=Math.atan2(L,_),this._y=Math.atan2(d,t)):(this._x=Math.atan2(-T,s),this._y=0)),this._order=e,i!==!1&&this.onChangeCallback(),this},setFromQuaternion:function(){var t=new c;return function(e,i,n){return t.makeRotationFromQuaternion(e),this.setFromRotationMatrix(t,i,n)}}(),setFromVector3:function(t,e){return this.set(t.x,t.y,t.z,e||this._order)},reorder:function(){var t=new f;return function(e){return t.setFromEuler(this),this.setFromQuaternion(t,e)}}(),equals:function(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._order===this._order},fromArray:function(t){return this._x=t[0],this._y=t[1],this._z=t[2],t[3]!==void 0&&(this._order=t[3]),this.onChangeCallback(),this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this._x,t[e+1]=this._y,t[e+2]=this._z,t[e+3]=this._order,t},toVector3:function(t){return t?t.set(this._x,this._y,this._z):new u(this._x,this._y,this._z)},onChange:function(t){return this.onChangeCallback=t,this},onChangeCallback:function(){}}),Object.assign(U.prototype,{set:function(t){this.mask=1<<t|0},enable:function(t){this.mask=this.mask|1<<t|0},toggle:function(t){this.mask^=1<<t|0},disable:function(t){this.mask&=~(1<<t|0)},test:function(t){return(this.mask&t.mask)!==0}});var qc=0;F.DefaultUp=new u(0,1,0),F.DefaultMatrixAutoUpdate=!0,F.prototype=Object.assign(Object.create(a.prototype),{constructor:F,isObject3D:!0,onBeforeRender:function(){},onAfterRender:function(){},applyMatrix:function(t){this.matrix.multiplyMatrices(t,this.matrix),this.matrix.decompose(this.position,this.quaternion,this.scale)},applyQuaternion:function(t){return this.quaternion.premultiply(t),this},setRotationFromAxisAngle:function(t,e){this.quaternion.setFromAxisAngle(t,e)},setRotationFromEuler:function(t){this.quaternion.setFromEuler(t,!0)},setRotationFromMatrix:function(t){this.quaternion.setFromRotationMatrix(t)},setRotationFromQuaternion:function(t){this.quaternion.copy(t)},rotateOnAxis:function(){var t=new f;return function(e,i){return t.setFromAxisAngle(e,i),this.quaternion.multiply(t),this}}(),rotateOnWorldAxis:function(){var t=new f;return function(e,i){return t.setFromAxisAngle(e,i),this.quaternion.premultiply(t),this}}(),rotateX:function(){var t=new u(1,0,0);return function(e){return this.rotateOnAxis(t,e)}}(),rotateY:function(){var t=new u(0,1,0);return function(e){return this.rotateOnAxis(t,e)}}(),rotateZ:function(){var t=new u(0,0,1);return function(e){return this.rotateOnAxis(t,e)}}(),translateOnAxis:function(){var t=new u;return function(e,i){return t.copy(e).applyQuaternion(this.quaternion),this.position.add(t.multiplyScalar(i)),this}}(),translateX:function(){var t=new u(1,0,0);return function(e){return this.translateOnAxis(t,e)}}(),translateY:function(){var t=new u(0,1,0);return function(e){return this.translateOnAxis(t,e)}}(),translateZ:function(){var t=new u(0,0,1);return function(e){return this.translateOnAxis(t,e)}}(),localToWorld:function(t){return t.applyMatrix4(this.matrixWorld)},worldToLocal:function(){var t=new c;return function(e){return e.applyMatrix4(t.getInverse(this.matrixWorld))}}(),lookAt:function(){var t=new f,e=new c,i=new u,n=new u;return function(s,l,d){s.isVector3?i.copy(s):i.set(s,l,d),s=this.parent,this.updateWorldMatrix(!0,!1),n.setFromMatrixPosition(this.matrixWorld),this.isCamera?e.lookAt(n,i,this.up):e.lookAt(i,n,this.up),this.quaternion.setFromRotationMatrix(e),s&&(e.extractRotation(s.matrixWorld),t.setFromRotationMatrix(e),this.quaternion.premultiply(t.inverse()))}}(),add:function(t){if(1<arguments.length){for(var e=0;e<arguments.length;e++)this.add(arguments[e]);return this}return t===this?this:(t&&t.isObject3D&&(t.parent!==null&&t.parent.remove(t),t.parent=this,t.dispatchEvent({type:"added"}),this.children.push(t)),this)},remove:function(t){if(1<arguments.length){for(var e=0;e<arguments.length;e++)this.remove(arguments[e]);return this}return e=this.children.indexOf(t),e!==-1&&(t.parent=null,t.dispatchEvent({type:"removed"}),this.children.splice(e,1)),this},getObjectById:function(t){return this.getObjectByProperty("id",t)},getObjectByName:function(t){return this.getObjectByProperty("name",t)},getObjectByProperty:function(t,e){if(this[t]===e)return this;for(var i=0,n=this.children.length;i<n;i++){var s=this.children[i].getObjectByProperty(t,e);if(s!==void 0)return s}},getWorldPosition:function(t){return t===void 0&&(t=new u),this.updateMatrixWorld(!0),t.setFromMatrixPosition(this.matrixWorld)},getWorldQuaternion:function(){var t=new u,e=new u;return function(i){return i===void 0&&(i=new f),this.updateMatrixWorld(!0),this.matrixWorld.decompose(t,i,e),i}}(),getWorldScale:function(){var t=new u,e=new f;return function(i){return i===void 0&&(i=new u),this.updateMatrixWorld(!0),this.matrixWorld.decompose(t,e,i),i}}(),getWorldDirection:function(t){t===void 0&&(t=new u),this.updateMatrixWorld(!0);var e=this.matrixWorld.elements;return t.set(e[8],e[9],e[10]).normalize()},raycast:function(){},traverse:function(t){t(this);for(var e=this.children,i=0,n=e.length;i<n;i++)e[i].traverse(t)},traverseVisible:function(t){if(this.visible!==!1){t(this);for(var e=this.children,i=0,n=e.length;i<n;i++)e[i].traverseVisible(t)}},traverseAncestors:function(t){var e=this.parent;e!==null&&(t(e),e.traverseAncestors(t))},updateMatrix:function(){this.matrix.compose(this.position,this.quaternion,this.scale),this.matrixWorldNeedsUpdate=!0},updateMatrixWorld:function(t){this.matrixAutoUpdate&&this.updateMatrix(),(this.matrixWorldNeedsUpdate||t)&&(this.parent===null?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix),this.matrixWorldNeedsUpdate=!1,t=!0);for(var e=this.children,i=0,n=e.length;i<n;i++)e[i].updateMatrixWorld(t)},updateWorldMatrix:function(t,e){var i=this.parent;if(t===!0&&i!==null&&i.updateWorldMatrix(!0,!1),this.matrixAutoUpdate&&this.updateMatrix(),this.parent===null?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix),e===!0)for(t=this.children,e=0,i=t.length;e<i;e++)t[e].updateWorldMatrix(!1,!0)},toJSON:function(t){function e(A,L){return A[L.uuid]===void 0&&(A[L.uuid]=L.toJSON(t)),L.uuid}function i(A){var L=[],B;for(B in A){var H=A[B];delete H.metadata,L.push(H)}return L}var n=t===void 0||typeof t=="string",s={};n&&(t={geometries:{},materials:{},textures:{},images:{},shapes:{}},s.metadata={version:4.5,type:"Object",generator:"Object3D.toJSON"});var l={};if(l.uuid=this.uuid,l.type=this.type,this.name!==""&&(l.name=this.name),this.castShadow===!0&&(l.castShadow=!0),this.receiveShadow===!0&&(l.receiveShadow=!0),this.visible===!1&&(l.visible=!1),this.frustumCulled===!1&&(l.frustumCulled=!1),this.renderOrder!==0&&(l.renderOrder=this.renderOrder),JSON.stringify(this.userData)!=="{}"&&(l.userData=this.userData),l.layers=this.layers.mask,l.matrix=this.matrix.toArray(),this.matrixAutoUpdate===!1&&(l.matrixAutoUpdate=!1),this.isMesh||this.isLine||this.isPoints){l.geometry=e(t.geometries,this.geometry);var d=this.geometry.parameters;if(d!==void 0&&d.shapes!==void 0)if(d=d.shapes,Array.isArray(d))for(var p=0,_=d.length;p<_;p++)e(t.shapes,d[p]);else e(t.shapes,d)}if(this.material!==void 0)if(Array.isArray(this.material)){for(d=[],p=0,_=this.material.length;p<_;p++)d.push(e(t.materials,this.material[p]));l.material=d}else l.material=e(t.materials,this.material);if(0<this.children.length)for(l.children=[],p=0;p<this.children.length;p++)l.children.push(this.children[p].toJSON(t).object);if(n){n=i(t.geometries),p=i(t.materials),_=i(t.textures);var T=i(t.images);d=i(t.shapes),0<n.length&&(s.geometries=n),0<p.length&&(s.materials=p),0<_.length&&(s.textures=_),0<T.length&&(s.images=T),0<d.length&&(s.shapes=d)}return s.object=l,s},clone:function(t){return new this.constructor().copy(this,t)},copy:function(t,e){if(e===void 0&&(e=!0),this.name=t.name,this.up.copy(t.up),this.position.copy(t.position),this.quaternion.copy(t.quaternion),this.scale.copy(t.scale),this.matrix.copy(t.matrix),this.matrixWorld.copy(t.matrixWorld),this.matrixAutoUpdate=t.matrixAutoUpdate,this.matrixWorldNeedsUpdate=t.matrixWorldNeedsUpdate,this.layers.mask=t.layers.mask,this.visible=t.visible,this.castShadow=t.castShadow,this.receiveShadow=t.receiveShadow,this.frustumCulled=t.frustumCulled,this.renderOrder=t.renderOrder,this.userData=JSON.parse(JSON.stringify(t.userData)),e===!0)for(e=0;e<t.children.length;e++)this.add(t.children[e].clone());return this}});var Yc=0;X.prototype=Object.assign(Object.create(a.prototype),{constructor:X,isGeometry:!0,applyMatrix:function(t){for(var e=new m().getNormalMatrix(t),i=0,n=this.vertices.length;i<n;i++)this.vertices[i].applyMatrix4(t);for(i=0,n=this.faces.length;i<n;i++){t=this.faces[i],t.normal.applyMatrix3(e).normalize();for(var s=0,l=t.vertexNormals.length;s<l;s++)t.vertexNormals[s].applyMatrix3(e).normalize()}return this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this.normalsNeedUpdate=this.verticesNeedUpdate=!0,this},rotateX:function(){var t=new c;return function(e){return t.makeRotationX(e),this.applyMatrix(t),this}}(),rotateY:function(){var t=new c;return function(e){return t.makeRotationY(e),this.applyMatrix(t),this}}(),rotateZ:function(){var t=new c;return function(e){return t.makeRotationZ(e),this.applyMatrix(t),this}}(),translate:function(){var t=new c;return function(e,i,n){return t.makeTranslation(e,i,n),this.applyMatrix(t),this}}(),scale:function(){var t=new c;return function(e,i,n){return t.makeScale(e,i,n),this.applyMatrix(t),this}}(),lookAt:function(){var t=new F;return function(e){t.lookAt(e),t.updateMatrix(),this.applyMatrix(t.matrix)}}(),fromBufferGeometry:function(t){function e(q,J,rt,xt){var gt=p===void 0?[]:[i.colors[q].clone(),i.colors[J].clone(),i.colors[rt].clone()],Ct=d===void 0?[]:[new u().fromArray(d,3*q),new u().fromArray(d,3*J),new u().fromArray(d,3*rt)];xt=new R(q,J,rt,Ct,gt,xt),i.faces.push(xt),_!==void 0&&i.faceVertexUvs[0].push([new o().fromArray(_,2*q),new o().fromArray(_,2*J),new o().fromArray(_,2*rt)]),T!==void 0&&i.faceVertexUvs[1].push([new o().fromArray(T,2*q),new o().fromArray(T,2*J),new o().fromArray(T,2*rt)])}var i=this,n=t.index!==null?t.index.array:void 0,s=t.attributes,l=s.position.array,d=s.normal!==void 0?s.normal.array:void 0,p=s.color!==void 0?s.color.array:void 0,_=s.uv!==void 0?s.uv.array:void 0,T=s.uv2!==void 0?s.uv2.array:void 0;T!==void 0&&(this.faceVertexUvs[1]=[]);for(var A=s=0;s<l.length;s+=3,A+=2)i.vertices.push(new u().fromArray(l,s)),p!==void 0&&i.colors.push(new P().fromArray(p,s));var L=t.groups;if(0<L.length)for(s=0;s<L.length;s++){l=L[s];var B=l.start,H=l.count;for(A=B,B+=H;A<B;A+=3)n!==void 0?e(n[A],n[A+1],n[A+2],l.materialIndex):e(A,A+1,A+2,l.materialIndex)}else if(n!==void 0)for(s=0;s<n.length;s+=3)e(n[s],n[s+1],n[s+2]);else for(s=0;s<l.length/3;s+=3)e(s,s+1,s+2);return this.computeFaceNormals(),t.boundingBox!==null&&(this.boundingBox=t.boundingBox.clone()),t.boundingSphere!==null&&(this.boundingSphere=t.boundingSphere.clone()),this},center:function(){var t=new u;return function(){return this.computeBoundingBox(),this.boundingBox.getCenter(t).negate(),this.translate(t.x,t.y,t.z),this}}(),normalize:function(){this.computeBoundingSphere();var t=this.boundingSphere.center,e=this.boundingSphere.radius;e=e===0?1:1/e;var i=new c;return i.set(e,0,0,-e*t.x,0,e,0,-e*t.y,0,0,e,-e*t.z,0,0,0,1),this.applyMatrix(i),this},computeFaceNormals:function(){for(var t=new u,e=new u,i=0,n=this.faces.length;i<n;i++){var s=this.faces[i],l=this.vertices[s.a],d=this.vertices[s.b];t.subVectors(this.vertices[s.c],d),e.subVectors(l,d),t.cross(e),t.normalize(),s.normal.copy(t)}},computeVertexNormals:function(t){t===void 0&&(t=!0);var e,i=Array(this.vertices.length),n=0;for(e=this.vertices.length;n<e;n++)i[n]=new u;if(t){var s=new u,l=new u;for(t=0,n=this.faces.length;t<n;t++){e=this.faces[t];var d=this.vertices[e.a],p=this.vertices[e.b],_=this.vertices[e.c];s.subVectors(_,p),l.subVectors(d,p),s.cross(l),i[e.a].add(s),i[e.b].add(s),i[e.c].add(s)}}else for(this.computeFaceNormals(),t=0,n=this.faces.length;t<n;t++)e=this.faces[t],i[e.a].add(e.normal),i[e.b].add(e.normal),i[e.c].add(e.normal);for(n=0,e=this.vertices.length;n<e;n++)i[n].normalize();for(t=0,n=this.faces.length;t<n;t++)e=this.faces[t],d=e.vertexNormals,d.length===3?(d[0].copy(i[e.a]),d[1].copy(i[e.b]),d[2].copy(i[e.c])):(d[0]=i[e.a].clone(),d[1]=i[e.b].clone(),d[2]=i[e.c].clone());0<this.faces.length&&(this.normalsNeedUpdate=!0)},computeFlatVertexNormals:function(){var t;this.computeFaceNormals();var e=0;for(t=this.faces.length;e<t;e++){var i=this.faces[e],n=i.vertexNormals;n.length===3?(n[0].copy(i.normal),n[1].copy(i.normal),n[2].copy(i.normal)):(n[0]=i.normal.clone(),n[1]=i.normal.clone(),n[2]=i.normal.clone())}0<this.faces.length&&(this.normalsNeedUpdate=!0)},computeMorphNormals:function(){var t,e,i=0;for(e=this.faces.length;i<e;i++){var n=this.faces[i];n.__originalFaceNormal?n.__originalFaceNormal.copy(n.normal):n.__originalFaceNormal=n.normal.clone(),n.__originalVertexNormals||(n.__originalVertexNormals=[]);var s=0;for(t=n.vertexNormals.length;s<t;s++)n.__originalVertexNormals[s]?n.__originalVertexNormals[s].copy(n.vertexNormals[s]):n.__originalVertexNormals[s]=n.vertexNormals[s].clone()}var l=new X;for(l.faces=this.faces,s=0,t=this.morphTargets.length;s<t;s++){if(!this.morphNormals[s]){this.morphNormals[s]={},this.morphNormals[s].faceNormals=[],this.morphNormals[s].vertexNormals=[],n=this.morphNormals[s].faceNormals;var d=this.morphNormals[s].vertexNormals;for(i=0,e=this.faces.length;i<e;i++){var p=new u,_={a:new u,b:new u,c:new u};n.push(p),d.push(_)}}for(d=this.morphNormals[s],l.vertices=this.morphTargets[s].vertices,l.computeFaceNormals(),l.computeVertexNormals(),i=0,e=this.faces.length;i<e;i++)n=this.faces[i],p=d.faceNormals[i],_=d.vertexNormals[i],p.copy(n.normal),_.a.copy(n.vertexNormals[0]),_.b.copy(n.vertexNormals[1]),_.c.copy(n.vertexNormals[2])}for(i=0,e=this.faces.length;i<e;i++)n=this.faces[i],n.normal=n.__originalFaceNormal,n.vertexNormals=n.__originalVertexNormals},computeBoundingBox:function(){this.boundingBox===null&&(this.boundingBox=new k),this.boundingBox.setFromPoints(this.vertices)},computeBoundingSphere:function(){this.boundingSphere===null&&(this.boundingSphere=new I),this.boundingSphere.setFromPoints(this.vertices)},merge:function(t,e,i){if(t&&t.isGeometry){var n,s=this.vertices.length,l=this.vertices,d=t.vertices,p=this.faces,_=t.faces,T=this.faceVertexUvs[0],A=t.faceVertexUvs[0],L=this.colors,B=t.colors;i===void 0&&(i=0),e!==void 0&&(n=new m().getNormalMatrix(e)),t=0;for(var H=d.length;t<H;t++){var q=d[t].clone();e!==void 0&&q.applyMatrix4(e),l.push(q)}for(t=0,H=B.length;t<H;t++)L.push(B[t].clone());for(t=0,H=_.length;t<H;t++){d=_[t];var J=d.vertexNormals;for(B=d.vertexColors,L=new R(d.a+s,d.b+s,d.c+s),L.normal.copy(d.normal),n!==void 0&&L.normal.applyMatrix3(n).normalize(),e=0,l=J.length;e<l;e++)q=J[e].clone(),n!==void 0&&q.applyMatrix3(n).normalize(),L.vertexNormals.push(q);for(L.color.copy(d.color),e=0,l=B.length;e<l;e++)q=B[e],L.vertexColors.push(q.clone());L.materialIndex=d.materialIndex+i,p.push(L)}for(t=0,H=A.length;t<H;t++)if(i=A[t],n=[],i!==void 0){for(e=0,l=i.length;e<l;e++)n.push(i[e].clone());T.push(n)}}},mergeMesh:function(t){t&&t.isMesh&&(t.matrixAutoUpdate&&t.updateMatrix(),this.merge(t.geometry,t.matrix))},mergeVertices:function(){var t={},e=[],i=[],n=Math.pow(10,4),s,l=0;for(s=this.vertices.length;l<s;l++){var d=this.vertices[l];d=Math.round(d.x*n)+"_"+Math.round(d.y*n)+"_"+Math.round(d.z*n),t[d]===void 0?(t[d]=l,e.push(this.vertices[l]),i[l]=e.length-1):i[l]=i[t[d]]}for(t=[],l=0,s=this.faces.length;l<s;l++)for(n=this.faces[l],n.a=i[n.a],n.b=i[n.b],n.c=i[n.c],n=[n.a,n.b,n.c],d=0;3>d;d++)if(n[d]===n[(d+1)%3]){t.push(l);break}for(l=t.length-1;0<=l;l--)for(n=t[l],this.faces.splice(n,1),i=0,s=this.faceVertexUvs.length;i<s;i++)this.faceVertexUvs[i].splice(n,1);return l=this.vertices.length-e.length,this.vertices=e,l},setFromPoints:function(t){this.vertices=[];for(var e=0,i=t.length;e<i;e++){var n=t[e];this.vertices.push(new u(n.x,n.y,n.z||0))}return this},sortFacesByMaterialIndex:function(){for(var t=this.faces,e=t.length,i=0;i<e;i++)t[i]._id=i;t.sort(function(_,T){return _.materialIndex-T.materialIndex});var n=this.faceVertexUvs[0],s=this.faceVertexUvs[1],l,d;for(n&&n.length===e&&(l=[]),s&&s.length===e&&(d=[]),i=0;i<e;i++){var p=t[i]._id;l&&l.push(n[p]),d&&d.push(s[p])}l&&(this.faceVertexUvs[0]=l),d&&(this.faceVertexUvs[1]=d)},toJSON:function(){function t(Vt,$,ot){return ot?Vt|1<<$:Vt&~(1<<$)}function e(Vt){var $=Vt.x.toString()+Vt.y.toString()+Vt.z.toString();return T[$]!==void 0||(T[$]=_.length/3,_.push(Vt.x,Vt.y,Vt.z)),T[$]}function i(Vt){var $=Vt.r.toString()+Vt.g.toString()+Vt.b.toString();return L[$]!==void 0||(L[$]=A.length,A.push(Vt.getHex())),L[$]}function n(Vt){var $=Vt.x.toString()+Vt.y.toString();return H[$]!==void 0||(H[$]=B.length/2,B.push(Vt.x,Vt.y)),H[$]}var s={metadata:{version:4.5,type:"Geometry",generator:"Geometry.toJSON"}};if(s.uuid=this.uuid,s.type=this.type,this.name!==""&&(s.name=this.name),this.parameters!==void 0){var l=this.parameters,d;for(d in l)l[d]!==void 0&&(s[d]=l[d]);return s}for(l=[],d=0;d<this.vertices.length;d++){var p=this.vertices[d];l.push(p.x,p.y,p.z)}p=[];var _=[],T={},A=[],L={},B=[],H={};for(d=0;d<this.faces.length;d++){var q=this.faces[d],J=this.faceVertexUvs[0][d]!==void 0,rt=0<q.normal.length(),xt=0<q.vertexNormals.length,gt=q.color.r!==1||q.color.g!==1||q.color.b!==1,Ct=0<q.vertexColors.length,wt=0;wt=t(wt,0,0),wt=t(wt,1,!0),wt=t(wt,2,!1),wt=t(wt,3,J),wt=t(wt,4,rt),wt=t(wt,5,xt),wt=t(wt,6,gt),wt=t(wt,7,Ct),p.push(wt),p.push(q.a,q.b,q.c),p.push(q.materialIndex),J&&(J=this.faceVertexUvs[0][d],p.push(n(J[0]),n(J[1]),n(J[2]))),rt&&p.push(e(q.normal)),xt&&(rt=q.vertexNormals,p.push(e(rt[0]),e(rt[1]),e(rt[2]))),gt&&p.push(i(q.color)),Ct&&(q=q.vertexColors,p.push(i(q[0]),i(q[1]),i(q[2])))}return s.data={},s.data.vertices=l,s.data.normals=_,0<A.length&&(s.data.colors=A),0<B.length&&(s.data.uvs=[B]),s.data.faces=p,s},clone:function(){return new X().copy(this)},copy:function(t){var e,i,n;this.vertices=[],this.colors=[],this.faces=[],this.faceVertexUvs=[[]],this.morphTargets=[],this.morphNormals=[],this.skinWeights=[],this.skinIndices=[],this.lineDistances=[],this.boundingSphere=this.boundingBox=null,this.name=t.name;var s=t.vertices,l=0;for(e=s.length;l<e;l++)this.vertices.push(s[l].clone());for(s=t.colors,l=0,e=s.length;l<e;l++)this.colors.push(s[l].clone());for(s=t.faces,l=0,e=s.length;l<e;l++)this.faces.push(s[l].clone());for(l=0,e=t.faceVertexUvs.length;l<e;l++){var d=t.faceVertexUvs[l];for(this.faceVertexUvs[l]===void 0&&(this.faceVertexUvs[l]=[]),s=0,i=d.length;s<i;s++){var p=d[s],_=[],T=0;for(n=p.length;T<n;T++)_.push(p[T].clone());this.faceVertexUvs[l].push(_)}}for(T=t.morphTargets,l=0,e=T.length;l<e;l++){if(n={},n.name=T[l].name,T[l].vertices!==void 0)for(n.vertices=[],s=0,i=T[l].vertices.length;s<i;s++)n.vertices.push(T[l].vertices[s].clone());if(T[l].normals!==void 0)for(n.normals=[],s=0,i=T[l].normals.length;s<i;s++)n.normals.push(T[l].normals[s].clone());this.morphTargets.push(n)}for(T=t.morphNormals,l=0,e=T.length;l<e;l++){if(n={},T[l].vertexNormals!==void 0)for(n.vertexNormals=[],s=0,i=T[l].vertexNormals.length;s<i;s++)d=T[l].vertexNormals[s],p={},p.a=d.a.clone(),p.b=d.b.clone(),p.c=d.c.clone(),n.vertexNormals.push(p);if(T[l].faceNormals!==void 0)for(n.faceNormals=[],s=0,i=T[l].faceNormals.length;s<i;s++)n.faceNormals.push(T[l].faceNormals[s].clone());this.morphNormals.push(n)}for(s=t.skinWeights,l=0,e=s.length;l<e;l++)this.skinWeights.push(s[l].clone());for(s=t.skinIndices,l=0,e=s.length;l<e;l++)this.skinIndices.push(s[l].clone());for(s=t.lineDistances,l=0,e=s.length;l<e;l++)this.lineDistances.push(s[l]);return l=t.boundingBox,l!==null&&(this.boundingBox=l.clone()),l=t.boundingSphere,l!==null&&(this.boundingSphere=l.clone()),this.elementsNeedUpdate=t.elementsNeedUpdate,this.verticesNeedUpdate=t.verticesNeedUpdate,this.uvsNeedUpdate=t.uvsNeedUpdate,this.normalsNeedUpdate=t.normalsNeedUpdate,this.colorsNeedUpdate=t.colorsNeedUpdate,this.lineDistancesNeedUpdate=t.lineDistancesNeedUpdate,this.groupsNeedUpdate=t.groupsNeedUpdate,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),Object.defineProperty(K.prototype,"needsUpdate",{set:function(t){t===!0&&this.version++}}),Object.assign(K.prototype,{isBufferAttribute:!0,onUploadCallback:function(){},setArray:function(t){if(Array.isArray(t))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");return this.count=t!==void 0?t.length/this.itemSize:0,this.array=t,this},setDynamic:function(t){return this.dynamic=t,this},copy:function(t){return this.name=t.name,this.array=new t.array.constructor(t.array),this.itemSize=t.itemSize,this.count=t.count,this.normalized=t.normalized,this.dynamic=t.dynamic,this},copyAt:function(t,e,i){t*=this.itemSize,i*=e.itemSize;for(var n=0,s=this.itemSize;n<s;n++)this.array[t+n]=e.array[i+n];return this},copyArray:function(t){return this.array.set(t),this},copyColorsArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new P),e[i++]=l.r,e[i++]=l.g,e[i++]=l.b}return this},copyVector2sArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new o),e[i++]=l.x,e[i++]=l.y}return this},copyVector3sArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new u),e[i++]=l.x,e[i++]=l.y,e[i++]=l.z}return this},copyVector4sArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new v),e[i++]=l.x,e[i++]=l.y,e[i++]=l.z,e[i++]=l.w}return this},set:function(t,e){return e===void 0&&(e=0),this.array.set(t,e),this},getX:function(t){return this.array[t*this.itemSize]},setX:function(t,e){return this.array[t*this.itemSize]=e,this},getY:function(t){return this.array[t*this.itemSize+1]},setY:function(t,e){return this.array[t*this.itemSize+1]=e,this},getZ:function(t){return this.array[t*this.itemSize+2]},setZ:function(t,e){return this.array[t*this.itemSize+2]=e,this},getW:function(t){return this.array[t*this.itemSize+3]},setW:function(t,e){return this.array[t*this.itemSize+3]=e,this},setXY:function(t,e,i){return t*=this.itemSize,this.array[t+0]=e,this.array[t+1]=i,this},setXYZ:function(t,e,i,n){return t*=this.itemSize,this.array[t+0]=e,this.array[t+1]=i,this.array[t+2]=n,this},setXYZW:function(t,e,i,n,s){return t*=this.itemSize,this.array[t+0]=e,this.array[t+1]=i,this.array[t+2]=n,this.array[t+3]=s,this},onUpload:function(t){return this.onUploadCallback=t,this},clone:function(){return new this.constructor(this.array,this.itemSize).copy(this)}}),Z.prototype=Object.create(K.prototype),Z.prototype.constructor=Z,ct.prototype=Object.create(K.prototype),ct.prototype.constructor=ct,Rt.prototype=Object.create(K.prototype),Rt.prototype.constructor=Rt,tt.prototype=Object.create(K.prototype),tt.prototype.constructor=tt,_t.prototype=Object.create(K.prototype),_t.prototype.constructor=_t,G.prototype=Object.create(K.prototype),G.prototype.constructor=G,Pt.prototype=Object.create(K.prototype),Pt.prototype.constructor=Pt,Et.prototype=Object.create(K.prototype),Et.prototype.constructor=Et,At.prototype=Object.create(K.prototype),At.prototype.constructor=At,Object.assign(ce.prototype,{computeGroups:function(t){var e=[],i=void 0;t=t.faces;for(var n=0;n<t.length;n++){var s=t[n];if(s.materialIndex!==i){i=s.materialIndex,l!==void 0&&(l.count=3*n-l.start,e.push(l));var l={start:3*n,materialIndex:i}}}l!==void 0&&(l.count=3*n-l.start,e.push(l)),this.groups=e},fromGeometry:function(t){var e=t.faces,i=t.vertices,n=t.faceVertexUvs,s=n[0]&&0<n[0].length,l=n[1]&&0<n[1].length,d=t.morphTargets,p=d.length;if(0<p){for(var _=[],T=0;T<p;T++)_[T]={name:d[T].name,data:[]};this.morphTargets.position=_}var A=t.morphNormals,L=A.length;if(0<L){var B=[];for(T=0;T<L;T++)B[T]={name:A[T].name,data:[]};this.morphTargets.normal=B}var H=t.skinIndices,q=t.skinWeights,J=H.length===i.length,rt=q.length===i.length;for(0<i.length&&e.length,T=0;T<e.length;T++){var xt=e[T];this.vertices.push(i[xt.a],i[xt.b],i[xt.c]);var gt=xt.vertexNormals;for(gt.length===3?this.normals.push(gt[0],gt[1],gt[2]):(gt=xt.normal,this.normals.push(gt,gt,gt)),gt=xt.vertexColors,gt.length===3?this.colors.push(gt[0],gt[1],gt[2]):(gt=xt.color,this.colors.push(gt,gt,gt)),s===!0&&(gt=n[0][T],gt!==void 0?this.uvs.push(gt[0],gt[1],gt[2]):this.uvs.push(new o,new o,new o)),l===!0&&(gt=n[1][T],gt!==void 0?this.uvs2.push(gt[0],gt[1],gt[2]):this.uvs2.push(new o,new o,new o)),gt=0;gt<p;gt++){var Ct=d[gt].vertices;_[gt].data.push(Ct[xt.a],Ct[xt.b],Ct[xt.c])}for(gt=0;gt<L;gt++)Ct=A[gt].vertexNormals[T],B[gt].data.push(Ct.a,Ct.b,Ct.c);J&&this.skinIndices.push(H[xt.a],H[xt.b],H[xt.c]),rt&&this.skinWeights.push(q[xt.a],q[xt.b],q[xt.c])}return this.computeGroups(t),this.verticesNeedUpdate=t.verticesNeedUpdate,this.normalsNeedUpdate=t.normalsNeedUpdate,this.colorsNeedUpdate=t.colorsNeedUpdate,this.uvsNeedUpdate=t.uvsNeedUpdate,this.groupsNeedUpdate=t.groupsNeedUpdate,this}});var Zc=1;Ft.prototype=Object.assign(Object.create(a.prototype),{constructor:Ft,isBufferGeometry:!0,getIndex:function(){return this.index},setIndex:function(t){Array.isArray(t)?this.index=new(65535<re(t)?Pt:_t)(t,1):this.index=t},addAttribute:function(t,e,i){return e&&e.isBufferAttribute||e&&e.isInterleavedBufferAttribute?t==="index"?(this.setIndex(e),this):(this.attributes[t]=e,this):this.addAttribute(t,new K(e,i))},getAttribute:function(t){return this.attributes[t]},removeAttribute:function(t){return delete this.attributes[t],this},addGroup:function(t,e,i){this.groups.push({start:t,count:e,materialIndex:i!==void 0?i:0})},clearGroups:function(){this.groups=[]},setDrawRange:function(t,e){this.drawRange.start=t,this.drawRange.count=e},applyMatrix:function(t){var e=this.attributes.position;return e!==void 0&&(t.applyToBufferAttribute(e),e.needsUpdate=!0),e=this.attributes.normal,e!==void 0&&(new m().getNormalMatrix(t).applyToBufferAttribute(e),e.needsUpdate=!0),this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this},rotateX:function(){var t=new c;return function(e){return t.makeRotationX(e),this.applyMatrix(t),this}}(),rotateY:function(){var t=new c;return function(e){return t.makeRotationY(e),this.applyMatrix(t),this}}(),rotateZ:function(){var t=new c;return function(e){return t.makeRotationZ(e),this.applyMatrix(t),this}}(),translate:function(){var t=new c;return function(e,i,n){return t.makeTranslation(e,i,n),this.applyMatrix(t),this}}(),scale:function(){var t=new c;return function(e,i,n){return t.makeScale(e,i,n),this.applyMatrix(t),this}}(),lookAt:function(){var t=new F;return function(e){t.lookAt(e),t.updateMatrix(),this.applyMatrix(t.matrix)}}(),center:function(){var t=new u;return function(){return this.computeBoundingBox(),this.boundingBox.getCenter(t).negate(),this.translate(t.x,t.y,t.z),this}}(),setFromObject:function(t){var e=t.geometry;if(t.isPoints||t.isLine){t=new Et(3*e.vertices.length,3);var i=new Et(3*e.colors.length,3);this.addAttribute("position",t.copyVector3sArray(e.vertices)),this.addAttribute("color",i.copyColorsArray(e.colors)),e.lineDistances&&e.lineDistances.length===e.vertices.length&&(t=new Et(e.lineDistances.length,1),this.addAttribute("lineDistance",t.copyArray(e.lineDistances))),e.boundingSphere!==null&&(this.boundingSphere=e.boundingSphere.clone()),e.boundingBox!==null&&(this.boundingBox=e.boundingBox.clone())}else t.isMesh&&e&&e.isGeometry&&this.fromGeometry(e);return this},setFromPoints:function(t){for(var e=[],i=0,n=t.length;i<n;i++){var s=t[i];e.push(s.x,s.y,s.z||0)}return this.addAttribute("position",new Et(e,3)),this},updateFromObject:function(t){var e=t.geometry;if(t.isMesh){var i=e.__directGeometry;if(e.elementsNeedUpdate===!0&&(i=void 0,e.elementsNeedUpdate=!1),i===void 0)return this.fromGeometry(e);i.verticesNeedUpdate=e.verticesNeedUpdate,i.normalsNeedUpdate=e.normalsNeedUpdate,i.colorsNeedUpdate=e.colorsNeedUpdate,i.uvsNeedUpdate=e.uvsNeedUpdate,i.groupsNeedUpdate=e.groupsNeedUpdate,e.verticesNeedUpdate=!1,e.normalsNeedUpdate=!1,e.colorsNeedUpdate=!1,e.uvsNeedUpdate=!1,e.groupsNeedUpdate=!1,e=i}return e.verticesNeedUpdate===!0&&(i=this.attributes.position,i!==void 0&&(i.copyVector3sArray(e.vertices),i.needsUpdate=!0),e.verticesNeedUpdate=!1),e.normalsNeedUpdate===!0&&(i=this.attributes.normal,i!==void 0&&(i.copyVector3sArray(e.normals),i.needsUpdate=!0),e.normalsNeedUpdate=!1),e.colorsNeedUpdate===!0&&(i=this.attributes.color,i!==void 0&&(i.copyColorsArray(e.colors),i.needsUpdate=!0),e.colorsNeedUpdate=!1),e.uvsNeedUpdate&&(i=this.attributes.uv,i!==void 0&&(i.copyVector2sArray(e.uvs),i.needsUpdate=!0),e.uvsNeedUpdate=!1),e.lineDistancesNeedUpdate&&(i=this.attributes.lineDistance,i!==void 0&&(i.copyArray(e.lineDistances),i.needsUpdate=!0),e.lineDistancesNeedUpdate=!1),e.groupsNeedUpdate&&(e.computeGroups(t.geometry),this.groups=e.groups,e.groupsNeedUpdate=!1),this},fromGeometry:function(t){return t.__directGeometry=new ce().fromGeometry(t),this.fromDirectGeometry(t.__directGeometry)},fromDirectGeometry:function(t){var e=new Float32Array(3*t.vertices.length);this.addAttribute("position",new K(e,3).copyVector3sArray(t.vertices)),0<t.normals.length&&(e=new Float32Array(3*t.normals.length),this.addAttribute("normal",new K(e,3).copyVector3sArray(t.normals))),0<t.colors.length&&(e=new Float32Array(3*t.colors.length),this.addAttribute("color",new K(e,3).copyColorsArray(t.colors))),0<t.uvs.length&&(e=new Float32Array(2*t.uvs.length),this.addAttribute("uv",new K(e,2).copyVector2sArray(t.uvs))),0<t.uvs2.length&&(e=new Float32Array(2*t.uvs2.length),this.addAttribute("uv2",new K(e,2).copyVector2sArray(t.uvs2))),this.groups=t.groups;for(var i in t.morphTargets){e=[];for(var n=t.morphTargets[i],s=0,l=n.length;s<l;s++){var d=n[s],p=new Et(3*d.data.length,3);p.name=d.name,e.push(p.copyVector3sArray(d.data))}this.morphAttributes[i]=e}return 0<t.skinIndices.length&&(i=new Et(4*t.skinIndices.length,4),this.addAttribute("skinIndex",i.copyVector4sArray(t.skinIndices))),0<t.skinWeights.length&&(i=new Et(4*t.skinWeights.length,4),this.addAttribute("skinWeight",i.copyVector4sArray(t.skinWeights))),t.boundingSphere!==null&&(this.boundingSphere=t.boundingSphere.clone()),t.boundingBox!==null&&(this.boundingBox=t.boundingBox.clone()),this},computeBoundingBox:function(){this.boundingBox===null&&(this.boundingBox=new k);var t=this.attributes.position;t!==void 0?this.boundingBox.setFromBufferAttribute(t):this.boundingBox.makeEmpty(),isNaN(this.boundingBox.min.x)||isNaN(this.boundingBox.min.y)||isNaN(this.boundingBox.min.z)},computeBoundingSphere:function(){var t=new k,e=new u;return function(){this.boundingSphere===null&&(this.boundingSphere=new I);var i=this.attributes.position;if(i){var n=this.boundingSphere.center;t.setFromBufferAttribute(i),t.getCenter(n);for(var s=0,l=0,d=i.count;l<d;l++)e.x=i.getX(l),e.y=i.getY(l),e.z=i.getZ(l),s=Math.max(s,n.distanceToSquared(e));this.boundingSphere.radius=Math.sqrt(s),isNaN(this.boundingSphere.radius)}}}(),computeFaceNormals:function(){},computeVertexNormals:function(){var t=this.index,e=this.attributes;if(e.position){var i=e.position.array;if(e.normal===void 0)this.addAttribute("normal",new K(new Float32Array(i.length),3));else for(var n=e.normal.array,s=0,l=n.length;s<l;s++)n[s]=0;n=e.normal.array;var d=new u,p=new u,_=new u,T=new u,A=new u;if(t){var L=t.array;for(s=0,l=t.count;s<l;s+=3){t=3*L[s+0];var B=3*L[s+1],H=3*L[s+2];d.fromArray(i,t),p.fromArray(i,B),_.fromArray(i,H),T.subVectors(_,p),A.subVectors(d,p),T.cross(A),n[t]+=T.x,n[t+1]+=T.y,n[t+2]+=T.z,n[B]+=T.x,n[B+1]+=T.y,n[B+2]+=T.z,n[H]+=T.x,n[H+1]+=T.y,n[H+2]+=T.z}}else for(s=0,l=i.length;s<l;s+=9)d.fromArray(i,s),p.fromArray(i,s+3),_.fromArray(i,s+6),T.subVectors(_,p),A.subVectors(d,p),T.cross(A),n[s]=T.x,n[s+1]=T.y,n[s+2]=T.z,n[s+3]=T.x,n[s+4]=T.y,n[s+5]=T.z,n[s+6]=T.x,n[s+7]=T.y,n[s+8]=T.z;this.normalizeNormals(),e.normal.needsUpdate=!0}},merge:function(t,e){if(t&&t.isBufferGeometry){e===void 0&&(e=0);var i=this.attributes,n;for(n in i)if(t.attributes[n]!==void 0){var s=i[n].array,l=t.attributes[n],d=l.array,p=0;for(l=l.itemSize*e;p<d.length;p++,l++)s[l]=d[p]}return this}},normalizeNormals:function(){var t=new u;return function(){for(var e=this.attributes.normal,i=0,n=e.count;i<n;i++)t.x=e.getX(i),t.y=e.getY(i),t.z=e.getZ(i),t.normalize(),e.setXYZ(i,t.x,t.y,t.z)}}(),toNonIndexed:function(){if(this.index===null)return this;var t=new Ft,e=this.index.array,i=this.attributes,n;for(n in i){var s=i[n],l=s.array,d=s.itemSize,p=new l.constructor(e.length*d),_=0;s=0;for(var T=e.length;s<T;s++)for(var A=e[s]*d,L=0;L<d;L++)p[_++]=l[A++];t.addAttribute(n,new K(p,d))}for(e=this.groups,s=0,T=e.length;s<T;s++)i=e[s],t.addGroup(i.start,i.count,i.materialIndex);return t},toJSON:function(){var t={metadata:{version:4.5,type:"BufferGeometry",generator:"BufferGeometry.toJSON"}};if(t.uuid=this.uuid,t.type=this.type,this.name!==""&&(t.name=this.name),0<Object.keys(this.userData).length&&(t.userData=this.userData),this.parameters!==void 0){var e=this.parameters;for(s in e)e[s]!==void 0&&(t[s]=e[s]);return t}t.data={attributes:{}};var i=this.index;i!==null&&(e=Array.prototype.slice.call(i.array),t.data.index={type:i.array.constructor.name,array:e}),i=this.attributes;for(s in i){var n=i[s];e=Array.prototype.slice.call(n.array),t.data.attributes[s]={itemSize:n.itemSize,type:n.array.constructor.name,array:e,normalized:n.normalized}}var s=this.groups;return 0<s.length&&(t.data.groups=JSON.parse(JSON.stringify(s))),s=this.boundingSphere,s!==null&&(t.data.boundingSphere={center:s.center.toArray(),radius:s.radius}),t},clone:function(){return new Ft().copy(this)},copy:function(t){var e;this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingSphere=this.boundingBox=null,this.name=t.name;var i=t.index;i!==null&&this.setIndex(i.clone()),i=t.attributes;for(d in i)this.addAttribute(d,i[d].clone());var n=t.morphAttributes;for(d in n){var s=[],l=n[d];for(i=0,e=l.length;i<e;i++)s.push(l[i].clone());this.morphAttributes[d]=s}var d=t.groups;for(i=0,e=d.length;i<e;i++)n=d[i],this.addGroup(n.start,n.count,n.materialIndex);return d=t.boundingBox,d!==null&&(this.boundingBox=d.clone()),d=t.boundingSphere,d!==null&&(this.boundingSphere=d.clone()),this.drawRange.start=t.drawRange.start,this.drawRange.count=t.drawRange.count,this.userData=t.userData,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),It.prototype=Object.create(X.prototype),It.prototype.constructor=It,Nt.prototype=Object.create(Ft.prototype),Nt.prototype.constructor=Nt,Pe.prototype=Object.create(X.prototype),Pe.prototype.constructor=Pe,pe.prototype=Object.create(Ft.prototype),pe.prototype.constructor=pe;var zu=0;Wt.prototype=Object.assign(Object.create(a.prototype),{constructor:Wt,isMaterial:!0,onBeforeCompile:function(){},setValues:function(t){if(t!==void 0)for(var e in t){var i=t[e];if(i!==void 0)if(e==="shading")this.flatShading=i===1;else{var n=this[e];n===void 0||(n&&n.isColor?n.set(i):n&&n.isVector3&&i&&i.isVector3?n.copy(i):this[e]=i)}}},toJSON:function(t){function e(s){var l=[],d;for(d in s){var p=s[d];delete p.metadata,l.push(p)}return l}var i=t===void 0||typeof t=="string";i&&(t={textures:{},images:{}});var n={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};return n.uuid=this.uuid,n.type=this.type,this.name!==""&&(n.name=this.name),this.color&&this.color.isColor&&(n.color=this.color.getHex()),this.roughness!==void 0&&(n.roughness=this.roughness),this.metalness!==void 0&&(n.metalness=this.metalness),this.emissive&&this.emissive.isColor&&(n.emissive=this.emissive.getHex()),this.emissiveIntensity!==1&&(n.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(n.specular=this.specular.getHex()),this.shininess!==void 0&&(n.shininess=this.shininess),this.clearCoat!==void 0&&(n.clearCoat=this.clearCoat),this.clearCoatRoughness!==void 0&&(n.clearCoatRoughness=this.clearCoatRoughness),this.map&&this.map.isTexture&&(n.map=this.map.toJSON(t).uuid),this.alphaMap&&this.alphaMap.isTexture&&(n.alphaMap=this.alphaMap.toJSON(t).uuid),this.lightMap&&this.lightMap.isTexture&&(n.lightMap=this.lightMap.toJSON(t).uuid),this.aoMap&&this.aoMap.isTexture&&(n.aoMap=this.aoMap.toJSON(t).uuid,n.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(n.bumpMap=this.bumpMap.toJSON(t).uuid,n.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(n.normalMap=this.normalMap.toJSON(t).uuid,n.normalMapType=this.normalMapType,n.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(n.displacementMap=this.displacementMap.toJSON(t).uuid,n.displacementScale=this.displacementScale,n.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(n.roughnessMap=this.roughnessMap.toJSON(t).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(n.metalnessMap=this.metalnessMap.toJSON(t).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(n.emissiveMap=this.emissiveMap.toJSON(t).uuid),this.specularMap&&this.specularMap.isTexture&&(n.specularMap=this.specularMap.toJSON(t).uuid),this.envMap&&this.envMap.isTexture&&(n.envMap=this.envMap.toJSON(t).uuid,n.reflectivity=this.reflectivity,this.combine!==void 0&&(n.combine=this.combine),this.envMapIntensity!==void 0&&(n.envMapIntensity=this.envMapIntensity)),this.gradientMap&&this.gradientMap.isTexture&&(n.gradientMap=this.gradientMap.toJSON(t).uuid),this.size!==void 0&&(n.size=this.size),this.sizeAttenuation!==void 0&&(n.sizeAttenuation=this.sizeAttenuation),this.blending!==1&&(n.blending=this.blending),this.flatShading===!0&&(n.flatShading=this.flatShading),this.side!==0&&(n.side=this.side),this.vertexColors!==0&&(n.vertexColors=this.vertexColors),1>this.opacity&&(n.opacity=this.opacity),this.transparent===!0&&(n.transparent=this.transparent),n.depthFunc=this.depthFunc,n.depthTest=this.depthTest,n.depthWrite=this.depthWrite,this.rotation!==0&&(n.rotation=this.rotation),this.polygonOffset===!0&&(n.polygonOffset=!0),this.polygonOffsetFactor!==0&&(n.polygonOffsetFactor=this.polygonOffsetFactor),this.polygonOffsetUnits!==0&&(n.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth!==1&&(n.linewidth=this.linewidth),this.dashSize!==void 0&&(n.dashSize=this.dashSize),this.gapSize!==void 0&&(n.gapSize=this.gapSize),this.scale!==void 0&&(n.scale=this.scale),this.dithering===!0&&(n.dithering=!0),0<this.alphaTest&&(n.alphaTest=this.alphaTest),this.premultipliedAlpha===!0&&(n.premultipliedAlpha=this.premultipliedAlpha),this.wireframe===!0&&(n.wireframe=this.wireframe),1<this.wireframeLinewidth&&(n.wireframeLinewidth=this.wireframeLinewidth),this.wireframeLinecap!=="round"&&(n.wireframeLinecap=this.wireframeLinecap),this.wireframeLinejoin!=="round"&&(n.wireframeLinejoin=this.wireframeLinejoin),this.morphTargets===!0&&(n.morphTargets=!0),this.skinning===!0&&(n.skinning=!0),this.visible===!1&&(n.visible=!1),JSON.stringify(this.userData)!=="{}"&&(n.userData=this.userData),i&&(i=e(t.textures),t=e(t.images),0<i.length&&(n.textures=i),0<t.length&&(n.images=t)),n},clone:function(){return new this.constructor().copy(this)},copy:function(t){this.name=t.name,this.fog=t.fog,this.lights=t.lights,this.blending=t.blending,this.side=t.side,this.flatShading=t.flatShading,this.vertexColors=t.vertexColors,this.opacity=t.opacity,this.transparent=t.transparent,this.blendSrc=t.blendSrc,this.blendDst=t.blendDst,this.blendEquation=t.blendEquation,this.blendSrcAlpha=t.blendSrcAlpha,this.blendDstAlpha=t.blendDstAlpha,this.blendEquationAlpha=t.blendEquationAlpha,this.depthFunc=t.depthFunc,this.depthTest=t.depthTest,this.depthWrite=t.depthWrite,this.colorWrite=t.colorWrite,this.precision=t.precision,this.polygonOffset=t.polygonOffset,this.polygonOffsetFactor=t.polygonOffsetFactor,this.polygonOffsetUnits=t.polygonOffsetUnits,this.dithering=t.dithering,this.alphaTest=t.alphaTest,this.premultipliedAlpha=t.premultipliedAlpha,this.visible=t.visible,this.userData=JSON.parse(JSON.stringify(t.userData)),this.clipShadows=t.clipShadows,this.clipIntersection=t.clipIntersection;var e=t.clippingPlanes,i=null;if(e!==null){var n=e.length;i=Array(n);for(var s=0;s!==n;++s)i[s]=e[s].clone()}return this.clippingPlanes=i,this.shadowSide=t.shadowSide,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),$e.prototype=Object.create(Wt.prototype),$e.prototype.constructor=$e,$e.prototype.isShaderMaterial=!0,$e.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.fragmentShader=t.fragmentShader,this.vertexShader=t.vertexShader,this.uniforms=Bn.clone(t.uniforms),this.defines=Object.assign({},t.defines),this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.lights=t.lights,this.clipping=t.clipping,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this.extensions=t.extensions,this},$e.prototype.toJSON=function(t){var e=Wt.prototype.toJSON.call(this,t);e.uniforms={};for(var i in this.uniforms){var n=this.uniforms[i].value;e.uniforms[i]=n.isTexture?{type:"t",value:n.toJSON(t).uuid}:n.isColor?{type:"c",value:n.getHex()}:n.isVector2?{type:"v2",value:n.toArray()}:n.isVector3?{type:"v3",value:n.toArray()}:n.isVector4?{type:"v4",value:n.toArray()}:n.isMatrix4?{type:"m4",value:n.toArray()}:{value:n}}return 0<Object.keys(this.defines).length&&(e.defines=this.defines),e.vertexShader=this.vertexShader,e.fragmentShader=this.fragmentShader,e},Object.assign(Si.prototype,{set:function(t,e){return this.origin.copy(t),this.direction.copy(e),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.origin.copy(t.origin),this.direction.copy(t.direction),this},at:function(t,e){return e===void 0&&(e=new u),e.copy(this.direction).multiplyScalar(t).add(this.origin)},lookAt:function(t){return this.direction.copy(t).sub(this.origin).normalize(),this},recast:function(){var t=new u;return function(e){return this.origin.copy(this.at(e,t)),this}}(),closestPointToPoint:function(t,e){return e===void 0&&(e=new u),e.subVectors(t,this.origin),t=e.dot(this.direction),0>t?e.copy(this.origin):e.copy(this.direction).multiplyScalar(t).add(this.origin)},distanceToPoint:function(t){return Math.sqrt(this.distanceSqToPoint(t))},distanceSqToPoint:function(){var t=new u;return function(e){var i=t.subVectors(e,this.origin).dot(this.direction);return 0>i?this.origin.distanceToSquared(e):(t.copy(this.direction).multiplyScalar(i).add(this.origin),t.distanceToSquared(e))}}(),distanceSqToSegment:function(){var t=new u,e=new u,i=new u;return function(n,s,l,d){t.copy(n).add(s).multiplyScalar(.5),e.copy(s).sub(n).normalize(),i.copy(this.origin).sub(t);var p=.5*n.distanceTo(s),_=-this.direction.dot(e),T=i.dot(this.direction),A=-i.dot(e),L=i.lengthSq(),B=Math.abs(1-_*_);if(0<B){n=_*A-T,s=_*T-A;var H=p*B;0<=n?s>=-H?s<=H?(p=1/B,n*=p,s*=p,_=n*(n+_*s+2*T)+s*(_*n+s+2*A)+L):(s=p,n=Math.max(0,-(_*s+T)),_=-n*n+s*(s+2*A)+L):(s=-p,n=Math.max(0,-(_*s+T)),_=-n*n+s*(s+2*A)+L):s<=-H?(n=Math.max(0,-(-_*p+T)),s=0<n?-p:Math.min(Math.max(-p,-A),p),_=-n*n+s*(s+2*A)+L):s<=H?(n=0,s=Math.min(Math.max(-p,-A),p),_=s*(s+2*A)+L):(n=Math.max(0,-(_*p+T)),s=0<n?p:Math.min(Math.max(-p,-A),p),_=-n*n+s*(s+2*A)+L)}else s=0<_?-p:p,n=Math.max(0,-(_*s+T)),_=-n*n+s*(s+2*A)+L;return l&&l.copy(this.direction).multiplyScalar(n).add(this.origin),d&&d.copy(e).multiplyScalar(s).add(t),_}}(),intersectSphere:function(){var t=new u;return function(e,i){t.subVectors(e.center,this.origin);var n=t.dot(this.direction),s=t.dot(t)-n*n;return e=e.radius*e.radius,s>e?null:(e=Math.sqrt(e-s),s=n-e,n+=e,0>s&&0>n?null:0>s?this.at(n,i):this.at(s,i))}}(),intersectsSphere:function(t){return this.distanceSqToPoint(t.center)<=t.radius*t.radius},distanceToPlane:function(t){var e=t.normal.dot(this.direction);return e===0?t.distanceToPoint(this.origin)===0?0:null:(t=-(this.origin.dot(t.normal)+t.constant)/e,0<=t?t:null)},intersectPlane:function(t,e){return t=this.distanceToPlane(t),t===null?null:this.at(t,e)},intersectsPlane:function(t){var e=t.distanceToPoint(this.origin);return e===0||0>t.normal.dot(this.direction)*e},intersectBox:function(t,e){var i=1/this.direction.x,n=1/this.direction.y,s=1/this.direction.z,l=this.origin;if(0<=i){var d=(t.min.x-l.x)*i;i*=t.max.x-l.x}else d=(t.max.x-l.x)*i,i*=t.min.x-l.x;if(0<=n){var p=(t.min.y-l.y)*n;n*=t.max.y-l.y}else p=(t.max.y-l.y)*n,n*=t.min.y-l.y;return d>n||p>i||((p>d||d!==d)&&(d=p),(n<i||i!==i)&&(i=n),0<=s?(p=(t.min.z-l.z)*s,t=(t.max.z-l.z)*s):(p=(t.max.z-l.z)*s,t=(t.min.z-l.z)*s),d>t||p>i)?null:((p>d||d!==d)&&(d=p),(t<i||i!==i)&&(i=t),0>i?null:this.at(0<=d?d:i,e))},intersectsBox:function(){var t=new u;return function(e){return this.intersectBox(e,t)!==null}}(),intersectTriangle:function(){var t=new u,e=new u,i=new u,n=new u;return function(s,l,d,p,_){if(e.subVectors(l,s),i.subVectors(d,s),n.crossVectors(e,i),l=this.direction.dot(n),0<l){if(p)return null;p=1}else if(0>l)p=-1,l=-l;else return null;return t.subVectors(this.origin,s),s=p*this.direction.dot(i.crossVectors(t,i)),0>s||(d=p*this.direction.dot(e.cross(t)),0>d||s+d>l)?null:(s=-p*t.dot(n),0>s?null:this.at(s/l,_))}}(),applyMatrix4:function(t){return this.origin.applyMatrix4(t),this.direction.transformDirection(t),this},equals:function(t){return t.origin.equals(this.origin)&&t.direction.equals(this.direction)}}),Object.assign(Oe,{getNormal:function(){var t=new u;return function(e,i,n,s){return s===void 0&&(s=new u),s.subVectors(n,i),t.subVectors(e,i),s.cross(t),e=s.lengthSq(),0<e?s.multiplyScalar(1/Math.sqrt(e)):s.set(0,0,0)}}(),getBarycoord:function(){var t=new u,e=new u,i=new u;return function(n,s,l,d,p){t.subVectors(d,s),e.subVectors(l,s),i.subVectors(n,s),n=t.dot(t),s=t.dot(e),l=t.dot(i);var _=e.dot(e);d=e.dot(i);var T=n*_-s*s;return p===void 0&&(p=new u),T===0?p.set(-2,-1,-1):(T=1/T,_=(_*l-s*d)*T,n=(n*d-s*l)*T,p.set(1-_-n,n,_))}}(),containsPoint:function(){var t=new u;return function(e,i,n,s){return Oe.getBarycoord(e,i,n,s,t),0<=t.x&&0<=t.y&&1>=t.x+t.y}}(),getUV:function(){var t=new u;return function(e,i,n,s,l,d,p,_){return this.getBarycoord(e,i,n,s,t),_.set(0,0),_.addScaledVector(l,t.x),_.addScaledVector(d,t.y),_.addScaledVector(p,t.z),_}}()}),Object.assign(Oe.prototype,{set:function(t,e,i){return this.a.copy(t),this.b.copy(e),this.c.copy(i),this},setFromPointsAndIndices:function(t,e,i,n){return this.a.copy(t[e]),this.b.copy(t[i]),this.c.copy(t[n]),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.a.copy(t.a),this.b.copy(t.b),this.c.copy(t.c),this},getArea:function(){var t=new u,e=new u;return function(){return t.subVectors(this.c,this.b),e.subVectors(this.a,this.b),.5*t.cross(e).length()}}(),getMidpoint:function(t){return t===void 0&&(t=new u),t.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},getNormal:function(t){return Oe.getNormal(this.a,this.b,this.c,t)},getPlane:function(t){return t===void 0&&(t=new u),t.setFromCoplanarPoints(this.a,this.b,this.c)},getBarycoord:function(t,e){return Oe.getBarycoord(t,this.a,this.b,this.c,e)},containsPoint:function(t){return Oe.containsPoint(t,this.a,this.b,this.c)},getUV:function(t,e,i,n,s){return Oe.getUV(t,this.a,this.b,this.c,e,i,n,s)},intersectsBox:function(t){return t.intersectsTriangle(this)},closestPointToPoint:function(){var t=new u,e=new u,i=new u,n=new u,s=new u,l=new u;return function(d,p){p===void 0&&(p=new u);var _=this.a,T=this.b,A=this.c;t.subVectors(T,_),e.subVectors(A,_),n.subVectors(d,_);var L=t.dot(n),B=e.dot(n);if(0>=L&&0>=B)return p.copy(_);s.subVectors(d,T);var H=t.dot(s),q=e.dot(s);if(0<=H&&q<=H)return p.copy(T);var J=L*q-H*B;if(0>=J&&0<=L&&0>=H)return T=L/(L-H),p.copy(_).addScaledVector(t,T);l.subVectors(d,A),d=t.dot(l);var rt=e.dot(l);return 0<=rt&&d<=rt?p.copy(A):(L=d*B-L*rt,0>=L&&0<=B&&0>=rt?(J=B/(B-rt),p.copy(_).addScaledVector(e,J)):(B=H*rt-d*q,0>=B&&0<=q-H&&0<=d-rt?(i.subVectors(A,T),J=(q-H)/(q-H+(d-rt)),p.copy(T).addScaledVector(i,J)):(A=1/(B+L+J),T=L*A,J*=A,p.copy(_).addScaledVector(t,T).addScaledVector(e,J))))}}(),equals:function(t){return t.a.equals(this.a)&&t.b.equals(this.b)&&t.c.equals(this.c)}}),Ge.prototype=Object.create(Wt.prototype),Ge.prototype.constructor=Ge,Ge.prototype.isMeshBasicMaterial=!0,Ge.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.specularMap=t.specularMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.combine=t.combine,this.reflectivity=t.reflectivity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this},pi.prototype=Object.assign(Object.create(F.prototype),{constructor:pi,isMesh:!0,setDrawMode:function(t){this.drawMode=t},copy:function(t){return F.prototype.copy.call(this,t),this.drawMode=t.drawMode,t.morphTargetInfluences!==void 0&&(this.morphTargetInfluences=t.morphTargetInfluences.slice()),t.morphTargetDictionary!==void 0&&(this.morphTargetDictionary=Object.assign({},t.morphTargetDictionary)),this},updateMorphTargets:function(){var t=this.geometry;if(t.isBufferGeometry){t=t.morphAttributes;var e=Object.keys(t);if(0<e.length){var i=t[e[0]];if(i!==void 0)for(this.morphTargetInfluences=[],this.morphTargetDictionary={},t=0,e=i.length;t<e;t++){var n=i[t].name||String(t);this.morphTargetInfluences.push(0),this.morphTargetDictionary[n]=t}}}else if(i=t.morphTargets,i!==void 0&&0<i.length)for(this.morphTargetInfluences=[],this.morphTargetDictionary={},t=0,e=i.length;t<e;t++)n=i[t].name||String(t),this.morphTargetInfluences.push(0),this.morphTargetDictionary[n]=t},raycast:function(){function t(rt,xt,gt,Ct,wt,Vt,$,ot){return(xt.side===1?Ct.intersectTriangle($,Vt,wt,!0,ot):Ct.intersectTriangle(wt,Vt,$,xt.side!==2,ot))===null?null:(J.copy(ot),J.applyMatrix4(rt.matrixWorld),xt=gt.ray.origin.distanceTo(J),xt<gt.near||xt>gt.far?null:{distance:xt,point:J.clone(),object:rt})}function e(rt,xt,gt,Ct,wt,Vt,$,ot,kt){return l.fromBufferAttribute(wt,$),d.fromBufferAttribute(wt,ot),p.fromBufferAttribute(wt,kt),(rt=t(rt,xt,gt,Ct,l,d,p,q))&&(Vt&&(L.fromBufferAttribute(Vt,$),B.fromBufferAttribute(Vt,ot),H.fromBufferAttribute(Vt,kt),rt.uv=Oe.getUV(q,l,d,p,L,B,H,new o)),Vt=new R($,ot,kt),Oe.getNormal(l,d,p,Vt.normal),rt.face=Vt),rt}var i=new c,n=new Si,s=new I,l=new u,d=new u,p=new u,_=new u,T=new u,A=new u,L=new o,B=new o,H=new o,q=new u,J=new u;return function(rt,xt){var gt=this.geometry,Ct=this.material,wt=this.matrixWorld;if(Ct!==void 0&&(gt.boundingSphere===null&>.computeBoundingSphere(),s.copy(gt.boundingSphere),s.applyMatrix4(wt),rt.ray.intersectsSphere(s)!==!1&&(i.getInverse(wt),n.copy(rt.ray).applyMatrix4(i),gt.boundingBox===null||n.intersectsBox(gt.boundingBox)!==!1))){if(gt.isBufferGeometry){var Vt=gt.index,$=gt.attributes.position,ot=gt.attributes.uv,kt=gt.groups;gt=gt.drawRange;var ee;if(Vt!==null)if(Array.isArray(Ct)){var $t=0;for(ee=kt.length;$t<ee;$t++){var Yt=kt[$t],Te=Ct[Yt.materialIndex];wt=Math.max(Yt.start,gt.start);var ge=Math.min(Yt.start+Yt.count,gt.start+gt.count);for(Yt=wt;Yt<ge;Yt+=3){wt=Vt.getX(Yt);var De=Vt.getX(Yt+1),be=Vt.getX(Yt+2);(wt=e(this,Te,rt,n,$,ot,wt,De,be))&&(wt.faceIndex=Math.floor(Yt/3),xt.push(wt))}}}else for(wt=Math.max(0,gt.start),ge=Math.min(Vt.count,gt.start+gt.count),$t=wt,ee=ge;$t<ee;$t+=3)wt=Vt.getX($t),De=Vt.getX($t+1),be=Vt.getX($t+2),(wt=e(this,Ct,rt,n,$,ot,wt,De,be))&&(wt.faceIndex=Math.floor($t/3),xt.push(wt));else if($!==void 0)if(Array.isArray(Ct))for($t=0,ee=kt.length;$t<ee;$t++)for(Yt=kt[$t],Te=Ct[Yt.materialIndex],wt=Math.max(Yt.start,gt.start),ge=Math.min(Yt.start+Yt.count,gt.start+gt.count),Yt=wt;Yt<ge;Yt+=3)wt=Yt,De=Yt+1,be=Yt+2,(wt=e(this,Te,rt,n,$,ot,wt,De,be))&&(wt.faceIndex=Math.floor(Yt/3),xt.push(wt));else for(wt=Math.max(0,gt.start),ge=Math.min($.count,gt.start+gt.count),$t=wt,ee=ge;$t<ee;$t+=3)wt=$t,De=$t+1,be=$t+2,(wt=e(this,Ct,rt,n,$,ot,wt,De,be))&&(wt.faceIndex=Math.floor($t/3),xt.push(wt))}else if(gt.isGeometry){for($=Array.isArray(Ct),ot=gt.vertices,kt=gt.faces,wt=gt.faceVertexUvs[0],0<wt.length&&(Vt=wt),Yt=0,ge=kt.length;Yt<ge;Yt++)if(De=kt[Yt],wt=$?Ct[De.materialIndex]:Ct,wt!==void 0){if($t=ot[De.a],ee=ot[De.b],Te=ot[De.c],wt.morphTargets===!0){be=gt.morphTargets;var ae=this.morphTargetInfluences;l.set(0,0,0),d.set(0,0,0),p.set(0,0,0);for(var We=0,Qe=be.length;We<Qe;We++){var fi=ae[We];if(fi!==0){var Cn=be[We].vertices;l.addScaledVector(_.subVectors(Cn[De.a],$t),fi),d.addScaledVector(T.subVectors(Cn[De.b],ee),fi),p.addScaledVector(A.subVectors(Cn[De.c],Te),fi)}}l.add($t),d.add(ee),p.add(Te),$t=l,ee=d,Te=p}(wt=t(this,wt,rt,n,$t,ee,Te,q))&&(Vt&&Vt[Yt]&&(be=Vt[Yt],L.copy(be[0]),B.copy(be[1]),H.copy(be[2]),wt.uv=Oe.getUV(q,$t,ee,Te,L,B,H,new o)),wt.face=De,wt.faceIndex=Yt,xt.push(wt))}}}}}(),clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}}),z.prototype=Object.create(g.prototype),z.prototype.constructor=z,z.prototype.isCubeTexture=!0,Object.defineProperty(z.prototype,"images",{get:function(){return this.image},set:function(t){this.image=t}}),Q.prototype=Object.create(g.prototype),Q.prototype.constructor=Q,Q.prototype.isDataTexture3D=!0;var qh=new g,Jc=new Q,ku=new z,ah=[],Ra=[],wl=new Float32Array(16),Bu=new Float32Array(9),Yh=new Float32Array(4);sa.prototype.updateCache=function(t){var e=this.cache;t instanceof Float32Array&&e.length!==t.length&&(this.cache=new Float32Array(t.length)),vt(e,t)},Ja.prototype.setValue=function(t,e,i){for(var n=this.seq,s=0,l=n.length;s!==l;++s){var d=n[s];d.setValue(t,e[d.id],i)}};var Zh=/([\w\d_]+)(\])?(\[|\.)?/g;ho.prototype.setValue=function(t,e,i){e=this.map[e],e!==void 0&&e.setValue(t,i,this.renderer)},ho.prototype.setOptional=function(t,e,i){e=e[i],e!==void 0&&this.setValue(t,i,e)},ho.upload=function(t,e,i,n){for(var s=0,l=e.length;s!==l;++s){var d=e[s],p=i[d.id];p.needsUpdate!==!1&&d.setValue(t,p.value,n)}},ho.seqWithValue=function(t,e){for(var i=[],n=0,s=t.length;n!==s;++n){var l=t[n];l.id in e&&i.push(l)}return i};var Bo=0,Jh=0;se.prototype=Object.create(Wt.prototype),se.prototype.constructor=se,se.prototype.isMeshDepthMaterial=!0,se.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.depthPacking=t.depthPacking,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.map=t.map,this.alphaMap=t.alphaMap,this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this},te.prototype=Object.create(Wt.prototype),te.prototype.constructor=te,te.prototype.isMeshDistanceMaterial=!0,te.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.referencePosition.copy(t.referencePosition),this.nearDistance=t.nearDistance,this.farDistance=t.farDistance,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.map=t.map,this.alphaMap=t.alphaMap,this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this},ci.prototype=Object.assign(Object.create(F.prototype),{constructor:ci,isGroup:!0}),Be.prototype=Object.assign(Object.create(F.prototype),{constructor:Be,isCamera:!0,copy:function(t,e){return F.prototype.copy.call(this,t,e),this.matrixWorldInverse.copy(t.matrixWorldInverse),this.projectionMatrix.copy(t.projectionMatrix),this.projectionMatrixInverse.copy(t.projectionMatrixInverse),this},getWorldDirection:function(t){t===void 0&&(t=new u),this.updateMatrixWorld(!0);var e=this.matrixWorld.elements;return t.set(-e[8],-e[9],-e[10]).normalize()},updateMatrixWorld:function(t){F.prototype.updateMatrixWorld.call(this,t),this.matrixWorldInverse.getInverse(this.matrixWorld)},clone:function(){return new this.constructor().copy(this)}}),_e.prototype=Object.assign(Object.create(Be.prototype),{constructor:_e,isPerspectiveCamera:!0,copy:function(t,e){return Be.prototype.copy.call(this,t,e),this.fov=t.fov,this.zoom=t.zoom,this.near=t.near,this.far=t.far,this.focus=t.focus,this.aspect=t.aspect,this.view=t.view===null?null:Object.assign({},t.view),this.filmGauge=t.filmGauge,this.filmOffset=t.filmOffset,this},setFocalLength:function(t){t=.5*this.getFilmHeight()/t,this.fov=2*di.RAD2DEG*Math.atan(t),this.updateProjectionMatrix()},getFocalLength:function(){var t=Math.tan(.5*di.DEG2RAD*this.fov);return .5*this.getFilmHeight()/t},getEffectiveFOV:function(){return 2*di.RAD2DEG*Math.atan(Math.tan(.5*di.DEG2RAD*this.fov)/this.zoom)},getFilmWidth:function(){return this.filmGauge*Math.min(this.aspect,1)},getFilmHeight:function(){return this.filmGauge/Math.max(this.aspect,1)},setViewOffset:function(t,e,i,n,s,l){this.aspect=t/e,this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=t,this.view.fullHeight=e,this.view.offsetX=i,this.view.offsetY=n,this.view.width=s,this.view.height=l,this.updateProjectionMatrix()},clearViewOffset:function(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()},updateProjectionMatrix:function(){var t=this.near,e=t*Math.tan(.5*di.DEG2RAD*this.fov)/this.zoom,i=2*e,n=this.aspect*i,s=-.5*n,l=this.view;if(this.view!==null&&this.view.enabled){var d=l.fullWidth,p=l.fullHeight;s+=l.offsetX*n/d,e-=l.offsetY*i/p,n*=l.width/d,i*=l.height/p}l=this.filmOffset,l!==0&&(s+=t*l/this.getFilmWidth()),this.projectionMatrix.makePerspective(s,s+n,e,e-i,t,this.far),this.projectionMatrixInverse.getInverse(this.projectionMatrix)},toJSON:function(t){return t=F.prototype.toJSON.call(this,t),t.object.fov=this.fov,t.object.zoom=this.zoom,t.object.near=this.near,t.object.far=this.far,t.object.focus=this.focus,t.object.aspect=this.aspect,this.view!==null&&(t.object.view=Object.assign({},this.view)),t.object.filmGauge=this.filmGauge,t.object.filmOffset=this.filmOffset,t}}),Fe.prototype=Object.assign(Object.create(_e.prototype),{constructor:Fe,isArrayCamera:!0});var ls=new u,wr=new u;Re.prototype.isFogExp2=!0,Re.prototype.clone=function(){return new Re(this.color,this.density)},Re.prototype.toJSON=function(){return{type:"FogExp2",color:this.color.getHex(),density:this.density}},Sn.prototype.isFog=!0,Sn.prototype.clone=function(){return new Sn(this.color,this.near,this.far)},Sn.prototype.toJSON=function(){return{type:"Fog",color:this.color.getHex(),near:this.near,far:this.far}},Xn.prototype=Object.assign(Object.create(F.prototype),{constructor:Xn,copy:function(t,e){return F.prototype.copy.call(this,t,e),t.background!==null&&(this.background=t.background.clone()),t.fog!==null&&(this.fog=t.fog.clone()),t.overrideMaterial!==null&&(this.overrideMaterial=t.overrideMaterial.clone()),this.autoUpdate=t.autoUpdate,this.matrixAutoUpdate=t.matrixAutoUpdate,this},toJSON:function(t){var e=F.prototype.toJSON.call(this,t);return this.background!==null&&(e.object.background=this.background.toJSON(t)),this.fog!==null&&(e.object.fog=this.fog.toJSON()),e}}),Object.defineProperty(ki.prototype,"needsUpdate",{set:function(t){t===!0&&this.version++}}),Object.assign(ki.prototype,{isInterleavedBuffer:!0,onUploadCallback:function(){},setArray:function(t){if(Array.isArray(t))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");return this.count=t!==void 0?t.length/this.stride:0,this.array=t,this},setDynamic:function(t){return this.dynamic=t,this},copy:function(t){return this.array=new t.array.constructor(t.array),this.count=t.count,this.stride=t.stride,this.dynamic=t.dynamic,this},copyAt:function(t,e,i){t*=this.stride,i*=e.stride;for(var n=0,s=this.stride;n<s;n++)this.array[t+n]=e.array[i+n];return this},set:function(t,e){return e===void 0&&(e=0),this.array.set(t,e),this},clone:function(){return new this.constructor().copy(this)},onUpload:function(t){return this.onUploadCallback=t,this}}),Object.defineProperties(Bi.prototype,{count:{get:function(){return this.data.count}},array:{get:function(){return this.data.array}}}),Object.assign(Bi.prototype,{isInterleavedBufferAttribute:!0,setX:function(t,e){return this.data.array[t*this.data.stride+this.offset]=e,this},setY:function(t,e){return this.data.array[t*this.data.stride+this.offset+1]=e,this},setZ:function(t,e){return this.data.array[t*this.data.stride+this.offset+2]=e,this},setW:function(t,e){return this.data.array[t*this.data.stride+this.offset+3]=e,this},getX:function(t){return this.data.array[t*this.data.stride+this.offset]},getY:function(t){return this.data.array[t*this.data.stride+this.offset+1]},getZ:function(t){return this.data.array[t*this.data.stride+this.offset+2]},getW:function(t){return this.data.array[t*this.data.stride+this.offset+3]},setXY:function(t,e,i){return t=t*this.data.stride+this.offset,this.data.array[t+0]=e,this.data.array[t+1]=i,this},setXYZ:function(t,e,i,n){return t=t*this.data.stride+this.offset,this.data.array[t+0]=e,this.data.array[t+1]=i,this.data.array[t+2]=n,this},setXYZW:function(t,e,i,n,s){return t=t*this.data.stride+this.offset,this.data.array[t+0]=e,this.data.array[t+1]=i,this.data.array[t+2]=n,this.data.array[t+3]=s,this}}),Hi.prototype=Object.create(Wt.prototype),Hi.prototype.constructor=Hi,Hi.prototype.isSpriteMaterial=!0,Hi.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.rotation=t.rotation,this.sizeAttenuation=t.sizeAttenuation,this};var Oa;nn.prototype=Object.assign(Object.create(F.prototype),{constructor:nn,isSprite:!0,raycast:function(){function t(H,q,J,rt,xt,gt){s.subVectors(H,J).addScalar(.5).multiply(rt),xt!==void 0?(l.x=gt*s.x-xt*s.y,l.y=xt*s.x+gt*s.y):l.copy(s),H.copy(q),H.x+=l.x,H.y+=l.y,H.applyMatrix4(d)}var e=new u,i=new u,n=new u,s=new o,l=new o,d=new c,p=new u,_=new u,T=new u,A=new o,L=new o,B=new o;return function(H,q){i.setFromMatrixScale(this.matrixWorld),d.getInverse(this.modelViewMatrix).premultiply(this.matrixWorld),n.setFromMatrixPosition(this.modelViewMatrix);var J=this.material.rotation;if(J!==0)var rt=Math.cos(J),xt=Math.sin(J);J=this.center,t(p.set(-.5,-.5,0),n,J,i,xt,rt),t(_.set(.5,-.5,0),n,J,i,xt,rt),t(T.set(.5,.5,0),n,J,i,xt,rt),A.set(0,0),L.set(1,0),B.set(1,1);var gt=H.ray.intersectTriangle(p,_,T,!1,e);gt===null&&(t(_.set(-.5,.5,0),n,J,i,xt,rt),L.set(0,1),gt=H.ray.intersectTriangle(p,T,_,!1,e),gt===null)||(xt=H.ray.origin.distanceTo(e),xt<H.near||xt>H.far||q.push({distance:xt,point:e.clone(),uv:Oe.getUV(e,p,_,T,A,L,B,new o),face:null,object:this}))}}(),clone:function(){return new this.constructor(this.material).copy(this)},copy:function(t){return F.prototype.copy.call(this,t),t.center!==void 0&&this.center.copy(t.center),this}}),rn.prototype=Object.assign(Object.create(F.prototype),{constructor:rn,copy:function(t){F.prototype.copy.call(this,t,!1),t=t.levels;for(var e=0,i=t.length;e<i;e++){var n=t[e];this.addLevel(n.object.clone(),n.distance)}return this},addLevel:function(t,e){e===void 0&&(e=0),e=Math.abs(e);for(var i=this.levels,n=0;n<i.length&&!(e<i[n].distance);n++);i.splice(n,0,{distance:e,object:t}),this.add(t)},getObjectForDistance:function(t){for(var e=this.levels,i=1,n=e.length;i<n&&!(t<e[i].distance);i++);return e[i-1].object},raycast:function(){var t=new u;return function(e,i){t.setFromMatrixPosition(this.matrixWorld);var n=e.ray.origin.distanceTo(t);this.getObjectForDistance(n).raycast(e,i)}}(),update:function(){var t=new u,e=new u;return function(i){var n=this.levels;if(1<n.length){t.setFromMatrixPosition(i.matrixWorld),e.setFromMatrixPosition(this.matrixWorld),i=t.distanceTo(e),n[0].object.visible=!0;for(var s=1,l=n.length;s<l&&i>=n[s].distance;s++)n[s-1].object.visible=!1,n[s].object.visible=!0;for(;s<l;s++)n[s].object.visible=!1}}}(),toJSON:function(t){t=F.prototype.toJSON.call(this,t),t.object.levels=[];for(var e=this.levels,i=0,n=e.length;i<n;i++){var s=e[i];t.object.levels.push({object:s.object.uuid,distance:s.distance})}return t}}),Object.assign(un.prototype,{calculateInverses:function(){this.boneInverses=[];for(var t=0,e=this.bones.length;t<e;t++){var i=new c;this.bones[t]&&i.getInverse(this.bones[t].matrixWorld),this.boneInverses.push(i)}},pose:function(){var t,e,i=0;for(e=this.bones.length;i<e;i++)(t=this.bones[i])&&t.matrixWorld.getInverse(this.boneInverses[i]);for(i=0,e=this.bones.length;i<e;i++)(t=this.bones[i])&&(t.parent&&t.parent.isBone?(t.matrix.getInverse(t.parent.matrixWorld),t.matrix.multiply(t.matrixWorld)):t.matrix.copy(t.matrixWorld),t.matrix.decompose(t.position,t.quaternion,t.scale))},update:function(){var t=new c,e=new c;return function(){for(var i=this.bones,n=this.boneInverses,s=this.boneMatrices,l=this.boneTexture,d=0,p=i.length;d<p;d++)t.multiplyMatrices(i[d]?i[d].matrixWorld:e,n[d]),t.toArray(s,16*d);l!==void 0&&(l.needsUpdate=!0)}}(),clone:function(){return new un(this.bones,this.boneInverses)},getBoneByName:function(t){for(var e=0,i=this.bones.length;e<i;e++){var n=this.bones[e];if(n.name===t)return n}}}),cn.prototype=Object.assign(Object.create(F.prototype),{constructor:cn,isBone:!0}),Gi.prototype=Object.assign(Object.create(pi.prototype),{constructor:Gi,isSkinnedMesh:!0,initBones:function(){var t=[],e;if(this.geometry&&this.geometry.bones!==void 0){var i=0;for(e=this.geometry.bones.length;i<e;i++){var n=this.geometry.bones[i],s=new cn;t.push(s),s.name=n.name,s.position.fromArray(n.pos),s.quaternion.fromArray(n.rotq),n.scl!==void 0&&s.scale.fromArray(n.scl)}for(i=0,e=this.geometry.bones.length;i<e;i++)n=this.geometry.bones[i],n.parent!==-1&&n.parent!==null&&t[n.parent]!==void 0?t[n.parent].add(t[i]):this.add(t[i])}return this.updateMatrixWorld(!0),t},bind:function(t,e){this.skeleton=t,e===void 0&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),e=this.matrixWorld),this.bindMatrix.copy(e),this.bindMatrixInverse.getInverse(e)},pose:function(){this.skeleton.pose()},normalizeSkinWeights:function(){var t;if(this.geometry&&this.geometry.isGeometry)for(t=0;t<this.geometry.skinWeights.length;t++){var e=this.geometry.skinWeights[t],i=1/e.manhattanLength();i!==1/0?e.multiplyScalar(i):e.set(1,0,0,0)}else if(this.geometry&&this.geometry.isBufferGeometry){e=new v;var n=this.geometry.attributes.skinWeight;for(t=0;t<n.count;t++)e.x=n.getX(t),e.y=n.getY(t),e.z=n.getZ(t),e.w=n.getW(t),i=1/e.manhattanLength(),i!==1/0?e.multiplyScalar(i):e.set(1,0,0,0),n.setXYZW(t,e.x,e.y,e.z,e.w)}},updateMatrixWorld:function(t){pi.prototype.updateMatrixWorld.call(this,t),this.bindMode==="attached"?this.bindMatrixInverse.getInverse(this.matrixWorld):this.bindMode==="detached"&&this.bindMatrixInverse.getInverse(this.bindMatrix)},clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}}),Ni.prototype=Object.create(Wt.prototype),Ni.prototype.constructor=Ni,Ni.prototype.isLineBasicMaterial=!0,Ni.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.linewidth=t.linewidth,this.linecap=t.linecap,this.linejoin=t.linejoin,this},ji.prototype=Object.assign(Object.create(F.prototype),{constructor:ji,isLine:!0,computeLineDistances:function(){var t=new u,e=new u;return function(){var i=this.geometry;if(i.isBufferGeometry){if(i.index===null){for(var n=i.attributes.position,s=[0],l=1,d=n.count;l<d;l++)t.fromBufferAttribute(n,l-1),e.fromBufferAttribute(n,l),s[l]=s[l-1],s[l]+=t.distanceTo(e);i.addAttribute("lineDistance",new Et(s,1))}}else if(i.isGeometry)for(n=i.vertices,s=i.lineDistances,s[0]=0,l=1,d=n.length;l<d;l++)s[l]=s[l-1],s[l]+=n[l-1].distanceTo(n[l]);return this}}(),raycast:function(){var t=new c,e=new Si,i=new I;return function(n,s){var l=n.linePrecision,d=this.geometry,p=this.matrixWorld;if(d.boundingSphere===null&&d.computeBoundingSphere(),i.copy(d.boundingSphere),i.applyMatrix4(p),i.radius+=l,n.ray.intersectsSphere(i)!==!1){t.getInverse(p),e.copy(n.ray).applyMatrix4(t),l/=(this.scale.x+this.scale.y+this.scale.z)/3,l*=l;var _=new u,T=new u;p=new u;var A=new u,L=this&&this.isLineSegments?2:1;if(d.isBufferGeometry){var B=d.index,H=d.attributes.position.array;if(B!==null){B=B.array,d=0;for(var q=B.length-1;d<q;d+=L){var J=B[d+1];_.fromArray(H,3*B[d]),T.fromArray(H,3*J),J=e.distanceSqToSegment(_,T,A,p),J>l||(A.applyMatrix4(this.matrixWorld),J=n.ray.origin.distanceTo(A),J<n.near||J>n.far||s.push({distance:J,point:p.clone().applyMatrix4(this.matrixWorld),index:d,face:null,faceIndex:null,object:this}))}}else for(d=0,q=H.length/3-1;d<q;d+=L)_.fromArray(H,3*d),T.fromArray(H,3*d+3),J=e.distanceSqToSegment(_,T,A,p),J>l||(A.applyMatrix4(this.matrixWorld),J=n.ray.origin.distanceTo(A),J<n.near||J>n.far||s.push({distance:J,point:p.clone().applyMatrix4(this.matrixWorld),index:d,face:null,faceIndex:null,object:this}))}else if(d.isGeometry)for(_=d.vertices,T=_.length,d=0;d<T-1;d+=L)J=e.distanceSqToSegment(_[d],_[d+1],A,p),J>l||(A.applyMatrix4(this.matrixWorld),J=n.ray.origin.distanceTo(A),J<n.near||J>n.far||s.push({distance:J,point:p.clone().applyMatrix4(this.matrixWorld),index:d,face:null,faceIndex:null,object:this}))}}}(),copy:function(t){return F.prototype.copy.call(this,t),this.geometry.copy(t.geometry),this.material.copy(t.material),this},clone:function(){return new this.constructor().copy(this)}}),gi.prototype=Object.assign(Object.create(ji.prototype),{constructor:gi,isLineSegments:!0,computeLineDistances:function(){var t=new u,e=new u;return function(){var i=this.geometry;if(i.isBufferGeometry){if(i.index===null){for(var n=i.attributes.position,s=[],l=0,d=n.count;l<d;l+=2)t.fromBufferAttribute(n,l),e.fromBufferAttribute(n,l+1),s[l]=l===0?0:s[l-1],s[l+1]=s[l]+t.distanceTo(e);i.addAttribute("lineDistance",new Et(s,1))}}else if(i.isGeometry)for(n=i.vertices,s=i.lineDistances,l=0,d=n.length;l<d;l+=2)t.copy(n[l]),e.copy(n[l+1]),s[l]=l===0?0:s[l-1],s[l+1]=s[l]+t.distanceTo(e);return this}}()}),co.prototype=Object.assign(Object.create(ji.prototype),{constructor:co,isLineLoop:!0}),Fn.prototype=Object.create(Wt.prototype),Fn.prototype.constructor=Fn,Fn.prototype.isPointsMaterial=!0,Fn.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.size=t.size,this.sizeAttenuation=t.sizeAttenuation,this.morphTargets=t.morphTargets,this},ha.prototype=Object.assign(Object.create(F.prototype),{constructor:ha,isPoints:!0,raycast:function(){var t=new c,e=new Si,i=new I;return function(n,s){function l(rt,xt){var gt=e.distanceSqToPoint(rt);gt<A&&(e.closestPointToPoint(rt,L),L.applyMatrix4(_),rt=n.ray.origin.distanceTo(L),rt<n.near||rt>n.far||s.push({distance:rt,distanceToRay:Math.sqrt(gt),point:L.clone(),index:xt,face:null,object:d}))}var d=this,p=this.geometry,_=this.matrixWorld,T=n.params.Points.threshold;if(p.boundingSphere===null&&p.computeBoundingSphere(),i.copy(p.boundingSphere),i.applyMatrix4(_),i.radius+=T,n.ray.intersectsSphere(i)!==!1){t.getInverse(_),e.copy(n.ray).applyMatrix4(t),T/=(this.scale.x+this.scale.y+this.scale.z)/3;var A=T*T;T=new u;var L=new u;if(p.isBufferGeometry){var B=p.index;if(p=p.attributes.position.array,B!==null){var H=B.array;B=0;for(var q=H.length;B<q;B++){var J=H[B];T.fromArray(p,3*J),l(T,J)}}else for(B=0,H=p.length/3;B<H;B++)T.fromArray(p,3*B),l(T,B)}else for(T=p.vertices,B=0,H=T.length;B<H;B++)l(T[B],B)}}}(),clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}}),zh.prototype=Object.assign(Object.create(g.prototype),{constructor:zh,isVideoTexture:!0,update:function(){var t=this.image;t.readyState>=t.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}}),Zo.prototype=Object.create(g.prototype),Zo.prototype.constructor=Zo,Zo.prototype.isCompressedTexture=!0,$a.prototype=Object.create(g.prototype),$a.prototype.constructor=$a,$a.prototype.isCanvasTexture=!0,Ka.prototype=Object.create(g.prototype),Ka.prototype.constructor=Ka,Ka.prototype.isDepthTexture=!0,ua.prototype=Object.create(Ft.prototype),ua.prototype.constructor=ua,Qa.prototype=Object.create(X.prototype),Qa.prototype.constructor=Qa,ca.prototype=Object.create(Ft.prototype),ca.prototype.constructor=ca,Xi.prototype=Object.create(X.prototype),Xi.prototype.constructor=Xi,xi.prototype=Object.create(Ft.prototype),xi.prototype.constructor=xi,tl.prototype=Object.create(X.prototype),tl.prototype.constructor=tl,fa.prototype=Object.create(xi.prototype),fa.prototype.constructor=fa,el.prototype=Object.create(X.prototype),el.prototype.constructor=el,xs.prototype=Object.create(xi.prototype),xs.prototype.constructor=xs,il.prototype=Object.create(X.prototype),il.prototype.constructor=il,da.prototype=Object.create(xi.prototype),da.prototype.constructor=da,pa.prototype=Object.create(X.prototype),pa.prototype.constructor=pa,ma.prototype=Object.create(xi.prototype),ma.prototype.constructor=ma,gn.prototype=Object.create(X.prototype),gn.prototype.constructor=gn,Jo.prototype=Object.create(Ft.prototype),Jo.prototype.constructor=Jo,Zr.prototype=Object.create(X.prototype),Zr.prototype.constructor=Zr,ws.prototype=Object.create(Ft.prototype),ws.prototype.constructor=ws,Ts.prototype=Object.create(X.prototype),Ts.prototype.constructor=Ts,Un.prototype=Object.create(Ft.prototype),Un.prototype.constructor=Un;var Nu={triangulate:function(t,e,i){i=i||2;var n=e&&e.length,s=n?e[0]*i:t.length,l=kh(t,0,s,i,!0),d=[];if(!l)return d;var p;if(n){var _=i;n=[];var T,A=0;for(T=e.length;A<T;A++){var L=e[A]*_,B=A<T-1?e[A+1]*_:t.length;L=kh(t,L,B,_,!1),L===L.next&&(L.steiner=!0),n.push(yr(L))}for(n.sort(Su),A=0;A<n.length;A++)e=n[A],_=l,(_=Eu(e,_))&&(e=nl(_,e),ga(e,e.next)),l=ga(l,l.next)}if(t.length>80*i){var H=p=t[0],q=n=t[1];for(_=i;_<s;_+=i)A=t[_],e=t[_+1],A<H&&(H=A),e<q&&(q=e),A>p&&(p=A),e>n&&(n=e);p=Math.max(p-H,n-q),p=p!==0?1/p:0}return va(l,d,i,H,q,p),d}},To={area:function(t){for(var e=t.length,i=0,n=e-1,s=0;s<e;n=s++)i+=t[n].x*t[s].y-t[s].x*t[n].y;return .5*i},isClockWise:function(t){return 0>To.area(t)},triangulateShape:function(t,e){var i=[],n=[],s=[];$l(t),bu(i,t);var l=t.length;for(e.forEach($l),t=0;t<e.length;t++)n.push(l),l+=e[t].length,bu(i,e[t]);for(e=Nu.triangulate(i,n),t=0;t<e.length;t+=3)s.push(e.slice(t,t+3));return s}};Po.prototype=Object.create(X.prototype),Po.prototype.constructor=Po,Po.prototype.toJSON=function(){var t=X.prototype.toJSON.call(this);return Cu(this.parameters.shapes,this.parameters.options,t)},po.prototype=Object.create(Ft.prototype),po.prototype.constructor=po,po.prototype.toJSON=function(){var t=Ft.prototype.toJSON.call(this);return Cu(this.parameters.shapes,this.parameters.options,t)};var Tl={generateTopUV:function(t,e,i,n,s){t=e[3*n],n=e[3*n+1];var l=e[3*s];return s=e[3*s+1],[new o(e[3*i],e[3*i+1]),new o(t,n),new o(l,s)]},generateSideWallUV:function(t,e,i,n,s,l){t=e[3*i];var d=e[3*i+1];i=e[3*i+2];var p=e[3*n],_=e[3*n+1];n=e[3*n+2];var T=e[3*s],A=e[3*s+1];s=e[3*s+2];var L=e[3*l],B=e[3*l+1];return e=e[3*l+2],.01>Math.abs(d-_)?[new o(t,1-i),new o(p,1-n),new o(T,1-s),new o(L,1-e)]:[new o(d,1-i),new o(_,1-n),new o(A,1-s),new o(B,1-e)]}};rl.prototype=Object.create(X.prototype),rl.prototype.constructor=rl,Ss.prototype=Object.create(po.prototype),Ss.prototype.constructor=Ss,$o.prototype=Object.create(X.prototype),$o.prototype.constructor=$o,Or.prototype=Object.create(Ft.prototype),Or.prototype.constructor=Or,ol.prototype=Object.create(X.prototype),ol.prototype.constructor=ol,Es.prototype=Object.create(Ft.prototype),Es.prototype.constructor=Es,ya.prototype=Object.create(X.prototype),ya.prototype.constructor=ya,Ko.prototype=Object.create(Ft.prototype),Ko.prototype.constructor=Ko,Lo.prototype=Object.create(X.prototype),Lo.prototype.constructor=Lo,Lo.prototype.toJSON=function(){var t=X.prototype.toJSON.call(this);return Au(this.parameters.shapes,t)},Qo.prototype=Object.create(Ft.prototype),Qo.prototype.constructor=Qo,Qo.prototype.toJSON=function(){var t=Ft.prototype.toJSON.call(this);return Au(this.parameters.shapes,t)},ts.prototype=Object.create(Ft.prototype),ts.prototype.constructor=ts,Ro.prototype=Object.create(X.prototype),Ro.prototype.constructor=Ro,Oo.prototype=Object.create(Ft.prototype),Oo.prototype.constructor=Oo,_a.prototype=Object.create(Ro.prototype),_a.prototype.constructor=_a,Gn.prototype=Object.create(Oo.prototype),Gn.prototype.constructor=Gn,bs.prototype=Object.create(X.prototype),bs.prototype.constructor=bs,mo.prototype=Object.create(Ft.prototype),mo.prototype.constructor=mo;var yn=Object.freeze({WireframeGeometry:ua,ParametricGeometry:Qa,ParametricBufferGeometry:ca,TetrahedronGeometry:tl,TetrahedronBufferGeometry:fa,OctahedronGeometry:el,OctahedronBufferGeometry:xs,IcosahedronGeometry:il,IcosahedronBufferGeometry:da,DodecahedronGeometry:pa,DodecahedronBufferGeometry:ma,PolyhedronGeometry:Xi,PolyhedronBufferGeometry:xi,TubeGeometry:gn,TubeBufferGeometry:Jo,TorusKnotGeometry:Zr,TorusKnotBufferGeometry:ws,TorusGeometry:Ts,TorusBufferGeometry:Un,TextGeometry:rl,TextBufferGeometry:Ss,SphereGeometry:$o,SphereBufferGeometry:Or,RingGeometry:ol,RingBufferGeometry:Es,PlaneGeometry:Pe,PlaneBufferGeometry:pe,LatheGeometry:ya,LatheBufferGeometry:Ko,ShapeGeometry:Lo,ShapeBufferGeometry:Qo,ExtrudeGeometry:Po,ExtrudeBufferGeometry:po,EdgesGeometry:ts,ConeGeometry:_a,ConeBufferGeometry:Gn,CylinderGeometry:Ro,CylinderBufferGeometry:Oo,CircleGeometry:bs,CircleBufferGeometry:mo,BoxGeometry:It,BoxBufferGeometry:Nt});es.prototype=Object.create(Wt.prototype),es.prototype.constructor=es,es.prototype.isShadowMaterial=!0,es.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this},Cs.prototype=Object.create($e.prototype),Cs.prototype.constructor=Cs,Cs.prototype.isRawShaderMaterial=!0,go.prototype=Object.create(Wt.prototype),go.prototype.constructor=go,go.prototype.isMeshStandardMaterial=!0,go.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.defines={STANDARD:""},this.color.copy(t.color),this.roughness=t.roughness,this.metalness=t.metalness,this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.emissive.copy(t.emissive),this.emissiveMap=t.emissiveMap,this.emissiveIntensity=t.emissiveIntensity,this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.roughnessMap=t.roughnessMap,this.metalnessMap=t.metalnessMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.envMapIntensity=t.envMapIntensity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},As.prototype=Object.create(go.prototype),As.prototype.constructor=As,As.prototype.isMeshPhysicalMaterial=!0,As.prototype.copy=function(t){return go.prototype.copy.call(this,t),this.defines={PHYSICAL:""},this.reflectivity=t.reflectivity,this.clearCoat=t.clearCoat,this.clearCoatRoughness=t.clearCoatRoughness,this},Jr.prototype=Object.create(Wt.prototype),Jr.prototype.constructor=Jr,Jr.prototype.isMeshPhongMaterial=!0,Jr.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.specular.copy(t.specular),this.shininess=t.shininess,this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.emissive.copy(t.emissive),this.emissiveMap=t.emissiveMap,this.emissiveIntensity=t.emissiveIntensity,this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.specularMap=t.specularMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.combine=t.combine,this.reflectivity=t.reflectivity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Ps.prototype=Object.create(Jr.prototype),Ps.prototype.constructor=Ps,Ps.prototype.isMeshToonMaterial=!0,Ps.prototype.copy=function(t){return Jr.prototype.copy.call(this,t),this.gradientMap=t.gradientMap,this},Ls.prototype=Object.create(Wt.prototype),Ls.prototype.constructor=Ls,Ls.prototype.isMeshNormalMaterial=!0,Ls.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Ir.prototype=Object.create(Wt.prototype),Ir.prototype.constructor=Ir,Ir.prototype.isMeshLambertMaterial=!0,Ir.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.emissive.copy(t.emissive),this.emissiveMap=t.emissiveMap,this.emissiveIntensity=t.emissiveIntensity,this.specularMap=t.specularMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.combine=t.combine,this.reflectivity=t.reflectivity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Rs.prototype=Object.create(Wt.prototype),Rs.prototype.constructor=Rs,Rs.prototype.isMeshMatcapMaterial=!0,Rs.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.defines={MATCAP:""},this.color.copy(t.color),this.matcap=t.matcap,this.map=t.map,this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.alphaMap=t.alphaMap,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Os.prototype=Object.create(Ni.prototype),Os.prototype.constructor=Os,Os.prototype.isLineDashedMaterial=!0,Os.prototype.copy=function(t){return Ni.prototype.copy.call(this,t),this.scale=t.scale,this.dashSize=t.dashSize,this.gapSize=t.gapSize,this};var Fu=Object.freeze({ShadowMaterial:es,SpriteMaterial:Hi,RawShaderMaterial:Cs,ShaderMaterial:$e,PointsMaterial:Fn,MeshPhysicalMaterial:As,MeshStandardMaterial:go,MeshPhongMaterial:Jr,MeshToonMaterial:Ps,MeshNormalMaterial:Ls,MeshLambertMaterial:Ir,MeshDepthMaterial:se,MeshDistanceMaterial:te,MeshBasicMaterial:Ge,MeshMatcapMaterial:Rs,LineDashedMaterial:Os,LineBasicMaterial:Ni,Material:Wt}),Yn={arraySlice:function(t,e,i){return Yn.isTypedArray(t)?new t.constructor(t.subarray(e,i!==void 0?i:t.length)):t.slice(e,i)},convertArray:function(t,e,i){return!t||!i&&t.constructor===e?t:typeof e.BYTES_PER_ELEMENT=="number"?new e(t):Array.prototype.slice.call(t)},isTypedArray:function(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)},getKeyframeOrder:function(t){for(var e=t.length,i=Array(e),n=0;n!==e;++n)i[n]=n;return i.sort(function(s,l){return t[s]-t[l]}),i},sortedArray:function(t,e,i){for(var n=t.length,s=new t.constructor(n),l=0,d=0;d!==n;++l)for(var p=i[l]*e,_=0;_!==e;++_)s[d++]=t[p+_];return s},flattenJSON:function(t,e,i,n){for(var s=1,l=t[0];l!==void 0&&l[n]===void 0;)l=t[s++];if(l!==void 0){var d=l[n];if(d!==void 0)if(Array.isArray(d))do d=l[n],d!==void 0&&(e.push(l.time),i.push.apply(i,d)),l=t[s++];while(l!==void 0);else if(d.toArray!==void 0)do d=l[n],d!==void 0&&(e.push(l.time),d.toArray(i,i.length)),l=t[s++];while(l!==void 0);else do d=l[n],d!==void 0&&(e.push(l.time),i.push(d)),l=t[s++];while(l!==void 0)}}};Object.assign($n.prototype,{evaluate:function(t){var e=this.parameterPositions,i=this._cachedIndex,n=e[i],s=e[i-1];t:{e:{i:{n:if(!(t<n)){for(var l=i+2;;){if(n===void 0){if(t<s)break n;return this._cachedIndex=i=e.length,this.afterEnd_(i-1,t,s)}if(i===l)break;if(s=n,n=e[++i],t<n)break e}n=e.length;break i}if(t>=s)break t;for(l=e[1],t<l&&(i=2,s=l),l=i-2;;){if(s===void 0)return this._cachedIndex=0,this.beforeStart_(0,t,n);if(i===l)break;if(n=s,s=e[--i-1],t>=s)break e}n=i,i=0}for(;i<n;)s=i+n>>>1,t<e[s]?n=s:i=s+1;if(n=e[i],s=e[i-1],s===void 0)return this._cachedIndex=0,this.beforeStart_(0,t,n);if(n===void 0)return this._cachedIndex=i=e.length,this.afterEnd_(i-1,s,t)}this._cachedIndex=i,this.intervalChanged_(i,s,n)}return this.interpolate_(i,s,t,n)},settings:null,DefaultSettings_:{},getSettings_:function(){return this.settings||this.DefaultSettings_},copySampleValue_:function(t){var e=this.resultBuffer,i=this.sampleValues,n=this.valueSize;t*=n;for(var s=0;s!==n;++s)e[s]=i[t+s];return e},interpolate_:function(){throw Error("call to abstract method")},intervalChanged_:function(){}}),Object.assign($n.prototype,{beforeStart_:$n.prototype.copySampleValue_,afterEnd_:$n.prototype.copySampleValue_}),sl.prototype=Object.assign(Object.create($n.prototype),{constructor:sl,DefaultSettings_:{endingStart:2400,endingEnd:2400},intervalChanged_:function(t,e,i){var n=this.parameterPositions,s=t-2,l=t+1,d=n[s],p=n[l];if(d===void 0)switch(this.getSettings_().endingStart){case 2401:s=t,d=2*e-i;break;case 2402:s=n.length-2,d=e+n[s]-n[s+1];break;default:s=t,d=i}if(p===void 0)switch(this.getSettings_().endingEnd){case 2401:l=t,p=2*i-e;break;case 2402:l=1,p=i+n[1]-n[0];break;default:l=t-1,p=e}t=.5*(i-e),n=this.valueSize,this._weightPrev=t/(e-d),this._weightNext=t/(p-i),this._offsetPrev=s*n,this._offsetNext=l*n},interpolate_:function(t,e,i,n){var s=this.resultBuffer,l=this.sampleValues,d=this.valueSize;t*=d;var p=t-d,_=this._offsetPrev,T=this._offsetNext,A=this._weightPrev,L=this._weightNext,B=(i-e)/(n-e);for(i=B*B,n=i*B,e=-A*n+2*A*i-A*B,A=(1+A)*n+(-1.5-2*A)*i+(-.5+A)*B+1,B=(-1-L)*n+(1.5+L)*i+.5*B,L=L*n-L*i,i=0;i!==d;++i)s[i]=e*l[_+i]+A*l[p+i]+B*l[t+i]+L*l[T+i];return s}}),Dr.prototype=Object.assign(Object.create($n.prototype),{constructor:Dr,interpolate_:function(t,e,i,n){var s=this.resultBuffer,l=this.sampleValues,d=this.valueSize;t*=d;var p=t-d;for(e=(i-e)/(n-e),i=1-e,n=0;n!==d;++n)s[n]=l[p+n]*i+l[t+n]*e;return s}}),Is.prototype=Object.assign(Object.create($n.prototype),{constructor:Is,interpolate_:function(t){return this.copySampleValue_(t-1)}}),Object.assign(Hn,{toJSON:function(t){var e=t.constructor;if(e.toJSON!==void 0)e=e.toJSON(t);else{e={name:t.name,times:Yn.convertArray(t.times,Array),values:Yn.convertArray(t.values,Array)};var i=t.getInterpolation();i!==t.DefaultInterpolation&&(e.interpolation=i)}return e.type=t.ValueTypeName,e}}),Object.assign(Hn.prototype,{constructor:Hn,TimeBufferType:Float32Array,ValueBufferType:Float32Array,DefaultInterpolation:2301,InterpolantFactoryMethodDiscrete:function(t){return new Is(this.times,this.values,this.getValueSize(),t)},InterpolantFactoryMethodLinear:function(t){return new Dr(this.times,this.values,this.getValueSize(),t)},InterpolantFactoryMethodSmooth:function(t){return new sl(this.times,this.values,this.getValueSize(),t)},setInterpolation:function(t){switch(t){case 2300:var e=this.InterpolantFactoryMethodDiscrete;break;case 2301:e=this.InterpolantFactoryMethodLinear;break;case 2302:e=this.InterpolantFactoryMethodSmooth}if(e===void 0){if(e="unsupported interpolation for "+this.ValueTypeName+" keyframe track named "+this.name,this.createInterpolant===void 0)if(t!==this.DefaultInterpolation)this.setInterpolation(this.DefaultInterpolation);else throw Error(e);return this}return this.createInterpolant=e,this},getInterpolation:function(){switch(this.createInterpolant){case this.InterpolantFactoryMethodDiscrete:return 2300;case this.InterpolantFactoryMethodLinear:return 2301;case this.InterpolantFactoryMethodSmooth:return 2302}},getValueSize:function(){return this.values.length/this.times.length},shift:function(t){if(t!==0)for(var e=this.times,i=0,n=e.length;i!==n;++i)e[i]+=t;return this},scale:function(t){if(t!==1)for(var e=this.times,i=0,n=e.length;i!==n;++i)e[i]*=t;return this},trim:function(t,e){for(var i=this.times,n=i.length,s=0,l=n-1;s!==n&&i[s]<t;)++s;for(;l!==-1&&i[l]>e;)--l;return++l,(s!==0||l!==n)&&(s>=l&&(l=Math.max(l,1),s=l-1),t=this.getValueSize(),this.times=Yn.arraySlice(i,s,l),this.values=Yn.arraySlice(this.values,s*t,l*t)),this},validate:function(){var t=!0,e=this.getValueSize();e-Math.floor(e)!==0&&(t=!1);var i=this.times;e=this.values;var n=i.length;n===0&&(t=!1);for(var s=null,l=0;l!==n;l++){var d=i[l];if(typeof d=="number"&&isNaN(d)){t=!1;break}if(s!==null&&s>d){t=!1;break}s=d}if(e!==void 0&&Yn.isTypedArray(e)){for(l=0,i=e.length;l!==i;++l)if(n=e[l],isNaN(n)){t=!1;break}}return t},optimize:function(){for(var t=this.times,e=this.values,i=this.getValueSize(),n=this.getInterpolation()===2302,s=1,l=t.length-1,d=1;d<l;++d){var p=!1,_=t[d];if(_!==t[d+1]&&(d!==1||_!==_[0]))if(n)p=!0;else{var T=d*i,A=T-i,L=T+i;for(_=0;_!==i;++_){var B=e[T+_];if(B!==e[A+_]||B!==e[L+_]){p=!0;break}}}if(p){if(d!==s)for(t[s]=t[d],p=d*i,T=s*i,_=0;_!==i;++_)e[T+_]=e[p+_];++s}}if(0<l){for(t[s]=t[l],p=l*i,T=s*i,_=0;_!==i;++_)e[T+_]=e[p+_];++s}return s!==t.length&&(this.times=Yn.arraySlice(t,0,s),this.values=Yn.arraySlice(e,0,s*i)),this}}),Kl.prototype=Object.assign(Object.create(Hn.prototype),{constructor:Kl,ValueTypeName:"bool",ValueBufferType:Array,DefaultInterpolation:2300,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0}),Ql.prototype=Object.assign(Object.create(Hn.prototype),{constructor:Ql,ValueTypeName:"color"}),$r.prototype=Object.assign(Object.create(Hn.prototype),{constructor:$r,ValueTypeName:"number"}),ar.prototype=Object.assign(Object.create($n.prototype),{constructor:ar,interpolate_:function(t,e,i,n){var s=this.resultBuffer,l=this.sampleValues,d=this.valueSize;for(t*=d,e=(i-e)/(n-e),i=t+d;t!==i;t+=4)f.slerpFlat(s,0,l,t-d,l,t,e);return s}}),xa.prototype=Object.assign(Object.create(Hn.prototype),{constructor:xa,ValueTypeName:"quaternion",DefaultInterpolation:2301,InterpolantFactoryMethodLinear:function(t){return new ar(this.times,this.values,this.getValueSize(),t)},InterpolantFactoryMethodSmooth:void 0}),th.prototype=Object.assign(Object.create(Hn.prototype),{constructor:th,ValueTypeName:"string",ValueBufferType:Array,DefaultInterpolation:2300,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0}),wa.prototype=Object.assign(Object.create(Hn.prototype),{constructor:wa,ValueTypeName:"vector"}),Object.assign(_r,{parse:function(t){for(var e=[],i=t.tracks,n=1/(t.fps||1),s=0,l=i.length;s!==l;++s)e.push(Xc(i[s]).scale(n));return new _r(t.name,t.duration,e)},toJSON:function(t){var e=[],i=t.tracks;t={name:t.name,duration:t.duration,tracks:e,uuid:t.uuid};for(var n=0,s=i.length;n!==s;++n)e.push(Hn.toJSON(i[n]));return t},CreateFromMorphTargetSequence:function(t,e,i,n){for(var s=e.length,l=[],d=0;d<s;d++){var p=[],_=[];p.push((d+s-1)%s,d,(d+1)%s),_.push(0,1,0);var T=Yn.getKeyframeOrder(p);p=Yn.sortedArray(p,1,T),_=Yn.sortedArray(_,1,T),n||p[0]!==0||(p.push(s),_.push(_[0])),l.push(new $r(".morphTargetInfluences["+e[d].name+"]",p,_).scale(1/i))}return new _r(t,-1,l)},findByName:function(t,e){var i=t;for(Array.isArray(t)||(i=t.geometry&&t.geometry.animations||t.animations),t=0;t<i.length;t++)if(i[t].name===e)return i[t];return null},CreateClipsFromMorphTargetSequences:function(t,e,i){for(var n={},s=/^([\w-]*?)([\d]+)$/,l=0,d=t.length;l<d;l++){var p=t[l],_=p.name.match(s);if(_&&1<_.length){var T=_[1];(_=n[T])||(n[T]=_=[]),_.push(p)}}t=[];for(T in n)t.push(_r.CreateFromMorphTargetSequence(T,n[T],e,i));return t},parseAnimation:function(t,e){if(!t)return null;var i=function(J,rt,xt,gt,Ct){if(xt.length!==0){var wt=[],Vt=[];Yn.flattenJSON(xt,wt,Vt,gt),wt.length!==0&&Ct.push(new J(rt,wt,Vt))}},n=[],s=t.name||"default",l=t.length||-1,d=t.fps||30;t=t.hierarchy||[];for(var p=0;p<t.length;p++){var _=t[p].keys;if(_&&_.length!==0)if(_[0].morphTargets){l={};for(var T=0;T<_.length;T++)if(_[T].morphTargets)for(var A=0;A<_[T].morphTargets.length;A++)l[_[T].morphTargets[A]]=-1;for(var L in l){var B=[],H=[];for(A=0;A!==_[T].morphTargets.length;++A){var q=_[T];B.push(q.time),H.push(q.morphTarget===L?1:0)}n.push(new $r(".morphTargetInfluence["+L+"]",B,H))}l=l.length*(d||1)}else T=".bones["+e[p].name+"]",i(wa,T+".position",_,"pos",n),i(xa,T+".quaternion",_,"rot",n),i(wa,T+".scale",_,"scl",n)}return n.length===0?null:new _r(s,l,n)}}),Object.assign(_r.prototype,{resetDuration:function(){for(var t=0,e=0,i=this.tracks.length;e!==i;++e){var n=this.tracks[e];t=Math.max(t,n.times[n.times.length-1])}return this.duration=t,this},trim:function(){for(var t=0;t<this.tracks.length;t++)this.tracks[t].trim(0,this.duration);return this},validate:function(){for(var t=!0,e=0;e<this.tracks.length;e++)t=t&&this.tracks[e].validate();return t},optimize:function(){for(var t=0;t<this.tracks.length;t++)this.tracks[t].optimize();return this}});var Mo={enabled:!1,files:{},add:function(t,e){this.enabled!==!1&&(this.files[t]=e)},get:function(t){if(this.enabled!==!1)return this.files[t]},remove:function(t){delete this.files[t]},clear:function(){this.files={}}},tr=new is,Br={};Object.assign(Lt.prototype,{load:function(t,e,i,n){t===void 0&&(t=""),this.path!==void 0&&(t=this.path+t),t=this.manager.resolveURL(t);var s=this,l=Mo.get(t);if(l!==void 0)return s.manager.itemStart(t),setTimeout(function(){e&&e(l),s.manager.itemEnd(t)},0),l;if(Br[t]!==void 0)Br[t].push({onLoad:e,onProgress:i,onError:n});else{var d=t.match(/^data:(.*?)(;base64)?,(.*)$/);if(d){i=d[1];var p=!!d[2];d=d[3],d=decodeURIComponent(d),p&&(d=atob(d));try{var _=(this.responseType||"").toLowerCase();switch(_){case"arraybuffer":case"blob":var T=new Uint8Array(d.length);for(p=0;p<d.length;p++)T[p]=d.charCodeAt(p);var A=_==="blob"?new Blob([T.buffer],{type:i}):T.buffer;break;case"document":A=new DOMParser().parseFromString(d,i);break;case"json":A=JSON.parse(d);break;default:A=d}setTimeout(function(){e&&e(A),s.manager.itemEnd(t)},0)}catch(B){setTimeout(function(){n&&n(B),s.manager.itemError(t),s.manager.itemEnd(t)},0)}}else{Br[t]=[],Br[t].push({onLoad:e,onProgress:i,onError:n});var L=new XMLHttpRequest;L.open("GET",t,!0),L.addEventListener("load",function(B){var H=this.response;Mo.add(t,H);var q=Br[t];if(delete Br[t],this.status===200||this.status===0){this.status;for(var J=0,rt=q.length;J<rt;J++){var xt=q[J];xt.onLoad&&xt.onLoad(H)}}else{for(J=0,rt=q.length;J<rt;J++)xt=q[J],xt.onError&&xt.onError(B);s.manager.itemError(t)}s.manager.itemEnd(t)},!1),L.addEventListener("progress",function(B){for(var H=Br[t],q=0,J=H.length;q<J;q++){var rt=H[q];rt.onProgress&&rt.onProgress(B)}},!1),L.addEventListener("error",function(B){var H=Br[t];delete Br[t];for(var q=0,J=H.length;q<J;q++){var rt=H[q];rt.onError&&rt.onError(B)}s.manager.itemError(t),s.manager.itemEnd(t)},!1),L.addEventListener("abort",function(B){var H=Br[t];delete Br[t];for(var q=0,J=H.length;q<J;q++){var rt=H[q];rt.onError&&rt.onError(B)}s.manager.itemError(t),s.manager.itemEnd(t)},!1),this.responseType!==void 0&&(L.responseType=this.responseType),this.withCredentials!==void 0&&(L.withCredentials=this.withCredentials),L.overrideMimeType&&L.overrideMimeType(this.mimeType!==void 0?this.mimeType:"text/plain");for(p in this.requestHeader)L.setRequestHeader(p,this.requestHeader[p]);L.send(null)}return s.manager.itemStart(t),L}},setPath:function(t){return this.path=t,this},setResponseType:function(t){return this.responseType=t,this},setWithCredentials:function(t){return this.withCredentials=t,this},setMimeType:function(t){return this.mimeType=t,this},setRequestHeader:function(t){return this.requestHeader=t,this}}),Object.assign(Qt.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(s.manager);l.setPath(s.path),l.load(t,function(d){e(s.parse(JSON.parse(d)))},i,n)},parse:function(t,e){for(var i=[],n=0;n<t.length;n++){var s=_r.parse(t[n]);i.push(s)}e(i)},setPath:function(t){return this.path=t,this}}),Object.assign(Zt.prototype,{load:function(t,e,i,n){function s(B){_.load(t[B],function(H){H=l._parser(H,!0),d[B]={width:H.width,height:H.height,format:H.format,mipmaps:H.mipmaps},T+=1,T===6&&(H.mipmapCount===1&&(p.minFilter=1006),p.format=H.format,p.needsUpdate=!0,e&&e(p))},i,n)}var l=this,d=[],p=new Zo;p.image=d;var _=new Lt(this.manager);if(_.setPath(this.path),_.setResponseType("arraybuffer"),Array.isArray(t))for(var T=0,A=0,L=t.length;A<L;++A)s(A);else _.load(t,function(B){if(B=l._parser(B,!0),B.isCubemap)for(var H=B.mipmaps.length/B.mipmapCount,q=0;q<H;q++){d[q]={mipmaps:[]};for(var J=0;J<B.mipmapCount;J++)d[q].mipmaps.push(B.mipmaps[q*B.mipmapCount+J]),d[q].format=B.format,d[q].width=B.width,d[q].height=B.height}else p.image.width=B.width,p.image.height=B.height,p.mipmaps=B.mipmaps;B.mipmapCount===1&&(p.minFilter=1006),p.format=B.format,p.needsUpdate=!0,e&&e(p)},i,n);return p},setPath:function(t){return this.path=t,this}}),Object.assign(Ue.prototype,{load:function(t,e,i,n){var s=this,l=new O,d=new Lt(this.manager);return d.setResponseType("arraybuffer"),d.setPath(this.path),d.load(t,function(p){(p=s._parser(p))&&(p.image!==void 0?l.image=p.image:p.data!==void 0&&(l.image.width=p.width,l.image.height=p.height,l.image.data=p.data),l.wrapS=p.wrapS!==void 0?p.wrapS:1001,l.wrapT=p.wrapT!==void 0?p.wrapT:1001,l.magFilter=p.magFilter!==void 0?p.magFilter:1006,l.minFilter=p.minFilter!==void 0?p.minFilter:1008,l.anisotropy=p.anisotropy!==void 0?p.anisotropy:1,p.format!==void 0&&(l.format=p.format),p.type!==void 0&&(l.type=p.type),p.mipmaps!==void 0&&(l.mipmaps=p.mipmaps),p.mipmapCount===1&&(l.minFilter=1006),l.needsUpdate=!0,e&&e(l,p))},i,n),l},setPath:function(t){return this.path=t,this}}),Object.assign(ai.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){function s(){_.removeEventListener("load",s,!1),_.removeEventListener("error",l,!1),Mo.add(t,this),e&&e(this),d.manager.itemEnd(t)}function l(T){_.removeEventListener("load",s,!1),_.removeEventListener("error",l,!1),n&&n(T),d.manager.itemError(t),d.manager.itemEnd(t)}t===void 0&&(t=""),this.path!==void 0&&(t=this.path+t),t=this.manager.resolveURL(t);var d=this,p=Mo.get(t);if(p!==void 0)return d.manager.itemStart(t),setTimeout(function(){e&&e(p),d.manager.itemEnd(t)},0),p;var _=document.createElementNS("http://www.w3.org/1999/xhtml","img");return _.addEventListener("load",s,!1),_.addEventListener("error",l,!1),t.substr(0,5)!=="data:"&&this.crossOrigin!==void 0&&(_.crossOrigin=this.crossOrigin),d.manager.itemStart(t),_.src=t,_},setCrossOrigin:function(t){return this.crossOrigin=t,this},setPath:function(t){return this.path=t,this}}),Object.assign(Fi.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){function s(_){d.load(t[_],function(T){l.images[_]=T,p++,p===6&&(l.needsUpdate=!0,e&&e(l))},void 0,n)}var l=new z,d=new ai(this.manager);d.setCrossOrigin(this.crossOrigin),d.setPath(this.path);var p=0;for(i=0;i<t.length;++i)s(i);return l},setCrossOrigin:function(t){return this.crossOrigin=t,this},setPath:function(t){return this.path=t,this}}),Object.assign(fn.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){var s=new g,l=new ai(this.manager);return l.setCrossOrigin(this.crossOrigin),l.setPath(this.path),l.load(t,function(d){s.image=d,d=0<t.search(/\.jpe?g$/i)||t.search(/^data:image\/jpeg/)===0,s.format=d?1022:1023,s.needsUpdate=!0,e!==void 0&&e(s)},i,n),s},setCrossOrigin:function(t){return this.crossOrigin=t,this},setPath:function(t){return this.path=t,this}}),Object.assign(Ee.prototype,{getPoint:function(){return null},getPointAt:function(t,e){return t=this.getUtoTmapping(t),this.getPoint(t,e)},getPoints:function(t){t===void 0&&(t=5);for(var e=[],i=0;i<=t;i++)e.push(this.getPoint(i/t));return e},getSpacedPoints:function(t){t===void 0&&(t=5);for(var e=[],i=0;i<=t;i++)e.push(this.getPointAt(i/t));return e},getLength:function(){var t=this.getLengths();return t[t.length-1]},getLengths:function(t){if(t===void 0&&(t=this.arcLengthDivisions),this.cacheArcLengths&&this.cacheArcLengths.length===t+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;var e=[],i=this.getPoint(0),n,s=0;for(e.push(0),n=1;n<=t;n++){var l=this.getPoint(n/t);s+=l.distanceTo(i),e.push(s),i=l}return this.cacheArcLengths=e},updateArcLengths:function(){this.needsUpdate=!0,this.getLengths()},getUtoTmapping:function(t,e){var i=this.getLengths(),n=i.length;e=e||t*i[n-1];for(var s=0,l=n-1,d;s<=l;)if(t=Math.floor(s+(l-s)/2),d=i[t]-e,0>d)s=t+1;else if(0<d)l=t-1;else{l=t;break}return t=l,i[t]===e?t/(n-1):(s=i[t],(t+(e-s)/(i[t+1]-s))/(n-1))},getTangent:function(t){var e=t-1e-4;return t+=1e-4,0>e&&(e=0),1<t&&(t=1),e=this.getPoint(e),this.getPoint(t).clone().sub(e).normalize()},getTangentAt:function(t){return t=this.getUtoTmapping(t),this.getTangent(t)},computeFrenetFrames:function(t,e){var i=new u,n=[],s=[],l=[],d=new u,p=new c,_;for(_=0;_<=t;_++){var T=_/t;n[_]=this.getTangentAt(T),n[_].normalize()}s[0]=new u,l[0]=new u,_=Number.MAX_VALUE,T=Math.abs(n[0].x);var A=Math.abs(n[0].y),L=Math.abs(n[0].z);for(T<=_&&(_=T,i.set(1,0,0)),A<=_&&(_=A,i.set(0,1,0)),L<=_&&i.set(0,0,1),d.crossVectors(n[0],i).normalize(),s[0].crossVectors(n[0],d),l[0].crossVectors(n[0],s[0]),_=1;_<=t;_++)s[_]=s[_-1].clone(),l[_]=l[_-1].clone(),d.crossVectors(n[_-1],n[_]),d.length()>Number.EPSILON&&(d.normalize(),i=Math.acos(di.clamp(n[_-1].dot(n[_]),-1,1)),s[_].applyMatrix4(p.makeRotationAxis(d,i))),l[_].crossVectors(n[_],s[_]);if(e===!0)for(i=Math.acos(di.clamp(s[0].dot(s[t]),-1,1)),i/=t,0<n[0].dot(d.crossVectors(s[0],s[t]))&&(i=-i),_=1;_<=t;_++)s[_].applyMatrix4(p.makeRotationAxis(n[_],i*_)),l[_].crossVectors(n[_],s[_]);return{tangents:n,normals:s,binormals:l}},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.arcLengthDivisions=t.arcLengthDivisions,this},toJSON:function(){var t={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return t.arcLengthDivisions=this.arcLengthDivisions,t.type=this.type,t},fromJSON:function(t){return this.arcLengthDivisions=t.arcLengthDivisions,this}}),Kn.prototype=Object.create(Ee.prototype),Kn.prototype.constructor=Kn,Kn.prototype.isEllipseCurve=!0,Kn.prototype.getPoint=function(t,e){e=e||new o;for(var i=2*Math.PI,n=this.aEndAngle-this.aStartAngle,s=Math.abs(n)<Number.EPSILON;0>n;)n+=i;for(;n>i;)n-=i;n<Number.EPSILON&&(n=s?0:i),this.aClockwise!==!0||s||(n=n===i?-i:n-i),i=this.aStartAngle+t*n,t=this.aX+this.xRadius*Math.cos(i);var l=this.aY+this.yRadius*Math.sin(i);return this.aRotation!==0&&(i=Math.cos(this.aRotation),n=Math.sin(this.aRotation),s=t-this.aX,l-=this.aY,t=s*i-l*n+this.aX,l=s*n+l*i+this.aY),e.set(t,l)},Kn.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.aX=t.aX,this.aY=t.aY,this.xRadius=t.xRadius,this.yRadius=t.yRadius,this.aStartAngle=t.aStartAngle,this.aEndAngle=t.aEndAngle,this.aClockwise=t.aClockwise,this.aRotation=t.aRotation,this},Kn.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.aX=this.aX,t.aY=this.aY,t.xRadius=this.xRadius,t.yRadius=this.yRadius,t.aStartAngle=this.aStartAngle,t.aEndAngle=this.aEndAngle,t.aClockwise=this.aClockwise,t.aRotation=this.aRotation,t},Kn.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.aX=t.aX,this.aY=t.aY,this.xRadius=t.xRadius,this.yRadius=t.yRadius,this.aStartAngle=t.aStartAngle,this.aEndAngle=t.aEndAngle,this.aClockwise=t.aClockwise,this.aRotation=t.aRotation,this},Ta.prototype=Object.create(Kn.prototype),Ta.prototype.constructor=Ta,Ta.prototype.isArcCurve=!0;var bn=new u,Ml=new lr,lh=new lr,Nr=new lr;On.prototype=Object.create(Ee.prototype),On.prototype.constructor=On,On.prototype.isCatmullRomCurve3=!0,On.prototype.getPoint=function(t,e){e=e||new u;var i=this.points,n=i.length;t*=n-(this.closed?0:1);var s=Math.floor(t);if(t-=s,this.closed?s+=0<s?0:(Math.floor(Math.abs(s)/n)+1)*n:t===0&&s===n-1&&(s=n-2,t=1),this.closed||0<s)var l=i[(s-1)%n];else bn.subVectors(i[0],i[1]).add(i[0]),l=bn;var d=i[s%n],p=i[(s+1)%n];if(this.closed||s+2<n?i=i[(s+2)%n]:(bn.subVectors(i[n-1],i[n-2]).add(i[n-1]),i=bn),this.curveType==="centripetal"||this.curveType==="chordal"){var _=this.curveType==="chordal"?.5:.25;n=Math.pow(l.distanceToSquared(d),_),s=Math.pow(d.distanceToSquared(p),_),_=Math.pow(p.distanceToSquared(i),_),1e-4>s&&(s=1),1e-4>n&&(n=s),1e-4>_&&(_=s),Ml.initNonuniformCatmullRom(l.x,d.x,p.x,i.x,n,s,_),lh.initNonuniformCatmullRom(l.y,d.y,p.y,i.y,n,s,_),Nr.initNonuniformCatmullRom(l.z,d.z,p.z,i.z,n,s,_)}else this.curveType==="catmullrom"&&(Ml.initCatmullRom(l.x,d.x,p.x,i.x,this.tension),lh.initCatmullRom(l.y,d.y,p.y,i.y,this.tension),Nr.initCatmullRom(l.z,d.z,p.z,i.z,this.tension));return e.set(Ml.calc(t),lh.calc(t),Nr.calc(t)),e},On.prototype.copy=function(t){Ee.prototype.copy.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++)this.points.push(t.points[e].clone());return this.closed=t.closed,this.curveType=t.curveType,this.tension=t.tension,this},On.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);t.points=[];for(var e=0,i=this.points.length;e<i;e++)t.points.push(this.points[e].toArray());return t.closed=this.closed,t.curveType=this.curveType,t.tension=this.tension,t},On.prototype.fromJSON=function(t){Ee.prototype.fromJSON.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++){var n=t.points[e];this.points.push(new u().fromArray(n))}return this.closed=t.closed,this.curveType=t.curveType,this.tension=t.tension,this},hr.prototype=Object.create(Ee.prototype),hr.prototype.constructor=hr,hr.prototype.isCubicBezierCurve=!0,hr.prototype.getPoint=function(t,e){e=e||new o;var i=this.v0,n=this.v1,s=this.v2,l=this.v3;return e.set(ns(t,i.x,n.x,s.x,l.x),ns(t,i.y,n.y,s.y,l.y)),e},hr.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this.v3.copy(t.v3),this},hr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t.v3=this.v3.toArray(),t},hr.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this.v3.fromArray(t.v3),this},Ti.prototype=Object.create(Ee.prototype),Ti.prototype.constructor=Ti,Ti.prototype.isCubicBezierCurve3=!0,Ti.prototype.getPoint=function(t,e){e=e||new u;var i=this.v0,n=this.v1,s=this.v2,l=this.v3;return e.set(ns(t,i.x,n.x,s.x,l.x),ns(t,i.y,n.y,s.y,l.y),ns(t,i.z,n.z,s.z,l.z)),e},Ti.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this.v3.copy(t.v3),this},Ti.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t.v3=this.v3.toArray(),t},Ti.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this.v3.fromArray(t.v3),this},ur.prototype=Object.create(Ee.prototype),ur.prototype.constructor=ur,ur.prototype.isLineCurve=!0,ur.prototype.getPoint=function(t,e){return e=e||new o,t===1?e.copy(this.v2):(e.copy(this.v2).sub(this.v1),e.multiplyScalar(t).add(this.v1)),e},ur.prototype.getPointAt=function(t,e){return this.getPoint(t,e)},ur.prototype.getTangent=function(){return this.v2.clone().sub(this.v1).normalize()},ur.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v1.copy(t.v1),this.v2.copy(t.v2),this},ur.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},ur.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},zr.prototype=Object.create(Ee.prototype),zr.prototype.constructor=zr,zr.prototype.isLineCurve3=!0,zr.prototype.getPoint=function(t,e){return e=e||new u,t===1?e.copy(this.v2):(e.copy(this.v2).sub(this.v1),e.multiplyScalar(t).add(this.v1)),e},zr.prototype.getPointAt=function(t,e){return this.getPoint(t,e)},zr.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v1.copy(t.v1),this.v2.copy(t.v2),this},zr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},zr.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},cr.prototype=Object.create(Ee.prototype),cr.prototype.constructor=cr,cr.prototype.isQuadraticBezierCurve=!0,cr.prototype.getPoint=function(t,e){e=e||new o;var i=this.v0,n=this.v1,s=this.v2;return e.set(vo(t,i.x,n.x,s.x),vo(t,i.y,n.y,s.y)),e},cr.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this},cr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},cr.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},yo.prototype=Object.create(Ee.prototype),yo.prototype.constructor=yo,yo.prototype.isQuadraticBezierCurve3=!0,yo.prototype.getPoint=function(t,e){e=e||new u;var i=this.v0,n=this.v1,s=this.v2;return e.set(vo(t,i.x,n.x,s.x),vo(t,i.y,n.y,s.y),vo(t,i.z,n.z,s.z)),e},yo.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this},yo.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},yo.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},Kr.prototype=Object.create(Ee.prototype),Kr.prototype.constructor=Kr,Kr.prototype.isSplineCurve=!0,Kr.prototype.getPoint=function(t,e){e=e||new o;var i=this.points,n=(i.length-1)*t;t=Math.floor(n),n-=t;var s=i[t===0?t:t-1],l=i[t],d=i[t>i.length-2?i.length-1:t+1];return i=i[t>i.length-3?i.length-1:t+2],e.set(Pu(n,s.x,l.x,d.x,i.x),Pu(n,s.y,l.y,d.y,i.y)),e},Kr.prototype.copy=function(t){Ee.prototype.copy.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++)this.points.push(t.points[e].clone());return this},Kr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);t.points=[];for(var e=0,i=this.points.length;e<i;e++)t.points.push(this.points[e].toArray());return t},Kr.prototype.fromJSON=function(t){Ee.prototype.fromJSON.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++){var n=t.points[e];this.points.push(new o().fromArray(n))}return this};var hh=Object.freeze({ArcCurve:Ta,CatmullRomCurve3:On,CubicBezierCurve:hr,CubicBezierCurve3:Ti,EllipseCurve:Kn,LineCurve:ur,LineCurve3:zr,QuadraticBezierCurve:cr,QuadraticBezierCurve3:yo,SplineCurve:Kr});Io.prototype=Object.assign(Object.create(Ee.prototype),{constructor:Io,add:function(t){this.curves.push(t)},closePath:function(){var t=this.curves[0].getPoint(0),e=this.curves[this.curves.length-1].getPoint(1);t.equals(e)||this.curves.push(new ur(e,t))},getPoint:function(t){var e=t*this.getLength(),i=this.getCurveLengths();for(t=0;t<i.length;){if(i[t]>=e)return e=i[t]-e,t=this.curves[t],i=t.getLength(),t.getPointAt(i===0?0:1-e/i);t++}return null},getLength:function(){var t=this.getCurveLengths();return t[t.length-1]},updateArcLengths:function(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()},getCurveLengths:function(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;for(var t=[],e=0,i=0,n=this.curves.length;i<n;i++)e+=this.curves[i].getLength(),t.push(e);return this.cacheLengths=t},getSpacedPoints:function(t){t===void 0&&(t=40);for(var e=[],i=0;i<=t;i++)e.push(this.getPoint(i/t));return this.autoClose&&e.push(e[0]),e},getPoints:function(t){t=t||12;for(var e=[],i,n=0,s=this.curves;n<s.length;n++){var l=s[n];l=l.getPoints(l&&l.isEllipseCurve?2*t:l&&(l.isLineCurve||l.isLineCurve3)?1:l&&l.isSplineCurve?t*l.points.length:t);for(var d=0;d<l.length;d++){var p=l[d];i&&i.equals(p)||(e.push(p),i=p)}}return this.autoClose&&1<e.length&&!e[e.length-1].equals(e[0])&&e.push(e[0]),e},copy:function(t){Ee.prototype.copy.call(this,t),this.curves=[];for(var e=0,i=t.curves.length;e<i;e++)this.curves.push(t.curves[e].clone());return this.autoClose=t.autoClose,this},toJSON:function(){var t=Ee.prototype.toJSON.call(this);t.autoClose=this.autoClose,t.curves=[];for(var e=0,i=this.curves.length;e<i;e++)t.curves.push(this.curves[e].toJSON());return t},fromJSON:function(t){Ee.prototype.fromJSON.call(this,t),this.autoClose=t.autoClose,this.curves=[];for(var e=0,i=t.curves.length;e<i;e++){var n=t.curves[e];this.curves.push(new hh[n.type]().fromJSON(n))}return this}}),fr.prototype=Object.assign(Object.create(Io.prototype),{constructor:fr,setFromPoints:function(t){this.moveTo(t[0].x,t[0].y);for(var e=1,i=t.length;e<i;e++)this.lineTo(t[e].x,t[e].y)},moveTo:function(t,e){this.currentPoint.set(t,e)},lineTo:function(t,e){var i=new ur(this.currentPoint.clone(),new o(t,e));this.curves.push(i),this.currentPoint.set(t,e)},quadraticCurveTo:function(t,e,i,n){t=new cr(this.currentPoint.clone(),new o(t,e),new o(i,n)),this.curves.push(t),this.currentPoint.set(i,n)},bezierCurveTo:function(t,e,i,n,s,l){t=new hr(this.currentPoint.clone(),new o(t,e),new o(i,n),new o(s,l)),this.curves.push(t),this.currentPoint.set(s,l)},splineThru:function(t){var e=[this.currentPoint.clone()].concat(t);e=new Kr(e),this.curves.push(e),this.currentPoint.copy(t[t.length-1])},arc:function(t,e,i,n,s,l){this.absarc(t+this.currentPoint.x,e+this.currentPoint.y,i,n,s,l)},absarc:function(t,e,i,n,s,l){this.absellipse(t,e,i,i,n,s,l)},ellipse:function(t,e,i,n,s,l,d,p){this.absellipse(t+this.currentPoint.x,e+this.currentPoint.y,i,n,s,l,d,p)},absellipse:function(t,e,i,n,s,l,d,p){t=new Kn(t,e,i,n,s,l,d,p),0<this.curves.length&&(e=t.getPoint(0),e.equals(this.currentPoint)||this.lineTo(e.x,e.y)),this.curves.push(t),t=t.getPoint(1),this.currentPoint.copy(t)},copy:function(t){return Io.prototype.copy.call(this,t),this.currentPoint.copy(t.currentPoint),this},toJSON:function(){var t=Io.prototype.toJSON.call(this);return t.currentPoint=this.currentPoint.toArray(),t},fromJSON:function(t){return Io.prototype.fromJSON.call(this,t),this.currentPoint.fromArray(t.currentPoint),this}}),Qn.prototype=Object.assign(Object.create(fr.prototype),{constructor:Qn,getPointsHoles:function(t){for(var e=[],i=0,n=this.holes.length;i<n;i++)e[i]=this.holes[i].getPoints(t);return e},extractPoints:function(t){return{shape:this.getPoints(t),holes:this.getPointsHoles(t)}},copy:function(t){fr.prototype.copy.call(this,t),this.holes=[];for(var e=0,i=t.holes.length;e<i;e++)this.holes.push(t.holes[e].clone());return this},toJSON:function(){var t=fr.prototype.toJSON.call(this);t.uuid=this.uuid,t.holes=[];for(var e=0,i=this.holes.length;e<i;e++)t.holes.push(this.holes[e].toJSON());return t},fromJSON:function(t){fr.prototype.fromJSON.call(this,t),this.uuid=t.uuid,this.holes=[];for(var e=0,i=t.holes.length;e<i;e++){var n=t.holes[e];this.holes.push(new fr().fromJSON(n))}return this}}),tn.prototype=Object.assign(Object.create(F.prototype),{constructor:tn,isLight:!0,copy:function(t){return F.prototype.copy.call(this,t),this.color.copy(t.color),this.intensity=t.intensity,this},toJSON:function(t){return t=F.prototype.toJSON.call(this,t),t.object.color=this.color.getHex(),t.object.intensity=this.intensity,this.groundColor!==void 0&&(t.object.groundColor=this.groundColor.getHex()),this.distance!==void 0&&(t.object.distance=this.distance),this.angle!==void 0&&(t.object.angle=this.angle),this.decay!==void 0&&(t.object.decay=this.decay),this.penumbra!==void 0&&(t.object.penumbra=this.penumbra),this.shadow!==void 0&&(t.object.shadow=this.shadow.toJSON()),t}}),al.prototype=Object.assign(Object.create(tn.prototype),{constructor:al,isHemisphereLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.groundColor.copy(t.groundColor),this}}),Object.assign(_o.prototype,{copy:function(t){return this.camera=t.camera.clone(),this.bias=t.bias,this.radius=t.radius,this.mapSize.copy(t.mapSize),this},clone:function(){return new this.constructor().copy(this)},toJSON:function(){var t={};return this.bias!==0&&(t.bias=this.bias),this.radius!==1&&(t.radius=this.radius),(this.mapSize.x!==512||this.mapSize.y!==512)&&(t.mapSize=this.mapSize.toArray()),t.camera=this.camera.toJSON(!1).object,delete t.camera.matrix,t}}),ll.prototype=Object.assign(Object.create(_o.prototype),{constructor:ll,isSpotLightShadow:!0,update:function(t){var e=this.camera,i=2*di.RAD2DEG*t.angle,n=this.mapSize.width/this.mapSize.height;t=t.distance||e.far,(i!==e.fov||n!==e.aspect||t!==e.far)&&(e.fov=i,e.aspect=n,e.far=t,e.updateProjectionMatrix())}}),hl.prototype=Object.assign(Object.create(tn.prototype),{constructor:hl,isSpotLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.distance=t.distance,this.angle=t.angle,this.penumbra=t.penumbra,this.decay=t.decay,this.target=t.target.clone(),this.shadow=t.shadow.clone(),this}}),Ds.prototype=Object.assign(Object.create(tn.prototype),{constructor:Ds,isPointLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.distance=t.distance,this.decay=t.decay,this.shadow=t.shadow.clone(),this}}),Ma.prototype=Object.assign(Object.create(Be.prototype),{constructor:Ma,isOrthographicCamera:!0,copy:function(t,e){return Be.prototype.copy.call(this,t,e),this.left=t.left,this.right=t.right,this.top=t.top,this.bottom=t.bottom,this.near=t.near,this.far=t.far,this.zoom=t.zoom,this.view=t.view===null?null:Object.assign({},t.view),this},setViewOffset:function(t,e,i,n,s,l){this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=t,this.view.fullHeight=e,this.view.offsetX=i,this.view.offsetY=n,this.view.width=s,this.view.height=l,this.updateProjectionMatrix()},clearViewOffset:function(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()},updateProjectionMatrix:function(){var t=(this.right-this.left)/(2*this.zoom),e=(this.top-this.bottom)/(2*this.zoom),i=(this.right+this.left)/2,n=(this.top+this.bottom)/2,s=i-t;if(i+=t,t=n+e,e=n-e,this.view!==null&&this.view.enabled){i=this.zoom/(this.view.width/this.view.fullWidth),e=this.zoom/(this.view.height/this.view.fullHeight);var l=(this.right-this.left)/this.view.width;n=(this.top-this.bottom)/this.view.height,s+=this.view.offsetX/i*l,i=s+this.view.width/i*l,t-=this.view.offsetY/e*n,e=t-this.view.height/e*n}this.projectionMatrix.makeOrthographic(s,i,t,e,this.near,this.far),this.projectionMatrixInverse.getInverse(this.projectionMatrix)},toJSON:function(t){return t=F.prototype.toJSON.call(this,t),t.object.zoom=this.zoom,t.object.left=this.left,t.object.right=this.right,t.object.top=this.top,t.object.bottom=this.bottom,t.object.near=this.near,t.object.far=this.far,this.view!==null&&(t.object.view=Object.assign({},this.view)),t}}),rs.prototype=Object.assign(Object.create(_o.prototype),{constructor:rs}),xo.prototype=Object.assign(Object.create(tn.prototype),{constructor:xo,isDirectionalLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.target=t.target.clone(),this.shadow=t.shadow.clone(),this}}),zs.prototype=Object.assign(Object.create(tn.prototype),{constructor:zs,isAmbientLight:!0}),eh.prototype=Object.assign(Object.create(tn.prototype),{constructor:eh,isRectAreaLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.width=t.width,this.height=t.height,this},toJSON:function(t){return t=tn.prototype.toJSON.call(this,t),t.object.width=this.width,t.object.height=this.height,t}}),Object.assign(ih.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(s.manager);l.setPath(s.path),l.load(t,function(d){e(s.parse(JSON.parse(d)))},i,n)},parse:function(t){function e(d){return i[d],i[d]}var i=this.textures,n=new Fu[t.type];if(t.uuid!==void 0&&(n.uuid=t.uuid),t.name!==void 0&&(n.name=t.name),t.color!==void 0&&n.color.setHex(t.color),t.roughness!==void 0&&(n.roughness=t.roughness),t.metalness!==void 0&&(n.metalness=t.metalness),t.emissive!==void 0&&n.emissive.setHex(t.emissive),t.specular!==void 0&&n.specular.setHex(t.specular),t.shininess!==void 0&&(n.shininess=t.shininess),t.clearCoat!==void 0&&(n.clearCoat=t.clearCoat),t.clearCoatRoughness!==void 0&&(n.clearCoatRoughness=t.clearCoatRoughness),t.vertexColors!==void 0&&(n.vertexColors=t.vertexColors),t.fog!==void 0&&(n.fog=t.fog),t.flatShading!==void 0&&(n.flatShading=t.flatShading),t.blending!==void 0&&(n.blending=t.blending),t.combine!==void 0&&(n.combine=t.combine),t.side!==void 0&&(n.side=t.side),t.opacity!==void 0&&(n.opacity=t.opacity),t.transparent!==void 0&&(n.transparent=t.transparent),t.alphaTest!==void 0&&(n.alphaTest=t.alphaTest),t.depthTest!==void 0&&(n.depthTest=t.depthTest),t.depthWrite!==void 0&&(n.depthWrite=t.depthWrite),t.colorWrite!==void 0&&(n.colorWrite=t.colorWrite),t.wireframe!==void 0&&(n.wireframe=t.wireframe),t.wireframeLinewidth!==void 0&&(n.wireframeLinewidth=t.wireframeLinewidth),t.wireframeLinecap!==void 0&&(n.wireframeLinecap=t.wireframeLinecap),t.wireframeLinejoin!==void 0&&(n.wireframeLinejoin=t.wireframeLinejoin),t.rotation!==void 0&&(n.rotation=t.rotation),t.linewidth!==1&&(n.linewidth=t.linewidth),t.dashSize!==void 0&&(n.dashSize=t.dashSize),t.gapSize!==void 0&&(n.gapSize=t.gapSize),t.scale!==void 0&&(n.scale=t.scale),t.polygonOffset!==void 0&&(n.polygonOffset=t.polygonOffset),t.polygonOffsetFactor!==void 0&&(n.polygonOffsetFactor=t.polygonOffsetFactor),t.polygonOffsetUnits!==void 0&&(n.polygonOffsetUnits=t.polygonOffsetUnits),t.skinning!==void 0&&(n.skinning=t.skinning),t.morphTargets!==void 0&&(n.morphTargets=t.morphTargets),t.dithering!==void 0&&(n.dithering=t.dithering),t.visible!==void 0&&(n.visible=t.visible),t.userData!==void 0&&(n.userData=t.userData),t.uniforms!==void 0)for(var s in t.uniforms){var l=t.uniforms[s];switch(n.uniforms[s]={},l.type){case"t":n.uniforms[s].value=e(l.value);break;case"c":n.uniforms[s].value=new P().setHex(l.value);break;case"v2":n.uniforms[s].value=new o().fromArray(l.value);break;case"v3":n.uniforms[s].value=new u().fromArray(l.value);break;case"v4":n.uniforms[s].value=new v().fromArray(l.value);break;case"m4":n.uniforms[s].value=new c().fromArray(l.value);break;default:n.uniforms[s].value=l.value}}return t.defines!==void 0&&(n.defines=t.defines),t.vertexShader!==void 0&&(n.vertexShader=t.vertexShader),t.fragmentShader!==void 0&&(n.fragmentShader=t.fragmentShader),t.shading!==void 0&&(n.flatShading=t.shading===1),t.size!==void 0&&(n.size=t.size),t.sizeAttenuation!==void 0&&(n.sizeAttenuation=t.sizeAttenuation),t.map!==void 0&&(n.map=e(t.map)),t.alphaMap!==void 0&&(n.alphaMap=e(t.alphaMap),n.transparent=!0),t.bumpMap!==void 0&&(n.bumpMap=e(t.bumpMap)),t.bumpScale!==void 0&&(n.bumpScale=t.bumpScale),t.normalMap!==void 0&&(n.normalMap=e(t.normalMap)),t.normalMapType!==void 0&&(n.normalMapType=t.normalMapType),t.normalScale!==void 0&&(s=t.normalScale,Array.isArray(s)===!1&&(s=[s,s]),n.normalScale=new o().fromArray(s)),t.displacementMap!==void 0&&(n.displacementMap=e(t.displacementMap)),t.displacementScale!==void 0&&(n.displacementScale=t.displacementScale),t.displacementBias!==void 0&&(n.displacementBias=t.displacementBias),t.roughnessMap!==void 0&&(n.roughnessMap=e(t.roughnessMap)),t.metalnessMap!==void 0&&(n.metalnessMap=e(t.metalnessMap)),t.emissiveMap!==void 0&&(n.emissiveMap=e(t.emissiveMap)),t.emissiveIntensity!==void 0&&(n.emissiveIntensity=t.emissiveIntensity),t.specularMap!==void 0&&(n.specularMap=e(t.specularMap)),t.envMap!==void 0&&(n.envMap=e(t.envMap)),t.envMapIntensity!==void 0&&(n.envMapIntensity=t.envMapIntensity),t.reflectivity!==void 0&&(n.reflectivity=t.reflectivity),t.lightMap!==void 0&&(n.lightMap=e(t.lightMap)),t.lightMapIntensity!==void 0&&(n.lightMapIntensity=t.lightMapIntensity),t.aoMap!==void 0&&(n.aoMap=e(t.aoMap)),t.aoMapIntensity!==void 0&&(n.aoMapIntensity=t.aoMapIntensity),t.gradientMap!==void 0&&(n.gradientMap=e(t.gradientMap)),n},setPath:function(t){return this.path=t,this},setTextures:function(t){return this.textures=t,this}});var Gs={decodeText:function(t){if(typeof TextDecoder<"u")return new TextDecoder().decode(t);for(var e="",i=0,n=t.length;i<n;i++)e+=String.fromCharCode(t[i]);return decodeURIComponent(escape(e))},extractUrlBase:function(t){var e=t.lastIndexOf("/");return e===-1?"./":t.substr(0,e+1)}};Object.assign(Nh.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(s.manager);l.setPath(s.path),l.load(t,function(d){e(s.parse(JSON.parse(d)))},i,n)},parse:function(t){var e=new Ft,i=t.data.index;i!==void 0&&(i=new hs[i.type](i.array),e.setIndex(new K(i,1)));var n=t.data.attributes;for(l in n){var s=n[l];i=new hs[s.type](s.array),e.addAttribute(l,new K(i,s.itemSize,s.normalized))}var l=t.data.groups||t.data.drawcalls||t.data.offsets;if(l!==void 0)for(i=0,n=l.length;i!==n;++i)s=l[i],e.addGroup(s.start,s.count,s.materialIndex);return t=t.data.boundingSphere,t!==void 0&&(l=new u,t.center!==void 0&&l.fromArray(t.center),e.boundingSphere=new I(l,t.radius)),e},setPath:function(t){return this.path=t,this}});var hs={Int8Array,Uint8Array,Uint8ClampedArray:typeof Uint8ClampedArray<"u"?Uint8ClampedArray:Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array};Do.Handlers={handlers:[],add:function(t,e){this.handlers.push(t,e)},get:function(t){for(var e=this.handlers,i=0,n=e.length;i<n;i+=2){var s=e[i+1];if(e[i].test(t))return s}return null}},Object.assign(Do.prototype,{crossOrigin:"anonymous",onLoadStart:function(){},onLoadProgress:function(){},onLoadComplete:function(){},initMaterials:function(t,e,i){for(var n=[],s=0;s<t.length;++s)n[s]=this.createMaterial(t[s],e,i);return n},createMaterial:function(){var t={NoBlending:0,NormalBlending:1,AdditiveBlending:2,SubtractiveBlending:3,MultiplyBlending:4,CustomBlending:5},e=new P,i=new fn,n=new ih;return function(s,l,d){function p(B,H,q,J,rt){B=l+B;var xt=Do.Handlers.get(B);return xt!==null?B=xt.load(B):(i.setCrossOrigin(d),B=i.load(B)),H!==void 0&&(B.repeat.fromArray(H),H[0]!==1&&(B.wrapS=1e3),H[1]!==1&&(B.wrapT=1e3)),q!==void 0&&B.offset.fromArray(q),J!==void 0&&(J[0]==="repeat"&&(B.wrapS=1e3),J[0]==="mirror"&&(B.wrapS=1002),J[1]==="repeat"&&(B.wrapT=1e3),J[1]==="mirror"&&(B.wrapT=1002)),rt!==void 0&&(B.anisotropy=rt),H=di.generateUUID(),_[H]=B,H}var _={},T={uuid:di.generateUUID(),type:"MeshLambertMaterial"},A;for(A in s){var L=s[A];switch(A){case"DbgColor":case"DbgIndex":case"opticalDensity":case"illumination":break;case"DbgName":T.name=L;break;case"blending":T.blending=t[L];break;case"colorAmbient":case"mapAmbient":break;case"colorDiffuse":T.color=e.fromArray(L).getHex();break;case"colorSpecular":T.specular=e.fromArray(L).getHex();break;case"colorEmissive":T.emissive=e.fromArray(L).getHex();break;case"specularCoef":T.shininess=L;break;case"shading":L.toLowerCase()==="basic"&&(T.type="MeshBasicMaterial"),L.toLowerCase()==="phong"&&(T.type="MeshPhongMaterial"),L.toLowerCase()==="standard"&&(T.type="MeshStandardMaterial");break;case"mapDiffuse":T.map=p(L,s.mapDiffuseRepeat,s.mapDiffuseOffset,s.mapDiffuseWrap,s.mapDiffuseAnisotropy);break;case"mapDiffuseRepeat":case"mapDiffuseOffset":case"mapDiffuseWrap":case"mapDiffuseAnisotropy":break;case"mapEmissive":T.emissiveMap=p(L,s.mapEmissiveRepeat,s.mapEmissiveOffset,s.mapEmissiveWrap,s.mapEmissiveAnisotropy);break;case"mapEmissiveRepeat":case"mapEmissiveOffset":case"mapEmissiveWrap":case"mapEmissiveAnisotropy":break;case"mapLight":T.lightMap=p(L,s.mapLightRepeat,s.mapLightOffset,s.mapLightWrap,s.mapLightAnisotropy);break;case"mapLightRepeat":case"mapLightOffset":case"mapLightWrap":case"mapLightAnisotropy":break;case"mapAO":T.aoMap=p(L,s.mapAORepeat,s.mapAOOffset,s.mapAOWrap,s.mapAOAnisotropy);break;case"mapAORepeat":case"mapAOOffset":case"mapAOWrap":case"mapAOAnisotropy":break;case"mapBump":T.bumpMap=p(L,s.mapBumpRepeat,s.mapBumpOffset,s.mapBumpWrap,s.mapBumpAnisotropy);break;case"mapBumpScale":T.bumpScale=L;break;case"mapBumpRepeat":case"mapBumpOffset":case"mapBumpWrap":case"mapBumpAnisotropy":break;case"mapNormal":T.normalMap=p(L,s.mapNormalRepeat,s.mapNormalOffset,s.mapNormalWrap,s.mapNormalAnisotropy);break;case"mapNormalFactor":T.normalScale=L;break;case"mapNormalRepeat":case"mapNormalOffset":case"mapNormalWrap":case"mapNormalAnisotropy":break;case"mapSpecular":T.specularMap=p(L,s.mapSpecularRepeat,s.mapSpecularOffset,s.mapSpecularWrap,s.mapSpecularAnisotropy);break;case"mapSpecularRepeat":case"mapSpecularOffset":case"mapSpecularWrap":case"mapSpecularAnisotropy":break;case"mapMetalness":T.metalnessMap=p(L,s.mapMetalnessRepeat,s.mapMetalnessOffset,s.mapMetalnessWrap,s.mapMetalnessAnisotropy);break;case"mapMetalnessRepeat":case"mapMetalnessOffset":case"mapMetalnessWrap":case"mapMetalnessAnisotropy":break;case"mapRoughness":T.roughnessMap=p(L,s.mapRoughnessRepeat,s.mapRoughnessOffset,s.mapRoughnessWrap,s.mapRoughnessAnisotropy);break;case"mapRoughnessRepeat":case"mapRoughnessOffset":case"mapRoughnessWrap":case"mapRoughnessAnisotropy":break;case"mapAlpha":T.alphaMap=p(L,s.mapAlphaRepeat,s.mapAlphaOffset,s.mapAlphaWrap,s.mapAlphaAnisotropy);break;case"mapAlphaRepeat":case"mapAlphaOffset":case"mapAlphaWrap":case"mapAlphaAnisotropy":break;case"flipSided":T.side=1;break;case"doubleSided":T.side=2;break;case"transparency":T.opacity=L;break;case"depthTest":case"depthWrite":case"colorWrite":case"opacity":case"reflectivity":case"transparent":case"visible":case"wireframe":T[A]=L;break;case"vertexColors":L===!0&&(T.vertexColors=2),L==="face"&&(T.vertexColors=1);break;default:}}return T.type==="MeshBasicMaterial"&&delete T.emissive,T.type!=="MeshPhongMaterial"&&delete T.specular,1>T.opacity&&(T.transparent=!0),n.setTextures(_),n.parse(T)}}()}),Object.assign(ks.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){var s=this,l=this.path===void 0?Gs.extractUrlBase(t):this.path,d=new Lt(this.manager);d.setPath(this.path),d.setWithCredentials(this.withCredentials),d.load(t,function(p){p=JSON.parse(p);var _=p.metadata;_!==void 0&&(_=_.type,_!==void 0&&_.toLowerCase()==="object")||(p=s.parse(p,l),e(p.geometry,p.materials))},i,n)},setPath:function(t){return this.path=t,this},setResourcePath:function(t){return this.resourcePath=t,this},setCrossOrigin:function(t){return this.crossOrigin=t,this},parse:function(){return function(t,e){t.data!==void 0&&(t=t.data),t.scale=t.scale!==void 0?1/t.scale:1;var i=new X,n=t,s,l,d,p=n.faces,_=n.vertices,T=n.normals,A=n.colors,L=n.scale,B=0;if(n.uvs!==void 0){for(s=0;s<n.uvs.length;s++)n.uvs[s].length&&B++;for(s=0;s<B;s++)i.faceVertexUvs[s]=[]}var H=0;for(d=_.length;H<d;)s=new u,s.x=_[H++]*L,s.y=_[H++]*L,s.z=_[H++]*L,i.vertices.push(s);for(H=0,d=p.length;H<d;){_=p[H++];var q=_&1,J=_&2;s=_&8;var rt=_&16,xt=_&32;if(L=_&64,_&=128,q){q=new R,q.a=p[H],q.b=p[H+1],q.c=p[H+3];var gt=new R;if(gt.a=p[H+1],gt.b=p[H+2],gt.c=p[H+3],H+=4,J&&(J=p[H++],q.materialIndex=J,gt.materialIndex=J),J=i.faces.length,s)for(s=0;s<B;s++){var Ct=n.uvs[s];for(i.faceVertexUvs[s][J]=[],i.faceVertexUvs[s][J+1]=[],l=0;4>l;l++){var wt=p[H++],Vt=Ct[2*wt];wt=Ct[2*wt+1],Vt=new o(Vt,wt),l!==2&&i.faceVertexUvs[s][J].push(Vt),l!==0&&i.faceVertexUvs[s][J+1].push(Vt)}}if(rt&&(rt=3*p[H++],q.normal.set(T[rt++],T[rt++],T[rt]),gt.normal.copy(q.normal)),xt)for(s=0;4>s;s++)rt=3*p[H++],xt=new u(T[rt++],T[rt++],T[rt]),s!==2&&q.vertexNormals.push(xt),s!==0&>.vertexNormals.push(xt);if(L&&(L=p[H++],L=A[L],q.color.setHex(L),gt.color.setHex(L)),_)for(s=0;4>s;s++)L=p[H++],L=A[L],s!==2&&q.vertexColors.push(new P(L)),s!==0&>.vertexColors.push(new P(L));i.faces.push(q),i.faces.push(gt)}else{if(q=new R,q.a=p[H++],q.b=p[H++],q.c=p[H++],J&&(J=p[H++],q.materialIndex=J),J=i.faces.length,s)for(s=0;s<B;s++)for(Ct=n.uvs[s],i.faceVertexUvs[s][J]=[],l=0;3>l;l++)wt=p[H++],Vt=Ct[2*wt],wt=Ct[2*wt+1],Vt=new o(Vt,wt),i.faceVertexUvs[s][J].push(Vt);if(rt&&(rt=3*p[H++],q.normal.set(T[rt++],T[rt++],T[rt])),xt)for(s=0;3>s;s++)rt=3*p[H++],xt=new u(T[rt++],T[rt++],T[rt]),q.vertexNormals.push(xt);if(L&&(L=p[H++],q.color.setHex(A[L])),_)for(s=0;3>s;s++)L=p[H++],q.vertexColors.push(new P(A[L]));i.faces.push(q)}}if(n=t,H=n.influencesPerVertex!==void 0?n.influencesPerVertex:2,n.skinWeights)for(d=0,p=n.skinWeights.length;d<p;d+=H)i.skinWeights.push(new v(n.skinWeights[d],1<H?n.skinWeights[d+1]:0,2<H?n.skinWeights[d+2]:0,3<H?n.skinWeights[d+3]:0));if(n.skinIndices)for(d=0,p=n.skinIndices.length;d<p;d+=H)i.skinIndices.push(new v(n.skinIndices[d],1<H?n.skinIndices[d+1]:0,2<H?n.skinIndices[d+2]:0,3<H?n.skinIndices[d+3]:0));if(i.bones=n.bones,i.bones&&0<i.bones.length&&(i.skinWeights.length!==i.skinIndices.length||(i.skinIndices.length,i.vertices.length)),d=t,p=d.scale,d.morphTargets!==void 0)for(n=0,H=d.morphTargets.length;n<H;n++)for(i.morphTargets[n]={},i.morphTargets[n].name=d.morphTargets[n].name,i.morphTargets[n].vertices=[],T=i.morphTargets[n].vertices,A=d.morphTargets[n].vertices,B=0,_=A.length;B<_;B+=3)L=new u,L.x=A[B]*p,L.y=A[B+1]*p,L.z=A[B+2]*p,T.push(L);if(d.morphColors!==void 0&&0<d.morphColors.length)for(p=i.faces,d=d.morphColors[0].colors,n=0,H=p.length;n<H;n++)p[n].color.fromArray(d,3*n);for(d=t,n=[],H=[],d.animation!==void 0&&H.push(d.animation),d.animations!==void 0&&(d.animations.length?H=H.concat(d.animations):H.push(d.animations)),d=0;d<H.length;d++)(p=_r.parseAnimation(H[d],i.bones))&&n.push(p);return i.morphTargets&&(H=_r.CreateClipsFromMorphTargetSequences(i.morphTargets,10),n=n.concat(H)),0<n.length&&(i.animations=n),i.computeFaceNormals(),i.computeBoundingSphere(),t.materials===void 0||t.materials.length===0?{geometry:i}:(t=Do.prototype.initMaterials(t.materials,this.resourcePath||e,this.crossOrigin),{geometry:i,materials:t})}}()}),Object.assign(ul.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){var s=this,l=this.path===void 0?Gs.extractUrlBase(t):this.path;this.resourcePath=this.resourcePath||l,l=new Lt(s.manager),l.setPath(this.path),l.load(t,function(d){var p=null;try{p=JSON.parse(d)}catch(_){n!==void 0&&n(_);return}d=p.metadata,d===void 0||d.type===void 0||d.type.toLowerCase()==="geometry"||s.parse(p,e)},i,n)},setPath:function(t){return this.path=t,this},setResourcePath:function(t){return this.resourcePath=t,this},setCrossOrigin:function(t){return this.crossOrigin=t,this},parse:function(t,e){var i=this.parseShape(t.shapes);i=this.parseGeometries(t.geometries,i);var n=this.parseImages(t.images,function(){e!==void 0&&e(s)});n=this.parseTextures(t.textures,n),n=this.parseMaterials(t.materials,n);var s=this.parseObject(t.object,i,n);return t.animations&&(s.animations=this.parseAnimations(t.animations)),t.images!==void 0&&t.images.length!==0||e===void 0||e(s),s},parseShape:function(t){var e={};if(t!==void 0)for(var i=0,n=t.length;i<n;i++){var s=new Qn().fromJSON(t[i]);e[s.uuid]=s}return e},parseGeometries:function(t,e){var i={};if(t!==void 0)for(var n=new ks,s=new Nh,l=0,d=t.length;l<d;l++){var p=t[l];switch(p.type){case"PlaneGeometry":case"PlaneBufferGeometry":var _=new yn[p.type](p.width,p.height,p.widthSegments,p.heightSegments);break;case"BoxGeometry":case"BoxBufferGeometry":case"CubeGeometry":_=new yn[p.type](p.width,p.height,p.depth,p.widthSegments,p.heightSegments,p.depthSegments);break;case"CircleGeometry":case"CircleBufferGeometry":_=new yn[p.type](p.radius,p.segments,p.thetaStart,p.thetaLength);break;case"CylinderGeometry":case"CylinderBufferGeometry":_=new yn[p.type](p.radiusTop,p.radiusBottom,p.height,p.radialSegments,p.heightSegments,p.openEnded,p.thetaStart,p.thetaLength);break;case"ConeGeometry":case"ConeBufferGeometry":_=new yn[p.type](p.radius,p.height,p.radialSegments,p.heightSegments,p.openEnded,p.thetaStart,p.thetaLength);break;case"SphereGeometry":case"SphereBufferGeometry":_=new yn[p.type](p.radius,p.widthSegments,p.heightSegments,p.phiStart,p.phiLength,p.thetaStart,p.thetaLength);break;case"DodecahedronGeometry":case"DodecahedronBufferGeometry":case"IcosahedronGeometry":case"IcosahedronBufferGeometry":case"OctahedronGeometry":case"OctahedronBufferGeometry":case"TetrahedronGeometry":case"TetrahedronBufferGeometry":_=new yn[p.type](p.radius,p.detail);break;case"RingGeometry":case"RingBufferGeometry":_=new yn[p.type](p.innerRadius,p.outerRadius,p.thetaSegments,p.phiSegments,p.thetaStart,p.thetaLength);break;case"TorusGeometry":case"TorusBufferGeometry":_=new yn[p.type](p.radius,p.tube,p.radialSegments,p.tubularSegments,p.arc);break;case"TorusKnotGeometry":case"TorusKnotBufferGeometry":_=new yn[p.type](p.radius,p.tube,p.tubularSegments,p.radialSegments,p.p,p.q);break;case"LatheGeometry":case"LatheBufferGeometry":_=new yn[p.type](p.points,p.segments,p.phiStart,p.phiLength);break;case"PolyhedronGeometry":case"PolyhedronBufferGeometry":_=new yn[p.type](p.vertices,p.indices,p.radius,p.details);break;case"ShapeGeometry":case"ShapeBufferGeometry":_=[];for(var T=0,A=p.shapes.length;T<A;T++){var L=e[p.shapes[T]];_.push(L)}_=new yn[p.type](_,p.curveSegments);break;case"ExtrudeGeometry":case"ExtrudeBufferGeometry":for(_=[],T=0,A=p.shapes.length;T<A;T++)L=e[p.shapes[T]],_.push(L);T=p.options.extrudePath,T!==void 0&&(p.options.extrudePath=new hh[T.type]().fromJSON(T)),_=new yn[p.type](_,p.options);break;case"BufferGeometry":_=s.parse(p);break;case"Geometry":_=n.parse(p,this.resourcePath).geometry;break;default:continue}_.uuid=p.uuid,p.name!==void 0&&(_.name=p.name),_.isBufferGeometry===!0&&p.userData!==void 0&&(_.userData=p.userData),i[p.uuid]=_}return i},parseMaterials:function(t,e){var i={},n={};if(t!==void 0){var s=new ih;s.setTextures(e),e=0;for(var l=t.length;e<l;e++){var d=t[e];if(d.type==="MultiMaterial"){for(var p=[],_=0;_<d.materials.length;_++){var T=d.materials[_];i[T.uuid]===void 0&&(i[T.uuid]=s.parse(T)),p.push(i[T.uuid])}n[d.uuid]=p}else n[d.uuid]=s.parse(d),i[d.uuid]=n[d.uuid]}}return n},parseAnimations:function(t){for(var e=[],i=0;i<t.length;i++){var n=t[i],s=_r.parse(n);n.uuid!==void 0&&(s.uuid=n.uuid),e.push(s)}return e},parseImages:function(t,e){function i(B){return n.manager.itemStart(B),l.load(B,function(){n.manager.itemEnd(B)},void 0,function(){n.manager.itemError(B),n.manager.itemEnd(B)})}var n=this,s={};if(t!==void 0&&0<t.length){e=new is(e);var l=new ai(e);l.setCrossOrigin(this.crossOrigin),e=0;for(var d=t.length;e<d;e++){var p=t[e],_=p.url;if(Array.isArray(_)){s[p.uuid]=[];for(var T=0,A=_.length;T<A;T++){var L=_[T];L=/^(\/\/)|([a-z]+:(\/\/)?)/i.test(L)?L:n.resourcePath+L,s[p.uuid].push(i(L))}}else L=/^(\/\/)|([a-z]+:(\/\/)?)/i.test(p.url)?p.url:n.resourcePath+p.url,s[p.uuid]=i(L)}}return s},parseTextures:function(t,e){function i(_,T){return typeof _=="number"?_:T[_]}var n={};if(t!==void 0)for(var s=0,l=t.length;s<l;s++){var d=t[s];d.image,e[d.image];var p=Array.isArray(e[d.image])?new z(e[d.image]):new g(e[d.image]);p.needsUpdate=!0,p.uuid=d.uuid,d.name!==void 0&&(p.name=d.name),d.mapping!==void 0&&(p.mapping=i(d.mapping,Uu)),d.offset!==void 0&&p.offset.fromArray(d.offset),d.repeat!==void 0&&p.repeat.fromArray(d.repeat),d.center!==void 0&&p.center.fromArray(d.center),d.rotation!==void 0&&(p.rotation=d.rotation),d.wrap!==void 0&&(p.wrapS=i(d.wrap[0],Zn),p.wrapT=i(d.wrap[1],Zn)),d.format!==void 0&&(p.format=d.format),d.minFilter!==void 0&&(p.minFilter=i(d.minFilter,uh)),d.magFilter!==void 0&&(p.magFilter=i(d.magFilter,uh)),d.anisotropy!==void 0&&(p.anisotropy=d.anisotropy),d.flipY!==void 0&&(p.flipY=d.flipY),n[d.uuid]=p}return n},parseObject:function(t,e,i){function n(T){return e[T],e[T]}function s(T){if(T!==void 0){if(Array.isArray(T)){for(var A=[],L=0,B=T.length;L<B;L++){var H=T[L];i[H],A.push(i[H])}return A}return i[T],i[T]}}switch(t.type){case"Scene":var l=new Xn;t.background!==void 0&&Number.isInteger(t.background)&&(l.background=new P(t.background)),t.fog!==void 0&&(t.fog.type==="Fog"?l.fog=new Sn(t.fog.color,t.fog.near,t.fog.far):t.fog.type==="FogExp2"&&(l.fog=new Re(t.fog.color,t.fog.density)));break;case"PerspectiveCamera":l=new _e(t.fov,t.aspect,t.near,t.far),t.focus!==void 0&&(l.focus=t.focus),t.zoom!==void 0&&(l.zoom=t.zoom),t.filmGauge!==void 0&&(l.filmGauge=t.filmGauge),t.filmOffset!==void 0&&(l.filmOffset=t.filmOffset),t.view!==void 0&&(l.view=Object.assign({},t.view));break;case"OrthographicCamera":l=new Ma(t.left,t.right,t.top,t.bottom,t.near,t.far),t.zoom!==void 0&&(l.zoom=t.zoom),t.view!==void 0&&(l.view=Object.assign({},t.view));break;case"AmbientLight":l=new zs(t.color,t.intensity);break;case"DirectionalLight":l=new xo(t.color,t.intensity);break;case"PointLight":l=new Ds(t.color,t.intensity,t.distance,t.decay);break;case"RectAreaLight":l=new eh(t.color,t.intensity,t.width,t.height);break;case"SpotLight":l=new hl(t.color,t.intensity,t.distance,t.angle,t.penumbra,t.decay);break;case"HemisphereLight":l=new al(t.color,t.groundColor,t.intensity);break;case"SkinnedMesh":case"Mesh":l=n(t.geometry);var d=s(t.material);l=l.bones&&0<l.bones.length?new Gi(l,d):new pi(l,d);break;case"LOD":l=new rn;break;case"Line":l=new ji(n(t.geometry),s(t.material),t.mode);break;case"LineLoop":l=new co(n(t.geometry),s(t.material));break;case"LineSegments":l=new gi(n(t.geometry),s(t.material));break;case"PointCloud":case"Points":l=new ha(n(t.geometry),s(t.material));break;case"Sprite":l=new nn(s(t.material));break;case"Group":l=new ci;break;default:l=new F}if(l.uuid=t.uuid,t.name!==void 0&&(l.name=t.name),t.matrix!==void 0?(l.matrix.fromArray(t.matrix),t.matrixAutoUpdate!==void 0&&(l.matrixAutoUpdate=t.matrixAutoUpdate),l.matrixAutoUpdate&&l.matrix.decompose(l.position,l.quaternion,l.scale)):(t.position!==void 0&&l.position.fromArray(t.position),t.rotation!==void 0&&l.rotation.fromArray(t.rotation),t.quaternion!==void 0&&l.quaternion.fromArray(t.quaternion),t.scale!==void 0&&l.scale.fromArray(t.scale)),t.castShadow!==void 0&&(l.castShadow=t.castShadow),t.receiveShadow!==void 0&&(l.receiveShadow=t.receiveShadow),t.shadow&&(t.shadow.bias!==void 0&&(l.shadow.bias=t.shadow.bias),t.shadow.radius!==void 0&&(l.shadow.radius=t.shadow.radius),t.shadow.mapSize!==void 0&&l.shadow.mapSize.fromArray(t.shadow.mapSize),t.shadow.camera!==void 0&&(l.shadow.camera=this.parseObject(t.shadow.camera))),t.visible!==void 0&&(l.visible=t.visible),t.frustumCulled!==void 0&&(l.frustumCulled=t.frustumCulled),t.renderOrder!==void 0&&(l.renderOrder=t.renderOrder),t.userData!==void 0&&(l.userData=t.userData),t.layers!==void 0&&(l.layers.mask=t.layers),t.children!==void 0){d=t.children;for(var p=0;p<d.length;p++)l.add(this.parseObject(d[p],e,i))}if(t.type==="LOD")for(t=t.levels,d=0;d<t.length;d++){p=t[d];var _=l.getObjectByProperty("uuid",p.object);_!==void 0&&l.addLevel(_,p.distance)}return l}});var Uu={UVMapping:300,CubeReflectionMapping:301,CubeRefractionMapping:302,EquirectangularReflectionMapping:303,EquirectangularRefractionMapping:304,SphericalReflectionMapping:305,CubeUVReflectionMapping:306,CubeUVRefractionMapping:307},Zn={RepeatWrapping:1e3,ClampToEdgeWrapping:1001,MirroredRepeatWrapping:1002},uh={NearestFilter:1003,NearestMipMapNearestFilter:1004,NearestMipMapLinearFilter:1005,LinearFilter:1006,LinearMipMapNearestFilter:1007,LinearMipMapLinearFilter:1008};Fh.prototype={constructor:Fh,setOptions:function(t){return this.options=t,this},load:function(t,e,i,n){t===void 0&&(t=""),this.path!==void 0&&(t=this.path+t),t=this.manager.resolveURL(t);var s=this,l=Mo.get(t);if(l!==void 0)return s.manager.itemStart(t),setTimeout(function(){e&&e(l),s.manager.itemEnd(t)},0),l;fetch(t).then(function(d){return d.blob()}).then(function(d){return createImageBitmap(d,s.options)}).then(function(d){Mo.add(t,d),e&&e(d),s.manager.itemEnd(t)}).catch(function(d){n&&n(d),s.manager.itemError(t),s.manager.itemEnd(t)})},setCrossOrigin:function(){return this},setPath:function(t){return this.path=t,this}},Object.assign(nh.prototype,{moveTo:function(t,e){this.currentPath=new fr,this.subPaths.push(this.currentPath),this.currentPath.moveTo(t,e)},lineTo:function(t,e){this.currentPath.lineTo(t,e)},quadraticCurveTo:function(t,e,i,n){this.currentPath.quadraticCurveTo(t,e,i,n)},bezierCurveTo:function(t,e,i,n,s,l){this.currentPath.bezierCurveTo(t,e,i,n,s,l)},splineThru:function(t){this.currentPath.splineThru(t)},toShapes:function(t,e){function i(rt){for(var xt=[],gt=0,Ct=rt.length;gt<Ct;gt++){var wt=rt[gt],Vt=new Qn;Vt.curves=wt.curves,xt.push(Vt)}return xt}function n(rt,xt){for(var gt=xt.length,Ct=!1,wt=gt-1,Vt=0;Vt<gt;wt=Vt++){var $=xt[wt],ot=xt[Vt],kt=ot.x-$.x,ee=ot.y-$.y;if(Math.abs(ee)>Number.EPSILON){if(0>ee&&($=xt[Vt],kt=-kt,ot=xt[wt],ee=-ee),!(rt.y<$.y||rt.y>ot.y))if(rt.y===$.y){if(rt.x===$.x)return!0}else{if(wt=ee*(rt.x-$.x)-kt*(rt.y-$.y),wt===0)return!0;0>wt||(Ct=!Ct)}}else if(rt.y===$.y&&(ot.x<=rt.x&&rt.x<=$.x||$.x<=rt.x&&rt.x<=ot.x))return!0}return Ct}var s=To.isClockWise,l=this.subPaths;if(l.length===0)return[];if(e===!0)return i(l);if(e=[],l.length===1){var d=l[0],p=new Qn;return p.curves=d.curves,e.push(p),e}var _=!s(l[0].getPoints());_=t?!_:_,p=[];var T=[],A=[],L=0;T[L]=void 0,A[L]=[];for(var B=0,H=l.length;B<H;B++){d=l[B];var q=d.getPoints(),J=s(q);(J=t?!J:J)?(!_&&T[L]&&L++,T[L]={s:new Qn,p:q},T[L].s.curves=d.curves,_&&L++,A[L]=[]):A[L].push({h:d,p:q[0]})}if(!T[0])return i(l);if(1<T.length){for(B=!1,t=[],s=0,l=T.length;s<l;s++)p[s]=[];for(s=0,l=T.length;s<l;s++)for(d=A[s],J=0;J<d.length;J++){for(_=d[J],L=!0,q=0;q<T.length;q++)n(_.p,T[q].p)&&(s!==q&&t.push({froms:s,tos:q,hole:J}),L?(L=!1,p[q].push(_)):B=!0);L&&p[s].push(_)}0<t.length&&(B||(A=p))}for(B=0,s=T.length;B<s;B++)for(p=T[B].s,e.push(p),t=A[B],l=0,d=t.length;l<d;l++)p.holes.push(t[l].h);return e}}),Object.assign(Uh.prototype,{isFont:!0,generateShapes:function(t,e){e===void 0&&(e=100);var i=[],n=e;e=this.data;var s=Array.from?Array.from(t):String(t).split("");n/=e.resolution;var l=(e.boundingBox.yMax-e.boundingBox.yMin+e.underlineThickness)*n;t=[];for(var d=0,p=0,_=0;_<s.length;_++){var T=s[_];if(T===`
|
|
2571
|
-
`)d=0,p-=l;else{var A=n,L=d,B=p;if(T=e.glyphs[T]||e.glyphs["?"]){var H=new nh;if(T.o)for(var q=T._cachedOutline||(T._cachedOutline=T.o.split(" ")),J=0,rt=q.length;J<rt;)switch(q[J++]){case"m":var xt=q[J++]*A+L,gt=q[J++]*A+B;H.moveTo(xt,gt);break;case"l":xt=q[J++]*A+L,gt=q[J++]*A+B,H.lineTo(xt,gt);break;case"q":var Ct=q[J++]*A+L,wt=q[J++]*A+B,Vt=q[J++]*A+L,$=q[J++]*A+B;H.quadraticCurveTo(Vt,$,Ct,wt);break;case"b":Ct=q[J++]*A+L,wt=q[J++]*A+B,Vt=q[J++]*A+L,$=q[J++]*A+B,xt=q[J++]*A+L,gt=q[J++]*A+B,H.bezierCurveTo(Vt,$,xt,gt,Ct,wt)}A={offsetX:T.ha*A,path:H}}else A=void 0;d+=A.offsetX,t.push(A.path)}}for(e=0,s=t.length;e<s;e++)Array.prototype.push.apply(i,t[e].toShapes());return i}}),Object.assign(Lu.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(this.manager);l.setPath(this.path),l.load(t,function(d){try{var p=JSON.parse(d)}catch{p=JSON.parse(d.substring(65,d.length-2))}d=s.parse(p),e&&e(d)},i,n)},parse:function(t){return new Uh(t)},setPath:function(t){return this.path=t,this}});var ch,$h={getContext:function(){return ch===void 0&&(ch=new(window.AudioContext||window.webkitAudioContext)),ch},setContext:function(t){ch=t}};Object.assign(vn.prototype,{load:function(t,e,i,n){var s=new Lt(this.manager);s.setResponseType("arraybuffer"),s.setPath(this.path),s.load(t,function(l){l=l.slice(0),$h.getContext().decodeAudioData(l,function(d){e(d)})},i,n)},setPath:function(t){return this.path=t,this}}),Object.assign(Vn.prototype,{update:function(){var t,e,i,n,s,l,d,p,_=new c,T=new c;return function(A){if(t!==this||e!==A.focus||i!==A.fov||n!==A.aspect*this.aspect||s!==A.near||l!==A.far||d!==A.zoom||p!==this.eyeSep){t=this,e=A.focus,i=A.fov,n=A.aspect*this.aspect,s=A.near,l=A.far,d=A.zoom;var L=A.projectionMatrix.clone();p=this.eyeSep/2;var B=p*s/e,H=s*Math.tan(di.DEG2RAD*i*.5)/d;T.elements[12]=-p,_.elements[12]=p;var q=-H*n+B,J=H*n+B;L.elements[0]=2*s/(J-q),L.elements[8]=(J+q)/(J-q),this.cameraL.projectionMatrix.copy(L),q=-H*n-B,J=H*n-B,L.elements[0]=2*s/(J-q),L.elements[8]=(J+q)/(J-q),this.cameraR.projectionMatrix.copy(L)}this.cameraL.matrixWorld.copy(A.matrixWorld).multiply(T),this.cameraR.matrixWorld.copy(A.matrixWorld).multiply(_)}}()}),cl.prototype=Object.create(F.prototype),cl.prototype.constructor=cl,Object.assign(Gh.prototype,{start:function(){this.oldTime=this.startTime=(typeof performance>"u"?Date:performance).now(),this.elapsedTime=0,this.running=!0},stop:function(){this.getElapsedTime(),this.autoStart=this.running=!1},getElapsedTime:function(){return this.getDelta(),this.elapsedTime},getDelta:function(){var t=0;if(this.autoStart&&!this.running)return this.start(),0;if(this.running){var e=(typeof performance>"u"?Date:performance).now();t=(e-this.oldTime)/1e3,this.oldTime=e,this.elapsedTime+=t}return t}}),rh.prototype=Object.assign(Object.create(F.prototype),{constructor:rh,getInput:function(){return this.gain},removeFilter:function(){return this.filter!==null&&(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination),this.gain.connect(this.context.destination),this.filter=null),this},getFilter:function(){return this.filter},setFilter:function(t){return this.filter!==null?(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination)):this.gain.disconnect(this.context.destination),this.filter=t,this.gain.connect(this.filter),this.filter.connect(this.context.destination),this},getMasterVolume:function(){return this.gain.gain.value},setMasterVolume:function(t){return this.gain.gain.setTargetAtTime(t,this.context.currentTime,.01),this},updateMatrixWorld:function(){var t=new u,e=new f,i=new u,n=new u,s=new Gh;return function(l){F.prototype.updateMatrixWorld.call(this,l),l=this.context.listener;var d=this.up;if(this.timeDelta=s.getDelta(),this.matrixWorld.decompose(t,e,i),n.set(0,0,-1).applyQuaternion(e),l.positionX){var p=this.context.currentTime+this.timeDelta;l.positionX.linearRampToValueAtTime(t.x,p),l.positionY.linearRampToValueAtTime(t.y,p),l.positionZ.linearRampToValueAtTime(t.z,p),l.forwardX.linearRampToValueAtTime(n.x,p),l.forwardY.linearRampToValueAtTime(n.y,p),l.forwardZ.linearRampToValueAtTime(n.z,p),l.upX.linearRampToValueAtTime(d.x,p),l.upY.linearRampToValueAtTime(d.y,p),l.upZ.linearRampToValueAtTime(d.z,p)}else l.setPosition(t.x,t.y,t.z),l.setOrientation(n.x,n.y,n.z,d.x,d.y,d.z)}}()}),Sa.prototype=Object.assign(Object.create(F.prototype),{constructor:Sa,getOutput:function(){return this.gain},setNodeSource:function(t){return this.hasPlaybackControl=!1,this.sourceType="audioNode",this.source=t,this.connect(),this},setMediaElementSource:function(t){return this.hasPlaybackControl=!1,this.sourceType="mediaNode",this.source=this.context.createMediaElementSource(t),this.connect(),this},setBuffer:function(t){return this.buffer=t,this.sourceType="buffer",this.autoplay&&this.play(),this},play:function(){if(this.isPlaying!==!0){if(this.hasPlaybackControl!==!1){var t=this.context.createBufferSource();return t.buffer=this.buffer,t.loop=this.loop,t.onended=this.onEnded.bind(this),t.playbackRate.setValueAtTime(this.playbackRate,this.startTime),this.startTime=this.context.currentTime,t.start(this.startTime,this.offset),this.isPlaying=!0,this.source=t,this.connect()}}},pause:function(){if(this.hasPlaybackControl!==!1)return this.isPlaying===!0&&(this.source.stop(),this.source.onended=null,this.offset+=(this.context.currentTime-this.startTime)*this.playbackRate,this.isPlaying=!1),this},stop:function(){if(this.hasPlaybackControl!==!1)return this.source.stop(),this.source.onended=null,this.offset=0,this.isPlaying=!1,this},connect:function(){if(0<this.filters.length){this.source.connect(this.filters[0]);for(var t=1,e=this.filters.length;t<e;t++)this.filters[t-1].connect(this.filters[t]);this.filters[this.filters.length-1].connect(this.getOutput())}else this.source.connect(this.getOutput());return this},disconnect:function(){if(0<this.filters.length){this.source.disconnect(this.filters[0]);for(var t=1,e=this.filters.length;t<e;t++)this.filters[t-1].disconnect(this.filters[t]);this.filters[this.filters.length-1].disconnect(this.getOutput())}else this.source.disconnect(this.getOutput());return this},getFilters:function(){return this.filters},setFilters:function(t){return t||(t=[]),this.isPlaying===!0?(this.disconnect(),this.filters=t,this.connect()):this.filters=t,this},getFilter:function(){return this.getFilters()[0]},setFilter:function(t){return this.setFilters(t?[t]:[])},setPlaybackRate:function(t){if(this.hasPlaybackControl!==!1)return this.playbackRate=t,this.isPlaying===!0&&this.source.playbackRate.setValueAtTime(this.playbackRate,this.context.currentTime),this},getPlaybackRate:function(){return this.playbackRate},onEnded:function(){this.isPlaying=!1},getLoop:function(){return this.hasPlaybackControl===!1?!1:this.loop},setLoop:function(t){if(this.hasPlaybackControl!==!1)return this.loop=t,this.isPlaying===!0&&(this.source.loop=this.loop),this},getVolume:function(){return this.gain.gain.value},setVolume:function(t){return this.gain.gain.setTargetAtTime(t,this.context.currentTime,.01),this}}),fl.prototype=Object.assign(Object.create(Sa.prototype),{constructor:fl,getOutput:function(){return this.panner},getRefDistance:function(){return this.panner.refDistance},setRefDistance:function(t){return this.panner.refDistance=t,this},getRolloffFactor:function(){return this.panner.rolloffFactor},setRolloffFactor:function(t){return this.panner.rolloffFactor=t,this},getDistanceModel:function(){return this.panner.distanceModel},setDistanceModel:function(t){return this.panner.distanceModel=t,this},getMaxDistance:function(){return this.panner.maxDistance},setMaxDistance:function(t){return this.panner.maxDistance=t,this},setDirectionalCone:function(t,e,i){return this.panner.coneInnerAngle=t,this.panner.coneOuterAngle=e,this.panner.coneOuterGain=i,this},updateMatrixWorld:function(){var t=new u,e=new f,i=new u,n=new u;return function(s){if(F.prototype.updateMatrixWorld.call(this,s),s=this.panner,this.matrixWorld.decompose(t,e,i),n.set(0,0,1).applyQuaternion(e),s.positionX){var l=this.context.currentTime+this.listener.timeDelta;s.positionX.linearRampToValueAtTime(t.x,l),s.positionY.linearRampToValueAtTime(t.y,l),s.positionZ.linearRampToValueAtTime(t.z,l),s.orientationX.linearRampToValueAtTime(n.x,l),s.orientationY.linearRampToValueAtTime(n.y,l),s.orientationZ.linearRampToValueAtTime(n.z,l)}else s.setPosition(t.x,t.y,t.z),s.setOrientation(n.x,n.y,n.z)}}()}),Object.assign(Bs.prototype,{getFrequencyData:function(){return this.analyser.getByteFrequencyData(this.data),this.data},getAverageFrequency:function(){for(var t=0,e=this.getFrequencyData(),i=0;i<e.length;i++)t+=e[i];return t/e.length}}),Object.assign(dl.prototype,{accumulate:function(t,e){var i=this.buffer,n=this.valueSize;t=t*n+n;var s=this.cumulativeWeight;if(s===0){for(s=0;s!==n;++s)i[t+s]=i[s];s=e}else s+=e,this._mixBufferRegion(i,t,0,e/s,n);this.cumulativeWeight=s},apply:function(t){var e=this.valueSize,i=this.buffer;t=t*e+e;var n=this.cumulativeWeight,s=this.binding;this.cumulativeWeight=0,1>n&&this._mixBufferRegion(i,t,3*e,1-n,e),n=e;for(var l=e+e;n!==l;++n)if(i[n]!==i[n+e]){s.setValue(i,t);break}},saveOriginalState:function(){var t=this.buffer,e=this.valueSize,i=3*e;this.binding.getValue(t,i);for(var n=e;n!==i;++n)t[n]=t[i+n%e];this.cumulativeWeight=0},restoreOriginalState:function(){this.binding.setValue(this.buffer,3*this.valueSize)},_select:function(t,e,i,n,s){if(.5<=n)for(n=0;n!==s;++n)t[e+n]=t[i+n]},_slerp:function(t,e,i,n){f.slerpFlat(t,e,t,e,t,i,n)},_lerp:function(t,e,i,n,s){for(var l=1-n,d=0;d!==s;++d){var p=e+d;t[p]=t[p]*l+t[i+d]*n}}}),Object.assign(Ns.prototype,{getValue:function(t,e){this.bind();var i=this._bindings[this._targetGroup.nCachedObjects_];i!==void 0&&i.getValue(t,e)},setValue:function(t,e){for(var i=this._bindings,n=this._targetGroup.nCachedObjects_,s=i.length;n!==s;++n)i[n].setValue(t,e)},bind:function(){for(var t=this._bindings,e=this._targetGroup.nCachedObjects_,i=t.length;e!==i;++e)t[e].bind()},unbind:function(){for(var t=this._bindings,e=this._targetGroup.nCachedObjects_,i=t.length;e!==i;++e)t[e].unbind()}}),Object.assign(En,{Composite:Ns,create:function(t,e,i){return t&&t.isAnimationObjectGroup?new En.Composite(t,e,i):new En(t,e,i)},sanitizeNodeName:function(){var t=/[\[\]\.:\/]/g;return function(e){return e.replace(/\s/g,"_").replace(t,"")}}(),parseTrackName:function(){var t="[^"+"\\[\\]\\.:\\/".replace("\\.","")+"]",e=/((?:WC+[\/:])*)/.source.replace("WC","[^\\[\\]\\.:\\/]");t=/(WCOD+)?/.source.replace("WCOD",t);var i=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC","[^\\[\\]\\.:\\/]"),n=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC","[^\\[\\]\\.:\\/]"),s=new RegExp("^"+e+t+i+n+"$"),l=["material","materials","bones"];return function(d){var p=s.exec(d);if(!p)throw Error("PropertyBinding: Cannot parse trackName: "+d);p={nodeName:p[2],objectName:p[3],objectIndex:p[4],propertyName:p[5],propertyIndex:p[6]};var _=p.nodeName&&p.nodeName.lastIndexOf(".");if(_!==void 0&&_!==-1){var T=p.nodeName.substring(_+1);l.indexOf(T)!==-1&&(p.nodeName=p.nodeName.substring(0,_),p.objectName=T)}if(p.propertyName===null||p.propertyName.length===0)throw Error("PropertyBinding: can not parse propertyName from trackName: "+d);return p}}(),findNode:function(t,e){if(!e||e===""||e==="root"||e==="."||e===-1||e===t.name||e===t.uuid)return t;if(t.skeleton){var i=t.skeleton.getBoneByName(e);if(i!==void 0)return i}if(t.children){var n=function(s){for(var l=0;l<s.length;l++){var d=s[l];if(d.name===e||d.uuid===e||(d=n(d.children)))return d}return null};if(t=n(t.children))return t}return null}}),Object.assign(En.prototype,{_getValue_unavailable:function(){},_setValue_unavailable:function(){},BindingType:{Direct:0,EntireArray:1,ArrayElement:2,HasFromToArray:3},Versioning:{None:0,NeedsUpdate:1,MatrixWorldNeedsUpdate:2},GetterByBindingType:[function(t,e){t[e]=this.node[this.propertyName]},function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)t[e++]=i[n]},function(t,e){t[e]=this.resolvedProperty[this.propertyIndex]},function(t,e){this.resolvedProperty.toArray(t,e)}],SetterByBindingTypeAndVersioning:[[function(t,e){this.targetObject[this.propertyName]=t[e]},function(t,e){this.targetObject[this.propertyName]=t[e],this.targetObject.needsUpdate=!0},function(t,e){this.targetObject[this.propertyName]=t[e],this.targetObject.matrixWorldNeedsUpdate=!0}],[function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)i[n]=t[e++]},function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)i[n]=t[e++];this.targetObject.needsUpdate=!0},function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)i[n]=t[e++];this.targetObject.matrixWorldNeedsUpdate=!0}],[function(t,e){this.resolvedProperty[this.propertyIndex]=t[e]},function(t,e){this.resolvedProperty[this.propertyIndex]=t[e],this.targetObject.needsUpdate=!0},function(t,e){this.resolvedProperty[this.propertyIndex]=t[e],this.targetObject.matrixWorldNeedsUpdate=!0}],[function(t,e){this.resolvedProperty.fromArray(t,e)},function(t,e){this.resolvedProperty.fromArray(t,e),this.targetObject.needsUpdate=!0},function(t,e){this.resolvedProperty.fromArray(t,e),this.targetObject.matrixWorldNeedsUpdate=!0}]],getValue:function(t,e){this.bind(),this.getValue(t,e)},setValue:function(t,e){this.bind(),this.setValue(t,e)},bind:function(){var t=this.node,e=this.parsedPath,i=e.objectName,n=e.propertyName,s=e.propertyIndex;if(t||(this.node=t=En.findNode(this.rootNode,e.nodeName)||this.rootNode),this.getValue=this._getValue_unavailable,this.setValue=this._setValue_unavailable,t){if(i){var l=e.objectIndex;switch(i){case"materials":if(!t.material||!t.material.materials)return;t=t.material.materials;break;case"bones":if(!t.skeleton)return;for(t=t.skeleton.bones,i=0;i<t.length;i++)if(t[i].name===l){l=i;break}break;default:if(t[i]===void 0)return;t=t[i]}if(l!==void 0){if(t[l]===void 0)return;t=t[l]}}if(l=t[n],l!==void 0){if(e=this.Versioning.None,this.targetObject=t,t.needsUpdate!==void 0?e=this.Versioning.NeedsUpdate:t.matrixWorldNeedsUpdate!==void 0&&(e=this.Versioning.MatrixWorldNeedsUpdate),i=this.BindingType.Direct,s!==void 0){if(n==="morphTargetInfluences"){if(!t.geometry)return;if(t.geometry.isBufferGeometry){if(!t.geometry.morphAttributes)return;for(i=0;i<this.node.geometry.morphAttributes.position.length;i++)if(t.geometry.morphAttributes.position[i].name===s){s=i;break}}else{if(!t.geometry.morphTargets)return;for(i=0;i<this.node.geometry.morphTargets.length;i++)if(t.geometry.morphTargets[i].name===s){s=i;break}}}i=this.BindingType.ArrayElement,this.resolvedProperty=l,this.propertyIndex=s}else l.fromArray!==void 0&&l.toArray!==void 0?(i=this.BindingType.HasFromToArray,this.resolvedProperty=l):Array.isArray(l)?(i=this.BindingType.EntireArray,this.resolvedProperty=l):this.propertyName=n;this.getValue=this.GetterByBindingType[i],this.setValue=this.SetterByBindingTypeAndVersioning[i][e]}}},unbind:function(){this.node=null,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}}),Object.assign(En.prototype,{_getValue_unbound:En.prototype.getValue,_setValue_unbound:En.prototype.setValue}),Object.assign(Ea.prototype,{isAnimationObjectGroup:!0,add:function(){for(var t=this._objects,e=t.length,i=this.nCachedObjects_,n=this._indicesByUUID,s=this._paths,l=this._parsedPaths,d=this._bindings,p=d.length,_=void 0,T=0,A=arguments.length;T!==A;++T){var L=arguments[T],B=L.uuid,H=n[B];if(H===void 0){H=e++,n[B]=H,t.push(L),B=0;for(var q=p;B!==q;++B)d[B].push(new En(L,s[B],l[B]))}else if(H<i){_=t[H];var J=--i;for(q=t[J],n[q.uuid]=H,t[H]=q,n[B]=J,t[J]=L,B=0,q=p;B!==q;++B){var rt=d[B],xt=rt[H];rt[H]=rt[J],xt===void 0&&(xt=new En(L,s[B],l[B])),rt[J]=xt}}else t[H]}this.nCachedObjects_=i},remove:function(){for(var t=this._objects,e=this.nCachedObjects_,i=this._indicesByUUID,n=this._bindings,s=n.length,l=0,d=arguments.length;l!==d;++l){var p=arguments[l],_=p.uuid,T=i[_];if(T!==void 0&&T>=e){var A=e++,L=t[A];for(i[L.uuid]=T,t[T]=L,i[_]=A,t[A]=p,p=0,_=s;p!==_;++p){L=n[p];var B=L[T];L[T]=L[A],L[A]=B}}}this.nCachedObjects_=e},uncache:function(){for(var t=this._objects,e=t.length,i=this.nCachedObjects_,n=this._indicesByUUID,s=this._bindings,l=s.length,d=0,p=arguments.length;d!==p;++d){var _=arguments[d].uuid,T=n[_];if(T!==void 0)if(delete n[_],T<i){_=--i;var A=t[_],L=--e,B=t[L];for(n[A.uuid]=T,t[T]=A,n[B.uuid]=_,t[_]=B,t.pop(),A=0,B=l;A!==B;++A){var H=s[A],q=H[L];H[T]=H[_],H[_]=q,H.pop()}}else for(L=--e,B=t[L],n[B.uuid]=T,t[T]=B,t.pop(),A=0,B=l;A!==B;++A)H=s[A],H[T]=H[L],H.pop()}this.nCachedObjects_=i},subscribe_:function(t,e){var i=this._bindingsIndicesByPath,n=i[t],s=this._bindings;if(n!==void 0)return s[n];var l=this._paths,d=this._parsedPaths,p=this._objects,_=this.nCachedObjects_,T=Array(p.length);for(n=s.length,i[t]=n,l.push(t),d.push(e),s.push(T),i=_,n=p.length;i!==n;++i)T[i]=new En(p[i],t,e);return T},unsubscribe_:function(t){var e=this._bindingsIndicesByPath,i=e[t];if(i!==void 0){var n=this._paths,s=this._parsedPaths,l=this._bindings,d=l.length-1,p=l[d];e[t[d]]=i,l[i]=p,l.pop(),s[i]=s[d],s.pop(),n[i]=n[d],n.pop()}}}),Object.assign(pl.prototype,{play:function(){return this._mixer._activateAction(this),this},stop:function(){return this._mixer._deactivateAction(this),this.reset()},reset:function(){return this.paused=!1,this.enabled=!0,this.time=0,this._loopCount=-1,this._startTime=null,this.stopFading().stopWarping()},isRunning:function(){return this.enabled&&!this.paused&&this.timeScale!==0&&this._startTime===null&&this._mixer._isActiveAction(this)},isScheduled:function(){return this._mixer._isActiveAction(this)},startAt:function(t){return this._startTime=t,this},setLoop:function(t,e){return this.loop=t,this.repetitions=e,this},setEffectiveWeight:function(t){return this.weight=t,this._effectiveWeight=this.enabled?t:0,this.stopFading()},getEffectiveWeight:function(){return this._effectiveWeight},fadeIn:function(t){return this._scheduleFading(t,0,1)},fadeOut:function(t){return this._scheduleFading(t,1,0)},crossFadeFrom:function(t,e,i){if(t.fadeOut(e),this.fadeIn(e),i){i=this._clip.duration;var n=t._clip.duration,s=i/n;t.warp(1,n/i,e),this.warp(s,1,e)}return this},crossFadeTo:function(t,e,i){return t.crossFadeFrom(this,e,i)},stopFading:function(){var t=this._weightInterpolant;return t!==null&&(this._weightInterpolant=null,this._mixer._takeBackControlInterpolant(t)),this},setEffectiveTimeScale:function(t){return this.timeScale=t,this._effectiveTimeScale=this.paused?0:t,this.stopWarping()},getEffectiveTimeScale:function(){return this._effectiveTimeScale},setDuration:function(t){return this.timeScale=this._clip.duration/t,this.stopWarping()},syncWith:function(t){return this.time=t.time,this.timeScale=t.timeScale,this.stopWarping()},halt:function(t){return this.warp(this._effectiveTimeScale,0,t)},warp:function(t,e,i){var n=this._mixer,s=n.time,l=this._timeScaleInterpolant,d=this.timeScale;return l===null&&(this._timeScaleInterpolant=l=n._lendControlInterpolant()),n=l.parameterPositions,l=l.sampleValues,n[0]=s,n[1]=s+i,l[0]=t/d,l[1]=e/d,this},stopWarping:function(){var t=this._timeScaleInterpolant;return t!==null&&(this._timeScaleInterpolant=null,this._mixer._takeBackControlInterpolant(t)),this},getMixer:function(){return this._mixer},getClip:function(){return this._clip},getRoot:function(){return this._localRoot||this._mixer._root},_update:function(t,e,i,n){if(this.enabled){var s=this._startTime;if(s!==null){if(e=(t-s)*i,0>e||i===0)return;this._startTime=null,e*=i}if(e*=this._updateTimeScale(t),i=this._updateTime(e),t=this._updateWeight(t),0<t){e=this._interpolants,s=this._propertyBindings;for(var l=0,d=e.length;l!==d;++l)e[l].evaluate(i),s[l].accumulate(n,t)}}else this._updateWeight(t)},_updateWeight:function(t){var e=0;if(this.enabled){e=this.weight;var i=this._weightInterpolant;if(i!==null){var n=i.evaluate(t)[0];e*=n,t>i.parameterPositions[1]&&(this.stopFading(),n===0&&(this.enabled=!1))}}return this._effectiveWeight=e},_updateTimeScale:function(t){var e=0;if(!this.paused){e=this.timeScale;var i=this._timeScaleInterpolant;if(i!==null){var n=i.evaluate(t)[0];e*=n,t>i.parameterPositions[1]&&(this.stopWarping(),e===0?this.paused=!0:this.timeScale=e)}}return this._effectiveTimeScale=e},_updateTime:function(t){var e=this.time+t,i=this._clip.duration,n=this.loop,s=this._loopCount,l=n===2202;if(t===0)return s===-1?e:l&&(s&1)===1?i-e:e;if(n===2200)t:{if(s===-1&&(this._loopCount=0,this._setEndings(!0,!0,!1)),e>=i)e=i;else if(0>e)e=0;else break t;this.clampWhenFinished?this.paused=!0:this.enabled=!1,this._mixer.dispatchEvent({type:"finished",action:this,direction:0>t?-1:1})}else{if(s===-1&&(0<=t?(s=0,this._setEndings(!0,this.repetitions===0,l)):this._setEndings(this.repetitions===0,!0,l)),e>=i||0>e){n=Math.floor(e/i),e-=i*n,s+=Math.abs(n);var d=this.repetitions-s;0>=d?(this.clampWhenFinished?this.paused=!0:this.enabled=!1,e=0<t?i:0,this._mixer.dispatchEvent({type:"finished",action:this,direction:0<t?1:-1})):(d===1?(t=0>t,this._setEndings(t,!t,l)):this._setEndings(!1,!1,l),this._loopCount=s,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:n}))}if(l&&(s&1)===1)return this.time=e,i-e}return this.time=e},_setEndings:function(t,e,i){var n=this._interpolantSettings;i?(n.endingStart=2401,n.endingEnd=2401):(n.endingStart=t?this.zeroSlopeAtStart?2401:2400:2402,n.endingEnd=e?this.zeroSlopeAtEnd?2401:2400:2402)},_scheduleFading:function(t,e,i){var n=this._mixer,s=n.time,l=this._weightInterpolant;return l===null&&(this._weightInterpolant=l=n._lendControlInterpolant()),n=l.parameterPositions,l=l.sampleValues,n[0]=s,l[0]=e,n[1]=s+t,l[1]=i,this}}),os.prototype=Object.assign(Object.create(a.prototype),{constructor:os,_bindAction:function(t,e){var i=t._localRoot||this._root,n=t._clip.tracks,s=n.length,l=t._propertyBindings;t=t._interpolants;var d=i.uuid,p=this._bindingsByRootAndName,_=p[d];for(_===void 0&&(_={},p[d]=_),p=0;p!==s;++p){var T=n[p],A=T.name,L=_[A];if(L===void 0){if(L=l[p],L!==void 0){L._cacheIndex===null&&(++L.referenceCount,this._addInactiveBinding(L,d,A));continue}L=new dl(En.create(i,A,e&&e._propertyBindings[p].binding.parsedPath),T.ValueTypeName,T.getValueSize()),++L.referenceCount,this._addInactiveBinding(L,d,A)}l[p]=L,t[p].resultBuffer=L.buffer}},_activateAction:function(t){if(!this._isActiveAction(t)){if(t._cacheIndex===null){var e=(t._localRoot||this._root).uuid,i=t._clip.uuid,n=this._actionsByClip[i];this._bindAction(t,n&&n.knownActions[0]),this._addInactiveAction(t,i,e)}for(e=t._propertyBindings,i=0,n=e.length;i!==n;++i){var s=e[i];s.useCount++===0&&(this._lendBinding(s),s.saveOriginalState())}this._lendAction(t)}},_deactivateAction:function(t){if(this._isActiveAction(t)){for(var e=t._propertyBindings,i=0,n=e.length;i!==n;++i){var s=e[i];--s.useCount===0&&(s.restoreOriginalState(),this._takeBackBinding(s))}this._takeBackAction(t)}},_initMemoryManager:function(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;var t=this;this.stats={actions:{get total(){return t._actions.length},get inUse(){return t._nActiveActions}},bindings:{get total(){return t._bindings.length},get inUse(){return t._nActiveBindings}},controlInterpolants:{get total(){return t._controlInterpolants.length},get inUse(){return t._nActiveControlInterpolants}}}},_isActiveAction:function(t){return t=t._cacheIndex,t!==null&&t<this._nActiveActions},_addInactiveAction:function(t,e,i){var n=this._actions,s=this._actionsByClip,l=s[e];l===void 0?(l={knownActions:[t],actionByRoot:{}},t._byClipCacheIndex=0,s[e]=l):(e=l.knownActions,t._byClipCacheIndex=e.length,e.push(t)),t._cacheIndex=n.length,n.push(t),l.actionByRoot[i]=t},_removeInactiveAction:function(t){var e=this._actions,i=e[e.length-1],n=t._cacheIndex;i._cacheIndex=n,e[n]=i,e.pop(),t._cacheIndex=null,e=t._clip.uuid,i=this._actionsByClip,n=i[e];var s=n.knownActions,l=s[s.length-1],d=t._byClipCacheIndex;l._byClipCacheIndex=d,s[d]=l,s.pop(),t._byClipCacheIndex=null,delete n.actionByRoot[(t._localRoot||this._root).uuid],s.length===0&&delete i[e],this._removeInactiveBindingsForAction(t)},_removeInactiveBindingsForAction:function(t){t=t._propertyBindings;for(var e=0,i=t.length;e!==i;++e){var n=t[e];--n.referenceCount===0&&this._removeInactiveBinding(n)}},_lendAction:function(t){var e=this._actions,i=t._cacheIndex,n=this._nActiveActions++,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_takeBackAction:function(t){var e=this._actions,i=t._cacheIndex,n=--this._nActiveActions,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_addInactiveBinding:function(t,e,i){var n=this._bindingsByRootAndName,s=n[e],l=this._bindings;s===void 0&&(s={},n[e]=s),s[i]=t,t._cacheIndex=l.length,l.push(t)},_removeInactiveBinding:function(t){var e=this._bindings,i=t.binding,n=i.rootNode.uuid;i=i.path;var s=this._bindingsByRootAndName,l=s[n],d=e[e.length-1];t=t._cacheIndex,d._cacheIndex=t,e[t]=d,e.pop(),delete l[i];t:{for(var p in l)break t;delete s[n]}},_lendBinding:function(t){var e=this._bindings,i=t._cacheIndex,n=this._nActiveBindings++,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_takeBackBinding:function(t){var e=this._bindings,i=t._cacheIndex,n=--this._nActiveBindings,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_lendControlInterpolant:function(){var t=this._controlInterpolants,e=this._nActiveControlInterpolants++,i=t[e];return i===void 0&&(i=new Dr(new Float32Array(2),new Float32Array(2),1,this._controlInterpolantsResultBuffer),i.__cacheIndex=e,t[e]=i),i},_takeBackControlInterpolant:function(t){var e=this._controlInterpolants,i=t.__cacheIndex,n=--this._nActiveControlInterpolants,s=e[n];t.__cacheIndex=n,e[n]=t,s.__cacheIndex=i,e[i]=s},_controlInterpolantsResultBuffer:new Float32Array(1),clipAction:function(t,e){var i=e||this._root,n=i.uuid;i=typeof t=="string"?_r.findByName(i,t):t,t=i!==null?i.uuid:t;var s=this._actionsByClip[t],l=null;if(s!==void 0){if(l=s.actionByRoot[n],l!==void 0)return l;l=s.knownActions[0],i===null&&(i=l._clip)}return i===null?null:(e=new pl(this,i,e),this._bindAction(e,l),this._addInactiveAction(e,t,n),e)},existingAction:function(t,e){var i=e||this._root;return e=i.uuid,i=typeof t=="string"?_r.findByName(i,t):t,t=this._actionsByClip[i?i.uuid:t],t!==void 0&&t.actionByRoot[e]||null},stopAllAction:function(){for(var t=this._actions,e=this._nActiveActions,i=this._bindings,n=this._nActiveBindings,s=this._nActiveBindings=this._nActiveActions=0;s!==e;++s)t[s].reset();for(s=0;s!==n;++s)i[s].useCount=0;return this},update:function(t){t*=this.timeScale;for(var e=this._actions,i=this._nActiveActions,n=this.time+=t,s=Math.sign(t),l=this._accuIndex^=1,d=0;d!==i;++d)e[d]._update(n,t,s,l);for(t=this._bindings,e=this._nActiveBindings,d=0;d!==e;++d)t[d].apply(l);return this},getRoot:function(){return this._root},uncacheClip:function(t){var e=this._actions;t=t.uuid;var i=this._actionsByClip,n=i[t];if(n!==void 0){n=n.knownActions;for(var s=0,l=n.length;s!==l;++s){var d=n[s];this._deactivateAction(d);var p=d._cacheIndex,_=e[e.length-1];d._cacheIndex=null,d._byClipCacheIndex=null,_._cacheIndex=p,e[p]=_,e.pop(),this._removeInactiveBindingsForAction(d)}delete i[t]}},uncacheRoot:function(t){t=t.uuid;var e=this._actionsByClip;for(n in e){var i=e[n].actionByRoot[t];i!==void 0&&(this._deactivateAction(i),this._removeInactiveAction(i))}var n=this._bindingsByRootAndName[t];if(n!==void 0)for(var s in n)t=n[s],t.restoreOriginalState(),this._removeInactiveBinding(t)},uncacheAction:function(t,e){t=this.existingAction(t,e),t!==null&&(this._deactivateAction(t),this._removeInactiveAction(t))}}),oh.prototype.clone=function(){return new oh(this.value.clone===void 0?this.value:this.value.clone())},Hh.prototype=Object.assign(Object.create(Ft.prototype),{constructor:Hh,isInstancedBufferGeometry:!0,copy:function(t){return Ft.prototype.copy.call(this,t),this.maxInstancedCount=t.maxInstancedCount,this},clone:function(){return new this.constructor().copy(this)}}),Vh.prototype=Object.assign(Object.create(ki.prototype),{constructor:Vh,isInstancedInterleavedBuffer:!0,copy:function(t){return ki.prototype.copy.call(this,t),this.meshPerAttribute=t.meshPerAttribute,this}}),Wh.prototype=Object.assign(Object.create(K.prototype),{constructor:Wh,isInstancedBufferAttribute:!0,copy:function(t){return K.prototype.copy.call(this,t),this.meshPerAttribute=t.meshPerAttribute,this}}),Object.assign(Ru.prototype,{linePrecision:1,set:function(t,e){this.ray.set(t,e)},setFromCamera:function(t,e){e&&e.isPerspectiveCamera?(this.ray.origin.setFromMatrixPosition(e.matrixWorld),this.ray.direction.set(t.x,t.y,.5).unproject(e).sub(this.ray.origin).normalize()):e&&e.isOrthographicCamera&&(this.ray.origin.set(t.x,t.y,(e.near+e.far)/(e.near-e.far)).unproject(e),this.ray.direction.set(0,0,-1).transformDirection(e.matrixWorld))},intersectObject:function(t,e,i){return i=i||[],Fs(t,this,i,e),i.sort(ml),i},intersectObjects:function(t,e,i){if(i=i||[],Array.isArray(t)===!1)return i;for(var n=0,s=t.length;n<s;n++)Fs(t[n],this,i,e);return i.sort(ml),i}}),Object.assign(jh.prototype,{set:function(t,e,i){return this.radius=t,this.phi=e,this.theta=i,this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.radius=t.radius,this.phi=t.phi,this.theta=t.theta,this},makeSafe:function(){return this.phi=Math.max(1e-6,Math.min(Math.PI-1e-6,this.phi)),this},setFromVector3:function(t){return this.setFromCartesianCoords(t.x,t.y,t.z)},setFromCartesianCoords:function(t,e,i){return this.radius=Math.sqrt(t*t+e*e+i*i),this.radius===0?this.phi=this.theta=0:(this.theta=Math.atan2(t,i),this.phi=Math.acos(di.clamp(e/this.radius,-1,1))),this}}),Object.assign(it.prototype,{set:function(t,e,i){return this.radius=t,this.theta=e,this.y=i,this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.radius=t.radius,this.theta=t.theta,this.y=t.y,this},setFromVector3:function(t){return this.setFromCartesianCoords(t.x,t.y,t.z)},setFromCartesianCoords:function(t,e,i){return this.radius=Math.sqrt(t*t+i*i),this.theta=Math.atan2(t,i),this.y=e,this}}),Object.assign(ss.prototype,{set:function(t,e){return this.min.copy(t),this.max.copy(e),this},setFromPoints:function(t){this.makeEmpty();for(var e=0,i=t.length;e<i;e++)this.expandByPoint(t[e]);return this},setFromCenterAndSize:function(){var t=new o;return function(e,i){return i=t.copy(i).multiplyScalar(.5),this.min.copy(e).sub(i),this.max.copy(e).add(i),this}}(),clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.min.copy(t.min),this.max.copy(t.max),this},makeEmpty:function(){return this.min.x=this.min.y=1/0,this.max.x=this.max.y=-1/0,this},isEmpty:function(){return this.max.x<this.min.x||this.max.y<this.min.y},getCenter:function(t){return t===void 0&&(t=new o),this.isEmpty()?t.set(0,0):t.addVectors(this.min,this.max).multiplyScalar(.5)},getSize:function(t){return t===void 0&&(t=new o),this.isEmpty()?t.set(0,0):t.subVectors(this.max,this.min)},expandByPoint:function(t){return this.min.min(t),this.max.max(t),this},expandByVector:function(t){return this.min.sub(t),this.max.add(t),this},expandByScalar:function(t){return this.min.addScalar(-t),this.max.addScalar(t),this},containsPoint:function(t){return!(t.x<this.min.x||t.x>this.max.x||t.y<this.min.y||t.y>this.max.y)},containsBox:function(t){return this.min.x<=t.min.x&&t.max.x<=this.max.x&&this.min.y<=t.min.y&&t.max.y<=this.max.y},getParameter:function(t,e){return e===void 0&&(e=new o),e.set((t.x-this.min.x)/(this.max.x-this.min.x),(t.y-this.min.y)/(this.max.y-this.min.y))},intersectsBox:function(t){return!(t.max.x<this.min.x||t.min.x>this.max.x||t.max.y<this.min.y||t.min.y>this.max.y)},clampPoint:function(t,e){return e===void 0&&(e=new o),e.copy(t).clamp(this.min,this.max)},distanceToPoint:function(){var t=new o;return function(e){return t.copy(e).clamp(this.min,this.max).sub(e).length()}}(),intersect:function(t){return this.min.max(t.min),this.max.min(t.max),this},union:function(t){return this.min.min(t.min),this.max.max(t.max),this},translate:function(t){return this.min.add(t),this.max.add(t),this},equals:function(t){return t.min.equals(this.min)&&t.max.equals(this.max)}}),Object.assign(ba.prototype,{set:function(t,e){return this.start.copy(t),this.end.copy(e),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.start.copy(t.start),this.end.copy(t.end),this},getCenter:function(t){return t===void 0&&(t=new u),t.addVectors(this.start,this.end).multiplyScalar(.5)},delta:function(t){return t===void 0&&(t=new u),t.subVectors(this.end,this.start)},distanceSq:function(){return this.start.distanceToSquared(this.end)},distance:function(){return this.start.distanceTo(this.end)},at:function(t,e){return e===void 0&&(e=new u),this.delta(e).multiplyScalar(t).add(this.start)},closestPointToPointParameter:function(){var t=new u,e=new u;return function(i,n){return t.subVectors(i,this.start),e.subVectors(this.end,this.start),i=e.dot(e),i=e.dot(t)/i,n&&(i=di.clamp(i,0,1)),i}}(),closestPointToPoint:function(t,e,i){return t=this.closestPointToPointParameter(t,e),i===void 0&&(i=new u),this.delta(i).multiplyScalar(t).add(this.start)},applyMatrix4:function(t){return this.start.applyMatrix4(t),this.end.applyMatrix4(t),this},equals:function(t){return t.start.equals(this.start)&&t.end.equals(this.end)}}),qn.prototype=Object.create(F.prototype),qn.prototype.constructor=qn,qn.prototype.isImmediateRenderObject=!0,_i.prototype=Object.create(gi.prototype),_i.prototype.constructor=_i,_i.prototype.update=function(){var t=new u,e=new u,i=new m;return function(){var n=["a","b","c"];this.object.updateMatrixWorld(!0),i.getNormalMatrix(this.object.matrixWorld);var s=this.object.matrixWorld,l=this.geometry.attributes.position,d=this.object.geometry;if(d&&d.isGeometry)for(var p=d.vertices,_=d.faces,T=d=0,A=_.length;T<A;T++)for(var L=_[T],B=0,H=L.vertexNormals.length;B<H;B++){var q=L.vertexNormals[B];t.copy(p[L[n[B]]]).applyMatrix4(s),e.copy(q).applyMatrix3(i).normalize().multiplyScalar(this.size).add(t),l.setXYZ(d,t.x,t.y,t.z),d+=1,l.setXYZ(d,e.x,e.y,e.z),d+=1}else if(d&&d.isBufferGeometry)for(n=d.attributes.position,p=d.attributes.normal,B=d=0,H=n.count;B<H;B++)t.set(n.getX(B),n.getY(B),n.getZ(B)).applyMatrix4(s),e.set(p.getX(B),p.getY(B),p.getZ(B)),e.applyMatrix3(i).normalize().multiplyScalar(this.size).add(t),l.setXYZ(d,t.x,t.y,t.z),d+=1,l.setXYZ(d,e.x,e.y,e.z),d+=1;l.needsUpdate=!0}}(),Ca.prototype=Object.create(F.prototype),Ca.prototype.constructor=Ca,Ca.prototype.dispose=function(){this.cone.geometry.dispose(),this.cone.material.dispose()},Ca.prototype.update=function(){var t=new u,e=new u;return function(){this.light.updateMatrixWorld();var i=this.light.distance?this.light.distance:1e3,n=i*Math.tan(this.light.angle);this.cone.scale.set(n,n,i),t.setFromMatrixPosition(this.light.matrixWorld),e.setFromMatrixPosition(this.light.target.matrixWorld),this.cone.lookAt(e.sub(t)),this.color!==void 0?this.cone.material.color.set(this.color):this.cone.material.color.copy(this.light.color)}}(),Aa.prototype=Object.create(gi.prototype),Aa.prototype.constructor=Aa,Aa.prototype.updateMatrixWorld=function(){var t=new u,e=new c,i=new c;return function(n){var s=this.bones,l=this.geometry,d=l.getAttribute("position");i.getInverse(this.root.matrixWorld);for(var p=0,_=0;p<s.length;p++){var T=s[p];T.parent&&T.parent.isBone&&(e.multiplyMatrices(i,T.matrixWorld),t.setFromMatrixPosition(e),d.setXYZ(_,t.x,t.y,t.z),e.multiplyMatrices(i,T.parent.matrixWorld),t.setFromMatrixPosition(e),d.setXYZ(_+1,t.x,t.y,t.z),_+=2)}l.getAttribute("position").needsUpdate=!0,F.prototype.updateMatrixWorld.call(this,n)}}(),kr.prototype=Object.create(pi.prototype),kr.prototype.constructor=kr,kr.prototype.dispose=function(){this.geometry.dispose(),this.material.dispose()},kr.prototype.update=function(){this.color!==void 0?this.material.color.set(this.color):this.material.color.copy(this.light.color)},Pa.prototype=Object.create(F.prototype),Pa.prototype.constructor=Pa,Pa.prototype.dispose=function(){this.children[0].geometry.dispose(),this.children[0].material.dispose()},Pa.prototype.update=function(){var t=.5*this.light.width,e=.5*this.light.height,i=this.line.geometry.attributes.position,n=i.array;n[0]=t,n[1]=-e,n[2]=0,n[3]=t,n[4]=e,n[5]=0,n[6]=-t,n[7]=e,n[8]=0,n[9]=-t,n[10]=-e,n[11]=0,n[12]=t,n[13]=-e,n[14]=0,i.needsUpdate=!0,this.color!==void 0?this.line.material.color.set(this.color):this.line.material.color.copy(this.light.color)},La.prototype=Object.create(F.prototype),La.prototype.constructor=La,La.prototype.dispose=function(){this.children[0].geometry.dispose(),this.children[0].material.dispose()},La.prototype.update=function(){var t=new u,e=new P,i=new P;return function(){var n=this.children[0];if(this.color!==void 0)this.material.color.set(this.color);else{var s=n.geometry.getAttribute("color");e.copy(this.light.color),i.copy(this.light.groundColor);for(var l=0,d=s.count;l<d;l++){var p=l<d/2?e:i;s.setXYZ(l,p.r,p.g,p.b)}s.needsUpdate=!0}n.lookAt(t.setFromMatrixPosition(this.light.matrixWorld).negate())}}(),gl.prototype=Object.create(gi.prototype),gl.prototype.constructor=gl,sh.prototype=Object.create(gi.prototype),sh.prototype.constructor=sh,vl.prototype=Object.create(gi.prototype),vl.prototype.constructor=vl,vl.prototype.update=function(){var t=new u,e=new u,i=new m;return function(){this.object.updateMatrixWorld(!0),i.getNormalMatrix(this.object.matrixWorld);var n=this.object.matrixWorld,s=this.geometry.attributes.position,l=this.object.geometry,d=l.vertices;l=l.faces;for(var p=0,_=0,T=l.length;_<T;_++){var A=l[_],L=A.normal;t.copy(d[A.a]).add(d[A.b]).add(d[A.c]).divideScalar(3).applyMatrix4(n),e.copy(L).applyMatrix3(i).normalize().multiplyScalar(this.size).add(t),s.setXYZ(p,t.x,t.y,t.z),p+=1,s.setXYZ(p,e.x,e.y,e.z),p+=1}s.needsUpdate=!0}}(),dr.prototype=Object.create(F.prototype),dr.prototype.constructor=dr,dr.prototype.dispose=function(){this.lightPlane.geometry.dispose(),this.lightPlane.material.dispose(),this.targetLine.geometry.dispose(),this.targetLine.material.dispose()},dr.prototype.update=function(){var t=new u,e=new u,i=new u;return function(){t.setFromMatrixPosition(this.light.matrixWorld),e.setFromMatrixPosition(this.light.target.matrixWorld),i.subVectors(e,t),this.lightPlane.lookAt(i),this.color!==void 0?(this.lightPlane.material.color.set(this.color),this.targetLine.material.color.set(this.color)):(this.lightPlane.material.color.copy(this.light.color),this.targetLine.material.color.copy(this.light.color)),this.targetLine.lookAt(i),this.targetLine.scale.z=i.length()}}(),yl.prototype=Object.create(gi.prototype),yl.prototype.constructor=yl,yl.prototype.update=function(){function t(l,d,p,_){if(n.set(d,p,_).unproject(s),l=i[l],l!==void 0)for(d=e.getAttribute("position"),p=0,_=l.length;p<_;p++)d.setXYZ(l[p],n.x,n.y,n.z)}var e,i,n=new u,s=new Be;return function(){e=this.geometry,i=this.pointMap,s.projectionMatrix.copy(this.camera.projectionMatrix),t("c",0,0,-1),t("t",0,0,1),t("n1",-1,-1,-1),t("n2",1,-1,-1),t("n3",-1,1,-1),t("n4",1,1,-1),t("f1",-1,-1,1),t("f2",1,-1,1),t("f3",-1,1,1),t("f4",1,1,1),t("u1",.7,1.1,-1),t("u2",-.7,1.1,-1),t("u3",0,2,-1),t("cf1",-1,0,1),t("cf2",1,0,1),t("cf3",0,-1,1),t("cf4",0,1,1),t("cn1",-1,0,-1),t("cn2",1,0,-1),t("cn3",0,-1,-1),t("cn4",0,1,-1),e.getAttribute("position").needsUpdate=!0}}(),zo.prototype=Object.create(gi.prototype),zo.prototype.constructor=zo,zo.prototype.update=function(){var t=new k;return function(e){if(this.object!==void 0&&t.setFromObject(this.object),!t.isEmpty()){e=t.min;var i=t.max,n=this.geometry.attributes.position,s=n.array;s[0]=i.x,s[1]=i.y,s[2]=i.z,s[3]=e.x,s[4]=i.y,s[5]=i.z,s[6]=e.x,s[7]=e.y,s[8]=i.z,s[9]=i.x,s[10]=e.y,s[11]=i.z,s[12]=i.x,s[13]=i.y,s[14]=e.z,s[15]=e.x,s[16]=i.y,s[17]=e.z,s[18]=e.x,s[19]=e.y,s[20]=e.z,s[21]=i.x,s[22]=e.y,s[23]=e.z,n.needsUpdate=!0,this.geometry.computeBoundingSphere()}}}(),zo.prototype.setFromObject=function(t){return this.object=t,this.update(),this},zo.prototype.copy=function(t){return gi.prototype.copy.call(this,t),this.object=t.object,this},zo.prototype.clone=function(){return new this.constructor().copy(this)},_l.prototype=Object.create(gi.prototype),_l.prototype.constructor=_l,_l.prototype.updateMatrixWorld=function(t){var e=this.box;e.isEmpty()||(e.getCenter(this.position),e.getSize(this.scale),this.scale.multiplyScalar(.5),F.prototype.updateMatrixWorld.call(this,t))},xl.prototype=Object.create(ji.prototype),xl.prototype.constructor=xl,xl.prototype.updateMatrixWorld=function(t){var e=-this.plane.constant;1e-8>Math.abs(e)&&(e=1e-8),this.scale.set(.5*this.size,.5*this.size,e),this.children[0].material.side=0>e?1:0,this.lookAt(this.plane.normal),F.prototype.updateMatrixWorld.call(this,t)};var fh,Sl;ko.prototype=Object.create(F.prototype),ko.prototype.constructor=ko,ko.prototype.setDirection=function(){var t=new u,e;return function(i){.99999<i.y?this.quaternion.set(0,0,0,1):-.99999>i.y?this.quaternion.set(1,0,0,0):(t.set(i.z,0,-i.x).normalize(),e=Math.acos(i.y),this.quaternion.setFromAxisAngle(t,e))}}(),ko.prototype.setLength=function(t,e,i){e===void 0&&(e=.2*t),i===void 0&&(i=.2*e),this.line.scale.set(1,Math.max(0,t-e),1),this.line.updateMatrix(),this.cone.scale.set(i,e,i),this.cone.position.y=t,this.cone.updateMatrix()},ko.prototype.setColor=function(t){this.line.material.color.copy(t),this.cone.material.color.copy(t)},ko.prototype.copy=function(t){return F.prototype.copy.call(this,t,!1),this.line.copy(t.line),this.cone.copy(t.cone),this},ko.prototype.clone=function(){return new this.constructor().copy(this)},xr.prototype=Object.create(gi.prototype),xr.prototype.constructor=xr,Ee.create=function(t,e){return t.prototype=Object.create(Ee.prototype),t.prototype.constructor=t,t.prototype.getPoint=e,t},Object.assign(Io.prototype,{createPointsGeometry:function(t){return t=this.getPoints(t),this.createGeometry(t)},createSpacedPointsGeometry:function(t){return t=this.getSpacedPoints(t),this.createGeometry(t)},createGeometry:function(t){for(var e=new X,i=0,n=t.length;i<n;i++){var s=t[i];e.vertices.push(new u(s.x,s.y,s.z||0))}return e}}),Object.assign(fr.prototype,{fromPoints:function(t){this.setFromPoints(t)}}),Iu.prototype=Object.create(On.prototype),Du.prototype=Object.create(On.prototype),Xh.prototype=Object.create(On.prototype),Object.assign(Xh.prototype,{initFromArray:function(){},getControlPointsArray:function(){},reparametrizeByArcLength:function(){}}),gl.prototype.setColors=function(){},Aa.prototype.update=function(){},Object.assign(Do.prototype,{extractUrlBase:function(t){return Gs.extractUrlBase(t)}}),Object.assign(ks.prototype,{setTexturePath:function(t){return this.setResourcePath(t)}}),Object.assign(ul.prototype,{setTexturePath:function(t){return this.setResourcePath(t)}}),Object.assign(ss.prototype,{center:function(t){return this.getCenter(t)},empty:function(){return this.isEmpty()},isIntersectionBox:function(t){return this.intersectsBox(t)},size:function(t){return this.getSize(t)}}),Object.assign(k.prototype,{center:function(t){return this.getCenter(t)},empty:function(){return this.isEmpty()},isIntersectionBox:function(t){return this.intersectsBox(t)},isIntersectionSphere:function(t){return this.intersectsSphere(t)},size:function(t){return this.getSize(t)}}),ba.prototype.center=function(t){return this.getCenter(t)},Object.assign(di,{random16:function(){return Math.random()},nearestPowerOfTwo:function(t){return di.floorPowerOfTwo(t)},nextPowerOfTwo:function(t){return di.ceilPowerOfTwo(t)}}),Object.assign(m.prototype,{flattenToArrayOffset:function(t,e){return this.toArray(t,e)},multiplyVector3:function(t){return t.applyMatrix3(this)},multiplyVector3Array:function(){},applyToBuffer:function(t){return this.applyToBufferAttribute(t)},applyToVector3Array:function(){}}),Object.assign(c.prototype,{extractPosition:function(t){return this.copyPosition(t)},flattenToArrayOffset:function(t,e){return this.toArray(t,e)},getPosition:function(){var t;return function(){return t===void 0&&(t=new u),t.setFromMatrixColumn(this,3)}}(),setRotationFromQuaternion:function(t){return this.makeRotationFromQuaternion(t)},multiplyToArray:function(){},multiplyVector3:function(t){return t.applyMatrix4(this)},multiplyVector4:function(t){return t.applyMatrix4(this)},multiplyVector3Array:function(){},rotateAxis:function(t){t.transformDirection(this)},crossVector:function(t){return t.applyMatrix4(this)},translate:function(){},rotateX:function(){},rotateY:function(){},rotateZ:function(){},rotateByAxis:function(){},applyToBuffer:function(t){return this.applyToBufferAttribute(t)},applyToVector3Array:function(){},makeFrustum:function(t,e,i,n,s,l){return this.makePerspective(t,e,n,i,s,l)}}),N.prototype.isIntersectionLine=function(t){return this.intersectsLine(t)},f.prototype.multiplyVector3=function(t){return t.applyQuaternion(this)},Object.assign(Si.prototype,{isIntersectionBox:function(t){return this.intersectsBox(t)},isIntersectionPlane:function(t){return this.intersectsPlane(t)},isIntersectionSphere:function(t){return this.intersectsSphere(t)}}),Object.assign(Oe.prototype,{area:function(){return this.getArea()},barycoordFromPoint:function(t,e){return this.getBarycoord(t,e)},midpoint:function(t){return this.getMidpoint(t)},normal:function(t){return this.getNormal(t)},plane:function(t){return this.getPlane(t)}}),Object.assign(Oe,{barycoordFromPoint:function(t,e,i,n,s){return Oe.getBarycoord(t,e,i,n,s)},normal:function(t,e,i,n){return Oe.getNormal(t,e,i,n)}}),Object.assign(Qn.prototype,{extractAllPoints:function(t){return this.extractPoints(t)},extrude:function(t){return new Po(this,t)},makeGeometry:function(t){return new Lo(this,t)}}),Object.assign(o.prototype,{fromAttribute:function(t,e,i){return this.fromBufferAttribute(t,e,i)},distanceToManhattan:function(t){return this.manhattanDistanceTo(t)},lengthManhattan:function(){return this.manhattanLength()}}),Object.assign(u.prototype,{setEulerFromRotationMatrix:function(){},setEulerFromQuaternion:function(){},getPositionFromMatrix:function(t){return this.setFromMatrixPosition(t)},getScaleFromMatrix:function(t){return this.setFromMatrixScale(t)},getColumnFromMatrix:function(t,e){return this.setFromMatrixColumn(e,t)},applyProjection:function(t){return this.applyMatrix4(t)},fromAttribute:function(t,e,i){return this.fromBufferAttribute(t,e,i)},distanceToManhattan:function(t){return this.manhattanDistanceTo(t)},lengthManhattan:function(){return this.manhattanLength()}}),Object.assign(v.prototype,{fromAttribute:function(t,e,i){return this.fromBufferAttribute(t,e,i)},lengthManhattan:function(){return this.manhattanLength()}}),Object.assign(X.prototype,{computeTangents:function(){},computeLineDistances:function(){}}),Object.assign(F.prototype,{getChildByName:function(t){return this.getObjectByName(t)},renderDepth:function(){},translate:function(t,e){return this.translateOnAxis(e,t)},getWorldRotation:function(){}}),Object.defineProperties(F.prototype,{eulerOrder:{get:function(){return this.rotation.order},set:function(t){this.rotation.order=t}},useQuaternion:{get:function(){},set:function(){}}}),Object.defineProperties(rn.prototype,{objects:{get:function(){return this.levels}}}),Object.defineProperty(un.prototype,"useVertexTexture",{get:function(){},set:function(){}}),Object.defineProperty(Ee.prototype,"__arcLengthDivisions",{get:function(){return this.arcLengthDivisions},set:function(t){this.arcLengthDivisions=t}}),_e.prototype.setLens=function(t,e){e!==void 0&&(this.filmGauge=e),this.setFocalLength(t)},Object.defineProperties(tn.prototype,{onlyShadow:{set:function(){}},shadowCameraFov:{set:function(t){this.shadow.camera.fov=t}},shadowCameraLeft:{set:function(t){this.shadow.camera.left=t}},shadowCameraRight:{set:function(t){this.shadow.camera.right=t}},shadowCameraTop:{set:function(t){this.shadow.camera.top=t}},shadowCameraBottom:{set:function(t){this.shadow.camera.bottom=t}},shadowCameraNear:{set:function(t){this.shadow.camera.near=t}},shadowCameraFar:{set:function(t){this.shadow.camera.far=t}},shadowCameraVisible:{set:function(){}},shadowBias:{set:function(t){this.shadow.bias=t}},shadowDarkness:{set:function(){}},shadowMapWidth:{set:function(t){this.shadow.mapSize.width=t}},shadowMapHeight:{set:function(t){this.shadow.mapSize.height=t}}}),Object.defineProperties(K.prototype,{length:{get:function(){return this.array.length}},copyIndicesArray:function(){}}),Object.assign(Ft.prototype,{addIndex:function(t){this.setIndex(t)},addDrawCall:function(t,e,i){this.addGroup(t,e)},clearDrawCalls:function(){this.clearGroups()},computeTangents:function(){},computeOffsets:function(){}}),Object.defineProperties(Ft.prototype,{drawcalls:{get:function(){return this.groups}},offsets:{get:function(){return this.groups}}}),Object.assign(po.prototype,{getArrays:function(){},addShapeList:function(){},addShape:function(){}}),Object.defineProperties(oh.prototype,{dynamic:{set:function(){}},onUpdate:{value:function(){return this}}}),Object.defineProperties(Wt.prototype,{wrapAround:{get:function(){},set:function(){}},overdraw:{get:function(){},set:function(){}},wrapRGB:{get:function(){return new P}},shading:{get:function(){},set:function(t){this.flatShading=t===1}}}),Object.defineProperties(Jr.prototype,{metal:{get:function(){return!1},set:function(){}}}),Object.defineProperties($e.prototype,{derivatives:{get:function(){return this.extensions.derivatives},set:function(t){this.extensions.derivatives=t}}}),Object.assign(xe.prototype,{clearTarget:function(t,e,i,n){this.setRenderTarget(t),this.clear(e,i,n)},animate:function(t){this.setAnimationLoop(t)},getCurrentRenderTarget:function(){return this.getRenderTarget()},getMaxAnisotropy:function(){return this.capabilities.getMaxAnisotropy()},getPrecision:function(){return this.capabilities.precision},resetGLState:function(){return this.state.reset()},supportsFloatTextures:function(){return this.extensions.get("OES_texture_float")},supportsHalfFloatTextures:function(){return this.extensions.get("OES_texture_half_float")},supportsStandardDerivatives:function(){return this.extensions.get("OES_standard_derivatives")},supportsCompressedTextureS3TC:function(){return this.extensions.get("WEBGL_compressed_texture_s3tc")},supportsCompressedTexturePVRTC:function(){return this.extensions.get("WEBGL_compressed_texture_pvrtc")},supportsBlendMinMax:function(){return this.extensions.get("EXT_blend_minmax")},supportsVertexTextures:function(){return this.capabilities.vertexTextures},supportsInstancedArrays:function(){return this.extensions.get("ANGLE_instanced_arrays")},enableScissorTest:function(t){this.setScissorTest(t)},initMaterial:function(){},addPrePlugin:function(){},addPostPlugin:function(){},updateShadowMap:function(){},setFaceCulling:function(){}}),Object.defineProperties(xe.prototype,{shadowMapEnabled:{get:function(){return this.shadowMap.enabled},set:function(t){this.shadowMap.enabled=t}},shadowMapType:{get:function(){return this.shadowMap.type},set:function(t){this.shadowMap.type=t}},shadowMapCullFace:{get:function(){},set:function(){}}}),Object.defineProperties(ye.prototype,{cullFace:{get:function(){},set:function(){}},renderReverseSided:{get:function(){},set:function(){}},renderSingleSided:{get:function(){},set:function(){}}}),Object.defineProperties(S.prototype,{wrapS:{get:function(){return this.texture.wrapS},set:function(t){this.texture.wrapS=t}},wrapT:{get:function(){return this.texture.wrapT},set:function(t){this.texture.wrapT=t}},magFilter:{get:function(){return this.texture.magFilter},set:function(t){this.texture.magFilter=t}},minFilter:{get:function(){return this.texture.minFilter},set:function(t){this.texture.minFilter=t}},anisotropy:{get:function(){return this.texture.anisotropy},set:function(t){this.texture.anisotropy=t}},offset:{get:function(){return this.texture.offset},set:function(t){this.texture.offset=t}},repeat:{get:function(){return this.texture.repeat},set:function(t){this.texture.repeat=t}},format:{get:function(){return this.texture.format},set:function(t){this.texture.format=t}},type:{get:function(){return this.texture.type},set:function(t){this.texture.type=t}},generateMipmaps:{get:function(){return this.texture.generateMipmaps},set:function(t){this.texture.generateMipmaps=t}}}),Object.defineProperties(mi.prototype,{standing:{set:function(){}},userHeight:{set:function(){}}}),Sa.prototype.load=function(t){var e=this;return new vn().load(t,function(i){e.setBuffer(i)}),this},Bs.prototype.getData=function(){return this.getFrequencyData()},cl.prototype.updateCubeMap=function(t,e){return this.update(t,e)},as.crossOrigin=void 0,as.loadTexture=function(t,e,i,n){var s=new fn;return s.setCrossOrigin(this.crossOrigin),t=s.load(t,i,void 0,n),e&&(t.mapping=e),t},as.loadTextureCube=function(t,e,i,n){var s=new Fi;return s.setCrossOrigin(this.crossOrigin),t=s.load(t,i,void 0,n),e&&(t.mapping=e),t},as.loadCompressedTexture=function(){},as.loadCompressedTextureCube=function(){},x.WebGLRenderTargetCube=b,x.WebGLRenderTarget=S,x.WebGLRenderer=xe,x.ShaderLib=wo,x.UniformsLib=qe,x.UniformsUtils=Bn,x.ShaderChunk=Ci,x.FogExp2=Re,x.Fog=Sn,x.Scene=Xn,x.Sprite=nn,x.LOD=rn,x.SkinnedMesh=Gi,x.Skeleton=un,x.Bone=cn,x.Mesh=pi,x.LineSegments=gi,x.LineLoop=co,x.Line=ji,x.Points=ha,x.Group=ci,x.VideoTexture=zh,x.DataTexture=O,x.DataTexture3D=Q,x.CompressedTexture=Zo,x.CubeTexture=z,x.CanvasTexture=$a,x.DepthTexture=Ka,x.Texture=g,x.AnimationLoader=Qt,x.CompressedTextureLoader=Zt,x.DataTextureLoader=Ue,x.CubeTextureLoader=Fi,x.TextureLoader=fn,x.ObjectLoader=ul,x.MaterialLoader=ih,x.BufferGeometryLoader=Nh,x.DefaultLoadingManager=tr,x.LoadingManager=is,x.JSONLoader=ks,x.ImageLoader=ai,x.ImageBitmapLoader=Fh,x.FontLoader=Lu,x.FileLoader=Lt,x.Loader=Do,x.LoaderUtils=Gs,x.Cache=Mo,x.AudioLoader=vn,x.SpotLightShadow=ll,x.SpotLight=hl,x.PointLight=Ds,x.RectAreaLight=eh,x.HemisphereLight=al,x.DirectionalLightShadow=rs,x.DirectionalLight=xo,x.AmbientLight=zs,x.LightShadow=_o,x.Light=tn,x.StereoCamera=Vn,x.PerspectiveCamera=_e,x.OrthographicCamera=Ma,x.CubeCamera=cl,x.ArrayCamera=Fe,x.Camera=Be,x.AudioListener=rh,x.PositionalAudio=fl,x.AudioContext=$h,x.AudioAnalyser=Bs,x.Audio=Sa,x.VectorKeyframeTrack=wa,x.StringKeyframeTrack=th,x.QuaternionKeyframeTrack=xa,x.NumberKeyframeTrack=$r,x.ColorKeyframeTrack=Ql,x.BooleanKeyframeTrack=Kl,x.PropertyMixer=dl,x.PropertyBinding=En,x.KeyframeTrack=Hn,x.AnimationUtils=Yn,x.AnimationObjectGroup=Ea,x.AnimationMixer=os,x.AnimationClip=_r,x.Uniform=oh,x.InstancedBufferGeometry=Hh,x.BufferGeometry=Ft,x.Geometry=X,x.InterleavedBufferAttribute=Bi,x.InstancedInterleavedBuffer=Vh,x.InterleavedBuffer=ki,x.InstancedBufferAttribute=Wh,x.Face3=R,x.Object3D=F,x.Raycaster=Ru,x.Layers=U,x.EventDispatcher=a,x.Clock=Gh,x.QuaternionLinearInterpolant=ar,x.LinearInterpolant=Dr,x.DiscreteInterpolant=Is,x.CubicInterpolant=sl,x.Interpolant=$n,x.Triangle=Oe,x.Math=di,x.Spherical=jh,x.Cylindrical=it,x.Plane=N,x.Frustum=E,x.Sphere=I,x.Ray=Si,x.Matrix4=c,x.Matrix3=m,x.Box3=k,x.Box2=ss,x.Line3=ba,x.Euler=C,x.Vector4=v,x.Vector3=u,x.Vector2=o,x.Quaternion=f,x.Color=P,x.ImmediateRenderObject=qn,x.VertexNormalsHelper=_i,x.SpotLightHelper=Ca,x.SkeletonHelper=Aa,x.PointLightHelper=kr,x.RectAreaLightHelper=Pa,x.HemisphereLightHelper=La,x.GridHelper=gl,x.PolarGridHelper=sh,x.FaceNormalsHelper=vl,x.DirectionalLightHelper=dr,x.CameraHelper=yl,x.BoxHelper=zo,x.Box3Helper=_l,x.PlaneHelper=xl,x.ArrowHelper=ko,x.AxesHelper=xr,x.Shape=Qn,x.Path=fr,x.ShapePath=nh,x.Font=Uh,x.CurvePath=Io,x.Curve=Ee,x.ImageUtils=as,x.ShapeUtils=To,x.WebGLUtils=He,x.WireframeGeometry=ua,x.ParametricGeometry=Qa,x.ParametricBufferGeometry=ca,x.TetrahedronGeometry=tl,x.TetrahedronBufferGeometry=fa,x.OctahedronGeometry=el,x.OctahedronBufferGeometry=xs,x.IcosahedronGeometry=il,x.IcosahedronBufferGeometry=da,x.DodecahedronGeometry=pa,x.DodecahedronBufferGeometry=ma,x.PolyhedronGeometry=Xi,x.PolyhedronBufferGeometry=xi,x.TubeGeometry=gn,x.TubeBufferGeometry=Jo,x.TorusKnotGeometry=Zr,x.TorusKnotBufferGeometry=ws,x.TorusGeometry=Ts,x.TorusBufferGeometry=Un,x.TextGeometry=rl,x.TextBufferGeometry=Ss,x.SphereGeometry=$o,x.SphereBufferGeometry=Or,x.RingGeometry=ol,x.RingBufferGeometry=Es,x.PlaneGeometry=Pe,x.PlaneBufferGeometry=pe,x.LatheGeometry=ya,x.LatheBufferGeometry=Ko,x.ShapeGeometry=Lo,x.ShapeBufferGeometry=Qo,x.ExtrudeGeometry=Po,x.ExtrudeBufferGeometry=po,x.EdgesGeometry=ts,x.ConeGeometry=_a,x.ConeBufferGeometry=Gn,x.CylinderGeometry=Ro,x.CylinderBufferGeometry=Oo,x.CircleGeometry=bs,x.CircleBufferGeometry=mo,x.BoxGeometry=It,x.BoxBufferGeometry=Nt,x.ShadowMaterial=es,x.SpriteMaterial=Hi,x.RawShaderMaterial=Cs,x.ShaderMaterial=$e,x.PointsMaterial=Fn,x.MeshPhysicalMaterial=As,x.MeshStandardMaterial=go,x.MeshPhongMaterial=Jr,x.MeshToonMaterial=Ps,x.MeshNormalMaterial=Ls,x.MeshLambertMaterial=Ir,x.MeshDepthMaterial=se,x.MeshDistanceMaterial=te,x.MeshBasicMaterial=Ge,x.MeshMatcapMaterial=Rs,x.LineDashedMaterial=Os,x.LineBasicMaterial=Ni,x.Material=Wt,x.Float64BufferAttribute=At,x.Float32BufferAttribute=Et,x.Uint32BufferAttribute=Pt,x.Int32BufferAttribute=G,x.Uint16BufferAttribute=_t,x.Int16BufferAttribute=tt,x.Uint8ClampedBufferAttribute=Rt,x.Uint8BufferAttribute=ct,x.Int8BufferAttribute=Z,x.BufferAttribute=K,x.ArcCurve=Ta,x.CatmullRomCurve3=On,x.CubicBezierCurve=hr,x.CubicBezierCurve3=Ti,x.EllipseCurve=Kn,x.LineCurve=ur,x.LineCurve3=zr,x.QuadraticBezierCurve=cr,x.QuadraticBezierCurve3=yo,x.SplineCurve=Kr,x.REVISION="98",x.MOUSE={LEFT:0,MIDDLE:1,RIGHT:2},x.CullFaceNone=0,x.CullFaceBack=1,x.CullFaceFront=2,x.CullFaceFrontBack=3,x.FrontFaceDirectionCW=0,x.FrontFaceDirectionCCW=1,x.BasicShadowMap=0,x.PCFShadowMap=1,x.PCFSoftShadowMap=2,x.FrontSide=0,x.BackSide=1,x.DoubleSide=2,x.FlatShading=1,x.SmoothShading=2,x.NoColors=0,x.FaceColors=1,x.VertexColors=2,x.NoBlending=0,x.NormalBlending=1,x.AdditiveBlending=2,x.SubtractiveBlending=3,x.MultiplyBlending=4,x.CustomBlending=5,x.AddEquation=100,x.SubtractEquation=101,x.ReverseSubtractEquation=102,x.MinEquation=103,x.MaxEquation=104,x.ZeroFactor=200,x.OneFactor=201,x.SrcColorFactor=202,x.OneMinusSrcColorFactor=203,x.SrcAlphaFactor=204,x.OneMinusSrcAlphaFactor=205,x.DstAlphaFactor=206,x.OneMinusDstAlphaFactor=207,x.DstColorFactor=208,x.OneMinusDstColorFactor=209,x.SrcAlphaSaturateFactor=210,x.NeverDepth=0,x.AlwaysDepth=1,x.LessDepth=2,x.LessEqualDepth=3,x.EqualDepth=4,x.GreaterEqualDepth=5,x.GreaterDepth=6,x.NotEqualDepth=7,x.MultiplyOperation=0,x.MixOperation=1,x.AddOperation=2,x.NoToneMapping=0,x.LinearToneMapping=1,x.ReinhardToneMapping=2,x.Uncharted2ToneMapping=3,x.CineonToneMapping=4,x.UVMapping=300,x.CubeReflectionMapping=301,x.CubeRefractionMapping=302,x.EquirectangularReflectionMapping=303,x.EquirectangularRefractionMapping=304,x.SphericalReflectionMapping=305,x.CubeUVReflectionMapping=306,x.CubeUVRefractionMapping=307,x.RepeatWrapping=1e3,x.ClampToEdgeWrapping=1001,x.MirroredRepeatWrapping=1002,x.NearestFilter=1003,x.NearestMipMapNearestFilter=1004,x.NearestMipMapLinearFilter=1005,x.LinearFilter=1006,x.LinearMipMapNearestFilter=1007,x.LinearMipMapLinearFilter=1008,x.UnsignedByteType=1009,x.ByteType=1010,x.ShortType=1011,x.UnsignedShortType=1012,x.IntType=1013,x.UnsignedIntType=1014,x.FloatType=1015,x.HalfFloatType=1016,x.UnsignedShort4444Type=1017,x.UnsignedShort5551Type=1018,x.UnsignedShort565Type=1019,x.UnsignedInt248Type=1020,x.AlphaFormat=1021,x.RGBFormat=1022,x.RGBAFormat=1023,x.LuminanceFormat=1024,x.LuminanceAlphaFormat=1025,x.RGBEFormat=1023,x.DepthFormat=1026,x.DepthStencilFormat=1027,x.RedFormat=1028,x.RGB_S3TC_DXT1_Format=33776,x.RGBA_S3TC_DXT1_Format=33777,x.RGBA_S3TC_DXT3_Format=33778,x.RGBA_S3TC_DXT5_Format=33779,x.RGB_PVRTC_4BPPV1_Format=35840,x.RGB_PVRTC_2BPPV1_Format=35841,x.RGBA_PVRTC_4BPPV1_Format=35842,x.RGBA_PVRTC_2BPPV1_Format=35843,x.RGB_ETC1_Format=36196,x.RGBA_ASTC_4x4_Format=37808,x.RGBA_ASTC_5x4_Format=37809,x.RGBA_ASTC_5x5_Format=37810,x.RGBA_ASTC_6x5_Format=37811,x.RGBA_ASTC_6x6_Format=37812,x.RGBA_ASTC_8x5_Format=37813,x.RGBA_ASTC_8x6_Format=37814,x.RGBA_ASTC_8x8_Format=37815,x.RGBA_ASTC_10x5_Format=37816,x.RGBA_ASTC_10x6_Format=37817,x.RGBA_ASTC_10x8_Format=37818,x.RGBA_ASTC_10x10_Format=37819,x.RGBA_ASTC_12x10_Format=37820,x.RGBA_ASTC_12x12_Format=37821,x.LoopOnce=2200,x.LoopRepeat=2201,x.LoopPingPong=2202,x.InterpolateDiscrete=2300,x.InterpolateLinear=2301,x.InterpolateSmooth=2302,x.ZeroCurvatureEnding=2400,x.ZeroSlopeEnding=2401,x.WrapAroundEnding=2402,x.TrianglesDrawMode=0,x.TriangleStripDrawMode=1,x.TriangleFanDrawMode=2,x.LinearEncoding=3e3,x.sRGBEncoding=3001,x.GammaEncoding=3007,x.RGBEEncoding=3002,x.LogLuvEncoding=3003,x.RGBM7Encoding=3004,x.RGBM16Encoding=3005,x.RGBDEncoding=3006,x.BasicDepthPacking=3200,x.RGBADepthPacking=3201,x.TangentSpaceNormalMap=0,x.ObjectSpaceNormalMap=1,x.CubeGeometry=It,x.Face4=function(t,e,i,n,s,l,d){return new R(t,e,i,s,l,d)},x.LineStrip=0,x.LinePieces=1,x.MeshFaceMaterial=function(t){return t},x.MultiMaterial=function(t){return t===void 0&&(t=[]),t.isMultiMaterial=!0,t.materials=t,t.clone=function(){return t.slice()},t},x.PointCloud=function(t,e){return new ha(t,e)},x.Particle=function(t){return new nn(t)},x.ParticleSystem=function(t,e){return new ha(t,e)},x.PointCloudMaterial=function(t){return new Fn(t)},x.ParticleBasicMaterial=function(t){return new Fn(t)},x.ParticleSystemMaterial=function(t){return new Fn(t)},x.Vertex=function(t,e,i){return new u(t,e,i)},x.DynamicBufferAttribute=function(t,e){return new K(t,e).setDynamic(!0)},x.Int8Attribute=function(t,e){return new Z(t,e)},x.Uint8Attribute=function(t,e){return new ct(t,e)},x.Uint8ClampedAttribute=function(t,e){return new Rt(t,e)},x.Int16Attribute=function(t,e){return new tt(t,e)},x.Uint16Attribute=function(t,e){return new _t(t,e)},x.Int32Attribute=function(t,e){return new G(t,e)},x.Uint32Attribute=function(t,e){return new Pt(t,e)},x.Float32Attribute=function(t,e){return new Et(t,e)},x.Float64Attribute=function(t,e){return new At(t,e)},x.ClosedSplineCurve3=Iu,x.SplineCurve3=Du,x.Spline=Xh,x.AxisHelper=function(t){return new xr(t)},x.BoundingBoxHelper=function(t,e){return new zo(t,e)},x.EdgesHelper=function(t,e){return new gi(new ts(t.geometry),new Ni({color:e!==void 0?e:16777215}))},x.WireframeHelper=function(t,e){return new gi(new ua(t.geometry),new Ni({color:e!==void 0?e:16777215}))},x.XHRLoader=function(t){return new Lt(t)},x.BinaryTextureLoader=function(t){return new Ue(t)},x.GeometryUtils={merge:function(t,e,i){if(e.isMesh){e.matrixAutoUpdate&&e.updateMatrix();var n=e.matrix;e=e.geometry}t.merge(e,n,i)},center:function(t){return t.center()}},x.Projector=function(){this.projectVector=function(t,e){t.project(e)},this.unprojectVector=function(t,e){t.unproject(e)},this.pickingRay=function(){}},x.CanvasRenderer=function(){},x.SceneUtils={createMultiMaterialObject:function(){},detach:function(){},attach:function(){}},x.LensFlare=function(){},Object.defineProperty(x,"__esModule",{value:!0})}),THREE.Sky=function(){var x=THREE.Sky.SkyShader,a=new THREE.ShaderMaterial({fragmentShader:x.fragmentShader,vertexShader:x.vertexShader,uniforms:THREE.UniformsUtils.clone(x.uniforms),side:THREE.BackSide});THREE.Mesh.call(this,new THREE.BoxBufferGeometry(1,1,1),a)},THREE.Sky.prototype=Object.create(THREE.Mesh.prototype),THREE.Sky.SkyShader={uniforms:{luminance:{value:1},turbidity:{value:2},rayleigh:{value:1},mieCoefficient:{value:.005},mieDirectionalG:{value:.8},sunPosition:{value:new THREE.Vector3}},vertexShader:["uniform vec3 sunPosition;","uniform float rayleigh;","uniform float turbidity;","uniform float mieCoefficient;","varying vec3 vWorldPosition;","varying vec3 vSunDirection;","varying float vSunfade;","varying vec3 vBetaR;","varying vec3 vBetaM;","varying float vSunE;","const vec3 up = vec3( 0.0, 1.0, 0.0 );","const float e = 2.71828182845904523536028747135266249775724709369995957;","const float pi = 3.141592653589793238462643383279502884197169;","const vec3 lambda = vec3( 680E-9, 550E-9, 450E-9 );","const vec3 totalRayleigh = vec3( 5.804542996261093E-6, 1.3562911419845635E-5, 3.0265902468824876E-5 );","const float v = 4.0;","const vec3 K = vec3( 0.686, 0.678, 0.666 );","const vec3 MieConst = vec3( 1.8399918514433978E14, 2.7798023919660528E14, 4.0790479543861094E14 );","const float cutoffAngle = 1.6110731556870734;","const float steepness = 1.5;","const float EE = 1000.0;","float sunIntensity( float zenithAngleCos ) {"," zenithAngleCos = clamp( zenithAngleCos, -1.0, 1.0 );"," return EE * max( 0.0, 1.0 - pow( e, -( ( cutoffAngle - acos( zenithAngleCos ) ) / steepness ) ) );","}","vec3 totalMie( float T ) {"," float c = ( 0.2 * T ) * 10E-18;"," return 0.434 * c * MieConst;","}","void main() {"," vec4 worldPosition = modelMatrix * vec4( position, 1.0 );"," vWorldPosition = worldPosition.xyz;"," gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );"," gl_Position.z = gl_Position.w;"," vSunDirection = normalize( sunPosition );"," vSunE = sunIntensity( dot( vSunDirection, up ) );"," vSunfade = 1.0 - clamp( 1.0 - exp( ( sunPosition.y / 450000.0 ) ), 0.0, 1.0 );"," float rayleighCoefficient = rayleigh - ( 1.0 * ( 1.0 - vSunfade ) );"," vBetaR = totalRayleigh * rayleighCoefficient;"," vBetaM = totalMie( turbidity ) * mieCoefficient;","}"].join(`
|
|
2570
|
+
`},Bn={merge:function(t){for(var e={},i=0;i<t.length;i++){var n=this.clone(t[i]),s;for(s in n)e[s]=n[s]}return e},clone:function(t){var e={},i;for(i in t){e[i]={};for(var n in t[i]){var s=t[i][n];s&&(s.isColor||s.isMatrix3||s.isMatrix4||s.isVector2||s.isVector3||s.isVector4||s.isTexture)?e[i][n]=s.clone():Array.isArray(s)?e[i][n]=s.slice():e[i][n]=s}}return e}},Qr={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Object.assign(P.prototype,{isColor:!0,r:1,g:1,b:1,set:function(t){return t&&t.isColor?this.copy(t):typeof t=="number"?this.setHex(t):typeof t=="string"&&this.setStyle(t),this},setScalar:function(t){return this.b=this.g=this.r=t,this},setHex:function(t){return t=Math.floor(t),this.r=(t>>16&255)/255,this.g=(t>>8&255)/255,this.b=(t&255)/255,this},setRGB:function(t,e,i){return this.r=t,this.g=e,this.b=i,this},setHSL:function(){function t(e,i,n){return 0>n&&(n+=1),1<n&&--n,n<1/6?e+6*(i-e)*n:.5>n?i:n<2/3?e+6*(i-e)*(2/3-n):e}return function(e,i,n){return e=di.euclideanModulo(e,1),i=di.clamp(i,0,1),n=di.clamp(n,0,1),i===0?this.r=this.g=this.b=n:(i=.5>=n?n*(1+i):n+i-n*i,n=2*n-i,this.r=t(n,i,e+1/3),this.g=t(n,i,e),this.b=t(n,i,e-1/3)),this}}(),setStyle:function(t){function e(d){d!==void 0&&1>parseFloat(d)}var i;if(i=/^((?:rgb|hsl)a?)\(\s*([^\)]*)\)/.exec(t)){var n=i[2];switch(i[1]){case"rgb":case"rgba":if(i=/^(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(n))return this.r=Math.min(255,parseInt(i[1],10))/255,this.g=Math.min(255,parseInt(i[2],10))/255,this.b=Math.min(255,parseInt(i[3],10))/255,e(i[5]),this;if(i=/^(\d+)%\s*,\s*(\d+)%\s*,\s*(\d+)%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(n))return this.r=Math.min(100,parseInt(i[1],10))/100,this.g=Math.min(100,parseInt(i[2],10))/100,this.b=Math.min(100,parseInt(i[3],10))/100,e(i[5]),this;break;case"hsl":case"hsla":if(i=/^([0-9]*\.?[0-9]+)\s*,\s*(\d+)%\s*,\s*(\d+)%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(n)){n=parseFloat(i[1])/360;var s=parseInt(i[2],10)/100,l=parseInt(i[3],10)/100;return e(i[5]),this.setHSL(n,s,l)}}}else if(i=/^#([A-Fa-f0-9]+)$/.exec(t)){if(i=i[1],n=i.length,n===3)return this.r=parseInt(i.charAt(0)+i.charAt(0),16)/255,this.g=parseInt(i.charAt(1)+i.charAt(1),16)/255,this.b=parseInt(i.charAt(2)+i.charAt(2),16)/255,this;if(n===6)return this.r=parseInt(i.charAt(0)+i.charAt(1),16)/255,this.g=parseInt(i.charAt(2)+i.charAt(3),16)/255,this.b=parseInt(i.charAt(4)+i.charAt(5),16)/255,this}return t&&0<t.length&&(i=Qr[t],i!==void 0&&this.setHex(i)),this},clone:function(){return new this.constructor(this.r,this.g,this.b)},copy:function(t){return this.r=t.r,this.g=t.g,this.b=t.b,this},copyGammaToLinear:function(t,e){return e===void 0&&(e=2),this.r=Math.pow(t.r,e),this.g=Math.pow(t.g,e),this.b=Math.pow(t.b,e),this},copyLinearToGamma:function(t,e){return e===void 0&&(e=2),e=0<e?1/e:1,this.r=Math.pow(t.r,e),this.g=Math.pow(t.g,e),this.b=Math.pow(t.b,e),this},convertGammaToLinear:function(t){return this.copyGammaToLinear(this,t),this},convertLinearToGamma:function(t){return this.copyLinearToGamma(this,t),this},copySRGBToLinear:function(){function t(e){return .04045>e?.0773993808*e:Math.pow(.9478672986*e+.0521327014,2.4)}return function(e){return this.r=t(e.r),this.g=t(e.g),this.b=t(e.b),this}}(),copyLinearToSRGB:function(){function t(e){return .0031308>e?12.92*e:1.055*Math.pow(e,.41666)-.055}return function(e){return this.r=t(e.r),this.g=t(e.g),this.b=t(e.b),this}}(),convertSRGBToLinear:function(){return this.copySRGBToLinear(this),this},convertLinearToSRGB:function(){return this.copyLinearToSRGB(this),this},getHex:function(){return 255*this.r<<16^255*this.g<<8^255*this.b<<0},getHexString:function(){return("000000"+this.getHex().toString(16)).slice(-6)},getHSL:function(t){t===void 0&&(t={h:0,s:0,l:0});var e=this.r,i=this.g,n=this.b,s=Math.max(e,i,n),l=Math.min(e,i,n),d,p=(l+s)/2;if(l===s)l=d=0;else{var _=s-l;switch(l=.5>=p?_/(s+l):_/(2-s-l),s){case e:d=(i-n)/_+(i<n?6:0);break;case i:d=(n-e)/_+2;break;case n:d=(e-i)/_+4}d/=6}return t.h=d,t.s=l,t.l=p,t},getStyle:function(){return"rgb("+(255*this.r|0)+","+(255*this.g|0)+","+(255*this.b|0)+")"},offsetHSL:function(){var t={};return function(e,i,n){return this.getHSL(t),t.h+=e,t.s+=i,t.l+=n,this.setHSL(t.h,t.s,t.l),this}}(),add:function(t){return this.r+=t.r,this.g+=t.g,this.b+=t.b,this},addColors:function(t,e){return this.r=t.r+e.r,this.g=t.g+e.g,this.b=t.b+e.b,this},addScalar:function(t){return this.r+=t,this.g+=t,this.b+=t,this},sub:function(t){return this.r=Math.max(0,this.r-t.r),this.g=Math.max(0,this.g-t.g),this.b=Math.max(0,this.b-t.b),this},multiply:function(t){return this.r*=t.r,this.g*=t.g,this.b*=t.b,this},multiplyScalar:function(t){return this.r*=t,this.g*=t,this.b*=t,this},lerp:function(t,e){return this.r+=(t.r-this.r)*e,this.g+=(t.g-this.g)*e,this.b+=(t.b-this.b)*e,this},lerpHSL:function(){var t={h:0,s:0,l:0},e={h:0,s:0,l:0};return function(i,n){this.getHSL(t),i.getHSL(e),i=di.lerp(t.h,e.h,n);var s=di.lerp(t.s,e.s,n);return n=di.lerp(t.l,e.l,n),this.setHSL(i,s,n),this}}(),equals:function(t){return t.r===this.r&&t.g===this.g&&t.b===this.b},fromArray:function(t,e){return e===void 0&&(e=0),this.r=t[e],this.g=t[e+1],this.b=t[e+2],this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this.r,t[e+1]=this.g,t[e+2]=this.b,t},toJSON:function(){return this.getHex()}});var qe={common:{diffuse:{value:new P(15658734)},opacity:{value:1},map:{value:null},uvTransform:{value:new m},alphaMap:{value:null}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new o(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new P(16777215)}},lights:{ambientLightColor:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}}},points:{diffuse:{value:new P(15658734)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},uvTransform:{value:new m}},sprite:{diffuse:{value:new P(15658734)},opacity:{value:1},center:{value:new o(.5,.5)},rotation:{value:0},map:{value:null},uvTransform:{value:new m}}},wo={basic:{uniforms:Bn.merge([qe.common,qe.specularmap,qe.envmap,qe.aomap,qe.lightmap,qe.fog]),vertexShader:Ci.meshbasic_vert,fragmentShader:Ci.meshbasic_frag},lambert:{uniforms:Bn.merge([qe.common,qe.specularmap,qe.envmap,qe.aomap,qe.lightmap,qe.emissivemap,qe.fog,qe.lights,{emissive:{value:new P(0)}}]),vertexShader:Ci.meshlambert_vert,fragmentShader:Ci.meshlambert_frag},phong:{uniforms:Bn.merge([qe.common,qe.specularmap,qe.envmap,qe.aomap,qe.lightmap,qe.emissivemap,qe.bumpmap,qe.normalmap,qe.displacementmap,qe.gradientmap,qe.fog,qe.lights,{emissive:{value:new P(0)},specular:{value:new P(1118481)},shininess:{value:30}}]),vertexShader:Ci.meshphong_vert,fragmentShader:Ci.meshphong_frag},standard:{uniforms:Bn.merge([qe.common,qe.envmap,qe.aomap,qe.lightmap,qe.emissivemap,qe.bumpmap,qe.normalmap,qe.displacementmap,qe.roughnessmap,qe.metalnessmap,qe.fog,qe.lights,{emissive:{value:new P(0)},roughness:{value:.5},metalness:{value:.5},envMapIntensity:{value:1}}]),vertexShader:Ci.meshphysical_vert,fragmentShader:Ci.meshphysical_frag},matcap:{uniforms:Bn.merge([qe.common,qe.bumpmap,qe.normalmap,qe.displacementmap,qe.fog,{matcap:{value:null}}]),vertexShader:Ci.meshmatcap_vert,fragmentShader:Ci.meshmatcap_frag},points:{uniforms:Bn.merge([qe.points,qe.fog]),vertexShader:Ci.points_vert,fragmentShader:Ci.points_frag},dashed:{uniforms:Bn.merge([qe.common,qe.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:Ci.linedashed_vert,fragmentShader:Ci.linedashed_frag},depth:{uniforms:Bn.merge([qe.common,qe.displacementmap]),vertexShader:Ci.depth_vert,fragmentShader:Ci.depth_frag},normal:{uniforms:Bn.merge([qe.common,qe.bumpmap,qe.normalmap,qe.displacementmap,{opacity:{value:1}}]),vertexShader:Ci.normal_vert,fragmentShader:Ci.normal_frag},sprite:{uniforms:Bn.merge([qe.sprite,qe.fog]),vertexShader:Ci.sprite_vert,fragmentShader:Ci.sprite_frag},background:{uniforms:{uvTransform:{value:new m},t2D:{value:null}},vertexShader:Ci.background_vert,fragmentShader:Ci.background_frag},cube:{uniforms:{tCube:{value:null},tFlip:{value:-1},opacity:{value:1}},vertexShader:Ci.cube_vert,fragmentShader:Ci.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:Ci.equirect_vert,fragmentShader:Ci.equirect_frag},distanceRGBA:{uniforms:Bn.merge([qe.common,qe.displacementmap,{referencePosition:{value:new u},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:Ci.distanceRGBA_vert,fragmentShader:Ci.distanceRGBA_frag},shadow:{uniforms:Bn.merge([qe.lights,qe.fog,{color:{value:new P(0)},opacity:{value:1}}]),vertexShader:Ci.shadow_vert,fragmentShader:Ci.shadow_frag}};wo.physical={uniforms:Bn.merge([wo.standard.uniforms,{clearCoat:{value:0},clearCoatRoughness:{value:0}}]),vertexShader:Ci.meshphysical_vert,fragmentShader:Ci.meshphysical_frag},Object.assign(R.prototype,{clone:function(){return new this.constructor().copy(this)},copy:function(t){this.a=t.a,this.b=t.b,this.c=t.c,this.normal.copy(t.normal),this.color.copy(t.color),this.materialIndex=t.materialIndex;for(var e=0,i=t.vertexNormals.length;e<i;e++)this.vertexNormals[e]=t.vertexNormals[e].clone();for(e=0,i=t.vertexColors.length;e<i;e++)this.vertexColors[e]=t.vertexColors[e].clone();return this}}),C.RotationOrders="XYZ YZX ZXY XZY YXZ ZYX".split(" "),C.DefaultOrder="XYZ",Object.defineProperties(C.prototype,{x:{get:function(){return this._x},set:function(t){this._x=t,this.onChangeCallback()}},y:{get:function(){return this._y},set:function(t){this._y=t,this.onChangeCallback()}},z:{get:function(){return this._z},set:function(t){this._z=t,this.onChangeCallback()}},order:{get:function(){return this._order},set:function(t){this._order=t,this.onChangeCallback()}}}),Object.assign(C.prototype,{isEuler:!0,set:function(t,e,i,n){return this._x=t,this._y=e,this._z=i,this._order=n||this._order,this.onChangeCallback(),this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._order)},copy:function(t){return this._x=t._x,this._y=t._y,this._z=t._z,this._order=t._order,this.onChangeCallback(),this},setFromRotationMatrix:function(t,e,i){var n=di.clamp,s=t.elements;t=s[0];var l=s[4],d=s[8],p=s[1],_=s[5],T=s[9],A=s[2],L=s[6];return s=s[10],e=e||this._order,e==="XYZ"?(this._y=Math.asin(n(d,-1,1)),.99999>Math.abs(d)?(this._x=Math.atan2(-T,s),this._z=Math.atan2(-l,t)):(this._x=Math.atan2(L,_),this._z=0)):e==="YXZ"?(this._x=Math.asin(-n(T,-1,1)),.99999>Math.abs(T)?(this._y=Math.atan2(d,s),this._z=Math.atan2(p,_)):(this._y=Math.atan2(-A,t),this._z=0)):e==="ZXY"?(this._x=Math.asin(n(L,-1,1)),.99999>Math.abs(L)?(this._y=Math.atan2(-A,s),this._z=Math.atan2(-l,_)):(this._y=0,this._z=Math.atan2(p,t))):e==="ZYX"?(this._y=Math.asin(-n(A,-1,1)),.99999>Math.abs(A)?(this._x=Math.atan2(L,s),this._z=Math.atan2(p,t)):(this._x=0,this._z=Math.atan2(-l,_))):e==="YZX"?(this._z=Math.asin(n(p,-1,1)),.99999>Math.abs(p)?(this._x=Math.atan2(-T,_),this._y=Math.atan2(-A,t)):(this._x=0,this._y=Math.atan2(d,s))):e==="XZY"&&(this._z=Math.asin(-n(l,-1,1)),.99999>Math.abs(l)?(this._x=Math.atan2(L,_),this._y=Math.atan2(d,t)):(this._x=Math.atan2(-T,s),this._y=0)),this._order=e,i!==!1&&this.onChangeCallback(),this},setFromQuaternion:function(){var t=new c;return function(e,i,n){return t.makeRotationFromQuaternion(e),this.setFromRotationMatrix(t,i,n)}}(),setFromVector3:function(t,e){return this.set(t.x,t.y,t.z,e||this._order)},reorder:function(){var t=new f;return function(e){return t.setFromEuler(this),this.setFromQuaternion(t,e)}}(),equals:function(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._order===this._order},fromArray:function(t){return this._x=t[0],this._y=t[1],this._z=t[2],t[3]!==void 0&&(this._order=t[3]),this.onChangeCallback(),this},toArray:function(t,e){return t===void 0&&(t=[]),e===void 0&&(e=0),t[e]=this._x,t[e+1]=this._y,t[e+2]=this._z,t[e+3]=this._order,t},toVector3:function(t){return t?t.set(this._x,this._y,this._z):new u(this._x,this._y,this._z)},onChange:function(t){return this.onChangeCallback=t,this},onChangeCallback:function(){}}),Object.assign(U.prototype,{set:function(t){this.mask=1<<t|0},enable:function(t){this.mask=this.mask|1<<t|0},toggle:function(t){this.mask^=1<<t|0},disable:function(t){this.mask&=~(1<<t|0)},test:function(t){return(this.mask&t.mask)!==0}});var qc=0;N.DefaultUp=new u(0,1,0),N.DefaultMatrixAutoUpdate=!0,N.prototype=Object.assign(Object.create(a.prototype),{constructor:N,isObject3D:!0,onBeforeRender:function(){},onAfterRender:function(){},applyMatrix:function(t){this.matrix.multiplyMatrices(t,this.matrix),this.matrix.decompose(this.position,this.quaternion,this.scale)},applyQuaternion:function(t){return this.quaternion.premultiply(t),this},setRotationFromAxisAngle:function(t,e){this.quaternion.setFromAxisAngle(t,e)},setRotationFromEuler:function(t){this.quaternion.setFromEuler(t,!0)},setRotationFromMatrix:function(t){this.quaternion.setFromRotationMatrix(t)},setRotationFromQuaternion:function(t){this.quaternion.copy(t)},rotateOnAxis:function(){var t=new f;return function(e,i){return t.setFromAxisAngle(e,i),this.quaternion.multiply(t),this}}(),rotateOnWorldAxis:function(){var t=new f;return function(e,i){return t.setFromAxisAngle(e,i),this.quaternion.premultiply(t),this}}(),rotateX:function(){var t=new u(1,0,0);return function(e){return this.rotateOnAxis(t,e)}}(),rotateY:function(){var t=new u(0,1,0);return function(e){return this.rotateOnAxis(t,e)}}(),rotateZ:function(){var t=new u(0,0,1);return function(e){return this.rotateOnAxis(t,e)}}(),translateOnAxis:function(){var t=new u;return function(e,i){return t.copy(e).applyQuaternion(this.quaternion),this.position.add(t.multiplyScalar(i)),this}}(),translateX:function(){var t=new u(1,0,0);return function(e){return this.translateOnAxis(t,e)}}(),translateY:function(){var t=new u(0,1,0);return function(e){return this.translateOnAxis(t,e)}}(),translateZ:function(){var t=new u(0,0,1);return function(e){return this.translateOnAxis(t,e)}}(),localToWorld:function(t){return t.applyMatrix4(this.matrixWorld)},worldToLocal:function(){var t=new c;return function(e){return e.applyMatrix4(t.getInverse(this.matrixWorld))}}(),lookAt:function(){var t=new f,e=new c,i=new u,n=new u;return function(s,l,d){s.isVector3?i.copy(s):i.set(s,l,d),s=this.parent,this.updateWorldMatrix(!0,!1),n.setFromMatrixPosition(this.matrixWorld),this.isCamera?e.lookAt(n,i,this.up):e.lookAt(i,n,this.up),this.quaternion.setFromRotationMatrix(e),s&&(e.extractRotation(s.matrixWorld),t.setFromRotationMatrix(e),this.quaternion.premultiply(t.inverse()))}}(),add:function(t){if(1<arguments.length){for(var e=0;e<arguments.length;e++)this.add(arguments[e]);return this}return t===this?this:(t&&t.isObject3D&&(t.parent!==null&&t.parent.remove(t),t.parent=this,t.dispatchEvent({type:"added"}),this.children.push(t)),this)},remove:function(t){if(1<arguments.length){for(var e=0;e<arguments.length;e++)this.remove(arguments[e]);return this}return e=this.children.indexOf(t),e!==-1&&(t.parent=null,t.dispatchEvent({type:"removed"}),this.children.splice(e,1)),this},getObjectById:function(t){return this.getObjectByProperty("id",t)},getObjectByName:function(t){return this.getObjectByProperty("name",t)},getObjectByProperty:function(t,e){if(this[t]===e)return this;for(var i=0,n=this.children.length;i<n;i++){var s=this.children[i].getObjectByProperty(t,e);if(s!==void 0)return s}},getWorldPosition:function(t){return t===void 0&&(t=new u),this.updateMatrixWorld(!0),t.setFromMatrixPosition(this.matrixWorld)},getWorldQuaternion:function(){var t=new u,e=new u;return function(i){return i===void 0&&(i=new f),this.updateMatrixWorld(!0),this.matrixWorld.decompose(t,i,e),i}}(),getWorldScale:function(){var t=new u,e=new f;return function(i){return i===void 0&&(i=new u),this.updateMatrixWorld(!0),this.matrixWorld.decompose(t,e,i),i}}(),getWorldDirection:function(t){t===void 0&&(t=new u),this.updateMatrixWorld(!0);var e=this.matrixWorld.elements;return t.set(e[8],e[9],e[10]).normalize()},raycast:function(){},traverse:function(t){t(this);for(var e=this.children,i=0,n=e.length;i<n;i++)e[i].traverse(t)},traverseVisible:function(t){if(this.visible!==!1){t(this);for(var e=this.children,i=0,n=e.length;i<n;i++)e[i].traverseVisible(t)}},traverseAncestors:function(t){var e=this.parent;e!==null&&(t(e),e.traverseAncestors(t))},updateMatrix:function(){this.matrix.compose(this.position,this.quaternion,this.scale),this.matrixWorldNeedsUpdate=!0},updateMatrixWorld:function(t){this.matrixAutoUpdate&&this.updateMatrix(),(this.matrixWorldNeedsUpdate||t)&&(this.parent===null?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix),this.matrixWorldNeedsUpdate=!1,t=!0);for(var e=this.children,i=0,n=e.length;i<n;i++)e[i].updateMatrixWorld(t)},updateWorldMatrix:function(t,e){var i=this.parent;if(t===!0&&i!==null&&i.updateWorldMatrix(!0,!1),this.matrixAutoUpdate&&this.updateMatrix(),this.parent===null?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix),e===!0)for(t=this.children,e=0,i=t.length;e<i;e++)t[e].updateWorldMatrix(!1,!0)},toJSON:function(t){function e(A,L){return A[L.uuid]===void 0&&(A[L.uuid]=L.toJSON(t)),L.uuid}function i(A){var L=[],B;for(B in A){var H=A[B];delete H.metadata,L.push(H)}return L}var n=t===void 0||typeof t=="string",s={};n&&(t={geometries:{},materials:{},textures:{},images:{},shapes:{}},s.metadata={version:4.5,type:"Object",generator:"Object3D.toJSON"});var l={};if(l.uuid=this.uuid,l.type=this.type,this.name!==""&&(l.name=this.name),this.castShadow===!0&&(l.castShadow=!0),this.receiveShadow===!0&&(l.receiveShadow=!0),this.visible===!1&&(l.visible=!1),this.frustumCulled===!1&&(l.frustumCulled=!1),this.renderOrder!==0&&(l.renderOrder=this.renderOrder),JSON.stringify(this.userData)!=="{}"&&(l.userData=this.userData),l.layers=this.layers.mask,l.matrix=this.matrix.toArray(),this.matrixAutoUpdate===!1&&(l.matrixAutoUpdate=!1),this.isMesh||this.isLine||this.isPoints){l.geometry=e(t.geometries,this.geometry);var d=this.geometry.parameters;if(d!==void 0&&d.shapes!==void 0)if(d=d.shapes,Array.isArray(d))for(var p=0,_=d.length;p<_;p++)e(t.shapes,d[p]);else e(t.shapes,d)}if(this.material!==void 0)if(Array.isArray(this.material)){for(d=[],p=0,_=this.material.length;p<_;p++)d.push(e(t.materials,this.material[p]));l.material=d}else l.material=e(t.materials,this.material);if(0<this.children.length)for(l.children=[],p=0;p<this.children.length;p++)l.children.push(this.children[p].toJSON(t).object);if(n){n=i(t.geometries),p=i(t.materials),_=i(t.textures);var T=i(t.images);d=i(t.shapes),0<n.length&&(s.geometries=n),0<p.length&&(s.materials=p),0<_.length&&(s.textures=_),0<T.length&&(s.images=T),0<d.length&&(s.shapes=d)}return s.object=l,s},clone:function(t){return new this.constructor().copy(this,t)},copy:function(t,e){if(e===void 0&&(e=!0),this.name=t.name,this.up.copy(t.up),this.position.copy(t.position),this.quaternion.copy(t.quaternion),this.scale.copy(t.scale),this.matrix.copy(t.matrix),this.matrixWorld.copy(t.matrixWorld),this.matrixAutoUpdate=t.matrixAutoUpdate,this.matrixWorldNeedsUpdate=t.matrixWorldNeedsUpdate,this.layers.mask=t.layers.mask,this.visible=t.visible,this.castShadow=t.castShadow,this.receiveShadow=t.receiveShadow,this.frustumCulled=t.frustumCulled,this.renderOrder=t.renderOrder,this.userData=JSON.parse(JSON.stringify(t.userData)),e===!0)for(e=0;e<t.children.length;e++)this.add(t.children[e].clone());return this}});var Yc=0;X.prototype=Object.assign(Object.create(a.prototype),{constructor:X,isGeometry:!0,applyMatrix:function(t){for(var e=new m().getNormalMatrix(t),i=0,n=this.vertices.length;i<n;i++)this.vertices[i].applyMatrix4(t);for(i=0,n=this.faces.length;i<n;i++){t=this.faces[i],t.normal.applyMatrix3(e).normalize();for(var s=0,l=t.vertexNormals.length;s<l;s++)t.vertexNormals[s].applyMatrix3(e).normalize()}return this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this.normalsNeedUpdate=this.verticesNeedUpdate=!0,this},rotateX:function(){var t=new c;return function(e){return t.makeRotationX(e),this.applyMatrix(t),this}}(),rotateY:function(){var t=new c;return function(e){return t.makeRotationY(e),this.applyMatrix(t),this}}(),rotateZ:function(){var t=new c;return function(e){return t.makeRotationZ(e),this.applyMatrix(t),this}}(),translate:function(){var t=new c;return function(e,i,n){return t.makeTranslation(e,i,n),this.applyMatrix(t),this}}(),scale:function(){var t=new c;return function(e,i,n){return t.makeScale(e,i,n),this.applyMatrix(t),this}}(),lookAt:function(){var t=new N;return function(e){t.lookAt(e),t.updateMatrix(),this.applyMatrix(t.matrix)}}(),fromBufferGeometry:function(t){function e(q,$,rt,xt){var gt=p===void 0?[]:[i.colors[q].clone(),i.colors[$].clone(),i.colors[rt].clone()],Ct=d===void 0?[]:[new u().fromArray(d,3*q),new u().fromArray(d,3*$),new u().fromArray(d,3*rt)];xt=new R(q,$,rt,Ct,gt,xt),i.faces.push(xt),_!==void 0&&i.faceVertexUvs[0].push([new o().fromArray(_,2*q),new o().fromArray(_,2*$),new o().fromArray(_,2*rt)]),T!==void 0&&i.faceVertexUvs[1].push([new o().fromArray(T,2*q),new o().fromArray(T,2*$),new o().fromArray(T,2*rt)])}var i=this,n=t.index!==null?t.index.array:void 0,s=t.attributes,l=s.position.array,d=s.normal!==void 0?s.normal.array:void 0,p=s.color!==void 0?s.color.array:void 0,_=s.uv!==void 0?s.uv.array:void 0,T=s.uv2!==void 0?s.uv2.array:void 0;T!==void 0&&(this.faceVertexUvs[1]=[]);for(var A=s=0;s<l.length;s+=3,A+=2)i.vertices.push(new u().fromArray(l,s)),p!==void 0&&i.colors.push(new P().fromArray(p,s));var L=t.groups;if(0<L.length)for(s=0;s<L.length;s++){l=L[s];var B=l.start,H=l.count;for(A=B,B+=H;A<B;A+=3)n!==void 0?e(n[A],n[A+1],n[A+2],l.materialIndex):e(A,A+1,A+2,l.materialIndex)}else if(n!==void 0)for(s=0;s<n.length;s+=3)e(n[s],n[s+1],n[s+2]);else for(s=0;s<l.length/3;s+=3)e(s,s+1,s+2);return this.computeFaceNormals(),t.boundingBox!==null&&(this.boundingBox=t.boundingBox.clone()),t.boundingSphere!==null&&(this.boundingSphere=t.boundingSphere.clone()),this},center:function(){var t=new u;return function(){return this.computeBoundingBox(),this.boundingBox.getCenter(t).negate(),this.translate(t.x,t.y,t.z),this}}(),normalize:function(){this.computeBoundingSphere();var t=this.boundingSphere.center,e=this.boundingSphere.radius;e=e===0?1:1/e;var i=new c;return i.set(e,0,0,-e*t.x,0,e,0,-e*t.y,0,0,e,-e*t.z,0,0,0,1),this.applyMatrix(i),this},computeFaceNormals:function(){for(var t=new u,e=new u,i=0,n=this.faces.length;i<n;i++){var s=this.faces[i],l=this.vertices[s.a],d=this.vertices[s.b];t.subVectors(this.vertices[s.c],d),e.subVectors(l,d),t.cross(e),t.normalize(),s.normal.copy(t)}},computeVertexNormals:function(t){t===void 0&&(t=!0);var e,i=Array(this.vertices.length),n=0;for(e=this.vertices.length;n<e;n++)i[n]=new u;if(t){var s=new u,l=new u;for(t=0,n=this.faces.length;t<n;t++){e=this.faces[t];var d=this.vertices[e.a],p=this.vertices[e.b],_=this.vertices[e.c];s.subVectors(_,p),l.subVectors(d,p),s.cross(l),i[e.a].add(s),i[e.b].add(s),i[e.c].add(s)}}else for(this.computeFaceNormals(),t=0,n=this.faces.length;t<n;t++)e=this.faces[t],i[e.a].add(e.normal),i[e.b].add(e.normal),i[e.c].add(e.normal);for(n=0,e=this.vertices.length;n<e;n++)i[n].normalize();for(t=0,n=this.faces.length;t<n;t++)e=this.faces[t],d=e.vertexNormals,d.length===3?(d[0].copy(i[e.a]),d[1].copy(i[e.b]),d[2].copy(i[e.c])):(d[0]=i[e.a].clone(),d[1]=i[e.b].clone(),d[2]=i[e.c].clone());0<this.faces.length&&(this.normalsNeedUpdate=!0)},computeFlatVertexNormals:function(){var t;this.computeFaceNormals();var e=0;for(t=this.faces.length;e<t;e++){var i=this.faces[e],n=i.vertexNormals;n.length===3?(n[0].copy(i.normal),n[1].copy(i.normal),n[2].copy(i.normal)):(n[0]=i.normal.clone(),n[1]=i.normal.clone(),n[2]=i.normal.clone())}0<this.faces.length&&(this.normalsNeedUpdate=!0)},computeMorphNormals:function(){var t,e,i=0;for(e=this.faces.length;i<e;i++){var n=this.faces[i];n.__originalFaceNormal?n.__originalFaceNormal.copy(n.normal):n.__originalFaceNormal=n.normal.clone(),n.__originalVertexNormals||(n.__originalVertexNormals=[]);var s=0;for(t=n.vertexNormals.length;s<t;s++)n.__originalVertexNormals[s]?n.__originalVertexNormals[s].copy(n.vertexNormals[s]):n.__originalVertexNormals[s]=n.vertexNormals[s].clone()}var l=new X;for(l.faces=this.faces,s=0,t=this.morphTargets.length;s<t;s++){if(!this.morphNormals[s]){this.morphNormals[s]={},this.morphNormals[s].faceNormals=[],this.morphNormals[s].vertexNormals=[],n=this.morphNormals[s].faceNormals;var d=this.morphNormals[s].vertexNormals;for(i=0,e=this.faces.length;i<e;i++){var p=new u,_={a:new u,b:new u,c:new u};n.push(p),d.push(_)}}for(d=this.morphNormals[s],l.vertices=this.morphTargets[s].vertices,l.computeFaceNormals(),l.computeVertexNormals(),i=0,e=this.faces.length;i<e;i++)n=this.faces[i],p=d.faceNormals[i],_=d.vertexNormals[i],p.copy(n.normal),_.a.copy(n.vertexNormals[0]),_.b.copy(n.vertexNormals[1]),_.c.copy(n.vertexNormals[2])}for(i=0,e=this.faces.length;i<e;i++)n=this.faces[i],n.normal=n.__originalFaceNormal,n.vertexNormals=n.__originalVertexNormals},computeBoundingBox:function(){this.boundingBox===null&&(this.boundingBox=new k),this.boundingBox.setFromPoints(this.vertices)},computeBoundingSphere:function(){this.boundingSphere===null&&(this.boundingSphere=new I),this.boundingSphere.setFromPoints(this.vertices)},merge:function(t,e,i){if(t&&t.isGeometry){var n,s=this.vertices.length,l=this.vertices,d=t.vertices,p=this.faces,_=t.faces,T=this.faceVertexUvs[0],A=t.faceVertexUvs[0],L=this.colors,B=t.colors;i===void 0&&(i=0),e!==void 0&&(n=new m().getNormalMatrix(e)),t=0;for(var H=d.length;t<H;t++){var q=d[t].clone();e!==void 0&&q.applyMatrix4(e),l.push(q)}for(t=0,H=B.length;t<H;t++)L.push(B[t].clone());for(t=0,H=_.length;t<H;t++){d=_[t];var $=d.vertexNormals;for(B=d.vertexColors,L=new R(d.a+s,d.b+s,d.c+s),L.normal.copy(d.normal),n!==void 0&&L.normal.applyMatrix3(n).normalize(),e=0,l=$.length;e<l;e++)q=$[e].clone(),n!==void 0&&q.applyMatrix3(n).normalize(),L.vertexNormals.push(q);for(L.color.copy(d.color),e=0,l=B.length;e<l;e++)q=B[e],L.vertexColors.push(q.clone());L.materialIndex=d.materialIndex+i,p.push(L)}for(t=0,H=A.length;t<H;t++)if(i=A[t],n=[],i!==void 0){for(e=0,l=i.length;e<l;e++)n.push(i[e].clone());T.push(n)}}},mergeMesh:function(t){t&&t.isMesh&&(t.matrixAutoUpdate&&t.updateMatrix(),this.merge(t.geometry,t.matrix))},mergeVertices:function(){var t={},e=[],i=[],n=Math.pow(10,4),s,l=0;for(s=this.vertices.length;l<s;l++){var d=this.vertices[l];d=Math.round(d.x*n)+"_"+Math.round(d.y*n)+"_"+Math.round(d.z*n),t[d]===void 0?(t[d]=l,e.push(this.vertices[l]),i[l]=e.length-1):i[l]=i[t[d]]}for(t=[],l=0,s=this.faces.length;l<s;l++)for(n=this.faces[l],n.a=i[n.a],n.b=i[n.b],n.c=i[n.c],n=[n.a,n.b,n.c],d=0;3>d;d++)if(n[d]===n[(d+1)%3]){t.push(l);break}for(l=t.length-1;0<=l;l--)for(n=t[l],this.faces.splice(n,1),i=0,s=this.faceVertexUvs.length;i<s;i++)this.faceVertexUvs[i].splice(n,1);return l=this.vertices.length-e.length,this.vertices=e,l},setFromPoints:function(t){this.vertices=[];for(var e=0,i=t.length;e<i;e++){var n=t[e];this.vertices.push(new u(n.x,n.y,n.z||0))}return this},sortFacesByMaterialIndex:function(){for(var t=this.faces,e=t.length,i=0;i<e;i++)t[i]._id=i;t.sort(function(_,T){return _.materialIndex-T.materialIndex});var n=this.faceVertexUvs[0],s=this.faceVertexUvs[1],l,d;for(n&&n.length===e&&(l=[]),s&&s.length===e&&(d=[]),i=0;i<e;i++){var p=t[i]._id;l&&l.push(n[p]),d&&d.push(s[p])}l&&(this.faceVertexUvs[0]=l),d&&(this.faceVertexUvs[1]=d)},toJSON:function(){function t(Vt,K,ot){return ot?Vt|1<<K:Vt&~(1<<K)}function e(Vt){var K=Vt.x.toString()+Vt.y.toString()+Vt.z.toString();return T[K]!==void 0||(T[K]=_.length/3,_.push(Vt.x,Vt.y,Vt.z)),T[K]}function i(Vt){var K=Vt.r.toString()+Vt.g.toString()+Vt.b.toString();return L[K]!==void 0||(L[K]=A.length,A.push(Vt.getHex())),L[K]}function n(Vt){var K=Vt.x.toString()+Vt.y.toString();return H[K]!==void 0||(H[K]=B.length/2,B.push(Vt.x,Vt.y)),H[K]}var s={metadata:{version:4.5,type:"Geometry",generator:"Geometry.toJSON"}};if(s.uuid=this.uuid,s.type=this.type,this.name!==""&&(s.name=this.name),this.parameters!==void 0){var l=this.parameters,d;for(d in l)l[d]!==void 0&&(s[d]=l[d]);return s}for(l=[],d=0;d<this.vertices.length;d++){var p=this.vertices[d];l.push(p.x,p.y,p.z)}p=[];var _=[],T={},A=[],L={},B=[],H={};for(d=0;d<this.faces.length;d++){var q=this.faces[d],$=this.faceVertexUvs[0][d]!==void 0,rt=0<q.normal.length(),xt=0<q.vertexNormals.length,gt=q.color.r!==1||q.color.g!==1||q.color.b!==1,Ct=0<q.vertexColors.length,wt=0;wt=t(wt,0,0),wt=t(wt,1,!0),wt=t(wt,2,!1),wt=t(wt,3,$),wt=t(wt,4,rt),wt=t(wt,5,xt),wt=t(wt,6,gt),wt=t(wt,7,Ct),p.push(wt),p.push(q.a,q.b,q.c),p.push(q.materialIndex),$&&($=this.faceVertexUvs[0][d],p.push(n($[0]),n($[1]),n($[2]))),rt&&p.push(e(q.normal)),xt&&(rt=q.vertexNormals,p.push(e(rt[0]),e(rt[1]),e(rt[2]))),gt&&p.push(i(q.color)),Ct&&(q=q.vertexColors,p.push(i(q[0]),i(q[1]),i(q[2])))}return s.data={},s.data.vertices=l,s.data.normals=_,0<A.length&&(s.data.colors=A),0<B.length&&(s.data.uvs=[B]),s.data.faces=p,s},clone:function(){return new X().copy(this)},copy:function(t){var e,i,n;this.vertices=[],this.colors=[],this.faces=[],this.faceVertexUvs=[[]],this.morphTargets=[],this.morphNormals=[],this.skinWeights=[],this.skinIndices=[],this.lineDistances=[],this.boundingSphere=this.boundingBox=null,this.name=t.name;var s=t.vertices,l=0;for(e=s.length;l<e;l++)this.vertices.push(s[l].clone());for(s=t.colors,l=0,e=s.length;l<e;l++)this.colors.push(s[l].clone());for(s=t.faces,l=0,e=s.length;l<e;l++)this.faces.push(s[l].clone());for(l=0,e=t.faceVertexUvs.length;l<e;l++){var d=t.faceVertexUvs[l];for(this.faceVertexUvs[l]===void 0&&(this.faceVertexUvs[l]=[]),s=0,i=d.length;s<i;s++){var p=d[s],_=[],T=0;for(n=p.length;T<n;T++)_.push(p[T].clone());this.faceVertexUvs[l].push(_)}}for(T=t.morphTargets,l=0,e=T.length;l<e;l++){if(n={},n.name=T[l].name,T[l].vertices!==void 0)for(n.vertices=[],s=0,i=T[l].vertices.length;s<i;s++)n.vertices.push(T[l].vertices[s].clone());if(T[l].normals!==void 0)for(n.normals=[],s=0,i=T[l].normals.length;s<i;s++)n.normals.push(T[l].normals[s].clone());this.morphTargets.push(n)}for(T=t.morphNormals,l=0,e=T.length;l<e;l++){if(n={},T[l].vertexNormals!==void 0)for(n.vertexNormals=[],s=0,i=T[l].vertexNormals.length;s<i;s++)d=T[l].vertexNormals[s],p={},p.a=d.a.clone(),p.b=d.b.clone(),p.c=d.c.clone(),n.vertexNormals.push(p);if(T[l].faceNormals!==void 0)for(n.faceNormals=[],s=0,i=T[l].faceNormals.length;s<i;s++)n.faceNormals.push(T[l].faceNormals[s].clone());this.morphNormals.push(n)}for(s=t.skinWeights,l=0,e=s.length;l<e;l++)this.skinWeights.push(s[l].clone());for(s=t.skinIndices,l=0,e=s.length;l<e;l++)this.skinIndices.push(s[l].clone());for(s=t.lineDistances,l=0,e=s.length;l<e;l++)this.lineDistances.push(s[l]);return l=t.boundingBox,l!==null&&(this.boundingBox=l.clone()),l=t.boundingSphere,l!==null&&(this.boundingSphere=l.clone()),this.elementsNeedUpdate=t.elementsNeedUpdate,this.verticesNeedUpdate=t.verticesNeedUpdate,this.uvsNeedUpdate=t.uvsNeedUpdate,this.normalsNeedUpdate=t.normalsNeedUpdate,this.colorsNeedUpdate=t.colorsNeedUpdate,this.lineDistancesNeedUpdate=t.lineDistancesNeedUpdate,this.groupsNeedUpdate=t.groupsNeedUpdate,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),Object.defineProperty(J.prototype,"needsUpdate",{set:function(t){t===!0&&this.version++}}),Object.assign(J.prototype,{isBufferAttribute:!0,onUploadCallback:function(){},setArray:function(t){if(Array.isArray(t))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");return this.count=t!==void 0?t.length/this.itemSize:0,this.array=t,this},setDynamic:function(t){return this.dynamic=t,this},copy:function(t){return this.name=t.name,this.array=new t.array.constructor(t.array),this.itemSize=t.itemSize,this.count=t.count,this.normalized=t.normalized,this.dynamic=t.dynamic,this},copyAt:function(t,e,i){t*=this.itemSize,i*=e.itemSize;for(var n=0,s=this.itemSize;n<s;n++)this.array[t+n]=e.array[i+n];return this},copyArray:function(t){return this.array.set(t),this},copyColorsArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new P),e[i++]=l.r,e[i++]=l.g,e[i++]=l.b}return this},copyVector2sArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new o),e[i++]=l.x,e[i++]=l.y}return this},copyVector3sArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new u),e[i++]=l.x,e[i++]=l.y,e[i++]=l.z}return this},copyVector4sArray:function(t){for(var e=this.array,i=0,n=0,s=t.length;n<s;n++){var l=t[n];l===void 0&&(l=new v),e[i++]=l.x,e[i++]=l.y,e[i++]=l.z,e[i++]=l.w}return this},set:function(t,e){return e===void 0&&(e=0),this.array.set(t,e),this},getX:function(t){return this.array[t*this.itemSize]},setX:function(t,e){return this.array[t*this.itemSize]=e,this},getY:function(t){return this.array[t*this.itemSize+1]},setY:function(t,e){return this.array[t*this.itemSize+1]=e,this},getZ:function(t){return this.array[t*this.itemSize+2]},setZ:function(t,e){return this.array[t*this.itemSize+2]=e,this},getW:function(t){return this.array[t*this.itemSize+3]},setW:function(t,e){return this.array[t*this.itemSize+3]=e,this},setXY:function(t,e,i){return t*=this.itemSize,this.array[t+0]=e,this.array[t+1]=i,this},setXYZ:function(t,e,i,n){return t*=this.itemSize,this.array[t+0]=e,this.array[t+1]=i,this.array[t+2]=n,this},setXYZW:function(t,e,i,n,s){return t*=this.itemSize,this.array[t+0]=e,this.array[t+1]=i,this.array[t+2]=n,this.array[t+3]=s,this},onUpload:function(t){return this.onUploadCallback=t,this},clone:function(){return new this.constructor(this.array,this.itemSize).copy(this)}}),Z.prototype=Object.create(J.prototype),Z.prototype.constructor=Z,ct.prototype=Object.create(J.prototype),ct.prototype.constructor=ct,Rt.prototype=Object.create(J.prototype),Rt.prototype.constructor=Rt,tt.prototype=Object.create(J.prototype),tt.prototype.constructor=tt,_t.prototype=Object.create(J.prototype),_t.prototype.constructor=_t,G.prototype=Object.create(J.prototype),G.prototype.constructor=G,Pt.prototype=Object.create(J.prototype),Pt.prototype.constructor=Pt,Et.prototype=Object.create(J.prototype),Et.prototype.constructor=Et,At.prototype=Object.create(J.prototype),At.prototype.constructor=At,Object.assign(ce.prototype,{computeGroups:function(t){var e=[],i=void 0;t=t.faces;for(var n=0;n<t.length;n++){var s=t[n];if(s.materialIndex!==i){i=s.materialIndex,l!==void 0&&(l.count=3*n-l.start,e.push(l));var l={start:3*n,materialIndex:i}}}l!==void 0&&(l.count=3*n-l.start,e.push(l)),this.groups=e},fromGeometry:function(t){var e=t.faces,i=t.vertices,n=t.faceVertexUvs,s=n[0]&&0<n[0].length,l=n[1]&&0<n[1].length,d=t.morphTargets,p=d.length;if(0<p){for(var _=[],T=0;T<p;T++)_[T]={name:d[T].name,data:[]};this.morphTargets.position=_}var A=t.morphNormals,L=A.length;if(0<L){var B=[];for(T=0;T<L;T++)B[T]={name:A[T].name,data:[]};this.morphTargets.normal=B}var H=t.skinIndices,q=t.skinWeights,$=H.length===i.length,rt=q.length===i.length;for(0<i.length&&e.length,T=0;T<e.length;T++){var xt=e[T];this.vertices.push(i[xt.a],i[xt.b],i[xt.c]);var gt=xt.vertexNormals;for(gt.length===3?this.normals.push(gt[0],gt[1],gt[2]):(gt=xt.normal,this.normals.push(gt,gt,gt)),gt=xt.vertexColors,gt.length===3?this.colors.push(gt[0],gt[1],gt[2]):(gt=xt.color,this.colors.push(gt,gt,gt)),s===!0&&(gt=n[0][T],gt!==void 0?this.uvs.push(gt[0],gt[1],gt[2]):this.uvs.push(new o,new o,new o)),l===!0&&(gt=n[1][T],gt!==void 0?this.uvs2.push(gt[0],gt[1],gt[2]):this.uvs2.push(new o,new o,new o)),gt=0;gt<p;gt++){var Ct=d[gt].vertices;_[gt].data.push(Ct[xt.a],Ct[xt.b],Ct[xt.c])}for(gt=0;gt<L;gt++)Ct=A[gt].vertexNormals[T],B[gt].data.push(Ct.a,Ct.b,Ct.c);$&&this.skinIndices.push(H[xt.a],H[xt.b],H[xt.c]),rt&&this.skinWeights.push(q[xt.a],q[xt.b],q[xt.c])}return this.computeGroups(t),this.verticesNeedUpdate=t.verticesNeedUpdate,this.normalsNeedUpdate=t.normalsNeedUpdate,this.colorsNeedUpdate=t.colorsNeedUpdate,this.uvsNeedUpdate=t.uvsNeedUpdate,this.groupsNeedUpdate=t.groupsNeedUpdate,this}});var Zc=1;Ft.prototype=Object.assign(Object.create(a.prototype),{constructor:Ft,isBufferGeometry:!0,getIndex:function(){return this.index},setIndex:function(t){Array.isArray(t)?this.index=new(65535<re(t)?Pt:_t)(t,1):this.index=t},addAttribute:function(t,e,i){return e&&e.isBufferAttribute||e&&e.isInterleavedBufferAttribute?t==="index"?(this.setIndex(e),this):(this.attributes[t]=e,this):this.addAttribute(t,new J(e,i))},getAttribute:function(t){return this.attributes[t]},removeAttribute:function(t){return delete this.attributes[t],this},addGroup:function(t,e,i){this.groups.push({start:t,count:e,materialIndex:i!==void 0?i:0})},clearGroups:function(){this.groups=[]},setDrawRange:function(t,e){this.drawRange.start=t,this.drawRange.count=e},applyMatrix:function(t){var e=this.attributes.position;return e!==void 0&&(t.applyToBufferAttribute(e),e.needsUpdate=!0),e=this.attributes.normal,e!==void 0&&(new m().getNormalMatrix(t).applyToBufferAttribute(e),e.needsUpdate=!0),this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this},rotateX:function(){var t=new c;return function(e){return t.makeRotationX(e),this.applyMatrix(t),this}}(),rotateY:function(){var t=new c;return function(e){return t.makeRotationY(e),this.applyMatrix(t),this}}(),rotateZ:function(){var t=new c;return function(e){return t.makeRotationZ(e),this.applyMatrix(t),this}}(),translate:function(){var t=new c;return function(e,i,n){return t.makeTranslation(e,i,n),this.applyMatrix(t),this}}(),scale:function(){var t=new c;return function(e,i,n){return t.makeScale(e,i,n),this.applyMatrix(t),this}}(),lookAt:function(){var t=new N;return function(e){t.lookAt(e),t.updateMatrix(),this.applyMatrix(t.matrix)}}(),center:function(){var t=new u;return function(){return this.computeBoundingBox(),this.boundingBox.getCenter(t).negate(),this.translate(t.x,t.y,t.z),this}}(),setFromObject:function(t){var e=t.geometry;if(t.isPoints||t.isLine){t=new Et(3*e.vertices.length,3);var i=new Et(3*e.colors.length,3);this.addAttribute("position",t.copyVector3sArray(e.vertices)),this.addAttribute("color",i.copyColorsArray(e.colors)),e.lineDistances&&e.lineDistances.length===e.vertices.length&&(t=new Et(e.lineDistances.length,1),this.addAttribute("lineDistance",t.copyArray(e.lineDistances))),e.boundingSphere!==null&&(this.boundingSphere=e.boundingSphere.clone()),e.boundingBox!==null&&(this.boundingBox=e.boundingBox.clone())}else t.isMesh&&e&&e.isGeometry&&this.fromGeometry(e);return this},setFromPoints:function(t){for(var e=[],i=0,n=t.length;i<n;i++){var s=t[i];e.push(s.x,s.y,s.z||0)}return this.addAttribute("position",new Et(e,3)),this},updateFromObject:function(t){var e=t.geometry;if(t.isMesh){var i=e.__directGeometry;if(e.elementsNeedUpdate===!0&&(i=void 0,e.elementsNeedUpdate=!1),i===void 0)return this.fromGeometry(e);i.verticesNeedUpdate=e.verticesNeedUpdate,i.normalsNeedUpdate=e.normalsNeedUpdate,i.colorsNeedUpdate=e.colorsNeedUpdate,i.uvsNeedUpdate=e.uvsNeedUpdate,i.groupsNeedUpdate=e.groupsNeedUpdate,e.verticesNeedUpdate=!1,e.normalsNeedUpdate=!1,e.colorsNeedUpdate=!1,e.uvsNeedUpdate=!1,e.groupsNeedUpdate=!1,e=i}return e.verticesNeedUpdate===!0&&(i=this.attributes.position,i!==void 0&&(i.copyVector3sArray(e.vertices),i.needsUpdate=!0),e.verticesNeedUpdate=!1),e.normalsNeedUpdate===!0&&(i=this.attributes.normal,i!==void 0&&(i.copyVector3sArray(e.normals),i.needsUpdate=!0),e.normalsNeedUpdate=!1),e.colorsNeedUpdate===!0&&(i=this.attributes.color,i!==void 0&&(i.copyColorsArray(e.colors),i.needsUpdate=!0),e.colorsNeedUpdate=!1),e.uvsNeedUpdate&&(i=this.attributes.uv,i!==void 0&&(i.copyVector2sArray(e.uvs),i.needsUpdate=!0),e.uvsNeedUpdate=!1),e.lineDistancesNeedUpdate&&(i=this.attributes.lineDistance,i!==void 0&&(i.copyArray(e.lineDistances),i.needsUpdate=!0),e.lineDistancesNeedUpdate=!1),e.groupsNeedUpdate&&(e.computeGroups(t.geometry),this.groups=e.groups,e.groupsNeedUpdate=!1),this},fromGeometry:function(t){return t.__directGeometry=new ce().fromGeometry(t),this.fromDirectGeometry(t.__directGeometry)},fromDirectGeometry:function(t){var e=new Float32Array(3*t.vertices.length);this.addAttribute("position",new J(e,3).copyVector3sArray(t.vertices)),0<t.normals.length&&(e=new Float32Array(3*t.normals.length),this.addAttribute("normal",new J(e,3).copyVector3sArray(t.normals))),0<t.colors.length&&(e=new Float32Array(3*t.colors.length),this.addAttribute("color",new J(e,3).copyColorsArray(t.colors))),0<t.uvs.length&&(e=new Float32Array(2*t.uvs.length),this.addAttribute("uv",new J(e,2).copyVector2sArray(t.uvs))),0<t.uvs2.length&&(e=new Float32Array(2*t.uvs2.length),this.addAttribute("uv2",new J(e,2).copyVector2sArray(t.uvs2))),this.groups=t.groups;for(var i in t.morphTargets){e=[];for(var n=t.morphTargets[i],s=0,l=n.length;s<l;s++){var d=n[s],p=new Et(3*d.data.length,3);p.name=d.name,e.push(p.copyVector3sArray(d.data))}this.morphAttributes[i]=e}return 0<t.skinIndices.length&&(i=new Et(4*t.skinIndices.length,4),this.addAttribute("skinIndex",i.copyVector4sArray(t.skinIndices))),0<t.skinWeights.length&&(i=new Et(4*t.skinWeights.length,4),this.addAttribute("skinWeight",i.copyVector4sArray(t.skinWeights))),t.boundingSphere!==null&&(this.boundingSphere=t.boundingSphere.clone()),t.boundingBox!==null&&(this.boundingBox=t.boundingBox.clone()),this},computeBoundingBox:function(){this.boundingBox===null&&(this.boundingBox=new k);var t=this.attributes.position;t!==void 0?this.boundingBox.setFromBufferAttribute(t):this.boundingBox.makeEmpty(),isNaN(this.boundingBox.min.x)||isNaN(this.boundingBox.min.y)||isNaN(this.boundingBox.min.z)},computeBoundingSphere:function(){var t=new k,e=new u;return function(){this.boundingSphere===null&&(this.boundingSphere=new I);var i=this.attributes.position;if(i){var n=this.boundingSphere.center;t.setFromBufferAttribute(i),t.getCenter(n);for(var s=0,l=0,d=i.count;l<d;l++)e.x=i.getX(l),e.y=i.getY(l),e.z=i.getZ(l),s=Math.max(s,n.distanceToSquared(e));this.boundingSphere.radius=Math.sqrt(s),isNaN(this.boundingSphere.radius)}}}(),computeFaceNormals:function(){},computeVertexNormals:function(){var t=this.index,e=this.attributes;if(e.position){var i=e.position.array;if(e.normal===void 0)this.addAttribute("normal",new J(new Float32Array(i.length),3));else for(var n=e.normal.array,s=0,l=n.length;s<l;s++)n[s]=0;n=e.normal.array;var d=new u,p=new u,_=new u,T=new u,A=new u;if(t){var L=t.array;for(s=0,l=t.count;s<l;s+=3){t=3*L[s+0];var B=3*L[s+1],H=3*L[s+2];d.fromArray(i,t),p.fromArray(i,B),_.fromArray(i,H),T.subVectors(_,p),A.subVectors(d,p),T.cross(A),n[t]+=T.x,n[t+1]+=T.y,n[t+2]+=T.z,n[B]+=T.x,n[B+1]+=T.y,n[B+2]+=T.z,n[H]+=T.x,n[H+1]+=T.y,n[H+2]+=T.z}}else for(s=0,l=i.length;s<l;s+=9)d.fromArray(i,s),p.fromArray(i,s+3),_.fromArray(i,s+6),T.subVectors(_,p),A.subVectors(d,p),T.cross(A),n[s]=T.x,n[s+1]=T.y,n[s+2]=T.z,n[s+3]=T.x,n[s+4]=T.y,n[s+5]=T.z,n[s+6]=T.x,n[s+7]=T.y,n[s+8]=T.z;this.normalizeNormals(),e.normal.needsUpdate=!0}},merge:function(t,e){if(t&&t.isBufferGeometry){e===void 0&&(e=0);var i=this.attributes,n;for(n in i)if(t.attributes[n]!==void 0){var s=i[n].array,l=t.attributes[n],d=l.array,p=0;for(l=l.itemSize*e;p<d.length;p++,l++)s[l]=d[p]}return this}},normalizeNormals:function(){var t=new u;return function(){for(var e=this.attributes.normal,i=0,n=e.count;i<n;i++)t.x=e.getX(i),t.y=e.getY(i),t.z=e.getZ(i),t.normalize(),e.setXYZ(i,t.x,t.y,t.z)}}(),toNonIndexed:function(){if(this.index===null)return this;var t=new Ft,e=this.index.array,i=this.attributes,n;for(n in i){var s=i[n],l=s.array,d=s.itemSize,p=new l.constructor(e.length*d),_=0;s=0;for(var T=e.length;s<T;s++)for(var A=e[s]*d,L=0;L<d;L++)p[_++]=l[A++];t.addAttribute(n,new J(p,d))}for(e=this.groups,s=0,T=e.length;s<T;s++)i=e[s],t.addGroup(i.start,i.count,i.materialIndex);return t},toJSON:function(){var t={metadata:{version:4.5,type:"BufferGeometry",generator:"BufferGeometry.toJSON"}};if(t.uuid=this.uuid,t.type=this.type,this.name!==""&&(t.name=this.name),0<Object.keys(this.userData).length&&(t.userData=this.userData),this.parameters!==void 0){var e=this.parameters;for(s in e)e[s]!==void 0&&(t[s]=e[s]);return t}t.data={attributes:{}};var i=this.index;i!==null&&(e=Array.prototype.slice.call(i.array),t.data.index={type:i.array.constructor.name,array:e}),i=this.attributes;for(s in i){var n=i[s];e=Array.prototype.slice.call(n.array),t.data.attributes[s]={itemSize:n.itemSize,type:n.array.constructor.name,array:e,normalized:n.normalized}}var s=this.groups;return 0<s.length&&(t.data.groups=JSON.parse(JSON.stringify(s))),s=this.boundingSphere,s!==null&&(t.data.boundingSphere={center:s.center.toArray(),radius:s.radius}),t},clone:function(){return new Ft().copy(this)},copy:function(t){var e;this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingSphere=this.boundingBox=null,this.name=t.name;var i=t.index;i!==null&&this.setIndex(i.clone()),i=t.attributes;for(d in i)this.addAttribute(d,i[d].clone());var n=t.morphAttributes;for(d in n){var s=[],l=n[d];for(i=0,e=l.length;i<e;i++)s.push(l[i].clone());this.morphAttributes[d]=s}var d=t.groups;for(i=0,e=d.length;i<e;i++)n=d[i],this.addGroup(n.start,n.count,n.materialIndex);return d=t.boundingBox,d!==null&&(this.boundingBox=d.clone()),d=t.boundingSphere,d!==null&&(this.boundingSphere=d.clone()),this.drawRange.start=t.drawRange.start,this.drawRange.count=t.drawRange.count,this.userData=t.userData,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),It.prototype=Object.create(X.prototype),It.prototype.constructor=It,Nt.prototype=Object.create(Ft.prototype),Nt.prototype.constructor=Nt,Pe.prototype=Object.create(X.prototype),Pe.prototype.constructor=Pe,pe.prototype=Object.create(Ft.prototype),pe.prototype.constructor=pe;var zu=0;Wt.prototype=Object.assign(Object.create(a.prototype),{constructor:Wt,isMaterial:!0,onBeforeCompile:function(){},setValues:function(t){if(t!==void 0)for(var e in t){var i=t[e];if(i!==void 0)if(e==="shading")this.flatShading=i===1;else{var n=this[e];n===void 0||(n&&n.isColor?n.set(i):n&&n.isVector3&&i&&i.isVector3?n.copy(i):this[e]=i)}}},toJSON:function(t){function e(s){var l=[],d;for(d in s){var p=s[d];delete p.metadata,l.push(p)}return l}var i=t===void 0||typeof t=="string";i&&(t={textures:{},images:{}});var n={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};return n.uuid=this.uuid,n.type=this.type,this.name!==""&&(n.name=this.name),this.color&&this.color.isColor&&(n.color=this.color.getHex()),this.roughness!==void 0&&(n.roughness=this.roughness),this.metalness!==void 0&&(n.metalness=this.metalness),this.emissive&&this.emissive.isColor&&(n.emissive=this.emissive.getHex()),this.emissiveIntensity!==1&&(n.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(n.specular=this.specular.getHex()),this.shininess!==void 0&&(n.shininess=this.shininess),this.clearCoat!==void 0&&(n.clearCoat=this.clearCoat),this.clearCoatRoughness!==void 0&&(n.clearCoatRoughness=this.clearCoatRoughness),this.map&&this.map.isTexture&&(n.map=this.map.toJSON(t).uuid),this.alphaMap&&this.alphaMap.isTexture&&(n.alphaMap=this.alphaMap.toJSON(t).uuid),this.lightMap&&this.lightMap.isTexture&&(n.lightMap=this.lightMap.toJSON(t).uuid),this.aoMap&&this.aoMap.isTexture&&(n.aoMap=this.aoMap.toJSON(t).uuid,n.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(n.bumpMap=this.bumpMap.toJSON(t).uuid,n.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(n.normalMap=this.normalMap.toJSON(t).uuid,n.normalMapType=this.normalMapType,n.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(n.displacementMap=this.displacementMap.toJSON(t).uuid,n.displacementScale=this.displacementScale,n.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(n.roughnessMap=this.roughnessMap.toJSON(t).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(n.metalnessMap=this.metalnessMap.toJSON(t).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(n.emissiveMap=this.emissiveMap.toJSON(t).uuid),this.specularMap&&this.specularMap.isTexture&&(n.specularMap=this.specularMap.toJSON(t).uuid),this.envMap&&this.envMap.isTexture&&(n.envMap=this.envMap.toJSON(t).uuid,n.reflectivity=this.reflectivity,this.combine!==void 0&&(n.combine=this.combine),this.envMapIntensity!==void 0&&(n.envMapIntensity=this.envMapIntensity)),this.gradientMap&&this.gradientMap.isTexture&&(n.gradientMap=this.gradientMap.toJSON(t).uuid),this.size!==void 0&&(n.size=this.size),this.sizeAttenuation!==void 0&&(n.sizeAttenuation=this.sizeAttenuation),this.blending!==1&&(n.blending=this.blending),this.flatShading===!0&&(n.flatShading=this.flatShading),this.side!==0&&(n.side=this.side),this.vertexColors!==0&&(n.vertexColors=this.vertexColors),1>this.opacity&&(n.opacity=this.opacity),this.transparent===!0&&(n.transparent=this.transparent),n.depthFunc=this.depthFunc,n.depthTest=this.depthTest,n.depthWrite=this.depthWrite,this.rotation!==0&&(n.rotation=this.rotation),this.polygonOffset===!0&&(n.polygonOffset=!0),this.polygonOffsetFactor!==0&&(n.polygonOffsetFactor=this.polygonOffsetFactor),this.polygonOffsetUnits!==0&&(n.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth!==1&&(n.linewidth=this.linewidth),this.dashSize!==void 0&&(n.dashSize=this.dashSize),this.gapSize!==void 0&&(n.gapSize=this.gapSize),this.scale!==void 0&&(n.scale=this.scale),this.dithering===!0&&(n.dithering=!0),0<this.alphaTest&&(n.alphaTest=this.alphaTest),this.premultipliedAlpha===!0&&(n.premultipliedAlpha=this.premultipliedAlpha),this.wireframe===!0&&(n.wireframe=this.wireframe),1<this.wireframeLinewidth&&(n.wireframeLinewidth=this.wireframeLinewidth),this.wireframeLinecap!=="round"&&(n.wireframeLinecap=this.wireframeLinecap),this.wireframeLinejoin!=="round"&&(n.wireframeLinejoin=this.wireframeLinejoin),this.morphTargets===!0&&(n.morphTargets=!0),this.skinning===!0&&(n.skinning=!0),this.visible===!1&&(n.visible=!1),JSON.stringify(this.userData)!=="{}"&&(n.userData=this.userData),i&&(i=e(t.textures),t=e(t.images),0<i.length&&(n.textures=i),0<t.length&&(n.images=t)),n},clone:function(){return new this.constructor().copy(this)},copy:function(t){this.name=t.name,this.fog=t.fog,this.lights=t.lights,this.blending=t.blending,this.side=t.side,this.flatShading=t.flatShading,this.vertexColors=t.vertexColors,this.opacity=t.opacity,this.transparent=t.transparent,this.blendSrc=t.blendSrc,this.blendDst=t.blendDst,this.blendEquation=t.blendEquation,this.blendSrcAlpha=t.blendSrcAlpha,this.blendDstAlpha=t.blendDstAlpha,this.blendEquationAlpha=t.blendEquationAlpha,this.depthFunc=t.depthFunc,this.depthTest=t.depthTest,this.depthWrite=t.depthWrite,this.colorWrite=t.colorWrite,this.precision=t.precision,this.polygonOffset=t.polygonOffset,this.polygonOffsetFactor=t.polygonOffsetFactor,this.polygonOffsetUnits=t.polygonOffsetUnits,this.dithering=t.dithering,this.alphaTest=t.alphaTest,this.premultipliedAlpha=t.premultipliedAlpha,this.visible=t.visible,this.userData=JSON.parse(JSON.stringify(t.userData)),this.clipShadows=t.clipShadows,this.clipIntersection=t.clipIntersection;var e=t.clippingPlanes,i=null;if(e!==null){var n=e.length;i=Array(n);for(var s=0;s!==n;++s)i[s]=e[s].clone()}return this.clippingPlanes=i,this.shadowSide=t.shadowSide,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),$e.prototype=Object.create(Wt.prototype),$e.prototype.constructor=$e,$e.prototype.isShaderMaterial=!0,$e.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.fragmentShader=t.fragmentShader,this.vertexShader=t.vertexShader,this.uniforms=Bn.clone(t.uniforms),this.defines=Object.assign({},t.defines),this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.lights=t.lights,this.clipping=t.clipping,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this.extensions=t.extensions,this},$e.prototype.toJSON=function(t){var e=Wt.prototype.toJSON.call(this,t);e.uniforms={};for(var i in this.uniforms){var n=this.uniforms[i].value;e.uniforms[i]=n.isTexture?{type:"t",value:n.toJSON(t).uuid}:n.isColor?{type:"c",value:n.getHex()}:n.isVector2?{type:"v2",value:n.toArray()}:n.isVector3?{type:"v3",value:n.toArray()}:n.isVector4?{type:"v4",value:n.toArray()}:n.isMatrix4?{type:"m4",value:n.toArray()}:{value:n}}return 0<Object.keys(this.defines).length&&(e.defines=this.defines),e.vertexShader=this.vertexShader,e.fragmentShader=this.fragmentShader,e},Object.assign(Si.prototype,{set:function(t,e){return this.origin.copy(t),this.direction.copy(e),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.origin.copy(t.origin),this.direction.copy(t.direction),this},at:function(t,e){return e===void 0&&(e=new u),e.copy(this.direction).multiplyScalar(t).add(this.origin)},lookAt:function(t){return this.direction.copy(t).sub(this.origin).normalize(),this},recast:function(){var t=new u;return function(e){return this.origin.copy(this.at(e,t)),this}}(),closestPointToPoint:function(t,e){return e===void 0&&(e=new u),e.subVectors(t,this.origin),t=e.dot(this.direction),0>t?e.copy(this.origin):e.copy(this.direction).multiplyScalar(t).add(this.origin)},distanceToPoint:function(t){return Math.sqrt(this.distanceSqToPoint(t))},distanceSqToPoint:function(){var t=new u;return function(e){var i=t.subVectors(e,this.origin).dot(this.direction);return 0>i?this.origin.distanceToSquared(e):(t.copy(this.direction).multiplyScalar(i).add(this.origin),t.distanceToSquared(e))}}(),distanceSqToSegment:function(){var t=new u,e=new u,i=new u;return function(n,s,l,d){t.copy(n).add(s).multiplyScalar(.5),e.copy(s).sub(n).normalize(),i.copy(this.origin).sub(t);var p=.5*n.distanceTo(s),_=-this.direction.dot(e),T=i.dot(this.direction),A=-i.dot(e),L=i.lengthSq(),B=Math.abs(1-_*_);if(0<B){n=_*A-T,s=_*T-A;var H=p*B;0<=n?s>=-H?s<=H?(p=1/B,n*=p,s*=p,_=n*(n+_*s+2*T)+s*(_*n+s+2*A)+L):(s=p,n=Math.max(0,-(_*s+T)),_=-n*n+s*(s+2*A)+L):(s=-p,n=Math.max(0,-(_*s+T)),_=-n*n+s*(s+2*A)+L):s<=-H?(n=Math.max(0,-(-_*p+T)),s=0<n?-p:Math.min(Math.max(-p,-A),p),_=-n*n+s*(s+2*A)+L):s<=H?(n=0,s=Math.min(Math.max(-p,-A),p),_=s*(s+2*A)+L):(n=Math.max(0,-(_*p+T)),s=0<n?p:Math.min(Math.max(-p,-A),p),_=-n*n+s*(s+2*A)+L)}else s=0<_?-p:p,n=Math.max(0,-(_*s+T)),_=-n*n+s*(s+2*A)+L;return l&&l.copy(this.direction).multiplyScalar(n).add(this.origin),d&&d.copy(e).multiplyScalar(s).add(t),_}}(),intersectSphere:function(){var t=new u;return function(e,i){t.subVectors(e.center,this.origin);var n=t.dot(this.direction),s=t.dot(t)-n*n;return e=e.radius*e.radius,s>e?null:(e=Math.sqrt(e-s),s=n-e,n+=e,0>s&&0>n?null:0>s?this.at(n,i):this.at(s,i))}}(),intersectsSphere:function(t){return this.distanceSqToPoint(t.center)<=t.radius*t.radius},distanceToPlane:function(t){var e=t.normal.dot(this.direction);return e===0?t.distanceToPoint(this.origin)===0?0:null:(t=-(this.origin.dot(t.normal)+t.constant)/e,0<=t?t:null)},intersectPlane:function(t,e){return t=this.distanceToPlane(t),t===null?null:this.at(t,e)},intersectsPlane:function(t){var e=t.distanceToPoint(this.origin);return e===0||0>t.normal.dot(this.direction)*e},intersectBox:function(t,e){var i=1/this.direction.x,n=1/this.direction.y,s=1/this.direction.z,l=this.origin;if(0<=i){var d=(t.min.x-l.x)*i;i*=t.max.x-l.x}else d=(t.max.x-l.x)*i,i*=t.min.x-l.x;if(0<=n){var p=(t.min.y-l.y)*n;n*=t.max.y-l.y}else p=(t.max.y-l.y)*n,n*=t.min.y-l.y;return d>n||p>i||((p>d||d!==d)&&(d=p),(n<i||i!==i)&&(i=n),0<=s?(p=(t.min.z-l.z)*s,t=(t.max.z-l.z)*s):(p=(t.max.z-l.z)*s,t=(t.min.z-l.z)*s),d>t||p>i)?null:((p>d||d!==d)&&(d=p),(t<i||i!==i)&&(i=t),0>i?null:this.at(0<=d?d:i,e))},intersectsBox:function(){var t=new u;return function(e){return this.intersectBox(e,t)!==null}}(),intersectTriangle:function(){var t=new u,e=new u,i=new u,n=new u;return function(s,l,d,p,_){if(e.subVectors(l,s),i.subVectors(d,s),n.crossVectors(e,i),l=this.direction.dot(n),0<l){if(p)return null;p=1}else if(0>l)p=-1,l=-l;else return null;return t.subVectors(this.origin,s),s=p*this.direction.dot(i.crossVectors(t,i)),0>s||(d=p*this.direction.dot(e.cross(t)),0>d||s+d>l)?null:(s=-p*t.dot(n),0>s?null:this.at(s/l,_))}}(),applyMatrix4:function(t){return this.origin.applyMatrix4(t),this.direction.transformDirection(t),this},equals:function(t){return t.origin.equals(this.origin)&&t.direction.equals(this.direction)}}),Object.assign(Oe,{getNormal:function(){var t=new u;return function(e,i,n,s){return s===void 0&&(s=new u),s.subVectors(n,i),t.subVectors(e,i),s.cross(t),e=s.lengthSq(),0<e?s.multiplyScalar(1/Math.sqrt(e)):s.set(0,0,0)}}(),getBarycoord:function(){var t=new u,e=new u,i=new u;return function(n,s,l,d,p){t.subVectors(d,s),e.subVectors(l,s),i.subVectors(n,s),n=t.dot(t),s=t.dot(e),l=t.dot(i);var _=e.dot(e);d=e.dot(i);var T=n*_-s*s;return p===void 0&&(p=new u),T===0?p.set(-2,-1,-1):(T=1/T,_=(_*l-s*d)*T,n=(n*d-s*l)*T,p.set(1-_-n,n,_))}}(),containsPoint:function(){var t=new u;return function(e,i,n,s){return Oe.getBarycoord(e,i,n,s,t),0<=t.x&&0<=t.y&&1>=t.x+t.y}}(),getUV:function(){var t=new u;return function(e,i,n,s,l,d,p,_){return this.getBarycoord(e,i,n,s,t),_.set(0,0),_.addScaledVector(l,t.x),_.addScaledVector(d,t.y),_.addScaledVector(p,t.z),_}}()}),Object.assign(Oe.prototype,{set:function(t,e,i){return this.a.copy(t),this.b.copy(e),this.c.copy(i),this},setFromPointsAndIndices:function(t,e,i,n){return this.a.copy(t[e]),this.b.copy(t[i]),this.c.copy(t[n]),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.a.copy(t.a),this.b.copy(t.b),this.c.copy(t.c),this},getArea:function(){var t=new u,e=new u;return function(){return t.subVectors(this.c,this.b),e.subVectors(this.a,this.b),.5*t.cross(e).length()}}(),getMidpoint:function(t){return t===void 0&&(t=new u),t.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},getNormal:function(t){return Oe.getNormal(this.a,this.b,this.c,t)},getPlane:function(t){return t===void 0&&(t=new u),t.setFromCoplanarPoints(this.a,this.b,this.c)},getBarycoord:function(t,e){return Oe.getBarycoord(t,this.a,this.b,this.c,e)},containsPoint:function(t){return Oe.containsPoint(t,this.a,this.b,this.c)},getUV:function(t,e,i,n,s){return Oe.getUV(t,this.a,this.b,this.c,e,i,n,s)},intersectsBox:function(t){return t.intersectsTriangle(this)},closestPointToPoint:function(){var t=new u,e=new u,i=new u,n=new u,s=new u,l=new u;return function(d,p){p===void 0&&(p=new u);var _=this.a,T=this.b,A=this.c;t.subVectors(T,_),e.subVectors(A,_),n.subVectors(d,_);var L=t.dot(n),B=e.dot(n);if(0>=L&&0>=B)return p.copy(_);s.subVectors(d,T);var H=t.dot(s),q=e.dot(s);if(0<=H&&q<=H)return p.copy(T);var $=L*q-H*B;if(0>=$&&0<=L&&0>=H)return T=L/(L-H),p.copy(_).addScaledVector(t,T);l.subVectors(d,A),d=t.dot(l);var rt=e.dot(l);return 0<=rt&&d<=rt?p.copy(A):(L=d*B-L*rt,0>=L&&0<=B&&0>=rt?($=B/(B-rt),p.copy(_).addScaledVector(e,$)):(B=H*rt-d*q,0>=B&&0<=q-H&&0<=d-rt?(i.subVectors(A,T),$=(q-H)/(q-H+(d-rt)),p.copy(T).addScaledVector(i,$)):(A=1/(B+L+$),T=L*A,$*=A,p.copy(_).addScaledVector(t,T).addScaledVector(e,$))))}}(),equals:function(t){return t.a.equals(this.a)&&t.b.equals(this.b)&&t.c.equals(this.c)}}),Ge.prototype=Object.create(Wt.prototype),Ge.prototype.constructor=Ge,Ge.prototype.isMeshBasicMaterial=!0,Ge.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.specularMap=t.specularMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.combine=t.combine,this.reflectivity=t.reflectivity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this},pi.prototype=Object.assign(Object.create(N.prototype),{constructor:pi,isMesh:!0,setDrawMode:function(t){this.drawMode=t},copy:function(t){return N.prototype.copy.call(this,t),this.drawMode=t.drawMode,t.morphTargetInfluences!==void 0&&(this.morphTargetInfluences=t.morphTargetInfluences.slice()),t.morphTargetDictionary!==void 0&&(this.morphTargetDictionary=Object.assign({},t.morphTargetDictionary)),this},updateMorphTargets:function(){var t=this.geometry;if(t.isBufferGeometry){t=t.morphAttributes;var e=Object.keys(t);if(0<e.length){var i=t[e[0]];if(i!==void 0)for(this.morphTargetInfluences=[],this.morphTargetDictionary={},t=0,e=i.length;t<e;t++){var n=i[t].name||String(t);this.morphTargetInfluences.push(0),this.morphTargetDictionary[n]=t}}}else if(i=t.morphTargets,i!==void 0&&0<i.length)for(this.morphTargetInfluences=[],this.morphTargetDictionary={},t=0,e=i.length;t<e;t++)n=i[t].name||String(t),this.morphTargetInfluences.push(0),this.morphTargetDictionary[n]=t},raycast:function(){function t(rt,xt,gt,Ct,wt,Vt,K,ot){return(xt.side===1?Ct.intersectTriangle(K,Vt,wt,!0,ot):Ct.intersectTriangle(wt,Vt,K,xt.side!==2,ot))===null?null:($.copy(ot),$.applyMatrix4(rt.matrixWorld),xt=gt.ray.origin.distanceTo($),xt<gt.near||xt>gt.far?null:{distance:xt,point:$.clone(),object:rt})}function e(rt,xt,gt,Ct,wt,Vt,K,ot,kt){return l.fromBufferAttribute(wt,K),d.fromBufferAttribute(wt,ot),p.fromBufferAttribute(wt,kt),(rt=t(rt,xt,gt,Ct,l,d,p,q))&&(Vt&&(L.fromBufferAttribute(Vt,K),B.fromBufferAttribute(Vt,ot),H.fromBufferAttribute(Vt,kt),rt.uv=Oe.getUV(q,l,d,p,L,B,H,new o)),Vt=new R(K,ot,kt),Oe.getNormal(l,d,p,Vt.normal),rt.face=Vt),rt}var i=new c,n=new Si,s=new I,l=new u,d=new u,p=new u,_=new u,T=new u,A=new u,L=new o,B=new o,H=new o,q=new u,$=new u;return function(rt,xt){var gt=this.geometry,Ct=this.material,wt=this.matrixWorld;if(Ct!==void 0&&(gt.boundingSphere===null&>.computeBoundingSphere(),s.copy(gt.boundingSphere),s.applyMatrix4(wt),rt.ray.intersectsSphere(s)!==!1&&(i.getInverse(wt),n.copy(rt.ray).applyMatrix4(i),gt.boundingBox===null||n.intersectsBox(gt.boundingBox)!==!1))){if(gt.isBufferGeometry){var Vt=gt.index,K=gt.attributes.position,ot=gt.attributes.uv,kt=gt.groups;gt=gt.drawRange;var ee;if(Vt!==null)if(Array.isArray(Ct)){var $t=0;for(ee=kt.length;$t<ee;$t++){var Yt=kt[$t],Te=Ct[Yt.materialIndex];wt=Math.max(Yt.start,gt.start);var ge=Math.min(Yt.start+Yt.count,gt.start+gt.count);for(Yt=wt;Yt<ge;Yt+=3){wt=Vt.getX(Yt);var De=Vt.getX(Yt+1),be=Vt.getX(Yt+2);(wt=e(this,Te,rt,n,K,ot,wt,De,be))&&(wt.faceIndex=Math.floor(Yt/3),xt.push(wt))}}}else for(wt=Math.max(0,gt.start),ge=Math.min(Vt.count,gt.start+gt.count),$t=wt,ee=ge;$t<ee;$t+=3)wt=Vt.getX($t),De=Vt.getX($t+1),be=Vt.getX($t+2),(wt=e(this,Ct,rt,n,K,ot,wt,De,be))&&(wt.faceIndex=Math.floor($t/3),xt.push(wt));else if(K!==void 0)if(Array.isArray(Ct))for($t=0,ee=kt.length;$t<ee;$t++)for(Yt=kt[$t],Te=Ct[Yt.materialIndex],wt=Math.max(Yt.start,gt.start),ge=Math.min(Yt.start+Yt.count,gt.start+gt.count),Yt=wt;Yt<ge;Yt+=3)wt=Yt,De=Yt+1,be=Yt+2,(wt=e(this,Te,rt,n,K,ot,wt,De,be))&&(wt.faceIndex=Math.floor(Yt/3),xt.push(wt));else for(wt=Math.max(0,gt.start),ge=Math.min(K.count,gt.start+gt.count),$t=wt,ee=ge;$t<ee;$t+=3)wt=$t,De=$t+1,be=$t+2,(wt=e(this,Ct,rt,n,K,ot,wt,De,be))&&(wt.faceIndex=Math.floor($t/3),xt.push(wt))}else if(gt.isGeometry){for(K=Array.isArray(Ct),ot=gt.vertices,kt=gt.faces,wt=gt.faceVertexUvs[0],0<wt.length&&(Vt=wt),Yt=0,ge=kt.length;Yt<ge;Yt++)if(De=kt[Yt],wt=K?Ct[De.materialIndex]:Ct,wt!==void 0){if($t=ot[De.a],ee=ot[De.b],Te=ot[De.c],wt.morphTargets===!0){be=gt.morphTargets;var ae=this.morphTargetInfluences;l.set(0,0,0),d.set(0,0,0),p.set(0,0,0);for(var We=0,Qe=be.length;We<Qe;We++){var fi=ae[We];if(fi!==0){var Cn=be[We].vertices;l.addScaledVector(_.subVectors(Cn[De.a],$t),fi),d.addScaledVector(T.subVectors(Cn[De.b],ee),fi),p.addScaledVector(A.subVectors(Cn[De.c],Te),fi)}}l.add($t),d.add(ee),p.add(Te),$t=l,ee=d,Te=p}(wt=t(this,wt,rt,n,$t,ee,Te,q))&&(Vt&&Vt[Yt]&&(be=Vt[Yt],L.copy(be[0]),B.copy(be[1]),H.copy(be[2]),wt.uv=Oe.getUV(q,$t,ee,Te,L,B,H,new o)),wt.face=De,wt.faceIndex=Yt,xt.push(wt))}}}}}(),clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}}),z.prototype=Object.create(g.prototype),z.prototype.constructor=z,z.prototype.isCubeTexture=!0,Object.defineProperty(z.prototype,"images",{get:function(){return this.image},set:function(t){this.image=t}}),Q.prototype=Object.create(g.prototype),Q.prototype.constructor=Q,Q.prototype.isDataTexture3D=!0;var qh=new g,Jc=new Q,ku=new z,ah=[],Ra=[],wl=new Float32Array(16),Bu=new Float32Array(9),Yh=new Float32Array(4);sa.prototype.updateCache=function(t){var e=this.cache;t instanceof Float32Array&&e.length!==t.length&&(this.cache=new Float32Array(t.length)),vt(e,t)},Ja.prototype.setValue=function(t,e,i){for(var n=this.seq,s=0,l=n.length;s!==l;++s){var d=n[s];d.setValue(t,e[d.id],i)}};var Zh=/([\w\d_]+)(\])?(\[|\.)?/g;ho.prototype.setValue=function(t,e,i){e=this.map[e],e!==void 0&&e.setValue(t,i,this.renderer)},ho.prototype.setOptional=function(t,e,i){e=e[i],e!==void 0&&this.setValue(t,i,e)},ho.upload=function(t,e,i,n){for(var s=0,l=e.length;s!==l;++s){var d=e[s],p=i[d.id];p.needsUpdate!==!1&&d.setValue(t,p.value,n)}},ho.seqWithValue=function(t,e){for(var i=[],n=0,s=t.length;n!==s;++n){var l=t[n];l.id in e&&i.push(l)}return i};var Bo=0,Jh=0;se.prototype=Object.create(Wt.prototype),se.prototype.constructor=se,se.prototype.isMeshDepthMaterial=!0,se.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.depthPacking=t.depthPacking,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.map=t.map,this.alphaMap=t.alphaMap,this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this},te.prototype=Object.create(Wt.prototype),te.prototype.constructor=te,te.prototype.isMeshDistanceMaterial=!0,te.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.referencePosition.copy(t.referencePosition),this.nearDistance=t.nearDistance,this.farDistance=t.farDistance,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.map=t.map,this.alphaMap=t.alphaMap,this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this},ci.prototype=Object.assign(Object.create(N.prototype),{constructor:ci,isGroup:!0}),Be.prototype=Object.assign(Object.create(N.prototype),{constructor:Be,isCamera:!0,copy:function(t,e){return N.prototype.copy.call(this,t,e),this.matrixWorldInverse.copy(t.matrixWorldInverse),this.projectionMatrix.copy(t.projectionMatrix),this.projectionMatrixInverse.copy(t.projectionMatrixInverse),this},getWorldDirection:function(t){t===void 0&&(t=new u),this.updateMatrixWorld(!0);var e=this.matrixWorld.elements;return t.set(-e[8],-e[9],-e[10]).normalize()},updateMatrixWorld:function(t){N.prototype.updateMatrixWorld.call(this,t),this.matrixWorldInverse.getInverse(this.matrixWorld)},clone:function(){return new this.constructor().copy(this)}}),_e.prototype=Object.assign(Object.create(Be.prototype),{constructor:_e,isPerspectiveCamera:!0,copy:function(t,e){return Be.prototype.copy.call(this,t,e),this.fov=t.fov,this.zoom=t.zoom,this.near=t.near,this.far=t.far,this.focus=t.focus,this.aspect=t.aspect,this.view=t.view===null?null:Object.assign({},t.view),this.filmGauge=t.filmGauge,this.filmOffset=t.filmOffset,this},setFocalLength:function(t){t=.5*this.getFilmHeight()/t,this.fov=2*di.RAD2DEG*Math.atan(t),this.updateProjectionMatrix()},getFocalLength:function(){var t=Math.tan(.5*di.DEG2RAD*this.fov);return .5*this.getFilmHeight()/t},getEffectiveFOV:function(){return 2*di.RAD2DEG*Math.atan(Math.tan(.5*di.DEG2RAD*this.fov)/this.zoom)},getFilmWidth:function(){return this.filmGauge*Math.min(this.aspect,1)},getFilmHeight:function(){return this.filmGauge/Math.max(this.aspect,1)},setViewOffset:function(t,e,i,n,s,l){this.aspect=t/e,this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=t,this.view.fullHeight=e,this.view.offsetX=i,this.view.offsetY=n,this.view.width=s,this.view.height=l,this.updateProjectionMatrix()},clearViewOffset:function(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()},updateProjectionMatrix:function(){var t=this.near,e=t*Math.tan(.5*di.DEG2RAD*this.fov)/this.zoom,i=2*e,n=this.aspect*i,s=-.5*n,l=this.view;if(this.view!==null&&this.view.enabled){var d=l.fullWidth,p=l.fullHeight;s+=l.offsetX*n/d,e-=l.offsetY*i/p,n*=l.width/d,i*=l.height/p}l=this.filmOffset,l!==0&&(s+=t*l/this.getFilmWidth()),this.projectionMatrix.makePerspective(s,s+n,e,e-i,t,this.far),this.projectionMatrixInverse.getInverse(this.projectionMatrix)},toJSON:function(t){return t=N.prototype.toJSON.call(this,t),t.object.fov=this.fov,t.object.zoom=this.zoom,t.object.near=this.near,t.object.far=this.far,t.object.focus=this.focus,t.object.aspect=this.aspect,this.view!==null&&(t.object.view=Object.assign({},this.view)),t.object.filmGauge=this.filmGauge,t.object.filmOffset=this.filmOffset,t}}),Fe.prototype=Object.assign(Object.create(_e.prototype),{constructor:Fe,isArrayCamera:!0});var ls=new u,wr=new u;Re.prototype.isFogExp2=!0,Re.prototype.clone=function(){return new Re(this.color,this.density)},Re.prototype.toJSON=function(){return{type:"FogExp2",color:this.color.getHex(),density:this.density}},Sn.prototype.isFog=!0,Sn.prototype.clone=function(){return new Sn(this.color,this.near,this.far)},Sn.prototype.toJSON=function(){return{type:"Fog",color:this.color.getHex(),near:this.near,far:this.far}},Xn.prototype=Object.assign(Object.create(N.prototype),{constructor:Xn,copy:function(t,e){return N.prototype.copy.call(this,t,e),t.background!==null&&(this.background=t.background.clone()),t.fog!==null&&(this.fog=t.fog.clone()),t.overrideMaterial!==null&&(this.overrideMaterial=t.overrideMaterial.clone()),this.autoUpdate=t.autoUpdate,this.matrixAutoUpdate=t.matrixAutoUpdate,this},toJSON:function(t){var e=N.prototype.toJSON.call(this,t);return this.background!==null&&(e.object.background=this.background.toJSON(t)),this.fog!==null&&(e.object.fog=this.fog.toJSON()),e}}),Object.defineProperty(ki.prototype,"needsUpdate",{set:function(t){t===!0&&this.version++}}),Object.assign(ki.prototype,{isInterleavedBuffer:!0,onUploadCallback:function(){},setArray:function(t){if(Array.isArray(t))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");return this.count=t!==void 0?t.length/this.stride:0,this.array=t,this},setDynamic:function(t){return this.dynamic=t,this},copy:function(t){return this.array=new t.array.constructor(t.array),this.count=t.count,this.stride=t.stride,this.dynamic=t.dynamic,this},copyAt:function(t,e,i){t*=this.stride,i*=e.stride;for(var n=0,s=this.stride;n<s;n++)this.array[t+n]=e.array[i+n];return this},set:function(t,e){return e===void 0&&(e=0),this.array.set(t,e),this},clone:function(){return new this.constructor().copy(this)},onUpload:function(t){return this.onUploadCallback=t,this}}),Object.defineProperties(Bi.prototype,{count:{get:function(){return this.data.count}},array:{get:function(){return this.data.array}}}),Object.assign(Bi.prototype,{isInterleavedBufferAttribute:!0,setX:function(t,e){return this.data.array[t*this.data.stride+this.offset]=e,this},setY:function(t,e){return this.data.array[t*this.data.stride+this.offset+1]=e,this},setZ:function(t,e){return this.data.array[t*this.data.stride+this.offset+2]=e,this},setW:function(t,e){return this.data.array[t*this.data.stride+this.offset+3]=e,this},getX:function(t){return this.data.array[t*this.data.stride+this.offset]},getY:function(t){return this.data.array[t*this.data.stride+this.offset+1]},getZ:function(t){return this.data.array[t*this.data.stride+this.offset+2]},getW:function(t){return this.data.array[t*this.data.stride+this.offset+3]},setXY:function(t,e,i){return t=t*this.data.stride+this.offset,this.data.array[t+0]=e,this.data.array[t+1]=i,this},setXYZ:function(t,e,i,n){return t=t*this.data.stride+this.offset,this.data.array[t+0]=e,this.data.array[t+1]=i,this.data.array[t+2]=n,this},setXYZW:function(t,e,i,n,s){return t=t*this.data.stride+this.offset,this.data.array[t+0]=e,this.data.array[t+1]=i,this.data.array[t+2]=n,this.data.array[t+3]=s,this}}),Hi.prototype=Object.create(Wt.prototype),Hi.prototype.constructor=Hi,Hi.prototype.isSpriteMaterial=!0,Hi.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.rotation=t.rotation,this.sizeAttenuation=t.sizeAttenuation,this};var Oa;nn.prototype=Object.assign(Object.create(N.prototype),{constructor:nn,isSprite:!0,raycast:function(){function t(H,q,$,rt,xt,gt){s.subVectors(H,$).addScalar(.5).multiply(rt),xt!==void 0?(l.x=gt*s.x-xt*s.y,l.y=xt*s.x+gt*s.y):l.copy(s),H.copy(q),H.x+=l.x,H.y+=l.y,H.applyMatrix4(d)}var e=new u,i=new u,n=new u,s=new o,l=new o,d=new c,p=new u,_=new u,T=new u,A=new o,L=new o,B=new o;return function(H,q){i.setFromMatrixScale(this.matrixWorld),d.getInverse(this.modelViewMatrix).premultiply(this.matrixWorld),n.setFromMatrixPosition(this.modelViewMatrix);var $=this.material.rotation;if($!==0)var rt=Math.cos($),xt=Math.sin($);$=this.center,t(p.set(-.5,-.5,0),n,$,i,xt,rt),t(_.set(.5,-.5,0),n,$,i,xt,rt),t(T.set(.5,.5,0),n,$,i,xt,rt),A.set(0,0),L.set(1,0),B.set(1,1);var gt=H.ray.intersectTriangle(p,_,T,!1,e);gt===null&&(t(_.set(-.5,.5,0),n,$,i,xt,rt),L.set(0,1),gt=H.ray.intersectTriangle(p,T,_,!1,e),gt===null)||(xt=H.ray.origin.distanceTo(e),xt<H.near||xt>H.far||q.push({distance:xt,point:e.clone(),uv:Oe.getUV(e,p,_,T,A,L,B,new o),face:null,object:this}))}}(),clone:function(){return new this.constructor(this.material).copy(this)},copy:function(t){return N.prototype.copy.call(this,t),t.center!==void 0&&this.center.copy(t.center),this}}),rn.prototype=Object.assign(Object.create(N.prototype),{constructor:rn,copy:function(t){N.prototype.copy.call(this,t,!1),t=t.levels;for(var e=0,i=t.length;e<i;e++){var n=t[e];this.addLevel(n.object.clone(),n.distance)}return this},addLevel:function(t,e){e===void 0&&(e=0),e=Math.abs(e);for(var i=this.levels,n=0;n<i.length&&!(e<i[n].distance);n++);i.splice(n,0,{distance:e,object:t}),this.add(t)},getObjectForDistance:function(t){for(var e=this.levels,i=1,n=e.length;i<n&&!(t<e[i].distance);i++);return e[i-1].object},raycast:function(){var t=new u;return function(e,i){t.setFromMatrixPosition(this.matrixWorld);var n=e.ray.origin.distanceTo(t);this.getObjectForDistance(n).raycast(e,i)}}(),update:function(){var t=new u,e=new u;return function(i){var n=this.levels;if(1<n.length){t.setFromMatrixPosition(i.matrixWorld),e.setFromMatrixPosition(this.matrixWorld),i=t.distanceTo(e),n[0].object.visible=!0;for(var s=1,l=n.length;s<l&&i>=n[s].distance;s++)n[s-1].object.visible=!1,n[s].object.visible=!0;for(;s<l;s++)n[s].object.visible=!1}}}(),toJSON:function(t){t=N.prototype.toJSON.call(this,t),t.object.levels=[];for(var e=this.levels,i=0,n=e.length;i<n;i++){var s=e[i];t.object.levels.push({object:s.object.uuid,distance:s.distance})}return t}}),Object.assign(un.prototype,{calculateInverses:function(){this.boneInverses=[];for(var t=0,e=this.bones.length;t<e;t++){var i=new c;this.bones[t]&&i.getInverse(this.bones[t].matrixWorld),this.boneInverses.push(i)}},pose:function(){var t,e,i=0;for(e=this.bones.length;i<e;i++)(t=this.bones[i])&&t.matrixWorld.getInverse(this.boneInverses[i]);for(i=0,e=this.bones.length;i<e;i++)(t=this.bones[i])&&(t.parent&&t.parent.isBone?(t.matrix.getInverse(t.parent.matrixWorld),t.matrix.multiply(t.matrixWorld)):t.matrix.copy(t.matrixWorld),t.matrix.decompose(t.position,t.quaternion,t.scale))},update:function(){var t=new c,e=new c;return function(){for(var i=this.bones,n=this.boneInverses,s=this.boneMatrices,l=this.boneTexture,d=0,p=i.length;d<p;d++)t.multiplyMatrices(i[d]?i[d].matrixWorld:e,n[d]),t.toArray(s,16*d);l!==void 0&&(l.needsUpdate=!0)}}(),clone:function(){return new un(this.bones,this.boneInverses)},getBoneByName:function(t){for(var e=0,i=this.bones.length;e<i;e++){var n=this.bones[e];if(n.name===t)return n}}}),cn.prototype=Object.assign(Object.create(N.prototype),{constructor:cn,isBone:!0}),Gi.prototype=Object.assign(Object.create(pi.prototype),{constructor:Gi,isSkinnedMesh:!0,initBones:function(){var t=[],e;if(this.geometry&&this.geometry.bones!==void 0){var i=0;for(e=this.geometry.bones.length;i<e;i++){var n=this.geometry.bones[i],s=new cn;t.push(s),s.name=n.name,s.position.fromArray(n.pos),s.quaternion.fromArray(n.rotq),n.scl!==void 0&&s.scale.fromArray(n.scl)}for(i=0,e=this.geometry.bones.length;i<e;i++)n=this.geometry.bones[i],n.parent!==-1&&n.parent!==null&&t[n.parent]!==void 0?t[n.parent].add(t[i]):this.add(t[i])}return this.updateMatrixWorld(!0),t},bind:function(t,e){this.skeleton=t,e===void 0&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),e=this.matrixWorld),this.bindMatrix.copy(e),this.bindMatrixInverse.getInverse(e)},pose:function(){this.skeleton.pose()},normalizeSkinWeights:function(){var t;if(this.geometry&&this.geometry.isGeometry)for(t=0;t<this.geometry.skinWeights.length;t++){var e=this.geometry.skinWeights[t],i=1/e.manhattanLength();i!==1/0?e.multiplyScalar(i):e.set(1,0,0,0)}else if(this.geometry&&this.geometry.isBufferGeometry){e=new v;var n=this.geometry.attributes.skinWeight;for(t=0;t<n.count;t++)e.x=n.getX(t),e.y=n.getY(t),e.z=n.getZ(t),e.w=n.getW(t),i=1/e.manhattanLength(),i!==1/0?e.multiplyScalar(i):e.set(1,0,0,0),n.setXYZW(t,e.x,e.y,e.z,e.w)}},updateMatrixWorld:function(t){pi.prototype.updateMatrixWorld.call(this,t),this.bindMode==="attached"?this.bindMatrixInverse.getInverse(this.matrixWorld):this.bindMode==="detached"&&this.bindMatrixInverse.getInverse(this.bindMatrix)},clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}}),Ni.prototype=Object.create(Wt.prototype),Ni.prototype.constructor=Ni,Ni.prototype.isLineBasicMaterial=!0,Ni.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.linewidth=t.linewidth,this.linecap=t.linecap,this.linejoin=t.linejoin,this},ji.prototype=Object.assign(Object.create(N.prototype),{constructor:ji,isLine:!0,computeLineDistances:function(){var t=new u,e=new u;return function(){var i=this.geometry;if(i.isBufferGeometry){if(i.index===null){for(var n=i.attributes.position,s=[0],l=1,d=n.count;l<d;l++)t.fromBufferAttribute(n,l-1),e.fromBufferAttribute(n,l),s[l]=s[l-1],s[l]+=t.distanceTo(e);i.addAttribute("lineDistance",new Et(s,1))}}else if(i.isGeometry)for(n=i.vertices,s=i.lineDistances,s[0]=0,l=1,d=n.length;l<d;l++)s[l]=s[l-1],s[l]+=n[l-1].distanceTo(n[l]);return this}}(),raycast:function(){var t=new c,e=new Si,i=new I;return function(n,s){var l=n.linePrecision,d=this.geometry,p=this.matrixWorld;if(d.boundingSphere===null&&d.computeBoundingSphere(),i.copy(d.boundingSphere),i.applyMatrix4(p),i.radius+=l,n.ray.intersectsSphere(i)!==!1){t.getInverse(p),e.copy(n.ray).applyMatrix4(t),l/=(this.scale.x+this.scale.y+this.scale.z)/3,l*=l;var _=new u,T=new u;p=new u;var A=new u,L=this&&this.isLineSegments?2:1;if(d.isBufferGeometry){var B=d.index,H=d.attributes.position.array;if(B!==null){B=B.array,d=0;for(var q=B.length-1;d<q;d+=L){var $=B[d+1];_.fromArray(H,3*B[d]),T.fromArray(H,3*$),$=e.distanceSqToSegment(_,T,A,p),$>l||(A.applyMatrix4(this.matrixWorld),$=n.ray.origin.distanceTo(A),$<n.near||$>n.far||s.push({distance:$,point:p.clone().applyMatrix4(this.matrixWorld),index:d,face:null,faceIndex:null,object:this}))}}else for(d=0,q=H.length/3-1;d<q;d+=L)_.fromArray(H,3*d),T.fromArray(H,3*d+3),$=e.distanceSqToSegment(_,T,A,p),$>l||(A.applyMatrix4(this.matrixWorld),$=n.ray.origin.distanceTo(A),$<n.near||$>n.far||s.push({distance:$,point:p.clone().applyMatrix4(this.matrixWorld),index:d,face:null,faceIndex:null,object:this}))}else if(d.isGeometry)for(_=d.vertices,T=_.length,d=0;d<T-1;d+=L)$=e.distanceSqToSegment(_[d],_[d+1],A,p),$>l||(A.applyMatrix4(this.matrixWorld),$=n.ray.origin.distanceTo(A),$<n.near||$>n.far||s.push({distance:$,point:p.clone().applyMatrix4(this.matrixWorld),index:d,face:null,faceIndex:null,object:this}))}}}(),copy:function(t){return N.prototype.copy.call(this,t),this.geometry.copy(t.geometry),this.material.copy(t.material),this},clone:function(){return new this.constructor().copy(this)}}),gi.prototype=Object.assign(Object.create(ji.prototype),{constructor:gi,isLineSegments:!0,computeLineDistances:function(){var t=new u,e=new u;return function(){var i=this.geometry;if(i.isBufferGeometry){if(i.index===null){for(var n=i.attributes.position,s=[],l=0,d=n.count;l<d;l+=2)t.fromBufferAttribute(n,l),e.fromBufferAttribute(n,l+1),s[l]=l===0?0:s[l-1],s[l+1]=s[l]+t.distanceTo(e);i.addAttribute("lineDistance",new Et(s,1))}}else if(i.isGeometry)for(n=i.vertices,s=i.lineDistances,l=0,d=n.length;l<d;l+=2)t.copy(n[l]),e.copy(n[l+1]),s[l]=l===0?0:s[l-1],s[l+1]=s[l]+t.distanceTo(e);return this}}()}),co.prototype=Object.assign(Object.create(ji.prototype),{constructor:co,isLineLoop:!0}),Fn.prototype=Object.create(Wt.prototype),Fn.prototype.constructor=Fn,Fn.prototype.isPointsMaterial=!0,Fn.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.size=t.size,this.sizeAttenuation=t.sizeAttenuation,this.morphTargets=t.morphTargets,this},ha.prototype=Object.assign(Object.create(N.prototype),{constructor:ha,isPoints:!0,raycast:function(){var t=new c,e=new Si,i=new I;return function(n,s){function l(rt,xt){var gt=e.distanceSqToPoint(rt);gt<A&&(e.closestPointToPoint(rt,L),L.applyMatrix4(_),rt=n.ray.origin.distanceTo(L),rt<n.near||rt>n.far||s.push({distance:rt,distanceToRay:Math.sqrt(gt),point:L.clone(),index:xt,face:null,object:d}))}var d=this,p=this.geometry,_=this.matrixWorld,T=n.params.Points.threshold;if(p.boundingSphere===null&&p.computeBoundingSphere(),i.copy(p.boundingSphere),i.applyMatrix4(_),i.radius+=T,n.ray.intersectsSphere(i)!==!1){t.getInverse(_),e.copy(n.ray).applyMatrix4(t),T/=(this.scale.x+this.scale.y+this.scale.z)/3;var A=T*T;T=new u;var L=new u;if(p.isBufferGeometry){var B=p.index;if(p=p.attributes.position.array,B!==null){var H=B.array;B=0;for(var q=H.length;B<q;B++){var $=H[B];T.fromArray(p,3*$),l(T,$)}}else for(B=0,H=p.length/3;B<H;B++)T.fromArray(p,3*B),l(T,B)}else for(T=p.vertices,B=0,H=T.length;B<H;B++)l(T[B],B)}}}(),clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}}),zh.prototype=Object.assign(Object.create(g.prototype),{constructor:zh,isVideoTexture:!0,update:function(){var t=this.image;t.readyState>=t.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}}),Zo.prototype=Object.create(g.prototype),Zo.prototype.constructor=Zo,Zo.prototype.isCompressedTexture=!0,$a.prototype=Object.create(g.prototype),$a.prototype.constructor=$a,$a.prototype.isCanvasTexture=!0,Ka.prototype=Object.create(g.prototype),Ka.prototype.constructor=Ka,Ka.prototype.isDepthTexture=!0,ua.prototype=Object.create(Ft.prototype),ua.prototype.constructor=ua,Qa.prototype=Object.create(X.prototype),Qa.prototype.constructor=Qa,ca.prototype=Object.create(Ft.prototype),ca.prototype.constructor=ca,Xi.prototype=Object.create(X.prototype),Xi.prototype.constructor=Xi,xi.prototype=Object.create(Ft.prototype),xi.prototype.constructor=xi,tl.prototype=Object.create(X.prototype),tl.prototype.constructor=tl,fa.prototype=Object.create(xi.prototype),fa.prototype.constructor=fa,el.prototype=Object.create(X.prototype),el.prototype.constructor=el,xs.prototype=Object.create(xi.prototype),xs.prototype.constructor=xs,il.prototype=Object.create(X.prototype),il.prototype.constructor=il,da.prototype=Object.create(xi.prototype),da.prototype.constructor=da,pa.prototype=Object.create(X.prototype),pa.prototype.constructor=pa,ma.prototype=Object.create(xi.prototype),ma.prototype.constructor=ma,gn.prototype=Object.create(X.prototype),gn.prototype.constructor=gn,Jo.prototype=Object.create(Ft.prototype),Jo.prototype.constructor=Jo,Zr.prototype=Object.create(X.prototype),Zr.prototype.constructor=Zr,ws.prototype=Object.create(Ft.prototype),ws.prototype.constructor=ws,Ts.prototype=Object.create(X.prototype),Ts.prototype.constructor=Ts,Un.prototype=Object.create(Ft.prototype),Un.prototype.constructor=Un;var Nu={triangulate:function(t,e,i){i=i||2;var n=e&&e.length,s=n?e[0]*i:t.length,l=kh(t,0,s,i,!0),d=[];if(!l)return d;var p;if(n){var _=i;n=[];var T,A=0;for(T=e.length;A<T;A++){var L=e[A]*_,B=A<T-1?e[A+1]*_:t.length;L=kh(t,L,B,_,!1),L===L.next&&(L.steiner=!0),n.push(yr(L))}for(n.sort(Su),A=0;A<n.length;A++)e=n[A],_=l,(_=Eu(e,_))&&(e=nl(_,e),ga(e,e.next)),l=ga(l,l.next)}if(t.length>80*i){var H=p=t[0],q=n=t[1];for(_=i;_<s;_+=i)A=t[_],e=t[_+1],A<H&&(H=A),e<q&&(q=e),A>p&&(p=A),e>n&&(n=e);p=Math.max(p-H,n-q),p=p!==0?1/p:0}return va(l,d,i,H,q,p),d}},To={area:function(t){for(var e=t.length,i=0,n=e-1,s=0;s<e;n=s++)i+=t[n].x*t[s].y-t[s].x*t[n].y;return .5*i},isClockWise:function(t){return 0>To.area(t)},triangulateShape:function(t,e){var i=[],n=[],s=[];$l(t),bu(i,t);var l=t.length;for(e.forEach($l),t=0;t<e.length;t++)n.push(l),l+=e[t].length,bu(i,e[t]);for(e=Nu.triangulate(i,n),t=0;t<e.length;t+=3)s.push(e.slice(t,t+3));return s}};Po.prototype=Object.create(X.prototype),Po.prototype.constructor=Po,Po.prototype.toJSON=function(){var t=X.prototype.toJSON.call(this);return Cu(this.parameters.shapes,this.parameters.options,t)},po.prototype=Object.create(Ft.prototype),po.prototype.constructor=po,po.prototype.toJSON=function(){var t=Ft.prototype.toJSON.call(this);return Cu(this.parameters.shapes,this.parameters.options,t)};var Tl={generateTopUV:function(t,e,i,n,s){t=e[3*n],n=e[3*n+1];var l=e[3*s];return s=e[3*s+1],[new o(e[3*i],e[3*i+1]),new o(t,n),new o(l,s)]},generateSideWallUV:function(t,e,i,n,s,l){t=e[3*i];var d=e[3*i+1];i=e[3*i+2];var p=e[3*n],_=e[3*n+1];n=e[3*n+2];var T=e[3*s],A=e[3*s+1];s=e[3*s+2];var L=e[3*l],B=e[3*l+1];return e=e[3*l+2],.01>Math.abs(d-_)?[new o(t,1-i),new o(p,1-n),new o(T,1-s),new o(L,1-e)]:[new o(d,1-i),new o(_,1-n),new o(A,1-s),new o(B,1-e)]}};rl.prototype=Object.create(X.prototype),rl.prototype.constructor=rl,Ss.prototype=Object.create(po.prototype),Ss.prototype.constructor=Ss,$o.prototype=Object.create(X.prototype),$o.prototype.constructor=$o,Or.prototype=Object.create(Ft.prototype),Or.prototype.constructor=Or,ol.prototype=Object.create(X.prototype),ol.prototype.constructor=ol,Es.prototype=Object.create(Ft.prototype),Es.prototype.constructor=Es,ya.prototype=Object.create(X.prototype),ya.prototype.constructor=ya,Ko.prototype=Object.create(Ft.prototype),Ko.prototype.constructor=Ko,Lo.prototype=Object.create(X.prototype),Lo.prototype.constructor=Lo,Lo.prototype.toJSON=function(){var t=X.prototype.toJSON.call(this);return Au(this.parameters.shapes,t)},Qo.prototype=Object.create(Ft.prototype),Qo.prototype.constructor=Qo,Qo.prototype.toJSON=function(){var t=Ft.prototype.toJSON.call(this);return Au(this.parameters.shapes,t)},ts.prototype=Object.create(Ft.prototype),ts.prototype.constructor=ts,Ro.prototype=Object.create(X.prototype),Ro.prototype.constructor=Ro,Oo.prototype=Object.create(Ft.prototype),Oo.prototype.constructor=Oo,_a.prototype=Object.create(Ro.prototype),_a.prototype.constructor=_a,Gn.prototype=Object.create(Oo.prototype),Gn.prototype.constructor=Gn,bs.prototype=Object.create(X.prototype),bs.prototype.constructor=bs,mo.prototype=Object.create(Ft.prototype),mo.prototype.constructor=mo;var yn=Object.freeze({WireframeGeometry:ua,ParametricGeometry:Qa,ParametricBufferGeometry:ca,TetrahedronGeometry:tl,TetrahedronBufferGeometry:fa,OctahedronGeometry:el,OctahedronBufferGeometry:xs,IcosahedronGeometry:il,IcosahedronBufferGeometry:da,DodecahedronGeometry:pa,DodecahedronBufferGeometry:ma,PolyhedronGeometry:Xi,PolyhedronBufferGeometry:xi,TubeGeometry:gn,TubeBufferGeometry:Jo,TorusKnotGeometry:Zr,TorusKnotBufferGeometry:ws,TorusGeometry:Ts,TorusBufferGeometry:Un,TextGeometry:rl,TextBufferGeometry:Ss,SphereGeometry:$o,SphereBufferGeometry:Or,RingGeometry:ol,RingBufferGeometry:Es,PlaneGeometry:Pe,PlaneBufferGeometry:pe,LatheGeometry:ya,LatheBufferGeometry:Ko,ShapeGeometry:Lo,ShapeBufferGeometry:Qo,ExtrudeGeometry:Po,ExtrudeBufferGeometry:po,EdgesGeometry:ts,ConeGeometry:_a,ConeBufferGeometry:Gn,CylinderGeometry:Ro,CylinderBufferGeometry:Oo,CircleGeometry:bs,CircleBufferGeometry:mo,BoxGeometry:It,BoxBufferGeometry:Nt});es.prototype=Object.create(Wt.prototype),es.prototype.constructor=es,es.prototype.isShadowMaterial=!0,es.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this},Cs.prototype=Object.create($e.prototype),Cs.prototype.constructor=Cs,Cs.prototype.isRawShaderMaterial=!0,go.prototype=Object.create(Wt.prototype),go.prototype.constructor=go,go.prototype.isMeshStandardMaterial=!0,go.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.defines={STANDARD:""},this.color.copy(t.color),this.roughness=t.roughness,this.metalness=t.metalness,this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.emissive.copy(t.emissive),this.emissiveMap=t.emissiveMap,this.emissiveIntensity=t.emissiveIntensity,this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.roughnessMap=t.roughnessMap,this.metalnessMap=t.metalnessMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.envMapIntensity=t.envMapIntensity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},As.prototype=Object.create(go.prototype),As.prototype.constructor=As,As.prototype.isMeshPhysicalMaterial=!0,As.prototype.copy=function(t){return go.prototype.copy.call(this,t),this.defines={PHYSICAL:""},this.reflectivity=t.reflectivity,this.clearCoat=t.clearCoat,this.clearCoatRoughness=t.clearCoatRoughness,this},Jr.prototype=Object.create(Wt.prototype),Jr.prototype.constructor=Jr,Jr.prototype.isMeshPhongMaterial=!0,Jr.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.specular.copy(t.specular),this.shininess=t.shininess,this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.emissive.copy(t.emissive),this.emissiveMap=t.emissiveMap,this.emissiveIntensity=t.emissiveIntensity,this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.specularMap=t.specularMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.combine=t.combine,this.reflectivity=t.reflectivity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Ps.prototype=Object.create(Jr.prototype),Ps.prototype.constructor=Ps,Ps.prototype.isMeshToonMaterial=!0,Ps.prototype.copy=function(t){return Jr.prototype.copy.call(this,t),this.gradientMap=t.gradientMap,this},Ls.prototype=Object.create(Wt.prototype),Ls.prototype.constructor=Ls,Ls.prototype.isMeshNormalMaterial=!0,Ls.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Ir.prototype=Object.create(Wt.prototype),Ir.prototype.constructor=Ir,Ir.prototype.isMeshLambertMaterial=!0,Ir.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.color.copy(t.color),this.map=t.map,this.lightMap=t.lightMap,this.lightMapIntensity=t.lightMapIntensity,this.aoMap=t.aoMap,this.aoMapIntensity=t.aoMapIntensity,this.emissive.copy(t.emissive),this.emissiveMap=t.emissiveMap,this.emissiveIntensity=t.emissiveIntensity,this.specularMap=t.specularMap,this.alphaMap=t.alphaMap,this.envMap=t.envMap,this.combine=t.combine,this.reflectivity=t.reflectivity,this.refractionRatio=t.refractionRatio,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this.wireframeLinecap=t.wireframeLinecap,this.wireframeLinejoin=t.wireframeLinejoin,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Rs.prototype=Object.create(Wt.prototype),Rs.prototype.constructor=Rs,Rs.prototype.isMeshMatcapMaterial=!0,Rs.prototype.copy=function(t){return Wt.prototype.copy.call(this,t),this.defines={MATCAP:""},this.color.copy(t.color),this.matcap=t.matcap,this.map=t.map,this.bumpMap=t.bumpMap,this.bumpScale=t.bumpScale,this.normalMap=t.normalMap,this.normalMapType=t.normalMapType,this.normalScale.copy(t.normalScale),this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.alphaMap=t.alphaMap,this.skinning=t.skinning,this.morphTargets=t.morphTargets,this.morphNormals=t.morphNormals,this},Os.prototype=Object.create(Ni.prototype),Os.prototype.constructor=Os,Os.prototype.isLineDashedMaterial=!0,Os.prototype.copy=function(t){return Ni.prototype.copy.call(this,t),this.scale=t.scale,this.dashSize=t.dashSize,this.gapSize=t.gapSize,this};var Fu=Object.freeze({ShadowMaterial:es,SpriteMaterial:Hi,RawShaderMaterial:Cs,ShaderMaterial:$e,PointsMaterial:Fn,MeshPhysicalMaterial:As,MeshStandardMaterial:go,MeshPhongMaterial:Jr,MeshToonMaterial:Ps,MeshNormalMaterial:Ls,MeshLambertMaterial:Ir,MeshDepthMaterial:se,MeshDistanceMaterial:te,MeshBasicMaterial:Ge,MeshMatcapMaterial:Rs,LineDashedMaterial:Os,LineBasicMaterial:Ni,Material:Wt}),Yn={arraySlice:function(t,e,i){return Yn.isTypedArray(t)?new t.constructor(t.subarray(e,i!==void 0?i:t.length)):t.slice(e,i)},convertArray:function(t,e,i){return!t||!i&&t.constructor===e?t:typeof e.BYTES_PER_ELEMENT=="number"?new e(t):Array.prototype.slice.call(t)},isTypedArray:function(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)},getKeyframeOrder:function(t){for(var e=t.length,i=Array(e),n=0;n!==e;++n)i[n]=n;return i.sort(function(s,l){return t[s]-t[l]}),i},sortedArray:function(t,e,i){for(var n=t.length,s=new t.constructor(n),l=0,d=0;d!==n;++l)for(var p=i[l]*e,_=0;_!==e;++_)s[d++]=t[p+_];return s},flattenJSON:function(t,e,i,n){for(var s=1,l=t[0];l!==void 0&&l[n]===void 0;)l=t[s++];if(l!==void 0){var d=l[n];if(d!==void 0)if(Array.isArray(d))do d=l[n],d!==void 0&&(e.push(l.time),i.push.apply(i,d)),l=t[s++];while(l!==void 0);else if(d.toArray!==void 0)do d=l[n],d!==void 0&&(e.push(l.time),d.toArray(i,i.length)),l=t[s++];while(l!==void 0);else do d=l[n],d!==void 0&&(e.push(l.time),i.push(d)),l=t[s++];while(l!==void 0)}}};Object.assign($n.prototype,{evaluate:function(t){var e=this.parameterPositions,i=this._cachedIndex,n=e[i],s=e[i-1];t:{e:{i:{n:if(!(t<n)){for(var l=i+2;;){if(n===void 0){if(t<s)break n;return this._cachedIndex=i=e.length,this.afterEnd_(i-1,t,s)}if(i===l)break;if(s=n,n=e[++i],t<n)break e}n=e.length;break i}if(t>=s)break t;for(l=e[1],t<l&&(i=2,s=l),l=i-2;;){if(s===void 0)return this._cachedIndex=0,this.beforeStart_(0,t,n);if(i===l)break;if(n=s,s=e[--i-1],t>=s)break e}n=i,i=0}for(;i<n;)s=i+n>>>1,t<e[s]?n=s:i=s+1;if(n=e[i],s=e[i-1],s===void 0)return this._cachedIndex=0,this.beforeStart_(0,t,n);if(n===void 0)return this._cachedIndex=i=e.length,this.afterEnd_(i-1,s,t)}this._cachedIndex=i,this.intervalChanged_(i,s,n)}return this.interpolate_(i,s,t,n)},settings:null,DefaultSettings_:{},getSettings_:function(){return this.settings||this.DefaultSettings_},copySampleValue_:function(t){var e=this.resultBuffer,i=this.sampleValues,n=this.valueSize;t*=n;for(var s=0;s!==n;++s)e[s]=i[t+s];return e},interpolate_:function(){throw Error("call to abstract method")},intervalChanged_:function(){}}),Object.assign($n.prototype,{beforeStart_:$n.prototype.copySampleValue_,afterEnd_:$n.prototype.copySampleValue_}),sl.prototype=Object.assign(Object.create($n.prototype),{constructor:sl,DefaultSettings_:{endingStart:2400,endingEnd:2400},intervalChanged_:function(t,e,i){var n=this.parameterPositions,s=t-2,l=t+1,d=n[s],p=n[l];if(d===void 0)switch(this.getSettings_().endingStart){case 2401:s=t,d=2*e-i;break;case 2402:s=n.length-2,d=e+n[s]-n[s+1];break;default:s=t,d=i}if(p===void 0)switch(this.getSettings_().endingEnd){case 2401:l=t,p=2*i-e;break;case 2402:l=1,p=i+n[1]-n[0];break;default:l=t-1,p=e}t=.5*(i-e),n=this.valueSize,this._weightPrev=t/(e-d),this._weightNext=t/(p-i),this._offsetPrev=s*n,this._offsetNext=l*n},interpolate_:function(t,e,i,n){var s=this.resultBuffer,l=this.sampleValues,d=this.valueSize;t*=d;var p=t-d,_=this._offsetPrev,T=this._offsetNext,A=this._weightPrev,L=this._weightNext,B=(i-e)/(n-e);for(i=B*B,n=i*B,e=-A*n+2*A*i-A*B,A=(1+A)*n+(-1.5-2*A)*i+(-.5+A)*B+1,B=(-1-L)*n+(1.5+L)*i+.5*B,L=L*n-L*i,i=0;i!==d;++i)s[i]=e*l[_+i]+A*l[p+i]+B*l[t+i]+L*l[T+i];return s}}),Dr.prototype=Object.assign(Object.create($n.prototype),{constructor:Dr,interpolate_:function(t,e,i,n){var s=this.resultBuffer,l=this.sampleValues,d=this.valueSize;t*=d;var p=t-d;for(e=(i-e)/(n-e),i=1-e,n=0;n!==d;++n)s[n]=l[p+n]*i+l[t+n]*e;return s}}),Is.prototype=Object.assign(Object.create($n.prototype),{constructor:Is,interpolate_:function(t){return this.copySampleValue_(t-1)}}),Object.assign(Hn,{toJSON:function(t){var e=t.constructor;if(e.toJSON!==void 0)e=e.toJSON(t);else{e={name:t.name,times:Yn.convertArray(t.times,Array),values:Yn.convertArray(t.values,Array)};var i=t.getInterpolation();i!==t.DefaultInterpolation&&(e.interpolation=i)}return e.type=t.ValueTypeName,e}}),Object.assign(Hn.prototype,{constructor:Hn,TimeBufferType:Float32Array,ValueBufferType:Float32Array,DefaultInterpolation:2301,InterpolantFactoryMethodDiscrete:function(t){return new Is(this.times,this.values,this.getValueSize(),t)},InterpolantFactoryMethodLinear:function(t){return new Dr(this.times,this.values,this.getValueSize(),t)},InterpolantFactoryMethodSmooth:function(t){return new sl(this.times,this.values,this.getValueSize(),t)},setInterpolation:function(t){switch(t){case 2300:var e=this.InterpolantFactoryMethodDiscrete;break;case 2301:e=this.InterpolantFactoryMethodLinear;break;case 2302:e=this.InterpolantFactoryMethodSmooth}if(e===void 0){if(e="unsupported interpolation for "+this.ValueTypeName+" keyframe track named "+this.name,this.createInterpolant===void 0)if(t!==this.DefaultInterpolation)this.setInterpolation(this.DefaultInterpolation);else throw Error(e);return this}return this.createInterpolant=e,this},getInterpolation:function(){switch(this.createInterpolant){case this.InterpolantFactoryMethodDiscrete:return 2300;case this.InterpolantFactoryMethodLinear:return 2301;case this.InterpolantFactoryMethodSmooth:return 2302}},getValueSize:function(){return this.values.length/this.times.length},shift:function(t){if(t!==0)for(var e=this.times,i=0,n=e.length;i!==n;++i)e[i]+=t;return this},scale:function(t){if(t!==1)for(var e=this.times,i=0,n=e.length;i!==n;++i)e[i]*=t;return this},trim:function(t,e){for(var i=this.times,n=i.length,s=0,l=n-1;s!==n&&i[s]<t;)++s;for(;l!==-1&&i[l]>e;)--l;return++l,(s!==0||l!==n)&&(s>=l&&(l=Math.max(l,1),s=l-1),t=this.getValueSize(),this.times=Yn.arraySlice(i,s,l),this.values=Yn.arraySlice(this.values,s*t,l*t)),this},validate:function(){var t=!0,e=this.getValueSize();e-Math.floor(e)!==0&&(t=!1);var i=this.times;e=this.values;var n=i.length;n===0&&(t=!1);for(var s=null,l=0;l!==n;l++){var d=i[l];if(typeof d=="number"&&isNaN(d)){t=!1;break}if(s!==null&&s>d){t=!1;break}s=d}if(e!==void 0&&Yn.isTypedArray(e)){for(l=0,i=e.length;l!==i;++l)if(n=e[l],isNaN(n)){t=!1;break}}return t},optimize:function(){for(var t=this.times,e=this.values,i=this.getValueSize(),n=this.getInterpolation()===2302,s=1,l=t.length-1,d=1;d<l;++d){var p=!1,_=t[d];if(_!==t[d+1]&&(d!==1||_!==_[0]))if(n)p=!0;else{var T=d*i,A=T-i,L=T+i;for(_=0;_!==i;++_){var B=e[T+_];if(B!==e[A+_]||B!==e[L+_]){p=!0;break}}}if(p){if(d!==s)for(t[s]=t[d],p=d*i,T=s*i,_=0;_!==i;++_)e[T+_]=e[p+_];++s}}if(0<l){for(t[s]=t[l],p=l*i,T=s*i,_=0;_!==i;++_)e[T+_]=e[p+_];++s}return s!==t.length&&(this.times=Yn.arraySlice(t,0,s),this.values=Yn.arraySlice(e,0,s*i)),this}}),Kl.prototype=Object.assign(Object.create(Hn.prototype),{constructor:Kl,ValueTypeName:"bool",ValueBufferType:Array,DefaultInterpolation:2300,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0}),Ql.prototype=Object.assign(Object.create(Hn.prototype),{constructor:Ql,ValueTypeName:"color"}),$r.prototype=Object.assign(Object.create(Hn.prototype),{constructor:$r,ValueTypeName:"number"}),ar.prototype=Object.assign(Object.create($n.prototype),{constructor:ar,interpolate_:function(t,e,i,n){var s=this.resultBuffer,l=this.sampleValues,d=this.valueSize;for(t*=d,e=(i-e)/(n-e),i=t+d;t!==i;t+=4)f.slerpFlat(s,0,l,t-d,l,t,e);return s}}),xa.prototype=Object.assign(Object.create(Hn.prototype),{constructor:xa,ValueTypeName:"quaternion",DefaultInterpolation:2301,InterpolantFactoryMethodLinear:function(t){return new ar(this.times,this.values,this.getValueSize(),t)},InterpolantFactoryMethodSmooth:void 0}),th.prototype=Object.assign(Object.create(Hn.prototype),{constructor:th,ValueTypeName:"string",ValueBufferType:Array,DefaultInterpolation:2300,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0}),wa.prototype=Object.assign(Object.create(Hn.prototype),{constructor:wa,ValueTypeName:"vector"}),Object.assign(_r,{parse:function(t){for(var e=[],i=t.tracks,n=1/(t.fps||1),s=0,l=i.length;s!==l;++s)e.push(Xc(i[s]).scale(n));return new _r(t.name,t.duration,e)},toJSON:function(t){var e=[],i=t.tracks;t={name:t.name,duration:t.duration,tracks:e,uuid:t.uuid};for(var n=0,s=i.length;n!==s;++n)e.push(Hn.toJSON(i[n]));return t},CreateFromMorphTargetSequence:function(t,e,i,n){for(var s=e.length,l=[],d=0;d<s;d++){var p=[],_=[];p.push((d+s-1)%s,d,(d+1)%s),_.push(0,1,0);var T=Yn.getKeyframeOrder(p);p=Yn.sortedArray(p,1,T),_=Yn.sortedArray(_,1,T),n||p[0]!==0||(p.push(s),_.push(_[0])),l.push(new $r(".morphTargetInfluences["+e[d].name+"]",p,_).scale(1/i))}return new _r(t,-1,l)},findByName:function(t,e){var i=t;for(Array.isArray(t)||(i=t.geometry&&t.geometry.animations||t.animations),t=0;t<i.length;t++)if(i[t].name===e)return i[t];return null},CreateClipsFromMorphTargetSequences:function(t,e,i){for(var n={},s=/^([\w-]*?)([\d]+)$/,l=0,d=t.length;l<d;l++){var p=t[l],_=p.name.match(s);if(_&&1<_.length){var T=_[1];(_=n[T])||(n[T]=_=[]),_.push(p)}}t=[];for(T in n)t.push(_r.CreateFromMorphTargetSequence(T,n[T],e,i));return t},parseAnimation:function(t,e){if(!t)return null;var i=function($,rt,xt,gt,Ct){if(xt.length!==0){var wt=[],Vt=[];Yn.flattenJSON(xt,wt,Vt,gt),wt.length!==0&&Ct.push(new $(rt,wt,Vt))}},n=[],s=t.name||"default",l=t.length||-1,d=t.fps||30;t=t.hierarchy||[];for(var p=0;p<t.length;p++){var _=t[p].keys;if(_&&_.length!==0)if(_[0].morphTargets){l={};for(var T=0;T<_.length;T++)if(_[T].morphTargets)for(var A=0;A<_[T].morphTargets.length;A++)l[_[T].morphTargets[A]]=-1;for(var L in l){var B=[],H=[];for(A=0;A!==_[T].morphTargets.length;++A){var q=_[T];B.push(q.time),H.push(q.morphTarget===L?1:0)}n.push(new $r(".morphTargetInfluence["+L+"]",B,H))}l=l.length*(d||1)}else T=".bones["+e[p].name+"]",i(wa,T+".position",_,"pos",n),i(xa,T+".quaternion",_,"rot",n),i(wa,T+".scale",_,"scl",n)}return n.length===0?null:new _r(s,l,n)}}),Object.assign(_r.prototype,{resetDuration:function(){for(var t=0,e=0,i=this.tracks.length;e!==i;++e){var n=this.tracks[e];t=Math.max(t,n.times[n.times.length-1])}return this.duration=t,this},trim:function(){for(var t=0;t<this.tracks.length;t++)this.tracks[t].trim(0,this.duration);return this},validate:function(){for(var t=!0,e=0;e<this.tracks.length;e++)t=t&&this.tracks[e].validate();return t},optimize:function(){for(var t=0;t<this.tracks.length;t++)this.tracks[t].optimize();return this}});var Mo={enabled:!1,files:{},add:function(t,e){this.enabled!==!1&&(this.files[t]=e)},get:function(t){if(this.enabled!==!1)return this.files[t]},remove:function(t){delete this.files[t]},clear:function(){this.files={}}},tr=new is,Br={};Object.assign(Lt.prototype,{load:function(t,e,i,n){t===void 0&&(t=""),this.path!==void 0&&(t=this.path+t),t=this.manager.resolveURL(t);var s=this,l=Mo.get(t);if(l!==void 0)return s.manager.itemStart(t),setTimeout(function(){e&&e(l),s.manager.itemEnd(t)},0),l;if(Br[t]!==void 0)Br[t].push({onLoad:e,onProgress:i,onError:n});else{var d=t.match(/^data:(.*?)(;base64)?,(.*)$/);if(d){i=d[1];var p=!!d[2];d=d[3],d=decodeURIComponent(d),p&&(d=atob(d));try{var _=(this.responseType||"").toLowerCase();switch(_){case"arraybuffer":case"blob":var T=new Uint8Array(d.length);for(p=0;p<d.length;p++)T[p]=d.charCodeAt(p);var A=_==="blob"?new Blob([T.buffer],{type:i}):T.buffer;break;case"document":A=new DOMParser().parseFromString(d,i);break;case"json":A=JSON.parse(d);break;default:A=d}setTimeout(function(){e&&e(A),s.manager.itemEnd(t)},0)}catch(B){setTimeout(function(){n&&n(B),s.manager.itemError(t),s.manager.itemEnd(t)},0)}}else{Br[t]=[],Br[t].push({onLoad:e,onProgress:i,onError:n});var L=new XMLHttpRequest;L.open("GET",t,!0),L.addEventListener("load",function(B){var H=this.response;Mo.add(t,H);var q=Br[t];if(delete Br[t],this.status===200||this.status===0){this.status;for(var $=0,rt=q.length;$<rt;$++){var xt=q[$];xt.onLoad&&xt.onLoad(H)}}else{for($=0,rt=q.length;$<rt;$++)xt=q[$],xt.onError&&xt.onError(B);s.manager.itemError(t)}s.manager.itemEnd(t)},!1),L.addEventListener("progress",function(B){for(var H=Br[t],q=0,$=H.length;q<$;q++){var rt=H[q];rt.onProgress&&rt.onProgress(B)}},!1),L.addEventListener("error",function(B){var H=Br[t];delete Br[t];for(var q=0,$=H.length;q<$;q++){var rt=H[q];rt.onError&&rt.onError(B)}s.manager.itemError(t),s.manager.itemEnd(t)},!1),L.addEventListener("abort",function(B){var H=Br[t];delete Br[t];for(var q=0,$=H.length;q<$;q++){var rt=H[q];rt.onError&&rt.onError(B)}s.manager.itemError(t),s.manager.itemEnd(t)},!1),this.responseType!==void 0&&(L.responseType=this.responseType),this.withCredentials!==void 0&&(L.withCredentials=this.withCredentials),L.overrideMimeType&&L.overrideMimeType(this.mimeType!==void 0?this.mimeType:"text/plain");for(p in this.requestHeader)L.setRequestHeader(p,this.requestHeader[p]);L.send(null)}return s.manager.itemStart(t),L}},setPath:function(t){return this.path=t,this},setResponseType:function(t){return this.responseType=t,this},setWithCredentials:function(t){return this.withCredentials=t,this},setMimeType:function(t){return this.mimeType=t,this},setRequestHeader:function(t){return this.requestHeader=t,this}}),Object.assign(Qt.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(s.manager);l.setPath(s.path),l.load(t,function(d){e(s.parse(JSON.parse(d)))},i,n)},parse:function(t,e){for(var i=[],n=0;n<t.length;n++){var s=_r.parse(t[n]);i.push(s)}e(i)},setPath:function(t){return this.path=t,this}}),Object.assign(Zt.prototype,{load:function(t,e,i,n){function s(B){_.load(t[B],function(H){H=l._parser(H,!0),d[B]={width:H.width,height:H.height,format:H.format,mipmaps:H.mipmaps},T+=1,T===6&&(H.mipmapCount===1&&(p.minFilter=1006),p.format=H.format,p.needsUpdate=!0,e&&e(p))},i,n)}var l=this,d=[],p=new Zo;p.image=d;var _=new Lt(this.manager);if(_.setPath(this.path),_.setResponseType("arraybuffer"),Array.isArray(t))for(var T=0,A=0,L=t.length;A<L;++A)s(A);else _.load(t,function(B){if(B=l._parser(B,!0),B.isCubemap)for(var H=B.mipmaps.length/B.mipmapCount,q=0;q<H;q++){d[q]={mipmaps:[]};for(var $=0;$<B.mipmapCount;$++)d[q].mipmaps.push(B.mipmaps[q*B.mipmapCount+$]),d[q].format=B.format,d[q].width=B.width,d[q].height=B.height}else p.image.width=B.width,p.image.height=B.height,p.mipmaps=B.mipmaps;B.mipmapCount===1&&(p.minFilter=1006),p.format=B.format,p.needsUpdate=!0,e&&e(p)},i,n);return p},setPath:function(t){return this.path=t,this}}),Object.assign(Ue.prototype,{load:function(t,e,i,n){var s=this,l=new O,d=new Lt(this.manager);return d.setResponseType("arraybuffer"),d.setPath(this.path),d.load(t,function(p){(p=s._parser(p))&&(p.image!==void 0?l.image=p.image:p.data!==void 0&&(l.image.width=p.width,l.image.height=p.height,l.image.data=p.data),l.wrapS=p.wrapS!==void 0?p.wrapS:1001,l.wrapT=p.wrapT!==void 0?p.wrapT:1001,l.magFilter=p.magFilter!==void 0?p.magFilter:1006,l.minFilter=p.minFilter!==void 0?p.minFilter:1008,l.anisotropy=p.anisotropy!==void 0?p.anisotropy:1,p.format!==void 0&&(l.format=p.format),p.type!==void 0&&(l.type=p.type),p.mipmaps!==void 0&&(l.mipmaps=p.mipmaps),p.mipmapCount===1&&(l.minFilter=1006),l.needsUpdate=!0,e&&e(l,p))},i,n),l},setPath:function(t){return this.path=t,this}}),Object.assign(ai.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){function s(){_.removeEventListener("load",s,!1),_.removeEventListener("error",l,!1),Mo.add(t,this),e&&e(this),d.manager.itemEnd(t)}function l(T){_.removeEventListener("load",s,!1),_.removeEventListener("error",l,!1),n&&n(T),d.manager.itemError(t),d.manager.itemEnd(t)}t===void 0&&(t=""),this.path!==void 0&&(t=this.path+t),t=this.manager.resolveURL(t);var d=this,p=Mo.get(t);if(p!==void 0)return d.manager.itemStart(t),setTimeout(function(){e&&e(p),d.manager.itemEnd(t)},0),p;var _=document.createElementNS("http://www.w3.org/1999/xhtml","img");return _.addEventListener("load",s,!1),_.addEventListener("error",l,!1),t.substr(0,5)!=="data:"&&this.crossOrigin!==void 0&&(_.crossOrigin=this.crossOrigin),d.manager.itemStart(t),_.src=t,_},setCrossOrigin:function(t){return this.crossOrigin=t,this},setPath:function(t){return this.path=t,this}}),Object.assign(Fi.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){function s(_){d.load(t[_],function(T){l.images[_]=T,p++,p===6&&(l.needsUpdate=!0,e&&e(l))},void 0,n)}var l=new z,d=new ai(this.manager);d.setCrossOrigin(this.crossOrigin),d.setPath(this.path);var p=0;for(i=0;i<t.length;++i)s(i);return l},setCrossOrigin:function(t){return this.crossOrigin=t,this},setPath:function(t){return this.path=t,this}}),Object.assign(fn.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){var s=new g,l=new ai(this.manager);return l.setCrossOrigin(this.crossOrigin),l.setPath(this.path),l.load(t,function(d){s.image=d,d=0<t.search(/\.jpe?g$/i)||t.search(/^data:image\/jpeg/)===0,s.format=d?1022:1023,s.needsUpdate=!0,e!==void 0&&e(s)},i,n),s},setCrossOrigin:function(t){return this.crossOrigin=t,this},setPath:function(t){return this.path=t,this}}),Object.assign(Ee.prototype,{getPoint:function(){return null},getPointAt:function(t,e){return t=this.getUtoTmapping(t),this.getPoint(t,e)},getPoints:function(t){t===void 0&&(t=5);for(var e=[],i=0;i<=t;i++)e.push(this.getPoint(i/t));return e},getSpacedPoints:function(t){t===void 0&&(t=5);for(var e=[],i=0;i<=t;i++)e.push(this.getPointAt(i/t));return e},getLength:function(){var t=this.getLengths();return t[t.length-1]},getLengths:function(t){if(t===void 0&&(t=this.arcLengthDivisions),this.cacheArcLengths&&this.cacheArcLengths.length===t+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;var e=[],i=this.getPoint(0),n,s=0;for(e.push(0),n=1;n<=t;n++){var l=this.getPoint(n/t);s+=l.distanceTo(i),e.push(s),i=l}return this.cacheArcLengths=e},updateArcLengths:function(){this.needsUpdate=!0,this.getLengths()},getUtoTmapping:function(t,e){var i=this.getLengths(),n=i.length;e=e||t*i[n-1];for(var s=0,l=n-1,d;s<=l;)if(t=Math.floor(s+(l-s)/2),d=i[t]-e,0>d)s=t+1;else if(0<d)l=t-1;else{l=t;break}return t=l,i[t]===e?t/(n-1):(s=i[t],(t+(e-s)/(i[t+1]-s))/(n-1))},getTangent:function(t){var e=t-1e-4;return t+=1e-4,0>e&&(e=0),1<t&&(t=1),e=this.getPoint(e),this.getPoint(t).clone().sub(e).normalize()},getTangentAt:function(t){return t=this.getUtoTmapping(t),this.getTangent(t)},computeFrenetFrames:function(t,e){var i=new u,n=[],s=[],l=[],d=new u,p=new c,_;for(_=0;_<=t;_++){var T=_/t;n[_]=this.getTangentAt(T),n[_].normalize()}s[0]=new u,l[0]=new u,_=Number.MAX_VALUE,T=Math.abs(n[0].x);var A=Math.abs(n[0].y),L=Math.abs(n[0].z);for(T<=_&&(_=T,i.set(1,0,0)),A<=_&&(_=A,i.set(0,1,0)),L<=_&&i.set(0,0,1),d.crossVectors(n[0],i).normalize(),s[0].crossVectors(n[0],d),l[0].crossVectors(n[0],s[0]),_=1;_<=t;_++)s[_]=s[_-1].clone(),l[_]=l[_-1].clone(),d.crossVectors(n[_-1],n[_]),d.length()>Number.EPSILON&&(d.normalize(),i=Math.acos(di.clamp(n[_-1].dot(n[_]),-1,1)),s[_].applyMatrix4(p.makeRotationAxis(d,i))),l[_].crossVectors(n[_],s[_]);if(e===!0)for(i=Math.acos(di.clamp(s[0].dot(s[t]),-1,1)),i/=t,0<n[0].dot(d.crossVectors(s[0],s[t]))&&(i=-i),_=1;_<=t;_++)s[_].applyMatrix4(p.makeRotationAxis(n[_],i*_)),l[_].crossVectors(n[_],s[_]);return{tangents:n,normals:s,binormals:l}},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.arcLengthDivisions=t.arcLengthDivisions,this},toJSON:function(){var t={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return t.arcLengthDivisions=this.arcLengthDivisions,t.type=this.type,t},fromJSON:function(t){return this.arcLengthDivisions=t.arcLengthDivisions,this}}),Kn.prototype=Object.create(Ee.prototype),Kn.prototype.constructor=Kn,Kn.prototype.isEllipseCurve=!0,Kn.prototype.getPoint=function(t,e){e=e||new o;for(var i=2*Math.PI,n=this.aEndAngle-this.aStartAngle,s=Math.abs(n)<Number.EPSILON;0>n;)n+=i;for(;n>i;)n-=i;n<Number.EPSILON&&(n=s?0:i),this.aClockwise!==!0||s||(n=n===i?-i:n-i),i=this.aStartAngle+t*n,t=this.aX+this.xRadius*Math.cos(i);var l=this.aY+this.yRadius*Math.sin(i);return this.aRotation!==0&&(i=Math.cos(this.aRotation),n=Math.sin(this.aRotation),s=t-this.aX,l-=this.aY,t=s*i-l*n+this.aX,l=s*n+l*i+this.aY),e.set(t,l)},Kn.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.aX=t.aX,this.aY=t.aY,this.xRadius=t.xRadius,this.yRadius=t.yRadius,this.aStartAngle=t.aStartAngle,this.aEndAngle=t.aEndAngle,this.aClockwise=t.aClockwise,this.aRotation=t.aRotation,this},Kn.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.aX=this.aX,t.aY=this.aY,t.xRadius=this.xRadius,t.yRadius=this.yRadius,t.aStartAngle=this.aStartAngle,t.aEndAngle=this.aEndAngle,t.aClockwise=this.aClockwise,t.aRotation=this.aRotation,t},Kn.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.aX=t.aX,this.aY=t.aY,this.xRadius=t.xRadius,this.yRadius=t.yRadius,this.aStartAngle=t.aStartAngle,this.aEndAngle=t.aEndAngle,this.aClockwise=t.aClockwise,this.aRotation=t.aRotation,this},Ta.prototype=Object.create(Kn.prototype),Ta.prototype.constructor=Ta,Ta.prototype.isArcCurve=!0;var bn=new u,Ml=new lr,lh=new lr,Nr=new lr;On.prototype=Object.create(Ee.prototype),On.prototype.constructor=On,On.prototype.isCatmullRomCurve3=!0,On.prototype.getPoint=function(t,e){e=e||new u;var i=this.points,n=i.length;t*=n-(this.closed?0:1);var s=Math.floor(t);if(t-=s,this.closed?s+=0<s?0:(Math.floor(Math.abs(s)/n)+1)*n:t===0&&s===n-1&&(s=n-2,t=1),this.closed||0<s)var l=i[(s-1)%n];else bn.subVectors(i[0],i[1]).add(i[0]),l=bn;var d=i[s%n],p=i[(s+1)%n];if(this.closed||s+2<n?i=i[(s+2)%n]:(bn.subVectors(i[n-1],i[n-2]).add(i[n-1]),i=bn),this.curveType==="centripetal"||this.curveType==="chordal"){var _=this.curveType==="chordal"?.5:.25;n=Math.pow(l.distanceToSquared(d),_),s=Math.pow(d.distanceToSquared(p),_),_=Math.pow(p.distanceToSquared(i),_),1e-4>s&&(s=1),1e-4>n&&(n=s),1e-4>_&&(_=s),Ml.initNonuniformCatmullRom(l.x,d.x,p.x,i.x,n,s,_),lh.initNonuniformCatmullRom(l.y,d.y,p.y,i.y,n,s,_),Nr.initNonuniformCatmullRom(l.z,d.z,p.z,i.z,n,s,_)}else this.curveType==="catmullrom"&&(Ml.initCatmullRom(l.x,d.x,p.x,i.x,this.tension),lh.initCatmullRom(l.y,d.y,p.y,i.y,this.tension),Nr.initCatmullRom(l.z,d.z,p.z,i.z,this.tension));return e.set(Ml.calc(t),lh.calc(t),Nr.calc(t)),e},On.prototype.copy=function(t){Ee.prototype.copy.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++)this.points.push(t.points[e].clone());return this.closed=t.closed,this.curveType=t.curveType,this.tension=t.tension,this},On.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);t.points=[];for(var e=0,i=this.points.length;e<i;e++)t.points.push(this.points[e].toArray());return t.closed=this.closed,t.curveType=this.curveType,t.tension=this.tension,t},On.prototype.fromJSON=function(t){Ee.prototype.fromJSON.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++){var n=t.points[e];this.points.push(new u().fromArray(n))}return this.closed=t.closed,this.curveType=t.curveType,this.tension=t.tension,this},hr.prototype=Object.create(Ee.prototype),hr.prototype.constructor=hr,hr.prototype.isCubicBezierCurve=!0,hr.prototype.getPoint=function(t,e){e=e||new o;var i=this.v0,n=this.v1,s=this.v2,l=this.v3;return e.set(ns(t,i.x,n.x,s.x,l.x),ns(t,i.y,n.y,s.y,l.y)),e},hr.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this.v3.copy(t.v3),this},hr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t.v3=this.v3.toArray(),t},hr.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this.v3.fromArray(t.v3),this},Ti.prototype=Object.create(Ee.prototype),Ti.prototype.constructor=Ti,Ti.prototype.isCubicBezierCurve3=!0,Ti.prototype.getPoint=function(t,e){e=e||new u;var i=this.v0,n=this.v1,s=this.v2,l=this.v3;return e.set(ns(t,i.x,n.x,s.x,l.x),ns(t,i.y,n.y,s.y,l.y),ns(t,i.z,n.z,s.z,l.z)),e},Ti.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this.v3.copy(t.v3),this},Ti.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t.v3=this.v3.toArray(),t},Ti.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this.v3.fromArray(t.v3),this},ur.prototype=Object.create(Ee.prototype),ur.prototype.constructor=ur,ur.prototype.isLineCurve=!0,ur.prototype.getPoint=function(t,e){return e=e||new o,t===1?e.copy(this.v2):(e.copy(this.v2).sub(this.v1),e.multiplyScalar(t).add(this.v1)),e},ur.prototype.getPointAt=function(t,e){return this.getPoint(t,e)},ur.prototype.getTangent=function(){return this.v2.clone().sub(this.v1).normalize()},ur.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v1.copy(t.v1),this.v2.copy(t.v2),this},ur.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},ur.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},zr.prototype=Object.create(Ee.prototype),zr.prototype.constructor=zr,zr.prototype.isLineCurve3=!0,zr.prototype.getPoint=function(t,e){return e=e||new u,t===1?e.copy(this.v2):(e.copy(this.v2).sub(this.v1),e.multiplyScalar(t).add(this.v1)),e},zr.prototype.getPointAt=function(t,e){return this.getPoint(t,e)},zr.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v1.copy(t.v1),this.v2.copy(t.v2),this},zr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},zr.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},cr.prototype=Object.create(Ee.prototype),cr.prototype.constructor=cr,cr.prototype.isQuadraticBezierCurve=!0,cr.prototype.getPoint=function(t,e){e=e||new o;var i=this.v0,n=this.v1,s=this.v2;return e.set(vo(t,i.x,n.x,s.x),vo(t,i.y,n.y,s.y)),e},cr.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this},cr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},cr.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},yo.prototype=Object.create(Ee.prototype),yo.prototype.constructor=yo,yo.prototype.isQuadraticBezierCurve3=!0,yo.prototype.getPoint=function(t,e){e=e||new u;var i=this.v0,n=this.v1,s=this.v2;return e.set(vo(t,i.x,n.x,s.x),vo(t,i.y,n.y,s.y),vo(t,i.z,n.z,s.z)),e},yo.prototype.copy=function(t){return Ee.prototype.copy.call(this,t),this.v0.copy(t.v0),this.v1.copy(t.v1),this.v2.copy(t.v2),this},yo.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);return t.v0=this.v0.toArray(),t.v1=this.v1.toArray(),t.v2=this.v2.toArray(),t},yo.prototype.fromJSON=function(t){return Ee.prototype.fromJSON.call(this,t),this.v0.fromArray(t.v0),this.v1.fromArray(t.v1),this.v2.fromArray(t.v2),this},Kr.prototype=Object.create(Ee.prototype),Kr.prototype.constructor=Kr,Kr.prototype.isSplineCurve=!0,Kr.prototype.getPoint=function(t,e){e=e||new o;var i=this.points,n=(i.length-1)*t;t=Math.floor(n),n-=t;var s=i[t===0?t:t-1],l=i[t],d=i[t>i.length-2?i.length-1:t+1];return i=i[t>i.length-3?i.length-1:t+2],e.set(Pu(n,s.x,l.x,d.x,i.x),Pu(n,s.y,l.y,d.y,i.y)),e},Kr.prototype.copy=function(t){Ee.prototype.copy.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++)this.points.push(t.points[e].clone());return this},Kr.prototype.toJSON=function(){var t=Ee.prototype.toJSON.call(this);t.points=[];for(var e=0,i=this.points.length;e<i;e++)t.points.push(this.points[e].toArray());return t},Kr.prototype.fromJSON=function(t){Ee.prototype.fromJSON.call(this,t),this.points=[];for(var e=0,i=t.points.length;e<i;e++){var n=t.points[e];this.points.push(new o().fromArray(n))}return this};var hh=Object.freeze({ArcCurve:Ta,CatmullRomCurve3:On,CubicBezierCurve:hr,CubicBezierCurve3:Ti,EllipseCurve:Kn,LineCurve:ur,LineCurve3:zr,QuadraticBezierCurve:cr,QuadraticBezierCurve3:yo,SplineCurve:Kr});Io.prototype=Object.assign(Object.create(Ee.prototype),{constructor:Io,add:function(t){this.curves.push(t)},closePath:function(){var t=this.curves[0].getPoint(0),e=this.curves[this.curves.length-1].getPoint(1);t.equals(e)||this.curves.push(new ur(e,t))},getPoint:function(t){var e=t*this.getLength(),i=this.getCurveLengths();for(t=0;t<i.length;){if(i[t]>=e)return e=i[t]-e,t=this.curves[t],i=t.getLength(),t.getPointAt(i===0?0:1-e/i);t++}return null},getLength:function(){var t=this.getCurveLengths();return t[t.length-1]},updateArcLengths:function(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()},getCurveLengths:function(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;for(var t=[],e=0,i=0,n=this.curves.length;i<n;i++)e+=this.curves[i].getLength(),t.push(e);return this.cacheLengths=t},getSpacedPoints:function(t){t===void 0&&(t=40);for(var e=[],i=0;i<=t;i++)e.push(this.getPoint(i/t));return this.autoClose&&e.push(e[0]),e},getPoints:function(t){t=t||12;for(var e=[],i,n=0,s=this.curves;n<s.length;n++){var l=s[n];l=l.getPoints(l&&l.isEllipseCurve?2*t:l&&(l.isLineCurve||l.isLineCurve3)?1:l&&l.isSplineCurve?t*l.points.length:t);for(var d=0;d<l.length;d++){var p=l[d];i&&i.equals(p)||(e.push(p),i=p)}}return this.autoClose&&1<e.length&&!e[e.length-1].equals(e[0])&&e.push(e[0]),e},copy:function(t){Ee.prototype.copy.call(this,t),this.curves=[];for(var e=0,i=t.curves.length;e<i;e++)this.curves.push(t.curves[e].clone());return this.autoClose=t.autoClose,this},toJSON:function(){var t=Ee.prototype.toJSON.call(this);t.autoClose=this.autoClose,t.curves=[];for(var e=0,i=this.curves.length;e<i;e++)t.curves.push(this.curves[e].toJSON());return t},fromJSON:function(t){Ee.prototype.fromJSON.call(this,t),this.autoClose=t.autoClose,this.curves=[];for(var e=0,i=t.curves.length;e<i;e++){var n=t.curves[e];this.curves.push(new hh[n.type]().fromJSON(n))}return this}}),fr.prototype=Object.assign(Object.create(Io.prototype),{constructor:fr,setFromPoints:function(t){this.moveTo(t[0].x,t[0].y);for(var e=1,i=t.length;e<i;e++)this.lineTo(t[e].x,t[e].y)},moveTo:function(t,e){this.currentPoint.set(t,e)},lineTo:function(t,e){var i=new ur(this.currentPoint.clone(),new o(t,e));this.curves.push(i),this.currentPoint.set(t,e)},quadraticCurveTo:function(t,e,i,n){t=new cr(this.currentPoint.clone(),new o(t,e),new o(i,n)),this.curves.push(t),this.currentPoint.set(i,n)},bezierCurveTo:function(t,e,i,n,s,l){t=new hr(this.currentPoint.clone(),new o(t,e),new o(i,n),new o(s,l)),this.curves.push(t),this.currentPoint.set(s,l)},splineThru:function(t){var e=[this.currentPoint.clone()].concat(t);e=new Kr(e),this.curves.push(e),this.currentPoint.copy(t[t.length-1])},arc:function(t,e,i,n,s,l){this.absarc(t+this.currentPoint.x,e+this.currentPoint.y,i,n,s,l)},absarc:function(t,e,i,n,s,l){this.absellipse(t,e,i,i,n,s,l)},ellipse:function(t,e,i,n,s,l,d,p){this.absellipse(t+this.currentPoint.x,e+this.currentPoint.y,i,n,s,l,d,p)},absellipse:function(t,e,i,n,s,l,d,p){t=new Kn(t,e,i,n,s,l,d,p),0<this.curves.length&&(e=t.getPoint(0),e.equals(this.currentPoint)||this.lineTo(e.x,e.y)),this.curves.push(t),t=t.getPoint(1),this.currentPoint.copy(t)},copy:function(t){return Io.prototype.copy.call(this,t),this.currentPoint.copy(t.currentPoint),this},toJSON:function(){var t=Io.prototype.toJSON.call(this);return t.currentPoint=this.currentPoint.toArray(),t},fromJSON:function(t){return Io.prototype.fromJSON.call(this,t),this.currentPoint.fromArray(t.currentPoint),this}}),Qn.prototype=Object.assign(Object.create(fr.prototype),{constructor:Qn,getPointsHoles:function(t){for(var e=[],i=0,n=this.holes.length;i<n;i++)e[i]=this.holes[i].getPoints(t);return e},extractPoints:function(t){return{shape:this.getPoints(t),holes:this.getPointsHoles(t)}},copy:function(t){fr.prototype.copy.call(this,t),this.holes=[];for(var e=0,i=t.holes.length;e<i;e++)this.holes.push(t.holes[e].clone());return this},toJSON:function(){var t=fr.prototype.toJSON.call(this);t.uuid=this.uuid,t.holes=[];for(var e=0,i=this.holes.length;e<i;e++)t.holes.push(this.holes[e].toJSON());return t},fromJSON:function(t){fr.prototype.fromJSON.call(this,t),this.uuid=t.uuid,this.holes=[];for(var e=0,i=t.holes.length;e<i;e++){var n=t.holes[e];this.holes.push(new fr().fromJSON(n))}return this}}),tn.prototype=Object.assign(Object.create(N.prototype),{constructor:tn,isLight:!0,copy:function(t){return N.prototype.copy.call(this,t),this.color.copy(t.color),this.intensity=t.intensity,this},toJSON:function(t){return t=N.prototype.toJSON.call(this,t),t.object.color=this.color.getHex(),t.object.intensity=this.intensity,this.groundColor!==void 0&&(t.object.groundColor=this.groundColor.getHex()),this.distance!==void 0&&(t.object.distance=this.distance),this.angle!==void 0&&(t.object.angle=this.angle),this.decay!==void 0&&(t.object.decay=this.decay),this.penumbra!==void 0&&(t.object.penumbra=this.penumbra),this.shadow!==void 0&&(t.object.shadow=this.shadow.toJSON()),t}}),al.prototype=Object.assign(Object.create(tn.prototype),{constructor:al,isHemisphereLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.groundColor.copy(t.groundColor),this}}),Object.assign(_o.prototype,{copy:function(t){return this.camera=t.camera.clone(),this.bias=t.bias,this.radius=t.radius,this.mapSize.copy(t.mapSize),this},clone:function(){return new this.constructor().copy(this)},toJSON:function(){var t={};return this.bias!==0&&(t.bias=this.bias),this.radius!==1&&(t.radius=this.radius),(this.mapSize.x!==512||this.mapSize.y!==512)&&(t.mapSize=this.mapSize.toArray()),t.camera=this.camera.toJSON(!1).object,delete t.camera.matrix,t}}),ll.prototype=Object.assign(Object.create(_o.prototype),{constructor:ll,isSpotLightShadow:!0,update:function(t){var e=this.camera,i=2*di.RAD2DEG*t.angle,n=this.mapSize.width/this.mapSize.height;t=t.distance||e.far,(i!==e.fov||n!==e.aspect||t!==e.far)&&(e.fov=i,e.aspect=n,e.far=t,e.updateProjectionMatrix())}}),hl.prototype=Object.assign(Object.create(tn.prototype),{constructor:hl,isSpotLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.distance=t.distance,this.angle=t.angle,this.penumbra=t.penumbra,this.decay=t.decay,this.target=t.target.clone(),this.shadow=t.shadow.clone(),this}}),Ds.prototype=Object.assign(Object.create(tn.prototype),{constructor:Ds,isPointLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.distance=t.distance,this.decay=t.decay,this.shadow=t.shadow.clone(),this}}),Ma.prototype=Object.assign(Object.create(Be.prototype),{constructor:Ma,isOrthographicCamera:!0,copy:function(t,e){return Be.prototype.copy.call(this,t,e),this.left=t.left,this.right=t.right,this.top=t.top,this.bottom=t.bottom,this.near=t.near,this.far=t.far,this.zoom=t.zoom,this.view=t.view===null?null:Object.assign({},t.view),this},setViewOffset:function(t,e,i,n,s,l){this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=t,this.view.fullHeight=e,this.view.offsetX=i,this.view.offsetY=n,this.view.width=s,this.view.height=l,this.updateProjectionMatrix()},clearViewOffset:function(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()},updateProjectionMatrix:function(){var t=(this.right-this.left)/(2*this.zoom),e=(this.top-this.bottom)/(2*this.zoom),i=(this.right+this.left)/2,n=(this.top+this.bottom)/2,s=i-t;if(i+=t,t=n+e,e=n-e,this.view!==null&&this.view.enabled){i=this.zoom/(this.view.width/this.view.fullWidth),e=this.zoom/(this.view.height/this.view.fullHeight);var l=(this.right-this.left)/this.view.width;n=(this.top-this.bottom)/this.view.height,s+=this.view.offsetX/i*l,i=s+this.view.width/i*l,t-=this.view.offsetY/e*n,e=t-this.view.height/e*n}this.projectionMatrix.makeOrthographic(s,i,t,e,this.near,this.far),this.projectionMatrixInverse.getInverse(this.projectionMatrix)},toJSON:function(t){return t=N.prototype.toJSON.call(this,t),t.object.zoom=this.zoom,t.object.left=this.left,t.object.right=this.right,t.object.top=this.top,t.object.bottom=this.bottom,t.object.near=this.near,t.object.far=this.far,this.view!==null&&(t.object.view=Object.assign({},this.view)),t}}),rs.prototype=Object.assign(Object.create(_o.prototype),{constructor:rs}),xo.prototype=Object.assign(Object.create(tn.prototype),{constructor:xo,isDirectionalLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.target=t.target.clone(),this.shadow=t.shadow.clone(),this}}),zs.prototype=Object.assign(Object.create(tn.prototype),{constructor:zs,isAmbientLight:!0}),eh.prototype=Object.assign(Object.create(tn.prototype),{constructor:eh,isRectAreaLight:!0,copy:function(t){return tn.prototype.copy.call(this,t),this.width=t.width,this.height=t.height,this},toJSON:function(t){return t=tn.prototype.toJSON.call(this,t),t.object.width=this.width,t.object.height=this.height,t}}),Object.assign(ih.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(s.manager);l.setPath(s.path),l.load(t,function(d){e(s.parse(JSON.parse(d)))},i,n)},parse:function(t){function e(d){return i[d],i[d]}var i=this.textures,n=new Fu[t.type];if(t.uuid!==void 0&&(n.uuid=t.uuid),t.name!==void 0&&(n.name=t.name),t.color!==void 0&&n.color.setHex(t.color),t.roughness!==void 0&&(n.roughness=t.roughness),t.metalness!==void 0&&(n.metalness=t.metalness),t.emissive!==void 0&&n.emissive.setHex(t.emissive),t.specular!==void 0&&n.specular.setHex(t.specular),t.shininess!==void 0&&(n.shininess=t.shininess),t.clearCoat!==void 0&&(n.clearCoat=t.clearCoat),t.clearCoatRoughness!==void 0&&(n.clearCoatRoughness=t.clearCoatRoughness),t.vertexColors!==void 0&&(n.vertexColors=t.vertexColors),t.fog!==void 0&&(n.fog=t.fog),t.flatShading!==void 0&&(n.flatShading=t.flatShading),t.blending!==void 0&&(n.blending=t.blending),t.combine!==void 0&&(n.combine=t.combine),t.side!==void 0&&(n.side=t.side),t.opacity!==void 0&&(n.opacity=t.opacity),t.transparent!==void 0&&(n.transparent=t.transparent),t.alphaTest!==void 0&&(n.alphaTest=t.alphaTest),t.depthTest!==void 0&&(n.depthTest=t.depthTest),t.depthWrite!==void 0&&(n.depthWrite=t.depthWrite),t.colorWrite!==void 0&&(n.colorWrite=t.colorWrite),t.wireframe!==void 0&&(n.wireframe=t.wireframe),t.wireframeLinewidth!==void 0&&(n.wireframeLinewidth=t.wireframeLinewidth),t.wireframeLinecap!==void 0&&(n.wireframeLinecap=t.wireframeLinecap),t.wireframeLinejoin!==void 0&&(n.wireframeLinejoin=t.wireframeLinejoin),t.rotation!==void 0&&(n.rotation=t.rotation),t.linewidth!==1&&(n.linewidth=t.linewidth),t.dashSize!==void 0&&(n.dashSize=t.dashSize),t.gapSize!==void 0&&(n.gapSize=t.gapSize),t.scale!==void 0&&(n.scale=t.scale),t.polygonOffset!==void 0&&(n.polygonOffset=t.polygonOffset),t.polygonOffsetFactor!==void 0&&(n.polygonOffsetFactor=t.polygonOffsetFactor),t.polygonOffsetUnits!==void 0&&(n.polygonOffsetUnits=t.polygonOffsetUnits),t.skinning!==void 0&&(n.skinning=t.skinning),t.morphTargets!==void 0&&(n.morphTargets=t.morphTargets),t.dithering!==void 0&&(n.dithering=t.dithering),t.visible!==void 0&&(n.visible=t.visible),t.userData!==void 0&&(n.userData=t.userData),t.uniforms!==void 0)for(var s in t.uniforms){var l=t.uniforms[s];switch(n.uniforms[s]={},l.type){case"t":n.uniforms[s].value=e(l.value);break;case"c":n.uniforms[s].value=new P().setHex(l.value);break;case"v2":n.uniforms[s].value=new o().fromArray(l.value);break;case"v3":n.uniforms[s].value=new u().fromArray(l.value);break;case"v4":n.uniforms[s].value=new v().fromArray(l.value);break;case"m4":n.uniforms[s].value=new c().fromArray(l.value);break;default:n.uniforms[s].value=l.value}}return t.defines!==void 0&&(n.defines=t.defines),t.vertexShader!==void 0&&(n.vertexShader=t.vertexShader),t.fragmentShader!==void 0&&(n.fragmentShader=t.fragmentShader),t.shading!==void 0&&(n.flatShading=t.shading===1),t.size!==void 0&&(n.size=t.size),t.sizeAttenuation!==void 0&&(n.sizeAttenuation=t.sizeAttenuation),t.map!==void 0&&(n.map=e(t.map)),t.alphaMap!==void 0&&(n.alphaMap=e(t.alphaMap),n.transparent=!0),t.bumpMap!==void 0&&(n.bumpMap=e(t.bumpMap)),t.bumpScale!==void 0&&(n.bumpScale=t.bumpScale),t.normalMap!==void 0&&(n.normalMap=e(t.normalMap)),t.normalMapType!==void 0&&(n.normalMapType=t.normalMapType),t.normalScale!==void 0&&(s=t.normalScale,Array.isArray(s)===!1&&(s=[s,s]),n.normalScale=new o().fromArray(s)),t.displacementMap!==void 0&&(n.displacementMap=e(t.displacementMap)),t.displacementScale!==void 0&&(n.displacementScale=t.displacementScale),t.displacementBias!==void 0&&(n.displacementBias=t.displacementBias),t.roughnessMap!==void 0&&(n.roughnessMap=e(t.roughnessMap)),t.metalnessMap!==void 0&&(n.metalnessMap=e(t.metalnessMap)),t.emissiveMap!==void 0&&(n.emissiveMap=e(t.emissiveMap)),t.emissiveIntensity!==void 0&&(n.emissiveIntensity=t.emissiveIntensity),t.specularMap!==void 0&&(n.specularMap=e(t.specularMap)),t.envMap!==void 0&&(n.envMap=e(t.envMap)),t.envMapIntensity!==void 0&&(n.envMapIntensity=t.envMapIntensity),t.reflectivity!==void 0&&(n.reflectivity=t.reflectivity),t.lightMap!==void 0&&(n.lightMap=e(t.lightMap)),t.lightMapIntensity!==void 0&&(n.lightMapIntensity=t.lightMapIntensity),t.aoMap!==void 0&&(n.aoMap=e(t.aoMap)),t.aoMapIntensity!==void 0&&(n.aoMapIntensity=t.aoMapIntensity),t.gradientMap!==void 0&&(n.gradientMap=e(t.gradientMap)),n},setPath:function(t){return this.path=t,this},setTextures:function(t){return this.textures=t,this}});var Gs={decodeText:function(t){if(typeof TextDecoder<"u")return new TextDecoder().decode(t);for(var e="",i=0,n=t.length;i<n;i++)e+=String.fromCharCode(t[i]);return decodeURIComponent(escape(e))},extractUrlBase:function(t){var e=t.lastIndexOf("/");return e===-1?"./":t.substr(0,e+1)}};Object.assign(Nh.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(s.manager);l.setPath(s.path),l.load(t,function(d){e(s.parse(JSON.parse(d)))},i,n)},parse:function(t){var e=new Ft,i=t.data.index;i!==void 0&&(i=new hs[i.type](i.array),e.setIndex(new J(i,1)));var n=t.data.attributes;for(l in n){var s=n[l];i=new hs[s.type](s.array),e.addAttribute(l,new J(i,s.itemSize,s.normalized))}var l=t.data.groups||t.data.drawcalls||t.data.offsets;if(l!==void 0)for(i=0,n=l.length;i!==n;++i)s=l[i],e.addGroup(s.start,s.count,s.materialIndex);return t=t.data.boundingSphere,t!==void 0&&(l=new u,t.center!==void 0&&l.fromArray(t.center),e.boundingSphere=new I(l,t.radius)),e},setPath:function(t){return this.path=t,this}});var hs={Int8Array,Uint8Array,Uint8ClampedArray:typeof Uint8ClampedArray<"u"?Uint8ClampedArray:Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array};Do.Handlers={handlers:[],add:function(t,e){this.handlers.push(t,e)},get:function(t){for(var e=this.handlers,i=0,n=e.length;i<n;i+=2){var s=e[i+1];if(e[i].test(t))return s}return null}},Object.assign(Do.prototype,{crossOrigin:"anonymous",onLoadStart:function(){},onLoadProgress:function(){},onLoadComplete:function(){},initMaterials:function(t,e,i){for(var n=[],s=0;s<t.length;++s)n[s]=this.createMaterial(t[s],e,i);return n},createMaterial:function(){var t={NoBlending:0,NormalBlending:1,AdditiveBlending:2,SubtractiveBlending:3,MultiplyBlending:4,CustomBlending:5},e=new P,i=new fn,n=new ih;return function(s,l,d){function p(B,H,q,$,rt){B=l+B;var xt=Do.Handlers.get(B);return xt!==null?B=xt.load(B):(i.setCrossOrigin(d),B=i.load(B)),H!==void 0&&(B.repeat.fromArray(H),H[0]!==1&&(B.wrapS=1e3),H[1]!==1&&(B.wrapT=1e3)),q!==void 0&&B.offset.fromArray(q),$!==void 0&&($[0]==="repeat"&&(B.wrapS=1e3),$[0]==="mirror"&&(B.wrapS=1002),$[1]==="repeat"&&(B.wrapT=1e3),$[1]==="mirror"&&(B.wrapT=1002)),rt!==void 0&&(B.anisotropy=rt),H=di.generateUUID(),_[H]=B,H}var _={},T={uuid:di.generateUUID(),type:"MeshLambertMaterial"},A;for(A in s){var L=s[A];switch(A){case"DbgColor":case"DbgIndex":case"opticalDensity":case"illumination":break;case"DbgName":T.name=L;break;case"blending":T.blending=t[L];break;case"colorAmbient":case"mapAmbient":break;case"colorDiffuse":T.color=e.fromArray(L).getHex();break;case"colorSpecular":T.specular=e.fromArray(L).getHex();break;case"colorEmissive":T.emissive=e.fromArray(L).getHex();break;case"specularCoef":T.shininess=L;break;case"shading":L.toLowerCase()==="basic"&&(T.type="MeshBasicMaterial"),L.toLowerCase()==="phong"&&(T.type="MeshPhongMaterial"),L.toLowerCase()==="standard"&&(T.type="MeshStandardMaterial");break;case"mapDiffuse":T.map=p(L,s.mapDiffuseRepeat,s.mapDiffuseOffset,s.mapDiffuseWrap,s.mapDiffuseAnisotropy);break;case"mapDiffuseRepeat":case"mapDiffuseOffset":case"mapDiffuseWrap":case"mapDiffuseAnisotropy":break;case"mapEmissive":T.emissiveMap=p(L,s.mapEmissiveRepeat,s.mapEmissiveOffset,s.mapEmissiveWrap,s.mapEmissiveAnisotropy);break;case"mapEmissiveRepeat":case"mapEmissiveOffset":case"mapEmissiveWrap":case"mapEmissiveAnisotropy":break;case"mapLight":T.lightMap=p(L,s.mapLightRepeat,s.mapLightOffset,s.mapLightWrap,s.mapLightAnisotropy);break;case"mapLightRepeat":case"mapLightOffset":case"mapLightWrap":case"mapLightAnisotropy":break;case"mapAO":T.aoMap=p(L,s.mapAORepeat,s.mapAOOffset,s.mapAOWrap,s.mapAOAnisotropy);break;case"mapAORepeat":case"mapAOOffset":case"mapAOWrap":case"mapAOAnisotropy":break;case"mapBump":T.bumpMap=p(L,s.mapBumpRepeat,s.mapBumpOffset,s.mapBumpWrap,s.mapBumpAnisotropy);break;case"mapBumpScale":T.bumpScale=L;break;case"mapBumpRepeat":case"mapBumpOffset":case"mapBumpWrap":case"mapBumpAnisotropy":break;case"mapNormal":T.normalMap=p(L,s.mapNormalRepeat,s.mapNormalOffset,s.mapNormalWrap,s.mapNormalAnisotropy);break;case"mapNormalFactor":T.normalScale=L;break;case"mapNormalRepeat":case"mapNormalOffset":case"mapNormalWrap":case"mapNormalAnisotropy":break;case"mapSpecular":T.specularMap=p(L,s.mapSpecularRepeat,s.mapSpecularOffset,s.mapSpecularWrap,s.mapSpecularAnisotropy);break;case"mapSpecularRepeat":case"mapSpecularOffset":case"mapSpecularWrap":case"mapSpecularAnisotropy":break;case"mapMetalness":T.metalnessMap=p(L,s.mapMetalnessRepeat,s.mapMetalnessOffset,s.mapMetalnessWrap,s.mapMetalnessAnisotropy);break;case"mapMetalnessRepeat":case"mapMetalnessOffset":case"mapMetalnessWrap":case"mapMetalnessAnisotropy":break;case"mapRoughness":T.roughnessMap=p(L,s.mapRoughnessRepeat,s.mapRoughnessOffset,s.mapRoughnessWrap,s.mapRoughnessAnisotropy);break;case"mapRoughnessRepeat":case"mapRoughnessOffset":case"mapRoughnessWrap":case"mapRoughnessAnisotropy":break;case"mapAlpha":T.alphaMap=p(L,s.mapAlphaRepeat,s.mapAlphaOffset,s.mapAlphaWrap,s.mapAlphaAnisotropy);break;case"mapAlphaRepeat":case"mapAlphaOffset":case"mapAlphaWrap":case"mapAlphaAnisotropy":break;case"flipSided":T.side=1;break;case"doubleSided":T.side=2;break;case"transparency":T.opacity=L;break;case"depthTest":case"depthWrite":case"colorWrite":case"opacity":case"reflectivity":case"transparent":case"visible":case"wireframe":T[A]=L;break;case"vertexColors":L===!0&&(T.vertexColors=2),L==="face"&&(T.vertexColors=1);break;default:}}return T.type==="MeshBasicMaterial"&&delete T.emissive,T.type!=="MeshPhongMaterial"&&delete T.specular,1>T.opacity&&(T.transparent=!0),n.setTextures(_),n.parse(T)}}()}),Object.assign(ks.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){var s=this,l=this.path===void 0?Gs.extractUrlBase(t):this.path,d=new Lt(this.manager);d.setPath(this.path),d.setWithCredentials(this.withCredentials),d.load(t,function(p){p=JSON.parse(p);var _=p.metadata;_!==void 0&&(_=_.type,_!==void 0&&_.toLowerCase()==="object")||(p=s.parse(p,l),e(p.geometry,p.materials))},i,n)},setPath:function(t){return this.path=t,this},setResourcePath:function(t){return this.resourcePath=t,this},setCrossOrigin:function(t){return this.crossOrigin=t,this},parse:function(){return function(t,e){t.data!==void 0&&(t=t.data),t.scale=t.scale!==void 0?1/t.scale:1;var i=new X,n=t,s,l,d,p=n.faces,_=n.vertices,T=n.normals,A=n.colors,L=n.scale,B=0;if(n.uvs!==void 0){for(s=0;s<n.uvs.length;s++)n.uvs[s].length&&B++;for(s=0;s<B;s++)i.faceVertexUvs[s]=[]}var H=0;for(d=_.length;H<d;)s=new u,s.x=_[H++]*L,s.y=_[H++]*L,s.z=_[H++]*L,i.vertices.push(s);for(H=0,d=p.length;H<d;){_=p[H++];var q=_&1,$=_&2;s=_&8;var rt=_&16,xt=_&32;if(L=_&64,_&=128,q){q=new R,q.a=p[H],q.b=p[H+1],q.c=p[H+3];var gt=new R;if(gt.a=p[H+1],gt.b=p[H+2],gt.c=p[H+3],H+=4,$&&($=p[H++],q.materialIndex=$,gt.materialIndex=$),$=i.faces.length,s)for(s=0;s<B;s++){var Ct=n.uvs[s];for(i.faceVertexUvs[s][$]=[],i.faceVertexUvs[s][$+1]=[],l=0;4>l;l++){var wt=p[H++],Vt=Ct[2*wt];wt=Ct[2*wt+1],Vt=new o(Vt,wt),l!==2&&i.faceVertexUvs[s][$].push(Vt),l!==0&&i.faceVertexUvs[s][$+1].push(Vt)}}if(rt&&(rt=3*p[H++],q.normal.set(T[rt++],T[rt++],T[rt]),gt.normal.copy(q.normal)),xt)for(s=0;4>s;s++)rt=3*p[H++],xt=new u(T[rt++],T[rt++],T[rt]),s!==2&&q.vertexNormals.push(xt),s!==0&>.vertexNormals.push(xt);if(L&&(L=p[H++],L=A[L],q.color.setHex(L),gt.color.setHex(L)),_)for(s=0;4>s;s++)L=p[H++],L=A[L],s!==2&&q.vertexColors.push(new P(L)),s!==0&>.vertexColors.push(new P(L));i.faces.push(q),i.faces.push(gt)}else{if(q=new R,q.a=p[H++],q.b=p[H++],q.c=p[H++],$&&($=p[H++],q.materialIndex=$),$=i.faces.length,s)for(s=0;s<B;s++)for(Ct=n.uvs[s],i.faceVertexUvs[s][$]=[],l=0;3>l;l++)wt=p[H++],Vt=Ct[2*wt],wt=Ct[2*wt+1],Vt=new o(Vt,wt),i.faceVertexUvs[s][$].push(Vt);if(rt&&(rt=3*p[H++],q.normal.set(T[rt++],T[rt++],T[rt])),xt)for(s=0;3>s;s++)rt=3*p[H++],xt=new u(T[rt++],T[rt++],T[rt]),q.vertexNormals.push(xt);if(L&&(L=p[H++],q.color.setHex(A[L])),_)for(s=0;3>s;s++)L=p[H++],q.vertexColors.push(new P(A[L]));i.faces.push(q)}}if(n=t,H=n.influencesPerVertex!==void 0?n.influencesPerVertex:2,n.skinWeights)for(d=0,p=n.skinWeights.length;d<p;d+=H)i.skinWeights.push(new v(n.skinWeights[d],1<H?n.skinWeights[d+1]:0,2<H?n.skinWeights[d+2]:0,3<H?n.skinWeights[d+3]:0));if(n.skinIndices)for(d=0,p=n.skinIndices.length;d<p;d+=H)i.skinIndices.push(new v(n.skinIndices[d],1<H?n.skinIndices[d+1]:0,2<H?n.skinIndices[d+2]:0,3<H?n.skinIndices[d+3]:0));if(i.bones=n.bones,i.bones&&0<i.bones.length&&(i.skinWeights.length!==i.skinIndices.length||(i.skinIndices.length,i.vertices.length)),d=t,p=d.scale,d.morphTargets!==void 0)for(n=0,H=d.morphTargets.length;n<H;n++)for(i.morphTargets[n]={},i.morphTargets[n].name=d.morphTargets[n].name,i.morphTargets[n].vertices=[],T=i.morphTargets[n].vertices,A=d.morphTargets[n].vertices,B=0,_=A.length;B<_;B+=3)L=new u,L.x=A[B]*p,L.y=A[B+1]*p,L.z=A[B+2]*p,T.push(L);if(d.morphColors!==void 0&&0<d.morphColors.length)for(p=i.faces,d=d.morphColors[0].colors,n=0,H=p.length;n<H;n++)p[n].color.fromArray(d,3*n);for(d=t,n=[],H=[],d.animation!==void 0&&H.push(d.animation),d.animations!==void 0&&(d.animations.length?H=H.concat(d.animations):H.push(d.animations)),d=0;d<H.length;d++)(p=_r.parseAnimation(H[d],i.bones))&&n.push(p);return i.morphTargets&&(H=_r.CreateClipsFromMorphTargetSequences(i.morphTargets,10),n=n.concat(H)),0<n.length&&(i.animations=n),i.computeFaceNormals(),i.computeBoundingSphere(),t.materials===void 0||t.materials.length===0?{geometry:i}:(t=Do.prototype.initMaterials(t.materials,this.resourcePath||e,this.crossOrigin),{geometry:i,materials:t})}}()}),Object.assign(ul.prototype,{crossOrigin:"anonymous",load:function(t,e,i,n){var s=this,l=this.path===void 0?Gs.extractUrlBase(t):this.path;this.resourcePath=this.resourcePath||l,l=new Lt(s.manager),l.setPath(this.path),l.load(t,function(d){var p=null;try{p=JSON.parse(d)}catch(_){n!==void 0&&n(_);return}d=p.metadata,d===void 0||d.type===void 0||d.type.toLowerCase()==="geometry"||s.parse(p,e)},i,n)},setPath:function(t){return this.path=t,this},setResourcePath:function(t){return this.resourcePath=t,this},setCrossOrigin:function(t){return this.crossOrigin=t,this},parse:function(t,e){var i=this.parseShape(t.shapes);i=this.parseGeometries(t.geometries,i);var n=this.parseImages(t.images,function(){e!==void 0&&e(s)});n=this.parseTextures(t.textures,n),n=this.parseMaterials(t.materials,n);var s=this.parseObject(t.object,i,n);return t.animations&&(s.animations=this.parseAnimations(t.animations)),t.images!==void 0&&t.images.length!==0||e===void 0||e(s),s},parseShape:function(t){var e={};if(t!==void 0)for(var i=0,n=t.length;i<n;i++){var s=new Qn().fromJSON(t[i]);e[s.uuid]=s}return e},parseGeometries:function(t,e){var i={};if(t!==void 0)for(var n=new ks,s=new Nh,l=0,d=t.length;l<d;l++){var p=t[l];switch(p.type){case"PlaneGeometry":case"PlaneBufferGeometry":var _=new yn[p.type](p.width,p.height,p.widthSegments,p.heightSegments);break;case"BoxGeometry":case"BoxBufferGeometry":case"CubeGeometry":_=new yn[p.type](p.width,p.height,p.depth,p.widthSegments,p.heightSegments,p.depthSegments);break;case"CircleGeometry":case"CircleBufferGeometry":_=new yn[p.type](p.radius,p.segments,p.thetaStart,p.thetaLength);break;case"CylinderGeometry":case"CylinderBufferGeometry":_=new yn[p.type](p.radiusTop,p.radiusBottom,p.height,p.radialSegments,p.heightSegments,p.openEnded,p.thetaStart,p.thetaLength);break;case"ConeGeometry":case"ConeBufferGeometry":_=new yn[p.type](p.radius,p.height,p.radialSegments,p.heightSegments,p.openEnded,p.thetaStart,p.thetaLength);break;case"SphereGeometry":case"SphereBufferGeometry":_=new yn[p.type](p.radius,p.widthSegments,p.heightSegments,p.phiStart,p.phiLength,p.thetaStart,p.thetaLength);break;case"DodecahedronGeometry":case"DodecahedronBufferGeometry":case"IcosahedronGeometry":case"IcosahedronBufferGeometry":case"OctahedronGeometry":case"OctahedronBufferGeometry":case"TetrahedronGeometry":case"TetrahedronBufferGeometry":_=new yn[p.type](p.radius,p.detail);break;case"RingGeometry":case"RingBufferGeometry":_=new yn[p.type](p.innerRadius,p.outerRadius,p.thetaSegments,p.phiSegments,p.thetaStart,p.thetaLength);break;case"TorusGeometry":case"TorusBufferGeometry":_=new yn[p.type](p.radius,p.tube,p.radialSegments,p.tubularSegments,p.arc);break;case"TorusKnotGeometry":case"TorusKnotBufferGeometry":_=new yn[p.type](p.radius,p.tube,p.tubularSegments,p.radialSegments,p.p,p.q);break;case"LatheGeometry":case"LatheBufferGeometry":_=new yn[p.type](p.points,p.segments,p.phiStart,p.phiLength);break;case"PolyhedronGeometry":case"PolyhedronBufferGeometry":_=new yn[p.type](p.vertices,p.indices,p.radius,p.details);break;case"ShapeGeometry":case"ShapeBufferGeometry":_=[];for(var T=0,A=p.shapes.length;T<A;T++){var L=e[p.shapes[T]];_.push(L)}_=new yn[p.type](_,p.curveSegments);break;case"ExtrudeGeometry":case"ExtrudeBufferGeometry":for(_=[],T=0,A=p.shapes.length;T<A;T++)L=e[p.shapes[T]],_.push(L);T=p.options.extrudePath,T!==void 0&&(p.options.extrudePath=new hh[T.type]().fromJSON(T)),_=new yn[p.type](_,p.options);break;case"BufferGeometry":_=s.parse(p);break;case"Geometry":_=n.parse(p,this.resourcePath).geometry;break;default:continue}_.uuid=p.uuid,p.name!==void 0&&(_.name=p.name),_.isBufferGeometry===!0&&p.userData!==void 0&&(_.userData=p.userData),i[p.uuid]=_}return i},parseMaterials:function(t,e){var i={},n={};if(t!==void 0){var s=new ih;s.setTextures(e),e=0;for(var l=t.length;e<l;e++){var d=t[e];if(d.type==="MultiMaterial"){for(var p=[],_=0;_<d.materials.length;_++){var T=d.materials[_];i[T.uuid]===void 0&&(i[T.uuid]=s.parse(T)),p.push(i[T.uuid])}n[d.uuid]=p}else n[d.uuid]=s.parse(d),i[d.uuid]=n[d.uuid]}}return n},parseAnimations:function(t){for(var e=[],i=0;i<t.length;i++){var n=t[i],s=_r.parse(n);n.uuid!==void 0&&(s.uuid=n.uuid),e.push(s)}return e},parseImages:function(t,e){function i(B){return n.manager.itemStart(B),l.load(B,function(){n.manager.itemEnd(B)},void 0,function(){n.manager.itemError(B),n.manager.itemEnd(B)})}var n=this,s={};if(t!==void 0&&0<t.length){e=new is(e);var l=new ai(e);l.setCrossOrigin(this.crossOrigin),e=0;for(var d=t.length;e<d;e++){var p=t[e],_=p.url;if(Array.isArray(_)){s[p.uuid]=[];for(var T=0,A=_.length;T<A;T++){var L=_[T];L=/^(\/\/)|([a-z]+:(\/\/)?)/i.test(L)?L:n.resourcePath+L,s[p.uuid].push(i(L))}}else L=/^(\/\/)|([a-z]+:(\/\/)?)/i.test(p.url)?p.url:n.resourcePath+p.url,s[p.uuid]=i(L)}}return s},parseTextures:function(t,e){function i(_,T){return typeof _=="number"?_:T[_]}var n={};if(t!==void 0)for(var s=0,l=t.length;s<l;s++){var d=t[s];d.image,e[d.image];var p=Array.isArray(e[d.image])?new z(e[d.image]):new g(e[d.image]);p.needsUpdate=!0,p.uuid=d.uuid,d.name!==void 0&&(p.name=d.name),d.mapping!==void 0&&(p.mapping=i(d.mapping,Uu)),d.offset!==void 0&&p.offset.fromArray(d.offset),d.repeat!==void 0&&p.repeat.fromArray(d.repeat),d.center!==void 0&&p.center.fromArray(d.center),d.rotation!==void 0&&(p.rotation=d.rotation),d.wrap!==void 0&&(p.wrapS=i(d.wrap[0],Zn),p.wrapT=i(d.wrap[1],Zn)),d.format!==void 0&&(p.format=d.format),d.minFilter!==void 0&&(p.minFilter=i(d.minFilter,uh)),d.magFilter!==void 0&&(p.magFilter=i(d.magFilter,uh)),d.anisotropy!==void 0&&(p.anisotropy=d.anisotropy),d.flipY!==void 0&&(p.flipY=d.flipY),n[d.uuid]=p}return n},parseObject:function(t,e,i){function n(T){return e[T],e[T]}function s(T){if(T!==void 0){if(Array.isArray(T)){for(var A=[],L=0,B=T.length;L<B;L++){var H=T[L];i[H],A.push(i[H])}return A}return i[T],i[T]}}switch(t.type){case"Scene":var l=new Xn;t.background!==void 0&&Number.isInteger(t.background)&&(l.background=new P(t.background)),t.fog!==void 0&&(t.fog.type==="Fog"?l.fog=new Sn(t.fog.color,t.fog.near,t.fog.far):t.fog.type==="FogExp2"&&(l.fog=new Re(t.fog.color,t.fog.density)));break;case"PerspectiveCamera":l=new _e(t.fov,t.aspect,t.near,t.far),t.focus!==void 0&&(l.focus=t.focus),t.zoom!==void 0&&(l.zoom=t.zoom),t.filmGauge!==void 0&&(l.filmGauge=t.filmGauge),t.filmOffset!==void 0&&(l.filmOffset=t.filmOffset),t.view!==void 0&&(l.view=Object.assign({},t.view));break;case"OrthographicCamera":l=new Ma(t.left,t.right,t.top,t.bottom,t.near,t.far),t.zoom!==void 0&&(l.zoom=t.zoom),t.view!==void 0&&(l.view=Object.assign({},t.view));break;case"AmbientLight":l=new zs(t.color,t.intensity);break;case"DirectionalLight":l=new xo(t.color,t.intensity);break;case"PointLight":l=new Ds(t.color,t.intensity,t.distance,t.decay);break;case"RectAreaLight":l=new eh(t.color,t.intensity,t.width,t.height);break;case"SpotLight":l=new hl(t.color,t.intensity,t.distance,t.angle,t.penumbra,t.decay);break;case"HemisphereLight":l=new al(t.color,t.groundColor,t.intensity);break;case"SkinnedMesh":case"Mesh":l=n(t.geometry);var d=s(t.material);l=l.bones&&0<l.bones.length?new Gi(l,d):new pi(l,d);break;case"LOD":l=new rn;break;case"Line":l=new ji(n(t.geometry),s(t.material),t.mode);break;case"LineLoop":l=new co(n(t.geometry),s(t.material));break;case"LineSegments":l=new gi(n(t.geometry),s(t.material));break;case"PointCloud":case"Points":l=new ha(n(t.geometry),s(t.material));break;case"Sprite":l=new nn(s(t.material));break;case"Group":l=new ci;break;default:l=new N}if(l.uuid=t.uuid,t.name!==void 0&&(l.name=t.name),t.matrix!==void 0?(l.matrix.fromArray(t.matrix),t.matrixAutoUpdate!==void 0&&(l.matrixAutoUpdate=t.matrixAutoUpdate),l.matrixAutoUpdate&&l.matrix.decompose(l.position,l.quaternion,l.scale)):(t.position!==void 0&&l.position.fromArray(t.position),t.rotation!==void 0&&l.rotation.fromArray(t.rotation),t.quaternion!==void 0&&l.quaternion.fromArray(t.quaternion),t.scale!==void 0&&l.scale.fromArray(t.scale)),t.castShadow!==void 0&&(l.castShadow=t.castShadow),t.receiveShadow!==void 0&&(l.receiveShadow=t.receiveShadow),t.shadow&&(t.shadow.bias!==void 0&&(l.shadow.bias=t.shadow.bias),t.shadow.radius!==void 0&&(l.shadow.radius=t.shadow.radius),t.shadow.mapSize!==void 0&&l.shadow.mapSize.fromArray(t.shadow.mapSize),t.shadow.camera!==void 0&&(l.shadow.camera=this.parseObject(t.shadow.camera))),t.visible!==void 0&&(l.visible=t.visible),t.frustumCulled!==void 0&&(l.frustumCulled=t.frustumCulled),t.renderOrder!==void 0&&(l.renderOrder=t.renderOrder),t.userData!==void 0&&(l.userData=t.userData),t.layers!==void 0&&(l.layers.mask=t.layers),t.children!==void 0){d=t.children;for(var p=0;p<d.length;p++)l.add(this.parseObject(d[p],e,i))}if(t.type==="LOD")for(t=t.levels,d=0;d<t.length;d++){p=t[d];var _=l.getObjectByProperty("uuid",p.object);_!==void 0&&l.addLevel(_,p.distance)}return l}});var Uu={UVMapping:300,CubeReflectionMapping:301,CubeRefractionMapping:302,EquirectangularReflectionMapping:303,EquirectangularRefractionMapping:304,SphericalReflectionMapping:305,CubeUVReflectionMapping:306,CubeUVRefractionMapping:307},Zn={RepeatWrapping:1e3,ClampToEdgeWrapping:1001,MirroredRepeatWrapping:1002},uh={NearestFilter:1003,NearestMipMapNearestFilter:1004,NearestMipMapLinearFilter:1005,LinearFilter:1006,LinearMipMapNearestFilter:1007,LinearMipMapLinearFilter:1008};Fh.prototype={constructor:Fh,setOptions:function(t){return this.options=t,this},load:function(t,e,i,n){t===void 0&&(t=""),this.path!==void 0&&(t=this.path+t),t=this.manager.resolveURL(t);var s=this,l=Mo.get(t);if(l!==void 0)return s.manager.itemStart(t),setTimeout(function(){e&&e(l),s.manager.itemEnd(t)},0),l;fetch(t).then(function(d){return d.blob()}).then(function(d){return createImageBitmap(d,s.options)}).then(function(d){Mo.add(t,d),e&&e(d),s.manager.itemEnd(t)}).catch(function(d){n&&n(d),s.manager.itemError(t),s.manager.itemEnd(t)})},setCrossOrigin:function(){return this},setPath:function(t){return this.path=t,this}},Object.assign(nh.prototype,{moveTo:function(t,e){this.currentPath=new fr,this.subPaths.push(this.currentPath),this.currentPath.moveTo(t,e)},lineTo:function(t,e){this.currentPath.lineTo(t,e)},quadraticCurveTo:function(t,e,i,n){this.currentPath.quadraticCurveTo(t,e,i,n)},bezierCurveTo:function(t,e,i,n,s,l){this.currentPath.bezierCurveTo(t,e,i,n,s,l)},splineThru:function(t){this.currentPath.splineThru(t)},toShapes:function(t,e){function i(rt){for(var xt=[],gt=0,Ct=rt.length;gt<Ct;gt++){var wt=rt[gt],Vt=new Qn;Vt.curves=wt.curves,xt.push(Vt)}return xt}function n(rt,xt){for(var gt=xt.length,Ct=!1,wt=gt-1,Vt=0;Vt<gt;wt=Vt++){var K=xt[wt],ot=xt[Vt],kt=ot.x-K.x,ee=ot.y-K.y;if(Math.abs(ee)>Number.EPSILON){if(0>ee&&(K=xt[Vt],kt=-kt,ot=xt[wt],ee=-ee),!(rt.y<K.y||rt.y>ot.y))if(rt.y===K.y){if(rt.x===K.x)return!0}else{if(wt=ee*(rt.x-K.x)-kt*(rt.y-K.y),wt===0)return!0;0>wt||(Ct=!Ct)}}else if(rt.y===K.y&&(ot.x<=rt.x&&rt.x<=K.x||K.x<=rt.x&&rt.x<=ot.x))return!0}return Ct}var s=To.isClockWise,l=this.subPaths;if(l.length===0)return[];if(e===!0)return i(l);if(e=[],l.length===1){var d=l[0],p=new Qn;return p.curves=d.curves,e.push(p),e}var _=!s(l[0].getPoints());_=t?!_:_,p=[];var T=[],A=[],L=0;T[L]=void 0,A[L]=[];for(var B=0,H=l.length;B<H;B++){d=l[B];var q=d.getPoints(),$=s(q);($=t?!$:$)?(!_&&T[L]&&L++,T[L]={s:new Qn,p:q},T[L].s.curves=d.curves,_&&L++,A[L]=[]):A[L].push({h:d,p:q[0]})}if(!T[0])return i(l);if(1<T.length){for(B=!1,t=[],s=0,l=T.length;s<l;s++)p[s]=[];for(s=0,l=T.length;s<l;s++)for(d=A[s],$=0;$<d.length;$++){for(_=d[$],L=!0,q=0;q<T.length;q++)n(_.p,T[q].p)&&(s!==q&&t.push({froms:s,tos:q,hole:$}),L?(L=!1,p[q].push(_)):B=!0);L&&p[s].push(_)}0<t.length&&(B||(A=p))}for(B=0,s=T.length;B<s;B++)for(p=T[B].s,e.push(p),t=A[B],l=0,d=t.length;l<d;l++)p.holes.push(t[l].h);return e}}),Object.assign(Uh.prototype,{isFont:!0,generateShapes:function(t,e){e===void 0&&(e=100);var i=[],n=e;e=this.data;var s=Array.from?Array.from(t):String(t).split("");n/=e.resolution;var l=(e.boundingBox.yMax-e.boundingBox.yMin+e.underlineThickness)*n;t=[];for(var d=0,p=0,_=0;_<s.length;_++){var T=s[_];if(T===`
|
|
2571
|
+
`)d=0,p-=l;else{var A=n,L=d,B=p;if(T=e.glyphs[T]||e.glyphs["?"]){var H=new nh;if(T.o)for(var q=T._cachedOutline||(T._cachedOutline=T.o.split(" ")),$=0,rt=q.length;$<rt;)switch(q[$++]){case"m":var xt=q[$++]*A+L,gt=q[$++]*A+B;H.moveTo(xt,gt);break;case"l":xt=q[$++]*A+L,gt=q[$++]*A+B,H.lineTo(xt,gt);break;case"q":var Ct=q[$++]*A+L,wt=q[$++]*A+B,Vt=q[$++]*A+L,K=q[$++]*A+B;H.quadraticCurveTo(Vt,K,Ct,wt);break;case"b":Ct=q[$++]*A+L,wt=q[$++]*A+B,Vt=q[$++]*A+L,K=q[$++]*A+B,xt=q[$++]*A+L,gt=q[$++]*A+B,H.bezierCurveTo(Vt,K,xt,gt,Ct,wt)}A={offsetX:T.ha*A,path:H}}else A=void 0;d+=A.offsetX,t.push(A.path)}}for(e=0,s=t.length;e<s;e++)Array.prototype.push.apply(i,t[e].toShapes());return i}}),Object.assign(Lu.prototype,{load:function(t,e,i,n){var s=this,l=new Lt(this.manager);l.setPath(this.path),l.load(t,function(d){try{var p=JSON.parse(d)}catch{p=JSON.parse(d.substring(65,d.length-2))}d=s.parse(p),e&&e(d)},i,n)},parse:function(t){return new Uh(t)},setPath:function(t){return this.path=t,this}});var ch,$h={getContext:function(){return ch===void 0&&(ch=new(window.AudioContext||window.webkitAudioContext)),ch},setContext:function(t){ch=t}};Object.assign(vn.prototype,{load:function(t,e,i,n){var s=new Lt(this.manager);s.setResponseType("arraybuffer"),s.setPath(this.path),s.load(t,function(l){l=l.slice(0),$h.getContext().decodeAudioData(l,function(d){e(d)})},i,n)},setPath:function(t){return this.path=t,this}}),Object.assign(Vn.prototype,{update:function(){var t,e,i,n,s,l,d,p,_=new c,T=new c;return function(A){if(t!==this||e!==A.focus||i!==A.fov||n!==A.aspect*this.aspect||s!==A.near||l!==A.far||d!==A.zoom||p!==this.eyeSep){t=this,e=A.focus,i=A.fov,n=A.aspect*this.aspect,s=A.near,l=A.far,d=A.zoom;var L=A.projectionMatrix.clone();p=this.eyeSep/2;var B=p*s/e,H=s*Math.tan(di.DEG2RAD*i*.5)/d;T.elements[12]=-p,_.elements[12]=p;var q=-H*n+B,$=H*n+B;L.elements[0]=2*s/($-q),L.elements[8]=($+q)/($-q),this.cameraL.projectionMatrix.copy(L),q=-H*n-B,$=H*n-B,L.elements[0]=2*s/($-q),L.elements[8]=($+q)/($-q),this.cameraR.projectionMatrix.copy(L)}this.cameraL.matrixWorld.copy(A.matrixWorld).multiply(T),this.cameraR.matrixWorld.copy(A.matrixWorld).multiply(_)}}()}),cl.prototype=Object.create(N.prototype),cl.prototype.constructor=cl,Object.assign(Gh.prototype,{start:function(){this.oldTime=this.startTime=(typeof performance>"u"?Date:performance).now(),this.elapsedTime=0,this.running=!0},stop:function(){this.getElapsedTime(),this.autoStart=this.running=!1},getElapsedTime:function(){return this.getDelta(),this.elapsedTime},getDelta:function(){var t=0;if(this.autoStart&&!this.running)return this.start(),0;if(this.running){var e=(typeof performance>"u"?Date:performance).now();t=(e-this.oldTime)/1e3,this.oldTime=e,this.elapsedTime+=t}return t}}),rh.prototype=Object.assign(Object.create(N.prototype),{constructor:rh,getInput:function(){return this.gain},removeFilter:function(){return this.filter!==null&&(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination),this.gain.connect(this.context.destination),this.filter=null),this},getFilter:function(){return this.filter},setFilter:function(t){return this.filter!==null?(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination)):this.gain.disconnect(this.context.destination),this.filter=t,this.gain.connect(this.filter),this.filter.connect(this.context.destination),this},getMasterVolume:function(){return this.gain.gain.value},setMasterVolume:function(t){return this.gain.gain.setTargetAtTime(t,this.context.currentTime,.01),this},updateMatrixWorld:function(){var t=new u,e=new f,i=new u,n=new u,s=new Gh;return function(l){N.prototype.updateMatrixWorld.call(this,l),l=this.context.listener;var d=this.up;if(this.timeDelta=s.getDelta(),this.matrixWorld.decompose(t,e,i),n.set(0,0,-1).applyQuaternion(e),l.positionX){var p=this.context.currentTime+this.timeDelta;l.positionX.linearRampToValueAtTime(t.x,p),l.positionY.linearRampToValueAtTime(t.y,p),l.positionZ.linearRampToValueAtTime(t.z,p),l.forwardX.linearRampToValueAtTime(n.x,p),l.forwardY.linearRampToValueAtTime(n.y,p),l.forwardZ.linearRampToValueAtTime(n.z,p),l.upX.linearRampToValueAtTime(d.x,p),l.upY.linearRampToValueAtTime(d.y,p),l.upZ.linearRampToValueAtTime(d.z,p)}else l.setPosition(t.x,t.y,t.z),l.setOrientation(n.x,n.y,n.z,d.x,d.y,d.z)}}()}),Sa.prototype=Object.assign(Object.create(N.prototype),{constructor:Sa,getOutput:function(){return this.gain},setNodeSource:function(t){return this.hasPlaybackControl=!1,this.sourceType="audioNode",this.source=t,this.connect(),this},setMediaElementSource:function(t){return this.hasPlaybackControl=!1,this.sourceType="mediaNode",this.source=this.context.createMediaElementSource(t),this.connect(),this},setBuffer:function(t){return this.buffer=t,this.sourceType="buffer",this.autoplay&&this.play(),this},play:function(){if(this.isPlaying!==!0){if(this.hasPlaybackControl!==!1){var t=this.context.createBufferSource();return t.buffer=this.buffer,t.loop=this.loop,t.onended=this.onEnded.bind(this),t.playbackRate.setValueAtTime(this.playbackRate,this.startTime),this.startTime=this.context.currentTime,t.start(this.startTime,this.offset),this.isPlaying=!0,this.source=t,this.connect()}}},pause:function(){if(this.hasPlaybackControl!==!1)return this.isPlaying===!0&&(this.source.stop(),this.source.onended=null,this.offset+=(this.context.currentTime-this.startTime)*this.playbackRate,this.isPlaying=!1),this},stop:function(){if(this.hasPlaybackControl!==!1)return this.source.stop(),this.source.onended=null,this.offset=0,this.isPlaying=!1,this},connect:function(){if(0<this.filters.length){this.source.connect(this.filters[0]);for(var t=1,e=this.filters.length;t<e;t++)this.filters[t-1].connect(this.filters[t]);this.filters[this.filters.length-1].connect(this.getOutput())}else this.source.connect(this.getOutput());return this},disconnect:function(){if(0<this.filters.length){this.source.disconnect(this.filters[0]);for(var t=1,e=this.filters.length;t<e;t++)this.filters[t-1].disconnect(this.filters[t]);this.filters[this.filters.length-1].disconnect(this.getOutput())}else this.source.disconnect(this.getOutput());return this},getFilters:function(){return this.filters},setFilters:function(t){return t||(t=[]),this.isPlaying===!0?(this.disconnect(),this.filters=t,this.connect()):this.filters=t,this},getFilter:function(){return this.getFilters()[0]},setFilter:function(t){return this.setFilters(t?[t]:[])},setPlaybackRate:function(t){if(this.hasPlaybackControl!==!1)return this.playbackRate=t,this.isPlaying===!0&&this.source.playbackRate.setValueAtTime(this.playbackRate,this.context.currentTime),this},getPlaybackRate:function(){return this.playbackRate},onEnded:function(){this.isPlaying=!1},getLoop:function(){return this.hasPlaybackControl===!1?!1:this.loop},setLoop:function(t){if(this.hasPlaybackControl!==!1)return this.loop=t,this.isPlaying===!0&&(this.source.loop=this.loop),this},getVolume:function(){return this.gain.gain.value},setVolume:function(t){return this.gain.gain.setTargetAtTime(t,this.context.currentTime,.01),this}}),fl.prototype=Object.assign(Object.create(Sa.prototype),{constructor:fl,getOutput:function(){return this.panner},getRefDistance:function(){return this.panner.refDistance},setRefDistance:function(t){return this.panner.refDistance=t,this},getRolloffFactor:function(){return this.panner.rolloffFactor},setRolloffFactor:function(t){return this.panner.rolloffFactor=t,this},getDistanceModel:function(){return this.panner.distanceModel},setDistanceModel:function(t){return this.panner.distanceModel=t,this},getMaxDistance:function(){return this.panner.maxDistance},setMaxDistance:function(t){return this.panner.maxDistance=t,this},setDirectionalCone:function(t,e,i){return this.panner.coneInnerAngle=t,this.panner.coneOuterAngle=e,this.panner.coneOuterGain=i,this},updateMatrixWorld:function(){var t=new u,e=new f,i=new u,n=new u;return function(s){if(N.prototype.updateMatrixWorld.call(this,s),s=this.panner,this.matrixWorld.decompose(t,e,i),n.set(0,0,1).applyQuaternion(e),s.positionX){var l=this.context.currentTime+this.listener.timeDelta;s.positionX.linearRampToValueAtTime(t.x,l),s.positionY.linearRampToValueAtTime(t.y,l),s.positionZ.linearRampToValueAtTime(t.z,l),s.orientationX.linearRampToValueAtTime(n.x,l),s.orientationY.linearRampToValueAtTime(n.y,l),s.orientationZ.linearRampToValueAtTime(n.z,l)}else s.setPosition(t.x,t.y,t.z),s.setOrientation(n.x,n.y,n.z)}}()}),Object.assign(Bs.prototype,{getFrequencyData:function(){return this.analyser.getByteFrequencyData(this.data),this.data},getAverageFrequency:function(){for(var t=0,e=this.getFrequencyData(),i=0;i<e.length;i++)t+=e[i];return t/e.length}}),Object.assign(dl.prototype,{accumulate:function(t,e){var i=this.buffer,n=this.valueSize;t=t*n+n;var s=this.cumulativeWeight;if(s===0){for(s=0;s!==n;++s)i[t+s]=i[s];s=e}else s+=e,this._mixBufferRegion(i,t,0,e/s,n);this.cumulativeWeight=s},apply:function(t){var e=this.valueSize,i=this.buffer;t=t*e+e;var n=this.cumulativeWeight,s=this.binding;this.cumulativeWeight=0,1>n&&this._mixBufferRegion(i,t,3*e,1-n,e),n=e;for(var l=e+e;n!==l;++n)if(i[n]!==i[n+e]){s.setValue(i,t);break}},saveOriginalState:function(){var t=this.buffer,e=this.valueSize,i=3*e;this.binding.getValue(t,i);for(var n=e;n!==i;++n)t[n]=t[i+n%e];this.cumulativeWeight=0},restoreOriginalState:function(){this.binding.setValue(this.buffer,3*this.valueSize)},_select:function(t,e,i,n,s){if(.5<=n)for(n=0;n!==s;++n)t[e+n]=t[i+n]},_slerp:function(t,e,i,n){f.slerpFlat(t,e,t,e,t,i,n)},_lerp:function(t,e,i,n,s){for(var l=1-n,d=0;d!==s;++d){var p=e+d;t[p]=t[p]*l+t[i+d]*n}}}),Object.assign(Ns.prototype,{getValue:function(t,e){this.bind();var i=this._bindings[this._targetGroup.nCachedObjects_];i!==void 0&&i.getValue(t,e)},setValue:function(t,e){for(var i=this._bindings,n=this._targetGroup.nCachedObjects_,s=i.length;n!==s;++n)i[n].setValue(t,e)},bind:function(){for(var t=this._bindings,e=this._targetGroup.nCachedObjects_,i=t.length;e!==i;++e)t[e].bind()},unbind:function(){for(var t=this._bindings,e=this._targetGroup.nCachedObjects_,i=t.length;e!==i;++e)t[e].unbind()}}),Object.assign(En,{Composite:Ns,create:function(t,e,i){return t&&t.isAnimationObjectGroup?new En.Composite(t,e,i):new En(t,e,i)},sanitizeNodeName:function(){var t=/[\[\]\.:\/]/g;return function(e){return e.replace(/\s/g,"_").replace(t,"")}}(),parseTrackName:function(){var t="[^"+"\\[\\]\\.:\\/".replace("\\.","")+"]",e=/((?:WC+[\/:])*)/.source.replace("WC","[^\\[\\]\\.:\\/]");t=/(WCOD+)?/.source.replace("WCOD",t);var i=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC","[^\\[\\]\\.:\\/]"),n=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC","[^\\[\\]\\.:\\/]"),s=new RegExp("^"+e+t+i+n+"$"),l=["material","materials","bones"];return function(d){var p=s.exec(d);if(!p)throw Error("PropertyBinding: Cannot parse trackName: "+d);p={nodeName:p[2],objectName:p[3],objectIndex:p[4],propertyName:p[5],propertyIndex:p[6]};var _=p.nodeName&&p.nodeName.lastIndexOf(".");if(_!==void 0&&_!==-1){var T=p.nodeName.substring(_+1);l.indexOf(T)!==-1&&(p.nodeName=p.nodeName.substring(0,_),p.objectName=T)}if(p.propertyName===null||p.propertyName.length===0)throw Error("PropertyBinding: can not parse propertyName from trackName: "+d);return p}}(),findNode:function(t,e){if(!e||e===""||e==="root"||e==="."||e===-1||e===t.name||e===t.uuid)return t;if(t.skeleton){var i=t.skeleton.getBoneByName(e);if(i!==void 0)return i}if(t.children){var n=function(s){for(var l=0;l<s.length;l++){var d=s[l];if(d.name===e||d.uuid===e||(d=n(d.children)))return d}return null};if(t=n(t.children))return t}return null}}),Object.assign(En.prototype,{_getValue_unavailable:function(){},_setValue_unavailable:function(){},BindingType:{Direct:0,EntireArray:1,ArrayElement:2,HasFromToArray:3},Versioning:{None:0,NeedsUpdate:1,MatrixWorldNeedsUpdate:2},GetterByBindingType:[function(t,e){t[e]=this.node[this.propertyName]},function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)t[e++]=i[n]},function(t,e){t[e]=this.resolvedProperty[this.propertyIndex]},function(t,e){this.resolvedProperty.toArray(t,e)}],SetterByBindingTypeAndVersioning:[[function(t,e){this.targetObject[this.propertyName]=t[e]},function(t,e){this.targetObject[this.propertyName]=t[e],this.targetObject.needsUpdate=!0},function(t,e){this.targetObject[this.propertyName]=t[e],this.targetObject.matrixWorldNeedsUpdate=!0}],[function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)i[n]=t[e++]},function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)i[n]=t[e++];this.targetObject.needsUpdate=!0},function(t,e){for(var i=this.resolvedProperty,n=0,s=i.length;n!==s;++n)i[n]=t[e++];this.targetObject.matrixWorldNeedsUpdate=!0}],[function(t,e){this.resolvedProperty[this.propertyIndex]=t[e]},function(t,e){this.resolvedProperty[this.propertyIndex]=t[e],this.targetObject.needsUpdate=!0},function(t,e){this.resolvedProperty[this.propertyIndex]=t[e],this.targetObject.matrixWorldNeedsUpdate=!0}],[function(t,e){this.resolvedProperty.fromArray(t,e)},function(t,e){this.resolvedProperty.fromArray(t,e),this.targetObject.needsUpdate=!0},function(t,e){this.resolvedProperty.fromArray(t,e),this.targetObject.matrixWorldNeedsUpdate=!0}]],getValue:function(t,e){this.bind(),this.getValue(t,e)},setValue:function(t,e){this.bind(),this.setValue(t,e)},bind:function(){var t=this.node,e=this.parsedPath,i=e.objectName,n=e.propertyName,s=e.propertyIndex;if(t||(this.node=t=En.findNode(this.rootNode,e.nodeName)||this.rootNode),this.getValue=this._getValue_unavailable,this.setValue=this._setValue_unavailable,t){if(i){var l=e.objectIndex;switch(i){case"materials":if(!t.material||!t.material.materials)return;t=t.material.materials;break;case"bones":if(!t.skeleton)return;for(t=t.skeleton.bones,i=0;i<t.length;i++)if(t[i].name===l){l=i;break}break;default:if(t[i]===void 0)return;t=t[i]}if(l!==void 0){if(t[l]===void 0)return;t=t[l]}}if(l=t[n],l!==void 0){if(e=this.Versioning.None,this.targetObject=t,t.needsUpdate!==void 0?e=this.Versioning.NeedsUpdate:t.matrixWorldNeedsUpdate!==void 0&&(e=this.Versioning.MatrixWorldNeedsUpdate),i=this.BindingType.Direct,s!==void 0){if(n==="morphTargetInfluences"){if(!t.geometry)return;if(t.geometry.isBufferGeometry){if(!t.geometry.morphAttributes)return;for(i=0;i<this.node.geometry.morphAttributes.position.length;i++)if(t.geometry.morphAttributes.position[i].name===s){s=i;break}}else{if(!t.geometry.morphTargets)return;for(i=0;i<this.node.geometry.morphTargets.length;i++)if(t.geometry.morphTargets[i].name===s){s=i;break}}}i=this.BindingType.ArrayElement,this.resolvedProperty=l,this.propertyIndex=s}else l.fromArray!==void 0&&l.toArray!==void 0?(i=this.BindingType.HasFromToArray,this.resolvedProperty=l):Array.isArray(l)?(i=this.BindingType.EntireArray,this.resolvedProperty=l):this.propertyName=n;this.getValue=this.GetterByBindingType[i],this.setValue=this.SetterByBindingTypeAndVersioning[i][e]}}},unbind:function(){this.node=null,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}}),Object.assign(En.prototype,{_getValue_unbound:En.prototype.getValue,_setValue_unbound:En.prototype.setValue}),Object.assign(Ea.prototype,{isAnimationObjectGroup:!0,add:function(){for(var t=this._objects,e=t.length,i=this.nCachedObjects_,n=this._indicesByUUID,s=this._paths,l=this._parsedPaths,d=this._bindings,p=d.length,_=void 0,T=0,A=arguments.length;T!==A;++T){var L=arguments[T],B=L.uuid,H=n[B];if(H===void 0){H=e++,n[B]=H,t.push(L),B=0;for(var q=p;B!==q;++B)d[B].push(new En(L,s[B],l[B]))}else if(H<i){_=t[H];var $=--i;for(q=t[$],n[q.uuid]=H,t[H]=q,n[B]=$,t[$]=L,B=0,q=p;B!==q;++B){var rt=d[B],xt=rt[H];rt[H]=rt[$],xt===void 0&&(xt=new En(L,s[B],l[B])),rt[$]=xt}}else t[H]}this.nCachedObjects_=i},remove:function(){for(var t=this._objects,e=this.nCachedObjects_,i=this._indicesByUUID,n=this._bindings,s=n.length,l=0,d=arguments.length;l!==d;++l){var p=arguments[l],_=p.uuid,T=i[_];if(T!==void 0&&T>=e){var A=e++,L=t[A];for(i[L.uuid]=T,t[T]=L,i[_]=A,t[A]=p,p=0,_=s;p!==_;++p){L=n[p];var B=L[T];L[T]=L[A],L[A]=B}}}this.nCachedObjects_=e},uncache:function(){for(var t=this._objects,e=t.length,i=this.nCachedObjects_,n=this._indicesByUUID,s=this._bindings,l=s.length,d=0,p=arguments.length;d!==p;++d){var _=arguments[d].uuid,T=n[_];if(T!==void 0)if(delete n[_],T<i){_=--i;var A=t[_],L=--e,B=t[L];for(n[A.uuid]=T,t[T]=A,n[B.uuid]=_,t[_]=B,t.pop(),A=0,B=l;A!==B;++A){var H=s[A],q=H[L];H[T]=H[_],H[_]=q,H.pop()}}else for(L=--e,B=t[L],n[B.uuid]=T,t[T]=B,t.pop(),A=0,B=l;A!==B;++A)H=s[A],H[T]=H[L],H.pop()}this.nCachedObjects_=i},subscribe_:function(t,e){var i=this._bindingsIndicesByPath,n=i[t],s=this._bindings;if(n!==void 0)return s[n];var l=this._paths,d=this._parsedPaths,p=this._objects,_=this.nCachedObjects_,T=Array(p.length);for(n=s.length,i[t]=n,l.push(t),d.push(e),s.push(T),i=_,n=p.length;i!==n;++i)T[i]=new En(p[i],t,e);return T},unsubscribe_:function(t){var e=this._bindingsIndicesByPath,i=e[t];if(i!==void 0){var n=this._paths,s=this._parsedPaths,l=this._bindings,d=l.length-1,p=l[d];e[t[d]]=i,l[i]=p,l.pop(),s[i]=s[d],s.pop(),n[i]=n[d],n.pop()}}}),Object.assign(pl.prototype,{play:function(){return this._mixer._activateAction(this),this},stop:function(){return this._mixer._deactivateAction(this),this.reset()},reset:function(){return this.paused=!1,this.enabled=!0,this.time=0,this._loopCount=-1,this._startTime=null,this.stopFading().stopWarping()},isRunning:function(){return this.enabled&&!this.paused&&this.timeScale!==0&&this._startTime===null&&this._mixer._isActiveAction(this)},isScheduled:function(){return this._mixer._isActiveAction(this)},startAt:function(t){return this._startTime=t,this},setLoop:function(t,e){return this.loop=t,this.repetitions=e,this},setEffectiveWeight:function(t){return this.weight=t,this._effectiveWeight=this.enabled?t:0,this.stopFading()},getEffectiveWeight:function(){return this._effectiveWeight},fadeIn:function(t){return this._scheduleFading(t,0,1)},fadeOut:function(t){return this._scheduleFading(t,1,0)},crossFadeFrom:function(t,e,i){if(t.fadeOut(e),this.fadeIn(e),i){i=this._clip.duration;var n=t._clip.duration,s=i/n;t.warp(1,n/i,e),this.warp(s,1,e)}return this},crossFadeTo:function(t,e,i){return t.crossFadeFrom(this,e,i)},stopFading:function(){var t=this._weightInterpolant;return t!==null&&(this._weightInterpolant=null,this._mixer._takeBackControlInterpolant(t)),this},setEffectiveTimeScale:function(t){return this.timeScale=t,this._effectiveTimeScale=this.paused?0:t,this.stopWarping()},getEffectiveTimeScale:function(){return this._effectiveTimeScale},setDuration:function(t){return this.timeScale=this._clip.duration/t,this.stopWarping()},syncWith:function(t){return this.time=t.time,this.timeScale=t.timeScale,this.stopWarping()},halt:function(t){return this.warp(this._effectiveTimeScale,0,t)},warp:function(t,e,i){var n=this._mixer,s=n.time,l=this._timeScaleInterpolant,d=this.timeScale;return l===null&&(this._timeScaleInterpolant=l=n._lendControlInterpolant()),n=l.parameterPositions,l=l.sampleValues,n[0]=s,n[1]=s+i,l[0]=t/d,l[1]=e/d,this},stopWarping:function(){var t=this._timeScaleInterpolant;return t!==null&&(this._timeScaleInterpolant=null,this._mixer._takeBackControlInterpolant(t)),this},getMixer:function(){return this._mixer},getClip:function(){return this._clip},getRoot:function(){return this._localRoot||this._mixer._root},_update:function(t,e,i,n){if(this.enabled){var s=this._startTime;if(s!==null){if(e=(t-s)*i,0>e||i===0)return;this._startTime=null,e*=i}if(e*=this._updateTimeScale(t),i=this._updateTime(e),t=this._updateWeight(t),0<t){e=this._interpolants,s=this._propertyBindings;for(var l=0,d=e.length;l!==d;++l)e[l].evaluate(i),s[l].accumulate(n,t)}}else this._updateWeight(t)},_updateWeight:function(t){var e=0;if(this.enabled){e=this.weight;var i=this._weightInterpolant;if(i!==null){var n=i.evaluate(t)[0];e*=n,t>i.parameterPositions[1]&&(this.stopFading(),n===0&&(this.enabled=!1))}}return this._effectiveWeight=e},_updateTimeScale:function(t){var e=0;if(!this.paused){e=this.timeScale;var i=this._timeScaleInterpolant;if(i!==null){var n=i.evaluate(t)[0];e*=n,t>i.parameterPositions[1]&&(this.stopWarping(),e===0?this.paused=!0:this.timeScale=e)}}return this._effectiveTimeScale=e},_updateTime:function(t){var e=this.time+t,i=this._clip.duration,n=this.loop,s=this._loopCount,l=n===2202;if(t===0)return s===-1?e:l&&(s&1)===1?i-e:e;if(n===2200)t:{if(s===-1&&(this._loopCount=0,this._setEndings(!0,!0,!1)),e>=i)e=i;else if(0>e)e=0;else break t;this.clampWhenFinished?this.paused=!0:this.enabled=!1,this._mixer.dispatchEvent({type:"finished",action:this,direction:0>t?-1:1})}else{if(s===-1&&(0<=t?(s=0,this._setEndings(!0,this.repetitions===0,l)):this._setEndings(this.repetitions===0,!0,l)),e>=i||0>e){n=Math.floor(e/i),e-=i*n,s+=Math.abs(n);var d=this.repetitions-s;0>=d?(this.clampWhenFinished?this.paused=!0:this.enabled=!1,e=0<t?i:0,this._mixer.dispatchEvent({type:"finished",action:this,direction:0<t?1:-1})):(d===1?(t=0>t,this._setEndings(t,!t,l)):this._setEndings(!1,!1,l),this._loopCount=s,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:n}))}if(l&&(s&1)===1)return this.time=e,i-e}return this.time=e},_setEndings:function(t,e,i){var n=this._interpolantSettings;i?(n.endingStart=2401,n.endingEnd=2401):(n.endingStart=t?this.zeroSlopeAtStart?2401:2400:2402,n.endingEnd=e?this.zeroSlopeAtEnd?2401:2400:2402)},_scheduleFading:function(t,e,i){var n=this._mixer,s=n.time,l=this._weightInterpolant;return l===null&&(this._weightInterpolant=l=n._lendControlInterpolant()),n=l.parameterPositions,l=l.sampleValues,n[0]=s,l[0]=e,n[1]=s+t,l[1]=i,this}}),os.prototype=Object.assign(Object.create(a.prototype),{constructor:os,_bindAction:function(t,e){var i=t._localRoot||this._root,n=t._clip.tracks,s=n.length,l=t._propertyBindings;t=t._interpolants;var d=i.uuid,p=this._bindingsByRootAndName,_=p[d];for(_===void 0&&(_={},p[d]=_),p=0;p!==s;++p){var T=n[p],A=T.name,L=_[A];if(L===void 0){if(L=l[p],L!==void 0){L._cacheIndex===null&&(++L.referenceCount,this._addInactiveBinding(L,d,A));continue}L=new dl(En.create(i,A,e&&e._propertyBindings[p].binding.parsedPath),T.ValueTypeName,T.getValueSize()),++L.referenceCount,this._addInactiveBinding(L,d,A)}l[p]=L,t[p].resultBuffer=L.buffer}},_activateAction:function(t){if(!this._isActiveAction(t)){if(t._cacheIndex===null){var e=(t._localRoot||this._root).uuid,i=t._clip.uuid,n=this._actionsByClip[i];this._bindAction(t,n&&n.knownActions[0]),this._addInactiveAction(t,i,e)}for(e=t._propertyBindings,i=0,n=e.length;i!==n;++i){var s=e[i];s.useCount++===0&&(this._lendBinding(s),s.saveOriginalState())}this._lendAction(t)}},_deactivateAction:function(t){if(this._isActiveAction(t)){for(var e=t._propertyBindings,i=0,n=e.length;i!==n;++i){var s=e[i];--s.useCount===0&&(s.restoreOriginalState(),this._takeBackBinding(s))}this._takeBackAction(t)}},_initMemoryManager:function(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;var t=this;this.stats={actions:{get total(){return t._actions.length},get inUse(){return t._nActiveActions}},bindings:{get total(){return t._bindings.length},get inUse(){return t._nActiveBindings}},controlInterpolants:{get total(){return t._controlInterpolants.length},get inUse(){return t._nActiveControlInterpolants}}}},_isActiveAction:function(t){return t=t._cacheIndex,t!==null&&t<this._nActiveActions},_addInactiveAction:function(t,e,i){var n=this._actions,s=this._actionsByClip,l=s[e];l===void 0?(l={knownActions:[t],actionByRoot:{}},t._byClipCacheIndex=0,s[e]=l):(e=l.knownActions,t._byClipCacheIndex=e.length,e.push(t)),t._cacheIndex=n.length,n.push(t),l.actionByRoot[i]=t},_removeInactiveAction:function(t){var e=this._actions,i=e[e.length-1],n=t._cacheIndex;i._cacheIndex=n,e[n]=i,e.pop(),t._cacheIndex=null,e=t._clip.uuid,i=this._actionsByClip,n=i[e];var s=n.knownActions,l=s[s.length-1],d=t._byClipCacheIndex;l._byClipCacheIndex=d,s[d]=l,s.pop(),t._byClipCacheIndex=null,delete n.actionByRoot[(t._localRoot||this._root).uuid],s.length===0&&delete i[e],this._removeInactiveBindingsForAction(t)},_removeInactiveBindingsForAction:function(t){t=t._propertyBindings;for(var e=0,i=t.length;e!==i;++e){var n=t[e];--n.referenceCount===0&&this._removeInactiveBinding(n)}},_lendAction:function(t){var e=this._actions,i=t._cacheIndex,n=this._nActiveActions++,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_takeBackAction:function(t){var e=this._actions,i=t._cacheIndex,n=--this._nActiveActions,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_addInactiveBinding:function(t,e,i){var n=this._bindingsByRootAndName,s=n[e],l=this._bindings;s===void 0&&(s={},n[e]=s),s[i]=t,t._cacheIndex=l.length,l.push(t)},_removeInactiveBinding:function(t){var e=this._bindings,i=t.binding,n=i.rootNode.uuid;i=i.path;var s=this._bindingsByRootAndName,l=s[n],d=e[e.length-1];t=t._cacheIndex,d._cacheIndex=t,e[t]=d,e.pop(),delete l[i];t:{for(var p in l)break t;delete s[n]}},_lendBinding:function(t){var e=this._bindings,i=t._cacheIndex,n=this._nActiveBindings++,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_takeBackBinding:function(t){var e=this._bindings,i=t._cacheIndex,n=--this._nActiveBindings,s=e[n];t._cacheIndex=n,e[n]=t,s._cacheIndex=i,e[i]=s},_lendControlInterpolant:function(){var t=this._controlInterpolants,e=this._nActiveControlInterpolants++,i=t[e];return i===void 0&&(i=new Dr(new Float32Array(2),new Float32Array(2),1,this._controlInterpolantsResultBuffer),i.__cacheIndex=e,t[e]=i),i},_takeBackControlInterpolant:function(t){var e=this._controlInterpolants,i=t.__cacheIndex,n=--this._nActiveControlInterpolants,s=e[n];t.__cacheIndex=n,e[n]=t,s.__cacheIndex=i,e[i]=s},_controlInterpolantsResultBuffer:new Float32Array(1),clipAction:function(t,e){var i=e||this._root,n=i.uuid;i=typeof t=="string"?_r.findByName(i,t):t,t=i!==null?i.uuid:t;var s=this._actionsByClip[t],l=null;if(s!==void 0){if(l=s.actionByRoot[n],l!==void 0)return l;l=s.knownActions[0],i===null&&(i=l._clip)}return i===null?null:(e=new pl(this,i,e),this._bindAction(e,l),this._addInactiveAction(e,t,n),e)},existingAction:function(t,e){var i=e||this._root;return e=i.uuid,i=typeof t=="string"?_r.findByName(i,t):t,t=this._actionsByClip[i?i.uuid:t],t!==void 0&&t.actionByRoot[e]||null},stopAllAction:function(){for(var t=this._actions,e=this._nActiveActions,i=this._bindings,n=this._nActiveBindings,s=this._nActiveBindings=this._nActiveActions=0;s!==e;++s)t[s].reset();for(s=0;s!==n;++s)i[s].useCount=0;return this},update:function(t){t*=this.timeScale;for(var e=this._actions,i=this._nActiveActions,n=this.time+=t,s=Math.sign(t),l=this._accuIndex^=1,d=0;d!==i;++d)e[d]._update(n,t,s,l);for(t=this._bindings,e=this._nActiveBindings,d=0;d!==e;++d)t[d].apply(l);return this},getRoot:function(){return this._root},uncacheClip:function(t){var e=this._actions;t=t.uuid;var i=this._actionsByClip,n=i[t];if(n!==void 0){n=n.knownActions;for(var s=0,l=n.length;s!==l;++s){var d=n[s];this._deactivateAction(d);var p=d._cacheIndex,_=e[e.length-1];d._cacheIndex=null,d._byClipCacheIndex=null,_._cacheIndex=p,e[p]=_,e.pop(),this._removeInactiveBindingsForAction(d)}delete i[t]}},uncacheRoot:function(t){t=t.uuid;var e=this._actionsByClip;for(n in e){var i=e[n].actionByRoot[t];i!==void 0&&(this._deactivateAction(i),this._removeInactiveAction(i))}var n=this._bindingsByRootAndName[t];if(n!==void 0)for(var s in n)t=n[s],t.restoreOriginalState(),this._removeInactiveBinding(t)},uncacheAction:function(t,e){t=this.existingAction(t,e),t!==null&&(this._deactivateAction(t),this._removeInactiveAction(t))}}),oh.prototype.clone=function(){return new oh(this.value.clone===void 0?this.value:this.value.clone())},Hh.prototype=Object.assign(Object.create(Ft.prototype),{constructor:Hh,isInstancedBufferGeometry:!0,copy:function(t){return Ft.prototype.copy.call(this,t),this.maxInstancedCount=t.maxInstancedCount,this},clone:function(){return new this.constructor().copy(this)}}),Vh.prototype=Object.assign(Object.create(ki.prototype),{constructor:Vh,isInstancedInterleavedBuffer:!0,copy:function(t){return ki.prototype.copy.call(this,t),this.meshPerAttribute=t.meshPerAttribute,this}}),Wh.prototype=Object.assign(Object.create(J.prototype),{constructor:Wh,isInstancedBufferAttribute:!0,copy:function(t){return J.prototype.copy.call(this,t),this.meshPerAttribute=t.meshPerAttribute,this}}),Object.assign(Ru.prototype,{linePrecision:1,set:function(t,e){this.ray.set(t,e)},setFromCamera:function(t,e){e&&e.isPerspectiveCamera?(this.ray.origin.setFromMatrixPosition(e.matrixWorld),this.ray.direction.set(t.x,t.y,.5).unproject(e).sub(this.ray.origin).normalize()):e&&e.isOrthographicCamera&&(this.ray.origin.set(t.x,t.y,(e.near+e.far)/(e.near-e.far)).unproject(e),this.ray.direction.set(0,0,-1).transformDirection(e.matrixWorld))},intersectObject:function(t,e,i){return i=i||[],Fs(t,this,i,e),i.sort(ml),i},intersectObjects:function(t,e,i){if(i=i||[],Array.isArray(t)===!1)return i;for(var n=0,s=t.length;n<s;n++)Fs(t[n],this,i,e);return i.sort(ml),i}}),Object.assign(jh.prototype,{set:function(t,e,i){return this.radius=t,this.phi=e,this.theta=i,this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.radius=t.radius,this.phi=t.phi,this.theta=t.theta,this},makeSafe:function(){return this.phi=Math.max(1e-6,Math.min(Math.PI-1e-6,this.phi)),this},setFromVector3:function(t){return this.setFromCartesianCoords(t.x,t.y,t.z)},setFromCartesianCoords:function(t,e,i){return this.radius=Math.sqrt(t*t+e*e+i*i),this.radius===0?this.phi=this.theta=0:(this.theta=Math.atan2(t,i),this.phi=Math.acos(di.clamp(e/this.radius,-1,1))),this}}),Object.assign(it.prototype,{set:function(t,e,i){return this.radius=t,this.theta=e,this.y=i,this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.radius=t.radius,this.theta=t.theta,this.y=t.y,this},setFromVector3:function(t){return this.setFromCartesianCoords(t.x,t.y,t.z)},setFromCartesianCoords:function(t,e,i){return this.radius=Math.sqrt(t*t+i*i),this.theta=Math.atan2(t,i),this.y=e,this}}),Object.assign(ss.prototype,{set:function(t,e){return this.min.copy(t),this.max.copy(e),this},setFromPoints:function(t){this.makeEmpty();for(var e=0,i=t.length;e<i;e++)this.expandByPoint(t[e]);return this},setFromCenterAndSize:function(){var t=new o;return function(e,i){return i=t.copy(i).multiplyScalar(.5),this.min.copy(e).sub(i),this.max.copy(e).add(i),this}}(),clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.min.copy(t.min),this.max.copy(t.max),this},makeEmpty:function(){return this.min.x=this.min.y=1/0,this.max.x=this.max.y=-1/0,this},isEmpty:function(){return this.max.x<this.min.x||this.max.y<this.min.y},getCenter:function(t){return t===void 0&&(t=new o),this.isEmpty()?t.set(0,0):t.addVectors(this.min,this.max).multiplyScalar(.5)},getSize:function(t){return t===void 0&&(t=new o),this.isEmpty()?t.set(0,0):t.subVectors(this.max,this.min)},expandByPoint:function(t){return this.min.min(t),this.max.max(t),this},expandByVector:function(t){return this.min.sub(t),this.max.add(t),this},expandByScalar:function(t){return this.min.addScalar(-t),this.max.addScalar(t),this},containsPoint:function(t){return!(t.x<this.min.x||t.x>this.max.x||t.y<this.min.y||t.y>this.max.y)},containsBox:function(t){return this.min.x<=t.min.x&&t.max.x<=this.max.x&&this.min.y<=t.min.y&&t.max.y<=this.max.y},getParameter:function(t,e){return e===void 0&&(e=new o),e.set((t.x-this.min.x)/(this.max.x-this.min.x),(t.y-this.min.y)/(this.max.y-this.min.y))},intersectsBox:function(t){return!(t.max.x<this.min.x||t.min.x>this.max.x||t.max.y<this.min.y||t.min.y>this.max.y)},clampPoint:function(t,e){return e===void 0&&(e=new o),e.copy(t).clamp(this.min,this.max)},distanceToPoint:function(){var t=new o;return function(e){return t.copy(e).clamp(this.min,this.max).sub(e).length()}}(),intersect:function(t){return this.min.max(t.min),this.max.min(t.max),this},union:function(t){return this.min.min(t.min),this.max.max(t.max),this},translate:function(t){return this.min.add(t),this.max.add(t),this},equals:function(t){return t.min.equals(this.min)&&t.max.equals(this.max)}}),Object.assign(ba.prototype,{set:function(t,e){return this.start.copy(t),this.end.copy(e),this},clone:function(){return new this.constructor().copy(this)},copy:function(t){return this.start.copy(t.start),this.end.copy(t.end),this},getCenter:function(t){return t===void 0&&(t=new u),t.addVectors(this.start,this.end).multiplyScalar(.5)},delta:function(t){return t===void 0&&(t=new u),t.subVectors(this.end,this.start)},distanceSq:function(){return this.start.distanceToSquared(this.end)},distance:function(){return this.start.distanceTo(this.end)},at:function(t,e){return e===void 0&&(e=new u),this.delta(e).multiplyScalar(t).add(this.start)},closestPointToPointParameter:function(){var t=new u,e=new u;return function(i,n){return t.subVectors(i,this.start),e.subVectors(this.end,this.start),i=e.dot(e),i=e.dot(t)/i,n&&(i=di.clamp(i,0,1)),i}}(),closestPointToPoint:function(t,e,i){return t=this.closestPointToPointParameter(t,e),i===void 0&&(i=new u),this.delta(i).multiplyScalar(t).add(this.start)},applyMatrix4:function(t){return this.start.applyMatrix4(t),this.end.applyMatrix4(t),this},equals:function(t){return t.start.equals(this.start)&&t.end.equals(this.end)}}),qn.prototype=Object.create(N.prototype),qn.prototype.constructor=qn,qn.prototype.isImmediateRenderObject=!0,_i.prototype=Object.create(gi.prototype),_i.prototype.constructor=_i,_i.prototype.update=function(){var t=new u,e=new u,i=new m;return function(){var n=["a","b","c"];this.object.updateMatrixWorld(!0),i.getNormalMatrix(this.object.matrixWorld);var s=this.object.matrixWorld,l=this.geometry.attributes.position,d=this.object.geometry;if(d&&d.isGeometry)for(var p=d.vertices,_=d.faces,T=d=0,A=_.length;T<A;T++)for(var L=_[T],B=0,H=L.vertexNormals.length;B<H;B++){var q=L.vertexNormals[B];t.copy(p[L[n[B]]]).applyMatrix4(s),e.copy(q).applyMatrix3(i).normalize().multiplyScalar(this.size).add(t),l.setXYZ(d,t.x,t.y,t.z),d+=1,l.setXYZ(d,e.x,e.y,e.z),d+=1}else if(d&&d.isBufferGeometry)for(n=d.attributes.position,p=d.attributes.normal,B=d=0,H=n.count;B<H;B++)t.set(n.getX(B),n.getY(B),n.getZ(B)).applyMatrix4(s),e.set(p.getX(B),p.getY(B),p.getZ(B)),e.applyMatrix3(i).normalize().multiplyScalar(this.size).add(t),l.setXYZ(d,t.x,t.y,t.z),d+=1,l.setXYZ(d,e.x,e.y,e.z),d+=1;l.needsUpdate=!0}}(),Ca.prototype=Object.create(N.prototype),Ca.prototype.constructor=Ca,Ca.prototype.dispose=function(){this.cone.geometry.dispose(),this.cone.material.dispose()},Ca.prototype.update=function(){var t=new u,e=new u;return function(){this.light.updateMatrixWorld();var i=this.light.distance?this.light.distance:1e3,n=i*Math.tan(this.light.angle);this.cone.scale.set(n,n,i),t.setFromMatrixPosition(this.light.matrixWorld),e.setFromMatrixPosition(this.light.target.matrixWorld),this.cone.lookAt(e.sub(t)),this.color!==void 0?this.cone.material.color.set(this.color):this.cone.material.color.copy(this.light.color)}}(),Aa.prototype=Object.create(gi.prototype),Aa.prototype.constructor=Aa,Aa.prototype.updateMatrixWorld=function(){var t=new u,e=new c,i=new c;return function(n){var s=this.bones,l=this.geometry,d=l.getAttribute("position");i.getInverse(this.root.matrixWorld);for(var p=0,_=0;p<s.length;p++){var T=s[p];T.parent&&T.parent.isBone&&(e.multiplyMatrices(i,T.matrixWorld),t.setFromMatrixPosition(e),d.setXYZ(_,t.x,t.y,t.z),e.multiplyMatrices(i,T.parent.matrixWorld),t.setFromMatrixPosition(e),d.setXYZ(_+1,t.x,t.y,t.z),_+=2)}l.getAttribute("position").needsUpdate=!0,N.prototype.updateMatrixWorld.call(this,n)}}(),kr.prototype=Object.create(pi.prototype),kr.prototype.constructor=kr,kr.prototype.dispose=function(){this.geometry.dispose(),this.material.dispose()},kr.prototype.update=function(){this.color!==void 0?this.material.color.set(this.color):this.material.color.copy(this.light.color)},Pa.prototype=Object.create(N.prototype),Pa.prototype.constructor=Pa,Pa.prototype.dispose=function(){this.children[0].geometry.dispose(),this.children[0].material.dispose()},Pa.prototype.update=function(){var t=.5*this.light.width,e=.5*this.light.height,i=this.line.geometry.attributes.position,n=i.array;n[0]=t,n[1]=-e,n[2]=0,n[3]=t,n[4]=e,n[5]=0,n[6]=-t,n[7]=e,n[8]=0,n[9]=-t,n[10]=-e,n[11]=0,n[12]=t,n[13]=-e,n[14]=0,i.needsUpdate=!0,this.color!==void 0?this.line.material.color.set(this.color):this.line.material.color.copy(this.light.color)},La.prototype=Object.create(N.prototype),La.prototype.constructor=La,La.prototype.dispose=function(){this.children[0].geometry.dispose(),this.children[0].material.dispose()},La.prototype.update=function(){var t=new u,e=new P,i=new P;return function(){var n=this.children[0];if(this.color!==void 0)this.material.color.set(this.color);else{var s=n.geometry.getAttribute("color");e.copy(this.light.color),i.copy(this.light.groundColor);for(var l=0,d=s.count;l<d;l++){var p=l<d/2?e:i;s.setXYZ(l,p.r,p.g,p.b)}s.needsUpdate=!0}n.lookAt(t.setFromMatrixPosition(this.light.matrixWorld).negate())}}(),gl.prototype=Object.create(gi.prototype),gl.prototype.constructor=gl,sh.prototype=Object.create(gi.prototype),sh.prototype.constructor=sh,vl.prototype=Object.create(gi.prototype),vl.prototype.constructor=vl,vl.prototype.update=function(){var t=new u,e=new u,i=new m;return function(){this.object.updateMatrixWorld(!0),i.getNormalMatrix(this.object.matrixWorld);var n=this.object.matrixWorld,s=this.geometry.attributes.position,l=this.object.geometry,d=l.vertices;l=l.faces;for(var p=0,_=0,T=l.length;_<T;_++){var A=l[_],L=A.normal;t.copy(d[A.a]).add(d[A.b]).add(d[A.c]).divideScalar(3).applyMatrix4(n),e.copy(L).applyMatrix3(i).normalize().multiplyScalar(this.size).add(t),s.setXYZ(p,t.x,t.y,t.z),p+=1,s.setXYZ(p,e.x,e.y,e.z),p+=1}s.needsUpdate=!0}}(),dr.prototype=Object.create(N.prototype),dr.prototype.constructor=dr,dr.prototype.dispose=function(){this.lightPlane.geometry.dispose(),this.lightPlane.material.dispose(),this.targetLine.geometry.dispose(),this.targetLine.material.dispose()},dr.prototype.update=function(){var t=new u,e=new u,i=new u;return function(){t.setFromMatrixPosition(this.light.matrixWorld),e.setFromMatrixPosition(this.light.target.matrixWorld),i.subVectors(e,t),this.lightPlane.lookAt(i),this.color!==void 0?(this.lightPlane.material.color.set(this.color),this.targetLine.material.color.set(this.color)):(this.lightPlane.material.color.copy(this.light.color),this.targetLine.material.color.copy(this.light.color)),this.targetLine.lookAt(i),this.targetLine.scale.z=i.length()}}(),yl.prototype=Object.create(gi.prototype),yl.prototype.constructor=yl,yl.prototype.update=function(){function t(l,d,p,_){if(n.set(d,p,_).unproject(s),l=i[l],l!==void 0)for(d=e.getAttribute("position"),p=0,_=l.length;p<_;p++)d.setXYZ(l[p],n.x,n.y,n.z)}var e,i,n=new u,s=new Be;return function(){e=this.geometry,i=this.pointMap,s.projectionMatrix.copy(this.camera.projectionMatrix),t("c",0,0,-1),t("t",0,0,1),t("n1",-1,-1,-1),t("n2",1,-1,-1),t("n3",-1,1,-1),t("n4",1,1,-1),t("f1",-1,-1,1),t("f2",1,-1,1),t("f3",-1,1,1),t("f4",1,1,1),t("u1",.7,1.1,-1),t("u2",-.7,1.1,-1),t("u3",0,2,-1),t("cf1",-1,0,1),t("cf2",1,0,1),t("cf3",0,-1,1),t("cf4",0,1,1),t("cn1",-1,0,-1),t("cn2",1,0,-1),t("cn3",0,-1,-1),t("cn4",0,1,-1),e.getAttribute("position").needsUpdate=!0}}(),zo.prototype=Object.create(gi.prototype),zo.prototype.constructor=zo,zo.prototype.update=function(){var t=new k;return function(e){if(this.object!==void 0&&t.setFromObject(this.object),!t.isEmpty()){e=t.min;var i=t.max,n=this.geometry.attributes.position,s=n.array;s[0]=i.x,s[1]=i.y,s[2]=i.z,s[3]=e.x,s[4]=i.y,s[5]=i.z,s[6]=e.x,s[7]=e.y,s[8]=i.z,s[9]=i.x,s[10]=e.y,s[11]=i.z,s[12]=i.x,s[13]=i.y,s[14]=e.z,s[15]=e.x,s[16]=i.y,s[17]=e.z,s[18]=e.x,s[19]=e.y,s[20]=e.z,s[21]=i.x,s[22]=e.y,s[23]=e.z,n.needsUpdate=!0,this.geometry.computeBoundingSphere()}}}(),zo.prototype.setFromObject=function(t){return this.object=t,this.update(),this},zo.prototype.copy=function(t){return gi.prototype.copy.call(this,t),this.object=t.object,this},zo.prototype.clone=function(){return new this.constructor().copy(this)},_l.prototype=Object.create(gi.prototype),_l.prototype.constructor=_l,_l.prototype.updateMatrixWorld=function(t){var e=this.box;e.isEmpty()||(e.getCenter(this.position),e.getSize(this.scale),this.scale.multiplyScalar(.5),N.prototype.updateMatrixWorld.call(this,t))},xl.prototype=Object.create(ji.prototype),xl.prototype.constructor=xl,xl.prototype.updateMatrixWorld=function(t){var e=-this.plane.constant;1e-8>Math.abs(e)&&(e=1e-8),this.scale.set(.5*this.size,.5*this.size,e),this.children[0].material.side=0>e?1:0,this.lookAt(this.plane.normal),N.prototype.updateMatrixWorld.call(this,t)};var fh,Sl;ko.prototype=Object.create(N.prototype),ko.prototype.constructor=ko,ko.prototype.setDirection=function(){var t=new u,e;return function(i){.99999<i.y?this.quaternion.set(0,0,0,1):-.99999>i.y?this.quaternion.set(1,0,0,0):(t.set(i.z,0,-i.x).normalize(),e=Math.acos(i.y),this.quaternion.setFromAxisAngle(t,e))}}(),ko.prototype.setLength=function(t,e,i){e===void 0&&(e=.2*t),i===void 0&&(i=.2*e),this.line.scale.set(1,Math.max(0,t-e),1),this.line.updateMatrix(),this.cone.scale.set(i,e,i),this.cone.position.y=t,this.cone.updateMatrix()},ko.prototype.setColor=function(t){this.line.material.color.copy(t),this.cone.material.color.copy(t)},ko.prototype.copy=function(t){return N.prototype.copy.call(this,t,!1),this.line.copy(t.line),this.cone.copy(t.cone),this},ko.prototype.clone=function(){return new this.constructor().copy(this)},xr.prototype=Object.create(gi.prototype),xr.prototype.constructor=xr,Ee.create=function(t,e){return t.prototype=Object.create(Ee.prototype),t.prototype.constructor=t,t.prototype.getPoint=e,t},Object.assign(Io.prototype,{createPointsGeometry:function(t){return t=this.getPoints(t),this.createGeometry(t)},createSpacedPointsGeometry:function(t){return t=this.getSpacedPoints(t),this.createGeometry(t)},createGeometry:function(t){for(var e=new X,i=0,n=t.length;i<n;i++){var s=t[i];e.vertices.push(new u(s.x,s.y,s.z||0))}return e}}),Object.assign(fr.prototype,{fromPoints:function(t){this.setFromPoints(t)}}),Iu.prototype=Object.create(On.prototype),Du.prototype=Object.create(On.prototype),Xh.prototype=Object.create(On.prototype),Object.assign(Xh.prototype,{initFromArray:function(){},getControlPointsArray:function(){},reparametrizeByArcLength:function(){}}),gl.prototype.setColors=function(){},Aa.prototype.update=function(){},Object.assign(Do.prototype,{extractUrlBase:function(t){return Gs.extractUrlBase(t)}}),Object.assign(ks.prototype,{setTexturePath:function(t){return this.setResourcePath(t)}}),Object.assign(ul.prototype,{setTexturePath:function(t){return this.setResourcePath(t)}}),Object.assign(ss.prototype,{center:function(t){return this.getCenter(t)},empty:function(){return this.isEmpty()},isIntersectionBox:function(t){return this.intersectsBox(t)},size:function(t){return this.getSize(t)}}),Object.assign(k.prototype,{center:function(t){return this.getCenter(t)},empty:function(){return this.isEmpty()},isIntersectionBox:function(t){return this.intersectsBox(t)},isIntersectionSphere:function(t){return this.intersectsSphere(t)},size:function(t){return this.getSize(t)}}),ba.prototype.center=function(t){return this.getCenter(t)},Object.assign(di,{random16:function(){return Math.random()},nearestPowerOfTwo:function(t){return di.floorPowerOfTwo(t)},nextPowerOfTwo:function(t){return di.ceilPowerOfTwo(t)}}),Object.assign(m.prototype,{flattenToArrayOffset:function(t,e){return this.toArray(t,e)},multiplyVector3:function(t){return t.applyMatrix3(this)},multiplyVector3Array:function(){},applyToBuffer:function(t){return this.applyToBufferAttribute(t)},applyToVector3Array:function(){}}),Object.assign(c.prototype,{extractPosition:function(t){return this.copyPosition(t)},flattenToArrayOffset:function(t,e){return this.toArray(t,e)},getPosition:function(){var t;return function(){return t===void 0&&(t=new u),t.setFromMatrixColumn(this,3)}}(),setRotationFromQuaternion:function(t){return this.makeRotationFromQuaternion(t)},multiplyToArray:function(){},multiplyVector3:function(t){return t.applyMatrix4(this)},multiplyVector4:function(t){return t.applyMatrix4(this)},multiplyVector3Array:function(){},rotateAxis:function(t){t.transformDirection(this)},crossVector:function(t){return t.applyMatrix4(this)},translate:function(){},rotateX:function(){},rotateY:function(){},rotateZ:function(){},rotateByAxis:function(){},applyToBuffer:function(t){return this.applyToBufferAttribute(t)},applyToVector3Array:function(){},makeFrustum:function(t,e,i,n,s,l){return this.makePerspective(t,e,n,i,s,l)}}),F.prototype.isIntersectionLine=function(t){return this.intersectsLine(t)},f.prototype.multiplyVector3=function(t){return t.applyQuaternion(this)},Object.assign(Si.prototype,{isIntersectionBox:function(t){return this.intersectsBox(t)},isIntersectionPlane:function(t){return this.intersectsPlane(t)},isIntersectionSphere:function(t){return this.intersectsSphere(t)}}),Object.assign(Oe.prototype,{area:function(){return this.getArea()},barycoordFromPoint:function(t,e){return this.getBarycoord(t,e)},midpoint:function(t){return this.getMidpoint(t)},normal:function(t){return this.getNormal(t)},plane:function(t){return this.getPlane(t)}}),Object.assign(Oe,{barycoordFromPoint:function(t,e,i,n,s){return Oe.getBarycoord(t,e,i,n,s)},normal:function(t,e,i,n){return Oe.getNormal(t,e,i,n)}}),Object.assign(Qn.prototype,{extractAllPoints:function(t){return this.extractPoints(t)},extrude:function(t){return new Po(this,t)},makeGeometry:function(t){return new Lo(this,t)}}),Object.assign(o.prototype,{fromAttribute:function(t,e,i){return this.fromBufferAttribute(t,e,i)},distanceToManhattan:function(t){return this.manhattanDistanceTo(t)},lengthManhattan:function(){return this.manhattanLength()}}),Object.assign(u.prototype,{setEulerFromRotationMatrix:function(){},setEulerFromQuaternion:function(){},getPositionFromMatrix:function(t){return this.setFromMatrixPosition(t)},getScaleFromMatrix:function(t){return this.setFromMatrixScale(t)},getColumnFromMatrix:function(t,e){return this.setFromMatrixColumn(e,t)},applyProjection:function(t){return this.applyMatrix4(t)},fromAttribute:function(t,e,i){return this.fromBufferAttribute(t,e,i)},distanceToManhattan:function(t){return this.manhattanDistanceTo(t)},lengthManhattan:function(){return this.manhattanLength()}}),Object.assign(v.prototype,{fromAttribute:function(t,e,i){return this.fromBufferAttribute(t,e,i)},lengthManhattan:function(){return this.manhattanLength()}}),Object.assign(X.prototype,{computeTangents:function(){},computeLineDistances:function(){}}),Object.assign(N.prototype,{getChildByName:function(t){return this.getObjectByName(t)},renderDepth:function(){},translate:function(t,e){return this.translateOnAxis(e,t)},getWorldRotation:function(){}}),Object.defineProperties(N.prototype,{eulerOrder:{get:function(){return this.rotation.order},set:function(t){this.rotation.order=t}},useQuaternion:{get:function(){},set:function(){}}}),Object.defineProperties(rn.prototype,{objects:{get:function(){return this.levels}}}),Object.defineProperty(un.prototype,"useVertexTexture",{get:function(){},set:function(){}}),Object.defineProperty(Ee.prototype,"__arcLengthDivisions",{get:function(){return this.arcLengthDivisions},set:function(t){this.arcLengthDivisions=t}}),_e.prototype.setLens=function(t,e){e!==void 0&&(this.filmGauge=e),this.setFocalLength(t)},Object.defineProperties(tn.prototype,{onlyShadow:{set:function(){}},shadowCameraFov:{set:function(t){this.shadow.camera.fov=t}},shadowCameraLeft:{set:function(t){this.shadow.camera.left=t}},shadowCameraRight:{set:function(t){this.shadow.camera.right=t}},shadowCameraTop:{set:function(t){this.shadow.camera.top=t}},shadowCameraBottom:{set:function(t){this.shadow.camera.bottom=t}},shadowCameraNear:{set:function(t){this.shadow.camera.near=t}},shadowCameraFar:{set:function(t){this.shadow.camera.far=t}},shadowCameraVisible:{set:function(){}},shadowBias:{set:function(t){this.shadow.bias=t}},shadowDarkness:{set:function(){}},shadowMapWidth:{set:function(t){this.shadow.mapSize.width=t}},shadowMapHeight:{set:function(t){this.shadow.mapSize.height=t}}}),Object.defineProperties(J.prototype,{length:{get:function(){return this.array.length}},copyIndicesArray:function(){}}),Object.assign(Ft.prototype,{addIndex:function(t){this.setIndex(t)},addDrawCall:function(t,e,i){this.addGroup(t,e)},clearDrawCalls:function(){this.clearGroups()},computeTangents:function(){},computeOffsets:function(){}}),Object.defineProperties(Ft.prototype,{drawcalls:{get:function(){return this.groups}},offsets:{get:function(){return this.groups}}}),Object.assign(po.prototype,{getArrays:function(){},addShapeList:function(){},addShape:function(){}}),Object.defineProperties(oh.prototype,{dynamic:{set:function(){}},onUpdate:{value:function(){return this}}}),Object.defineProperties(Wt.prototype,{wrapAround:{get:function(){},set:function(){}},overdraw:{get:function(){},set:function(){}},wrapRGB:{get:function(){return new P}},shading:{get:function(){},set:function(t){this.flatShading=t===1}}}),Object.defineProperties(Jr.prototype,{metal:{get:function(){return!1},set:function(){}}}),Object.defineProperties($e.prototype,{derivatives:{get:function(){return this.extensions.derivatives},set:function(t){this.extensions.derivatives=t}}}),Object.assign(xe.prototype,{clearTarget:function(t,e,i,n){this.setRenderTarget(t),this.clear(e,i,n)},animate:function(t){this.setAnimationLoop(t)},getCurrentRenderTarget:function(){return this.getRenderTarget()},getMaxAnisotropy:function(){return this.capabilities.getMaxAnisotropy()},getPrecision:function(){return this.capabilities.precision},resetGLState:function(){return this.state.reset()},supportsFloatTextures:function(){return this.extensions.get("OES_texture_float")},supportsHalfFloatTextures:function(){return this.extensions.get("OES_texture_half_float")},supportsStandardDerivatives:function(){return this.extensions.get("OES_standard_derivatives")},supportsCompressedTextureS3TC:function(){return this.extensions.get("WEBGL_compressed_texture_s3tc")},supportsCompressedTexturePVRTC:function(){return this.extensions.get("WEBGL_compressed_texture_pvrtc")},supportsBlendMinMax:function(){return this.extensions.get("EXT_blend_minmax")},supportsVertexTextures:function(){return this.capabilities.vertexTextures},supportsInstancedArrays:function(){return this.extensions.get("ANGLE_instanced_arrays")},enableScissorTest:function(t){this.setScissorTest(t)},initMaterial:function(){},addPrePlugin:function(){},addPostPlugin:function(){},updateShadowMap:function(){},setFaceCulling:function(){}}),Object.defineProperties(xe.prototype,{shadowMapEnabled:{get:function(){return this.shadowMap.enabled},set:function(t){this.shadowMap.enabled=t}},shadowMapType:{get:function(){return this.shadowMap.type},set:function(t){this.shadowMap.type=t}},shadowMapCullFace:{get:function(){},set:function(){}}}),Object.defineProperties(ye.prototype,{cullFace:{get:function(){},set:function(){}},renderReverseSided:{get:function(){},set:function(){}},renderSingleSided:{get:function(){},set:function(){}}}),Object.defineProperties(S.prototype,{wrapS:{get:function(){return this.texture.wrapS},set:function(t){this.texture.wrapS=t}},wrapT:{get:function(){return this.texture.wrapT},set:function(t){this.texture.wrapT=t}},magFilter:{get:function(){return this.texture.magFilter},set:function(t){this.texture.magFilter=t}},minFilter:{get:function(){return this.texture.minFilter},set:function(t){this.texture.minFilter=t}},anisotropy:{get:function(){return this.texture.anisotropy},set:function(t){this.texture.anisotropy=t}},offset:{get:function(){return this.texture.offset},set:function(t){this.texture.offset=t}},repeat:{get:function(){return this.texture.repeat},set:function(t){this.texture.repeat=t}},format:{get:function(){return this.texture.format},set:function(t){this.texture.format=t}},type:{get:function(){return this.texture.type},set:function(t){this.texture.type=t}},generateMipmaps:{get:function(){return this.texture.generateMipmaps},set:function(t){this.texture.generateMipmaps=t}}}),Object.defineProperties(mi.prototype,{standing:{set:function(){}},userHeight:{set:function(){}}}),Sa.prototype.load=function(t){var e=this;return new vn().load(t,function(i){e.setBuffer(i)}),this},Bs.prototype.getData=function(){return this.getFrequencyData()},cl.prototype.updateCubeMap=function(t,e){return this.update(t,e)},as.crossOrigin=void 0,as.loadTexture=function(t,e,i,n){var s=new fn;return s.setCrossOrigin(this.crossOrigin),t=s.load(t,i,void 0,n),e&&(t.mapping=e),t},as.loadTextureCube=function(t,e,i,n){var s=new Fi;return s.setCrossOrigin(this.crossOrigin),t=s.load(t,i,void 0,n),e&&(t.mapping=e),t},as.loadCompressedTexture=function(){},as.loadCompressedTextureCube=function(){},x.WebGLRenderTargetCube=b,x.WebGLRenderTarget=S,x.WebGLRenderer=xe,x.ShaderLib=wo,x.UniformsLib=qe,x.UniformsUtils=Bn,x.ShaderChunk=Ci,x.FogExp2=Re,x.Fog=Sn,x.Scene=Xn,x.Sprite=nn,x.LOD=rn,x.SkinnedMesh=Gi,x.Skeleton=un,x.Bone=cn,x.Mesh=pi,x.LineSegments=gi,x.LineLoop=co,x.Line=ji,x.Points=ha,x.Group=ci,x.VideoTexture=zh,x.DataTexture=O,x.DataTexture3D=Q,x.CompressedTexture=Zo,x.CubeTexture=z,x.CanvasTexture=$a,x.DepthTexture=Ka,x.Texture=g,x.AnimationLoader=Qt,x.CompressedTextureLoader=Zt,x.DataTextureLoader=Ue,x.CubeTextureLoader=Fi,x.TextureLoader=fn,x.ObjectLoader=ul,x.MaterialLoader=ih,x.BufferGeometryLoader=Nh,x.DefaultLoadingManager=tr,x.LoadingManager=is,x.JSONLoader=ks,x.ImageLoader=ai,x.ImageBitmapLoader=Fh,x.FontLoader=Lu,x.FileLoader=Lt,x.Loader=Do,x.LoaderUtils=Gs,x.Cache=Mo,x.AudioLoader=vn,x.SpotLightShadow=ll,x.SpotLight=hl,x.PointLight=Ds,x.RectAreaLight=eh,x.HemisphereLight=al,x.DirectionalLightShadow=rs,x.DirectionalLight=xo,x.AmbientLight=zs,x.LightShadow=_o,x.Light=tn,x.StereoCamera=Vn,x.PerspectiveCamera=_e,x.OrthographicCamera=Ma,x.CubeCamera=cl,x.ArrayCamera=Fe,x.Camera=Be,x.AudioListener=rh,x.PositionalAudio=fl,x.AudioContext=$h,x.AudioAnalyser=Bs,x.Audio=Sa,x.VectorKeyframeTrack=wa,x.StringKeyframeTrack=th,x.QuaternionKeyframeTrack=xa,x.NumberKeyframeTrack=$r,x.ColorKeyframeTrack=Ql,x.BooleanKeyframeTrack=Kl,x.PropertyMixer=dl,x.PropertyBinding=En,x.KeyframeTrack=Hn,x.AnimationUtils=Yn,x.AnimationObjectGroup=Ea,x.AnimationMixer=os,x.AnimationClip=_r,x.Uniform=oh,x.InstancedBufferGeometry=Hh,x.BufferGeometry=Ft,x.Geometry=X,x.InterleavedBufferAttribute=Bi,x.InstancedInterleavedBuffer=Vh,x.InterleavedBuffer=ki,x.InstancedBufferAttribute=Wh,x.Face3=R,x.Object3D=N,x.Raycaster=Ru,x.Layers=U,x.EventDispatcher=a,x.Clock=Gh,x.QuaternionLinearInterpolant=ar,x.LinearInterpolant=Dr,x.DiscreteInterpolant=Is,x.CubicInterpolant=sl,x.Interpolant=$n,x.Triangle=Oe,x.Math=di,x.Spherical=jh,x.Cylindrical=it,x.Plane=F,x.Frustum=E,x.Sphere=I,x.Ray=Si,x.Matrix4=c,x.Matrix3=m,x.Box3=k,x.Box2=ss,x.Line3=ba,x.Euler=C,x.Vector4=v,x.Vector3=u,x.Vector2=o,x.Quaternion=f,x.Color=P,x.ImmediateRenderObject=qn,x.VertexNormalsHelper=_i,x.SpotLightHelper=Ca,x.SkeletonHelper=Aa,x.PointLightHelper=kr,x.RectAreaLightHelper=Pa,x.HemisphereLightHelper=La,x.GridHelper=gl,x.PolarGridHelper=sh,x.FaceNormalsHelper=vl,x.DirectionalLightHelper=dr,x.CameraHelper=yl,x.BoxHelper=zo,x.Box3Helper=_l,x.PlaneHelper=xl,x.ArrowHelper=ko,x.AxesHelper=xr,x.Shape=Qn,x.Path=fr,x.ShapePath=nh,x.Font=Uh,x.CurvePath=Io,x.Curve=Ee,x.ImageUtils=as,x.ShapeUtils=To,x.WebGLUtils=He,x.WireframeGeometry=ua,x.ParametricGeometry=Qa,x.ParametricBufferGeometry=ca,x.TetrahedronGeometry=tl,x.TetrahedronBufferGeometry=fa,x.OctahedronGeometry=el,x.OctahedronBufferGeometry=xs,x.IcosahedronGeometry=il,x.IcosahedronBufferGeometry=da,x.DodecahedronGeometry=pa,x.DodecahedronBufferGeometry=ma,x.PolyhedronGeometry=Xi,x.PolyhedronBufferGeometry=xi,x.TubeGeometry=gn,x.TubeBufferGeometry=Jo,x.TorusKnotGeometry=Zr,x.TorusKnotBufferGeometry=ws,x.TorusGeometry=Ts,x.TorusBufferGeometry=Un,x.TextGeometry=rl,x.TextBufferGeometry=Ss,x.SphereGeometry=$o,x.SphereBufferGeometry=Or,x.RingGeometry=ol,x.RingBufferGeometry=Es,x.PlaneGeometry=Pe,x.PlaneBufferGeometry=pe,x.LatheGeometry=ya,x.LatheBufferGeometry=Ko,x.ShapeGeometry=Lo,x.ShapeBufferGeometry=Qo,x.ExtrudeGeometry=Po,x.ExtrudeBufferGeometry=po,x.EdgesGeometry=ts,x.ConeGeometry=_a,x.ConeBufferGeometry=Gn,x.CylinderGeometry=Ro,x.CylinderBufferGeometry=Oo,x.CircleGeometry=bs,x.CircleBufferGeometry=mo,x.BoxGeometry=It,x.BoxBufferGeometry=Nt,x.ShadowMaterial=es,x.SpriteMaterial=Hi,x.RawShaderMaterial=Cs,x.ShaderMaterial=$e,x.PointsMaterial=Fn,x.MeshPhysicalMaterial=As,x.MeshStandardMaterial=go,x.MeshPhongMaterial=Jr,x.MeshToonMaterial=Ps,x.MeshNormalMaterial=Ls,x.MeshLambertMaterial=Ir,x.MeshDepthMaterial=se,x.MeshDistanceMaterial=te,x.MeshBasicMaterial=Ge,x.MeshMatcapMaterial=Rs,x.LineDashedMaterial=Os,x.LineBasicMaterial=Ni,x.Material=Wt,x.Float64BufferAttribute=At,x.Float32BufferAttribute=Et,x.Uint32BufferAttribute=Pt,x.Int32BufferAttribute=G,x.Uint16BufferAttribute=_t,x.Int16BufferAttribute=tt,x.Uint8ClampedBufferAttribute=Rt,x.Uint8BufferAttribute=ct,x.Int8BufferAttribute=Z,x.BufferAttribute=J,x.ArcCurve=Ta,x.CatmullRomCurve3=On,x.CubicBezierCurve=hr,x.CubicBezierCurve3=Ti,x.EllipseCurve=Kn,x.LineCurve=ur,x.LineCurve3=zr,x.QuadraticBezierCurve=cr,x.QuadraticBezierCurve3=yo,x.SplineCurve=Kr,x.REVISION="98",x.MOUSE={LEFT:0,MIDDLE:1,RIGHT:2},x.CullFaceNone=0,x.CullFaceBack=1,x.CullFaceFront=2,x.CullFaceFrontBack=3,x.FrontFaceDirectionCW=0,x.FrontFaceDirectionCCW=1,x.BasicShadowMap=0,x.PCFShadowMap=1,x.PCFSoftShadowMap=2,x.FrontSide=0,x.BackSide=1,x.DoubleSide=2,x.FlatShading=1,x.SmoothShading=2,x.NoColors=0,x.FaceColors=1,x.VertexColors=2,x.NoBlending=0,x.NormalBlending=1,x.AdditiveBlending=2,x.SubtractiveBlending=3,x.MultiplyBlending=4,x.CustomBlending=5,x.AddEquation=100,x.SubtractEquation=101,x.ReverseSubtractEquation=102,x.MinEquation=103,x.MaxEquation=104,x.ZeroFactor=200,x.OneFactor=201,x.SrcColorFactor=202,x.OneMinusSrcColorFactor=203,x.SrcAlphaFactor=204,x.OneMinusSrcAlphaFactor=205,x.DstAlphaFactor=206,x.OneMinusDstAlphaFactor=207,x.DstColorFactor=208,x.OneMinusDstColorFactor=209,x.SrcAlphaSaturateFactor=210,x.NeverDepth=0,x.AlwaysDepth=1,x.LessDepth=2,x.LessEqualDepth=3,x.EqualDepth=4,x.GreaterEqualDepth=5,x.GreaterDepth=6,x.NotEqualDepth=7,x.MultiplyOperation=0,x.MixOperation=1,x.AddOperation=2,x.NoToneMapping=0,x.LinearToneMapping=1,x.ReinhardToneMapping=2,x.Uncharted2ToneMapping=3,x.CineonToneMapping=4,x.UVMapping=300,x.CubeReflectionMapping=301,x.CubeRefractionMapping=302,x.EquirectangularReflectionMapping=303,x.EquirectangularRefractionMapping=304,x.SphericalReflectionMapping=305,x.CubeUVReflectionMapping=306,x.CubeUVRefractionMapping=307,x.RepeatWrapping=1e3,x.ClampToEdgeWrapping=1001,x.MirroredRepeatWrapping=1002,x.NearestFilter=1003,x.NearestMipMapNearestFilter=1004,x.NearestMipMapLinearFilter=1005,x.LinearFilter=1006,x.LinearMipMapNearestFilter=1007,x.LinearMipMapLinearFilter=1008,x.UnsignedByteType=1009,x.ByteType=1010,x.ShortType=1011,x.UnsignedShortType=1012,x.IntType=1013,x.UnsignedIntType=1014,x.FloatType=1015,x.HalfFloatType=1016,x.UnsignedShort4444Type=1017,x.UnsignedShort5551Type=1018,x.UnsignedShort565Type=1019,x.UnsignedInt248Type=1020,x.AlphaFormat=1021,x.RGBFormat=1022,x.RGBAFormat=1023,x.LuminanceFormat=1024,x.LuminanceAlphaFormat=1025,x.RGBEFormat=1023,x.DepthFormat=1026,x.DepthStencilFormat=1027,x.RedFormat=1028,x.RGB_S3TC_DXT1_Format=33776,x.RGBA_S3TC_DXT1_Format=33777,x.RGBA_S3TC_DXT3_Format=33778,x.RGBA_S3TC_DXT5_Format=33779,x.RGB_PVRTC_4BPPV1_Format=35840,x.RGB_PVRTC_2BPPV1_Format=35841,x.RGBA_PVRTC_4BPPV1_Format=35842,x.RGBA_PVRTC_2BPPV1_Format=35843,x.RGB_ETC1_Format=36196,x.RGBA_ASTC_4x4_Format=37808,x.RGBA_ASTC_5x4_Format=37809,x.RGBA_ASTC_5x5_Format=37810,x.RGBA_ASTC_6x5_Format=37811,x.RGBA_ASTC_6x6_Format=37812,x.RGBA_ASTC_8x5_Format=37813,x.RGBA_ASTC_8x6_Format=37814,x.RGBA_ASTC_8x8_Format=37815,x.RGBA_ASTC_10x5_Format=37816,x.RGBA_ASTC_10x6_Format=37817,x.RGBA_ASTC_10x8_Format=37818,x.RGBA_ASTC_10x10_Format=37819,x.RGBA_ASTC_12x10_Format=37820,x.RGBA_ASTC_12x12_Format=37821,x.LoopOnce=2200,x.LoopRepeat=2201,x.LoopPingPong=2202,x.InterpolateDiscrete=2300,x.InterpolateLinear=2301,x.InterpolateSmooth=2302,x.ZeroCurvatureEnding=2400,x.ZeroSlopeEnding=2401,x.WrapAroundEnding=2402,x.TrianglesDrawMode=0,x.TriangleStripDrawMode=1,x.TriangleFanDrawMode=2,x.LinearEncoding=3e3,x.sRGBEncoding=3001,x.GammaEncoding=3007,x.RGBEEncoding=3002,x.LogLuvEncoding=3003,x.RGBM7Encoding=3004,x.RGBM16Encoding=3005,x.RGBDEncoding=3006,x.BasicDepthPacking=3200,x.RGBADepthPacking=3201,x.TangentSpaceNormalMap=0,x.ObjectSpaceNormalMap=1,x.CubeGeometry=It,x.Face4=function(t,e,i,n,s,l,d){return new R(t,e,i,s,l,d)},x.LineStrip=0,x.LinePieces=1,x.MeshFaceMaterial=function(t){return t},x.MultiMaterial=function(t){return t===void 0&&(t=[]),t.isMultiMaterial=!0,t.materials=t,t.clone=function(){return t.slice()},t},x.PointCloud=function(t,e){return new ha(t,e)},x.Particle=function(t){return new nn(t)},x.ParticleSystem=function(t,e){return new ha(t,e)},x.PointCloudMaterial=function(t){return new Fn(t)},x.ParticleBasicMaterial=function(t){return new Fn(t)},x.ParticleSystemMaterial=function(t){return new Fn(t)},x.Vertex=function(t,e,i){return new u(t,e,i)},x.DynamicBufferAttribute=function(t,e){return new J(t,e).setDynamic(!0)},x.Int8Attribute=function(t,e){return new Z(t,e)},x.Uint8Attribute=function(t,e){return new ct(t,e)},x.Uint8ClampedAttribute=function(t,e){return new Rt(t,e)},x.Int16Attribute=function(t,e){return new tt(t,e)},x.Uint16Attribute=function(t,e){return new _t(t,e)},x.Int32Attribute=function(t,e){return new G(t,e)},x.Uint32Attribute=function(t,e){return new Pt(t,e)},x.Float32Attribute=function(t,e){return new Et(t,e)},x.Float64Attribute=function(t,e){return new At(t,e)},x.ClosedSplineCurve3=Iu,x.SplineCurve3=Du,x.Spline=Xh,x.AxisHelper=function(t){return new xr(t)},x.BoundingBoxHelper=function(t,e){return new zo(t,e)},x.EdgesHelper=function(t,e){return new gi(new ts(t.geometry),new Ni({color:e!==void 0?e:16777215}))},x.WireframeHelper=function(t,e){return new gi(new ua(t.geometry),new Ni({color:e!==void 0?e:16777215}))},x.XHRLoader=function(t){return new Lt(t)},x.BinaryTextureLoader=function(t){return new Ue(t)},x.GeometryUtils={merge:function(t,e,i){if(e.isMesh){e.matrixAutoUpdate&&e.updateMatrix();var n=e.matrix;e=e.geometry}t.merge(e,n,i)},center:function(t){return t.center()}},x.Projector=function(){this.projectVector=function(t,e){t.project(e)},this.unprojectVector=function(t,e){t.unproject(e)},this.pickingRay=function(){}},x.CanvasRenderer=function(){},x.SceneUtils={createMultiMaterialObject:function(){},detach:function(){},attach:function(){}},x.LensFlare=function(){},Object.defineProperty(x,"__esModule",{value:!0})}),THREE.Sky=function(){var x=THREE.Sky.SkyShader,a=new THREE.ShaderMaterial({fragmentShader:x.fragmentShader,vertexShader:x.vertexShader,uniforms:THREE.UniformsUtils.clone(x.uniforms),side:THREE.BackSide});THREE.Mesh.call(this,new THREE.BoxBufferGeometry(1,1,1),a)},THREE.Sky.prototype=Object.create(THREE.Mesh.prototype),THREE.Sky.SkyShader={uniforms:{luminance:{value:1},turbidity:{value:2},rayleigh:{value:1},mieCoefficient:{value:.005},mieDirectionalG:{value:.8},sunPosition:{value:new THREE.Vector3}},vertexShader:["uniform vec3 sunPosition;","uniform float rayleigh;","uniform float turbidity;","uniform float mieCoefficient;","varying vec3 vWorldPosition;","varying vec3 vSunDirection;","varying float vSunfade;","varying vec3 vBetaR;","varying vec3 vBetaM;","varying float vSunE;","const vec3 up = vec3( 0.0, 1.0, 0.0 );","const float e = 2.71828182845904523536028747135266249775724709369995957;","const float pi = 3.141592653589793238462643383279502884197169;","const vec3 lambda = vec3( 680E-9, 550E-9, 450E-9 );","const vec3 totalRayleigh = vec3( 5.804542996261093E-6, 1.3562911419845635E-5, 3.0265902468824876E-5 );","const float v = 4.0;","const vec3 K = vec3( 0.686, 0.678, 0.666 );","const vec3 MieConst = vec3( 1.8399918514433978E14, 2.7798023919660528E14, 4.0790479543861094E14 );","const float cutoffAngle = 1.6110731556870734;","const float steepness = 1.5;","const float EE = 1000.0;","float sunIntensity( float zenithAngleCos ) {"," zenithAngleCos = clamp( zenithAngleCos, -1.0, 1.0 );"," return EE * max( 0.0, 1.0 - pow( e, -( ( cutoffAngle - acos( zenithAngleCos ) ) / steepness ) ) );","}","vec3 totalMie( float T ) {"," float c = ( 0.2 * T ) * 10E-18;"," return 0.434 * c * MieConst;","}","void main() {"," vec4 worldPosition = modelMatrix * vec4( position, 1.0 );"," vWorldPosition = worldPosition.xyz;"," gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );"," gl_Position.z = gl_Position.w;"," vSunDirection = normalize( sunPosition );"," vSunE = sunIntensity( dot( vSunDirection, up ) );"," vSunfade = 1.0 - clamp( 1.0 - exp( ( sunPosition.y / 450000.0 ) ), 0.0, 1.0 );"," float rayleighCoefficient = rayleigh - ( 1.0 * ( 1.0 - vSunfade ) );"," vBetaR = totalRayleigh * rayleighCoefficient;"," vBetaM = totalMie( turbidity ) * mieCoefficient;","}"].join(`
|
|
2572
2572
|
`),fragmentShader:["varying vec3 vWorldPosition;","varying vec3 vSunDirection;","varying float vSunfade;","varying vec3 vBetaR;","varying vec3 vBetaM;","varying float vSunE;","uniform float luminance;","uniform float mieDirectionalG;","const vec3 cameraPos = vec3( 0.0, 1.0, 0.0 );","const float pi = 3.141592653589793238462643383279502884197169;","const float n = 1.0003;","const float N = 2.545E25;","const float rayleighZenithLength = 8.4E3;","const float mieZenithLength = 1.25E3;","const vec3 up = vec3( 0.0, 1.0, 0.0 );","const float sunAngularDiameterCos = 0.999956676946448443553574619906976478926848692873900859324;","const float THREE_OVER_SIXTEENPI = 0.05968310365946075;","const float ONE_OVER_FOURPI = 0.07957747154594767;","float rayleighPhase( float cosTheta ) {"," return THREE_OVER_SIXTEENPI * ( 1.0 + pow( cosTheta, 2.0 ) );","}","float hgPhase( float cosTheta, float g ) {"," float g2 = pow( g, 2.0 );"," float inverse = 1.0 / pow( 1.0 - 2.0 * g * cosTheta + g2, 1.5 );"," return ONE_OVER_FOURPI * ( ( 1.0 - g2 ) * inverse );","}","const float A = 0.15;","const float B = 0.50;","const float C = 0.10;","const float D = 0.20;","const float E = 0.02;","const float F = 0.30;","const float whiteScale = 1.0748724675633854;","vec3 Uncharted2Tonemap( vec3 x ) {"," return ( ( x * ( A * x + C * B ) + D * E ) / ( x * ( A * x + B ) + D * F ) ) - E / F;","}","void main() {"," float zenithAngle = acos( max( 0.0, dot( up, normalize( vWorldPosition - cameraPos ) ) ) );"," float inverse = 1.0 / ( cos( zenithAngle ) + 0.15 * pow( 93.885 - ( ( zenithAngle * 180.0 ) / pi ), -1.253 ) );"," float sR = rayleighZenithLength * inverse;"," float sM = mieZenithLength * inverse;"," vec3 Fex = exp( -( vBetaR * sR + vBetaM * sM ) );"," float cosTheta = dot( normalize( vWorldPosition - cameraPos ), vSunDirection );"," float rPhase = rayleighPhase( cosTheta * 0.5 + 0.5 );"," vec3 betaRTheta = vBetaR * rPhase;"," float mPhase = hgPhase( cosTheta, mieDirectionalG );"," vec3 betaMTheta = vBetaM * mPhase;"," vec3 Lin = pow( vSunE * ( ( betaRTheta + betaMTheta ) / ( vBetaR + vBetaM ) ) * ( 1.0 - Fex ), vec3( 1.5 ) );"," Lin *= mix( vec3( 1.0 ), pow( vSunE * ( ( betaRTheta + betaMTheta ) / ( vBetaR + vBetaM ) ) * Fex, vec3( 1.0 / 2.0 ) ), clamp( pow( 1.0 - dot( up, vSunDirection ), 5.0 ), 0.0, 1.0 ) );"," vec3 direction = normalize( vWorldPosition - cameraPos );"," float theta = acos( direction.y ); // elevation --> y-axis, [-pi/2, pi/2]"," float phi = atan( direction.z, direction.x ); // azimuth --> x-axis [-pi/2, pi/2]"," vec2 uv = vec2( phi, theta ) / vec2( 2.0 * pi, pi ) + vec2( 0.5, 0.0 );"," vec3 L0 = vec3( 0.1 ) * Fex;"," float sundisk = smoothstep( sunAngularDiameterCos, sunAngularDiameterCos + 0.00002, cosTheta );"," L0 += ( vSunE * 19000.0 * Fex ) * sundisk;"," vec3 texColor = ( Lin + L0 ) * 0.04 + vec3( 0.0, 0.0003, 0.00075 );"," vec3 curr = Uncharted2Tonemap( ( log2( 2.0 / pow( luminance, 4.0 ) ) ) * texColor );"," vec3 color = curr * whiteScale;"," vec3 retColor = pow( color, vec3( 1.0 / ( 1.2 + ( 1.2 * vSunfade ) ) ) );"," gl_FragColor = vec4( retColor, 1.0 );","}"].join(`
|
|
2573
|
-
`)},function(x){typeof module>"u"?window.charming=x:module.exports=x}(function(x,a){a=a||{};var o=a.tagName||"span",c=a.classPrefix!=null?a.classPrefix:"char",f=1,u=function(m){for(var g=m.parentNode,v=m.nodeValue,S=v.length,b=-1;++b<S;){var O=document.createElement(o);c&&(O.className=c+f,f++),O.appendChild(document.createTextNode(v[b])),g.insertBefore(O,m)}g.removeChild(m)};return function m(g){for(var v=[].slice.call(g.childNodes),S=v.length,b=-1;++b<S;)m(v[b]);g.nodeType===Node.TEXT_NODE&&u(g)}(x),x});class sm{constructor(a=[]){Ho(this,"componentonTick",()=>{this.componentColoringArray.forEach(a=>{let{componentMap:o,oldColorRgb:c,modelId:f}=a,u=c||"rgba(255,255,255",m=this.queryModel(f);m&&(m.style=g=>{const v=mars3d.Util.get3DTileFeatureAttr(g).id,S=window.map.viewer.clock.currentTime;let b;if(o.has(v)){let{startTime:O,totalDuration:k,modelInit:I,endTime:N}=o.get(v);if(b=I,k==0){if(b==1)return`${u},0)`;if(b==0)return`${u},1)`}if(k!=0){let E=(S.dayNumber-O.dayNumber)/(N.dayNumber-O.dayNumber);if(b==1?E=1-E:b==0&&(E=0+E),E>1?E=1:E<0&&(E=0),E==1)return`${u},${E})`;if(E<1){if(I==2)return"rgba(255,215,0,1)";if(b==0)if(E>.85&&E<1){const w=Date.now()/1e3;return`rgba(135, 206, 250,${.1+(Math.sin(w*10)+1)*.1})`}else return`rgba(135, 206, 250,${E})`;else if(E<.15&&E>0){const w=Date.now()/1e3;return`rgba(240, 128, 128,${.1+(Math.sin(w*10)+1)*.1})`}else return`rgba(240, 128, 128,${E})`}}}return`${u},0)`})})});Ho(this,"initComponentAnimation",()=>{this.componentItem=null,window.map.viewer.clock.onTick.removeEventListener(this.componentonTick)});Ho(this,"initComponentDyeing",(a=[])=>{if(a.length>0){const o=this.convertComponentListToMap(a);this.componentColoringArray=o,this.componentColoringArray.forEach(c=>{let{componentMap:f,oldColorRgb:u,modelId:m}=c,g=u||"rgba(255,255,255",v=this.queryModel(m);v&&(v.style=S=>{const b=mars3d.Util.get3DTileFeatureAttr(S).id;return f.has(b)?`${g},1)`:`${g},0)`})})}});mars3d&&(this.tilesetLayer,this.modelArr=a,this.bimObliquePhotographyId=[],this.editDate={id:null},this.componentColoringArray=[],this.componentItem,this.disabled=!0)}pushModel(a){this.modelArr.push(a)}add(a,o,c){let f=c==null?void 0:c.isClone;const u=new Map([["click",mars3d.EventType.click],["initialTilesLoaded",mars3d.EventType.initialTilesLoaded]]);return new Promise((m,g)=>{let v,S,b,O,k,I,N,E,P,w={enabled:!0,precise:!1,czm:!1},M={enabled:!0,precise:!1,czm:!1};if(typeof a!="object"){let F=this.query(a);F||g("缺少树结构");let{id:X,bimModelExcavationDetails:K,bimModel:Z}=F;v=X,S=Z.modelType,b=Z.tender,O=Z.releasedDistance,k=Z.modelName,I=Z.isDynamicReleased,N={bimModelExcavationDetails:K},E=F.url,P=Z.modelColor,w.maxCanvasSize=Z.gridResolution||4080}else v=a.modelId,S=a.modelType,b=a.tender,O=a.releasedDistance,k=a.modelTitle,I=a.permission,N=a.customize,E=a.url,P=a.color,w.maxCanvasSize=a.maxCanvasSize||4080;let R=2147483648,C=16;if(c){if(c.color&&(P=c.color),c.clip&&(w.area=c.clip.handleDataList),c.flat&&(M.area=c.flat.handleDataList),c.maxCanvasSize&&(w.maxCanvasSize=c.maxCanvasSize||4080),c.cacheSpaceMultiplier){let F=F*c.cacheSpaceMultiplier}c.maximumScreenSpaceError&&S==0&&(C=c.maximumScreenSpaceError)}let U;if(f?window.mapClone&&(U=window.mapClone.mapEx.getLayer(a,"modelId")):U=window.map.getLayer(a,"modelId"),U){if(c.color&&this.editColor(a,c.color,c),window.schemeEvnModify&&c.clip){let{modelId:F,handleDataList:X}=c.clip;X.forEach(K=>{let{id:Z,positions:ct}=K;window.schemeEvnModify.modelCutById(F,ct,Z)})}return m(U),!1}else{if(E.indexOf("tileset.json")<0)return m({tite:"【模型】「"+k+"」链接地址有误",type:"error",id:v,url:E}),!1;new Cesium.Resource({url:E}).fetchJson().then(X=>{let K=null;P&&(K={color:{conditions:[["true",P]]}}),this.tilesetLayer=new mars3d.layer.TilesetLayer({modelId:v,modelType:S,tender:b,releasedDistance:O,modelTitle:k,permission:I,customize:N,url:encodeURI(E),skipLevelOfDetail:!1,loadSiblings:!0,cullRequestsWhileMoving:!0,cullRequestsWhileMovingMultiplier:10,preferLeaves:!0,progressiveResolutionHeightFraction:.5,dynamicScreenSpaceError:!0,preloadWhenHidden:!1,style:K,clip:w,flat:M,maximumScreenSpaceError:C,cacheBytes:1073741824,maximumCacheOverflowBytes:R,environmentMapManager:{enabled:!1},highlight:{type:"click",color:"rgba(255,0,0,1)"}}),this.tilesetLayer.bindPopup(Z=>{if(!this.disabled)return!1;if(Z.graphic){const ct=Z.graphic.attr;let Rt=null,tt=null;return JSON.stringify(ct)!=="{}"?(ct.name&&(Rt=ct.name.lastIndexOf("@")),Rt&&Rt>-1&&(tt=ct.name.slice(0,Rt)),ct.name?` <span>${tt||ct.name}</span> `:` <span>${k}</span> `):` <span>${k}</span> `}else return` <span>${k}</span> `}),this.tilesetLayer.readyPromise.then(Z=>{if(Z.layer.environmentMapManager.enabled=!1,(c==null?void 0:c.light)==!1){const ct=new Cesium.CustomShader({lightingModel:Cesium.LightingModel.UNLIT});Z.layer.customShader=ct}m(Z)}).catch(Z=>{m()}),o&&Object.keys(o).forEach(Z=>{this.tilesetLayer.on(u.get(Z),ct=>{o[Z](ct)})}),S==0&&this.bimObliquePhotographyId.push(v),f?window.mapClone&&window.mapClone.mapEx.addLayer(this.tilesetLayer):window.map.addLayer(this.tilesetLayer)}).catch(X=>{m({tite:"【模型】「"+k+"」无法加载",type:"error",id:v,url:E})})}})}remove(a,o){let c=o==null?void 0:o.isClone;window.map.getLayer(a,"modelId")&&(c?(window.mapClone.mapEx.getLayer(a,"modelId").closeHighlight(),window.mapClone.mapEx.removeLayer(window.mapClone.mapEx.getLayer(a,"modelId"))):(window.map.getLayer(a,"modelId").closeHighlight(),window.map.removeLayer(window.map.getLayer(a,"modelId"))))}selected(a,o,c,f=!0){return new Promise((u,m)=>{let g=window.map.getLayer(a,"modelId");g?(g.style==null&&map.bimMapEdit=="0"&&g.openHighlight({color:"rgba(255,0,0,1)"},!0),f?g.flyTo({complete:()=>{u(g)}}):u(g)):this.add(a,o,c).then(v=>{v&&(v.style==null&&map.bimMapEdit=="0"&&v.openHighlight({color:"rgba(255,0,0,1)"},!0),f?v.flyTo({complete:()=>{u(v)}}):u(v))})})}initial(){this.modelArr=[],this.bimObliquePhotographyId=[],this.tilesetLayer=null}query(a){return this.modelArr.length==0?!1:this.modelArr.find(o=>o.id==a)}queryModel(a,o){return(o==null?void 0:o.isClone)?window.mapClone.mapEx.getLayer(a,"modelId"):window.map.getLayer(a,"modelId")}postEditDate(a){this.editDate={id:a}}editColor(a,o,c,f="true"){let u,m=c==null?void 0:c.isClone;if(typeof a!="object"&&(m?u=window.mapClone.mapEx.getLayer(a,"modelId"):u=window.map.getLayer(a,"modelId")),u)if(o)u.style={color:{conditions:[[f,o]]}};else{let g=this.query(a).bimModel.modelColor;g?u.style={color:{conditions:[[f,g]]}}:u.style=null}}editOpacity(a,o){window.map.getLayer(a,"modelId").opacity=o}addClip(a){return new Promise((o,c)=>{window.bimClip?o(bimClip.clipModelAdd(a)):c("挖洞工具未初始化")})}removeClip(a){window.bimClip&&window.bimClip.clipModelremoveClip(a)}componentDyeing(a,o=[],c="id"){let f=this.queryModel(a);const u=new Map;o.forEach(m=>{m.id.forEach(g=>{u.set(g,m.color)})}),f&&(f.style=m=>{const g=mars3d.Util.get3DTileFeatureAttr(m)[c];return u.get(g)||"rgba(255,255,255,0)"})}getLastDayOfMonth(a){const o=new Date(a.getFullYear(),a.getMonth()+1,1);return new Date(o-1)}async fadeOutModel(a,o=[],c=[],f=1,u=!1,m){if(c.length>0){let g=new Cesium.JulianDate.fromIso8601(c[0]),v=new Cesium.JulianDate.fromIso8601(c[1]),S;if(u?S=0:S=Cesium.JulianDate.secondsDifference(v,g),g&&v&&o.length>0){let b=this.queryModel(a);!b&&!m&&(b=await this.add(a));let O=this.componentColoringArray.find(I=>I.modelId==a),k=new Map;if(O)o.forEach(I=>{O.componentMap.set(I,{startTime:g,endTime:v,totalDuration:S,modelInit:f})});else{o.forEach(E=>{k.set(E,{startTime:g,endTime:v,totalDuration:S,modelInit:f})});let I=this.query(a).bimModel.modelColor,N;I&&(N=I.substring(0,I.lastIndexOf(","))+","),O={modelId:a,oldColorRgb:N,componentMap:k,modelInit:f},this.componentColoringArray.push(O)}window.map.viewer.clock.onTick.removeEventListener(this.componentonTick),window.map.viewer.clock.onTick.addEventListener(this.componentonTick)}}}convertComponentListToMap(a){return a.map(o=>{let c=this.query(o.modelId),f;const u=new Map;if(c){let{bimModel:m}=c,{modelColor:g}=m;g&&g!=""&&(f=(g==null?void 0:g.substring(0,g.lastIndexOf(",")))+",")}return o.componentList.forEach(m=>{u.set(m,{modelInit:0,totalDuration:0})}),{modelId:o.modelId,componentMap:u,oldColorRgb:f}})}fadeOutModel2(a,o=[],c=3e3,f=0){const u=Date.now();let m=this.query(a).bimModel.modelColor;const g=m.substring(0,m.lastIndexOf(","))+",",v=()=>{const O=(Date.now()-u)/c;if(O<1){let k;f==1?k=1-O:f==0&&(k=0+O);const I=bimModel.queryModel(a);I&&(I.style=N=>{if(o.length==0)return`rgba(255,0,0,${k})`;const E=mars3d.Util.get3DTileFeatureAttr(N).id;if(o.length!=0)return o.includes(E)?`rgba(255,0,0,${k})`:m}),requestAnimationFrame(v)}else{const k=bimModel.queryModel(a);k&&(k.style=I=>{const N=mars3d.Util.get3DTileFeatureAttr(I).id;if(o.length==0)return`${g}${1-f})`;if(o.length!=0)return o.includes(N)?`${g}${1-f})`:m})}};v()}}const su=x=>Object.prototype.toString.call(x)==="[object Object]";function au(){const x=Array.from(arguments);if(x.length<2)return x[0];let a=x[0];return x.shift(),x.forEach(o=>{if(su(o)){su(a)||(a={});for(let c in o)a[c]&&su(o[c])?a[c]=au(a[c],o[c]):a[c]=o[c]}else o instanceof Array&&(a instanceof Array||(a=[]),o.forEach((c,f)=>{su(c)?a[f]=au(a[f]):a[f]=c}))}),a}let vh={};const bf=(x,a,o)=>{vh={};let{vectorStyle:c,difference:f}=x;if(c){let{divType:u}=c,m="";if(u){let{theme_color:g,title:v,font_color:S,content:b,scaleByDistance:O,scaleByDistance_far:k,scaleByDistance_farValue:I,scaleByDistance_near:N,scaleByDistance_nearValue:E,distanceDisplayCondition:P,distanceDisplayCondition_far:w,distanceDisplayCondition_near:M,clampToGround:R,divStyle:C,isMirror:U}=c,{theme_color2:F,theme_color3:X}=C;switch(u){case"1":m=`<div class="entity-div-style entity-div-style1" style="--theme-color1:${g};--theme-font-color1:${S};">
|
|
2573
|
+
`)},function(x){typeof module>"u"?window.charming=x:module.exports=x}(function(x,a){a=a||{};var o=a.tagName||"span",c=a.classPrefix!=null?a.classPrefix:"char",f=1,u=function(m){for(var g=m.parentNode,v=m.nodeValue,S=v.length,b=-1;++b<S;){var O=document.createElement(o);c&&(O.className=c+f,f++),O.appendChild(document.createTextNode(v[b])),g.insertBefore(O,m)}g.removeChild(m)};return function m(g){for(var v=[].slice.call(g.childNodes),S=v.length,b=-1;++b<S;)m(v[b]);g.nodeType===Node.TEXT_NODE&&u(g)}(x),x});class sm{constructor(a=[]){Ho(this,"componentonTick",()=>{this.componentColoringArray.forEach(a=>{let{componentMap:o,oldColorRgb:c,modelId:f}=a,u=c||"rgba(255,255,255",m=this.queryModel(f);m&&(m.style=g=>{const v=mars3d.Util.get3DTileFeatureAttr(g).id,S=window.map.viewer.clock.currentTime;let b;if(o.has(v)){let{startTime:O,totalDuration:k,modelInit:I,endTime:F}=o.get(v);if(b=I,k==0){if(b==1)return`${u},0)`;if(b==0)return`${u},1)`}if(k!=0){let E=(S.dayNumber-O.dayNumber)/(F.dayNumber-O.dayNumber);if(b==1?E=1-E:b==0&&(E=0+E),E>1?E=1:E<0&&(E=0),E==1)return`${u},${E})`;if(E<1){if(I==2)return"rgba(255,215,0,1)";if(b==0)if(E>.85&&E<1){const w=Date.now()/1e3;return`rgba(135, 206, 250,${.1+(Math.sin(w*10)+1)*.1})`}else return`rgba(135, 206, 250,${E})`;else if(E<.15&&E>0){const w=Date.now()/1e3;return`rgba(240, 128, 128,${.1+(Math.sin(w*10)+1)*.1})`}else return`rgba(240, 128, 128,${E})`}}}return`${u},0)`})})});Ho(this,"initComponentAnimation",()=>{this.componentItem=null,window.map.viewer.clock.onTick.removeEventListener(this.componentonTick)});Ho(this,"initComponentDyeing",(a=[])=>{if(a.length>0){const o=this.convertComponentListToMap(a);this.componentColoringArray=o,this.componentColoringArray.forEach(c=>{let{componentMap:f,oldColorRgb:u,modelId:m}=c,g=u||"rgba(255,255,255",v=this.queryModel(m);v&&(v.style=S=>{const b=mars3d.Util.get3DTileFeatureAttr(S).id;return f.has(b)?`${g},1)`:`${g},0)`})})}});mars3d&&(this.tilesetLayer,this.modelArr=a,this.bimObliquePhotographyId=[],this.editDate={id:null},this.componentColoringArray=[],this.componentItem,this.disabled=!0)}pushModel(a){this.modelArr.push(a)}add(a,o,c){let f=c==null?void 0:c.isClone;const u=new Map([["click",mars3d.EventType.click],["initialTilesLoaded",mars3d.EventType.initialTilesLoaded]]);return new Promise((m,g)=>{let v,S,b,O,k,I,F,E,P,w={enabled:!0,precise:!1,czm:!1},M={enabled:!0,precise:!1,czm:!1};if(typeof a!="object"){let N=this.query(a);N||g("缺少树结构");let{id:X,bimModelExcavationDetails:J,bimModel:Z}=N;v=X,S=Z?Z.modelType:N.modelType,b=Z?Z.tender:N.tender,O=Z?Z.releasedDistance:N.releasedDistance,k=Z?Z.modelName:N.modelName,I=Z?Z.isDynamicReleased:N.isDynamicReleased,F={bimModelExcavationDetails:J},E=N.url,P=Z?Z.modelColor:N.modelColor,w.maxCanvasSize=Z?Z.gridResolution:N.gridResolution||4080}else v=a.modelId,S=a.modelType,b=a.tender,O=a.releasedDistance,k=a.modelTitle,I=a.permission,F=a.customize,E=a.url,P=a.color,w.maxCanvasSize=a.maxCanvasSize||4080;let R=2147483648,C=16;if(c){if(c.color&&(P=c.color),c.clip&&(w.area=c.clip.handleDataList),c.flat&&(M.area=c.flat.handleDataList),c.maxCanvasSize&&(w.maxCanvasSize=c.maxCanvasSize||4080),c.cacheSpaceMultiplier){let N=N*c.cacheSpaceMultiplier}c.maximumScreenSpaceError&&S==0&&(C=c.maximumScreenSpaceError)}let U;if(f?window.mapClone&&(U=window.mapClone.mapEx.getLayer(a,"modelId")):U=window.map.getLayer(a,"modelId"),U){if(c.color&&this.editColor(a,c.color,c),window.schemeEvnModify&&c.clip){let{modelId:N,handleDataList:X}=c.clip;X.forEach(J=>{let{id:Z,positions:ct}=J;window.schemeEvnModify.modelCutById(N,ct,Z)})}return m(U),!1}else{if(E.indexOf("tileset.json")<0)return m({tite:"【模型】「"+k+"」链接地址有误",type:"error",id:v,url:E}),!1;new Cesium.Resource({url:E}).fetchJson().then(X=>{let J=null;P&&(J={color:{conditions:[["true",P]]}}),this.tilesetLayer=new mars3d.layer.TilesetLayer({modelId:v,modelType:S,tender:b,releasedDistance:O,modelTitle:k,permission:I,customize:F,url:encodeURI(E),skipLevelOfDetail:!1,loadSiblings:!0,cullRequestsWhileMoving:!0,cullRequestsWhileMovingMultiplier:10,preferLeaves:!0,progressiveResolutionHeightFraction:.5,dynamicScreenSpaceError:!0,preloadWhenHidden:!1,style:J,clip:w,flat:M,maximumScreenSpaceError:C,cacheBytes:1073741824,maximumCacheOverflowBytes:R,environmentMapManager:{enabled:!1},highlight:{type:"click",color:"rgba(255,0,0,1)"}}),this.tilesetLayer.bindPopup(Z=>{if(!this.disabled)return!1;if(Z.graphic){const ct=Z.graphic.attr;let Rt=null,tt=null;return JSON.stringify(ct)!=="{}"?(ct.name&&(Rt=ct.name.lastIndexOf("@")),Rt&&Rt>-1&&(tt=ct.name.slice(0,Rt)),ct.name?` <span>${tt||ct.name}</span> `:` <span>${k}</span> `):` <span>${k}</span> `}else return` <span>${k}</span> `}),this.tilesetLayer.readyPromise.then(Z=>{if(Z.layer.environmentMapManager.enabled=!1,(c==null?void 0:c.light)==!1){const ct=new Cesium.CustomShader({lightingModel:Cesium.LightingModel.UNLIT});Z.layer.customShader=ct}m(Z)}).catch(Z=>{m()}),o&&Object.keys(o).forEach(Z=>{this.tilesetLayer.on(u.get(Z),ct=>{o[Z](ct)})}),S==0&&this.bimObliquePhotographyId.push(v),f?window.mapClone&&window.mapClone.mapEx.addLayer(this.tilesetLayer):window.map.addLayer(this.tilesetLayer)}).catch(X=>{m({tite:"【模型】「"+k+"」无法加载",type:"error",id:v,url:E})})}})}remove(a,o){let c=o==null?void 0:o.isClone;window.map.getLayer(a,"modelId")&&(c?(window.mapClone.mapEx.getLayer(a,"modelId").closeHighlight(),window.mapClone.mapEx.removeLayer(window.mapClone.mapEx.getLayer(a,"modelId"))):(window.map.getLayer(a,"modelId").closeHighlight(),window.map.removeLayer(window.map.getLayer(a,"modelId"))))}selected(a,o,c,f=!0){return new Promise((u,m)=>{let g=window.map.getLayer(a,"modelId");g?(g.style==null&&map.bimMapEdit=="0"&&g.openHighlight({color:"rgba(255,0,0,1)"},!0),f?g.flyTo({complete:()=>{u(g)}}):u(g)):this.add(a,o,c).then(v=>{v&&(v.style==null&&map.bimMapEdit=="0"&&v.openHighlight({color:"rgba(255,0,0,1)"},!0),f?v.flyTo({complete:()=>{u(v)}}):u(v))})})}initial(){this.modelArr=[],this.bimObliquePhotographyId=[],this.tilesetLayer=null}query(a){return this.modelArr.length==0?!1:this.modelArr.find(o=>o.id==a)}queryModel(a,o){return(o==null?void 0:o.isClone)?window.mapClone.mapEx.getLayer(a,"modelId"):window.map.getLayer(a,"modelId")}postEditDate(a){this.editDate={id:a}}editColor(a,o,c,f="true"){let u,m=c==null?void 0:c.isClone;if(typeof a!="object"&&(m?u=window.mapClone.mapEx.getLayer(a,"modelId"):u=window.map.getLayer(a,"modelId")),u)if(o)u.style={color:{conditions:[[f,o]]}};else{let g=this.query(a).bimModel?this.query(a).bimModel.modelColor:this.query(a).model.modelColor;g?u.style={color:{conditions:[[f,g]]}}:u.style=null}}editOpacity(a,o){window.map.getLayer(a,"modelId").opacity=o}addClip(a){return new Promise((o,c)=>{window.bimClip?o(bimClip.clipModelAdd(a)):c("挖洞工具未初始化")})}removeClip(a){window.bimClip&&window.bimClip.clipModelremoveClip(a)}componentDyeing(a,o=[],c="id"){let f=this.queryModel(a);const u=new Map;o.forEach(m=>{m.id.forEach(g=>{u.set(g,m.color)})}),f&&(f.style=m=>{const g=mars3d.Util.get3DTileFeatureAttr(m)[c];return u.get(g)||"rgba(255,255,255,0)"})}getLastDayOfMonth(a){const o=new Date(a.getFullYear(),a.getMonth()+1,1);return new Date(o-1)}async fadeOutModel(a,o=[],c=[],f=1,u=!1,m){if(c.length>0){let g=new Cesium.JulianDate.fromIso8601(c[0]),v=new Cesium.JulianDate.fromIso8601(c[1]),S;if(u?S=0:S=Cesium.JulianDate.secondsDifference(v,g),g&&v&&o.length>0){let b=this.queryModel(a);!b&&!m&&(b=await this.add(a));let O=this.componentColoringArray.find(I=>I.modelId==a),k=new Map;if(O)o.forEach(I=>{O.componentMap.set(I,{startTime:g,endTime:v,totalDuration:S,modelInit:f})});else{o.forEach(E=>{k.set(E,{startTime:g,endTime:v,totalDuration:S,modelInit:f})});let I=this.query(a).bimModel?this.query(a).bimModel.modelColor:this.query(a).model.modelColor,F;I&&(F=I.substring(0,I.lastIndexOf(","))+","),O={modelId:a,oldColorRgb:F,componentMap:k,modelInit:f},this.componentColoringArray.push(O)}window.map.viewer.clock.onTick.removeEventListener(this.componentonTick),window.map.viewer.clock.onTick.addEventListener(this.componentonTick)}}}convertComponentListToMap(a){return a.map(o=>{let c=this.query(o.modelId),f;const u=new Map;if(c){let{bimModel:m}=c,{modelColor:g}=m||c;g&&g!=""&&(f=(g==null?void 0:g.substring(0,g.lastIndexOf(",")))+",")}return o.componentList.forEach(m=>{u.set(m,{modelInit:0,totalDuration:0})}),{modelId:o.modelId,componentMap:u,oldColorRgb:f}})}fadeOutModel2(a,o=[],c=3e3,f=0){const u=Date.now();let m=this.query(a).bimModel?this.query(a).bimModel.modelColor:this.query(a).model.modelColor;const g=m.substring(0,m.lastIndexOf(","))+",",v=()=>{const O=(Date.now()-u)/c;if(O<1){let k;f==1?k=1-O:f==0&&(k=0+O);const I=bimModel.queryModel(a);I&&(I.style=F=>{if(o.length==0)return`rgba(255,0,0,${k})`;const E=mars3d.Util.get3DTileFeatureAttr(F).id;if(o.length!=0)return o.includes(E)?`rgba(255,0,0,${k})`:m}),requestAnimationFrame(v)}else{const k=bimModel.queryModel(a);k&&(k.style=I=>{const F=mars3d.Util.get3DTileFeatureAttr(I).id;if(o.length==0)return`${g}${1-f})`;if(o.length!=0)return o.includes(F)?`${g}${1-f})`:m})}};v()}}const su=x=>Object.prototype.toString.call(x)==="[object Object]";function au(){const x=Array.from(arguments);if(x.length<2)return x[0];let a=x[0];return x.shift(),x.forEach(o=>{if(su(o)){su(a)||(a={});for(let c in o)a[c]&&su(o[c])?a[c]=au(a[c],o[c]):a[c]=o[c]}else o instanceof Array&&(a instanceof Array||(a=[]),o.forEach((c,f)=>{su(c)?a[f]=au(a[f]):a[f]=c}))}),a}let vh={};const bf=(x,a,o)=>{vh={};let{vectorStyle:c,difference:f}=x;if(c){let{divType:u}=c,m="";if(u){let{theme_color:g,title:v,font_color:S,content:b,scaleByDistance:O,scaleByDistance_far:k,scaleByDistance_farValue:I,scaleByDistance_near:F,scaleByDistance_nearValue:E,distanceDisplayCondition:P,distanceDisplayCondition_far:w,distanceDisplayCondition_near:M,clampToGround:R,divStyle:C,isMirror:U}=c,{theme_color2:N,theme_color3:X}=C;switch(u){case"1":m=`<div class="entity-div-style entity-div-style1" style="--theme-color1:${g};--theme-font-color1:${S};">
|
|
2574
2574
|
<div class="title">${v}</div>
|
|
2575
2575
|
</div >`;break;case"2":m=`<div class="entity-div-style entity-div-style2" style="--theme-color1:${g};--theme-font-color1:${S};">
|
|
2576
2576
|
<div class="title">${v}</div>
|
|
2577
2577
|
<div class="mars3d-divUpLabel-line"></div>
|
|
2578
|
-
</div >`;break;case"3":m=`<div class="entity-div-style entity-div-style3" style="--theme-color1:${g};--theme-font-color1:${S};--theme-color2:${
|
|
2578
|
+
</div >`;break;case"3":m=`<div class="entity-div-style entity-div-style3" style="--theme-color1:${g};--theme-font-color1:${S};--theme-color2:${N};--theme-color3:${X}">
|
|
2579
2579
|
<div class="image"></div><div class="wave"></div><div class="wave"></div><div class="wave"></div>
|
|
2580
2580
|
<div class="infotop"><div class="title">${v}</div><div class="content overflow-auto scrollbar h-full">${b}</div></div>
|
|
2581
2581
|
</div >`;break;case"4":m=`<div class="entity-div-style entity-div-style4 ${U?"isMirror":""}" style="--theme-color1:${g};--theme-font-color1:${S};">
|
|
2582
2582
|
<div class="entity-title"><span class="title">${v}</span></div>
|
|
2583
2583
|
<div class="circular"></div>
|
|
2584
|
-
</div >`;break;case"5":m=`<div class="entity-div-style entity-div-style5 marsTiltPanel marsTiltPanel-theme-green" style="--theme-color1:${g};--theme-font-color1:${S};--theme-color2:${
|
|
2584
|
+
</div >`;break;case"5":m=`<div class="entity-div-style entity-div-style5 marsTiltPanel marsTiltPanel-theme-green" style="--theme-color1:${g};--theme-font-color1:${S};--theme-color2:${N};">
|
|
2585
2585
|
<div class="marsTiltPanel-wrap">
|
|
2586
2586
|
<div class="area">
|
|
2587
2587
|
<div class="arrow-lt"></div>
|
|
@@ -2599,7 +2599,7 @@ void main() {
|
|
|
2599
2599
|
<div class="b-b-r"></div>
|
|
2600
2600
|
</div>
|
|
2601
2601
|
<div class="arrow"></div>
|
|
2602
|
-
</div >`;break;case"6":m=`<div class="entity-div-style entity-div-style6" style="--theme-color1:${g};--theme-font-color1:${S};--theme-color2:${
|
|
2602
|
+
</div >`;break;case"6":m=`<div class="entity-div-style entity-div-style6" style="--theme-color1:${g};--theme-font-color1:${S};--theme-color2:${N};">
|
|
2603
2603
|
<div class="title">${v}</div>
|
|
2604
2604
|
</div >`;break;case"7":m=`<div class="entity-div-style entity-div-style7" style="--theme-color1:${g};--theme-font-color1:${S};">
|
|
2605
2605
|
<div class="title">${v}</div>
|
|
@@ -2607,16 +2607,16 @@ void main() {
|
|
|
2607
2607
|
<div class="circular"></div>
|
|
2608
2608
|
<div class="pole"></div>
|
|
2609
2609
|
</div>
|
|
2610
|
-
</div >`;break}vh={html:m,scaleByDistance:O,scaleByDistance_far:k,scaleByDistance_farValue:I,scaleByDistance_near:
|
|
2610
|
+
</div >`;break}vh={html:m,scaleByDistance:O,scaleByDistance_far:k,scaleByDistance_farValue:I,scaleByDistance_near:F,scaleByDistance_nearValue:E,distanceDisplayCondition:P,distanceDisplayCondition_far:w,distanceDisplayCondition_near:M,clampToGround:R}}else x.difference&&x.difference.length>0&&x.difference.forEach(g=>{au(vh,{[g]:c[g]})}),a&&a.difference&&a.difference.length>0&&a.difference.forEach(g=>{au(vh,{label:{[g]:a.labelStyle[g]}})})}return vh};var Er=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function tc(x){return x&&x.__esModule&&Object.prototype.hasOwnProperty.call(x,"default")?x.default:x}var lu={exports:{}};/**
|
|
2611
2611
|
* @license
|
|
2612
2612
|
* Lodash <https://lodash.com/>
|
|
2613
2613
|
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
2614
2614
|
* Released under MIT license <https://lodash.com/license>
|
|
2615
2615
|
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
2616
2616
|
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
2617
|
-
*/lu.exports,function(x,a){(function(){var o,c="4.17.21",f=200,u="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",m="Expected a function",g="Invalid `variable` option passed into `_.template`",v="__lodash_hash_undefined__",S=500,b="__lodash_placeholder__",O=1,k=2,I=4,N=1,E=2,P=1,w=2,M=4,R=8,C=16,U=32,F=64,X=128,K=256,Z=512,ct=30,Rt="...",tt=800,_t=16,G=1,Pt=2,Et=3,At=1/0,ce=9007199254740991,re=17976931348623157e292,Ft=0/0,It=4294967295,Nt=It-1,Pe=It>>>1,pe=[["ary",X],["bind",P],["bindKey",w],["curry",R],["curryRight",C],["flip",Z],["partial",U],["partialRight",F],["rearg",K]],Wt="[object Arguments]",$e="[object Array]",Si="[object AsyncFunction]",Oe="[object Boolean]",Ge="[object Date]",pi="[object DOMException]",Di="[object Error]",mn="[object Function]",Qi="[object GeneratorFunction]",W="[object Map]",Jt="[object Number]",jt="[object Null]",dt="[object Object]",pt="[object Promise]",Dt="[object Proxy]",ie="[object RegExp]",Kt="[object Set]",z="[object String]",Q="[object Symbol]",st="[object Undefined]",nt="[object WeakMap]",vt="[object WeakSet]",Ut="[object ArrayBuffer]",qt="[object DataView]",Xt="[object Float32Array]",Ne="[object Float64Array]",Ie="[object Int8Array]",me="[object Int16Array]",we="[object Int32Array]",yi="[object Uint8Array]",Ei="[object Uint8ClampedArray]",ni="[object Uint16Array]",bi="[object Uint32Array]",qr=/\b__p \+= '';/g,sr=/\b(__p \+=) '' \+/g,sn=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Ao=/&(?:amp|lt|gt|quot|#39);/g,zi=/[&<>"']/g,Yo=RegExp(Ao.source),ao=RegExp(zi.source),Hl=/<%-([\s\S]+?)%>/g,Mn=/<%([\s\S]+?)%>/g,ra=/<%=([\s\S]+?)%>/g,vs=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,vr=/^\w*$/,oa=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Za=/[\\^$.*+?()[\]{}|]/g,Vl=RegExp(Za.source),lo=/^\s+/,Oh=/\s/,sa=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Ja=/\{\n\/\* \[wrapped with (.+)\] \*/,ho=/,? & /,Wl=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,aa=/[()=,{}\[\]\/\s]/,la=/\\(\\)?/g,uo=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,jl=/\w*$/,Ih=/^[-+]0x[0-9a-f]+$/i,Dh=/^0b[01]+$/i,ys=/^\[object .+?Constructor\]$/,_s=/^0o[0-7]+$/i,Xl=/^(?:0|[1-9]\d*)$/,ql=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Yr=/($^)/,V=/['\n\r\u2028\u2029\\]/g,et="\\ud800-\\udfff",lt="\\u0300-\\u036f",at="\\ufe20-\\ufe2f",j="\\u20d0-\\u20ff",St=lt+at+j,ht="\\u2700-\\u27bf",Ot="a-z\\xdf-\\xf6\\xf8-\\xff",Gt="\\xac\\xb1\\xd7\\xf7",zt="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Mt="\\u2000-\\u206f",he=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",se="A-Z\\xc0-\\xd6\\xd8-\\xde",te="\\ufe0e\\ufe0f",ye=Gt+zt+Mt+he,ue="['’]",je="["+et+"]",He="["+ye+"]",ci="["+St+"]",Be="\\d+",_e="["+ht+"]",Fe="["+Ot+"]",fe="[^"+et+ye+Be+ht+Ot+se+"]",mi="\\ud83c[\\udffb-\\udfff]",Le="(?:"+ci+"|"+mi+")",xe="[^"+et+"]",Re="(?:\\ud83c[\\udde6-\\uddff]){2}",Sn="[\\ud800-\\udbff][\\udc00-\\udfff]",Xn="["+se+"]",ki="\\u200d",Bi="(?:"+Fe+"|"+fe+")",Hi="(?:"+Xn+"|"+fe+")",nn="(?:"+ue+"(?:d|ll|m|re|s|t|ve))?",rn="(?:"+ue+"(?:D|LL|M|RE|S|T|VE))?",un=Le+"?",cn="["+te+"]?",Gi="(?:"+ki+"(?:"+[xe,Re,Sn].join("|")+")"+cn+un+")*",Ni="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ji="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",gi=cn+un+Gi,co="(?:"+[_e,Re,Sn].join("|")+")"+gi,Fn="(?:"+[xe+ci+"?",ci,Re,Sn,je].join("|")+")",ha=RegExp(ue,"g"),zh=RegExp(ci,"g"),Zo=RegExp(mi+"(?="+mi+")|"+Fn+gi,"g"),$a=RegExp([Xn+"?"+Fe+"+"+nn+"(?="+[He,Xn,"$"].join("|")+")",Hi+"+"+rn+"(?="+[He,Xn+Bi,"$"].join("|")+")",Xn+"?"+Bi+"+"+nn,Xn+"+"+rn,ji,Ni,Be,co].join("|"),"g"),Ka=RegExp("["+ki+et+St+te+"]"),ua=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Qa=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ca=-1,Xi={};Xi[Xt]=Xi[Ne]=Xi[Ie]=Xi[me]=Xi[we]=Xi[yi]=Xi[Ei]=Xi[ni]=Xi[bi]=!0,Xi[Wt]=Xi[$e]=Xi[Ut]=Xi[Oe]=Xi[qt]=Xi[Ge]=Xi[Di]=Xi[mn]=Xi[W]=Xi[Jt]=Xi[dt]=Xi[ie]=Xi[Kt]=Xi[z]=Xi[nt]=!1;var xi={};xi[Wt]=xi[$e]=xi[Ut]=xi[qt]=xi[Oe]=xi[Ge]=xi[Xt]=xi[Ne]=xi[Ie]=xi[me]=xi[we]=xi[W]=xi[Jt]=xi[dt]=xi[ie]=xi[Kt]=xi[z]=xi[Q]=xi[yi]=xi[Ei]=xi[ni]=xi[bi]=!0,xi[Di]=xi[mn]=xi[nt]=!1;var tl={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},fa={"&":"&","<":"<",">":">",'"':""","'":"'"},el={"&":"&","<":"<",">":">",""":'"',"'":"'"},xs={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},il=parseFloat,da=parseInt,pa=typeof Er=="object"&&Er&&Er.Object===Object&&Er,ma=typeof self=="object"&&self&&self.Object===Object&&self,gn=pa||ma||Function("return this")(),Jo=a&&!a.nodeType&&a,Zr=Jo&&!0&&x&&!x.nodeType&&x,ws=Zr&&Zr.exports===Jo,Ts=ws&&pa.process,Un=function(){try{var Lt=Zr&&Zr.require&&Zr.require("util").types;return Lt||Ts&&Ts.binding&&Ts.binding("util")}catch{}}(),kh=Un&&Un.isArrayBuffer,ga=Un&&Un.isDate,va=Un&&Un.isMap,Su=Un&&Un.isRegExp,Eu=Un&&Un.isSet,Yl=Un&&Un.isTypedArray;function yr(Lt,Qt,Zt){switch(Zt.length){case 0:return Lt.call(Qt);case 1:return Lt.call(Qt,Zt[0]);case 2:return Lt.call(Qt,Zt[0],Zt[1]);case 3:return Lt.call(Qt,Zt[0],Zt[1],Zt[2])}return Lt.apply(Qt,Zt)}function Zl(Lt,Qt,Zt,Ue){for(var ai=-1,Fi=Lt==null?0:Lt.length;++ai<Fi;){var fn=Lt[ai];Qt(Ue,fn,Zt(fn),Lt)}return Ue}function Ji(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length;++Zt<Ue&&Qt(Lt[Zt],Zt,Lt)!==!1;);return Lt}function Ms(Lt,Qt){for(var Zt=Lt==null?0:Lt.length;Zt--&&Qt(Lt[Zt],Zt,Lt)!==!1;);return Lt}function Bh(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length;++Zt<Ue;)if(!Qt(Lt[Zt],Zt,Lt))return!1;return!0}function Rr(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length,ai=0,Fi=[];++Zt<Ue;){var fn=Lt[Zt];Qt(fn,Zt,Lt)&&(Fi[ai++]=fn)}return Fi}function nl(Lt,Qt){var Zt=Lt==null?0:Lt.length;return!!Zt&&Or(Lt,Qt,0)>-1}function Jl(Lt,Qt,Zt){for(var Ue=-1,ai=Lt==null?0:Lt.length;++Ue<ai;)if(Zt(Qt,Lt[Ue]))return!0;return!1}function Yi(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length,ai=Array(Ue);++Zt<Ue;)ai[Zt]=Qt(Lt[Zt],Zt,Lt);return ai}function fo(Lt,Qt){for(var Zt=-1,Ue=Qt.length,ai=Lt.length;++Zt<Ue;)Lt[ai+Zt]=Qt[Zt];return Lt}function $l(Lt,Qt,Zt,Ue){var ai=-1,Fi=Lt==null?0:Lt.length;for(Ue&&Fi&&(Zt=Lt[++ai]);++ai<Fi;)Zt=Qt(Zt,Lt[ai],ai,Lt);return Zt}function bu(Lt,Qt,Zt,Ue){var ai=Lt==null?0:Lt.length;for(Ue&&ai&&(Zt=Lt[--ai]);ai--;)Zt=Qt(Zt,Lt[ai],ai,Lt);return Zt}function Po(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length;++Zt<Ue;)if(Qt(Lt[Zt],Zt,Lt))return!0;return!1}var po=Ko("length");function Cu(Lt){return Lt.split("")}function rl(Lt){return Lt.match(Wl)||[]}function Ss(Lt,Qt,Zt){var Ue;return Zt(Lt,function(ai,Fi,fn){if(Qt(ai,Fi,fn))return Ue=Fi,!1}),Ue}function $o(Lt,Qt,Zt,Ue){for(var ai=Lt.length,Fi=Zt+(Ue?1:-1);Ue?Fi--:++Fi<ai;)if(Qt(Lt[Fi],Fi,Lt))return Fi;return-1}function Or(Lt,Qt,Zt){return Qt===Qt?Kl(Lt,Qt,Zt):$o(Lt,Es,Zt)}function ol(Lt,Qt,Zt,Ue){for(var ai=Zt-1,Fi=Lt.length;++ai<Fi;)if(Ue(Lt[ai],Qt))return ai;return-1}function Es(Lt){return Lt!==Lt}function ya(Lt,Qt){var Zt=Lt==null?0:Lt.length;return Zt?ts(Lt,Qt)/Zt:Ft}function Ko(Lt){return function(Qt){return Qt==null?o:Qt[Lt]}}function Lo(Lt){return function(Qt){return Lt==null?o:Lt[Qt]}}function Qo(Lt,Qt,Zt,Ue,ai){return ai(Lt,function(Fi,fn,Ee){Zt=Ue?(Ue=!1,Fi):Qt(Zt,Fi,fn,Ee)}),Zt}function Au(Lt,Qt){var Zt=Lt.length;for(Lt.sort(Qt);Zt--;)Lt[Zt]=Lt[Zt].value;return Lt}function ts(Lt,Qt){for(var Zt,Ue=-1,ai=Lt.length;++Ue<ai;){var Fi=Qt(Lt[Ue]);Fi!==o&&(Zt=Zt===o?Fi:Zt+Fi)}return Zt}function Ro(Lt,Qt){for(var Zt=-1,Ue=Array(Lt);++Zt<Lt;)Ue[Zt]=Qt(Zt);return Ue}function Oo(Lt,Qt){return Yi(Qt,function(Zt){return[Zt,Lt[Zt]]})}function _a(Lt){return Lt&&Lt.slice(0,xa(Lt)+1).replace(lo,"")}function Gn(Lt){return function(Qt){return Lt(Qt)}}function bs(Lt,Qt){return Yi(Qt,function(Zt){return Lt[Zt]})}function mo(Lt,Qt){return Lt.has(Qt)}function es(Lt,Qt){for(var Zt=-1,Ue=Lt.length;++Zt<Ue&&Or(Qt,Lt[Zt],0)>-1;);return Zt}function Cs(Lt,Qt){for(var Zt=Lt.length;Zt--&&Or(Qt,Lt[Zt],0)>-1;);return Zt}function go(Lt,Qt){for(var Zt=Lt.length,Ue=0;Zt--;)Lt[Zt]===Qt&&++Ue;return Ue}var As=Lo(tl),Jr=Lo(fa);function Ps(Lt){return"\\"+xs[Lt]}function Ls(Lt,Qt){return Lt==null?o:Lt[Qt]}function Ir(Lt){return Ka.test(Lt)}function Rs(Lt){return ua.test(Lt)}function Os(Lt){for(var Qt,Zt=[];!(Qt=Lt.next()).done;)Zt.push(Qt.value);return Zt}function $n(Lt){var Qt=-1,Zt=Array(Lt.size);return Lt.forEach(function(Ue,ai){Zt[++Qt]=[ai,Ue]}),Zt}function sl(Lt,Qt){return function(Zt){return Lt(Qt(Zt))}}function Dr(Lt,Qt){for(var Zt=-1,Ue=Lt.length,ai=0,Fi=[];++Zt<Ue;){var fn=Lt[Zt];(fn===Qt||fn===b)&&(Lt[Zt]=b,Fi[ai++]=Zt)}return Fi}function Is(Lt){var Qt=-1,Zt=Array(Lt.size);return Lt.forEach(function(Ue){Zt[++Qt]=Ue}),Zt}function Hn(Lt){var Qt=-1,Zt=Array(Lt.size);return Lt.forEach(function(Ue){Zt[++Qt]=[Ue,Ue]}),Zt}function Kl(Lt,Qt,Zt){for(var Ue=Zt-1,ai=Lt.length;++Ue<ai;)if(Lt[Ue]===Qt)return Ue;return-1}function Ql(Lt,Qt,Zt){for(var Ue=Zt+1;Ue--;)if(Lt[Ue]===Qt)return Ue;return Ue}function $r(Lt){return Ir(Lt)?wa(Lt):po(Lt)}function ar(Lt){return Ir(Lt)?_r(Lt):Cu(Lt)}function xa(Lt){for(var Qt=Lt.length;Qt--&&Oh.test(Lt.charAt(Qt)););return Qt}var th=Lo(el);function wa(Lt){for(var Qt=Zo.lastIndex=0;Zo.test(Lt);)++Qt;return Qt}function _r(Lt){return Lt.match(Zo)||[]}function jc(Lt){return Lt.match($a)||[]}var Xc=function Lt(Qt){Qt=Qt==null?gn:is.defaults(gn.Object(),Qt,is.pick(gn,Qa));var Zt=Qt.Array,Ue=Qt.Date,ai=Qt.Error,Fi=Qt.Function,fn=Qt.Math,Ee=Qt.Object,Kn=Qt.RegExp,Ta=Qt.String,lr=Qt.TypeError,On=Zt.prototype,Pu=Fi.prototype,vo=Ee.prototype,ns=Qt["__core-js_shared__"],hr=Pu.toString,Ti=vo.hasOwnProperty,ur=0,zr=function(){var r=/[^.]+$/.exec(ns&&ns.keys&&ns.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""}(),cr=vo.toString,yo=hr.call(Ee),Kr=gn._,Io=Kn("^"+hr.call(Ti).replace(Za,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),fr=ws?Qt.Buffer:o,Qn=Qt.Symbol,tn=Qt.Uint8Array,al=fr?fr.allocUnsafe:o,_o=sl(Ee.getPrototypeOf,Ee),ll=Ee.create,hl=vo.propertyIsEnumerable,Ds=On.splice,Ma=Qn?Qn.isConcatSpreadable:o,rs=Qn?Qn.iterator:o,xo=Qn?Qn.toStringTag:o,zs=function(){try{var r=bl(Ee,"defineProperty");return r({},"",{}),r}catch{}}(),eh=Qt.clearTimeout!==gn.clearTimeout&&Qt.clearTimeout,ih=Ue&&Ue.now!==gn.Date.now&&Ue.now,Nh=Qt.setTimeout!==gn.setTimeout&&Qt.setTimeout,Do=fn.ceil,ks=fn.floor,ul=Ee.getOwnPropertySymbols,Fh=fr?fr.isBuffer:o,nh=Qt.isFinite,Uh=On.join,Lu=sl(Ee.keys,Ee),vn=fn.max,Vn=fn.min,cl=Ue.now,Gh=Qt.parseInt,rh=fn.random,Sa=On.reverse,fl=bl(Qt,"DataView"),Bs=bl(Qt,"Map"),dl=bl(Qt,"Promise"),Ns=bl(Qt,"Set"),En=bl(Qt,"WeakMap"),Ea=bl(Ee,"create"),pl=En&&new En,os={},oh=Cl(fl),Hh=Cl(Bs),Vh=Cl(dl),Wh=Cl(Ns),Ru=Cl(En),ml=Qn?Qn.prototype:o,Fs=ml?ml.valueOf:o,jh=ml?ml.toString:o;function it(r){if(Ln(r)&&!vi(r)&&!(r instanceof _i)){if(r instanceof qn)return r;if(Ti.call(r,"__wrapped__"))return sp(r)}return new qn(r)}var ss=function(){function r(){}return function(h){if(!wn(h))return{};if(ll)return ll(h);r.prototype=h;var y=new r;return r.prototype=o,y}}();function ba(){}function qn(r,h){this.__wrapped__=r,this.__actions__=[],this.__chain__=!!h,this.__index__=0,this.__values__=o}it.templateSettings={escape:Hl,evaluate:Mn,interpolate:ra,variable:"",imports:{_:it}},it.prototype=ba.prototype,it.prototype.constructor=it,qn.prototype=ss(ba.prototype),qn.prototype.constructor=qn;function _i(r){this.__wrapped__=r,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=It,this.__views__=[]}function Ca(){var r=new _i(this.__wrapped__);return r.__actions__=er(this.__actions__),r.__dir__=this.__dir__,r.__filtered__=this.__filtered__,r.__iteratees__=er(this.__iteratees__),r.__takeCount__=this.__takeCount__,r.__views__=er(this.__views__),r}function Ou(){if(this.__filtered__){var r=new _i(this);r.__dir__=-1,r.__filtered__=!0}else r=this.clone(),r.__dir__*=-1;return r}function Aa(){var r=this.__wrapped__.value(),h=this.__dir__,y=vi(r),D=h<0,Y=y?r.length:0,ut=Zg(0,Y,this.__views__),yt=ut.start,bt=ut.end,Bt=bt-yt,oe=D?bt:yt-1,le=this.__iteratees__,de=le.length,ke=0,Ze=Vn(Bt,this.__takeCount__);if(!y||!D&&Y==Bt&&Ze==Bt)return ri(r,this.__actions__);var hi=[];t:for(;Bt--&&ke<Ze;){oe+=h;for(var Mi=-1,ui=r[oe];++Mi<de;){var Ri=le[Mi],Ui=Ri.iteratee,eo=Ri.type,Sr=Ui(ui);if(eo==Pt)ui=Sr;else if(!Sr){if(eo==G)continue t;break t}}hi[ke++]=ui}return hi}_i.prototype=ss(ba.prototype),_i.prototype.constructor=_i;function kr(r){var h=-1,y=r==null?0:r.length;for(this.clear();++h<y;){var D=r[h];this.set(D[0],D[1])}}function Pa(){this.__data__=Ea?Ea(null):{},this.size=0}function La(r){var h=this.has(r)&&delete this.__data__[r];return this.size-=h?1:0,h}function gl(r){var h=this.__data__;if(Ea){var y=h[r];return y===v?o:y}return Ti.call(h,r)?h[r]:o}function sh(r){var h=this.__data__;return Ea?h[r]!==o:Ti.call(h,r)}function vl(r,h){var y=this.__data__;return this.size+=this.has(r)?0:1,y[r]=Ea&&h===o?v:h,this}kr.prototype.clear=Pa,kr.prototype.delete=La,kr.prototype.get=gl,kr.prototype.has=sh,kr.prototype.set=vl;function dr(r){var h=-1,y=r==null?0:r.length;for(this.clear();++h<y;){var D=r[h];this.set(D[0],D[1])}}function yl(){this.__data__=[],this.size=0}function zo(r){var h=this.__data__,y=wl(h,r);if(y<0)return!1;var D=h.length-1;return y==D?h.pop():Ds.call(h,y,1),--this.size,!0}function _l(r){var h=this.__data__,y=wl(h,r);return y<0?o:h[y][1]}function xl(r){return wl(this.__data__,r)>-1}function ko(r,h){var y=this.__data__,D=wl(y,r);return D<0?(++this.size,y.push([r,h])):y[D][1]=h,this}dr.prototype.clear=yl,dr.prototype.delete=zo,dr.prototype.get=_l,dr.prototype.has=xl,dr.prototype.set=ko;function xr(r){var h=-1,y=r==null?0:r.length;for(this.clear();++h<y;){var D=r[h];this.set(D[0],D[1])}}function Iu(){this.size=0,this.__data__={hash:new kr,map:new(Bs||dr),string:new kr}}function Du(r){var h=Wu(this,r).delete(r);return this.size-=h?1:0,h}function Xh(r){return Wu(this,r).get(r)}function di(r){return Wu(this,r).has(r)}function as(r,h){var y=Wu(this,r),D=y.size;return y.set(r,h),this.size+=y.size==D?0:1,this}xr.prototype.clear=Iu,xr.prototype.delete=Du,xr.prototype.get=Xh,xr.prototype.has=di,xr.prototype.set=as;function Us(r){var h=-1,y=r==null?0:r.length;for(this.__data__=new xr;++h<y;)this.add(r[h])}function Ci(r){return this.__data__.set(r,v),this}function Bn(r){return this.__data__.has(r)}Us.prototype.add=Us.prototype.push=Ci,Us.prototype.has=Bn;function Qr(r){var h=this.__data__=new dr(r);this.size=h.size}function qe(){this.__data__=new dr,this.size=0}function wo(r){var h=this.__data__,y=h.delete(r);return this.size=h.size,y}function qc(r){return this.__data__.get(r)}function Yc(r){return this.__data__.has(r)}function Zc(r,h){var y=this.__data__;if(y instanceof dr){var D=y.__data__;if(!Bs||D.length<f-1)return D.push([r,h]),this.size=++y.size,this;y=this.__data__=new xr(D)}return y.set(r,h),this.size=y.size,this}Qr.prototype.clear=qe,Qr.prototype.delete=wo,Qr.prototype.get=qc,Qr.prototype.has=Yc,Qr.prototype.set=Zc;function zu(r,h){var y=vi(r),D=!y&&Al(r),Y=!y&&!D&&Ba(r),ut=!y&&!D&&!Y&&mh(r),yt=y||D||Y||ut,bt=yt?Ro(r.length,Ta):[],Bt=bt.length;for(var oe in r)(h||Ti.call(r,oe))&&!(yt&&(oe=="length"||Y&&(oe=="offset"||oe=="parent")||ut&&(oe=="buffer"||oe=="byteLength"||oe=="byteOffset")||js(oe,Bt)))&&bt.push(oe);return bt}function qh(r){var h=r.length;return h?r[ge(0,h-1)]:o}function Jc(r,h){return ju(er(r),ls(h,0,r.length))}function ku(r){return ju(er(r))}function ah(r,h,y){(y!==o&&!Uo(r[h],y)||y===o&&!(h in r))&&Bo(r,h,y)}function Ra(r,h,y){var D=r[h];(!(Ti.call(r,h)&&Uo(D,y))||y===o&&!(h in r))&&Bo(r,h,y)}function wl(r,h){for(var y=r.length;y--;)if(Uo(r[y][0],h))return y;return-1}function Bu(r,h,y,D){return yn(r,function(Y,ut,yt){h(D,Y,y(Y),yt)}),D}function Yh(r,h){return r&&In(h,Jn(h),r)}function Zh(r,h){return r&&In(h,Ur(h),r)}function Bo(r,h,y){h=="__proto__"&&zs?zs(r,h,{configurable:!0,enumerable:!0,value:y,writable:!0}):r[h]=y}function Jh(r,h){for(var y=-1,D=h.length,Y=Zt(D),ut=r==null;++y<D;)Y[y]=ut?o:df(r,h[y]);return Y}function ls(r,h,y){return r===r&&(y!==o&&(r=r<=y?r:y),h!==o&&(r=r>=h?r:h)),r}function wr(r,h,y,D,Y,ut){var yt,bt=h&O,Bt=h&k,oe=h&I;if(y&&(yt=Y?y(r,D,Y,ut):y(r)),yt!==o)return yt;if(!wn(r))return r;var le=vi(r);if(le){if(yt=$g(r),!bt)return er(r,yt)}else{var de=mr(r),ke=de==mn||de==Qi;if(Ba(r))return No(r,bt);if(de==dt||de==Wt||ke&&!Y){if(yt=Bt||ke?{}:$d(r),!bt)return Bt?Gu(r,Zh(yt,r)):So(r,Yh(yt,r))}else{if(!xi[de])return Y?r:{};yt=Kg(r,de,bt)}}ut||(ut=new Qr);var Ze=ut.get(r);if(Ze)return Ze;ut.set(r,yt),bp(r)?r.forEach(function(ui){yt.add(wr(ui,h,y,ui,r,ut))}):Sp(r)&&r.forEach(function(ui,Ri){yt.set(Ri,wr(ui,h,y,Ri,r,ut))});var hi=oe?Bt?Kc:$c:Bt?Ur:Jn,Mi=le?o:hi(r);return Ji(Mi||r,function(ui,Ri){Mi&&(Ri=ui,ui=r[Ri]),Ra(yt,Ri,wr(ui,h,y,Ri,r,ut))}),yt}function Oa(r){var h=Jn(r);return function(y){return Nu(y,r,h)}}function Nu(r,h,y){var D=y.length;if(r==null)return!D;for(r=Ee(r);D--;){var Y=y[D],ut=h[Y],yt=r[Y];if(yt===o&&!(Y in r)||!ut(yt))return!1}return!0}function To(r,h,y){if(typeof r!="function")throw new lr(m);return ru(function(){r.apply(o,y)},h)}function Tl(r,h,y,D){var Y=-1,ut=nl,yt=!0,bt=r.length,Bt=[],oe=h.length;if(!bt)return Bt;y&&(h=Yi(h,Gn(y))),D?(ut=Jl,yt=!1):h.length>=f&&(ut=mo,yt=!1,h=new Us(h));t:for(;++Y<bt;){var le=r[Y],de=y==null?le:y(le);if(le=D||le!==0?le:0,yt&&de===de){for(var ke=oe;ke--;)if(h[ke]===de)continue t;Bt.push(le)}else ut(h,de,D)||Bt.push(le)}return Bt}var yn=ft(Nr),Fu=ft(hh,!0);function Yn(r,h){var y=!0;return yn(r,function(D,Y,ut){return y=!!h(D,Y,ut),y}),y}function Mo(r,h,y){for(var D=-1,Y=r.length;++D<Y;){var ut=r[D],yt=h(ut);if(yt!=null&&(bt===o?yt===yt&&!to(yt):y(yt,bt)))var bt=yt,Bt=ut}return Bt}function tr(r,h,y,D){var Y=r.length;for(y=wi(y),y<0&&(y=-y>Y?0:Y+y),D=D===o||D>Y?Y:wi(D),D<0&&(D+=Y),D=y>D?0:Ap(D);y<D;)r[y++]=h;return r}function Br(r,h){var y=[];return yn(r,function(D,Y,ut){h(D,Y,ut)&&y.push(D)}),y}function bn(r,h,y,D,Y){var ut=-1,yt=r.length;for(y||(y=t0),Y||(Y=[]);++ut<yt;){var bt=r[ut];h>0&&y(bt)?h>1?bn(bt,h-1,y,D,Y):fo(Y,bt):D||(Y[Y.length]=bt)}return Y}var Ml=Tt(),lh=Tt(!0);function Nr(r,h){return r&&Ml(r,h,Jn)}function hh(r,h){return r&&lh(r,h,Jn)}function Gs(r,h){return Rr(h,function(y){return Xs(r[y])})}function hs(r,h){h=Je(h,r);for(var y=0,D=h.length;r!=null&&y<D;)r=r[cs(h[y++])];return y&&y==D?r:o}function Uu(r,h,y){var D=h(r);return vi(r)?D:fo(D,y(r))}function Zn(r){return r==null?r===o?st:jt:xo&&xo in Ee(r)?Yg(r):a0(r)}function uh(r,h){return r>h}function ch(r,h){return r!=null&&Ti.call(r,h)}function $h(r,h){return r!=null&&h in Ee(r)}function fh(r,h,y){return r>=Vn(h,y)&&r<vn(h,y)}function Sl(r,h,y){for(var D=y?Jl:nl,Y=r[0].length,ut=r.length,yt=ut,bt=Zt(ut),Bt=1/0,oe=[];yt--;){var le=r[yt];yt&&h&&(le=Yi(le,Gn(h))),Bt=Vn(le.length,Bt),bt[yt]=!y&&(h||Y>=120&&le.length>=120)?new Us(yt&&le):o}le=r[0];var de=-1,ke=bt[0];t:for(;++de<Y&&oe.length<Bt;){var Ze=le[de],hi=h?h(Ze):Ze;if(Ze=y||Ze!==0?Ze:0,!(ke?mo(ke,hi):D(oe,hi,y))){for(yt=ut;--yt;){var Mi=bt[yt];if(!(Mi?mo(Mi,hi):D(r[yt],hi,y)))continue t}ke&&ke.push(hi),oe.push(Ze)}}return oe}function t(r,h,y,D){return Nr(r,function(Y,ut,yt){h(D,y(Y),ut,yt)}),D}function e(r,h,y){h=Je(h,r),r=ep(r,h);var D=r==null?r:r[cs(bo(h))];return D==null?o:yr(D,r,y)}function i(r){return Ln(r)&&Zn(r)==Wt}function n(r){return Ln(r)&&Zn(r)==Ut}function s(r){return Ln(r)&&Zn(r)==Ge}function l(r,h,y,D,Y){return r===h?!0:r==null||h==null||!Ln(r)&&!Ln(h)?r!==r&&h!==h:d(r,h,y,D,l,Y)}function d(r,h,y,D,Y,ut){var yt=vi(r),bt=vi(h),Bt=yt?$e:mr(r),oe=bt?$e:mr(h);Bt=Bt==Wt?dt:Bt,oe=oe==Wt?dt:oe;var le=Bt==dt,de=oe==dt,ke=Bt==oe;if(ke&&Ba(r)){if(!Ba(h))return!1;yt=!0,le=!1}if(ke&&!le)return ut||(ut=new Qr),yt||mh(r)?Yd(r,h,y,D,Y,ut):Xg(r,h,Bt,y,D,Y,ut);if(!(y&N)){var Ze=le&&Ti.call(r,"__wrapped__"),hi=de&&Ti.call(h,"__wrapped__");if(Ze||hi){var Mi=Ze?r.value():r,ui=hi?h.value():h;return ut||(ut=new Qr),Y(Mi,ui,y,D,ut)}}return ke?(ut||(ut=new Qr),qg(r,h,y,D,Y,ut)):!1}function p(r){return Ln(r)&&mr(r)==W}function _(r,h,y,D){var Y=y.length,ut=Y,yt=!D;if(r==null)return!ut;for(r=Ee(r);Y--;){var bt=y[Y];if(yt&&bt[2]?bt[1]!==r[bt[0]]:!(bt[0]in r))return!1}for(;++Y<ut;){bt=y[Y];var Bt=bt[0],oe=r[Bt],le=bt[1];if(yt&&bt[2]){if(oe===o&&!(Bt in r))return!1}else{var de=new Qr;if(D)var ke=D(oe,le,Bt,r,h,de);if(!(ke===o?l(le,oe,N|E,D,de):ke))return!1}}return!0}function T(r){if(!wn(r)||i0(r))return!1;var h=Xs(r)?Io:ys;return h.test(Cl(r))}function A(r){return Ln(r)&&Zn(r)==ie}function L(r){return Ln(r)&&mr(r)==Kt}function B(r){return Ln(r)&&$u(r.length)&&!!Xi[Zn(r)]}function H(r){return typeof r=="function"?r:r==null?Gr:typeof r=="object"?vi(r)?Ct(r[0],r[1]):gt(r):Fp(r)}function q(r){if(!nu(r))return Lu(r);var h=[];for(var y in Ee(r))Ti.call(r,y)&&y!="constructor"&&h.push(y);return h}function J(r){if(!wn(r))return s0(r);var h=nu(r),y=[];for(var D in r)D=="constructor"&&(h||!Ti.call(r,D))||y.push(D);return y}function rt(r,h){return r<h}function xt(r,h){var y=-1,D=Fr(r)?Zt(r.length):[];return yn(r,function(Y,ut,yt){D[++y]=h(Y,ut,yt)}),D}function gt(r){var h=tf(r);return h.length==1&&h[0][2]?Qd(h[0][0],h[0][1]):function(y){return y===r||_(y,r,h)}}function Ct(r,h){return nf(r)&&Kd(h)?Qd(cs(r),h):function(y){var D=df(y,r);return D===o&&D===h?pf(y,r):l(h,D,N|E)}}function wt(r,h,y,D,Y){r!==h&&Ml(h,function(ut,yt){if(Y||(Y=new Qr),wn(ut))Vt(r,h,yt,y,wt,D,Y);else{var bt=D?D(of(r,yt),ut,yt+"",r,h,Y):o;bt===o&&(bt=ut),ah(r,yt,bt)}},Ur)}function Vt(r,h,y,D,Y,ut,yt){var bt=of(r,y),Bt=of(h,y),oe=yt.get(Bt);if(oe){ah(r,y,oe);return}var le=ut?ut(bt,Bt,y+"",r,h,yt):o,de=le===o;if(de){var ke=vi(Bt),Ze=!ke&&Ba(Bt),hi=!ke&&!Ze&&mh(Bt);le=Bt,ke||Ze||hi?vi(bt)?le=bt:Dn(bt)?le=er(bt):Ze?(de=!1,le=No(Bt,!0)):hi?(de=!1,le=El(Bt,!0)):le=[]:ou(Bt)||Al(Bt)?(le=bt,Al(bt)?le=Pp(bt):(!wn(bt)||Xs(bt))&&(le=$d(Bt))):de=!1}de&&(yt.set(Bt,le),Y(le,Bt,D,ut,yt),yt.delete(Bt)),ah(r,y,le)}function $(r,h){var y=r.length;if(y)return h+=h<0?y:0,js(h,y)?r[h]:o}function ot(r,h,y){h.length?h=Yi(h,function(ut){return vi(ut)?function(yt){return hs(yt,ut.length===1?ut[0]:ut)}:ut}):h=[Gr];var D=-1;h=Yi(h,Gn(si()));var Y=xt(r,function(ut,yt,bt){var Bt=Yi(h,function(oe){return oe(ut)});return{criteria:Bt,index:++D,value:ut}});return Au(Y,function(ut,yt){return us(ut,yt,y)})}function kt(r,h){return ee(r,h,function(y,D){return pf(r,D)})}function ee(r,h,y){for(var D=-1,Y=h.length,ut={};++D<Y;){var yt=h[D],bt=hs(r,yt);y(bt,yt)&&fi(ut,Je(yt,r),bt)}return ut}function $t(r){return function(h){return hs(h,r)}}function Yt(r,h,y,D){var Y=D?ol:Or,ut=-1,yt=h.length,bt=r;for(r===h&&(h=er(h)),y&&(bt=Yi(r,Gn(y)));++ut<yt;)for(var Bt=0,oe=h[ut],le=y?y(oe):oe;(Bt=Y(bt,le,Bt,D))>-1;)bt!==r&&Ds.call(bt,Bt,1),Ds.call(r,Bt,1);return r}function Te(r,h){for(var y=r?h.length:0,D=y-1;y--;){var Y=h[y];if(y==D||Y!==ut){var ut=Y;js(Y)?Ds.call(r,Y,1):Wi(r,Y)}}return r}function ge(r,h){return r+ks(rh()*(h-r+1))}function De(r,h,y,D){for(var Y=-1,ut=vn(Do((h-r)/(y||1)),0),yt=Zt(ut);ut--;)yt[D?ut:++Y]=r,r+=y;return yt}function be(r,h){var y="";if(!r||h<1||h>ce)return y;do h%2&&(y+=r),h=ks(h/2),h&&(r+=r);while(h);return y}function ae(r,h){return sf(tp(r,h,Gr),r+"")}function We(r){return qh(gh(r))}function Qe(r,h){var y=gh(r);return ju(y,ls(h,0,y.length))}function fi(r,h,y,D){if(!wn(r))return r;h=Je(h,r);for(var Y=-1,ut=h.length,yt=ut-1,bt=r;bt!=null&&++Y<ut;){var Bt=cs(h[Y]),oe=y;if(Bt==="__proto__"||Bt==="constructor"||Bt==="prototype")return r;if(Y!=yt){var le=bt[Bt];oe=D?D(le,Bt,bt):o,oe===o&&(oe=wn(le)?le:js(h[Y+1])?[]:{})}Ra(bt,Bt,oe),bt=bt[Bt]}return r}var Cn=pl?function(r,h){return pl.set(r,h),r}:Gr,_n=zs?function(r,h){return zs(r,"toString",{configurable:!0,enumerable:!1,value:gf(h),writable:!0})}:Gr;function qi(r){return ju(gh(r))}function Vi(r,h,y){var D=-1,Y=r.length;h<0&&(h=-h>Y?0:Y+h),y=y>Y?Y:y,y<0&&(y+=Y),Y=h>y?0:y-h>>>0,h>>>=0;for(var ut=Zt(Y);++D<Y;)ut[D]=r[D+h];return ut}function on(r,h){var y;return yn(r,function(D,Y,ut){return y=h(D,Y,ut),!y}),!!y}function An(r,h,y){var D=0,Y=r==null?D:r.length;if(typeof h=="number"&&h===h&&Y<=Pe){for(;D<Y;){var ut=D+Y>>>1,yt=r[ut];yt!==null&&!to(yt)&&(y?yt<=h:yt<h)?D=ut+1:Y=ut}return Y}return Ce(r,h,Gr,y)}function Ce(r,h,y,D){var Y=0,ut=r==null?0:r.length;if(ut===0)return 0;h=y(h);for(var yt=h!==h,bt=h===null,Bt=to(h),oe=h===o;Y<ut;){var le=ks((Y+ut)/2),de=y(r[le]),ke=de!==o,Ze=de===null,hi=de===de,Mi=to(de);if(yt)var ui=D||hi;else oe?ui=hi&&(D||ke):bt?ui=hi&&ke&&(D||!Ze):Bt?ui=hi&&ke&&!Ze&&(D||!Mi):Ze||Mi?ui=!1:ui=D?de<=h:de<h;ui?Y=le+1:ut=le}return Vn(ut,Nt)}function ti(r,h){for(var y=-1,D=r.length,Y=0,ut=[];++y<D;){var yt=r[y],bt=h?h(yt):yt;if(!y||!Uo(bt,Bt)){var Bt=bt;ut[Y++]=yt===0?0:yt}}return ut}function Ht(r){return typeof r=="number"?r:to(r)?Ft:+r}function Ye(r){if(typeof r=="string")return r;if(vi(r))return Yi(r,Ye)+"";if(to(r))return jh?jh.call(r):"";var h=r+"";return h=="0"&&1/r==-At?"-0":h}function ei(r,h,y){var D=-1,Y=nl,ut=r.length,yt=!0,bt=[],Bt=bt;if(y)yt=!1,Y=Jl;else if(ut>=f){var oe=h?null:ka(r);if(oe)return Is(oe);yt=!1,Y=mo,Bt=new Us}else Bt=h?[]:bt;t:for(;++D<ut;){var le=r[D],de=h?h(le):le;if(le=y||le!==0?le:0,yt&&de===de){for(var ke=Bt.length;ke--;)if(Bt[ke]===de)continue t;h&&Bt.push(de),bt.push(le)}else Y(Bt,de,y)||(Bt!==bt&&Bt.push(de),bt.push(le))}return bt}function Wi(r,h){return h=Je(h,r),r=ep(r,h),r==null||delete r[cs(bo(h))]}function Ae(r,h,y,D){return fi(r,h,y(hs(r,h)),D)}function Xe(r,h,y,D){for(var Y=r.length,ut=D?Y:-1;(D?ut--:++ut<Y)&&h(r[ut],ut,r););return y?Vi(r,D?0:ut,D?ut+1:Y):Vi(r,D?ut+1:0,D?Y:ut)}function ri(r,h){var y=r;return y instanceof _i&&(y=y.value()),$l(h,function(D,Y){return Y.func.apply(Y.thisArg,fo([D],Y.args))},y)}function Li(r,h,y){var D=r.length;if(D<2)return D?ei(r[0]):[];for(var Y=-1,ut=Zt(D);++Y<D;)for(var yt=r[Y],bt=-1;++bt<D;)bt!=Y&&(ut[Y]=Tl(ut[Y]||yt,r[bt],h,y));return ei(bn(ut,1),h,y)}function Ai(r,h,y){for(var D=-1,Y=r.length,ut=h.length,yt={};++D<Y;){var bt=D<ut?h[D]:o;y(yt,r[D],bt)}return yt}function ne(r){return Dn(r)?r:[]}function ii(r){return typeof r=="function"?r:Gr}function Je(r,h){return vi(r)?r:nf(r,h)?[r]:op(Zi(r))}var li=ae;function xn(r,h,y){var D=r.length;return y=y===o?D:y,!h&&y>=D?r:Vi(r,h,y)}var Pn=eh||function(r){return gn.clearTimeout(r)};function No(r,h){if(h)return r.slice();var y=r.length,D=al?al(y):new r.constructor(y);return r.copy(D),D}function Ia(r){var h=new r.constructor(r.byteLength);return new tn(h).set(new tn(r)),h}function Kh(r,h){var y=h?Ia(r.buffer):r.buffer;return new r.constructor(y,r.byteOffset,r.byteLength)}function Da(r){var h=new r.constructor(r.source,jl.exec(r));return h.lastIndex=r.lastIndex,h}function Hs(r){return Fs?Ee(Fs.call(r)):{}}function El(r,h){var y=h?Ia(r.buffer):r.buffer;return new r.constructor(y,r.byteOffset,r.length)}function Vs(r,h){if(r!==h){var y=r!==o,D=r===null,Y=r===r,ut=to(r),yt=h!==o,bt=h===null,Bt=h===h,oe=to(h);if(!bt&&!oe&&!ut&&r>h||ut&&yt&&Bt&&!bt&&!oe||D&&yt&&Bt||!y&&Bt||!Y)return 1;if(!D&&!ut&&!oe&&r<h||oe&&y&&Y&&!D&&!ut||bt&&y&&Y||!yt&&Y||!Bt)return-1}return 0}function us(r,h,y){for(var D=-1,Y=r.criteria,ut=h.criteria,yt=Y.length,bt=y.length;++D<yt;){var Bt=Vs(Y[D],ut[D]);if(Bt){if(D>=bt)return Bt;var oe=y[D];return Bt*(oe=="desc"?-1:1)}}return r.index-h.index}function Qh(r,h,y,D){for(var Y=-1,ut=r.length,yt=y.length,bt=-1,Bt=h.length,oe=vn(ut-yt,0),le=Zt(Bt+oe),de=!D;++bt<Bt;)le[bt]=h[bt];for(;++Y<yt;)(de||Y<ut)&&(le[y[Y]]=r[Y]);for(;oe--;)le[bt++]=r[Y++];return le}function tu(r,h,y,D){for(var Y=-1,ut=r.length,yt=-1,bt=y.length,Bt=-1,oe=h.length,le=vn(ut-bt,0),de=Zt(le+oe),ke=!D;++Y<le;)de[Y]=r[Y];for(var Ze=Y;++Bt<oe;)de[Ze+Bt]=h[Bt];for(;++yt<bt;)(ke||Y<ut)&&(de[Ze+y[yt]]=r[Y++]);return de}function er(r,h){var y=-1,D=r.length;for(h||(h=Zt(D));++y<D;)h[y]=r[y];return h}function In(r,h,y,D){var Y=!y;y||(y={});for(var ut=-1,yt=h.length;++ut<yt;){var bt=h[ut],Bt=D?D(y[bt],r[bt],bt,y,r):o;Bt===o&&(Bt=r[bt]),Y?Bo(y,bt,Bt):Ra(y,bt,Bt)}return y}function So(r,h){return In(r,ef(r),h)}function Gu(r,h){return In(r,Zd(r),h)}function za(r,h){return function(y,D){var Y=vi(y)?Zl:Bu,ut=h?h():{};return Y(y,r,si(D,2),ut)}}function Fo(r){return ae(function(h,y){var D=-1,Y=y.length,ut=Y>1?y[Y-1]:o,yt=Y>2?y[2]:o;for(ut=r.length>3&&typeof ut=="function"?(Y--,ut):o,yt&&Mr(y[0],y[1],yt)&&(ut=Y<3?o:ut,Y=1),h=Ee(h);++D<Y;){var bt=y[D];bt&&r(h,bt,D,ut)}return h})}function ft(r,h){return function(y,D){if(y==null)return y;if(!Fr(y))return r(y,D);for(var Y=y.length,ut=h?Y:-1,yt=Ee(y);(h?ut--:++ut<Y)&&D(yt[ut],ut,yt)!==!1;);return y}}function Tt(r){return function(h,y,D){for(var Y=-1,ut=Ee(h),yt=D(h),bt=yt.length;bt--;){var Bt=yt[r?bt:++Y];if(y(ut[Bt],Bt,ut)===!1)break}return h}}function mt(r,h,y){var D=h&P,Y=Ve(r);function ut(){var yt=this&&this!==gn&&this instanceof ut?Y:r;return yt.apply(D?y:this,arguments)}return ut}function Me(r){return function(h){h=Zi(h);var y=Ir(h)?ar(h):o,D=y?y[0]:h.charAt(0),Y=y?xn(y,1).join(""):h.slice(1);return D[r]()+Y}}function ze(r){return function(h){return $l(Bp(kp(h).replace(ha,"")),r,"")}}function Ve(r){return function(){var h=arguments;switch(h.length){case 0:return new r;case 1:return new r(h[0]);case 2:return new r(h[0],h[1]);case 3:return new r(h[0],h[1],h[2]);case 4:return new r(h[0],h[1],h[2],h[3]);case 5:return new r(h[0],h[1],h[2],h[3],h[4]);case 6:return new r(h[0],h[1],h[2],h[3],h[4],h[5]);case 7:return new r(h[0],h[1],h[2],h[3],h[4],h[5],h[6])}var y=ss(r.prototype),D=r.apply(y,h);return wn(D)?D:y}}function Se(r,h,y){var D=Ve(r);function Y(){for(var ut=arguments.length,yt=Zt(ut),bt=ut,Bt=ph(Y);bt--;)yt[bt]=arguments[bt];var oe=ut<3&&yt[0]!==Bt&&yt[ut-1]!==Bt?[]:Dr(yt,Bt);if(ut-=oe.length,ut<y)return iu(r,h,$i,Y.placeholder,o,yt,oe,o,o,y-ut);var le=this&&this!==gn&&this instanceof Y?D:r;return yr(le,this,yt)}return Y}function Ke(r){return function(h,y,D){var Y=Ee(h);if(!Fr(h)){var ut=si(y,3);h=Jn(h),y=function(bt){return ut(Y[bt],bt,Y)}}var yt=r(h,y,D);return yt>-1?Y[ut?h[yt]:yt]:o}}function Oi(r){return Ws(function(h){var y=h.length,D=y,Y=qn.prototype.thru;for(r&&h.reverse();D--;){var ut=h[D];if(typeof ut!="function")throw new lr(m);if(Y&&!yt&&Vu(ut)=="wrapper")var yt=new qn([],!0)}for(D=yt?D:y;++D<y;){ut=h[D];var bt=Vu(ut),Bt=bt=="wrapper"?Qc(ut):o;Bt&&rf(Bt[0])&&Bt[1]==(X|R|U|K)&&!Bt[4].length&&Bt[9]==1?yt=yt[Vu(Bt[0])].apply(yt,Bt[3]):yt=ut.length==1&&rf(ut)?yt[bt]():yt.thru(ut)}return function(){var oe=arguments,le=oe[0];if(yt&&oe.length==1&&vi(le))return yt.plant(le).value();for(var de=0,ke=y?h[de].apply(this,oe):le;++de<y;)ke=h[de].call(this,ke);return ke}})}function $i(r,h,y,D,Y,ut,yt,bt,Bt,oe){var le=h&X,de=h&P,ke=h&w,Ze=h&(R|C),hi=h&Z,Mi=ke?o:Ve(r);function ui(){for(var Ri=arguments.length,Ui=Zt(Ri),eo=Ri;eo--;)Ui[eo]=arguments[eo];if(Ze)var Sr=ph(ui),io=go(Ui,Sr);if(D&&(Ui=Qh(Ui,D,Y,Ze)),ut&&(Ui=tu(Ui,ut,yt,Ze)),Ri-=io,Ze&&Ri<oe){var zn=Dr(Ui,Sr);return iu(r,h,$i,ui.placeholder,y,Ui,zn,bt,Bt,oe-Ri)}var Go=de?y:this,Ys=ke?Go[r]:r;return Ri=Ui.length,bt?Ui=l0(Ui,bt):hi&&Ri>1&&Ui.reverse(),le&&Bt<Ri&&(Ui.length=Bt),this&&this!==gn&&this instanceof ui&&(Ys=Mi||Ve(Ys)),Ys.apply(Go,Ui)}return ui}function ve(r,h){return function(y,D){return t(y,r,h(D),{})}}function Tr(r,h){return function(y,D){var Y;if(y===o&&D===o)return h;if(y!==o&&(Y=y),D!==o){if(Y===o)return D;typeof y=="string"||typeof D=="string"?(y=Ye(y),D=Ye(D)):(y=Ht(y),D=Ht(D)),Y=r(y,D)}return Y}}function Nn(r){return Ws(function(h){return h=Yi(h,Gn(si())),ae(function(y){var D=this;return r(h,function(Y){return yr(Y,D,y)})})})}function an(r,h){h=h===o?" ":Ye(h);var y=h.length;if(y<2)return y?be(h,r):h;var D=be(h,Do(r/$r(h)));return Ir(h)?xn(ar(D),0,r).join(""):D.slice(0,r)}function pr(r,h,y,D){var Y=h&P,ut=Ve(r);function yt(){for(var bt=-1,Bt=arguments.length,oe=-1,le=D.length,de=Zt(le+Bt),ke=this&&this!==gn&&this instanceof yt?ut:r;++oe<le;)de[oe]=D[oe];for(;Bt--;)de[oe++]=arguments[++bt];return yr(ke,Y?y:this,de)}return yt}function eu(r){return function(h,y,D){return D&&typeof D!="number"&&Mr(h,y,D)&&(y=D=o),h=qs(h),y===o?(y=h,h=0):y=qs(y),D=D===o?h<y?1:-1:qs(D),De(h,y,D,r)}}function Eo(r){return function(h,y){return typeof h=="string"&&typeof y=="string"||(h=Co(h),y=Co(y)),r(h,y)}}function iu(r,h,y,D,Y,ut,yt,bt,Bt,oe){var le=h&R,de=le?yt:o,ke=le?o:yt,Ze=le?ut:o,hi=le?o:ut;h|=le?U:F,h&=~(le?F:U),h&M||(h&=~(P|w));var Mi=[r,h,Y,Ze,de,hi,ke,bt,Bt,oe],ui=y.apply(o,Mi);return rf(r)&&ip(ui,Mi),ui.placeholder=D,np(ui,r,h)}function dh(r){var h=fn[r];return function(y,D){if(y=Co(y),D=D==null?0:Vn(wi(D),292),D&&nh(y)){var Y=(Zi(y)+"e").split("e"),ut=h(Y[0]+"e"+(+Y[1]+D));return Y=(Zi(ut)+"e").split("e"),+(Y[0]+"e"+(+Y[1]-D))}return h(y)}}var ka=Ns&&1/Is(new Ns([,-0]))[1]==At?function(r){return new Ns(r)}:_f;function Hu(r){return function(h){var y=mr(h);return y==W?$n(h):y==Kt?Hn(h):Oo(h,r(h))}}function ir(r,h,y,D,Y,ut,yt,bt){var Bt=h&w;if(!Bt&&typeof r!="function")throw new lr(m);var oe=D?D.length:0;if(oe||(h&=~(U|F),D=Y=o),yt=yt===o?yt:vn(wi(yt),0),bt=bt===o?bt:wi(bt),oe-=Y?Y.length:0,h&F){var le=D,de=Y;D=Y=o}var ke=Bt?o:Qc(r),Ze=[r,h,y,D,Y,le,de,ut,yt,bt];if(ke&&o0(Ze,ke),r=Ze[0],h=Ze[1],y=Ze[2],D=Ze[3],Y=Ze[4],bt=Ze[9]=Ze[9]===o?Bt?0:r.length:vn(Ze[9]-oe,0),!bt&&h&(R|C)&&(h&=~(R|C)),!h||h==P)var hi=mt(r,h,y);else h==R||h==C?hi=Se(r,h,bt):(h==U||h==(P|U))&&!Y.length?hi=pr(r,h,y,D):hi=$i.apply(o,Ze);var Mi=ke?Cn:ip;return np(Mi(hi,Ze),r,h)}function Xd(r,h,y,D){return r===o||Uo(r,vo[y])&&!Ti.call(D,y)?h:r}function qd(r,h,y,D,Y,ut){return wn(r)&&wn(h)&&(ut.set(h,r),wt(r,h,o,qd,ut),ut.delete(h)),r}function jg(r){return ou(r)?o:r}function Yd(r,h,y,D,Y,ut){var yt=y&N,bt=r.length,Bt=h.length;if(bt!=Bt&&!(yt&&Bt>bt))return!1;var oe=ut.get(r),le=ut.get(h);if(oe&&le)return oe==h&&le==r;var de=-1,ke=!0,Ze=y&E?new Us:o;for(ut.set(r,h),ut.set(h,r);++de<bt;){var hi=r[de],Mi=h[de];if(D)var ui=yt?D(Mi,hi,de,h,r,ut):D(hi,Mi,de,r,h,ut);if(ui!==o){if(ui)continue;ke=!1;break}if(Ze){if(!Po(h,function(Ri,Ui){if(!mo(Ze,Ui)&&(hi===Ri||Y(hi,Ri,y,D,ut)))return Ze.push(Ui)})){ke=!1;break}}else if(!(hi===Mi||Y(hi,Mi,y,D,ut))){ke=!1;break}}return ut.delete(r),ut.delete(h),ke}function Xg(r,h,y,D,Y,ut,yt){switch(y){case qt:if(r.byteLength!=h.byteLength||r.byteOffset!=h.byteOffset)return!1;r=r.buffer,h=h.buffer;case Ut:return!(r.byteLength!=h.byteLength||!ut(new tn(r),new tn(h)));case Oe:case Ge:case Jt:return Uo(+r,+h);case Di:return r.name==h.name&&r.message==h.message;case ie:case z:return r==h+"";case W:var bt=$n;case Kt:var Bt=D&N;if(bt||(bt=Is),r.size!=h.size&&!Bt)return!1;var oe=yt.get(r);if(oe)return oe==h;D|=E,yt.set(r,h);var le=Yd(bt(r),bt(h),D,Y,ut,yt);return yt.delete(r),le;case Q:if(Fs)return Fs.call(r)==Fs.call(h)}return!1}function qg(r,h,y,D,Y,ut){var yt=y&N,bt=$c(r),Bt=bt.length,oe=$c(h),le=oe.length;if(Bt!=le&&!yt)return!1;for(var de=Bt;de--;){var ke=bt[de];if(!(yt?ke in h:Ti.call(h,ke)))return!1}var Ze=ut.get(r),hi=ut.get(h);if(Ze&&hi)return Ze==h&&hi==r;var Mi=!0;ut.set(r,h),ut.set(h,r);for(var ui=yt;++de<Bt;){ke=bt[de];var Ri=r[ke],Ui=h[ke];if(D)var eo=yt?D(Ui,Ri,ke,h,r,ut):D(Ri,Ui,ke,r,h,ut);if(!(eo===o?Ri===Ui||Y(Ri,Ui,y,D,ut):eo)){Mi=!1;break}ui||(ui=ke=="constructor")}if(Mi&&!ui){var Sr=r.constructor,io=h.constructor;Sr!=io&&"constructor"in r&&"constructor"in h&&!(typeof Sr=="function"&&Sr instanceof Sr&&typeof io=="function"&&io instanceof io)&&(Mi=!1)}return ut.delete(r),ut.delete(h),Mi}function Ws(r){return sf(tp(r,o,hp),r+"")}function $c(r){return Uu(r,Jn,ef)}function Kc(r){return Uu(r,Ur,Zd)}var Qc=pl?function(r){return pl.get(r)}:_f;function Vu(r){for(var h=r.name+"",y=os[h],D=Ti.call(os,h)?y.length:0;D--;){var Y=y[D],ut=Y.func;if(ut==null||ut==r)return Y.name}return h}function ph(r){var h=Ti.call(it,"placeholder")?it:r;return h.placeholder}function si(){var r=it.iteratee||vf;return r=r===vf?H:r,arguments.length?r(arguments[0],arguments[1]):r}function Wu(r,h){var y=r.__data__;return e0(h)?y[typeof h=="string"?"string":"hash"]:y.map}function tf(r){for(var h=Jn(r),y=h.length;y--;){var D=h[y],Y=r[D];h[y]=[D,Y,Kd(Y)]}return h}function bl(r,h){var y=Ls(r,h);return T(y)?y:o}function Yg(r){var h=Ti.call(r,xo),y=r[xo];try{r[xo]=o;var D=!0}catch{}var Y=cr.call(r);return D&&(h?r[xo]=y:delete r[xo]),Y}var ef=ul?function(r){return r==null?[]:(r=Ee(r),Rr(ul(r),function(h){return hl.call(r,h)}))}:xf,Zd=ul?function(r){for(var h=[];r;)fo(h,ef(r)),r=_o(r);return h}:xf,mr=Zn;(fl&&mr(new fl(new ArrayBuffer(1)))!=qt||Bs&&mr(new Bs)!=W||dl&&mr(dl.resolve())!=pt||Ns&&mr(new Ns)!=Kt||En&&mr(new En)!=nt)&&(mr=function(r){var h=Zn(r),y=h==dt?r.constructor:o,D=y?Cl(y):"";if(D)switch(D){case oh:return qt;case Hh:return W;case Vh:return pt;case Wh:return Kt;case Ru:return nt}return h});function Zg(r,h,y){for(var D=-1,Y=y.length;++D<Y;){var ut=y[D],yt=ut.size;switch(ut.type){case"drop":r+=yt;break;case"dropRight":h-=yt;break;case"take":h=Vn(h,r+yt);break;case"takeRight":r=vn(r,h-yt);break}}return{start:r,end:h}}function Jg(r){var h=r.match(Ja);return h?h[1].split(ho):[]}function Jd(r,h,y){h=Je(h,r);for(var D=-1,Y=h.length,ut=!1;++D<Y;){var yt=cs(h[D]);if(!(ut=r!=null&&y(r,yt)))break;r=r[yt]}return ut||++D!=Y?ut:(Y=r==null?0:r.length,!!Y&&$u(Y)&&js(yt,Y)&&(vi(r)||Al(r)))}function $g(r){var h=r.length,y=new r.constructor(h);return h&&typeof r[0]=="string"&&Ti.call(r,"index")&&(y.index=r.index,y.input=r.input),y}function $d(r){return typeof r.constructor=="function"&&!nu(r)?ss(_o(r)):{}}function Kg(r,h,y){var D=r.constructor;switch(h){case Ut:return Ia(r);case Oe:case Ge:return new D(+r);case qt:return Kh(r,y);case Xt:case Ne:case Ie:case me:case we:case yi:case Ei:case ni:case bi:return El(r,y);case W:return new D;case Jt:case z:return new D(r);case ie:return Da(r);case Kt:return new D;case Q:return Hs(r)}}function Qg(r,h){var y=h.length;if(!y)return r;var D=y-1;return h[D]=(y>1?"& ":"")+h[D],h=h.join(y>2?", ":" "),r.replace(sa,`{
|
|
2617
|
+
*/lu.exports,function(x,a){(function(){var o,c="4.17.21",f=200,u="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",m="Expected a function",g="Invalid `variable` option passed into `_.template`",v="__lodash_hash_undefined__",S=500,b="__lodash_placeholder__",O=1,k=2,I=4,F=1,E=2,P=1,w=2,M=4,R=8,C=16,U=32,N=64,X=128,J=256,Z=512,ct=30,Rt="...",tt=800,_t=16,G=1,Pt=2,Et=3,At=1/0,ce=9007199254740991,re=17976931348623157e292,Ft=0/0,It=4294967295,Nt=It-1,Pe=It>>>1,pe=[["ary",X],["bind",P],["bindKey",w],["curry",R],["curryRight",C],["flip",Z],["partial",U],["partialRight",N],["rearg",J]],Wt="[object Arguments]",$e="[object Array]",Si="[object AsyncFunction]",Oe="[object Boolean]",Ge="[object Date]",pi="[object DOMException]",Di="[object Error]",mn="[object Function]",Qi="[object GeneratorFunction]",W="[object Map]",Jt="[object Number]",jt="[object Null]",dt="[object Object]",pt="[object Promise]",Dt="[object Proxy]",ie="[object RegExp]",Kt="[object Set]",z="[object String]",Q="[object Symbol]",st="[object Undefined]",nt="[object WeakMap]",vt="[object WeakSet]",Ut="[object ArrayBuffer]",qt="[object DataView]",Xt="[object Float32Array]",Ne="[object Float64Array]",Ie="[object Int8Array]",me="[object Int16Array]",we="[object Int32Array]",yi="[object Uint8Array]",Ei="[object Uint8ClampedArray]",ni="[object Uint16Array]",bi="[object Uint32Array]",qr=/\b__p \+= '';/g,sr=/\b(__p \+=) '' \+/g,sn=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Ao=/&(?:amp|lt|gt|quot|#39);/g,zi=/[&<>"']/g,Yo=RegExp(Ao.source),ao=RegExp(zi.source),Hl=/<%-([\s\S]+?)%>/g,Mn=/<%([\s\S]+?)%>/g,ra=/<%=([\s\S]+?)%>/g,vs=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,vr=/^\w*$/,oa=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Za=/[\\^$.*+?()[\]{}|]/g,Vl=RegExp(Za.source),lo=/^\s+/,Oh=/\s/,sa=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Ja=/\{\n\/\* \[wrapped with (.+)\] \*/,ho=/,? & /,Wl=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,aa=/[()=,{}\[\]\/\s]/,la=/\\(\\)?/g,uo=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,jl=/\w*$/,Ih=/^[-+]0x[0-9a-f]+$/i,Dh=/^0b[01]+$/i,ys=/^\[object .+?Constructor\]$/,_s=/^0o[0-7]+$/i,Xl=/^(?:0|[1-9]\d*)$/,ql=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Yr=/($^)/,V=/['\n\r\u2028\u2029\\]/g,et="\\ud800-\\udfff",lt="\\u0300-\\u036f",at="\\ufe20-\\ufe2f",j="\\u20d0-\\u20ff",St=lt+at+j,ht="\\u2700-\\u27bf",Ot="a-z\\xdf-\\xf6\\xf8-\\xff",Gt="\\xac\\xb1\\xd7\\xf7",zt="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Mt="\\u2000-\\u206f",he=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",se="A-Z\\xc0-\\xd6\\xd8-\\xde",te="\\ufe0e\\ufe0f",ye=Gt+zt+Mt+he,ue="['’]",je="["+et+"]",He="["+ye+"]",ci="["+St+"]",Be="\\d+",_e="["+ht+"]",Fe="["+Ot+"]",fe="[^"+et+ye+Be+ht+Ot+se+"]",mi="\\ud83c[\\udffb-\\udfff]",Le="(?:"+ci+"|"+mi+")",xe="[^"+et+"]",Re="(?:\\ud83c[\\udde6-\\uddff]){2}",Sn="[\\ud800-\\udbff][\\udc00-\\udfff]",Xn="["+se+"]",ki="\\u200d",Bi="(?:"+Fe+"|"+fe+")",Hi="(?:"+Xn+"|"+fe+")",nn="(?:"+ue+"(?:d|ll|m|re|s|t|ve))?",rn="(?:"+ue+"(?:D|LL|M|RE|S|T|VE))?",un=Le+"?",cn="["+te+"]?",Gi="(?:"+ki+"(?:"+[xe,Re,Sn].join("|")+")"+cn+un+")*",Ni="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ji="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",gi=cn+un+Gi,co="(?:"+[_e,Re,Sn].join("|")+")"+gi,Fn="(?:"+[xe+ci+"?",ci,Re,Sn,je].join("|")+")",ha=RegExp(ue,"g"),zh=RegExp(ci,"g"),Zo=RegExp(mi+"(?="+mi+")|"+Fn+gi,"g"),$a=RegExp([Xn+"?"+Fe+"+"+nn+"(?="+[He,Xn,"$"].join("|")+")",Hi+"+"+rn+"(?="+[He,Xn+Bi,"$"].join("|")+")",Xn+"?"+Bi+"+"+nn,Xn+"+"+rn,ji,Ni,Be,co].join("|"),"g"),Ka=RegExp("["+ki+et+St+te+"]"),ua=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Qa=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ca=-1,Xi={};Xi[Xt]=Xi[Ne]=Xi[Ie]=Xi[me]=Xi[we]=Xi[yi]=Xi[Ei]=Xi[ni]=Xi[bi]=!0,Xi[Wt]=Xi[$e]=Xi[Ut]=Xi[Oe]=Xi[qt]=Xi[Ge]=Xi[Di]=Xi[mn]=Xi[W]=Xi[Jt]=Xi[dt]=Xi[ie]=Xi[Kt]=Xi[z]=Xi[nt]=!1;var xi={};xi[Wt]=xi[$e]=xi[Ut]=xi[qt]=xi[Oe]=xi[Ge]=xi[Xt]=xi[Ne]=xi[Ie]=xi[me]=xi[we]=xi[W]=xi[Jt]=xi[dt]=xi[ie]=xi[Kt]=xi[z]=xi[Q]=xi[yi]=xi[Ei]=xi[ni]=xi[bi]=!0,xi[Di]=xi[mn]=xi[nt]=!1;var tl={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},fa={"&":"&","<":"<",">":">",'"':""","'":"'"},el={"&":"&","<":"<",">":">",""":'"',"'":"'"},xs={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},il=parseFloat,da=parseInt,pa=typeof Er=="object"&&Er&&Er.Object===Object&&Er,ma=typeof self=="object"&&self&&self.Object===Object&&self,gn=pa||ma||Function("return this")(),Jo=a&&!a.nodeType&&a,Zr=Jo&&!0&&x&&!x.nodeType&&x,ws=Zr&&Zr.exports===Jo,Ts=ws&&pa.process,Un=function(){try{var Lt=Zr&&Zr.require&&Zr.require("util").types;return Lt||Ts&&Ts.binding&&Ts.binding("util")}catch{}}(),kh=Un&&Un.isArrayBuffer,ga=Un&&Un.isDate,va=Un&&Un.isMap,Su=Un&&Un.isRegExp,Eu=Un&&Un.isSet,Yl=Un&&Un.isTypedArray;function yr(Lt,Qt,Zt){switch(Zt.length){case 0:return Lt.call(Qt);case 1:return Lt.call(Qt,Zt[0]);case 2:return Lt.call(Qt,Zt[0],Zt[1]);case 3:return Lt.call(Qt,Zt[0],Zt[1],Zt[2])}return Lt.apply(Qt,Zt)}function Zl(Lt,Qt,Zt,Ue){for(var ai=-1,Fi=Lt==null?0:Lt.length;++ai<Fi;){var fn=Lt[ai];Qt(Ue,fn,Zt(fn),Lt)}return Ue}function Ji(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length;++Zt<Ue&&Qt(Lt[Zt],Zt,Lt)!==!1;);return Lt}function Ms(Lt,Qt){for(var Zt=Lt==null?0:Lt.length;Zt--&&Qt(Lt[Zt],Zt,Lt)!==!1;);return Lt}function Bh(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length;++Zt<Ue;)if(!Qt(Lt[Zt],Zt,Lt))return!1;return!0}function Rr(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length,ai=0,Fi=[];++Zt<Ue;){var fn=Lt[Zt];Qt(fn,Zt,Lt)&&(Fi[ai++]=fn)}return Fi}function nl(Lt,Qt){var Zt=Lt==null?0:Lt.length;return!!Zt&&Or(Lt,Qt,0)>-1}function Jl(Lt,Qt,Zt){for(var Ue=-1,ai=Lt==null?0:Lt.length;++Ue<ai;)if(Zt(Qt,Lt[Ue]))return!0;return!1}function Yi(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length,ai=Array(Ue);++Zt<Ue;)ai[Zt]=Qt(Lt[Zt],Zt,Lt);return ai}function fo(Lt,Qt){for(var Zt=-1,Ue=Qt.length,ai=Lt.length;++Zt<Ue;)Lt[ai+Zt]=Qt[Zt];return Lt}function $l(Lt,Qt,Zt,Ue){var ai=-1,Fi=Lt==null?0:Lt.length;for(Ue&&Fi&&(Zt=Lt[++ai]);++ai<Fi;)Zt=Qt(Zt,Lt[ai],ai,Lt);return Zt}function bu(Lt,Qt,Zt,Ue){var ai=Lt==null?0:Lt.length;for(Ue&&ai&&(Zt=Lt[--ai]);ai--;)Zt=Qt(Zt,Lt[ai],ai,Lt);return Zt}function Po(Lt,Qt){for(var Zt=-1,Ue=Lt==null?0:Lt.length;++Zt<Ue;)if(Qt(Lt[Zt],Zt,Lt))return!0;return!1}var po=Ko("length");function Cu(Lt){return Lt.split("")}function rl(Lt){return Lt.match(Wl)||[]}function Ss(Lt,Qt,Zt){var Ue;return Zt(Lt,function(ai,Fi,fn){if(Qt(ai,Fi,fn))return Ue=Fi,!1}),Ue}function $o(Lt,Qt,Zt,Ue){for(var ai=Lt.length,Fi=Zt+(Ue?1:-1);Ue?Fi--:++Fi<ai;)if(Qt(Lt[Fi],Fi,Lt))return Fi;return-1}function Or(Lt,Qt,Zt){return Qt===Qt?Kl(Lt,Qt,Zt):$o(Lt,Es,Zt)}function ol(Lt,Qt,Zt,Ue){for(var ai=Zt-1,Fi=Lt.length;++ai<Fi;)if(Ue(Lt[ai],Qt))return ai;return-1}function Es(Lt){return Lt!==Lt}function ya(Lt,Qt){var Zt=Lt==null?0:Lt.length;return Zt?ts(Lt,Qt)/Zt:Ft}function Ko(Lt){return function(Qt){return Qt==null?o:Qt[Lt]}}function Lo(Lt){return function(Qt){return Lt==null?o:Lt[Qt]}}function Qo(Lt,Qt,Zt,Ue,ai){return ai(Lt,function(Fi,fn,Ee){Zt=Ue?(Ue=!1,Fi):Qt(Zt,Fi,fn,Ee)}),Zt}function Au(Lt,Qt){var Zt=Lt.length;for(Lt.sort(Qt);Zt--;)Lt[Zt]=Lt[Zt].value;return Lt}function ts(Lt,Qt){for(var Zt,Ue=-1,ai=Lt.length;++Ue<ai;){var Fi=Qt(Lt[Ue]);Fi!==o&&(Zt=Zt===o?Fi:Zt+Fi)}return Zt}function Ro(Lt,Qt){for(var Zt=-1,Ue=Array(Lt);++Zt<Lt;)Ue[Zt]=Qt(Zt);return Ue}function Oo(Lt,Qt){return Yi(Qt,function(Zt){return[Zt,Lt[Zt]]})}function _a(Lt){return Lt&&Lt.slice(0,xa(Lt)+1).replace(lo,"")}function Gn(Lt){return function(Qt){return Lt(Qt)}}function bs(Lt,Qt){return Yi(Qt,function(Zt){return Lt[Zt]})}function mo(Lt,Qt){return Lt.has(Qt)}function es(Lt,Qt){for(var Zt=-1,Ue=Lt.length;++Zt<Ue&&Or(Qt,Lt[Zt],0)>-1;);return Zt}function Cs(Lt,Qt){for(var Zt=Lt.length;Zt--&&Or(Qt,Lt[Zt],0)>-1;);return Zt}function go(Lt,Qt){for(var Zt=Lt.length,Ue=0;Zt--;)Lt[Zt]===Qt&&++Ue;return Ue}var As=Lo(tl),Jr=Lo(fa);function Ps(Lt){return"\\"+xs[Lt]}function Ls(Lt,Qt){return Lt==null?o:Lt[Qt]}function Ir(Lt){return Ka.test(Lt)}function Rs(Lt){return ua.test(Lt)}function Os(Lt){for(var Qt,Zt=[];!(Qt=Lt.next()).done;)Zt.push(Qt.value);return Zt}function $n(Lt){var Qt=-1,Zt=Array(Lt.size);return Lt.forEach(function(Ue,ai){Zt[++Qt]=[ai,Ue]}),Zt}function sl(Lt,Qt){return function(Zt){return Lt(Qt(Zt))}}function Dr(Lt,Qt){for(var Zt=-1,Ue=Lt.length,ai=0,Fi=[];++Zt<Ue;){var fn=Lt[Zt];(fn===Qt||fn===b)&&(Lt[Zt]=b,Fi[ai++]=Zt)}return Fi}function Is(Lt){var Qt=-1,Zt=Array(Lt.size);return Lt.forEach(function(Ue){Zt[++Qt]=Ue}),Zt}function Hn(Lt){var Qt=-1,Zt=Array(Lt.size);return Lt.forEach(function(Ue){Zt[++Qt]=[Ue,Ue]}),Zt}function Kl(Lt,Qt,Zt){for(var Ue=Zt-1,ai=Lt.length;++Ue<ai;)if(Lt[Ue]===Qt)return Ue;return-1}function Ql(Lt,Qt,Zt){for(var Ue=Zt+1;Ue--;)if(Lt[Ue]===Qt)return Ue;return Ue}function $r(Lt){return Ir(Lt)?wa(Lt):po(Lt)}function ar(Lt){return Ir(Lt)?_r(Lt):Cu(Lt)}function xa(Lt){for(var Qt=Lt.length;Qt--&&Oh.test(Lt.charAt(Qt)););return Qt}var th=Lo(el);function wa(Lt){for(var Qt=Zo.lastIndex=0;Zo.test(Lt);)++Qt;return Qt}function _r(Lt){return Lt.match(Zo)||[]}function jc(Lt){return Lt.match($a)||[]}var Xc=function Lt(Qt){Qt=Qt==null?gn:is.defaults(gn.Object(),Qt,is.pick(gn,Qa));var Zt=Qt.Array,Ue=Qt.Date,ai=Qt.Error,Fi=Qt.Function,fn=Qt.Math,Ee=Qt.Object,Kn=Qt.RegExp,Ta=Qt.String,lr=Qt.TypeError,On=Zt.prototype,Pu=Fi.prototype,vo=Ee.prototype,ns=Qt["__core-js_shared__"],hr=Pu.toString,Ti=vo.hasOwnProperty,ur=0,zr=function(){var r=/[^.]+$/.exec(ns&&ns.keys&&ns.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""}(),cr=vo.toString,yo=hr.call(Ee),Kr=gn._,Io=Kn("^"+hr.call(Ti).replace(Za,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),fr=ws?Qt.Buffer:o,Qn=Qt.Symbol,tn=Qt.Uint8Array,al=fr?fr.allocUnsafe:o,_o=sl(Ee.getPrototypeOf,Ee),ll=Ee.create,hl=vo.propertyIsEnumerable,Ds=On.splice,Ma=Qn?Qn.isConcatSpreadable:o,rs=Qn?Qn.iterator:o,xo=Qn?Qn.toStringTag:o,zs=function(){try{var r=bl(Ee,"defineProperty");return r({},"",{}),r}catch{}}(),eh=Qt.clearTimeout!==gn.clearTimeout&&Qt.clearTimeout,ih=Ue&&Ue.now!==gn.Date.now&&Ue.now,Nh=Qt.setTimeout!==gn.setTimeout&&Qt.setTimeout,Do=fn.ceil,ks=fn.floor,ul=Ee.getOwnPropertySymbols,Fh=fr?fr.isBuffer:o,nh=Qt.isFinite,Uh=On.join,Lu=sl(Ee.keys,Ee),vn=fn.max,Vn=fn.min,cl=Ue.now,Gh=Qt.parseInt,rh=fn.random,Sa=On.reverse,fl=bl(Qt,"DataView"),Bs=bl(Qt,"Map"),dl=bl(Qt,"Promise"),Ns=bl(Qt,"Set"),En=bl(Qt,"WeakMap"),Ea=bl(Ee,"create"),pl=En&&new En,os={},oh=Cl(fl),Hh=Cl(Bs),Vh=Cl(dl),Wh=Cl(Ns),Ru=Cl(En),ml=Qn?Qn.prototype:o,Fs=ml?ml.valueOf:o,jh=ml?ml.toString:o;function it(r){if(Ln(r)&&!vi(r)&&!(r instanceof _i)){if(r instanceof qn)return r;if(Ti.call(r,"__wrapped__"))return sp(r)}return new qn(r)}var ss=function(){function r(){}return function(h){if(!wn(h))return{};if(ll)return ll(h);r.prototype=h;var y=new r;return r.prototype=o,y}}();function ba(){}function qn(r,h){this.__wrapped__=r,this.__actions__=[],this.__chain__=!!h,this.__index__=0,this.__values__=o}it.templateSettings={escape:Hl,evaluate:Mn,interpolate:ra,variable:"",imports:{_:it}},it.prototype=ba.prototype,it.prototype.constructor=it,qn.prototype=ss(ba.prototype),qn.prototype.constructor=qn;function _i(r){this.__wrapped__=r,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=It,this.__views__=[]}function Ca(){var r=new _i(this.__wrapped__);return r.__actions__=er(this.__actions__),r.__dir__=this.__dir__,r.__filtered__=this.__filtered__,r.__iteratees__=er(this.__iteratees__),r.__takeCount__=this.__takeCount__,r.__views__=er(this.__views__),r}function Ou(){if(this.__filtered__){var r=new _i(this);r.__dir__=-1,r.__filtered__=!0}else r=this.clone(),r.__dir__*=-1;return r}function Aa(){var r=this.__wrapped__.value(),h=this.__dir__,y=vi(r),D=h<0,Y=y?r.length:0,ut=Zg(0,Y,this.__views__),yt=ut.start,bt=ut.end,Bt=bt-yt,oe=D?bt:yt-1,le=this.__iteratees__,de=le.length,ke=0,Ze=Vn(Bt,this.__takeCount__);if(!y||!D&&Y==Bt&&Ze==Bt)return ri(r,this.__actions__);var hi=[];t:for(;Bt--&&ke<Ze;){oe+=h;for(var Mi=-1,ui=r[oe];++Mi<de;){var Ri=le[Mi],Ui=Ri.iteratee,eo=Ri.type,Sr=Ui(ui);if(eo==Pt)ui=Sr;else if(!Sr){if(eo==G)continue t;break t}}hi[ke++]=ui}return hi}_i.prototype=ss(ba.prototype),_i.prototype.constructor=_i;function kr(r){var h=-1,y=r==null?0:r.length;for(this.clear();++h<y;){var D=r[h];this.set(D[0],D[1])}}function Pa(){this.__data__=Ea?Ea(null):{},this.size=0}function La(r){var h=this.has(r)&&delete this.__data__[r];return this.size-=h?1:0,h}function gl(r){var h=this.__data__;if(Ea){var y=h[r];return y===v?o:y}return Ti.call(h,r)?h[r]:o}function sh(r){var h=this.__data__;return Ea?h[r]!==o:Ti.call(h,r)}function vl(r,h){var y=this.__data__;return this.size+=this.has(r)?0:1,y[r]=Ea&&h===o?v:h,this}kr.prototype.clear=Pa,kr.prototype.delete=La,kr.prototype.get=gl,kr.prototype.has=sh,kr.prototype.set=vl;function dr(r){var h=-1,y=r==null?0:r.length;for(this.clear();++h<y;){var D=r[h];this.set(D[0],D[1])}}function yl(){this.__data__=[],this.size=0}function zo(r){var h=this.__data__,y=wl(h,r);if(y<0)return!1;var D=h.length-1;return y==D?h.pop():Ds.call(h,y,1),--this.size,!0}function _l(r){var h=this.__data__,y=wl(h,r);return y<0?o:h[y][1]}function xl(r){return wl(this.__data__,r)>-1}function ko(r,h){var y=this.__data__,D=wl(y,r);return D<0?(++this.size,y.push([r,h])):y[D][1]=h,this}dr.prototype.clear=yl,dr.prototype.delete=zo,dr.prototype.get=_l,dr.prototype.has=xl,dr.prototype.set=ko;function xr(r){var h=-1,y=r==null?0:r.length;for(this.clear();++h<y;){var D=r[h];this.set(D[0],D[1])}}function Iu(){this.size=0,this.__data__={hash:new kr,map:new(Bs||dr),string:new kr}}function Du(r){var h=Wu(this,r).delete(r);return this.size-=h?1:0,h}function Xh(r){return Wu(this,r).get(r)}function di(r){return Wu(this,r).has(r)}function as(r,h){var y=Wu(this,r),D=y.size;return y.set(r,h),this.size+=y.size==D?0:1,this}xr.prototype.clear=Iu,xr.prototype.delete=Du,xr.prototype.get=Xh,xr.prototype.has=di,xr.prototype.set=as;function Us(r){var h=-1,y=r==null?0:r.length;for(this.__data__=new xr;++h<y;)this.add(r[h])}function Ci(r){return this.__data__.set(r,v),this}function Bn(r){return this.__data__.has(r)}Us.prototype.add=Us.prototype.push=Ci,Us.prototype.has=Bn;function Qr(r){var h=this.__data__=new dr(r);this.size=h.size}function qe(){this.__data__=new dr,this.size=0}function wo(r){var h=this.__data__,y=h.delete(r);return this.size=h.size,y}function qc(r){return this.__data__.get(r)}function Yc(r){return this.__data__.has(r)}function Zc(r,h){var y=this.__data__;if(y instanceof dr){var D=y.__data__;if(!Bs||D.length<f-1)return D.push([r,h]),this.size=++y.size,this;y=this.__data__=new xr(D)}return y.set(r,h),this.size=y.size,this}Qr.prototype.clear=qe,Qr.prototype.delete=wo,Qr.prototype.get=qc,Qr.prototype.has=Yc,Qr.prototype.set=Zc;function zu(r,h){var y=vi(r),D=!y&&Al(r),Y=!y&&!D&&Ba(r),ut=!y&&!D&&!Y&&mh(r),yt=y||D||Y||ut,bt=yt?Ro(r.length,Ta):[],Bt=bt.length;for(var oe in r)(h||Ti.call(r,oe))&&!(yt&&(oe=="length"||Y&&(oe=="offset"||oe=="parent")||ut&&(oe=="buffer"||oe=="byteLength"||oe=="byteOffset")||js(oe,Bt)))&&bt.push(oe);return bt}function qh(r){var h=r.length;return h?r[ge(0,h-1)]:o}function Jc(r,h){return ju(er(r),ls(h,0,r.length))}function ku(r){return ju(er(r))}function ah(r,h,y){(y!==o&&!Uo(r[h],y)||y===o&&!(h in r))&&Bo(r,h,y)}function Ra(r,h,y){var D=r[h];(!(Ti.call(r,h)&&Uo(D,y))||y===o&&!(h in r))&&Bo(r,h,y)}function wl(r,h){for(var y=r.length;y--;)if(Uo(r[y][0],h))return y;return-1}function Bu(r,h,y,D){return yn(r,function(Y,ut,yt){h(D,Y,y(Y),yt)}),D}function Yh(r,h){return r&&In(h,Jn(h),r)}function Zh(r,h){return r&&In(h,Ur(h),r)}function Bo(r,h,y){h=="__proto__"&&zs?zs(r,h,{configurable:!0,enumerable:!0,value:y,writable:!0}):r[h]=y}function Jh(r,h){for(var y=-1,D=h.length,Y=Zt(D),ut=r==null;++y<D;)Y[y]=ut?o:df(r,h[y]);return Y}function ls(r,h,y){return r===r&&(y!==o&&(r=r<=y?r:y),h!==o&&(r=r>=h?r:h)),r}function wr(r,h,y,D,Y,ut){var yt,bt=h&O,Bt=h&k,oe=h&I;if(y&&(yt=Y?y(r,D,Y,ut):y(r)),yt!==o)return yt;if(!wn(r))return r;var le=vi(r);if(le){if(yt=$g(r),!bt)return er(r,yt)}else{var de=mr(r),ke=de==mn||de==Qi;if(Ba(r))return No(r,bt);if(de==dt||de==Wt||ke&&!Y){if(yt=Bt||ke?{}:$d(r),!bt)return Bt?Gu(r,Zh(yt,r)):So(r,Yh(yt,r))}else{if(!xi[de])return Y?r:{};yt=Kg(r,de,bt)}}ut||(ut=new Qr);var Ze=ut.get(r);if(Ze)return Ze;ut.set(r,yt),bp(r)?r.forEach(function(ui){yt.add(wr(ui,h,y,ui,r,ut))}):Sp(r)&&r.forEach(function(ui,Ri){yt.set(Ri,wr(ui,h,y,Ri,r,ut))});var hi=oe?Bt?Kc:$c:Bt?Ur:Jn,Mi=le?o:hi(r);return Ji(Mi||r,function(ui,Ri){Mi&&(Ri=ui,ui=r[Ri]),Ra(yt,Ri,wr(ui,h,y,Ri,r,ut))}),yt}function Oa(r){var h=Jn(r);return function(y){return Nu(y,r,h)}}function Nu(r,h,y){var D=y.length;if(r==null)return!D;for(r=Ee(r);D--;){var Y=y[D],ut=h[Y],yt=r[Y];if(yt===o&&!(Y in r)||!ut(yt))return!1}return!0}function To(r,h,y){if(typeof r!="function")throw new lr(m);return ru(function(){r.apply(o,y)},h)}function Tl(r,h,y,D){var Y=-1,ut=nl,yt=!0,bt=r.length,Bt=[],oe=h.length;if(!bt)return Bt;y&&(h=Yi(h,Gn(y))),D?(ut=Jl,yt=!1):h.length>=f&&(ut=mo,yt=!1,h=new Us(h));t:for(;++Y<bt;){var le=r[Y],de=y==null?le:y(le);if(le=D||le!==0?le:0,yt&&de===de){for(var ke=oe;ke--;)if(h[ke]===de)continue t;Bt.push(le)}else ut(h,de,D)||Bt.push(le)}return Bt}var yn=ft(Nr),Fu=ft(hh,!0);function Yn(r,h){var y=!0;return yn(r,function(D,Y,ut){return y=!!h(D,Y,ut),y}),y}function Mo(r,h,y){for(var D=-1,Y=r.length;++D<Y;){var ut=r[D],yt=h(ut);if(yt!=null&&(bt===o?yt===yt&&!to(yt):y(yt,bt)))var bt=yt,Bt=ut}return Bt}function tr(r,h,y,D){var Y=r.length;for(y=wi(y),y<0&&(y=-y>Y?0:Y+y),D=D===o||D>Y?Y:wi(D),D<0&&(D+=Y),D=y>D?0:Ap(D);y<D;)r[y++]=h;return r}function Br(r,h){var y=[];return yn(r,function(D,Y,ut){h(D,Y,ut)&&y.push(D)}),y}function bn(r,h,y,D,Y){var ut=-1,yt=r.length;for(y||(y=t0),Y||(Y=[]);++ut<yt;){var bt=r[ut];h>0&&y(bt)?h>1?bn(bt,h-1,y,D,Y):fo(Y,bt):D||(Y[Y.length]=bt)}return Y}var Ml=Tt(),lh=Tt(!0);function Nr(r,h){return r&&Ml(r,h,Jn)}function hh(r,h){return r&&lh(r,h,Jn)}function Gs(r,h){return Rr(h,function(y){return Xs(r[y])})}function hs(r,h){h=Je(h,r);for(var y=0,D=h.length;r!=null&&y<D;)r=r[cs(h[y++])];return y&&y==D?r:o}function Uu(r,h,y){var D=h(r);return vi(r)?D:fo(D,y(r))}function Zn(r){return r==null?r===o?st:jt:xo&&xo in Ee(r)?Yg(r):a0(r)}function uh(r,h){return r>h}function ch(r,h){return r!=null&&Ti.call(r,h)}function $h(r,h){return r!=null&&h in Ee(r)}function fh(r,h,y){return r>=Vn(h,y)&&r<vn(h,y)}function Sl(r,h,y){for(var D=y?Jl:nl,Y=r[0].length,ut=r.length,yt=ut,bt=Zt(ut),Bt=1/0,oe=[];yt--;){var le=r[yt];yt&&h&&(le=Yi(le,Gn(h))),Bt=Vn(le.length,Bt),bt[yt]=!y&&(h||Y>=120&&le.length>=120)?new Us(yt&&le):o}le=r[0];var de=-1,ke=bt[0];t:for(;++de<Y&&oe.length<Bt;){var Ze=le[de],hi=h?h(Ze):Ze;if(Ze=y||Ze!==0?Ze:0,!(ke?mo(ke,hi):D(oe,hi,y))){for(yt=ut;--yt;){var Mi=bt[yt];if(!(Mi?mo(Mi,hi):D(r[yt],hi,y)))continue t}ke&&ke.push(hi),oe.push(Ze)}}return oe}function t(r,h,y,D){return Nr(r,function(Y,ut,yt){h(D,y(Y),ut,yt)}),D}function e(r,h,y){h=Je(h,r),r=ep(r,h);var D=r==null?r:r[cs(bo(h))];return D==null?o:yr(D,r,y)}function i(r){return Ln(r)&&Zn(r)==Wt}function n(r){return Ln(r)&&Zn(r)==Ut}function s(r){return Ln(r)&&Zn(r)==Ge}function l(r,h,y,D,Y){return r===h?!0:r==null||h==null||!Ln(r)&&!Ln(h)?r!==r&&h!==h:d(r,h,y,D,l,Y)}function d(r,h,y,D,Y,ut){var yt=vi(r),bt=vi(h),Bt=yt?$e:mr(r),oe=bt?$e:mr(h);Bt=Bt==Wt?dt:Bt,oe=oe==Wt?dt:oe;var le=Bt==dt,de=oe==dt,ke=Bt==oe;if(ke&&Ba(r)){if(!Ba(h))return!1;yt=!0,le=!1}if(ke&&!le)return ut||(ut=new Qr),yt||mh(r)?Yd(r,h,y,D,Y,ut):Xg(r,h,Bt,y,D,Y,ut);if(!(y&F)){var Ze=le&&Ti.call(r,"__wrapped__"),hi=de&&Ti.call(h,"__wrapped__");if(Ze||hi){var Mi=Ze?r.value():r,ui=hi?h.value():h;return ut||(ut=new Qr),Y(Mi,ui,y,D,ut)}}return ke?(ut||(ut=new Qr),qg(r,h,y,D,Y,ut)):!1}function p(r){return Ln(r)&&mr(r)==W}function _(r,h,y,D){var Y=y.length,ut=Y,yt=!D;if(r==null)return!ut;for(r=Ee(r);Y--;){var bt=y[Y];if(yt&&bt[2]?bt[1]!==r[bt[0]]:!(bt[0]in r))return!1}for(;++Y<ut;){bt=y[Y];var Bt=bt[0],oe=r[Bt],le=bt[1];if(yt&&bt[2]){if(oe===o&&!(Bt in r))return!1}else{var de=new Qr;if(D)var ke=D(oe,le,Bt,r,h,de);if(!(ke===o?l(le,oe,F|E,D,de):ke))return!1}}return!0}function T(r){if(!wn(r)||i0(r))return!1;var h=Xs(r)?Io:ys;return h.test(Cl(r))}function A(r){return Ln(r)&&Zn(r)==ie}function L(r){return Ln(r)&&mr(r)==Kt}function B(r){return Ln(r)&&$u(r.length)&&!!Xi[Zn(r)]}function H(r){return typeof r=="function"?r:r==null?Gr:typeof r=="object"?vi(r)?Ct(r[0],r[1]):gt(r):Fp(r)}function q(r){if(!nu(r))return Lu(r);var h=[];for(var y in Ee(r))Ti.call(r,y)&&y!="constructor"&&h.push(y);return h}function $(r){if(!wn(r))return s0(r);var h=nu(r),y=[];for(var D in r)D=="constructor"&&(h||!Ti.call(r,D))||y.push(D);return y}function rt(r,h){return r<h}function xt(r,h){var y=-1,D=Fr(r)?Zt(r.length):[];return yn(r,function(Y,ut,yt){D[++y]=h(Y,ut,yt)}),D}function gt(r){var h=tf(r);return h.length==1&&h[0][2]?Qd(h[0][0],h[0][1]):function(y){return y===r||_(y,r,h)}}function Ct(r,h){return nf(r)&&Kd(h)?Qd(cs(r),h):function(y){var D=df(y,r);return D===o&&D===h?pf(y,r):l(h,D,F|E)}}function wt(r,h,y,D,Y){r!==h&&Ml(h,function(ut,yt){if(Y||(Y=new Qr),wn(ut))Vt(r,h,yt,y,wt,D,Y);else{var bt=D?D(of(r,yt),ut,yt+"",r,h,Y):o;bt===o&&(bt=ut),ah(r,yt,bt)}},Ur)}function Vt(r,h,y,D,Y,ut,yt){var bt=of(r,y),Bt=of(h,y),oe=yt.get(Bt);if(oe){ah(r,y,oe);return}var le=ut?ut(bt,Bt,y+"",r,h,yt):o,de=le===o;if(de){var ke=vi(Bt),Ze=!ke&&Ba(Bt),hi=!ke&&!Ze&&mh(Bt);le=Bt,ke||Ze||hi?vi(bt)?le=bt:Dn(bt)?le=er(bt):Ze?(de=!1,le=No(Bt,!0)):hi?(de=!1,le=El(Bt,!0)):le=[]:ou(Bt)||Al(Bt)?(le=bt,Al(bt)?le=Pp(bt):(!wn(bt)||Xs(bt))&&(le=$d(Bt))):de=!1}de&&(yt.set(Bt,le),Y(le,Bt,D,ut,yt),yt.delete(Bt)),ah(r,y,le)}function K(r,h){var y=r.length;if(y)return h+=h<0?y:0,js(h,y)?r[h]:o}function ot(r,h,y){h.length?h=Yi(h,function(ut){return vi(ut)?function(yt){return hs(yt,ut.length===1?ut[0]:ut)}:ut}):h=[Gr];var D=-1;h=Yi(h,Gn(si()));var Y=xt(r,function(ut,yt,bt){var Bt=Yi(h,function(oe){return oe(ut)});return{criteria:Bt,index:++D,value:ut}});return Au(Y,function(ut,yt){return us(ut,yt,y)})}function kt(r,h){return ee(r,h,function(y,D){return pf(r,D)})}function ee(r,h,y){for(var D=-1,Y=h.length,ut={};++D<Y;){var yt=h[D],bt=hs(r,yt);y(bt,yt)&&fi(ut,Je(yt,r),bt)}return ut}function $t(r){return function(h){return hs(h,r)}}function Yt(r,h,y,D){var Y=D?ol:Or,ut=-1,yt=h.length,bt=r;for(r===h&&(h=er(h)),y&&(bt=Yi(r,Gn(y)));++ut<yt;)for(var Bt=0,oe=h[ut],le=y?y(oe):oe;(Bt=Y(bt,le,Bt,D))>-1;)bt!==r&&Ds.call(bt,Bt,1),Ds.call(r,Bt,1);return r}function Te(r,h){for(var y=r?h.length:0,D=y-1;y--;){var Y=h[y];if(y==D||Y!==ut){var ut=Y;js(Y)?Ds.call(r,Y,1):Wi(r,Y)}}return r}function ge(r,h){return r+ks(rh()*(h-r+1))}function De(r,h,y,D){for(var Y=-1,ut=vn(Do((h-r)/(y||1)),0),yt=Zt(ut);ut--;)yt[D?ut:++Y]=r,r+=y;return yt}function be(r,h){var y="";if(!r||h<1||h>ce)return y;do h%2&&(y+=r),h=ks(h/2),h&&(r+=r);while(h);return y}function ae(r,h){return sf(tp(r,h,Gr),r+"")}function We(r){return qh(gh(r))}function Qe(r,h){var y=gh(r);return ju(y,ls(h,0,y.length))}function fi(r,h,y,D){if(!wn(r))return r;h=Je(h,r);for(var Y=-1,ut=h.length,yt=ut-1,bt=r;bt!=null&&++Y<ut;){var Bt=cs(h[Y]),oe=y;if(Bt==="__proto__"||Bt==="constructor"||Bt==="prototype")return r;if(Y!=yt){var le=bt[Bt];oe=D?D(le,Bt,bt):o,oe===o&&(oe=wn(le)?le:js(h[Y+1])?[]:{})}Ra(bt,Bt,oe),bt=bt[Bt]}return r}var Cn=pl?function(r,h){return pl.set(r,h),r}:Gr,_n=zs?function(r,h){return zs(r,"toString",{configurable:!0,enumerable:!1,value:gf(h),writable:!0})}:Gr;function qi(r){return ju(gh(r))}function Vi(r,h,y){var D=-1,Y=r.length;h<0&&(h=-h>Y?0:Y+h),y=y>Y?Y:y,y<0&&(y+=Y),Y=h>y?0:y-h>>>0,h>>>=0;for(var ut=Zt(Y);++D<Y;)ut[D]=r[D+h];return ut}function on(r,h){var y;return yn(r,function(D,Y,ut){return y=h(D,Y,ut),!y}),!!y}function An(r,h,y){var D=0,Y=r==null?D:r.length;if(typeof h=="number"&&h===h&&Y<=Pe){for(;D<Y;){var ut=D+Y>>>1,yt=r[ut];yt!==null&&!to(yt)&&(y?yt<=h:yt<h)?D=ut+1:Y=ut}return Y}return Ce(r,h,Gr,y)}function Ce(r,h,y,D){var Y=0,ut=r==null?0:r.length;if(ut===0)return 0;h=y(h);for(var yt=h!==h,bt=h===null,Bt=to(h),oe=h===o;Y<ut;){var le=ks((Y+ut)/2),de=y(r[le]),ke=de!==o,Ze=de===null,hi=de===de,Mi=to(de);if(yt)var ui=D||hi;else oe?ui=hi&&(D||ke):bt?ui=hi&&ke&&(D||!Ze):Bt?ui=hi&&ke&&!Ze&&(D||!Mi):Ze||Mi?ui=!1:ui=D?de<=h:de<h;ui?Y=le+1:ut=le}return Vn(ut,Nt)}function ti(r,h){for(var y=-1,D=r.length,Y=0,ut=[];++y<D;){var yt=r[y],bt=h?h(yt):yt;if(!y||!Uo(bt,Bt)){var Bt=bt;ut[Y++]=yt===0?0:yt}}return ut}function Ht(r){return typeof r=="number"?r:to(r)?Ft:+r}function Ye(r){if(typeof r=="string")return r;if(vi(r))return Yi(r,Ye)+"";if(to(r))return jh?jh.call(r):"";var h=r+"";return h=="0"&&1/r==-At?"-0":h}function ei(r,h,y){var D=-1,Y=nl,ut=r.length,yt=!0,bt=[],Bt=bt;if(y)yt=!1,Y=Jl;else if(ut>=f){var oe=h?null:ka(r);if(oe)return Is(oe);yt=!1,Y=mo,Bt=new Us}else Bt=h?[]:bt;t:for(;++D<ut;){var le=r[D],de=h?h(le):le;if(le=y||le!==0?le:0,yt&&de===de){for(var ke=Bt.length;ke--;)if(Bt[ke]===de)continue t;h&&Bt.push(de),bt.push(le)}else Y(Bt,de,y)||(Bt!==bt&&Bt.push(de),bt.push(le))}return bt}function Wi(r,h){return h=Je(h,r),r=ep(r,h),r==null||delete r[cs(bo(h))]}function Ae(r,h,y,D){return fi(r,h,y(hs(r,h)),D)}function Xe(r,h,y,D){for(var Y=r.length,ut=D?Y:-1;(D?ut--:++ut<Y)&&h(r[ut],ut,r););return y?Vi(r,D?0:ut,D?ut+1:Y):Vi(r,D?ut+1:0,D?Y:ut)}function ri(r,h){var y=r;return y instanceof _i&&(y=y.value()),$l(h,function(D,Y){return Y.func.apply(Y.thisArg,fo([D],Y.args))},y)}function Li(r,h,y){var D=r.length;if(D<2)return D?ei(r[0]):[];for(var Y=-1,ut=Zt(D);++Y<D;)for(var yt=r[Y],bt=-1;++bt<D;)bt!=Y&&(ut[Y]=Tl(ut[Y]||yt,r[bt],h,y));return ei(bn(ut,1),h,y)}function Ai(r,h,y){for(var D=-1,Y=r.length,ut=h.length,yt={};++D<Y;){var bt=D<ut?h[D]:o;y(yt,r[D],bt)}return yt}function ne(r){return Dn(r)?r:[]}function ii(r){return typeof r=="function"?r:Gr}function Je(r,h){return vi(r)?r:nf(r,h)?[r]:op(Zi(r))}var li=ae;function xn(r,h,y){var D=r.length;return y=y===o?D:y,!h&&y>=D?r:Vi(r,h,y)}var Pn=eh||function(r){return gn.clearTimeout(r)};function No(r,h){if(h)return r.slice();var y=r.length,D=al?al(y):new r.constructor(y);return r.copy(D),D}function Ia(r){var h=new r.constructor(r.byteLength);return new tn(h).set(new tn(r)),h}function Kh(r,h){var y=h?Ia(r.buffer):r.buffer;return new r.constructor(y,r.byteOffset,r.byteLength)}function Da(r){var h=new r.constructor(r.source,jl.exec(r));return h.lastIndex=r.lastIndex,h}function Hs(r){return Fs?Ee(Fs.call(r)):{}}function El(r,h){var y=h?Ia(r.buffer):r.buffer;return new r.constructor(y,r.byteOffset,r.length)}function Vs(r,h){if(r!==h){var y=r!==o,D=r===null,Y=r===r,ut=to(r),yt=h!==o,bt=h===null,Bt=h===h,oe=to(h);if(!bt&&!oe&&!ut&&r>h||ut&&yt&&Bt&&!bt&&!oe||D&&yt&&Bt||!y&&Bt||!Y)return 1;if(!D&&!ut&&!oe&&r<h||oe&&y&&Y&&!D&&!ut||bt&&y&&Y||!yt&&Y||!Bt)return-1}return 0}function us(r,h,y){for(var D=-1,Y=r.criteria,ut=h.criteria,yt=Y.length,bt=y.length;++D<yt;){var Bt=Vs(Y[D],ut[D]);if(Bt){if(D>=bt)return Bt;var oe=y[D];return Bt*(oe=="desc"?-1:1)}}return r.index-h.index}function Qh(r,h,y,D){for(var Y=-1,ut=r.length,yt=y.length,bt=-1,Bt=h.length,oe=vn(ut-yt,0),le=Zt(Bt+oe),de=!D;++bt<Bt;)le[bt]=h[bt];for(;++Y<yt;)(de||Y<ut)&&(le[y[Y]]=r[Y]);for(;oe--;)le[bt++]=r[Y++];return le}function tu(r,h,y,D){for(var Y=-1,ut=r.length,yt=-1,bt=y.length,Bt=-1,oe=h.length,le=vn(ut-bt,0),de=Zt(le+oe),ke=!D;++Y<le;)de[Y]=r[Y];for(var Ze=Y;++Bt<oe;)de[Ze+Bt]=h[Bt];for(;++yt<bt;)(ke||Y<ut)&&(de[Ze+y[yt]]=r[Y++]);return de}function er(r,h){var y=-1,D=r.length;for(h||(h=Zt(D));++y<D;)h[y]=r[y];return h}function In(r,h,y,D){var Y=!y;y||(y={});for(var ut=-1,yt=h.length;++ut<yt;){var bt=h[ut],Bt=D?D(y[bt],r[bt],bt,y,r):o;Bt===o&&(Bt=r[bt]),Y?Bo(y,bt,Bt):Ra(y,bt,Bt)}return y}function So(r,h){return In(r,ef(r),h)}function Gu(r,h){return In(r,Zd(r),h)}function za(r,h){return function(y,D){var Y=vi(y)?Zl:Bu,ut=h?h():{};return Y(y,r,si(D,2),ut)}}function Fo(r){return ae(function(h,y){var D=-1,Y=y.length,ut=Y>1?y[Y-1]:o,yt=Y>2?y[2]:o;for(ut=r.length>3&&typeof ut=="function"?(Y--,ut):o,yt&&Mr(y[0],y[1],yt)&&(ut=Y<3?o:ut,Y=1),h=Ee(h);++D<Y;){var bt=y[D];bt&&r(h,bt,D,ut)}return h})}function ft(r,h){return function(y,D){if(y==null)return y;if(!Fr(y))return r(y,D);for(var Y=y.length,ut=h?Y:-1,yt=Ee(y);(h?ut--:++ut<Y)&&D(yt[ut],ut,yt)!==!1;);return y}}function Tt(r){return function(h,y,D){for(var Y=-1,ut=Ee(h),yt=D(h),bt=yt.length;bt--;){var Bt=yt[r?bt:++Y];if(y(ut[Bt],Bt,ut)===!1)break}return h}}function mt(r,h,y){var D=h&P,Y=Ve(r);function ut(){var yt=this&&this!==gn&&this instanceof ut?Y:r;return yt.apply(D?y:this,arguments)}return ut}function Me(r){return function(h){h=Zi(h);var y=Ir(h)?ar(h):o,D=y?y[0]:h.charAt(0),Y=y?xn(y,1).join(""):h.slice(1);return D[r]()+Y}}function ze(r){return function(h){return $l(Bp(kp(h).replace(ha,"")),r,"")}}function Ve(r){return function(){var h=arguments;switch(h.length){case 0:return new r;case 1:return new r(h[0]);case 2:return new r(h[0],h[1]);case 3:return new r(h[0],h[1],h[2]);case 4:return new r(h[0],h[1],h[2],h[3]);case 5:return new r(h[0],h[1],h[2],h[3],h[4]);case 6:return new r(h[0],h[1],h[2],h[3],h[4],h[5]);case 7:return new r(h[0],h[1],h[2],h[3],h[4],h[5],h[6])}var y=ss(r.prototype),D=r.apply(y,h);return wn(D)?D:y}}function Se(r,h,y){var D=Ve(r);function Y(){for(var ut=arguments.length,yt=Zt(ut),bt=ut,Bt=ph(Y);bt--;)yt[bt]=arguments[bt];var oe=ut<3&&yt[0]!==Bt&&yt[ut-1]!==Bt?[]:Dr(yt,Bt);if(ut-=oe.length,ut<y)return iu(r,h,$i,Y.placeholder,o,yt,oe,o,o,y-ut);var le=this&&this!==gn&&this instanceof Y?D:r;return yr(le,this,yt)}return Y}function Ke(r){return function(h,y,D){var Y=Ee(h);if(!Fr(h)){var ut=si(y,3);h=Jn(h),y=function(bt){return ut(Y[bt],bt,Y)}}var yt=r(h,y,D);return yt>-1?Y[ut?h[yt]:yt]:o}}function Oi(r){return Ws(function(h){var y=h.length,D=y,Y=qn.prototype.thru;for(r&&h.reverse();D--;){var ut=h[D];if(typeof ut!="function")throw new lr(m);if(Y&&!yt&&Vu(ut)=="wrapper")var yt=new qn([],!0)}for(D=yt?D:y;++D<y;){ut=h[D];var bt=Vu(ut),Bt=bt=="wrapper"?Qc(ut):o;Bt&&rf(Bt[0])&&Bt[1]==(X|R|U|J)&&!Bt[4].length&&Bt[9]==1?yt=yt[Vu(Bt[0])].apply(yt,Bt[3]):yt=ut.length==1&&rf(ut)?yt[bt]():yt.thru(ut)}return function(){var oe=arguments,le=oe[0];if(yt&&oe.length==1&&vi(le))return yt.plant(le).value();for(var de=0,ke=y?h[de].apply(this,oe):le;++de<y;)ke=h[de].call(this,ke);return ke}})}function $i(r,h,y,D,Y,ut,yt,bt,Bt,oe){var le=h&X,de=h&P,ke=h&w,Ze=h&(R|C),hi=h&Z,Mi=ke?o:Ve(r);function ui(){for(var Ri=arguments.length,Ui=Zt(Ri),eo=Ri;eo--;)Ui[eo]=arguments[eo];if(Ze)var Sr=ph(ui),io=go(Ui,Sr);if(D&&(Ui=Qh(Ui,D,Y,Ze)),ut&&(Ui=tu(Ui,ut,yt,Ze)),Ri-=io,Ze&&Ri<oe){var zn=Dr(Ui,Sr);return iu(r,h,$i,ui.placeholder,y,Ui,zn,bt,Bt,oe-Ri)}var Go=de?y:this,Ys=ke?Go[r]:r;return Ri=Ui.length,bt?Ui=l0(Ui,bt):hi&&Ri>1&&Ui.reverse(),le&&Bt<Ri&&(Ui.length=Bt),this&&this!==gn&&this instanceof ui&&(Ys=Mi||Ve(Ys)),Ys.apply(Go,Ui)}return ui}function ve(r,h){return function(y,D){return t(y,r,h(D),{})}}function Tr(r,h){return function(y,D){var Y;if(y===o&&D===o)return h;if(y!==o&&(Y=y),D!==o){if(Y===o)return D;typeof y=="string"||typeof D=="string"?(y=Ye(y),D=Ye(D)):(y=Ht(y),D=Ht(D)),Y=r(y,D)}return Y}}function Nn(r){return Ws(function(h){return h=Yi(h,Gn(si())),ae(function(y){var D=this;return r(h,function(Y){return yr(Y,D,y)})})})}function an(r,h){h=h===o?" ":Ye(h);var y=h.length;if(y<2)return y?be(h,r):h;var D=be(h,Do(r/$r(h)));return Ir(h)?xn(ar(D),0,r).join(""):D.slice(0,r)}function pr(r,h,y,D){var Y=h&P,ut=Ve(r);function yt(){for(var bt=-1,Bt=arguments.length,oe=-1,le=D.length,de=Zt(le+Bt),ke=this&&this!==gn&&this instanceof yt?ut:r;++oe<le;)de[oe]=D[oe];for(;Bt--;)de[oe++]=arguments[++bt];return yr(ke,Y?y:this,de)}return yt}function eu(r){return function(h,y,D){return D&&typeof D!="number"&&Mr(h,y,D)&&(y=D=o),h=qs(h),y===o?(y=h,h=0):y=qs(y),D=D===o?h<y?1:-1:qs(D),De(h,y,D,r)}}function Eo(r){return function(h,y){return typeof h=="string"&&typeof y=="string"||(h=Co(h),y=Co(y)),r(h,y)}}function iu(r,h,y,D,Y,ut,yt,bt,Bt,oe){var le=h&R,de=le?yt:o,ke=le?o:yt,Ze=le?ut:o,hi=le?o:ut;h|=le?U:N,h&=~(le?N:U),h&M||(h&=~(P|w));var Mi=[r,h,Y,Ze,de,hi,ke,bt,Bt,oe],ui=y.apply(o,Mi);return rf(r)&&ip(ui,Mi),ui.placeholder=D,np(ui,r,h)}function dh(r){var h=fn[r];return function(y,D){if(y=Co(y),D=D==null?0:Vn(wi(D),292),D&&nh(y)){var Y=(Zi(y)+"e").split("e"),ut=h(Y[0]+"e"+(+Y[1]+D));return Y=(Zi(ut)+"e").split("e"),+(Y[0]+"e"+(+Y[1]-D))}return h(y)}}var ka=Ns&&1/Is(new Ns([,-0]))[1]==At?function(r){return new Ns(r)}:_f;function Hu(r){return function(h){var y=mr(h);return y==W?$n(h):y==Kt?Hn(h):Oo(h,r(h))}}function ir(r,h,y,D,Y,ut,yt,bt){var Bt=h&w;if(!Bt&&typeof r!="function")throw new lr(m);var oe=D?D.length:0;if(oe||(h&=~(U|N),D=Y=o),yt=yt===o?yt:vn(wi(yt),0),bt=bt===o?bt:wi(bt),oe-=Y?Y.length:0,h&N){var le=D,de=Y;D=Y=o}var ke=Bt?o:Qc(r),Ze=[r,h,y,D,Y,le,de,ut,yt,bt];if(ke&&o0(Ze,ke),r=Ze[0],h=Ze[1],y=Ze[2],D=Ze[3],Y=Ze[4],bt=Ze[9]=Ze[9]===o?Bt?0:r.length:vn(Ze[9]-oe,0),!bt&&h&(R|C)&&(h&=~(R|C)),!h||h==P)var hi=mt(r,h,y);else h==R||h==C?hi=Se(r,h,bt):(h==U||h==(P|U))&&!Y.length?hi=pr(r,h,y,D):hi=$i.apply(o,Ze);var Mi=ke?Cn:ip;return np(Mi(hi,Ze),r,h)}function Xd(r,h,y,D){return r===o||Uo(r,vo[y])&&!Ti.call(D,y)?h:r}function qd(r,h,y,D,Y,ut){return wn(r)&&wn(h)&&(ut.set(h,r),wt(r,h,o,qd,ut),ut.delete(h)),r}function jg(r){return ou(r)?o:r}function Yd(r,h,y,D,Y,ut){var yt=y&F,bt=r.length,Bt=h.length;if(bt!=Bt&&!(yt&&Bt>bt))return!1;var oe=ut.get(r),le=ut.get(h);if(oe&&le)return oe==h&&le==r;var de=-1,ke=!0,Ze=y&E?new Us:o;for(ut.set(r,h),ut.set(h,r);++de<bt;){var hi=r[de],Mi=h[de];if(D)var ui=yt?D(Mi,hi,de,h,r,ut):D(hi,Mi,de,r,h,ut);if(ui!==o){if(ui)continue;ke=!1;break}if(Ze){if(!Po(h,function(Ri,Ui){if(!mo(Ze,Ui)&&(hi===Ri||Y(hi,Ri,y,D,ut)))return Ze.push(Ui)})){ke=!1;break}}else if(!(hi===Mi||Y(hi,Mi,y,D,ut))){ke=!1;break}}return ut.delete(r),ut.delete(h),ke}function Xg(r,h,y,D,Y,ut,yt){switch(y){case qt:if(r.byteLength!=h.byteLength||r.byteOffset!=h.byteOffset)return!1;r=r.buffer,h=h.buffer;case Ut:return!(r.byteLength!=h.byteLength||!ut(new tn(r),new tn(h)));case Oe:case Ge:case Jt:return Uo(+r,+h);case Di:return r.name==h.name&&r.message==h.message;case ie:case z:return r==h+"";case W:var bt=$n;case Kt:var Bt=D&F;if(bt||(bt=Is),r.size!=h.size&&!Bt)return!1;var oe=yt.get(r);if(oe)return oe==h;D|=E,yt.set(r,h);var le=Yd(bt(r),bt(h),D,Y,ut,yt);return yt.delete(r),le;case Q:if(Fs)return Fs.call(r)==Fs.call(h)}return!1}function qg(r,h,y,D,Y,ut){var yt=y&F,bt=$c(r),Bt=bt.length,oe=$c(h),le=oe.length;if(Bt!=le&&!yt)return!1;for(var de=Bt;de--;){var ke=bt[de];if(!(yt?ke in h:Ti.call(h,ke)))return!1}var Ze=ut.get(r),hi=ut.get(h);if(Ze&&hi)return Ze==h&&hi==r;var Mi=!0;ut.set(r,h),ut.set(h,r);for(var ui=yt;++de<Bt;){ke=bt[de];var Ri=r[ke],Ui=h[ke];if(D)var eo=yt?D(Ui,Ri,ke,h,r,ut):D(Ri,Ui,ke,r,h,ut);if(!(eo===o?Ri===Ui||Y(Ri,Ui,y,D,ut):eo)){Mi=!1;break}ui||(ui=ke=="constructor")}if(Mi&&!ui){var Sr=r.constructor,io=h.constructor;Sr!=io&&"constructor"in r&&"constructor"in h&&!(typeof Sr=="function"&&Sr instanceof Sr&&typeof io=="function"&&io instanceof io)&&(Mi=!1)}return ut.delete(r),ut.delete(h),Mi}function Ws(r){return sf(tp(r,o,hp),r+"")}function $c(r){return Uu(r,Jn,ef)}function Kc(r){return Uu(r,Ur,Zd)}var Qc=pl?function(r){return pl.get(r)}:_f;function Vu(r){for(var h=r.name+"",y=os[h],D=Ti.call(os,h)?y.length:0;D--;){var Y=y[D],ut=Y.func;if(ut==null||ut==r)return Y.name}return h}function ph(r){var h=Ti.call(it,"placeholder")?it:r;return h.placeholder}function si(){var r=it.iteratee||vf;return r=r===vf?H:r,arguments.length?r(arguments[0],arguments[1]):r}function Wu(r,h){var y=r.__data__;return e0(h)?y[typeof h=="string"?"string":"hash"]:y.map}function tf(r){for(var h=Jn(r),y=h.length;y--;){var D=h[y],Y=r[D];h[y]=[D,Y,Kd(Y)]}return h}function bl(r,h){var y=Ls(r,h);return T(y)?y:o}function Yg(r){var h=Ti.call(r,xo),y=r[xo];try{r[xo]=o;var D=!0}catch{}var Y=cr.call(r);return D&&(h?r[xo]=y:delete r[xo]),Y}var ef=ul?function(r){return r==null?[]:(r=Ee(r),Rr(ul(r),function(h){return hl.call(r,h)}))}:xf,Zd=ul?function(r){for(var h=[];r;)fo(h,ef(r)),r=_o(r);return h}:xf,mr=Zn;(fl&&mr(new fl(new ArrayBuffer(1)))!=qt||Bs&&mr(new Bs)!=W||dl&&mr(dl.resolve())!=pt||Ns&&mr(new Ns)!=Kt||En&&mr(new En)!=nt)&&(mr=function(r){var h=Zn(r),y=h==dt?r.constructor:o,D=y?Cl(y):"";if(D)switch(D){case oh:return qt;case Hh:return W;case Vh:return pt;case Wh:return Kt;case Ru:return nt}return h});function Zg(r,h,y){for(var D=-1,Y=y.length;++D<Y;){var ut=y[D],yt=ut.size;switch(ut.type){case"drop":r+=yt;break;case"dropRight":h-=yt;break;case"take":h=Vn(h,r+yt);break;case"takeRight":r=vn(r,h-yt);break}}return{start:r,end:h}}function Jg(r){var h=r.match(Ja);return h?h[1].split(ho):[]}function Jd(r,h,y){h=Je(h,r);for(var D=-1,Y=h.length,ut=!1;++D<Y;){var yt=cs(h[D]);if(!(ut=r!=null&&y(r,yt)))break;r=r[yt]}return ut||++D!=Y?ut:(Y=r==null?0:r.length,!!Y&&$u(Y)&&js(yt,Y)&&(vi(r)||Al(r)))}function $g(r){var h=r.length,y=new r.constructor(h);return h&&typeof r[0]=="string"&&Ti.call(r,"index")&&(y.index=r.index,y.input=r.input),y}function $d(r){return typeof r.constructor=="function"&&!nu(r)?ss(_o(r)):{}}function Kg(r,h,y){var D=r.constructor;switch(h){case Ut:return Ia(r);case Oe:case Ge:return new D(+r);case qt:return Kh(r,y);case Xt:case Ne:case Ie:case me:case we:case yi:case Ei:case ni:case bi:return El(r,y);case W:return new D;case Jt:case z:return new D(r);case ie:return Da(r);case Kt:return new D;case Q:return Hs(r)}}function Qg(r,h){var y=h.length;if(!y)return r;var D=y-1;return h[D]=(y>1?"& ":"")+h[D],h=h.join(y>2?", ":" "),r.replace(sa,`{
|
|
2618
2618
|
/* [wrapped with `+h+`] */
|
|
2619
|
-
`)}function t0(r){return vi(r)||Al(r)||!!(Ma&&r&&r[Ma])}function js(r,h){var y=typeof r;return h=h??ce,!!h&&(y=="number"||y!="symbol"&&Xl.test(r))&&r>-1&&r%1==0&&r<h}function Mr(r,h,y){if(!wn(y))return!1;var D=typeof h;return(D=="number"?Fr(y)&&js(h,y.length):D=="string"&&h in y)?Uo(y[h],r):!1}function nf(r,h){if(vi(r))return!1;var y=typeof r;return y=="number"||y=="symbol"||y=="boolean"||r==null||to(r)?!0:vr.test(r)||!vs.test(r)||h!=null&&r in Ee(h)}function e0(r){var h=typeof r;return h=="string"||h=="number"||h=="symbol"||h=="boolean"?r!=="__proto__":r===null}function rf(r){var h=Vu(r),y=it[h];if(typeof y!="function"||!(h in _i.prototype))return!1;if(r===y)return!0;var D=Qc(y);return!!D&&r===D[0]}function i0(r){return!!zr&&zr in r}var n0=ns?Xs:wf;function nu(r){var h=r&&r.constructor,y=typeof h=="function"&&h.prototype||vo;return r===y}function Kd(r){return r===r&&!wn(r)}function Qd(r,h){return function(y){return y==null?!1:y[r]===h&&(h!==o||r in Ee(y))}}function r0(r){var h=Zu(r,function(D){return y.size===S&&y.clear(),D}),y=h.cache;return h}function o0(r,h){var y=r[1],D=h[1],Y=y|D,ut=Y<(P|w|X),yt=D==X&&y==R||D==X&&y==K&&r[7].length<=h[8]||D==(X|K)&&h[7].length<=h[8]&&y==R;if(!(ut||yt))return r;D&P&&(r[2]=h[2],Y|=y&P?0:M);var bt=h[3];if(bt){var Bt=r[3];r[3]=Bt?Qh(Bt,bt,h[4]):bt,r[4]=Bt?Dr(r[3],b):h[4]}return bt=h[5],bt&&(Bt=r[5],r[5]=Bt?tu(Bt,bt,h[6]):bt,r[6]=Bt?Dr(r[5],b):h[6]),bt=h[7],bt&&(r[7]=bt),D&X&&(r[8]=r[8]==null?h[8]:Vn(r[8],h[8])),r[9]==null&&(r[9]=h[9]),r[0]=h[0],r[1]=Y,r}function s0(r){var h=[];if(r!=null)for(var y in Ee(r))h.push(y);return h}function a0(r){return cr.call(r)}function tp(r,h,y){return h=vn(h===o?r.length-1:h,0),function(){for(var D=arguments,Y=-1,ut=vn(D.length-h,0),yt=Zt(ut);++Y<ut;)yt[Y]=D[h+Y];Y=-1;for(var bt=Zt(h+1);++Y<h;)bt[Y]=D[Y];return bt[h]=y(yt),yr(r,this,bt)}}function ep(r,h){return h.length<2?r:hs(r,Vi(h,0,-1))}function l0(r,h){for(var y=r.length,D=Vn(h.length,y),Y=er(r);D--;){var ut=h[D];r[D]=js(ut,y)?Y[ut]:o}return r}function of(r,h){if(!(h==="constructor"&&typeof r[h]=="function")&&h!="__proto__")return r[h]}var ip=rp(Cn),ru=Nh||function(r,h){return gn.setTimeout(r,h)},sf=rp(_n);function np(r,h,y){var D=h+"";return sf(r,Qg(D,h0(Jg(D),y)))}function rp(r){var h=0,y=0;return function(){var D=cl(),Y=_t-(D-y);if(y=D,Y>0){if(++h>=tt)return arguments[0]}else h=0;return r.apply(o,arguments)}}function ju(r,h){var y=-1,D=r.length,Y=D-1;for(h=h===o?D:h;++y<h;){var ut=ge(y,Y),yt=r[ut];r[ut]=r[y],r[y]=yt}return r.length=h,r}var op=r0(function(r){var h=[];return r.charCodeAt(0)===46&&h.push(""),r.replace(oa,function(y,D,Y,ut){h.push(Y?ut.replace(la,"$1"):D||y)}),h});function cs(r){if(typeof r=="string"||to(r))return r;var h=r+"";return h=="0"&&1/r==-At?"-0":h}function Cl(r){if(r!=null){try{return hr.call(r)}catch{}try{return r+""}catch{}}return""}function h0(r,h){return Ji(pe,function(y){var D="_."+y[0];h&y[1]&&!nl(r,D)&&r.push(D)}),r.sort()}function sp(r){if(r instanceof _i)return r.clone();var h=new qn(r.__wrapped__,r.__chain__);return h.__actions__=er(r.__actions__),h.__index__=r.__index__,h.__values__=r.__values__,h}function u0(r,h,y){(y?Mr(r,h,y):h===o)?h=1:h=vn(wi(h),0);var D=r==null?0:r.length;if(!D||h<1)return[];for(var Y=0,ut=0,yt=Zt(Do(D/h));Y<D;)yt[ut++]=Vi(r,Y,Y+=h);return yt}function c0(r){for(var h=-1,y=r==null?0:r.length,D=0,Y=[];++h<y;){var ut=r[h];ut&&(Y[D++]=ut)}return Y}function f0(){var r=arguments.length;if(!r)return[];for(var h=Zt(r-1),y=arguments[0],D=r;D--;)h[D-1]=arguments[D];return fo(vi(y)?er(y):[y],bn(h,1))}var d0=ae(function(r,h){return Dn(r)?Tl(r,bn(h,1,Dn,!0)):[]}),p0=ae(function(r,h){var y=bo(h);return Dn(y)&&(y=o),Dn(r)?Tl(r,bn(h,1,Dn,!0),si(y,2)):[]}),m0=ae(function(r,h){var y=bo(h);return Dn(y)&&(y=o),Dn(r)?Tl(r,bn(h,1,Dn,!0),o,y):[]});function g0(r,h,y){var D=r==null?0:r.length;return D?(h=y||h===o?1:wi(h),Vi(r,h<0?0:h,D)):[]}function v0(r,h,y){var D=r==null?0:r.length;return D?(h=y||h===o?1:wi(h),h=D-h,Vi(r,0,h<0?0:h)):[]}function y0(r,h){return r&&r.length?Xe(r,si(h,3),!0,!0):[]}function _0(r,h){return r&&r.length?Xe(r,si(h,3),!0):[]}function x0(r,h,y,D){var Y=r==null?0:r.length;return Y?(y&&typeof y!="number"&&Mr(r,h,y)&&(y=0,D=Y),tr(r,h,y,D)):[]}function ap(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=y==null?0:wi(y);return Y<0&&(Y=vn(D+Y,0)),$o(r,si(h,3),Y)}function lp(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=D-1;return y!==o&&(Y=wi(y),Y=y<0?vn(D+Y,0):Vn(Y,D-1)),$o(r,si(h,3),Y,!0)}function hp(r){var h=r==null?0:r.length;return h?bn(r,1):[]}function w0(r){var h=r==null?0:r.length;return h?bn(r,At):[]}function T0(r,h){var y=r==null?0:r.length;return y?(h=h===o?1:wi(h),bn(r,h)):[]}function M0(r){for(var h=-1,y=r==null?0:r.length,D={};++h<y;){var Y=r[h];D[Y[0]]=Y[1]}return D}function up(r){return r&&r.length?r[0]:o}function S0(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=y==null?0:wi(y);return Y<0&&(Y=vn(D+Y,0)),Or(r,h,Y)}function E0(r){var h=r==null?0:r.length;return h?Vi(r,0,-1):[]}var b0=ae(function(r){var h=Yi(r,ne);return h.length&&h[0]===r[0]?Sl(h):[]}),C0=ae(function(r){var h=bo(r),y=Yi(r,ne);return h===bo(y)?h=o:y.pop(),y.length&&y[0]===r[0]?Sl(y,si(h,2)):[]}),A0=ae(function(r){var h=bo(r),y=Yi(r,ne);return h=typeof h=="function"?h:o,h&&y.pop(),y.length&&y[0]===r[0]?Sl(y,o,h):[]});function P0(r,h){return r==null?"":Uh.call(r,h)}function bo(r){var h=r==null?0:r.length;return h?r[h-1]:o}function L0(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=D;return y!==o&&(Y=wi(y),Y=Y<0?vn(D+Y,0):Vn(Y,D-1)),h===h?Ql(r,h,Y):$o(r,Es,Y,!0)}function R0(r,h){return r&&r.length?$(r,wi(h)):o}var O0=ae(cp);function cp(r,h){return r&&r.length&&h&&h.length?Yt(r,h):r}function I0(r,h,y){return r&&r.length&&h&&h.length?Yt(r,h,si(y,2)):r}function D0(r,h,y){return r&&r.length&&h&&h.length?Yt(r,h,o,y):r}var z0=Ws(function(r,h){var y=r==null?0:r.length,D=Jh(r,h);return Te(r,Yi(h,function(Y){return js(Y,y)?+Y:Y}).sort(Vs)),D});function k0(r,h){var y=[];if(!(r&&r.length))return y;var D=-1,Y=[],ut=r.length;for(h=si(h,3);++D<ut;){var yt=r[D];h(yt,D,r)&&(y.push(yt),Y.push(D))}return Te(r,Y),y}function af(r){return r==null?r:Sa.call(r)}function B0(r,h,y){var D=r==null?0:r.length;return D?(y&&typeof y!="number"&&Mr(r,h,y)?(h=0,y=D):(h=h==null?0:wi(h),y=y===o?D:wi(y)),Vi(r,h,y)):[]}function N0(r,h){return An(r,h)}function F0(r,h,y){return Ce(r,h,si(y,2))}function U0(r,h){var y=r==null?0:r.length;if(y){var D=An(r,h);if(D<y&&Uo(r[D],h))return D}return-1}function G0(r,h){return An(r,h,!0)}function H0(r,h,y){return Ce(r,h,si(y,2),!0)}function V0(r,h){var y=r==null?0:r.length;if(y){var D=An(r,h,!0)-1;if(Uo(r[D],h))return D}return-1}function W0(r){return r&&r.length?ti(r):[]}function j0(r,h){return r&&r.length?ti(r,si(h,2)):[]}function X0(r){var h=r==null?0:r.length;return h?Vi(r,1,h):[]}function q0(r,h,y){return r&&r.length?(h=y||h===o?1:wi(h),Vi(r,0,h<0?0:h)):[]}function Y0(r,h,y){var D=r==null?0:r.length;return D?(h=y||h===o?1:wi(h),h=D-h,Vi(r,h<0?0:h,D)):[]}function Z0(r,h){return r&&r.length?Xe(r,si(h,3),!1,!0):[]}function J0(r,h){return r&&r.length?Xe(r,si(h,3)):[]}var $0=ae(function(r){return ei(bn(r,1,Dn,!0))}),K0=ae(function(r){var h=bo(r);return Dn(h)&&(h=o),ei(bn(r,1,Dn,!0),si(h,2))}),Q0=ae(function(r){var h=bo(r);return h=typeof h=="function"?h:o,ei(bn(r,1,Dn,!0),o,h)});function tv(r){return r&&r.length?ei(r):[]}function ev(r,h){return r&&r.length?ei(r,si(h,2)):[]}function iv(r,h){return h=typeof h=="function"?h:o,r&&r.length?ei(r,o,h):[]}function lf(r){if(!(r&&r.length))return[];var h=0;return r=Rr(r,function(y){if(Dn(y))return h=vn(y.length,h),!0}),Ro(h,function(y){return Yi(r,Ko(y))})}function fp(r,h){if(!(r&&r.length))return[];var y=lf(r);return h==null?y:Yi(y,function(D){return yr(h,o,D)})}var nv=ae(function(r,h){return Dn(r)?Tl(r,h):[]}),rv=ae(function(r){return Li(Rr(r,Dn))}),ov=ae(function(r){var h=bo(r);return Dn(h)&&(h=o),Li(Rr(r,Dn),si(h,2))}),sv=ae(function(r){var h=bo(r);return h=typeof h=="function"?h:o,Li(Rr(r,Dn),o,h)}),av=ae(lf);function lv(r,h){return Ai(r||[],h||[],Ra)}function hv(r,h){return Ai(r||[],h||[],fi)}var uv=ae(function(r){var h=r.length,y=h>1?r[h-1]:o;return y=typeof y=="function"?(r.pop(),y):o,fp(r,y)});function dp(r){var h=it(r);return h.__chain__=!0,h}function cv(r,h){return h(r),r}function Xu(r,h){return h(r)}var fv=Ws(function(r){var h=r.length,y=h?r[0]:0,D=this.__wrapped__,Y=function(ut){return Jh(ut,r)};return h>1||this.__actions__.length||!(D instanceof _i)||!js(y)?this.thru(Y):(D=D.slice(y,+y+(h?1:0)),D.__actions__.push({func:Xu,args:[Y],thisArg:o}),new qn(D,this.__chain__).thru(function(ut){return h&&!ut.length&&ut.push(o),ut}))});function dv(){return dp(this)}function pv(){return new qn(this.value(),this.__chain__)}function mv(){this.__values__===o&&(this.__values__=Cp(this.value()));var r=this.__index__>=this.__values__.length,h=r?o:this.__values__[this.__index__++];return{done:r,value:h}}function gv(){return this}function vv(r){for(var h,y=this;y instanceof ba;){var D=sp(y);D.__index__=0,D.__values__=o,h?Y.__wrapped__=D:h=D;var Y=D;y=y.__wrapped__}return Y.__wrapped__=r,h}function yv(){var r=this.__wrapped__;if(r instanceof _i){var h=r;return this.__actions__.length&&(h=new _i(this)),h=h.reverse(),h.__actions__.push({func:Xu,args:[af],thisArg:o}),new qn(h,this.__chain__)}return this.thru(af)}function _v(){return ri(this.__wrapped__,this.__actions__)}var xv=za(function(r,h,y){Ti.call(r,y)?++r[y]:Bo(r,y,1)});function wv(r,h,y){var D=vi(r)?Bh:Yn;return y&&Mr(r,h,y)&&(h=o),D(r,si(h,3))}function Tv(r,h){var y=vi(r)?Rr:Br;return y(r,si(h,3))}var Mv=Ke(ap),Sv=Ke(lp);function Ev(r,h){return bn(qu(r,h),1)}function bv(r,h){return bn(qu(r,h),At)}function Cv(r,h,y){return y=y===o?1:wi(y),bn(qu(r,h),y)}function pp(r,h){var y=vi(r)?Ji:yn;return y(r,si(h,3))}function mp(r,h){var y=vi(r)?Ms:Fu;return y(r,si(h,3))}var Av=za(function(r,h,y){Ti.call(r,y)?r[y].push(h):Bo(r,y,[h])});function Pv(r,h,y,D){r=Fr(r)?r:gh(r),y=y&&!D?wi(y):0;var Y=r.length;return y<0&&(y=vn(Y+y,0)),Ku(r)?y<=Y&&r.indexOf(h,y)>-1:!!Y&&Or(r,h,y)>-1}var Lv=ae(function(r,h,y){var D=-1,Y=typeof h=="function",ut=Fr(r)?Zt(r.length):[];return yn(r,function(yt){ut[++D]=Y?yr(h,yt,y):e(yt,h,y)}),ut}),Rv=za(function(r,h,y){Bo(r,y,h)});function qu(r,h){var y=vi(r)?Yi:xt;return y(r,si(h,3))}function Ov(r,h,y,D){return r==null?[]:(vi(h)||(h=h==null?[]:[h]),y=D?o:y,vi(y)||(y=y==null?[]:[y]),ot(r,h,y))}var Iv=za(function(r,h,y){r[y?0:1].push(h)},function(){return[[],[]]});function Dv(r,h,y){var D=vi(r)?$l:Qo,Y=arguments.length<3;return D(r,si(h,4),y,Y,yn)}function zv(r,h,y){var D=vi(r)?bu:Qo,Y=arguments.length<3;return D(r,si(h,4),y,Y,Fu)}function kv(r,h){var y=vi(r)?Rr:Br;return y(r,Ju(si(h,3)))}function Bv(r){var h=vi(r)?qh:We;return h(r)}function Nv(r,h,y){(y?Mr(r,h,y):h===o)?h=1:h=wi(h);var D=vi(r)?Jc:Qe;return D(r,h)}function Fv(r){var h=vi(r)?ku:qi;return h(r)}function Uv(r){if(r==null)return 0;if(Fr(r))return Ku(r)?$r(r):r.length;var h=mr(r);return h==W||h==Kt?r.size:q(r).length}function Gv(r,h,y){var D=vi(r)?Po:on;return y&&Mr(r,h,y)&&(h=o),D(r,si(h,3))}var Hv=ae(function(r,h){if(r==null)return[];var y=h.length;return y>1&&Mr(r,h[0],h[1])?h=[]:y>2&&Mr(h[0],h[1],h[2])&&(h=[h[0]]),ot(r,bn(h,1),[])}),Yu=ih||function(){return gn.Date.now()};function Vv(r,h){if(typeof h!="function")throw new lr(m);return r=wi(r),function(){if(--r<1)return h.apply(this,arguments)}}function gp(r,h,y){return h=y?o:h,h=r&&h==null?r.length:h,ir(r,X,o,o,o,o,h)}function vp(r,h){var y;if(typeof h!="function")throw new lr(m);return r=wi(r),function(){return--r>0&&(y=h.apply(this,arguments)),r<=1&&(h=o),y}}var hf=ae(function(r,h,y){var D=P;if(y.length){var Y=Dr(y,ph(hf));D|=U}return ir(r,D,h,y,Y)}),yp=ae(function(r,h,y){var D=P|w;if(y.length){var Y=Dr(y,ph(yp));D|=U}return ir(h,D,r,y,Y)});function _p(r,h,y){h=y?o:h;var D=ir(r,R,o,o,o,o,o,h);return D.placeholder=_p.placeholder,D}function xp(r,h,y){h=y?o:h;var D=ir(r,C,o,o,o,o,o,h);return D.placeholder=xp.placeholder,D}function wp(r,h,y){var D,Y,ut,yt,bt,Bt,oe=0,le=!1,de=!1,ke=!0;if(typeof r!="function")throw new lr(m);h=Co(h)||0,wn(y)&&(le=!!y.leading,de="maxWait"in y,ut=de?vn(Co(y.maxWait)||0,h):ut,ke="trailing"in y?!!y.trailing:ke);function Ze(zn){var Go=D,Ys=Y;return D=Y=o,oe=zn,yt=r.apply(Ys,Go),yt}function hi(zn){return oe=zn,bt=ru(Ri,h),le?Ze(zn):yt}function Mi(zn){var Go=zn-Bt,Ys=zn-oe,Up=h-Go;return de?Vn(Up,ut-Ys):Up}function ui(zn){var Go=zn-Bt,Ys=zn-oe;return Bt===o||Go>=h||Go<0||de&&Ys>=ut}function Ri(){var zn=Yu();if(ui(zn))return Ui(zn);bt=ru(Ri,Mi(zn))}function Ui(zn){return bt=o,ke&&D?Ze(zn):(D=Y=o,yt)}function eo(){bt!==o&&Pn(bt),oe=0,D=Bt=Y=bt=o}function Sr(){return bt===o?yt:Ui(Yu())}function io(){var zn=Yu(),Go=ui(zn);if(D=arguments,Y=this,Bt=zn,Go){if(bt===o)return hi(Bt);if(de)return Pn(bt),bt=ru(Ri,h),Ze(Bt)}return bt===o&&(bt=ru(Ri,h)),yt}return io.cancel=eo,io.flush=Sr,io}var Wv=ae(function(r,h){return To(r,1,h)}),jv=ae(function(r,h,y){return To(r,Co(h)||0,y)});function Xv(r){return ir(r,Z)}function Zu(r,h){if(typeof r!="function"||h!=null&&typeof h!="function")throw new lr(m);var y=function(){var D=arguments,Y=h?h.apply(this,D):D[0],ut=y.cache;if(ut.has(Y))return ut.get(Y);var yt=r.apply(this,D);return y.cache=ut.set(Y,yt)||ut,yt};return y.cache=new(Zu.Cache||xr),y}Zu.Cache=xr;function Ju(r){if(typeof r!="function")throw new lr(m);return function(){var h=arguments;switch(h.length){case 0:return!r.call(this);case 1:return!r.call(this,h[0]);case 2:return!r.call(this,h[0],h[1]);case 3:return!r.call(this,h[0],h[1],h[2])}return!r.apply(this,h)}}function qv(r){return vp(2,r)}var Yv=li(function(r,h){h=h.length==1&&vi(h[0])?Yi(h[0],Gn(si())):Yi(bn(h,1),Gn(si()));var y=h.length;return ae(function(D){for(var Y=-1,ut=Vn(D.length,y);++Y<ut;)D[Y]=h[Y].call(this,D[Y]);return yr(r,this,D)})}),uf=ae(function(r,h){var y=Dr(h,ph(uf));return ir(r,U,o,h,y)}),Tp=ae(function(r,h){var y=Dr(h,ph(Tp));return ir(r,F,o,h,y)}),Zv=Ws(function(r,h){return ir(r,K,o,o,o,h)});function Jv(r,h){if(typeof r!="function")throw new lr(m);return h=h===o?h:wi(h),ae(r,h)}function $v(r,h){if(typeof r!="function")throw new lr(m);return h=h==null?0:vn(wi(h),0),ae(function(y){var D=y[h],Y=xn(y,0,h);return D&&fo(Y,D),yr(r,this,Y)})}function Kv(r,h,y){var D=!0,Y=!0;if(typeof r!="function")throw new lr(m);return wn(y)&&(D="leading"in y?!!y.leading:D,Y="trailing"in y?!!y.trailing:Y),wp(r,h,{leading:D,maxWait:h,trailing:Y})}function Qv(r){return gp(r,1)}function ty(r,h){return uf(ii(h),r)}function ey(){if(!arguments.length)return[];var r=arguments[0];return vi(r)?r:[r]}function iy(r){return wr(r,I)}function ny(r,h){return h=typeof h=="function"?h:o,wr(r,I,h)}function ry(r){return wr(r,O|I)}function oy(r,h){return h=typeof h=="function"?h:o,wr(r,O|I,h)}function sy(r,h){return h==null||Nu(r,h,Jn(h))}function Uo(r,h){return r===h||r!==r&&h!==h}var ay=Eo(uh),ly=Eo(function(r,h){return r>=h}),Al=i(function(){return arguments}())?i:function(r){return Ln(r)&&Ti.call(r,"callee")&&!hl.call(r,"callee")},vi=Zt.isArray,hy=kh?Gn(kh):n;function Fr(r){return r!=null&&$u(r.length)&&!Xs(r)}function Dn(r){return Ln(r)&&Fr(r)}function uy(r){return r===!0||r===!1||Ln(r)&&Zn(r)==Oe}var Ba=Fh||wf,cy=ga?Gn(ga):s;function fy(r){return Ln(r)&&r.nodeType===1&&!ou(r)}function dy(r){if(r==null)return!0;if(Fr(r)&&(vi(r)||typeof r=="string"||typeof r.splice=="function"||Ba(r)||mh(r)||Al(r)))return!r.length;var h=mr(r);if(h==W||h==Kt)return!r.size;if(nu(r))return!q(r).length;for(var y in r)if(Ti.call(r,y))return!1;return!0}function py(r,h){return l(r,h)}function my(r,h,y){y=typeof y=="function"?y:o;var D=y?y(r,h):o;return D===o?l(r,h,o,y):!!D}function cf(r){if(!Ln(r))return!1;var h=Zn(r);return h==Di||h==pi||typeof r.message=="string"&&typeof r.name=="string"&&!ou(r)}function gy(r){return typeof r=="number"&&nh(r)}function Xs(r){if(!wn(r))return!1;var h=Zn(r);return h==mn||h==Qi||h==Si||h==Dt}function Mp(r){return typeof r=="number"&&r==wi(r)}function $u(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=ce}function wn(r){var h=typeof r;return r!=null&&(h=="object"||h=="function")}function Ln(r){return r!=null&&typeof r=="object"}var Sp=va?Gn(va):p;function vy(r,h){return r===h||_(r,h,tf(h))}function yy(r,h,y){return y=typeof y=="function"?y:o,_(r,h,tf(h),y)}function _y(r){return Ep(r)&&r!=+r}function xy(r){if(n0(r))throw new ai(u);return T(r)}function wy(r){return r===null}function Ty(r){return r==null}function Ep(r){return typeof r=="number"||Ln(r)&&Zn(r)==Jt}function ou(r){if(!Ln(r)||Zn(r)!=dt)return!1;var h=_o(r);if(h===null)return!0;var y=Ti.call(h,"constructor")&&h.constructor;return typeof y=="function"&&y instanceof y&&hr.call(y)==yo}var ff=Su?Gn(Su):A;function My(r){return Mp(r)&&r>=-ce&&r<=ce}var bp=Eu?Gn(Eu):L;function Ku(r){return typeof r=="string"||!vi(r)&&Ln(r)&&Zn(r)==z}function to(r){return typeof r=="symbol"||Ln(r)&&Zn(r)==Q}var mh=Yl?Gn(Yl):B;function Sy(r){return r===o}function Ey(r){return Ln(r)&&mr(r)==nt}function by(r){return Ln(r)&&Zn(r)==vt}var Cy=Eo(rt),Ay=Eo(function(r,h){return r<=h});function Cp(r){if(!r)return[];if(Fr(r))return Ku(r)?ar(r):er(r);if(rs&&r[rs])return Os(r[rs]());var h=mr(r),y=h==W?$n:h==Kt?Is:gh;return y(r)}function qs(r){if(!r)return r===0?r:0;if(r=Co(r),r===At||r===-At){var h=r<0?-1:1;return h*re}return r===r?r:0}function wi(r){var h=qs(r),y=h%1;return h===h?y?h-y:h:0}function Ap(r){return r?ls(wi(r),0,It):0}function Co(r){if(typeof r=="number")return r;if(to(r))return Ft;if(wn(r)){var h=typeof r.valueOf=="function"?r.valueOf():r;r=wn(h)?h+"":h}if(typeof r!="string")return r===0?r:+r;r=_a(r);var y=Dh.test(r);return y||_s.test(r)?da(r.slice(2),y?2:8):Ih.test(r)?Ft:+r}function Pp(r){return In(r,Ur(r))}function Py(r){return r?ls(wi(r),-ce,ce):r===0?r:0}function Zi(r){return r==null?"":Ye(r)}var Ly=Fo(function(r,h){if(nu(h)||Fr(h)){In(h,Jn(h),r);return}for(var y in h)Ti.call(h,y)&&Ra(r,y,h[y])}),Lp=Fo(function(r,h){In(h,Ur(h),r)}),Qu=Fo(function(r,h,y,D){In(h,Ur(h),r,D)}),Ry=Fo(function(r,h,y,D){In(h,Jn(h),r,D)}),Oy=Ws(Jh);function Iy(r,h){var y=ss(r);return h==null?y:Yh(y,h)}var Dy=ae(function(r,h){r=Ee(r);var y=-1,D=h.length,Y=D>2?h[2]:o;for(Y&&Mr(h[0],h[1],Y)&&(D=1);++y<D;)for(var ut=h[y],yt=Ur(ut),bt=-1,Bt=yt.length;++bt<Bt;){var oe=yt[bt],le=r[oe];(le===o||Uo(le,vo[oe])&&!Ti.call(r,oe))&&(r[oe]=ut[oe])}return r}),zy=ae(function(r){return r.push(o,qd),yr(Rp,o,r)});function ky(r,h){return Ss(r,si(h,3),Nr)}function By(r,h){return Ss(r,si(h,3),hh)}function Ny(r,h){return r==null?r:Ml(r,si(h,3),Ur)}function Fy(r,h){return r==null?r:lh(r,si(h,3),Ur)}function Uy(r,h){return r&&Nr(r,si(h,3))}function Gy(r,h){return r&&hh(r,si(h,3))}function Hy(r){return r==null?[]:Gs(r,Jn(r))}function Vy(r){return r==null?[]:Gs(r,Ur(r))}function df(r,h,y){var D=r==null?o:hs(r,h);return D===o?y:D}function Wy(r,h){return r!=null&&Jd(r,h,ch)}function pf(r,h){return r!=null&&Jd(r,h,$h)}var jy=ve(function(r,h,y){h!=null&&typeof h.toString!="function"&&(h=cr.call(h)),r[h]=y},gf(Gr)),Xy=ve(function(r,h,y){h!=null&&typeof h.toString!="function"&&(h=cr.call(h)),Ti.call(r,h)?r[h].push(y):r[h]=[y]},si),qy=ae(e);function Jn(r){return Fr(r)?zu(r):q(r)}function Ur(r){return Fr(r)?zu(r,!0):J(r)}function Yy(r,h){var y={};return h=si(h,3),Nr(r,function(D,Y,ut){Bo(y,h(D,Y,ut),D)}),y}function Zy(r,h){var y={};return h=si(h,3),Nr(r,function(D,Y,ut){Bo(y,Y,h(D,Y,ut))}),y}var Jy=Fo(function(r,h,y){wt(r,h,y)}),Rp=Fo(function(r,h,y,D){wt(r,h,y,D)}),$y=Ws(function(r,h){var y={};if(r==null)return y;var D=!1;h=Yi(h,function(ut){return ut=Je(ut,r),D||(D=ut.length>1),ut}),In(r,Kc(r),y),D&&(y=wr(y,O|k|I,jg));for(var Y=h.length;Y--;)Wi(y,h[Y]);return y});function Ky(r,h){return Op(r,Ju(si(h)))}var Qy=Ws(function(r,h){return r==null?{}:kt(r,h)});function Op(r,h){if(r==null)return{};var y=Yi(Kc(r),function(D){return[D]});return h=si(h),ee(r,y,function(D,Y){return h(D,Y[0])})}function t_(r,h,y){h=Je(h,r);var D=-1,Y=h.length;for(Y||(Y=1,r=o);++D<Y;){var ut=r==null?o:r[cs(h[D])];ut===o&&(D=Y,ut=y),r=Xs(ut)?ut.call(r):ut}return r}function e_(r,h,y){return r==null?r:fi(r,h,y)}function i_(r,h,y,D){return D=typeof D=="function"?D:o,r==null?r:fi(r,h,y,D)}var Ip=Hu(Jn),Dp=Hu(Ur);function n_(r,h,y){var D=vi(r),Y=D||Ba(r)||mh(r);if(h=si(h,4),y==null){var ut=r&&r.constructor;Y?y=D?new ut:[]:wn(r)?y=Xs(ut)?ss(_o(r)):{}:y={}}return(Y?Ji:Nr)(r,function(yt,bt,Bt){return h(y,yt,bt,Bt)}),y}function r_(r,h){return r==null?!0:Wi(r,h)}function o_(r,h,y){return r==null?r:Ae(r,h,ii(y))}function s_(r,h,y,D){return D=typeof D=="function"?D:o,r==null?r:Ae(r,h,ii(y),D)}function gh(r){return r==null?[]:bs(r,Jn(r))}function a_(r){return r==null?[]:bs(r,Ur(r))}function l_(r,h,y){return y===o&&(y=h,h=o),y!==o&&(y=Co(y),y=y===y?y:0),h!==o&&(h=Co(h),h=h===h?h:0),ls(Co(r),h,y)}function h_(r,h,y){return h=qs(h),y===o?(y=h,h=0):y=qs(y),r=Co(r),fh(r,h,y)}function u_(r,h,y){if(y&&typeof y!="boolean"&&Mr(r,h,y)&&(h=y=o),y===o&&(typeof h=="boolean"?(y=h,h=o):typeof r=="boolean"&&(y=r,r=o)),r===o&&h===o?(r=0,h=1):(r=qs(r),h===o?(h=r,r=0):h=qs(h)),r>h){var D=r;r=h,h=D}if(y||r%1||h%1){var Y=rh();return Vn(r+Y*(h-r+il("1e-"+((Y+"").length-1))),h)}return ge(r,h)}var c_=ze(function(r,h,y){return h=h.toLowerCase(),r+(y?zp(h):h)});function zp(r){return mf(Zi(r).toLowerCase())}function kp(r){return r=Zi(r),r&&r.replace(ql,As).replace(zh,"")}function f_(r,h,y){r=Zi(r),h=Ye(h);var D=r.length;y=y===o?D:ls(wi(y),0,D);var Y=y;return y-=h.length,y>=0&&r.slice(y,Y)==h}function d_(r){return r=Zi(r),r&&ao.test(r)?r.replace(zi,Jr):r}function p_(r){return r=Zi(r),r&&Vl.test(r)?r.replace(Za,"\\$&"):r}var m_=ze(function(r,h,y){return r+(y?"-":"")+h.toLowerCase()}),g_=ze(function(r,h,y){return r+(y?" ":"")+h.toLowerCase()}),v_=Me("toLowerCase");function y_(r,h,y){r=Zi(r),h=wi(h);var D=h?$r(r):0;if(!h||D>=h)return r;var Y=(h-D)/2;return an(ks(Y),y)+r+an(Do(Y),y)}function __(r,h,y){r=Zi(r),h=wi(h);var D=h?$r(r):0;return h&&D<h?r+an(h-D,y):r}function x_(r,h,y){r=Zi(r),h=wi(h);var D=h?$r(r):0;return h&&D<h?an(h-D,y)+r:r}function w_(r,h,y){return y||h==null?h=0:h&&(h=+h),Gh(Zi(r).replace(lo,""),h||0)}function T_(r,h,y){return(y?Mr(r,h,y):h===o)?h=1:h=wi(h),be(Zi(r),h)}function M_(){var r=arguments,h=Zi(r[0]);return r.length<3?h:h.replace(r[1],r[2])}var S_=ze(function(r,h,y){return r+(y?"_":"")+h.toLowerCase()});function E_(r,h,y){return y&&typeof y!="number"&&Mr(r,h,y)&&(h=y=o),y=y===o?It:y>>>0,y?(r=Zi(r),r&&(typeof h=="string"||h!=null&&!ff(h))&&(h=Ye(h),!h&&Ir(r))?xn(ar(r),0,y):r.split(h,y)):[]}var b_=ze(function(r,h,y){return r+(y?" ":"")+mf(h)});function C_(r,h,y){return r=Zi(r),y=y==null?0:ls(wi(y),0,r.length),h=Ye(h),r.slice(y,y+h.length)==h}function A_(r,h,y){var D=it.templateSettings;y&&Mr(r,h,y)&&(h=o),r=Zi(r),h=Qu({},h,D,Xd);var Y=Qu({},h.imports,D.imports,Xd),ut=Jn(Y),yt=bs(Y,ut),bt,Bt,oe=0,le=h.interpolate||Yr,de="__p += '",ke=Kn((h.escape||Yr).source+"|"+le.source+"|"+(le===ra?uo:Yr).source+"|"+(h.evaluate||Yr).source+"|$","g"),Ze="//# sourceURL="+(Ti.call(h,"sourceURL")?(h.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++ca+"]")+`
|
|
2619
|
+
`)}function t0(r){return vi(r)||Al(r)||!!(Ma&&r&&r[Ma])}function js(r,h){var y=typeof r;return h=h??ce,!!h&&(y=="number"||y!="symbol"&&Xl.test(r))&&r>-1&&r%1==0&&r<h}function Mr(r,h,y){if(!wn(y))return!1;var D=typeof h;return(D=="number"?Fr(y)&&js(h,y.length):D=="string"&&h in y)?Uo(y[h],r):!1}function nf(r,h){if(vi(r))return!1;var y=typeof r;return y=="number"||y=="symbol"||y=="boolean"||r==null||to(r)?!0:vr.test(r)||!vs.test(r)||h!=null&&r in Ee(h)}function e0(r){var h=typeof r;return h=="string"||h=="number"||h=="symbol"||h=="boolean"?r!=="__proto__":r===null}function rf(r){var h=Vu(r),y=it[h];if(typeof y!="function"||!(h in _i.prototype))return!1;if(r===y)return!0;var D=Qc(y);return!!D&&r===D[0]}function i0(r){return!!zr&&zr in r}var n0=ns?Xs:wf;function nu(r){var h=r&&r.constructor,y=typeof h=="function"&&h.prototype||vo;return r===y}function Kd(r){return r===r&&!wn(r)}function Qd(r,h){return function(y){return y==null?!1:y[r]===h&&(h!==o||r in Ee(y))}}function r0(r){var h=Zu(r,function(D){return y.size===S&&y.clear(),D}),y=h.cache;return h}function o0(r,h){var y=r[1],D=h[1],Y=y|D,ut=Y<(P|w|X),yt=D==X&&y==R||D==X&&y==J&&r[7].length<=h[8]||D==(X|J)&&h[7].length<=h[8]&&y==R;if(!(ut||yt))return r;D&P&&(r[2]=h[2],Y|=y&P?0:M);var bt=h[3];if(bt){var Bt=r[3];r[3]=Bt?Qh(Bt,bt,h[4]):bt,r[4]=Bt?Dr(r[3],b):h[4]}return bt=h[5],bt&&(Bt=r[5],r[5]=Bt?tu(Bt,bt,h[6]):bt,r[6]=Bt?Dr(r[5],b):h[6]),bt=h[7],bt&&(r[7]=bt),D&X&&(r[8]=r[8]==null?h[8]:Vn(r[8],h[8])),r[9]==null&&(r[9]=h[9]),r[0]=h[0],r[1]=Y,r}function s0(r){var h=[];if(r!=null)for(var y in Ee(r))h.push(y);return h}function a0(r){return cr.call(r)}function tp(r,h,y){return h=vn(h===o?r.length-1:h,0),function(){for(var D=arguments,Y=-1,ut=vn(D.length-h,0),yt=Zt(ut);++Y<ut;)yt[Y]=D[h+Y];Y=-1;for(var bt=Zt(h+1);++Y<h;)bt[Y]=D[Y];return bt[h]=y(yt),yr(r,this,bt)}}function ep(r,h){return h.length<2?r:hs(r,Vi(h,0,-1))}function l0(r,h){for(var y=r.length,D=Vn(h.length,y),Y=er(r);D--;){var ut=h[D];r[D]=js(ut,y)?Y[ut]:o}return r}function of(r,h){if(!(h==="constructor"&&typeof r[h]=="function")&&h!="__proto__")return r[h]}var ip=rp(Cn),ru=Nh||function(r,h){return gn.setTimeout(r,h)},sf=rp(_n);function np(r,h,y){var D=h+"";return sf(r,Qg(D,h0(Jg(D),y)))}function rp(r){var h=0,y=0;return function(){var D=cl(),Y=_t-(D-y);if(y=D,Y>0){if(++h>=tt)return arguments[0]}else h=0;return r.apply(o,arguments)}}function ju(r,h){var y=-1,D=r.length,Y=D-1;for(h=h===o?D:h;++y<h;){var ut=ge(y,Y),yt=r[ut];r[ut]=r[y],r[y]=yt}return r.length=h,r}var op=r0(function(r){var h=[];return r.charCodeAt(0)===46&&h.push(""),r.replace(oa,function(y,D,Y,ut){h.push(Y?ut.replace(la,"$1"):D||y)}),h});function cs(r){if(typeof r=="string"||to(r))return r;var h=r+"";return h=="0"&&1/r==-At?"-0":h}function Cl(r){if(r!=null){try{return hr.call(r)}catch{}try{return r+""}catch{}}return""}function h0(r,h){return Ji(pe,function(y){var D="_."+y[0];h&y[1]&&!nl(r,D)&&r.push(D)}),r.sort()}function sp(r){if(r instanceof _i)return r.clone();var h=new qn(r.__wrapped__,r.__chain__);return h.__actions__=er(r.__actions__),h.__index__=r.__index__,h.__values__=r.__values__,h}function u0(r,h,y){(y?Mr(r,h,y):h===o)?h=1:h=vn(wi(h),0);var D=r==null?0:r.length;if(!D||h<1)return[];for(var Y=0,ut=0,yt=Zt(Do(D/h));Y<D;)yt[ut++]=Vi(r,Y,Y+=h);return yt}function c0(r){for(var h=-1,y=r==null?0:r.length,D=0,Y=[];++h<y;){var ut=r[h];ut&&(Y[D++]=ut)}return Y}function f0(){var r=arguments.length;if(!r)return[];for(var h=Zt(r-1),y=arguments[0],D=r;D--;)h[D-1]=arguments[D];return fo(vi(y)?er(y):[y],bn(h,1))}var d0=ae(function(r,h){return Dn(r)?Tl(r,bn(h,1,Dn,!0)):[]}),p0=ae(function(r,h){var y=bo(h);return Dn(y)&&(y=o),Dn(r)?Tl(r,bn(h,1,Dn,!0),si(y,2)):[]}),m0=ae(function(r,h){var y=bo(h);return Dn(y)&&(y=o),Dn(r)?Tl(r,bn(h,1,Dn,!0),o,y):[]});function g0(r,h,y){var D=r==null?0:r.length;return D?(h=y||h===o?1:wi(h),Vi(r,h<0?0:h,D)):[]}function v0(r,h,y){var D=r==null?0:r.length;return D?(h=y||h===o?1:wi(h),h=D-h,Vi(r,0,h<0?0:h)):[]}function y0(r,h){return r&&r.length?Xe(r,si(h,3),!0,!0):[]}function _0(r,h){return r&&r.length?Xe(r,si(h,3),!0):[]}function x0(r,h,y,D){var Y=r==null?0:r.length;return Y?(y&&typeof y!="number"&&Mr(r,h,y)&&(y=0,D=Y),tr(r,h,y,D)):[]}function ap(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=y==null?0:wi(y);return Y<0&&(Y=vn(D+Y,0)),$o(r,si(h,3),Y)}function lp(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=D-1;return y!==o&&(Y=wi(y),Y=y<0?vn(D+Y,0):Vn(Y,D-1)),$o(r,si(h,3),Y,!0)}function hp(r){var h=r==null?0:r.length;return h?bn(r,1):[]}function w0(r){var h=r==null?0:r.length;return h?bn(r,At):[]}function T0(r,h){var y=r==null?0:r.length;return y?(h=h===o?1:wi(h),bn(r,h)):[]}function M0(r){for(var h=-1,y=r==null?0:r.length,D={};++h<y;){var Y=r[h];D[Y[0]]=Y[1]}return D}function up(r){return r&&r.length?r[0]:o}function S0(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=y==null?0:wi(y);return Y<0&&(Y=vn(D+Y,0)),Or(r,h,Y)}function E0(r){var h=r==null?0:r.length;return h?Vi(r,0,-1):[]}var b0=ae(function(r){var h=Yi(r,ne);return h.length&&h[0]===r[0]?Sl(h):[]}),C0=ae(function(r){var h=bo(r),y=Yi(r,ne);return h===bo(y)?h=o:y.pop(),y.length&&y[0]===r[0]?Sl(y,si(h,2)):[]}),A0=ae(function(r){var h=bo(r),y=Yi(r,ne);return h=typeof h=="function"?h:o,h&&y.pop(),y.length&&y[0]===r[0]?Sl(y,o,h):[]});function P0(r,h){return r==null?"":Uh.call(r,h)}function bo(r){var h=r==null?0:r.length;return h?r[h-1]:o}function L0(r,h,y){var D=r==null?0:r.length;if(!D)return-1;var Y=D;return y!==o&&(Y=wi(y),Y=Y<0?vn(D+Y,0):Vn(Y,D-1)),h===h?Ql(r,h,Y):$o(r,Es,Y,!0)}function R0(r,h){return r&&r.length?K(r,wi(h)):o}var O0=ae(cp);function cp(r,h){return r&&r.length&&h&&h.length?Yt(r,h):r}function I0(r,h,y){return r&&r.length&&h&&h.length?Yt(r,h,si(y,2)):r}function D0(r,h,y){return r&&r.length&&h&&h.length?Yt(r,h,o,y):r}var z0=Ws(function(r,h){var y=r==null?0:r.length,D=Jh(r,h);return Te(r,Yi(h,function(Y){return js(Y,y)?+Y:Y}).sort(Vs)),D});function k0(r,h){var y=[];if(!(r&&r.length))return y;var D=-1,Y=[],ut=r.length;for(h=si(h,3);++D<ut;){var yt=r[D];h(yt,D,r)&&(y.push(yt),Y.push(D))}return Te(r,Y),y}function af(r){return r==null?r:Sa.call(r)}function B0(r,h,y){var D=r==null?0:r.length;return D?(y&&typeof y!="number"&&Mr(r,h,y)?(h=0,y=D):(h=h==null?0:wi(h),y=y===o?D:wi(y)),Vi(r,h,y)):[]}function N0(r,h){return An(r,h)}function F0(r,h,y){return Ce(r,h,si(y,2))}function U0(r,h){var y=r==null?0:r.length;if(y){var D=An(r,h);if(D<y&&Uo(r[D],h))return D}return-1}function G0(r,h){return An(r,h,!0)}function H0(r,h,y){return Ce(r,h,si(y,2),!0)}function V0(r,h){var y=r==null?0:r.length;if(y){var D=An(r,h,!0)-1;if(Uo(r[D],h))return D}return-1}function W0(r){return r&&r.length?ti(r):[]}function j0(r,h){return r&&r.length?ti(r,si(h,2)):[]}function X0(r){var h=r==null?0:r.length;return h?Vi(r,1,h):[]}function q0(r,h,y){return r&&r.length?(h=y||h===o?1:wi(h),Vi(r,0,h<0?0:h)):[]}function Y0(r,h,y){var D=r==null?0:r.length;return D?(h=y||h===o?1:wi(h),h=D-h,Vi(r,h<0?0:h,D)):[]}function Z0(r,h){return r&&r.length?Xe(r,si(h,3),!1,!0):[]}function J0(r,h){return r&&r.length?Xe(r,si(h,3)):[]}var $0=ae(function(r){return ei(bn(r,1,Dn,!0))}),K0=ae(function(r){var h=bo(r);return Dn(h)&&(h=o),ei(bn(r,1,Dn,!0),si(h,2))}),Q0=ae(function(r){var h=bo(r);return h=typeof h=="function"?h:o,ei(bn(r,1,Dn,!0),o,h)});function tv(r){return r&&r.length?ei(r):[]}function ev(r,h){return r&&r.length?ei(r,si(h,2)):[]}function iv(r,h){return h=typeof h=="function"?h:o,r&&r.length?ei(r,o,h):[]}function lf(r){if(!(r&&r.length))return[];var h=0;return r=Rr(r,function(y){if(Dn(y))return h=vn(y.length,h),!0}),Ro(h,function(y){return Yi(r,Ko(y))})}function fp(r,h){if(!(r&&r.length))return[];var y=lf(r);return h==null?y:Yi(y,function(D){return yr(h,o,D)})}var nv=ae(function(r,h){return Dn(r)?Tl(r,h):[]}),rv=ae(function(r){return Li(Rr(r,Dn))}),ov=ae(function(r){var h=bo(r);return Dn(h)&&(h=o),Li(Rr(r,Dn),si(h,2))}),sv=ae(function(r){var h=bo(r);return h=typeof h=="function"?h:o,Li(Rr(r,Dn),o,h)}),av=ae(lf);function lv(r,h){return Ai(r||[],h||[],Ra)}function hv(r,h){return Ai(r||[],h||[],fi)}var uv=ae(function(r){var h=r.length,y=h>1?r[h-1]:o;return y=typeof y=="function"?(r.pop(),y):o,fp(r,y)});function dp(r){var h=it(r);return h.__chain__=!0,h}function cv(r,h){return h(r),r}function Xu(r,h){return h(r)}var fv=Ws(function(r){var h=r.length,y=h?r[0]:0,D=this.__wrapped__,Y=function(ut){return Jh(ut,r)};return h>1||this.__actions__.length||!(D instanceof _i)||!js(y)?this.thru(Y):(D=D.slice(y,+y+(h?1:0)),D.__actions__.push({func:Xu,args:[Y],thisArg:o}),new qn(D,this.__chain__).thru(function(ut){return h&&!ut.length&&ut.push(o),ut}))});function dv(){return dp(this)}function pv(){return new qn(this.value(),this.__chain__)}function mv(){this.__values__===o&&(this.__values__=Cp(this.value()));var r=this.__index__>=this.__values__.length,h=r?o:this.__values__[this.__index__++];return{done:r,value:h}}function gv(){return this}function vv(r){for(var h,y=this;y instanceof ba;){var D=sp(y);D.__index__=0,D.__values__=o,h?Y.__wrapped__=D:h=D;var Y=D;y=y.__wrapped__}return Y.__wrapped__=r,h}function yv(){var r=this.__wrapped__;if(r instanceof _i){var h=r;return this.__actions__.length&&(h=new _i(this)),h=h.reverse(),h.__actions__.push({func:Xu,args:[af],thisArg:o}),new qn(h,this.__chain__)}return this.thru(af)}function _v(){return ri(this.__wrapped__,this.__actions__)}var xv=za(function(r,h,y){Ti.call(r,y)?++r[y]:Bo(r,y,1)});function wv(r,h,y){var D=vi(r)?Bh:Yn;return y&&Mr(r,h,y)&&(h=o),D(r,si(h,3))}function Tv(r,h){var y=vi(r)?Rr:Br;return y(r,si(h,3))}var Mv=Ke(ap),Sv=Ke(lp);function Ev(r,h){return bn(qu(r,h),1)}function bv(r,h){return bn(qu(r,h),At)}function Cv(r,h,y){return y=y===o?1:wi(y),bn(qu(r,h),y)}function pp(r,h){var y=vi(r)?Ji:yn;return y(r,si(h,3))}function mp(r,h){var y=vi(r)?Ms:Fu;return y(r,si(h,3))}var Av=za(function(r,h,y){Ti.call(r,y)?r[y].push(h):Bo(r,y,[h])});function Pv(r,h,y,D){r=Fr(r)?r:gh(r),y=y&&!D?wi(y):0;var Y=r.length;return y<0&&(y=vn(Y+y,0)),Ku(r)?y<=Y&&r.indexOf(h,y)>-1:!!Y&&Or(r,h,y)>-1}var Lv=ae(function(r,h,y){var D=-1,Y=typeof h=="function",ut=Fr(r)?Zt(r.length):[];return yn(r,function(yt){ut[++D]=Y?yr(h,yt,y):e(yt,h,y)}),ut}),Rv=za(function(r,h,y){Bo(r,y,h)});function qu(r,h){var y=vi(r)?Yi:xt;return y(r,si(h,3))}function Ov(r,h,y,D){return r==null?[]:(vi(h)||(h=h==null?[]:[h]),y=D?o:y,vi(y)||(y=y==null?[]:[y]),ot(r,h,y))}var Iv=za(function(r,h,y){r[y?0:1].push(h)},function(){return[[],[]]});function Dv(r,h,y){var D=vi(r)?$l:Qo,Y=arguments.length<3;return D(r,si(h,4),y,Y,yn)}function zv(r,h,y){var D=vi(r)?bu:Qo,Y=arguments.length<3;return D(r,si(h,4),y,Y,Fu)}function kv(r,h){var y=vi(r)?Rr:Br;return y(r,Ju(si(h,3)))}function Bv(r){var h=vi(r)?qh:We;return h(r)}function Nv(r,h,y){(y?Mr(r,h,y):h===o)?h=1:h=wi(h);var D=vi(r)?Jc:Qe;return D(r,h)}function Fv(r){var h=vi(r)?ku:qi;return h(r)}function Uv(r){if(r==null)return 0;if(Fr(r))return Ku(r)?$r(r):r.length;var h=mr(r);return h==W||h==Kt?r.size:q(r).length}function Gv(r,h,y){var D=vi(r)?Po:on;return y&&Mr(r,h,y)&&(h=o),D(r,si(h,3))}var Hv=ae(function(r,h){if(r==null)return[];var y=h.length;return y>1&&Mr(r,h[0],h[1])?h=[]:y>2&&Mr(h[0],h[1],h[2])&&(h=[h[0]]),ot(r,bn(h,1),[])}),Yu=ih||function(){return gn.Date.now()};function Vv(r,h){if(typeof h!="function")throw new lr(m);return r=wi(r),function(){if(--r<1)return h.apply(this,arguments)}}function gp(r,h,y){return h=y?o:h,h=r&&h==null?r.length:h,ir(r,X,o,o,o,o,h)}function vp(r,h){var y;if(typeof h!="function")throw new lr(m);return r=wi(r),function(){return--r>0&&(y=h.apply(this,arguments)),r<=1&&(h=o),y}}var hf=ae(function(r,h,y){var D=P;if(y.length){var Y=Dr(y,ph(hf));D|=U}return ir(r,D,h,y,Y)}),yp=ae(function(r,h,y){var D=P|w;if(y.length){var Y=Dr(y,ph(yp));D|=U}return ir(h,D,r,y,Y)});function _p(r,h,y){h=y?o:h;var D=ir(r,R,o,o,o,o,o,h);return D.placeholder=_p.placeholder,D}function xp(r,h,y){h=y?o:h;var D=ir(r,C,o,o,o,o,o,h);return D.placeholder=xp.placeholder,D}function wp(r,h,y){var D,Y,ut,yt,bt,Bt,oe=0,le=!1,de=!1,ke=!0;if(typeof r!="function")throw new lr(m);h=Co(h)||0,wn(y)&&(le=!!y.leading,de="maxWait"in y,ut=de?vn(Co(y.maxWait)||0,h):ut,ke="trailing"in y?!!y.trailing:ke);function Ze(zn){var Go=D,Ys=Y;return D=Y=o,oe=zn,yt=r.apply(Ys,Go),yt}function hi(zn){return oe=zn,bt=ru(Ri,h),le?Ze(zn):yt}function Mi(zn){var Go=zn-Bt,Ys=zn-oe,Up=h-Go;return de?Vn(Up,ut-Ys):Up}function ui(zn){var Go=zn-Bt,Ys=zn-oe;return Bt===o||Go>=h||Go<0||de&&Ys>=ut}function Ri(){var zn=Yu();if(ui(zn))return Ui(zn);bt=ru(Ri,Mi(zn))}function Ui(zn){return bt=o,ke&&D?Ze(zn):(D=Y=o,yt)}function eo(){bt!==o&&Pn(bt),oe=0,D=Bt=Y=bt=o}function Sr(){return bt===o?yt:Ui(Yu())}function io(){var zn=Yu(),Go=ui(zn);if(D=arguments,Y=this,Bt=zn,Go){if(bt===o)return hi(Bt);if(de)return Pn(bt),bt=ru(Ri,h),Ze(Bt)}return bt===o&&(bt=ru(Ri,h)),yt}return io.cancel=eo,io.flush=Sr,io}var Wv=ae(function(r,h){return To(r,1,h)}),jv=ae(function(r,h,y){return To(r,Co(h)||0,y)});function Xv(r){return ir(r,Z)}function Zu(r,h){if(typeof r!="function"||h!=null&&typeof h!="function")throw new lr(m);var y=function(){var D=arguments,Y=h?h.apply(this,D):D[0],ut=y.cache;if(ut.has(Y))return ut.get(Y);var yt=r.apply(this,D);return y.cache=ut.set(Y,yt)||ut,yt};return y.cache=new(Zu.Cache||xr),y}Zu.Cache=xr;function Ju(r){if(typeof r!="function")throw new lr(m);return function(){var h=arguments;switch(h.length){case 0:return!r.call(this);case 1:return!r.call(this,h[0]);case 2:return!r.call(this,h[0],h[1]);case 3:return!r.call(this,h[0],h[1],h[2])}return!r.apply(this,h)}}function qv(r){return vp(2,r)}var Yv=li(function(r,h){h=h.length==1&&vi(h[0])?Yi(h[0],Gn(si())):Yi(bn(h,1),Gn(si()));var y=h.length;return ae(function(D){for(var Y=-1,ut=Vn(D.length,y);++Y<ut;)D[Y]=h[Y].call(this,D[Y]);return yr(r,this,D)})}),uf=ae(function(r,h){var y=Dr(h,ph(uf));return ir(r,U,o,h,y)}),Tp=ae(function(r,h){var y=Dr(h,ph(Tp));return ir(r,N,o,h,y)}),Zv=Ws(function(r,h){return ir(r,J,o,o,o,h)});function Jv(r,h){if(typeof r!="function")throw new lr(m);return h=h===o?h:wi(h),ae(r,h)}function $v(r,h){if(typeof r!="function")throw new lr(m);return h=h==null?0:vn(wi(h),0),ae(function(y){var D=y[h],Y=xn(y,0,h);return D&&fo(Y,D),yr(r,this,Y)})}function Kv(r,h,y){var D=!0,Y=!0;if(typeof r!="function")throw new lr(m);return wn(y)&&(D="leading"in y?!!y.leading:D,Y="trailing"in y?!!y.trailing:Y),wp(r,h,{leading:D,maxWait:h,trailing:Y})}function Qv(r){return gp(r,1)}function ty(r,h){return uf(ii(h),r)}function ey(){if(!arguments.length)return[];var r=arguments[0];return vi(r)?r:[r]}function iy(r){return wr(r,I)}function ny(r,h){return h=typeof h=="function"?h:o,wr(r,I,h)}function ry(r){return wr(r,O|I)}function oy(r,h){return h=typeof h=="function"?h:o,wr(r,O|I,h)}function sy(r,h){return h==null||Nu(r,h,Jn(h))}function Uo(r,h){return r===h||r!==r&&h!==h}var ay=Eo(uh),ly=Eo(function(r,h){return r>=h}),Al=i(function(){return arguments}())?i:function(r){return Ln(r)&&Ti.call(r,"callee")&&!hl.call(r,"callee")},vi=Zt.isArray,hy=kh?Gn(kh):n;function Fr(r){return r!=null&&$u(r.length)&&!Xs(r)}function Dn(r){return Ln(r)&&Fr(r)}function uy(r){return r===!0||r===!1||Ln(r)&&Zn(r)==Oe}var Ba=Fh||wf,cy=ga?Gn(ga):s;function fy(r){return Ln(r)&&r.nodeType===1&&!ou(r)}function dy(r){if(r==null)return!0;if(Fr(r)&&(vi(r)||typeof r=="string"||typeof r.splice=="function"||Ba(r)||mh(r)||Al(r)))return!r.length;var h=mr(r);if(h==W||h==Kt)return!r.size;if(nu(r))return!q(r).length;for(var y in r)if(Ti.call(r,y))return!1;return!0}function py(r,h){return l(r,h)}function my(r,h,y){y=typeof y=="function"?y:o;var D=y?y(r,h):o;return D===o?l(r,h,o,y):!!D}function cf(r){if(!Ln(r))return!1;var h=Zn(r);return h==Di||h==pi||typeof r.message=="string"&&typeof r.name=="string"&&!ou(r)}function gy(r){return typeof r=="number"&&nh(r)}function Xs(r){if(!wn(r))return!1;var h=Zn(r);return h==mn||h==Qi||h==Si||h==Dt}function Mp(r){return typeof r=="number"&&r==wi(r)}function $u(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=ce}function wn(r){var h=typeof r;return r!=null&&(h=="object"||h=="function")}function Ln(r){return r!=null&&typeof r=="object"}var Sp=va?Gn(va):p;function vy(r,h){return r===h||_(r,h,tf(h))}function yy(r,h,y){return y=typeof y=="function"?y:o,_(r,h,tf(h),y)}function _y(r){return Ep(r)&&r!=+r}function xy(r){if(n0(r))throw new ai(u);return T(r)}function wy(r){return r===null}function Ty(r){return r==null}function Ep(r){return typeof r=="number"||Ln(r)&&Zn(r)==Jt}function ou(r){if(!Ln(r)||Zn(r)!=dt)return!1;var h=_o(r);if(h===null)return!0;var y=Ti.call(h,"constructor")&&h.constructor;return typeof y=="function"&&y instanceof y&&hr.call(y)==yo}var ff=Su?Gn(Su):A;function My(r){return Mp(r)&&r>=-ce&&r<=ce}var bp=Eu?Gn(Eu):L;function Ku(r){return typeof r=="string"||!vi(r)&&Ln(r)&&Zn(r)==z}function to(r){return typeof r=="symbol"||Ln(r)&&Zn(r)==Q}var mh=Yl?Gn(Yl):B;function Sy(r){return r===o}function Ey(r){return Ln(r)&&mr(r)==nt}function by(r){return Ln(r)&&Zn(r)==vt}var Cy=Eo(rt),Ay=Eo(function(r,h){return r<=h});function Cp(r){if(!r)return[];if(Fr(r))return Ku(r)?ar(r):er(r);if(rs&&r[rs])return Os(r[rs]());var h=mr(r),y=h==W?$n:h==Kt?Is:gh;return y(r)}function qs(r){if(!r)return r===0?r:0;if(r=Co(r),r===At||r===-At){var h=r<0?-1:1;return h*re}return r===r?r:0}function wi(r){var h=qs(r),y=h%1;return h===h?y?h-y:h:0}function Ap(r){return r?ls(wi(r),0,It):0}function Co(r){if(typeof r=="number")return r;if(to(r))return Ft;if(wn(r)){var h=typeof r.valueOf=="function"?r.valueOf():r;r=wn(h)?h+"":h}if(typeof r!="string")return r===0?r:+r;r=_a(r);var y=Dh.test(r);return y||_s.test(r)?da(r.slice(2),y?2:8):Ih.test(r)?Ft:+r}function Pp(r){return In(r,Ur(r))}function Py(r){return r?ls(wi(r),-ce,ce):r===0?r:0}function Zi(r){return r==null?"":Ye(r)}var Ly=Fo(function(r,h){if(nu(h)||Fr(h)){In(h,Jn(h),r);return}for(var y in h)Ti.call(h,y)&&Ra(r,y,h[y])}),Lp=Fo(function(r,h){In(h,Ur(h),r)}),Qu=Fo(function(r,h,y,D){In(h,Ur(h),r,D)}),Ry=Fo(function(r,h,y,D){In(h,Jn(h),r,D)}),Oy=Ws(Jh);function Iy(r,h){var y=ss(r);return h==null?y:Yh(y,h)}var Dy=ae(function(r,h){r=Ee(r);var y=-1,D=h.length,Y=D>2?h[2]:o;for(Y&&Mr(h[0],h[1],Y)&&(D=1);++y<D;)for(var ut=h[y],yt=Ur(ut),bt=-1,Bt=yt.length;++bt<Bt;){var oe=yt[bt],le=r[oe];(le===o||Uo(le,vo[oe])&&!Ti.call(r,oe))&&(r[oe]=ut[oe])}return r}),zy=ae(function(r){return r.push(o,qd),yr(Rp,o,r)});function ky(r,h){return Ss(r,si(h,3),Nr)}function By(r,h){return Ss(r,si(h,3),hh)}function Ny(r,h){return r==null?r:Ml(r,si(h,3),Ur)}function Fy(r,h){return r==null?r:lh(r,si(h,3),Ur)}function Uy(r,h){return r&&Nr(r,si(h,3))}function Gy(r,h){return r&&hh(r,si(h,3))}function Hy(r){return r==null?[]:Gs(r,Jn(r))}function Vy(r){return r==null?[]:Gs(r,Ur(r))}function df(r,h,y){var D=r==null?o:hs(r,h);return D===o?y:D}function Wy(r,h){return r!=null&&Jd(r,h,ch)}function pf(r,h){return r!=null&&Jd(r,h,$h)}var jy=ve(function(r,h,y){h!=null&&typeof h.toString!="function"&&(h=cr.call(h)),r[h]=y},gf(Gr)),Xy=ve(function(r,h,y){h!=null&&typeof h.toString!="function"&&(h=cr.call(h)),Ti.call(r,h)?r[h].push(y):r[h]=[y]},si),qy=ae(e);function Jn(r){return Fr(r)?zu(r):q(r)}function Ur(r){return Fr(r)?zu(r,!0):$(r)}function Yy(r,h){var y={};return h=si(h,3),Nr(r,function(D,Y,ut){Bo(y,h(D,Y,ut),D)}),y}function Zy(r,h){var y={};return h=si(h,3),Nr(r,function(D,Y,ut){Bo(y,Y,h(D,Y,ut))}),y}var Jy=Fo(function(r,h,y){wt(r,h,y)}),Rp=Fo(function(r,h,y,D){wt(r,h,y,D)}),$y=Ws(function(r,h){var y={};if(r==null)return y;var D=!1;h=Yi(h,function(ut){return ut=Je(ut,r),D||(D=ut.length>1),ut}),In(r,Kc(r),y),D&&(y=wr(y,O|k|I,jg));for(var Y=h.length;Y--;)Wi(y,h[Y]);return y});function Ky(r,h){return Op(r,Ju(si(h)))}var Qy=Ws(function(r,h){return r==null?{}:kt(r,h)});function Op(r,h){if(r==null)return{};var y=Yi(Kc(r),function(D){return[D]});return h=si(h),ee(r,y,function(D,Y){return h(D,Y[0])})}function t_(r,h,y){h=Je(h,r);var D=-1,Y=h.length;for(Y||(Y=1,r=o);++D<Y;){var ut=r==null?o:r[cs(h[D])];ut===o&&(D=Y,ut=y),r=Xs(ut)?ut.call(r):ut}return r}function e_(r,h,y){return r==null?r:fi(r,h,y)}function i_(r,h,y,D){return D=typeof D=="function"?D:o,r==null?r:fi(r,h,y,D)}var Ip=Hu(Jn),Dp=Hu(Ur);function n_(r,h,y){var D=vi(r),Y=D||Ba(r)||mh(r);if(h=si(h,4),y==null){var ut=r&&r.constructor;Y?y=D?new ut:[]:wn(r)?y=Xs(ut)?ss(_o(r)):{}:y={}}return(Y?Ji:Nr)(r,function(yt,bt,Bt){return h(y,yt,bt,Bt)}),y}function r_(r,h){return r==null?!0:Wi(r,h)}function o_(r,h,y){return r==null?r:Ae(r,h,ii(y))}function s_(r,h,y,D){return D=typeof D=="function"?D:o,r==null?r:Ae(r,h,ii(y),D)}function gh(r){return r==null?[]:bs(r,Jn(r))}function a_(r){return r==null?[]:bs(r,Ur(r))}function l_(r,h,y){return y===o&&(y=h,h=o),y!==o&&(y=Co(y),y=y===y?y:0),h!==o&&(h=Co(h),h=h===h?h:0),ls(Co(r),h,y)}function h_(r,h,y){return h=qs(h),y===o?(y=h,h=0):y=qs(y),r=Co(r),fh(r,h,y)}function u_(r,h,y){if(y&&typeof y!="boolean"&&Mr(r,h,y)&&(h=y=o),y===o&&(typeof h=="boolean"?(y=h,h=o):typeof r=="boolean"&&(y=r,r=o)),r===o&&h===o?(r=0,h=1):(r=qs(r),h===o?(h=r,r=0):h=qs(h)),r>h){var D=r;r=h,h=D}if(y||r%1||h%1){var Y=rh();return Vn(r+Y*(h-r+il("1e-"+((Y+"").length-1))),h)}return ge(r,h)}var c_=ze(function(r,h,y){return h=h.toLowerCase(),r+(y?zp(h):h)});function zp(r){return mf(Zi(r).toLowerCase())}function kp(r){return r=Zi(r),r&&r.replace(ql,As).replace(zh,"")}function f_(r,h,y){r=Zi(r),h=Ye(h);var D=r.length;y=y===o?D:ls(wi(y),0,D);var Y=y;return y-=h.length,y>=0&&r.slice(y,Y)==h}function d_(r){return r=Zi(r),r&&ao.test(r)?r.replace(zi,Jr):r}function p_(r){return r=Zi(r),r&&Vl.test(r)?r.replace(Za,"\\$&"):r}var m_=ze(function(r,h,y){return r+(y?"-":"")+h.toLowerCase()}),g_=ze(function(r,h,y){return r+(y?" ":"")+h.toLowerCase()}),v_=Me("toLowerCase");function y_(r,h,y){r=Zi(r),h=wi(h);var D=h?$r(r):0;if(!h||D>=h)return r;var Y=(h-D)/2;return an(ks(Y),y)+r+an(Do(Y),y)}function __(r,h,y){r=Zi(r),h=wi(h);var D=h?$r(r):0;return h&&D<h?r+an(h-D,y):r}function x_(r,h,y){r=Zi(r),h=wi(h);var D=h?$r(r):0;return h&&D<h?an(h-D,y)+r:r}function w_(r,h,y){return y||h==null?h=0:h&&(h=+h),Gh(Zi(r).replace(lo,""),h||0)}function T_(r,h,y){return(y?Mr(r,h,y):h===o)?h=1:h=wi(h),be(Zi(r),h)}function M_(){var r=arguments,h=Zi(r[0]);return r.length<3?h:h.replace(r[1],r[2])}var S_=ze(function(r,h,y){return r+(y?"_":"")+h.toLowerCase()});function E_(r,h,y){return y&&typeof y!="number"&&Mr(r,h,y)&&(h=y=o),y=y===o?It:y>>>0,y?(r=Zi(r),r&&(typeof h=="string"||h!=null&&!ff(h))&&(h=Ye(h),!h&&Ir(r))?xn(ar(r),0,y):r.split(h,y)):[]}var b_=ze(function(r,h,y){return r+(y?" ":"")+mf(h)});function C_(r,h,y){return r=Zi(r),y=y==null?0:ls(wi(y),0,r.length),h=Ye(h),r.slice(y,y+h.length)==h}function A_(r,h,y){var D=it.templateSettings;y&&Mr(r,h,y)&&(h=o),r=Zi(r),h=Qu({},h,D,Xd);var Y=Qu({},h.imports,D.imports,Xd),ut=Jn(Y),yt=bs(Y,ut),bt,Bt,oe=0,le=h.interpolate||Yr,de="__p += '",ke=Kn((h.escape||Yr).source+"|"+le.source+"|"+(le===ra?uo:Yr).source+"|"+(h.evaluate||Yr).source+"|$","g"),Ze="//# sourceURL="+(Ti.call(h,"sourceURL")?(h.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++ca+"]")+`
|
|
2620
2620
|
`;r.replace(ke,function(ui,Ri,Ui,eo,Sr,io){return Ui||(Ui=eo),de+=r.slice(oe,io).replace(V,Ps),Ri&&(bt=!0,de+=`' +
|
|
2621
2621
|
__e(`+Ri+`) +
|
|
2622
2622
|
'`),Sr&&(Bt=!0,de+=`';
|
|
@@ -2633,7 +2633,7 @@ __p += '`),Ui&&(de+=`' +
|
|
|
2633
2633
|
function print() { __p += __j.call(arguments, '') }
|
|
2634
2634
|
`:`;
|
|
2635
2635
|
`)+de+`return __p
|
|
2636
|
-
}`;var Mi=Np(function(){return Fi(ut,Ze+"return "+de).apply(o,yt)});if(Mi.source=de,cf(Mi))throw Mi;return Mi}function P_(r){return Zi(r).toLowerCase()}function L_(r){return Zi(r).toUpperCase()}function R_(r,h,y){if(r=Zi(r),r&&(y||h===o))return _a(r);if(!r||!(h=Ye(h)))return r;var D=ar(r),Y=ar(h),ut=es(D,Y),yt=Cs(D,Y)+1;return xn(D,ut,yt).join("")}function O_(r,h,y){if(r=Zi(r),r&&(y||h===o))return r.slice(0,xa(r)+1);if(!r||!(h=Ye(h)))return r;var D=ar(r),Y=Cs(D,ar(h))+1;return xn(D,0,Y).join("")}function I_(r,h,y){if(r=Zi(r),r&&(y||h===o))return r.replace(lo,"");if(!r||!(h=Ye(h)))return r;var D=ar(r),Y=es(D,ar(h));return xn(D,Y).join("")}function D_(r,h){var y=ct,D=Rt;if(wn(h)){var Y="separator"in h?h.separator:Y;y="length"in h?wi(h.length):y,D="omission"in h?Ye(h.omission):D}r=Zi(r);var ut=r.length;if(Ir(r)){var yt=ar(r);ut=yt.length}if(y>=ut)return r;var bt=y-$r(D);if(bt<1)return D;var Bt=yt?xn(yt,0,bt).join(""):r.slice(0,bt);if(Y===o)return Bt+D;if(yt&&(bt+=Bt.length-bt),ff(Y)){if(r.slice(bt).search(Y)){var oe,le=Bt;for(Y.global||(Y=Kn(Y.source,Zi(jl.exec(Y))+"g")),Y.lastIndex=0;oe=Y.exec(le);)var de=oe.index;Bt=Bt.slice(0,de===o?bt:de)}}else if(r.indexOf(Ye(Y),bt)!=bt){var ke=Bt.lastIndexOf(Y);ke>-1&&(Bt=Bt.slice(0,ke))}return Bt+D}function z_(r){return r=Zi(r),r&&Yo.test(r)?r.replace(Ao,th):r}var k_=ze(function(r,h,y){return r+(y?" ":"")+h.toUpperCase()}),mf=Me("toUpperCase");function Bp(r,h,y){return r=Zi(r),h=y?o:h,h===o?Rs(r)?jc(r):rl(r):r.match(h)||[]}var Np=ae(function(r,h){try{return yr(r,o,h)}catch(y){return cf(y)?y:new ai(y)}}),B_=Ws(function(r,h){return Ji(h,function(y){y=cs(y),Bo(r,y,hf(r[y],r))}),r});function N_(r){var h=r==null?0:r.length,y=si();return r=h?Yi(r,function(D){if(typeof D[1]!="function")throw new lr(m);return[y(D[0]),D[1]]}):[],ae(function(D){for(var Y=-1;++Y<h;){var ut=r[Y];if(yr(ut[0],this,D))return yr(ut[1],this,D)}})}function F_(r){return Oa(wr(r,O))}function gf(r){return function(){return r}}function U_(r,h){return r==null||r!==r?h:r}var G_=Oi(),H_=Oi(!0);function Gr(r){return r}function vf(r){return H(typeof r=="function"?r:wr(r,O))}function V_(r){return gt(wr(r,O))}function W_(r,h){return Ct(r,wr(h,O))}var j_=ae(function(r,h){return function(y){return e(y,r,h)}}),X_=ae(function(r,h){return function(y){return e(r,y,h)}});function yf(r,h,y){var D=Jn(h),Y=Gs(h,D);y==null&&!(wn(h)&&(Y.length||!D.length))&&(y=h,h=r,r=this,Y=Gs(h,Jn(h)));var ut=!(wn(y)&&"chain"in y)||!!y.chain,yt=Xs(r);return Ji(Y,function(bt){var Bt=h[bt];r[bt]=Bt,yt&&(r.prototype[bt]=function(){var oe=this.__chain__;if(ut||oe){var le=r(this.__wrapped__),de=le.__actions__=er(this.__actions__);return de.push({func:Bt,args:arguments,thisArg:r}),le.__chain__=oe,le}return Bt.apply(r,fo([this.value()],arguments))})}),r}function q_(){return gn._===this&&(gn._=Kr),this}function _f(){}function Y_(r){return r=wi(r),ae(function(h){return $(h,r)})}var Z_=Nn(Yi),J_=Nn(Bh),$_=Nn(Po);function Fp(r){return nf(r)?Ko(cs(r)):$t(r)}function K_(r){return function(h){return r==null?o:hs(r,h)}}var Q_=eu(),t1=eu(!0);function xf(){return[]}function wf(){return!1}function e1(){return{}}function i1(){return""}function n1(){return!0}function r1(r,h){if(r=wi(r),r<1||r>ce)return[];var y=It,D=Vn(r,It);h=si(h),r-=It;for(var Y=Ro(D,h);++y<r;)h(y);return Y}function o1(r){return vi(r)?Yi(r,cs):to(r)?[r]:er(op(Zi(r)))}function s1(r){var h=++ur;return Zi(r)+h}var a1=Tr(function(r,h){return r+h},0),l1=dh("ceil"),h1=Tr(function(r,h){return r/h},1),u1=dh("floor");function c1(r){return r&&r.length?Mo(r,Gr,uh):o}function f1(r,h){return r&&r.length?Mo(r,si(h,2),uh):o}function d1(r){return ya(r,Gr)}function p1(r,h){return ya(r,si(h,2))}function m1(r){return r&&r.length?Mo(r,Gr,rt):o}function g1(r,h){return r&&r.length?Mo(r,si(h,2),rt):o}var v1=Tr(function(r,h){return r*h},1),y1=dh("round"),_1=Tr(function(r,h){return r-h},0);function x1(r){return r&&r.length?ts(r,Gr):0}function w1(r,h){return r&&r.length?ts(r,si(h,2)):0}return it.after=Vv,it.ary=gp,it.assign=Ly,it.assignIn=Lp,it.assignInWith=Qu,it.assignWith=Ry,it.at=Oy,it.before=vp,it.bind=hf,it.bindAll=B_,it.bindKey=yp,it.castArray=ey,it.chain=dp,it.chunk=u0,it.compact=c0,it.concat=f0,it.cond=N_,it.conforms=F_,it.constant=gf,it.countBy=xv,it.create=Iy,it.curry=_p,it.curryRight=xp,it.debounce=wp,it.defaults=Dy,it.defaultsDeep=zy,it.defer=Wv,it.delay=jv,it.difference=d0,it.differenceBy=p0,it.differenceWith=m0,it.drop=g0,it.dropRight=v0,it.dropRightWhile=y0,it.dropWhile=_0,it.fill=x0,it.filter=Tv,it.flatMap=Ev,it.flatMapDeep=bv,it.flatMapDepth=Cv,it.flatten=hp,it.flattenDeep=w0,it.flattenDepth=T0,it.flip=Xv,it.flow=G_,it.flowRight=H_,it.fromPairs=M0,it.functions=Hy,it.functionsIn=Vy,it.groupBy=Av,it.initial=E0,it.intersection=b0,it.intersectionBy=C0,it.intersectionWith=A0,it.invert=jy,it.invertBy=Xy,it.invokeMap=Lv,it.iteratee=vf,it.keyBy=Rv,it.keys=Jn,it.keysIn=Ur,it.map=qu,it.mapKeys=Yy,it.mapValues=Zy,it.matches=V_,it.matchesProperty=W_,it.memoize=Zu,it.merge=Jy,it.mergeWith=Rp,it.method=j_,it.methodOf=X_,it.mixin=yf,it.negate=Ju,it.nthArg=Y_,it.omit=$y,it.omitBy=Ky,it.once=qv,it.orderBy=Ov,it.over=Z_,it.overArgs=Yv,it.overEvery=J_,it.overSome=$_,it.partial=uf,it.partialRight=Tp,it.partition=Iv,it.pick=Qy,it.pickBy=Op,it.property=Fp,it.propertyOf=K_,it.pull=O0,it.pullAll=cp,it.pullAllBy=I0,it.pullAllWith=D0,it.pullAt=z0,it.range=Q_,it.rangeRight=t1,it.rearg=Zv,it.reject=kv,it.remove=k0,it.rest=Jv,it.reverse=af,it.sampleSize=Nv,it.set=e_,it.setWith=i_,it.shuffle=Fv,it.slice=B0,it.sortBy=Hv,it.sortedUniq=W0,it.sortedUniqBy=j0,it.split=E_,it.spread=$v,it.tail=X0,it.take=q0,it.takeRight=Y0,it.takeRightWhile=Z0,it.takeWhile=J0,it.tap=cv,it.throttle=Kv,it.thru=Xu,it.toArray=Cp,it.toPairs=Ip,it.toPairsIn=Dp,it.toPath=o1,it.toPlainObject=Pp,it.transform=n_,it.unary=Qv,it.union=$0,it.unionBy=K0,it.unionWith=Q0,it.uniq=tv,it.uniqBy=ev,it.uniqWith=iv,it.unset=r_,it.unzip=lf,it.unzipWith=fp,it.update=o_,it.updateWith=s_,it.values=gh,it.valuesIn=a_,it.without=nv,it.words=Bp,it.wrap=ty,it.xor=rv,it.xorBy=ov,it.xorWith=sv,it.zip=av,it.zipObject=lv,it.zipObjectDeep=hv,it.zipWith=uv,it.entries=Ip,it.entriesIn=Dp,it.extend=Lp,it.extendWith=Qu,yf(it,it),it.add=a1,it.attempt=Np,it.camelCase=c_,it.capitalize=zp,it.ceil=l1,it.clamp=l_,it.clone=iy,it.cloneDeep=ry,it.cloneDeepWith=oy,it.cloneWith=ny,it.conformsTo=sy,it.deburr=kp,it.defaultTo=U_,it.divide=h1,it.endsWith=f_,it.eq=Uo,it.escape=d_,it.escapeRegExp=p_,it.every=wv,it.find=Mv,it.findIndex=ap,it.findKey=ky,it.findLast=Sv,it.findLastIndex=lp,it.findLastKey=By,it.floor=u1,it.forEach=pp,it.forEachRight=mp,it.forIn=Ny,it.forInRight=Fy,it.forOwn=Uy,it.forOwnRight=Gy,it.get=df,it.gt=ay,it.gte=ly,it.has=Wy,it.hasIn=pf,it.head=up,it.identity=Gr,it.includes=Pv,it.indexOf=S0,it.inRange=h_,it.invoke=qy,it.isArguments=Al,it.isArray=vi,it.isArrayBuffer=hy,it.isArrayLike=Fr,it.isArrayLikeObject=Dn,it.isBoolean=uy,it.isBuffer=Ba,it.isDate=cy,it.isElement=fy,it.isEmpty=dy,it.isEqual=py,it.isEqualWith=my,it.isError=cf,it.isFinite=gy,it.isFunction=Xs,it.isInteger=Mp,it.isLength=$u,it.isMap=Sp,it.isMatch=vy,it.isMatchWith=yy,it.isNaN=_y,it.isNative=xy,it.isNil=Ty,it.isNull=wy,it.isNumber=Ep,it.isObject=wn,it.isObjectLike=Ln,it.isPlainObject=ou,it.isRegExp=ff,it.isSafeInteger=My,it.isSet=bp,it.isString=Ku,it.isSymbol=to,it.isTypedArray=mh,it.isUndefined=Sy,it.isWeakMap=Ey,it.isWeakSet=by,it.join=P0,it.kebabCase=m_,it.last=bo,it.lastIndexOf=L0,it.lowerCase=g_,it.lowerFirst=v_,it.lt=Cy,it.lte=Ay,it.max=c1,it.maxBy=f1,it.mean=d1,it.meanBy=p1,it.min=m1,it.minBy=g1,it.stubArray=xf,it.stubFalse=wf,it.stubObject=e1,it.stubString=i1,it.stubTrue=n1,it.multiply=v1,it.nth=R0,it.noConflict=q_,it.noop=_f,it.now=Yu,it.pad=y_,it.padEnd=__,it.padStart=x_,it.parseInt=w_,it.random=u_,it.reduce=Dv,it.reduceRight=zv,it.repeat=T_,it.replace=M_,it.result=t_,it.round=y1,it.runInContext=Lt,it.sample=Bv,it.size=Uv,it.snakeCase=S_,it.some=Gv,it.sortedIndex=N0,it.sortedIndexBy=F0,it.sortedIndexOf=U0,it.sortedLastIndex=G0,it.sortedLastIndexBy=H0,it.sortedLastIndexOf=V0,it.startCase=b_,it.startsWith=C_,it.subtract=_1,it.sum=x1,it.sumBy=w1,it.template=A_,it.times=r1,it.toFinite=qs,it.toInteger=wi,it.toLength=Ap,it.toLower=P_,it.toNumber=Co,it.toSafeInteger=Py,it.toString=Zi,it.toUpper=L_,it.trim=R_,it.trimEnd=O_,it.trimStart=I_,it.truncate=D_,it.unescape=z_,it.uniqueId=s1,it.upperCase=k_,it.upperFirst=mf,it.each=pp,it.eachRight=mp,it.first=up,yf(it,function(){var r={};return Nr(it,function(h,y){Ti.call(it.prototype,y)||(r[y]=h)}),r}(),{chain:!1}),it.VERSION=c,Ji(["bind","bindKey","curry","curryRight","partial","partialRight"],function(r){it[r].placeholder=it}),Ji(["drop","take"],function(r,h){_i.prototype[r]=function(y){y=y===o?1:vn(wi(y),0);var D=this.__filtered__&&!h?new _i(this):this.clone();return D.__filtered__?D.__takeCount__=Vn(y,D.__takeCount__):D.__views__.push({size:Vn(y,It),type:r+(D.__dir__<0?"Right":"")}),D},_i.prototype[r+"Right"]=function(y){return this.reverse()[r](y).reverse()}}),Ji(["filter","map","takeWhile"],function(r,h){var y=h+1,D=y==G||y==Et;_i.prototype[r]=function(Y){var ut=this.clone();return ut.__iteratees__.push({iteratee:si(Y,3),type:y}),ut.__filtered__=ut.__filtered__||D,ut}}),Ji(["head","last"],function(r,h){var y="take"+(h?"Right":"");_i.prototype[r]=function(){return this[y](1).value()[0]}}),Ji(["initial","tail"],function(r,h){var y="drop"+(h?"":"Right");_i.prototype[r]=function(){return this.__filtered__?new _i(this):this[y](1)}}),_i.prototype.compact=function(){return this.filter(Gr)},_i.prototype.find=function(r){return this.filter(r).head()},_i.prototype.findLast=function(r){return this.reverse().find(r)},_i.prototype.invokeMap=ae(function(r,h){return typeof r=="function"?new _i(this):this.map(function(y){return e(y,r,h)})}),_i.prototype.reject=function(r){return this.filter(Ju(si(r)))},_i.prototype.slice=function(r,h){r=wi(r);var y=this;return y.__filtered__&&(r>0||h<0)?new _i(y):(r<0?y=y.takeRight(-r):r&&(y=y.drop(r)),h!==o&&(h=wi(h),y=h<0?y.dropRight(-h):y.take(h-r)),y)},_i.prototype.takeRightWhile=function(r){return this.reverse().takeWhile(r).reverse()},_i.prototype.toArray=function(){return this.take(It)},Nr(_i.prototype,function(r,h){var y=/^(?:filter|find|map|reject)|While$/.test(h),D=/^(?:head|last)$/.test(h),Y=it[D?"take"+(h=="last"?"Right":""):h],ut=D||/^find/.test(h);Y&&(it.prototype[h]=function(){var yt=this.__wrapped__,bt=D?[1]:arguments,Bt=yt instanceof _i,oe=bt[0],le=Bt||vi(yt),de=function(Ri){var Ui=Y.apply(it,fo([Ri],bt));return D&&ke?Ui[0]:Ui};le&&y&&typeof oe=="function"&&oe.length!=1&&(Bt=le=!1);var ke=this.__chain__,Ze=!!this.__actions__.length,hi=ut&&!ke,Mi=Bt&&!Ze;if(!ut&&le){yt=Mi?yt:new _i(this);var ui=r.apply(yt,bt);return ui.__actions__.push({func:Xu,args:[de],thisArg:o}),new qn(ui,ke)}return hi&&Mi?r.apply(this,bt):(ui=this.thru(de),hi?D?ui.value()[0]:ui.value():ui)})}),Ji(["pop","push","shift","sort","splice","unshift"],function(r){var h=On[r],y=/^(?:push|sort|unshift)$/.test(r)?"tap":"thru",D=/^(?:pop|shift)$/.test(r);it.prototype[r]=function(){var Y=arguments;if(D&&!this.__chain__){var ut=this.value();return h.apply(vi(ut)?ut:[],Y)}return this[y](function(yt){return h.apply(vi(yt)?yt:[],Y)})}}),Nr(_i.prototype,function(r,h){var y=it[h];if(y){var D=y.name+"";Ti.call(os,D)||(os[D]=[]),os[D].push({name:h,func:y})}}),os[$i(o,w).name]=[{name:"wrapper",func:o}],_i.prototype.clone=Ca,_i.prototype.reverse=Ou,_i.prototype.value=Aa,it.prototype.at=fv,it.prototype.chain=dv,it.prototype.commit=pv,it.prototype.next=mv,it.prototype.plant=vv,it.prototype.reverse=yv,it.prototype.toJSON=it.prototype.valueOf=it.prototype.value=_v,it.prototype.first=it.prototype.head,rs&&(it.prototype[rs]=gv),it},is=Xc();Zr?((Zr.exports=is)._=is,Jo._=is):gn._=is}).call(Er)}(lu,lu.exports);var am=lu.exports;const ec=tc(am);class lm{constructor(a=[],o=!1){Ho(this,"simplifyFunc",a=>{try{a=turf.simplify(a,{tolerance:5e-4,highQuality:!1,mutate:!0})}catch{}return a});mars3d&&(this.vectorArr=a,this.geoJsonType=new Map([["Point"],["LineString"],["Polygon"],["MultiPoint"],["MultiLineString"],["MultiPolygon"]]),this.avoidanceArr=[],this.editDate={id:""},this.isDynamicMasking=o,this.disabled=!1)}remove(a,o=null){o&&o.isClone=="true"?window.mapClone.mapEx.removeLayer(window.mapClone.mapEx.getLayer(a,"vectorId")):(window.map.removeLayer(window.map.getLayer(a,"vectorId")),window.dynamicMasking&&window.dynamicMasking.remove(a))}add(a,o){return new Promise((c,f)=>{let u,m=o==null?void 0:o.isClone;if(typeof a!="object"){let g=window.map.getLayer(a,"vectorId");if(g)return c(g);u=this.query(a)}else{let g=window.map.getLayer(a.id,"vectorId");if(g)return c(g);u=a}if(u){let{value:g,url:v,id:S,title:b}=u;new Cesium.Resource({url:v}).fetchJson().then(k=>{let{id:I,title:N,shpInfo:E}=u,{attributes:P,geometryType:w,geometryCount:M,pointCount:R}=E;if(P){let{width:C,materialType:U,materialOptions:F,clampToGround:X,distanceDisplayCondition:K,distanceDisplayCondition_near:Z,distanceDisplayCondition_far:ct,zIndex:Rt,label:tt,fill:_t,diffHeight:G,outline:Pt,outlineStyle:Et,color:At,pixelSize:ce,outlineColor:re,outlineWidth:Ft,classificationType:It,setHeight:Nt}=JSON.parse(P),Pe;switch(tt.height==""&&(tt.height=null),this.isDynamicMasking?(tt.color=Cesium.Color.fromCssColorString(tt.color).withAlpha(0),tt.outlineColor=Cesium.Color.fromCssColorString(tt.outlineColor).withAlpha(.001),tt.backgroundColor=Cesium.Color.fromCssColorString(tt.backgroundColor).withAlpha(.001),tt.background=!1,tt.outline=!1,tt.show=!1):(tt.color=Cesium.Color.fromCssColorString(tt.color),tt.outlineColor=Cesium.Color.fromCssColorString(tt.outlineColor),tt.backgroundColor=Cesium.Color.fromCssColorString(tt.backgroundColor)),w){case"LineString":case"MultiLineString":tt.backgroundPadding=5,Pe=new mars3d.layer.GeoJsonLayer({data:k,vectorId:I,symbol:{type:"polylineC",styleOptions:{width:C,clampToGround:X,distanceDisplayCondition:K,distanceDisplayCondition_far:ct,distanceDisplayCondition_near:Z,materialType:U,materialOptions:F,classificationType:It,setHeight:Nt,label:tt}},hasZIndex:!0,zIndex:Rt});break;case"Polygon":case"MultiPolygon":U=="PolyGrass"&&(F={evenColor:new Cesium.Color(.25,.4,.1,1),oddColor:new Cesium.Color(.1,.1,.1,1),frequency:1.5}),Pe=new mars3d.layer.GeoJsonLayer({data:k,vectorId:I,symbol:{type:"polygon",styleOptions:{fill:_t,diffHeight:G,clampToGround:X,materialType:U,materialOptions:F,distanceDisplayCondition:K,distanceDisplayCondition_far:ct,distanceDisplayCondition_near:Z,outlineStyle:Et,outline:Pt,classificationType:It,setHeight:Nt,label:tt}}});break;case"Point":case"MultiPoint":Pe=new mars3d.layer.GeoJsonLayer({data:k,vectorId:I,symbol:{type:"pointC",styleOptions:{color:At,pixelSize:ce,outline:Pt,outlineColor:re,outlineWidth:Ft,visibleDepth:!1,label:tt}}});break}m?window.mapClone.mapEx.addLayer(Pe):window.map.addLayer(Pe),Pe.bindPopup(Wt=>{if(this.disabled==!0)return!1;let $e='<div class="bim-map-popup">';return Object.keys(Wt.graphic.attr).forEach((Si,Oe)=>{Wt.graphic.attr[Si]&&($e+=`<p><b>${Si}</b> : ${Wt.graphic.attr[Si]}</p>`)}),$e+="</div>",$e});let pe=ec.debounce(Wt=>{window.dynamicMasking.add(Wt,JSON.parse(P))},500);Pe.readyPromise.then(Wt=>{window.dynamicMasking&&pe(Wt),c(Wt)}).catch(Wt=>{c({tite:"【矢量】「"+N+"」无法加载",type:"error",id:I,url:v})})}else c({tite:"【矢量】「"+N+"」无法加载",type:"error",id:I,url:v})}).catch(k=>{c({tite:"【矢量】「"+b+"」链接地址有误",type:"error",id:S,url:v})})}else c({tite:"【矢量】ID:「"+a+"」已删除",type:"error",id:a})})}updateData(a){this.vectorArr=a}processingKML(a){let o,c=2e3,f=!0,{kmlInfo:u}=a,{fill:m,areaColor:g,areaSideColor:v,transparency:S,isAreaSideColor:b,minDistinct:O,textDistinct:k,textSize:I,textColor:N,fontStyle:E,outLine:P,sideColor:w,backGround:M,backGroundColor:R,clampToGround:C}=u,U={fill:m,color:g,opacity:S||.5,outline:b,outlineColor:v,outlineWidth:2,clampToGround:C,distanceDisplayCondition:!0,distanceDisplayCondition_far:k||1e6,distanceDisplayCondition_near:O||0,classificationType:o,opacity:String(S)},F={text:"{name}",horizontalOrigin:Cesium.HorizontalOrigin.CENTER,verticalOrigin:Cesium.VerticalOrigin.BOTTOM,pixelOffsetY:-10,font_size:26,color:N||"#ffffff",font_family:E||"黑体",outline:P||!0,outlineColor:w||"#000000",outlineWidth:4,scaleByDistance:!0,distanceDisplayCondition:!0,distanceDisplayCondition_far:k||1e6,distanceDisplayCondition_near:O||0,background:M||!1,backgroundColor:R||"",visibleDepth:f,clampToGround:C||!1,disableDepthTestDistance:c};return{...U,label:F}}selected(a){window.map.getLayer(a,"vectorId")&&window.map.getLayer(a,"vectorId").flyTo()}query(a){return this.vectorArr.length==0?!1:this.vectorArr.find(o=>o.id==a)}queryVector(a){return window.map.getLayer(a,"vectorId")}editVector(a,o,c){let f=window.map.getLayer(a,"vectorId"),u=bf(o,c);f&&(f.eachGraphic(m=>{m.label&&m.label.show===!1&&(delete m.label.outline,delete m.label.background,delete m.label.outlineColor,delete m.label.backgroundColor),u.label&&u.label.height==""&&(u.label.height=null),m.setStyle({...u})}),window.dynamicMasking&&dynamicMasking.modify(a,u))}nationalBoundaries(a="/gis/nationalBoundaries.json"){let o=new mars3d.layer.GeoJsonLayer({name:"国界",url:a,vectorId:"border",format:c=>{try{c=turf.simplify(c,{tolerance:1e-5,highQuality:!1,mutate:!0})}catch{}return c},symbol:{type:"polylineC",styleOptions:{width:2,materialType:"Color",materialOptions:{color:"#CD9B1D"},distanceDisplayCondition:!0,distanceDisplayCondition_near:1e3,distanceDisplayCondition_far:2e7,clampToGround:!0,classificationType:Cesium.ClassificationType.TERRAIN}}});map.addLayer(o)}switchDynamicMasking(a){this.isDynamicMasking=a}}class hm{constructor(a=[]){mars3d&&(this.terrainProviderArr=a,this.terrainProviderId="",this.events={},window.map.on(mars3d.EventType.terrainLoadError,o=>{this.hide()}),window.map.viewer.scene.globe.tileLoadProgressEvent.addEventListener(o=>{window.map.viewer.scene.globe.tilesLoaded&&this.emit("load",o)}))}add(a,o){if(o==null?void 0:o.isClone)mapClone&&(window.mapClone.mapEx.terrainProvider=window.map.terrainProvider);else{let{url:f,id:u}=a;if(this.terrainProviderId==u&&window.map.terrainProvider._layers)return!1;window.map.terrainProvider=mars3d.LayerUtil.createTerrainProvider({imageXyzId:u,type:"xyz",url:f,requestVertexNormals:!0,requestMetadata:!0,clip:!0,flat:!0,uplift:!0,flood:!0}),this.terrainProviderId=u}}show(a){(a==null?void 0:a.isClone)?window.mapClone.mapEx.hasTerrain=!0:window.map.hasTerrain=!0}hide(a){(a==null?void 0:a.isClone)?window.mapClone.mapEx.hasTerrain=!1:window.map.hasTerrain=!1}on(a,o){a=="load"&&(this.events[a]?this.events[a].push(o):this.events[a]=[o])}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}once(a,o){const c=()=>{o(),this.off(a,c)};this.on(a,c)}addClip(a){return new Promise((o,c)=>{window.bimClip?o(bimClip.clipGisAdd(a)):c("挖洞工具未初始化")})}}class um{constructor(a=[],o){mars3d&&(this.elevationImageArr=a,this.elevationImageLayer,o?this.gisTkone={Authorization:`Bearer ${o}`}:this.gisTkone={},this.form={brightnessVal:1.3,msaaSamples:4,surfaceOpacity:1,layerOpacity:1,layerBrightness:2,layerContrast:1,layerHue:0,layerSaturation:1,layerGamma:1},this.tdtLayer=null)}pushVector(a){this.elevationImageArr.push(a)}add(a,o=!0,c){let f;if(typeof a!="object"?f=a:f=a.imageXyzId,window.map.getLayer(f,"imageXyzId"))return!1;const{layerOpacity:u,layerBrightness:m,layerContrast:g,layerHue:v,layerSaturation:S,layerGamma:b,surfaceOpacity:O}=this.exposureEnvironmentSettings();return new Promise((k,I)=>{let N,E,P,w,M,R;if(typeof a!="object"){let C=this.query(a);C||I("缺少树结构");let{gisInfo:U}=C;N=U.id,P=U.order,E=C.url,w=U.minLevel,M=U.maxLevel}else N=a.imageXyzId,E=a.url,P=a.zIndex,w=a.minimumLevel,M=a.maximumLevel,R=a.chinaCRS;this.elevationImageLayer=new mars3d.layer.XyzLayer({imageXyzId:N,type:"xyz",url:E,hasZIndex:!0,zIndex:P.toString(),brightness:m,opacity:u,saturation:S,contrast:g,hue:v,gamma:b,alpha:O,show:!0,minimumLevel:w||0,maximumLevel:M||15,chinaCRS:R,headers:o?this.gisTkone:null}),this.elevationImageLayer.on(mars3d.EventType.load,C=>{k(C)}),window.map.addLayer(this.elevationImageLayer),c&&Object.keys(c).forEach(C=>{this.elevationImageLayer.on(fnType.get(C),U=>{c[C](U)})})})}remove(a){window.map.removeLayer(window.map.getLayer(a,"imageXyzId"))}query(a){return this.elevationImageArr.length==0?!1:this.elevationImageArr.find(o=>o.id==a)}initial(){this.elevationImageArr=[],this.elevationImageLayer=null}exposureEnvironmentSettings(){return localStorage.getItem("environmentSettings")?JSON.parse(localStorage.getItem("environmentSettings")):(localStorage.setItem("environmentSettings",JSON.stringify(this.form)),JSON.parse(JSON.stringify(this.form)))}}class cm{constructor(a,...o){Ho(this,"manualFreed",ec.debounce(()=>{let{lng:a,lat:o,alt:c,pitch:f}=window.map.getCameraView(),u;this.modelArray.forEach(m=>{u=m.releasedDistance?m.releasedDistance:1e4,this.disTance([a,o,c],[m.center._lng,m.center._lat,m.center._alt],this.calculateDistance(f,u))?window.map.getLayer(m.id,"modelId")&&this.emit("leave",m):window.map.getLayer(m.id,"modelId")||this.emit("enter",m)})},200));mars3d&&(a&&a!=null&&(this.modelArray=a),this.showModelArray=[],this.Cesium=mars3d.Cesium,this.events={})}on(a,o){(a=="enter"||a=="leave")&&(this.events[a]?this.events[a].push(o):this.events[a]=[o])}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}once(a,o){const c=()=>{o(),this.off(a,c)};this.on(a,c)}say(a){return this[a]}add(a,o){this[a].push(o)}remove(a,o){this[a]=this[a].filter(function(c){return c!==o})}initial(){this.modelArray=[],this.events={}}updateCustomExcavationDetails(a,o,c,f=[],u={}){let m,g,v;switch(m=this.modelArray.find(S=>S.modelId==a).customize.bimModelExcavationDetails,v=m.find((S,b)=>{if(S.id==o)return g=b,S}),c){case"delete":m.splice(g,1);break;case"update":v.excavationDetails=f;break;case"add":m.push(u);break;case"edit":v.excavationDetails=u.excavationDetails,v.kId=u.kId;break}return m}resourceRelease(){window.map.viewer.camera.moveEnd.addEventListener(()=>{this.freed()})}freed(){let{alt:a}=window.map.getCameraView();a<2e4&&(this.freed=ec.throttle(()=>{let{lng:o,lat:c,alt:f,pitch:u}=window.map.getCameraView();this.modelArray&&this.modelArray.forEach(m=>{let g=m.bimModel.releasedDistance?m.bimModel.releasedDistance:1e4;m.center&&this.disTance([o,c,f],[m.center._lng,m.center._lat,m.center._alt],this.calculateDistance(u,g))?window.map.getLayer(m.id,"modelId")&&this.emit("leave",m):this.showModelArray.indexOf(m.id)>=0&&!window.map.getLayer(m.id,"modelId")&&this.emit("enter",m)})},2e3),this.freed())}findPnodeId(a,o,c="id"){let f;if(a){for(var u=0;u<a.length;u++){let m=a[u];if(m[c]==o)return f=m,f;if(m.children&&m.children.length>0&&(f=this.findPnodeId(m.children,o,c),f))return f}return f}}disTance(a,o,c){let f,u,m;return f=Cesium.Cartesian3.fromDegrees(...a),u=Cesium.Cartesian3.fromDegrees(...o),m=Cesium.Cartesian3.distance(f,u),m>c}calculateDistance(a,o){let c=(a+180)%360-180;c=Math.max(-90,Math.min(c,90));let f=(o-o/5)*(Math.abs(c)/90)+o/5;return Math.round(f)}}class fm{constructor(a=[],o){mars3d&&(this.entityArr=a,this.entityLayer=new mars3d.layer.GraphicLayer({entityId:"bimEntity"}),window.map.addLayer(this.entityLayer),this.entityItem=null,this.events={},this.entityCloneLayer)}on(a,o){(a=="change"||a=="collection")&&(this.events[a]?this.events[a].push(o):this.events[a]=[o])}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}offAll(){this.events={}}once(a,o){const c=()=>{o(),this.off(a,c)};this.on(a,c)}add(a,o=null,c){return new Promise((f,u)=>{var m;if(this.entityLayer){let g,v,S;if(c==null?void 0:c.isClone)this.entityCloneLayer&&(v=this.query(a),v?(S=v.bimPlanPainting?JSON.parse(v.bimPlanPainting.graphic):JSON.parse(v.graphic),S.attr=S.attr||{},S.attr.entityId=a,this.entityCloneLayer.addGraphic(S)):f({tite:"【标绘】 ID:「"+a+"」已删除",type:"error",id:a}));else{if(typeof a!="object"?(g=this.entityLayer.getGraphicByAttr(a,"entityId"),v=this.query(a),v?(S=v.bimPlanPainting?JSON.parse(v.bimPlanPainting.graphic):JSON.parse(v.graphic),S.attr=S.attr||{},S.attr.entityId=a):f({tite:"【标绘】ID:「"+a+"」已删除",type:"error",id:a})):(g=this.entityLayer.getGraphicByAttr(a.id,"entityId"),S=JSON.parse(JSON.stringify(a)),S.attr=S.attr||{},S.attr.entityId=S.attr.entityId||o,S.attr==null?S.attr={entityId:a.id}:((m=S.attr)==null?void 0:m.entityId)==null&&o&&(S.attr.entityId=o)),g)return f();this.entityLayer.addGraphic(S),f(S)}}else f()})}query(a){return this.entityArr.length==0?!1:this.entityArr.find(o=>o.id==a)}queryEntity(a){if(bimEntity.entityLayer)return bimEntity.entityLayer.getGraphicByAttr(a,"entityId")}selected(a,o=null){let c=this.entityLayer.getGraphicByAttr(a,"entityId");o==null||o.isClone,(c.options.type=="div"||c.options.type=="point")&&c._point?c.flyTo({radius:c._point._alt+500<500?5e3:c._point._alt+500}):c.flyTo()}remove(a,o=null){var f,u;(o==null?void 0:o.isClone)?this.entityCloneLayer&&((f=this.entityCloneLayer.getGraphicByAttr(a,"entityId"))==null||f.remove()):this.entityLayer.getGraphicByAttr(a,"entityId")&&((u=this.entityLayer.getGraphicByAttr(a,"entityId"))==null||u.remove(),this.entityItem&&(this.entityItem._state=="destroy"||this.entityItem.options.attr.entityId==a)&&(this.entityItem=null))}entityCloneLayerInit(){(this.entityCloneLayer==null||this.entityCloneLayer.state=="destroy")&&(this.entityCloneLayer=window.mapClone._mapEx.getLayer("bimEntity","entityId"))}entityCloneLayerRemove(){this.entityCloneLayer.remove(),this.entityCloneLayer=null}removeEntityItem(){this.entityItem=null}updateData(a){this.entityArr=a}startDrawGraphic(a){return new Promise((o,c)=>{let{type:f,style:u}=a;if(a.drawShow=!1,f=="div")if(u.html)this.entityLayer.startDraw(a).then(m=>{setTimeout(()=>{this.entityItem=m,this.entityLayer.startEditing(m)},500)});else{let{title:m,divType:g,theme_color:v,font_color:S,scaleByDistance:b,scaleByDistance_far:O,scaleByDistance_farValue:k,scaleByDistance_near:I,scaleByDistance_nearValue:N,distanceDisplayCondition:E,distanceDisplayCondition_far:P,distanceDisplayCondition_near:w,clampToGround:M}=u,R={type:"div",style:{pointerEvents:!0,scaleByDistance:b,scaleByDistance_far:O,scaleByDistance_farValue:k,scaleByDistance_near:I,scaleByDistance_nearValue:N,distanceDisplayCondition:E,distanceDisplayCondition_far:P,distanceDisplayCondition_near:w,clampToGround:M,horizontalOrigin:Cesium.HorizontalOrigin.LEFT,verticalOrigin:Cesium.VerticalOrigin.BOTTOM}};switch(g){case"1":R.style.html=`<div class="entity-div-style entity-div-style1" style="--theme-color1:${v};--theme-font-color1:${S};">
|
|
2636
|
+
}`;var Mi=Np(function(){return Fi(ut,Ze+"return "+de).apply(o,yt)});if(Mi.source=de,cf(Mi))throw Mi;return Mi}function P_(r){return Zi(r).toLowerCase()}function L_(r){return Zi(r).toUpperCase()}function R_(r,h,y){if(r=Zi(r),r&&(y||h===o))return _a(r);if(!r||!(h=Ye(h)))return r;var D=ar(r),Y=ar(h),ut=es(D,Y),yt=Cs(D,Y)+1;return xn(D,ut,yt).join("")}function O_(r,h,y){if(r=Zi(r),r&&(y||h===o))return r.slice(0,xa(r)+1);if(!r||!(h=Ye(h)))return r;var D=ar(r),Y=Cs(D,ar(h))+1;return xn(D,0,Y).join("")}function I_(r,h,y){if(r=Zi(r),r&&(y||h===o))return r.replace(lo,"");if(!r||!(h=Ye(h)))return r;var D=ar(r),Y=es(D,ar(h));return xn(D,Y).join("")}function D_(r,h){var y=ct,D=Rt;if(wn(h)){var Y="separator"in h?h.separator:Y;y="length"in h?wi(h.length):y,D="omission"in h?Ye(h.omission):D}r=Zi(r);var ut=r.length;if(Ir(r)){var yt=ar(r);ut=yt.length}if(y>=ut)return r;var bt=y-$r(D);if(bt<1)return D;var Bt=yt?xn(yt,0,bt).join(""):r.slice(0,bt);if(Y===o)return Bt+D;if(yt&&(bt+=Bt.length-bt),ff(Y)){if(r.slice(bt).search(Y)){var oe,le=Bt;for(Y.global||(Y=Kn(Y.source,Zi(jl.exec(Y))+"g")),Y.lastIndex=0;oe=Y.exec(le);)var de=oe.index;Bt=Bt.slice(0,de===o?bt:de)}}else if(r.indexOf(Ye(Y),bt)!=bt){var ke=Bt.lastIndexOf(Y);ke>-1&&(Bt=Bt.slice(0,ke))}return Bt+D}function z_(r){return r=Zi(r),r&&Yo.test(r)?r.replace(Ao,th):r}var k_=ze(function(r,h,y){return r+(y?" ":"")+h.toUpperCase()}),mf=Me("toUpperCase");function Bp(r,h,y){return r=Zi(r),h=y?o:h,h===o?Rs(r)?jc(r):rl(r):r.match(h)||[]}var Np=ae(function(r,h){try{return yr(r,o,h)}catch(y){return cf(y)?y:new ai(y)}}),B_=Ws(function(r,h){return Ji(h,function(y){y=cs(y),Bo(r,y,hf(r[y],r))}),r});function N_(r){var h=r==null?0:r.length,y=si();return r=h?Yi(r,function(D){if(typeof D[1]!="function")throw new lr(m);return[y(D[0]),D[1]]}):[],ae(function(D){for(var Y=-1;++Y<h;){var ut=r[Y];if(yr(ut[0],this,D))return yr(ut[1],this,D)}})}function F_(r){return Oa(wr(r,O))}function gf(r){return function(){return r}}function U_(r,h){return r==null||r!==r?h:r}var G_=Oi(),H_=Oi(!0);function Gr(r){return r}function vf(r){return H(typeof r=="function"?r:wr(r,O))}function V_(r){return gt(wr(r,O))}function W_(r,h){return Ct(r,wr(h,O))}var j_=ae(function(r,h){return function(y){return e(y,r,h)}}),X_=ae(function(r,h){return function(y){return e(r,y,h)}});function yf(r,h,y){var D=Jn(h),Y=Gs(h,D);y==null&&!(wn(h)&&(Y.length||!D.length))&&(y=h,h=r,r=this,Y=Gs(h,Jn(h)));var ut=!(wn(y)&&"chain"in y)||!!y.chain,yt=Xs(r);return Ji(Y,function(bt){var Bt=h[bt];r[bt]=Bt,yt&&(r.prototype[bt]=function(){var oe=this.__chain__;if(ut||oe){var le=r(this.__wrapped__),de=le.__actions__=er(this.__actions__);return de.push({func:Bt,args:arguments,thisArg:r}),le.__chain__=oe,le}return Bt.apply(r,fo([this.value()],arguments))})}),r}function q_(){return gn._===this&&(gn._=Kr),this}function _f(){}function Y_(r){return r=wi(r),ae(function(h){return K(h,r)})}var Z_=Nn(Yi),J_=Nn(Bh),$_=Nn(Po);function Fp(r){return nf(r)?Ko(cs(r)):$t(r)}function K_(r){return function(h){return r==null?o:hs(r,h)}}var Q_=eu(),t1=eu(!0);function xf(){return[]}function wf(){return!1}function e1(){return{}}function i1(){return""}function n1(){return!0}function r1(r,h){if(r=wi(r),r<1||r>ce)return[];var y=It,D=Vn(r,It);h=si(h),r-=It;for(var Y=Ro(D,h);++y<r;)h(y);return Y}function o1(r){return vi(r)?Yi(r,cs):to(r)?[r]:er(op(Zi(r)))}function s1(r){var h=++ur;return Zi(r)+h}var a1=Tr(function(r,h){return r+h},0),l1=dh("ceil"),h1=Tr(function(r,h){return r/h},1),u1=dh("floor");function c1(r){return r&&r.length?Mo(r,Gr,uh):o}function f1(r,h){return r&&r.length?Mo(r,si(h,2),uh):o}function d1(r){return ya(r,Gr)}function p1(r,h){return ya(r,si(h,2))}function m1(r){return r&&r.length?Mo(r,Gr,rt):o}function g1(r,h){return r&&r.length?Mo(r,si(h,2),rt):o}var v1=Tr(function(r,h){return r*h},1),y1=dh("round"),_1=Tr(function(r,h){return r-h},0);function x1(r){return r&&r.length?ts(r,Gr):0}function w1(r,h){return r&&r.length?ts(r,si(h,2)):0}return it.after=Vv,it.ary=gp,it.assign=Ly,it.assignIn=Lp,it.assignInWith=Qu,it.assignWith=Ry,it.at=Oy,it.before=vp,it.bind=hf,it.bindAll=B_,it.bindKey=yp,it.castArray=ey,it.chain=dp,it.chunk=u0,it.compact=c0,it.concat=f0,it.cond=N_,it.conforms=F_,it.constant=gf,it.countBy=xv,it.create=Iy,it.curry=_p,it.curryRight=xp,it.debounce=wp,it.defaults=Dy,it.defaultsDeep=zy,it.defer=Wv,it.delay=jv,it.difference=d0,it.differenceBy=p0,it.differenceWith=m0,it.drop=g0,it.dropRight=v0,it.dropRightWhile=y0,it.dropWhile=_0,it.fill=x0,it.filter=Tv,it.flatMap=Ev,it.flatMapDeep=bv,it.flatMapDepth=Cv,it.flatten=hp,it.flattenDeep=w0,it.flattenDepth=T0,it.flip=Xv,it.flow=G_,it.flowRight=H_,it.fromPairs=M0,it.functions=Hy,it.functionsIn=Vy,it.groupBy=Av,it.initial=E0,it.intersection=b0,it.intersectionBy=C0,it.intersectionWith=A0,it.invert=jy,it.invertBy=Xy,it.invokeMap=Lv,it.iteratee=vf,it.keyBy=Rv,it.keys=Jn,it.keysIn=Ur,it.map=qu,it.mapKeys=Yy,it.mapValues=Zy,it.matches=V_,it.matchesProperty=W_,it.memoize=Zu,it.merge=Jy,it.mergeWith=Rp,it.method=j_,it.methodOf=X_,it.mixin=yf,it.negate=Ju,it.nthArg=Y_,it.omit=$y,it.omitBy=Ky,it.once=qv,it.orderBy=Ov,it.over=Z_,it.overArgs=Yv,it.overEvery=J_,it.overSome=$_,it.partial=uf,it.partialRight=Tp,it.partition=Iv,it.pick=Qy,it.pickBy=Op,it.property=Fp,it.propertyOf=K_,it.pull=O0,it.pullAll=cp,it.pullAllBy=I0,it.pullAllWith=D0,it.pullAt=z0,it.range=Q_,it.rangeRight=t1,it.rearg=Zv,it.reject=kv,it.remove=k0,it.rest=Jv,it.reverse=af,it.sampleSize=Nv,it.set=e_,it.setWith=i_,it.shuffle=Fv,it.slice=B0,it.sortBy=Hv,it.sortedUniq=W0,it.sortedUniqBy=j0,it.split=E_,it.spread=$v,it.tail=X0,it.take=q0,it.takeRight=Y0,it.takeRightWhile=Z0,it.takeWhile=J0,it.tap=cv,it.throttle=Kv,it.thru=Xu,it.toArray=Cp,it.toPairs=Ip,it.toPairsIn=Dp,it.toPath=o1,it.toPlainObject=Pp,it.transform=n_,it.unary=Qv,it.union=$0,it.unionBy=K0,it.unionWith=Q0,it.uniq=tv,it.uniqBy=ev,it.uniqWith=iv,it.unset=r_,it.unzip=lf,it.unzipWith=fp,it.update=o_,it.updateWith=s_,it.values=gh,it.valuesIn=a_,it.without=nv,it.words=Bp,it.wrap=ty,it.xor=rv,it.xorBy=ov,it.xorWith=sv,it.zip=av,it.zipObject=lv,it.zipObjectDeep=hv,it.zipWith=uv,it.entries=Ip,it.entriesIn=Dp,it.extend=Lp,it.extendWith=Qu,yf(it,it),it.add=a1,it.attempt=Np,it.camelCase=c_,it.capitalize=zp,it.ceil=l1,it.clamp=l_,it.clone=iy,it.cloneDeep=ry,it.cloneDeepWith=oy,it.cloneWith=ny,it.conformsTo=sy,it.deburr=kp,it.defaultTo=U_,it.divide=h1,it.endsWith=f_,it.eq=Uo,it.escape=d_,it.escapeRegExp=p_,it.every=wv,it.find=Mv,it.findIndex=ap,it.findKey=ky,it.findLast=Sv,it.findLastIndex=lp,it.findLastKey=By,it.floor=u1,it.forEach=pp,it.forEachRight=mp,it.forIn=Ny,it.forInRight=Fy,it.forOwn=Uy,it.forOwnRight=Gy,it.get=df,it.gt=ay,it.gte=ly,it.has=Wy,it.hasIn=pf,it.head=up,it.identity=Gr,it.includes=Pv,it.indexOf=S0,it.inRange=h_,it.invoke=qy,it.isArguments=Al,it.isArray=vi,it.isArrayBuffer=hy,it.isArrayLike=Fr,it.isArrayLikeObject=Dn,it.isBoolean=uy,it.isBuffer=Ba,it.isDate=cy,it.isElement=fy,it.isEmpty=dy,it.isEqual=py,it.isEqualWith=my,it.isError=cf,it.isFinite=gy,it.isFunction=Xs,it.isInteger=Mp,it.isLength=$u,it.isMap=Sp,it.isMatch=vy,it.isMatchWith=yy,it.isNaN=_y,it.isNative=xy,it.isNil=Ty,it.isNull=wy,it.isNumber=Ep,it.isObject=wn,it.isObjectLike=Ln,it.isPlainObject=ou,it.isRegExp=ff,it.isSafeInteger=My,it.isSet=bp,it.isString=Ku,it.isSymbol=to,it.isTypedArray=mh,it.isUndefined=Sy,it.isWeakMap=Ey,it.isWeakSet=by,it.join=P0,it.kebabCase=m_,it.last=bo,it.lastIndexOf=L0,it.lowerCase=g_,it.lowerFirst=v_,it.lt=Cy,it.lte=Ay,it.max=c1,it.maxBy=f1,it.mean=d1,it.meanBy=p1,it.min=m1,it.minBy=g1,it.stubArray=xf,it.stubFalse=wf,it.stubObject=e1,it.stubString=i1,it.stubTrue=n1,it.multiply=v1,it.nth=R0,it.noConflict=q_,it.noop=_f,it.now=Yu,it.pad=y_,it.padEnd=__,it.padStart=x_,it.parseInt=w_,it.random=u_,it.reduce=Dv,it.reduceRight=zv,it.repeat=T_,it.replace=M_,it.result=t_,it.round=y1,it.runInContext=Lt,it.sample=Bv,it.size=Uv,it.snakeCase=S_,it.some=Gv,it.sortedIndex=N0,it.sortedIndexBy=F0,it.sortedIndexOf=U0,it.sortedLastIndex=G0,it.sortedLastIndexBy=H0,it.sortedLastIndexOf=V0,it.startCase=b_,it.startsWith=C_,it.subtract=_1,it.sum=x1,it.sumBy=w1,it.template=A_,it.times=r1,it.toFinite=qs,it.toInteger=wi,it.toLength=Ap,it.toLower=P_,it.toNumber=Co,it.toSafeInteger=Py,it.toString=Zi,it.toUpper=L_,it.trim=R_,it.trimEnd=O_,it.trimStart=I_,it.truncate=D_,it.unescape=z_,it.uniqueId=s1,it.upperCase=k_,it.upperFirst=mf,it.each=pp,it.eachRight=mp,it.first=up,yf(it,function(){var r={};return Nr(it,function(h,y){Ti.call(it.prototype,y)||(r[y]=h)}),r}(),{chain:!1}),it.VERSION=c,Ji(["bind","bindKey","curry","curryRight","partial","partialRight"],function(r){it[r].placeholder=it}),Ji(["drop","take"],function(r,h){_i.prototype[r]=function(y){y=y===o?1:vn(wi(y),0);var D=this.__filtered__&&!h?new _i(this):this.clone();return D.__filtered__?D.__takeCount__=Vn(y,D.__takeCount__):D.__views__.push({size:Vn(y,It),type:r+(D.__dir__<0?"Right":"")}),D},_i.prototype[r+"Right"]=function(y){return this.reverse()[r](y).reverse()}}),Ji(["filter","map","takeWhile"],function(r,h){var y=h+1,D=y==G||y==Et;_i.prototype[r]=function(Y){var ut=this.clone();return ut.__iteratees__.push({iteratee:si(Y,3),type:y}),ut.__filtered__=ut.__filtered__||D,ut}}),Ji(["head","last"],function(r,h){var y="take"+(h?"Right":"");_i.prototype[r]=function(){return this[y](1).value()[0]}}),Ji(["initial","tail"],function(r,h){var y="drop"+(h?"":"Right");_i.prototype[r]=function(){return this.__filtered__?new _i(this):this[y](1)}}),_i.prototype.compact=function(){return this.filter(Gr)},_i.prototype.find=function(r){return this.filter(r).head()},_i.prototype.findLast=function(r){return this.reverse().find(r)},_i.prototype.invokeMap=ae(function(r,h){return typeof r=="function"?new _i(this):this.map(function(y){return e(y,r,h)})}),_i.prototype.reject=function(r){return this.filter(Ju(si(r)))},_i.prototype.slice=function(r,h){r=wi(r);var y=this;return y.__filtered__&&(r>0||h<0)?new _i(y):(r<0?y=y.takeRight(-r):r&&(y=y.drop(r)),h!==o&&(h=wi(h),y=h<0?y.dropRight(-h):y.take(h-r)),y)},_i.prototype.takeRightWhile=function(r){return this.reverse().takeWhile(r).reverse()},_i.prototype.toArray=function(){return this.take(It)},Nr(_i.prototype,function(r,h){var y=/^(?:filter|find|map|reject)|While$/.test(h),D=/^(?:head|last)$/.test(h),Y=it[D?"take"+(h=="last"?"Right":""):h],ut=D||/^find/.test(h);Y&&(it.prototype[h]=function(){var yt=this.__wrapped__,bt=D?[1]:arguments,Bt=yt instanceof _i,oe=bt[0],le=Bt||vi(yt),de=function(Ri){var Ui=Y.apply(it,fo([Ri],bt));return D&&ke?Ui[0]:Ui};le&&y&&typeof oe=="function"&&oe.length!=1&&(Bt=le=!1);var ke=this.__chain__,Ze=!!this.__actions__.length,hi=ut&&!ke,Mi=Bt&&!Ze;if(!ut&&le){yt=Mi?yt:new _i(this);var ui=r.apply(yt,bt);return ui.__actions__.push({func:Xu,args:[de],thisArg:o}),new qn(ui,ke)}return hi&&Mi?r.apply(this,bt):(ui=this.thru(de),hi?D?ui.value()[0]:ui.value():ui)})}),Ji(["pop","push","shift","sort","splice","unshift"],function(r){var h=On[r],y=/^(?:push|sort|unshift)$/.test(r)?"tap":"thru",D=/^(?:pop|shift)$/.test(r);it.prototype[r]=function(){var Y=arguments;if(D&&!this.__chain__){var ut=this.value();return h.apply(vi(ut)?ut:[],Y)}return this[y](function(yt){return h.apply(vi(yt)?yt:[],Y)})}}),Nr(_i.prototype,function(r,h){var y=it[h];if(y){var D=y.name+"";Ti.call(os,D)||(os[D]=[]),os[D].push({name:h,func:y})}}),os[$i(o,w).name]=[{name:"wrapper",func:o}],_i.prototype.clone=Ca,_i.prototype.reverse=Ou,_i.prototype.value=Aa,it.prototype.at=fv,it.prototype.chain=dv,it.prototype.commit=pv,it.prototype.next=mv,it.prototype.plant=vv,it.prototype.reverse=yv,it.prototype.toJSON=it.prototype.valueOf=it.prototype.value=_v,it.prototype.first=it.prototype.head,rs&&(it.prototype[rs]=gv),it},is=Xc();Zr?((Zr.exports=is)._=is,Jo._=is):gn._=is}).call(Er)}(lu,lu.exports);var am=lu.exports;const ec=tc(am);class lm{constructor(a=[],o=!1){Ho(this,"simplifyFunc",a=>{try{a=turf.simplify(a,{tolerance:5e-4,highQuality:!1,mutate:!0})}catch{}return a});mars3d&&(this.vectorArr=a,this.geoJsonType=new Map([["Point"],["LineString"],["Polygon"],["MultiPoint"],["MultiLineString"],["MultiPolygon"]]),this.avoidanceArr=[],this.editDate={id:""},this.isDynamicMasking=o,this.disabled=!1)}remove(a,o=null){o&&o.isClone=="true"?window.mapClone.mapEx.removeLayer(window.mapClone.mapEx.getLayer(a,"vectorId")):(window.map.removeLayer(window.map.getLayer(a,"vectorId")),window.dynamicMasking&&window.dynamicMasking.remove(a))}add(a,o){return new Promise((c,f)=>{let u,m=o==null?void 0:o.isClone;if(typeof a!="object"){let g=window.map.getLayer(a,"vectorId");if(g)return c(g);u=this.query(a)}else{let g=window.map.getLayer(a.id,"vectorId");if(g)return c(g);u=a}if(u){let{value:g,url:v,id:S,title:b}=u;new Cesium.Resource({url:v}).fetchJson().then(k=>{let{id:I,title:F,shpInfo:E}=u,{attributes:P,geometryType:w,geometryCount:M,pointCount:R}=E;if(P){let{width:C,materialType:U,materialOptions:N,clampToGround:X,distanceDisplayCondition:J,distanceDisplayCondition_near:Z,distanceDisplayCondition_far:ct,zIndex:Rt,label:tt,fill:_t,diffHeight:G,outline:Pt,outlineStyle:Et,color:At,pixelSize:ce,outlineColor:re,outlineWidth:Ft,classificationType:It,setHeight:Nt}=JSON.parse(P),Pe;switch(tt.height==""&&(tt.height=null),this.isDynamicMasking?(tt.color=Cesium.Color.fromCssColorString(tt.color).withAlpha(0),tt.outlineColor=Cesium.Color.fromCssColorString(tt.outlineColor).withAlpha(.001),tt.backgroundColor=Cesium.Color.fromCssColorString(tt.backgroundColor).withAlpha(.001),tt.background=!1,tt.outline=!1,tt.show=!1):(tt.color=Cesium.Color.fromCssColorString(tt.color),tt.outlineColor=Cesium.Color.fromCssColorString(tt.outlineColor),tt.backgroundColor=Cesium.Color.fromCssColorString(tt.backgroundColor)),w){case"LineString":case"MultiLineString":tt.backgroundPadding=5,Pe=new mars3d.layer.GeoJsonLayer({data:k,vectorId:I,symbol:{type:"polylineC",styleOptions:{width:C,clampToGround:X,distanceDisplayCondition:J,distanceDisplayCondition_far:ct,distanceDisplayCondition_near:Z,materialType:U,materialOptions:N,classificationType:It,setHeight:Nt,label:tt}},hasZIndex:!0,zIndex:Rt});break;case"Polygon":case"MultiPolygon":U=="PolyGrass"&&(N={evenColor:new Cesium.Color(.25,.4,.1,1),oddColor:new Cesium.Color(.1,.1,.1,1),frequency:1.5}),Pe=new mars3d.layer.GeoJsonLayer({data:k,vectorId:I,symbol:{type:"polygon",styleOptions:{fill:_t,diffHeight:G,clampToGround:X,materialType:U,materialOptions:N,distanceDisplayCondition:J,distanceDisplayCondition_far:ct,distanceDisplayCondition_near:Z,outlineStyle:Et,outline:Pt,classificationType:It,setHeight:Nt,label:tt}}});break;case"Point":case"MultiPoint":Pe=new mars3d.layer.GeoJsonLayer({data:k,vectorId:I,symbol:{type:"pointC",styleOptions:{color:At,pixelSize:ce,outline:Pt,outlineColor:re,outlineWidth:Ft,visibleDepth:!1,label:tt}}});break}m?window.mapClone.mapEx.addLayer(Pe):window.map.addLayer(Pe),Pe.bindPopup(Wt=>{if(this.disabled==!0)return!1;let $e='<div class="bim-map-popup">';return Object.keys(Wt.graphic.attr).forEach((Si,Oe)=>{Wt.graphic.attr[Si]&&($e+=`<p><b>${Si}</b> : ${Wt.graphic.attr[Si]}</p>`)}),$e+="</div>",$e});let pe=ec.debounce(Wt=>{window.dynamicMasking.add(Wt,JSON.parse(P))},500);Pe.readyPromise.then(Wt=>{window.dynamicMasking&&pe(Wt),c(Wt)}).catch(Wt=>{c({tite:"【矢量】「"+F+"」无法加载",type:"error",id:I,url:v})})}else c({tite:"【矢量】「"+F+"」无法加载",type:"error",id:I,url:v})}).catch(k=>{c({tite:"【矢量】「"+b+"」链接地址有误",type:"error",id:S,url:v})})}else c({tite:"【矢量】ID:「"+a+"」已删除",type:"error",id:a})})}updateData(a){this.vectorArr=a}processingKML(a){let o,c=2e3,f=!0,{kmlInfo:u}=a,{fill:m,areaColor:g,areaSideColor:v,transparency:S,isAreaSideColor:b,minDistinct:O,textDistinct:k,textSize:I,textColor:F,fontStyle:E,outLine:P,sideColor:w,backGround:M,backGroundColor:R,clampToGround:C}=u,U={fill:m,color:g,opacity:S||.5,outline:b,outlineColor:v,outlineWidth:2,clampToGround:C,distanceDisplayCondition:!0,distanceDisplayCondition_far:k||1e6,distanceDisplayCondition_near:O||0,classificationType:o,opacity:String(S)},N={text:"{name}",horizontalOrigin:Cesium.HorizontalOrigin.CENTER,verticalOrigin:Cesium.VerticalOrigin.BOTTOM,pixelOffsetY:-10,font_size:26,color:F||"#ffffff",font_family:E||"黑体",outline:P||!0,outlineColor:w||"#000000",outlineWidth:4,scaleByDistance:!0,distanceDisplayCondition:!0,distanceDisplayCondition_far:k||1e6,distanceDisplayCondition_near:O||0,background:M||!1,backgroundColor:R||"",visibleDepth:f,clampToGround:C||!1,disableDepthTestDistance:c};return{...U,label:N}}selected(a){window.map.getLayer(a,"vectorId")&&window.map.getLayer(a,"vectorId").flyTo()}query(a){return this.vectorArr.length==0?!1:this.vectorArr.find(o=>o.id==a)}queryVector(a){return window.map.getLayer(a,"vectorId")}editVector(a,o,c){let f=window.map.getLayer(a,"vectorId"),u=bf(o,c);f&&(f.eachGraphic(m=>{m.label&&m.label.show===!1&&(delete m.label.outline,delete m.label.background,delete m.label.outlineColor,delete m.label.backgroundColor),u.label&&u.label.height==""&&(u.label.height=null),m.setStyle({...u})}),window.dynamicMasking&&dynamicMasking.modify(a,u))}nationalBoundaries(a="/gis/nationalBoundaries.json"){let o=new mars3d.layer.GeoJsonLayer({name:"国界",url:a,vectorId:"border",format:c=>{try{c=turf.simplify(c,{tolerance:1e-5,highQuality:!1,mutate:!0})}catch{}return c},symbol:{type:"polylineC",styleOptions:{width:2,materialType:"Color",materialOptions:{color:"#CD9B1D"},distanceDisplayCondition:!0,distanceDisplayCondition_near:1e3,distanceDisplayCondition_far:2e7,clampToGround:!0,classificationType:Cesium.ClassificationType.TERRAIN}}});map.addLayer(o)}switchDynamicMasking(a){this.isDynamicMasking=a}}class hm{constructor(a=[]){mars3d&&(this.terrainProviderArr=a,this.terrainProviderId="",this.events={},window.map.on(mars3d.EventType.terrainLoadError,o=>{this.hide()}),window.map.viewer.scene.globe.tileLoadProgressEvent.addEventListener(o=>{window.map.viewer.scene.globe.tilesLoaded&&this.emit("load",o)}))}add(a,o){if(o==null?void 0:o.isClone)mapClone&&(window.mapClone.mapEx.terrainProvider=window.map.terrainProvider);else{let f,u;if(typeof a=="string"?(f=a,u=this.terrainProviderArr.find(m=>m.id==f).url):(f=a.id,u=a.url),this.terrainProviderId==f&&window.map.terrainProvider._layers)return!1;window.map.terrainProvider=mars3d.LayerUtil.createTerrainProvider({imageXyzId:f,type:"xyz",url:u,requestVertexNormals:!0,requestMetadata:!0,clip:!0,flat:!0,uplift:!0,flood:!0}),this.terrainProviderId=f}}show(a){(a==null?void 0:a.isClone)?window.mapClone.mapEx.hasTerrain=!0:window.map.hasTerrain=!0}hide(a){(a==null?void 0:a.isClone)?window.mapClone.mapEx.hasTerrain=!1:window.map.hasTerrain=!1}on(a,o){a=="load"&&(this.events[a]?this.events[a].push(o):this.events[a]=[o])}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}once(a,o){const c=()=>{o(),this.off(a,c)};this.on(a,c)}addClip(a){return new Promise((o,c)=>{window.bimClip?o(bimClip.clipGisAdd(a)):c("挖洞工具未初始化")})}}class um{constructor(a=[],o){mars3d&&(this.elevationImageArr=a,this.elevationImageLayer,o?this.gisTkone={Authorization:`Bearer ${o}`}:this.gisTkone={},this.form={brightnessVal:1.3,msaaSamples:4,surfaceOpacity:1,layerOpacity:1,layerBrightness:2,layerContrast:1,layerHue:0,layerSaturation:1,layerGamma:1},this.tdtLayer=null)}pushVector(a){this.elevationImageArr.push(a)}add(a,o=!0,c){let f;if(typeof a!="object"?f=a:f=a.imageXyzId,window.map.getLayer(f,"imageXyzId"))return!1;const{layerOpacity:u,layerBrightness:m,layerContrast:g,layerHue:v,layerSaturation:S,layerGamma:b,surfaceOpacity:O}=this.exposureEnvironmentSettings();return new Promise((k,I)=>{let F,E,P,w,M,R;if(typeof a!="object"){let C=this.query(a);C||I("缺少树结构");let{gisInfo:U}=C,{id:N,order:X,minLevel:J,maxLevel:Z}=U||C;F=N,P=X,E=C.url,w=J,M=Z}else F=a.imageXyzId,E=a.url,P=a.zIndex,w=a.minimumLevel,M=a.maximumLevel,R=a.chinaCRS;this.elevationImageLayer=new mars3d.layer.XyzLayer({imageXyzId:F,type:"xyz",url:E,hasZIndex:!0,zIndex:P.toString(),brightness:m,opacity:u,saturation:S,contrast:g,hue:v,gamma:b,alpha:O,show:!0,minimumLevel:w||0,maximumLevel:M||15,chinaCRS:R,headers:o?this.gisTkone:null}),this.elevationImageLayer.on(mars3d.EventType.load,C=>{k(C)}),window.map.addLayer(this.elevationImageLayer),c&&Object.keys(c).forEach(C=>{this.elevationImageLayer.on(fnType.get(C),U=>{c[C](U)})})})}remove(a){window.map.removeLayer(window.map.getLayer(a,"imageXyzId"))}query(a){return this.elevationImageArr.length==0?!1:this.elevationImageArr.find(o=>o.id==a)}initial(){this.elevationImageArr=[],this.elevationImageLayer=null}exposureEnvironmentSettings(){return localStorage.getItem("environmentSettings")?JSON.parse(localStorage.getItem("environmentSettings")):(localStorage.setItem("environmentSettings",JSON.stringify(this.form)),JSON.parse(JSON.stringify(this.form)))}}class cm{constructor(a,...o){Ho(this,"manualFreed",ec.debounce(()=>{let{lng:a,lat:o,alt:c,pitch:f}=window.map.getCameraView(),u;this.modelArray.forEach(m=>{u=m.releasedDistance?m.releasedDistance:1e4,this.disTance([a,o,c],[m.center._lng,m.center._lat,m.center._alt],this.calculateDistance(f,u))?window.map.getLayer(m.id,"modelId")&&this.emit("leave",m):window.map.getLayer(m.id,"modelId")||this.emit("enter",m)})},200));mars3d&&(a&&a!=null&&(this.modelArray=a),this.showModelArray=[],this.Cesium=mars3d.Cesium,this.events={})}on(a,o){(a=="enter"||a=="leave")&&(this.events[a]?this.events[a].push(o):this.events[a]=[o])}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}once(a,o){const c=()=>{o(),this.off(a,c)};this.on(a,c)}say(a){return this[a]}add(a,o){this[a].push(o)}remove(a,o){this[a]=this[a].filter(function(c){return c!==o})}initial(){this.modelArray=[],this.events={}}updateCustomExcavationDetails(a,o,c,f=[],u={}){let m,g,v;switch(m=this.modelArray.find(S=>S.modelId==a).customize.bimModelExcavationDetails,v=m.find((S,b)=>{if(S.id==o)return g=b,S}),c){case"delete":m.splice(g,1);break;case"update":v.excavationDetails=f;break;case"add":m.push(u);break;case"edit":v.excavationDetails=u.excavationDetails,v.kId=u.kId;break}return m}resourceRelease(){window.map.viewer.camera.moveEnd.addEventListener(()=>{this.freed()})}freed(){let{alt:a}=window.map.getCameraView();a<2e4&&(this.freed=ec.throttle(()=>{let{lng:o,lat:c,alt:f,pitch:u}=window.map.getCameraView();this.modelArray&&this.modelArray.forEach(m=>{let g=m.bimModel.releasedDistance?m.bimModel.releasedDistance:1e4;m.center&&this.disTance([o,c,f],[m.center._lng,m.center._lat,m.center._alt],this.calculateDistance(u,g))?window.map.getLayer(m.id,"modelId")&&this.emit("leave",m):this.showModelArray.indexOf(m.id)>=0&&!window.map.getLayer(m.id,"modelId")&&this.emit("enter",m)})},2e3),this.freed())}findPnodeId(a,o,c="id"){let f;if(a){for(var u=0;u<a.length;u++){let m=a[u];if(m[c]==o)return f=m,f;if(m.children&&m.children.length>0&&(f=this.findPnodeId(m.children,o,c),f))return f}return f}}disTance(a,o,c){let f,u,m;return f=Cesium.Cartesian3.fromDegrees(...a),u=Cesium.Cartesian3.fromDegrees(...o),m=Cesium.Cartesian3.distance(f,u),m>c}calculateDistance(a,o){let c=(a+180)%360-180;c=Math.max(-90,Math.min(c,90));let f=(o-o/5)*(Math.abs(c)/90)+o/5;return Math.round(f)}}class fm{constructor(a=[],o){mars3d&&(this.entityArr=a,this.entityLayer=new mars3d.layer.GraphicLayer({entityId:"bimEntity"}),window.map.addLayer(this.entityLayer),this.entityItem=null,this.events={},this.entityCloneLayer)}on(a,o){(a=="change"||a=="collection")&&(this.events[a]?this.events[a].push(o):this.events[a]=[o])}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}offAll(){this.events={}}once(a,o){const c=()=>{o(),this.off(a,c)};this.on(a,c)}add(a,o=null,c){return new Promise((f,u)=>{var m;if(this.entityLayer){let g,v,S;if(c==null?void 0:c.isClone)this.entityCloneLayer&&(v=this.query(a),v?(S=v.bimPlanPainting?JSON.parse(v.bimPlanPainting.graphic):JSON.parse(v.graphic),S.attr=S.attr||{},S.attr.entityId=a,this.entityCloneLayer.addGraphic(S)):f({tite:"【标绘】 ID:「"+a+"」已删除",type:"error",id:a}));else{if(typeof a!="object"?(g=this.entityLayer.getGraphicByAttr(a,"entityId"),v=this.query(a),v?(S=v.bimPlanPainting?JSON.parse(v.bimPlanPainting.graphic):JSON.parse(v.graphic),S.attr=S.attr||{},S.attr.entityId=a):f({tite:"【标绘】ID:「"+a+"」已删除",type:"error",id:a})):(g=this.entityLayer.getGraphicByAttr(a.id,"entityId"),S=JSON.parse(JSON.stringify(a)),S.attr=S.attr||{},S.attr.entityId=S.attr.entityId||o,S.attr==null?S.attr={entityId:a.id}:((m=S.attr)==null?void 0:m.entityId)==null&&o&&(S.attr.entityId=o)),g)return f();this.entityLayer.addGraphic(S),f(S)}}else f()})}query(a){return this.entityArr.length==0?!1:this.entityArr.find(o=>o.id==a)}queryEntity(a){if(bimEntity.entityLayer)return bimEntity.entityLayer.getGraphicByAttr(a,"entityId")}selected(a,o=null){let c=this.entityLayer.getGraphicByAttr(a,"entityId");o==null||o.isClone,(c.options.type=="div"||c.options.type=="point")&&c._point?c.flyTo({radius:c._point._alt+500<500?5e3:c._point._alt+500}):c.flyTo()}remove(a,o=null){var f,u;(o==null?void 0:o.isClone)?this.entityCloneLayer&&((f=this.entityCloneLayer.getGraphicByAttr(a,"entityId"))==null||f.remove()):this.entityLayer.getGraphicByAttr(a,"entityId")&&((u=this.entityLayer.getGraphicByAttr(a,"entityId"))==null||u.remove(),this.entityItem&&(this.entityItem._state=="destroy"||this.entityItem.options.attr.entityId==a)&&(this.entityItem=null))}entityCloneLayerInit(){(this.entityCloneLayer==null||this.entityCloneLayer.state=="destroy")&&(this.entityCloneLayer=window.mapClone._mapEx.getLayer("bimEntity","entityId"))}entityCloneLayerRemove(){this.entityCloneLayer.remove(),this.entityCloneLayer=null}removeEntityItem(){this.entityItem=null}updateData(a){this.entityArr=a}startDrawGraphic(a){return new Promise((o,c)=>{let{type:f,style:u}=a;if(a.drawShow=!1,f=="div")if(u.html)this.entityLayer.startDraw(a).then(m=>{setTimeout(()=>{this.entityItem=m,this.entityLayer.startEditing(m)},500)});else{let{title:m,divType:g,theme_color:v,font_color:S,scaleByDistance:b,scaleByDistance_far:O,scaleByDistance_farValue:k,scaleByDistance_near:I,scaleByDistance_nearValue:F,distanceDisplayCondition:E,distanceDisplayCondition_far:P,distanceDisplayCondition_near:w,clampToGround:M}=u,R={type:"div",style:{pointerEvents:!0,scaleByDistance:b,scaleByDistance_far:O,scaleByDistance_farValue:k,scaleByDistance_near:I,scaleByDistance_nearValue:F,distanceDisplayCondition:E,distanceDisplayCondition_far:P,distanceDisplayCondition_near:w,clampToGround:M,horizontalOrigin:Cesium.HorizontalOrigin.LEFT,verticalOrigin:Cesium.VerticalOrigin.BOTTOM}};switch(g){case"1":R.style.html=`<div class="entity-div-style entity-div-style1" style="--theme-color1:${v};--theme-font-color1:${S};">
|
|
2637
2637
|
<div class="title">${m}</div>
|
|
2638
2638
|
</div>`,R.style.horizontalOrigin=Cesium.HorizontalOrigin.CENTER;break}this.entityLayer.startDraw(R).then(C=>{setTimeout(()=>{this.entityItem=C,this.entityLayer.startEditing(C),o(C)},500)})}else a.type.type=="polylineP"&&a.style.materialType=="Color"&&a.style.depthFail==!0&&(a.style.depthFailColor=a.style.materialOptions.color),this.entityLayer.startDraw(a).then(m=>{setTimeout(()=>{this.entityItem=m,this.entityLayer.startEditing(m),o(m)},500)})})}stopDraw(a=!0){this.entityLayer&&this.entityLayer.clearDrawing(),a&&this.entityItem&&(this.entityItem.stopEditing(),this.entityItem.remove(),this.entityItem=null)}updateEntityItem(a){let o=this.entityLayer.getGraphicByAttr(a,"entityId");o?this.entityItem=o:this.removeEntityItem()}edit(a,o,c,f){let u=bf(o,c);if(o.vectorStyle&&this.entityItem)if(o.vectorStyle.divType==5)this.entityItem.setStyle({...u,horizontalOrigin:Cesium.HorizontalOrigin.LEFT});else{if(this.entityItem.type=="circleP"&&Object.keys(u).length==1&&Object.keys(u)[0]=="radius"&&u.radius==this.entityItem.options.style.radius)return!1;this.entityItem.setStyle({...u,horizontalOrigin:Cesium.HorizontalOrigin.CENTER})}}enableDragging(a=!0){a?this.entityLayer.startEditing(this.entityItem):(this.entityLayer.stopDraw(),this.entityItem&&this.entityItem.stopEditing())}addRightMenu(){this.entityLayer.bindContextMenu([{text:"编辑对象",callback:a=>{this.emit("change",a)}},{text:"收藏对象",callback:a=>{this.emit("collection",a)}}])}removeRightMenu(){this.entityLayer.hasContextMenu()&&this.entityLayer.unbindContextMenu()}processDivData(a){let o={"--theme-color1":"theme_color","--theme-font-color1":"font_color","--theme-color2":"theme_color2","--theme-color3":"theme_color3"},c={title:"",theme_color:"",font_color:"",content:"",divType:"",divStyle:{},isMirror:!1};const f=document.createElement("div");f.innerHTML=a;const u=f.querySelector(".entity-div-style");return Object.keys(o).forEach(m=>{m=="--theme-color2"||m=="--theme-color3"?c.divStyle[o[m]]=u.style.getPropertyValue(m)||"#fff":c[o[m]]=u.style.getPropertyValue(m)}),c.title=u.querySelector(".title")?u.querySelector(".title").innerText:"标题",c.content=u.querySelector(".content")?u.querySelector(".content").innerText:"内容",c.divType=u.classList[1]?u.classList[1].replace("entity-div-style",""):"",c.isMirror=u.classList.contains("isMirror"),c}updateHtml(a,o){let{theme_color:c,font_color:f,title:u,content:m,divStyle:g}=o,{theme_color2:v,theme_color3:S}=g,b="";switch(a){case"1":b=`<div class="entity-div-style entity-div-style1" style="--theme-color1:${c};--theme-font-color1:${f};">
|
|
2639
2639
|
<div class="title">${u}</div>
|
|
@@ -2682,8 +2682,8 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
2682
2682
|
|
|
2683
2683
|
JSZip uses the library pako released under the MIT license :
|
|
2684
2684
|
https://github.com/nodeca/pako/blob/main/LICENSE
|
|
2685
|
-
*/(function(x,a){(function(o){x.exports=o()})(function(){return function o(c,f,u){function m(S,b){if(!f[S]){if(!c[S]){var O=typeof hu=="function"&&hu;if(!b&&O)return O(S,!0);if(g)return g(S,!0);var k=new Error("Cannot find module '"+S+"'");throw k.code="MODULE_NOT_FOUND",k}var I=f[S]={exports:{}};c[S][0].call(I.exports,function(
|
|
2686
|
-
\0`,pe+=u(It,2),pe+=F.magic,pe+=u(R,2),pe+=u(C,2),pe+=u(Ft.crc32,4),pe+=u(Ft.compressedSize,4),pe+=u(Ft.uncompressedSize,4),pe+=u(K.length,2),pe+=u(Pt.length,2),{fileRecord:O.LOCAL_FILE_HEADER+pe+K+Pt,dirRecord:O.CENTRAL_FILE_HEADER+u(Pe,2)+pe+u(Rt.length,2)+"\0\0\0\0"+u(Nt,4)+u(P,4)+K+Pt+Rt}}var g=o("../utils"),v=o("../stream/GenericWorker"),S=o("../utf8"),b=o("../crc32"),O=o("../signature");function k(I,N,E,P){v.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=N,this.zipPlatform=E,this.encodeFileName=P,this.streamFiles=I,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}g.inherits(k,v),k.prototype.push=function(I){var N=I.meta.percent||0,E=this.entriesCount,P=this._sources.length;this.accumulate?this.contentBuffer.push(I):(this.bytesWritten+=I.data.length,v.prototype.push.call(this,{data:I.data,meta:{currentFile:this.currentFile,percent:E?(N+100*(E-P-1))/E:100}}))},k.prototype.openedSource=function(I){this.currentSourceOffset=this.bytesWritten,this.currentFile=I.file.name;var N=this.streamFiles&&!I.file.dir;if(N){var E=m(I,N,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:E.fileRecord,meta:{percent:0}})}else this.accumulate=!0},k.prototype.closedSource=function(I){this.accumulate=!1;var N=this.streamFiles&&!I.file.dir,E=m(I,N,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(E.dirRecord),N)this.push({data:function(P){return O.DATA_DESCRIPTOR+u(P.crc32,4)+u(P.compressedSize,4)+u(P.uncompressedSize,4)}(I),meta:{percent:100}});else for(this.push({data:E.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},k.prototype.flush=function(){for(var I=this.bytesWritten,N=0;N<this.dirRecords.length;N++)this.push({data:this.dirRecords[N],meta:{percent:100}});var E=this.bytesWritten-I,P=function(w,M,R,C,U){var F=g.transformTo("string",U(C));return O.CENTRAL_DIRECTORY_END+"\0\0\0\0"+u(w,2)+u(w,2)+u(M,4)+u(R,4)+u(F.length,2)+F}(this.dirRecords.length,E,I,this.zipComment,this.encodeFileName);this.push({data:P,meta:{percent:100}})},k.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},k.prototype.registerPrevious=function(I){this._sources.push(I);var N=this;return I.on("data",function(E){N.processChunk(E)}),I.on("end",function(){N.closedSource(N.previous.streamInfo),N._sources.length?N.prepareNextSource():N.end()}),I.on("error",function(E){N.error(E)}),this},k.prototype.resume=function(){return!!v.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},k.prototype.error=function(I){var N=this._sources;if(!v.prototype.error.call(this,I))return!1;for(var E=0;E<N.length;E++)try{N[E].error(I)}catch{}return!0},k.prototype.lock=function(){v.prototype.lock.call(this);for(var I=this._sources,N=0;N<I.length;N++)I[N].lock()},c.exports=k},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(o,c,f){var u=o("../compressions"),m=o("./ZipFileWorker");f.generateWorker=function(g,v,S){var b=new m(v.streamFiles,S,v.platform,v.encodeFileName),O=0;try{g.forEach(function(k,I){O++;var N=function(M,R){var C=M||R,U=u[C];if(!U)throw new Error(C+" is not a valid compression method !");return U}(I.options.compression,v.compression),E=I.options.compressionOptions||v.compressionOptions||{},P=I.dir,w=I.date;I._compressWorker(N,E).withStreamInfo("file",{name:k,dir:P,date:w,comment:I.comment||"",unixPermissions:I.unixPermissions,dosPermissions:I.dosPermissions}).pipe(b)}),b.entriesCount=O}catch(k){b.error(k)}return b}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(o,c,f){function u(){if(!(this instanceof u))return new u;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var m=new u;for(var g in this)typeof this[g]!="function"&&(m[g]=this[g]);return m}}(u.prototype=o("./object")).loadAsync=o("./load"),u.support=o("./support"),u.defaults=o("./defaults"),u.version="3.10.1",u.loadAsync=function(m,g){return new u().loadAsync(m,g)},u.external=o("./external"),c.exports=u},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(o,c,f){var u=o("./utils"),m=o("./external"),g=o("./utf8"),v=o("./zipEntries"),S=o("./stream/Crc32Probe"),b=o("./nodejsUtils");function O(k){return new m.Promise(function(I,N){var E=k.decompressed.getContentWorker().pipe(new S);E.on("error",function(P){N(P)}).on("end",function(){E.streamInfo.crc32!==k.decompressed.crc32?N(new Error("Corrupted zip : CRC32 mismatch")):I()}).resume()})}c.exports=function(k,I){var N=this;return I=u.extend(I||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:g.utf8decode}),b.isNode&&b.isStream(k)?m.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):u.prepareContent("the loaded zip file",k,!0,I.optimizedBinaryString,I.base64).then(function(E){var P=new v(I);return P.load(E),P}).then(function(E){var P=[m.Promise.resolve(E)],w=E.files;if(I.checkCRC32)for(var M=0;M<w.length;M++)P.push(O(w[M]));return m.Promise.all(P)}).then(function(E){for(var P=E.shift(),w=P.files,M=0;M<w.length;M++){var R=w[M],C=R.fileNameStr,U=u.resolve(R.fileNameStr);N.file(U,R.decompressed,{binary:!0,optimizedBinaryString:!0,date:R.date,dir:R.dir,comment:R.fileCommentStr.length?R.fileCommentStr:null,unixPermissions:R.unixPermissions,dosPermissions:R.dosPermissions,createFolders:I.createFolders}),R.dir||(N.file(U).unsafeOriginalName=C)}return P.zipComment.length&&(N.comment=P.zipComment),N})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(o,c,f){var u=o("../utils"),m=o("../stream/GenericWorker");function g(v,S){m.call(this,"Nodejs stream input adapter for "+v),this._upstreamEnded=!1,this._bindStream(S)}u.inherits(g,m),g.prototype._bindStream=function(v){var S=this;(this._stream=v).pause(),v.on("data",function(b){S.push({data:b,meta:{percent:0}})}).on("error",function(b){S.isPaused?this.generatedError=b:S.error(b)}).on("end",function(){S.isPaused?S._upstreamEnded=!0:S.end()})},g.prototype.pause=function(){return!!m.prototype.pause.call(this)&&(this._stream.pause(),!0)},g.prototype.resume=function(){return!!m.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},c.exports=g},{"../stream/GenericWorker":28,"../utils":32}],13:[function(o,c,f){var u=o("readable-stream").Readable;function m(g,v,S){u.call(this,v),this._helper=g;var b=this;g.on("data",function(O,k){b.push(O)||b._helper.pause(),S&&S(k)}).on("error",function(O){b.emit("error",O)}).on("end",function(){b.push(null)})}o("../utils").inherits(m,u),m.prototype._read=function(){this._helper.resume()},c.exports=m},{"../utils":32,"readable-stream":16}],14:[function(o,c,f){c.exports={isNode:typeof Buffer<"u",newBufferFrom:function(u,m){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(u,m);if(typeof u=="number")throw new Error('The "data" argument must not be a number');return new Buffer(u,m)},allocBuffer:function(u){if(Buffer.alloc)return Buffer.alloc(u);var m=new Buffer(u);return m.fill(0),m},isBuffer:function(u){return Buffer.isBuffer(u)},isStream:function(u){return u&&typeof u.on=="function"&&typeof u.pause=="function"&&typeof u.resume=="function"}}},{}],15:[function(o,c,f){function u(U,F,X){var K,Z=g.getTypeOf(F),ct=g.extend(X||{},b);ct.date=ct.date||new Date,ct.compression!==null&&(ct.compression=ct.compression.toUpperCase()),typeof ct.unixPermissions=="string"&&(ct.unixPermissions=parseInt(ct.unixPermissions,8)),ct.unixPermissions&&16384&ct.unixPermissions&&(ct.dir=!0),ct.dosPermissions&&16&ct.dosPermissions&&(ct.dir=!0),ct.dir&&(U=w(U)),ct.createFolders&&(K=P(U))&&M.call(this,K,!0);var Rt=Z==="string"&&ct.binary===!1&&ct.base64===!1;X&&X.binary!==void 0||(ct.binary=!Rt),(F instanceof O&&F.uncompressedSize===0||ct.dir||!F||F.length===0)&&(ct.base64=!1,ct.binary=!0,F="",ct.compression="STORE",Z="string");var tt=null;tt=F instanceof O||F instanceof v?F:N.isNode&&N.isStream(F)?new E(U,F):g.prepareContent(U,F,ct.binary,ct.optimizedBinaryString,ct.base64);var _t=new k(U,tt,ct);this.files[U]=_t}var m=o("./utf8"),g=o("./utils"),v=o("./stream/GenericWorker"),S=o("./stream/StreamHelper"),b=o("./defaults"),O=o("./compressedObject"),k=o("./zipObject"),I=o("./generate"),N=o("./nodejsUtils"),E=o("./nodejs/NodejsStreamInputAdapter"),P=function(U){U.slice(-1)==="/"&&(U=U.substring(0,U.length-1));var F=U.lastIndexOf("/");return 0<F?U.substring(0,F):""},w=function(U){return U.slice(-1)!=="/"&&(U+="/"),U},M=function(U,F){return F=F!==void 0?F:b.createFolders,U=w(U),this.files[U]||u.call(this,U,null,{dir:!0,createFolders:F}),this.files[U]};function R(U){return Object.prototype.toString.call(U)==="[object RegExp]"}var C={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(U){var F,X,K;for(F in this.files)K=this.files[F],(X=F.slice(this.root.length,F.length))&&F.slice(0,this.root.length)===this.root&&U(X,K)},filter:function(U){var F=[];return this.forEach(function(X,K){U(X,K)&&F.push(K)}),F},file:function(U,F,X){if(arguments.length!==1)return U=this.root+U,u.call(this,U,F,X),this;if(R(U)){var K=U;return this.filter(function(ct,Rt){return!Rt.dir&&K.test(ct)})}var Z=this.files[this.root+U];return Z&&!Z.dir?Z:null},folder:function(U){if(!U)return this;if(R(U))return this.filter(function(Z,ct){return ct.dir&&U.test(Z)});var F=this.root+U,X=M.call(this,F),K=this.clone();return K.root=X.name,K},remove:function(U){U=this.root+U;var F=this.files[U];if(F||(U.slice(-1)!=="/"&&(U+="/"),F=this.files[U]),F&&!F.dir)delete this.files[U];else for(var X=this.filter(function(Z,ct){return ct.name.slice(0,U.length)===U}),K=0;K<X.length;K++)delete this.files[X[K].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(U){var F,X={};try{if((X=g.extend(U||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:m.utf8encode})).type=X.type.toLowerCase(),X.compression=X.compression.toUpperCase(),X.type==="binarystring"&&(X.type="string"),!X.type)throw new Error("No output type specified.");g.checkSupport(X.type),X.platform!=="darwin"&&X.platform!=="freebsd"&&X.platform!=="linux"&&X.platform!=="sunos"||(X.platform="UNIX"),X.platform==="win32"&&(X.platform="DOS");var K=X.comment||this.comment||"";F=I.generateWorker(this,X,K)}catch(Z){(F=new v("error")).error(Z)}return new S(F,X.type||"string",X.mimeType)},generateAsync:function(U,F){return this.generateInternalStream(U).accumulate(F)},generateNodeStream:function(U,F){return(U=U||{}).type||(U.type="nodebuffer"),this.generateInternalStream(U).toNodejsStream(F)}};c.exports=C},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(o,c,f){c.exports=o("stream")},{stream:void 0}],17:[function(o,c,f){var u=o("./DataReader");function m(g){u.call(this,g);for(var v=0;v<this.data.length;v++)g[v]=255&g[v]}o("../utils").inherits(m,u),m.prototype.byteAt=function(g){return this.data[this.zero+g]},m.prototype.lastIndexOfSignature=function(g){for(var v=g.charCodeAt(0),S=g.charCodeAt(1),b=g.charCodeAt(2),O=g.charCodeAt(3),k=this.length-4;0<=k;--k)if(this.data[k]===v&&this.data[k+1]===S&&this.data[k+2]===b&&this.data[k+3]===O)return k-this.zero;return-1},m.prototype.readAndCheckSignature=function(g){var v=g.charCodeAt(0),S=g.charCodeAt(1),b=g.charCodeAt(2),O=g.charCodeAt(3),k=this.readData(4);return v===k[0]&&S===k[1]&&b===k[2]&&O===k[3]},m.prototype.readData=function(g){if(this.checkOffset(g),g===0)return[];var v=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./DataReader":18}],18:[function(o,c,f){var u=o("../utils");function m(g){this.data=g,this.length=g.length,this.index=0,this.zero=0}m.prototype={checkOffset:function(g){this.checkIndex(this.index+g)},checkIndex:function(g){if(this.length<this.zero+g||g<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+g+"). Corrupted zip ?")},setIndex:function(g){this.checkIndex(g),this.index=g},skip:function(g){this.setIndex(this.index+g)},byteAt:function(){},readInt:function(g){var v,S=0;for(this.checkOffset(g),v=this.index+g-1;v>=this.index;v--)S=(S<<8)+this.byteAt(v);return this.index+=g,S},readString:function(g){return u.transformTo("string",this.readData(g))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var g=this.readInt(4);return new Date(Date.UTC(1980+(g>>25&127),(g>>21&15)-1,g>>16&31,g>>11&31,g>>5&63,(31&g)<<1))}},c.exports=m},{"../utils":32}],19:[function(o,c,f){var u=o("./Uint8ArrayReader");function m(g){u.call(this,g)}o("../utils").inherits(m,u),m.prototype.readData=function(g){this.checkOffset(g);var v=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(o,c,f){var u=o("./DataReader");function m(g){u.call(this,g)}o("../utils").inherits(m,u),m.prototype.byteAt=function(g){return this.data.charCodeAt(this.zero+g)},m.prototype.lastIndexOfSignature=function(g){return this.data.lastIndexOf(g)-this.zero},m.prototype.readAndCheckSignature=function(g){return g===this.readData(4)},m.prototype.readData=function(g){this.checkOffset(g);var v=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./DataReader":18}],21:[function(o,c,f){var u=o("./ArrayReader");function m(g){u.call(this,g)}o("../utils").inherits(m,u),m.prototype.readData=function(g){if(this.checkOffset(g),g===0)return new Uint8Array(0);var v=this.data.subarray(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./ArrayReader":17}],22:[function(o,c,f){var u=o("../utils"),m=o("../support"),g=o("./ArrayReader"),v=o("./StringReader"),S=o("./NodeBufferReader"),b=o("./Uint8ArrayReader");c.exports=function(O){var k=u.getTypeOf(O);return u.checkSupport(k),k!=="string"||m.uint8array?k==="nodebuffer"?new S(O):m.uint8array?new b(u.transformTo("uint8array",O)):new g(u.transformTo("array",O)):new v(O)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(o,c,f){f.LOCAL_FILE_HEADER="PK",f.CENTRAL_FILE_HEADER="PK",f.CENTRAL_DIRECTORY_END="PK",f.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",f.ZIP64_CENTRAL_DIRECTORY_END="PK",f.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(o,c,f){var u=o("./GenericWorker"),m=o("../utils");function g(v){u.call(this,"ConvertWorker to "+v),this.destType=v}m.inherits(g,u),g.prototype.processChunk=function(v){this.push({data:m.transformTo(this.destType,v.data),meta:v.meta})},c.exports=g},{"../utils":32,"./GenericWorker":28}],25:[function(o,c,f){var u=o("./GenericWorker"),m=o("../crc32");function g(){u.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}o("../utils").inherits(g,u),g.prototype.processChunk=function(v){this.streamInfo.crc32=m(v.data,this.streamInfo.crc32||0),this.push(v)},c.exports=g},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(o,c,f){var u=o("../utils"),m=o("./GenericWorker");function g(v){m.call(this,"DataLengthProbe for "+v),this.propName=v,this.withStreamInfo(v,0)}u.inherits(g,m),g.prototype.processChunk=function(v){if(v){var S=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=S+v.data.length}m.prototype.processChunk.call(this,v)},c.exports=g},{"../utils":32,"./GenericWorker":28}],27:[function(o,c,f){var u=o("../utils"),m=o("./GenericWorker");function g(v){m.call(this,"DataWorker");var S=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,v.then(function(b){S.dataIsReady=!0,S.data=b,S.max=b&&b.length||0,S.type=u.getTypeOf(b),S.isPaused||S._tickAndRepeat()},function(b){S.error(b)})}u.inherits(g,m),g.prototype.cleanUp=function(){m.prototype.cleanUp.call(this),this.data=null},g.prototype.resume=function(){return!!m.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,u.delay(this._tickAndRepeat,[],this)),!0)},g.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(u.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},g.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var v=null,S=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":v=this.data.substring(this.index,S);break;case"uint8array":v=this.data.subarray(this.index,S);break;case"array":case"nodebuffer":v=this.data.slice(this.index,S)}return this.index=S,this.push({data:v,meta:{percent:this.max?this.index/this.max*100:0}})},c.exports=g},{"../utils":32,"./GenericWorker":28}],28:[function(o,c,f){function u(m){this.name=m||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}u.prototype={push:function(m){this.emit("data",m)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(m){this.emit("error",m)}return!0},error:function(m){return!this.isFinished&&(this.isPaused?this.generatedError=m:(this.isFinished=!0,this.emit("error",m),this.previous&&this.previous.error(m),this.cleanUp()),!0)},on:function(m,g){return this._listeners[m].push(g),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(m,g){if(this._listeners[m])for(var v=0;v<this._listeners[m].length;v++)this._listeners[m][v].call(this,g)},pipe:function(m){return m.registerPrevious(this)},registerPrevious:function(m){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=m.streamInfo,this.mergeStreamInfo(),this.previous=m;var g=this;return m.on("data",function(v){g.processChunk(v)}),m.on("end",function(){g.end()}),m.on("error",function(v){g.error(v)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var m=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),m=!0),this.previous&&this.previous.resume(),!m},flush:function(){},processChunk:function(m){this.push(m)},withStreamInfo:function(m,g){return this.extraStreamInfo[m]=g,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var m in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,m)&&(this.streamInfo[m]=this.extraStreamInfo[m])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var m="Worker "+this.name;return this.previous?this.previous+" -> "+m:m}},c.exports=u},{}],29:[function(o,c,f){var u=o("../utils"),m=o("./ConvertWorker"),g=o("./GenericWorker"),v=o("../base64"),S=o("../support"),b=o("../external"),O=null;if(S.nodestream)try{O=o("../nodejs/NodejsStreamOutputAdapter")}catch{}function k(N,E){return new b.Promise(function(P,w){var M=[],R=N._internalType,C=N._outputType,U=N._mimeType;N.on("data",function(F,X){M.push(F),E&&E(X)}).on("error",function(F){M=[],w(F)}).on("end",function(){try{var F=function(X,K,Z){switch(X){case"blob":return u.newBlob(u.transformTo("arraybuffer",K),Z);case"base64":return v.encode(K);default:return u.transformTo(X,K)}}(C,function(X,K){var Z,ct=0,Rt=null,tt=0;for(Z=0;Z<K.length;Z++)tt+=K[Z].length;switch(X){case"string":return K.join("");case"array":return Array.prototype.concat.apply([],K);case"uint8array":for(Rt=new Uint8Array(tt),Z=0;Z<K.length;Z++)Rt.set(K[Z],ct),ct+=K[Z].length;return Rt;case"nodebuffer":return Buffer.concat(K);default:throw new Error("concat : unsupported type '"+X+"'")}}(R,M),U);P(F)}catch(X){w(X)}M=[]}).resume()})}function I(N,E,P){var w=E;switch(E){case"blob":case"arraybuffer":w="uint8array";break;case"base64":w="string"}try{this._internalType=w,this._outputType=E,this._mimeType=P,u.checkSupport(w),this._worker=N.pipe(new m(w)),N.lock()}catch(M){this._worker=new g("error"),this._worker.error(M)}}I.prototype={accumulate:function(N){return k(this,N)},on:function(N,E){var P=this;return N==="data"?this._worker.on(N,function(w){E.call(P,w.data,w.meta)}):this._worker.on(N,function(){u.delay(E,arguments,P)}),this},resume:function(){return u.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(N){if(u.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new O(this,{objectMode:this._outputType!=="nodebuffer"},N)}},c.exports=I},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(o,c,f){if(f.base64=!0,f.array=!0,f.string=!0,f.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",f.nodebuffer=typeof Buffer<"u",f.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")f.blob=!1;else{var u=new ArrayBuffer(0);try{f.blob=new Blob([u],{type:"application/zip"}).size===0}catch{try{var m=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);m.append(u),f.blob=m.getBlob("application/zip").size===0}catch{f.blob=!1}}}try{f.nodestream=!!o("readable-stream").Readable}catch{f.nodestream=!1}},{"readable-stream":16}],31:[function(o,c,f){for(var u=o("./utils"),m=o("./support"),g=o("./nodejsUtils"),v=o("./stream/GenericWorker"),S=new Array(256),b=0;b<256;b++)S[b]=252<=b?6:248<=b?5:240<=b?4:224<=b?3:192<=b?2:1;S[254]=S[254]=1;function O(){v.call(this,"utf-8 decode"),this.leftOver=null}function k(){v.call(this,"utf-8 encode")}f.utf8encode=function(I){return m.nodebuffer?g.newBufferFrom(I,"utf-8"):function(N){var E,P,w,M,R,C=N.length,U=0;for(M=0;M<C;M++)(64512&(P=N.charCodeAt(M)))==55296&&M+1<C&&(64512&(w=N.charCodeAt(M+1)))==56320&&(P=65536+(P-55296<<10)+(w-56320),M++),U+=P<128?1:P<2048?2:P<65536?3:4;for(E=m.uint8array?new Uint8Array(U):new Array(U),M=R=0;R<U;M++)(64512&(P=N.charCodeAt(M)))==55296&&M+1<C&&(64512&(w=N.charCodeAt(M+1)))==56320&&(P=65536+(P-55296<<10)+(w-56320),M++),P<128?E[R++]=P:(P<2048?E[R++]=192|P>>>6:(P<65536?E[R++]=224|P>>>12:(E[R++]=240|P>>>18,E[R++]=128|P>>>12&63),E[R++]=128|P>>>6&63),E[R++]=128|63&P);return E}(I)},f.utf8decode=function(I){return m.nodebuffer?u.transformTo("nodebuffer",I).toString("utf-8"):function(N){var E,P,w,M,R=N.length,C=new Array(2*R);for(E=P=0;E<R;)if((w=N[E++])<128)C[P++]=w;else if(4<(M=S[w]))C[P++]=65533,E+=M-1;else{for(w&=M===2?31:M===3?15:7;1<M&&E<R;)w=w<<6|63&N[E++],M--;1<M?C[P++]=65533:w<65536?C[P++]=w:(w-=65536,C[P++]=55296|w>>10&1023,C[P++]=56320|1023&w)}return C.length!==P&&(C.subarray?C=C.subarray(0,P):C.length=P),u.applyFromCharCode(C)}(I=u.transformTo(m.uint8array?"uint8array":"array",I))},u.inherits(O,v),O.prototype.processChunk=function(I){var N=u.transformTo(m.uint8array?"uint8array":"array",I.data);if(this.leftOver&&this.leftOver.length){if(m.uint8array){var E=N;(N=new Uint8Array(E.length+this.leftOver.length)).set(this.leftOver,0),N.set(E,this.leftOver.length)}else N=this.leftOver.concat(N);this.leftOver=null}var P=function(M,R){var C;for((R=R||M.length)>M.length&&(R=M.length),C=R-1;0<=C&&(192&M[C])==128;)C--;return C<0||C===0?R:C+S[M[C]]>R?C:R}(N),w=N;P!==N.length&&(m.uint8array?(w=N.subarray(0,P),this.leftOver=N.subarray(P,N.length)):(w=N.slice(0,P),this.leftOver=N.slice(P,N.length))),this.push({data:f.utf8decode(w),meta:I.meta})},O.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:f.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},f.Utf8DecodeWorker=O,u.inherits(k,v),k.prototype.processChunk=function(I){this.push({data:f.utf8encode(I.data),meta:I.meta})},f.Utf8EncodeWorker=k},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(o,c,f){var u=o("./support"),m=o("./base64"),g=o("./nodejsUtils"),v=o("./external");function S(E){return E}function b(E,P){for(var w=0;w<E.length;++w)P[w]=255&E.charCodeAt(w);return P}o("setimmediate"),f.newBlob=function(E,P){f.checkSupport("blob");try{return new Blob([E],{type:P})}catch{try{var w=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return w.append(E),w.getBlob(P)}catch{throw new Error("Bug : can't construct the Blob.")}}};var O={stringifyByChunk:function(E,P,w){var M=[],R=0,C=E.length;if(C<=w)return String.fromCharCode.apply(null,E);for(;R<C;)P==="array"||P==="nodebuffer"?M.push(String.fromCharCode.apply(null,E.slice(R,Math.min(R+w,C)))):M.push(String.fromCharCode.apply(null,E.subarray(R,Math.min(R+w,C)))),R+=w;return M.join("")},stringifyByChar:function(E){for(var P="",w=0;w<E.length;w++)P+=String.fromCharCode(E[w]);return P},applyCanBeUsed:{uint8array:function(){try{return u.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}}(),nodebuffer:function(){try{return u.nodebuffer&&String.fromCharCode.apply(null,g.allocBuffer(1)).length===1}catch{return!1}}()}};function k(E){var P=65536,w=f.getTypeOf(E),M=!0;if(w==="uint8array"?M=O.applyCanBeUsed.uint8array:w==="nodebuffer"&&(M=O.applyCanBeUsed.nodebuffer),M)for(;1<P;)try{return O.stringifyByChunk(E,w,P)}catch{P=Math.floor(P/2)}return O.stringifyByChar(E)}function I(E,P){for(var w=0;w<E.length;w++)P[w]=E[w];return P}f.applyFromCharCode=k;var N={};N.string={string:S,array:function(E){return b(E,new Array(E.length))},arraybuffer:function(E){return N.string.uint8array(E).buffer},uint8array:function(E){return b(E,new Uint8Array(E.length))},nodebuffer:function(E){return b(E,g.allocBuffer(E.length))}},N.array={string:k,array:S,arraybuffer:function(E){return new Uint8Array(E).buffer},uint8array:function(E){return new Uint8Array(E)},nodebuffer:function(E){return g.newBufferFrom(E)}},N.arraybuffer={string:function(E){return k(new Uint8Array(E))},array:function(E){return I(new Uint8Array(E),new Array(E.byteLength))},arraybuffer:S,uint8array:function(E){return new Uint8Array(E)},nodebuffer:function(E){return g.newBufferFrom(new Uint8Array(E))}},N.uint8array={string:k,array:function(E){return I(E,new Array(E.length))},arraybuffer:function(E){return E.buffer},uint8array:S,nodebuffer:function(E){return g.newBufferFrom(E)}},N.nodebuffer={string:k,array:function(E){return I(E,new Array(E.length))},arraybuffer:function(E){return N.nodebuffer.uint8array(E).buffer},uint8array:function(E){return I(E,new Uint8Array(E.length))},nodebuffer:S},f.transformTo=function(E,P){if(P=P||"",!E)return P;f.checkSupport(E);var w=f.getTypeOf(P);return N[w][E](P)},f.resolve=function(E){for(var P=E.split("/"),w=[],M=0;M<P.length;M++){var R=P[M];R==="."||R===""&&M!==0&&M!==P.length-1||(R===".."?w.pop():w.push(R))}return w.join("/")},f.getTypeOf=function(E){return typeof E=="string"?"string":Object.prototype.toString.call(E)==="[object Array]"?"array":u.nodebuffer&&g.isBuffer(E)?"nodebuffer":u.uint8array&&E instanceof Uint8Array?"uint8array":u.arraybuffer&&E instanceof ArrayBuffer?"arraybuffer":void 0},f.checkSupport=function(E){if(!u[E.toLowerCase()])throw new Error(E+" is not supported by this platform")},f.MAX_VALUE_16BITS=65535,f.MAX_VALUE_32BITS=-1,f.pretty=function(E){var P,w,M="";for(w=0;w<(E||"").length;w++)M+="\\x"+((P=E.charCodeAt(w))<16?"0":"")+P.toString(16).toUpperCase();return M},f.delay=function(E,P,w){setImmediate(function(){E.apply(w||null,P||[])})},f.inherits=function(E,P){function w(){}w.prototype=P.prototype,E.prototype=new w},f.extend=function(){var E,P,w={};for(E=0;E<arguments.length;E++)for(P in arguments[E])Object.prototype.hasOwnProperty.call(arguments[E],P)&&w[P]===void 0&&(w[P]=arguments[E][P]);return w},f.prepareContent=function(E,P,w,M,R){return v.Promise.resolve(P).then(function(C){return u.blob&&(C instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(C))!==-1)&&typeof FileReader<"u"?new v.Promise(function(U,F){var X=new FileReader;X.onload=function(K){U(K.target.result)},X.onerror=function(K){F(K.target.error)},X.readAsArrayBuffer(C)}):C}).then(function(C){var U=f.getTypeOf(C);return U?(U==="arraybuffer"?C=f.transformTo("uint8array",C):U==="string"&&(R?C=m.decode(C):w&&M!==!0&&(C=function(F){return b(F,u.uint8array?new Uint8Array(F.length):new Array(F.length))}(C))),C):v.Promise.reject(new Error("Can't read the data of '"+E+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(o,c,f){var u=o("./reader/readerFor"),m=o("./utils"),g=o("./signature"),v=o("./zipEntry"),S=o("./support");function b(O){this.files=[],this.loadOptions=O}b.prototype={checkSignature:function(O){if(!this.reader.readAndCheckSignature(O)){this.reader.index-=4;var k=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+m.pretty(k)+", expected "+m.pretty(O)+")")}},isSignature:function(O,k){var I=this.reader.index;this.reader.setIndex(O);var N=this.reader.readString(4)===k;return this.reader.setIndex(I),N},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var O=this.reader.readData(this.zipCommentLength),k=S.uint8array?"uint8array":"array",I=m.transformTo(k,O);this.zipComment=this.loadOptions.decodeFileName(I)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var O,k,I,N=this.zip64EndOfCentralSize-44;0<N;)O=this.reader.readInt(2),k=this.reader.readInt(4),I=this.reader.readData(k),this.zip64ExtensibleData[O]={id:O,length:k,value:I}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var O,k;for(O=0;O<this.files.length;O++)k=this.files[O],this.reader.setIndex(k.localHeaderOffset),this.checkSignature(g.LOCAL_FILE_HEADER),k.readLocalPart(this.reader),k.handleUTF8(),k.processAttributes()},readCentralDir:function(){var O;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(g.CENTRAL_FILE_HEADER);)(O=new v({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(O);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var O=this.reader.lastIndexOfSignature(g.CENTRAL_DIRECTORY_END);if(O<0)throw this.isSignature(0,g.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(O);var k=O;if(this.checkSignature(g.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===m.MAX_VALUE_16BITS||this.diskWithCentralDirStart===m.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===m.MAX_VALUE_16BITS||this.centralDirRecords===m.MAX_VALUE_16BITS||this.centralDirSize===m.MAX_VALUE_32BITS||this.centralDirOffset===m.MAX_VALUE_32BITS){if(this.zip64=!0,(O=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(O),this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,g.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var I=this.centralDirOffset+this.centralDirSize;this.zip64&&(I+=20,I+=12+this.zip64EndOfCentralSize);var N=k-I;if(0<N)this.isSignature(k,g.CENTRAL_FILE_HEADER)||(this.reader.zero=N);else if(N<0)throw new Error("Corrupted zip: missing "+Math.abs(N)+" bytes.")},prepareReader:function(O){this.reader=u(O)},load:function(O){this.prepareReader(O),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},c.exports=b},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(o,c,f){var u=o("./reader/readerFor"),m=o("./utils"),g=o("./compressedObject"),v=o("./crc32"),S=o("./utf8"),b=o("./compressions"),O=o("./support");function k(I,N){this.options=I,this.loadOptions=N}k.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(I){var N,E;if(I.skip(22),this.fileNameLength=I.readInt(2),E=I.readInt(2),this.fileName=I.readData(this.fileNameLength),I.skip(E),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if((N=function(P){for(var w in b)if(Object.prototype.hasOwnProperty.call(b,w)&&b[w].magic===P)return b[w];return null}(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+m.pretty(this.compressionMethod)+" unknown (inner file : "+m.transformTo("string",this.fileName)+")");this.decompressed=new g(this.compressedSize,this.uncompressedSize,this.crc32,N,I.readData(this.compressedSize))},readCentralPart:function(I){this.versionMadeBy=I.readInt(2),I.skip(2),this.bitFlag=I.readInt(2),this.compressionMethod=I.readString(2),this.date=I.readDate(),this.crc32=I.readInt(4),this.compressedSize=I.readInt(4),this.uncompressedSize=I.readInt(4);var N=I.readInt(2);if(this.extraFieldsLength=I.readInt(2),this.fileCommentLength=I.readInt(2),this.diskNumberStart=I.readInt(2),this.internalFileAttributes=I.readInt(2),this.externalFileAttributes=I.readInt(4),this.localHeaderOffset=I.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");I.skip(N),this.readExtraFields(I),this.parseZIP64ExtraField(I),this.fileComment=I.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var I=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),I==0&&(this.dosPermissions=63&this.externalFileAttributes),I==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var I=u(this.extraFields[1].value);this.uncompressedSize===m.MAX_VALUE_32BITS&&(this.uncompressedSize=I.readInt(8)),this.compressedSize===m.MAX_VALUE_32BITS&&(this.compressedSize=I.readInt(8)),this.localHeaderOffset===m.MAX_VALUE_32BITS&&(this.localHeaderOffset=I.readInt(8)),this.diskNumberStart===m.MAX_VALUE_32BITS&&(this.diskNumberStart=I.readInt(4))}},readExtraFields:function(I){var N,E,P,w=I.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});I.index+4<w;)N=I.readInt(2),E=I.readInt(2),P=I.readData(E),this.extraFields[N]={id:N,length:E,value:P};I.setIndex(w)},handleUTF8:function(){var I=O.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=S.utf8decode(this.fileName),this.fileCommentStr=S.utf8decode(this.fileComment);else{var N=this.findExtraFieldUnicodePath();if(N!==null)this.fileNameStr=N;else{var E=m.transformTo(I,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(E)}var P=this.findExtraFieldUnicodeComment();if(P!==null)this.fileCommentStr=P;else{var w=m.transformTo(I,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(w)}}},findExtraFieldUnicodePath:function(){var I=this.extraFields[28789];if(I){var N=u(I.value);return N.readInt(1)!==1||v(this.fileName)!==N.readInt(4)?null:S.utf8decode(N.readData(I.length-5))}return null},findExtraFieldUnicodeComment:function(){var I=this.extraFields[25461];if(I){var N=u(I.value);return N.readInt(1)!==1||v(this.fileComment)!==N.readInt(4)?null:S.utf8decode(N.readData(I.length-5))}return null}},c.exports=k},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(o,c,f){function u(N,E,P){this.name=N,this.dir=P.dir,this.date=P.date,this.comment=P.comment,this.unixPermissions=P.unixPermissions,this.dosPermissions=P.dosPermissions,this._data=E,this._dataBinary=P.binary,this.options={compression:P.compression,compressionOptions:P.compressionOptions}}var m=o("./stream/StreamHelper"),g=o("./stream/DataWorker"),v=o("./utf8"),S=o("./compressedObject"),b=o("./stream/GenericWorker");u.prototype={internalStream:function(N){var E=null,P="string";try{if(!N)throw new Error("No output type specified.");var w=(P=N.toLowerCase())==="string"||P==="text";P!=="binarystring"&&P!=="text"||(P="string"),E=this._decompressWorker();var M=!this._dataBinary;M&&!w&&(E=E.pipe(new v.Utf8EncodeWorker)),!M&&w&&(E=E.pipe(new v.Utf8DecodeWorker))}catch(R){(E=new b("error")).error(R)}return new m(E,P,"")},async:function(N,E){return this.internalStream(N).accumulate(E)},nodeStream:function(N,E){return this.internalStream(N||"nodebuffer").toNodejsStream(E)},_compressWorker:function(N,E){if(this._data instanceof S&&this._data.compression.magic===N.magic)return this._data.getCompressedWorker();var P=this._decompressWorker();return this._dataBinary||(P=P.pipe(new v.Utf8EncodeWorker)),S.createWorkerFrom(P,N,E)},_decompressWorker:function(){return this._data instanceof S?this._data.getContentWorker():this._data instanceof b?this._data:new g(this._data)}};for(var O=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],k=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},I=0;I<O.length;I++)u.prototype[O[I]]=k;c.exports=u},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(o,c,f){(function(u){var m,g,v=u.MutationObserver||u.WebKitMutationObserver;if(v){var S=0,b=new v(N),O=u.document.createTextNode("");b.observe(O,{characterData:!0}),m=function(){O.data=S=++S%2}}else if(u.setImmediate||u.MessageChannel===void 0)m="document"in u&&"onreadystatechange"in u.document.createElement("script")?function(){var E=u.document.createElement("script");E.onreadystatechange=function(){N(),E.onreadystatechange=null,E.parentNode.removeChild(E),E=null},u.document.documentElement.appendChild(E)}:function(){setTimeout(N,0)};else{var k=new u.MessageChannel;k.port1.onmessage=N,m=function(){k.port2.postMessage(0)}}var I=[];function N(){var E,P;g=!0;for(var w=I.length;w;){for(P=I,I=[],E=-1;++E<w;)P[E]();w=I.length}g=!1}c.exports=function(E){I.push(E)!==1||g||m()}}).call(this,typeof Er<"u"?Er:typeof self<"u"?self:typeof window<"u"?window:{})},{}],37:[function(o,c,f){var u=o("immediate");function m(){}var g={},v=["REJECTED"],S=["FULFILLED"],b=["PENDING"];function O(w){if(typeof w!="function")throw new TypeError("resolver must be a function");this.state=b,this.queue=[],this.outcome=void 0,w!==m&&E(this,w)}function k(w,M,R){this.promise=w,typeof M=="function"&&(this.onFulfilled=M,this.callFulfilled=this.otherCallFulfilled),typeof R=="function"&&(this.onRejected=R,this.callRejected=this.otherCallRejected)}function I(w,M,R){u(function(){var C;try{C=M(R)}catch(U){return g.reject(w,U)}C===w?g.reject(w,new TypeError("Cannot resolve promise with itself")):g.resolve(w,C)})}function N(w){var M=w&&w.then;if(w&&(typeof w=="object"||typeof w=="function")&&typeof M=="function")return function(){M.apply(w,arguments)}}function E(w,M){var R=!1;function C(X){R||(R=!0,g.reject(w,X))}function U(X){R||(R=!0,g.resolve(w,X))}var F=P(function(){M(U,C)});F.status==="error"&&C(F.value)}function P(w,M){var R={};try{R.value=w(M),R.status="success"}catch(C){R.status="error",R.value=C}return R}(c.exports=O).prototype.finally=function(w){if(typeof w!="function")return this;var M=this.constructor;return this.then(function(R){return M.resolve(w()).then(function(){return R})},function(R){return M.resolve(w()).then(function(){throw R})})},O.prototype.catch=function(w){return this.then(null,w)},O.prototype.then=function(w,M){if(typeof w!="function"&&this.state===S||typeof M!="function"&&this.state===v)return this;var R=new this.constructor(m);return this.state!==b?I(R,this.state===S?w:M,this.outcome):this.queue.push(new k(R,w,M)),R},k.prototype.callFulfilled=function(w){g.resolve(this.promise,w)},k.prototype.otherCallFulfilled=function(w){I(this.promise,this.onFulfilled,w)},k.prototype.callRejected=function(w){g.reject(this.promise,w)},k.prototype.otherCallRejected=function(w){I(this.promise,this.onRejected,w)},g.resolve=function(w,M){var R=P(N,M);if(R.status==="error")return g.reject(w,R.value);var C=R.value;if(C)E(w,C);else{w.state=S,w.outcome=M;for(var U=-1,F=w.queue.length;++U<F;)w.queue[U].callFulfilled(M)}return w},g.reject=function(w,M){w.state=v,w.outcome=M;for(var R=-1,C=w.queue.length;++R<C;)w.queue[R].callRejected(M);return w},O.resolve=function(w){return w instanceof this?w:g.resolve(new this(m),w)},O.reject=function(w){var M=new this(m);return g.reject(M,w)},O.all=function(w){var M=this;if(Object.prototype.toString.call(w)!=="[object Array]")return this.reject(new TypeError("must be an array"));var R=w.length,C=!1;if(!R)return this.resolve([]);for(var U=new Array(R),F=0,X=-1,K=new this(m);++X<R;)Z(w[X],X);return K;function Z(ct,Rt){M.resolve(ct).then(function(tt){U[Rt]=tt,++F!==R||C||(C=!0,g.resolve(K,U))},function(tt){C||(C=!0,g.reject(K,tt))})}},O.race=function(w){var M=this;if(Object.prototype.toString.call(w)!=="[object Array]")return this.reject(new TypeError("must be an array"));var R=w.length,C=!1;if(!R)return this.resolve([]);for(var U=-1,F=new this(m);++U<R;)X=w[U],M.resolve(X).then(function(K){C||(C=!0,g.resolve(F,K))},function(K){C||(C=!0,g.reject(F,K))});var X;return F}},{immediate:36}],38:[function(o,c,f){var u={};(0,o("./lib/utils/common").assign)(u,o("./lib/deflate"),o("./lib/inflate"),o("./lib/zlib/constants")),c.exports=u},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(o,c,f){var u=o("./zlib/deflate"),m=o("./utils/common"),g=o("./utils/strings"),v=o("./zlib/messages"),S=o("./zlib/zstream"),b=Object.prototype.toString,O=0,k=-1,I=0,N=8;function E(w){if(!(this instanceof E))return new E(w);this.options=m.assign({level:k,method:N,chunkSize:16384,windowBits:15,memLevel:8,strategy:I,to:""},w||{});var M=this.options;M.raw&&0<M.windowBits?M.windowBits=-M.windowBits:M.gzip&&0<M.windowBits&&M.windowBits<16&&(M.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new S,this.strm.avail_out=0;var R=u.deflateInit2(this.strm,M.level,M.method,M.windowBits,M.memLevel,M.strategy);if(R!==O)throw new Error(v[R]);if(M.header&&u.deflateSetHeader(this.strm,M.header),M.dictionary){var C;if(C=typeof M.dictionary=="string"?g.string2buf(M.dictionary):b.call(M.dictionary)==="[object ArrayBuffer]"?new Uint8Array(M.dictionary):M.dictionary,(R=u.deflateSetDictionary(this.strm,C))!==O)throw new Error(v[R]);this._dict_set=!0}}function P(w,M){var R=new E(M);if(R.push(w,!0),R.err)throw R.msg||v[R.err];return R.result}E.prototype.push=function(w,M){var R,C,U=this.strm,F=this.options.chunkSize;if(this.ended)return!1;C=M===~~M?M:M===!0?4:0,typeof w=="string"?U.input=g.string2buf(w):b.call(w)==="[object ArrayBuffer]"?U.input=new Uint8Array(w):U.input=w,U.next_in=0,U.avail_in=U.input.length;do{if(U.avail_out===0&&(U.output=new m.Buf8(F),U.next_out=0,U.avail_out=F),(R=u.deflate(U,C))!==1&&R!==O)return this.onEnd(R),!(this.ended=!0);U.avail_out!==0&&(U.avail_in!==0||C!==4&&C!==2)||(this.options.to==="string"?this.onData(g.buf2binstring(m.shrinkBuf(U.output,U.next_out))):this.onData(m.shrinkBuf(U.output,U.next_out)))}while((0<U.avail_in||U.avail_out===0)&&R!==1);return C===4?(R=u.deflateEnd(this.strm),this.onEnd(R),this.ended=!0,R===O):C!==2||(this.onEnd(O),!(U.avail_out=0))},E.prototype.onData=function(w){this.chunks.push(w)},E.prototype.onEnd=function(w){w===O&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=m.flattenChunks(this.chunks)),this.chunks=[],this.err=w,this.msg=this.strm.msg},f.Deflate=E,f.deflate=P,f.deflateRaw=function(w,M){return(M=M||{}).raw=!0,P(w,M)},f.gzip=function(w,M){return(M=M||{}).gzip=!0,P(w,M)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(o,c,f){var u=o("./zlib/inflate"),m=o("./utils/common"),g=o("./utils/strings"),v=o("./zlib/constants"),S=o("./zlib/messages"),b=o("./zlib/zstream"),O=o("./zlib/gzheader"),k=Object.prototype.toString;function I(E){if(!(this instanceof I))return new I(E);this.options=m.assign({chunkSize:16384,windowBits:0,to:""},E||{});var P=this.options;P.raw&&0<=P.windowBits&&P.windowBits<16&&(P.windowBits=-P.windowBits,P.windowBits===0&&(P.windowBits=-15)),!(0<=P.windowBits&&P.windowBits<16)||E&&E.windowBits||(P.windowBits+=32),15<P.windowBits&&P.windowBits<48&&!(15&P.windowBits)&&(P.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new b,this.strm.avail_out=0;var w=u.inflateInit2(this.strm,P.windowBits);if(w!==v.Z_OK)throw new Error(S[w]);this.header=new O,u.inflateGetHeader(this.strm,this.header)}function N(E,P){var w=new I(P);if(w.push(E,!0),w.err)throw w.msg||S[w.err];return w.result}I.prototype.push=function(E,P){var w,M,R,C,U,F,X=this.strm,K=this.options.chunkSize,Z=this.options.dictionary,ct=!1;if(this.ended)return!1;M=P===~~P?P:P===!0?v.Z_FINISH:v.Z_NO_FLUSH,typeof E=="string"?X.input=g.binstring2buf(E):k.call(E)==="[object ArrayBuffer]"?X.input=new Uint8Array(E):X.input=E,X.next_in=0,X.avail_in=X.input.length;do{if(X.avail_out===0&&(X.output=new m.Buf8(K),X.next_out=0,X.avail_out=K),(w=u.inflate(X,v.Z_NO_FLUSH))===v.Z_NEED_DICT&&Z&&(F=typeof Z=="string"?g.string2buf(Z):k.call(Z)==="[object ArrayBuffer]"?new Uint8Array(Z):Z,w=u.inflateSetDictionary(this.strm,F)),w===v.Z_BUF_ERROR&&ct===!0&&(w=v.Z_OK,ct=!1),w!==v.Z_STREAM_END&&w!==v.Z_OK)return this.onEnd(w),!(this.ended=!0);X.next_out&&(X.avail_out!==0&&w!==v.Z_STREAM_END&&(X.avail_in!==0||M!==v.Z_FINISH&&M!==v.Z_SYNC_FLUSH)||(this.options.to==="string"?(R=g.utf8border(X.output,X.next_out),C=X.next_out-R,U=g.buf2string(X.output,R),X.next_out=C,X.avail_out=K-C,C&&m.arraySet(X.output,X.output,R,C,0),this.onData(U)):this.onData(m.shrinkBuf(X.output,X.next_out)))),X.avail_in===0&&X.avail_out===0&&(ct=!0)}while((0<X.avail_in||X.avail_out===0)&&w!==v.Z_STREAM_END);return w===v.Z_STREAM_END&&(M=v.Z_FINISH),M===v.Z_FINISH?(w=u.inflateEnd(this.strm),this.onEnd(w),this.ended=!0,w===v.Z_OK):M!==v.Z_SYNC_FLUSH||(this.onEnd(v.Z_OK),!(X.avail_out=0))},I.prototype.onData=function(E){this.chunks.push(E)},I.prototype.onEnd=function(E){E===v.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=m.flattenChunks(this.chunks)),this.chunks=[],this.err=E,this.msg=this.strm.msg},f.Inflate=I,f.inflate=N,f.inflateRaw=function(E,P){return(P=P||{}).raw=!0,N(E,P)},f.ungzip=N},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(o,c,f){var u=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";f.assign=function(v){for(var S=Array.prototype.slice.call(arguments,1);S.length;){var b=S.shift();if(b){if(typeof b!="object")throw new TypeError(b+"must be non-object");for(var O in b)b.hasOwnProperty(O)&&(v[O]=b[O])}}return v},f.shrinkBuf=function(v,S){return v.length===S?v:v.subarray?v.subarray(0,S):(v.length=S,v)};var m={arraySet:function(v,S,b,O,k){if(S.subarray&&v.subarray)v.set(S.subarray(b,b+O),k);else for(var I=0;I<O;I++)v[k+I]=S[b+I]},flattenChunks:function(v){var S,b,O,k,I,N;for(S=O=0,b=v.length;S<b;S++)O+=v[S].length;for(N=new Uint8Array(O),S=k=0,b=v.length;S<b;S++)I=v[S],N.set(I,k),k+=I.length;return N}},g={arraySet:function(v,S,b,O,k){for(var I=0;I<O;I++)v[k+I]=S[b+I]},flattenChunks:function(v){return[].concat.apply([],v)}};f.setTyped=function(v){v?(f.Buf8=Uint8Array,f.Buf16=Uint16Array,f.Buf32=Int32Array,f.assign(f,m)):(f.Buf8=Array,f.Buf16=Array,f.Buf32=Array,f.assign(f,g))},f.setTyped(u)},{}],42:[function(o,c,f){var u=o("./common"),m=!0,g=!0;try{String.fromCharCode.apply(null,[0])}catch{m=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{g=!1}for(var v=new u.Buf8(256),S=0;S<256;S++)v[S]=252<=S?6:248<=S?5:240<=S?4:224<=S?3:192<=S?2:1;function b(O,k){if(k<65537&&(O.subarray&&g||!O.subarray&&m))return String.fromCharCode.apply(null,u.shrinkBuf(O,k));for(var I="",N=0;N<k;N++)I+=String.fromCharCode(O[N]);return I}v[254]=v[254]=1,f.string2buf=function(O){var k,I,N,E,P,w=O.length,M=0;for(E=0;E<w;E++)(64512&(I=O.charCodeAt(E)))==55296&&E+1<w&&(64512&(N=O.charCodeAt(E+1)))==56320&&(I=65536+(I-55296<<10)+(N-56320),E++),M+=I<128?1:I<2048?2:I<65536?3:4;for(k=new u.Buf8(M),E=P=0;P<M;E++)(64512&(I=O.charCodeAt(E)))==55296&&E+1<w&&(64512&(N=O.charCodeAt(E+1)))==56320&&(I=65536+(I-55296<<10)+(N-56320),E++),I<128?k[P++]=I:(I<2048?k[P++]=192|I>>>6:(I<65536?k[P++]=224|I>>>12:(k[P++]=240|I>>>18,k[P++]=128|I>>>12&63),k[P++]=128|I>>>6&63),k[P++]=128|63&I);return k},f.buf2binstring=function(O){return b(O,O.length)},f.binstring2buf=function(O){for(var k=new u.Buf8(O.length),I=0,N=k.length;I<N;I++)k[I]=O.charCodeAt(I);return k},f.buf2string=function(O,k){var I,N,E,P,w=k||O.length,M=new Array(2*w);for(I=N=0;I<w;)if((E=O[I++])<128)M[N++]=E;else if(4<(P=v[E]))M[N++]=65533,I+=P-1;else{for(E&=P===2?31:P===3?15:7;1<P&&I<w;)E=E<<6|63&O[I++],P--;1<P?M[N++]=65533:E<65536?M[N++]=E:(E-=65536,M[N++]=55296|E>>10&1023,M[N++]=56320|1023&E)}return b(M,N)},f.utf8border=function(O,k){var I;for((k=k||O.length)>O.length&&(k=O.length),I=k-1;0<=I&&(192&O[I])==128;)I--;return I<0||I===0?k:I+v[O[I]]>k?I:k}},{"./common":41}],43:[function(o,c,f){c.exports=function(u,m,g,v){for(var S=65535&u|0,b=u>>>16&65535|0,O=0;g!==0;){for(g-=O=2e3<g?2e3:g;b=b+(S=S+m[v++]|0)|0,--O;);S%=65521,b%=65521}return S|b<<16|0}},{}],44:[function(o,c,f){c.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(o,c,f){var u=function(){for(var m,g=[],v=0;v<256;v++){m=v;for(var S=0;S<8;S++)m=1&m?3988292384^m>>>1:m>>>1;g[v]=m}return g}();c.exports=function(m,g,v,S){var b=u,O=S+v;m^=-1;for(var k=S;k<O;k++)m=m>>>8^b[255&(m^g[k])];return-1^m}},{}],46:[function(o,c,f){var u,m=o("../utils/common"),g=o("./trees"),v=o("./adler32"),S=o("./crc32"),b=o("./messages"),O=0,k=4,I=0,N=-2,E=-1,P=4,w=2,M=8,R=9,C=286,U=30,F=19,X=2*C+1,K=15,Z=3,ct=258,Rt=ct+Z+1,tt=42,_t=113,G=1,Pt=2,Et=3,At=4;function ce(W,Jt){return W.msg=b[Jt],Jt}function re(W){return(W<<1)-(4<W?9:0)}function Ft(W){for(var Jt=W.length;0<=--Jt;)W[Jt]=0}function It(W){var Jt=W.state,jt=Jt.pending;jt>W.avail_out&&(jt=W.avail_out),jt!==0&&(m.arraySet(W.output,Jt.pending_buf,Jt.pending_out,jt,W.next_out),W.next_out+=jt,Jt.pending_out+=jt,W.total_out+=jt,W.avail_out-=jt,Jt.pending-=jt,Jt.pending===0&&(Jt.pending_out=0))}function Nt(W,Jt){g._tr_flush_block(W,0<=W.block_start?W.block_start:-1,W.strstart-W.block_start,Jt),W.block_start=W.strstart,It(W.strm)}function Pe(W,Jt){W.pending_buf[W.pending++]=Jt}function pe(W,Jt){W.pending_buf[W.pending++]=Jt>>>8&255,W.pending_buf[W.pending++]=255&Jt}function Wt(W,Jt){var jt,dt,pt=W.max_chain_length,Dt=W.strstart,ie=W.prev_length,Kt=W.nice_match,z=W.strstart>W.w_size-Rt?W.strstart-(W.w_size-Rt):0,Q=W.window,st=W.w_mask,nt=W.prev,vt=W.strstart+ct,Ut=Q[Dt+ie-1],qt=Q[Dt+ie];W.prev_length>=W.good_match&&(pt>>=2),Kt>W.lookahead&&(Kt=W.lookahead);do if(Q[(jt=Jt)+ie]===qt&&Q[jt+ie-1]===Ut&&Q[jt]===Q[Dt]&&Q[++jt]===Q[Dt+1]){Dt+=2,jt++;do;while(Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Dt<vt);if(dt=ct-(vt-Dt),Dt=vt-ct,ie<dt){if(W.match_start=Jt,Kt<=(ie=dt))break;Ut=Q[Dt+ie-1],qt=Q[Dt+ie]}}while((Jt=nt[Jt&st])>z&&--pt!=0);return ie<=W.lookahead?ie:W.lookahead}function $e(W){var Jt,jt,dt,pt,Dt,ie,Kt,z,Q,st,nt=W.w_size;do{if(pt=W.window_size-W.lookahead-W.strstart,W.strstart>=nt+(nt-Rt)){for(m.arraySet(W.window,W.window,nt,nt,0),W.match_start-=nt,W.strstart-=nt,W.block_start-=nt,Jt=jt=W.hash_size;dt=W.head[--Jt],W.head[Jt]=nt<=dt?dt-nt:0,--jt;);for(Jt=jt=nt;dt=W.prev[--Jt],W.prev[Jt]=nt<=dt?dt-nt:0,--jt;);pt+=nt}if(W.strm.avail_in===0)break;if(ie=W.strm,Kt=W.window,z=W.strstart+W.lookahead,Q=pt,st=void 0,st=ie.avail_in,Q<st&&(st=Q),jt=st===0?0:(ie.avail_in-=st,m.arraySet(Kt,ie.input,ie.next_in,st,z),ie.state.wrap===1?ie.adler=v(ie.adler,Kt,st,z):ie.state.wrap===2&&(ie.adler=S(ie.adler,Kt,st,z)),ie.next_in+=st,ie.total_in+=st,st),W.lookahead+=jt,W.lookahead+W.insert>=Z)for(Dt=W.strstart-W.insert,W.ins_h=W.window[Dt],W.ins_h=(W.ins_h<<W.hash_shift^W.window[Dt+1])&W.hash_mask;W.insert&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[Dt+Z-1])&W.hash_mask,W.prev[Dt&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=Dt,Dt++,W.insert--,!(W.lookahead+W.insert<Z)););}while(W.lookahead<Rt&&W.strm.avail_in!==0)}function Si(W,Jt){for(var jt,dt;;){if(W.lookahead<Rt){if($e(W),W.lookahead<Rt&&Jt===O)return G;if(W.lookahead===0)break}if(jt=0,W.lookahead>=Z&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart),jt!==0&&W.strstart-jt<=W.w_size-Rt&&(W.match_length=Wt(W,jt)),W.match_length>=Z)if(dt=g._tr_tally(W,W.strstart-W.match_start,W.match_length-Z),W.lookahead-=W.match_length,W.match_length<=W.max_lazy_match&&W.lookahead>=Z){for(W.match_length--;W.strstart++,W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart,--W.match_length!=0;);W.strstart++}else W.strstart+=W.match_length,W.match_length=0,W.ins_h=W.window[W.strstart],W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+1])&W.hash_mask;else dt=g._tr_tally(W,0,W.window[W.strstart]),W.lookahead--,W.strstart++;if(dt&&(Nt(W,!1),W.strm.avail_out===0))return G}return W.insert=W.strstart<Z-1?W.strstart:Z-1,Jt===k?(Nt(W,!0),W.strm.avail_out===0?Et:At):W.last_lit&&(Nt(W,!1),W.strm.avail_out===0)?G:Pt}function Oe(W,Jt){for(var jt,dt,pt;;){if(W.lookahead<Rt){if($e(W),W.lookahead<Rt&&Jt===O)return G;if(W.lookahead===0)break}if(jt=0,W.lookahead>=Z&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart),W.prev_length=W.match_length,W.prev_match=W.match_start,W.match_length=Z-1,jt!==0&&W.prev_length<W.max_lazy_match&&W.strstart-jt<=W.w_size-Rt&&(W.match_length=Wt(W,jt),W.match_length<=5&&(W.strategy===1||W.match_length===Z&&4096<W.strstart-W.match_start)&&(W.match_length=Z-1)),W.prev_length>=Z&&W.match_length<=W.prev_length){for(pt=W.strstart+W.lookahead-Z,dt=g._tr_tally(W,W.strstart-1-W.prev_match,W.prev_length-Z),W.lookahead-=W.prev_length-1,W.prev_length-=2;++W.strstart<=pt&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart),--W.prev_length!=0;);if(W.match_available=0,W.match_length=Z-1,W.strstart++,dt&&(Nt(W,!1),W.strm.avail_out===0))return G}else if(W.match_available){if((dt=g._tr_tally(W,0,W.window[W.strstart-1]))&&Nt(W,!1),W.strstart++,W.lookahead--,W.strm.avail_out===0)return G}else W.match_available=1,W.strstart++,W.lookahead--}return W.match_available&&(dt=g._tr_tally(W,0,W.window[W.strstart-1]),W.match_available=0),W.insert=W.strstart<Z-1?W.strstart:Z-1,Jt===k?(Nt(W,!0),W.strm.avail_out===0?Et:At):W.last_lit&&(Nt(W,!1),W.strm.avail_out===0)?G:Pt}function Ge(W,Jt,jt,dt,pt){this.good_length=W,this.max_lazy=Jt,this.nice_length=jt,this.max_chain=dt,this.func=pt}function pi(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=M,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new m.Buf16(2*X),this.dyn_dtree=new m.Buf16(2*(2*U+1)),this.bl_tree=new m.Buf16(2*(2*F+1)),Ft(this.dyn_ltree),Ft(this.dyn_dtree),Ft(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new m.Buf16(K+1),this.heap=new m.Buf16(2*C+1),Ft(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new m.Buf16(2*C+1),Ft(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function Di(W){var Jt;return W&&W.state?(W.total_in=W.total_out=0,W.data_type=w,(Jt=W.state).pending=0,Jt.pending_out=0,Jt.wrap<0&&(Jt.wrap=-Jt.wrap),Jt.status=Jt.wrap?tt:_t,W.adler=Jt.wrap===2?0:1,Jt.last_flush=O,g._tr_init(Jt),I):ce(W,N)}function mn(W){var Jt=Di(W);return Jt===I&&function(jt){jt.window_size=2*jt.w_size,Ft(jt.head),jt.max_lazy_match=u[jt.level].max_lazy,jt.good_match=u[jt.level].good_length,jt.nice_match=u[jt.level].nice_length,jt.max_chain_length=u[jt.level].max_chain,jt.strstart=0,jt.block_start=0,jt.lookahead=0,jt.insert=0,jt.match_length=jt.prev_length=Z-1,jt.match_available=0,jt.ins_h=0}(W.state),Jt}function Qi(W,Jt,jt,dt,pt,Dt){if(!W)return N;var ie=1;if(Jt===E&&(Jt=6),dt<0?(ie=0,dt=-dt):15<dt&&(ie=2,dt-=16),pt<1||R<pt||jt!==M||dt<8||15<dt||Jt<0||9<Jt||Dt<0||P<Dt)return ce(W,N);dt===8&&(dt=9);var Kt=new pi;return(W.state=Kt).strm=W,Kt.wrap=ie,Kt.gzhead=null,Kt.w_bits=dt,Kt.w_size=1<<Kt.w_bits,Kt.w_mask=Kt.w_size-1,Kt.hash_bits=pt+7,Kt.hash_size=1<<Kt.hash_bits,Kt.hash_mask=Kt.hash_size-1,Kt.hash_shift=~~((Kt.hash_bits+Z-1)/Z),Kt.window=new m.Buf8(2*Kt.w_size),Kt.head=new m.Buf16(Kt.hash_size),Kt.prev=new m.Buf16(Kt.w_size),Kt.lit_bufsize=1<<pt+6,Kt.pending_buf_size=4*Kt.lit_bufsize,Kt.pending_buf=new m.Buf8(Kt.pending_buf_size),Kt.d_buf=1*Kt.lit_bufsize,Kt.l_buf=3*Kt.lit_bufsize,Kt.level=Jt,Kt.strategy=Dt,Kt.method=jt,mn(W)}u=[new Ge(0,0,0,0,function(W,Jt){var jt=65535;for(jt>W.pending_buf_size-5&&(jt=W.pending_buf_size-5);;){if(W.lookahead<=1){if($e(W),W.lookahead===0&&Jt===O)return G;if(W.lookahead===0)break}W.strstart+=W.lookahead,W.lookahead=0;var dt=W.block_start+jt;if((W.strstart===0||W.strstart>=dt)&&(W.lookahead=W.strstart-dt,W.strstart=dt,Nt(W,!1),W.strm.avail_out===0)||W.strstart-W.block_start>=W.w_size-Rt&&(Nt(W,!1),W.strm.avail_out===0))return G}return W.insert=0,Jt===k?(Nt(W,!0),W.strm.avail_out===0?Et:At):(W.strstart>W.block_start&&(Nt(W,!1),W.strm.avail_out),G)}),new Ge(4,4,8,4,Si),new Ge(4,5,16,8,Si),new Ge(4,6,32,32,Si),new Ge(4,4,16,16,Oe),new Ge(8,16,32,32,Oe),new Ge(8,16,128,128,Oe),new Ge(8,32,128,256,Oe),new Ge(32,128,258,1024,Oe),new Ge(32,258,258,4096,Oe)],f.deflateInit=function(W,Jt){return Qi(W,Jt,M,15,8,0)},f.deflateInit2=Qi,f.deflateReset=mn,f.deflateResetKeep=Di,f.deflateSetHeader=function(W,Jt){return W&&W.state?W.state.wrap!==2?N:(W.state.gzhead=Jt,I):N},f.deflate=function(W,Jt){var jt,dt,pt,Dt;if(!W||!W.state||5<Jt||Jt<0)return W?ce(W,N):N;if(dt=W.state,!W.output||!W.input&&W.avail_in!==0||dt.status===666&&Jt!==k)return ce(W,W.avail_out===0?-5:N);if(dt.strm=W,jt=dt.last_flush,dt.last_flush=Jt,dt.status===tt)if(dt.wrap===2)W.adler=0,Pe(dt,31),Pe(dt,139),Pe(dt,8),dt.gzhead?(Pe(dt,(dt.gzhead.text?1:0)+(dt.gzhead.hcrc?2:0)+(dt.gzhead.extra?4:0)+(dt.gzhead.name?8:0)+(dt.gzhead.comment?16:0)),Pe(dt,255&dt.gzhead.time),Pe(dt,dt.gzhead.time>>8&255),Pe(dt,dt.gzhead.time>>16&255),Pe(dt,dt.gzhead.time>>24&255),Pe(dt,dt.level===9?2:2<=dt.strategy||dt.level<2?4:0),Pe(dt,255&dt.gzhead.os),dt.gzhead.extra&&dt.gzhead.extra.length&&(Pe(dt,255&dt.gzhead.extra.length),Pe(dt,dt.gzhead.extra.length>>8&255)),dt.gzhead.hcrc&&(W.adler=S(W.adler,dt.pending_buf,dt.pending,0)),dt.gzindex=0,dt.status=69):(Pe(dt,0),Pe(dt,0),Pe(dt,0),Pe(dt,0),Pe(dt,0),Pe(dt,dt.level===9?2:2<=dt.strategy||dt.level<2?4:0),Pe(dt,3),dt.status=_t);else{var ie=M+(dt.w_bits-8<<4)<<8;ie|=(2<=dt.strategy||dt.level<2?0:dt.level<6?1:dt.level===6?2:3)<<6,dt.strstart!==0&&(ie|=32),ie+=31-ie%31,dt.status=_t,pe(dt,ie),dt.strstart!==0&&(pe(dt,W.adler>>>16),pe(dt,65535&W.adler)),W.adler=1}if(dt.status===69)if(dt.gzhead.extra){for(pt=dt.pending;dt.gzindex<(65535&dt.gzhead.extra.length)&&(dt.pending!==dt.pending_buf_size||(dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),It(W),pt=dt.pending,dt.pending!==dt.pending_buf_size));)Pe(dt,255&dt.gzhead.extra[dt.gzindex]),dt.gzindex++;dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),dt.gzindex===dt.gzhead.extra.length&&(dt.gzindex=0,dt.status=73)}else dt.status=73;if(dt.status===73)if(dt.gzhead.name){pt=dt.pending;do{if(dt.pending===dt.pending_buf_size&&(dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),It(W),pt=dt.pending,dt.pending===dt.pending_buf_size)){Dt=1;break}Dt=dt.gzindex<dt.gzhead.name.length?255&dt.gzhead.name.charCodeAt(dt.gzindex++):0,Pe(dt,Dt)}while(Dt!==0);dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),Dt===0&&(dt.gzindex=0,dt.status=91)}else dt.status=91;if(dt.status===91)if(dt.gzhead.comment){pt=dt.pending;do{if(dt.pending===dt.pending_buf_size&&(dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),It(W),pt=dt.pending,dt.pending===dt.pending_buf_size)){Dt=1;break}Dt=dt.gzindex<dt.gzhead.comment.length?255&dt.gzhead.comment.charCodeAt(dt.gzindex++):0,Pe(dt,Dt)}while(Dt!==0);dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),Dt===0&&(dt.status=103)}else dt.status=103;if(dt.status===103&&(dt.gzhead.hcrc?(dt.pending+2>dt.pending_buf_size&&It(W),dt.pending+2<=dt.pending_buf_size&&(Pe(dt,255&W.adler),Pe(dt,W.adler>>8&255),W.adler=0,dt.status=_t)):dt.status=_t),dt.pending!==0){if(It(W),W.avail_out===0)return dt.last_flush=-1,I}else if(W.avail_in===0&&re(Jt)<=re(jt)&&Jt!==k)return ce(W,-5);if(dt.status===666&&W.avail_in!==0)return ce(W,-5);if(W.avail_in!==0||dt.lookahead!==0||Jt!==O&&dt.status!==666){var Kt=dt.strategy===2?function(z,Q){for(var st;;){if(z.lookahead===0&&($e(z),z.lookahead===0)){if(Q===O)return G;break}if(z.match_length=0,st=g._tr_tally(z,0,z.window[z.strstart]),z.lookahead--,z.strstart++,st&&(Nt(z,!1),z.strm.avail_out===0))return G}return z.insert=0,Q===k?(Nt(z,!0),z.strm.avail_out===0?Et:At):z.last_lit&&(Nt(z,!1),z.strm.avail_out===0)?G:Pt}(dt,Jt):dt.strategy===3?function(z,Q){for(var st,nt,vt,Ut,qt=z.window;;){if(z.lookahead<=ct){if($e(z),z.lookahead<=ct&&Q===O)return G;if(z.lookahead===0)break}if(z.match_length=0,z.lookahead>=Z&&0<z.strstart&&(nt=qt[vt=z.strstart-1])===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]){Ut=z.strstart+ct;do;while(nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&vt<Ut);z.match_length=ct-(Ut-vt),z.match_length>z.lookahead&&(z.match_length=z.lookahead)}if(z.match_length>=Z?(st=g._tr_tally(z,1,z.match_length-Z),z.lookahead-=z.match_length,z.strstart+=z.match_length,z.match_length=0):(st=g._tr_tally(z,0,z.window[z.strstart]),z.lookahead--,z.strstart++),st&&(Nt(z,!1),z.strm.avail_out===0))return G}return z.insert=0,Q===k?(Nt(z,!0),z.strm.avail_out===0?Et:At):z.last_lit&&(Nt(z,!1),z.strm.avail_out===0)?G:Pt}(dt,Jt):u[dt.level].func(dt,Jt);if(Kt!==Et&&Kt!==At||(dt.status=666),Kt===G||Kt===Et)return W.avail_out===0&&(dt.last_flush=-1),I;if(Kt===Pt&&(Jt===1?g._tr_align(dt):Jt!==5&&(g._tr_stored_block(dt,0,0,!1),Jt===3&&(Ft(dt.head),dt.lookahead===0&&(dt.strstart=0,dt.block_start=0,dt.insert=0))),It(W),W.avail_out===0))return dt.last_flush=-1,I}return Jt!==k?I:dt.wrap<=0?1:(dt.wrap===2?(Pe(dt,255&W.adler),Pe(dt,W.adler>>8&255),Pe(dt,W.adler>>16&255),Pe(dt,W.adler>>24&255),Pe(dt,255&W.total_in),Pe(dt,W.total_in>>8&255),Pe(dt,W.total_in>>16&255),Pe(dt,W.total_in>>24&255)):(pe(dt,W.adler>>>16),pe(dt,65535&W.adler)),It(W),0<dt.wrap&&(dt.wrap=-dt.wrap),dt.pending!==0?I:1)},f.deflateEnd=function(W){var Jt;return W&&W.state?(Jt=W.state.status)!==tt&&Jt!==69&&Jt!==73&&Jt!==91&&Jt!==103&&Jt!==_t&&Jt!==666?ce(W,N):(W.state=null,Jt===_t?ce(W,-3):I):N},f.deflateSetDictionary=function(W,Jt){var jt,dt,pt,Dt,ie,Kt,z,Q,st=Jt.length;if(!W||!W.state||(Dt=(jt=W.state).wrap)===2||Dt===1&&jt.status!==tt||jt.lookahead)return N;for(Dt===1&&(W.adler=v(W.adler,Jt,st,0)),jt.wrap=0,st>=jt.w_size&&(Dt===0&&(Ft(jt.head),jt.strstart=0,jt.block_start=0,jt.insert=0),Q=new m.Buf8(jt.w_size),m.arraySet(Q,Jt,st-jt.w_size,jt.w_size,0),Jt=Q,st=jt.w_size),ie=W.avail_in,Kt=W.next_in,z=W.input,W.avail_in=st,W.next_in=0,W.input=Jt,$e(jt);jt.lookahead>=Z;){for(dt=jt.strstart,pt=jt.lookahead-(Z-1);jt.ins_h=(jt.ins_h<<jt.hash_shift^jt.window[dt+Z-1])&jt.hash_mask,jt.prev[dt&jt.w_mask]=jt.head[jt.ins_h],jt.head[jt.ins_h]=dt,dt++,--pt;);jt.strstart=dt,jt.lookahead=Z-1,$e(jt)}return jt.strstart+=jt.lookahead,jt.block_start=jt.strstart,jt.insert=jt.lookahead,jt.lookahead=0,jt.match_length=jt.prev_length=Z-1,jt.match_available=0,W.next_in=Kt,W.input=z,W.avail_in=ie,jt.wrap=Dt,I},f.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(o,c,f){c.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(o,c,f){c.exports=function(u,m){var g,v,S,b,O,k,I,N,E,P,w,M,R,C,U,F,X,K,Z,ct,Rt,tt,_t,G,Pt;g=u.state,v=u.next_in,G=u.input,S=v+(u.avail_in-5),b=u.next_out,Pt=u.output,O=b-(m-u.avail_out),k=b+(u.avail_out-257),I=g.dmax,N=g.wsize,E=g.whave,P=g.wnext,w=g.window,M=g.hold,R=g.bits,C=g.lencode,U=g.distcode,F=(1<<g.lenbits)-1,X=(1<<g.distbits)-1;t:do{R<15&&(M+=G[v++]<<R,R+=8,M+=G[v++]<<R,R+=8),K=C[M&F];e:for(;;){if(M>>>=Z=K>>>24,R-=Z,(Z=K>>>16&255)===0)Pt[b++]=65535&K;else{if(!(16&Z)){if(!(64&Z)){K=C[(65535&K)+(M&(1<<Z)-1)];continue e}if(32&Z){g.mode=12;break t}u.msg="invalid literal/length code",g.mode=30;break t}ct=65535&K,(Z&=15)&&(R<Z&&(M+=G[v++]<<R,R+=8),ct+=M&(1<<Z)-1,M>>>=Z,R-=Z),R<15&&(M+=G[v++]<<R,R+=8,M+=G[v++]<<R,R+=8),K=U[M&X];i:for(;;){if(M>>>=Z=K>>>24,R-=Z,!(16&(Z=K>>>16&255))){if(!(64&Z)){K=U[(65535&K)+(M&(1<<Z)-1)];continue i}u.msg="invalid distance code",g.mode=30;break t}if(Rt=65535&K,R<(Z&=15)&&(M+=G[v++]<<R,(R+=8)<Z&&(M+=G[v++]<<R,R+=8)),I<(Rt+=M&(1<<Z)-1)){u.msg="invalid distance too far back",g.mode=30;break t}if(M>>>=Z,R-=Z,(Z=b-O)<Rt){if(E<(Z=Rt-Z)&&g.sane){u.msg="invalid distance too far back",g.mode=30;break t}if(_t=w,(tt=0)===P){if(tt+=N-Z,Z<ct){for(ct-=Z;Pt[b++]=w[tt++],--Z;);tt=b-Rt,_t=Pt}}else if(P<Z){if(tt+=N+P-Z,(Z-=P)<ct){for(ct-=Z;Pt[b++]=w[tt++],--Z;);if(tt=0,P<ct){for(ct-=Z=P;Pt[b++]=w[tt++],--Z;);tt=b-Rt,_t=Pt}}}else if(tt+=P-Z,Z<ct){for(ct-=Z;Pt[b++]=w[tt++],--Z;);tt=b-Rt,_t=Pt}for(;2<ct;)Pt[b++]=_t[tt++],Pt[b++]=_t[tt++],Pt[b++]=_t[tt++],ct-=3;ct&&(Pt[b++]=_t[tt++],1<ct&&(Pt[b++]=_t[tt++]))}else{for(tt=b-Rt;Pt[b++]=Pt[tt++],Pt[b++]=Pt[tt++],Pt[b++]=Pt[tt++],2<(ct-=3););ct&&(Pt[b++]=Pt[tt++],1<ct&&(Pt[b++]=Pt[tt++]))}break}}break}}while(v<S&&b<k);v-=ct=R>>3,M&=(1<<(R-=ct<<3))-1,u.next_in=v,u.next_out=b,u.avail_in=v<S?S-v+5:5-(v-S),u.avail_out=b<k?k-b+257:257-(b-k),g.hold=M,g.bits=R}},{}],49:[function(o,c,f){var u=o("../utils/common"),m=o("./adler32"),g=o("./crc32"),v=o("./inffast"),S=o("./inftrees"),b=1,O=2,k=0,I=-2,N=1,E=852,P=592;function w(tt){return(tt>>>24&255)+(tt>>>8&65280)+((65280&tt)<<8)+((255&tt)<<24)}function M(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new u.Buf16(320),this.work=new u.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function R(tt){var _t;return tt&&tt.state?(_t=tt.state,tt.total_in=tt.total_out=_t.total=0,tt.msg="",_t.wrap&&(tt.adler=1&_t.wrap),_t.mode=N,_t.last=0,_t.havedict=0,_t.dmax=32768,_t.head=null,_t.hold=0,_t.bits=0,_t.lencode=_t.lendyn=new u.Buf32(E),_t.distcode=_t.distdyn=new u.Buf32(P),_t.sane=1,_t.back=-1,k):I}function C(tt){var _t;return tt&&tt.state?((_t=tt.state).wsize=0,_t.whave=0,_t.wnext=0,R(tt)):I}function U(tt,_t){var G,Pt;return tt&&tt.state?(Pt=tt.state,_t<0?(G=0,_t=-_t):(G=1+(_t>>4),_t<48&&(_t&=15)),_t&&(_t<8||15<_t)?I:(Pt.window!==null&&Pt.wbits!==_t&&(Pt.window=null),Pt.wrap=G,Pt.wbits=_t,C(tt))):I}function F(tt,_t){var G,Pt;return tt?(Pt=new M,(tt.state=Pt).window=null,(G=U(tt,_t))!==k&&(tt.state=null),G):I}var X,K,Z=!0;function ct(tt){if(Z){var _t;for(X=new u.Buf32(512),K=new u.Buf32(32),_t=0;_t<144;)tt.lens[_t++]=8;for(;_t<256;)tt.lens[_t++]=9;for(;_t<280;)tt.lens[_t++]=7;for(;_t<288;)tt.lens[_t++]=8;for(S(b,tt.lens,0,288,X,0,tt.work,{bits:9}),_t=0;_t<32;)tt.lens[_t++]=5;S(O,tt.lens,0,32,K,0,tt.work,{bits:5}),Z=!1}tt.lencode=X,tt.lenbits=9,tt.distcode=K,tt.distbits=5}function Rt(tt,_t,G,Pt){var Et,At=tt.state;return At.window===null&&(At.wsize=1<<At.wbits,At.wnext=0,At.whave=0,At.window=new u.Buf8(At.wsize)),Pt>=At.wsize?(u.arraySet(At.window,_t,G-At.wsize,At.wsize,0),At.wnext=0,At.whave=At.wsize):(Pt<(Et=At.wsize-At.wnext)&&(Et=Pt),u.arraySet(At.window,_t,G-Pt,Et,At.wnext),(Pt-=Et)?(u.arraySet(At.window,_t,G-Pt,Pt,0),At.wnext=Pt,At.whave=At.wsize):(At.wnext+=Et,At.wnext===At.wsize&&(At.wnext=0),At.whave<At.wsize&&(At.whave+=Et))),0}f.inflateReset=C,f.inflateReset2=U,f.inflateResetKeep=R,f.inflateInit=function(tt){return F(tt,15)},f.inflateInit2=F,f.inflate=function(tt,_t){var G,Pt,Et,At,ce,re,Ft,It,Nt,Pe,pe,Wt,$e,Si,Oe,Ge,pi,Di,mn,Qi,W,Jt,jt,dt,pt=0,Dt=new u.Buf8(4),ie=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!tt||!tt.state||!tt.output||!tt.input&&tt.avail_in!==0)return I;(G=tt.state).mode===12&&(G.mode=13),ce=tt.next_out,Et=tt.output,Ft=tt.avail_out,At=tt.next_in,Pt=tt.input,re=tt.avail_in,It=G.hold,Nt=G.bits,Pe=re,pe=Ft,Jt=k;t:for(;;)switch(G.mode){case N:if(G.wrap===0){G.mode=13;break}for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(2&G.wrap&&It===35615){Dt[G.check=0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0),Nt=It=0,G.mode=2;break}if(G.flags=0,G.head&&(G.head.done=!1),!(1&G.wrap)||(((255&It)<<8)+(It>>8))%31){tt.msg="incorrect header check",G.mode=30;break}if((15&It)!=8){tt.msg="unknown compression method",G.mode=30;break}if(Nt-=4,W=8+(15&(It>>>=4)),G.wbits===0)G.wbits=W;else if(W>G.wbits){tt.msg="invalid window size",G.mode=30;break}G.dmax=1<<W,tt.adler=G.check=1,G.mode=512&It?10:12,Nt=It=0;break;case 2:for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(G.flags=It,(255&G.flags)!=8){tt.msg="unknown compression method",G.mode=30;break}if(57344&G.flags){tt.msg="unknown header flags set",G.mode=30;break}G.head&&(G.head.text=It>>8&1),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0)),Nt=It=0,G.mode=3;case 3:for(;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.head&&(G.head.time=It),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,Dt[2]=It>>>16&255,Dt[3]=It>>>24&255,G.check=g(G.check,Dt,4,0)),Nt=It=0,G.mode=4;case 4:for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.head&&(G.head.xflags=255&It,G.head.os=It>>8),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0)),Nt=It=0,G.mode=5;case 5:if(1024&G.flags){for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.length=It,G.head&&(G.head.extra_len=It),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0)),Nt=It=0}else G.head&&(G.head.extra=null);G.mode=6;case 6:if(1024&G.flags&&(re<(Wt=G.length)&&(Wt=re),Wt&&(G.head&&(W=G.head.extra_len-G.length,G.head.extra||(G.head.extra=new Array(G.head.extra_len)),u.arraySet(G.head.extra,Pt,At,Wt,W)),512&G.flags&&(G.check=g(G.check,Pt,Wt,At)),re-=Wt,At+=Wt,G.length-=Wt),G.length))break t;G.length=0,G.mode=7;case 7:if(2048&G.flags){if(re===0)break t;for(Wt=0;W=Pt[At+Wt++],G.head&&W&&G.length<65536&&(G.head.name+=String.fromCharCode(W)),W&&Wt<re;);if(512&G.flags&&(G.check=g(G.check,Pt,Wt,At)),re-=Wt,At+=Wt,W)break t}else G.head&&(G.head.name=null);G.length=0,G.mode=8;case 8:if(4096&G.flags){if(re===0)break t;for(Wt=0;W=Pt[At+Wt++],G.head&&W&&G.length<65536&&(G.head.comment+=String.fromCharCode(W)),W&&Wt<re;);if(512&G.flags&&(G.check=g(G.check,Pt,Wt,At)),re-=Wt,At+=Wt,W)break t}else G.head&&(G.head.comment=null);G.mode=9;case 9:if(512&G.flags){for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(It!==(65535&G.check)){tt.msg="header crc mismatch",G.mode=30;break}Nt=It=0}G.head&&(G.head.hcrc=G.flags>>9&1,G.head.done=!0),tt.adler=G.check=0,G.mode=12;break;case 10:for(;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}tt.adler=G.check=w(It),Nt=It=0,G.mode=11;case 11:if(G.havedict===0)return tt.next_out=ce,tt.avail_out=Ft,tt.next_in=At,tt.avail_in=re,G.hold=It,G.bits=Nt,2;tt.adler=G.check=1,G.mode=12;case 12:if(_t===5||_t===6)break t;case 13:if(G.last){It>>>=7&Nt,Nt-=7&Nt,G.mode=27;break}for(;Nt<3;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}switch(G.last=1&It,Nt-=1,3&(It>>>=1)){case 0:G.mode=14;break;case 1:if(ct(G),G.mode=20,_t!==6)break;It>>>=2,Nt-=2;break t;case 2:G.mode=17;break;case 3:tt.msg="invalid block type",G.mode=30}It>>>=2,Nt-=2;break;case 14:for(It>>>=7&Nt,Nt-=7&Nt;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if((65535&It)!=(It>>>16^65535)){tt.msg="invalid stored block lengths",G.mode=30;break}if(G.length=65535&It,Nt=It=0,G.mode=15,_t===6)break t;case 15:G.mode=16;case 16:if(Wt=G.length){if(re<Wt&&(Wt=re),Ft<Wt&&(Wt=Ft),Wt===0)break t;u.arraySet(Et,Pt,At,Wt,ce),re-=Wt,At+=Wt,Ft-=Wt,ce+=Wt,G.length-=Wt;break}G.mode=12;break;case 17:for(;Nt<14;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(G.nlen=257+(31&It),It>>>=5,Nt-=5,G.ndist=1+(31&It),It>>>=5,Nt-=5,G.ncode=4+(15&It),It>>>=4,Nt-=4,286<G.nlen||30<G.ndist){tt.msg="too many length or distance symbols",G.mode=30;break}G.have=0,G.mode=18;case 18:for(;G.have<G.ncode;){for(;Nt<3;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.lens[ie[G.have++]]=7&It,It>>>=3,Nt-=3}for(;G.have<19;)G.lens[ie[G.have++]]=0;if(G.lencode=G.lendyn,G.lenbits=7,jt={bits:G.lenbits},Jt=S(0,G.lens,0,19,G.lencode,0,G.work,jt),G.lenbits=jt.bits,Jt){tt.msg="invalid code lengths set",G.mode=30;break}G.have=0,G.mode=19;case 19:for(;G.have<G.nlen+G.ndist;){for(;Ge=(pt=G.lencode[It&(1<<G.lenbits)-1])>>>16&255,pi=65535&pt,!((Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(pi<16)It>>>=Oe,Nt-=Oe,G.lens[G.have++]=pi;else{if(pi===16){for(dt=Oe+2;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(It>>>=Oe,Nt-=Oe,G.have===0){tt.msg="invalid bit length repeat",G.mode=30;break}W=G.lens[G.have-1],Wt=3+(3&It),It>>>=2,Nt-=2}else if(pi===17){for(dt=Oe+3;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}Nt-=Oe,W=0,Wt=3+(7&(It>>>=Oe)),It>>>=3,Nt-=3}else{for(dt=Oe+7;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}Nt-=Oe,W=0,Wt=11+(127&(It>>>=Oe)),It>>>=7,Nt-=7}if(G.have+Wt>G.nlen+G.ndist){tt.msg="invalid bit length repeat",G.mode=30;break}for(;Wt--;)G.lens[G.have++]=W}}if(G.mode===30)break;if(G.lens[256]===0){tt.msg="invalid code -- missing end-of-block",G.mode=30;break}if(G.lenbits=9,jt={bits:G.lenbits},Jt=S(b,G.lens,0,G.nlen,G.lencode,0,G.work,jt),G.lenbits=jt.bits,Jt){tt.msg="invalid literal/lengths set",G.mode=30;break}if(G.distbits=6,G.distcode=G.distdyn,jt={bits:G.distbits},Jt=S(O,G.lens,G.nlen,G.ndist,G.distcode,0,G.work,jt),G.distbits=jt.bits,Jt){tt.msg="invalid distances set",G.mode=30;break}if(G.mode=20,_t===6)break t;case 20:G.mode=21;case 21:if(6<=re&&258<=Ft){tt.next_out=ce,tt.avail_out=Ft,tt.next_in=At,tt.avail_in=re,G.hold=It,G.bits=Nt,v(tt,pe),ce=tt.next_out,Et=tt.output,Ft=tt.avail_out,At=tt.next_in,Pt=tt.input,re=tt.avail_in,It=G.hold,Nt=G.bits,G.mode===12&&(G.back=-1);break}for(G.back=0;Ge=(pt=G.lencode[It&(1<<G.lenbits)-1])>>>16&255,pi=65535&pt,!((Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(Ge&&!(240&Ge)){for(Di=Oe,mn=Ge,Qi=pi;Ge=(pt=G.lencode[Qi+((It&(1<<Di+mn)-1)>>Di)])>>>16&255,pi=65535&pt,!(Di+(Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}It>>>=Di,Nt-=Di,G.back+=Di}if(It>>>=Oe,Nt-=Oe,G.back+=Oe,G.length=pi,Ge===0){G.mode=26;break}if(32&Ge){G.back=-1,G.mode=12;break}if(64&Ge){tt.msg="invalid literal/length code",G.mode=30;break}G.extra=15&Ge,G.mode=22;case 22:if(G.extra){for(dt=G.extra;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.length+=It&(1<<G.extra)-1,It>>>=G.extra,Nt-=G.extra,G.back+=G.extra}G.was=G.length,G.mode=23;case 23:for(;Ge=(pt=G.distcode[It&(1<<G.distbits)-1])>>>16&255,pi=65535&pt,!((Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(!(240&Ge)){for(Di=Oe,mn=Ge,Qi=pi;Ge=(pt=G.distcode[Qi+((It&(1<<Di+mn)-1)>>Di)])>>>16&255,pi=65535&pt,!(Di+(Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}It>>>=Di,Nt-=Di,G.back+=Di}if(It>>>=Oe,Nt-=Oe,G.back+=Oe,64&Ge){tt.msg="invalid distance code",G.mode=30;break}G.offset=pi,G.extra=15&Ge,G.mode=24;case 24:if(G.extra){for(dt=G.extra;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.offset+=It&(1<<G.extra)-1,It>>>=G.extra,Nt-=G.extra,G.back+=G.extra}if(G.offset>G.dmax){tt.msg="invalid distance too far back",G.mode=30;break}G.mode=25;case 25:if(Ft===0)break t;if(Wt=pe-Ft,G.offset>Wt){if((Wt=G.offset-Wt)>G.whave&&G.sane){tt.msg="invalid distance too far back",G.mode=30;break}$e=Wt>G.wnext?(Wt-=G.wnext,G.wsize-Wt):G.wnext-Wt,Wt>G.length&&(Wt=G.length),Si=G.window}else Si=Et,$e=ce-G.offset,Wt=G.length;for(Ft<Wt&&(Wt=Ft),Ft-=Wt,G.length-=Wt;Et[ce++]=Si[$e++],--Wt;);G.length===0&&(G.mode=21);break;case 26:if(Ft===0)break t;Et[ce++]=G.length,Ft--,G.mode=21;break;case 27:if(G.wrap){for(;Nt<32;){if(re===0)break t;re--,It|=Pt[At++]<<Nt,Nt+=8}if(pe-=Ft,tt.total_out+=pe,G.total+=pe,pe&&(tt.adler=G.check=G.flags?g(G.check,Et,pe,ce-pe):m(G.check,Et,pe,ce-pe)),pe=Ft,(G.flags?It:w(It))!==G.check){tt.msg="incorrect data check",G.mode=30;break}Nt=It=0}G.mode=28;case 28:if(G.wrap&&G.flags){for(;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(It!==(4294967295&G.total)){tt.msg="incorrect length check",G.mode=30;break}Nt=It=0}G.mode=29;case 29:Jt=1;break t;case 30:Jt=-3;break t;case 31:return-4;case 32:default:return I}return tt.next_out=ce,tt.avail_out=Ft,tt.next_in=At,tt.avail_in=re,G.hold=It,G.bits=Nt,(G.wsize||pe!==tt.avail_out&&G.mode<30&&(G.mode<27||_t!==4))&&Rt(tt,tt.output,tt.next_out,pe-tt.avail_out)?(G.mode=31,-4):(Pe-=tt.avail_in,pe-=tt.avail_out,tt.total_in+=Pe,tt.total_out+=pe,G.total+=pe,G.wrap&&pe&&(tt.adler=G.check=G.flags?g(G.check,Et,pe,tt.next_out-pe):m(G.check,Et,pe,tt.next_out-pe)),tt.data_type=G.bits+(G.last?64:0)+(G.mode===12?128:0)+(G.mode===20||G.mode===15?256:0),(Pe==0&&pe===0||_t===4)&&Jt===k&&(Jt=-5),Jt)},f.inflateEnd=function(tt){if(!tt||!tt.state)return I;var _t=tt.state;return _t.window&&(_t.window=null),tt.state=null,k},f.inflateGetHeader=function(tt,_t){var G;return tt&&tt.state&&2&(G=tt.state).wrap?((G.head=_t).done=!1,k):I},f.inflateSetDictionary=function(tt,_t){var G,Pt=_t.length;return tt&&tt.state?(G=tt.state).wrap!==0&&G.mode!==11?I:G.mode===11&&m(1,_t,Pt,0)!==G.check?-3:Rt(tt,_t,Pt,Pt)?(G.mode=31,-4):(G.havedict=1,k):I},f.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(o,c,f){var u=o("../utils/common"),m=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],g=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],v=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],S=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,O,k,I,N,E,P,w){var M,R,C,U,F,X,K,Z,ct,Rt=w.bits,tt=0,_t=0,G=0,Pt=0,Et=0,At=0,ce=0,re=0,Ft=0,It=0,Nt=null,Pe=0,pe=new u.Buf16(16),Wt=new u.Buf16(16),$e=null,Si=0;for(tt=0;tt<=15;tt++)pe[tt]=0;for(_t=0;_t<I;_t++)pe[O[k+_t]]++;for(Et=Rt,Pt=15;1<=Pt&&pe[Pt]===0;Pt--);if(Pt<Et&&(Et=Pt),Pt===0)return N[E++]=20971520,N[E++]=20971520,w.bits=1,0;for(G=1;G<Pt&&pe[G]===0;G++);for(Et<G&&(Et=G),tt=re=1;tt<=15;tt++)if(re<<=1,(re-=pe[tt])<0)return-1;if(0<re&&(b===0||Pt!==1))return-1;for(Wt[1]=0,tt=1;tt<15;tt++)Wt[tt+1]=Wt[tt]+pe[tt];for(_t=0;_t<I;_t++)O[k+_t]!==0&&(P[Wt[O[k+_t]]++]=_t);if(X=b===0?(Nt=$e=P,19):b===1?(Nt=m,Pe-=257,$e=g,Si-=257,256):(Nt=v,$e=S,-1),tt=G,F=E,ce=_t=It=0,C=-1,U=(Ft=1<<(At=Et))-1,b===1&&852<Ft||b===2&&592<Ft)return 1;for(;;){for(K=tt-ce,ct=P[_t]<X?(Z=0,P[_t]):P[_t]>X?(Z=$e[Si+P[_t]],Nt[Pe+P[_t]]):(Z=96,0),M=1<<tt-ce,G=R=1<<At;N[F+(It>>ce)+(R-=M)]=K<<24|Z<<16|ct|0,R!==0;);for(M=1<<tt-1;It&M;)M>>=1;if(M!==0?(It&=M-1,It+=M):It=0,_t++,--pe[tt]==0){if(tt===Pt)break;tt=O[k+P[_t]]}if(Et<tt&&(It&U)!==C){for(ce===0&&(ce=Et),F+=G,re=1<<(At=tt-ce);At+ce<Pt&&!((re-=pe[At+ce])<=0);)At++,re<<=1;if(Ft+=1<<At,b===1&&852<Ft||b===2&&592<Ft)return 1;N[C=It&U]=Et<<24|At<<16|F-E|0}}return It!==0&&(N[F+It]=tt-ce<<24|64<<16|0),w.bits=Et,0}},{"../utils/common":41}],51:[function(o,c,f){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(o,c,f){var u=o("../utils/common"),m=0,g=1;function v(pt){for(var Dt=pt.length;0<=--Dt;)pt[Dt]=0}var S=0,b=29,O=256,k=O+1+b,I=30,N=19,E=2*k+1,P=15,w=16,M=7,R=256,C=16,U=17,F=18,X=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],K=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],Z=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],ct=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],Rt=new Array(2*(k+2));v(Rt);var tt=new Array(2*I);v(tt);var _t=new Array(512);v(_t);var G=new Array(256);v(G);var Pt=new Array(b);v(Pt);var Et,At,ce,re=new Array(I);function Ft(pt,Dt,ie,Kt,z){this.static_tree=pt,this.extra_bits=Dt,this.extra_base=ie,this.elems=Kt,this.max_length=z,this.has_stree=pt&&pt.length}function It(pt,Dt){this.dyn_tree=pt,this.max_code=0,this.stat_desc=Dt}function Nt(pt){return pt<256?_t[pt]:_t[256+(pt>>>7)]}function Pe(pt,Dt){pt.pending_buf[pt.pending++]=255&Dt,pt.pending_buf[pt.pending++]=Dt>>>8&255}function pe(pt,Dt,ie){pt.bi_valid>w-ie?(pt.bi_buf|=Dt<<pt.bi_valid&65535,Pe(pt,pt.bi_buf),pt.bi_buf=Dt>>w-pt.bi_valid,pt.bi_valid+=ie-w):(pt.bi_buf|=Dt<<pt.bi_valid&65535,pt.bi_valid+=ie)}function Wt(pt,Dt,ie){pe(pt,ie[2*Dt],ie[2*Dt+1])}function $e(pt,Dt){for(var ie=0;ie|=1&pt,pt>>>=1,ie<<=1,0<--Dt;);return ie>>>1}function Si(pt,Dt,ie){var Kt,z,Q=new Array(P+1),st=0;for(Kt=1;Kt<=P;Kt++)Q[Kt]=st=st+ie[Kt-1]<<1;for(z=0;z<=Dt;z++){var nt=pt[2*z+1];nt!==0&&(pt[2*z]=$e(Q[nt]++,nt))}}function Oe(pt){var Dt;for(Dt=0;Dt<k;Dt++)pt.dyn_ltree[2*Dt]=0;for(Dt=0;Dt<I;Dt++)pt.dyn_dtree[2*Dt]=0;for(Dt=0;Dt<N;Dt++)pt.bl_tree[2*Dt]=0;pt.dyn_ltree[2*R]=1,pt.opt_len=pt.static_len=0,pt.last_lit=pt.matches=0}function Ge(pt){8<pt.bi_valid?Pe(pt,pt.bi_buf):0<pt.bi_valid&&(pt.pending_buf[pt.pending++]=pt.bi_buf),pt.bi_buf=0,pt.bi_valid=0}function pi(pt,Dt,ie,Kt){var z=2*Dt,Q=2*ie;return pt[z]<pt[Q]||pt[z]===pt[Q]&&Kt[Dt]<=Kt[ie]}function Di(pt,Dt,ie){for(var Kt=pt.heap[ie],z=ie<<1;z<=pt.heap_len&&(z<pt.heap_len&&pi(Dt,pt.heap[z+1],pt.heap[z],pt.depth)&&z++,!pi(Dt,Kt,pt.heap[z],pt.depth));)pt.heap[ie]=pt.heap[z],ie=z,z<<=1;pt.heap[ie]=Kt}function mn(pt,Dt,ie){var Kt,z,Q,st,nt=0;if(pt.last_lit!==0)for(;Kt=pt.pending_buf[pt.d_buf+2*nt]<<8|pt.pending_buf[pt.d_buf+2*nt+1],z=pt.pending_buf[pt.l_buf+nt],nt++,Kt===0?Wt(pt,z,Dt):(Wt(pt,(Q=G[z])+O+1,Dt),(st=X[Q])!==0&&pe(pt,z-=Pt[Q],st),Wt(pt,Q=Nt(--Kt),ie),(st=K[Q])!==0&&pe(pt,Kt-=re[Q],st)),nt<pt.last_lit;);Wt(pt,R,Dt)}function Qi(pt,Dt){var ie,Kt,z,Q=Dt.dyn_tree,st=Dt.stat_desc.static_tree,nt=Dt.stat_desc.has_stree,vt=Dt.stat_desc.elems,Ut=-1;for(pt.heap_len=0,pt.heap_max=E,ie=0;ie<vt;ie++)Q[2*ie]!==0?(pt.heap[++pt.heap_len]=Ut=ie,pt.depth[ie]=0):Q[2*ie+1]=0;for(;pt.heap_len<2;)Q[2*(z=pt.heap[++pt.heap_len]=Ut<2?++Ut:0)]=1,pt.depth[z]=0,pt.opt_len--,nt&&(pt.static_len-=st[2*z+1]);for(Dt.max_code=Ut,ie=pt.heap_len>>1;1<=ie;ie--)Di(pt,Q,ie);for(z=vt;ie=pt.heap[1],pt.heap[1]=pt.heap[pt.heap_len--],Di(pt,Q,1),Kt=pt.heap[1],pt.heap[--pt.heap_max]=ie,pt.heap[--pt.heap_max]=Kt,Q[2*z]=Q[2*ie]+Q[2*Kt],pt.depth[z]=(pt.depth[ie]>=pt.depth[Kt]?pt.depth[ie]:pt.depth[Kt])+1,Q[2*ie+1]=Q[2*Kt+1]=z,pt.heap[1]=z++,Di(pt,Q,1),2<=pt.heap_len;);pt.heap[--pt.heap_max]=pt.heap[1],function(qt,Xt){var Ne,Ie,me,we,yi,Ei,ni=Xt.dyn_tree,bi=Xt.max_code,qr=Xt.stat_desc.static_tree,sr=Xt.stat_desc.has_stree,sn=Xt.stat_desc.extra_bits,Ao=Xt.stat_desc.extra_base,zi=Xt.stat_desc.max_length,Yo=0;for(we=0;we<=P;we++)qt.bl_count[we]=0;for(ni[2*qt.heap[qt.heap_max]+1]=0,Ne=qt.heap_max+1;Ne<E;Ne++)zi<(we=ni[2*ni[2*(Ie=qt.heap[Ne])+1]+1]+1)&&(we=zi,Yo++),ni[2*Ie+1]=we,bi<Ie||(qt.bl_count[we]++,yi=0,Ao<=Ie&&(yi=sn[Ie-Ao]),Ei=ni[2*Ie],qt.opt_len+=Ei*(we+yi),sr&&(qt.static_len+=Ei*(qr[2*Ie+1]+yi)));if(Yo!==0){do{for(we=zi-1;qt.bl_count[we]===0;)we--;qt.bl_count[we]--,qt.bl_count[we+1]+=2,qt.bl_count[zi]--,Yo-=2}while(0<Yo);for(we=zi;we!==0;we--)for(Ie=qt.bl_count[we];Ie!==0;)bi<(me=qt.heap[--Ne])||(ni[2*me+1]!==we&&(qt.opt_len+=(we-ni[2*me+1])*ni[2*me],ni[2*me+1]=we),Ie--)}}(pt,Dt),Si(Q,Ut,pt.bl_count)}function W(pt,Dt,ie){var Kt,z,Q=-1,st=Dt[1],nt=0,vt=7,Ut=4;for(st===0&&(vt=138,Ut=3),Dt[2*(ie+1)+1]=65535,Kt=0;Kt<=ie;Kt++)z=st,st=Dt[2*(Kt+1)+1],++nt<vt&&z===st||(nt<Ut?pt.bl_tree[2*z]+=nt:z!==0?(z!==Q&&pt.bl_tree[2*z]++,pt.bl_tree[2*C]++):nt<=10?pt.bl_tree[2*U]++:pt.bl_tree[2*F]++,Q=z,Ut=(nt=0)===st?(vt=138,3):z===st?(vt=6,3):(vt=7,4))}function Jt(pt,Dt,ie){var Kt,z,Q=-1,st=Dt[1],nt=0,vt=7,Ut=4;for(st===0&&(vt=138,Ut=3),Kt=0;Kt<=ie;Kt++)if(z=st,st=Dt[2*(Kt+1)+1],!(++nt<vt&&z===st)){if(nt<Ut)for(;Wt(pt,z,pt.bl_tree),--nt!=0;);else z!==0?(z!==Q&&(Wt(pt,z,pt.bl_tree),nt--),Wt(pt,C,pt.bl_tree),pe(pt,nt-3,2)):nt<=10?(Wt(pt,U,pt.bl_tree),pe(pt,nt-3,3)):(Wt(pt,F,pt.bl_tree),pe(pt,nt-11,7));Q=z,Ut=(nt=0)===st?(vt=138,3):z===st?(vt=6,3):(vt=7,4)}}v(re);var jt=!1;function dt(pt,Dt,ie,Kt){pe(pt,(S<<1)+(Kt?1:0),3),function(z,Q,st,nt){Ge(z),nt&&(Pe(z,st),Pe(z,~st)),u.arraySet(z.pending_buf,z.window,Q,st,z.pending),z.pending+=st}(pt,Dt,ie,!0)}f._tr_init=function(pt){jt||(function(){var Dt,ie,Kt,z,Q,st=new Array(P+1);for(z=Kt=0;z<b-1;z++)for(Pt[z]=Kt,Dt=0;Dt<1<<X[z];Dt++)G[Kt++]=z;for(G[Kt-1]=z,z=Q=0;z<16;z++)for(re[z]=Q,Dt=0;Dt<1<<K[z];Dt++)_t[Q++]=z;for(Q>>=7;z<I;z++)for(re[z]=Q<<7,Dt=0;Dt<1<<K[z]-7;Dt++)_t[256+Q++]=z;for(ie=0;ie<=P;ie++)st[ie]=0;for(Dt=0;Dt<=143;)Rt[2*Dt+1]=8,Dt++,st[8]++;for(;Dt<=255;)Rt[2*Dt+1]=9,Dt++,st[9]++;for(;Dt<=279;)Rt[2*Dt+1]=7,Dt++,st[7]++;for(;Dt<=287;)Rt[2*Dt+1]=8,Dt++,st[8]++;for(Si(Rt,k+1,st),Dt=0;Dt<I;Dt++)tt[2*Dt+1]=5,tt[2*Dt]=$e(Dt,5);Et=new Ft(Rt,X,O+1,k,P),At=new Ft(tt,K,0,I,P),ce=new Ft(new Array(0),Z,0,N,M)}(),jt=!0),pt.l_desc=new It(pt.dyn_ltree,Et),pt.d_desc=new It(pt.dyn_dtree,At),pt.bl_desc=new It(pt.bl_tree,ce),pt.bi_buf=0,pt.bi_valid=0,Oe(pt)},f._tr_stored_block=dt,f._tr_flush_block=function(pt,Dt,ie,Kt){var z,Q,st=0;0<pt.level?(pt.strm.data_type===2&&(pt.strm.data_type=function(nt){var vt,Ut=4093624447;for(vt=0;vt<=31;vt++,Ut>>>=1)if(1&Ut&&nt.dyn_ltree[2*vt]!==0)return m;if(nt.dyn_ltree[18]!==0||nt.dyn_ltree[20]!==0||nt.dyn_ltree[26]!==0)return g;for(vt=32;vt<O;vt++)if(nt.dyn_ltree[2*vt]!==0)return g;return m}(pt)),Qi(pt,pt.l_desc),Qi(pt,pt.d_desc),st=function(nt){var vt;for(W(nt,nt.dyn_ltree,nt.l_desc.max_code),W(nt,nt.dyn_dtree,nt.d_desc.max_code),Qi(nt,nt.bl_desc),vt=N-1;3<=vt&&nt.bl_tree[2*ct[vt]+1]===0;vt--);return nt.opt_len+=3*(vt+1)+5+5+4,vt}(pt),z=pt.opt_len+3+7>>>3,(Q=pt.static_len+3+7>>>3)<=z&&(z=Q)):z=Q=ie+5,ie+4<=z&&Dt!==-1?dt(pt,Dt,ie,Kt):pt.strategy===4||Q===z?(pe(pt,2+(Kt?1:0),3),mn(pt,Rt,tt)):(pe(pt,4+(Kt?1:0),3),function(nt,vt,Ut,qt){var Xt;for(pe(nt,vt-257,5),pe(nt,Ut-1,5),pe(nt,qt-4,4),Xt=0;Xt<qt;Xt++)pe(nt,nt.bl_tree[2*ct[Xt]+1],3);Jt(nt,nt.dyn_ltree,vt-1),Jt(nt,nt.dyn_dtree,Ut-1)}(pt,pt.l_desc.max_code+1,pt.d_desc.max_code+1,st+1),mn(pt,pt.dyn_ltree,pt.dyn_dtree)),Oe(pt),Kt&&Ge(pt)},f._tr_tally=function(pt,Dt,ie){return pt.pending_buf[pt.d_buf+2*pt.last_lit]=Dt>>>8&255,pt.pending_buf[pt.d_buf+2*pt.last_lit+1]=255&Dt,pt.pending_buf[pt.l_buf+pt.last_lit]=255&ie,pt.last_lit++,Dt===0?pt.dyn_ltree[2*ie]++:(pt.matches++,Dt--,pt.dyn_ltree[2*(G[ie]+O+1)]++,pt.dyn_dtree[2*Nt(Dt)]++),pt.last_lit===pt.lit_bufsize-1},f._tr_align=function(pt){pe(pt,2,3),Wt(pt,R,Rt),function(Dt){Dt.bi_valid===16?(Pe(Dt,Dt.bi_buf),Dt.bi_buf=0,Dt.bi_valid=0):8<=Dt.bi_valid&&(Dt.pending_buf[Dt.pending++]=255&Dt.bi_buf,Dt.bi_buf>>=8,Dt.bi_valid-=8)}(pt)}},{"../utils/common":41}],53:[function(o,c,f){c.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(o,c,f){(function(u){(function(m,g){if(!m.setImmediate){var v,S,b,O,k=1,I={},N=!1,E=m.document,P=Object.getPrototypeOf&&Object.getPrototypeOf(m);P=P&&P.setTimeout?P:m,v={}.toString.call(m.process)==="[object process]"?function(C){process.nextTick(function(){M(C)})}:function(){if(m.postMessage&&!m.importScripts){var C=!0,U=m.onmessage;return m.onmessage=function(){C=!1},m.postMessage("","*"),m.onmessage=U,C}}()?(O="setImmediate$"+Math.random()+"$",m.addEventListener?m.addEventListener("message",R,!1):m.attachEvent("onmessage",R),function(C){m.postMessage(O+C,"*")}):m.MessageChannel?((b=new MessageChannel).port1.onmessage=function(C){M(C.data)},function(C){b.port2.postMessage(C)}):E&&"onreadystatechange"in E.createElement("script")?(S=E.documentElement,function(C){var U=E.createElement("script");U.onreadystatechange=function(){M(C),U.onreadystatechange=null,S.removeChild(U),U=null},S.appendChild(U)}):function(C){setTimeout(M,0,C)},P.setImmediate=function(C){typeof C!="function"&&(C=new Function(""+C));for(var U=new Array(arguments.length-1),F=0;F<U.length;F++)U[F]=arguments[F+1];var X={callback:C,args:U};return I[k]=X,v(k),k++},P.clearImmediate=w}function w(C){delete I[C]}function M(C){if(N)setTimeout(M,0,C);else{var U=I[C];if(U){N=!0;try{(function(F){var X=F.callback,K=F.args;switch(K.length){case 0:X();break;case 1:X(K[0]);break;case 2:X(K[0],K[1]);break;case 3:X(K[0],K[1],K[2]);break;default:X.apply(g,K)}})(U)}finally{w(C),N=!1}}}}function R(C){C.source===m&&typeof C.data=="string"&&C.data.indexOf(O)===0&&M(+C.data.slice(O.length))}})(typeof self>"u"?u===void 0?this:u:self)}).call(this,typeof Er<"u"?Er:typeof self<"u"?self:typeof window<"u"?window:{})},{}]},{},[10])(10)})})(Cf);var dm=Cf.exports;const pm=tc(dm);var Af={exports:{}};(function(x,a){(function(o,c){c()})(Er,function(){function o(S,b){return typeof b>"u"?b={autoBom:!1}:typeof b!="object"&&(b={autoBom:!b}),b.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(S.type)?new Blob(["\uFEFF",S],{type:S.type}):S}function c(S,b,O){var k=new XMLHttpRequest;k.open("GET",S),k.responseType="blob",k.onload=function(){v(k.response,b,O)},k.onerror=function(){},k.send()}function f(S){var b=new XMLHttpRequest;b.open("HEAD",S,!1);try{b.send()}catch{}return 200<=b.status&&299>=b.status}function u(S){try{S.dispatchEvent(new MouseEvent("click"))}catch{var b=document.createEvent("MouseEvents");b.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),S.dispatchEvent(b)}}var m=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof Er=="object"&&Er.global===Er?Er:void 0,g=m.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),v=m.saveAs||(typeof window!="object"||window!==m?function(){}:"download"in HTMLAnchorElement.prototype&&!g?function(S,b,O){var k=m.URL||m.webkitURL,I=document.createElement("a");b=b||S.name||"download",I.download=b,I.rel="noopener",typeof S=="string"?(I.href=S,I.origin===location.origin?u(I):f(I.href)?c(S,b,O):u(I,I.target="_blank")):(I.href=k.createObjectURL(S),setTimeout(function(){k.revokeObjectURL(I.href)},4e4),setTimeout(function(){u(I)},0))}:"msSaveOrOpenBlob"in navigator?function(S,b,O){if(b=b||S.name||"download",typeof S!="string")navigator.msSaveOrOpenBlob(o(S,O),b);else if(f(S))c(S,b,O);else{var k=document.createElement("a");k.href=S,k.target="_blank",setTimeout(function(){u(k)})}}:function(S,b,O,k){if(k=k||open("","_blank"),k&&(k.document.title=k.document.body.innerText="downloading..."),typeof S=="string")return c(S,b,O);var I=S.type==="application/octet-stream",N=/constructor/i.test(m.HTMLElement)||m.safari,E=/CriOS\/[\d]+/.test(navigator.userAgent);if((E||I&&N||g)&&typeof FileReader<"u"){var P=new FileReader;P.onloadend=function(){var R=P.result;R=E?R:R.replace(/^data:[^;]*;/,"data:attachment/file;"),k?k.location.href=R:location=R,k=null},P.readAsDataURL(S)}else{var w=m.URL||m.webkitURL,M=w.createObjectURL(S);k?k.location=M:location.href=M,k=null,setTimeout(function(){w.revokeObjectURL(M)},4e4)}});m.saveAs=v.saveAs=v,x.exports=v})})(Af);var mm=Af.exports;const gm=tc(mm);class vm{constructor(a,o){window.mars3d&&(this.panoramicViewClass=o,this.coordinate=[{heading:0,pitch:0,stop:5},{heading:90,pitch:0,stop:5},{heading:180,pitch:0,stop:5},{heading:270,pitch:0,stop:5},{heading:0,pitch:90,stop:5},{heading:0,pitch:-90,stop:5}],this.screenshotArray=[],this.events={},this.timestamp=0,this.lat,this.lng,this.alt)}start(a=!0){var o,c;if(a){window.map.container.getElementsByClassName("mars3d-locationbar")&&(window.map.container.getElementsByClassName("mars3d-locationbar")[0].style.display="none"),this.timestamp=new Date().getTime();const f=document.getElementById("app"),u=window.innerHeight,m=document.getElementById("mars3dContainer");m&&(m.style.width=u.toString()+"px",m.style.height=u.toString()+"px"),f!==null&&f.classList.add(this.panoramicViewClass);let{lat:g,lng:v,alt:S}=window.map.getCameraView();this.lat=g,this.lng=v,this.alt=S,window.map.viewer.scene.camera.frustum.fov=window.Cesium.Math.PI_OVER_THREE*1.5}this.screenshotArray&&this.coordinate?this.coordinate[(o=this.screenshotArray)==null?void 0:o.length]?window.map.setCameraView({lat:this.lat,lng:this.lng,alt:this.alt,...this.coordinate[(c=this.screenshotArray)==null?void 0:c.length]},{complete:()=>{setTimeout(()=>{var f;this.screenshot((f=this.screenshotArray)==null?void 0:f.length)},100)}}):(this.downloadImagesAsZip(),this.screenshotArray=[]):this.emit("state",{type:"error"})}async screenshot(a){const o=await window.map.expImage({download:!1}),c=window.map.container.getElementsByClassName("cesium-viewer-cesiumWidgetContainer"),f=await window.domtoimage.toPng(window.map.container,{filter:u=>u!==c[0]});this.mergeImage(o.image,f,o.width,o.height).then(u=>{var v;let m=Number(a)+1,g={src:u,name:"全景图_"+this.timestamp+"_"+m+".jpg"};this.emit("intercept",g),(v=this.screenshotArray)==null||v.push(g),this.start(!1)})}mergeImage(a,o,c,f){return new Promise((u,m)=>{const g=document.createElement("canvas");g.width=c,g.height=f;const v=g.getContext("2d");if(g&&v){const S=new Image;S.crossOrigin="Anonymous",S.onload=()=>{v.drawImage(S,0,0,c,f);const b=new Image;b.crossOrigin="Anonymous",b.onload=()=>{v.drawImage(b,0,0,c,f);const O=g.toDataURL("image/png");u(O)},b.src=o},S.src=a}else m()})}download(){this.screenshotArray&&this.screenshotArray.forEach(a=>{window.mars3d.Util.downloadBase64Image(a.name,a.src)})}async downloadImagesAsZip(){if(this.screenshotArray){const a=new pm;this.screenshotArray.forEach(c=>{const f=c.src.split(",")[1],u=atob(f),m=[];for(let S=0;S<u.length;S+=1024){const b=u.slice(S,S+1024),O=new Array(b.length);for(let I=0;I<b.length;I++)O[I]=b.charCodeAt(I);const k=new Uint8Array(O);m.push(k)}const g=new Blob(m,{type:"image/jpeg"}),v=`${c.name}`;a.file(v,g,{binary:!0})});const o=await a.generateAsync({type:"blob"});gm(o,"CHBIM-Panorama.zip"),this.emit("state",{type:"success",schedule:100}),this.init()}}init(){const a=document.getElementById("app");a&&a.classList.remove(this.panoramicViewClass);const o=document.getElementById("mars3dContainer");o&&(o.style.width="",o.style.height=""),window.map.container.getElementsByClassName("mars3d-locationbar")&&(window.map.container.getElementsByClassName("mars3d-locationbar")[0].style.display="")}on(a,o){this.events[a]?this.events[a].push(o):this.events[a]=[o]}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}}function fs(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}function Pf(x,a){x.prototype=Object.create(a.prototype),x.prototype.constructor=x,x.__proto__=a}/*!
|
|
2685
|
+
*/(function(x,a){(function(o){x.exports=o()})(function(){return function o(c,f,u){function m(S,b){if(!f[S]){if(!c[S]){var O=typeof hu=="function"&&hu;if(!b&&O)return O(S,!0);if(g)return g(S,!0);var k=new Error("Cannot find module '"+S+"'");throw k.code="MODULE_NOT_FOUND",k}var I=f[S]={exports:{}};c[S][0].call(I.exports,function(F){var E=c[S][1][F];return m(E||F)},I,I.exports,o,c,f,u)}return f[S].exports}for(var g=typeof hu=="function"&&hu,v=0;v<u.length;v++)m(u[v]);return m}({1:[function(o,c,f){var u=o("./utils"),m=o("./support"),g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";f.encode=function(v){for(var S,b,O,k,I,F,E,P=[],w=0,M=v.length,R=M,C=u.getTypeOf(v)!=="string";w<v.length;)R=M-w,O=C?(S=v[w++],b=w<M?v[w++]:0,w<M?v[w++]:0):(S=v.charCodeAt(w++),b=w<M?v.charCodeAt(w++):0,w<M?v.charCodeAt(w++):0),k=S>>2,I=(3&S)<<4|b>>4,F=1<R?(15&b)<<2|O>>6:64,E=2<R?63&O:64,P.push(g.charAt(k)+g.charAt(I)+g.charAt(F)+g.charAt(E));return P.join("")},f.decode=function(v){var S,b,O,k,I,F,E=0,P=0,w="data:";if(v.substr(0,w.length)===w)throw new Error("Invalid base64 input, it looks like a data url.");var M,R=3*(v=v.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(v.charAt(v.length-1)===g.charAt(64)&&R--,v.charAt(v.length-2)===g.charAt(64)&&R--,R%1!=0)throw new Error("Invalid base64 input, bad content length.");for(M=m.uint8array?new Uint8Array(0|R):new Array(0|R);E<v.length;)S=g.indexOf(v.charAt(E++))<<2|(k=g.indexOf(v.charAt(E++)))>>4,b=(15&k)<<4|(I=g.indexOf(v.charAt(E++)))>>2,O=(3&I)<<6|(F=g.indexOf(v.charAt(E++))),M[P++]=S,I!==64&&(M[P++]=b),F!==64&&(M[P++]=O);return M}},{"./support":30,"./utils":32}],2:[function(o,c,f){var u=o("./external"),m=o("./stream/DataWorker"),g=o("./stream/Crc32Probe"),v=o("./stream/DataLengthProbe");function S(b,O,k,I,F){this.compressedSize=b,this.uncompressedSize=O,this.crc32=k,this.compression=I,this.compressedContent=F}S.prototype={getContentWorker:function(){var b=new m(u.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new v("data_length")),O=this;return b.on("end",function(){if(this.streamInfo.data_length!==O.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),b},getCompressedWorker:function(){return new m(u.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},S.createWorkerFrom=function(b,O,k){return b.pipe(new g).pipe(new v("uncompressedSize")).pipe(O.compressWorker(k)).pipe(new v("compressedSize")).withStreamInfo("compression",O)},c.exports=S},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(o,c,f){var u=o("./stream/GenericWorker");f.STORE={magic:"\0\0",compressWorker:function(){return new u("STORE compression")},uncompressWorker:function(){return new u("STORE decompression")}},f.DEFLATE=o("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(o,c,f){var u=o("./utils"),m=function(){for(var g,v=[],S=0;S<256;S++){g=S;for(var b=0;b<8;b++)g=1&g?3988292384^g>>>1:g>>>1;v[S]=g}return v}();c.exports=function(g,v){return g!==void 0&&g.length?u.getTypeOf(g)!=="string"?function(S,b,O,k){var I=m,F=k+O;S^=-1;for(var E=k;E<F;E++)S=S>>>8^I[255&(S^b[E])];return-1^S}(0|v,g,g.length,0):function(S,b,O,k){var I=m,F=k+O;S^=-1;for(var E=k;E<F;E++)S=S>>>8^I[255&(S^b.charCodeAt(E))];return-1^S}(0|v,g,g.length,0):0}},{"./utils":32}],5:[function(o,c,f){f.base64=!1,f.binary=!1,f.dir=!1,f.createFolders=!0,f.date=null,f.compression=null,f.compressionOptions=null,f.comment=null,f.unixPermissions=null,f.dosPermissions=null},{}],6:[function(o,c,f){var u=null;u=typeof Promise<"u"?Promise:o("lie"),c.exports={Promise:u}},{lie:37}],7:[function(o,c,f){var u=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",m=o("pako"),g=o("./utils"),v=o("./stream/GenericWorker"),S=u?"uint8array":"array";function b(O,k){v.call(this,"FlateWorker/"+O),this._pako=null,this._pakoAction=O,this._pakoOptions=k,this.meta={}}f.magic="\b\0",g.inherits(b,v),b.prototype.processChunk=function(O){this.meta=O.meta,this._pako===null&&this._createPako(),this._pako.push(g.transformTo(S,O.data),!1)},b.prototype.flush=function(){v.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)},b.prototype.cleanUp=function(){v.prototype.cleanUp.call(this),this._pako=null},b.prototype._createPako=function(){this._pako=new m[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var O=this;this._pako.onData=function(k){O.push({data:k,meta:O.meta})}},f.compressWorker=function(O){return new b("Deflate",O)},f.uncompressWorker=function(){return new b("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(o,c,f){function u(I,F){var E,P="";for(E=0;E<F;E++)P+=String.fromCharCode(255&I),I>>>=8;return P}function m(I,F,E,P,w,M){var R,C,U=I.file,N=I.compression,X=M!==S.utf8encode,J=g.transformTo("string",M(U.name)),Z=g.transformTo("string",S.utf8encode(U.name)),ct=U.comment,Rt=g.transformTo("string",M(ct)),tt=g.transformTo("string",S.utf8encode(ct)),_t=Z.length!==U.name.length,G=tt.length!==ct.length,Pt="",Et="",At="",ce=U.dir,re=U.date,Ft={crc32:0,compressedSize:0,uncompressedSize:0};F&&!E||(Ft.crc32=I.crc32,Ft.compressedSize=I.compressedSize,Ft.uncompressedSize=I.uncompressedSize);var It=0;F&&(It|=8),X||!_t&&!G||(It|=2048);var Nt=0,Pe=0;ce&&(Nt|=16),w==="UNIX"?(Pe=798,Nt|=function(Wt,$e){var Si=Wt;return Wt||(Si=$e?16893:33204),(65535&Si)<<16}(U.unixPermissions,ce)):(Pe=20,Nt|=function(Wt){return 63&(Wt||0)}(U.dosPermissions)),R=re.getUTCHours(),R<<=6,R|=re.getUTCMinutes(),R<<=5,R|=re.getUTCSeconds()/2,C=re.getUTCFullYear()-1980,C<<=4,C|=re.getUTCMonth()+1,C<<=5,C|=re.getUTCDate(),_t&&(Et=u(1,1)+u(b(J),4)+Z,Pt+="up"+u(Et.length,2)+Et),G&&(At=u(1,1)+u(b(Rt),4)+tt,Pt+="uc"+u(At.length,2)+At);var pe="";return pe+=`
|
|
2686
|
+
\0`,pe+=u(It,2),pe+=N.magic,pe+=u(R,2),pe+=u(C,2),pe+=u(Ft.crc32,4),pe+=u(Ft.compressedSize,4),pe+=u(Ft.uncompressedSize,4),pe+=u(J.length,2),pe+=u(Pt.length,2),{fileRecord:O.LOCAL_FILE_HEADER+pe+J+Pt,dirRecord:O.CENTRAL_FILE_HEADER+u(Pe,2)+pe+u(Rt.length,2)+"\0\0\0\0"+u(Nt,4)+u(P,4)+J+Pt+Rt}}var g=o("../utils"),v=o("../stream/GenericWorker"),S=o("../utf8"),b=o("../crc32"),O=o("../signature");function k(I,F,E,P){v.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=F,this.zipPlatform=E,this.encodeFileName=P,this.streamFiles=I,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}g.inherits(k,v),k.prototype.push=function(I){var F=I.meta.percent||0,E=this.entriesCount,P=this._sources.length;this.accumulate?this.contentBuffer.push(I):(this.bytesWritten+=I.data.length,v.prototype.push.call(this,{data:I.data,meta:{currentFile:this.currentFile,percent:E?(F+100*(E-P-1))/E:100}}))},k.prototype.openedSource=function(I){this.currentSourceOffset=this.bytesWritten,this.currentFile=I.file.name;var F=this.streamFiles&&!I.file.dir;if(F){var E=m(I,F,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:E.fileRecord,meta:{percent:0}})}else this.accumulate=!0},k.prototype.closedSource=function(I){this.accumulate=!1;var F=this.streamFiles&&!I.file.dir,E=m(I,F,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(E.dirRecord),F)this.push({data:function(P){return O.DATA_DESCRIPTOR+u(P.crc32,4)+u(P.compressedSize,4)+u(P.uncompressedSize,4)}(I),meta:{percent:100}});else for(this.push({data:E.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},k.prototype.flush=function(){for(var I=this.bytesWritten,F=0;F<this.dirRecords.length;F++)this.push({data:this.dirRecords[F],meta:{percent:100}});var E=this.bytesWritten-I,P=function(w,M,R,C,U){var N=g.transformTo("string",U(C));return O.CENTRAL_DIRECTORY_END+"\0\0\0\0"+u(w,2)+u(w,2)+u(M,4)+u(R,4)+u(N.length,2)+N}(this.dirRecords.length,E,I,this.zipComment,this.encodeFileName);this.push({data:P,meta:{percent:100}})},k.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},k.prototype.registerPrevious=function(I){this._sources.push(I);var F=this;return I.on("data",function(E){F.processChunk(E)}),I.on("end",function(){F.closedSource(F.previous.streamInfo),F._sources.length?F.prepareNextSource():F.end()}),I.on("error",function(E){F.error(E)}),this},k.prototype.resume=function(){return!!v.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},k.prototype.error=function(I){var F=this._sources;if(!v.prototype.error.call(this,I))return!1;for(var E=0;E<F.length;E++)try{F[E].error(I)}catch{}return!0},k.prototype.lock=function(){v.prototype.lock.call(this);for(var I=this._sources,F=0;F<I.length;F++)I[F].lock()},c.exports=k},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(o,c,f){var u=o("../compressions"),m=o("./ZipFileWorker");f.generateWorker=function(g,v,S){var b=new m(v.streamFiles,S,v.platform,v.encodeFileName),O=0;try{g.forEach(function(k,I){O++;var F=function(M,R){var C=M||R,U=u[C];if(!U)throw new Error(C+" is not a valid compression method !");return U}(I.options.compression,v.compression),E=I.options.compressionOptions||v.compressionOptions||{},P=I.dir,w=I.date;I._compressWorker(F,E).withStreamInfo("file",{name:k,dir:P,date:w,comment:I.comment||"",unixPermissions:I.unixPermissions,dosPermissions:I.dosPermissions}).pipe(b)}),b.entriesCount=O}catch(k){b.error(k)}return b}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(o,c,f){function u(){if(!(this instanceof u))return new u;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var m=new u;for(var g in this)typeof this[g]!="function"&&(m[g]=this[g]);return m}}(u.prototype=o("./object")).loadAsync=o("./load"),u.support=o("./support"),u.defaults=o("./defaults"),u.version="3.10.1",u.loadAsync=function(m,g){return new u().loadAsync(m,g)},u.external=o("./external"),c.exports=u},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(o,c,f){var u=o("./utils"),m=o("./external"),g=o("./utf8"),v=o("./zipEntries"),S=o("./stream/Crc32Probe"),b=o("./nodejsUtils");function O(k){return new m.Promise(function(I,F){var E=k.decompressed.getContentWorker().pipe(new S);E.on("error",function(P){F(P)}).on("end",function(){E.streamInfo.crc32!==k.decompressed.crc32?F(new Error("Corrupted zip : CRC32 mismatch")):I()}).resume()})}c.exports=function(k,I){var F=this;return I=u.extend(I||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:g.utf8decode}),b.isNode&&b.isStream(k)?m.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):u.prepareContent("the loaded zip file",k,!0,I.optimizedBinaryString,I.base64).then(function(E){var P=new v(I);return P.load(E),P}).then(function(E){var P=[m.Promise.resolve(E)],w=E.files;if(I.checkCRC32)for(var M=0;M<w.length;M++)P.push(O(w[M]));return m.Promise.all(P)}).then(function(E){for(var P=E.shift(),w=P.files,M=0;M<w.length;M++){var R=w[M],C=R.fileNameStr,U=u.resolve(R.fileNameStr);F.file(U,R.decompressed,{binary:!0,optimizedBinaryString:!0,date:R.date,dir:R.dir,comment:R.fileCommentStr.length?R.fileCommentStr:null,unixPermissions:R.unixPermissions,dosPermissions:R.dosPermissions,createFolders:I.createFolders}),R.dir||(F.file(U).unsafeOriginalName=C)}return P.zipComment.length&&(F.comment=P.zipComment),F})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(o,c,f){var u=o("../utils"),m=o("../stream/GenericWorker");function g(v,S){m.call(this,"Nodejs stream input adapter for "+v),this._upstreamEnded=!1,this._bindStream(S)}u.inherits(g,m),g.prototype._bindStream=function(v){var S=this;(this._stream=v).pause(),v.on("data",function(b){S.push({data:b,meta:{percent:0}})}).on("error",function(b){S.isPaused?this.generatedError=b:S.error(b)}).on("end",function(){S.isPaused?S._upstreamEnded=!0:S.end()})},g.prototype.pause=function(){return!!m.prototype.pause.call(this)&&(this._stream.pause(),!0)},g.prototype.resume=function(){return!!m.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},c.exports=g},{"../stream/GenericWorker":28,"../utils":32}],13:[function(o,c,f){var u=o("readable-stream").Readable;function m(g,v,S){u.call(this,v),this._helper=g;var b=this;g.on("data",function(O,k){b.push(O)||b._helper.pause(),S&&S(k)}).on("error",function(O){b.emit("error",O)}).on("end",function(){b.push(null)})}o("../utils").inherits(m,u),m.prototype._read=function(){this._helper.resume()},c.exports=m},{"../utils":32,"readable-stream":16}],14:[function(o,c,f){c.exports={isNode:typeof Buffer<"u",newBufferFrom:function(u,m){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(u,m);if(typeof u=="number")throw new Error('The "data" argument must not be a number');return new Buffer(u,m)},allocBuffer:function(u){if(Buffer.alloc)return Buffer.alloc(u);var m=new Buffer(u);return m.fill(0),m},isBuffer:function(u){return Buffer.isBuffer(u)},isStream:function(u){return u&&typeof u.on=="function"&&typeof u.pause=="function"&&typeof u.resume=="function"}}},{}],15:[function(o,c,f){function u(U,N,X){var J,Z=g.getTypeOf(N),ct=g.extend(X||{},b);ct.date=ct.date||new Date,ct.compression!==null&&(ct.compression=ct.compression.toUpperCase()),typeof ct.unixPermissions=="string"&&(ct.unixPermissions=parseInt(ct.unixPermissions,8)),ct.unixPermissions&&16384&ct.unixPermissions&&(ct.dir=!0),ct.dosPermissions&&16&ct.dosPermissions&&(ct.dir=!0),ct.dir&&(U=w(U)),ct.createFolders&&(J=P(U))&&M.call(this,J,!0);var Rt=Z==="string"&&ct.binary===!1&&ct.base64===!1;X&&X.binary!==void 0||(ct.binary=!Rt),(N instanceof O&&N.uncompressedSize===0||ct.dir||!N||N.length===0)&&(ct.base64=!1,ct.binary=!0,N="",ct.compression="STORE",Z="string");var tt=null;tt=N instanceof O||N instanceof v?N:F.isNode&&F.isStream(N)?new E(U,N):g.prepareContent(U,N,ct.binary,ct.optimizedBinaryString,ct.base64);var _t=new k(U,tt,ct);this.files[U]=_t}var m=o("./utf8"),g=o("./utils"),v=o("./stream/GenericWorker"),S=o("./stream/StreamHelper"),b=o("./defaults"),O=o("./compressedObject"),k=o("./zipObject"),I=o("./generate"),F=o("./nodejsUtils"),E=o("./nodejs/NodejsStreamInputAdapter"),P=function(U){U.slice(-1)==="/"&&(U=U.substring(0,U.length-1));var N=U.lastIndexOf("/");return 0<N?U.substring(0,N):""},w=function(U){return U.slice(-1)!=="/"&&(U+="/"),U},M=function(U,N){return N=N!==void 0?N:b.createFolders,U=w(U),this.files[U]||u.call(this,U,null,{dir:!0,createFolders:N}),this.files[U]};function R(U){return Object.prototype.toString.call(U)==="[object RegExp]"}var C={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(U){var N,X,J;for(N in this.files)J=this.files[N],(X=N.slice(this.root.length,N.length))&&N.slice(0,this.root.length)===this.root&&U(X,J)},filter:function(U){var N=[];return this.forEach(function(X,J){U(X,J)&&N.push(J)}),N},file:function(U,N,X){if(arguments.length!==1)return U=this.root+U,u.call(this,U,N,X),this;if(R(U)){var J=U;return this.filter(function(ct,Rt){return!Rt.dir&&J.test(ct)})}var Z=this.files[this.root+U];return Z&&!Z.dir?Z:null},folder:function(U){if(!U)return this;if(R(U))return this.filter(function(Z,ct){return ct.dir&&U.test(Z)});var N=this.root+U,X=M.call(this,N),J=this.clone();return J.root=X.name,J},remove:function(U){U=this.root+U;var N=this.files[U];if(N||(U.slice(-1)!=="/"&&(U+="/"),N=this.files[U]),N&&!N.dir)delete this.files[U];else for(var X=this.filter(function(Z,ct){return ct.name.slice(0,U.length)===U}),J=0;J<X.length;J++)delete this.files[X[J].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(U){var N,X={};try{if((X=g.extend(U||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:m.utf8encode})).type=X.type.toLowerCase(),X.compression=X.compression.toUpperCase(),X.type==="binarystring"&&(X.type="string"),!X.type)throw new Error("No output type specified.");g.checkSupport(X.type),X.platform!=="darwin"&&X.platform!=="freebsd"&&X.platform!=="linux"&&X.platform!=="sunos"||(X.platform="UNIX"),X.platform==="win32"&&(X.platform="DOS");var J=X.comment||this.comment||"";N=I.generateWorker(this,X,J)}catch(Z){(N=new v("error")).error(Z)}return new S(N,X.type||"string",X.mimeType)},generateAsync:function(U,N){return this.generateInternalStream(U).accumulate(N)},generateNodeStream:function(U,N){return(U=U||{}).type||(U.type="nodebuffer"),this.generateInternalStream(U).toNodejsStream(N)}};c.exports=C},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(o,c,f){c.exports=o("stream")},{stream:void 0}],17:[function(o,c,f){var u=o("./DataReader");function m(g){u.call(this,g);for(var v=0;v<this.data.length;v++)g[v]=255&g[v]}o("../utils").inherits(m,u),m.prototype.byteAt=function(g){return this.data[this.zero+g]},m.prototype.lastIndexOfSignature=function(g){for(var v=g.charCodeAt(0),S=g.charCodeAt(1),b=g.charCodeAt(2),O=g.charCodeAt(3),k=this.length-4;0<=k;--k)if(this.data[k]===v&&this.data[k+1]===S&&this.data[k+2]===b&&this.data[k+3]===O)return k-this.zero;return-1},m.prototype.readAndCheckSignature=function(g){var v=g.charCodeAt(0),S=g.charCodeAt(1),b=g.charCodeAt(2),O=g.charCodeAt(3),k=this.readData(4);return v===k[0]&&S===k[1]&&b===k[2]&&O===k[3]},m.prototype.readData=function(g){if(this.checkOffset(g),g===0)return[];var v=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./DataReader":18}],18:[function(o,c,f){var u=o("../utils");function m(g){this.data=g,this.length=g.length,this.index=0,this.zero=0}m.prototype={checkOffset:function(g){this.checkIndex(this.index+g)},checkIndex:function(g){if(this.length<this.zero+g||g<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+g+"). Corrupted zip ?")},setIndex:function(g){this.checkIndex(g),this.index=g},skip:function(g){this.setIndex(this.index+g)},byteAt:function(){},readInt:function(g){var v,S=0;for(this.checkOffset(g),v=this.index+g-1;v>=this.index;v--)S=(S<<8)+this.byteAt(v);return this.index+=g,S},readString:function(g){return u.transformTo("string",this.readData(g))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var g=this.readInt(4);return new Date(Date.UTC(1980+(g>>25&127),(g>>21&15)-1,g>>16&31,g>>11&31,g>>5&63,(31&g)<<1))}},c.exports=m},{"../utils":32}],19:[function(o,c,f){var u=o("./Uint8ArrayReader");function m(g){u.call(this,g)}o("../utils").inherits(m,u),m.prototype.readData=function(g){this.checkOffset(g);var v=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(o,c,f){var u=o("./DataReader");function m(g){u.call(this,g)}o("../utils").inherits(m,u),m.prototype.byteAt=function(g){return this.data.charCodeAt(this.zero+g)},m.prototype.lastIndexOfSignature=function(g){return this.data.lastIndexOf(g)-this.zero},m.prototype.readAndCheckSignature=function(g){return g===this.readData(4)},m.prototype.readData=function(g){this.checkOffset(g);var v=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./DataReader":18}],21:[function(o,c,f){var u=o("./ArrayReader");function m(g){u.call(this,g)}o("../utils").inherits(m,u),m.prototype.readData=function(g){if(this.checkOffset(g),g===0)return new Uint8Array(0);var v=this.data.subarray(this.zero+this.index,this.zero+this.index+g);return this.index+=g,v},c.exports=m},{"../utils":32,"./ArrayReader":17}],22:[function(o,c,f){var u=o("../utils"),m=o("../support"),g=o("./ArrayReader"),v=o("./StringReader"),S=o("./NodeBufferReader"),b=o("./Uint8ArrayReader");c.exports=function(O){var k=u.getTypeOf(O);return u.checkSupport(k),k!=="string"||m.uint8array?k==="nodebuffer"?new S(O):m.uint8array?new b(u.transformTo("uint8array",O)):new g(u.transformTo("array",O)):new v(O)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(o,c,f){f.LOCAL_FILE_HEADER="PK",f.CENTRAL_FILE_HEADER="PK",f.CENTRAL_DIRECTORY_END="PK",f.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",f.ZIP64_CENTRAL_DIRECTORY_END="PK",f.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(o,c,f){var u=o("./GenericWorker"),m=o("../utils");function g(v){u.call(this,"ConvertWorker to "+v),this.destType=v}m.inherits(g,u),g.prototype.processChunk=function(v){this.push({data:m.transformTo(this.destType,v.data),meta:v.meta})},c.exports=g},{"../utils":32,"./GenericWorker":28}],25:[function(o,c,f){var u=o("./GenericWorker"),m=o("../crc32");function g(){u.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}o("../utils").inherits(g,u),g.prototype.processChunk=function(v){this.streamInfo.crc32=m(v.data,this.streamInfo.crc32||0),this.push(v)},c.exports=g},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(o,c,f){var u=o("../utils"),m=o("./GenericWorker");function g(v){m.call(this,"DataLengthProbe for "+v),this.propName=v,this.withStreamInfo(v,0)}u.inherits(g,m),g.prototype.processChunk=function(v){if(v){var S=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=S+v.data.length}m.prototype.processChunk.call(this,v)},c.exports=g},{"../utils":32,"./GenericWorker":28}],27:[function(o,c,f){var u=o("../utils"),m=o("./GenericWorker");function g(v){m.call(this,"DataWorker");var S=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,v.then(function(b){S.dataIsReady=!0,S.data=b,S.max=b&&b.length||0,S.type=u.getTypeOf(b),S.isPaused||S._tickAndRepeat()},function(b){S.error(b)})}u.inherits(g,m),g.prototype.cleanUp=function(){m.prototype.cleanUp.call(this),this.data=null},g.prototype.resume=function(){return!!m.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,u.delay(this._tickAndRepeat,[],this)),!0)},g.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(u.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},g.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var v=null,S=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":v=this.data.substring(this.index,S);break;case"uint8array":v=this.data.subarray(this.index,S);break;case"array":case"nodebuffer":v=this.data.slice(this.index,S)}return this.index=S,this.push({data:v,meta:{percent:this.max?this.index/this.max*100:0}})},c.exports=g},{"../utils":32,"./GenericWorker":28}],28:[function(o,c,f){function u(m){this.name=m||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}u.prototype={push:function(m){this.emit("data",m)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(m){this.emit("error",m)}return!0},error:function(m){return!this.isFinished&&(this.isPaused?this.generatedError=m:(this.isFinished=!0,this.emit("error",m),this.previous&&this.previous.error(m),this.cleanUp()),!0)},on:function(m,g){return this._listeners[m].push(g),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(m,g){if(this._listeners[m])for(var v=0;v<this._listeners[m].length;v++)this._listeners[m][v].call(this,g)},pipe:function(m){return m.registerPrevious(this)},registerPrevious:function(m){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=m.streamInfo,this.mergeStreamInfo(),this.previous=m;var g=this;return m.on("data",function(v){g.processChunk(v)}),m.on("end",function(){g.end()}),m.on("error",function(v){g.error(v)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var m=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),m=!0),this.previous&&this.previous.resume(),!m},flush:function(){},processChunk:function(m){this.push(m)},withStreamInfo:function(m,g){return this.extraStreamInfo[m]=g,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var m in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,m)&&(this.streamInfo[m]=this.extraStreamInfo[m])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var m="Worker "+this.name;return this.previous?this.previous+" -> "+m:m}},c.exports=u},{}],29:[function(o,c,f){var u=o("../utils"),m=o("./ConvertWorker"),g=o("./GenericWorker"),v=o("../base64"),S=o("../support"),b=o("../external"),O=null;if(S.nodestream)try{O=o("../nodejs/NodejsStreamOutputAdapter")}catch{}function k(F,E){return new b.Promise(function(P,w){var M=[],R=F._internalType,C=F._outputType,U=F._mimeType;F.on("data",function(N,X){M.push(N),E&&E(X)}).on("error",function(N){M=[],w(N)}).on("end",function(){try{var N=function(X,J,Z){switch(X){case"blob":return u.newBlob(u.transformTo("arraybuffer",J),Z);case"base64":return v.encode(J);default:return u.transformTo(X,J)}}(C,function(X,J){var Z,ct=0,Rt=null,tt=0;for(Z=0;Z<J.length;Z++)tt+=J[Z].length;switch(X){case"string":return J.join("");case"array":return Array.prototype.concat.apply([],J);case"uint8array":for(Rt=new Uint8Array(tt),Z=0;Z<J.length;Z++)Rt.set(J[Z],ct),ct+=J[Z].length;return Rt;case"nodebuffer":return Buffer.concat(J);default:throw new Error("concat : unsupported type '"+X+"'")}}(R,M),U);P(N)}catch(X){w(X)}M=[]}).resume()})}function I(F,E,P){var w=E;switch(E){case"blob":case"arraybuffer":w="uint8array";break;case"base64":w="string"}try{this._internalType=w,this._outputType=E,this._mimeType=P,u.checkSupport(w),this._worker=F.pipe(new m(w)),F.lock()}catch(M){this._worker=new g("error"),this._worker.error(M)}}I.prototype={accumulate:function(F){return k(this,F)},on:function(F,E){var P=this;return F==="data"?this._worker.on(F,function(w){E.call(P,w.data,w.meta)}):this._worker.on(F,function(){u.delay(E,arguments,P)}),this},resume:function(){return u.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(F){if(u.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new O(this,{objectMode:this._outputType!=="nodebuffer"},F)}},c.exports=I},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(o,c,f){if(f.base64=!0,f.array=!0,f.string=!0,f.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",f.nodebuffer=typeof Buffer<"u",f.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")f.blob=!1;else{var u=new ArrayBuffer(0);try{f.blob=new Blob([u],{type:"application/zip"}).size===0}catch{try{var m=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);m.append(u),f.blob=m.getBlob("application/zip").size===0}catch{f.blob=!1}}}try{f.nodestream=!!o("readable-stream").Readable}catch{f.nodestream=!1}},{"readable-stream":16}],31:[function(o,c,f){for(var u=o("./utils"),m=o("./support"),g=o("./nodejsUtils"),v=o("./stream/GenericWorker"),S=new Array(256),b=0;b<256;b++)S[b]=252<=b?6:248<=b?5:240<=b?4:224<=b?3:192<=b?2:1;S[254]=S[254]=1;function O(){v.call(this,"utf-8 decode"),this.leftOver=null}function k(){v.call(this,"utf-8 encode")}f.utf8encode=function(I){return m.nodebuffer?g.newBufferFrom(I,"utf-8"):function(F){var E,P,w,M,R,C=F.length,U=0;for(M=0;M<C;M++)(64512&(P=F.charCodeAt(M)))==55296&&M+1<C&&(64512&(w=F.charCodeAt(M+1)))==56320&&(P=65536+(P-55296<<10)+(w-56320),M++),U+=P<128?1:P<2048?2:P<65536?3:4;for(E=m.uint8array?new Uint8Array(U):new Array(U),M=R=0;R<U;M++)(64512&(P=F.charCodeAt(M)))==55296&&M+1<C&&(64512&(w=F.charCodeAt(M+1)))==56320&&(P=65536+(P-55296<<10)+(w-56320),M++),P<128?E[R++]=P:(P<2048?E[R++]=192|P>>>6:(P<65536?E[R++]=224|P>>>12:(E[R++]=240|P>>>18,E[R++]=128|P>>>12&63),E[R++]=128|P>>>6&63),E[R++]=128|63&P);return E}(I)},f.utf8decode=function(I){return m.nodebuffer?u.transformTo("nodebuffer",I).toString("utf-8"):function(F){var E,P,w,M,R=F.length,C=new Array(2*R);for(E=P=0;E<R;)if((w=F[E++])<128)C[P++]=w;else if(4<(M=S[w]))C[P++]=65533,E+=M-1;else{for(w&=M===2?31:M===3?15:7;1<M&&E<R;)w=w<<6|63&F[E++],M--;1<M?C[P++]=65533:w<65536?C[P++]=w:(w-=65536,C[P++]=55296|w>>10&1023,C[P++]=56320|1023&w)}return C.length!==P&&(C.subarray?C=C.subarray(0,P):C.length=P),u.applyFromCharCode(C)}(I=u.transformTo(m.uint8array?"uint8array":"array",I))},u.inherits(O,v),O.prototype.processChunk=function(I){var F=u.transformTo(m.uint8array?"uint8array":"array",I.data);if(this.leftOver&&this.leftOver.length){if(m.uint8array){var E=F;(F=new Uint8Array(E.length+this.leftOver.length)).set(this.leftOver,0),F.set(E,this.leftOver.length)}else F=this.leftOver.concat(F);this.leftOver=null}var P=function(M,R){var C;for((R=R||M.length)>M.length&&(R=M.length),C=R-1;0<=C&&(192&M[C])==128;)C--;return C<0||C===0?R:C+S[M[C]]>R?C:R}(F),w=F;P!==F.length&&(m.uint8array?(w=F.subarray(0,P),this.leftOver=F.subarray(P,F.length)):(w=F.slice(0,P),this.leftOver=F.slice(P,F.length))),this.push({data:f.utf8decode(w),meta:I.meta})},O.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:f.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},f.Utf8DecodeWorker=O,u.inherits(k,v),k.prototype.processChunk=function(I){this.push({data:f.utf8encode(I.data),meta:I.meta})},f.Utf8EncodeWorker=k},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(o,c,f){var u=o("./support"),m=o("./base64"),g=o("./nodejsUtils"),v=o("./external");function S(E){return E}function b(E,P){for(var w=0;w<E.length;++w)P[w]=255&E.charCodeAt(w);return P}o("setimmediate"),f.newBlob=function(E,P){f.checkSupport("blob");try{return new Blob([E],{type:P})}catch{try{var w=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return w.append(E),w.getBlob(P)}catch{throw new Error("Bug : can't construct the Blob.")}}};var O={stringifyByChunk:function(E,P,w){var M=[],R=0,C=E.length;if(C<=w)return String.fromCharCode.apply(null,E);for(;R<C;)P==="array"||P==="nodebuffer"?M.push(String.fromCharCode.apply(null,E.slice(R,Math.min(R+w,C)))):M.push(String.fromCharCode.apply(null,E.subarray(R,Math.min(R+w,C)))),R+=w;return M.join("")},stringifyByChar:function(E){for(var P="",w=0;w<E.length;w++)P+=String.fromCharCode(E[w]);return P},applyCanBeUsed:{uint8array:function(){try{return u.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}}(),nodebuffer:function(){try{return u.nodebuffer&&String.fromCharCode.apply(null,g.allocBuffer(1)).length===1}catch{return!1}}()}};function k(E){var P=65536,w=f.getTypeOf(E),M=!0;if(w==="uint8array"?M=O.applyCanBeUsed.uint8array:w==="nodebuffer"&&(M=O.applyCanBeUsed.nodebuffer),M)for(;1<P;)try{return O.stringifyByChunk(E,w,P)}catch{P=Math.floor(P/2)}return O.stringifyByChar(E)}function I(E,P){for(var w=0;w<E.length;w++)P[w]=E[w];return P}f.applyFromCharCode=k;var F={};F.string={string:S,array:function(E){return b(E,new Array(E.length))},arraybuffer:function(E){return F.string.uint8array(E).buffer},uint8array:function(E){return b(E,new Uint8Array(E.length))},nodebuffer:function(E){return b(E,g.allocBuffer(E.length))}},F.array={string:k,array:S,arraybuffer:function(E){return new Uint8Array(E).buffer},uint8array:function(E){return new Uint8Array(E)},nodebuffer:function(E){return g.newBufferFrom(E)}},F.arraybuffer={string:function(E){return k(new Uint8Array(E))},array:function(E){return I(new Uint8Array(E),new Array(E.byteLength))},arraybuffer:S,uint8array:function(E){return new Uint8Array(E)},nodebuffer:function(E){return g.newBufferFrom(new Uint8Array(E))}},F.uint8array={string:k,array:function(E){return I(E,new Array(E.length))},arraybuffer:function(E){return E.buffer},uint8array:S,nodebuffer:function(E){return g.newBufferFrom(E)}},F.nodebuffer={string:k,array:function(E){return I(E,new Array(E.length))},arraybuffer:function(E){return F.nodebuffer.uint8array(E).buffer},uint8array:function(E){return I(E,new Uint8Array(E.length))},nodebuffer:S},f.transformTo=function(E,P){if(P=P||"",!E)return P;f.checkSupport(E);var w=f.getTypeOf(P);return F[w][E](P)},f.resolve=function(E){for(var P=E.split("/"),w=[],M=0;M<P.length;M++){var R=P[M];R==="."||R===""&&M!==0&&M!==P.length-1||(R===".."?w.pop():w.push(R))}return w.join("/")},f.getTypeOf=function(E){return typeof E=="string"?"string":Object.prototype.toString.call(E)==="[object Array]"?"array":u.nodebuffer&&g.isBuffer(E)?"nodebuffer":u.uint8array&&E instanceof Uint8Array?"uint8array":u.arraybuffer&&E instanceof ArrayBuffer?"arraybuffer":void 0},f.checkSupport=function(E){if(!u[E.toLowerCase()])throw new Error(E+" is not supported by this platform")},f.MAX_VALUE_16BITS=65535,f.MAX_VALUE_32BITS=-1,f.pretty=function(E){var P,w,M="";for(w=0;w<(E||"").length;w++)M+="\\x"+((P=E.charCodeAt(w))<16?"0":"")+P.toString(16).toUpperCase();return M},f.delay=function(E,P,w){setImmediate(function(){E.apply(w||null,P||[])})},f.inherits=function(E,P){function w(){}w.prototype=P.prototype,E.prototype=new w},f.extend=function(){var E,P,w={};for(E=0;E<arguments.length;E++)for(P in arguments[E])Object.prototype.hasOwnProperty.call(arguments[E],P)&&w[P]===void 0&&(w[P]=arguments[E][P]);return w},f.prepareContent=function(E,P,w,M,R){return v.Promise.resolve(P).then(function(C){return u.blob&&(C instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(C))!==-1)&&typeof FileReader<"u"?new v.Promise(function(U,N){var X=new FileReader;X.onload=function(J){U(J.target.result)},X.onerror=function(J){N(J.target.error)},X.readAsArrayBuffer(C)}):C}).then(function(C){var U=f.getTypeOf(C);return U?(U==="arraybuffer"?C=f.transformTo("uint8array",C):U==="string"&&(R?C=m.decode(C):w&&M!==!0&&(C=function(N){return b(N,u.uint8array?new Uint8Array(N.length):new Array(N.length))}(C))),C):v.Promise.reject(new Error("Can't read the data of '"+E+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(o,c,f){var u=o("./reader/readerFor"),m=o("./utils"),g=o("./signature"),v=o("./zipEntry"),S=o("./support");function b(O){this.files=[],this.loadOptions=O}b.prototype={checkSignature:function(O){if(!this.reader.readAndCheckSignature(O)){this.reader.index-=4;var k=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+m.pretty(k)+", expected "+m.pretty(O)+")")}},isSignature:function(O,k){var I=this.reader.index;this.reader.setIndex(O);var F=this.reader.readString(4)===k;return this.reader.setIndex(I),F},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var O=this.reader.readData(this.zipCommentLength),k=S.uint8array?"uint8array":"array",I=m.transformTo(k,O);this.zipComment=this.loadOptions.decodeFileName(I)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var O,k,I,F=this.zip64EndOfCentralSize-44;0<F;)O=this.reader.readInt(2),k=this.reader.readInt(4),I=this.reader.readData(k),this.zip64ExtensibleData[O]={id:O,length:k,value:I}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var O,k;for(O=0;O<this.files.length;O++)k=this.files[O],this.reader.setIndex(k.localHeaderOffset),this.checkSignature(g.LOCAL_FILE_HEADER),k.readLocalPart(this.reader),k.handleUTF8(),k.processAttributes()},readCentralDir:function(){var O;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(g.CENTRAL_FILE_HEADER);)(O=new v({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(O);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var O=this.reader.lastIndexOfSignature(g.CENTRAL_DIRECTORY_END);if(O<0)throw this.isSignature(0,g.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(O);var k=O;if(this.checkSignature(g.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===m.MAX_VALUE_16BITS||this.diskWithCentralDirStart===m.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===m.MAX_VALUE_16BITS||this.centralDirRecords===m.MAX_VALUE_16BITS||this.centralDirSize===m.MAX_VALUE_32BITS||this.centralDirOffset===m.MAX_VALUE_32BITS){if(this.zip64=!0,(O=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(O),this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,g.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var I=this.centralDirOffset+this.centralDirSize;this.zip64&&(I+=20,I+=12+this.zip64EndOfCentralSize);var F=k-I;if(0<F)this.isSignature(k,g.CENTRAL_FILE_HEADER)||(this.reader.zero=F);else if(F<0)throw new Error("Corrupted zip: missing "+Math.abs(F)+" bytes.")},prepareReader:function(O){this.reader=u(O)},load:function(O){this.prepareReader(O),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},c.exports=b},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(o,c,f){var u=o("./reader/readerFor"),m=o("./utils"),g=o("./compressedObject"),v=o("./crc32"),S=o("./utf8"),b=o("./compressions"),O=o("./support");function k(I,F){this.options=I,this.loadOptions=F}k.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(I){var F,E;if(I.skip(22),this.fileNameLength=I.readInt(2),E=I.readInt(2),this.fileName=I.readData(this.fileNameLength),I.skip(E),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if((F=function(P){for(var w in b)if(Object.prototype.hasOwnProperty.call(b,w)&&b[w].magic===P)return b[w];return null}(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+m.pretty(this.compressionMethod)+" unknown (inner file : "+m.transformTo("string",this.fileName)+")");this.decompressed=new g(this.compressedSize,this.uncompressedSize,this.crc32,F,I.readData(this.compressedSize))},readCentralPart:function(I){this.versionMadeBy=I.readInt(2),I.skip(2),this.bitFlag=I.readInt(2),this.compressionMethod=I.readString(2),this.date=I.readDate(),this.crc32=I.readInt(4),this.compressedSize=I.readInt(4),this.uncompressedSize=I.readInt(4);var F=I.readInt(2);if(this.extraFieldsLength=I.readInt(2),this.fileCommentLength=I.readInt(2),this.diskNumberStart=I.readInt(2),this.internalFileAttributes=I.readInt(2),this.externalFileAttributes=I.readInt(4),this.localHeaderOffset=I.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");I.skip(F),this.readExtraFields(I),this.parseZIP64ExtraField(I),this.fileComment=I.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var I=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),I==0&&(this.dosPermissions=63&this.externalFileAttributes),I==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var I=u(this.extraFields[1].value);this.uncompressedSize===m.MAX_VALUE_32BITS&&(this.uncompressedSize=I.readInt(8)),this.compressedSize===m.MAX_VALUE_32BITS&&(this.compressedSize=I.readInt(8)),this.localHeaderOffset===m.MAX_VALUE_32BITS&&(this.localHeaderOffset=I.readInt(8)),this.diskNumberStart===m.MAX_VALUE_32BITS&&(this.diskNumberStart=I.readInt(4))}},readExtraFields:function(I){var F,E,P,w=I.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});I.index+4<w;)F=I.readInt(2),E=I.readInt(2),P=I.readData(E),this.extraFields[F]={id:F,length:E,value:P};I.setIndex(w)},handleUTF8:function(){var I=O.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=S.utf8decode(this.fileName),this.fileCommentStr=S.utf8decode(this.fileComment);else{var F=this.findExtraFieldUnicodePath();if(F!==null)this.fileNameStr=F;else{var E=m.transformTo(I,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(E)}var P=this.findExtraFieldUnicodeComment();if(P!==null)this.fileCommentStr=P;else{var w=m.transformTo(I,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(w)}}},findExtraFieldUnicodePath:function(){var I=this.extraFields[28789];if(I){var F=u(I.value);return F.readInt(1)!==1||v(this.fileName)!==F.readInt(4)?null:S.utf8decode(F.readData(I.length-5))}return null},findExtraFieldUnicodeComment:function(){var I=this.extraFields[25461];if(I){var F=u(I.value);return F.readInt(1)!==1||v(this.fileComment)!==F.readInt(4)?null:S.utf8decode(F.readData(I.length-5))}return null}},c.exports=k},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(o,c,f){function u(F,E,P){this.name=F,this.dir=P.dir,this.date=P.date,this.comment=P.comment,this.unixPermissions=P.unixPermissions,this.dosPermissions=P.dosPermissions,this._data=E,this._dataBinary=P.binary,this.options={compression:P.compression,compressionOptions:P.compressionOptions}}var m=o("./stream/StreamHelper"),g=o("./stream/DataWorker"),v=o("./utf8"),S=o("./compressedObject"),b=o("./stream/GenericWorker");u.prototype={internalStream:function(F){var E=null,P="string";try{if(!F)throw new Error("No output type specified.");var w=(P=F.toLowerCase())==="string"||P==="text";P!=="binarystring"&&P!=="text"||(P="string"),E=this._decompressWorker();var M=!this._dataBinary;M&&!w&&(E=E.pipe(new v.Utf8EncodeWorker)),!M&&w&&(E=E.pipe(new v.Utf8DecodeWorker))}catch(R){(E=new b("error")).error(R)}return new m(E,P,"")},async:function(F,E){return this.internalStream(F).accumulate(E)},nodeStream:function(F,E){return this.internalStream(F||"nodebuffer").toNodejsStream(E)},_compressWorker:function(F,E){if(this._data instanceof S&&this._data.compression.magic===F.magic)return this._data.getCompressedWorker();var P=this._decompressWorker();return this._dataBinary||(P=P.pipe(new v.Utf8EncodeWorker)),S.createWorkerFrom(P,F,E)},_decompressWorker:function(){return this._data instanceof S?this._data.getContentWorker():this._data instanceof b?this._data:new g(this._data)}};for(var O=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],k=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},I=0;I<O.length;I++)u.prototype[O[I]]=k;c.exports=u},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(o,c,f){(function(u){var m,g,v=u.MutationObserver||u.WebKitMutationObserver;if(v){var S=0,b=new v(F),O=u.document.createTextNode("");b.observe(O,{characterData:!0}),m=function(){O.data=S=++S%2}}else if(u.setImmediate||u.MessageChannel===void 0)m="document"in u&&"onreadystatechange"in u.document.createElement("script")?function(){var E=u.document.createElement("script");E.onreadystatechange=function(){F(),E.onreadystatechange=null,E.parentNode.removeChild(E),E=null},u.document.documentElement.appendChild(E)}:function(){setTimeout(F,0)};else{var k=new u.MessageChannel;k.port1.onmessage=F,m=function(){k.port2.postMessage(0)}}var I=[];function F(){var E,P;g=!0;for(var w=I.length;w;){for(P=I,I=[],E=-1;++E<w;)P[E]();w=I.length}g=!1}c.exports=function(E){I.push(E)!==1||g||m()}}).call(this,typeof Er<"u"?Er:typeof self<"u"?self:typeof window<"u"?window:{})},{}],37:[function(o,c,f){var u=o("immediate");function m(){}var g={},v=["REJECTED"],S=["FULFILLED"],b=["PENDING"];function O(w){if(typeof w!="function")throw new TypeError("resolver must be a function");this.state=b,this.queue=[],this.outcome=void 0,w!==m&&E(this,w)}function k(w,M,R){this.promise=w,typeof M=="function"&&(this.onFulfilled=M,this.callFulfilled=this.otherCallFulfilled),typeof R=="function"&&(this.onRejected=R,this.callRejected=this.otherCallRejected)}function I(w,M,R){u(function(){var C;try{C=M(R)}catch(U){return g.reject(w,U)}C===w?g.reject(w,new TypeError("Cannot resolve promise with itself")):g.resolve(w,C)})}function F(w){var M=w&&w.then;if(w&&(typeof w=="object"||typeof w=="function")&&typeof M=="function")return function(){M.apply(w,arguments)}}function E(w,M){var R=!1;function C(X){R||(R=!0,g.reject(w,X))}function U(X){R||(R=!0,g.resolve(w,X))}var N=P(function(){M(U,C)});N.status==="error"&&C(N.value)}function P(w,M){var R={};try{R.value=w(M),R.status="success"}catch(C){R.status="error",R.value=C}return R}(c.exports=O).prototype.finally=function(w){if(typeof w!="function")return this;var M=this.constructor;return this.then(function(R){return M.resolve(w()).then(function(){return R})},function(R){return M.resolve(w()).then(function(){throw R})})},O.prototype.catch=function(w){return this.then(null,w)},O.prototype.then=function(w,M){if(typeof w!="function"&&this.state===S||typeof M!="function"&&this.state===v)return this;var R=new this.constructor(m);return this.state!==b?I(R,this.state===S?w:M,this.outcome):this.queue.push(new k(R,w,M)),R},k.prototype.callFulfilled=function(w){g.resolve(this.promise,w)},k.prototype.otherCallFulfilled=function(w){I(this.promise,this.onFulfilled,w)},k.prototype.callRejected=function(w){g.reject(this.promise,w)},k.prototype.otherCallRejected=function(w){I(this.promise,this.onRejected,w)},g.resolve=function(w,M){var R=P(F,M);if(R.status==="error")return g.reject(w,R.value);var C=R.value;if(C)E(w,C);else{w.state=S,w.outcome=M;for(var U=-1,N=w.queue.length;++U<N;)w.queue[U].callFulfilled(M)}return w},g.reject=function(w,M){w.state=v,w.outcome=M;for(var R=-1,C=w.queue.length;++R<C;)w.queue[R].callRejected(M);return w},O.resolve=function(w){return w instanceof this?w:g.resolve(new this(m),w)},O.reject=function(w){var M=new this(m);return g.reject(M,w)},O.all=function(w){var M=this;if(Object.prototype.toString.call(w)!=="[object Array]")return this.reject(new TypeError("must be an array"));var R=w.length,C=!1;if(!R)return this.resolve([]);for(var U=new Array(R),N=0,X=-1,J=new this(m);++X<R;)Z(w[X],X);return J;function Z(ct,Rt){M.resolve(ct).then(function(tt){U[Rt]=tt,++N!==R||C||(C=!0,g.resolve(J,U))},function(tt){C||(C=!0,g.reject(J,tt))})}},O.race=function(w){var M=this;if(Object.prototype.toString.call(w)!=="[object Array]")return this.reject(new TypeError("must be an array"));var R=w.length,C=!1;if(!R)return this.resolve([]);for(var U=-1,N=new this(m);++U<R;)X=w[U],M.resolve(X).then(function(J){C||(C=!0,g.resolve(N,J))},function(J){C||(C=!0,g.reject(N,J))});var X;return N}},{immediate:36}],38:[function(o,c,f){var u={};(0,o("./lib/utils/common").assign)(u,o("./lib/deflate"),o("./lib/inflate"),o("./lib/zlib/constants")),c.exports=u},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(o,c,f){var u=o("./zlib/deflate"),m=o("./utils/common"),g=o("./utils/strings"),v=o("./zlib/messages"),S=o("./zlib/zstream"),b=Object.prototype.toString,O=0,k=-1,I=0,F=8;function E(w){if(!(this instanceof E))return new E(w);this.options=m.assign({level:k,method:F,chunkSize:16384,windowBits:15,memLevel:8,strategy:I,to:""},w||{});var M=this.options;M.raw&&0<M.windowBits?M.windowBits=-M.windowBits:M.gzip&&0<M.windowBits&&M.windowBits<16&&(M.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new S,this.strm.avail_out=0;var R=u.deflateInit2(this.strm,M.level,M.method,M.windowBits,M.memLevel,M.strategy);if(R!==O)throw new Error(v[R]);if(M.header&&u.deflateSetHeader(this.strm,M.header),M.dictionary){var C;if(C=typeof M.dictionary=="string"?g.string2buf(M.dictionary):b.call(M.dictionary)==="[object ArrayBuffer]"?new Uint8Array(M.dictionary):M.dictionary,(R=u.deflateSetDictionary(this.strm,C))!==O)throw new Error(v[R]);this._dict_set=!0}}function P(w,M){var R=new E(M);if(R.push(w,!0),R.err)throw R.msg||v[R.err];return R.result}E.prototype.push=function(w,M){var R,C,U=this.strm,N=this.options.chunkSize;if(this.ended)return!1;C=M===~~M?M:M===!0?4:0,typeof w=="string"?U.input=g.string2buf(w):b.call(w)==="[object ArrayBuffer]"?U.input=new Uint8Array(w):U.input=w,U.next_in=0,U.avail_in=U.input.length;do{if(U.avail_out===0&&(U.output=new m.Buf8(N),U.next_out=0,U.avail_out=N),(R=u.deflate(U,C))!==1&&R!==O)return this.onEnd(R),!(this.ended=!0);U.avail_out!==0&&(U.avail_in!==0||C!==4&&C!==2)||(this.options.to==="string"?this.onData(g.buf2binstring(m.shrinkBuf(U.output,U.next_out))):this.onData(m.shrinkBuf(U.output,U.next_out)))}while((0<U.avail_in||U.avail_out===0)&&R!==1);return C===4?(R=u.deflateEnd(this.strm),this.onEnd(R),this.ended=!0,R===O):C!==2||(this.onEnd(O),!(U.avail_out=0))},E.prototype.onData=function(w){this.chunks.push(w)},E.prototype.onEnd=function(w){w===O&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=m.flattenChunks(this.chunks)),this.chunks=[],this.err=w,this.msg=this.strm.msg},f.Deflate=E,f.deflate=P,f.deflateRaw=function(w,M){return(M=M||{}).raw=!0,P(w,M)},f.gzip=function(w,M){return(M=M||{}).gzip=!0,P(w,M)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(o,c,f){var u=o("./zlib/inflate"),m=o("./utils/common"),g=o("./utils/strings"),v=o("./zlib/constants"),S=o("./zlib/messages"),b=o("./zlib/zstream"),O=o("./zlib/gzheader"),k=Object.prototype.toString;function I(E){if(!(this instanceof I))return new I(E);this.options=m.assign({chunkSize:16384,windowBits:0,to:""},E||{});var P=this.options;P.raw&&0<=P.windowBits&&P.windowBits<16&&(P.windowBits=-P.windowBits,P.windowBits===0&&(P.windowBits=-15)),!(0<=P.windowBits&&P.windowBits<16)||E&&E.windowBits||(P.windowBits+=32),15<P.windowBits&&P.windowBits<48&&!(15&P.windowBits)&&(P.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new b,this.strm.avail_out=0;var w=u.inflateInit2(this.strm,P.windowBits);if(w!==v.Z_OK)throw new Error(S[w]);this.header=new O,u.inflateGetHeader(this.strm,this.header)}function F(E,P){var w=new I(P);if(w.push(E,!0),w.err)throw w.msg||S[w.err];return w.result}I.prototype.push=function(E,P){var w,M,R,C,U,N,X=this.strm,J=this.options.chunkSize,Z=this.options.dictionary,ct=!1;if(this.ended)return!1;M=P===~~P?P:P===!0?v.Z_FINISH:v.Z_NO_FLUSH,typeof E=="string"?X.input=g.binstring2buf(E):k.call(E)==="[object ArrayBuffer]"?X.input=new Uint8Array(E):X.input=E,X.next_in=0,X.avail_in=X.input.length;do{if(X.avail_out===0&&(X.output=new m.Buf8(J),X.next_out=0,X.avail_out=J),(w=u.inflate(X,v.Z_NO_FLUSH))===v.Z_NEED_DICT&&Z&&(N=typeof Z=="string"?g.string2buf(Z):k.call(Z)==="[object ArrayBuffer]"?new Uint8Array(Z):Z,w=u.inflateSetDictionary(this.strm,N)),w===v.Z_BUF_ERROR&&ct===!0&&(w=v.Z_OK,ct=!1),w!==v.Z_STREAM_END&&w!==v.Z_OK)return this.onEnd(w),!(this.ended=!0);X.next_out&&(X.avail_out!==0&&w!==v.Z_STREAM_END&&(X.avail_in!==0||M!==v.Z_FINISH&&M!==v.Z_SYNC_FLUSH)||(this.options.to==="string"?(R=g.utf8border(X.output,X.next_out),C=X.next_out-R,U=g.buf2string(X.output,R),X.next_out=C,X.avail_out=J-C,C&&m.arraySet(X.output,X.output,R,C,0),this.onData(U)):this.onData(m.shrinkBuf(X.output,X.next_out)))),X.avail_in===0&&X.avail_out===0&&(ct=!0)}while((0<X.avail_in||X.avail_out===0)&&w!==v.Z_STREAM_END);return w===v.Z_STREAM_END&&(M=v.Z_FINISH),M===v.Z_FINISH?(w=u.inflateEnd(this.strm),this.onEnd(w),this.ended=!0,w===v.Z_OK):M!==v.Z_SYNC_FLUSH||(this.onEnd(v.Z_OK),!(X.avail_out=0))},I.prototype.onData=function(E){this.chunks.push(E)},I.prototype.onEnd=function(E){E===v.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=m.flattenChunks(this.chunks)),this.chunks=[],this.err=E,this.msg=this.strm.msg},f.Inflate=I,f.inflate=F,f.inflateRaw=function(E,P){return(P=P||{}).raw=!0,F(E,P)},f.ungzip=F},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(o,c,f){var u=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";f.assign=function(v){for(var S=Array.prototype.slice.call(arguments,1);S.length;){var b=S.shift();if(b){if(typeof b!="object")throw new TypeError(b+"must be non-object");for(var O in b)b.hasOwnProperty(O)&&(v[O]=b[O])}}return v},f.shrinkBuf=function(v,S){return v.length===S?v:v.subarray?v.subarray(0,S):(v.length=S,v)};var m={arraySet:function(v,S,b,O,k){if(S.subarray&&v.subarray)v.set(S.subarray(b,b+O),k);else for(var I=0;I<O;I++)v[k+I]=S[b+I]},flattenChunks:function(v){var S,b,O,k,I,F;for(S=O=0,b=v.length;S<b;S++)O+=v[S].length;for(F=new Uint8Array(O),S=k=0,b=v.length;S<b;S++)I=v[S],F.set(I,k),k+=I.length;return F}},g={arraySet:function(v,S,b,O,k){for(var I=0;I<O;I++)v[k+I]=S[b+I]},flattenChunks:function(v){return[].concat.apply([],v)}};f.setTyped=function(v){v?(f.Buf8=Uint8Array,f.Buf16=Uint16Array,f.Buf32=Int32Array,f.assign(f,m)):(f.Buf8=Array,f.Buf16=Array,f.Buf32=Array,f.assign(f,g))},f.setTyped(u)},{}],42:[function(o,c,f){var u=o("./common"),m=!0,g=!0;try{String.fromCharCode.apply(null,[0])}catch{m=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{g=!1}for(var v=new u.Buf8(256),S=0;S<256;S++)v[S]=252<=S?6:248<=S?5:240<=S?4:224<=S?3:192<=S?2:1;function b(O,k){if(k<65537&&(O.subarray&&g||!O.subarray&&m))return String.fromCharCode.apply(null,u.shrinkBuf(O,k));for(var I="",F=0;F<k;F++)I+=String.fromCharCode(O[F]);return I}v[254]=v[254]=1,f.string2buf=function(O){var k,I,F,E,P,w=O.length,M=0;for(E=0;E<w;E++)(64512&(I=O.charCodeAt(E)))==55296&&E+1<w&&(64512&(F=O.charCodeAt(E+1)))==56320&&(I=65536+(I-55296<<10)+(F-56320),E++),M+=I<128?1:I<2048?2:I<65536?3:4;for(k=new u.Buf8(M),E=P=0;P<M;E++)(64512&(I=O.charCodeAt(E)))==55296&&E+1<w&&(64512&(F=O.charCodeAt(E+1)))==56320&&(I=65536+(I-55296<<10)+(F-56320),E++),I<128?k[P++]=I:(I<2048?k[P++]=192|I>>>6:(I<65536?k[P++]=224|I>>>12:(k[P++]=240|I>>>18,k[P++]=128|I>>>12&63),k[P++]=128|I>>>6&63),k[P++]=128|63&I);return k},f.buf2binstring=function(O){return b(O,O.length)},f.binstring2buf=function(O){for(var k=new u.Buf8(O.length),I=0,F=k.length;I<F;I++)k[I]=O.charCodeAt(I);return k},f.buf2string=function(O,k){var I,F,E,P,w=k||O.length,M=new Array(2*w);for(I=F=0;I<w;)if((E=O[I++])<128)M[F++]=E;else if(4<(P=v[E]))M[F++]=65533,I+=P-1;else{for(E&=P===2?31:P===3?15:7;1<P&&I<w;)E=E<<6|63&O[I++],P--;1<P?M[F++]=65533:E<65536?M[F++]=E:(E-=65536,M[F++]=55296|E>>10&1023,M[F++]=56320|1023&E)}return b(M,F)},f.utf8border=function(O,k){var I;for((k=k||O.length)>O.length&&(k=O.length),I=k-1;0<=I&&(192&O[I])==128;)I--;return I<0||I===0?k:I+v[O[I]]>k?I:k}},{"./common":41}],43:[function(o,c,f){c.exports=function(u,m,g,v){for(var S=65535&u|0,b=u>>>16&65535|0,O=0;g!==0;){for(g-=O=2e3<g?2e3:g;b=b+(S=S+m[v++]|0)|0,--O;);S%=65521,b%=65521}return S|b<<16|0}},{}],44:[function(o,c,f){c.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(o,c,f){var u=function(){for(var m,g=[],v=0;v<256;v++){m=v;for(var S=0;S<8;S++)m=1&m?3988292384^m>>>1:m>>>1;g[v]=m}return g}();c.exports=function(m,g,v,S){var b=u,O=S+v;m^=-1;for(var k=S;k<O;k++)m=m>>>8^b[255&(m^g[k])];return-1^m}},{}],46:[function(o,c,f){var u,m=o("../utils/common"),g=o("./trees"),v=o("./adler32"),S=o("./crc32"),b=o("./messages"),O=0,k=4,I=0,F=-2,E=-1,P=4,w=2,M=8,R=9,C=286,U=30,N=19,X=2*C+1,J=15,Z=3,ct=258,Rt=ct+Z+1,tt=42,_t=113,G=1,Pt=2,Et=3,At=4;function ce(W,Jt){return W.msg=b[Jt],Jt}function re(W){return(W<<1)-(4<W?9:0)}function Ft(W){for(var Jt=W.length;0<=--Jt;)W[Jt]=0}function It(W){var Jt=W.state,jt=Jt.pending;jt>W.avail_out&&(jt=W.avail_out),jt!==0&&(m.arraySet(W.output,Jt.pending_buf,Jt.pending_out,jt,W.next_out),W.next_out+=jt,Jt.pending_out+=jt,W.total_out+=jt,W.avail_out-=jt,Jt.pending-=jt,Jt.pending===0&&(Jt.pending_out=0))}function Nt(W,Jt){g._tr_flush_block(W,0<=W.block_start?W.block_start:-1,W.strstart-W.block_start,Jt),W.block_start=W.strstart,It(W.strm)}function Pe(W,Jt){W.pending_buf[W.pending++]=Jt}function pe(W,Jt){W.pending_buf[W.pending++]=Jt>>>8&255,W.pending_buf[W.pending++]=255&Jt}function Wt(W,Jt){var jt,dt,pt=W.max_chain_length,Dt=W.strstart,ie=W.prev_length,Kt=W.nice_match,z=W.strstart>W.w_size-Rt?W.strstart-(W.w_size-Rt):0,Q=W.window,st=W.w_mask,nt=W.prev,vt=W.strstart+ct,Ut=Q[Dt+ie-1],qt=Q[Dt+ie];W.prev_length>=W.good_match&&(pt>>=2),Kt>W.lookahead&&(Kt=W.lookahead);do if(Q[(jt=Jt)+ie]===qt&&Q[jt+ie-1]===Ut&&Q[jt]===Q[Dt]&&Q[++jt]===Q[Dt+1]){Dt+=2,jt++;do;while(Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Q[++Dt]===Q[++jt]&&Dt<vt);if(dt=ct-(vt-Dt),Dt=vt-ct,ie<dt){if(W.match_start=Jt,Kt<=(ie=dt))break;Ut=Q[Dt+ie-1],qt=Q[Dt+ie]}}while((Jt=nt[Jt&st])>z&&--pt!=0);return ie<=W.lookahead?ie:W.lookahead}function $e(W){var Jt,jt,dt,pt,Dt,ie,Kt,z,Q,st,nt=W.w_size;do{if(pt=W.window_size-W.lookahead-W.strstart,W.strstart>=nt+(nt-Rt)){for(m.arraySet(W.window,W.window,nt,nt,0),W.match_start-=nt,W.strstart-=nt,W.block_start-=nt,Jt=jt=W.hash_size;dt=W.head[--Jt],W.head[Jt]=nt<=dt?dt-nt:0,--jt;);for(Jt=jt=nt;dt=W.prev[--Jt],W.prev[Jt]=nt<=dt?dt-nt:0,--jt;);pt+=nt}if(W.strm.avail_in===0)break;if(ie=W.strm,Kt=W.window,z=W.strstart+W.lookahead,Q=pt,st=void 0,st=ie.avail_in,Q<st&&(st=Q),jt=st===0?0:(ie.avail_in-=st,m.arraySet(Kt,ie.input,ie.next_in,st,z),ie.state.wrap===1?ie.adler=v(ie.adler,Kt,st,z):ie.state.wrap===2&&(ie.adler=S(ie.adler,Kt,st,z)),ie.next_in+=st,ie.total_in+=st,st),W.lookahead+=jt,W.lookahead+W.insert>=Z)for(Dt=W.strstart-W.insert,W.ins_h=W.window[Dt],W.ins_h=(W.ins_h<<W.hash_shift^W.window[Dt+1])&W.hash_mask;W.insert&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[Dt+Z-1])&W.hash_mask,W.prev[Dt&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=Dt,Dt++,W.insert--,!(W.lookahead+W.insert<Z)););}while(W.lookahead<Rt&&W.strm.avail_in!==0)}function Si(W,Jt){for(var jt,dt;;){if(W.lookahead<Rt){if($e(W),W.lookahead<Rt&&Jt===O)return G;if(W.lookahead===0)break}if(jt=0,W.lookahead>=Z&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart),jt!==0&&W.strstart-jt<=W.w_size-Rt&&(W.match_length=Wt(W,jt)),W.match_length>=Z)if(dt=g._tr_tally(W,W.strstart-W.match_start,W.match_length-Z),W.lookahead-=W.match_length,W.match_length<=W.max_lazy_match&&W.lookahead>=Z){for(W.match_length--;W.strstart++,W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart,--W.match_length!=0;);W.strstart++}else W.strstart+=W.match_length,W.match_length=0,W.ins_h=W.window[W.strstart],W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+1])&W.hash_mask;else dt=g._tr_tally(W,0,W.window[W.strstart]),W.lookahead--,W.strstart++;if(dt&&(Nt(W,!1),W.strm.avail_out===0))return G}return W.insert=W.strstart<Z-1?W.strstart:Z-1,Jt===k?(Nt(W,!0),W.strm.avail_out===0?Et:At):W.last_lit&&(Nt(W,!1),W.strm.avail_out===0)?G:Pt}function Oe(W,Jt){for(var jt,dt,pt;;){if(W.lookahead<Rt){if($e(W),W.lookahead<Rt&&Jt===O)return G;if(W.lookahead===0)break}if(jt=0,W.lookahead>=Z&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart),W.prev_length=W.match_length,W.prev_match=W.match_start,W.match_length=Z-1,jt!==0&&W.prev_length<W.max_lazy_match&&W.strstart-jt<=W.w_size-Rt&&(W.match_length=Wt(W,jt),W.match_length<=5&&(W.strategy===1||W.match_length===Z&&4096<W.strstart-W.match_start)&&(W.match_length=Z-1)),W.prev_length>=Z&&W.match_length<=W.prev_length){for(pt=W.strstart+W.lookahead-Z,dt=g._tr_tally(W,W.strstart-1-W.prev_match,W.prev_length-Z),W.lookahead-=W.prev_length-1,W.prev_length-=2;++W.strstart<=pt&&(W.ins_h=(W.ins_h<<W.hash_shift^W.window[W.strstart+Z-1])&W.hash_mask,jt=W.prev[W.strstart&W.w_mask]=W.head[W.ins_h],W.head[W.ins_h]=W.strstart),--W.prev_length!=0;);if(W.match_available=0,W.match_length=Z-1,W.strstart++,dt&&(Nt(W,!1),W.strm.avail_out===0))return G}else if(W.match_available){if((dt=g._tr_tally(W,0,W.window[W.strstart-1]))&&Nt(W,!1),W.strstart++,W.lookahead--,W.strm.avail_out===0)return G}else W.match_available=1,W.strstart++,W.lookahead--}return W.match_available&&(dt=g._tr_tally(W,0,W.window[W.strstart-1]),W.match_available=0),W.insert=W.strstart<Z-1?W.strstart:Z-1,Jt===k?(Nt(W,!0),W.strm.avail_out===0?Et:At):W.last_lit&&(Nt(W,!1),W.strm.avail_out===0)?G:Pt}function Ge(W,Jt,jt,dt,pt){this.good_length=W,this.max_lazy=Jt,this.nice_length=jt,this.max_chain=dt,this.func=pt}function pi(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=M,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new m.Buf16(2*X),this.dyn_dtree=new m.Buf16(2*(2*U+1)),this.bl_tree=new m.Buf16(2*(2*N+1)),Ft(this.dyn_ltree),Ft(this.dyn_dtree),Ft(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new m.Buf16(J+1),this.heap=new m.Buf16(2*C+1),Ft(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new m.Buf16(2*C+1),Ft(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function Di(W){var Jt;return W&&W.state?(W.total_in=W.total_out=0,W.data_type=w,(Jt=W.state).pending=0,Jt.pending_out=0,Jt.wrap<0&&(Jt.wrap=-Jt.wrap),Jt.status=Jt.wrap?tt:_t,W.adler=Jt.wrap===2?0:1,Jt.last_flush=O,g._tr_init(Jt),I):ce(W,F)}function mn(W){var Jt=Di(W);return Jt===I&&function(jt){jt.window_size=2*jt.w_size,Ft(jt.head),jt.max_lazy_match=u[jt.level].max_lazy,jt.good_match=u[jt.level].good_length,jt.nice_match=u[jt.level].nice_length,jt.max_chain_length=u[jt.level].max_chain,jt.strstart=0,jt.block_start=0,jt.lookahead=0,jt.insert=0,jt.match_length=jt.prev_length=Z-1,jt.match_available=0,jt.ins_h=0}(W.state),Jt}function Qi(W,Jt,jt,dt,pt,Dt){if(!W)return F;var ie=1;if(Jt===E&&(Jt=6),dt<0?(ie=0,dt=-dt):15<dt&&(ie=2,dt-=16),pt<1||R<pt||jt!==M||dt<8||15<dt||Jt<0||9<Jt||Dt<0||P<Dt)return ce(W,F);dt===8&&(dt=9);var Kt=new pi;return(W.state=Kt).strm=W,Kt.wrap=ie,Kt.gzhead=null,Kt.w_bits=dt,Kt.w_size=1<<Kt.w_bits,Kt.w_mask=Kt.w_size-1,Kt.hash_bits=pt+7,Kt.hash_size=1<<Kt.hash_bits,Kt.hash_mask=Kt.hash_size-1,Kt.hash_shift=~~((Kt.hash_bits+Z-1)/Z),Kt.window=new m.Buf8(2*Kt.w_size),Kt.head=new m.Buf16(Kt.hash_size),Kt.prev=new m.Buf16(Kt.w_size),Kt.lit_bufsize=1<<pt+6,Kt.pending_buf_size=4*Kt.lit_bufsize,Kt.pending_buf=new m.Buf8(Kt.pending_buf_size),Kt.d_buf=1*Kt.lit_bufsize,Kt.l_buf=3*Kt.lit_bufsize,Kt.level=Jt,Kt.strategy=Dt,Kt.method=jt,mn(W)}u=[new Ge(0,0,0,0,function(W,Jt){var jt=65535;for(jt>W.pending_buf_size-5&&(jt=W.pending_buf_size-5);;){if(W.lookahead<=1){if($e(W),W.lookahead===0&&Jt===O)return G;if(W.lookahead===0)break}W.strstart+=W.lookahead,W.lookahead=0;var dt=W.block_start+jt;if((W.strstart===0||W.strstart>=dt)&&(W.lookahead=W.strstart-dt,W.strstart=dt,Nt(W,!1),W.strm.avail_out===0)||W.strstart-W.block_start>=W.w_size-Rt&&(Nt(W,!1),W.strm.avail_out===0))return G}return W.insert=0,Jt===k?(Nt(W,!0),W.strm.avail_out===0?Et:At):(W.strstart>W.block_start&&(Nt(W,!1),W.strm.avail_out),G)}),new Ge(4,4,8,4,Si),new Ge(4,5,16,8,Si),new Ge(4,6,32,32,Si),new Ge(4,4,16,16,Oe),new Ge(8,16,32,32,Oe),new Ge(8,16,128,128,Oe),new Ge(8,32,128,256,Oe),new Ge(32,128,258,1024,Oe),new Ge(32,258,258,4096,Oe)],f.deflateInit=function(W,Jt){return Qi(W,Jt,M,15,8,0)},f.deflateInit2=Qi,f.deflateReset=mn,f.deflateResetKeep=Di,f.deflateSetHeader=function(W,Jt){return W&&W.state?W.state.wrap!==2?F:(W.state.gzhead=Jt,I):F},f.deflate=function(W,Jt){var jt,dt,pt,Dt;if(!W||!W.state||5<Jt||Jt<0)return W?ce(W,F):F;if(dt=W.state,!W.output||!W.input&&W.avail_in!==0||dt.status===666&&Jt!==k)return ce(W,W.avail_out===0?-5:F);if(dt.strm=W,jt=dt.last_flush,dt.last_flush=Jt,dt.status===tt)if(dt.wrap===2)W.adler=0,Pe(dt,31),Pe(dt,139),Pe(dt,8),dt.gzhead?(Pe(dt,(dt.gzhead.text?1:0)+(dt.gzhead.hcrc?2:0)+(dt.gzhead.extra?4:0)+(dt.gzhead.name?8:0)+(dt.gzhead.comment?16:0)),Pe(dt,255&dt.gzhead.time),Pe(dt,dt.gzhead.time>>8&255),Pe(dt,dt.gzhead.time>>16&255),Pe(dt,dt.gzhead.time>>24&255),Pe(dt,dt.level===9?2:2<=dt.strategy||dt.level<2?4:0),Pe(dt,255&dt.gzhead.os),dt.gzhead.extra&&dt.gzhead.extra.length&&(Pe(dt,255&dt.gzhead.extra.length),Pe(dt,dt.gzhead.extra.length>>8&255)),dt.gzhead.hcrc&&(W.adler=S(W.adler,dt.pending_buf,dt.pending,0)),dt.gzindex=0,dt.status=69):(Pe(dt,0),Pe(dt,0),Pe(dt,0),Pe(dt,0),Pe(dt,0),Pe(dt,dt.level===9?2:2<=dt.strategy||dt.level<2?4:0),Pe(dt,3),dt.status=_t);else{var ie=M+(dt.w_bits-8<<4)<<8;ie|=(2<=dt.strategy||dt.level<2?0:dt.level<6?1:dt.level===6?2:3)<<6,dt.strstart!==0&&(ie|=32),ie+=31-ie%31,dt.status=_t,pe(dt,ie),dt.strstart!==0&&(pe(dt,W.adler>>>16),pe(dt,65535&W.adler)),W.adler=1}if(dt.status===69)if(dt.gzhead.extra){for(pt=dt.pending;dt.gzindex<(65535&dt.gzhead.extra.length)&&(dt.pending!==dt.pending_buf_size||(dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),It(W),pt=dt.pending,dt.pending!==dt.pending_buf_size));)Pe(dt,255&dt.gzhead.extra[dt.gzindex]),dt.gzindex++;dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),dt.gzindex===dt.gzhead.extra.length&&(dt.gzindex=0,dt.status=73)}else dt.status=73;if(dt.status===73)if(dt.gzhead.name){pt=dt.pending;do{if(dt.pending===dt.pending_buf_size&&(dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),It(W),pt=dt.pending,dt.pending===dt.pending_buf_size)){Dt=1;break}Dt=dt.gzindex<dt.gzhead.name.length?255&dt.gzhead.name.charCodeAt(dt.gzindex++):0,Pe(dt,Dt)}while(Dt!==0);dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),Dt===0&&(dt.gzindex=0,dt.status=91)}else dt.status=91;if(dt.status===91)if(dt.gzhead.comment){pt=dt.pending;do{if(dt.pending===dt.pending_buf_size&&(dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),It(W),pt=dt.pending,dt.pending===dt.pending_buf_size)){Dt=1;break}Dt=dt.gzindex<dt.gzhead.comment.length?255&dt.gzhead.comment.charCodeAt(dt.gzindex++):0,Pe(dt,Dt)}while(Dt!==0);dt.gzhead.hcrc&&dt.pending>pt&&(W.adler=S(W.adler,dt.pending_buf,dt.pending-pt,pt)),Dt===0&&(dt.status=103)}else dt.status=103;if(dt.status===103&&(dt.gzhead.hcrc?(dt.pending+2>dt.pending_buf_size&&It(W),dt.pending+2<=dt.pending_buf_size&&(Pe(dt,255&W.adler),Pe(dt,W.adler>>8&255),W.adler=0,dt.status=_t)):dt.status=_t),dt.pending!==0){if(It(W),W.avail_out===0)return dt.last_flush=-1,I}else if(W.avail_in===0&&re(Jt)<=re(jt)&&Jt!==k)return ce(W,-5);if(dt.status===666&&W.avail_in!==0)return ce(W,-5);if(W.avail_in!==0||dt.lookahead!==0||Jt!==O&&dt.status!==666){var Kt=dt.strategy===2?function(z,Q){for(var st;;){if(z.lookahead===0&&($e(z),z.lookahead===0)){if(Q===O)return G;break}if(z.match_length=0,st=g._tr_tally(z,0,z.window[z.strstart]),z.lookahead--,z.strstart++,st&&(Nt(z,!1),z.strm.avail_out===0))return G}return z.insert=0,Q===k?(Nt(z,!0),z.strm.avail_out===0?Et:At):z.last_lit&&(Nt(z,!1),z.strm.avail_out===0)?G:Pt}(dt,Jt):dt.strategy===3?function(z,Q){for(var st,nt,vt,Ut,qt=z.window;;){if(z.lookahead<=ct){if($e(z),z.lookahead<=ct&&Q===O)return G;if(z.lookahead===0)break}if(z.match_length=0,z.lookahead>=Z&&0<z.strstart&&(nt=qt[vt=z.strstart-1])===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]){Ut=z.strstart+ct;do;while(nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&nt===qt[++vt]&&vt<Ut);z.match_length=ct-(Ut-vt),z.match_length>z.lookahead&&(z.match_length=z.lookahead)}if(z.match_length>=Z?(st=g._tr_tally(z,1,z.match_length-Z),z.lookahead-=z.match_length,z.strstart+=z.match_length,z.match_length=0):(st=g._tr_tally(z,0,z.window[z.strstart]),z.lookahead--,z.strstart++),st&&(Nt(z,!1),z.strm.avail_out===0))return G}return z.insert=0,Q===k?(Nt(z,!0),z.strm.avail_out===0?Et:At):z.last_lit&&(Nt(z,!1),z.strm.avail_out===0)?G:Pt}(dt,Jt):u[dt.level].func(dt,Jt);if(Kt!==Et&&Kt!==At||(dt.status=666),Kt===G||Kt===Et)return W.avail_out===0&&(dt.last_flush=-1),I;if(Kt===Pt&&(Jt===1?g._tr_align(dt):Jt!==5&&(g._tr_stored_block(dt,0,0,!1),Jt===3&&(Ft(dt.head),dt.lookahead===0&&(dt.strstart=0,dt.block_start=0,dt.insert=0))),It(W),W.avail_out===0))return dt.last_flush=-1,I}return Jt!==k?I:dt.wrap<=0?1:(dt.wrap===2?(Pe(dt,255&W.adler),Pe(dt,W.adler>>8&255),Pe(dt,W.adler>>16&255),Pe(dt,W.adler>>24&255),Pe(dt,255&W.total_in),Pe(dt,W.total_in>>8&255),Pe(dt,W.total_in>>16&255),Pe(dt,W.total_in>>24&255)):(pe(dt,W.adler>>>16),pe(dt,65535&W.adler)),It(W),0<dt.wrap&&(dt.wrap=-dt.wrap),dt.pending!==0?I:1)},f.deflateEnd=function(W){var Jt;return W&&W.state?(Jt=W.state.status)!==tt&&Jt!==69&&Jt!==73&&Jt!==91&&Jt!==103&&Jt!==_t&&Jt!==666?ce(W,F):(W.state=null,Jt===_t?ce(W,-3):I):F},f.deflateSetDictionary=function(W,Jt){var jt,dt,pt,Dt,ie,Kt,z,Q,st=Jt.length;if(!W||!W.state||(Dt=(jt=W.state).wrap)===2||Dt===1&&jt.status!==tt||jt.lookahead)return F;for(Dt===1&&(W.adler=v(W.adler,Jt,st,0)),jt.wrap=0,st>=jt.w_size&&(Dt===0&&(Ft(jt.head),jt.strstart=0,jt.block_start=0,jt.insert=0),Q=new m.Buf8(jt.w_size),m.arraySet(Q,Jt,st-jt.w_size,jt.w_size,0),Jt=Q,st=jt.w_size),ie=W.avail_in,Kt=W.next_in,z=W.input,W.avail_in=st,W.next_in=0,W.input=Jt,$e(jt);jt.lookahead>=Z;){for(dt=jt.strstart,pt=jt.lookahead-(Z-1);jt.ins_h=(jt.ins_h<<jt.hash_shift^jt.window[dt+Z-1])&jt.hash_mask,jt.prev[dt&jt.w_mask]=jt.head[jt.ins_h],jt.head[jt.ins_h]=dt,dt++,--pt;);jt.strstart=dt,jt.lookahead=Z-1,$e(jt)}return jt.strstart+=jt.lookahead,jt.block_start=jt.strstart,jt.insert=jt.lookahead,jt.lookahead=0,jt.match_length=jt.prev_length=Z-1,jt.match_available=0,W.next_in=Kt,W.input=z,W.avail_in=ie,jt.wrap=Dt,I},f.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(o,c,f){c.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(o,c,f){c.exports=function(u,m){var g,v,S,b,O,k,I,F,E,P,w,M,R,C,U,N,X,J,Z,ct,Rt,tt,_t,G,Pt;g=u.state,v=u.next_in,G=u.input,S=v+(u.avail_in-5),b=u.next_out,Pt=u.output,O=b-(m-u.avail_out),k=b+(u.avail_out-257),I=g.dmax,F=g.wsize,E=g.whave,P=g.wnext,w=g.window,M=g.hold,R=g.bits,C=g.lencode,U=g.distcode,N=(1<<g.lenbits)-1,X=(1<<g.distbits)-1;t:do{R<15&&(M+=G[v++]<<R,R+=8,M+=G[v++]<<R,R+=8),J=C[M&N];e:for(;;){if(M>>>=Z=J>>>24,R-=Z,(Z=J>>>16&255)===0)Pt[b++]=65535&J;else{if(!(16&Z)){if(!(64&Z)){J=C[(65535&J)+(M&(1<<Z)-1)];continue e}if(32&Z){g.mode=12;break t}u.msg="invalid literal/length code",g.mode=30;break t}ct=65535&J,(Z&=15)&&(R<Z&&(M+=G[v++]<<R,R+=8),ct+=M&(1<<Z)-1,M>>>=Z,R-=Z),R<15&&(M+=G[v++]<<R,R+=8,M+=G[v++]<<R,R+=8),J=U[M&X];i:for(;;){if(M>>>=Z=J>>>24,R-=Z,!(16&(Z=J>>>16&255))){if(!(64&Z)){J=U[(65535&J)+(M&(1<<Z)-1)];continue i}u.msg="invalid distance code",g.mode=30;break t}if(Rt=65535&J,R<(Z&=15)&&(M+=G[v++]<<R,(R+=8)<Z&&(M+=G[v++]<<R,R+=8)),I<(Rt+=M&(1<<Z)-1)){u.msg="invalid distance too far back",g.mode=30;break t}if(M>>>=Z,R-=Z,(Z=b-O)<Rt){if(E<(Z=Rt-Z)&&g.sane){u.msg="invalid distance too far back",g.mode=30;break t}if(_t=w,(tt=0)===P){if(tt+=F-Z,Z<ct){for(ct-=Z;Pt[b++]=w[tt++],--Z;);tt=b-Rt,_t=Pt}}else if(P<Z){if(tt+=F+P-Z,(Z-=P)<ct){for(ct-=Z;Pt[b++]=w[tt++],--Z;);if(tt=0,P<ct){for(ct-=Z=P;Pt[b++]=w[tt++],--Z;);tt=b-Rt,_t=Pt}}}else if(tt+=P-Z,Z<ct){for(ct-=Z;Pt[b++]=w[tt++],--Z;);tt=b-Rt,_t=Pt}for(;2<ct;)Pt[b++]=_t[tt++],Pt[b++]=_t[tt++],Pt[b++]=_t[tt++],ct-=3;ct&&(Pt[b++]=_t[tt++],1<ct&&(Pt[b++]=_t[tt++]))}else{for(tt=b-Rt;Pt[b++]=Pt[tt++],Pt[b++]=Pt[tt++],Pt[b++]=Pt[tt++],2<(ct-=3););ct&&(Pt[b++]=Pt[tt++],1<ct&&(Pt[b++]=Pt[tt++]))}break}}break}}while(v<S&&b<k);v-=ct=R>>3,M&=(1<<(R-=ct<<3))-1,u.next_in=v,u.next_out=b,u.avail_in=v<S?S-v+5:5-(v-S),u.avail_out=b<k?k-b+257:257-(b-k),g.hold=M,g.bits=R}},{}],49:[function(o,c,f){var u=o("../utils/common"),m=o("./adler32"),g=o("./crc32"),v=o("./inffast"),S=o("./inftrees"),b=1,O=2,k=0,I=-2,F=1,E=852,P=592;function w(tt){return(tt>>>24&255)+(tt>>>8&65280)+((65280&tt)<<8)+((255&tt)<<24)}function M(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new u.Buf16(320),this.work=new u.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function R(tt){var _t;return tt&&tt.state?(_t=tt.state,tt.total_in=tt.total_out=_t.total=0,tt.msg="",_t.wrap&&(tt.adler=1&_t.wrap),_t.mode=F,_t.last=0,_t.havedict=0,_t.dmax=32768,_t.head=null,_t.hold=0,_t.bits=0,_t.lencode=_t.lendyn=new u.Buf32(E),_t.distcode=_t.distdyn=new u.Buf32(P),_t.sane=1,_t.back=-1,k):I}function C(tt){var _t;return tt&&tt.state?((_t=tt.state).wsize=0,_t.whave=0,_t.wnext=0,R(tt)):I}function U(tt,_t){var G,Pt;return tt&&tt.state?(Pt=tt.state,_t<0?(G=0,_t=-_t):(G=1+(_t>>4),_t<48&&(_t&=15)),_t&&(_t<8||15<_t)?I:(Pt.window!==null&&Pt.wbits!==_t&&(Pt.window=null),Pt.wrap=G,Pt.wbits=_t,C(tt))):I}function N(tt,_t){var G,Pt;return tt?(Pt=new M,(tt.state=Pt).window=null,(G=U(tt,_t))!==k&&(tt.state=null),G):I}var X,J,Z=!0;function ct(tt){if(Z){var _t;for(X=new u.Buf32(512),J=new u.Buf32(32),_t=0;_t<144;)tt.lens[_t++]=8;for(;_t<256;)tt.lens[_t++]=9;for(;_t<280;)tt.lens[_t++]=7;for(;_t<288;)tt.lens[_t++]=8;for(S(b,tt.lens,0,288,X,0,tt.work,{bits:9}),_t=0;_t<32;)tt.lens[_t++]=5;S(O,tt.lens,0,32,J,0,tt.work,{bits:5}),Z=!1}tt.lencode=X,tt.lenbits=9,tt.distcode=J,tt.distbits=5}function Rt(tt,_t,G,Pt){var Et,At=tt.state;return At.window===null&&(At.wsize=1<<At.wbits,At.wnext=0,At.whave=0,At.window=new u.Buf8(At.wsize)),Pt>=At.wsize?(u.arraySet(At.window,_t,G-At.wsize,At.wsize,0),At.wnext=0,At.whave=At.wsize):(Pt<(Et=At.wsize-At.wnext)&&(Et=Pt),u.arraySet(At.window,_t,G-Pt,Et,At.wnext),(Pt-=Et)?(u.arraySet(At.window,_t,G-Pt,Pt,0),At.wnext=Pt,At.whave=At.wsize):(At.wnext+=Et,At.wnext===At.wsize&&(At.wnext=0),At.whave<At.wsize&&(At.whave+=Et))),0}f.inflateReset=C,f.inflateReset2=U,f.inflateResetKeep=R,f.inflateInit=function(tt){return N(tt,15)},f.inflateInit2=N,f.inflate=function(tt,_t){var G,Pt,Et,At,ce,re,Ft,It,Nt,Pe,pe,Wt,$e,Si,Oe,Ge,pi,Di,mn,Qi,W,Jt,jt,dt,pt=0,Dt=new u.Buf8(4),ie=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!tt||!tt.state||!tt.output||!tt.input&&tt.avail_in!==0)return I;(G=tt.state).mode===12&&(G.mode=13),ce=tt.next_out,Et=tt.output,Ft=tt.avail_out,At=tt.next_in,Pt=tt.input,re=tt.avail_in,It=G.hold,Nt=G.bits,Pe=re,pe=Ft,Jt=k;t:for(;;)switch(G.mode){case F:if(G.wrap===0){G.mode=13;break}for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(2&G.wrap&&It===35615){Dt[G.check=0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0),Nt=It=0,G.mode=2;break}if(G.flags=0,G.head&&(G.head.done=!1),!(1&G.wrap)||(((255&It)<<8)+(It>>8))%31){tt.msg="incorrect header check",G.mode=30;break}if((15&It)!=8){tt.msg="unknown compression method",G.mode=30;break}if(Nt-=4,W=8+(15&(It>>>=4)),G.wbits===0)G.wbits=W;else if(W>G.wbits){tt.msg="invalid window size",G.mode=30;break}G.dmax=1<<W,tt.adler=G.check=1,G.mode=512&It?10:12,Nt=It=0;break;case 2:for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(G.flags=It,(255&G.flags)!=8){tt.msg="unknown compression method",G.mode=30;break}if(57344&G.flags){tt.msg="unknown header flags set",G.mode=30;break}G.head&&(G.head.text=It>>8&1),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0)),Nt=It=0,G.mode=3;case 3:for(;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.head&&(G.head.time=It),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,Dt[2]=It>>>16&255,Dt[3]=It>>>24&255,G.check=g(G.check,Dt,4,0)),Nt=It=0,G.mode=4;case 4:for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.head&&(G.head.xflags=255&It,G.head.os=It>>8),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0)),Nt=It=0,G.mode=5;case 5:if(1024&G.flags){for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.length=It,G.head&&(G.head.extra_len=It),512&G.flags&&(Dt[0]=255&It,Dt[1]=It>>>8&255,G.check=g(G.check,Dt,2,0)),Nt=It=0}else G.head&&(G.head.extra=null);G.mode=6;case 6:if(1024&G.flags&&(re<(Wt=G.length)&&(Wt=re),Wt&&(G.head&&(W=G.head.extra_len-G.length,G.head.extra||(G.head.extra=new Array(G.head.extra_len)),u.arraySet(G.head.extra,Pt,At,Wt,W)),512&G.flags&&(G.check=g(G.check,Pt,Wt,At)),re-=Wt,At+=Wt,G.length-=Wt),G.length))break t;G.length=0,G.mode=7;case 7:if(2048&G.flags){if(re===0)break t;for(Wt=0;W=Pt[At+Wt++],G.head&&W&&G.length<65536&&(G.head.name+=String.fromCharCode(W)),W&&Wt<re;);if(512&G.flags&&(G.check=g(G.check,Pt,Wt,At)),re-=Wt,At+=Wt,W)break t}else G.head&&(G.head.name=null);G.length=0,G.mode=8;case 8:if(4096&G.flags){if(re===0)break t;for(Wt=0;W=Pt[At+Wt++],G.head&&W&&G.length<65536&&(G.head.comment+=String.fromCharCode(W)),W&&Wt<re;);if(512&G.flags&&(G.check=g(G.check,Pt,Wt,At)),re-=Wt,At+=Wt,W)break t}else G.head&&(G.head.comment=null);G.mode=9;case 9:if(512&G.flags){for(;Nt<16;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(It!==(65535&G.check)){tt.msg="header crc mismatch",G.mode=30;break}Nt=It=0}G.head&&(G.head.hcrc=G.flags>>9&1,G.head.done=!0),tt.adler=G.check=0,G.mode=12;break;case 10:for(;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}tt.adler=G.check=w(It),Nt=It=0,G.mode=11;case 11:if(G.havedict===0)return tt.next_out=ce,tt.avail_out=Ft,tt.next_in=At,tt.avail_in=re,G.hold=It,G.bits=Nt,2;tt.adler=G.check=1,G.mode=12;case 12:if(_t===5||_t===6)break t;case 13:if(G.last){It>>>=7&Nt,Nt-=7&Nt,G.mode=27;break}for(;Nt<3;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}switch(G.last=1&It,Nt-=1,3&(It>>>=1)){case 0:G.mode=14;break;case 1:if(ct(G),G.mode=20,_t!==6)break;It>>>=2,Nt-=2;break t;case 2:G.mode=17;break;case 3:tt.msg="invalid block type",G.mode=30}It>>>=2,Nt-=2;break;case 14:for(It>>>=7&Nt,Nt-=7&Nt;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if((65535&It)!=(It>>>16^65535)){tt.msg="invalid stored block lengths",G.mode=30;break}if(G.length=65535&It,Nt=It=0,G.mode=15,_t===6)break t;case 15:G.mode=16;case 16:if(Wt=G.length){if(re<Wt&&(Wt=re),Ft<Wt&&(Wt=Ft),Wt===0)break t;u.arraySet(Et,Pt,At,Wt,ce),re-=Wt,At+=Wt,Ft-=Wt,ce+=Wt,G.length-=Wt;break}G.mode=12;break;case 17:for(;Nt<14;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(G.nlen=257+(31&It),It>>>=5,Nt-=5,G.ndist=1+(31&It),It>>>=5,Nt-=5,G.ncode=4+(15&It),It>>>=4,Nt-=4,286<G.nlen||30<G.ndist){tt.msg="too many length or distance symbols",G.mode=30;break}G.have=0,G.mode=18;case 18:for(;G.have<G.ncode;){for(;Nt<3;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.lens[ie[G.have++]]=7&It,It>>>=3,Nt-=3}for(;G.have<19;)G.lens[ie[G.have++]]=0;if(G.lencode=G.lendyn,G.lenbits=7,jt={bits:G.lenbits},Jt=S(0,G.lens,0,19,G.lencode,0,G.work,jt),G.lenbits=jt.bits,Jt){tt.msg="invalid code lengths set",G.mode=30;break}G.have=0,G.mode=19;case 19:for(;G.have<G.nlen+G.ndist;){for(;Ge=(pt=G.lencode[It&(1<<G.lenbits)-1])>>>16&255,pi=65535&pt,!((Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(pi<16)It>>>=Oe,Nt-=Oe,G.lens[G.have++]=pi;else{if(pi===16){for(dt=Oe+2;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(It>>>=Oe,Nt-=Oe,G.have===0){tt.msg="invalid bit length repeat",G.mode=30;break}W=G.lens[G.have-1],Wt=3+(3&It),It>>>=2,Nt-=2}else if(pi===17){for(dt=Oe+3;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}Nt-=Oe,W=0,Wt=3+(7&(It>>>=Oe)),It>>>=3,Nt-=3}else{for(dt=Oe+7;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}Nt-=Oe,W=0,Wt=11+(127&(It>>>=Oe)),It>>>=7,Nt-=7}if(G.have+Wt>G.nlen+G.ndist){tt.msg="invalid bit length repeat",G.mode=30;break}for(;Wt--;)G.lens[G.have++]=W}}if(G.mode===30)break;if(G.lens[256]===0){tt.msg="invalid code -- missing end-of-block",G.mode=30;break}if(G.lenbits=9,jt={bits:G.lenbits},Jt=S(b,G.lens,0,G.nlen,G.lencode,0,G.work,jt),G.lenbits=jt.bits,Jt){tt.msg="invalid literal/lengths set",G.mode=30;break}if(G.distbits=6,G.distcode=G.distdyn,jt={bits:G.distbits},Jt=S(O,G.lens,G.nlen,G.ndist,G.distcode,0,G.work,jt),G.distbits=jt.bits,Jt){tt.msg="invalid distances set",G.mode=30;break}if(G.mode=20,_t===6)break t;case 20:G.mode=21;case 21:if(6<=re&&258<=Ft){tt.next_out=ce,tt.avail_out=Ft,tt.next_in=At,tt.avail_in=re,G.hold=It,G.bits=Nt,v(tt,pe),ce=tt.next_out,Et=tt.output,Ft=tt.avail_out,At=tt.next_in,Pt=tt.input,re=tt.avail_in,It=G.hold,Nt=G.bits,G.mode===12&&(G.back=-1);break}for(G.back=0;Ge=(pt=G.lencode[It&(1<<G.lenbits)-1])>>>16&255,pi=65535&pt,!((Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(Ge&&!(240&Ge)){for(Di=Oe,mn=Ge,Qi=pi;Ge=(pt=G.lencode[Qi+((It&(1<<Di+mn)-1)>>Di)])>>>16&255,pi=65535&pt,!(Di+(Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}It>>>=Di,Nt-=Di,G.back+=Di}if(It>>>=Oe,Nt-=Oe,G.back+=Oe,G.length=pi,Ge===0){G.mode=26;break}if(32&Ge){G.back=-1,G.mode=12;break}if(64&Ge){tt.msg="invalid literal/length code",G.mode=30;break}G.extra=15&Ge,G.mode=22;case 22:if(G.extra){for(dt=G.extra;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.length+=It&(1<<G.extra)-1,It>>>=G.extra,Nt-=G.extra,G.back+=G.extra}G.was=G.length,G.mode=23;case 23:for(;Ge=(pt=G.distcode[It&(1<<G.distbits)-1])>>>16&255,pi=65535&pt,!((Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(!(240&Ge)){for(Di=Oe,mn=Ge,Qi=pi;Ge=(pt=G.distcode[Qi+((It&(1<<Di+mn)-1)>>Di)])>>>16&255,pi=65535&pt,!(Di+(Oe=pt>>>24)<=Nt);){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}It>>>=Di,Nt-=Di,G.back+=Di}if(It>>>=Oe,Nt-=Oe,G.back+=Oe,64&Ge){tt.msg="invalid distance code",G.mode=30;break}G.offset=pi,G.extra=15&Ge,G.mode=24;case 24:if(G.extra){for(dt=G.extra;Nt<dt;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}G.offset+=It&(1<<G.extra)-1,It>>>=G.extra,Nt-=G.extra,G.back+=G.extra}if(G.offset>G.dmax){tt.msg="invalid distance too far back",G.mode=30;break}G.mode=25;case 25:if(Ft===0)break t;if(Wt=pe-Ft,G.offset>Wt){if((Wt=G.offset-Wt)>G.whave&&G.sane){tt.msg="invalid distance too far back",G.mode=30;break}$e=Wt>G.wnext?(Wt-=G.wnext,G.wsize-Wt):G.wnext-Wt,Wt>G.length&&(Wt=G.length),Si=G.window}else Si=Et,$e=ce-G.offset,Wt=G.length;for(Ft<Wt&&(Wt=Ft),Ft-=Wt,G.length-=Wt;Et[ce++]=Si[$e++],--Wt;);G.length===0&&(G.mode=21);break;case 26:if(Ft===0)break t;Et[ce++]=G.length,Ft--,G.mode=21;break;case 27:if(G.wrap){for(;Nt<32;){if(re===0)break t;re--,It|=Pt[At++]<<Nt,Nt+=8}if(pe-=Ft,tt.total_out+=pe,G.total+=pe,pe&&(tt.adler=G.check=G.flags?g(G.check,Et,pe,ce-pe):m(G.check,Et,pe,ce-pe)),pe=Ft,(G.flags?It:w(It))!==G.check){tt.msg="incorrect data check",G.mode=30;break}Nt=It=0}G.mode=28;case 28:if(G.wrap&&G.flags){for(;Nt<32;){if(re===0)break t;re--,It+=Pt[At++]<<Nt,Nt+=8}if(It!==(4294967295&G.total)){tt.msg="incorrect length check",G.mode=30;break}Nt=It=0}G.mode=29;case 29:Jt=1;break t;case 30:Jt=-3;break t;case 31:return-4;case 32:default:return I}return tt.next_out=ce,tt.avail_out=Ft,tt.next_in=At,tt.avail_in=re,G.hold=It,G.bits=Nt,(G.wsize||pe!==tt.avail_out&&G.mode<30&&(G.mode<27||_t!==4))&&Rt(tt,tt.output,tt.next_out,pe-tt.avail_out)?(G.mode=31,-4):(Pe-=tt.avail_in,pe-=tt.avail_out,tt.total_in+=Pe,tt.total_out+=pe,G.total+=pe,G.wrap&&pe&&(tt.adler=G.check=G.flags?g(G.check,Et,pe,tt.next_out-pe):m(G.check,Et,pe,tt.next_out-pe)),tt.data_type=G.bits+(G.last?64:0)+(G.mode===12?128:0)+(G.mode===20||G.mode===15?256:0),(Pe==0&&pe===0||_t===4)&&Jt===k&&(Jt=-5),Jt)},f.inflateEnd=function(tt){if(!tt||!tt.state)return I;var _t=tt.state;return _t.window&&(_t.window=null),tt.state=null,k},f.inflateGetHeader=function(tt,_t){var G;return tt&&tt.state&&2&(G=tt.state).wrap?((G.head=_t).done=!1,k):I},f.inflateSetDictionary=function(tt,_t){var G,Pt=_t.length;return tt&&tt.state?(G=tt.state).wrap!==0&&G.mode!==11?I:G.mode===11&&m(1,_t,Pt,0)!==G.check?-3:Rt(tt,_t,Pt,Pt)?(G.mode=31,-4):(G.havedict=1,k):I},f.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(o,c,f){var u=o("../utils/common"),m=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],g=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],v=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],S=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,O,k,I,F,E,P,w){var M,R,C,U,N,X,J,Z,ct,Rt=w.bits,tt=0,_t=0,G=0,Pt=0,Et=0,At=0,ce=0,re=0,Ft=0,It=0,Nt=null,Pe=0,pe=new u.Buf16(16),Wt=new u.Buf16(16),$e=null,Si=0;for(tt=0;tt<=15;tt++)pe[tt]=0;for(_t=0;_t<I;_t++)pe[O[k+_t]]++;for(Et=Rt,Pt=15;1<=Pt&&pe[Pt]===0;Pt--);if(Pt<Et&&(Et=Pt),Pt===0)return F[E++]=20971520,F[E++]=20971520,w.bits=1,0;for(G=1;G<Pt&&pe[G]===0;G++);for(Et<G&&(Et=G),tt=re=1;tt<=15;tt++)if(re<<=1,(re-=pe[tt])<0)return-1;if(0<re&&(b===0||Pt!==1))return-1;for(Wt[1]=0,tt=1;tt<15;tt++)Wt[tt+1]=Wt[tt]+pe[tt];for(_t=0;_t<I;_t++)O[k+_t]!==0&&(P[Wt[O[k+_t]]++]=_t);if(X=b===0?(Nt=$e=P,19):b===1?(Nt=m,Pe-=257,$e=g,Si-=257,256):(Nt=v,$e=S,-1),tt=G,N=E,ce=_t=It=0,C=-1,U=(Ft=1<<(At=Et))-1,b===1&&852<Ft||b===2&&592<Ft)return 1;for(;;){for(J=tt-ce,ct=P[_t]<X?(Z=0,P[_t]):P[_t]>X?(Z=$e[Si+P[_t]],Nt[Pe+P[_t]]):(Z=96,0),M=1<<tt-ce,G=R=1<<At;F[N+(It>>ce)+(R-=M)]=J<<24|Z<<16|ct|0,R!==0;);for(M=1<<tt-1;It&M;)M>>=1;if(M!==0?(It&=M-1,It+=M):It=0,_t++,--pe[tt]==0){if(tt===Pt)break;tt=O[k+P[_t]]}if(Et<tt&&(It&U)!==C){for(ce===0&&(ce=Et),N+=G,re=1<<(At=tt-ce);At+ce<Pt&&!((re-=pe[At+ce])<=0);)At++,re<<=1;if(Ft+=1<<At,b===1&&852<Ft||b===2&&592<Ft)return 1;F[C=It&U]=Et<<24|At<<16|N-E|0}}return It!==0&&(F[N+It]=tt-ce<<24|64<<16|0),w.bits=Et,0}},{"../utils/common":41}],51:[function(o,c,f){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(o,c,f){var u=o("../utils/common"),m=0,g=1;function v(pt){for(var Dt=pt.length;0<=--Dt;)pt[Dt]=0}var S=0,b=29,O=256,k=O+1+b,I=30,F=19,E=2*k+1,P=15,w=16,M=7,R=256,C=16,U=17,N=18,X=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],J=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],Z=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],ct=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],Rt=new Array(2*(k+2));v(Rt);var tt=new Array(2*I);v(tt);var _t=new Array(512);v(_t);var G=new Array(256);v(G);var Pt=new Array(b);v(Pt);var Et,At,ce,re=new Array(I);function Ft(pt,Dt,ie,Kt,z){this.static_tree=pt,this.extra_bits=Dt,this.extra_base=ie,this.elems=Kt,this.max_length=z,this.has_stree=pt&&pt.length}function It(pt,Dt){this.dyn_tree=pt,this.max_code=0,this.stat_desc=Dt}function Nt(pt){return pt<256?_t[pt]:_t[256+(pt>>>7)]}function Pe(pt,Dt){pt.pending_buf[pt.pending++]=255&Dt,pt.pending_buf[pt.pending++]=Dt>>>8&255}function pe(pt,Dt,ie){pt.bi_valid>w-ie?(pt.bi_buf|=Dt<<pt.bi_valid&65535,Pe(pt,pt.bi_buf),pt.bi_buf=Dt>>w-pt.bi_valid,pt.bi_valid+=ie-w):(pt.bi_buf|=Dt<<pt.bi_valid&65535,pt.bi_valid+=ie)}function Wt(pt,Dt,ie){pe(pt,ie[2*Dt],ie[2*Dt+1])}function $e(pt,Dt){for(var ie=0;ie|=1&pt,pt>>>=1,ie<<=1,0<--Dt;);return ie>>>1}function Si(pt,Dt,ie){var Kt,z,Q=new Array(P+1),st=0;for(Kt=1;Kt<=P;Kt++)Q[Kt]=st=st+ie[Kt-1]<<1;for(z=0;z<=Dt;z++){var nt=pt[2*z+1];nt!==0&&(pt[2*z]=$e(Q[nt]++,nt))}}function Oe(pt){var Dt;for(Dt=0;Dt<k;Dt++)pt.dyn_ltree[2*Dt]=0;for(Dt=0;Dt<I;Dt++)pt.dyn_dtree[2*Dt]=0;for(Dt=0;Dt<F;Dt++)pt.bl_tree[2*Dt]=0;pt.dyn_ltree[2*R]=1,pt.opt_len=pt.static_len=0,pt.last_lit=pt.matches=0}function Ge(pt){8<pt.bi_valid?Pe(pt,pt.bi_buf):0<pt.bi_valid&&(pt.pending_buf[pt.pending++]=pt.bi_buf),pt.bi_buf=0,pt.bi_valid=0}function pi(pt,Dt,ie,Kt){var z=2*Dt,Q=2*ie;return pt[z]<pt[Q]||pt[z]===pt[Q]&&Kt[Dt]<=Kt[ie]}function Di(pt,Dt,ie){for(var Kt=pt.heap[ie],z=ie<<1;z<=pt.heap_len&&(z<pt.heap_len&&pi(Dt,pt.heap[z+1],pt.heap[z],pt.depth)&&z++,!pi(Dt,Kt,pt.heap[z],pt.depth));)pt.heap[ie]=pt.heap[z],ie=z,z<<=1;pt.heap[ie]=Kt}function mn(pt,Dt,ie){var Kt,z,Q,st,nt=0;if(pt.last_lit!==0)for(;Kt=pt.pending_buf[pt.d_buf+2*nt]<<8|pt.pending_buf[pt.d_buf+2*nt+1],z=pt.pending_buf[pt.l_buf+nt],nt++,Kt===0?Wt(pt,z,Dt):(Wt(pt,(Q=G[z])+O+1,Dt),(st=X[Q])!==0&&pe(pt,z-=Pt[Q],st),Wt(pt,Q=Nt(--Kt),ie),(st=J[Q])!==0&&pe(pt,Kt-=re[Q],st)),nt<pt.last_lit;);Wt(pt,R,Dt)}function Qi(pt,Dt){var ie,Kt,z,Q=Dt.dyn_tree,st=Dt.stat_desc.static_tree,nt=Dt.stat_desc.has_stree,vt=Dt.stat_desc.elems,Ut=-1;for(pt.heap_len=0,pt.heap_max=E,ie=0;ie<vt;ie++)Q[2*ie]!==0?(pt.heap[++pt.heap_len]=Ut=ie,pt.depth[ie]=0):Q[2*ie+1]=0;for(;pt.heap_len<2;)Q[2*(z=pt.heap[++pt.heap_len]=Ut<2?++Ut:0)]=1,pt.depth[z]=0,pt.opt_len--,nt&&(pt.static_len-=st[2*z+1]);for(Dt.max_code=Ut,ie=pt.heap_len>>1;1<=ie;ie--)Di(pt,Q,ie);for(z=vt;ie=pt.heap[1],pt.heap[1]=pt.heap[pt.heap_len--],Di(pt,Q,1),Kt=pt.heap[1],pt.heap[--pt.heap_max]=ie,pt.heap[--pt.heap_max]=Kt,Q[2*z]=Q[2*ie]+Q[2*Kt],pt.depth[z]=(pt.depth[ie]>=pt.depth[Kt]?pt.depth[ie]:pt.depth[Kt])+1,Q[2*ie+1]=Q[2*Kt+1]=z,pt.heap[1]=z++,Di(pt,Q,1),2<=pt.heap_len;);pt.heap[--pt.heap_max]=pt.heap[1],function(qt,Xt){var Ne,Ie,me,we,yi,Ei,ni=Xt.dyn_tree,bi=Xt.max_code,qr=Xt.stat_desc.static_tree,sr=Xt.stat_desc.has_stree,sn=Xt.stat_desc.extra_bits,Ao=Xt.stat_desc.extra_base,zi=Xt.stat_desc.max_length,Yo=0;for(we=0;we<=P;we++)qt.bl_count[we]=0;for(ni[2*qt.heap[qt.heap_max]+1]=0,Ne=qt.heap_max+1;Ne<E;Ne++)zi<(we=ni[2*ni[2*(Ie=qt.heap[Ne])+1]+1]+1)&&(we=zi,Yo++),ni[2*Ie+1]=we,bi<Ie||(qt.bl_count[we]++,yi=0,Ao<=Ie&&(yi=sn[Ie-Ao]),Ei=ni[2*Ie],qt.opt_len+=Ei*(we+yi),sr&&(qt.static_len+=Ei*(qr[2*Ie+1]+yi)));if(Yo!==0){do{for(we=zi-1;qt.bl_count[we]===0;)we--;qt.bl_count[we]--,qt.bl_count[we+1]+=2,qt.bl_count[zi]--,Yo-=2}while(0<Yo);for(we=zi;we!==0;we--)for(Ie=qt.bl_count[we];Ie!==0;)bi<(me=qt.heap[--Ne])||(ni[2*me+1]!==we&&(qt.opt_len+=(we-ni[2*me+1])*ni[2*me],ni[2*me+1]=we),Ie--)}}(pt,Dt),Si(Q,Ut,pt.bl_count)}function W(pt,Dt,ie){var Kt,z,Q=-1,st=Dt[1],nt=0,vt=7,Ut=4;for(st===0&&(vt=138,Ut=3),Dt[2*(ie+1)+1]=65535,Kt=0;Kt<=ie;Kt++)z=st,st=Dt[2*(Kt+1)+1],++nt<vt&&z===st||(nt<Ut?pt.bl_tree[2*z]+=nt:z!==0?(z!==Q&&pt.bl_tree[2*z]++,pt.bl_tree[2*C]++):nt<=10?pt.bl_tree[2*U]++:pt.bl_tree[2*N]++,Q=z,Ut=(nt=0)===st?(vt=138,3):z===st?(vt=6,3):(vt=7,4))}function Jt(pt,Dt,ie){var Kt,z,Q=-1,st=Dt[1],nt=0,vt=7,Ut=4;for(st===0&&(vt=138,Ut=3),Kt=0;Kt<=ie;Kt++)if(z=st,st=Dt[2*(Kt+1)+1],!(++nt<vt&&z===st)){if(nt<Ut)for(;Wt(pt,z,pt.bl_tree),--nt!=0;);else z!==0?(z!==Q&&(Wt(pt,z,pt.bl_tree),nt--),Wt(pt,C,pt.bl_tree),pe(pt,nt-3,2)):nt<=10?(Wt(pt,U,pt.bl_tree),pe(pt,nt-3,3)):(Wt(pt,N,pt.bl_tree),pe(pt,nt-11,7));Q=z,Ut=(nt=0)===st?(vt=138,3):z===st?(vt=6,3):(vt=7,4)}}v(re);var jt=!1;function dt(pt,Dt,ie,Kt){pe(pt,(S<<1)+(Kt?1:0),3),function(z,Q,st,nt){Ge(z),nt&&(Pe(z,st),Pe(z,~st)),u.arraySet(z.pending_buf,z.window,Q,st,z.pending),z.pending+=st}(pt,Dt,ie,!0)}f._tr_init=function(pt){jt||(function(){var Dt,ie,Kt,z,Q,st=new Array(P+1);for(z=Kt=0;z<b-1;z++)for(Pt[z]=Kt,Dt=0;Dt<1<<X[z];Dt++)G[Kt++]=z;for(G[Kt-1]=z,z=Q=0;z<16;z++)for(re[z]=Q,Dt=0;Dt<1<<J[z];Dt++)_t[Q++]=z;for(Q>>=7;z<I;z++)for(re[z]=Q<<7,Dt=0;Dt<1<<J[z]-7;Dt++)_t[256+Q++]=z;for(ie=0;ie<=P;ie++)st[ie]=0;for(Dt=0;Dt<=143;)Rt[2*Dt+1]=8,Dt++,st[8]++;for(;Dt<=255;)Rt[2*Dt+1]=9,Dt++,st[9]++;for(;Dt<=279;)Rt[2*Dt+1]=7,Dt++,st[7]++;for(;Dt<=287;)Rt[2*Dt+1]=8,Dt++,st[8]++;for(Si(Rt,k+1,st),Dt=0;Dt<I;Dt++)tt[2*Dt+1]=5,tt[2*Dt]=$e(Dt,5);Et=new Ft(Rt,X,O+1,k,P),At=new Ft(tt,J,0,I,P),ce=new Ft(new Array(0),Z,0,F,M)}(),jt=!0),pt.l_desc=new It(pt.dyn_ltree,Et),pt.d_desc=new It(pt.dyn_dtree,At),pt.bl_desc=new It(pt.bl_tree,ce),pt.bi_buf=0,pt.bi_valid=0,Oe(pt)},f._tr_stored_block=dt,f._tr_flush_block=function(pt,Dt,ie,Kt){var z,Q,st=0;0<pt.level?(pt.strm.data_type===2&&(pt.strm.data_type=function(nt){var vt,Ut=4093624447;for(vt=0;vt<=31;vt++,Ut>>>=1)if(1&Ut&&nt.dyn_ltree[2*vt]!==0)return m;if(nt.dyn_ltree[18]!==0||nt.dyn_ltree[20]!==0||nt.dyn_ltree[26]!==0)return g;for(vt=32;vt<O;vt++)if(nt.dyn_ltree[2*vt]!==0)return g;return m}(pt)),Qi(pt,pt.l_desc),Qi(pt,pt.d_desc),st=function(nt){var vt;for(W(nt,nt.dyn_ltree,nt.l_desc.max_code),W(nt,nt.dyn_dtree,nt.d_desc.max_code),Qi(nt,nt.bl_desc),vt=F-1;3<=vt&&nt.bl_tree[2*ct[vt]+1]===0;vt--);return nt.opt_len+=3*(vt+1)+5+5+4,vt}(pt),z=pt.opt_len+3+7>>>3,(Q=pt.static_len+3+7>>>3)<=z&&(z=Q)):z=Q=ie+5,ie+4<=z&&Dt!==-1?dt(pt,Dt,ie,Kt):pt.strategy===4||Q===z?(pe(pt,2+(Kt?1:0),3),mn(pt,Rt,tt)):(pe(pt,4+(Kt?1:0),3),function(nt,vt,Ut,qt){var Xt;for(pe(nt,vt-257,5),pe(nt,Ut-1,5),pe(nt,qt-4,4),Xt=0;Xt<qt;Xt++)pe(nt,nt.bl_tree[2*ct[Xt]+1],3);Jt(nt,nt.dyn_ltree,vt-1),Jt(nt,nt.dyn_dtree,Ut-1)}(pt,pt.l_desc.max_code+1,pt.d_desc.max_code+1,st+1),mn(pt,pt.dyn_ltree,pt.dyn_dtree)),Oe(pt),Kt&&Ge(pt)},f._tr_tally=function(pt,Dt,ie){return pt.pending_buf[pt.d_buf+2*pt.last_lit]=Dt>>>8&255,pt.pending_buf[pt.d_buf+2*pt.last_lit+1]=255&Dt,pt.pending_buf[pt.l_buf+pt.last_lit]=255&ie,pt.last_lit++,Dt===0?pt.dyn_ltree[2*ie]++:(pt.matches++,Dt--,pt.dyn_ltree[2*(G[ie]+O+1)]++,pt.dyn_dtree[2*Nt(Dt)]++),pt.last_lit===pt.lit_bufsize-1},f._tr_align=function(pt){pe(pt,2,3),Wt(pt,R,Rt),function(Dt){Dt.bi_valid===16?(Pe(Dt,Dt.bi_buf),Dt.bi_buf=0,Dt.bi_valid=0):8<=Dt.bi_valid&&(Dt.pending_buf[Dt.pending++]=255&Dt.bi_buf,Dt.bi_buf>>=8,Dt.bi_valid-=8)}(pt)}},{"../utils/common":41}],53:[function(o,c,f){c.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(o,c,f){(function(u){(function(m,g){if(!m.setImmediate){var v,S,b,O,k=1,I={},F=!1,E=m.document,P=Object.getPrototypeOf&&Object.getPrototypeOf(m);P=P&&P.setTimeout?P:m,v={}.toString.call(m.process)==="[object process]"?function(C){process.nextTick(function(){M(C)})}:function(){if(m.postMessage&&!m.importScripts){var C=!0,U=m.onmessage;return m.onmessage=function(){C=!1},m.postMessage("","*"),m.onmessage=U,C}}()?(O="setImmediate$"+Math.random()+"$",m.addEventListener?m.addEventListener("message",R,!1):m.attachEvent("onmessage",R),function(C){m.postMessage(O+C,"*")}):m.MessageChannel?((b=new MessageChannel).port1.onmessage=function(C){M(C.data)},function(C){b.port2.postMessage(C)}):E&&"onreadystatechange"in E.createElement("script")?(S=E.documentElement,function(C){var U=E.createElement("script");U.onreadystatechange=function(){M(C),U.onreadystatechange=null,S.removeChild(U),U=null},S.appendChild(U)}):function(C){setTimeout(M,0,C)},P.setImmediate=function(C){typeof C!="function"&&(C=new Function(""+C));for(var U=new Array(arguments.length-1),N=0;N<U.length;N++)U[N]=arguments[N+1];var X={callback:C,args:U};return I[k]=X,v(k),k++},P.clearImmediate=w}function w(C){delete I[C]}function M(C){if(F)setTimeout(M,0,C);else{var U=I[C];if(U){F=!0;try{(function(N){var X=N.callback,J=N.args;switch(J.length){case 0:X();break;case 1:X(J[0]);break;case 2:X(J[0],J[1]);break;case 3:X(J[0],J[1],J[2]);break;default:X.apply(g,J)}})(U)}finally{w(C),F=!1}}}}function R(C){C.source===m&&typeof C.data=="string"&&C.data.indexOf(O)===0&&M(+C.data.slice(O.length))}})(typeof self>"u"?u===void 0?this:u:self)}).call(this,typeof Er<"u"?Er:typeof self<"u"?self:typeof window<"u"?window:{})},{}]},{},[10])(10)})})(Cf);var dm=Cf.exports;const pm=tc(dm);var Af={exports:{}};(function(x,a){(function(o,c){c()})(Er,function(){function o(S,b){return typeof b>"u"?b={autoBom:!1}:typeof b!="object"&&(b={autoBom:!b}),b.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(S.type)?new Blob(["\uFEFF",S],{type:S.type}):S}function c(S,b,O){var k=new XMLHttpRequest;k.open("GET",S),k.responseType="blob",k.onload=function(){v(k.response,b,O)},k.onerror=function(){},k.send()}function f(S){var b=new XMLHttpRequest;b.open("HEAD",S,!1);try{b.send()}catch{}return 200<=b.status&&299>=b.status}function u(S){try{S.dispatchEvent(new MouseEvent("click"))}catch{var b=document.createEvent("MouseEvents");b.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),S.dispatchEvent(b)}}var m=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof Er=="object"&&Er.global===Er?Er:void 0,g=m.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),v=m.saveAs||(typeof window!="object"||window!==m?function(){}:"download"in HTMLAnchorElement.prototype&&!g?function(S,b,O){var k=m.URL||m.webkitURL,I=document.createElement("a");b=b||S.name||"download",I.download=b,I.rel="noopener",typeof S=="string"?(I.href=S,I.origin===location.origin?u(I):f(I.href)?c(S,b,O):u(I,I.target="_blank")):(I.href=k.createObjectURL(S),setTimeout(function(){k.revokeObjectURL(I.href)},4e4),setTimeout(function(){u(I)},0))}:"msSaveOrOpenBlob"in navigator?function(S,b,O){if(b=b||S.name||"download",typeof S!="string")navigator.msSaveOrOpenBlob(o(S,O),b);else if(f(S))c(S,b,O);else{var k=document.createElement("a");k.href=S,k.target="_blank",setTimeout(function(){u(k)})}}:function(S,b,O,k){if(k=k||open("","_blank"),k&&(k.document.title=k.document.body.innerText="downloading..."),typeof S=="string")return c(S,b,O);var I=S.type==="application/octet-stream",F=/constructor/i.test(m.HTMLElement)||m.safari,E=/CriOS\/[\d]+/.test(navigator.userAgent);if((E||I&&F||g)&&typeof FileReader<"u"){var P=new FileReader;P.onloadend=function(){var R=P.result;R=E?R:R.replace(/^data:[^;]*;/,"data:attachment/file;"),k?k.location.href=R:location=R,k=null},P.readAsDataURL(S)}else{var w=m.URL||m.webkitURL,M=w.createObjectURL(S);k?k.location=M:location.href=M,k=null,setTimeout(function(){w.revokeObjectURL(M)},4e4)}});m.saveAs=v.saveAs=v,x.exports=v})})(Af);var mm=Af.exports;const gm=tc(mm);class vm{constructor(a,o){window.mars3d&&(this.panoramicViewClass=o,this.coordinate=[{heading:0,pitch:0,stop:5},{heading:90,pitch:0,stop:5},{heading:180,pitch:0,stop:5},{heading:270,pitch:0,stop:5},{heading:0,pitch:90,stop:5},{heading:0,pitch:-90,stop:5}],this.screenshotArray=[],this.events={},this.timestamp=0,this.lat,this.lng,this.alt)}start(a=!0){var o,c;if(a){window.map.container.getElementsByClassName("mars3d-locationbar")&&(window.map.container.getElementsByClassName("mars3d-locationbar")[0].style.display="none"),this.timestamp=new Date().getTime();const f=document.getElementById("app"),u=window.innerHeight,m=document.getElementById("mars3dContainer");m&&(m.style.width=u.toString()+"px",m.style.height=u.toString()+"px"),f!==null&&f.classList.add(this.panoramicViewClass);let{lat:g,lng:v,alt:S}=window.map.getCameraView();this.lat=g,this.lng=v,this.alt=S,window.map.viewer.scene.camera.frustum.fov=window.Cesium.Math.PI_OVER_THREE*1.5}this.screenshotArray&&this.coordinate?this.coordinate[(o=this.screenshotArray)==null?void 0:o.length]?window.map.setCameraView({lat:this.lat,lng:this.lng,alt:this.alt,...this.coordinate[(c=this.screenshotArray)==null?void 0:c.length]},{complete:()=>{setTimeout(()=>{var f;this.screenshot((f=this.screenshotArray)==null?void 0:f.length)},100)}}):(this.downloadImagesAsZip(),this.screenshotArray=[]):this.emit("state",{type:"error"})}async screenshot(a){const o=await window.map.expImage({download:!1}),c=window.map.container.getElementsByClassName("cesium-viewer-cesiumWidgetContainer"),f=await window.domtoimage.toPng(window.map.container,{filter:u=>u!==c[0]});this.mergeImage(o.image,f,o.width,o.height).then(u=>{var v;let m=Number(a)+1,g={src:u,name:"全景图_"+this.timestamp+"_"+m+".jpg"};this.emit("intercept",g),(v=this.screenshotArray)==null||v.push(g),this.start(!1)})}mergeImage(a,o,c,f){return new Promise((u,m)=>{const g=document.createElement("canvas");g.width=c,g.height=f;const v=g.getContext("2d");if(g&&v){const S=new Image;S.crossOrigin="Anonymous",S.onload=()=>{v.drawImage(S,0,0,c,f);const b=new Image;b.crossOrigin="Anonymous",b.onload=()=>{v.drawImage(b,0,0,c,f);const O=g.toDataURL("image/png");u(O)},b.src=o},S.src=a}else m()})}download(){this.screenshotArray&&this.screenshotArray.forEach(a=>{window.mars3d.Util.downloadBase64Image(a.name,a.src)})}async downloadImagesAsZip(){if(this.screenshotArray){const a=new pm;this.screenshotArray.forEach(c=>{const f=c.src.split(",")[1],u=atob(f),m=[];for(let S=0;S<u.length;S+=1024){const b=u.slice(S,S+1024),O=new Array(b.length);for(let I=0;I<b.length;I++)O[I]=b.charCodeAt(I);const k=new Uint8Array(O);m.push(k)}const g=new Blob(m,{type:"image/jpeg"}),v=`${c.name}`;a.file(v,g,{binary:!0})});const o=await a.generateAsync({type:"blob"});gm(o,"CHBIM-Panorama.zip"),this.emit("state",{type:"success",schedule:100}),this.init()}}init(){const a=document.getElementById("app");a&&a.classList.remove(this.panoramicViewClass);const o=document.getElementById("mars3dContainer");o&&(o.style.width="",o.style.height=""),window.map.container.getElementsByClassName("mars3d-locationbar")&&(window.map.container.getElementsByClassName("mars3d-locationbar")[0].style.display="")}on(a,o){this.events[a]?this.events[a].push(o):this.events[a]=[o]}emit(a,...o){this.events[a]!=null&&this.events[a].forEach(c=>c(...o))}off(a,o){this.events[a]=this.events[a].filter(c=>c!==o)}}function fs(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}function Pf(x,a){x.prototype=Object.create(a.prototype),x.prototype.constructor=x,x.__proto__=a}/*!
|
|
2687
2687
|
* GSAP 3.12.5
|
|
2688
2688
|
* https://gsap.com
|
|
2689
2689
|
*
|
|
@@ -2691,7 +2691,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
2691
2691
|
* Subject to the terms at https://gsap.com/standard-license or for
|
|
2692
2692
|
* Club GSAP members, the agreement issued with that membership.
|
|
2693
2693
|
* @author: Jack Doyle, jack@greensock.com
|
|
2694
|
-
*/var Hr={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},Ll={duration:.5,overwrite:!1,delay:0},ic,nr,hn,no=1e8,en=1/no,nc=Math.PI*2,ym=nc/4,_m=0,Lf=Math.sqrt,xm=Math.cos,wm=Math.sin,Wn=function(a){return typeof a=="string"},Tn=function(a){return typeof a=="function"},ds=function(a){return typeof a=="number"},rc=function(a){return typeof a>"u"},Vo=function(a){return typeof a=="object"},br=function(a){return a!==!1},oc=function(){return typeof window<"u"},uu=function(a){return Tn(a)||Wn(a)},Rf=typeof ArrayBuffer=="function"&&ArrayBuffer.isView||function(){},rr=Array.isArray,sc=/(?:-?\.?\d|\.)+/gi,Of=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,Rl=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,ac=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,If=/[+-]=-?[.\d]+/,Df=/[^,'"\[\]\s]+/gi,Tm=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,dn,Wo,lc,hc,Vr={},cu={},zf,kf=function(a){return(cu=Fa(a,Vr))&&Pr},uc=function(a,o){},yh=function(a,o){return!o&&void 0},Bf=function(a,o){return a&&(Vr[a]=o)&&cu&&(cu[a]=o)||Vr},_h=function(){return 0},Mm={suppressEvents:!0,isStart:!0,kill:!1},fu={suppressEvents:!0,kill:!1},Sm={suppressEvents:!0},cc={},Zs=[],fc={},Nf,Wr={},dc={},Ff=30,du=[],pc="",mc=function(a){var o=a[0],c,f;if(Vo(o)||Tn(o)||(a=[a]),!(c=(o._gsap||{}).harness)){for(f=du.length;f--&&!du[f].targetTest(o););c=du[f]}for(f=a.length;f--;)a[f]&&(a[f]._gsap||(a[f]._gsap=new pd(a[f],c)))||a.splice(f,1);return a},Na=function(a){return a._gsap||mc(so(a))[0]._gsap},Uf=function(a,o,c){return(c=a[o])&&Tn(c)?a[o]():rc(c)&&a.getAttribute&&a.getAttribute(o)||c},Cr=function(a,o){return(a=a.split(",")).forEach(o)||a},Rn=function(a){return Math.round(a*1e5)/1e5||0},jn=function(a){return Math.round(a*1e7)/1e7||0},Ol=function(a,o){var c=o.charAt(0),f=parseFloat(o.substr(2));return a=parseFloat(a),c==="+"?a+f:c==="-"?a-f:c==="*"?a*f:a/f},Em=function(a,o){for(var c=o.length,f=0;a.indexOf(o[f])<0&&++f<c;);return f<c},pu=function(){var a=Zs.length,o=Zs.slice(0),c,f;for(fc={},Zs.length=0,c=0;c<a;c++)f=o[c],f&&f._lazy&&(f.render(f._lazy[0],f._lazy[1],!0)._lazy=0)},Gf=function(a,o,c,f){Zs.length&&!nr&&pu(),a.render(o,c,f||nr&&o<0&&(a._initted||a._startAt)),Zs.length&&!nr&&pu()},Hf=function(a){var o=parseFloat(a);return(o||o===0)&&(a+"").match(Df).length<2?o:Wn(a)?a.trim():a},Vf=function(a){return a},ro=function(a,o){for(var c in o)c in a||(a[c]=o[c]);return a},bm=function(a){return function(o,c){for(var f in c)f in o||f==="duration"&&a||f==="ease"||(o[f]=c[f])}},Fa=function(a,o){for(var c in o)a[c]=o[c];return a},Wf=function x(a,o){for(var c in o)c!=="__proto__"&&c!=="constructor"&&c!=="prototype"&&(a[c]=Vo(o[c])?x(a[c]||(a[c]={}),o[c]):o[c]);return a},mu=function(a,o){var c={},f;for(f in a)f in o||(c[f]=a[f]);return c},xh=function(a){var o=a.parent||dn,c=a.keyframes?bm(rr(a.keyframes)):ro;if(br(a.inherit))for(;o;)c(a,o.vars.defaults),o=o.parent||o._dp;return a},Cm=function(a,o){for(var c=a.length,f=c===o.length;f&&c--&&a[c]===o[c];);return c<0},jf=function(a,o,c,f,u){c===void 0&&(c="_first"),f===void 0&&(f="_last");var m=a[f],g;if(u)for(g=o[u];m&&m[u]>g;)m=m._prev;return m?(o._next=m._next,m._next=o):(o._next=a[c],a[c]=o),o._next?o._next._prev=o:a[f]=o,o._prev=m,o.parent=o._dp=a,o},gu=function(a,o,c,f){c===void 0&&(c="_first"),f===void 0&&(f="_last");var u=o._prev,m=o._next;u?u._next=m:a[c]===o&&(a[c]=m),m?m._prev=u:a[f]===o&&(a[f]=u),o._next=o._prev=o.parent=null},Js=function(a,o){a.parent&&(!o||a.parent.autoRemoveChildren)&&a.parent.remove&&a.parent.remove(a),a._act=0},Ua=function(a,o){if(a&&(!o||o._end>a._dur||o._start<0))for(var c=a;c;)c._dirty=1,c=c.parent;return a},Am=function(a){for(var o=a.parent;o&&o.parent;)o._dirty=1,o.totalDuration(),o=o.parent;return a},gc=function(a,o,c,f){return a._startAt&&(nr?a._startAt.revert(fu):a.vars.immediateRender&&!a.vars.autoRevert||a._startAt.render(o,!0,f))},Pm=function x(a){return!a||a._ts&&x(a.parent)},Xf=function(a){return a._repeat?Il(a._tTime,a=a.duration()+a._rDelay)*a:0},Il=function(a,o){var c=Math.floor(a/=o);return a&&c===a?c-1:c},vu=function(a,o){return(a-o._start)*o._ts+(o._ts>=0?0:o._dirty?o.totalDuration():o._tDur)},yu=function(a){return a._end=jn(a._start+(a._tDur/Math.abs(a._ts||a._rts||en)||0))},_u=function(a,o){var c=a._dp;return c&&c.smoothChildTiming&&a._ts&&(a._start=jn(c._time-(a._ts>0?o/a._ts:((a._dirty?a.totalDuration():a._tDur)-o)/-a._ts)),yu(a),c._dirty||Ua(c,a)),a},qf=function(a,o){var c;if((o._time||!o._dur&&o._initted||o._start<a._time&&(o._dur||!o.add))&&(c=vu(a.rawTime(),o),(!o._dur||Th(0,o.totalDuration(),c)-o._tTime>en)&&o.render(c,!0)),Ua(a,o)._dp&&a._initted&&a._time>=a._dur&&a._ts){if(a._dur<a.duration())for(c=a;c._dp;)c.rawTime()>=0&&c.totalTime(c._tTime),c=c._dp;a._zTime=-en}},jo=function(a,o,c,f){return o.parent&&Js(o),o._start=jn((ds(c)?c:c||a!==dn?oo(a,c,o):a._time)+o._delay),o._end=jn(o._start+(o.totalDuration()/Math.abs(o.timeScale())||0)),jf(a,o,"_first","_last",a._sort?"_start":0),vc(o)||(a._recent=o),f||qf(a,o),a._ts<0&&_u(a,a._tTime),a},Yf=function(a,o){return(Vr.ScrollTrigger||uc("scrollTrigger",o))&&Vr.ScrollTrigger.create(o,a)},Zf=function(a,o,c,f,u){if(bc(a,o,u),!a._initted)return 1;if(!c&&a._pt&&!nr&&(a._dur&&a.vars.lazy!==!1||!a._dur&&a.vars.lazy)&&Nf!==Xr.frame)return Zs.push(a),a._lazy=[u,f],1},Lm=function x(a){var o=a.parent;return o&&o._ts&&o._initted&&!o._lock&&(o.rawTime()<0||x(o))},vc=function(a){var o=a.data;return o==="isFromStart"||o==="isStart"},Rm=function(a,o,c,f){var u=a.ratio,m=o<0||!o&&(!a._start&&Lm(a)&&!(!a._initted&&vc(a))||(a._ts<0||a._dp._ts<0)&&!vc(a))?0:1,g=a._rDelay,v=0,S,b,O;if(g&&a._repeat&&(v=Th(0,a._tDur,o),b=Il(v,g),a._yoyo&&b&1&&(m=1-m),b!==Il(a._tTime,g)&&(u=1-m,a.vars.repeatRefresh&&a._initted&&a.invalidate())),m!==u||nr||f||a._zTime===en||!o&&a._zTime){if(!a._initted&&Zf(a,o,f,c,v))return;for(O=a._zTime,a._zTime=o||(c?en:0),c||(c=o&&!O),a.ratio=m,a._from&&(m=1-m),a._time=0,a._tTime=v,S=a._pt;S;)S.r(m,S.d),S=S._next;o<0&&gc(a,o,c,!0),a._onUpdate&&!c&&jr(a,"onUpdate"),v&&a._repeat&&!c&&a.parent&&jr(a,"onRepeat"),(o>=a._tDur||o<0)&&a.ratio===m&&(m&&Js(a,1),!c&&!nr&&(jr(a,m?"onComplete":"onReverseComplete",!0),a._prom&&a._prom()))}else a._zTime||(a._zTime=o)},Om=function(a,o,c){var f;if(c>o)for(f=a._first;f&&f._start<=c;){if(f.data==="isPause"&&f._start>o)return f;f=f._next}else for(f=a._last;f&&f._start>=c;){if(f.data==="isPause"&&f._start<o)return f;f=f._prev}},Dl=function(a,o,c,f){var u=a._repeat,m=jn(o)||0,g=a._tTime/a._tDur;return g&&!f&&(a._time*=m/a._dur),a._dur=m,a._tDur=u?u<0?1e10:jn(m*(u+1)+a._rDelay*u):m,g>0&&!f&&_u(a,a._tTime=a._tDur*g),a.parent&&yu(a),c||Ua(a.parent,a),a},Jf=function(a){return a instanceof gr?Ua(a):Dl(a,a._dur)},Im={_start:0,endTime:_h,totalDuration:_h},oo=function x(a,o,c){var f=a.labels,u=a._recent||Im,m=a.duration()>=no?u.endTime(!1):a._dur,g,v,S;return Wn(o)&&(isNaN(o)||o in f)?(v=o.charAt(0),S=o.substr(-1)==="%",g=o.indexOf("="),v==="<"||v===">"?(g>=0&&(o=o.replace(/=/,"")),(v==="<"?u._start:u.endTime(u._repeat>=0))+(parseFloat(o.substr(1))||0)*(S?(g<0?u:c).totalDuration()/100:1)):g<0?(o in f||(f[o]=m),f[o]):(v=parseFloat(o.charAt(g-1)+o.substr(g+1)),S&&c&&(v=v/100*(rr(c)?c[0]:c).totalDuration()),g>1?x(a,o.substr(0,g-1),c)+v:m+v)):o==null?m:+o},wh=function(a,o,c){var f=ds(o[1]),u=(f?2:1)+(a<2?0:1),m=o[u],g,v;if(f&&(m.duration=o[1]),m.parent=c,a){for(g=m,v=c;v&&!("immediateRender"in g);)g=v.vars.defaults||{},v=br(v.vars.inherit)&&v.parent;m.immediateRender=br(g.immediateRender),a<2?m.runBackwards=1:m.startAt=o[u-1]}return new kn(o[0],m,o[u+1])},$s=function(a,o){return a||a===0?o(a):o},Th=function(a,o,c){return c<a?a:c>o?o:c},or=function(a,o){return!Wn(a)||!(o=Tm.exec(a))?"":o[1]},Dm=function(a,o,c){return $s(c,function(f){return Th(a,o,f)})},yc=[].slice,$f=function(a,o){return a&&Vo(a)&&"length"in a&&(!o&&!a.length||a.length-1 in a&&Vo(a[0]))&&!a.nodeType&&a!==Wo},zm=function(a,o,c){return c===void 0&&(c=[]),a.forEach(function(f){var u;return Wn(f)&&!o||$f(f,1)?(u=c).push.apply(u,so(f)):c.push(f)})||c},so=function(a,o,c){return hn&&!o&&hn.selector?hn.selector(a):Wn(a)&&!c&&(lc||!kl())?yc.call((o||hc).querySelectorAll(a),0):rr(a)?zm(a,c):$f(a)?yc.call(a,0):a?[a]:[]},_c=function(a){return a=so(a)[0]||yh("Invalid scope")||{},function(o){var c=a.current||a.nativeElement||a;return so(o,c.querySelectorAll?c:c===a?yh("Invalid scope")||hc.createElement("div"):a)}},Kf=function(a){return a.sort(function(){return .5-Math.random()})},Qf=function(a){if(Tn(a))return a;var o=Vo(a)?a:{each:a},c=Ga(o.ease),f=o.from||0,u=parseFloat(o.base)||0,m={},g=f>0&&f<1,v=isNaN(f)||g,S=o.axis,b=f,O=f;return Wn(f)?b=O={center:.5,edges:.5,end:1}[f]||0:!g&&v&&(b=f[0],O=f[1]),function(k,I,N){var E=(N||o).length,P=m[E],w,M,R,C,U,F,X,K,Z;if(!P){if(Z=o.grid==="auto"?0:(o.grid||[1,no])[1],!Z){for(X=-no;X<(X=N[Z++].getBoundingClientRect().left)&&Z<E;);Z<E&&Z--}for(P=m[E]=[],w=v?Math.min(Z,E)*b-.5:f%Z,M=Z===no?0:v?E*O/Z-.5:f/Z|0,X=0,K=no,F=0;F<E;F++)R=F%Z-w,C=M-(F/Z|0),P[F]=U=S?Math.abs(S==="y"?C:R):Lf(R*R+C*C),U>X&&(X=U),U<K&&(K=U);f==="random"&&Kf(P),P.max=X-K,P.min=K,P.v=E=(parseFloat(o.amount)||parseFloat(o.each)*(Z>E?E-1:S?S==="y"?E/Z:Z:Math.max(Z,E/Z))||0)*(f==="edges"?-1:1),P.b=E<0?u-E:u,P.u=or(o.amount||o.each)||0,c=c&&E<0?cd(c):c}return E=(P[k]-P.min)/P.max||0,jn(P.b+(c?c(E):E)*P.v)+P.u}},xc=function(a){var o=Math.pow(10,((a+"").split(".")[1]||"").length);return function(c){var f=jn(Math.round(parseFloat(c)/a)*a*o);return(f-f%1)/o+(ds(c)?0:or(c))}},td=function(a,o){var c=rr(a),f,u;return!c&&Vo(a)&&(f=c=a.radius||no,a.values?(a=so(a.values),(u=!ds(a[0]))&&(f*=f)):a=xc(a.increment)),$s(o,c?Tn(a)?function(m){return u=a(m),Math.abs(u-m)<=f?u:m}:function(m){for(var g=parseFloat(u?m.x:m),v=parseFloat(u?m.y:0),S=no,b=0,O=a.length,k,I;O--;)u?(k=a[O].x-g,I=a[O].y-v,k=k*k+I*I):k=Math.abs(a[O]-g),k<S&&(S=k,b=O);return b=!f||S<=f?a[b]:m,u||b===m||ds(m)?b:b+or(m)}:xc(a))},ed=function(a,o,c,f){return $s(rr(a)?!o:c===!0?!!(c=0):!f,function(){return rr(a)?a[~~(Math.random()*a.length)]:(c=c||1e-5)&&(f=c<1?Math.pow(10,(c+"").length-2):1)&&Math.floor(Math.round((a-c/2+Math.random()*(o-a+c*.99))/c)*c*f)/f})},km=function(){for(var a=arguments.length,o=new Array(a),c=0;c<a;c++)o[c]=arguments[c];return function(f){return o.reduce(function(u,m){return m(u)},f)}},Bm=function(a,o){return function(c){return a(parseFloat(c))+(o||or(c))}},Nm=function(a,o,c){return nd(a,o,0,1,c)},id=function(a,o,c){return $s(c,function(f){return a[~~o(f)]})},Fm=function x(a,o,c){var f=o-a;return rr(a)?id(a,x(0,a.length),o):$s(c,function(u){return(f+(u-a)%f)%f+a})},Um=function x(a,o,c){var f=o-a,u=f*2;return rr(a)?id(a,x(0,a.length-1),o):$s(c,function(m){return m=(u+(m-a)%u)%u||0,a+(m>f?u-m:m)})},Mh=function(a){for(var o=0,c="",f,u,m,g;~(f=a.indexOf("random(",o));)m=a.indexOf(")",f),g=a.charAt(f+7)==="[",u=a.substr(f+7,m-f-7).match(g?Df:sc),c+=a.substr(o,f-o)+ed(g?u:+u[0],g?0:+u[1],+u[2]||1e-5),o=m+1;return c+a.substr(o,a.length-o)},nd=function(a,o,c,f,u){var m=o-a,g=f-c;return $s(u,function(v){return c+((v-a)/m*g||0)})},Gm=function x(a,o,c,f){var u=isNaN(a+o)?0:function(I){return(1-I)*a+I*o};if(!u){var m=Wn(a),g={},v,S,b,O,k;if(c===!0&&(f=1)&&(c=null),m)a={p:a},o={p:o};else if(rr(a)&&!rr(o)){for(b=[],O=a.length,k=O-2,S=1;S<O;S++)b.push(x(a[S-1],a[S]));O--,u=function(N){N*=O;var E=Math.min(k,~~N);return b[E](N-E)},c=o}else f||(a=Fa(rr(a)?[]:{},a));if(!b){for(v in o)Sc.call(g,a,v,"get",o[v]);u=function(N){return Pc(N,g)||(m?a.p:a)}}}return $s(c,u)},rd=function(a,o,c){var f=a.labels,u=no,m,g,v;for(m in f)g=f[m]-o,g<0==!!c&&g&&u>(g=Math.abs(g))&&(v=m,u=g);return v},jr=function(a,o,c){var f=a.vars,u=f[o],m=hn,g=a._ctx,v,S,b;if(u)return v=f[o+"Params"],S=f.callbackScope||a,c&&Zs.length&&pu(),g&&(hn=g),b=v?u.apply(S,v):u.call(S),hn=m,b},Sh=function(a){return Js(a),a.scrollTrigger&&a.scrollTrigger.kill(!!nr),a.progress()<1&&jr(a,"onInterrupt"),a},zl,od=[],sd=function(a){if(a)if(a=!a.name&&a.default||a,oc()||a.headless){var o=a.name,c=Tn(a),f=o&&!c&&a.init?function(){this._props=[]}:a,u={init:_h,render:Pc,add:Sc,kill:ng,modifier:ig,rawVars:0},m={targetTest:0,get:0,getSetter:Ac,aliases:{},register:0};if(kl(),a!==f){if(Wr[o])return;ro(f,ro(mu(a,u),m)),Fa(f.prototype,Fa(u,mu(a,m))),Wr[f.prop=o]=f,a.targetTest&&(du.push(f),cc[o]=1),o=(o==="css"?"CSS":o.charAt(0).toUpperCase()+o.substr(1))+"Plugin"}Bf(o,f),a.register&&a.register(Pr,f,Ar)}else od.push(a)},Ki=255,Eh={aqua:[0,Ki,Ki],lime:[0,Ki,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,Ki],navy:[0,0,128],white:[Ki,Ki,Ki],olive:[128,128,0],yellow:[Ki,Ki,0],orange:[Ki,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[Ki,0,0],pink:[Ki,192,203],cyan:[0,Ki,Ki],transparent:[Ki,Ki,Ki,0]},wc=function(a,o,c){return a+=a<0?1:a>1?-1:0,(a*6<1?o+(c-o)*a*6:a<.5?c:a*3<2?o+(c-o)*(2/3-a)*6:o)*Ki+.5|0},ad=function(a,o,c){var f=a?ds(a)?[a>>16,a>>8&Ki,a&Ki]:0:Eh.black,u,m,g,v,S,b,O,k,I,N;if(!f){if(a.substr(-1)===","&&(a=a.substr(0,a.length-1)),Eh[a])f=Eh[a];else if(a.charAt(0)==="#"){if(a.length<6&&(u=a.charAt(1),m=a.charAt(2),g=a.charAt(3),a="#"+u+u+m+m+g+g+(a.length===5?a.charAt(4)+a.charAt(4):"")),a.length===9)return f=parseInt(a.substr(1,6),16),[f>>16,f>>8&Ki,f&Ki,parseInt(a.substr(7),16)/255];a=parseInt(a.substr(1),16),f=[a>>16,a>>8&Ki,a&Ki]}else if(a.substr(0,3)==="hsl"){if(f=N=a.match(sc),!o)v=+f[0]%360/360,S=+f[1]/100,b=+f[2]/100,m=b<=.5?b*(S+1):b+S-b*S,u=b*2-m,f.length>3&&(f[3]*=1),f[0]=wc(v+1/3,u,m),f[1]=wc(v,u,m),f[2]=wc(v-1/3,u,m);else if(~a.indexOf("="))return f=a.match(Of),c&&f.length<4&&(f[3]=1),f}else f=a.match(sc)||Eh.transparent;f=f.map(Number)}return o&&!N&&(u=f[0]/Ki,m=f[1]/Ki,g=f[2]/Ki,O=Math.max(u,m,g),k=Math.min(u,m,g),b=(O+k)/2,O===k?v=S=0:(I=O-k,S=b>.5?I/(2-O-k):I/(O+k),v=O===u?(m-g)/I+(m<g?6:0):O===m?(g-u)/I+2:(u-m)/I+4,v*=60),f[0]=~~(v+.5),f[1]=~~(S*100+.5),f[2]=~~(b*100+.5)),c&&f.length<4&&(f[3]=1),f},ld=function(a){var o=[],c=[],f=-1;return a.split(Ks).forEach(function(u){var m=u.match(Rl)||[];o.push.apply(o,m),c.push(f+=m.length+1)}),o.c=c,o},hd=function(a,o,c){var f="",u=(a+f).match(Ks),m=o?"hsla(":"rgba(",g=0,v,S,b,O;if(!u)return a;if(u=u.map(function(k){return(k=ad(k,o,1))&&m+(o?k[0]+","+k[1]+"%,"+k[2]+"%,"+k[3]:k.join(","))+")"}),c&&(b=ld(a),v=c.c,v.join(f)!==b.c.join(f)))for(S=a.replace(Ks,"1").split(Rl),O=S.length-1;g<O;g++)f+=S[g]+(~v.indexOf(g)?u.shift()||m+"0,0,0,0)":(b.length?b:u.length?u:c).shift());if(!S)for(S=a.split(Ks),O=S.length-1;g<O;g++)f+=S[g]+u[g];return f+S[O]},Ks=function(){var x="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3,4}){1,2}\\b",a;for(a in Eh)x+="|"+a+"\\b";return new RegExp(x+")","gi")}(),Hm=/hsl[a]?\(/,ud=function(a){var o=a.join(" "),c;if(Ks.lastIndex=0,Ks.test(o))return c=Hm.test(o),a[1]=hd(a[1],c),a[0]=hd(a[0],c,ld(a[1])),!0},bh,Xr=function(){var x=Date.now,a=500,o=33,c=x(),f=c,u=1e3/240,m=u,g=[],v,S,b,O,k,I,N=function E(P){var w=x()-f,M=P===!0,R,C,U,F;if((w>a||w<0)&&(c+=w-o),f+=w,U=f-c,R=U-m,(R>0||M)&&(F=++O.frame,k=U-O.time*1e3,O.time=U=U/1e3,m+=R+(R>=u?4:u-R),C=1),M||(v=S(E)),C)for(I=0;I<g.length;I++)g[I](U,k,F,P)};return O={time:0,frame:0,tick:function(){N(!0)},deltaRatio:function(P){return k/(1e3/(P||60))},wake:function(){zf&&(!lc&&oc()&&(Wo=lc=window,hc=Wo.document||{},Vr.gsap=Pr,(Wo.gsapVersions||(Wo.gsapVersions=[])).push(Pr.version),kf(cu||Wo.GreenSockGlobals||!Wo.gsap&&Wo||{}),od.forEach(sd)),b=typeof requestAnimationFrame<"u"&&requestAnimationFrame,v&&O.sleep(),S=b||function(P){return setTimeout(P,m-O.time*1e3+1|0)},bh=1,N(2))},sleep:function(){(b?cancelAnimationFrame:clearTimeout)(v),bh=0,S=_h},lagSmoothing:function(P,w){a=P||1/0,o=Math.min(w||33,a)},fps:function(P){u=1e3/(P||240),m=O.time*1e3+u},add:function(P,w,M){var R=w?function(C,U,F,X){P(C,U,F,X),O.remove(R)}:P;return O.remove(P),g[M?"unshift":"push"](R),kl(),R},remove:function(P,w){~(w=g.indexOf(P))&&g.splice(w,1)&&I>=w&&I--},_listeners:g},O}(),kl=function(){return!bh&&Xr.wake()},Ii={},Vm=/^[\d.\-M][\d.\-,\s]/,Wm=/["']/g,jm=function(a){for(var o={},c=a.substr(1,a.length-3).split(":"),f=c[0],u=1,m=c.length,g,v,S;u<m;u++)v=c[u],g=u!==m-1?v.lastIndexOf(","):v.length,S=v.substr(0,g),o[f]=isNaN(S)?S.replace(Wm,"").trim():+S,f=v.substr(g+1).trim();return o},Xm=function(a){var o=a.indexOf("(")+1,c=a.indexOf(")"),f=a.indexOf("(",o);return a.substring(o,~f&&f<c?a.indexOf(")",c+1):c)},qm=function(a){var o=(a+"").split("("),c=Ii[o[0]];return c&&o.length>1&&c.config?c.config.apply(null,~a.indexOf("{")?[jm(o[1])]:Xm(a).split(",").map(Hf)):Ii._CE&&Vm.test(a)?Ii._CE("",a):c},cd=function(a){return function(o){return 1-a(1-o)}},fd=function x(a,o){for(var c=a._first,f;c;)c instanceof gr?x(c,o):c.vars.yoyoEase&&(!c._yoyo||!c._repeat)&&c._yoyo!==o&&(c.timeline?x(c.timeline,o):(f=c._ease,c._ease=c._yEase,c._yEase=f,c._yoyo=o)),c=c._next},Ga=function(a,o){return a&&(Tn(a)?a:Ii[a]||qm(a))||o},Ha=function(a,o,c,f){c===void 0&&(c=function(v){return 1-o(1-v)}),f===void 0&&(f=function(v){return v<.5?o(v*2)/2:1-o((1-v)*2)/2});var u={easeIn:o,easeOut:c,easeInOut:f},m;return Cr(a,function(g){Ii[g]=Vr[g]=u,Ii[m=g.toLowerCase()]=c;for(var v in u)Ii[m+(v==="easeIn"?".in":v==="easeOut"?".out":".inOut")]=Ii[g+"."+v]=u[v]}),u},dd=function(a){return function(o){return o<.5?(1-a(1-o*2))/2:.5+a((o-.5)*2)/2}},Tc=function x(a,o,c){var f=o>=1?o:1,u=(c||(a?.3:.45))/(o<1?o:1),m=u/nc*(Math.asin(1/f)||0),g=function(b){return b===1?1:f*Math.pow(2,-10*b)*wm((b-m)*u)+1},v=a==="out"?g:a==="in"?function(S){return 1-g(1-S)}:dd(g);return u=nc/u,v.config=function(S,b){return x(a,S,b)},v},Mc=function x(a,o){o===void 0&&(o=1.70158);var c=function(m){return m?--m*m*((o+1)*m+o)+1:0},f=a==="out"?c:a==="in"?function(u){return 1-c(1-u)}:dd(c);return f.config=function(u){return x(a,u)},f};Cr("Linear,Quad,Cubic,Quart,Quint,Strong",function(x,a){var o=a<5?a+1:a;Ha(x+",Power"+(o-1),a?function(c){return Math.pow(c,o)}:function(c){return c},function(c){return 1-Math.pow(1-c,o)},function(c){return c<.5?Math.pow(c*2,o)/2:1-Math.pow((1-c)*2,o)/2})}),Ii.Linear.easeNone=Ii.none=Ii.Linear.easeIn,Ha("Elastic",Tc("in"),Tc("out"),Tc()),function(x,a){var o=1/a,c=2*o,f=2.5*o,u=function(g){return g<o?x*g*g:g<c?x*Math.pow(g-1.5/a,2)+.75:g<f?x*(g-=2.25/a)*g+.9375:x*Math.pow(g-2.625/a,2)+.984375};Ha("Bounce",function(m){return 1-u(1-m)},u)}(7.5625,2.75),Ha("Expo",function(x){return x?Math.pow(2,10*(x-1)):0}),Ha("Circ",function(x){return-(Lf(1-x*x)-1)}),Ha("Sine",function(x){return x===1?1:-xm(x*ym)+1}),Ha("Back",Mc("in"),Mc("out"),Mc()),Ii.SteppedEase=Ii.steps=Vr.SteppedEase={config:function(a,o){a===void 0&&(a=1);var c=1/a,f=a+(o?0:1),u=o?1:0,m=1-en;return function(g){return((f*Th(0,m,g)|0)+u)*c}}},Ll.ease=Ii["quad.out"],Cr("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",function(x){return pc+=x+","+x+"Params,"});var pd=function(a,o){this.id=_m++,a._gsap=this,this.target=a,this.harness=o,this.get=o?o.get:Uf,this.set=o?o.getSetter:Ac},Ch=function(){function x(o){this.vars=o,this._delay=+o.delay||0,(this._repeat=o.repeat===1/0?-2:o.repeat||0)&&(this._rDelay=o.repeatDelay||0,this._yoyo=!!o.yoyo||!!o.yoyoEase),this._ts=1,Dl(this,+o.duration,1,1),this.data=o.data,hn&&(this._ctx=hn,hn.data.push(this)),bh||Xr.wake()}var a=x.prototype;return a.delay=function(c){return c||c===0?(this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+c-this._delay),this._delay=c,this):this._delay},a.duration=function(c){return arguments.length?this.totalDuration(this._repeat>0?c+(c+this._rDelay)*this._repeat:c):this.totalDuration()&&this._dur},a.totalDuration=function(c){return arguments.length?(this._dirty=0,Dl(this,this._repeat<0?c:(c-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},a.totalTime=function(c,f){if(kl(),!arguments.length)return this._tTime;var u=this._dp;if(u&&u.smoothChildTiming&&this._ts){for(_u(this,c),!u._dp||u.parent||qf(u,this);u&&u.parent;)u.parent._time!==u._start+(u._ts>=0?u._tTime/u._ts:(u.totalDuration()-u._tTime)/-u._ts)&&u.totalTime(u._tTime,!0),u=u.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&c<this._tDur||this._ts<0&&c>0||!this._tDur&&!c)&&jo(this._dp,this,this._start-this._delay)}return(this._tTime!==c||!this._dur&&!f||this._initted&&Math.abs(this._zTime)===en||!c&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=c),Gf(this,c,f)),this},a.time=function(c,f){return arguments.length?this.totalTime(Math.min(this.totalDuration(),c+Xf(this))%(this._dur+this._rDelay)||(c?this._dur:0),f):this._time},a.totalProgress=function(c,f){return arguments.length?this.totalTime(this.totalDuration()*c,f):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>0?1:0},a.progress=function(c,f){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&!(this.iteration()&1)?1-c:c)+Xf(this),f):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},a.iteration=function(c,f){var u=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(c-1)*u,f):this._repeat?Il(this._tTime,u)+1:1},a.timeScale=function(c,f){if(!arguments.length)return this._rts===-en?0:this._rts;if(this._rts===c)return this;var u=this.parent&&this._ts?vu(this.parent._time,this):this._tTime;return this._rts=+c||0,this._ts=this._ps||c===-en?0:this._rts,this.totalTime(Th(-Math.abs(this._delay),this._tDur,u),f!==!1),yu(this),Am(this)},a.paused=function(c){return arguments.length?(this._ps!==c&&(this._ps=c,c?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(kl(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,this.progress()===1&&Math.abs(this._zTime)!==en&&(this._tTime-=en)))),this):this._ps},a.startTime=function(c){if(arguments.length){this._start=c;var f=this.parent||this._dp;return f&&(f._sort||!this.parent)&&jo(f,this,c-this._delay),this}return this._start},a.endTime=function(c){return this._start+(br(c)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},a.rawTime=function(c){var f=this.parent||this._dp;return f?c&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?vu(f.rawTime(c),this):this._tTime:this._tTime},a.revert=function(c){c===void 0&&(c=Sm);var f=nr;return nr=c,(this._initted||this._startAt)&&(this.timeline&&this.timeline.revert(c),this.totalTime(-.01,c.suppressEvents)),this.data!=="nested"&&c.kill!==!1&&this.kill(),nr=f,this},a.globalTime=function(c){for(var f=this,u=arguments.length?c:f.rawTime();f;)u=f._start+u/(Math.abs(f._ts)||1),f=f._dp;return!this.parent&&this._sat?this._sat.globalTime(c):u},a.repeat=function(c){return arguments.length?(this._repeat=c===1/0?-2:c,Jf(this)):this._repeat===-2?1/0:this._repeat},a.repeatDelay=function(c){if(arguments.length){var f=this._time;return this._rDelay=c,Jf(this),f?this.time(f):this}return this._rDelay},a.yoyo=function(c){return arguments.length?(this._yoyo=c,this):this._yoyo},a.seek=function(c,f){return this.totalTime(oo(this,c),br(f))},a.restart=function(c,f){return this.play().totalTime(c?-this._delay:0,br(f))},a.play=function(c,f){return c!=null&&this.seek(c,f),this.reversed(!1).paused(!1)},a.reverse=function(c,f){return c!=null&&this.seek(c||this.totalDuration(),f),this.reversed(!0).paused(!1)},a.pause=function(c,f){return c!=null&&this.seek(c,f),this.paused(!0)},a.resume=function(){return this.paused(!1)},a.reversed=function(c){return arguments.length?(!!c!==this.reversed()&&this.timeScale(-this._rts||(c?-en:0)),this):this._rts<0},a.invalidate=function(){return this._initted=this._act=0,this._zTime=-en,this},a.isActive=function(){var c=this.parent||this._dp,f=this._start,u;return!!(!c||this._ts&&this._initted&&c.isActive()&&(u=c.rawTime(!0))>=f&&u<this.endTime(!0)-en)},a.eventCallback=function(c,f,u){var m=this.vars;return arguments.length>1?(f?(m[c]=f,u&&(m[c+"Params"]=u),c==="onUpdate"&&(this._onUpdate=f)):delete m[c],this):m[c]},a.then=function(c){var f=this;return new Promise(function(u){var m=Tn(c)?c:Vf,g=function(){var S=f.then;f.then=null,Tn(m)&&(m=m(f))&&(m.then||m===f)&&(f.then=S),u(m),f.then=S};f._initted&&f.totalProgress()===1&&f._ts>=0||!f._tTime&&f._ts<0?g():f._prom=g})},a.kill=function(){Sh(this)},x}();ro(Ch.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-en,_prom:0,_ps:!1,_rts:1});var gr=function(x){Pf(a,x);function a(c,f){var u;return c===void 0&&(c={}),u=x.call(this,c)||this,u.labels={},u.smoothChildTiming=!!c.smoothChildTiming,u.autoRemoveChildren=!!c.autoRemoveChildren,u._sort=br(c.sortChildren),dn&&jo(c.parent||dn,fs(u),f),c.reversed&&u.reverse(),c.paused&&u.paused(!0),c.scrollTrigger&&Yf(fs(u),c.scrollTrigger),u}var o=a.prototype;return o.to=function(f,u,m){return wh(0,arguments,this),this},o.from=function(f,u,m){return wh(1,arguments,this),this},o.fromTo=function(f,u,m,g){return wh(2,arguments,this),this},o.set=function(f,u,m){return u.duration=0,u.parent=this,xh(u).repeatDelay||(u.repeat=0),u.immediateRender=!!u.immediateRender,new kn(f,u,oo(this,m),1),this},o.call=function(f,u,m){return jo(this,kn.delayedCall(0,f,u),m)},o.staggerTo=function(f,u,m,g,v,S,b){return m.duration=u,m.stagger=m.stagger||g,m.onComplete=S,m.onCompleteParams=b,m.parent=this,new kn(f,m,oo(this,v)),this},o.staggerFrom=function(f,u,m,g,v,S,b){return m.runBackwards=1,xh(m).immediateRender=br(m.immediateRender),this.staggerTo(f,u,m,g,v,S,b)},o.staggerFromTo=function(f,u,m,g,v,S,b,O){return g.startAt=m,xh(g).immediateRender=br(g.immediateRender),this.staggerTo(f,u,g,v,S,b,O)},o.render=function(f,u,m){var g=this._time,v=this._dirty?this.totalDuration():this._tDur,S=this._dur,b=f<=0?0:jn(f),O=this._zTime<0!=f<0&&(this._initted||!S),k,I,N,E,P,w,M,R,C,U,F,X;if(this!==dn&&b>v&&f>=0&&(b=v),b!==this._tTime||m||O){if(g!==this._time&&S&&(b+=this._time-g,f+=this._time-g),k=b,C=this._start,R=this._ts,w=!R,O&&(S||(g=this._zTime),(f||!u)&&(this._zTime=f)),this._repeat){if(F=this._yoyo,P=S+this._rDelay,this._repeat<-1&&f<0)return this.totalTime(P*100+f,u,m);if(k=jn(b%P),b===v?(E=this._repeat,k=S):(E=~~(b/P),E&&E===b/P&&(k=S,E--),k>S&&(k=S)),U=Il(this._tTime,P),!g&&this._tTime&&U!==E&&this._tTime-U*P-this._dur<=0&&(U=E),F&&E&1&&(k=S-k,X=1),E!==U&&!this._lock){var K=F&&U&1,Z=K===(F&&E&1);if(E<U&&(K=!K),g=K?0:b%S?S:b,this._lock=1,this.render(g||(X?0:jn(E*P)),u,!S)._lock=0,this._tTime=b,!u&&this.parent&&jr(this,"onRepeat"),this.vars.repeatRefresh&&!X&&(this.invalidate()._lock=1),g&&g!==this._time||w!==!this._ts||this.vars.onRepeat&&!this.parent&&!this._act)return this;if(S=this._dur,v=this._tDur,Z&&(this._lock=2,g=K?S:-1e-4,this.render(g,!0),this.vars.repeatRefresh&&!X&&this.invalidate()),this._lock=0,!this._ts&&!w)return this;fd(this,X)}}if(this._hasPause&&!this._forcing&&this._lock<2&&(M=Om(this,jn(g),jn(k)),M&&(b-=k-(k=M._start))),this._tTime=b,this._time=k,this._act=!R,this._initted||(this._onUpdate=this.vars.onUpdate,this._initted=1,this._zTime=f,g=0),!g&&k&&!u&&!E&&(jr(this,"onStart"),this._tTime!==b))return this;if(k>=g&&f>=0)for(I=this._first;I;){if(N=I._next,(I._act||k>=I._start)&&I._ts&&M!==I){if(I.parent!==this)return this.render(f,u,m);if(I.render(I._ts>0?(k-I._start)*I._ts:(I._dirty?I.totalDuration():I._tDur)+(k-I._start)*I._ts,u,m),k!==this._time||!this._ts&&!w){M=0,N&&(b+=this._zTime=-en);break}}I=N}else{I=this._last;for(var ct=f<0?f:k;I;){if(N=I._prev,(I._act||ct<=I._end)&&I._ts&&M!==I){if(I.parent!==this)return this.render(f,u,m);if(I.render(I._ts>0?(ct-I._start)*I._ts:(I._dirty?I.totalDuration():I._tDur)+(ct-I._start)*I._ts,u,m||nr&&(I._initted||I._startAt)),k!==this._time||!this._ts&&!w){M=0,N&&(b+=this._zTime=ct?-en:en);break}}I=N}}if(M&&!u&&(this.pause(),M.render(k>=g?0:-en)._zTime=k>=g?1:-1,this._ts))return this._start=C,yu(this),this.render(f,u,m);this._onUpdate&&!u&&jr(this,"onUpdate",!0),(b===v&&this._tTime>=this.totalDuration()||!b&&g)&&(C===this._start||Math.abs(R)!==Math.abs(this._ts))&&(this._lock||((f||!S)&&(b===v&&this._ts>0||!b&&this._ts<0)&&Js(this,1),!u&&!(f<0&&!g)&&(b||g||!v)&&(jr(this,b===v&&f>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(b<v&&this.timeScale()>0)&&this._prom())))}return this},o.add=function(f,u){var m=this;if(ds(u)||(u=oo(this,u,f)),!(f instanceof Ch)){if(rr(f))return f.forEach(function(g){return m.add(g,u)}),this;if(Wn(f))return this.addLabel(f,u);if(Tn(f))f=kn.delayedCall(0,f);else return this}return this!==f?jo(this,f,u):this},o.getChildren=function(f,u,m,g){f===void 0&&(f=!0),u===void 0&&(u=!0),m===void 0&&(m=!0),g===void 0&&(g=-no);for(var v=[],S=this._first;S;)S._start>=g&&(S instanceof kn?u&&v.push(S):(m&&v.push(S),f&&v.push.apply(v,S.getChildren(!0,u,m)))),S=S._next;return v},o.getById=function(f){for(var u=this.getChildren(1,1,1),m=u.length;m--;)if(u[m].vars.id===f)return u[m]},o.remove=function(f){return Wn(f)?this.removeLabel(f):Tn(f)?this.killTweensOf(f):(gu(this,f),f===this._recent&&(this._recent=this._last),Ua(this))},o.totalTime=function(f,u){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=jn(Xr.time-(this._ts>0?f/this._ts:(this.totalDuration()-f)/-this._ts))),x.prototype.totalTime.call(this,f,u),this._forcing=0,this):this._tTime},o.addLabel=function(f,u){return this.labels[f]=oo(this,u),this},o.removeLabel=function(f){return delete this.labels[f],this},o.addPause=function(f,u,m){var g=kn.delayedCall(0,u||_h,m);return g.data="isPause",this._hasPause=1,jo(this,g,oo(this,f))},o.removePause=function(f){var u=this._first;for(f=oo(this,f);u;)u._start===f&&u.data==="isPause"&&Js(u),u=u._next},o.killTweensOf=function(f,u,m){for(var g=this.getTweensOf(f,m),v=g.length;v--;)Qs!==g[v]&&g[v].kill(f,u);return this},o.getTweensOf=function(f,u){for(var m=[],g=so(f),v=this._first,S=ds(u),b;v;)v instanceof kn?Em(v._targets,g)&&(S?(!Qs||v._initted&&v._ts)&&v.globalTime(0)<=u&&v.globalTime(v.totalDuration())>u:!u||v.isActive())&&m.push(v):(b=v.getTweensOf(g,u)).length&&m.push.apply(m,b),v=v._next;return m},o.tweenTo=function(f,u){u=u||{};var m=this,g=oo(m,f),v=u,S=v.startAt,b=v.onStart,O=v.onStartParams,k=v.immediateRender,I,N=kn.to(m,ro({ease:u.ease||"none",lazy:!1,immediateRender:!1,time:g,overwrite:"auto",duration:u.duration||Math.abs((g-(S&&"time"in S?S.time:m._time))/m.timeScale())||en,onStart:function(){if(m.pause(),!I){var P=u.duration||Math.abs((g-(S&&"time"in S?S.time:m._time))/m.timeScale());N._dur!==P&&Dl(N,P,0,1).render(N._time,!0,!0),I=1}b&&b.apply(N,O||[])}},u));return k?N.render(0):N},o.tweenFromTo=function(f,u,m){return this.tweenTo(u,ro({startAt:{time:oo(this,f)}},m))},o.recent=function(){return this._recent},o.nextLabel=function(f){return f===void 0&&(f=this._time),rd(this,oo(this,f))},o.previousLabel=function(f){return f===void 0&&(f=this._time),rd(this,oo(this,f),1)},o.currentLabel=function(f){return arguments.length?this.seek(f,!0):this.previousLabel(this._time+en)},o.shiftChildren=function(f,u,m){m===void 0&&(m=0);for(var g=this._first,v=this.labels,S;g;)g._start>=m&&(g._start+=f,g._end+=f),g=g._next;if(u)for(S in v)v[S]>=m&&(v[S]+=f);return Ua(this)},o.invalidate=function(f){var u=this._first;for(this._lock=0;u;)u.invalidate(f),u=u._next;return x.prototype.invalidate.call(this,f)},o.clear=function(f){f===void 0&&(f=!0);for(var u=this._first,m;u;)m=u._next,this.remove(u),u=m;return this._dp&&(this._time=this._tTime=this._pTime=0),f&&(this.labels={}),Ua(this)},o.totalDuration=function(f){var u=0,m=this,g=m._last,v=no,S,b,O;if(arguments.length)return m.timeScale((m._repeat<0?m.duration():m.totalDuration())/(m.reversed()?-f:f));if(m._dirty){for(O=m.parent;g;)S=g._prev,g._dirty&&g.totalDuration(),b=g._start,b>v&&m._sort&&g._ts&&!m._lock?(m._lock=1,jo(m,g,b-g._delay,1)._lock=0):v=b,b<0&&g._ts&&(u-=b,(!O&&!m._dp||O&&O.smoothChildTiming)&&(m._start+=b/m._ts,m._time-=b,m._tTime-=b),m.shiftChildren(-b,!1,-1/0),v=0),g._end>u&&g._ts&&(u=g._end),g=S;Dl(m,m===dn&&m._time>u?m._time:u,1,1),m._dirty=0}return m._tDur},a.updateRoot=function(f){if(dn._ts&&(Gf(dn,vu(f,dn)),Nf=Xr.frame),Xr.frame>=Ff){Ff+=Hr.autoSleep||120;var u=dn._first;if((!u||!u._ts)&&Hr.autoSleep&&Xr._listeners.length<2){for(;u&&!u._ts;)u=u._next;u||Xr.sleep()}}},a}(Ch);ro(gr.prototype,{_lock:0,_hasPause:0,_forcing:0});var Ym=function(a,o,c,f,u,m,g){var v=new Ar(this._pt,a,o,0,1,xd,null,u),S=0,b=0,O,k,I,N,E,P,w,M;for(v.b=c,v.e=f,c+="",f+="",(w=~f.indexOf("random("))&&(f=Mh(f)),m&&(M=[c,f],m(M,a,o),c=M[0],f=M[1]),k=c.match(ac)||[];O=ac.exec(f);)N=O[0],E=f.substring(S,O.index),I?I=(I+1)%5:E.substr(-5)==="rgba("&&(I=1),N!==k[b++]&&(P=parseFloat(k[b-1])||0,v._pt={_next:v._pt,p:E||b===1?E:",",s:P,c:N.charAt(1)==="="?Ol(P,N)-P:parseFloat(N)-P,m:I&&I<4?Math.round:0},S=ac.lastIndex);return v.c=S<f.length?f.substring(S,f.length):"",v.fp=g,(If.test(f)||w)&&(v.e=0),this._pt=v,v},Sc=function(a,o,c,f,u,m,g,v,S,b){Tn(f)&&(f=f(u||0,a,m));var O=a[o],k=c!=="get"?c:Tn(O)?S?a[o.indexOf("set")||!Tn(a["get"+o.substr(3)])?o:"get"+o.substr(3)](S):a[o]():O,I=Tn(O)?S?Qm:yd:Cc,N;if(Wn(f)&&(~f.indexOf("random(")&&(f=Mh(f)),f.charAt(1)==="="&&(N=Ol(k,f)+(or(k)||0),(N||N===0)&&(f=N))),!b||k!==f||Ec)return!isNaN(k*f)&&f!==""?(N=new Ar(this._pt,a,o,+k||0,f-(k||0),typeof O=="boolean"?eg:_d,0,I),S&&(N.fp=S),g&&N.modifier(g,this,a),this._pt=N):(!O&&!(o in a)&&uc(o,f),Ym.call(this,a,o,k,f,I,v||Hr.stringFilter,S))},Zm=function(a,o,c,f,u){if(Tn(a)&&(a=Ah(a,u,o,c,f)),!Vo(a)||a.style&&a.nodeType||rr(a)||Rf(a))return Wn(a)?Ah(a,u,o,c,f):a;var m={},g;for(g in a)m[g]=Ah(a[g],u,o,c,f);return m},md=function(a,o,c,f,u,m){var g,v,S,b;if(Wr[a]&&(g=new Wr[a]).init(u,g.rawVars?o[a]:Zm(o[a],f,u,m,c),c,f,m)!==!1&&(c._pt=v=new Ar(c._pt,u,a,0,1,g.render,g,0,g.priority),c!==zl))for(S=c._ptLookup[c._targets.indexOf(u)],b=g._props.length;b--;)S[g._props[b]]=v;return g},Qs,Ec,bc=function x(a,o,c){var f=a.vars,u=f.ease,m=f.startAt,g=f.immediateRender,v=f.lazy,S=f.onUpdate,b=f.runBackwards,O=f.yoyoEase,k=f.keyframes,I=f.autoRevert,N=a._dur,E=a._startAt,P=a._targets,w=a.parent,M=w&&w.data==="nested"?w.vars.targets:P,R=a._overwrite==="auto"&&!ic,C=a.timeline,U,F,X,K,Z,ct,Rt,tt,_t,G,Pt,Et,At;if(C&&(!k||!u)&&(u="none"),a._ease=Ga(u,Ll.ease),a._yEase=O?cd(Ga(O===!0?u:O,Ll.ease)):0,O&&a._yoyo&&!a._repeat&&(O=a._yEase,a._yEase=a._ease,a._ease=O),a._from=!C&&!!f.runBackwards,!C||k&&!f.stagger){if(tt=P[0]?Na(P[0]).harness:0,Et=tt&&f[tt.prop],U=mu(f,cc),E&&(E._zTime<0&&E.progress(1),o<0&&b&&g&&!I?E.render(-1,!0):E.revert(b&&N?fu:Mm),E._lazy=0),m){if(Js(a._startAt=kn.set(P,ro({data:"isStart",overwrite:!1,parent:w,immediateRender:!0,lazy:!E&&br(v),startAt:null,delay:0,onUpdate:S&&function(){return jr(a,"onUpdate")},stagger:0},m))),a._startAt._dp=0,a._startAt._sat=a,o<0&&(nr||!g&&!I)&&a._startAt.revert(fu),g&&N&&o<=0&&c<=0){o&&(a._zTime=o);return}}else if(b&&N&&!E){if(o&&(g=!1),X=ro({overwrite:!1,data:"isFromStart",lazy:g&&!E&&br(v),immediateRender:g,stagger:0,parent:w},U),Et&&(X[tt.prop]=Et),Js(a._startAt=kn.set(P,X)),a._startAt._dp=0,a._startAt._sat=a,o<0&&(nr?a._startAt.revert(fu):a._startAt.render(-1,!0)),a._zTime=o,!g)x(a._startAt,en,en);else if(!o)return}for(a._pt=a._ptCache=0,v=N&&br(v)||v&&!N,F=0;F<P.length;F++){if(Z=P[F],Rt=Z._gsap||mc(P)[F]._gsap,a._ptLookup[F]=G={},fc[Rt.id]&&Zs.length&&pu(),Pt=M===P?F:M.indexOf(Z),tt&&(_t=new tt).init(Z,Et||U,a,Pt,M)!==!1&&(a._pt=K=new Ar(a._pt,Z,_t.name,0,1,_t.render,_t,0,_t.priority),_t._props.forEach(function(ce){G[ce]=K}),_t.priority&&(ct=1)),!tt||Et)for(X in U)Wr[X]&&(_t=md(X,U,a,Pt,Z,M))?_t.priority&&(ct=1):G[X]=K=Sc.call(a,Z,X,"get",U[X],Pt,M,0,f.stringFilter);a._op&&a._op[F]&&a.kill(Z,a._op[F]),R&&a._pt&&(Qs=a,dn.killTweensOf(Z,G,a.globalTime(o)),At=!a.parent,Qs=0),a._pt&&v&&(fc[Rt.id]=1)}ct&&wd(a),a._onInit&&a._onInit(a)}a._onUpdate=S,a._initted=(!a._op||a._pt)&&!At,k&&o<=0&&C.render(no,!0,!0)},Jm=function(a,o,c,f,u,m,g,v){var S=(a._pt&&a._ptCache||(a._ptCache={}))[o],b,O,k,I;if(!S)for(S=a._ptCache[o]=[],k=a._ptLookup,I=a._targets.length;I--;){if(b=k[I][o],b&&b.d&&b.d._pt)for(b=b.d._pt;b&&b.p!==o&&b.fp!==o;)b=b._next;if(!b)return Ec=1,a.vars[o]="+=0",bc(a,g),Ec=0,v?yh(o+" not eligible for reset"):1;S.push(b)}for(I=S.length;I--;)O=S[I],b=O._pt||O,b.s=(f||f===0)&&!u?f:b.s+(f||0)+m*b.c,b.c=c-b.s,O.e&&(O.e=Rn(c)+or(O.e)),O.b&&(O.b=b.s+or(O.b))},$m=function(a,o){var c=a[0]?Na(a[0]).harness:0,f=c&&c.aliases,u,m,g,v;if(!f)return o;u=Fa({},o);for(m in f)if(m in u)for(v=f[m].split(","),g=v.length;g--;)u[v[g]]=u[m];return u},Km=function(a,o,c,f){var u=o.ease||f||"power1.inOut",m,g;if(rr(o))g=c[a]||(c[a]=[]),o.forEach(function(v,S){return g.push({t:S/(o.length-1)*100,v,e:u})});else for(m in o)g=c[m]||(c[m]=[]),m==="ease"||g.push({t:parseFloat(a),v:o[m],e:u})},Ah=function(a,o,c,f,u){return Tn(a)?a.call(o,c,f,u):Wn(a)&&~a.indexOf("random(")?Mh(a):a},gd=pc+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase,autoRevert",vd={};Cr(gd+",id,stagger,delay,duration,paused,scrollTrigger",function(x){return vd[x]=1});var kn=function(x){Pf(a,x);function a(c,f,u,m){var g;typeof f=="number"&&(u.duration=f,f=u,u=null),g=x.call(this,m?f:xh(f))||this;var v=g.vars,S=v.duration,b=v.delay,O=v.immediateRender,k=v.stagger,I=v.overwrite,N=v.keyframes,E=v.defaults,P=v.scrollTrigger,w=v.yoyoEase,M=f.parent||dn,R=(rr(c)||Rf(c)?ds(c[0]):"length"in f)?[c]:so(c),C,U,F,X,K,Z,ct,Rt;if(g._targets=R.length?mc(R):yh("GSAP target "+c+" not found. https://gsap.com",!Hr.nullTargetWarn)||[],g._ptLookup=[],g._overwrite=I,N||k||uu(S)||uu(b)){if(f=g.vars,C=g.timeline=new gr({data:"nested",defaults:E||{},targets:M&&M.data==="nested"?M.vars.targets:R}),C.kill(),C.parent=C._dp=fs(g),C._start=0,k||uu(S)||uu(b)){if(X=R.length,ct=k&&Qf(k),Vo(k))for(K in k)~gd.indexOf(K)&&(Rt||(Rt={}),Rt[K]=k[K]);for(U=0;U<X;U++)F=mu(f,vd),F.stagger=0,w&&(F.yoyoEase=w),Rt&&Fa(F,Rt),Z=R[U],F.duration=+Ah(S,fs(g),U,Z,R),F.delay=(+Ah(b,fs(g),U,Z,R)||0)-g._delay,!k&&X===1&&F.delay&&(g._delay=b=F.delay,g._start+=b,F.delay=0),C.to(Z,F,ct?ct(U,Z,R):0),C._ease=Ii.none;C.duration()?S=b=0:g.timeline=0}else if(N){xh(ro(C.vars.defaults,{ease:"none"})),C._ease=Ga(N.ease||f.ease||"none");var tt=0,_t,G,Pt;if(rr(N))N.forEach(function(Et){return C.to(R,Et,">")}),C.duration();else{F={};for(K in N)K==="ease"||K==="easeEach"||Km(K,N[K],F,N.easeEach);for(K in F)for(_t=F[K].sort(function(Et,At){return Et.t-At.t}),tt=0,U=0;U<_t.length;U++)G=_t[U],Pt={ease:G.e,duration:(G.t-(U?_t[U-1].t:0))/100*S},Pt[K]=G.v,C.to(R,Pt,tt),tt+=Pt.duration;C.duration()<S&&C.to({},{duration:S-C.duration()})}}S||g.duration(S=C.duration())}else g.timeline=0;return I===!0&&!ic&&(Qs=fs(g),dn.killTweensOf(R),Qs=0),jo(M,fs(g),u),f.reversed&&g.reverse(),f.paused&&g.paused(!0),(O||!S&&!N&&g._start===jn(M._time)&&br(O)&&Pm(fs(g))&&M.data!=="nested")&&(g._tTime=-en,g.render(Math.max(0,-b)||0)),P&&Yf(fs(g),P),g}var o=a.prototype;return o.render=function(f,u,m){var g=this._time,v=this._tDur,S=this._dur,b=f<0,O=f>v-en&&!b?v:f<en?0:f,k,I,N,E,P,w,M,R,C;if(!S)Rm(this,f,u,m);else if(O!==this._tTime||!f||m||!this._initted&&this._tTime||this._startAt&&this._zTime<0!==b){if(k=O,R=this.timeline,this._repeat){if(E=S+this._rDelay,this._repeat<-1&&b)return this.totalTime(E*100+f,u,m);if(k=jn(O%E),O===v?(N=this._repeat,k=S):(N=~~(O/E),N&&N===jn(O/E)&&(k=S,N--),k>S&&(k=S)),w=this._yoyo&&N&1,w&&(C=this._yEase,k=S-k),P=Il(this._tTime,E),k===g&&!m&&this._initted&&N===P)return this._tTime=O,this;N!==P&&(R&&this._yEase&&fd(R,w),this.vars.repeatRefresh&&!w&&!this._lock&&this._time!==E&&this._initted&&(this._lock=m=1,this.render(jn(E*N),!0).invalidate()._lock=0))}if(!this._initted){if(Zf(this,b?f:k,m,u,O))return this._tTime=0,this;if(g!==this._time&&!(m&&this.vars.repeatRefresh&&N!==P))return this;if(S!==this._dur)return this.render(f,u,m)}if(this._tTime=O,this._time=k,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=M=(C||this._ease)(k/S),this._from&&(this.ratio=M=1-M),k&&!g&&!u&&!N&&(jr(this,"onStart"),this._tTime!==O))return this;for(I=this._pt;I;)I.r(M,I.d),I=I._next;R&&R.render(f<0?f:R._dur*R._ease(k/this._dur),u,m)||this._startAt&&(this._zTime=f),this._onUpdate&&!u&&(b&&gc(this,f,u,m),jr(this,"onUpdate")),this._repeat&&N!==P&&this.vars.onRepeat&&!u&&this.parent&&jr(this,"onRepeat"),(O===this._tDur||!O)&&this._tTime===O&&(b&&!this._onUpdate&&gc(this,f,!0,!0),(f||!S)&&(O===this._tDur&&this._ts>0||!O&&this._ts<0)&&Js(this,1),!u&&!(b&&!g)&&(O||g||w)&&(jr(this,O===v?"onComplete":"onReverseComplete",!0),this._prom&&!(O<v&&this.timeScale()>0)&&this._prom()))}return this},o.targets=function(){return this._targets},o.invalidate=function(f){return(!f||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(f),x.prototype.invalidate.call(this,f)},o.resetTo=function(f,u,m,g,v){bh||Xr.wake(),this._ts||this.play();var S=Math.min(this._dur,(this._dp._time-this._start)*this._ts),b;return this._initted||bc(this,S),b=this._ease(S/this._dur),Jm(this,f,u,m,g,b,S,v)?this.resetTo(f,u,m,g,1):(_u(this,0),this.parent||jf(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},o.kill=function(f,u){if(u===void 0&&(u="all"),!f&&(!u||u==="all"))return this._lazy=this._pt=0,this.parent?Sh(this):this;if(this.timeline){var m=this.timeline.totalDuration();return this.timeline.killTweensOf(f,u,Qs&&Qs.vars.overwrite!==!0)._first||Sh(this),this.parent&&m!==this.timeline.totalDuration()&&Dl(this,this._dur*this.timeline._tDur/m,0,1),this}var g=this._targets,v=f?so(f):g,S=this._ptLookup,b=this._pt,O,k,I,N,E,P,w;if((!u||u==="all")&&Cm(g,v))return u==="all"&&(this._pt=0),Sh(this);for(O=this._op=this._op||[],u!=="all"&&(Wn(u)&&(E={},Cr(u,function(M){return E[M]=1}),u=E),u=$m(g,u)),w=g.length;w--;)if(~v.indexOf(g[w])){k=S[w],u==="all"?(O[w]=u,N=k,I={}):(I=O[w]=O[w]||{},N=u);for(E in N)P=k&&k[E],P&&((!("kill"in P.d)||P.d.kill(E)===!0)&&gu(this,P,"_pt"),delete k[E]),I!=="all"&&(I[E]=1)}return this._initted&&!this._pt&&b&&Sh(this),this},a.to=function(f,u){return new a(f,u,arguments[2])},a.from=function(f,u){return wh(1,arguments)},a.delayedCall=function(f,u,m,g){return new a(u,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:f,onComplete:u,onReverseComplete:u,onCompleteParams:m,onReverseCompleteParams:m,callbackScope:g})},a.fromTo=function(f,u,m){return wh(2,arguments)},a.set=function(f,u){return u.duration=0,u.repeatDelay||(u.repeat=0),new a(f,u)},a.killTweensOf=function(f,u,m){return dn.killTweensOf(f,u,m)},a}(Ch);ro(kn.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0}),Cr("staggerTo,staggerFrom,staggerFromTo",function(x){kn[x]=function(){var a=new gr,o=yc.call(arguments,0);return o.splice(x==="staggerFromTo"?5:4,0,0),a[x].apply(a,o)}});var Cc=function(a,o,c){return a[o]=c},yd=function(a,o,c){return a[o](c)},Qm=function(a,o,c,f){return a[o](f.fp,c)},tg=function(a,o,c){return a.setAttribute(o,c)},Ac=function(a,o){return Tn(a[o])?yd:rc(a[o])&&a.setAttribute?tg:Cc},_d=function(a,o){return o.set(o.t,o.p,Math.round((o.s+o.c*a)*1e6)/1e6,o)},eg=function(a,o){return o.set(o.t,o.p,!!(o.s+o.c*a),o)},xd=function(a,o){var c=o._pt,f="";if(!a&&o.b)f=o.b;else if(a===1&&o.e)f=o.e;else{for(;c;)f=c.p+(c.m?c.m(c.s+c.c*a):Math.round((c.s+c.c*a)*1e4)/1e4)+f,c=c._next;f+=o.c}o.set(o.t,o.p,f,o)},Pc=function(a,o){for(var c=o._pt;c;)c.r(a,c.d),c=c._next},ig=function(a,o,c,f){for(var u=this._pt,m;u;)m=u._next,u.p===f&&u.modifier(a,o,c),u=m},ng=function(a){for(var o=this._pt,c,f;o;)f=o._next,o.p===a&&!o.op||o.op===a?gu(this,o,"_pt"):o.dep||(c=1),o=f;return!c},rg=function(a,o,c,f){f.mSet(a,o,f.m.call(f.tween,c,f.mt),f)},wd=function(a){for(var o=a._pt,c,f,u,m;o;){for(c=o._next,f=u;f&&f.pr>o.pr;)f=f._next;(o._prev=f?f._prev:m)?o._prev._next=o:u=o,(o._next=f)?f._prev=o:m=o,o=c}a._pt=u},Ar=function(){function x(o,c,f,u,m,g,v,S,b){this.t=c,this.s=u,this.c=m,this.p=f,this.r=g||_d,this.d=v||this,this.set=S||Cc,this.pr=b||0,this._next=o,o&&(o._prev=this)}var a=x.prototype;return a.modifier=function(c,f,u){this.mSet=this.mSet||this.set,this.set=rg,this.m=c,this.mt=u,this.tween=f},x}();Cr(pc+"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(x){return cc[x]=1}),Vr.TweenMax=Vr.TweenLite=kn,Vr.TimelineLite=Vr.TimelineMax=gr,dn=new gr({sortChildren:!1,defaults:Ll,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0}),Hr.stringFilter=ud;var Va=[],xu={},og=[],Td=0,sg=0,Lc=function(a){return(xu[a]||og).map(function(o){return o()})},Rc=function(){var a=Date.now(),o=[];a-Td>2&&(Lc("matchMediaInit"),Va.forEach(function(c){var f=c.queries,u=c.conditions,m,g,v,S;for(g in f)m=Wo.matchMedia(f[g]).matches,m&&(v=1),m!==u[g]&&(u[g]=m,S=1);S&&(c.revert(),v&&o.push(c))}),Lc("matchMediaRevert"),o.forEach(function(c){return c.onMatch(c,function(f){return c.add(null,f)})}),Td=a,Lc("matchMedia"))},Md=function(){function x(o,c){this.selector=c&&_c(c),this.data=[],this._r=[],this.isReverted=!1,this.id=sg++,o&&this.add(o)}var a=x.prototype;return a.add=function(c,f,u){Tn(c)&&(u=f,f=c,c=Tn);var m=this,g=function(){var S=hn,b=m.selector,O;return S&&S!==m&&S.data.push(m),u&&(m.selector=_c(u)),hn=m,O=f.apply(m,arguments),Tn(O)&&m._r.push(O),hn=S,m.selector=b,m.isReverted=!1,O};return m.last=g,c===Tn?g(m,function(v){return m.add(null,v)}):c?m[c]=g:g},a.ignore=function(c){var f=hn;hn=null,c(this),hn=f},a.getTweens=function(){var c=[];return this.data.forEach(function(f){return f instanceof x?c.push.apply(c,f.getTweens()):f instanceof kn&&!(f.parent&&f.parent.data==="nested")&&c.push(f)}),c},a.clear=function(){this._r.length=this.data.length=0},a.kill=function(c,f){var u=this;if(c?function(){for(var g=u.getTweens(),v=u.data.length,S;v--;)S=u.data[v],S.data==="isFlip"&&(S.revert(),S.getChildren(!0,!0,!1).forEach(function(b){return g.splice(g.indexOf(b),1)}));for(g.map(function(b){return{g:b._dur||b._delay||b._sat&&!b._sat.vars.immediateRender?b.globalTime(0):-1/0,t:b}}).sort(function(b,O){return O.g-b.g||-1/0}).forEach(function(b){return b.t.revert(c)}),v=u.data.length;v--;)S=u.data[v],S instanceof gr?S.data!=="nested"&&(S.scrollTrigger&&S.scrollTrigger.revert(),S.kill()):!(S instanceof kn)&&S.revert&&S.revert(c);u._r.forEach(function(b){return b(c,u)}),u.isReverted=!0}():this.data.forEach(function(g){return g.kill&&g.kill()}),this.clear(),f)for(var m=Va.length;m--;)Va[m].id===this.id&&Va.splice(m,1)},a.revert=function(c){this.kill(c||{})},x}(),ag=function(){function x(o){this.contexts=[],this.scope=o,hn&&hn.data.push(this)}var a=x.prototype;return a.add=function(c,f,u){Vo(c)||(c={matches:c});var m=new Md(0,u||this.scope),g=m.conditions={},v,S,b;hn&&!m.selector&&(m.selector=hn.selector),this.contexts.push(m),f=m.add("onMatch",f),m.queries=c;for(S in c)S==="all"?b=1:(v=Wo.matchMedia(c[S]),v&&(Va.indexOf(m)<0&&Va.push(m),(g[S]=v.matches)&&(b=1),v.addListener?v.addListener(Rc):v.addEventListener("change",Rc)));return b&&f(m,function(O){return m.add(null,O)}),this},a.revert=function(c){this.kill(c||{})},a.kill=function(c){this.contexts.forEach(function(f){return f.kill(c,!0)})},x}(),wu={registerPlugin:function(){for(var a=arguments.length,o=new Array(a),c=0;c<a;c++)o[c]=arguments[c];o.forEach(function(f){return sd(f)})},timeline:function(a){return new gr(a)},getTweensOf:function(a,o){return dn.getTweensOf(a,o)},getProperty:function(a,o,c,f){Wn(a)&&(a=so(a)[0]);var u=Na(a||{}).get,m=c?Vf:Hf;return c==="native"&&(c=""),a&&(o?m((Wr[o]&&Wr[o].get||u)(a,o,c,f)):function(g,v,S){return m((Wr[g]&&Wr[g].get||u)(a,g,v,S))})},quickSetter:function(a,o,c){if(a=so(a),a.length>1){var f=a.map(function(b){return Pr.quickSetter(b,o,c)}),u=f.length;return function(b){for(var O=u;O--;)f[O](b)}}a=a[0]||{};var m=Wr[o],g=Na(a),v=g.harness&&(g.harness.aliases||{})[o]||o,S=m?function(b){var O=new m;zl._pt=0,O.init(a,c?b+c:b,zl,0,[a]),O.render(1,O),zl._pt&&Pc(1,zl)}:g.set(a,v);return m?S:function(b){return S(a,v,c?b+c:b,g,1)}},quickTo:function(a,o,c){var f,u=Pr.to(a,Fa((f={},f[o]="+=0.1",f.paused=!0,f),c||{})),m=function(v,S,b){return u.resetTo(o,v,S,b)};return m.tween=u,m},isTweening:function(a){return dn.getTweensOf(a,!0).length>0},defaults:function(a){return a&&a.ease&&(a.ease=Ga(a.ease,Ll.ease)),Wf(Ll,a||{})},config:function(a){return Wf(Hr,a||{})},registerEffect:function(a){var o=a.name,c=a.effect,f=a.plugins,u=a.defaults,m=a.extendTimeline;(f||"").split(",").forEach(function(g){return g&&!Wr[g]&&!Vr[g]&&yh(o+" effect requires "+g+" plugin.")}),dc[o]=function(g,v,S){return c(so(g),ro(v||{},u),S)},m&&(gr.prototype[o]=function(g,v,S){return this.add(dc[o](g,Vo(v)?v:(S=v)&&{},this),S)})},registerEase:function(a,o){Ii[a]=Ga(o)},parseEase:function(a,o){return arguments.length?Ga(a,o):Ii},getById:function(a){return dn.getById(a)},exportRoot:function(a,o){a===void 0&&(a={});var c=new gr(a),f,u;for(c.smoothChildTiming=br(a.smoothChildTiming),dn.remove(c),c._dp=0,c._time=c._tTime=dn._time,f=dn._first;f;)u=f._next,(o||!(!f._dur&&f instanceof kn&&f.vars.onComplete===f._targets[0]))&&jo(c,f,f._start-f._delay),f=u;return jo(dn,c,0),c},context:function(a,o){return a?new Md(a,o):hn},matchMedia:function(a){return new ag(a)},matchMediaRefresh:function(){return Va.forEach(function(a){var o=a.conditions,c,f;for(f in o)o[f]&&(o[f]=!1,c=1);c&&a.revert()})||Rc()},addEventListener:function(a,o){var c=xu[a]||(xu[a]=[]);~c.indexOf(o)||c.push(o)},removeEventListener:function(a,o){var c=xu[a],f=c&&c.indexOf(o);f>=0&&c.splice(f,1)},utils:{wrap:Fm,wrapYoyo:Um,distribute:Qf,random:ed,snap:td,normalize:Nm,getUnit:or,clamp:Dm,splitColor:ad,toArray:so,selector:_c,mapRange:nd,pipe:km,unitize:Bm,interpolate:Gm,shuffle:Kf},install:kf,effects:dc,ticker:Xr,updateRoot:gr.updateRoot,plugins:Wr,globalTimeline:dn,core:{PropTween:Ar,globals:Bf,Tween:kn,Timeline:gr,Animation:Ch,getCache:Na,_removeLinkedListItem:gu,reverting:function(){return nr},context:function(a){return a&&hn&&(hn.data.push(a),a._ctx=hn),hn},suppressOverwrites:function(a){return ic=a}}};Cr("to,from,fromTo,delayedCall,set,killTweensOf",function(x){return wu[x]=kn[x]}),Xr.add(gr.updateRoot),zl=wu.to({},{duration:0});var lg=function(a,o){for(var c=a._pt;c&&c.p!==o&&c.op!==o&&c.fp!==o;)c=c._next;return c},hg=function(a,o){var c=a._targets,f,u,m;for(f in o)for(u=c.length;u--;)m=a._ptLookup[u][f],m&&(m=m.d)&&(m._pt&&(m=lg(m,f)),m&&m.modifier&&m.modifier(o[f],a,c[u],f))},Oc=function(a,o){return{name:a,rawVars:1,init:function(f,u,m){m._onInit=function(g){var v,S;if(Wn(u)&&(v={},Cr(u,function(b){return v[b]=1}),u=v),o){v={};for(S in u)v[S]=o(u[S]);u=v}hg(g,u)}}}},Pr=wu.registerPlugin({name:"attr",init:function(a,o,c,f,u){var m,g,v;this.tween=c;for(m in o)v=a.getAttribute(m)||"",g=this.add(a,"setAttribute",(v||0)+"",o[m],f,u,0,0,m),g.op=m,g.b=v,this._props.push(m)},render:function(a,o){for(var c=o._pt;c;)nr?c.set(c.t,c.p,c.b,c):c.r(a,c.d),c=c._next}},{name:"endArray",init:function(a,o){for(var c=o.length;c--;)this.add(a,c,a[c]||0,o[c],0,0,0,0,0,1)}},Oc("roundProps",xc),Oc("modifiers"),Oc("snap",td))||wu;kn.version=gr.version=Pr.version="3.12.5",zf=1,oc()&&kl(),Ii.Power0,Ii.Power1,Ii.Power2,Ii.Power3,Ii.Power4,Ii.Linear,Ii.Quad,Ii.Cubic,Ii.Quart,Ii.Quint,Ii.Strong,Ii.Elastic,Ii.Back,Ii.SteppedEase,Ii.Bounce,Ii.Sine,Ii.Expo,Ii.Circ;/*!
|
|
2694
|
+
*/var Hr={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},Ll={duration:.5,overwrite:!1,delay:0},ic,nr,hn,no=1e8,en=1/no,nc=Math.PI*2,ym=nc/4,_m=0,Lf=Math.sqrt,xm=Math.cos,wm=Math.sin,Wn=function(a){return typeof a=="string"},Tn=function(a){return typeof a=="function"},ds=function(a){return typeof a=="number"},rc=function(a){return typeof a>"u"},Vo=function(a){return typeof a=="object"},br=function(a){return a!==!1},oc=function(){return typeof window<"u"},uu=function(a){return Tn(a)||Wn(a)},Rf=typeof ArrayBuffer=="function"&&ArrayBuffer.isView||function(){},rr=Array.isArray,sc=/(?:-?\.?\d|\.)+/gi,Of=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,Rl=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,ac=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,If=/[+-]=-?[.\d]+/,Df=/[^,'"\[\]\s]+/gi,Tm=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,dn,Wo,lc,hc,Vr={},cu={},zf,kf=function(a){return(cu=Fa(a,Vr))&&Pr},uc=function(a,o){},yh=function(a,o){return!o&&void 0},Bf=function(a,o){return a&&(Vr[a]=o)&&cu&&(cu[a]=o)||Vr},_h=function(){return 0},Mm={suppressEvents:!0,isStart:!0,kill:!1},fu={suppressEvents:!0,kill:!1},Sm={suppressEvents:!0},cc={},Zs=[],fc={},Nf,Wr={},dc={},Ff=30,du=[],pc="",mc=function(a){var o=a[0],c,f;if(Vo(o)||Tn(o)||(a=[a]),!(c=(o._gsap||{}).harness)){for(f=du.length;f--&&!du[f].targetTest(o););c=du[f]}for(f=a.length;f--;)a[f]&&(a[f]._gsap||(a[f]._gsap=new pd(a[f],c)))||a.splice(f,1);return a},Na=function(a){return a._gsap||mc(so(a))[0]._gsap},Uf=function(a,o,c){return(c=a[o])&&Tn(c)?a[o]():rc(c)&&a.getAttribute&&a.getAttribute(o)||c},Cr=function(a,o){return(a=a.split(",")).forEach(o)||a},Rn=function(a){return Math.round(a*1e5)/1e5||0},jn=function(a){return Math.round(a*1e7)/1e7||0},Ol=function(a,o){var c=o.charAt(0),f=parseFloat(o.substr(2));return a=parseFloat(a),c==="+"?a+f:c==="-"?a-f:c==="*"?a*f:a/f},Em=function(a,o){for(var c=o.length,f=0;a.indexOf(o[f])<0&&++f<c;);return f<c},pu=function(){var a=Zs.length,o=Zs.slice(0),c,f;for(fc={},Zs.length=0,c=0;c<a;c++)f=o[c],f&&f._lazy&&(f.render(f._lazy[0],f._lazy[1],!0)._lazy=0)},Gf=function(a,o,c,f){Zs.length&&!nr&&pu(),a.render(o,c,f||nr&&o<0&&(a._initted||a._startAt)),Zs.length&&!nr&&pu()},Hf=function(a){var o=parseFloat(a);return(o||o===0)&&(a+"").match(Df).length<2?o:Wn(a)?a.trim():a},Vf=function(a){return a},ro=function(a,o){for(var c in o)c in a||(a[c]=o[c]);return a},bm=function(a){return function(o,c){for(var f in c)f in o||f==="duration"&&a||f==="ease"||(o[f]=c[f])}},Fa=function(a,o){for(var c in o)a[c]=o[c];return a},Wf=function x(a,o){for(var c in o)c!=="__proto__"&&c!=="constructor"&&c!=="prototype"&&(a[c]=Vo(o[c])?x(a[c]||(a[c]={}),o[c]):o[c]);return a},mu=function(a,o){var c={},f;for(f in a)f in o||(c[f]=a[f]);return c},xh=function(a){var o=a.parent||dn,c=a.keyframes?bm(rr(a.keyframes)):ro;if(br(a.inherit))for(;o;)c(a,o.vars.defaults),o=o.parent||o._dp;return a},Cm=function(a,o){for(var c=a.length,f=c===o.length;f&&c--&&a[c]===o[c];);return c<0},jf=function(a,o,c,f,u){c===void 0&&(c="_first"),f===void 0&&(f="_last");var m=a[f],g;if(u)for(g=o[u];m&&m[u]>g;)m=m._prev;return m?(o._next=m._next,m._next=o):(o._next=a[c],a[c]=o),o._next?o._next._prev=o:a[f]=o,o._prev=m,o.parent=o._dp=a,o},gu=function(a,o,c,f){c===void 0&&(c="_first"),f===void 0&&(f="_last");var u=o._prev,m=o._next;u?u._next=m:a[c]===o&&(a[c]=m),m?m._prev=u:a[f]===o&&(a[f]=u),o._next=o._prev=o.parent=null},Js=function(a,o){a.parent&&(!o||a.parent.autoRemoveChildren)&&a.parent.remove&&a.parent.remove(a),a._act=0},Ua=function(a,o){if(a&&(!o||o._end>a._dur||o._start<0))for(var c=a;c;)c._dirty=1,c=c.parent;return a},Am=function(a){for(var o=a.parent;o&&o.parent;)o._dirty=1,o.totalDuration(),o=o.parent;return a},gc=function(a,o,c,f){return a._startAt&&(nr?a._startAt.revert(fu):a.vars.immediateRender&&!a.vars.autoRevert||a._startAt.render(o,!0,f))},Pm=function x(a){return!a||a._ts&&x(a.parent)},Xf=function(a){return a._repeat?Il(a._tTime,a=a.duration()+a._rDelay)*a:0},Il=function(a,o){var c=Math.floor(a/=o);return a&&c===a?c-1:c},vu=function(a,o){return(a-o._start)*o._ts+(o._ts>=0?0:o._dirty?o.totalDuration():o._tDur)},yu=function(a){return a._end=jn(a._start+(a._tDur/Math.abs(a._ts||a._rts||en)||0))},_u=function(a,o){var c=a._dp;return c&&c.smoothChildTiming&&a._ts&&(a._start=jn(c._time-(a._ts>0?o/a._ts:((a._dirty?a.totalDuration():a._tDur)-o)/-a._ts)),yu(a),c._dirty||Ua(c,a)),a},qf=function(a,o){var c;if((o._time||!o._dur&&o._initted||o._start<a._time&&(o._dur||!o.add))&&(c=vu(a.rawTime(),o),(!o._dur||Th(0,o.totalDuration(),c)-o._tTime>en)&&o.render(c,!0)),Ua(a,o)._dp&&a._initted&&a._time>=a._dur&&a._ts){if(a._dur<a.duration())for(c=a;c._dp;)c.rawTime()>=0&&c.totalTime(c._tTime),c=c._dp;a._zTime=-en}},jo=function(a,o,c,f){return o.parent&&Js(o),o._start=jn((ds(c)?c:c||a!==dn?oo(a,c,o):a._time)+o._delay),o._end=jn(o._start+(o.totalDuration()/Math.abs(o.timeScale())||0)),jf(a,o,"_first","_last",a._sort?"_start":0),vc(o)||(a._recent=o),f||qf(a,o),a._ts<0&&_u(a,a._tTime),a},Yf=function(a,o){return(Vr.ScrollTrigger||uc("scrollTrigger",o))&&Vr.ScrollTrigger.create(o,a)},Zf=function(a,o,c,f,u){if(bc(a,o,u),!a._initted)return 1;if(!c&&a._pt&&!nr&&(a._dur&&a.vars.lazy!==!1||!a._dur&&a.vars.lazy)&&Nf!==Xr.frame)return Zs.push(a),a._lazy=[u,f],1},Lm=function x(a){var o=a.parent;return o&&o._ts&&o._initted&&!o._lock&&(o.rawTime()<0||x(o))},vc=function(a){var o=a.data;return o==="isFromStart"||o==="isStart"},Rm=function(a,o,c,f){var u=a.ratio,m=o<0||!o&&(!a._start&&Lm(a)&&!(!a._initted&&vc(a))||(a._ts<0||a._dp._ts<0)&&!vc(a))?0:1,g=a._rDelay,v=0,S,b,O;if(g&&a._repeat&&(v=Th(0,a._tDur,o),b=Il(v,g),a._yoyo&&b&1&&(m=1-m),b!==Il(a._tTime,g)&&(u=1-m,a.vars.repeatRefresh&&a._initted&&a.invalidate())),m!==u||nr||f||a._zTime===en||!o&&a._zTime){if(!a._initted&&Zf(a,o,f,c,v))return;for(O=a._zTime,a._zTime=o||(c?en:0),c||(c=o&&!O),a.ratio=m,a._from&&(m=1-m),a._time=0,a._tTime=v,S=a._pt;S;)S.r(m,S.d),S=S._next;o<0&&gc(a,o,c,!0),a._onUpdate&&!c&&jr(a,"onUpdate"),v&&a._repeat&&!c&&a.parent&&jr(a,"onRepeat"),(o>=a._tDur||o<0)&&a.ratio===m&&(m&&Js(a,1),!c&&!nr&&(jr(a,m?"onComplete":"onReverseComplete",!0),a._prom&&a._prom()))}else a._zTime||(a._zTime=o)},Om=function(a,o,c){var f;if(c>o)for(f=a._first;f&&f._start<=c;){if(f.data==="isPause"&&f._start>o)return f;f=f._next}else for(f=a._last;f&&f._start>=c;){if(f.data==="isPause"&&f._start<o)return f;f=f._prev}},Dl=function(a,o,c,f){var u=a._repeat,m=jn(o)||0,g=a._tTime/a._tDur;return g&&!f&&(a._time*=m/a._dur),a._dur=m,a._tDur=u?u<0?1e10:jn(m*(u+1)+a._rDelay*u):m,g>0&&!f&&_u(a,a._tTime=a._tDur*g),a.parent&&yu(a),c||Ua(a.parent,a),a},Jf=function(a){return a instanceof gr?Ua(a):Dl(a,a._dur)},Im={_start:0,endTime:_h,totalDuration:_h},oo=function x(a,o,c){var f=a.labels,u=a._recent||Im,m=a.duration()>=no?u.endTime(!1):a._dur,g,v,S;return Wn(o)&&(isNaN(o)||o in f)?(v=o.charAt(0),S=o.substr(-1)==="%",g=o.indexOf("="),v==="<"||v===">"?(g>=0&&(o=o.replace(/=/,"")),(v==="<"?u._start:u.endTime(u._repeat>=0))+(parseFloat(o.substr(1))||0)*(S?(g<0?u:c).totalDuration()/100:1)):g<0?(o in f||(f[o]=m),f[o]):(v=parseFloat(o.charAt(g-1)+o.substr(g+1)),S&&c&&(v=v/100*(rr(c)?c[0]:c).totalDuration()),g>1?x(a,o.substr(0,g-1),c)+v:m+v)):o==null?m:+o},wh=function(a,o,c){var f=ds(o[1]),u=(f?2:1)+(a<2?0:1),m=o[u],g,v;if(f&&(m.duration=o[1]),m.parent=c,a){for(g=m,v=c;v&&!("immediateRender"in g);)g=v.vars.defaults||{},v=br(v.vars.inherit)&&v.parent;m.immediateRender=br(g.immediateRender),a<2?m.runBackwards=1:m.startAt=o[u-1]}return new kn(o[0],m,o[u+1])},$s=function(a,o){return a||a===0?o(a):o},Th=function(a,o,c){return c<a?a:c>o?o:c},or=function(a,o){return!Wn(a)||!(o=Tm.exec(a))?"":o[1]},Dm=function(a,o,c){return $s(c,function(f){return Th(a,o,f)})},yc=[].slice,$f=function(a,o){return a&&Vo(a)&&"length"in a&&(!o&&!a.length||a.length-1 in a&&Vo(a[0]))&&!a.nodeType&&a!==Wo},zm=function(a,o,c){return c===void 0&&(c=[]),a.forEach(function(f){var u;return Wn(f)&&!o||$f(f,1)?(u=c).push.apply(u,so(f)):c.push(f)})||c},so=function(a,o,c){return hn&&!o&&hn.selector?hn.selector(a):Wn(a)&&!c&&(lc||!kl())?yc.call((o||hc).querySelectorAll(a),0):rr(a)?zm(a,c):$f(a)?yc.call(a,0):a?[a]:[]},_c=function(a){return a=so(a)[0]||yh("Invalid scope")||{},function(o){var c=a.current||a.nativeElement||a;return so(o,c.querySelectorAll?c:c===a?yh("Invalid scope")||hc.createElement("div"):a)}},Kf=function(a){return a.sort(function(){return .5-Math.random()})},Qf=function(a){if(Tn(a))return a;var o=Vo(a)?a:{each:a},c=Ga(o.ease),f=o.from||0,u=parseFloat(o.base)||0,m={},g=f>0&&f<1,v=isNaN(f)||g,S=o.axis,b=f,O=f;return Wn(f)?b=O={center:.5,edges:.5,end:1}[f]||0:!g&&v&&(b=f[0],O=f[1]),function(k,I,F){var E=(F||o).length,P=m[E],w,M,R,C,U,N,X,J,Z;if(!P){if(Z=o.grid==="auto"?0:(o.grid||[1,no])[1],!Z){for(X=-no;X<(X=F[Z++].getBoundingClientRect().left)&&Z<E;);Z<E&&Z--}for(P=m[E]=[],w=v?Math.min(Z,E)*b-.5:f%Z,M=Z===no?0:v?E*O/Z-.5:f/Z|0,X=0,J=no,N=0;N<E;N++)R=N%Z-w,C=M-(N/Z|0),P[N]=U=S?Math.abs(S==="y"?C:R):Lf(R*R+C*C),U>X&&(X=U),U<J&&(J=U);f==="random"&&Kf(P),P.max=X-J,P.min=J,P.v=E=(parseFloat(o.amount)||parseFloat(o.each)*(Z>E?E-1:S?S==="y"?E/Z:Z:Math.max(Z,E/Z))||0)*(f==="edges"?-1:1),P.b=E<0?u-E:u,P.u=or(o.amount||o.each)||0,c=c&&E<0?cd(c):c}return E=(P[k]-P.min)/P.max||0,jn(P.b+(c?c(E):E)*P.v)+P.u}},xc=function(a){var o=Math.pow(10,((a+"").split(".")[1]||"").length);return function(c){var f=jn(Math.round(parseFloat(c)/a)*a*o);return(f-f%1)/o+(ds(c)?0:or(c))}},td=function(a,o){var c=rr(a),f,u;return!c&&Vo(a)&&(f=c=a.radius||no,a.values?(a=so(a.values),(u=!ds(a[0]))&&(f*=f)):a=xc(a.increment)),$s(o,c?Tn(a)?function(m){return u=a(m),Math.abs(u-m)<=f?u:m}:function(m){for(var g=parseFloat(u?m.x:m),v=parseFloat(u?m.y:0),S=no,b=0,O=a.length,k,I;O--;)u?(k=a[O].x-g,I=a[O].y-v,k=k*k+I*I):k=Math.abs(a[O]-g),k<S&&(S=k,b=O);return b=!f||S<=f?a[b]:m,u||b===m||ds(m)?b:b+or(m)}:xc(a))},ed=function(a,o,c,f){return $s(rr(a)?!o:c===!0?!!(c=0):!f,function(){return rr(a)?a[~~(Math.random()*a.length)]:(c=c||1e-5)&&(f=c<1?Math.pow(10,(c+"").length-2):1)&&Math.floor(Math.round((a-c/2+Math.random()*(o-a+c*.99))/c)*c*f)/f})},km=function(){for(var a=arguments.length,o=new Array(a),c=0;c<a;c++)o[c]=arguments[c];return function(f){return o.reduce(function(u,m){return m(u)},f)}},Bm=function(a,o){return function(c){return a(parseFloat(c))+(o||or(c))}},Nm=function(a,o,c){return nd(a,o,0,1,c)},id=function(a,o,c){return $s(c,function(f){return a[~~o(f)]})},Fm=function x(a,o,c){var f=o-a;return rr(a)?id(a,x(0,a.length),o):$s(c,function(u){return(f+(u-a)%f)%f+a})},Um=function x(a,o,c){var f=o-a,u=f*2;return rr(a)?id(a,x(0,a.length-1),o):$s(c,function(m){return m=(u+(m-a)%u)%u||0,a+(m>f?u-m:m)})},Mh=function(a){for(var o=0,c="",f,u,m,g;~(f=a.indexOf("random(",o));)m=a.indexOf(")",f),g=a.charAt(f+7)==="[",u=a.substr(f+7,m-f-7).match(g?Df:sc),c+=a.substr(o,f-o)+ed(g?u:+u[0],g?0:+u[1],+u[2]||1e-5),o=m+1;return c+a.substr(o,a.length-o)},nd=function(a,o,c,f,u){var m=o-a,g=f-c;return $s(u,function(v){return c+((v-a)/m*g||0)})},Gm=function x(a,o,c,f){var u=isNaN(a+o)?0:function(I){return(1-I)*a+I*o};if(!u){var m=Wn(a),g={},v,S,b,O,k;if(c===!0&&(f=1)&&(c=null),m)a={p:a},o={p:o};else if(rr(a)&&!rr(o)){for(b=[],O=a.length,k=O-2,S=1;S<O;S++)b.push(x(a[S-1],a[S]));O--,u=function(F){F*=O;var E=Math.min(k,~~F);return b[E](F-E)},c=o}else f||(a=Fa(rr(a)?[]:{},a));if(!b){for(v in o)Sc.call(g,a,v,"get",o[v]);u=function(F){return Pc(F,g)||(m?a.p:a)}}}return $s(c,u)},rd=function(a,o,c){var f=a.labels,u=no,m,g,v;for(m in f)g=f[m]-o,g<0==!!c&&g&&u>(g=Math.abs(g))&&(v=m,u=g);return v},jr=function(a,o,c){var f=a.vars,u=f[o],m=hn,g=a._ctx,v,S,b;if(u)return v=f[o+"Params"],S=f.callbackScope||a,c&&Zs.length&&pu(),g&&(hn=g),b=v?u.apply(S,v):u.call(S),hn=m,b},Sh=function(a){return Js(a),a.scrollTrigger&&a.scrollTrigger.kill(!!nr),a.progress()<1&&jr(a,"onInterrupt"),a},zl,od=[],sd=function(a){if(a)if(a=!a.name&&a.default||a,oc()||a.headless){var o=a.name,c=Tn(a),f=o&&!c&&a.init?function(){this._props=[]}:a,u={init:_h,render:Pc,add:Sc,kill:ng,modifier:ig,rawVars:0},m={targetTest:0,get:0,getSetter:Ac,aliases:{},register:0};if(kl(),a!==f){if(Wr[o])return;ro(f,ro(mu(a,u),m)),Fa(f.prototype,Fa(u,mu(a,m))),Wr[f.prop=o]=f,a.targetTest&&(du.push(f),cc[o]=1),o=(o==="css"?"CSS":o.charAt(0).toUpperCase()+o.substr(1))+"Plugin"}Bf(o,f),a.register&&a.register(Pr,f,Ar)}else od.push(a)},Ki=255,Eh={aqua:[0,Ki,Ki],lime:[0,Ki,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,Ki],navy:[0,0,128],white:[Ki,Ki,Ki],olive:[128,128,0],yellow:[Ki,Ki,0],orange:[Ki,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[Ki,0,0],pink:[Ki,192,203],cyan:[0,Ki,Ki],transparent:[Ki,Ki,Ki,0]},wc=function(a,o,c){return a+=a<0?1:a>1?-1:0,(a*6<1?o+(c-o)*a*6:a<.5?c:a*3<2?o+(c-o)*(2/3-a)*6:o)*Ki+.5|0},ad=function(a,o,c){var f=a?ds(a)?[a>>16,a>>8&Ki,a&Ki]:0:Eh.black,u,m,g,v,S,b,O,k,I,F;if(!f){if(a.substr(-1)===","&&(a=a.substr(0,a.length-1)),Eh[a])f=Eh[a];else if(a.charAt(0)==="#"){if(a.length<6&&(u=a.charAt(1),m=a.charAt(2),g=a.charAt(3),a="#"+u+u+m+m+g+g+(a.length===5?a.charAt(4)+a.charAt(4):"")),a.length===9)return f=parseInt(a.substr(1,6),16),[f>>16,f>>8&Ki,f&Ki,parseInt(a.substr(7),16)/255];a=parseInt(a.substr(1),16),f=[a>>16,a>>8&Ki,a&Ki]}else if(a.substr(0,3)==="hsl"){if(f=F=a.match(sc),!o)v=+f[0]%360/360,S=+f[1]/100,b=+f[2]/100,m=b<=.5?b*(S+1):b+S-b*S,u=b*2-m,f.length>3&&(f[3]*=1),f[0]=wc(v+1/3,u,m),f[1]=wc(v,u,m),f[2]=wc(v-1/3,u,m);else if(~a.indexOf("="))return f=a.match(Of),c&&f.length<4&&(f[3]=1),f}else f=a.match(sc)||Eh.transparent;f=f.map(Number)}return o&&!F&&(u=f[0]/Ki,m=f[1]/Ki,g=f[2]/Ki,O=Math.max(u,m,g),k=Math.min(u,m,g),b=(O+k)/2,O===k?v=S=0:(I=O-k,S=b>.5?I/(2-O-k):I/(O+k),v=O===u?(m-g)/I+(m<g?6:0):O===m?(g-u)/I+2:(u-m)/I+4,v*=60),f[0]=~~(v+.5),f[1]=~~(S*100+.5),f[2]=~~(b*100+.5)),c&&f.length<4&&(f[3]=1),f},ld=function(a){var o=[],c=[],f=-1;return a.split(Ks).forEach(function(u){var m=u.match(Rl)||[];o.push.apply(o,m),c.push(f+=m.length+1)}),o.c=c,o},hd=function(a,o,c){var f="",u=(a+f).match(Ks),m=o?"hsla(":"rgba(",g=0,v,S,b,O;if(!u)return a;if(u=u.map(function(k){return(k=ad(k,o,1))&&m+(o?k[0]+","+k[1]+"%,"+k[2]+"%,"+k[3]:k.join(","))+")"}),c&&(b=ld(a),v=c.c,v.join(f)!==b.c.join(f)))for(S=a.replace(Ks,"1").split(Rl),O=S.length-1;g<O;g++)f+=S[g]+(~v.indexOf(g)?u.shift()||m+"0,0,0,0)":(b.length?b:u.length?u:c).shift());if(!S)for(S=a.split(Ks),O=S.length-1;g<O;g++)f+=S[g]+u[g];return f+S[O]},Ks=function(){var x="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3,4}){1,2}\\b",a;for(a in Eh)x+="|"+a+"\\b";return new RegExp(x+")","gi")}(),Hm=/hsl[a]?\(/,ud=function(a){var o=a.join(" "),c;if(Ks.lastIndex=0,Ks.test(o))return c=Hm.test(o),a[1]=hd(a[1],c),a[0]=hd(a[0],c,ld(a[1])),!0},bh,Xr=function(){var x=Date.now,a=500,o=33,c=x(),f=c,u=1e3/240,m=u,g=[],v,S,b,O,k,I,F=function E(P){var w=x()-f,M=P===!0,R,C,U,N;if((w>a||w<0)&&(c+=w-o),f+=w,U=f-c,R=U-m,(R>0||M)&&(N=++O.frame,k=U-O.time*1e3,O.time=U=U/1e3,m+=R+(R>=u?4:u-R),C=1),M||(v=S(E)),C)for(I=0;I<g.length;I++)g[I](U,k,N,P)};return O={time:0,frame:0,tick:function(){F(!0)},deltaRatio:function(P){return k/(1e3/(P||60))},wake:function(){zf&&(!lc&&oc()&&(Wo=lc=window,hc=Wo.document||{},Vr.gsap=Pr,(Wo.gsapVersions||(Wo.gsapVersions=[])).push(Pr.version),kf(cu||Wo.GreenSockGlobals||!Wo.gsap&&Wo||{}),od.forEach(sd)),b=typeof requestAnimationFrame<"u"&&requestAnimationFrame,v&&O.sleep(),S=b||function(P){return setTimeout(P,m-O.time*1e3+1|0)},bh=1,F(2))},sleep:function(){(b?cancelAnimationFrame:clearTimeout)(v),bh=0,S=_h},lagSmoothing:function(P,w){a=P||1/0,o=Math.min(w||33,a)},fps:function(P){u=1e3/(P||240),m=O.time*1e3+u},add:function(P,w,M){var R=w?function(C,U,N,X){P(C,U,N,X),O.remove(R)}:P;return O.remove(P),g[M?"unshift":"push"](R),kl(),R},remove:function(P,w){~(w=g.indexOf(P))&&g.splice(w,1)&&I>=w&&I--},_listeners:g},O}(),kl=function(){return!bh&&Xr.wake()},Ii={},Vm=/^[\d.\-M][\d.\-,\s]/,Wm=/["']/g,jm=function(a){for(var o={},c=a.substr(1,a.length-3).split(":"),f=c[0],u=1,m=c.length,g,v,S;u<m;u++)v=c[u],g=u!==m-1?v.lastIndexOf(","):v.length,S=v.substr(0,g),o[f]=isNaN(S)?S.replace(Wm,"").trim():+S,f=v.substr(g+1).trim();return o},Xm=function(a){var o=a.indexOf("(")+1,c=a.indexOf(")"),f=a.indexOf("(",o);return a.substring(o,~f&&f<c?a.indexOf(")",c+1):c)},qm=function(a){var o=(a+"").split("("),c=Ii[o[0]];return c&&o.length>1&&c.config?c.config.apply(null,~a.indexOf("{")?[jm(o[1])]:Xm(a).split(",").map(Hf)):Ii._CE&&Vm.test(a)?Ii._CE("",a):c},cd=function(a){return function(o){return 1-a(1-o)}},fd=function x(a,o){for(var c=a._first,f;c;)c instanceof gr?x(c,o):c.vars.yoyoEase&&(!c._yoyo||!c._repeat)&&c._yoyo!==o&&(c.timeline?x(c.timeline,o):(f=c._ease,c._ease=c._yEase,c._yEase=f,c._yoyo=o)),c=c._next},Ga=function(a,o){return a&&(Tn(a)?a:Ii[a]||qm(a))||o},Ha=function(a,o,c,f){c===void 0&&(c=function(v){return 1-o(1-v)}),f===void 0&&(f=function(v){return v<.5?o(v*2)/2:1-o((1-v)*2)/2});var u={easeIn:o,easeOut:c,easeInOut:f},m;return Cr(a,function(g){Ii[g]=Vr[g]=u,Ii[m=g.toLowerCase()]=c;for(var v in u)Ii[m+(v==="easeIn"?".in":v==="easeOut"?".out":".inOut")]=Ii[g+"."+v]=u[v]}),u},dd=function(a){return function(o){return o<.5?(1-a(1-o*2))/2:.5+a((o-.5)*2)/2}},Tc=function x(a,o,c){var f=o>=1?o:1,u=(c||(a?.3:.45))/(o<1?o:1),m=u/nc*(Math.asin(1/f)||0),g=function(b){return b===1?1:f*Math.pow(2,-10*b)*wm((b-m)*u)+1},v=a==="out"?g:a==="in"?function(S){return 1-g(1-S)}:dd(g);return u=nc/u,v.config=function(S,b){return x(a,S,b)},v},Mc=function x(a,o){o===void 0&&(o=1.70158);var c=function(m){return m?--m*m*((o+1)*m+o)+1:0},f=a==="out"?c:a==="in"?function(u){return 1-c(1-u)}:dd(c);return f.config=function(u){return x(a,u)},f};Cr("Linear,Quad,Cubic,Quart,Quint,Strong",function(x,a){var o=a<5?a+1:a;Ha(x+",Power"+(o-1),a?function(c){return Math.pow(c,o)}:function(c){return c},function(c){return 1-Math.pow(1-c,o)},function(c){return c<.5?Math.pow(c*2,o)/2:1-Math.pow((1-c)*2,o)/2})}),Ii.Linear.easeNone=Ii.none=Ii.Linear.easeIn,Ha("Elastic",Tc("in"),Tc("out"),Tc()),function(x,a){var o=1/a,c=2*o,f=2.5*o,u=function(g){return g<o?x*g*g:g<c?x*Math.pow(g-1.5/a,2)+.75:g<f?x*(g-=2.25/a)*g+.9375:x*Math.pow(g-2.625/a,2)+.984375};Ha("Bounce",function(m){return 1-u(1-m)},u)}(7.5625,2.75),Ha("Expo",function(x){return x?Math.pow(2,10*(x-1)):0}),Ha("Circ",function(x){return-(Lf(1-x*x)-1)}),Ha("Sine",function(x){return x===1?1:-xm(x*ym)+1}),Ha("Back",Mc("in"),Mc("out"),Mc()),Ii.SteppedEase=Ii.steps=Vr.SteppedEase={config:function(a,o){a===void 0&&(a=1);var c=1/a,f=a+(o?0:1),u=o?1:0,m=1-en;return function(g){return((f*Th(0,m,g)|0)+u)*c}}},Ll.ease=Ii["quad.out"],Cr("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",function(x){return pc+=x+","+x+"Params,"});var pd=function(a,o){this.id=_m++,a._gsap=this,this.target=a,this.harness=o,this.get=o?o.get:Uf,this.set=o?o.getSetter:Ac},Ch=function(){function x(o){this.vars=o,this._delay=+o.delay||0,(this._repeat=o.repeat===1/0?-2:o.repeat||0)&&(this._rDelay=o.repeatDelay||0,this._yoyo=!!o.yoyo||!!o.yoyoEase),this._ts=1,Dl(this,+o.duration,1,1),this.data=o.data,hn&&(this._ctx=hn,hn.data.push(this)),bh||Xr.wake()}var a=x.prototype;return a.delay=function(c){return c||c===0?(this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+c-this._delay),this._delay=c,this):this._delay},a.duration=function(c){return arguments.length?this.totalDuration(this._repeat>0?c+(c+this._rDelay)*this._repeat:c):this.totalDuration()&&this._dur},a.totalDuration=function(c){return arguments.length?(this._dirty=0,Dl(this,this._repeat<0?c:(c-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},a.totalTime=function(c,f){if(kl(),!arguments.length)return this._tTime;var u=this._dp;if(u&&u.smoothChildTiming&&this._ts){for(_u(this,c),!u._dp||u.parent||qf(u,this);u&&u.parent;)u.parent._time!==u._start+(u._ts>=0?u._tTime/u._ts:(u.totalDuration()-u._tTime)/-u._ts)&&u.totalTime(u._tTime,!0),u=u.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&c<this._tDur||this._ts<0&&c>0||!this._tDur&&!c)&&jo(this._dp,this,this._start-this._delay)}return(this._tTime!==c||!this._dur&&!f||this._initted&&Math.abs(this._zTime)===en||!c&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=c),Gf(this,c,f)),this},a.time=function(c,f){return arguments.length?this.totalTime(Math.min(this.totalDuration(),c+Xf(this))%(this._dur+this._rDelay)||(c?this._dur:0),f):this._time},a.totalProgress=function(c,f){return arguments.length?this.totalTime(this.totalDuration()*c,f):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>0?1:0},a.progress=function(c,f){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&!(this.iteration()&1)?1-c:c)+Xf(this),f):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},a.iteration=function(c,f){var u=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(c-1)*u,f):this._repeat?Il(this._tTime,u)+1:1},a.timeScale=function(c,f){if(!arguments.length)return this._rts===-en?0:this._rts;if(this._rts===c)return this;var u=this.parent&&this._ts?vu(this.parent._time,this):this._tTime;return this._rts=+c||0,this._ts=this._ps||c===-en?0:this._rts,this.totalTime(Th(-Math.abs(this._delay),this._tDur,u),f!==!1),yu(this),Am(this)},a.paused=function(c){return arguments.length?(this._ps!==c&&(this._ps=c,c?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(kl(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,this.progress()===1&&Math.abs(this._zTime)!==en&&(this._tTime-=en)))),this):this._ps},a.startTime=function(c){if(arguments.length){this._start=c;var f=this.parent||this._dp;return f&&(f._sort||!this.parent)&&jo(f,this,c-this._delay),this}return this._start},a.endTime=function(c){return this._start+(br(c)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},a.rawTime=function(c){var f=this.parent||this._dp;return f?c&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?vu(f.rawTime(c),this):this._tTime:this._tTime},a.revert=function(c){c===void 0&&(c=Sm);var f=nr;return nr=c,(this._initted||this._startAt)&&(this.timeline&&this.timeline.revert(c),this.totalTime(-.01,c.suppressEvents)),this.data!=="nested"&&c.kill!==!1&&this.kill(),nr=f,this},a.globalTime=function(c){for(var f=this,u=arguments.length?c:f.rawTime();f;)u=f._start+u/(Math.abs(f._ts)||1),f=f._dp;return!this.parent&&this._sat?this._sat.globalTime(c):u},a.repeat=function(c){return arguments.length?(this._repeat=c===1/0?-2:c,Jf(this)):this._repeat===-2?1/0:this._repeat},a.repeatDelay=function(c){if(arguments.length){var f=this._time;return this._rDelay=c,Jf(this),f?this.time(f):this}return this._rDelay},a.yoyo=function(c){return arguments.length?(this._yoyo=c,this):this._yoyo},a.seek=function(c,f){return this.totalTime(oo(this,c),br(f))},a.restart=function(c,f){return this.play().totalTime(c?-this._delay:0,br(f))},a.play=function(c,f){return c!=null&&this.seek(c,f),this.reversed(!1).paused(!1)},a.reverse=function(c,f){return c!=null&&this.seek(c||this.totalDuration(),f),this.reversed(!0).paused(!1)},a.pause=function(c,f){return c!=null&&this.seek(c,f),this.paused(!0)},a.resume=function(){return this.paused(!1)},a.reversed=function(c){return arguments.length?(!!c!==this.reversed()&&this.timeScale(-this._rts||(c?-en:0)),this):this._rts<0},a.invalidate=function(){return this._initted=this._act=0,this._zTime=-en,this},a.isActive=function(){var c=this.parent||this._dp,f=this._start,u;return!!(!c||this._ts&&this._initted&&c.isActive()&&(u=c.rawTime(!0))>=f&&u<this.endTime(!0)-en)},a.eventCallback=function(c,f,u){var m=this.vars;return arguments.length>1?(f?(m[c]=f,u&&(m[c+"Params"]=u),c==="onUpdate"&&(this._onUpdate=f)):delete m[c],this):m[c]},a.then=function(c){var f=this;return new Promise(function(u){var m=Tn(c)?c:Vf,g=function(){var S=f.then;f.then=null,Tn(m)&&(m=m(f))&&(m.then||m===f)&&(f.then=S),u(m),f.then=S};f._initted&&f.totalProgress()===1&&f._ts>=0||!f._tTime&&f._ts<0?g():f._prom=g})},a.kill=function(){Sh(this)},x}();ro(Ch.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-en,_prom:0,_ps:!1,_rts:1});var gr=function(x){Pf(a,x);function a(c,f){var u;return c===void 0&&(c={}),u=x.call(this,c)||this,u.labels={},u.smoothChildTiming=!!c.smoothChildTiming,u.autoRemoveChildren=!!c.autoRemoveChildren,u._sort=br(c.sortChildren),dn&&jo(c.parent||dn,fs(u),f),c.reversed&&u.reverse(),c.paused&&u.paused(!0),c.scrollTrigger&&Yf(fs(u),c.scrollTrigger),u}var o=a.prototype;return o.to=function(f,u,m){return wh(0,arguments,this),this},o.from=function(f,u,m){return wh(1,arguments,this),this},o.fromTo=function(f,u,m,g){return wh(2,arguments,this),this},o.set=function(f,u,m){return u.duration=0,u.parent=this,xh(u).repeatDelay||(u.repeat=0),u.immediateRender=!!u.immediateRender,new kn(f,u,oo(this,m),1),this},o.call=function(f,u,m){return jo(this,kn.delayedCall(0,f,u),m)},o.staggerTo=function(f,u,m,g,v,S,b){return m.duration=u,m.stagger=m.stagger||g,m.onComplete=S,m.onCompleteParams=b,m.parent=this,new kn(f,m,oo(this,v)),this},o.staggerFrom=function(f,u,m,g,v,S,b){return m.runBackwards=1,xh(m).immediateRender=br(m.immediateRender),this.staggerTo(f,u,m,g,v,S,b)},o.staggerFromTo=function(f,u,m,g,v,S,b,O){return g.startAt=m,xh(g).immediateRender=br(g.immediateRender),this.staggerTo(f,u,g,v,S,b,O)},o.render=function(f,u,m){var g=this._time,v=this._dirty?this.totalDuration():this._tDur,S=this._dur,b=f<=0?0:jn(f),O=this._zTime<0!=f<0&&(this._initted||!S),k,I,F,E,P,w,M,R,C,U,N,X;if(this!==dn&&b>v&&f>=0&&(b=v),b!==this._tTime||m||O){if(g!==this._time&&S&&(b+=this._time-g,f+=this._time-g),k=b,C=this._start,R=this._ts,w=!R,O&&(S||(g=this._zTime),(f||!u)&&(this._zTime=f)),this._repeat){if(N=this._yoyo,P=S+this._rDelay,this._repeat<-1&&f<0)return this.totalTime(P*100+f,u,m);if(k=jn(b%P),b===v?(E=this._repeat,k=S):(E=~~(b/P),E&&E===b/P&&(k=S,E--),k>S&&(k=S)),U=Il(this._tTime,P),!g&&this._tTime&&U!==E&&this._tTime-U*P-this._dur<=0&&(U=E),N&&E&1&&(k=S-k,X=1),E!==U&&!this._lock){var J=N&&U&1,Z=J===(N&&E&1);if(E<U&&(J=!J),g=J?0:b%S?S:b,this._lock=1,this.render(g||(X?0:jn(E*P)),u,!S)._lock=0,this._tTime=b,!u&&this.parent&&jr(this,"onRepeat"),this.vars.repeatRefresh&&!X&&(this.invalidate()._lock=1),g&&g!==this._time||w!==!this._ts||this.vars.onRepeat&&!this.parent&&!this._act)return this;if(S=this._dur,v=this._tDur,Z&&(this._lock=2,g=J?S:-1e-4,this.render(g,!0),this.vars.repeatRefresh&&!X&&this.invalidate()),this._lock=0,!this._ts&&!w)return this;fd(this,X)}}if(this._hasPause&&!this._forcing&&this._lock<2&&(M=Om(this,jn(g),jn(k)),M&&(b-=k-(k=M._start))),this._tTime=b,this._time=k,this._act=!R,this._initted||(this._onUpdate=this.vars.onUpdate,this._initted=1,this._zTime=f,g=0),!g&&k&&!u&&!E&&(jr(this,"onStart"),this._tTime!==b))return this;if(k>=g&&f>=0)for(I=this._first;I;){if(F=I._next,(I._act||k>=I._start)&&I._ts&&M!==I){if(I.parent!==this)return this.render(f,u,m);if(I.render(I._ts>0?(k-I._start)*I._ts:(I._dirty?I.totalDuration():I._tDur)+(k-I._start)*I._ts,u,m),k!==this._time||!this._ts&&!w){M=0,F&&(b+=this._zTime=-en);break}}I=F}else{I=this._last;for(var ct=f<0?f:k;I;){if(F=I._prev,(I._act||ct<=I._end)&&I._ts&&M!==I){if(I.parent!==this)return this.render(f,u,m);if(I.render(I._ts>0?(ct-I._start)*I._ts:(I._dirty?I.totalDuration():I._tDur)+(ct-I._start)*I._ts,u,m||nr&&(I._initted||I._startAt)),k!==this._time||!this._ts&&!w){M=0,F&&(b+=this._zTime=ct?-en:en);break}}I=F}}if(M&&!u&&(this.pause(),M.render(k>=g?0:-en)._zTime=k>=g?1:-1,this._ts))return this._start=C,yu(this),this.render(f,u,m);this._onUpdate&&!u&&jr(this,"onUpdate",!0),(b===v&&this._tTime>=this.totalDuration()||!b&&g)&&(C===this._start||Math.abs(R)!==Math.abs(this._ts))&&(this._lock||((f||!S)&&(b===v&&this._ts>0||!b&&this._ts<0)&&Js(this,1),!u&&!(f<0&&!g)&&(b||g||!v)&&(jr(this,b===v&&f>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(b<v&&this.timeScale()>0)&&this._prom())))}return this},o.add=function(f,u){var m=this;if(ds(u)||(u=oo(this,u,f)),!(f instanceof Ch)){if(rr(f))return f.forEach(function(g){return m.add(g,u)}),this;if(Wn(f))return this.addLabel(f,u);if(Tn(f))f=kn.delayedCall(0,f);else return this}return this!==f?jo(this,f,u):this},o.getChildren=function(f,u,m,g){f===void 0&&(f=!0),u===void 0&&(u=!0),m===void 0&&(m=!0),g===void 0&&(g=-no);for(var v=[],S=this._first;S;)S._start>=g&&(S instanceof kn?u&&v.push(S):(m&&v.push(S),f&&v.push.apply(v,S.getChildren(!0,u,m)))),S=S._next;return v},o.getById=function(f){for(var u=this.getChildren(1,1,1),m=u.length;m--;)if(u[m].vars.id===f)return u[m]},o.remove=function(f){return Wn(f)?this.removeLabel(f):Tn(f)?this.killTweensOf(f):(gu(this,f),f===this._recent&&(this._recent=this._last),Ua(this))},o.totalTime=function(f,u){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=jn(Xr.time-(this._ts>0?f/this._ts:(this.totalDuration()-f)/-this._ts))),x.prototype.totalTime.call(this,f,u),this._forcing=0,this):this._tTime},o.addLabel=function(f,u){return this.labels[f]=oo(this,u),this},o.removeLabel=function(f){return delete this.labels[f],this},o.addPause=function(f,u,m){var g=kn.delayedCall(0,u||_h,m);return g.data="isPause",this._hasPause=1,jo(this,g,oo(this,f))},o.removePause=function(f){var u=this._first;for(f=oo(this,f);u;)u._start===f&&u.data==="isPause"&&Js(u),u=u._next},o.killTweensOf=function(f,u,m){for(var g=this.getTweensOf(f,m),v=g.length;v--;)Qs!==g[v]&&g[v].kill(f,u);return this},o.getTweensOf=function(f,u){for(var m=[],g=so(f),v=this._first,S=ds(u),b;v;)v instanceof kn?Em(v._targets,g)&&(S?(!Qs||v._initted&&v._ts)&&v.globalTime(0)<=u&&v.globalTime(v.totalDuration())>u:!u||v.isActive())&&m.push(v):(b=v.getTweensOf(g,u)).length&&m.push.apply(m,b),v=v._next;return m},o.tweenTo=function(f,u){u=u||{};var m=this,g=oo(m,f),v=u,S=v.startAt,b=v.onStart,O=v.onStartParams,k=v.immediateRender,I,F=kn.to(m,ro({ease:u.ease||"none",lazy:!1,immediateRender:!1,time:g,overwrite:"auto",duration:u.duration||Math.abs((g-(S&&"time"in S?S.time:m._time))/m.timeScale())||en,onStart:function(){if(m.pause(),!I){var P=u.duration||Math.abs((g-(S&&"time"in S?S.time:m._time))/m.timeScale());F._dur!==P&&Dl(F,P,0,1).render(F._time,!0,!0),I=1}b&&b.apply(F,O||[])}},u));return k?F.render(0):F},o.tweenFromTo=function(f,u,m){return this.tweenTo(u,ro({startAt:{time:oo(this,f)}},m))},o.recent=function(){return this._recent},o.nextLabel=function(f){return f===void 0&&(f=this._time),rd(this,oo(this,f))},o.previousLabel=function(f){return f===void 0&&(f=this._time),rd(this,oo(this,f),1)},o.currentLabel=function(f){return arguments.length?this.seek(f,!0):this.previousLabel(this._time+en)},o.shiftChildren=function(f,u,m){m===void 0&&(m=0);for(var g=this._first,v=this.labels,S;g;)g._start>=m&&(g._start+=f,g._end+=f),g=g._next;if(u)for(S in v)v[S]>=m&&(v[S]+=f);return Ua(this)},o.invalidate=function(f){var u=this._first;for(this._lock=0;u;)u.invalidate(f),u=u._next;return x.prototype.invalidate.call(this,f)},o.clear=function(f){f===void 0&&(f=!0);for(var u=this._first,m;u;)m=u._next,this.remove(u),u=m;return this._dp&&(this._time=this._tTime=this._pTime=0),f&&(this.labels={}),Ua(this)},o.totalDuration=function(f){var u=0,m=this,g=m._last,v=no,S,b,O;if(arguments.length)return m.timeScale((m._repeat<0?m.duration():m.totalDuration())/(m.reversed()?-f:f));if(m._dirty){for(O=m.parent;g;)S=g._prev,g._dirty&&g.totalDuration(),b=g._start,b>v&&m._sort&&g._ts&&!m._lock?(m._lock=1,jo(m,g,b-g._delay,1)._lock=0):v=b,b<0&&g._ts&&(u-=b,(!O&&!m._dp||O&&O.smoothChildTiming)&&(m._start+=b/m._ts,m._time-=b,m._tTime-=b),m.shiftChildren(-b,!1,-1/0),v=0),g._end>u&&g._ts&&(u=g._end),g=S;Dl(m,m===dn&&m._time>u?m._time:u,1,1),m._dirty=0}return m._tDur},a.updateRoot=function(f){if(dn._ts&&(Gf(dn,vu(f,dn)),Nf=Xr.frame),Xr.frame>=Ff){Ff+=Hr.autoSleep||120;var u=dn._first;if((!u||!u._ts)&&Hr.autoSleep&&Xr._listeners.length<2){for(;u&&!u._ts;)u=u._next;u||Xr.sleep()}}},a}(Ch);ro(gr.prototype,{_lock:0,_hasPause:0,_forcing:0});var Ym=function(a,o,c,f,u,m,g){var v=new Ar(this._pt,a,o,0,1,xd,null,u),S=0,b=0,O,k,I,F,E,P,w,M;for(v.b=c,v.e=f,c+="",f+="",(w=~f.indexOf("random("))&&(f=Mh(f)),m&&(M=[c,f],m(M,a,o),c=M[0],f=M[1]),k=c.match(ac)||[];O=ac.exec(f);)F=O[0],E=f.substring(S,O.index),I?I=(I+1)%5:E.substr(-5)==="rgba("&&(I=1),F!==k[b++]&&(P=parseFloat(k[b-1])||0,v._pt={_next:v._pt,p:E||b===1?E:",",s:P,c:F.charAt(1)==="="?Ol(P,F)-P:parseFloat(F)-P,m:I&&I<4?Math.round:0},S=ac.lastIndex);return v.c=S<f.length?f.substring(S,f.length):"",v.fp=g,(If.test(f)||w)&&(v.e=0),this._pt=v,v},Sc=function(a,o,c,f,u,m,g,v,S,b){Tn(f)&&(f=f(u||0,a,m));var O=a[o],k=c!=="get"?c:Tn(O)?S?a[o.indexOf("set")||!Tn(a["get"+o.substr(3)])?o:"get"+o.substr(3)](S):a[o]():O,I=Tn(O)?S?Qm:yd:Cc,F;if(Wn(f)&&(~f.indexOf("random(")&&(f=Mh(f)),f.charAt(1)==="="&&(F=Ol(k,f)+(or(k)||0),(F||F===0)&&(f=F))),!b||k!==f||Ec)return!isNaN(k*f)&&f!==""?(F=new Ar(this._pt,a,o,+k||0,f-(k||0),typeof O=="boolean"?eg:_d,0,I),S&&(F.fp=S),g&&F.modifier(g,this,a),this._pt=F):(!O&&!(o in a)&&uc(o,f),Ym.call(this,a,o,k,f,I,v||Hr.stringFilter,S))},Zm=function(a,o,c,f,u){if(Tn(a)&&(a=Ah(a,u,o,c,f)),!Vo(a)||a.style&&a.nodeType||rr(a)||Rf(a))return Wn(a)?Ah(a,u,o,c,f):a;var m={},g;for(g in a)m[g]=Ah(a[g],u,o,c,f);return m},md=function(a,o,c,f,u,m){var g,v,S,b;if(Wr[a]&&(g=new Wr[a]).init(u,g.rawVars?o[a]:Zm(o[a],f,u,m,c),c,f,m)!==!1&&(c._pt=v=new Ar(c._pt,u,a,0,1,g.render,g,0,g.priority),c!==zl))for(S=c._ptLookup[c._targets.indexOf(u)],b=g._props.length;b--;)S[g._props[b]]=v;return g},Qs,Ec,bc=function x(a,o,c){var f=a.vars,u=f.ease,m=f.startAt,g=f.immediateRender,v=f.lazy,S=f.onUpdate,b=f.runBackwards,O=f.yoyoEase,k=f.keyframes,I=f.autoRevert,F=a._dur,E=a._startAt,P=a._targets,w=a.parent,M=w&&w.data==="nested"?w.vars.targets:P,R=a._overwrite==="auto"&&!ic,C=a.timeline,U,N,X,J,Z,ct,Rt,tt,_t,G,Pt,Et,At;if(C&&(!k||!u)&&(u="none"),a._ease=Ga(u,Ll.ease),a._yEase=O?cd(Ga(O===!0?u:O,Ll.ease)):0,O&&a._yoyo&&!a._repeat&&(O=a._yEase,a._yEase=a._ease,a._ease=O),a._from=!C&&!!f.runBackwards,!C||k&&!f.stagger){if(tt=P[0]?Na(P[0]).harness:0,Et=tt&&f[tt.prop],U=mu(f,cc),E&&(E._zTime<0&&E.progress(1),o<0&&b&&g&&!I?E.render(-1,!0):E.revert(b&&F?fu:Mm),E._lazy=0),m){if(Js(a._startAt=kn.set(P,ro({data:"isStart",overwrite:!1,parent:w,immediateRender:!0,lazy:!E&&br(v),startAt:null,delay:0,onUpdate:S&&function(){return jr(a,"onUpdate")},stagger:0},m))),a._startAt._dp=0,a._startAt._sat=a,o<0&&(nr||!g&&!I)&&a._startAt.revert(fu),g&&F&&o<=0&&c<=0){o&&(a._zTime=o);return}}else if(b&&F&&!E){if(o&&(g=!1),X=ro({overwrite:!1,data:"isFromStart",lazy:g&&!E&&br(v),immediateRender:g,stagger:0,parent:w},U),Et&&(X[tt.prop]=Et),Js(a._startAt=kn.set(P,X)),a._startAt._dp=0,a._startAt._sat=a,o<0&&(nr?a._startAt.revert(fu):a._startAt.render(-1,!0)),a._zTime=o,!g)x(a._startAt,en,en);else if(!o)return}for(a._pt=a._ptCache=0,v=F&&br(v)||v&&!F,N=0;N<P.length;N++){if(Z=P[N],Rt=Z._gsap||mc(P)[N]._gsap,a._ptLookup[N]=G={},fc[Rt.id]&&Zs.length&&pu(),Pt=M===P?N:M.indexOf(Z),tt&&(_t=new tt).init(Z,Et||U,a,Pt,M)!==!1&&(a._pt=J=new Ar(a._pt,Z,_t.name,0,1,_t.render,_t,0,_t.priority),_t._props.forEach(function(ce){G[ce]=J}),_t.priority&&(ct=1)),!tt||Et)for(X in U)Wr[X]&&(_t=md(X,U,a,Pt,Z,M))?_t.priority&&(ct=1):G[X]=J=Sc.call(a,Z,X,"get",U[X],Pt,M,0,f.stringFilter);a._op&&a._op[N]&&a.kill(Z,a._op[N]),R&&a._pt&&(Qs=a,dn.killTweensOf(Z,G,a.globalTime(o)),At=!a.parent,Qs=0),a._pt&&v&&(fc[Rt.id]=1)}ct&&wd(a),a._onInit&&a._onInit(a)}a._onUpdate=S,a._initted=(!a._op||a._pt)&&!At,k&&o<=0&&C.render(no,!0,!0)},Jm=function(a,o,c,f,u,m,g,v){var S=(a._pt&&a._ptCache||(a._ptCache={}))[o],b,O,k,I;if(!S)for(S=a._ptCache[o]=[],k=a._ptLookup,I=a._targets.length;I--;){if(b=k[I][o],b&&b.d&&b.d._pt)for(b=b.d._pt;b&&b.p!==o&&b.fp!==o;)b=b._next;if(!b)return Ec=1,a.vars[o]="+=0",bc(a,g),Ec=0,v?yh(o+" not eligible for reset"):1;S.push(b)}for(I=S.length;I--;)O=S[I],b=O._pt||O,b.s=(f||f===0)&&!u?f:b.s+(f||0)+m*b.c,b.c=c-b.s,O.e&&(O.e=Rn(c)+or(O.e)),O.b&&(O.b=b.s+or(O.b))},$m=function(a,o){var c=a[0]?Na(a[0]).harness:0,f=c&&c.aliases,u,m,g,v;if(!f)return o;u=Fa({},o);for(m in f)if(m in u)for(v=f[m].split(","),g=v.length;g--;)u[v[g]]=u[m];return u},Km=function(a,o,c,f){var u=o.ease||f||"power1.inOut",m,g;if(rr(o))g=c[a]||(c[a]=[]),o.forEach(function(v,S){return g.push({t:S/(o.length-1)*100,v,e:u})});else for(m in o)g=c[m]||(c[m]=[]),m==="ease"||g.push({t:parseFloat(a),v:o[m],e:u})},Ah=function(a,o,c,f,u){return Tn(a)?a.call(o,c,f,u):Wn(a)&&~a.indexOf("random(")?Mh(a):a},gd=pc+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase,autoRevert",vd={};Cr(gd+",id,stagger,delay,duration,paused,scrollTrigger",function(x){return vd[x]=1});var kn=function(x){Pf(a,x);function a(c,f,u,m){var g;typeof f=="number"&&(u.duration=f,f=u,u=null),g=x.call(this,m?f:xh(f))||this;var v=g.vars,S=v.duration,b=v.delay,O=v.immediateRender,k=v.stagger,I=v.overwrite,F=v.keyframes,E=v.defaults,P=v.scrollTrigger,w=v.yoyoEase,M=f.parent||dn,R=(rr(c)||Rf(c)?ds(c[0]):"length"in f)?[c]:so(c),C,U,N,X,J,Z,ct,Rt;if(g._targets=R.length?mc(R):yh("GSAP target "+c+" not found. https://gsap.com",!Hr.nullTargetWarn)||[],g._ptLookup=[],g._overwrite=I,F||k||uu(S)||uu(b)){if(f=g.vars,C=g.timeline=new gr({data:"nested",defaults:E||{},targets:M&&M.data==="nested"?M.vars.targets:R}),C.kill(),C.parent=C._dp=fs(g),C._start=0,k||uu(S)||uu(b)){if(X=R.length,ct=k&&Qf(k),Vo(k))for(J in k)~gd.indexOf(J)&&(Rt||(Rt={}),Rt[J]=k[J]);for(U=0;U<X;U++)N=mu(f,vd),N.stagger=0,w&&(N.yoyoEase=w),Rt&&Fa(N,Rt),Z=R[U],N.duration=+Ah(S,fs(g),U,Z,R),N.delay=(+Ah(b,fs(g),U,Z,R)||0)-g._delay,!k&&X===1&&N.delay&&(g._delay=b=N.delay,g._start+=b,N.delay=0),C.to(Z,N,ct?ct(U,Z,R):0),C._ease=Ii.none;C.duration()?S=b=0:g.timeline=0}else if(F){xh(ro(C.vars.defaults,{ease:"none"})),C._ease=Ga(F.ease||f.ease||"none");var tt=0,_t,G,Pt;if(rr(F))F.forEach(function(Et){return C.to(R,Et,">")}),C.duration();else{N={};for(J in F)J==="ease"||J==="easeEach"||Km(J,F[J],N,F.easeEach);for(J in N)for(_t=N[J].sort(function(Et,At){return Et.t-At.t}),tt=0,U=0;U<_t.length;U++)G=_t[U],Pt={ease:G.e,duration:(G.t-(U?_t[U-1].t:0))/100*S},Pt[J]=G.v,C.to(R,Pt,tt),tt+=Pt.duration;C.duration()<S&&C.to({},{duration:S-C.duration()})}}S||g.duration(S=C.duration())}else g.timeline=0;return I===!0&&!ic&&(Qs=fs(g),dn.killTweensOf(R),Qs=0),jo(M,fs(g),u),f.reversed&&g.reverse(),f.paused&&g.paused(!0),(O||!S&&!F&&g._start===jn(M._time)&&br(O)&&Pm(fs(g))&&M.data!=="nested")&&(g._tTime=-en,g.render(Math.max(0,-b)||0)),P&&Yf(fs(g),P),g}var o=a.prototype;return o.render=function(f,u,m){var g=this._time,v=this._tDur,S=this._dur,b=f<0,O=f>v-en&&!b?v:f<en?0:f,k,I,F,E,P,w,M,R,C;if(!S)Rm(this,f,u,m);else if(O!==this._tTime||!f||m||!this._initted&&this._tTime||this._startAt&&this._zTime<0!==b){if(k=O,R=this.timeline,this._repeat){if(E=S+this._rDelay,this._repeat<-1&&b)return this.totalTime(E*100+f,u,m);if(k=jn(O%E),O===v?(F=this._repeat,k=S):(F=~~(O/E),F&&F===jn(O/E)&&(k=S,F--),k>S&&(k=S)),w=this._yoyo&&F&1,w&&(C=this._yEase,k=S-k),P=Il(this._tTime,E),k===g&&!m&&this._initted&&F===P)return this._tTime=O,this;F!==P&&(R&&this._yEase&&fd(R,w),this.vars.repeatRefresh&&!w&&!this._lock&&this._time!==E&&this._initted&&(this._lock=m=1,this.render(jn(E*F),!0).invalidate()._lock=0))}if(!this._initted){if(Zf(this,b?f:k,m,u,O))return this._tTime=0,this;if(g!==this._time&&!(m&&this.vars.repeatRefresh&&F!==P))return this;if(S!==this._dur)return this.render(f,u,m)}if(this._tTime=O,this._time=k,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=M=(C||this._ease)(k/S),this._from&&(this.ratio=M=1-M),k&&!g&&!u&&!F&&(jr(this,"onStart"),this._tTime!==O))return this;for(I=this._pt;I;)I.r(M,I.d),I=I._next;R&&R.render(f<0?f:R._dur*R._ease(k/this._dur),u,m)||this._startAt&&(this._zTime=f),this._onUpdate&&!u&&(b&&gc(this,f,u,m),jr(this,"onUpdate")),this._repeat&&F!==P&&this.vars.onRepeat&&!u&&this.parent&&jr(this,"onRepeat"),(O===this._tDur||!O)&&this._tTime===O&&(b&&!this._onUpdate&&gc(this,f,!0,!0),(f||!S)&&(O===this._tDur&&this._ts>0||!O&&this._ts<0)&&Js(this,1),!u&&!(b&&!g)&&(O||g||w)&&(jr(this,O===v?"onComplete":"onReverseComplete",!0),this._prom&&!(O<v&&this.timeScale()>0)&&this._prom()))}return this},o.targets=function(){return this._targets},o.invalidate=function(f){return(!f||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(f),x.prototype.invalidate.call(this,f)},o.resetTo=function(f,u,m,g,v){bh||Xr.wake(),this._ts||this.play();var S=Math.min(this._dur,(this._dp._time-this._start)*this._ts),b;return this._initted||bc(this,S),b=this._ease(S/this._dur),Jm(this,f,u,m,g,b,S,v)?this.resetTo(f,u,m,g,1):(_u(this,0),this.parent||jf(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},o.kill=function(f,u){if(u===void 0&&(u="all"),!f&&(!u||u==="all"))return this._lazy=this._pt=0,this.parent?Sh(this):this;if(this.timeline){var m=this.timeline.totalDuration();return this.timeline.killTweensOf(f,u,Qs&&Qs.vars.overwrite!==!0)._first||Sh(this),this.parent&&m!==this.timeline.totalDuration()&&Dl(this,this._dur*this.timeline._tDur/m,0,1),this}var g=this._targets,v=f?so(f):g,S=this._ptLookup,b=this._pt,O,k,I,F,E,P,w;if((!u||u==="all")&&Cm(g,v))return u==="all"&&(this._pt=0),Sh(this);for(O=this._op=this._op||[],u!=="all"&&(Wn(u)&&(E={},Cr(u,function(M){return E[M]=1}),u=E),u=$m(g,u)),w=g.length;w--;)if(~v.indexOf(g[w])){k=S[w],u==="all"?(O[w]=u,F=k,I={}):(I=O[w]=O[w]||{},F=u);for(E in F)P=k&&k[E],P&&((!("kill"in P.d)||P.d.kill(E)===!0)&&gu(this,P,"_pt"),delete k[E]),I!=="all"&&(I[E]=1)}return this._initted&&!this._pt&&b&&Sh(this),this},a.to=function(f,u){return new a(f,u,arguments[2])},a.from=function(f,u){return wh(1,arguments)},a.delayedCall=function(f,u,m,g){return new a(u,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:f,onComplete:u,onReverseComplete:u,onCompleteParams:m,onReverseCompleteParams:m,callbackScope:g})},a.fromTo=function(f,u,m){return wh(2,arguments)},a.set=function(f,u){return u.duration=0,u.repeatDelay||(u.repeat=0),new a(f,u)},a.killTweensOf=function(f,u,m){return dn.killTweensOf(f,u,m)},a}(Ch);ro(kn.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0}),Cr("staggerTo,staggerFrom,staggerFromTo",function(x){kn[x]=function(){var a=new gr,o=yc.call(arguments,0);return o.splice(x==="staggerFromTo"?5:4,0,0),a[x].apply(a,o)}});var Cc=function(a,o,c){return a[o]=c},yd=function(a,o,c){return a[o](c)},Qm=function(a,o,c,f){return a[o](f.fp,c)},tg=function(a,o,c){return a.setAttribute(o,c)},Ac=function(a,o){return Tn(a[o])?yd:rc(a[o])&&a.setAttribute?tg:Cc},_d=function(a,o){return o.set(o.t,o.p,Math.round((o.s+o.c*a)*1e6)/1e6,o)},eg=function(a,o){return o.set(o.t,o.p,!!(o.s+o.c*a),o)},xd=function(a,o){var c=o._pt,f="";if(!a&&o.b)f=o.b;else if(a===1&&o.e)f=o.e;else{for(;c;)f=c.p+(c.m?c.m(c.s+c.c*a):Math.round((c.s+c.c*a)*1e4)/1e4)+f,c=c._next;f+=o.c}o.set(o.t,o.p,f,o)},Pc=function(a,o){for(var c=o._pt;c;)c.r(a,c.d),c=c._next},ig=function(a,o,c,f){for(var u=this._pt,m;u;)m=u._next,u.p===f&&u.modifier(a,o,c),u=m},ng=function(a){for(var o=this._pt,c,f;o;)f=o._next,o.p===a&&!o.op||o.op===a?gu(this,o,"_pt"):o.dep||(c=1),o=f;return!c},rg=function(a,o,c,f){f.mSet(a,o,f.m.call(f.tween,c,f.mt),f)},wd=function(a){for(var o=a._pt,c,f,u,m;o;){for(c=o._next,f=u;f&&f.pr>o.pr;)f=f._next;(o._prev=f?f._prev:m)?o._prev._next=o:u=o,(o._next=f)?f._prev=o:m=o,o=c}a._pt=u},Ar=function(){function x(o,c,f,u,m,g,v,S,b){this.t=c,this.s=u,this.c=m,this.p=f,this.r=g||_d,this.d=v||this,this.set=S||Cc,this.pr=b||0,this._next=o,o&&(o._prev=this)}var a=x.prototype;return a.modifier=function(c,f,u){this.mSet=this.mSet||this.set,this.set=rg,this.m=c,this.mt=u,this.tween=f},x}();Cr(pc+"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(x){return cc[x]=1}),Vr.TweenMax=Vr.TweenLite=kn,Vr.TimelineLite=Vr.TimelineMax=gr,dn=new gr({sortChildren:!1,defaults:Ll,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0}),Hr.stringFilter=ud;var Va=[],xu={},og=[],Td=0,sg=0,Lc=function(a){return(xu[a]||og).map(function(o){return o()})},Rc=function(){var a=Date.now(),o=[];a-Td>2&&(Lc("matchMediaInit"),Va.forEach(function(c){var f=c.queries,u=c.conditions,m,g,v,S;for(g in f)m=Wo.matchMedia(f[g]).matches,m&&(v=1),m!==u[g]&&(u[g]=m,S=1);S&&(c.revert(),v&&o.push(c))}),Lc("matchMediaRevert"),o.forEach(function(c){return c.onMatch(c,function(f){return c.add(null,f)})}),Td=a,Lc("matchMedia"))},Md=function(){function x(o,c){this.selector=c&&_c(c),this.data=[],this._r=[],this.isReverted=!1,this.id=sg++,o&&this.add(o)}var a=x.prototype;return a.add=function(c,f,u){Tn(c)&&(u=f,f=c,c=Tn);var m=this,g=function(){var S=hn,b=m.selector,O;return S&&S!==m&&S.data.push(m),u&&(m.selector=_c(u)),hn=m,O=f.apply(m,arguments),Tn(O)&&m._r.push(O),hn=S,m.selector=b,m.isReverted=!1,O};return m.last=g,c===Tn?g(m,function(v){return m.add(null,v)}):c?m[c]=g:g},a.ignore=function(c){var f=hn;hn=null,c(this),hn=f},a.getTweens=function(){var c=[];return this.data.forEach(function(f){return f instanceof x?c.push.apply(c,f.getTweens()):f instanceof kn&&!(f.parent&&f.parent.data==="nested")&&c.push(f)}),c},a.clear=function(){this._r.length=this.data.length=0},a.kill=function(c,f){var u=this;if(c?function(){for(var g=u.getTweens(),v=u.data.length,S;v--;)S=u.data[v],S.data==="isFlip"&&(S.revert(),S.getChildren(!0,!0,!1).forEach(function(b){return g.splice(g.indexOf(b),1)}));for(g.map(function(b){return{g:b._dur||b._delay||b._sat&&!b._sat.vars.immediateRender?b.globalTime(0):-1/0,t:b}}).sort(function(b,O){return O.g-b.g||-1/0}).forEach(function(b){return b.t.revert(c)}),v=u.data.length;v--;)S=u.data[v],S instanceof gr?S.data!=="nested"&&(S.scrollTrigger&&S.scrollTrigger.revert(),S.kill()):!(S instanceof kn)&&S.revert&&S.revert(c);u._r.forEach(function(b){return b(c,u)}),u.isReverted=!0}():this.data.forEach(function(g){return g.kill&&g.kill()}),this.clear(),f)for(var m=Va.length;m--;)Va[m].id===this.id&&Va.splice(m,1)},a.revert=function(c){this.kill(c||{})},x}(),ag=function(){function x(o){this.contexts=[],this.scope=o,hn&&hn.data.push(this)}var a=x.prototype;return a.add=function(c,f,u){Vo(c)||(c={matches:c});var m=new Md(0,u||this.scope),g=m.conditions={},v,S,b;hn&&!m.selector&&(m.selector=hn.selector),this.contexts.push(m),f=m.add("onMatch",f),m.queries=c;for(S in c)S==="all"?b=1:(v=Wo.matchMedia(c[S]),v&&(Va.indexOf(m)<0&&Va.push(m),(g[S]=v.matches)&&(b=1),v.addListener?v.addListener(Rc):v.addEventListener("change",Rc)));return b&&f(m,function(O){return m.add(null,O)}),this},a.revert=function(c){this.kill(c||{})},a.kill=function(c){this.contexts.forEach(function(f){return f.kill(c,!0)})},x}(),wu={registerPlugin:function(){for(var a=arguments.length,o=new Array(a),c=0;c<a;c++)o[c]=arguments[c];o.forEach(function(f){return sd(f)})},timeline:function(a){return new gr(a)},getTweensOf:function(a,o){return dn.getTweensOf(a,o)},getProperty:function(a,o,c,f){Wn(a)&&(a=so(a)[0]);var u=Na(a||{}).get,m=c?Vf:Hf;return c==="native"&&(c=""),a&&(o?m((Wr[o]&&Wr[o].get||u)(a,o,c,f)):function(g,v,S){return m((Wr[g]&&Wr[g].get||u)(a,g,v,S))})},quickSetter:function(a,o,c){if(a=so(a),a.length>1){var f=a.map(function(b){return Pr.quickSetter(b,o,c)}),u=f.length;return function(b){for(var O=u;O--;)f[O](b)}}a=a[0]||{};var m=Wr[o],g=Na(a),v=g.harness&&(g.harness.aliases||{})[o]||o,S=m?function(b){var O=new m;zl._pt=0,O.init(a,c?b+c:b,zl,0,[a]),O.render(1,O),zl._pt&&Pc(1,zl)}:g.set(a,v);return m?S:function(b){return S(a,v,c?b+c:b,g,1)}},quickTo:function(a,o,c){var f,u=Pr.to(a,Fa((f={},f[o]="+=0.1",f.paused=!0,f),c||{})),m=function(v,S,b){return u.resetTo(o,v,S,b)};return m.tween=u,m},isTweening:function(a){return dn.getTweensOf(a,!0).length>0},defaults:function(a){return a&&a.ease&&(a.ease=Ga(a.ease,Ll.ease)),Wf(Ll,a||{})},config:function(a){return Wf(Hr,a||{})},registerEffect:function(a){var o=a.name,c=a.effect,f=a.plugins,u=a.defaults,m=a.extendTimeline;(f||"").split(",").forEach(function(g){return g&&!Wr[g]&&!Vr[g]&&yh(o+" effect requires "+g+" plugin.")}),dc[o]=function(g,v,S){return c(so(g),ro(v||{},u),S)},m&&(gr.prototype[o]=function(g,v,S){return this.add(dc[o](g,Vo(v)?v:(S=v)&&{},this),S)})},registerEase:function(a,o){Ii[a]=Ga(o)},parseEase:function(a,o){return arguments.length?Ga(a,o):Ii},getById:function(a){return dn.getById(a)},exportRoot:function(a,o){a===void 0&&(a={});var c=new gr(a),f,u;for(c.smoothChildTiming=br(a.smoothChildTiming),dn.remove(c),c._dp=0,c._time=c._tTime=dn._time,f=dn._first;f;)u=f._next,(o||!(!f._dur&&f instanceof kn&&f.vars.onComplete===f._targets[0]))&&jo(c,f,f._start-f._delay),f=u;return jo(dn,c,0),c},context:function(a,o){return a?new Md(a,o):hn},matchMedia:function(a){return new ag(a)},matchMediaRefresh:function(){return Va.forEach(function(a){var o=a.conditions,c,f;for(f in o)o[f]&&(o[f]=!1,c=1);c&&a.revert()})||Rc()},addEventListener:function(a,o){var c=xu[a]||(xu[a]=[]);~c.indexOf(o)||c.push(o)},removeEventListener:function(a,o){var c=xu[a],f=c&&c.indexOf(o);f>=0&&c.splice(f,1)},utils:{wrap:Fm,wrapYoyo:Um,distribute:Qf,random:ed,snap:td,normalize:Nm,getUnit:or,clamp:Dm,splitColor:ad,toArray:so,selector:_c,mapRange:nd,pipe:km,unitize:Bm,interpolate:Gm,shuffle:Kf},install:kf,effects:dc,ticker:Xr,updateRoot:gr.updateRoot,plugins:Wr,globalTimeline:dn,core:{PropTween:Ar,globals:Bf,Tween:kn,Timeline:gr,Animation:Ch,getCache:Na,_removeLinkedListItem:gu,reverting:function(){return nr},context:function(a){return a&&hn&&(hn.data.push(a),a._ctx=hn),hn},suppressOverwrites:function(a){return ic=a}}};Cr("to,from,fromTo,delayedCall,set,killTweensOf",function(x){return wu[x]=kn[x]}),Xr.add(gr.updateRoot),zl=wu.to({},{duration:0});var lg=function(a,o){for(var c=a._pt;c&&c.p!==o&&c.op!==o&&c.fp!==o;)c=c._next;return c},hg=function(a,o){var c=a._targets,f,u,m;for(f in o)for(u=c.length;u--;)m=a._ptLookup[u][f],m&&(m=m.d)&&(m._pt&&(m=lg(m,f)),m&&m.modifier&&m.modifier(o[f],a,c[u],f))},Oc=function(a,o){return{name:a,rawVars:1,init:function(f,u,m){m._onInit=function(g){var v,S;if(Wn(u)&&(v={},Cr(u,function(b){return v[b]=1}),u=v),o){v={};for(S in u)v[S]=o(u[S]);u=v}hg(g,u)}}}},Pr=wu.registerPlugin({name:"attr",init:function(a,o,c,f,u){var m,g,v;this.tween=c;for(m in o)v=a.getAttribute(m)||"",g=this.add(a,"setAttribute",(v||0)+"",o[m],f,u,0,0,m),g.op=m,g.b=v,this._props.push(m)},render:function(a,o){for(var c=o._pt;c;)nr?c.set(c.t,c.p,c.b,c):c.r(a,c.d),c=c._next}},{name:"endArray",init:function(a,o){for(var c=o.length;c--;)this.add(a,c,a[c]||0,o[c],0,0,0,0,0,1)}},Oc("roundProps",xc),Oc("modifiers"),Oc("snap",td))||wu;kn.version=gr.version=Pr.version="3.12.5",zf=1,oc()&&kl(),Ii.Power0,Ii.Power1,Ii.Power2,Ii.Power3,Ii.Power4,Ii.Linear,Ii.Quad,Ii.Cubic,Ii.Quart,Ii.Quint,Ii.Strong,Ii.Elastic,Ii.Back,Ii.SteppedEase,Ii.Bounce,Ii.Sine,Ii.Expo,Ii.Circ;/*!
|
|
2695
2695
|
* CSSPlugin 3.12.5
|
|
2696
2696
|
* https://gsap.com
|
|
2697
2697
|
*
|
|
@@ -2699,4 +2699,4 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
2699
2699
|
* Subject to the terms at https://gsap.com/standard-license or for
|
|
2700
2700
|
* Club GSAP members, the agreement issued with that membership.
|
|
2701
2701
|
* @author: Jack Doyle, jack@greensock.com
|
|
2702
|
-
*/var Sd,ta,Bl,Ic,Wa,Ed,Dc,ug=function(){return typeof window<"u"},ps={},ja=180/Math.PI,Nl=Math.PI/180,Fl=Math.atan2,bd=1e8,zc=/([A-Z])/g,cg=/(left|right|width|margin|padding|x)/i,fg=/[\s,\(]\S/,Xo={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},kc=function(a,o){return o.set(o.t,o.p,Math.round((o.s+o.c*a)*1e4)/1e4+o.u,o)},dg=function(a,o){return o.set(o.t,o.p,a===1?o.e:Math.round((o.s+o.c*a)*1e4)/1e4+o.u,o)},pg=function(a,o){return o.set(o.t,o.p,a?Math.round((o.s+o.c*a)*1e4)/1e4+o.u:o.b,o)},mg=function(a,o){var c=o.s+o.c*a;o.set(o.t,o.p,~~(c+(c<0?-.5:.5))+o.u,o)},Cd=function(a,o){return o.set(o.t,o.p,a?o.e:o.b,o)},Ad=function(a,o){return o.set(o.t,o.p,a!==1?o.b:o.e,o)},gg=function(a,o,c){return a.style[o]=c},vg=function(a,o,c){return a.style.setProperty(o,c)},yg=function(a,o,c){return a._gsap[o]=c},_g=function(a,o,c){return a._gsap.scaleX=a._gsap.scaleY=c},xg=function(a,o,c,f,u){var m=a._gsap;m.scaleX=m.scaleY=c,m.renderTransform(u,m)},wg=function(a,o,c,f,u){var m=a._gsap;m[o]=c,m.renderTransform(u,m)},pn="transform",Lr=pn+"Origin",Tg=function x(a,o){var c=this,f=this.target,u=f.style,m=f._gsap;if(a in ps&&u){if(this.tfm=this.tfm||{},a!=="transform")a=Xo[a]||a,~a.indexOf(",")?a.split(",").forEach(function(g){return c.tfm[g]=ms(f,g)}):this.tfm[a]=m.x?m[a]:ms(f,a),a===Lr&&(this.tfm.zOrigin=m.zOrigin);else return Xo.transform.split(",").forEach(function(g){return x.call(c,g,o)});if(this.props.indexOf(pn)>=0)return;m.svg&&(this.svgo=f.getAttribute("data-svg-origin"),this.props.push(Lr,o,"")),a=pn}(u||o)&&this.props.push(a,o,u[a])},Pd=function(a){a.translate&&(a.removeProperty("translate"),a.removeProperty("scale"),a.removeProperty("rotate"))},Mg=function(){var a=this.props,o=this.target,c=o.style,f=o._gsap,u,m;for(u=0;u<a.length;u+=3)a[u+1]?o[a[u]]=a[u+2]:a[u+2]?c[a[u]]=a[u+2]:c.removeProperty(a[u].substr(0,2)==="--"?a[u]:a[u].replace(zc,"-$1").toLowerCase());if(this.tfm){for(m in this.tfm)f[m]=this.tfm[m];f.svg&&(f.renderTransform(),o.setAttribute("data-svg-origin",this.svgo||"")),u=Dc(),(!u||!u.isStart)&&!c[pn]&&(Pd(c),f.zOrigin&&c[Lr]&&(c[Lr]+=" "+f.zOrigin+"px",f.zOrigin=0,f.renderTransform()),f.uncache=1)}},Ld=function(a,o){var c={target:a,props:[],revert:Mg,save:Tg};return a._gsap||Pr.core.getCache(a),o&&o.split(",").forEach(function(f){return c.save(f)}),c},Rd,Bc=function(a,o){var c=ta.createElementNS?ta.createElementNS((o||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),a):ta.createElement(a);return c&&c.style?c:ta.createElement(a)},qo=function x(a,o,c){var f=getComputedStyle(a);return f[o]||f.getPropertyValue(o.replace(zc,"-$1").toLowerCase())||f.getPropertyValue(o)||!c&&x(a,Ul(o)||o,1)||""},Od="O,Moz,ms,Ms,Webkit".split(","),Ul=function(a,o,c){var f=o||Wa,u=f.style,m=5;if(a in u&&!c)return a;for(a=a.charAt(0).toUpperCase()+a.substr(1);m--&&!(Od[m]+a in u););return m<0?null:(m===3?"ms":m>=0?Od[m]:"")+a},Nc=function(){ug()&&window.document&&(Sd=window,ta=Sd.document,Bl=ta.documentElement,Wa=Bc("div")||{style:{}},Bc("div"),pn=Ul(pn),Lr=pn+"Origin",Wa.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",Rd=!!Ul("perspective"),Dc=Pr.core.reverting,Ic=1)},Fc=function x(a){var o=Bc("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),c=this.parentNode,f=this.nextSibling,u=this.style.cssText,m;if(Bl.appendChild(o),o.appendChild(this),this.style.display="block",a)try{m=this.getBBox(),this._gsapBBox=this.getBBox,this.getBBox=x}catch{}else this._gsapBBox&&(m=this._gsapBBox());return c&&(f?c.insertBefore(this,f):c.appendChild(this)),Bl.removeChild(o),this.style.cssText=u,m},Id=function(a,o){for(var c=o.length;c--;)if(a.hasAttribute(o[c]))return a.getAttribute(o[c])},Dd=function(a){var o;try{o=a.getBBox()}catch{o=Fc.call(a,!0)}return o&&(o.width||o.height)||a.getBBox===Fc||(o=Fc.call(a,!0)),o&&!o.width&&!o.x&&!o.y?{x:+Id(a,["x","cx","x1"])||0,y:+Id(a,["y","cy","y1"])||0,width:0,height:0}:o},zd=function(a){return!!(a.getCTM&&(!a.parentNode||a.ownerSVGElement)&&Dd(a))},Xa=function(a,o){if(o){var c=a.style,f;o in ps&&o!==Lr&&(o=pn),c.removeProperty?(f=o.substr(0,2),(f==="ms"||o.substr(0,6)==="webkit")&&(o="-"+o),c.removeProperty(f==="--"?o:o.replace(zc,"-$1").toLowerCase())):c.removeAttribute(o)}},ea=function(a,o,c,f,u,m){var g=new Ar(a._pt,o,c,0,1,m?Ad:Cd);return a._pt=g,g.b=f,g.e=u,a._props.push(c),g},kd={deg:1,rad:1,turn:1},Sg={grid:1,flex:1},ia=function x(a,o,c,f){var u=parseFloat(c)||0,m=(c+"").trim().substr((u+"").length)||"px",g=Wa.style,v=cg.test(o),S=a.tagName.toLowerCase()==="svg",b=(S?"client":"offset")+(v?"Width":"Height"),O=100,k=f==="px",I=f==="%",N,E,P,w;if(f===m||!u||kd[f]||kd[m])return u;if(m!=="px"&&!k&&(u=x(a,o,c,"px")),w=a.getCTM&&zd(a),(I||m==="%")&&(ps[o]||~o.indexOf("adius")))return N=w?a.getBBox()[v?"width":"height"]:a[b],Rn(I?u/N*O:u/100*N);if(g[v?"width":"height"]=O+(k?m:f),E=~o.indexOf("adius")||f==="em"&&a.appendChild&&!S?a:a.parentNode,w&&(E=(a.ownerSVGElement||{}).parentNode),(!E||E===ta||!E.appendChild)&&(E=ta.body),P=E._gsap,P&&I&&P.width&&v&&P.time===Xr.time&&!P.uncache)return Rn(u/P.width*O);if(I&&(o==="height"||o==="width")){var M=a.style[o];a.style[o]=O+f,N=a[b],M?a.style[o]=M:Xa(a,o)}else(I||m==="%")&&!Sg[qo(E,"display")]&&(g.position=qo(a,"position")),E===a&&(g.position="static"),E.appendChild(Wa),N=Wa[b],E.removeChild(Wa),g.position="absolute";return v&&I&&(P=Na(E),P.time=Xr.time,P.width=E[b]),Rn(k?N*u/O:N&&u?O/N*u:0)},ms=function(a,o,c,f){var u;return Ic||Nc(),o in Xo&&o!=="transform"&&(o=Xo[o],~o.indexOf(",")&&(o=o.split(",")[0])),ps[o]&&o!=="transform"?(u=Lh(a,f),u=o!=="transformOrigin"?u[o]:u.svg?u.origin:Mu(qo(a,Lr))+" "+u.zOrigin+"px"):(u=a.style[o],(!u||u==="auto"||f||~(u+"").indexOf("calc("))&&(u=Tu[o]&&Tu[o](a,o,c)||qo(a,o)||Uf(a,o)||(o==="opacity"?1:0))),c&&!~(u+"").trim().indexOf(" ")?ia(a,o,u,c)+c:u},Eg=function(a,o,c,f){if(!c||c==="none"){var u=Ul(o,a,1),m=u&&qo(a,u,1);m&&m!==c?(o=u,c=m):o==="borderColor"&&(c=qo(a,"borderTopColor"))}var g=new Ar(this._pt,a.style,o,0,1,xd),v=0,S=0,b,O,k,I,N,E,P,w,M,R,C,U;if(g.b=c,g.e=f,c+="",f+="",f==="auto"&&(E=a.style[o],a.style[o]=f,f=qo(a,o)||f,E?a.style[o]=E:Xa(a,o)),b=[c,f],ud(b),c=b[0],f=b[1],k=c.match(Rl)||[],U=f.match(Rl)||[],U.length){for(;O=Rl.exec(f);)P=O[0],M=f.substring(v,O.index),N?N=(N+1)%5:(M.substr(-5)==="rgba("||M.substr(-5)==="hsla(")&&(N=1),P!==(E=k[S++]||"")&&(I=parseFloat(E)||0,C=E.substr((I+"").length),P.charAt(1)==="="&&(P=Ol(I,P)+C),w=parseFloat(P),R=P.substr((w+"").length),v=Rl.lastIndex-R.length,R||(R=R||Hr.units[o]||C,v===f.length&&(f+=R,g.e+=R)),C!==R&&(I=ia(a,o,E,R)||0),g._pt={_next:g._pt,p:M||S===1?M:",",s:I,c:w-I,m:N&&N<4||o==="zIndex"?Math.round:0});g.c=v<f.length?f.substring(v,f.length):""}else g.r=o==="display"&&f==="none"?Ad:Cd;return If.test(f)&&(g.e=0),this._pt=g,g},Bd={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"},bg=function(a){var o=a.split(" "),c=o[0],f=o[1]||"50%";return(c==="top"||c==="bottom"||f==="left"||f==="right")&&(a=c,c=f,f=a),o[0]=Bd[c]||c,o[1]=Bd[f]||f,o.join(" ")},Cg=function(a,o){if(o.tween&&o.tween._time===o.tween._dur){var c=o.t,f=c.style,u=o.u,m=c._gsap,g,v,S;if(u==="all"||u===!0)f.cssText="",v=1;else for(u=u.split(","),S=u.length;--S>-1;)g=u[S],ps[g]&&(v=1,g=g==="transformOrigin"?Lr:pn),Xa(c,g);v&&(Xa(c,pn),m&&(m.svg&&c.removeAttribute("transform"),Lh(c,1),m.uncache=1,Pd(f)))}},Tu={clearProps:function(a,o,c,f,u){if(u.data!=="isFromStart"){var m=a._pt=new Ar(a._pt,o,c,0,0,Cg);return m.u=f,m.pr=-10,m.tween=u,a._props.push(c),1}}},Ph=[1,0,0,1,0,0],Nd={},Fd=function(a){return a==="matrix(1, 0, 0, 1, 0, 0)"||a==="none"||!a},Ud=function(a){var o=qo(a,pn);return Fd(o)?Ph:o.substr(7).match(Of).map(Rn)},Uc=function(a,o){var c=a._gsap||Na(a),f=a.style,u=Ud(a),m,g,v,S;return c.svg&&a.getAttribute("transform")?(v=a.transform.baseVal.consolidate().matrix,u=[v.a,v.b,v.c,v.d,v.e,v.f],u.join(",")==="1,0,0,1,0,0"?Ph:u):(u===Ph&&!a.offsetParent&&a!==Bl&&!c.svg&&(v=f.display,f.display="block",m=a.parentNode,(!m||!a.offsetParent)&&(S=1,g=a.nextElementSibling,Bl.appendChild(a)),u=Ud(a),v?f.display=v:Xa(a,"display"),S&&(g?m.insertBefore(a,g):m?m.appendChild(a):Bl.removeChild(a))),o&&u.length>6?[u[0],u[1],u[4],u[5],u[12],u[13]]:u)},Gc=function(a,o,c,f,u,m){var g=a._gsap,v=u||Uc(a,!0),S=g.xOrigin||0,b=g.yOrigin||0,O=g.xOffset||0,k=g.yOffset||0,I=v[0],N=v[1],E=v[2],P=v[3],w=v[4],M=v[5],R=o.split(" "),C=parseFloat(R[0])||0,U=parseFloat(R[1])||0,F,X,K,Z;c?v!==Ph&&(X=I*P-N*E)&&(K=C*(P/X)+U*(-E/X)+(E*M-P*w)/X,Z=C*(-N/X)+U*(I/X)-(I*M-N*w)/X,C=K,U=Z):(F=Dd(a),C=F.x+(~R[0].indexOf("%")?C/100*F.width:C),U=F.y+(~(R[1]||R[0]).indexOf("%")?U/100*F.height:U)),f||f!==!1&&g.smooth?(w=C-S,M=U-b,g.xOffset=O+(w*I+M*E)-w,g.yOffset=k+(w*N+M*P)-M):g.xOffset=g.yOffset=0,g.xOrigin=C,g.yOrigin=U,g.smooth=!!f,g.origin=o,g.originIsAbsolute=!!c,a.style[Lr]="0px 0px",m&&(ea(m,g,"xOrigin",S,C),ea(m,g,"yOrigin",b,U),ea(m,g,"xOffset",O,g.xOffset),ea(m,g,"yOffset",k,g.yOffset)),a.setAttribute("data-svg-origin",C+" "+U)},Lh=function(a,o){var c=a._gsap||new pd(a);if("x"in c&&!o&&!c.uncache)return c;var f=a.style,u=c.scaleX<0,m="px",g="deg",v=getComputedStyle(a),S=qo(a,Lr)||"0",b,O,k,I,N,E,P,w,M,R,C,U,F,X,K,Z,ct,Rt,tt,_t,G,Pt,Et,At,ce,re,Ft,It,Nt,Pe,pe,Wt;return b=O=k=E=P=w=M=R=C=0,I=N=1,c.svg=!!(a.getCTM&&zd(a)),v.translate&&((v.translate!=="none"||v.scale!=="none"||v.rotate!=="none")&&(f[pn]=(v.translate!=="none"?"translate3d("+(v.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+(v.rotate!=="none"?"rotate("+v.rotate+") ":"")+(v.scale!=="none"?"scale("+v.scale.split(" ").join(",")+") ":"")+(v[pn]!=="none"?v[pn]:"")),f.scale=f.rotate=f.translate="none"),X=Uc(a,c.svg),c.svg&&(c.uncache?(ce=a.getBBox(),S=c.xOrigin-ce.x+"px "+(c.yOrigin-ce.y)+"px",At=""):At=!o&&a.getAttribute("data-svg-origin"),Gc(a,At||S,!!At||c.originIsAbsolute,c.smooth!==!1,X)),U=c.xOrigin||0,F=c.yOrigin||0,X!==Ph&&(Rt=X[0],tt=X[1],_t=X[2],G=X[3],b=Pt=X[4],O=Et=X[5],X.length===6?(I=Math.sqrt(Rt*Rt+tt*tt),N=Math.sqrt(G*G+_t*_t),E=Rt||tt?Fl(tt,Rt)*ja:0,M=_t||G?Fl(_t,G)*ja+E:0,M&&(N*=Math.abs(Math.cos(M*Nl))),c.svg&&(b-=U-(U*Rt+F*_t),O-=F-(U*tt+F*G))):(Wt=X[6],Pe=X[7],Ft=X[8],It=X[9],Nt=X[10],pe=X[11],b=X[12],O=X[13],k=X[14],K=Fl(Wt,Nt),P=K*ja,K&&(Z=Math.cos(-K),ct=Math.sin(-K),At=Pt*Z+Ft*ct,ce=Et*Z+It*ct,re=Wt*Z+Nt*ct,Ft=Pt*-ct+Ft*Z,It=Et*-ct+It*Z,Nt=Wt*-ct+Nt*Z,pe=Pe*-ct+pe*Z,Pt=At,Et=ce,Wt=re),K=Fl(-_t,Nt),w=K*ja,K&&(Z=Math.cos(-K),ct=Math.sin(-K),At=Rt*Z-Ft*ct,ce=tt*Z-It*ct,re=_t*Z-Nt*ct,pe=G*ct+pe*Z,Rt=At,tt=ce,_t=re),K=Fl(tt,Rt),E=K*ja,K&&(Z=Math.cos(K),ct=Math.sin(K),At=Rt*Z+tt*ct,ce=Pt*Z+Et*ct,tt=tt*Z-Rt*ct,Et=Et*Z-Pt*ct,Rt=At,Pt=ce),P&&Math.abs(P)+Math.abs(E)>359.9&&(P=E=0,w=180-w),I=Rn(Math.sqrt(Rt*Rt+tt*tt+_t*_t)),N=Rn(Math.sqrt(Et*Et+Wt*Wt)),K=Fl(Pt,Et),M=Math.abs(K)>2e-4?K*ja:0,C=pe?1/(pe<0?-pe:pe):0),c.svg&&(At=a.getAttribute("transform"),c.forceCSS=a.setAttribute("transform","")||!Fd(qo(a,pn)),At&&a.setAttribute("transform",At))),Math.abs(M)>90&&Math.abs(M)<270&&(u?(I*=-1,M+=E<=0?180:-180,E+=E<=0?180:-180):(N*=-1,M+=M<=0?180:-180)),o=o||c.uncache,c.x=b-((c.xPercent=b&&(!o&&c.xPercent||(Math.round(a.offsetWidth/2)===Math.round(-b)?-50:0)))?a.offsetWidth*c.xPercent/100:0)+m,c.y=O-((c.yPercent=O&&(!o&&c.yPercent||(Math.round(a.offsetHeight/2)===Math.round(-O)?-50:0)))?a.offsetHeight*c.yPercent/100:0)+m,c.z=k+m,c.scaleX=Rn(I),c.scaleY=Rn(N),c.rotation=Rn(E)+g,c.rotationX=Rn(P)+g,c.rotationY=Rn(w)+g,c.skewX=M+g,c.skewY=R+g,c.transformPerspective=C+m,(c.zOrigin=parseFloat(S.split(" ")[2])||!o&&c.zOrigin||0)&&(f[Lr]=Mu(S)),c.xOffset=c.yOffset=0,c.force3D=Hr.force3D,c.renderTransform=c.svg?Pg:Rd?Gd:Ag,c.uncache=0,c},Mu=function(a){return(a=a.split(" "))[0]+" "+a[1]},Hc=function(a,o,c){var f=or(o);return Rn(parseFloat(o)+parseFloat(ia(a,"x",c+"px",f)))+f},Ag=function(a,o){o.z="0px",o.rotationY=o.rotationX="0deg",o.force3D=0,Gd(a,o)},qa="0deg",Rh="0px",Ya=") ",Gd=function(a,o){var c=o||this,f=c.xPercent,u=c.yPercent,m=c.x,g=c.y,v=c.z,S=c.rotation,b=c.rotationY,O=c.rotationX,k=c.skewX,I=c.skewY,N=c.scaleX,E=c.scaleY,P=c.transformPerspective,w=c.force3D,M=c.target,R=c.zOrigin,C="",U=w==="auto"&&a&&a!==1||w===!0;if(R&&(O!==qa||b!==qa)){var F=parseFloat(b)*Nl,X=Math.sin(F),K=Math.cos(F),Z;F=parseFloat(O)*Nl,Z=Math.cos(F),m=Hc(M,m,X*Z*-R),g=Hc(M,g,-Math.sin(F)*-R),v=Hc(M,v,K*Z*-R+R)}P!==Rh&&(C+="perspective("+P+Ya),(f||u)&&(C+="translate("+f+"%, "+u+"%) "),(U||m!==Rh||g!==Rh||v!==Rh)&&(C+=v!==Rh||U?"translate3d("+m+", "+g+", "+v+") ":"translate("+m+", "+g+Ya),S!==qa&&(C+="rotate("+S+Ya),b!==qa&&(C+="rotateY("+b+Ya),O!==qa&&(C+="rotateX("+O+Ya),(k!==qa||I!==qa)&&(C+="skew("+k+", "+I+Ya),(N!==1||E!==1)&&(C+="scale("+N+", "+E+Ya),M.style[pn]=C||"translate(0, 0)"},Pg=function(a,o){var c=o||this,f=c.xPercent,u=c.yPercent,m=c.x,g=c.y,v=c.rotation,S=c.skewX,b=c.skewY,O=c.scaleX,k=c.scaleY,I=c.target,N=c.xOrigin,E=c.yOrigin,P=c.xOffset,w=c.yOffset,M=c.forceCSS,R=parseFloat(m),C=parseFloat(g),U,F,X,K,Z;v=parseFloat(v),S=parseFloat(S),b=parseFloat(b),b&&(b=parseFloat(b),S+=b,v+=b),v||S?(v*=Nl,S*=Nl,U=Math.cos(v)*O,F=Math.sin(v)*O,X=Math.sin(v-S)*-k,K=Math.cos(v-S)*k,S&&(b*=Nl,Z=Math.tan(S-b),Z=Math.sqrt(1+Z*Z),X*=Z,K*=Z,b&&(Z=Math.tan(b),Z=Math.sqrt(1+Z*Z),U*=Z,F*=Z)),U=Rn(U),F=Rn(F),X=Rn(X),K=Rn(K)):(U=O,K=k,F=X=0),(R&&!~(m+"").indexOf("px")||C&&!~(g+"").indexOf("px"))&&(R=ia(I,"x",m,"px"),C=ia(I,"y",g,"px")),(N||E||P||w)&&(R=Rn(R+N-(N*U+E*X)+P),C=Rn(C+E-(N*F+E*K)+w)),(f||u)&&(Z=I.getBBox(),R=Rn(R+f/100*Z.width),C=Rn(C+u/100*Z.height)),Z="matrix("+U+","+F+","+X+","+K+","+R+","+C+")",I.setAttribute("transform",Z),M&&(I.style[pn]=Z)},Lg=function(a,o,c,f,u){var m=360,g=Wn(u),v=parseFloat(u)*(g&&~u.indexOf("rad")?ja:1),S=v-f,b=f+S+"deg",O,k;return g&&(O=u.split("_")[1],O==="short"&&(S%=m,S!==S%(m/2)&&(S+=S<0?m:-m)),O==="cw"&&S<0?S=(S+m*bd)%m-~~(S/m)*m:O==="ccw"&&S>0&&(S=(S-m*bd)%m-~~(S/m)*m)),a._pt=k=new Ar(a._pt,o,c,f,S,dg),k.e=b,k.u="deg",a._props.push(c),k},Hd=function(a,o){for(var c in o)a[c]=o[c];return a},Rg=function(a,o,c){var f=Hd({},c._gsap),u="perspective,force3D,transformOrigin,svgOrigin",m=c.style,g,v,S,b,O,k,I,N;f.svg?(S=c.getAttribute("transform"),c.setAttribute("transform",""),m[pn]=o,g=Lh(c,1),Xa(c,pn),c.setAttribute("transform",S)):(S=getComputedStyle(c)[pn],m[pn]=o,g=Lh(c,1),m[pn]=S);for(v in ps)S=f[v],b=g[v],S!==b&&u.indexOf(v)<0&&(I=or(S),N=or(b),O=I!==N?ia(c,v,S,N):parseFloat(S),k=parseFloat(b),a._pt=new Ar(a._pt,g,v,O,k-O,kc),a._pt.u=N||0,a._props.push(v));Hd(g,f)};Cr("padding,margin,Width,Radius",function(x,a){var o="Top",c="Right",f="Bottom",u="Left",m=(a<3?[o,c,f,u]:[o+u,o+c,f+c,f+u]).map(function(g){return a<2?x+g:"border"+g+x});Tu[a>1?"border"+x:x]=function(g,v,S,b,O){var k,I;if(arguments.length<4)return k=m.map(function(N){return ms(g,N,S)}),I=k.join(" "),I.split(k[0]).length===5?k[0]:I;k=(b+"").split(" "),I={},m.forEach(function(N,E){return I[N]=k[E]=k[E]||k[(E-1)/2|0]}),g.init(v,I,O)}});var Vd={name:"css",register:Nc,targetTest:function(a){return a.style&&a.nodeType},init:function(a,o,c,f,u){var m=this._props,g=a.style,v=c.vars.startAt,S,b,O,k,I,N,E,P,w,M,R,C,U,F,X,K;Ic||Nc(),this.styles=this.styles||Ld(a),K=this.styles.props,this.tween=c;for(E in o)if(E!=="autoRound"&&(b=o[E],!(Wr[E]&&md(E,o,c,f,a,u)))){if(I=typeof b,N=Tu[E],I==="function"&&(b=b.call(c,f,a,u),I=typeof b),I==="string"&&~b.indexOf("random(")&&(b=Mh(b)),N)N(this,a,E,b,c)&&(X=1);else if(E.substr(0,2)==="--")S=(getComputedStyle(a).getPropertyValue(E)+"").trim(),b+="",Ks.lastIndex=0,Ks.test(S)||(P=or(S),w=or(b)),w?P!==w&&(S=ia(a,E,S,w)+w):P&&(b+=P),this.add(g,"setProperty",S,b,f,u,0,0,E),m.push(E),K.push(E,0,g[E]);else if(I!=="undefined"){if(v&&E in v?(S=typeof v[E]=="function"?v[E].call(c,f,a,u):v[E],Wn(S)&&~S.indexOf("random(")&&(S=Mh(S)),or(S+"")||S==="auto"||(S+=Hr.units[E]||or(ms(a,E))||""),(S+"").charAt(1)==="="&&(S=ms(a,E))):S=ms(a,E),k=parseFloat(S),M=I==="string"&&b.charAt(1)==="="&&b.substr(0,2),M&&(b=b.substr(2)),O=parseFloat(b),E in Xo&&(E==="autoAlpha"&&(k===1&&ms(a,"visibility")==="hidden"&&O&&(k=0),K.push("visibility",0,g.visibility),ea(this,g,"visibility",k?"inherit":"hidden",O?"inherit":"hidden",!O)),E!=="scale"&&E!=="transform"&&(E=Xo[E],~E.indexOf(",")&&(E=E.split(",")[0]))),R=E in ps,R){if(this.styles.save(E),C||(U=a._gsap,U.renderTransform&&!o.parseTransform||Lh(a,o.parseTransform),F=o.smoothOrigin!==!1&&U.smooth,C=this._pt=new Ar(this._pt,g,pn,0,1,U.renderTransform,U,0,-1),C.dep=1),E==="scale")this._pt=new Ar(this._pt,U,"scaleY",U.scaleY,(M?Ol(U.scaleY,M+O):O)-U.scaleY||0,kc),this._pt.u=0,m.push("scaleY",E),E+="X";else if(E==="transformOrigin"){K.push(Lr,0,g[Lr]),b=bg(b),U.svg?Gc(a,b,0,F,0,this):(w=parseFloat(b.split(" ")[2])||0,w!==U.zOrigin&&ea(this,U,"zOrigin",U.zOrigin,w),ea(this,g,E,Mu(S),Mu(b)));continue}else if(E==="svgOrigin"){Gc(a,b,1,F,0,this);continue}else if(E in Nd){Lg(this,U,E,k,M?Ol(k,M+b):b);continue}else if(E==="smoothOrigin"){ea(this,U,"smooth",U.smooth,b);continue}else if(E==="force3D"){U[E]=b;continue}else if(E==="transform"){Rg(this,b,a);continue}}else E in g||(E=Ul(E)||E);if(R||(O||O===0)&&(k||k===0)&&!fg.test(b)&&E in g)P=(S+"").substr((k+"").length),O||(O=0),w=or(b)||(E in Hr.units?Hr.units[E]:P),P!==w&&(k=ia(a,E,S,w)),this._pt=new Ar(this._pt,R?U:g,E,k,(M?Ol(k,M+O):O)-k,!R&&(w==="px"||E==="zIndex")&&o.autoRound!==!1?mg:kc),this._pt.u=w||0,P!==w&&w!=="%"&&(this._pt.b=S,this._pt.r=pg);else if(E in g)Eg.call(this,a,E,S,M?M+b:b);else if(E in a)this.add(a,E,S||a[E],M?M+b:b,f,u);else if(E!=="parseTransform"){uc(E,b);continue}R||(E in g?K.push(E,0,g[E]):K.push(E,1,S||a[E])),m.push(E)}}X&&wd(this)},render:function(a,o){if(o.tween._time||!Dc())for(var c=o._pt;c;)c.r(a,c.d),c=c._next;else o.styles.revert()},get:ms,aliases:Xo,getSetter:function(a,o,c){var f=Xo[o];return f&&f.indexOf(",")<0&&(o=f),o in ps&&o!==Lr&&(a._gsap.x||ms(a,"x"))?c&&Ed===c?o==="scale"?_g:yg:(Ed=c||{})&&(o==="scale"?xg:wg):a.style&&!rc(a.style[o])?gg:~o.indexOf("-")?vg:Ac(a,o)},core:{_removeProperty:Xa,_getMatrix:Uc}};Pr.utils.checkPrefix=Ul,Pr.core.getStyleSaver=Ld,function(x,a,o,c){var f=Cr(x+","+a+","+o,function(u){ps[u]=1});Cr(a,function(u){Hr.units[u]="deg",Nd[u]=1}),Xo[f[13]]=x+","+a,Cr(c,function(u){var m=u.split(":");Xo[m[1]]=f[m[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"),Cr("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(x){Hr.units[x]="px"}),Pr.registerPlugin(Vd);var Vc=Pr.registerPlugin(Vd)||Pr;Vc.core.Tween;class Og{constructor(a,o=!1){window.mars3d&&(this.Cesium=window.mars3d.Cesium,this.DynamicMaskingArr=[],this.DynamicMaskingStyle=[],this.canvasClientWidth=a.viewer.canvas.clientWidth,this.canvasClientHeight=a.viewer.canvas.clientHeight,this.oldSet=new Set,this.tweenMap=new Map,this.isDynamicMasking=o)}add(a,o){let c=a.options.symbol.styleOptions.label.font_size,f=a.options.vectorId,u=Number(c)*1.4,m=Number(c)*1.8,g=a.options.symbol.styleOptions.label,{color:v,outlineColor:S,backgroundColor:b}=g;a.eachGraphic(O=>{O.style.label&&this.DynamicMaskingArr.push({id:f,uid:O.id,position:O._getLablePosition(),label:O.name,width:O.name?u*O.name.length:0,height:m,color:v,outline:o.label.outline,outlineColor:S,background:o.label.background,backgroundColor:b,dynamicMaskingColor:{backgroundColor:this.Cesium.Color.fromCssColorString(o.label.backgroundColor),color:this.Cesium.Color.fromCssColorString(o.label.color),outlineColor:this.Cesium.Color.fromCssColorString(o.label.outlineColor)}})}),this.DynamicMaskingStyle.push({vectorId:a.options.vectorId,outline:o.label.outline,background:o.label.background,color:this.Cesium.Color.fromCssColorString(o.label.color),backgroundColor:this.Cesium.Color.fromCssColorString(o.label.backgroundColor),outlineColor:this.Cesium.Color.fromCssColorString(o.label.outlineColor)}),this.oldSet=new Set,this.tweenMap=new Map}remove(a){this.DynamicMaskingArr=this.DynamicMaskingArr.filter(o=>o.id!==a),this.DynamicMaskingStyle=this.DynamicMaskingStyle.filter(o=>o.vectorId!==a),this.oldSet=new Set,this.tweenMap=new Map}modify(a,o){let{label:c}=o;if(c){let{color:f,outline:u,outlineColor:m,background:g,backgroundColor:v}=c;this.DynamicMaskingArr.forEach(S=>{S.id===a&&(f!=null&&(S.color=this.Cesium.Color.fromCssColorString(f),S.dynamicMaskingColor.color=this.Cesium.Color.fromCssColorString(f)),u!=null&&(S.outline=u),m!=null&&(S.outlineColor=this.Cesium.Color.fromCssColorString(m),S.dynamicMaskingColor.outlineColor=this.Cesium.Color.fromCssColorString(m)),g!=null&&(S.background=g),v!=null&&(S.backgroundColor=this.Cesium.Color.fromCssColorString(v),S.dynamicMaskingColor.backgroundColor=this.Cesium.Color.fromCssColorString(v)))})}}getBoundingRectangle(a){var o=this.Cesium.SceneTransforms.wgs84ToWindowCoordinates(window.map.viewer.scene,a.position);return o!==void 0?new this.Cesium.BoundingRectangle(o.x,o.y,a.width,a.height):new this.Cesium.BoundingRectangle(0,0,1,1)}getNonIntersectingRectangles(){let a=[];for(var o=0;o<this.DynamicMaskingArr.length;o++){let f=!1,u=this.DynamicMaskingArr[o],m,g,v;if(g=this.getBoundingRectangle(u),!(g.x<0||g.x>this.canvasClientWidth||g.y<0||g.y>this.canvasClientHeight))if(a.length===0){a.push(o);continue}else{for(var c=0;c<a.length;c++)if(m=this.DynamicMaskingArr[a[c]],v=this.getBoundingRectangle(m),this.Cesium.Intersect.OUTSIDE!==this.Cesium.BoundingRectangle.intersect(g,v)){f=!0;break}f||a.push(o)}}return new Set(a)}ifShow(){if(this.isDynamicMasking){let o={color:.001,outlineColor:.001,backgroundColor:.001},c={color:1,outlineColor:1,backgroundColor:1},f=this.getNonIntersectingRectangles(),u=new Set([...this.oldSet].filter(g=>!f.has(g))),m=new Set([...f].filter(g=>!this.oldSet.has(g)));for(let g of u)if(this.DynamicMaskingArr[g]){if(this.tweenMap.has(g)){var a=this.tweenMap.get(g);a.kill(),this.tweenMap.delete(g)}var a=Vc.to(c,{duration:.2,color:0,outlineColor:0,backgroundColor:0,onUpdate:()=>{var S,b;var v=this.DynamicMaskingArr[g];v.backgroundColor.alpha=c.backgroundColor,v.color.alpha=c.color,v.outlineColor.alpha=c.outlineColor,(b=(S=window.map.getLayer(v.id,"vectorId"))==null?void 0:S.getGraphicByAttr(v.uid))==null||b.setStyle({label:{show:!1,outline:!1,background:!1}})}});this.tweenMap.set(g,a)}for(let g of m)if(this.DynamicMaskingArr[g]){if(this.tweenMap.has(g)){var a=this.tweenMap.get(g);a.kill(),this.tweenMap.delete(g)}let v=this.DynamicMaskingArr[g],{backgroundColor:S,color:b,outlineColor:O}=v.dynamicMaskingColor;var a=Vc.to(o,{duration:.8+Math.random(),color:b.alpha,outlineColor:O.alpha,backgroundColor:S.alpha,onUpdate:()=>{var I,N;v.backgroundColor.alpha=o.backgroundColor,v.color.alpha=o.color,v.outlineColor.alpha=o.outlineColor,(N=(I=window.map.getLayer(v.id,"vectorId"))==null?void 0:I.getGraphicByAttr(v.uid))==null||N.setStyle({label:{show:!0,outline:v.outline,background:v.background,color:v.color,outlineColor:v.outlineColor,backgroundColor:v.backgroundColor}})}});this.tweenMap.set(g,a)}this.oldSet=f}}switchDynamicMasking(a){if(a)window.map.getLayers().forEach(o=>{var c;if((c=o.options)!=null&&c.vectorId){let{color:f,outlineColor:u,backgroundColor:m}=o.options.symbol.styleOptions.label;o.eachGraphic(g=>{g.setStyle({label:{color:f.withAlpha(0),outlineColor:u.withAlpha(.001),backgroundColor:m.withAlpha(.001),show:!1,background:!1,outline:!1}})})}});else if(this.DynamicMaskingStyle.length>0){let o;this.DynamicMaskingStyle.forEach(c=>{let{color:f,outline:u,outlineColor:m,background:g,backgroundColor:v,vectorId:S}=c;o=window.map.getLayer(S,"vectorId"),o&&o.eachGraphic(b=>{b.setStyle({label:{color:f,outlineColor:m,backgroundColor:v,show:!0,background:g,outline:u}})})})}this.isDynamicMasking=a,window.bimVector.switchDynamicMasking(a)}}const Ig=()=>{var x,a;window.planClip.clearPlanClip(),window.schemeEvnModify.clearAllEvnModify(),window.bimRotatePoint.stop(),window.bimTrafficSimulation.destruction(),window.bimMapPTV&&window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.bimMapCompare.hide?window.bimMapCompare.hide():window.bimMapCompare.destroyControl(),window.updateEitor({content:""}),(a=(x=window.glftSet)==null?void 0:x.glftList)==null||a.map(o=>{o.remove()})},Dg=()=>{var x,a;window.planClip.clearPlanClip(),window.bimRotatePoint.stop(),window.bimTrafficSimulation.destruction(),window.bimMapPTV&&window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.bimMapCompare.hide?window.bimMapCompare.hide():window.bimMapCompare.destroyControl(),window.updateEitor({content:""}),(a=(x=window.glftSet)==null?void 0:x.glftList)==null||a.map(o=>{o.remove()})},zg=()=>{var x,a;window.planClip.clearPlanClip(),window.bimRotatePoint.stop(),window.bimTrafficSimulation.destruction(),window.bimMapPTV&&window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.bimMapCompare.hide?window.bimMapCompare.hide():window.bimMapCompare.destroyControl(),window.updateEitor({content:""}),(a=(x=window.glftSet)==null?void 0:x.glftList)==null||a.map(o=>{o.remove()})},kg=x=>{let a=[];if(x.forEach(o=>{let{id:c}=o,f={id:c,mockData:{nextPage:[],item:[],previousPage:[]}};o.operate.forEach((u,m)=>{let g=Wc(u,f.mockData.nextPage);f.mockData.nextPage=g,f.mockData.item=g,f.mockData.previousPage=[]}),a.push(f)}),a.length>1)for(let o=1;o<a.length;o++){let c=a[o].mockData,f=a[o-1].mockData.item;const u=new Map;f.forEach(m=>{m.type!="rotatePoint"&&m.type!="viewpoint"&&m.type!="roaming"&&m.type!="splitScreen"&&m.type!="planClip"&&m.type!="editor"&&m.type!="gltf"?u.set(`${m.screenplayId}-${m.type}`,m):a[o].mockData.previousPage.push(m)}),c.nextPage.forEach(m=>{const g=`${m.screenplayId}-${m.type}`;let v={...u.get(g)};if(u.has(g)){if(m.type=="flight")a[o].mockData.previousPage.unshift(u.get(g)),v=m;else{let S={};Object.keys(m).forEach(b=>{if(b!="screenplayId"&&b!="type")if(u.get(g)[b])if(Object.keys(S).length==0&&(S={screenplayId:m.screenplayId,type:m.type}),b=="clip"||b=="flat"){v[b]=Wd(u.get(g)[b],m[b]);let O={screenplayId:m.screenplayId,type:m.type};O[b]={},Object.keys(m[b]).forEach(k=>{u.get(g)[b][k]?O[b][k]=u.get(g)[b][k]:m[b][k]=="true"&&(O[b][k]="false")}),S={...O,...S}}else S[b]=u.get(g)[b],v[b]=m[b];else a[o].mockData.previousPage.some(O=>O.screenplayId===m.screenplayId)||(S={...jd(m,b),...S}),v[b]=m[b]}),Object.keys(S).length>0&&a[o].mockData.previousPage.push(S)}u.set(g,v)}else{let S=jd(m);S&&a[o].mockData.previousPage.push(S),u.set(g,m)}}),a[o].mockData.item=Array.from(u.values())}return a},Wc=(x,a=null)=>{let{executionProperty:o,screenplayId:c,property:f,type:u,delay:m,delayTime:g}=x;if((f=="add"||f==!0)&&(f="true"),(f=="remove"||f==!1)&&(f="false"),u=="pit"){let S=window.schemeEvnModify.getModelModifyDataForInitModelById(c);if(S){let b={};b[c]=f,f=b,c=S.modelId,o=S.type}}let v;if(c==""||c=="map")if(c="map",u=="splitScreen"){let{splitScreenMode:S,splitScreenModePercentage:b}=JSON.parse(f);a.push({screenplayId:c,type:u,executionProperty:{splitScreenMode:S,splitScreenModePercentage:b,mapClone:[]}});let{mainScreen:O,secondaryScreen:k}=JSON.parse(x.property);O.forEach(N=>{Wc(N,a)});let I=a.find(N=>N.type=="splitScreen");k.forEach(N=>{Wc(N,I.executionProperty.mapClone)})}else v={screenplayId:c,type:u,executionProperty:f},(o=="clip"||o=="flat")&&(v[o]=f),m&&(v.delay=m),g&&(v.delayTime=g),a&&(u=="flight"?a.unshift(v):a.push(v));else v=a?a.find(S=>S.screenplayId==c):null,v?(o=="clip"||o=="flat"?v[o]?v[o]=Wd(v[o],f):(v[o]=f,v.type="model"):v[o]=f,m&&(v[o].delay=m),g&&(v[o].delayTime=g)):(v={screenplayId:c,type:u},m&&(v.delay=m),g&&(v.delayTime=g),o=="clip"||o=="flat"?(v[o]=f,v.type="model"):v[o]=f,a&&(u=="flight"?a.unshift(v):a.push(v)));return a||v},Wd=(x,a)=>{const o={...x};for(const c in a)a.hasOwnProperty(c)&&(o[c]=a[c]);return o},jd=(x,a="all")=>{let{type:o,show:c,screenplayId:f,overallStaining:u,clip:m,flat:g}=x,v={};if(a=="all")switch(o){case"model":case"shp":case"plot":c&&c=="true"&&(v={screenplayId:f,type:o,show:"false"}),u&&(v={...v,screenplayId:f,type:o,overallStaining:"false"}),m&&(v={...v,screenplayId:f,type:o,clip:"false"}),g&&(v={...v,screenplayId:f,type:o,flat:"false"});break;case"terrain":v={screenplayId:f,type:o,executionProperty:"true"};break;case"pit":v={screenplayId:f,type:o,executionProperty:"false"};break;case"underground":v={screenplayId:f,type:o,executionProperty:"1"};break}else switch(a){case"clip":case"flat":case"overallStaining":v={screenplayId:f,type:o},v[a]="false";break}return Object.keys(v).length>0?v:null},Bg=(x,a)=>{const o={};return Object.keys(a).forEach(c=>{x.hasOwnProperty(c)&&(o[c]=x[c])}),o},Ng=x=>/^rgba\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*,\s*(0|1|0\.\d+)\s*\)$/i.test(x),Fg=x=>{let a={};(x==null?void 0:x.length)>0&&x[0].operate.forEach(o=>{let{executionProperty:c,screenplayId:f,property:u,type:m}=o;(c=="show"||c=="overallStaining")&&(a[f]||(a[f]={type:m}),a[f][u]=c)}),window.map.getLayers().forEach(o=>{if((o.type=="3dtiles"||o.type=="geojson"||o.type=="tileset")&&o.options.name!="国界"){let c=o.options.modelId||o.options.vectorId;a[c]?(window.bimModel.editColor(c),window.schemeEvnModify.clearAllModelModify({isClone:!1})):o.remove()}}),window.bimEntity.entityLayer.getGraphicsByAttr().forEach(o=>{o.remove()}),window.bimMapSetUp.undergroundVal(1),window.bimTerrainProvider.show(),window.bimTrafficSimulation.destruction(),window.bimRotatePoint.stop(),window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.planClip.clearPlanClip()};class Ug{constructor(a){Ho(this,"getPositions",a=>a.length>1&&(Array.isArray(a[0])||typeof a[0]=="object")?a:this.getPositions(a[0]));Ho(this,"terrainCutById",(a,o,c)=>{switch(c==null?void 0:c.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainClipClone||this.terrainClipClone.list.find(f=>f.id==o))return;this.terrainClipClone.addArea(a.length>1?a:a[0],{id:o});break;case!1:if(!this.terrainClip||this.terrainClip.list.find(f=>f.id==o))return;this.terrainClip.addArea(a.length>1?a:a[0],{id:o});break}});Ho(this,"clearTerrainCutById",(a,o)=>{switch(o==null?void 0:o.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainClipClone)return;this.terrainClipClone.removeArea(a);break;case!1:if(!this.terrainClip)return;this.terrainClip.removeArea(a);break}});Ho(this,"terrainFlattenById",(a,o,c,f)=>{switch(f==null?void 0:f.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainFlatClone||this.terrainFlatClone.list.find(u=>u.id==c))return;this.terrainFlatClone.addArea(a.length>1?a:a[0],{id:c,height:o});break;case!1:if(!this.terrainFlat||this.terrainFlat.list.find(u=>u.id==c))return;this.terrainFlat.addArea(a.length>1?a:a[0],{id:c,height:o});break}});Ho(this,"clearTerrainFlattenById",(a,o)=>{switch(o==null?void 0:o.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainFlatClone)return;this.terrainFlatClone.removeArea(a);break;case!1:if(!this.terrainFlat)return;this.terrainFlat.removeArea(a);break}});this.flattenedEvnModifyData=a,this.modelIdListByModify=[],this.modelIdListByModifyClone=[],this.terrainClip=null,this.terrainFlat=null,this.terrainClipClone=null,this.terrainFlatClone=null,this.createTerrainModifyInstance()}getDataFromFlattenedEvnModifyListById(a){const o=this.flattenedEvnModifyData.find(c=>c.id==a);return o||null}getModelFromMapById(a,o){let c;switch(o==null?void 0:o.isClone){case!0:c=window.mapClone?window.mapClone.mapEx.getLayers():[];break;case!1:c=window.map.getLayers();break}return c.find(u=>u.options.modelId==a)}updateFlattenedEvnModifyData(a){this.flattenedEvnModifyData=a}modelCutById(a,o,c,f){const u=bimModel.queryModel(a,f);if(u&&!u.clip.list.find(m=>m.id==c))switch(u.clip.addArea(o.length>1?o:o[0],{id:c}),f==null?void 0:f.isClone){case!0:this.modelIdListByModifyClone.push(a),this.modelIdListByModifyClone=[...new Set(this.modelIdListByModifyClone)];break;case!1:this.modelIdListByModify.push(a),this.modelIdListByModify=[...new Set(this.modelIdListByModify)];break}}modelFlattenById(a,o,c,f,u){const m=bimModel.queryModel(a,u);if(m&&!m.flat.list.find(g=>g.id==f))switch(m.flat.addArea(o.length>1?o:o[0],{height:c,id:f}),u==null?void 0:u.isClone){case!0:this.modelIdListByModifyClone.push(a),this.modelIdListByModifyClone=[...new Set(this.modelIdListByModifyClone)];break;case!1:this.modelIdListByModify.push(a),this.modelIdListByModify=[...new Set(this.modelIdListByModify)];break}}clearModelCutById(a,o,c){const f=bimModel.queryModel(a,c);if(f)switch(f.clip.removeArea(o),c.isClone){case!0:this.modelIdListByModifyClone=this.modelIdListByModifyClone.filter(u=>u!=a);break;case!1:this.modelIdListByModify=this.modelIdListByModify.filter(u=>u!=a);break}}clearModelFlattenById(a,o,c){const f=bimModel.queryModel(a,c);if(f)switch(f.flat.removeArea(o),c==null?void 0:c.isClone){case!0:this.modelIdListByModifyClone=this.modelIdListByModifyClone.filter(u=>u!=a);break;case!1:this.modelIdListByModify=this.modelIdListByModify.filter(u=>u!=a);break}}createTerrainModifyInstance(){if(window.map.thing.terrainClip)this.terrainClip=window.map.thing.terrainClip;else{const a=new mars3d.thing.TerrainClip({czm:!1,splitNum:30});window.map.addThing(a),this.terrainClip=a}if(window.map.thing.terrainFlat)this.terrainFlat=window.map.thing.terrainFlat;else{const a=new mars3d.thing.TerrainFlat({splitNum:80});window.map.addThing(a),this.terrainFlat=a}}createTerrainModifyInstanceClone(){if(window.mapClone){if(window.mapClone.mapEx.thing.terrainClip)this.terrainClipClone=window.mapClone.mapEx.thing.terrainClip;else{const a=new mars3d.thing.TerrainClip({splitNum:80});window.mapClone.mapEx.addThing(a),this.terrainClipClone=a}if(window.mapClone.mapEx.thing.terrainFlat)this.terrainFlatClone=window.mapClone.mapEx.thing.terrainFlat;else{const a=new mars3d.thing.TerrainFlat({splitNum:80});window.mapClone.mapEx.addThing(a),this.terrainFlatClone=a}}}evnModifyById(a,o){o=arguments[1]||{isClone:!1};const c=this.getDataFromFlattenedEvnModifyListById(a);if(!c)return;const{bimEnvModify:{embsId:f,dataType:u,modifyType:m}}=c;for(let g=0;g<c.bimEnvModifyData.length;g++){const v=this.getPositions(JSON.parse(c.bimEnvModifyData[g].modifyData).coordinates),S=JSON.parse(c.bimEnvModifyData[g].modifyData).depth,b=c.bimEnvModifyData[g].id;u===0&&m===0?this.modelCutById(f,v,b,o):u===0&&m===1?this.modelFlattenById(f,v,S,b,o):u===1&&m===0?this.terrainCutById(v,b,o):u===1&&m===1&&this.terrainFlattenById(v,S,b,o)}}evnModifyByIdAndAddOptionsToStore(a,o){o=arguments[1]||{isClone:!1};const c=this.getDataFromFlattenedEvnModifyListById(a);if(!c)return;const{bimEnvModify:{embsId:f,dataType:u,modifyType:m}}=c;for(let g=0;g<c.bimEnvModifyData.length;g++){const v=this.getPositions(JSON.parse(c.bimEnvModifyData[g].modifyData).coordinates),S=JSON.parse(c.bimEnvModifyData[g].modifyData).depth,b=c.bimEnvModifyData[g].id;u===0&&m===0?this.modelCutById(f,v,b,o):u===0&&m===1?this.modelFlattenById(f,v,S,b,o):u===1&&m===0?this.terrainCutById(v,b,o):u===1&&m===1&&this.terrainFlattenById(v,S,b,o)}}clearEvnModifyById(a,o){o=arguments[1]||{isClone:!1};const c=this.getDataFromFlattenedEvnModifyListById(a);if(!c)return;const{bimEnvModify:{embsId:f,dataType:u,modifyType:m}}=c;for(let g=0;g<c.bimEnvModifyData.length;g++){const v=c.bimEnvModifyData[g].id;u===0&&m===0?this.clearModelCutById(f,v,o):u===0&&m===1?this.clearModelFlattenById(f,v,o):u===1&&m===0?this.clearTerrainCutById(v,o):u===1&&m===1&&this.clearTerrainFlattenById(v,o)}}clearAllModelModify(a){switch(a||(a={isClone:!1}),a.isClone){case!0:this.modelIdListByModifyClone.forEach(o=>{const c=bimModel.queryModel(o,a);c&&(c.clip.clear(),c.flat.clear())}),this.modelIdListByModifyClone=[];break;case!1:this.modelIdListByModify.forEach(o=>{const c=bimModel.queryModel(o,a);c&&(c.clip.clear(),c.flat.clear())}),this.modelIdListByModify=[];break}}clearAllTerrainModify(a){switch(a||(a={isClone:!1}),a.isClone){case!0:window.mapClone||(this.terrainClipClone=null,this.terrainFlatClone=null),this.terrainClipClone&&this.terrainClipClone.clear(),this.terrainFlatClone&&this.terrainFlatClone.clear();break;case!1:this.terrainClip&&this.terrainClip.clear(),this.terrainFlat&&this.terrainFlat.clear();break}}getModelModifyDataForInitModelById(a){const o=this.getDataFromFlattenedEvnModifyListById(a);if(!o)return;const{bimEnvModify:{embsId:c,dataType:f,modifyType:u}}=o;if(this.modelIdListByModify.push(c),f===0&&u===0){const m={modelId:c,type:"clip",area:[]};for(let g=0;g<o.bimEnvModifyData.length;g++){const S={positions:this.getPositions(JSON.parse(o.bimEnvModifyData[g].modifyData).coordinates),id:o.bimEnvModifyData[g].id};m.area.push(S)}return m}else if(f===0&&u===1){const m={modelId:c,type:"flat",area:[]};for(let g=0;g<o.bimEnvModifyData.length;g++){const v=this.getPositions(JSON.parse(o.bimEnvModifyData[g].modifyData).coordinates),S={id:o.bimEnvModifyData[g].id,positions:v,height:JSON.parse(o.bimEnvModifyData[g].modifyData).depth};return m.area.push(S),m}}}clearAllEvnModify(){this.clearAllModelModify({isClone:!0}),this.clearAllModelModify({isClone:!1}),this.clearAllTerrainModify({isClone:!0}),this.clearAllTerrainModify({isClone:!1})}destroyTerrainModifyInstance(){this.clearAllTerrainModify({isClone:!0}),this.clearAllTerrainModify({isClone:!1}),this.terrainClip&&window.map.removeThing(this.terrainClip,!0),this.terrainFlat&&window.map.removeThing(this.terrainFlat,!0),this.terrainClipClone&&window.mapClone.mapEx.removeThing(this.terrainClipClone,!0),this.terrainFlatClone&&window.mapClone.mapEx.removeThing(this.terrainFlatClone,!0),this.terrainClip=null,this.terrainFlat=null,this.terrainClipClone=null,this.terrainFlatClone=null}}let Gl=null,gs=null,na=null;class Gg{constructor(){mars3d&&(this.projectId=parseInt(window.sessionStorage.getItem("nowProjectId")),this.viewPoints=new Array,this.roaming=null)}init(a,o,c){gs=new mars3d.layer.GraphicLayer({isContinued:!0});var f=this;window.map.addLayer(gs),gs.on(mars3d.EventType.drawCreated,function(u){var m=u.graphic.point;o(m),setTimeout(()=>{f.startDrawGraphic()},500)}),gs.on(mars3d.EventType.editStop,function(u){}),na=c,Gl=new mars3d.layer.GraphicLayer,window.map.addLayer(Gl),a&&(this.viewPoints=a.filter((u,m)=>{if(m%(na.smooth*1)==0)return u})),this.addGraphicLayer(this.viewPoints)}addDemoGraphic1(a,o){const c=new mars3d.graphic.PolylinePrimitive({positions:a.map(f=>[f.lng,f.lat,f.alt+1e3]),style:{width:10,materialType:mars3d.MaterialType.LineFlow,materialOptions:{color:"red",image:o+"img/line/line-arrow-blue.png",speed:10,repeat:new Cesium.Cartesian2(5,1),mixt:!0}}});Gl.addGraphic(c)}addGraphicLayer(a){var o={};na.Viewovalue==1?o={camera:{type:"dy",followedX:na.followedX,followedZ:na.followedZ},interpolation:!0,interpolationDegree:6,autoMiddleDynamicPosition:!0,interpolationAlgorithm:Cesium.HermitePolynomialApproximation}:na.Viewovalue==2?o={camera:{type:"gs",pitch:-30,radius:500},interpolation:!0,interpolationDegree:2,clockLoop:!0,path:{width:3,color:Cesium.Color.fromCssColorString("#ff0000").withAlpha(.5)}}:o={camera:{type:"sd",followedZ:na.followedZ},polyline:{width:3,color:Cesium.Color.fromCssColorString("#ff0000").withAlpha(.5)}},a=a.map(c=>[c.lng,c.lat,c.alt]),a.length,this.fixedRoute=new mars3d.graphic.FixedRoute({name:"贴地表表面漫游",speed:na.speed,autoStop:!0,positions:a,offsetHeight:1.6,clockLoop:!0,...o}),Gl.addGraphic(this.fixedRoute)}addDemoGraphic(a,o){const c=new mars3d.graphic.BillboardEntity({position:new mars3d.LngLatPoint(a.lng,a.lat,a.alt),style:{width:30,height:32,image:"/img/marker/markffd700.png",scale:1,scaleByDistance:!1,scaleByDistance_far:1e6,scaleByDistance_farValue:.1,scaleByDistance_near:1e3,scaleByDistance_nearValue:1,distanceDisplayCondition:!1,distanceDisplayCondition_far:2e6,distanceDisplayCondition_near:0,clampToGround:!1,visibleDepth:!1,drawShow:!0}});gs.addGraphic(c)}startDrawGraphic(a){gs.startDraw({type:"billboard",style:{width:30,height:32,image:"/img/marker/markffd700.png",scale:1,scaleByDistance:!1,scaleByDistance_far:1e6,scaleByDistance_farValue:.1,scaleByDistance_near:1e3,scaleByDistance_nearValue:1,distanceDisplayCondition:!1,distanceDisplayCondition_far:2e6,distanceDisplayCondition_near:0,clampToGround:!1,visibleDepth:!1,drawShow:!0,classificationType:Cesium.ClassificationType.TERRAIN}}).then(o=>{})}start(){this.fixedRoute&&(this.fixedRoute.start(),window.map.scene.screenSpaceCameraController.enableCollisionDetection=!1)}pause(){this.fixedRoute&&this.fixedRoute.pause()}resume(){this.fixedRoute&&this.fixedRoute.proceed()}stop(){this.fixedRoute&&this.fixedRoute.stop()}remove(){this.fixedRoute&&this.fixedRoute.stop(),window.map.removeThing(this.roaming,!0),window.map.removeLayer(Gl,!0),window.map.removeLayer(gs,!0),this.viewPoints=[],window.map.scene.screenSpaceCameraController.enableCollisionDetection=!0}removeCameraRoute(){Gl.clear(),gs.clear()}removegraphicLayerpoint(){gs.clear()}}class Hg{constructor(a){window.mars3d&&(this.beginDate="",this.endDate="",this.trafficSimulationLayer,this.trafficSimulationArr=[],this.style={width:4,materialType:window.mars3d.MaterialType.LineFlow,materialOptions:{color:"#4ac2ff",image:a+"img/textures/line-arrow-right.png",repeat_x:20,repeat_y:1,speed:20},clampToGround:!1,allowDrillPick:!1},this.vehicleSum=100,this.automobileList=[{url:a+"gltf/cart/suv.gltf"},{url:a+"gltf/cart/red_car.gltf"},{url:a+"gltf/cart/benchi3.gltf"},{url:a+"gltf/cart/suv.gltf"},{url:a+"gltf/cart/red_car.gltf"},{url:a+"gltf/cart/benchi3.gltf"},{url:a+"gltf/cart/aodi1.gltf"},{url:a+"gltf/cart/kache3.gltf"},{url:a+"gltf/cart/bus2.gltf"},{url:a+"gltf/cart/jiaobanche.glb"}],this._czmlLayer,this._czmlLayerArr=[])}init(a){this.trafficSimulationLayer=new window.mars3d.layer.GraphicLayer({temporaryLayer:"trafficSimulation"}),window.map.addLayer(this.trafficSimulationLayer),window.map.bimMapEdit="1",a&&(this._czmlLayerArr=a)}addLine(a){let o=a;return new Promise(c=>{this.trafficSimulationLayer.startDraw({type:"polylineP",attr:{trafficSimulationId:o},style:{...this.style}}).then(f=>{c({id:o,pointSet:f.coordinates,speed:45,interval:1})})})}initLine(a){let o;a.forEach(c=>{let{id:f}=c;o=new window.mars3d.graphic.PolylinePrimitive({positions:c.pointSet,attr:{trafficSimulationId:f},style:{...this.style}}),this.trafficSimulationLayer.addGraphic(o)})}positionLine(a){let o=this.queryTrafficSimulationLine(a);o&&o.flyTo({scale:2})}deleteLine(a){let o=this.queryTrafficSimulationLine(a);o&&o.remove()}queryTrafficSimulationArr(){return this.trafficSimulationArr}queryTrafficSimulationLine(a){if(this.trafficSimulationLayer)return this.trafficSimulationLayer.getGraphicByAttr(a,"trafficSimulationId")}editTrafficSimulationLine(a,o=!0){let c=this.queryTrafficSimulationLine(a);o?(c.setStyle({materialOptions:{color:"#ff0000"}}),c.startEditing()):(c.setStyle({materialOptions:{color:"#4ac2ff"}}),c.stopEditing())}fallbackTrafficSimulationLine(a,o){let c=this.queryTrafficSimulationLine(a);c.positions=o,c.setStyle({materialOptions:{color:"#4ac2ff"}}),c.stopEditing()}queryCzml(a){return this._czmlLayerArr.length==0?!1:this._czmlLayerArr.find(o=>o.id==a)}start(a="add"){this.destruction(),this.beginDate=new Date().toISOString();let o=new Date,c=o.getDate();o.setDate(c+1),this.endDate=o.toISOString(),this.queryCzml(a)?this.trafficSimulationArr=JSON.parse(this.queryCzml(a).route):this.trafficSimulationArr=[],this.processingData(a)}selected(){this._czmlLayer&&this._czmlLayer.flyTo()}destruction(){this.trafficSimulationLayer.clear(),this.trafficSimulationLayer.remove(),this._czmlLayer&&(this._czmlLayer.clear(),this._czmlLayer.remove()),this.style.materialOptions.color="#4ac2ff",window.map.bimMapEdit="0"}processingData(a){let o=[{version:"1.0",id:"document",clock:{interval:`${this.beginDate}/${this.endDate}`,currentTime:this.beginDate,multiplier:1},style:{distanceDisplayCondition:!0,distanceDisplayCondition_far:1e6,distanceDisplayCondition_near:0}}],c=[],f=JSON.parse(JSON.stringify(this.trafficSimulationArr)),u=0;f.forEach((g,v)=>{let S=0,b=0,{pointSet:O,interval:k,speed:I}=g;for(let N=1;N<=this.vehicleSum;N++){let E=JSON.parse(JSON.stringify(O));E.forEach((w,M)=>{M>0&&(u=parseFloat((this.disTance(w,E[M-1].slice(1))/I).toFixed(2)),S+=u),M==0&&(S=b),w.unshift(S)}),b+=k,c=E.reduce((w,M)=>w.concat(M));let P={name:`${v}-${N}`,availability:`${this.beginDate}/${this.endDate}`,orientation:{velocityReference:"#position"},position:{epoch:this.beginDate,cartographicDegrees:c},style:{minimumPixelSize:100,distanceDisplayCondition:!0,distanceDisplayCondition_near:0,distanceDisplayCondition_far:1300,distanceDisplayPoint:{color:"#00ff00",pixelSize:8}},model:{show:!0,gltf:this.randomVehicle(),heightReference:window.Cesium.HeightReference.CLAMP_TO_GROUND,clampToGround:!0,scale:.6,minimumPixelSize:100,maximumScale:1.5}};o.push(P)}});let m={name:"交通模拟",czmlId:a,data:o,autoUpdateClock:!1};this._czmlLayer=new window.mars3d.layer.CzmlLayer(m),window.map.addLayer(this._czmlLayer)}disTance(a,o){let c,f,u;return c=window.Cesium.Cartesian3.fromDegrees(...a),f=window.Cesium.Cartesian3.fromDegrees(...o),u=window.Cesium.Cartesian3.distance(c,f),u}randomVehicle(){let a=Math.round(Math.random()*(this.automobileList.length-1));return this.automobileList[a].url}}const Vg=[Tf,Ef],Wg={continuation:null,mapModali:null,install(x){if(Vg.forEach((m,g)=>{x.component(m.name,m)}),this.continuation){x.config.globalProperties.$continuation=this.continuation;return}let a=oi.createApp(Mf),o=document.createElement("div"),c=document.body;if(c.appendChild(o),this.loading=a.mount(o),x.config.globalProperties.$loading=this.loading,window.$continuation=this.loading,this.mapModali){x.config.globalProperties.$mapModali=this.mapModali;return}let f=oi.createApp(Sf),u=document.createElement("div");c.appendChild(u),this.mapModali=f.mount(u),x.config.globalProperties.$mapModali=this.mapModali,window.$mapModali=this.mapModali}};Pi.BimBackgroundPlate=Ef,Pi.BimCutscenes=Mf,Pi.BimElevationImage=um,Pi.BimEntity=fm,Pi.BimModel=sm,Pi.BimModify=Ug,Pi.BimTerrainProvider=hm,Pi.BimTrafficSimulation=Hg,Pi.BimVector=lm,Pi.Bimroaming=Gg,Pi.Button=Tf,Pi.ChbimPlugins=Wg,Pi.DynamicMasking=Og,Pi.MapModali=Sf,Pi.PanoramicView=vm,Pi.ViewShed=cm,Pi.getSameKeyData=Bg,Pi.init=Ig,Pi.initMap=Fg,Pi.isValidRGBA=Ng,Pi.nextPage=zg,Pi.operateMapData=kg,Pi.previousPage=Dg,Object.defineProperty(Pi,Symbol.toStringTag,{value:"Module"})});
|
|
2702
|
+
*/var Sd,ta,Bl,Ic,Wa,Ed,Dc,ug=function(){return typeof window<"u"},ps={},ja=180/Math.PI,Nl=Math.PI/180,Fl=Math.atan2,bd=1e8,zc=/([A-Z])/g,cg=/(left|right|width|margin|padding|x)/i,fg=/[\s,\(]\S/,Xo={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},kc=function(a,o){return o.set(o.t,o.p,Math.round((o.s+o.c*a)*1e4)/1e4+o.u,o)},dg=function(a,o){return o.set(o.t,o.p,a===1?o.e:Math.round((o.s+o.c*a)*1e4)/1e4+o.u,o)},pg=function(a,o){return o.set(o.t,o.p,a?Math.round((o.s+o.c*a)*1e4)/1e4+o.u:o.b,o)},mg=function(a,o){var c=o.s+o.c*a;o.set(o.t,o.p,~~(c+(c<0?-.5:.5))+o.u,o)},Cd=function(a,o){return o.set(o.t,o.p,a?o.e:o.b,o)},Ad=function(a,o){return o.set(o.t,o.p,a!==1?o.b:o.e,o)},gg=function(a,o,c){return a.style[o]=c},vg=function(a,o,c){return a.style.setProperty(o,c)},yg=function(a,o,c){return a._gsap[o]=c},_g=function(a,o,c){return a._gsap.scaleX=a._gsap.scaleY=c},xg=function(a,o,c,f,u){var m=a._gsap;m.scaleX=m.scaleY=c,m.renderTransform(u,m)},wg=function(a,o,c,f,u){var m=a._gsap;m[o]=c,m.renderTransform(u,m)},pn="transform",Lr=pn+"Origin",Tg=function x(a,o){var c=this,f=this.target,u=f.style,m=f._gsap;if(a in ps&&u){if(this.tfm=this.tfm||{},a!=="transform")a=Xo[a]||a,~a.indexOf(",")?a.split(",").forEach(function(g){return c.tfm[g]=ms(f,g)}):this.tfm[a]=m.x?m[a]:ms(f,a),a===Lr&&(this.tfm.zOrigin=m.zOrigin);else return Xo.transform.split(",").forEach(function(g){return x.call(c,g,o)});if(this.props.indexOf(pn)>=0)return;m.svg&&(this.svgo=f.getAttribute("data-svg-origin"),this.props.push(Lr,o,"")),a=pn}(u||o)&&this.props.push(a,o,u[a])},Pd=function(a){a.translate&&(a.removeProperty("translate"),a.removeProperty("scale"),a.removeProperty("rotate"))},Mg=function(){var a=this.props,o=this.target,c=o.style,f=o._gsap,u,m;for(u=0;u<a.length;u+=3)a[u+1]?o[a[u]]=a[u+2]:a[u+2]?c[a[u]]=a[u+2]:c.removeProperty(a[u].substr(0,2)==="--"?a[u]:a[u].replace(zc,"-$1").toLowerCase());if(this.tfm){for(m in this.tfm)f[m]=this.tfm[m];f.svg&&(f.renderTransform(),o.setAttribute("data-svg-origin",this.svgo||"")),u=Dc(),(!u||!u.isStart)&&!c[pn]&&(Pd(c),f.zOrigin&&c[Lr]&&(c[Lr]+=" "+f.zOrigin+"px",f.zOrigin=0,f.renderTransform()),f.uncache=1)}},Ld=function(a,o){var c={target:a,props:[],revert:Mg,save:Tg};return a._gsap||Pr.core.getCache(a),o&&o.split(",").forEach(function(f){return c.save(f)}),c},Rd,Bc=function(a,o){var c=ta.createElementNS?ta.createElementNS((o||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),a):ta.createElement(a);return c&&c.style?c:ta.createElement(a)},qo=function x(a,o,c){var f=getComputedStyle(a);return f[o]||f.getPropertyValue(o.replace(zc,"-$1").toLowerCase())||f.getPropertyValue(o)||!c&&x(a,Ul(o)||o,1)||""},Od="O,Moz,ms,Ms,Webkit".split(","),Ul=function(a,o,c){var f=o||Wa,u=f.style,m=5;if(a in u&&!c)return a;for(a=a.charAt(0).toUpperCase()+a.substr(1);m--&&!(Od[m]+a in u););return m<0?null:(m===3?"ms":m>=0?Od[m]:"")+a},Nc=function(){ug()&&window.document&&(Sd=window,ta=Sd.document,Bl=ta.documentElement,Wa=Bc("div")||{style:{}},Bc("div"),pn=Ul(pn),Lr=pn+"Origin",Wa.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",Rd=!!Ul("perspective"),Dc=Pr.core.reverting,Ic=1)},Fc=function x(a){var o=Bc("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),c=this.parentNode,f=this.nextSibling,u=this.style.cssText,m;if(Bl.appendChild(o),o.appendChild(this),this.style.display="block",a)try{m=this.getBBox(),this._gsapBBox=this.getBBox,this.getBBox=x}catch{}else this._gsapBBox&&(m=this._gsapBBox());return c&&(f?c.insertBefore(this,f):c.appendChild(this)),Bl.removeChild(o),this.style.cssText=u,m},Id=function(a,o){for(var c=o.length;c--;)if(a.hasAttribute(o[c]))return a.getAttribute(o[c])},Dd=function(a){var o;try{o=a.getBBox()}catch{o=Fc.call(a,!0)}return o&&(o.width||o.height)||a.getBBox===Fc||(o=Fc.call(a,!0)),o&&!o.width&&!o.x&&!o.y?{x:+Id(a,["x","cx","x1"])||0,y:+Id(a,["y","cy","y1"])||0,width:0,height:0}:o},zd=function(a){return!!(a.getCTM&&(!a.parentNode||a.ownerSVGElement)&&Dd(a))},Xa=function(a,o){if(o){var c=a.style,f;o in ps&&o!==Lr&&(o=pn),c.removeProperty?(f=o.substr(0,2),(f==="ms"||o.substr(0,6)==="webkit")&&(o="-"+o),c.removeProperty(f==="--"?o:o.replace(zc,"-$1").toLowerCase())):c.removeAttribute(o)}},ea=function(a,o,c,f,u,m){var g=new Ar(a._pt,o,c,0,1,m?Ad:Cd);return a._pt=g,g.b=f,g.e=u,a._props.push(c),g},kd={deg:1,rad:1,turn:1},Sg={grid:1,flex:1},ia=function x(a,o,c,f){var u=parseFloat(c)||0,m=(c+"").trim().substr((u+"").length)||"px",g=Wa.style,v=cg.test(o),S=a.tagName.toLowerCase()==="svg",b=(S?"client":"offset")+(v?"Width":"Height"),O=100,k=f==="px",I=f==="%",F,E,P,w;if(f===m||!u||kd[f]||kd[m])return u;if(m!=="px"&&!k&&(u=x(a,o,c,"px")),w=a.getCTM&&zd(a),(I||m==="%")&&(ps[o]||~o.indexOf("adius")))return F=w?a.getBBox()[v?"width":"height"]:a[b],Rn(I?u/F*O:u/100*F);if(g[v?"width":"height"]=O+(k?m:f),E=~o.indexOf("adius")||f==="em"&&a.appendChild&&!S?a:a.parentNode,w&&(E=(a.ownerSVGElement||{}).parentNode),(!E||E===ta||!E.appendChild)&&(E=ta.body),P=E._gsap,P&&I&&P.width&&v&&P.time===Xr.time&&!P.uncache)return Rn(u/P.width*O);if(I&&(o==="height"||o==="width")){var M=a.style[o];a.style[o]=O+f,F=a[b],M?a.style[o]=M:Xa(a,o)}else(I||m==="%")&&!Sg[qo(E,"display")]&&(g.position=qo(a,"position")),E===a&&(g.position="static"),E.appendChild(Wa),F=Wa[b],E.removeChild(Wa),g.position="absolute";return v&&I&&(P=Na(E),P.time=Xr.time,P.width=E[b]),Rn(k?F*u/O:F&&u?O/F*u:0)},ms=function(a,o,c,f){var u;return Ic||Nc(),o in Xo&&o!=="transform"&&(o=Xo[o],~o.indexOf(",")&&(o=o.split(",")[0])),ps[o]&&o!=="transform"?(u=Lh(a,f),u=o!=="transformOrigin"?u[o]:u.svg?u.origin:Mu(qo(a,Lr))+" "+u.zOrigin+"px"):(u=a.style[o],(!u||u==="auto"||f||~(u+"").indexOf("calc("))&&(u=Tu[o]&&Tu[o](a,o,c)||qo(a,o)||Uf(a,o)||(o==="opacity"?1:0))),c&&!~(u+"").trim().indexOf(" ")?ia(a,o,u,c)+c:u},Eg=function(a,o,c,f){if(!c||c==="none"){var u=Ul(o,a,1),m=u&&qo(a,u,1);m&&m!==c?(o=u,c=m):o==="borderColor"&&(c=qo(a,"borderTopColor"))}var g=new Ar(this._pt,a.style,o,0,1,xd),v=0,S=0,b,O,k,I,F,E,P,w,M,R,C,U;if(g.b=c,g.e=f,c+="",f+="",f==="auto"&&(E=a.style[o],a.style[o]=f,f=qo(a,o)||f,E?a.style[o]=E:Xa(a,o)),b=[c,f],ud(b),c=b[0],f=b[1],k=c.match(Rl)||[],U=f.match(Rl)||[],U.length){for(;O=Rl.exec(f);)P=O[0],M=f.substring(v,O.index),F?F=(F+1)%5:(M.substr(-5)==="rgba("||M.substr(-5)==="hsla(")&&(F=1),P!==(E=k[S++]||"")&&(I=parseFloat(E)||0,C=E.substr((I+"").length),P.charAt(1)==="="&&(P=Ol(I,P)+C),w=parseFloat(P),R=P.substr((w+"").length),v=Rl.lastIndex-R.length,R||(R=R||Hr.units[o]||C,v===f.length&&(f+=R,g.e+=R)),C!==R&&(I=ia(a,o,E,R)||0),g._pt={_next:g._pt,p:M||S===1?M:",",s:I,c:w-I,m:F&&F<4||o==="zIndex"?Math.round:0});g.c=v<f.length?f.substring(v,f.length):""}else g.r=o==="display"&&f==="none"?Ad:Cd;return If.test(f)&&(g.e=0),this._pt=g,g},Bd={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"},bg=function(a){var o=a.split(" "),c=o[0],f=o[1]||"50%";return(c==="top"||c==="bottom"||f==="left"||f==="right")&&(a=c,c=f,f=a),o[0]=Bd[c]||c,o[1]=Bd[f]||f,o.join(" ")},Cg=function(a,o){if(o.tween&&o.tween._time===o.tween._dur){var c=o.t,f=c.style,u=o.u,m=c._gsap,g,v,S;if(u==="all"||u===!0)f.cssText="",v=1;else for(u=u.split(","),S=u.length;--S>-1;)g=u[S],ps[g]&&(v=1,g=g==="transformOrigin"?Lr:pn),Xa(c,g);v&&(Xa(c,pn),m&&(m.svg&&c.removeAttribute("transform"),Lh(c,1),m.uncache=1,Pd(f)))}},Tu={clearProps:function(a,o,c,f,u){if(u.data!=="isFromStart"){var m=a._pt=new Ar(a._pt,o,c,0,0,Cg);return m.u=f,m.pr=-10,m.tween=u,a._props.push(c),1}}},Ph=[1,0,0,1,0,0],Nd={},Fd=function(a){return a==="matrix(1, 0, 0, 1, 0, 0)"||a==="none"||!a},Ud=function(a){var o=qo(a,pn);return Fd(o)?Ph:o.substr(7).match(Of).map(Rn)},Uc=function(a,o){var c=a._gsap||Na(a),f=a.style,u=Ud(a),m,g,v,S;return c.svg&&a.getAttribute("transform")?(v=a.transform.baseVal.consolidate().matrix,u=[v.a,v.b,v.c,v.d,v.e,v.f],u.join(",")==="1,0,0,1,0,0"?Ph:u):(u===Ph&&!a.offsetParent&&a!==Bl&&!c.svg&&(v=f.display,f.display="block",m=a.parentNode,(!m||!a.offsetParent)&&(S=1,g=a.nextElementSibling,Bl.appendChild(a)),u=Ud(a),v?f.display=v:Xa(a,"display"),S&&(g?m.insertBefore(a,g):m?m.appendChild(a):Bl.removeChild(a))),o&&u.length>6?[u[0],u[1],u[4],u[5],u[12],u[13]]:u)},Gc=function(a,o,c,f,u,m){var g=a._gsap,v=u||Uc(a,!0),S=g.xOrigin||0,b=g.yOrigin||0,O=g.xOffset||0,k=g.yOffset||0,I=v[0],F=v[1],E=v[2],P=v[3],w=v[4],M=v[5],R=o.split(" "),C=parseFloat(R[0])||0,U=parseFloat(R[1])||0,N,X,J,Z;c?v!==Ph&&(X=I*P-F*E)&&(J=C*(P/X)+U*(-E/X)+(E*M-P*w)/X,Z=C*(-F/X)+U*(I/X)-(I*M-F*w)/X,C=J,U=Z):(N=Dd(a),C=N.x+(~R[0].indexOf("%")?C/100*N.width:C),U=N.y+(~(R[1]||R[0]).indexOf("%")?U/100*N.height:U)),f||f!==!1&&g.smooth?(w=C-S,M=U-b,g.xOffset=O+(w*I+M*E)-w,g.yOffset=k+(w*F+M*P)-M):g.xOffset=g.yOffset=0,g.xOrigin=C,g.yOrigin=U,g.smooth=!!f,g.origin=o,g.originIsAbsolute=!!c,a.style[Lr]="0px 0px",m&&(ea(m,g,"xOrigin",S,C),ea(m,g,"yOrigin",b,U),ea(m,g,"xOffset",O,g.xOffset),ea(m,g,"yOffset",k,g.yOffset)),a.setAttribute("data-svg-origin",C+" "+U)},Lh=function(a,o){var c=a._gsap||new pd(a);if("x"in c&&!o&&!c.uncache)return c;var f=a.style,u=c.scaleX<0,m="px",g="deg",v=getComputedStyle(a),S=qo(a,Lr)||"0",b,O,k,I,F,E,P,w,M,R,C,U,N,X,J,Z,ct,Rt,tt,_t,G,Pt,Et,At,ce,re,Ft,It,Nt,Pe,pe,Wt;return b=O=k=E=P=w=M=R=C=0,I=F=1,c.svg=!!(a.getCTM&&zd(a)),v.translate&&((v.translate!=="none"||v.scale!=="none"||v.rotate!=="none")&&(f[pn]=(v.translate!=="none"?"translate3d("+(v.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+(v.rotate!=="none"?"rotate("+v.rotate+") ":"")+(v.scale!=="none"?"scale("+v.scale.split(" ").join(",")+") ":"")+(v[pn]!=="none"?v[pn]:"")),f.scale=f.rotate=f.translate="none"),X=Uc(a,c.svg),c.svg&&(c.uncache?(ce=a.getBBox(),S=c.xOrigin-ce.x+"px "+(c.yOrigin-ce.y)+"px",At=""):At=!o&&a.getAttribute("data-svg-origin"),Gc(a,At||S,!!At||c.originIsAbsolute,c.smooth!==!1,X)),U=c.xOrigin||0,N=c.yOrigin||0,X!==Ph&&(Rt=X[0],tt=X[1],_t=X[2],G=X[3],b=Pt=X[4],O=Et=X[5],X.length===6?(I=Math.sqrt(Rt*Rt+tt*tt),F=Math.sqrt(G*G+_t*_t),E=Rt||tt?Fl(tt,Rt)*ja:0,M=_t||G?Fl(_t,G)*ja+E:0,M&&(F*=Math.abs(Math.cos(M*Nl))),c.svg&&(b-=U-(U*Rt+N*_t),O-=N-(U*tt+N*G))):(Wt=X[6],Pe=X[7],Ft=X[8],It=X[9],Nt=X[10],pe=X[11],b=X[12],O=X[13],k=X[14],J=Fl(Wt,Nt),P=J*ja,J&&(Z=Math.cos(-J),ct=Math.sin(-J),At=Pt*Z+Ft*ct,ce=Et*Z+It*ct,re=Wt*Z+Nt*ct,Ft=Pt*-ct+Ft*Z,It=Et*-ct+It*Z,Nt=Wt*-ct+Nt*Z,pe=Pe*-ct+pe*Z,Pt=At,Et=ce,Wt=re),J=Fl(-_t,Nt),w=J*ja,J&&(Z=Math.cos(-J),ct=Math.sin(-J),At=Rt*Z-Ft*ct,ce=tt*Z-It*ct,re=_t*Z-Nt*ct,pe=G*ct+pe*Z,Rt=At,tt=ce,_t=re),J=Fl(tt,Rt),E=J*ja,J&&(Z=Math.cos(J),ct=Math.sin(J),At=Rt*Z+tt*ct,ce=Pt*Z+Et*ct,tt=tt*Z-Rt*ct,Et=Et*Z-Pt*ct,Rt=At,Pt=ce),P&&Math.abs(P)+Math.abs(E)>359.9&&(P=E=0,w=180-w),I=Rn(Math.sqrt(Rt*Rt+tt*tt+_t*_t)),F=Rn(Math.sqrt(Et*Et+Wt*Wt)),J=Fl(Pt,Et),M=Math.abs(J)>2e-4?J*ja:0,C=pe?1/(pe<0?-pe:pe):0),c.svg&&(At=a.getAttribute("transform"),c.forceCSS=a.setAttribute("transform","")||!Fd(qo(a,pn)),At&&a.setAttribute("transform",At))),Math.abs(M)>90&&Math.abs(M)<270&&(u?(I*=-1,M+=E<=0?180:-180,E+=E<=0?180:-180):(F*=-1,M+=M<=0?180:-180)),o=o||c.uncache,c.x=b-((c.xPercent=b&&(!o&&c.xPercent||(Math.round(a.offsetWidth/2)===Math.round(-b)?-50:0)))?a.offsetWidth*c.xPercent/100:0)+m,c.y=O-((c.yPercent=O&&(!o&&c.yPercent||(Math.round(a.offsetHeight/2)===Math.round(-O)?-50:0)))?a.offsetHeight*c.yPercent/100:0)+m,c.z=k+m,c.scaleX=Rn(I),c.scaleY=Rn(F),c.rotation=Rn(E)+g,c.rotationX=Rn(P)+g,c.rotationY=Rn(w)+g,c.skewX=M+g,c.skewY=R+g,c.transformPerspective=C+m,(c.zOrigin=parseFloat(S.split(" ")[2])||!o&&c.zOrigin||0)&&(f[Lr]=Mu(S)),c.xOffset=c.yOffset=0,c.force3D=Hr.force3D,c.renderTransform=c.svg?Pg:Rd?Gd:Ag,c.uncache=0,c},Mu=function(a){return(a=a.split(" "))[0]+" "+a[1]},Hc=function(a,o,c){var f=or(o);return Rn(parseFloat(o)+parseFloat(ia(a,"x",c+"px",f)))+f},Ag=function(a,o){o.z="0px",o.rotationY=o.rotationX="0deg",o.force3D=0,Gd(a,o)},qa="0deg",Rh="0px",Ya=") ",Gd=function(a,o){var c=o||this,f=c.xPercent,u=c.yPercent,m=c.x,g=c.y,v=c.z,S=c.rotation,b=c.rotationY,O=c.rotationX,k=c.skewX,I=c.skewY,F=c.scaleX,E=c.scaleY,P=c.transformPerspective,w=c.force3D,M=c.target,R=c.zOrigin,C="",U=w==="auto"&&a&&a!==1||w===!0;if(R&&(O!==qa||b!==qa)){var N=parseFloat(b)*Nl,X=Math.sin(N),J=Math.cos(N),Z;N=parseFloat(O)*Nl,Z=Math.cos(N),m=Hc(M,m,X*Z*-R),g=Hc(M,g,-Math.sin(N)*-R),v=Hc(M,v,J*Z*-R+R)}P!==Rh&&(C+="perspective("+P+Ya),(f||u)&&(C+="translate("+f+"%, "+u+"%) "),(U||m!==Rh||g!==Rh||v!==Rh)&&(C+=v!==Rh||U?"translate3d("+m+", "+g+", "+v+") ":"translate("+m+", "+g+Ya),S!==qa&&(C+="rotate("+S+Ya),b!==qa&&(C+="rotateY("+b+Ya),O!==qa&&(C+="rotateX("+O+Ya),(k!==qa||I!==qa)&&(C+="skew("+k+", "+I+Ya),(F!==1||E!==1)&&(C+="scale("+F+", "+E+Ya),M.style[pn]=C||"translate(0, 0)"},Pg=function(a,o){var c=o||this,f=c.xPercent,u=c.yPercent,m=c.x,g=c.y,v=c.rotation,S=c.skewX,b=c.skewY,O=c.scaleX,k=c.scaleY,I=c.target,F=c.xOrigin,E=c.yOrigin,P=c.xOffset,w=c.yOffset,M=c.forceCSS,R=parseFloat(m),C=parseFloat(g),U,N,X,J,Z;v=parseFloat(v),S=parseFloat(S),b=parseFloat(b),b&&(b=parseFloat(b),S+=b,v+=b),v||S?(v*=Nl,S*=Nl,U=Math.cos(v)*O,N=Math.sin(v)*O,X=Math.sin(v-S)*-k,J=Math.cos(v-S)*k,S&&(b*=Nl,Z=Math.tan(S-b),Z=Math.sqrt(1+Z*Z),X*=Z,J*=Z,b&&(Z=Math.tan(b),Z=Math.sqrt(1+Z*Z),U*=Z,N*=Z)),U=Rn(U),N=Rn(N),X=Rn(X),J=Rn(J)):(U=O,J=k,N=X=0),(R&&!~(m+"").indexOf("px")||C&&!~(g+"").indexOf("px"))&&(R=ia(I,"x",m,"px"),C=ia(I,"y",g,"px")),(F||E||P||w)&&(R=Rn(R+F-(F*U+E*X)+P),C=Rn(C+E-(F*N+E*J)+w)),(f||u)&&(Z=I.getBBox(),R=Rn(R+f/100*Z.width),C=Rn(C+u/100*Z.height)),Z="matrix("+U+","+N+","+X+","+J+","+R+","+C+")",I.setAttribute("transform",Z),M&&(I.style[pn]=Z)},Lg=function(a,o,c,f,u){var m=360,g=Wn(u),v=parseFloat(u)*(g&&~u.indexOf("rad")?ja:1),S=v-f,b=f+S+"deg",O,k;return g&&(O=u.split("_")[1],O==="short"&&(S%=m,S!==S%(m/2)&&(S+=S<0?m:-m)),O==="cw"&&S<0?S=(S+m*bd)%m-~~(S/m)*m:O==="ccw"&&S>0&&(S=(S-m*bd)%m-~~(S/m)*m)),a._pt=k=new Ar(a._pt,o,c,f,S,dg),k.e=b,k.u="deg",a._props.push(c),k},Hd=function(a,o){for(var c in o)a[c]=o[c];return a},Rg=function(a,o,c){var f=Hd({},c._gsap),u="perspective,force3D,transformOrigin,svgOrigin",m=c.style,g,v,S,b,O,k,I,F;f.svg?(S=c.getAttribute("transform"),c.setAttribute("transform",""),m[pn]=o,g=Lh(c,1),Xa(c,pn),c.setAttribute("transform",S)):(S=getComputedStyle(c)[pn],m[pn]=o,g=Lh(c,1),m[pn]=S);for(v in ps)S=f[v],b=g[v],S!==b&&u.indexOf(v)<0&&(I=or(S),F=or(b),O=I!==F?ia(c,v,S,F):parseFloat(S),k=parseFloat(b),a._pt=new Ar(a._pt,g,v,O,k-O,kc),a._pt.u=F||0,a._props.push(v));Hd(g,f)};Cr("padding,margin,Width,Radius",function(x,a){var o="Top",c="Right",f="Bottom",u="Left",m=(a<3?[o,c,f,u]:[o+u,o+c,f+c,f+u]).map(function(g){return a<2?x+g:"border"+g+x});Tu[a>1?"border"+x:x]=function(g,v,S,b,O){var k,I;if(arguments.length<4)return k=m.map(function(F){return ms(g,F,S)}),I=k.join(" "),I.split(k[0]).length===5?k[0]:I;k=(b+"").split(" "),I={},m.forEach(function(F,E){return I[F]=k[E]=k[E]||k[(E-1)/2|0]}),g.init(v,I,O)}});var Vd={name:"css",register:Nc,targetTest:function(a){return a.style&&a.nodeType},init:function(a,o,c,f,u){var m=this._props,g=a.style,v=c.vars.startAt,S,b,O,k,I,F,E,P,w,M,R,C,U,N,X,J;Ic||Nc(),this.styles=this.styles||Ld(a),J=this.styles.props,this.tween=c;for(E in o)if(E!=="autoRound"&&(b=o[E],!(Wr[E]&&md(E,o,c,f,a,u)))){if(I=typeof b,F=Tu[E],I==="function"&&(b=b.call(c,f,a,u),I=typeof b),I==="string"&&~b.indexOf("random(")&&(b=Mh(b)),F)F(this,a,E,b,c)&&(X=1);else if(E.substr(0,2)==="--")S=(getComputedStyle(a).getPropertyValue(E)+"").trim(),b+="",Ks.lastIndex=0,Ks.test(S)||(P=or(S),w=or(b)),w?P!==w&&(S=ia(a,E,S,w)+w):P&&(b+=P),this.add(g,"setProperty",S,b,f,u,0,0,E),m.push(E),J.push(E,0,g[E]);else if(I!=="undefined"){if(v&&E in v?(S=typeof v[E]=="function"?v[E].call(c,f,a,u):v[E],Wn(S)&&~S.indexOf("random(")&&(S=Mh(S)),or(S+"")||S==="auto"||(S+=Hr.units[E]||or(ms(a,E))||""),(S+"").charAt(1)==="="&&(S=ms(a,E))):S=ms(a,E),k=parseFloat(S),M=I==="string"&&b.charAt(1)==="="&&b.substr(0,2),M&&(b=b.substr(2)),O=parseFloat(b),E in Xo&&(E==="autoAlpha"&&(k===1&&ms(a,"visibility")==="hidden"&&O&&(k=0),J.push("visibility",0,g.visibility),ea(this,g,"visibility",k?"inherit":"hidden",O?"inherit":"hidden",!O)),E!=="scale"&&E!=="transform"&&(E=Xo[E],~E.indexOf(",")&&(E=E.split(",")[0]))),R=E in ps,R){if(this.styles.save(E),C||(U=a._gsap,U.renderTransform&&!o.parseTransform||Lh(a,o.parseTransform),N=o.smoothOrigin!==!1&&U.smooth,C=this._pt=new Ar(this._pt,g,pn,0,1,U.renderTransform,U,0,-1),C.dep=1),E==="scale")this._pt=new Ar(this._pt,U,"scaleY",U.scaleY,(M?Ol(U.scaleY,M+O):O)-U.scaleY||0,kc),this._pt.u=0,m.push("scaleY",E),E+="X";else if(E==="transformOrigin"){J.push(Lr,0,g[Lr]),b=bg(b),U.svg?Gc(a,b,0,N,0,this):(w=parseFloat(b.split(" ")[2])||0,w!==U.zOrigin&&ea(this,U,"zOrigin",U.zOrigin,w),ea(this,g,E,Mu(S),Mu(b)));continue}else if(E==="svgOrigin"){Gc(a,b,1,N,0,this);continue}else if(E in Nd){Lg(this,U,E,k,M?Ol(k,M+b):b);continue}else if(E==="smoothOrigin"){ea(this,U,"smooth",U.smooth,b);continue}else if(E==="force3D"){U[E]=b;continue}else if(E==="transform"){Rg(this,b,a);continue}}else E in g||(E=Ul(E)||E);if(R||(O||O===0)&&(k||k===0)&&!fg.test(b)&&E in g)P=(S+"").substr((k+"").length),O||(O=0),w=or(b)||(E in Hr.units?Hr.units[E]:P),P!==w&&(k=ia(a,E,S,w)),this._pt=new Ar(this._pt,R?U:g,E,k,(M?Ol(k,M+O):O)-k,!R&&(w==="px"||E==="zIndex")&&o.autoRound!==!1?mg:kc),this._pt.u=w||0,P!==w&&w!=="%"&&(this._pt.b=S,this._pt.r=pg);else if(E in g)Eg.call(this,a,E,S,M?M+b:b);else if(E in a)this.add(a,E,S||a[E],M?M+b:b,f,u);else if(E!=="parseTransform"){uc(E,b);continue}R||(E in g?J.push(E,0,g[E]):J.push(E,1,S||a[E])),m.push(E)}}X&&wd(this)},render:function(a,o){if(o.tween._time||!Dc())for(var c=o._pt;c;)c.r(a,c.d),c=c._next;else o.styles.revert()},get:ms,aliases:Xo,getSetter:function(a,o,c){var f=Xo[o];return f&&f.indexOf(",")<0&&(o=f),o in ps&&o!==Lr&&(a._gsap.x||ms(a,"x"))?c&&Ed===c?o==="scale"?_g:yg:(Ed=c||{})&&(o==="scale"?xg:wg):a.style&&!rc(a.style[o])?gg:~o.indexOf("-")?vg:Ac(a,o)},core:{_removeProperty:Xa,_getMatrix:Uc}};Pr.utils.checkPrefix=Ul,Pr.core.getStyleSaver=Ld,function(x,a,o,c){var f=Cr(x+","+a+","+o,function(u){ps[u]=1});Cr(a,function(u){Hr.units[u]="deg",Nd[u]=1}),Xo[f[13]]=x+","+a,Cr(c,function(u){var m=u.split(":");Xo[m[1]]=f[m[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"),Cr("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(x){Hr.units[x]="px"}),Pr.registerPlugin(Vd);var Vc=Pr.registerPlugin(Vd)||Pr;Vc.core.Tween;class Og{constructor(a,o=!1){window.mars3d&&(this.Cesium=window.mars3d.Cesium,this.DynamicMaskingArr=[],this.DynamicMaskingStyle=[],this.canvasClientWidth=a.viewer.canvas.clientWidth,this.canvasClientHeight=a.viewer.canvas.clientHeight,this.oldSet=new Set,this.tweenMap=new Map,this.isDynamicMasking=o)}add(a,o){let c=a.options.symbol.styleOptions.label.font_size,f=a.options.vectorId,u=Number(c)*1.4,m=Number(c)*1.8,g=a.options.symbol.styleOptions.label,{color:v,outlineColor:S,backgroundColor:b}=g;a.eachGraphic(O=>{O.style.label&&this.DynamicMaskingArr.push({id:f,uid:O.id,position:O._getLablePosition(),label:O.name,width:O.name?u*O.name.length:0,height:m,color:v,outline:o.label.outline,outlineColor:S,background:o.label.background,backgroundColor:b,dynamicMaskingColor:{backgroundColor:this.Cesium.Color.fromCssColorString(o.label.backgroundColor),color:this.Cesium.Color.fromCssColorString(o.label.color),outlineColor:this.Cesium.Color.fromCssColorString(o.label.outlineColor)}})}),this.DynamicMaskingStyle.push({vectorId:a.options.vectorId,outline:o.label.outline,background:o.label.background,color:this.Cesium.Color.fromCssColorString(o.label.color),backgroundColor:this.Cesium.Color.fromCssColorString(o.label.backgroundColor),outlineColor:this.Cesium.Color.fromCssColorString(o.label.outlineColor)}),this.oldSet=new Set,this.tweenMap=new Map}remove(a){this.DynamicMaskingArr=this.DynamicMaskingArr.filter(o=>o.id!==a),this.DynamicMaskingStyle=this.DynamicMaskingStyle.filter(o=>o.vectorId!==a),this.oldSet=new Set,this.tweenMap=new Map}modify(a,o){let{label:c}=o;if(c){let{color:f,outline:u,outlineColor:m,background:g,backgroundColor:v}=c;this.DynamicMaskingArr.forEach(S=>{S.id===a&&(f!=null&&(S.color=this.Cesium.Color.fromCssColorString(f),S.dynamicMaskingColor.color=this.Cesium.Color.fromCssColorString(f)),u!=null&&(S.outline=u),m!=null&&(S.outlineColor=this.Cesium.Color.fromCssColorString(m),S.dynamicMaskingColor.outlineColor=this.Cesium.Color.fromCssColorString(m)),g!=null&&(S.background=g),v!=null&&(S.backgroundColor=this.Cesium.Color.fromCssColorString(v),S.dynamicMaskingColor.backgroundColor=this.Cesium.Color.fromCssColorString(v)))})}}getBoundingRectangle(a){var o=this.Cesium.SceneTransforms.wgs84ToWindowCoordinates(window.map.viewer.scene,a.position);return o!==void 0?new this.Cesium.BoundingRectangle(o.x,o.y,a.width,a.height):new this.Cesium.BoundingRectangle(0,0,1,1)}getNonIntersectingRectangles(){let a=[];for(var o=0;o<this.DynamicMaskingArr.length;o++){let f=!1,u=this.DynamicMaskingArr[o],m,g,v;if(g=this.getBoundingRectangle(u),!(g.x<0||g.x>this.canvasClientWidth||g.y<0||g.y>this.canvasClientHeight))if(a.length===0){a.push(o);continue}else{for(var c=0;c<a.length;c++)if(m=this.DynamicMaskingArr[a[c]],v=this.getBoundingRectangle(m),this.Cesium.Intersect.OUTSIDE!==this.Cesium.BoundingRectangle.intersect(g,v)){f=!0;break}f||a.push(o)}}return new Set(a)}ifShow(){if(this.isDynamicMasking){let o={color:.001,outlineColor:.001,backgroundColor:.001},c={color:1,outlineColor:1,backgroundColor:1},f=this.getNonIntersectingRectangles(),u=new Set([...this.oldSet].filter(g=>!f.has(g))),m=new Set([...f].filter(g=>!this.oldSet.has(g)));for(let g of u)if(this.DynamicMaskingArr[g]){if(this.tweenMap.has(g)){var a=this.tweenMap.get(g);a.kill(),this.tweenMap.delete(g)}var a=Vc.to(c,{duration:.2,color:0,outlineColor:0,backgroundColor:0,onUpdate:()=>{var S,b;var v=this.DynamicMaskingArr[g];v.backgroundColor.alpha=c.backgroundColor,v.color.alpha=c.color,v.outlineColor.alpha=c.outlineColor,(b=(S=window.map.getLayer(v.id,"vectorId"))==null?void 0:S.getGraphicByAttr(v.uid))==null||b.setStyle({label:{show:!1,outline:!1,background:!1}})}});this.tweenMap.set(g,a)}for(let g of m)if(this.DynamicMaskingArr[g]){if(this.tweenMap.has(g)){var a=this.tweenMap.get(g);a.kill(),this.tweenMap.delete(g)}let v=this.DynamicMaskingArr[g],{backgroundColor:S,color:b,outlineColor:O}=v.dynamicMaskingColor;var a=Vc.to(o,{duration:.8+Math.random(),color:b.alpha,outlineColor:O.alpha,backgroundColor:S.alpha,onUpdate:()=>{var I,F;v.backgroundColor.alpha=o.backgroundColor,v.color.alpha=o.color,v.outlineColor.alpha=o.outlineColor,(F=(I=window.map.getLayer(v.id,"vectorId"))==null?void 0:I.getGraphicByAttr(v.uid))==null||F.setStyle({label:{show:!0,outline:v.outline,background:v.background,color:v.color,outlineColor:v.outlineColor,backgroundColor:v.backgroundColor}})}});this.tweenMap.set(g,a)}this.oldSet=f}}switchDynamicMasking(a){if(a)window.map.getLayers().forEach(o=>{var c;if((c=o.options)!=null&&c.vectorId){let{color:f,outlineColor:u,backgroundColor:m}=o.options.symbol.styleOptions.label;o.eachGraphic(g=>{g.setStyle({label:{color:f.withAlpha(0),outlineColor:u.withAlpha(.001),backgroundColor:m.withAlpha(.001),show:!1,background:!1,outline:!1}})})}});else if(this.DynamicMaskingStyle.length>0){let o;this.DynamicMaskingStyle.forEach(c=>{let{color:f,outline:u,outlineColor:m,background:g,backgroundColor:v,vectorId:S}=c;o=window.map.getLayer(S,"vectorId"),o&&o.eachGraphic(b=>{b.setStyle({label:{color:f,outlineColor:m,backgroundColor:v,show:!0,background:g,outline:u}})})})}this.isDynamicMasking=a,window.bimVector.switchDynamicMasking(a)}}const Ig=()=>{var x,a;window.planClip.clearPlanClip(),window.schemeEvnModify.clearAllEvnModify(),window.bimRotatePoint.stop(),window.bimTrafficSimulation.destruction(),window.bimMapPTV&&window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.bimMapCompare.hide?window.bimMapCompare.hide():window.bimMapCompare.destroyControl(),window.updateEitor({content:""}),(a=(x=window.glftSet)==null?void 0:x.glftList)==null||a.map(o=>{o.remove()})},Dg=()=>{var x,a;window.planClip.clearPlanClip(),window.bimRotatePoint.stop(),window.bimTrafficSimulation.destruction(),window.bimMapPTV&&window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.bimMapCompare.hide?window.bimMapCompare.hide():window.bimMapCompare.destroyControl(),window.updateEitor({content:""}),(a=(x=window.glftSet)==null?void 0:x.glftList)==null||a.map(o=>{o.remove()})},zg=()=>{var x,a;window.planClip.clearPlanClip(),window.bimRotatePoint.stop(),window.bimTrafficSimulation.destruction(),window.bimMapPTV&&window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.bimMapCompare.hide?window.bimMapCompare.hide():window.bimMapCompare.destroyControl(),window.updateEitor({content:""}),(a=(x=window.glftSet)==null?void 0:x.glftList)==null||a.map(o=>{o.remove()})},kg=x=>{let a=[];if(x.forEach(o=>{let{id:c}=o,f={id:c,mockData:{nextPage:[],item:[],previousPage:[]}};o.operate.forEach((u,m)=>{let g=Wc(u,f.mockData.nextPage);f.mockData.nextPage=g,f.mockData.item=g,f.mockData.previousPage=[]}),a.push(f)}),a.length>1)for(let o=1;o<a.length;o++){let c=a[o].mockData,f=a[o-1].mockData.item;const u=new Map;f.forEach(m=>{m.type!="rotatePoint"&&m.type!="viewpoint"&&m.type!="roaming"&&m.type!="splitScreen"&&m.type!="planClip"&&m.type!="editor"&&m.type!="gltf"?u.set(`${m.screenplayId}-${m.type}`,m):a[o].mockData.previousPage.push(m)}),c.nextPage.forEach(m=>{const g=`${m.screenplayId}-${m.type}`;let v={...u.get(g)};if(u.has(g)){if(m.type=="flight")a[o].mockData.previousPage.unshift(u.get(g)),v=m;else{let S={};Object.keys(m).forEach(b=>{if(b!="screenplayId"&&b!="type")if(u.get(g)[b])if(Object.keys(S).length==0&&(S={screenplayId:m.screenplayId,type:m.type}),b=="clip"||b=="flat"){v[b]=Wd(u.get(g)[b],m[b]);let O={screenplayId:m.screenplayId,type:m.type};O[b]={},Object.keys(m[b]).forEach(k=>{u.get(g)[b][k]?O[b][k]=u.get(g)[b][k]:m[b][k]=="true"&&(O[b][k]="false")}),S={...O,...S}}else S[b]=u.get(g)[b],v[b]=m[b];else a[o].mockData.previousPage.some(O=>O.screenplayId===m.screenplayId)||(S={...jd(m,b),...S}),v[b]=m[b]}),Object.keys(S).length>0&&a[o].mockData.previousPage.push(S)}u.set(g,v)}else{let S=jd(m);S&&a[o].mockData.previousPage.push(S),u.set(g,m)}}),a[o].mockData.item=Array.from(u.values())}return a},Wc=(x,a=null)=>{let{executionProperty:o,screenplayId:c,property:f,type:u,delay:m,delayTime:g}=x;if((f=="add"||f==!0)&&(f="true"),(f=="remove"||f==!1)&&(f="false"),u=="pit"){let S=window.schemeEvnModify.getModelModifyDataForInitModelById(c);if(S){let b={};b[c]=f,f=b,c=S.modelId,o=S.type}}let v;if(c==""||c=="map")if(c="map",u=="splitScreen"){let{splitScreenMode:S,splitScreenModePercentage:b}=JSON.parse(f);a.push({screenplayId:c,type:u,executionProperty:{splitScreenMode:S,splitScreenModePercentage:b,mapClone:[]}});let{mainScreen:O,secondaryScreen:k}=JSON.parse(x.property);O.forEach(F=>{Wc(F,a)});let I=a.find(F=>F.type=="splitScreen");k.forEach(F=>{Wc(F,I.executionProperty.mapClone)})}else v={screenplayId:c,type:u,executionProperty:f},(o=="clip"||o=="flat")&&(v[o]=f),m&&(v.delay=m),g&&(v.delayTime=g),a&&(u=="flight"?a.unshift(v):a.push(v));else v=a?a.find(S=>S.screenplayId==c):null,v?(o=="clip"||o=="flat"?v[o]?v[o]=Wd(v[o],f):(v[o]=f,v.type="model"):v[o]=f,m&&(v[o].delay=m),g&&(v[o].delayTime=g)):(v={screenplayId:c,type:u},m&&(v.delay=m),g&&(v.delayTime=g),o=="clip"||o=="flat"?(v[o]=f,v.type="model"):v[o]=f,a&&(u=="flight"?a.unshift(v):a.push(v)));return a||v},Wd=(x,a)=>{const o={...x};for(const c in a)a.hasOwnProperty(c)&&(o[c]=a[c]);return o},jd=(x,a="all")=>{let{type:o,show:c,screenplayId:f,overallStaining:u,clip:m,flat:g}=x,v={};if(a=="all")switch(o){case"model":case"shp":case"plot":c&&c=="true"&&(v={screenplayId:f,type:o,show:"false"}),u&&(v={...v,screenplayId:f,type:o,overallStaining:"false"}),m&&(v={...v,screenplayId:f,type:o,clip:"false"}),g&&(v={...v,screenplayId:f,type:o,flat:"false"});break;case"terrain":v={screenplayId:f,type:o,executionProperty:"true"};break;case"pit":v={screenplayId:f,type:o,executionProperty:"false"};break;case"underground":v={screenplayId:f,type:o,executionProperty:"1"};break}else switch(a){case"clip":case"flat":case"overallStaining":v={screenplayId:f,type:o},v[a]="false";break}return Object.keys(v).length>0?v:null},Bg=(x,a)=>{const o={};return Object.keys(a).forEach(c=>{x.hasOwnProperty(c)&&(o[c]=x[c])}),o},Ng=x=>/^rgba\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*,\s*(0|1|0\.\d+)\s*\)$/i.test(x),Fg=x=>{let a={};(x==null?void 0:x.length)>0&&x[0].operate.forEach(o=>{let{executionProperty:c,screenplayId:f,property:u,type:m}=o;(c=="show"||c=="overallStaining")&&(a[f]||(a[f]={type:m}),a[f][u]=c)}),window.map.getLayers().forEach(o=>{if((o.type=="3dtiles"||o.type=="geojson"||o.type=="tileset")&&o.options.name!="国界"){let c=o.options.modelId||o.options.vectorId;a[c]?(window.bimModel.editColor(c),window.schemeEvnModify.clearAllModelModify({isClone:!1})):o.remove()}}),window.bimEntity.entityLayer.getGraphicsByAttr().forEach(o=>{o.remove()}),window.bimMapSetUp.undergroundVal(1),window.bimTerrainProvider.show(),window.bimTrafficSimulation.destruction(),window.bimRotatePoint.stop(),window.bimMapPTV.destruction(),window.romStop(),window.complete(),window.planClip.clearPlanClip()};class Ug{constructor(a){Ho(this,"getPositions",a=>a.length>1&&(Array.isArray(a[0])||typeof a[0]=="object")?a:this.getPositions(a[0]));Ho(this,"terrainCutById",(a,o,c)=>{switch(c==null?void 0:c.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainClipClone||this.terrainClipClone.list.find(f=>f.id==o))return;this.terrainClipClone.addArea(a.length>1?a:a[0],{id:o});break;case!1:if(!this.terrainClip||this.terrainClip.list.find(f=>f.id==o))return;this.terrainClip.addArea(a.length>1?a:a[0],{id:o});break}});Ho(this,"clearTerrainCutById",(a,o)=>{switch(o==null?void 0:o.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainClipClone)return;this.terrainClipClone.removeArea(a);break;case!1:if(!this.terrainClip)return;this.terrainClip.removeArea(a);break}});Ho(this,"terrainFlattenById",(a,o,c,f)=>{switch(f==null?void 0:f.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainFlatClone||this.terrainFlatClone.list.find(u=>u.id==c))return;this.terrainFlatClone.addArea(a.length>1?a:a[0],{id:c,height:o});break;case!1:if(!this.terrainFlat||this.terrainFlat.list.find(u=>u.id==c))return;this.terrainFlat.addArea(a.length>1?a:a[0],{id:c,height:o});break}});Ho(this,"clearTerrainFlattenById",(a,o)=>{switch(o==null?void 0:o.isClone){case!0:if(this.createTerrainModifyInstanceClone(),!this.terrainFlatClone)return;this.terrainFlatClone.removeArea(a);break;case!1:if(!this.terrainFlat)return;this.terrainFlat.removeArea(a);break}});this.flattenedEvnModifyData=a,this.modelIdListByModify=[],this.modelIdListByModifyClone=[],this.terrainClip=null,this.terrainFlat=null,this.terrainClipClone=null,this.terrainFlatClone=null,this.createTerrainModifyInstance()}getDataFromFlattenedEvnModifyListById(a){const o=this.flattenedEvnModifyData.find(c=>c.id==a);return o||null}getModelFromMapById(a,o){let c;switch(o==null?void 0:o.isClone){case!0:c=window.mapClone?window.mapClone.mapEx.getLayers():[];break;case!1:c=window.map.getLayers();break}return c.find(u=>u.options.modelId==a)}updateFlattenedEvnModifyData(a){this.flattenedEvnModifyData=a}modelCutById(a,o,c,f){const u=bimModel.queryModel(a,f);if(u&&!u.clip.list.find(m=>m.id==c))switch(u.clip.addArea(o.length>1?o:o[0],{id:c}),f==null?void 0:f.isClone){case!0:this.modelIdListByModifyClone.push(a),this.modelIdListByModifyClone=[...new Set(this.modelIdListByModifyClone)];break;case!1:this.modelIdListByModify.push(a),this.modelIdListByModify=[...new Set(this.modelIdListByModify)];break}}modelFlattenById(a,o,c,f,u){const m=bimModel.queryModel(a,u);if(m&&!m.flat.list.find(g=>g.id==f))switch(m.flat.addArea(o.length>1?o:o[0],{height:c,id:f}),u==null?void 0:u.isClone){case!0:this.modelIdListByModifyClone.push(a),this.modelIdListByModifyClone=[...new Set(this.modelIdListByModifyClone)];break;case!1:this.modelIdListByModify.push(a),this.modelIdListByModify=[...new Set(this.modelIdListByModify)];break}}clearModelCutById(a,o,c){const f=bimModel.queryModel(a,c);if(f)switch(f.clip.removeArea(o),c.isClone){case!0:this.modelIdListByModifyClone=this.modelIdListByModifyClone.filter(u=>u!=a);break;case!1:this.modelIdListByModify=this.modelIdListByModify.filter(u=>u!=a);break}}clearModelFlattenById(a,o,c){const f=bimModel.queryModel(a,c);if(f)switch(f.flat.removeArea(o),c==null?void 0:c.isClone){case!0:this.modelIdListByModifyClone=this.modelIdListByModifyClone.filter(u=>u!=a);break;case!1:this.modelIdListByModify=this.modelIdListByModify.filter(u=>u!=a);break}}createTerrainModifyInstance(){if(window.map.thing.terrainClip)this.terrainClip=window.map.thing.terrainClip;else{const a=new mars3d.thing.TerrainClip({czm:!1,splitNum:30});window.map.addThing(a),this.terrainClip=a}if(window.map.thing.terrainFlat)this.terrainFlat=window.map.thing.terrainFlat;else{const a=new mars3d.thing.TerrainFlat({splitNum:80});window.map.addThing(a),this.terrainFlat=a}}createTerrainModifyInstanceClone(){if(window.mapClone){if(window.mapClone.mapEx.thing.terrainClip)this.terrainClipClone=window.mapClone.mapEx.thing.terrainClip;else{const a=new mars3d.thing.TerrainClip({splitNum:80});window.mapClone.mapEx.addThing(a),this.terrainClipClone=a}if(window.mapClone.mapEx.thing.terrainFlat)this.terrainFlatClone=window.mapClone.mapEx.thing.terrainFlat;else{const a=new mars3d.thing.TerrainFlat({splitNum:80});window.mapClone.mapEx.addThing(a),this.terrainFlatClone=a}}}evnModifyById(a,o){o=arguments[1]||{isClone:!1};const c=this.getDataFromFlattenedEvnModifyListById(a);if(!c)return;const{bimEnvModify:{embsId:f,dataType:u,modifyType:m}}=c;for(let g=0;g<c.bimEnvModifyData.length;g++){const v=this.getPositions(JSON.parse(c.bimEnvModifyData[g].modifyData).coordinates),S=JSON.parse(c.bimEnvModifyData[g].modifyData).depth,b=c.bimEnvModifyData[g].id;u===0&&m===0?this.modelCutById(f,v,b,o):u===0&&m===1?this.modelFlattenById(f,v,S,b,o):u===1&&m===0?this.terrainCutById(v,b,o):u===1&&m===1&&this.terrainFlattenById(v,S,b,o)}}evnModifyByIdAndAddOptionsToStore(a,o){o=arguments[1]||{isClone:!1};const c=this.getDataFromFlattenedEvnModifyListById(a);if(!c)return;const{bimEnvModify:{embsId:f,dataType:u,modifyType:m}}=c;for(let g=0;g<c.bimEnvModifyData.length;g++){const v=this.getPositions(JSON.parse(c.bimEnvModifyData[g].modifyData).coordinates),S=JSON.parse(c.bimEnvModifyData[g].modifyData).depth,b=c.bimEnvModifyData[g].id;u===0&&m===0?this.modelCutById(f,v,b,o):u===0&&m===1?this.modelFlattenById(f,v,S,b,o):u===1&&m===0?this.terrainCutById(v,b,o):u===1&&m===1&&this.terrainFlattenById(v,S,b,o)}}clearEvnModifyById(a,o){o=arguments[1]||{isClone:!1};const c=this.getDataFromFlattenedEvnModifyListById(a);if(!c)return;const{bimEnvModify:{embsId:f,dataType:u,modifyType:m}}=c;for(let g=0;g<c.bimEnvModifyData.length;g++){const v=c.bimEnvModifyData[g].id;u===0&&m===0?this.clearModelCutById(f,v,o):u===0&&m===1?this.clearModelFlattenById(f,v,o):u===1&&m===0?this.clearTerrainCutById(v,o):u===1&&m===1&&this.clearTerrainFlattenById(v,o)}}clearAllModelModify(a){switch(a||(a={isClone:!1}),a.isClone){case!0:this.modelIdListByModifyClone.forEach(o=>{const c=bimModel.queryModel(o,a);c&&(c.clip.clear(),c.flat.clear())}),this.modelIdListByModifyClone=[];break;case!1:this.modelIdListByModify.forEach(o=>{const c=bimModel.queryModel(o,a);c&&(c.clip.clear(),c.flat.clear())}),this.modelIdListByModify=[];break}}clearAllTerrainModify(a){switch(a||(a={isClone:!1}),a.isClone){case!0:window.mapClone||(this.terrainClipClone=null,this.terrainFlatClone=null),this.terrainClipClone&&this.terrainClipClone.clear(),this.terrainFlatClone&&this.terrainFlatClone.clear();break;case!1:this.terrainClip&&this.terrainClip.clear(),this.terrainFlat&&this.terrainFlat.clear();break}}getModelModifyDataForInitModelById(a){const o=this.getDataFromFlattenedEvnModifyListById(a);if(!o)return;const{bimEnvModify:{embsId:c,dataType:f,modifyType:u}}=o;if(this.modelIdListByModify.push(c),f===0&&u===0){const m={modelId:c,type:"clip",area:[]};for(let g=0;g<o.bimEnvModifyData.length;g++){const S={positions:this.getPositions(JSON.parse(o.bimEnvModifyData[g].modifyData).coordinates),id:o.bimEnvModifyData[g].id};m.area.push(S)}return m}else if(f===0&&u===1){const m={modelId:c,type:"flat",area:[]};for(let g=0;g<o.bimEnvModifyData.length;g++){const v=this.getPositions(JSON.parse(o.bimEnvModifyData[g].modifyData).coordinates),S={id:o.bimEnvModifyData[g].id,positions:v,height:JSON.parse(o.bimEnvModifyData[g].modifyData).depth};return m.area.push(S),m}}}clearAllEvnModify(){this.clearAllModelModify({isClone:!0}),this.clearAllModelModify({isClone:!1}),this.clearAllTerrainModify({isClone:!0}),this.clearAllTerrainModify({isClone:!1})}destroyTerrainModifyInstance(){this.clearAllTerrainModify({isClone:!0}),this.clearAllTerrainModify({isClone:!1}),this.terrainClip&&window.map.removeThing(this.terrainClip,!0),this.terrainFlat&&window.map.removeThing(this.terrainFlat,!0),this.terrainClipClone&&window.mapClone.mapEx.removeThing(this.terrainClipClone,!0),this.terrainFlatClone&&window.mapClone.mapEx.removeThing(this.terrainFlatClone,!0),this.terrainClip=null,this.terrainFlat=null,this.terrainClipClone=null,this.terrainFlatClone=null}}let Gl=null,gs=null,na=null;class Gg{constructor(){mars3d&&(this.projectId=parseInt(window.sessionStorage.getItem("nowProjectId")),this.viewPoints=new Array,this.roaming=null)}init(a,o,c){gs=new mars3d.layer.GraphicLayer({isContinued:!0});var f=this;window.map.addLayer(gs),gs.on(mars3d.EventType.drawCreated,function(u){var m=u.graphic.point;o(m),setTimeout(()=>{f.startDrawGraphic()},500)}),gs.on(mars3d.EventType.editStop,function(u){}),na=c,Gl=new mars3d.layer.GraphicLayer,window.map.addLayer(Gl),a&&(this.viewPoints=a.filter((u,m)=>{if(m%(na.smooth*1)==0)return u})),this.addGraphicLayer(this.viewPoints)}addDemoGraphic1(a,o){const c=new mars3d.graphic.PolylinePrimitive({positions:a.map(f=>[f.lng,f.lat,f.alt+1e3]),style:{width:10,materialType:mars3d.MaterialType.LineFlow,materialOptions:{color:"red",image:o+"img/line/line-arrow-blue.png",speed:10,repeat:new Cesium.Cartesian2(5,1),mixt:!0}}});Gl.addGraphic(c)}addGraphicLayer(a){var o={};na.Viewovalue==1?o={camera:{type:"dy",followedX:na.followedX,followedZ:na.followedZ},interpolation:!0,interpolationDegree:6,autoMiddleDynamicPosition:!0,interpolationAlgorithm:Cesium.HermitePolynomialApproximation}:na.Viewovalue==2?o={camera:{type:"gs",pitch:-30,radius:500},interpolation:!0,interpolationDegree:2,clockLoop:!0,path:{width:3,color:Cesium.Color.fromCssColorString("#ff0000").withAlpha(.5)}}:o={camera:{type:"sd",followedZ:na.followedZ},polyline:{width:3,color:Cesium.Color.fromCssColorString("#ff0000").withAlpha(.5)}},a=a.map(c=>[c.lng,c.lat,c.alt]),a.length,this.fixedRoute=new mars3d.graphic.FixedRoute({name:"贴地表表面漫游",speed:na.speed,autoStop:!0,positions:a,offsetHeight:1.6,clockLoop:!0,...o}),Gl.addGraphic(this.fixedRoute)}addDemoGraphic(a,o){const c=new mars3d.graphic.BillboardEntity({position:new mars3d.LngLatPoint(a.lng,a.lat,a.alt),style:{width:30,height:32,image:"/img/marker/markffd700.png",scale:1,scaleByDistance:!1,scaleByDistance_far:1e6,scaleByDistance_farValue:.1,scaleByDistance_near:1e3,scaleByDistance_nearValue:1,distanceDisplayCondition:!1,distanceDisplayCondition_far:2e6,distanceDisplayCondition_near:0,clampToGround:!1,visibleDepth:!1,drawShow:!0}});gs.addGraphic(c)}startDrawGraphic(a){gs.startDraw({type:"billboard",style:{width:30,height:32,image:"/img/marker/markffd700.png",scale:1,scaleByDistance:!1,scaleByDistance_far:1e6,scaleByDistance_farValue:.1,scaleByDistance_near:1e3,scaleByDistance_nearValue:1,distanceDisplayCondition:!1,distanceDisplayCondition_far:2e6,distanceDisplayCondition_near:0,clampToGround:!1,visibleDepth:!1,drawShow:!0,classificationType:Cesium.ClassificationType.TERRAIN}}).then(o=>{})}start(){this.fixedRoute&&(this.fixedRoute.start(),window.map.scene.screenSpaceCameraController.enableCollisionDetection=!1)}pause(){this.fixedRoute&&this.fixedRoute.pause()}resume(){this.fixedRoute&&this.fixedRoute.proceed()}stop(){this.fixedRoute&&this.fixedRoute.stop()}remove(){this.fixedRoute&&this.fixedRoute.stop(),window.map.removeThing(this.roaming,!0),window.map.removeLayer(Gl,!0),window.map.removeLayer(gs,!0),this.viewPoints=[],window.map.scene.screenSpaceCameraController.enableCollisionDetection=!0}removeCameraRoute(){Gl.clear(),gs.clear()}removegraphicLayerpoint(){gs.clear()}}class Hg{constructor(a){window.mars3d&&(this.beginDate="",this.endDate="",this.trafficSimulationLayer,this.trafficSimulationArr=[],this.style={width:4,materialType:window.mars3d.MaterialType.LineFlow,materialOptions:{color:"#4ac2ff",image:a+"img/textures/line-arrow-right.png",repeat_x:20,repeat_y:1,speed:20},clampToGround:!1,allowDrillPick:!1},this.vehicleSum=100,this.automobileList=[{url:a+"gltf/cart/suv.gltf"},{url:a+"gltf/cart/red_car.gltf"},{url:a+"gltf/cart/benchi3.gltf"},{url:a+"gltf/cart/suv.gltf"},{url:a+"gltf/cart/red_car.gltf"},{url:a+"gltf/cart/benchi3.gltf"},{url:a+"gltf/cart/aodi1.gltf"},{url:a+"gltf/cart/kache3.gltf"},{url:a+"gltf/cart/bus2.gltf"},{url:a+"gltf/cart/jiaobanche.glb"}],this._czmlLayer,this._czmlLayerArr=[])}init(a){this.trafficSimulationLayer=new window.mars3d.layer.GraphicLayer({temporaryLayer:"trafficSimulation"}),window.map.addLayer(this.trafficSimulationLayer),window.map.bimMapEdit="1",a&&(this._czmlLayerArr=a)}addLine(a){let o=a;return new Promise(c=>{this.trafficSimulationLayer.startDraw({type:"polylineP",attr:{trafficSimulationId:o},style:{...this.style}}).then(f=>{c({id:o,pointSet:f.coordinates,speed:45,interval:1})})})}initLine(a){let o;a.forEach(c=>{let{id:f}=c;o=new window.mars3d.graphic.PolylinePrimitive({positions:c.pointSet,attr:{trafficSimulationId:f},style:{...this.style}}),this.trafficSimulationLayer.addGraphic(o)})}positionLine(a){let o=this.queryTrafficSimulationLine(a);o&&o.flyTo({scale:2})}deleteLine(a){let o=this.queryTrafficSimulationLine(a);o&&o.remove()}queryTrafficSimulationArr(){return this.trafficSimulationArr}queryTrafficSimulationLine(a){if(this.trafficSimulationLayer)return this.trafficSimulationLayer.getGraphicByAttr(a,"trafficSimulationId")}editTrafficSimulationLine(a,o=!0){let c=this.queryTrafficSimulationLine(a);o?(c.setStyle({materialOptions:{color:"#ff0000"}}),c.startEditing()):(c.setStyle({materialOptions:{color:"#4ac2ff"}}),c.stopEditing())}fallbackTrafficSimulationLine(a,o){let c=this.queryTrafficSimulationLine(a);c.positions=o,c.setStyle({materialOptions:{color:"#4ac2ff"}}),c.stopEditing()}queryCzml(a){return this._czmlLayerArr.length==0?!1:this._czmlLayerArr.find(o=>o.id==a)}start(a="add"){this.destruction(),this.beginDate=new Date().toISOString();let o=new Date,c=o.getDate();o.setDate(c+1),this.endDate=o.toISOString(),this.queryCzml(a)?this.trafficSimulationArr=JSON.parse(this.queryCzml(a).route):this.trafficSimulationArr=[],this.processingData(a)}selected(){this._czmlLayer&&this._czmlLayer.flyTo()}destruction(){this.trafficSimulationLayer.clear(),this.trafficSimulationLayer.remove(),this._czmlLayer&&(this._czmlLayer.clear(),this._czmlLayer.remove()),this.style.materialOptions.color="#4ac2ff",window.map.bimMapEdit="0"}processingData(a){let o=[{version:"1.0",id:"document",clock:{interval:`${this.beginDate}/${this.endDate}`,currentTime:this.beginDate,multiplier:1},style:{distanceDisplayCondition:!0,distanceDisplayCondition_far:1e6,distanceDisplayCondition_near:0}}],c=[],f=JSON.parse(JSON.stringify(this.trafficSimulationArr)),u=0;f.forEach((g,v)=>{let S=0,b=0,{pointSet:O,interval:k,speed:I}=g;for(let F=1;F<=this.vehicleSum;F++){let E=JSON.parse(JSON.stringify(O));E.forEach((w,M)=>{M>0&&(u=parseFloat((this.disTance(w,E[M-1].slice(1))/I).toFixed(2)),S+=u),M==0&&(S=b),w.unshift(S)}),b+=k,c=E.reduce((w,M)=>w.concat(M));let P={name:`${v}-${F}`,availability:`${this.beginDate}/${this.endDate}`,orientation:{velocityReference:"#position"},position:{epoch:this.beginDate,cartographicDegrees:c},style:{minimumPixelSize:100,distanceDisplayCondition:!0,distanceDisplayCondition_near:0,distanceDisplayCondition_far:1300,distanceDisplayPoint:{color:"#00ff00",pixelSize:8}},model:{show:!0,gltf:this.randomVehicle(),heightReference:window.Cesium.HeightReference.CLAMP_TO_GROUND,clampToGround:!0,scale:.6,minimumPixelSize:100,maximumScale:1.5}};o.push(P)}});let m={name:"交通模拟",czmlId:a,data:o,autoUpdateClock:!1};this._czmlLayer=new window.mars3d.layer.CzmlLayer(m),window.map.addLayer(this._czmlLayer)}disTance(a,o){let c,f,u;return c=window.Cesium.Cartesian3.fromDegrees(...a),f=window.Cesium.Cartesian3.fromDegrees(...o),u=window.Cesium.Cartesian3.distance(c,f),u}randomVehicle(){let a=Math.round(Math.random()*(this.automobileList.length-1));return this.automobileList[a].url}}const Vg=[Tf,Ef],Wg={continuation:null,mapModali:null,install(x){if(Vg.forEach((m,g)=>{x.component(m.name,m)}),this.continuation){x.config.globalProperties.$continuation=this.continuation;return}let a=oi.createApp(Mf),o=document.createElement("div"),c=document.body;if(c.appendChild(o),this.loading=a.mount(o),x.config.globalProperties.$loading=this.loading,window.$continuation=this.loading,this.mapModali){x.config.globalProperties.$mapModali=this.mapModali;return}let f=oi.createApp(Sf),u=document.createElement("div");c.appendChild(u),this.mapModali=f.mount(u),x.config.globalProperties.$mapModali=this.mapModali,window.$mapModali=this.mapModali}};Pi.BimBackgroundPlate=Ef,Pi.BimCutscenes=Mf,Pi.BimElevationImage=um,Pi.BimEntity=fm,Pi.BimModel=sm,Pi.BimModify=Ug,Pi.BimTerrainProvider=hm,Pi.BimTrafficSimulation=Hg,Pi.BimVector=lm,Pi.Bimroaming=Gg,Pi.Button=Tf,Pi.ChbimPlugins=Wg,Pi.DynamicMasking=Og,Pi.MapModali=Sf,Pi.PanoramicView=vm,Pi.ViewShed=cm,Pi.getSameKeyData=Bg,Pi.init=Ig,Pi.initMap=Fg,Pi.isValidRGBA=Ng,Pi.nextPage=zg,Pi.operateMapData=kg,Pi.previousPage=Dg,Object.defineProperty(Pi,Symbol.toStringTag,{value:"Module"})});
|