vite-bundle-explorer 0.3.4 → 1.1.0
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/README.md +77 -26
- package/bin/index.js +1 -0
- package/dist-plugin/esbuild.d.mts +10 -0
- package/dist-plugin/esbuild.mjs +109 -0
- package/dist-plugin/src-CgEHOuup.mjs +41 -0
- package/dist-plugin/{stats-plugin.d.ts → stats-plugin.d.mts} +2 -5
- package/dist-plugin/{stats-plugin.js → stats-plugin.mjs} +20 -71
- package/dist-ui/assets/index-CyISDKh8.js +20 -0
- package/dist-ui/assets/index-q6r_rC1D.css +1 -0
- package/dist-ui/index.html +2 -2
- package/package.json +40 -29
- package/dist-ui/assets/index-D-ZNVfN7.css +0 -1
- package/dist-ui/assets/index-DHfe3O-k.js +0 -63
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
var e=Object.defineProperty,t=(t,n)=>{let r={};for(var i in t)e(r,i,{get:t[i],enumerable:!0});return n||e(r,Symbol.toStringTag,{value:`Module`}),r};(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();function n(e){let t=Object.create(null);for(let n of e.split(`,`))t[n]=1;return e=>e in t}var r={},i=[],a=()=>{},o=()=>!1,s=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),c=e=>e.startsWith(`onUpdate:`),l=Object.assign,u=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},d=Object.prototype.hasOwnProperty,f=(e,t)=>d.call(e,t),p=Array.isArray,m=e=>C(e)===`[object Map]`,h=e=>C(e)===`[object Set]`,g=e=>C(e)===`[object Date]`,_=e=>typeof e==`function`,v=e=>typeof e==`string`,y=e=>typeof e==`symbol`,b=e=>typeof e==`object`&&!!e,x=e=>(b(e)||_(e))&&_(e.then)&&_(e.catch),S=Object.prototype.toString,C=e=>S.call(e),w=e=>C(e).slice(8,-1),T=e=>C(e)===`[object Object]`,E=e=>v(e)&&e!==`NaN`&&e[0]!==`-`&&``+parseInt(e,10)===e,D=n(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),O=e=>{let t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},k=/-\w/g,A=O(e=>e.replace(k,e=>e.slice(1).toUpperCase())),ee=/\B([A-Z])/g,te=O(e=>e.replace(ee,`-$1`).toLowerCase()),ne=O(e=>e.charAt(0).toUpperCase()+e.slice(1)),re=O(e=>e?`on${ne(e)}`:``),j=(e,t)=>!Object.is(e,t),ie=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},ae=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},oe=e=>{let t=parseFloat(e);return isNaN(t)?e:t},se,ce=()=>se||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function le(e){if(p(e)){let t={};for(let n=0;n<e.length;n++){let r=e[n],i=v(r)?pe(r):le(r);if(i)for(let e in i)t[e]=i[e]}return t}if(v(e)||b(e))return e}var ue=/;(?![^(]*\))/g,de=/:([^]+)/,fe=/"(?:[^"\\]|\\[^])*"|'(?:[^'\\]|\\[^])*'|\\[^]|\/\*[^]*?\*\//g;function pe(e){let t={};return e.replace(fe,e=>e.startsWith(`/*`)?``:e).split(ue).forEach(e=>{if(e){let n=e.split(de);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function M(e){let t=``;if(v(e))t=e;else if(p(e))for(let n=0;n<e.length;n++){let r=M(e[n]);r&&(t+=r+` `)}else if(b(e))for(let n in e)e[n]&&(t+=n+` `);return t.trim()}function me(e){if(!e)return null;let{class:t,style:n}=e;return t&&!v(t)&&(e.class=M(t)),n&&(e.style=le(n)),e}var he=n(`itemscope,allowfullscreen,disablepictureinpicture,disableremoteplayback,formnovalidate,ismap,nomodule,novalidate,playsinline,readonly`);function ge(e){return!!e||e===``}function _e(e,t,n){if(e.length!==t.length)return!1;let r=!0;for(let i=0;r&&i<e.length;i++)r=xe(e[i],t[i],n);return r}function ve(e,t,n){if(e.size!==t.size)return!1;let r=Array.from(t),i=new Uint8Array(r.length);for(let t of e){let e=-1;for(let a=0;a<r.length;a++)if(!i[a]&&xe(t,r[a],n)){e=a;break}if(e<0)return!1;i[e]=1}return!0}function ye(e,t,n){let r=m(e),i=m(t);if(r||i||(r=h(e),i=h(t),r||i))return r&&i?ve(e,t,n):!1;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let r in e){let i=e.hasOwnProperty(r),a=t.hasOwnProperty(r);if(i&&!a||!i&&a||!xe(e[r],t[r],n))return!1}return String(e)===String(t)}function be(e,t,n,r){n||=[new Map,new Map];let[i,a]=n;if(i.has(e)||a.has(t))return i.get(e)===t&&a.get(t)===e;i.set(e,t),a.set(t,e);let o=r(e,t,n);return i.delete(e),a.delete(t),o}function xe(e,t,n){if(e===t)return!0;let r=g(e),i=g(t);return r||i?r&&i?e.getTime()===t.getTime():!1:(r=y(e),i=y(t),r||i?e===t:(r=p(e),i=p(t),r||i?r&&i?be(e,t,n,_e):!1:(r=b(e),i=b(t),r||i?!r||!i?!1:be(e,t,n,ye):String(e)===String(t))))}function Se(e,t){return e.findIndex(e=>xe(e,t))}var Ce=e=>!!(e&&e.__v_isRef===!0),we=e=>v(e)?e:e==null?``:p(e)||b(e)&&(e.toString===S||!_(e.toString))?Ce(e)?we(e.value):JSON.stringify(e,Te,2):String(e),Te=(e,t)=>Ce(t)?Te(e,t.value):m(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Ee(t,r)+` =>`]=n,e),{})}:h(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Ee(e))}:y(t)?Ee(t):b(t)&&!p(t)&&!T(t)?String(t):t,Ee=(e,t=``)=>y(e)?`Symbol(${e.description??t})`:e,De,Oe=class{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&De&&(De.active?(this.parent=De,this.index=(De.scopes||(De.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}let n=this.effects.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}}run(e){if(this._active){let t=De;try{return De=this,e()}finally{De=t}}}on(){++this._on===1&&(this.prevScope=De,De=this)}off(){if(this._on>0&&--this._on===0){if(De===this)De=this.prevScope;else{let e=De;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,n;for(t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(this.effects.length=0,t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){let e=this.scopes.slice();for(t=0,n=e.length;t<n;t++)e[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}};function ke(e){return new Oe(e)}function Ae(){return De}function je(e,t=!1){De&&(De.active?De.cleanups.push(e):e())}var Me,Ne=new WeakSet,Pe=class{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,De&&(De.active?De.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Ne.has(this)&&(Ne.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Re(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Ze(this),Ve(this);let e=Me,t=qe;Me=this,qe=!0;try{return this.fn()}finally{He(this),Me=e,qe=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Ge(e);this.deps=this.depsTail=void 0,Ze(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Ne.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Ue(this)&&this.run()}get dirty(){return Ue(this)}},Fe=0,Ie,Le;function Re(e,t=!1){e.flags|=8,t?(e.next=Le,Le=e):(e.next=Ie,Ie=e)}function ze(){Fe++}function Be(){if(--Fe>0)return;if(Le){let e=Le;for(Le=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;for(;Ie;){let t=Ie;for(Ie=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(t){e||=t}t=n}}if(e)throw e}function Ve(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function He(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;r.version===-1?(r===n&&(n=e),Ge(r),Ke(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function Ue(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(We(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function We(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Qe)||(e.globalVersion=Qe,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Ue(e))))return;e.flags|=2;let t=e.dep,n=Me,r=qe;Me=e,qe=!0;try{Ve(e);let n=e.fn(e._value);(t.version===0||j(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(e){throw t.version++,e}finally{Me=n,qe=r,He(e),e.flags&=-3}}function Ge(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)Ge(e,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function Ke(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}var qe=!0,Je=[];function Ye(){Je.push(qe),qe=!1}function Xe(){let e=Je.pop();qe=e===void 0||e}function Ze(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=Me;Me=void 0;try{t()}finally{Me=e}}}var Qe=0,$e=class{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},et=class{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!Me||!qe||Me===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==Me)t=this.activeLink=new $e(Me,this),Me.deps?(t.prevDep=Me.depsTail,Me.depsTail.nextDep=t,Me.depsTail=t):Me.deps=Me.depsTail=t,tt(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=Me.depsTail,t.nextDep=void 0,Me.depsTail.nextDep=t,Me.depsTail=t,Me.deps===t&&(Me.deps=e)}return t}trigger(e){this.version++,Qe++,this.notify(e)}notify(e){ze();try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{Be()}}};function tt(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)tt(e)}let n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}var nt=new WeakMap,rt=Symbol(``),it=Symbol(``),at=Symbol(``);function ot(e,t,n){if(qe&&Me){let t=nt.get(e);t||nt.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new et),r.map=t,r.key=n),r.track()}}function st(e,t,n,r,i,a){let o=nt.get(e);if(!o){Qe++;return}let s=e=>{e&&e.trigger()};if(ze(),t===`clear`)o.forEach(s);else{let i=p(e),a=i&&E(n);if(i&&n===`length`){let e=Number(r);o.forEach((t,n)=>{(n===`length`||n===at||!y(n)&&n>=e)&&s(t)})}else switch((n!==void 0||o.has(void 0))&&s(o.get(n)),a&&s(o.get(at)),t){case`add`:i?a&&s(o.get(`length`)):(s(o.get(rt)),m(e)&&s(o.get(it)));break;case`delete`:i||(s(o.get(rt)),m(e)&&s(o.get(it)));break;case`set`:m(e)&&s(o.get(rt))}}Be()}function ct(e,t){let n=nt.get(e);return n&&n.get(t)}function lt(e){let t=en(e);return t===e||(ot(t,`iterate`,at),Qt(e))?t:Zt(e)?Xt(e)?t.map(e=>rn(nn(e))):t.map(rn):t.map(nn)}function ut(e){return ot(e=en(e),`iterate`,at),e}function dt(e,t){return Zt(e)?rn(Xt(e)?nn(t):t):nn(t)}var ft={__proto__:null,[Symbol.iterator](){return pt(this,Symbol.iterator,e=>dt(this,e))},concat(...e){return lt(this).concat(...e.map(e=>p(e)?lt(e):e))},entries(){return pt(this,`entries`,e=>(e[1]=dt(this,e[1]),e))},every(e,t){return gt(this,`every`,e,t,void 0,arguments)},filter(e,t){return gt(this,`filter`,e,t,e=>e.map(e=>dt(this,e)),arguments)},find(e,t){return gt(this,`find`,e,t,e=>dt(this,e),arguments)},findIndex(e,t){return gt(this,`findIndex`,e,t,void 0,arguments)},findLast(e,t){return gt(this,`findLast`,e,t,e=>dt(this,e),arguments)},findLastIndex(e,t){return gt(this,`findLastIndex`,e,t,void 0,arguments)},forEach(e,t){return gt(this,`forEach`,e,t,void 0,arguments)},includes(...e){return vt(this,`includes`,e)},indexOf(...e){return vt(this,`indexOf`,e)},join(e){return lt(this).join(e)},lastIndexOf(...e){return vt(this,`lastIndexOf`,e)},map(e,t){return gt(this,`map`,e,t,void 0,arguments)},pop(){return yt(this,`pop`)},push(...e){return yt(this,`push`,e)},reduce(e,...t){return _t(this,`reduce`,e,t)},reduceRight(e,...t){return _t(this,`reduceRight`,e,t)},shift(){return yt(this,`shift`)},some(e,t){return gt(this,`some`,e,t,void 0,arguments)},splice(...e){return yt(this,`splice`,e)},toReversed(){return lt(this).toReversed()},toSorted(e){return lt(this).toSorted(e)},toSpliced(...e){return lt(this).toSpliced(...e)},unshift(...e){return yt(this,`unshift`,e)},values(){return pt(this,`values`,e=>dt(this,e))}};function pt(e,t,n){let r=ut(e),i=r[t],a=i.call(r);if(r!==e&&!Qt(e)){if(a[Symbol.toStringTag]===`Array Iterator`){let e=Object.create(Object.getPrototypeOf(a));return e.next=()=>mt(a.next(),n),i!==ht[t]&&Object.defineProperties(e,{return:{get(){let e=a.return;return typeof e==`function`?e.bind(a):e}},throw:{get(){let e=a.throw;return typeof e==`function`?e.bind(a):e}}}),e}a._next=a.next,a.next=()=>mt(a._next(),n)}return a}function mt(e,t){return e.done||(e.value=t(e.value)),e}var ht=Array.prototype;function gt(e,t,n,r,i,a){let o=ut(e),s=o!==e&&!Qt(e),c=o[t];if(c!==ht[t]){let t=c.apply(e,a);return s?nn(t):t}let l=n;o!==e&&(s?l=function(t,r){return n.call(this,dt(e,t),r,e)}:n.length>2&&(l=function(t,r){return n.call(this,t,r,e)}));let u=c.call(o,l,r);return s&&i?i(u):u}function _t(e,t,n,r){let i=ut(e),a=i!==e&&!Qt(e),o=n,s=!1;i!==e&&(a?(s=r.length===0,o=function(t,r,i){return s&&(s=!1,t=dt(e,t)),n.call(this,t,dt(e,r),i,e)}):n.length>3&&(o=function(t,r,i){return n.call(this,t,r,i,e)}));let c=i[t](o,...r);return s?dt(e,c):c}function vt(e,t,n){let r=en(e);ot(r,`iterate`,at);let i=r[t](...n);return(i===-1||i===!1)&&$t(n[0])?(n[0]=en(n[0]),r[t](...n)):i}function yt(e,t,n=[]){Ye(),ze();let r=en(e)[t].apply(e,n);return Be(),Xe(),r}var bt=n(`__proto__,__v_isRef,__isVue`),xt=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!==`arguments`&&e!==`caller`).map(e=>Symbol[e]).filter(y));function St(e){y(e)||(e=String(e));let t=en(this);return ot(t,`has`,e),t.hasOwnProperty(e)}var Ct=class{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if(t===`__v_skip`)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if(t===`__v_isReactive`)return!r;if(t===`__v_isReadonly`)return r;if(t===`__v_isShallow`)return i;if(t===`__v_raw`)return n===(r?i?Ut:Ht:i?Vt:Bt).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=p(e);if(!r){let e;if(a&&(e=ft[t]))return e;if(t===`hasOwnProperty`)return St}let o=Reflect.get(e,t,an(e)?e:n);if((y(t)?xt.has(t):bt(t))||(r||ot(e,`get`,t),i))return o;if(an(o)){let e=a&&E(t)?o:o.value;return r&&b(e)?qt(e):e}return b(o)?r?qt(o):Gt(o):o}},wt=class extends Ct{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t],a=p(e)&&E(t);if(!this._isShallow){let e=Zt(i);if(!Qt(n)&&!Zt(n)&&(i=en(i),n=en(n)),!a&&an(i)&&!an(n))return e||(i.value=n),!0}let o=a?Number(t)<e.length:f(e,t),s=Reflect.set(e,t,n,an(e)?e:r);return e===en(r)&&s&&(o?j(n,i)&&st(e,`set`,t,n,i):st(e,`add`,t,n)),s}deleteProperty(e,t){let n=f(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&st(e,`delete`,t,void 0,r),i}has(e,t){let n=Reflect.has(e,t);return y(t)&&xt.has(t)||ot(e,`has`,t),n}ownKeys(e){return ot(e,`iterate`,p(e)?`length`:rt),Reflect.ownKeys(e)}},Tt=class extends Ct{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}},Et=new wt,Dt=new Tt,Ot=new wt(!0),kt=new Tt(!0),At=e=>e,jt=e=>Reflect.getPrototypeOf(e);function Mt(e,t,n){return function(...r){let i=this.__v_raw,a=en(i),o=m(a),s=e===`entries`||e===Symbol.iterator&&o,c=e===`keys`&&o,u=i[e](...r),d=n?At:t?rn:nn;return!t&&ot(a,`iterate`,c?it:rt),l(Object.create(u),{next(){let{value:e,done:t}=u.next();return t?{value:e,done:t}:{value:s?[d(e[0]),d(e[1])]:d(e),done:t}}})}}function Nt(e){return function(...t){return e===`delete`?!1:e===`clear`?void 0:this}}function Pt(e,t){let n={get(n){let r=this.__v_raw,i=en(r),a=en(n);e||(j(n,a)&&ot(i,`get`,n),ot(i,`get`,a));let{has:o}=jt(i),s=t?At:e?rn:nn;if(o.call(i,n))return s(r.get(n));if(o.call(i,a))return s(r.get(a));r!==i&&r.get(n)},get size(){let t=this.__v_raw;return!e&&ot(en(t),`iterate`,rt),t.size},has(t){let n=this.__v_raw,r=en(n),i=en(t);return e||(j(t,i)&&ot(r,`has`,t),ot(r,`has`,i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,o=en(a),s=t?At:e?rn:nn;return!e&&ot(o,`iterate`,rt),a.forEach((e,t)=>n.call(r,s(e),s(t),i))}};return l(n,e?{add:Nt(`add`),set:Nt(`set`),delete:Nt(`delete`),clear:Nt(`clear`)}:{add(e){let n=en(this),r=jt(n),i=en(e),a=!t&&!Qt(e)&&!Zt(e)?i:e;return r.has.call(n,a)||j(e,a)&&r.has.call(n,e)||j(i,a)&&r.has.call(n,i)||(n.add(a),st(n,`add`,a,a)),this},set(e,n){t||Qt(n)||Zt(n)||(n=en(n));let r=en(this),{has:i,get:a}=jt(r),o=i.call(r,e);o||=(e=en(e),i.call(r,e));let s=a.call(r,e);return r.set(e,n),o?j(n,s)&&st(r,`set`,e,n,s):st(r,`add`,e,n),this},delete(e){let t=en(this),{has:n,get:r}=jt(t),i=n.call(t,e);i||=(e=en(e),n.call(t,e));let a=r?r.call(t,e):void 0,o=t.delete(e);return i&&st(t,`delete`,e,void 0,a),o},clear(){let e=en(this),t=e.size!==0,n=e.clear();return t&&st(e,`clear`,void 0,void 0,void 0),n}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(r=>{n[r]=Mt(r,e,t)}),n}function Ft(e,t){let n=Pt(e,t);return(r,i,a)=>i===`__v_isReactive`?!e:i===`__v_isReadonly`?e:i===`__v_isShallow`?t:i===`__v_raw`?r:Reflect.get(f(n,i)&&i in r?n:r,i,a)}var It={get:Ft(!1,!1)},Lt={get:Ft(!1,!0)},Rt={get:Ft(!0,!1)},zt={get:Ft(!0,!0)},Bt=new WeakMap,Vt=new WeakMap,Ht=new WeakMap,Ut=new WeakMap;function Wt(e){switch(e){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function Gt(e){return Zt(e)?e:Yt(e,!1,Et,It,Bt)}function Kt(e){return Yt(e,!1,Ot,Lt,Vt)}function qt(e){return Yt(e,!0,Dt,Rt,Ht)}function Jt(e){return Yt(e,!0,kt,zt,Ut)}function Yt(e,t,n,r,i){if(!b(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let a=i.get(e);if(a)return a;let o=Wt(w(e));if(o===0)return e;let s=new Proxy(e,o===2?r:n);return i.set(e,s),s}function Xt(e){return Zt(e)?Xt(e.__v_raw):!!(e&&e.__v_isReactive)}function Zt(e){return!!(e&&e.__v_isReadonly)}function Qt(e){return!!(e&&e.__v_isShallow)}function $t(e){return e?!!e.__v_raw:!1}function en(e){let t=e&&e.__v_raw;return t?en(t):e}function tn(e){return!f(e,`__v_skip`)&&Object.isExtensible(e)&&ae(e,`__v_skip`,!0),e}var nn=e=>b(e)?Gt(e):e,rn=e=>b(e)?qt(e):e;function an(e){return e?e.__v_isRef===!0:!1}function N(e){return sn(e,!1)}function on(e){return sn(e,!0)}function sn(e,t){return an(e)?e:new cn(e,t)}var cn=class{constructor(e,t){this.dep=new et,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:en(e),this._value=t?e:nn(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||Qt(e)||Zt(e);e=n?e:en(e),j(e,t)&&(this._rawValue=e,this._value=n?e:nn(e),this.dep.trigger())}};function ln(e){e.dep&&e.dep.trigger()}function P(e){return an(e)?e.value:e}function un(e){return _(e)?e():P(e)}var dn={get:(e,t,n)=>t===`__v_raw`?e:P(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return an(i)&&!an(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function fn(e){return Xt(e)?e:new Proxy(e,dn)}var pn=class{constructor(e){this.__v_isRef=!0,this._value=void 0;let t=this.dep=new et,{get:n,set:r}=e(t.track.bind(t),t.trigger.bind(t));this._get=n,this._set=r}get value(){return this._value=this._get()}set value(e){this._set(e)}};function mn(e){return new pn(e)}function hn(e){let t=p(e)?Array(e.length):{};for(let n in e)t[n]=yn(e,n);return t}var gn=class{constructor(e,t,n){this._object=e,this._defaultValue=n,this.__v_isRef=!0,this._value=void 0,this._key=y(t)?t:String(t),this._raw=en(e);let r=!0,i=e;if(!p(e)||y(this._key)||!E(this._key))do r=!$t(i)||Qt(i);while(r&&(i=i.__v_raw));this._shallow=r}get value(){let e=this._object[this._key];return this._shallow&&(e=P(e)),this._value=e===void 0?this._defaultValue:e}set value(e){if(this._shallow&&an(this._raw[this._key])){let t=this._object[this._key];if(an(t)){t.value=e;return}}this._object[this._key]=e}get dep(){return ct(this._raw,this._key)}},_n=class{constructor(e){this._getter=e,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}};function vn(e,t,n){return an(e)?e:_(e)?new _n(e):b(e)&&arguments.length>1?yn(e,t,n):N(e)}function yn(e,t,n){return new gn(e,t,n)}var bn=class{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new et(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Qe-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&Me!==this)return Re(this,!0),!0}get value(){let e=this.dep.track();return We(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}};function xn(e,t,n=!1){let r,i;return _(e)?r=e:(r=e.get,i=e.set),new bn(r,i,n)}var Sn={},Cn=new WeakMap,wn=void 0;function Tn(e,t=!1,n=wn){if(n){let t=Cn.get(n);t||Cn.set(n,t=[]),t.push(e)}}function En(e,t,n=r){let{immediate:i,deep:o,once:s,scheduler:c,augmentJob:l,call:d}=n,f=e=>o?e:Qt(e)||o===!1||o===0?Dn(e,1):Dn(e),m,h,g,v,y=!1,b=!1;if(an(e)?(h=()=>e.value,y=Qt(e)):Xt(e)?(h=()=>f(e),y=!0):p(e)?(b=!0,y=e.some(e=>Xt(e)||Qt(e)),h=()=>e.map(e=>{if(an(e))return e.value;if(Xt(e))return f(e);if(_(e))return d?d(e,2):e()})):h=_(e)?t?d?()=>d(e,2):e:()=>{if(g){Ye();try{g()}finally{Xe()}}let t=wn;wn=m;try{return d?d(e,3,[v]):e(v)}finally{wn=t}}:a,t&&o){let e=h,t=o===!0?1/0:o;h=()=>Dn(e(),t)}let x=Ae(),S=()=>{m.stop(),x&&x.active&&u(x.effects,m)};if(s&&t){let e=t;t=(...t)=>{try{return e(...t)}finally{S()}}}let C=b?Array(e.length).fill(Sn):Sn,w=e=>{if(m.flags&1&&(m.dirty||e)){if(t){let n=m.run();if(e||o||y||(b?n.some((e,t)=>j(e,C[t])):j(n,C))){let e=wn;Ye();try{g&&g(),wn=m;let e=[n,C===Sn?void 0:b&&C[0]===Sn?[]:C,v];C=n,d?d(t,3,e):t(...e)}finally{wn=e,Xe()}}}else m.run()}};return l&&l(w),m=new Pe(h),m.scheduler=c?()=>c(w,!1):w,v=e=>Tn(e,!1,m),g=m.onStop=()=>{let e=Cn.get(m);if(e){if(d)d(e,4);else for(let t of e)t();Cn.delete(m)}},t?i?w(!0):C=m.run():c?c(w.bind(null,!0),!0):m.run(),S.pause=m.pause.bind(m),S.resume=m.resume.bind(m),S.stop=S,S}function Dn(e,t=1/0,n){if(t<=0||!b(e)||e.__v_skip||(n||=new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,an(e))Dn(e.value,t,n);else if(p(e))for(let r=0;r<e.length;r++)Dn(e[r],t,n);else if(h(e)||m(e))e.forEach(e=>{Dn(e,t,n)});else if(T(e)){for(let r in e)Dn(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Dn(e[r],t,n)}return e}function On(e,t,n,r){try{return r?e(...r):e()}catch(e){An(e,t,n)}}function kn(e,t,n,r){if(_(e)){let i=On(e,t,n,r);return i&&x(i)&&i.catch(e=>{An(e,t,n,void 0,!0)}),i}if(p(e)){let i=[];for(let a=0;a<e.length;a++)i.push(kn(e[a],t,n,r));return i}}function An(e,t,n,i=!0,a=!1){let o=t?t.vnode:null,{errorHandler:s,throwUnhandledErrorInProduction:c}=t&&t.appContext.config||r;if(t){let r=t.parent,i=t.proxy,o=`https://vuejs.org/error-reference/#runtime-${n}`;for(;r;){let t=r.ec;if(t&&!r.isUnmounted&&(!a||r.scope.active)){for(let n=0;n<t.length;n++)if(t[n](e,i,o)===!1)return}r=r.parent}if(s){Ye(),On(s,null,10,[e,i,o]),Xe();return}}jn(e,n,o,i,c)}function jn(e,t,n,r=!0,i=!1){if(i)throw e;console.error(e)}var Mn=[],Nn=-1,Pn=[],Fn=null,In=0,Ln=Promise.resolve(),Rn=null;function zn(e){let t=Rn||Ln;return e?t.then(this?e.bind(this):e):t}function Bn(e){let t=Nn+1,n=Mn.length;for(;t<n;){let r=t+n>>>1,i=Mn[r],a=Jn(i);a<e||a===e&&i.flags&2?t=r+1:n=r}return t}function Vn(e){if(!(e.flags&1)){let t=Jn(e),n=Mn[Mn.length-1];!n||!(e.flags&2)&&t>=Jn(n)?Mn.push(e):Mn.splice(Bn(t),0,e),e.flags|=1,Hn()}}function Hn(){Rn||=Ln.then(Yn)}function Un(e){if(!p(e))Fn&&e.id===-1?Fn.splice(In+1,0,e):e.flags&1||(Pn.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)Pn.push(e[t]);Hn()}function Wn(e,t,n,r=Nn+1){for(;r<Mn.length;r++){let n=Mn[r];if(n&&n.flags&2){if(e&&n.id!==e.uid||t!==void 0&&!(n.id>=t))continue;Mn.splice(r,1),r=e?r-1:Nn,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function Gn(e,t,n=0){if(Pn.length){let e=Pn,r=0;if(t){e=[];for(let i=0;i<Pn.length;i++){let a=Pn[i];(a.i===void 0?t.has(a):!a.i||a.i.uid<n)?Pn[r++]=a:e.push(a)}}let i=[...new Set(e)].sort((e,t)=>Jn(e)-Jn(t));if(Pn.length=r,Fn){for(let e=0;e<i.length;e++)Fn.push(i[e]);return}for(Fn=i,In=0;In<Fn.length;In++){let e=Fn[In];e.flags&4&&(e.flags&=-2),e.flags&8||e(),e.flags&=-2}Fn=null,In=0}}var Kn=!1;function qn(e,t){if(Kn){e();return}let n=t===void 0?void 0:new Set(Pn);e(),Kn=!0;try{Wn(void 0,t),Gn(void 0,n,t)}finally{Kn=!1}}var Jn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function Yn(e){try{for(Nn=0;Nn<Mn.length;Nn++){let e=Mn[Nn];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),On(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;Nn<Mn.length;Nn++){let e=Mn[Nn];e&&(e.flags&=-2)}Nn=-1,Mn.length=0,Gn(e),Rn=null,(Mn.length||Pn.length)&&Yn(e)}}var Xn=null,Zn=null;function Qn(e){let t=Xn;return Xn=e,Zn=e&&e.type.__scopeId||null,t}function F(e,t=Xn,n){if(!t||e._n)return e;let r=(...n)=>{r._d&&Ma(-1);let i=Qn(t),a=Oa.length,o;try{o=e(...n)}finally{for(let e=Oa.length;e>a;e--)Aa();Qn(i),r._d&&Ma(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function $n(e,t){if(Xn===null)return e;let n=go(Xn),i=e.dirs||=[];for(let e=0;e<t.length;e++){let[a,o,s,c=r]=t[e];a&&(_(a)&&(a={mounted:a,updated:a}),a.deep&&Dn(o),i.push({dir:a,instance:n,value:o,oldValue:void 0,arg:s,modifiers:c}))}return e}function er(e,t,n,r){let i=e;if(r===`beforeMount`)e._mount=e;else if(r===`beforeUpdate`){let n=t&&t._mount;n&&(n._latest=e,e._mount=n)}else if(r===`mounted`){let t=e._latest;e._mount=e._latest=void 0,t&&(i=t,t._mount=void 0)}let a=i.dirs,o=t&&t.dirs;for(let s=0;s<a.length;s++){let c=a[s];o?c.oldValue=o[s].value:r===`mounted`&&c.oldValue!==void 0&&(c=l({},c,{oldValue:void 0}));let u=c.dir[r];u&&(Ye(),kn(u,n,8,[e.el,c,i,t]),Xe())}}function tr(e,t){if(eo){let n=eo.provides,r=eo.parent&&eo.parent.provides;r===n&&(n=eo.provides=Object.create(r)),n[e]=t}}function nr(e,t,n=!1){let r=to();if(r||ji){let i=ji?ji._context.provides:r?r.parent==null||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&_(t)?t.call(r&&r.proxy):t}}function rr(){return!!(to()||ji)}var ir=Symbol.for(`v-scx`),ar=()=>nr(ir);function or(e,t){return lr(e,null,t)}function sr(e,t){return lr(e,null,{flush:`sync`})}function cr(e,t,n){return lr(e,t,n)}function lr(e,t,n=r){let{immediate:i,deep:o,flush:s,once:c}=n,u=l({},n),d=t&&i||!t&&s!==`post`,f;if(so){if(s===`sync`){let e=ar();f=e.__watcherHandles||=[]}else if(!d){let e=()=>{};return e.stop=a,e.resume=a,e.pause=a,e}}let p=eo;u.call=(e,t,n)=>kn(e,p,t,n);let m=!1;s===`post`?u.scheduler=e=>{e.i=p,ua(e,p&&p.suspense)}:s!==`sync`&&(m=!0,u.scheduler=(e,t)=>{t?e():Vn(e)}),u.augmentJob=e=>{t&&(e.flags|=4),m&&(e.flags|=2,p&&(e.id=p.uid,e.i=p))};let h=En(e,t,u);return so&&(f?f.push(h):d&&h()),h}function ur(e,t,n){let r=this.proxy,i=v(e)?e.includes(`.`)?dr(r,e):()=>r[e]:e.bind(r,r),a;_(t)?a=t:(a=t.handler,n=t);let o=io(this),s=lr(i,a.bind(r),n);return o(),s}function dr(e,t){let n=t.split(`.`);return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}var fr=new WeakMap,pr=Symbol(`_vte`),mr=e=>e.__isTeleport,hr=e=>e&&(e.disabled||e.disabled===``),gr=e=>e&&(e.defer||e.defer===``),_r=e=>typeof SVGElement<`u`&&e instanceof SVGElement,vr=e=>typeof MathMLElement==`function`&&e instanceof MathMLElement,yr=(e,t)=>{let n=e&&e.to;return v(n)?t?t(n):null:n},br={name:`Teleport`,__isTeleport:!0,process(e,t,n,r,i,a,o,s,c,l){let{mc:u,pc:d,pbc:f,o:{insert:p,querySelector:m,createText:h,createComment:g,parentNode:_}}=l,v=hr(t.props),{dynamicChildren:y}=t,b=(e,t,n)=>{e.shapeFlag&16&&u(e.children,t,n,i,a,o,s,c)},x=(e=t)=>{let n=hr(e.props),r=e.target=yr(e.props,m),a=Tr(r,e,h,p);r&&(o!==`svg`&&_r(r)?o=`svg`:o!==`mathml`&&vr(r)&&(o=`mathml`),i&&i.isCE&&(i.ce._teleportTargets||(i.ce._teleportTargets=new Set)).add(r),n||(b(e,r,a),wr(e,!1)))},S=e=>{let t=()=>{if(fr.get(e)===t){if(fr.delete(e),hr(e.props)){let t=_(e.el)||n;b(e,t,e.anchor),wr(e,!0)}x(e)}};fr.set(e,t),ua(t,a)};if(e==null){let e=t.el=h(``),i=t.anchor=h(``);if(p(e,n,r),p(i,n,r),gr(t.props)||a&&a.pendingBranch){S(t);return}v&&(b(t,n,i),wr(t,!0)),x()}else{t.el=e.el;let r=t.anchor=e.anchor,u=fr.get(e);if(u){u.flags|=8,fr.delete(e),S(t);return}t.targetStart=e.targetStart;let p=t.target=e.target,h=t.targetAnchor=e.targetAnchor,g=hr(e.props),_=g?n:p,b=g?r:h;if(o===`svg`||_r(p)?o=`svg`:(o===`mathml`||vr(p))&&(o=`mathml`),y?(f(e.dynamicChildren,y,_,i,a,o,s),ga(e,t,!0)):c||d(e,t,_,b,i,a,o,s,!1),v)g?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):xr(t,n,r,l,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){let e=yr(t.props,m);e&&(t.target=e,xr(t,e,null,l,0))}else g&&xr(t,p,h,l,1);wr(t,v)}},remove(e,t,n,{um:r,o:{remove:i}},a){let{shapeFlag:o,children:s,anchor:c,targetStart:l,targetAnchor:u,target:d,props:f}=e,p=hr(f),m=a||!p,h=fr.get(e);if(h&&(h.flags|=8,fr.delete(e)),d&&(i(l),i(u)),a&&i(c),!h&&(p||d)&&o&16)for(let e=0;e<s.length;e++){let i=s[e];r(i,t,n,m,!!i.dynamicChildren)}},move:xr,hydrate:Sr};function xr(e,t,n,{o:{insert:r},m:i},a=2){a===0&&(e.targetStart&&r(e.targetStart,t,n),r(e.targetAnchor,t,n),n=e.targetAnchor);let{el:o,anchor:s,shapeFlag:c,children:l,props:u}=e,d=a===2;if(d&&r(o,t,n),!fr.has(e)&&(!d||hr(u))&&c&16)for(let e=0;e<l.length;e++)i(l[e],t,n,2);d&&r(s,t,n)}function Sr(e,t,n,r,i,a,{o:{nextSibling:o,parentNode:s,querySelector:c,insert:l,createText:u}},d){function f(e,n){let r=n;for(;r;){if(r&&r.nodeType===8){if(r.data===`teleport start anchor`)t.targetStart=r;else if(r.data===`teleport anchor`){t.targetAnchor=r,e._lpa=t.targetAnchor&&o(t.targetAnchor);break}}r=o(r)}}function p(e,t){t.anchor=d(o(e),t,s(e),n,r,i,a)}let m=t.target=yr(t.props,c),h=hr(t.props);if(m){let c=m._lpa||m.firstChild;t.shapeFlag&16&&(h?(p(e,t),f(m,c),t.targetAnchor||Tr(m,t,u,l,s(e)===m?e:null)):(t.anchor=o(e),f(m,c),t.targetAnchor||Tr(m,t,u,l),d(c&&o(c),t,m,n,r,i,a))),wr(t,h)}else h&&t.shapeFlag&16&&(p(e,t),t.targetStart=e,t.targetAnchor=o(e));return t.anchor&&o(t.anchor)}var Cr=br;function wr(e,t){let n=e.ctx;if(n&&n.ut){let r,i;for(t?(r=e.el,i=e.anchor):(r=e.targetStart,i=e.targetAnchor);r&&r!==i;)r.nodeType===1&&r.setAttribute(`data-v-owner`,n.uid),r=r.nextSibling;n.ut()}}function Tr(e,t,n,r,i=null){let a=t.targetStart=n(``),o=t.targetAnchor=n(``);return a[pr]=o,e&&(r(a,e,i),r(o,e,i)),o}var Er=Symbol(`_leaveCb`);function Dr(e){let t=e[0];if(e.length>1){for(let n of e)if(n.type!==Ea){t=n;break}}return t}function Or(e){if(!zr(e))return mr(e.type)&&e.children?Dr(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&_(n.default))return n.default()}}function kr(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let n=e.component.subTree;kr(mr(n.type)&&Or(n)||n,t)}else if(e.shapeFlag&128){let n=e.suspense;if(n){let e=n.isHydrating?n.pendingBranch:n.activeBranch;e&&kr(e,t.clone(e))}else e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)}else if(e.transition=t,e.type===wa&&p(e.children)){let n=zi(e.children,!1);n&&kr(n,t)}}function Ar(e){if(e.component)return Ar(e.component.subTree);if(e.type===wa){let t=p(e.children)&&zi(e.children,!1);return t?Ar(t):void 0}if(e.type!==Ea)return e}function I(e,t){return _(e)?l({name:e.name},t,{setup:e}):e}function jr(){let e=to();return e?(e.appContext.config.idPrefix||`v`)+`-`+e.ids[0]+e.ids[1]++:``}function Mr(e){e.ids=[e.ids[0]+e.ids[2]+++`-`,0,0]}function Nr(e){let t=to(),n=on(null);if(t){let i=t.refs===r?t.refs={}:t.refs;Object.defineProperty(i,e,{enumerable:!0,get:()=>n.value,set:e=>n.value=e})}return n}function Pr(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}var Fr=new WeakMap;function Ir(e,t,n,i,a=!1){if(p(e)){e.forEach((e,r)=>Ir(e,t&&(p(t)?t[r]:t),n,i,a));return}if(Rr(i)&&!a){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&Ir(e,t,n,i.component.subTree);return}let s=i.shapeFlag&4?go(i.component):i.el,c=a?null:s,{i:l,r:d}=e,m=t&&t.r,h=l.refs===r?l.refs={}:l.refs,g=l.setupState,y=en(g),b=g===r?o:e=>!Pr(h,e)&&f(y,e),x=(e,t)=>!(t&&Pr(h,t));if(m!=null&&m!==d){if(Lr(t),v(m))h[m]=null,b(m)&&(g[m]=null);else if(an(m)){let e=t;x(m,e.k)&&(m.value=null),e.k&&(h[e.k]=null)}}if(_(d))On(d,l,12,[c,h]);else{let t=v(d),r=an(d);if(t||r){let i=()=>{if(e.f){let n=t?b(d)?g[d]:h[d]:x(d)||!e.k?d.value:h[e.k];if(a)p(n)&&u(n,s);else if(p(n))n.includes(s)||n.push(s);else if(t)h[d]=[s],b(d)&&(g[d]=h[d]);else{let t=[s];x(d,e.k)&&(d.value=t),e.k&&(h[e.k]=t)}}else t?(h[d]=c,b(d)&&(g[d]=c)):r&&(x(d,e.k)&&(d.value=c),e.k&&(h[e.k]=c))};if(c){let t=()=>{i(),Fr.delete(e)};t.id=-1,Fr.set(e,t),ua(t,n)}else Lr(e),i()}}}function Lr(e){let t=Fr.get(e);t&&(t.flags|=8,Fr.delete(e))}ce().requestIdleCallback,ce().cancelIdleCallback;var Rr=e=>!!e.type.__asyncLoader,zr=e=>e.type.__isKeepAlive;function Br(e,t){Hr(e,`a`,t)}function Vr(e,t){Hr(e,`da`,t)}function Hr(e,t,n=eo){let r=e.__wdc||=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()};if(Wr(t,r,n),n){let e=n.parent;for(;e&&e.parent;)zr(e.parent.vnode)&&Ur(r,t,n,e),e=e.parent}}function Ur(e,t,n,r){let i=Wr(t,e,r,!0),a=Wr(`um`,()=>u(r[t],i),n);a.flags=16}function Wr(e,t,n=eo,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||=(...r)=>{Ye();let i=io(n),a=kn(t,n,e,r);return i(),Xe(),a};return r?i.unshift(a):i.push(a),a}}var Gr=e=>(t,n=eo)=>{so&&e!==`sp`||Wr(e,(...e)=>t(...e),n)},Kr=Gr(`bm`),qr=Gr(`m`),Jr=Gr(`bu`),Yr=Gr(`u`),Xr=Gr(`bum`),Zr=Gr(`um`),Qr=Gr(`sp`),$r=Gr(`rtg`),ei=Gr(`rtc`);function ti(e,t=eo){Wr(`ec`,e,t)}var ni=Symbol.for(`v-ndc`);function ri(e,t,n,r){let i,a=n&&n[r],o=p(e);if(o||v(e)){let n=o&&Xt(e),r=!1,s=!1;n&&(r=!Qt(e),s=Zt(e),e=ut(e)),i=Array(e.length);for(let n=0,o=e.length;n<o;n++)i[n]=t(r?s?rn(nn(e[n])):nn(e[n]):e[n],n,void 0,a&&a[n])}else if(typeof e==`number`){if(!Number.isInteger(e)||e<0)i=[];else{i=Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,a&&a[n])}}else if(b(e)){if(e[Symbol.iterator])i=Array.from(e,(e,n)=>t(e,n,void 0,a&&a[n]));else{let n=Object.keys(e);i=Array(n.length);for(let r=0,o=n.length;r<o;r++){let o=n[r];i[r]=t(e[o],o,r,a&&a[r])}}}else i=[];return n&&(n[r]=i),i}function ii(e,t){for(let n=0;n<t.length;n++){let r=t[n];if(p(r))for(let t=0;t<r.length;t++)e[r[t].name]=r[t].fn;else r&&(e[r.name]=r.key?(...e)=>{let t=r.fn(...e);return t&&(t.key=r.key),t}:r.fn)}return e}function ai(e,t,n,r,i,a){if(n??={},Xn.ce||Xn.parent&&Rr(Xn.parent)&&Xn.parent.ce){let e=a!=null&&n.key==null?l({},n,{key:a}):n,i=Object.keys(e).length>0;return t!=="default"&&(e.name=t),L(),R(wa,null,[B(`slot`,e,r&&r())],i?-2:64)}let o=e[t];o&&o._c&&(o._d=!1);let s=Oa.length;L();let c;try{let i=o&&oi(o(n)),s=n.key||a||i&&i.key;c=R(wa,{key:(s&&!y(s)?s:`_${t}`)+(!i&&r?`_fb`:``)},i||(r?r():[]),i&&e._===1?64:-2)}catch(e){for(let e=Oa.length;e>s;e--)Aa();throw e}finally{o&&o._c&&(o._d=!0)}return!i&&c.scopeId&&(c.slotScopeIds=[c.scopeId+`-s`]),c}function oi(e){return e.some(e=>!Fa(e)||!(e.type===Ea||e.type===wa&&!oi(e.children)))?e:null}var si=e=>e?oo(e)?go(e):si(e.parent):null,ci=l(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>si(e.parent),$root:e=>si(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>vi(e),$forceUpdate:e=>e.f||=()=>{Vn(e.update)},$nextTick:e=>e.n||=zn.bind(e.proxy),$watch:e=>ur.bind(e)}),li=(e,t)=>e!==r&&!e.__isScriptSetup&&f(e,t),ui={get({_:e},t){if(t===`__v_skip`)return!0;let{ctx:n,setupState:i,data:a,props:o,accessCache:s,type:c,appContext:l}=e;if(t[0]!==`$`){let e=s[t];if(e!==void 0)switch(e){case 1:return i[t];case 2:return a[t];case 4:return n[t];case 3:return o[t]}else if(li(i,t))return s[t]=1,i[t];else if(a!==r&&f(a,t))return s[t]=2,a[t];else if(f(o,t))return s[t]=3,o[t];else if(n!==r&&f(n,t))return s[t]=4,n[t];else pi&&(s[t]=0)}let u=ci[t],d,p;if(u)return t===`$attrs`&&ot(e.attrs,`get`,``),u(e);if((d=c.__cssModules)&&(d=d[t]))return d;if(n!==r&&f(n,t))return s[t]=4,n[t];if(p=l.config.globalProperties,f(p,t))return p[t]},set({_:e},t,n){let{data:i,setupState:a,ctx:o}=e;return li(a,t)?(a[t]=n,!0):i!==r&&f(i,t)?(i[t]=n,!0):f(e.props,t)||t[0]===`$`&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:i,appContext:a,props:o,type:s}},c){let l;return!!(n[c]||e!==r&&c[0]!==`$`&&f(e,c)||li(t,c)||f(o,c)||f(i,c)||f(ci,c)||f(a.config.globalProperties,c)||(l=s.__cssModules)&&l[c])},defineProperty(e,t,n){return n.get==null?f(n,`value`)&&this.set(e,t,n.value,null):e._.accessCache[t]=0,Reflect.defineProperty(e,t,n)}};function di(e){return p(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}function fi(e,t){return!e||!t?e||t:p(e)&&p(t)?e.concat(t):l({},di(e),di(t))}var pi=!0;function mi(e){let t=vi(e),n=e.proxy,r=e.ctx;pi=!1,t.beforeCreate&&gi(t.beforeCreate,e,`bc`);let{data:i,computed:o,methods:s,watch:c,provide:l,inject:u,created:d,beforeMount:f,mounted:m,beforeUpdate:h,updated:g,activated:v,deactivated:y,beforeDestroy:x,beforeUnmount:S,destroyed:C,unmounted:w,render:T,renderTracked:E,renderTriggered:D,errorCaptured:O,serverPrefetch:k,expose:A,inheritAttrs:ee,components:te,directives:ne,filters:re}=t;if(u&&hi(u,r,null),s)for(let e in s){let t=s[e];_(t)&&(r[e]=t.bind(n))}if(i){let t=i.call(n,n);b(t)&&(e.data=Gt(t))}if(pi=!0,o)for(let e in o){let t=o[e],i=V({get:_(t)?t.bind(n,n):_(t.get)?t.get.bind(n,n):a,set:!_(t)&&_(t.set)?t.set.bind(n):a});Object.defineProperty(r,e,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e})}if(c)for(let e in c)_i(c[e],r,n,e);if(l){let e=_(l)?l.call(n):l;Reflect.ownKeys(e).forEach(t=>{tr(t,e[t])})}d&&gi(d,e,`c`);function j(e,t){p(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(j(Kr,f),j(qr,m),j(Jr,h),j(Yr,g),j(Br,v),j(Vr,y),j(ti,O),j(ei,E),j($r,D),j(Xr,S),j(Zr,w),j(Qr,k),p(A)){if(A.length){let t=e.exposed||={};A.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||={}}T&&e.render===a&&(e.render=T),ee!=null&&(e.inheritAttrs=ee),te&&(e.components=te),ne&&(e.directives=ne),k&&Mr(e)}function hi(e,t,n=a){p(e)&&(e=Ci(e));for(let n in e){let r=e[n],i;i=b(r)?`default`in r?nr(r.from||n,r.default,!0):nr(r.from||n):nr(r),an(i)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[n]=i}}function gi(e,t,n){kn(p(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function _i(e,t,n,r){let i=r.includes(`.`)?dr(n,r):()=>n[r];if(v(e)){let n=t[e];_(n)&&cr(i,n)}else if(_(e))cr(i,e.bind(n));else if(b(e)){if(p(e))e.forEach(e=>_i(e,t,n,r));else{let r=_(e.handler)?e.handler.bind(n):t[e.handler];_(r)&&cr(i,r,e)}}}function vi(e){let t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:a,config:{optionMergeStrategies:o}}=e.appContext,s=a.get(t),c;return s?c=s:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(e=>yi(c,e,o,!0)),yi(c,t,o)),b(t)&&a.set(t,c),c}function yi(e,t,n,r=!1){let{mixins:i,extends:a}=t;a&&yi(e,a,n,!0),i&&i.forEach(t=>yi(e,t,n,!0));for(let i in t)if(!(r&&i===`expose`)){let r=bi[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}var bi={data:xi,props:Ei,emits:Ei,methods:Ti,computed:Ti,beforeCreate:wi,created:wi,beforeMount:wi,mounted:wi,beforeUpdate:wi,updated:wi,beforeDestroy:wi,beforeUnmount:wi,destroyed:wi,unmounted:wi,activated:wi,deactivated:wi,errorCaptured:wi,serverPrefetch:wi,components:Ti,directives:Ti,watch:Di,provide:xi,inject:Si};function xi(e,t){return t?e?function(){return l(_(e)?e.call(this,this):e,_(t)?t.call(this,this):t)}:t:e}function Si(e,t){return Ti(Ci(e),Ci(t))}function Ci(e){if(p(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function wi(e,t){return e?[...new Set([].concat(e,t))]:t}function Ti(e,t){return e?l(Object.create(null),e,t):t}function Ei(e,t){return e?p(e)&&p(t)?[...new Set([...e,...t])]:l(Object.create(null),di(e),di(t??{})):t}function Di(e,t){if(!e)return t;if(!t)return e;let n=l(Object.create(null),e);for(let r in t)n[r]=wi(e[r],t[r]);return n}function Oi(){return{app:null,config:{isNativeTag:o,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}var ki=0;function Ai(e,t){return function(n,r=null){_(n)||(n=l({},n)),r!=null&&!b(r)&&(r=null);let i=Oi(),a=new WeakSet,o=[],s=!1,c=i.app={_uid:ki++,_component:n,_props:r,_container:null,_context:i,_instance:null,version:yo,get config(){return i.config},set config(e){},use(e,...t){return a.has(e)||(e&&_(e.install)?(a.add(e),e.install(c,...t)):_(e)&&(a.add(e),e(c,...t))),c},mixin(e){return i.mixins.includes(e)||i.mixins.push(e),c},component(e,t){return t?(i.components[e]=t,c):i.components[e]},directive(e,t){return t?(i.directives[e]=t,c):i.directives[e]},mount(a,o,l){if(!s){let u=c._ceVNode||B(n,r);return u.appContext=i,l===!0?l=`svg`:l===!1&&(l=void 0),o&&t?t(u,a):e(u,a,l),s=!0,c._container=a,a.__vue_app__=c,go(u.component)}},onUnmount(e){o.push(e)},unmount(){s&&(kn(o,c._instance,16),e(null,c._container),delete c._container.__vue_app__)},provide(e,t){return i.provides[e]=t,c},runWithContext(e){let t=ji;ji=c;try{return e()}finally{ji=t}}};return c}}var ji=null;function Mi(e,t,n=r){let i=to(),a=A(t),o=te(t),s=Ni(e,a),c=mn((s,c)=>{let l,u=r,d;return sr(()=>{let t=e[a];j(l,t)&&(l=t,c())}),{get(){return s(),n.get?n.get(l):l},set(e){let s=n.set?n.set(e):e;if(!j(s,l)&&!(u!==r&&j(e,u)))return;let f=i.vnode.props,p=!!(f&&(t in f||a in f||o in f)&&(`onUpdate:${t}`in f||`onUpdate:${a}`in f||`onUpdate:${o}`in f));p||(l=e,c()),i.emit(`update:${t}`,s),j(e,u)&&(j(e,s)&&!j(s,d)||p&&u!==r&&!j(s,l))&&c(),u=e,d=s}}});return c[Symbol.iterator]=()=>{let e=0;return{next(){return e<2?{value:e++?s||r:c,done:!1}:{done:!0}}}},c}var Ni=(e,t)=>t===`modelValue`||t===`model-value`?e.modelModifiers:e[`${t}Modifiers`]||e[`${A(t)}Modifiers`]||e[`${te(t)}Modifiers`];function Pi(e,t,...n){if(e.isUnmounted)return;let i=e.vnode.props||r,a=n,o=t.startsWith(`update:`),s=o&&Ni(i,t.slice(7));s&&(s.trim&&(a=n.map(e=>v(e)?e.trim():e)),s.number&&(a=a.map(oe)));let c,l=i[c=re(t)]||i[c=re(A(t))];!l&&o&&(l=i[c=re(te(t))]),l&&kn(l,e,6,a);let u=i[c+`Once`];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[c])return;e.emitted[c]=!0,kn(u,e,6,a)}}var Fi=new WeakMap;function Ii(e,t,n=!1){let r=n?Fi:t.emitsCache,i=r.get(e);if(i!==void 0)return i;let a=e.emits,o={},s=!1;if(!_(e)){let r=e=>{let n=Ii(e,t,!0);n&&(s=!0,l(o,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return!a&&!s?(b(e)&&r.set(e,null),null):(p(a)?a.forEach(e=>o[e]=null):l(o,a),b(e)&&r.set(e,o),o)}function Li(e,t){return!e||!s(t)?!1:(t=t.slice(2),t=t===`Once`?t:t.replace(/Once$/,``),f(e,t[0].toLowerCase()+t.slice(1))||f(e,te(t))||f(e,t))}function Ri(e){let{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[a],slots:o,attrs:s,emit:l,render:u,renderCache:d,props:f,data:p,setupState:m,ctx:h,inheritAttrs:g}=e,_=Qn(e),v,y;try{if(n.shapeFlag&4){let e=i||r,t=e;v=Ga(u.call(t,e,d,f,m,p,h)),y=s}else{let e=t;v=Ga(e.length>1?e(f,{attrs:s,slots:o,emit:l}):e(f,null)),y=t.props?s:Bi(s)}}catch(t){Oa.length=0,An(t,e,1),v=B(Ea)}let b=v;if(y&&g!==!1){let e=Object.keys(y),{shapeFlag:t}=b;e.length&&t&7&&(a&&e.some(c)&&(y=Vi(y,a)),b=Va(b,y,!1,!0))}return n.dirs&&(b=Va(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&kr(mr(b.type)&&Or(b)||b,n.transition),v=b,Qn(_),v}function zi(e,t=!0){let n;for(let t=0;t<e.length;t++){let r=e[t];if(Fa(r)){if(r.type!==Ea||r.children===`v-if`){if(n)return;n=r}}else return}return n}var Bi=e=>{let t;for(let n in e)(n===`class`||n===`style`||s(n))&&((t||={})[n]=e[n]);return t},Vi=(e,t)=>{let n={};for(let r in e)c(r)&&r.slice(9)in t||(n[r]=e[r]);return n};function Hi(e,t,n){let{props:r,children:i,component:a}=e,{props:o,children:s,patchFlag:c}=t,l=a.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?Ui(r,o,l):!!o;if(c&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t];if(Wi(o,r,n)&&!Li(l,n))return!0}}}else return(i||s)&&(!s||!s.$stable)?!0:r===o?!1:r?!o||Ui(r,o,l):!!o;return!1}function Ui(e,t,n){let r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){let a=r[i];if(!f(e,a)||Wi(t,e,a)&&!Li(n,a))return!0}return!1}function Wi(e,t,n){let r=e[n],i=t[n];return n===`style`&&b(r)&&b(i)?!xe(r,i):r!==i}function Gi({vnode:e,parent:t,suspense:n},r){for(;t;){let n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.suspense.vnode.el=n.el=r,e=n),n===e)(e=t.vnode).el=r,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=r)}var Ki={},qi=()=>Object.create(Ki),Ji=e=>Object.getPrototypeOf(e)===Ki;function Yi(e,t,n,r=!1){let i={},a=qi();e.propsDefaults=Object.create(null),Zi(e,t,i,a);for(let t in e.propsOptions[0])t in i||(i[t]=void 0);e.props=n?r?i:Kt(i):e.type.props?i:a,e.attrs=a}function Xi(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:o}}=e,s=en(i),[c]=e.propsOptions,l=!1;if((r||o>0)&&!(o&16)){if(o&8){let n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let o=n[r];if(Li(e.emitsOptions,o))continue;let u=t[o];if(c){if(f(a,o))u!==a[o]&&(a[o]=u,l=!0);else{let t=A(o);i[t]=Qi(c,s,t,u,e,!1)}}else u!==a[o]&&(a[o]=u,l=!0)}}}else{Zi(e,t,i,a)&&(l=!0);let r;for(let a in s)t&&(f(t,a)||(r=te(a))!==a&&f(t,r))||(c?n&&(n[a]!==void 0||n[r]!==void 0)&&(i[a]=Qi(c,s,a,void 0,e,!0)):delete i[a]);if(a!==s)for(let e in a)t&&f(t,e)||(delete a[e],l=!0)}l&&st(e.attrs,`set`,``)}function Zi(e,t,n,i){let[a,o]=e.propsOptions,s=!1,c;if(t)for(let r in t){if(D(r))continue;let l=t[r],u;a&&f(a,u=A(r))?!o||!o.includes(u)?n[u]=l:(c||={})[u]=l:Li(e.emitsOptions,r)||r in i&&l===i[r]||(i[r]=l,s=!0)}if(o){let t=en(n),i=c||r;for(let r=0;r<o.length;r++){let s=o[r];n[s]=Qi(a,t,s,i[s],e,!f(i,s))}}return s}function Qi(e,t,n,r,i,a){let o=e[n];if(o!=null){let e=f(o,`default`);if(e&&r===void 0){let e=o.default;if(o.type!==Function&&!o.skipFactory&&_(e)){let{propsDefaults:a}=i;if(n in a)r=a[n];else{let o=io(i);r=a[n]=e.call(null,t),o()}}else r=e;i.ce&&i.ce._setProp(n,r)}o[0]&&(a&&!e?r=!1:o[1]&&(r===``||r===te(n))&&(r=!0))}return r}var $i=new WeakMap;function ea(e,t,n=!1){let a=n?$i:t.propsCache,o=a.get(e);if(o)return o;let s=e.props,c={},u=[],d=!1;if(!_(e)){let r=e=>{d=!0;let[n,r]=ea(e,t,!0);l(c,n),r&&u.push(...r)};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}if(!s&&!d)return b(e)&&a.set(e,i),i;if(p(s))for(let e=0;e<s.length;e++){let t=A(s[e]);ta(t)&&(c[t]=r)}else if(s)for(let e in s){let t=A(e);if(ta(t)){let n=s[e],r=c[t]=p(n)||_(n)?{type:n}:l({},n),i=r.type,a=!1,o=!0;if(p(i))for(let e=0;e<i.length;++e){let t=i[e],n=_(t)&&t.name;if(n===`Boolean`){a=!0;break}n===`String`&&(o=!1)}else a=_(i)&&i.name===`Boolean`;r[0]=a,r[1]=o,(a||f(r,`default`))&&u.push(t)}}let m=[c,u];return b(e)&&a.set(e,m),m}function ta(e){return e[0]!==`$`&&!D(e)}var na=e=>e===`_`||e===`_ctx`||e===`$stable`,ra=e=>p(e)?e.map(Ga):[Ga(e)],ia=(e,t,n)=>{if(t._n)return t;let r=F((...e)=>ra(t(...e)),n);return r._c=!1,r},aa=(e,t,n)=>{let r=e._ctx;for(let n in e){if(na(n))continue;let i=e[n];if(_(i))t[n]=ia(n,i,r);else if(i!=null){let e=ra(i);t[n]=()=>e}}},oa=(e,t)=>{let n=ra(t);e.slots.default=()=>n},sa=(e,t,n)=>{for(let r in t)(n||!na(r))&&(e[r]=t[r])},ca=(e,t,n)=>{let r=e.slots=qi();if(e.vnode.shapeFlag&32){let e=t._;e?(sa(r,t,n),n&&ae(r,`_`,e,!0)):aa(t,r)}else t&&oa(e,t)},la=(e,t,n)=>{let{vnode:i,slots:a}=e,o=!0,s=r;if(i.shapeFlag&32){let e=t._;e?n&&e===1?o=!1:sa(a,t,n):(o=!t.$stable,aa(t,a)),s=t}else t&&(oa(e,t),s={default:1});if(o)for(let e in a)!na(e)&&s[e]==null&&delete a[e]},ua=Ca;function da(e){return fa(e)}function fa(e,t){let n=ce();n.__VUE__=!0;let{insert:o,remove:s,patchProp:c,createElement:l,createText:u,createComment:d,setText:f,setElementText:p,parentNode:m,nextSibling:h,setScopeId:g=a,insertStaticContent:_}=e,v=(e,t,n,r=null,a=null,o=null,s=void 0,c=null,l=!!t.dynamicChildren)=>{if(e===t)return;e&&!Ia(e,t)&&(r=ge(e),fe(e,a,o,!0),e=null),t.patchFlag===-2&&(l=!1,t.dynamicChildren=null),t.dynamicChildren&&e&&e.dynamicChildren&&e.dynamicChildren.hasOnce&&(t.dynamicChildren===i&&(t.dynamicChildren=[]),t.dynamicChildren.hasOnce=!0);let{type:u,ref:d,shapeFlag:f}=t;switch(u){case Ta:y(e,t,n,r);break;case Ea:b(e,t,n,r);break;case Da:e??x(t,n,r,s);break;case wa:te(e,t,n,r,a,o,s,c,l);break;default:f&1?w(e,t,n,r,a,o,s,c,l):f&6?ne(e,t,n,r,a,o,s,c,l):(f&64||f&128)&&u.process(e,t,n,r,a,o,s,c,l,ve)}d!=null&&a?Ir(d,e&&e.ref,o,t||e,!t):d==null&&e&&e.ref!=null&&Ir(e.ref,null,o,e,!0)},y=(e,t,n,r)=>{if(e==null)o(t.el=u(t.children),n,r);else{let n=t.el=e.el;t.children!==e.children&&f(n,t.children)}},b=(e,t,n,r)=>{e==null?o(t.el=d(t.children||``),n,r):t.el=e.el},x=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,r)=>{let i;for(;e&&e!==t;)i=h(e),o(e,n,r),e=i;o(t,n,r)},C=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=h(e),s(e),e=n;s(t)},w=(e,t,n,r,i,a,o,s,c)=>{if(t.type===`svg`?o=`svg`:t.type===`math`&&(o=`mathml`),e==null)T(t,n,r,i,a,o,s,c);else{let n=e.el&&e.el._isVueCE?e.el:null;try{n&&n._beginPatch(),k(e,t,i,a,o,s,c)}finally{n&&n._endPatch()}}},T=(e,t,n,r,i,a,s,u)=>{let d,f,{props:m,shapeFlag:h,transition:g,dirs:_}=e;if(d=e.el=l(e.type,a,m&&m.is,m),h&8?p(d,e.children):h&16&&O(e.children,d,null,r,i,pa(e,a),s,u),_&&er(e,null,r,`created`),E(d,e,e.scopeId,s,r),m){for(let e in m)e!==`value`&&!D(e)&&c(d,e,null,m[e],a,r);`value`in m&&c(d,`value`,null,m.value,a),(f=m.onVnodeBeforeMount)&&Ya(f,r,e)}_&&er(e,null,r,`beforeMount`);let v=ha(i,g);v?g.beforeEnter(d):g&&!g.persisted&&(d[Sa]=!0),o(d,t,n),((f=m&&m.onVnodeMounted)||v||_)&&ua(()=>{try{f&&Ya(f,r,e),v&&g.enter(d),_&&er(e,null,r,`mounted`)}finally{}},i)},E=(e,t,n,r,i)=>{if(n&&g(e,n),r)for(let t=0;t<r.length;t++)g(e,r[t]);if(i){let n=i.subTree;if(t===n||xa(n.type)&&(n.ssContent===t||n.ssFallback===t)){let t=i.vnode;E(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},O=(e,t,n,r,i,a,o,s,c=0)=>{for(let l=c;l<e.length;l++){let c=e[l]=s?Ka(e[l]):Ga(e[l]);v(null,c,t,n,r,i,a,o,s)}},k=(e,t,n,i,a,o,s)=>{let l=t.el=e.el,{patchFlag:u,dynamicChildren:d,dirs:f}=t;u|=e.patchFlag&16;let m=e.props||r,h=t.props||r,g;if(n&&ma(n,!1),(g=h.onVnodeBeforeUpdate)&&Ya(g,n,t,e),f&&er(t,e,n,`beforeUpdate`),n&&ma(n,!0),d&&(!e.dynamicChildren||e.dynamicChildren.length!==d.length)&&(u=0,s=!1,d=null),(m.innerHTML&&h.innerHTML==null||m.textContent&&h.textContent==null)&&p(l,``),d?A(e.dynamicChildren,d,l,n,i,pa(t,a),o):s||se(e,t,l,null,n,i,pa(t,a),o,!1),u>0){if(u&16)ee(l,m,h,n,a);else if(u&2&&m.class!==h.class&&c(l,`class`,null,h.class,a),u&4&&c(l,`style`,m.style,h.style,a),u&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let r=e[t],i=m[r],o=h[r];(o!==i||r===`value`)&&c(l,r,i,o,a,n)}}u&1&&e.children!==t.children&&p(l,t.children)}else!s&&d==null&&ee(l,m,h,n,a);((g=h.onVnodeUpdated)||f)&&ua(()=>{g&&Ya(g,n,t,e),f&&er(t,e,n,`updated`)},i)},A=(e,t,n,r,i,a,o)=>{for(let s=0;s<t.length;s++){let c=e[s],l=t[s],u=c.el||ba(c),d=u&&(c.type===wa||!Ia(c,l)||c.shapeFlag&198)?m(u):n;v(c,l,d,null,r,i,a,o,!0)}},ee=(e,t,n,i,a)=>{if(t!==n){if(t!==r)for(let r in t)!D(r)&&!(r in n)&&c(e,r,t[r],null,a,i);for(let r in n){if(D(r))continue;let o=n[r],s=t[r];o!==s&&r!==`value`&&c(e,r,s,o,a,i)}`value`in n&&c(e,`value`,t.value,n.value,a)}},te=(e,t,n,r,i,a,s,c,l)=>{let d=t.el=e?e.el:u(``),f=t.anchor=e?e.anchor:u(``),{patchFlag:p,dynamicChildren:m,slotScopeIds:h}=t;h&&(c=c?c.concat(h):h),e==null?(o(d,n,r),o(f,n,r),O(t.children||[],n,f,i,a,s,c,l)):p>0&&p&64&&m&&e.dynamicChildren&&e.dynamicChildren.length===m.length?(A(e.dynamicChildren,m,n,i,a,s,c),(t.key!=null||i&&t===i.subTree)&&ga(e,t,!0)):se(e,t,n,f,i,a,s,c,l)},ne=(e,t,n,r,i,a,o,s,c)=>{t.slotScopeIds=s,e==null?t.shapeFlag&512?i.ctx.activate(t,n,r,o,c):re(t,n,r,i,a,o,c):j(e,t,c)},re=(e,t,n,r,i,a,o)=>{let s=e.component=$a(e,r,i);if(zr(e)&&(s.ctx.renderer=ve),co(s,!1,o),s.asyncDep){if(i&&i.registerDep(s,ae,o,a),!e.el){let r=s.subTree=B(Ea);b(null,r,t,n),e.placeholder=r.el}}else ae(s,e,t,n,i,a,o)},j=(e,t,n)=>{let r=t.component=e.component;if(Hi(e,t,n)){if(r.asyncDep&&!r.asyncResolved){t.el=e.el,t.placeholder=e.placeholder,oe(r,t,n);return}r.next=t,r.update()}else t.el=e.el,t.placeholder=e.placeholder,r.vnode=t},ae=(e,t,n,r,i,a,o)=>{let s=()=>{if(e.isMounted){let{next:t,bu:n,u:r,parent:s,vnode:c}=e;{let n=va(e);if(n){t&&(t.el=c.el,oe(e,t,o)),n.asyncDep.then(()=>{let t=()=>{e.job.flags&8||(i&&i.pendingBranch?ua(t,i):l())};t.flags=48,ua(t,i)});return}}let u=t,d;ma(e,!1),t?(t.el=c.el,oe(e,t,o)):t=c,n&&ie(n),(d=t.props&&t.props.onVnodeBeforeUpdate)&&Ya(d,s,t,c),ma(e,!0);let f=Ri(e),p=e.subTree;e.subTree=f,v(p,f,m(p.el||ba(p)),ge(p),e,i,a),t.el=f.el,u===null&&Gi(e,f.el),r&&ua(r,i),(d=t.props&&t.props.onVnodeUpdated)&&ua(()=>Ya(d,s,t,c),i)}else{let o,{el:s,props:c}=t,{bm:l,m:u,parent:d,root:f,type:p}=e,m=Rr(t);if(ma(e,!1),l&&ie(l),!m&&(o=c&&c.onVnodeBeforeMount)&&Ya(o,d,t),ma(e,!0),s&&be){let t=()=>{e.subTree=Ri(e),be(s,e.subTree,e,i,null)};m&&p.__asyncHydrate?p.__asyncHydrate(s,e,t):t()}else{f.ce&&f.ce._hasShadowRoot()&&f.ce._injectChildStyle(p,e.parent?e.parent.type:void 0);let o=e.subTree=Ri(e);v(null,o,n,r,e,i,a),t.el=o.el}if(u&&ua(u,i),!m&&(o=c&&c.onVnodeMounted)){let e=t;ua(()=>Ya(o,d,e),i)}(t.shapeFlag&256||d&&Rr(d.vnode)&&d.vnode.shapeFlag&256)&&e.a&&ua(e.a,i),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new Pe(s);e.scope.off();let l=e.update=c.run.bind(c),u=e.job=c.runIfDirty.bind(c);u.i=e,u.id=e.uid,c.scheduler=()=>Vn(u),ma(e,!0),l()},oe=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,Xi(e,t.props,r,n),la(e,t.children,n),Ye(),Wn(e),Xe()},se=(e,t,n,r,i,a,o,s,c=!1)=>{let l=e&&e.children,u=e?e.shapeFlag:0,d=t.children,{patchFlag:f,shapeFlag:m}=t;if(f>0){if(f&128){ue(l,d,n,r,i,a,o,s,c);return}if(f&256){le(l,d,n,r,i,a,o,s,c);return}}m&8?(u&16&&he(l,i,a),d!==l&&p(n,d)):u&16?m&16?ue(l,d,n,r,i,a,o,s,c):he(l,i,a,!0):(u&8&&p(n,``),m&16&&O(d,n,r,i,a,o,s,c))},le=(e,t,n,r,a,o,s,c,l)=>{e||=i,t||=i;let u=e.length,d=t.length,f=Math.min(u,d),p=0;for(;p<f;p++){let r=t[p]=l?Ka(t[p]):Ga(t[p]);v(e[p],r,n,null,a,o,s,c,l)}u>d?he(e,a,o,!0,!1,f):O(t,n,r,a,o,s,c,l,f)},ue=(e,t,n,r,a,o,s,c,l)=>{let u=0,d=t.length,f=e.length-1,p=d-1;for(;u<=f&&u<=p;){let r=e[u],i=t[u]=l?Ka(t[u]):Ga(t[u]);if(Ia(r,i))v(r,i,n,null,a,o,s,c,l);else break;u++}for(;u<=f&&u<=p;){let r=e[f],i=t[p]=l?Ka(t[p]):Ga(t[p]);if(Ia(r,i))v(r,i,n,null,a,o,s,c,l);else break;f--,p--}if(u>f){if(u<=p){let e=p+1,i=e<d?t[e].el:r;for(;u<=p;)v(null,t[u]=l?Ka(t[u]):Ga(t[u]),n,i,a,o,s,c,l),u++}}else if(u>p)for(;u<=f;)fe(e[u],a,o,!0),u++;else{let m=u,h=u,g=new Map;for(u=h;u<=p;u++){let e=t[u]=l?Ka(t[u]):Ga(t[u]);e.key!=null&&g.set(e.key,u)}let _,y=0,b=p-h+1,x=!1,S=0,C=Array(b);for(u=0;u<b;u++)C[u]=0;for(u=m;u<=f;u++){let r=e[u];if(y>=b){fe(r,a,o,!0);continue}let i;if(r.key!=null)i=g.get(r.key);else for(_=h;_<=p;_++)if(C[_-h]===0&&Ia(r,t[_])){i=_;break}i===void 0?fe(r,a,o,!0):(C[i-h]=u+1,i>=S?S=i:x=!0,v(r,t[i],n,null,a,o,s,c,l),y++)}let w=x?_a(C):i;for(_=w.length-1,u=b-1;u>=0;u--){let e=h+u,i=t[e],f=t[e+1],p=e+1<d?f.el||ba(f):r;C[u]===0?v(null,i,n,p,a,o,s,c,l):x&&(_<0||u!==w[_]?de(i,n,p,2):_--)}}},de=(e,t,n,r,i=null)=>{let{el:a,type:c,transition:l,children:u,shapeFlag:d}=e;if(d&6)de(e.component.subTree,t,n,r);else if(d&128)e.suspense.move(t,n,r);else if(d&64)c.move(e,t,n,ve);else if(c===wa){o(a,t,n);for(let e=0;e<u.length;e++)de(u[e],t,n,r);o(e.anchor,t,n)}else if(c===Da)S(e,t,n);else if(r!==2&&d&1&&l){if(r===0)l.persisted&&!a[Er]?o(a,t,n):(l.beforeEnter(a),o(a,t,n),ua(()=>l.enter(a),i));else{let{leave:r,delayLeave:i,afterLeave:c}=l,u=()=>{e.ctx.isUnmounted?s(a):o(a,t,n)},d=()=>{let e=a._isLeaving||!!a[Er];a._isLeaving&&a[Er](!0),l.persisted&&!e?u():r(a,()=>{u(),c&&c()})};i?i(a,u,d):d()}}else o(a,t,n)},fe=(e,t,n,r=!1,i=!1)=>{let{type:a,props:o,ref:s,children:c,dynamicChildren:l,shapeFlag:u,patchFlag:d,dirs:f,cacheIndex:p,memo:m}=e;if((d===-2||l&&l.hasOnce)&&(i=!1),s!=null&&(Ye(),Ir(s,null,n,e,!0),Xe()),p==null||e.ctx&&e.ctx!==t||(t.renderCache[p]=void 0),u&256&&t.ctx.deactivate(e))return;let h=u&1&&f,g=!Rr(e),_;if(g&&(_=o&&o.onVnodeBeforeUnmount)&&Ya(_,t,e),u&6)me(e.component,n,r);else{if(u&128){e.suspense.unmount(n,r);return}h&&er(e,null,t,`beforeUnmount`),u&64?e.type.remove(e,t,n,ve,r):l&&!l.hasOnce&&(a!==wa||d>0&&d&64)?he(l,t,n,!1,!0):(a===wa&&d&384||!i&&u&16)&&he(c,t,n),r&&pe(e)}let v=m!=null&&p==null;(g&&(_=o&&o.onVnodeUnmounted)||h||v)&&ua(()=>{_&&Ya(_,t,e),h&&er(e,null,t,`unmounted`),v&&(e.el=null)},n)},pe=e=>{let{type:t,el:n,anchor:r,transition:i}=e,a=t===wa;if(a&&!i){M(n,r);return}if(t===Da){C(e),i&&!i.persisted&&i.afterLeave&&i.afterLeave();return}let o=a?Ar(e):e,c=()=>{a?m(n)&&M(n,r):s(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(o&&o.shapeFlag&1&&i&&!i.persisted){let{leave:e,delayLeave:t}=i,n=o.el,r=()=>e(n,c);t?t(n,c,r):r()}else c()},M=(e,t)=>{let n;for(;e!==t;)n=h(e),s(e),e=n;s(t)},me=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:o,um:s,m:c,a:l}=e;ya(c),ya(l),r&&ie(r),i.stop(),a?(a.flags|=8,fe(o,e,t,n)):o&&(o.transition=e.vnode.transition,fe(o,e,t,n)),s&&ua(s,t);let u=()=>{e.isUnmounted=!0};u.flags=16,ua(u,t)},he=(e,t,n,r=!1,i=!1,a=0)=>{for(let o=a;o<e.length;o++)fe(e[o],t,n,r,i)},ge=e=>{if(e.shapeFlag&6)return ge(e.component.subTree);if(e.shapeFlag&128)return e.suspense.next();let t=h(e.anchor||e.el),n=t&&t[pr];return n?h(n):t},_e=(e,t,n)=>{qn(()=>{e==null?t._vnode&&fe(t._vnode,null,null,!0):v(t._vnode||null,e,t,null,null,null,n),t._vnode=e},e&&t._vnode?void 0:e&&e.component?e.component.uid:Qa())},ve={p:v,um:fe,m:de,r:pe,mt:re,mc:O,pc:se,pbc:A,n:ge,o:e},ye,be;return t&&([ye,be]=t(ve)),{render:_e,hydrate:ye,createApp:Ai(_e,ye)}}function pa({type:e,props:t},n){return n===`svg`&&e===`foreignObject`||n===`mathml`&&e===`annotation-xml`&&t&&t.encoding&&t.encoding.includes(`html`)?void 0:n}function ma({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function ha(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function ga(e,t,n=!1){let r=e.children,i=t.children;if(p(r)&&p(i))for(let e=0;e<r.length;e++){let t=r[e],a=i[e];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=i[e]=Ka(i[e]),a.el=t.el),!n&&a.patchFlag!==-2&&ga(t,a)),a.type===Ta&&(a.patchFlag===-1&&(a=i[e]=Ka(a)),a.el=t.el),a.type===Ea&&!a.el&&(a.el=t.el)}}function _a(e){let t=e.slice(),n=[0],r,i,a,o,s,c=e.length;for(r=0;r<c;r++){let c=e[r];if(c!==0){if(i=n[n.length-1],e[i]<c){t[r]=i,n.push(r);continue}for(a=0,o=n.length-1;a<o;)s=a+o>>1,e[n[s]]<c?a=s+1:o=s;c<e[n[a]]&&(a>0&&(t[r]=n[a-1]),n[a]=r)}}for(a=n.length,o=n[a-1];a-->0;)n[a]=o,o=t[o];return n}function va(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:va(t)}function ya(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function ba(e){if(e.placeholder)return e.placeholder;let t=e.component;if(t)return ba(t.subTree);let n=e.suspense;return n&&n.activeBranch?ba(n.activeBranch):null}var xa=e=>e.__isSuspense,Sa=Symbol(`_deferredEnter`);function Ca(e,t){t&&t.pendingBranch?p(e)?t.effects.push(...e):t.effects.push(e):Un(e)}var wa=Symbol.for(`v-fgt`),Ta=Symbol.for(`v-txt`),Ea=Symbol.for(`v-cmt`),Da=Symbol.for(`v-stc`),Oa=[],ka=null;function L(e=!1){Oa.push(ka=e?null:[])}function Aa(){Oa.pop(),ka=Oa[Oa.length-1]||null}var ja=1;function Ma(e,t=!1){ja+=e,e<0&&ka&&t&&(ka.hasOnce=!0)}function Na(e){return e.dynamicChildren=ja>0?ka||i:null,Aa(),ja>0&&ka&&ka.push(e),e}function Pa(e,t,n,r,i,a){return Na(z(e,t,n,r,i,a,!0))}function R(e,t,n,r,i){return Na(B(e,t,n,r,i,!0))}function Fa(e){return e?e.__v_isVNode===!0:!1}function Ia(e,t){return e.type===t.type&&e.key===t.key}var La=({key:e})=>e??null,Ra=({ref:e,ref_key:t,ref_for:n})=>(typeof e==`number`&&(e=``+e),e==null?null:v(e)||an(e)||_(e)?{i:Xn,r:e,k:t,f:!!n}:e);function z(e,t=null,n=null,r=0,i=null,a=e===wa?0:1,o=!1,s=!1){let c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&La(t),ref:t&&Ra(t),scopeId:Zn,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Xn};return s?(qa(c,n),a&128&&e.normalize(c)):n&&(c.shapeFlag|=v(n)?8:16),ja>0&&!o&&ka&&(c.patchFlag>0||a&6)&&c.patchFlag!==32&&ka.push(c),c}var B=za;function za(e,t=null,n=null,r=0,i=null,a=!1){if(e&&e!==ni||(e=Ea),Fa(e)){let r=Va(e,t,!0);return n&&qa(r,n),ja>0&&!a&&ka&&(r.shapeFlag&6?ka[ka.indexOf(e)]=r:ka.push(r)),r.patchFlag=-2,r}if(_o(e)&&(e=e.__vccOpts),t){t=Ba(t);let{class:e,style:n}=t;e&&!v(e)&&(t.class=M(e)),b(n)&&($t(n)&&!p(n)&&(n=l({},n)),t.style=le(n))}let o=v(e)?1:xa(e)?128:mr(e)?64:b(e)?4:_(e)?2:0;return z(e,t,n,r,i,o,a,!0)}function Ba(e){return e?$t(e)?l({},e):Ji(e)?l({},e[po]||e):e:null}function Va(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:o,children:s,transition:c}=e,l=t?Ja(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&La(l),ref:t&&t.ref?n&&a?p(a)?a.concat(Ra(t)):[a,Ra(t)]:Ra(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==wa?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Va(e.ssContent),ssFallback:e.ssFallback&&Va(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce,cacheIndex:e.cacheIndex};return c&&r&&kr(u,c.clone(u)),u}function Ha(e=` `,t=0){return B(Ta,null,e,t)}function Ua(e,t){let n=B(Da,null,e);return n.staticCount=t,n}function Wa(e=``,t=!1){return t?(L(),R(Ea,null,e)):B(Ea,null,e)}function Ga(e){return e==null||typeof e==`boolean`?B(Ea):p(e)?B(wa,null,e.slice()):Fa(e)?Ka(e):B(Ta,null,String(e))}function Ka(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Va(e)}function qa(e,t){let n=0,{shapeFlag:r}=e;if(t==null)t=null;else if(p(t))n=16;else if(typeof t==`object`){if(r&65){let n=t.default;n&&(n._c&&(n._d=!1),qa(e,n()),n._c&&(n._d=!0));return}{n=32;let r=t._;!r&&!Ji(t)?t._ctx=Xn:r===3&&Xn&&(Xn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}}else if(_(t)){if(r&65){qa(e,{default:t});return}t={default:t,_ctx:Xn},n=32}else t=String(t),r&64?(n=16,t=[Ha(t)]):n=8;e.children=t,e.shapeFlag|=n}function Ja(...e){let t={};for(let n=0;n<e.length;n++){let r=e[n];for(let e in r)if(e===`class`)t.class!==r.class&&(t.class=M([t.class,r.class]));else if(e===`style`)t.style=le([t.style,r.style]);else if(s(e)){let n=t[e],i=r[e];i&&n!==i&&!(p(n)&&n.includes(i))?t[e]=n?[].concat(n,i):i:i==null&&n==null&&!c(e)&&(t[e]=i)}else e!==``&&(t[e]=r[e])}return t}function Ya(e,t,n,r=null){kn(e,t,7,[n,r])}var Xa=Oi(),Za=0;function Qa(){return Za}function $a(e,t,n){let i=e.type,a=(t?t.appContext:e.appContext)||Xa,o={uid:Za++,vnode:e,type:i,parent:t,appContext:a,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Oe(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(a.provides),ids:t?t.ids:[``,0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:ea(i,a),emitsOptions:Ii(i,a),emit:null,emitted:null,propsDefaults:r,inheritAttrs:i.inheritAttrs,ctx:r,data:r,props:r,attrs:r,slots:r,refs:r,setupState:r,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=Pi.bind(null,o),e.ce&&e.ce(o),o}var eo=null,to=()=>eo||Xn,no,ro;{let e=ce(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};no=t(`__VUE_INSTANCE_SETTERS__`,e=>eo=e),ro=t(`__VUE_SSR_SETTERS__`,e=>so=e)}var io=e=>{let t=eo;return no(e),e.scope.on(),()=>{e.scope.off(),no(t)}},ao=()=>{eo&&eo.scope.off(),no(null)};function oo(e){return e.vnode.shapeFlag&4}var so=!1;function co(e,t=!1,n=!1){t&&ro(t);let{props:r,children:i}=e.vnode,a=oo(e);Yi(e,r,a,t),ca(e,i,n||t);let o=a?lo(e,t):void 0;return t&&ro(!1),o}function lo(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,ui);let{setup:r}=n;if(r){Ye();let n=e.setupContext=r.length>1?ho(e):null,i=io(e),a=On(r,e,0,[e.props,n]),o=x(a);if(Xe(),i(),(o||e.sp)&&!Rr(e)&&Mr(e),o){if(a.then(ao,ao),t)return a.then(n=>{ro(!0);try{uo(e,n,t)}finally{ro(!1)}}).catch(t=>{An(t,e,0,void 0,!0),e.ssrRender=(e,t)=>t(`<!---->`)});e.asyncDep=a}else uo(e,a,t)}else fo(e,t)}function uo(e,t,n){_(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:b(t)&&(e.setupState=fn(t)),fo(e,n)}function fo(e,t,n){let r=e.type;e.render||=r.render||a;{let t=io(e);Ye();try{mi(e)}finally{Xe(),t()}}}var po=Symbol(),mo={get(e,t){return ot(e,`get`,``),t===po?e:e[t]}};function ho(e){return{attrs:new Proxy(e.attrs,mo),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function go(e){return e.exposed?e.exposeProxy||=new Proxy(fn(tn(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in ci)return ci[n](e)},has(e,t){return t in e||t in ci}}):e.proxy}function _o(e){return _(e)&&`__vccOpts`in e}var V=(e,t)=>xn(e,t,so);function vo(e,t,n){try{Ma(-1);let r=arguments.length;return r===2?b(t)&&!p(t)?Fa(t)?B(e,null,[t]):B(e,t):B(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&Fa(n)&&(n=[n]),B(e,t,n))}finally{Ma(1)}}var yo=`3.5.45`,bo=void 0,xo=typeof window<`u`&&window.trustedTypes;if(xo)try{bo=xo.createPolicy(`vue`,{createHTML:e=>e})}catch{}var So=bo?e=>bo.createHTML(e):e=>e,Co=`http://www.w3.org/2000/svg`,wo=`http://www.w3.org/1998/Math/MathML`,To=typeof document<`u`?document:null,Eo=To&&To.createElement(`template`),Do={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?To.createElementNS(Co,e):t===`mathml`?To.createElementNS(wo,e):n?To.createElement(e,{is:n}):To.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>To.createTextNode(e),createComment:e=>To.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>To.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),i!==a&&(i=i.nextSibling););else{Eo.innerHTML=So(r===`svg`?`<svg>${e}</svg>`:r===`mathml`?`<math>${e}</math>`:e);let i=Eo.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Oo=Symbol(`_vtc`);function ko(e,t,n){let r=e[Oo];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var Ao=Symbol(`_vod`),jo=Symbol(`_vsh`),Mo={name:`show`,beforeMount(e,{value:t},{transition:n}){e[Ao]=e.style.display===`none`?``:e.style.display,n&&t?n.beforeEnter(e):No(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),No(e,!0),r.enter(e)):r.leave(e,()=>{No(e,!1)}):No(e,t))},beforeUnmount(e,{value:t}){No(e,t)}};function No(e,t){e.style.display=t?e[Ao]:`none`,e[jo]=!t}var Po=Symbol(``),Fo=/(?:^|;)\s*display\s*:/;function Io(e,t,n){let r=e.style,i=v(n),a=!1;if(n&&!i){if(t){if(v(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??Ro(r,t,``)}else for(let e in t)n[e]??Ro(r,e,``)}for(let i in n){i===`display`&&(a=!0);let o=n[i];o==null?Ro(r,i,``):Ho(e,i,!v(t)&&t?t[i]:void 0,o)||Ro(r,i,o)}}else if(i){if(t!==n){let e=r[Po];e&&(n+=`;`+e),r.cssText=n,a=Fo.test(n)}}else t&&e.removeAttribute(`style`);Ao in e&&(i&&t===n||(e[Ao]=a?r.display:``),e[jo]&&(r.display=`none`))}var Lo=/\s*!important$/;function Ro(e,t,n){if(p(n))n.forEach(n=>Ro(e,t,n));else if(n??=``,t.startsWith(`--`))Lo.test(n)?e.setProperty(t,n.replace(Lo,``),`important`):e.setProperty(t,n);else{let r=Vo(e,t);Lo.test(n)?e.setProperty(te(r),n.replace(Lo,``),`important`):e[r]=n}}var zo=[`Webkit`,`Moz`,`ms`],Bo={};function Vo(e,t){let n=Bo[t];if(n)return n;let r=A(t);if(r!==`filter`&&r in e)return Bo[t]=r;r=ne(r);for(let n=0;n<zo.length;n++){let i=zo[n]+r;if(i in e)return Bo[t]=i}return t}function Ho(e,t,n,r){return e.tagName===`TEXTAREA`&&(t===`width`||t===`height`)&&v(r)&&n===r}var Uo=`http://www.w3.org/1999/xlink`;function Wo(e,t,n,r,i,a=he(t)){r&&t.startsWith(`xlink:`)?n==null?e.removeAttributeNS(Uo,t.slice(6,t.length)):e.setAttributeNS(Uo,t,n):n==null||a&&!ge(n)?e.removeAttribute(t):e.setAttribute(t,a?``:y(n)?String(n):n)}function Go(e,t,n,r,i){if(t===`innerHTML`||t===`textContent`){n!=null&&(e[t]=t===`innerHTML`?So(n):n);return}let a=e.tagName;if(t===`value`&&a!==`PROGRESS`&&!a.includes(`-`)){let r=a===`OPTION`?e.getAttribute(`value`)||``:e.value,i=n==null?e.type===`checkbox`?`on`:``:String(n);r===i&&`_value`in e||(e.value=i),n??e.removeAttribute(t),e._value=n;return}let o=!1;if(n===``||n==null){let r=typeof e[t];r===`boolean`?n=ge(n):n==null&&r===`string`?(n=``,o=!0):r===`number`&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(i||t)}function Ko(e,t,n,r){e.addEventListener(t,n,r)}function qo(e,t,n,r){e.removeEventListener(t,n,r)}var Jo=Symbol(`_vei`);function Yo(e,t,n,r,i=null){let a=e[Jo]||(e[Jo]={}),o=a[t];if(r&&o)o.value=r;else{let[n,s]=Qo(t);r?Ko(e,n,a[t]=ns(r,i),s):o&&(qo(e,n,o,s),a[t]=void 0)}}var Xo=/(Once|Passive|Capture)$/,Zo=/^on:?(?:Once|Passive|Capture)$/;function Qo(e){let t,n;for(;(n=e.match(Xo))&&!Zo.test(e);)t||={},e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===`:`?e.slice(3):te(e.slice(2)),t]}var $o=0,es=Promise.resolve(),ts=()=>$o||=(es.then(()=>$o=0),Date.now());function ns(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;let r=n.value;if(p(r)){let n=e.stopImmediatePropagation;e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0};let i=r.slice(),a=[e];for(let n=0;n<i.length&&!e._stopped;n++){let e=i[n];e&&kn(e,t,5,a)}}else kn(r,t,5,[e])};return n.value=e,n.attached=ts(),n}var rs=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,is=(e,t,n,r,i,a)=>{let o=i===`svg`;t===`class`?ko(e,r,o):t===`style`?Io(e,n,r):s(t)?c(t)||Yo(e,t,n,r,a):(t[0]===`.`?(t=t.slice(1),1):t[0]===`^`?(t=t.slice(1),0):as(e,t,r,o))?(Go(e,t,r),e.tagName.includes(`-`)||t!==`value`&&t!==`checked`&&t!==`selected`||Wo(e,t,r,o,a,t!==`value`)):e._isVueCE&&(os(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!v(r)))?Go(e,A(t),r,a,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),Wo(e,t,r,o))};function as(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&rs(t)&&_(n));if(t===`spellcheck`||t===`draggable`||t===`translate`||t===`autocorrect`||t===`sandbox`&&e.tagName===`IFRAME`||t===`form`||t===`list`&&e.tagName===`INPUT`||t===`type`&&e.tagName===`TEXTAREA`)return!1;if(t===`width`||t===`height`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return rs(t)&&v(n)?!1:t in e}function os(e,t){let n=e._def.props;if(!n)return!1;let r=A(t);return Array.isArray(n)?n.some(e=>A(e)===r):Object.keys(n).some(e=>A(e)===r)}var ss=e=>{let t=e.props[`onUpdate:modelValue`]||!1;return p(t)?e=>ie(t,e):t},cs=Symbol(`_assign`),ls={deep:!0,created(e,{value:t,modifiers:{number:n}},r){e._modelValue=t,Ko(e,`change`,()=>{let t=Array.prototype.filter.call(e.options,e=>e.selected).map(e=>n?oe(fs(e)):fs(e)),r=e.multiple,i=r?h(e._modelValue)?new Set(t):t:t[0],a=e._pendingValue=[r,r?p(i)?t.slice():t:i];try{e[cs](i)}finally{zn(()=>{e._pendingValue===a&&(e._pendingValue=void 0)})}}),e[cs]=ss(r)},mounted(e,{value:t,modifiers:{number:n}}){ds(e,t,n)},beforeUpdate(e,{value:t},n){e._modelValue=t,e[cs]=ss(n)},updated(e,{value:t,modifiers:{number:n}}){let r=e._pendingValue;e._pendingValue=void 0,r&&r[0]===e.multiple&&us(t,r[1],r[0])||ds(e,t,n)}};function us(e,t,n){if(!n||p(e))return xe(e,t);if(h(e)){if(e.size!==t.length)return!1;for(let n of t)if(!e.has(n))return!1;return!0}return!1}function ds(e,t,n=!1){let r=e.multiple,i=p(t);if(!r||i||h(t)){for(let a=0,o=e.options.length;a<o;a++){let o=e.options[a],s=fs(o);if(r){if(i){let e=typeof s;o.selected=e===`string`||e===`number`?t.some(e=>String(e)===String(s)):Se(t,s)>-1}else o.selected=t.has(s)||n&&typeof s==`string`&&t.has(oe(s))}else if(xe(fs(o),t)){e.selectedIndex!==a&&(e.selectedIndex=a);return}}!r&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function fs(e){return`_value`in e?e._value:e.value}var ps=[`ctrl`,`shift`,`alt`,`meta`],ms={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,t)=>ps.some(n=>e[`${n}Key`]&&!t.includes(n))},hs=(e,t)=>{if(!e)return e;let n=e._withMods||={},r=t.join(`.`);return n[r]||(n[r]=((n,...r)=>{for(let e=0;e<t.length;e++){let r=ms[t[e]];if(r&&r(n,t))return}return e(n,...r)}))},gs={esc:`escape`,space:` `,up:`arrow-up`,left:`arrow-left`,right:`arrow-right`,down:`arrow-down`,delete:`backspace`},_s=(e,t)=>{let n=e._withKeys||={},r=t.join(`.`);return n[r]||(n[r]=(n=>{if(!(`key`in n))return;let r=te(n.key);if(t.some(e=>e===r||gs[e]===r))return e(n)}))},vs=l({patchProp:is},Do),ys;function bs(){return ys||=da(vs)}var xs=((...e)=>{let t=bs().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=Cs(e);if(!r)return;let i=t._component;_(i)||i.render||i.template||(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,Ss(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function Ss(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function Cs(e){return v(e)?document.querySelector(e):e}function ws(e){return e.lastIndexOf(`node_modules`)!==-1}function Ts(e){if(!ws(e))return``;let t=e.split(`/`),n=t.lastIndexOf(`node_modules`);return t[n+1].startsWith(`@`)?`${t[n+1]}/${t[n+2]}`:t[n+1]}function Es(e){let t=e.chunks.length,n=e.moduleFileNames.length,r=0;for(let t of e.chunks)for(let e of t.modules)e.virtual&&(r+=1);let i=new Map;for(let t of e.moduleFileNames){let e=Ts(t);if(!e)continue;let n=t.lastIndexOf(`node_modules/${e}`),r=i.get(e);r?r.indices.includes(n)||r.indices.push(n):i.set(e,{indices:[n]})}let a=[];for(let[e,t]of i)t.indices.length>1&&a.push({name:e,count:t.indices.length});return{numberOfModules:n,numberOfVirtualModules:r,numberOfChunks:t,numberOfDependencies:i.size,duplicatedDependencies:a,hasWarnings:a.length>0}}var Ds=[`disabled`],Os=I({__name:`BaseButton`,props:{disabled:{type:Boolean}},setup(e){return(t,n)=>(L(),Pa(`button`,{type:`button`,class:M([`h-6 inline-flex flex-shrink-0 cursor-pointer items-center justify-center gap-1 border border-gray-300 rounded bg-white px-2 text-xs text-gray-700 transition-colors dark:border-gray-700 active:bg-gray-200 dark:bg-gray-800 hover:bg-gray-100 dark:text-gray-200 dark:hover:bg-gray-700`,e.disabled?`opacity-50 cursor-not-allowed pointer-events-none`:``]),disabled:e.disabled},[ai(t.$slots,`default`)],10,Ds))}});function ks(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}var As=typeof document<`u`;function js(e,t){let n=typeof e==`string`&&!t?`${e}Context`:t,r=Symbol(n);return[t=>{let n=nr(r,t);if(n||n===null)return n;throw Error(`Injection \`${r.toString()}\` not found. Component must be used within ${Array.isArray(e)?`one of the following components: ${e.join(`, `)}`:`\`${e}\``}`)},e=>(tr(r,e),e)]}function Ms(){let e=document.activeElement;if(e==null)return null;for(;e!=null&&e.shadowRoot!=null&&e.shadowRoot.activeElement!=null;)e=e.shadowRoot.activeElement;return e}function Ns(e,t,n){let r=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&r.addEventListener(e,t,{once:!0}),r.dispatchEvent(i)}function Ps(e,t){return Ae()?(je(e,t),!0):!1}function Fs(e){let t=!1,n,r=ke(!0);return((...i)=>(t||=(n=r.run(()=>e(...i)),!0),n))}var Is=typeof window<`u`&&typeof document<`u`;typeof WorkerGlobalScope<`u`&&globalThis instanceof WorkerGlobalScope;var Ls=e=>e!==void 0,Rs=Object.prototype.toString,zs=e=>Rs.call(e)===`[object Object]`,Bs=Vs();function Vs(){var e,t;return Is&&!!((e=window)!=null&&(e=e.navigator)!=null&&e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window)==null||(t=t.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function Hs(e){return Array.isArray(e)?e:[e]}function Us(e){return e||to()}function Ws(e){if(!Is)return e;let t=0,n,r,i=()=>{--t,r&&t<=0&&(r.stop(),n=void 0,r=void 0)};return((...a)=>(t+=1,r||(r=ke(!0),n=r.run(()=>e(...a))),Ps(i),n))}function Gs(e,t){Us(t)&&Xr(e,t)}function Ks(e,t,n){return cr(e,t,{...n,immediate:!0})}var qs=Is?window:void 0;Is&&window.document,Is&&window.navigator,Is&&window.location;function Js(e){let t=un(e);return t?.$el??t}function Ys(...e){let t=(e,t,n,r)=>(e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)),n=V(()=>{let t=Hs(un(e[0])).filter(e=>e!=null);return t.every(e=>typeof e!=`string`)?t:void 0});return Ks(()=>[n.value?.map(e=>Js(e))??[qs].filter(e=>e!=null),Hs(un(n.value?e[1]:e[0])),Hs(P(n.value?e[2]:e[1])),un(n.value?e[3]:e[2])],([e,n,r,i],a,o)=>{if(!e?.length||!n?.length||!r?.length)return;let s=zs(i)?{...i}:i,c=e.flatMap(e=>n.flatMap(n=>r.map(r=>t(e,n,r,s))));o(()=>{c.forEach(e=>e())})},{flush:`post`})}function Xs(){let e=on(!1),t=to();return t&&qr(()=>{e.value=!0},t),e}function Zs(e){return typeof e==`function`?e:typeof e==`string`?t=>t.key===e:Array.isArray(e)?t=>e.includes(t.key):()=>!0}function Qs(...e){let t,n,r={};e.length===3?(t=e[0],n=e[1],r=e[2]):e.length===2?typeof e[1]==`object`?(t=!0,n=e[0],r=e[1]):(t=e[0],n=e[1]):(t=!0,n=e[0]);let{target:i=qs,eventName:a=`keydown`,passive:o=!1,dedupe:s=!1}=r,c=Zs(t);return Ys(i,a,e=>{e.repeat&&un(s)||c(e)&&n(e)},o)}function $s(e){return JSON.parse(JSON.stringify(e))}function ec(e,t,n,r={}){var i,a;let{clone:o=!1,passive:s=!1,eventName:c,deep:l=!1,defaultValue:u,shouldEmit:d}=r,f=to(),p=n||f?.emit||(f==null||(i=f.$emit)==null?void 0:i.bind(f))||(f==null||(a=f.proxy)==null||(a=a.$emit)==null?void 0:a.bind(f?.proxy)),m=c;t||=`modelValue`,m||=`update:${t.toString()}`;let h=e=>o?typeof o==`function`?o(e):$s(e):e,g=()=>Ls(e[t])?h(e[t]):u,_=e=>{d?d(e)&&p(m,e):p(m,e)};if(s){let n=N(g()),r=!1;return cr(()=>e[t],e=>{r||(r=!0,n.value=h(e),zn(()=>r=!1))}),cr(n,n=>{!r&&(n!==e[t]||l)&&_(n)},{deep:l}),n}return V({get(){return g()},set(e){_(e)}})}function tc(e){return e?e.flatMap(e=>e.type===wa?tc(e.children):[e]):[]}var[nc,rc]=js(`ConfigProvider`),ic=new WeakMap;function ac(e,t){let n=ic.get(e);n||(n={owners:new Set,original:e.body.style.pointerEvents},ic.set(e,n)),n.owners.add(t),e.body.style.pointerEvents=`none`}function oc(e,t){let n=ic.get(e);n?.owners.delete(t)&&n.owners.size===0&&(ic.delete(e),e.body.style.pointerEvents=n.original)}function sc(e){if(typeof e!=`object`||!e)return!1;let t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null||Symbol.iterator in e?!1:Symbol.toStringTag in e?Object.prototype.toString.call(e)===`[object Module]`:!0}function cc(e,t,n=`.`,r){if(!sc(t))return cc(e,{},n,r);let i={...t};for(let t of Object.keys(e)){if(t===`__proto__`||t===`constructor`)continue;let a=e[t];a!=null&&(r&&r(i,t,a,n)||(i[t]=Array.isArray(a)&&Array.isArray(i[t])?[...a,...i[t]]:sc(a)&&sc(i[t])?cc(a,i[t],(n?`${n}.`:``)+t.toString(),r):a))}return i}function lc(e){return(...t)=>t.reduce((t,n)=>cc(t,n,``,e),{})}var uc=lc(),dc=Symbol(`useBodyScrollLock`),fc=Ws(()=>{let e=N(new Map),t=N(),n=V(()=>{for(let t of e.value.values())if(t)return!0;return!1}),r=nc({scrollBody:N(!0)}),i=null,a=()=>{document.body.style.paddingRight=``,document.body.style.marginRight=``,oc(document,dc),document.documentElement.style.removeProperty(`--scrollbar-width`),document.body.style.overflow=t.value??``,Bs&&i?.(),t.value=void 0};return cr(n,(e,o)=>{if(!Is)return;if(!e){o&&a();return}t.value===void 0&&(t.value=document.body.style.overflow);let s=window.innerWidth-document.documentElement.clientWidth,c={padding:s,margin:0},l=r.scrollBody?.value?typeof r.scrollBody.value==`object`?uc({padding:r.scrollBody.value.padding===!0?s:r.scrollBody.value.padding,margin:r.scrollBody.value.margin===!0?s:r.scrollBody.value.margin},c):c:{padding:0,margin:0};s>0&&(document.body.style.paddingRight=typeof l.padding==`number`?`${l.padding}px`:String(l.padding),document.body.style.marginRight=typeof l.margin==`number`?`${l.margin}px`:String(l.margin),document.documentElement.style.setProperty(`--scrollbar-width`,`${s}px`),document.body.style.overflow=`hidden`),Bs&&(i=Ys(document,`touchmove`,e=>hc(e),{passive:!1})),zn(()=>{n.value&&(ac(document,dc),document.body.style.overflow=`hidden`)})},{immediate:!0,flush:`sync`}),e});function pc(e){let t=Math.random().toString(36).substring(2,7),n=fc();n.value.set(t,e??!1);let r=V({get:()=>n.value.get(t)??!1,set:e=>n.value.set(t,e)});return Gs(()=>{n.value.delete(t)}),r}function mc(e){let t=window.getComputedStyle(e);if(t.overflowX===`scroll`||t.overflowY===`scroll`||t.overflowX===`auto`&&e.clientWidth<e.scrollWidth||t.overflowY===`auto`&&e.clientHeight<e.scrollHeight)return!0;{let t=e.parentNode;return!(t instanceof Element)||t.tagName===`BODY`?!1:mc(t)}}function hc(e){let t=e||window.event,n=t.target;return n instanceof Element&&mc(n)?!1:t.touches.length>1||(t.preventDefault&&t.cancelable&&t.preventDefault(),!1)}function gc(e){let t=nc({dir:N(`ltr`)});return V(()=>e?.value||t.dir?.value||`ltr`)}function _c(e){let t=to(),n=t?.type.emits,r={};return n?.length||console.warn(`No emitted event found. Please check component: ${t?.type.__name}`),n?.forEach(t=>{r[re(A(t))]=(...n)=>e(t,...n)}),r}function vc(e){return V(()=>!un(e)||!!Js(e)?.closest(`form`))}function yc(){let e=to(),t=N(),n=V(()=>r());Yr(()=>{n.value!==r()&&ln(t)});function r(){return t.value&&`$el`in t.value&&[`#text`,`#comment`].includes(t.value.$el.nodeName)?t.value.$el.nextElementSibling:Js(t)}let i=Object.assign({},e.exposed),a={};for(let t in e.props)Object.defineProperty(a,t,{enumerable:!0,configurable:!0,get:()=>e.props[t]});if(Object.keys(i).length>0)for(let e in i)Object.defineProperty(a,e,{enumerable:!0,configurable:!0,get:()=>i[e]});Object.defineProperty(a,"$el",{enumerable:!0,configurable:!0,get:()=>e.vnode.el}),e.exposed=a;function o(n){if(t.value=n,n&&(Object.defineProperty(a,"$el",{enumerable:!0,configurable:!0,get:()=>n instanceof Element?n:n.$el}),!(n instanceof Element)&&!Object.hasOwn(n,`$el`))){let t=n.$.exposed,r=Object.assign({},a);for(let e in t)Object.defineProperty(r,e,{enumerable:!0,configurable:!0,get:()=>t[e]});e.exposed=r}}return{forwardRef:o,currentRef:t,currentElement:n}}function bc(){let e=to()?.vnode?.scopeId;return e?{[e]:``}:{}}var xc=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},Sc=new WeakMap,Cc=new WeakMap,wc={},Tc=0,Ec=function(e){return e&&(e.host||Ec(e.parentNode))},Dc=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=Ec(t);return n&&e.contains(n)?n:(console.error(`aria-hidden`,t,`in not contained inside`,e,`. Doing nothing`),null)}).filter(function(e){return!!e})},Oc=function(e,t,n,r){var i=Dc(t,Array.isArray(e)?e:[e]);wc[n]||(wc[n]=new WeakMap);var a=wc[n],o=[],s=new Set,c=new Set(i),l=function(e){e&&!s.has(e)&&(s.add(e),l(e.parentNode))};i.forEach(l);var u=function(e){e&&!c.has(e)&&Array.prototype.forEach.call(e.children,function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),i=t!==null&&t!==`false`,c=(Sc.get(e)||0)+1,l=(a.get(e)||0)+1;Sc.set(e,c),a.set(e,l),o.push(e),c===1&&i&&Cc.set(e,!0),l===1&&e.setAttribute(n,`true`),i||e.setAttribute(r,`true`)}catch(t){console.error(`aria-hidden: cannot operate on `,e,t)}})};return u(t),s.clear(),Tc++,function(){o.forEach(function(e){var t=Sc.get(e)-1,i=a.get(e)-1;Sc.set(e,t),a.set(e,i),t||(Cc.has(e)||e.removeAttribute(r),Cc.delete(e)),i||e.removeAttribute(n)}),Tc--,Tc||(Sc=new WeakMap,Sc=new WeakMap,Cc=new WeakMap,wc={})}},kc=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||xc(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),Oc(r,i,n,`aria-hidden`)):function(){return null}};function Ac(e){let t;cr(()=>Js(e),e=>{let n=!1;try{n=!!e?.closest(`[popover]:not(:popover-open)`)}catch{}e&&!n?t=kc(e):t&&t()}),Zr(()=>{t&&t()})}function jc(e,t=`reka`){if(e)return e;let n,r=nc({useId:void 0});return n=r.useId?r.useId():jr?.(),t?`${t}-${n}`:n}function Mc(e,t){let n=N(e);function r(e){return t[n.value][e]??n.value}return{state:n,dispatch:e=>{n.value=r(e)}}}function Nc(e,t){let n=N({}),r=N(`none`),i=N(e),a=e.value?`mounted`:`unmounted`,o,s=t.value?.ownerDocument.defaultView??qs,{state:c,dispatch:l}=Mc(a,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}}),u=e=>{if(Is){let n=new CustomEvent(e,{bubbles:!1,cancelable:!1});t.value?.dispatchEvent(n)}};cr(e,async(e,i)=>{let a=i!==e;if(await zn(),a){let a=r.value,o=Pc(t.value);e?(l(`MOUNT`),u(`enter`),o===`none`&&u(`after-enter`)):o===`none`||o===`undefined`||n.value?.display===`none`?(l(`UNMOUNT`),u(`leave`),u(`after-leave`)):i&&a!==o?(l(`ANIMATION_OUT`),u(`leave`)):(l(`UNMOUNT`),u(`after-leave`))}},{immediate:!0});let d=e=>{if(e.target!==t.value)return;let n=Pc(t.value),r=n.includes(CSS.escape(e.animationName)),a=c.value===`mounted`?`enter`:`leave`;if(r&&(u(`after-${a}`),l(`ANIMATION_END`),!i.value)){let e=t.value.style.animationFillMode;t.value.style.animationFillMode=`forwards`,o=s?.setTimeout(()=>{t.value?.style.animationFillMode===`forwards`&&(t.value.style.animationFillMode=e)})}n===`none`&&l(`ANIMATION_END`)},f=e=>{e.target===t.value&&(r.value=Pc(t.value))},p=cr(t,(e,t)=>{e?(n.value=getComputedStyle(e),e.addEventListener(`animationstart`,f),e.addEventListener(`animationcancel`,d),e.addEventListener(`animationend`,d)):(l(`ANIMATION_END`),o!==void 0&&s?.clearTimeout(o),t?.removeEventListener(`animationstart`,f),t?.removeEventListener(`animationcancel`,d),t?.removeEventListener(`animationend`,d))},{immediate:!0}),m=cr(c,()=>{let e=Pc(t.value);r.value=c.value===`mounted`?e:`none`});return Zr(()=>{p(),m(),t.value&&(t.value.removeEventListener(`animationstart`,f),t.value.removeEventListener(`animationcancel`,d),t.value.removeEventListener(`animationend`,d)),o!==void 0&&s?.clearTimeout(o)}),{isPresent:V(()=>[`mounted`,`unmountSuspended`].includes(c.value))}}function Pc(e){return e&&getComputedStyle(e).animationName||`none`}var Fc=I({name:`Presence`,props:{present:{type:Boolean,required:!0},forceMount:{type:Boolean}},slots:{},setup(e,{slots:t,expose:n}){let{present:r,forceMount:i}=hn(e),a=N(),{isPresent:o}=Nc(r,a);n({present:o});let s=t.default({present:o.value});s=tc(s||[]);let c=to();if(s&&s?.length>1){let e=c?.parent?.type.name?`<${c.parent.type.name} />`:`component`;throw Error([`Detected an invalid children for \`${e}\` for \`Presence\` component.`,``,"Note: Presence works similarly to `v-if` directly, but it waits for animation/transition to finished before unmounting. So it expect only one direct child of valid VNode type.",`You can apply a few solutions:`,["Provide a single child element so that `presence` directive attach correctly.",`Ensure the first child is an actual element instead of a raw text node or comment node.`].map(e=>` - ${e}`).join(`
|
|
2
|
+
`)].join(`
|
|
3
|
+
`))}return()=>i.value||r.value||o.value?vo(t.default({present:o.value})[0],{ref:e=>{let t=Js(e);return t?.hasAttribute===void 0||(t?.hasAttribute(`data-reka-popper-content-wrapper`)?a.value=t.firstElementChild:a.value=t),t}}):null}}),Ic=I({name:`PrimitiveSlot`,inheritAttrs:!1,setup(e,{attrs:t,slots:n}){return()=>{if(!n.default)return null;let e=tc(n.default()),r=e.findIndex(e=>e.type!==Ea);if(r===-1)return e;let i=e[r];delete i.props?.ref;let a=i.props?Ja(t,i.props):t,o=Va({...i,props:{}},a);return e.length===1?o:(e[r]=o,e)}}}),Lc=[`area`,`img`,`input`],Rc=I({name:`Primitive`,inheritAttrs:!1,props:{asChild:{type:Boolean,default:!1},as:{type:[String,Object],default:`div`}},setup(e,{attrs:t,slots:n}){let r=e.asChild?`template`:e.as;return typeof r==`string`&&Lc.includes(r)?()=>vo(r,t):r===`template`?()=>vo(Ic,t,{default:n.default}):()=>vo(e.as,t,{default:n.default})}});function zc(){let e=N();return{primitiveElement:e,currentElement:V(()=>[`#text`,`#comment`].includes(e.value?.$el.nodeName)?e.value?.$el.nextElementSibling:Js(e))}}var[Bc,Vc]=js(`DialogRoot`),Hc=I({inheritAttrs:!1,__name:`DialogRoot`,props:{open:{type:Boolean,required:!1,default:void 0},defaultOpen:{type:Boolean,required:!1,default:!1},modal:{type:Boolean,required:!1,default:!0},unmountOnHide:{type:Boolean,required:!1,default:!0}},emits:[`update:open`],setup(e,{emit:t}){let n=e,r=ec(n,`open`,t,{defaultValue:n.defaultOpen,passive:n.open===void 0}),i=N(),a=N(),{modal:o,unmountOnHide:s}=hn(n);return Vc({open:r,modal:o,unmountOnHide:s,openModal:()=>{r.value=!0},onOpenChange:e=>{r.value=e},onOpenToggle:()=>{r.value=!r.value},contentId:``,titleId:``,descriptionId:``,triggerElement:i,contentElement:a}),(e,t)=>ai(e.$slots,`default`,{open:P(r),close:()=>r.value=!1})}}),Uc=I({__name:`DialogClose`,props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:`button`}},setup(e){let t=e;yc();let n=Bc();return(r,i)=>(L(),R(P(Rc),Ja(t,{type:e.as===`button`?`button`:void 0,onClick:i[0]||=e=>P(n).onOpenChange(!1)}),{default:F(()=>[ai(r.$slots,`default`)]),_:3},16,[`type`]))}}),Wc=`dismissableLayer.pointerDownOutside`,Gc=`dismissableLayer.focusOutside`;function Kc(e){if(typeof e!=`object`||!e)return!1;let t=e.ownerDocument?.defaultView;return typeof Element<`u`&&e instanceof Element||!!t&&e instanceof t.Element}function qc(e,t){if(!Kc(t))return!1;if(e.contains(t))return!0;let n=t.closest(`[data-dismissable-layer]`),r=e.dataset.dismissableLayer===``?e:e.querySelector(`[data-dismissable-layer]`),i=Array.from(e.ownerDocument.querySelectorAll(`[data-dismissable-layer]`));return!!(n&&(r===n||i.indexOf(r)<i.indexOf(n)))}function Jc(e,t,n=!0){let r=N(!1),i=N(()=>{});return or(a=>{if(!Is||!un(n))return;let o=t?.value?.ownerDocument??globalThis.document,s=async n=>{let a=n.target;if(t?.value&&a){if(qc(t.value,a))o.removeEventListener(`click`,i.value),r.value=!1;else{if(n.target&&!r.value){let t={originalEvent:n};function r(){Ns(Wc,e,t)}n.pointerType===`touch`?(o.removeEventListener(`click`,i.value),i.value=r,o.addEventListener(`click`,i.value,{once:!0})):r()}else o.removeEventListener(`click`,i.value);r.value=!1}}},c=window.setTimeout(()=>{o.addEventListener(`pointerdown`,s)},0);a(()=>{window.clearTimeout(c),o.removeEventListener(`pointerdown`,s),o.removeEventListener(`click`,i.value)})}),{onPointerDownCapture:()=>{un(n)&&(r.value=!0)}}}function Yc(e,t,n=!0){let r=N(!1);return or(i=>{if(!Is||!un(n))return;let a=t?.value?.ownerDocument??globalThis.document,o=async n=>{if(!t?.value)return;await zn(),await zn();let i=n.target;t.value&&i&&!qc(t.value,i)&&n.target&&!r.value&&Ns(Gc,e,{originalEvent:n})};a.addEventListener(`focusin`,o),i(()=>a.removeEventListener(`focusin`,o))}),{onFocusCapture:()=>{un(n)&&(r.value=!0)},onBlurCapture:()=>{un(n)&&(r.value=!1)}}}var Xc=Gt({layersRoot:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Zc=I({__name:`DismissableLayer`,props:{disableOutsidePointerEvents:{type:Boolean,required:!1,default:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},present:{type:Boolean,required:!1,default:!0}},emits:[`escapeKeyDown`,`pointerDownOutside`,`focusOutside`,`interactOutside`,`dismiss`],setup(e,{emit:t}){let n=e,r=t,{forwardRef:i,currentElement:a}=yc(),o=V(()=>a.value?.ownerDocument??globalThis.document),s=V(()=>Xc.layersRoot),c=V(()=>a.value?Array.from(s.value).indexOf(a.value):-1),l=V(()=>Xc.layersWithOutsidePointerEventsDisabled.size>0),u=V(()=>{let e=Array.from(s.value),[t]=[...Xc.layersWithOutsidePointerEventsDisabled].slice(-1),n=e.indexOf(t);return c.value>=n}),d=Jc(async e=>{let t=[...Xc.branches].some(t=>t?.contains(e.target));n.present&&u.value&&!t&&(r(`pointerDownOutside`,e),r(`interactOutside`,e),await zn(),e.defaultPrevented||r(`dismiss`))},a,()=>n.present),f=Yc(e=>{let t=[...Xc.branches].some(t=>t?.contains(e.target));n.present&&!t&&(r(`focusOutside`,e),r(`interactOutside`,e),e.defaultPrevented||r(`dismiss`))},a);return Qs(`Escape`,e=>{n.present&&c.value===s.value.size-1&&(r(`escapeKeyDown`,e),e.defaultPrevented||r(`dismiss`))},{target:()=>o.value?.defaultView??globalThis.window}),cr([a,()=>n.disableOutsidePointerEvents,()=>n.present],([e,t,n],r,i)=>{if(e&&n&&t){let t=e.ownerDocument;ac(t,e),Xc.layersWithOutsidePointerEventsDisabled.add(e),i(()=>{Xc.layersWithOutsidePointerEventsDisabled.delete(e),oc(t,e)})}},{immediate:!0}),cr([a,()=>n.present],([e,t],n,r)=>{e&&t&&(s.value.add(e),r(()=>{s.value.delete(e)}))},{immediate:!0}),or(e=>{e(()=>{a.value&&(s.value.delete(a.value),Xc.layersWithOutsidePointerEventsDisabled.delete(a.value))})}),(t,n)=>(L(),R(P(Rc),{ref:P(i),"as-child":e.asChild,as:e.as,"data-dismissable-layer":``,style:le({pointerEvents:l.value?u.value?`auto`:`none`:void 0}),onFocusCapture:P(f).onFocusCapture,onBlurCapture:P(f).onBlurCapture,onPointerdownCapture:P(d).onPointerDownCapture},{default:F(()=>[ai(t.$slots,`default`)]),_:3},8,[`as-child`,`as`,`style`,`onFocusCapture`,`onBlurCapture`,`onPointerdownCapture`]))}}),Qc=Fs(()=>N([]));function $c(){let e=Qc();return{add(t){let n=e.value[0];t!==n&&n?.pause(),e.value=el(e.value,t),e.value.unshift(t)},remove(t){e.value=el(e.value,t),e.value[0]?.resume()}}}function el(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}var tl=`focusScope.autoFocusOnMount`,nl=`focusScope.autoFocusOnUnmount`,rl={bubbles:!1,cancelable:!0};function il(e,t){let n=t;for(;n;){if(e.contains(n))return!0;n=n.getRootNode().host??null}return!1}function al(e,{select:t=!1}={}){let n=Ms();for(let r of e)if(dl(r,{select:t}),Ms()!==n)return!0}function ol(e){let t=sl(e);return[cl(t,e),cl(t.reverse(),e)]}function sl(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t=e.tagName===`INPUT`&&e.type===`hidden`;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t.sort((e,t)=>e.tabIndex===t.tabIndex?0:e.tabIndex===0?1:t.tabIndex===0?-1:e.tabIndex-t.tabIndex)}function cl(e,t){for(let n of e)if(!ll(n,{upTo:t}))return n}function ll(e,{upTo:t}){if(getComputedStyle(e).visibility===`hidden`)return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display===`none`)return!0;e=e.parentElement}return!1}function ul(e){return e instanceof HTMLInputElement&&`select`in e}function dl(e,{select:t=!1}={}){if(e&&e.focus){let n=Ms();e.focus({preventScroll:!0}),e!==n&&ul(e)&&t&&e.select()}}var fl=I({__name:`FocusScope`,props:{loop:{type:Boolean,required:!1,default:!1},trapped:{type:Boolean,required:!1,default:!1},present:{type:Boolean,required:!1,default:!0},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:[`mountAutoFocus`,`unmountAutoFocus`],setup(e,{emit:t}){let n=e,r=t,{currentRef:i,currentElement:a}=yc(),o=N(null),s=$c(),c=Gt({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}});or(e=>{if(!Is)return;let t=a.value;if(!n.trapped)return;let r=t?.ownerDocument??document,i=t?t.getRootNode():r;function s(e){if(c.paused||!t)return;let n=e.target;t.contains(n)?o.value=n:dl(o.value,{select:!0})}function l(e){if(c.paused||!t)return;let n=e.relatedTarget;n!==null&&(t.contains(n)||dl(o.value,{select:!0}))}function u(e){let n=o.value;if(n===null||!e.some(e=>e.removedNodes.length>0))return;let r=Ms();r&&t.contains(r)||t.contains(n)||dl(t)}function d(e){if(c.paused||!t)return;let n=e.composedPath()[0];il(t,n)||dl(o.value,{select:!0})}i.addEventListener(`focusin`,s),i.addEventListener(`focusout`,l),i!==r&&r.addEventListener(`focusin`,d);let f=new MutationObserver(u);t&&f.observe(t,{childList:!0,subtree:!0}),e(()=>{i.removeEventListener(`focusin`,s),i.removeEventListener(`focusout`,l),i!==r&&r.removeEventListener(`focusin`,d),f.disconnect()})});function l(e,t){let n=new CustomEvent(tl,rl),i=e=>r(`mountAutoFocus`,e);e.addEventListener(tl,i),e.dispatchEvent(n),e.removeEventListener(tl,i),n.defaultPrevented||(al(sl(e),{select:!0}),Ms()===t&&dl(e))}or(async e=>{let t=a.value;if(await zn(),!t)return;n.present!==!1&&s.add(c);let i=Ms();!t.contains(i)&&n.present!==!1&&l(t,i),e(()=>{let e=new CustomEvent(nl,rl),n=e=>{r(`unmountAutoFocus`,e)};t.addEventListener(nl,n),t.dispatchEvent(e),t.setAttribute(`data-focus-scope-unmounting`,``),setTimeout(()=>{e.defaultPrevented||dl(i??document.body,{select:!0}),t.removeEventListener(nl,n),s.remove(c),t.removeAttribute(`data-focus-scope-unmounting`)},0)})}),cr(()=>n.present,async(e,t)=>{if(!Is)return;if(e===!1&&t===!0){s.remove(c);return}if(e!==!0||t!==!1)return;s.add(c),await zn();let n=a.value;if(!n)return;let r=Ms();n.contains(r)||l(n,r)});function u(e){if(!n.loop&&!n.trapped||c.paused)return;let t=e.key===`Tab`&&!e.altKey&&!e.ctrlKey&&!e.metaKey,r=Ms();if(t&&r){let t=e.currentTarget,[i,a]=ol(t);i&&a?!e.shiftKey&&r===a?(e.preventDefault(),n.loop&&dl(i,{select:!0})):e.shiftKey&&r===i&&(e.preventDefault(),n.loop&&dl(a,{select:!0})):r===t&&e.preventDefault()}}return(t,n)=>(L(),R(P(Rc),{ref_key:`currentRef`,ref:i,tabindex:`-1`,"as-child":e.asChild,as:e.as,onKeydown:u},{default:F(()=>[ai(t.$slots,`default`)]),_:3},8,[`as-child`,`as`]))}}),pl=[`Enter`,` `],ml=[`ArrowDown`,`PageUp`,`Home`],hl=[`ArrowUp`,`PageDown`,`End`];[...ml,...hl],[...pl],[...pl];function gl(e){return e?`open`:`closed`}var _l=I({__name:`DialogContentImpl`,props:{forceMount:{type:Boolean,required:!1},trapFocus:{type:Boolean,required:!1},disableOutsidePointerEvents:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},present:{type:Boolean,required:!1}},emits:[`escapeKeyDown`,`pointerDownOutside`,`focusOutside`,`interactOutside`,`openAutoFocus`,`closeAutoFocus`],setup(e,{emit:t}){let n=e,r=t,i=Bc(),{forwardRef:a,currentElement:o}=yc();return i.titleId||=jc(void 0,`reka-dialog-title`),i.descriptionId||=jc(void 0,`reka-dialog-description`),qr(()=>{i.contentElement=o,Ms()!==document.body&&(i.triggerElement.value=Ms())}),(t,o)=>(L(),R(P(fl),{"as-child":``,loop:``,trapped:n.trapFocus,present:n.present,onMountAutoFocus:o[5]||=e=>r(`openAutoFocus`,e),onUnmountAutoFocus:o[6]||=e=>r(`closeAutoFocus`,e)},{default:F(()=>[B(P(Zc),Ja({id:P(i).contentId,ref:P(a),as:e.as,"as-child":e.asChild,present:n.present,"disable-outside-pointer-events":e.disableOutsidePointerEvents,role:`dialog`,"aria-describedby":P(i).descriptionId,"aria-labelledby":P(i).titleId,"data-state":P(gl)(P(i).open.value)},t.$attrs,{onDismiss:o[0]||=e=>P(i).onOpenChange(!1),onEscapeKeyDown:o[1]||=e=>r(`escapeKeyDown`,e),onFocusOutside:o[2]||=e=>r(`focusOutside`,e),onInteractOutside:o[3]||=e=>r(`interactOutside`,e),onPointerDownOutside:o[4]||=e=>r(`pointerDownOutside`,e)}),{default:F(()=>[ai(t.$slots,`default`)]),_:3},16,[`id`,`as`,`as-child`,`present`,`disable-outside-pointer-events`,`aria-describedby`,`aria-labelledby`,`data-state`])]),_:3},8,[`trapped`,`present`]))}}),vl=I({__name:`DialogContentModal`,props:{forceMount:{type:Boolean,required:!1},trapFocus:{type:Boolean,required:!1},disableOutsidePointerEvents:{type:Boolean,required:!1,default:!0},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},present:{type:Boolean,required:!0}},emits:[`escapeKeyDown`,`pointerDownOutside`,`focusOutside`,`interactOutside`,`openAutoFocus`,`closeAutoFocus`],setup(e,{emit:t}){let n=e,r=t,i=Bc(),a=_c(r),{forwardRef:o,currentElement:s}=yc();Ac(V(()=>n.present?s.value:void 0));let c=V(()=>{let{present:e,...t}=n;return t});return cr(()=>n.present,(e,t)=>{!e&&t&&i.triggerElement.value?.focus()}),(t,r)=>(L(),R(_l,Ja({...c.value,...P(a)},{ref:P(o),present:e.present,"trap-focus":P(i).open.value,"disable-outside-pointer-events":n.disableOutsidePointerEvents,onCloseAutoFocus:r[0]||=e=>{e.defaultPrevented||(e.preventDefault(),P(i).triggerElement.value?.focus())},onPointerDownOutside:r[1]||=e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()},onFocusOutside:r[2]||=e=>{e.preventDefault()}}),{default:F(()=>[ai(t.$slots,`default`)]),_:3},16,[`present`,`trap-focus`,`disable-outside-pointer-events`]))}}),yl=I({__name:`DialogContentNonModal`,props:{forceMount:{type:Boolean,required:!1},trapFocus:{type:Boolean,required:!1},disableOutsidePointerEvents:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1},present:{type:Boolean,required:!0}},emits:[`escapeKeyDown`,`pointerDownOutside`,`focusOutside`,`interactOutside`,`openAutoFocus`,`closeAutoFocus`],setup(e,{emit:t}){let n=e,r=_c(t);yc();let i=Bc(),a=N(!1),o=N(!1),s=V(()=>{let{present:e,...t}=n;return t});return cr(()=>n.present,(e,t)=>{!e&&t&&(a.value||i.triggerElement.value?.focus(),a.value=!1,o.value=!1)}),(t,n)=>(L(),R(_l,Ja({...s.value,...P(r)},{present:e.present,"trap-focus":!1,"disable-outside-pointer-events":!1,onCloseAutoFocus:n[0]||=e=>{e.defaultPrevented||(a.value||P(i).triggerElement.value?.focus(),e.preventDefault()),a.value=!1,o.value=!1},onInteractOutside:n[1]||=e=>{e.defaultPrevented||(a.value=!0,e.detail.originalEvent.type===`pointerdown`&&(o.value=!0));let t=e.target;P(i).triggerElement.value?.contains(t)&&e.preventDefault(),e.detail.originalEvent.type===`focusin`&&o.value&&e.preventDefault()}}),{default:F(()=>[ai(t.$slots,`default`)]),_:3},16,[`present`]))}}),bl=I({__name:`DialogContent`,props:{forceMount:{type:Boolean,required:!1},disableOutsidePointerEvents:{type:Boolean,required:!1,default:void 0},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:[`escapeKeyDown`,`pointerDownOutside`,`focusOutside`,`interactOutside`,`openAutoFocus`,`closeAutoFocus`],setup(e,{emit:t}){let n=e,r=t,i=Bc(),a=_c(r),{forwardRef:o}=yc(),s=V(()=>n.forceMount||!i.unmountOnHide.value);return(t,r)=>(L(),R(P(Fc),{present:P(i).open.value,"force-mount":s.value},{default:F(({present:r})=>[P(i).modal.value?$n((L(),R(vl,Ja({key:0,ref:P(o),present:!s.value||r},{...n,...P(a),...t.$attrs}),{default:F(()=>[ai(t.$slots,`default`)]),_:3},16,[`present`])),[[Mo,e.forceMount||P(i).unmountOnHide.value||r]]):$n((L(),R(yl,Ja({key:1,ref:P(o),present:!s.value||r},{...n,...P(a),...t.$attrs}),{default:F(()=>[ai(t.$slots,`default`)]),_:3},16,[`present`])),[[Mo,e.forceMount||P(i).unmountOnHide.value||r]])]),_:3},8,[`present`,`force-mount`]))}}),xl=I({__name:`DialogOverlayImpl`,props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1},present:{type:Boolean,required:!1,default:!0}},setup(e){let t=e,n=Bc(),r=pc(t.present);return cr(()=>t.present,e=>r.value=e),yc(),(t,r)=>(L(),R(P(Rc),{as:e.as,"as-child":e.asChild,"data-state":P(n).open.value?`open`:`closed`,style:{"pointer-events":`auto`},onPointerdown:r[0]||=hs(()=>{},[`left`,`self`,`prevent`])},{default:F(()=>[ai(t.$slots,`default`)]),_:3},8,[`as`,`as-child`,`data-state`]))}}),Sl=I({__name:`DialogOverlay`,props:{forceMount:{type:Boolean,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},setup(e){let t=e,n=Bc(),{forwardRef:r}=yc(),i=V(()=>t.forceMount||!n.unmountOnHide.value);return(t,a)=>P(n)?.modal.value?(L(),R(P(Fc),{key:0,present:P(n).open.value,"force-mount":i.value},{default:F(({present:a})=>[$n(B(xl,Ja(t.$attrs,{ref:P(r),as:e.as,"as-child":e.asChild,present:!i.value||a}),{default:F(()=>[ai(t.$slots,`default`)]),_:3},16,[`as`,`as-child`,`present`]),[[Mo,e.forceMount||P(n).unmountOnHide.value||a]])]),_:3},8,[`present`,`force-mount`])):Wa(`v-if`,!0)}}),Cl=I({__name:`Teleport`,props:{to:{type:null,required:!1},disabled:{type:Boolean,required:!1},defer:{type:Boolean,required:!1},forceMount:{type:Boolean,required:!1}},setup(e){let t=e,n=nc({}),r=V(()=>t.to??n.teleportTo?.value??`body`),i=Xs();return(t,n)=>P(i)||e.forceMount?(L(),R(Cr,{key:0,to:r.value,disabled:e.disabled,defer:e.defer},[ai(t.$slots,`default`)],8,[`to`,`disabled`,`defer`])):Wa(`v-if`,!0)}}),wl=I({__name:`DialogPortal`,props:{to:{type:null,required:!1},disabled:{type:Boolean,required:!1},defer:{type:Boolean,required:!1},forceMount:{type:Boolean,required:!1}},setup(e){let t=e;return(e,n)=>(L(),R(P(Cl),me(Ba(t)),{default:F(()=>[ai(e.$slots,`default`)]),_:3},16))}}),Tl=I({__name:`DialogTitle`,props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:`h2`}},setup(e){let t=e,n=Bc();return yc(),(e,r)=>(L(),R(P(Rc),Ja(t,{id:P(n).titleId}),{default:F(()=>[ai(e.$slots,`default`)]),_:3},16,[`id`]))}}),El=I({__name:`DialogTrigger`,props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:`button`}},setup(e){let t=e,n=Bc(),{forwardRef:r,currentElement:i}=yc();return n.contentId||=jc(void 0,`reka-dialog-content`),qr(()=>{n.triggerElement.value=i.value}),(i,a)=>(L(),R(P(Rc),Ja(t,{ref:P(r),type:e.as===`button`?`button`:void 0,"aria-haspopup":`dialog`,"aria-expanded":P(n).open.value||!1,"aria-controls":P(n).open.value?P(n).contentId:void 0,"data-state":P(n).open.value?`open`:`closed`,onClick:P(n).onOpenToggle}),{default:F(()=>[ai(i.$slots,`default`)]),_:3},16,[`type`,`aria-expanded`,`aria-controls`,`data-state`,`onClick`]))}}),Dl=I({__name:`VisuallyHidden`,props:{feature:{type:String,required:!1,default:`focusable`},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:`span`}},setup(e){return(t,n)=>(L(),R(P(Rc),{as:e.as,"as-child":e.asChild,"aria-hidden":e.feature===`fully-hidden`?`true`:void 0,"data-hidden":e.feature===`fully-hidden`?``:void 0,tabindex:e.feature===`fully-hidden`?`-1`:void 0,style:{position:`absolute`,border:0,width:`1px`,height:`1px`,padding:0,margin:`-1px`,overflow:`hidden`,clip:`rect(0, 0, 0, 0)`,clipPath:`inset(50%)`,whiteSpace:`nowrap`,wordWrap:`normal`,top:`-1px`,left:`-1px`}},{default:F(()=>[ai(t.$slots,`default`)]),_:3},8,[`as`,`as-child`,`aria-hidden`,`data-hidden`,`tabindex`]))}}),Ol=I({inheritAttrs:!1,__name:`VisuallyHiddenInputBubble`,props:{name:{type:String,required:!0},value:{type:null,required:!0},checked:{type:Boolean,required:!1,default:void 0},required:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},feature:{type:String,required:!1,default:`fully-hidden`}},setup(e){let t=e,{primitiveElement:n,currentElement:r}=zc();return cr(V(()=>t.checked??t.value),(e,t)=>{if(!r.value)return;let n=r.value,i=window.HTMLInputElement.prototype,a=Object.getOwnPropertyDescriptor(i,`value`).set;if(a&&e!==t){let t=new Event(`input`,{bubbles:!0}),r=new Event(`change`,{bubbles:!0});a.call(n,e),n.dispatchEvent(t),n.dispatchEvent(r)}}),(e,r)=>(L(),R(Dl,Ja({ref_key:`primitiveElement`,ref:n},{...t,...e.$attrs},{as:`input`}),null,16))}}),kl=I({inheritAttrs:!1,__name:`VisuallyHiddenInput`,props:{name:{type:String,required:!0},value:{type:null,required:!0},checked:{type:Boolean,required:!1,default:void 0},required:{type:Boolean,required:!1},disabled:{type:Boolean,required:!1},feature:{type:String,required:!1,default:`fully-hidden`}},setup(e){let t=e,n=V(()=>typeof t.value==`object`&&Array.isArray(t.value)&&t.value.length===0&&t.required),r=V(()=>typeof t.value==`string`||typeof t.value==`number`||typeof t.value==`boolean`||t.value===null||t.value===void 0?[{name:t.name,value:t.value}]:typeof t.value==`object`&&Array.isArray(t.value)?t.value.flatMap((e,n)=>typeof e==`object`?Object.entries(e).map(([e,r])=>({name:`${t.name}[${n}][${e}]`,value:r})):{name:`${t.name}[${n}]`,value:e}):t.value!==null&&typeof t.value==`object`&&!Array.isArray(t.value)?Object.entries(t.value).map(([e,n])=>({name:`${t.name}[${e}]`,value:n})):[]);return(i,a)=>(L(),Pa(wa,null,[Wa(` We render single input if it's required `),n.value?(L(),R(Ol,Ja({key:e.name},{...t,...i.$attrs},{name:e.name,value:e.value}),null,16,[`name`,`value`])):(L(!0),Pa(wa,{key:1},ri(r.value,e=>(L(),R(Ol,Ja({key:e.name},{ref_for:!0},{...t,...i.$attrs},{name:e.name,value:e.value}),null,16,[`name`,`value`]))),128))],2112))}});function Al(e){let t=nc({nonce:N()});return V(()=>e?.value||t.nonce?.value)}function H(e,t=`Assertion failed!`){if(!e)throw console.error(t),Error(t)}function jl(e,t=document){return As?t instanceof HTMLElement&&t?.dataset?.panelGroupId===e?t:t.querySelector(`[data-panel-group][data-panel-group-id="${e}"]`)||null:null}function Ml(e,t=document){return As&&t.querySelector(`[data-panel-resize-handle-id="${e}"]`)||null}function Nl(e,t,n=document){return As?Pl(e,n).findIndex(e=>e.getAttribute(`data-panel-resize-handle-id`)===t)??null:null}function Pl(e,t=document){return As?Array.from(t.querySelectorAll(`[data-panel-resize-handle-id][data-panel-group-id="${e}"]`)):[]}function Fl(e,t,n,r=document){let i=Ml(t,r),a=Pl(e,r),o=i?a.indexOf(i):-1;return[n[o]?.id??null,n[o+1]?.id??null]}function Il(e){return e.type===`keydown`}function Ll(e){return e.type.startsWith(`mouse`)}function Rl(e){return e.type.startsWith(`touch`)}function zl(e){if(Ll(e))return{x:e.clientX,y:e.clientY};if(Rl(e)){let t=e.touches[0];if(t&&t.clientX&&t.clientY)return{x:t.clientX,y:t.clientY}}return{x:1/0,y:1/0}}function Bl(e,t){let n=e===`horizontal`,{x:r,y:i}=zl(t);return n?r:i}function Vl(e,t,n,r,i){let a=n===`horizontal`,o=Ml(t,i);H(o);let s=o.getAttribute(`data-panel-group-id`);H(s);let{initialCursorPosition:c}=r,l=Bl(n,e),u=jl(s,i);H(u);let d=u.getBoundingClientRect(),f=a?d.width:d.height;return(l-c)/f*100}function Hl(e,t,n,r,i,a){if(Il(e)){let t=n===`horizontal`,r=0;r=e.shiftKey?100:i??10;let a=0;switch(e.key){case`ArrowDown`:a=t?0:r;break;case`ArrowLeft`:a=t?-r:0;break;case`ArrowRight`:a=t?r:0;break;case`ArrowUp`:a=t?0:-r;break;case`End`:a=100;break;case`Home`:a=-100}return a}return r==null?0:Vl(e,t,n,r,a)}function Ul({layout:e,panelsArray:t,pivotIndices:n}){let r=0,i=100,a=0,o=0,s=n[0];return H(s!=null),t.forEach((e,t)=>{let{constraints:n}=e,{maxSize:c=100,minSize:l=0}=n;t===s?(r=l,i=c):(a+=l,o+=c)}),{valueMax:Math.min(i,100-a),valueMin:Math.max(r,100-o),valueNow:e[s]}}function Wl({panelDataArray:e}){let t=Array.from({length:e.length}),n=e.map(e=>e.constraints),r=0,i=100;for(let a=0;a<e.length;a++){let e=n[a];H(e);let{defaultSize:o}=e;o!=null&&(r++,t[a]=o,i-=o)}for(let a=0;a<e.length;a++){let o=n[a];H(o);let{defaultSize:s}=o;if(s!=null)continue;let c=e.length-r,l=i/c;r++,t[a]=l,i-=l}return t}function Gl(e,t,n=10){e=Number.parseFloat(e.toFixed(n)),t=Number.parseFloat(t.toFixed(n));let r=e-t;return r===0?0:r>0?1:-1}function Kl(e,t,n){return Gl(e,t,n)===0}function ql(e,t,n,r){t.forEach((t,i)=>{let a=e[i];H(a);let{callbacks:o,constraints:s,id:c}=a,{collapsedSize:l=0,collapsible:u,sizeUnit:d}=s,f=t;d===`px`&&r!=null&&(f=t/100*r);let p=n[c];if(p==null||!Kl(f,p)){n[c]=f;let{onCollapse:e,onExpand:t,onResize:r}=o;r&&r(f,p),u&&(e||t)&&(t&&(p==null||Kl(p,l))&&!Kl(f,l)&&t(),e&&(p==null||!Kl(p,l))&&Kl(f,l)&&e())}})}function Jl(e,t=10){let n=null;return(...r)=>{n!==null&&clearTimeout(n),n=setTimeout(()=>{e(...r)},t)}}function Yl({panelConstraints:e,panelIndex:t,size:n}){let r=e[t];H(r!=null);let{collapsedSize:i=0,collapsible:a,maxSize:o=100,minSize:s=0}=r;if(Gl(n,s)<0){if(a){let e=(i+s)/2;n=Gl(n,e)<0?i:s}else n=s}return n=Math.min(o,n),n=Number.parseFloat(n.toFixed(10)),n}function Xl(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}function Zl({delta:e,layout:t,panelConstraints:n,pivotIndices:r,trigger:i}){if(Kl(e,0))return t;let a=[...t],[o,s]=r;H(o!=null),H(s!=null);let c=0;if(i===`keyboard`){{let r=e<0?s:o,i=n[r];if(H(i),i.collapsible){let i=t[r];H(i!=null);let a=n[r];H(a);let{collapsedSize:o=0,minSize:s=0}=a;if(Kl(i,o)){let t=s-i;Gl(t,Math.abs(e))>0&&(e=e<0?0-t:t)}}}{let r=e<0?o:s,i=n[r];H(i);let{collapsible:a}=i;if(a){let i=t[r];H(i!=null);let a=n[r];H(a);let{collapsedSize:o=0,minSize:s=0}=a;if(Kl(i,s)){let t=i-o;Gl(t,Math.abs(e))>0&&(e=e<0?0-t:t)}}}}{let r=e<0?1:-1,i=e<0?s:o,a=0;for(;;){let e=t[i];H(e!=null);let o=Yl({panelConstraints:n,panelIndex:i,size:100})-e;if(a+=o,i+=r,i<0||i>=n.length)break}let c=Math.min(Math.abs(e),Math.abs(a));e=e<0?0-c:c}{let r=e<0?o:s;for(;r>=0&&r<n.length;){let i=Math.abs(e)-Math.abs(c),o=t[r];H(o!=null);let s=o-i,l=Yl({panelConstraints:n,panelIndex:r,size:s});if(!Kl(o,l)&&(c+=o-l,a[r]=l,c.toPrecision(3).localeCompare(Math.abs(e).toPrecision(3),void 0,{numeric:!0})>=0))break;e<0?r--:r++}}if(Kl(c,0))return t;{let r=e<0?s:o,i=t[r];H(i!=null);let l=i+c,u=Yl({panelConstraints:n,panelIndex:r,size:l});if(a[r]=u,!Kl(u,l)){let t=l-u,r=e<0?s:o;for(;r>=0&&r<n.length;){let i=a[r];H(i!=null);let o=i+t,s=Yl({panelConstraints:n,panelIndex:r,size:o});if(Kl(i,s)||(t-=s-i,a[r]=s),Kl(t,0))break;e>0?r--:r++}}}return Kl(a.reduce((e,t)=>t+e,0),100)?a:t}function Ql(e,t,n){let r=Nl(e,t,n);return r==null?[-1,-1]:[r,r+1]}function $l(e,t,n){return n?e.x<t.x+t.width&&e.x+e.width>t.x&&e.y<t.y+t.height&&e.y+e.height>t.y:e.x<=t.x+t.width&&e.x+e.width>=t.x&&e.y<=t.y+t.height&&e.y+e.height>=t.y}function eu(e,t){if(e===t)throw Error(`Cannot compare node with itself`);let n={a:ou(e),b:ou(t)},r;for(;n.a.at(-1)===n.b.at(-1);)e=n.a.pop(),t=n.b.pop(),r=e;H(r);let i={a:au(iu(n.a)),b:au(iu(n.b))};if(i.a===i.b){let e=r.childNodes,t={a:n.a.at(-1),b:n.b.at(-1)},i=e.length;for(;i--;){let n=e[i];if(n===t.a)return 1;if(n===t.b)return-1}}return Math.sign(i.a-i.b)}var tu=/\b(?:position|zIndex|opacity|transform|webkitTransform|mixBlendMode|filter|webkitFilter|isolation)\b/;function nu(e){let t=getComputedStyle(su(e)).display;return t===`flex`||t===`inline-flex`}function ru(e){let t=getComputedStyle(e);return!!(t.position===`fixed`||t.zIndex!==`auto`&&(t.position!==`static`||nu(e))||+t.opacity<1||`transform`in t&&t.transform!==`none`||`webkitTransform`in t&&t.webkitTransform!==`none`||`mixBlendMode`in t&&t.mixBlendMode!==`normal`||`filter`in t&&t.filter!==`none`||`webkitFilter`in t&&t.webkitFilter!==`none`||`isolation`in t&&t.isolation===`isolate`||tu.test(t.willChange)||t.webkitOverflowScrolling===`touch`)}function iu(e){let t=e.length;for(;t--;){let n=e[t];if(H(n),ru(n))return n}return null}function au(e){return e&&Number(getComputedStyle(e).zIndex)||0}function ou(e){let t=[];for(;e;)t.push(e),e=su(e);return t}function su(e){return e.parentNode instanceof DocumentFragment&&e.parentNode?.host||e.parentNode}function cu(){if(typeof matchMedia==`function`)return matchMedia(`(pointer:coarse)`).matches?`coarse`:`fine`}var lu=cu()===`coarse`,uu=[],du=!1,fu=new Map,pu=new Map,mu=new Set;function hu(e,t,n,r,i,a){let{ownerDocument:o}=t,s={direction:n,element:t,hitAreaMargins:r,nonce:i,setResizeHandlerState:a},c=fu.get(o)??0;return fu.set(o,c+1),mu.add(s),wu(),function(){pu.delete(e),mu.delete(s);let t=fu.get(o)??1;fu.set(o,t-1),wu(),ku(),t===1&&fu.delete(o)}}function gu(e){let{target:t}=e,{x:n,y:r}=zl(e);du=!0,xu({target:t,x:n,y:r}),wu(),uu.length>0&&(Tu(`down`,e),e.preventDefault())}function _u(e){let{x:t,y:n}=zl(e);if(!du){let{target:r}=e;if(yu(r))return;xu({target:r,x:t,y:n})}Tu(`move`,e),Cu(),uu.length>0&&e.preventDefault()}function vu(e){!du&&yu(e.relatedTarget)&&(uu.splice(0),Tu(`move`,e),Cu())}function yu(e){return e!==null&&`tagName`in e&&e.tagName===`IFRAME`}function bu(e){let{target:t}=e,{x:n,y:r}=zl(e);pu.clear(),du=!1,uu.length>0&&e.preventDefault(),Tu(`up`,e),xu({target:t,x:n,y:r}),Cu(),wu()}function xu({target:e,x:t,y:n}){uu.splice(0);let r=null;e instanceof HTMLElement&&(r=e),mu.forEach(e=>{let{element:i,hitAreaMargins:a}=e,o=i.getBoundingClientRect(),{bottom:s,left:c,right:l,top:u}=o,d=lu?a.coarse:a.fine;if(t>=c-d&&t<=l+d&&n>=u-d&&n<=s+d){if(r!==null&&i!==r&&!i.contains(r)&&!r.contains(i)&&eu(r,i)>0){let e=r,t=!1;for(;e&&!e.contains(i);){if($l(e.getBoundingClientRect(),o,!0)){t=!0;break}e=e.parentElement}if(t)return}uu.push(e)}})}function Su(e,t){pu.set(e,t)}function Cu(){let e=!1,t=!1,n;uu.forEach(r=>{let{direction:i,nonce:a}=r;i.value===`horizontal`?e=!0:t=!0,n=a.value});let r=0;pu.forEach(e=>{r|=e}),e&&t?Au(`intersection`,r,n):e?Au(`horizontal`,r,n):t?Au(`vertical`,r,n):ku()}function wu(){fu.forEach((e,t)=>{let{body:n}=t;n.removeEventListener(`contextmenu`,bu),n.removeEventListener(`mousedown`,gu),n.removeEventListener(`mouseleave`,_u),n.removeEventListener(`mousemove`,_u),n.removeEventListener(`mouseout`,vu),n.removeEventListener(`touchmove`,_u),n.removeEventListener(`touchstart`,gu)}),window.removeEventListener(`mouseup`,bu),window.removeEventListener(`touchcancel`,bu),window.removeEventListener(`touchend`,bu),mu.size>0&&(du?(uu.length>0&&fu.forEach((e,t)=>{let{body:n}=t;e>0&&(n.addEventListener(`contextmenu`,bu),n.addEventListener(`mouseleave`,_u),n.addEventListener(`mousemove`,_u),n.addEventListener(`touchmove`,_u,{passive:!1}))}),window.addEventListener(`mouseup`,bu),window.addEventListener(`touchcancel`,bu),window.addEventListener(`touchend`,bu)):fu.forEach((e,t)=>{let{body:n}=t;e>0&&(n.addEventListener(`mousedown`,gu),n.addEventListener(`mousemove`,_u),n.addEventListener(`mouseout`,vu),n.addEventListener(`touchmove`,_u,{passive:!1}),n.addEventListener(`touchstart`,gu))}))}function Tu(e,t){mu.forEach(n=>{let{setResizeHandlerState:r}=n;r(e,uu.includes(n),t)})}var Eu=null,Du=null;function Ou(e,t){if(t){let e=!!(t&1),n=!!(t&2),r=!!(t&4),i=!!(t&8);if(e)return r?`se-resize`:i?`ne-resize`:`e-resize`;if(n)return r?`sw-resize`:i?`nw-resize`:`w-resize`;if(r)return`s-resize`;if(i)return`n-resize`}switch(e){case`horizontal`:return`ew-resize`;case`intersection`:return`move`;case`vertical`:return`ns-resize`}}function ku(){Du!==null&&(document.head.removeChild(Du),Eu=null,Du=null)}function Au(e,t,n){let r=Ou(e,t);Eu!==r&&(Eu=r,Du===null&&(Du=document.createElement(`style`),n&&(Du.nonce=n),document.head.appendChild(Du)),Du.textContent=`*{cursor: ${r}!important;}`)}function ju({defaultSize:e,dragState:t,layout:n,panelData:r,panelIndex:i,precision:a=3}){let o=n[i],s;return s=o==null?e===void 0?`1`:e.toPrecision(a):r.length===1?`1`:o.toPrecision(a),{flexBasis:0,flexGrow:s,flexShrink:1,overflow:`hidden`,pointerEvents:t===null?void 0:`none`}}function Mu({sizeUnit:e,groupSizeInPixels:t,value:n}){if(n==null||e===`%`)return n;if(t!=null&&t!==0)return n/t*100}function Nu({panelDataArray:e,groupSizeInPixels:t}){return e.some(e=>(e.constraints.sizeUnit??`%`)===`px`)&&(!t||Number.isNaN(t))?null:e.map(e=>{let n=e.constraints,r=n.sizeUnit??`%`,i=Mu({groupSizeInPixels:t,sizeUnit:r,value:n.collapsedSize}),a=Mu({groupSizeInPixels:t,sizeUnit:r,value:n.defaultSize}),o=Mu({groupSizeInPixels:t,sizeUnit:r,value:n.maxSize}),s=Mu({groupSizeInPixels:t,sizeUnit:r,value:n.minSize});return{...n,collapsedSize:i??n.collapsedSize??0,defaultSize:a,maxSize:o??100,minSize:s??0,sizeUnit:`%`}})}function Pu(e){return e.some(e=>(e.constraints.sizeUnit??`%`)===`px`)}function Fu({layout:e,panelDataArray:t,prevGroupSize:n,nextGroupSize:r}){if(!Pu(t)||n==null||r==null||n===0||r===0||Number.isNaN(n)||Number.isNaN(r))return null;let i=t.reduce((e,t,n)=>((t.constraints.sizeUnit??`%`)===`px`&&e.push(n),e),[]);if(i.length===0)return null;let a=new Set(i),o=e.map(e=>e??0);i.reduce((t,n)=>t+(e[n]??0),0);let s=i.map(t=>(e[t]??0)/100*n/r*100),c=s.reduce((e,t)=>e+t,0),l=e.reduce((e,t,n)=>a.has(n)?e:e+(t??0),0),u=Math.max(0,100-c),d=l>0?u/l:0;i.forEach((e,t)=>{o[e]=s[t]});for(let t=0;t<o.length;t++){if(a.has(t))continue;let n=e[t]??0;o[t]=n*d}let f=o.reduce((e,t)=>e+t,0);if(f>0&&Math.abs(f-100)>1e-9){let e=100/f;for(let t=0;t<o.length;t++)o[t]=(o[t]??0)*e}return o}function Iu({layout:e,panelConstraints:t}){let n=[...e];if(n.length===0&&t.length===0)return n;let r=n.reduce((e,t)=>e+t,0);if(n.length!==t.length)throw Error(`Invalid ${t.length} panel layout: ${n.map(e=>`${e}%`).join(`, `)}`);if(!Kl(r,100)){console.warn(`WARNING: Invalid layout total size: ${n.map(e=>`${e}%`).join(`, `)}. Layout normalization will be applied.`);for(let e=0;e<t.length;e++){let t=n[e];H(t!=null);let i=100/r*t;n[e]=i}}let i=0;for(let e=0;e<t.length;e++){let r=n[e];H(r!=null);let a=Yl({panelConstraints:t,panelIndex:e,size:r});r!==a&&(i+=r-a,n[e]=a)}if(!Kl(i,0))for(let e=0;e<t.length;e++){let r=n[e];H(r!=null);let a=r+i,o=Yl({panelConstraints:t,panelIndex:e,size:a});if(r!==o&&(i-=o-r,n[e]=o,Kl(i,0)))break}return n}function Lu({eagerValuesRef:e,groupId:t,layout:n,panelDataArray:r,panelGroupElement:i,setLayout:a,getPanelDataWithPercentConstraints:o}){or(e=>{let r=i.value;if(!r)return;let a=o();if(!a)return;let s=Pl(t,r);for(let e=0;e<a.length-1;e++){let{valueMax:t,valueMin:r,valueNow:i}=Ul({layout:n.value,panelsArray:a,pivotIndices:[e,e+1]}),o=s[e];if(o!=null){let n=a[e];H(n),o.setAttribute(`aria-controls`,n.id),o.setAttribute(`aria-valuemax`,`${Math.round(t)}`),o.setAttribute(`aria-valuemin`,`${Math.round(r)}`),o.setAttribute(`aria-valuenow`,i==null?``:`${Math.round(i)}`)}}e(()=>{s.forEach(e=>{e.removeAttribute(`aria-controls`),e.removeAttribute(`aria-valuemax`),e.removeAttribute(`aria-valuemin`),e.removeAttribute(`aria-valuenow`)})})}),or(r=>{let s=i.value;if(!s)return;let c=e.value;H(c);let l=o();if(!l)return;let{panelDataArray:u}=c;H(jl(t,s)!=null,`No group found for id "${t}"`);let d=Pl(t,s);H(d);let f=d.map(e=>{let r=e.getAttribute(`data-panel-resize-handle-id`);H(r);let[i,o]=Fl(t,r,u,s);if(i==null||o==null)return()=>{};let c=e=>{if(!e.defaultPrevented)switch(e.key){case`Enter`:{e.preventDefault();let o=l.findIndex(e=>e.id===i);if(o>=0){let e=l[o];H(e);let i=n.value[o],{collapsedSize:c=0,collapsible:u,minSize:d=0}=e.constraints;if(i!=null&&u){let e=Zl({delta:Kl(i,c)?d-c:c-i,layout:n.value,panelConstraints:l.map(e=>e.constraints),pivotIndices:Ql(t,r,s),trigger:`keyboard`});n.value!==e&&a(e)}}break}}};return e.addEventListener(`keydown`,c),()=>{e.removeEventListener(`keydown`,c)}});r(()=>{f.forEach(e=>e())})})}function Ru(e){try{if(typeof localStorage<`u`)e.getItem=e=>localStorage.getItem(e),e.setItem=(e,t)=>{localStorage.setItem(e,t)};else throw TypeError(`localStorage not supported in this environment`)}catch(t){console.error(t),e.getItem=()=>null,e.setItem=()=>{}}}function zu(e){return`reka:${e}`}function Bu(e){return e.map(e=>{let{constraints:t,id:n,idIsFromProps:r,order:i}=e;return r?n:i?`${i}:${JSON.stringify(t)}`:JSON.stringify(t)}).sort((e,t)=>e.localeCompare(t)).join(`,`)}function Vu(e,t){try{let n=zu(e),r=t.getItem(n);if(r){let e=JSON.parse(r);if(typeof e==`object`&&e)return e}}catch{}return null}function Hu(e,t,n){return(Vu(e,n)??{})[Bu(t)]??null}function Uu(e,t,n,r,i){let a=zu(e),o=Bu(t),s=Vu(e,i)??{},c={};t.forEach((e,t)=>{(e.constraints.sizeUnit??`%`)===`px`&&(c[t]=`px`)}),s[o]={expandToSizes:Object.fromEntries(n.entries()),layout:r,...Object.keys(c).length>0&&{sizeUnits:c}};try{i.setItem(a,JSON.stringify(s))}catch(e){console.error(e)}}var Wu=100,Gu={getItem:e=>(Ru(Gu),Gu.getItem(e)),setItem:(e,t)=>{Ru(Gu),Gu.setItem(e,t)}},[Ku,qu]=js(`PanelGroup`),Ju=I({__name:`SplitterGroup`,props:{id:{type:[String,null],required:!1},autoSaveId:{type:[String,null],required:!1,default:null},direction:{type:String,required:!0},keyboardResizeBy:{type:[Number,null],required:!1,default:10},storage:{type:Object,required:!1,default:()=>Gu},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:[`layout`],setup(e,{emit:t}){let n=e,r=t,i={},{direction:a}=hn(n),o=jc(n.id,`reka-splitter-group`),s=gc(),{forwardRef:c,currentElement:l}=yc(),u=N(null),d=N(null),f=N(null),p=N([]),m=N({}),h=N(new Map),g=N(0),_=V(()=>({autoSaveId:n.autoSaveId,direction:n.direction,dragState:u.value,id:o,keyboardResizeBy:n.keyboardResizeBy,storage:n.storage})),v=N({layout:p.value,panelDataArray:[],panelDataArrayChanged:!1});function y(){if(d.value!=null)return d.value;let e=l.value;if(e&&e instanceof HTMLElement){let t=e.getBoundingClientRect(),n=a.value===`horizontal`?t.width:t.height;if(!Number.isNaN(n))return d.value=n,n}return null}function b(e){let t=e??y();return Nu({panelDataArray:v.value.panelDataArray,groupSizeInPixels:t})}function x(e){let t=b(e);return t?v.value.panelDataArray.map((e,n)=>({...e,constraints:t[n]})):null}let S=e=>p.value=e;function C(e){let{panelDataArray:t}=v.value,n=y();return e.map((e,r)=>{let i=t[r];return i&&(i.constraints.sizeUnit??`%`)===`px`&&n!=null?e/100*n:e})}Lu({eagerValuesRef:v,groupId:o,layout:p,panelDataArray:v.value.panelDataArray,setLayout:S,panelGroupElement:l,getPanelDataWithPercentConstraints:x}),or(e=>{let t=l.value;if(!t||typeof ResizeObserver!=`function`)return;let n=new ResizeObserver(e=>{let t=e[0];if(!t)return;let{height:n,width:r}=t.contentRect,i=a.value===`horizontal`?r:n;Number.isNaN(i)||(d.value=i)});t instanceof HTMLElement&&n.observe(t),e(()=>n.disconnect())}),or(()=>{let{panelDataArray:e}=v.value,{autoSaveId:t}=n;if(t){if(p.value.length===0||p.value.length!==e.length)return;let r=i[t];r||(r=Jl(Uu,Wu),i[t]=r);let a=[...e],o=new Map(h.value);r(t,a,o,p.value,n.storage)}});function w(e,t){let{panelDataArray:n}=v.value,r=ae(n,e);return ju({defaultSize:t,dragState:u.value,layout:p.value,panelData:n,panelIndex:r})}function T(e){let{panelDataArray:t}=v.value;t.push(e),t.sort((e,t)=>{let n=e.order,r=t.order;return n==null&&r==null?0:n==null?-1:r==null?1:n-r}),v.value.panelDataArrayChanged=!0}cr(()=>v.value.panelDataArrayChanged,()=>{if(v.value.panelDataArrayChanged){v.value.panelDataArrayChanged=!1;let{autoSaveId:e,storage:t}=_.value,{layout:n,panelDataArray:i}=v.value,a=null;if(e){let n=Hu(e,i,t);n&&(h.value=new Map(Object.entries(n.expandToSizes)),a=n.layout)}if(a===null){let e=x();if(!e)return;a=Wl({panelDataArray:e})}let o=b();if(!o)return;let s=Iu({layout:a,panelConstraints:o});f.value=y(),ks(n,s)||(S(s),v.value.layout=s,r(`layout`,C(s)),ql(i,s,m.value,y()))}}),cr(d,(e,t)=>{if(t==null||e==null)return;let{layout:n,panelDataArray:i}=v.value;if(n.length===0||!Pu(i))return;let a=f.value;if(a!=null&&a>0&&a<50&&e>a*10){v.value.panelDataArrayChanged=!0;return}let o=Fu({layout:n,panelDataArray:i,prevGroupSize:t,nextGroupSize:e});if(!o)return;let s=b(e);if(!s)return;let c=Iu({layout:o,panelConstraints:s});Xl(n,c)||(S(c),v.value.layout=c,r(`layout`,C(c)),ql(i,c,m.value,y()))});function E(e){return function(t){t.preventDefault();let n=l.value;if(!n)return()=>null;let{direction:i,dragState:a,id:o,keyboardResizeBy:c}=_.value,{layout:u,panelDataArray:d}=v.value,{initialLayout:f}=a??{},p=Ql(o,e,n),h=Hl(t,e,i,a,c,n);if(h===0)return;let x=i===`horizontal`;s.value===`rtl`&&x&&(h=-h);let w=b();if(!w)return;let T=Zl({delta:h,layout:f??u,panelConstraints:w,pivotIndices:p,trigger:Il(t)?`keyboard`:`mouse-or-touch`}),E=!Xl(u,T);(Ll(t)||Rl(t))&&g.value!==h&&(g.value=h,E?Su(e,0):x?Su(e,h<0?1:2):Su(e,h<0?4:8)),E&&(S(T),v.value.layout=T,r(`layout`,C(T)),ql(d,T,m.value,y()))}}function D(e,t){let{layout:n,panelDataArray:i}=v.value,a=b();if(!a)return;let o=ae(i,e),s=e.constraints.sizeUnit??`%`,c=t;if(s===`px`){let e=y();e!=null&&(c=t/e*100)}let{panelSize:l,pivotIndices:u}=oe(i,e,n,a);H(l!=null);let d=Zl({delta:o===i.length-1?l-c:c-l,layout:n,panelConstraints:a,pivotIndices:u,trigger:`imperative-api`});Xl(n,d)||(S(d),v.value.layout=d,r(`layout`,C(d)),ql(i,d,m.value,y()))}function O(e,t){let{layout:n,panelDataArray:r}=v.value,i=ae(r,e);r[i]=e,v.value.panelDataArrayChanged=!0;let a=b();if(!a)return;let o=a[i],{panelSize:s}=oe(r,e,n,a);if(s===null)return;let c=o?.collapsedSize??0,l=o?.maxSize??100,u=o?.minSize??0;o?.collapsible&&j(e)?s!==c&&D(e,c):s<u?D(e,u):s>l&&D(e,l)}function k(e,t){let{direction:n}=_.value,{layout:r}=v.value;if(!l.value)return;let i=Ml(e,l.value);H(i);let a=Bl(n,t);u.value={dragHandleId:e,dragHandleRect:i.getBoundingClientRect(),initialCursorPosition:a,initialLayout:r}}function A(){u.value=null}function ee(e){let{panelDataArray:t}=v.value,n=ae(t,e);n>=0&&(t.splice(n,1),delete m.value[e.id],v.value.panelDataArrayChanged=!0)}function te(e){let{layout:t,panelDataArray:n}=v.value;if(e.constraints.collapsible){let i=b();if(!i)return;let{collapsedSize:a=0,panelSize:o,pivotIndices:s}=oe(n,e,t,i);if(H(o!=null,`Panel size not found for panel "${e.id}"`),o!==a){let c=e.constraints.sizeUnit??`%`,l=d.value??y(),u=c===`px`&&l?o/100*l:o;h.value.set(e.id,u);let f=Zl({delta:ae(n,e)===n.length-1?o-a:a-o,layout:t,panelConstraints:i,pivotIndices:s,trigger:`imperative-api`});Xl(t,f)||(S(f),v.value.layout=f,r(`layout`,C(f)),ql(n,f,m.value,y()))}}}function ne(e){let{layout:t,panelDataArray:n}=v.value;if(e.constraints.collapsible){let i=b();if(!i)return;let{collapsedSize:a=0,panelSize:o=0,minSize:s=0,pivotIndices:c}=oe(n,e,t,i);if(Gl(o,a)<=0){let a=h.value.get(e.id),l=e.constraints.sizeUnit??`%`,u=d.value??y(),f=l===`px`&&u?a==null?null:a/u*100:a,p=f!=null&&f>=s?f:s,g=Zl({delta:ae(n,e)===n.length-1?o-p:p-o,layout:t,panelConstraints:i,pivotIndices:c,trigger:`imperative-api`});Xl(t,g)||(S(g),v.value.layout=g,r(`layout`,C(g)),ql(n,g,m.value,y()))}}}function re(e){let{layout:t,panelDataArray:n}=v.value,{panelSize:r}=oe(n,e,t);if(H(r!=null,`Panel size not found for panel "${e.id}"`),(e.constraints.sizeUnit??`%`)===`px`){let e=y();if(e!=null)return r/100*e}return r}function j(e){let{layout:t,panelDataArray:n}=v.value,r=b(),{collapsedSize:i=0,collapsible:a,panelSize:o}=oe(n,e,t,r??void 0);if(!a)return!1;if(o===void 0){let t=ae(n,e),i=r?.[t]??e.constraints;return i.defaultSize===i.collapsedSize}return Gl(o,i)<=0}function ie(e){let{layout:t,panelDataArray:n}=v.value,{collapsedSize:r=0,collapsible:i,panelSize:a}=oe(n,e,t,b()??void 0);return H(a!=null,`Panel size not found for panel "${e.id}"`),!i||Gl(a,r)>0}qu({direction:a,dragState:u.value,groupId:o,reevaluatePanelConstraints:O,registerPanel:T,registerResizeHandle:E,resizePanel:D,startDragging:k,stopDragging:A,unregisterPanel:ee,panelGroupElement:l,collapsePanel:te,expandPanel:ne,isPanelCollapsed:j,isPanelExpanded:ie,getPanelSize:re,getPanelStyle:w});function ae(e,t){return e.findIndex(e=>e===t||e.id===t.id)}function oe(e,t,n,r){let i=ae(e,t),a=i===e.length-1?[i-1,i]:[i,i+1],o=(r??b())?.[i],s=n[i];return{...o??t.constraints,panelSize:s,pivotIndices:a}}return(t,n)=>(L(),R(P(Rc),{ref:P(c),as:e.as,"as-child":e.asChild,style:le({display:`flex`,flexDirection:P(a)===`horizontal`?`row`:`column`,height:`100%`,overflow:`hidden`,width:`100%`}),"data-panel-group":``,"data-orientation":P(a),"data-panel-group-id":P(o)},{default:F(()=>[ai(t.$slots,`default`,{layout:p.value})]),_:3},8,[`as`,`as-child`,`style`,`data-orientation`,`data-panel-group-id`]))}}),Yu=I({__name:`SplitterPanel`,props:{collapsedSize:{type:Number,required:!1},collapsible:{type:Boolean,required:!1},defaultSize:{type:Number,required:!1},id:{type:String,required:!1},maxSize:{type:Number,required:!1},minSize:{type:Number,required:!1},order:{type:Number,required:!1},sizeUnit:{type:String,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:[`collapse`,`expand`,`resize`],setup(e,{expose:t,emit:n}){let r=e,i=n,a=Ku();if(a===null)throw Error(`SplitterPanel components must be rendered within a SplitterGroup container`);let{collapsePanel:o,expandPanel:s,getPanelSize:c,getPanelStyle:l,isPanelCollapsed:u,resizePanel:d,groupId:f,reevaluatePanelConstraints:p,registerPanel:m,unregisterPanel:h}=a,g=jc(r.id,`reka-splitter-panel`),_=V(()=>({callbacks:{onCollapse:()=>i(`collapse`),onExpand:()=>i(`expand`),onResize:(...e)=>i(`resize`,...e)},constraints:{collapsedSize:r.collapsedSize&&Number.parseFloat(r.collapsedSize.toFixed(10)),collapsible:r.collapsible,defaultSize:r.defaultSize,maxSize:r.maxSize,minSize:r.minSize,sizeUnit:r.sizeUnit??`%`},id:g,idIsFromProps:r.id!==void 0,order:r.order}));cr(()=>_.value.constraints,(e,t)=>{(t.collapsedSize!==e.collapsedSize||t.collapsible!==e.collapsible||t.maxSize!==e.maxSize||t.minSize!==e.minSize||t.sizeUnit!==e.sizeUnit)&&p(_.value,t)},{deep:!0}),qr(()=>{m(_.value)}),Zr(()=>{h(_.value)});let v=V(()=>l(_.value,r.defaultSize)),y=V(()=>u(_.value)),b=V(()=>!y.value);function x(){o(_.value)}function S(){s(_.value)}function C(e){d(_.value,e)}return t({collapse:x,expand:S,getSize(){return c(_.value)},resize:C,isCollapsed:y,isExpanded:b}),(t,n)=>(L(),R(P(Rc),{id:P(g),style:le(v.value),as:e.as,"as-child":e.asChild,"data-panel":``,"data-panel-collapsible":e.collapsible||void 0,"data-panel-group-id":P(f),"data-panel-id":P(g),"data-panel-size":Number.parseFloat(`${v.value.flexGrow}`).toFixed(1),"data-state":e.collapsible?y.value?`collapsed`:`expanded`:void 0},{default:F(()=>[ai(t.$slots,`default`,{isCollapsed:y.value,isExpanded:b.value,expand:S,collapse:x,resize:C})]),_:3},8,[`id`,`style`,`as`,`as-child`,`data-panel-collapsible`,`data-panel-group-id`,`data-panel-id`,`data-panel-size`,`data-state`]))}});function Xu({disabled:e,handleId:t,resizeHandler:n,panelGroupElement:r}){or(i=>{let a=r.value;if(e.value||n.value===null||a===null)return;let o=Ml(t,a);if(o==null)return;let s=e=>{if(!e.defaultPrevented)switch(e.key){case`ArrowDown`:case`ArrowLeft`:case`ArrowRight`:case`ArrowUp`:case`End`:case`Home`:e.preventDefault(),n.value?.(e);break;case`F6`:{e.preventDefault();let n=o.getAttribute(`data-panel-group-id`);H(n);let r=Pl(n,a),i=Nl(n,t,a);H(i!==null),r[e.shiftKey?i>0?i-1:r.length-1:i+1<r.length?i+1:0].focus();break}}};o.addEventListener(`keydown`,s),i(()=>{o.removeEventListener(`keydown`,s)})})}var Zu=I({__name:`SplitterResizeHandle`,props:{id:{type:String,required:!1},hitAreaMargins:{type:Object,required:!1},tabindex:{type:Number,required:!1,default:0},disabled:{type:Boolean,required:!1},nonce:{type:String,required:!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1}},emits:[`dragging`],setup(e,{emit:t}){let n=e,r=t,{forwardRef:i,currentElement:a}=yc(),{disabled:o}=hn(n),s=Ku();if(s===null)throw Error(`PanelResizeHandle components must be rendered within a PanelGroup container`);let{direction:c,groupId:l,registerResizeHandle:u,startDragging:d,stopDragging:f,panelGroupElement:p}=s,m=jc(n.id,`reka-splitter-resize-handle`),h=N(`inactive`),g=N(!1),_=N(null),{nonce:v}=hn(n),y=Al(v);return cr(o,()=>{As&&(o.value?_.value=null:_.value=u(m))},{immediate:!0}),or(e=>{if(o.value||_.value===null)return;let t=a.value;t&&(H(t),e(hu(m,t,c,{coarse:n.hitAreaMargins?.coarse??15,fine:n.hitAreaMargins?.fine??5},y,(e,t,n)=>{if(t)switch(e){case`down`:h.value=`drag`,d(m,n),r(`dragging`,!0);break;case`move`:h.value!==`drag`&&(h.value=`hover`),_.value?.(n);break;case`up`:h.value=`hover`,f(),r(`dragging`,!1)}else h.value=`inactive`})))}),Xu({disabled:o,resizeHandler:_,handleId:m,panelGroupElement:p}),(t,n)=>(L(),R(P(Rc),{id:P(m),ref:P(i),style:{touchAction:`none`,userSelect:`none`},as:e.as,"as-child":e.asChild,role:`separator`,"data-resize-handle":``,tabindex:e.tabindex,"data-state":h.value,"data-disabled":P(o)?``:void 0,"data-orientation":P(c),"data-panel-group-id":P(l),"data-resize-handle-active":h.value===`drag`?`pointer`:g.value?`keyboard`:void 0,"data-resize-handle-state":h.value,"data-panel-resize-handle-enabled":!P(o),"data-panel-resize-handle-id":P(m),onBlur:n[0]||=e=>g.value=!1,onFocus:n[1]||=e=>g.value=!1},{default:F(()=>[ai(t.$slots,`default`)]),_:3},8,[`id`,`as`,`as-child`,`tabindex`,`data-state`,`data-disabled`,`data-orientation`,`data-panel-group-id`,`data-resize-handle-active`,`data-resize-handle-state`,`data-panel-resize-handle-enabled`,`data-panel-resize-handle-id`]))}}),[Qu,$u]=js(`SwitchRoot`),ed=I({inheritAttrs:!1,__name:`SwitchRoot`,props:{defaultValue:{type:null,required:!1},modelValue:{type:null,required:!1,default:void 0},disabled:{type:Boolean,required:!1},id:{type:String,required:!1},value:{type:String,required:!1,default:`on`},trueValue:{type:null,required:!1,default:()=>!0},falseValue:{type:null,required:!1,default:()=>!1},asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:`button`},name:{type:String,required:!1},required:{type:Boolean,required:!1}},emits:[`update:modelValue`],setup(e,{emit:t}){let n=e,r=t,{disabled:i}=hn(n),a=ec(n,`modelValue`,r,{defaultValue:n.defaultValue??n.falseValue,passive:n.modelValue===void 0}),o=V(()=>a.value===n.trueValue);function s(){i.value||(a.value=o.value?n.falseValue:n.trueValue)}let{forwardRef:c,currentElement:l}=yc(),u=vc(l),d=bc(),f=V(()=>n.id&&l.value?document.querySelector(`[for="${n.id}"]`)?.innerText:void 0);return $u({checked:o,toggleCheck:s,disabled:i}),(t,n)=>(L(),Pa(wa,null,[B(P(Rc),Ja({id:e.id,ref:P(c),role:`switch`,type:e.as===`button`?`button`:void 0,value:e.value,"aria-label":t.$attrs[`aria-label`]||f.value,"aria-checked":o.value,"aria-required":e.required,"data-state":o.value?`checked`:`unchecked`,"data-disabled":P(i)?``:void 0,"as-child":e.asChild,as:e.as,disabled:P(i)},{...P(d),...t.$attrs},{onClick:s,onKeydown:_s(hs(s,[`prevent`]),[`enter`])}),{default:F(()=>[ai(t.$slots,`default`,{modelValue:P(a),checked:o.value})]),_:3},16,[`id`,`type`,`value`,`aria-label`,`aria-checked`,`aria-required`,`data-state`,`data-disabled`,`as-child`,`as`,`disabled`,`onKeydown`]),P(u)&&e.name?(L(),R(P(kl),Ja({key:0,type:`checkbox`,name:e.name,disabled:P(i),required:e.required,value:e.value,checked:o.value},P(d)),null,16,[`name`,`disabled`,`required`,`value`,`checked`])):Wa(`v-if`,!0)],64))}}),td=I({__name:`SwitchThumb`,props:{asChild:{type:Boolean,required:!1},as:{type:null,required:!1,default:`span`}},setup(e){let t=Qu();return yc(),(n,r)=>(L(),R(P(Rc),{"data-state":P(t).checked.value?`checked`:`unchecked`,"data-disabled":P(t).disabled.value?``:void 0,"as-child":e.asChild,as:e.as},{default:F(()=>[ai(n.$slots,`default`)]),_:3},8,[`data-state`,`data-disabled`,`as-child`,`as`]))}}),nd=I({__name:`BaseSwitch`,props:{modelValue:{type:Boolean},modelModifiers:{}},emits:[`update:modelValue`],setup(e){let t=Mi(e,`modelValue`);return(e,n)=>(L(),R(P(ed),{modelValue:t.value,"onUpdate:modelValue":n[0]||=e=>t.value=e,class:`relative h-4 w-7 flex cursor-pointer border border-transparent rounded-full transition-colors data-[state=checked]:border-blue-600 data-[state=checked]:bg-blue-600 data-[state=unchecked]:bg-gray-300 dark:data-[state=unchecked]:bg-gray-600`},{default:F(()=>[B(P(td),{class:`my-auto h-3 w-3 translate-x-[2px] rounded-full bg-white shadow-sm transition-transform will-change-transform data-[state=checked]:translate-x-[14px]`})]),_:1},8,[`modelValue`]))}}),rd={class:`min-h-0 overflow-y-auto px-3 py-2.5 text-[13px] text-gray-700 dark:text-gray-300`},id=I({__name:`BaseDialog`,props:fi({title:{}},{open:{type:Boolean,default:!1},openModifiers:{}}),emits:[`update:open`],setup(e){let t=Mi(e,`open`);return(n,r)=>(L(),R(P(Hc),{open:t.value,"onUpdate:open":r[0]||=e=>t.value=e},{default:F(()=>[n.$slots.trigger?(L(),R(P(El),{key:0,"as-child":``},{default:F(()=>[ai(n.$slots,`trigger`)]),_:3})):Wa(``,!0),B(P(wl),null,{default:F(()=>[B(P(Sl),{class:`fixed inset-0 z-30 bg-black/50`}),B(P(bl),{"aria-describedby":void 0,class:`fixed left-[50%] top-[50%] z-30 max-h-[85vh] max-w-96 w-[90vw] flex flex-col translate-x-[-50%] translate-y-[-50%] overflow-hidden border border-gray-200 rounded-md bg-white text-gray-900 shadow-lg outline-none dark:border-gray-700 dark:bg-gray-800 dark:text-gray-100`},{default:F(()=>[B(P(Tl),{class:`flex flex-none items-center justify-between gap-2 border-b border-gray-200 px-3 py-2 text-[13px] font-semibold dark:border-gray-800`},{default:F(()=>[Ha(we(e.title)+` `,1),B(P(Uc),{class:`h-6 w-6 flex cursor-pointer items-center justify-center rounded text-gray-500 transition-colors -mr-1 hover:bg-gray-100 dark:text-gray-400 hover:text-gray-900 dark:hover:bg-gray-700 dark:hover:text-white`},{default:F(()=>[...r[1]||=[z(`span`,{class:`i-mdi:close`},null,-1)]]),_:1})]),_:1}),z(`div`,rd,[ai(n.$slots,`default`)])]),_:3})]),_:3})]),_:3},8,[`open`]))}}),ad=new WeakMap,od=(...e)=>{let t=e[0],n=to()?.proxy??Ae();if(n==null&&!rr())throw Error(`injectLocal must be called in setup`);return n&&ad.has(n)&&t in ad.get(n)?ad.get(n)[t]:nr(...e)},sd=typeof window<`u`&&typeof document<`u`;typeof WorkerGlobalScope<`u`&&globalThis instanceof WorkerGlobalScope;var cd=Object.prototype.toString,ld=e=>cd.call(e)===`[object Object]`,ud=()=>{},dd=fd();function fd(){var e,t;return sd&&!!((e=window)!=null&&(e=e.navigator)!=null&&e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window)==null||(t=t.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function pd(...e){if(e.length!==1)return vn(...e);let t=e[0];return typeof t==`function`?qt(mn(()=>({get:t,set:ud}))):N(t)}function md(e,t){function n(...n){return new Promise((r,i)=>{Promise.resolve(e(()=>t.apply(this,n),{fn:t,thisArg:this,args:n})).then(r).catch(i)})}return`cancel`in e&&Object.assign(n,{cancel:e.cancel,flush:e.flush,isPending:e.isPending}),n}var hd=e=>e();function gd(e=hd,t={}){let{initialState:n=`active`}=t,r=pd(n===`active`);function i(){r.value=!1}function a(){r.value=!0}return{isActive:Jt(r),pause:i,resume:a,eventFilter:(...t)=>{r.value&&e(...t)}}}function _d(e){return e.endsWith(`rem`)?Number.parseFloat(e)*16:Number.parseFloat(e)}function vd(e){return Array.isArray(e)?e:[e]}function yd(e){return e||to()}function bd(e,t,n={}){let{eventFilter:r=hd,...i}=n;return cr(e,md(r,t),i)}function xd(e,t,n={}){let{eventFilter:r,initialState:i=`active`,...a}=n,{eventFilter:o,pause:s,resume:c,isActive:l}=gd(r,{initialState:i});return{stop:bd(e,t,{...a,eventFilter:o}),pause:s,resume:c,isActive:l}}function Sd(e,t=!0,n){yd(n)?qr(e,n):t?e():zn(e)}function Cd(e,t,n){return cr(e,t,{...n,immediate:!0})}var wd=sd?window:void 0;sd&&window.document,sd&&window.navigator,sd&&window.location;function Td(e){let t=un(e);return t?.$el??t}function Ed(...e){let t=(e,t,n,r)=>(e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)),n=V(()=>{let t=vd(un(e[0])).filter(e=>e!=null);return t.every(e=>typeof e!=`string`)?t:void 0});return Cd(()=>[n.value?.map(e=>Td(e))??[wd].filter(e=>e!=null),vd(un(n.value?e[1]:e[0])),vd(P(n.value?e[2]:e[1])),un(n.value?e[3]:e[2])],([e,n,r,i],a,o)=>{if(!e?.length||!n?.length||!r?.length)return;let s=ld(i)?{...i}:i,c=e.flatMap(e=>n.flatMap(n=>r.map(r=>t(e,n,r,s))));o(()=>{c.forEach(e=>e())})},{flush:`post`})}var Dd=!1;function Od(e,t,n={}){let{window:r=wd,ignore:i=[],capture:a=!0,detectIframe:o=!1,controls:s=!1}=n;if(!r)return s?{stop:ud,cancel:ud,trigger:ud}:ud;if(dd&&!Dd){Dd=!0;let e={passive:!0};Array.from(r.document.body.children).forEach(t=>t.addEventListener(`click`,ud,e)),r.document.documentElement.addEventListener(`click`,ud,e)}let c=!0,l=e=>un(i).some(t=>{if(typeof t==`string`)return Array.from(r.document.querySelectorAll(t)).some(t=>t===e.target||e.composedPath().includes(t));{let n=Td(t);return n&&(e.target===n||e.composedPath().includes(n))}});function u(e){let t=un(e);return t&&t.$.subTree.shapeFlag===16}function d(e,t){let n=un(e),r=n.$.subTree&&n.$.subTree.children;return r==null||!Array.isArray(r)?!1:r.some(e=>e.el===t.target||t.composedPath().includes(e.el))}let f=n=>{let r=Td(e);n.target!=null&&(!(r instanceof Element)&&u(e)&&d(e,n)||r&&r!==n.target&&!n.composedPath().includes(r)&&(`detail`in n&&n.detail===0&&(c=!l(n)),c?t(n):c=!0))},p=!1,m=[Ed(r,`click`,e=>{p||(p=!0,setTimeout(()=>{p=!1},0),f(e))},{passive:!0,capture:a}),Ed(r,`pointerdown`,t=>{let n=Td(e);c=!l(t)&&!(!n||t.composedPath().includes(n))},{passive:!0}),o&&Ed(r,`blur`,n=>{setTimeout(()=>{let i=Td(e),a=r.document.activeElement;for(;a?.shadowRoot;)a=a.shadowRoot.activeElement;a?.tagName===`IFRAME`&&!i?.contains(r.document.activeElement)&&t(n)},0)},{passive:!0})].filter(Boolean),h=()=>m.forEach(e=>e());return s?{stop:h,cancel:()=>{c=!1},trigger:e=>{c=!0,f(e),c=!1}}:h}function kd(){let e=on(!1),t=to();return t&&qr(()=>{e.value=!0},t),e}function Ad(e){let t=kd();return V(()=>(t.value,!!e()))}var jd=Symbol(`vueuse-ssr-width`);function Md(){let e=rr()?od(jd,null):null;return typeof e==`number`?e:void 0}function Nd(e,t={}){let{window:n=wd,ssrWidth:r=Md()}=t,i=Ad(()=>n&&`matchMedia`in n&&typeof n.matchMedia==`function`),a=on(typeof r==`number`),o=on(),s=on(!1);return or(()=>{if(a.value){a.value=!i.value;let t=un(e).split(`,`);s.value=t.some(e=>{let t=e.includes(`not all`),n=e.match(/\(\s*min-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/),i=e.match(/\(\s*max-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/),a=!!(n||i);return n&&a&&(a=r>=_d(n[1])),i&&a&&(a=r<=_d(i[1])),t?!a:a})}else i.value&&(o.value=n.matchMedia(un(e)),s.value=o.value.matches)}),Ed(o,`change`,e=>{s.value=e.matches},{passive:!0}),V(()=>s.value)}var Pd=typeof globalThis<`u`?globalThis:typeof window<`u`?window:typeof global<`u`?global:typeof self<`u`?self:{},Fd=`__vueuse_ssr_handlers__`,Id=Ld();function Ld(){return Fd in Pd||(Pd[Fd]=Pd[Fd]||{}),Pd[Fd]}function Rd(e,t){return Id[e]||t}function zd(e){return Nd(`(prefers-color-scheme: dark)`,e)}function Bd(e){return e==null?`any`:e instanceof Set?`set`:e instanceof Map?`map`:e instanceof Date?`date`:typeof e==`boolean`?`boolean`:typeof e==`string`?`string`:typeof e==`object`?`object`:Number.isNaN(e)?`any`:`number`}var Vd={boolean:{read:e=>e===`true`,write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},Hd=`vueuse-storage`;function Ud(e,t,n,r={}){let{flush:i=`pre`,deep:a=!0,listenToStorageChanges:o=!0,writeDefaults:s=!0,mergeDefaults:c=!1,shallow:l,window:u=wd,eventFilter:d,onError:f=e=>{console.error(e)},initOnMounted:p}=r,m=(l?on:N)(typeof t==`function`?t():t),h=V(()=>un(e));if(!n)try{n=Rd(`getDefaultStorage`,()=>wd?.localStorage)()}catch(e){f(e)}if(!n)return m;let g=un(t),_=Bd(g),v=r.serializer??Vd[_],{pause:y,resume:b}=xd(m,e=>C(e),{flush:i,deep:a,eventFilter:d});cr(h,()=>T(),{flush:i});let x=!1;u&&o&&(n instanceof Storage?Ed(u,`storage`,e=>{(!p||x)&&T(e)},{passive:!0}):Ed(u,Hd,e=>{(!p||x)&&E(e)})),p?Sd(()=>{x=!0,T()}):T();function S(e,t){if(u){let r={key:h.value,oldValue:e,newValue:t,storageArea:n};u.dispatchEvent(n instanceof Storage?new StorageEvent(`storage`,r):new CustomEvent(Hd,{detail:r}))}}function C(e){try{let t=n.getItem(h.value);if(e==null)S(t,null),n.removeItem(h.value);else{let r=v.write(e);t!==r&&(n.setItem(h.value,r),S(t,r))}}catch(e){f(e)}}function w(e){let t=e?e.newValue:n.getItem(h.value);if(t==null)return s&&g!=null&&n.setItem(h.value,v.write(g)),g;if(!e&&c){let e=v.read(t);return typeof c==`function`?c(e,g):_===`object`&&!Array.isArray(e)?{...g,...e}:e}return typeof t==`string`?v.read(t):t}function T(e){if(!(e&&e.storageArea!==n)){if(e&&e.key==null)m.value=g;else if(!(e&&e.key!==h.value)){y();try{let t=v.write(m.value);(e===void 0||e?.newValue!==t)&&(m.value=w(e))}catch(e){f(e)}finally{e?zn(b):b()}}}}function E(e){T(e.detail)}return m}var Wd=`*,*::before,*::after{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}`;function Gd(e={}){let{selector:t=`html`,attribute:n=`class`,initialValue:r=`auto`,window:i=wd,storage:a,storageKey:o=`vueuse-color-scheme`,listenToStorageChanges:s=!0,storageRef:c,emitAuto:l,disableTransition:u=!0}=e,d={auto:``,light:`light`,dark:`dark`,...e.modes||{}},f=zd({window:i}),p=V(()=>f.value?`dark`:`light`),m=c||(o==null?pd(r):Ud(o,r,a,{window:i,listenToStorageChanges:s})),h=V(()=>m.value===`auto`?p.value:m.value),g=Rd(`updateHTMLAttrs`,(e,t,n)=>{let r=typeof e==`string`?i?.document.querySelector(e):Td(e);if(!r)return;let a=new Set,o=new Set,s=null;if(t===`class`){let e=n.split(/\s/g);Object.values(d).flatMap(e=>(e||``).split(/\s/g)).filter(Boolean).forEach(t=>{e.includes(t)?a.add(t):o.add(t)})}else s={key:t,value:n};if(a.size===0&&o.size===0&&s===null)return;let c;u&&(c=i.document.createElement(`style`),c.appendChild(document.createTextNode(Wd)),i.document.head.appendChild(c));for(let e of a)r.classList.add(e);for(let e of o)r.classList.remove(e);s&&r.setAttribute(s.key,s.value),u&&(i.getComputedStyle(c).opacity,document.head.removeChild(c))});function _(e){g(t,n,d[e]??e)}function v(t){e.onChanged?e.onChanged(t,_):_(t)}cr(h,v,{flush:`post`,immediate:!0}),Sd(()=>v(h.value));let y=V({get(){return l?m.value:h.value},set(e){m.value=e}});return Object.assign(y,{store:m,system:p,state:h})}function Kd(e={}){let{valueDark:t=`dark`,valueLight:n=``}=e,r=Gd({...e,onChanged:(t,n)=>{var r;e.onChanged?(r=e.onChanged)==null||r.call(e,t===`dark`,n,t):n(t)},modes:{dark:t,light:n}}),i=V(()=>r.system.value);return V({get(){return r.value===`dark`},set(e){let t=e?`dark`:`light`;i.value===t?r.value=`auto`:r.value=t}})}var qd={ctrl:`control`,command:`meta`,cmd:`meta`,option:`alt`,up:`arrowup`,down:`arrowdown`,left:`arrowleft`,right:`arrowright`};function Jd(e={}){let{reactive:t=!1,target:n=wd,aliasMap:r=qd,passive:i=!0,onEventFired:a=ud}=e,o=Gt(new Set),s={toJSON(){return{}},current:o},c=t?Gt(s):s,l=new Set,u=new Map([[`Meta`,l],[`Shift`,new Set],[`Alt`,new Set]]),d=new Set;function f(e,n){e in c&&(t?c[e]=n:c[e].value=n)}function p(){o.clear();for(let e of d)f(e,!1)}function m(e,t,n){if(e&&typeof t.getModifierState==`function`){for(let[e,r]of u)if(t.getModifierState(e)){n.forEach(e=>r.add(e));break}}}function h(e,t){if(e)return;let n=`${t[0].toUpperCase()}${t.slice(1)}`,r=u.get(n);if(![`shift`,`alt`].includes(t)||!r)return;let i=Array.from(r),a=i.indexOf(t);i.forEach((e,t)=>{t>=a&&(o.delete(e),f(e,!1))}),r.clear()}function g(e,t){let n=e.key?.toLowerCase(),r=[e.code?.toLowerCase(),n].filter(Boolean);if(n){n&&(t?o.add(n):o.delete(n));for(let e of r)d.add(e),f(e,t);m(t,e,[...o,...r]),h(t,n),n===`meta`&&!t&&(l.forEach(e=>{o.delete(e),f(e,!1)}),l.clear())}}Ed(n,`keydown`,e=>(g(e,!0),a(e)),{passive:i}),Ed(n,`keyup`,e=>(g(e,!1),a(e)),{passive:i}),Ed(`blur`,p,{passive:i}),Ed(`focus`,p,{passive:i});let _=new Proxy(c,{get(e,n,i){if(typeof n!=`string`)return Reflect.get(e,n,i);if(n=n.toLowerCase(),n in r&&(n=r[n]),!(n in c)){if(/[+_-]/.test(n)){let e=n.split(/[+_-]/g).map(e=>e.trim());c[n]=V(()=>e.map(e=>un(_[e])).every(Boolean))}else c[n]=on(!1)}let a=Reflect.get(e,n,i);return t?un(a):a}});return _}var Yd={role:`menu`,class:`min-w-40 border border-gray-200 rounded-md bg-white py-1 text-[13px] shadow-lg dark:border-gray-700 dark:bg-gray-800`},Xd=[`onClick`],Zd=I({__name:`BaseContextMenu`,props:fi({x:{},y:{},items:{}},{modelValue:{type:Boolean,required:!1},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let t=Mi(e,`modelValue`),{escape:n}=Jd();cr(n,()=>{t.value&&=!1});let r=Nr(`root`);Od(r,()=>{t.value=!1});function i(e){t.value=!1,e.onClick()}return(n,a)=>t.value?(L(),Pa(`div`,{key:0,ref_key:`root`,ref:r,class:`fixed`,style:le({left:`${e.x}px`,top:`${e.y}px`})},[z(`ul`,Yd,[(L(!0),Pa(wa,null,ri(e.items,e=>(L(),Pa(`li`,{key:e.label,role:`menuitem`,class:`cursor-pointer px-2.5 py-1 text-gray-700 transition-colors hover:bg-gray-100 dark:text-gray-200 dark:hover:bg-gray-700`,onClick:t=>i(e)},we(e.label),9,Xd))),128))])],4)):Wa(``,!0)}}),Qd={class:`flex flex-shrink-0 gap-0.5 rounded-md bg-gray-100 p-0.5 dark:bg-gray-800`},$d=[`onClick`],ef=I({__name:`BaseToggleGroup`,props:fi({options:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let t=Mi(e,`modelValue`);return(n,r)=>(L(),Pa(`div`,Qd,[(L(!0),Pa(wa,null,ri(e.options,e=>(L(),Pa(`button`,{key:e.key,type:`button`,class:M([`h-6 flex cursor-pointer items-center gap-1 rounded px-2 text-xs font-medium transition-colors`,t.value===e.key?`bg-white text-gray-900 shadow-sm dark:bg-gray-600 dark:text-white`:`text-gray-500 hover:text-gray-900 dark:text-gray-400 dark:hover:text-white`]),onClick:n=>t.value=e.key},[z(`span`,{class:M([e.icon,`text-[13px]`])},null,2),Ha(` `+we(e.label),1)],10,$d))),128))]))}}),tf=[`aria-expanded`,`aria-describedby`],nf=[`id`],rf=I({__name:`BaseTooltip`,setup(e){let t=Nr(`trigger`),n=Nr(`tooltip`),r=jr(),i=N(!1),a=N({x:0,y:0});function o(){if(i.value=!i.value,i.value&&t.value){let e=t.value.getBoundingClientRect();a.value.x=e.right,a.value.y=e.top}}function s(){i.value=!1}return Od(n,e=>{t.value?.contains(e.target)||s()}),(e,c)=>(L(),Pa(wa,null,[z(`button`,{ref_key:`trigger`,ref:t,type:`button`,class:`cursor-pointer`,"aria-expanded":i.value,"aria-describedby":i.value?P(r):void 0,onClick:o,onKeydown:_s(s,[`escape`])},[ai(e.$slots,`default`)],40,tf),(L(),R(Cr,{to:`body`},[i.value?(L(),Pa(`div`,{key:0,id:P(r),ref_key:`tooltip`,ref:n,role:`tooltip`,style:le({left:`${a.value.x}px`,top:`${a.value.y}px`}),class:`absolute max-w-[350px] border border-gray-200 rounded-md bg-white px-3 py-2 text-[13px] text-gray-700 shadow-lg dark:border-gray-700 dark:bg-gray-800 dark:text-gray-300`},[ai(e.$slots,`content`)],12,nf)):Wa(``,!0)]))],64))}}),af={class:`flex items-center gap-2 px-2 py-1.5 text-[13px] text-gray-700 dark:text-gray-300`},of=[`title`],sf=I({__name:`OptionItem`,props:{title:{}},setup(e){return(t,n)=>(L(),Pa(`div`,af,[z(`span`,{class:`min-w-0 flex-1 truncate`,title:e.title},we(e.title),9,of),t.$slots.description?(L(),R(rf,{key:0},{content:F(()=>[ai(t.$slots,`description`)]),default:F(()=>[n[0]||=z(`div`,{class:`i-mdi:information-outline`},null,-1)]),_:3})):Wa(``,!0),ai(t.$slots,`default`)]))}}),cf=[`value`],lf=I({__name:`DropdownOption`,props:fi({options:{},title:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let t=Mi(e,`modelValue`);return(n,r)=>(L(),R(sf,{title:e.title},ii({default:F(()=>[$n(z(`select`,{"onUpdate:modelValue":r[0]||=e=>t.value=e,class:`cursor-pointer rounded bg-gray-100 px-1.5 py-0.5 text-xs capitalize transition-colors dark:bg-gray-800 hover:bg-gray-200 focus:outline-none dark:hover:bg-gray-700`},[(L(!0),Pa(wa,null,ri(e.options,e=>(L(),Pa(`option`,{key:e,value:e,class:`capitalize`},we(e),9,cf))),128))],512),[[ls,t.value]])]),_:2},[n.$slots.description?{name:`description`,fn:F(()=>[ai(n.$slots,`description`)]),key:`0`}:void 0]),1032,[`title`]))}}),uf=[`aria-expanded`,`aria-controls`],df=[`id`],ff=I({__name:`BaseDisclosure`,props:fi({persistent:{type:Boolean},labelClass:{},panelClass:{}},{open:{type:Boolean,required:!1,default:!1},openModifiers:{}}),emits:[`update:open`],setup(e){let t=e,n=Mi(e,`open`),r=jr(),i=V(()=>{let e;return t.persistent&&(e=n.value?void 0:`none`),{style:e}});function a(e){n.value=e??!n.value}return(t,o)=>(L(),Pa(wa,null,[z(`button`,{type:`button`,class:M(e.labelClass),"aria-expanded":n.value,"aria-controls":P(r),onClick:o[0]||=e=>a()},[ai(t.$slots,`label`,{isOpen:n.value,toggle:a})],10,uf),e.persistent||n.value?(L(),Pa(`div`,{key:0,id:P(r),style:le(i.value),class:M(e.panelClass)},[ai(t.$slots,`default`)],14,df)):Wa(``,!0)],64))}}),pf=I({__name:`OptionGroup`,props:{title:{}},setup(e){return(t,n)=>(L(),R(ff,{"label-class":`text-[13px] text-gray-700 dark:text-gray-300 px-2 py-1.5 flex w-full items-center justify-between`,open:``},{label:F(({isOpen:t})=>[Ha(we(e.title)+` `,1),z(`span`,{class:M([`i-mdi:chevron-down flex-none text-[14px] transition-transform`,t?`rotate-180`:``])},null,2)]),default:F(()=>[ai(t.$slots,`default`)]),_:3}))}}),mf=[`title`],hf=I({__name:`ThemeSwitcher`,setup(e){let t=Kd();function n(){t.value=!t.value}return(e,r)=>(L(),Pa(`button`,{type:`button`,class:`h-7 w-7 flex cursor-pointer items-center justify-center rounded text-gray-500 transition-colors hover:bg-gray-100 dark:text-gray-400 hover:text-gray-900 dark:hover:bg-gray-800 dark:hover:text-gray-100`,title:P(t)?`Switch to light theme`:`Switch to dark theme`,onClick:n},[z(`span`,{class:M(P(t)?`i-mdi:weather-sunny`:`i-mdi:weather-night`)},null,2)],8,mf))}}),gf={key:0,class:`i-mdi:warning-outline text-amber-500`},_f={key:1,class:`i-mdi:information-outline`},vf={class:`space-y-1`},yf={key:0,class:`mt-2 space-y-1`},bf=I({__name:`OverviewModal`,props:{stats:{}},setup(e){let t=Es(e.stats);return(e,n)=>(L(),R(P(id),{title:`Report`},{trigger:F(()=>[B(P(Os),{class:M(e.$attrs.class)},{default:F(()=>[P(t).hasWarnings?(L(),Pa(`span`,gf)):(L(),Pa(`span`,_f)),n[0]||=Ha(` Report `,-1)]),_:1},8,[`class`])]),default:F(()=>[z(`div`,vf,[z(`div`,null,`Number of chunks: `+we(P(t).numberOfChunks),1),z(`div`,null,` Number of modules: `+we(P(t).numberOfModules)+` (`+we(P(t).numberOfVirtualModules)+` virtual) `,1),z(`div`,null,`Number of dependencies: `+we(P(t).numberOfDependencies),1),z(`div`,null,`Duplicated dependencies: `+we(P(t).duplicatedDependencies.length),1),P(t).duplicatedDependencies.length>0?(L(),Pa(`ul`,yf,[(L(!0),Pa(wa,null,ri(P(t).duplicatedDependencies,e=>(L(),Pa(`li`,{key:e.name,class:`flex items-center gap-1`},[n[1]||=z(`div`,{class:`i-mdi:alert-circle-outline text-amber-500`},null,-1),Ha(` `+we(e.name)+` - `+we(e.count)+` versions `,1)]))),128))])):Wa(``,!0)])]),_:1}))}}),xf={class:`h-full overflow-y-auto bg-gray-50 p-1.5 dark:bg-gray-950/40`},Sf=I({__name:`SplitLayout`,setup(e){function t(){window.dispatchEvent(new Event(`resize`))}return(e,n)=>(L(),R(P(Ju),{direction:`horizontal`,class:`min-h-0 flex-1`},{default:F(()=>[B(P(Yu),{"default-size":20,"min-size":12},{default:F(()=>[z(`div`,xf,[ai(e.$slots,`aside`)])]),_:3}),B(P(Zu),{class:`w-1.5 bg-gray-100 outline-none transition-colors dark:bg-gray-800 hover:bg-blue-600`}),B(P(Yu),{class:`flex`,onResize:t},{default:F(()=>[ai(e.$slots,`main`)]),_:3})]),_:3}))}}),Cf=function(e,t){return Cf=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},Cf(e,t)};function U(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);Cf(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var wf=function(){function e(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return e}(),W=new(function(){function e(){this.browser=new wf,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 e}());typeof wx==`object`&&typeof wx.getSystemInfoSync==`function`?(W.wxa=!0,W.touchEventsSupported=!0):typeof document>`u`&&typeof self<`u`?W.worker=!0:!W.hasGlobalWindow||`Deno`in window?(W.node=!0,W.svgSupported=!0):Tf(navigator.userAgent,W);function Tf(e,t){var n=t.browser,r=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);r&&(n.firefox=!0,n.version=r[1]),i&&(n.ie=!0,n.version=i[1]),a&&(n.edge=!0,n.version=a[1],n.newEdge=+a[1].split(`.`)[0]>18),o&&(n.weChat=!0),t.svgSupported=typeof SVGRect<`u`,t.touchEventsSupported=`ontouchstart`in window&&!n.ie&&!n.edge,t.pointerEventsSupported=`onpointerdown`in window&&(n.edge||n.ie&&+n.version>=11),t.domSupported=typeof document<`u`;var s=document.documentElement.style;t.transform3dSupported=(n.ie&&`transition`in s||n.edge||`WebKitCSSMatrix`in window&&`m11`in new WebKitCSSMatrix||`MozPerspective`in s)&&!(`OTransition`in s),t.transformSupported=t.transform3dSupported||n.ie&&+n.version>=9}var Ef=`12px sans-serif`,Df=20,Of=100,kf=`007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N`;function Af(e){var t={};if(typeof JSON>`u`)return t;for(var n=0;n<e.length;n++){var r=String.fromCharCode(n+32);t[r]=(e.charCodeAt(n)-Df)/Of}return t}var jf=Af(kf),Mf={createCanvas:function(){return typeof document<`u`&&document.createElement(`canvas`)},measureText:(function(){var e,t;return function(n,r){if(!e){var i=Mf.createCanvas();e=i&&i.getContext(`2d`)}if(e)return t!==r&&(t=e.font=r||`12px sans-serif`),e.measureText(n);n||=``,r||=`12px sans-serif`;var a=/((?:\d+)?\.?\d*)px/.exec(r),o=a&&+a[1]||12,s=0;if(r.indexOf(`mono`)>=0)s=o*n.length;else for(var c=0;c<n.length;c++){var l=jf[n[c]];s+=l==null?o:l*o}return{width:s}}})(),loadImage:function(e,t,n){var r=new Image;return r.onload=t,r.onerror=n,r.src=e,r}},Nf=ep([`Function`,`RegExp`,`Date`,`Error`,`CanvasGradient`,`CanvasPattern`,`Image`,`Canvas`],function(e,t){return e[`[object `+t+`]`]=!0,e},{}),Pf=ep([`Int8`,`Uint8`,`Uint8Clamped`,`Int16`,`Uint16`,`Int32`,`Uint32`,`Float32`,`Float64`],function(e,t){return e[`[object `+t+`Array]`]=!0,e},{}),Ff=Object.prototype.toString,If=Array.prototype,Lf=If.forEach,Rf=If.filter,zf=If.slice,Bf=If.map,Vf=function(){}.constructor,Hf=Vf?Vf.prototype:null,Uf=`__proto__`,Wf=2311;function Gf(){return Wf++}function Kf(){var e=[...arguments];typeof console<`u`&&console.error.apply(console,e)}function G(e){if(typeof e!=`object`||!e)return e;var t=e,n=Ff.call(e);if(n===`[object Array]`){if(!Cp(e)){t=[];for(var r=0,i=e.length;r<i;r++)t[r]=G(e[r])}}else if(Pf[n]){if(!Cp(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var r=0,i=e.length;r<i;r++)t[r]=e[r]}}}else if(!Nf[n]&&!Cp(e)&&!dp(e))for(var o in t={},e)e.hasOwnProperty(o)&&o!==Uf&&(t[o]=G(e[o]));return t}function qf(e,t,n){if(!X(t)||!X(e))return n?G(t):e;for(var r in t)if(t.hasOwnProperty(r)&&r!==Uf){var i=e[r],a=t[r];X(a)&&X(i)&&!J(a)&&!J(i)&&!dp(a)&&!dp(i)&&!lp(a)&&!lp(i)&&!Cp(a)&&!Cp(i)?qf(i,a,n):(n||!(r in e))&&(e[r]=G(t[r]))}return e}function K(e,t){if(Object.assign)Object.assign(e,t);else for(var n in t)t.hasOwnProperty(n)&&n!==Uf&&(e[n]=t[n]);return e}function Jf(e,t,n){for(var r=np(t),i=0,a=r.length;i<a;i++){var o=r[i];(n?t[o]!=null:e[o]==null)&&(e[o]=t[o])}return e}Mf.createCanvas;function Yf(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n}return-1}function Xf(e,t){var n=e.prototype;function r(){}for(var i in r.prototype=t.prototype,e.prototype=new r,n)n.hasOwnProperty(i)&&(e.prototype[i]=n[i]);e.prototype.constructor=e,e.superClass=t}function Zf(e,t,n){if(e=`prototype`in e?e.prototype:e,t=`prototype`in t?t.prototype:t,Object.getOwnPropertyNames)for(var r=Object.getOwnPropertyNames(t),i=0;i<r.length;i++){var a=r[i];a!==`constructor`&&(n?t[a]!=null:e[a]==null)&&(e[a]=t[a])}else Jf(e,t,n)}function Qf(e){return!e||typeof e==`string`?!1:typeof e.length==`number`}function q(e,t,n){if(e&&t){if(e.forEach&&e.forEach===Lf)e.forEach(t,n);else if(e.length===+e.length)for(var r=0,i=e.length;r<i;r++)t.call(n,e[r],r,e);else for(var a in e)e.hasOwnProperty(a)&&t.call(n,e[a],a,e)}}function $f(e,t,n){if(!e)return[];if(!t)return _p(e);if(e.map&&e.map===Bf)return e.map(t,n);for(var r=[],i=0,a=e.length;i<a;i++)r.push(t.call(n,e[i],i,e));return r}function ep(e,t,n,r){if(e&&t){for(var i=0,a=e.length;i<a;i++)n=t.call(r,n,e[i],i,e);return n}}function tp(e,t,n){if(!e)return[];if(!t)return _p(e);if(e.filter&&e.filter===Rf)return e.filter(t,n);for(var r=[],i=0,a=e.length;i<a;i++)t.call(n,e[i],i,e)&&r.push(e[i]);return r}function np(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}function rp(e,t){var n=[...arguments].slice(2);return function(){return e.apply(t,n.concat(zf.call(arguments)))}}var ip=Hf&&op(Hf.bind)?Hf.call.bind(Hf.bind):rp;function ap(e){var t=[...arguments].slice(1);return function(){return e.apply(this,t.concat(zf.call(arguments)))}}function J(e){return Array.isArray?Array.isArray(e):Ff.call(e)===`[object Array]`}function op(e){return typeof e==`function`}function Y(e){return typeof e==`string`}function sp(e){return Ff.call(e)===`[object String]`}function cp(e){return typeof e==`number`}function X(e){var t=typeof e;return t===`function`||!!e&&t===`object`}function lp(e){return!!Nf[Ff.call(e)]}function up(e){return!!Pf[Ff.call(e)]}function dp(e){return typeof e==`object`&&typeof e.nodeType==`number`&&typeof e.ownerDocument==`object`}function fp(e){return e.colorStops!=null}function pp(e){return e.image!=null}function mp(e){return e!==e}function hp(){for(var e=[...arguments],t=0,n=e.length;t<n;t++)if(e[t]!=null)return e[t]}function Z(e,t){return e??t}function gp(e,t,n){return e??t??n}function _p(e){var t=[...arguments].slice(1);return zf.apply(e,t)}function vp(e){if(typeof e==`number`)return[e,e,e,e];var t=e.length;return t===2?[e[0],e[1],e[0],e[1]]:t===3?[e[0],e[1],e[2],e[1]]:e}function yp(e,t){if(!e)throw Error(t)}function bp(e){return e==null?null:typeof e.trim==`function`?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``)}var xp=`__ec_primitive__`;function Sp(e){e[xp]=!0}function Cp(e){return e[xp]}var wp=function(){function e(){this.data={}}return e.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},e.prototype.has=function(e){return this.data.hasOwnProperty(e)},e.prototype.get=function(e){return this.data[e]},e.prototype.set=function(e,t){return this.data[e]=t,this},e.prototype.keys=function(){return np(this.data)},e.prototype.forEach=function(e){var t=this.data;for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)},e}(),Tp=typeof Map==`function`;function Ep(){return Tp?new Map:new wp}var Dp=function(){function e(t){var n=J(t);this.data=Ep();var r=this;t instanceof e?t.each(i):t&&q(t,i);function i(e,t){n?r.set(e,t):r.set(t,e)}}return e.prototype.hasKey=function(e){return this.data.has(e)},e.prototype.get=function(e){return this.data.get(e)},e.prototype.set=function(e,t){return this.data.set(e,t),t},e.prototype.each=function(e,t){this.data.forEach(function(n,r){e.call(t,n,r)})},e.prototype.keys=function(){var e=this.data.keys();return Tp?Array.from(e):e},e.prototype.removeKey=function(e){this.data.delete(e)},e}();function Q(e){return new Dp(e)}function Op(e,t){for(var n=new e.constructor(e.length+t.length),r=0;r<e.length;r++)n[r]=e[r];for(var i=e.length,r=0;r<t.length;r++)n[r+i]=t[r];return n}function kp(e,t){var n;if(Object.create)n=Object.create(e);else{var r=function(){};r.prototype=e,n=new r}return t&&K(n,t),n}function Ap(e){var t=e.style;t.webkitUserSelect=`none`,t.userSelect=`none`,t.webkitTapHighlightColor=`rgba(0,0,0,0)`,t[`-webkit-touch-callout`]=`none`}function jp(e,t){return e.hasOwnProperty(t)}function Mp(){}var Np=180/Math.PI;function Pp(e,t){return e??=0,t??=0,[e,t]}function Fp(e,t){return e[0]=t[0],e[1]=t[1],e}function Ip(e){return[e[0],e[1]]}function Lp(e,t,n){return e[0]=t,e[1]=n,e}function Rp(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function zp(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e}function Bp(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function Vp(e){return Math.sqrt(Hp(e))}function Hp(e){return e[0]*e[0]+e[1]*e[1]}function Up(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function Wp(e,t){var n=Vp(t);return n===0?(e[0]=0,e[1]=0):(e[0]=t[0]/n,e[1]=t[1]/n),e}function Gp(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}var Kp=Gp;function qp(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}var Jp=qp;function Yp(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i+n[4],e[1]=n[1]*r+n[3]*i+n[5],e}function Xp(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function Zp(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}var Qp=function(){function e(e,t){this.target=e,this.topTarget=t&&t.topTarget}return e}(),$p=function(){function e(e){this.handler=e,e.on(`mousedown`,this._dragStart,this),e.on(`mousemove`,this._drag,this),e.on(`mouseup`,this._dragEnd,this)}return e.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 Qp(t,e),`dragstart`,e.event))},e.prototype._drag=function(e){var t=this._draggingTarget;if(t){var n=e.offsetX,r=e.offsetY,i=n-this._x,a=r-this._y;this._x=n,this._y=r,t.drift(i,a,e),this.handler.dispatchToElement(new Qp(t,e),`drag`,e.event);var o=this.handler.findHover(n,r,t).target,s=this._dropTarget;this._dropTarget=o,t!==o&&(s&&o!==s&&this.handler.dispatchToElement(new Qp(s,e),`dragleave`,e.event),o&&o!==s&&this.handler.dispatchToElement(new Qp(o,e),`dragenter`,e.event))}},e.prototype._dragEnd=function(e){var t=this._draggingTarget;t&&(t.dragging=!1),this.handler.dispatchToElement(new Qp(t,e),`dragend`,e.event),this._dropTarget&&this.handler.dispatchToElement(new Qp(this._dropTarget,e),`drop`,e.event),this._draggingTarget=null,this._dropTarget=null},e}(),em=function(){function e(e){e&&(this._$eventProcessor=e)}return e.prototype.on=function(e,t,n,r){this._$handlers||={};var i=this._$handlers;if(typeof t==`function`&&(r=n,n=t,t=null),!n||!e)return this;var a=this._$eventProcessor;t!=null&&a&&a.normalizeQuery&&(t=a.normalizeQuery(t)),i[e]||(i[e]=[]);for(var o=0;o<i[e].length;o++)if(i[e][o].h===n)return this;var s={h:n,query:t,ctx:r||this,callAtLast:n.zrEventfulCallAtLast},c=i[e].length-1,l=i[e][c];return l&&l.callAtLast?i[e].splice(c,0,s):i[e].push(s),this},e.prototype.isSilent=function(e){var t=this._$handlers;return!t||!t[e]||!t[e].length},e.prototype.off=function(e,t){var n=this._$handlers;if(!n)return this;if(!e)return this._$handlers={},this;if(t){if(n[e]){for(var r=[],i=0,a=n[e].length;i<a;i++)n[e][i].h!==t&&r.push(n[e][i]);n[e]=r}n[e]&&n[e].length===0&&delete n[e]}else delete n[e];return this},e.prototype.trigger=function(e){var t=[...arguments].slice(1);if(!this._$handlers)return this;var n=this._$handlers[e],r=this._$eventProcessor;if(n)for(var i=t.length,a=n.length,o=0;o<a;o++){var s=n[o];if(!(r&&r.filter&&s.query!=null&&!r.filter(e,s.query)))switch(i){case 0:s.h.call(s.ctx);break;case 1:s.h.call(s.ctx,t[0]);break;case 2:s.h.call(s.ctx,t[0],t[1]);break;default:s.h.apply(s.ctx,t)}}return r&&r.afterTrigger&&r.afterTrigger(e),this},e.prototype.triggerWithContext=function(e){var t=[...arguments].slice(1);if(!this._$handlers)return this;var n=this._$handlers[e],r=this._$eventProcessor;if(n)for(var i=t.length,a=t[i-1],o=n.length,s=0;s<o;s++){var c=n[s];if(!(r&&r.filter&&c.query!=null&&!r.filter(e,c.query)))switch(i){case 0:c.h.call(a);break;case 1:c.h.call(a,t[0]);break;case 2:c.h.call(a,t[0],t[1]);break;default:c.h.apply(a,t.slice(1,i-1))}}return r&&r.afterTrigger&&r.afterTrigger(e),this},e}(),tm=Math.log(2);function nm(e,t,n,r,i,a){var o=r+`-`+i,s=e.length;if(a.hasOwnProperty(o))return a[o];if(t===1){var c=Math.round(Math.log((1<<s)-1&~i)/tm);return e[n][c]}for(var l=r|1<<n,u=n+1;r&1<<u;)u++;for(var d=0,f=0,p=0;f<s;f++){var m=1<<f;m&i||(d+=(p%2?-1:1)*e[n][f]*nm(e,t-1,u,l,i|m,a),p++)}return a[o]=d,d}function rm(e,t){var n=[[e[0],e[1],1,0,0,0,-t[0]*e[0],-t[0]*e[1]],[0,0,0,e[0],e[1],1,-t[1]*e[0],-t[1]*e[1]],[e[2],e[3],1,0,0,0,-t[2]*e[2],-t[2]*e[3]],[0,0,0,e[2],e[3],1,-t[3]*e[2],-t[3]*e[3]],[e[4],e[5],1,0,0,0,-t[4]*e[4],-t[4]*e[5]],[0,0,0,e[4],e[5],1,-t[5]*e[4],-t[5]*e[5]],[e[6],e[7],1,0,0,0,-t[6]*e[6],-t[6]*e[7]],[0,0,0,e[6],e[7],1,-t[7]*e[6],-t[7]*e[7]]],r={},i=nm(n,8,0,0,0,r);if(i!==0){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)a[s]??(a[s]=0),a[s]+=((o+s)%2?-1:1)*nm(n,7,+(o===0),1<<o,1<<s,r)/i*t[o];return function(e,t,n){var r=t*a[6]+n*a[7]+1;e[0]=(t*a[0]+n*a[1]+a[2])/r,e[1]=(t*a[3]+n*a[4]+a[5])/r}}}var im=`___zrEVENTSAVED`,am=[];function om(e,t,n,r,i){return sm(am,t,r,i,!0)&&sm(e,n,am[0],am[1])}function sm(e,t,n,r,i){if(t.getBoundingClientRect&&W.domSupported&&!um(t)){var a=t[im]||(t[im]={}),o=lm(cm(t,a),a,i);if(o)return o(e,n,r),!0}return!1}function cm(e,t){var n=t.markers;if(n)return n;n=t.markers=[];for(var r=[`left`,`right`],i=[`top`,`bottom`],a=0;a<4;a++){var o=document.createElement(`div`),s=o.style,c=a%2,l=(a>>1)%2;s.cssText=[`position: absolute`,`visibility: hidden`,`padding: 0`,`margin: 0`,`border-width: 0`,`user-select: none`,`width:0`,`height:0`,r[c]+`:0`,i[l]+`:0`,r[1-c]+`:auto`,i[1-l]+`:auto`,``].join(`!important;`),e.appendChild(o),n.push(o)}return n}function lm(e,t,n){for(var r=n?`invTrans`:`trans`,i=t[r],a=t.srcCoords,o=[],s=[],c=!0,l=0;l<4;l++){var u=e[l].getBoundingClientRect(),d=2*l,f=u.left,p=u.top;o.push(f,p),c=c&&a&&f===a[d]&&p===a[d+1],s.push(e[l].offsetLeft,e[l].offsetTop)}return c&&i?i:(t.srcCoords=o,t[r]=n?rm(s,o):rm(o,s))}function um(e){return e.nodeName.toUpperCase()===`CANVAS`}var dm=/([&<>"'])/g,fm={"&":`&`,"<":`<`,">":`>`,'"':`"`,"'":`'`};function pm(e){return e==null?``:(e+``).replace(dm,function(e,t){return fm[t]})}var mm=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,hm=[],gm=W.browser.firefox&&+W.browser.version.split(`.`)[0]<39;function _m(e,t,n,r){return n||={},r?vm(e,t,n):gm&&t.layerX!=null&&t.layerX!==t.offsetX?(n.zrX=t.layerX,n.zrY=t.layerY):t.offsetX==null?vm(e,t,n):(n.zrX=t.offsetX,n.zrY=t.offsetY),n}function vm(e,t,n){if(W.domSupported&&e.getBoundingClientRect){var r=t.clientX,i=t.clientY;if(um(e)){var a=e.getBoundingClientRect();n.zrX=r-a.left,n.zrY=i-a.top;return}if(sm(hm,e,r,i)){n.zrX=hm[0],n.zrY=hm[1];return}}n.zrX=n.zrY=0}function ym(e){return e||window.event}function bm(e,t,n){if(t=ym(t),t.zrX!=null)return t;var r=t.type;if(r&&r.indexOf(`touch`)>=0){var i=r===`touchend`?t.changedTouches[0]:t.targetTouches[0];i&&_m(e,i,t,n)}else{_m(e,t,t,n);var a=xm(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var o=t.button;return t.which==null&&o!==void 0&&mm.test(t.type)&&(t.which=o&1?1:o&2?3:o&4?2:0),t}function xm(e){var t=e.wheelDelta;if(t)return t;var n=e.deltaX,r=e.deltaY;if(n==null||r==null)return t;var i=Math.abs(r===0?n:r),a=r>0?-1:r<0?1:n>0?-1:1;return 3*i*a}function Sm(e,t,n,r){e.addEventListener(t,n,r)}function Cm(e,t,n,r){e.removeEventListener(t,n,r)}var wm=function(e){e.preventDefault(),e.stopPropagation(),e.cancelBubble=!0};function Tm(e){return e.which===2||e.which===3}var Em=function(){function e(){this._track=[]}return e.prototype.recognize=function(e,t,n){return this._doTrack(e,t,n),this._recognize(e)},e.prototype.clear=function(){return this._track.length=0,this},e.prototype._doTrack=function(e,t,n){var r=e.touches;if(r){for(var i={points:[],touches:[],target:t,event:e},a=0,o=r.length;a<o;a++){var s=r[a],c=_m(n,s,{});i.points.push([c.zrX,c.zrY]),i.touches.push(s)}this._track.push(i)}},e.prototype._recognize=function(e){for(var t in km)if(km.hasOwnProperty(t)){var n=km[t](this._track,e);if(n)return n}},e}();function Dm(e){var t=e[1][0]-e[0][0],n=e[1][1]-e[0][1];return Math.sqrt(t*t+n*n)}function Om(e){return[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]}var km={pinch:function(e,t){var n=e.length;if(n){var r=(e[n-1]||{}).points,i=(e[n-2]||{}).points||r;if(i&&i.length>1&&r&&r.length>1){var a=Dm(r)/Dm(i);!isFinite(a)&&(a=1),t.pinchScale=a;var o=Om(r);return t.pinchX=o[0],t.pinchY=o[1],{type:`pinch`,target:e[0].target,event:t}}}}};function Am(){return[1,0,0,1,0,0]}function jm(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function Mm(e,t){return 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}function Nm(e,t,n){var r=t[0]*n[0]+t[2]*n[1],i=t[1]*n[0]+t[3]*n[1],a=t[0]*n[2]+t[2]*n[3],o=t[1]*n[2]+t[3]*n[3],s=t[0]*n[4]+t[2]*n[5]+t[4],c=t[1]*n[4]+t[3]*n[5]+t[5];return e[0]=r,e[1]=i,e[2]=a,e[3]=o,e[4]=s,e[5]=c,e}function Pm(e,t,n){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+n[0],e[5]=t[5]+n[1],e}function Fm(e,t,n,r){r===void 0&&(r=[0,0]);var i=t[0],a=t[2],o=t[4],s=t[1],c=t[3],l=t[5],u=Math.sin(n),d=Math.cos(n);return e[0]=i*d+s*u,e[1]=-i*u+s*d,e[2]=a*d+c*u,e[3]=-a*u+d*c,e[4]=d*(o-r[0])+u*(l-r[1])+r[0],e[5]=d*(l-r[1])-u*(o-r[0])+r[1],e}function Im(e,t,n){var r=n[0],i=n[1];return e[0]=t[0]*r,e[1]=t[1]*i,e[2]=t[2]*r,e[3]=t[3]*i,e[4]=t[4]*r,e[5]=t[5]*i,e}function Lm(e,t){var n=t[0],r=t[2],i=t[4],a=t[1],o=t[3],s=t[5],c=n*o-a*r;return c?(c=1/c,e[0]=o*c,e[1]=-a*c,e[2]=-r*c,e[3]=n*c,e[4]=(r*s-o*i)*c,e[5]=(a*i-n*s)*c,e):null}var Rm=function(){function e(e,t){this.x=e||0,this.y=t||0}return e.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},e.prototype.clone=function(){return new e(this.x,this.y)},e.prototype.set=function(e,t){return this.x=e,this.y=t,this},e.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},e.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},e.prototype.scale=function(e){this.x*=e,this.y*=e},e.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},e.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},e.prototype.dot=function(e){return this.x*e.x+this.y*e.y},e.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},e.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},e.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},e.prototype.distance=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},e.prototype.distanceSquare=function(e){var t=this.x-e.x,n=this.y-e.y;return t*t+n*n},e.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},e.prototype.transform=function(e){if(e){var t=this.x,n=this.y;return this.x=e[0]*t+e[2]*n+e[4],this.y=e[1]*t+e[3]*n+e[5],this}},e.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},e.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},e.set=function(e,t,n){e.x=t,e.y=n},e.copy=function(e,t){e.x=t.x,e.y=t.y},e.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},e.lenSquare=function(e){return e.x*e.x+e.y*e.y},e.dot=function(e,t){return e.x*t.x+e.y*t.y},e.add=function(e,t,n){e.x=t.x+n.x,e.y=t.y+n.y},e.sub=function(e,t,n){e.x=t.x-n.x,e.y=t.y-n.y},e.scale=function(e,t,n){e.x=t.x*n,e.y=t.y*n},e.scaleAndAdd=function(e,t,n,r){e.x=t.x+n.x*r,e.y=t.y+n.y*r},e.lerp=function(e,t,n,r){var i=1-r;e.x=i*t.x+r*n.x,e.y=i*t.y+r*n.y},e}(),zm=Math.min,Bm=Math.max,Vm=new Rm,Hm=new Rm,Um=new Rm,Wm=new Rm,Gm=new Rm,Km=new Rm,$=function(){function e(e,t,n,r){n<0&&(e+=n,n=-n),r<0&&(t+=r,r=-r),this.x=e,this.y=t,this.width=n,this.height=r}return e.prototype.union=function(e){var t=zm(e.x,this.x),n=zm(e.y,this.y);this.width=isFinite(this.x)&&isFinite(this.width)?Bm(e.x+e.width,this.x+this.width)-t:e.width,this.height=isFinite(this.y)&&isFinite(this.height)?Bm(e.y+e.height,this.y+this.height)-n:e.height,this.x=t,this.y=n},e.prototype.applyTransform=function(t){e.applyTransform(this,this,t)},e.prototype.calculateTransform=function(e){var t=this,n=e.width/t.width,r=e.height/t.height,i=Am();return Pm(i,i,[-t.x,-t.y]),Im(i,i,[n,r]),Pm(i,i,[e.x,e.y]),i},e.prototype.intersect=function(t,n){if(!t)return!1;t instanceof e||(t=e.create(t));var r=this,i=r.x,a=r.x+r.width,o=r.y,s=r.y+r.height,c=t.x,l=t.x+t.width,u=t.y,d=t.y+t.height,f=!(a<c||l<i||s<u||d<o);if(n){var p=1/0,m=0,h=Math.abs(a-c),g=Math.abs(l-i),_=Math.abs(s-u),v=Math.abs(d-o),y=Math.min(h,g),b=Math.min(_,v);a<c||l<i?y>m&&(m=y,h<g?Rm.set(Km,-h,0):Rm.set(Km,g,0)):y<p&&(p=y,h<g?Rm.set(Gm,h,0):Rm.set(Gm,-g,0)),s<u||d<o?b>m&&(m=b,_<v?Rm.set(Km,0,-_):Rm.set(Km,0,v)):y<p&&(p=y,_<v?Rm.set(Gm,0,_):Rm.set(Gm,0,-v))}return n&&Rm.copy(n,f?Gm:Km),f},e.prototype.contain=function(e,t){var n=this;return e>=n.x&&e<=n.x+n.width&&t>=n.y&&t<=n.y+n.height},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.copy=function(t){e.copy(this,t)},e.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},e.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},e.prototype.isZero=function(){return this.width===0||this.height===0},e.create=function(t){return new e(t.x,t.y,t.width,t.height)},e.copy=function(e,t){e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height},e.applyTransform=function(t,n,r){if(!r)t!==n&&e.copy(t,n);else if(r[1]<1e-5&&r[1]>-1e-5&&r[2]<1e-5&&r[2]>-1e-5){var i=r[0],a=r[3],o=r[4],s=r[5];t.x=n.x*i+o,t.y=n.y*a+s,t.width=n.width*i,t.height=n.height*a,t.width<0&&(t.x+=t.width,t.width=-t.width),t.height<0&&(t.y+=t.height,t.height=-t.height)}else{Vm.x=Um.x=n.x,Vm.y=Wm.y=n.y,Hm.x=Wm.x=n.x+n.width,Hm.y=Um.y=n.y+n.height,Vm.transform(r),Wm.transform(r),Hm.transform(r),Um.transform(r),t.x=zm(Vm.x,Hm.x,Um.x,Wm.x),t.y=zm(Vm.y,Hm.y,Um.y,Wm.y);var c=Bm(Vm.x,Hm.x,Um.x,Wm.x),l=Bm(Vm.y,Hm.y,Um.y,Wm.y);t.width=c-t.x,t.height=l-t.y}},e}(),qm=`silent`;function Jm(e,t,n){return{type:e,event:n,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:Ym}}function Ym(){wm(this.event)}var Xm=function(e){U(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.handler=null,t}return t.prototype.dispose=function(){},t.prototype.setCursor=function(){},t}(em),Zm=function(){function e(e,t){this.x=e,this.y=t}return e}(),Qm=[`click`,`dblclick`,`mousewheel`,`mouseout`,`mouseup`,`mousedown`,`mousemove`,`contextmenu`],$m=new $(0,0,0,0),eh=function(e){U(t,e);function t(t,n,r,i,a){var o=e.call(this)||this;return o._hovered=new Zm(0,0),o.storage=t,o.painter=n,o.painterRoot=i,o._pointerSize=a,r||=new Xm,o.proxy=null,o.setHandlerProxy(r),o._draggingMgr=new $p(o),o}return t.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(q(Qm,function(t){e.on&&e.on(t,this[t],this)},this),e.handler=this),this.proxy=e},t.prototype.mousemove=function(e){var t=e.zrX,n=e.zrY,r=rh(this,t,n),i=this._hovered,a=i.target;a&&!a.__zr&&(i=this.findHover(i.x,i.y),a=i.target);var o=this._hovered=r?new Zm(t,n):this.findHover(t,n),s=o.target,c=this.proxy;c.setCursor&&c.setCursor(s?s.cursor:`default`),a&&s!==a&&this.dispatchToElement(i,`mouseout`,e),this.dispatchToElement(o,`mousemove`,e),s&&s!==a&&this.dispatchToElement(o,`mouseover`,e)},t.prototype.mouseout=function(e){var t=e.zrEventControl;t!==`only_globalout`&&this.dispatchToElement(this._hovered,`mouseout`,e),t!==`no_globalout`&&this.trigger(`globalout`,{type:`globalout`,event:e})},t.prototype.resize=function(){this._hovered=new Zm(0,0)},t.prototype.dispatch=function(e,t){var n=this[e];n&&n.call(this,t)},t.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},t.prototype.setCursorStyle=function(e){var t=this.proxy;t.setCursor&&t.setCursor(e)},t.prototype.dispatchToElement=function(e,t,n){e||={};var r=e.target;if(!(r&&r.silent)){for(var i=`on`+t,a=Jm(t,e,n);r&&(r[i]&&(a.cancelBubble=!!r[i].call(r,a)),r.trigger(t,a),r=r.__hostTarget?r.__hostTarget:r.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(t,a),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(e){typeof e[i]==`function`&&e[i].call(e,a),e.trigger&&e.trigger(t,a)}))}},t.prototype.findHover=function(e,t,n){var r=this.storage.getDisplayList(),i=new Zm(e,t);if(nh(r,i,e,t,n),this._pointerSize&&!i.target){for(var a=[],o=this._pointerSize,s=o/2,c=new $(e-s,t-s,o,o),l=r.length-1;l>=0;l--){var u=r[l];u===n||u.ignore||u.ignoreCoarsePointer||u.parent&&u.parent.ignoreCoarsePointer||($m.copy(u.getBoundingRect()),u.transform&&$m.applyTransform(u.transform),$m.intersect(c)&&a.push(u))}if(a.length){for(var d=4,f=Math.PI/12,p=Math.PI*2,m=0;m<s;m+=d)for(var h=0;h<p;h+=f)if(nh(a,i,e+m*Math.cos(h),t+m*Math.sin(h),n),i.target)return i}}return i},t.prototype.processGesture=function(e,t){this._gestureMgr||=new Em;var n=this._gestureMgr;t===`start`&&n.clear();var r=n.recognize(e,this.findHover(e.zrX,e.zrY,null).target,this.proxy.dom);if(t===`end`&&n.clear(),r){var i=r.type;e.gestureEvent=i;var a=new Zm;a.target=r.target,this.dispatchToElement(a,i,r.event)}},t}(em);q([`click`,`mousedown`,`mouseup`,`mousewheel`,`dblclick`,`contextmenu`],function(e){eh.prototype[e]=function(t){var n=t.zrX,r=t.zrY,i=rh(this,n,r),a,o;if(e===`mouseup`&&i||(a=this.findHover(n,r),o=a.target),e===`mousedown`)this._downEl=o,this._downPoint=[t.zrX,t.zrY],this._upEl=o;else if(e===`mouseup`)this._upEl=o;else if(e===`click`){if(this._downEl!==this._upEl||!this._downPoint||Kp(this._downPoint,[t.zrX,t.zrY])>4)return;this._downPoint=null}this.dispatchToElement(a,e,t)}});function th(e,t,n){if(e[e.rectHover?`rectContain`:`contain`](t,n)){for(var r=e,i=void 0,a=!1;r;){if(r.ignoreClip&&(a=!0),!a){var o=r.getClipPath();if(o&&!o.contain(t,n))return!1}r.silent&&(i=!0),r=r.__hostTarget||r.parent}return!i||qm}return!1}function nh(e,t,n,r,i){for(var a=e.length-1;a>=0;a--){var o=e[a],s=void 0;if(o!==i&&!o.ignore&&(s=th(o,n,r))&&(!t.topTarget&&(t.topTarget=o),s!==qm)){t.target=o;break}}}function rh(e,t,n){var r=e.painter;return t<0||t>r.getWidth()||n<0||n>r.getHeight()}var ih=32,ah=7;function oh(e){for(var t=0;e>=ih;)t|=e&1,e>>=1;return e+t}function sh(e,t,n,r){var i=t+1;if(i===n)return 1;if(r(e[i++],e[t])<0){for(;i<n&&r(e[i],e[i-1])<0;)i++;ch(e,t,i)}else for(;i<n&&r(e[i],e[i-1])>=0;)i++;return i-t}function ch(e,t,n){for(n--;t<n;){var r=e[t];e[t++]=e[n],e[n--]=r}}function lh(e,t,n,r,i){for(r===t&&r++;r<n;r++){for(var a=e[r],o=t,s=r,c;o<s;)c=o+s>>>1,i(a,e[c])<0?s=c:o=c+1;var l=r-o;switch(l){case 3:e[o+3]=e[o+2];case 2:e[o+2]=e[o+1];case 1:e[o+1]=e[o];break;default:for(;l>0;)e[o+l]=e[o+l-1],l--}e[o]=a}}function uh(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])>0){for(s=r-i;c<s&&a(e,t[n+i+c])>0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}else{for(s=i+1;c<s&&a(e,t[n+i-c])<=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])>0?o=u+1:c=u}return c}function dh(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])<0){for(s=i+1;c<s&&a(e,t[n+i-c])<0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}else{for(s=r-i;c<s&&a(e,t[n+i+c])>=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])<0?c=u:o=u+1}return c}function fh(e,t){var n=ah,r,i,a=0,o=[];r=[],i=[];function s(e,t){r[a]=e,i[a]=t,a+=1}function c(){for(;a>1;){var e=a-2;if(e>=1&&i[e-1]<=i[e]+i[e+1]||e>=2&&i[e-2]<=i[e]+i[e-1])i[e-1]<i[e+1]&&e--;else if(i[e]>i[e+1])break;u(e)}}function l(){for(;a>1;){var e=a-2;e>0&&i[e-1]<i[e+1]&&e--,u(e)}}function u(n){var o=r[n],s=i[n],c=r[n+1],l=i[n+1];i[n]=s+l,n===a-3&&(r[n+1]=r[n+2],i[n+1]=i[n+2]),a--;var u=dh(e[c],e,o,s,0,t);o+=u,s-=u,s!==0&&(l=uh(e[o+s-1],e,c,l,l-1,t),l!==0&&(s<=l?d(o,s,c,l):f(o,s,c,l)))}function d(r,i,a,s){var c=0;for(c=0;c<i;c++)o[c]=e[r+c];var l=0,u=a,d=r;if(e[d++]=e[u++],--s===0)for(c=0;c<i;c++)e[d+c]=o[l+c];else if(i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l]}else{for(var f=n,p,m,h;;){p=0,m=0,h=!1;do if(t(e[u],o[l])<0){if(e[d++]=e[u++],m++,p=0,--s===0){h=!0;break}}else if(e[d++]=o[l++],p++,m=0,--i===1){h=!0;break}while((p|m)<f);if(h)break;do{if(p=dh(e[u],o,l,i,0,t),p!==0){for(c=0;c<p;c++)e[d+c]=o[l+c];if(d+=p,l+=p,i-=p,i<=1){h=!0;break}}if(e[d++]=e[u++],--s===0){h=!0;break}if(m=uh(o[l],e,u,s,0,t),m!==0){for(c=0;c<m;c++)e[d+c]=e[u+c];if(d+=m,u+=m,s-=m,s===0){h=!0;break}}if(e[d++]=o[l++],--i===1){h=!0;break}f--}while(p>=ah||m>=ah);if(h)break;f<0&&(f=0),f+=2}if(n=f,n<1&&(n=1),i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l]}else if(i===0)throw Error();else for(c=0;c<i;c++)e[d+c]=o[l+c]}}function f(r,i,a,s){var c=0;for(c=0;c<s;c++)o[c]=e[a+c];var l=r+i-1,u=s-1,d=a+s-1,f=0,p=0;if(e[d--]=e[l--],--i===0)for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c];else if(s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u]}else{for(var m=n;;){var h=0,g=0,_=!1;do if(t(o[u],e[l])<0){if(e[d--]=e[l--],h++,g=0,--i===0){_=!0;break}}else if(e[d--]=o[u--],g++,h=0,--s===1){_=!0;break}while((h|g)<m);if(_)break;do{if(h=i-dh(o[u],e,r,i,i-1,t),h!==0){for(d-=h,l-=h,i-=h,p=d+1,f=l+1,c=h-1;c>=0;c--)e[p+c]=e[f+c];if(i===0){_=!0;break}}if(e[d--]=o[u--],--s===1){_=!0;break}if(g=s-uh(e[l],o,0,s,s-1,t),g!==0){for(d-=g,u-=g,s-=g,p=d+1,f=u+1,c=0;c<g;c++)e[p+c]=o[f+c];if(s<=1){_=!0;break}}if(e[d--]=e[l--],--i===0){_=!0;break}m--}while(h>=ah||g>=ah);if(_)break;m<0&&(m=0),m+=2}if(n=m,n<1&&(n=1),s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u]}else if(s===0)throw Error();else for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c]}}return{mergeRuns:c,forceMergeRuns:l,pushRun:s}}function ph(e,t,n,r){n||=0,r||=e.length;var i=r-n;if(!(i<2)){var a=0;if(i<ih)a=sh(e,n,r,t),lh(e,n,r,n+a,t);else{var o=fh(e,t),s=oh(i);do{if(a=sh(e,n,r,t),a<s){var c=i;c>s&&(c=s),lh(e,n,n+c,n+a,t),a=c}o.pushRun(n,a),o.mergeRuns(),i-=a,n+=a}while(i!==0);o.forceMergeRuns()}}}var mh=!1;function hh(){mh||(mh=!0,console.warn(`z / z2 / zlevel of displayable is invalid, which may cause unexpected errors`))}function gh(e,t){return e.zlevel===t.zlevel?e.z===t.z?e.z2-t.z2:e.z-t.z:e.zlevel-t.zlevel}var _h=function(){function e(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=gh}return e.prototype.traverse=function(e,t){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(e,t)},e.prototype.getDisplayList=function(e,t){t||=!1;var n=this._displayList;return(e||!n.length)&&this.updateDisplayList(t),n},e.prototype.updateDisplayList=function(e){this._displayListLen=0;for(var t=this._roots,n=this._displayList,r=0,i=t.length;r<i;r++)this._updateAndAddDisplayable(t[r],null,e);n.length=this._displayListLen,ph(n,gh)},e.prototype._updateAndAddDisplayable=function(e,t,n){if(!e.ignore||n){e.beforeUpdate(),e.update(),e.afterUpdate();var r=e.getClipPath();if(e.ignoreClip)t=null;else if(r){t=t?t.slice():[];for(var i=r,a=e;i;)i.parent=a,i.updateTransform(),t.push(i),a=i,i=i.getClipPath()}if(e.childrenRef){for(var o=e.childrenRef(),s=0;s<o.length;s++){var c=o[s];e.__dirty&&(c.__dirty|=1),this._updateAndAddDisplayable(c,t,n)}e.__dirty=0}else{var l=e;t&&t.length?l.__clipPaths=t:l.__clipPaths&&l.__clipPaths.length>0&&(l.__clipPaths=[]),isNaN(l.z)&&(hh(),l.z=0),isNaN(l.z2)&&(hh(),l.z2=0),isNaN(l.zlevel)&&(hh(),l.zlevel=0),this._displayList[this._displayListLen++]=l}var u=e.getDecalElement&&e.getDecalElement();u&&this._updateAndAddDisplayable(u,t,n);var d=e.getTextGuideLine();d&&this._updateAndAddDisplayable(d,t,n);var f=e.getTextContent();f&&this._updateAndAddDisplayable(f,t,n)}},e.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},e.prototype.delRoot=function(e){if(e instanceof Array)for(var t=0,n=e.length;t<n;t++)this.delRoot(e[t]);else{var r=Yf(this._roots,e);r>=0&&this._roots.splice(r,1)}},e.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},e.prototype.getRoots=function(){return this._roots},e.prototype.dispose=function(){this._displayList=null,this._roots=null},e}(),vh=W.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(e){return setTimeout(e,16)},yh={linear:function(e){return e},quadraticIn:function(e){return e*e},quadraticOut:function(e){return e*(2-e)},quadraticInOut:function(e){return(e*=2)<1?.5*e*e:-.5*(--e*(e-2)-1)},cubicIn:function(e){return e*e*e},cubicOut:function(e){return--e*e*e+1},cubicInOut:function(e){return(e*=2)<1?.5*e*e*e:.5*((e-=2)*e*e+2)},quarticIn:function(e){return e*e*e*e},quarticOut:function(e){return 1- --e*e*e*e},quarticInOut:function(e){return(e*=2)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2)},quinticIn:function(e){return e*e*e*e*e},quinticOut:function(e){return--e*e*e*e*e+1},quinticInOut:function(e){return(e*=2)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2)},sinusoidalIn:function(e){return 1-Math.cos(e*Math.PI/2)},sinusoidalOut:function(e){return Math.sin(e*Math.PI/2)},sinusoidalInOut:function(e){return .5*(1-Math.cos(Math.PI*e))},exponentialIn:function(e){return e===0?0:1024**(e-1)},exponentialOut:function(e){return e===1?1:1-2**(-10*e)},exponentialInOut:function(e){return e===0?0:e===1?1:(e*=2)<1?.5*1024**(e-1):.5*(-(2**(-10*(e-1)))+2)},circularIn:function(e){return 1-Math.sqrt(1-e*e)},circularOut:function(e){return Math.sqrt(1- --e*e)},circularInOut:function(e){return(e*=2)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1)},elasticIn:function(e){var t,n=.1,r=.4;return e===0?0:e===1?1:(!n||n<1?(n=1,t=r/4):t=r*Math.asin(1/n)/(2*Math.PI),-(n*2**(10*--e)*Math.sin((e-t)*(2*Math.PI)/r)))},elasticOut:function(e){var t,n=.1,r=.4;return e===0?0:e===1?1:(!n||n<1?(n=1,t=r/4):t=r*Math.asin(1/n)/(2*Math.PI),n*2**(-10*e)*Math.sin((e-t)*(2*Math.PI)/r)+1)},elasticInOut:function(e){var t,n=.1,r=.4;return e===0?0:e===1?1:(!n||n<1?(n=1,t=r/4):t=r*Math.asin(1/n)/(2*Math.PI),(e*=2)<1?-.5*(n*2**(10*--e)*Math.sin((e-t)*(2*Math.PI)/r)):n*2**(-10*--e)*Math.sin((e-t)*(2*Math.PI)/r)*.5+1)},backIn:function(e){var t=1.70158;return e*e*((t+1)*e-t)},backOut:function(e){var t=1.70158;return--e*e*((t+1)*e+t)+1},backInOut:function(e){var t=2.5949095;return(e*=2)<1?.5*(e*e*((t+1)*e-t)):.5*((e-=2)*e*((t+1)*e+t)+2)},bounceIn:function(e){return 1-yh.bounceOut(1-e)},bounceOut:function(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},bounceInOut:function(e){return e<.5?yh.bounceIn(e*2)*.5:yh.bounceOut(e*2-1)*.5+.5}},bh=Math.pow,xh=Math.sqrt,Sh=1e-8,Ch=1e-4,wh=xh(3),Th=1/3,Eh=Pp(),Dh=Pp(),Oh=Pp();function kh(e){return e>-Sh&&e<Sh}function Ah(e){return e>Sh||e<-Sh}function jh(e,t,n,r,i){var a=1-i;return a*a*(a*e+3*i*t)+i*i*(i*r+3*a*n)}function Mh(e,t,n,r,i){var a=1-i;return 3*(((t-e)*a+2*(n-t)*i)*a+(r-n)*i*i)}function Nh(e,t,n,r,i,a){var o=r+3*(t-n)-e,s=3*(n-t*2+e),c=3*(t-e),l=e-i,u=s*s-3*o*c,d=s*c-9*o*l,f=c*c-3*s*l,p=0;if(kh(u)&&kh(d)){if(kh(s))a[0]=0;else{var m=-c/s;m>=0&&m<=1&&(a[p++]=m)}}else{var h=d*d-4*u*f;if(kh(h)){var g=d/u,m=-s/o+g,_=-g/2;m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_)}else if(h>0){var v=xh(h),y=u*s+1.5*o*(-d+v),b=u*s+1.5*o*(-d-v);y=y<0?-bh(-y,Th):bh(y,Th),b=b<0?-bh(-b,Th):bh(b,Th);var m=(-s-(y+b))/(3*o);m>=0&&m<=1&&(a[p++]=m)}else{var x=(2*u*s-3*o*d)/(2*xh(u*u*u)),S=Math.acos(x)/3,C=xh(u),w=Math.cos(S),m=(-s-2*C*w)/(3*o),_=(-s+C*(w+wh*Math.sin(S)))/(3*o),T=(-s+C*(w-wh*Math.sin(S)))/(3*o);m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_),T>=0&&T<=1&&(a[p++]=T)}}return p}function Ph(e,t,n,r,i){var a=6*n-12*t+6*e,o=9*t+3*r-3*e-9*n,s=3*t-3*e,c=0;if(kh(o)){if(Ah(a)){var l=-s/a;l>=0&&l<=1&&(i[c++]=l)}}else{var u=a*a-4*o*s;if(kh(u))i[0]=-a/(2*o);else if(u>0){var d=xh(u),l=(-a+d)/(2*o),f=(-a-d)/(2*o);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function Fh(e,t,n,r,i,a){var o=(t-e)*i+e,s=(n-t)*i+t,c=(r-n)*i+n,l=(s-o)*i+o,u=(c-s)*i+s,d=(u-l)*i+l;a[0]=e,a[1]=o,a[2]=l,a[3]=d,a[4]=d,a[5]=u,a[6]=c,a[7]=r}function Ih(e,t,n,r,i,a,o,s,c,l,u){var d,f=.005,p=1/0,m,h,g,_;Eh[0]=c,Eh[1]=l;for(var v=0;v<1;v+=.05)Dh[0]=jh(e,n,i,o,v),Dh[1]=jh(t,r,a,s,v),g=Jp(Eh,Dh),g<p&&(d=v,p=g);p=1/0;for(var y=0;y<32&&!(f<Ch);y++)m=d-f,h=d+f,Dh[0]=jh(e,n,i,o,m),Dh[1]=jh(t,r,a,s,m),g=Jp(Dh,Eh),m>=0&&g<p?(d=m,p=g):(Oh[0]=jh(e,n,i,o,h),Oh[1]=jh(t,r,a,s,h),_=Jp(Oh,Eh),h<=1&&_<p?(d=h,p=_):f*=.5);return u&&(u[0]=jh(e,n,i,o,d),u[1]=jh(t,r,a,s,d)),xh(p)}function Lh(e,t,n,r,i,a,o,s,c){for(var l=e,u=t,d=0,f=1/c,p=1;p<=c;p++){var m=p*f,h=jh(e,n,i,o,m),g=jh(t,r,a,s,m),_=h-l,v=g-u;d+=Math.sqrt(_*_+v*v),l=h,u=g}return d}function Rh(e,t,n,r){var i=1-r;return i*(i*e+2*r*t)+r*r*n}function zh(e,t,n,r){return 2*((1-r)*(t-e)+r*(n-t))}function Bh(e,t,n,r,i){var a=e-2*t+n,o=2*(t-e),s=e-r,c=0;if(kh(a)){if(Ah(o)){var l=-s/o;l>=0&&l<=1&&(i[c++]=l)}}else{var u=o*o-4*a*s;if(kh(u)){var l=-o/(2*a);l>=0&&l<=1&&(i[c++]=l)}else if(u>0){var d=xh(u),l=(-o+d)/(2*a),f=(-o-d)/(2*a);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function Vh(e,t,n){var r=e+n-2*t;return r===0?.5:(e-t)/r}function Hh(e,t,n,r,i){var a=(t-e)*r+e,o=(n-t)*r+t,s=(o-a)*r+a;i[0]=e,i[1]=a,i[2]=s,i[3]=s,i[4]=o,i[5]=n}function Uh(e,t,n,r,i,a,o,s,c){var l,u=.005,d=1/0;Eh[0]=o,Eh[1]=s;for(var f=0;f<1;f+=.05){Dh[0]=Rh(e,n,i,f),Dh[1]=Rh(t,r,a,f);var p=Jp(Eh,Dh);p<d&&(l=f,d=p)}d=1/0;for(var m=0;m<32&&!(u<Ch);m++){var h=l-u,g=l+u;Dh[0]=Rh(e,n,i,h),Dh[1]=Rh(t,r,a,h);var p=Jp(Dh,Eh);if(h>=0&&p<d)l=h,d=p;else{Oh[0]=Rh(e,n,i,g),Oh[1]=Rh(t,r,a,g);var _=Jp(Oh,Eh);g<=1&&_<d?(l=g,d=_):u*=.5}}return c&&(c[0]=Rh(e,n,i,l),c[1]=Rh(t,r,a,l)),xh(d)}function Wh(e,t,n,r,i,a,o){for(var s=e,c=t,l=0,u=1/o,d=1;d<=o;d++){var f=d*u,p=Rh(e,n,i,f),m=Rh(t,r,a,f),h=p-s,g=m-c;l+=Math.sqrt(h*h+g*g),s=p,c=m}return l}var Gh=/cubic-bezier\(([0-9,\.e ]+)\)/;function Kh(e){var t=e&&Gh.exec(e);if(t){var n=t[1].split(`,`),r=+bp(n[0]),i=+bp(n[1]),a=+bp(n[2]),o=+bp(n[3]);if(isNaN(r+i+a+o))return;var s=[];return function(e){return e<=0?0:e>=1?1:Nh(0,r,a,1,e,s)&&jh(0,i,o,1,s[0])}}}var qh=function(){function e(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||Mp,this.ondestroy=e.ondestroy||Mp,this.onrestart=e.onrestart||Mp,e.easing&&this.setEasing(e.easing)}return e.prototype.step=function(e,t){if(this._inited||=(this._startTime=e+this._delay,!0),this._paused)this._pausedTime+=t;else{var n=this._life,r=e-this._startTime-this._pausedTime,i=r/n;i<0&&(i=0),i=Math.min(i,1);var a=this.easingFunc,o=a?a(i):i;if(this.onframe(o),i===1){if(this.loop){var s=r%n;this._startTime=e-s,this._pausedTime=0,this.onrestart()}else return!0}return!1}},e.prototype.pause=function(){this._paused=!0},e.prototype.resume=function(){this._paused=!1},e.prototype.setEasing=function(e){this.easing=e,this.easingFunc=op(e)?e:yh[e]||Kh(e)},e}(),Jh=function(){function e(e){this.value=e}return e}(),Yh=function(){function e(){this._len=0}return e.prototype.insert=function(e){var t=new Jh(e);return this.insertEntry(t),t},e.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++},e.prototype.remove=function(e){var t=e.prev,n=e.next;t?t.next=n:this.head=n,n?n.prev=t:this.tail=t,e.next=e.prev=null,this._len--},e.prototype.len=function(){return this._len},e.prototype.clear=function(){this.head=this.tail=null,this._len=0},e}(),Xh=function(){function e(e){this._list=new Yh,this._maxSize=10,this._map={},this._maxSize=e}return e.prototype.put=function(e,t){var n=this._list,r=this._map,i=null;if(r[e]==null){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var s=n.head;n.remove(s),delete r[s.key],i=s.value,this._lastRemovedEntry=s}o?o.value=t:o=new Jh(t),o.key=e,n.insertEntry(o),r[e]=o}return i},e.prototype.get=function(e){var t=this._map[e],n=this._list;if(t!=null)return t!==n.tail&&(n.remove(t),n.insertEntry(t)),t.value},e.prototype.clear=function(){this._list.clear(),this._map={}},e.prototype.len=function(){return this._list.len()},e}(),Zh={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 Qh(e){return e=Math.round(e),e<0?0:e>255?255:e}function $h(e){return e=Math.round(e),e<0?0:e>360?360:e}function eg(e){return e<0?0:e>1?1:e}function tg(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?Qh(parseFloat(t)/100*255):Qh(parseInt(t,10))}function ng(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?eg(parseFloat(t)/100):eg(parseFloat(t))}function rg(e,t,n){return n<0?n+=1:n>1&&--n,n*6<1?e+(t-e)*n*6:n*2<1?t:n*3<2?e+(t-e)*(2/3-n)*6:e}function ig(e,t,n){return e+(t-e)*n}function ag(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e}function og(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}var sg=new Xh(20),cg=null;function lg(e,t){cg&&og(cg,t),cg=sg.put(e,cg||t.slice())}function ug(e,t){if(e){t||=[];var n=sg.get(e);if(n)return og(t,n);e+=``;var r=e.replace(/ /g,``).toLowerCase();if(r in Zh)return og(t,Zh[r]),lg(e,t),t;var i=r.length;if(r.charAt(0)===`#`){if(i===4||i===5){var a=parseInt(r.slice(1,4),16);if(!(a>=0&&a<=4095)){ag(t,0,0,0,1);return}return ag(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,i===5?parseInt(r.slice(4),16)/15:1),lg(e,t),t}if(i===7||i===9){var a=parseInt(r.slice(1,7),16);if(!(a>=0&&a<=16777215)){ag(t,0,0,0,1);return}return ag(t,(a&16711680)>>16,(a&65280)>>8,a&255,i===9?parseInt(r.slice(7),16)/255:1),lg(e,t),t}}else{var o=r.indexOf(`(`),s=r.indexOf(`)`);if(o!==-1&&s+1===i){var c=r.substr(0,o),l=r.substr(o+1,s-(o+1)).split(`,`),u=1;switch(c){case`rgba`:if(l.length!==4)return l.length===3?ag(t,+l[0],+l[1],+l[2],1):ag(t,0,0,0,1);u=ng(l.pop());case`rgb`:if(l.length>=3)return ag(t,tg(l[0]),tg(l[1]),tg(l[2]),l.length===3?u:ng(l[3])),lg(e,t),t;ag(t,0,0,0,1);return;case`hsla`:if(l.length!==4){ag(t,0,0,0,1);return}return l[3]=ng(l[3]),dg(l,t),lg(e,t),t;case`hsl`:if(l.length!==3){ag(t,0,0,0,1);return}return dg(l,t),lg(e,t),t;default:return}}ag(t,0,0,0,1)}}}function dg(e,t){var n=(parseFloat(e[0])%360+360)%360/360,r=ng(e[1]),i=ng(e[2]),a=i<=.5?i*(r+1):i+r-i*r,o=i*2-a;return t||=[],ag(t,Qh(rg(o,a,n+1/3)*255),Qh(rg(o,a,n)*255),Qh(rg(o,a,n-1/3)*255),1),e.length===4&&(t[3]=e[3]),t}function fg(e){if(e){var t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=a-i,s=(a+i)/2,c,l;if(o===0)c=0,l=0;else{l=s<.5?o/(a+i):o/(2-a-i);var u=((a-t)/6+o/2)/o,d=((a-n)/6+o/2)/o,f=((a-r)/6+o/2)/o;t===a?c=f-d:n===a?c=1/3+u-f:r===a&&(c=2/3+d-u),c<0&&(c+=1),c>1&&--c}var p=[c*360,l,s];return e[3]!=null&&p.push(e[3]),p}}function pg(e,t){var n=ug(e);if(n){for(var r=0;r<3;r++)t<0?n[r]=n[r]*(1-t)|0:n[r]=(255-n[r])*t+n[r]|0,n[r]>255?n[r]=255:n[r]<0&&(n[r]=0);return _g(n,n.length===4?`rgba`:`rgb`)}}function mg(e,t,n){if(t&&t.length&&e>=0&&e<=1){n||=[];var r=e*(t.length-1),i=Math.floor(r),a=Math.ceil(r),o=t[i],s=t[a],c=r-i;return n[0]=Qh(ig(o[0],s[0],c)),n[1]=Qh(ig(o[1],s[1],c)),n[2]=Qh(ig(o[2],s[2],c)),n[3]=eg(ig(o[3],s[3],c)),n}}function hg(e,t,n,r){var i=ug(e);if(e)return i=fg(i),t!=null&&(i[0]=$h(t)),n!=null&&(i[1]=ng(n)),r!=null&&(i[2]=ng(r)),_g(dg(i),`rgba`)}function gg(e,t){var n=ug(e);if(n&&t!=null)return n[3]=eg(t),_g(n,`rgba`)}function _g(e,t){if(e&&e.length){var n=e[0]+`,`+e[1]+`,`+e[2];return(t===`rgba`||t===`hsva`||t===`hsla`)&&(n+=`,`+e[3]),t+`(`+n+`)`}}function vg(e,t){var n=ug(e);return n?(.299*n[0]+.587*n[1]+.114*n[2])*n[3]/255+(1-n[3])*t:0}var yg=new Xh(100);function bg(e){if(Y(e)){var t=yg.get(e);return t||(t=pg(e,-.1),yg.put(e,t)),t}if(fp(e)){var n=K({},e);return n.colorStops=$f(e.colorStops,function(e){return{offset:e.offset,color:pg(e.color,-.1)}}),n}return e}function xg(e){return e.type===`linear`}function Sg(e){return e.type===`radial`}(function(){return W.hasGlobalWindow&&op(window.btoa)?function(e){return window.btoa(unescape(encodeURIComponent(e)))}:typeof Buffer<`u`?function(e){return Buffer.from(e).toString(`base64`)}:function(e){return null}})();var Cg=Array.prototype.slice;function wg(e,t,n){return(t-e)*n+e}function Tg(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=wg(t[a],n[a],r);return e}function Eg(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=wg(t[o][s],n[o][s],r)}return e}function Dg(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=t[a]+n[a]*r;return e}function Og(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=t[o][s]+n[o][s]*r}return e}function kg(e,t){for(var n=e.length,r=t.length,i=n>r?t:e,a=Math.min(n,r),o=i[a-1]||{color:[0,0,0,0],offset:0},s=a;s<Math.max(n,r);s++)i.push({offset:o.offset,color:o.color.slice()})}function Ag(e,t,n){var r=e,i=t;if(r.push&&i.push){var a=r.length,o=i.length;if(a!==o){if(a>o)r.length=o;else for(var s=a;s<o;s++)r.push(n===1?i[s]:Cg.call(i[s]))}for(var c=r[0]&&r[0].length,s=0;s<r.length;s++)if(n===1)isNaN(r[s])&&(r[s]=i[s]);else for(var l=0;l<c;l++)isNaN(r[s][l])&&(r[s][l]=i[s][l])}}function jg(e){if(Qf(e)){var t=e.length;if(Qf(e[0])){for(var n=[],r=0;r<t;r++)n.push(Cg.call(e[r]));return n}return Cg.call(e)}return e}function Mg(e){return e[0]=Math.floor(e[0])||0,e[1]=Math.floor(e[1])||0,e[2]=Math.floor(e[2])||0,e[3]=e[3]==null?1:e[3],`rgba(`+e.join(`,`)+`)`}function Ng(e){return Qf(e&&e[0])?2:1}var Pg=0,Fg=1,Ig=2,Lg=3,Rg=4,zg=5,Bg=6;function Vg(e){return e===Rg||e===zg}function Hg(e){return e===Fg||e===Ig}var Ug=[0,0,0,0],Wg=function(){function e(e){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=e}return e.prototype.isFinished=function(){return this._finished},e.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},e.prototype.needsAnimate=function(){return this.keyframes.length>=1},e.prototype.getAdditiveTrack=function(){return this._additiveTrack},e.prototype.addKeyframe=function(e,t,n){this._needsSort=!0;var r=this.keyframes,i=r.length,a=!1,o=Bg,s=t;if(Qf(t)){var c=Ng(t);o=c,(c===1&&!cp(t[0])||c===2&&!cp(t[0][0]))&&(a=!0)}else if(cp(t)&&!mp(t))o=Pg;else if(Y(t)){if(!isNaN(+t))o=Pg;else{var l=ug(t);l&&(s=l,o=Lg)}}else if(fp(t)){var u=K({},s);u.colorStops=$f(t.colorStops,function(e){return{offset:e.offset,color:ug(e.color)}}),xg(t)?o=Rg:Sg(t)&&(o=zg),s=u}i===0?this.valType=o:(o!==this.valType||o===Bg)&&(a=!0),this.discrete=this.discrete||a;var d={time:e,value:s,rawValue:t,percent:0};return n&&(d.easing=n,d.easingFunc=op(n)?n:yh[n]||Kh(n)),r.push(d),d},e.prototype.prepare=function(e,t){var n=this.keyframes;this._needsSort&&n.sort(function(e,t){return e.time-t.time});for(var r=this.valType,i=n.length,a=n[i-1],o=this.discrete,s=Hg(r),c=Vg(r),l=0;l<i;l++){var u=n[l],d=u.value,f=a.value;u.percent=u.time/e,o||(s&&l!==i-1?Ag(d,f,r):c&&kg(d.colorStops,f.colorStops))}if(!o&&r!==zg&&t&&this.needsAnimate()&&t.needsAnimate()&&r===t.valType&&!t._finished){this._additiveTrack=t;for(var p=n[0].value,l=0;l<i;l++)r===Pg?n[l].additiveValue=n[l].value-p:r===Lg?n[l].additiveValue=Dg([],n[l].value,p,-1):Hg(r)&&(n[l].additiveValue=r===Fg?Dg([],n[l].value,p,-1):Og([],n[l].value,p,-1))}},e.prototype.step=function(e,t){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n=this._additiveTrack!=null,r=n?`additiveValue`:`value`,i=this.valType,a=this.keyframes,o=a.length,s=this.propName,c=i===Lg,l,u=this._lastFr,d=Math.min,f,p;if(o===1)f=p=a[0];else{if(t<0)l=0;else if(t<this._lastFrP){for(l=d(u+1,o-1);l>=0&&!(a[l].percent<=t);l--);l=d(l,o-2)}else{for(l=u;l<o&&!(a[l].percent>t);l++);l=d(l-1,o-2)}p=a[l+1],f=a[l]}if(f&&p){this._lastFr=l,this._lastFrP=t;var m=p.percent-f.percent,h=m===0?1:d((t-f.percent)/m,1);p.easingFunc&&(h=p.easingFunc(h));var g=n?this._additiveValue:c?Ug:e[s];if((Hg(i)||c)&&!g&&(g=this._additiveValue=[]),this.discrete)e[s]=h<1?f.rawValue:p.rawValue;else if(Hg(i))i===Fg?Tg(g,f[r],p[r],h):Eg(g,f[r],p[r],h);else if(Vg(i)){var _=f[r],v=p[r],y=i===Rg;e[s]={type:y?`linear`:`radial`,x:wg(_.x,v.x,h),y:wg(_.y,v.y,h),colorStops:$f(_.colorStops,function(e,t){var n=v.colorStops[t];return{offset:wg(e.offset,n.offset,h),color:Mg(Tg([],e.color,n.color,h))}}),global:v.global},y?(e[s].x2=wg(_.x2,v.x2,h),e[s].y2=wg(_.y2,v.y2,h)):e[s].r=wg(_.r,v.r,h)}else if(c)Tg(g,f[r],p[r],h),n||(e[s]=Mg(g));else{var b=wg(f[r],p[r],h);n?this._additiveValue=b:e[s]=b}n&&this._addToTarget(e)}}},e.prototype._addToTarget=function(e){var t=this.valType,n=this.propName,r=this._additiveValue;t===Pg?e[n]=e[n]+r:t===Lg?(ug(e[n],Ug),Dg(Ug,Ug,r,1),e[n]=Mg(Ug)):t===Fg?Dg(e[n],e[n],r,1):t===Ig&&Og(e[n],e[n],r,1)},e}(),Gg=function(){function e(e,t,n,r){this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=e,this._loop=t,t&&r?Kf(`Can' use additive animation on looped animation.`):(this._additiveAnimators=r,this._allowDiscrete=n)}return e.prototype.getMaxTime=function(){return this._maxTime},e.prototype.getDelay=function(){return this._delay},e.prototype.getLoop=function(){return this._loop},e.prototype.getTarget=function(){return this._target},e.prototype.changeTarget=function(e){this._target=e},e.prototype.when=function(e,t,n){return this.whenWithKeys(e,t,np(t),n)},e.prototype.whenWithKeys=function(e,t,n,r){for(var i=this._tracks,a=0;a<n.length;a++){var o=n[a],s=i[o];if(!s){s=i[o]=new Wg(o);var c=void 0,l=this._getAdditiveTrack(o);if(l){var u=l.keyframes,d=u[u.length-1];c=d&&d.value,l.valType===Lg&&c&&(c=Mg(c))}else c=this._target[o];if(c==null)continue;e>0&&s.addKeyframe(0,jg(c),r),this._trackKeys.push(o)}s.addKeyframe(e,jg(t[o]),r)}return this._maxTime=Math.max(this._maxTime,e),this},e.prototype.pause=function(){this._clip.pause(),this._paused=!0},e.prototype.resume=function(){this._clip.resume(),this._paused=!1},e.prototype.isPaused=function(){return!!this._paused},e.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},e.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var e=this._doneCbs;if(e)for(var t=e.length,n=0;n<t;n++)e[n].call(this)},e.prototype._abortedCallback=function(){this._setTracksFinished();var e=this.animation,t=this._abortedCbs;if(e&&e.removeClip(this._clip),this._clip=null,t)for(var n=0;n<t.length;n++)t[n].call(this)},e.prototype._setTracksFinished=function(){for(var e=this._tracks,t=this._trackKeys,n=0;n<t.length;n++)e[t[n]].setFinished()},e.prototype._getAdditiveTrack=function(e){var t,n=this._additiveAnimators;if(n)for(var r=0;r<n.length;r++){var i=n[r].getTrack(e);i&&(t=i)}return t},e.prototype.start=function(e){if(!(this._started>0)){this._started=1;for(var t=this,n=[],r=this._maxTime||0,i=0;i<this._trackKeys.length;i++){var a=this._trackKeys[i],o=this._tracks[a],s=this._getAdditiveTrack(a),c=o.keyframes,l=c.length;if(o.prepare(r,s),o.needsAnimate()){if(!this._allowDiscrete&&o.discrete){var u=c[l-1];u&&(t._target[o.propName]=u.rawValue),o.setFinished()}else n.push(o)}}if(n.length||this._force){var d=new qh({life:r,loop:this._loop,delay:this._delay||0,onframe:function(e){t._started=2;var r=t._additiveAnimators;if(r){for(var i=!1,a=0;a<r.length;a++)if(r[a]._clip){i=!0;break}i||(t._additiveAnimators=null)}for(var a=0;a<n.length;a++)n[a].step(t._target,e);var o=t._onframeCbs;if(o)for(var a=0;a<o.length;a++)o[a](t._target,e)},ondestroy:function(){t._doneCallback()}});this._clip=d,this.animation&&this.animation.addClip(d),e&&d.setEasing(e)}else this._doneCallback();return this}},e.prototype.stop=function(e){if(this._clip){var t=this._clip;e&&t.onframe(1),this._abortedCallback()}},e.prototype.delay=function(e){return this._delay=e,this},e.prototype.during=function(e){return e&&(this._onframeCbs||=[],this._onframeCbs.push(e)),this},e.prototype.done=function(e){return e&&(this._doneCbs||=[],this._doneCbs.push(e)),this},e.prototype.aborted=function(e){return e&&(this._abortedCbs||=[],this._abortedCbs.push(e)),this},e.prototype.getClip=function(){return this._clip},e.prototype.getTrack=function(e){return this._tracks[e]},e.prototype.getTracks=function(){var e=this;return $f(this._trackKeys,function(t){return e._tracks[t]})},e.prototype.stopTracks=function(e,t){if(!e.length||!this._clip)return!0;for(var n=this._tracks,r=this._trackKeys,i=0;i<e.length;i++){var a=n[e[i]];a&&!a.isFinished()&&(t?a.step(this._target,1):this._started===1&&a.step(this._target,0),a.setFinished())}for(var o=!0,i=0;i<r.length;i++)if(!n[r[i]].isFinished()){o=!1;break}return o&&this._abortedCallback(),o},e.prototype.saveTo=function(e,t,n){if(e){t||=this._trackKeys;for(var r=0;r<t.length;r++){var i=t[r],a=this._tracks[i];if(a&&!a.isFinished()){var o=a.keyframes,s=o[n?0:o.length-1];s&&(e[i]=jg(s.rawValue))}}}},e.prototype.__changeFinalValue=function(e,t){t||=np(e);for(var n=0;n<t.length;n++){var r=t[n],i=this._tracks[r];if(i){var a=i.keyframes;if(a.length>1){var o=a.pop();i.addKeyframe(o.time,e[r]),i.prepare(this._maxTime,i.getAdditiveTrack())}}}},e}();function Kg(){return new Date().getTime()}var qg=function(e){U(t,e);function t(t){var n=e.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,t||={},n.stage=t.stage||{},n}return t.prototype.addClip=function(e){e.animation&&this.removeClip(e),this._head?(this._tail.next=e,e.prev=this._tail,e.next=null,this._tail=e):this._head=this._tail=e,e.animation=this},t.prototype.addAnimator=function(e){e.animation=this;var t=e.getClip();t&&this.addClip(t)},t.prototype.removeClip=function(e){if(e.animation){var t=e.prev,n=e.next;t?t.next=n:this._head=n,n?n.prev=t:this._tail=t,e.next=e.prev=e.animation=null}},t.prototype.removeAnimator=function(e){var t=e.getClip();t&&this.removeClip(t),e.animation=null},t.prototype.update=function(e){for(var t=Kg()-this._pausedTime,n=t-this._time,r=this._head;r;){var i=r.next;r.step(t,n)&&(r.ondestroy(),this.removeClip(r)),r=i}this._time=t,e||(this.trigger(`frame`,n),this.stage.update&&this.stage.update())},t.prototype._startLoop=function(){var e=this;this._running=!0;function t(){e._running&&(vh(t),!e._paused&&e.update())}vh(t)},t.prototype.start=function(){this._running||(this._time=Kg(),this._pausedTime=0,this._startLoop())},t.prototype.stop=function(){this._running=!1},t.prototype.pause=function(){this._paused||=(this._pauseStart=Kg(),!0)},t.prototype.resume=function(){this._paused&&=(this._pausedTime+=Kg()-this._pauseStart,!1)},t.prototype.clear=function(){for(var e=this._head;e;){var t=e.next;e.prev=e.next=e.animation=null,e=t}this._head=this._tail=null},t.prototype.isFinished=function(){return this._head==null},t.prototype.animate=function(e,t){t||={},this.start();var n=new Gg(e,t.loop);return this.addAnimator(n),n},t}(em),Jg=300,Yg=W.domSupported,Xg=(function(){var e=[`click`,`dblclick`,`mousewheel`,`wheel`,`mouseout`,`mouseup`,`mousedown`,`mousemove`,`contextmenu`],t=[`touchstart`,`touchend`,`touchmove`],n={pointerdown:1,pointerup:1,pointermove:1,pointerout:1};return{mouse:e,touch:t,pointer:$f(e,function(e){var t=e.replace(`mouse`,`pointer`);return n.hasOwnProperty(t)?t:e})}})(),Zg={mouse:[`mousemove`,`mouseup`],pointer:[`pointermove`,`pointerup`]},Qg=!1;function $g(e){var t=e.pointerType;return t===`pen`||t===`touch`}function e_(e){e.touching=!0,e.touchTimer!=null&&(clearTimeout(e.touchTimer),e.touchTimer=null),e.touchTimer=setTimeout(function(){e.touching=!1,e.touchTimer=null},700)}function t_(e){e&&(e.zrByTouch=!0)}function n_(e,t){return bm(e.dom,new i_(e,t),!0)}function r_(e,t){for(var n=t,r=!1;n&&n.nodeType!==9&&!(r=n.domBelongToZr||n!==t&&n===e.painterRoot);)n=n.parentNode;return r}var i_=function(){function e(e,t){this.stopPropagation=Mp,this.stopImmediatePropagation=Mp,this.preventDefault=Mp,this.type=t.type,this.target=this.currentTarget=e.dom,this.pointerType=t.pointerType,this.clientX=t.clientX,this.clientY=t.clientY}return e}(),a_={mousedown:function(e){e=bm(this.dom,e),this.__mayPointerCapture=[e.zrX,e.zrY],this.trigger(`mousedown`,e)},mousemove:function(e){e=bm(this.dom,e);var t=this.__mayPointerCapture;t&&(e.zrX!==t[0]||e.zrY!==t[1])&&this.__togglePointerCapture(!0),this.trigger(`mousemove`,e)},mouseup:function(e){e=bm(this.dom,e),this.__togglePointerCapture(!1),this.trigger(`mouseup`,e)},mouseout:function(e){e=bm(this.dom,e);var t=e.toElement||e.relatedTarget;r_(this,t)||(this.__pointerCapturing&&(e.zrEventControl=`no_globalout`),this.trigger(`mouseout`,e))},wheel:function(e){Qg=!0,e=bm(this.dom,e),this.trigger(`mousewheel`,e)},mousewheel:function(e){Qg||(e=bm(this.dom,e),this.trigger(`mousewheel`,e))},touchstart:function(e){e=bm(this.dom,e),t_(e),this.__lastTouchMoment=new Date,this.handler.processGesture(e,`start`),a_.mousemove.call(this,e),a_.mousedown.call(this,e)},touchmove:function(e){e=bm(this.dom,e),t_(e),this.handler.processGesture(e,`change`),a_.mousemove.call(this,e)},touchend:function(e){e=bm(this.dom,e),t_(e),this.handler.processGesture(e,`end`),a_.mouseup.call(this,e),+new Date-this.__lastTouchMoment<Jg&&a_.click.call(this,e)},pointerdown:function(e){a_.mousedown.call(this,e)},pointermove:function(e){$g(e)||a_.mousemove.call(this,e)},pointerup:function(e){a_.mouseup.call(this,e)},pointerout:function(e){$g(e)||a_.mouseout.call(this,e)}};q([`click`,`dblclick`,`contextmenu`],function(e){a_[e]=function(t){t=bm(this.dom,t),this.trigger(e,t)}});var o_={pointermove:function(e){$g(e)||o_.mousemove.call(this,e)},pointerup:function(e){o_.mouseup.call(this,e)},mousemove:function(e){this.trigger(`mousemove`,e)},mouseup:function(e){var t=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger(`mouseup`,e),t&&(e.zrEventControl=`only_globalout`,this.trigger(`mouseout`,e))}};function s_(e,t){var n=t.domHandlers;W.pointerEventsSupported?q(Xg.pointer,function(r){l_(t,r,function(t){n[r].call(e,t)})}):(W.touchEventsSupported&&q(Xg.touch,function(r){l_(t,r,function(i){n[r].call(e,i),e_(t)})}),q(Xg.mouse,function(r){l_(t,r,function(i){i=ym(i),t.touching||n[r].call(e,i)})}))}function c_(e,t){W.pointerEventsSupported?q(Zg.pointer,n):W.touchEventsSupported||q(Zg.mouse,n);function n(n){function r(r){r=ym(r),r_(e,r.target)||(r=n_(e,r),t.domHandlers[n].call(e,r))}l_(t,n,r,{capture:!0})}}function l_(e,t,n,r){e.mounted[t]=n,e.listenerOpts[t]=r,Sm(e.domTarget,t,n,r)}function u_(e){var t=e.mounted;for(var n in t)t.hasOwnProperty(n)&&Cm(e.domTarget,n,t[n],e.listenerOpts[n]);e.mounted={}}var d_=function(){function e(e,t){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=e,this.domHandlers=t}return e}(),f_=function(e){U(t,e);function t(t,n){var r=e.call(this)||this;return r.__pointerCapturing=!1,r.dom=t,r.painterRoot=n,r._localHandlerScope=new d_(t,a_),Yg&&(r._globalHandlerScope=new d_(document,o_)),s_(r,r._localHandlerScope),r}return t.prototype.dispose=function(){u_(this._localHandlerScope),Yg&&u_(this._globalHandlerScope)},t.prototype.setCursor=function(e){this.dom.style&&(this.dom.style.cursor=e||`default`)},t.prototype.__togglePointerCapture=function(e){if(this.__mayPointerCapture=null,Yg&&+this.__pointerCapturing^e){this.__pointerCapturing=e;var t=this._globalHandlerScope;e?c_(this,t):u_(t)}},t}(em),p_=1;W.hasGlobalWindow&&(p_=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var m_=p_,h_=.4,g_=`#333`,__=`#ccc`,v_=`#eee`,y_=jm,b_=5e-5;function x_(e){return e>b_||e<-b_}var S_=[],C_=[],w_=Am(),T_=Math.abs,E_=function(){function e(){}return e.prototype.getLocalTransform=function(t){return e.getLocalTransform(this,t)},e.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},e.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},e.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},e.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},e.prototype.needLocalTransform=function(){return x_(this.rotation)||x_(this.x)||x_(this.y)||x_(this.scaleX-1)||x_(this.scaleY-1)||x_(this.skewX)||x_(this.skewY)},e.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),n=this.transform;t||e?(n||=Am(),t?this.getLocalTransform(n):y_(n),e&&(t?Nm(n,e,n):Mm(n,e)),this.transform=n,this._resolveGlobalScaleRatio(n)):n&&(y_(n),this.invTransform=null)},e.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(t!=null&&t!==1){this.getGlobalScale(S_);var n=S_[0]<0?-1:1,r=S_[1]<0?-1:1,i=((S_[0]-n)*t+n)/S_[0]||0,a=((S_[1]-r)*t+r)/S_[1]||0;e[0]*=i,e[1]*=i,e[2]*=a,e[3]*=a}this.invTransform=this.invTransform||Am(),Lm(this.invTransform,e)},e.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},e.prototype.setLocalTransform=function(e){if(e){var t=e[0]*e[0]+e[1]*e[1],n=e[2]*e[2]+e[3]*e[3],r=Math.atan2(e[1],e[0]),i=Math.PI/2+r-Math.atan2(e[3],e[2]);n=Math.sqrt(n)*Math.cos(i),t=Math.sqrt(t),this.skewX=i,this.skewY=0,this.rotation=-r,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=n,this.originX=0,this.originY=0}},e.prototype.decomposeTransform=function(){if(this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(e.invTransform=e.invTransform||Am(),Nm(C_,e.invTransform,t),t=C_);var n=this.originX,r=this.originY;(n||r)&&(w_[4]=n,w_[5]=r,Nm(C_,t,w_),C_[4]-=n,C_[5]-=r,t=C_),this.setLocalTransform(t)}},e.prototype.getGlobalScale=function(e){var t=this.transform;return e||=[],t?(e[0]=Math.sqrt(t[0]*t[0]+t[1]*t[1]),e[1]=Math.sqrt(t[2]*t[2]+t[3]*t[3]),t[0]<0&&(e[0]=-e[0]),t[3]<0&&(e[1]=-e[1]),e):(e[0]=1,e[1]=1,e)},e.prototype.transformCoordToLocal=function(e,t){var n=[e,t],r=this.invTransform;return r&&Yp(n,n,r),n},e.prototype.transformCoordToGlobal=function(e,t){var n=[e,t],r=this.transform;return r&&Yp(n,n,r),n},e.prototype.getLineScale=function(){var e=this.transform;return e&&T_(e[0]-1)>1e-10&&T_(e[3]-1)>1e-10?Math.sqrt(T_(e[0]*e[3]-e[2]*e[1])):1},e.prototype.copyTransform=function(e){O_(this,e)},e.getLocalTransform=function(e,t){t||=[];var n=e.originX||0,r=e.originY||0,i=e.scaleX,a=e.scaleY,o=e.anchorX,s=e.anchorY,c=e.rotation||0,l=e.x,u=e.y,d=e.skewX?Math.tan(e.skewX):0,f=e.skewY?Math.tan(-e.skewY):0;if(n||r||o||s){var p=n+o,m=r+s;t[4]=-p*i-d*m*a,t[5]=-m*a-f*p*i}else t[4]=t[5]=0;return t[0]=i,t[3]=a,t[1]=f*i,t[2]=d*a,c&&Fm(t,t,c),t[4]+=n+l,t[5]+=r+u,t},e.initDefaultProps=(function(){var t=e.prototype;t.scaleX=t.scaleY=t.globalScaleRatio=1,t.x=t.y=t.originX=t.originY=t.skewX=t.skewY=t.rotation=t.anchorX=t.anchorY=0})(),e}(),D_=[`x`,`y`,`originX`,`originY`,`anchorX`,`anchorY`,`rotation`,`scaleX`,`scaleY`,`skewX`,`skewY`];function O_(e,t){for(var n=0;n<D_.length;n++){var r=D_[n];e[r]=t[r]}}var k_={};function A_(e,t){t||=`12px sans-serif`;var n=k_[t];n||=k_[t]=new Xh(500);var r=n.get(e);return r??(r=Mf.measureText(e,t).width,n.put(e,r)),r}function j_(e,t,n,r){var i=A_(e,t),a=F_(t);return new $(N_(0,i,n),P_(0,a,r),i,a)}function M_(e,t,n,r){var i=((e||``)+``).split(`
|
|
4
|
+
`);if(i.length===1)return j_(i[0],t,n,r);for(var a=new $(0,0,0,0),o=0;o<i.length;o++){var s=j_(i[o],t,n,r);o===0?a.copy(s):a.union(s)}return a}function N_(e,t,n){return n===`right`?e-=t:n===`center`&&(e-=t/2),e}function P_(e,t,n){return n===`middle`?e-=t/2:n===`bottom`&&(e-=t),e}function F_(e){return A_(`国`,e)}function I_(e,t){return typeof e==`string`?e.lastIndexOf(`%`)>=0?parseFloat(e)/100*t:parseFloat(e):e}function L_(e,t,n){var r=t.position||`inside`,i=t.distance==null?5:t.distance,a=n.height,o=n.width,s=a/2,c=n.x,l=n.y,u=`left`,d=`top`;if(r instanceof Array)c+=I_(r[0],n.width),l+=I_(r[1],n.height),u=null,d=null;else switch(r){case`left`:c-=i,l+=s,u=`right`,d=`middle`;break;case`right`:c+=i+o,l+=s,d=`middle`;break;case`top`:c+=o/2,l-=i,u=`center`,d=`bottom`;break;case`bottom`:c+=o/2,l+=a+i,u=`center`;break;case`inside`:c+=o/2,l+=s,u=`center`,d=`middle`;break;case`insideLeft`:c+=i,l+=s,d=`middle`;break;case`insideRight`:c+=o-i,l+=s,u=`right`,d=`middle`;break;case`insideTop`:c+=o/2,l+=i,u=`center`;break;case`insideBottom`:c+=o/2,l+=a-i,u=`center`,d=`bottom`;break;case`insideTopLeft`:c+=i,l+=i;break;case`insideTopRight`:c+=o-i,l+=i,u=`right`;break;case`insideBottomLeft`:c+=i,l+=a-i,d=`bottom`;break;case`insideBottomRight`:c+=o-i,l+=a-i,u=`right`,d=`bottom`}return e||={},e.x=c,e.y=l,e.align=u,e.verticalAlign=d,e}var R_=`__zr_normal__`,z_=D_.concat([`ignore`]),B_=ep(D_,function(e,t){return e[t]=!0,e},{ignore:!1}),V_={},H_=new $(0,0,0,0),U_=function(){function e(e){this.id=Gf(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return e.prototype._init=function(e){this.attr(e)},e.prototype.drift=function(e,t,n){switch(this.draggable){case`horizontal`:t=0;break;case`vertical`:e=0}var r=this.transform;r||=this.transform=[1,0,0,1,0,0],r[4]+=e,r[5]+=t,this.decomposeTransform(),this.markRedraw()},e.prototype.beforeUpdate=function(){},e.prototype.afterUpdate=function(){},e.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},e.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||={};var n=this.textConfig,r=n.local,i=t.innerTransformable,a=void 0,o=void 0,s=!1;i.parent=r?this:null;var c=!1;if(i.copyTransform(t),n.position!=null){var l=H_;n.layoutRect?l.copy(n.layoutRect):l.copy(this.getBoundingRect()),r||l.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(V_,n,l):L_(V_,n,l),i.x=V_.x,i.y=V_.y,a=V_.align,o=V_.verticalAlign;var u=n.origin;if(u&&n.rotation!=null){var d=void 0,f=void 0;u===`center`?(d=l.width*.5,f=l.height*.5):(d=I_(u[0],l.width),f=I_(u[1],l.height)),c=!0,i.originX=-i.x+d+(r?0:l.x),i.originY=-i.y+f+(r?0:l.y)}}n.rotation!=null&&(i.rotation=n.rotation);var p=n.offset;p&&(i.x+=p[0],i.y+=p[1],c||(i.originX=-p[0],i.originY=-p[1]));var m=n.inside==null?typeof n.position==`string`&&n.position.indexOf(`inside`)>=0:n.inside,h=this._innerTextDefaultStyle||={},g=void 0,_=void 0,v=void 0;m&&this.canBeInsideText()?(g=n.insideFill,_=n.insideStroke,(g==null||g===`auto`)&&(g=this.getInsideTextFill()),(_==null||_===`auto`)&&(_=this.getInsideTextStroke(g),v=!0)):(g=n.outsideFill,_=n.outsideStroke,(g==null||g===`auto`)&&(g=this.getOutsideFill()),(_==null||_===`auto`)&&(_=this.getOutsideStroke(g),v=!0)),g||=`#000`,(g!==h.fill||_!==h.stroke||v!==h.autoStroke||a!==h.align||o!==h.verticalAlign)&&(s=!0,h.fill=g,h.stroke=_,h.autoStroke=v,h.align=a,h.verticalAlign=o,t.setDefaultTextStyle(h)),t.__dirty|=1,s&&t.dirtyStyle(!0)}},e.prototype.canBeInsideText=function(){return!0},e.prototype.getInsideTextFill=function(){return`#fff`},e.prototype.getInsideTextStroke=function(e){return`#000`},e.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?__:g_},e.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),n=typeof t==`string`&&ug(t);n||=[255,255,255,1];for(var r=n[3],i=this.__zr.isDarkMode(),a=0;a<3;a++)n[a]=n[a]*r+(i?0:255)*(1-r);return n[3]=1,_g(n,`rgba`)},e.prototype.traverse=function(e,t){},e.prototype.attrKV=function(e,t){e===`textConfig`?this.setTextConfig(t):e===`textContent`?this.setTextContent(t):e===`clipPath`?this.setClipPath(t):e===`extra`?(this.extra=this.extra||{},K(this.extra,t)):this[e]=t},e.prototype.hide=function(){this.ignore=!0,this.markRedraw()},e.prototype.show=function(){this.ignore=!1,this.markRedraw()},e.prototype.attr=function(e,t){if(typeof e==`string`)this.attrKV(e,t);else if(X(e))for(var n=np(e),r=0;r<n.length;r++){var i=n[r];this.attrKV(i,e[i])}return this.markRedraw(),this},e.prototype.saveCurrentToNormalState=function(e){this._innerSaveToNormal(e);for(var t=this._normalState,n=0;n<this.animators.length;n++){var r=this.animators[n],i=r.__fromStateTransition;if(!(r.getLoop()||i&&i!==`__zr_normal__`)){var a=r.targetName,o=a?t[a]:t;r.saveTo(o)}}},e.prototype._innerSaveToNormal=function(e){var t=this._normalState;t||=this._normalState={},e.textConfig&&!t.textConfig&&(t.textConfig=this.textConfig),this._savePrimaryToNormal(e,t,z_)},e.prototype._savePrimaryToNormal=function(e,t,n){for(var r=0;r<n.length;r++){var i=n[r];e[i]!=null&&!(i in t)&&(t[i]=this[i])}},e.prototype.hasState=function(){return this.currentStates.length>0},e.prototype.getState=function(e){return this.states[e]},e.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},e.prototype.clearStates=function(e){this.useState(R_,!1,e)},e.prototype.useState=function(e,t,n,r){var i=e===R_;if(this.hasState()||!i){var a=this.currentStates,o=this.stateTransition;if(!(Yf(a,e)>=0&&(t||a.length===1))){var s;if(this.stateProxy&&!i&&(s=this.stateProxy(e)),s||=this.states&&this.states[e],!s&&!i)Kf(`State `+e+` not exists.`);else{i||this.saveCurrentToNormalState(s);var c=!!(s&&s.hoverLayer||r);c&&this._toggleHoverLayerFlag(!0),this._applyStateObj(e,s,this._normalState,t,!n&&!this.__inHover&&o&&o.duration>0,o);var l=this._textContent,u=this._textGuide;return l&&l.useState(e,t,n,c),u&&u.useState(e,t,n,c),i?(this.currentStates=[],this._normalState={}):t?this.currentStates.push(e):this.currentStates=[e],this._updateAnimationTargets(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=-2),s}}}},e.prototype.useStates=function(e,t,n){if(!e.length)this.clearStates();else{var r=[],i=this.currentStates,a=e.length,o=a===i.length;if(o){for(var s=0;s<a;s++)if(e[s]!==i[s]){o=!1;break}}if(o)return;for(var s=0;s<a;s++){var c=e[s],l=void 0;this.stateProxy&&(l=this.stateProxy(c,e)),l||=this.states[c],l&&r.push(l)}var u=r[a-1],d=!!(u&&u.hoverLayer||n);d&&this._toggleHoverLayerFlag(!0);var f=this._mergeStates(r),p=this.stateTransition;this.saveCurrentToNormalState(f),this._applyStateObj(e.join(`,`),f,this._normalState,!1,!t&&!this.__inHover&&p&&p.duration>0,p);var m=this._textContent,h=this._textGuide;m&&m.useStates(e,t,d),h&&h.useStates(e,t,d),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!d&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=-2)}},e.prototype.isSilent=function(){for(var e=this.silent,t=this.parent;!e&&t;){if(t.silent){e=!0;break}t=t.parent}return e},e.prototype._updateAnimationTargets=function(){for(var e=0;e<this.animators.length;e++){var t=this.animators[e];t.targetName&&t.changeTarget(this[t.targetName])}},e.prototype.removeState=function(e){var t=Yf(this.currentStates,e);if(t>=0){var n=this.currentStates.slice();n.splice(t,1),this.useStates(n)}},e.prototype.replaceState=function(e,t,n){var r=this.currentStates.slice(),i=Yf(r,e),a=Yf(r,t)>=0;i>=0?a?r.splice(i,1):r[i]=t:n&&!a&&r.push(t),this.useStates(r)},e.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},e.prototype._mergeStates=function(e){for(var t={},n,r=0;r<e.length;r++){var i=e[r];K(t,i),i.textConfig&&(n||={},K(n,i.textConfig))}return n&&(t.textConfig=n),t},e.prototype._applyStateObj=function(e,t,n,r,i,a){var o=!(t&&r);t&&t.textConfig?(this.textConfig=K({},r?this.textConfig:n.textConfig),K(this.textConfig,t.textConfig)):o&&n.textConfig&&(this.textConfig=n.textConfig);for(var s={},c=!1,l=0;l<z_.length;l++){var u=z_[l],d=i&&B_[u];t&&t[u]!=null?d?(c=!0,s[u]=t[u]):this[u]=t[u]:o&&n[u]!=null&&(d?(c=!0,s[u]=n[u]):this[u]=n[u])}if(!i)for(var l=0;l<this.animators.length;l++){var f=this.animators[l],p=f.targetName;f.getLoop()||f.__changeFinalValue(p?(t||n)[p]:t||n)}c&&this._transitionState(e,s,a)},e.prototype._attachComponent=function(e){if((!e.__zr||e.__hostTarget)&&e!==this){var t=this.__zr;t&&e.addSelfToZr(t),e.__zr=t,e.__hostTarget=this}},e.prototype._detachComponent=function(e){e.__zr&&e.removeSelfFromZr(e.__zr),e.__zr=null,e.__hostTarget=null},e.prototype.getClipPath=function(){return this._clipPath},e.prototype.setClipPath=function(e){this._clipPath&&this._clipPath!==e&&this.removeClipPath(),this._attachComponent(e),this._clipPath=e,this.markRedraw()},e.prototype.removeClipPath=function(){var e=this._clipPath;e&&(this._detachComponent(e),this._clipPath=null,this.markRedraw())},e.prototype.getTextContent=function(){return this._textContent},e.prototype.setTextContent=function(e){var t=this._textContent;t!==e&&(t&&t!==e&&this.removeTextContent(),e.innerTransformable=new E_,this._attachComponent(e),this._textContent=e,this.markRedraw())},e.prototype.setTextConfig=function(e){this.textConfig||={},K(this.textConfig,e),this.markRedraw()},e.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},e.prototype.removeTextContent=function(){var e=this._textContent;e&&(e.innerTransformable=null,this._detachComponent(e),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},e.prototype.getTextGuideLine=function(){return this._textGuide},e.prototype.setTextGuideLine=function(e){this._textGuide&&this._textGuide!==e&&this.removeTextGuideLine(),this._attachComponent(e),this._textGuide=e,this.markRedraw()},e.prototype.removeTextGuideLine=function(){var e=this._textGuide;e&&(this._detachComponent(e),this._textGuide=null,this.markRedraw())},e.prototype.markRedraw=function(){this.__dirty|=1;var e=this.__zr;e&&(this.__inHover?e.refreshHover():e.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},e.prototype.dirty=function(){this.markRedraw()},e.prototype._toggleHoverLayerFlag=function(e){this.__inHover=e;var t=this._textContent,n=this._textGuide;t&&(t.__inHover=e),n&&(n.__inHover=e)},e.prototype.addSelfToZr=function(e){if(this.__zr!==e){this.__zr=e;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.addAnimator(t[n]);this._clipPath&&this._clipPath.addSelfToZr(e),this._textContent&&this._textContent.addSelfToZr(e),this._textGuide&&this._textGuide.addSelfToZr(e)}},e.prototype.removeSelfFromZr=function(e){if(this.__zr){this.__zr=null;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.removeAnimator(t[n]);this._clipPath&&this._clipPath.removeSelfFromZr(e),this._textContent&&this._textContent.removeSelfFromZr(e),this._textGuide&&this._textGuide.removeSelfFromZr(e)}},e.prototype.animate=function(e,t,n){var r=new Gg(e?this[e]:this,t,n);return e&&(r.targetName=e),this.addAnimator(r,e),r},e.prototype.addAnimator=function(e,t){var n=this.__zr,r=this;e.during(function(){r.updateDuringAnimation(t)}).done(function(){var t=r.animators,n=Yf(t,e);n>=0&&t.splice(n,1)}),this.animators.push(e),n&&n.animation.addAnimator(e),n&&n.wakeUp()},e.prototype.updateDuringAnimation=function(e){this.markRedraw()},e.prototype.stopAnimation=function(e,t){for(var n=this.animators,r=n.length,i=[],a=0;a<r;a++){var o=n[a];!e||e===o.scope?o.stop(t):i.push(o)}return this.animators=i,this},e.prototype.animateTo=function(e,t,n){W_(this,e,t,n)},e.prototype.animateFrom=function(e,t,n){W_(this,e,t,n,!0)},e.prototype._transitionState=function(e,t,n,r){for(var i=W_(this,t,n,r),a=0;a<i.length;a++)i[a].__fromStateTransition=e},e.prototype.getBoundingRect=function(){return null},e.prototype.getPaintRect=function(){return null},e.initDefaultProps=(function(){var t=e.prototype;t.type=`element`,t.name=``,t.ignore=t.silent=t.isGroup=t.draggable=t.dragging=t.ignoreClip=t.__inHover=!1,t.__dirty=1;function n(e,n,r,i){Object.defineProperty(t,e,{get:function(){if(!this[n]){var e=this[n]=[];a(this,e)}return this[n]},set:function(e){this[r]=e[0],this[i]=e[1],this[n]=e,a(this,e)}});function a(e,t){Object.defineProperty(t,0,{get:function(){return e[r]},set:function(t){e[r]=t}}),Object.defineProperty(t,1,{get:function(){return e[i]},set:function(t){e[i]=t}})}}Object.defineProperty&&(n(`position`,`_legacyPos`,`x`,`y`),n(`scale`,`_legacyScale`,`scaleX`,`scaleY`),n(`origin`,`_legacyOrigin`,`originX`,`originY`))})(),e}();Zf(U_,em),Zf(U_,E_);function W_(e,t,n,r,i){n||={};var a=[];X_(e,``,e,t,n,r,a,i);var o=a.length,s=!1,c=n.done,l=n.aborted,u=function(){s=!0,o--,o<=0&&(s?c&&c():l&&l())},d=function(){o--,o<=0&&(s?c&&c():l&&l())};o||c&&c(),a.length>0&&n.during&&a[0].during(function(e,t){n.during(t)});for(var f=0;f<a.length;f++){var p=a[f];u&&p.done(u),d&&p.aborted(d),n.force&&p.duration(n.duration),p.start(n.easing)}return a}function G_(e,t,n){for(var r=0;r<n;r++)e[r]=t[r]}function K_(e){return Qf(e[0])}function q_(e,t,n){if(Qf(t[n])){if(Qf(e[n])||(e[n]=[]),up(t[n])){var r=t[n].length;e[n].length!==r&&(e[n]=new t[n].constructor(r),G_(e[n],t[n],r))}else{var i=t[n],a=e[n],o=i.length;if(K_(i))for(var s=i[0].length,c=0;c<o;c++)a[c]?G_(a[c],i[c],s):a[c]=Array.prototype.slice.call(i[c]);else G_(a,i,o);a.length=i.length}}else e[n]=t[n]}function J_(e,t){return e===t||Qf(e)&&Qf(t)&&Y_(e,t)}function Y_(e,t){var n=e.length;if(n!==t.length)return!1;for(var r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function X_(e,t,n,r,i,a,o,s){for(var c=np(r),l=i.duration,u=i.delay,d=i.additive,f=i.setToFinal,p=!X(a),m=e.animators,h=[],g=0;g<c.length;g++){var _=c[g],v=r[_];if(v!=null&&n[_]!=null&&(p||a[_])){if(X(v)&&!Qf(v)&&!fp(v)){if(t){s||(n[_]=v,e.updateDuringAnimation(t));continue}X_(e,_,n[_],v,i,a&&a[_],o,s)}else h.push(_)}else s||(n[_]=v,e.updateDuringAnimation(t),h.push(_))}var y=h.length;if(!d&&y)for(var b=0;b<m.length;b++){var x=m[b];if(x.targetName===t&&x.stopTracks(h)){var S=Yf(m,x);m.splice(S,1)}}if(i.force||(h=tp(h,function(e){return!J_(r[e],n[e])}),y=h.length),y>0||i.force&&!o.length){var C=void 0,w=void 0,T=void 0;if(s){w={},f&&(C={});for(var b=0;b<y;b++){var _=h[b];w[_]=n[_],f?C[_]=r[_]:n[_]=r[_]}}else if(f){T={};for(var b=0;b<y;b++){var _=h[b];T[_]=jg(n[_]),q_(n,r,_)}}var x=new Gg(n,!1,!1,d?tp(m,function(e){return e.targetName===t}):null);x.targetName=t,i.scope&&(x.scope=i.scope),f&&C&&x.whenWithKeys(0,C,h),T&&x.whenWithKeys(0,T,h),x.whenWithKeys(l??500,s?w:r,h).delay(u||0),e.addAnimator(x,t),o.push(x)}}var Z_=function(e){U(t,e);function t(t){var n=e.call(this)||this;return n.isGroup=!0,n._children=[],n.attr(t),n}return t.prototype.childrenRef=function(){return this._children},t.prototype.children=function(){return this._children.slice()},t.prototype.childAt=function(e){return this._children[e]},t.prototype.childOfName=function(e){for(var t=this._children,n=0;n<t.length;n++)if(t[n].name===e)return t[n]},t.prototype.childCount=function(){return this._children.length},t.prototype.add=function(e){return e&&e!==this&&e.parent!==this&&(this._children.push(e),this._doAdd(e)),this},t.prototype.addBefore=function(e,t){if(e&&e!==this&&e.parent!==this&&t&&t.parent===this){var n=this._children,r=n.indexOf(t);r>=0&&(n.splice(r,0,e),this._doAdd(e))}return this},t.prototype.replace=function(e,t){var n=Yf(this._children,e);return n>=0&&this.replaceAt(t,n),this},t.prototype.replaceAt=function(e,t){var n=this._children,r=n[t];if(e&&e!==this&&e.parent!==this&&e!==r){n[t]=e,r.parent=null;var i=this.__zr;i&&r.removeSelfFromZr(i),this._doAdd(e)}return this},t.prototype._doAdd=function(e){e.parent&&e.parent.remove(e),e.parent=this;var t=this.__zr;t&&t!==e.__zr&&e.addSelfToZr(t),t&&t.refresh()},t.prototype.remove=function(e){var t=this.__zr,n=this._children,r=Yf(n,e);return r<0||(n.splice(r,1),e.parent=null,t&&e.removeSelfFromZr(t),t&&t.refresh()),this},t.prototype.removeAll=function(){for(var e=this._children,t=this.__zr,n=0;n<e.length;n++){var r=e[n];t&&r.removeSelfFromZr(t),r.parent=null}return e.length=0,this},t.prototype.eachChild=function(e,t){for(var n=this._children,r=0;r<n.length;r++){var i=n[r];e.call(t,i,r)}return this},t.prototype.traverse=function(e,t){for(var n=0;n<this._children.length;n++){var r=this._children[n],i=e.call(t,r);r.isGroup&&!i&&r.traverse(e,t)}return this},t.prototype.addSelfToZr=function(t){e.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].addSelfToZr(t)},t.prototype.removeSelfFromZr=function(t){e.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].removeSelfFromZr(t)},t.prototype.getBoundingRect=function(e){for(var t=new $(0,0,0,0),n=e||this._children,r=[],i=null,a=0;a<n.length;a++){var o=n[a];if(!(o.ignore||o.invisible)){var s=o.getBoundingRect(),c=o.getLocalTransform(r);c?($.applyTransform(t,s,c),i||=t.clone(),i.union(t)):(i||=s.clone(),i.union(s))}}return i||t},t}(U_);Z_.prototype.type=`group`;var Q_={},$_={};function ev(e){delete $_[e]}function tv(e){if(!e)return!1;if(typeof e==`string`)return vg(e,1)<h_;if(e.colorStops){for(var t=e.colorStops,n=0,r=t.length,i=0;i<r;i++)n+=vg(t[i].color,1);return n/=r,n<h_}return!1}var nv=function(){function e(e,t,n){var r=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,n||={},this.dom=t,this.id=e;var i=new _h,a=n.renderer||`canvas`;Q_[a]||(a=np(Q_)[0]),n.useDirtyRect=n.useDirtyRect!=null&&n.useDirtyRect;var o=new Q_[a](t,i,n,e),s=n.ssr||o.ssrOnly;this.storage=i,this.painter=o;var c=!W.node&&!W.worker&&!s?new f_(o.getViewportRoot(),o.root):null,l=n.useCoarsePointer,u=l==null||l===`auto`?W.touchEventsSupported:!!l,d=44,f;u&&(f=Z(n.pointerSize,d)),this.handler=new eh(i,o,c,o.root,f),this.animation=new qg({stage:{update:s?null:function(){return r._flush(!0)}}}),s||this.animation.start()}return e.prototype.add=function(e){!this._disposed&&e&&(this.storage.addRoot(e),e.addSelfToZr(this),this.refresh())},e.prototype.remove=function(e){!this._disposed&&e&&(this.storage.delRoot(e),e.removeSelfFromZr(this),this.refresh())},e.prototype.configLayer=function(e,t){this._disposed||(this.painter.configLayer&&this.painter.configLayer(e,t),this.refresh())},e.prototype.setBackgroundColor=function(e){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(e),this.refresh(),this._backgroundColor=e,this._darkMode=tv(e))},e.prototype.getBackgroundColor=function(){return this._backgroundColor},e.prototype.setDarkMode=function(e){this._darkMode=e},e.prototype.isDarkMode=function(){return this._darkMode},e.prototype.refreshImmediately=function(e){this._disposed||(e||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1)},e.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},e.prototype.flush=function(){this._disposed||this._flush(!1)},e.prototype._flush=function(e){var t,n=Kg();this._needsRefresh&&(t=!0,this.refreshImmediately(e)),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately());var r=Kg();t?(this._stillFrameAccum=0,this.trigger(`rendered`,{elapsedTime:r-n})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},e.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},e.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},e.prototype.refreshHover=function(){this._needsRefreshHover=!0},e.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()===`canvas`&&this.painter.refreshHover())},e.prototype.resize=function(e){this._disposed||(e||={},this.painter.resize(e.width,e.height),this.handler.resize())},e.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},e.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},e.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},e.prototype.setCursorStyle=function(e){this._disposed||this.handler.setCursorStyle(e)},e.prototype.findHover=function(e,t){if(!this._disposed)return this.handler.findHover(e,t)},e.prototype.on=function(e,t,n){return this._disposed||this.handler.on(e,t,n),this},e.prototype.off=function(e,t){this._disposed||this.handler.off(e,t)},e.prototype.trigger=function(e,t){this._disposed||this.handler.trigger(e,t)},e.prototype.clear=function(){if(!this._disposed){for(var e=this.storage.getRoots(),t=0;t<e.length;t++)e[t]instanceof Z_&&e[t].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},e.prototype.dispose=function(){this._disposed||(this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,ev(this.id))},e}();function rv(e,t){var n=new nv(Gf(),e,t);return $_[n.id]=n,n}function iv(e,t){Q_[e]=t}var av=1e-4,ov=20;function sv(e){return e.replace(/^\s+|\s+$/g,``)}function cv(e,t,n,r){var i=t[0],a=t[1],o=n[0],s=n[1],c=a-i,l=s-o;if(c===0)return l===0?o:(o+s)/2;if(r){if(c>0){if(e<=i)return o;if(e>=a)return s}else if(e>=i)return o;else if(e<=a)return s}else{if(e===i)return o;if(e===a)return s}return(e-i)/c*l+o}function lv(e,t){switch(e){case`center`:case`middle`:e=`50%`;break;case`left`:case`top`:e=`0%`;break;case`right`:case`bottom`:e=`100%`}return Y(e)?sv(e).match(/%$/)?parseFloat(e)/100*t:parseFloat(e):e==null?NaN:+e}function uv(e,t,n){return t??=10,t=Math.min(Math.max(0,t),ov),e=(+e).toFixed(t),n?e:+e}function dv(e){if(e=+e,isNaN(e))return 0;if(e>1e-14){for(var t=1,n=0;n<15;n++,t*=10)if(Math.round(e*t)/t===e)return n}return fv(e)}function fv(e){var t=e.toString().toLowerCase(),n=t.indexOf(`e`),r=n>0?+t.slice(n+1):0,i=n>0?n:t.length,a=t.indexOf(`.`),o=a<0?0:i-1-a;return Math.max(0,o-r)}function pv(e,t){var n=Math.max(dv(e),dv(t)),r=e+t;return n>ov?r:uv(r,n)}function mv(e){var t=Math.PI*2;return(e%t+t)%t}function hv(e){return e>-av&&e<av}var gv=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function _v(e){if(e instanceof Date)return e;if(Y(e)){var t=gv.exec(e);if(!t)return new Date(NaN);if(t[8]){var n=+t[4]||0;return t[8].toUpperCase()!==`Z`&&(n-=+t[8].slice(0,3)),new Date(Date.UTC(+t[1],(t[2]||1)-1,+t[3]||1,n,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0))}return new Date(+t[1],(t[2]||1)-1,+t[3]||1,+t[4]||0,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0)}return e==null?new Date(NaN):new Date(Math.round(e))}function vv(e){var t=parseFloat(e);return t==e&&(t!==0||!Y(e)||e.indexOf(`x`)<=0)?t:NaN}function yv(e){return!isNaN(vv(e))}function bv(){return Math.round(Math.random()*9)}function xv(e,t){return t===0?e:xv(t,e%t)}function Sv(e,t){return e==null?t:t==null?e:e*t/xv(e,t)}function Cv(e){throw Error(e)}var wv=`series\0`,Tv=`\0_ec_\0`;function Ev(e){return e instanceof Array?e:e==null?[]:[e]}function Dv(e,t,n){if(e){e[t]=e[t]||{},e.emphasis=e.emphasis||{},e.emphasis[t]=e.emphasis[t]||{};for(var r=0,i=n.length;r<i;r++){var a=n[r];!e.emphasis[t].hasOwnProperty(a)&&e[t].hasOwnProperty(a)&&(e.emphasis[t][a]=e[t][a])}}}var Ov=`fontStyle.fontWeight.fontSize.fontFamily.rich.tag.color.textBorderColor.textBorderWidth.width.height.lineHeight.align.verticalAlign.baseline.shadowColor.shadowBlur.shadowOffsetX.shadowOffsetY.textShadowColor.textShadowBlur.textShadowOffsetX.textShadowOffsetY.backgroundColor.borderColor.borderWidth.borderRadius.padding`.split(`.`);function kv(e){return X(e)&&!J(e)&&!(e instanceof Date)?e.value:e}function Av(e){return X(e)&&!(e instanceof Array)}function jv(e,t,n){var r=n===`normalMerge`,i=n===`replaceMerge`,a=n===`replaceAll`;e||=[],t=(t||[]).slice();var o=Q();q(t,function(e,n){X(e)||(t[n]=null)});var s=Mv(e,o,n);return(r||i)&&Nv(s,e,o,t),r&&Pv(s,t),r||i?Fv(s,t,i):a&&Iv(s,t),Lv(s),s}function Mv(e,t,n){var r=[];if(n===`replaceAll`)return r;for(var i=0;i<e.length;i++){var a=e[i];a&&a.id!=null&&t.set(a.id,i),r.push({existing:n===`replaceMerge`||Hv(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return r}function Nv(e,t,n,r){q(r,function(i,a){if(i&&i.id!=null){var o=zv(i.id),s=n.get(o);if(s!=null){var c=e[s];yp(!c.newOption,`Duplicated option on id "`+o+`".`),c.newOption=i,c.existing=t[s],r[a]=null}}})}function Pv(e,t){q(t,function(n,r){if(n&&n.name!=null)for(var i=0;i<e.length;i++){var a=e[i].existing;if(!e[i].newOption&&a&&(a.id==null||n.id==null)&&!Hv(n)&&!Hv(a)&&Rv(`name`,a,n)){e[i].newOption=n,t[r]=null;return}}})}function Fv(e,t,n){q(t,function(t){if(t){for(var r,i=0;(r=e[i])&&(r.newOption||Hv(r.existing)||r.existing&&t.id!=null&&!Rv(`id`,t,r.existing));)i++;r?(r.newOption=t,r.brandNew=n):e.push({newOption:t,brandNew:n,existing:null,keyInfo:null}),i++}})}function Iv(e,t){q(t,function(t){e.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function Lv(e){var t=Q();q(e,function(e){var n=e.existing;n&&t.set(n.id,e)}),q(e,function(e){var n=e.newOption;yp(!n||n.id==null||!t.get(n.id)||t.get(n.id)===e,`id duplicates: `+(n&&n.id)),n&&n.id!=null&&t.set(n.id,e),!e.keyInfo&&(e.keyInfo={})}),q(e,function(e,n){var r=e.existing,i=e.newOption,a=e.keyInfo;if(X(i)){if(a.name=i.name==null?r?r.name:wv+n:zv(i.name),r)a.id=zv(r.id);else if(i.id!=null)a.id=zv(i.id);else{var o=0;do a.id=`\0`+a.name+`\0`+o++;while(t.get(a.id))}t.set(a.id,e)}})}function Rv(e,t,n){var r=Bv(t[e],null),i=Bv(n[e],null);return r!=null&&i!=null&&r===i}function zv(e){return Bv(e,``)}function Bv(e,t){return e==null?t:Y(e)?e:cp(e)||sp(e)?e+``:t}function Vv(e){var t=e.name;return!!(t&&t.indexOf(wv))}function Hv(e){return e&&e.id!=null&&zv(e.id).indexOf(Tv)===0}function Uv(e,t,n){q(e,function(e){var r=e.newOption;X(r)&&(e.keyInfo.mainType=t,e.keyInfo.subType=Wv(t,r,e.existing,n))})}function Wv(e,t,n,r){return t.type?t.type:n?n.subType:r.determineSubType(e,t)}function Gv(e,t){if(t.dataIndexInside!=null)return t.dataIndexInside;if(t.dataIndex!=null)return J(t.dataIndex)?$f(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex);if(t.name!=null)return J(t.name)?$f(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name)}function Kv(){var e=`__ec_inner_`+qv++;return function(t){return t[e]||(t[e]={})}}var qv=bv();function Jv(e,t,n){var r=Yv(t,n),i=r.mainTypeSpecified,a=r.queryOptionMap,o=r.others,s=n?n.defaultMainType:null;return!i&&s&&a.set(s,{}),a.each(function(t,r){var i=Zv(e,r,t,{useDefault:s===r,enableAll:n&&n.enableAll!=null?n.enableAll:!0,enableNone:n&&n.enableNone!=null?n.enableNone:!0});o[r+`Models`]=i.models,o[r+`Model`]=i.models[0]}),o}function Yv(e,t){var n;if(Y(e)){var r={};r[e+`Index`]=0,n=r}else n=e;var i=Q(),a={},o=!1;return q(n,function(e,n){if(n===`dataIndex`||n===`dataIndexInside`)a[n]=e;else{var r=n.match(/^(\w+)(Index|Id|Name)$/)||[],s=r[1],c=(r[2]||``).toLowerCase();if(!(!s||!c||t&&t.includeMainTypes&&Yf(t.includeMainTypes,s)<0)){o||=!!s;var l=i.get(s)||i.set(s,{});l[c]=e}}}),{mainTypeSpecified:o,queryOptionMap:i,others:a}}var Xv={useDefault:!0,enableAll:!1,enableNone:!1};function Zv(e,t,n,r){r||=Xv;var i=n.index,a=n.id,o=n.name,s={models:null,specified:i!=null||a!=null||o!=null};if(!s.specified){var c=void 0;return s.models=r.useDefault&&(c=e.getComponent(t))?[c]:[],s}return i===`none`||i===!1?(yp(r.enableNone,'`"none"` or `false` is not a valid value on index option.'),s.models=[],s):(i===`all`&&(yp(r.enableAll,'`"all"` is not a valid value on index option.'),i=a=o=null),s.models=e.queryComponents({mainType:t,index:i,id:a,name:o}),s)}function Qv(e,t,n){e.setAttribute?e.setAttribute(t,n):e[t]=n}function $v(e,t){return e.getAttribute?e.getAttribute(t):e[t]}function ey(e){return e===`auto`?W.domSupported?`html`:`richText`:e||`html`}var ty=`.`,ny=`___EC__COMPONENT__CONTAINER___`,ry=`___EC__EXTENDED_CLASS___`;function iy(e){var t={main:``,sub:``};if(e){var n=e.split(ty);t.main=n[0]||``,t.sub=n[1]||``}return t}function ay(e){yp(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e),`componentType "`+e+`" illegal`)}function oy(e){return!!(e&&e[ry])}function sy(e,t){e.$constructor=e,e.extend=function(e){var t=this,n;return cy(t)?n=function(e){U(t,e);function t(){return e.apply(this,arguments)||this}return t}(t):(n=function(){(e.$constructor||t).apply(this,arguments)},Xf(n,this)),K(n.prototype,e),n[ry]=!0,n.extend=this.extend,n.superCall=fy,n.superApply=py,n.superClass=t,n}}function cy(e){return op(e)&&/^class\s/.test(Function.prototype.toString.call(e))}function ly(e,t){e.extend=t.extend}var uy=Math.round(Math.random()*10);function dy(e){var t=[`__\0is_clz`,uy++].join(`_`);e.prototype[t]=!0,e.isInstance=function(e){return!!(e&&e[t])}}function fy(e,t){var n=[...arguments].slice(2);return this.superClass.prototype[t].apply(e,n)}function py(e,t,n){return this.superClass.prototype[t].apply(e,n)}function my(e){var t={};e.registerClass=function(e){var r=e.type||e.prototype.type;if(r){ay(r),e.prototype.type=r;var i=iy(r);if(!i.sub)t[i.main]=e;else if(i.sub!==ny){var a=n(i);a[i.sub]=e}}return e},e.getClass=function(e,n,r){var i=t[e];if(i&&i[ny]&&(i=n?i[n]:null),r&&!i)throw Error(n?`Component `+e+`.`+(n||``)+` is used but not imported.`:e+`.type should be specified.`);return i},e.getClassesByMainType=function(e){var n=iy(e),r=[],i=t[n.main];return i&&i[ny]?q(i,function(e,t){t!==ny&&r.push(e)}):r.push(i),r},e.hasClass=function(e){return!!t[iy(e).main]},e.getAllClassMainTypes=function(){var e=[];return q(t,function(t,n){e.push(n)}),e},e.hasSubTypes=function(e){var n=t[iy(e).main];return n&&n[ny]};function n(e){var n=t[e.main];return n&&n[ny]||(n=t[e.main]={},n[ny]=!0),n}}function hy(e,t){for(var n=0;n<e.length;n++)e[n][1]||(e[n][1]=e[n][0]);return t||=!1,function(n,r,i){for(var a={},o=0;o<e.length;o++){var s=e[o][1];if(!(r&&Yf(r,s)>=0||i&&Yf(i,s)<0)){var c=n.getShallow(s,t);c!=null&&(a[e[o][0]]=c)}}return a}}var gy=hy([[`fill`,`color`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`opacity`],[`shadowColor`]]),_y=function(){function e(){}return e.prototype.getAreaStyle=function(e,t){return gy(this,e,t)},e}(),vy=new Xh(50);function yy(e){if(typeof e==`string`){var t=vy.get(e);return t&&t.image}return e}function by(e,t,n,r,i){if(!e)return t;if(typeof e==`string`){if(t&&t.__zrImageSrc===e||!n)return t;var a=vy.get(e),o={hostEl:n,cb:r,cbPayload:i};return a?(t=a.image,!Sy(t)&&a.pending.push(o)):(t=Mf.loadImage(e,xy,xy),t.__zrImageSrc=e,vy.put(e,t.__cachedImgObj={image:t,pending:[o]})),t}return e}function xy(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var n=e.pending[t],r=n.cb;r&&r(this,n.cbPayload),n.hostEl.dirty()}e.pending.length=0}function Sy(e){return e&&e.width&&e.height}var Cy=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function wy(e,t,n,r,i,a){if(!n)e.text=``,e.isTruncated=!1;else{var o=(t+``).split(`
|
|
5
|
+
`);a=Ty(n,r,i,a);for(var s=!1,c={},l=0,u=o.length;l<u;l++)Ey(c,o[l],a),o[l]=c.textLine,s||=c.isTruncated;e.text=o.join(`
|
|
6
|
+
`),e.isTruncated=s}}function Ty(e,t,n,r){r||={};var i=K({},r);i.font=t,n=Z(n,`...`),i.maxIterations=Z(r.maxIterations,2);var a=i.minChar=Z(r.minChar,0);i.cnCharWidth=A_(`国`,t);var o=i.ascCharWidth=A_(`a`,t);i.placeholder=Z(r.placeholder,``);for(var s=e=Math.max(0,e-1),c=0;c<a&&s>=o;c++)s-=o;var l=A_(n,t);return l>s&&(n=``,l=0),s=e-l,i.ellipsis=n,i.ellipsisWidth=l,i.contentWidth=s,i.containerWidth=e,i}function Ey(e,t,n){var r=n.containerWidth,i=n.font,a=n.contentWidth;if(!r)e.textLine=``,e.isTruncated=!1;else{var o=A_(t,i);if(o<=r)e.textLine=t,e.isTruncated=!1;else{for(var s=0;;s++){if(o<=a||s>=n.maxIterations){t+=n.ellipsis;break}var c=s===0?Dy(t,a,n.ascCharWidth,n.cnCharWidth):o>0?Math.floor(t.length*a/o):0;t=t.substr(0,c),o=A_(t,i)}t===``&&(t=n.placeholder),e.textLine=t,e.isTruncated=!0}}}function Dy(e,t,n,r){for(var i=0,a=0,o=e.length;a<o&&i<t;a++){var s=e.charCodeAt(a);i+=0<=s&&s<=127?n:r}return a}function Oy(e,t){e!=null&&(e+=``);var n=t.overflow,r=t.padding,i=t.font,a=n===`truncate`,o=F_(i),s=Z(t.lineHeight,o),c=!!t.backgroundColor,l=t.lineOverflow===`truncate`,u=!1,d=t.width,f=d!=null&&(n===`break`||n===`breakAll`)?e?Ly(e,t.font,d,n===`breakAll`,0).lines:[]:e?e.split(`
|
|
7
|
+
`):[],p=f.length*s,m=Z(t.height,p);if(p>m&&l){var h=Math.floor(m/s);u||=f.length>h,f=f.slice(0,h)}if(e&&a&&d!=null)for(var g=Ty(d,i,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),_={},v=0;v<f.length;v++)Ey(_,f[v],g),f[v]=_.textLine,u||=_.isTruncated;for(var y=m,b=0,v=0;v<f.length;v++)b=Math.max(A_(f[v],i),b);d??=b;var x=b;return r&&(y+=r[0]+r[2],x+=r[1]+r[3],d+=r[1]+r[3]),c&&(x=d),{lines:f,height:m,outerWidth:x,outerHeight:y,lineHeight:s,calculatedLineHeight:o,contentWidth:b,contentHeight:p,width:d,isTruncated:u}}var ky=function(){function e(){}return e}(),Ay=function(){function e(e){this.tokens=[],e&&(this.tokens=e)}return e}(),jy=function(){function e(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return e}();function My(e,t){var n=new jy;if(e!=null&&(e+=``),!e)return n;for(var r=t.width,i=t.height,a=t.overflow,o=(a===`break`||a===`breakAll`)&&r!=null?{width:r,accumWidth:0,breakAll:a===`breakAll`}:null,s=Cy.lastIndex=0,c;(c=Cy.exec(e))!=null;){var l=c.index;l>s&&Ny(n,e.substring(s,l),t,o),Ny(n,c[2],t,o,c[1]),s=Cy.lastIndex}s<e.length&&Ny(n,e.substring(s,e.length),t,o);var u=[],d=0,f=0,p=t.padding,m=a===`truncate`,h=t.lineOverflow===`truncate`,g={};function _(e,t,n){e.width=t,e.lineHeight=n,d+=n,f=Math.max(f,t)}outer:for(var v=0;v<n.lines.length;v++){for(var y=n.lines[v],b=0,x=0,S=0;S<y.tokens.length;S++){var C=y.tokens[S],w=C.styleName&&t.rich[C.styleName]||{},T=C.textPadding=w.padding,E=T?T[1]+T[3]:0,D=C.font=w.font||t.font;C.contentHeight=F_(D);var O=Z(w.height,C.contentHeight);if(C.innerHeight=O,T&&(O+=T[0]+T[2]),C.height=O,C.lineHeight=gp(w.lineHeight,t.lineHeight,O),C.align=w&&w.align||t.align,C.verticalAlign=w&&w.verticalAlign||`middle`,h&&i!=null&&d+C.lineHeight>i){var k=n.lines.length;S>0?(y.tokens=y.tokens.slice(0,S),_(y,x,b),n.lines=n.lines.slice(0,v+1)):n.lines=n.lines.slice(0,v),n.isTruncated=n.isTruncated||n.lines.length<k;break outer}var A=w.width,ee=A==null||A===`auto`;if(typeof A==`string`&&A.charAt(A.length-1)===`%`)C.percentWidth=A,u.push(C),C.contentWidth=A_(C.text,D);else{if(ee){var te=w.backgroundColor,ne=te&&te.image;ne&&(ne=yy(ne),Sy(ne)&&(C.width=Math.max(C.width,ne.width*O/ne.height)))}var re=m&&r!=null?r-x:null;re!=null&&re<C.width?!ee||re<E?(C.text=``,C.width=C.contentWidth=0):(wy(g,C.text,re-E,D,t.ellipsis,{minChar:t.truncateMinChar}),C.text=g.text,n.isTruncated=n.isTruncated||g.isTruncated,C.width=C.contentWidth=A_(C.text,D)):C.contentWidth=A_(C.text,D)}C.width+=E,x+=C.width,w&&(b=Math.max(b,C.lineHeight))}_(y,x,b)}n.outerWidth=n.width=Z(r,f),n.outerHeight=n.height=Z(i,d),n.contentHeight=d,n.contentWidth=f,p&&(n.outerWidth+=p[1]+p[3],n.outerHeight+=p[0]+p[2]);for(var v=0;v<u.length;v++){var C=u[v],j=C.percentWidth;C.width=parseInt(j,10)/100*n.width}return n}function Ny(e,t,n,r,i){var a=t===``,o=i&&n.rich[i]||{},s=e.lines,c=o.font||n.font,l=!1,u,d;if(r){var f=o.padding,p=f?f[1]+f[3]:0;if(o.width!=null&&o.width!==`auto`){var m=I_(o.width,r.width)+p;s.length>0&&m+r.accumWidth>r.width&&(u=t.split(`
|
|
8
|
+
`),l=!0),r.accumWidth=m}else{var h=Ly(t,c,r.width,r.breakAll,r.accumWidth);r.accumWidth=h.accumWidth+p,d=h.linesWidths,u=h.lines}}else u=t.split(`
|
|
9
|
+
`);for(var g=0;g<u.length;g++){var _=u[g],v=new ky;if(v.styleName=i,v.text=_,v.isLineHolder=!_&&!a,v.width=typeof o.width==`number`?o.width:d?d[g]:A_(_,c),!g&&!l){var y=(s[s.length-1]||(s[0]=new Ay)).tokens,b=y.length;b===1&&y[0].isLineHolder?y[0]=v:(_||!b||a)&&y.push(v)}else s.push(new Ay([v]))}}function Py(e){var t=e.charCodeAt(0);return t>=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}var Fy=ep(`,&?/;] `.split(``),function(e,t){return e[t]=!0,e},{});function Iy(e){return!Py(e)||!!Fy[e]}function Ly(e,t,n,r,i){for(var a=[],o=[],s=``,c=``,l=0,u=0,d=0;d<e.length;d++){var f=e.charAt(d);if(f===`
|
|
10
|
+
`)c&&(s+=c,u+=l),a.push(s),o.push(u),s=``,c=``,l=0,u=0;else{var p=A_(f,t),m=!r&&!Iy(f);(a.length?u+p>n:i+u+p>n)?u?(s||c)&&(m?(s||(s=c,c=``,l=0,u=l),a.push(s),o.push(u-l),c+=f,l+=p,s=``,u=l):(c&&(s+=c,c=``,l=0),a.push(s),o.push(u),s=f,u=p)):m?(a.push(c),o.push(l),c=f,l=p):(a.push(f),o.push(p)):(u+=p,m?(c+=f,l+=p):(c&&(s+=c,c=``,l=0),s+=f))}}return!a.length&&!s&&(s=e,c=``,l=0),c&&(s+=c),s&&(a.push(s),o.push(u)),a.length===1&&(u+=i),{accumWidth:u,lines:a,linesWidths:o}}var Ry=`__zr_style_`+Math.round(Math.random()*10),zy={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:`#000`,opacity:1,blend:`source-over`},By={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};zy[Ry]=!0;var Vy=[`z`,`z2`,`invisible`],Hy=[`invisible`],Uy=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype._init=function(t){for(var n=np(t),r=0;r<n.length;r++){var i=n[r];i===`style`?this.useStyle(t[i]):e.prototype.attrKV.call(this,i,t[i])}this.style||this.useStyle({})},t.prototype.beforeBrush=function(){},t.prototype.afterBrush=function(){},t.prototype.innerBeforeBrush=function(){},t.prototype.innerAfterBrush=function(){},t.prototype.shouldBePainted=function(e,t,n,r){var i=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&Ky(this,e,t)||i&&!i[0]&&!i[3])return!1;if(n&&this.__clipPaths){for(var a=0;a<this.__clipPaths.length;++a)if(this.__clipPaths[a].isZeroArea())return!1}if(r&&this.parent)for(var o=this.parent;o;){if(o.ignore)return!1;o=o.parent}return!0},t.prototype.contain=function(e,t){return this.rectContain(e,t)},t.prototype.traverse=function(e,t){e.call(t,this)},t.prototype.rectContain=function(e,t){var n=this.transformCoordToLocal(e,t);return this.getBoundingRect().contain(n[0],n[1])},t.prototype.getPaintRect=function(){var e=this._paintRect;if(!this._paintRect||this.__dirty){var t=this.transform,n=this.getBoundingRect(),r=this.style,i=r.shadowBlur||0,a=r.shadowOffsetX||0,o=r.shadowOffsetY||0;e=this._paintRect||=new $(0,0,0,0),t?$.applyTransform(e,n,t):e.copy(n),(i||a||o)&&(e.width+=i*2+Math.abs(a),e.height+=i*2+Math.abs(o),e.x=Math.min(e.x,e.x+a-i),e.y=Math.min(e.y,e.y+o-i));var s=this.dirtyRectTolerance;e.isZero()||(e.x=Math.floor(e.x-s),e.y=Math.floor(e.y-s),e.width=Math.ceil(e.width+1+s*2),e.height=Math.ceil(e.height+1+s*2))}return e},t.prototype.setPrevPaintRect=function(e){e?(this._prevPaintRect=this._prevPaintRect||new $(0,0,0,0),this._prevPaintRect.copy(e)):this._prevPaintRect=null},t.prototype.getPrevPaintRect=function(){return this._prevPaintRect},t.prototype.animateStyle=function(e){return this.animate(`style`,e)},t.prototype.updateDuringAnimation=function(e){e===`style`?this.dirtyStyle():this.markRedraw()},t.prototype.attrKV=function(t,n){t===`style`?this.style?this.setStyle(n):this.useStyle(n):e.prototype.attrKV.call(this,t,n)},t.prototype.setStyle=function(e,t){return typeof e==`string`?this.style[e]=t:K(this.style,e),this.dirtyStyle(),this},t.prototype.dirtyStyle=function(e){e||this.markRedraw(),this.__dirty|=2,this._rect&&=null},t.prototype.dirty=function(){this.dirtyStyle()},t.prototype.styleChanged=function(){return!!(this.__dirty&2)},t.prototype.styleUpdated=function(){this.__dirty&=-3},t.prototype.createStyle=function(e){return kp(zy,e)},t.prototype.useStyle=function(e){e[Ry]||(e=this.createStyle(e)),this.__inHover?this.__hoverStyle=e:this.style=e,this.dirtyStyle()},t.prototype.isStyleObject=function(e){return e[Ry]},t.prototype._innerSaveToNormal=function(t){e.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.style&&!n.style&&(n.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(t,n,Vy)},t.prototype._applyStateObj=function(t,n,r,i,a,o){e.prototype._applyStateObj.call(this,t,n,r,i,a,o);var s=!(n&&i),c;if(n&&n.style?a?i?c=n.style:(c=this._mergeStyle(this.createStyle(),r.style),this._mergeStyle(c,n.style)):(c=this._mergeStyle(this.createStyle(),i?this.style:r.style),this._mergeStyle(c,n.style)):s&&(c=r.style),c){if(a){var l=this.style;if(this.style=this.createStyle(s?{}:l),s)for(var u=np(l),d=0;d<u.length;d++){var f=u[d];f in c&&(c[f]=c[f],this.style[f]=l[f])}for(var p=np(c),d=0;d<p.length;d++){var f=p[d];this.style[f]=this.style[f]}this._transitionState(t,{style:c},o,this.getAnimationStyleProps())}else this.useStyle(c)}for(var m=this.__inHover?Hy:Vy,d=0;d<m.length;d++){var f=m[d];n&&n[f]!=null?this[f]=n[f]:s&&r[f]!=null&&(this[f]=r[f])}},t.prototype._mergeStates=function(t){for(var n=e.prototype._mergeStates.call(this,t),r,i=0;i<t.length;i++){var a=t[i];a.style&&(r||={},this._mergeStyle(r,a.style))}return r&&(n.style=r),n},t.prototype._mergeStyle=function(e,t){return K(e,t),e},t.prototype.getAnimationStyleProps=function(){return By},t.initDefaultProps=(function(){var e=t.prototype;e.type=`displayable`,e.invisible=!1,e.z=0,e.z2=0,e.zlevel=0,e.culling=!1,e.cursor=`pointer`,e.rectHover=!1,e.incremental=!1,e._rect=null,e.dirtyRectTolerance=0,e.__dirty=3})(),t}(U_),Wy=new $(0,0,0,0),Gy=new $(0,0,0,0);function Ky(e,t,n){return Wy.copy(e.getBoundingRect()),e.transform&&Wy.applyTransform(e.transform),Gy.width=t,Gy.height=n,!Wy.intersect(Gy)}var qy=Math.min,Jy=Math.max,Yy=Math.sin,Xy=Math.cos,Zy=Math.PI*2,Qy=Pp(),$y=Pp(),eb=Pp();function tb(e,t,n){if(e.length!==0){for(var r=e[0],i=r[0],a=r[0],o=r[1],s=r[1],c=1;c<e.length;c++)r=e[c],i=qy(i,r[0]),a=Jy(a,r[0]),o=qy(o,r[1]),s=Jy(s,r[1]);t[0]=i,t[1]=o,n[0]=a,n[1]=s}}function nb(e,t,n,r,i,a){i[0]=qy(e,n),i[1]=qy(t,r),a[0]=Jy(e,n),a[1]=Jy(t,r)}var rb=[],ib=[];function ab(e,t,n,r,i,a,o,s,c,l){var u=Ph,d=jh,f=u(e,n,i,o,rb);c[0]=1/0,c[1]=1/0,l[0]=-1/0,l[1]=-1/0;for(var p=0;p<f;p++){var m=d(e,n,i,o,rb[p]);c[0]=qy(m,c[0]),l[0]=Jy(m,l[0])}f=u(t,r,a,s,ib);for(var p=0;p<f;p++){var h=d(t,r,a,s,ib[p]);c[1]=qy(h,c[1]),l[1]=Jy(h,l[1])}c[0]=qy(e,c[0]),l[0]=Jy(e,l[0]),c[0]=qy(o,c[0]),l[0]=Jy(o,l[0]),c[1]=qy(t,c[1]),l[1]=Jy(t,l[1]),c[1]=qy(s,c[1]),l[1]=Jy(s,l[1])}function ob(e,t,n,r,i,a,o,s){var c=Vh,l=Rh,u=Jy(qy(c(e,n,i),1),0),d=Jy(qy(c(t,r,a),1),0),f=l(e,n,i,u),p=l(t,r,a,d);o[0]=qy(e,i,f),o[1]=qy(t,a,p),s[0]=Jy(e,i,f),s[1]=Jy(t,a,p)}function sb(e,t,n,r,i,a,o,s,c){var l=Xp,u=Zp,d=Math.abs(i-a);if(d%Zy<1e-4&&d>1e-4)s[0]=e-n,s[1]=t-r,c[0]=e+n,c[1]=t+r;else{if(Qy[0]=Xy(i)*n+e,Qy[1]=Yy(i)*r+t,$y[0]=Xy(a)*n+e,$y[1]=Yy(a)*r+t,l(s,Qy,$y),u(c,Qy,$y),i%=Zy,i<0&&(i+=Zy),a%=Zy,a<0&&(a+=Zy),i>a&&!o?a+=Zy:i<a&&o&&(i+=Zy),o){var f=a;a=i,i=f}for(var p=0;p<a;p+=Math.PI/2)p>i&&(eb[0]=Xy(p)*n+e,eb[1]=Yy(p)*r+t,l(s,eb,s),u(c,eb,c))}}var cb={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},lb=[],ub=[],db=[],fb=[],pb=[],mb=[],hb=Math.min,gb=Math.max,_b=Math.cos,vb=Math.sin,yb=Math.abs,bb=Math.PI,xb=bb*2,Sb=typeof Float32Array<`u`,Cb=[];function wb(e){return Math.round(e/bb*1e8)/1e8%2*bb}function Tb(e,t){var n=wb(e[0]);n<0&&(n+=xb);var r=n-e[0],i=e[1];i+=r,!t&&i-n>=xb?i=n+xb:t&&n-i>=xb?i=n-xb:!t&&n>i?i=n+(xb-wb(n-i)):t&&n<i&&(i=n-(xb-wb(i-n))),e[0]=n,e[1]=i}var Eb=function(){function e(e){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,e&&(this._saveData=!1),this._saveData&&(this.data=[])}return e.prototype.increaseVersion=function(){this._version++},e.prototype.getVersion=function(){return this._version},e.prototype.setScale=function(e,t,n){n||=0,n>0&&(this._ux=yb(n/m_/e)||0,this._uy=yb(n/m_/t)||0)},e.prototype.setDPR=function(e){this.dpr=e},e.prototype.setContext=function(e){this._ctx=e},e.prototype.getContext=function(){return this._ctx},e.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},e.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},e.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData(cb.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},e.prototype.lineTo=function(e,t){var n=yb(e-this._xi),r=yb(t-this._yi),i=n>this._ux||r>this._uy;if(this.addData(cb.L,e,t),this._ctx&&i&&this._ctx.lineTo(e,t),i)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var a=n*n+r*r;a>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=a)}return this},e.prototype.bezierCurveTo=function(e,t,n,r,i,a){return this._drawPendingPt(),this.addData(cb.C,e,t,n,r,i,a),this._ctx&&this._ctx.bezierCurveTo(e,t,n,r,i,a),this._xi=i,this._yi=a,this},e.prototype.quadraticCurveTo=function(e,t,n,r){return this._drawPendingPt(),this.addData(cb.Q,e,t,n,r),this._ctx&&this._ctx.quadraticCurveTo(e,t,n,r),this._xi=n,this._yi=r,this},e.prototype.arc=function(e,t,n,r,i,a){this._drawPendingPt(),Cb[0]=r,Cb[1]=i,Tb(Cb,a),r=Cb[0],i=Cb[1];var o=i-r;return this.addData(cb.A,e,t,n,n,r,o,0,+!a),this._ctx&&this._ctx.arc(e,t,n,r,i,a),this._xi=_b(i)*n+e,this._yi=vb(i)*n+t,this},e.prototype.arcTo=function(e,t,n,r,i){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,n,r,i),this},e.prototype.rect=function(e,t,n,r){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,n,r),this.addData(cb.R,e,t,n,r),this},e.prototype.closePath=function(){this._drawPendingPt(),this.addData(cb.Z);var e=this._ctx,t=this._x0,n=this._y0;return e&&e.closePath(),this._xi=t,this._yi=n,this},e.prototype.fill=function(e){e&&e.fill(),this.toStatic()},e.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},e.prototype.len=function(){return this._len},e.prototype.setData=function(e){var t=e.length;!(this.data&&this.data.length===t)&&Sb&&(this.data=new Float32Array(t));for(var n=0;n<t;n++)this.data[n]=e[n];this._len=t},e.prototype.appendPath=function(e){e instanceof Array||(e=[e]);for(var t=e.length,n=0,r=this._len,i=0;i<t;i++)n+=e[i].len();Sb&&this.data instanceof Float32Array&&(this.data=new Float32Array(r+n));for(var i=0;i<t;i++)for(var a=e[i].data,o=0;o<a.length;o++)this.data[r++]=a[o];this._len=r},e.prototype.addData=function(e,t,n,r,i,a,o,s,c){if(this._saveData){var l=this.data;this._len+arguments.length>l.length&&(this._expandData(),l=this.data);for(var u=0;u<arguments.length;u++)l[this._len++]=arguments[u]}},e.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},e.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var e=[],t=0;t<this._len;t++)e[t]=this.data[t];this.data=e}},e.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var e=this.data;e instanceof Array&&(e.length=this._len,Sb&&this._len>11&&(this.data=new Float32Array(e)))}},e.prototype.getBoundingRect=function(){db[0]=db[1]=pb[0]=pb[1]=Number.MAX_VALUE,fb[0]=fb[1]=mb[0]=mb[1]=-Number.MAX_VALUE;for(var e=this.data,t=0,n=0,r=0,i=0,a=0;a<this._len;){var o=e[a++],s=a===1;switch(s&&(t=e[a],n=e[a+1],r=t,i=n),o){case cb.M:t=r=e[a++],n=i=e[a++],pb[0]=r,pb[1]=i,mb[0]=r,mb[1]=i;break;case cb.L:nb(t,n,e[a],e[a+1],pb,mb),t=e[a++],n=e[a++];break;case cb.C:ab(t,n,e[a++],e[a++],e[a++],e[a++],e[a],e[a+1],pb,mb),t=e[a++],n=e[a++];break;case cb.Q:ob(t,n,e[a++],e[a++],e[a],e[a+1],pb,mb),t=e[a++],n=e[a++];break;case cb.A:var c=e[a++],l=e[a++],u=e[a++],d=e[a++],f=e[a++],p=e[a++]+f;a+=1;var m=!e[a++];s&&(r=_b(f)*u+c,i=vb(f)*d+l),sb(c,l,u,d,f,p,m,pb,mb),t=_b(p)*u+c,n=vb(p)*d+l;break;case cb.R:r=t=e[a++],i=n=e[a++];var h=e[a++],g=e[a++];nb(r,i,r+h,i+g,pb,mb);break;case cb.Z:t=r,n=i}Xp(db,db,pb),Zp(fb,fb,mb)}return a===0&&(db[0]=db[1]=fb[0]=fb[1]=0),new $(db[0],db[1],fb[0]-db[0],fb[1]-db[1])},e.prototype._calculateLength=function(){var e=this.data,t=this._len,n=this._ux,r=this._uy,i=0,a=0,o=0,s=0;this._pathSegLen||=[];for(var c=this._pathSegLen,l=0,u=0,d=0;d<t;){var f=e[d++],p=d===1;p&&(i=e[d],a=e[d+1],o=i,s=a);var m=-1;switch(f){case cb.M:i=o=e[d++],a=s=e[d++];break;case cb.L:var h=e[d++],g=e[d++],_=h-i,v=g-a;(yb(_)>n||yb(v)>r||d===t-1)&&(m=Math.sqrt(_*_+v*v),i=h,a=g);break;case cb.C:var y=e[d++],b=e[d++],h=e[d++],g=e[d++],x=e[d++],S=e[d++];m=Lh(i,a,y,b,h,g,x,S,10),i=x,a=S;break;case cb.Q:var y=e[d++],b=e[d++],h=e[d++],g=e[d++];m=Wh(i,a,y,b,h,g,10),i=h,a=g;break;case cb.A:var C=e[d++],w=e[d++],T=e[d++],E=e[d++],D=e[d++],O=e[d++],k=O+D;d+=1,p&&(o=_b(D)*T+C,s=vb(D)*E+w),m=gb(T,E)*hb(xb,Math.abs(O)),i=_b(k)*T+C,a=vb(k)*E+w;break;case cb.R:o=i=e[d++],s=a=e[d++];var A=e[d++],ee=e[d++];m=A*2+ee*2;break;case cb.Z:var _=o-i,v=s-a;m=Math.sqrt(_*_+v*v),i=o,a=s}m>=0&&(c[u++]=m,l+=m)}return this._pathLen=l,l},e.prototype.rebuildPath=function(e,t){var n=this.data,r=this._ux,i=this._uy,a=this._len,o,s,c,l,u,d,f=t<1,p,m,h=0,g=0,_,v=0,y,b;if(!(f&&(this._pathSegLen||this._calculateLength(),p=this._pathSegLen,m=this._pathLen,_=t*m,!_)))lo:for(var x=0;x<a;){var S=n[x++],C=x===1;switch(C&&(c=n[x],l=n[x+1],o=c,s=l),S!==cb.L&&v>0&&(e.lineTo(y,b),v=0),S){case cb.M:o=c=n[x++],s=l=n[x++],e.moveTo(c,l);break;case cb.L:u=n[x++],d=n[x++];var w=yb(u-c),T=yb(d-l);if(w>r||T>i){if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;e.lineTo(c*(1-D)+u*D,l*(1-D)+d*D);break lo}h+=E}e.lineTo(u,d),c=u,l=d,v=0}else{var O=w*w+T*T;O>v&&(y=u,b=d,v=O)}break;case cb.C:var k=n[x++],A=n[x++],ee=n[x++],te=n[x++],ne=n[x++],re=n[x++];if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;Fh(c,k,ee,ne,D,lb),Fh(l,A,te,re,D,ub),e.bezierCurveTo(lb[1],ub[1],lb[2],ub[2],lb[3],ub[3]);break lo}h+=E}e.bezierCurveTo(k,A,ee,te,ne,re),c=ne,l=re;break;case cb.Q:var k=n[x++],A=n[x++],ee=n[x++],te=n[x++];if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;Hh(c,k,ee,D,lb),Hh(l,A,te,D,ub),e.quadraticCurveTo(lb[1],ub[1],lb[2],ub[2]);break lo}h+=E}e.quadraticCurveTo(k,A,ee,te),c=ee,l=te;break;case cb.A:var j=n[x++],ie=n[x++],ae=n[x++],oe=n[x++],se=n[x++],ce=n[x++],le=n[x++],ue=!n[x++],de=ae>oe?ae:oe,fe=yb(ae-oe)>.001,pe=se+ce,M=!1;if(f){var E=p[g++];h+E>_&&(pe=se+ce*(_-h)/E,M=!0),h+=E}if(fe&&e.ellipse?e.ellipse(j,ie,ae,oe,le,se,pe,ue):e.arc(j,ie,de,se,pe,ue),M)break lo;C&&(o=_b(se)*ae+j,s=vb(se)*oe+ie),c=_b(pe)*ae+j,l=vb(pe)*oe+ie;break;case cb.R:o=c=n[x],s=l=n[x+1],u=n[x++],d=n[x++];var me=n[x++],he=n[x++];if(f){var E=p[g++];if(h+E>_){var ge=_-h;e.moveTo(u,d),e.lineTo(u+hb(ge,me),d),ge-=me,ge>0&&e.lineTo(u+me,d+hb(ge,he)),ge-=he,ge>0&&e.lineTo(u+gb(me-ge,0),d+he),ge-=me,ge>0&&e.lineTo(u,d+gb(he-ge,0));break lo}h+=E}e.rect(u,d,me,he);break;case cb.Z:if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;e.lineTo(c*(1-D)+o*D,l*(1-D)+s*D);break lo}h+=E}e.closePath(),c=o,l=s}}},e.prototype.clone=function(){var t=new e,n=this.data;return t.data=n.slice?n.slice():Array.prototype.slice.call(n),t._len=this._len,t},e.CMD=cb,e.initDefaultProps=(function(){var t=e.prototype;t._saveData=!0,t._ux=0,t._uy=0,t._pendingPtDist=0,t._version=0})(),e}();function Db(e,t,n,r,i,a,o){if(i===0)return!1;var s=i,c=0,l=e;if(o>t+s&&o>r+s||o<t-s&&o<r-s||a>e+s&&a>n+s||a<e-s&&a<n-s)return!1;if(e!==n)c=(t-r)/(e-n),l=(e*r-n*t)/(e-n);else return Math.abs(a-e)<=s/2;var u=c*a-o+l;return u*u/(c*c+1)<=s/2*s/2}function Ob(e,t,n,r,i,a,o,s,c,l,u){if(c===0)return!1;var d=c;return u>t+d&&u>r+d&&u>a+d&&u>s+d||u<t-d&&u<r-d&&u<a-d&&u<s-d||l>e+d&&l>n+d&&l>i+d&&l>o+d||l<e-d&&l<n-d&&l<i-d&&l<o-d?!1:Ih(e,t,n,r,i,a,o,s,l,u,null)<=d/2}function kb(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;return c>t+l&&c>r+l&&c>a+l||c<t-l&&c<r-l&&c<a-l||s>e+l&&s>n+l&&s>i+l||s<e-l&&s<n-l&&s<i-l?!1:Uh(e,t,n,r,i,a,s,c,null)<=l/2}var Ab=Math.PI*2;function jb(e){return e%=Ab,e<0&&(e+=Ab),e}var Mb=Math.PI*2;function Nb(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;s-=e,c-=t;var u=Math.sqrt(s*s+c*c);if(u-l>n||u+l<n)return!1;if(Math.abs(r-i)%Mb<1e-4)return!0;if(a){var d=r;r=jb(i),i=jb(d)}else r=jb(r),i=jb(i);r>i&&(i+=Mb);var f=Math.atan2(c,s);return f<0&&(f+=Mb),f>=r&&f<=i||f+Mb>=r&&f+Mb<=i}function Pb(e,t,n,r,i,a){if(a>t&&a>r||a<t&&a<r||r===t)return 0;var o=(a-t)/(r-t),s=r<t?1:-1;(o===1||o===0)&&(s=r<t?.5:-.5);var c=o*(n-e)+e;return c===i?1/0:c>i?s:0}var Fb=Eb.CMD,Ib=Math.PI*2,Lb=1e-4;function Rb(e,t){return Math.abs(e-t)<Lb}var zb=[-1,-1,-1],Bb=[-1,-1];function Vb(){var e=Bb[0];Bb[0]=Bb[1],Bb[1]=e}function Hb(e,t,n,r,i,a,o,s,c,l){if(l>t&&l>r&&l>a&&l>s||l<t&&l<r&&l<a&&l<s)return 0;var u=Nh(t,r,a,s,l,zb);if(u===0)return 0;for(var d=0,f=-1,p=void 0,m=void 0,h=0;h<u;h++){var g=zb[h],_=g===0||g===1?.5:1;jh(e,n,i,o,g)<c||(f<0&&(f=Ph(t,r,a,s,Bb),Bb[1]<Bb[0]&&f>1&&Vb(),p=jh(t,r,a,s,Bb[0]),f>1&&(m=jh(t,r,a,s,Bb[1]))),f===2?g<Bb[0]?d+=p<t?_:-_:g<Bb[1]?d+=m<p?_:-_:d+=s<m?_:-_:g<Bb[0]?d+=p<t?_:-_:d+=s<p?_:-_)}return d}function Ub(e,t,n,r,i,a,o,s){if(s>t&&s>r&&s>a||s<t&&s<r&&s<a)return 0;var c=Bh(t,r,a,s,zb);if(c===0)return 0;var l=Vh(t,r,a);if(l>=0&&l<=1){for(var u=0,d=Rh(t,r,a,l),f=0;f<c;f++){var p=zb[f]===0||zb[f]===1?.5:1,m=Rh(e,n,i,zb[f]);m<o||(zb[f]<l?u+=d<t?p:-p:u+=a<d?p:-p)}return u}var p=zb[0]===0||zb[0]===1?.5:1,m=Rh(e,n,i,zb[0]);return m<o?0:a<t?p:-p}function Wb(e,t,n,r,i,a,o,s){if(s-=t,s>n||s<-n)return 0;var c=Math.sqrt(n*n-s*s);zb[0]=-c,zb[1]=c;var l=Math.abs(r-i);if(l<1e-4)return 0;if(l>=Ib-1e-4){r=0,i=Ib;var u=a?1:-1;return o>=zb[0]+e&&o<=zb[1]+e?u:0}if(r>i){var d=r;r=i,i=d}r<0&&(r+=Ib,i+=Ib);for(var f=0,p=0;p<2;p++){var m=zb[p];if(m+e>o){var h=Math.atan2(s,m),u=a?1:-1;h<0&&(h=Ib+h),(h>=r&&h<=i||h+Ib>=r&&h+Ib<=i)&&(h>Math.PI/2&&h<Math.PI*1.5&&(u=-u),f+=u)}}return f}function Gb(e,t,n,r,i){for(var a=e.data,o=e.len(),s=0,c=0,l=0,u=0,d=0,f,p,m=0;m<o;){var h=a[m++],g=m===1;switch(h===Fb.M&&m>1&&(n||(s+=Pb(c,l,u,d,r,i))),g&&(c=a[m],l=a[m+1],u=c,d=l),h){case Fb.M:u=a[m++],d=a[m++],c=u,l=d;break;case Fb.L:if(n){if(Db(c,l,a[m],a[m+1],t,r,i))return!0}else s+=Pb(c,l,a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case Fb.C:if(n){if(Ob(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=Hb(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case Fb.Q:if(n){if(kb(c,l,a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=Ub(c,l,a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case Fb.A:var _=a[m++],v=a[m++],y=a[m++],b=a[m++],x=a[m++],S=a[m++];m+=1;var C=!!(1-a[m++]);f=Math.cos(x)*y+_,p=Math.sin(x)*b+v,g?(u=f,d=p):s+=Pb(c,l,f,p,r,i);var w=(r-_)*b/y+_;if(n){if(Nb(_,v,b,x,x+S,C,t,w,i))return!0}else s+=Wb(_,v,b,x,x+S,C,w,i);c=Math.cos(x+S)*y+_,l=Math.sin(x+S)*b+v;break;case Fb.R:u=c=a[m++],d=l=a[m++];var T=a[m++],E=a[m++];if(f=u+T,p=d+E,n){if(Db(u,d,f,d,t,r,i)||Db(f,d,f,p,t,r,i)||Db(f,p,u,p,t,r,i)||Db(u,p,u,d,t,r,i))return!0}else s+=Pb(f,d,f,p,r,i),s+=Pb(u,p,u,d,r,i);break;case Fb.Z:if(n){if(Db(c,l,u,d,t,r,i))return!0}else s+=Pb(c,l,u,d,r,i);c=u,l=d}}return!n&&!Rb(l,d)&&(s+=Pb(c,l,u,d,r,i)||0),s!==0}function Kb(e,t,n){return Gb(e,0,!1,t,n)}function qb(e,t,n,r){return Gb(e,t,!0,n,r)}var Jb=Jf({fill:`#000`,stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:`butt`,miterLimit:10,strokeNoScale:!1,strokeFirst:!1},zy),Yb={style:Jf({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},By.style)},Xb=D_.concat([`invisible`,`culling`,`z`,`z2`,`zlevel`,`parent`]),Zb=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.update=function(){var n=this;e.prototype.update.call(this);var r=this.style;if(r.decal){var i=this._decalEl=this._decalEl||new t;i.buildPath===t.prototype.buildPath&&(i.buildPath=function(e){n.buildPath(e,n.shape)}),i.silent=!0;var a=i.style;for(var o in r)a[o]!==r[o]&&(a[o]=r[o]);a.fill=r.fill?r.decal:null,a.decal=null,a.shadowColor=null,r.strokeFirst&&(a.stroke=null);for(var s=0;s<Xb.length;++s)i[Xb[s]]=this[Xb[s]];i.__dirty|=1}else this._decalEl&&=null},t.prototype.getDecalElement=function(){return this._decalEl},t.prototype._init=function(t){var n=np(t);this.shape=this.getDefaultShape();var r=this.getDefaultStyle();r&&this.useStyle(r);for(var i=0;i<n.length;i++){var a=n[i],o=t[a];a===`style`?this.style?K(this.style,o):this.useStyle(o):a===`shape`?K(this.shape,o):e.prototype.attrKV.call(this,a,o)}this.style||this.useStyle({})},t.prototype.getDefaultStyle=function(){return null},t.prototype.getDefaultShape=function(){return{}},t.prototype.canBeInsideText=function(){return this.hasFill()},t.prototype.getInsideTextFill=function(){var e=this.style.fill;if(e!==`none`){if(Y(e)){var t=vg(e,0);return t>.5?g_:t>.2?v_:__}if(e)return __}return g_},t.prototype.getInsideTextStroke=function(e){var t=this.style.fill;if(Y(t)){var n=this.__zr;if(!!(n&&n.isDarkMode())==vg(e,0)<.4)return t}},t.prototype.buildPath=function(e,t,n){},t.prototype.pathUpdated=function(){this.__dirty&=-5},t.prototype.getUpdatedPathProxy=function(e){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,e),this.path},t.prototype.createPathProxy=function(){this.path=new Eb(!1)},t.prototype.hasStroke=function(){var e=this.style,t=e.stroke;return!(t==null||t===`none`||!(e.lineWidth>0))},t.prototype.hasFill=function(){var e=this.style.fill;return e!=null&&e!==`none`},t.prototype.getBoundingRect=function(){var e=this._rect,t=this.style,n=!e;if(n){var r=!1;this.path||(r=!0,this.createPathProxy());var i=this.path;(r||this.__dirty&4)&&(i.beginPath(),this.buildPath(i,this.shape,!1),this.pathUpdated()),e=i.getBoundingRect()}if(this._rect=e,this.hasStroke()&&this.path&&this.path.len()>0){var a=this._rectStroke||=e.clone();if(this.__dirty||n){a.copy(e);var o=t.strokeNoScale?this.getLineScale():1,s=t.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;s=Math.max(s,c??4)}o>1e-10&&(a.width+=s/o,a.height+=s/o,a.x-=s/o/2,a.y-=s/o/2)}return a}return e},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t),r=this.getBoundingRect(),i=this.style;if(e=n[0],t=n[1],r.contain(e,t)){var a=this.path;if(this.hasStroke()){var o=i.lineWidth,s=i.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(this.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),qb(a,o/s,e,t)))return!0}if(this.hasFill())return Kb(a,e,t)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=4,this._rect&&=null,this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(e){return this.animate(`shape`,e)},t.prototype.updateDuringAnimation=function(e){e===`style`?this.dirtyStyle():e===`shape`?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(t,n){t===`shape`?this.setShape(n):e.prototype.attrKV.call(this,t,n)},t.prototype.setShape=function(e,t){var n=this.shape;return n||=this.shape={},typeof e==`string`?n[e]=t:K(n,e),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&4)},t.prototype.createStyle=function(e){return kp(Jb,e)},t.prototype._innerSaveToNormal=function(t){e.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.shape&&!n.shape&&(n.shape=K({},this.shape))},t.prototype._applyStateObj=function(t,n,r,i,a,o){e.prototype._applyStateObj.call(this,t,n,r,i,a,o);var s=!(n&&i),c;if(n&&n.shape?a?i?c=n.shape:(c=K({},r.shape),K(c,n.shape)):(c=K({},i?this.shape:r.shape),K(c,n.shape)):s&&(c=r.shape),c){if(a){this.shape=K({},this.shape);for(var l={},u=np(c),d=0;d<u.length;d++){var f=u[d];typeof c[f]==`object`?this.shape[f]=c[f]:l[f]=c[f]}this._transitionState(t,{shape:l},o)}else this.shape=c,this.dirtyShape()}},t.prototype._mergeStates=function(t){for(var n=e.prototype._mergeStates.call(this,t),r,i=0;i<t.length;i++){var a=t[i];a.shape&&(r||={},this._mergeStyle(r,a.shape))}return r&&(n.shape=r),n},t.prototype.getAnimationStyleProps=function(){return Yb},t.prototype.isZeroArea=function(){return!1},t.extend=function(e){var n=function(t){U(n,t);function n(n){var r=t.call(this,n)||this;return e.init&&e.init.call(r,n),r}return n.prototype.getDefaultStyle=function(){return G(e.style)},n.prototype.getDefaultShape=function(){return G(e.shape)},n}(t);for(var r in e)typeof e[r]==`function`&&(n.prototype[r]=e[r]);return n},t.initDefaultProps=(function(){var e=t.prototype;e.type=`path`,e.strokeContainThreshold=5,e.segmentIgnoreThreshold=0,e.subPixelOptimize=!1,e.autoBatch=!1,e.__dirty=7})(),t}(Uy),Qb=Jf({strokeFirst:!0,font:Ef,x:0,y:0,textAlign:`left`,textBaseline:`top`,miterLimit:2},Jb),$b=function(e){U(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.hasStroke=function(){var e=this.style,t=e.stroke;return t!=null&&t!==`none`&&e.lineWidth>0},t.prototype.hasFill=function(){var e=this.style.fill;return e!=null&&e!==`none`},t.prototype.createStyle=function(e){return kp(Qb,e)},t.prototype.setBoundingRect=function(e){this._rect=e},t.prototype.getBoundingRect=function(){var e=this.style;if(!this._rect){var t=e.text;t==null?t=``:t+=``;var n=M_(t,e.font,e.textAlign,e.textBaseline);if(n.x+=e.x||0,n.y+=e.y||0,this.hasStroke()){var r=e.lineWidth;n.x-=r/2,n.y-=r/2,n.width+=r,n.height+=r}this._rect=n}return this._rect},t.initDefaultProps=(function(){var e=t.prototype;e.dirtyRectTolerance=10})(),t}(Uy);$b.prototype.type=`tspan`;var ex=Jf({x:0,y:0},zy),tx={style:Jf({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},By.style)};function nx(e){return!!(e&&typeof e!=`string`&&e.width&&e.height)}var rx=function(e){U(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.createStyle=function(e){return kp(ex,e)},t.prototype._getSize=function(e){var t=this.style,n=t[e];if(n!=null)return n;var r=nx(t.image)?t.image:this.__image;if(!r)return 0;var i=e===`width`?`height`:`width`,a=t[i];return a==null?r[e]:r[e]/r[i]*a},t.prototype.getWidth=function(){return this._getSize(`width`)},t.prototype.getHeight=function(){return this._getSize(`height`)},t.prototype.getAnimationStyleProps=function(){return tx},t.prototype.getBoundingRect=function(){var e=this.style;return this._rect||=new $(e.x||0,e.y||0,this.getWidth(),this.getHeight()),this._rect},t}(Uy);rx.prototype.type=`image`;function ix(e,t){var n=t.x,r=t.y,i=t.width,a=t.height,o=t.r,s,c,l,u;i<0&&(n+=i,i=-i),a<0&&(r+=a,a=-a),typeof o==`number`?s=c=l=u=o:o instanceof Array?o.length===1?s=c=l=u=o[0]:o.length===2?(s=l=o[0],c=u=o[1]):o.length===3?(s=o[0],c=u=o[1],l=o[2]):(s=o[0],c=o[1],l=o[2],u=o[3]):s=c=l=u=0;var d;s+c>i&&(d=s+c,s*=i/d,c*=i/d),l+u>i&&(d=l+u,l*=i/d,u*=i/d),c+l>a&&(d=c+l,c*=a/d,l*=a/d),s+u>a&&(d=s+u,s*=a/d,u*=a/d),e.moveTo(n+s,r),e.lineTo(n+i-c,r),c!==0&&e.arc(n+i-c,r+c,c,-Math.PI/2,0),e.lineTo(n+i,r+a-l),l!==0&&e.arc(n+i-l,r+a-l,l,0,Math.PI/2),e.lineTo(n+u,r+a),u!==0&&e.arc(n+u,r+a-u,u,Math.PI/2,Math.PI),e.lineTo(n,r+s),s!==0&&e.arc(n+s,r+s,s,Math.PI,Math.PI*1.5)}var ax=Math.round;function ox(e,t,n){if(t){var r=t.x1,i=t.x2,a=t.y1,o=t.y2;e.x1=r,e.x2=i,e.y1=a,e.y2=o;var s=n&&n.lineWidth;return s&&(ax(r*2)===ax(i*2)&&(e.x1=e.x2=cx(r,s,!0)),ax(a*2)===ax(o*2)&&(e.y1=e.y2=cx(a,s,!0))),e}}function sx(e,t,n){if(t){var r=t.x,i=t.y,a=t.width,o=t.height;e.x=r,e.y=i,e.width=a,e.height=o;var s=n&&n.lineWidth;return s&&(e.x=cx(r,s,!0),e.y=cx(i,s,!0),e.width=Math.max(cx(r+a,s,!1)-e.x,a===0?0:1),e.height=Math.max(cx(i+o,s,!1)-e.y,o===0?0:1)),e}}function cx(e,t,n){if(!t)return e;var r=ax(e*2);return(r+ax(t))%2==0?r/2:(r+(n?1:-1))/2}var lx=function(){function e(){this.x=0,this.y=0,this.width=0,this.height=0}return e}(),ux={},dx=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new lx},t.prototype.buildPath=function(e,t){var n,r,i,a;if(this.subPixelOptimize){var o=sx(ux,t,this.style);n=o.x,r=o.y,i=o.width,a=o.height,o.r=t.r,t=o}else n=t.x,r=t.y,i=t.width,a=t.height;t.r?ix(e,t):e.rect(n,r,i,a)},t.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},t}(Zb);dx.prototype.type=`rect`;var fx={fill:`#000`},px=2,mx={style:Jf({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},By.style)},hx=function(e){U(t,e);function t(t){var n=e.call(this)||this;return n.type=`text`,n._children=[],n._defaultStyle=fx,n.attr(t),n}return t.prototype.childrenRef=function(){return this._children},t.prototype.update=function(){e.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;t<this._children.length;t++){var n=this._children[t];n.zlevel=this.zlevel,n.z=this.z,n.z2=this.z2,n.culling=this.culling,n.cursor=this.cursor,n.invisible=this.invisible}},t.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):e.prototype.updateTransform.call(this)},t.prototype.getLocalTransform=function(t){var n=this.innerTransformable;return n?n.getLocalTransform(t):e.prototype.getLocalTransform.call(this,t)},t.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),e.prototype.getComputedTransform.call(this)},t.prototype._updateSubTexts=function(){this._childCursor=0,Sx(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},t.prototype.addSelfToZr=function(t){e.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=t},t.prototype.removeSelfFromZr=function(t){e.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=null},t.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var e=new $(0,0,0,0),t=this._children,n=[],r=null,i=0;i<t.length;i++){var a=t[i],o=a.getBoundingRect(),s=a.getLocalTransform(n);s?(e.copy(o),e.applyTransform(s),r||=e.clone(),r.union(e)):(r||=o.clone(),r.union(o))}this._rect=r||e}return this._rect},t.prototype.setDefaultTextStyle=function(e){this._defaultStyle=e||fx},t.prototype.setTextContent=function(e){},t.prototype._mergeStyle=function(e,t){if(!t)return e;var n=t.rich,r=e.rich||n&&{};return K(e,t),n&&r?(this._mergeRich(r,n),e.rich=r):r&&(e.rich=r),e},t.prototype._mergeRich=function(e,t){for(var n=np(t),r=0;r<n.length;r++){var i=n[r];e[i]=e[i]||{},K(e[i],t[i])}},t.prototype.getAnimationStyleProps=function(){return mx},t.prototype._getOrCreateChild=function(e){var t=this._children[this._childCursor];return t&&t instanceof e||(t=new e),this._children[this._childCursor++]=t,t.__zr=this.__zr,t.parent=this,t},t.prototype._updatePlainTexts=function(){var e=this.style,t=e.font||`12px sans-serif`,n=e.padding,r=Oy(Ox(e),e),i=kx(e),a=!!e.backgroundColor,o=r.outerHeight,s=r.outerWidth,c=r.contentWidth,l=r.lines,u=r.lineHeight,d=this._defaultStyle;this.isTruncated=!!r.isTruncated;var f=e.x||0,p=e.y||0,m=e.align||d.align||`left`,h=e.verticalAlign||d.verticalAlign||`top`,g=f,_=P_(p,r.contentHeight,h);if(i||n){var v=N_(f,s,m),y=P_(p,o,h);i&&this._renderBackground(e,e,v,y,s,o)}_+=u/2,n&&(g=Dx(f,m,n),h===`top`?_+=n[0]:h===`bottom`&&(_-=n[2]));for(var b=0,x=!1,S=Ex(`fill`in e?e.fill:(x=!0,d.fill)),C=Tx(`stroke`in e?e.stroke:!a&&(!d.autoStroke||x)?(b=px,d.stroke):null),w=e.textShadowBlur>0,T=e.width!=null&&(e.overflow===`truncate`||e.overflow===`break`||e.overflow===`breakAll`),E=r.calculatedLineHeight,D=0;D<l.length;D++){var O=this._getOrCreateChild($b),k=O.createStyle();O.useStyle(k),k.text=l[D],k.x=g,k.y=_,m&&(k.textAlign=m),k.textBaseline=`middle`,k.opacity=e.opacity,k.strokeFirst=!0,w&&(k.shadowBlur=e.textShadowBlur||0,k.shadowColor=e.textShadowColor||`transparent`,k.shadowOffsetX=e.textShadowOffsetX||0,k.shadowOffsetY=e.textShadowOffsetY||0),k.stroke=C,k.fill=S,C&&(k.lineWidth=e.lineWidth||b,k.lineDash=e.lineDash,k.lineDashOffset=e.lineDashOffset||0),k.font=t,bx(k,e),_+=u,T&&O.setBoundingRect(new $(N_(k.x,c,k.textAlign),P_(k.y,E,k.textBaseline),c,E))}},t.prototype._updateRichTexts=function(){var e=this.style,t=My(Ox(e),e),n=t.width,r=t.outerWidth,i=t.outerHeight,a=e.padding,o=e.x||0,s=e.y||0,c=this._defaultStyle,l=e.align||c.align,u=e.verticalAlign||c.verticalAlign;this.isTruncated=!!t.isTruncated;var d=N_(o,r,l),f=P_(s,i,u),p=d,m=f;a&&(p+=a[3],m+=a[0]);var h=p+n;kx(e)&&this._renderBackground(e,e,d,f,r,i);for(var g=!!e.backgroundColor,_=0;_<t.lines.length;_++){for(var v=t.lines[_],y=v.tokens,b=y.length,x=v.lineHeight,S=v.width,C=0,w=p,T=h,E=b-1,D=void 0;C<b&&(D=y[C],!D.align||D.align===`left`);)this._placeToken(D,e,x,m,w,`left`,g),S-=D.width,w+=D.width,C++;for(;E>=0&&(D=y[E],D.align===`right`);)this._placeToken(D,e,x,m,T,`right`,g),S-=D.width,T-=D.width,E--;for(w+=(n-(w-p)-(h-T)-S)/2;C<=E;)D=y[C],this._placeToken(D,e,x,m,w+D.width/2,`center`,g),w+=D.width,C++;m+=x}},t.prototype._placeToken=function(e,t,n,r,i,a,o){var s=t.rich[e.styleName]||{};s.text=e.text;var c=e.verticalAlign,l=r+n/2;c===`top`?l=r+e.height/2:c===`bottom`&&(l=r+n-e.height/2),!e.isLineHolder&&kx(s)&&this._renderBackground(s,t,a===`right`?i-e.width:a===`center`?i-e.width/2:i,l-e.height/2,e.width,e.height);var u=!!s.backgroundColor,d=e.textPadding;d&&(i=Dx(i,a,d),l-=e.height/2-d[0]-e.innerHeight/2);var f=this._getOrCreateChild($b),p=f.createStyle();f.useStyle(p);var m=this._defaultStyle,h=!1,g=0,_=Ex(`fill`in s?s.fill:`fill`in t?t.fill:(h=!0,m.fill)),v=Tx(`stroke`in s?s.stroke:`stroke`in t?t.stroke:!u&&!o&&(!m.autoStroke||h)?(g=px,m.stroke):null),y=s.textShadowBlur>0||t.textShadowBlur>0;p.text=e.text,p.x=i,p.y=l,y&&(p.shadowBlur=s.textShadowBlur||t.textShadowBlur||0,p.shadowColor=s.textShadowColor||t.textShadowColor||`transparent`,p.shadowOffsetX=s.textShadowOffsetX||t.textShadowOffsetX||0,p.shadowOffsetY=s.textShadowOffsetY||t.textShadowOffsetY||0),p.textAlign=a,p.textBaseline=`middle`,p.font=e.font||`12px sans-serif`,p.opacity=gp(s.opacity,t.opacity,1),bx(p,s),v&&(p.lineWidth=gp(s.lineWidth,t.lineWidth,g),p.lineDash=Z(s.lineDash,t.lineDash),p.lineDashOffset=t.lineDashOffset||0,p.stroke=v),_&&(p.fill=_);var b=e.contentWidth,x=e.contentHeight;f.setBoundingRect(new $(N_(p.x,b,p.textAlign),P_(p.y,x,p.textBaseline),b,x))},t.prototype._renderBackground=function(e,t,n,r,i,a){var o=e.backgroundColor,s=e.borderWidth,c=e.borderColor,l=o&&o.image,u=o&&!l,d=e.borderRadius,f=this,p,m;if(u||e.lineHeight||s&&c){p=this._getOrCreateChild(dx),p.useStyle(p.createStyle()),p.style.fill=null;var h=p.shape;h.x=n,h.y=r,h.width=i,h.height=a,h.r=d,p.dirtyShape()}if(u){var g=p.style;g.fill=o||null,g.fillOpacity=Z(e.fillOpacity,1)}else if(l){m=this._getOrCreateChild(rx),m.onload=function(){f.dirtyStyle()};var _=m.style;_.image=o.image,_.x=n,_.y=r,_.width=i,_.height=a}if(s&&c){var g=p.style;g.lineWidth=s,g.stroke=c,g.strokeOpacity=Z(e.strokeOpacity,1),g.lineDash=e.borderDash,g.lineDashOffset=e.borderDashOffset||0,p.strokeContainThreshold=0,p.hasFill()&&p.hasStroke()&&(g.strokeFirst=!0,g.lineWidth*=2)}var v=(p||m).style;v.shadowBlur=e.shadowBlur||0,v.shadowColor=e.shadowColor||`transparent`,v.shadowOffsetX=e.shadowOffsetX||0,v.shadowOffsetY=e.shadowOffsetY||0,v.opacity=gp(e.opacity,t.opacity,1)},t.makeFont=function(e){var t=``;return xx(e)&&(t=[e.fontStyle,e.fontWeight,yx(e.fontSize),e.fontFamily||`sans-serif`].join(` `)),t&&bp(t)||e.textFont||e.font},t}(Uy),gx={left:!0,right:1,center:1},_x={top:1,bottom:1,middle:1},vx=[`fontStyle`,`fontWeight`,`fontSize`,`fontFamily`];function yx(e){return typeof e==`string`&&(e.indexOf(`px`)!==-1||e.indexOf(`rem`)!==-1||e.indexOf(`em`)!==-1)?e:isNaN(+e)?`12px`:e+`px`}function bx(e,t){for(var n=0;n<vx.length;n++){var r=vx[n],i=t[r];i!=null&&(e[r]=i)}}function xx(e){return e.fontSize!=null||e.fontFamily||e.fontWeight}function Sx(e){return Cx(e),q(e.rich,Cx),e}function Cx(e){if(e){e.font=hx.makeFont(e);var t=e.align;t===`middle`&&(t=`center`),e.align=t==null||gx[t]?t:`left`;var n=e.verticalAlign;n===`center`&&(n=`middle`),e.verticalAlign=n==null||_x[n]?n:`top`,e.padding&&=vp(e.padding)}}function Tx(e,t){return e==null||t<=0||e===`transparent`||e===`none`?null:e.image||e.colorStops?`#000`:e}function Ex(e){return e==null||e===`none`?null:e.image||e.colorStops?`#000`:e}function Dx(e,t,n){return t===`right`?e-n[1]:t===`center`?e+n[3]/2-n[1]/2:e+n[3]}function Ox(e){var t=e.text;return t!=null&&(t+=``),t}function kx(e){return!!(e.backgroundColor||e.lineHeight||e.borderWidth&&e.borderColor)}var Ax=Kv(),jx=function(e,t,n,r){if(r){var i=Ax(r);i.dataIndex=n,i.dataType=t,i.seriesIndex=e,i.ssrType=`chart`,r.type===`group`&&r.traverse(function(r){var i=Ax(r);i.seriesIndex=e,i.dataIndex=n,i.dataType=t,i.ssrType=`chart`})}},Mx=1,Nx={},Px=Kv(),Fx=Kv(),Ix=[`emphasis`,`blur`,`select`],Lx=[`normal`,`emphasis`,`blur`,`select`],Rx=`highlight`,zx=`downplay`,Bx=`select`,Vx=`unselect`,Hx=`toggleSelect`;function Ux(e){return e!=null&&e!==`none`}function Wx(e,t,n){e.onHoverStateChange&&(e.hoverState||0)!==n&&e.onHoverStateChange(t),e.hoverState=n}function Gx(e){Wx(e,`emphasis`,2)}function Kx(e){e.hoverState===2&&Wx(e,`normal`,0)}function qx(e){Wx(e,`blur`,1)}function Jx(e){e.hoverState===1&&Wx(e,`normal`,0)}function Yx(e){e.selected=!0}function Xx(e){e.selected=!1}function Zx(e,t,n){t(e,n)}function Qx(e,t,n){Zx(e,t,n),e.isGroup&&e.traverse(function(e){Zx(e,t,n)})}function $x(e,t,n,r){for(var i=e.style,a={},o=0;o<t.length;o++){var s=t[o];a[s]=i[s]??(r&&r[s])}for(var o=0;o<e.animators.length;o++){var c=e.animators[o];c.__fromStateTransition&&c.__fromStateTransition.indexOf(n)<0&&c.targetName===`style`&&c.saveTo(a,t)}return a}function eS(e,t,n,r){var i=n&&Yf(n,`select`)>=0,a=!1;if(e instanceof Zb){var o=Px(e),s=i&&o.selectFill||o.normalFill,c=i&&o.selectStroke||o.normalStroke;if(Ux(s)||Ux(c)){r||={};var l=r.style||{};l.fill===`inherit`?(a=!0,r=K({},r),l=K({},l),l.fill=s):!Ux(l.fill)&&Ux(s)?(a=!0,r=K({},r),l=K({},l),l.fill=bg(s)):!Ux(l.stroke)&&Ux(c)&&(a||(r=K({},r),l=K({},l)),l.stroke=bg(c)),r.style=l}}if(r&&r.z2==null){a||(r=K({},r));var u=e.z2EmphasisLift;r.z2=e.z2+(u??10)}return r}function tS(e,t,n){if(n&&n.z2==null){n=K({},n);var r=e.z2SelectLift;n.z2=e.z2+(r??9)}return n}function nS(e,t,n){var r=Yf(e.currentStates,t)>=0,i=e.style.opacity,a=r?null:$x(e,[`opacity`],t,{opacity:1});n||={};var o=n.style||{};return o.opacity??(n=K({},n),o=K({opacity:r?i:a.opacity*.1},o),n.style=o),n}function rS(e,t){var n=this.states[e];if(this.style){if(e===`emphasis`)return eS(this,e,t,n);if(e===`blur`)return nS(this,e,n);if(e===`select`)return tS(this,e,n)}return n}function iS(e){e.stateProxy=rS;var t=e.getTextContent(),n=e.getTextGuideLine();t&&(t.stateProxy=rS),n&&(n.stateProxy=rS)}function aS(e,t){!pS(e,t)&&!e.__highByOuter&&Qx(e,Gx)}function oS(e,t){!pS(e,t)&&!e.__highByOuter&&Qx(e,Kx)}function sS(e,t){e.__highByOuter|=1<<(t||0),Qx(e,Gx)}function cS(e,t){!(e.__highByOuter&=~(1<<(t||0)))&&Qx(e,Kx)}function lS(e){Qx(e,qx)}function uS(e){Qx(e,Jx)}function dS(e){Qx(e,Yx)}function fS(e){Qx(e,Xx)}function pS(e,t){return e.__highDownSilentOnTouch&&t.zrByTouch}function mS(e){var t=e.getModel(),n=[],r=[];t.eachComponent(function(t,i){var a=Fx(i),o=t===`series`,s=o?e.getViewOfSeriesModel(i):e.getViewOfComponentModel(i);!o&&r.push(s),a.isBlured&&(s.group.traverse(function(e){Jx(e)}),o&&n.push(i)),a.isBlured=!1}),q(r,function(e){e&&e.toggleBlurSeries&&e.toggleBlurSeries(n,!1,t)})}function hS(e,t,n,r){var i=r.getModel();n||=`coordinateSystem`;function a(e,t){for(var n=0;n<t.length;n++){var r=e.getItemGraphicEl(t[n]);r&&uS(r)}}if(e!=null&&t&&t!==`none`){var o=i.getSeriesByIndex(e),s=o.coordinateSystem;s&&s.master&&(s=s.master);var c=[];i.eachSeries(function(e){var i=o===e,l=e.coordinateSystem;if(l&&l.master&&(l=l.master),!(n===`series`&&!i||n===`coordinateSystem`&&!(l&&s?l===s:i)||t===`series`&&i)){if(r.getViewOfSeriesModel(e).group.traverse(function(e){e.__highByOuter&&i&&t===`self`||qx(e)}),Qf(t))a(e.getData(),t);else if(X(t))for(var u=np(t),d=0;d<u.length;d++)a(e.getData(u[d]),t[u[d]]);c.push(e),Fx(e).isBlured=!0}}),i.eachComponent(function(e,t){if(e!==`series`){var n=r.getViewOfComponentModel(t);n&&n.toggleBlurSeries&&n.toggleBlurSeries(c,!0,i)}})}}function gS(e,t,n){if(e!=null&&t!=null){var r=n.getModel().getComponent(e,t);if(r){Fx(r).isBlured=!0;var i=n.getViewOfComponentModel(r);i&&i.focusBlurEnabled&&i.group.traverse(function(e){qx(e)})}}}function _S(e,t,n){var r=e.seriesIndex,i=e.getData(t.dataType);if(i){var a=Gv(i,t);a=(J(a)?a[0]:a)||0;var o=i.getItemGraphicEl(a);if(!o)for(var s=i.count(),c=0;!o&&c<s;)o=i.getItemGraphicEl(c++);if(o){var l=Ax(o);hS(r,l.focus,l.blurScope,n)}else{var u=e.get([`emphasis`,`focus`]),d=e.get([`emphasis`,`blurScope`]);u!=null&&hS(r,u,d,n)}}}function vS(e,t,n,r){var i={focusSelf:!1,dispatchers:null};if(e==null||e===`series`||t==null||n==null)return i;var a=r.getModel().getComponent(e,t);if(!a)return i;var o=r.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return i;for(var s=o.findHighDownDispatchers(n),c,l=0;l<s.length;l++)if(Ax(s[l]).focus===`self`){c=!0;break}return{focusSelf:c,dispatchers:s}}function yS(e,t,n){var r=Ax(e),i=vS(r.componentMainType,r.componentIndex,r.componentHighDownName,n),a=i.dispatchers,o=i.focusSelf;a?(o&&gS(r.componentMainType,r.componentIndex,n),q(a,function(e){return aS(e,t)})):(hS(r.seriesIndex,r.focus,r.blurScope,n),r.focus===`self`&&gS(r.componentMainType,r.componentIndex,n),aS(e,t))}function bS(e,t,n){mS(n);var r=Ax(e),i=vS(r.componentMainType,r.componentIndex,r.componentHighDownName,n).dispatchers;i?q(i,function(e){return oS(e,t)}):oS(e,t)}function xS(e,t,n){if(jS(t)){var r=t.dataType,i=Gv(e.getData(r),t);J(i)||(i=[i]),e[t.type===`toggleSelect`?`toggleSelect`:t.type===`select`?`select`:`unselect`](i,r)}}function SS(e){q(e.getAllData(),function(t){var n=t.data,r=t.type;n.eachItemGraphicEl(function(t,n){e.isSelected(n,r)?dS(t):fS(t)})})}function CS(e){var t=[];return e.eachSeries(function(e){q(e.getAllData(),function(n){n.data;var r=n.type,i=e.getSelectedDataIndices();if(i.length>0){var a={dataIndex:i,seriesIndex:e.seriesIndex};r!=null&&(a.dataType=r),t.push(a)}})}),t}function wS(e,t,n){OS(e,!0),Qx(e,iS),DS(e,t,n)}function TS(e){OS(e,!1)}function ES(e,t,n,r){r?TS(e):wS(e,t,n)}function DS(e,t,n){var r=Ax(e);t==null?r.focus&&=null:(r.focus=t,r.blurScope=n)}function OS(e,t){var n=t===!1,r=e;e.highDownSilentOnTouch&&(r.__highDownSilentOnTouch=e.highDownSilentOnTouch),(!n||r.__highDownDispatcher)&&(r.__highByOuter=r.__highByOuter||0,r.__highDownDispatcher=!n)}function kS(e){return!!(e&&e.__highDownDispatcher)}function AS(e){var t=Nx[e];return t==null&&Mx<=32&&(t=Nx[e]=Mx++),t}function jS(e){var t=e.type;return t===`select`||t===`unselect`||t===`toggleSelect`}function MS(e){var t=e.type;return t===`highlight`||t===`downplay`}function NS(e){var t=Px(e);t.normalFill=e.style.fill,t.normalStroke=e.style.stroke;var n=e.states.select||{};t.selectFill=n.style&&n.style.fill||null,t.selectStroke=n.style&&n.style.stroke||null}var PS=Eb.CMD,FS=[[],[],[]],IS=Math.sqrt,LS=Math.atan2;function RS(e,t){if(t){var n=e.data,r=e.len(),i,a,o,s,c,l,u=PS.M,d=PS.C,f=PS.L,p=PS.R,m=PS.A,h=PS.Q;for(o=0,s=0;o<r;){switch(i=n[o++],s=o,a=0,i){case u:a=1;break;case f:a=1;break;case d:a=3;break;case h:a=2;break;case m:var g=t[4],_=t[5],v=IS(t[0]*t[0]+t[1]*t[1]),y=IS(t[2]*t[2]+t[3]*t[3]),b=LS(-t[1]/y,t[0]/v);n[o]*=v,n[o++]+=g,n[o]*=y,n[o++]+=_,n[o++]*=v,n[o++]*=y,n[o++]+=b,n[o++]+=b,o+=2,s=o;break;case p:l[0]=n[o++],l[1]=n[o++],Yp(l,l,t),n[s++]=l[0],n[s++]=l[1],l[0]+=n[o++],l[1]+=n[o++],Yp(l,l,t),n[s++]=l[0],n[s++]=l[1]}for(c=0;c<a;c++){var x=FS[c];x[0]=n[o++],x[1]=n[o++],Yp(x,x,t),n[s++]=x[0],n[s++]=x[1]}}e.increaseVersion()}}var zS=Math.sqrt,BS=Math.sin,VS=Math.cos,HS=Math.PI;function US(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function WS(e,t){return(e[0]*t[0]+e[1]*t[1])/(US(e)*US(t))}function GS(e,t){return(e[0]*t[1]<e[1]*t[0]?-1:1)*Math.acos(WS(e,t))}function KS(e,t,n,r,i,a,o,s,c,l,u){var d=HS/180*c,f=VS(d)*(e-n)/2+BS(d)*(t-r)/2,p=-1*BS(d)*(e-n)/2+VS(d)*(t-r)/2,m=f*f/(o*o)+p*p/(s*s);m>1&&(o*=zS(m),s*=zS(m));var h=(i===a?-1:1)*zS((o*o*(s*s)-o*o*(p*p)-s*s*(f*f))/(o*o*(p*p)+s*s*(f*f)))||0,g=h*o*p/s,_=h*-s*f/o,v=(e+n)/2+VS(d)*g-BS(d)*_,y=(t+r)/2+BS(d)*g+VS(d)*_,b=GS([1,0],[(f-g)/o,(p-_)/s]),x=[(f-g)/o,(p-_)/s],S=[(-1*f-g)/o,(-1*p-_)/s],C=GS(x,S);if(WS(x,S)<=-1&&(C=HS),WS(x,S)>=1&&(C=0),C<0){var w=Math.round(C/HS*1e6)/1e6;C=HS*2+w%2*HS}u.addData(l,v,y,o,s,b,C,d,a)}var qS=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,JS=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function YS(e){var t=new Eb;if(!e)return t;var n=0,r=0,i=n,a=r,o,s=Eb.CMD,c=e.match(qS);if(!c)return t;for(var l=0;l<c.length;l++){for(var u=c[l],d=u.charAt(0),f=void 0,p=u.match(JS)||[],m=p.length,h=0;h<m;h++)p[h]=parseFloat(p[h]);for(var g=0;g<m;){var _=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=n,T=r,E=void 0,D=void 0;switch(d){case`l`:n+=p[g++],r+=p[g++],f=s.L,t.addData(f,n,r);break;case`L`:n=p[g++],r=p[g++],f=s.L,t.addData(f,n,r);break;case`m`:n+=p[g++],r+=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`l`;break;case`M`:n=p[g++],r=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`L`;break;case`h`:n+=p[g++],f=s.L,t.addData(f,n,r);break;case`H`:n=p[g++],f=s.L,t.addData(f,n,r);break;case`v`:r+=p[g++],f=s.L,t.addData(f,n,r);break;case`V`:r=p[g++],f=s.L,t.addData(f,n,r);break;case`C`:f=s.C,t.addData(f,p[g++],p[g++],p[g++],p[g++],p[g++],p[g++]),n=p[g-2],r=p[g-1];break;case`c`:f=s.C,t.addData(f,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r),n+=p[g-2],r+=p[g-1];break;case`S`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=p[g++],T=p[g++],n=p[g++],r=p[g++],t.addData(f,_,v,w,T,n,r);break;case`s`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=n+p[g++],T=r+p[g++],n+=p[g++],r+=p[g++],t.addData(f,_,v,w,T,n,r);break;case`Q`:w=p[g++],T=p[g++],n=p[g++],r=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`q`:w=p[g++]+n,T=p[g++]+r,n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`T`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n=p[g++],r=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`t`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`A`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n=p[g++],r=p[g++],f=s.A,KS(w,T,n,r,S,C,y,b,x,f,t);break;case`a`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n+=p[g++],r+=p[g++],f=s.A,KS(w,T,n,r,S,C,y,b,x,f,t)}}(d===`z`||d===`Z`)&&(f=s.Z,t.addData(f),n=i,r=a),o=f}return t.toStatic(),t}var XS=function(e){U(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.applyTransform=function(e){},t}(Zb);function ZS(e){return e.setData!=null}function QS(e,t){var n=YS(e),r=K({},t);return r.buildPath=function(e){if(ZS(e)){e.setData(n.data);var t=e.getContext();t&&e.rebuildPath(t,1)}else{var t=e;n.rebuildPath(t,1)}},r.applyTransform=function(e){RS(n,e),this.dirtyShape()},r}function $S(e,t){return new XS(QS(e,t))}function eC(e,t){var n=QS(e,t);return function(e){U(t,e);function t(t){var r=e.call(this,t)||this;return r.applyTransform=n.applyTransform,r.buildPath=n.buildPath,r}return t}(XS)}function tC(e,t){for(var n=[],r=e.length,i=0;i<r;i++){var a=e[i];n.push(a.getUpdatedPathProxy(!0))}var o=new Zb(t);return o.createPathProxy(),o.buildPath=function(e){if(ZS(e)){e.appendPath(n);var t=e.getContext();t&&e.rebuildPath(t,1)}},o}var nC=function(){function e(){this.cx=0,this.cy=0,this.r=0}return e}(),rC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new nC},t.prototype.buildPath=function(e,t){e.moveTo(t.cx+t.r,t.cy),e.arc(t.cx,t.cy,t.r,0,Math.PI*2)},t}(Zb);rC.prototype.type=`circle`;var iC=function(){function e(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return e}(),aC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new iC},t.prototype.buildPath=function(e,t){var n=.5522848,r=t.cx,i=t.cy,a=t.rx,o=t.ry,s=a*n,c=o*n;e.moveTo(r-a,i),e.bezierCurveTo(r-a,i-c,r-s,i-o,r,i-o),e.bezierCurveTo(r+s,i-o,r+a,i-c,r+a,i),e.bezierCurveTo(r+a,i+c,r+s,i+o,r,i+o),e.bezierCurveTo(r-s,i+o,r-a,i+c,r-a,i),e.closePath()},t}(Zb);aC.prototype.type=`ellipse`;var oC=Math.PI,sC=oC*2,cC=Math.sin,lC=Math.cos,uC=Math.acos,dC=Math.atan2,fC=Math.abs,pC=Math.sqrt,mC=Math.max,hC=Math.min,gC=1e-4;function _C(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<gC))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function vC(e,t,n,r,i,a,o){var s=e-n,c=t-r,l=(o?a:-a)/pC(s*s+c*c),u=l*c,d=-l*s,f=e+u,p=t+d,m=n+u,h=r+d,g=(f+m)/2,_=(p+h)/2,v=m-f,y=h-p,b=v*v+y*y,x=i-a,S=f*h-m*p,C=(y<0?-1:1)*pC(mC(0,x*x*b-S*S)),w=(S*y-v*C)/b,T=(-S*v-y*C)/b,E=(S*y+v*C)/b,D=(-S*v+y*C)/b,O=w-g,k=T-_,A=E-g,ee=D-_;return O*O+k*k>A*A+ee*ee&&(w=E,T=D),{cx:w,cy:T,x0:-u,y0:-d,x1:w*(i/x-1),y1:T*(i/x-1)}}function yC(e){var t;if(J(e)){var n=e.length;if(!n)return e;t=n===1?[e[0],e[0],0,0]:n===2?[e[0],e[0],e[1],e[1]]:n===3?e.concat(e[2]):e}else t=[e,e,e,e];return t}function bC(e,t){var n,r=mC(t.r,0),i=mC(t.r0||0,0),a=r>0;if(a||i>0){if(a||(r=i,i=0),i>r){var o=r;r=i,i=o}var s=t.startAngle,c=t.endAngle;if(!(isNaN(s)||isNaN(c))){var l=t.cx,u=t.cy,d=!!t.clockwise,f=fC(c-s),p=f>sC&&f%sC;if(p>gC&&(f=p),!(r>gC))e.moveTo(l,u);else if(f>sC-gC)e.moveTo(l+r*lC(s),u+r*cC(s)),e.arc(l,u,r,s,c,!d),i>gC&&(e.moveTo(l+i*lC(c),u+i*cC(c)),e.arc(l,u,i,c,s,d));else{var m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=void 0,T=void 0,E=void 0,D=void 0,O=void 0,k=void 0,A=r*lC(s),ee=r*cC(s),te=i*lC(c),ne=i*cC(c),re=f>gC;if(re){var j=t.cornerRadius;j&&(n=yC(j),m=n[0],h=n[1],g=n[2],_=n[3]);var ie=fC(r-i)/2;if(v=hC(ie,g),y=hC(ie,_),b=hC(ie,m),x=hC(ie,h),w=S=mC(v,y),T=C=mC(b,x),(S>gC||C>gC)&&(E=r*lC(c),D=r*cC(c),O=i*lC(s),k=i*cC(s),f<oC)){var ae=_C(A,ee,O,k,E,D,te,ne);if(ae){var oe=A-ae[0],se=ee-ae[1],ce=E-ae[0],le=D-ae[1],ue=1/cC(uC((oe*ce+se*le)/(pC(oe*oe+se*se)*pC(ce*ce+le*le)))/2),de=pC(ae[0]*ae[0]+ae[1]*ae[1]);w=hC(S,(r-de)/(ue+1)),T=hC(C,(i-de)/(ue-1))}}}if(!re)e.moveTo(l+A,u+ee);else if(w>gC){var fe=hC(g,w),pe=hC(_,w),M=vC(O,k,A,ee,r,fe,d),me=vC(E,D,te,ne,r,pe,d);e.moveTo(l+M.cx+M.x0,u+M.cy+M.y0),w<S&&fe===pe?e.arc(l+M.cx,u+M.cy,w,dC(M.y0,M.x0),dC(me.y0,me.x0),!d):(fe>0&&e.arc(l+M.cx,u+M.cy,fe,dC(M.y0,M.x0),dC(M.y1,M.x1),!d),e.arc(l,u,r,dC(M.cy+M.y1,M.cx+M.x1),dC(me.cy+me.y1,me.cx+me.x1),!d),pe>0&&e.arc(l+me.cx,u+me.cy,pe,dC(me.y1,me.x1),dC(me.y0,me.x0),!d))}else e.moveTo(l+A,u+ee),e.arc(l,u,r,s,c,!d);if(!(i>gC)||!re)e.lineTo(l+te,u+ne);else if(T>gC){var fe=hC(m,T),pe=hC(h,T),M=vC(te,ne,E,D,i,-pe,d),me=vC(A,ee,O,k,i,-fe,d);e.lineTo(l+M.cx+M.x0,u+M.cy+M.y0),T<C&&fe===pe?e.arc(l+M.cx,u+M.cy,T,dC(M.y0,M.x0),dC(me.y0,me.x0),!d):(pe>0&&e.arc(l+M.cx,u+M.cy,pe,dC(M.y0,M.x0),dC(M.y1,M.x1),!d),e.arc(l,u,i,dC(M.cy+M.y1,M.cx+M.x1),dC(me.cy+me.y1,me.cx+me.x1),d),fe>0&&e.arc(l+me.cx,u+me.cy,fe,dC(me.y1,me.x1),dC(me.y0,me.x0),!d))}else e.lineTo(l+te,u+ne),e.arc(l,u,i,c,s,d)}e.closePath()}}}var xC=function(){function e(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return e}(),SC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new xC},t.prototype.buildPath=function(e,t){bC(e,t)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t}(Zb);SC.prototype.type=`sector`;var CC=function(){function e(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return e}(),wC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new CC},t.prototype.buildPath=function(e,t){var n=t.cx,r=t.cy,i=Math.PI*2;e.moveTo(n+t.r,r),e.arc(n,r,t.r,0,i,!1),e.moveTo(n+t.r0,r),e.arc(n,r,t.r0,0,i,!0)},t}(Zb);wC.prototype.type=`ring`;function TC(e,t,n,r){var i=[],a=[],o=[],s=[],c,l,u,d;if(r){u=[1/0,1/0],d=[-1/0,-1/0];for(var f=0,p=e.length;f<p;f++)Xp(u,u,e[f]),Zp(d,d,e[f]);Xp(u,u,r[0]),Zp(d,d,r[1])}for(var f=0,p=e.length;f<p;f++){var m=e[f];if(n)c=e[f?f-1:p-1],l=e[(f+1)%p];else if(f===0||f===p-1){i.push(Ip(e[f]));continue}else c=e[f-1],l=e[f+1];Bp(a,l,c),Up(a,a,t);var h=Gp(m,c),g=Gp(m,l),_=h+g;_!==0&&(h/=_,g/=_),Up(o,a,-h),Up(s,a,g);var v=Rp([],m,o),y=Rp([],m,s);r&&(Zp(v,v,u),Xp(v,v,d),Zp(y,y,u),Xp(y,y,d)),i.push(v),i.push(y)}return n&&i.push(i.shift()),i}function EC(e,t,n){var r=t.smooth,i=t.points;if(i&&i.length>=2){if(r){var a=TC(i,r,n,t.smoothConstraint);e.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;s<(n?o:o-1);s++){var c=a[s*2],l=a[s*2+1],u=i[(s+1)%o];e.bezierCurveTo(c[0],c[1],l[0],l[1],u[0],u[1])}}else{e.moveTo(i[0][0],i[0][1]);for(var s=1,d=i.length;s<d;s++)e.lineTo(i[s][0],i[s][1])}n&&e.closePath()}}var DC=function(){function e(){this.points=null,this.smooth=0,this.smoothConstraint=null}return e}(),OC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new DC},t.prototype.buildPath=function(e,t){EC(e,t,!0)},t}(Zb);OC.prototype.type=`polygon`;var kC=function(){function e(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return e}(),AC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new kC},t.prototype.buildPath=function(e,t){EC(e,t,!1)},t}(Zb);AC.prototype.type=`polyline`;var jC={},MC=function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return e}(),NC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new MC},t.prototype.buildPath=function(e,t){var n,r,i,a;if(this.subPixelOptimize){var o=ox(jC,t,this.style);n=o.x1,r=o.y1,i=o.x2,a=o.y2}else n=t.x1,r=t.y1,i=t.x2,a=t.y2;var s=t.percent;s!==0&&(e.moveTo(n,r),s<1&&(i=n*(1-s)+i*s,a=r*(1-s)+a*s),e.lineTo(i,a))},t.prototype.pointAt=function(e){var t=this.shape;return[t.x1*(1-e)+t.x2*e,t.y1*(1-e)+t.y2*e]},t}(Zb);NC.prototype.type=`line`;var PC=[],FC=function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return e}();function IC(e,t,n){var r=e.cpx2,i=e.cpy2;return r!=null||i!=null?[(n?Mh:jh)(e.x1,e.cpx1,e.cpx2,e.x2,t),(n?Mh:jh)(e.y1,e.cpy1,e.cpy2,e.y2,t)]:[(n?zh:Rh)(e.x1,e.cpx1,e.x2,t),(n?zh:Rh)(e.y1,e.cpy1,e.y2,t)]}var LC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new FC},t.prototype.buildPath=function(e,t){var n=t.x1,r=t.y1,i=t.x2,a=t.y2,o=t.cpx1,s=t.cpy1,c=t.cpx2,l=t.cpy2,u=t.percent;u!==0&&(e.moveTo(n,r),c==null||l==null?(u<1&&(Hh(n,o,i,u,PC),o=PC[1],i=PC[2],Hh(r,s,a,u,PC),s=PC[1],a=PC[2]),e.quadraticCurveTo(o,s,i,a)):(u<1&&(Fh(n,o,c,i,u,PC),o=PC[1],c=PC[2],i=PC[3],Fh(r,s,l,a,u,PC),s=PC[1],l=PC[2],a=PC[3]),e.bezierCurveTo(o,s,c,l,i,a)))},t.prototype.pointAt=function(e){return IC(this.shape,e,!1)},t.prototype.tangentAt=function(e){var t=IC(this.shape,e,!0);return Wp(t,t)},t}(Zb);LC.prototype.type=`bezier-curve`;var RC=function(){function e(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return e}(),zC=function(e){U(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new RC},t.prototype.buildPath=function(e,t){var n=t.cx,r=t.cy,i=Math.max(t.r,0),a=t.startAngle,o=t.endAngle,s=t.clockwise,c=Math.cos(a),l=Math.sin(a);e.moveTo(c*i+n,l*i+r),e.arc(n,r,i,a,o,!s)},t}(Zb);zC.prototype.type=`arc`;var BC=function(e){U(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.type=`compound`,t}return t.prototype._updatePathDirty=function(){for(var e=this.shape.paths,t=this.shapeChanged(),n=0;n<e.length;n++)t||=e[n].shapeChanged();t&&this.dirtyShape()},t.prototype.beforeBrush=function(){this._updatePathDirty();for(var e=this.shape.paths||[],t=this.getGlobalScale(),n=0;n<e.length;n++)e[n].path||e[n].createPathProxy(),e[n].path.setScale(t[0],t[1],e[n].segmentIgnoreThreshold)},t.prototype.buildPath=function(e,t){for(var n=t.paths||[],r=0;r<n.length;r++)n[r].buildPath(e,n[r].shape,!0)},t.prototype.afterBrush=function(){for(var e=this.shape.paths||[],t=0;t<e.length;t++)e[t].pathUpdated()},t.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),Zb.prototype.getBoundingRect.call(this)},t}(Zb),VC=function(){function e(e){this.colorStops=e||[]}return e.prototype.addColorStop=function(e,t){this.colorStops.push({offset:e,color:t})},e}(),HC=function(e){U(t,e);function t(t,n,r,i,a,o){var s=e.call(this,a)||this;return s.x=t??0,s.y=n??0,s.x2=r??1,s.y2=i??0,s.type=`linear`,s.global=o||!1,s}return t}(VC),UC=function(e){U(t,e);function t(t,n,r,i,a){var o=e.call(this,i)||this;return o.x=t??.5,o.y=n??.5,o.r=r??.5,o.type=`radial`,o.global=a||!1,o}return t}(VC),WC=[0,0],GC=[0,0],KC=new Rm,qC=new Rm,JC=function(){function e(e,t){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new Rm;for(var n=0;n<2;n++)this._axes[n]=new Rm;e&&this.fromBoundingRect(e,t)}return e.prototype.fromBoundingRect=function(e,t){var n=this._corners,r=this._axes,i=e.x,a=e.y,o=i+e.width,s=a+e.height;if(n[0].set(i,a),n[1].set(o,a),n[2].set(o,s),n[3].set(i,s),t)for(var c=0;c<4;c++)n[c].transform(t);Rm.sub(r[0],n[1],n[0]),Rm.sub(r[1],n[3],n[0]),r[0].normalize(),r[1].normalize();for(var c=0;c<2;c++)this._origin[c]=r[c].dot(n[0])},e.prototype.intersect=function(e,t){var n=!0,r=!t;return KC.set(1/0,1/0),qC.set(0,0),!this._intersectCheckOneSide(this,e,KC,qC,r,1)&&(n=!1,r)||!this._intersectCheckOneSide(e,this,KC,qC,r,-1)&&(n=!1,r)||r||Rm.copy(t,n?KC:qC),n},e.prototype._intersectCheckOneSide=function(e,t,n,r,i,a){for(var o=!0,s=0;s<2;s++){var c=this._axes[s];if(this._getProjMinMaxOnAxis(s,e._corners,WC),this._getProjMinMaxOnAxis(s,t._corners,GC),WC[1]<GC[0]||WC[0]>GC[1]){if(o=!1,i)return o;var l=Math.abs(GC[0]-WC[1]),u=Math.abs(WC[0]-GC[1]);Math.min(l,u)>r.len()&&(l<u?Rm.scale(r,c,-l*a):Rm.scale(r,c,u*a))}else if(n){var l=Math.abs(GC[0]-WC[1]),u=Math.abs(WC[0]-GC[1]);Math.min(l,u)<n.len()&&(l<u?Rm.scale(n,c,l*a):Rm.scale(n,c,-u*a))}}return o},e.prototype._getProjMinMaxOnAxis=function(e,t,n){for(var r=this._axes[e],i=this._origin,a=t[0].dot(r)+i[e],o=a,s=a,c=1;c<t.length;c++){var l=t[c].dot(r)+i[e];o=Math.min(l,o),s=Math.max(l,s)}n[0]=o,n[1]=s},e}(),YC=[],XC=function(e){U(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.notClear=!0,t.incremental=!0,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}return t.prototype.traverse=function(e,t){e.call(t,this)},t.prototype.useStyle=function(){this.style={}},t.prototype.getCursor=function(){return this._cursor},t.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},t.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},t.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},t.prototype.addDisplayable=function(e,t){t?this._temporaryDisplayables.push(e):this._displayables.push(e),this.markRedraw()},t.prototype.addDisplayables=function(e,t){t||=!1;for(var n=0;n<e.length;n++)this.addDisplayable(e[n],t)},t.prototype.getDisplayables=function(){return this._displayables},t.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},t.prototype.eachPendingDisplayable=function(e){for(var t=this._cursor;t<this._displayables.length;t++)e&&e(this._displayables[t]);for(var t=0;t<this._temporaryDisplayables.length;t++)e&&e(this._temporaryDisplayables[t])},t.prototype.update=function(){this.updateTransform();for(var e=this._cursor;e<this._displayables.length;e++){var t=this._displayables[e];t.parent=this,t.update(),t.parent=null}for(var e=0;e<this._temporaryDisplayables.length;e++){var t=this._temporaryDisplayables[e];t.parent=this,t.update(),t.parent=null}},t.prototype.getBoundingRect=function(){if(!this._rect){for(var e=new $(1/0,1/0,-1/0,-1/0),t=0;t<this._displayables.length;t++){var n=this._displayables[t],r=n.getBoundingRect().clone();n.needLocalTransform()&&r.applyTransform(n.getLocalTransform(YC)),e.union(r)}this._rect=e}return this._rect},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t);if(this.getBoundingRect().contain(n[0],n[1])){for(var r=0;r<this._displayables.length;r++)if(this._displayables[r].contain(e,t))return!0}return!1},t}(Uy),ZC=Kv();function QC(e,t,n,r,i){var a;if(t&&t.ecModel){var o=t.ecModel.getUpdatePayload();a=o&&o.animation}var s=t&&t.isAnimationEnabled(),c=e===`update`;if(s){var l=void 0,u=void 0,d=void 0;return r?(l=Z(r.duration,200),u=Z(r.easing,`cubicOut`),d=0):(l=t.getShallow(c?`animationDurationUpdate`:`animationDuration`),u=t.getShallow(c?`animationEasingUpdate`:`animationEasing`),d=t.getShallow(c?`animationDelayUpdate`:`animationDelay`)),a&&(a.duration!=null&&(l=a.duration),a.easing!=null&&(u=a.easing),a.delay!=null&&(d=a.delay)),op(d)&&(d=d(n,i)),op(l)&&(l=l(n)),{duration:l||0,delay:d,easing:u}}return null}function $C(e,t,n,r,i,a,o){var s=!1,c;op(i)?(o=a,a=i,i=null):X(i)&&(a=i.cb,o=i.during,s=i.isFrom,c=i.removeOpt,i=i.dataIndex);var l=e===`leave`;l||t.stopAnimation(`leave`);var u=QC(e,r,i,l?c||{}:null,r&&r.getAnimationDelayParams?r.getAnimationDelayParams(t,i):null);if(u&&u.duration>0){var d=u.duration,f=u.delay,p=u.easing,m={duration:d,delay:f||0,easing:p,done:a,force:!!a||!!o,setToFinal:!l,scope:e,during:o};s?t.animateFrom(n,m):t.animateTo(n,m)}else t.stopAnimation(),!s&&t.attr(n),o&&o(1),a&&a()}function ew(e,t,n,r,i,a){$C(`update`,e,t,n,r,i,a)}function tw(e,t,n,r,i,a){$C(`enter`,e,t,n,r,i,a)}function nw(e){if(!e.__zr)return!0;for(var t=0;t<e.animators.length;t++)if(e.animators[t].scope===`leave`)return!0;return!1}function rw(e,t,n,r,i,a){nw(e)||$C(`leave`,e,t,n,r,i,a)}function iw(e,t,n,r){e.removeTextContent(),e.removeTextGuideLine(),rw(e,{style:{opacity:0}},t,n,r)}function aw(e,t,n){function r(){e.parent&&e.parent.remove(e)}e.isGroup?e.traverse(function(e){e.isGroup||iw(e,t,n,r)}):iw(e,t,n,r)}function ow(e){ZC(e).oldStyle=e.style}var sw=t({Arc:()=>zC,BezierCurve:()=>LC,BoundingRect:()=>$,Circle:()=>rC,CompoundPath:()=>BC,Ellipse:()=>aC,Group:()=>Z_,Image:()=>rx,IncrementalDisplayable:()=>XC,Line:()=>NC,LinearGradient:()=>HC,OrientedBoundingRect:()=>JC,Path:()=>Zb,Point:()=>Rm,Polygon:()=>OC,Polyline:()=>AC,RadialGradient:()=>UC,Rect:()=>dx,Ring:()=>wC,Sector:()=>SC,Text:()=>hx,applyTransform:()=>Tw,clipPointsByRect:()=>Aw,clipRectByRect:()=>jw,createIcon:()=>Mw,extendPath:()=>pw,extendShape:()=>dw,getShapeClass:()=>hw,getTransform:()=>ww,groupTransition:()=>kw,initProps:()=>tw,isElementRemoved:()=>nw,lineLineIntersect:()=>Pw,linePolygonIntersect:()=>Nw,makeImage:()=>_w,makePath:()=>gw,mergePath:()=>yw,registerShape:()=>mw,removeElement:()=>rw,removeElementWithFadeOut:()=>aw,resizePath:()=>bw,setTooltipConfig:()=>Lw,subPixelOptimize:()=>Cw,subPixelOptimizeLine:()=>xw,subPixelOptimizeRect:()=>Sw,transformDirection:()=>Ew,traverseElements:()=>zw,updateProps:()=>ew}),cw=Math.max,lw=Math.min,uw={};function dw(e){return Zb.extend(e)}var fw=eC;function pw(e,t){return fw(e,t)}function mw(e,t){uw[e]=t}function hw(e){if(uw.hasOwnProperty(e))return uw[e]}function gw(e,t,n,r){var i=$S(e,t);return n&&(r===`center`&&(n=vw(n,i.getBoundingRect())),bw(i,n)),i}function _w(e,t,n){var r=new rx({style:{image:e,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(e){if(n===`center`){var i={width:e.width,height:e.height};r.setStyle(vw(t,i))}}});return r}function vw(e,t){var n=t.width/t.height,r=e.height*n,i;r<=e.width?i=e.height:(r=e.width,i=r/n);var a=e.x+e.width/2,o=e.y+e.height/2;return{x:a-r/2,y:o-i/2,width:r,height:i}}var yw=tC;function bw(e,t){if(e.applyTransform){var n=e.getBoundingRect().calculateTransform(t);e.applyTransform(n)}}function xw(e,t){return ox(e,e,{lineWidth:t}),e}function Sw(e){return sx(e.shape,e.shape,e.style),e}var Cw=cx;function ww(e,t){for(var n=jm([]);e&&e!==t;)Nm(n,e.getLocalTransform(),n),e=e.parent;return n}function Tw(e,t,n){return t&&!Qf(t)&&(t=E_.getLocalTransform(t)),n&&(t=Lm([],t)),Yp([],e,t)}function Ew(e,t,n){var r=t[4]===0||t[5]===0||t[0]===0?1:Math.abs(2*t[4]/t[0]),i=t[4]===0||t[5]===0||t[2]===0?1:Math.abs(2*t[4]/t[2]),a=[e===`left`?-r:e===`right`?r:0,e===`top`?-i:e===`bottom`?i:0];return a=Tw(a,t,n),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?`right`:`left`:a[1]>0?`bottom`:`top`}function Dw(e){return!e.isGroup}function Ow(e){return e.shape!=null}function kw(e,t,n){if(!e||!t)return;function r(e){var t={};return e.traverse(function(e){Dw(e)&&e.anid&&(t[e.anid]=e)}),t}function i(e){var t={x:e.x,y:e.y,rotation:e.rotation};return Ow(e)&&(t.shape=K({},e.shape)),t}var a=r(e);t.traverse(function(e){if(Dw(e)&&e.anid){var t=a[e.anid];if(t){var r=i(e);e.attr(i(t)),ew(e,r,n,Ax(e).dataIndex)}}})}function Aw(e,t){return $f(e,function(e){var n=e[0];n=cw(n,t.x),n=lw(n,t.x+t.width);var r=e[1];return r=cw(r,t.y),r=lw(r,t.y+t.height),[n,r]})}function jw(e,t){var n=cw(e.x,t.x),r=lw(e.x+e.width,t.x+t.width),i=cw(e.y,t.y),a=lw(e.y+e.height,t.y+t.height);if(r>=n&&a>=i)return{x:n,y:i,width:r-n,height:a-i}}function Mw(e,t,n){var r=K({rectHover:!0},t),i=r.style={strokeNoScale:!0};if(n||={x:-1,y:-1,width:2,height:2},e)return e.indexOf(`image://`)===0?(i.image=e.slice(8),Jf(i,n),new rx(r)):gw(e.replace(`path://`,``),r,n,`center`)}function Nw(e,t,n,r,i){for(var a=0,o=i[i.length-1];a<i.length;a++){var s=i[a];if(Pw(e,t,n,r,s[0],s[1],o[0],o[1]))return!0;o=s}}function Pw(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=Fw(u,d,c,l);if(Iw(f))return!1;var p=e-i,m=t-a,h=Fw(p,m,c,l)/f;if(h<0||h>1)return!1;var g=Fw(p,m,u,d)/f;return!(g<0||g>1)}function Fw(e,t,n,r){return e*r-n*t}function Iw(e){return e<=1e-6&&e>=-1e-6}function Lw(e){var t=e.itemTooltipOption,n=e.componentModel,r=e.itemName,i=Y(t)?{formatter:t}:t,a=n.mainType,o=n.componentIndex,s={componentType:a,name:r,$vars:[`name`]};s[a+`Index`]=o;var c=e.formatterParamsExtra;c&&q(np(c),function(e){jp(s,e)||(s[e]=c[e],s.$vars.push(e))});var l=Ax(e.el);l.componentMainType=a,l.componentIndex=o,l.tooltipConfig={name:r,option:Jf({content:r,encodeHTMLContent:!0,formatterParams:s},i)}}function Rw(e,t){var n;e.isGroup&&(n=t(e)),n||e.traverse(t)}function zw(e,t){if(e){if(J(e))for(var n=0;n<e.length;n++)Rw(e[n],t);else Rw(e,t)}}mw(`circle`,rC),mw(`ellipse`,aC),mw(`sector`,SC),mw(`ring`,wC),mw(`polygon`,OC),mw(`polyline`,AC),mw(`rect`,dx),mw(`line`,NC),mw(`bezierCurve`,LC),mw(`arc`,zC);var Bw={};function Vw(e,t){for(var n=0;n<Ix.length;n++){var r=Ix[n],i=t[r],a=e.ensureState(r);a.style=a.style||{},a.style.text=i}var o=e.currentStates.slice();e.clearStates(!0),e.setStyle({text:t.normal}),e.useStates(o,!0)}function Hw(e,t,n){var r=e.labelFetcher,i=e.labelDataIndex,a=e.labelDimIndex,o=t.normal,s;r&&(s=r.getFormattedLabel(i,`normal`,null,a,o&&o.get(`formatter`),n==null?null:{interpolatedValue:n})),s??=op(e.defaultText)?e.defaultText(i,e,n):e.defaultText;for(var c={normal:s},l=0;l<Ix.length;l++){var u=Ix[l],d=t[u];c[u]=Z(r?r.getFormattedLabel(i,u,null,a,d&&d.get(`formatter`)):null,s)}return c}function Uw(e,t,n,r){n||=Bw;for(var i=e instanceof hx,a=!1,o=0;o<Lx.length;o++){var s=t[Lx[o]];if(s&&s.getShallow(`show`)){a=!0;break}}var c=i?e:e.getTextContent();if(a){i||(c||(c=new hx,e.setTextContent(c)),e.stateProxy&&(c.stateProxy=e.stateProxy));var l=Hw(n,t),u=t.normal,d=!!u.getShallow(`show`),f=Gw(u,r&&r.normal,n,!1,!i);f.text=l.normal,i||e.setTextConfig(Kw(u,n,!1));for(var o=0;o<Ix.length;o++){var p=Ix[o],s=t[p];if(s){var m=c.ensureState(p),h=!!Z(s.getShallow(`show`),d);if(h!==d&&(m.ignore=!h),m.style=Gw(s,r&&r[p],n,!0,!i),m.style.text=l[p],!i){var g=e.ensureState(p);g.textConfig=Kw(s,n,!0)}}}c.silent=!!u.getShallow(`silent`),c.style.x!=null&&(f.x=c.style.x),c.style.y!=null&&(f.y=c.style.y),c.ignore=!d,c.useStyle(f),c.dirty(),n.enableTextSetter&&(eT(c).setLabelText=function(e){var r=Hw(n,t,e);Vw(c,r)})}else c&&(c.ignore=!0);e.dirty()}function Ww(e,t){t||=`label`;for(var n={normal:e.getModel(t)},r=0;r<Ix.length;r++){var i=Ix[r];n[i]=e.getModel([i,t])}return n}function Gw(e,t,n,r,i){var a={};return qw(a,e,n,r,i),t&&K(a,t),a}function Kw(e,t,n){t||={};var r={},i,a=e.getShallow(`rotate`),o=Z(e.getShallow(`distance`),n?null:5),s=e.getShallow(`offset`);return i=e.getShallow(`position`)||(n?null:`inside`),i===`outside`&&(i=t.defaultOutsidePosition||`top`),i!=null&&(r.position=i),s!=null&&(r.offset=s),a!=null&&(a*=Math.PI/180,r.rotation=a),o!=null&&(r.distance=o),r.outsideFill=e.get(`color`)===`inherit`?t.inheritColor||null:`auto`,r}function qw(e,t,n,r,i){n||=Bw;var a=t.ecModel,o=a&&a.option.textStyle,s=Jw(t),c;if(s){for(var l in c={},s)if(s.hasOwnProperty(l)){var u=t.getModel([`rich`,l]);Qw(c[l]={},u,o,n,r,i,!1,!0)}}c&&(e.rich=c);var d=t.get(`overflow`);d&&(e.overflow=d);var f=t.get(`minMargin`);f!=null&&(e.margin=f),Qw(e,t,o,n,r,i,!0,!1)}function Jw(e){for(var t;e&&e!==e.ecModel;){var n=(e.option||Bw).rich;if(n){t||={};for(var r=np(n),i=0;i<r.length;i++){var a=r[i];t[a]=1}}e=e.parentModel}return t}var Yw=[`fontStyle`,`fontWeight`,`fontSize`,`fontFamily`,`textShadowColor`,`textShadowBlur`,`textShadowOffsetX`,`textShadowOffsetY`],Xw=[`align`,`lineHeight`,`width`,`height`,`tag`,`verticalAlign`,`ellipsis`],Zw=[`padding`,`borderWidth`,`borderRadius`,`borderDashOffset`,`backgroundColor`,`borderColor`,`shadowColor`,`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`];function Qw(e,t,n,r,i,a,o,s){n=!i&&n||Bw;var c=r&&r.inheritColor,l=t.getShallow(`color`),u=t.getShallow(`textBorderColor`),d=Z(t.getShallow(`opacity`),n.opacity);(l===`inherit`||l===`auto`)&&(l=c||null),(u===`inherit`||u===`auto`)&&(u=c||null),a||(l||=n.color,u||=n.textBorderColor),l!=null&&(e.fill=l),u!=null&&(e.stroke=u);var f=Z(t.getShallow(`textBorderWidth`),n.textBorderWidth);f!=null&&(e.lineWidth=f);var p=Z(t.getShallow(`textBorderType`),n.textBorderType);p!=null&&(e.lineDash=p);var m=Z(t.getShallow(`textBorderDashOffset`),n.textBorderDashOffset);m!=null&&(e.lineDashOffset=m),!i&&d==null&&!s&&(d=r&&r.defaultOpacity),d!=null&&(e.opacity=d),!i&&!a&&e.fill==null&&r.inheritColor&&(e.fill=r.inheritColor);for(var h=0;h<Yw.length;h++){var g=Yw[h],_=Z(t.getShallow(g),n[g]);_!=null&&(e[g]=_)}for(var h=0;h<Xw.length;h++){var g=Xw[h],_=t.getShallow(g);_!=null&&(e[g]=_)}if(e.verticalAlign==null){var v=t.getShallow(`baseline`);v!=null&&(e.verticalAlign=v)}if(!o||!r.disableBox){for(var h=0;h<Zw.length;h++){var g=Zw[h],_=t.getShallow(g);_!=null&&(e[g]=_)}var y=t.getShallow(`borderType`);y!=null&&(e.borderDash=y),(e.backgroundColor===`auto`||e.backgroundColor===`inherit`)&&c&&(e.backgroundColor=c),(e.borderColor===`auto`||e.borderColor===`inherit`)&&c&&(e.borderColor=c)}}function $w(e,t){var n=t&&t.getModel(`textStyle`);return bp([e.fontStyle||n&&n.getShallow(`fontStyle`)||``,e.fontWeight||n&&n.getShallow(`fontWeight`)||``,(e.fontSize||n&&n.getShallow(`fontSize`)||12)+`px`,e.fontFamily||n&&n.getShallow(`fontFamily`)||`sans-serif`].join(` `))}var eT=Kv(),tT=[`textStyle`,`color`],nT=[`fontStyle`,`fontWeight`,`fontSize`,`fontFamily`,`padding`,`lineHeight`,`rich`,`width`,`height`,`overflow`],rT=new hx,iT=function(){function e(){}return e.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow(`color`)||(!e&&t?t.get(tT):null)},e.prototype.getFont=function(){return $w({fontStyle:this.getShallow(`fontStyle`),fontWeight:this.getShallow(`fontWeight`),fontSize:this.getShallow(`fontSize`),fontFamily:this.getShallow(`fontFamily`)},this.ecModel)},e.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow(`verticalAlign`)||this.getShallow(`baseline`)},n=0;n<nT.length;n++)t[nT[n]]=this.getShallow(nT[n]);return rT.useStyle(t),rT.update(),rT.getBoundingRect()},e}(),aT=[[`lineWidth`,`width`],[`stroke`,`color`],[`opacity`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`shadowColor`],[`lineDash`,`type`],[`lineDashOffset`,`dashOffset`],[`lineCap`,`cap`],[`lineJoin`,`join`],[`miterLimit`]],oT=hy(aT),sT=function(){function e(){}return e.prototype.getLineStyle=function(e){return oT(this,e)},e}(),cT=[[`fill`,`color`],[`stroke`,`borderColor`],[`lineWidth`,`borderWidth`],[`opacity`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`shadowColor`],[`lineDash`,`borderType`],[`lineDashOffset`,`borderDashOffset`],[`lineCap`,`borderCap`],[`lineJoin`,`borderJoin`],[`miterLimit`,`borderMiterLimit`]],lT=hy(cT),uT=function(){function e(){}return e.prototype.getItemStyle=function(e,t){return lT(this,e,t)},e}(),dT=function(){function e(e,t,n){this.parentModel=t,this.ecModel=n,this.option=e}return e.prototype.init=function(e,t,n){},e.prototype.mergeOption=function(e,t){qf(this.option,e,!0)},e.prototype.get=function(e,t){return e==null?this.option:this._doGet(this.parsePath(e),!t&&this.parentModel)},e.prototype.getShallow=function(e,t){var n=this.option,r=n==null?n:n[e];if(r==null&&!t){var i=this.parentModel;i&&(r=i.getShallow(e))}return r},e.prototype.getModel=function(t,n){var r=t!=null,i=r?this.parsePath(t):null,a=r?this._doGet(i):this.option;return n||=this.parentModel&&this.parentModel.getModel(this.resolveParentPath(i)),new e(a,n,this.ecModel)},e.prototype.isEmpty=function(){return this.option==null},e.prototype.restoreData=function(){},e.prototype.clone=function(){var e=this.constructor;return new e(G(this.option))},e.prototype.parsePath=function(e){return typeof e==`string`?e.split(`.`):e},e.prototype.resolveParentPath=function(e){return e},e.prototype.isAnimationEnabled=function(){if(!W.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},e.prototype._doGet=function(e,t){var n=this.option;if(!e)return n;for(var r=0;r<e.length&&!(e[r]&&(n=n&&typeof n==`object`?n[e[r]]:null,n==null));r++);return n==null&&t&&(n=t._doGet(this.resolveParentPath(e),t.parentModel)),n},e}();sy(dT),dy(dT),Zf(dT,sT),Zf(dT,uT),Zf(dT,_y),Zf(dT,iT);var fT=Math.round(Math.random()*10);function pT(e){return[e||``,fT++].join(`_`)}function mT(e){var t={};e.registerSubTypeDefaulter=function(e,n){var r=iy(e);t[r.main]=n},e.determineSubType=function(n,r){var i=r.type;if(!i){var a=iy(n).main;e.hasSubTypes(n)&&t[a]&&(i=t[a](r))}return i}}function hT(e,t){e.topologicalTravel=function(e,t,r,i){if(!e.length)return;var a=n(t),o=a.graph,s=a.noEntryList,c={};for(q(e,function(e){c[e]=!0});s.length;){var l=s.pop(),u=o[l],d=!!c[l];d&&(r.call(i,l,u.originalDeps.slice()),delete c[l]),q(u.successor,d?p:f)}q(c,function(){throw Error(``)});function f(e){o[e].entryCount--,o[e].entryCount===0&&s.push(e)}function p(e){c[e]=!0,f(e)}};function n(e){var n={},a=[];return q(e,function(o){var s=r(n,o),c=i(s.originalDeps=t(o),e);s.entryCount=c.length,s.entryCount===0&&a.push(o),q(c,function(e){Yf(s.predecessor,e)<0&&s.predecessor.push(e);var t=r(n,e);Yf(t.successor,e)<0&&t.successor.push(o)})}),{graph:n,noEntryList:a}}function r(e,t){return e[t]||(e[t]={predecessor:[],successor:[]}),e[t]}function i(e,t){var n=[];return q(e,function(e){Yf(t,e)>=0&&n.push(e)}),n}}function gT(e,t){return qf(qf({},e,!0),t,!0)}var _T={time:{month:[`January`,`February`,`March`,`April`,`May`,`June`,`July`,`August`,`September`,`October`,`November`,`December`],monthAbbr:[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`],dayOfWeek:[`Sunday`,`Monday`,`Tuesday`,`Wednesday`,`Thursday`,`Friday`,`Saturday`],dayOfWeekAbbr:[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`]},legend:{selector:{all:`All`,inverse:`Inv`}},toolbox:{brush:{title:{rect:`Box Select`,polygon:`Lasso Select`,lineX:`Horizontally Select`,lineY:`Vertically Select`,keep:`Keep Selections`,clear:`Clear Selections`}},dataView:{title:`Data View`,lang:[`Data View`,`Close`,`Refresh`]},dataZoom:{title:{zoom:`Zoom`,back:`Zoom Reset`}},magicType:{title:{line:`Switch to Line Chart`,bar:`Switch to Bar Chart`,stack:`Stack`,tiled:`Tile`}},restore:{title:`Restore`},saveAsImage:{title:`Save as Image`,lang:[`Right Click to Save Image`]}},series:{typeNames:{pie:`Pie chart`,bar:`Bar chart`,line:`Line chart`,scatter:`Scatter plot`,effectScatter:`Ripple scatter plot`,radar:`Radar chart`,tree:`Tree`,treemap:`Treemap`,boxplot:`Boxplot`,candlestick:`Candlestick`,k:`K line chart`,heatmap:`Heat map`,map:`Map`,parallel:`Parallel coordinate map`,lines:`Line graph`,graph:`Relationship graph`,sankey:`Sankey diagram`,funnel:`Funnel chart`,gauge:`Gauge`,pictorialBar:`Pictorial bar`,themeRiver:`Theme River Map`,sunburst:`Sunburst`,custom:`Custom chart`,chart:`Chart`}},aria:{general:{withTitle:`This is a chart about "{title}"`,withoutTitle:`This is a chart`},series:{single:{prefix:``,withName:` with type {seriesType} named {seriesName}.`,withoutName:` with type {seriesType}.`},multiple:{prefix:`. It consists of {seriesCount} series count.`,withName:` The {seriesId} series is a {seriesType} representing {seriesName}.`,withoutName:` The {seriesId} series is a {seriesType}.`,separator:{middle:``,end:``}}},data:{allData:`The data is as follows: `,partialData:`The first {displayCnt} items are: `,withName:`the data for {name} is {value}`,withoutName:`{value}`,separator:{middle:`, `,end:`. `}}}},vT={time:{month:[`一月`,`二月`,`三月`,`四月`,`五月`,`六月`,`七月`,`八月`,`九月`,`十月`,`十一月`,`十二月`],monthAbbr:[`1月`,`2月`,`3月`,`4月`,`5月`,`6月`,`7月`,`8月`,`9月`,`10月`,`11月`,`12月`],dayOfWeek:[`星期日`,`星期一`,`星期二`,`星期三`,`星期四`,`星期五`,`星期六`],dayOfWeekAbbr:[`日`,`一`,`二`,`三`,`四`,`五`,`六`]},legend:{selector:{all:`全选`,inverse:`反选`}},toolbox:{brush:{title:{rect:`矩形选择`,polygon:`圈选`,lineX:`横向选择`,lineY:`纵向选择`,keep:`保持选择`,clear:`清除选择`}},dataView:{title:`数据视图`,lang:[`数据视图`,`关闭`,`刷新`]},dataZoom:{title:{zoom:`区域缩放`,back:`区域缩放还原`}},magicType:{title:{line:`切换为折线图`,bar:`切换为柱状图`,stack:`切换为堆叠`,tiled:`切换为平铺`}},restore:{title:`还原`},saveAsImage:{title:`保存为图片`,lang:[`右键另存为图片`]}},series:{typeNames:{pie:`饼图`,bar:`柱状图`,line:`折线图`,scatter:`散点图`,effectScatter:`涟漪散点图`,radar:`雷达图`,tree:`树图`,treemap:`矩形树图`,boxplot:`箱型图`,candlestick:`K线图`,k:`K线图`,heatmap:`热力图`,map:`地图`,parallel:`平行坐标图`,lines:`线图`,graph:`关系图`,sankey:`桑基图`,funnel:`漏斗图`,gauge:`仪表盘图`,pictorialBar:`象形柱图`,themeRiver:`主题河流图`,sunburst:`旭日图`,custom:`自定义图表`,chart:`图表`}},aria:{general:{withTitle:`这是一个关于“{title}”的图表。`,withoutTitle:`这是一个图表,`},series:{single:{prefix:``,withName:`图表类型是{seriesType},表示{seriesName}。`,withoutName:`图表类型是{seriesType}。`},multiple:{prefix:`它由{seriesCount}个图表系列组成。`,withName:`第{seriesId}个系列是一个表示{seriesName}的{seriesType},`,withoutName:`第{seriesId}个系列是一个{seriesType},`,separator:{middle:`;`,end:`。`}}},data:{allData:`其数据是——`,partialData:`其中,前{displayCnt}项是——`,withName:`{name}的数据是{value}`,withoutName:`{value}`,separator:{middle:`,`,end:``}}}},yT=`ZH`,bT=`EN`,xT=bT,ST={},CT={},wT=W.domSupported?function(){return(document.documentElement.lang||navigator.language||navigator.browserLanguage||xT).toUpperCase().indexOf(yT)>-1?yT:xT}():xT;function TT(e,t){e=e.toUpperCase(),CT[e]=new dT(t),ST[e]=t}function ET(e){if(Y(e)){var t=ST[e.toUpperCase()]||{};return e===yT||e===bT?G(t):qf(G(t),G(ST[xT]),!1)}return qf(G(e),G(ST[xT]),!1)}function DT(e){return CT[e]}function OT(){return CT[xT]}TT(bT,_T),TT(yT,vT);var kT={year:`{yyyy}`,month:`{MMM}`,day:`{d}`,hour:`{HH}:{mm}`,minute:`{HH}:{mm}`,second:`{HH}:{mm}:{ss}`,millisecond:`{HH}:{mm}:{ss} {SSS}`,none:`{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}`},AT=`{yyyy}-{MM}-{dd}`;AT+``+kT.hour,AT+``+kT.minute,AT+``+kT.second,kT.none;function jT(e,t){return e+=``,`0000`.substr(0,t-e.length)+e}function MT(e,t,n,r){var i=_v(e),a=i[NT(n)](),o=i[PT(n)]()+1,s=Math.floor((o-1)/3)+1,c=i[FT(n)](),l=i[`get`+(n?`UTC`:``)+`Day`](),u=i[IT(n)](),d=(u-1)%12+1,f=i[LT(n)](),p=i[RT(n)](),m=i[zT(n)](),h=u>=12?`pm`:`am`,g=h.toUpperCase(),_=(r instanceof dT?r:DT(r||wT)||OT()).getModel(`time`),v=_.get(`month`),y=_.get(`monthAbbr`),b=_.get(`dayOfWeek`),x=_.get(`dayOfWeekAbbr`);return(t||``).replace(/{a}/g,h+``).replace(/{A}/g,g+``).replace(/{yyyy}/g,a+``).replace(/{yy}/g,jT(a%100+``,2)).replace(/{Q}/g,s+``).replace(/{MMMM}/g,v[o-1]).replace(/{MMM}/g,y[o-1]).replace(/{MM}/g,jT(o,2)).replace(/{M}/g,o+``).replace(/{dd}/g,jT(c,2)).replace(/{d}/g,c+``).replace(/{eeee}/g,b[l]).replace(/{ee}/g,x[l]).replace(/{e}/g,l+``).replace(/{HH}/g,jT(u,2)).replace(/{H}/g,u+``).replace(/{hh}/g,jT(d+``,2)).replace(/{h}/g,d+``).replace(/{mm}/g,jT(f,2)).replace(/{m}/g,f+``).replace(/{ss}/g,jT(p,2)).replace(/{s}/g,p+``).replace(/{SSS}/g,jT(m,3)).replace(/{S}/g,m+``)}function NT(e){return e?`getUTCFullYear`:`getFullYear`}function PT(e){return e?`getUTCMonth`:`getMonth`}function FT(e){return e?`getUTCDate`:`getDate`}function IT(e){return e?`getUTCHours`:`getHours`}function LT(e){return e?`getUTCMinutes`:`getMinutes`}function RT(e){return e?`getUTCSeconds`:`getSeconds`}function zT(e){return e?`getUTCMilliseconds`:`getMilliseconds`}function BT(e){if(!yv(e))return Y(e)?e:`-`;var t=(e+``).split(`.`);return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,`$1,`)+(t.length>1?`.`+t[1]:``)}function VT(e,t){return e=(e||``).toLowerCase().replace(/-(.)/g,function(e,t){return t.toUpperCase()}),t&&e&&(e=e.charAt(0).toUpperCase()+e.slice(1)),e}var HT=vp;function UT(e,t,n){var r=`{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}`;function i(e){return e&&bp(e)?e:`-`}function a(e){return!(e==null||isNaN(e)||!isFinite(e))}var o=t===`time`,s=e instanceof Date;if(o||s){var c=o?_v(e):e;if(!isNaN(+c))return MT(c,r,n);if(s)return`-`}if(t===`ordinal`)return sp(e)?i(e):cp(e)&&a(e)?e+``:`-`;var l=vv(e);return a(l)?BT(l):sp(e)?i(e):typeof e==`boolean`?e+``:`-`}var WT=[`a`,`b`,`c`,`d`,`e`,`f`,`g`],GT=function(e,t){return`{`+e+(t??``)+`}`};function KT(e,t,n){J(t)||(t=[t]);var r=t.length;if(!r)return``;for(var i=t[0].$vars||[],a=0;a<i.length;a++){var o=WT[a];e=e.replace(GT(o),GT(o,0))}for(var s=0;s<r;s++)for(var c=0;c<i.length;c++){var l=t[s][i[c]];e=e.replace(GT(WT[c],s),n?pm(l):l)}return e}function qT(e,t){var n=Y(e)?{color:e,extraCssText:t}:e||{},r=n.color,i=n.type;t=n.extraCssText;var a=n.renderMode||`html`;return r?a===`html`?i===`subItem`?`<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:`+pm(r)+`;`+(t||``)+`"></span>`:`<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:`+pm(r)+`;`+(t||``)+`"></span>`:{renderMode:a,content:`{`+(n.markerId||`markerX`)+`|} `,style:i===`subItem`?{width:4,height:4,borderRadius:2,backgroundColor:r}:{width:10,height:10,borderRadius:5,backgroundColor:r}}:``}function JT(e,t){return t||=`transparent`,Y(e)?e:X(e)&&e.colorStops&&(e.colorStops[0]||{}).color||t}function YT(e,t){if(t===`_blank`||t===`blank`){var n=window.open();n.opener=null,n.location.href=e}else window.open(e,t)}var XT=q,ZT=[`left`,`right`,`top`,`bottom`,`width`,`height`],QT=[[`width`,`left`,`right`],[`height`,`top`,`bottom`]];function $T(e,t,n,r,i){var a=0,o=0;r??=1/0,i??=1/0;var s=0;t.eachChild(function(c,l){var u=c.getBoundingRect(),d=t.childAt(l+1),f=d&&d.getBoundingRect(),p,m;if(e===`horizontal`){var h=u.width+(f?-f.x+u.x:0);p=a+h,p>r||c.newline?(a=0,p=h,o+=s+n,s=u.height):s=Math.max(s,u.height)}else{var g=u.height+(f?-f.y+u.y:0);m=o+g,m>i||c.newline?(a+=s+n,o=0,m=g,s=u.width):s=Math.max(s,u.width)}c.newline||(c.x=a,c.y=o,c.markRedraw(),e===`horizontal`?a=p+n:o=m+n)})}var eE=$T;ap($T,`vertical`),ap($T,`horizontal`);function tE(e,t,n){var r=t.width,i=t.height,a=lv(e.left,r),o=lv(e.top,i),s=lv(e.right,r),c=lv(e.bottom,i);return(isNaN(a)||isNaN(parseFloat(e.left)))&&(a=0),(isNaN(s)||isNaN(parseFloat(e.right)))&&(s=r),(isNaN(o)||isNaN(parseFloat(e.top)))&&(o=0),(isNaN(c)||isNaN(parseFloat(e.bottom)))&&(c=i),n=HT(n||0),{width:Math.max(s-a-n[1]-n[3],0),height:Math.max(c-o-n[0]-n[2],0)}}function nE(e,t,n){n=HT(n||0);var r=t.width,i=t.height,a=lv(e.left,r),o=lv(e.top,i),s=lv(e.right,r),c=lv(e.bottom,i),l=lv(e.width,r),u=lv(e.height,i),d=n[2]+n[0],f=n[1]+n[3],p=e.aspect;switch(isNaN(l)&&(l=r-s-f-a),isNaN(u)&&(u=i-c-d-o),p!=null&&(isNaN(l)&&isNaN(u)&&(p>r/i?l=r*.8:u=i*.8),isNaN(l)&&(l=p*u),isNaN(u)&&(u=l/p)),isNaN(a)&&(a=r-s-l-f),isNaN(o)&&(o=i-c-u-d),e.left||e.right){case`center`:a=r/2-l/2-n[3];break;case`right`:a=r-l-f}switch(e.top||e.bottom){case`middle`:case`center`:o=i/2-u/2-n[0];break;case`bottom`:o=i-u-d}a||=0,o||=0,isNaN(l)&&(l=r-f-a-(s||0)),isNaN(u)&&(u=i-d-o-(c||0));var m=new $(a+n[3],o+n[0],l,u);return m.margin=n,m}function rE(e,t,n,r,i,a){var o=!i||!i.hv||i.hv[0],s=!i||!i.hv||i.hv[1],c=i&&i.boundingMode||`all`;if(a||=e,a.x=e.x,a.y=e.y,!o&&!s)return!1;var l;if(c===`raw`)l=e.type===`group`?new $(0,0,+t.width||0,+t.height||0):e.getBoundingRect();else if(l=e.getBoundingRect(),e.needLocalTransform()){var u=e.getLocalTransform();l=l.clone(),l.applyTransform(u)}var d=nE(Jf({width:l.width,height:l.height},t),n,r),f=o?d.x-l.x:0,p=s?d.y-l.y:0;return c===`raw`?(a.x=f,a.y=p):(a.x+=f,a.y+=p),a===e&&e.markRedraw(),!0}function iE(e){var t=e.layoutMode||e.constructor.layoutMode;return X(t)?t:t?{type:t}:null}function aE(e,t,n){var r=n&&n.ignoreSize;!J(r)&&(r=[r,r]);var i=o(QT[0],0),a=o(QT[1],1);l(QT[0],e,i),l(QT[1],e,a);function o(n,i){var a={},o=0,l={},u=0,d=2;if(XT(n,function(t){l[t]=e[t]}),XT(n,function(e){s(t,e)&&(a[e]=l[e]=t[e]),c(a,e)&&o++,c(l,e)&&u++}),r[i])return c(t,n[1])?l[n[2]]=null:c(t,n[2])&&(l[n[1]]=null),l;if(u===d||!o)return l;if(o>=d)return a;for(var f=0;f<n.length;f++){var p=n[f];if(!s(a,p)&&s(e,p)){a[p]=e[p];break}}return a}function s(e,t){return e.hasOwnProperty(t)}function c(e,t){return e[t]!=null&&e[t]!==`auto`}function l(e,t,n){XT(e,function(e){t[e]=n[e]})}}function oE(e){return sE({},e)}function sE(e,t){return t&&e&&XT(ZT,function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e}var cE=Kv(),lE=function(e){U(t,e);function t(t,n,r){var i=e.call(this,t,n,r)||this;return i.uid=pT(`ec_cpt_model`),i}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n)},t.prototype.mergeDefaultAndTheme=function(e,t){var n=iE(this),r=n?oE(e):{};qf(e,t.getTheme().get(this.mainType)),qf(e,this.getDefaultOption()),n&&aE(e,r,n)},t.prototype.mergeOption=function(e,t){qf(this.option,e,!0);var n=iE(this);n&&aE(this.option,e,n)},t.prototype.optionUpdated=function(e,t){},t.prototype.getDefaultOption=function(){var e=this.constructor;if(!oy(e))return e.defaultOption;var t=cE(this);if(!t.defaultOption){for(var n=[],r=e;r;){var i=r.prototype.defaultOption;i&&n.push(i),r=r.superClass}for(var a={},o=n.length-1;o>=0;o--)a=qf(a,n[o],!0);t.defaultOption=a}return t.defaultOption},t.prototype.getReferringComponents=function(e,t){var n=e+`Index`,r=e+`Id`;return Zv(this.ecModel,e,{index:this.get(n,!0),id:this.get(r,!0)},t)},t.prototype.getBoxLayoutParams=function(){var e=this;return{left:e.get(`left`),top:e.get(`top`),right:e.get(`right`),bottom:e.get(`bottom`),width:e.get(`width`),height:e.get(`height`)}},t.prototype.getZLevelKey=function(){return``},t.prototype.setZLevel=function(e){this.option.zlevel=e},t.protoInitialize=function(){var e=t.prototype;e.type=`component`,e.id=``,e.name=``,e.mainType=``,e.subType=``,e.componentIndex=0}(),t}(dT);ly(lE,dT),my(lE),mT(lE),hT(lE,uE);function uE(e){var t=[];return q(lE.getClassesByMainType(e),function(e){t=t.concat(e.dependencies||e.prototype.dependencies||[])}),t=$f(t,function(e){return iy(e).main}),e!==`dataset`&&Yf(t,`dataset`)<=0&&t.unshift(`dataset`),t}var dE=``;typeof navigator<`u`&&(dE=navigator.platform||``);var fE=`rgba(0, 0, 0, 0.2)`,pE={darkMode:`auto`,colorBy:`series`,color:[`#5470c6`,`#91cc75`,`#fac858`,`#ee6666`,`#73c0de`,`#3ba272`,`#fc8452`,`#9a60b4`,`#ea7ccc`],gradientColor:[`#f6efa6`,`#d88273`,`#bf444c`],aria:{decal:{decals:[{color:fE,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:fE,symbol:`circle`,dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:fE,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:fE,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:fE,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:fE,symbol:`triangle`,dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:dE.match(/^Win/)?`Microsoft YaHei`:`sans-serif`,fontSize:12,fontStyle:`normal`,fontWeight:`normal`},blendMode:null,stateAnimation:{duration:300,easing:`cubicOut`},animation:`auto`,animationDuration:1e3,animationDurationUpdate:500,animationEasing:`cubicInOut`,animationEasingUpdate:`cubicInOut`,animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},mE=Q([`tooltip`,`label`,`itemName`,`itemId`,`itemGroupId`,`itemChildGroupId`,`seriesName`]),hE=`original`,gE=`arrayRows`,_E=`objectRows`,vE=`keyedColumns`,yE=`typedArray`,bE=`unknown`,xE=`column`,SE={Must:1,Might:2,Not:3},CE=Kv();function wE(e){CE(e).datasetMap=Q()}function TE(e,t,n){var r={},i=EE(t);if(!i||!e)return r;var a=[],o=[],s=t.ecModel,c=CE(s).datasetMap,l=i.uid+`_`+n.seriesLayoutBy,u,d;e=e.slice(),q(e,function(t,n){var i=X(t)?t:e[n]={name:t};i.type===`ordinal`&&u==null&&(u=n,d=m(i)),r[i.name]=[]});var f=c.get(l)||c.set(l,{categoryWayDim:d,valueWayDim:0});q(e,function(e,t){var n=e.name,i=m(e);if(u==null){var s=f.valueWayDim;p(r[n],s,i),p(o,s,i),f.valueWayDim+=i}else if(u===t)p(r[n],0,i),p(a,0,i);else{var s=f.categoryWayDim;p(r[n],s,i),p(o,s,i),f.categoryWayDim+=i}});function p(e,t,n){for(var r=0;r<n;r++)e.push(t+r)}function m(e){var t=e.dimsDef;return t?t.length:1}return a.length&&(r.itemName=a),o.length&&(r.seriesName=o),r}function EE(e){if(!e.get(`data`,!0))return Zv(e.ecModel,`dataset`,{index:e.get(`datasetIndex`,!0),id:e.get(`datasetId`,!0)},Xv).models[0]}function DE(e){return!e.get(`transform`,!0)&&!e.get(`fromTransformResult`,!0)?[]:Zv(e.ecModel,`dataset`,{index:e.get(`fromDatasetIndex`,!0),id:e.get(`fromDatasetId`,!0)},Xv).models}function OE(e,t){return kE(e.data,e.sourceFormat,e.seriesLayoutBy,e.dimensionsDefine,e.startIndex,t)}function kE(e,t,n,r,i,a){var o,s=5;if(up(e))return SE.Not;var c,l;if(r){var u=r[a];X(u)?(c=u.name,l=u.type):Y(u)&&(c=u)}if(l!=null)return l===`ordinal`?SE.Must:SE.Not;if(t===`arrayRows`){var d=e;if(n===`row`){for(var f=d[a],p=0;p<(f||[]).length&&p<s;p++)if((o=b(f[i+p]))!=null)return o}else for(var p=0;p<d.length&&p<s;p++){var m=d[i+p];if(m&&(o=b(m[a]))!=null)return o}}else if(t===`objectRows`){var h=e;if(!c)return SE.Not;for(var p=0;p<h.length&&p<s;p++){var g=h[p];if(g&&(o=b(g[c]))!=null)return o}}else if(t===`keyedColumns`){var _=e;if(!c)return SE.Not;var f=_[c];if(!f||up(f))return SE.Not;for(var p=0;p<f.length&&p<s;p++)if((o=b(f[p]))!=null)return o}else if(t===`original`)for(var v=e,p=0;p<v.length&&p<s;p++){var g=v[p],y=kv(g);if(!J(y))return SE.Not;if((o=b(y[a]))!=null)return o}function b(e){var t=Y(e);if(e!=null&&Number.isFinite(Number(e))&&e!==``)return t?SE.Might:SE.Not;if(t&&e!==`-`)return SE.Must}return SE.Not}var AE=Q();function jE(e,t,n){var r=AE.get(t);if(!r)return n;var i=r(e);return i?n.concat(i):n}var ME=Kv(),NE=Kv(),PE=function(){function e(){}return e.prototype.getColorFromPalette=function(e,t,n){var r=Ev(this.get(`color`,!0)),i=this.get(`colorLayer`,!0);return LE(this,ME,r,i,e,t,n)},e.prototype.clearColorPalette=function(){RE(this,ME)},e}();function FE(e,t,n,r){return LE(e,NE,Ev(e.get([`aria`,`decal`,`decals`])),null,t,n,r)}function IE(e,t){for(var n=e.length,r=0;r<n;r++)if(e[r].length>t)return e[r];return e[n-1]}function LE(e,t,n,r,i,a,o){a||=e;var s=t(a),c=s.paletteIdx||0,l=s.paletteNameMap=s.paletteNameMap||{};if(l.hasOwnProperty(i))return l[i];var u=o==null||!r?n:IE(r,o);if(u||=n,u&&u.length){var d=u[c];return i&&(l[i]=d),s.paletteIdx=(c+1)%u.length,d}}function RE(e,t){t(e).paletteIdx=0,t(e).paletteNameMap={}}var zE,BE,VE,HE=`\0_ec_inner`,UE=1,WE=function(e){U(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.init=function(e,t,n,r,i,a){r||={},this.option=null,this._theme=new dT(r),this._locale=new dT(i),this._optionManager=a},t.prototype.setOption=function(e,t,n){var r=YE(t);this._optionManager.setOption(e,n,r),this._resetOption(null,r)},t.prototype.resetOption=function(e,t){return this._resetOption(e,YE(t))},t.prototype._resetOption=function(e,t){var n=!1,r=this._optionManager;if(!e||e===`recreate`){var i=r.mountOption(e===`recreate`);!this.option||e===`recreate`?VE(this,i):(this.restoreData(),this._mergeOption(i,t)),n=!0}if((e===`timeline`||e===`media`)&&this.restoreData(),!e||e===`recreate`||e===`timeline`){var a=r.getTimelineOption(this);a&&(n=!0,this._mergeOption(a,t))}if(!e||e===`recreate`||e===`media`){var o=r.getMediaOption(this);o.length&&q(o,function(e){n=!0,this._mergeOption(e,t)},this)}return n},t.prototype.mergeOption=function(e){this._mergeOption(e,null)},t.prototype._mergeOption=function(e,t){var n=this.option,r=this._componentsMap,i=this._componentsCount,a=[],o=Q(),s=t&&t.replaceMergeMainTypeMap;wE(this),q(e,function(e,t){e!=null&&(lE.hasClass(t)?t&&(a.push(t),o.set(t,!0)):n[t]=n[t]==null?G(e):qf(n[t],e,!0))}),s&&s.each(function(e,t){lE.hasClass(t)&&!o.get(t)&&(a.push(t),o.set(t,!0))}),lE.topologicalTravel(a,lE.getAllClassMainTypes(),c,this);function c(t){var a=jE(this,t,Ev(e[t])),o=r.get(t),c=jv(o,a,o?s&&s.get(t)?`replaceMerge`:`normalMerge`:`replaceAll`);Uv(c,t,lE),n[t]=null,r.set(t,null),i.set(t,0);var l=[],u=[],d=0,f;q(c,function(e,n){var r=e.existing,i=e.newOption;if(!i)r&&(r.mergeOption({},this),r.optionUpdated({},!1));else{var a=t===`series`,o=lE.getClass(t,e.keyInfo.subType,!a);if(!o)return;if(t===`tooltip`){if(f)return;f=!0}if(r&&r.constructor===o)r.name=e.keyInfo.name,r.mergeOption(i,this),r.optionUpdated(i,!1);else{var s=K({componentIndex:n},e.keyInfo);r=new o(i,this,this,s),K(r,s),e.brandNew&&(r.__requireNewView=!0),r.init(i,this,this),r.optionUpdated(null,!0)}}r?(l.push(r.option),u.push(r),d++):(l.push(void 0),u.push(void 0))},this),n[t]=l,r.set(t,u),i.set(t,d),t===`series`&&zE(this)}this._seriesIndices||zE(this)},t.prototype.getOption=function(){var e=G(this.option);return q(e,function(t,n){if(lE.hasClass(n)){for(var r=Ev(t),i=r.length,a=!1,o=i-1;o>=0;o--)r[o]&&!Hv(r[o])?a=!0:(r[o]=null,!a&&i--);r.length=i,e[n]=r}}),delete e[HE],e},t.prototype.getTheme=function(){return this._theme},t.prototype.getLocaleModel=function(){return this._locale},t.prototype.setUpdatePayload=function(e){this._payload=e},t.prototype.getUpdatePayload=function(){return this._payload},t.prototype.getComponent=function(e,t){var n=this._componentsMap.get(e);if(n){var r=n[t||0];if(r)return r;if(t==null){for(var i=0;i<n.length;i++)if(n[i])return n[i]}}},t.prototype.queryComponents=function(e){var t=e.mainType;if(!t)return[];var n=e.index,r=e.id,i=e.name,a=this._componentsMap.get(t);if(!a||!a.length)return[];var o;return n==null?o=r==null?i==null?tp(a,function(e){return!!e}):qE(`name`,i,a):qE(`id`,r,a):(o=[],q(Ev(n),function(e){a[e]&&o.push(a[e])})),JE(o,e)},t.prototype.findComponents=function(e){var t=e.query,n=e.mainType,r=i(t);return a(JE(r?this.queryComponents(r):tp(this._componentsMap.get(n),function(e){return!!e}),e));function i(e){var t=n+`Index`,r=n+`Id`,i=n+`Name`;return e&&(e[t]!=null||e[r]!=null||e[i]!=null)?{mainType:n,index:e[t],id:e[r],name:e[i]}:null}function a(t){return e.filter?tp(t,e.filter):t}},t.prototype.eachComponent=function(e,t,n){var r=this._componentsMap;if(op(e)){var i=t,a=e;r.each(function(e,t){for(var n=0;e&&n<e.length;n++){var r=e[n];r&&a.call(i,t,r,r.componentIndex)}})}else for(var o=Y(e)?r.get(e):X(e)?this.findComponents(e):null,s=0;o&&s<o.length;s++){var c=o[s];c&&t.call(n,c,c.componentIndex)}},t.prototype.getSeriesByName=function(e){var t=Bv(e,null);return tp(this._componentsMap.get(`series`),function(e){return!!e&&t!=null&&e.name===t})},t.prototype.getSeriesByIndex=function(e){return this._componentsMap.get(`series`)[e]},t.prototype.getSeriesByType=function(e){return tp(this._componentsMap.get(`series`),function(t){return!!t&&t.subType===e})},t.prototype.getSeries=function(){return tp(this._componentsMap.get(`series`),function(e){return!!e})},t.prototype.getSeriesCount=function(){return this._componentsCount.get(`series`)},t.prototype.eachSeries=function(e,t){BE(this),q(this._seriesIndices,function(n){var r=this._componentsMap.get(`series`)[n];e.call(t,r,n)},this)},t.prototype.eachRawSeries=function(e,t){q(this._componentsMap.get(`series`),function(n){n&&e.call(t,n,n.componentIndex)})},t.prototype.eachSeriesByType=function(e,t,n){BE(this),q(this._seriesIndices,function(r){var i=this._componentsMap.get(`series`)[r];i.subType===e&&t.call(n,i,r)},this)},t.prototype.eachRawSeriesByType=function(e,t,n){return q(this.getSeriesByType(e),t,n)},t.prototype.isSeriesFiltered=function(e){return BE(this),this._seriesIndicesMap.get(e.componentIndex)==null},t.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},t.prototype.filterSeries=function(e,t){BE(this);var n=[];q(this._seriesIndices,function(r){var i=this._componentsMap.get(`series`)[r];e.call(t,i,r)&&n.push(r)},this),this._seriesIndices=n,this._seriesIndicesMap=Q(n)},t.prototype.restoreData=function(e){zE(this);var t=this._componentsMap,n=[];t.each(function(e,t){lE.hasClass(t)&&n.push(t)}),lE.topologicalTravel(n,lE.getAllClassMainTypes(),function(n){q(t.get(n),function(t){t&&(n!==`series`||!GE(t,e))&&t.restoreData()})})},t.internalField=function(){zE=function(e){var t=e._seriesIndices=[];q(e._componentsMap.get(`series`),function(e){e&&t.push(e.componentIndex)}),e._seriesIndicesMap=Q(t)},BE=function(e){},VE=function(e,t){e.option={},e.option[HE]=UE,e._componentsMap=Q({series:[]}),e._componentsCount=Q();var n=t.aria;X(n)&&n.enabled==null&&(n.enabled=!0),KE(t,e._theme.option),qf(t,pE,!1),e._mergeOption(t,null)}}(),t}(dT);function GE(e,t){if(t){var n=t.seriesIndex,r=t.seriesId,i=t.seriesName;return n!=null&&e.componentIndex!==n||r!=null&&e.id!==r||i!=null&&e.name!==i}}function KE(e,t){var n=e.color&&!e.colorLayer;q(t,function(t,r){r===`colorLayer`&&n||lE.hasClass(r)||(typeof t==`object`?e[r]=e[r]?qf(e[r],t,!1):G(t):e[r]??(e[r]=t))})}function qE(e,t,n){if(J(t)){var r=Q();return q(t,function(e){e!=null&&Bv(e,null)!=null&&r.set(e,!0)}),tp(n,function(t){return t&&r.get(t[e])})}var i=Bv(t,null);return tp(n,function(t){return t&&i!=null&&t[e]===i})}function JE(e,t){return t.hasOwnProperty(`subType`)?tp(e,function(e){return e&&e.subType===t.subType}):e}function YE(e){var t=Q();return e&&q(Ev(e.replaceMerge),function(e){t.set(e,!0)}),{replaceMergeMainTypeMap:t}}Zf(WE,PE);var XE=[`getDom`,`getZr`,`getWidth`,`getHeight`,`getDevicePixelRatio`,`dispatchAction`,`isSSR`,`isDisposed`,`on`,`off`,`getDataURL`,`getConnectedDataURL`,`getOption`,`getId`,`updateLabelLayout`],ZE=function(){function e(e){q(XE,function(t){this[t]=ip(e[t],e)},this)}return e}(),QE={},$E=function(){function e(){this._coordinateSystems=[]}return e.prototype.create=function(e,t){var n=[];q(QE,function(r,i){var a=r.create(e,t);n=n.concat(a||[])}),this._coordinateSystems=n},e.prototype.update=function(e,t){q(this._coordinateSystems,function(n){n.update&&n.update(e,t)})},e.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},e.register=function(e,t){QE[e]=t},e.get=function(e){return QE[e]},e}(),eD=/^(min|max)?(.+)$/,tD=function(){function e(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return e.prototype.setOption=function(e,t,n){e&&(q(Ev(e.series),function(e){e&&e.data&&up(e.data)&&Sp(e.data)}),q(Ev(e.dataset),function(e){e&&e.source&&up(e.source)&&Sp(e.source)})),e=G(e);var r=this._optionBackup,i=nD(e,t,!r);this._newBaseOption=i.baseOption,r?(i.timelineOptions.length&&(r.timelineOptions=i.timelineOptions),i.mediaList.length&&(r.mediaList=i.mediaList),i.mediaDefault&&(r.mediaDefault=i.mediaDefault)):this._optionBackup=i},e.prototype.mountOption=function(e){var t=this._optionBackup;return this._timelineOptions=t.timelineOptions,this._mediaList=t.mediaList,this._mediaDefault=t.mediaDefault,this._currentMediaIndices=[],G(e?t.baseOption:this._newBaseOption)},e.prototype.getTimelineOption=function(e){var t,n=this._timelineOptions;if(n.length){var r=e.getComponent(`timeline`);r&&(t=G(n[r.getCurrentIndex()]))}return t},e.prototype.getMediaOption=function(e){var t=this._api.getWidth(),n=this._api.getHeight(),r=this._mediaList,i=this._mediaDefault,a=[],o=[];if(!r.length&&!i)return o;for(var s=0,c=r.length;s<c;s++)rD(r[s].query,t,n)&&a.push(s);return!a.length&&i&&(a=[-1]),a.length&&!aD(a,this._currentMediaIndices)&&(o=$f(a,function(e){return G(e===-1?i.option:r[e].option)})),this._currentMediaIndices=a,o},e}();function nD(e,t,n){var r=[],i,a,o=e.baseOption,s=e.timeline,c=e.options,l=e.media,u=!!e.media,d=!!(c||s||o&&o.timeline);o?(a=o,a.timeline||(a.timeline=s)):((d||u)&&(e.options=e.media=null),a=e),u&&J(l)&&q(l,function(e){e&&e.option&&(e.query?r.push(e):i||=e)}),f(a),q(c,function(e){return f(e)}),q(r,function(e){return f(e.option)});function f(e){q(t,function(t){t(e,n)})}return{baseOption:a,timelineOptions:c||[],mediaDefault:i,mediaList:r}}function rD(e,t,n){var r={width:t,height:n,aspectratio:t/n},i=!0;return q(e,function(e,t){var n=t.match(eD);if(n&&n[1]&&n[2]){var a=n[1];iD(r[n[2].toLowerCase()],e,a)||(i=!1)}}),i}function iD(e,t,n){return n===`min`?e>=t:n===`max`?e<=t:e===t}function aD(e,t){return e.join(`,`)===t.join(`,`)}var oD=q,sD=X,cD=[`areaStyle`,`lineStyle`,`nodeStyle`,`linkStyle`,`chordStyle`,`label`,`labelLine`];function lD(e){var t=e&&e.itemStyle;if(t)for(var n=0,r=cD.length;n<r;n++){var i=cD[n],a=t.normal,o=t.emphasis;a&&a[i]&&(e[i]=e[i]||{},e[i].normal?qf(e[i].normal,a[i]):e[i].normal=a[i],a[i]=null),o&&o[i]&&(e[i]=e[i]||{},e[i].emphasis?qf(e[i].emphasis,o[i]):e[i].emphasis=o[i],o[i]=null)}}function uD(e,t,n){if(e&&e[t]&&(e[t].normal||e[t].emphasis)){var r=e[t].normal,i=e[t].emphasis;r&&(n?(e[t].normal=e[t].emphasis=null,Jf(e[t],r)):e[t]=r),i&&(e.emphasis=e.emphasis||{},e.emphasis[t]=i,i.focus&&(e.emphasis.focus=i.focus),i.blurScope&&(e.emphasis.blurScope=i.blurScope))}}function dD(e){uD(e,`itemStyle`),uD(e,`lineStyle`),uD(e,`areaStyle`),uD(e,`label`),uD(e,`labelLine`),uD(e,`upperLabel`),uD(e,`edgeLabel`)}function fD(e,t){var n=sD(e)&&e[t],r=sD(n)&&n.textStyle;if(r)for(var i=0,a=Ov.length;i<a;i++){var o=Ov[i];r.hasOwnProperty(o)&&(n[o]=r[o])}}function pD(e){e&&(dD(e),fD(e,`label`),e.emphasis&&fD(e.emphasis,`label`))}function mD(e){if(sD(e)){lD(e),dD(e),fD(e,`label`),fD(e,`upperLabel`),fD(e,`edgeLabel`),e.emphasis&&(fD(e.emphasis,`label`),fD(e.emphasis,`upperLabel`),fD(e.emphasis,`edgeLabel`));var t=e.markPoint;t&&(lD(t),pD(t));var n=e.markLine;n&&(lD(n),pD(n));var r=e.markArea;r&&pD(r);var i=e.data;if(e.type===`graph`){i||=e.nodes;var a=e.links||e.edges;if(a&&!up(a))for(var o=0;o<a.length;o++)pD(a[o]);q(e.categories,function(e){dD(e)})}if(i&&!up(i))for(var o=0;o<i.length;o++)pD(i[o]);if(t=e.markPoint,t&&t.data)for(var s=t.data,o=0;o<s.length;o++)pD(s[o]);if(n=e.markLine,n&&n.data)for(var c=n.data,o=0;o<c.length;o++)J(c[o])?(pD(c[o][0]),pD(c[o][1])):pD(c[o]);e.type===`gauge`?(fD(e,`axisLabel`),fD(e,`title`),fD(e,`detail`)):e.type===`treemap`?(uD(e.breadcrumb,`itemStyle`),q(e.levels,function(e){dD(e)})):e.type===`tree`&&dD(e.leaves)}}function hD(e){return J(e)?e:e?[e]:[]}function gD(e){return(J(e)?e[0]:e)||{}}function _D(e,t){oD(hD(e.series),function(e){sD(e)&&mD(e)});var n=[`xAxis`,`yAxis`,`radiusAxis`,`angleAxis`,`singleAxis`,`parallelAxis`,`radar`];t&&n.push(`valueAxis`,`categoryAxis`,`logAxis`,`timeAxis`),oD(n,function(t){oD(hD(e[t]),function(e){e&&(fD(e,`axisLabel`),fD(e.axisPointer,`label`))})}),oD(hD(e.parallel),function(e){var t=e&&e.parallelAxisDefault;fD(t,`axisLabel`),fD(t&&t.axisPointer,`label`)}),oD(hD(e.calendar),function(e){uD(e,`itemStyle`),fD(e,`dayLabel`),fD(e,`monthLabel`),fD(e,`yearLabel`)}),oD(hD(e.radar),function(e){fD(e,`name`),e.name&&e.axisName==null&&(e.axisName=e.name,delete e.name),e.nameGap!=null&&e.axisNameGap==null&&(e.axisNameGap=e.nameGap,delete e.nameGap)}),oD(hD(e.geo),function(e){sD(e)&&(pD(e),oD(hD(e.regions),function(e){pD(e)}))}),oD(hD(e.timeline),function(e){pD(e),uD(e,`label`),uD(e,`itemStyle`),uD(e,`controlStyle`,!0);var t=e.data;J(t)&&q(t,function(e){X(e)&&(uD(e,`label`),uD(e,`itemStyle`))})}),oD(hD(e.toolbox),function(e){uD(e,`iconStyle`),oD(e.feature,function(e){uD(e,`iconStyle`)})}),fD(gD(e.axisPointer),`label`),fD(gD(e.tooltip).axisPointer,`label`)}function vD(e,t){for(var n=t.split(`,`),r=e,i=0;i<n.length&&(r&&=r[n[i]],r!=null);i++);return r}function yD(e,t,n,r){for(var i=t.split(`,`),a=e,o,s=0;s<i.length-1;s++)o=i[s],a[o]??(a[o]={}),a=a[o];(r||a[i[s]]==null)&&(a[i[s]]=n)}function bD(e){e&&q(xD,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var xD=[[`x`,`left`],[`y`,`top`],[`x2`,`right`],[`y2`,`bottom`]],SD=[`grid`,`geo`,`parallel`,`legend`,`toolbox`,`title`,`visualMap`,`dataZoom`,`timeline`],CD=[[`borderRadius`,`barBorderRadius`],[`borderColor`,`barBorderColor`],[`borderWidth`,`barBorderWidth`]];function wD(e){var t=e&&e.itemStyle;if(t)for(var n=0;n<CD.length;n++){var r=CD[n][1],i=CD[n][0];t[r]!=null&&(t[i]=t[r])}}function TD(e){e&&e.alignTo===`edge`&&e.margin!=null&&e.edgeDistance==null&&(e.edgeDistance=e.margin)}function ED(e){e&&e.downplay&&!e.blur&&(e.blur=e.downplay)}function DD(e){e&&e.focusNodeAdjacency!=null&&(e.emphasis=e.emphasis||{},e.emphasis.focus??(e.emphasis.focus=`adjacency`))}function OD(e,t){if(e)for(var n=0;n<e.length;n++)t(e[n]),e[n]&&OD(e[n].children,t)}function kD(e,t){_D(e,t),e.series=Ev(e.series),q(e.series,function(e){if(X(e)){var t=e.type;if(t===`line`)e.clipOverflow!=null&&(e.clip=e.clipOverflow);else if(t===`pie`||t===`gauge`){e.clockWise!=null&&(e.clockwise=e.clockWise),TD(e.label);var n=e.data;if(n&&!up(n))for(var r=0;r<n.length;r++)TD(n[r]);e.hoverOffset!=null&&(e.emphasis=e.emphasis||{},(e.emphasis.scaleSize=null)&&(e.emphasis.scaleSize=e.hoverOffset))}else if(t===`gauge`){var i=vD(e,`pointer.color`);i!=null&&yD(e,`itemStyle.color`,i)}else if(t===`bar`){wD(e),wD(e.backgroundStyle),wD(e.emphasis);var n=e.data;if(n&&!up(n))for(var r=0;r<n.length;r++)typeof n[r]==`object`&&(wD(n[r]),wD(n[r]&&n[r].emphasis))}else if(t===`sunburst`){var a=e.highlightPolicy;a&&(e.emphasis=e.emphasis||{},e.emphasis.focus||(e.emphasis.focus=a)),ED(e),OD(e.data,ED)}else t===`graph`||t===`sankey`?DD(e):t===`map`&&(e.mapType&&!e.map&&(e.map=e.mapType),e.mapLocation&&Jf(e,e.mapLocation));e.hoverAnimation!=null&&(e.emphasis=e.emphasis||{},e.emphasis&&e.emphasis.scale==null&&(e.emphasis.scale=e.hoverAnimation)),bD(e)}}),e.dataRange&&(e.visualMap=e.dataRange),q(SD,function(t){var n=e[t];n&&(J(n)||(n=[n]),q(n,function(e){bD(e)}))})}function AD(e){var t=Q();e.eachSeries(function(e){var n=e.get(`stack`);if(n){var r=t.get(n)||t.set(n,[]),i=e.getData(),a={stackResultDimension:i.getCalculationInfo(`stackResultDimension`),stackedOverDimension:i.getCalculationInfo(`stackedOverDimension`),stackedDimension:i.getCalculationInfo(`stackedDimension`),stackedByDimension:i.getCalculationInfo(`stackedByDimension`),isStackedByIndex:i.getCalculationInfo(`isStackedByIndex`),data:i,seriesModel:e};if(!a.stackedDimension||!(a.isStackedByIndex||a.stackedByDimension))return;r.length&&i.setCalculationInfo(`stackedOnSeries`,r[r.length-1].seriesModel),r.push(a)}}),t.each(jD)}function jD(e){q(e,function(t,n){var r=[],i=[NaN,NaN],a=[t.stackResultDimension,t.stackedOverDimension],o=t.data,s=t.isStackedByIndex,c=t.seriesModel.get(`stackStrategy`)||`samesign`;o.modify(a,function(a,l,u){var d=o.get(t.stackedDimension,u);if(isNaN(d))return i;var f,p;s?p=o.getRawIndex(u):f=o.get(t.stackedByDimension,u);for(var m=NaN,h=n-1;h>=0;h--){var g=e[h];if(s||(p=g.data.rawIndexOf(g.stackedByDimension,f)),p>=0){var _=g.data.getByRawIndex(g.stackResultDimension,p);if(c===`all`||c===`positive`&&_>0||c===`negative`&&_<0||c===`samesign`&&d>=0&&_>0||c===`samesign`&&d<=0&&_<0){d=pv(d,_),m=_;break}}}return r[0]=d,r[1]=m,r})})}var MD=function(){function e(e){this.data=e.data||(e.sourceFormat===`keyedColumns`?{}:[]),this.sourceFormat=e.sourceFormat||`unknown`,this.seriesLayoutBy=e.seriesLayoutBy||`column`,this.startIndex=e.startIndex||0,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var t=this.dimensionsDefine=e.dimensionsDefine;if(t)for(var n=0;n<t.length;n++){var r=t[n];r.type==null&&OE(this,n)===SE.Must&&(r.type=`ordinal`)}}return e}();function ND(e){return e instanceof MD}function PD(e,t,n){n||=LD(e);var r=t.seriesLayoutBy,i=RD(e,n,r,t.sourceHeader,t.dimensions);return new MD({data:e,sourceFormat:n,seriesLayoutBy:r,dimensionsDefine:i.dimensionsDefine,startIndex:i.startIndex,dimensionsDetectedCount:i.dimensionsDetectedCount,metaRawOption:G(t)})}function FD(e){return new MD({data:e,sourceFormat:up(e)?yE:hE})}function ID(e){return new MD({data:e.data,sourceFormat:e.sourceFormat,seriesLayoutBy:e.seriesLayoutBy,dimensionsDefine:G(e.dimensionsDefine),startIndex:e.startIndex,dimensionsDetectedCount:e.dimensionsDetectedCount})}function LD(e){var t=bE;if(up(e))t=yE;else if(J(e)){e.length===0&&(t=gE);for(var n=0,r=e.length;n<r;n++){var i=e[n];if(i!=null){if(J(i)||up(i)){t=gE;break}if(X(i)){t=_E;break}}}}else if(X(e)){for(var a in e)if(jp(e,a)&&Qf(e[a])){t=vE;break}}return t}function RD(e,t,n,r,i){var a,o;if(!e)return{dimensionsDefine:BD(i),startIndex:o,dimensionsDetectedCount:a};if(t===`arrayRows`){var s=e;r===`auto`||r==null?VD(function(e){e!=null&&e!==`-`&&(Y(e)?o??=1:o=0)},n,s,10):o=cp(r)?r:+!!r,!i&&o===1&&(i=[],VD(function(e,t){i[t]=e==null?``:e+``},n,s,1/0)),a=i?i.length:n===`row`?s.length:s[0]?s[0].length:null}else if(t===`objectRows`)i||=zD(e);else if(t===`keyedColumns`)i||(i=[],q(e,function(e,t){i.push(t)}));else if(t===`original`){var c=kv(e[0]);a=J(c)&&c.length||1}return{startIndex:o,dimensionsDefine:BD(i),dimensionsDetectedCount:a}}function zD(e){for(var t=0,n;t<e.length&&!(n=e[t++]););if(n)return np(n)}function BD(e){if(e){var t=Q();return $f(e,function(e,n){e=X(e)?e:{name:e};var r={name:e.name,displayName:e.displayName,type:e.type};if(r.name==null)return r;r.name+=``,r.displayName??=r.name;var i=t.get(r.name);return i?r.name+=`-`+i.count++:t.set(r.name,{count:1}),r})}}function VD(e,t,n,r){if(t===`row`)for(var i=0;i<n.length&&i<r;i++)e(n[i]?n[i][0]:null,i);else for(var a=n[0]||[],i=0;i<a.length&&i<r;i++)e(a[i],i)}function HD(e){var t=e.sourceFormat;return t===`objectRows`||t===`keyedColumns`}var UD,WD,GD,KD,qD,JD=function(){function e(e,t){var n=ND(e)?e:FD(e);this._source=n;var r=this._data=n.data;n.sourceFormat===`typedArray`&&(this._offset=0,this._dimSize=t,this._data=r),qD(this,r,n)}return e.prototype.getSource=function(){return this._source},e.prototype.count=function(){return 0},e.prototype.getItem=function(e,t){},e.prototype.appendData=function(e){},e.prototype.clean=function(){},e.protoInitialize=function(){var t=e.prototype;t.pure=!1,t.persistent=!0}(),e.internalField=function(){var e;qD=function(e,i,a){var o=a.sourceFormat,s=a.seriesLayoutBy,c=a.startIndex,l=a.dimensionsDefine,u=KD[iO(o,s)];K(e,u),o===`typedArray`?(e.getItem=t,e.count=r,e.fillStorage=n):(e.getItem=ip(ZD(o,s),null,i,c,l),e.count=ip(eO(o,s),null,i,c,l))};var t=function(e,t){e-=this._offset,t||=[];for(var n=this._data,r=this._dimSize,i=r*e,a=0;a<r;a++)t[a]=n[i+a];return t},n=function(e,t,n,r){for(var i=this._data,a=this._dimSize,o=0;o<a;o++){for(var s=r[o],c=s[0]==null?1/0:s[0],l=s[1]==null?-1/0:s[1],u=t-e,d=n[o],f=0;f<u;f++){var p=i[f*a+o];d[e+f]=p,p<c&&(c=p),p>l&&(l=p)}s[0]=c,s[1]=l}},r=function(){return this._data?this._data.length/this._dimSize:0};KD=(e={},e[gE+`_`+xE]={pure:!0,appendData:i},e[gE+`_row`]={pure:!0,appendData:function(){throw Error(`Do not support appendData when set seriesLayoutBy: "row".`)}},e[_E]={pure:!0,appendData:i},e[vE]={pure:!0,appendData:function(e){var t=this._data;q(e,function(e,n){for(var r=t[n]||(t[n]=[]),i=0;i<(e||[]).length;i++)r.push(e[i])})}},e[hE]={appendData:i},e[yE]={persistent:!1,pure:!0,appendData:function(e){this._data=e},clean:function(){this._offset+=this.count(),this._data=null}},e);function i(e){for(var t=0;t<e.length;t++)this._data.push(e[t])}}(),e}(),YD=function(e,t,n,r){return e[r]},XD=(UD={},UD[gE+`_`+xE]=function(e,t,n,r){return e[r+t]},UD[gE+`_row`]=function(e,t,n,r,i){r+=t;for(var a=i||[],o=e,s=0;s<o.length;s++){var c=o[s];a[s]=c?c[r]:null}return a},UD[_E]=YD,UD[vE]=function(e,t,n,r,i){for(var a=i||[],o=0;o<n.length;o++){var s=e[n[o].name];a[o]=s?s[r]:null}return a},UD[hE]=YD,UD);function ZD(e,t){return XD[iO(e,t)]}var QD=function(e,t,n){return e.length},$D=(WD={},WD[gE+`_`+xE]=function(e,t,n){return Math.max(0,e.length-t)},WD[gE+`_row`]=function(e,t,n){var r=e[0];return r?Math.max(0,r.length-t):0},WD[_E]=QD,WD[vE]=function(e,t,n){var r=e[n[0].name];return r?r.length:0},WD[hE]=QD,WD);function eO(e,t){return $D[iO(e,t)]}var tO=function(e,t,n){return e[t]},nO=(GD={},GD[gE]=tO,GD[_E]=function(e,t,n){return e[n]},GD[vE]=tO,GD[hE]=function(e,t,n){var r=kv(e);return r instanceof Array?r[t]:r},GD[yE]=tO,GD);function rO(e){return nO[e]}function iO(e,t){return e===`arrayRows`?e+`_`+t:e}function aO(e,t,n){if(e){var r=e.getRawDataItem(t);if(r!=null){var i=e.getStore(),a=i.getSource().sourceFormat;if(n!=null){var o=e.getDimensionIndex(n),s=i.getDimensionProperty(o);return rO(a)(r,o,s)}var c=r;return a===`original`&&(c=kv(r)),c}}}var oO=/\{@(.+?)\}/g,sO=function(){function e(){}return e.prototype.getDataParams=function(e,t){var n=this.getData(t),r=this.getRawValue(e,t),i=n.getRawIndex(e),a=n.getName(e),o=n.getRawDataItem(e),s=n.getItemVisual(e,`style`),c=s&&s[n.getItemVisual(e,`drawType`)||`fill`],l=s&&s.stroke,u=this.mainType,d=u===`series`,f=n.userOutput&&n.userOutput.get();return{componentType:u,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:d?this.subType:null,seriesIndex:this.seriesIndex,seriesId:d?this.id:null,seriesName:d?this.name:null,name:a,dataIndex:i,data:o,dataType:t,value:r,color:c,borderColor:l,dimensionNames:f?f.fullDimensions:null,encode:f?f.encode:null,$vars:[`seriesName`,`name`,`value`]}},e.prototype.getFormattedLabel=function(e,t,n,r,i,a){t||=`normal`;var o=this.getData(n),s=this.getDataParams(e,n);if(a&&(s.value=a.interpolatedValue),r!=null&&J(s.value)&&(s.value=s.value[r]),i||=o.getItemModel(e).get(t===`normal`?[`label`,`formatter`]:[t,`label`,`formatter`]),op(i))return s.status=t,s.dimensionIndex=r,i(s);if(Y(i))return KT(i,s).replace(oO,function(t,n){var r=n.length,i=n;i.charAt(0)===`[`&&i.charAt(r-1)===`]`&&(i=+i.slice(1,r-1));var s=aO(o,e,i);if(a&&J(a.interpolatedValue)){var c=o.getDimensionIndex(i);c>=0&&(s=a.interpolatedValue[c])}return s==null?``:s+``})},e.prototype.getRawValue=function(e,t){return aO(this.getData(t),e)},e.prototype.formatTooltip=function(e,t,n){},e}();function cO(e){var t,n;return X(e)?e.type&&(n=e):t=e,{text:t,frag:n}}function lO(e){return new uO(e)}var uO=function(){function e(e){e||={},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return e.prototype.perform=function(e){var t=this._upstream,n=e&&e.skip;if(this._dirty&&t){var r=this.context;r.data=r.outputData=t.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var i;this._plan&&!n&&(i=this._plan(this.context));var a=l(this._modBy),o=this._modDataCount||0,s=l(e&&e.modBy),c=e&&e.modDataCount||0;(a!==s||o!==c)&&(i=`reset`);function l(e){return!(e>=1)&&(e=1),e}var u;(this._dirty||i===`reset`)&&(this._dirty=!1,u=this._doReset(n)),this._modBy=s,this._modDataCount=c;var d=e&&e.step;if(this._dueEnd=t?t._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var f=this._dueIndex,p=Math.min(d==null?1/0:this._dueIndex+d,this._dueEnd);if(!n&&(u||f<p)){var m=this._progress;if(J(m))for(var h=0;h<m.length;h++)this._doProgress(m[h],f,p,s,c);else this._doProgress(m,f,p,s,c)}this._dueIndex=p;var g=this._settedOutputEnd==null?p:this._settedOutputEnd;this._outputDueEnd=g}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd==null?this._dueEnd:this._settedOutputEnd;return this.unfinished()},e.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},e.prototype._doProgress=function(e,t,n,r,i){dO.reset(t,n,r,i),this._callingProgress=e,this._callingProgress({start:t,end:n,count:n-t,next:dO.next},this.context)},e.prototype._doReset=function(e){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var t,n;!e&&this._reset&&(t=this._reset(this.context),t&&t.progress&&(n=t.forceFirstProgress,t=t.progress),J(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var r=this._downstream;return r&&r.dirty(),n},e.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},e.prototype.pipe=function(e){(this._downstream!==e||this._dirty)&&(this._downstream=e,e._upstream=this,e.dirty())},e.prototype.dispose=function(){this._disposed||=(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,!0)},e.prototype.getUpstream=function(){return this._upstream},e.prototype.getDownstream=function(){return this._downstream},e.prototype.setOutputEnd=function(e){this._outputDueEnd=this._settedOutputEnd=e},e}(),dO=function(){var e,t,n,r,i,a={reset:function(c,l,u,d){t=c,e=l,n=u,r=d,i=Math.ceil(r/n),a.next=n>1&&r>0?s:o}};return a;function o(){return t<e?t++:null}function s(){var a=t%i*n+Math.ceil(t/i),o=t>=e?null:a<r?a:t;return t++,o}}();function fO(e,t){var n=t&&t.type;return n===`ordinal`?e:(n===`time`&&!cp(e)&&e!=null&&e!==`-`&&(e=+_v(e)),e==null||e===``?NaN:Number(e))}Q({number:function(e){return parseFloat(e)},time:function(e){return+_v(e)},trim:function(e){return Y(e)?bp(e):e}});var pO={lt:function(e,t){return e<t},lte:function(e,t){return e<=t},gt:function(e,t){return e>t},gte:function(e,t){return e>=t}};(function(){function e(e,t){cp(t)||Cv(``),this._opFn=pO[e],this._rvalFloat=vv(t)}return e.prototype.evaluate=function(e){return cp(e)?this._opFn(e,this._rvalFloat):this._opFn(vv(e),this._rvalFloat)},e})();var mO=function(){function e(e,t){var n=e===`desc`;this._resultLT=n?1:-1,t??=n?`min`:`max`,this._incomparable=t===`min`?-1/0:1/0}return e.prototype.evaluate=function(e,t){var n=cp(e)?e:vv(e),r=cp(t)?t:vv(t),i=isNaN(n),a=isNaN(r);if(i&&(n=this._incomparable),a&&(r=this._incomparable),i&&a){var o=Y(e),s=Y(t);o&&(n=s?e:0),s&&(r=o?t:0)}return n<r?this._resultLT:n>r?-this._resultLT:0},e}();(function(){function e(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=vv(t)}return e.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var n=typeof e;n!==this._rvalTypeof&&(n===`number`||this._rvalTypeof===`number`)&&(t=vv(e)===this._rvalFloat)}return this._isEQ?t:!t},e})();var hO=function(){function e(){}return e.prototype.getRawData=function(){throw Error(`not supported`)},e.prototype.getRawDataItem=function(e){throw Error(`not supported`)},e.prototype.cloneRawData=function(){},e.prototype.getDimensionInfo=function(e){},e.prototype.cloneAllDimensionInfo=function(){},e.prototype.count=function(){},e.prototype.retrieveValue=function(e,t){},e.prototype.retrieveValueFromItem=function(e,t){},e.prototype.convertValue=function(e,t){return fO(e,t)},e}();function gO(e,t){var n=new hO,r=e.data,i=n.sourceFormat=e.sourceFormat,a=e.startIndex;e.seriesLayoutBy!==`column`&&Cv(``);var o=[],s={},c=e.dimensionsDefine;if(c)q(c,function(e,t){var n=e.name,r={index:t,name:n,displayName:e.displayName};o.push(r),n!=null&&(jp(s,n)&&Cv(``),s[n]=r)});else for(var l=0;l<e.dimensionsDetectedCount;l++)o.push({index:l});var u=ZD(i,xE);t.__isBuiltIn&&(n.getRawDataItem=function(e){return u(r,a,o,e)},n.getRawData=ip(_O,null,e)),n.cloneRawData=ip(vO,null,e),n.count=ip(eO(i,xE),null,r,a,o);var d=rO(i);n.retrieveValue=function(e,t){return f(u(r,a,o,e),t)};var f=n.retrieveValueFromItem=function(e,t){if(e!=null){var n=o[t];if(n)return d(e,t,n.name)}};return n.getDimensionInfo=ip(yO,null,o,s),n.cloneAllDimensionInfo=ip(bO,null,o),n}function _O(e){var t=e.sourceFormat;return TO(t)||Cv(``),e.data}function vO(e){var t=e.sourceFormat,n=e.data;if(TO(t)||Cv(``),t===`arrayRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(n[i].slice());return r}if(t===`objectRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(K({},n[i]));return r}}function yO(e,t,n){if(n!=null){if(cp(n)||!isNaN(n)&&!jp(t,n))return e[n];if(jp(t,n))return t[n]}}function bO(e){return G(e)}var xO=Q();function SO(e){e=G(e);var t=e.type,n=``;t||Cv(n);var r=t.split(`:`);r.length!==2&&Cv(n);var i=!1;r[0]===`echarts`&&(t=r[1],i=!0),e.__isBuiltIn=i,xO.set(t,e)}function CO(e,t,n){var r=Ev(e),i=r.length;i||Cv(``);for(var a=0,o=i;a<o;a++){var s=r[a];t=wO(s,t,n,i===1?null:a),a!==o-1&&(t.length=Math.max(t.length,1))}return t}function wO(e,t,n,r){var i=``;t.length||Cv(i),X(e)||Cv(i);var a=e.type,o=xO.get(a);o||Cv(i);var s=$f(t,function(e){return gO(e,o)});return $f(Ev(o.transform({upstream:s[0],upstreamList:s,config:G(e.config)})),function(e,n){var r=``;X(e)||Cv(r),e.data||Cv(r),TO(LD(e.data))||Cv(r);var i,a=t[0];if(a&&n===0&&!e.dimensions){var o=a.startIndex;o&&(e.data=a.data.slice(0,o).concat(e.data)),i={seriesLayoutBy:xE,sourceHeader:o,dimensions:a.metaRawOption.dimensions}}else i={seriesLayoutBy:xE,sourceHeader:0,dimensions:e.dimensions};return PD(e.data,i,null)})}function TO(e){return e===`arrayRows`||e===`objectRows`}var EO=`undefined`,DO=typeof Uint32Array===EO?Array:Uint32Array,OO=typeof Uint16Array===EO?Array:Uint16Array,kO=typeof Int32Array===EO?Array:Int32Array,AO=typeof Float64Array===EO?Array:Float64Array,jO={float:AO,int:kO,ordinal:Array,number:Array,time:AO},MO;function NO(e){return e>65535?DO:OO}function PO(){return[1/0,-1/0]}function FO(e){var t=e.constructor;return t===Array?e.slice():new t(e)}function IO(e,t,n,r,i){var a=jO[n||`float`];if(i){var o=e[t],s=o&&o.length;if(s!==r){for(var c=new a(r),l=0;l<s;l++)c[l]=o[l];e[t]=c}}else e[t]=new a(r)}var LO=function(){function e(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=Q()}return e.prototype.initData=function(e,t,n){this._provider=e,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var r=e.getSource(),i=this.defaultDimValueGetter=MO[r.sourceFormat];this._dimValueGetter=n||i,this._rawExtent=[],HD(r),this._dimensions=$f(t,function(e){return{type:e.type,property:e.property}}),this._initDataFromProvider(0,e.count())},e.prototype.getProvider=function(){return this._provider},e.prototype.getSource=function(){return this._provider.getSource()},e.prototype.ensureCalculationDimension=function(e,t){var n=this._calcDimNameToIdx,r=this._dimensions,i=n.get(e);if(i!=null){if(r[i].type===t)return i}else i=r.length;return r[i]={type:t},n.set(e,i),this._chunks[i]=new jO[t||`float`](this._rawCount),this._rawExtent[i]=PO(),i},e.prototype.collectOrdinalMeta=function(e,t){var n=this._chunks[e],r=this._dimensions[e],i=this._rawExtent,a=r.ordinalOffset||0,o=n.length;a===0&&(i[e]=PO());for(var s=i[e],c=a;c<o;c++){var l=n[c]=t.parseAndCollect(n[c]);isNaN(l)||(s[0]=Math.min(l,s[0]),s[1]=Math.max(l,s[1]))}r.ordinalMeta=t,r.ordinalOffset=o,r.type=`ordinal`},e.prototype.getOrdinalMeta=function(e){return this._dimensions[e].ordinalMeta},e.prototype.getDimensionProperty=function(e){var t=this._dimensions[e];return t&&t.property},e.prototype.appendData=function(e){var t=this._provider,n=this.count();t.appendData(e);var r=t.count();return t.persistent||(r+=n),n<r&&this._initDataFromProvider(n,r,!0),[n,r]},e.prototype.appendValues=function(e,t){for(var n=this._chunks,r=this._dimensions,i=r.length,a=this._rawExtent,o=this.count(),s=o+Math.max(e.length,t||0),c=0;c<i;c++){var l=r[c];IO(n,c,l.type,s,!0)}for(var u=[],d=o;d<s;d++)for(var f=d-o,p=0;p<i;p++){var l=r[p],m=MO.arrayRows.call(this,e[f]||u,l.property,f,p);n[p][d]=m;var h=a[p];m<h[0]&&(h[0]=m),m>h[1]&&(h[1]=m)}return this._rawCount=this._count=s,{start:o,end:s}},e.prototype._initDataFromProvider=function(e,t,n){for(var r=this._provider,i=this._chunks,a=this._dimensions,o=a.length,s=this._rawExtent,c=$f(a,function(e){return e.property}),l=0;l<o;l++){var u=a[l];s[l]||(s[l]=PO()),IO(i,l,u.type,t,n)}if(r.fillStorage)r.fillStorage(e,t,i,s);else for(var d=[],f=e;f<t;f++){d=r.getItem(f,d);for(var p=0;p<o;p++){var m=i[p],h=this._dimValueGetter(d,c[p],f,p);m[f]=h;var g=s[p];h<g[0]&&(g[0]=h),h>g[1]&&(g[1]=h)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=t,this._extent=[]},e.prototype.count=function(){return this._count},e.prototype.get=function(e,t){if(!(t>=0&&t<this._count))return NaN;var n=this._chunks[e];return n?n[this.getRawIndex(t)]:NaN},e.prototype.getValues=function(e,t){var n=[],r=[];if(t==null){t=e,e=[];for(var i=0;i<this._dimensions.length;i++)r.push(i)}else r=e;for(var i=0,a=r.length;i<a;i++)n.push(this.get(r[i],t));return n},e.prototype.getByRawIndex=function(e,t){if(!(t>=0&&t<this._rawCount))return NaN;var n=this._chunks[e];return n?n[t]:NaN},e.prototype.getSum=function(e){var t=this._chunks[e],n=0;if(t)for(var r=0,i=this.count();r<i;r++){var a=this.get(e,r);isNaN(a)||(n+=a)}return n},e.prototype.getMedian=function(e){var t=[];this.each([e],function(e){isNaN(e)||t.push(e)});var n=t.sort(function(e,t){return e-t}),r=this.count();return r===0?0:r%2==1?n[(r-1)/2]:(n[r/2]+n[r/2-1])/2},e.prototype.indexOfRawIndex=function(e){if(e>=this._rawCount||e<0)return-1;if(!this._indices)return e;var t=this._indices,n=t[e];if(n!=null&&n<this._count&&n===e)return e;for(var r=0,i=this._count-1;r<=i;){var a=(r+i)/2|0;if(t[a]<e)r=a+1;else if(t[a]>e)i=a-1;else return a}return-1},e.prototype.indicesOfNearest=function(e,t,n){var r=this._chunks[e],i=[];if(!r)return i;n??=1/0;for(var a=1/0,o=-1,s=0,c=0,l=this.count();c<l;c++){var u=t-r[this.getRawIndex(c)],d=Math.abs(u);d<=n&&((d<a||d===a&&u>=0&&o<0)&&(a=d,o=u,s=0),u===o&&(i[s++]=c))}return i.length=s,i},e.prototype.getIndices=function(){var e,t=this._indices;if(t){var n=t.constructor,r=this._count;if(n===Array){e=new n(r);for(var i=0;i<r;i++)e[i]=t[i]}else e=new n(t.buffer,0,r)}else{var n=NO(this._rawCount);e=new n(this.count());for(var i=0;i<e.length;i++)e[i]=i}return e},e.prototype.filter=function(e,t){if(!this._count)return this;for(var n=this.clone(),r=n.count(),i=new(NO(n._rawCount))(r),a=[],o=e.length,s=0,c=e[0],l=n._chunks,u=0;u<r;u++){var d=void 0,f=n.getRawIndex(u);if(o===0)d=t(u);else if(o===1){var p=l[c][f];d=t(p,u)}else{for(var m=0;m<o;m++)a[m]=l[e[m]][f];a[m]=u,d=t.apply(null,a)}d&&(i[s++]=f)}return s<r&&(n._indices=i),n._count=s,n._extent=[],n._updateGetRawIdx(),n},e.prototype.selectRange=function(e){var t=this.clone(),n=t._count;if(!n)return this;var r=np(e),i=r.length;if(!i)return this;var a=t.count(),o=new(NO(t._rawCount))(a),s=0,c=r[0],l=e[c][0],u=e[c][1],d=t._chunks,f=!1;if(!t._indices){var p=0;if(i===1){for(var m=d[r[0]],h=0;h<n;h++){var g=m[h];(g>=l&&g<=u||isNaN(g))&&(o[s++]=p),p++}f=!0}else if(i===2){for(var m=d[r[0]],_=d[r[1]],v=e[r[1]][0],y=e[r[1]][1],h=0;h<n;h++){var g=m[h],b=_[h];(g>=l&&g<=u||isNaN(g))&&(b>=v&&b<=y||isNaN(b))&&(o[s++]=p),p++}f=!0}}if(!f){if(i===1)for(var h=0;h<a;h++){var x=t.getRawIndex(h),g=d[r[0]][x];(g>=l&&g<=u||isNaN(g))&&(o[s++]=x)}else for(var h=0;h<a;h++){for(var S=!0,x=t.getRawIndex(h),C=0;C<i;C++){var w=r[C],g=d[w][x];(g<e[w][0]||g>e[w][1])&&(S=!1)}S&&(o[s++]=t.getRawIndex(h))}}return s<a&&(t._indices=o),t._count=s,t._extent=[],t._updateGetRawIdx(),t},e.prototype.map=function(e,t){var n=this.clone(e);return this._updateDims(n,e,t),n},e.prototype.modify=function(e,t){this._updateDims(this,e,t)},e.prototype._updateDims=function(e,t,n){for(var r=e._chunks,i=[],a=t.length,o=e.count(),s=[],c=e._rawExtent,l=0;l<t.length;l++)c[t[l]]=PO();for(var u=0;u<o;u++){for(var d=e.getRawIndex(u),f=0;f<a;f++)s[f]=r[t[f]][d];s[a]=u;var p=n&&n.apply(null,s);if(p!=null){typeof p!=`object`&&(i[0]=p,p=i);for(var l=0;l<p.length;l++){var m=t[l],h=p[l],g=c[m],_=r[m];_&&(_[d]=h),h<g[0]&&(g[0]=h),h>g[1]&&(g[1]=h)}}}},e.prototype.lttbDownSample=function(e,t){var n=this.clone([e],!0),r=n._chunks[e],i=this.count(),a=0,o=Math.floor(1/t),s=this.getRawIndex(0),c,l,u,d=new(NO(this._rawCount))(Math.min((Math.ceil(i/o)+2)*2,i));d[a++]=s;for(var f=1;f<i-1;f+=o){for(var p=Math.min(f+o,i-1),m=Math.min(f+o*2,i),h=(m+p)/2,g=0,_=p;_<m;_++){var v=this.getRawIndex(_),y=r[v];isNaN(y)||(g+=y)}g/=m-p;var b=f,x=Math.min(f+o,i),S=f-1,C=r[s];c=-1,u=b;for(var w=-1,T=0,_=b;_<x;_++){var v=this.getRawIndex(_),y=r[v];isNaN(y)?(T++,w<0&&(w=v)):(l=Math.abs((S-h)*(y-C)-(S-_)*(g-C)),l>c&&(c=l,u=v))}T>0&&T<x-b&&(d[a++]=Math.min(w,u),u=Math.max(w,u)),d[a++]=u,s=u}return d[a++]=this.getRawIndex(i-1),n._count=a,n._indices=d,n.getRawIndex=this._getRawIdx,n},e.prototype.minmaxDownSample=function(e,t){for(var n=this.clone([e],!0),r=n._chunks,i=Math.floor(1/t),a=r[e],o=this.count(),s=new(NO(this._rawCount))(Math.ceil(o/i)*2),c=0,l=0;l<o;l+=i){var u=l,d=a[this.getRawIndex(u)],f=l,p=a[this.getRawIndex(f)],m=i;l+i>o&&(m=o-l);for(var h=0;h<m;h++){var g=a[this.getRawIndex(l+h)];g<d&&(d=g,u=l+h),g>p&&(p=g,f=l+h)}var _=this.getRawIndex(u),v=this.getRawIndex(f);u<f?(s[c++]=_,s[c++]=v):(s[c++]=v,s[c++]=_)}return n._count=c,n._indices=s,n._updateGetRawIdx(),n},e.prototype.downSample=function(e,t,n,r){for(var i=this.clone([e],!0),a=i._chunks,o=[],s=Math.floor(1/t),c=a[e],l=this.count(),u=i._rawExtent[e]=PO(),d=new(NO(this._rawCount))(Math.ceil(l/s)),f=0,p=0;p<l;p+=s){s>l-p&&(s=l-p,o.length=s);for(var m=0;m<s;m++){var h=this.getRawIndex(p+m);o[m]=c[h]}var g=n(o),_=this.getRawIndex(Math.min(p+r(o,g)||0,l-1));c[_]=g,g<u[0]&&(u[0]=g),g>u[1]&&(u[1]=g),d[f++]=_}return i._count=f,i._indices=d,i._updateGetRawIdx(),i},e.prototype.each=function(e,t){if(this._count)for(var n=e.length,r=this._chunks,i=0,a=this.count();i<a;i++){var o=this.getRawIndex(i);switch(n){case 0:t(i);break;case 1:t(r[e[0]][o],i);break;case 2:t(r[e[0]][o],r[e[1]][o],i);break;default:for(var s=0,c=[];s<n;s++)c[s]=r[e[s]][o];c[s]=i,t.apply(null,c)}}},e.prototype.getDataExtent=function(e){var t=this._chunks[e],n=PO();if(!t)return n;var r=this.count(),i=!this._indices,a;if(i)return this._rawExtent[e].slice();if(a=this._extent[e],a)return a.slice();a=n;for(var o=a[0],s=a[1],c=0;c<r;c++){var l=t[this.getRawIndex(c)];l<o&&(o=l),l>s&&(s=l)}return a=[o,s],this._extent[e]=a,a},e.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var n=[],r=this._chunks,i=0;i<r.length;i++)n.push(r[i][t]);return n},e.prototype.clone=function(t,n){var r=new e,i=this._chunks,a=t&&ep(t,function(e,t){return e[t]=!0,e},{});if(a)for(var o=0;o<i.length;o++)r._chunks[o]=a[o]?FO(i[o]):i[o];else r._chunks=i;return this._copyCommonProps(r),n||(r._indices=this._cloneIndices()),r._updateGetRawIdx(),r},e.prototype._copyCommonProps=function(e){e._count=this._count,e._rawCount=this._rawCount,e._provider=this._provider,e._dimensions=this._dimensions,e._extent=G(this._extent),e._rawExtent=G(this._rawExtent)},e.prototype._cloneIndices=function(){if(this._indices){var e=this._indices.constructor,t=void 0;if(e===Array){var n=this._indices.length;t=new e(n);for(var r=0;r<n;r++)t[r]=this._indices[r]}else t=new e(this._indices);return t}return null},e.prototype._getRawIdxIdentity=function(e){return e},e.prototype._getRawIdx=function(e){return e<this._count&&e>=0?this._indices[e]:-1},e.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},e.internalField=function(){function e(e,t,n,r){return fO(e[r],this._dimensions[r])}MO={arrayRows:e,objectRows:function(e,t,n,r){return fO(e[t],this._dimensions[r])},keyedColumns:e,original:function(e,t,n,r){var i=e&&(e.value==null?e:e.value);return fO(i instanceof Array?i[r]:i,this._dimensions[r])},typedArray:function(e,t,n,r){return e[r]}}}(),e}(),RO=function(){function e(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return e.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},e.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},e.prototype._getVersionSign=function(){return this._sourceHost.uid+`_`+this._versionSignBase},e.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},e.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,t=this._getUpstreamSourceManagers(),n=!!t.length,r,i;if(zO(e)){var a=e,o=void 0,s=void 0,c=void 0;if(n){var l=t[0];l.prepareSource(),c=l.getSource(),o=c.data,s=c.sourceFormat,i=[l._getVersionSign()]}else o=a.get(`data`,!0),s=up(o)?yE:hE,i=[];var u=this._getSourceMetaRawOption()||{},d=c&&c.metaRawOption||{},f=Z(u.seriesLayoutBy,d.seriesLayoutBy)||null,p=Z(u.sourceHeader,d.sourceHeader),m=Z(u.dimensions,d.dimensions);r=f!==d.seriesLayoutBy||!!p!=!!d.sourceHeader||m?[PD(o,{seriesLayoutBy:f,sourceHeader:p,dimensions:m},s)]:[]}else{var h=e;if(n){var g=this._applyTransform(t);r=g.sourceList,i=g.upstreamSignList}else r=[PD(h.get(`source`,!0),this._getSourceMetaRawOption(),null)],i=[]}this._setLocalSource(r,i)},e.prototype._applyTransform=function(e){var t=this._sourceHost,n=t.get(`transform`,!0),r=t.get(`fromTransformResult`,!0);r!=null&&e.length!==1&&BO(``);var i,a=[],o=[];return q(e,function(e){e.prepareSource();var t=e.getSource(r||0);r!=null&&!t&&BO(``),a.push(t),o.push(e._getVersionSign())}),n?i=CO(n,a,{datasetIndex:t.componentIndex}):r!=null&&(i=[ID(a[0])]),{sourceList:i,upstreamSignList:o}},e.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),t=0;t<e.length;t++){var n=e[t];if(n._isDirty()||this._upstreamSignList[t]!==n._getVersionSign())return!0}},e.prototype.getSource=function(e){e||=0;var t=this._sourceList[e];if(!t){var n=this._getUpstreamSourceManagers();return n[0]&&n[0].getSource(e)}return t},e.prototype.getSharedDataStore=function(e){var t=e.makeStoreSchema();return this._innerGetDataStore(t.dimensions,e.source,t.hash)},e.prototype._innerGetDataStore=function(e,t,n){var r=0,i=this._storeList,a=i[r];a||=i[r]={};var o=a[n];if(!o){var s=this._getUpstreamSourceManagers()[0];zO(this._sourceHost)&&s?o=s._innerGetDataStore(e,t,n):(o=new LO,o.initData(new JD(t,e.length),e)),a[n]=o}return o},e.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if(zO(e)){var t=EE(e);return t?[t.getSourceManager()]:[]}return $f(DE(e),function(e){return e.getSourceManager()})},e.prototype._getSourceMetaRawOption=function(){var e=this._sourceHost,t,n,r;if(zO(e))t=e.get(`seriesLayoutBy`,!0),n=e.get(`sourceHeader`,!0),r=e.get(`dimensions`,!0);else if(!this._getUpstreamSourceManagers().length){var i=e;t=i.get(`seriesLayoutBy`,!0),n=i.get(`sourceHeader`,!0),r=i.get(`dimensions`,!0)}return{seriesLayoutBy:t,sourceHeader:n,dimensions:r}},e}();function zO(e){return e.mainType===`series`}function BO(e){throw Error(e)}var VO=`line-height:1`;function HO(e){var t=e.lineHeight;return t==null?VO:`line-height:`+pm(t+``)+`px`}function UO(e,t){var n=e.color||`#6e7079`,r=e.fontSize||12,i=e.fontWeight||`400`,a=e.color||`#464646`,o=e.fontSize||14,s=e.fontWeight||`900`;return t===`html`?{nameStyle:`font-size:`+pm(r+``)+`px;color:`+pm(n)+`;font-weight:`+pm(i+``),valueStyle:`font-size:`+pm(o+``)+`px;color:`+pm(a)+`;font-weight:`+pm(s+``)}:{nameStyle:{fontSize:r,fill:n,fontWeight:i},valueStyle:{fontSize:o,fill:a,fontWeight:s}}}var WO=[0,10,20,30],GO=[``,`
|
|
11
|
+
`,`
|
|
12
|
+
|
|
13
|
+
`,`
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
`];function KO(e,t){return t.type=e,t}function qO(e){return e.type===`section`}function JO(e){return qO(e)?XO:ZO}function YO(e){if(qO(e)){var t=0,n=e.blocks.length,r=n>1||n>0&&!e.noHeader;return q(e.blocks,function(e){var n=YO(e);n>=t&&(t=n+ +(r&&(!n||qO(e)&&!e.noHeader)))}),t}return 0}function XO(e,t,n,r){var i=t.noHeader,a=$O(YO(t)),o=[],s=t.blocks||[];yp(!s||J(s)),s||=[];var c=e.orderMode;if(t.sortBlocks&&c){s=s.slice();var l={valueAsc:`asc`,valueDesc:`desc`};if(jp(l,c)){var u=new mO(l[c],null);s.sort(function(e,t){return u.evaluate(e.sortParam,t.sortParam)})}else c===`seriesDesc`&&s.reverse()}q(s,function(n,i){var s=t.valueFormatter,c=JO(n)(s?K(K({},e),{valueFormatter:s}):e,n,i>0?a.html:0,r);c!=null&&o.push(c)});var d=e.renderMode===`richText`?o.join(a.richText):ek(r,o.join(``),i?n:a.html);if(i)return d;var f=UT(t.header,`ordinal`,e.useUTC),p=UO(r,e.renderMode).nameStyle,m=HO(r);return e.renderMode===`richText`?rk(e,f,p)+a.richText+d:ek(r,`<div style="`+p+`;`+m+`;">`+pm(f)+`</div>`+d,n)}function ZO(e,t,n,r){var i=e.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,c=t.name,l=e.useUTC,u=t.valueFormatter||e.valueFormatter||function(e){return e=J(e)?e:[e],$f(e,function(e,t){return UT(e,J(p)?p[t]:p,l)})};if(!(a&&o)){var d=s?``:e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||`#333`,i),f=a?``:UT(c,`ordinal`,l),p=t.valueType,m=o?[]:u(t.value,t.dataIndex),h=!s||!a,g=!s&&a,_=UO(r,i),v=_.nameStyle,y=_.valueStyle;return i===`richText`?(s?``:d)+(a?``:rk(e,f,v))+(o?``:ik(e,m,h,g,y)):ek(r,(s?``:d)+(a?``:tk(f,!s,v))+(o?``:nk(m,h,g,y)),n)}}function QO(e,t,n,r,i,a){if(e)return JO(e)({useUTC:i,renderMode:n,orderMode:r,markupStyleCreator:t,valueFormatter:e.valueFormatter},e,0,a)}function $O(e){return{html:WO[e],richText:GO[e]}}function ek(e,t,n){var r=`<div style="clear:both"></div>`,i=`margin: `+n+`px 0 0`,a=HO(e);return`<div style="`+i+`;`+a+`;">`+t+r+`</div>`}function tk(e,t,n){var r=t?`margin-left:2px`:``;return`<span style="`+n+`;`+r+`">`+pm(e)+`</span>`}function nk(e,t,n,r){var i=t?`float:right;margin-left:`+(n?`10px`:`20px`):``;return e=J(e)?e:[e],`<span style="`+i+`;`+r+`">`+$f(e,function(e){return pm(e)}).join(` `)+`</span>`}function rk(e,t,n){return e.markupStyleCreator.wrapRichTextStyle(t,n)}function ik(e,t,n,r,i){var a=[i],o=r?10:20;return n&&a.push({padding:[0,0,0,o],align:`right`}),e.markupStyleCreator.wrapRichTextStyle(J(t)?t.join(` `):t,a)}function ak(e,t){var n=e.getData().getItemVisual(t,`style`)[e.visualDrawType];return JT(n)}function ok(e,t){return e.get(`padding`)??(t===`richText`?[8,10]:10)}var sk=function(){function e(){this.richTextStyles={},this._nextStyleNameId=bv()}return e.prototype._generateStyleName=function(){return`__EC_aUTo_`+this._nextStyleNameId++},e.prototype.makeTooltipMarker=function(e,t,n){var r=n===`richText`?this._generateStyleName():null,i=qT({color:t,type:e,renderMode:n,markerId:r});return Y(i)?i:(this.richTextStyles[r]=i.style,i.content)},e.prototype.wrapRichTextStyle=function(e,t){var n={};J(t)?q(t,function(e){return K(n,e)}):K(n,t);var r=this._generateStyleName();return this.richTextStyles[r]=n,`{`+r+`|`+e+`}`},e}();function ck(e){var t=e.series,n=e.dataIndex,r=e.multipleSeries,i=t.getData(),a=i.mapDimensionsAll(`defaultedTooltip`),o=a.length,s=t.getRawValue(n),c=J(s),l=ak(t,n),u,d,f,p;if(o>1||c&&!o){var m=lk(s,t,n,a,l);u=m.inlineValues,d=m.inlineValueTypes,f=m.blocks,p=m.inlineValues[0]}else if(o){var h=i.getDimensionInfo(a[0]);p=u=aO(i,n,a[0]),d=h.type}else p=u=c?s[0]:s;var g=Vv(t),_=g&&t.name||``,v=i.getName(n),y=r?_:v;return KO(`section`,{header:_,noHeader:r||!g,sortParam:p,blocks:[KO(`nameValue`,{markerType:`item`,markerColor:l,name:y,noName:!bp(y),value:u,valueType:d,dataIndex:n})].concat(f||[])})}function lk(e,t,n,r,i){var a=t.getData(),o=ep(e,function(e,t,n){var r=a.getDimensionInfo(n);return e||=r&&r.tooltip!==!1&&r.displayName!=null},!1),s=[],c=[],l=[];r.length?q(r,function(e){u(aO(a,n,e),e)}):q(e,u);function u(e,t){var n=a.getDimensionInfo(t);n&&n.otherDims.tooltip!==!1&&(o?l.push(KO(`nameValue`,{markerType:`subItem`,markerColor:i,name:n.displayName,value:e,valueType:n.type})):(s.push(e),c.push(n.type)))}return{inlineValues:s,inlineValueTypes:c,blocks:l}}var uk=Kv();function dk(e,t){return e.getName(t)||e.getId(t)}var fk=function(e){U(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return t.prototype.init=function(e,t,n){this.seriesIndex=this.componentIndex,this.dataTask=lO({count:hk,reset:gk}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(e,n),(uk(this).sourceManager=new RO(this)).prepareSource();var r=this.getInitialData(e,n);vk(r,this),this.dataTask.context.data=r,uk(this).dataBeforeProcessed=r,pk(this),this._initSelectedMapFromData(r)},t.prototype.mergeDefaultAndTheme=function(e,t){var n=iE(this),r=n?oE(e):{},i=this.subType;lE.hasClass(i)&&(i+=`Series`),qf(e,t.getTheme().get(this.subType)),qf(e,this.getDefaultOption()),Dv(e,`label`,[`show`]),this.fillDataTextStyle(e.data),n&&aE(e,r,n)},t.prototype.mergeOption=function(e,t){e=qf(this.option,e,!0),this.fillDataTextStyle(e.data);var n=iE(this);n&&aE(this.option,e,n);var r=uk(this).sourceManager;r.dirty(),r.prepareSource();var i=this.getInitialData(e,t);vk(i,this),this.dataTask.dirty(),this.dataTask.context.data=i,uk(this).dataBeforeProcessed=i,pk(this),this._initSelectedMapFromData(i)},t.prototype.fillDataTextStyle=function(e){if(e&&!up(e))for(var t=[`show`],n=0;n<e.length;n++)e[n]&&e[n].label&&Dv(e[n],`label`,t)},t.prototype.getInitialData=function(e,t){},t.prototype.appendData=function(e){this.getRawData().appendData(e.data)},t.prototype.getData=function(e){var t=bk(this);if(t){var n=t.context.data;return e==null||!n.getLinkedData?n:n.getLinkedData(e)}return uk(this).data},t.prototype.getAllData=function(){var e=this.getData();return e&&e.getLinkedDataAll?e.getLinkedDataAll():[{data:e}]},t.prototype.setData=function(e){var t=bk(this);if(t){var n=t.context;n.outputData=e,t!==this.dataTask&&(n.data=e)}uk(this).data=e},t.prototype.getEncode=function(){var e=this.get(`encode`,!0);if(e)return Q(e)},t.prototype.getSourceManager=function(){return uk(this).sourceManager},t.prototype.getSource=function(){return this.getSourceManager().getSource()},t.prototype.getRawData=function(){return uk(this).dataBeforeProcessed},t.prototype.getColorBy=function(){return this.get(`colorBy`)||`series`},t.prototype.isColorBySeries=function(){return this.getColorBy()===`series`},t.prototype.getBaseAxis=function(){var e=this.coordinateSystem;return e&&e.getBaseAxis&&e.getBaseAxis()},t.prototype.formatTooltip=function(e,t,n){return ck({series:this,dataIndex:e,multipleSeries:t})},t.prototype.isAnimationEnabled=function(){var e=this.ecModel;if(W.node&&!(e&&e.ssr))return!1;var t=this.getShallow(`animation`);return t&&this.getData().count()>this.getShallow(`animationThreshold`)&&(t=!1),!!t},t.prototype.restoreData=function(){this.dataTask.dirty()},t.prototype.getColorFromPalette=function(e,t,n){var r=this.ecModel,i=PE.prototype.getColorFromPalette.call(this,e,t,n);return i||=r.getColorFromPalette(e,t,n),i},t.prototype.coordDimToDataDim=function(e){return this.getRawData().mapDimensionsAll(e)},t.prototype.getProgressive=function(){return this.get(`progressive`)},t.prototype.getProgressiveThreshold=function(){return this.get(`progressiveThreshold`)},t.prototype.select=function(e,t){this._innerSelect(this.getData(t),e)},t.prototype.unselect=function(e,t){var n=this.option.selectedMap;if(n){var r=this.option.selectedMode,i=this.getData(t);if(r===`series`||n===`all`)this.option.selectedMap={},this._selectedDataIndicesMap={};else for(var a=0;a<e.length;a++){var o=e[a],s=dk(i,o);n[s]=!1,this._selectedDataIndicesMap[s]=-1}}},t.prototype.toggleSelect=function(e,t){for(var n=[],r=0;r<e.length;r++)n[0]=e[r],this.isSelected(e[r],t)?this.unselect(n,t):this.select(n,t)},t.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap===`all`)return[].slice.call(this.getData().getIndices());for(var e=this._selectedDataIndicesMap,t=np(e),n=[],r=0;r<t.length;r++){var i=e[t[r]];i>=0&&n.push(i)}return n},t.prototype.isSelected=function(e,t){var n=this.option.selectedMap;if(!n)return!1;var r=this.getData(t);return(n===`all`||n[dk(r,e)])&&!r.getItemModel(e).get([`select`,`disabled`])},t.prototype.isUniversalTransitionEnabled=function(){if(this.__universalTransitionEnabled)return!0;var e=this.option.universalTransition;return e?e===!0||e&&e.enabled:!1},t.prototype._innerSelect=function(e,t){var n,r,i=this.option,a=i.selectedMode,o=t.length;if(a&&o){if(a===`series`)i.selectedMap=`all`;else if(a===`multiple`){X(i.selectedMap)||(i.selectedMap={});for(var s=i.selectedMap,c=0;c<o;c++){var l=t[c],u=dk(e,l);s[u]=!0,this._selectedDataIndicesMap[u]=e.getRawIndex(l)}}else if(a===`single`||a===!0){var d=t[o-1],u=dk(e,d);i.selectedMap=(n={},n[u]=!0,n),this._selectedDataIndicesMap=(r={},r[u]=e.getRawIndex(d),r)}}},t.prototype._initSelectedMapFromData=function(e){if(!this.option.selectedMap){var t=[];e.hasItemOption&&e.each(function(n){var r=e.getRawDataItem(n);r&&r.selected&&t.push(n)}),t.length>0&&this._innerSelect(e,t)}},t.registerClass=function(e){return lE.registerClass(e)},t.protoInitialize=function(){var e=t.prototype;e.type=`series.__base__`,e.seriesIndex=0,e.ignoreStyleOnData=!1,e.hasSymbolVisual=!1,e.defaultSymbol=`circle`,e.visualStyleAccessPath=`itemStyle`,e.visualDrawType=`fill`}(),t}(lE);Zf(fk,sO),Zf(fk,PE),ly(fk,lE);function pk(e){var t=e.name;Vv(e)||(e.name=mk(e)||t)}function mk(e){var t=e.getRawData(),n=t.mapDimensionsAll(`seriesName`),r=[];return q(n,function(e){var n=t.getDimensionInfo(e);n.displayName&&r.push(n.displayName)}),r.join(` `)}function hk(e){return e.model.getRawData().count()}function gk(e){var t=e.model;return t.setData(t.getRawData().cloneShallow()),_k}function _k(e,t){t.outputData&&e.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function vk(e,t){q(Op(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(n){e.wrapMethod(n,ap(yk,t))})}function yk(e,t){var n=bk(e);return n&&n.setOutputEnd((t||this).count()),t}function bk(e){var t=(e.ecModel||{}).scheduler,n=t&&t.getPipeline(e.uid);if(n){var r=n.currentTask;if(r){var i=r.agentStubMap;i&&(r=i.get(e.uid))}return r}}var xk=function(){function e(){this.group=new Z_,this.uid=pT(`viewComponent`)}return e.prototype.init=function(e,t){},e.prototype.render=function(e,t,n,r){},e.prototype.dispose=function(e,t){},e.prototype.updateView=function(e,t,n,r){},e.prototype.updateLayout=function(e,t,n,r){},e.prototype.updateVisual=function(e,t,n,r){},e.prototype.toggleBlurSeries=function(e,t,n){},e.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},e}();sy(xk),my(xk);function Sk(){var e=Kv();return function(t){var n=e(t),r=t.pipelineContext,i=!!n.large,a=!!n.progressiveRender,o=n.large=!!(r&&r.large),s=n.progressiveRender=!!(r&&r.progressiveRender);return(i!==o||a!==s)&&`reset`}}var Ck=Kv(),wk=Sk(),Tk=function(){function e(){this.group=new Z_,this.uid=pT(`viewChart`),this.renderTask=lO({plan:Ok,reset:kk}),this.renderTask.context={view:this}}return e.prototype.init=function(e,t){},e.prototype.render=function(e,t,n,r){},e.prototype.highlight=function(e,t,n,r){var i=e.getData(r&&r.dataType);i&&Dk(i,r,`emphasis`)},e.prototype.downplay=function(e,t,n,r){var i=e.getData(r&&r.dataType);i&&Dk(i,r,`normal`)},e.prototype.remove=function(e,t){this.group.removeAll()},e.prototype.dispose=function(e,t){},e.prototype.updateView=function(e,t,n,r){this.render(e,t,n,r)},e.prototype.updateLayout=function(e,t,n,r){this.render(e,t,n,r)},e.prototype.updateVisual=function(e,t,n,r){this.render(e,t,n,r)},e.prototype.eachRendered=function(e){zw(this.group,e)},e.markUpdateMethod=function(e,t){Ck(e).updateMethod=t},e.protoInitialize=function(){var t=e.prototype;t.type=`chart`}(),e}();function Ek(e,t,n){e&&kS(e)&&(t===`emphasis`?sS:cS)(e,n)}function Dk(e,t,n){var r=Gv(e,t),i=t&&t.highlightKey!=null?AS(t.highlightKey):null;r==null?e.eachItemGraphicEl(function(e){Ek(e,n,i)}):q(Ev(r),function(t){Ek(e.getItemGraphicEl(t),n,i)})}sy(Tk,[`dispose`]),my(Tk);function Ok(e){return wk(e.model)}function kk(e){var t=e.model,n=e.ecModel,r=e.api,i=e.payload,a=t.pipelineContext.progressiveRender,o=e.view,s=i&&Ck(i).updateMethod,c=a?`incrementalPrepareRender`:s&&o[s]?s:`render`;return c!==`render`&&o[c](t,n,r,i),Ak[c]}var Ak={incrementalPrepareRender:{progress:function(e,t){t.view.incrementalRender(e,t.model,t.ecModel,t.api,t.payload)}},render:{forceFirstProgress:!0,progress:function(e,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}},jk=`\0__throttleOriginMethod`,Mk=`\0__throttleRate`,Nk=`\0__throttleType`;function Pk(e,t,n){var r,i=0,a=0,o=null,s,c,l,u;t||=0;function d(){a=new Date().getTime(),o=null,e.apply(c,l||[])}var f=function(){var e=[...arguments];r=new Date().getTime(),c=this,l=e;var f=u||t,p=u||n;u=null,s=r-(p?i:a)-f,clearTimeout(o),p?o=setTimeout(d,f):s>=0?d():o=setTimeout(d,-s),i=r};return f.clear=function(){o&&=(clearTimeout(o),null)},f.debounceNextCall=function(e){u=e},f}function Fk(e,t,n,r){var i=e[t];if(i){var a=i[jk]||i,o=i[Nk];if(i[Mk]!==n||o!==r){if(n==null||!r)return e[t]=a;i=e[t]=Pk(a,n,r===`debounce`),i[jk]=a,i[Nk]=r,i[Mk]=n}return i}}function Ik(e,t){var n=e[t];n&&n[jk]&&(n.clear&&n.clear(),e[t]=n[jk])}var Lk=Kv(),Rk={itemStyle:hy(cT,!0),lineStyle:hy(aT,!0)},zk={lineStyle:`stroke`,itemStyle:`fill`};function Bk(e,t){return e.visualStyleMapper||Rk[t]||(console.warn(`Unknown style type '`+t+`'.`),Rk.itemStyle)}function Vk(e,t){return e.visualDrawType||zk[t]||(console.warn(`Unknown style type '`+t+`'.`),`fill`)}var Hk={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData(),r=e.visualStyleAccessPath||`itemStyle`,i=e.getModel(r),a=Bk(e,r)(i),o=i.getShallow(`decal`);o&&(n.setVisual(`decal`,o),o.dirty=!0);var s=Vk(e,r),c=a[s],l=op(c)?c:null,u=a.fill===`auto`||a.stroke===`auto`;if(!a[s]||l||u){var d=e.getColorFromPalette(e.name,null,t.getSeriesCount());a[s]||(a[s]=d,n.setVisual(`colorFromPalette`,!0)),a.fill=a.fill===`auto`||op(a.fill)?d:a.fill,a.stroke=a.stroke===`auto`||op(a.stroke)?d:a.stroke}if(n.setVisual(`style`,a),n.setVisual(`drawType`,s),!t.isSeriesFiltered(e)&&l)return n.setVisual(`colorFromPalette`,!1),{dataEach:function(t,n){var r=e.getDataParams(n),i=K({},a);i[s]=l(r),t.setItemVisual(n,`style`,i)}}}},Uk=new dT,Wk={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){if(!(e.ignoreStyleOnData||t.isSeriesFiltered(e))){var n=e.getData(),r=e.visualStyleAccessPath||`itemStyle`,i=Bk(e,r),a=n.getVisual(`drawType`);return{dataEach:n.hasItemOption?function(e,t){var n=e.getRawDataItem(t);if(n&&n[r]){Uk.option=n[r];var o=i(Uk);K(e.ensureUniqueItemVisual(t,`style`),o),Uk.option.decal&&(e.setItemVisual(t,`decal`,Uk.option.decal),Uk.option.decal.dirty=!0),a in o&&e.setItemVisual(t,`colorFromPalette`,!1)}}:null}}}},Gk={performRawSeries:!0,overallReset:function(e){var t=Q();e.eachSeries(function(e){var n=e.getColorBy();if(!e.isColorBySeries()){var r=e.type+`-`+n,i=t.get(r);i||(i={},t.set(r,i)),Lk(e).scope=i}}),e.eachSeries(function(t){if(!(t.isColorBySeries()||e.isSeriesFiltered(t))){var n=t.getRawData(),r={},i=t.getData(),a=Lk(t).scope,o=Vk(t,t.visualStyleAccessPath||`itemStyle`);i.each(function(e){var t=i.getRawIndex(e);r[t]=e}),n.each(function(e){var s=r[e];if(i.getItemVisual(s,`colorFromPalette`)){var c=i.ensureUniqueItemVisual(s,`style`),l=n.getName(e)||e+``,u=n.count();c[o]=t.getColorFromPalette(l,a,u)}})}})}},Kk=Math.PI;function qk(e,t){t||={},Jf(t,{text:`loading`,textColor:`#000`,fontSize:12,fontWeight:`normal`,fontStyle:`normal`,fontFamily:`sans-serif`,maskColor:`rgba(255, 255, 255, 0.8)`,showSpinner:!0,color:`#5470c6`,spinnerRadius:10,lineWidth:5,zlevel:0});var n=new Z_,r=new dx({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});n.add(r);var i=new hx({style:{text:t.text,fill:t.textColor,fontSize:t.fontSize,fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:t.fontFamily},zlevel:t.zlevel,z:10001}),a=new dx({style:{fill:`none`},textContent:i,textConfig:{position:`right`,distance:10},zlevel:t.zlevel,z:10001});n.add(a);var o;return t.showSpinner&&(o=new zC({shape:{startAngle:-Kk/2,endAngle:-Kk/2+.1,r:t.spinnerRadius},style:{stroke:t.color,lineCap:`round`,lineWidth:t.lineWidth},zlevel:t.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:Kk*3/2}).start(`circularInOut`),o.animateShape(!0).when(1e3,{startAngle:Kk*3/2}).delay(300).start(`circularInOut`),n.add(o)),n.resize=function(){var n=i.getBoundingRect().width,s=t.showSpinner?t.spinnerRadius:0,c=(e.getWidth()-s*2-(t.showSpinner&&n?10:0)-n)/2-(t.showSpinner&&n?0:5+n/2)+(t.showSpinner?0:n/2)+(n?0:s),l=e.getHeight()/2;t.showSpinner&&o.setShape({cx:c,cy:l}),a.setShape({x:c-s,y:l-s,width:s*2,height:s*2}),r.setShape({x:0,y:0,width:e.getWidth(),height:e.getHeight()})},n.resize(),n}var Jk=function(){function e(e,t,n,r){this._stageTaskMap=Q(),this.ecInstance=e,this.api=t,n=this._dataProcessorHandlers=n.slice(),r=this._visualHandlers=r.slice(),this._allHandlers=n.concat(r)}return e.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(e){var t=e.overallTask;t&&t.dirty()})},e.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var n=this._pipelineMap.get(e.__pipeline.id),r=n.context,i=!t&&n.progressiveEnabled&&(!r||r.progressiveRender)&&e.__idxInPipeline>n.blockIndex?n.step:null,a=r&&r.modDataCount;return{step:i,modBy:a==null?null:Math.ceil(a/i),modDataCount:a}}},e.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},e.prototype.updateStreamModes=function(e,t){var n=this._pipelineMap.get(e.uid),r=e.getData().count(),i=n.progressiveEnabled&&t.incrementalPrepareRender&&r>=n.threshold,a=e.get(`large`)&&r>=e.get(`largeThreshold`);e.pipelineContext=n.context={progressiveRender:i,modDataCount:e.get(`progressiveChunkMode`)===`mod`?r:null,large:a}},e.prototype.restorePipelines=function(e){var t=this,n=t._pipelineMap=Q();e.eachSeries(function(e){var r=e.getProgressive(),i=e.uid;n.set(i,{id:i,head:null,tail:null,threshold:e.getProgressiveThreshold(),progressiveEnabled:r&&!(e.preventIncremental&&e.preventIncremental()),blockIndex:-1,step:Math.round(r||700),count:0}),t._pipe(e,e.dataTask)})},e.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),n=this.api;q(this._allHandlers,function(r){var i=e.get(r.uid)||e.set(r.uid,{});yp(!(r.reset&&r.overallReset),``),r.reset&&this._createSeriesStageTask(r,i,t,n),r.overallReset&&this._createOverallStageTask(r,i,t,n)},this)},e.prototype.prepareView=function(e,t,n,r){var i=e.renderTask,a=i.context;a.model=t,a.ecModel=n,a.api=r,i.__block=!e.incrementalPrepareRender,this._pipe(t,i)},e.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},e.prototype.performVisualTasks=function(e,t,n){this._performStageTasks(this._visualHandlers,e,t,n)},e.prototype._performStageTasks=function(e,t,n,r){r||={};var i=!1,a=this;q(e,function(e,s){if(!(r.visualType&&r.visualType!==e.visualType)){var c=a._stageTaskMap.get(e.uid),l=c.seriesTaskMap,u=c.overallTask;if(u){var d,f=u.agentStubMap;f.each(function(e){o(r,e)&&(e.dirty(),d=!0)}),d&&u.dirty(),a.updatePayload(u,n);var p=a.getPerformArgs(u,r.block);f.each(function(e){e.perform(p)}),u.perform(p)&&(i=!0)}else l&&l.each(function(s,c){o(r,s)&&s.dirty();var l=a.getPerformArgs(s,r.block);l.skip=!e.performRawSeries&&t.isSeriesFiltered(s.context.model),a.updatePayload(s,n),s.perform(l)&&(i=!0)})}});function o(e,t){return e.setDirty&&(!e.dirtyMap||e.dirtyMap.get(t.__pipeline.id))}this.unfinished=i||this.unfinished},e.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(e){t=e.dataTask.perform()||t}),this.unfinished=t||this.unfinished},e.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},e.prototype.updatePayload=function(e,t){t!==`remain`&&(e.context.payload=t)},e.prototype._createSeriesStageTask=function(e,t,n,r){var i=this,a=t.seriesTaskMap,o=t.seriesTaskMap=Q(),s=e.seriesType,c=e.getTargetSeries;e.createOnAllSeries?n.eachRawSeries(l):s?n.eachRawSeriesByType(s,l):c&&c(n,r).each(l);function l(t){var s=t.uid,c=o.set(s,a&&a.get(s)||lO({plan:$k,reset:eA,count:rA}));c.context={model:t,ecModel:n,api:r,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:i},i._pipe(t,c)}},e.prototype._createOverallStageTask=function(e,t,n,r){var i=this,a=t.overallTask=t.overallTask||lO({reset:Yk});a.context={ecModel:n,api:r,overallReset:e.overallReset,scheduler:i};var o=a.agentStubMap,s=a.agentStubMap=Q(),c=e.seriesType,l=e.getTargetSeries,u=!0,d=!1;yp(!e.createOnAllSeries,``),c?n.eachRawSeriesByType(c,f):l?l(n,r).each(f):(u=!1,q(n.getSeries(),f));function f(e){var t=e.uid,n=s.set(t,o&&o.get(t)||(d=!0,lO({reset:Xk,onDirty:Qk})));n.context={model:e,overallProgress:u},n.agent=a,n.__block=u,i._pipe(e,n)}d&&a.dirty()},e.prototype._pipe=function(e,t){var n=e.uid,r=this._pipelineMap.get(n);!r.head&&(r.head=t),r.tail&&r.tail.pipe(t),r.tail=t,t.__idxInPipeline=r.count++,t.__pipeline=r},e.wrapStageHandler=function(e,t){return op(e)&&(e={overallReset:e,seriesType:iA(e)}),e.uid=pT(`stageHandler`),t&&(e.visualType=t),e},e}();function Yk(e){e.overallReset(e.ecModel,e.api,e.payload)}function Xk(e){return e.overallProgress&&Zk}function Zk(){this.agent.dirty(),this.getDownstream().dirty()}function Qk(){this.agent&&this.agent.dirty()}function $k(e){return e.plan?e.plan(e.model,e.ecModel,e.api,e.payload):null}function eA(e){e.useClearVisual&&e.data.clearAllVisual();var t=e.resetDefines=Ev(e.reset(e.model,e.ecModel,e.api,e.payload));return t.length>1?$f(t,function(e,t){return nA(t)}):tA}var tA=nA(0);function nA(e){return function(t,n){var r=n.data,i=n.resetDefines[e];if(i&&i.dataEach)for(var a=t.start;a<t.end;a++)i.dataEach(r,a);else i&&i.progress&&i.progress(t,r)}}function rA(e){return e.data.count()}function iA(e){sA=null;try{e(aA,oA)}catch{}return sA}var aA={},oA={},sA;cA(aA,WE),cA(oA,ZE),aA.eachSeriesByType=aA.eachRawSeriesByType=function(e){sA=e},aA.eachComponent=function(e){e.mainType===`series`&&e.subType&&(sA=e.subType)};function cA(e,t){for(var n in t.prototype)e[n]=Mp}var lA=[`#37A2DA`,`#32C5E9`,`#67E0E3`,`#9FE6B8`,`#FFDB5C`,`#ff9f7f`,`#fb7293`,`#E062AE`,`#E690D1`,`#e7bcf3`,`#9d96f5`,`#8378EA`,`#96BFFF`],uA={color:lA,colorLayer:[[`#37A2DA`,`#ffd85c`,`#fd7b5f`],[`#37A2DA`,`#67E0E3`,`#FFDB5C`,`#ff9f7f`,`#E062AE`,`#9d96f5`],[`#37A2DA`,`#32C5E9`,`#9FE6B8`,`#FFDB5C`,`#ff9f7f`,`#fb7293`,`#e7bcf3`,`#8378EA`,`#96BFFF`],lA]},dA=`#B9B8CE`,fA=`#100C2A`,pA=function(){return{axisLine:{lineStyle:{color:dA}},splitLine:{lineStyle:{color:`#484753`}},splitArea:{areaStyle:{color:[`rgba(255,255,255,0.02)`,`rgba(255,255,255,0.05)`]}},minorSplitLine:{lineStyle:{color:`#20203B`}}}},mA=[`#4992ff`,`#7cffb2`,`#fddd60`,`#ff6e76`,`#58d9f9`,`#05c091`,`#ff8a45`,`#8d48e3`,`#dd79ff`],hA={darkMode:!0,color:mA,backgroundColor:fA,axisPointer:{lineStyle:{color:`#817f91`},crossStyle:{color:`#817f91`},label:{color:`#fff`}},legend:{textStyle:{color:dA},pageTextStyle:{color:dA}},textStyle:{color:dA},title:{textStyle:{color:`#EEF1FA`},subtextStyle:{color:`#B9B8CE`}},toolbox:{iconStyle:{borderColor:dA}},dataZoom:{borderColor:`#71708A`,textStyle:{color:dA},brushStyle:{color:`rgba(135,163,206,0.3)`},handleStyle:{color:`#353450`,borderColor:`#C5CBE3`},moveHandleStyle:{color:`#B0B6C3`,opacity:.3},fillerColor:`rgba(135,163,206,0.2)`,emphasis:{handleStyle:{borderColor:`#91B7F2`,color:`#4D587D`},moveHandleStyle:{color:`#636D9A`,opacity:.7}},dataBackground:{lineStyle:{color:`#71708A`,width:1},areaStyle:{color:`#71708A`}},selectedDataBackground:{lineStyle:{color:`#87A3CE`},areaStyle:{color:`#87A3CE`}}},visualMap:{textStyle:{color:dA}},timeline:{lineStyle:{color:dA},label:{color:dA},controlStyle:{color:dA,borderColor:dA}},calendar:{itemStyle:{color:fA},dayLabel:{color:dA},monthLabel:{color:dA},yearLabel:{color:dA}},timeAxis:pA(),logAxis:pA(),valueAxis:pA(),categoryAxis:pA(),line:{symbol:`circle`},graph:{color:mA},gauge:{title:{color:dA},axisLine:{lineStyle:{color:[[1,`rgba(207,212,219,0.2)`]]}},axisLabel:{color:dA},detail:{color:`#EEF1FA`}},candlestick:{itemStyle:{color:`#f64e56`,color0:`#54ea92`,borderColor:`#f64e56`,borderColor0:`#54ea92`}}};hA.categoryAxis.splitLine.show=!1;var gA=function(){function e(){}return e.prototype.normalizeQuery=function(e){var t={},n={},r={};if(Y(e)){var i=iy(e);t.mainType=i.main||null,t.subType=i.sub||null}else{var a=[`Index`,`Name`,`Id`],o={name:1,dataIndex:1,dataType:1};q(e,function(e,i){for(var s=!1,c=0;c<a.length;c++){var l=a[c],u=i.lastIndexOf(l);if(u>0&&u===i.length-l.length){var d=i.slice(0,u);d!==`data`&&(t.mainType=d,t[l.toLowerCase()]=e,s=!0)}}o.hasOwnProperty(i)&&(n[i]=e,s=!0),s||(r[i]=e)})}return{cptQuery:t,dataQuery:n,otherQuery:r}},e.prototype.filter=function(e,t){var n=this.eventInfo;if(!n)return!0;var r=n.targetEl,i=n.packedEvent,a=n.model,o=n.view;if(!a||!o)return!0;var s=t.cptQuery,c=t.dataQuery;return l(s,a,`mainType`)&&l(s,a,`subType`)&&l(s,a,`index`,`componentIndex`)&&l(s,a,`name`)&&l(s,a,`id`)&&l(c,i,`name`)&&l(c,i,`dataIndex`)&&l(c,i,`dataType`)&&(!o.filterForExposedEvent||o.filterForExposedEvent(e,t.otherQuery,r,i));function l(e,t,n,r){return e[n]==null||t[r||n]===e[n]}},e.prototype.afterTrigger=function(){this.eventInfo=null},e}(),_A=[`symbol`,`symbolSize`,`symbolRotate`,`symbolOffset`],vA=_A.concat([`symbolKeepAspect`]),yA={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData();if(e.legendIcon&&n.setVisual(`legendIcon`,e.legendIcon),!e.hasSymbolVisual)return;for(var r={},i={},a=!1,o=0;o<_A.length;o++){var s=_A[o],c=e.get(s);op(c)?(a=!0,i[s]=c):r[s]=c}if(r.symbol=r.symbol||e.defaultSymbol,n.setVisual(K({legendIcon:e.legendIcon||r.symbol,symbolKeepAspect:e.get(`symbolKeepAspect`)},r)),t.isSeriesFiltered(e))return;var l=np(i);function u(t,n){for(var r=e.getRawValue(n),a=e.getDataParams(n),o=0;o<l.length;o++){var s=l[o];t.setItemVisual(n,s,i[s](r,a))}}return{dataEach:a?u:null}}},bA={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){if(!e.hasSymbolVisual||t.isSeriesFiltered(e))return;var n=e.getData();function r(e,t){for(var n=e.getItemModel(t),r=0;r<vA.length;r++){var i=vA[r],a=n.getShallow(i,!0);a!=null&&e.setItemVisual(t,i,a)}}return{dataEach:n.hasItemOption?r:null}}};function xA(e,t,n){switch(n){case`color`:return e.getItemVisual(t,`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getItemVisual(t,`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getItemVisual(t,n)}}function SA(e,t){switch(t){case`color`:return e.getVisual(`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getVisual(`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getVisual(t)}}function CA(e,t,n,r,i){var a=e+t;n.isSilent(a)||r.eachComponent({mainType:`series`,subType:`pie`},function(e){for(var t=e.seriesIndex,r=e.option.selectedMap,o=i.selected,s=0;s<o.length;s++)if(o[s].seriesIndex===t){var c=e.getData(),l=Gv(c,i.fromActionPayload);n.trigger(a,{type:a,seriesId:e.id,name:J(l)?c.getName(l[0]):c.getName(l),selected:Y(r)?r:K({},r)})}})}function wA(e,t,n){e.on(`selectchanged`,function(e){var r=n.getModel();e.isFromClick?(CA(`map`,`selectchanged`,t,r,e),CA(`pie`,`selectchanged`,t,r,e)):e.fromAction===`select`?(CA(`map`,`selected`,t,r,e),CA(`pie`,`selected`,t,r,e)):e.fromAction===`unselect`&&(CA(`map`,`unselected`,t,r,e),CA(`pie`,`unselected`,t,r,e))})}function TA(e,t,n){for(var r;e&&!(t(e)&&(r=e,n));)e=e.__hostTarget||e.parent;return r}var EA=Math.round(Math.random()*9),DA=typeof Object.defineProperty==`function`,OA=function(){function e(){this._id=`__ec_inner_`+EA++}return e.prototype.get=function(e){return this._guard(e)[this._id]},e.prototype.set=function(e,t){var n=this._guard(e);return DA?Object.defineProperty(n,this._id,{value:t,enumerable:!1,configurable:!0}):n[this._id]=t,this},e.prototype.delete=function(e){return this.has(e)?(delete this._guard(e)[this._id],!0):!1},e.prototype.has=function(e){return!!this._guard(e)[this._id]},e.prototype._guard=function(e){if(e!==Object(e))throw TypeError(`Value of WeakMap is not a non-null object.`);return e},e}(),kA=Zb.extend({type:`triangle`,shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var n=t.cx,r=t.cy,i=t.width/2,a=t.height/2;e.moveTo(n,r-a),e.lineTo(n+i,r+a),e.lineTo(n-i,r+a),e.closePath()}}),AA={line:NC,rect:dx,roundRect:dx,square:dx,circle:rC,diamond:Zb.extend({type:`diamond`,shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var n=t.cx,r=t.cy,i=t.width/2,a=t.height/2;e.moveTo(n,r-a),e.lineTo(n+i,r),e.lineTo(n,r+a),e.lineTo(n-i,r),e.closePath()}}),pin:Zb.extend({type:`pin`,shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var n=t.x,r=t.y,i=t.width/5*3,a=Math.max(i,t.height),o=i/2,s=o*o/(a-o),c=r-a+o+s,l=Math.asin(s/o),u=Math.cos(l)*o,d=Math.sin(l),f=Math.cos(l),p=o*.6,m=o*.7;e.moveTo(n-u,c+s),e.arc(n,c,o,Math.PI-l,Math.PI*2+l),e.bezierCurveTo(n+u-d*p,c+s+f*p,n,r-m,n,r),e.bezierCurveTo(n,r-m,n-u+d*p,c+s+f*p,n-u,c+s),e.closePath()}}),arrow:Zb.extend({type:`arrow`,shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var n=t.height,r=t.width,i=t.x,a=t.y,o=r/3*2;e.moveTo(i,a),e.lineTo(i+o,a+n),e.lineTo(i,a+n/4*3),e.lineTo(i-o,a+n),e.lineTo(i,a),e.closePath()}}),triangle:kA},jA={line:function(e,t,n,r,i){i.x1=e,i.y1=t+r/2,i.x2=e+n,i.y2=t+r/2},rect:function(e,t,n,r,i){i.x=e,i.y=t,i.width=n,i.height=r},roundRect:function(e,t,n,r,i){i.x=e,i.y=t,i.width=n,i.height=r,i.r=Math.min(n,r)/4},square:function(e,t,n,r,i){var a=Math.min(n,r);i.x=e,i.y=t,i.width=a,i.height=a},circle:function(e,t,n,r,i){i.cx=e+n/2,i.cy=t+r/2,i.r=Math.min(n,r)/2},diamond:function(e,t,n,r,i){i.cx=e+n/2,i.cy=t+r/2,i.width=n,i.height=r},pin:function(e,t,n,r,i){i.x=e+n/2,i.y=t+r/2,i.width=n,i.height=r},arrow:function(e,t,n,r,i){i.x=e+n/2,i.y=t+r/2,i.width=n,i.height=r},triangle:function(e,t,n,r,i){i.cx=e+n/2,i.cy=t+r/2,i.width=n,i.height=r}},MA={};q(AA,function(e,t){MA[t]=new e});var NA=Zb.extend({type:`symbol`,shape:{symbolType:``,x:0,y:0,width:0,height:0},calculateTextPosition:function(e,t,n){var r=L_(e,t,n),i=this.shape;return i&&i.symbolType===`pin`&&t.position===`inside`&&(r.y=n.y+n.height*.4),r},buildPath:function(e,t,n){var r=t.symbolType;if(r!==`none`){var i=MA[r];i||=(r=`rect`,MA[r]),jA[r](t.x,t.y,t.width,t.height,i.shape),i.buildPath(e,i.shape,n)}}});function PA(e,t){if(this.type!==`image`){var n=this.style;this.__isEmptyBrush?(n.stroke=e,n.fill=t||`#fff`,n.lineWidth=2):this.shape.symbolType===`line`?n.stroke=e:n.fill=e,this.markRedraw()}}function FA(e,t,n,r,i,a,o){var s=e.indexOf(`empty`)===0;s&&(e=e.substr(5,1).toLowerCase()+e.substr(6));var c=e.indexOf(`image://`)===0?_w(e.slice(8),new $(t,n,r,i),o?`center`:`cover`):e.indexOf(`path://`)===0?gw(e.slice(7),{},new $(t,n,r,i),o?`center`:`cover`):new NA({shape:{symbolType:e,x:t,y:n,width:r,height:i}});return c.__isEmptyBrush=s,c.setColor=PA,a&&c.setColor(a),c}function IA(e){return J(e)||(e=[+e,+e]),[e[0]||0,e[1]||0]}function LA(e,t){if(e!=null)return J(e)||(e=[e,e]),[lv(e[0],t[0])||0,lv(Z(e[1],e[0]),t[1])||0]}function RA(e){return isFinite(e)}function zA(e,t,n){var r=t.x==null?0:t.x,i=t.x2==null?1:t.x2,a=t.y==null?0:t.y,o=t.y2==null?0:t.y2;return t.global||(r=r*n.width+n.x,i=i*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y),r=RA(r)?r:0,i=RA(i)?i:1,a=RA(a)?a:0,o=RA(o)?o:0,e.createLinearGradient(r,a,i,o)}function BA(e,t,n){var r=n.width,i=n.height,a=Math.min(r,i),o=t.x==null?.5:t.x,s=t.y==null?.5:t.y,c=t.r==null?.5:t.r;return t.global||(o=o*r+n.x,s=s*i+n.y,c*=a),o=RA(o)?o:.5,s=RA(s)?s:.5,c=c>=0&&RA(c)?c:.5,e.createRadialGradient(o,s,0,o,s,c)}function VA(e,t,n){for(var r=t.type===`radial`?BA(e,t,n):zA(e,t,n),i=t.colorStops,a=0;a<i.length;a++)r.addColorStop(i[a].offset,i[a].color);return r}function HA(e,t){if(e===t||!e&&!t)return!1;if(!e||!t||e.length!==t.length)return!0;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!0;return!1}function UA(e){return parseInt(e,10)}function WA(e,t,n){var r=[`width`,`height`][t],i=[`clientWidth`,`clientHeight`][t],a=[`paddingLeft`,`paddingTop`][t],o=[`paddingRight`,`paddingBottom`][t];if(n[r]!=null&&n[r]!==`auto`)return parseFloat(n[r]);var s=document.defaultView.getComputedStyle(e);return(e[i]||UA(s[r])||UA(e.style[r]))-(UA(s[a])||0)-(UA(s[o])||0)|0}function GA(e,t){return!e||e===`solid`||!(t>0)?null:e===`dashed`?[4*t,2*t]:e===`dotted`?[t]:cp(e)?[e]:J(e)?e:null}function KA(e){var t=e.style,n=t.lineDash&&t.lineWidth>0&&GA(t.lineDash,t.lineWidth),r=t.lineDashOffset;if(n){var i=t.strokeNoScale&&e.getLineScale?e.getLineScale():1;i&&i!==1&&(n=$f(n,function(e){return e/i}),r/=i)}return[n,r]}var qA=new Eb(!0);function JA(e){var t=e.stroke;return!(t==null||t===`none`||!(e.lineWidth>0))}function YA(e){return typeof e==`string`&&e!==`none`}function XA(e){var t=e.fill;return t!=null&&t!==`none`}function ZA(e,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.fillOpacity*t.opacity,e.fill(),e.globalAlpha=n}else e.fill()}function QA(e,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.strokeOpacity*t.opacity,e.stroke(),e.globalAlpha=n}else e.stroke()}function $A(e,t,n){var r=by(t.image,t.__image,n);if(Sy(r)){var i=e.createPattern(r,t.repeat||`repeat`);if(typeof DOMMatrix==`function`&&i&&i.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*Np),a.scaleSelf(t.scaleX||1,t.scaleY||1),i.setTransform(a)}return i}}function ej(e,t,n,r){var i,a=JA(n),o=XA(n),s=n.strokePercent,c=s<1,l=!t.path;(!t.silent||c)&&l&&t.createPathProxy();var u=t.path||qA,d=t.__dirty;if(!r){var f=n.fill,p=n.stroke,m=o&&!!f.colorStops,h=a&&!!p.colorStops,g=o&&!!f.image,_=a&&!!p.image,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0;(m||h)&&(S=t.getBoundingRect()),m&&(v=d?VA(e,f,S):t.__canvasFillGradient,t.__canvasFillGradient=v),h&&(y=d?VA(e,p,S):t.__canvasStrokeGradient,t.__canvasStrokeGradient=y),g&&(b=d||!t.__canvasFillPattern?$A(e,f,t):t.__canvasFillPattern,t.__canvasFillPattern=b),_&&(x=d||!t.__canvasStrokePattern?$A(e,p,t):t.__canvasStrokePattern,t.__canvasStrokePattern=b),m?e.fillStyle=v:g&&(b?e.fillStyle=b:o=!1),h?e.strokeStyle=y:_&&(x?e.strokeStyle=x:a=!1)}var C=t.getGlobalScale();u.setScale(C[0],C[1],t.segmentIgnoreThreshold);var w,T;e.setLineDash&&n.lineDash&&(i=KA(t),w=i[0],T=i[1]);var E=!0;(l||d&4)&&(u.setDPR(e.dpr),c?u.setContext(null):(u.setContext(e),E=!1),u.reset(),t.buildPath(u,t.shape,r),u.toStatic(),t.pathUpdated()),E&&u.rebuildPath(e,c?s:1),w&&(e.setLineDash(w),e.lineDashOffset=T),r||(n.strokeFirst?(a&&QA(e,n),o&&ZA(e,n)):(o&&ZA(e,n),a&&QA(e,n))),w&&e.setLineDash([])}function tj(e,t,n){var r=t.__image=by(n.image,t.__image,t,t.onload);if(r&&Sy(r)){var i=n.x||0,a=n.y||0,o=t.getWidth(),s=t.getHeight(),c=r.width/r.height;if(o==null&&s!=null?o=s*c:s==null&&o!=null?s=o/c:o==null&&s==null&&(o=r.width,s=r.height),n.sWidth&&n.sHeight){var l=n.sx||0,u=n.sy||0;e.drawImage(r,l,u,n.sWidth,n.sHeight,i,a,o,s)}else if(n.sx&&n.sy){var l=n.sx,u=n.sy,d=o-l,f=s-u;e.drawImage(r,l,u,d,f,i,a,o,s)}else e.drawImage(r,i,a,o,s)}}function nj(e,t,n){var r,i=n.text;if(i!=null&&(i+=``),i){e.font=n.font||`12px sans-serif`,e.textAlign=n.textAlign,e.textBaseline=n.textBaseline;var a=void 0,o=void 0;e.setLineDash&&n.lineDash&&(r=KA(t),a=r[0],o=r[1]),a&&(e.setLineDash(a),e.lineDashOffset=o),n.strokeFirst?(JA(n)&&e.strokeText(i,n.x,n.y),XA(n)&&e.fillText(i,n.x,n.y)):(XA(n)&&e.fillText(i,n.x,n.y),JA(n)&&e.strokeText(i,n.x,n.y)),a&&e.setLineDash([])}}var rj=[`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`],ij=[[`lineCap`,`butt`],[`lineJoin`,`miter`],[`miterLimit`,10]];function aj(e,t,n,r,i){var a=!1;if(!r&&(n||={},t===n))return!1;if(r||t.opacity!==n.opacity){gj(e,i),a=!0;var o=Math.max(Math.min(t.opacity,1),0);e.globalAlpha=isNaN(o)?zy.opacity:o}(r||t.blend!==n.blend)&&(a||=(gj(e,i),!0),e.globalCompositeOperation=t.blend||zy.blend);for(var s=0;s<rj.length;s++){var c=rj[s];(r||t[c]!==n[c])&&(a||=(gj(e,i),!0),e[c]=e.dpr*(t[c]||0))}return(r||t.shadowColor!==n.shadowColor)&&(a||=(gj(e,i),!0),e.shadowColor=t.shadowColor||zy.shadowColor),a}function oj(e,t,n,r,i){var a=_j(t,i.inHover),o=r?null:n&&_j(n,i.inHover)||{};if(a===o)return!1;var s=aj(e,a,o,r,i);if((r||a.fill!==o.fill)&&(s||=(gj(e,i),!0),YA(a.fill)&&(e.fillStyle=a.fill)),(r||a.stroke!==o.stroke)&&(s||=(gj(e,i),!0),YA(a.stroke)&&(e.strokeStyle=a.stroke)),(r||a.opacity!==o.opacity)&&(s||=(gj(e,i),!0),e.globalAlpha=a.opacity==null?1:a.opacity),t.hasStroke()){var c=a.lineWidth/(a.strokeNoScale&&t.getLineScale?t.getLineScale():1);e.lineWidth!==c&&(s||=(gj(e,i),!0),e.lineWidth=c)}for(var l=0;l<ij.length;l++){var u=ij[l],d=u[0];(r||a[d]!==o[d])&&(s||=(gj(e,i),!0),e[d]=a[d]||u[1])}return s}function sj(e,t,n,r,i){return aj(e,_j(t,i.inHover),n&&_j(n,i.inHover),r,i)}function cj(e,t){var n=t.transform,r=e.dpr||1;n?e.setTransform(r*n[0],r*n[1],r*n[2],r*n[3],r*n[4],r*n[5]):e.setTransform(r,0,0,r,0,0)}function lj(e,t,n){for(var r=!1,i=0;i<e.length;i++){var a=e[i];r||=a.isZeroArea(),cj(t,a),t.beginPath(),a.buildPath(t,a.shape),t.clip()}n.allClipped=r}function uj(e,t){return e&&t?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&&!t)}var dj=1,fj=2,pj=3,mj=4;function hj(e){var t=XA(e),n=JA(e);return!(e.lineDash||!(+t^n)||t&&typeof e.fill!=`string`||n&&typeof e.stroke!=`string`||e.strokePercent<1||e.strokeOpacity<1||e.fillOpacity<1)}function gj(e,t){t.batchFill&&e.fill(),t.batchStroke&&e.stroke(),t.batchFill=``,t.batchStroke=``}function _j(e,t){return t&&e.__hoverStyle||e.style}function vj(e,t){yj(e,t,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function yj(e,t,n,r){var i=t.transform;if(!t.shouldBePainted(n.viewWidth,n.viewHeight,!1,!1))t.__dirty&=-2,t.__isRendered=!1;else{var a=t.__clipPaths,o=n.prevElClipPaths,s=!1,c=!1;if((!o||HA(a,o))&&(o&&o.length&&(gj(e,n),e.restore(),c=s=!0,n.prevElClipPaths=null,n.allClipped=!1,n.prevEl=null),a&&a.length&&(gj(e,n),e.save(),lj(a,e,n),s=!0),n.prevElClipPaths=a),n.allClipped)t.__isRendered=!1;else{t.beforeBrush&&t.beforeBrush(),t.innerBeforeBrush();var l=n.prevEl;l||(c=s=!0);var u=t instanceof Zb&&t.autoBatch&&hj(t.style);s||uj(i,l.transform)?(gj(e,n),cj(e,t)):u||gj(e,n);var d=_j(t,n.inHover);t instanceof Zb?(n.lastDrawType!==dj&&(c=!0,n.lastDrawType=dj),oj(e,t,l,c,n),u&&(n.batchFill||n.batchStroke)||e.beginPath(),ej(e,t,d,u),u&&(n.batchFill=d.fill||``,n.batchStroke=d.stroke||``)):t instanceof $b?(n.lastDrawType!==pj&&(c=!0,n.lastDrawType=pj),oj(e,t,l,c,n),nj(e,t,d)):t instanceof rx?(n.lastDrawType!==fj&&(c=!0,n.lastDrawType=fj),sj(e,t,l,c,n),tj(e,t,d)):t.getTemporalDisplayables&&(n.lastDrawType!==mj&&(c=!0,n.lastDrawType=mj),bj(e,t,n)),u&&r&&gj(e,n),t.innerAfterBrush(),t.afterBrush&&t.afterBrush(),n.prevEl=t,t.__dirty=0,t.__isRendered=!0}}}function bj(e,t,n){var r=t.getDisplayables(),i=t.getTemporalDisplayables();e.save();for(var a={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:n.viewWidth,viewHeight:n.viewHeight,inHover:n.inHover},o=t.getCursor(),s=r.length;o<s;o++){var c=r[o];c.beforeBrush&&c.beforeBrush(),c.innerBeforeBrush(),yj(e,c,a,o===s-1),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}for(var l=0,u=i.length;l<u;l++){var c=i[l];c.beforeBrush&&c.beforeBrush(),c.innerBeforeBrush(),yj(e,c,a,l===u-1),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}t.clearTemporalDisplayables(),t.notClear=!0,e.restore()}var xj=new OA,Sj=new Xh(100),Cj=[`symbol`,`symbolSize`,`symbolKeepAspect`,`color`,`backgroundColor`,`dashArrayX`,`dashArrayY`,`maxTileWidth`,`maxTileHeight`];function wj(e,t){if(e===`none`)return null;var n=t.getDevicePixelRatio(),r=t.getZr(),i=r.painter.type===`svg`;e.dirty&&xj.delete(e);var a=xj.get(e);if(a)return a;var o=Jf(e,{symbol:`rect`,symbolSize:1,symbolKeepAspect:!0,color:`rgba(0, 0, 0, 0.2)`,backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor===`none`&&(o.backgroundColor=null);var s={repeat:`repeat`};return c(s),s.rotation=o.rotation,s.scaleX=s.scaleY=i?1:1/n,xj.set(e,s),e.dirty=!1,s;function c(e){for(var t=[n],a=!0,s=0;s<Cj.length;++s){var c=o[Cj[s]];if(c!=null&&!J(c)&&!Y(c)&&!cp(c)&&typeof c!=`boolean`){a=!1;break}t.push(c)}var l;if(a){l=t.join(`,`)+(i?`-svg`:``);var u=Sj.get(l);u&&(i?e.svgElement=u:e.image=u)}var d=Ej(o.dashArrayX),f=Dj(o.dashArrayY),p=Tj(o.symbol),m=Oj(d),h=kj(f),g=!i&&Mf.createCanvas(),_=i&&{tag:`g`,attrs:{},key:`dcl`,children:[]},v=b(),y;g&&(g.width=v.width*n,g.height=v.height*n,y=g.getContext(`2d`)),x(),a&&Sj.put(l,g||_),e.image=g,e.svgElement=_,e.svgWidth=v.width,e.svgHeight=v.height;function b(){for(var e=1,t=0,n=m.length;t<n;++t)e=Sv(e,m[t]);for(var r=1,t=0,n=p.length;t<n;++t)r=Sv(r,p[t].length);e*=r;var i=h*m.length*p.length;return{width:Math.max(1,Math.min(e,o.maxTileWidth)),height:Math.max(1,Math.min(i,o.maxTileHeight))}}function x(){y&&(y.clearRect(0,0,g.width,g.height),o.backgroundColor&&(y.fillStyle=o.backgroundColor,y.fillRect(0,0,g.width,g.height)));for(var e=0,t=0;t<f.length;++t)e+=f[t];if(e<=0)return;for(var a=-h,s=0,c=0,l=0;a<v.height;){if(s%2==0){for(var u=c/2%p.length,m=0,b=0,x=0;m<v.width*2;){for(var S=0,t=0;t<d[l].length;++t)S+=d[l][t];if(S<=0)break;if(b%2==0){var C=(1-o.symbolSize)*.5,w=m+d[l][b]*C,T=a+f[s]*C,E=d[l][b]*o.symbolSize,D=f[s]*o.symbolSize,O=x/2%p[u].length;k(w,T,E,D,p[u][O])}m+=d[l][b],++x,++b,b===d[l].length&&(b=0)}++l,l===d.length&&(l=0)}a+=f[s],++c,++s,s===f.length&&(s=0)}function k(e,t,a,s,c){var l=i?1:n,u=FA(c,e*l,t*l,a*l,s*l,o.color,o.symbolKeepAspect);if(i){var d=r.painter.renderOneToVNode(u);d&&_.children.push(d)}else vj(y,u)}}}}function Tj(e){if(!e||e.length===0)return[[`rect`]];if(Y(e))return[[e]];for(var t=!0,n=0;n<e.length;++n)if(!Y(e[n])){t=!1;break}if(t)return Tj([e]);for(var r=[],n=0;n<e.length;++n)Y(e[n])?r.push([e[n]]):r.push(e[n]);return r}function Ej(e){if(!e||e.length===0)return[[0,0]];if(cp(e)){var t=Math.ceil(e);return[[t,t]]}for(var n=!0,r=0;r<e.length;++r)if(!cp(e[r])){n=!1;break}if(n)return Ej([e]);for(var i=[],r=0;r<e.length;++r)if(cp(e[r])){var t=Math.ceil(e[r]);i.push([t,t])}else{var t=$f(e[r],function(e){return Math.ceil(e)});t.length%2==1?i.push(t.concat(t)):i.push(t)}return i}function Dj(e){if(!e||typeof e==`object`&&e.length===0)return[0,0];if(cp(e)){var t=Math.ceil(e);return[t,t]}var n=$f(e,function(e){return Math.ceil(e)});return e.length%2?n.concat(n):n}function Oj(e){return $f(e,function(e){return kj(e)})}function kj(e){for(var t=0,n=0;n<e.length;++n)t+=e[n];return e.length%2==1?t*2:t}function Aj(e,t){e.eachRawSeries(function(n){if(!e.isSeriesFiltered(n)){var r=n.getData();r.hasItemVisual()&&r.each(function(e){var n=r.getItemVisual(e,`decal`);if(n){var i=r.ensureUniqueItemVisual(e,`style`);i.decal=wj(n,t)}});var i=r.getVisual(`decal`);if(i){var a=r.getVisual(`style`);a.decal=wj(i,t)}}})}var jj=new em,Mj={};function Nj(e,t){Mj[e]=t}function Pj(e){return Mj[e]}var Fj=1,Ij=800,Lj=900,Rj=1e3,zj=2e3,Bj=5e3,Vj=1e3,Hj=1100,Uj=2e3,Wj=3e3,Gj=4e3,Kj=4500,qj=4600,Jj=5e3,Yj=6e3,Xj=7e3,Zj={PROCESSOR:{FILTER:Rj,SERIES_FILTER:Ij,STATISTIC:Bj},VISUAL:{LAYOUT:Vj,PROGRESSIVE_LAYOUT:Hj,GLOBAL:Uj,CHART:Wj,POST_CHART_LAYOUT:qj,COMPONENT:Gj,BRUSH:Jj,CHART_ITEM:Kj,ARIA:Yj,DECAL:Xj}},Qj=`__flagInMainProcess`,$j=`__pendingUpdate`,eM=`__needsUpdateStatus`,tM=/^[a-zA-Z0-9_]+$/,nM=`__connectUpdateStatus`,rM=0,iM=1,aM=2;function oM(e){return function(){var t=[...arguments];if(this.isDisposed())this.id;else return cM(this,e,t)}}function sM(e){return function(){var t=[...arguments];return cM(this,e,t)}}function cM(e,t,n){return n[0]=n[0]&&n[0].toLowerCase(),em.prototype[t].apply(e,n)}var lM=function(e){U(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t}(em),uM=lM.prototype;uM.on=sM(`on`),uM.off=sM(`off`);var dM,fM,pM,mM,hM,gM,_M,vM,yM,bM,xM,SM,CM,wM,TM,EM,DM,OM,kM=function(e){U(t,e);function t(t,n,r){var i=e.call(this,new gA)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],r||={},Y(n)&&(n=LM[n]),i._dom=t;var a=`canvas`,o=`auto`,s=!1;r.ssr;var c=i._zr=rv(t,{renderer:r.renderer||a,devicePixelRatio:r.devicePixelRatio,width:r.width,height:r.height,ssr:r.ssr,useDirtyRect:Z(r.useDirtyRect,s),useCoarsePointer:Z(r.useCoarsePointer,o),pointerSize:r.pointerSize});i._ssr=r.ssr,i._throttledZrFlush=Pk(ip(c.flush,c),17),n=G(n),n&&kD(n,!0),i._theme=n,i._locale=ET(r.locale||wT),i._coordSysMgr=new $E;var l=i._api=TM(i);function u(e,t){return e.__prio-t.__prio}return ph(IM,u),ph(PM,u),i._scheduler=new Jk(i,l,PM,IM),i._messageCenter=new lM,i._initEvents(),i.resize=ip(i.resize,i),c.animation.on(`frame`,i._onframe,i),bM(c,i),xM(c,i),Sp(i),i}return t.prototype._onframe=function(){if(!this._disposed){OM(this);var e=this._scheduler;if(this[$j]){var t=this[$j].silent;this[Qj]=!0;try{dM(this),mM.update.call(this,null,this[$j].updateParams)}catch(e){throw this[Qj]=!1,this[$j]=null,e}this._zr.flush(),this[Qj]=!1,this[$j]=null,vM.call(this,t),yM.call(this,t)}else if(e.unfinished){var n=Fj,r=this._model,i=this._api;e.unfinished=!1;do{var a=+new Date;e.performSeriesTasks(r),e.performDataProcessorTasks(r),gM(this,r),e.performVisualTasks(r),wM(this,this._model,i,`remain`,{}),n-=+new Date-a}while(n>0&&e.unfinished);e.unfinished||this._zr.flush()}}},t.prototype.getDom=function(){return this._dom},t.prototype.getId=function(){return this.id},t.prototype.getZr=function(){return this._zr},t.prototype.isSSR=function(){return this._ssr},t.prototype.setOption=function(e,t,n){if(!this[Qj]){if(this._disposed)this.id;else{var r,i,a;if(X(t)&&(n=t.lazyUpdate,r=t.silent,i=t.replaceMerge,a=t.transition,t=t.notMerge),this[Qj]=!0,!this._model||t){var o=new tD(this._api),s=this._theme,c=this._model=new WE;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,s,this._locale,o)}this._model.setOption(e,{replaceMerge:i},FM);var l={seriesTransition:a,optionChanged:!0};if(n)this[$j]={silent:r,updateParams:l},this[Qj]=!1,this.getZr().wakeUp();else{try{dM(this),mM.update.call(this,null,l)}catch(e){throw this[$j]=null,this[Qj]=!1,e}this._ssr||this._zr.flush(),this[$j]=null,this[Qj]=!1,vM.call(this,r),yM.call(this,r)}}}},t.prototype.setTheme=function(){},t.prototype.getModel=function(){return this._model},t.prototype.getOption=function(){return this._model&&this._model.getOption()},t.prototype.getWidth=function(){return this._zr.getWidth()},t.prototype.getHeight=function(){return this._zr.getHeight()},t.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||W.hasGlobalWindow&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(e){return this.renderToCanvas(e)},t.prototype.renderToCanvas=function(e){return e||={},this._zr.painter.getRenderedCanvas({backgroundColor:e.backgroundColor||this._model.get(`backgroundColor`),pixelRatio:e.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(e){return e||={},this._zr.painter.renderToString({useViewBox:e.useViewBox})},t.prototype.getSvgDataURL=function(){if(W.svgSupported){var e=this._zr;return q(e.storage.getDisplayList(),function(e){e.stopAnimation(null,!0)}),e.painter.toDataURL()}},t.prototype.getDataURL=function(e){if(this._disposed)this.id;else{e||={};var t=e.excludeComponents,n=this._model,r=[],i=this;q(t,function(e){n.eachComponent({mainType:e},function(e){var t=i._componentsMap[e.__viewId];t.group.ignore||(r.push(t),t.group.ignore=!0)})});var a=this._zr.painter.getType()===`svg`?this.getSvgDataURL():this.renderToCanvas(e).toDataURL(`image/`+(e&&e.type||`png`));return q(r,function(e){e.group.ignore=!1}),a}},t.prototype.getConnectedDataURL=function(e){if(this._disposed)this.id;else{var t=e.type===`svg`,n=this.group,r=Math.min,i=Math.max,a=1/0;if(BM[n]){var o=a,s=a,c=-a,l=-a,u=[],d=e&&e.pixelRatio||this.getDevicePixelRatio();q(zM,function(a,d){if(a.group===n){var f=t?a.getZr().painter.getSvgDom().innerHTML:a.renderToCanvas(G(e)),p=a.getDom().getBoundingClientRect();o=r(p.left,o),s=r(p.top,s),c=i(p.right,c),l=i(p.bottom,l),u.push({dom:f,left:p.left,top:p.top})}}),o*=d,s*=d,c*=d,l*=d;var f=c-o,p=l-s,m=Mf.createCanvas(),h=rv(m,{renderer:t?`svg`:`canvas`});if(h.resize({width:f,height:p}),t){var g=``;return q(u,function(e){var t=e.left-o,n=e.top-s;g+=`<g transform="translate(`+t+`,`+n+`)">`+e.dom+`</g>`}),h.painter.getSvgRoot().innerHTML=g,e.connectedBackgroundColor&&h.painter.setBackgroundColor(e.connectedBackgroundColor),h.refreshImmediately(),h.painter.toDataURL()}return e.connectedBackgroundColor&&h.add(new dx({shape:{x:0,y:0,width:f,height:p},style:{fill:e.connectedBackgroundColor}})),q(u,function(e){var t=new rx({style:{x:e.left*d-o,y:e.top*d-s,image:e.dom}});h.add(t)}),h.refreshImmediately(),m.toDataURL(`image/`+(e&&e.type||`png`))}return this.getDataURL(e)}},t.prototype.convertToPixel=function(e,t){return hM(this,`convertToPixel`,e,t)},t.prototype.convertFromPixel=function(e,t){return hM(this,`convertFromPixel`,e,t)},t.prototype.containPixel=function(e,t){if(this._disposed)this.id;else{var n=this._model,r;return q(Jv(n,e),function(e,n){n.indexOf(`Models`)>=0&&q(e,function(e){var i=e.coordinateSystem;if(i&&i.containPoint)r||=!!i.containPoint(t);else if(n===`seriesModels`){var a=this._chartsMap[e.__viewId];a&&a.containPoint&&(r||=a.containPoint(t,e))}},this)},this),!!r}},t.prototype.getVisual=function(e,t){var n=this._model,r=Jv(n,e,{defaultMainType:`series`}),i=r.seriesModel.getData(),a=r.hasOwnProperty(`dataIndexInside`)?r.dataIndexInside:r.hasOwnProperty(`dataIndex`)?i.indexOfRawIndex(r.dataIndex):null;return a==null?SA(i,t):xA(i,a,t)},t.prototype.getViewOfComponentModel=function(e){return this._componentsMap[e.__viewId]},t.prototype.getViewOfSeriesModel=function(e){return this._chartsMap[e.__viewId]},t.prototype._initEvents=function(){var e=this;q(jM,function(t){var n=function(n){var r=e.getModel(),i=n.target,a;if(t===`globalout`?a={}:i&&TA(i,function(e){var t=Ax(e);if(t&&t.dataIndex!=null){var n=t.dataModel||r.getSeriesByIndex(t.seriesIndex);return a=n&&n.getDataParams(t.dataIndex,t.dataType,i)||{},!0}if(t.eventData)return a=K({},t.eventData),!0},!0),a){var o=a.componentType,s=a.componentIndex;(o===`markLine`||o===`markPoint`||o===`markArea`)&&(o=`series`,s=a.seriesIndex);var c=o&&s!=null&&r.getComponent(o,s),l=c&&e[c.mainType===`series`?`_chartsMap`:`_componentsMap`][c.__viewId];a.event=n,a.type=t,e._$eventProcessor.eventInfo={targetEl:i,packedEvent:a,model:c,view:l},e.trigger(t,a)}};n.zrEventfulCallAtLast=!0,e._zr.on(t,n,e)}),q(NM,function(t,n){e._messageCenter.on(n,function(e){this.trigger(n,e)},e)}),q([`selectchanged`],function(t){e._messageCenter.on(t,function(e){this.trigger(t,e)},e)}),wA(this._messageCenter,this,this._api)},t.prototype.isDisposed=function(){return this._disposed},t.prototype.clear=function(){this._disposed?this.id:this.setOption({series:[]},!0)},t.prototype.dispose=function(){if(this._disposed)this.id;else{this._disposed=!0,this.getDom()&&Qv(this.getDom(),HM,``);var e=this,t=e._api,n=e._model;q(e._componentsViews,function(e){e.dispose(n,t)}),q(e._chartsViews,function(e){e.dispose(n,t)}),e._zr.dispose(),e._dom=e._model=e._chartsMap=e._componentsMap=e._chartsViews=e._componentsViews=e._scheduler=e._api=e._zr=e._throttledZrFlush=e._theme=e._coordSysMgr=e._messageCenter=null,delete zM[e.id]}},t.prototype.resize=function(e){if(!this[Qj]){if(this._disposed)this.id;else{this._zr.resize(e);var t=this._model;if(this._loadingFX&&this._loadingFX.resize(),t){var n=t.resetOption(`media`),r=e&&e.silent;this[$j]&&(r??=this[$j].silent,n=!0,this[$j]=null),this[Qj]=!0;try{n&&dM(this),mM.update.call(this,{type:`resize`,animation:K({duration:0},e&&e.animation)})}catch(e){throw this[Qj]=!1,e}this[Qj]=!1,vM.call(this,r),yM.call(this,r)}}}},t.prototype.showLoading=function(e,t){if(this._disposed)this.id;else if(X(e)&&(t=e,e=``),e||=`default`,this.hideLoading(),RM[e]){var n=RM[e](this._api,t),r=this._zr;this._loadingFX=n,r.add(n)}},t.prototype.hideLoading=function(){this._disposed?this.id:(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},t.prototype.makeActionFromEvent=function(e){var t=K({},e);return t.type=NM[e.type],t},t.prototype.dispatchAction=function(e,t){if(this._disposed)this.id;else if(X(t)||(t={silent:!!t}),MM[e.type]&&this._model){if(this[Qj])this._pendingActions.push(e);else{var n=t.silent;_M.call(this,e,n);var r=t.flush;r?this._zr.flush():r!==!1&&W.browser.weChat&&this._throttledZrFlush(),vM.call(this,n),yM.call(this,n)}}},t.prototype.updateLabelLayout=function(){jj.trigger(`series:layoutlabels`,this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(e){if(this._disposed)this.id;else{var t=e.seriesIndex;this.getModel().getSeriesByIndex(t).appendData(e),this._scheduler.unfinished=!0,this.getZr().wakeUp()}},t.internalField=function(){dM=function(e){var t=e._scheduler;t.restorePipelines(e._model),t.prepareStageTasks(),fM(e,!0),fM(e,!1),t.plan()},fM=function(e,t){for(var n=e._model,r=e._scheduler,i=t?e._componentsViews:e._chartsViews,a=t?e._componentsMap:e._chartsMap,o=e._zr,s=e._api,c=0;c<i.length;c++)i[c].__alive=!1;t?n.eachComponent(function(e,t){e!==`series`&&l(t)}):n.eachSeries(l);function l(e){var c=e.__requireNewView;e.__requireNewView=!1;var l=`_ec_`+e.id+`_`+e.type,u=!c&&a[l];if(!u){var d=iy(e.type);u=new(t?xk.getClass(d.main,d.sub):Tk.getClass(d.sub)),u.init(n,s),a[l]=u,i.push(u),o.add(u.group)}e.__viewId=u.__id=l,u.__alive=!0,u.__model=e,u.group.__ecComponentInfo={mainType:e.mainType,index:e.componentIndex},!t&&r.prepareView(u,e,n,s)}for(var c=0;c<i.length;){var u=i[c];u.__alive?c++:(!t&&u.renderTask.dispose(),o.remove(u.group),u.dispose(n,s),i.splice(c,1),a[u.__id]===u&&delete a[u.__id],u.__id=u.group.__ecComponentInfo=null)}},pM=function(e,t,n,r,i){var a=e._model;if(a.setUpdatePayload(n),!r){q([].concat(e._componentsViews,e._chartsViews),u);return}var o={};o[r+`Id`]=n[r+`Id`],o[r+`Index`]=n[r+`Index`],o[r+`Name`]=n[r+`Name`];var s={mainType:r,query:o};i&&(s.subType=i);var c=n.excludeSeriesId,l;c!=null&&(l=Q(),q(Ev(c),function(e){var t=Bv(e,null);t!=null&&l.set(t,!0)})),a&&a.eachComponent(s,function(t){if(!(l&&l.get(t.id)!=null)){if(MS(n)){if(t instanceof fk)n.type===`highlight`&&!n.notBlur&&!t.get([`emphasis`,`disabled`])&&_S(t,n,e._api);else{var r=vS(t.mainType,t.componentIndex,n.name,e._api),i=r.focusSelf,a=r.dispatchers;n.type===`highlight`&&i&&!n.notBlur&&gS(t.mainType,t.componentIndex,e._api),a&&q(a,function(e){n.type===`highlight`?sS(e):cS(e)})}}else jS(n)&&t instanceof fk&&(xS(t,n,e._api),SS(t),DM(e))}},e),a&&a.eachComponent(s,function(t){l&&l.get(t.id)!=null||u(e[r===`series`?`_chartsMap`:`_componentsMap`][t.__viewId])},e);function u(r){r&&r.__alive&&r[t]&&r[t](r.__model,a,e._api,n)}},mM={prepareAndUpdate:function(e){dM(this),mM.update.call(this,e,{optionChanged:e.newOption!=null})},update:function(t,n){var r=this._model,i=this._api,a=this._zr,o=this._coordSysMgr,s=this._scheduler;if(r){r.setUpdatePayload(t),s.restoreData(r,t),s.performSeriesTasks(r),o.create(r,i),s.performDataProcessorTasks(r,t),gM(this,r),o.update(r,i),e(r),s.performVisualTasks(r,t),SM(this,r,i,t,n);var c=r.get(`backgroundColor`)||`transparent`,l=r.get(`darkMode`);a.setBackgroundColor(c),l!=null&&l!==`auto`&&a.setDarkMode(l),jj.trigger(`afterupdate`,r,i)}},updateTransform:function(t){var n=this,r=this._model,i=this._api;if(r){r.setUpdatePayload(t);var a=[];r.eachComponent(function(e,o){if(e!==`series`){var s=n.getViewOfComponentModel(o);if(s&&s.__alive){if(s.updateTransform){var c=s.updateTransform(o,r,i,t);c&&c.update&&a.push(s)}else a.push(s)}}});var o=Q();r.eachSeries(function(e){var a=n._chartsMap[e.__viewId];if(a.updateTransform){var s=a.updateTransform(e,r,i,t);s&&s.update&&o.set(e.uid,1)}else o.set(e.uid,1)}),e(r),this._scheduler.performVisualTasks(r,t,{setDirty:!0,dirtyMap:o}),wM(this,r,i,t,{},o),jj.trigger(`afterupdate`,r,i)}},updateView:function(t){var n=this._model;n&&(n.setUpdatePayload(t),Tk.markUpdateMethod(t,`updateView`),e(n),this._scheduler.performVisualTasks(n,t,{setDirty:!0}),SM(this,n,this._api,t,{}),jj.trigger(`afterupdate`,n,this._api))},updateVisual:function(t){var n=this,r=this._model;r&&(r.setUpdatePayload(t),r.eachSeries(function(e){e.getData().clearAllVisual()}),Tk.markUpdateMethod(t,`updateVisual`),e(r),this._scheduler.performVisualTasks(r,t,{visualType:`visual`,setDirty:!0}),r.eachComponent(function(e,i){if(e!==`series`){var a=n.getViewOfComponentModel(i);a&&a.__alive&&a.updateVisual(i,r,n._api,t)}}),r.eachSeries(function(e){n._chartsMap[e.__viewId].updateVisual(e,r,n._api,t)}),jj.trigger(`afterupdate`,r,this._api))},updateLayout:function(e){mM.update.call(this,e)}},hM=function(e,t,n,r){if(e._disposed)e.id;else for(var i=e._model,a=e._coordSysMgr.getCoordinateSystems(),o,s=Jv(i,n),c=0;c<a.length;c++){var l=a[c];if(l[t]&&(o=l[t](i,s,r))!=null)return o}},gM=function(e,t){var n=e._chartsMap,r=e._scheduler;t.eachSeries(function(e){r.updateStreamModes(e,n[e.__viewId])})},_M=function(e,t){var n=this,r=this.getModel(),i=e.type,a=e.escapeConnect,o=MM[i],s=o.actionInfo,c=(s.update||`update`).split(`:`),l=c.pop(),u=c[0]!=null&&iy(c[0]);this[Qj]=!0;var d=[e],f=!1;e.batch&&(f=!0,d=$f(e.batch,function(t){return t=Jf(K({},t),e),t.batch=null,t}));var p=[],m,h=jS(e),g=MS(e);if(g&&mS(this._api),q(d,function(t){if(m=o.action(t,n._model,n._api),m||=K({},t),m.type=s.event||m.type,p.push(m),g){var r=Yv(e),i=r.queryOptionMap,a=r.mainTypeSpecified?i.keys()[0]:`series`;pM(n,l,t,a),DM(n)}else h?(pM(n,l,t,`series`),DM(n)):u&&pM(n,l,t,u.main,u.sub)}),l!==`none`&&!g&&!h&&!u)try{this[$j]?(dM(this),mM.update.call(this,e),this[$j]=null):mM[l].call(this,e)}catch(e){throw this[Qj]=!1,e}if(m=f?{type:s.event||i,escapeConnect:a,batch:p}:p[0],this[Qj]=!1,!t){var _=this._messageCenter;if(_.trigger(m.type,m),h){var v={type:`selectchanged`,escapeConnect:a,selected:CS(r),isFromClick:e.isFromClick||!1,fromAction:e.type,fromActionPayload:e};_.trigger(v.type,v)}}},vM=function(e){for(var t=this._pendingActions;t.length;){var n=t.shift();_M.call(this,n,e)}},yM=function(e){!e&&this.trigger(`updated`)},bM=function(e,t){e.on(`rendered`,function(n){t.trigger(`rendered`,n),e.animation.isFinished()&&!t[$j]&&!t._scheduler.unfinished&&!t._pendingActions.length&&t.trigger(`finished`)})},xM=function(e,t){e.on(`mouseover`,function(e){var n=e.target,r=TA(n,kS);r&&(yS(r,e,t._api),DM(t))}).on(`mouseout`,function(e){var n=e.target,r=TA(n,kS);r&&(bS(r,e,t._api),DM(t))}).on(`click`,function(e){var n=e.target,r=TA(n,function(e){return Ax(e).dataIndex!=null},!0);if(r){var i=r.selected?`unselect`:`select`,a=Ax(r);t._api.dispatchAction({type:i,dataType:a.dataType,dataIndexInside:a.dataIndex,seriesIndex:a.seriesIndex,isFromClick:!0})}})};function e(e){e.clearColorPalette(),e.eachSeries(function(e){e.clearColorPalette()})}function t(e){var t=[],n=[],r=!1;if(e.eachComponent(function(e,i){var a=i.get(`zlevel`)||0,o=i.get(`z`)||0,s=i.getZLevelKey();r||=!!s,(e===`series`?n:t).push({zlevel:a,z:o,idx:i.componentIndex,type:e,key:s})}),r){var i=t.concat(n),a,o;ph(i,function(e,t){return e.zlevel===t.zlevel?e.z-t.z:e.zlevel-t.zlevel}),q(i,function(t){var n=e.getComponent(t.type,t.idx),r=t.zlevel,i=t.key;a!=null&&(r=Math.max(a,r)),i?(r===a&&i!==o&&r++,o=i):o&&=(r===a&&r++,``),a=r,n.setZLevel(r)})}}SM=function(e,n,r,i,a){t(n),CM(e,n,r,i,a),q(e._chartsViews,function(e){e.__alive=!1}),wM(e,n,r,i,a),q(e._chartsViews,function(e){e.__alive||e.remove(n,r)})},CM=function(e,t,n,r,i,o){q(o||e._componentsViews,function(e){var i=e.__model;s(i,e),e.render(i,t,n,r),a(i,e),c(i,e)})},wM=function(e,t,n,o,l,u){var d=e._scheduler;l=K(l||{},{updatedSeries:t.getSeries()}),jj.trigger(`series:beforeupdate`,t,n,l);var f=!1;t.eachSeries(function(t){var n=e._chartsMap[t.__viewId];n.__alive=!0;var r=n.renderTask;d.updatePayload(r,o),s(t,n),u&&u.get(t.uid)&&r.dirty(),r.perform(d.getPerformArgs(r))&&(f=!0),n.group.silent=!!t.get(`silent`),i(t,n),SS(t)}),d.unfinished=f||d.unfinished,jj.trigger(`series:layoutlabels`,t,n,l),jj.trigger(`series:transition`,t,n,l),t.eachSeries(function(t){var n=e._chartsMap[t.__viewId];a(t,n),c(t,n)}),r(e,t),jj.trigger(`series:afterupdate`,t,n,l)},DM=function(e){e[eM]=!0,e.getZr().wakeUp()},OM=function(e){e[eM]&&(e.getZr().storage.traverse(function(e){nw(e)||n(e)}),e[eM]=!1)};function n(e){for(var t=[],n=e.currentStates,r=0;r<n.length;r++){var i=n[r];i!==`emphasis`&&i!==`blur`&&i!==`select`&&t.push(i)}e.selected&&e.states.select&&t.push(`select`),e.hoverState===2&&e.states.emphasis?t.push(`emphasis`):e.hoverState===1&&e.states.blur&&t.push(`blur`),e.useStates(t)}function r(e,t){var n=e._zr.storage,r=0;n.traverse(function(e){e.isGroup||r++}),r>t.get(`hoverLayerThreshold`)&&!W.node&&!W.worker&&t.eachSeries(function(t){if(!t.preventUsingHoverLayer){var n=e._chartsMap[t.__viewId];n.__alive&&n.eachRendered(function(e){e.states.emphasis&&(e.states.emphasis.hoverLayer=!0)})}})}function i(e,t){var n=e.get(`blendMode`)||null;t.eachRendered(function(e){e.isGroup||(e.style.blend=n)})}function a(e,t){if(!e.preventAutoZ){var n=e.get(`z`)||0,r=e.get(`zlevel`)||0;t.eachRendered(function(e){return o(e,n,r,-1/0),!0})}}function o(e,t,n,r){var i=e.getTextContent(),a=e.getTextGuideLine();if(e.isGroup)for(var s=e.childrenRef(),c=0;c<s.length;c++)r=Math.max(o(s[c],t,n,r),r);else e.z=t,e.zlevel=n,r=Math.max(e.z2,r);if(i&&(i.z=t,i.zlevel=n,isFinite(r)&&(i.z2=r+2)),a){var l=e.textGuideLineConfig;a.z=t,a.zlevel=n,isFinite(r)&&(a.z2=r+(l&&l.showAbove?1:-1))}return r}function s(e,t){t.eachRendered(function(e){if(!nw(e)){var t=e.getTextContent(),n=e.getTextGuideLine();e.stateTransition&&=null,t&&t.stateTransition&&(t.stateTransition=null),n&&n.stateTransition&&(n.stateTransition=null),e.hasState()?(e.prevStates=e.currentStates,e.clearStates()):e.prevStates&&=null}})}function c(e,t){var r=e.getModel(`stateAnimation`),i=e.isAnimationEnabled(),a=r.get(`duration`),o=a>0?{duration:a,delay:r.get(`delay`),easing:r.get(`easing`)}:null;t.eachRendered(function(e){if(e.states&&e.states.emphasis){if(nw(e))return;if(e instanceof Zb&&NS(e),e.__dirty){var t=e.prevStates;t&&e.useStates(t)}if(i){e.stateTransition=o;var r=e.getTextContent(),a=e.getTextGuideLine();r&&(r.stateTransition=o),a&&(a.stateTransition=o)}e.__dirty&&n(e)}})}TM=function(e){return new(function(t){U(n,t);function n(){return t!==null&&t.apply(this,arguments)||this}return n.prototype.getCoordinateSystems=function(){return e._coordSysMgr.getCoordinateSystems()},n.prototype.getComponentByElement=function(t){for(;t;){var n=t.__ecComponentInfo;if(n!=null)return e._model.getComponent(n.mainType,n.index);t=t.parent}},n.prototype.enterEmphasis=function(t,n){sS(t,n),DM(e)},n.prototype.leaveEmphasis=function(t,n){cS(t,n),DM(e)},n.prototype.enterBlur=function(t){lS(t),DM(e)},n.prototype.leaveBlur=function(t){uS(t),DM(e)},n.prototype.enterSelect=function(t){dS(t),DM(e)},n.prototype.leaveSelect=function(t){fS(t),DM(e)},n.prototype.getModel=function(){return e.getModel()},n.prototype.getViewOfComponentModel=function(t){return e.getViewOfComponentModel(t)},n.prototype.getViewOfSeriesModel=function(t){return e.getViewOfSeriesModel(t)},n}(ZE))(e)},EM=function(e){function t(e,t){for(var n=0;n<e.length;n++){var r=e[n];r[nM]=t}}q(NM,function(n,r){e._messageCenter.on(r,function(n){if(BM[e.group]&&e[nM]!==rM){if(n&&n.escapeConnect)return;var r=e.makeActionFromEvent(n),i=[];q(zM,function(t){t!==e&&t.group===e.group&&i.push(t)}),t(i,rM),q(i,function(e){e[nM]!==iM&&e.dispatchAction(r)}),t(i,aM)}})})}}(),t}(em),AM=kM.prototype;AM.on=oM(`on`),AM.off=oM(`off`),AM.one=function(e,t,n){var r=this;function i(){var n=[...arguments];t&&t.apply&&t.apply(this,n),r.off(e,i)}this.on.call(this,e,i,n)};var jM=[`click`,`dblclick`,`mouseover`,`mouseout`,`mousemove`,`mousedown`,`mouseup`,`globalout`,`contextmenu`],MM={},NM={},PM=[],FM=[],IM=[],LM={},RM={},zM={},BM={},VM=new Date-0;new Date-0;var HM=`_echarts_instance_`;function UM(e,t,n){var r=!(n&&n.ssr);if(r){var i=WM(e);if(i)return i}var a=new kM(e,t,n);return a.id=`ec_`+VM++,zM[a.id]=a,r&&Qv(e,HM,a.id),EM(a),jj.trigger(`afterinit`,a),a}function WM(e){return zM[$v(e,HM)]}function GM(e,t){LM[e]=t}function KM(e){Yf(FM,e)<0&&FM.push(e)}function qM(e,t){nN(PM,e,t,zj)}function JM(e){XM(`afterinit`,e)}function YM(e){XM(`afterupdate`,e)}function XM(e,t){jj.on(e,t)}function ZM(e,t,n){op(t)&&(n=t,t=``);var r=X(e)?e.type:[e,e={event:t}][0];e.event=(e.event||r).toLowerCase(),t=e.event,NM[t]||(yp(tM.test(r)&&tM.test(t)),MM[r]||(MM[r]={action:n,actionInfo:e}),NM[t]=r)}function QM(e,t){$E.register(e,t)}function $M(e,t){nN(IM,e,t,Vj,`layout`)}function eN(e,t){nN(IM,e,t,Wj,`visual`)}var tN=[];function nN(e,t,n,r,i){if((op(t)||X(t))&&(n=t,t=r),!(Yf(tN,n)>=0)){tN.push(n);var a=Jk.wrapStageHandler(n,i);a.__prio=t,a.__raw=n,e.push(a)}}function rN(e,t){RM[e]=t}function iN(e,t,n){var r=Pj(`registerMap`);r&&r(e,t,n)}var aN=SO;eN(Uj,Hk),eN(Kj,Wk),eN(Kj,Gk),eN(Uj,yA),eN(Kj,bA),eN(Xj,Aj),KM(kD),qM(Lj,AD),rN(`default`,qk),ZM({type:Rx,event:Rx,update:Rx},Mp),ZM({type:zx,event:zx,update:zx},Mp),ZM({type:Bx,event:Bx,update:Bx},Mp),ZM({type:Vx,event:Vx,update:Vx},Mp),ZM({type:Hx,event:Hx,update:Hx},Mp),GM(`light`,uA),GM(`dark`,hA);function oN(e){return e==null?0:e.length||1}function sN(e){return e}var cN=function(){function e(e,t,n,r,i,a){this._old=e,this._new=t,this._oldKeyGetter=n||sN,this._newKeyGetter=r||sN,this.context=i,this._diffModeMultiple=a===`multiple`}return e.prototype.add=function(e){return this._add=e,this},e.prototype.update=function(e){return this._update=e,this},e.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},e.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},e.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},e.prototype.remove=function(e){return this._remove=e,this},e.prototype.execute=function(){this[this._diffModeMultiple?`_executeMultiple`:`_executeOneToOne`]()},e.prototype._executeOneToOne=function(){var e=this._old,t=this._new,n={},r=Array(e.length),i=Array(t.length);this._initIndexMap(e,null,r,`_oldKeyGetter`),this._initIndexMap(t,n,i,`_newKeyGetter`);for(var a=0;a<e.length;a++){var o=r[a],s=n[o],c=oN(s);if(c>1){var l=s.shift();s.length===1&&(n[o]=s[0]),this._update&&this._update(l,a)}else c===1?(n[o]=null,this._update&&this._update(s,a)):this._remove&&this._remove(a)}this._performRestAdd(i,n)},e.prototype._executeMultiple=function(){var e=this._old,t=this._new,n={},r={},i=[],a=[];this._initIndexMap(e,n,i,`_oldKeyGetter`),this._initIndexMap(t,r,a,`_newKeyGetter`);for(var o=0;o<i.length;o++){var s=i[o],c=n[s],l=r[s],u=oN(c),d=oN(l);if(u>1&&d===1)this._updateManyToOne&&this._updateManyToOne(l,c),r[s]=null;else if(u===1&&d>1)this._updateOneToMany&&this._updateOneToMany(l,c),r[s]=null;else if(u===1&&d===1)this._update&&this._update(l,c),r[s]=null;else if(u>1&&d>1)this._updateManyToMany&&this._updateManyToMany(l,c),r[s]=null;else if(u>1)for(var f=0;f<u;f++)this._remove&&this._remove(c[f]);else this._remove&&this._remove(c)}this._performRestAdd(a,r)},e.prototype._performRestAdd=function(e,t){for(var n=0;n<e.length;n++){var r=e[n],i=t[r],a=oN(i);if(a>1)for(var o=0;o<a;o++)this._add&&this._add(i[o]);else a===1&&this._add&&this._add(i);t[r]=null}},e.prototype._initIndexMap=function(e,t,n,r){for(var i=this._diffModeMultiple,a=0;a<e.length;a++){var o=`_ec_`+this[r](e[a],a);if(i||(n[a]=o),t){var s=t[o],c=oN(s);c===0?(t[o]=a,i&&n.push(o)):c===1?t[o]=[s,a]:s.push(a)}}},e}(),lN=function(){function e(e,t){this._encode=e,this._schema=t}return e.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},e.prototype._getFullDimensionNames=function(){return this._cachedDimNames||=this._schema?this._schema.makeOutputDimensionNames():[],this._cachedDimNames},e}();function uN(e,t){var n={},r=n.encode={},i=Q(),a=[],o=[],s={};q(e.dimensions,function(t){var n=e.getDimensionInfo(t),c=n.coordDim;if(c){var l=n.coordDimIndex;dN(r,c)[l]=t,n.isExtraCoord||(i.set(c,1),pN(n.type)&&(a[0]=t),dN(s,c)[l]=e.getDimensionIndex(n.name)),n.defaultTooltip&&o.push(t)}mE.each(function(e,t){var i=dN(r,t),a=n.otherDims[t];a!=null&&a!==!1&&(i[a]=n.name)})});var c=[],l={};i.each(function(e,t){var n=r[t];l[t]=n[0],c=c.concat(n)}),n.dataDimsOnCoord=c,n.dataDimIndicesOnCoord=$f(c,function(t){return e.getDimensionInfo(t).storeDimIndex}),n.encodeFirstDimNotExtra=l;var u=r.label;u&&u.length&&(a=u.slice());var d=r.tooltip;return d&&d.length?o=d.slice():o.length||(o=a.slice()),r.defaultedLabel=a,r.defaultedTooltip=o,n.userOutput=new lN(s,t),n}function dN(e,t){return e.hasOwnProperty(t)||(e[t]=[]),e[t]}function fN(e){return e===`category`?`ordinal`:e===`time`?`time`:`float`}function pN(e){return e!==`ordinal`&&e!==`time`}var mN=function(){function e(e){this.otherDims={},e!=null&&K(this,e)}return e}(),hN=Kv(),gN={float:`f`,int:`i`,ordinal:`o`,number:`n`,time:`t`},_N=function(){function e(e){this.dimensions=e.dimensions,this._dimOmitted=e.dimensionOmitted,this.source=e.source,this._fullDimCount=e.fullDimensionCount,this._updateDimOmitted(e.dimensionOmitted)}return e.prototype.isDimensionOmitted=function(){return this._dimOmitted},e.prototype._updateDimOmitted=function(e){this._dimOmitted=e,e&&(this._dimNameMap||=bN(this.source))},e.prototype.getSourceDimensionIndex=function(e){return Z(this._dimNameMap.get(e),-1)},e.prototype.getSourceDimension=function(e){var t=this.source.dimensionsDefine;if(t)return t[e]},e.prototype.makeStoreSchema=function(){for(var e=this._fullDimCount,t=HD(this.source),n=!xN(e),r=``,i=[],a=0,o=0;a<e;a++){var s=void 0,c=void 0,l=void 0,u=this.dimensions[o];if(u&&u.storeDimIndex===a)s=t?u.name:null,c=u.type,l=u.ordinalMeta,o++;else{var d=this.getSourceDimension(a);d&&(s=t?d.name:null,c=d.type)}i.push({property:s,type:c,ordinalMeta:l}),!t||s==null||u&&u.isCalculationCoord||(r+=n?s.replace(/\`/g,"`1").replace(/\$/g,"`2"):s),r+=`$`,r+=gN[c]||`f`,l&&(r+=l.uid),r+=`$`}var f=this.source;return{dimensions:i,hash:[f.seriesLayoutBy,f.startIndex,r].join(`$$`)}},e.prototype.makeOutputDimensionNames=function(){for(var e=[],t=0,n=0;t<this._fullDimCount;t++){var r=void 0,i=this.dimensions[n];if(i&&i.storeDimIndex===t)i.isCalculationCoord||(r=i.name),n++;else{var a=this.getSourceDimension(t);a&&(r=a.name)}e.push(r)}return e},e.prototype.appendCalculationDimension=function(e){this.dimensions.push(e),e.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},e}();function vN(e){return e instanceof _N}function yN(e){for(var t=Q(),n=0;n<(e||[]).length;n++){var r=e[n],i=X(r)?r.name:r;i!=null&&t.get(i)==null&&t.set(i,n)}return t}function bN(e){var t=hN(e);return t.dimNameMap||=yN(e.dimensionsDefine)}function xN(e){return e>30}var SN=X,CN=$f,wN=typeof Int32Array>`u`?Array:Int32Array,TN=`e\0\0`,EN=-1,DN=[`hasItemOption`,`_nameList`,`_idList`,`_invertedIndicesMap`,`_dimSummary`,`userOutput`,`_rawData`,`_dimValueGetter`,`_nameDimIdx`,`_idDimIdx`,`_nameRepeatCount`],ON=[`_approximateExtent`],kN,AN,jN,MN,NN,PN,FN,IN=function(){function e(e,t){this.type=`list`,this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=[`cloneShallow`,`downSample`,`minmaxDownSample`,`lttbDownSample`,`map`],this.CHANGABLE_METHODS=[`filterSelf`,`selectRange`],this.DOWNSAMPLE_METHODS=[`downSample`,`minmaxDownSample`,`lttbDownSample`];var n,r=!1;vN(e)?(n=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(r=!0,n=e),n||=[`x`,`y`];for(var i={},a=[],o={},s=!1,c={},l=0;l<n.length;l++){var u=n[l],d=Y(u)?new mN({name:u}):u instanceof mN?u:new mN(u),f=d.name;d.type=d.type||`float`,d.coordDim||(d.coordDim=f,d.coordDimIndex=0);var p=d.otherDims=d.otherDims||{};a.push(f),i[f]=d,c[f]!=null&&(s=!0),d.createInvertedIndices&&(o[f]=[]),p.itemName===0&&(this._nameDimIdx=l),p.itemId===0&&(this._idDimIdx=l),r&&(d.storeDimIndex=l)}if(this.dimensions=a,this._dimInfos=i,this._initGetDimensionInfo(s),this.hostModel=t,this._invertedIndicesMap=o,this._dimOmitted){var m=this._dimIdxToName=Q();q(a,function(e){m.set(i[e].storeDimIndex,e)})}}return e.prototype.getDimension=function(e){var t=this._recognizeDimIndex(e);if(t==null)return e;if(t=e,!this._dimOmitted)return this.dimensions[t];var n=this._dimIdxToName.get(t);if(n!=null)return n;var r=this._schema.getSourceDimension(t);if(r)return r.name},e.prototype.getDimensionIndex=function(e){var t=this._recognizeDimIndex(e);if(t!=null)return t;if(e==null)return-1;var n=this._getDimInfo(e);return n?n.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(e):-1},e.prototype._recognizeDimIndex=function(e){if(cp(e)||e!=null&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(e)<0))return+e},e.prototype._getStoreDimIndex=function(e){return this.getDimensionIndex(e)},e.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},e.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(e){return t.hasOwnProperty(e)?t[e]:void 0}:function(e){return t[e]}},e.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},e.prototype.mapDimension=function(e,t){var n=this._dimSummary;if(t==null)return n.encodeFirstDimNotExtra[e];var r=n.encode[e];return r?r[t]:null},e.prototype.mapDimensionsAll=function(e){return(this._dimSummary.encode[e]||[]).slice()},e.prototype.getStore=function(){return this._store},e.prototype.initData=function(e,t,n){var r=this,i;if(e instanceof LO&&(i=e),!i){var a=this.dimensions,o=ND(e)||Qf(e)?new JD(e,a.length):e;i=new LO;var s=CN(a,function(e){return{type:r._dimInfos[e].type,property:e}});i.initData(o,s,n)}this._store=i,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,i.count()),this._dimSummary=uN(this,this._schema),this.userOutput=this._dimSummary.userOutput},e.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},e.prototype.appendValues=function(e,t){var n=this._store.appendValues(e,t&&t.length),r=n.start,i=n.end,a=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var o=r;o<i;o++){var s=o-r;this._nameList[o]=t[s],a&&FN(this,o)}},e.prototype._updateOrdinalMeta=function(){for(var e=this._store,t=this.dimensions,n=0;n<t.length;n++){var r=this._dimInfos[t[n]];r.ordinalMeta&&e.collectOrdinalMeta(r.storeDimIndex,r.ordinalMeta)}},e.prototype._shouldMakeIdFromName=function(){var e=this._store.getProvider();return this._idDimIdx==null&&e.getSource().sourceFormat!==`typedArray`&&!e.fillStorage},e.prototype._doInit=function(e,t){if(!(e>=t)){var n=this._store.getProvider();this._updateOrdinalMeta();var r=this._nameList,i=this._idList;if(n.getSource().sourceFormat===`original`&&!n.pure)for(var a=[],o=e;o<t;o++){var s=n.getItem(o,a);if(!this.hasItemOption&&Av(s)&&(this.hasItemOption=!0),s){var c=s.name;r[o]==null&&c!=null&&(r[o]=Bv(c,null));var l=s.id;i[o]==null&&l!=null&&(i[o]=Bv(l,null))}}if(this._shouldMakeIdFromName())for(var o=e;o<t;o++)FN(this,o);kN(this)}},e.prototype.getApproximateExtent=function(e){return this._approximateExtent[e]||this._store.getDataExtent(this._getStoreDimIndex(e))},e.prototype.setApproximateExtent=function(e,t){t=this.getDimension(t),this._approximateExtent[t]=e.slice()},e.prototype.getCalculationInfo=function(e){return this._calculationInfo[e]},e.prototype.setCalculationInfo=function(e,t){SN(e)?K(this._calculationInfo,e):this._calculationInfo[e]=t},e.prototype.getName=function(e){var t=this.getRawIndex(e),n=this._nameList[t];return n==null&&this._nameDimIdx!=null&&(n=jN(this,this._nameDimIdx,t)),n??=``,n},e.prototype._getCategory=function(e,t){var n=this._store.get(e,t),r=this._store.getOrdinalMeta(e);return r?r.categories[n]:n},e.prototype.getId=function(e){return AN(this,this.getRawIndex(e))},e.prototype.count=function(){return this._store.count()},e.prototype.get=function(e,t){var n=this._store,r=this._dimInfos[e];if(r)return n.get(r.storeDimIndex,t)},e.prototype.getByRawIndex=function(e,t){var n=this._store,r=this._dimInfos[e];if(r)return n.getByRawIndex(r.storeDimIndex,t)},e.prototype.getIndices=function(){return this._store.getIndices()},e.prototype.getDataExtent=function(e){return this._store.getDataExtent(this._getStoreDimIndex(e))},e.prototype.getSum=function(e){return this._store.getSum(this._getStoreDimIndex(e))},e.prototype.getMedian=function(e){return this._store.getMedian(this._getStoreDimIndex(e))},e.prototype.getValues=function(e,t){var n=this,r=this._store;return J(e)?r.getValues(CN(e,function(e){return n._getStoreDimIndex(e)}),t):r.getValues(e)},e.prototype.hasValue=function(e){for(var t=this._dimSummary.dataDimIndicesOnCoord,n=0,r=t.length;n<r;n++)if(isNaN(this._store.get(t[n],e)))return!1;return!0},e.prototype.indexOfName=function(e){for(var t=0,n=this._store.count();t<n;t++)if(this.getName(t)===e)return t;return-1},e.prototype.getRawIndex=function(e){return this._store.getRawIndex(e)},e.prototype.indexOfRawIndex=function(e){return this._store.indexOfRawIndex(e)},e.prototype.rawIndexOf=function(e,t){var n=e&&this._invertedIndicesMap[e],r=n&&n[t];return r==null||isNaN(r)?EN:r},e.prototype.indicesOfNearest=function(e,t,n){return this._store.indicesOfNearest(this._getStoreDimIndex(e),t,n)},e.prototype.each=function(e,t,n){op(e)&&(n=t,t=e,e=[]);var r=n||this,i=CN(MN(e),this._getStoreDimIndex,this);this._store.each(i,r?ip(t,r):t)},e.prototype.filterSelf=function(e,t,n){op(e)&&(n=t,t=e,e=[]);var r=n||this,i=CN(MN(e),this._getStoreDimIndex,this);return this._store=this._store.filter(i,r?ip(t,r):t),this},e.prototype.selectRange=function(e){var t=this,n={},r=np(e),i=[];return q(r,function(r){var a=t._getStoreDimIndex(r);n[a]=e[r],i.push(a)}),this._store=this._store.selectRange(n),this},e.prototype.mapArray=function(e,t,n){op(e)&&(n=t,t=e,e=[]),n||=this;var r=[];return this.each(e,function(){r.push(t&&t.apply(this,arguments))},n),r},e.prototype.map=function(e,t,n,r){var i=n||r||this,a=CN(MN(e),this._getStoreDimIndex,this),o=PN(this);return o._store=this._store.map(a,i?ip(t,i):t),o},e.prototype.modify=function(e,t,n,r){var i=n||r||this,a=CN(MN(e),this._getStoreDimIndex,this);this._store.modify(a,i?ip(t,i):t)},e.prototype.downSample=function(e,t,n,r){var i=PN(this);return i._store=this._store.downSample(this._getStoreDimIndex(e),t,n,r),i},e.prototype.minmaxDownSample=function(e,t){var n=PN(this);return n._store=this._store.minmaxDownSample(this._getStoreDimIndex(e),t),n},e.prototype.lttbDownSample=function(e,t){var n=PN(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(e),t),n},e.prototype.getRawDataItem=function(e){return this._store.getRawDataItem(e)},e.prototype.getItemModel=function(e){var t=this.hostModel;return new dT(this.getRawDataItem(e),t,t&&t.ecModel)},e.prototype.diff=function(e){var t=this;return new cN(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(t){return AN(e,t)},function(e){return AN(t,e)})},e.prototype.getVisual=function(e){var t=this._visual;return t&&t[e]},e.prototype.setVisual=function(e,t){this._visual=this._visual||{},SN(e)?K(this._visual,e):this._visual[e]=t},e.prototype.getItemVisual=function(e,t){var n=this._itemVisuals[e];return(n&&n[t])??this.getVisual(t)},e.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},e.prototype.ensureUniqueItemVisual=function(e,t){var n=this._itemVisuals,r=n[e];r||=n[e]={};var i=r[t];return i??(i=this.getVisual(t),J(i)?i=i.slice():SN(i)&&(i=K({},i)),r[t]=i),i},e.prototype.setItemVisual=function(e,t,n){var r=this._itemVisuals[e]||{};this._itemVisuals[e]=r,SN(t)?K(r,t):r[t]=n},e.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},e.prototype.setLayout=function(e,t){SN(e)?K(this._layout,e):this._layout[e]=t},e.prototype.getLayout=function(e){return this._layout[e]},e.prototype.getItemLayout=function(e){return this._itemLayouts[e]},e.prototype.setItemLayout=function(e,t,n){this._itemLayouts[e]=n?K(this._itemLayouts[e]||{},t):t},e.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},e.prototype.setItemGraphicEl=function(e,t){jx(this.hostModel&&this.hostModel.seriesIndex,this.dataType,e,t),this._graphicEls[e]=t},e.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},e.prototype.eachItemGraphicEl=function(e,t){q(this._graphicEls,function(n,r){n&&e&&e.call(t,n,r)})},e.prototype.cloneShallow=function(t){return t||=new e(this._schema?this._schema:CN(this.dimensions,this._getDimInfo,this),this.hostModel),NN(t,this),t._store=this._store,t},e.prototype.wrapMethod=function(e,t){var n=this[e];op(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var e=n.apply(this,arguments);return t.apply(this,[e].concat(_p(arguments)))})},e.internalField=function(){kN=function(e){var t=e._invertedIndicesMap;q(t,function(n,r){var i=e._dimInfos[r],a=i.ordinalMeta,o=e._store;if(a){n=t[r]=new wN(a.categories.length);for(var s=0;s<n.length;s++)n[s]=EN;for(var s=0;s<o.count();s++)n[o.get(i.storeDimIndex,s)]=s}})},jN=function(e,t,n){return Bv(e._getCategory(t,n),null)},AN=function(e,t){var n=e._idList[t];return n==null&&e._idDimIdx!=null&&(n=jN(e,e._idDimIdx,t)),n??=TN+t,n},MN=function(e){return J(e)||(e=e==null?[]:[e]),e},PN=function(t){var n=new e(t._schema?t._schema:CN(t.dimensions,t._getDimInfo,t),t.hostModel);return NN(n,t),n},NN=function(e,t){q(DN.concat(t.__wrappedMethods||[]),function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e.__wrappedMethods=t.__wrappedMethods,q(ON,function(n){e[n]=G(t[n])}),e._calculationInfo=K({},t._calculationInfo)},FN=function(e,t){var n=e._nameList,r=e._idList,i=e._nameDimIdx,a=e._idDimIdx,o=n[t],s=r[t];if(o==null&&i!=null&&(n[t]=o=jN(e,i,t)),s==null&&a!=null&&(r[t]=s=jN(e,a,t)),s==null&&o!=null){var c=e._nameRepeatCount,l=c[o]=(c[o]||0)+1;s=o,l>1&&(s+=`__ec__`+l),r[t]=s}}}(),e}();function LN(e,t){ND(e)||(e=FD(e)),t||={};var n=t.coordDimensions||[],r=t.dimensionsDefine||e.dimensionsDefine||[],i=Q(),a=[],o=zN(e,n,r,t.dimensionsCount),s=t.canOmitUnusedDimensions&&xN(o),c=r===e.dimensionsDefine,l=c?bN(e):yN(r),u=t.encodeDefine;!u&&t.encodeDefaulter&&(u=t.encodeDefaulter(e,o));for(var d=Q(u),f=new kO(o),p=0;p<f.length;p++)f[p]=-1;function m(e){var t=f[e];if(t<0){var n=r[e],i=X(n)?n:{name:n},o=new mN,s=i.name;return s!=null&&l.get(s)!=null&&(o.name=o.displayName=s),i.type!=null&&(o.type=i.type),i.displayName!=null&&(o.displayName=i.displayName),f[e]=a.length,o.storeDimIndex=e,a.push(o),o}return a[t]}if(!s)for(var p=0;p<o;p++)m(p);d.each(function(e,t){var n=Ev(e).slice();if(n.length===1&&!Y(n[0])&&n[0]<0)d.set(t,!1);else{var r=d.set(t,[]);q(n,function(e,n){var i=Y(e)?l.get(e):e;i!=null&&i<o&&(r[n]=i,g(m(i),t,n))})}});var h=0;q(n,function(e){var t,n,r,i;if(Y(e))t=e,i={};else{i=e,t=i.name;var a=i.ordinalMeta;i.ordinalMeta=null,i=K({},i),i.ordinalMeta=a,n=i.dimsDef,r=i.otherDims,i.name=i.coordDim=i.coordDimIndex=i.dimsDef=i.otherDims=null}var s=d.get(t);if(s!==!1){if(s=Ev(s),!s.length)for(var l=0;l<(n&&n.length||1);l++){for(;h<o&&m(h).coordDim!=null;)h++;h<o&&s.push(h++)}q(s,function(e,a){var o=m(e);if(c&&i.type!=null&&(o.type=i.type),g(Jf(o,i),t,a),o.name==null&&n){var s=n[a];!X(s)&&(s={name:s}),o.name=o.displayName=s.name,o.defaultTooltip=s.defaultTooltip}r&&Jf(o.otherDims,r)})}});function g(e,t,n){mE.get(t)==null?(e.coordDim=t,e.coordDimIndex=n,i.set(t,!0)):e.otherDims[t]=n}var _=t.generateCoord,v=t.generateCoordCount,y=v!=null;v=_?v||1:0;var b=_||`value`;function x(e){e.name??=e.coordDim}if(s)q(a,function(e){x(e)}),a.sort(function(e,t){return e.storeDimIndex-t.storeDimIndex});else for(var S=0;S<o;S++){var C=m(S);C.coordDim??(C.coordDim=BN(b,i,y),C.coordDimIndex=0,(!_||v<=0)&&(C.isExtraCoord=!0),v--),x(C),C.type==null&&(OE(e,S)===SE.Must||C.isExtraCoord&&(C.otherDims.itemName!=null||C.otherDims.seriesName!=null))&&(C.type=`ordinal`)}return RN(a),new _N({source:e,dimensions:a,fullDimensionCount:o,dimensionOmitted:s})}function RN(e){for(var t=Q(),n=0;n<e.length;n++){var r=e[n],i=r.name,a=t.get(i)||0;a>0&&(r.name=i+(a-1)),a++,t.set(i,a)}}function zN(e,t,n,r){var i=Math.max(e.dimensionsDetectedCount||1,t.length,n.length,r||0);return q(t,function(e){var t;X(e)&&(t=e.dimsDef)&&(i=Math.max(i,t.length))}),i}function BN(e,t,n){if(n||t.hasKey(e)){for(var r=0;t.hasKey(e+r);)r++;e+=r}return t.set(e,!0),e}var VN=function(){function e(e){this.coordSysDims=[],this.axisMap=Q(),this.categoryAxisMap=Q(),this.coordSysName=e}return e}();function HN(e){var t=e.get(`coordinateSystem`),n=new VN(t),r=UN[t];if(r)return r(e,n,n.axisMap,n.categoryAxisMap),n}var UN={cartesian2d:function(e,t,n,r){var i=e.getReferringComponents(`xAxis`,Xv).models[0],a=e.getReferringComponents(`yAxis`,Xv).models[0];t.coordSysDims=[`x`,`y`],n.set(`x`,i),n.set(`y`,a),WN(i)&&(r.set(`x`,i),t.firstCategoryDimIndex=0),WN(a)&&(r.set(`y`,a),t.firstCategoryDimIndex??=1)},singleAxis:function(e,t,n,r){var i=e.getReferringComponents(`singleAxis`,Xv).models[0];t.coordSysDims=[`single`],n.set(`single`,i),WN(i)&&(r.set(`single`,i),t.firstCategoryDimIndex=0)},polar:function(e,t,n,r){var i=e.getReferringComponents(`polar`,Xv).models[0],a=i.findAxisModel(`radiusAxis`),o=i.findAxisModel(`angleAxis`);t.coordSysDims=[`radius`,`angle`],n.set(`radius`,a),n.set(`angle`,o),WN(a)&&(r.set(`radius`,a),t.firstCategoryDimIndex=0),WN(o)&&(r.set(`angle`,o),t.firstCategoryDimIndex??=1)},geo:function(e,t,n,r){t.coordSysDims=[`lng`,`lat`]},parallel:function(e,t,n,r){var i=e.ecModel,a=i.getComponent(`parallel`,e.get(`parallelIndex`)),o=t.coordSysDims=a.dimensions.slice();q(a.parallelAxisIndex,function(e,a){var s=i.getComponent(`parallelAxis`,e),c=o[a];n.set(c,s),WN(s)&&(r.set(c,s),t.firstCategoryDimIndex??=a)})}};function WN(e){return e.get(`type`)===`category`}function GN(e,t,n){n||={};var r=n.byIndex,i=n.stackedCoordDimension,a,o,s;KN(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var c=!!(e&&e.get(`stack`)),l,u,d,f;if(q(a,function(e,t){Y(e)&&(a[t]=e={name:e}),c&&!e.isExtraCoord&&(!r&&!l&&e.ordinalMeta&&(l=e),u||e.type===`ordinal`||e.type===`time`||i&&i!==e.coordDim||(u=e))}),u&&!r&&!l&&(r=!0),u){d=`__\0ecstackresult_`+e.id,f=`__\0ecstackedover_`+e.id,l&&(l.createInvertedIndices=!0);var p=u.coordDim,m=u.type,h=0;q(a,function(e){e.coordDim===p&&h++});var g={name:d,coordDim:p,coordDimIndex:h,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},_={name:f,coordDim:f,coordDimIndex:h+1,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(g.storeDimIndex=s.ensureCalculationDimension(f,m),_.storeDimIndex=s.ensureCalculationDimension(d,m)),o.appendCalculationDimension(g),o.appendCalculationDimension(_)):(a.push(g),a.push(_))}return{stackedDimension:u&&u.name,stackedByDimension:l&&l.name,isStackedByIndex:r,stackedOverDimension:f,stackResultDimension:d}}function KN(e){return!vN(e.schema)}function qN(e,t){var n=e.get(`coordinateSystem`),r=$E.get(n),i;return t&&t.coordSysDims&&(i=$f(t.coordSysDims,function(e){var n={name:e},r=t.axisMap.get(e);return r&&(n.type=fN(r.get(`type`))),n})),i||=r&&(r.getDimensionsInfo?r.getDimensionsInfo():r.dimensions.slice())||[`x`,`y`],i}function JN(e,t,n){var r,i;return n&&q(e,function(e,a){var o=e.coordDim,s=n.categoryAxisMap.get(o);s&&(r??=a,e.ordinalMeta=s.getOrdinalMeta(),t&&(e.createInvertedIndices=!0)),e.otherDims.itemName!=null&&(i=!0)}),!i&&r!=null&&(e[r].otherDims.itemName=0),r}function YN(e,t,n){n||={};var r=t.getSourceManager(),i,a=!1;e?(a=!0,i=FD(e)):(i=r.getSource(),a=i.sourceFormat===hE);var o=HN(t),s=qN(t,o),c=n.useEncodeDefaulter,l=op(c)?c:c?ap(TE,s,t):null,u={coordDimensions:s,generateCoord:n.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:l,canOmitUnusedDimensions:!a},d=LN(i,u),f=JN(d.dimensions,n.createInvertedIndices,o),p=a?null:r.getSharedDataStore(d),m=GN(t,{schema:d,store:p}),h=new IN(d,t);h.setCalculationInfo(m);var g=f!=null&&XN(i)?function(e,t,n,r){return r===f?n:this.defaultDimValueGetter(e,t,n,r)}:null;return h.hasItemOption=!1,h.initData(a?i:p,null,g),h}function XN(e){if(e.sourceFormat===`original`)return!J(kv(ZN(e.data||[])))}function ZN(e){for(var t=0;t<e.length&&e[t]==null;)t++;return e[t]}function QN(e,t){return e.type===`category`?e.scale.getLabel(t):t.value}function $N(e){return e.get(`interval`)??`auto`}function eP(e){return e.type===`category`&&$N(e.getLabelModel())===0}var tP=[],nP={registerPreprocessor:KM,registerProcessor:qM,registerPostInit:JM,registerPostUpdate:YM,registerUpdateLifecycle:XM,registerAction:ZM,registerCoordinateSystem:QM,registerLayout:$M,registerVisual:eN,registerTransform:aN,registerLoading:rN,registerMap:iN,registerImpl:Nj,PRIORITY:Zj,ComponentModel:lE,ComponentView:xk,SeriesModel:fk,ChartView:Tk,registerComponentModel:function(e){lE.registerClass(e)},registerComponentView:function(e){xk.registerClass(e)},registerSeriesModel:function(e){fk.registerClass(e)},registerChartView:function(e){Tk.registerClass(e)},registerSubTypeDefaulter:function(e,t){lE.registerSubTypeDefaulter(e,t)},registerPainter:function(e,t){iv(e,t)}};function rP(e){J(e)?q(e,function(e){rP(e)}):Yf(tP,e)>=0||(tP.push(e),op(e)&&(e={install:e}),e.install(nP))}function iP(e){for(var t=[],n=0;n<e.length;n++){var r=e[n];if(!r.defaultAttr.ignore){var i=r.label,a=i.getComputedTransform(),o=i.getBoundingRect(),s=!a||a[1]<1e-5&&a[2]<1e-5,c=i.style.margin||0,l=o.clone();l.applyTransform(a),l.x-=c/2,l.y-=c/2,l.width+=c,l.height+=c;var u=s?new JC(o,a):null;t.push({label:i,labelLine:r.labelLine,rect:l,localRect:o,obb:u,priority:r.priority,defaultAttr:r.defaultAttr,layoutOption:r.computedLayoutOption,axisAligned:s,transform:a})}}return t}function aP(e){var t=[];e.sort(function(e,t){return t.priority-e.priority});var n=new $(0,0,0,0);function r(e){if(!e.ignore){var t=e.ensureState(`emphasis`);t.ignore??=!1}e.ignore=!0}for(var i=0;i<e.length;i++){var a=e[i],o=a.axisAligned,s=a.localRect,c=a.transform,l=a.label,u=a.labelLine;n.copy(a.rect),n.width-=.1,n.height-=.1,n.x+=.05,n.y+=.05;for(var d=a.obb,f=!1,p=0;p<t.length;p++){var m=t[p];if(n.intersect(m.rect)&&(o&&m.axisAligned||(m.obb||=new JC(m.localRect,m.transform),d||=new JC(s,c),d.intersect(m.obb)))){f=!0;break}}f?(r(l),u&&r(u)):(l.attr(`ignore`,a.defaultAttr.ignore),u&&u.attr(`ignore`,a.defaultAttr.labelGuideIgnore),t.push(a))}}function oP(e,t,n){n||={};var r=e.coordinateSystem,i=t.axis,a={},o=i.getAxesOnZeroOf()[0],s=i.position,c=o?`onZero`:s,l=i.dim,u=r.getRect(),d=[u.x,u.x+u.width,u.y,u.y+u.height],f={left:0,right:1,top:0,bottom:1,onZero:2},p=t.get(`offset`)||0,m=l===`x`?[d[2]-p,d[3]+p]:[d[0]-p,d[1]+p];if(o){var h=o.toGlobalCoord(o.dataToCoord(0));m[f.onZero]=Math.max(Math.min(h,m[1]),m[0])}a.position=[l===`y`?m[f[c]]:d[0],l===`x`?m[f[c]]:d[3]],a.rotation=Math.PI/2*(l===`x`?0:1),a.labelDirection=a.tickDirection=a.nameDirection={top:-1,bottom:1,left:-1,right:1}[s],a.labelOffset=o?m[f[s]]-m[f.onZero]:0,t.get([`axisTick`,`inside`])&&(a.tickDirection=-a.tickDirection),hp(n.labelInside,t.get([`axisLabel`,`inside`]))&&(a.labelDirection=-a.labelDirection);var g=t.get([`axisLabel`,`rotate`]);return a.labelRotate=c===`top`?-g:g,a.z2=1,a}var sP=Math.PI,cP=function(){function e(e,t){this.group=new Z_,this.opt=t,this.axisModel=e,Jf(t,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var n=new Z_({x:t.position[0],y:t.position[1],rotation:t.rotation});n.updateTransform(),this._transformGroup=n}return e.prototype.hasBuilder=function(e){return!!lP[e]},e.prototype.add=function(e){lP[e](this.opt,this.axisModel,this.group,this._transformGroup)},e.prototype.getGroup=function(){return this.group},e.innerTextLayout=function(e,t,n){var r=mv(t-e),i,a;return hv(r)?(a=n>0?`top`:`bottom`,i=`center`):hv(r-sP)?(a=n>0?`bottom`:`top`,i=`center`):(a=`middle`,i=r>0&&r<sP?n>0?`right`:`left`:n>0?`left`:`right`),{rotation:r,textAlign:i,textVerticalAlign:a}},e.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+`Index`]=e.componentIndex,t},e.isLabelSilent=function(e){var t=e.get(`tooltip`);return e.get(`silent`)||!(e.get(`triggerEvent`)||t&&t.show)},e}(),lP={axisLine:function(e,t,n,r){var i=t.get([`axisLine`,`show`]);if(i===`auto`&&e.handleAutoShown&&(i=e.handleAutoShown(`axisLine`)),i){var a=t.axis.getExtent(),o=r.transform,s=[a[0],0],c=[a[1],0],l=s[0]>c[0];o&&(Yp(s,s,o),Yp(c,c,o));var u=K({lineCap:`round`},t.getModel([`axisLine`,`lineStyle`]).getLineStyle()),d=new NC({shape:{x1:s[0],y1:s[1],x2:c[0],y2:c[1]},style:u,strokeContainThreshold:e.strokeContainThreshold||5,silent:!0,z2:1});xw(d.shape,d.style.lineWidth),d.anid=`line`,n.add(d);var f=t.get([`axisLine`,`symbol`]);if(f!=null){var p=t.get([`axisLine`,`symbolSize`]);Y(f)&&(f=[f,f]),(Y(p)||cp(p))&&(p=[p,p]);var m=LA(t.get([`axisLine`,`symbolOffset`])||0,p),h=p[0],g=p[1];q([{rotate:e.rotation+Math.PI/2,offset:m[0],r:0},{rotate:e.rotation-Math.PI/2,offset:m[1],r:Math.sqrt((s[0]-c[0])*(s[0]-c[0])+(s[1]-c[1])*(s[1]-c[1]))}],function(t,r){if(f[r]!==`none`&&f[r]!=null){var i=FA(f[r],-h/2,-g/2,h,g,u.stroke,!0),a=t.r+t.offset,o=l?c:s;i.attr({rotation:t.rotate,x:o[0]+a*Math.cos(e.rotation),y:o[1]-a*Math.sin(e.rotation),silent:!0,z2:11}),n.add(i)}})}}},axisTickLabel:function(e,t,n,r){var i=gP(n,r,t,e),a=vP(n,r,t,e);dP(t,a,i),_P(n,r,t,e.tickDirection),t.get([`axisLabel`,`hideOverlap`])&&aP(iP($f(a,function(e){return{label:e,priority:e.z2,defaultAttr:{ignore:e.ignore}}})))},axisName:function(e,t,n,r){var i=hp(e.axisName,t.get(`name`));if(i){var a=t.get(`nameLocation`),o=e.nameDirection,s=t.getModel(`nameTextStyle`),c=t.get(`nameGap`)||0,l=t.axis.getExtent(),u=l[0]>l[1]?-1:1,d=[a===`start`?l[0]-u*c:a===`end`?l[1]+u*c:(l[0]+l[1])/2,mP(a)?e.labelOffset+o*c:0],f,p=t.get(`nameRotate`);p!=null&&(p=p*sP/180);var m;mP(a)?f=cP.innerTextLayout(e.rotation,p??e.rotation,o):(f=uP(e.rotation,a,p||0,l),m=e.axisNameAvailableWidth,m!=null&&(m=Math.abs(m/Math.sin(f.rotation)),!isFinite(m)&&(m=null)));var h=s.getFont(),g=t.get(`nameTruncate`,!0)||{},_=g.ellipsis,v=hp(e.nameTruncateMaxWidth,g.maxWidth,m),y=new hx({x:d[0],y:d[1],rotation:f.rotation,silent:cP.isLabelSilent(t),style:Gw(s,{text:i,font:h,overflow:`truncate`,width:v,ellipsis:_,fill:s.getTextColor()||t.get([`axisLine`,`lineStyle`,`color`]),align:s.get(`align`)||f.textAlign,verticalAlign:s.get(`verticalAlign`)||f.textVerticalAlign}),z2:1});if(Lw({el:y,componentModel:t,itemName:i}),y.__fullText=i,y.anid=`name`,t.get(`triggerEvent`)){var b=cP.makeAxisEventDataBase(t);b.targetType=`axisName`,b.name=i,Ax(y).eventData=b}r.add(y),y.updateTransform(),n.add(y),y.decomposeTransform()}}};function uP(e,t,n,r){var i=mv(n-e),a,o,s=r[0]>r[1],c=t===`start`&&!s||t!==`start`&&s;return hv(i-sP/2)?(o=c?`bottom`:`top`,a=`center`):hv(i-sP*1.5)?(o=c?`top`:`bottom`,a=`center`):(o=`middle`,a=i<sP*1.5&&i>sP/2?c?`left`:`right`:c?`right`:`left`),{rotation:i,textAlign:a,textVerticalAlign:o}}function dP(e,t,n){if(!eP(e.axis)){var r=e.get([`axisLabel`,`showMinLabel`]),i=e.get([`axisLabel`,`showMaxLabel`]);t||=[],n||=[];var a=t[0],o=t[1],s=t[t.length-1],c=t[t.length-2],l=n[0],u=n[1],d=n[n.length-1],f=n[n.length-2];r===!1?(fP(a),fP(l)):pP(a,o)&&(r?(fP(o),fP(u)):(fP(a),fP(l))),i===!1?(fP(s),fP(d)):pP(c,s)&&(i?(fP(c),fP(f)):(fP(s),fP(d)))}}function fP(e){e&&(e.ignore=!0)}function pP(e,t){var n=e&&e.getBoundingRect().clone(),r=t&&t.getBoundingRect().clone();if(n&&r){var i=jm([]);return Fm(i,i,-e.rotation),n.applyTransform(Nm([],i,e.getLocalTransform())),r.applyTransform(Nm([],i,t.getLocalTransform())),n.intersect(r)}}function mP(e){return e===`middle`||e===`center`}function hP(e,t,n,r,i){for(var a=[],o=[],s=[],c=0;c<e.length;c++){var l=e[c].coord;o[0]=l,o[1]=0,s[0]=l,s[1]=n,t&&(Yp(o,o,t),Yp(s,s,t));var u=new NC({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:r,z2:2,autoBatch:!0,silent:!0});xw(u.shape,u.style.lineWidth),u.anid=i+`_`+e[c].tickValue,a.push(u)}return a}function gP(e,t,n,r){var i=n.axis,a=n.getModel(`axisTick`),o=a.get(`show`);if(o===`auto`&&r.handleAutoShown&&(o=r.handleAutoShown(`axisTick`)),o&&!i.scale.isBlank()){for(var s=a.getModel(`lineStyle`),c=r.tickDirection*a.get(`length`),l=hP(i.getTicksCoords(),t.transform,c,Jf(s.getLineStyle(),{stroke:n.get([`axisLine`,`lineStyle`,`color`])}),`ticks`),u=0;u<l.length;u++)e.add(l[u]);return l}}function _P(e,t,n,r){var i=n.axis,a=n.getModel(`minorTick`);if(a.get(`show`)&&!i.scale.isBlank()){var o=i.getMinorTicksCoords();if(o.length)for(var s=a.getModel(`lineStyle`),c=r*a.get(`length`),l=Jf(s.getLineStyle(),Jf(n.getModel(`axisTick`).getLineStyle(),{stroke:n.get([`axisLine`,`lineStyle`,`color`])})),u=0;u<o.length;u++)for(var d=hP(o[u],t.transform,c,l,`minorticks_`+u),f=0;f<d.length;f++)e.add(d[f])}}function vP(e,t,n,r){var i=n.axis;if(hp(r.axisLabelShow,n.get([`axisLabel`,`show`]))&&!i.scale.isBlank()){var a=n.getModel(`axisLabel`),o=a.get(`margin`),s=i.getViewLabels(),c=(hp(r.labelRotate,a.get(`rotate`))||0)*sP/180,l=cP.innerTextLayout(r.rotation,c,r.labelDirection),u=n.getCategories&&n.getCategories(!0),d=[],f=cP.isLabelSilent(n),p=n.get(`triggerEvent`);return q(s,function(c,m){var h=i.scale.type===`ordinal`?i.scale.getRawOrdinalNumber(c.tickValue):c.tickValue,g=c.formattedLabel,_=c.rawLabel,v=a;if(u&&u[h]){var y=u[h];X(y)&&y.textStyle&&(v=new dT(y.textStyle,a,n.ecModel))}var b=v.getTextColor()||n.get([`axisLine`,`lineStyle`,`color`]),x=i.dataToCoord(h),S=v.getShallow(`align`,!0)||l.textAlign,C=Z(v.getShallow(`alignMinLabel`,!0),S),w=Z(v.getShallow(`alignMaxLabel`,!0),S),T=v.getShallow(`verticalAlign`,!0)||v.getShallow(`baseline`,!0)||l.textVerticalAlign,E=Z(v.getShallow(`verticalAlignMinLabel`,!0),T),D=Z(v.getShallow(`verticalAlignMaxLabel`,!0),T),O=new hx({x,y:r.labelOffset+r.labelDirection*o,rotation:l.rotation,silent:f,z2:10+(c.level||0),style:Gw(v,{text:g,align:m===0?C:m===s.length-1?w:S,verticalAlign:m===0?E:m===s.length-1?D:T,fill:op(b)?b(i.type===`category`?_:i.type===`value`?h+``:h,m):b})});if(O.anid=`label_`+h,Lw({el:O,componentModel:n,itemName:g,formatterParamsExtra:{isTruncated:function(){return O.isTruncated},value:_,tickIndex:m}}),p){var k=cP.makeAxisEventDataBase(n);k.targetType=`axisLabel`,k.value=_,k.tickIndex=m,i.type===`category`&&(k.dataIndex=h),Ax(O).eventData=k}t.add(O),O.updateTransform(),d.push(O),e.add(O),O.decomposeTransform()}),d}}function yP(e,t){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return bP(n,e,t),n.seriesInvolved&&SP(n,e),n}function bP(e,t,n){var r=t.getComponent(`tooltip`),i=t.getComponent(`axisPointer`),a=i.get(`link`,!0)||[],o=[];q(n.getCoordinateSystems(),function(n){if(!n.axisPointerEnabled)return;var s=kP(n.model),c=e.coordSysAxesInfo[s]={};e.coordSysMap[s]=n;var l=n.model.getModel(`tooltip`,r);if(q(n.getAxes(),ap(p,!1,null)),n.getTooltipAxes&&r&&l.get(`show`)){var u=l.get(`trigger`)===`axis`,d=l.get([`axisPointer`,`type`])===`cross`,f=n.getTooltipAxes(l.get([`axisPointer`,`axis`]));(u||d)&&q(f.baseAxes,ap(p,!d||`cross`,u)),d&&q(f.otherAxes,ap(p,`cross`,!1))}function p(r,s,u){var d=u.model.getModel(`axisPointer`,i),f=d.get(`show`);if(f&&(f!==`auto`||r||OP(d))){s??=d.get(`triggerTooltip`),d=r?xP(u,l,i,t,r,s):d;var p=d.get(`snap`),m=d.get(`triggerEmphasis`),h=kP(u.model),g=s||p||u.type===`category`,_=e.axesInfo[h]={key:h,axis:u,coordSys:n,axisPointerModel:d,triggerTooltip:s,triggerEmphasis:m,involveSeries:g,snap:p,useHandle:OP(d),seriesModels:[],linkGroup:null};c[h]=_,e.seriesInvolved=e.seriesInvolved||g;var v=CP(a,u);if(v!=null){var y=o[v]||(o[v]={axesInfo:{}});y.axesInfo[h]=_,y.mapper=a[v].mapper,_.linkGroup=y}}}})}function xP(e,t,n,r,i,a){var o=t.getModel(`axisPointer`),s=[`type`,`snap`,`lineStyle`,`shadowStyle`,`label`,`animation`,`animationDurationUpdate`,`animationEasingUpdate`,`z`],c={};q(s,function(e){c[e]=G(o.get(e))}),c.snap=e.type!==`category`&&!!a,o.get(`type`)===`cross`&&(c.type=`line`);var l=c.label||={};if(l.show??=!1,i===`cross`&&(l.show=o.get([`label`,`show`])??!0,!a)){var u=c.lineStyle=o.get(`crossStyle`);u&&Jf(l,u.textStyle)}return e.model.getModel(`axisPointer`,new dT(c,n,r))}function SP(e,t){t.eachSeries(function(t){var n=t.coordinateSystem,r=t.get([`tooltip`,`trigger`],!0),i=t.get([`tooltip`,`show`],!0);n&&r!==`none`&&r!==!1&&r!==`item`&&i!==!1&&t.get([`axisPointer`,`show`],!0)!==!1&&q(e.coordSysAxesInfo[kP(n.model)],function(e){var r=e.axis;n.getAxis(r.dim)===r&&(e.seriesModels.push(t),e.seriesDataCount??=0,e.seriesDataCount+=t.getData().count())})})}function CP(e,t){for(var n=t.model,r=t.dim,i=0;i<e.length;i++){var a=e[i]||{};if(wP(a[r+`AxisId`],n.id)||wP(a[r+`AxisIndex`],n.componentIndex)||wP(a[r+`AxisName`],n.name))return i}}function wP(e,t){return e===`all`||J(e)&&Yf(e,t)>=0||e===t}function TP(e){var t=EP(e);if(t){var n=t.axisPointerModel,r=t.axis.scale,i=n.option,a=n.get(`status`),o=n.get(`value`);o!=null&&(o=r.parse(o));var s=OP(n);a??(i.status=s?`show`:`hide`);var c=r.getExtent().slice();c[0]>c[1]&&c.reverse(),(o==null||o>c[1])&&(o=c[1]),o<c[0]&&(o=c[0]),i.value=o,s&&(i.status=t.axis.scale.isBlank()?`hide`:`show`)}}function EP(e){var t=(e.ecModel.getComponent(`axisPointer`)||{}).coordSysAxesInfo;return t&&t.axesInfo[kP(e)]}function DP(e){var t=EP(e);return t&&t.axisPointerModel}function OP(e){return!!e.get([`handle`,`show`])}function kP(e){return e.type+`||`+e.id}var AP={},jP=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.render=function(t,n,r,i){this.axisPointerClass&&TP(t),e.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,r,!0)},t.prototype.updateAxisPointer=function(e,t,n,r){this._doUpdateAxisPointerClass(e,n,!1)},t.prototype.remove=function(e,t){var n=this._axisPointer;n&&n.remove(t)},t.prototype.dispose=function(t,n){this._disposeAxisPointer(n),e.prototype.dispose.apply(this,arguments)},t.prototype._doUpdateAxisPointerClass=function(e,n,r){var i=t.getAxisPointerClass(this.axisPointerClass);if(i){var a=DP(e);a?(this._axisPointer||=new i).render(e,a,n,r):this._disposeAxisPointer(n)}},t.prototype._disposeAxisPointer=function(e){this._axisPointer&&this._axisPointer.dispose(e),this._axisPointer=null},t.registerAxisPointerClass=function(e,t){AP[e]=t},t.getAxisPointerClass=function(e){return e&&AP[e]},t.type=`axis`,t}(xk),MP=Kv(),NP=G,PP=ip,FP=function(){function e(){this._dragging=!1,this.animationThreshold=15}return e.prototype.render=function(e,t,n,r){var i=t.get(`value`),a=t.get(`status`);if(this._axisModel=e,this._axisPointerModel=t,this._api=n,r||this._lastValue!==i||this._lastStatus!==a){this._lastValue=i,this._lastStatus=a;var o=this._group,s=this._handle;if(!a||a===`hide`)o&&o.hide(),s&&s.hide();else{o&&o.show(),s&&s.show();var c={};this.makeElOption(c,i,e,t,n);var l=c.graphicKey;l!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=l;var u=this._moveAnimation=this.determineAnimation(e,t);if(!o)o=this._group=new Z_,this.createPointerEl(o,c,e,t),this.createLabelEl(o,c,e,t),n.getZr().add(o);else{var d=ap(IP,t,u);this.updatePointerEl(o,c,d),this.updateLabelEl(o,c,d,t)}BP(o,t,!0),this._renderHandle(i)}}},e.prototype.remove=function(e){this.clear(e)},e.prototype.dispose=function(e){this.clear(e)},e.prototype.determineAnimation=function(e,t){var n=t.get(`animation`),r=e.axis,i=r.type===`category`,a=t.get(`snap`);if(!a&&!i)return!1;if(n===`auto`||n==null){var o=this.animationThreshold;if(i&&r.getBandWidth()>o)return!0;if(a){var s=EP(e).seriesDataCount,c=r.getExtent();return Math.abs(c[0]-c[1])/s>o}return!1}return n===!0},e.prototype.makeElOption=function(e,t,n,r,i){},e.prototype.createPointerEl=function(e,t,n,r){var i=t.pointer;if(i){var a=MP(e).pointerEl=new sw[i.type](NP(t.pointer));e.add(a)}},e.prototype.createLabelEl=function(e,t,n,r){if(t.label){var i=MP(e).labelEl=new hx(NP(t.label));e.add(i),RP(i,r)}},e.prototype.updatePointerEl=function(e,t,n){var r=MP(e).pointerEl;r&&t.pointer&&(r.setStyle(t.pointer.style),n(r,{shape:t.pointer.shape}))},e.prototype.updateLabelEl=function(e,t,n,r){var i=MP(e).labelEl;i&&(i.setStyle(t.label.style),n(i,{x:t.label.x,y:t.label.y}),RP(i,r))},e.prototype._renderHandle=function(e){if(!this._dragging&&this.updateHandleTransform){var t=this._axisPointerModel,n=this._api.getZr(),r=this._handle,i=t.getModel(`handle`),a=t.get(`status`);if(!i.get(`show`)||!a||a===`hide`)r&&n.remove(r),this._handle=null;else{var o;this._handle||(o=!0,r=this._handle=Mw(i.get(`icon`),{cursor:`move`,draggable:!0,onmousemove:function(e){wm(e.event)},onmousedown:PP(this._onHandleDragMove,this,0,0),drift:PP(this._onHandleDragMove,this),ondragend:PP(this._onHandleDragEnd,this)}),n.add(r)),BP(r,t,!1),r.setStyle(i.getItemStyle(null,[`color`,`borderColor`,`borderWidth`,`opacity`,`shadowColor`,`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`]));var s=i.get(`size`);J(s)||(s=[s,s]),r.scaleX=s[0]/2,r.scaleY=s[1]/2,Fk(this,`_doDispatchAxisPointer`,i.get(`throttle`)||0,`fixRate`),this._moveHandleToValue(e,o)}}},e.prototype._moveHandleToValue=function(e,t){IP(this._axisPointerModel,!t&&this._moveAnimation,this._handle,zP(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},e.prototype._onHandleDragMove=function(e,t){var n=this._handle;if(n){this._dragging=!0;var r=this.updateHandleTransform(zP(n),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=r,n.stopAnimation(),n.attr(zP(r)),MP(n).lastProp=null,this._doDispatchAxisPointer()}},e.prototype._doDispatchAxisPointer=function(){if(this._handle){var e=this._payloadInfo,t=this._axisModel;this._api.dispatchAction({type:`updateAxisPointer`,x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:t.axis.dim,axisIndex:t.componentIndex}]})}},e.prototype._onHandleDragEnd=function(){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get(`value`);this._moveHandleToValue(e),this._api.dispatchAction({type:`hideTip`})}},e.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),n=this._group,r=this._handle;t&&n&&(this._lastGraphicKey=null,n&&t.remove(n),r&&t.remove(r),this._group=null,this._handle=null,this._payloadInfo=null),Ik(this,`_doDispatchAxisPointer`)},e.prototype.doClear=function(){},e.prototype.buildLabel=function(e,t,n){return n||=0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}},e}();function IP(e,t,n,r){LP(MP(n).lastProp,r)||(MP(n).lastProp=r,t?ew(n,r,e):(n.stopAnimation(),n.attr(r)))}function LP(e,t){if(X(e)&&X(t)){var n=!0;return q(t,function(t,r){n&&=LP(e[r],t)}),!!n}return e===t}function RP(e,t){e[t.get([`label`,`show`])?`show`:`hide`]()}function zP(e){return{x:e.x||0,y:e.y||0,rotation:e.rotation||0}}function BP(e,t,n){var r=t.get(`z`),i=t.get(`zlevel`);e&&e.traverse(function(e){e.type!==`group`&&(r!=null&&(e.z=r),i!=null&&(e.zlevel=i),e.silent=n)})}function VP(e){var t=e.get(`type`),n=e.getModel(t+`Style`),r;return t===`line`?(r=n.getLineStyle(),r.fill=null):t===`shadow`&&(r=n.getAreaStyle(),r.stroke=null),r}function HP(e,t,n,r,i){var a=WP(n.get(`value`),t.axis,t.ecModel,n.get(`seriesDataIndices`),{precision:n.get([`label`,`precision`]),formatter:n.get([`label`,`formatter`])}),o=n.getModel(`label`),s=HT(o.get(`padding`)||0),c=o.getFont(),l=M_(a,c),u=i.position,d=l.width+s[1]+s[3],f=l.height+s[0]+s[2],p=i.align;p===`right`&&(u[0]-=d),p===`center`&&(u[0]-=d/2);var m=i.verticalAlign;m===`bottom`&&(u[1]-=f),m===`middle`&&(u[1]-=f/2),UP(u,d,f,r);var h=o.get(`backgroundColor`);h&&h!==`auto`||(h=t.get([`axisLine`,`lineStyle`,`color`])),e.label={x:u[0],y:u[1],style:Gw(o,{text:a,font:c,fill:o.getTextColor(),padding:s,backgroundColor:h}),z2:10}}function UP(e,t,n,r){var i=r.getWidth(),a=r.getHeight();e[0]=Math.min(e[0]+t,i)-t,e[1]=Math.min(e[1]+n,a)-n,e[0]=Math.max(e[0],0),e[1]=Math.max(e[1],0)}function WP(e,t,n,r,i){e=t.scale.parse(e);var a=t.scale.getLabel({value:e},{precision:i.precision}),o=i.formatter;if(o){var s={value:QN(t,{value:e}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};q(r,function(e){var t=n.getSeriesByIndex(e.seriesIndex),r=e.dataIndexInside,i=t&&t.getDataParams(r);i&&s.seriesData.push(i)}),Y(o)?a=o.replace(`{value}`,a):op(o)&&(a=o(s))}return a}function GP(e,t,n){var r=Am();return Fm(r,r,n.rotation),Pm(r,r,n.position),Tw([e.dataToCoord(t),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],r)}function KP(e,t,n,r,i,a){var o=cP.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=i.get([`label`,`margin`]),HP(t,r,i,a,{position:GP(r.axis,e,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function qP(e,t,n){return n||=0,{x1:e[n],y1:e[1-n],x2:t[n],y2:t[1-n]}}function JP(e,t,n){return n||=0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}}var YP=function(e){U(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.makeElOption=function(e,t,n,r,i){var a=n.axis,o=a.grid,s=r.get(`type`),c=XP(o,a).getOtherAxis(a).getGlobalExtent(),l=a.toGlobalCoord(a.dataToCoord(t,!0));if(s&&s!==`none`){var u=VP(r),d=ZP[s](a,l,c);d.style=u,e.graphicKey=d.type,e.pointer=d}KP(t,e,oP(o.model,n),n,r,i)},t.prototype.getHandleTransform=function(e,t,n){var r=oP(t.axis.grid.model,t,{labelInside:!1});r.labelMargin=n.get([`handle`,`margin`]);var i=GP(t.axis,e,r);return{x:i[0],y:i[1],rotation:r.rotation+(r.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(e,t,n,r){var i=n.axis,a=i.grid,o=i.getGlobalExtent(!0),s=XP(a,i).getOtherAxis(i).getGlobalExtent(),c=i.dim===`x`?0:1,l=[e.x,e.y];l[c]+=t[c],l[c]=Math.min(o[1],l[c]),l[c]=Math.max(o[0],l[c]);var u=(s[1]+s[0])/2,d=[u,u];return d[c]=l[c],{x:l[0],y:l[1],rotation:e.rotation,cursorPoint:d,tooltipOption:[{verticalAlign:`middle`},{align:`center`}][c]}},t}(FP);function XP(e,t){var n={};return n[t.dim+`AxisIndex`]=t.index,e.getCartesian(n)}var ZP={line:function(e,t,n){return{type:`Line`,subPixelOptimize:!0,shape:qP([t,n[0]],[t,n[1]],QP(e))}},shadow:function(e,t,n){var r=Math.max(1,e.getBandWidth()),i=n[1]-n[0];return{type:`Rect`,shape:JP([t-r/2,n[0]],[r,i],QP(e))}}};function QP(e){return e.dim===`x`?0:1}var $P=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`axisPointer`,t.defaultOption={show:`auto`,z:50,type:`line`,snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:`#B9BEC9`,width:1,type:`dashed`},shadowStyle:{color:`rgba(210,219,238,0.2)`},label:{show:!0,formatter:null,precision:`auto`,margin:3,color:`#fff`,padding:[5,7,5,7],backgroundColor:`auto`,borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:`M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z`,size:45,margin:50,color:`#333`,shadowBlur:3,shadowColor:`#aaa`,shadowOffsetX:0,shadowOffsetY:2,throttle:40}},t}(lE),eF=Kv(),tF=q;function nF(e,t,n){if(!W.node){var r=t.getZr();eF(r).records||(eF(r).records={}),rF(r,t);var i=eF(r).records[e]||(eF(r).records[e]={});i.handler=n}}function rF(e,t){if(eF(e).initialized)return;eF(e).initialized=!0,n(`click`,ap(oF,`click`)),n(`mousemove`,ap(oF,`mousemove`)),n(`globalout`,aF);function n(n,r){e.on(n,function(n){var i=sF(t);tF(eF(e).records,function(e){e&&r(e,n,i.dispatchAction)}),iF(i.pendings,t)})}}function iF(e,t){var n=e.showTip.length,r=e.hideTip.length,i;n?i=e.showTip[n-1]:r&&(i=e.hideTip[r-1]),i&&(i.dispatchAction=null,t.dispatchAction(i))}function aF(e,t,n){e.handler(`leave`,null,n)}function oF(e,t,n,r){t.handler(e,n,r)}function sF(e){var t={showTip:[],hideTip:[]},n=function(r){var i=t[r.type];i?i.push(r):(r.dispatchAction=n,e.dispatchAction(r))};return{dispatchAction:n,pendings:t}}function cF(e,t){if(!W.node){var n=t.getZr();(eF(n).records||{})[e]&&(eF(n).records[e]=null)}}var lF=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.render=function(e,t,n){var r=t.getComponent(`tooltip`),i=e.get(`triggerOn`)||r&&r.get(`triggerOn`)||`mousemove|click`;nF(`axisPointer`,n,function(e,t,n){i!==`none`&&(e===`leave`||i.indexOf(e)>=0)&&n({type:`updateAxisPointer`,currTrigger:e,x:t&&t.offsetX,y:t&&t.offsetY})})},t.prototype.remove=function(e,t){cF(`axisPointer`,t)},t.prototype.dispose=function(e,t){cF(`axisPointer`,t)},t.type=`axisPointer`,t}(xk);function uF(e,t){var n=[],r=e.seriesIndex,i;if(r==null||!(i=t.getSeriesByIndex(r)))return{point:[]};var a=i.getData(),o=Gv(a,e);if(o==null||o<0||J(o))return{point:[]};var s=a.getItemGraphicEl(o),c=i.coordinateSystem;if(i.getTooltipPosition)n=i.getTooltipPosition(o)||[];else if(c&&c.dataToPoint){if(e.isStacked){var l=c.getBaseAxis(),u=c.getOtherAxis(l).dim,d=l.dim,f=+(u===`x`||u===`radius`),p=a.mapDimension(d),m=[];m[f]=a.get(p,o),m[1-f]=a.get(a.getCalculationInfo(`stackResultDimension`),o),n=c.dataToPoint(m)||[]}else n=c.dataToPoint(a.getValues($f(c.dimensions,function(e){return a.mapDimension(e)}),o))||[]}else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),n=[h.x+h.width/2,h.y+h.height/2]}return{point:n,el:s}}var dF=Kv();function fF(e,t,n){var r=e.currTrigger,i=[e.x,e.y],a=e,o=e.dispatchAction||ip(n.dispatchAction,n),s=t.getComponent(`axisPointer`).coordSysAxesInfo;if(s){SF(i)&&(i=uF({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var c=SF(i),l=a.axesInfo,u=s.axesInfo,d=r===`leave`||SF(i),f={},p={},m={list:[],map:{}},h={showPointer:ap(hF,p),showTooltip:ap(gF,m)};q(s.coordSysMap,function(e,t){var n=c||e.containPoint(i);q(s.coordSysAxesInfo[t],function(e,t){var r=e.axis,a=bF(l,e);if(!d&&n&&(!l||a)){var o=a&&a.value;o==null&&!c&&(o=r.pointToData(i)),o!=null&&pF(e,o,h,!1,f)}})});var g={};return q(u,function(e,t){var n=e.linkGroup;n&&!p[t]&&q(n.axesInfo,function(t,r){var i=p[r];if(t!==e&&i){var a=i.value;n.mapper&&(a=e.axis.scale.parse(n.mapper(a,xF(t),xF(e)))),g[e.key]=a}})}),q(g,function(e,t){pF(u[t],e,h,!0,f)}),_F(p,u,f),vF(m,i,e,o),yF(u,o,n),f}}function pF(e,t,n,r,i){var a=e.axis;if(!a.scale.isBlank()&&a.containData(t)){if(!e.involveSeries)n.showPointer(e,t);else{var o=mF(t,e),s=o.payloadBatch,c=o.snapToValue;s[0]&&i.seriesIndex==null&&K(i,s[0]),!r&&e.snap&&a.containData(c)&&c!=null&&(t=c),n.showPointer(e,t,s),n.showTooltip(e,o,c)}}}function mF(e,t){var n=t.axis,r=n.dim,i=e,a=[],o=Number.MAX_VALUE,s=-1;return q(t.seriesModels,function(t,c){var l=t.getData().mapDimensionsAll(r),u,d;if(t.getAxisTooltipData){var f=t.getAxisTooltipData(l,e,n);d=f.dataIndices,u=f.nestestValue}else{if(d=t.getData().indicesOfNearest(l[0],e,n.type===`category`?.5:null),!d.length)return;u=t.getData().get(l[0],d[0])}if(u!=null&&isFinite(u)){var p=e-u,m=Math.abs(p);m<=o&&((m<o||p>=0&&s<0)&&(o=m,s=p,i=u,a.length=0),q(d,function(e){a.push({seriesIndex:t.seriesIndex,dataIndexInside:e,dataIndex:t.getData().getRawIndex(e)})}))}}),{payloadBatch:a,snapToValue:i}}function hF(e,t,n,r){e[t.key]={value:n,payloadBatch:r}}function gF(e,t,n,r){var i=n.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(t.triggerTooltip&&i.length){var c=t.coordSys.model,l=kP(c),u=e.map[l];u||(u=e.map[l]={coordSysId:c.id,coordSysIndex:c.componentIndex,coordSysType:c.type,coordSysMainType:c.mainType,dataByAxis:[]},e.list.push(u)),u.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:r,valueLabelOpt:{precision:s.get([`label`,`precision`]),formatter:s.get([`label`,`formatter`])},seriesDataIndices:i.slice()})}}function _F(e,t,n){var r=n.axesInfo=[];q(t,function(t,n){var i=t.axisPointerModel.option,a=e[n];a?(!t.useHandle&&(i.status=`show`),i.value=a.value,i.seriesDataIndices=(a.payloadBatch||[]).slice()):!t.useHandle&&(i.status=`hide`),i.status===`show`&&r.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:i.value})})}function vF(e,t,n,r){if(SF(t)||!e.list.length)r({type:`hideTip`});else{var i=((e.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};r({type:`showTip`,escapeConnect:!0,x:t[0],y:t[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:i.dataIndexInside,dataIndex:i.dataIndex,seriesIndex:i.seriesIndex,dataByCoordSys:e.list})}}function yF(e,t,n){var r=n.getZr(),i=`axisPointerLastHighlights`,a=dF(r)[i]||{},o=dF(r)[i]={};q(e,function(e,t){var n=e.axisPointerModel.option;n.status===`show`&&e.triggerEmphasis&&q(n.seriesDataIndices,function(e){var t=e.seriesIndex+` | `+e.dataIndex;o[t]=e})});var s=[],c=[];q(a,function(e,t){!o[t]&&c.push(e)}),q(o,function(e,t){!a[t]&&s.push(e)}),c.length&&n.dispatchAction({type:`downplay`,escapeConnect:!0,notBlur:!0,batch:c}),s.length&&n.dispatchAction({type:`highlight`,escapeConnect:!0,notBlur:!0,batch:s})}function bF(e,t){for(var n=0;n<(e||[]).length;n++){var r=e[n];if(t.axis.dim===r.axisDim&&t.axis.model.componentIndex===r.axisIndex)return r}}function xF(e){var t=e.axis.model,n={},r=n.axisDim=e.axis.dim;return n.axisIndex=n[r+`AxisIndex`]=t.componentIndex,n.axisName=n[r+`AxisName`]=t.name,n.axisId=n[r+`AxisId`]=t.id,n}function SF(e){return!e||e[0]==null||isNaN(e[0])||e[1]==null||isNaN(e[1])}function CF(e){jP.registerAxisPointerClass(`CartesianAxisPointer`,YP),e.registerComponentModel($P),e.registerComponentView(lF),e.registerPreprocessor(function(e){if(e){e.axisPointer&&e.axisPointer.length!==0||(e.axisPointer={});var t=e.axisPointer.link;t&&!J(t)&&(e.axisPointer.link=[t])}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,function(e,t){e.getComponent(`axisPointer`).coordSysAxesInfo=yP(e,t)}),e.registerAction({type:`updateAxisPointer`,event:`updateAxisPointer`,update:`:updateAxisPointer`},fF)}var wF=Yp,TF=function(e){U(t,e);function t(t){var n=e.call(this)||this;return n.type=`view`,n.dimensions=[`x`,`y`],n._roamTransformable=new E_,n._rawTransformable=new E_,n.name=t,n}return t.prototype.setBoundingRect=function(e,t,n,r){return this._rect=new $(e,t,n,r),this._rect},t.prototype.getBoundingRect=function(){return this._rect},t.prototype.setViewRect=function(e,t,n,r){this._transformTo(e,t,n,r),this._viewRect=new $(e,t,n,r)},t.prototype._transformTo=function(e,t,n,r){var i=this.getBoundingRect(),a=this._rawTransformable;a.transform=i.calculateTransform(new $(e,t,n,r));var o=a.parent;a.parent=null,a.decomposeTransform(),a.parent=o,this._updateTransform()},t.prototype.setCenter=function(e,t){e&&(this._center=[lv(e[0],t.getWidth()),lv(e[1],t.getHeight())],this._updateCenterAndZoom())},t.prototype.setZoom=function(e){e||=1;var t=this.zoomLimit;t&&(t.max!=null&&(e=Math.min(t.max,e)),t.min!=null&&(e=Math.max(t.min,e))),this._zoom=e,this._updateCenterAndZoom()},t.prototype.getDefaultCenter=function(){var e=this.getBoundingRect();return[e.x+e.width/2,e.y+e.height/2]},t.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},t.prototype.getZoom=function(){return this._zoom||1},t.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},t.prototype._updateCenterAndZoom=function(){var e=this._rawTransformable.getLocalTransform(),t=this._roamTransformable,n=this.getDefaultCenter(),r=this.getCenter(),i=this.getZoom();r=Yp([],r,e),n=Yp([],n,e),t.originX=r[0],t.originY=r[1],t.x=n[0]-r[0],t.y=n[1]-r[1],t.scaleX=t.scaleY=i,this._updateTransform()},t.prototype._updateTransform=function(){var e=this._roamTransformable,t=this._rawTransformable;t.parent=e,e.updateTransform(),t.updateTransform(),Mm(this.transform||=[],t.transform||Am()),this._rawTransform=t.getLocalTransform(),this.invTransform=this.invTransform||[],Lm(this.invTransform,this.transform),this.decomposeTransform()},t.prototype.getTransformInfo=function(){var e=this._rawTransformable,t=this._roamTransformable,n=new E_;return n.transform=t.transform,n.decomposeTransform(),{roam:{x:n.x,y:n.y,scaleX:n.scaleX,scaleY:n.scaleY},raw:{x:e.x,y:e.y,scaleX:e.scaleX,scaleY:e.scaleY}}},t.prototype.getViewRect=function(){return this._viewRect},t.prototype.getViewRectAfterRoam=function(){var e=this.getBoundingRect().clone();return e.applyTransform(this.transform),e},t.prototype.dataToPoint=function(e,t,n){var r=t?this._rawTransform:this.transform;return n||=[],r?wF(n,e,r):Fp(n,e)},t.prototype.pointToData=function(e){var t=this.invTransform;return t?wF([],e,t):[e[0],e[1]]},t.prototype.convertToPixel=function(e,t,n){var r=EF(t);return r===this?r.dataToPoint(n):null},t.prototype.convertFromPixel=function(e,t,n){var r=EF(t);return r===this?r.pointToData(n):null},t.prototype.containPoint=function(e){return this.getViewRectAfterRoam().contain(e[0],e[1])},t.dimensions=[`x`,`y`],t}(E_);function EF(e){var t=e.seriesModel;return t?t.coordinateSystem:null}function DF(e,t){return e.pointToProjected?e.pointToProjected(t):e.pointToData(t)}function OF(e,t,n,r){var i=e.getZoom(),a=e.getCenter(),o=t.zoom,s=e.projectedToPoint?e.projectedToPoint(a):e.dataToPoint(a);if(t.dx!=null&&t.dy!=null&&(s[0]-=t.dx,s[1]-=t.dy,e.setCenter(DF(e,s),r)),o!=null){if(n){var c=n.min||0,l=n.max||1/0;o=Math.max(Math.min(i*o,l),c)/i}e.scaleX*=o,e.scaleY*=o;var u=(t.originX-e.x)*(o-1),d=(t.originY-e.y)*(o-1);e.x-=u,e.y-=d,e.updateTransform(),e.setCenter(DF(e,s),r),e.setZoom(o*i)}return{center:e.getCenter(),zoom:e.getZoom()}}var kF=`\0_ec_interaction_mutex`;function AF(e,t){return!!jF(e)[t]}function jF(e){return e[kF]||(e[kF]={})}ZM({type:`takeGlobalCursor`,event:`globalCursorTaken`,update:`update`},Mp);var MF=function(e){U(t,e);function t(t){var n=e.call(this)||this;n._zr=t;var r=ip(n._mousedownHandler,n),i=ip(n._mousemoveHandler,n),a=ip(n._mouseupHandler,n),o=ip(n._mousewheelHandler,n),s=ip(n._pinchHandler,n);return n.enable=function(e,n){this.disable(),this._opt=Jf(G(n)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e??=!0,(e===!0||e===`move`||e===`pan`)&&(t.on(`mousedown`,r),t.on(`mousemove`,i),t.on(`mouseup`,a)),(e===!0||e===`scale`||e===`zoom`)&&(t.on(`mousewheel`,o),t.on(`pinch`,s))},n.disable=function(){t.off(`mousedown`,r),t.off(`mousemove`,i),t.off(`mouseup`,a),t.off(`mousewheel`,o),t.off(`pinch`,s)},n}return t.prototype.isDragging=function(){return this._dragging},t.prototype.isPinching=function(){return this._pinching},t.prototype.setPointerChecker=function(e){this.pointerChecker=e},t.prototype.dispose=function(){this.disable()},t.prototype._mousedownHandler=function(e){if(!Tm(e)){for(var t=e.target;t;){if(t.draggable)return;t=t.__hostTarget||t.parent}var n=e.offsetX,r=e.offsetY;this.pointerChecker&&this.pointerChecker(e,n,r)&&(this._x=n,this._y=r,this._dragging=!0)}},t.prototype._mousemoveHandler=function(e){if(this._dragging&&FF(`moveOnMouseMove`,e,this._opt)&&e.gestureEvent!==`pinch`&&!AF(this._zr,`globalPan`)){var t=e.offsetX,n=e.offsetY,r=this._x,i=this._y,a=t-r,o=n-i;this._x=t,this._y=n,this._opt.preventDefaultMouseMove&&wm(e.event),PF(this,`pan`,`moveOnMouseMove`,e,{dx:a,dy:o,oldX:r,oldY:i,newX:t,newY:n,isAvailableBehavior:null})}},t.prototype._mouseupHandler=function(e){Tm(e)||(this._dragging=!1)},t.prototype._mousewheelHandler=function(e){var t=FF(`zoomOnMouseWheel`,e,this._opt),n=FF(`moveOnMouseWheel`,e,this._opt),r=e.wheelDelta,i=Math.abs(r),a=e.offsetX,o=e.offsetY;if(r!==0&&(t||n)){if(t){var s=i>3?1.4:i>1?1.2:1.1,c=r>0?s:1/s;NF(this,`zoom`,`zoomOnMouseWheel`,e,{scale:c,originX:a,originY:o,isAvailableBehavior:null})}if(n){var l=Math.abs(r),u=(r>0?1:-1)*(l>3?.4:l>1?.15:.05);NF(this,`scrollMove`,`moveOnMouseWheel`,e,{scrollDelta:u,originX:a,originY:o,isAvailableBehavior:null})}}},t.prototype._pinchHandler=function(e){if(!AF(this._zr,`globalPan`)){var t=e.pinchScale>1?1.1:1/1.1;NF(this,`zoom`,null,e,{scale:t,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},t}(em);function NF(e,t,n,r,i){e.pointerChecker&&e.pointerChecker(r,i.originX,i.originY)&&(wm(r.event),PF(e,t,n,r,i))}function PF(e,t,n,r,i){i.isAvailableBehavior=ip(FF,null,n,r),e.trigger(t,i)}function FF(e,t,n){var r=n[e];return!e||r&&(!Y(r)||t.event[r+`Key`])}function IF(e,t,n){var r=e.target;r.x+=t,r.y+=n,r.dirty()}function LF(e,t,n,r){var i=e.target,a=e.zoomLimit,o=e.zoom=e.zoom||1;if(o*=t,a){var s=a.min||0,c=a.max||1/0;o=Math.max(Math.min(c,o),s)}var l=o/e.zoom;e.zoom=o,i.x-=(n-i.x)*(l-1),i.y-=(r-i.y)*(l-1),i.scaleX*=l,i.scaleY*=l,i.dirty()}var RF={axisPointer:1,tooltip:1,brush:1};function zF(e,t,n){var r=t.getComponentByElement(e.topTarget),i=r&&r.coordinateSystem;return r&&r!==n&&!RF.hasOwnProperty(r.mainType)&&i&&i.model!==n}function BF(e,t){var n=HT(t.get(`padding`)),r=t.getItemStyle([`color`,`opacity`]);return r.fill=t.get(`backgroundColor`),e=new dx({shape:{x:e.x-n[3],y:e.y-n[0],width:e.width+n[1]+n[3],height:e.height+n[0]+n[2],r:t.get(`borderRadius`)},style:r,silent:!0,z2:-1}),e}var VF=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`tooltip`,t.dependencies=[`axisPointer`],t.defaultOption={z:60,show:!0,showContent:!0,trigger:`item`,triggerOn:`mousemove|click`,alwaysShowContent:!1,displayMode:`single`,renderMode:`auto`,confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:`#fff`,shadowBlur:10,shadowColor:`rgba(0, 0, 0, .2)`,shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:``,axisPointer:{type:`line`,axis:`auto`,animation:`auto`,animationDurationUpdate:200,animationEasingUpdate:`exponentialOut`,crossStyle:{color:`#999`,width:1,type:`dashed`,textStyle:{}}},textStyle:{color:`#666`,fontSize:14}},t}(lE);function HF(e){var t=e.get(`confine`);return t==null?e.get(`renderMode`)===`richText`:!!t}function UF(e){if(W.domSupported){for(var t=document.documentElement.style,n=0,r=e.length;n<r;n++)if(e[n]in t)return e[n]}}var WF=UF([`transform`,`webkitTransform`,`OTransform`,`MozTransform`,`msTransform`]),GF=UF([`webkitTransition`,`transition`,`OTransition`,`MozTransition`,`msTransition`]);function KF(e,t){if(!e)return t;t=VT(t,!0);var n=e.indexOf(t);return e=n===-1?t:`-`+e.slice(0,n)+`-`+t,e.toLowerCase()}function qF(e,t){var n=e.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(e);return n?t?n[t]:n:null}var JF=KF(GF,`transition`),YF=KF(WF,`transform`),XF=`position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;`+(W.transform3dSupported?`will-change:transform;`:``);function ZF(e){return e=e===`left`?`right`:e===`right`?`left`:e===`top`?`bottom`:`top`,e}function QF(e,t,n){if(!Y(n)||n===`inside`)return``;var r=e.get(`backgroundColor`),i=e.get(`borderWidth`);t=JT(t);var a=ZF(n),o=Math.max(Math.round(i)*1.5,6),s=``,c=YF+`:`,l;Yf([`left`,`right`],a)>-1?(s+=`top:50%`,c+=`translateY(-50%) rotate(`+(l=a===`left`?-225:-45)+`deg)`):(s+=`left:50%`,c+=`translateX(-50%) rotate(`+(l=a===`top`?225:45)+`deg)`);var u=l*Math.PI/180,d=o+i,f=d*Math.abs(Math.cos(u))+d*Math.abs(Math.sin(u)),p=Math.round(((f-Math.SQRT2*i)/2+Math.SQRT2*i-(f-d)/2)*100)/100;s+=`;`+a+`:-`+p+`px`;var m=t+` solid `+i+`px;`;return`<div style="`+[`position:absolute;width:`+o+`px;height:`+o+`px;z-index:-1;`,s+`;`+c+`;`,`border-bottom:`+m,`border-right:`+m,`background-color:`+r+`;`].join(``)+`"></div>`}function $F(e,t){var n=`cubic-bezier(0.23,1,0.32,1)`,r=` `+e/2+`s `+n,i=`opacity`+r+`,visibility`+r;return t||(r=` `+e+`s `+n,i+=W.transformSupported?`,`+YF+r:`,left`+r+`,top`+r),JF+`:`+i}function eI(e,t,n){var r=e.toFixed(0)+`px`,i=t.toFixed(0)+`px`;if(!W.transformSupported)return n?`top:`+i+`;left:`+r+`;`:[[`top`,i],[`left`,r]];var a=W.transform3dSupported,o=`translate`+(a?`3d`:``)+`(`+r+`,`+i+(a?`,0`:``)+`)`;return n?`top:0;left:0;`+YF+`:`+o+`;`:[[`top`,0],[`left`,0],[WF,o]]}function tI(e){var t=[],n=e.get(`fontSize`),r=e.getTextColor();r&&t.push(`color:`+r),t.push(`font:`+e.getFont());var i=Z(e.get(`lineHeight`),Math.round(n*3/2));n&&t.push(`line-height:`+i+`px`);var a=e.get(`textShadowColor`),o=e.get(`textShadowBlur`)||0,s=e.get(`textShadowOffsetX`)||0,c=e.get(`textShadowOffsetY`)||0;return a&&o&&t.push(`text-shadow:`+s+`px `+c+`px `+o+`px `+a),q([`decoration`,`align`],function(n){var r=e.get(n);r&&t.push(`text-`+n+`:`+r)}),t.join(`;`)}function nI(e,t,n){var r=[],i=e.get(`transitionDuration`),a=e.get(`backgroundColor`),o=e.get(`shadowBlur`),s=e.get(`shadowColor`),c=e.get(`shadowOffsetX`),l=e.get(`shadowOffsetY`),u=e.getModel(`textStyle`),d=ok(e,`html`),f=c+`px `+l+`px `+o+`px `+s;return r.push(`box-shadow:`+f),t&&i&&r.push($F(i,n)),a&&r.push(`background-color:`+a),q([`width`,`color`,`radius`],function(t){var n=`border-`+t,i=VT(n),a=e.get(i);a!=null&&r.push(n+`:`+a+(t===`color`?``:`px`))}),r.push(tI(u)),d!=null&&r.push(`padding:`+HT(d).join(`px `)+`px`),r.join(`;`)+`;`}function rI(e,t,n,r,i){var a=t&&t.painter;if(n){var o=a&&a.getViewportRoot();o&&om(e,o,n,r,i)}else{e[0]=r,e[1]=i;var s=a&&a.getViewportRootOffset();s&&(e[0]+=s.offsetLeft,e[1]+=s.offsetTop)}e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var iI=function(){function e(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,W.wxa)return null;var n=document.createElement(`div`);n.domBelongToZr=!0,this.el=n;var r=this._zr=e.getZr(),i=t.appendTo,a=i&&(Y(i)?document.querySelector(i):dp(i)?i:op(i)&&i(e.getDom()));rI(this._styleCoord,r,a,e.getWidth()/2,e.getHeight()/2),(a||e.getDom()).appendChild(n),this._api=e,this._container=a;var o=this;n.onmouseenter=function(){o._enterable&&(clearTimeout(o._hideTimeout),o._show=!0),o._inContent=!0},n.onmousemove=function(e){if(e||=window.event,!o._enterable){var t=r.handler;bm(r.painter.getViewportRoot(),e,!0),t.dispatch(`mousemove`,e)}},n.onmouseleave=function(){o._inContent=!1,o._enterable&&o._show&&o.hideLater(o._hideDelay)}}return e.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),n=qF(t,`position`),r=t.style;r.position!==`absolute`&&n!==`absolute`&&(r.position=`relative`)}var i=e.get(`alwaysShowContent`);i&&this._moveIfResized(),this._alwaysShowContent=i,this.el.className=e.get(`className`)||``},e.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,r=n.style,i=this._styleCoord;n.innerHTML?r.cssText=XF+nI(e,!this._firstShow,this._longHide)+eI(i[0],i[1],!0)+(`border-color:`+JT(t)+`;`)+(e.get(`extraCssText`)||``)+(`;pointer-events:`+(this._enterable?`auto`:`none`)):r.display=`none`,this._show=!0,this._firstShow=!1,this._longHide=!1},e.prototype.setContent=function(e,t,n,r,i){var a=this.el;if(e==null)a.innerHTML=``;else{var o=``;if(Y(i)&&n.get(`trigger`)===`item`&&!HF(n)&&(o=QF(n,r,i)),Y(e))a.innerHTML=e+o;else if(e){a.innerHTML=``,J(e)||(e=[e]);for(var s=0;s<e.length;s++)dp(e[s])&&e[s].parentNode!==a&&a.appendChild(e[s]);if(o&&a.childNodes.length){var c=document.createElement(`div`);c.innerHTML=o,a.appendChild(c)}}}},e.prototype.setEnterable=function(e){this._enterable=e},e.prototype.getSize=function(){var e=this.el;return e?[e.offsetWidth,e.offsetHeight]:[0,0]},e.prototype.moveTo=function(e,t){if(this.el){var n=this._styleCoord;if(rI(n,this._zr,this._container,e,t),n[0]!=null&&n[1]!=null){var r=this.el.style;q(eI(n[0],n[1]),function(e){r[e[0]]=e[1]})}}},e.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},e.prototype.hide=function(){var e=this,t=this.el.style;t.visibility=`hidden`,t.opacity=`0`,W.transform3dSupported&&(t.willChange=``),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},e.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(ip(this.hide,this),e)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var e=this.el.parentNode;e&&e.removeChild(this.el),this.el=this._container=null},e}(),aI=function(){function e(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),cI(this._styleCoord,this._zr,e.getWidth()/2,e.getHeight()/2)}return e.prototype.update=function(e){var t=e.get(`alwaysShowContent`);t&&this._moveIfResized(),this._alwaysShowContent=t},e.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},e.prototype.setContent=function(e,t,n,r,i){var a=this;X(e)&&Cv(``),this.el&&this._zr.remove(this.el);var o=n.getModel(`textStyle`);this.el=new hx({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:r,textShadowColor:o.get(`textShadowColor`),fill:n.get([`textStyle`,`color`]),padding:ok(n,`richText`),verticalAlign:`top`,align:`left`},z:n.get(`z`)}),q([`backgroundColor`,`borderRadius`,`shadowColor`,`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`],function(e){a.el.style[e]=n.get(e)}),q([`textShadowBlur`,`textShadowOffsetX`,`textShadowOffsetY`],function(e){a.el.style[e]=o.get(e)||0}),this._zr.add(this.el);var s=this;this.el.on(`mouseover`,function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0}),this.el.on(`mouseout`,function(){s._enterable&&s._show&&s.hideLater(s._hideDelay),s._inContent=!1})},e.prototype.setEnterable=function(e){this._enterable=e},e.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),n=sI(e.style);return[t.width+n.left+n.right,t.height+n.top+n.bottom]},e.prototype.moveTo=function(e,t){var n=this.el;if(n){var r=this._styleCoord;cI(r,this._zr,e,t),e=r[0],t=r[1];var i=n.style,a=oI(i.borderWidth||0),o=sI(i);n.x=e+a+o.left,n.y=t+a+o.top,n.markRedraw()}},e.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},e.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},e.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(ip(this.hide,this),e)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){this._zr.remove(this.el)},e}();function oI(e){return Math.max(0,e)}function sI(e){var t=oI(e.shadowBlur||0),n=oI(e.shadowOffsetX||0),r=oI(e.shadowOffsetY||0);return{left:oI(t-n),right:oI(t+n),top:oI(t-r),bottom:oI(t+r)}}function cI(e,t,n,r){e[0]=n,e[1]=r,e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var lI=new dx({shape:{x:-1,y:-1,width:2,height:2}}),uI=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.init=function(e,t){if(!W.node&&t.getDom()){var n=e.getComponent(`tooltip`),r=this._renderMode=ey(n.get(`renderMode`));this._tooltipContent=r===`richText`?new aI(t):new iI(t,{appendTo:n.get(`appendToBody`,!0)?`body`:n.get(`appendTo`,!0)})}},t.prototype.render=function(e,t,n){if(!W.node&&n.getDom()){this.group.removeAll(),this._tooltipModel=e,this._ecModel=t,this._api=n;var r=this._tooltipContent;r.update(e),r.setEnterable(e.get(`enterable`)),this._initGlobalListener(),this._keepShow(),this._renderMode!==`richText`&&e.get(`transitionDuration`)?Fk(this,`_updatePosition`,50,`fixRate`):Ik(this,`_updatePosition`)}},t.prototype._initGlobalListener=function(){var e=this._tooltipModel.get(`triggerOn`);nF(`itemTooltip`,this._api,ip(function(t,n,r){e!==`none`&&(e.indexOf(t)>=0?this._tryShow(n,r):t===`leave`&&this._hide(r))},this))},t.prototype._keepShow=function(){var e=this._tooltipModel,t=this._ecModel,n=this._api,r=e.get(`triggerOn`);if(this._lastX!=null&&this._lastY!=null&&r!==`none`&&r!==`click`){var i=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&i.manuallyShowTip(e,t,n,{x:i._lastX,y:i._lastY,dataByCoordSys:i._lastDataByCoordSys})})}},t.prototype.manuallyShowTip=function(e,t,n,r){if(r.from!==this.uid&&!W.node&&n.getDom()){var i=fI(r,n);this._ticket=``;var a=r.dataByCoordSys,o=_I(r,t,n);if(o){var s=o.el.getBoundingRect().clone();s.applyTransform(o.el.transform),this._tryShow({offsetX:s.x+s.width/2,offsetY:s.y+s.height/2,target:o.el,position:r.position,positionDefault:`bottom`},i)}else if(r.tooltip&&r.x!=null&&r.y!=null){var c=lI;c.x=r.x,c.y=r.y,c.update(),Ax(c).tooltipConfig={name:null,option:r.tooltip},this._tryShow({offsetX:r.x,offsetY:r.y,target:c},i)}else if(a)this._tryShow({offsetX:r.x,offsetY:r.y,position:r.position,dataByCoordSys:a,tooltipOption:r.tooltipOption},i);else if(r.seriesIndex!=null){if(this._manuallyAxisShowTip(e,t,n,r))return;var l=uF(r,t),u=l.point[0],d=l.point[1];u!=null&&d!=null&&this._tryShow({offsetX:u,offsetY:d,target:l.el,position:r.position,positionDefault:`bottom`},i)}else r.x!=null&&r.y!=null&&(n.dispatchAction({type:`updateAxisPointer`,x:r.x,y:r.y}),this._tryShow({offsetX:r.x,offsetY:r.y,position:r.position,target:n.getZr().findHover(r.x,r.y).target},i))}},t.prototype.manuallyHideTip=function(e,t,n,r){var i=this._tooltipContent;this._tooltipModel&&i.hideLater(this._tooltipModel.get(`hideDelay`)),this._lastX=this._lastY=this._lastDataByCoordSys=null,r.from!==this.uid&&this._hide(fI(r,n))},t.prototype._manuallyAxisShowTip=function(e,t,n,r){var i=r.seriesIndex,a=r.dataIndex,o=t.getComponent(`axisPointer`).coordSysAxesInfo;if(i!=null&&a!=null&&o!=null){var s=t.getSeriesByIndex(i);if(s&&dI([s.getData().getItemModel(a),s,(s.coordinateSystem||{}).model],this._tooltipModel).get(`trigger`)===`axis`)return n.dispatchAction({type:`updateAxisPointer`,seriesIndex:i,dataIndex:a,position:r.position}),!0}},t.prototype._tryShow=function(e,t){var n=e.target;if(this._tooltipModel){this._lastX=e.offsetX,this._lastY=e.offsetY;var r=e.dataByCoordSys;if(r&&r.length)this._showAxisTooltip(r,e);else if(n){if(Ax(n).ssrType===`legend`)return;this._lastDataByCoordSys=null;var i,a;TA(n,function(e){if(Ax(e).dataIndex!=null)return i=e,!0;if(Ax(e).tooltipConfig!=null)return a=e,!0},!0),i?this._showSeriesItemTooltip(e,i,t):a?this._showComponentItemTooltip(e,a,t):this._hide(t)}else this._lastDataByCoordSys=null,this._hide(t)}},t.prototype._showOrMove=function(e,t){var n=e.get(`showDelay`);t=ip(t,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(t,n):t()},t.prototype._showAxisTooltip=function(e,t){var n=this._ecModel,r=this._tooltipModel,i=[t.offsetX,t.offsetY],a=dI([t.tooltipOption],r),o=this._renderMode,s=[],c=KO(`section`,{blocks:[],noHeader:!0}),l=[],u=new sk;q(e,function(e){q(e.dataByAxis,function(e){var t=n.getComponent(e.axisDim+`Axis`,e.axisIndex),i=e.value;if(t&&i!=null){var a=WP(i,t.axis,n,e.seriesDataIndices,e.valueLabelOpt),d=KO(`section`,{header:a,noHeader:!bp(a),sortBlocks:!0,blocks:[]});c.blocks.push(d),q(e.seriesDataIndices,function(c){var f=n.getSeriesByIndex(c.seriesIndex),p=c.dataIndexInside,m=f.getDataParams(p);if(!(m.dataIndex<0)){m.axisDim=e.axisDim,m.axisIndex=e.axisIndex,m.axisType=e.axisType,m.axisId=e.axisId,m.axisValue=QN(t.axis,{value:i}),m.axisValueLabel=a,m.marker=u.makeTooltipMarker(`item`,JT(m.color),o);var h=cO(f.formatTooltip(p,!0,null)),g=h.frag;if(g){var _=dI([f],r).get(`valueFormatter`);d.blocks.push(_?K({valueFormatter:_},g):g)}h.text&&l.push(h.text),s.push(m)}})}})}),c.blocks.reverse(),l.reverse();var d=t.position,f=QO(c,u,o,a.get(`order`),n.get(`useUTC`),a.get(`textStyle`));f&&l.unshift(f);var p=o===`richText`?`
|
|
17
|
+
|
|
18
|
+
`:`<br/>`,m=l.join(p);this._showOrMove(a,function(){this._updateContentNotChangedOnAxis(e,s)?this._updatePosition(a,d,i[0],i[1],this._tooltipContent,s):this._showTooltipContent(a,m,s,Math.random()+``,i[0],i[1],d,null,u)})},t.prototype._showSeriesItemTooltip=function(e,t,n){var r=this._ecModel,i=Ax(t),a=i.seriesIndex,o=r.getSeriesByIndex(a),s=i.dataModel||o,c=i.dataIndex,l=i.dataType,u=s.getData(l),d=this._renderMode,f=e.positionDefault,p=dI([u.getItemModel(c),s,o&&(o.coordinateSystem||{}).model],this._tooltipModel,f?{position:f}:null),m=p.get(`trigger`);if(m==null||m===`item`){var h=s.getDataParams(c,l),g=new sk;h.marker=g.makeTooltipMarker(`item`,JT(h.color),d);var _=cO(s.formatTooltip(c,!1,l)),v=p.get(`order`),y=p.get(`valueFormatter`),b=_.frag,x=b?QO(y?K({valueFormatter:y},b):b,g,d,v,r.get(`useUTC`),p.get(`textStyle`)):_.text,S=`item_`+s.name+`_`+c;this._showOrMove(p,function(){this._showTooltipContent(p,x,h,S,e.offsetX,e.offsetY,e.position,e.target,g)}),n({type:`showTip`,dataIndexInside:c,dataIndex:u.getRawIndex(c),seriesIndex:a,from:this.uid})}},t.prototype._showComponentItemTooltip=function(e,t,n){var r=this._renderMode===`html`,i=Ax(t),a=i.tooltipConfig.option||{},o=a.encodeHTMLContent;if(Y(a)){var s=a;a={content:s,formatter:s},o=!0}o&&r&&a.content&&(a=G(a),a.content=pm(a.content));var c=[a],l=this._ecModel.getComponent(i.componentMainType,i.componentIndex);l&&c.push(l),c.push({formatter:a.content});var u=e.positionDefault,d=dI(c,this._tooltipModel,u?{position:u}:null),f=d.get(`content`),p=Math.random()+``,m=new sk;this._showOrMove(d,function(){var n=G(d.get(`formatterParams`)||{});this._showTooltipContent(d,f,n,p,e.offsetX,e.offsetY,e.position,t,m)}),n({type:`showTip`,from:this.uid})},t.prototype._showTooltipContent=function(e,t,n,r,i,a,o,s,c){if(this._ticket=``,e.get(`showContent`)&&e.get(`show`)){var l=this._tooltipContent;l.setEnterable(e.get(`enterable`));var u=e.get(`formatter`);o||=e.get(`position`);var d=t,f=this._getNearestPoint([i,a],n,e.get(`trigger`),e.get(`borderColor`)).color;if(u){if(Y(u)){var p=e.ecModel.get(`useUTC`),m=J(n)?n[0]:n,h=m&&m.axisType&&m.axisType.indexOf(`time`)>=0;d=u,h&&(d=MT(m.axisValue,d,p)),d=KT(d,n,!0)}else if(op(u)){var g=ip(function(t,r){t===this._ticket&&(l.setContent(r,c,e,f,o),this._updatePosition(e,o,i,a,l,n,s))},this);this._ticket=r,d=u(n,r,g)}else d=u}l.setContent(d,c,e,f,o),l.show(e,f),this._updatePosition(e,o,i,a,l,n,s)}},t.prototype._getNearestPoint=function(e,t,n,r){if(n===`axis`||J(t))return{color:r||(this._renderMode===`html`?`#fff`:`none`)};if(!J(t))return{color:r||t.color||t.borderColor}},t.prototype._updatePosition=function(e,t,n,r,i,a,o){var s=this._api.getWidth(),c=this._api.getHeight();t||=e.get(`position`);var l=i.getSize(),u=e.get(`align`),d=e.get(`verticalAlign`),f=o&&o.getBoundingRect().clone();if(o&&f.applyTransform(o.transform),op(t)&&(t=t([n,r],a,i.el,f,{viewSize:[s,c],contentSize:l.slice()})),J(t))n=lv(t[0],s),r=lv(t[1],c);else if(X(t)){var p=t;p.width=l[0],p.height=l[1];var m=nE(p,{width:s,height:c});n=m.x,r=m.y,u=null,d=null}else if(Y(t)&&o){var h=hI(t,f,l,e.get(`borderWidth`));n=h[0],r=h[1]}else{var h=pI(n,r,i,s,c,u?null:20,d?null:20);n=h[0],r=h[1]}if(u&&(n-=gI(u)?l[0]/2:u===`right`?l[0]:0),d&&(r-=gI(d)?l[1]/2:d===`bottom`?l[1]:0),HF(e)){var h=mI(n,r,i,s,c);n=h[0],r=h[1]}i.moveTo(n,r)},t.prototype._updateContentNotChangedOnAxis=function(e,t){var n=this._lastDataByCoordSys,r=this._cbParamsList,i=!!n&&n.length===e.length;return i&&q(n,function(n,a){var o=n.dataByAxis||[],s=(e[a]||{}).dataByAxis||[];i&&=o.length===s.length,i&&q(o,function(e,n){var a=s[n]||{},o=e.seriesDataIndices||[],c=a.seriesDataIndices||[];i=i&&e.value===a.value&&e.axisType===a.axisType&&e.axisId===a.axisId&&o.length===c.length,i&&q(o,function(e,t){var n=c[t];i=i&&e.seriesIndex===n.seriesIndex&&e.dataIndex===n.dataIndex}),r&&q(e.seriesDataIndices,function(e){var n=e.seriesIndex,a=t[n],o=r[n];a&&o&&o.data!==a.data&&(i=!1)})})}),this._lastDataByCoordSys=e,this._cbParamsList=t,!!i},t.prototype._hide=function(e){this._lastDataByCoordSys=null,e({type:`hideTip`,from:this.uid})},t.prototype.dispose=function(e,t){!W.node&&t.getDom()&&(Ik(this,`_updatePosition`),this._tooltipContent.dispose(),cF(`itemTooltip`,t))},t.type=`tooltip`,t}(xk);function dI(e,t,n){var r=t.ecModel,i;n?(i=new dT(n,r,r),i=new dT(t.option,i,r)):i=t;for(var a=e.length-1;a>=0;a--){var o=e[a];o&&(o instanceof dT&&(o=o.get(`tooltip`,!0)),Y(o)&&(o={formatter:o}),o&&(i=new dT(o,i,r)))}return i}function fI(e,t){return e.dispatchAction||ip(t.dispatchAction,t)}function pI(e,t,n,r,i,a,o){var s=n.getSize(),c=s[0],l=s[1];return a!=null&&(e+c+a+2>r?e-=c+a:e+=a),o!=null&&(t+l+o>i?t-=l+o:t+=o),[e,t]}function mI(e,t,n,r,i){var a=n.getSize(),o=a[0],s=a[1];return e=Math.min(e+o,r)-o,t=Math.min(t+s,i)-s,e=Math.max(e,0),t=Math.max(t,0),[e,t]}function hI(e,t,n,r){var i=n[0],a=n[1],o=Math.ceil(Math.SQRT2*r)+8,s=0,c=0,l=t.width,u=t.height;switch(e){case`inside`:s=t.x+l/2-i/2,c=t.y+u/2-a/2;break;case`top`:s=t.x+l/2-i/2,c=t.y-a-o;break;case`bottom`:s=t.x+l/2-i/2,c=t.y+u+o;break;case`left`:s=t.x-i-o,c=t.y+u/2-a/2;break;case`right`:s=t.x+l+o,c=t.y+u/2-a/2}return[s,c]}function gI(e){return e===`center`||e===`middle`}function _I(e,t,n){var r=Yv(e).queryOptionMap,i=r.keys()[0];if(i&&i!==`series`){var a=Zv(t,i,r.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(a){var o=n.getViewOfComponentModel(a),s;if(o.group.traverse(function(t){var n=Ax(t).tooltipConfig;if(n&&n.name===e.name)return s=t,!0}),s)return{componentMainType:i,componentIndex:a.componentIndex,el:s}}}}function vI(e){rP(CF),e.registerComponentModel(VF),e.registerComponentView(uI),e.registerAction({type:`showTip`,event:`showTip`,update:`tooltip:manuallyShowTip`},Mp),e.registerAction({type:`hideTip`,event:`hideTip`,update:`tooltip:manuallyHideTip`},Mp)}var yI=q,bI=X,xI=-1,SI=function(){function e(t){var n=t.mappingMethod,r=t.type,i=this.option=G(t);this.type=r,this.mappingMethod=n,this._normalizeData=PI[n];var a=e.visualHandlers[r];this.applyVisual=a.applyVisual,this.getColorMapper=a.getColorMapper,this._normalizedToVisual=a._normalizedToVisual[n],n===`piecewise`?(TI(i),CI(i)):n===`category`?i.categories?wI(i):TI(i,!0):(yp(n!==`linear`||i.dataExtent),TI(i))}return e.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},e.prototype.getNormalizer=function(){return ip(this._normalizeData,this)},e.listVisualTypes=function(){return np(e.visualHandlers)},e.isValidType=function(t){return e.visualHandlers.hasOwnProperty(t)},e.eachVisual=function(e,t,n){X(e)?q(e,t,n):t.call(n,e)},e.mapVisual=function(t,n,r){var i,a=J(t)?[]:X(t)?{}:(i=!0,null);return e.eachVisual(t,function(e,t){var o=n.call(r,e,t);i?a=o:a[t]=o}),a},e.retrieveVisuals=function(t){var n={},r;return t&&yI(e.visualHandlers,function(e,i){t.hasOwnProperty(i)&&(n[i]=t[i],r=!0)}),r?n:null},e.prepareVisualTypes=function(e){if(J(e))e=e.slice();else if(bI(e)){var t=[];yI(e,function(e,n){t.push(n)}),e=t}else return[];return e.sort(function(e,t){return t===`color`&&e!==`color`&&e.indexOf(`color`)===0?1:-1}),e},e.dependsOn=function(e,t){return t===`color`?!!(e&&e.indexOf(t)===0):e===t},e.findPieceIndex=function(e,t,n){for(var r,i=1/0,a=0,o=t.length;a<o;a++){var s=t[a].value;if(s!=null){if(s===e||Y(s)&&s===e+``)return a;n&&d(s,a)}}for(var a=0,o=t.length;a<o;a++){var c=t[a],l=c.interval,u=c.close;if(l){if(l[0]===-1/0){if(FI(u[1],e,l[1]))return a}else if(l[1]===1/0){if(FI(u[0],l[0],e))return a}else if(FI(u[0],l[0],e)&&FI(u[1],e,l[1]))return a;n&&d(l[0],a),n&&d(l[1],a)}}if(n)return e===1/0?t.length-1:e===-1/0?0:r;function d(t,n){var a=Math.abs(t-e);a<i&&(i=a,r=n)}},e.visualHandlers={color:{applyVisual:OI(`color`),getColorMapper:function(){var e=this.option;return ip(e.mappingMethod===`category`?function(e,t){return!t&&(e=this._normalizeData(e)),kI.call(this,e)}:function(t,n,r){var i=!!r;return!n&&(t=this._normalizeData(t)),r=mg(t,e.parsedVisual,r),i?r:_g(r,`rgba`)},this)},_normalizedToVisual:{linear:function(e){return _g(mg(e,this.option.parsedVisual),`rgba`)},category:kI,piecewise:function(e,t){var n=MI.call(this,t);return n??=_g(mg(e,this.option.parsedVisual),`rgba`),n},fixed:AI}},colorHue:EI(function(e,t){return hg(e,t)}),colorSaturation:EI(function(e,t){return hg(e,null,t)}),colorLightness:EI(function(e,t){return hg(e,null,null,t)}),colorAlpha:EI(function(e,t){return gg(e,t)}),decal:{applyVisual:OI(`decal`),_normalizedToVisual:{linear:null,category:kI,piecewise:null,fixed:null}},opacity:{applyVisual:OI(`opacity`),_normalizedToVisual:jI([0,1])},liftZ:{applyVisual:OI(`liftZ`),_normalizedToVisual:{linear:AI,category:AI,piecewise:AI,fixed:AI}},symbol:{applyVisual:function(e,t,n){n(`symbol`,this.mapValueToVisual(e))},_normalizedToVisual:{linear:DI,category:kI,piecewise:function(e,t){var n=MI.call(this,t);return n??=DI.call(this,e),n},fixed:AI}},symbolSize:{applyVisual:OI(`symbolSize`),_normalizedToVisual:jI([0,1])}},e}();function CI(e){var t=e.pieceList;e.hasSpecialVisual=!1,q(t,function(t,n){t.originIndex=n,t.visual!=null&&(e.hasSpecialVisual=!0)})}function wI(e){var t=e.categories,n=e.categoryMap={},r=e.visual;if(yI(t,function(e,t){n[e]=t}),!J(r)){var i=[];X(r)?yI(r,function(e,t){var r=n[t];i[r??xI]=e}):i[xI]=r,r=NI(e,i)}for(var a=t.length-1;a>=0;a--)r[a]??(delete n[t[a]],t.pop())}function TI(e,t){var n=e.visual,r=[];X(n)?yI(n,function(e){r.push(e)}):n!=null&&r.push(n),!t&&r.length===1&&!{color:1,symbol:1}.hasOwnProperty(e.type)&&(r[1]=r[0]),NI(e,r)}function EI(e){return{applyVisual:function(t,n,r){var i=this.mapValueToVisual(t);r(`color`,e(n(`color`),i))},_normalizedToVisual:jI([0,1])}}function DI(e){var t=this.option.visual;return t[Math.round(cv(e,[0,1],[0,t.length-1],!0))]||{}}function OI(e){return function(t,n,r){r(e,this.mapValueToVisual(t))}}function kI(e){var t=this.option.visual;return t[this.option.loop&&e!==xI?e%t.length:e]}function AI(){return this.option.visual[0]}function jI(e){return{linear:function(t){return cv(t,e,this.option.visual,!0)},category:kI,piecewise:function(t,n){var r=MI.call(this,n);return r??=cv(t,e,this.option.visual,!0),r},fixed:AI}}function MI(e){var t=this.option,n=t.pieceList;if(t.hasSpecialVisual){var r=n[SI.findPieceIndex(e,n)];if(r&&r.visual)return r.visual[this.type]}}function NI(e,t){return e.visual=t,e.type===`color`&&(e.parsedVisual=$f(t,function(e){return ug(e)||[0,0,0,1]})),t}var PI={linear:function(e){return cv(e,this.option.dataExtent,[0,1],!0)},piecewise:function(e){var t=this.option.pieceList,n=SI.findPieceIndex(e,t,!0);if(n!=null)return cv(n,[0,t.length-1],[0,1],!0)},category:function(e){return(this.option.categories?this.option.categoryMap[e]:e)??xI},fixed:Mp};function FI(e,t,n){return e?t<=n:t<n}var II=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.layoutMode={type:`box`,ignoreSize:!0},n}return t.type=`title`,t.defaultOption={z:6,show:!0,text:``,target:`blank`,subtext:``,subtarget:`blank`,left:0,top:0,backgroundColor:`rgba(0,0,0,0)`,borderColor:`#ccc`,borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:`bold`,color:`#464646`},subtextStyle:{fontSize:12,color:`#6E7079`}},t}(lE),LI=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.render=function(e,t,n){if(this.group.removeAll(),e.get(`show`)){var r=this.group,i=e.getModel(`textStyle`),a=e.getModel(`subtextStyle`),o=e.get(`textAlign`),s=Z(e.get(`textBaseline`),e.get(`textVerticalAlign`)),c=new hx({style:Gw(i,{text:e.get(`text`),fill:i.getTextColor()},{disableBox:!0}),z2:10}),l=c.getBoundingRect(),u=e.get(`subtext`),d=new hx({style:Gw(a,{text:u,fill:a.getTextColor(),y:l.height+e.get(`itemGap`),verticalAlign:`top`},{disableBox:!0}),z2:10}),f=e.get(`link`),p=e.get(`sublink`),m=e.get(`triggerEvent`,!0);c.silent=!f&&!m,d.silent=!p&&!m,f&&c.on(`click`,function(){YT(f,`_`+e.get(`target`))}),p&&d.on(`click`,function(){YT(p,`_`+e.get(`subtarget`))}),Ax(c).eventData=Ax(d).eventData=m?{componentType:`title`,componentIndex:e.componentIndex}:null,r.add(c),u&&r.add(d);var h=r.getBoundingRect(),g=e.getBoxLayoutParams();g.width=h.width,g.height=h.height;var _=nE(g,{width:n.getWidth(),height:n.getHeight()},e.get(`padding`));o||(o=e.get(`left`)||e.get(`right`),o===`middle`&&(o=`center`),o===`right`?_.x+=_.width:o===`center`&&(_.x+=_.width/2)),s||(s=e.get(`top`)||e.get(`bottom`),s===`center`&&(s=`middle`),s===`bottom`?_.y+=_.height:s===`middle`&&(_.y+=_.height/2),s||=`top`),r.x=_.x,r.y=_.y,r.markRedraw();var v={align:o,verticalAlign:s};c.setStyle(v),d.setStyle(v),h=r.getBoundingRect();var y=_.margin,b=e.getItemStyle([`color`,`opacity`]);b.fill=e.get(`backgroundColor`);var x=new dx({shape:{x:h.x-y[3],y:h.y-y[0],width:h.width+y[1]+y[3],height:h.height+y[0]+y[2],r:e.get(`borderRadius`)},style:b,subPixelOptimize:!0,silent:!0});r.add(x)}},t.type=`title`,t}(xk);function RI(e){e.registerComponentModel(II),e.registerComponentView(LI)}function zI(e,t){var n=e.mapDimensionsAll(`defaultedLabel`),r=n.length;if(r===1){var i=aO(e,t,n[0]);return i==null?null:i+``}if(r){for(var a=[],o=0;o<n.length;o++)a.push(aO(e,t,n[o]));return a.join(` `)}}var BI=function(e){U(t,e);function t(t,n,r,i){var a=e.call(this)||this;return a.updateData(t,n,r,i),a}return t.prototype._createSymbol=function(e,t,n,r,i){this.removeAll();var a=FA(e,-1,-1,2,2,null,i);a.attr({z2:100,culling:!0,scaleX:r[0]/2,scaleY:r[1]/2}),a.drift=VI,this._symbolType=e,this.add(a)},t.prototype.stopSymbolAnimation=function(e){this.childAt(0).stopAnimation(null,e)},t.prototype.getSymbolType=function(){return this._symbolType},t.prototype.getSymbolPath=function(){return this.childAt(0)},t.prototype.highlight=function(){sS(this.childAt(0))},t.prototype.downplay=function(){cS(this.childAt(0))},t.prototype.setZ=function(e,t){var n=this.childAt(0);n.zlevel=e,n.z=t},t.prototype.setDraggable=function(e,t){var n=this.childAt(0);n.draggable=e,n.cursor=!t&&e?`move`:n.cursor},t.prototype.updateData=function(e,n,r,i){this.silent=!1;var a=e.getItemVisual(n,`symbol`)||`circle`,o=e.hostModel,s=t.getSymbolSize(e,n),c=a!==this._symbolType,l=i&&i.disableAnimation;if(c){var u=e.getItemVisual(n,`symbolKeepAspect`);this._createSymbol(a,e,n,s,u)}else{var d=this.childAt(0);d.silent=!1;var f={scaleX:s[0]/2,scaleY:s[1]/2};l?d.attr(f):ew(d,f,o,n),ow(d)}if(this._updateCommon(e,n,s,r,i),c){var d=this.childAt(0);if(!l){var f={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:d.style.opacity}};d.scaleX=d.scaleY=0,d.style.opacity=0,tw(d,f,o,n)}}l&&this.childAt(0).stopAnimation(`leave`)},t.prototype._updateCommon=function(e,t,n,r,i){var a=this.childAt(0),o=e.hostModel,s,c,l,u,d,f,p,m,h;if(r&&(s=r.emphasisItemStyle,c=r.blurItemStyle,l=r.selectItemStyle,u=r.focus,d=r.blurScope,p=r.labelStatesModels,m=r.hoverScale,h=r.cursorStyle,f=r.emphasisDisabled),!r||e.hasItemOption){var g=r&&r.itemModel?r.itemModel:e.getItemModel(t),_=g.getModel(`emphasis`);s=_.getModel(`itemStyle`).getItemStyle(),l=g.getModel([`select`,`itemStyle`]).getItemStyle(),c=g.getModel([`blur`,`itemStyle`]).getItemStyle(),u=_.get(`focus`),d=_.get(`blurScope`),f=_.get(`disabled`),p=Ww(g),m=_.getShallow(`scale`),h=g.getShallow(`cursor`)}var v=e.getItemVisual(t,`symbolRotate`);a.attr(`rotation`,(v||0)*Math.PI/180||0);var y=LA(e.getItemVisual(t,`symbolOffset`),n);y&&(a.x=y[0],a.y=y[1]),h&&a.attr(`cursor`,h);var b=e.getItemVisual(t,`style`),x=b.fill;if(a instanceof rx){var S=a.style;a.useStyle(K({image:S.image,x:S.x,y:S.y,width:S.width,height:S.height},b))}else a.__isEmptyBrush?a.useStyle(K({},b)):a.useStyle(b),a.style.decal=null,a.setColor(x,i&&i.symbolInnerColor),a.style.strokeNoScale=!0;var C=e.getItemVisual(t,`liftZ`),w=this._z2;C==null?w!=null&&(a.z2=w,this._z2=null):w??(this._z2=a.z2,a.z2+=C);var T=i&&i.useNameLabel;Uw(a,p,{labelFetcher:o,labelDataIndex:t,defaultText:E,inheritColor:x,defaultOpacity:b.opacity});function E(t){return T?e.getName(t):zI(e,t)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var D=a.ensureState(`emphasis`);D.style=s,a.ensureState(`select`).style=l,a.ensureState(`blur`).style=c;var O=m==null||m===!0?Math.max(1.1,3/this._sizeY):isFinite(m)&&m>0?+m:1;D.scaleX=this._sizeX*O,D.scaleY=this._sizeY*O,this.setSymbolScale(1),ES(this,u,d,f)},t.prototype.setSymbolScale=function(e){this.scaleX=this.scaleY=e},t.prototype.fadeOut=function(e,t,n){var r=this.childAt(0),i=Ax(this).dataIndex,a=n&&n.animation;if(this.silent=r.silent=!0,n&&n.fadeLabel){var o=r.getTextContent();o&&rw(o,{style:{opacity:0}},t,{dataIndex:i,removeOpt:a,cb:function(){r.removeTextContent()}})}else r.removeTextContent();rw(r,{style:{opacity:0},scaleX:0,scaleY:0},t,{dataIndex:i,cb:e,removeOpt:a})},t.getSymbolSize=function(e,t){return IA(e.getItemVisual(t,`symbolSize`))},t}(Z_);function VI(e,t){this.parent.drift(e,t)}function HI(e,t,n,r){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(r.isIgnore&&r.isIgnore(n))&&!(r.clipShape&&!r.clipShape.contain(t[0],t[1]))&&e.getItemVisual(n,`symbol`)!==`none`}function UI(e){return e!=null&&!X(e)&&(e={isIgnore:e}),e||{}}function WI(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{emphasisItemStyle:n.getModel(`itemStyle`).getItemStyle(),blurItemStyle:t.getModel([`blur`,`itemStyle`]).getItemStyle(),selectItemStyle:t.getModel([`select`,`itemStyle`]).getItemStyle(),focus:n.get(`focus`),blurScope:n.get(`blurScope`),emphasisDisabled:n.get(`disabled`),hoverScale:n.get(`scale`),labelStatesModels:Ww(t),cursorStyle:t.get(`cursor`)}}var GI=function(){function e(e){this.group=new Z_,this._SymbolCtor=e||BI}return e.prototype.updateData=function(e,t){this._progressiveEls=null,t=UI(t);var n=this.group,r=e.hostModel,i=this._data,a=this._SymbolCtor,o=t.disableAnimation,s=WI(e),c={disableAnimation:o},l=t.getSymbolPoint||function(t){return e.getItemLayout(t)};i||n.removeAll(),e.diff(i).add(function(r){var i=l(r);if(HI(e,i,r,t)){var o=new a(e,r,s,c);o.setPosition(i),e.setItemGraphicEl(r,o),n.add(o)}}).update(function(u,d){var f=i.getItemGraphicEl(d),p=l(u);if(!HI(e,p,u,t))n.remove(f);else{var m=e.getItemVisual(u,`symbol`)||`circle`,h=f&&f.getSymbolType&&f.getSymbolType();if(!f||h&&h!==m)n.remove(f),f=new a(e,u,s,c),f.setPosition(p);else{f.updateData(e,u,s,c);var g={x:p[0],y:p[1]};o?f.attr(g):ew(f,g,r)}n.add(f),e.setItemGraphicEl(u,f)}}).remove(function(e){var t=i.getItemGraphicEl(e);t&&t.fadeOut(function(){n.remove(t)},r)}).execute(),this._getSymbolPoint=l,this._data=e},e.prototype.updateLayout=function(){var e=this,t=this._data;t&&t.eachItemGraphicEl(function(t,n){var r=e._getSymbolPoint(n);t.setPosition(r),t.markRedraw()})},e.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=WI(e),this._data=null,this.group.removeAll()},e.prototype.incrementalUpdate=function(e,t,n){this._progressiveEls=[],n=UI(n);function r(e){e.isGroup||(e.incremental=!0,e.ensureState(`emphasis`).hoverLayer=!0)}for(var i=e.start;i<e.end;i++){var a=t.getItemLayout(i);if(HI(t,a,i,n)){var o=new this._SymbolCtor(t,i,this._seriesScope);o.traverse(r),o.setPosition(a),this.group.add(o),t.setItemGraphicEl(i,o),this._progressiveEls.push(o)}}},e.prototype.eachRendered=function(e){zw(this._progressiveEls||this.group,e)},e.prototype.remove=function(e){var t=this.group,n=this._data;n&&e?n.eachItemGraphicEl(function(e){e.fadeOut(function(){t.remove(e)},n.hostModel)}):t.removeAll()},e}(),KI=NC.prototype,qI=LC.prototype,JI=function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return e}();(function(e){U(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t})(JI);function YI(e){return isNaN(+e.cpx1)||isNaN(+e.cpy1)}var XI=function(e){U(t,e);function t(t){var n=e.call(this,t)||this;return n.type=`ec-line`,n}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new JI},t.prototype.buildPath=function(e,t){YI(t)?KI.buildPath.call(this,e,t):qI.buildPath.call(this,e,t)},t.prototype.pointAt=function(e){return YI(this.shape)?KI.pointAt.call(this,e):qI.pointAt.call(this,e)},t.prototype.tangentAt=function(e){var t=this.shape,n=YI(t)?[t.x2-t.x1,t.y2-t.y1]:qI.tangentAt.call(this,e);return Wp(n,n)},t}(Zb),ZI=[`fromSymbol`,`toSymbol`];function QI(e){return`_`+e+`Type`}function $I(e,t,n){var r=t.getItemVisual(n,e);if(!r||r===`none`)return r;var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=IA(i),l=LA(o||0,c);return r+c+l+(a||``)+(s||``)}function eL(e,t,n){var r=t.getItemVisual(n,e);if(r&&r!==`none`){var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=IA(i),l=LA(o||0,c),u=FA(r,-c[0]/2+l[0],-c[1]/2+l[1],c[0],c[1],null,s);return u.__specifiedRotation=a==null||isNaN(a)?void 0:a*Math.PI/180||0,u.name=e,u}}function tL(e){var t=new XI({name:`line`,subPixelOptimize:!0});return nL(t.shape,e),t}function nL(e,t){e.x1=t[0][0],e.y1=t[0][1],e.x2=t[1][0],e.y2=t[1][1],e.percent=1;var n=t[2];n?(e.cpx1=n[0],e.cpy1=n[1]):(e.cpx1=NaN,e.cpy1=NaN)}var rL=function(e){U(t,e);function t(t,n,r){var i=e.call(this)||this;return i._createLine(t,n,r),i}return t.prototype._createLine=function(e,t,n){var r=e.hostModel,i=tL(e.getItemLayout(t));i.shape.percent=0,tw(i,{shape:{percent:1}},r,t),this.add(i),q(ZI,function(n){var r=eL(n,e,t);this.add(r),this[QI(n)]=$I(n,e,t)},this),this._updateCommonStl(e,t,n)},t.prototype.updateData=function(e,t,n){var r=e.hostModel,i=this.childOfName(`line`),a=e.getItemLayout(t),o={shape:{}};nL(o.shape,a),ew(i,o,r,t),q(ZI,function(n){var r=$I(n,e,t),i=QI(n);if(this[i]!==r){this.remove(this.childOfName(n));var a=eL(n,e,t);this.add(a)}this[i]=r},this),this._updateCommonStl(e,t,n)},t.prototype.getLinePath=function(){return this.childAt(0)},t.prototype._updateCommonStl=function(e,t,n){var r=e.hostModel,i=this.childOfName(`line`),a=n&&n.emphasisLineStyle,o=n&&n.blurLineStyle,s=n&&n.selectLineStyle,c=n&&n.labelStatesModels,l=n&&n.emphasisDisabled,u=n&&n.focus,d=n&&n.blurScope;if(!n||e.hasItemOption){var f=e.getItemModel(t),p=f.getModel(`emphasis`);a=p.getModel(`lineStyle`).getLineStyle(),o=f.getModel([`blur`,`lineStyle`]).getLineStyle(),s=f.getModel([`select`,`lineStyle`]).getLineStyle(),l=p.get(`disabled`),u=p.get(`focus`),d=p.get(`blurScope`),c=Ww(f)}var m=e.getItemVisual(t,`style`),h=m.stroke;i.useStyle(m),i.style.fill=null,i.style.strokeNoScale=!0,i.ensureState(`emphasis`).style=a,i.ensureState(`blur`).style=o,i.ensureState(`select`).style=s,q(ZI,function(e){var t=this.childOfName(e);if(t){t.setColor(h),t.style.opacity=m.opacity;for(var n=0;n<Ix.length;n++){var r=Ix[n],a=i.getState(r);if(a){var o=a.style||{},s=t.ensureState(r),c=s.style||={};o.stroke!=null&&(c[t.__isEmptyBrush?`stroke`:`fill`]=o.stroke),o.opacity!=null&&(c.opacity=o.opacity)}}t.markRedraw()}},this);var g=r.getRawValue(t);Uw(this,c,{labelDataIndex:t,labelFetcher:{getFormattedLabel:function(t,n){return r.getFormattedLabel(t,n,e.dataType)}},inheritColor:h||`#000`,defaultOpacity:m.opacity,defaultText:(g==null?e.getName(t):isFinite(g)?uv(g):g)+``});var _=this.getTextContent();if(_){var v=c.normal;_.__align=_.style.align,_.__verticalAlign=_.style.verticalAlign,_.__position=v.get(`position`)||`middle`;var y=v.get(`distance`);J(y)||(y=[y,y]),_.__labelDistance=y}this.setTextConfig({position:null,local:!0,inside:!1}),ES(this,u,d,l)},t.prototype.highlight=function(){sS(this)},t.prototype.downplay=function(){cS(this)},t.prototype.updateLayout=function(e,t){this.setLinePoints(e.getItemLayout(t))},t.prototype.setLinePoints=function(e){var t=this.childOfName(`line`);nL(t.shape,e),t.dirty()},t.prototype.beforeUpdate=function(){var e=this,t=e.childOfName(`fromSymbol`),n=e.childOfName(`toSymbol`),r=e.getTextContent();if(!t&&!n&&(!r||r.ignore))return;for(var i=1,a=this.parent;a;)a.scaleX&&(i/=a.scaleX),a=a.parent;var o=e.childOfName(`line`);if(!this.__dirty&&!o.__dirty)return;var s=o.shape.percent,c=o.pointAt(0),l=o.pointAt(s),u=Bp([],l,c);Wp(u,u);function d(e,t){var n=e.__specifiedRotation;if(n==null){var r=o.tangentAt(t);e.attr(`rotation`,(t===1?-1:1)*Math.PI/2-Math.atan2(r[1],r[0]))}else e.attr(`rotation`,n)}if(t&&(t.setPosition(c),d(t,0),t.scaleX=t.scaleY=i*s,t.markRedraw()),n&&(n.setPosition(l),d(n,1),n.scaleX=n.scaleY=i*s,n.markRedraw()),r&&!r.ignore){r.x=r.y=0,r.originX=r.originY=0;var f=void 0,p=void 0,m=r.__labelDistance,h=m[0]*i,g=m[1]*i,_=s/2,v=o.tangentAt(_),y=[v[1],-v[0]],b=o.pointAt(_);y[1]>0&&(y[0]=-y[0],y[1]=-y[1]);var x=v[0]<0?-1:1;if(r.__position!==`start`&&r.__position!==`end`){var S=-Math.atan2(v[1],v[0]);l[0]<c[0]&&(S=Math.PI+S),r.rotation=S}var C=void 0;switch(r.__position){case`insideStartTop`:case`insideMiddleTop`:case`insideEndTop`:case`middle`:C=-g,p=`bottom`;break;case`insideStartBottom`:case`insideMiddleBottom`:case`insideEndBottom`:C=g,p=`top`;break;default:C=0,p=`middle`}switch(r.__position){case`end`:r.x=u[0]*h+l[0],r.y=u[1]*g+l[1],f=u[0]>.8?`left`:u[0]<-.8?`right`:`center`,p=u[1]>.8?`top`:u[1]<-.8?`bottom`:`middle`;break;case`start`:r.x=-u[0]*h+c[0],r.y=-u[1]*g+c[1],f=u[0]>.8?`right`:u[0]<-.8?`left`:`center`,p=u[1]>.8?`bottom`:u[1]<-.8?`top`:`middle`;break;case`insideStartTop`:case`insideStart`:case`insideStartBottom`:r.x=h*x+c[0],r.y=c[1]+C,f=v[0]<0?`right`:`left`,r.originX=-h*x,r.originY=-C;break;case`insideMiddleTop`:case`insideMiddle`:case`insideMiddleBottom`:case`middle`:r.x=b[0],r.y=b[1]+C,f=`center`,r.originY=-C;break;case`insideEndTop`:case`insideEnd`:case`insideEndBottom`:r.x=-h*x+l[0],r.y=l[1]+C,f=v[0]>=0?`right`:`left`,r.originX=h*x,r.originY=-C}r.scaleX=r.scaleY=i,r.setStyle({verticalAlign:r.__verticalAlign||p,align:r.__align||f})}},t}(Z_),iL=function(){function e(e){this.group=new Z_,this._LineCtor=e||rL}return e.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var n=this,r=n.group,i=n._lineData;n._lineData=e,i||r.removeAll();var a=oL(e);e.diff(i).add(function(n){t._doAdd(e,n,a)}).update(function(n,r){t._doUpdate(i,e,r,n,a)}).remove(function(e){r.remove(i.getItemGraphicEl(e))}).execute()},e.prototype.updateLayout=function(){var e=this._lineData;e&&e.eachItemGraphicEl(function(t,n){t.updateLayout(e,n)},this)},e.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=oL(e),this._lineData=null,this.group.removeAll()},e.prototype.incrementalUpdate=function(e,t){this._progressiveEls=[];function n(e){!e.isGroup&&!aL(e)&&(e.incremental=!0,e.ensureState(`emphasis`).hoverLayer=!0)}for(var r=e.start;r<e.end;r++)if(cL(t.getItemLayout(r))){var i=new this._LineCtor(t,r,this._seriesScope);i.traverse(n),this.group.add(i),t.setItemGraphicEl(r,i),this._progressiveEls.push(i)}},e.prototype.remove=function(){this.group.removeAll()},e.prototype.eachRendered=function(e){zw(this._progressiveEls||this.group,e)},e.prototype._doAdd=function(e,t,n){if(cL(e.getItemLayout(t))){var r=new this._LineCtor(e,t,n);e.setItemGraphicEl(t,r),this.group.add(r)}},e.prototype._doUpdate=function(e,t,n,r,i){var a=e.getItemGraphicEl(n);cL(t.getItemLayout(r))?(a?a.updateData(t,r,i):a=new this._LineCtor(t,r,i),t.setItemGraphicEl(r,a),this.group.add(a)):this.group.remove(a)},e}();function aL(e){return e.animators&&e.animators.length>0}function oL(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{lineStyle:t.getModel(`lineStyle`).getLineStyle(),emphasisLineStyle:n.getModel([`lineStyle`]).getLineStyle(),blurLineStyle:t.getModel([`blur`,`lineStyle`]).getLineStyle(),selectLineStyle:t.getModel([`select`,`lineStyle`]).getLineStyle(),emphasisDisabled:n.get(`disabled`),blurScope:n.get(`blurScope`),focus:n.get(`focus`),labelStatesModels:Ww(t)}}function sL(e){return isNaN(e[0])||isNaN(e[1])}function cL(e){return e&&!sL(e[0])&&!sL(e[1])}var lL=function(e,t){if(t===`all`)return{type:`all`,title:e.getLocaleModel().get([`legend`,`selector`,`all`])};if(t===`inverse`)return{type:`inverse`,title:e.getLocaleModel().get([`legend`,`selector`,`inverse`])}},uL=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.layoutMode={type:`box`,ignoreSize:!0},n}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n),e.selected=e.selected||{},this._updateSelector(e)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),this._updateSelector(t)},t.prototype._updateSelector=function(e){var t=e.selector,n=this.ecModel;t===!0&&(t=e.selector=[`all`,`inverse`]),J(t)&&q(t,function(e,r){Y(e)&&(e={type:e}),t[r]=qf(e,lL(n,e.type))})},t.prototype.optionUpdated=function(){this._updateData(this.ecModel);var e=this._data;if(e[0]&&this.get(`selectedMode`)===`single`){for(var t=!1,n=0;n<e.length;n++){var r=e[n].get(`name`);if(this.isSelected(r)){this.select(r),t=!0;break}}!t&&this.select(e[0].get(`name`))}},t.prototype._updateData=function(e){var t=[],n=[];e.eachRawSeries(function(r){var i=r.name;n.push(i);var a;if(r.legendVisualProvider){var o=r.legendVisualProvider.getAllNames();e.isSeriesFiltered(r)||(n=n.concat(o)),o.length?t=t.concat(o):a=!0}else a=!0;a&&Vv(r)&&t.push(r.name)}),this._availableNames=n;var r=this.get(`data`)||t,i=Q(),a=$f(r,function(e){return(Y(e)||cp(e))&&(e={name:e}),i.get(e.name)?null:(i.set(e.name,!0),new dT(e,this,this.ecModel))},this);this._data=tp(a,function(e){return!!e})},t.prototype.getData=function(){return this._data},t.prototype.select=function(e){var t=this.option.selected;if(this.get(`selectedMode`)===`single`){var n=this._data;q(n,function(e){t[e.get(`name`)]=!1})}t[e]=!0},t.prototype.unSelect=function(e){this.get(`selectedMode`)!==`single`&&(this.option.selected[e]=!1)},t.prototype.toggleSelected=function(e){var t=this.option.selected;t.hasOwnProperty(e)||(t[e]=!0),this[t[e]?`unSelect`:`select`](e)},t.prototype.allSelect=function(){var e=this._data,t=this.option.selected;q(e,function(e){t[e.get(`name`,!0)]=!0})},t.prototype.inverseSelect=function(){var e=this._data,t=this.option.selected;q(e,function(e){var n=e.get(`name`,!0);t.hasOwnProperty(n)||(t[n]=!0),t[n]=!t[n]})},t.prototype.isSelected=function(e){var t=this.option.selected;return!(t.hasOwnProperty(e)&&!t[e])&&Yf(this._availableNames,e)>=0},t.prototype.getOrient=function(){return this.get(`orient`)===`vertical`?{index:1,name:`vertical`}:{index:0,name:`horizontal`}},t.type=`legend.plain`,t.dependencies=[`series`],t.defaultOption={z:4,show:!0,orient:`horizontal`,left:`center`,top:0,align:`auto`,backgroundColor:`rgba(0,0,0,0)`,borderColor:`#ccc`,borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:`inherit`,symbolKeepAspect:!0,inactiveColor:`#ccc`,inactiveBorderColor:`#ccc`,inactiveBorderWidth:`auto`,itemStyle:{color:`inherit`,opacity:`inherit`,borderColor:`inherit`,borderWidth:`auto`,borderCap:`inherit`,borderJoin:`inherit`,borderDashOffset:`inherit`,borderMiterLimit:`inherit`},lineStyle:{width:`auto`,color:`inherit`,inactiveColor:`#ccc`,inactiveWidth:2,opacity:`inherit`,type:`inherit`,cap:`inherit`,join:`inherit`,dashOffset:`inherit`,miterLimit:`inherit`},textStyle:{color:`#333`},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:`sans-serif`,color:`#666`,borderWidth:1,borderColor:`#666`},emphasis:{selectorLabel:{show:!0,color:`#eee`,backgroundColor:`#666`}},selectorPosition:`auto`,selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},t}(lE),dL=ap,fL=q,pL=Z_,mL=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!1,n}return t.prototype.init=function(){this.group.add(this._contentGroup=new pL),this.group.add(this._selectorGroup=new pL),this._isFirstRender=!0},t.prototype.getContentGroup=function(){return this._contentGroup},t.prototype.getSelectorGroup=function(){return this._selectorGroup},t.prototype.render=function(e,t,n){var r=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),e.get(`show`,!0)){var i=e.get(`align`),a=e.get(`orient`);i&&i!==`auto`||(i=e.get(`left`)===`right`&&a===`vertical`?`right`:`left`);var o=e.get(`selector`,!0),s=e.get(`selectorPosition`,!0);o&&(!s||s===`auto`)&&(s=a===`horizontal`?`end`:`start`),this.renderInner(i,e,t,n,o,a,s);var c=e.getBoxLayoutParams(),l={width:n.getWidth(),height:n.getHeight()},u=e.get(`padding`),d=nE(c,l,u),f=this.layoutInner(e,i,d,r,o,s),p=nE(Jf({width:f.width,height:f.height},c),l,u);this.group.x=p.x-f.x,this.group.y=p.y-f.y,this.group.markRedraw(),this.group.add(this._backgroundEl=BF(f,e))}},t.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},t.prototype.renderInner=function(e,t,n,r,i,a,o){var s=this.getContentGroup(),c=Q(),l=t.get(`selectedMode`),u=[];n.eachRawSeries(function(e){!e.get(`legendHoverLink`)&&u.push(e.id)}),fL(t.getData(),function(i,a){var o=i.get(`name`);if(!this.newlineDisabled&&(o===``||o===`
|
|
19
|
+
`)){var d=new pL;d.newline=!0,s.add(d)}else{var f=n.getSeriesByName(o)[0];if(!c.get(o)){if(f){var p=f.getData(),m=p.getVisual(`legendLineStyle`)||{},h=p.getVisual(`legendIcon`),g=p.getVisual(`style`),_=this._createItem(f,o,a,i,t,e,m,g,h,l,r);_.on(`click`,dL(_L,o,null,r,u)).on(`mouseover`,dL(yL,f.name,null,r,u)).on(`mouseout`,dL(bL,f.name,null,r,u)),n.ssr&&_.eachChild(function(e){var t=Ax(e);t.seriesIndex=f.seriesIndex,t.dataIndex=a,t.ssrType=`legend`}),c.set(o,!0)}else n.eachRawSeries(function(s){if(!c.get(o)&&s.legendVisualProvider){var d=s.legendVisualProvider;if(!d.containName(o))return;var f=d.indexOfName(o),p=d.getItemVisual(f,`style`),m=d.getItemVisual(f,`legendIcon`),h=ug(p.fill);h&&h[3]===0&&(h[3]=.2,p=K(K({},p),{fill:_g(h,`rgba`)}));var g=this._createItem(s,o,a,i,t,e,{},p,m,l,r);g.on(`click`,dL(_L,null,o,r,u)).on(`mouseover`,dL(yL,null,o,r,u)).on(`mouseout`,dL(bL,null,o,r,u)),n.ssr&&g.eachChild(function(e){var t=Ax(e);t.seriesIndex=s.seriesIndex,t.dataIndex=a,t.ssrType=`legend`}),c.set(o,!0)}},this)}}},this),i&&this._createSelector(i,t,r,a,o)},t.prototype._createSelector=function(e,t,n,r,i){var a=this.getSelectorGroup();fL(e,function(e){var r=e.type,i=new hx({style:{x:0,y:0,align:`center`,verticalAlign:`middle`},onclick:function(){n.dispatchAction({type:r===`all`?`legendAllSelect`:`legendInverseSelect`,legendId:t.id})}});a.add(i),Uw(i,{normal:t.getModel(`selectorLabel`),emphasis:t.getModel([`emphasis`,`selectorLabel`])},{defaultText:e.title}),wS(i)})},t.prototype._createItem=function(e,t,n,r,i,a,o,s,c,l,u){var d=e.visualDrawType,f=i.get(`itemWidth`),p=i.get(`itemHeight`),m=i.isSelected(t),h=r.get(`symbolRotate`),g=r.get(`symbolKeepAspect`),_=r.get(`icon`);c=_||c||`roundRect`;var v=hL(c,r,o,s,d,m,u),y=new pL,b=r.getModel(`textStyle`);if(op(e.getLegendIcon)&&(!_||_===`inherit`))y.add(e.getLegendIcon({itemWidth:f,itemHeight:p,icon:c,iconRotate:h,itemStyle:v.itemStyle,lineStyle:v.lineStyle,symbolKeepAspect:g}));else{var x=_===`inherit`&&e.getData().getVisual(`symbol`)?h===`inherit`?e.getData().getVisual(`symbolRotate`):h:0;y.add(gL({itemWidth:f,itemHeight:p,icon:c,iconRotate:x,itemStyle:v.itemStyle,lineStyle:v.lineStyle,symbolKeepAspect:g}))}var S=a===`left`?f+5:-5,C=a,w=i.get(`formatter`),T=t;Y(w)&&w?T=w.replace(`{name}`,t??``):op(w)&&(T=w(t));var E=m?b.getTextColor():r.get(`inactiveColor`);y.add(new hx({style:Gw(b,{text:T,x:S,y:p/2,fill:E,align:C,verticalAlign:`middle`},{inheritColor:E})}));var D=new dx({shape:y.getBoundingRect(),style:{fill:`transparent`}}),O=r.getModel(`tooltip`);return O.get(`show`)&&Lw({el:D,componentModel:i,itemName:t,itemTooltipOption:O.option}),y.add(D),y.eachChild(function(e){e.silent=!0}),D.silent=!l,this.getContentGroup().add(y),wS(y),y.__legendDataIndex=n,y},t.prototype.layoutInner=function(e,t,n,r,i,a){var o=this.getContentGroup(),s=this.getSelectorGroup();eE(e.get(`orient`),o,e.get(`itemGap`),n.width,n.height);var c=o.getBoundingRect(),l=[-c.x,-c.y];if(s.markRedraw(),o.markRedraw(),i){eE(`horizontal`,s,e.get(`selectorItemGap`,!0));var u=s.getBoundingRect(),d=[-u.x,-u.y],f=e.get(`selectorButtonGap`,!0),p=e.getOrient().index,m=p===0?`width`:`height`,h=p===0?`height`:`width`,g=p===0?`y`:`x`;a===`end`?d[p]+=c[m]+f:l[p]+=u[m]+f,d[1-p]+=c[h]/2-u[h]/2,s.x=d[0],s.y=d[1],o.x=l[0],o.y=l[1];var _={x:0,y:0};return _[m]=c[m]+f+u[m],_[h]=Math.max(c[h],u[h]),_[g]=Math.min(0,u[g]+d[1-p]),_}return o.x=l[0],o.y=l[1],this.group.getBoundingRect()},t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type=`legend.plain`,t}(xk);function hL(e,t,n,r,i,a,o){function s(e,t){e.lineWidth===`auto`&&(e.lineWidth=t.lineWidth>0?2:0),fL(e,function(n,r){e[r]===`inherit`&&(e[r]=t[r])})}var c=t.getModel(`itemStyle`),l=c.getItemStyle(),u=e.lastIndexOf(`empty`,0)===0?`fill`:`stroke`,d=c.getShallow(`decal`);l.decal=!d||d===`inherit`?r.decal:wj(d,o),l.fill===`inherit`&&(l.fill=r[i]),l.stroke===`inherit`&&(l.stroke=r[u]),l.opacity===`inherit`&&(l.opacity=(i===`fill`?r:n).opacity),s(l,r);var f=t.getModel(`lineStyle`),p=f.getLineStyle();if(s(p,n),l.fill===`auto`&&(l.fill=r.fill),l.stroke===`auto`&&(l.stroke=r.fill),p.stroke===`auto`&&(p.stroke=r.fill),!a){var m=t.get(`inactiveBorderWidth`),h=l[u];l.lineWidth=m===`auto`?r.lineWidth>0&&h?2:0:l.lineWidth,l.fill=t.get(`inactiveColor`),l.stroke=t.get(`inactiveBorderColor`),p.stroke=f.get(`inactiveColor`),p.lineWidth=f.get(`inactiveWidth`)}return{itemStyle:l,lineStyle:p}}function gL(e){var t=e.icon||`roundRect`,n=FA(t,0,0,e.itemWidth,e.itemHeight,e.itemStyle.fill,e.symbolKeepAspect);return n.setStyle(e.itemStyle),n.rotation=(e.iconRotate||0)*Math.PI/180,n.setOrigin([e.itemWidth/2,e.itemHeight/2]),t.indexOf(`empty`)>-1&&(n.style.stroke=n.style.fill,n.style.fill=`#fff`,n.style.lineWidth=2),n}function _L(e,t,n,r){bL(e,t,n,r),n.dispatchAction({type:`legendToggleSelect`,name:e??t}),yL(e,t,n,r)}function vL(e){for(var t=e.getZr().storage.getDisplayList(),n,r=0,i=t.length;r<i&&!(n=t[r].states.emphasis);)r++;return n&&n.hoverLayer}function yL(e,t,n,r){vL(n)||n.dispatchAction({type:`highlight`,seriesName:e,name:t,excludeSeriesId:r})}function bL(e,t,n,r){vL(n)||n.dispatchAction({type:`downplay`,seriesName:e,name:t,excludeSeriesId:r})}function xL(e){var t=e.findComponents({mainType:`legend`});t&&t.length&&e.filterSeries(function(e){for(var n=0;n<t.length;n++)if(!t[n].isSelected(e.name))return!1;return!0})}function SL(e,t,n){var r=e===`allSelect`||e===`inverseSelect`,i={},a=[];n.eachComponent({mainType:`legend`,query:t},function(n){r?n[e]():n[e](t.name),CL(n,i),a.push(n.componentIndex)});var o={};return n.eachComponent(`legend`,function(e){q(i,function(t,n){e[t?`select`:`unSelect`](n)}),CL(e,o)}),r?{selected:o,legendIndex:a}:{name:t.name,selected:o}}function CL(e,t){var n=t||{};return q(e.getData(),function(t){var r=t.get(`name`);if(r!==`
|
|
20
|
+
`&&r!==``){var i=e.isSelected(r);n[r]=jp(n,r)?n[r]&&i:i}}),n}function wL(e){e.registerAction(`legendToggleSelect`,`legendselectchanged`,ap(SL,`toggleSelected`)),e.registerAction(`legendAllSelect`,`legendselectall`,ap(SL,`allSelect`)),e.registerAction(`legendInverseSelect`,`legendinverseselect`,ap(SL,`inverseSelect`)),e.registerAction(`legendSelect`,`legendselected`,ap(SL,`select`)),e.registerAction(`legendUnSelect`,`legendunselected`,ap(SL,`unSelect`))}function TL(e){e.registerComponentModel(uL),e.registerComponentView(mL),e.registerProcessor(e.PRIORITY.PROCESSOR.SERIES_FILTER,xL),e.registerSubTypeDefaulter(`legend`,function(){return`plain`}),wL(e)}var EL=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.setScrollDataIndex=function(e){this.option.scrollDataIndex=e},t.prototype.init=function(t,n,r){var i=oE(t);e.prototype.init.call(this,t,n,r),DL(this,t,i)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),DL(this,this.option,t)},t.type=`legend.scroll`,t.defaultOption=gT(uL.defaultOption,{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:`end`,pageFormatter:`{current}/{total}`,pageIcons:{horizontal:[`M0,0L12,-10L12,10z`,`M0,0L-12,-10L-12,10z`],vertical:[`M0,0L20,0L10,-20z`,`M0,0L20,0L10,20z`]},pageIconColor:`#2f4554`,pageIconInactiveColor:`#aaa`,pageIconSize:15,pageTextStyle:{color:`#333`},animationDurationUpdate:800}),t}(uL);function DL(e,t,n){var r=e.getOrient(),i=[1,1];i[r.index]=0,aE(t,n,{type:`box`,ignoreSize:!!i})}var OL=Z_,kL=[`width`,`height`],AL=[`x`,`y`],jL=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!0,n._currentIndex=0,n}return t.prototype.init=function(){e.prototype.init.call(this),this.group.add(this._containerGroup=new OL),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new OL)},t.prototype.resetInner=function(){e.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},t.prototype.renderInner=function(t,n,r,i,a,o,s){var c=this;e.prototype.renderInner.call(this,t,n,r,i,a,o,s);var l=this._controllerGroup,u=n.get(`pageIconSize`,!0),d=J(u)?u:[u,u];p(`pagePrev`,0);var f=n.getModel(`pageTextStyle`);l.add(new hx({name:`pageText`,style:{text:`xx/xx`,fill:f.getTextColor(),font:f.getFont(),verticalAlign:`middle`,align:`center`},silent:!0})),p(`pageNext`,1);function p(e,t){var r=e+`DataIndex`,a=Mw(n.get(`pageIcons`,!0)[n.getOrient().name][t],{onclick:ip(c._pageGo,c,r,n,i)},{x:-d[0]/2,y:-d[1]/2,width:d[0],height:d[1]});a.name=e,l.add(a)}},t.prototype.layoutInner=function(e,t,n,r,i,a){var o=this.getSelectorGroup(),s=e.getOrient().index,c=kL[s],l=AL[s],u=kL[1-s],d=AL[1-s];i&&eE(`horizontal`,o,e.get(`selectorItemGap`,!0));var f=e.get(`selectorButtonGap`,!0),p=o.getBoundingRect(),m=[-p.x,-p.y],h=G(n);i&&(h[c]=n[c]-p[c]-f);var g=this._layoutContentAndController(e,r,h,s,c,u,d,l);if(i){if(a===`end`)m[s]+=g[c]+f;else{var _=p[c]+f;m[s]-=_,g[l]-=_}g[c]+=p[c]+f,m[1-s]+=g[d]+g[u]/2-p[u]/2,g[u]=Math.max(g[u],p[u]),g[d]=Math.min(g[d],p[d]+m[1-s]),o.x=m[0],o.y=m[1],o.markRedraw()}return g},t.prototype._layoutContentAndController=function(e,t,n,r,i,a,o,s){var c=this.getContentGroup(),l=this._containerGroup,u=this._controllerGroup;eE(e.get(`orient`),c,e.get(`itemGap`),r?n.width:null,r?null:n.height),eE(`horizontal`,u,e.get(`pageButtonItemGap`,!0));var d=c.getBoundingRect(),f=u.getBoundingRect(),p=this._showController=d[i]>n[i],m=[-d.x,-d.y];t||(m[r]=c[s]);var h=[0,0],g=[-f.x,-f.y],_=Z(e.get(`pageButtonGap`,!0),e.get(`itemGap`,!0));p&&(e.get(`pageButtonPosition`,!0)===`end`?g[r]+=n[i]-f[i]:h[r]+=f[i]+_),g[1-r]+=d[a]/2-f[a]/2,c.setPosition(m),l.setPosition(h),u.setPosition(g);var v={x:0,y:0};if(v[i]=p?n[i]:d[i],v[a]=Math.max(d[a],f[a]),v[o]=Math.min(0,f[o]+g[1-r]),l.__rectSize=n[i],p){var y={x:0,y:0};y[i]=Math.max(n[i]-f[i]-_,0),y[a]=v[a],l.setClipPath(new dx({shape:y})),l.__rectSize=y[i]}else u.eachChild(function(e){e.attr({invisible:!0,silent:!0})});var b=this._getPageInfo(e);return b.pageIndex!=null&&ew(c,{x:b.contentPosition[0],y:b.contentPosition[1]},p?e:null),this._updatePageInfoView(e,b),v},t.prototype._pageGo=function(e,t,n){var r=this._getPageInfo(t)[e];r!=null&&n.dispatchAction({type:`legendScroll`,scrollDataIndex:r,legendId:t.id})},t.prototype._updatePageInfoView=function(e,t){var n=this._controllerGroup;q([`pagePrev`,`pageNext`],function(r){var i=t[r+`DataIndex`]!=null,a=n.childOfName(r);a&&(a.setStyle(`fill`,i?e.get(`pageIconColor`,!0):e.get(`pageIconInactiveColor`,!0)),a.cursor=i?`pointer`:`default`)});var r=n.childOfName(`pageText`),i=e.get(`pageFormatter`),a=t.pageIndex,o=a==null?0:a+1,s=t.pageCount;r&&i&&r.setStyle(`text`,Y(i)?i.replace(`{current}`,o==null?``:o+``).replace(`{total}`,s==null?``:s+``):i({current:o,total:s}))},t.prototype._getPageInfo=function(e){var t=e.get(`scrollDataIndex`,!0),n=this.getContentGroup(),r=this._containerGroup.__rectSize,i=e.getOrient().index,a=kL[i],o=AL[i],s=this._findTargetItemIndex(t),c=n.children(),l=c[s],u=c.length,d=+!!u,f={contentPosition:[n.x,n.y],pageCount:d,pageIndex:d-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!l)return f;var p=v(l);f.contentPosition[i]=-p.s;for(var m=s+1,h=p,g=p,_=null;m<=u;++m)_=v(c[m]),(!_&&g.e>h.s+r||_&&!y(_,h.s))&&(h=g.i>h.i?g:_,h&&(f.pageNextDataIndex??=h.i,++f.pageCount)),g=_;for(var m=s-1,h=p,g=p,_=null;m>=-1;--m)_=v(c[m]),(!_||!y(g,_.s))&&h.i<g.i&&(g=h,f.pagePrevDataIndex??=h.i,++f.pageCount,++f.pageIndex),h=_;return f;function v(e){if(e){var t=e.getBoundingRect(),n=t[o]+e[o];return{s:n,e:n+t[a],i:e.__legendDataIndex}}}function y(e,t){return e.e>=t&&e.s<=t+r}},t.prototype._findTargetItemIndex=function(e){if(!this._showController)return 0;var t,n=this.getContentGroup(),r;return n.eachChild(function(n,i){var a=n.__legendDataIndex;r==null&&a!=null&&(r=i),a===e&&(t=i)}),t??r},t.type=`legend.scroll`,t}(mL);function ML(e){e.registerAction(`legendScroll`,`legendscroll`,function(e,t){var n=e.scrollDataIndex;n!=null&&t.eachComponent({mainType:`legend`,subType:`scroll`,query:e},function(e){e.setScrollDataIndex(n)})})}function NL(e){rP(TL),e.registerComponentModel(EL),e.registerComponentView(jL),ML(e)}function PL(e){rP(TL),rP(NL)}var FL=function(){function e(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return e.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},e.prototype.containName=function(e){return this._getRawData().indexOfName(e)>=0},e.prototype.indexOfName=function(e){return this._getDataWithEncodedVisual().indexOfName(e)},e.prototype.getItemVisual=function(e,t){return this._getDataWithEncodedVisual().getItemVisual(e,t)},e}(),IL=Kv();function LL(e){var t=e.mainData,n=e.datas;n||(n={main:t},e.datasAttr={main:`data`}),e.datas=e.mainData=null,WL(t,n,e),q(n,function(n){q(t.TRANSFERABLE_METHODS,function(t){n.wrapMethod(t,ap(RL,e))})}),t.wrapMethod(`cloneShallow`,ap(BL,e)),q(t.CHANGABLE_METHODS,function(n){t.wrapMethod(n,ap(zL,e))}),yp(n[t.dataType]===t)}function RL(e,t){if(UL(this)){var n=K({},IL(this).datas);n[this.dataType]=t,WL(t,n,e)}else GL(t,this.dataType,IL(this).mainData,e);return t}function zL(e,t){return e.struct&&e.struct.update(),t}function BL(e,t){return q(IL(t).datas,function(n,r){n!==t&&GL(n.cloneShallow(),r,t,e)}),t}function VL(e){var t=IL(this).mainData;return e==null||t==null?t:IL(t).datas[e]}function HL(){var e=IL(this).mainData;return e==null?[{data:e}]:$f(np(IL(e).datas),function(t){return{type:t,data:IL(e).datas[t]}})}function UL(e){return IL(e).mainData===e}function WL(e,t,n){IL(e).datas={},q(t,function(t,r){GL(t,r,e,n)})}function GL(e,t,n,r){IL(n).datas[t]=e,IL(e).mainData=n,e.dataType=t,r.struct&&(e[r.structAttr]=r.struct,r.struct[r.datasAttr[t]]=e),e.getLinkedData=VL,e.getLinkedDataAll=HL}var KL=function(){function e(e,t){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=e||``,this.hostTree=t}return e.prototype.isRemoved=function(){return this.dataIndex<0},e.prototype.eachNode=function(e,t,n){op(e)&&(n=t,t=e,e=null),e||={},Y(e)&&(e={order:e});var r=e.order||`preorder`,i=this[e.attr||`children`],a;r===`preorder`&&(a=t.call(n,this));for(var o=0;!a&&o<i.length;o++)i[o].eachNode(e,t,n);r===`postorder`&&t.call(n,this)},e.prototype.updateDepthAndHeight=function(e){var t=0;this.depth=e;for(var n=0;n<this.children.length;n++){var r=this.children[n];r.updateDepthAndHeight(e+1),r.height>t&&(t=r.height)}this.height=t+1},e.prototype.getNodeById=function(e){if(this.getId()===e)return this;for(var t=0,n=this.children,r=n.length;t<r;t++){var i=n[t].getNodeById(e);if(i)return i}},e.prototype.contains=function(e){if(e===this)return!0;for(var t=0,n=this.children,r=n.length;t<r;t++){var i=n[t].contains(e);if(i)return i}},e.prototype.getAncestors=function(e){for(var t=[],n=e?this:this.parentNode;n;)t.push(n),n=n.parentNode;return t.reverse(),t},e.prototype.getAncestorsIndices=function(){for(var e=[],t=this;t;)e.push(t.dataIndex),t=t.parentNode;return e.reverse(),e},e.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},e.prototype.getValue=function(e){var t=this.hostTree.data;return t.getStore().get(t.getDimensionIndex(e||`value`),this.dataIndex)},e.prototype.setLayout=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemLayout(this.dataIndex,e,t)},e.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},e.prototype.getModel=function(e){if(!(this.dataIndex<0))return this.hostTree.data.getItemModel(this.dataIndex).getModel(e)},e.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},e.prototype.setVisual=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,e,t)},e.prototype.getVisual=function(e){return this.hostTree.data.getItemVisual(this.dataIndex,e)},e.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},e.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},e.prototype.getChildIndex=function(){if(this.parentNode){for(var e=this.parentNode.children,t=0;t<e.length;++t)if(e[t]===this)return t;return-1}return-1},e.prototype.isAncestorOf=function(e){for(var t=e.parentNode;t;){if(t===this)return!0;t=t.parentNode}return!1},e.prototype.isDescendantOf=function(e){return e!==this&&e.isAncestorOf(this)},e}(),qL=function(){function e(e){this.type=`tree`,this._nodes=[],this.hostModel=e}return e.prototype.eachNode=function(e,t,n){this.root.eachNode(e,t,n)},e.prototype.getNodeByDataIndex=function(e){var t=this.data.getRawIndex(e);return this._nodes[t]},e.prototype.getNodeById=function(e){return this.root.getNodeById(e)},e.prototype.update=function(){for(var e=this.data,t=this._nodes,n=0,r=t.length;n<r;n++)t[n].dataIndex=-1;for(var n=0,r=e.count();n<r;n++)t[e.getRawIndex(n)].dataIndex=n},e.prototype.clearLayouts=function(){this.data.clearItemLayouts()},e.createTree=function(t,n,r){var i=new e(n),a=[],o=1;s(t);function s(e,t){var n=e.value;o=Math.max(o,J(n)?n.length:1),a.push(e);var r=new KL(Bv(e.name,``),i);t?JL(r,t):i.root=r,i._nodes.push(r);var c=e.children;if(c)for(var l=0;l<c.length;l++)s(c[l],r)}i.root.updateDepthAndHeight(0);var c=LN(a,{coordDimensions:[`value`],dimensionsCount:o}).dimensions,l=new IN(c,n);return l.initData(a),r&&r(l),LL({mainData:l,struct:i,structAttr:`tree`}),i.update(),i},e}();function JL(e,t){var n=t.children;e.parentNode!==t&&(n.push(e),e.parentNode=t)}function YL(e,t,n){if(e&&Yf(t,e.type)>=0){var r=n.getData().tree.root,i=e.targetNode;if(Y(i)&&(i=r.getNodeById(i)),i&&r.contains(i))return{node:i};var a=e.targetNodeId;if(a!=null&&(i=r.getNodeById(a)))return{node:i}}}function XL(e){for(var t=[];e;)e=e.parentNode,e&&t.push(e);return t.reverse()}function ZL(e,t){return Yf(XL(e),t)>=0}function QL(e,t){for(var n=[];e;){var r=e.dataIndex;n.push({name:e.name,dataIndex:r,value:t.getRawValue(r)}),e=e.parentNode}return n.reverse(),n}var $L=[`treemapZoomToNode`,`treemapRender`,`treemapMove`];function eR(e){for(var t=0;t<$L.length;t++)e.registerAction({type:$L[t],update:`updateView`},Mp);e.registerAction({type:`treemapRootToNode`,update:`updateView`},function(e,t){t.eachComponent({mainType:`series`,subType:`treemap`,query:e},n);function n(t,n){var r=YL(e,[`treemapZoomToNode`,`treemapRootToNode`],t);if(r){var i=t.getViewRoot();i&&(e.direction=ZL(i,r.node)?`rollUp`:`drillDown`),t.resetViewRoot(r.node)}}})}function tR(e){var t=e.getData().tree,n={};t.eachNode(function(t){for(var r=t;r&&r.depth>1;)r=r.parentNode;var i=FE(e.ecModel,r.name||r.dataIndex+``,n);t.setVisual(`decal`,i)})}var nR=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.preventUsingHoverLayer=!0,n}return t.prototype.getInitialData=function(e,t){var n={name:e.name,children:e.data};rR(n);var r=e.levels||[],i=new dT({itemStyle:this.designatedVisualItemStyle={}},this,t);r=e.levels=iR(r,t);var a=$f(r||[],function(e){return new dT(e,i,t)},this),o=qL.createTree(n,this,s);function s(e){e.wrapMethod(`getItemModel`,function(e,t){var n=o.getNodeByDataIndex(t);return e.parentModel=(n?a[n.depth]:null)||i,e})}return o.data},t.prototype.optionUpdated=function(){this.resetViewRoot()},t.prototype.formatTooltip=function(e,t,n){var r=this.getData(),i=this.getRawValue(e);return KO(`nameValue`,{name:r.getName(e),value:i})},t.prototype.getDataParams=function(t){var n=e.prototype.getDataParams.apply(this,arguments);return n.treeAncestors=QL(this.getData().tree.getNodeByDataIndex(t),this),n.treePathInfo=n.treeAncestors,n},t.prototype.setLayoutInfo=function(e){this.layoutInfo=this.layoutInfo||{},K(this.layoutInfo,e)},t.prototype.mapIdToIndex=function(e){var t=this._idIndexMap;t||(t=this._idIndexMap=Q(),this._idIndexMapCount=0);var n=t.get(e);return n??t.set(e,n=this._idIndexMapCount++),n},t.prototype.getViewRoot=function(){return this._viewRoot},t.prototype.resetViewRoot=function(e){e?this._viewRoot=e:e=this._viewRoot;var t=this.getRawData().tree.root;(!e||e!==t&&!t.contains(e))&&(this._viewRoot=t)},t.prototype.enableAriaDecal=function(){tR(this)},t.type=`series.treemap`,t.layoutMode=`box`,t.defaultOption={progressive:0,left:`center`,top:`middle`,width:`80%`,height:`80%`,sort:!0,clipWindow:`origin`,squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:`▶`,zoomToNodeRatio:.1024,scaleLimit:null,roam:!0,nodeClick:`zoomToNode`,animation:!0,animationDurationUpdate:900,animationEasing:`quinticInOut`,breadcrumb:{show:!0,height:22,left:`center`,top:`bottom`,emptyItemWidth:25,itemStyle:{color:`rgba(0,0,0,0.7)`,textStyle:{color:`#fff`}},emphasis:{itemStyle:{color:`rgba(0,0,0,0.9)`}}},label:{show:!0,distance:0,padding:5,position:`inside`,color:`#fff`,overflow:`truncate`},upperLabel:{show:!1,position:[0,`50%`],height:20,overflow:`truncate`,verticalAlign:`middle`},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:`#fff`,borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,`50%`],overflow:`truncate`,verticalAlign:`middle`}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:`index`,visibleMin:10,childrenVisibleMin:null,levels:[]},t}(fk);function rR(e){var t=0;q(e.children,function(e){rR(e);var n=e.value;J(n)&&(n=n[0]),t+=n});var n=e.value;J(n)&&(n=n[0]),(n==null||isNaN(n))&&(n=t),n<0&&(n=0),J(e.value)?e.value[0]=n:e.value=n}function iR(e,t){var n=Ev(t.get(`color`)),r=Ev(t.get([`aria`,`decal`,`decals`]));if(n){e||=[];var i,a;q(e,function(e){var t=new dT(e),n=t.get(`color`),r=t.get(`decal`);(t.get([`itemStyle`,`color`])||n&&n!==`none`)&&(i=!0),(t.get([`itemStyle`,`decal`])||r&&r!==`none`)&&(a=!0)});var o=e[0]||(e[0]={});return i||(o.color=n.slice()),!a&&r&&(o.decal=r.slice()),e}}var aR=8,oR=8,sR=5,cR=function(){function e(e){this.group=new Z_,e.add(this.group)}return e.prototype.render=function(e,t,n,r){var i=e.getModel(`breadcrumb`),a=this.group;if(a.removeAll(),i.get(`show`)&&n){var o=i.getModel(`itemStyle`),s=i.getModel(`emphasis`),c=o.getModel(`textStyle`),l=s.getModel([`itemStyle`,`textStyle`]),u={pos:{left:i.get(`left`),right:i.get(`right`),top:i.get(`top`),bottom:i.get(`bottom`)},box:{width:t.getWidth(),height:t.getHeight()},emptyItemWidth:i.get(`emptyItemWidth`),totalWidth:0,renderList:[]};this._prepare(n,u,c),this._renderContent(e,u,o,s,c,l,r),rE(a,u.pos,u.box)}},e.prototype._prepare=function(e,t,n){for(var r=e;r;r=r.parentNode){var i=Bv(r.getModel().get(`name`),``),a=n.getTextRect(i),o=Math.max(a.width+aR*2,t.emptyItemWidth);t.totalWidth+=o+oR,t.renderList.push({node:r,text:i,width:o})}},e.prototype._renderContent=function(e,t,n,r,i,a,o){for(var s=0,c=t.emptyItemWidth,l=e.get([`breadcrumb`,`height`]),u=tE(t.pos,t.box),d=t.totalWidth,f=t.renderList,p=r.getModel(`itemStyle`).getItemStyle(),m=f.length-1;m>=0;m--){var h=f[m],g=h.node,_=h.width,v=h.text;d>u.width&&(d-=_-c,_=c,v=null);var y=new OC({shape:{points:lR(s,0,_,l,m===f.length-1,m===0)},style:Jf(n.getItemStyle(),{lineJoin:`bevel`}),textContent:new hx({style:Gw(i,{text:v})}),textConfig:{position:`inside`},z2:1e5,onclick:ap(o,g)});y.disableLabelAnimation=!0,y.getTextContent().ensureState(`emphasis`).style=Gw(a,{text:v}),y.ensureState(`emphasis`).style=p,ES(y,r.get(`focus`),r.get(`blurScope`),r.get(`disabled`)),this.group.add(y),uR(y,e,g),s+=_+oR}},e.prototype.remove=function(){this.group.removeAll()},e}();function lR(e,t,n,r,i,a){var o=[[i?e:e-sR,t],[e+n,t],[e+n,t+r],[i?e:e-sR,t+r]];return!a&&o.splice(2,0,[e+n+sR,t+r/2]),!i&&o.push([e,t+r/2]),o}function uR(e,t,n){Ax(e).eventData={componentType:`series`,componentSubType:`treemap`,componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:`treemap`,selfType:`breadcrumb`,nodeData:{dataIndex:n&&n.dataIndex,name:n&&n.name},treePathInfo:n&&QL(n,t)}}var dR=function(){function e(){this._storage=[],this._elExistsMap={}}return e.prototype.add=function(e,t,n,r,i){return!this._elExistsMap[e.id]&&(this._elExistsMap[e.id]=!0,this._storage.push({el:e,target:t,duration:n,delay:r,easing:i}),!0)},e.prototype.finished=function(e){return this._finishedCallback=e,this},e.prototype.start=function(){for(var e=this,t=this._storage.length,n=function(){t--,t<=0&&(e._storage.length=0,e._elExistsMap={},e._finishedCallback&&e._finishedCallback())},r=0,i=this._storage.length;r<i;r++){var a=this._storage[r];a.el.animateTo(a.target,{duration:a.duration,delay:a.delay,easing:a.easing,setToFinal:!0,done:n,aborted:n})}return this},e}();function fR(){return new dR}var pR=Z_,mR=dx,hR=3,gR=`label`,_R=`upperLabel`,vR=100,yR=20,bR=30,xR=hy([[`fill`,`color`],[`stroke`,`strokeColor`],[`lineWidth`,`strokeWidth`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`shadowColor`]]),SR=function(e){var t=xR(e);return t.stroke=t.fill=t.lineWidth=null,t},CR=Kv(),wR=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n._state=`ready`,n._storage=TR(),n}return t.prototype.render=function(e,t,n,r){if(!(Yf(t.findComponents({mainType:`series`,subType:`treemap`,query:r}),e)<0)){this.seriesModel=e,this.api=n,this.ecModel=t;var i=YL(r,[`treemapZoomToNode`,`treemapRootToNode`],e),a=r&&r.type,o=e.layoutInfo,s=!this._oldTree,c=this._storage,l=a===`treemapRootToNode`&&i&&c?{rootNodeGroup:c.nodeGroup[i.node.getRawIndex()],direction:r.direction}:null,u=this._giveContainerGroup(o),d=e.get(`animation`),f=this._doRender(u,e,l);d&&!s&&(!a||a===`treemapZoomToNode`||a===`treemapRootToNode`)?this._doAnimation(u,f,e,l):f.renderFinally(),this._resetController(n),this._renderBreadcrumb(e,n,i)}},t.prototype._giveContainerGroup=function(e){var t=this._containerGroup;return t||(t=this._containerGroup=new pR,this._initEvents(t),this.group.add(t)),t.x=e.x,t.y=e.y,t},t.prototype._doRender=function(e,t,n){var r=t.getData().tree,i=this._oldTree,a=TR(),o=TR(),s=this._storage,c=[];function l(e,r,i,l){return ER(t,o,s,n,a,c,e,r,i,l)}p(r.root?[r.root]:[],i&&i.root?[i.root]:[],e,r===i||!i,0);var u=m(s);if(this._oldTree=r,this._storage=o,this._controllerHost){var d=this.seriesModel.layoutInfo,f=r.root.getLayout();f.width===d.width&&f.height===d.height&&(this._controllerHost.zoom=1)}return{lastsForAnimation:a,willDeleteEls:u,renderFinally:h};function p(e,t,n,r,i){r?(t=e,q(e,function(e,t){!e.isRemoved()&&o(t,t)})):new cN(t,e,a,a).add(o).update(o).remove(ap(o,null)).execute();function a(e){return e.getId()}function o(a,o){var s=a==null?null:e[a],c=o==null?null:t[o],u=l(s,c,n,i);u&&p(s&&s.viewChildren||[],c&&c.viewChildren||[],u,r,i+1)}}function m(e){var t=TR();return e&&q(e,function(e,n){var r=t[n];q(e,function(e){e&&(r.push(e),CR(e).willDelete=!0)})}),t}function h(){q(u,function(e){q(e,function(e){e.parent&&e.parent.remove(e)})}),q(c,function(e){e.invisible=!0,e.dirty()})}},t.prototype._doAnimation=function(e,t,n,r){var i=n.get(`animationDurationUpdate`),a=n.get(`animationEasing`),o=(op(i)?0:i)||0,s=(op(a)?null:a)||`cubicOut`,c=fR();q(t.willDeleteEls,function(e,t){q(e,function(e,n){if(!e.invisible){var i=e.parent,a,l=CR(i);if(r&&r.direction===`drillDown`)a=i===r.rootNodeGroup?{shape:{x:0,y:0,width:l.nodeWidth,height:l.nodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var u=0,d=0;l.willDelete||(u=l.nodeWidth/2,d=l.nodeHeight/2),a=t===`nodeGroup`?{x:u,y:d,style:{opacity:0}}:{shape:{x:u,y:d,width:0,height:0},style:{opacity:0}}}a&&c.add(e,a,o,0,s)}})}),q(this._storage,function(e,n){q(e,function(e,r){var i=t.lastsForAnimation[n][r],a={};i&&(e instanceof Z_?i.oldX!=null&&(a.x=e.x,a.y=e.y,e.x=i.oldX,e.y=i.oldY):(i.oldShape&&(a.shape=K({},e.shape),e.setShape(i.oldShape)),i.fadein?(e.setStyle(`opacity`,0),a.style={opacity:1}):e.style.opacity!==1&&(a.style={opacity:1})),c.add(e,a,o,0,s))})},this),this._state=`animating`,c.finished(ip(function(){this._state=`ready`,t.renderFinally()},this)).start()},t.prototype._resetController=function(e){var t=this._controller,n=this._controllerHost;n||=(this._controllerHost={target:this.group},this._controllerHost),t||(t=this._controller=new MF(e.getZr()),t.enable(this.seriesModel.get(`roam`)),n.zoomLimit=this.seriesModel.get(`scaleLimit`),n.zoom=this.seriesModel.get(`zoom`),t.on(`pan`,ip(this._onPan,this)),t.on(`zoom`,ip(this._onZoom,this)));var r=new $(0,0,e.getWidth(),e.getHeight());t.setPointerChecker(function(e,t,n){return r.contain(t,n)})},t.prototype._clearController=function(){var e=this._controller;this._controllerHost=null,e&&=(e.dispose(),null)},t.prototype._onPan=function(e){if(this._state!==`animating`&&(Math.abs(e.dx)>hR||Math.abs(e.dy)>hR)){var t=this.seriesModel.getData().tree.root;if(!t)return;var n=t.getLayout();if(!n)return;this.api.dispatchAction({type:`treemapMove`,from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+e.dx,y:n.y+e.dy,width:n.width,height:n.height}})}},t.prototype._onZoom=function(e){var t=e.originX,n=e.originY,r=e.scale;if(this._state!==`animating`){var i=this.seriesModel.getData().tree.root;if(!i)return;var a=i.getLayout();if(!a)return;var o=new $(a.x,a.y,a.width,a.height),s=null,c=this._controllerHost;s=c.zoomLimit;var l=c.zoom=c.zoom||1;if(l*=r,s){var u=s.min||0,d=s.max||1/0;l=Math.max(Math.min(d,l),u)}var f=l/c.zoom;c.zoom=l;var p=this.seriesModel.layoutInfo;t-=p.x,n-=p.y;var m=Am();Pm(m,m,[-t,-n]),Im(m,m,[f,f]),Pm(m,m,[t,n]),o.applyTransform(m),this.api.dispatchAction({type:`treemapRender`,from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:o.x,y:o.y,width:o.width,height:o.height}})}},t.prototype._initEvents=function(e){var t=this;e.on(`click`,function(e){if(t._state===`ready`){var n=t.seriesModel.get(`nodeClick`,!0);if(n){var r=t.findTarget(e.offsetX,e.offsetY);if(r){var i=r.node;if(i.getLayout().isLeafRoot)t._rootToNode(r);else if(n===`zoomToNode`)t._zoomToNode(r);else if(n===`link`){var a=i.hostTree.data.getItemModel(i.dataIndex),o=a.get(`link`,!0),s=a.get(`target`,!0)||`blank`;o&&YT(o,s)}}}}},this)},t.prototype._renderBreadcrumb=function(e,t,n){var r=this;n||(n=e.get(`leafDepth`,!0)==null?this.findTarget(t.getWidth()/2,t.getHeight()/2):{node:e.getViewRoot()},n||={node:e.getData().tree.root}),(this._breadcrumb||=new cR(this.group)).render(e,t,n.node,function(t){r._state!==`animating`&&(ZL(e.getViewRoot(),t)?r._rootToNode({node:t}):r._zoomToNode({node:t}))})},t.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=TR(),this._state=`ready`,this._breadcrumb&&this._breadcrumb.remove()},t.prototype.dispose=function(){this._clearController()},t.prototype._zoomToNode=function(e){this.api.dispatchAction({type:`treemapZoomToNode`,from:this.uid,seriesId:this.seriesModel.id,targetNode:e.node})},t.prototype._rootToNode=function(e){this.api.dispatchAction({type:`treemapRootToNode`,from:this.uid,seriesId:this.seriesModel.id,targetNode:e.node})},t.prototype.findTarget=function(e,t){var n;return this.seriesModel.getViewRoot().eachNode({attr:`viewChildren`,order:`preorder`},function(r){var i=this._storage.background[r.getRawIndex()];if(i){var a=i.transformCoordToLocal(e,t),o=i.shape;if(o.x<=a[0]&&a[0]<=o.x+o.width&&o.y<=a[1]&&a[1]<=o.y+o.height)n={node:r,offsetX:a[0],offsetY:a[1]};else return!1}},this),n},t.type=`treemap`,t}(Tk);function TR(){return{nodeGroup:[],background:[],content:[]}}function ER(e,t,n,r,i,a,o,s,c,l){if(!o)return;var u=o.getLayout(),d=e.getData(),f=o.getModel();if(d.setItemGraphicEl(o.dataIndex,null),!u||!u.isInView)return;var p=u.width,m=u.height,h=u.borderWidth,g=u.invisible,_=o.getRawIndex(),v=s&&s.getRawIndex(),y=o.viewChildren,b=u.upperHeight,x=y&&y.length,S=f.getModel(`itemStyle`),C=f.getModel([`emphasis`,`itemStyle`]),w=f.getModel([`blur`,`itemStyle`]),T=f.getModel([`select`,`itemStyle`]),E=S.get(`borderRadius`)||0,D=le(`nodeGroup`,pR);if(!D)return;if(c.add(D),D.x=u.x||0,D.y=u.y||0,D.markRedraw(),CR(D).nodeWidth=p,CR(D).nodeHeight=m,u.isAboveViewRoot)return D;var O=le(`background`,mR,l,yR);O&&ie(D,O,x&&u.upperLabelHeight);var k=f.getModel(`emphasis`),A=k.get(`focus`),ee=k.get(`blurScope`),te=k.get(`disabled`),ne=A===`ancestor`?o.getAncestorsIndices():A===`descendant`?o.getDescendantIndices():A;if(x)kS(D)&&OS(D,!1),O&&(OS(O,!te),d.setItemGraphicEl(o.dataIndex,O),DS(O,ne,ee));else{var re=le(`content`,mR,l,bR);re&&ae(D,re),O.disableMorphing=!0,O&&kS(O)&&OS(O,!1),OS(D,!te),d.setItemGraphicEl(o.dataIndex,D);var j=f.getShallow(`cursor`);j&&re.attr(`cursor`,j),DS(D,ne,ee)}return D;function ie(t,n,r){var i=Ax(n);if(i.dataIndex=o.dataIndex,i.seriesIndex=e.seriesIndex,n.setShape({x:0,y:0,width:p,height:m,r:E}),g)oe(n);else{n.invisible=!1;var a=o.getVisual(`style`),s=a.stroke,c=SR(S);c.fill=s;var l=xR(C);l.fill=C.get(`borderColor`);var u=xR(w);u.fill=w.get(`borderColor`);var d=xR(T);if(d.fill=T.get(`borderColor`),r){var f=p-2*h;se(n,s,a.opacity,{x:h,y:0,width:f,height:b})}else n.removeTextContent();n.setStyle(c),n.ensureState(`emphasis`).style=l,n.ensureState(`blur`).style=u,n.ensureState(`select`).style=d,iS(n)}t.add(n)}function ae(t,n){var r=Ax(n);r.dataIndex=o.dataIndex,r.seriesIndex=e.seriesIndex;var i=Math.max(p-2*h,0),a=Math.max(m-2*h,0);if(n.culling=!0,n.setShape({x:h,y:h,width:i,height:a,r:E}),g)oe(n);else{n.invisible=!1;var s=o.getVisual(`style`),c=s.fill,l=SR(S);l.fill=c,l.decal=s.decal;var u=xR(C),d=xR(w),f=xR(T);se(n,c,s.opacity,null),n.setStyle(l),n.ensureState(`emphasis`).style=u,n.ensureState(`blur`).style=d,n.ensureState(`select`).style=f,iS(n)}t.add(n)}function oe(e){!e.invisible&&a.push(e)}function se(t,n,r,i){var a=f.getModel(i?_R:gR),s=Bv(f.get(`name`),null),c=a.getShallow(`show`);Uw(t,Ww(f,i?_R:gR),{defaultText:c?s:null,inheritColor:n,defaultOpacity:r,labelFetcher:e,labelDataIndex:o.dataIndex});var l=t.getTextContent();if(l){var d=l.style,p=vp(d.padding||0);i&&(t.setTextConfig({layoutRect:i}),l.disableLabelLayout=!0),l.beforeUpdate=function(){var e=Math.max((i?i.width:t.shape.width)-p[1]-p[3],0),n=Math.max((i?i.height:t.shape.height)-p[0]-p[2],0);(d.width!==e||d.height!==n)&&l.setStyle({width:e,height:n})},d.truncateMinChar=2,d.lineOverflow=`truncate`,ce(d,i,u);var m=l.getState(`emphasis`);ce(m?m.style:null,i,u)}}function ce(t,n,r){var i=t?t.text:null;if(!n&&r.isLeafRoot&&i!=null){var a=e.get(`drillDownIcon`,!0);t.text=a?a+` `+i:i}}function le(e,r,a,o){var s=v!=null&&n[e][v],c=i[e];return s?(n[e][v]=null,ue(c,s)):g||(s=new r,s instanceof Uy&&(s.z2=DR(a,o)),de(c,s)),t[e][_]=s}function ue(e,t){var n=e[_]={};t instanceof pR?(n.oldX=t.x,n.oldY=t.y):n.oldShape=K({},t.shape)}function de(e,t){var n=e[_]={},a=o.parentNode,s=t instanceof Z_;if(a&&(!r||r.direction===`drillDown`)){var c=0,l=0,u=i.background[a.getRawIndex()];!r&&u&&u.oldShape&&(c=u.oldShape.width,l=u.oldShape.height),s?(n.oldX=0,n.oldY=l):n.oldShape={x:c,y:l,width:0,height:0}}n.fadein=!s}}function DR(e,t){return e*vR+t}var OR=`itemStyle`,kR=Kv(),AR={seriesType:`treemap`,reset:function(e){var t=e.getData().tree.root;t.isRemoved()||jR(t,{},e.getViewRoot().getAncestors(),e)}};function jR(e,t,n,r){var i=e.getModel(),a=e.getLayout(),o=e.hostTree.data;if(a&&!a.invisible&&a.isInView){var s=i.getModel(OR),c=MR(s,t,r),l=o.ensureUniqueItemVisual(e.dataIndex,`style`),u=s.get(`borderColor`),d=s.get(`borderColorSaturation`),f;d!=null&&(f=NR(c),u=PR(d,f)),l.stroke=u;var p=e.viewChildren;if(!p||!p.length)f=NR(c),l.fill=f;else{var m=IR(e,i,a,s,c,p);q(p,function(e,t){(e.depth>=n.length||e===n[e.depth])&&jR(e,RR(i,c,e,t,m,r),n,r)})}}}function MR(e,t,n){var r=K({},t),i=n.designatedVisualItemStyle;return q([`color`,`colorAlpha`,`colorSaturation`],function(n){i[n]=t[n];var a=e.get(n);i[n]=null,a!=null&&(r[n]=a)}),r}function NR(e){var t=FR(e,`color`);if(t){var n=FR(e,`colorAlpha`),r=FR(e,`colorSaturation`);return r&&(t=hg(t,null,null,r)),n&&(t=gg(t,n)),t}}function PR(e,t){return t==null?null:hg(t,null,null,e)}function FR(e,t){var n=e[t];if(n!=null&&n!==`none`)return n}function IR(e,t,n,r,i,a){if(a&&a.length){var o=LR(t,`color`)||i.color!=null&&i.color!==`none`&&(LR(t,`colorAlpha`)||LR(t,`colorSaturation`));if(o){var s=t.get(`visualMin`),c=t.get(`visualMax`),l=n.dataExtent.slice();s!=null&&s<l[0]&&(l[0]=s),c!=null&&c>l[1]&&(l[1]=c);var u=t.get(`colorMappingBy`),d={type:o.name,dataExtent:l,visual:o.range};d.type===`color`&&(u===`index`||u===`id`)?(d.mappingMethod=`category`,d.loop=!0):d.mappingMethod=`linear`;var f=new SI(d);return kR(f).drColorMappingBy=u,f}}}function LR(e,t){var n=e.get(t);return J(n)&&n.length?{name:t,range:n}:null}function RR(e,t,n,r,i,a){var o=K({},t);if(i){var s=i.type,c=s===`color`&&kR(i).drColorMappingBy,l=c===`index`?r:c===`id`?a.mapIdToIndex(n.getId()):n.getValue(e.get(`visualDimension`));o[s]=i.mapValueToVisual(l)}return o}var zR=Math.max,BR=Math.min,VR=hp,HR=q,UR=[`itemStyle`,`borderWidth`],WR=[`itemStyle`,`gapWidth`],GR=[`upperLabel`,`show`],KR=[`upperLabel`,`height`],qR={seriesType:`treemap`,reset:function(e,t,n,r){var i=n.getWidth(),a=n.getHeight(),o=e.option,s=nE(e.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()}),c=o.size||[],l=lv(VR(s.width,c[0]),i),u=lv(VR(s.height,c[1]),a),d=r&&r.type,f=YL(r,[`treemapZoomToNode`,`treemapRootToNode`],e),p=d===`treemapRender`||d===`treemapMove`?r.rootRect:null,m=e.getViewRoot(),h=XL(m);if(d!==`treemapMove`){var g=d===`treemapZoomToNode`?tz(e,f,m,l,u):p?[p.width,p.height]:[l,u],_=o.sort;_&&_!==`asc`&&_!==`desc`&&(_=`desc`);var v={squareRatio:o.squareRatio,sort:_,leafDepth:o.leafDepth};m.hostTree.clearLayouts();var y={x:0,y:0,width:g[0],height:g[1],area:g[0]*g[1]};m.setLayout(y),JR(m,v,!1,0),y=m.getLayout(),HR(h,function(e,t){var n=(h[t+1]||m).getValue();e.setLayout(K({dataExtent:[n,n],borderWidth:0,upperHeight:0},y))})}var b=e.getData().tree.root;b.setLayout(nz(s,p,f),!0),e.setLayoutInfo(s),rz(b,new $(-s.x,-s.y,i,a),h,m,0)}};function JR(e,t,n,r){var i,a;if(!e.isRemoved()){var o=e.getLayout();i=o.width,a=o.height;var s=e.getModel(),c=s.get(UR),l=s.get(WR)/2,u=iz(s),d=Math.max(c,u),f=c-l,p=d-l;e.setLayout({borderWidth:c,upperHeight:d,upperLabelHeight:u},!0),i=zR(i-2*f,0),a=zR(a-f-p,0);var m=i*a,h=YR(e,s,m,t,n,r);if(h.length){var g={x:f,y:p,width:i,height:a},_=BR(i,a),v=1/0,y=[];y.area=0;for(var b=0,x=h.length;b<x;){var S=h[b];y.push(S),y.area+=S.getLayout().area;var C=$R(y,_,t.squareRatio);C<=v?(b++,v=C):(y.area-=y.pop().getLayout().area,ez(y,_,g,l,!1),_=BR(g.width,g.height),y.length=y.area=0,v=1/0)}if(y.length&&ez(y,_,g,l,!0),!n){var w=s.get(`childrenVisibleMin`);w!=null&&m<w&&(n=!0)}for(var b=0,x=h.length;b<x;b++)JR(h[b],t,n,r+1)}}}function YR(e,t,n,r,i,a){var o=e.children||[],s=r.sort;s!==`asc`&&s!==`desc`&&(s=null);var c=r.leafDepth!=null&&r.leafDepth<=a;if(i&&!c)return e.viewChildren=[];o=tp(o,function(e){return!e.isRemoved()}),ZR(o,s);var l=QR(t,o,s);if(l.sum===0||(l.sum=XR(t,n,l.sum,s,o),l.sum===0))return e.viewChildren=[];for(var u=0,d=o.length;u<d;u++){var f=o[u].getValue()/l.sum*n;o[u].setLayout({area:f})}return c&&(o.length&&e.setLayout({isLeafRoot:!0},!0),o.length=0),e.viewChildren=o,e.setLayout({dataExtent:l.dataExtent},!0),o}function XR(e,t,n,r,i){if(!r)return n;for(var a=e.get(`visibleMin`),o=i.length,s=o,c=o-1;c>=0;c--){var l=i[r===`asc`?o-c-1:c].getValue();l/n*t<a&&(s=c,n-=l)}return r===`asc`?i.splice(0,o-s):i.splice(s,o-s),n}function ZR(e,t){return t&&e.sort(function(e,n){var r=t===`asc`?e.getValue()-n.getValue():n.getValue()-e.getValue();return r===0?t===`asc`?e.dataIndex-n.dataIndex:n.dataIndex-e.dataIndex:r}),e}function QR(e,t,n){for(var r=0,i=0,a=t.length;i<a;i++)r+=t[i].getValue();var o=e.get(`visualDimension`),s;return!t||!t.length?s=[NaN,NaN]:o===`value`&&n?(s=[t[t.length-1].getValue(),t[0].getValue()],n===`asc`&&s.reverse()):(s=[1/0,-1/0],HR(t,function(e){var t=e.getValue(o);t<s[0]&&(s[0]=t),t>s[1]&&(s[1]=t)})),{sum:r,dataExtent:s}}function $R(e,t,n){for(var r=0,i=1/0,a=0,o=void 0,s=e.length;a<s;a++)o=e[a].getLayout().area,o&&(o<i&&(i=o),o>r&&(r=o));var c=e.area*e.area,l=t*t*n;return c?zR(l*r/c,c/(l*i)):1/0}function ez(e,t,n,r,i){var a=t===n.width?0:1,o=1-a,s=[`x`,`y`],c=[`width`,`height`],l=n[s[a]],u=t?e.area/t:0;(i||u>n[c[o]])&&(u=n[c[o]]);for(var d=0,f=e.length;d<f;d++){var p=e[d],m={},h=u?p.getLayout().area/u:0,g=m[c[o]]=zR(u-2*r,0),_=n[s[a]]+n[c[a]]-l,v=d===f-1||_<h?_:h,y=m[c[a]]=zR(v-2*r,0);m[s[o]]=n[s[o]]+BR(r,g/2),m[s[a]]=l+BR(r,y/2),l+=v,p.setLayout(m,!0)}n[s[o]]+=u,n[c[o]]-=u}function tz(e,t,n,r,i){var a=(t||{}).node,o=[r,i];if(!a||a===n)return o;for(var s,c=r*i,l=c*e.option.zoomToNodeRatio;s=a.parentNode;){for(var u=0,d=s.children,f=0,p=d.length;f<p;f++)u+=d[f].getValue();var m=a.getValue();if(m===0)return o;l*=u/m;var h=s.getModel(),g=h.get(UR),_=Math.max(g,iz(h));l+=4*g*g+(3*g+_)*l**.5,l>9007199254740991&&(l=9007199254740991),a=s}l<c&&(l=c);var v=(l/c)**.5;return[r*v,i*v]}function nz(e,t,n){if(t)return{x:t.x,y:t.y};var r={x:0,y:0};if(!n)return r;var i=n.node,a=i.getLayout();if(!a)return r;for(var o=[a.width/2,a.height/2],s=i;s;){var c=s.getLayout();o[0]+=c.x,o[1]+=c.y,s=s.parentNode}return{x:e.width/2-o[0],y:e.height/2-o[1]}}function rz(e,t,n,r,i){var a=e.getLayout(),o=n[i],s=o&&o===e;if(!(o&&!s||i===n.length&&e!==r)){e.setLayout({isInView:!0,invisible:!s&&!t.intersect(a),isAboveViewRoot:s},!0);var c=new $(t.x-a.x,t.y-a.y,t.width,t.height);HR(e.viewChildren||[],function(e){rz(e,c,n,r,i+1)})}}function iz(e){return e.get(GR)?e.get(KR):0}function az(e){e.registerSeriesModel(nR),e.registerChartView(wR),e.registerVisual(AR),e.registerLayout(qR),eR(e)}function oz(e){var t=e.findComponents({mainType:`legend`});t&&t.length&&e.eachSeriesByType(`graph`,function(e){var n=e.getCategoriesData(),r=e.getGraph().data,i=n.mapArray(n.getName);r.filterSelf(function(e){var n=r.getItemModel(e).getShallow(`category`);if(n!=null){cp(n)&&(n=i[n]);for(var a=0;a<t.length;a++)if(!t[a].isSelected(n))return!1}return!0})})}function sz(e){var t={};e.eachSeriesByType(`graph`,function(e){var n=e.getCategoriesData(),r=e.getData(),i={};n.each(function(r){var a=n.getName(r);i[`ec-`+a]=r;var o=n.getItemModel(r),s=o.getModel(`itemStyle`).getItemStyle();s.fill||=e.getColorFromPalette(a,t),n.setItemVisual(r,`style`,s);for(var c=[`symbol`,`symbolSize`,`symbolKeepAspect`],l=0;l<c.length;l++){var u=o.getShallow(c[l],!0);u!=null&&n.setItemVisual(r,c[l],u)}}),n.count()&&r.each(function(e){var t=r.getItemModel(e).getShallow(`category`);if(t!=null){Y(t)&&(t=i[`ec-`+t]);var a=n.getItemVisual(t,`style`);K(r.ensureUniqueItemVisual(e,`style`),a);for(var o=[`symbol`,`symbolSize`,`symbolKeepAspect`],s=0;s<o.length;s++)r.setItemVisual(e,o[s],n.getItemVisual(t,o[s]))}})})}function cz(e){return e instanceof Array||(e=[e,e]),e}function lz(e){e.eachSeriesByType(`graph`,function(e){var t=e.getGraph(),n=e.getEdgeData(),r=cz(e.get(`edgeSymbol`)),i=cz(e.get(`edgeSymbolSize`));n.setVisual(`fromSymbol`,r&&r[0]),n.setVisual(`toSymbol`,r&&r[1]),n.setVisual(`fromSymbolSize`,i&&i[0]),n.setVisual(`toSymbolSize`,i&&i[1]),n.setVisual(`style`,e.getModel(`lineStyle`).getLineStyle()),n.each(function(e){var r=n.getItemModel(e),i=t.getEdgeByIndex(e),a=cz(r.getShallow(`symbol`,!0)),o=cz(r.getShallow(`symbolSize`,!0)),s=r.getModel(`lineStyle`).getLineStyle(),c=n.ensureUniqueItemVisual(e,`style`);switch(K(c,s),c.stroke){case`source`:var l=i.node1.getVisual(`style`);c.stroke=l&&l.fill;break;case`target`:var l=i.node2.getVisual(`style`);c.stroke=l&&l.fill}a[0]&&i.setVisual(`fromSymbol`,a[0]),a[1]&&i.setVisual(`toSymbol`,a[1]),o[0]&&i.setVisual(`fromSymbolSize`,o[0]),o[1]&&i.setVisual(`toSymbolSize`,o[1])})})}var uz=`-->`,dz=function(e){return e.get(`autoCurveness`)||null},fz=function(e,t){var n=dz(e),r=20,i=[];if(cp(n))r=n;else if(J(n)){e.__curvenessList=n;return}t>r&&(r=t);var a=r%2?r+2:r+3;i=[];for(var o=0;o<a;o++)i.push((o%2?o+1:o)/10*(o%2?-1:1));e.__curvenessList=i},pz=function(e,t,n){var r=[e.id,e.dataIndex].join(`.`),i=[t.id,t.dataIndex].join(`.`);return[n.uid,r,i].join(uz)},mz=function(e){var t=e.split(uz);return[t[0],t[2],t[1]].join(uz)},hz=function(e,t){var n=pz(e.node1,e.node2,t);return t.__edgeMap[n]},gz=function(e,t){return _z(pz(e.node1,e.node2,t),t)+_z(pz(e.node2,e.node1,t),t)},_z=function(e,t){var n=t.__edgeMap;return n[e]?n[e].length:0};function vz(e){dz(e)&&(e.__curvenessList=[],e.__edgeMap={},fz(e))}function yz(e,t,n,r){if(dz(n)){var i=pz(e,t,n),a=n.__edgeMap,o=a[mz(i)];a[i]&&!o?a[i].isForward=!0:o&&a[i]&&(o.isForward=!0,a[i].isForward=!1),a[i]=a[i]||[],a[i].push(r)}}function bz(e,t,n,r){var i=dz(t),a=J(i);if(!i)return null;var o=hz(e,t);if(!o)return null;for(var s=-1,c=0;c<o.length;c++)if(o[c]===n){s=c;break}var l=gz(e,t);fz(t,l),e.lineStyle=e.lineStyle||{};var u=pz(e.node1,e.node2,t),d=t.__curvenessList,f=a||l%2?0:1;if(o.isForward)return d[f+s];var p=_z(mz(u),t),m=d[s+p+f];return r?a?i&&i[0]===0?(p+f)%2?m:-m:((p%2?0:1)+f)%2?m:-m:(p+f)%2?m:-m:d[s+p+f]}function xz(e){var t=e.coordinateSystem;if(!(t&&t.type!==`view`)){var n=e.getGraph();n.eachNode(function(e){var t=e.getModel();e.setLayout([+t.get(`x`),+t.get(`y`)])}),Sz(n,e)}}function Sz(e,t){e.eachEdge(function(e,n){var r=gp(e.getModel().get([`lineStyle`,`curveness`]),-bz(e,t,n,!0),0),i=Ip(e.node1.getLayout()),a=Ip(e.node2.getLayout()),o=[i,a];+r&&o.push([(i[0]+a[0])/2-(i[1]-a[1])*r,(i[1]+a[1])/2-(a[0]-i[0])*r]),e.setLayout(o)})}function Cz(e,t){e.eachSeriesByType(`graph`,function(e){var t=e.get(`layout`),n=e.coordinateSystem;if(n&&n.type!==`view`){var r=e.getData(),i=[];q(n.dimensions,function(e){i=i.concat(r.mapDimensionsAll(e))});for(var a=0;a<r.count();a++){for(var o=[],s=!1,c=0;c<i.length;c++){var l=r.get(i[c],a);isNaN(l)||(s=!0),o.push(l)}s?r.setItemLayout(a,n.dataToPoint(o)):r.setItemLayout(a,[NaN,NaN])}Sz(r.graph,e)}else t&&t!==`none`||xz(e)})}function wz(e){var t=e.coordinateSystem;if(t.type!==`view`)return 1;var n=e.option.nodeScaleRatio,r=t.scaleX;return((t.getZoom()-1)*n+1)/r}function Tz(e){var t=e.getVisual(`symbolSize`);return t instanceof Array&&(t=(t[0]+t[1])/2),+t}var Ez=Math.PI,Dz=[];function Oz(e,t,n,r){var i=e.coordinateSystem;if(!(i&&i.type!==`view`)){var a=i.getBoundingRect(),o=e.getData(),s=o.graph,c=a.width/2+a.x,l=a.height/2+a.y,u=Math.min(a.width,a.height)/2,d=o.count();if(o.setLayout({cx:c,cy:l}),d){if(n){var f=i.pointToData(r),p=f[0],m=f[1],h=[p-c,m-l];Wp(h,h),Up(h,h,u),n.setLayout([c+h[0],l+h[1]],!0),Az(n,e.get([`circular`,`rotateLabel`]),c,l)}kz[t](e,s,o,u,c,l,d),s.eachEdge(function(t,n){var r=gp(t.getModel().get([`lineStyle`,`curveness`]),bz(t,e,n),0),i=Ip(t.node1.getLayout()),a=Ip(t.node2.getLayout()),o,s=(i[0]+a[0])/2,u=(i[1]+a[1])/2;+r&&(r*=3,o=[c*r+s*(1-r),l*r+u*(1-r)]),t.setLayout([i,a,o])})}}}var kz={value:function(e,t,n,r,i,a,o){var s=0,c=n.getSum(`value`),l=Math.PI*2/(c||o);t.eachNode(function(e){var t=e.getValue(`value`),n=l*(c?t:1)/2;s+=n,e.setLayout([r*Math.cos(s)+i,r*Math.sin(s)+a]),s+=n})},symbolSize:function(e,t,n,r,i,a,o){var s=0;Dz.length=o;var c=wz(e);t.eachNode(function(e){var t=Tz(e);isNaN(t)&&(t=2),t<0&&(t=0),t*=c;var n=Math.asin(t/2/r);isNaN(n)&&(n=Ez/2),Dz[e.dataIndex]=n,s+=n*2});var l=(2*Ez-s)/o/2,u=0;t.eachNode(function(e){var t=l+Dz[e.dataIndex];u+=t,e.getLayout()&&e.getLayout().fixed||e.setLayout([r*Math.cos(u)+i,r*Math.sin(u)+a]),u+=t})}};function Az(e,t,n,r){var i=e.getGraphicEl();if(i){var a=e.getModel().get([`label`,`rotate`])||0,o=i.getSymbolPath();if(t){var s=e.getLayout(),c=Math.atan2(s[1]-r,s[0]-n);c<0&&(c=Math.PI*2+c);var l=s[0]<n;l&&(c-=Math.PI);var u=l?`left`:`right`;o.setTextConfig({rotation:-c,position:u,origin:`center`});var d=o.ensureState(`emphasis`);K(d.textConfig||={},{position:u})}else o.setTextConfig({rotation:a*=Math.PI/180})}}function jz(e){e.eachSeriesByType(`graph`,function(e){e.get(`layout`)===`circular`&&Oz(e,`symbolSize`)})}var Mz=zp;function Nz(e,t,n){for(var r=e,i=t,a=n.rect,o=a.width,s=a.height,c=[a.x+o/2,a.y+s/2],l=n.gravity==null?.1:n.gravity,u=0;u<r.length;u++){var d=r[u];d.p||=Pp(o*(Math.random()-.5)+c[0],s*(Math.random()-.5)+c[1]),d.pp=Ip(d.p),d.edges=null}var f=n.friction==null?.6:n.friction,p=f,m,h;return{warmUp:function(){p=f*.8},setFixed:function(e){r[e].fixed=!0},setUnfixed:function(e){r[e].fixed=!1},beforeStep:function(e){m=e},afterStep:function(e){h=e},step:function(e){m&&m(r,i);for(var t=[],n=r.length,a=0;a<i.length;a++){var o=i[a];if(!o.ignoreForceLayout){var s=o.n1,u=o.n2;Bp(t,u.p,s.p);var d=Vp(t)-o.d,f=u.w/(s.w+u.w);isNaN(f)&&(f=0),Wp(t,t),!s.fixed&&Mz(s.p,s.p,t,f*d*p),!u.fixed&&Mz(u.p,u.p,t,-(1-f)*d*p)}}for(var a=0;a<n;a++){var g=r[a];g.fixed||(Bp(t,c,g.p),Mz(g.p,g.p,t,l*p))}for(var a=0;a<n;a++)for(var s=r[a],_=a+1;_<n;_++){var u=r[_];Bp(t,u.p,s.p);var d=Vp(t);d===0&&(Lp(t,Math.random()-.5,Math.random()-.5),d=1);var v=(s.rep+u.rep)/d/d;!s.fixed&&Mz(s.pp,s.pp,t,v),!u.fixed&&Mz(u.pp,u.pp,t,-v)}for(var y=[],a=0;a<n;a++){var g=r[a];g.fixed||(Bp(y,g.p,g.pp),Mz(g.p,g.p,y,p),Fp(g.pp,g.p))}p*=.992;var b=p<.01;h&&h(r,i,b),e&&e(b)}}}function Pz(e){e.eachSeriesByType(`graph`,function(e){var t=e.coordinateSystem;if(!(t&&t.type!==`view`)){if(e.get(`layout`)===`force`){var n=e.preservedPoints||{},r=e.getGraph(),i=r.data,a=r.edgeData,o=e.getModel(`force`),s=o.get(`initLayout`);e.preservedPoints?i.each(function(e){var t=i.getId(e);i.setItemLayout(e,n[t]||[NaN,NaN])}):!s||s===`none`?xz(e):s===`circular`&&Oz(e,`value`);var c=i.getDataExtent(`value`),l=a.getDataExtent(`value`),u=o.get(`repulsion`),d=o.get(`edgeLength`),f=J(u)?u:[u,u],p=J(d)?d:[d,d];p=[p[1],p[0]];var m=i.mapArray(`value`,function(e,t){var n=i.getItemLayout(t),r=cv(e,c,f);return isNaN(r)&&(r=(f[0]+f[1])/2),{w:r,rep:r,fixed:i.getItemModel(t).get(`fixed`),p:!n||isNaN(n[0])||isNaN(n[1])?null:n}}),h=Nz(m,a.mapArray(`value`,function(t,n){var i=r.getEdgeByIndex(n),a=cv(t,l,p);isNaN(a)&&(a=(p[0]+p[1])/2);var o=i.getModel(),s=gp(i.getModel().get([`lineStyle`,`curveness`]),-bz(i,e,n,!0),0);return{n1:m[i.node1.dataIndex],n2:m[i.node2.dataIndex],d:a,curveness:s,ignoreForceLayout:o.get(`ignoreForceLayout`)}}),{rect:t.getBoundingRect(),gravity:o.get(`gravity`),friction:o.get(`friction`)});h.beforeStep(function(e,t){for(var n=0,i=e.length;n<i;n++)e[n].fixed&&Fp(e[n].p,r.getNodeByIndex(n).getLayout())}),h.afterStep(function(e,t,a){for(var o=0,s=e.length;o<s;o++)e[o].fixed||r.getNodeByIndex(o).setLayout(e[o].p),n[i.getId(o)]=e[o].p;for(var o=0,s=t.length;o<s;o++){var c=t[o],l=r.getEdgeByIndex(o),u=c.n1.p,d=c.n2.p,f=l.getLayout();f=f?f.slice():[],f[0]=f[0]||[],f[1]=f[1]||[],Fp(f[0],u),Fp(f[1],d),+c.curveness&&(f[2]=[(u[0]+d[0])/2-(u[1]-d[1])*c.curveness,(u[1]+d[1])/2-(d[0]-u[0])*c.curveness]),l.setLayout(f)}}),e.forceLayout=h,e.preservedPoints=n,h.step()}else e.forceLayout=null}})}function Fz(e,t,n){return nE(K(e.getBoxLayoutParams(),{aspect:n}),{width:t.getWidth(),height:t.getHeight()})}function Iz(e,t){var n=[];return e.eachSeriesByType(`graph`,function(e){var r=e.get(`coordinateSystem`);if(!r||r===`view`){var i=e.getData(),a=i.mapArray(function(e){var t=i.getItemModel(e);return[+t.get(`x`),+t.get(`y`)]}),o=[],s=[];tb(a,o,s),s[0]-o[0]===0&&(s[0]+=1,--o[0]),s[1]-o[1]===0&&(s[1]+=1,--o[1]);var c=(s[0]-o[0])/(s[1]-o[1]),l=Fz(e,t,c);isNaN(c)&&(o=[l.x,l.y],s=[l.x+l.width,l.y+l.height]);var u=s[0]-o[0],d=s[1]-o[1],f=l.width,p=l.height,m=e.coordinateSystem=new TF;m.zoomLimit=e.get(`scaleLimit`),m.setBoundingRect(o[0],o[1],u,d),m.setViewRect(l.x,l.y,f,p),m.setCenter(e.get(`center`),t),m.setZoom(e.get(`zoom`)),n.push(m)}}),n}var Lz=[],Rz=[],zz=[],Bz=Rh,Vz=Jp,Hz=Math.abs;function Uz(e,t,n){for(var r=e[0],i=e[1],a=e[2],o=1/0,s,c=n*n,l=.1,u=.1;u<=.9;u+=.1){Lz[0]=Bz(r[0],i[0],a[0],u),Lz[1]=Bz(r[1],i[1],a[1],u);var d=Hz(Vz(Lz,t)-c);d<o&&(o=d,s=u)}for(var f=0;f<32;f++){var p=s+l;Rz[0]=Bz(r[0],i[0],a[0],s),Rz[1]=Bz(r[1],i[1],a[1],s),zz[0]=Bz(r[0],i[0],a[0],p),zz[1]=Bz(r[1],i[1],a[1],p);var d=Vz(Rz,t)-c;if(Hz(d)<.01)break;var m=Vz(zz,t)-c;l/=2,d<0?m>=0?s+=l:s-=l:m>=0?s-=l:s+=l}return s}function Wz(e,t){var n=[],r=Hh,i=[[],[],[]],a=[[],[]],o=[];t/=2,e.eachEdge(function(e,s){var c=e.getLayout(),l=e.getVisual(`fromSymbol`),u=e.getVisual(`toSymbol`);c.__original||(c.__original=[Ip(c[0]),Ip(c[1])],c[2]&&c.__original.push(Ip(c[2])));var d=c.__original;if(c[2]!=null){if(Fp(i[0],d[0]),Fp(i[1],d[2]),Fp(i[2],d[1]),l&&l!==`none`){var f=Tz(e.node1),p=Uz(i,d[0],f*t);r(i[0][0],i[1][0],i[2][0],p,n),i[0][0]=n[3],i[1][0]=n[4],r(i[0][1],i[1][1],i[2][1],p,n),i[0][1]=n[3],i[1][1]=n[4]}if(u&&u!==`none`){var f=Tz(e.node2),p=Uz(i,d[1],f*t);r(i[0][0],i[1][0],i[2][0],p,n),i[1][0]=n[1],i[2][0]=n[2],r(i[0][1],i[1][1],i[2][1],p,n),i[1][1]=n[1],i[2][1]=n[2]}Fp(c[0],i[0]),Fp(c[1],i[2]),Fp(c[2],i[1])}else{if(Fp(a[0],d[0]),Fp(a[1],d[1]),Bp(o,a[1],a[0]),Wp(o,o),l&&l!==`none`){var f=Tz(e.node1);zp(a[0],a[0],o,f*t)}if(u&&u!==`none`){var f=Tz(e.node2);zp(a[1],a[1],o,-f*t)}Fp(c[0],a[0]),Fp(c[1],a[1])}})}function Gz(e){return e.type===`view`}var Kz=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.init=function(e,t){var n=new GI,r=new iL,i=this.group;this._controller=new MF(t.getZr()),this._controllerHost={target:i},i.add(n.group),i.add(r.group),this._symbolDraw=n,this._lineDraw=r,this._firstRender=!0},t.prototype.render=function(e,t,n){var r=this,i=e.coordinateSystem;this._model=e;var a=this._symbolDraw,o=this._lineDraw,s=this.group;if(Gz(i)){var c={x:i.x,y:i.y,scaleX:i.scaleX,scaleY:i.scaleY};this._firstRender?s.attr(c):ew(s,c,e)}Wz(e.getGraph(),wz(e));var l=e.getData();a.updateData(l);var u=e.getEdgeData();o.updateData(u),this._updateNodeAndLinkScale(),this._updateController(e,t,n),clearTimeout(this._layoutTimeout);var d=e.forceLayout,f=e.get([`force`,`layoutAnimation`]);d&&this._startForceLayoutIteration(d,f);var p=e.get(`layout`);l.graph.eachNode(function(t){var n=t.dataIndex,i=t.getGraphicEl(),a=t.getModel();if(i){i.off(`drag`).off(`dragend`);var o=a.get(`draggable`);o&&i.on(`drag`,function(a){switch(p){case`force`:d.warmUp(),!r._layouting&&r._startForceLayoutIteration(d,f),d.setFixed(n),l.setItemLayout(n,[i.x,i.y]);break;case`circular`:l.setItemLayout(n,[i.x,i.y]),t.setLayout({fixed:!0},!0),Oz(e,`symbolSize`,t,[a.offsetX,a.offsetY]),r.updateLayout(e);break;default:l.setItemLayout(n,[i.x,i.y]),Sz(e.getGraph(),e),r.updateLayout(e)}}).on(`dragend`,function(){d&&d.setUnfixed(n)}),i.setDraggable(o,!!a.get(`cursor`)),a.get([`emphasis`,`focus`])===`adjacency`&&(Ax(i).focus=t.getAdjacentDataIndices())}}),l.graph.eachEdge(function(e){var t=e.getGraphicEl(),n=e.getModel().get([`emphasis`,`focus`]);t&&n===`adjacency`&&(Ax(t).focus={edge:[e.dataIndex],node:[e.node1.dataIndex,e.node2.dataIndex]})});var m=e.get(`layout`)===`circular`&&e.get([`circular`,`rotateLabel`]),h=l.getLayout(`cx`),g=l.getLayout(`cy`);l.graph.eachNode(function(e){Az(e,m,h,g)}),this._firstRender=!1},t.prototype.dispose=function(){this.remove(),this._controller&&this._controller.dispose(),this._controllerHost=null},t.prototype._startForceLayoutIteration=function(e,t){var n=this;(function r(){e.step(function(e){n.updateLayout(n._model),(n._layouting=!e)&&(t?n._layoutTimeout=setTimeout(r,16):r())})})()},t.prototype._updateController=function(e,t,n){var r=this,i=this._controller,a=this._controllerHost,o=this.group;i.setPointerChecker(function(t,r,i){var a=o.getBoundingRect();return a.applyTransform(o.transform),a.contain(r,i)&&!zF(t,n,e)}),Gz(e.coordinateSystem)?(i.enable(e.get(`roam`)),a.zoomLimit=e.get(`scaleLimit`),a.zoom=e.coordinateSystem.getZoom(),i.off(`pan`).off(`zoom`).on(`pan`,function(t){IF(a,t.dx,t.dy),n.dispatchAction({seriesId:e.id,type:`graphRoam`,dx:t.dx,dy:t.dy})}).on(`zoom`,function(t){LF(a,t.scale,t.originX,t.originY),n.dispatchAction({seriesId:e.id,type:`graphRoam`,zoom:t.scale,originX:t.originX,originY:t.originY}),r._updateNodeAndLinkScale(),Wz(e.getGraph(),wz(e)),r._lineDraw.updateLayout(),n.updateLabelLayout()})):i.disable()},t.prototype._updateNodeAndLinkScale=function(){var e=this._model,t=e.getData(),n=wz(e);t.eachItemGraphicEl(function(e,t){e&&e.setSymbolScale(n)})},t.prototype.updateLayout=function(e){Wz(e.getGraph(),wz(e)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},t.prototype.remove=function(){clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},t.type=`graph`,t}(Tk);function qz(e){return`_EC_`+e}var Jz=function(){function e(e){this.type=`graph`,this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=e||!1}return e.prototype.isDirected=function(){return this._directed},e.prototype.addNode=function(e,t){e=e==null?``+t:``+e;var n=this._nodesMap;if(!n[qz(e)]){var r=new Yz(e,t);return r.hostGraph=this,this.nodes.push(r),n[qz(e)]=r,r}},e.prototype.getNodeByIndex=function(e){var t=this.data.getRawIndex(e);return this.nodes[t]},e.prototype.getNodeById=function(e){return this._nodesMap[qz(e)]},e.prototype.addEdge=function(e,t,n){var r=this._nodesMap,i=this._edgesMap;if(cp(e)&&(e=this.nodes[e]),cp(t)&&(t=this.nodes[t]),e instanceof Yz||(e=r[qz(e)]),t instanceof Yz||(t=r[qz(t)]),e&&t){var a=e.id+`-`+t.id,o=new Xz(e,t,n);return o.hostGraph=this,this._directed&&(e.outEdges.push(o),t.inEdges.push(o)),e.edges.push(o),e!==t&&t.edges.push(o),this.edges.push(o),i[a]=o,o}},e.prototype.getEdgeByIndex=function(e){var t=this.edgeData.getRawIndex(e);return this.edges[t]},e.prototype.getEdge=function(e,t){e instanceof Yz&&(e=e.id),t instanceof Yz&&(t=t.id);var n=this._edgesMap;return this._directed?n[e+`-`+t]:n[e+`-`+t]||n[t+`-`+e]},e.prototype.eachNode=function(e,t){for(var n=this.nodes,r=n.length,i=0;i<r;i++)n[i].dataIndex>=0&&e.call(t,n[i],i)},e.prototype.eachEdge=function(e,t){for(var n=this.edges,r=n.length,i=0;i<r;i++)n[i].dataIndex>=0&&n[i].node1.dataIndex>=0&&n[i].node2.dataIndex>=0&&e.call(t,n[i],i)},e.prototype.breadthFirstTraverse=function(e,t,n,r){if(t instanceof Yz||(t=this._nodesMap[qz(t)]),t){for(var i=n===`out`?`outEdges`:n===`in`?`inEdges`:`edges`,a=0;a<this.nodes.length;a++)this.nodes[a].__visited=!1;if(!e.call(r,t,null))for(var o=[t];o.length;)for(var s=o.shift(),c=s[i],a=0;a<c.length;a++){var l=c[a],u=l.node1===s?l.node2:l.node1;if(!u.__visited){if(e.call(r,u,s))return;o.push(u),u.__visited=!0}}}},e.prototype.update=function(){for(var e=this.data,t=this.edgeData,n=this.nodes,r=this.edges,i=0,a=n.length;i<a;i++)n[i].dataIndex=-1;for(var i=0,a=e.count();i<a;i++)n[e.getRawIndex(i)].dataIndex=i;t.filterSelf(function(e){var n=r[t.getRawIndex(e)];return n.node1.dataIndex>=0&&n.node2.dataIndex>=0});for(var i=0,a=r.length;i<a;i++)r[i].dataIndex=-1;for(var i=0,a=t.count();i<a;i++)r[t.getRawIndex(i)].dataIndex=i},e.prototype.clone=function(){for(var t=new e(this._directed),n=this.nodes,r=this.edges,i=0;i<n.length;i++)t.addNode(n[i].id,n[i].dataIndex);for(var i=0;i<r.length;i++){var a=r[i];t.addEdge(a.node1.id,a.node2.id,a.dataIndex)}return t},e}(),Yz=function(){function e(e,t){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=e??``,this.dataIndex=t??-1}return e.prototype.degree=function(){return this.edges.length},e.prototype.inDegree=function(){return this.inEdges.length},e.prototype.outDegree=function(){return this.outEdges.length},e.prototype.getModel=function(e){if(!(this.dataIndex<0))return this.hostGraph.data.getItemModel(this.dataIndex).getModel(e)},e.prototype.getAdjacentDataIndices=function(){for(var e={edge:[],node:[]},t=0;t<this.edges.length;t++){var n=this.edges[t];n.dataIndex<0||(e.edge.push(n.dataIndex),e.node.push(n.node1.dataIndex,n.node2.dataIndex))}return e},e.prototype.getTrajectoryDataIndices=function(){for(var e=Q(),t=Q(),n=0;n<this.edges.length;n++){var r=this.edges[n];if(!(r.dataIndex<0)){e.set(r.dataIndex,!0);for(var i=[r.node1],a=[r.node2],o=0;o<i.length;){var s=i[o];o++,t.set(s.dataIndex,!0);for(var c=0;c<s.inEdges.length;c++)e.set(s.inEdges[c].dataIndex,!0),i.push(s.inEdges[c].node1)}for(o=0;o<a.length;){var l=a[o];o++,t.set(l.dataIndex,!0);for(var c=0;c<l.outEdges.length;c++)e.set(l.outEdges[c].dataIndex,!0),a.push(l.outEdges[c].node2)}}}return{edge:e.keys(),node:t.keys()}},e}(),Xz=function(){function e(e,t,n){this.dataIndex=-1,this.node1=e,this.node2=t,this.dataIndex=n??-1}return e.prototype.getModel=function(e){if(!(this.dataIndex<0))return this.hostGraph.edgeData.getItemModel(this.dataIndex).getModel(e)},e.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},e.prototype.getTrajectoryDataIndices=function(){var e=Q(),t=Q();e.set(this.dataIndex,!0);for(var n=[this.node1],r=[this.node2],i=0;i<n.length;){var a=n[i];i++,t.set(a.dataIndex,!0);for(var o=0;o<a.inEdges.length;o++)e.set(a.inEdges[o].dataIndex,!0),n.push(a.inEdges[o].node1)}for(i=0;i<r.length;){var s=r[i];i++,t.set(s.dataIndex,!0);for(var o=0;o<s.outEdges.length;o++)e.set(s.outEdges[o].dataIndex,!0),r.push(s.outEdges[o].node2)}return{edge:e.keys(),node:t.keys()}},e}();function Zz(e,t){return{getValue:function(n){var r=this[e][t];return r.getStore().get(r.getDimensionIndex(n||`value`),this.dataIndex)},setVisual:function(n,r){this.dataIndex>=0&&this[e][t].setItemVisual(this.dataIndex,n,r)},getVisual:function(n){return this[e][t].getItemVisual(this.dataIndex,n)},setLayout:function(n,r){this.dataIndex>=0&&this[e][t].setItemLayout(this.dataIndex,n,r)},getLayout:function(){return this[e][t].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[e][t].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[e][t].getRawIndex(this.dataIndex)}}}Zf(Yz,Zz(`hostGraph`,`data`)),Zf(Xz,Zz(`hostGraph`,`edgeData`));function Qz(e,t,n,r,i){for(var a=new Jz(r),o=0;o<e.length;o++)a.addNode(hp(e[o].id,e[o].name,o),o);for(var s=[],c=[],l=0,o=0;o<t.length;o++){var u=t[o],d=u.source,f=u.target;a.addEdge(d,f,l)&&(c.push(u),s.push(hp(Bv(u.id,null),d+` > `+f)),l++)}var p=n.get(`coordinateSystem`),m;if(p===`cartesian2d`||p===`polar`)m=YN(e,n);else{var h=$E.get(p),g=h&&h.dimensions||[];Yf(g,`value`)<0&&g.concat([`value`]);var _=LN(e,{coordDimensions:g,encodeDefine:n.getEncode()}).dimensions;m=new IN(_,n),m.initData(e)}var v=new IN([`value`],n);return v.initData(c,s),i&&i(m,v),LL({mainData:m,struct:a,structAttr:`graph`,datas:{node:m,edge:v},datasAttr:{node:`data`,edge:`edgeData`}}),a.update(),a}var $z=function(e){U(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return t.prototype.init=function(t){e.prototype.init.apply(this,arguments);var n=this;function r(){return n._categoriesData}this.legendVisualProvider=new FL(r,r),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},t.prototype.mergeOption=function(t){e.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},t.prototype.mergeDefaultAndTheme=function(t){e.prototype.mergeDefaultAndTheme.apply(this,arguments),Dv(t,`edgeLabel`,[`show`])},t.prototype.getInitialData=function(e,t){var n=e.edges||e.links||[],r=e.data||e.nodes||[],i=this;if(r&&n){vz(this);var a=Qz(r,n,this,!0,o);return q(a.edges,function(e){yz(e.node1,e.node2,this,e.dataIndex)},this),a.data}function o(e,t){e.wrapMethod(`getItemModel`,function(e){var t=i._categoriesModels[e.getShallow(`category`)];return t&&(t.parentModel=e.parentModel,e.parentModel=t),e});var n=dT.prototype.getModel;function r(e,t){var r=n.call(this,e,t);return r.resolveParentPath=a,r}t.wrapMethod(`getItemModel`,function(e){return e.resolveParentPath=a,e.getModel=r,e});function a(e){if(e&&(e[0]===`label`||e[1]===`label`)){var t=e.slice();return e[0]===`label`?t[0]=`edgeLabel`:e[1]===`label`&&(t[1]=`edgeLabel`),t}return e}}},t.prototype.getGraph=function(){return this.getData().graph},t.prototype.getEdgeData=function(){return this.getGraph().edgeData},t.prototype.getCategoriesData=function(){return this._categoriesData},t.prototype.formatTooltip=function(e,t,n){if(n===`edge`){var r=this.getData(),i=this.getDataParams(e,n),a=r.graph.getEdgeByIndex(e),o=r.getName(a.node1.dataIndex),s=r.getName(a.node2.dataIndex),c=[];return o!=null&&c.push(o),s!=null&&c.push(s),KO(`nameValue`,{name:c.join(` > `),value:i.value,noValue:i.value==null})}return ck({series:this,dataIndex:e,multipleSeries:t})},t.prototype._updateCategoriesData=function(){var e=$f(this.option.categories||[],function(e){return e.value==null?K({value:0},e):e}),t=new IN([`value`],this);t.initData(e),this._categoriesData=t,this._categoriesModels=t.mapArray(function(e){return t.getItemModel(e)})},t.prototype.setZoom=function(e){this.option.zoom=e},t.prototype.setCenter=function(e){this.option.center=e},t.prototype.isAnimationEnabled=function(){return e.prototype.isAnimationEnabled.call(this)&&!(this.get(`layout`)===`force`&&this.get([`force`,`layoutAnimation`]))},t.type=`series.graph`,t.dependencies=[`grid`,`polar`,`geo`,`singleAxis`,`calendar`],t.defaultOption={z:2,coordinateSystem:`view`,legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:`center`,top:`center`,symbol:`circle`,symbolSize:10,edgeSymbol:[`none`,`none`],edgeSymbolSize:10,edgeLabel:{position:`middle`,distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:`{b}`},itemStyle:{},lineStyle:{color:`#aaa`,width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:`#212121`}}},t}(fk),eB={type:`graphRoam`,event:`graphRoam`,update:`none`};function tB(e){e.registerChartView(Kz),e.registerSeriesModel($z),e.registerProcessor(oz),e.registerVisual(sz),e.registerVisual(lz),e.registerLayout(Cz),e.registerLayout(e.PRIORITY.VISUAL.POST_CHART_LAYOUT,jz),e.registerLayout(Pz),e.registerCoordinateSystem(`graphView`,{dimensions:TF.dimensions,create:Iz}),e.registerAction({type:`focusNodeAdjacency`,event:`focusNodeAdjacency`,update:`series:focusNodeAdjacency`},Mp),e.registerAction({type:`unfocusNodeAdjacency`,event:`unfocusNodeAdjacency`,update:`series:unfocusNodeAdjacency`},Mp),e.registerAction(eB,function(e,t,n){t.eachComponent({mainType:`series`,query:e},function(t){var r=t.coordinateSystem,i=OF(r,e,void 0,n);t.setCenter&&t.setCenter(i.center),t.setZoom&&t.setZoom(i.zoom)})})}function nB(e,t,n){var r=Mf.createCanvas(),i=t.getWidth(),a=t.getHeight(),o=r.style;return o&&(o.position=`absolute`,o.left=`0`,o.top=`0`,o.width=i+`px`,o.height=a+`px`,r.setAttribute(`data-zr-dom-id`,e)),r.width=i*n,r.height=a*n,r}var rB=function(e){U(t,e);function t(t,n,r){var i=e.call(this)||this;i.motionBlur=!1,i.lastFrameAlpha=.7,i.dpr=1,i.virtual=!1,i.config={},i.incremental=!1,i.zlevel=0,i.maxRepaintRectCount=5,i.__dirty=!0,i.__firstTimePaint=!0,i.__used=!1,i.__drawIndex=0,i.__startIndex=0,i.__endIndex=0,i.__prevStartIndex=null,i.__prevEndIndex=null;var a;r||=m_,typeof t==`string`?a=nB(t,n,r):X(t)&&(a=t,t=a.id),i.id=t,i.dom=a;var o=a.style;return o&&(Ap(a),a.onselectstart=function(){return!1},o.padding=`0`,o.margin=`0`,o.borderWidth=`0`),i.painter=n,i.dpr=r,i}return t.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},t.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},t.prototype.initContext=function(){this.ctx=this.dom.getContext(`2d`),this.ctx.dpr=this.dpr},t.prototype.setUnpainted=function(){this.__firstTimePaint=!0},t.prototype.createBackBuffer=function(){var e=this.dpr;this.domBack=nB(`back-`+this.id,this.painter,e),this.ctxBack=this.domBack.getContext(`2d`),e!==1&&this.ctxBack.scale(e,e)},t.prototype.createRepaintRects=function(e,t,n,r){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var i=[],a=this.maxRepaintRectCount,o=!1,s=new $(0,0,0,0);function c(e){if(e.isFinite()&&!e.isZero()){if(i.length===0){var t=new $(0,0,0,0);t.copy(e),i.push(t)}else{for(var n=!1,r=1/0,c=0,l=0;l<i.length;++l){var u=i[l];if(u.intersect(e)){var d=new $(0,0,0,0);d.copy(u),d.union(e),i[l]=d,n=!0;break}if(o){s.copy(e),s.union(u);var f=e.width*e.height,p=u.width*u.height,m=s.width*s.height-f-p;m<r&&(r=m,c=l)}}if(o&&(i[c].union(e),n=!0),!n){var t=new $(0,0,0,0);t.copy(e),i.push(t)}o||=i.length>=a}}}for(var l=this.__startIndex;l<this.__endIndex;++l){var u=e[l];if(u){var d=u.shouldBePainted(n,r,!0,!0),f=u.__isRendered&&(u.__dirty&1||!d)?u.getPrevPaintRect():null;f&&c(f);var p=d&&(u.__dirty&1||!u.__isRendered)?u.getPaintRect():null;p&&c(p)}}for(var l=this.__prevStartIndex;l<this.__prevEndIndex;++l){var u=t[l],d=u&&u.shouldBePainted(n,r,!0,!0);if(u&&(!d||!u.__zr)&&u.__isRendered){var f=u.getPrevPaintRect();f&&c(f)}}var m;do{m=!1;for(var l=0;l<i.length;)if(i[l].isZero())i.splice(l,1);else{for(var h=l+1;h<i.length;)i[l].intersect(i[h])?(m=!0,i[l].union(i[h]),i.splice(h,1)):h++;l++}}while(m);return this._paintRects=i,i},t.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},t.prototype.resize=function(e,t){var n=this.dpr,r=this.dom,i=r.style,a=this.domBack;i&&(i.width=e+`px`,i.height=t+`px`),r.width=e*n,r.height=t*n,a&&(a.width=e*n,a.height=t*n,n!==1&&this.ctxBack.scale(n,n))},t.prototype.clear=function(e,t,n){var r=this.dom,i=this.ctx,a=r.width,o=r.height;t||=this.clearColor;var s=this.motionBlur&&!e,c=this.lastFrameAlpha,l=this.dpr,u=this;s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation=`copy`,this.ctxBack.drawImage(r,0,0,a/l,o/l));var d=this.domBack;function f(e,n,r,a){if(i.clearRect(e,n,r,a),t&&t!==`transparent`){var o=void 0;fp(t)?(o=(t.global||t.__width===r&&t.__height===a)&&t.__canvasGradient||VA(i,t,{x:0,y:0,width:r,height:a}),t.__canvasGradient=o,t.__width=r,t.__height=a):pp(t)&&(t.scaleX=t.scaleX||l,t.scaleY=t.scaleY||l,o=$A(i,t,{dirty:function(){u.setUnpainted(),u.painter.refresh()}})),i.save(),i.fillStyle=o||t,i.fillRect(e,n,r,a),i.restore()}s&&(i.save(),i.globalAlpha=c,i.drawImage(d,e,n,r,a),i.restore())}!n||s?f(0,0,a,o):n.length&&q(n,function(e){f(e.x*l,e.y*l,e.width*l,e.height*l)})},t}(em),iB=1e5,aB=314159,oB=.01,sB=.001;function cB(e){return e?e.__builtin__?!0:typeof e.resize==`function`&&typeof e.refresh==`function`:!1}function lB(e,t){var n=document.createElement(`div`);return n.style.cssText=[`position:relative`,`width:`+e+`px`,`height:`+t+`px`,`padding:0`,`margin:0`,`border-width:0`].join(`;`)+`;`,n}var uB=function(){function e(e,t,n,r){this.type=`canvas`,this._zlevelList=[],this._prevDisplayList=[],this._layers={},this._layerConfig={},this._needsManuallyCompositing=!1,this.type=`canvas`;var i=!e.nodeName||e.nodeName.toUpperCase()===`CANVAS`;this._opts=n=K({},n||{}),this.dpr=n.devicePixelRatio||m_,this._singleCanvas=i,this.root=e,e.style&&(Ap(e),e.innerHTML=``),this.storage=t;var a=this._zlevelList;this._prevDisplayList=[];var o=this._layers;if(i){var s=e,c=s.width,l=s.height;n.width!=null&&(c=n.width),n.height!=null&&(l=n.height),this.dpr=n.devicePixelRatio||1,s.width=c*this.dpr,s.height=l*this.dpr,this._width=c,this._height=l;var u=new rB(s,this,this.dpr);u.__builtin__=!0,u.initContext(),o[aB]=u,u.zlevel=aB,a.push(aB),this._domRoot=e}else{this._width=WA(e,0,n),this._height=WA(e,1,n);var d=this._domRoot=lB(this._width,this._height);e.appendChild(d)}}return e.prototype.getType=function(){return`canvas`},e.prototype.isSingleCanvas=function(){return this._singleCanvas},e.prototype.getViewportRoot=function(){return this._domRoot},e.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},e.prototype.refresh=function(e){var t=this.storage.getDisplayList(!0),n=this._prevDisplayList,r=this._zlevelList;this._redrawId=Math.random(),this._paintList(t,n,e,this._redrawId);for(var i=0;i<r.length;i++){var a=r[i],o=this._layers[a];if(!o.__builtin__&&o.refresh){var s=i===0?this._backgroundColor:null;o.refresh(s)}}return this._opts.useDirtyRect&&(this._prevDisplayList=t.slice()),this},e.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},e.prototype._paintHoverList=function(e){var t=e.length,n=this._hoverlayer;if(n&&n.clear(),t){for(var r={inHover:!0,viewWidth:this._width,viewHeight:this._height},i,a=0;a<t;a++){var o=e[a];o.__inHover&&(n||=this._hoverlayer=this.getLayer(iB),i||(i=n.ctx,i.save()),yj(i,o,r,a===t-1))}i&&i.restore()}},e.prototype.getHoverLayer=function(){return this.getLayer(iB)},e.prototype.paintOne=function(e,t){vj(e,t)},e.prototype._paintList=function(e,t,n,r){if(this._redrawId===r){n||=!1,this._updateLayerStatus(e);var i=this._doPaintList(e,t,n),a=i.finished,o=i.needsRefreshHover;if(this._needsManuallyCompositing&&this._compositeManually(),o&&this._paintHoverList(e),a)this.eachLayer(function(e){e.afterBrush&&e.afterBrush()});else{var s=this;vh(function(){s._paintList(e,t,n,r)})}}},e.prototype._compositeManually=function(){var e=this.getLayer(aB).ctx,t=this._domRoot.width,n=this._domRoot.height;e.clearRect(0,0,t,n),this.eachBuiltinLayer(function(r){r.virtual&&e.drawImage(r.dom,0,0,t,n)})},e.prototype._doPaintList=function(e,t,n){for(var r=this,i=[],a=this._opts.useDirtyRect,o=0;o<this._zlevelList.length;o++){var s=this._zlevelList[o],c=this._layers[s];c.__builtin__&&c!==this._hoverlayer&&(c.__dirty||n)&&i.push(c)}for(var l=!0,u=!1,d=function(o){var s=i[o],c=s.ctx,d=a&&s.createRepaintRects(e,t,f._width,f._height),p=n?s.__startIndex:s.__drawIndex,m=!n&&s.incremental&&Date.now,h=m&&Date.now(),g=s.zlevel===f._zlevelList[0]?f._backgroundColor:null;if(s.__startIndex===s.__endIndex)s.clear(!1,g,d);else if(p===s.__startIndex){var _=e[p];_.incremental&&_.notClear&&!n||s.clear(!1,g,d)}p===-1&&(console.error(`For some unknown reason. drawIndex is -1`),p=s.__startIndex);var v,y=function(t){var n={inHover:!1,allClipped:!1,prevEl:null,viewWidth:r._width,viewHeight:r._height};for(v=p;v<s.__endIndex;v++){var i=e[v];if(i.__inHover&&(u=!0),r._doPaintEl(i,s,a,t,n,v===s.__endIndex-1),m&&Date.now()-h>15)break}n.prevElClipPaths&&c.restore()};if(d){if(d.length===0)v=s.__endIndex;else for(var b=f.dpr,x=0;x<d.length;++x){var S=d[x];c.save(),c.beginPath(),c.rect(S.x*b,S.y*b,S.width*b,S.height*b),c.clip(),y(S),c.restore()}}else c.save(),y(),c.restore();s.__drawIndex=v,s.__drawIndex<s.__endIndex&&(l=!1)},f=this,p=0;p<i.length;p++)d(p);return W.wxa&&q(this._layers,function(e){e&&e.ctx&&e.ctx.draw&&e.ctx.draw()}),{finished:l,needsRefreshHover:u}},e.prototype._doPaintEl=function(e,t,n,r,i,a){var o=t.ctx;if(n){var s=e.getPaintRect();(!r||s&&s.intersect(r))&&(yj(o,e,i,a),e.setPrevPaintRect(s))}else yj(o,e,i,a)},e.prototype.getLayer=function(e,t){this._singleCanvas&&!this._needsManuallyCompositing&&(e=aB);var n=this._layers[e];return n||(n=new rB(`zr_`+e,this,this.dpr),n.zlevel=e,n.__builtin__=!0,this._layerConfig[e]?qf(n,this._layerConfig[e],!0):this._layerConfig[e-oB]&&qf(n,this._layerConfig[e-oB],!0),t&&(n.virtual=t),this.insertLayer(e,n),n.initContext()),n},e.prototype.insertLayer=function(e,t){var n=this._layers,r=this._zlevelList,i=r.length,a=this._domRoot,o=null,s=-1;if(!n[e]&&cB(t)){if(i>0&&e>r[0]){for(s=0;s<i-1&&!(r[s]<e&&r[s+1]>e);s++);o=n[r[s]]}if(r.splice(s+1,0,e),n[e]=t,!t.virtual){if(o){var c=o.dom;c.nextSibling?a.insertBefore(t.dom,c.nextSibling):a.appendChild(t.dom)}else a.firstChild?a.insertBefore(t.dom,a.firstChild):a.appendChild(t.dom)}t.painter||=this}},e.prototype.eachLayer=function(e,t){for(var n=this._zlevelList,r=0;r<n.length;r++){var i=n[r];e.call(t,this._layers[i],i)}},e.prototype.eachBuiltinLayer=function(e,t){for(var n=this._zlevelList,r=0;r<n.length;r++){var i=n[r],a=this._layers[i];a.__builtin__&&e.call(t,a,i)}},e.prototype.eachOtherLayer=function(e,t){for(var n=this._zlevelList,r=0;r<n.length;r++){var i=n[r],a=this._layers[i];a.__builtin__||e.call(t,a,i)}},e.prototype.getLayers=function(){return this._layers},e.prototype._updateLayerStatus=function(e){this.eachBuiltinLayer(function(e,t){e.__dirty=e.__used=!1});function t(e){i&&(i.__endIndex!==e&&(i.__dirty=!0),i.__endIndex=e)}if(this._singleCanvas)for(var n=1;n<e.length;n++){var r=e[n];if(r.zlevel!==e[n-1].zlevel||r.incremental){this._needsManuallyCompositing=!0;break}}for(var i=null,a=0,o,s=0;s<e.length;s++){var r=e[s],c=r.zlevel,l=void 0;o!==c&&(o=c,a=0),r.incremental?(l=this.getLayer(c+sB,this._needsManuallyCompositing),l.incremental=!0,a=1):l=this.getLayer(c+(a>0?oB:0),this._needsManuallyCompositing),l.__builtin__||Kf(`ZLevel `+c+` has been used by unkown layer `+l.id),l!==i&&(l.__used=!0,l.__startIndex!==s&&(l.__dirty=!0),l.__startIndex=s,l.incremental?l.__drawIndex=-1:l.__drawIndex=s,t(s),i=l),r.__dirty&1&&!r.__inHover&&(l.__dirty=!0,l.incremental&&l.__drawIndex<0&&(l.__drawIndex=s))}t(s),this.eachBuiltinLayer(function(e,t){!e.__used&&e.getElementCount()>0&&(e.__dirty=!0,e.__startIndex=e.__endIndex=e.__drawIndex=0),e.__dirty&&e.__drawIndex<0&&(e.__drawIndex=e.__startIndex)})},e.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},e.prototype._clearLayer=function(e){e.clear()},e.prototype.setBackgroundColor=function(e){this._backgroundColor=e,q(this._layers,function(e){e.setUnpainted()})},e.prototype.configLayer=function(e,t){if(t){var n=this._layerConfig;n[e]?qf(n[e],t,!0):n[e]=t;for(var r=0;r<this._zlevelList.length;r++){var i=this._zlevelList[r];if(i===e||i===e+oB){var a=this._layers[i];qf(a,n[e],!0)}}}},e.prototype.delLayer=function(e){var t=this._layers,n=this._zlevelList,r=t[e];r&&(r.dom.parentNode.removeChild(r.dom),delete t[e],n.splice(Yf(n,e),1))},e.prototype.resize=function(e,t){if(this._domRoot.style){var n=this._domRoot;n.style.display=`none`;var r=this._opts,i=this.root;if(e!=null&&(r.width=e),t!=null&&(r.height=t),e=WA(i,0,r),t=WA(i,1,r),n.style.display=``,this._width!==e||t!==this._height){for(var a in n.style.width=e+`px`,n.style.height=t+`px`,this._layers)this._layers.hasOwnProperty(a)&&this._layers[a].resize(e,t);this.refresh(!0)}this._width=e,this._height=t}else{if(e==null||t==null)return;this._width=e,this._height=t,this.getLayer(aB).resize(e,t)}return this},e.prototype.clearLayer=function(e){var t=this._layers[e];t&&t.clear()},e.prototype.dispose=function(){this.root.innerHTML=``,this.root=this.storage=this._domRoot=this._layers=null},e.prototype.getRenderedCanvas=function(e){if(e||={},this._singleCanvas&&!this._compositeManually)return this._layers[aB].dom;var t=new rB(`image`,this,e.pixelRatio||this.dpr);t.initContext(),t.clear(!1,e.backgroundColor||this._backgroundColor);var n=t.ctx;if(e.pixelRatio<=this.dpr){this.refresh();var r=t.dom.width,i=t.dom.height;this.eachLayer(function(e){e.__builtin__?n.drawImage(e.dom,0,0,r,i):e.renderToCanvas&&(n.save(),e.renderToCanvas(n),n.restore())})}else for(var a={inHover:!1,viewWidth:this._width,viewHeight:this._height},o=this.storage.getDisplayList(!0),s=0,c=o.length;s<c;s++){var l=o[s];yj(n,l,a,s===c-1)}return t.dom},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e}();function dB(e){e.registerPainter(`canvas`,uB)}var fB=Object.values({indigo:{300:`#A5B4FC`,400:`#818CF8`,500:`#6366F1`,600:`#4F46E5`,700:`#4338CA`,800:`#3730A3`,900:`#312E81`,950:`#1A1B2C`},violet:{300:`#C4B5FD`,400:`#A78BFA`,500:`#8B5CF6`,600:`#7C3AED`,700:`#6D28D9`,800:`#5B21B6`,900:`#4C1D95`,950:`#2E1065`},purple:{300:`#D8B4FE`,400:`#C084FC`,500:`#A855F7`,600:`#9333EA`,700:`#7E22CE`,800:`#6B21A8`,900:`#581C87`,950:`#3B0764`},fuchsia:{300:`#F9A8D4`,400:`#F472B6`,500:`#EC4899`,600:`#DB2777`,700:`#BE185D`,800:`#9D174D`,900:`#831843`,950:`#500724`},pink:{300:`#F9A8D4`,400:`#F472B6`,500:`#EC4899`,600:`#DB2777`,700:`#BE185D`,800:`#9D174D`,900:`#831843`,950:`#500724`},rose:{300:`#FDA4AF`,400:`#FB7185`,500:`#F43F5E`,600:`#E11D48`,700:`#BE123C`,800:`#9F1239`,900:`#881337`,950:`#4C0519`},orange:{300:`#FDBA74`,400:`#FB923C`,500:`#F97316`,600:`#EA580C`,700:`#C2410C`,800:`#9A3412`,900:`#7C2D12`,950:`#431407`},amber:{300:`#FCD34D`,400:`#FBBF24`,500:`#F59E0B`,600:`#D97706`,700:`#B45309`,800:`#92400E`,900:`#78350F`,950:`#451A03`},yellow:{300:`#FDE047`,400:`#FACC15`,500:`#EAB308`,600:`#CA8A04`,700:`#A16207`,800:`#854D0E`,900:`#713F12`,950:`#362F0F`},lime:{300:`#BFE4A5`,400:`#9FE673`,500:`#84CC16`,600:`#65A30D`,700:`#4D7C0F`,800:`#3F6212`,900:`#365314`,950:`#1A2E05`},green:{300:`#86E4A8`,400:`#4ADE80`,500:`#22C55E`,600:`#16A34A`,700:`#15803D`,800:`#145C30`,900:`#14532B`,950:`#052E16`},emerald:{300:`#6EE7B7`,400:`#34D399`,500:`#10B981`,600:`#059669`,700:`#047857`,800:`#065F46`,900:`#064E3B`,950:`#022C22`},teal:{300:`#5EEAD4`,400:`#2DD4BF`,500:`#14B8A6`,600:`#0D9488`,700:`#0F766E`,800:`#115E59`,900:`#134E4A`,950:`#042F2D`},cyan:{300:`#67E8F9`,400:`#22D3EE`,500:`#06B6D4`,600:`#0891B2`,700:`#0E7490`,800:`#155E75`,900:`#164E63`,950:`#083344`},sky:{300:`#7DD5FE`,400:`#38BDF8`,500:`#0EA5E9`,600:`#0284C7`,700:`#0369A1`,800:`#075985`,900:`#0C4A6E`,950:`#082F49`}}).map(e=>Object.values(e)),pB=fB.map(e=>e[2]),mB=Object.values({blue:{300:`#93C5FD`,400:`#60A5FA`,500:`#3B82F6`,600:`#2563EB`,700:`#1D4ED8`,800:`#1E40AF`,900:`#1E3A8A`,950:`#172554`}}.blue),hB=mB[2];function gB(e,t){let{length:n}=e,r=Math.floor(t/n)%2==1?n-2:0;return e[r+(r===0?1:-1)*(t%e.length)]}function _B(e,t,n){rP(t);let r=on(),i;return qr(()=>{let t=e.value;t&&(r.value=UM(t),n(r.value),i=new ResizeObserver(()=>r.value?.resize()),i.observe(t))}),Zr(()=>{i?.disconnect(),r.value?.dispose()}),r}function vB(e,t){return V({get:()=>e.value[t],set:n=>{e.value={...e.value,[t]:n}}})}function yB(e,t,n,r=!0){let i=r?[...e]:e,a=r?t.map(([e,t])=>[e,t]):t;for(let e of[...n].sort((e,t)=>t-e))a=a.filter(([t,n])=>t!==e&&n!==e),i=i.filter((t,n)=>n!==e),a.forEach(t=>{t[0]>e&&--t[0],t[1]>e&&--t[1]});return{nodes:i,edges:a}}function bB(e,t,n,r){let i=0;do{i=0;let a=[];for(let i=0;i<e.length;i+=1){let o=[];for(let e=0;e<t.length;e+=1)t[e][0]===i&&o.push(t[e][1]);o.length===0&&!EB(e[i],n,r)&&a.push(i)}i=a.length;let o=yB(e,t,a);e=o.nodes,t=o.edges}while(i);return{nodes:e,edges:t}}var xB={Rendered:`rendered`,Bundled:`bundled`,Gzipped:`gzipped`};function SB(e){return`${e[0].toUpperCase()+e.slice(1)} size`}function CB(e){let t=[];return e.chunks.every(e=>e.minifiedLength!==-1)&&t.push(xB.Bundled),t.push(xB.Rendered),e.chunks.every(e=>e.compressedLength!==-1)&&t.push(xB.Gzipped),t}function wB(e,t,n){let r=t.chunks.find(t=>t.fileName===e);if(r)switch(n){case xB.Rendered:return r.modules.reduce((e,t)=>e+t.renderedLength,0);case xB.Bundled:return r.minifiedLength;case xB.Gzipped:return r.compressedLength;default:throw Error(`Unexpected metric value: ${n}`)}}function TB(e){return e<1024?`${Math.ceil(e)} B`:e<1048576?`${(e/1024).toFixed(2)} KB`:`${(e/1024/1024).toFixed(2)} MB`}function EB(e,t,n){let r=typeof e==`string`?t.moduleFileNames.indexOf(e):e;if(r!==-1){for(let e of t.chunks)for(let i of e.modules)if(i.fileNameIndex===r){if(n===xB.Rendered)return i.renderedLength;let r=wB(e.fileName,t,xB.Rendered),a=i.renderedLength/r;if(n===xB.Bundled)return e.minifiedLength*a;if(n===xB.Gzipped)return e.compressedLength*a}}}function DB(e,t){let n=typeof e==`string`?t.moduleFileNames.indexOf(e):e;for(let e of t.chunks)for(let t of e.modules)if(t.fileNameIndex===n)return t.virtual??!1;return!1}function OB(e,t,n){let r=[[t]];for(;r.length;){let t=r.shift(),i=t[t.length-1];if(i===n)return t;for(let n of e)n[0]===i&&!t.includes(n[1])&&r.push([...t,n[1]])}}function kB(e,t,n=0){for(let r of e)kB(r.children,t,n+1),t(r,n)}var AB=I({inheritAttrs:!1,__name:`TreeMapView`,props:fi({stats:{}},{options:{required:!0},optionsModifiers:{}}),emits:fi([`updateView`],[`update:options`]),setup(e,{emit:t}){let n=e,r=t,i=Mi(e,`options`),a=Kd(),o=N(),s=N(!1),c=N({x:0,y:0});function l(){let e=o.value;if(!e)return;let t=new Set;e.moduleIndex&&t.add(e.moduleIndex);function n(e){e.children.forEach(e=>n(e)),e.moduleIndex&&t.add(e.moduleIndex)}n(e),i.value={...i.value,hiddenModules:[...i.value.hiddenModules,...Array.from(t)]}}function u(){let e=o.value;if(!e)return;let t=e.moduleIndex;if(t==null)return;let i=OB(n.stats.importGraph.edges,0,t);if(!i)return;let a=n.stats.moduleFileNames.map((e,t)=>t).filter(e=>!i.includes(e));r(`updateView`,`graph`,{hiddenModules:a})}let d=Nr(`main`),f=_B(d,[RI,vI,PL,tB,dB,az],e=>{e.on(`contextmenu`,e=>{e.event.event.preventDefault();let t=e.event.event;c.value={x:t.clientX,y:t.clientY},s.value=!0,o.value=e.data});let t={show:!0,textBorderColor:`black`,textBorderWidth:0,height:30};function r(){return{upperLabel:{...t,color:`white`},itemStyle:{textColor:`black`,borderWidth:8,gapWidth:4}}}e.setOption({color:pB,tooltip:{formatter(e){let{value:t}=e,{treePathInfo:r}=e,a=[];for(let e=1;e<r.length;e+=1)a.push(r[e].name);let o=[];o.push(`<div class="tooltip-title">${pm(a.length===1?a:a.slice(1).join(`/`))}</div>`,`${SB(i.value.metric)}: ${BT((t/1024).toFixed(2))} KB`);let s=a.slice(1).join(`/`),c=n.stats.moduleFileNames.findIndex(e=>e===s);c>=0&&o.push(`<div>Module index: ${c}</div>`);let l=(c>=0?n.stats.importGraph.edges.filter(([e,t])=>t===c):[]).map(e=>n.stats.moduleFileNames[e[0]]);return l.length&&(o.push(`<div class="mt-2">Imported by:</div>`,`<ul>`),l.length>8?(o.push(...l.slice(0,7).map(e=>`<li>${e}</li>`)),o.push(`and ${l.length-8} more`)):o.push(...l.map(e=>`<li>${e}</li>`)),o.push(`</ul>`)),o.join(``)}},series:[{name:`Chunks`,type:`treemap`,label:{show:!0,formatter:`{b}`},upperLabel:t,levels:[{itemStyle:{gapWidth:8}},...Array.from({length:30}).map(r)],data:p.value}]})});or(()=>{f.value?.setOption({series:[{itemStyle:{borderColor:a.value?`#111827`:`#ffffff`}}]})});let p=V(()=>{let e=[];for(let t=0;t<n.stats.chunks.length;t+=1){let r=n.stats.chunks[t],a=fB[t%fB.length];if(i.value.hiddenChunks.includes(r.fileName))continue;let o={value:0,name:r.fileName,path:r.fileName,children:[],upperLabel:{backgroundColor:a[0]},itemStyle:{color:a[0],borderColor:a[0]}};e.push(o);for(let e of r.modules){let t=e.fileNameIndex;if(i.value.hiddenModules.includes(t))continue;let r=n.stats.moduleFileNames[e.fileNameIndex].split(`/`),s=o;for(let o=0;o<r.length;o+=1){let c=s.children.find(e=>e.name===r[o]);if(c)s=c;else{let c={name:r[o],path:r[o],value:EB(e.fileNameIndex,n.stats,i.value.metric)??0,children:[],moduleIndex:t,upperLabel:{backgroundColor:ws(r[0])?gB(a,o+1):gB(mB,o)},itemStyle:{color:ws(r[0])?gB(a,o+1):gB(mB,o),borderColor:ws(r[0])?gB(a,o+1):gB(mB,o)}};s.children.push(c),s=c}}}}return kB(e,e=>{e.children.length&&(e.value=e.children.reduce((e,t)=>e+t.value,0))}),i.value.compact&&kB(e,e=>{e.children.length===1&&(e.path=`${e.path}/${e.children[0].path}`,e.name=`${e.name}/${e.children[0].name}`,e.children=e.children[0].children)}),e});return cr(p,()=>{f.value?.setOption({series:[{data:p.value}]})}),qr(()=>{zn(()=>window.dispatchEvent(new Event(`resize`)))}),(e,t)=>(L(),Pa(wa,null,[z(`div`,{ref_key:`main`,ref:d,class:M(e.$attrs.class)},null,2),B(P(Zd),{modelValue:s.value,"onUpdate:modelValue":t[0]||=e=>s.value=e,x:c.value.x,y:c.value.y,items:[{label:`Hide`,onClick:l},{label:`Show import path`,onClick:u}]},null,8,[`modelValue`,`x`,`y`,`items`])],64))}}),jB=I({__name:`MetricOption`,props:fi({stats:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let t=e,n=Mi(e,`modelValue`),r=[xB.Rendered,xB.Bundled,xB.Gzipped],i=CB(t.stats).sort((e,t)=>r.indexOf(e)-r.indexOf(t));return(e,t)=>(L(),R(P(lf),{modelValue:n.value,"onUpdate:modelValue":t[0]||=e=>n.value=e,title:`Size metric`,options:P(i)},{description:F(()=>[...t[1]||=[Ha(` Choose which size is displayed. `,-1),z(`p`,{class:`mt-2`},[z(`b`,null,`Rendered`),Ha(`: code after transforms and tree-shaking. This is the size of the processed code. `)],-1),z(`p`,{class:`mt-2`},[z(`b`,null,`Bundled`),Ha(`: rendered code after bundling. Each module's size is accurately estimated from the percentage of the chunk it occupies. This is the size of an actual bundle file. `)],-1),z(`p`,{class:`mt-2`},[z(`b`,null,`Gzipped`),Ha(`: bundled code after gzip compression. This value is calculated using Node.js's default gzip settings, so the real network transfer size may differ slightly. This is the size of the data transferred over the network. `)],-1)]]),_:1},8,[`modelValue`,`options`]))}});function MB(e,t,n=0,r,i=`pre`){for(let a of e)i===`pre`&&t(a,n),a.children&&(r?.(a)||MB(a.children,t,n+1,r,i)),i===`post`&&t(a,n)}function NB(e,t){e.sort(t);for(let n of e)n.children&&NB(n.children,t)}var PB=`group flex h-6 items-center gap-1 overflow-hidden pr-2 cursor-pointer rounded hover:bg-gray-100 dark:hover:bg-gray-800`,FB=`flex-none text-[14px] text-gray-400 dark:text-gray-500`,IB=`flex-none ml-1 text-xs tabular-nums text-gray-400 dark:text-gray-500`,LB=I({props:{data:{type:Object,required:!0}},emits:[`toggle`,`toggle-visibility`,`hover`,`context-menu`],setup(e,{emit:t}){return()=>{let n=[];return MB(e.data,(e,r)=>{n.push(vo(`li`,{role:`treeitem`,ariaLevel:r+1,onClick(){t(`toggle`,e)},onContextmenu(n){n.preventDefault(),t(`context-menu`,{node:e,event:n})},class:PB,style:{paddingLeft:`${r*10+6}px`}},[vo(`div`,{class:e.visible?`i-mdi:eye-outline flex-none text-[14px] opacity-0 group-hover:opacity-60`:`i-mdi:eye-off-outline flex-none text-[14px] text-gray-400 dark:text-gray-500`,onClick(n){n.stopPropagation(),t(`toggle-visibility`,e)}}),e.children?vo(`div`,{class:`${e.collapsed?`i-mdi:chevron-right`:`i-mdi:chevron-down`} ${FB}`}):vo(`div`,{class:`flex-none w-3.5 h-3.5`}),e.icons?.map(e=>vo(`div`,{class:`inline-block flex-none text-[14px] mr-0.5 ${e}`})),vo(`div`,{class:`flex-1 min-w-0 truncate`,title:e.title},e.title),e.query&&vo(`div`,{class:`flex-none text-[13px] text-gray-400 i-mdi:help`,title:e.query}),typeof e.size==`number`&&vo(`div`,{class:IB},TB(e.size))]))},0,e=>!!e.collapsed,`pre`),vo(`ul`,{role:`tree`,class:`text-[13px] text-gray-700 dark:text-gray-300`},n)}}});function RB(e){let[t,n]=e.substring(e.lastIndexOf(`/`)).split(`?`);return n?[t,n]:[t]}var zB={js:`i-vscode-icons:file-type-js-official`,mjs:`i-vscode-icons:file-type-js-official`,cjs:`i-vscode-icons:file-type-js-official`,ts:`i-vscode-icons:file-type-typescript-official`,mts:`i-vscode-icons:file-type-typescript-official`,cts:`i-vscode-icons:file-type-typescript-official`,vue:`i-vscode-icons:file-type-vue`,jsx:`i-vscode-icons:file-type-reactjs`,tsx:`i-vscode-icons:file-type-reactts`,css:`i-vscode-icons:file-type-css`,scss:`i-vscode-icons:file-type-sass`,sass:`i-vscode-icons:file-type-sass`,less:`i-vscode-icons:file-type-less`,svg:`i-vscode-icons:file-type-svg`,html:`i-vscode-icons:file-type-html`};function BB(e,t){let n=[],{fileName:r}=e;if(!r)return n;if(DB(r,t))return n.push(`i-vscode-icons:file-type-vite`),n;let[i,a]=RB(r),o=zB[i.substring(i.lastIndexOf(`.`)+1)];if(o&&n.push(o),typeof a==`string`&&a?.startsWith(`vue`)){let e=zB[/lang\.([a-z]+)/gm.exec(a)?.[1]??``];e&&n.push(e)}return t.builtInModules?.includes(t.moduleFileNames.indexOf(e.title??``))&&n.push(`i-vscode-icons:file-type-node`),n}function VB(e,t){let n=[];for(let r of e){let e=t.builtInModules?.includes(t.moduleFileNames.indexOf(r))?[r]:r.split(`/`),i=n;for(let n=0;n<e.length;n+=1){let a=i.find(t=>t.title===e[n]);if(a)i=a.children;else{let a={title:e[n],visible:!0};if(n!==e.length-1)a.children=[],a.collapsed=!0,a.icons=[`i-vscode-icons:default-folder`];else{let i=e[n].indexOf(`?`);i!==-1&&(a.query=e[n].substring(i+1)),a.title=a.title.substring(0,i===-1?void 0:i),a.fileName=r,a.icons=BB(a,t)}i.push(a),i=a.children}}}return n}var HB={class:`flex items-center justify-between gap-2 px-2 pb-1.5`},UB={class:`flex items-center gap-1 text-xs text-gray-500 dark:text-gray-400`},WB=I({__name:`ModuleFilter`,props:fi({stats:{},modules:{}},{options:{required:!0},optionsModifiers:{}}),emits:fi([`updateView`],[`update:options`]),setup(e,{emit:t}){let n=e,r=t,i=Mi(e,`options`);function a(e,t){t?i.value={...i.value,hiddenModules:i.value.hiddenModules.filter(t=>!e.includes(t))}:i.value={...i.value,hiddenModules:[...i.value.hiddenModules,...e]}}let o=V(()=>{let e=[];if(n.modules===`bundled`)for(let t of n.stats.chunks)for(let r of t.modules)e.push(n.stats.moduleFileNames[r.fileNameIndex]);else e.push(...n.stats.moduleFileNames);return e});function s(){i.value.hiddenModules.length===0?i.value={...i.value,hiddenModules:o.value.map(e=>n.stats.moduleFileNames.indexOf(e))}:i.value={...i.value,hiddenModules:[]}}let c=n.modules===`all`?n.stats.moduleFileNames.length:n.stats.chunks.reduce((e,t)=>e+t.modules.length,0),l=N(VB(o.value,n.stats));cr(()=>i.value.metric,e=>{MB(l.value,t=>{t.fileName&&(t.size=EB(t.fileName,n.stats,e)??0),t.children&&(t.size=t.children?.reduce((e,t)=>e+(t.size??0),0)??0)},0,void 0,`post`)},{immediate:!0}),cr(()=>i.value.hiddenModules,e=>{MB(l.value,t=>{let r=t.fileName?n.stats.moduleFileNames.indexOf(t.fileName):-1;e.includes(r)?t.visible=!1:r!==-1&&(t.visible=!0)}),MB(l.value,e=>{e.children&&(e.visible=!e.children.every(e=>e.visible===!1))},0,void 0,`post`)},{immediate:!0});let u=N(`size`);cr(u,e=>{e===`size`?NB(l.value,(e,t)=>(t.size??0)-(e.size??0)):e===`name`&&NB(l.value,(e,t)=>e.title.localeCompare(t.title))},{immediate:!0});function d(e){if(e.visible=!e.visible,e.fileName!=null&&a([n.stats.moduleFileNames.indexOf(e.fileName)],e.visible),e.children){let t=[];MB(e.children,r=>{r.visible=e.visible,r.fileName&&t.push(n.stats.moduleFileNames.indexOf(r.fileName))}),a(t,e.visible)}}let f=N(),p=N(!1),m=N({x:0,y:0});function h(e){let{event:t,node:n}=e;m.value.x=t.clientX,m.value.y=t.clientY,f.value=n,p.value=!0}function g(){f.value&&d(f.value)}function _(){let e=f.value;if(!e)return;let{fileName:t}=e;if(t==null)return;let i=n.stats.moduleFileNames.indexOf(t),a=OB(n.stats.importGraph.edges,0,i);if(!a)return;let o=n.stats.moduleFileNames.map((e,t)=>t).filter(e=>!a.includes(e));r(`updateView`,`graph`,{hiddenModules:o})}return(e,t)=>(L(),R(P(pf),{title:`Visible modules (${P(c)-i.value.hiddenModules.length}/${P(c)})`},{default:F(()=>[z(`div`,HB,[B(P(Os),{onClick:s},{default:F(()=>[...t[3]||=[Ha(` Toggle all `,-1)]]),_:1}),z(`label`,UB,[t[5]||=Ha(` Sort `,-1),$n(z(`select`,{"onUpdate:modelValue":t[0]||=e=>u.value=e,class:`cursor-pointer rounded bg-gray-100 px-1 py-0.5 text-xs capitalize transition-colors dark:bg-gray-800 hover:bg-gray-200 focus:outline-none dark:hover:bg-gray-700`},[...t[4]||=[z(`option`,{value:`name`},`Name`,-1),z(`option`,{value:`size`},`Size`,-1)]],512),[[ls,u.value]])])]),B(LB,{data:l.value,onToggle:t[1]||=e=>e.collapsed=!e.collapsed,onToggleVisibility:d,onContextMenu:h},null,8,[`data`]),B(P(Zd),{modelValue:p.value,"onUpdate:modelValue":t[2]||=e=>p.value=e,x:m.value.x,y:m.value.y,items:[{label:`Toggle visibility`,onClick:g},{label:`Show import path`,onClick:_}]},null,8,[`modelValue`,`x`,`y`,`items`])]),_:1},8,[`title`]))}}),GB={class:`flex items-center justify-between gap-2 px-2 pb-1.5`},KB={class:`flex items-center gap-1 text-xs text-gray-500 dark:text-gray-400`},qB=I({__name:`ChunkFilter`,props:fi({stats:{}},{options:{required:!0},optionsModifiers:{}}),emits:[`update:options`],setup(e){let t=e,n=Mi(e,`options`);function r(){n.value.hiddenChunks.length===0?n.value={...n.value,hiddenChunks:t.stats.chunks.map(e=>e.fileName)}:n.value={...n.value,hiddenChunks:[]}}function i(e){return e.modules.reduce((e,t)=>e+t.renderedLength,0)}let a=N(``),o=V(()=>a.value===`size-asc`?t.stats.chunks.toSorted((e,t)=>i(e)-i(t)):a.value===`size-desc`?t.stats.chunks.toSorted((e,t)=>i(t)-i(e)):a.value===`name-asc`?t.stats.chunks.toSorted((e,t)=>e.fileName.localeCompare(t.fileName)):a.value===`name-desc`?t.stats.chunks.toSorted((e,t)=>t.fileName.localeCompare(e.fileName)):t.stats.chunks),s=V(()=>o.value.map(e=>{let n={title:e.fileName,size:i(e),visible:!0,fileName:e.fileName};return n.icons=BB(n,t.stats),n}));return(e,t)=>(L(),Pa(`div`,null,[z(`div`,GB,[B(P(Os),{onClick:r},{default:F(()=>[...t[1]||=[Ha(` Toggle all `,-1)]]),_:1}),z(`label`,KB,[t[3]||=Ha(` Sort `,-1),$n(z(`select`,{"onUpdate:modelValue":t[0]||=e=>a.value=e,class:`cursor-pointer rounded bg-gray-100 px-1 py-0.5 text-xs capitalize transition-colors dark:bg-gray-800 hover:bg-gray-200 focus:outline-none dark:hover:bg-gray-700`},[...t[2]||=[Ua(`<option value="">-</option><option value="name-asc">Name asc</option><option value="name-desc">Name desc</option><option value="size-asc">Size asc</option><option value="size-desc">Size desc</option>`,5)]],512),[[ls,a.value]])])]),B(P(LB),{data:s.value},null,8,[`data`])]))}}),JB=I({__name:`TreeMapViewOptions`,props:fi({stats:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:fi([`updateView`],[`update:modelValue`]),setup(e,{emit:t}){let n=t,r=Mi(e,`modelValue`),i=V({get:()=>r.value.compact,set:e=>{r.value={...r.value,compact:e}}}),a=vB(r,`metric`);function o(e,t){n(`updateView`,e,t)}return(t,n)=>(L(),Pa(`div`,null,[B(P(jB),{modelValue:P(a),"onUpdate:modelValue":n[0]||=e=>an(a)?a.value=e:null,stats:e.stats},null,8,[`modelValue`,`stats`]),B(P(sf),{title:`Compact`},{description:F(()=>[...n[4]||=[Ha(` Merges groups that contain a single child into one node. A chain like `,-1),z(`b`,null,`src › lib › ui`,-1),Ha(` becomes one `,-1),z(`b`,null,`src/lib/ui`,-1),Ha(` tile instead of three nested ones. `,-1)]]),default:F(()=>[B(P(nd),{modelValue:i.value,"onUpdate:modelValue":n[1]||=e=>i.value=e},null,8,[`modelValue`])]),_:1}),B(P(pf),{title:`Visible chunks (${e.stats.chunks.length-r.value.hiddenChunks.length}/${e.stats.chunks.length})`},{default:F(()=>[B(qB,{options:r.value,"onUpdate:options":n[2]||=e=>r.value=e,stats:e.stats},null,8,[`options`,`stats`])]),_:1},8,[`title`]),B(P(WB),{options:r.value,"onUpdate:options":n[3]||=e=>r.value=e,stats:e.stats,modules:`bundled`,onUpdateView:o},null,8,[`options`,`stats`])]))}});function YB(e){return{metric:CB(e)[0],compact:!0,hiddenModules:[],hiddenChunks:[]}}var XB=I({__name:`TreeMapPage`,props:{stats:{}},setup(e){let t=N(YB(e.stats));return(n,r)=>(L(),R(Sf,null,{aside:F(()=>[B(JB,{modelValue:t.value,"onUpdate:modelValue":r[0]||=e=>t.value=e,stats:e.stats},null,8,[`modelValue`,`stats`])]),main:F(()=>[B(AB,{stats:e.stats,options:t.value,class:`h-full w-full`},null,8,[`stats`,`options`])]),_:1}))}});function ZB(e){let t=+this._x.call(null,e),n=+this._y.call(null,e);return QB(this.cover(t,n),t,n,e)}function QB(e,t,n,r){if(isNaN(t)||isNaN(n))return e;var i,a=e._root,o={data:r},s=e._x0,c=e._y0,l=e._x1,u=e._y1,d,f,p,m,h,g,_,v;if(!a)return e._root=o,e;for(;a.length;)if((h=t>=(d=(s+l)/2))?s=d:l=d,(g=n>=(f=(c+u)/2))?c=f:u=f,i=a,!(a=a[_=g<<1|h]))return i[_]=o,e;if(p=+e._x.call(null,a.data),m=+e._y.call(null,a.data),t===p&&n===m)return o.next=a,i?i[_]=o:e._root=o,e;do i=i?i[_]=[,,,,]:e._root=[,,,,],(h=t>=(d=(s+l)/2))?s=d:l=d,(g=n>=(f=(c+u)/2))?c=f:u=f;while((_=g<<1|h)==(v=(m>=f)<<1|p>=d));return i[v]=a,i[_]=o,e}function $B(e){Array.isArray(e)||(e=Array.from(e));let t=e.length,n=new Float64Array(t),r=new Float64Array(t),i=1/0,a=i,o=-i,s=o;for(let c=0,l,u,d;c<t;++c)isNaN(u=+this._x.call(null,l=e[c]))||isNaN(d=+this._y.call(null,l))?n[c]=NaN:(n[c]=u,r[c]=d,u<i&&(i=u),u>o&&(o=u),d<a&&(a=d),d>s&&(s=d));if(i>o||a>s)return this;this.cover(i,a).cover(o,s);for(let i=0;i<t;++i)QB(this,n[i],r[i],e[i]);return this}function eV(e,t){if(isNaN(e=+e)||isNaN(t=+t))return this;var n=this._x0,r=this._y0,i=this._x1,a=this._y1;if(isNaN(n))i=(n=Math.floor(e))+1,a=(r=Math.floor(t))+1;else{for(var o=i-n||1,s=this._root,c,l;n>e||e>=i||r>t||t>=a;)switch(l=(t<r)<<1|e<n,c=[,,,,],c[l]=s,s=c,o*=2,l){case 0:i=n+o,a=r+o;break;case 1:n=i-o,a=r+o;break;case 2:i=n+o,r=a-o;break;case 3:n=i-o,r=a-o}this._root&&this._root.length&&(this._root=s)}return this._x0=n,this._y0=r,this._x1=i,this._y1=a,this}function tV(){var e=[];return this.visit(function(t){if(!t.length)do e.push(t.data);while(t=t.next)}),e}function nV(e){return arguments.length?this.cover(+e[0][0],+e[0][1]).cover(+e[1][0],+e[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]}function rV(e,t,n,r,i){this.node=e,this.x0=t,this.y0=n,this.x1=r,this.y1=i}function iV(e,t,n){var r,i=this._x0,a=this._y0,o,s,c,l,u=this._x1,d=this._y1,f=[],p=this._root,m,h;for(p&&f.push(new rV(p,i,a,u,d)),n==null?n=1/0:(i=e-n,a=t-n,u=e+n,d=t+n,n*=n);m=f.pop();)if(!(!(p=m.node)||(o=m.x0)>u||(s=m.y0)>d||(c=m.x1)<i||(l=m.y1)<a)){if(p.length){var g=(o+c)/2,_=(s+l)/2;f.push(new rV(p[3],g,_,c,l),new rV(p[2],o,_,g,l),new rV(p[1],g,s,c,_),new rV(p[0],o,s,g,_)),(h=(t>=_)<<1|e>=g)&&(m=f[f.length-1],f[f.length-1]=f[f.length-1-h],f[f.length-1-h]=m)}else{var v=e-+this._x.call(null,p.data),y=t-+this._y.call(null,p.data),b=v*v+y*y;if(b<n){var x=Math.sqrt(n=b);i=e-x,a=t-x,u=e+x,d=t+x,r=p.data}}}return r}function aV(e){if(isNaN(u=+this._x.call(null,e))||isNaN(d=+this._y.call(null,e)))return this;var t,n=this._root,r,i,a,o=this._x0,s=this._y0,c=this._x1,l=this._y1,u,d,f,p,m,h,g,_;if(!n)return this;if(n.length)for(;;){if((m=u>=(f=(o+c)/2))?o=f:c=f,(h=d>=(p=(s+l)/2))?s=p:l=p,t=n,!(n=n[g=h<<1|m]))return this;if(!n.length)break;(t[g+1&3]||t[g+2&3]||t[g+3&3])&&(r=t,_=g)}for(;n.data!==e;)if(i=n,!(n=n.next))return this;return(a=n.next)&&delete n.next,i?(a?i.next=a:delete i.next,this):t?(a?t[g]=a:delete t[g],(n=t[0]||t[1]||t[2]||t[3])&&n===(t[3]||t[2]||t[1]||t[0])&&!n.length&&(r?r[_]=n:this._root=n),this):(this._root=a,this)}function oV(e){for(var t=0,n=e.length;t<n;++t)this.remove(e[t]);return this}function sV(){return this._root}function cV(){var e=0;return this.visit(function(t){if(!t.length)do++e;while(t=t.next)}),e}function lV(e){var t=[],n,r=this._root,i,a,o,s,c;for(r&&t.push(new rV(r,this._x0,this._y0,this._x1,this._y1));n=t.pop();)if(!e(r=n.node,a=n.x0,o=n.y0,s=n.x1,c=n.y1)&&r.length){var l=(a+s)/2,u=(o+c)/2;(i=r[3])&&t.push(new rV(i,l,u,s,c)),(i=r[2])&&t.push(new rV(i,a,u,l,c)),(i=r[1])&&t.push(new rV(i,l,o,s,u)),(i=r[0])&&t.push(new rV(i,a,o,l,u))}return this}function uV(e){var t=[],n=[],r;for(this._root&&t.push(new rV(this._root,this._x0,this._y0,this._x1,this._y1));r=t.pop();){var i=r.node;if(i.length){var a,o=r.x0,s=r.y0,c=r.x1,l=r.y1,u=(o+c)/2,d=(s+l)/2;(a=i[0])&&t.push(new rV(a,o,s,u,d)),(a=i[1])&&t.push(new rV(a,u,s,c,d)),(a=i[2])&&t.push(new rV(a,o,d,u,l)),(a=i[3])&&t.push(new rV(a,u,d,c,l))}n.push(r)}for(;r=n.pop();)e(r.node,r.x0,r.y0,r.x1,r.y1);return this}function dV(e){return e[0]}function fV(e){return arguments.length?(this._x=e,this):this._x}function pV(e){return e[1]}function mV(e){return arguments.length?(this._y=e,this):this._y}function hV(e,t,n){var r=new gV(t??dV,n??pV,NaN,NaN,NaN,NaN);return e==null?r:r.addAll(e)}function gV(e,t,n,r,i,a){this._x=e,this._y=t,this._x0=n,this._y0=r,this._x1=i,this._y1=a,this._root=void 0}function _V(e){for(var t={data:e.data},n=t;e=e.next;)n=n.next={data:e.data};return t}var vV=hV.prototype=gV.prototype;vV.copy=function(){var e=new gV(this._x,this._y,this._x0,this._y0,this._x1,this._y1),t=this._root,n,r;if(!t)return e;if(!t.length)return e._root=_V(t),e;for(n=[{source:t,target:e._root=[,,,,]}];t=n.pop();)for(var i=0;i<4;++i)(r=t.source[i])&&(r.length?n.push({source:r,target:t.target[i]=[,,,,]}):t.target[i]=_V(r));return e},vV.add=ZB,vV.addAll=$B,vV.cover=eV,vV.data=tV,vV.extent=nV,vV.find=iV,vV.remove=aV,vV.removeAll=oV,vV.root=sV,vV.size=cV,vV.visit=lV,vV.visitAfter=uV,vV.x=fV,vV.y=mV;var yV={value:()=>{}};function bV(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+``)||r in n||/[\s.]/.test(r))throw Error(`illegal type: `+r);n[r]=[]}return new xV(n)}function xV(e){this._=e}function SV(e,t){return e.trim().split(/^|\s+/).map(function(e){var n=``,r=e.indexOf(`.`);if(r>=0&&(n=e.slice(r+1),e=e.slice(0,r)),e&&!t.hasOwnProperty(e))throw Error(`unknown type: `+e);return{type:e,name:n}})}xV.prototype=bV.prototype={constructor:xV,on:function(e,t){var n=this._,r=SV(e+``,n),i,a=-1,o=r.length;if(arguments.length<2){for(;++a<o;)if((i=(e=r[a]).type)&&(i=CV(n[i],e.name)))return i}else{if(t!=null&&typeof t!=`function`)throw Error(`invalid callback: `+t);for(;++a<o;)if(i=(e=r[a]).type)n[i]=wV(n[i],e.name,t);else if(t==null)for(i in n)n[i]=wV(n[i],e.name,null);return this}},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new xV(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var n=Array(i),r=0,i,a;r<i;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw Error(`unknown type: `+e);for(a=this._[e],r=0,i=a.length;r<i;++r)a[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw Error(`unknown type: `+e);for(var r=this._[e],i=0,a=r.length;i<a;++i)r[i].value.apply(t,n)}};function CV(e,t){for(var n=0,r=e.length,i;n<r;++n)if((i=e[n]).name===t)return i.value}function wV(e,t,n){for(var r=0,i=e.length;r<i;++r)if(e[r].name===t){e[r]=yV,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var TV=0,EV=0,DV=0,OV=1e3,kV,AV,jV=0,MV=0,NV=0,PV=typeof performance==`object`&&performance.now?performance:Date,FV=typeof window==`object`&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function IV(){return MV||=(FV(LV),PV.now()+NV)}function LV(){MV=0}function RV(){this._call=this._time=this._next=null}RV.prototype=zV.prototype={constructor:RV,restart:function(e,t,n){if(typeof e!=`function`)throw TypeError(`callback is not a function`);n=(n==null?IV():+n)+(t==null?0:+t),!this._next&&AV!==this&&(AV?AV._next=this:kV=this,AV=this),this._call=e,this._time=n,WV()},stop:function(){this._call&&(this._call=null,this._time=1/0,WV())}};function zV(e,t,n){var r=new RV;return r.restart(e,t,n),r}function BV(){IV(),++TV;for(var e=kV,t;e;)(t=MV-e._time)>=0&&e._call.call(void 0,t),e=e._next;--TV}function VV(){MV=(jV=PV.now())+NV,TV=EV=0;try{BV()}finally{TV=0,UV(),MV=0}}function HV(){var e=PV.now(),t=e-jV;t>OV&&(NV-=t,jV=e)}function UV(){for(var e,t=kV,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:kV=n);AV=e,WV(r)}function WV(e){TV||(EV&&=clearTimeout(EV),e-MV>24?(e<1/0&&(EV=setTimeout(VV,Math.ceil(e-PV.now()-NV)+1)),DV&&=clearInterval(DV)):(DV||=(jV=PV.now(),setInterval(HV,OV)),TV=1,FV(VV)))}function GV(e){return function(){return e}}function KV(e){return(e()-.5)*1e-6}function qV(e){return e.x+e.vx}function JV(e){return e.y+e.vy}function YV(e){var t,n,r,i=1,a=1;typeof e!=`function`&&(e=GV(e==null?1:+e));function o(){for(var e,o=t.length,c,l,u,d,f,p,m=0;m<a;++m)for(c=hV(t,qV,JV).visitAfter(s),e=0;e<o;++e)l=t[e],f=n[l.index],p=f*f,u=l.x+l.vx,d=l.y+l.vy,c.visit(h);function h(e,t,n,a,o){var s=e.data,c=e.r,m=f+c;if(s){if(s.index>l.index){var h=u-s.x-s.vx,g=d-s.y-s.vy,_=h*h+g*g;_<m*m&&(h===0&&(h=KV(r),_+=h*h),g===0&&(g=KV(r),_+=g*g),_=(m-(_=Math.sqrt(_)))/_*i,l.vx+=(h*=_)*(m=(c*=c)/(p+c)),l.vy+=(g*=_)*m,s.vx-=h*(m=1-m),s.vy-=g*m)}}else return t>u+m||a<u-m||n>d+m||o<d-m}}function s(e){if(e.data)return e.r=n[e.data.index];for(var t=e.r=0;t<4;++t)e[t]&&e[t].r>e.r&&(e.r=e[t].r)}function c(){if(t){var r,i=t.length,a;for(n=Array(i),r=0;r<i;++r)a=t[r],n[a.index]=+e(a,r,t)}}return o.initialize=function(e,n){t=e,r=n,c()},o.iterations=function(e){return arguments.length?(a=+e,o):a},o.strength=function(e){return arguments.length?(i=+e,o):i},o.radius=function(t){return arguments.length?(e=typeof t==`function`?t:GV(+t),c(),o):e},o}function XV(e){return e.index}function ZV(e,t){var n=e.get(t);if(!n)throw Error(`node not found: `+t);return n}function QV(e){var t=XV,n=d,r,i=GV(30),a,o,s,c,l,u=1;e??=[];function d(e){return 1/Math.min(s[e.source.index],s[e.target.index])}function f(t){for(var n=0,i=e.length;n<u;++n)for(var o=0,s,d,f,p,m,h,g;o<i;++o)s=e[o],d=s.source,f=s.target,p=f.x+f.vx-d.x-d.vx||KV(l),m=f.y+f.vy-d.y-d.vy||KV(l),h=Math.sqrt(p*p+m*m),h=(h-a[o])/h*t*r[o],p*=h,m*=h,f.vx-=p*(g=c[o]),f.vy-=m*g,d.vx+=p*(g=1-g),d.vy+=m*g}function p(){if(o){var n,i=o.length,l=e.length,u=new Map(o.map((e,n)=>[t(e,n,o),e])),d;for(n=0,s=Array(i);n<l;++n)d=e[n],d.index=n,typeof d.source!=`object`&&(d.source=ZV(u,d.source)),typeof d.target!=`object`&&(d.target=ZV(u,d.target)),s[d.source.index]=(s[d.source.index]||0)+1,s[d.target.index]=(s[d.target.index]||0)+1;for(n=0,c=Array(l);n<l;++n)d=e[n],c[n]=s[d.source.index]/(s[d.source.index]+s[d.target.index]);r=Array(l),m(),a=Array(l),h()}}function m(){if(o)for(var t=0,i=e.length;t<i;++t)r[t]=+n(e[t],t,e)}function h(){if(o)for(var t=0,n=e.length;t<n;++t)a[t]=+i(e[t],t,e)}return f.initialize=function(e,t){o=e,l=t,p()},f.links=function(t){return arguments.length?(e=t,p(),f):e},f.id=function(e){return arguments.length?(t=e,f):t},f.iterations=function(e){return arguments.length?(u=+e,f):u},f.strength=function(e){return arguments.length?(n=typeof e==`function`?e:GV(+e),m(),f):n},f.distance=function(e){return arguments.length?(i=typeof e==`function`?e:GV(+e),h(),f):i},f}var $V=1664525,eH=1013904223,tH=4294967296;function nH(){let e=1;return()=>(e=($V*e+eH)%tH)/tH}function rH(e){return e.x}function iH(e){return e.y}var aH=10,oH=Math.PI*(3-Math.sqrt(5));function sH(e){var t,n=1,r=.001,i=1-r**(1/300),a=0,o=.6,s=new Map,c=zV(d),l=bV(`tick`,`end`),u=nH();e??=[];function d(){f(),l.call(`tick`,t),n<r&&(c.stop(),l.call(`end`,t))}function f(r){var c,l=e.length,u;r===void 0&&(r=1);for(var d=0;d<r;++d)for(n+=(a-n)*i,s.forEach(function(e){e(n)}),c=0;c<l;++c)u=e[c],u.fx==null?u.x+=u.vx*=o:(u.x=u.fx,u.vx=0),u.fy==null?u.y+=u.vy*=o:(u.y=u.fy,u.vy=0);return t}function p(){for(var t=0,n=e.length,r;t<n;++t){if(r=e[t],r.index=t,r.fx!=null&&(r.x=r.fx),r.fy!=null&&(r.y=r.fy),isNaN(r.x)||isNaN(r.y)){var i=aH*Math.sqrt(.5+t),a=t*oH;r.x=i*Math.cos(a),r.y=i*Math.sin(a)}(isNaN(r.vx)||isNaN(r.vy))&&(r.vx=r.vy=0)}}function m(t){return t.initialize&&t.initialize(e,u),t}return p(),t={tick:f,restart:function(){return c.restart(d),t},stop:function(){return c.stop(),t},nodes:function(n){return arguments.length?(e=n,p(),s.forEach(m),t):e},alpha:function(e){return arguments.length?(n=+e,t):n},alphaMin:function(e){return arguments.length?(r=+e,t):r},alphaDecay:function(e){return arguments.length?(i=+e,t):+i},alphaTarget:function(e){return arguments.length?(a=+e,t):a},velocityDecay:function(e){return arguments.length?(o=1-e,t):1-o},randomSource:function(e){return arguments.length?(u=e,s.forEach(m),t):u},force:function(e,n){return arguments.length>1?(n==null?s.delete(e):s.set(e,m(n)),t):s.get(e)},find:function(t,n,r){var i=0,a=e.length,o,s,c,l,u;for(r==null?r=1/0:r*=r,i=0;i<a;++i)l=e[i],o=t-l.x,s=n-l.y,c=o*o+s*s,c<r&&(u=l,r=c);return u},on:function(e,n){return arguments.length>1?(l.on(e,n),t):l.on(e)}}}function cH(){var e,t,n,r,i=GV(-30),a,o=1,s=1/0,c=.81;function l(n){var i,a=e.length,o=hV(e,rH,iH).visitAfter(d);for(r=n,i=0;i<a;++i)t=e[i],o.visit(f)}function u(){if(e){var t,n=e.length,r;for(a=Array(n),t=0;t<n;++t)r=e[t],a[r.index]=+i(r,t,e)}}function d(e){var t=0,n,r,i=0,o,s,c;if(e.length){for(o=s=c=0;c<4;++c)(n=e[c])&&(r=Math.abs(n.value))&&(t+=n.value,i+=r,o+=r*n.x,s+=r*n.y);e.x=o/i,e.y=s/i}else{n=e,n.x=n.data.x,n.y=n.data.y;do t+=a[n.data.index];while(n=n.next)}e.value=t}function f(e,i,l,u){if(!e.value)return!0;var d=e.x-t.x,f=e.y-t.y,p=u-i,m=d*d+f*f;if(p*p/c<m)return m<s&&(d===0&&(d=KV(n),m+=d*d),f===0&&(f=KV(n),m+=f*f),m<o&&(m=Math.sqrt(o*m)),t.vx+=d*e.value*r/m,t.vy+=f*e.value*r/m),!0;if(!(e.length||m>=s)){(e.data!==t||e.next)&&(d===0&&(d=KV(n),m+=d*d),f===0&&(f=KV(n),m+=f*f),m<o&&(m=Math.sqrt(o*m)));do e.data!==t&&(p=a[e.data.index]*r/m,t.vx+=d*p,t.vy+=f*p);while(e=e.next)}}return l.initialize=function(t,r){e=t,n=r,u()},l.strength=function(e){return arguments.length?(i=typeof e==`function`?e:GV(+e),u(),l):i},l.distanceMin=function(e){return arguments.length?(o=e*e,l):Math.sqrt(o)},l.distanceMax=function(e){return arguments.length?(s=e*e,l):Math.sqrt(s)},l.theta=function(e){return arguments.length?(c=e*e,l):Math.sqrt(c)},l}function lH(e){var t=GV(.1),n,r,i;typeof e!=`function`&&(e=GV(e==null?0:+e));function a(e){for(var t=0,a=n.length,o;t<a;++t)o=n[t],o.vx+=(i[t]-o.x)*r[t]*e}function o(){if(n){var a,o=n.length;for(r=Array(o),i=Array(o),a=0;a<o;++a)r[a]=isNaN(i[a]=+e(n[a],a,n))?0:+t(n[a],a,n)}}return a.initialize=function(e){n=e,o()},a.strength=function(e){return arguments.length?(t=typeof e==`function`?e:GV(+e),o(),a):t},a.x=function(t){return arguments.length?(e=typeof t==`function`?t:GV(+t),o(),a):e},a}function uH(e){var t=GV(.1),n,r,i;typeof e!=`function`&&(e=GV(e==null?0:+e));function a(e){for(var t=0,a=n.length,o;t<a;++t)o=n[t],o.vy+=(i[t]-o.y)*r[t]*e}function o(){if(n){var a,o=n.length;for(r=Array(o),i=Array(o),a=0;a<o;++a)r[a]=isNaN(i[a]=+e(n[a],a,n))?0:+t(n[a],a,n)}}return a.initialize=function(e){n=e,o()},a.strength=function(e){return arguments.length?(t=typeof e==`function`?e:GV(+e),o(),a):t},a.y=function(t){return arguments.length?(e=typeof t==`function`?t:GV(+t),o(),a):e},a}var dH=14,fH=Math.PI*(3-Math.sqrt(5)),pH=72e3,mH=60,hH=200,gH=20,_H=.5,vH={dense:{charge:-90,chargeRange:320,chargeTheta:1.4,collidePad:2,collideFrom:.6,linkStrength:()=>_H},spread:{charge:-120,chargeRange:600,chargeTheta:1,collidePad:4,collideFrom:.3,linkStrength:e=>Math.min(1,_H*3/e)}},yH=.05;function bH(e){let t=(e%4294967296+4294967296)%4294967296;return()=>(t=(t*1664525+1013904223)%4294967296,t/4294967296)}function xH(e,t,n=!1){let{moduleFileNames:r,importGraph:i}=e,a=new Map;if(r.length===0)return a;let o=n?vH.dense:vH.spread,s=r.map(()=>[]);for(let[e,t]of i.edges)e!==t&&s[e].push(t);for(let e of s)e.sort((e,t)=>e-t);let c=new Map(r.map((e,t)=>[e,t])),l=new Uint8Array(r.length),u=[];for(let t of e.entryPoints){let e=c.get(t);e!==void 0&&!l[e]&&(l[e]=1,u.push(e))}let d=0,f=0;for(;d<u.length;){let e=u[d];d+=1;for(let t of s[e])l[t]||(l[t]=1,u.push(t));if(d===u.length){for(;f<r.length&&l[f];)f+=1;f<r.length&&(l[f]=1,u.push(f))}}let p=u.map((e,n)=>{let i=n*fH,a=dH*Math.sqrt(n);return{name:r[e],x:Math.cos(i)*a,y:Math.sin(i)*a,radius:t(r[e])/2}}),m=Array.from({length:r.length});u.forEach((e,t)=>{m[e]=p[t]});let h=i.edges.filter(([e,t])=>e!==t).map(([e,t])=>({source:m[e],target:m[t]})),g=new Map;for(let{source:e,target:t}of h)g.set(e,(g.get(e)??0)+1),g.set(t,(g.get(t)??0)+1);let _=Math.round(Math.min(hH,Math.max(mH,pH/r.length))),v=sH(p).force(`link`,QV(h).distance(e=>{let t=e.source,n=e.target;return t.radius+n.radius+gH}).strength(e=>{let t=e.source,n=e.target,r=Math.min(g.get(t)??1,g.get(n)??1);return o.linkStrength(r)})).force(`charge`,cH().strength(o.charge).distanceMax(o.chargeRange).theta(o.chargeTheta)).force(`x`,lH(0).strength(yH)).force(`y`,uH(0).strength(yH)).randomSource(bH(42)).stop();v.alphaDecay(1-v.alphaMin()**(1/_));let y=Math.floor(_*o.collideFrom);for(let e=0;e<_&&v.alpha()>v.alphaMin();e+=1)e===y&&v.force(`collide`,YV(e=>e.radius+o.collidePad)),v.tick();let b=p.reduce((e,t)=>e+t.x,0)/p.length,x=p.reduce((e,t)=>e+t.y,0)/p.length;for(let e of p)a.set(e.name,{x:e.x-b,y:e.y-x});return a}function SH(e,t,n){return Math.min(Math.max(e,t),n)}var CH=12,wH=75,TH=[void 0,`arrow`],EH=6,DH=`#e7000b`,OH=I({__name:`GraphView`,props:fi({stats:{}},{options:{required:!0},optionsModifiers:{}}),emits:[`update:options`],setup(e){let t=e,n=Mi(e,`options`),r=Nr(`main`),i=_B(r,[RI,vI,az,dB],e=>{e.on(`contextmenu`,e=>{e.event.event.preventDefault(),n.value={...n.value,hiddenModules:[...n.value.hiddenModules,e.data.id]}}),e.setOption({color:pB,title:{text:`Dependencies`,top:20,left:0},animationDurationUpdate:1500,animationEasingUpdate:`quinticInOut`,series:[{type:`graph`,layout:`none`,emphasis:{focus:`adjacency`,label:{position:`right`,show:!0}},label:{show:!1,formatter(e){let r=e.data.name;return`${r}\n${TB(EB(r,t.stats,n.value.metric)??0)}`}},roam:!0,lineStyle:{width:.5,opacity:.5,curveness:.3}}]}),e.setOption(u.value)}),a=V(()=>n.value.metric),o=V(e=>{if(e?.length!==n.value.hiddenModules.length)return n.value.hiddenModules;for(let t=0;t<e.length;t+=1)if(e[t]!==n.value.hiddenModules[t])return n.value.hiddenModules;return e}),s=V(()=>n.value.compact),c=Kd();or(()=>{if(i.value){let e=c.value?`#ffffff`:`#111827`;i.value.setOption({title:{textStyle:{color:e}},legend:{textStyle:{color:e}},label:{color:e}})}});let l=V(()=>{let e=CB(t.stats)[0];return xH(t.stats,n=>SH((EB(n,t.stats,e)??0)/1024,CH,wH),!n.value.spreadLayout)}),u=V(()=>{let{edges:e}=t.stats.importGraph,n=t.stats.moduleFileNames;if(s.value){let r=bB(n,e,t.stats,a.value);e=r.edges,n=r.nodes}if(o.value.length){let t=yB(n,e,o.value);e=t.edges,n=t.nodes}let r=new Set;for(let e of n){let t=Ts(e);t&&r.add(t)}let i=Array.from(r),c=[{name:`src`,itemStyle:{color:hB}},...i.map((e,t)=>({name:e,itemStyle:{color:pB[t%pB.length]}}))];return{legend:{data:c,top:50,left:0,icon:`circle`,orient:`vertical`,type:`scroll`,inactiveColor:`#333`},series:[{categories:c,edges:e.map(e=>({source:e[0],target:e[1],symbol:TH,symbolSize:EH})),data:n.map((e,n)=>{let r=t.stats.entryPoints.includes(e),o=EB(e,t.stats,a.value)??0,s=i.findIndex(t=>t===Ts(e))+1,u=l.value.get(e),d;return r?d=DH:o===0&&(d=`#ffffff`),{category:s,id:n,name:e,x:u.x,y:u.y,symbolSize:SH(o/1024,CH,wH),itemStyle:{borderColor:o===0?c[s].itemStyle.color:void 0,color:d},emphasis:{label:{show:!0}}}})}]}});return cr(u,e=>{i.value?.setOption(e)}),(e,t)=>(L(),Pa(`div`,{ref_key:`main`,ref:r},null,512))}}),kH=I({__name:`GraphViewOptions`,props:fi({stats:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:[`update:modelValue`],setup(e){let t=Mi(e,`modelValue`),n=vB(t,`compact`),r=vB(t,`metric`),i=vB(t,`spreadLayout`);return(a,o)=>(L(),Pa(`div`,null,[B(P(jB),{modelValue:P(r),"onUpdate:modelValue":o[0]||=e=>an(r)?r.value=e:null,stats:e.stats},null,8,[`modelValue`,`stats`]),B(P(sf),{title:`Compact`},{description:F(()=>[...o[4]||=[z(`p`,null,` Hides modules that contribute no size to the selected metric and import nothing themselves. `,-1),z(`p`,{class:`mt-2`},` This check repeats, so modules emptied by these removals are hidden as well. `,-1)]]),default:F(()=>[B(P(nd),{modelValue:P(n),"onUpdate:modelValue":o[1]||=e=>an(n)?n.value=e:null},null,8,[`modelValue`])]),_:1}),B(P(sf),{title:`Spread layout`},{description:F(()=>[...o[5]||=[z(`p`,null,` Reduces spring-domination effect in clusters. Makes modules spread out more in tight clusters and a bit easier to read. `,-1),z(`p`,{class:`mt-2`},` This might obscure direct connections between modules by overlapping edges with nodes and spreading out related nodes. `,-1)]]),default:F(()=>[B(P(nd),{modelValue:P(i),"onUpdate:modelValue":o[2]||=e=>an(i)?i.value=e:null},null,8,[`modelValue`])]),_:1}),B(P(WB),{options:t.value,"onUpdate:options":o[3]||=e=>t.value=e,stats:e.stats,modules:`all`},null,8,[`options`,`stats`])]))}});function AH(e){let t=e.moduleFileNames.reduce((t,n,r)=>((ws(n)||DB(n,e))&&t.push(r),t),[]);return{metric:CB(e)[0],compact:!1,spreadLayout:!1,hiddenModules:t}}var jH=I({__name:`GraphPage`,props:{stats:{}},setup(e){let t=N(AH(e.stats));return(n,r)=>(L(),R(Sf,null,{aside:F(()=>[B(kH,{modelValue:t.value,"onUpdate:modelValue":r[0]||=e=>t.value=e,stats:e.stats},null,8,[`modelValue`,`stats`])]),main:F(()=>[B(OH,{stats:e.stats,options:t.value,class:`h-full w-full`},null,8,[`stats`,`options`])]),_:1}))}}),MH={class:`h-screen w-screen flex flex-col bg-white text-gray-900 dark:bg-gray-900 dark:text-gray-100`},NH={class:`h-10 flex flex-none items-center gap-3 border-b border-gray-200 px-2 dark:border-gray-800`},PH={class:`ml-auto flex items-center gap-1.5`},FH={class:`flex gap-2`},IH=[`value`];xs(I({__name:`App`,setup(e){let t=on(),n=[{key:`treemap`,label:`Treemap`,icon:`i-mdi:chart-tree`},{key:`graph`,label:`Graph`,icon:`i-mdi:graph`}],r=N(n[0].key),i=N(!1),a=N(),o=N([]);t.value=JSON.parse(window.BUNDLE_STATS??``);function s(){if(!a.value)return;let e=encodeURIComponent(a.value);fetch(`/get?name=${e}`).then(e=>e.json()).then(n=>{t.value=n,i.value=!1,window.location.hash=e}).catch(console.error)}return(e,c)=>(L(),Pa(wa,null,[z(`div`,MH,[z(`header`,NH,[c[3]||=z(`div`,{class:`flex items-center gap-1.5 pl-1 text-[13px] font-semibold`},[z(`span`,{class:`i-vscode-icons:file-type-vite`}),Ha(` Bundle Explorer `)],-1),B(P(ef),{modelValue:r.value,"onUpdate:modelValue":c[0]||=e=>r.value=e,options:n},null,8,[`modelValue`]),z(`div`,PH,[t.value?(L(),R(P(bf),{key:0,stats:t.value},null,8,[`stats`])):Wa(``,!0),B(P(hf))])]),t.value==null?Wa(``,!0):(L(),Pa(wa,{key:0},[r.value===`treemap`?(L(),R(P(XB),{key:0,stats:t.value},null,8,[`stats`])):Wa(``,!0),r.value===`graph`?(L(),R(P(jH),{key:1,stats:t.value},null,8,[`stats`])):Wa(``,!0)],64))]),B(P(id),{open:i.value,"onUpdate:open":c[2]||=e=>i.value=e,title:`Select a fixture`},{default:F(()=>[z(`div`,FH,[$n(z(`select`,{"onUpdate:modelValue":c[1]||=e=>a.value=e,class:`min-w-0 flex-1 cursor-pointer border border-gray-300 rounded bg-white px-2 py-1 text-[13px] outline-none dark:border-gray-700 dark:bg-gray-800`},[(L(!0),Pa(wa,null,ri(o.value,e=>(L(),Pa(`option`,{key:e,value:e},we(e),9,IH))),128))],512),[[ls,a.value]]),B(P(Os),{disabled:!a.value,onClick:s},{default:F(()=>[...c[4]||=[Ha(` Select `,-1)]]),_:1},8,[`disabled`])])]),_:1},8,[`open`])],64))}})).mount(`#app`);
|