UNPKG

jamis

Version:

一种支持通过JSON配置方式生成页面的组件库

14 lines (12 loc) 1.03 MB
/*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */var yp=function(r,e){return yp=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,a){t.__proto__=a}||function(t,a){for(var n in a)Object.prototype.hasOwnProperty.call(a,n)&&(t[n]=a[n])},yp(r,e)};function k(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");yp(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var DI=function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r}(),LI=function(){function r(){this.browser=new DI,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"}return r}(),Rn=new LI;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(Rn.wxa=!0,Rn.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?Rn.worker=!0:typeof navigator>"u"?(Rn.node=!0,Rn.svgSupported=!0):II(navigator.userAgent,Rn);function II(r,e){var t=e.browser,a=r.match(/Firefox\/([\d.]+)/),n=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),i=r.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(r);a&&(t.firefox=!0,t.version=a[1]),n&&(t.ie=!0,t.version=n[1]),i&&(t.edge=!0,t.version=i[1],t.newEdge=+i[1].split(".")[0]>18),o&&(t.weChat=!0),e.svgSupported=typeof SVGRect<"u",e.touchEventsSupported="ontouchstart"in window&&!t.ie&&!t.edge,e.pointerEventsSupported="onpointerdown"in window&&(t.edge||t.ie&&+t.version>=11),e.domSupported=typeof document<"u";var s=document.documentElement.style;e.transform3dSupported=(t.ie&&"transition"in s||t.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),e.transformSupported=e.transform3dSupported||t.ie&&+t.version>=9}const Ct=Rn;var ng=12,yw="sans-serif",Xa=ng+"px "+yw,PI=20,RI=100,EI="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function kI(r){var e={};if(typeof JSON>"u")return e;for(var t=0;t<r.length;t++){var a=String.fromCharCode(t+32),n=(r.charCodeAt(t)-PI)/RI;e[a]=n}return e}var OI=kI(EI),Tr={createCanvas:function(){return typeof document<"u"&&document.createElement("canvas")},measureText:function(){var r,e;return function(t,a){if(!r){var n=Tr.createCanvas();r=n&&n.getContext("2d")}if(r)return e!==a&&(e=r.font=a||Xa),r.measureText(t);t=t||"",a=a||Xa;var i=/^([0-9]*?)px$/.exec(a),o=+(i&&i[1])||ng,s=0;if(a.indexOf("mono")>=0)s=o*t.length;else for(var l=0;l<t.length;l++){var u=OI[t[l]];s+=u==null?o:u*o}return{width:s}}}(),loadImage:function(r,e,t){var a=new Image;return a.onload=e,a.onerror=t,a.src=r,a}};function mw(r){for(var e in Tr)r[e]&&(Tr[e]=r[e])}var _w=sr(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(r,e){return r["[object "+e+"]"]=!0,r},{}),Sw=sr(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(r,e){return r["[object "+e+"Array]"]=!0,r},{}),vo=Object.prototype.toString,sh=Array.prototype,NI=sh.forEach,VI=sh.filter,ig=sh.slice,BI=sh.map,bm=(function(){}).constructor,Gl=bm?bm.prototype:null,og="__proto__",zI=2311;function sg(){return zI++}function lh(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];typeof console<"u"&&console.error.apply(console,r)}function J(r){if(r==null||typeof r!="object")return r;var e=r,t=vo.call(r);if(t==="[object Array]"){if(!Xi(r)){e=[];for(var a=0,n=r.length;a<n;a++)e[a]=J(r[a])}}else if(Sw[t]){if(!Xi(r)){var i=r.constructor;if(i.from)e=i.from(r);else{e=new i(r.length);for(var a=0,n=r.length;a<n;a++)e[a]=r[a]}}}else if(!_w[t]&&!Xi(r)&&!eo(r)){e={};for(var o in r)r.hasOwnProperty(o)&&o!==og&&(e[o]=J(r[o]))}return e}function it(r,e,t){if(!Q(e)||!Q(r))return t?J(e):r;for(var a in e)if(e.hasOwnProperty(a)&&a!==og){var n=r[a],i=e[a];Q(i)&&Q(n)&&!z(i)&&!z(n)&&!eo(i)&&!eo(n)&&!mp(i)&&!mp(n)&&!Xi(i)&&!Xi(n)?it(n,i,t):(t||!(a in r))&&(r[a]=J(e[a]))}return r}function uh(r,e){for(var t=r[0],a=1,n=r.length;a<n;a++)t=it(t,r[a],e);return t}function B(r,e){if(Object.assign)Object.assign(r,e);else for(var t in e)e.hasOwnProperty(t)&&t!==og&&(r[t]=e[t]);return r}function j(r,e,t){for(var a=yt(e),n=0;n<a.length;n++){var i=a[n];(t?e[i]!=null:r[i]==null)&&(r[i]=e[i])}return r}var GI=Tr.createCanvas;function ut(r,e){if(r){if(r.indexOf)return r.indexOf(e);for(var t=0,a=r.length;t<a;t++)if(r[t]===e)return t}return-1}function lg(r,e){var t=r.prototype;function a(){}a.prototype=e.prototype,r.prototype=new a;for(var n in t)t.hasOwnProperty(n)&&(r.prototype[n]=t[n]);r.prototype.constructor=r,r.superClass=e}function Ut(r,e,t){if(r="prototype"in r?r.prototype:r,e="prototype"in e?e.prototype:e,Object.getOwnPropertyNames)for(var a=Object.getOwnPropertyNames(e),n=0;n<a.length;n++){var i=a[n];i!=="constructor"&&(t?e[i]!=null:r[i]==null)&&(r[i]=e[i])}else j(r,e,t)}function fe(r){return!r||typeof r=="string"?!1:typeof r.length=="number"}function C(r,e,t){if(r&&e)if(r.forEach&&r.forEach===NI)r.forEach(e,t);else if(r.length===+r.length)for(var a=0,n=r.length;a<n;a++)e.call(t,r[a],a,r);else for(var i in r)r.hasOwnProperty(i)&&e.call(t,r[i],i,r)}function G(r,e,t){if(!r)return[];if(!e)return fh(r);if(r.map&&r.map===BI)return r.map(e,t);for(var a=[],n=0,i=r.length;n<i;n++)a.push(e.call(t,r[n],n,r));return a}function sr(r,e,t,a){if(r&&e){for(var n=0,i=r.length;n<i;n++)t=e.call(a,t,r[n],n,r);return t}}function It(r,e,t){if(!r)return[];if(!e)return fh(r);if(r.filter&&r.filter===VI)return r.filter(e,t);for(var a=[],n=0,i=r.length;n<i;n++)e.call(t,r[n],n,r)&&a.push(r[n]);return a}function xw(r,e,t){if(r&&e){for(var a=0,n=r.length;a<n;a++)if(e.call(t,r[a],a,r))return r[a]}}function yt(r){if(!r)return[];if(Object.keys)return Object.keys(r);var e=[];for(var t in r)r.hasOwnProperty(t)&&e.push(t);return e}function FI(r,e){for(var t=[],a=2;a<arguments.length;a++)t[a-2]=arguments[a];return function(){return r.apply(e,t.concat(ig.call(arguments)))}}var U=Gl&&K(Gl.bind)?Gl.call.bind(Gl.bind):FI;function nt(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return function(){return r.apply(this,e.concat(ig.call(arguments)))}}function z(r){return Array.isArray?Array.isArray(r):vo.call(r)==="[object Array]"}function K(r){return typeof r=="function"}function $(r){return typeof r=="string"}function ff(r){return vo.call(r)==="[object String]"}function xt(r){return typeof r=="number"}function Q(r){var e=typeof r;return e==="function"||!!r&&e==="object"}function mp(r){return!!_w[vo.call(r)]}function Ve(r){return!!Sw[vo.call(r)]}function eo(r){return typeof r=="object"&&typeof r.nodeType=="number"&&typeof r.ownerDocument=="object"}function pl(r){return r.colorStops!=null}function bw(r){return r.image!=null}function ww(r){return vo.call(r)==="[object RegExp]"}function ro(r){return r!==r}function ee(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];for(var t=0,a=r.length;t<a;t++)if(r[t]!=null)return r[t]}function ht(r,e){return r??e}function Wr(r,e,t){return r??e??t}function fh(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return ig.apply(r,e)}function hh(r){if(typeof r=="number")return[r,r,r,r];var e=r.length;return e===2?[r[0],r[1],r[0],r[1]]:e===3?[r[0],r[1],r[2],r[1]]:r}function me(r,e){if(!r)throw new Error(e)}function ir(r){return r==null?null:typeof r.trim=="function"?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var Tw="__ec_primitive__";function Ns(r){r[Tw]=!0}function Xi(r){return r[Tw]}var Cw=function(){function r(e){this.data={};var t=z(e);this.data={};var a=this;e instanceof r?e.each(n):e&&C(e,n);function n(i,o){t?a.set(i,o):a.set(o,i)}}return r.prototype.get=function(e){return this.data.hasOwnProperty(e)?this.data[e]:null},r.prototype.set=function(e,t){return this.data[e]=t},r.prototype.each=function(e,t){for(var a in this.data)this.data.hasOwnProperty(a)&&e.call(t,this.data[a],a)},r.prototype.keys=function(){return yt(this.data)},r.prototype.removeKey=function(e){delete this.data[e]},r}();function q(r){return new Cw(r)}function Vs(r,e){for(var t=new r.constructor(r.length+e.length),a=0;a<r.length;a++)t[a]=r[a];for(var n=r.length,a=0;a<e.length;a++)t[a+n]=e[a];return t}function dl(r,e){var t;if(Object.create)t=Object.create(r);else{var a=function(){};a.prototype=r,t=new a}return e&&B(t,e),t}function ug(r){var e=r.style;e.webkitUserSelect="none",e.userSelect="none",e.webkitTapHighlightColor="rgba(0,0,0,0)",e["-webkit-touch-callout"]="none"}function Y(r,e){return r.hasOwnProperty(e)}function Zt(){}var Ss=180/Math.PI;const HI=Object.freeze(Object.defineProperty({__proto__:null,HashMap:Cw,RADIAN_TO_DEGREE:Ss,assert:me,bind:U,clone:J,concatArray:Vs,createCanvas:GI,createHashMap:q,createObject:dl,curry:nt,defaults:j,disableUserSelect:ug,each:C,eqNaN:ro,extend:B,filter:It,find:xw,guid:sg,hasOwn:Y,indexOf:ut,inherits:lg,isArray:z,isArrayLike:fe,isBuiltInObject:mp,isDom:eo,isFunction:K,isGradientObject:pl,isImagePatternObject:bw,isNumber:xt,isObject:Q,isPrimitive:Xi,isRegExp:ww,isString:$,isStringSafe:ff,isTypedArray:Ve,keys:yt,logError:lh,map:G,merge:it,mergeAll:uh,mixin:Ut,noop:Zt,normalizeCssArray:hh,reduce:sr,retrieve:ee,retrieve2:ht,retrieve3:Wr,setAsPrimitive:Ns,slice:fh,trim:ir},Symbol.toStringTag,{value:"Module"}));function rn(r,e){return r==null&&(r=0),e==null&&(e=0),[r,e]}function de(r,e){return r[0]=e[0],r[1]=e[1],r}function $r(r){return[r[0],r[1]]}function Aw(r,e,t){return r[0]=e,r[1]=t,r}function _p(r,e,t){return r[0]=e[0]+t[0],r[1]=e[1]+t[1],r}function hf(r,e,t,a){return r[0]=e[0]+t[0]*a,r[1]=e[1]+t[1]*a,r}function Ea(r,e,t){return r[0]=e[0]-t[0],r[1]=e[1]-t[1],r}function Bs(r){return Math.sqrt(fg(r))}var WI=Bs;function fg(r){return r[0]*r[0]+r[1]*r[1]}var $I=fg;function UI(r,e,t){return r[0]=e[0]*t[0],r[1]=e[1]*t[1],r}function YI(r,e,t){return r[0]=e[0]/t[0],r[1]=e[1]/t[1],r}function ZI(r,e){return r[0]*e[0]+r[1]*e[1]}function Wu(r,e,t){return r[0]=e[0]*t,r[1]=e[1]*t,r}function co(r,e){var t=Bs(e);return t===0?(r[0]=0,r[1]=0):(r[0]=e[0]/t,r[1]=e[1]/t),r}function vf(r,e){return Math.sqrt((r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1]))}var na=vf;function Mw(r,e){return(r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1])}var Fa=Mw;function XI(r,e){return r[0]=-e[0],r[1]=-e[1],r}function xs(r,e,t,a){return r[0]=e[0]+a*(t[0]-e[0]),r[1]=e[1]+a*(t[1]-e[1]),r}function ie(r,e,t){var a=e[0],n=e[1];return r[0]=t[0]*a+t[2]*n+t[4],r[1]=t[1]*a+t[3]*n+t[5],r}function ia(r,e,t){return r[0]=Math.min(e[0],t[0]),r[1]=Math.min(e[1],t[1]),r}function oa(r,e,t){return r[0]=Math.max(e[0],t[0]),r[1]=Math.max(e[1],t[1]),r}const qI=Object.freeze(Object.defineProperty({__proto__:null,add:_p,applyTransform:ie,clone:$r,copy:de,create:rn,dist:na,distSquare:Fa,distance:vf,distanceSquare:Mw,div:YI,dot:ZI,len:Bs,lenSquare:fg,length:WI,lengthSquare:$I,lerp:xs,max:oa,min:ia,mul:UI,negate:XI,normalize:co,scale:Wu,scaleAndAdd:hf,set:Aw,sub:Ea},Symbol.toStringTag,{value:"Module"}));var gi=function(){function r(e,t){this.target=e,this.topTarget=t&&t.topTarget}return r}(),KI=function(){function r(e){this.handler=e,e.on("mousedown",this._dragStart,this),e.on("mousemove",this._drag,this),e.on("mouseup",this._dragEnd,this)}return r.prototype._dragStart=function(e){for(var t=e.target;t&&!t.draggable;)t=t.parent||t.__hostTarget;t&&(this._draggingTarget=t,t.dragging=!0,this._x=e.offsetX,this._y=e.offsetY,this.handler.dispatchToElement(new gi(t,e),"dragstart",e.event))},r.prototype._drag=function(e){var t=this._draggingTarget;if(t){var a=e.offsetX,n=e.offsetY,i=a-this._x,o=n-this._y;this._x=a,this._y=n,t.drift(i,o,e),this.handler.dispatchToElement(new gi(t,e),"drag",e.event);var s=this.handler.findHover(a,n,t).target,l=this._dropTarget;this._dropTarget=s,t!==s&&(l&&s!==l&&this.handler.dispatchToElement(new gi(l,e),"dragleave",e.event),s&&s!==l&&this.handler.dispatchToElement(new gi(s,e),"dragenter",e.event))}},r.prototype._dragEnd=function(e){var t=this._draggingTarget;t&&(t.dragging=!1),this.handler.dispatchToElement(new gi(t,e),"dragend",e.event),this._dropTarget&&this.handler.dispatchToElement(new gi(this._dropTarget,e),"drop",e.event),this._draggingTarget=null,this._dropTarget=null},r}();const jI=KI;var QI=function(){function r(e){e&&(this._$eventProcessor=e)}return r.prototype.on=function(e,t,a,n){this._$handlers||(this._$handlers={});var i=this._$handlers;if(typeof t=="function"&&(n=a,a=t,t=null),!a||!e)return this;var o=this._$eventProcessor;t!=null&&o&&o.normalizeQuery&&(t=o.normalizeQuery(t)),i[e]||(i[e]=[]);for(var s=0;s<i[e].length;s++)if(i[e][s].h===a)return this;var l={h:a,query:t,ctx:n||this,callAtLast:a.zrEventfulCallAtLast},u=i[e].length-1,f=i[e][u];return f&&f.callAtLast?i[e].splice(u,0,l):i[e].push(l),this},r.prototype.isSilent=function(e){var t=this._$handlers;return!t||!t[e]||!t[e].length},r.prototype.off=function(e,t){var a=this._$handlers;if(!a)return this;if(!e)return this._$handlers={},this;if(t){if(a[e]){for(var n=[],i=0,o=a[e].length;i<o;i++)a[e][i].h!==t&&n.push(a[e][i]);a[e]=n}a[e]&&a[e].length===0&&delete a[e]}else delete a[e];return this},r.prototype.trigger=function(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];if(!this._$handlers)return this;var n=this._$handlers[e],i=this._$eventProcessor;if(n)for(var o=t.length,s=n.length,l=0;l<s;l++){var u=n[l];if(!(i&&i.filter&&u.query!=null&&!i.filter(e,u.query)))switch(o){case 0:u.h.call(u.ctx);break;case 1:u.h.call(u.ctx,t[0]);break;case 2:u.h.call(u.ctx,t[0],t[1]);break;default:u.h.apply(u.ctx,t);break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r.prototype.triggerWithContext=function(e){for(var t=[],a=1;a<arguments.length;a++)t[a-1]=arguments[a];if(!this._$handlers)return this;var n=this._$handlers[e],i=this._$eventProcessor;if(n)for(var o=t.length,s=t[o-1],l=n.length,u=0;u<l;u++){var f=n[u];if(!(i&&i.filter&&f.query!=null&&!i.filter(e,f.query)))switch(o){case 0:f.h.call(s);break;case 1:f.h.call(s,t[0]);break;case 2:f.h.call(s,t[0],t[1]);break;default:f.h.apply(s,t.slice(1,o-1));break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r}();const ur=QI;var JI=Math.log(2);function Sp(r,e,t,a,n,i){var o=a+"-"+n,s=r.length;if(i.hasOwnProperty(o))return i[o];if(e===1){var l=Math.round(Math.log((1<<s)-1&~n)/JI);return r[t][l]}for(var u=a|1<<t,f=t+1;a&1<<f;)f++;for(var h=0,v=0,c=0;v<s;v++){var p=1<<v;p&n||(h+=(c%2?-1:1)*r[t][v]*Sp(r,e-1,f,u,n|p,i),c++)}return i[o]=h,h}function wm(r,e){var t=[[r[0],r[1],1,0,0,0,-e[0]*r[0],-e[0]*r[1]],[0,0,0,r[0],r[1],1,-e[1]*r[0],-e[1]*r[1]],[r[2],r[3],1,0,0,0,-e[2]*r[2],-e[2]*r[3]],[0,0,0,r[2],r[3],1,-e[3]*r[2],-e[3]*r[3]],[r[4],r[5],1,0,0,0,-e[4]*r[4],-e[4]*r[5]],[0,0,0,r[4],r[5],1,-e[5]*r[4],-e[5]*r[5]],[r[6],r[7],1,0,0,0,-e[6]*r[6],-e[6]*r[7]],[0,0,0,r[6],r[7],1,-e[7]*r[6],-e[7]*r[7]]],a={},n=Sp(t,8,0,0,0,a);if(n!==0){for(var i=[],o=0;o<8;o++)for(var s=0;s<8;s++)i[s]==null&&(i[s]=0),i[s]+=((o+s)%2?-1:1)*Sp(t,7,o===0?1:0,1<<o,1<<s,a)/n*e[o];return function(l,u,f){var h=u*i[6]+f*i[7]+1;l[0]=(u*i[0]+f*i[1]+i[2])/h,l[1]=(u*i[3]+f*i[4]+i[5])/h}}}var Tm="___zrEVENTSAVED",Jh=[];function t2(r,e,t,a,n){return xp(Jh,e,a,n,!0)&&xp(r,t,Jh[0],Jh[1])}function xp(r,e,t,a,n){if(e.getBoundingClientRect&&Ct.domSupported&&!Dw(e)){var i=e[Tm]||(e[Tm]={}),o=e2(e,i),s=r2(o,i,n);if(s)return s(r,t,a),!0}return!1}function e2(r,e){var t=e.markers;if(t)return t;t=e.markers=[];for(var a=["left","right"],n=["top","bottom"],i=0;i<4;i++){var o=document.createElement("div"),s=o.style,l=i%2,u=(i>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",a[l]+":0",n[u]+":0",a[1-l]+":auto",n[1-u]+":auto",""].join("!important;"),r.appendChild(o),t.push(o)}return t}function r2(r,e,t){for(var a=t?"invTrans":"trans",n=e[a],i=e.srcCoords,o=[],s=[],l=!0,u=0;u<4;u++){var f=r[u].getBoundingClientRect(),h=2*u,v=f.left,c=f.top;o.push(v,c),l=l&&i&&v===i[h]&&c===i[h+1],s.push(r[u].offsetLeft,r[u].offsetTop)}return l&&n?n:(e.srcCoords=o,e[a]=t?wm(s,o):wm(o,s))}function Dw(r){return r.nodeName.toUpperCase()==="CANVAS"}var a2=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,tv=[],n2=Ct.browser.firefox&&+Ct.browser.version.split(".")[0]<39;function bp(r,e,t,a){return t=t||{},a?Cm(r,e,t):n2&&e.layerX!=null&&e.layerX!==e.offsetX?(t.zrX=e.layerX,t.zrY=e.layerY):e.offsetX!=null?(t.zrX=e.offsetX,t.zrY=e.offsetY):Cm(r,e,t),t}function Cm(r,e,t){if(Ct.domSupported&&r.getBoundingClientRect){var a=e.clientX,n=e.clientY;if(Dw(r)){var i=r.getBoundingClientRect();t.zrX=a-i.left,t.zrY=n-i.top;return}else if(xp(tv,r,a,n)){t.zrX=tv[0],t.zrY=tv[1];return}}t.zrX=t.zrY=0}function hg(r){return r||window.event}function Qe(r,e,t){if(e=hg(e),e.zrX!=null)return e;var a=e.type,n=a&&a.indexOf("touch")>=0;if(n){var o=a!=="touchend"?e.targetTouches[0]:e.changedTouches[0];o&&bp(r,o,e,t)}else{bp(r,e,e,t);var i=i2(e);e.zrDelta=i?i/120:-(e.detail||0)/3}var s=e.button;return e.which==null&&s!==void 0&&a2.test(e.type)&&(e.which=s&1?1:s&2?3:s&4?2:0),e}function i2(r){var e=r.wheelDelta;if(e)return e;var t=r.deltaX,a=r.deltaY;if(t==null||a==null)return e;var n=Math.abs(a!==0?a:t),i=a>0?-1:a<0?1:t>0?-1:1;return 3*n*i}function wp(r,e,t,a){r.addEventListener(e,t,a)}function o2(r,e,t,a){r.removeEventListener(e,t,a)}var ha=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function Am(r){return r.which===2||r.which===3}var s2=function(){function r(){this._track=[]}return r.prototype.recognize=function(e,t,a){return this._doTrack(e,t,a),this._recognize(e)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(e,t,a){var n=e.touches;if(n){for(var i={points:[],touches:[],target:t,event:e},o=0,s=n.length;o<s;o++){var l=n[o],u=bp(a,l,{});i.points.push([u.zrX,u.zrY]),i.touches.push(l)}this._track.push(i)}},r.prototype._recognize=function(e){for(var t in ev)if(ev.hasOwnProperty(t)){var a=ev[t](this._track,e);if(a)return a}},r}();function Mm(r){var e=r[1][0]-r[0][0],t=r[1][1]-r[0][1];return Math.sqrt(e*e+t*t)}function l2(r){return[(r[0][0]+r[1][0])/2,(r[0][1]+r[1][1])/2]}var ev={pinch:function(r,e){var t=r.length;if(t){var a=(r[t-1]||{}).points,n=(r[t-2]||{}).points||a;if(n&&n.length>1&&a&&a.length>1){var i=Mm(a)/Mm(n);!isFinite(i)&&(i=1),e.pinchScale=i;var o=l2(a);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:r[0].target,event:e}}}}},Lw="silent";function u2(r,e,t){return{type:r,event:t,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:t.zrX,offsetY:t.zrY,gestureEvent:t.gestureEvent,pinchX:t.pinchX,pinchY:t.pinchY,pinchScale:t.pinchScale,wheelDelta:t.zrDelta,zrByTouch:t.zrByTouch,which:t.which,stop:f2}}function f2(){ha(this.event)}var h2=function(r){k(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.handler=null,t}return e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e}(ur),Eo=function(){function r(e,t){this.x=e,this.y=t}return r}(),v2=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Iw=function(r){k(e,r);function e(t,a,n,i){var o=r.call(this)||this;return o._hovered=new Eo(0,0),o.storage=t,o.painter=a,o.painterRoot=i,n=n||new h2,o.proxy=null,o.setHandlerProxy(n),o._draggingMgr=new jI(o),o}return e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(C(v2,function(a){t.on&&t.on(a,this[a],this)},this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var a=t.zrX,n=t.zrY,i=Pw(this,a,n),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var l=this._hovered=i?new Eo(a,n):this.findHover(a,n),u=l.target,f=this.proxy;f.setCursor&&f.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(o,"mouseout",t),this.dispatchToElement(l,"mousemove",t),u&&u!==s&&this.dispatchToElement(l,"mouseover",t)},e.prototype.mouseout=function(t){var a=t.zrEventControl;a!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",t),a!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new Eo(0,0)},e.prototype.dispatch=function(t,a){var n=this[t];n&&n.call(this,a)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var a=this.proxy;a.setCursor&&a.setCursor(t)},e.prototype.dispatchToElement=function(t,a,n){t=t||{};var i=t.target;if(!(i&&i.silent)){for(var o="on"+a,s=u2(a,t,n);i&&(i[o]&&(s.cancelBubble=!!i[o].call(i,s)),i.trigger(a,s),i=i.__hostTarget?i.__hostTarget:i.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(a,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[o]=="function"&&l[o].call(l,s),l.trigger&&l.trigger(a,s)}))}},e.prototype.findHover=function(t,a,n){for(var i=this.storage.getDisplayList(),o=new Eo(t,a),s=i.length-1;s>=0;s--){var l=void 0;if(i[s]!==n&&!i[s].ignore&&(l=c2(i[s],t,a))&&(!o.topTarget&&(o.topTarget=i[s]),l!==Lw)){o.target=i[s];break}}return o},e.prototype.processGesture=function(t,a){this._gestureMgr||(this._gestureMgr=new s2);var n=this._gestureMgr;a==="start"&&n.clear();var i=n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if(a==="end"&&n.clear(),i){var o=i.type;t.gestureEvent=o;var s=new Eo;s.target=i.target,this.dispatchToElement(s,o,i.event)}},e}(ur);C(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(r){Iw.prototype[r]=function(e){var t=e.zrX,a=e.zrY,n=Pw(this,t,a),i,o;if((r!=="mouseup"||!n)&&(i=this.findHover(t,a),o=i.target),r==="mousedown")this._downEl=o,this._downPoint=[e.zrX,e.zrY],this._upEl=o;else if(r==="mouseup")this._upEl=o;else if(r==="click"){if(this._downEl!==this._upEl||!this._downPoint||na(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(i,r,e)}});function c2(r,e,t){if(r[r.rectHover?"rectContain":"contain"](e,t)){for(var a=r,n=void 0,i=!1;a;){if(a.ignoreClip&&(i=!0),!i){var o=a.getClipPath();if(o&&!o.contain(e,t))return!1;a.silent&&(n=!0)}var s=a.__hostTarget;a=s||a.parent}return n?Lw:!0}return!1}function Pw(r,e,t){var a=r.painter;return e<0||e>a.getWidth()||t<0||t>a.getHeight()}const p2=Iw;var Rw=32,ko=7;function d2(r){for(var e=0;r>=Rw;)e|=r&1,r>>=1;return r+e}function Dm(r,e,t,a){var n=e+1;if(n===t)return 1;if(a(r[n++],r[e])<0){for(;n<t&&a(r[n],r[n-1])<0;)n++;g2(r,e,n)}else for(;n<t&&a(r[n],r[n-1])>=0;)n++;return n-e}function g2(r,e,t){for(t--;e<t;){var a=r[e];r[e++]=r[t],r[t--]=a}}function Lm(r,e,t,a,n){for(a===e&&a++;a<t;a++){for(var i=r[a],o=e,s=a,l;o<s;)l=o+s>>>1,n(i,r[l])<0?s=l:o=l+1;var u=a-o;switch(u){case 3:r[o+3]=r[o+2];case 2:r[o+2]=r[o+1];case 1:r[o+1]=r[o];break;default:for(;u>0;)r[o+u]=r[o+u-1],u--}r[o]=i}}function rv(r,e,t,a,n,i){var o=0,s=0,l=1;if(i(r,e[t+n])>0){for(s=a-n;l<s&&i(r,e[t+n+l])>0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}else{for(s=n+1;l<s&&i(r,e[t+n-l])<=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=n-l,l=n-u}for(o++;o<l;){var f=o+(l-o>>>1);i(r,e[t+f])>0?o=f+1:l=f}return l}function av(r,e,t,a,n,i){var o=0,s=0,l=1;if(i(r,e[t+n])<0){for(s=n+1;l<s&&i(r,e[t+n-l])<0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=n-l,l=n-u}else{for(s=a-n;l<s&&i(r,e[t+n+l])>=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}for(o++;o<l;){var f=o+(l-o>>>1);i(r,e[t+f])<0?l=f:o=f+1}return l}function y2(r,e){var t=ko,a,n,i=0;r.length;var o=[];a=[],n=[];function s(c,p){a[i]=c,n[i]=p,i+=1}function l(){for(;i>1;){var c=i-2;if(c>=1&&n[c-1]<=n[c]+n[c+1]||c>=2&&n[c-2]<=n[c]+n[c-1])n[c-1]<n[c+1]&&c--;else if(n[c]>n[c+1])break;f(c)}}function u(){for(;i>1;){var c=i-2;c>0&&n[c-1]<n[c+1]&&c--,f(c)}}function f(c){var p=a[c],d=n[c],g=a[c+1],y=n[c+1];n[c]=d+y,c===i-3&&(a[c+1]=a[c+2],n[c+1]=n[c+2]),i--;var m=av(r[g],r,p,d,0,e);p+=m,d-=m,d!==0&&(y=rv(r[p+d-1],r,g,y,y-1,e),y!==0&&(d<=y?h(p,d,g,y):v(p,d,g,y)))}function h(c,p,d,g){var y=0;for(y=0;y<p;y++)o[y]=r[c+y];var m=0,_=d,S=c;if(r[S++]=r[_++],--g===0){for(y=0;y<p;y++)r[S+y]=o[m+y];return}if(p===1){for(y=0;y<g;y++)r[S+y]=r[_+y];r[S+g]=o[m];return}for(var b=t,x,w,T;;){x=0,w=0,T=!1;do if(e(r[_],o[m])<0){if(r[S++]=r[_++],w++,x=0,--g===0){T=!0;break}}else if(r[S++]=o[m++],x++,w=0,--p===1){T=!0;break}while((x|w)<b);if(T)break;do{if(x=av(r[_],o,m,p,0,e),x!==0){for(y=0;y<x;y++)r[S+y]=o[m+y];if(S+=x,m+=x,p-=x,p<=1){T=!0;break}}if(r[S++]=r[_++],--g===0){T=!0;break}if(w=rv(o[m],r,_,g,0,e),w!==0){for(y=0;y<w;y++)r[S+y]=r[_+y];if(S+=w,_+=w,g-=w,g===0){T=!0;break}}if(r[S++]=o[m++],--p===1){T=!0;break}b--}while(x>=ko||w>=ko);if(T)break;b<0&&(b=0),b+=2}if(t=b,t<1&&(t=1),p===1){for(y=0;y<g;y++)r[S+y]=r[_+y];r[S+g]=o[m]}else{if(p===0)throw new Error;for(y=0;y<p;y++)r[S+y]=o[m+y]}}function v(c,p,d,g){var y=0;for(y=0;y<g;y++)o[y]=r[d+y];var m=c+p-1,_=g-1,S=d+g-1,b=0,x=0;if(r[S--]=r[m--],--p===0){for(b=S-(g-1),y=0;y<g;y++)r[b+y]=o[y];return}if(g===1){for(S-=p,m-=p,x=S+1,b=m+1,y=p-1;y>=0;y--)r[x+y]=r[b+y];r[S]=o[_];return}for(var w=t;;){var T=0,A=0,M=!1;do if(e(o[_],r[m])<0){if(r[S--]=r[m--],T++,A=0,--p===0){M=!0;break}}else if(r[S--]=o[_--],A++,T=0,--g===1){M=!0;break}while((T|A)<w);if(M)break;do{if(T=p-av(o[_],r,c,p,p-1,e),T!==0){for(S-=T,m-=T,p-=T,x=S+1,b=m+1,y=T-1;y>=0;y--)r[x+y]=r[b+y];if(p===0){M=!0;break}}if(r[S--]=o[_--],--g===1){M=!0;break}if(A=g-rv(r[m],o,0,g,g-1,e),A!==0){for(S-=A,_-=A,g-=A,x=S+1,b=_+1,y=0;y<A;y++)r[x+y]=o[b+y];if(g<=1){M=!0;break}}if(r[S--]=r[m--],--p===0){M=!0;break}w--}while(T>=ko||A>=ko);if(M)break;w<0&&(w=0),w+=2}if(t=w,t<1&&(t=1),g===1){for(S-=p,m-=p,x=S+1,b=m+1,y=p-1;y>=0;y--)r[x+y]=r[b+y];r[S]=o[_]}else{if(g===0)throw new Error;for(b=S-(g-1),y=0;y<g;y++)r[b+y]=o[y]}}return{mergeRuns:l,forceMergeRuns:u,pushRun:s}}function $u(r,e,t,a){t||(t=0),a||(a=r.length);var n=a-t;if(!(n<2)){var i=0;if(n<Rw){i=Dm(r,t,a,e),Lm(r,t,a,t+i,e);return}var o=y2(r,e),s=d2(n);do{if(i=Dm(r,t,a,e),i<s){var l=n;l>s&&(l=s),Lm(r,t,t+l,t+i,e),i=l}o.pushRun(t,i),o.mergeRuns(),n-=i,t+=i}while(n!==0);o.forceMergeRuns()}}var Ge=1,ls=2,Vi=4,Im=!1;function nv(){Im||(Im=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function Pm(r,e){return r.zlevel===e.zlevel?r.z===e.z?r.z2-e.z2:r.z-e.z:r.zlevel-e.zlevel}var m2=function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=Pm}return r.prototype.traverse=function(e,t){for(var a=0;a<this._roots.length;a++)this._roots[a].traverse(e,t)},r.prototype.getDisplayList=function(e,t){t=t||!1;var a=this._displayList;return(e||!a.length)&&this.updateDisplayList(t),a},r.prototype.updateDisplayList=function(e){this._displayListLen=0;for(var t=this._roots,a=this._displayList,n=0,i=t.length;n<i;n++)this._updateAndAddDisplayable(t[n],null,e);a.length=this._displayListLen,$u(a,Pm)},r.prototype._updateAndAddDisplayable=function(e,t,a){if(!(e.ignore&&!a)){e.beforeUpdate(),e.update(),e.afterUpdate();var n=e.getClipPath();if(e.ignoreClip)t=null;else if(n){t?t=t.slice():t=[];for(var i=n,o=e;i;)i.parent=o,i.updateTransform(),t.push(i),o=i,i=i.getClipPath()}if(e.childrenRef){for(var s=e.childrenRef(),l=0;l<s.length;l++){var u=s[l];e.__dirty&&(u.__dirty|=Ge),this._updateAndAddDisplayable(u,t,a)}e.__dirty=0}else{var f=e;t&&t.length?f.__clipPaths=t:f.__clipPaths&&f.__clipPaths.length>0&&(f.__clipPaths=[]),isNaN(f.z)&&(nv(),f.z=0),isNaN(f.z2)&&(nv(),f.z2=0),isNaN(f.zlevel)&&(nv(),f.zlevel=0),this._displayList[this._displayListLen++]=f}var h=e.getDecalElement&&e.getDecalElement();h&&this._updateAndAddDisplayable(h,t,a);var v=e.getTextGuideLine();v&&this._updateAndAddDisplayable(v,t,a);var c=e.getTextContent();c&&this._updateAndAddDisplayable(c,t,a)}},r.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},r.prototype.delRoot=function(e){if(e instanceof Array){for(var t=0,a=e.length;t<a;t++)this.delRoot(e[t]);return}var n=ut(this._roots,e);n>=0&&this._roots.splice(n,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r}();const _2=m2;var Ew;Ew=Ct.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};const Tp=Ew;var Uu={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var e,t=.1,a=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=a/4):e=a*Math.asin(1/t)/(2*Math.PI),-(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/a)))},elasticOut:function(r){var e,t=.1,a=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=a/4):e=a*Math.asin(1/t)/(2*Math.PI),t*Math.pow(2,-10*r)*Math.sin((r-e)*(2*Math.PI)/a)+1)},elasticInOut:function(r){var e,t=.1,a=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=a/4):e=a*Math.asin(1/t)/(2*Math.PI),(r*=2)<1?-.5*(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/a)):t*Math.pow(2,-10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/a)*.5+1)},backIn:function(r){var e=1.70158;return r*r*((e+1)*r-e)},backOut:function(r){var e=1.70158;return--r*r*((e+1)*r+e)+1},backInOut:function(r){var e=2.5949095;return(r*=2)<1?.5*(r*r*((e+1)*r-e)):.5*((r-=2)*r*((e+1)*r+e)+2)},bounceIn:function(r){return 1-Uu.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?Uu.bounceIn(r*2)*.5:Uu.bounceOut(r*2-1)*.5+.5}};const kw=Uu;var Fl=Math.pow,Ha=Math.sqrt,cf=1e-8,Ow=1e-4,Rm=Ha(3),Hl=1/3,Br=rn(),rr=rn(),qi=rn();function ka(r){return r>-cf&&r<cf}function Nw(r){return r>cf||r<-cf}function Jt(r,e,t,a,n){var i=1-n;return i*i*(i*r+3*n*e)+n*n*(n*a+3*i*t)}function Em(r,e,t,a,n){var i=1-n;return 3*(((e-r)*i+2*(t-e)*n)*i+(a-t)*n*n)}function pf(r,e,t,a,n,i){var o=a+3*(e-t)-r,s=3*(t-e*2+r),l=3*(e-r),u=r-n,f=s*s-3*o*l,h=s*l-9*o*u,v=l*l-3*s*u,c=0;if(ka(f)&&ka(h))if(ka(s))i[0]=0;else{var p=-l/s;p>=0&&p<=1&&(i[c++]=p)}else{var d=h*h-4*f*v;if(ka(d)){var g=h/f,p=-s/o+g,y=-g/2;p>=0&&p<=1&&(i[c++]=p),y>=0&&y<=1&&(i[c++]=y)}else if(d>0){var m=Ha(d),_=f*s+1.5*o*(-h+m),S=f*s+1.5*o*(-h-m);_<0?_=-Fl(-_,Hl):_=Fl(_,Hl),S<0?S=-Fl(-S,Hl):S=Fl(S,Hl);var p=(-s-(_+S))/(3*o);p>=0&&p<=1&&(i[c++]=p)}else{var b=(2*f*s-3*o*h)/(2*Ha(f*f*f)),x=Math.acos(b)/3,w=Ha(f),T=Math.cos(x),p=(-s-2*w*T)/(3*o),y=(-s+w*(T+Rm*Math.sin(x)))/(3*o),A=(-s+w*(T-Rm*Math.sin(x)))/(3*o);p>=0&&p<=1&&(i[c++]=p),y>=0&&y<=1&&(i[c++]=y),A>=0&&A<=1&&(i[c++]=A)}}return c}function Vw(r,e,t,a,n){var i=6*t-12*e+6*r,o=9*e+3*a-3*r-9*t,s=3*e-3*r,l=0;if(ka(o)){if(Nw(i)){var u=-s/i;u>=0&&u<=1&&(n[l++]=u)}}else{var f=i*i-4*o*s;if(ka(f))n[0]=-i/(2*o);else if(f>0){var h=Ha(f),u=(-i+h)/(2*o),v=(-i-h)/(2*o);u>=0&&u<=1&&(n[l++]=u),v>=0&&v<=1&&(n[l++]=v)}}return l}function qa(r,e,t,a,n,i){var o=(e-r)*n+r,s=(t-e)*n+e,l=(a-t)*n+t,u=(s-o)*n+o,f=(l-s)*n+s,h=(f-u)*n+u;i[0]=r,i[1]=o,i[2]=u,i[3]=h,i[4]=h,i[5]=f,i[6]=l,i[7]=a}function Bw(r,e,t,a,n,i,o,s,l,u,f){var h,v=.005,c=1/0,p,d,g,y;Br[0]=l,Br[1]=u;for(var m=0;m<1;m+=.05)rr[0]=Jt(r,t,n,o,m),rr[1]=Jt(e,a,i,s,m),g=Fa(Br,rr),g<c&&(h=m,c=g);c=1/0;for(var _=0;_<32&&!(v<Ow);_++)p=h-v,d=h+v,rr[0]=Jt(r,t,n,o,p),rr[1]=Jt(e,a,i,s,p),g=Fa(rr,Br),p>=0&&g<c?(h=p,c=g):(qi[0]=Jt(r,t,n,o,d),qi[1]=Jt(e,a,i,s,d),y=Fa(qi,Br),d<=1&&y<c?(h=d,c=y):v*=.5);return f&&(f[0]=Jt(r,t,n,o,h),f[1]=Jt(e,a,i,s,h)),Ha(c)}function S2(r,e,t,a,n,i,o,s,l){for(var u=r,f=e,h=0,v=1/l,c=1;c<=l;c++){var p=c*v,d=Jt(r,t,n,o,p),g=Jt(e,a,i,s,p),y=d-u,m=g-f;h+=Math.sqrt(y*y+m*m),u=d,f=g}return h}function ne(r,e,t,a){var n=1-a;return n*(n*r+2*a*e)+a*a*t}function Cp(r,e,t,a){return 2*((1-a)*(e-r)+a*(t-e))}function x2(r,e,t,a,n){var i=r-2*e+t,o=2*(e-r),s=r-a,l=0;if(ka(i)){if(Nw(o)){var u=-s/o;u>=0&&u<=1&&(n[l++]=u)}}else{var f=o*o-4*i*s;if(ka(f)){var u=-o/(2*i);u>=0&&u<=1&&(n[l++]=u)}else if(f>0){var h=Ha(f),u=(-o+h)/(2*i),v=(-o-h)/(2*i);u>=0&&u<=1&&(n[l++]=u),v>=0&&v<=1&&(n[l++]=v)}}return l}function zw(r,e,t){var a=r+t-2*e;return a===0?.5:(r-e)/a}function zs(r,e,t,a,n){var i=(e-r)*a+r,o=(t-e)*a+e,s=(o-i)*a+i;n[0]=r,n[1]=i,n[2]=s,n[3]=s,n[4]=o,n[5]=t}function Gw(r,e,t,a,n,i,o,s,l){var u,f=.005,h=1/0;Br[0]=o,Br[1]=s;for(var v=0;v<1;v+=.05){rr[0]=ne(r,t,n,v),rr[1]=ne(e,a,i,v);var c=Fa(Br,rr);c<h&&(u=v,h=c)}h=1/0;for(var p=0;p<32&&!(f<Ow);p++){var d=u-f,g=u+f;rr[0]=ne(r,t,n,d),rr[1]=ne(e,a,i,d);var c=Fa(rr,Br);if(d>=0&&c<h)u=d,h=c;else{qi[0]=ne(r,t,n,g),qi[1]=ne(e,a,i,g);var y=Fa(qi,Br);g<=1&&y<h?(u=g,h=y):f*=.5}}return l&&(l[0]=ne(r,t,n,u),l[1]=ne(e,a,i,u)),Ha(h)}function b2(r,e,t,a,n,i,o){for(var s=r,l=e,u=0,f=1/o,h=1;h<=o;h++){var v=h*f,c=ne(r,t,n,v),p=ne(e,a,i,v),d=c-s,g=p-l;u+=Math.sqrt(d*d+g*g),s=c,l=p}return u}var w2=/cubic-bezier\(([0-9,\.e ]+)\)/;function vg(r){var e=r&&w2.exec(r);if(e){var t=e[1].split(","),a=+ir(t[0]),n=+ir(t[1]),i=+ir(t[2]),o=+ir(t[3]);if(isNaN(a+n+i+o))return;var s=[];return function(l){return l<=0?0:l>=1?1:pf(0,a,i,1,l,s)&&Jt(0,n,o,1,s[0])}}}var T2=function(){function r(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||Zt,this.ondestroy=e.ondestroy||Zt,this.onrestart=e.onrestart||Zt,e.easing&&this.setEasing(e.easing)}return r.prototype.step=function(e,t){if(this._inited||(this._startTime=e+this._delay,this._inited=!0),this._paused){this._pausedTime+=t;return}var a=this._life,n=e-this._startTime-this._pausedTime,i=n/a;i<0&&(i=0),i=Math.min(i,1);var o=this.easingFunc,s=o?o(i):i;if(this.onframe(s),i===1)if(this.loop){var l=n%a;this._startTime=e-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(e){this.easing=e,this.easingFunc=K(e)?e:kw[e]||vg(e)},r}();const C2=T2;var Fw=function(){function r(e){this.value=e}return r}(),A2=function(){function r(){this._len=0}return r.prototype.insert=function(e){var t=new Fw(e);return this.insertEntry(t),t},r.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},r.prototype.remove=function(e){var t=e.prev,a=e.next;t?t.next=a:this.head=a,a?a.prev=t:this.tail=t,e.next=e.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r}(),M2=function(){function r(e){this._list=new A2,this._maxSize=10,this._map={},this._maxSize=e}return r.prototype.put=function(e,t){var a=this._list,n=this._map,i=null;if(n[e]==null){var o=a.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var l=a.head;a.remove(l),delete n[l.key],i=l.value,this._lastRemovedEntry=l}s?s.value=t:s=new Fw(t),s.key=e,a.insertEntry(s),n[e]=s}return i},r.prototype.get=function(e){var t=this._map[e],a=this._list;if(t!=null)return t!==a.tail&&(a.remove(t),a.insertEntry(t)),t.value},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r}();const gl=M2;var km={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function xr(r){return r=Math.round(r),r<0?0:r>255?255:r}function D2(r){return r=Math.round(r),r<0?0:r>360?360:r}function Gs(r){return r<0?0:r>1?1:r}function iv(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?xr(parseFloat(e)/100*255):xr(parseInt(e,10))}function ao(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?Gs(parseFloat(e)/100):Gs(parseFloat(e))}function ov(r,e,t){return t<0?t+=1:t>1&&(t-=1),t*6<1?r+(e-r)*t*6:t*2<1?e:t*3<2?r+(e-r)*(2/3-t)*6:r}function Oa(r,e,t){return r+(e-r)*t}function je(r,e,t,a,n){return r[0]=e,r[1]=t,r[2]=a,r[3]=n,r}function Ap(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r}var Hw=new gl(20),Wl=null;function yi(r,e){Wl&&Ap(Wl,e),Wl=Hw.put(r,Wl||e.slice())}function Te(r,e){if(r){e=e||[];var t=Hw.get(r);if(t)return Ap(e,t);r=r+"";var a=r.replace(/ /g,"").toLowerCase();if(a in km)return Ap(e,km[a]),yi(r,e),e;var n=a.length;if(a.charAt(0)==="#"){if(n===4||n===5){var i=parseInt(a.slice(1,4),16);if(!(i>=0&&i<=4095)){je(e,0,0,0,1);return}return je(e,(i&3840)>>4|(i&3840)>>8,i&240|(i&240)>>4,i&15|(i&15)<<4,n===5?parseInt(a.slice(4),16)/15:1),yi(r,e),e}else if(n===7||n===9){var i=parseInt(a.slice(1,7),16);if(!(i>=0&&i<=16777215)){je(e,0,0,0,1);return}return je(e,(i&16711680)>>16,(i&65280)>>8,i&255,n===9?parseInt(a.slice(7),16)/255:1),yi(r,e),e}return}var o=a.indexOf("("),s=a.indexOf(")");if(o!==-1&&s+1===n){var l=a.substr(0,o),u=a.substr(o+1,s-(o+1)).split(","),f=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?je(e,+u[0],+u[1],+u[2],1):je(e,0,0,0,1);f=ao(u.pop());case"rgb":if(u.length!==3){je(e,0,0,0,1);return}return je(e,iv(u[0]),iv(u[1]),iv(u[2]),f),yi(r,e),e;case"hsla":if(u.length!==4){je(e,0,0,0,1);return}return u[3]=ao(u[3]),Mp(u,e),yi(r,e),e;case"hsl":if(u.length!==3){je(e,0,0,0,1);return}return Mp(u,e),yi(r,e),e;default:return}}je(e,0,0,0,1)}}function Mp(r,e){var t=(parseFloat(r[0])%360+360)%360/360,a=ao(r[1]),n=ao(r[2]),i=n<=.5?n*(a+1):n+a-n*a,o=n*2-i;return e=e||[],je(e,xr(ov(o,i,t+1/3)*255),xr(ov(o,i,t)*255),xr(ov(o,i,t-1/3)*255),1),r.length===4&&(e[3]=r[3]),e}function L2(r){if(r){var e=r[0]/255,t=r[1]/255,a=r[2]/255,n=Math.min(e,t,a),i=Math.max(e,t,a),o=i-n,s=(i+n)/2,l,u;if(o===0)l=0,u=0;else{s<.5?u=o/(i+n):u=o/(2-i-n);var f=((i-e)/6+o/2)/o,h=((i-t)/6+o/2)/o,v=((i-a)/6+o/2)/o;e===i?l=v-h:t===i?l=1/3+f-v:a===i&&(l=2/3+h-f),l<0&&(l+=1),l>1&&(l-=1)}var c=[l*360,u,s];return r[3]!=null&&c.push(r[3]),c}}function df(r,e){var t=Te(r);if(t){for(var a=0;a<3;a++)e<0?t[a]=t[a]*(1-e)|0:t[a]=(255-t[a])*e+t[a]|0,t[a]>255?t[a]=255:t[a]<0&&(t[a]=0);return br(t,t.length===4?"rgba":"rgb")}}function I2(r){var e=Te(r);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function bs(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){t=t||[];var a=r*(e.length-1),n=Math.floor(a),i=Math.ceil(a),o=e[n],s=e[i],l=a-n;return t[0]=xr(Oa(o[0],s[0],l)),t[1]=xr(Oa(o[1],s[1],l)),t[2]=xr(Oa(o[2],s[2],l)),t[3]=Gs(Oa(o[3],s[3],l)),t}}var P2=bs;function cg(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){var a=r*(e.length-1),n=Math.floor(a),i=Math.ceil(a),o=Te(e[n]),s=Te(e[i]),l=a-n,u=br([xr(Oa(o[0],s[0],l)),xr(Oa(o[1],s[1],l)),xr(Oa(o[2],s[2],l)),Gs(Oa(o[3],s[3],l))],"rgba");return t?{color:u,leftIndex:n,rightIndex:i,value:a}:u}}var R2=cg;function Ki(r,e,t,a){var n=Te(r);if(r)return n=L2(n),e!=null&&(n[0]=D2(e)),t!=null&&(n[1]=ao(t)),a!=null&&(n[2]=ao(a)),br(Mp(n),"rgba")}function Fs(r,e){var t=Te(r);if(t&&e!=null)return t[3]=Gs(e),br(t,"rgba")}function br(r,e){if(!(!r||!r.length)){var t=r[0]+","+r[1]+","+r[2];return(e==="rgba"||e==="hsva"||e==="hsla")&&(t+=","+r[3]),e+"("+t+")"}}function Hs(r,e){var t=Te(r);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}function E2(){return br([Math.round(Math.random()*255),Math.round(Math.random()*255),Math.round(Math.random()*255)],"rgb")}const k2=Object.freeze(Object.defineProperty({__proto__:null,fastLerp:bs,fastMapToColor:P2,lerp:cg,lift:df,lum:Hs,mapToColor:R2,modifyAlpha:Fs,modifyHSL:Ki,parse:Te,random:E2,stringify:br,toHex:I2},Symbol.toStringTag,{value:"Module"}));var gf=Math.round;function no(r){var e;if(!r||r==="transparent")r="none";else if(typeof r=="string"&&r.indexOf("rgba")>-1){var t=Te(r);t&&(r="rgb("+t[0]+","+t[1]+","+t[2]+")",e=t[3])}return{color:r,opacity:e??1}}var Om=1e-4;function Na(r){return r<Om&&r>-Om}function $l(r){return gf(r*1e3)/1e3}function Dp(r){return gf(r*1e4)/1e4}function O2(r){return"matrix("+$l(r[0])+","+$l(r[1])+","+$l(r[2])+","+$l(r[3])+","+Dp(r[4])+","+Dp(r[5])+")"}var N2={left:"start",right:"end",center:"middle",middle:"middle"};function V2(r,e,t){return t==="top"?r+=e/2:t==="bottom"&&(r-=e/2),r}function B2(r){return r&&(r.shadowBlur||r.shadowOffsetX||r.shadowOffsetY)}function z2(r){var e=r.style,t=r.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),t[0],t[1]].join(",")}function Ww(r){return r&&!!r.image}function G2(r){return r&&!!r.svgElement}function F2(r){return Ww(r)||G2(r)}function $w(r){return r.type==="linear"}function Uw(r){return r.type==="radial"}function H2(r){return r&&(r.type==="linear"||r.type==="radial")}function vh(r){return"url(#"+r+")"}function Yw(r){var e=r.getGlobalScale(),t=Math.max(e[0],e[1]);return Math.max(Math.ceil(Math.log(t)/Math.log(10)),1)}function Zw(r){var e=r.x||0,t=r.y||0,a=(r.rotation||0)*Ss,n=ht(r.scaleX,1),i=ht(r.scaleY,1),o=r.skewX||0,s=r.skewY||0,l=[];return(e||t)&&l.push("translate("+e+"px,"+t+"px)"),a&&l.push("rotate("+a+")"),(n!==1||i!==1)&&l.push("scale("+n+","+i+")"),(o||s)&&l.push("skew("+gf(o*Ss)+"deg, "+gf(s*Ss)+"deg)"),l.join(" ")}var W2=function(){return Ct.hasGlobalWindow&&K(window.btoa)?function(r){return window.btoa(unescape(r))}:typeof Buffer<"u"?function(r){return Buffer.from(r).toString("base64")}:function(r){return null}}(),Lp=Array.prototype.slice;function ra(r,e,t){return(e-r)*t+r}function sv(r,e,t,a){for(var n=e.length,i=0;i<n;i++)r[i]=ra(e[i],t[i],a);return r}function $2(r,e,t,a){for(var n=e.length,i=n&&e[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=ra(e[o][s],t[o][s],a)}return r}function Ul(r,e,t,a){for(var n=e.length,i=0;i<n;i++)r[i]=e[i]+t[i]*a;return r}function Nm(r,e,t,a){for(var n=e.length,i=n&&e[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=e[o][s]+t[o][s]*a}return r}function U2(r,e){for(var t=r.length,a=e.length,n=t>a?e:r,i=Math.min(t,a),o=n[i-1]||{color:[0,0,0,0],offset:0},s=i;s<Math.max(t,a);s++)n.push({offset:o.offset,color:o.color.slice()})}function Y2(r,e,t){var a=r,n=e;if(!(!a.push||!n.push)){var i=a.length,o=n.length;if(i!==o){var s=i>o;if(s)a.length=o;else for(var l=i;l<o;l++)a.push(t===1?n[l]:Lp.call(n[l]))}for(var u=a[0]&&a[0].length,l=0;l<a.length;l++)if(t===1)isNaN(a[l])&&(a[l]=n[l]);else for(var f=0;f<u;f++)isNaN(a[l][f])&&(a[l][f]=n[l][f])}}function ws(r){if(fe(r)){var e=r.length;if(fe(r[0])){for(var t=[],a=0;a<e;a++)t.push(Lp.call(r[a]));return t}return Lp.call(r)}return r}function Yu(r){return r[0]=Math.floor(r[0])||0,r[1]=Math.floor(r[1])||0,r[2]=Math.floor(r[2])||0,r[3]=r[3]==null?1:r[3],"rgba("+r.join(",")+")"}function Z2(r){return fe(r&&r[0])?2:1}var Yl=0,Zu=1,Xw=2,us=3,Ip=4,Pp=5,Vm=6;function Bm(r){return r===Ip||r===Pp}function Zl(r){return r===Zu||r===Xw}var Oo=[0,0,0,0],X2=function(){function r(e){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=e}return r.prototype.isFinished=function(){return this._finished},r.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},r.prototype.needsAnimate=function(){return this.keyframes.length>=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(e,t,a){this._needsSort=!0;var n=this.keyframes,i=n.length,o=!1,s=Vm,l=t;if(fe(t)){var u=Z2(t);s=u,(u===1&&!xt(t[0])||u===2&&!xt(t[0][0]))&&(o=!0)}else if(xt(t)&&!ro(t))s=Yl;else if($(t))if(!isNaN(+t))s=Yl;else{var f=Te(t);f&&(l=f,s=us)}else if(pl(t)){var h=B({},l);h.colorStops=G(t.colorStops,function(c){return{offset:c.offset,color:Te(c.color)}}),$w(t)?s=Ip:Uw(t)&&(s=Pp),l=h}i===0?this.valType=s:(s!==this.valType||s===Vm)&&(o=!0),this.discrete=this.discrete||o;var v={time:e,value:l,rawValue:t,percent:0};return a&&(v.easing=a,v.easingFunc=K(a)?a:kw[a]||vg(a)),n.push(v),v},r.prototype.prepare=function(e,t){var a=this.keyframes;this._needsSort&&a.sort(function(d,g){return d.time-g.time});for(var n=this.valType,i=a.length,o=a[i-1],s=this.discrete,l=Zl(n),u=Bm(n),f=0;f<i;f++){var h=a[f],v=h.value,c=o.value;h.percent=h.time/e,s||(l&&f!==i-1?Y2(v,c,n):u&&U2(v.colorStops,c.colorStops))}if(!s&&n!==Pp&&t&&this.needsAnimate()&&t.needsAnimate()&&n===t.valType&&!t._finished){this._additiveTrack=t;for(var p=a[0].value,f=0;f<i;f++)n===Yl?a[f].additiveValue=a[f].value-p:n===us?a[f].additiveValue=Ul([],a[f].value,p,-1):Zl(n)&&(a[f].additiveValue=n===Zu?Ul([],a[f].value,p,-1):Nm([],a[f].value,p,-1))}},r.prototype.step=function(e,t){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var a=this._additiveTrack!=null,n=a?"additiveValue":"value",i=this.valType,o=this.keyframes,s=o.length,l=this.propName,u=i===us,f,h=this._lastFr,v=Math.min,c,p;if(s===1)c=p