shopport 0.1.13 → 0.1.14

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.
@@ -1,310 +0,0 @@
1
- var _I=r=>{throw TypeError(r)};var VS=(r,e,t)=>e.has(r)||_I("Cannot "+t);var J=(r,e,t)=>(VS(r,e,"read from private field"),t?t.call(r):e.get(r)),$e=(r,e,t)=>e.has(r)?_I("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(r):e.set(r,t),Pe=(r,e,t,n)=>(VS(r,e,"write to private field"),n?n.call(r,t):e.set(r,t),t),xt=(r,e,t)=>(VS(r,e,"access private method"),t);var yy=(r,e,t,n)=>({set _(a){Pe(r,e,a,t)},get _(){return J(r,e,n)}});function eq(r,e){for(var t=0;t<e.length;t++){const n=e[t];if(typeof n!="string"&&!Array.isArray(n)){for(const a in n)if(a!=="default"&&!(a in r)){const i=Object.getOwnPropertyDescriptor(n,a);i&&Object.defineProperty(r,a,i.get?i:{enumerable:!0,get:()=>n[a]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const a of document.querySelectorAll('link[rel="modulepreload"]'))n(a);new MutationObserver(a=>{for(const i of a)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function t(a){const i={};return a.integrity&&(i.integrity=a.integrity),a.referrerPolicy&&(i.referrerPolicy=a.referrerPolicy),a.crossOrigin==="use-credentials"?i.credentials="include":a.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function n(a){if(a.ep)return;a.ep=!0;const i=t(a);fetch(a.href,i)}})();function mM(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var GS={exports:{}},gv={};/**
2
- * @license React
3
- * react-jsx-runtime.production.js
4
- *
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- */var SI;function tq(){if(SI)return gv;SI=1;var r=Symbol.for("react.transitional.element"),e=Symbol.for("react.fragment");function t(n,a,i){var o=null;if(i!==void 0&&(o=""+i),a.key!==void 0&&(o=""+a.key),"key"in a){i={};for(var s in a)s!=="key"&&(i[s]=a[s])}else i=a;return a=i.ref,{$$typeof:r,type:n,key:o,ref:a!==void 0?a:null,props:i}}return gv.Fragment=e,gv.jsx=t,gv.jsxs=t,gv}var wI;function rq(){return wI||(wI=1,GS.exports=tq()),GS.exports}var _=rq(),Rg=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(r){return this.listeners.add(r),this.onSubscribe(),()=>{this.listeners.delete(r),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Uu,Ws,gh,pV,nq=(pV=class extends Rg{constructor(){super();$e(this,Uu);$e(this,Ws);$e(this,gh);Pe(this,gh,e=>{if(typeof window<"u"&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}})}onSubscribe(){J(this,Ws)||this.setEventListener(J(this,gh))}onUnsubscribe(){var e;this.hasListeners()||((e=J(this,Ws))==null||e.call(this),Pe(this,Ws,void 0))}setEventListener(e){var t;Pe(this,gh,e),(t=J(this,Ws))==null||t.call(this),Pe(this,Ws,e(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(e){J(this,Uu)!==e&&(Pe(this,Uu,e),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(t=>{t(e)})}isFocused(){var e;return typeof J(this,Uu)=="boolean"?J(this,Uu):((e=globalThis.document)==null?void 0:e.visibilityState)!=="hidden"}},Uu=new WeakMap,Ws=new WeakMap,gh=new WeakMap,pV),yM=new nq,aq={setTimeout:(r,e)=>setTimeout(r,e),clearTimeout:r=>clearTimeout(r),setInterval:(r,e)=>setInterval(r,e),clearInterval:r=>clearInterval(r)},Xs,gM,gV,iq=(gV=class{constructor(){$e(this,Xs,aq);$e(this,gM,!1)}setTimeoutProvider(r){Pe(this,Xs,r)}setTimeout(r,e){return J(this,Xs).setTimeout(r,e)}clearTimeout(r){J(this,Xs).clearTimeout(r)}setInterval(r,e){return J(this,Xs).setInterval(r,e)}clearInterval(r){J(this,Xs).clearInterval(r)}},Xs=new WeakMap,gM=new WeakMap,gV),Pu=new iq;function oq(r){setTimeout(r,0)}var sq=typeof window>"u"||"Deno"in globalThis;function kn(){}function lq(r,e){return typeof r=="function"?r(e):r}function kT(r){return typeof r=="number"&&r>=0&&r!==1/0}function CV(r,e){return Math.max(r+(e||0)-Date.now(),0)}function sl(r,e){return typeof r=="function"?r(e):r}function Da(r,e){return typeof r=="function"?r(e):r}function TI(r,e){const{type:t="all",exact:n,fetchStatus:a,predicate:i,queryKey:o,stale:s}=r;if(o){if(n){if(e.queryHash!==xM(o,e.options))return!1}else if(!Vp(e.queryKey,o))return!1}if(t!=="all"){const l=e.isActive();if(t==="active"&&!l||t==="inactive"&&l)return!1}return!(typeof s=="boolean"&&e.isStale()!==s||a&&a!==e.state.fetchStatus||i&&!i(e))}function CI(r,e){const{exact:t,status:n,predicate:a,mutationKey:i}=r;if(i){if(!e.options.mutationKey)return!1;if(t){if(Bp(e.options.mutationKey)!==Bp(i))return!1}else if(!Vp(e.options.mutationKey,i))return!1}return!(n&&e.state.status!==n||a&&!a(e))}function xM(r,e){return((e==null?void 0:e.queryKeyHashFn)||Bp)(r)}function Bp(r){return JSON.stringify(r,(e,t)=>OT(t)?Object.keys(t).sort().reduce((n,a)=>(n[a]=t[a],n),{}):t)}function Vp(r,e){return r===e?!0:typeof r!=typeof e?!1:r&&e&&typeof r=="object"&&typeof e=="object"?Object.keys(e).every(t=>Vp(r[t],e[t])):!1}var uq=Object.prototype.hasOwnProperty;function AV(r,e,t=0){if(r===e)return r;if(t>500)return e;const n=AI(r)&&AI(e);if(!n&&!(OT(r)&&OT(e)))return e;const i=(n?r:Object.keys(r)).length,o=n?e:Object.keys(e),s=o.length,l=n?new Array(s):{};let u=0;for(let c=0;c<s;c++){const f=n?c:o[c],d=r[f],v=e[f];if(d===v){l[f]=d,(n?c<i:uq.call(r,f))&&u++;continue}if(d===null||v===null||typeof d!="object"||typeof v!="object"){l[f]=v;continue}const g=AV(d,v,t+1);l[f]=g,g===d&&u++}return i===s&&u===i?r:l}function IT(r,e){if(!e||Object.keys(r).length!==Object.keys(e).length)return!1;for(const t in r)if(r[t]!==e[t])return!1;return!0}function AI(r){return Array.isArray(r)&&r.length===Object.keys(r).length}function OT(r){if(!MI(r))return!1;const e=r.constructor;if(e===void 0)return!0;const t=e.prototype;return!(!MI(t)||!t.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(r)!==Object.prototype)}function MI(r){return Object.prototype.toString.call(r)==="[object Object]"}function cq(r){return new Promise(e=>{Pu.setTimeout(e,r)})}function PT(r,e,t){return typeof t.structuralSharing=="function"?t.structuralSharing(r,e):t.structuralSharing!==!1?AV(r,e):e}function fq(r,e,t=0){const n=[...r,e];return t&&n.length>t?n.slice(1):n}function hq(r,e,t=0){const n=[e,...r];return t&&n.length>t?n.slice(0,-1):n}var bM=Symbol();function MV(r,e){return!r.queryFn&&(e!=null&&e.initialPromise)?()=>e.initialPromise:!r.queryFn||r.queryFn===bM?()=>Promise.reject(new Error(`Missing queryFn: '${r.queryHash}'`)):r.queryFn}function DV(r,e){return typeof r=="function"?r(...e):!!r}function dq(r,e,t){let n=!1,a;return Object.defineProperty(r,"signal",{enumerable:!0,get:()=>(a??(a=e()),n||(n=!0,a.aborted?t():a.addEventListener("abort",t,{once:!0})),a)}),r}var Gp=(()=>{let r=()=>sq;return{isServer(){return r()},setIsServer(e){r=e}}})();function jT(){let r,e;const t=new Promise((a,i)=>{r=a,e=i});t.status="pending",t.catch(()=>{});function n(a){Object.assign(t,a),delete t.resolve,delete t.reject}return t.resolve=a=>{n({status:"fulfilled",value:a}),r(a)},t.reject=a=>{n({status:"rejected",reason:a}),e(a)},t}var vq=oq;function pq(){let r=[],e=0,t=s=>{s()},n=s=>{s()},a=vq;const i=s=>{e?r.push(s):a(()=>{t(s)})},o=()=>{const s=r;r=[],s.length&&a(()=>{n(()=>{s.forEach(l=>{t(l)})})})};return{batch:s=>{let l;e++;try{l=s()}finally{e--,e||o()}return l},batchCalls:s=>(...l)=>{i(()=>{s(...l)})},schedule:i,setNotifyFunction:s=>{t=s},setBatchNotifyFunction:s=>{n=s},setScheduler:s=>{a=s}}}var Qr=pq(),mh,qs,yh,mV,gq=(mV=class extends Rg{constructor(){super();$e(this,mh,!0);$e(this,qs);$e(this,yh);Pe(this,yh,e=>{if(typeof window<"u"&&window.addEventListener){const t=()=>e(!0),n=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",n)}}})}onSubscribe(){J(this,qs)||this.setEventListener(J(this,yh))}onUnsubscribe(){var e;this.hasListeners()||((e=J(this,qs))==null||e.call(this),Pe(this,qs,void 0))}setEventListener(e){var t;Pe(this,yh,e),(t=J(this,qs))==null||t.call(this),Pe(this,qs,e(this.setOnline.bind(this)))}setOnline(e){J(this,mh)!==e&&(Pe(this,mh,e),this.listeners.forEach(n=>{n(e)}))}isOnline(){return J(this,mh)}},mh=new WeakMap,qs=new WeakMap,yh=new WeakMap,mV),dx=new gq;function mq(r){return Math.min(1e3*2**r,3e4)}function NV(r){return(r??"online")==="online"?dx.isOnline():!0}var zT=class extends Error{constructor(r){super("CancelledError"),this.revert=r==null?void 0:r.revert,this.silent=r==null?void 0:r.silent}};function LV(r){let e=!1,t=0,n;const a=jT(),i=()=>a.status!=="pending",o=y=>{var x;if(!i()){const b=new zT(y);d(b),(x=r.onCancel)==null||x.call(r,b)}},s=()=>{e=!0},l=()=>{e=!1},u=()=>yM.isFocused()&&(r.networkMode==="always"||dx.isOnline())&&r.canRun(),c=()=>NV(r.networkMode)&&r.canRun(),f=y=>{i()||(n==null||n(),a.resolve(y))},d=y=>{i()||(n==null||n(),a.reject(y))},v=()=>new Promise(y=>{var x;n=b=>{(i()||u())&&y(b)},(x=r.onPause)==null||x.call(r)}).then(()=>{var y;n=void 0,i()||(y=r.onContinue)==null||y.call(r)}),g=()=>{if(i())return;let y;const x=t===0?r.initialPromise:void 0;try{y=x??r.fn()}catch(b){y=Promise.reject(b)}Promise.resolve(y).then(f).catch(b=>{var M;if(i())return;const w=r.retry??(Gp.isServer()?0:3),T=r.retryDelay??mq,C=typeof T=="function"?T(t,b):T,D=w===!0||typeof w=="number"&&t<w||typeof w=="function"&&w(t,b);if(e||!D){d(b);return}t++,(M=r.onFail)==null||M.call(r,t,b),cq(C).then(()=>u()?void 0:v()).then(()=>{e?d(b):g()})})};return{promise:a,status:()=>a.status,cancel:o,continue:()=>(n==null||n(),a),cancelRetry:s,continueRetry:l,canStart:c,start:()=>(c()?g():v().then(g),a)}}var Yu,yV,RV=(yV=class{constructor(){$e(this,Yu)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),kT(this.gcTime)&&Pe(this,Yu,Pu.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(r){this.gcTime=Math.max(this.gcTime||0,r??(Gp.isServer()?1/0:300*1e3))}clearGcTimeout(){J(this,Yu)!==void 0&&(Pu.clearTimeout(J(this,Yu)),Pe(this,Yu,void 0))}},Yu=new WeakMap,yV),Wu,xh,Ca,Xu,Gr,Ag,qu,Kn,EV,Mo,xV,yq=(xV=class extends RV{constructor(e){super();$e(this,Kn);$e(this,Wu);$e(this,xh);$e(this,Ca);$e(this,Xu);$e(this,Gr);$e(this,Ag);$e(this,qu);Pe(this,qu,!1),Pe(this,Ag,e.defaultOptions),this.setOptions(e.options),this.observers=[],Pe(this,Xu,e.client),Pe(this,Ca,J(this,Xu).getQueryCache()),this.queryKey=e.queryKey,this.queryHash=e.queryHash,Pe(this,Wu,NI(this.options)),this.state=e.state??J(this,Wu),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return(e=J(this,Gr))==null?void 0:e.promise}setOptions(e){if(this.options={...J(this,Ag),...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const t=NI(this.options);t.data!==void 0&&(this.setState(DI(t.data,t.dataUpdatedAt)),Pe(this,Wu,t))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&J(this,Ca).remove(this)}setData(e,t){const n=PT(this.state.data,e,this.options);return xt(this,Kn,Mo).call(this,{data:n,type:"success",dataUpdatedAt:t==null?void 0:t.updatedAt,manual:t==null?void 0:t.manual}),n}setState(e,t){xt(this,Kn,Mo).call(this,{type:"setState",state:e,setStateOptions:t})}cancel(e){var n,a;const t=(n=J(this,Gr))==null?void 0:n.promise;return(a=J(this,Gr))==null||a.cancel(e),t?t.then(kn).catch(kn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return J(this,Wu)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(e=>Da(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===bM||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>sl(e.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e==="static"?!1:this.state.isInvalidated?!0:!CV(this.state.dataUpdatedAt,e)}onFocus(){var t;const e=this.observers.find(n=>n.shouldFetchOnWindowFocus());e==null||e.refetch({cancelRefetch:!1}),(t=J(this,Gr))==null||t.continue()}onOnline(){var t;const e=this.observers.find(n=>n.shouldFetchOnReconnect());e==null||e.refetch({cancelRefetch:!1}),(t=J(this,Gr))==null||t.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),J(this,Ca).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(J(this,Gr)&&(J(this,qu)||xt(this,Kn,EV).call(this)?J(this,Gr).cancel({revert:!0}):J(this,Gr).cancelRetry()),this.scheduleGc()),J(this,Ca).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||xt(this,Kn,Mo).call(this,{type:"invalidate"})}async fetch(e,t){var l,u,c,f,d,v,g,y,x,b,w,T;if(this.state.fetchStatus!=="idle"&&((l=J(this,Gr))==null?void 0:l.status())!=="rejected"){if(this.state.data!==void 0&&(t!=null&&t.cancelRefetch))this.cancel({silent:!0});else if(J(this,Gr))return J(this,Gr).continueRetry(),J(this,Gr).promise}if(e&&this.setOptions(e),!this.options.queryFn){const C=this.observers.find(D=>D.options.queryFn);C&&this.setOptions(C.options)}const n=new AbortController,a=C=>{Object.defineProperty(C,"signal",{enumerable:!0,get:()=>(Pe(this,qu,!0),n.signal)})},i=()=>{const C=MV(this.options,t),M=(()=>{const N={client:J(this,Xu),queryKey:this.queryKey,meta:this.meta};return a(N),N})();return Pe(this,qu,!1),this.options.persister?this.options.persister(C,M,this):C(M)},s=(()=>{const C={fetchOptions:t,options:this.options,queryKey:this.queryKey,client:J(this,Xu),state:this.state,fetchFn:i};return a(C),C})();(u=this.options.behavior)==null||u.onFetch(s,this),Pe(this,xh,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=s.fetchOptions)==null?void 0:c.meta))&&xt(this,Kn,Mo).call(this,{type:"fetch",meta:(f=s.fetchOptions)==null?void 0:f.meta}),Pe(this,Gr,LV({initialPromise:t==null?void 0:t.initialPromise,fn:s.fetchFn,onCancel:C=>{C instanceof zT&&C.revert&&this.setState({...J(this,xh),fetchStatus:"idle"}),n.abort()},onFail:(C,D)=>{xt(this,Kn,Mo).call(this,{type:"failed",failureCount:C,error:D})},onPause:()=>{xt(this,Kn,Mo).call(this,{type:"pause"})},onContinue:()=>{xt(this,Kn,Mo).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0}));try{const C=await J(this,Gr).start();if(C===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(C),(v=(d=J(this,Ca).config).onSuccess)==null||v.call(d,C,this),(y=(g=J(this,Ca).config).onSettled)==null||y.call(g,C,this.state.error,this),C}catch(C){if(C instanceof zT){if(C.silent)return J(this,Gr).promise;if(C.revert){if(this.state.data===void 0)throw C;return this.state.data}}throw xt(this,Kn,Mo).call(this,{type:"error",error:C}),(b=(x=J(this,Ca).config).onError)==null||b.call(x,C,this),(T=(w=J(this,Ca).config).onSettled)==null||T.call(w,this.state.data,C,this),C}finally{this.scheduleGc()}}},Wu=new WeakMap,xh=new WeakMap,Ca=new WeakMap,Xu=new WeakMap,Gr=new WeakMap,Ag=new WeakMap,qu=new WeakMap,Kn=new WeakSet,EV=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},Mo=function(e){const t=n=>{switch(e.type){case"failed":return{...n,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...kV(n.data,this.options),fetchMeta:e.meta??null};case"success":const a={...n,...DI(e.data,e.dataUpdatedAt),dataUpdateCount:n.dataUpdateCount+1,...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return Pe(this,xh,e.manual?a:void 0),a;case"error":const i=e.error;return{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...e.state}}};this.state=t(this.state),Qr.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),J(this,Ca).notify({query:this,type:"updated",action:e})})},xV);function kV(r,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:NV(e.networkMode)?"fetching":"paused",...r===void 0&&{error:null,status:"pending"}}}function DI(r,e){return{data:r,dataUpdatedAt:e??Date.now(),error:null,isInvalidated:!1,status:"success"}}function NI(r){const e=typeof r.initialData=="function"?r.initialData():r.initialData,t=e!==void 0,n=t?typeof r.initialDataUpdatedAt=="function"?r.initialDataUpdatedAt():r.initialDataUpdatedAt:0;return{data:e,dataUpdateCount:0,dataUpdatedAt:t?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:t?"success":"pending",fetchStatus:"idle"}}var En,bt,Mg,yn,Zu,bh,Ro,Zs,Dg,_h,Sh,$u,Ku,$s,wh,kt,sp,BT,VT,GT,HT,FT,UT,YT,IV,bV,xq=(bV=class extends Rg{constructor(e,t){super();$e(this,kt);$e(this,En);$e(this,bt);$e(this,Mg);$e(this,yn);$e(this,Zu);$e(this,bh);$e(this,Ro);$e(this,Zs);$e(this,Dg);$e(this,_h);$e(this,Sh);$e(this,$u);$e(this,Ku);$e(this,$s);$e(this,wh,new Set);this.options=t,Pe(this,En,e),Pe(this,Zs,null),Pe(this,Ro,jT()),this.bindMethods(),this.setOptions(t)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(J(this,bt).addObserver(this),LI(J(this,bt),this.options)?xt(this,kt,sp).call(this):this.updateResult(),xt(this,kt,HT).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return WT(J(this,bt),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return WT(J(this,bt),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,xt(this,kt,FT).call(this),xt(this,kt,UT).call(this),J(this,bt).removeObserver(this)}setOptions(e){const t=this.options,n=J(this,bt);if(this.options=J(this,En).defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Da(this.options.enabled,J(this,bt))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");xt(this,kt,YT).call(this),J(this,bt).setOptions(this.options),t._defaulted&&!IT(this.options,t)&&J(this,En).getQueryCache().notify({type:"observerOptionsUpdated",query:J(this,bt),observer:this});const a=this.hasListeners();a&&RI(J(this,bt),n,this.options,t)&&xt(this,kt,sp).call(this),this.updateResult(),a&&(J(this,bt)!==n||Da(this.options.enabled,J(this,bt))!==Da(t.enabled,J(this,bt))||sl(this.options.staleTime,J(this,bt))!==sl(t.staleTime,J(this,bt)))&&xt(this,kt,BT).call(this);const i=xt(this,kt,VT).call(this);a&&(J(this,bt)!==n||Da(this.options.enabled,J(this,bt))!==Da(t.enabled,J(this,bt))||i!==J(this,$s))&&xt(this,kt,GT).call(this,i)}getOptimisticResult(e){const t=J(this,En).getQueryCache().build(J(this,En),e),n=this.createResult(t,e);return _q(this,n)&&(Pe(this,yn,n),Pe(this,bh,this.options),Pe(this,Zu,J(this,bt).state)),n}getCurrentResult(){return J(this,yn)}trackResult(e,t){return new Proxy(e,{get:(n,a)=>(this.trackProp(a),t==null||t(a),a==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&J(this,Ro).status==="pending"&&J(this,Ro).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(n,a))})}trackProp(e){J(this,wh).add(e)}getCurrentQuery(){return J(this,bt)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const t=J(this,En).defaultQueryOptions(e),n=J(this,En).getQueryCache().build(J(this,En),t);return n.fetch().then(()=>this.createResult(n,t))}fetch(e){return xt(this,kt,sp).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),J(this,yn)))}createResult(e,t){var E;const n=J(this,bt),a=this.options,i=J(this,yn),o=J(this,Zu),s=J(this,bh),u=e!==n?e.state:J(this,Mg),{state:c}=e;let f={...c},d=!1,v;if(t._optimisticResults){const k=this.hasListeners(),I=!k&&LI(e,t),B=k&&RI(e,n,t,a);(I||B)&&(f={...f,...kV(c.data,e.options)}),t._optimisticResults==="isRestoring"&&(f.fetchStatus="idle")}let{error:g,errorUpdatedAt:y,status:x}=f;v=f.data;let b=!1;if(t.placeholderData!==void 0&&v===void 0&&x==="pending"){let k;i!=null&&i.isPlaceholderData&&t.placeholderData===(s==null?void 0:s.placeholderData)?(k=i.data,b=!0):k=typeof t.placeholderData=="function"?t.placeholderData((E=J(this,Sh))==null?void 0:E.state.data,J(this,Sh)):t.placeholderData,k!==void 0&&(x="success",v=PT(i==null?void 0:i.data,k,t),d=!0)}if(t.select&&v!==void 0&&!b)if(i&&v===(o==null?void 0:o.data)&&t.select===J(this,Dg))v=J(this,_h);else try{Pe(this,Dg,t.select),v=t.select(v),v=PT(i==null?void 0:i.data,v,t),Pe(this,_h,v),Pe(this,Zs,null)}catch(k){Pe(this,Zs,k)}J(this,Zs)&&(g=J(this,Zs),v=J(this,_h),y=Date.now(),x="error");const w=f.fetchStatus==="fetching",T=x==="pending",C=x==="error",D=T&&w,M=v!==void 0,R={status:x,fetchStatus:f.fetchStatus,isPending:T,isSuccess:x==="success",isError:C,isInitialLoading:D,isLoading:D,data:v,dataUpdatedAt:f.dataUpdatedAt,error:g,errorUpdatedAt:y,failureCount:f.fetchFailureCount,failureReason:f.fetchFailureReason,errorUpdateCount:f.errorUpdateCount,isFetched:e.isFetched(),isFetchedAfterMount:f.dataUpdateCount>u.dataUpdateCount||f.errorUpdateCount>u.errorUpdateCount,isFetching:w,isRefetching:w&&!T,isLoadingError:C&&!M,isPaused:f.fetchStatus==="paused",isPlaceholderData:d,isRefetchError:C&&M,isStale:_M(e,t),refetch:this.refetch,promise:J(this,Ro),isEnabled:Da(t.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const k=R.data!==void 0,I=R.status==="error"&&!k,B=V=>{I?V.reject(R.error):k&&V.resolve(R.data)},P=()=>{const V=Pe(this,Ro,R.promise=jT());B(V)},H=J(this,Ro);switch(H.status){case"pending":e.queryHash===n.queryHash&&B(H);break;case"fulfilled":(I||R.data!==H.value)&&P();break;case"rejected":(!I||R.error!==H.reason)&&P();break}}return R}updateResult(){const e=J(this,yn),t=this.createResult(J(this,bt),this.options);if(Pe(this,Zu,J(this,bt).state),Pe(this,bh,this.options),J(this,Zu).data!==void 0&&Pe(this,Sh,J(this,bt)),IT(t,e))return;Pe(this,yn,t);const n=()=>{if(!e)return!0;const{notifyOnChangeProps:a}=this.options,i=typeof a=="function"?a():a;if(i==="all"||!i&&!J(this,wh).size)return!0;const o=new Set(i??J(this,wh));return this.options.throwOnError&&o.add("error"),Object.keys(J(this,yn)).some(s=>{const l=s;return J(this,yn)[l]!==e[l]&&o.has(l)})};xt(this,kt,IV).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&xt(this,kt,HT).call(this)}},En=new WeakMap,bt=new WeakMap,Mg=new WeakMap,yn=new WeakMap,Zu=new WeakMap,bh=new WeakMap,Ro=new WeakMap,Zs=new WeakMap,Dg=new WeakMap,_h=new WeakMap,Sh=new WeakMap,$u=new WeakMap,Ku=new WeakMap,$s=new WeakMap,wh=new WeakMap,kt=new WeakSet,sp=function(e){xt(this,kt,YT).call(this);let t=J(this,bt).fetch(this.options,e);return e!=null&&e.throwOnError||(t=t.catch(kn)),t},BT=function(){xt(this,kt,FT).call(this);const e=sl(this.options.staleTime,J(this,bt));if(Gp.isServer()||J(this,yn).isStale||!kT(e))return;const n=CV(J(this,yn).dataUpdatedAt,e)+1;Pe(this,$u,Pu.setTimeout(()=>{J(this,yn).isStale||this.updateResult()},n))},VT=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(J(this,bt)):this.options.refetchInterval)??!1},GT=function(e){xt(this,kt,UT).call(this),Pe(this,$s,e),!(Gp.isServer()||Da(this.options.enabled,J(this,bt))===!1||!kT(J(this,$s))||J(this,$s)===0)&&Pe(this,Ku,Pu.setInterval(()=>{(this.options.refetchIntervalInBackground||yM.isFocused())&&xt(this,kt,sp).call(this)},J(this,$s)))},HT=function(){xt(this,kt,BT).call(this),xt(this,kt,GT).call(this,xt(this,kt,VT).call(this))},FT=function(){J(this,$u)!==void 0&&(Pu.clearTimeout(J(this,$u)),Pe(this,$u,void 0))},UT=function(){J(this,Ku)!==void 0&&(Pu.clearInterval(J(this,Ku)),Pe(this,Ku,void 0))},YT=function(){const e=J(this,En).getQueryCache().build(J(this,En),this.options);if(e===J(this,bt))return;const t=J(this,bt);Pe(this,bt,e),Pe(this,Mg,e.state),this.hasListeners()&&(t==null||t.removeObserver(this),e.addObserver(this))},IV=function(e){Qr.batch(()=>{e.listeners&&this.listeners.forEach(t=>{t(J(this,yn))}),J(this,En).getQueryCache().notify({query:J(this,bt),type:"observerResultsUpdated"})})},bV);function bq(r,e){return Da(e.enabled,r)!==!1&&r.state.data===void 0&&!(r.state.status==="error"&&e.retryOnMount===!1)}function LI(r,e){return bq(r,e)||r.state.data!==void 0&&WT(r,e,e.refetchOnMount)}function WT(r,e,t){if(Da(e.enabled,r)!==!1&&sl(e.staleTime,r)!=="static"){const n=typeof t=="function"?t(r):t;return n==="always"||n!==!1&&_M(r,e)}return!1}function RI(r,e,t,n){return(r!==e||Da(n.enabled,r)===!1)&&(!t.suspense||r.state.status!=="error")&&_M(r,t)}function _M(r,e){return Da(e.enabled,r)!==!1&&r.isStaleByTime(sl(e.staleTime,r))}function _q(r,e){return!IT(r.getCurrentResult(),e)}function EI(r){return{onFetch:(e,t)=>{var c,f,d,v,g;const n=e.options,a=(d=(f=(c=e.fetchOptions)==null?void 0:c.meta)==null?void 0:f.fetchMore)==null?void 0:d.direction,i=((v=e.state.data)==null?void 0:v.pages)||[],o=((g=e.state.data)==null?void 0:g.pageParams)||[];let s={pages:[],pageParams:[]},l=0;const u=async()=>{let y=!1;const x=T=>{dq(T,()=>e.signal,()=>y=!0)},b=MV(e.options,e.fetchOptions),w=async(T,C,D)=>{if(y)return Promise.reject();if(C==null&&T.pages.length)return Promise.resolve(T);const N=(()=>{const I={client:e.client,queryKey:e.queryKey,pageParam:C,direction:D?"backward":"forward",meta:e.options.meta};return x(I),I})(),R=await b(N),{maxPages:E}=e.options,k=D?hq:fq;return{pages:k(T.pages,R,E),pageParams:k(T.pageParams,C,E)}};if(a&&i.length){const T=a==="backward",C=T?Sq:kI,D={pages:i,pageParams:o},M=C(n,D);s=await w(D,M,T)}else{const T=r??i.length;do{const C=l===0?o[0]??n.initialPageParam:kI(n,s);if(l>0&&C==null)break;s=await w(s,C),l++}while(l<T)}return s};e.options.persister?e.fetchFn=()=>{var y,x;return(x=(y=e.options).persister)==null?void 0:x.call(y,u,{client:e.client,queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},t)}:e.fetchFn=u}}}function kI(r,{pages:e,pageParams:t}){const n=e.length-1;return e.length>0?r.getNextPageParam(e[n],e,t[n],t):void 0}function Sq(r,{pages:e,pageParams:t}){var n;return e.length>0?(n=r.getPreviousPageParam)==null?void 0:n.call(r,e[0],e,t[0],t):void 0}var Ng,Ai,cn,Qu,Mi,Gs,_V,wq=(_V=class extends RV{constructor(e){super();$e(this,Mi);$e(this,Ng);$e(this,Ai);$e(this,cn);$e(this,Qu);Pe(this,Ng,e.client),this.mutationId=e.mutationId,Pe(this,cn,e.mutationCache),Pe(this,Ai,[]),this.state=e.state||Tq(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){J(this,Ai).includes(e)||(J(this,Ai).push(e),this.clearGcTimeout(),J(this,cn).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){Pe(this,Ai,J(this,Ai).filter(t=>t!==e)),this.scheduleGc(),J(this,cn).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){J(this,Ai).length||(this.state.status==="pending"?this.scheduleGc():J(this,cn).remove(this))}continue(){var e;return((e=J(this,Qu))==null?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var o,s,l,u,c,f,d,v,g,y,x,b,w,T,C,D,M,N;const t=()=>{xt(this,Mi,Gs).call(this,{type:"continue"})},n={client:J(this,Ng),meta:this.options.meta,mutationKey:this.options.mutationKey};Pe(this,Qu,LV({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(new Error("No mutationFn found")),onFail:(R,E)=>{xt(this,Mi,Gs).call(this,{type:"failed",failureCount:R,error:E})},onPause:()=>{xt(this,Mi,Gs).call(this,{type:"pause"})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>J(this,cn).canRun(this)}));const a=this.state.status==="pending",i=!J(this,Qu).canStart();try{if(a)t();else{xt(this,Mi,Gs).call(this,{type:"pending",variables:e,isPaused:i}),J(this,cn).config.onMutate&&await J(this,cn).config.onMutate(e,this,n);const E=await((s=(o=this.options).onMutate)==null?void 0:s.call(o,e,n));E!==this.state.context&&xt(this,Mi,Gs).call(this,{type:"pending",context:E,variables:e,isPaused:i})}const R=await J(this,Qu).start();return await((u=(l=J(this,cn).config).onSuccess)==null?void 0:u.call(l,R,e,this.state.context,this,n)),await((f=(c=this.options).onSuccess)==null?void 0:f.call(c,R,e,this.state.context,n)),await((v=(d=J(this,cn).config).onSettled)==null?void 0:v.call(d,R,null,this.state.variables,this.state.context,this,n)),await((y=(g=this.options).onSettled)==null?void 0:y.call(g,R,null,e,this.state.context,n)),xt(this,Mi,Gs).call(this,{type:"success",data:R}),R}catch(R){try{await((b=(x=J(this,cn).config).onError)==null?void 0:b.call(x,R,e,this.state.context,this,n))}catch(E){Promise.reject(E)}try{await((T=(w=this.options).onError)==null?void 0:T.call(w,R,e,this.state.context,n))}catch(E){Promise.reject(E)}try{await((D=(C=J(this,cn).config).onSettled)==null?void 0:D.call(C,void 0,R,this.state.variables,this.state.context,this,n))}catch(E){Promise.reject(E)}try{await((N=(M=this.options).onSettled)==null?void 0:N.call(M,void 0,R,e,this.state.context,n))}catch(E){Promise.reject(E)}throw xt(this,Mi,Gs).call(this,{type:"error",error:R}),R}finally{J(this,cn).runNext(this)}}},Ng=new WeakMap,Ai=new WeakMap,cn=new WeakMap,Qu=new WeakMap,Mi=new WeakSet,Gs=function(e){const t=n=>{switch(e.type){case"failed":return{...n,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...n,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:e.error,failureCount:n.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=t(this.state),Qr.batch(()=>{J(this,Ai).forEach(n=>{n.onMutationUpdate(e)}),J(this,cn).notify({mutation:this,type:"updated",action:e})})},_V);function Tq(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Eo,$a,Lg,SV,Cq=(SV=class extends Rg{constructor(e={}){super();$e(this,Eo);$e(this,$a);$e(this,Lg);this.config=e,Pe(this,Eo,new Set),Pe(this,$a,new Map),Pe(this,Lg,0)}build(e,t,n){const a=new wq({client:e,mutationCache:this,mutationId:++yy(this,Lg)._,options:e.defaultMutationOptions(t),state:n});return this.add(a),a}add(e){J(this,Eo).add(e);const t=xy(e);if(typeof t=="string"){const n=J(this,$a).get(t);n?n.push(e):J(this,$a).set(t,[e])}this.notify({type:"added",mutation:e})}remove(e){if(J(this,Eo).delete(e)){const t=xy(e);if(typeof t=="string"){const n=J(this,$a).get(t);if(n)if(n.length>1){const a=n.indexOf(e);a!==-1&&n.splice(a,1)}else n[0]===e&&J(this,$a).delete(t)}}this.notify({type:"removed",mutation:e})}canRun(e){const t=xy(e);if(typeof t=="string"){const n=J(this,$a).get(t),a=n==null?void 0:n.find(i=>i.state.status==="pending");return!a||a===e}else return!0}runNext(e){var n;const t=xy(e);if(typeof t=="string"){const a=(n=J(this,$a).get(t))==null?void 0:n.find(i=>i!==e&&i.state.isPaused);return(a==null?void 0:a.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Qr.batch(()=>{J(this,Eo).forEach(e=>{this.notify({type:"removed",mutation:e})}),J(this,Eo).clear(),J(this,$a).clear()})}getAll(){return Array.from(J(this,Eo))}find(e){const t={exact:!0,...e};return this.getAll().find(n=>CI(t,n))}findAll(e={}){return this.getAll().filter(t=>CI(e,t))}notify(e){Qr.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){const e=this.getAll().filter(t=>t.state.isPaused);return Qr.batch(()=>Promise.all(e.map(t=>t.continue().catch(kn))))}},Eo=new WeakMap,$a=new WeakMap,Lg=new WeakMap,SV);function xy(r){var e;return(e=r.options.scope)==null?void 0:e.id}var Di,wV,Aq=(wV=class extends Rg{constructor(e={}){super();$e(this,Di);this.config=e,Pe(this,Di,new Map)}build(e,t,n){const a=t.queryKey,i=t.queryHash??xM(a,t);let o=this.get(i);return o||(o=new yq({client:e,queryKey:a,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(a)}),this.add(o)),o}add(e){J(this,Di).has(e.queryHash)||(J(this,Di).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=J(this,Di).get(e.queryHash);t&&(e.destroy(),t===e&&J(this,Di).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){Qr.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return J(this,Di).get(e)}getAll(){return[...J(this,Di).values()]}find(e){const t={exact:!0,...e};return this.getAll().find(n=>TI(t,n))}findAll(e={}){const t=this.getAll();return Object.keys(e).length>0?t.filter(n=>TI(e,n)):t}notify(e){Qr.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){Qr.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){Qr.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Di=new WeakMap,wV),nr,Ks,Qs,Th,Ch,Js,Ah,Mh,TV,Mq=(TV=class{constructor(r={}){$e(this,nr);$e(this,Ks);$e(this,Qs);$e(this,Th);$e(this,Ch);$e(this,Js);$e(this,Ah);$e(this,Mh);Pe(this,nr,r.queryCache||new Aq),Pe(this,Ks,r.mutationCache||new Cq),Pe(this,Qs,r.defaultOptions||{}),Pe(this,Th,new Map),Pe(this,Ch,new Map),Pe(this,Js,0)}mount(){yy(this,Js)._++,J(this,Js)===1&&(Pe(this,Ah,yM.subscribe(async r=>{r&&(await this.resumePausedMutations(),J(this,nr).onFocus())})),Pe(this,Mh,dx.subscribe(async r=>{r&&(await this.resumePausedMutations(),J(this,nr).onOnline())})))}unmount(){var r,e;yy(this,Js)._--,J(this,Js)===0&&((r=J(this,Ah))==null||r.call(this),Pe(this,Ah,void 0),(e=J(this,Mh))==null||e.call(this),Pe(this,Mh,void 0))}isFetching(r){return J(this,nr).findAll({...r,fetchStatus:"fetching"}).length}isMutating(r){return J(this,Ks).findAll({...r,status:"pending"}).length}getQueryData(r){var t;const e=this.defaultQueryOptions({queryKey:r});return(t=J(this,nr).get(e.queryHash))==null?void 0:t.state.data}ensureQueryData(r){const e=this.defaultQueryOptions(r),t=J(this,nr).build(this,e),n=t.state.data;return n===void 0?this.fetchQuery(r):(r.revalidateIfStale&&t.isStaleByTime(sl(e.staleTime,t))&&this.prefetchQuery(e),Promise.resolve(n))}getQueriesData(r){return J(this,nr).findAll(r).map(({queryKey:e,state:t})=>{const n=t.data;return[e,n]})}setQueryData(r,e,t){const n=this.defaultQueryOptions({queryKey:r}),a=J(this,nr).get(n.queryHash),i=a==null?void 0:a.state.data,o=lq(e,i);if(o!==void 0)return J(this,nr).build(this,n).setData(o,{...t,manual:!0})}setQueriesData(r,e,t){return Qr.batch(()=>J(this,nr).findAll(r).map(({queryKey:n})=>[n,this.setQueryData(n,e,t)]))}getQueryState(r){var t;const e=this.defaultQueryOptions({queryKey:r});return(t=J(this,nr).get(e.queryHash))==null?void 0:t.state}removeQueries(r){const e=J(this,nr);Qr.batch(()=>{e.findAll(r).forEach(t=>{e.remove(t)})})}resetQueries(r,e){const t=J(this,nr);return Qr.batch(()=>(t.findAll(r).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...r},e)))}cancelQueries(r,e={}){const t={revert:!0,...e},n=Qr.batch(()=>J(this,nr).findAll(r).map(a=>a.cancel(t)));return Promise.all(n).then(kn).catch(kn)}invalidateQueries(r,e={}){return Qr.batch(()=>(J(this,nr).findAll(r).forEach(t=>{t.invalidate()}),(r==null?void 0:r.refetchType)==="none"?Promise.resolve():this.refetchQueries({...r,type:(r==null?void 0:r.refetchType)??(r==null?void 0:r.type)??"active"},e)))}refetchQueries(r,e={}){const t={...e,cancelRefetch:e.cancelRefetch??!0},n=Qr.batch(()=>J(this,nr).findAll(r).filter(a=>!a.isDisabled()&&!a.isStatic()).map(a=>{let i=a.fetch(void 0,t);return t.throwOnError||(i=i.catch(kn)),a.state.fetchStatus==="paused"?Promise.resolve():i}));return Promise.all(n).then(kn)}fetchQuery(r){const e=this.defaultQueryOptions(r);e.retry===void 0&&(e.retry=!1);const t=J(this,nr).build(this,e);return t.isStaleByTime(sl(e.staleTime,t))?t.fetch(e):Promise.resolve(t.state.data)}prefetchQuery(r){return this.fetchQuery(r).then(kn).catch(kn)}fetchInfiniteQuery(r){return r.behavior=EI(r.pages),this.fetchQuery(r)}prefetchInfiniteQuery(r){return this.fetchInfiniteQuery(r).then(kn).catch(kn)}ensureInfiniteQueryData(r){return r.behavior=EI(r.pages),this.ensureQueryData(r)}resumePausedMutations(){return dx.isOnline()?J(this,Ks).resumePausedMutations():Promise.resolve()}getQueryCache(){return J(this,nr)}getMutationCache(){return J(this,Ks)}getDefaultOptions(){return J(this,Qs)}setDefaultOptions(r){Pe(this,Qs,r)}setQueryDefaults(r,e){J(this,Th).set(Bp(r),{queryKey:r,defaultOptions:e})}getQueryDefaults(r){const e=[...J(this,Th).values()],t={};return e.forEach(n=>{Vp(r,n.queryKey)&&Object.assign(t,n.defaultOptions)}),t}setMutationDefaults(r,e){J(this,Ch).set(Bp(r),{mutationKey:r,defaultOptions:e})}getMutationDefaults(r){const e=[...J(this,Ch).values()],t={};return e.forEach(n=>{Vp(r,n.mutationKey)&&Object.assign(t,n.defaultOptions)}),t}defaultQueryOptions(r){if(r._defaulted)return r;const e={...J(this,Qs).queries,...this.getQueryDefaults(r.queryKey),...r,_defaulted:!0};return e.queryHash||(e.queryHash=xM(e.queryKey,e)),e.refetchOnReconnect===void 0&&(e.refetchOnReconnect=e.networkMode!=="always"),e.throwOnError===void 0&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.queryFn===bM&&(e.enabled=!1),e}defaultMutationOptions(r){return r!=null&&r._defaulted?r:{...J(this,Qs).mutations,...(r==null?void 0:r.mutationKey)&&this.getMutationDefaults(r.mutationKey),...r,_defaulted:!0}}clear(){J(this,nr).clear(),J(this,Ks).clear()}},nr=new WeakMap,Ks=new WeakMap,Qs=new WeakMap,Th=new WeakMap,Ch=new WeakMap,Js=new WeakMap,Ah=new WeakMap,Mh=new WeakMap,TV),HS={exports:{}},ut={};/**
10
- * @license React
11
- * react.production.js
12
- *
13
- * Copyright (c) Meta Platforms, Inc. and affiliates.
14
- *
15
- * This source code is licensed under the MIT license found in the
16
- * LICENSE file in the root directory of this source tree.
17
- */var II;function Dq(){if(II)return ut;II=1;var r=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),t=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),o=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),u=Symbol.for("react.memo"),c=Symbol.for("react.lazy"),f=Symbol.iterator;function d(G){return G===null||typeof G!="object"?null:(G=f&&G[f]||G["@@iterator"],typeof G=="function"?G:null)}var v={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,y={};function x(G,W,$){this.props=G,this.context=W,this.refs=y,this.updater=$||v}x.prototype.isReactComponent={},x.prototype.setState=function(G,W){if(typeof G!="object"&&typeof G!="function"&&G!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,G,W,"setState")},x.prototype.forceUpdate=function(G){this.updater.enqueueForceUpdate(this,G,"forceUpdate")};function b(){}b.prototype=x.prototype;function w(G,W,$){this.props=G,this.context=W,this.refs=y,this.updater=$||v}var T=w.prototype=new b;T.constructor=w,g(T,x.prototype),T.isPureReactComponent=!0;var C=Array.isArray,D={H:null,A:null,T:null,S:null,V:null},M=Object.prototype.hasOwnProperty;function N(G,W,$,te,ue,ge){return $=ge.ref,{$$typeof:r,type:G,key:W,ref:$!==void 0?$:null,props:ge}}function R(G,W){return N(G.type,W,void 0,void 0,void 0,G.props)}function E(G){return typeof G=="object"&&G!==null&&G.$$typeof===r}function k(G){var W={"=":"=0",":":"=2"};return"$"+G.replace(/[=:]/g,function($){return W[$]})}var I=/\/+/g;function B(G,W){return typeof G=="object"&&G!==null&&G.key!=null?k(""+G.key):W.toString(36)}function P(){}function H(G){switch(G.status){case"fulfilled":return G.value;case"rejected":throw G.reason;default:switch(typeof G.status=="string"?G.then(P,P):(G.status="pending",G.then(function(W){G.status==="pending"&&(G.status="fulfilled",G.value=W)},function(W){G.status==="pending"&&(G.status="rejected",G.reason=W)})),G.status){case"fulfilled":return G.value;case"rejected":throw G.reason}}throw G}function V(G,W,$,te,ue){var ge=typeof G;(ge==="undefined"||ge==="boolean")&&(G=null);var Se=!1;if(G===null)Se=!0;else switch(ge){case"bigint":case"string":case"number":Se=!0;break;case"object":switch(G.$$typeof){case r:case e:Se=!0;break;case c:return Se=G._init,V(Se(G._payload),W,$,te,ue)}}if(Se)return ue=ue(G),Se=te===""?"."+B(G,0):te,C(ue)?($="",Se!=null&&($=Se.replace(I,"$&/")+"/"),V(ue,W,$,"",function(we){return we})):ue!=null&&(E(ue)&&(ue=R(ue,$+(ue.key==null||G&&G.key===ue.key?"":(""+ue.key).replace(I,"$&/")+"/")+Se)),W.push(ue)),1;Se=0;var Xe=te===""?".":te+":";if(C(G))for(var be=0;be<G.length;be++)te=G[be],ge=Xe+B(te,be),Se+=V(te,W,$,ge,ue);else if(be=d(G),typeof be=="function")for(G=be.call(G),be=0;!(te=G.next()).done;)te=te.value,ge=Xe+B(te,be++),Se+=V(te,W,$,ge,ue);else if(ge==="object"){if(typeof G.then=="function")return V(H(G),W,$,te,ue);throw W=String(G),Error("Objects are not valid as a React child (found: "+(W==="[object Object]"?"object with keys {"+Object.keys(G).join(", ")+"}":W)+"). If you meant to render a collection of children, use an array instead.")}return Se}function j(G,W,$){if(G==null)return G;var te=[],ue=0;return V(G,te,"","",function(ge){return W.call($,ge,ue++)}),te}function U(G){if(G._status===-1){var W=G._result;W=W(),W.then(function($){(G._status===0||G._status===-1)&&(G._status=1,G._result=$)},function($){(G._status===0||G._status===-1)&&(G._status=2,G._result=$)}),G._status===-1&&(G._status=0,G._result=W)}if(G._status===1)return G._result.default;throw G._result}var F=typeof reportError=="function"?reportError:function(G){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var W=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof G=="object"&&G!==null&&typeof G.message=="string"?String(G.message):String(G),error:G});if(!window.dispatchEvent(W))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",G);return}console.error(G)};function X(){}return ut.Children={map:j,forEach:function(G,W,$){j(G,function(){W.apply(this,arguments)},$)},count:function(G){var W=0;return j(G,function(){W++}),W},toArray:function(G){return j(G,function(W){return W})||[]},only:function(G){if(!E(G))throw Error("React.Children.only expected to receive a single React element child.");return G}},ut.Component=x,ut.Fragment=t,ut.Profiler=a,ut.PureComponent=w,ut.StrictMode=n,ut.Suspense=l,ut.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=D,ut.__COMPILER_RUNTIME={__proto__:null,c:function(G){return D.H.useMemoCache(G)}},ut.cache=function(G){return function(){return G.apply(null,arguments)}},ut.cloneElement=function(G,W,$){if(G==null)throw Error("The argument must be a React element, but you passed "+G+".");var te=g({},G.props),ue=G.key,ge=void 0;if(W!=null)for(Se in W.ref!==void 0&&(ge=void 0),W.key!==void 0&&(ue=""+W.key),W)!M.call(W,Se)||Se==="key"||Se==="__self"||Se==="__source"||Se==="ref"&&W.ref===void 0||(te[Se]=W[Se]);var Se=arguments.length-2;if(Se===1)te.children=$;else if(1<Se){for(var Xe=Array(Se),be=0;be<Se;be++)Xe[be]=arguments[be+2];te.children=Xe}return N(G.type,ue,void 0,void 0,ge,te)},ut.createContext=function(G){return G={$$typeof:o,_currentValue:G,_currentValue2:G,_threadCount:0,Provider:null,Consumer:null},G.Provider=G,G.Consumer={$$typeof:i,_context:G},G},ut.createElement=function(G,W,$){var te,ue={},ge=null;if(W!=null)for(te in W.key!==void 0&&(ge=""+W.key),W)M.call(W,te)&&te!=="key"&&te!=="__self"&&te!=="__source"&&(ue[te]=W[te]);var Se=arguments.length-2;if(Se===1)ue.children=$;else if(1<Se){for(var Xe=Array(Se),be=0;be<Se;be++)Xe[be]=arguments[be+2];ue.children=Xe}if(G&&G.defaultProps)for(te in Se=G.defaultProps,Se)ue[te]===void 0&&(ue[te]=Se[te]);return N(G,ge,void 0,void 0,null,ue)},ut.createRef=function(){return{current:null}},ut.forwardRef=function(G){return{$$typeof:s,render:G}},ut.isValidElement=E,ut.lazy=function(G){return{$$typeof:c,_payload:{_status:-1,_result:G},_init:U}},ut.memo=function(G,W){return{$$typeof:u,type:G,compare:W===void 0?null:W}},ut.startTransition=function(G){var W=D.T,$={};D.T=$;try{var te=G(),ue=D.S;ue!==null&&ue($,te),typeof te=="object"&&te!==null&&typeof te.then=="function"&&te.then(X,F)}catch(ge){F(ge)}finally{D.T=W}},ut.unstable_useCacheRefresh=function(){return D.H.useCacheRefresh()},ut.use=function(G){return D.H.use(G)},ut.useActionState=function(G,W,$){return D.H.useActionState(G,W,$)},ut.useCallback=function(G,W){return D.H.useCallback(G,W)},ut.useContext=function(G){return D.H.useContext(G)},ut.useDebugValue=function(){},ut.useDeferredValue=function(G,W){return D.H.useDeferredValue(G,W)},ut.useEffect=function(G,W,$){var te=D.H;if(typeof $=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return te.useEffect(G,W)},ut.useId=function(){return D.H.useId()},ut.useImperativeHandle=function(G,W,$){return D.H.useImperativeHandle(G,W,$)},ut.useInsertionEffect=function(G,W){return D.H.useInsertionEffect(G,W)},ut.useLayoutEffect=function(G,W){return D.H.useLayoutEffect(G,W)},ut.useMemo=function(G,W){return D.H.useMemo(G,W)},ut.useOptimistic=function(G,W){return D.H.useOptimistic(G,W)},ut.useReducer=function(G,W,$){return D.H.useReducer(G,W,$)},ut.useRef=function(G){return D.H.useRef(G)},ut.useState=function(G){return D.H.useState(G)},ut.useSyncExternalStore=function(G,W,$){return D.H.useSyncExternalStore(G,W,$)},ut.useTransition=function(){return D.H.useTransition()},ut.version="19.1.0",ut}var OI;function SM(){return OI||(OI=1,HS.exports=Dq()),HS.exports}var q=SM();const OV=mM(q),PV=eq({__proto__:null,default:OV},[q]);var jV=q.createContext(void 0),zV=r=>{const e=q.useContext(jV);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},Nq=({client:r,children:e})=>(q.useEffect(()=>(r.mount(),()=>{r.unmount()}),[r]),_.jsx(jV.Provider,{value:r,children:e})),BV=q.createContext(!1),Lq=()=>q.useContext(BV);BV.Provider;function Rq(){let r=!1;return{clearReset:()=>{r=!1},reset:()=>{r=!0},isReset:()=>r}}var Eq=q.createContext(Rq()),kq=()=>q.useContext(Eq),Iq=(r,e,t)=>{const n=t!=null&&t.state.error&&typeof r.throwOnError=="function"?DV(r.throwOnError,[t.state.error,t]):r.throwOnError;(r.suspense||r.experimental_prefetchInRender||n)&&(e.isReset()||(r.retryOnMount=!1))},Oq=r=>{q.useEffect(()=>{r.clearReset()},[r])},Pq=({result:r,errorResetBoundary:e,throwOnError:t,query:n,suspense:a})=>r.isError&&!e.isReset()&&!r.isFetching&&n&&(a&&r.data===void 0||DV(t,[r.error,n])),jq=r=>{if(r.suspense){const t=a=>a==="static"?a:Math.max(a??1e3,1e3),n=r.staleTime;r.staleTime=typeof n=="function"?(...a)=>t(n(...a)):t(n),typeof r.gcTime=="number"&&(r.gcTime=Math.max(r.gcTime,1e3))}},zq=(r,e)=>r.isLoading&&r.isFetching&&!e,Bq=(r,e)=>(r==null?void 0:r.suspense)&&e.isPending,PI=(r,e,t)=>e.fetchOptimistic(r).catch(()=>{t.clearReset()});function Vq(r,e,t){var d,v,g,y;const n=Lq(),a=kq(),i=zV(),o=i.defaultQueryOptions(r);(v=(d=i.getDefaultOptions().queries)==null?void 0:d._experimental_beforeQuery)==null||v.call(d,o);const s=i.getQueryCache().get(o.queryHash);o._optimisticResults=n?"isRestoring":"optimistic",jq(o),Iq(o,a,s),Oq(a);const l=!i.getQueryCache().get(o.queryHash),[u]=q.useState(()=>new e(i,o)),c=u.getOptimisticResult(o),f=!n&&r.subscribed!==!1;if(q.useSyncExternalStore(q.useCallback(x=>{const b=f?u.subscribe(Qr.batchCalls(x)):kn;return u.updateResult(),b},[u,f]),()=>u.getCurrentResult(),()=>u.getCurrentResult()),q.useEffect(()=>{u.setOptions(o)},[o,u]),Bq(o,c))throw PI(o,u,a);if(Pq({result:c,errorResetBoundary:a,throwOnError:o.throwOnError,query:s,suspense:o.suspense}))throw c.error;if((y=(g=i.getDefaultOptions().queries)==null?void 0:g._experimental_afterQuery)==null||y.call(g,o,c),o.experimental_prefetchInRender&&!Gp.isServer()&&zq(c,n)){const x=l?PI(o,u,a):s==null?void 0:s.promise;x==null||x.catch(kn).finally(()=>{u.updateResult()})}return o.notifyOnChangeProps?c:u.trackResult(c)}function wr(r,e){return Vq(r,xq)}var FS={exports:{}},mv={},US={exports:{}},YS={};/**
18
- * @license React
19
- * scheduler.production.js
20
- *
21
- * Copyright (c) Meta Platforms, Inc. and affiliates.
22
- *
23
- * This source code is licensed under the MIT license found in the
24
- * LICENSE file in the root directory of this source tree.
25
- */var jI;function Gq(){return jI||(jI=1,(function(r){function e(j,U){var F=j.length;j.push(U);e:for(;0<F;){var X=F-1>>>1,G=j[X];if(0<a(G,U))j[X]=U,j[F]=G,F=X;else break e}}function t(j){return j.length===0?null:j[0]}function n(j){if(j.length===0)return null;var U=j[0],F=j.pop();if(F!==U){j[0]=F;e:for(var X=0,G=j.length,W=G>>>1;X<W;){var $=2*(X+1)-1,te=j[$],ue=$+1,ge=j[ue];if(0>a(te,F))ue<G&&0>a(ge,te)?(j[X]=ge,j[ue]=F,X=ue):(j[X]=te,j[$]=F,X=$);else if(ue<G&&0>a(ge,F))j[X]=ge,j[ue]=F,X=ue;else break e}}return U}function a(j,U){var F=j.sortIndex-U.sortIndex;return F!==0?F:j.id-U.id}if(r.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var i=performance;r.unstable_now=function(){return i.now()}}else{var o=Date,s=o.now();r.unstable_now=function(){return o.now()-s}}var l=[],u=[],c=1,f=null,d=3,v=!1,g=!1,y=!1,x=!1,b=typeof setTimeout=="function"?setTimeout:null,w=typeof clearTimeout=="function"?clearTimeout:null,T=typeof setImmediate<"u"?setImmediate:null;function C(j){for(var U=t(u);U!==null;){if(U.callback===null)n(u);else if(U.startTime<=j)n(u),U.sortIndex=U.expirationTime,e(l,U);else break;U=t(u)}}function D(j){if(y=!1,C(j),!g)if(t(l)!==null)g=!0,M||(M=!0,B());else{var U=t(u);U!==null&&V(D,U.startTime-j)}}var M=!1,N=-1,R=5,E=-1;function k(){return x?!0:!(r.unstable_now()-E<R)}function I(){if(x=!1,M){var j=r.unstable_now();E=j;var U=!0;try{e:{g=!1,y&&(y=!1,w(N),N=-1),v=!0;var F=d;try{t:{for(C(j),f=t(l);f!==null&&!(f.expirationTime>j&&k());){var X=f.callback;if(typeof X=="function"){f.callback=null,d=f.priorityLevel;var G=X(f.expirationTime<=j);if(j=r.unstable_now(),typeof G=="function"){f.callback=G,C(j),U=!0;break t}f===t(l)&&n(l),C(j)}else n(l);f=t(l)}if(f!==null)U=!0;else{var W=t(u);W!==null&&V(D,W.startTime-j),U=!1}}break e}finally{f=null,d=F,v=!1}U=void 0}}finally{U?B():M=!1}}}var B;if(typeof T=="function")B=function(){T(I)};else if(typeof MessageChannel<"u"){var P=new MessageChannel,H=P.port2;P.port1.onmessage=I,B=function(){H.postMessage(null)}}else B=function(){b(I,0)};function V(j,U){N=b(function(){j(r.unstable_now())},U)}r.unstable_IdlePriority=5,r.unstable_ImmediatePriority=1,r.unstable_LowPriority=4,r.unstable_NormalPriority=3,r.unstable_Profiling=null,r.unstable_UserBlockingPriority=2,r.unstable_cancelCallback=function(j){j.callback=null},r.unstable_forceFrameRate=function(j){0>j||125<j?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):R=0<j?Math.floor(1e3/j):5},r.unstable_getCurrentPriorityLevel=function(){return d},r.unstable_next=function(j){switch(d){case 1:case 2:case 3:var U=3;break;default:U=d}var F=d;d=U;try{return j()}finally{d=F}},r.unstable_requestPaint=function(){x=!0},r.unstable_runWithPriority=function(j,U){switch(j){case 1:case 2:case 3:case 4:case 5:break;default:j=3}var F=d;d=j;try{return U()}finally{d=F}},r.unstable_scheduleCallback=function(j,U,F){var X=r.unstable_now();switch(typeof F=="object"&&F!==null?(F=F.delay,F=typeof F=="number"&&0<F?X+F:X):F=X,j){case 1:var G=-1;break;case 2:G=250;break;case 5:G=1073741823;break;case 4:G=1e4;break;default:G=5e3}return G=F+G,j={id:c++,callback:U,priorityLevel:j,startTime:F,expirationTime:G,sortIndex:-1},F>X?(j.sortIndex=F,e(u,j),t(l)===null&&j===t(u)&&(y?(w(N),N=-1):y=!0,V(D,F-X))):(j.sortIndex=G,e(l,j),g||v||(g=!0,M||(M=!0,B()))),j},r.unstable_shouldYield=k,r.unstable_wrapCallback=function(j){var U=d;return function(){var F=d;d=U;try{return j.apply(this,arguments)}finally{d=F}}}})(YS)),YS}var zI;function Hq(){return zI||(zI=1,US.exports=Gq()),US.exports}var WS={exports:{}},ln={};/**
26
- * @license React
27
- * react-dom.production.js
28
- *
29
- * Copyright (c) Meta Platforms, Inc. and affiliates.
30
- *
31
- * This source code is licensed under the MIT license found in the
32
- * LICENSE file in the root directory of this source tree.
33
- */var BI;function Fq(){if(BI)return ln;BI=1;var r=SM();function e(l){var u="https://react.dev/errors/"+l;if(1<arguments.length){u+="?args[]="+encodeURIComponent(arguments[1]);for(var c=2;c<arguments.length;c++)u+="&args[]="+encodeURIComponent(arguments[c])}return"Minified React error #"+l+"; visit "+u+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function t(){}var n={d:{f:t,r:function(){throw Error(e(522))},D:t,C:t,L:t,m:t,X:t,S:t,M:t},p:0,findDOMNode:null},a=Symbol.for("react.portal");function i(l,u,c){var f=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:f==null?null:""+f,children:l,containerInfo:u,implementation:c}}var o=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function s(l,u){if(l==="font")return"";if(typeof u=="string")return u==="use-credentials"?u:""}return ln.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=n,ln.createPortal=function(l,u){var c=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!u||u.nodeType!==1&&u.nodeType!==9&&u.nodeType!==11)throw Error(e(299));return i(l,u,null,c)},ln.flushSync=function(l){var u=o.T,c=n.p;try{if(o.T=null,n.p=2,l)return l()}finally{o.T=u,n.p=c,n.d.f()}},ln.preconnect=function(l,u){typeof l=="string"&&(u?(u=u.crossOrigin,u=typeof u=="string"?u==="use-credentials"?u:"":void 0):u=null,n.d.C(l,u))},ln.prefetchDNS=function(l){typeof l=="string"&&n.d.D(l)},ln.preinit=function(l,u){if(typeof l=="string"&&u&&typeof u.as=="string"){var c=u.as,f=s(c,u.crossOrigin),d=typeof u.integrity=="string"?u.integrity:void 0,v=typeof u.fetchPriority=="string"?u.fetchPriority:void 0;c==="style"?n.d.S(l,typeof u.precedence=="string"?u.precedence:void 0,{crossOrigin:f,integrity:d,fetchPriority:v}):c==="script"&&n.d.X(l,{crossOrigin:f,integrity:d,fetchPriority:v,nonce:typeof u.nonce=="string"?u.nonce:void 0})}},ln.preinitModule=function(l,u){if(typeof l=="string")if(typeof u=="object"&&u!==null){if(u.as==null||u.as==="script"){var c=s(u.as,u.crossOrigin);n.d.M(l,{crossOrigin:c,integrity:typeof u.integrity=="string"?u.integrity:void 0,nonce:typeof u.nonce=="string"?u.nonce:void 0})}}else u==null&&n.d.M(l)},ln.preload=function(l,u){if(typeof l=="string"&&typeof u=="object"&&u!==null&&typeof u.as=="string"){var c=u.as,f=s(c,u.crossOrigin);n.d.L(l,c,{crossOrigin:f,integrity:typeof u.integrity=="string"?u.integrity:void 0,nonce:typeof u.nonce=="string"?u.nonce:void 0,type:typeof u.type=="string"?u.type:void 0,fetchPriority:typeof u.fetchPriority=="string"?u.fetchPriority:void 0,referrerPolicy:typeof u.referrerPolicy=="string"?u.referrerPolicy:void 0,imageSrcSet:typeof u.imageSrcSet=="string"?u.imageSrcSet:void 0,imageSizes:typeof u.imageSizes=="string"?u.imageSizes:void 0,media:typeof u.media=="string"?u.media:void 0})}},ln.preloadModule=function(l,u){if(typeof l=="string")if(u){var c=s(u.as,u.crossOrigin);n.d.m(l,{as:typeof u.as=="string"&&u.as!=="script"?u.as:void 0,crossOrigin:c,integrity:typeof u.integrity=="string"?u.integrity:void 0})}else n.d.m(l)},ln.requestFormReset=function(l){n.d.r(l)},ln.unstable_batchedUpdates=function(l,u){return l(u)},ln.useFormState=function(l,u,c){return o.H.useFormState(l,u,c)},ln.useFormStatus=function(){return o.H.useHostTransitionStatus()},ln.version="19.1.0",ln}var VI;function VV(){if(VI)return WS.exports;VI=1;function r(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(e){console.error(e)}}return r(),WS.exports=Fq(),WS.exports}/**
34
- * @license React
35
- * react-dom-client.production.js
36
- *
37
- * Copyright (c) Meta Platforms, Inc. and affiliates.
38
- *
39
- * This source code is licensed under the MIT license found in the
40
- * LICENSE file in the root directory of this source tree.
41
- */var GI;function Uq(){if(GI)return mv;GI=1;var r=Hq(),e=SM(),t=VV();function n(h){var p="https://react.dev/errors/"+h;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var m=2;m<arguments.length;m++)p+="&args[]="+encodeURIComponent(arguments[m])}return"Minified React error #"+h+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function a(h){return!(!h||h.nodeType!==1&&h.nodeType!==9&&h.nodeType!==11)}function i(h){var p=h,m=h;if(h.alternate)for(;p.return;)p=p.return;else{h=p;do p=h,(p.flags&4098)!==0&&(m=p.return),h=p.return;while(h)}return p.tag===3?m:null}function o(h){if(h.tag===13){var p=h.memoizedState;if(p===null&&(h=h.alternate,h!==null&&(p=h.memoizedState)),p!==null)return p.dehydrated}return null}function s(h){if(i(h)!==h)throw Error(n(188))}function l(h){var p=h.alternate;if(!p){if(p=i(h),p===null)throw Error(n(188));return p!==h?null:h}for(var m=h,S=p;;){var A=m.return;if(A===null)break;var L=A.alternate;if(L===null){if(S=A.return,S!==null){m=S;continue}break}if(A.child===L.child){for(L=A.child;L;){if(L===m)return s(A),h;if(L===S)return s(A),p;L=L.sibling}throw Error(n(188))}if(m.return!==S.return)m=A,S=L;else{for(var z=!1,Y=A.child;Y;){if(Y===m){z=!0,m=A,S=L;break}if(Y===S){z=!0,S=A,m=L;break}Y=Y.sibling}if(!z){for(Y=L.child;Y;){if(Y===m){z=!0,m=L,S=A;break}if(Y===S){z=!0,S=L,m=A;break}Y=Y.sibling}if(!z)throw Error(n(189))}}if(m.alternate!==S)throw Error(n(190))}if(m.tag!==3)throw Error(n(188));return m.stateNode.current===m?h:p}function u(h){var p=h.tag;if(p===5||p===26||p===27||p===6)return h;for(h=h.child;h!==null;){if(p=u(h),p!==null)return p;h=h.sibling}return null}var c=Object.assign,f=Symbol.for("react.element"),d=Symbol.for("react.transitional.element"),v=Symbol.for("react.portal"),g=Symbol.for("react.fragment"),y=Symbol.for("react.strict_mode"),x=Symbol.for("react.profiler"),b=Symbol.for("react.provider"),w=Symbol.for("react.consumer"),T=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),D=Symbol.for("react.suspense"),M=Symbol.for("react.suspense_list"),N=Symbol.for("react.memo"),R=Symbol.for("react.lazy"),E=Symbol.for("react.activity"),k=Symbol.for("react.memo_cache_sentinel"),I=Symbol.iterator;function B(h){return h===null||typeof h!="object"?null:(h=I&&h[I]||h["@@iterator"],typeof h=="function"?h:null)}var P=Symbol.for("react.client.reference");function H(h){if(h==null)return null;if(typeof h=="function")return h.$$typeof===P?null:h.displayName||h.name||null;if(typeof h=="string")return h;switch(h){case g:return"Fragment";case x:return"Profiler";case y:return"StrictMode";case D:return"Suspense";case M:return"SuspenseList";case E:return"Activity"}if(typeof h=="object")switch(h.$$typeof){case v:return"Portal";case T:return(h.displayName||"Context")+".Provider";case w:return(h._context.displayName||"Context")+".Consumer";case C:var p=h.render;return h=h.displayName,h||(h=p.displayName||p.name||"",h=h!==""?"ForwardRef("+h+")":"ForwardRef"),h;case N:return p=h.displayName||null,p!==null?p:H(h.type)||"Memo";case R:p=h._payload,h=h._init;try{return H(h(p))}catch{}}return null}var V=Array.isArray,j=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,U=t.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F={pending:!1,data:null,method:null,action:null},X=[],G=-1;function W(h){return{current:h}}function $(h){0>G||(h.current=X[G],X[G]=null,G--)}function te(h,p){G++,X[G]=h.current,h.current=p}var ue=W(null),ge=W(null),Se=W(null),Xe=W(null);function be(h,p){switch(te(Se,p),te(ge,h),te(ue,null),p.nodeType){case 9:case 11:h=(h=p.documentElement)&&(h=h.namespaceURI)?Zk(h):0;break;default:if(h=p.tagName,p=p.namespaceURI)p=Zk(p),h=$k(p,h);else switch(h){case"svg":h=1;break;case"math":h=2;break;default:h=0}}$(ue),te(ue,h)}function we(){$(ue),$(ge),$(Se)}function ze(h){h.memoizedState!==null&&te(Xe,h);var p=ue.current,m=$k(p,h.type);p!==m&&(te(ge,h),te(ue,m))}function oe(h){ge.current===h&&($(ue),$(ge)),Xe.current===h&&($(Xe),fv._currentValue=F)}var pe=Object.prototype.hasOwnProperty,Be=r.unstable_scheduleCallback,Le=r.unstable_cancelCallback,at=r.unstable_shouldYield,ft=r.unstable_requestPaint,At=r.unstable_now,Wr=r.unstable_getCurrentPriorityLevel,er=r.unstable_ImmediatePriority,ci=r.unstable_UserBlockingPriority,Ga=r.unstable_NormalPriority,yd=r.unstable_LowPriority,RL=r.unstable_IdlePriority,PY=r.log,jY=r.unstable_setDisableYieldValue,xd=null,Vn=null;function os(h){if(typeof PY=="function"&&jY(h),Vn&&typeof Vn.setStrictMode=="function")try{Vn.setStrictMode(xd,h)}catch{}}var Gn=Math.clz32?Math.clz32:VY,zY=Math.log,BY=Math.LN2;function VY(h){return h>>>=0,h===0?32:31-(zY(h)/BY|0)|0}var im=256,om=4194304;function Il(h){var p=h&42;if(p!==0)return p;switch(h&-h){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return h&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return h&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return h}}function sm(h,p,m){var S=h.pendingLanes;if(S===0)return 0;var A=0,L=h.suspendedLanes,z=h.pingedLanes;h=h.warmLanes;var Y=S&134217727;return Y!==0?(S=Y&~L,S!==0?A=Il(S):(z&=Y,z!==0?A=Il(z):m||(m=Y&~h,m!==0&&(A=Il(m))))):(Y=S&~L,Y!==0?A=Il(Y):z!==0?A=Il(z):m||(m=S&~h,m!==0&&(A=Il(m)))),A===0?0:p!==0&&p!==A&&(p&L)===0&&(L=A&-A,m=p&-p,L>=m||L===32&&(m&4194048)!==0)?p:A}function bd(h,p){return(h.pendingLanes&~(h.suspendedLanes&~h.pingedLanes)&p)===0}function GY(h,p){switch(h){case 1:case 2:case 4:case 8:case 64:return p+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return p+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function EL(){var h=im;return im<<=1,(im&4194048)===0&&(im=256),h}function kL(){var h=om;return om<<=1,(om&62914560)===0&&(om=4194304),h}function Nb(h){for(var p=[],m=0;31>m;m++)p.push(h);return p}function _d(h,p){h.pendingLanes|=p,p!==268435456&&(h.suspendedLanes=0,h.pingedLanes=0,h.warmLanes=0)}function HY(h,p,m,S,A,L){var z=h.pendingLanes;h.pendingLanes=m,h.suspendedLanes=0,h.pingedLanes=0,h.warmLanes=0,h.expiredLanes&=m,h.entangledLanes&=m,h.errorRecoveryDisabledLanes&=m,h.shellSuspendCounter=0;var Y=h.entanglements,Z=h.expirationTimes,ae=h.hiddenUpdates;for(m=z&~m;0<m;){var he=31-Gn(m),ve=1<<he;Y[he]=0,Z[he]=-1;var se=ae[he];if(se!==null)for(ae[he]=null,he=0;he<se.length;he++){var le=se[he];le!==null&&(le.lane&=-536870913)}m&=~ve}S!==0&&IL(h,S,0),L!==0&&A===0&&h.tag!==0&&(h.suspendedLanes|=L&~(z&~p))}function IL(h,p,m){h.pendingLanes|=p,h.suspendedLanes&=~p;var S=31-Gn(p);h.entangledLanes|=p,h.entanglements[S]=h.entanglements[S]|1073741824|m&4194090}function OL(h,p){var m=h.entangledLanes|=p;for(h=h.entanglements;m;){var S=31-Gn(m),A=1<<S;A&p|h[S]&p&&(h[S]|=p),m&=~A}}function Lb(h){switch(h){case 2:h=1;break;case 8:h=4;break;case 32:h=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:h=128;break;case 268435456:h=134217728;break;default:h=0}return h}function Rb(h){return h&=-h,2<h?8<h?(h&134217727)!==0?32:268435456:8:2}function PL(){var h=U.p;return h!==0?h:(h=window.event,h===void 0?32:pI(h.type))}function FY(h,p){var m=U.p;try{return U.p=h,p()}finally{U.p=m}}var ss=Math.random().toString(36).slice(2),on="__reactFiber$"+ss,An="__reactProps$"+ss,Dc="__reactContainer$"+ss,Eb="__reactEvents$"+ss,UY="__reactListeners$"+ss,YY="__reactHandles$"+ss,jL="__reactResources$"+ss,Sd="__reactMarker$"+ss;function kb(h){delete h[on],delete h[An],delete h[Eb],delete h[UY],delete h[YY]}function Nc(h){var p=h[on];if(p)return p;for(var m=h.parentNode;m;){if(p=m[Dc]||m[on]){if(m=p.alternate,p.child!==null||m!==null&&m.child!==null)for(h=eI(h);h!==null;){if(m=h[on])return m;h=eI(h)}return p}h=m,m=h.parentNode}return null}function Lc(h){if(h=h[on]||h[Dc]){var p=h.tag;if(p===5||p===6||p===13||p===26||p===27||p===3)return h}return null}function wd(h){var p=h.tag;if(p===5||p===26||p===27||p===6)return h.stateNode;throw Error(n(33))}function Rc(h){var p=h[jL];return p||(p=h[jL]={hoistableStyles:new Map,hoistableScripts:new Map}),p}function Or(h){h[Sd]=!0}var zL=new Set,BL={};function Ol(h,p){Ec(h,p),Ec(h+"Capture",p)}function Ec(h,p){for(BL[h]=p,h=0;h<p.length;h++)zL.add(p[h])}var WY=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),VL={},GL={};function XY(h){return pe.call(GL,h)?!0:pe.call(VL,h)?!1:WY.test(h)?GL[h]=!0:(VL[h]=!0,!1)}function lm(h,p,m){if(XY(p))if(m===null)h.removeAttribute(p);else{switch(typeof m){case"undefined":case"function":case"symbol":h.removeAttribute(p);return;case"boolean":var S=p.toLowerCase().slice(0,5);if(S!=="data-"&&S!=="aria-"){h.removeAttribute(p);return}}h.setAttribute(p,""+m)}}function um(h,p,m){if(m===null)h.removeAttribute(p);else{switch(typeof m){case"undefined":case"function":case"symbol":case"boolean":h.removeAttribute(p);return}h.setAttribute(p,""+m)}}function ro(h,p,m,S){if(S===null)h.removeAttribute(m);else{switch(typeof S){case"undefined":case"function":case"symbol":case"boolean":h.removeAttribute(m);return}h.setAttributeNS(p,m,""+S)}}var Ib,HL;function kc(h){if(Ib===void 0)try{throw Error()}catch(m){var p=m.stack.trim().match(/\n( *(at )?)/);Ib=p&&p[1]||"",HL=-1<m.stack.indexOf(`
42
- at`)?" (<anonymous>)":-1<m.stack.indexOf("@")?"@unknown:0:0":""}return`
43
- `+Ib+h+HL}var Ob=!1;function Pb(h,p){if(!h||Ob)return"";Ob=!0;var m=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var S={DetermineComponentFrameRoot:function(){try{if(p){var ve=function(){throw Error()};if(Object.defineProperty(ve.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ve,[])}catch(le){var se=le}Reflect.construct(h,[],ve)}else{try{ve.call()}catch(le){se=le}h.call(ve.prototype)}}else{try{throw Error()}catch(le){se=le}(ve=h())&&typeof ve.catch=="function"&&ve.catch(function(){})}}catch(le){if(le&&se&&typeof le.stack=="string")return[le.stack,se.stack]}return[null,null]}};S.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var A=Object.getOwnPropertyDescriptor(S.DetermineComponentFrameRoot,"name");A&&A.configurable&&Object.defineProperty(S.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var L=S.DetermineComponentFrameRoot(),z=L[0],Y=L[1];if(z&&Y){var Z=z.split(`
44
- `),ae=Y.split(`
45
- `);for(A=S=0;S<Z.length&&!Z[S].includes("DetermineComponentFrameRoot");)S++;for(;A<ae.length&&!ae[A].includes("DetermineComponentFrameRoot");)A++;if(S===Z.length||A===ae.length)for(S=Z.length-1,A=ae.length-1;1<=S&&0<=A&&Z[S]!==ae[A];)A--;for(;1<=S&&0<=A;S--,A--)if(Z[S]!==ae[A]){if(S!==1||A!==1)do if(S--,A--,0>A||Z[S]!==ae[A]){var he=`
46
- `+Z[S].replace(" at new "," at ");return h.displayName&&he.includes("<anonymous>")&&(he=he.replace("<anonymous>",h.displayName)),he}while(1<=S&&0<=A);break}}}finally{Ob=!1,Error.prepareStackTrace=m}return(m=h?h.displayName||h.name:"")?kc(m):""}function qY(h){switch(h.tag){case 26:case 27:case 5:return kc(h.type);case 16:return kc("Lazy");case 13:return kc("Suspense");case 19:return kc("SuspenseList");case 0:case 15:return Pb(h.type,!1);case 11:return Pb(h.type.render,!1);case 1:return Pb(h.type,!0);case 31:return kc("Activity");default:return""}}function FL(h){try{var p="";do p+=qY(h),h=h.return;while(h);return p}catch(m){return`
47
- Error generating stack: `+m.message+`
48
- `+m.stack}}function ca(h){switch(typeof h){case"bigint":case"boolean":case"number":case"string":case"undefined":return h;case"object":return h;default:return""}}function UL(h){var p=h.type;return(h=h.nodeName)&&h.toLowerCase()==="input"&&(p==="checkbox"||p==="radio")}function ZY(h){var p=UL(h)?"checked":"value",m=Object.getOwnPropertyDescriptor(h.constructor.prototype,p),S=""+h[p];if(!h.hasOwnProperty(p)&&typeof m<"u"&&typeof m.get=="function"&&typeof m.set=="function"){var A=m.get,L=m.set;return Object.defineProperty(h,p,{configurable:!0,get:function(){return A.call(this)},set:function(z){S=""+z,L.call(this,z)}}),Object.defineProperty(h,p,{enumerable:m.enumerable}),{getValue:function(){return S},setValue:function(z){S=""+z},stopTracking:function(){h._valueTracker=null,delete h[p]}}}}function cm(h){h._valueTracker||(h._valueTracker=ZY(h))}function YL(h){if(!h)return!1;var p=h._valueTracker;if(!p)return!0;var m=p.getValue(),S="";return h&&(S=UL(h)?h.checked?"true":"false":h.value),h=S,h!==m?(p.setValue(h),!0):!1}function fm(h){if(h=h||(typeof document<"u"?document:void 0),typeof h>"u")return null;try{return h.activeElement||h.body}catch{return h.body}}var $Y=/[\n"\\]/g;function fa(h){return h.replace($Y,function(p){return"\\"+p.charCodeAt(0).toString(16)+" "})}function jb(h,p,m,S,A,L,z,Y){h.name="",z!=null&&typeof z!="function"&&typeof z!="symbol"&&typeof z!="boolean"?h.type=z:h.removeAttribute("type"),p!=null?z==="number"?(p===0&&h.value===""||h.value!=p)&&(h.value=""+ca(p)):h.value!==""+ca(p)&&(h.value=""+ca(p)):z!=="submit"&&z!=="reset"||h.removeAttribute("value"),p!=null?zb(h,z,ca(p)):m!=null?zb(h,z,ca(m)):S!=null&&h.removeAttribute("value"),A==null&&L!=null&&(h.defaultChecked=!!L),A!=null&&(h.checked=A&&typeof A!="function"&&typeof A!="symbol"),Y!=null&&typeof Y!="function"&&typeof Y!="symbol"&&typeof Y!="boolean"?h.name=""+ca(Y):h.removeAttribute("name")}function WL(h,p,m,S,A,L,z,Y){if(L!=null&&typeof L!="function"&&typeof L!="symbol"&&typeof L!="boolean"&&(h.type=L),p!=null||m!=null){if(!(L!=="submit"&&L!=="reset"||p!=null))return;m=m!=null?""+ca(m):"",p=p!=null?""+ca(p):m,Y||p===h.value||(h.value=p),h.defaultValue=p}S=S??A,S=typeof S!="function"&&typeof S!="symbol"&&!!S,h.checked=Y?h.checked:!!S,h.defaultChecked=!!S,z!=null&&typeof z!="function"&&typeof z!="symbol"&&typeof z!="boolean"&&(h.name=z)}function zb(h,p,m){p==="number"&&fm(h.ownerDocument)===h||h.defaultValue===""+m||(h.defaultValue=""+m)}function Ic(h,p,m,S){if(h=h.options,p){p={};for(var A=0;A<m.length;A++)p["$"+m[A]]=!0;for(m=0;m<h.length;m++)A=p.hasOwnProperty("$"+h[m].value),h[m].selected!==A&&(h[m].selected=A),A&&S&&(h[m].defaultSelected=!0)}else{for(m=""+ca(m),p=null,A=0;A<h.length;A++){if(h[A].value===m){h[A].selected=!0,S&&(h[A].defaultSelected=!0);return}p!==null||h[A].disabled||(p=h[A])}p!==null&&(p.selected=!0)}}function XL(h,p,m){if(p!=null&&(p=""+ca(p),p!==h.value&&(h.value=p),m==null)){h.defaultValue!==p&&(h.defaultValue=p);return}h.defaultValue=m!=null?""+ca(m):""}function qL(h,p,m,S){if(p==null){if(S!=null){if(m!=null)throw Error(n(92));if(V(S)){if(1<S.length)throw Error(n(93));S=S[0]}m=S}m==null&&(m=""),p=m}m=ca(p),h.defaultValue=m,S=h.textContent,S===m&&S!==""&&S!==null&&(h.value=S)}function Oc(h,p){if(p){var m=h.firstChild;if(m&&m===h.lastChild&&m.nodeType===3){m.nodeValue=p;return}}h.textContent=p}var KY=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function ZL(h,p,m){var S=p.indexOf("--")===0;m==null||typeof m=="boolean"||m===""?S?h.setProperty(p,""):p==="float"?h.cssFloat="":h[p]="":S?h.setProperty(p,m):typeof m!="number"||m===0||KY.has(p)?p==="float"?h.cssFloat=m:h[p]=(""+m).trim():h[p]=m+"px"}function $L(h,p,m){if(p!=null&&typeof p!="object")throw Error(n(62));if(h=h.style,m!=null){for(var S in m)!m.hasOwnProperty(S)||p!=null&&p.hasOwnProperty(S)||(S.indexOf("--")===0?h.setProperty(S,""):S==="float"?h.cssFloat="":h[S]="");for(var A in p)S=p[A],p.hasOwnProperty(A)&&m[A]!==S&&ZL(h,A,S)}else for(var L in p)p.hasOwnProperty(L)&&ZL(h,L,p[L])}function Bb(h){if(h.indexOf("-")===-1)return!1;switch(h){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var QY=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),JY=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function hm(h){return JY.test(""+h)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":h}var Vb=null;function Gb(h){return h=h.target||h.srcElement||window,h.correspondingUseElement&&(h=h.correspondingUseElement),h.nodeType===3?h.parentNode:h}var Pc=null,jc=null;function KL(h){var p=Lc(h);if(p&&(h=p.stateNode)){var m=h[An]||null;e:switch(h=p.stateNode,p.type){case"input":if(jb(h,m.value,m.defaultValue,m.defaultValue,m.checked,m.defaultChecked,m.type,m.name),p=m.name,m.type==="radio"&&p!=null){for(m=h;m.parentNode;)m=m.parentNode;for(m=m.querySelectorAll('input[name="'+fa(""+p)+'"][type="radio"]'),p=0;p<m.length;p++){var S=m[p];if(S!==h&&S.form===h.form){var A=S[An]||null;if(!A)throw Error(n(90));jb(S,A.value,A.defaultValue,A.defaultValue,A.checked,A.defaultChecked,A.type,A.name)}}for(p=0;p<m.length;p++)S=m[p],S.form===h.form&&YL(S)}break e;case"textarea":XL(h,m.value,m.defaultValue);break e;case"select":p=m.value,p!=null&&Ic(h,!!m.multiple,p,!1)}}}var Hb=!1;function QL(h,p,m){if(Hb)return h(p,m);Hb=!0;try{var S=h(p);return S}finally{if(Hb=!1,(Pc!==null||jc!==null)&&(Km(),Pc&&(p=Pc,h=jc,jc=Pc=null,KL(p),h)))for(p=0;p<h.length;p++)KL(h[p])}}function Td(h,p){var m=h.stateNode;if(m===null)return null;var S=m[An]||null;if(S===null)return null;m=S[p];e:switch(p){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(S=!S.disabled)||(h=h.type,S=!(h==="button"||h==="input"||h==="select"||h==="textarea")),h=!S;break e;default:h=!1}if(h)return null;if(m&&typeof m!="function")throw Error(n(231,p,typeof m));return m}var no=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Fb=!1;if(no)try{var Cd={};Object.defineProperty(Cd,"passive",{get:function(){Fb=!0}}),window.addEventListener("test",Cd,Cd),window.removeEventListener("test",Cd,Cd)}catch{Fb=!1}var ls=null,Ub=null,dm=null;function JL(){if(dm)return dm;var h,p=Ub,m=p.length,S,A="value"in ls?ls.value:ls.textContent,L=A.length;for(h=0;h<m&&p[h]===A[h];h++);var z=m-h;for(S=1;S<=z&&p[m-S]===A[L-S];S++);return dm=A.slice(h,1<S?1-S:void 0)}function vm(h){var p=h.keyCode;return"charCode"in h?(h=h.charCode,h===0&&p===13&&(h=13)):h=p,h===10&&(h=13),32<=h||h===13?h:0}function pm(){return!0}function eR(){return!1}function Mn(h){function p(m,S,A,L,z){this._reactName=m,this._targetInst=A,this.type=S,this.nativeEvent=L,this.target=z,this.currentTarget=null;for(var Y in h)h.hasOwnProperty(Y)&&(m=h[Y],this[Y]=m?m(L):L[Y]);return this.isDefaultPrevented=(L.defaultPrevented!=null?L.defaultPrevented:L.returnValue===!1)?pm:eR,this.isPropagationStopped=eR,this}return c(p.prototype,{preventDefault:function(){this.defaultPrevented=!0;var m=this.nativeEvent;m&&(m.preventDefault?m.preventDefault():typeof m.returnValue!="unknown"&&(m.returnValue=!1),this.isDefaultPrevented=pm)},stopPropagation:function(){var m=this.nativeEvent;m&&(m.stopPropagation?m.stopPropagation():typeof m.cancelBubble!="unknown"&&(m.cancelBubble=!0),this.isPropagationStopped=pm)},persist:function(){},isPersistent:pm}),p}var Pl={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(h){return h.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},gm=Mn(Pl),Ad=c({},Pl,{view:0,detail:0}),eW=Mn(Ad),Yb,Wb,Md,mm=c({},Ad,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:qb,button:0,buttons:0,relatedTarget:function(h){return h.relatedTarget===void 0?h.fromElement===h.srcElement?h.toElement:h.fromElement:h.relatedTarget},movementX:function(h){return"movementX"in h?h.movementX:(h!==Md&&(Md&&h.type==="mousemove"?(Yb=h.screenX-Md.screenX,Wb=h.screenY-Md.screenY):Wb=Yb=0,Md=h),Yb)},movementY:function(h){return"movementY"in h?h.movementY:Wb}}),tR=Mn(mm),tW=c({},mm,{dataTransfer:0}),rW=Mn(tW),nW=c({},Ad,{relatedTarget:0}),Xb=Mn(nW),aW=c({},Pl,{animationName:0,elapsedTime:0,pseudoElement:0}),iW=Mn(aW),oW=c({},Pl,{clipboardData:function(h){return"clipboardData"in h?h.clipboardData:window.clipboardData}}),sW=Mn(oW),lW=c({},Pl,{data:0}),rR=Mn(lW),uW={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},cW={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},fW={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function hW(h){var p=this.nativeEvent;return p.getModifierState?p.getModifierState(h):(h=fW[h])?!!p[h]:!1}function qb(){return hW}var dW=c({},Ad,{key:function(h){if(h.key){var p=uW[h.key]||h.key;if(p!=="Unidentified")return p}return h.type==="keypress"?(h=vm(h),h===13?"Enter":String.fromCharCode(h)):h.type==="keydown"||h.type==="keyup"?cW[h.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:qb,charCode:function(h){return h.type==="keypress"?vm(h):0},keyCode:function(h){return h.type==="keydown"||h.type==="keyup"?h.keyCode:0},which:function(h){return h.type==="keypress"?vm(h):h.type==="keydown"||h.type==="keyup"?h.keyCode:0}}),vW=Mn(dW),pW=c({},mm,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),nR=Mn(pW),gW=c({},Ad,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:qb}),mW=Mn(gW),yW=c({},Pl,{propertyName:0,elapsedTime:0,pseudoElement:0}),xW=Mn(yW),bW=c({},mm,{deltaX:function(h){return"deltaX"in h?h.deltaX:"wheelDeltaX"in h?-h.wheelDeltaX:0},deltaY:function(h){return"deltaY"in h?h.deltaY:"wheelDeltaY"in h?-h.wheelDeltaY:"wheelDelta"in h?-h.wheelDelta:0},deltaZ:0,deltaMode:0}),_W=Mn(bW),SW=c({},Pl,{newState:0,oldState:0}),wW=Mn(SW),TW=[9,13,27,32],Zb=no&&"CompositionEvent"in window,Dd=null;no&&"documentMode"in document&&(Dd=document.documentMode);var CW=no&&"TextEvent"in window&&!Dd,aR=no&&(!Zb||Dd&&8<Dd&&11>=Dd),iR=" ",oR=!1;function sR(h,p){switch(h){case"keyup":return TW.indexOf(p.keyCode)!==-1;case"keydown":return p.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function lR(h){return h=h.detail,typeof h=="object"&&"data"in h?h.data:null}var zc=!1;function AW(h,p){switch(h){case"compositionend":return lR(p);case"keypress":return p.which!==32?null:(oR=!0,iR);case"textInput":return h=p.data,h===iR&&oR?null:h;default:return null}}function MW(h,p){if(zc)return h==="compositionend"||!Zb&&sR(h,p)?(h=JL(),dm=Ub=ls=null,zc=!1,h):null;switch(h){case"paste":return null;case"keypress":if(!(p.ctrlKey||p.altKey||p.metaKey)||p.ctrlKey&&p.altKey){if(p.char&&1<p.char.length)return p.char;if(p.which)return String.fromCharCode(p.which)}return null;case"compositionend":return aR&&p.locale!=="ko"?null:p.data;default:return null}}var DW={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function uR(h){var p=h&&h.nodeName&&h.nodeName.toLowerCase();return p==="input"?!!DW[h.type]:p==="textarea"}function cR(h,p,m,S){Pc?jc?jc.push(S):jc=[S]:Pc=S,p=ny(p,"onChange"),0<p.length&&(m=new gm("onChange","change",null,m,S),h.push({event:m,listeners:p}))}var Nd=null,Ld=null;function NW(h){Uk(h,0)}function ym(h){var p=wd(h);if(YL(p))return h}function fR(h,p){if(h==="change")return p}var hR=!1;if(no){var $b;if(no){var Kb="oninput"in document;if(!Kb){var dR=document.createElement("div");dR.setAttribute("oninput","return;"),Kb=typeof dR.oninput=="function"}$b=Kb}else $b=!1;hR=$b&&(!document.documentMode||9<document.documentMode)}function vR(){Nd&&(Nd.detachEvent("onpropertychange",pR),Ld=Nd=null)}function pR(h){if(h.propertyName==="value"&&ym(Ld)){var p=[];cR(p,Ld,h,Gb(h)),QL(NW,p)}}function LW(h,p,m){h==="focusin"?(vR(),Nd=p,Ld=m,Nd.attachEvent("onpropertychange",pR)):h==="focusout"&&vR()}function RW(h){if(h==="selectionchange"||h==="keyup"||h==="keydown")return ym(Ld)}function EW(h,p){if(h==="click")return ym(p)}function kW(h,p){if(h==="input"||h==="change")return ym(p)}function IW(h,p){return h===p&&(h!==0||1/h===1/p)||h!==h&&p!==p}var Hn=typeof Object.is=="function"?Object.is:IW;function Rd(h,p){if(Hn(h,p))return!0;if(typeof h!="object"||h===null||typeof p!="object"||p===null)return!1;var m=Object.keys(h),S=Object.keys(p);if(m.length!==S.length)return!1;for(S=0;S<m.length;S++){var A=m[S];if(!pe.call(p,A)||!Hn(h[A],p[A]))return!1}return!0}function gR(h){for(;h&&h.firstChild;)h=h.firstChild;return h}function mR(h,p){var m=gR(h);h=0;for(var S;m;){if(m.nodeType===3){if(S=h+m.textContent.length,h<=p&&S>=p)return{node:m,offset:p-h};h=S}e:{for(;m;){if(m.nextSibling){m=m.nextSibling;break e}m=m.parentNode}m=void 0}m=gR(m)}}function yR(h,p){return h&&p?h===p?!0:h&&h.nodeType===3?!1:p&&p.nodeType===3?yR(h,p.parentNode):"contains"in h?h.contains(p):h.compareDocumentPosition?!!(h.compareDocumentPosition(p)&16):!1:!1}function xR(h){h=h!=null&&h.ownerDocument!=null&&h.ownerDocument.defaultView!=null?h.ownerDocument.defaultView:window;for(var p=fm(h.document);p instanceof h.HTMLIFrameElement;){try{var m=typeof p.contentWindow.location.href=="string"}catch{m=!1}if(m)h=p.contentWindow;else break;p=fm(h.document)}return p}function Qb(h){var p=h&&h.nodeName&&h.nodeName.toLowerCase();return p&&(p==="input"&&(h.type==="text"||h.type==="search"||h.type==="tel"||h.type==="url"||h.type==="password")||p==="textarea"||h.contentEditable==="true")}var OW=no&&"documentMode"in document&&11>=document.documentMode,Bc=null,Jb=null,Ed=null,e_=!1;function bR(h,p,m){var S=m.window===m?m.document:m.nodeType===9?m:m.ownerDocument;e_||Bc==null||Bc!==fm(S)||(S=Bc,"selectionStart"in S&&Qb(S)?S={start:S.selectionStart,end:S.selectionEnd}:(S=(S.ownerDocument&&S.ownerDocument.defaultView||window).getSelection(),S={anchorNode:S.anchorNode,anchorOffset:S.anchorOffset,focusNode:S.focusNode,focusOffset:S.focusOffset}),Ed&&Rd(Ed,S)||(Ed=S,S=ny(Jb,"onSelect"),0<S.length&&(p=new gm("onSelect","select",null,p,m),h.push({event:p,listeners:S}),p.target=Bc)))}function jl(h,p){var m={};return m[h.toLowerCase()]=p.toLowerCase(),m["Webkit"+h]="webkit"+p,m["Moz"+h]="moz"+p,m}var Vc={animationend:jl("Animation","AnimationEnd"),animationiteration:jl("Animation","AnimationIteration"),animationstart:jl("Animation","AnimationStart"),transitionrun:jl("Transition","TransitionRun"),transitionstart:jl("Transition","TransitionStart"),transitioncancel:jl("Transition","TransitionCancel"),transitionend:jl("Transition","TransitionEnd")},t_={},_R={};no&&(_R=document.createElement("div").style,"AnimationEvent"in window||(delete Vc.animationend.animation,delete Vc.animationiteration.animation,delete Vc.animationstart.animation),"TransitionEvent"in window||delete Vc.transitionend.transition);function zl(h){if(t_[h])return t_[h];if(!Vc[h])return h;var p=Vc[h],m;for(m in p)if(p.hasOwnProperty(m)&&m in _R)return t_[h]=p[m];return h}var SR=zl("animationend"),wR=zl("animationiteration"),TR=zl("animationstart"),PW=zl("transitionrun"),jW=zl("transitionstart"),zW=zl("transitioncancel"),CR=zl("transitionend"),AR=new Map,r_="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");r_.push("scrollEnd");function Ha(h,p){AR.set(h,p),Ol(p,[h])}var MR=new WeakMap;function ha(h,p){if(typeof h=="object"&&h!==null){var m=MR.get(h);return m!==void 0?m:(p={value:h,source:p,stack:FL(p)},MR.set(h,p),p)}return{value:h,source:p,stack:FL(p)}}var da=[],Gc=0,n_=0;function xm(){for(var h=Gc,p=n_=Gc=0;p<h;){var m=da[p];da[p++]=null;var S=da[p];da[p++]=null;var A=da[p];da[p++]=null;var L=da[p];if(da[p++]=null,S!==null&&A!==null){var z=S.pending;z===null?A.next=A:(A.next=z.next,z.next=A),S.pending=A}L!==0&&DR(m,A,L)}}function bm(h,p,m,S){da[Gc++]=h,da[Gc++]=p,da[Gc++]=m,da[Gc++]=S,n_|=S,h.lanes|=S,h=h.alternate,h!==null&&(h.lanes|=S)}function a_(h,p,m,S){return bm(h,p,m,S),_m(h)}function Hc(h,p){return bm(h,null,null,p),_m(h)}function DR(h,p,m){h.lanes|=m;var S=h.alternate;S!==null&&(S.lanes|=m);for(var A=!1,L=h.return;L!==null;)L.childLanes|=m,S=L.alternate,S!==null&&(S.childLanes|=m),L.tag===22&&(h=L.stateNode,h===null||h._visibility&1||(A=!0)),h=L,L=L.return;return h.tag===3?(L=h.stateNode,A&&p!==null&&(A=31-Gn(m),h=L.hiddenUpdates,S=h[A],S===null?h[A]=[p]:S.push(p),p.lane=m|536870912),L):null}function _m(h){if(50<nv)throw nv=0,cS=null,Error(n(185));for(var p=h.return;p!==null;)h=p,p=h.return;return h.tag===3?h.stateNode:null}var Fc={};function BW(h,p,m,S){this.tag=h,this.key=m,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=p,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=S,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Fn(h,p,m,S){return new BW(h,p,m,S)}function i_(h){return h=h.prototype,!(!h||!h.isReactComponent)}function ao(h,p){var m=h.alternate;return m===null?(m=Fn(h.tag,p,h.key,h.mode),m.elementType=h.elementType,m.type=h.type,m.stateNode=h.stateNode,m.alternate=h,h.alternate=m):(m.pendingProps=p,m.type=h.type,m.flags=0,m.subtreeFlags=0,m.deletions=null),m.flags=h.flags&65011712,m.childLanes=h.childLanes,m.lanes=h.lanes,m.child=h.child,m.memoizedProps=h.memoizedProps,m.memoizedState=h.memoizedState,m.updateQueue=h.updateQueue,p=h.dependencies,m.dependencies=p===null?null:{lanes:p.lanes,firstContext:p.firstContext},m.sibling=h.sibling,m.index=h.index,m.ref=h.ref,m.refCleanup=h.refCleanup,m}function NR(h,p){h.flags&=65011714;var m=h.alternate;return m===null?(h.childLanes=0,h.lanes=p,h.child=null,h.subtreeFlags=0,h.memoizedProps=null,h.memoizedState=null,h.updateQueue=null,h.dependencies=null,h.stateNode=null):(h.childLanes=m.childLanes,h.lanes=m.lanes,h.child=m.child,h.subtreeFlags=0,h.deletions=null,h.memoizedProps=m.memoizedProps,h.memoizedState=m.memoizedState,h.updateQueue=m.updateQueue,h.type=m.type,p=m.dependencies,h.dependencies=p===null?null:{lanes:p.lanes,firstContext:p.firstContext}),h}function Sm(h,p,m,S,A,L){var z=0;if(S=h,typeof h=="function")i_(h)&&(z=1);else if(typeof h=="string")z=GX(h,m,ue.current)?26:h==="html"||h==="head"||h==="body"?27:5;else e:switch(h){case E:return h=Fn(31,m,p,A),h.elementType=E,h.lanes=L,h;case g:return Bl(m.children,A,L,p);case y:z=8,A|=24;break;case x:return h=Fn(12,m,p,A|2),h.elementType=x,h.lanes=L,h;case D:return h=Fn(13,m,p,A),h.elementType=D,h.lanes=L,h;case M:return h=Fn(19,m,p,A),h.elementType=M,h.lanes=L,h;default:if(typeof h=="object"&&h!==null)switch(h.$$typeof){case b:case T:z=10;break e;case w:z=9;break e;case C:z=11;break e;case N:z=14;break e;case R:z=16,S=null;break e}z=29,m=Error(n(130,h===null?"null":typeof h,"")),S=null}return p=Fn(z,m,p,A),p.elementType=h,p.type=S,p.lanes=L,p}function Bl(h,p,m,S){return h=Fn(7,h,S,p),h.lanes=m,h}function o_(h,p,m){return h=Fn(6,h,null,p),h.lanes=m,h}function s_(h,p,m){return p=Fn(4,h.children!==null?h.children:[],h.key,p),p.lanes=m,p.stateNode={containerInfo:h.containerInfo,pendingChildren:null,implementation:h.implementation},p}var Uc=[],Yc=0,wm=null,Tm=0,va=[],pa=0,Vl=null,io=1,oo="";function Gl(h,p){Uc[Yc++]=Tm,Uc[Yc++]=wm,wm=h,Tm=p}function LR(h,p,m){va[pa++]=io,va[pa++]=oo,va[pa++]=Vl,Vl=h;var S=io;h=oo;var A=32-Gn(S)-1;S&=~(1<<A),m+=1;var L=32-Gn(p)+A;if(30<L){var z=A-A%5;L=(S&(1<<z)-1).toString(32),S>>=z,A-=z,io=1<<32-Gn(p)+A|m<<A|S,oo=L+h}else io=1<<L|m<<A|S,oo=h}function l_(h){h.return!==null&&(Gl(h,1),LR(h,1,0))}function u_(h){for(;h===wm;)wm=Uc[--Yc],Uc[Yc]=null,Tm=Uc[--Yc],Uc[Yc]=null;for(;h===Vl;)Vl=va[--pa],va[pa]=null,oo=va[--pa],va[pa]=null,io=va[--pa],va[pa]=null}var gn=null,tr=null,Dt=!1,Hl=null,fi=!1,c_=Error(n(519));function Fl(h){var p=Error(n(418,""));throw Od(ha(p,h)),c_}function RR(h){var p=h.stateNode,m=h.type,S=h.memoizedProps;switch(p[on]=h,p[An]=S,m){case"dialog":yt("cancel",p),yt("close",p);break;case"iframe":case"object":case"embed":yt("load",p);break;case"video":case"audio":for(m=0;m<iv.length;m++)yt(iv[m],p);break;case"source":yt("error",p);break;case"img":case"image":case"link":yt("error",p),yt("load",p);break;case"details":yt("toggle",p);break;case"input":yt("invalid",p),WL(p,S.value,S.defaultValue,S.checked,S.defaultChecked,S.type,S.name,!0),cm(p);break;case"select":yt("invalid",p);break;case"textarea":yt("invalid",p),qL(p,S.value,S.defaultValue,S.children),cm(p)}m=S.children,typeof m!="string"&&typeof m!="number"&&typeof m!="bigint"||p.textContent===""+m||S.suppressHydrationWarning===!0||qk(p.textContent,m)?(S.popover!=null&&(yt("beforetoggle",p),yt("toggle",p)),S.onScroll!=null&&yt("scroll",p),S.onScrollEnd!=null&&yt("scrollend",p),S.onClick!=null&&(p.onclick=ay),p=!0):p=!1,p||Fl(h)}function ER(h){for(gn=h.return;gn;)switch(gn.tag){case 5:case 13:fi=!1;return;case 27:case 3:fi=!0;return;default:gn=gn.return}}function kd(h){if(h!==gn)return!1;if(!Dt)return ER(h),Dt=!0,!1;var p=h.tag,m;if((m=p!==3&&p!==27)&&((m=p===5)&&(m=h.type,m=!(m!=="form"&&m!=="button")||AS(h.type,h.memoizedProps)),m=!m),m&&tr&&Fl(h),ER(h),p===13){if(h=h.memoizedState,h=h!==null?h.dehydrated:null,!h)throw Error(n(317));e:{for(h=h.nextSibling,p=0;h;){if(h.nodeType===8)if(m=h.data,m==="/$"){if(p===0){tr=Ua(h.nextSibling);break e}p--}else m!=="$"&&m!=="$!"&&m!=="$?"||p++;h=h.nextSibling}tr=null}}else p===27?(p=tr,Ts(h.type)?(h=LS,LS=null,tr=h):tr=p):tr=gn?Ua(h.stateNode.nextSibling):null;return!0}function Id(){tr=gn=null,Dt=!1}function kR(){var h=Hl;return h!==null&&(Ln===null?Ln=h:Ln.push.apply(Ln,h),Hl=null),h}function Od(h){Hl===null?Hl=[h]:Hl.push(h)}var f_=W(null),Ul=null,so=null;function us(h,p,m){te(f_,p._currentValue),p._currentValue=m}function lo(h){h._currentValue=f_.current,$(f_)}function h_(h,p,m){for(;h!==null;){var S=h.alternate;if((h.childLanes&p)!==p?(h.childLanes|=p,S!==null&&(S.childLanes|=p)):S!==null&&(S.childLanes&p)!==p&&(S.childLanes|=p),h===m)break;h=h.return}}function d_(h,p,m,S){var A=h.child;for(A!==null&&(A.return=h);A!==null;){var L=A.dependencies;if(L!==null){var z=A.child;L=L.firstContext;e:for(;L!==null;){var Y=L;L=A;for(var Z=0;Z<p.length;Z++)if(Y.context===p[Z]){L.lanes|=m,Y=L.alternate,Y!==null&&(Y.lanes|=m),h_(L.return,m,h),S||(z=null);break e}L=Y.next}}else if(A.tag===18){if(z=A.return,z===null)throw Error(n(341));z.lanes|=m,L=z.alternate,L!==null&&(L.lanes|=m),h_(z,m,h),z=null}else z=A.child;if(z!==null)z.return=A;else for(z=A;z!==null;){if(z===h){z=null;break}if(A=z.sibling,A!==null){A.return=z.return,z=A;break}z=z.return}A=z}}function Pd(h,p,m,S){h=null;for(var A=p,L=!1;A!==null;){if(!L){if((A.flags&524288)!==0)L=!0;else if((A.flags&262144)!==0)break}if(A.tag===10){var z=A.alternate;if(z===null)throw Error(n(387));if(z=z.memoizedProps,z!==null){var Y=A.type;Hn(A.pendingProps.value,z.value)||(h!==null?h.push(Y):h=[Y])}}else if(A===Xe.current){if(z=A.alternate,z===null)throw Error(n(387));z.memoizedState.memoizedState!==A.memoizedState.memoizedState&&(h!==null?h.push(fv):h=[fv])}A=A.return}h!==null&&d_(p,h,m,S),p.flags|=262144}function Cm(h){for(h=h.firstContext;h!==null;){if(!Hn(h.context._currentValue,h.memoizedValue))return!0;h=h.next}return!1}function Yl(h){Ul=h,so=null,h=h.dependencies,h!==null&&(h.firstContext=null)}function sn(h){return IR(Ul,h)}function Am(h,p){return Ul===null&&Yl(h),IR(h,p)}function IR(h,p){var m=p._currentValue;if(p={context:p,memoizedValue:m,next:null},so===null){if(h===null)throw Error(n(308));so=p,h.dependencies={lanes:0,firstContext:p},h.flags|=524288}else so=so.next=p;return m}var VW=typeof AbortController<"u"?AbortController:function(){var h=[],p=this.signal={aborted:!1,addEventListener:function(m,S){h.push(S)}};this.abort=function(){p.aborted=!0,h.forEach(function(m){return m()})}},GW=r.unstable_scheduleCallback,HW=r.unstable_NormalPriority,Ar={$$typeof:T,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function v_(){return{controller:new VW,data:new Map,refCount:0}}function jd(h){h.refCount--,h.refCount===0&&GW(HW,function(){h.controller.abort()})}var zd=null,p_=0,Wc=0,Xc=null;function FW(h,p){if(zd===null){var m=zd=[];p_=0,Wc=mS(),Xc={status:"pending",value:void 0,then:function(S){m.push(S)}}}return p_++,p.then(OR,OR),p}function OR(){if(--p_===0&&zd!==null){Xc!==null&&(Xc.status="fulfilled");var h=zd;zd=null,Wc=0,Xc=null;for(var p=0;p<h.length;p++)(0,h[p])()}}function UW(h,p){var m=[],S={status:"pending",value:null,reason:null,then:function(A){m.push(A)}};return h.then(function(){S.status="fulfilled",S.value=p;for(var A=0;A<m.length;A++)(0,m[A])(p)},function(A){for(S.status="rejected",S.reason=A,A=0;A<m.length;A++)(0,m[A])(void 0)}),S}var PR=j.S;j.S=function(h,p){typeof p=="object"&&p!==null&&typeof p.then=="function"&&FW(h,p),PR!==null&&PR(h,p)};var Wl=W(null);function g_(){var h=Wl.current;return h!==null?h:Yt.pooledCache}function Mm(h,p){p===null?te(Wl,Wl.current):te(Wl,p.pool)}function jR(){var h=g_();return h===null?null:{parent:Ar._currentValue,pool:h}}var Bd=Error(n(460)),zR=Error(n(474)),Dm=Error(n(542)),m_={then:function(){}};function BR(h){return h=h.status,h==="fulfilled"||h==="rejected"}function Nm(){}function VR(h,p,m){switch(m=h[m],m===void 0?h.push(p):m!==p&&(p.then(Nm,Nm),p=m),p.status){case"fulfilled":return p.value;case"rejected":throw h=p.reason,HR(h),h;default:if(typeof p.status=="string")p.then(Nm,Nm);else{if(h=Yt,h!==null&&100<h.shellSuspendCounter)throw Error(n(482));h=p,h.status="pending",h.then(function(S){if(p.status==="pending"){var A=p;A.status="fulfilled",A.value=S}},function(S){if(p.status==="pending"){var A=p;A.status="rejected",A.reason=S}})}switch(p.status){case"fulfilled":return p.value;case"rejected":throw h=p.reason,HR(h),h}throw Vd=p,Bd}}var Vd=null;function GR(){if(Vd===null)throw Error(n(459));var h=Vd;return Vd=null,h}function HR(h){if(h===Bd||h===Dm)throw Error(n(483))}var cs=!1;function y_(h){h.updateQueue={baseState:h.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function x_(h,p){h=h.updateQueue,p.updateQueue===h&&(p.updateQueue={baseState:h.baseState,firstBaseUpdate:h.firstBaseUpdate,lastBaseUpdate:h.lastBaseUpdate,shared:h.shared,callbacks:null})}function fs(h){return{lane:h,tag:0,payload:null,callback:null,next:null}}function hs(h,p,m){var S=h.updateQueue;if(S===null)return null;if(S=S.shared,(It&2)!==0){var A=S.pending;return A===null?p.next=p:(p.next=A.next,A.next=p),S.pending=p,p=_m(h),DR(h,null,m),p}return bm(h,S,p,m),_m(h)}function Gd(h,p,m){if(p=p.updateQueue,p!==null&&(p=p.shared,(m&4194048)!==0)){var S=p.lanes;S&=h.pendingLanes,m|=S,p.lanes=m,OL(h,m)}}function b_(h,p){var m=h.updateQueue,S=h.alternate;if(S!==null&&(S=S.updateQueue,m===S)){var A=null,L=null;if(m=m.firstBaseUpdate,m!==null){do{var z={lane:m.lane,tag:m.tag,payload:m.payload,callback:null,next:null};L===null?A=L=z:L=L.next=z,m=m.next}while(m!==null);L===null?A=L=p:L=L.next=p}else A=L=p;m={baseState:S.baseState,firstBaseUpdate:A,lastBaseUpdate:L,shared:S.shared,callbacks:S.callbacks},h.updateQueue=m;return}h=m.lastBaseUpdate,h===null?m.firstBaseUpdate=p:h.next=p,m.lastBaseUpdate=p}var __=!1;function Hd(){if(__){var h=Xc;if(h!==null)throw h}}function Fd(h,p,m,S){__=!1;var A=h.updateQueue;cs=!1;var L=A.firstBaseUpdate,z=A.lastBaseUpdate,Y=A.shared.pending;if(Y!==null){A.shared.pending=null;var Z=Y,ae=Z.next;Z.next=null,z===null?L=ae:z.next=ae,z=Z;var he=h.alternate;he!==null&&(he=he.updateQueue,Y=he.lastBaseUpdate,Y!==z&&(Y===null?he.firstBaseUpdate=ae:Y.next=ae,he.lastBaseUpdate=Z))}if(L!==null){var ve=A.baseState;z=0,he=ae=Z=null,Y=L;do{var se=Y.lane&-536870913,le=se!==Y.lane;if(le?(wt&se)===se:(S&se)===se){se!==0&&se===Wc&&(__=!0),he!==null&&(he=he.next={lane:0,tag:Y.tag,payload:Y.payload,callback:null,next:null});e:{var rt=h,Ze=Y;se=p;var Gt=m;switch(Ze.tag){case 1:if(rt=Ze.payload,typeof rt=="function"){ve=rt.call(Gt,ve,se);break e}ve=rt;break e;case 3:rt.flags=rt.flags&-65537|128;case 0:if(rt=Ze.payload,se=typeof rt=="function"?rt.call(Gt,ve,se):rt,se==null)break e;ve=c({},ve,se);break e;case 2:cs=!0}}se=Y.callback,se!==null&&(h.flags|=64,le&&(h.flags|=8192),le=A.callbacks,le===null?A.callbacks=[se]:le.push(se))}else le={lane:se,tag:Y.tag,payload:Y.payload,callback:Y.callback,next:null},he===null?(ae=he=le,Z=ve):he=he.next=le,z|=se;if(Y=Y.next,Y===null){if(Y=A.shared.pending,Y===null)break;le=Y,Y=le.next,le.next=null,A.lastBaseUpdate=le,A.shared.pending=null}}while(!0);he===null&&(Z=ve),A.baseState=Z,A.firstBaseUpdate=ae,A.lastBaseUpdate=he,L===null&&(A.shared.lanes=0),bs|=z,h.lanes=z,h.memoizedState=ve}}function FR(h,p){if(typeof h!="function")throw Error(n(191,h));h.call(p)}function UR(h,p){var m=h.callbacks;if(m!==null)for(h.callbacks=null,h=0;h<m.length;h++)FR(m[h],p)}var qc=W(null),Lm=W(0);function YR(h,p){h=go,te(Lm,h),te(qc,p),go=h|p.baseLanes}function S_(){te(Lm,go),te(qc,qc.current)}function w_(){go=Lm.current,$(qc),$(Lm)}var ds=0,ht=null,Bt=null,gr=null,Rm=!1,Zc=!1,Xl=!1,Em=0,Ud=0,$c=null,YW=0;function cr(){throw Error(n(321))}function T_(h,p){if(p===null)return!1;for(var m=0;m<p.length&&m<h.length;m++)if(!Hn(h[m],p[m]))return!1;return!0}function C_(h,p,m,S,A,L){return ds=L,ht=p,p.memoizedState=null,p.updateQueue=null,p.lanes=0,j.H=h===null||h.memoizedState===null?DE:NE,Xl=!1,L=m(S,A),Xl=!1,Zc&&(L=XR(p,m,S,A)),WR(h),L}function WR(h){j.H=zm;var p=Bt!==null&&Bt.next!==null;if(ds=0,gr=Bt=ht=null,Rm=!1,Ud=0,$c=null,p)throw Error(n(300));h===null||Pr||(h=h.dependencies,h!==null&&Cm(h)&&(Pr=!0))}function XR(h,p,m,S){ht=h;var A=0;do{if(Zc&&($c=null),Ud=0,Zc=!1,25<=A)throw Error(n(301));if(A+=1,gr=Bt=null,h.updateQueue!=null){var L=h.updateQueue;L.lastEffect=null,L.events=null,L.stores=null,L.memoCache!=null&&(L.memoCache.index=0)}j.H=QW,L=p(m,S)}while(Zc);return L}function WW(){var h=j.H,p=h.useState()[0];return p=typeof p.then=="function"?Yd(p):p,h=h.useState()[0],(Bt!==null?Bt.memoizedState:null)!==h&&(ht.flags|=1024),p}function A_(){var h=Em!==0;return Em=0,h}function M_(h,p,m){p.updateQueue=h.updateQueue,p.flags&=-2053,h.lanes&=~m}function D_(h){if(Rm){for(h=h.memoizedState;h!==null;){var p=h.queue;p!==null&&(p.pending=null),h=h.next}Rm=!1}ds=0,gr=Bt=ht=null,Zc=!1,Ud=Em=0,$c=null}function Dn(){var h={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return gr===null?ht.memoizedState=gr=h:gr=gr.next=h,gr}function mr(){if(Bt===null){var h=ht.alternate;h=h!==null?h.memoizedState:null}else h=Bt.next;var p=gr===null?ht.memoizedState:gr.next;if(p!==null)gr=p,Bt=h;else{if(h===null)throw ht.alternate===null?Error(n(467)):Error(n(310));Bt=h,h={memoizedState:Bt.memoizedState,baseState:Bt.baseState,baseQueue:Bt.baseQueue,queue:Bt.queue,next:null},gr===null?ht.memoizedState=gr=h:gr=gr.next=h}return gr}function N_(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Yd(h){var p=Ud;return Ud+=1,$c===null&&($c=[]),h=VR($c,h,p),p=ht,(gr===null?p.memoizedState:gr.next)===null&&(p=p.alternate,j.H=p===null||p.memoizedState===null?DE:NE),h}function km(h){if(h!==null&&typeof h=="object"){if(typeof h.then=="function")return Yd(h);if(h.$$typeof===T)return sn(h)}throw Error(n(438,String(h)))}function L_(h){var p=null,m=ht.updateQueue;if(m!==null&&(p=m.memoCache),p==null){var S=ht.alternate;S!==null&&(S=S.updateQueue,S!==null&&(S=S.memoCache,S!=null&&(p={data:S.data.map(function(A){return A.slice()}),index:0})))}if(p==null&&(p={data:[],index:0}),m===null&&(m=N_(),ht.updateQueue=m),m.memoCache=p,m=p.data[p.index],m===void 0)for(m=p.data[p.index]=Array(h),S=0;S<h;S++)m[S]=k;return p.index++,m}function uo(h,p){return typeof p=="function"?p(h):p}function Im(h){var p=mr();return R_(p,Bt,h)}function R_(h,p,m){var S=h.queue;if(S===null)throw Error(n(311));S.lastRenderedReducer=m;var A=h.baseQueue,L=S.pending;if(L!==null){if(A!==null){var z=A.next;A.next=L.next,L.next=z}p.baseQueue=A=L,S.pending=null}if(L=h.baseState,A===null)h.memoizedState=L;else{p=A.next;var Y=z=null,Z=null,ae=p,he=!1;do{var ve=ae.lane&-536870913;if(ve!==ae.lane?(wt&ve)===ve:(ds&ve)===ve){var se=ae.revertLane;if(se===0)Z!==null&&(Z=Z.next={lane:0,revertLane:0,action:ae.action,hasEagerState:ae.hasEagerState,eagerState:ae.eagerState,next:null}),ve===Wc&&(he=!0);else if((ds&se)===se){ae=ae.next,se===Wc&&(he=!0);continue}else ve={lane:0,revertLane:ae.revertLane,action:ae.action,hasEagerState:ae.hasEagerState,eagerState:ae.eagerState,next:null},Z===null?(Y=Z=ve,z=L):Z=Z.next=ve,ht.lanes|=se,bs|=se;ve=ae.action,Xl&&m(L,ve),L=ae.hasEagerState?ae.eagerState:m(L,ve)}else se={lane:ve,revertLane:ae.revertLane,action:ae.action,hasEagerState:ae.hasEagerState,eagerState:ae.eagerState,next:null},Z===null?(Y=Z=se,z=L):Z=Z.next=se,ht.lanes|=ve,bs|=ve;ae=ae.next}while(ae!==null&&ae!==p);if(Z===null?z=L:Z.next=Y,!Hn(L,h.memoizedState)&&(Pr=!0,he&&(m=Xc,m!==null)))throw m;h.memoizedState=L,h.baseState=z,h.baseQueue=Z,S.lastRenderedState=L}return A===null&&(S.lanes=0),[h.memoizedState,S.dispatch]}function E_(h){var p=mr(),m=p.queue;if(m===null)throw Error(n(311));m.lastRenderedReducer=h;var S=m.dispatch,A=m.pending,L=p.memoizedState;if(A!==null){m.pending=null;var z=A=A.next;do L=h(L,z.action),z=z.next;while(z!==A);Hn(L,p.memoizedState)||(Pr=!0),p.memoizedState=L,p.baseQueue===null&&(p.baseState=L),m.lastRenderedState=L}return[L,S]}function qR(h,p,m){var S=ht,A=mr(),L=Dt;if(L){if(m===void 0)throw Error(n(407));m=m()}else m=p();var z=!Hn((Bt||A).memoizedState,m);z&&(A.memoizedState=m,Pr=!0),A=A.queue;var Y=KR.bind(null,S,A,h);if(Wd(2048,8,Y,[h]),A.getSnapshot!==p||z||gr!==null&&gr.memoizedState.tag&1){if(S.flags|=2048,Kc(9,Om(),$R.bind(null,S,A,m,p),null),Yt===null)throw Error(n(349));L||(ds&124)!==0||ZR(S,p,m)}return m}function ZR(h,p,m){h.flags|=16384,h={getSnapshot:p,value:m},p=ht.updateQueue,p===null?(p=N_(),ht.updateQueue=p,p.stores=[h]):(m=p.stores,m===null?p.stores=[h]:m.push(h))}function $R(h,p,m,S){p.value=m,p.getSnapshot=S,QR(p)&&JR(h)}function KR(h,p,m){return m(function(){QR(p)&&JR(h)})}function QR(h){var p=h.getSnapshot;h=h.value;try{var m=p();return!Hn(h,m)}catch{return!0}}function JR(h){var p=Hc(h,2);p!==null&&qn(p,h,2)}function k_(h){var p=Dn();if(typeof h=="function"){var m=h;if(h=m(),Xl){os(!0);try{m()}finally{os(!1)}}}return p.memoizedState=p.baseState=h,p.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:uo,lastRenderedState:h},p}function eE(h,p,m,S){return h.baseState=m,R_(h,Bt,typeof S=="function"?S:uo)}function XW(h,p,m,S,A){if(jm(h))throw Error(n(485));if(h=p.action,h!==null){var L={payload:A,action:h,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(z){L.listeners.push(z)}};j.T!==null?m(!0):L.isTransition=!1,S(L),m=p.pending,m===null?(L.next=p.pending=L,tE(p,L)):(L.next=m.next,p.pending=m.next=L)}}function tE(h,p){var m=p.action,S=p.payload,A=h.state;if(p.isTransition){var L=j.T,z={};j.T=z;try{var Y=m(A,S),Z=j.S;Z!==null&&Z(z,Y),rE(h,p,Y)}catch(ae){I_(h,p,ae)}finally{j.T=L}}else try{L=m(A,S),rE(h,p,L)}catch(ae){I_(h,p,ae)}}function rE(h,p,m){m!==null&&typeof m=="object"&&typeof m.then=="function"?m.then(function(S){nE(h,p,S)},function(S){return I_(h,p,S)}):nE(h,p,m)}function nE(h,p,m){p.status="fulfilled",p.value=m,aE(p),h.state=m,p=h.pending,p!==null&&(m=p.next,m===p?h.pending=null:(m=m.next,p.next=m,tE(h,m)))}function I_(h,p,m){var S=h.pending;if(h.pending=null,S!==null){S=S.next;do p.status="rejected",p.reason=m,aE(p),p=p.next;while(p!==S)}h.action=null}function aE(h){h=h.listeners;for(var p=0;p<h.length;p++)(0,h[p])()}function iE(h,p){return p}function oE(h,p){if(Dt){var m=Yt.formState;if(m!==null){e:{var S=ht;if(Dt){if(tr){t:{for(var A=tr,L=fi;A.nodeType!==8;){if(!L){A=null;break t}if(A=Ua(A.nextSibling),A===null){A=null;break t}}L=A.data,A=L==="F!"||L==="F"?A:null}if(A){tr=Ua(A.nextSibling),S=A.data==="F!";break e}}Fl(S)}S=!1}S&&(p=m[0])}}return m=Dn(),m.memoizedState=m.baseState=p,S={pending:null,lanes:0,dispatch:null,lastRenderedReducer:iE,lastRenderedState:p},m.queue=S,m=CE.bind(null,ht,S),S.dispatch=m,S=k_(!1),L=B_.bind(null,ht,!1,S.queue),S=Dn(),A={state:p,dispatch:null,action:h,pending:null},S.queue=A,m=XW.bind(null,ht,A,L,m),A.dispatch=m,S.memoizedState=h,[p,m,!1]}function sE(h){var p=mr();return lE(p,Bt,h)}function lE(h,p,m){if(p=R_(h,p,iE)[0],h=Im(uo)[0],typeof p=="object"&&p!==null&&typeof p.then=="function")try{var S=Yd(p)}catch(z){throw z===Bd?Dm:z}else S=p;p=mr();var A=p.queue,L=A.dispatch;return m!==p.memoizedState&&(ht.flags|=2048,Kc(9,Om(),qW.bind(null,A,m),null)),[S,L,h]}function qW(h,p){h.action=p}function uE(h){var p=mr(),m=Bt;if(m!==null)return lE(p,m,h);mr(),p=p.memoizedState,m=mr();var S=m.queue.dispatch;return m.memoizedState=h,[p,S,!1]}function Kc(h,p,m,S){return h={tag:h,create:m,deps:S,inst:p,next:null},p=ht.updateQueue,p===null&&(p=N_(),ht.updateQueue=p),m=p.lastEffect,m===null?p.lastEffect=h.next=h:(S=m.next,m.next=h,h.next=S,p.lastEffect=h),h}function Om(){return{destroy:void 0,resource:void 0}}function cE(){return mr().memoizedState}function Pm(h,p,m,S){var A=Dn();S=S===void 0?null:S,ht.flags|=h,A.memoizedState=Kc(1|p,Om(),m,S)}function Wd(h,p,m,S){var A=mr();S=S===void 0?null:S;var L=A.memoizedState.inst;Bt!==null&&S!==null&&T_(S,Bt.memoizedState.deps)?A.memoizedState=Kc(p,L,m,S):(ht.flags|=h,A.memoizedState=Kc(1|p,L,m,S))}function fE(h,p){Pm(8390656,8,h,p)}function hE(h,p){Wd(2048,8,h,p)}function dE(h,p){return Wd(4,2,h,p)}function vE(h,p){return Wd(4,4,h,p)}function pE(h,p){if(typeof p=="function"){h=h();var m=p(h);return function(){typeof m=="function"?m():p(null)}}if(p!=null)return h=h(),p.current=h,function(){p.current=null}}function gE(h,p,m){m=m!=null?m.concat([h]):null,Wd(4,4,pE.bind(null,p,h),m)}function O_(){}function mE(h,p){var m=mr();p=p===void 0?null:p;var S=m.memoizedState;return p!==null&&T_(p,S[1])?S[0]:(m.memoizedState=[h,p],h)}function yE(h,p){var m=mr();p=p===void 0?null:p;var S=m.memoizedState;if(p!==null&&T_(p,S[1]))return S[0];if(S=h(),Xl){os(!0);try{h()}finally{os(!1)}}return m.memoizedState=[S,p],S}function P_(h,p,m){return m===void 0||(ds&1073741824)!==0?h.memoizedState=p:(h.memoizedState=m,h=_k(),ht.lanes|=h,bs|=h,m)}function xE(h,p,m,S){return Hn(m,p)?m:qc.current!==null?(h=P_(h,m,S),Hn(h,p)||(Pr=!0),h):(ds&42)===0?(Pr=!0,h.memoizedState=m):(h=_k(),ht.lanes|=h,bs|=h,p)}function bE(h,p,m,S,A){var L=U.p;U.p=L!==0&&8>L?L:8;var z=j.T,Y={};j.T=Y,B_(h,!1,p,m);try{var Z=A(),ae=j.S;if(ae!==null&&ae(Y,Z),Z!==null&&typeof Z=="object"&&typeof Z.then=="function"){var he=UW(Z,S);Xd(h,p,he,Xn(h))}else Xd(h,p,S,Xn(h))}catch(ve){Xd(h,p,{then:function(){},status:"rejected",reason:ve},Xn())}finally{U.p=L,j.T=z}}function ZW(){}function j_(h,p,m,S){if(h.tag!==5)throw Error(n(476));var A=_E(h).queue;bE(h,A,p,F,m===null?ZW:function(){return SE(h),m(S)})}function _E(h){var p=h.memoizedState;if(p!==null)return p;p={memoizedState:F,baseState:F,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:uo,lastRenderedState:F},next:null};var m={};return p.next={memoizedState:m,baseState:m,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:uo,lastRenderedState:m},next:null},h.memoizedState=p,h=h.alternate,h!==null&&(h.memoizedState=p),p}function SE(h){var p=_E(h).next.queue;Xd(h,p,{},Xn())}function z_(){return sn(fv)}function wE(){return mr().memoizedState}function TE(){return mr().memoizedState}function $W(h){for(var p=h.return;p!==null;){switch(p.tag){case 24:case 3:var m=Xn();h=fs(m);var S=hs(p,h,m);S!==null&&(qn(S,p,m),Gd(S,p,m)),p={cache:v_()},h.payload=p;return}p=p.return}}function KW(h,p,m){var S=Xn();m={lane:S,revertLane:0,action:m,hasEagerState:!1,eagerState:null,next:null},jm(h)?AE(p,m):(m=a_(h,p,m,S),m!==null&&(qn(m,h,S),ME(m,p,S)))}function CE(h,p,m){var S=Xn();Xd(h,p,m,S)}function Xd(h,p,m,S){var A={lane:S,revertLane:0,action:m,hasEagerState:!1,eagerState:null,next:null};if(jm(h))AE(p,A);else{var L=h.alternate;if(h.lanes===0&&(L===null||L.lanes===0)&&(L=p.lastRenderedReducer,L!==null))try{var z=p.lastRenderedState,Y=L(z,m);if(A.hasEagerState=!0,A.eagerState=Y,Hn(Y,z))return bm(h,p,A,0),Yt===null&&xm(),!1}catch{}finally{}if(m=a_(h,p,A,S),m!==null)return qn(m,h,S),ME(m,p,S),!0}return!1}function B_(h,p,m,S){if(S={lane:2,revertLane:mS(),action:S,hasEagerState:!1,eagerState:null,next:null},jm(h)){if(p)throw Error(n(479))}else p=a_(h,m,S,2),p!==null&&qn(p,h,2)}function jm(h){var p=h.alternate;return h===ht||p!==null&&p===ht}function AE(h,p){Zc=Rm=!0;var m=h.pending;m===null?p.next=p:(p.next=m.next,m.next=p),h.pending=p}function ME(h,p,m){if((m&4194048)!==0){var S=p.lanes;S&=h.pendingLanes,m|=S,p.lanes=m,OL(h,m)}}var zm={readContext:sn,use:km,useCallback:cr,useContext:cr,useEffect:cr,useImperativeHandle:cr,useLayoutEffect:cr,useInsertionEffect:cr,useMemo:cr,useReducer:cr,useRef:cr,useState:cr,useDebugValue:cr,useDeferredValue:cr,useTransition:cr,useSyncExternalStore:cr,useId:cr,useHostTransitionStatus:cr,useFormState:cr,useActionState:cr,useOptimistic:cr,useMemoCache:cr,useCacheRefresh:cr},DE={readContext:sn,use:km,useCallback:function(h,p){return Dn().memoizedState=[h,p===void 0?null:p],h},useContext:sn,useEffect:fE,useImperativeHandle:function(h,p,m){m=m!=null?m.concat([h]):null,Pm(4194308,4,pE.bind(null,p,h),m)},useLayoutEffect:function(h,p){return Pm(4194308,4,h,p)},useInsertionEffect:function(h,p){Pm(4,2,h,p)},useMemo:function(h,p){var m=Dn();p=p===void 0?null:p;var S=h();if(Xl){os(!0);try{h()}finally{os(!1)}}return m.memoizedState=[S,p],S},useReducer:function(h,p,m){var S=Dn();if(m!==void 0){var A=m(p);if(Xl){os(!0);try{m(p)}finally{os(!1)}}}else A=p;return S.memoizedState=S.baseState=A,h={pending:null,lanes:0,dispatch:null,lastRenderedReducer:h,lastRenderedState:A},S.queue=h,h=h.dispatch=KW.bind(null,ht,h),[S.memoizedState,h]},useRef:function(h){var p=Dn();return h={current:h},p.memoizedState=h},useState:function(h){h=k_(h);var p=h.queue,m=CE.bind(null,ht,p);return p.dispatch=m,[h.memoizedState,m]},useDebugValue:O_,useDeferredValue:function(h,p){var m=Dn();return P_(m,h,p)},useTransition:function(){var h=k_(!1);return h=bE.bind(null,ht,h.queue,!0,!1),Dn().memoizedState=h,[!1,h]},useSyncExternalStore:function(h,p,m){var S=ht,A=Dn();if(Dt){if(m===void 0)throw Error(n(407));m=m()}else{if(m=p(),Yt===null)throw Error(n(349));(wt&124)!==0||ZR(S,p,m)}A.memoizedState=m;var L={value:m,getSnapshot:p};return A.queue=L,fE(KR.bind(null,S,L,h),[h]),S.flags|=2048,Kc(9,Om(),$R.bind(null,S,L,m,p),null),m},useId:function(){var h=Dn(),p=Yt.identifierPrefix;if(Dt){var m=oo,S=io;m=(S&~(1<<32-Gn(S)-1)).toString(32)+m,p="«"+p+"R"+m,m=Em++,0<m&&(p+="H"+m.toString(32)),p+="»"}else m=YW++,p="«"+p+"r"+m.toString(32)+"»";return h.memoizedState=p},useHostTransitionStatus:z_,useFormState:oE,useActionState:oE,useOptimistic:function(h){var p=Dn();p.memoizedState=p.baseState=h;var m={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return p.queue=m,p=B_.bind(null,ht,!0,m),m.dispatch=p,[h,p]},useMemoCache:L_,useCacheRefresh:function(){return Dn().memoizedState=$W.bind(null,ht)}},NE={readContext:sn,use:km,useCallback:mE,useContext:sn,useEffect:hE,useImperativeHandle:gE,useInsertionEffect:dE,useLayoutEffect:vE,useMemo:yE,useReducer:Im,useRef:cE,useState:function(){return Im(uo)},useDebugValue:O_,useDeferredValue:function(h,p){var m=mr();return xE(m,Bt.memoizedState,h,p)},useTransition:function(){var h=Im(uo)[0],p=mr().memoizedState;return[typeof h=="boolean"?h:Yd(h),p]},useSyncExternalStore:qR,useId:wE,useHostTransitionStatus:z_,useFormState:sE,useActionState:sE,useOptimistic:function(h,p){var m=mr();return eE(m,Bt,h,p)},useMemoCache:L_,useCacheRefresh:TE},QW={readContext:sn,use:km,useCallback:mE,useContext:sn,useEffect:hE,useImperativeHandle:gE,useInsertionEffect:dE,useLayoutEffect:vE,useMemo:yE,useReducer:E_,useRef:cE,useState:function(){return E_(uo)},useDebugValue:O_,useDeferredValue:function(h,p){var m=mr();return Bt===null?P_(m,h,p):xE(m,Bt.memoizedState,h,p)},useTransition:function(){var h=E_(uo)[0],p=mr().memoizedState;return[typeof h=="boolean"?h:Yd(h),p]},useSyncExternalStore:qR,useId:wE,useHostTransitionStatus:z_,useFormState:uE,useActionState:uE,useOptimistic:function(h,p){var m=mr();return Bt!==null?eE(m,Bt,h,p):(m.baseState=h,[h,m.queue.dispatch])},useMemoCache:L_,useCacheRefresh:TE},Qc=null,qd=0;function Bm(h){var p=qd;return qd+=1,Qc===null&&(Qc=[]),VR(Qc,h,p)}function Zd(h,p){p=p.props.ref,h.ref=p!==void 0?p:null}function Vm(h,p){throw p.$$typeof===f?Error(n(525)):(h=Object.prototype.toString.call(p),Error(n(31,h==="[object Object]"?"object with keys {"+Object.keys(p).join(", ")+"}":h)))}function LE(h){var p=h._init;return p(h._payload)}function RE(h){function p(re,Q){if(h){var ne=re.deletions;ne===null?(re.deletions=[Q],re.flags|=16):ne.push(Q)}}function m(re,Q){if(!h)return null;for(;Q!==null;)p(re,Q),Q=Q.sibling;return null}function S(re){for(var Q=new Map;re!==null;)re.key!==null?Q.set(re.key,re):Q.set(re.index,re),re=re.sibling;return Q}function A(re,Q){return re=ao(re,Q),re.index=0,re.sibling=null,re}function L(re,Q,ne){return re.index=ne,h?(ne=re.alternate,ne!==null?(ne=ne.index,ne<Q?(re.flags|=67108866,Q):ne):(re.flags|=67108866,Q)):(re.flags|=1048576,Q)}function z(re){return h&&re.alternate===null&&(re.flags|=67108866),re}function Y(re,Q,ne,de){return Q===null||Q.tag!==6?(Q=o_(ne,re.mode,de),Q.return=re,Q):(Q=A(Q,ne),Q.return=re,Q)}function Z(re,Q,ne,de){var Ve=ne.type;return Ve===g?he(re,Q,ne.props.children,de,ne.key):Q!==null&&(Q.elementType===Ve||typeof Ve=="object"&&Ve!==null&&Ve.$$typeof===R&&LE(Ve)===Q.type)?(Q=A(Q,ne.props),Zd(Q,ne),Q.return=re,Q):(Q=Sm(ne.type,ne.key,ne.props,null,re.mode,de),Zd(Q,ne),Q.return=re,Q)}function ae(re,Q,ne,de){return Q===null||Q.tag!==4||Q.stateNode.containerInfo!==ne.containerInfo||Q.stateNode.implementation!==ne.implementation?(Q=s_(ne,re.mode,de),Q.return=re,Q):(Q=A(Q,ne.children||[]),Q.return=re,Q)}function he(re,Q,ne,de,Ve){return Q===null||Q.tag!==7?(Q=Bl(ne,re.mode,de,Ve),Q.return=re,Q):(Q=A(Q,ne),Q.return=re,Q)}function ve(re,Q,ne){if(typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint")return Q=o_(""+Q,re.mode,ne),Q.return=re,Q;if(typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case d:return ne=Sm(Q.type,Q.key,Q.props,null,re.mode,ne),Zd(ne,Q),ne.return=re,ne;case v:return Q=s_(Q,re.mode,ne),Q.return=re,Q;case R:var de=Q._init;return Q=de(Q._payload),ve(re,Q,ne)}if(V(Q)||B(Q))return Q=Bl(Q,re.mode,ne,null),Q.return=re,Q;if(typeof Q.then=="function")return ve(re,Bm(Q),ne);if(Q.$$typeof===T)return ve(re,Am(re,Q),ne);Vm(re,Q)}return null}function se(re,Q,ne,de){var Ve=Q!==null?Q.key:null;if(typeof ne=="string"&&ne!==""||typeof ne=="number"||typeof ne=="bigint")return Ve!==null?null:Y(re,Q,""+ne,de);if(typeof ne=="object"&&ne!==null){switch(ne.$$typeof){case d:return ne.key===Ve?Z(re,Q,ne,de):null;case v:return ne.key===Ve?ae(re,Q,ne,de):null;case R:return Ve=ne._init,ne=Ve(ne._payload),se(re,Q,ne,de)}if(V(ne)||B(ne))return Ve!==null?null:he(re,Q,ne,de,null);if(typeof ne.then=="function")return se(re,Q,Bm(ne),de);if(ne.$$typeof===T)return se(re,Q,Am(re,ne),de);Vm(re,ne)}return null}function le(re,Q,ne,de,Ve){if(typeof de=="string"&&de!==""||typeof de=="number"||typeof de=="bigint")return re=re.get(ne)||null,Y(Q,re,""+de,Ve);if(typeof de=="object"&&de!==null){switch(de.$$typeof){case d:return re=re.get(de.key===null?ne:de.key)||null,Z(Q,re,de,Ve);case v:return re=re.get(de.key===null?ne:de.key)||null,ae(Q,re,de,Ve);case R:var vt=de._init;return de=vt(de._payload),le(re,Q,ne,de,Ve)}if(V(de)||B(de))return re=re.get(ne)||null,he(Q,re,de,Ve,null);if(typeof de.then=="function")return le(re,Q,ne,Bm(de),Ve);if(de.$$typeof===T)return le(re,Q,ne,Am(Q,de),Ve);Vm(Q,de)}return null}function rt(re,Q,ne,de){for(var Ve=null,vt=null,Ue=Q,Ke=Q=0,zr=null;Ue!==null&&Ke<ne.length;Ke++){Ue.index>Ke?(zr=Ue,Ue=null):zr=Ue.sibling;var Mt=se(re,Ue,ne[Ke],de);if(Mt===null){Ue===null&&(Ue=zr);break}h&&Ue&&Mt.alternate===null&&p(re,Ue),Q=L(Mt,Q,Ke),vt===null?Ve=Mt:vt.sibling=Mt,vt=Mt,Ue=zr}if(Ke===ne.length)return m(re,Ue),Dt&&Gl(re,Ke),Ve;if(Ue===null){for(;Ke<ne.length;Ke++)Ue=ve(re,ne[Ke],de),Ue!==null&&(Q=L(Ue,Q,Ke),vt===null?Ve=Ue:vt.sibling=Ue,vt=Ue);return Dt&&Gl(re,Ke),Ve}for(Ue=S(Ue);Ke<ne.length;Ke++)zr=le(Ue,re,Ke,ne[Ke],de),zr!==null&&(h&&zr.alternate!==null&&Ue.delete(zr.key===null?Ke:zr.key),Q=L(zr,Q,Ke),vt===null?Ve=zr:vt.sibling=zr,vt=zr);return h&&Ue.forEach(function(Ns){return p(re,Ns)}),Dt&&Gl(re,Ke),Ve}function Ze(re,Q,ne,de){if(ne==null)throw Error(n(151));for(var Ve=null,vt=null,Ue=Q,Ke=Q=0,zr=null,Mt=ne.next();Ue!==null&&!Mt.done;Ke++,Mt=ne.next()){Ue.index>Ke?(zr=Ue,Ue=null):zr=Ue.sibling;var Ns=se(re,Ue,Mt.value,de);if(Ns===null){Ue===null&&(Ue=zr);break}h&&Ue&&Ns.alternate===null&&p(re,Ue),Q=L(Ns,Q,Ke),vt===null?Ve=Ns:vt.sibling=Ns,vt=Ns,Ue=zr}if(Mt.done)return m(re,Ue),Dt&&Gl(re,Ke),Ve;if(Ue===null){for(;!Mt.done;Ke++,Mt=ne.next())Mt=ve(re,Mt.value,de),Mt!==null&&(Q=L(Mt,Q,Ke),vt===null?Ve=Mt:vt.sibling=Mt,vt=Mt);return Dt&&Gl(re,Ke),Ve}for(Ue=S(Ue);!Mt.done;Ke++,Mt=ne.next())Mt=le(Ue,re,Ke,Mt.value,de),Mt!==null&&(h&&Mt.alternate!==null&&Ue.delete(Mt.key===null?Ke:Mt.key),Q=L(Mt,Q,Ke),vt===null?Ve=Mt:vt.sibling=Mt,vt=Mt);return h&&Ue.forEach(function(JX){return p(re,JX)}),Dt&&Gl(re,Ke),Ve}function Gt(re,Q,ne,de){if(typeof ne=="object"&&ne!==null&&ne.type===g&&ne.key===null&&(ne=ne.props.children),typeof ne=="object"&&ne!==null){switch(ne.$$typeof){case d:e:{for(var Ve=ne.key;Q!==null;){if(Q.key===Ve){if(Ve=ne.type,Ve===g){if(Q.tag===7){m(re,Q.sibling),de=A(Q,ne.props.children),de.return=re,re=de;break e}}else if(Q.elementType===Ve||typeof Ve=="object"&&Ve!==null&&Ve.$$typeof===R&&LE(Ve)===Q.type){m(re,Q.sibling),de=A(Q,ne.props),Zd(de,ne),de.return=re,re=de;break e}m(re,Q);break}else p(re,Q);Q=Q.sibling}ne.type===g?(de=Bl(ne.props.children,re.mode,de,ne.key),de.return=re,re=de):(de=Sm(ne.type,ne.key,ne.props,null,re.mode,de),Zd(de,ne),de.return=re,re=de)}return z(re);case v:e:{for(Ve=ne.key;Q!==null;){if(Q.key===Ve)if(Q.tag===4&&Q.stateNode.containerInfo===ne.containerInfo&&Q.stateNode.implementation===ne.implementation){m(re,Q.sibling),de=A(Q,ne.children||[]),de.return=re,re=de;break e}else{m(re,Q);break}else p(re,Q);Q=Q.sibling}de=s_(ne,re.mode,de),de.return=re,re=de}return z(re);case R:return Ve=ne._init,ne=Ve(ne._payload),Gt(re,Q,ne,de)}if(V(ne))return rt(re,Q,ne,de);if(B(ne)){if(Ve=B(ne),typeof Ve!="function")throw Error(n(150));return ne=Ve.call(ne),Ze(re,Q,ne,de)}if(typeof ne.then=="function")return Gt(re,Q,Bm(ne),de);if(ne.$$typeof===T)return Gt(re,Q,Am(re,ne),de);Vm(re,ne)}return typeof ne=="string"&&ne!==""||typeof ne=="number"||typeof ne=="bigint"?(ne=""+ne,Q!==null&&Q.tag===6?(m(re,Q.sibling),de=A(Q,ne),de.return=re,re=de):(m(re,Q),de=o_(ne,re.mode,de),de.return=re,re=de),z(re)):m(re,Q)}return function(re,Q,ne,de){try{qd=0;var Ve=Gt(re,Q,ne,de);return Qc=null,Ve}catch(Ue){if(Ue===Bd||Ue===Dm)throw Ue;var vt=Fn(29,Ue,null,re.mode);return vt.lanes=de,vt.return=re,vt}finally{}}}var Jc=RE(!0),EE=RE(!1),ga=W(null),hi=null;function vs(h){var p=h.alternate;te(Mr,Mr.current&1),te(ga,h),hi===null&&(p===null||qc.current!==null||p.memoizedState!==null)&&(hi=h)}function kE(h){if(h.tag===22){if(te(Mr,Mr.current),te(ga,h),hi===null){var p=h.alternate;p!==null&&p.memoizedState!==null&&(hi=h)}}else ps()}function ps(){te(Mr,Mr.current),te(ga,ga.current)}function co(h){$(ga),hi===h&&(hi=null),$(Mr)}var Mr=W(0);function Gm(h){for(var p=h;p!==null;){if(p.tag===13){var m=p.memoizedState;if(m!==null&&(m=m.dehydrated,m===null||m.data==="$?"||NS(m)))return p}else if(p.tag===19&&p.memoizedProps.revealOrder!==void 0){if((p.flags&128)!==0)return p}else if(p.child!==null){p.child.return=p,p=p.child;continue}if(p===h)break;for(;p.sibling===null;){if(p.return===null||p.return===h)return null;p=p.return}p.sibling.return=p.return,p=p.sibling}return null}function V_(h,p,m,S){p=h.memoizedState,m=m(S,p),m=m==null?p:c({},p,m),h.memoizedState=m,h.lanes===0&&(h.updateQueue.baseState=m)}var G_={enqueueSetState:function(h,p,m){h=h._reactInternals;var S=Xn(),A=fs(S);A.payload=p,m!=null&&(A.callback=m),p=hs(h,A,S),p!==null&&(qn(p,h,S),Gd(p,h,S))},enqueueReplaceState:function(h,p,m){h=h._reactInternals;var S=Xn(),A=fs(S);A.tag=1,A.payload=p,m!=null&&(A.callback=m),p=hs(h,A,S),p!==null&&(qn(p,h,S),Gd(p,h,S))},enqueueForceUpdate:function(h,p){h=h._reactInternals;var m=Xn(),S=fs(m);S.tag=2,p!=null&&(S.callback=p),p=hs(h,S,m),p!==null&&(qn(p,h,m),Gd(p,h,m))}};function IE(h,p,m,S,A,L,z){return h=h.stateNode,typeof h.shouldComponentUpdate=="function"?h.shouldComponentUpdate(S,L,z):p.prototype&&p.prototype.isPureReactComponent?!Rd(m,S)||!Rd(A,L):!0}function OE(h,p,m,S){h=p.state,typeof p.componentWillReceiveProps=="function"&&p.componentWillReceiveProps(m,S),typeof p.UNSAFE_componentWillReceiveProps=="function"&&p.UNSAFE_componentWillReceiveProps(m,S),p.state!==h&&G_.enqueueReplaceState(p,p.state,null)}function ql(h,p){var m=p;if("ref"in p){m={};for(var S in p)S!=="ref"&&(m[S]=p[S])}if(h=h.defaultProps){m===p&&(m=c({},m));for(var A in h)m[A]===void 0&&(m[A]=h[A])}return m}var Hm=typeof reportError=="function"?reportError:function(h){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var p=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof h=="object"&&h!==null&&typeof h.message=="string"?String(h.message):String(h),error:h});if(!window.dispatchEvent(p))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",h);return}console.error(h)};function PE(h){Hm(h)}function jE(h){console.error(h)}function zE(h){Hm(h)}function Fm(h,p){try{var m=h.onUncaughtError;m(p.value,{componentStack:p.stack})}catch(S){setTimeout(function(){throw S})}}function BE(h,p,m){try{var S=h.onCaughtError;S(m.value,{componentStack:m.stack,errorBoundary:p.tag===1?p.stateNode:null})}catch(A){setTimeout(function(){throw A})}}function H_(h,p,m){return m=fs(m),m.tag=3,m.payload={element:null},m.callback=function(){Fm(h,p)},m}function VE(h){return h=fs(h),h.tag=3,h}function GE(h,p,m,S){var A=m.type.getDerivedStateFromError;if(typeof A=="function"){var L=S.value;h.payload=function(){return A(L)},h.callback=function(){BE(p,m,S)}}var z=m.stateNode;z!==null&&typeof z.componentDidCatch=="function"&&(h.callback=function(){BE(p,m,S),typeof A!="function"&&(_s===null?_s=new Set([this]):_s.add(this));var Y=S.stack;this.componentDidCatch(S.value,{componentStack:Y!==null?Y:""})})}function JW(h,p,m,S,A){if(m.flags|=32768,S!==null&&typeof S=="object"&&typeof S.then=="function"){if(p=m.alternate,p!==null&&Pd(p,m,A,!0),m=ga.current,m!==null){switch(m.tag){case 13:return hi===null?hS():m.alternate===null&&rr===0&&(rr=3),m.flags&=-257,m.flags|=65536,m.lanes=A,S===m_?m.flags|=16384:(p=m.updateQueue,p===null?m.updateQueue=new Set([S]):p.add(S),vS(h,S,A)),!1;case 22:return m.flags|=65536,S===m_?m.flags|=16384:(p=m.updateQueue,p===null?(p={transitions:null,markerInstances:null,retryQueue:new Set([S])},m.updateQueue=p):(m=p.retryQueue,m===null?p.retryQueue=new Set([S]):m.add(S)),vS(h,S,A)),!1}throw Error(n(435,m.tag))}return vS(h,S,A),hS(),!1}if(Dt)return p=ga.current,p!==null?((p.flags&65536)===0&&(p.flags|=256),p.flags|=65536,p.lanes=A,S!==c_&&(h=Error(n(422),{cause:S}),Od(ha(h,m)))):(S!==c_&&(p=Error(n(423),{cause:S}),Od(ha(p,m))),h=h.current.alternate,h.flags|=65536,A&=-A,h.lanes|=A,S=ha(S,m),A=H_(h.stateNode,S,A),b_(h,A),rr!==4&&(rr=2)),!1;var L=Error(n(520),{cause:S});if(L=ha(L,m),rv===null?rv=[L]:rv.push(L),rr!==4&&(rr=2),p===null)return!0;S=ha(S,m),m=p;do{switch(m.tag){case 3:return m.flags|=65536,h=A&-A,m.lanes|=h,h=H_(m.stateNode,S,h),b_(m,h),!1;case 1:if(p=m.type,L=m.stateNode,(m.flags&128)===0&&(typeof p.getDerivedStateFromError=="function"||L!==null&&typeof L.componentDidCatch=="function"&&(_s===null||!_s.has(L))))return m.flags|=65536,A&=-A,m.lanes|=A,A=VE(A),GE(A,h,m,S),b_(m,A),!1}m=m.return}while(m!==null);return!1}var HE=Error(n(461)),Pr=!1;function Xr(h,p,m,S){p.child=h===null?EE(p,null,m,S):Jc(p,h.child,m,S)}function FE(h,p,m,S,A){m=m.render;var L=p.ref;if("ref"in S){var z={};for(var Y in S)Y!=="ref"&&(z[Y]=S[Y])}else z=S;return Yl(p),S=C_(h,p,m,z,L,A),Y=A_(),h!==null&&!Pr?(M_(h,p,A),fo(h,p,A)):(Dt&&Y&&l_(p),p.flags|=1,Xr(h,p,S,A),p.child)}function UE(h,p,m,S,A){if(h===null){var L=m.type;return typeof L=="function"&&!i_(L)&&L.defaultProps===void 0&&m.compare===null?(p.tag=15,p.type=L,YE(h,p,L,S,A)):(h=Sm(m.type,null,S,p,p.mode,A),h.ref=p.ref,h.return=p,p.child=h)}if(L=h.child,!$_(h,A)){var z=L.memoizedProps;if(m=m.compare,m=m!==null?m:Rd,m(z,S)&&h.ref===p.ref)return fo(h,p,A)}return p.flags|=1,h=ao(L,S),h.ref=p.ref,h.return=p,p.child=h}function YE(h,p,m,S,A){if(h!==null){var L=h.memoizedProps;if(Rd(L,S)&&h.ref===p.ref)if(Pr=!1,p.pendingProps=S=L,$_(h,A))(h.flags&131072)!==0&&(Pr=!0);else return p.lanes=h.lanes,fo(h,p,A)}return F_(h,p,m,S,A)}function WE(h,p,m){var S=p.pendingProps,A=S.children,L=h!==null?h.memoizedState:null;if(S.mode==="hidden"){if((p.flags&128)!==0){if(S=L!==null?L.baseLanes|m:m,h!==null){for(A=p.child=h.child,L=0;A!==null;)L=L|A.lanes|A.childLanes,A=A.sibling;p.childLanes=L&~S}else p.childLanes=0,p.child=null;return XE(h,p,S,m)}if((m&536870912)!==0)p.memoizedState={baseLanes:0,cachePool:null},h!==null&&Mm(p,L!==null?L.cachePool:null),L!==null?YR(p,L):S_(),kE(p);else return p.lanes=p.childLanes=536870912,XE(h,p,L!==null?L.baseLanes|m:m,m)}else L!==null?(Mm(p,L.cachePool),YR(p,L),ps(),p.memoizedState=null):(h!==null&&Mm(p,null),S_(),ps());return Xr(h,p,A,m),p.child}function XE(h,p,m,S){var A=g_();return A=A===null?null:{parent:Ar._currentValue,pool:A},p.memoizedState={baseLanes:m,cachePool:A},h!==null&&Mm(p,null),S_(),kE(p),h!==null&&Pd(h,p,S,!0),null}function Um(h,p){var m=p.ref;if(m===null)h!==null&&h.ref!==null&&(p.flags|=4194816);else{if(typeof m!="function"&&typeof m!="object")throw Error(n(284));(h===null||h.ref!==m)&&(p.flags|=4194816)}}function F_(h,p,m,S,A){return Yl(p),m=C_(h,p,m,S,void 0,A),S=A_(),h!==null&&!Pr?(M_(h,p,A),fo(h,p,A)):(Dt&&S&&l_(p),p.flags|=1,Xr(h,p,m,A),p.child)}function qE(h,p,m,S,A,L){return Yl(p),p.updateQueue=null,m=XR(p,S,m,A),WR(h),S=A_(),h!==null&&!Pr?(M_(h,p,L),fo(h,p,L)):(Dt&&S&&l_(p),p.flags|=1,Xr(h,p,m,L),p.child)}function ZE(h,p,m,S,A){if(Yl(p),p.stateNode===null){var L=Fc,z=m.contextType;typeof z=="object"&&z!==null&&(L=sn(z)),L=new m(S,L),p.memoizedState=L.state!==null&&L.state!==void 0?L.state:null,L.updater=G_,p.stateNode=L,L._reactInternals=p,L=p.stateNode,L.props=S,L.state=p.memoizedState,L.refs={},y_(p),z=m.contextType,L.context=typeof z=="object"&&z!==null?sn(z):Fc,L.state=p.memoizedState,z=m.getDerivedStateFromProps,typeof z=="function"&&(V_(p,m,z,S),L.state=p.memoizedState),typeof m.getDerivedStateFromProps=="function"||typeof L.getSnapshotBeforeUpdate=="function"||typeof L.UNSAFE_componentWillMount!="function"&&typeof L.componentWillMount!="function"||(z=L.state,typeof L.componentWillMount=="function"&&L.componentWillMount(),typeof L.UNSAFE_componentWillMount=="function"&&L.UNSAFE_componentWillMount(),z!==L.state&&G_.enqueueReplaceState(L,L.state,null),Fd(p,S,L,A),Hd(),L.state=p.memoizedState),typeof L.componentDidMount=="function"&&(p.flags|=4194308),S=!0}else if(h===null){L=p.stateNode;var Y=p.memoizedProps,Z=ql(m,Y);L.props=Z;var ae=L.context,he=m.contextType;z=Fc,typeof he=="object"&&he!==null&&(z=sn(he));var ve=m.getDerivedStateFromProps;he=typeof ve=="function"||typeof L.getSnapshotBeforeUpdate=="function",Y=p.pendingProps!==Y,he||typeof L.UNSAFE_componentWillReceiveProps!="function"&&typeof L.componentWillReceiveProps!="function"||(Y||ae!==z)&&OE(p,L,S,z),cs=!1;var se=p.memoizedState;L.state=se,Fd(p,S,L,A),Hd(),ae=p.memoizedState,Y||se!==ae||cs?(typeof ve=="function"&&(V_(p,m,ve,S),ae=p.memoizedState),(Z=cs||IE(p,m,Z,S,se,ae,z))?(he||typeof L.UNSAFE_componentWillMount!="function"&&typeof L.componentWillMount!="function"||(typeof L.componentWillMount=="function"&&L.componentWillMount(),typeof L.UNSAFE_componentWillMount=="function"&&L.UNSAFE_componentWillMount()),typeof L.componentDidMount=="function"&&(p.flags|=4194308)):(typeof L.componentDidMount=="function"&&(p.flags|=4194308),p.memoizedProps=S,p.memoizedState=ae),L.props=S,L.state=ae,L.context=z,S=Z):(typeof L.componentDidMount=="function"&&(p.flags|=4194308),S=!1)}else{L=p.stateNode,x_(h,p),z=p.memoizedProps,he=ql(m,z),L.props=he,ve=p.pendingProps,se=L.context,ae=m.contextType,Z=Fc,typeof ae=="object"&&ae!==null&&(Z=sn(ae)),Y=m.getDerivedStateFromProps,(ae=typeof Y=="function"||typeof L.getSnapshotBeforeUpdate=="function")||typeof L.UNSAFE_componentWillReceiveProps!="function"&&typeof L.componentWillReceiveProps!="function"||(z!==ve||se!==Z)&&OE(p,L,S,Z),cs=!1,se=p.memoizedState,L.state=se,Fd(p,S,L,A),Hd();var le=p.memoizedState;z!==ve||se!==le||cs||h!==null&&h.dependencies!==null&&Cm(h.dependencies)?(typeof Y=="function"&&(V_(p,m,Y,S),le=p.memoizedState),(he=cs||IE(p,m,he,S,se,le,Z)||h!==null&&h.dependencies!==null&&Cm(h.dependencies))?(ae||typeof L.UNSAFE_componentWillUpdate!="function"&&typeof L.componentWillUpdate!="function"||(typeof L.componentWillUpdate=="function"&&L.componentWillUpdate(S,le,Z),typeof L.UNSAFE_componentWillUpdate=="function"&&L.UNSAFE_componentWillUpdate(S,le,Z)),typeof L.componentDidUpdate=="function"&&(p.flags|=4),typeof L.getSnapshotBeforeUpdate=="function"&&(p.flags|=1024)):(typeof L.componentDidUpdate!="function"||z===h.memoizedProps&&se===h.memoizedState||(p.flags|=4),typeof L.getSnapshotBeforeUpdate!="function"||z===h.memoizedProps&&se===h.memoizedState||(p.flags|=1024),p.memoizedProps=S,p.memoizedState=le),L.props=S,L.state=le,L.context=Z,S=he):(typeof L.componentDidUpdate!="function"||z===h.memoizedProps&&se===h.memoizedState||(p.flags|=4),typeof L.getSnapshotBeforeUpdate!="function"||z===h.memoizedProps&&se===h.memoizedState||(p.flags|=1024),S=!1)}return L=S,Um(h,p),S=(p.flags&128)!==0,L||S?(L=p.stateNode,m=S&&typeof m.getDerivedStateFromError!="function"?null:L.render(),p.flags|=1,h!==null&&S?(p.child=Jc(p,h.child,null,A),p.child=Jc(p,null,m,A)):Xr(h,p,m,A),p.memoizedState=L.state,h=p.child):h=fo(h,p,A),h}function $E(h,p,m,S){return Id(),p.flags|=256,Xr(h,p,m,S),p.child}var U_={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Y_(h){return{baseLanes:h,cachePool:jR()}}function W_(h,p,m){return h=h!==null?h.childLanes&~m:0,p&&(h|=ma),h}function KE(h,p,m){var S=p.pendingProps,A=!1,L=(p.flags&128)!==0,z;if((z=L)||(z=h!==null&&h.memoizedState===null?!1:(Mr.current&2)!==0),z&&(A=!0,p.flags&=-129),z=(p.flags&32)!==0,p.flags&=-33,h===null){if(Dt){if(A?vs(p):ps(),Dt){var Y=tr,Z;if(Z=Y){e:{for(Z=Y,Y=fi;Z.nodeType!==8;){if(!Y){Y=null;break e}if(Z=Ua(Z.nextSibling),Z===null){Y=null;break e}}Y=Z}Y!==null?(p.memoizedState={dehydrated:Y,treeContext:Vl!==null?{id:io,overflow:oo}:null,retryLane:536870912,hydrationErrors:null},Z=Fn(18,null,null,0),Z.stateNode=Y,Z.return=p,p.child=Z,gn=p,tr=null,Z=!0):Z=!1}Z||Fl(p)}if(Y=p.memoizedState,Y!==null&&(Y=Y.dehydrated,Y!==null))return NS(Y)?p.lanes=32:p.lanes=536870912,null;co(p)}return Y=S.children,S=S.fallback,A?(ps(),A=p.mode,Y=Ym({mode:"hidden",children:Y},A),S=Bl(S,A,m,null),Y.return=p,S.return=p,Y.sibling=S,p.child=Y,A=p.child,A.memoizedState=Y_(m),A.childLanes=W_(h,z,m),p.memoizedState=U_,S):(vs(p),X_(p,Y))}if(Z=h.memoizedState,Z!==null&&(Y=Z.dehydrated,Y!==null)){if(L)p.flags&256?(vs(p),p.flags&=-257,p=q_(h,p,m)):p.memoizedState!==null?(ps(),p.child=h.child,p.flags|=128,p=null):(ps(),A=S.fallback,Y=p.mode,S=Ym({mode:"visible",children:S.children},Y),A=Bl(A,Y,m,null),A.flags|=2,S.return=p,A.return=p,S.sibling=A,p.child=S,Jc(p,h.child,null,m),S=p.child,S.memoizedState=Y_(m),S.childLanes=W_(h,z,m),p.memoizedState=U_,p=A);else if(vs(p),NS(Y)){if(z=Y.nextSibling&&Y.nextSibling.dataset,z)var ae=z.dgst;z=ae,S=Error(n(419)),S.stack="",S.digest=z,Od({value:S,source:null,stack:null}),p=q_(h,p,m)}else if(Pr||Pd(h,p,m,!1),z=(m&h.childLanes)!==0,Pr||z){if(z=Yt,z!==null&&(S=m&-m,S=(S&42)!==0?1:Lb(S),S=(S&(z.suspendedLanes|m))!==0?0:S,S!==0&&S!==Z.retryLane))throw Z.retryLane=S,Hc(h,S),qn(z,h,S),HE;Y.data==="$?"||hS(),p=q_(h,p,m)}else Y.data==="$?"?(p.flags|=192,p.child=h.child,p=null):(h=Z.treeContext,tr=Ua(Y.nextSibling),gn=p,Dt=!0,Hl=null,fi=!1,h!==null&&(va[pa++]=io,va[pa++]=oo,va[pa++]=Vl,io=h.id,oo=h.overflow,Vl=p),p=X_(p,S.children),p.flags|=4096);return p}return A?(ps(),A=S.fallback,Y=p.mode,Z=h.child,ae=Z.sibling,S=ao(Z,{mode:"hidden",children:S.children}),S.subtreeFlags=Z.subtreeFlags&65011712,ae!==null?A=ao(ae,A):(A=Bl(A,Y,m,null),A.flags|=2),A.return=p,S.return=p,S.sibling=A,p.child=S,S=A,A=p.child,Y=h.child.memoizedState,Y===null?Y=Y_(m):(Z=Y.cachePool,Z!==null?(ae=Ar._currentValue,Z=Z.parent!==ae?{parent:ae,pool:ae}:Z):Z=jR(),Y={baseLanes:Y.baseLanes|m,cachePool:Z}),A.memoizedState=Y,A.childLanes=W_(h,z,m),p.memoizedState=U_,S):(vs(p),m=h.child,h=m.sibling,m=ao(m,{mode:"visible",children:S.children}),m.return=p,m.sibling=null,h!==null&&(z=p.deletions,z===null?(p.deletions=[h],p.flags|=16):z.push(h)),p.child=m,p.memoizedState=null,m)}function X_(h,p){return p=Ym({mode:"visible",children:p},h.mode),p.return=h,h.child=p}function Ym(h,p){return h=Fn(22,h,null,p),h.lanes=0,h.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},h}function q_(h,p,m){return Jc(p,h.child,null,m),h=X_(p,p.pendingProps.children),h.flags|=2,p.memoizedState=null,h}function QE(h,p,m){h.lanes|=p;var S=h.alternate;S!==null&&(S.lanes|=p),h_(h.return,p,m)}function Z_(h,p,m,S,A){var L=h.memoizedState;L===null?h.memoizedState={isBackwards:p,rendering:null,renderingStartTime:0,last:S,tail:m,tailMode:A}:(L.isBackwards=p,L.rendering=null,L.renderingStartTime=0,L.last=S,L.tail=m,L.tailMode=A)}function JE(h,p,m){var S=p.pendingProps,A=S.revealOrder,L=S.tail;if(Xr(h,p,S.children,m),S=Mr.current,(S&2)!==0)S=S&1|2,p.flags|=128;else{if(h!==null&&(h.flags&128)!==0)e:for(h=p.child;h!==null;){if(h.tag===13)h.memoizedState!==null&&QE(h,m,p);else if(h.tag===19)QE(h,m,p);else if(h.child!==null){h.child.return=h,h=h.child;continue}if(h===p)break e;for(;h.sibling===null;){if(h.return===null||h.return===p)break e;h=h.return}h.sibling.return=h.return,h=h.sibling}S&=1}switch(te(Mr,S),A){case"forwards":for(m=p.child,A=null;m!==null;)h=m.alternate,h!==null&&Gm(h)===null&&(A=m),m=m.sibling;m=A,m===null?(A=p.child,p.child=null):(A=m.sibling,m.sibling=null),Z_(p,!1,A,m,L);break;case"backwards":for(m=null,A=p.child,p.child=null;A!==null;){if(h=A.alternate,h!==null&&Gm(h)===null){p.child=A;break}h=A.sibling,A.sibling=m,m=A,A=h}Z_(p,!0,m,null,L);break;case"together":Z_(p,!1,null,null,void 0);break;default:p.memoizedState=null}return p.child}function fo(h,p,m){if(h!==null&&(p.dependencies=h.dependencies),bs|=p.lanes,(m&p.childLanes)===0)if(h!==null){if(Pd(h,p,m,!1),(m&p.childLanes)===0)return null}else return null;if(h!==null&&p.child!==h.child)throw Error(n(153));if(p.child!==null){for(h=p.child,m=ao(h,h.pendingProps),p.child=m,m.return=p;h.sibling!==null;)h=h.sibling,m=m.sibling=ao(h,h.pendingProps),m.return=p;m.sibling=null}return p.child}function $_(h,p){return(h.lanes&p)!==0?!0:(h=h.dependencies,!!(h!==null&&Cm(h)))}function eX(h,p,m){switch(p.tag){case 3:be(p,p.stateNode.containerInfo),us(p,Ar,h.memoizedState.cache),Id();break;case 27:case 5:ze(p);break;case 4:be(p,p.stateNode.containerInfo);break;case 10:us(p,p.type,p.memoizedProps.value);break;case 13:var S=p.memoizedState;if(S!==null)return S.dehydrated!==null?(vs(p),p.flags|=128,null):(m&p.child.childLanes)!==0?KE(h,p,m):(vs(p),h=fo(h,p,m),h!==null?h.sibling:null);vs(p);break;case 19:var A=(h.flags&128)!==0;if(S=(m&p.childLanes)!==0,S||(Pd(h,p,m,!1),S=(m&p.childLanes)!==0),A){if(S)return JE(h,p,m);p.flags|=128}if(A=p.memoizedState,A!==null&&(A.rendering=null,A.tail=null,A.lastEffect=null),te(Mr,Mr.current),S)break;return null;case 22:case 23:return p.lanes=0,WE(h,p,m);case 24:us(p,Ar,h.memoizedState.cache)}return fo(h,p,m)}function ek(h,p,m){if(h!==null)if(h.memoizedProps!==p.pendingProps)Pr=!0;else{if(!$_(h,m)&&(p.flags&128)===0)return Pr=!1,eX(h,p,m);Pr=(h.flags&131072)!==0}else Pr=!1,Dt&&(p.flags&1048576)!==0&&LR(p,Tm,p.index);switch(p.lanes=0,p.tag){case 16:e:{h=p.pendingProps;var S=p.elementType,A=S._init;if(S=A(S._payload),p.type=S,typeof S=="function")i_(S)?(h=ql(S,h),p.tag=1,p=ZE(null,p,S,h,m)):(p.tag=0,p=F_(null,p,S,h,m));else{if(S!=null){if(A=S.$$typeof,A===C){p.tag=11,p=FE(null,p,S,h,m);break e}else if(A===N){p.tag=14,p=UE(null,p,S,h,m);break e}}throw p=H(S)||S,Error(n(306,p,""))}}return p;case 0:return F_(h,p,p.type,p.pendingProps,m);case 1:return S=p.type,A=ql(S,p.pendingProps),ZE(h,p,S,A,m);case 3:e:{if(be(p,p.stateNode.containerInfo),h===null)throw Error(n(387));S=p.pendingProps;var L=p.memoizedState;A=L.element,x_(h,p),Fd(p,S,null,m);var z=p.memoizedState;if(S=z.cache,us(p,Ar,S),S!==L.cache&&d_(p,[Ar],m,!0),Hd(),S=z.element,L.isDehydrated)if(L={element:S,isDehydrated:!1,cache:z.cache},p.updateQueue.baseState=L,p.memoizedState=L,p.flags&256){p=$E(h,p,S,m);break e}else if(S!==A){A=ha(Error(n(424)),p),Od(A),p=$E(h,p,S,m);break e}else{switch(h=p.stateNode.containerInfo,h.nodeType){case 9:h=h.body;break;default:h=h.nodeName==="HTML"?h.ownerDocument.body:h}for(tr=Ua(h.firstChild),gn=p,Dt=!0,Hl=null,fi=!0,m=EE(p,null,S,m),p.child=m;m;)m.flags=m.flags&-3|4096,m=m.sibling}else{if(Id(),S===A){p=fo(h,p,m);break e}Xr(h,p,S,m)}p=p.child}return p;case 26:return Um(h,p),h===null?(m=aI(p.type,null,p.pendingProps,null))?p.memoizedState=m:Dt||(m=p.type,h=p.pendingProps,S=iy(Se.current).createElement(m),S[on]=p,S[An]=h,Zr(S,m,h),Or(S),p.stateNode=S):p.memoizedState=aI(p.type,h.memoizedProps,p.pendingProps,h.memoizedState),null;case 27:return ze(p),h===null&&Dt&&(S=p.stateNode=tI(p.type,p.pendingProps,Se.current),gn=p,fi=!0,A=tr,Ts(p.type)?(LS=A,tr=Ua(S.firstChild)):tr=A),Xr(h,p,p.pendingProps.children,m),Um(h,p),h===null&&(p.flags|=4194304),p.child;case 5:return h===null&&Dt&&((A=S=tr)&&(S=DX(S,p.type,p.pendingProps,fi),S!==null?(p.stateNode=S,gn=p,tr=Ua(S.firstChild),fi=!1,A=!0):A=!1),A||Fl(p)),ze(p),A=p.type,L=p.pendingProps,z=h!==null?h.memoizedProps:null,S=L.children,AS(A,L)?S=null:z!==null&&AS(A,z)&&(p.flags|=32),p.memoizedState!==null&&(A=C_(h,p,WW,null,null,m),fv._currentValue=A),Um(h,p),Xr(h,p,S,m),p.child;case 6:return h===null&&Dt&&((h=m=tr)&&(m=NX(m,p.pendingProps,fi),m!==null?(p.stateNode=m,gn=p,tr=null,h=!0):h=!1),h||Fl(p)),null;case 13:return KE(h,p,m);case 4:return be(p,p.stateNode.containerInfo),S=p.pendingProps,h===null?p.child=Jc(p,null,S,m):Xr(h,p,S,m),p.child;case 11:return FE(h,p,p.type,p.pendingProps,m);case 7:return Xr(h,p,p.pendingProps,m),p.child;case 8:return Xr(h,p,p.pendingProps.children,m),p.child;case 12:return Xr(h,p,p.pendingProps.children,m),p.child;case 10:return S=p.pendingProps,us(p,p.type,S.value),Xr(h,p,S.children,m),p.child;case 9:return A=p.type._context,S=p.pendingProps.children,Yl(p),A=sn(A),S=S(A),p.flags|=1,Xr(h,p,S,m),p.child;case 14:return UE(h,p,p.type,p.pendingProps,m);case 15:return YE(h,p,p.type,p.pendingProps,m);case 19:return JE(h,p,m);case 31:return S=p.pendingProps,m=p.mode,S={mode:S.mode,children:S.children},h===null?(m=Ym(S,m),m.ref=p.ref,p.child=m,m.return=p,p=m):(m=ao(h.child,S),m.ref=p.ref,p.child=m,m.return=p,p=m),p;case 22:return WE(h,p,m);case 24:return Yl(p),S=sn(Ar),h===null?(A=g_(),A===null&&(A=Yt,L=v_(),A.pooledCache=L,L.refCount++,L!==null&&(A.pooledCacheLanes|=m),A=L),p.memoizedState={parent:S,cache:A},y_(p),us(p,Ar,A)):((h.lanes&m)!==0&&(x_(h,p),Fd(p,null,null,m),Hd()),A=h.memoizedState,L=p.memoizedState,A.parent!==S?(A={parent:S,cache:S},p.memoizedState=A,p.lanes===0&&(p.memoizedState=p.updateQueue.baseState=A),us(p,Ar,S)):(S=L.cache,us(p,Ar,S),S!==A.cache&&d_(p,[Ar],m,!0))),Xr(h,p,p.pendingProps.children,m),p.child;case 29:throw p.pendingProps}throw Error(n(156,p.tag))}function ho(h){h.flags|=4}function tk(h,p){if(p.type!=="stylesheet"||(p.state.loading&4)!==0)h.flags&=-16777217;else if(h.flags|=16777216,!uI(p)){if(p=ga.current,p!==null&&((wt&4194048)===wt?hi!==null:(wt&62914560)!==wt&&(wt&536870912)===0||p!==hi))throw Vd=m_,zR;h.flags|=8192}}function Wm(h,p){p!==null&&(h.flags|=4),h.flags&16384&&(p=h.tag!==22?kL():536870912,h.lanes|=p,nf|=p)}function $d(h,p){if(!Dt)switch(h.tailMode){case"hidden":p=h.tail;for(var m=null;p!==null;)p.alternate!==null&&(m=p),p=p.sibling;m===null?h.tail=null:m.sibling=null;break;case"collapsed":m=h.tail;for(var S=null;m!==null;)m.alternate!==null&&(S=m),m=m.sibling;S===null?p||h.tail===null?h.tail=null:h.tail.sibling=null:S.sibling=null}}function $t(h){var p=h.alternate!==null&&h.alternate.child===h.child,m=0,S=0;if(p)for(var A=h.child;A!==null;)m|=A.lanes|A.childLanes,S|=A.subtreeFlags&65011712,S|=A.flags&65011712,A.return=h,A=A.sibling;else for(A=h.child;A!==null;)m|=A.lanes|A.childLanes,S|=A.subtreeFlags,S|=A.flags,A.return=h,A=A.sibling;return h.subtreeFlags|=S,h.childLanes=m,p}function tX(h,p,m){var S=p.pendingProps;switch(u_(p),p.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return $t(p),null;case 1:return $t(p),null;case 3:return m=p.stateNode,S=null,h!==null&&(S=h.memoizedState.cache),p.memoizedState.cache!==S&&(p.flags|=2048),lo(Ar),we(),m.pendingContext&&(m.context=m.pendingContext,m.pendingContext=null),(h===null||h.child===null)&&(kd(p)?ho(p):h===null||h.memoizedState.isDehydrated&&(p.flags&256)===0||(p.flags|=1024,kR())),$t(p),null;case 26:return m=p.memoizedState,h===null?(ho(p),m!==null?($t(p),tk(p,m)):($t(p),p.flags&=-16777217)):m?m!==h.memoizedState?(ho(p),$t(p),tk(p,m)):($t(p),p.flags&=-16777217):(h.memoizedProps!==S&&ho(p),$t(p),p.flags&=-16777217),null;case 27:oe(p),m=Se.current;var A=p.type;if(h!==null&&p.stateNode!=null)h.memoizedProps!==S&&ho(p);else{if(!S){if(p.stateNode===null)throw Error(n(166));return $t(p),null}h=ue.current,kd(p)?RR(p):(h=tI(A,S,m),p.stateNode=h,ho(p))}return $t(p),null;case 5:if(oe(p),m=p.type,h!==null&&p.stateNode!=null)h.memoizedProps!==S&&ho(p);else{if(!S){if(p.stateNode===null)throw Error(n(166));return $t(p),null}if(h=ue.current,kd(p))RR(p);else{switch(A=iy(Se.current),h){case 1:h=A.createElementNS("http://www.w3.org/2000/svg",m);break;case 2:h=A.createElementNS("http://www.w3.org/1998/Math/MathML",m);break;default:switch(m){case"svg":h=A.createElementNS("http://www.w3.org/2000/svg",m);break;case"math":h=A.createElementNS("http://www.w3.org/1998/Math/MathML",m);break;case"script":h=A.createElement("div"),h.innerHTML="<script><\/script>",h=h.removeChild(h.firstChild);break;case"select":h=typeof S.is=="string"?A.createElement("select",{is:S.is}):A.createElement("select"),S.multiple?h.multiple=!0:S.size&&(h.size=S.size);break;default:h=typeof S.is=="string"?A.createElement(m,{is:S.is}):A.createElement(m)}}h[on]=p,h[An]=S;e:for(A=p.child;A!==null;){if(A.tag===5||A.tag===6)h.appendChild(A.stateNode);else if(A.tag!==4&&A.tag!==27&&A.child!==null){A.child.return=A,A=A.child;continue}if(A===p)break e;for(;A.sibling===null;){if(A.return===null||A.return===p)break e;A=A.return}A.sibling.return=A.return,A=A.sibling}p.stateNode=h;e:switch(Zr(h,m,S),m){case"button":case"input":case"select":case"textarea":h=!!S.autoFocus;break e;case"img":h=!0;break e;default:h=!1}h&&ho(p)}}return $t(p),p.flags&=-16777217,null;case 6:if(h&&p.stateNode!=null)h.memoizedProps!==S&&ho(p);else{if(typeof S!="string"&&p.stateNode===null)throw Error(n(166));if(h=Se.current,kd(p)){if(h=p.stateNode,m=p.memoizedProps,S=null,A=gn,A!==null)switch(A.tag){case 27:case 5:S=A.memoizedProps}h[on]=p,h=!!(h.nodeValue===m||S!==null&&S.suppressHydrationWarning===!0||qk(h.nodeValue,m)),h||Fl(p)}else h=iy(h).createTextNode(S),h[on]=p,p.stateNode=h}return $t(p),null;case 13:if(S=p.memoizedState,h===null||h.memoizedState!==null&&h.memoizedState.dehydrated!==null){if(A=kd(p),S!==null&&S.dehydrated!==null){if(h===null){if(!A)throw Error(n(318));if(A=p.memoizedState,A=A!==null?A.dehydrated:null,!A)throw Error(n(317));A[on]=p}else Id(),(p.flags&128)===0&&(p.memoizedState=null),p.flags|=4;$t(p),A=!1}else A=kR(),h!==null&&h.memoizedState!==null&&(h.memoizedState.hydrationErrors=A),A=!0;if(!A)return p.flags&256?(co(p),p):(co(p),null)}if(co(p),(p.flags&128)!==0)return p.lanes=m,p;if(m=S!==null,h=h!==null&&h.memoizedState!==null,m){S=p.child,A=null,S.alternate!==null&&S.alternate.memoizedState!==null&&S.alternate.memoizedState.cachePool!==null&&(A=S.alternate.memoizedState.cachePool.pool);var L=null;S.memoizedState!==null&&S.memoizedState.cachePool!==null&&(L=S.memoizedState.cachePool.pool),L!==A&&(S.flags|=2048)}return m!==h&&m&&(p.child.flags|=8192),Wm(p,p.updateQueue),$t(p),null;case 4:return we(),h===null&&_S(p.stateNode.containerInfo),$t(p),null;case 10:return lo(p.type),$t(p),null;case 19:if($(Mr),A=p.memoizedState,A===null)return $t(p),null;if(S=(p.flags&128)!==0,L=A.rendering,L===null)if(S)$d(A,!1);else{if(rr!==0||h!==null&&(h.flags&128)!==0)for(h=p.child;h!==null;){if(L=Gm(h),L!==null){for(p.flags|=128,$d(A,!1),h=L.updateQueue,p.updateQueue=h,Wm(p,h),p.subtreeFlags=0,h=m,m=p.child;m!==null;)NR(m,h),m=m.sibling;return te(Mr,Mr.current&1|2),p.child}h=h.sibling}A.tail!==null&&At()>Zm&&(p.flags|=128,S=!0,$d(A,!1),p.lanes=4194304)}else{if(!S)if(h=Gm(L),h!==null){if(p.flags|=128,S=!0,h=h.updateQueue,p.updateQueue=h,Wm(p,h),$d(A,!0),A.tail===null&&A.tailMode==="hidden"&&!L.alternate&&!Dt)return $t(p),null}else 2*At()-A.renderingStartTime>Zm&&m!==536870912&&(p.flags|=128,S=!0,$d(A,!1),p.lanes=4194304);A.isBackwards?(L.sibling=p.child,p.child=L):(h=A.last,h!==null?h.sibling=L:p.child=L,A.last=L)}return A.tail!==null?(p=A.tail,A.rendering=p,A.tail=p.sibling,A.renderingStartTime=At(),p.sibling=null,h=Mr.current,te(Mr,S?h&1|2:h&1),p):($t(p),null);case 22:case 23:return co(p),w_(),S=p.memoizedState!==null,h!==null?h.memoizedState!==null!==S&&(p.flags|=8192):S&&(p.flags|=8192),S?(m&536870912)!==0&&(p.flags&128)===0&&($t(p),p.subtreeFlags&6&&(p.flags|=8192)):$t(p),m=p.updateQueue,m!==null&&Wm(p,m.retryQueue),m=null,h!==null&&h.memoizedState!==null&&h.memoizedState.cachePool!==null&&(m=h.memoizedState.cachePool.pool),S=null,p.memoizedState!==null&&p.memoizedState.cachePool!==null&&(S=p.memoizedState.cachePool.pool),S!==m&&(p.flags|=2048),h!==null&&$(Wl),null;case 24:return m=null,h!==null&&(m=h.memoizedState.cache),p.memoizedState.cache!==m&&(p.flags|=2048),lo(Ar),$t(p),null;case 25:return null;case 30:return null}throw Error(n(156,p.tag))}function rX(h,p){switch(u_(p),p.tag){case 1:return h=p.flags,h&65536?(p.flags=h&-65537|128,p):null;case 3:return lo(Ar),we(),h=p.flags,(h&65536)!==0&&(h&128)===0?(p.flags=h&-65537|128,p):null;case 26:case 27:case 5:return oe(p),null;case 13:if(co(p),h=p.memoizedState,h!==null&&h.dehydrated!==null){if(p.alternate===null)throw Error(n(340));Id()}return h=p.flags,h&65536?(p.flags=h&-65537|128,p):null;case 19:return $(Mr),null;case 4:return we(),null;case 10:return lo(p.type),null;case 22:case 23:return co(p),w_(),h!==null&&$(Wl),h=p.flags,h&65536?(p.flags=h&-65537|128,p):null;case 24:return lo(Ar),null;case 25:return null;default:return null}}function rk(h,p){switch(u_(p),p.tag){case 3:lo(Ar),we();break;case 26:case 27:case 5:oe(p);break;case 4:we();break;case 13:co(p);break;case 19:$(Mr);break;case 10:lo(p.type);break;case 22:case 23:co(p),w_(),h!==null&&$(Wl);break;case 24:lo(Ar)}}function Kd(h,p){try{var m=p.updateQueue,S=m!==null?m.lastEffect:null;if(S!==null){var A=S.next;m=A;do{if((m.tag&h)===h){S=void 0;var L=m.create,z=m.inst;S=L(),z.destroy=S}m=m.next}while(m!==A)}}catch(Y){Ft(p,p.return,Y)}}function gs(h,p,m){try{var S=p.updateQueue,A=S!==null?S.lastEffect:null;if(A!==null){var L=A.next;S=L;do{if((S.tag&h)===h){var z=S.inst,Y=z.destroy;if(Y!==void 0){z.destroy=void 0,A=p;var Z=m,ae=Y;try{ae()}catch(he){Ft(A,Z,he)}}}S=S.next}while(S!==L)}}catch(he){Ft(p,p.return,he)}}function nk(h){var p=h.updateQueue;if(p!==null){var m=h.stateNode;try{UR(p,m)}catch(S){Ft(h,h.return,S)}}}function ak(h,p,m){m.props=ql(h.type,h.memoizedProps),m.state=h.memoizedState;try{m.componentWillUnmount()}catch(S){Ft(h,p,S)}}function Qd(h,p){try{var m=h.ref;if(m!==null){switch(h.tag){case 26:case 27:case 5:var S=h.stateNode;break;case 30:S=h.stateNode;break;default:S=h.stateNode}typeof m=="function"?h.refCleanup=m(S):m.current=S}}catch(A){Ft(h,p,A)}}function di(h,p){var m=h.ref,S=h.refCleanup;if(m!==null)if(typeof S=="function")try{S()}catch(A){Ft(h,p,A)}finally{h.refCleanup=null,h=h.alternate,h!=null&&(h.refCleanup=null)}else if(typeof m=="function")try{m(null)}catch(A){Ft(h,p,A)}else m.current=null}function ik(h){var p=h.type,m=h.memoizedProps,S=h.stateNode;try{e:switch(p){case"button":case"input":case"select":case"textarea":m.autoFocus&&S.focus();break e;case"img":m.src?S.src=m.src:m.srcSet&&(S.srcset=m.srcSet)}}catch(A){Ft(h,h.return,A)}}function K_(h,p,m){try{var S=h.stateNode;wX(S,h.type,m,p),S[An]=p}catch(A){Ft(h,h.return,A)}}function ok(h){return h.tag===5||h.tag===3||h.tag===26||h.tag===27&&Ts(h.type)||h.tag===4}function Q_(h){e:for(;;){for(;h.sibling===null;){if(h.return===null||ok(h.return))return null;h=h.return}for(h.sibling.return=h.return,h=h.sibling;h.tag!==5&&h.tag!==6&&h.tag!==18;){if(h.tag===27&&Ts(h.type)||h.flags&2||h.child===null||h.tag===4)continue e;h.child.return=h,h=h.child}if(!(h.flags&2))return h.stateNode}}function J_(h,p,m){var S=h.tag;if(S===5||S===6)h=h.stateNode,p?(m.nodeType===9?m.body:m.nodeName==="HTML"?m.ownerDocument.body:m).insertBefore(h,p):(p=m.nodeType===9?m.body:m.nodeName==="HTML"?m.ownerDocument.body:m,p.appendChild(h),m=m._reactRootContainer,m!=null||p.onclick!==null||(p.onclick=ay));else if(S!==4&&(S===27&&Ts(h.type)&&(m=h.stateNode,p=null),h=h.child,h!==null))for(J_(h,p,m),h=h.sibling;h!==null;)J_(h,p,m),h=h.sibling}function Xm(h,p,m){var S=h.tag;if(S===5||S===6)h=h.stateNode,p?m.insertBefore(h,p):m.appendChild(h);else if(S!==4&&(S===27&&Ts(h.type)&&(m=h.stateNode),h=h.child,h!==null))for(Xm(h,p,m),h=h.sibling;h!==null;)Xm(h,p,m),h=h.sibling}function sk(h){var p=h.stateNode,m=h.memoizedProps;try{for(var S=h.type,A=p.attributes;A.length;)p.removeAttributeNode(A[0]);Zr(p,S,m),p[on]=h,p[An]=m}catch(L){Ft(h,h.return,L)}}var vo=!1,fr=!1,eS=!1,lk=typeof WeakSet=="function"?WeakSet:Set,jr=null;function nX(h,p){if(h=h.containerInfo,TS=fy,h=xR(h),Qb(h)){if("selectionStart"in h)var m={start:h.selectionStart,end:h.selectionEnd};else e:{m=(m=h.ownerDocument)&&m.defaultView||window;var S=m.getSelection&&m.getSelection();if(S&&S.rangeCount!==0){m=S.anchorNode;var A=S.anchorOffset,L=S.focusNode;S=S.focusOffset;try{m.nodeType,L.nodeType}catch{m=null;break e}var z=0,Y=-1,Z=-1,ae=0,he=0,ve=h,se=null;t:for(;;){for(var le;ve!==m||A!==0&&ve.nodeType!==3||(Y=z+A),ve!==L||S!==0&&ve.nodeType!==3||(Z=z+S),ve.nodeType===3&&(z+=ve.nodeValue.length),(le=ve.firstChild)!==null;)se=ve,ve=le;for(;;){if(ve===h)break t;if(se===m&&++ae===A&&(Y=z),se===L&&++he===S&&(Z=z),(le=ve.nextSibling)!==null)break;ve=se,se=ve.parentNode}ve=le}m=Y===-1||Z===-1?null:{start:Y,end:Z}}else m=null}m=m||{start:0,end:0}}else m=null;for(CS={focusedElem:h,selectionRange:m},fy=!1,jr=p;jr!==null;)if(p=jr,h=p.child,(p.subtreeFlags&1024)!==0&&h!==null)h.return=p,jr=h;else for(;jr!==null;){switch(p=jr,L=p.alternate,h=p.flags,p.tag){case 0:break;case 11:case 15:break;case 1:if((h&1024)!==0&&L!==null){h=void 0,m=p,A=L.memoizedProps,L=L.memoizedState,S=m.stateNode;try{var rt=ql(m.type,A,m.elementType===m.type);h=S.getSnapshotBeforeUpdate(rt,L),S.__reactInternalSnapshotBeforeUpdate=h}catch(Ze){Ft(m,m.return,Ze)}}break;case 3:if((h&1024)!==0){if(h=p.stateNode.containerInfo,m=h.nodeType,m===9)DS(h);else if(m===1)switch(h.nodeName){case"HEAD":case"HTML":case"BODY":DS(h);break;default:h.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((h&1024)!==0)throw Error(n(163))}if(h=p.sibling,h!==null){h.return=p.return,jr=h;break}jr=p.return}}function uk(h,p,m){var S=m.flags;switch(m.tag){case 0:case 11:case 15:ms(h,m),S&4&&Kd(5,m);break;case 1:if(ms(h,m),S&4)if(h=m.stateNode,p===null)try{h.componentDidMount()}catch(z){Ft(m,m.return,z)}else{var A=ql(m.type,p.memoizedProps);p=p.memoizedState;try{h.componentDidUpdate(A,p,h.__reactInternalSnapshotBeforeUpdate)}catch(z){Ft(m,m.return,z)}}S&64&&nk(m),S&512&&Qd(m,m.return);break;case 3:if(ms(h,m),S&64&&(h=m.updateQueue,h!==null)){if(p=null,m.child!==null)switch(m.child.tag){case 27:case 5:p=m.child.stateNode;break;case 1:p=m.child.stateNode}try{UR(h,p)}catch(z){Ft(m,m.return,z)}}break;case 27:p===null&&S&4&&sk(m);case 26:case 5:ms(h,m),p===null&&S&4&&ik(m),S&512&&Qd(m,m.return);break;case 12:ms(h,m);break;case 13:ms(h,m),S&4&&hk(h,m),S&64&&(h=m.memoizedState,h!==null&&(h=h.dehydrated,h!==null&&(m=hX.bind(null,m),LX(h,m))));break;case 22:if(S=m.memoizedState!==null||vo,!S){p=p!==null&&p.memoizedState!==null||fr,A=vo;var L=fr;vo=S,(fr=p)&&!L?ys(h,m,(m.subtreeFlags&8772)!==0):ms(h,m),vo=A,fr=L}break;case 30:break;default:ms(h,m)}}function ck(h){var p=h.alternate;p!==null&&(h.alternate=null,ck(p)),h.child=null,h.deletions=null,h.sibling=null,h.tag===5&&(p=h.stateNode,p!==null&&kb(p)),h.stateNode=null,h.return=null,h.dependencies=null,h.memoizedProps=null,h.memoizedState=null,h.pendingProps=null,h.stateNode=null,h.updateQueue=null}var qt=null,Nn=!1;function po(h,p,m){for(m=m.child;m!==null;)fk(h,p,m),m=m.sibling}function fk(h,p,m){if(Vn&&typeof Vn.onCommitFiberUnmount=="function")try{Vn.onCommitFiberUnmount(xd,m)}catch{}switch(m.tag){case 26:fr||di(m,p),po(h,p,m),m.memoizedState?m.memoizedState.count--:m.stateNode&&(m=m.stateNode,m.parentNode.removeChild(m));break;case 27:fr||di(m,p);var S=qt,A=Nn;Ts(m.type)&&(qt=m.stateNode,Nn=!1),po(h,p,m),sv(m.stateNode),qt=S,Nn=A;break;case 5:fr||di(m,p);case 6:if(S=qt,A=Nn,qt=null,po(h,p,m),qt=S,Nn=A,qt!==null)if(Nn)try{(qt.nodeType===9?qt.body:qt.nodeName==="HTML"?qt.ownerDocument.body:qt).removeChild(m.stateNode)}catch(L){Ft(m,p,L)}else try{qt.removeChild(m.stateNode)}catch(L){Ft(m,p,L)}break;case 18:qt!==null&&(Nn?(h=qt,Jk(h.nodeType===9?h.body:h.nodeName==="HTML"?h.ownerDocument.body:h,m.stateNode),pv(h)):Jk(qt,m.stateNode));break;case 4:S=qt,A=Nn,qt=m.stateNode.containerInfo,Nn=!0,po(h,p,m),qt=S,Nn=A;break;case 0:case 11:case 14:case 15:fr||gs(2,m,p),fr||gs(4,m,p),po(h,p,m);break;case 1:fr||(di(m,p),S=m.stateNode,typeof S.componentWillUnmount=="function"&&ak(m,p,S)),po(h,p,m);break;case 21:po(h,p,m);break;case 22:fr=(S=fr)||m.memoizedState!==null,po(h,p,m),fr=S;break;default:po(h,p,m)}}function hk(h,p){if(p.memoizedState===null&&(h=p.alternate,h!==null&&(h=h.memoizedState,h!==null&&(h=h.dehydrated,h!==null))))try{pv(h)}catch(m){Ft(p,p.return,m)}}function aX(h){switch(h.tag){case 13:case 19:var p=h.stateNode;return p===null&&(p=h.stateNode=new lk),p;case 22:return h=h.stateNode,p=h._retryCache,p===null&&(p=h._retryCache=new lk),p;default:throw Error(n(435,h.tag))}}function tS(h,p){var m=aX(h);p.forEach(function(S){var A=dX.bind(null,h,S);m.has(S)||(m.add(S),S.then(A,A))})}function Un(h,p){var m=p.deletions;if(m!==null)for(var S=0;S<m.length;S++){var A=m[S],L=h,z=p,Y=z;e:for(;Y!==null;){switch(Y.tag){case 27:if(Ts(Y.type)){qt=Y.stateNode,Nn=!1;break e}break;case 5:qt=Y.stateNode,Nn=!1;break e;case 3:case 4:qt=Y.stateNode.containerInfo,Nn=!0;break e}Y=Y.return}if(qt===null)throw Error(n(160));fk(L,z,A),qt=null,Nn=!1,L=A.alternate,L!==null&&(L.return=null),A.return=null}if(p.subtreeFlags&13878)for(p=p.child;p!==null;)dk(p,h),p=p.sibling}var Fa=null;function dk(h,p){var m=h.alternate,S=h.flags;switch(h.tag){case 0:case 11:case 14:case 15:Un(p,h),Yn(h),S&4&&(gs(3,h,h.return),Kd(3,h),gs(5,h,h.return));break;case 1:Un(p,h),Yn(h),S&512&&(fr||m===null||di(m,m.return)),S&64&&vo&&(h=h.updateQueue,h!==null&&(S=h.callbacks,S!==null&&(m=h.shared.hiddenCallbacks,h.shared.hiddenCallbacks=m===null?S:m.concat(S))));break;case 26:var A=Fa;if(Un(p,h),Yn(h),S&512&&(fr||m===null||di(m,m.return)),S&4){var L=m!==null?m.memoizedState:null;if(S=h.memoizedState,m===null)if(S===null)if(h.stateNode===null){e:{S=h.type,m=h.memoizedProps,A=A.ownerDocument||A;t:switch(S){case"title":L=A.getElementsByTagName("title")[0],(!L||L[Sd]||L[on]||L.namespaceURI==="http://www.w3.org/2000/svg"||L.hasAttribute("itemprop"))&&(L=A.createElement(S),A.head.insertBefore(L,A.querySelector("head > title"))),Zr(L,S,m),L[on]=h,Or(L),S=L;break e;case"link":var z=sI("link","href",A).get(S+(m.href||""));if(z){for(var Y=0;Y<z.length;Y++)if(L=z[Y],L.getAttribute("href")===(m.href==null||m.href===""?null:m.href)&&L.getAttribute("rel")===(m.rel==null?null:m.rel)&&L.getAttribute("title")===(m.title==null?null:m.title)&&L.getAttribute("crossorigin")===(m.crossOrigin==null?null:m.crossOrigin)){z.splice(Y,1);break t}}L=A.createElement(S),Zr(L,S,m),A.head.appendChild(L);break;case"meta":if(z=sI("meta","content",A).get(S+(m.content||""))){for(Y=0;Y<z.length;Y++)if(L=z[Y],L.getAttribute("content")===(m.content==null?null:""+m.content)&&L.getAttribute("name")===(m.name==null?null:m.name)&&L.getAttribute("property")===(m.property==null?null:m.property)&&L.getAttribute("http-equiv")===(m.httpEquiv==null?null:m.httpEquiv)&&L.getAttribute("charset")===(m.charSet==null?null:m.charSet)){z.splice(Y,1);break t}}L=A.createElement(S),Zr(L,S,m),A.head.appendChild(L);break;default:throw Error(n(468,S))}L[on]=h,Or(L),S=L}h.stateNode=S}else lI(A,h.type,h.stateNode);else h.stateNode=oI(A,S,h.memoizedProps);else L!==S?(L===null?m.stateNode!==null&&(m=m.stateNode,m.parentNode.removeChild(m)):L.count--,S===null?lI(A,h.type,h.stateNode):oI(A,S,h.memoizedProps)):S===null&&h.stateNode!==null&&K_(h,h.memoizedProps,m.memoizedProps)}break;case 27:Un(p,h),Yn(h),S&512&&(fr||m===null||di(m,m.return)),m!==null&&S&4&&K_(h,h.memoizedProps,m.memoizedProps);break;case 5:if(Un(p,h),Yn(h),S&512&&(fr||m===null||di(m,m.return)),h.flags&32){A=h.stateNode;try{Oc(A,"")}catch(le){Ft(h,h.return,le)}}S&4&&h.stateNode!=null&&(A=h.memoizedProps,K_(h,A,m!==null?m.memoizedProps:A)),S&1024&&(eS=!0);break;case 6:if(Un(p,h),Yn(h),S&4){if(h.stateNode===null)throw Error(n(162));S=h.memoizedProps,m=h.stateNode;try{m.nodeValue=S}catch(le){Ft(h,h.return,le)}}break;case 3:if(ly=null,A=Fa,Fa=oy(p.containerInfo),Un(p,h),Fa=A,Yn(h),S&4&&m!==null&&m.memoizedState.isDehydrated)try{pv(p.containerInfo)}catch(le){Ft(h,h.return,le)}eS&&(eS=!1,vk(h));break;case 4:S=Fa,Fa=oy(h.stateNode.containerInfo),Un(p,h),Yn(h),Fa=S;break;case 12:Un(p,h),Yn(h);break;case 13:Un(p,h),Yn(h),h.child.flags&8192&&h.memoizedState!==null!=(m!==null&&m.memoizedState!==null)&&(sS=At()),S&4&&(S=h.updateQueue,S!==null&&(h.updateQueue=null,tS(h,S)));break;case 22:A=h.memoizedState!==null;var Z=m!==null&&m.memoizedState!==null,ae=vo,he=fr;if(vo=ae||A,fr=he||Z,Un(p,h),fr=he,vo=ae,Yn(h),S&8192)e:for(p=h.stateNode,p._visibility=A?p._visibility&-2:p._visibility|1,A&&(m===null||Z||vo||fr||Zl(h)),m=null,p=h;;){if(p.tag===5||p.tag===26){if(m===null){Z=m=p;try{if(L=Z.stateNode,A)z=L.style,typeof z.setProperty=="function"?z.setProperty("display","none","important"):z.display="none";else{Y=Z.stateNode;var ve=Z.memoizedProps.style,se=ve!=null&&ve.hasOwnProperty("display")?ve.display:null;Y.style.display=se==null||typeof se=="boolean"?"":(""+se).trim()}}catch(le){Ft(Z,Z.return,le)}}}else if(p.tag===6){if(m===null){Z=p;try{Z.stateNode.nodeValue=A?"":Z.memoizedProps}catch(le){Ft(Z,Z.return,le)}}}else if((p.tag!==22&&p.tag!==23||p.memoizedState===null||p===h)&&p.child!==null){p.child.return=p,p=p.child;continue}if(p===h)break e;for(;p.sibling===null;){if(p.return===null||p.return===h)break e;m===p&&(m=null),p=p.return}m===p&&(m=null),p.sibling.return=p.return,p=p.sibling}S&4&&(S=h.updateQueue,S!==null&&(m=S.retryQueue,m!==null&&(S.retryQueue=null,tS(h,m))));break;case 19:Un(p,h),Yn(h),S&4&&(S=h.updateQueue,S!==null&&(h.updateQueue=null,tS(h,S)));break;case 30:break;case 21:break;default:Un(p,h),Yn(h)}}function Yn(h){var p=h.flags;if(p&2){try{for(var m,S=h.return;S!==null;){if(ok(S)){m=S;break}S=S.return}if(m==null)throw Error(n(160));switch(m.tag){case 27:var A=m.stateNode,L=Q_(h);Xm(h,L,A);break;case 5:var z=m.stateNode;m.flags&32&&(Oc(z,""),m.flags&=-33);var Y=Q_(h);Xm(h,Y,z);break;case 3:case 4:var Z=m.stateNode.containerInfo,ae=Q_(h);J_(h,ae,Z);break;default:throw Error(n(161))}}catch(he){Ft(h,h.return,he)}h.flags&=-3}p&4096&&(h.flags&=-4097)}function vk(h){if(h.subtreeFlags&1024)for(h=h.child;h!==null;){var p=h;vk(p),p.tag===5&&p.flags&1024&&p.stateNode.reset(),h=h.sibling}}function ms(h,p){if(p.subtreeFlags&8772)for(p=p.child;p!==null;)uk(h,p.alternate,p),p=p.sibling}function Zl(h){for(h=h.child;h!==null;){var p=h;switch(p.tag){case 0:case 11:case 14:case 15:gs(4,p,p.return),Zl(p);break;case 1:di(p,p.return);var m=p.stateNode;typeof m.componentWillUnmount=="function"&&ak(p,p.return,m),Zl(p);break;case 27:sv(p.stateNode);case 26:case 5:di(p,p.return),Zl(p);break;case 22:p.memoizedState===null&&Zl(p);break;case 30:Zl(p);break;default:Zl(p)}h=h.sibling}}function ys(h,p,m){for(m=m&&(p.subtreeFlags&8772)!==0,p=p.child;p!==null;){var S=p.alternate,A=h,L=p,z=L.flags;switch(L.tag){case 0:case 11:case 15:ys(A,L,m),Kd(4,L);break;case 1:if(ys(A,L,m),S=L,A=S.stateNode,typeof A.componentDidMount=="function")try{A.componentDidMount()}catch(ae){Ft(S,S.return,ae)}if(S=L,A=S.updateQueue,A!==null){var Y=S.stateNode;try{var Z=A.shared.hiddenCallbacks;if(Z!==null)for(A.shared.hiddenCallbacks=null,A=0;A<Z.length;A++)FR(Z[A],Y)}catch(ae){Ft(S,S.return,ae)}}m&&z&64&&nk(L),Qd(L,L.return);break;case 27:sk(L);case 26:case 5:ys(A,L,m),m&&S===null&&z&4&&ik(L),Qd(L,L.return);break;case 12:ys(A,L,m);break;case 13:ys(A,L,m),m&&z&4&&hk(A,L);break;case 22:L.memoizedState===null&&ys(A,L,m),Qd(L,L.return);break;case 30:break;default:ys(A,L,m)}p=p.sibling}}function rS(h,p){var m=null;h!==null&&h.memoizedState!==null&&h.memoizedState.cachePool!==null&&(m=h.memoizedState.cachePool.pool),h=null,p.memoizedState!==null&&p.memoizedState.cachePool!==null&&(h=p.memoizedState.cachePool.pool),h!==m&&(h!=null&&h.refCount++,m!=null&&jd(m))}function nS(h,p){h=null,p.alternate!==null&&(h=p.alternate.memoizedState.cache),p=p.memoizedState.cache,p!==h&&(p.refCount++,h!=null&&jd(h))}function vi(h,p,m,S){if(p.subtreeFlags&10256)for(p=p.child;p!==null;)pk(h,p,m,S),p=p.sibling}function pk(h,p,m,S){var A=p.flags;switch(p.tag){case 0:case 11:case 15:vi(h,p,m,S),A&2048&&Kd(9,p);break;case 1:vi(h,p,m,S);break;case 3:vi(h,p,m,S),A&2048&&(h=null,p.alternate!==null&&(h=p.alternate.memoizedState.cache),p=p.memoizedState.cache,p!==h&&(p.refCount++,h!=null&&jd(h)));break;case 12:if(A&2048){vi(h,p,m,S),h=p.stateNode;try{var L=p.memoizedProps,z=L.id,Y=L.onPostCommit;typeof Y=="function"&&Y(z,p.alternate===null?"mount":"update",h.passiveEffectDuration,-0)}catch(Z){Ft(p,p.return,Z)}}else vi(h,p,m,S);break;case 13:vi(h,p,m,S);break;case 23:break;case 22:L=p.stateNode,z=p.alternate,p.memoizedState!==null?L._visibility&2?vi(h,p,m,S):Jd(h,p):L._visibility&2?vi(h,p,m,S):(L._visibility|=2,ef(h,p,m,S,(p.subtreeFlags&10256)!==0)),A&2048&&rS(z,p);break;case 24:vi(h,p,m,S),A&2048&&nS(p.alternate,p);break;default:vi(h,p,m,S)}}function ef(h,p,m,S,A){for(A=A&&(p.subtreeFlags&10256)!==0,p=p.child;p!==null;){var L=h,z=p,Y=m,Z=S,ae=z.flags;switch(z.tag){case 0:case 11:case 15:ef(L,z,Y,Z,A),Kd(8,z);break;case 23:break;case 22:var he=z.stateNode;z.memoizedState!==null?he._visibility&2?ef(L,z,Y,Z,A):Jd(L,z):(he._visibility|=2,ef(L,z,Y,Z,A)),A&&ae&2048&&rS(z.alternate,z);break;case 24:ef(L,z,Y,Z,A),A&&ae&2048&&nS(z.alternate,z);break;default:ef(L,z,Y,Z,A)}p=p.sibling}}function Jd(h,p){if(p.subtreeFlags&10256)for(p=p.child;p!==null;){var m=h,S=p,A=S.flags;switch(S.tag){case 22:Jd(m,S),A&2048&&rS(S.alternate,S);break;case 24:Jd(m,S),A&2048&&nS(S.alternate,S);break;default:Jd(m,S)}p=p.sibling}}var ev=8192;function tf(h){if(h.subtreeFlags&ev)for(h=h.child;h!==null;)gk(h),h=h.sibling}function gk(h){switch(h.tag){case 26:tf(h),h.flags&ev&&h.memoizedState!==null&&FX(Fa,h.memoizedState,h.memoizedProps);break;case 5:tf(h);break;case 3:case 4:var p=Fa;Fa=oy(h.stateNode.containerInfo),tf(h),Fa=p;break;case 22:h.memoizedState===null&&(p=h.alternate,p!==null&&p.memoizedState!==null?(p=ev,ev=16777216,tf(h),ev=p):tf(h));break;default:tf(h)}}function mk(h){var p=h.alternate;if(p!==null&&(h=p.child,h!==null)){p.child=null;do p=h.sibling,h.sibling=null,h=p;while(h!==null)}}function tv(h){var p=h.deletions;if((h.flags&16)!==0){if(p!==null)for(var m=0;m<p.length;m++){var S=p[m];jr=S,xk(S,h)}mk(h)}if(h.subtreeFlags&10256)for(h=h.child;h!==null;)yk(h),h=h.sibling}function yk(h){switch(h.tag){case 0:case 11:case 15:tv(h),h.flags&2048&&gs(9,h,h.return);break;case 3:tv(h);break;case 12:tv(h);break;case 22:var p=h.stateNode;h.memoizedState!==null&&p._visibility&2&&(h.return===null||h.return.tag!==13)?(p._visibility&=-3,qm(h)):tv(h);break;default:tv(h)}}function qm(h){var p=h.deletions;if((h.flags&16)!==0){if(p!==null)for(var m=0;m<p.length;m++){var S=p[m];jr=S,xk(S,h)}mk(h)}for(h=h.child;h!==null;){switch(p=h,p.tag){case 0:case 11:case 15:gs(8,p,p.return),qm(p);break;case 22:m=p.stateNode,m._visibility&2&&(m._visibility&=-3,qm(p));break;default:qm(p)}h=h.sibling}}function xk(h,p){for(;jr!==null;){var m=jr;switch(m.tag){case 0:case 11:case 15:gs(8,m,p);break;case 23:case 22:if(m.memoizedState!==null&&m.memoizedState.cachePool!==null){var S=m.memoizedState.cachePool.pool;S!=null&&S.refCount++}break;case 24:jd(m.memoizedState.cache)}if(S=m.child,S!==null)S.return=m,jr=S;else e:for(m=h;jr!==null;){S=jr;var A=S.sibling,L=S.return;if(ck(S),S===m){jr=null;break e}if(A!==null){A.return=L,jr=A;break e}jr=L}}}var iX={getCacheForType:function(h){var p=sn(Ar),m=p.data.get(h);return m===void 0&&(m=h(),p.data.set(h,m)),m}},oX=typeof WeakMap=="function"?WeakMap:Map,It=0,Yt=null,mt=null,wt=0,Ot=0,Wn=null,xs=!1,rf=!1,aS=!1,go=0,rr=0,bs=0,$l=0,iS=0,ma=0,nf=0,rv=null,Ln=null,oS=!1,sS=0,Zm=1/0,$m=null,_s=null,qr=0,Ss=null,af=null,of=0,lS=0,uS=null,bk=null,nv=0,cS=null;function Xn(){if((It&2)!==0&&wt!==0)return wt&-wt;if(j.T!==null){var h=Wc;return h!==0?h:mS()}return PL()}function _k(){ma===0&&(ma=(wt&536870912)===0||Dt?EL():536870912);var h=ga.current;return h!==null&&(h.flags|=32),ma}function qn(h,p,m){(h===Yt&&(Ot===2||Ot===9)||h.cancelPendingCommit!==null)&&(sf(h,0),ws(h,wt,ma,!1)),_d(h,m),((It&2)===0||h!==Yt)&&(h===Yt&&((It&2)===0&&($l|=m),rr===4&&ws(h,wt,ma,!1)),pi(h))}function Sk(h,p,m){if((It&6)!==0)throw Error(n(327));var S=!m&&(p&124)===0&&(p&h.expiredLanes)===0||bd(h,p),A=S?uX(h,p):dS(h,p,!0),L=S;do{if(A===0){rf&&!S&&ws(h,p,0,!1);break}else{if(m=h.current.alternate,L&&!sX(m)){A=dS(h,p,!1),L=!1;continue}if(A===2){if(L=p,h.errorRecoveryDisabledLanes&L)var z=0;else z=h.pendingLanes&-536870913,z=z!==0?z:z&536870912?536870912:0;if(z!==0){p=z;e:{var Y=h;A=rv;var Z=Y.current.memoizedState.isDehydrated;if(Z&&(sf(Y,z).flags|=256),z=dS(Y,z,!1),z!==2){if(aS&&!Z){Y.errorRecoveryDisabledLanes|=L,$l|=L,A=4;break e}L=Ln,Ln=A,L!==null&&(Ln===null?Ln=L:Ln.push.apply(Ln,L))}A=z}if(L=!1,A!==2)continue}}if(A===1){sf(h,0),ws(h,p,0,!0);break}e:{switch(S=h,L=A,L){case 0:case 1:throw Error(n(345));case 4:if((p&4194048)!==p)break;case 6:ws(S,p,ma,!xs);break e;case 2:Ln=null;break;case 3:case 5:break;default:throw Error(n(329))}if((p&62914560)===p&&(A=sS+300-At(),10<A)){if(ws(S,p,ma,!xs),sm(S,0,!0)!==0)break e;S.timeoutHandle=Kk(wk.bind(null,S,m,Ln,$m,oS,p,ma,$l,nf,xs,L,2,-0,0),A);break e}wk(S,m,Ln,$m,oS,p,ma,$l,nf,xs,L,0,-0,0)}}break}while(!0);pi(h)}function wk(h,p,m,S,A,L,z,Y,Z,ae,he,ve,se,le){if(h.timeoutHandle=-1,ve=p.subtreeFlags,(ve&8192||(ve&16785408)===16785408)&&(cv={stylesheets:null,count:0,unsuspend:HX},gk(p),ve=UX(),ve!==null)){h.cancelPendingCommit=ve(Lk.bind(null,h,p,L,m,S,A,z,Y,Z,he,1,se,le)),ws(h,L,z,!ae);return}Lk(h,p,L,m,S,A,z,Y,Z)}function sX(h){for(var p=h;;){var m=p.tag;if((m===0||m===11||m===15)&&p.flags&16384&&(m=p.updateQueue,m!==null&&(m=m.stores,m!==null)))for(var S=0;S<m.length;S++){var A=m[S],L=A.getSnapshot;A=A.value;try{if(!Hn(L(),A))return!1}catch{return!1}}if(m=p.child,p.subtreeFlags&16384&&m!==null)m.return=p,p=m;else{if(p===h)break;for(;p.sibling===null;){if(p.return===null||p.return===h)return!0;p=p.return}p.sibling.return=p.return,p=p.sibling}}return!0}function ws(h,p,m,S){p&=~iS,p&=~$l,h.suspendedLanes|=p,h.pingedLanes&=~p,S&&(h.warmLanes|=p),S=h.expirationTimes;for(var A=p;0<A;){var L=31-Gn(A),z=1<<L;S[L]=-1,A&=~z}m!==0&&IL(h,m,p)}function Km(){return(It&6)===0?(av(0),!1):!0}function fS(){if(mt!==null){if(Ot===0)var h=mt.return;else h=mt,so=Ul=null,D_(h),Qc=null,qd=0,h=mt;for(;h!==null;)rk(h.alternate,h),h=h.return;mt=null}}function sf(h,p){var m=h.timeoutHandle;m!==-1&&(h.timeoutHandle=-1,CX(m)),m=h.cancelPendingCommit,m!==null&&(h.cancelPendingCommit=null,m()),fS(),Yt=h,mt=m=ao(h.current,null),wt=p,Ot=0,Wn=null,xs=!1,rf=bd(h,p),aS=!1,nf=ma=iS=$l=bs=rr=0,Ln=rv=null,oS=!1,(p&8)!==0&&(p|=p&32);var S=h.entangledLanes;if(S!==0)for(h=h.entanglements,S&=p;0<S;){var A=31-Gn(S),L=1<<A;p|=h[A],S&=~L}return go=p,xm(),m}function Tk(h,p){ht=null,j.H=zm,p===Bd||p===Dm?(p=GR(),Ot=3):p===zR?(p=GR(),Ot=4):Ot=p===HE?8:p!==null&&typeof p=="object"&&typeof p.then=="function"?6:1,Wn=p,mt===null&&(rr=1,Fm(h,ha(p,h.current)))}function Ck(){var h=j.H;return j.H=zm,h===null?zm:h}function Ak(){var h=j.A;return j.A=iX,h}function hS(){rr=4,xs||(wt&4194048)!==wt&&ga.current!==null||(rf=!0),(bs&134217727)===0&&($l&134217727)===0||Yt===null||ws(Yt,wt,ma,!1)}function dS(h,p,m){var S=It;It|=2;var A=Ck(),L=Ak();(Yt!==h||wt!==p)&&($m=null,sf(h,p)),p=!1;var z=rr;e:do try{if(Ot!==0&&mt!==null){var Y=mt,Z=Wn;switch(Ot){case 8:fS(),z=6;break e;case 3:case 2:case 9:case 6:ga.current===null&&(p=!0);var ae=Ot;if(Ot=0,Wn=null,lf(h,Y,Z,ae),m&&rf){z=0;break e}break;default:ae=Ot,Ot=0,Wn=null,lf(h,Y,Z,ae)}}lX(),z=rr;break}catch(he){Tk(h,he)}while(!0);return p&&h.shellSuspendCounter++,so=Ul=null,It=S,j.H=A,j.A=L,mt===null&&(Yt=null,wt=0,xm()),z}function lX(){for(;mt!==null;)Mk(mt)}function uX(h,p){var m=It;It|=2;var S=Ck(),A=Ak();Yt!==h||wt!==p?($m=null,Zm=At()+500,sf(h,p)):rf=bd(h,p);e:do try{if(Ot!==0&&mt!==null){p=mt;var L=Wn;t:switch(Ot){case 1:Ot=0,Wn=null,lf(h,p,L,1);break;case 2:case 9:if(BR(L)){Ot=0,Wn=null,Dk(p);break}p=function(){Ot!==2&&Ot!==9||Yt!==h||(Ot=7),pi(h)},L.then(p,p);break e;case 3:Ot=7;break e;case 4:Ot=5;break e;case 7:BR(L)?(Ot=0,Wn=null,Dk(p)):(Ot=0,Wn=null,lf(h,p,L,7));break;case 5:var z=null;switch(mt.tag){case 26:z=mt.memoizedState;case 5:case 27:var Y=mt;if(!z||uI(z)){Ot=0,Wn=null;var Z=Y.sibling;if(Z!==null)mt=Z;else{var ae=Y.return;ae!==null?(mt=ae,Qm(ae)):mt=null}break t}}Ot=0,Wn=null,lf(h,p,L,5);break;case 6:Ot=0,Wn=null,lf(h,p,L,6);break;case 8:fS(),rr=6;break e;default:throw Error(n(462))}}cX();break}catch(he){Tk(h,he)}while(!0);return so=Ul=null,j.H=S,j.A=A,It=m,mt!==null?0:(Yt=null,wt=0,xm(),rr)}function cX(){for(;mt!==null&&!at();)Mk(mt)}function Mk(h){var p=ek(h.alternate,h,go);h.memoizedProps=h.pendingProps,p===null?Qm(h):mt=p}function Dk(h){var p=h,m=p.alternate;switch(p.tag){case 15:case 0:p=qE(m,p,p.pendingProps,p.type,void 0,wt);break;case 11:p=qE(m,p,p.pendingProps,p.type.render,p.ref,wt);break;case 5:D_(p);default:rk(m,p),p=mt=NR(p,go),p=ek(m,p,go)}h.memoizedProps=h.pendingProps,p===null?Qm(h):mt=p}function lf(h,p,m,S){so=Ul=null,D_(p),Qc=null,qd=0;var A=p.return;try{if(JW(h,A,p,m,wt)){rr=1,Fm(h,ha(m,h.current)),mt=null;return}}catch(L){if(A!==null)throw mt=A,L;rr=1,Fm(h,ha(m,h.current)),mt=null;return}p.flags&32768?(Dt||S===1?h=!0:rf||(wt&536870912)!==0?h=!1:(xs=h=!0,(S===2||S===9||S===3||S===6)&&(S=ga.current,S!==null&&S.tag===13&&(S.flags|=16384))),Nk(p,h)):Qm(p)}function Qm(h){var p=h;do{if((p.flags&32768)!==0){Nk(p,xs);return}h=p.return;var m=tX(p.alternate,p,go);if(m!==null){mt=m;return}if(p=p.sibling,p!==null){mt=p;return}mt=p=h}while(p!==null);rr===0&&(rr=5)}function Nk(h,p){do{var m=rX(h.alternate,h);if(m!==null){m.flags&=32767,mt=m;return}if(m=h.return,m!==null&&(m.flags|=32768,m.subtreeFlags=0,m.deletions=null),!p&&(h=h.sibling,h!==null)){mt=h;return}mt=h=m}while(h!==null);rr=6,mt=null}function Lk(h,p,m,S,A,L,z,Y,Z){h.cancelPendingCommit=null;do Jm();while(qr!==0);if((It&6)!==0)throw Error(n(327));if(p!==null){if(p===h.current)throw Error(n(177));if(L=p.lanes|p.childLanes,L|=n_,HY(h,m,L,z,Y,Z),h===Yt&&(mt=Yt=null,wt=0),af=p,Ss=h,of=m,lS=L,uS=A,bk=S,(p.subtreeFlags&10256)!==0||(p.flags&10256)!==0?(h.callbackNode=null,h.callbackPriority=0,vX(Ga,function(){return Ok(),null})):(h.callbackNode=null,h.callbackPriority=0),S=(p.flags&13878)!==0,(p.subtreeFlags&13878)!==0||S){S=j.T,j.T=null,A=U.p,U.p=2,z=It,It|=4;try{nX(h,p,m)}finally{It=z,U.p=A,j.T=S}}qr=1,Rk(),Ek(),kk()}}function Rk(){if(qr===1){qr=0;var h=Ss,p=af,m=(p.flags&13878)!==0;if((p.subtreeFlags&13878)!==0||m){m=j.T,j.T=null;var S=U.p;U.p=2;var A=It;It|=4;try{dk(p,h);var L=CS,z=xR(h.containerInfo),Y=L.focusedElem,Z=L.selectionRange;if(z!==Y&&Y&&Y.ownerDocument&&yR(Y.ownerDocument.documentElement,Y)){if(Z!==null&&Qb(Y)){var ae=Z.start,he=Z.end;if(he===void 0&&(he=ae),"selectionStart"in Y)Y.selectionStart=ae,Y.selectionEnd=Math.min(he,Y.value.length);else{var ve=Y.ownerDocument||document,se=ve&&ve.defaultView||window;if(se.getSelection){var le=se.getSelection(),rt=Y.textContent.length,Ze=Math.min(Z.start,rt),Gt=Z.end===void 0?Ze:Math.min(Z.end,rt);!le.extend&&Ze>Gt&&(z=Gt,Gt=Ze,Ze=z);var re=mR(Y,Ze),Q=mR(Y,Gt);if(re&&Q&&(le.rangeCount!==1||le.anchorNode!==re.node||le.anchorOffset!==re.offset||le.focusNode!==Q.node||le.focusOffset!==Q.offset)){var ne=ve.createRange();ne.setStart(re.node,re.offset),le.removeAllRanges(),Ze>Gt?(le.addRange(ne),le.extend(Q.node,Q.offset)):(ne.setEnd(Q.node,Q.offset),le.addRange(ne))}}}}for(ve=[],le=Y;le=le.parentNode;)le.nodeType===1&&ve.push({element:le,left:le.scrollLeft,top:le.scrollTop});for(typeof Y.focus=="function"&&Y.focus(),Y=0;Y<ve.length;Y++){var de=ve[Y];de.element.scrollLeft=de.left,de.element.scrollTop=de.top}}fy=!!TS,CS=TS=null}finally{It=A,U.p=S,j.T=m}}h.current=p,qr=2}}function Ek(){if(qr===2){qr=0;var h=Ss,p=af,m=(p.flags&8772)!==0;if((p.subtreeFlags&8772)!==0||m){m=j.T,j.T=null;var S=U.p;U.p=2;var A=It;It|=4;try{uk(h,p.alternate,p)}finally{It=A,U.p=S,j.T=m}}qr=3}}function kk(){if(qr===4||qr===3){qr=0,ft();var h=Ss,p=af,m=of,S=bk;(p.subtreeFlags&10256)!==0||(p.flags&10256)!==0?qr=5:(qr=0,af=Ss=null,Ik(h,h.pendingLanes));var A=h.pendingLanes;if(A===0&&(_s=null),Rb(m),p=p.stateNode,Vn&&typeof Vn.onCommitFiberRoot=="function")try{Vn.onCommitFiberRoot(xd,p,void 0,(p.current.flags&128)===128)}catch{}if(S!==null){p=j.T,A=U.p,U.p=2,j.T=null;try{for(var L=h.onRecoverableError,z=0;z<S.length;z++){var Y=S[z];L(Y.value,{componentStack:Y.stack})}}finally{j.T=p,U.p=A}}(of&3)!==0&&Jm(),pi(h),A=h.pendingLanes,(m&4194090)!==0&&(A&42)!==0?h===cS?nv++:(nv=0,cS=h):nv=0,av(0)}}function Ik(h,p){(h.pooledCacheLanes&=p)===0&&(p=h.pooledCache,p!=null&&(h.pooledCache=null,jd(p)))}function Jm(h){return Rk(),Ek(),kk(),Ok()}function Ok(){if(qr!==5)return!1;var h=Ss,p=lS;lS=0;var m=Rb(of),S=j.T,A=U.p;try{U.p=32>m?32:m,j.T=null,m=uS,uS=null;var L=Ss,z=of;if(qr=0,af=Ss=null,of=0,(It&6)!==0)throw Error(n(331));var Y=It;if(It|=4,yk(L.current),pk(L,L.current,z,m),It=Y,av(0,!1),Vn&&typeof Vn.onPostCommitFiberRoot=="function")try{Vn.onPostCommitFiberRoot(xd,L)}catch{}return!0}finally{U.p=A,j.T=S,Ik(h,p)}}function Pk(h,p,m){p=ha(m,p),p=H_(h.stateNode,p,2),h=hs(h,p,2),h!==null&&(_d(h,2),pi(h))}function Ft(h,p,m){if(h.tag===3)Pk(h,h,m);else for(;p!==null;){if(p.tag===3){Pk(p,h,m);break}else if(p.tag===1){var S=p.stateNode;if(typeof p.type.getDerivedStateFromError=="function"||typeof S.componentDidCatch=="function"&&(_s===null||!_s.has(S))){h=ha(m,h),m=VE(2),S=hs(p,m,2),S!==null&&(GE(m,S,p,h),_d(S,2),pi(S));break}}p=p.return}}function vS(h,p,m){var S=h.pingCache;if(S===null){S=h.pingCache=new oX;var A=new Set;S.set(p,A)}else A=S.get(p),A===void 0&&(A=new Set,S.set(p,A));A.has(m)||(aS=!0,A.add(m),h=fX.bind(null,h,p,m),p.then(h,h))}function fX(h,p,m){var S=h.pingCache;S!==null&&S.delete(p),h.pingedLanes|=h.suspendedLanes&m,h.warmLanes&=~m,Yt===h&&(wt&m)===m&&(rr===4||rr===3&&(wt&62914560)===wt&&300>At()-sS?(It&2)===0&&sf(h,0):iS|=m,nf===wt&&(nf=0)),pi(h)}function jk(h,p){p===0&&(p=kL()),h=Hc(h,p),h!==null&&(_d(h,p),pi(h))}function hX(h){var p=h.memoizedState,m=0;p!==null&&(m=p.retryLane),jk(h,m)}function dX(h,p){var m=0;switch(h.tag){case 13:var S=h.stateNode,A=h.memoizedState;A!==null&&(m=A.retryLane);break;case 19:S=h.stateNode;break;case 22:S=h.stateNode._retryCache;break;default:throw Error(n(314))}S!==null&&S.delete(p),jk(h,m)}function vX(h,p){return Be(h,p)}var ey=null,uf=null,pS=!1,ty=!1,gS=!1,Kl=0;function pi(h){h!==uf&&h.next===null&&(uf===null?ey=uf=h:uf=uf.next=h),ty=!0,pS||(pS=!0,gX())}function av(h,p){if(!gS&&ty){gS=!0;do for(var m=!1,S=ey;S!==null;){if(h!==0){var A=S.pendingLanes;if(A===0)var L=0;else{var z=S.suspendedLanes,Y=S.pingedLanes;L=(1<<31-Gn(42|h)+1)-1,L&=A&~(z&~Y),L=L&201326741?L&201326741|1:L?L|2:0}L!==0&&(m=!0,Gk(S,L))}else L=wt,L=sm(S,S===Yt?L:0,S.cancelPendingCommit!==null||S.timeoutHandle!==-1),(L&3)===0||bd(S,L)||(m=!0,Gk(S,L));S=S.next}while(m);gS=!1}}function pX(){zk()}function zk(){ty=pS=!1;var h=0;Kl!==0&&(TX()&&(h=Kl),Kl=0);for(var p=At(),m=null,S=ey;S!==null;){var A=S.next,L=Bk(S,p);L===0?(S.next=null,m===null?ey=A:m.next=A,A===null&&(uf=m)):(m=S,(h!==0||(L&3)!==0)&&(ty=!0)),S=A}av(h)}function Bk(h,p){for(var m=h.suspendedLanes,S=h.pingedLanes,A=h.expirationTimes,L=h.pendingLanes&-62914561;0<L;){var z=31-Gn(L),Y=1<<z,Z=A[z];Z===-1?((Y&m)===0||(Y&S)!==0)&&(A[z]=GY(Y,p)):Z<=p&&(h.expiredLanes|=Y),L&=~Y}if(p=Yt,m=wt,m=sm(h,h===p?m:0,h.cancelPendingCommit!==null||h.timeoutHandle!==-1),S=h.callbackNode,m===0||h===p&&(Ot===2||Ot===9)||h.cancelPendingCommit!==null)return S!==null&&S!==null&&Le(S),h.callbackNode=null,h.callbackPriority=0;if((m&3)===0||bd(h,m)){if(p=m&-m,p===h.callbackPriority)return p;switch(S!==null&&Le(S),Rb(m)){case 2:case 8:m=ci;break;case 32:m=Ga;break;case 268435456:m=RL;break;default:m=Ga}return S=Vk.bind(null,h),m=Be(m,S),h.callbackPriority=p,h.callbackNode=m,p}return S!==null&&S!==null&&Le(S),h.callbackPriority=2,h.callbackNode=null,2}function Vk(h,p){if(qr!==0&&qr!==5)return h.callbackNode=null,h.callbackPriority=0,null;var m=h.callbackNode;if(Jm()&&h.callbackNode!==m)return null;var S=wt;return S=sm(h,h===Yt?S:0,h.cancelPendingCommit!==null||h.timeoutHandle!==-1),S===0?null:(Sk(h,S,p),Bk(h,At()),h.callbackNode!=null&&h.callbackNode===m?Vk.bind(null,h):null)}function Gk(h,p){if(Jm())return null;Sk(h,p,!0)}function gX(){AX(function(){(It&6)!==0?Be(er,pX):zk()})}function mS(){return Kl===0&&(Kl=EL()),Kl}function Hk(h){return h==null||typeof h=="symbol"||typeof h=="boolean"?null:typeof h=="function"?h:hm(""+h)}function Fk(h,p){var m=p.ownerDocument.createElement("input");return m.name=p.name,m.value=p.value,h.id&&m.setAttribute("form",h.id),p.parentNode.insertBefore(m,p),h=new FormData(h),m.parentNode.removeChild(m),h}function mX(h,p,m,S,A){if(p==="submit"&&m&&m.stateNode===A){var L=Hk((A[An]||null).action),z=S.submitter;z&&(p=(p=z[An]||null)?Hk(p.formAction):z.getAttribute("formAction"),p!==null&&(L=p,z=null));var Y=new gm("action","action",null,S,A);h.push({event:Y,listeners:[{instance:null,listener:function(){if(S.defaultPrevented){if(Kl!==0){var Z=z?Fk(A,z):new FormData(A);j_(m,{pending:!0,data:Z,method:A.method,action:L},null,Z)}}else typeof L=="function"&&(Y.preventDefault(),Z=z?Fk(A,z):new FormData(A),j_(m,{pending:!0,data:Z,method:A.method,action:L},L,Z))},currentTarget:A}]})}}for(var yS=0;yS<r_.length;yS++){var xS=r_[yS],yX=xS.toLowerCase(),xX=xS[0].toUpperCase()+xS.slice(1);Ha(yX,"on"+xX)}Ha(SR,"onAnimationEnd"),Ha(wR,"onAnimationIteration"),Ha(TR,"onAnimationStart"),Ha("dblclick","onDoubleClick"),Ha("focusin","onFocus"),Ha("focusout","onBlur"),Ha(PW,"onTransitionRun"),Ha(jW,"onTransitionStart"),Ha(zW,"onTransitionCancel"),Ha(CR,"onTransitionEnd"),Ec("onMouseEnter",["mouseout","mouseover"]),Ec("onMouseLeave",["mouseout","mouseover"]),Ec("onPointerEnter",["pointerout","pointerover"]),Ec("onPointerLeave",["pointerout","pointerover"]),Ol("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ol("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ol("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ol("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ol("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ol("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var iv="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),bX=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(iv));function Uk(h,p){p=(p&4)!==0;for(var m=0;m<h.length;m++){var S=h[m],A=S.event;S=S.listeners;e:{var L=void 0;if(p)for(var z=S.length-1;0<=z;z--){var Y=S[z],Z=Y.instance,ae=Y.currentTarget;if(Y=Y.listener,Z!==L&&A.isPropagationStopped())break e;L=Y,A.currentTarget=ae;try{L(A)}catch(he){Hm(he)}A.currentTarget=null,L=Z}else for(z=0;z<S.length;z++){if(Y=S[z],Z=Y.instance,ae=Y.currentTarget,Y=Y.listener,Z!==L&&A.isPropagationStopped())break e;L=Y,A.currentTarget=ae;try{L(A)}catch(he){Hm(he)}A.currentTarget=null,L=Z}}}}function yt(h,p){var m=p[Eb];m===void 0&&(m=p[Eb]=new Set);var S=h+"__bubble";m.has(S)||(Yk(p,h,2,!1),m.add(S))}function bS(h,p,m){var S=0;p&&(S|=4),Yk(m,h,S,p)}var ry="_reactListening"+Math.random().toString(36).slice(2);function _S(h){if(!h[ry]){h[ry]=!0,zL.forEach(function(m){m!=="selectionchange"&&(bX.has(m)||bS(m,!1,h),bS(m,!0,h))});var p=h.nodeType===9?h:h.ownerDocument;p===null||p[ry]||(p[ry]=!0,bS("selectionchange",!1,p))}}function Yk(h,p,m,S){switch(pI(p)){case 2:var A=XX;break;case 8:A=qX;break;default:A=OS}m=A.bind(null,p,m,h),A=void 0,!Fb||p!=="touchstart"&&p!=="touchmove"&&p!=="wheel"||(A=!0),S?A!==void 0?h.addEventListener(p,m,{capture:!0,passive:A}):h.addEventListener(p,m,!0):A!==void 0?h.addEventListener(p,m,{passive:A}):h.addEventListener(p,m,!1)}function SS(h,p,m,S,A){var L=S;if((p&1)===0&&(p&2)===0&&S!==null)e:for(;;){if(S===null)return;var z=S.tag;if(z===3||z===4){var Y=S.stateNode.containerInfo;if(Y===A)break;if(z===4)for(z=S.return;z!==null;){var Z=z.tag;if((Z===3||Z===4)&&z.stateNode.containerInfo===A)return;z=z.return}for(;Y!==null;){if(z=Nc(Y),z===null)return;if(Z=z.tag,Z===5||Z===6||Z===26||Z===27){S=L=z;continue e}Y=Y.parentNode}}S=S.return}QL(function(){var ae=L,he=Gb(m),ve=[];e:{var se=AR.get(h);if(se!==void 0){var le=gm,rt=h;switch(h){case"keypress":if(vm(m)===0)break e;case"keydown":case"keyup":le=vW;break;case"focusin":rt="focus",le=Xb;break;case"focusout":rt="blur",le=Xb;break;case"beforeblur":case"afterblur":le=Xb;break;case"click":if(m.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":le=tR;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":le=rW;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":le=mW;break;case SR:case wR:case TR:le=iW;break;case CR:le=xW;break;case"scroll":case"scrollend":le=eW;break;case"wheel":le=_W;break;case"copy":case"cut":case"paste":le=sW;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":le=nR;break;case"toggle":case"beforetoggle":le=wW}var Ze=(p&4)!==0,Gt=!Ze&&(h==="scroll"||h==="scrollend"),re=Ze?se!==null?se+"Capture":null:se;Ze=[];for(var Q=ae,ne;Q!==null;){var de=Q;if(ne=de.stateNode,de=de.tag,de!==5&&de!==26&&de!==27||ne===null||re===null||(de=Td(Q,re),de!=null&&Ze.push(ov(Q,de,ne))),Gt)break;Q=Q.return}0<Ze.length&&(se=new le(se,rt,null,m,he),ve.push({event:se,listeners:Ze}))}}if((p&7)===0){e:{if(se=h==="mouseover"||h==="pointerover",le=h==="mouseout"||h==="pointerout",se&&m!==Vb&&(rt=m.relatedTarget||m.fromElement)&&(Nc(rt)||rt[Dc]))break e;if((le||se)&&(se=he.window===he?he:(se=he.ownerDocument)?se.defaultView||se.parentWindow:window,le?(rt=m.relatedTarget||m.toElement,le=ae,rt=rt?Nc(rt):null,rt!==null&&(Gt=i(rt),Ze=rt.tag,rt!==Gt||Ze!==5&&Ze!==27&&Ze!==6)&&(rt=null)):(le=null,rt=ae),le!==rt)){if(Ze=tR,de="onMouseLeave",re="onMouseEnter",Q="mouse",(h==="pointerout"||h==="pointerover")&&(Ze=nR,de="onPointerLeave",re="onPointerEnter",Q="pointer"),Gt=le==null?se:wd(le),ne=rt==null?se:wd(rt),se=new Ze(de,Q+"leave",le,m,he),se.target=Gt,se.relatedTarget=ne,de=null,Nc(he)===ae&&(Ze=new Ze(re,Q+"enter",rt,m,he),Ze.target=ne,Ze.relatedTarget=Gt,de=Ze),Gt=de,le&&rt)t:{for(Ze=le,re=rt,Q=0,ne=Ze;ne;ne=cf(ne))Q++;for(ne=0,de=re;de;de=cf(de))ne++;for(;0<Q-ne;)Ze=cf(Ze),Q--;for(;0<ne-Q;)re=cf(re),ne--;for(;Q--;){if(Ze===re||re!==null&&Ze===re.alternate)break t;Ze=cf(Ze),re=cf(re)}Ze=null}else Ze=null;le!==null&&Wk(ve,se,le,Ze,!1),rt!==null&&Gt!==null&&Wk(ve,Gt,rt,Ze,!0)}}e:{if(se=ae?wd(ae):window,le=se.nodeName&&se.nodeName.toLowerCase(),le==="select"||le==="input"&&se.type==="file")var Ve=fR;else if(uR(se))if(hR)Ve=kW;else{Ve=RW;var vt=LW}else le=se.nodeName,!le||le.toLowerCase()!=="input"||se.type!=="checkbox"&&se.type!=="radio"?ae&&Bb(ae.elementType)&&(Ve=fR):Ve=EW;if(Ve&&(Ve=Ve(h,ae))){cR(ve,Ve,m,he);break e}vt&&vt(h,se,ae),h==="focusout"&&ae&&se.type==="number"&&ae.memoizedProps.value!=null&&zb(se,"number",se.value)}switch(vt=ae?wd(ae):window,h){case"focusin":(uR(vt)||vt.contentEditable==="true")&&(Bc=vt,Jb=ae,Ed=null);break;case"focusout":Ed=Jb=Bc=null;break;case"mousedown":e_=!0;break;case"contextmenu":case"mouseup":case"dragend":e_=!1,bR(ve,m,he);break;case"selectionchange":if(OW)break;case"keydown":case"keyup":bR(ve,m,he)}var Ue;if(Zb)e:{switch(h){case"compositionstart":var Ke="onCompositionStart";break e;case"compositionend":Ke="onCompositionEnd";break e;case"compositionupdate":Ke="onCompositionUpdate";break e}Ke=void 0}else zc?sR(h,m)&&(Ke="onCompositionEnd"):h==="keydown"&&m.keyCode===229&&(Ke="onCompositionStart");Ke&&(aR&&m.locale!=="ko"&&(zc||Ke!=="onCompositionStart"?Ke==="onCompositionEnd"&&zc&&(Ue=JL()):(ls=he,Ub="value"in ls?ls.value:ls.textContent,zc=!0)),vt=ny(ae,Ke),0<vt.length&&(Ke=new rR(Ke,h,null,m,he),ve.push({event:Ke,listeners:vt}),Ue?Ke.data=Ue:(Ue=lR(m),Ue!==null&&(Ke.data=Ue)))),(Ue=CW?AW(h,m):MW(h,m))&&(Ke=ny(ae,"onBeforeInput"),0<Ke.length&&(vt=new rR("onBeforeInput","beforeinput",null,m,he),ve.push({event:vt,listeners:Ke}),vt.data=Ue)),mX(ve,h,ae,m,he)}Uk(ve,p)})}function ov(h,p,m){return{instance:h,listener:p,currentTarget:m}}function ny(h,p){for(var m=p+"Capture",S=[];h!==null;){var A=h,L=A.stateNode;if(A=A.tag,A!==5&&A!==26&&A!==27||L===null||(A=Td(h,m),A!=null&&S.unshift(ov(h,A,L)),A=Td(h,p),A!=null&&S.push(ov(h,A,L))),h.tag===3)return S;h=h.return}return[]}function cf(h){if(h===null)return null;do h=h.return;while(h&&h.tag!==5&&h.tag!==27);return h||null}function Wk(h,p,m,S,A){for(var L=p._reactName,z=[];m!==null&&m!==S;){var Y=m,Z=Y.alternate,ae=Y.stateNode;if(Y=Y.tag,Z!==null&&Z===S)break;Y!==5&&Y!==26&&Y!==27||ae===null||(Z=ae,A?(ae=Td(m,L),ae!=null&&z.unshift(ov(m,ae,Z))):A||(ae=Td(m,L),ae!=null&&z.push(ov(m,ae,Z)))),m=m.return}z.length!==0&&h.push({event:p,listeners:z})}var _X=/\r\n?/g,SX=/\u0000|\uFFFD/g;function Xk(h){return(typeof h=="string"?h:""+h).replace(_X,`
49
- `).replace(SX,"")}function qk(h,p){return p=Xk(p),Xk(h)===p}function ay(){}function Vt(h,p,m,S,A,L){switch(m){case"children":typeof S=="string"?p==="body"||p==="textarea"&&S===""||Oc(h,S):(typeof S=="number"||typeof S=="bigint")&&p!=="body"&&Oc(h,""+S);break;case"className":um(h,"class",S);break;case"tabIndex":um(h,"tabindex",S);break;case"dir":case"role":case"viewBox":case"width":case"height":um(h,m,S);break;case"style":$L(h,S,L);break;case"data":if(p!=="object"){um(h,"data",S);break}case"src":case"href":if(S===""&&(p!=="a"||m!=="href")){h.removeAttribute(m);break}if(S==null||typeof S=="function"||typeof S=="symbol"||typeof S=="boolean"){h.removeAttribute(m);break}S=hm(""+S),h.setAttribute(m,S);break;case"action":case"formAction":if(typeof S=="function"){h.setAttribute(m,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof L=="function"&&(m==="formAction"?(p!=="input"&&Vt(h,p,"name",A.name,A,null),Vt(h,p,"formEncType",A.formEncType,A,null),Vt(h,p,"formMethod",A.formMethod,A,null),Vt(h,p,"formTarget",A.formTarget,A,null)):(Vt(h,p,"encType",A.encType,A,null),Vt(h,p,"method",A.method,A,null),Vt(h,p,"target",A.target,A,null)));if(S==null||typeof S=="symbol"||typeof S=="boolean"){h.removeAttribute(m);break}S=hm(""+S),h.setAttribute(m,S);break;case"onClick":S!=null&&(h.onclick=ay);break;case"onScroll":S!=null&&yt("scroll",h);break;case"onScrollEnd":S!=null&&yt("scrollend",h);break;case"dangerouslySetInnerHTML":if(S!=null){if(typeof S!="object"||!("__html"in S))throw Error(n(61));if(m=S.__html,m!=null){if(A.children!=null)throw Error(n(60));h.innerHTML=m}}break;case"multiple":h.multiple=S&&typeof S!="function"&&typeof S!="symbol";break;case"muted":h.muted=S&&typeof S!="function"&&typeof S!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(S==null||typeof S=="function"||typeof S=="boolean"||typeof S=="symbol"){h.removeAttribute("xlink:href");break}m=hm(""+S),h.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",m);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":S!=null&&typeof S!="function"&&typeof S!="symbol"?h.setAttribute(m,""+S):h.removeAttribute(m);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":S&&typeof S!="function"&&typeof S!="symbol"?h.setAttribute(m,""):h.removeAttribute(m);break;case"capture":case"download":S===!0?h.setAttribute(m,""):S!==!1&&S!=null&&typeof S!="function"&&typeof S!="symbol"?h.setAttribute(m,S):h.removeAttribute(m);break;case"cols":case"rows":case"size":case"span":S!=null&&typeof S!="function"&&typeof S!="symbol"&&!isNaN(S)&&1<=S?h.setAttribute(m,S):h.removeAttribute(m);break;case"rowSpan":case"start":S==null||typeof S=="function"||typeof S=="symbol"||isNaN(S)?h.removeAttribute(m):h.setAttribute(m,S);break;case"popover":yt("beforetoggle",h),yt("toggle",h),lm(h,"popover",S);break;case"xlinkActuate":ro(h,"http://www.w3.org/1999/xlink","xlink:actuate",S);break;case"xlinkArcrole":ro(h,"http://www.w3.org/1999/xlink","xlink:arcrole",S);break;case"xlinkRole":ro(h,"http://www.w3.org/1999/xlink","xlink:role",S);break;case"xlinkShow":ro(h,"http://www.w3.org/1999/xlink","xlink:show",S);break;case"xlinkTitle":ro(h,"http://www.w3.org/1999/xlink","xlink:title",S);break;case"xlinkType":ro(h,"http://www.w3.org/1999/xlink","xlink:type",S);break;case"xmlBase":ro(h,"http://www.w3.org/XML/1998/namespace","xml:base",S);break;case"xmlLang":ro(h,"http://www.w3.org/XML/1998/namespace","xml:lang",S);break;case"xmlSpace":ro(h,"http://www.w3.org/XML/1998/namespace","xml:space",S);break;case"is":lm(h,"is",S);break;case"innerText":case"textContent":break;default:(!(2<m.length)||m[0]!=="o"&&m[0]!=="O"||m[1]!=="n"&&m[1]!=="N")&&(m=QY.get(m)||m,lm(h,m,S))}}function wS(h,p,m,S,A,L){switch(m){case"style":$L(h,S,L);break;case"dangerouslySetInnerHTML":if(S!=null){if(typeof S!="object"||!("__html"in S))throw Error(n(61));if(m=S.__html,m!=null){if(A.children!=null)throw Error(n(60));h.innerHTML=m}}break;case"children":typeof S=="string"?Oc(h,S):(typeof S=="number"||typeof S=="bigint")&&Oc(h,""+S);break;case"onScroll":S!=null&&yt("scroll",h);break;case"onScrollEnd":S!=null&&yt("scrollend",h);break;case"onClick":S!=null&&(h.onclick=ay);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!BL.hasOwnProperty(m))e:{if(m[0]==="o"&&m[1]==="n"&&(A=m.endsWith("Capture"),p=m.slice(2,A?m.length-7:void 0),L=h[An]||null,L=L!=null?L[m]:null,typeof L=="function"&&h.removeEventListener(p,L,A),typeof S=="function")){typeof L!="function"&&L!==null&&(m in h?h[m]=null:h.hasAttribute(m)&&h.removeAttribute(m)),h.addEventListener(p,S,A);break e}m in h?h[m]=S:S===!0?h.setAttribute(m,""):lm(h,m,S)}}}function Zr(h,p,m){switch(p){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":yt("error",h),yt("load",h);var S=!1,A=!1,L;for(L in m)if(m.hasOwnProperty(L)){var z=m[L];if(z!=null)switch(L){case"src":S=!0;break;case"srcSet":A=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(n(137,p));default:Vt(h,p,L,z,m,null)}}A&&Vt(h,p,"srcSet",m.srcSet,m,null),S&&Vt(h,p,"src",m.src,m,null);return;case"input":yt("invalid",h);var Y=L=z=A=null,Z=null,ae=null;for(S in m)if(m.hasOwnProperty(S)){var he=m[S];if(he!=null)switch(S){case"name":A=he;break;case"type":z=he;break;case"checked":Z=he;break;case"defaultChecked":ae=he;break;case"value":L=he;break;case"defaultValue":Y=he;break;case"children":case"dangerouslySetInnerHTML":if(he!=null)throw Error(n(137,p));break;default:Vt(h,p,S,he,m,null)}}WL(h,L,Y,Z,ae,z,A,!1),cm(h);return;case"select":yt("invalid",h),S=z=L=null;for(A in m)if(m.hasOwnProperty(A)&&(Y=m[A],Y!=null))switch(A){case"value":L=Y;break;case"defaultValue":z=Y;break;case"multiple":S=Y;default:Vt(h,p,A,Y,m,null)}p=L,m=z,h.multiple=!!S,p!=null?Ic(h,!!S,p,!1):m!=null&&Ic(h,!!S,m,!0);return;case"textarea":yt("invalid",h),L=A=S=null;for(z in m)if(m.hasOwnProperty(z)&&(Y=m[z],Y!=null))switch(z){case"value":S=Y;break;case"defaultValue":A=Y;break;case"children":L=Y;break;case"dangerouslySetInnerHTML":if(Y!=null)throw Error(n(91));break;default:Vt(h,p,z,Y,m,null)}qL(h,S,A,L),cm(h);return;case"option":for(Z in m)if(m.hasOwnProperty(Z)&&(S=m[Z],S!=null))switch(Z){case"selected":h.selected=S&&typeof S!="function"&&typeof S!="symbol";break;default:Vt(h,p,Z,S,m,null)}return;case"dialog":yt("beforetoggle",h),yt("toggle",h),yt("cancel",h),yt("close",h);break;case"iframe":case"object":yt("load",h);break;case"video":case"audio":for(S=0;S<iv.length;S++)yt(iv[S],h);break;case"image":yt("error",h),yt("load",h);break;case"details":yt("toggle",h);break;case"embed":case"source":case"link":yt("error",h),yt("load",h);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(ae in m)if(m.hasOwnProperty(ae)&&(S=m[ae],S!=null))switch(ae){case"children":case"dangerouslySetInnerHTML":throw Error(n(137,p));default:Vt(h,p,ae,S,m,null)}return;default:if(Bb(p)){for(he in m)m.hasOwnProperty(he)&&(S=m[he],S!==void 0&&wS(h,p,he,S,m,void 0));return}}for(Y in m)m.hasOwnProperty(Y)&&(S=m[Y],S!=null&&Vt(h,p,Y,S,m,null))}function wX(h,p,m,S){switch(p){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var A=null,L=null,z=null,Y=null,Z=null,ae=null,he=null;for(le in m){var ve=m[le];if(m.hasOwnProperty(le)&&ve!=null)switch(le){case"checked":break;case"value":break;case"defaultValue":Z=ve;default:S.hasOwnProperty(le)||Vt(h,p,le,null,S,ve)}}for(var se in S){var le=S[se];if(ve=m[se],S.hasOwnProperty(se)&&(le!=null||ve!=null))switch(se){case"type":L=le;break;case"name":A=le;break;case"checked":ae=le;break;case"defaultChecked":he=le;break;case"value":z=le;break;case"defaultValue":Y=le;break;case"children":case"dangerouslySetInnerHTML":if(le!=null)throw Error(n(137,p));break;default:le!==ve&&Vt(h,p,se,le,S,ve)}}jb(h,z,Y,Z,ae,he,L,A);return;case"select":le=z=Y=se=null;for(L in m)if(Z=m[L],m.hasOwnProperty(L)&&Z!=null)switch(L){case"value":break;case"multiple":le=Z;default:S.hasOwnProperty(L)||Vt(h,p,L,null,S,Z)}for(A in S)if(L=S[A],Z=m[A],S.hasOwnProperty(A)&&(L!=null||Z!=null))switch(A){case"value":se=L;break;case"defaultValue":Y=L;break;case"multiple":z=L;default:L!==Z&&Vt(h,p,A,L,S,Z)}p=Y,m=z,S=le,se!=null?Ic(h,!!m,se,!1):!!S!=!!m&&(p!=null?Ic(h,!!m,p,!0):Ic(h,!!m,m?[]:"",!1));return;case"textarea":le=se=null;for(Y in m)if(A=m[Y],m.hasOwnProperty(Y)&&A!=null&&!S.hasOwnProperty(Y))switch(Y){case"value":break;case"children":break;default:Vt(h,p,Y,null,S,A)}for(z in S)if(A=S[z],L=m[z],S.hasOwnProperty(z)&&(A!=null||L!=null))switch(z){case"value":se=A;break;case"defaultValue":le=A;break;case"children":break;case"dangerouslySetInnerHTML":if(A!=null)throw Error(n(91));break;default:A!==L&&Vt(h,p,z,A,S,L)}XL(h,se,le);return;case"option":for(var rt in m)if(se=m[rt],m.hasOwnProperty(rt)&&se!=null&&!S.hasOwnProperty(rt))switch(rt){case"selected":h.selected=!1;break;default:Vt(h,p,rt,null,S,se)}for(Z in S)if(se=S[Z],le=m[Z],S.hasOwnProperty(Z)&&se!==le&&(se!=null||le!=null))switch(Z){case"selected":h.selected=se&&typeof se!="function"&&typeof se!="symbol";break;default:Vt(h,p,Z,se,S,le)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Ze in m)se=m[Ze],m.hasOwnProperty(Ze)&&se!=null&&!S.hasOwnProperty(Ze)&&Vt(h,p,Ze,null,S,se);for(ae in S)if(se=S[ae],le=m[ae],S.hasOwnProperty(ae)&&se!==le&&(se!=null||le!=null))switch(ae){case"children":case"dangerouslySetInnerHTML":if(se!=null)throw Error(n(137,p));break;default:Vt(h,p,ae,se,S,le)}return;default:if(Bb(p)){for(var Gt in m)se=m[Gt],m.hasOwnProperty(Gt)&&se!==void 0&&!S.hasOwnProperty(Gt)&&wS(h,p,Gt,void 0,S,se);for(he in S)se=S[he],le=m[he],!S.hasOwnProperty(he)||se===le||se===void 0&&le===void 0||wS(h,p,he,se,S,le);return}}for(var re in m)se=m[re],m.hasOwnProperty(re)&&se!=null&&!S.hasOwnProperty(re)&&Vt(h,p,re,null,S,se);for(ve in S)se=S[ve],le=m[ve],!S.hasOwnProperty(ve)||se===le||se==null&&le==null||Vt(h,p,ve,se,S,le)}var TS=null,CS=null;function iy(h){return h.nodeType===9?h:h.ownerDocument}function Zk(h){switch(h){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function $k(h,p){if(h===0)switch(p){case"svg":return 1;case"math":return 2;default:return 0}return h===1&&p==="foreignObject"?0:h}function AS(h,p){return h==="textarea"||h==="noscript"||typeof p.children=="string"||typeof p.children=="number"||typeof p.children=="bigint"||typeof p.dangerouslySetInnerHTML=="object"&&p.dangerouslySetInnerHTML!==null&&p.dangerouslySetInnerHTML.__html!=null}var MS=null;function TX(){var h=window.event;return h&&h.type==="popstate"?h===MS?!1:(MS=h,!0):(MS=null,!1)}var Kk=typeof setTimeout=="function"?setTimeout:void 0,CX=typeof clearTimeout=="function"?clearTimeout:void 0,Qk=typeof Promise=="function"?Promise:void 0,AX=typeof queueMicrotask=="function"?queueMicrotask:typeof Qk<"u"?function(h){return Qk.resolve(null).then(h).catch(MX)}:Kk;function MX(h){setTimeout(function(){throw h})}function Ts(h){return h==="head"}function Jk(h,p){var m=p,S=0,A=0;do{var L=m.nextSibling;if(h.removeChild(m),L&&L.nodeType===8)if(m=L.data,m==="/$"){if(0<S&&8>S){m=S;var z=h.ownerDocument;if(m&1&&sv(z.documentElement),m&2&&sv(z.body),m&4)for(m=z.head,sv(m),z=m.firstChild;z;){var Y=z.nextSibling,Z=z.nodeName;z[Sd]||Z==="SCRIPT"||Z==="STYLE"||Z==="LINK"&&z.rel.toLowerCase()==="stylesheet"||m.removeChild(z),z=Y}}if(A===0){h.removeChild(L),pv(p);return}A--}else m==="$"||m==="$?"||m==="$!"?A++:S=m.charCodeAt(0)-48;else S=0;m=L}while(m);pv(p)}function DS(h){var p=h.firstChild;for(p&&p.nodeType===10&&(p=p.nextSibling);p;){var m=p;switch(p=p.nextSibling,m.nodeName){case"HTML":case"HEAD":case"BODY":DS(m),kb(m);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(m.rel.toLowerCase()==="stylesheet")continue}h.removeChild(m)}}function DX(h,p,m,S){for(;h.nodeType===1;){var A=m;if(h.nodeName.toLowerCase()!==p.toLowerCase()){if(!S&&(h.nodeName!=="INPUT"||h.type!=="hidden"))break}else if(S){if(!h[Sd])switch(p){case"meta":if(!h.hasAttribute("itemprop"))break;return h;case"link":if(L=h.getAttribute("rel"),L==="stylesheet"&&h.hasAttribute("data-precedence"))break;if(L!==A.rel||h.getAttribute("href")!==(A.href==null||A.href===""?null:A.href)||h.getAttribute("crossorigin")!==(A.crossOrigin==null?null:A.crossOrigin)||h.getAttribute("title")!==(A.title==null?null:A.title))break;return h;case"style":if(h.hasAttribute("data-precedence"))break;return h;case"script":if(L=h.getAttribute("src"),(L!==(A.src==null?null:A.src)||h.getAttribute("type")!==(A.type==null?null:A.type)||h.getAttribute("crossorigin")!==(A.crossOrigin==null?null:A.crossOrigin))&&L&&h.hasAttribute("async")&&!h.hasAttribute("itemprop"))break;return h;default:return h}}else if(p==="input"&&h.type==="hidden"){var L=A.name==null?null:""+A.name;if(A.type==="hidden"&&h.getAttribute("name")===L)return h}else return h;if(h=Ua(h.nextSibling),h===null)break}return null}function NX(h,p,m){if(p==="")return null;for(;h.nodeType!==3;)if((h.nodeType!==1||h.nodeName!=="INPUT"||h.type!=="hidden")&&!m||(h=Ua(h.nextSibling),h===null))return null;return h}function NS(h){return h.data==="$!"||h.data==="$?"&&h.ownerDocument.readyState==="complete"}function LX(h,p){var m=h.ownerDocument;if(h.data!=="$?"||m.readyState==="complete")p();else{var S=function(){p(),m.removeEventListener("DOMContentLoaded",S)};m.addEventListener("DOMContentLoaded",S),h._reactRetry=S}}function Ua(h){for(;h!=null;h=h.nextSibling){var p=h.nodeType;if(p===1||p===3)break;if(p===8){if(p=h.data,p==="$"||p==="$!"||p==="$?"||p==="F!"||p==="F")break;if(p==="/$")return null}}return h}var LS=null;function eI(h){h=h.previousSibling;for(var p=0;h;){if(h.nodeType===8){var m=h.data;if(m==="$"||m==="$!"||m==="$?"){if(p===0)return h;p--}else m==="/$"&&p++}h=h.previousSibling}return null}function tI(h,p,m){switch(p=iy(m),h){case"html":if(h=p.documentElement,!h)throw Error(n(452));return h;case"head":if(h=p.head,!h)throw Error(n(453));return h;case"body":if(h=p.body,!h)throw Error(n(454));return h;default:throw Error(n(451))}}function sv(h){for(var p=h.attributes;p.length;)h.removeAttributeNode(p[0]);kb(h)}var ya=new Map,rI=new Set;function oy(h){return typeof h.getRootNode=="function"?h.getRootNode():h.nodeType===9?h:h.ownerDocument}var mo=U.d;U.d={f:RX,r:EX,D:kX,C:IX,L:OX,m:PX,X:zX,S:jX,M:BX};function RX(){var h=mo.f(),p=Km();return h||p}function EX(h){var p=Lc(h);p!==null&&p.tag===5&&p.type==="form"?SE(p):mo.r(h)}var ff=typeof document>"u"?null:document;function nI(h,p,m){var S=ff;if(S&&typeof p=="string"&&p){var A=fa(p);A='link[rel="'+h+'"][href="'+A+'"]',typeof m=="string"&&(A+='[crossorigin="'+m+'"]'),rI.has(A)||(rI.add(A),h={rel:h,crossOrigin:m,href:p},S.querySelector(A)===null&&(p=S.createElement("link"),Zr(p,"link",h),Or(p),S.head.appendChild(p)))}}function kX(h){mo.D(h),nI("dns-prefetch",h,null)}function IX(h,p){mo.C(h,p),nI("preconnect",h,p)}function OX(h,p,m){mo.L(h,p,m);var S=ff;if(S&&h&&p){var A='link[rel="preload"][as="'+fa(p)+'"]';p==="image"&&m&&m.imageSrcSet?(A+='[imagesrcset="'+fa(m.imageSrcSet)+'"]',typeof m.imageSizes=="string"&&(A+='[imagesizes="'+fa(m.imageSizes)+'"]')):A+='[href="'+fa(h)+'"]';var L=A;switch(p){case"style":L=hf(h);break;case"script":L=df(h)}ya.has(L)||(h=c({rel:"preload",href:p==="image"&&m&&m.imageSrcSet?void 0:h,as:p},m),ya.set(L,h),S.querySelector(A)!==null||p==="style"&&S.querySelector(lv(L))||p==="script"&&S.querySelector(uv(L))||(p=S.createElement("link"),Zr(p,"link",h),Or(p),S.head.appendChild(p)))}}function PX(h,p){mo.m(h,p);var m=ff;if(m&&h){var S=p&&typeof p.as=="string"?p.as:"script",A='link[rel="modulepreload"][as="'+fa(S)+'"][href="'+fa(h)+'"]',L=A;switch(S){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":L=df(h)}if(!ya.has(L)&&(h=c({rel:"modulepreload",href:h},p),ya.set(L,h),m.querySelector(A)===null)){switch(S){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(m.querySelector(uv(L)))return}S=m.createElement("link"),Zr(S,"link",h),Or(S),m.head.appendChild(S)}}}function jX(h,p,m){mo.S(h,p,m);var S=ff;if(S&&h){var A=Rc(S).hoistableStyles,L=hf(h);p=p||"default";var z=A.get(L);if(!z){var Y={loading:0,preload:null};if(z=S.querySelector(lv(L)))Y.loading=5;else{h=c({rel:"stylesheet",href:h,"data-precedence":p},m),(m=ya.get(L))&&RS(h,m);var Z=z=S.createElement("link");Or(Z),Zr(Z,"link",h),Z._p=new Promise(function(ae,he){Z.onload=ae,Z.onerror=he}),Z.addEventListener("load",function(){Y.loading|=1}),Z.addEventListener("error",function(){Y.loading|=2}),Y.loading|=4,sy(z,p,S)}z={type:"stylesheet",instance:z,count:1,state:Y},A.set(L,z)}}}function zX(h,p){mo.X(h,p);var m=ff;if(m&&h){var S=Rc(m).hoistableScripts,A=df(h),L=S.get(A);L||(L=m.querySelector(uv(A)),L||(h=c({src:h,async:!0},p),(p=ya.get(A))&&ES(h,p),L=m.createElement("script"),Or(L),Zr(L,"link",h),m.head.appendChild(L)),L={type:"script",instance:L,count:1,state:null},S.set(A,L))}}function BX(h,p){mo.M(h,p);var m=ff;if(m&&h){var S=Rc(m).hoistableScripts,A=df(h),L=S.get(A);L||(L=m.querySelector(uv(A)),L||(h=c({src:h,async:!0,type:"module"},p),(p=ya.get(A))&&ES(h,p),L=m.createElement("script"),Or(L),Zr(L,"link",h),m.head.appendChild(L)),L={type:"script",instance:L,count:1,state:null},S.set(A,L))}}function aI(h,p,m,S){var A=(A=Se.current)?oy(A):null;if(!A)throw Error(n(446));switch(h){case"meta":case"title":return null;case"style":return typeof m.precedence=="string"&&typeof m.href=="string"?(p=hf(m.href),m=Rc(A).hoistableStyles,S=m.get(p),S||(S={type:"style",instance:null,count:0,state:null},m.set(p,S)),S):{type:"void",instance:null,count:0,state:null};case"link":if(m.rel==="stylesheet"&&typeof m.href=="string"&&typeof m.precedence=="string"){h=hf(m.href);var L=Rc(A).hoistableStyles,z=L.get(h);if(z||(A=A.ownerDocument||A,z={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},L.set(h,z),(L=A.querySelector(lv(h)))&&!L._p&&(z.instance=L,z.state.loading=5),ya.has(h)||(m={rel:"preload",as:"style",href:m.href,crossOrigin:m.crossOrigin,integrity:m.integrity,media:m.media,hrefLang:m.hrefLang,referrerPolicy:m.referrerPolicy},ya.set(h,m),L||VX(A,h,m,z.state))),p&&S===null)throw Error(n(528,""));return z}if(p&&S!==null)throw Error(n(529,""));return null;case"script":return p=m.async,m=m.src,typeof m=="string"&&p&&typeof p!="function"&&typeof p!="symbol"?(p=df(m),m=Rc(A).hoistableScripts,S=m.get(p),S||(S={type:"script",instance:null,count:0,state:null},m.set(p,S)),S):{type:"void",instance:null,count:0,state:null};default:throw Error(n(444,h))}}function hf(h){return'href="'+fa(h)+'"'}function lv(h){return'link[rel="stylesheet"]['+h+"]"}function iI(h){return c({},h,{"data-precedence":h.precedence,precedence:null})}function VX(h,p,m,S){h.querySelector('link[rel="preload"][as="style"]['+p+"]")?S.loading=1:(p=h.createElement("link"),S.preload=p,p.addEventListener("load",function(){return S.loading|=1}),p.addEventListener("error",function(){return S.loading|=2}),Zr(p,"link",m),Or(p),h.head.appendChild(p))}function df(h){return'[src="'+fa(h)+'"]'}function uv(h){return"script[async]"+h}function oI(h,p,m){if(p.count++,p.instance===null)switch(p.type){case"style":var S=h.querySelector('style[data-href~="'+fa(m.href)+'"]');if(S)return p.instance=S,Or(S),S;var A=c({},m,{"data-href":m.href,"data-precedence":m.precedence,href:null,precedence:null});return S=(h.ownerDocument||h).createElement("style"),Or(S),Zr(S,"style",A),sy(S,m.precedence,h),p.instance=S;case"stylesheet":A=hf(m.href);var L=h.querySelector(lv(A));if(L)return p.state.loading|=4,p.instance=L,Or(L),L;S=iI(m),(A=ya.get(A))&&RS(S,A),L=(h.ownerDocument||h).createElement("link"),Or(L);var z=L;return z._p=new Promise(function(Y,Z){z.onload=Y,z.onerror=Z}),Zr(L,"link",S),p.state.loading|=4,sy(L,m.precedence,h),p.instance=L;case"script":return L=df(m.src),(A=h.querySelector(uv(L)))?(p.instance=A,Or(A),A):(S=m,(A=ya.get(L))&&(S=c({},m),ES(S,A)),h=h.ownerDocument||h,A=h.createElement("script"),Or(A),Zr(A,"link",S),h.head.appendChild(A),p.instance=A);case"void":return null;default:throw Error(n(443,p.type))}else p.type==="stylesheet"&&(p.state.loading&4)===0&&(S=p.instance,p.state.loading|=4,sy(S,m.precedence,h));return p.instance}function sy(h,p,m){for(var S=m.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),A=S.length?S[S.length-1]:null,L=A,z=0;z<S.length;z++){var Y=S[z];if(Y.dataset.precedence===p)L=Y;else if(L!==A)break}L?L.parentNode.insertBefore(h,L.nextSibling):(p=m.nodeType===9?m.head:m,p.insertBefore(h,p.firstChild))}function RS(h,p){h.crossOrigin==null&&(h.crossOrigin=p.crossOrigin),h.referrerPolicy==null&&(h.referrerPolicy=p.referrerPolicy),h.title==null&&(h.title=p.title)}function ES(h,p){h.crossOrigin==null&&(h.crossOrigin=p.crossOrigin),h.referrerPolicy==null&&(h.referrerPolicy=p.referrerPolicy),h.integrity==null&&(h.integrity=p.integrity)}var ly=null;function sI(h,p,m){if(ly===null){var S=new Map,A=ly=new Map;A.set(m,S)}else A=ly,S=A.get(m),S||(S=new Map,A.set(m,S));if(S.has(h))return S;for(S.set(h,null),m=m.getElementsByTagName(h),A=0;A<m.length;A++){var L=m[A];if(!(L[Sd]||L[on]||h==="link"&&L.getAttribute("rel")==="stylesheet")&&L.namespaceURI!=="http://www.w3.org/2000/svg"){var z=L.getAttribute(p)||"";z=h+z;var Y=S.get(z);Y?Y.push(L):S.set(z,[L])}}return S}function lI(h,p,m){h=h.ownerDocument||h,h.head.insertBefore(m,p==="title"?h.querySelector("head > title"):null)}function GX(h,p,m){if(m===1||p.itemProp!=null)return!1;switch(h){case"meta":case"title":return!0;case"style":if(typeof p.precedence!="string"||typeof p.href!="string"||p.href==="")break;return!0;case"link":if(typeof p.rel!="string"||typeof p.href!="string"||p.href===""||p.onLoad||p.onError)break;switch(p.rel){case"stylesheet":return h=p.disabled,typeof p.precedence=="string"&&h==null;default:return!0}case"script":if(p.async&&typeof p.async!="function"&&typeof p.async!="symbol"&&!p.onLoad&&!p.onError&&p.src&&typeof p.src=="string")return!0}return!1}function uI(h){return!(h.type==="stylesheet"&&(h.state.loading&3)===0)}var cv=null;function HX(){}function FX(h,p,m){if(cv===null)throw Error(n(475));var S=cv;if(p.type==="stylesheet"&&(typeof m.media!="string"||matchMedia(m.media).matches!==!1)&&(p.state.loading&4)===0){if(p.instance===null){var A=hf(m.href),L=h.querySelector(lv(A));if(L){h=L._p,h!==null&&typeof h=="object"&&typeof h.then=="function"&&(S.count++,S=uy.bind(S),h.then(S,S)),p.state.loading|=4,p.instance=L,Or(L);return}L=h.ownerDocument||h,m=iI(m),(A=ya.get(A))&&RS(m,A),L=L.createElement("link"),Or(L);var z=L;z._p=new Promise(function(Y,Z){z.onload=Y,z.onerror=Z}),Zr(L,"link",m),p.instance=L}S.stylesheets===null&&(S.stylesheets=new Map),S.stylesheets.set(p,h),(h=p.state.preload)&&(p.state.loading&3)===0&&(S.count++,p=uy.bind(S),h.addEventListener("load",p),h.addEventListener("error",p))}}function UX(){if(cv===null)throw Error(n(475));var h=cv;return h.stylesheets&&h.count===0&&kS(h,h.stylesheets),0<h.count?function(p){var m=setTimeout(function(){if(h.stylesheets&&kS(h,h.stylesheets),h.unsuspend){var S=h.unsuspend;h.unsuspend=null,S()}},6e4);return h.unsuspend=p,function(){h.unsuspend=null,clearTimeout(m)}}:null}function uy(){if(this.count--,this.count===0){if(this.stylesheets)kS(this,this.stylesheets);else if(this.unsuspend){var h=this.unsuspend;this.unsuspend=null,h()}}}var cy=null;function kS(h,p){h.stylesheets=null,h.unsuspend!==null&&(h.count++,cy=new Map,p.forEach(YX,h),cy=null,uy.call(h))}function YX(h,p){if(!(p.state.loading&4)){var m=cy.get(h);if(m)var S=m.get(null);else{m=new Map,cy.set(h,m);for(var A=h.querySelectorAll("link[data-precedence],style[data-precedence]"),L=0;L<A.length;L++){var z=A[L];(z.nodeName==="LINK"||z.getAttribute("media")!=="not all")&&(m.set(z.dataset.precedence,z),S=z)}S&&m.set(null,S)}A=p.instance,z=A.getAttribute("data-precedence"),L=m.get(z)||S,L===S&&m.set(null,A),m.set(z,A),this.count++,S=uy.bind(this),A.addEventListener("load",S),A.addEventListener("error",S),L?L.parentNode.insertBefore(A,L.nextSibling):(h=h.nodeType===9?h.head:h,h.insertBefore(A,h.firstChild)),p.state.loading|=4}}var fv={$$typeof:T,Provider:null,Consumer:null,_currentValue:F,_currentValue2:F,_threadCount:0};function WX(h,p,m,S,A,L,z,Y){this.tag=1,this.containerInfo=h,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Nb(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Nb(0),this.hiddenUpdates=Nb(null),this.identifierPrefix=S,this.onUncaughtError=A,this.onCaughtError=L,this.onRecoverableError=z,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=Y,this.incompleteTransitions=new Map}function cI(h,p,m,S,A,L,z,Y,Z,ae,he,ve){return h=new WX(h,p,m,z,Y,Z,ae,ve),p=1,L===!0&&(p|=24),L=Fn(3,null,null,p),h.current=L,L.stateNode=h,p=v_(),p.refCount++,h.pooledCache=p,p.refCount++,L.memoizedState={element:S,isDehydrated:m,cache:p},y_(L),h}function fI(h){return h?(h=Fc,h):Fc}function hI(h,p,m,S,A,L){A=fI(A),S.context===null?S.context=A:S.pendingContext=A,S=fs(p),S.payload={element:m},L=L===void 0?null:L,L!==null&&(S.callback=L),m=hs(h,S,p),m!==null&&(qn(m,h,p),Gd(m,h,p))}function dI(h,p){if(h=h.memoizedState,h!==null&&h.dehydrated!==null){var m=h.retryLane;h.retryLane=m!==0&&m<p?m:p}}function IS(h,p){dI(h,p),(h=h.alternate)&&dI(h,p)}function vI(h){if(h.tag===13){var p=Hc(h,67108864);p!==null&&qn(p,h,67108864),IS(h,67108864)}}var fy=!0;function XX(h,p,m,S){var A=j.T;j.T=null;var L=U.p;try{U.p=2,OS(h,p,m,S)}finally{U.p=L,j.T=A}}function qX(h,p,m,S){var A=j.T;j.T=null;var L=U.p;try{U.p=8,OS(h,p,m,S)}finally{U.p=L,j.T=A}}function OS(h,p,m,S){if(fy){var A=PS(S);if(A===null)SS(h,p,S,hy,m),gI(h,S);else if($X(A,h,p,m,S))S.stopPropagation();else if(gI(h,S),p&4&&-1<ZX.indexOf(h)){for(;A!==null;){var L=Lc(A);if(L!==null)switch(L.tag){case 3:if(L=L.stateNode,L.current.memoizedState.isDehydrated){var z=Il(L.pendingLanes);if(z!==0){var Y=L;for(Y.pendingLanes|=2,Y.entangledLanes|=2;z;){var Z=1<<31-Gn(z);Y.entanglements[1]|=Z,z&=~Z}pi(L),(It&6)===0&&(Zm=At()+500,av(0))}}break;case 13:Y=Hc(L,2),Y!==null&&qn(Y,L,2),Km(),IS(L,2)}if(L=PS(S),L===null&&SS(h,p,S,hy,m),L===A)break;A=L}A!==null&&S.stopPropagation()}else SS(h,p,S,null,m)}}function PS(h){return h=Gb(h),jS(h)}var hy=null;function jS(h){if(hy=null,h=Nc(h),h!==null){var p=i(h);if(p===null)h=null;else{var m=p.tag;if(m===13){if(h=o(p),h!==null)return h;h=null}else if(m===3){if(p.stateNode.current.memoizedState.isDehydrated)return p.tag===3?p.stateNode.containerInfo:null;h=null}else p!==h&&(h=null)}}return hy=h,null}function pI(h){switch(h){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Wr()){case er:return 2;case ci:return 8;case Ga:case yd:return 32;case RL:return 268435456;default:return 32}default:return 32}}var zS=!1,Cs=null,As=null,Ms=null,hv=new Map,dv=new Map,Ds=[],ZX="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function gI(h,p){switch(h){case"focusin":case"focusout":Cs=null;break;case"dragenter":case"dragleave":As=null;break;case"mouseover":case"mouseout":Ms=null;break;case"pointerover":case"pointerout":hv.delete(p.pointerId);break;case"gotpointercapture":case"lostpointercapture":dv.delete(p.pointerId)}}function vv(h,p,m,S,A,L){return h===null||h.nativeEvent!==L?(h={blockedOn:p,domEventName:m,eventSystemFlags:S,nativeEvent:L,targetContainers:[A]},p!==null&&(p=Lc(p),p!==null&&vI(p)),h):(h.eventSystemFlags|=S,p=h.targetContainers,A!==null&&p.indexOf(A)===-1&&p.push(A),h)}function $X(h,p,m,S,A){switch(p){case"focusin":return Cs=vv(Cs,h,p,m,S,A),!0;case"dragenter":return As=vv(As,h,p,m,S,A),!0;case"mouseover":return Ms=vv(Ms,h,p,m,S,A),!0;case"pointerover":var L=A.pointerId;return hv.set(L,vv(hv.get(L)||null,h,p,m,S,A)),!0;case"gotpointercapture":return L=A.pointerId,dv.set(L,vv(dv.get(L)||null,h,p,m,S,A)),!0}return!1}function mI(h){var p=Nc(h.target);if(p!==null){var m=i(p);if(m!==null){if(p=m.tag,p===13){if(p=o(m),p!==null){h.blockedOn=p,FY(h.priority,function(){if(m.tag===13){var S=Xn();S=Lb(S);var A=Hc(m,S);A!==null&&qn(A,m,S),IS(m,S)}});return}}else if(p===3&&m.stateNode.current.memoizedState.isDehydrated){h.blockedOn=m.tag===3?m.stateNode.containerInfo:null;return}}}h.blockedOn=null}function dy(h){if(h.blockedOn!==null)return!1;for(var p=h.targetContainers;0<p.length;){var m=PS(h.nativeEvent);if(m===null){m=h.nativeEvent;var S=new m.constructor(m.type,m);Vb=S,m.target.dispatchEvent(S),Vb=null}else return p=Lc(m),p!==null&&vI(p),h.blockedOn=m,!1;p.shift()}return!0}function yI(h,p,m){dy(h)&&m.delete(p)}function KX(){zS=!1,Cs!==null&&dy(Cs)&&(Cs=null),As!==null&&dy(As)&&(As=null),Ms!==null&&dy(Ms)&&(Ms=null),hv.forEach(yI),dv.forEach(yI)}function vy(h,p){h.blockedOn===p&&(h.blockedOn=null,zS||(zS=!0,r.unstable_scheduleCallback(r.unstable_NormalPriority,KX)))}var py=null;function xI(h){py!==h&&(py=h,r.unstable_scheduleCallback(r.unstable_NormalPriority,function(){py===h&&(py=null);for(var p=0;p<h.length;p+=3){var m=h[p],S=h[p+1],A=h[p+2];if(typeof S!="function"){if(jS(S||m)===null)continue;break}var L=Lc(m);L!==null&&(h.splice(p,3),p-=3,j_(L,{pending:!0,data:A,method:m.method,action:S},S,A))}}))}function pv(h){function p(Z){return vy(Z,h)}Cs!==null&&vy(Cs,h),As!==null&&vy(As,h),Ms!==null&&vy(Ms,h),hv.forEach(p),dv.forEach(p);for(var m=0;m<Ds.length;m++){var S=Ds[m];S.blockedOn===h&&(S.blockedOn=null)}for(;0<Ds.length&&(m=Ds[0],m.blockedOn===null);)mI(m),m.blockedOn===null&&Ds.shift();if(m=(h.ownerDocument||h).$$reactFormReplay,m!=null)for(S=0;S<m.length;S+=3){var A=m[S],L=m[S+1],z=A[An]||null;if(typeof L=="function")z||xI(m);else if(z){var Y=null;if(L&&L.hasAttribute("formAction")){if(A=L,z=L[An]||null)Y=z.formAction;else if(jS(A)!==null)continue}else Y=z.action;typeof Y=="function"?m[S+1]=Y:(m.splice(S,3),S-=3),xI(m)}}}function BS(h){this._internalRoot=h}gy.prototype.render=BS.prototype.render=function(h){var p=this._internalRoot;if(p===null)throw Error(n(409));var m=p.current,S=Xn();hI(m,S,h,p,null,null)},gy.prototype.unmount=BS.prototype.unmount=function(){var h=this._internalRoot;if(h!==null){this._internalRoot=null;var p=h.containerInfo;hI(h.current,2,null,h,null,null),Km(),p[Dc]=null}};function gy(h){this._internalRoot=h}gy.prototype.unstable_scheduleHydration=function(h){if(h){var p=PL();h={blockedOn:null,target:h,priority:p};for(var m=0;m<Ds.length&&p!==0&&p<Ds[m].priority;m++);Ds.splice(m,0,h),m===0&&mI(h)}};var bI=e.version;if(bI!=="19.1.0")throw Error(n(527,bI,"19.1.0"));U.findDOMNode=function(h){var p=h._reactInternals;if(p===void 0)throw typeof h.render=="function"?Error(n(188)):(h=Object.keys(h).join(","),Error(n(268,h)));return h=l(p),h=h!==null?u(h):null,h=h===null?null:h.stateNode,h};var QX={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:j,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var my=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!my.isDisabled&&my.supportsFiber)try{xd=my.inject(QX),Vn=my}catch{}}return mv.createRoot=function(h,p){if(!a(h))throw Error(n(299));var m=!1,S="",A=PE,L=jE,z=zE,Y=null;return p!=null&&(p.unstable_strictMode===!0&&(m=!0),p.identifierPrefix!==void 0&&(S=p.identifierPrefix),p.onUncaughtError!==void 0&&(A=p.onUncaughtError),p.onCaughtError!==void 0&&(L=p.onCaughtError),p.onRecoverableError!==void 0&&(z=p.onRecoverableError),p.unstable_transitionCallbacks!==void 0&&(Y=p.unstable_transitionCallbacks)),p=cI(h,1,!1,null,null,m,S,A,L,z,Y,null),h[Dc]=p.current,_S(h),new BS(p)},mv.hydrateRoot=function(h,p,m){if(!a(h))throw Error(n(299));var S=!1,A="",L=PE,z=jE,Y=zE,Z=null,ae=null;return m!=null&&(m.unstable_strictMode===!0&&(S=!0),m.identifierPrefix!==void 0&&(A=m.identifierPrefix),m.onUncaughtError!==void 0&&(L=m.onUncaughtError),m.onCaughtError!==void 0&&(z=m.onCaughtError),m.onRecoverableError!==void 0&&(Y=m.onRecoverableError),m.unstable_transitionCallbacks!==void 0&&(Z=m.unstable_transitionCallbacks),m.formState!==void 0&&(ae=m.formState)),p=cI(h,1,!0,p,m??null,S,A,L,z,Y,Z,ae),p.context=fI(null),m=p.current,S=Xn(),S=Lb(S),A=fs(S),A.callback=null,hs(m,A,S),m=S,p.current.lanes=m,_d(p,m),pi(p),h[Dc]=p.current,_S(h),new gy(p)},mv.version="19.1.0",mv}var HI;function Yq(){if(HI)return FS.exports;HI=1;function r(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(r)}catch(e){console.error(e)}}return r(),FS.exports=Uq(),FS.exports}var Wq=Yq();async function Tr(r){const e=await fetch(`/api${r}`);if(!e.ok)throw new Error(`API ${r} failed: ${e.status}`);return e.json()}function Xq(){return wr({queryKey:["channel-board"],queryFn:()=>Tr("/channel-board"),refetchInterval:5e3})}function Xh(){return wr({queryKey:["status"],queryFn:()=>Tr("/status"),refetchInterval:3e4})}function qq(){return wr({queryKey:["overview"],queryFn:()=>Tr("/overview"),refetchInterval:3e4})}function Zq(){return wr({queryKey:["sessions"],queryFn:()=>Tr("/session").then(r=>r.sessions),refetchInterval:3e3})}function $q(){return wr({queryKey:["market-cache"],queryFn:()=>Tr("/market-cache").then(r=>r.entries),refetchInterval:1e4})}function Kq(){return wr({queryKey:["supplier-verify"],queryFn:()=>Tr("/supplier-verify").then(r=>r.entries),refetchInterval:15e3})}function GV(r){return wr({queryKey:["imported-summary",r],queryFn:()=>{const e=r?new URLSearchParams(Object.fromEntries(Object.entries(r).filter(([,t])=>t))).toString():"";return Tr(`/imported/summary${e?`?${e}`:""}`)},refetchInterval:15e3})}function Qq(){return wr({queryKey:["settlement-fee-rules"],queryFn:()=>Tr("/settlement/fee-rules"),staleTime:1e4})}function Jq(r,e){const t=r||e?`?${new URLSearchParams(Object.fromEntries([r?["from",r]:null,e?["to",e]:null].filter(Boolean)))}`:"";return wr({queryKey:["deposit-schedule",r,e],queryFn:()=>Tr(`/settlement/deposit-schedule${t}`).then(n=>n.schedule),staleTime:3e4})}function eZ(r,e,t=!0){return wr({queryKey:["smartstore-daily",r,e],queryFn:()=>Tr(`/settlement/smartstore/daily?orderFrom=${r}&orderTo=${e}`),enabled:t&&!!r&&!!e,staleTime:5*6e4})}function tZ(r,e,t=!0){return wr({queryKey:["smartstore-order-settlement",r,e],queryFn:()=>Tr(`/settlement/smartstore/order?orderId=${r}&payDate=${e}`),enabled:t&&!!r&&!!e,staleTime:10*6e4})}function rZ(r,e=!0){return wr({queryKey:["coupang-monthly",r],queryFn:()=>Tr(`/settlement/coupang/monthly?yearMonth=${r}`),enabled:e&&!!r,staleTime:5*6e4})}function nZ(r,e,t=!0){return wr({queryKey:["coupang-reconcile",r,e],queryFn:()=>Tr(`/settlement/coupang/reconcile?from=${r}&to=${e}`),enabled:t&&!!r&&!!e,staleTime:5*6e4})}function wM(r){return wr({queryKey:["orders",r],queryFn:()=>{const e=r?new URLSearchParams(r).toString():"";return Tr(`/orders${e?`?${e}`:""}`)},staleTime:3e4})}function HV(r){return wr({queryKey:["product-catalog",r],queryFn:()=>{const e=r?new URLSearchParams(r).toString():"";return Tr(`/product-catalog${e?`?${e}`:""}`)},staleTime:3e4})}function aZ(){return wr({queryKey:["trend-status"],queryFn:()=>Tr("/trend/status"),staleTime:3e4})}async function iZ(r){const e=await fetch(`/api/trend/keyword?q=${encodeURIComponent(r)}`);if(!e.ok)throw new Error(`API /trend/keyword failed: ${e.status}`);return e.json()}async function oZ(r,e=20){const t=await fetch(`/api/trend/platform?id=${encodeURIComponent(r)}&limit=${e}`);if(!t.ok)throw new Error(`API /trend/platform failed: ${t.status}`);return t.json()}function sZ(){return wr({queryKey:["trend-history"],queryFn:()=>Tr("/trend/history?limit=50"),staleTime:5e3,refetchInterval:1e4})}async function FV(){const r=await fetch("/api/orders/sync",{method:"POST"});if(!r.ok)throw new Error(`API /orders/sync failed: ${r.status}`);return r.json()}function UV(){const r=zV(),[e,t]=q.useState(!1),[n,a]=q.useState(null);async function i(){t(!0),a(null);try{const o=await FV();a(`${o.synced}건 동기화 완료`),r.invalidateQueries()}catch{a("동기화 실패")}finally{t(!1)}}return{syncing:e,syncResult:n,handleSync:i}}function YV(){return wr({queryKey:["config"],queryFn:()=>Tr("/config"),staleTime:5e3})}function lZ(){return wr({queryKey:["weekly-stats"],queryFn:()=>Tr("/stats/weekly"),staleTime:3e5})}function uZ(){return wr({queryKey:["period-stats"],queryFn:()=>Tr("/stats/period"),refetchInterval:6e4})}async function TM(r){const e=await fetch("/api/config",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(r)});if(!e.ok)throw new Error(`PUT /api/config failed: ${e.status}`);return e.json()}let CM=null;const XT=new Set;function WV(){for(const r of XT)r()}function vx(r){CM=r,WV()}function XS(){CM=null,WV()}function cZ(){return q.useSyncExternalStore(r=>(XT.add(r),()=>XT.delete(r)),()=>CM)}const Kf={cafe24:{label:"카페24",guide:"https://developers.cafe24.com",cliNote:"sppt config set cafe24 storeId <mallId>",fields:[{key:"storeId",label:"스토어 ID (mallId)",type:"text",placeholder:"mymall"},{key:"clientId",label:"Client ID",type:"text"},{key:"clientSecret",label:"Client Secret",type:"password"},{key:"accessToken",label:"Access Token",type:"text",readOnly:!0,hint:"OAuth 인증 후 자동 발급·갱신"}]},coupang:{label:"쿠팡",guide:"https://wing.coupang.com",cliNote:"sppt config set coupang storeId <vendorId>",ipNote:`Wing 포털 → 판매자정보 → Open API → IP 관리에서 아래 IP를 등록해야 합니다.
50
- 209.71.88.61`,fields:[{key:"storeId",label:"Vendor ID",type:"text",placeholder:"A00123456"},{key:"accessKey",label:"Access Key",type:"text"},{key:"secretKey",label:"Secret Key",type:"password"},{key:"keyExpiresAt",label:"키 만료일",type:"text",readOnly:!0,hint:"키 생성 후 180일. CLI에서 accessKey 입력 시 자동 계산"},{key:"vendorUserId",label:"Wing 포털 ID",type:"text",optional:!0},{key:"outboundShippingPlaceCode",label:"출고지 코드",type:"number",optional:!0,hint:"Wing → 판매자정보 → 출고지 관리"},{key:"returnCenterCode",label:"반품지 코드",type:"text",optional:!0}]},smartstore:{label:"스마트스토어",guide:"https://sell.smartstore.naver.com",cliNote:"sppt config set smartstore clientId <id>",ipNote:`네이버 커머스 API → 애플리케이션 관리 → IP 허용 목록에서 아래 IP를 등록해야 합니다.
51
- 209.71.88.61`,fields:[{key:"clientId",label:"애플리케이션 ID",type:"text"},{key:"clientSecret",label:"애플리케이션 시크릿",type:"password"},{key:"accessToken",label:"Access Token",type:"text",readOnly:!0,hint:"자동 발급·갱신"},{key:"quickSettlement",label:"빠른정산 사용 중",type:"boolean",optional:!0,hint:"체크 시 정산 기준일이 구매확정일 대신 집화처리일로 계산됩니다"},{key:"isBrandStore",label:"브랜드스토어 여부",type:"boolean",optional:!0,hint:"브랜드스토어는 판매수수료 4% (마케팅링크 2%)"}]},shopify:{label:"Shopify",guide:"https://admin.shopify.com",cliNote:"sppt config set shopify storeId <domain>",fields:[{key:"storeId",label:"스토어 도메인",type:"text",placeholder:"mystore.myshopify.com"},{key:"accessToken",label:"Access Token",type:"password",hint:"Shopify Admin → Apps → 앱 개발 → Token 발급"},{key:"apiVersion",label:"API Version",type:"text",placeholder:"2024-10"}]},"toss-shopping":{label:"토스쇼핑",guide:"https://shopping-seller.toss.im/integration-key",cliNote:"sppt config set toss-shopping clientId <id>",fields:[{key:"clientId",label:"Client ID",type:"text",hint:"토스쇼핑 셀러 포털 → 연동 키 관리"},{key:"clientSecret",label:"Client Secret",type:"password"},{key:"accessToken",label:"Access Token",type:"text",readOnly:!0,hint:"자동 갱신"}]},"29cm":{label:"29CM",guide:"https://openapi.29cm.co.kr",cliNote:"sppt config set 29cm clientId <id>",fields:[{key:"clientId",label:"Client ID",type:"text",hint:"29CM 파트너 포털(29Connect)에서 발급"},{key:"clientSecret",label:"Client Secret",type:"password"},{key:"partnerKey",label:"Partner Key",type:"password",hint:"상품 API 전용 키 (별도 발급)"},{key:"accessToken",label:"Access Token",type:"text",readOnly:!0,hint:"자동 갱신"}]},musinsa:{label:"무신사",guide:"https://partners.musinsa.com",cliNote:"sppt config set musinsa apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"text",hint:"⚠️ 2026-04 현재 공개 API 미제공 — EDI 계약 필요"},{key:"apiSecret",label:"API Secret",type:"password"}]},oliveyoung:{label:"올리브영 파트너 · 브라우저",guide:"https://partner.oliveyoung.co.kr",cliNote:"sppt init browser oliveyoung",fields:[{key:"id",label:"파트너 ID",type:"text",hint:"partner.oliveyoung.co.kr 로그인 ID"},{key:"password",label:"비밀번호",type:"password"}]},kurly:{label:"컬리 파트너 오피스 · 브라우저",guide:"https://3p-partner.kurly.com",cliNote:"sppt init browser kurly",fields:[{key:"id",label:"파트너 ID (이메일)",type:"text"},{key:"password",label:"비밀번호",type:"password"}]},ohouse:{label:"오늘의집 파트너센터 · 브라우저",guide:"https://partner.ohou.se",cliNote:"sppt init browser ohouse",fields:[{key:"id",label:"파트너 ID",type:"text"},{key:"password",label:"비밀번호",type:"password"}]}},AM=new Set(["oliveyoung","kurly","ohouse"]),qT={domeggook:{label:"도매꾹",guide:"https://mobile.domeggook.com/openAPI/management",cliNote:"sppt config set domeggook apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password"}]},domemae:{label:"도매매",cliNote:"sppt config set domemae apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password",hint:"도매꾹 API Key 공유 (동일 계정)"}]},specialoffer:{label:"스페셜오퍼",cliNote:"sppt config set specialoffer apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password"}]},cjdropshipping:{label:"CJ Dropshipping",guide:"https://cjdropshipping.com",cliNote:"sppt config set cjdropshipping accessToken <token>",fields:[{key:"accessToken",label:"Access Token",type:"password",hint:"CJ Dropshipping 셀러 센터에서 발급"}]}},ZT={"naver-datalab":{label:"네이버 데이터랩",guide:"https://developers.naver.com/apps",cliNote:"sppt config set naver-datalab clientId <id>",proxyNote:"shopport 공용 키로 검색 트렌드를 조회합니다. 월 요청량이 많거나 전용 키가 필요하면 직접 설정하세요.",fields:[{key:"clientId",label:"Client ID",type:"text",hint:"네이버 개발자 센터 → 내 애플리케이션"},{key:"clientSecret",label:"Client Secret",type:"password"}]},"naver-searchad":{label:"네이버 검색광고",guide:"https://searchad.naver.com",cliNote:"sppt config set naver-searchad customerId <id>",proxyNote:"shopport 공용 키로 키워드 검색량을 조회합니다. 직접 계정을 연결하면 더 정확한 데이터를 얻을 수 있습니다.",fields:[{key:"customerId",label:"Customer ID",type:"text",hint:"네이버 검색광고 → API 관리"},{key:"accessLicense",label:"Access License",type:"text"},{key:"secretKey",label:"Secret Key",type:"password"}]},"naver-shopping":{label:"네이버 쇼핑",guide:"https://developers.naver.com/apps",cliNote:"sppt config set naver-shopping clientId <id>",proxyNote:"shopport 공용 키로 네이버 쇼핑 데이터를 조회합니다. 직접 설정 시 네이버 개발자 센터에서 발급하세요.",fields:[{key:"clientId",label:"Client ID",type:"text"},{key:"clientSecret",label:"Client Secret",type:"password"}]}},$T={"dada-erp":{label:"DADA ERP (세이고)",cliNote:"sppt config set dada-erp apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password",hint:"세이고 ERP → 시스템설정 → API 관리"},{key:"apiSecret",label:"API Secret",type:"password"},{key:"companyCode",label:"업체 코드",type:"text",optional:!0}]},ezadmin:{label:"이지어드민",cliNote:"sppt config set ezadmin apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password",hint:"이지어드민 → 환경설정 → API 연동 관리"},{key:"shopCode",label:"쇼핑몰 코드",type:"text",hint:"가입 시 부여된 코드 (예: SHOP001)"}]},onewms:{label:"OneWMS",cliNote:"sppt config set onewms apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password",hint:"OneWMS → 관리 → API 설정"},{key:"warehouseCode",label:"창고 코드",type:"text"},{key:"clientCode",label:"고객사 코드",type:"text",optional:!0}]},sabangnet:{label:"사방넷",cliNote:"sppt config set sabangnet sabangId <id>",fields:[{key:"sabangId",label:"아이디",type:"text"},{key:"sabangKey",label:"API Key",type:"password",hint:"사방넷 → 기본설정 → API 설정"}]},boxhero:{label:"박스히어로",guide:"https://www.boxhero.io",cliNote:"sppt config set boxhero accessToken <token>",fields:[{key:"accessToken",label:"Access Token",type:"password",hint:"BoxHero → Settings → Integrations → Open API"},{key:"teamId",label:"팀 ID",type:"text",optional:!0}]},"ecount-erp":{label:"이카운트ERP",cliNote:"sppt config set ecount-erp companyCode <code>",fields:[{key:"companyCode",label:"회사 코드",type:"text",hint:"로그인 화면에서 확인"},{key:"userId",label:"아이디",type:"text"},{key:"apiKey",label:"API Key",type:"password",hint:"ERP → 시스템관리 → Open API 설정"},{key:"zoneCode",label:"Zone 코드 (A~E)",type:"text",optional:!0}]},"douzone-wehago":{label:"더존 WEHAGO",guide:"https://developer.wehago.com",cliNote:"sppt config set douzone-wehago clientId <id>",fields:[{key:"clientId",label:"Client ID",type:"text",hint:"더존 개발자 포털에서 발급"},{key:"clientSecret",label:"Client Secret",type:"password"},{key:"companyCode",label:"회사 코드",type:"text"},{key:"accessToken",label:"Access Token",type:"text",readOnly:!0,hint:"자동 갱신"}]},playauto:{label:"플레이오토",guide:"https://plto.com/additional/API/",cliNote:"sppt config set playauto apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password"},{key:"apiSecret",label:"API Secret",type:"password"},{key:"shopId",label:"쇼핑몰 ID",type:"text",optional:!0}]},argo:{label:"아르고 풀필먼트",cliNote:"sppt config set argo apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password"},{key:"clientCode",label:"고객사 코드",type:"text",optional:!0}]},poomgo:{label:"품고",cliNote:"sppt config set poomgo apiKey <key>",fields:[{key:"apiKey",label:"API Key",type:"password"},{key:"warehouseCode",label:"창고 코드",type:"text",optional:!0}]}};function XV(r){var e,t,n="";if(typeof r=="string"||typeof r=="number")n+=r;else if(typeof r=="object")if(Array.isArray(r)){var a=r.length;for(e=0;e<a;e++)r[e]&&(t=XV(r[e]))&&(n&&(n+=" "),n+=t)}else for(t in r)r[t]&&(n&&(n+=" "),n+=t);return n}function fZ(){for(var r,e,t=0,n="",a=arguments.length;t<a;t++)(r=arguments[t])&&(e=XV(r))&&(n&&(n+=" "),n+=e);return n}const MM="-",hZ=r=>{const e=vZ(r),{conflictingClassGroups:t,conflictingClassGroupModifiers:n}=r;return{getClassGroupId:o=>{const s=o.split(MM);return s[0]===""&&s.length!==1&&s.shift(),qV(s,e)||dZ(o)},getConflictingClassGroupIds:(o,s)=>{const l=t[o]||[];return s&&n[o]?[...l,...n[o]]:l}}},qV=(r,e)=>{var o;if(r.length===0)return e.classGroupId;const t=r[0],n=e.nextPart.get(t),a=n?qV(r.slice(1),n):void 0;if(a)return a;if(e.validators.length===0)return;const i=r.join(MM);return(o=e.validators.find(({validator:s})=>s(i)))==null?void 0:o.classGroupId},FI=/^\[(.+)\]$/,dZ=r=>{if(FI.test(r)){const e=FI.exec(r)[1],t=e==null?void 0:e.substring(0,e.indexOf(":"));if(t)return"arbitrary.."+t}},vZ=r=>{const{theme:e,prefix:t}=r,n={nextPart:new Map,validators:[]};return gZ(Object.entries(r.classGroups),t).forEach(([i,o])=>{KT(o,n,i,e)}),n},KT=(r,e,t,n)=>{r.forEach(a=>{if(typeof a=="string"){const i=a===""?e:UI(e,a);i.classGroupId=t;return}if(typeof a=="function"){if(pZ(a)){KT(a(n),e,t,n);return}e.validators.push({validator:a,classGroupId:t});return}Object.entries(a).forEach(([i,o])=>{KT(o,UI(e,i),t,n)})})},UI=(r,e)=>{let t=r;return e.split(MM).forEach(n=>{t.nextPart.has(n)||t.nextPart.set(n,{nextPart:new Map,validators:[]}),t=t.nextPart.get(n)}),t},pZ=r=>r.isThemeGetter,gZ=(r,e)=>e?r.map(([t,n])=>{const a=n.map(i=>typeof i=="string"?e+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([o,s])=>[e+o,s])):i);return[t,a]}):r,mZ=r=>{if(r<1)return{get:()=>{},set:()=>{}};let e=0,t=new Map,n=new Map;const a=(i,o)=>{t.set(i,o),e++,e>r&&(e=0,n=t,t=new Map)};return{get(i){let o=t.get(i);if(o!==void 0)return o;if((o=n.get(i))!==void 0)return a(i,o),o},set(i,o){t.has(i)?t.set(i,o):a(i,o)}}},ZV="!",yZ=r=>{const{separator:e,experimentalParseClassName:t}=r,n=e.length===1,a=e[0],i=e.length,o=s=>{const l=[];let u=0,c=0,f;for(let x=0;x<s.length;x++){let b=s[x];if(u===0){if(b===a&&(n||s.slice(x,x+i)===e)){l.push(s.slice(c,x)),c=x+i;continue}if(b==="/"){f=x;continue}}b==="["?u++:b==="]"&&u--}const d=l.length===0?s:s.substring(c),v=d.startsWith(ZV),g=v?d.substring(1):d,y=f&&f>c?f-c:void 0;return{modifiers:l,hasImportantModifier:v,baseClassName:g,maybePostfixModifierPosition:y}};return t?s=>t({className:s,parseClassName:o}):o},xZ=r=>{if(r.length<=1)return r;const e=[];let t=[];return r.forEach(n=>{n[0]==="["?(e.push(...t.sort(),n),t=[]):t.push(n)}),e.push(...t.sort()),e},bZ=r=>({cache:mZ(r.cacheSize),parseClassName:yZ(r),...hZ(r)}),_Z=/\s+/,SZ=(r,e)=>{const{parseClassName:t,getClassGroupId:n,getConflictingClassGroupIds:a}=e,i=[],o=r.trim().split(_Z);let s="";for(let l=o.length-1;l>=0;l-=1){const u=o[l],{modifiers:c,hasImportantModifier:f,baseClassName:d,maybePostfixModifierPosition:v}=t(u);let g=!!v,y=n(g?d.substring(0,v):d);if(!y){if(!g){s=u+(s.length>0?" "+s:s);continue}if(y=n(d),!y){s=u+(s.length>0?" "+s:s);continue}g=!1}const x=xZ(c).join(":"),b=f?x+ZV:x,w=b+y;if(i.includes(w))continue;i.push(w);const T=a(y,g);for(let C=0;C<T.length;++C){const D=T[C];i.push(b+D)}s=u+(s.length>0?" "+s:s)}return s};function wZ(){let r=0,e,t,n="";for(;r<arguments.length;)(e=arguments[r++])&&(t=$V(e))&&(n&&(n+=" "),n+=t);return n}const $V=r=>{if(typeof r=="string")return r;let e,t="";for(let n=0;n<r.length;n++)r[n]&&(e=$V(r[n]))&&(t&&(t+=" "),t+=e);return t};function TZ(r,...e){let t,n,a,i=o;function o(l){const u=e.reduce((c,f)=>f(c),r());return t=bZ(u),n=t.cache.get,a=t.cache.set,i=s,s(l)}function s(l){const u=n(l);if(u)return u;const c=SZ(l,t);return a(l,c),c}return function(){return i(wZ.apply(null,arguments))}}const Xt=r=>{const e=t=>t[r]||[];return e.isThemeGetter=!0,e},KV=/^\[(?:([a-z-]+):)?(.+)\]$/i,CZ=/^\d+\/\d+$/,AZ=new Set(["px","full","screen"]),MZ=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,DZ=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,NZ=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,LZ=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,RZ=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,yo=r=>ih(r)||AZ.has(r)||CZ.test(r),Ls=r=>qh(r,"length",BZ),ih=r=>!!r&&!Number.isNaN(Number(r)),qS=r=>qh(r,"number",ih),yv=r=>!!r&&Number.isInteger(Number(r)),EZ=r=>r.endsWith("%")&&ih(r.slice(0,-1)),ct=r=>KV.test(r),Rs=r=>MZ.test(r),kZ=new Set(["length","size","percentage"]),IZ=r=>qh(r,kZ,QV),OZ=r=>qh(r,"position",QV),PZ=new Set(["image","url"]),jZ=r=>qh(r,PZ,GZ),zZ=r=>qh(r,"",VZ),xv=()=>!0,qh=(r,e,t)=>{const n=KV.exec(r);return n?n[1]?typeof e=="string"?n[1]===e:e.has(n[1]):t(n[2]):!1},BZ=r=>DZ.test(r)&&!NZ.test(r),QV=()=>!1,VZ=r=>LZ.test(r),GZ=r=>RZ.test(r),HZ=()=>{const r=Xt("colors"),e=Xt("spacing"),t=Xt("blur"),n=Xt("brightness"),a=Xt("borderColor"),i=Xt("borderRadius"),o=Xt("borderSpacing"),s=Xt("borderWidth"),l=Xt("contrast"),u=Xt("grayscale"),c=Xt("hueRotate"),f=Xt("invert"),d=Xt("gap"),v=Xt("gradientColorStops"),g=Xt("gradientColorStopPositions"),y=Xt("inset"),x=Xt("margin"),b=Xt("opacity"),w=Xt("padding"),T=Xt("saturate"),C=Xt("scale"),D=Xt("sepia"),M=Xt("skew"),N=Xt("space"),R=Xt("translate"),E=()=>["auto","contain","none"],k=()=>["auto","hidden","clip","visible","scroll"],I=()=>["auto",ct,e],B=()=>[ct,e],P=()=>["",yo,Ls],H=()=>["auto",ih,ct],V=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],j=()=>["solid","dashed","dotted","double","none"],U=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],F=()=>["start","end","center","between","around","evenly","stretch"],X=()=>["","0",ct],G=()=>["auto","avoid","all","avoid-page","page","left","right","column"],W=()=>[ih,ct];return{cacheSize:500,separator:":",theme:{colors:[xv],spacing:[yo,Ls],blur:["none","",Rs,ct],brightness:W(),borderColor:[r],borderRadius:["none","","full",Rs,ct],borderSpacing:B(),borderWidth:P(),contrast:W(),grayscale:X(),hueRotate:W(),invert:X(),gap:B(),gradientColorStops:[r],gradientColorStopPositions:[EZ,Ls],inset:I(),margin:I(),opacity:W(),padding:B(),saturate:W(),scale:W(),sepia:X(),skew:W(),space:B(),translate:B()},classGroups:{aspect:[{aspect:["auto","square","video",ct]}],container:["container"],columns:[{columns:[Rs]}],"break-after":[{"break-after":G()}],"break-before":[{"break-before":G()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...V(),ct]}],overflow:[{overflow:k()}],"overflow-x":[{"overflow-x":k()}],"overflow-y":[{"overflow-y":k()}],overscroll:[{overscroll:E()}],"overscroll-x":[{"overscroll-x":E()}],"overscroll-y":[{"overscroll-y":E()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[y]}],"inset-x":[{"inset-x":[y]}],"inset-y":[{"inset-y":[y]}],start:[{start:[y]}],end:[{end:[y]}],top:[{top:[y]}],right:[{right:[y]}],bottom:[{bottom:[y]}],left:[{left:[y]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",yv,ct]}],basis:[{basis:I()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",ct]}],grow:[{grow:X()}],shrink:[{shrink:X()}],order:[{order:["first","last","none",yv,ct]}],"grid-cols":[{"grid-cols":[xv]}],"col-start-end":[{col:["auto",{span:["full",yv,ct]},ct]}],"col-start":[{"col-start":H()}],"col-end":[{"col-end":H()}],"grid-rows":[{"grid-rows":[xv]}],"row-start-end":[{row:["auto",{span:[yv,ct]},ct]}],"row-start":[{"row-start":H()}],"row-end":[{"row-end":H()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",ct]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",ct]}],gap:[{gap:[d]}],"gap-x":[{"gap-x":[d]}],"gap-y":[{"gap-y":[d]}],"justify-content":[{justify:["normal",...F()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...F(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...F(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[w]}],px:[{px:[w]}],py:[{py:[w]}],ps:[{ps:[w]}],pe:[{pe:[w]}],pt:[{pt:[w]}],pr:[{pr:[w]}],pb:[{pb:[w]}],pl:[{pl:[w]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[N]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[N]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",ct,e]}],"min-w":[{"min-w":[ct,e,"min","max","fit"]}],"max-w":[{"max-w":[ct,e,"none","full","min","max","fit","prose",{screen:[Rs]},Rs]}],h:[{h:[ct,e,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[ct,e,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[ct,e,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[ct,e,"auto","min","max","fit"]}],"font-size":[{text:["base",Rs,Ls]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",qS]}],"font-family":[{font:[xv]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",ct]}],"line-clamp":[{"line-clamp":["none",ih,qS]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",yo,ct]}],"list-image":[{"list-image":["none",ct]}],"list-style-type":[{list:["none","disc","decimal",ct]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[r]}],"placeholder-opacity":[{"placeholder-opacity":[b]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[r]}],"text-opacity":[{"text-opacity":[b]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...j(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",yo,Ls]}],"underline-offset":[{"underline-offset":["auto",yo,ct]}],"text-decoration-color":[{decoration:[r]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:B()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ct]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",ct]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[b]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...V(),OZ]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",IZ]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},jZ]}],"bg-color":[{bg:[r]}],"gradient-from-pos":[{from:[g]}],"gradient-via-pos":[{via:[g]}],"gradient-to-pos":[{to:[g]}],"gradient-from":[{from:[v]}],"gradient-via":[{via:[v]}],"gradient-to":[{to:[v]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[b]}],"border-style":[{border:[...j(),"hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[b]}],"divide-style":[{divide:j()}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["",...j()]}],"outline-offset":[{"outline-offset":[yo,ct]}],"outline-w":[{outline:[yo,Ls]}],"outline-color":[{outline:[r]}],"ring-w":[{ring:P()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[r]}],"ring-opacity":[{"ring-opacity":[b]}],"ring-offset-w":[{"ring-offset":[yo,Ls]}],"ring-offset-color":[{"ring-offset":[r]}],shadow:[{shadow:["","inner","none",Rs,zZ]}],"shadow-color":[{shadow:[xv]}],opacity:[{opacity:[b]}],"mix-blend":[{"mix-blend":[...U(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":U()}],filter:[{filter:["","none"]}],blur:[{blur:[t]}],brightness:[{brightness:[n]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Rs,ct]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[c]}],invert:[{invert:[f]}],saturate:[{saturate:[T]}],sepia:[{sepia:[D]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[t]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[c]}],"backdrop-invert":[{"backdrop-invert":[f]}],"backdrop-opacity":[{"backdrop-opacity":[b]}],"backdrop-saturate":[{"backdrop-saturate":[T]}],"backdrop-sepia":[{"backdrop-sepia":[D]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[o]}],"border-spacing-x":[{"border-spacing-x":[o]}],"border-spacing-y":[{"border-spacing-y":[o]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",ct]}],duration:[{duration:W()}],ease:[{ease:["linear","in","out","in-out",ct]}],delay:[{delay:W()}],animate:[{animate:["none","spin","ping","pulse","bounce",ct]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[C]}],"scale-x":[{"scale-x":[C]}],"scale-y":[{"scale-y":[C]}],rotate:[{rotate:[yv,ct]}],"translate-x":[{"translate-x":[R]}],"translate-y":[{"translate-y":[R]}],"skew-x":[{"skew-x":[M]}],"skew-y":[{"skew-y":[M]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",ct]}],accent:[{accent:["auto",r]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",ct]}],"caret-color":[{caret:[r]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":B()}],"scroll-mx":[{"scroll-mx":B()}],"scroll-my":[{"scroll-my":B()}],"scroll-ms":[{"scroll-ms":B()}],"scroll-me":[{"scroll-me":B()}],"scroll-mt":[{"scroll-mt":B()}],"scroll-mr":[{"scroll-mr":B()}],"scroll-mb":[{"scroll-mb":B()}],"scroll-ml":[{"scroll-ml":B()}],"scroll-p":[{"scroll-p":B()}],"scroll-px":[{"scroll-px":B()}],"scroll-py":[{"scroll-py":B()}],"scroll-ps":[{"scroll-ps":B()}],"scroll-pe":[{"scroll-pe":B()}],"scroll-pt":[{"scroll-pt":B()}],"scroll-pr":[{"scroll-pr":B()}],"scroll-pb":[{"scroll-pb":B()}],"scroll-pl":[{"scroll-pl":B()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",ct]}],fill:[{fill:[r,"none"]}],"stroke-w":[{stroke:[yo,Ls,qS]}],stroke:[{stroke:[r,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},FZ=TZ(HZ);function Ae(...r){return FZ(fZ(r))}/**
52
- * @license lucide-react v0.469.0 - ISC
53
- *
54
- * This source code is licensed under the ISC license.
55
- * See the LICENSE file in the root directory of this source tree.
56
- */const UZ=r=>r.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),JV=(...r)=>r.filter((e,t,n)=>!!e&&e.trim()!==""&&n.indexOf(e)===t).join(" ").trim();/**
57
- * @license lucide-react v0.469.0 - ISC
58
- *
59
- * This source code is licensed under the ISC license.
60
- * See the LICENSE file in the root directory of this source tree.
61
- */var YZ={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
62
- * @license lucide-react v0.469.0 - ISC
63
- *
64
- * This source code is licensed under the ISC license.
65
- * See the LICENSE file in the root directory of this source tree.
66
- */const WZ=q.forwardRef(({color:r="currentColor",size:e=24,strokeWidth:t=2,absoluteStrokeWidth:n,className:a="",children:i,iconNode:o,...s},l)=>q.createElement("svg",{ref:l,...YZ,width:e,height:e,stroke:r,strokeWidth:n?Number(t)*24/Number(e):t,className:JV("lucide",a),...s},[...o.map(([u,c])=>q.createElement(u,c)),...Array.isArray(i)?i:[i]]));/**
67
- * @license lucide-react v0.469.0 - ISC
68
- *
69
- * This source code is licensed under the ISC license.
70
- * See the LICENSE file in the root directory of this source tree.
71
- */const Tt=(r,e)=>{const t=q.forwardRef(({className:n,...a},i)=>q.createElement(WZ,{ref:i,iconNode:e,className:JV(`lucide-${UZ(r)}`,n),...a}));return t.displayName=`${r}`,t};/**
72
- * @license lucide-react v0.469.0 - ISC
73
- *
74
- * This source code is licensed under the ISC license.
75
- * See the LICENSE file in the root directory of this source tree.
76
- */const XZ=Tt("Award",[["path",{d:"m15.477 12.89 1.515 8.526a.5.5 0 0 1-.81.47l-3.58-2.687a1 1 0 0 0-1.197 0l-3.586 2.686a.5.5 0 0 1-.81-.469l1.514-8.526",key:"1yiouv"}],["circle",{cx:"12",cy:"8",r:"6",key:"1vp47v"}]]);/**
77
- * @license lucide-react v0.469.0 - ISC
78
- *
79
- * This source code is licensed under the ISC license.
80
- * See the LICENSE file in the root directory of this source tree.
81
- */const Hp=Tt("ChartNoAxesColumn",[["line",{x1:"18",x2:"18",y1:"20",y2:"10",key:"1xfpm4"}],["line",{x1:"12",x2:"12",y1:"20",y2:"4",key:"be30l9"}],["line",{x1:"6",x2:"6",y1:"20",y2:"14",key:"1r4le6"}]]);/**
82
- * @license lucide-react v0.469.0 - ISC
83
- *
84
- * This source code is licensed under the ISC license.
85
- * See the LICENSE file in the root directory of this source tree.
86
- */const Eg=Tt("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
87
- * @license lucide-react v0.469.0 - ISC
88
- *
89
- * This source code is licensed under the ISC license.
90
- * See the LICENSE file in the root directory of this source tree.
91
- */const Sn=Tt("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
92
- * @license lucide-react v0.469.0 - ISC
93
- *
94
- * This source code is licensed under the ISC license.
95
- * See the LICENSE file in the root directory of this source tree.
96
- */const qZ=Tt("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
97
- * @license lucide-react v0.469.0 - ISC
98
- *
99
- * This source code is licensed under the ISC license.
100
- * See the LICENSE file in the root directory of this source tree.
101
- */const Pn=Tt("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
102
- * @license lucide-react v0.469.0 - ISC
103
- *
104
- * This source code is licensed under the ISC license.
105
- * See the LICENSE file in the root directory of this source tree.
106
- */const DM=Tt("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
107
- * @license lucide-react v0.469.0 - ISC
108
- *
109
- * This source code is licensed under the ISC license.
110
- * See the LICENSE file in the root directory of this source tree.
111
- */const YI=Tt("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
112
- * @license lucide-react v0.469.0 - ISC
113
- *
114
- * This source code is licensed under the ISC license.
115
- * See the LICENSE file in the root directory of this source tree.
116
- */const ZZ=Tt("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
117
- * @license lucide-react v0.469.0 - ISC
118
- *
119
- * This source code is licensed under the ISC license.
120
- * See the LICENSE file in the root directory of this source tree.
121
- */const $Z=Tt("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
122
- * @license lucide-react v0.469.0 - ISC
123
- *
124
- * This source code is licensed under the ISC license.
125
- * See the LICENSE file in the root directory of this source tree.
126
- */const kg=Tt("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);/**
127
- * @license lucide-react v0.469.0 - ISC
128
- *
129
- * This source code is licensed under the ISC license.
130
- * See the LICENSE file in the root directory of this source tree.
131
- */const WI=Tt("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/**
132
- * @license lucide-react v0.469.0 - ISC
133
- *
134
- * This source code is licensed under the ISC license.
135
- * See the LICENSE file in the root directory of this source tree.
136
- */const KZ=Tt("History",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]);/**
137
- * @license lucide-react v0.469.0 - ISC
138
- *
139
- * This source code is licensed under the ISC license.
140
- * See the LICENSE file in the root directory of this source tree.
141
- */const eG=Tt("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
142
- * @license lucide-react v0.469.0 - ISC
143
- *
144
- * This source code is licensed under the ISC license.
145
- * See the LICENSE file in the root directory of this source tree.
146
- */const QZ=Tt("LayoutDashboard",[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]]);/**
147
- * @license lucide-react v0.469.0 - ISC
148
- *
149
- * This source code is licensed under the ISC license.
150
- * See the LICENSE file in the root directory of this source tree.
151
- */const JZ=Tt("Link2",[["path",{d:"M9 17H7A5 5 0 0 1 7 7h2",key:"8i5ue5"}],["path",{d:"M15 7h2a5 5 0 1 1 0 10h-2",key:"1b9ql8"}],["line",{x1:"8",x2:"16",y1:"12",y2:"12",key:"1jonct"}]]);/**
152
- * @license lucide-react v0.469.0 - ISC
153
- *
154
- * This source code is licensed under the ISC license.
155
- * See the LICENSE file in the root directory of this source tree.
156
- */const e$=Tt("Link",[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]]);/**
157
- * @license lucide-react v0.469.0 - ISC
158
- *
159
- * This source code is licensed under the ISC license.
160
- * See the LICENSE file in the root directory of this source tree.
161
- */const t$=Tt("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
162
- * @license lucide-react v0.469.0 - ISC
163
- *
164
- * This source code is licensed under the ISC license.
165
- * See the LICENSE file in the root directory of this source tree.
166
- */const tG=Tt("LockOpen",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 9.9-1",key:"1mm8w8"}]]);/**
167
- * @license lucide-react v0.469.0 - ISC
168
- *
169
- * This source code is licensed under the ISC license.
170
- * See the LICENSE file in the root directory of this source tree.
171
- */const QT=Tt("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
172
- * @license lucide-react v0.469.0 - ISC
173
- *
174
- * This source code is licensed under the ISC license.
175
- * See the LICENSE file in the root directory of this source tree.
176
- */const px=Tt("Package",[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["path",{d:"m3.3 7 7.703 4.734a2 2 0 0 0 1.994 0L20.7 7",key:"yx3hmr"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]]);/**
177
- * @license lucide-react v0.469.0 - ISC
178
- *
179
- * This source code is licensed under the ISC license.
180
- * See the LICENSE file in the root directory of this source tree.
181
- */const r$=Tt("Receipt",[["path",{d:"M4 2v20l2-1 2 1 2-1 2 1 2-1 2 1 2-1 2 1V2l-2 1-2-1-2 1-2-1-2 1-2-1-2 1Z",key:"q3az6g"}],["path",{d:"M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8",key:"1h4pet"}],["path",{d:"M12 17.5v-11",key:"1jc1ny"}]]);/**
182
- * @license lucide-react v0.469.0 - ISC
183
- *
184
- * This source code is licensed under the ISC license.
185
- * See the LICENSE file in the root directory of this source tree.
186
- */const F0=Tt("RefreshCcw",[["path",{d:"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"14sxne"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16",key:"1hlbsb"}],["path",{d:"M16 16h5v5",key:"ccwih5"}]]);/**
187
- * @license lucide-react v0.469.0 - ISC
188
- *
189
- * This source code is licensed under the ISC license.
190
- * See the LICENSE file in the root directory of this source tree.
191
- */const rG=Tt("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
192
- * @license lucide-react v0.469.0 - ISC
193
- *
194
- * This source code is licensed under the ISC license.
195
- * See the LICENSE file in the root directory of this source tree.
196
- */const k1=Tt("Save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);/**
197
- * @license lucide-react v0.469.0 - ISC
198
- *
199
- * This source code is licensed under the ISC license.
200
- * See the LICENSE file in the root directory of this source tree.
201
- */const Fp=Tt("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
202
- * @license lucide-react v0.469.0 - ISC
203
- *
204
- * This source code is licensed under the ISC license.
205
- * See the LICENSE file in the root directory of this source tree.
206
- */const n$=Tt("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
207
- * @license lucide-react v0.469.0 - ISC
208
- *
209
- * This source code is licensed under the ISC license.
210
- * See the LICENSE file in the root directory of this source tree.
211
- */const a$=Tt("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
212
- * @license lucide-react v0.469.0 - ISC
213
- *
214
- * This source code is licensed under the ISC license.
215
- * See the LICENSE file in the root directory of this source tree.
216
- */const nG=Tt("ShoppingCart",[["circle",{cx:"8",cy:"21",r:"1",key:"jimo8o"}],["circle",{cx:"19",cy:"21",r:"1",key:"13723u"}],["path",{d:"M2.05 2.05h2l2.66 12.42a2 2 0 0 0 2 1.58h9.78a2 2 0 0 0 1.95-1.57l1.65-7.43H5.12",key:"9zh506"}]]);/**
217
- * @license lucide-react v0.469.0 - ISC
218
- *
219
- * This source code is licensed under the ISC license.
220
- * See the LICENSE file in the root directory of this source tree.
221
- */const aG=Tt("TrendingDown",[["polyline",{points:"22 17 13.5 8.5 8.5 13.5 2 7",key:"1r2t7k"}],["polyline",{points:"16 17 22 17 22 11",key:"11uiuu"}]]);/**
222
- * @license lucide-react v0.469.0 - ISC
223
- *
224
- * This source code is licensed under the ISC license.
225
- * See the LICENSE file in the root directory of this source tree.
226
- */const ll=Tt("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]);/**
227
- * @license lucide-react v0.469.0 - ISC
228
- *
229
- * This source code is licensed under the ISC license.
230
- * See the LICENSE file in the root directory of this source tree.
231
- */const iG=Tt("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
232
- * @license lucide-react v0.469.0 - ISC
233
- *
234
- * This source code is licensed under the ISC license.
235
- * See the LICENSE file in the root directory of this source tree.
236
- */const ml=Tt("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
237
- * @license lucide-react v0.469.0 - ISC
238
- *
239
- * This source code is licensed under the ISC license.
240
- * See the LICENSE file in the root directory of this source tree.
241
- */const i$=Tt("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]);function XI(r){return AM.has(r)&&Kf[r]?{schema:Kf[r],group:"browserChannels"}:Kf[r]?{schema:Kf[r],group:"channels"}:qT[r]?{schema:qT[r],group:"sourceChannels"}:ZT[r]?{schema:ZT[r],group:"trendChannels"}:$T[r]?{schema:$T[r],group:"logisticsChannels"}:null}function o$({schema:r,current:e,onSave:t,saving:n,saved:a}){const i=r.fields.filter(v=>!v.readOnly),o=r.fields.filter(v=>v.readOnly),s=i.some(v=>{const g=e[v.key];return g!==void 0&&g!==""&&g!==null}),[l,u]=q.useState(!r.proxyNote||s),[c,f]=q.useState(()=>{const v={};for(const g of i){const y=e[g.key];g.type==="boolean"?v[g.key]=!!y:g.type==="number"?v[g.key]=y!==void 0&&y!==""?Number(y):"":v[g.key]=String(y??"")}return v});function d(){if(!i.some(y=>{const x=c[y.key];return x!==""&&x!==void 0})){t({});return}const g={...e};for(const y of i){const x=c[y.key];x!==""&&x!==void 0?g[y.key]=x:delete g[y.key]}t(g)}return _.jsxs("div",{className:"space-y-3",children:[(r.guide||r.cliNote)&&_.jsxs("div",{className:"flex items-center gap-4 text-[11px] text-muted-foreground border-b border-border/50 pb-2",children:[r.guide&&_.jsxs("a",{href:r.guide,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1 hover:text-foreground transition-colors",children:[_.jsx(kg,{size:10}),"자격증명 발급"]}),r.cliNote&&_.jsx("code",{className:"font-mono text-[10px] bg-muted px-1.5 py-0.5 rounded text-foreground/70",children:r.cliNote})]}),r.proxyNote&&!l?_.jsxs("div",{className:"flex items-start justify-between gap-4",children:[_.jsx("p",{className:"text-[12px] text-foreground/80",children:r.proxyNote}),_.jsxs("button",{type:"button",onClick:()=>u(!0),className:"shrink-0 flex items-center gap-1.5 px-3 py-1.5 text-[11px] border border-border rounded hover:bg-muted transition-colors",children:[_.jsx(tG,{size:10}),"직접 설정"]})]}):_.jsxs("div",{className:"space-y-2.5",children:[r.proxyNote&&l&&_.jsxs("div",{className:"flex items-center justify-between pb-1 border-b border-border/50",children:[_.jsx("span",{className:"text-[11px] text-muted-foreground",children:"직접 설정 중"}),_.jsxs("button",{type:"button",onClick:()=>u(!1),className:"flex items-center gap-1 text-[11px] text-muted-foreground hover:text-foreground",children:[_.jsx(QT,{size:10})," 공용 키로 전환"]})]}),i.map(v=>_.jsx(oG,{field:v,value:c[v.key],onChange:f},v.key)),o.filter(v=>e[v.key]!==void 0&&e[v.key]!=="").map(v=>_.jsxs("div",{className:"grid grid-cols-[140px_1fr] items-start gap-3",children:[_.jsx("span",{className:"text-[12px] text-right pt-1.5 text-muted-foreground/50",children:v.label}),_.jsx("div",{className:"h-7 px-2 flex items-center",children:_.jsx("span",{className:"text-[12px] font-mono text-muted-foreground/70 truncate",children:v.type==="password"?"••••••••":String(e[v.key])})})]},v.key)),r.ipNote&&_.jsx("div",{className:"py-2.5 px-3 bg-amber-50 dark:bg-amber-950/30 rounded-md border border-amber-200/60 dark:border-amber-800/40",children:r.ipNote.split(`
242
- `).map((v,g)=>g===0?_.jsx("p",{className:"text-[11px] text-amber-800 dark:text-amber-300",children:v},v):_.jsx("p",{className:"mt-0.5 font-mono text-[12px] font-semibold text-amber-900 dark:text-amber-200 select-all",children:v},v))}),_.jsxs("div",{className:"flex items-center justify-end gap-2 pt-1",children:[a&&_.jsxs("span",{className:"text-[11px] text-emerald-600 flex items-center gap-1",children:[_.jsx(Eg,{size:11})," 저장됨"]}),_.jsxs("button",{type:"button",onClick:d,disabled:n,className:"flex items-center gap-1.5 px-3 py-1.5 text-[12px] bg-primary text-primary-foreground rounded hover:bg-primary/90 disabled:opacity-50 transition-colors",children:[_.jsx(k1,{size:11}),n?"저장 중...":"저장"]})]})]})]})}function oG({field:r,value:e,onChange:t}){return _.jsxs("div",{className:"grid grid-cols-[140px_1fr] items-start gap-3",children:[_.jsxs("span",{className:Ae("text-[12px] text-right pt-1.5 leading-tight",r.optional?"text-muted-foreground/60":"text-muted-foreground"),children:[r.label,r.optional&&_.jsx("span",{className:"ml-1 text-[10px]",children:"(선택)"})]}),_.jsxs("div",{className:"space-y-0.5",children:[r.type==="boolean"?_.jsx("input",{type:"checkbox",checked:!!e,onChange:n=>t(a=>({...a,[r.key]:n.target.checked})),className:"w-4 h-4 accent-primary mt-1.5"}):_.jsx("input",{type:r.type==="password"?"password":r.type==="number"?"number":"text",value:String(e??""),placeholder:r.placeholder??"",onChange:n=>t(a=>({...a,[r.key]:n.target.value})),className:"h-7 px-2 text-[12px] border border-border rounded bg-background w-full font-mono focus:outline-none focus:ring-1 focus:ring-primary/50"}),r.hint&&_.jsx("p",{className:"text-[10px] text-muted-foreground/70 pl-0.5",children:r.hint})]})]})}function s$({config:r,onSaved:e}){var u;const[t,n]=q.useState(!1),[a,i]=q.useState(!1),[o,s]=q.useState(String(((u=r.settlement)==null?void 0:u.annualRevenue)??""));async function l(){n(!0);try{await TM({...r,settlement:{...r.settlement??{},annualRevenue:o?Number(o):void 0}}),i(!0),e(),setTimeout(()=>i(!1),2e3)}finally{n(!1)}}return _.jsxs("div",{className:"space-y-3",children:[_.jsx("p",{className:"text-[12px] text-muted-foreground leading-relaxed",children:"스마트스토어 Npay 등급, 카페24 카드 영중소 우대 등 채널별 수수료율이 연 매출 기준으로 결정됩니다."}),_.jsx(oG,{field:{key:"annualRevenue",label:"연 매출 (원)",type:"number",placeholder:"500000000",optional:!0,hint:"대략적인 구간만 맞아도 등급 판정에 충분합니다."},value:o,onChange:c=>{const f=typeof c=="function"?c({annualRevenue:o}):c;s(String(f.annualRevenue??""))}}),_.jsxs("div",{className:"flex items-center justify-end gap-2 pt-1",children:[a&&_.jsxs("span",{className:"text-[11px] text-emerald-600 flex items-center gap-1",children:[_.jsx(Eg,{size:11})," 저장됨"]}),_.jsxs("button",{type:"button",onClick:l,disabled:t,className:"flex items-center gap-1.5 px-3 py-1.5 text-[12px] bg-primary text-primary-foreground rounded hover:bg-primary/90 disabled:opacity-50 transition-colors",children:[_.jsx(k1,{size:11}),t?"저장 중...":"저장"]})]})]})}function l$(){var c;const r=cZ(),{data:e,refetch:t}=YV(),[n,a]=q.useState(!1),[i,o]=q.useState(!1),s=q.useCallback(f=>{f.key==="Escape"&&XS()},[]);if(q.useEffect(()=>{if(r)return document.addEventListener("keydown",s),()=>document.removeEventListener("keydown",s)},[r,s]),!r||!e)return null;const l=r.type==="annualRevenue"?"연 매출 설정":((c=XI(r.channel))==null?void 0:c.schema.label)??r.channel;function u(f,d,v){const g={...e[f]};Object.keys(v).length>0?g[d]={...v,channel:d}:delete g[d];const y={...e,[f]:g};a(!0),TM(y).then(()=>{o(!0),t(),setTimeout(()=>o(!1),2e3)}).finally(()=>a(!1))}return _.jsx("div",{className:"fixed inset-0 z-50 flex items-start justify-center pt-[15vh] bg-black/40 backdrop-blur-sm",onClick:f=>{f.target===f.currentTarget&&XS()},onKeyDown:()=>{},children:_.jsxs("div",{className:"bg-card border border-border rounded-xl shadow-2xl w-full max-w-[480px] max-h-[70vh] overflow-y-auto",children:[_.jsxs("div",{className:"flex items-center justify-between px-5 py-3.5 border-b border-border sticky top-0 bg-card rounded-t-xl z-10",children:[_.jsx("h3",{className:"text-[14px] font-semibold",children:l}),_.jsx("button",{type:"button",onClick:XS,className:"p-1 rounded hover:bg-muted transition-colors text-muted-foreground hover:text-foreground",children:_.jsx(ml,{size:15})})]}),_.jsxs("div",{className:"px-5 py-4",children:[r.type==="annualRevenue"&&_.jsx(s$,{config:e,onSaved:()=>t()}),r.type==="channel"&&(()=>{var d;const f=XI(r.channel);return f?_.jsx(o$,{schema:f.schema,current:((d=e[f.group])==null?void 0:d[r.channel])??{},onSave:v=>u(f.group,r.channel,v),saving:n,saved:i}):_.jsxs("p",{className:"text-[12px] text-muted-foreground",children:["알 수 없는 채널: ",r.channel]})})()]})]})})}function Lo(r,e,{checkForDefaultPrevented:t=!0}={}){return function(a){if(r==null||r(a),t===!1||!a.defaultPrevented)return e==null?void 0:e(a)}}function qI(r,e){if(typeof r=="function")return r(e);r!=null&&(r.current=e)}function sG(...r){return e=>{let t=!1;const n=r.map(a=>{const i=qI(a,e);return!t&&typeof i=="function"&&(t=!0),i});if(t)return()=>{for(let a=0;a<n.length;a++){const i=n[a];typeof i=="function"?i():qI(r[a],null)}}}}function yc(...r){return q.useCallback(sG(...r),r)}function lG(r,e=[]){let t=[];function n(i,o){const s=q.createContext(o),l=t.length;t=[...t,o];const u=f=>{var b;const{scope:d,children:v,...g}=f,y=((b=d==null?void 0:d[r])==null?void 0:b[l])||s,x=q.useMemo(()=>g,Object.values(g));return _.jsx(y.Provider,{value:x,children:v})};u.displayName=i+"Provider";function c(f,d){var y;const v=((y=d==null?void 0:d[r])==null?void 0:y[l])||s,g=q.useContext(v);if(g)return g;if(o!==void 0)return o;throw new Error(`\`${f}\` must be used within \`${i}\``)}return[u,c]}const a=()=>{const i=t.map(o=>q.createContext(o));return function(s){const l=(s==null?void 0:s[r])||i;return q.useMemo(()=>({[`__scope${r}`]:{...s,[r]:l}}),[s,l])}};return a.scopeName=r,[n,u$(a,...e)]}function u$(...r){const e=r[0];if(r.length===1)return e;const t=()=>{const n=r.map(a=>({useScope:a(),scopeName:a.scopeName}));return function(i){const o=n.reduce((s,{useScope:l,scopeName:u})=>{const f=l(i)[`__scope${u}`];return{...s,...f}},{});return q.useMemo(()=>({[`__scope${e.scopeName}`]:o}),[o])}};return t.scopeName=e.scopeName,t}var NM=VV();const c$=mM(NM);function f$(r){const e=h$(r),t=q.forwardRef((n,a)=>{const{children:i,...o}=n,s=q.Children.toArray(i),l=s.find(v$);if(l){const u=l.props.children,c=s.map(f=>f===l?q.Children.count(u)>1?q.Children.only(null):q.isValidElement(u)?u.props.children:null:f);return _.jsx(e,{...o,ref:a,children:q.isValidElement(u)?q.cloneElement(u,void 0,c):null})}return _.jsx(e,{...o,ref:a,children:i})});return t.displayName=`${r}.Slot`,t}function h$(r){const e=q.forwardRef((t,n)=>{const{children:a,...i}=t;if(q.isValidElement(a)){const o=g$(a),s=p$(i,a.props);return a.type!==q.Fragment&&(s.ref=n?sG(n,o):o),q.cloneElement(a,s)}return q.Children.count(a)>1?q.Children.only(null):null});return e.displayName=`${r}.SlotClone`,e}var uG=Symbol("radix.slottable");function d$(r){const e=({children:t})=>_.jsx(_.Fragment,{children:t});return e.displayName=`${r}.Slottable`,e.__radixId=uG,e}function v$(r){return q.isValidElement(r)&&typeof r.type=="function"&&"__radixId"in r.type&&r.type.__radixId===uG}function p$(r,e){const t={...e};for(const n in e){const a=r[n],i=e[n];/^on[A-Z]/.test(n)?a&&i?t[n]=(...s)=>{const l=i(...s);return a(...s),l}:a&&(t[n]=a):n==="style"?t[n]={...a,...i}:n==="className"&&(t[n]=[a,i].filter(Boolean).join(" "))}return{...r,...t}}function g$(r){var n,a;let e=(n=Object.getOwnPropertyDescriptor(r.props,"ref"))==null?void 0:n.get,t=e&&"isReactWarning"in e&&e.isReactWarning;return t?r.ref:(e=(a=Object.getOwnPropertyDescriptor(r,"ref"))==null?void 0:a.get,t=e&&"isReactWarning"in e&&e.isReactWarning,t?r.props.ref:r.props.ref||r.ref)}var m$=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ml=m$.reduce((r,e)=>{const t=f$(`Primitive.${e}`),n=q.forwardRef((a,i)=>{const{asChild:o,...s}=a,l=o?t:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),_.jsx(l,{...s,ref:i})});return n.displayName=`Primitive.${e}`,{...r,[e]:n}},{});function y$(r,e){r&&NM.flushSync(()=>r.dispatchEvent(e))}function I1(r){const e=q.useRef(r);return q.useEffect(()=>{e.current=r}),q.useMemo(()=>(...t)=>{var n;return(n=e.current)==null?void 0:n.call(e,...t)},[])}function x$(r,e=globalThis==null?void 0:globalThis.document){const t=I1(r);q.useEffect(()=>{const n=a=>{a.key==="Escape"&&t(a)};return e.addEventListener("keydown",n,{capture:!0}),()=>e.removeEventListener("keydown",n,{capture:!0})},[t,e])}var b$="DismissableLayer",JT="dismissableLayer.update",_$="dismissableLayer.pointerDownOutside",S$="dismissableLayer.focusOutside",ZI,cG=q.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),fG=q.forwardRef((r,e)=>{const{disableOutsidePointerEvents:t=!1,onEscapeKeyDown:n,onPointerDownOutside:a,onFocusOutside:i,onInteractOutside:o,onDismiss:s,...l}=r,u=q.useContext(cG),[c,f]=q.useState(null),d=(c==null?void 0:c.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,v]=q.useState({}),g=yc(e,N=>f(N)),y=Array.from(u.layers),[x]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),b=y.indexOf(x),w=c?y.indexOf(c):-1,T=u.layersWithOutsidePointerEventsDisabled.size>0,C=w>=b,D=C$(N=>{const R=N.target,E=[...u.branches].some(k=>k.contains(R));!C||E||(a==null||a(N),o==null||o(N),N.defaultPrevented||s==null||s())},d),M=A$(N=>{const R=N.target;[...u.branches].some(k=>k.contains(R))||(i==null||i(N),o==null||o(N),N.defaultPrevented||s==null||s())},d);return x$(N=>{w===u.layers.size-1&&(n==null||n(N),!N.defaultPrevented&&s&&(N.preventDefault(),s()))},d),q.useEffect(()=>{if(c)return t&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(ZI=d.body.style.pointerEvents,d.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(c)),u.layers.add(c),$I(),()=>{t&&u.layersWithOutsidePointerEventsDisabled.size===1&&(d.body.style.pointerEvents=ZI)}},[c,d,t,u]),q.useEffect(()=>()=>{c&&(u.layers.delete(c),u.layersWithOutsidePointerEventsDisabled.delete(c),$I())},[c,u]),q.useEffect(()=>{const N=()=>v({});return document.addEventListener(JT,N),()=>document.removeEventListener(JT,N)},[]),_.jsx(Ml.div,{...l,ref:g,style:{pointerEvents:T?C?"auto":"none":void 0,...r.style},onFocusCapture:Lo(r.onFocusCapture,M.onFocusCapture),onBlurCapture:Lo(r.onBlurCapture,M.onBlurCapture),onPointerDownCapture:Lo(r.onPointerDownCapture,D.onPointerDownCapture)})});fG.displayName=b$;var w$="DismissableLayerBranch",T$=q.forwardRef((r,e)=>{const t=q.useContext(cG),n=q.useRef(null),a=yc(e,n);return q.useEffect(()=>{const i=n.current;if(i)return t.branches.add(i),()=>{t.branches.delete(i)}},[t.branches]),_.jsx(Ml.div,{...r,ref:a})});T$.displayName=w$;function C$(r,e=globalThis==null?void 0:globalThis.document){const t=I1(r),n=q.useRef(!1),a=q.useRef(()=>{});return q.useEffect(()=>{const i=s=>{if(s.target&&!n.current){let l=function(){hG(_$,t,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(e.removeEventListener("click",a.current),a.current=l,e.addEventListener("click",a.current,{once:!0})):l()}else e.removeEventListener("click",a.current);n.current=!1},o=window.setTimeout(()=>{e.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(o),e.removeEventListener("pointerdown",i),e.removeEventListener("click",a.current)}},[e,t]),{onPointerDownCapture:()=>n.current=!0}}function A$(r,e=globalThis==null?void 0:globalThis.document){const t=I1(r),n=q.useRef(!1);return q.useEffect(()=>{const a=i=>{i.target&&!n.current&&hG(S$,t,{originalEvent:i},{discrete:!1})};return e.addEventListener("focusin",a),()=>e.removeEventListener("focusin",a)},[e,t]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function $I(){const r=new CustomEvent(JT);document.dispatchEvent(r)}function hG(r,e,t,{discrete:n}){const a=t.originalEvent.target,i=new CustomEvent(r,{bubbles:!1,cancelable:!0,detail:t});e&&a.addEventListener(r,e,{once:!0}),n?y$(a,i):a.dispatchEvent(i)}var yl=globalThis!=null&&globalThis.document?q.useLayoutEffect:()=>{},M$=PV[" useId ".trim().toString()]||(()=>{}),D$=0;function N$(r){const[e,t]=q.useState(M$());return yl(()=>{t(n=>n??String(D$++))},[r]),e?`radix-${e}`:""}const L$=["top","right","bottom","left"],xl=Math.min,Jn=Math.max,gx=Math.round,by=Math.floor,Gi=r=>({x:r,y:r}),R$={left:"right",right:"left",bottom:"top",top:"bottom"};function eC(r,e,t){return Jn(r,xl(e,t))}function Wo(r,e){return typeof r=="function"?r(e):r}function Xo(r){return r.split("-")[0]}function Zh(r){return r.split("-")[1]}function LM(r){return r==="x"?"y":"x"}function RM(r){return r==="y"?"height":"width"}function Oi(r){const e=r[0];return e==="t"||e==="b"?"y":"x"}function EM(r){return LM(Oi(r))}function E$(r,e,t){t===void 0&&(t=!1);const n=Zh(r),a=EM(r),i=RM(a);let o=a==="x"?n===(t?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[i]>e.floating[i]&&(o=mx(o)),[o,mx(o)]}function k$(r){const e=mx(r);return[tC(r),e,tC(e)]}function tC(r){return r.includes("start")?r.replace("start","end"):r.replace("end","start")}const KI=["left","right"],QI=["right","left"],I$=["top","bottom"],O$=["bottom","top"];function P$(r,e,t){switch(r){case"top":case"bottom":return t?e?QI:KI:e?KI:QI;case"left":case"right":return e?I$:O$;default:return[]}}function j$(r,e,t,n){const a=Zh(r);let i=P$(Xo(r),t==="start",n);return a&&(i=i.map(o=>o+"-"+a),e&&(i=i.concat(i.map(tC)))),i}function mx(r){const e=Xo(r);return R$[e]+r.slice(e.length)}function z$(r){return{top:0,right:0,bottom:0,left:0,...r}}function dG(r){return typeof r!="number"?z$(r):{top:r,right:r,bottom:r,left:r}}function yx(r){const{x:e,y:t,width:n,height:a}=r;return{width:n,height:a,top:t,left:e,right:e+n,bottom:t+a,x:e,y:t}}function JI(r,e,t){let{reference:n,floating:a}=r;const i=Oi(e),o=EM(e),s=RM(o),l=Xo(e),u=i==="y",c=n.x+n.width/2-a.width/2,f=n.y+n.height/2-a.height/2,d=n[s]/2-a[s]/2;let v;switch(l){case"top":v={x:c,y:n.y-a.height};break;case"bottom":v={x:c,y:n.y+n.height};break;case"right":v={x:n.x+n.width,y:f};break;case"left":v={x:n.x-a.width,y:f};break;default:v={x:n.x,y:n.y}}switch(Zh(e)){case"start":v[o]-=d*(t&&u?-1:1);break;case"end":v[o]+=d*(t&&u?-1:1);break}return v}async function B$(r,e){var t;e===void 0&&(e={});const{x:n,y:a,platform:i,rects:o,elements:s,strategy:l}=r,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:f="floating",altBoundary:d=!1,padding:v=0}=Wo(e,r),g=dG(v),x=s[d?f==="floating"?"reference":"floating":f],b=yx(await i.getClippingRect({element:(t=await(i.isElement==null?void 0:i.isElement(x)))==null||t?x:x.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(s.floating)),boundary:u,rootBoundary:c,strategy:l})),w=f==="floating"?{x:n,y:a,width:o.floating.width,height:o.floating.height}:o.reference,T=await(i.getOffsetParent==null?void 0:i.getOffsetParent(s.floating)),C=await(i.isElement==null?void 0:i.isElement(T))?await(i.getScale==null?void 0:i.getScale(T))||{x:1,y:1}:{x:1,y:1},D=yx(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:w,offsetParent:T,strategy:l}):w);return{top:(b.top-D.top+g.top)/C.y,bottom:(D.bottom-b.bottom+g.bottom)/C.y,left:(b.left-D.left+g.left)/C.x,right:(D.right-b.right+g.right)/C.x}}const V$=50,G$=async(r,e,t)=>{const{placement:n="bottom",strategy:a="absolute",middleware:i=[],platform:o}=t,s=o.detectOverflow?o:{...o,detectOverflow:B$},l=await(o.isRTL==null?void 0:o.isRTL(e));let u=await o.getElementRects({reference:r,floating:e,strategy:a}),{x:c,y:f}=JI(u,n,l),d=n,v=0;const g={};for(let y=0;y<i.length;y++){const x=i[y];if(!x)continue;const{name:b,fn:w}=x,{x:T,y:C,data:D,reset:M}=await w({x:c,y:f,initialPlacement:n,placement:d,strategy:a,middlewareData:g,rects:u,platform:s,elements:{reference:r,floating:e}});c=T??c,f=C??f,g[b]={...g[b],...D},M&&v<V$&&(v++,typeof M=="object"&&(M.placement&&(d=M.placement),M.rects&&(u=M.rects===!0?await o.getElementRects({reference:r,floating:e,strategy:a}):M.rects),{x:c,y:f}=JI(u,d,l)),y=-1)}return{x:c,y:f,placement:d,strategy:a,middlewareData:g}},H$=r=>({name:"arrow",options:r,async fn(e){const{x:t,y:n,placement:a,rects:i,platform:o,elements:s,middlewareData:l}=e,{element:u,padding:c=0}=Wo(r,e)||{};if(u==null)return{};const f=dG(c),d={x:t,y:n},v=EM(a),g=RM(v),y=await o.getDimensions(u),x=v==="y",b=x?"top":"left",w=x?"bottom":"right",T=x?"clientHeight":"clientWidth",C=i.reference[g]+i.reference[v]-d[v]-i.floating[g],D=d[v]-i.reference[v],M=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u));let N=M?M[T]:0;(!N||!await(o.isElement==null?void 0:o.isElement(M)))&&(N=s.floating[T]||i.floating[g]);const R=C/2-D/2,E=N/2-y[g]/2-1,k=xl(f[b],E),I=xl(f[w],E),B=k,P=N-y[g]-I,H=N/2-y[g]/2+R,V=eC(B,H,P),j=!l.arrow&&Zh(a)!=null&&H!==V&&i.reference[g]/2-(H<B?k:I)-y[g]/2<0,U=j?H<B?H-B:H-P:0;return{[v]:d[v]+U,data:{[v]:V,centerOffset:H-V-U,...j&&{alignmentOffset:U}},reset:j}}}),F$=function(r){return r===void 0&&(r={}),{name:"flip",options:r,async fn(e){var t,n;const{placement:a,middlewareData:i,rects:o,initialPlacement:s,platform:l,elements:u}=e,{mainAxis:c=!0,crossAxis:f=!0,fallbackPlacements:d,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:y=!0,...x}=Wo(r,e);if((t=i.arrow)!=null&&t.alignmentOffset)return{};const b=Xo(a),w=Oi(s),T=Xo(s)===s,C=await(l.isRTL==null?void 0:l.isRTL(u.floating)),D=d||(T||!y?[mx(s)]:k$(s)),M=g!=="none";!d&&M&&D.push(...j$(s,y,g,C));const N=[s,...D],R=await l.detectOverflow(e,x),E=[];let k=((n=i.flip)==null?void 0:n.overflows)||[];if(c&&E.push(R[b]),f){const H=E$(a,o,C);E.push(R[H[0]],R[H[1]])}if(k=[...k,{placement:a,overflows:E}],!E.every(H=>H<=0)){var I,B;const H=(((I=i.flip)==null?void 0:I.index)||0)+1,V=N[H];if(V&&(!(f==="alignment"?w!==Oi(V):!1)||k.every(F=>Oi(F.placement)===w?F.overflows[0]>0:!0)))return{data:{index:H,overflows:k},reset:{placement:V}};let j=(B=k.filter(U=>U.overflows[0]<=0).sort((U,F)=>U.overflows[1]-F.overflows[1])[0])==null?void 0:B.placement;if(!j)switch(v){case"bestFit":{var P;const U=(P=k.filter(F=>{if(M){const X=Oi(F.placement);return X===w||X==="y"}return!0}).map(F=>[F.placement,F.overflows.filter(X=>X>0).reduce((X,G)=>X+G,0)]).sort((F,X)=>F[1]-X[1])[0])==null?void 0:P[0];U&&(j=U);break}case"initialPlacement":j=s;break}if(a!==j)return{reset:{placement:j}}}return{}}}};function eO(r,e){return{top:r.top-e.height,right:r.right-e.width,bottom:r.bottom-e.height,left:r.left-e.width}}function tO(r){return L$.some(e=>r[e]>=0)}const U$=function(r){return r===void 0&&(r={}),{name:"hide",options:r,async fn(e){const{rects:t,platform:n}=e,{strategy:a="referenceHidden",...i}=Wo(r,e);switch(a){case"referenceHidden":{const o=await n.detectOverflow(e,{...i,elementContext:"reference"}),s=eO(o,t.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:tO(s)}}}case"escaped":{const o=await n.detectOverflow(e,{...i,altBoundary:!0}),s=eO(o,t.floating);return{data:{escapedOffsets:s,escaped:tO(s)}}}default:return{}}}}},vG=new Set(["left","top"]);async function Y$(r,e){const{placement:t,platform:n,elements:a}=r,i=await(n.isRTL==null?void 0:n.isRTL(a.floating)),o=Xo(t),s=Zh(t),l=Oi(t)==="y",u=vG.has(o)?-1:1,c=i&&l?-1:1,f=Wo(e,r);let{mainAxis:d,crossAxis:v,alignmentAxis:g}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return s&&typeof g=="number"&&(v=s==="end"?g*-1:g),l?{x:v*c,y:d*u}:{x:d*u,y:v*c}}const W$=function(r){return r===void 0&&(r=0),{name:"offset",options:r,async fn(e){var t,n;const{x:a,y:i,placement:o,middlewareData:s}=e,l=await Y$(e,r);return o===((t=s.offset)==null?void 0:t.placement)&&(n=s.arrow)!=null&&n.alignmentOffset?{}:{x:a+l.x,y:i+l.y,data:{...l,placement:o}}}}},X$=function(r){return r===void 0&&(r={}),{name:"shift",options:r,async fn(e){const{x:t,y:n,placement:a,platform:i}=e,{mainAxis:o=!0,crossAxis:s=!1,limiter:l={fn:b=>{let{x:w,y:T}=b;return{x:w,y:T}}},...u}=Wo(r,e),c={x:t,y:n},f=await i.detectOverflow(e,u),d=Oi(Xo(a)),v=LM(d);let g=c[v],y=c[d];if(o){const b=v==="y"?"top":"left",w=v==="y"?"bottom":"right",T=g+f[b],C=g-f[w];g=eC(T,g,C)}if(s){const b=d==="y"?"top":"left",w=d==="y"?"bottom":"right",T=y+f[b],C=y-f[w];y=eC(T,y,C)}const x=l.fn({...e,[v]:g,[d]:y});return{...x,data:{x:x.x-t,y:x.y-n,enabled:{[v]:o,[d]:s}}}}}},q$=function(r){return r===void 0&&(r={}),{options:r,fn(e){const{x:t,y:n,placement:a,rects:i,middlewareData:o}=e,{offset:s=0,mainAxis:l=!0,crossAxis:u=!0}=Wo(r,e),c={x:t,y:n},f=Oi(a),d=LM(f);let v=c[d],g=c[f];const y=Wo(s,e),x=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:0,crossAxis:0,...y};if(l){const T=d==="y"?"height":"width",C=i.reference[d]-i.floating[T]+x.mainAxis,D=i.reference[d]+i.reference[T]-x.mainAxis;v<C?v=C:v>D&&(v=D)}if(u){var b,w;const T=d==="y"?"width":"height",C=vG.has(Xo(a)),D=i.reference[f]-i.floating[T]+(C&&((b=o.offset)==null?void 0:b[f])||0)+(C?0:x.crossAxis),M=i.reference[f]+i.reference[T]+(C?0:((w=o.offset)==null?void 0:w[f])||0)-(C?x.crossAxis:0);g<D?g=D:g>M&&(g=M)}return{[d]:v,[f]:g}}}},Z$=function(r){return r===void 0&&(r={}),{name:"size",options:r,async fn(e){var t,n;const{placement:a,rects:i,platform:o,elements:s}=e,{apply:l=()=>{},...u}=Wo(r,e),c=await o.detectOverflow(e,u),f=Xo(a),d=Zh(a),v=Oi(a)==="y",{width:g,height:y}=i.floating;let x,b;f==="top"||f==="bottom"?(x=f,b=d===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?"start":"end")?"left":"right"):(b=f,x=d==="end"?"top":"bottom");const w=y-c.top-c.bottom,T=g-c.left-c.right,C=xl(y-c[x],w),D=xl(g-c[b],T),M=!e.middlewareData.shift;let N=C,R=D;if((t=e.middlewareData.shift)!=null&&t.enabled.x&&(R=T),(n=e.middlewareData.shift)!=null&&n.enabled.y&&(N=w),M&&!d){const k=Jn(c.left,0),I=Jn(c.right,0),B=Jn(c.top,0),P=Jn(c.bottom,0);v?R=g-2*(k!==0||I!==0?k+I:Jn(c.left,c.right)):N=y-2*(B!==0||P!==0?B+P:Jn(c.top,c.bottom))}await l({...e,availableWidth:R,availableHeight:N});const E=await o.getDimensions(s.floating);return g!==E.width||y!==E.height?{reset:{rects:!0}}:{}}}};function O1(){return typeof window<"u"}function $h(r){return pG(r)?(r.nodeName||"").toLowerCase():"#document"}function oa(r){var e;return(r==null||(e=r.ownerDocument)==null?void 0:e.defaultView)||window}function Qi(r){var e;return(e=(pG(r)?r.ownerDocument:r.document)||window.document)==null?void 0:e.documentElement}function pG(r){return O1()?r instanceof Node||r instanceof oa(r).Node:!1}function ni(r){return O1()?r instanceof Element||r instanceof oa(r).Element:!1}function rs(r){return O1()?r instanceof HTMLElement||r instanceof oa(r).HTMLElement:!1}function rO(r){return!O1()||typeof ShadowRoot>"u"?!1:r instanceof ShadowRoot||r instanceof oa(r).ShadowRoot}function Ig(r){const{overflow:e,overflowX:t,overflowY:n,display:a}=ai(r);return/auto|scroll|overlay|hidden|clip/.test(e+n+t)&&a!=="inline"&&a!=="contents"}function $$(r){return/^(table|td|th)$/.test($h(r))}function P1(r){try{if(r.matches(":popover-open"))return!0}catch{}try{return r.matches(":modal")}catch{return!1}}const K$=/transform|translate|scale|rotate|perspective|filter/,Q$=/paint|layout|strict|content/,Ql=r=>!!r&&r!=="none";let ZS;function kM(r){const e=ni(r)?ai(r):r;return Ql(e.transform)||Ql(e.translate)||Ql(e.scale)||Ql(e.rotate)||Ql(e.perspective)||!IM()&&(Ql(e.backdropFilter)||Ql(e.filter))||K$.test(e.willChange||"")||Q$.test(e.contain||"")}function J$(r){let e=bl(r);for(;rs(e)&&!Dh(e);){if(kM(e))return e;if(P1(e))return null;e=bl(e)}return null}function IM(){return ZS==null&&(ZS=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),ZS}function Dh(r){return/^(html|body|#document)$/.test($h(r))}function ai(r){return oa(r).getComputedStyle(r)}function j1(r){return ni(r)?{scrollLeft:r.scrollLeft,scrollTop:r.scrollTop}:{scrollLeft:r.scrollX,scrollTop:r.scrollY}}function bl(r){if($h(r)==="html")return r;const e=r.assignedSlot||r.parentNode||rO(r)&&r.host||Qi(r);return rO(e)?e.host:e}function gG(r){const e=bl(r);return Dh(e)?r.ownerDocument?r.ownerDocument.body:r.body:rs(e)&&Ig(e)?e:gG(e)}function Up(r,e,t){var n;e===void 0&&(e=[]),t===void 0&&(t=!0);const a=gG(r),i=a===((n=r.ownerDocument)==null?void 0:n.body),o=oa(a);if(i){const s=rC(o);return e.concat(o,o.visualViewport||[],Ig(a)?a:[],s&&t?Up(s):[])}else return e.concat(a,Up(a,[],t))}function rC(r){return r.parent&&Object.getPrototypeOf(r.parent)?r.frameElement:null}function mG(r){const e=ai(r);let t=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const a=rs(r),i=a?r.offsetWidth:t,o=a?r.offsetHeight:n,s=gx(t)!==i||gx(n)!==o;return s&&(t=i,n=o),{width:t,height:n,$:s}}function OM(r){return ni(r)?r:r.contextElement}function oh(r){const e=OM(r);if(!rs(e))return Gi(1);const t=e.getBoundingClientRect(),{width:n,height:a,$:i}=mG(e);let o=(i?gx(t.width):t.width)/n,s=(i?gx(t.height):t.height)/a;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}const eK=Gi(0);function yG(r){const e=oa(r);return!IM()||!e.visualViewport?eK:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function tK(r,e,t){return e===void 0&&(e=!1),!t||e&&t!==oa(r)?!1:e}function oc(r,e,t,n){e===void 0&&(e=!1),t===void 0&&(t=!1);const a=r.getBoundingClientRect(),i=OM(r);let o=Gi(1);e&&(n?ni(n)&&(o=oh(n)):o=oh(r));const s=tK(i,t,n)?yG(i):Gi(0);let l=(a.left+s.x)/o.x,u=(a.top+s.y)/o.y,c=a.width/o.x,f=a.height/o.y;if(i){const d=oa(i),v=n&&ni(n)?oa(n):n;let g=d,y=rC(g);for(;y&&n&&v!==g;){const x=oh(y),b=y.getBoundingClientRect(),w=ai(y),T=b.left+(y.clientLeft+parseFloat(w.paddingLeft))*x.x,C=b.top+(y.clientTop+parseFloat(w.paddingTop))*x.y;l*=x.x,u*=x.y,c*=x.x,f*=x.y,l+=T,u+=C,g=oa(y),y=rC(g)}}return yx({width:c,height:f,x:l,y:u})}function z1(r,e){const t=j1(r).scrollLeft;return e?e.left+t:oc(Qi(r)).left+t}function xG(r,e){const t=r.getBoundingClientRect(),n=t.left+e.scrollLeft-z1(r,t),a=t.top+e.scrollTop;return{x:n,y:a}}function rK(r){let{elements:e,rect:t,offsetParent:n,strategy:a}=r;const i=a==="fixed",o=Qi(n),s=e?P1(e.floating):!1;if(n===o||s&&i)return t;let l={scrollLeft:0,scrollTop:0},u=Gi(1);const c=Gi(0),f=rs(n);if((f||!f&&!i)&&(($h(n)!=="body"||Ig(o))&&(l=j1(n)),f)){const v=oc(n);u=oh(n),c.x=v.x+n.clientLeft,c.y=v.y+n.clientTop}const d=o&&!f&&!i?xG(o,l):Gi(0);return{width:t.width*u.x,height:t.height*u.y,x:t.x*u.x-l.scrollLeft*u.x+c.x+d.x,y:t.y*u.y-l.scrollTop*u.y+c.y+d.y}}function nK(r){return Array.from(r.getClientRects())}function aK(r){const e=Qi(r),t=j1(r),n=r.ownerDocument.body,a=Jn(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=Jn(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);let o=-t.scrollLeft+z1(r);const s=-t.scrollTop;return ai(n).direction==="rtl"&&(o+=Jn(e.clientWidth,n.clientWidth)-a),{width:a,height:i,x:o,y:s}}const nO=25;function iK(r,e){const t=oa(r),n=Qi(r),a=t.visualViewport;let i=n.clientWidth,o=n.clientHeight,s=0,l=0;if(a){i=a.width,o=a.height;const c=IM();(!c||c&&e==="fixed")&&(s=a.offsetLeft,l=a.offsetTop)}const u=z1(n);if(u<=0){const c=n.ownerDocument,f=c.body,d=getComputedStyle(f),v=c.compatMode==="CSS1Compat"&&parseFloat(d.marginLeft)+parseFloat(d.marginRight)||0,g=Math.abs(n.clientWidth-f.clientWidth-v);g<=nO&&(i-=g)}else u<=nO&&(i+=u);return{width:i,height:o,x:s,y:l}}function oK(r,e){const t=oc(r,!0,e==="fixed"),n=t.top+r.clientTop,a=t.left+r.clientLeft,i=rs(r)?oh(r):Gi(1),o=r.clientWidth*i.x,s=r.clientHeight*i.y,l=a*i.x,u=n*i.y;return{width:o,height:s,x:l,y:u}}function aO(r,e,t){let n;if(e==="viewport")n=iK(r,t);else if(e==="document")n=aK(Qi(r));else if(ni(e))n=oK(e,t);else{const a=yG(r);n={x:e.x-a.x,y:e.y-a.y,width:e.width,height:e.height}}return yx(n)}function bG(r,e){const t=bl(r);return t===e||!ni(t)||Dh(t)?!1:ai(t).position==="fixed"||bG(t,e)}function sK(r,e){const t=e.get(r);if(t)return t;let n=Up(r,[],!1).filter(s=>ni(s)&&$h(s)!=="body"),a=null;const i=ai(r).position==="fixed";let o=i?bl(r):r;for(;ni(o)&&!Dh(o);){const s=ai(o),l=kM(o);!l&&s.position==="fixed"&&(a=null),(i?!l&&!a:!l&&s.position==="static"&&!!a&&(a.position==="absolute"||a.position==="fixed")||Ig(o)&&!l&&bG(r,o))?n=n.filter(c=>c!==o):a=s,o=bl(o)}return e.set(r,n),n}function lK(r){let{element:e,boundary:t,rootBoundary:n,strategy:a}=r;const o=[...t==="clippingAncestors"?P1(e)?[]:sK(e,this._c):[].concat(t),n],s=aO(e,o[0],a);let l=s.top,u=s.right,c=s.bottom,f=s.left;for(let d=1;d<o.length;d++){const v=aO(e,o[d],a);l=Jn(v.top,l),u=xl(v.right,u),c=xl(v.bottom,c),f=Jn(v.left,f)}return{width:u-f,height:c-l,x:f,y:l}}function uK(r){const{width:e,height:t}=mG(r);return{width:e,height:t}}function cK(r,e,t){const n=rs(e),a=Qi(e),i=t==="fixed",o=oc(r,!0,i,e);let s={scrollLeft:0,scrollTop:0};const l=Gi(0);function u(){l.x=z1(a)}if(n||!n&&!i)if(($h(e)!=="body"||Ig(a))&&(s=j1(e)),n){const v=oc(e,!0,i,e);l.x=v.x+e.clientLeft,l.y=v.y+e.clientTop}else a&&u();i&&!n&&a&&u();const c=a&&!n&&!i?xG(a,s):Gi(0),f=o.left+s.scrollLeft-l.x-c.x,d=o.top+s.scrollTop-l.y-c.y;return{x:f,y:d,width:o.width,height:o.height}}function $S(r){return ai(r).position==="static"}function iO(r,e){if(!rs(r)||ai(r).position==="fixed")return null;if(e)return e(r);let t=r.offsetParent;return Qi(r)===t&&(t=t.ownerDocument.body),t}function _G(r,e){const t=oa(r);if(P1(r))return t;if(!rs(r)){let a=bl(r);for(;a&&!Dh(a);){if(ni(a)&&!$S(a))return a;a=bl(a)}return t}let n=iO(r,e);for(;n&&$$(n)&&$S(n);)n=iO(n,e);return n&&Dh(n)&&$S(n)&&!kM(n)?t:n||J$(r)||t}const fK=async function(r){const e=this.getOffsetParent||_G,t=this.getDimensions,n=await t(r.floating);return{reference:cK(r.reference,await e(r.floating),r.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function hK(r){return ai(r).direction==="rtl"}const dK={convertOffsetParentRelativeRectToViewportRelativeRect:rK,getDocumentElement:Qi,getClippingRect:lK,getOffsetParent:_G,getElementRects:fK,getClientRects:nK,getDimensions:uK,getScale:oh,isElement:ni,isRTL:hK};function SG(r,e){return r.x===e.x&&r.y===e.y&&r.width===e.width&&r.height===e.height}function vK(r,e){let t=null,n;const a=Qi(r);function i(){var s;clearTimeout(n),(s=t)==null||s.disconnect(),t=null}function o(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),i();const u=r.getBoundingClientRect(),{left:c,top:f,width:d,height:v}=u;if(s||e(),!d||!v)return;const g=by(f),y=by(a.clientWidth-(c+d)),x=by(a.clientHeight-(f+v)),b=by(c),T={rootMargin:-g+"px "+-y+"px "+-x+"px "+-b+"px",threshold:Jn(0,xl(1,l))||1};let C=!0;function D(M){const N=M[0].intersectionRatio;if(N!==l){if(!C)return o();N?o(!1,N):n=setTimeout(()=>{o(!1,1e-7)},1e3)}N===1&&!SG(u,r.getBoundingClientRect())&&o(),C=!1}try{t=new IntersectionObserver(D,{...T,root:a.ownerDocument})}catch{t=new IntersectionObserver(D,T)}t.observe(r)}return o(!0),i}function pK(r,e,t,n){n===void 0&&(n={});const{ancestorScroll:a=!0,ancestorResize:i=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,u=OM(r),c=a||i?[...u?Up(u):[],...e?Up(e):[]]:[];c.forEach(b=>{a&&b.addEventListener("scroll",t,{passive:!0}),i&&b.addEventListener("resize",t)});const f=u&&s?vK(u,t):null;let d=-1,v=null;o&&(v=new ResizeObserver(b=>{let[w]=b;w&&w.target===u&&v&&e&&(v.unobserve(e),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var T;(T=v)==null||T.observe(e)})),t()}),u&&!l&&v.observe(u),e&&v.observe(e));let g,y=l?oc(r):null;l&&x();function x(){const b=oc(r);y&&!SG(y,b)&&t(),y=b,g=requestAnimationFrame(x)}return t(),()=>{var b;c.forEach(w=>{a&&w.removeEventListener("scroll",t),i&&w.removeEventListener("resize",t)}),f==null||f(),(b=v)==null||b.disconnect(),v=null,l&&cancelAnimationFrame(g)}}const gK=W$,mK=X$,yK=F$,xK=Z$,bK=U$,oO=H$,_K=q$,SK=(r,e,t)=>{const n=new Map,a={platform:dK,...t},i={...a.platform,_c:n};return G$(r,e,{...a,platform:i})};var wK=typeof document<"u",TK=function(){},U0=wK?q.useLayoutEffect:TK;function xx(r,e){if(r===e)return!0;if(typeof r!=typeof e)return!1;if(typeof r=="function"&&r.toString()===e.toString())return!0;let t,n,a;if(r&&e&&typeof r=="object"){if(Array.isArray(r)){if(t=r.length,t!==e.length)return!1;for(n=t;n--!==0;)if(!xx(r[n],e[n]))return!1;return!0}if(a=Object.keys(r),t=a.length,t!==Object.keys(e).length)return!1;for(n=t;n--!==0;)if(!{}.hasOwnProperty.call(e,a[n]))return!1;for(n=t;n--!==0;){const i=a[n];if(!(i==="_owner"&&r.$$typeof)&&!xx(r[i],e[i]))return!1}return!0}return r!==r&&e!==e}function wG(r){return typeof window>"u"?1:(r.ownerDocument.defaultView||window).devicePixelRatio||1}function sO(r,e){const t=wG(r);return Math.round(e*t)/t}function KS(r){const e=q.useRef(r);return U0(()=>{e.current=r}),e}function CK(r){r===void 0&&(r={});const{placement:e="bottom",strategy:t="absolute",middleware:n=[],platform:a,elements:{reference:i,floating:o}={},transform:s=!0,whileElementsMounted:l,open:u}=r,[c,f]=q.useState({x:0,y:0,strategy:t,placement:e,middlewareData:{},isPositioned:!1}),[d,v]=q.useState(n);xx(d,n)||v(n);const[g,y]=q.useState(null),[x,b]=q.useState(null),w=q.useCallback(F=>{F!==M.current&&(M.current=F,y(F))},[]),T=q.useCallback(F=>{F!==N.current&&(N.current=F,b(F))},[]),C=i||g,D=o||x,M=q.useRef(null),N=q.useRef(null),R=q.useRef(c),E=l!=null,k=KS(l),I=KS(a),B=KS(u),P=q.useCallback(()=>{if(!M.current||!N.current)return;const F={placement:e,strategy:t,middleware:d};I.current&&(F.platform=I.current),SK(M.current,N.current,F).then(X=>{const G={...X,isPositioned:B.current!==!1};H.current&&!xx(R.current,G)&&(R.current=G,NM.flushSync(()=>{f(G)}))})},[d,e,t,I,B]);U0(()=>{u===!1&&R.current.isPositioned&&(R.current.isPositioned=!1,f(F=>({...F,isPositioned:!1})))},[u]);const H=q.useRef(!1);U0(()=>(H.current=!0,()=>{H.current=!1}),[]),U0(()=>{if(C&&(M.current=C),D&&(N.current=D),C&&D){if(k.current)return k.current(C,D,P);P()}},[C,D,P,k,E]);const V=q.useMemo(()=>({reference:M,floating:N,setReference:w,setFloating:T}),[w,T]),j=q.useMemo(()=>({reference:C,floating:D}),[C,D]),U=q.useMemo(()=>{const F={position:t,left:0,top:0};if(!j.floating)return F;const X=sO(j.floating,c.x),G=sO(j.floating,c.y);return s?{...F,transform:"translate("+X+"px, "+G+"px)",...wG(j.floating)>=1.5&&{willChange:"transform"}}:{position:t,left:X,top:G}},[t,s,j.floating,c.x,c.y]);return q.useMemo(()=>({...c,update:P,refs:V,elements:j,floatingStyles:U}),[c,P,V,j,U])}const AK=r=>{function e(t){return{}.hasOwnProperty.call(t,"current")}return{name:"arrow",options:r,fn(t){const{element:n,padding:a}=typeof r=="function"?r(t):r;return n&&e(n)?n.current!=null?oO({element:n.current,padding:a}).fn(t):{}:n?oO({element:n,padding:a}).fn(t):{}}}},MK=(r,e)=>{const t=gK(r);return{name:t.name,fn:t.fn,options:[r,e]}},DK=(r,e)=>{const t=mK(r);return{name:t.name,fn:t.fn,options:[r,e]}},NK=(r,e)=>({fn:_K(r).fn,options:[r,e]}),LK=(r,e)=>{const t=yK(r);return{name:t.name,fn:t.fn,options:[r,e]}},RK=(r,e)=>{const t=xK(r);return{name:t.name,fn:t.fn,options:[r,e]}},EK=(r,e)=>{const t=bK(r);return{name:t.name,fn:t.fn,options:[r,e]}},kK=(r,e)=>{const t=AK(r);return{name:t.name,fn:t.fn,options:[r,e]}};var IK="Arrow",TG=q.forwardRef((r,e)=>{const{children:t,width:n=10,height:a=5,...i}=r;return _.jsx(Ml.svg,{...i,ref:e,width:n,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:r.asChild?t:_.jsx("polygon",{points:"0,0 30,0 15,10"})})});TG.displayName=IK;var OK=TG;function PK(r){const[e,t]=q.useState(void 0);return yl(()=>{if(r){t({width:r.offsetWidth,height:r.offsetHeight});const n=new ResizeObserver(a=>{if(!Array.isArray(a)||!a.length)return;const i=a[0];let o,s;if("borderBoxSize"in i){const l=i.borderBoxSize,u=Array.isArray(l)?l[0]:l;o=u.inlineSize,s=u.blockSize}else o=r.offsetWidth,s=r.offsetHeight;t({width:o,height:s})});return n.observe(r,{box:"border-box"}),()=>n.unobserve(r)}else t(void 0)},[r]),e}var PM="Popper",[CG,AG]=lG(PM),[jK,MG]=CG(PM),DG=r=>{const{__scopePopper:e,children:t}=r,[n,a]=q.useState(null);return _.jsx(jK,{scope:e,anchor:n,onAnchorChange:a,children:t})};DG.displayName=PM;var NG="PopperAnchor",LG=q.forwardRef((r,e)=>{const{__scopePopper:t,virtualRef:n,...a}=r,i=MG(NG,t),o=q.useRef(null),s=yc(e,o),l=q.useRef(null);return q.useEffect(()=>{const u=l.current;l.current=(n==null?void 0:n.current)||o.current,u!==l.current&&i.onAnchorChange(l.current)}),n?null:_.jsx(Ml.div,{...a,ref:s})});LG.displayName=NG;var jM="PopperContent",[zK,BK]=CG(jM),RG=q.forwardRef((r,e)=>{var Xe,be,we,ze,oe,pe;const{__scopePopper:t,side:n="bottom",sideOffset:a=0,align:i="center",alignOffset:o=0,arrowPadding:s=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:c=0,sticky:f="partial",hideWhenDetached:d=!1,updatePositionStrategy:v="optimized",onPlaced:g,...y}=r,x=MG(jM,t),[b,w]=q.useState(null),T=yc(e,Be=>w(Be)),[C,D]=q.useState(null),M=PK(C),N=(M==null?void 0:M.width)??0,R=(M==null?void 0:M.height)??0,E=n+(i!=="center"?"-"+i:""),k=typeof c=="number"?c:{top:0,right:0,bottom:0,left:0,...c},I=Array.isArray(u)?u:[u],B=I.length>0,P={padding:k,boundary:I.filter(GK),altBoundary:B},{refs:H,floatingStyles:V,placement:j,isPositioned:U,middlewareData:F}=CK({strategy:"fixed",placement:E,whileElementsMounted:(...Be)=>pK(...Be,{animationFrame:v==="always"}),elements:{reference:x.anchor},middleware:[MK({mainAxis:a+R,alignmentAxis:o}),l&&DK({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?NK():void 0,...P}),l&&LK({...P}),RK({...P,apply:({elements:Be,rects:Le,availableWidth:at,availableHeight:ft})=>{const{width:At,height:Wr}=Le.reference,er=Be.floating.style;er.setProperty("--radix-popper-available-width",`${at}px`),er.setProperty("--radix-popper-available-height",`${ft}px`),er.setProperty("--radix-popper-anchor-width",`${At}px`),er.setProperty("--radix-popper-anchor-height",`${Wr}px`)}}),C&&kK({element:C,padding:s}),HK({arrowWidth:N,arrowHeight:R}),d&&EK({strategy:"referenceHidden",...P})]}),[X,G]=IG(j),W=I1(g);yl(()=>{U&&(W==null||W())},[U,W]);const $=(Xe=F.arrow)==null?void 0:Xe.x,te=(be=F.arrow)==null?void 0:be.y,ue=((we=F.arrow)==null?void 0:we.centerOffset)!==0,[ge,Se]=q.useState();return yl(()=>{b&&Se(window.getComputedStyle(b).zIndex)},[b]),_.jsx("div",{ref:H.setFloating,"data-radix-popper-content-wrapper":"",style:{...V,transform:U?V.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ge,"--radix-popper-transform-origin":[(ze=F.transformOrigin)==null?void 0:ze.x,(oe=F.transformOrigin)==null?void 0:oe.y].join(" "),...((pe=F.hide)==null?void 0:pe.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:r.dir,children:_.jsx(zK,{scope:t,placedSide:X,onArrowChange:D,arrowX:$,arrowY:te,shouldHideArrow:ue,children:_.jsx(Ml.div,{"data-side":X,"data-align":G,...y,ref:T,style:{...y.style,animation:U?void 0:"none"}})})})});RG.displayName=jM;var EG="PopperArrow",VK={top:"bottom",right:"left",bottom:"top",left:"right"},kG=q.forwardRef(function(e,t){const{__scopePopper:n,...a}=e,i=BK(EG,n),o=VK[i.placedSide];return _.jsx("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0},children:_.jsx(OK,{...a,ref:t,style:{...a.style,display:"block"}})})});kG.displayName=EG;function GK(r){return r!==null}var HK=r=>({name:"transformOrigin",options:r,fn(e){var x,b,w;const{placement:t,rects:n,middlewareData:a}=e,o=((x=a.arrow)==null?void 0:x.centerOffset)!==0,s=o?0:r.arrowWidth,l=o?0:r.arrowHeight,[u,c]=IG(t),f={start:"0%",center:"50%",end:"100%"}[c],d=(((b=a.arrow)==null?void 0:b.x)??0)+s/2,v=(((w=a.arrow)==null?void 0:w.y)??0)+l/2;let g="",y="";return u==="bottom"?(g=o?f:`${d}px`,y=`${-l}px`):u==="top"?(g=o?f:`${d}px`,y=`${n.floating.height+l}px`):u==="right"?(g=`${-l}px`,y=o?f:`${v}px`):u==="left"&&(g=`${n.floating.width+l}px`,y=o?f:`${v}px`),{data:{x:g,y}}}});function IG(r){const[e,t="center"]=r.split("-");return[e,t]}var FK=DG,UK=LG,YK=RG,WK=kG,XK="Portal",OG=q.forwardRef((r,e)=>{var s;const{container:t,...n}=r,[a,i]=q.useState(!1);yl(()=>i(!0),[]);const o=t||a&&((s=globalThis==null?void 0:globalThis.document)==null?void 0:s.body);return o?c$.createPortal(_.jsx(Ml.div,{...n,ref:e}),o):null});OG.displayName=XK;function qK(r,e){return q.useReducer((t,n)=>e[t][n]??t,r)}var zM=r=>{const{present:e,children:t}=r,n=ZK(e),a=typeof t=="function"?t({present:n.isPresent}):q.Children.only(t),i=yc(n.ref,$K(a));return typeof t=="function"||n.isPresent?q.cloneElement(a,{ref:i}):null};zM.displayName="Presence";function ZK(r){const[e,t]=q.useState(),n=q.useRef(null),a=q.useRef(r),i=q.useRef("none"),o=r?"mounted":"unmounted",[s,l]=qK(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return q.useEffect(()=>{const u=_y(n.current);i.current=s==="mounted"?u:"none"},[s]),yl(()=>{const u=n.current,c=a.current;if(c!==r){const d=i.current,v=_y(u);r?l("MOUNT"):v==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(c&&d!==v?"ANIMATION_OUT":"UNMOUNT"),a.current=r}},[r,l]),yl(()=>{if(e){let u;const c=e.ownerDocument.defaultView??window,f=v=>{const y=_y(n.current).includes(CSS.escape(v.animationName));if(v.target===e&&y&&(l("ANIMATION_END"),!a.current)){const x=e.style.animationFillMode;e.style.animationFillMode="forwards",u=c.setTimeout(()=>{e.style.animationFillMode==="forwards"&&(e.style.animationFillMode=x)})}},d=v=>{v.target===e&&(i.current=_y(n.current))};return e.addEventListener("animationstart",d),e.addEventListener("animationcancel",f),e.addEventListener("animationend",f),()=>{c.clearTimeout(u),e.removeEventListener("animationstart",d),e.removeEventListener("animationcancel",f),e.removeEventListener("animationend",f)}}else l("ANIMATION_END")},[e,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:q.useCallback(u=>{n.current=u?getComputedStyle(u):null,t(u)},[])}}function _y(r){return(r==null?void 0:r.animationName)||"none"}function $K(r){var n,a;let e=(n=Object.getOwnPropertyDescriptor(r.props,"ref"))==null?void 0:n.get,t=e&&"isReactWarning"in e&&e.isReactWarning;return t?r.ref:(e=(a=Object.getOwnPropertyDescriptor(r,"ref"))==null?void 0:a.get,t=e&&"isReactWarning"in e&&e.isReactWarning,t?r.props.ref:r.props.ref||r.ref)}var KK=PV[" useInsertionEffect ".trim().toString()]||yl;function QK({prop:r,defaultProp:e,onChange:t=()=>{},caller:n}){const[a,i,o]=JK({defaultProp:e,onChange:t}),s=r!==void 0,l=s?r:a;{const c=q.useRef(r!==void 0);q.useEffect(()=>{const f=c.current;f!==s&&console.warn(`${n} is changing from ${f?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),c.current=s},[s,n])}const u=q.useCallback(c=>{var f;if(s){const d=eQ(c)?c(r):c;d!==r&&((f=o.current)==null||f.call(o,d))}else i(c)},[s,r,i,o]);return[l,u]}function JK({defaultProp:r,onChange:e}){const[t,n]=q.useState(r),a=q.useRef(t),i=q.useRef(e);return KK(()=>{i.current=e},[e]),q.useEffect(()=>{var o;a.current!==t&&((o=i.current)==null||o.call(i,t),a.current=t)},[t,a]),[t,n,i]}function eQ(r){return typeof r=="function"}var tQ=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),rQ="VisuallyHidden",PG=q.forwardRef((r,e)=>_.jsx(Ml.span,{...r,ref:e,style:{...tQ,...r.style}}));PG.displayName=rQ;var nQ=PG,[B1]=lG("Tooltip",[AG]),V1=AG(),jG="TooltipProvider",aQ=700,nC="tooltip.open",[iQ,BM]=B1(jG),zG=r=>{const{__scopeTooltip:e,delayDuration:t=aQ,skipDelayDuration:n=300,disableHoverableContent:a=!1,children:i}=r,o=q.useRef(!0),s=q.useRef(!1),l=q.useRef(0);return q.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),_.jsx(iQ,{scope:e,isOpenDelayedRef:o,delayDuration:t,onOpen:q.useCallback(()=>{window.clearTimeout(l.current),o.current=!1},[]),onClose:q.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>o.current=!0,n)},[n]),isPointerInTransitRef:s,onPointerInTransitChange:q.useCallback(u=>{s.current=u},[]),disableHoverableContent:a,children:i})};zG.displayName=jG;var Yp="Tooltip",[oQ,Og]=B1(Yp),BG=r=>{const{__scopeTooltip:e,children:t,open:n,defaultOpen:a,onOpenChange:i,disableHoverableContent:o,delayDuration:s}=r,l=BM(Yp,r.__scopeTooltip),u=V1(e),[c,f]=q.useState(null),d=N$(),v=q.useRef(0),g=o??l.disableHoverableContent,y=s??l.delayDuration,x=q.useRef(!1),[b,w]=QK({prop:n,defaultProp:a??!1,onChange:N=>{N?(l.onOpen(),document.dispatchEvent(new CustomEvent(nC))):l.onClose(),i==null||i(N)},caller:Yp}),T=q.useMemo(()=>b?x.current?"delayed-open":"instant-open":"closed",[b]),C=q.useCallback(()=>{window.clearTimeout(v.current),v.current=0,x.current=!1,w(!0)},[w]),D=q.useCallback(()=>{window.clearTimeout(v.current),v.current=0,w(!1)},[w]),M=q.useCallback(()=>{window.clearTimeout(v.current),v.current=window.setTimeout(()=>{x.current=!0,w(!0),v.current=0},y)},[y,w]);return q.useEffect(()=>()=>{v.current&&(window.clearTimeout(v.current),v.current=0)},[]),_.jsx(FK,{...u,children:_.jsx(oQ,{scope:e,contentId:d,open:b,stateAttribute:T,trigger:c,onTriggerChange:f,onTriggerEnter:q.useCallback(()=>{l.isOpenDelayedRef.current?M():C()},[l.isOpenDelayedRef,M,C]),onTriggerLeave:q.useCallback(()=>{g?D():(window.clearTimeout(v.current),v.current=0)},[D,g]),onOpen:C,onClose:D,disableHoverableContent:g,children:t})})};BG.displayName=Yp;var aC="TooltipTrigger",VG=q.forwardRef((r,e)=>{const{__scopeTooltip:t,...n}=r,a=Og(aC,t),i=BM(aC,t),o=V1(t),s=q.useRef(null),l=yc(e,s,a.onTriggerChange),u=q.useRef(!1),c=q.useRef(!1),f=q.useCallback(()=>u.current=!1,[]);return q.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),_.jsx(UK,{asChild:!0,...o,children:_.jsx(Ml.button,{"aria-describedby":a.open?a.contentId:void 0,"data-state":a.stateAttribute,...n,ref:l,onPointerMove:Lo(r.onPointerMove,d=>{d.pointerType!=="touch"&&!c.current&&!i.isPointerInTransitRef.current&&(a.onTriggerEnter(),c.current=!0)}),onPointerLeave:Lo(r.onPointerLeave,()=>{a.onTriggerLeave(),c.current=!1}),onPointerDown:Lo(r.onPointerDown,()=>{a.open&&a.onClose(),u.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:Lo(r.onFocus,()=>{u.current||a.onOpen()}),onBlur:Lo(r.onBlur,a.onClose),onClick:Lo(r.onClick,a.onClose)})})});VG.displayName=aC;var VM="TooltipPortal",[sQ,lQ]=B1(VM,{forceMount:void 0}),GG=r=>{const{__scopeTooltip:e,forceMount:t,children:n,container:a}=r,i=Og(VM,e);return _.jsx(sQ,{scope:e,forceMount:t,children:_.jsx(zM,{present:t||i.open,children:_.jsx(OG,{asChild:!0,container:a,children:n})})})};GG.displayName=VM;var Nh="TooltipContent",HG=q.forwardRef((r,e)=>{const t=lQ(Nh,r.__scopeTooltip),{forceMount:n=t.forceMount,side:a="top",...i}=r,o=Og(Nh,r.__scopeTooltip);return _.jsx(zM,{present:n||o.open,children:o.disableHoverableContent?_.jsx(FG,{side:a,...i,ref:e}):_.jsx(uQ,{side:a,...i,ref:e})})}),uQ=q.forwardRef((r,e)=>{const t=Og(Nh,r.__scopeTooltip),n=BM(Nh,r.__scopeTooltip),a=q.useRef(null),i=yc(e,a),[o,s]=q.useState(null),{trigger:l,onClose:u}=t,c=a.current,{onPointerInTransitChange:f}=n,d=q.useCallback(()=>{s(null),f(!1)},[f]),v=q.useCallback((g,y)=>{const x=g.currentTarget,b={x:g.clientX,y:g.clientY},w=vQ(b,x.getBoundingClientRect()),T=pQ(b,w),C=gQ(y.getBoundingClientRect()),D=yQ([...T,...C]);s(D),f(!0)},[f]);return q.useEffect(()=>()=>d(),[d]),q.useEffect(()=>{if(l&&c){const g=x=>v(x,c),y=x=>v(x,l);return l.addEventListener("pointerleave",g),c.addEventListener("pointerleave",y),()=>{l.removeEventListener("pointerleave",g),c.removeEventListener("pointerleave",y)}}},[l,c,v,d]),q.useEffect(()=>{if(o){const g=y=>{const x=y.target,b={x:y.clientX,y:y.clientY},w=(l==null?void 0:l.contains(x))||(c==null?void 0:c.contains(x)),T=!mQ(b,o);w?d():T&&(d(),u())};return document.addEventListener("pointermove",g),()=>document.removeEventListener("pointermove",g)}},[l,c,o,u,d]),_.jsx(FG,{...r,ref:i})}),[cQ,fQ]=B1(Yp,{isInside:!1}),hQ=d$("TooltipContent"),FG=q.forwardRef((r,e)=>{const{__scopeTooltip:t,children:n,"aria-label":a,onEscapeKeyDown:i,onPointerDownOutside:o,...s}=r,l=Og(Nh,t),u=V1(t),{onClose:c}=l;return q.useEffect(()=>(document.addEventListener(nC,c),()=>document.removeEventListener(nC,c)),[c]),q.useEffect(()=>{if(l.trigger){const f=d=>{const v=d.target;v!=null&&v.contains(l.trigger)&&c()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[l.trigger,c]),_.jsx(fG,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:f=>f.preventDefault(),onDismiss:c,children:_.jsxs(YK,{"data-state":l.stateAttribute,...u,...s,ref:e,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[_.jsx(hQ,{children:n}),_.jsx(cQ,{scope:t,isInside:!0,children:_.jsx(nQ,{id:l.contentId,role:"tooltip",children:a||n})})]})})});HG.displayName=Nh;var UG="TooltipArrow",dQ=q.forwardRef((r,e)=>{const{__scopeTooltip:t,...n}=r,a=V1(t);return fQ(UG,t).isInside?null:_.jsx(WK,{...a,...n,ref:e})});dQ.displayName=UG;function vQ(r,e){const t=Math.abs(e.top-r.y),n=Math.abs(e.bottom-r.y),a=Math.abs(e.right-r.x),i=Math.abs(e.left-r.x);switch(Math.min(t,n,a,i)){case i:return"left";case a:return"right";case t:return"top";case n:return"bottom";default:throw new Error("unreachable")}}function pQ(r,e,t=5){const n=[];switch(e){case"top":n.push({x:r.x-t,y:r.y+t},{x:r.x+t,y:r.y+t});break;case"bottom":n.push({x:r.x-t,y:r.y-t},{x:r.x+t,y:r.y-t});break;case"left":n.push({x:r.x+t,y:r.y-t},{x:r.x+t,y:r.y+t});break;case"right":n.push({x:r.x-t,y:r.y-t},{x:r.x-t,y:r.y+t});break}return n}function gQ(r){const{top:e,right:t,bottom:n,left:a}=r;return[{x:a,y:e},{x:t,y:e},{x:t,y:n},{x:a,y:n}]}function mQ(r,e){const{x:t,y:n}=r;let a=!1;for(let i=0,o=e.length-1;i<e.length;o=i++){const s=e[i],l=e[o],u=s.x,c=s.y,f=l.x,d=l.y;c>n!=d>n&&t<(f-u)*(n-c)/(d-c)+u&&(a=!a)}return a}function yQ(r){const e=r.slice();return e.sort((t,n)=>t.x<n.x?-1:t.x>n.x?1:t.y<n.y?-1:t.y>n.y?1:0),xQ(e)}function xQ(r){if(r.length<=1)return r.slice();const e=[];for(let n=0;n<r.length;n++){const a=r[n];for(;e.length>=2;){const i=e[e.length-1],o=e[e.length-2];if((i.x-o.x)*(a.y-o.y)>=(i.y-o.y)*(a.x-o.x))e.pop();else break}e.push(a)}e.pop();const t=[];for(let n=r.length-1;n>=0;n--){const a=r[n];for(;t.length>=2;){const i=t[t.length-1],o=t[t.length-2];if((i.x-o.x)*(a.y-o.y)>=(i.y-o.y)*(a.x-o.x))t.pop();else break}t.push(a)}return t.pop(),e.length===1&&t.length===1&&e[0].x===t[0].x&&e[0].y===t[0].y?e:e.concat(t)}var bQ=zG,_Q=BG,SQ=VG,wQ=GG,YG=HG;const WG=bQ,TQ=_Q,CQ=SQ,XG=q.forwardRef(({className:r,sideOffset:e=4,...t},n)=>_.jsx(wQ,{children:_.jsx(YG,{ref:n,sideOffset:e,className:Ae("z-50 max-w-[280px] rounded-md bg-popover px-3 py-1.5 text-[11px] leading-relaxed text-popover-foreground shadow-md","animate-in fade-in-0 zoom-in-95","data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95","data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2","data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",r),...t})}));XG.displayName=YG.displayName;function Bo({children:r,content:e,delayDuration:t=200,side:n,contentClassName:a}){return _.jsxs(TQ,{delayDuration:t,children:[_.jsx(CQ,{asChild:!0,children:r}),_.jsx(XG,{side:n,className:a,children:e})]})}const Dr={cafe24:"카페24",coupang:"쿠팡",smartstore:"스마트스토어",shopify:"Shopify","toss-shopping":"토스쇼핑","29cm":"29CM",musinsa:"무신사",kurly:"컬리",ssf:"SSF",bronte:"브론테",ezadmin:"이지어드민",기타:"기타"},GM={cafe24:"#3b82f6",coupang:"#f97316",smartstore:"#22c55e",shopify:"#10b981","toss-shopping":"#38bdf8","29cm":"#64748b",musinsa:"#a1a1aa",kurly:"#a855f7",ssf:"#38bdf8",bronte:"#f43f5e"},AQ={cafe24:"bg-blue-500",coupang:"bg-orange-500",smartstore:"bg-green-500",shopify:"bg-emerald-500","toss-shopping":"bg-blue-400","29cm":"bg-slate-700 dark:bg-slate-400",musinsa:"bg-zinc-800 dark:bg-zinc-200",kurly:"bg-purple-500",ssf:"bg-sky-500",bronte:"bg-rose-500",ezadmin:"bg-gray-500"},qG={cafe24:{domain:"cafe24.com",initial:"C24",bg:"#3b82f6"},coupang:{domain:"coupang.com",initial:"CP",bg:"#f97316"},smartstore:{domain:"shopping.naver.com",initial:"N",bg:"#03c75a"},shopify:{domain:"shopify.com",initial:"S",bg:"#96bf48"},"toss-shopping":{domain:"toss.im",initial:"T",bg:"#0064ff"},"29cm":{domain:"29cm.co.kr",initial:"29",bg:"#1a1a1a"},musinsa:{domain:"musinsa.com",initial:"M",bg:"#1a1a1a"},kurly:{domain:"kurly.com",initial:"K",bg:"#5f0080"},ssf:{domain:"ssfshop.com",initial:"SSF",bg:"#1a1a1a"},bronte:{domain:"bronte.co.kr",initial:"B",bg:"#e8927c"},ezadmin:{initial:"EZ",bg:"#4a7cbe"}};function MQ(r,e=32){const t=qG[r];if(t!=null&&t.domain)return`https://www.google.com/s2/favicons?domain=${t.domain}&sz=${e}`}const lO=[{id:"cafe24",label:Dr.cafe24,hasApi:!0},{id:"coupang",label:Dr.coupang,hasApi:!0},{id:"smartstore",label:Dr.smartstore,hasApi:!0},{id:"shopify",label:Dr.shopify,hasApi:!0},{id:"toss-shopping",label:Dr["toss-shopping"],hasApi:!0},{id:"kurly",label:Dr.kurly,hasApi:!1},{id:"ssf",label:Dr.ssf,hasApi:!1},{id:"bronte",label:Dr.bronte,hasApi:!1},{id:"ezadmin",label:Dr.ezadmin,hasApi:!1}],DQ=[{categoryId:"R",category:"매출",rows:[{id:"R1",feature:"매출액 합계",command:"report revenue",conquered:!0,dataKey:"totalRevenue"},{id:"R2",feature:"기간별 추이",command:"report --period",conquered:!0},{id:"R3",feature:"평균주문가 (AOV)",command:"report revenue",conquered:!0,dataKey:"avgOrderValue"},{id:"R4",feature:"시간대별 매출",command:"report --by hour"},{id:"R5",feature:"결제수단별 매출",command:"report --by payment"}]},{categoryId:"O",category:"주문",rows:[{id:"O1",feature:"주문 목록",command:"order list",conquered:!0,dataKey:"orderCount"},{id:"O2",feature:"주문 상태별 현황",command:"order list --status",conquered:!0,dataKey:"statusBreakdown"},{id:"O3",feature:"채널별 주문수 비교",command:"report --by channel",conquered:!0},{id:"O4",feature:"주문 상세",command:"order get"}]},{categoryId:"P",category:"상품",rows:[{id:"P1",feature:"상품 매핑/해체",command:"product rules",conquered:!0},{id:"P2",feature:"상품별 판매량/매출",command:"report --by product",conquered:!0},{id:"P3",feature:"카테고리별 판매량/매출",command:"report --by category",conquered:!0},{id:"P4",feature:"제품라인별 판매량/매출",command:"report --by productline",conquered:!0},{id:"P5",feature:"공헌이익",command:"report --metric contribution"},{id:"P6",feature:"상품 조회수 (PV)",command:"-"},{id:"P7",feature:"전환율 (CVR)",command:"-"},{id:"P8",feature:"재고 현황",command:"inventory sync"}]},{categoryId:"C",category:"고객",rows:[{id:"C1",feature:"신규/재구매 비율",command:"report --segment"},{id:"C2",feature:"고객 등급/세그먼트",command:"-"},{id:"C3",feature:"LTV/구매주기",command:"-"},{id:"C4",feature:"리뷰 분석",command:"-"}]},{categoryId:"M",category:"마케팅",rows:[{id:"M1",feature:"유입경로별 전환",command:"-"},{id:"M2",feature:"광고 캠페인 성과",command:"-"},{id:"M3",feature:"쿠폰 발급/사용",command:"coupon"},{id:"M4",feature:"키워드 검색량",command:"trend keyword"}]},{categoryId:"D",category:"배송/CS",rows:[{id:"D1",feature:"배송 리드타임",command:"order list"},{id:"D2",feature:"반품/교환율",command:"order list"},{id:"D3",feature:"CS 문의 분석",command:"-"}]},{categoryId:"S",category:"정산",rows:[{id:"S1",feature:"수수료 정책 모델링",command:"settlement calc",conquered:!0,dataKey:"commissionRate"},{id:"S2",feature:"수수료 역산/검증",command:"settlement fee-check",conquered:!0},{id:"S3",feature:"정산 스케줄 예측",command:"settlement schedule",conquered:!0},{id:"S4",feature:"채널수수료 공헌이익",command:"report --by channel --metric margin",conquered:!0,dataKey:"netRevenue"},{id:"S5",feature:"정산 상세 내역",command:"settlement list"},{id:"S6",feature:"정산-예측 대조",command:"settlement reconcile"},{id:"S7",feature:"채널간 순이익 비교",command:"settlement summary"}]}];function NQ(r,e){if(!r||e==="-")return null;const t=e.split(" ")[0];for(const[n,a]of Object.entries(r))if(e.includes(" ")){if(n.startsWith(e))return a}else if(n.startsWith(t))return a;return null}function LQ(r){const e=Date.now()-new Date(r).getTime(),t=Math.floor(e/6e4);if(t<1)return"방금";if(t<60)return`${t}분 전`;const n=Math.floor(t/60);if(n<24)return`${n}시간 전`;const a=Math.floor(n/24);return a<30?`${a}일 전`:`${Math.floor(a/30)}개월 전`}function QS(r){return r>=1e8?`${(r/1e8).toFixed(1)}억`:r>=1e4?`${Math.round(r/1e4)}만`:r.toLocaleString()}function RQ(r,e,t){if(!r)return null;switch(r){case"orderCount":return e!=null&&e.orderCount?`${e.orderCount.toLocaleString()}건`:null;case"totalRevenue":return e!=null&&e.totalRevenue?QS(e.totalRevenue):null;case"avgOrderValue":return e!=null&&e.avgOrderValue?`${QS(e.avgOrderValue)}원`:null;case"statusBreakdown":{if(!(e!=null&&e.statusBreakdown))return null;const n=e.statusBreakdown,a=[];return n.paid&&a.push(`결제 ${n.paid}`),n.shipping&&a.push(`배송 ${n.shipping}`),n.delivered&&a.push(`완료 ${n.delivered}`),n.cancelled&&a.push(`취소 ${n.cancelled}`),a.length>0?a.join(" · "):null}case"commissionRate":return(t==null?void 0:t.avgCommissionRate)!=null?`${(t.avgCommissionRate*100).toFixed(1)}%`:null;case"netRevenue":return t!=null&&t.netRevenue?QS(t.netRevenue):null;default:return null}}const ZG="bg-[#ddebe9cc] text-teal-700 dark:bg-teal-950/30 dark:text-teal-400",$G="bg-[#e8ece6cc] text-teal-600/70 dark:bg-teal-950/15 dark:text-teal-500/70",KG="bg-stone-200/60 text-stone-500 dark:bg-stone-800/40 dark:text-stone-400",QG="bg-[hsl(0_84%_60%/0.08)] text-[hsl(var(--destructive))] dark:bg-[hsl(0_72%_51%/0.12)] dark:text-red-400";function EQ(r){const e=(Date.now()-new Date(r).getTime())/36e5;return e<24?ZG:e<168?$G:KG}function kQ({exec:r,dataLabel:e}){if(!r&&!e)return _.jsx("div",{className:"h-full flex items-center justify-center rounded-[3px] bg-muted/30",children:_.jsx("span",{className:"text-[10px] text-muted-foreground/20",children:"—"})});if(!r&&e)return _.jsx("div",{className:"h-full flex flex-col items-center justify-center rounded-[3px] px-2 py-1.5 bg-stone-200/60 text-stone-500 dark:bg-stone-800/40 dark:text-stone-400",children:_.jsx("span",{className:"text-[11px] font-semibold leading-tight",children:e})});const t=r,a=t.result==="error"?QG:EQ(t.lastRun);return _.jsxs("div",{className:Ae("h-full flex flex-col items-center justify-center rounded-[3px] px-2 py-1.5 gap-0.5",a),children:[e&&_.jsx("span",{className:"text-[11px] font-semibold leading-tight",children:e}),_.jsx("span",{className:Ae("leading-tight",e?"text-[9px] opacity-60":"text-[11px] font-medium"),children:LQ(t.lastRun)}),!e&&t.durationMs>0&&_.jsx("span",{className:"text-[9px] opacity-60",children:t.durationMs<1e3?`${t.durationMs}ms`:`${(t.durationMs/1e3).toFixed(1)}s`})]})}function IQ({channelId:r}){const e=qG[r];if(!e)return null;const t=MQ(r);return t?_.jsx("img",{src:t,alt:r,width:20,height:20,className:"shrink-0 rounded-[3px]",onError:n=>{const a=document.createElement("span");a.className="inline-flex items-center justify-center w-5 h-5 rounded-[4px] text-[8px] font-bold text-white shrink-0 leading-none",a.style.backgroundColor=e.bg,a.textContent=e.initial,n.target.replaceWith(a)}}):_.jsx("span",{className:"inline-flex items-center justify-center w-5 h-5 rounded-[4px] text-[8px] font-bold text-white shrink-0 leading-none",style:{backgroundColor:e.bg},children:e.initial})}function OQ(r,e){switch(r){case"cafe24":return e?`https://${e}.cafe24.com/disp/admin/shop1/index`:null;case"coupang":return"https://wing.coupang.com/";case"smartstore":return"https://partner.smartstore.naver.com/";case"shopify":return e?`https://${e}/admin`:null;case"toss-shopping":return"https://shopping-seller.toss.im/";default:return null}}function PQ({ch:r}){const{data:e}=Xh(),t=r.hasApi?e==null?void 0:e.channels.find(i=>i.channel===r.id):void 0,n=(t==null?void 0:t.connected)??!1,a=n?OQ(r.id,t==null?void 0:t.storeId):null;return _.jsx("th",{className:"text-center px-3 py-3.5 min-w-[155px] align-bottom",children:_.jsxs("div",{className:"flex flex-col items-center gap-1.5",children:[_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx(IQ,{channelId:r.id}),_.jsx("span",{className:"font-semibold text-[13px] whitespace-nowrap",children:r.label})]}),r.hasApi&&n&&t&&_.jsxs("div",{className:"flex flex-col items-center gap-0.5",children:[a?_.jsx("a",{href:a,target:"_blank",rel:"noopener noreferrer",className:"text-[10px] font-medium text-[hsl(var(--success))] hover:underline whitespace-nowrap",children:t.storeId||"연결됨"}):_.jsx("span",{className:"text-[10px] font-medium text-[hsl(var(--success))] whitespace-nowrap",children:t.storeId||"연결됨"}),_.jsxs("div",{className:"text-[9px] text-muted-foreground/50 font-normal whitespace-nowrap",children:[t.rateLimit,"rps · ",t.webhook?"webhook":"polling",t.keyExpiry!==void 0&&t.keyExpiry<=14&&_.jsxs("span",{className:"text-[hsl(var(--warning))] ml-1",children:[_.jsx(iG,{size:8,className:"inline"})," ",t.keyExpiry,"d"]})]})]}),r.hasApi&&!n&&_.jsxs("button",{type:"button",onClick:()=>{window.location.hash="config"},className:"flex items-center gap-1 text-[10px] text-muted-foreground/50 hover:text-[hsl(var(--primary))] transition-colors px-2 py-0.5 rounded border border-dashed border-border hover:border-[hsl(var(--primary))] whitespace-nowrap",children:[_.jsx(JZ,{size:10}),"연결하기"]}),!r.hasApi&&_.jsx("span",{className:"text-[10px] text-muted-foreground/40 font-normal",children:"CSV only"})]})})}const Pg=60,G1=130,HM=28,JG=180,e6=Pg,t6=Pg+G1,r6=Pg+G1+HM,Sy="sticky z-20 bg-background",JS="sticky z-20 bg-card",jQ="sticky z-20 bg-[hsl(var(--muted))]",n6="after:absolute after:right-0 after:top-0 after:bottom-0 after:w-[6px] after:pointer-events-none after:bg-gradient-to-r after:from-black/[0.04] after:to-transparent dark:after:from-white/[0.06]",a6=r=>({width:r,minWidth:r,maxWidth:r}),sh=(r,e)=>({width:r,minWidth:r,maxWidth:r,left:e});function zQ({command:r}){const[e,t]=q.useState(!1),n=q.useCallback(()=>{navigator.clipboard.writeText(r),t(!0),setTimeout(()=>t(!1),1200)},[r]);return _.jsxs("div",{className:"flex items-center gap-1 max-w-full",children:[_.jsx("code",{className:"text-[10px] bg-muted/60 px-1.5 py-0.5 rounded font-mono whitespace-nowrap overflow-hidden text-ellipsis min-w-0",children:r}),_.jsx("button",{type:"button",onClick:n,className:"shrink-0 p-0.5 rounded hover:bg-muted text-muted-foreground/40 hover:text-foreground transition-colors",title:"복사",children:e?_.jsx("span",{className:"text-emerald-500 text-[9px] font-medium",children:"ok"}):_.jsx($Z,{size:10})})]})}function BQ({groups:r,channels:e,ctx:t}){return _.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsx("div",{className:"overflow-x-auto",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:Ae("text-left px-3 py-2.5 border-r border-border/50",Sy),style:{...a6(Pg),left:0},children:"영역"}),_.jsx("th",{className:Ae("text-left px-3 py-2.5 border-r border-border/50",Sy),style:sh(G1,e6),children:"분석 항목"}),_.jsx("th",{className:Ae("text-center py-2.5 border-r border-border/50",Sy),style:sh(HM,t6),title:"핵심 정복 항목",children:_.jsx("span",{className:"text-[10px]",children:"주요"})}),_.jsx("th",{className:Ae("text-left px-3 py-2.5 relative",Sy,n6),style:sh(JG,r6),children:_.jsx("span",{className:"font-mono text-[10px]",children:"명령어"})}),e.map(n=>_.jsx(PQ,{ch:n},n.id))]})}),_.jsx("tbody",{children:r.map(n=>_.jsx(VQ,{group:n,channels:e,ctx:t},n.category))})]})})})}function VQ({group:r,channels:e,ctx:t}){return _.jsx(_.Fragment,{children:r.rows.map((n,a)=>_.jsxs("tr",{className:Ae("border-b border-border/50",a===0&&"border-t-[2px] border-t-border",a===r.rows.length-1&&"border-b-border"),children:[a===0&&_.jsxs("td",{rowSpan:r.rows.length,className:Ae("px-3 py-3 border-r border-border/50 align-middle text-center",jQ),style:{...a6(Pg),left:0},children:[_.jsx("span",{className:"text-[9px] text-muted-foreground/40 font-mono block mb-0.5",children:r.categoryId}),_.jsx("span",{className:"text-[12px] font-bold text-foreground/70 whitespace-nowrap",children:r.category})]}),_.jsxs("td",{className:Ae("px-3 py-2 font-medium border-r border-border/50",JS),style:sh(G1,e6),children:[_.jsx("span",{className:"text-[9px] text-muted-foreground/40 font-mono mr-1",children:n.id}),n.feature]}),_.jsx("td",{className:Ae("text-center border-r border-border/50",JS),style:sh(HM,t6),children:n.conquered&&_.jsx("span",{className:"text-emerald-500 text-[13px] leading-none",title:"정복",children:"●"})}),_.jsx("td",{className:Ae("px-3 py-2 relative overflow-hidden",JS,n6),style:sh(JG,r6),children:n.command!=="-"?_.jsx(zQ,{command:`sppt ${n.command}`}):_.jsx("span",{className:"text-muted-foreground/30 text-[10px]",children:"-"})}),e.map(i=>{const o=NQ(t.executions[i.id],n.command),s=RQ(n.dataKey,t.channelData[i.id],t.settlementData[i.id]);return _.jsx("td",{className:"px-1.5 py-1 text-center min-w-[155px] bg-card",children:_.jsx(kQ,{exec:o,dataLabel:s})},i.id)})]},n.feature))})}function GQ(){const{isLoading:r}=Xh(),{data:e,isLoading:t}=Xq(),[n,a]=q.useState(""),i=q.useMemo(()=>{if(!n.trim())return lO;const s=n.trim().toLowerCase();return lO.filter(l=>l.label.toLowerCase().includes(s)||l.id.toLowerCase().includes(s))},[n]),o={executions:(e==null?void 0:e.executions)??{},channelData:(e==null?void 0:e.channelData)??{},settlementData:(e==null?void 0:e.settlementData)??{}};return r||t?_.jsxs("div",{children:[_.jsx("h2",{className:"text-xl font-medium mb-6",children:"채널 보드"}),_.jsx("div",{className:"text-sm text-muted-foreground",children:"로딩 중..."})]}):_.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center justify-between mb-4",children:[_.jsx("h2",{className:"text-xl font-medium",children:"채널 보드"}),_.jsxs("div",{className:"relative",children:[_.jsx(Fp,{size:13,className:"absolute left-2.5 top-1/2 -translate-y-1/2 text-muted-foreground/50"}),_.jsx("input",{type:"text",value:n,onChange:s=>a(s.target.value),placeholder:"채널 검색",className:"pl-7 pr-3 py-1.5 text-[11px] bg-muted/40 border border-border rounded-md w-[160px] focus:outline-none focus:border-foreground/20 placeholder:text-muted-foreground/40"})]})]}),_.jsxs("div",{className:"flex flex-wrap items-center gap-x-5 gap-y-1.5 text-[11px] mb-3",children:[_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx("span",{className:Ae("inline-block px-1.5 py-0.5 rounded-[3px] text-[10px] font-medium leading-none",ZG),children:"방금"}),_.jsx("span",{className:"text-muted-foreground",children:"24시간 이내"})]}),_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx("span",{className:Ae("inline-block px-1.5 py-0.5 rounded-[3px] text-[10px] font-medium leading-none",$G),children:"3일 전"}),_.jsx("span",{className:"text-muted-foreground",children:"1~7일"})]}),_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx("span",{className:Ae("inline-block px-1.5 py-0.5 rounded-[3px] text-[10px] font-medium leading-none",KG),children:"2주 전"}),_.jsx("span",{className:"text-muted-foreground",children:"7일 이상"})]}),_.jsx("div",{className:"flex items-center gap-1.5",children:_.jsx("span",{className:Ae("inline-block px-1.5 py-0.5 rounded-[3px] text-[10px] font-medium leading-none",QG),children:"실패"})}),_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx("span",{className:"text-emerald-500 text-[13px] leading-none",children:"●"}),_.jsx("span",{className:"text-muted-foreground",children:"주요 항목"})]})]}),_.jsx(BQ,{groups:DQ,channels:i,ctx:o})]})}function Yf({channelKey:r,schema:e,current:t,onSave:n,saving:a,saved:i}){const o=e.fields.filter(b=>!b.readOnly),s=e.fields.filter(b=>b.readOnly),l=o.some(b=>{const w=t[b.key];return w!==void 0&&w!==""&&w!==null}),u=o.some(b=>{const w=t[b.key];return w!==void 0&&w!==""&&w!==null}),[c,f]=q.useState(l),[d,v]=q.useState(!e.proxyNote||u),[g,y]=q.useState(()=>{const b={};for(const w of o){const T=t[w.key];w.type==="boolean"?b[w.key]=!!T:w.type==="number"?b[w.key]=T!==void 0&&T!==""?Number(T):"":b[w.key]=String(T??"")}return b});function x(){if(!o.some(T=>{const C=g[T.key];return C!==""&&C!==void 0})){n({});return}const w={...t};for(const T of o){const C=g[T.key];C!==""&&C!==void 0?w[T.key]=C:delete w[T.key]}n(w)}return _.jsxs("div",{id:r?`cfg-ch-${r}`:void 0,className:"border border-border rounded-lg overflow-hidden bg-card scroll-mt-4",children:[_.jsxs("button",{type:"button",onClick:()=>f(b=>!b),className:"w-full flex items-center justify-between px-4 py-2.5 text-[13px] hover:bg-muted/30 transition-colors",children:[_.jsxs("span",{className:"flex items-center gap-2",children:[c?_.jsx(Sn,{size:13,className:"text-muted-foreground"}):_.jsx(Pn,{size:13,className:"text-muted-foreground"}),_.jsx("span",{className:"font-medium",children:e.label}),l&&_.jsx("span",{className:"w-1.5 h-1.5 rounded-full bg-emerald-500 shrink-0"})]}),_.jsx("span",{className:"text-[11px] text-muted-foreground",children:l?_.jsx("span",{className:"text-emerald-600",children:"연결됨"}):e.proxyNote&&!u?_.jsxs("span",{className:"flex items-center gap-1",children:[_.jsx(QT,{size:10})," 공용 키"]}):null})]}),c&&_.jsxs("div",{className:"border-t border-border bg-muted/10",children:[(e.guide||e.cliNote)&&_.jsxs("div",{className:"px-4 pt-3 pb-2 flex items-center gap-4 text-[11px] text-muted-foreground border-b border-border/50",children:[e.guide&&_.jsxs("a",{href:e.guide,target:"_blank",rel:"noreferrer",className:"flex items-center gap-1 hover:text-foreground transition-colors",onClick:b=>b.stopPropagation(),children:[_.jsx(kg,{size:10}),"자격증명 발급"]}),e.cliNote&&_.jsx("code",{className:"font-mono text-[10px] bg-muted px-1.5 py-0.5 rounded text-foreground/70",children:e.cliNote})]}),e.proxyNote&&!d?_.jsxs("div",{className:"px-4 py-4 flex items-start justify-between gap-4",children:[_.jsx("div",{className:"space-y-1",children:_.jsx("p",{className:"text-[12px] text-foreground/80",children:e.proxyNote})}),_.jsxs("button",{type:"button",onClick:()=>v(!0),className:"shrink-0 flex items-center gap-1.5 px-3 py-1.5 text-[11px] border border-border rounded hover:bg-muted transition-colors",children:[_.jsx(tG,{size:10}),"직접 설정"]})]}):_.jsxs("div",{className:"px-4 py-4 space-y-2.5",children:[e.proxyNote&&d&&_.jsxs("div",{className:"flex items-center justify-between pb-1 border-b border-border/50",children:[_.jsx("span",{className:"text-[11px] text-muted-foreground",children:"직접 설정 중"}),_.jsxs("button",{type:"button",onClick:()=>v(!1),className:"flex items-center gap-1 text-[11px] text-muted-foreground hover:text-foreground",children:[_.jsx(QT,{size:10})," 공용 키로 전환"]})]}),o.map(b=>_.jsxs("div",{className:"grid grid-cols-[190px_1fr] items-start gap-3",children:[_.jsxs("span",{className:Ae("text-[12px] text-right pt-1.5 leading-tight",b.optional?"text-muted-foreground/60":"text-muted-foreground"),children:[b.label,b.optional&&_.jsx("span",{className:"ml-1 text-[10px]",children:"(선택)"})]}),_.jsxs("div",{className:"space-y-0.5",children:[b.type==="boolean"?_.jsx("input",{type:"checkbox",checked:!!g[b.key],onChange:w=>y(T=>({...T,[b.key]:w.target.checked})),className:"w-4 h-4 accent-primary mt-1.5"}):_.jsx("input",{type:b.type==="password"?"password":b.type==="number"?"number":"text",value:String(g[b.key]??""),placeholder:b.placeholder??"",onChange:w=>y(T=>({...T,[b.key]:w.target.value})),className:"h-7 px-2 text-[12px] border border-border rounded bg-background w-full font-mono focus:outline-none focus:ring-1 focus:ring-primary/50"}),b.hint&&_.jsx("p",{className:"text-[10px] text-muted-foreground/70 pl-0.5",children:b.hint})]})]},b.key)),s.filter(b=>t[b.key]!==void 0&&t[b.key]!=="").map(b=>_.jsxs("div",{className:"grid grid-cols-[190px_1fr] items-start gap-3",children:[_.jsx("span",{className:"text-[12px] text-right pt-1.5 text-muted-foreground/50",children:b.label}),_.jsxs("div",{className:"space-y-0.5",children:[_.jsx("div",{className:"h-7 px-2 flex items-center",children:_.jsx("span",{className:"text-[12px] font-mono text-muted-foreground/70 truncate",children:b.type==="password"?"••••••••":String(t[b.key])})}),b.hint&&_.jsx("p",{className:"text-[10px] text-muted-foreground/50 pl-0.5",children:b.hint})]})]},b.key)),e.ipNote&&_.jsx("div",{className:"py-2.5 px-3 bg-amber-50 dark:bg-amber-950/30 rounded-md border border-amber-200/60 dark:border-amber-800/40",children:e.ipNote.split(`
243
- `).map((b,w)=>w===0?_.jsx("p",{className:"text-[11px] text-amber-800 dark:text-amber-300",children:b},b):_.jsx("p",{className:"mt-0.5 font-mono text-[12px] font-semibold text-amber-900 dark:text-amber-200 select-all",children:b},b))}),_.jsxs("div",{className:"flex items-center justify-end gap-2 pt-1",children:[i&&_.jsxs("span",{className:"text-[11px] text-emerald-600 flex items-center gap-1",children:[_.jsx(Eg,{size:11})," 저장됨"]}),_.jsxs("button",{type:"button",onClick:x,disabled:a,className:"flex items-center gap-1.5 px-3 py-1.5 text-[12px] bg-primary text-primary-foreground rounded hover:bg-primary/90 disabled:opacity-50 transition-colors",children:[_.jsx(k1,{size:11}),a?"저장 중...":"저장"]})]})]})]})]})}function vf({id:r,title:e,defaultOpen:t=!0,children:n}){const[a,i]=q.useState(t);return _.jsxs("div",{id:r,className:"space-y-2 scroll-mt-4",children:[_.jsxs("button",{type:"button",onClick:()=>i(o=>!o),className:"flex items-center gap-1.5 text-[11px] font-semibold text-muted-foreground uppercase tracking-wider hover:text-foreground transition-colors w-full",children:[a?_.jsx(Sn,{size:11}):_.jsx(Pn,{size:11}),e]}),a&&_.jsx("div",{className:"space-y-1.5",children:n})]})}const wy=[{id:"cfg-seller",label:"사업자 정보"},{id:"cfg-sell",label:"판매 채널"},{id:"cfg-source",label:"소싱 채널"},{id:"cfg-trend",label:"트렌드 · 외부 도구"},{id:"cfg-logistics",label:"물류 채널"},{id:"cfg-advanced",label:"고급 설정"}];function HQ(){const[r,e]=q.useState(wy[0].id);q.useEffect(()=>{function n(){const a=window.innerHeight/3;let i=wy[0].id;for(const{id:o}of wy){const s=document.getElementById(o);s&&s.getBoundingClientRect().top<a&&(i=o)}e(i)}return window.addEventListener("scroll",n,{passive:!0}),()=>window.removeEventListener("scroll",n)},[]);function t(n){var a;(a=document.getElementById(n))==null||a.scrollIntoView({behavior:"smooth",block:"start"}),e(n)}return _.jsxs("nav",{className:"fixed top-8 right-6 w-36 z-20 pt-1",children:[_.jsx("p",{className:"text-[10px] font-semibold text-muted-foreground uppercase tracking-wider mb-2 px-2",children:"목차"}),_.jsx("ul",{className:"space-y-0.5",children:wy.map(n=>_.jsx("li",{children:_.jsx("button",{type:"button",onClick:()=>t(n.id),className:Ae("w-full text-left text-[12px] px-2 py-1.5 rounded border-l-2 transition-colors leading-tight",r===n.id?"border-primary text-foreground font-medium bg-muted/60":"border-transparent text-muted-foreground hover:text-foreground hover:bg-muted/30"),children:n.label})},n.id))})]})}function Wf({title:r,description:e,fields:t,values:n,onSave:a,saving:i,saved:o,defaultOpen:s=!1,cliNote:l}){const[u,c]=q.useState(s),[f,d]=q.useState(()=>{const x={};for(const b of t){const w=n[b.key];b.type==="boolean"?x[b.key]=!!w:b.type==="number"?x[b.key]=w!==void 0&&w!==""?Number(w):"":x[b.key]=String(w??"")}return x}),[v,g]=q.useState(n);if(n!==v){g(n);const x={};for(const b of t){const w=n[b.key];b.type==="boolean"?x[b.key]=!!w:b.type==="number"?x[b.key]=w!==void 0&&w!==""?Number(w):"":x[b.key]=String(w??"")}d(x)}function y(){const x={};for(const b of t){const w=f[b.key];w!==""&&w!==void 0&&(x[b.key]=w)}a(x)}return _.jsxs("div",{className:"border border-border rounded-lg overflow-hidden bg-card",children:[_.jsx("button",{type:"button",onClick:()=>c(x=>!x),className:"w-full flex items-center justify-between px-4 py-2.5 text-[13px] hover:bg-muted/30 transition-colors",children:_.jsxs("span",{className:"flex items-center gap-2",children:[u?_.jsx(Sn,{size:13,className:"text-muted-foreground"}):_.jsx(Pn,{size:13,className:"text-muted-foreground"}),_.jsx("span",{className:"font-medium",children:r})]})}),u&&_.jsxs("div",{className:"border-t border-border bg-muted/10",children:[(e||l)&&_.jsxs("div",{className:"px-4 pt-3 pb-2 space-y-1 border-b border-border/50",children:[e&&_.jsx("p",{className:"text-[12px] text-muted-foreground leading-relaxed",children:e}),l&&_.jsx("code",{className:"text-[10px] font-mono bg-muted px-1.5 py-0.5 rounded text-foreground/70",children:l})]}),_.jsxs("div",{className:"px-4 py-4 space-y-2.5",children:[t.map(x=>_.jsxs("div",{className:"grid grid-cols-[190px_1fr] items-start gap-3",children:[_.jsxs("span",{className:Ae("text-[12px] text-right pt-1.5 leading-tight",x.optional?"text-muted-foreground/60":"text-muted-foreground"),children:[x.label,x.optional&&_.jsx("span",{className:"ml-1 text-[10px]",children:"(선택)"})]}),_.jsxs("div",{className:"space-y-0.5",children:[x.type==="boolean"?_.jsx("input",{type:"checkbox",checked:!!f[x.key],onChange:b=>d(w=>({...w,[x.key]:b.target.checked})),className:"w-4 h-4 accent-primary mt-1.5"}):_.jsx("input",{type:x.type==="password"?"password":x.type==="number"?"number":"text",value:String(f[x.key]??""),placeholder:x.placeholder??"",onChange:b=>d(w=>({...w,[x.key]:b.target.value})),className:"h-7 px-2 text-[12px] border border-border rounded bg-background w-full font-mono focus:outline-none focus:ring-1 focus:ring-primary/50"}),x.hint&&_.jsx("p",{className:"text-[10px] text-muted-foreground/70 pl-0.5",children:x.hint})]})]},x.key)),_.jsxs("div",{className:"flex items-center justify-end gap-2 pt-1",children:[o&&_.jsxs("span",{className:"text-[11px] text-emerald-600 flex items-center gap-1",children:[_.jsx(Eg,{size:11})," 저장됨"]}),_.jsxs("button",{type:"button",onClick:y,disabled:i,className:"flex items-center gap-1.5 px-3 py-1.5 text-[12px] bg-primary text-primary-foreground rounded hover:bg-primary/90 disabled:opacity-50 transition-colors",children:[_.jsx(k1,{size:11}),i?"저장 중...":"저장"]})]})]})]})]})}const uO=[{key:"store",label:"스토어 프로필"},{key:"channels",label:"채널 연결"},{key:"done",label:"완료"}];function FQ({current:r}){const e=uO.findIndex(t=>t.key===r);return _.jsx("div",{className:"flex items-center gap-2 mb-8",children:uO.map((t,n)=>_.jsxs("div",{className:"flex items-center gap-2",children:[n>0&&_.jsx("div",{className:Ae("w-8 h-px",n<=e?"bg-primary":"bg-border")}),_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx("div",{className:Ae("w-6 h-6 rounded-full flex items-center justify-center text-[11px] font-medium",n<e||n===e?"bg-primary text-primary-foreground":"bg-muted text-muted-foreground"),children:n<e?_.jsx(Eg,{size:12}):n+1}),_.jsx("span",{className:Ae("text-[12px]",n===e?"font-medium text-foreground":"text-muted-foreground"),children:t.label})]})]},t.key))})}function UQ({connectedCount:r,onBack:e}){const[t,n]=q.useState("idle"),[a,i]=q.useState(null);async function o(){n("syncing"),i(null);try{const s=await FV();i(s),n(s.error?"error":"success")}catch(s){i({synced:0,error:s instanceof Error?s.message:"알 수 없는 오류"}),n("error")}}return _.jsxs("div",{className:"py-8 space-y-6",children:[_.jsxs("div",{className:"text-center space-y-3",children:[_.jsx(YI,{size:44,className:"mx-auto text-emerald-500"}),_.jsx("h3",{className:"text-[16px] font-semibold",children:"채널 설정 완료!"}),r>0?_.jsxs("p",{className:"text-[13px] text-muted-foreground",children:[r,"개 채널이 연결되었습니다."]}):_.jsx("p",{className:"text-[13px] text-muted-foreground",children:"채널은 나중에 Settings에서 추가할 수 있습니다."})]}),r>0&&_.jsx("div",{className:"border border-border rounded-lg bg-card overflow-hidden",children:_.jsxs("div",{className:"px-5 py-4 space-y-3",children:[_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx(px,{size:15,className:"text-muted-foreground"}),_.jsx("span",{className:"text-[13px] font-medium",children:"최근 주문 가져오기"})]}),_.jsx("p",{className:"text-[12px] text-muted-foreground",children:"연결된 채널에서 최근 7일간 주문을 가져옵니다."}),t==="idle"&&_.jsxs("button",{type:"button",onClick:o,className:"flex items-center gap-2 px-4 py-2 text-[13px] bg-primary text-primary-foreground rounded-lg hover:bg-primary/90 transition-colors",children:[_.jsx(px,{size:13}),"주문 가져오기"]}),t==="syncing"&&_.jsxs("div",{className:"flex items-center gap-2 text-[13px] text-muted-foreground",children:[_.jsx(t$,{size:14,className:"animate-spin"}),"연결된 채널에서 주문을 가져오는 중..."]}),t==="success"&&a&&_.jsxs("div",{className:"space-y-2",children:[_.jsxs("div",{className:"flex items-center gap-2 text-[13px] text-emerald-600",children:[_.jsx(YI,{size:14}),a.synced>0?`${a.synced}건의 주문을 가져왔습니다.`:"새로운 주문이 없습니다."]}),_.jsx("button",{type:"button",onClick:()=>{window.location.hash="orders"},className:"text-[12px] text-primary hover:underline",children:"주문 목록 보기"})]}),t==="error"&&a&&_.jsxs("div",{className:"space-y-2",children:[_.jsxs("div",{className:"flex items-start gap-2 text-[13px] text-red-600",children:[_.jsx(DM,{size:14,className:"mt-0.5 shrink-0"}),_.jsxs("div",{children:[_.jsx("p",{children:"주문 가져오기에 실패했습니다."}),a.error&&_.jsx("p",{className:"text-[11px] text-red-500/80 mt-0.5",children:a.error})]})]}),_.jsxs("div",{className:"flex items-center gap-3",children:[_.jsx("button",{type:"button",onClick:o,className:"text-[12px] text-primary hover:underline",children:"다시 시도"}),_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:["또는 터미널에서: ",_.jsx("code",{className:"font-mono",children:"sppt order list"})]})]})]})]})}),_.jsxs("div",{className:"p-4 bg-muted/50 rounded-lg border border-border/60 text-left",children:[_.jsx("p",{className:"text-[12px] text-muted-foreground mb-1.5",children:"터미널에서 바로 사용 가능합니다:"}),_.jsxs("div",{className:"space-y-0.5",children:[_.jsx("code",{className:"text-[12px] font-mono text-foreground/80 block",children:"sppt health"}),_.jsx("code",{className:"text-[12px] font-mono text-foreground/80 block",children:"sppt product list"}),_.jsx("code",{className:"text-[12px] font-mono text-foreground/80 block",children:"sppt order list"})]})]}),_.jsxs("div",{className:"flex items-center justify-between",children:[_.jsx("button",{type:"button",onClick:e,className:"px-4 py-2 text-[13px] text-muted-foreground hover:text-foreground transition-colors",children:"채널 더 추가하기"}),_.jsx("button",{type:"button",onClick:()=>{window.location.hash="overview"},className:"px-5 py-2 text-[13px] bg-primary text-primary-foreground rounded-lg hover:bg-primary/90 transition-colors",children:"대시보드로 이동"})]})]})}function YQ({draft:r,doSave:e,channelSaver:t,mk:n}){const[a,i]=q.useState("store"),o=Object.entries(r.channels??{}).filter(([,s])=>{const l=s;return l&&Object.values(l).some(u=>u!==void 0&&u!==""&&u!==null)});return _.jsxs("div",{className:"max-w-[720px] mx-auto",children:[_.jsxs("div",{className:"mb-6",children:[_.jsx("h2",{className:"text-[17px] font-semibold",children:"초기 설정"}),_.jsx("p",{className:"text-[12px] text-muted-foreground mt-0.5",children:"스토어 정보를 입력하고 판매 채널을 연결하세요."})]}),_.jsx(FQ,{current:a}),a==="store"&&_.jsxs("div",{className:"space-y-4",children:[_.jsx(Wf,{title:"스토어 기본 정보",description:"브랜드명과 사업자 정보를 입력하세요. 오픈마켓 입점 시 활용됩니다.",defaultOpen:!0,fields:[{key:"businessName",label:"상호명",type:"text"},{key:"representative",label:"대표자명",type:"text"},{key:"businessRegNumber",label:"사업자등록번호",type:"text",placeholder:"123-45-67890",optional:!0},{key:"mailOrderRegNumber",label:"통신판매업 신고번호",type:"text",placeholder:"2024-서울강남-12345",optional:!0}],values:r.seller??{},onSave:s=>e("seller",{...r,seller:s}),...n("seller")}),_.jsx("div",{className:"flex justify-end pt-2",children:_.jsx("button",{type:"button",onClick:()=>i("channels"),className:"px-5 py-2 text-[13px] bg-primary text-primary-foreground rounded-lg hover:bg-primary/90 transition-colors",children:"다음"})})]}),a==="channels"&&_.jsxs("div",{className:"space-y-4",children:[_.jsx("p",{className:"text-[12px] text-muted-foreground",children:"사용하는 판매 채널의 API 키를 입력하세요. 나중에 추가할 수도 있습니다."}),Object.entries(Kf).filter(([s])=>!AM.has(s)).map(([s,l])=>{var u;return _.jsx(Yf,{channelKey:s,schema:l,current:((u=r.channels)==null?void 0:u[s])??{},onSave:t("channels",s),...n(`channels.${s}`)},s)}),_.jsxs("div",{className:"flex items-center justify-between pt-2",children:[_.jsx("button",{type:"button",onClick:()=>i("store"),className:"px-4 py-2 text-[13px] text-muted-foreground hover:text-foreground transition-colors",children:"이전"}),_.jsx("button",{type:"button",onClick:()=>i("done"),className:"px-5 py-2 text-[13px] bg-primary text-primary-foreground rounded-lg hover:bg-primary/90 transition-colors",children:o.length>0?`다음 (${o.length}개 연결됨)`:"건너뛰기"})]})]}),a==="done"&&_.jsx(UQ,{connectedCount:o.length,onBack:()=>i("channels")})]})}function WQ({initMode:r=!1}){var v,g,y,x;const{data:e,isLoading:t,refetch:n}=YV(),[a,i]=q.useState(null),[o,s]=q.useState({}),[l,u]=q.useState({});q.useEffect(()=>{e&&i(e)},[e]);async function c(b,w){i(w),s(T=>({...T,[b]:!0}));try{await TM(w),u(T=>({...T,[b]:!0})),setTimeout(()=>u(T=>({...T,[b]:!1})),2e3),n()}finally{s(T=>({...T,[b]:!1}))}}function f(b,w){return T=>{if(!a)return;const C=`${b}.${w}`,D={...a[b]??{}};Object.keys(T).length>0?D[w]={...T,channel:w}:delete D[w],c(C,{...a,[b]:D})}}const d=b=>({saving:!!o[b],saved:!!l[b]});return t||!a?_.jsx("div",{className:"text-[13px] text-muted-foreground p-4",children:"설정 불러오는 중..."}):r?_.jsx(YQ,{draft:a,doSave:c,channelSaver:f,mk:d}):_.jsxs("div",{className:"flex gap-8 mx-auto max-w-[860px]",children:[_.jsxs("div",{className:"flex-1 min-w-0 space-y-8",children:[_.jsxs("div",{children:[_.jsx("h2",{className:"text-[17px] font-semibold",children:"설정"}),_.jsx("p",{className:"text-[12px] text-muted-foreground mt-0.5",children:"~/.shopport/config.json 과 양방향 동기화됩니다."}),_.jsxs("div",{className:"mt-2 px-3 py-2 bg-muted/50 rounded-lg border border-border/60 text-[11px] text-muted-foreground",children:["커맨드라인에서도 설정 가능:",_.jsx("code",{className:"ml-2 font-mono text-foreground/70",children:"sppt config set <채널> <키> <값>"}),_.jsx("span",{className:"mx-2 text-border",children:"·"}),_.jsx("code",{className:"font-mono text-foreground/70",children:"sppt config list"})]})]}),_.jsxs(vf,{id:"cfg-seller",title:"사업자 정보",children:[_.jsx(Wf,{title:"사업자 기본 정보",description:"오픈마켓 입점 및 채널 온보딩에 활용됩니다. 사업자등록번호·통신판매업 신고번호는 쿠팡·스마트스토어 등 판매의 필수 전제 조건입니다.",cliNote:"sppt config set seller businessRegNumber <번호>",defaultOpen:!0,fields:[{key:"businessRegNumber",label:"사업자등록번호",type:"text",placeholder:"123-45-67890"},{key:"mailOrderRegNumber",label:"통신판매업 신고번호",type:"text",placeholder:"2024-서울강남-12345"},{key:"businessName",label:"상호명",type:"text"},{key:"representative",label:"대표자명",type:"text"}],values:a.seller??{},onSave:b=>c("seller",{...a,seller:b}),...d("seller")}),_.jsx(Wf,{title:"연 매출 설정",description:"스마트스토어 Npay 등급, 카페24 카드 영중소 우대 등 채널별 수수료율이 연 매출 기준으로 결정됩니다. 대략적인 연 매출을 입력하면 정산 페이지의 수수료율 계산 정확도가 높아집니다.",defaultOpen:!0,fields:[{key:"annualRevenue",label:"연 매출 (원)",type:"number",placeholder:"500000000",optional:!0,hint:"정확하지 않아도 됩니다. 대략적인 구간만 맞아도 등급 판정에 충분합니다."}],values:{annualRevenue:((v=a.settlement)==null?void 0:v.annualRevenue)??""},onSave:b=>c("settlement.annualRevenue",{...a,settlement:{...a.settlement??{},annualRevenue:b.annualRevenue?Number(b.annualRevenue):void 0}}),...d("settlement.annualRevenue")})]}),_.jsx(vf,{id:"cfg-sell",title:"판매 채널",children:Object.entries(Kf).map(([b,w])=>{var C,D;const T=AM.has(b);return _.jsx(Yf,{channelKey:b,schema:w,current:T?((C=a.browserChannels)==null?void 0:C[b])??{}:((D=a.channels)==null?void 0:D[b])??{},onSave:f(T?"browserChannels":"channels",b),...d(`${T?"browserChannels":"channels"}.${b}`)},b)})}),_.jsx(vf,{id:"cfg-source",title:"소싱 채널",children:Object.entries(qT).map(([b,w])=>{var T;return _.jsx(Yf,{channelKey:b,schema:w,current:((T=a.sourceChannels)==null?void 0:T[b])??{},onSave:f("sourceChannels",b),...d(`sourceChannels.${b}`)},b)})}),_.jsxs(vf,{id:"cfg-trend",title:"트렌드 · 외부 도구",children:[Object.entries(ZT).map(([b,w])=>{var T;return _.jsx(Yf,{channelKey:b,schema:w,current:((T=a.trendChannels)==null?void 0:T[b])??{},onSave:f("trendChannels",b),...d(`trendChannels.${b}`)},b)}),_.jsx(Yf,{channelKey:"apify",schema:{label:"Apify",guide:"https://console.apify.com/account/integrations",cliNote:"sppt config set apify apiToken <token>",proxyNote:"shopport 공용 Apify 계정으로 전문몰 랭킹 등을 수집합니다. 크롤링 한도가 부족하거나 전용 계정이 필요하면 직접 설정하세요.",fields:[{key:"apiToken",label:"API Token",type:"password",hint:"Apify Console → Settings → Integrations"}]},current:a.apify??{},onSave:b=>c("apify",{...a,apify:b}),...d("apify")})]}),_.jsx(vf,{id:"cfg-logistics",title:"물류 채널",defaultOpen:!1,children:Object.entries($T).map(([b,w])=>{var T;return _.jsx(Yf,{channelKey:b,schema:w,current:((T=a.logisticsChannels)==null?void 0:T[b])??{},onSave:f("logisticsChannels",b),...d(`logisticsChannels.${b}`)},b)})}),_.jsxs(vf,{id:"cfg-advanced",title:"고급 설정",defaultOpen:!1,children:[_.jsx(Wf,{title:"소싱 환율 (USD → KRW)",description:"중국·해외 소싱 상품의 원가를 원화로 계산할 때 사용합니다.",fields:[{key:"usdToKrw",label:"환율",type:"number",placeholder:"1380",hint:"기본값: 1380",optional:!0}],values:{usdToKrw:a.usdToKrw??""},onSave:b=>c("usdToKrw",{...a,usdToKrw:b.usdToKrw?Number(b.usdToKrw):void 0}),...d("usdToKrw")}),_.jsx(Wf,{title:"DB 연결",description:"PostgreSQL에 운영 이력, 상품 매핑, 주문 내역을 저장합니다. 설정하지 않으면 로컬 파일(JSONL)에 저장됩니다.",fields:[{key:"url",label:"Connection URL",type:"text",placeholder:"postgresql://user:pass@host:5432/db",optional:!0}],values:{url:((g=a.database)==null?void 0:g.url)??""},onSave:b=>c("database",{...a,database:b.url?{url:String(b.url)}:void 0}),...d("database")}),_.jsx(Wf,{title:"프록시 설정",description:"Fly.io 정적 IP 프록시를 통해 쿠팡 IP 화이트리스트를 우회합니다.",fields:[{key:"enabled",label:"사용",type:"boolean"},{key:"baseUrl",label:"프록시 URL",type:"text",placeholder:"https://rocketsell-proxy.fly.dev",optional:!0}],values:{enabled:((y=a.proxy)==null?void 0:y.enabled)??!1,baseUrl:((x=a.proxy)==null?void 0:x.baseUrl)??""},onSave:b=>c("proxy",{...a,proxy:{enabled:!!b.enabled,baseUrl:b.baseUrl?String(b.baseUrl):void 0}}),...d("proxy")})]})]}),_.jsx("div",{className:"w-36 shrink-0","aria-hidden":"true"}),_.jsx(HQ,{})]})}const bv=r=>r.toISOString().slice(0,10),cO=r=>{const e=new Date;return e.setDate(e.getDate()-r),e};function FM({from:r,to:e,onChange:t,className:n}){var f;const a=bv(new Date),i=new Date,o=`${i.getFullYear()}-${String(i.getMonth()+1).padStart(2,"0")}-01`,s=bv(new Date(i.getFullYear(),i.getMonth()-1,1)),l=bv(new Date(i.getFullYear(),i.getMonth(),0)),u=[{label:"전체",from:"",to:""},{label:"오늘",from:a,to:a},{label:"7일",from:bv(cO(7)),to:a},{label:"이번 달",from:o,to:a},{label:"지난 달",from:s,to:l},{label:"3개월",from:bv(cO(90)),to:a}],c=((f=u.find(d=>d.from===r&&d.to===e))==null?void 0:f.label)??null;return _.jsxs("div",{className:Ae("flex items-center gap-2 flex-wrap",n),children:[_.jsx("div",{className:"flex items-center gap-1",children:u.map(({label:d,from:v,to:g})=>_.jsx("button",{type:"button",onClick:()=>t(v,g),className:Ae("text-[11px] px-2 py-0.5 rounded border cursor-pointer transition-colors",c===d?"border-primary/60 bg-primary/10 text-foreground font-medium":"border-border bg-card text-muted-foreground hover:text-foreground"),children:d},d))}),_.jsx("span",{className:"text-muted-foreground/30",children:"|"}),_.jsx("input",{type:"date",value:r,onChange:d=>t(d.target.value,e),className:"text-[12px] px-2 py-1 rounded-md border border-border bg-card outline-none"}),_.jsx("span",{className:"text-[11px] text-muted-foreground",children:"~"}),_.jsx("input",{type:"date",value:e,onChange:d=>t(r,d.target.value),className:"text-[12px] px-2 py-1 rounded-md border border-border bg-card outline-none"}),(!!r||!!e)&&c===null&&_.jsxs("button",{type:"button",onClick:()=>t("",""),className:"text-[11px] text-muted-foreground hover:text-foreground flex items-center gap-0.5 cursor-pointer",children:[_.jsx(ml,{size:11})," 초기화"]})]})}const i6=6048e5,XQ=864e5,o6=6e4,s6=36e5,Ty=43200,fO=1440,hO=Symbol.for("constructDateFrom");function Yi(r,e){return typeof r=="function"?r(e):r&&typeof r=="object"&&hO in r?r[hO](e):r instanceof Date?new r.constructor(e):new Date(e)}function br(r,e){return Yi(e||r,r)}let qQ={};function jg(){return qQ}function Wp(r,e){var s,l,u,c;const t=jg(),n=(e==null?void 0:e.weekStartsOn)??((l=(s=e==null?void 0:e.locale)==null?void 0:s.options)==null?void 0:l.weekStartsOn)??t.weekStartsOn??((c=(u=t.locale)==null?void 0:u.options)==null?void 0:c.weekStartsOn)??0,a=br(r,e==null?void 0:e.in),i=a.getDay(),o=(i<n?7:0)+i-n;return a.setDate(a.getDate()-o),a.setHours(0,0,0,0),a}function bx(r,e){return Wp(r,{...e,weekStartsOn:1})}function l6(r,e){const t=br(r,e==null?void 0:e.in),n=t.getFullYear(),a=Yi(t,0);a.setFullYear(n+1,0,4),a.setHours(0,0,0,0);const i=bx(a),o=Yi(t,0);o.setFullYear(n,0,4),o.setHours(0,0,0,0);const s=bx(o);return t.getTime()>=i.getTime()?n+1:t.getTime()>=s.getTime()?n:n-1}function _x(r){const e=br(r),t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),+r-+t}function H1(r,...e){const t=Yi.bind(null,r||e.find(n=>typeof n=="object"));return e.map(t)}function dO(r,e){const t=br(r,e==null?void 0:e.in);return t.setHours(0,0,0,0),t}function ZQ(r,e,t){const[n,a]=H1(t==null?void 0:t.in,r,e),i=dO(n),o=dO(a),s=+i-_x(i),l=+o-_x(o);return Math.round((s-l)/XQ)}function $Q(r,e){const t=l6(r,e),n=Yi(r,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),bx(n)}function Y0(r,e){const t=+br(r)-+br(e);return t<0?-1:t>0?1:t}function KQ(r){return Yi(r,Date.now())}function QQ(r){return r instanceof Date||typeof r=="object"&&Object.prototype.toString.call(r)==="[object Date]"}function JQ(r){return!(!QQ(r)&&typeof r!="number"||isNaN(+br(r)))}function eJ(r,e,t){const[n,a]=H1(t==null?void 0:t.in,r,e),i=n.getFullYear()-a.getFullYear(),o=n.getMonth()-a.getMonth();return i*12+o}function tJ(r){return e=>{const n=(r?Math[r]:Math.trunc)(e);return n===0?0:n}}function rJ(r,e){return+br(r)-+br(e)}function nJ(r,e){const t=br(r,e==null?void 0:e.in);return t.setHours(23,59,59,999),t}function aJ(r,e){const t=br(r,e==null?void 0:e.in),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(23,59,59,999),t}function iJ(r,e){const t=br(r,e==null?void 0:e.in);return+nJ(t,e)==+aJ(t,e)}function oJ(r,e,t){const[n,a,i]=H1(t==null?void 0:t.in,r,r,e),o=Y0(a,i),s=Math.abs(eJ(a,i));if(s<1)return 0;a.getMonth()===1&&a.getDate()>27&&a.setDate(30),a.setMonth(a.getMonth()-o*s);let l=Y0(a,i)===-o;iJ(n)&&s===1&&Y0(n,i)===1&&(l=!1);const u=o*(s-+l);return u===0?0:u}function sJ(r,e,t){const n=rJ(r,e)/1e3;return tJ(t==null?void 0:t.roundingMethod)(n)}function lJ(r,e){const t=br(r,e==null?void 0:e.in);return t.setFullYear(t.getFullYear(),0,1),t.setHours(0,0,0,0),t}const uJ={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},cJ=(r,e,t)=>{let n;const a=uJ[r];return typeof a=="string"?n=a:e===1?n=a.one:n=a.other.replace("{{count}}",e.toString()),t!=null&&t.addSuffix?t.comparison&&t.comparison>0?"in "+n:n+" ago":n};function lh(r){return(e={})=>{const t=e.width?String(e.width):r.defaultWidth;return r.formats[t]||r.formats[r.defaultWidth]}}const fJ={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},hJ={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dJ={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},vJ={date:lh({formats:fJ,defaultWidth:"full"}),time:lh({formats:hJ,defaultWidth:"full"}),dateTime:lh({formats:dJ,defaultWidth:"full"})},pJ={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},gJ=(r,e,t,n)=>pJ[r];function Ni(r){return(e,t)=>{const n=t!=null&&t.context?String(t.context):"standalone";let a;if(n==="formatting"&&r.formattingValues){const o=r.defaultFormattingWidth||r.defaultWidth,s=t!=null&&t.width?String(t.width):o;a=r.formattingValues[s]||r.formattingValues[o]}else{const o=r.defaultWidth,s=t!=null&&t.width?String(t.width):r.defaultWidth;a=r.values[s]||r.values[o]}const i=r.argumentCallback?r.argumentCallback(e):e;return a[i]}}const mJ={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},yJ={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},xJ={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},bJ={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},_J={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},SJ={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},wJ=(r,e)=>{const t=Number(r),n=t%100;if(n>20||n<10)switch(n%10){case 1:return t+"st";case 2:return t+"nd";case 3:return t+"rd"}return t+"th"},TJ={ordinalNumber:wJ,era:Ni({values:mJ,defaultWidth:"wide"}),quarter:Ni({values:yJ,defaultWidth:"wide",argumentCallback:r=>r-1}),month:Ni({values:xJ,defaultWidth:"wide"}),day:Ni({values:bJ,defaultWidth:"wide"}),dayPeriod:Ni({values:_J,defaultWidth:"wide",formattingValues:SJ,defaultFormattingWidth:"wide"})};function Li(r){return(e,t={})=>{const n=t.width,a=n&&r.matchPatterns[n]||r.matchPatterns[r.defaultMatchWidth],i=e.match(a);if(!i)return null;const o=i[0],s=n&&r.parsePatterns[n]||r.parsePatterns[r.defaultParseWidth],l=Array.isArray(s)?AJ(s,f=>f.test(o)):CJ(s,f=>f.test(o));let u;u=r.valueCallback?r.valueCallback(l):l,u=t.valueCallback?t.valueCallback(u):u;const c=e.slice(o.length);return{value:u,rest:c}}}function CJ(r,e){for(const t in r)if(Object.prototype.hasOwnProperty.call(r,t)&&e(r[t]))return t}function AJ(r,e){for(let t=0;t<r.length;t++)if(e(r[t]))return t}function u6(r){return(e,t={})=>{const n=e.match(r.matchPattern);if(!n)return null;const a=n[0],i=e.match(r.parsePattern);if(!i)return null;let o=r.valueCallback?r.valueCallback(i[0]):i[0];o=t.valueCallback?t.valueCallback(o):o;const s=e.slice(a.length);return{value:o,rest:s}}}const MJ=/^(\d+)(th|st|nd|rd)?/i,DJ=/\d+/i,NJ={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},LJ={any:[/^b/i,/^(a|c)/i]},RJ={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},EJ={any:[/1/i,/2/i,/3/i,/4/i]},kJ={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},IJ={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},OJ={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},PJ={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},jJ={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},zJ={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},BJ={ordinalNumber:u6({matchPattern:MJ,parsePattern:DJ,valueCallback:r=>parseInt(r,10)}),era:Li({matchPatterns:NJ,defaultMatchWidth:"wide",parsePatterns:LJ,defaultParseWidth:"any"}),quarter:Li({matchPatterns:RJ,defaultMatchWidth:"wide",parsePatterns:EJ,defaultParseWidth:"any",valueCallback:r=>r+1}),month:Li({matchPatterns:kJ,defaultMatchWidth:"wide",parsePatterns:IJ,defaultParseWidth:"any"}),day:Li({matchPatterns:OJ,defaultMatchWidth:"wide",parsePatterns:PJ,defaultParseWidth:"any"}),dayPeriod:Li({matchPatterns:jJ,defaultMatchWidth:"any",parsePatterns:zJ,defaultParseWidth:"any"})},c6={code:"en-US",formatDistance:cJ,formatLong:vJ,formatRelative:gJ,localize:TJ,match:BJ,options:{weekStartsOn:0,firstWeekContainsDate:1}};function VJ(r,e){const t=br(r,e==null?void 0:e.in);return ZQ(t,lJ(t))+1}function GJ(r,e){const t=br(r,e==null?void 0:e.in),n=+bx(t)-+$Q(t);return Math.round(n/i6)+1}function f6(r,e){var c,f,d,v;const t=br(r,e==null?void 0:e.in),n=t.getFullYear(),a=jg(),i=(e==null?void 0:e.firstWeekContainsDate)??((f=(c=e==null?void 0:e.locale)==null?void 0:c.options)==null?void 0:f.firstWeekContainsDate)??a.firstWeekContainsDate??((v=(d=a.locale)==null?void 0:d.options)==null?void 0:v.firstWeekContainsDate)??1,o=Yi((e==null?void 0:e.in)||r,0);o.setFullYear(n+1,0,i),o.setHours(0,0,0,0);const s=Wp(o,e),l=Yi((e==null?void 0:e.in)||r,0);l.setFullYear(n,0,i),l.setHours(0,0,0,0);const u=Wp(l,e);return+t>=+s?n+1:+t>=+u?n:n-1}function HJ(r,e){var s,l,u,c;const t=jg(),n=(e==null?void 0:e.firstWeekContainsDate)??((l=(s=e==null?void 0:e.locale)==null?void 0:s.options)==null?void 0:l.firstWeekContainsDate)??t.firstWeekContainsDate??((c=(u=t.locale)==null?void 0:u.options)==null?void 0:c.firstWeekContainsDate)??1,a=f6(r,e),i=Yi((e==null?void 0:e.in)||r,0);return i.setFullYear(a,0,n),i.setHours(0,0,0,0),Wp(i,e)}function FJ(r,e){const t=br(r,e==null?void 0:e.in),n=+Wp(t,e)-+HJ(t,e);return Math.round(n/i6)+1}function Pt(r,e){const t=r<0?"-":"",n=Math.abs(r).toString().padStart(e,"0");return t+n}const Es={y(r,e){const t=r.getFullYear(),n=t>0?t:1-t;return Pt(e==="yy"?n%100:n,e.length)},M(r,e){const t=r.getMonth();return e==="M"?String(t+1):Pt(t+1,2)},d(r,e){return Pt(r.getDate(),e.length)},a(r,e){const t=r.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return t.toUpperCase();case"aaa":return t;case"aaaaa":return t[0];case"aaaa":default:return t==="am"?"a.m.":"p.m."}},h(r,e){return Pt(r.getHours()%12||12,e.length)},H(r,e){return Pt(r.getHours(),e.length)},m(r,e){return Pt(r.getMinutes(),e.length)},s(r,e){return Pt(r.getSeconds(),e.length)},S(r,e){const t=e.length,n=r.getMilliseconds(),a=Math.trunc(n*Math.pow(10,t-3));return Pt(a,e.length)}},pf={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},vO={G:function(r,e,t){const n=r.getFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return t.era(n,{width:"abbreviated"});case"GGGGG":return t.era(n,{width:"narrow"});case"GGGG":default:return t.era(n,{width:"wide"})}},y:function(r,e,t){if(e==="yo"){const n=r.getFullYear(),a=n>0?n:1-n;return t.ordinalNumber(a,{unit:"year"})}return Es.y(r,e)},Y:function(r,e,t,n){const a=f6(r,n),i=a>0?a:1-a;if(e==="YY"){const o=i%100;return Pt(o,2)}return e==="Yo"?t.ordinalNumber(i,{unit:"year"}):Pt(i,e.length)},R:function(r,e){const t=l6(r);return Pt(t,e.length)},u:function(r,e){const t=r.getFullYear();return Pt(t,e.length)},Q:function(r,e,t){const n=Math.ceil((r.getMonth()+1)/3);switch(e){case"Q":return String(n);case"QQ":return Pt(n,2);case"Qo":return t.ordinalNumber(n,{unit:"quarter"});case"QQQ":return t.quarter(n,{width:"abbreviated",context:"formatting"});case"QQQQQ":return t.quarter(n,{width:"narrow",context:"formatting"});case"QQQQ":default:return t.quarter(n,{width:"wide",context:"formatting"})}},q:function(r,e,t){const n=Math.ceil((r.getMonth()+1)/3);switch(e){case"q":return String(n);case"qq":return Pt(n,2);case"qo":return t.ordinalNumber(n,{unit:"quarter"});case"qqq":return t.quarter(n,{width:"abbreviated",context:"standalone"});case"qqqqq":return t.quarter(n,{width:"narrow",context:"standalone"});case"qqqq":default:return t.quarter(n,{width:"wide",context:"standalone"})}},M:function(r,e,t){const n=r.getMonth();switch(e){case"M":case"MM":return Es.M(r,e);case"Mo":return t.ordinalNumber(n+1,{unit:"month"});case"MMM":return t.month(n,{width:"abbreviated",context:"formatting"});case"MMMMM":return t.month(n,{width:"narrow",context:"formatting"});case"MMMM":default:return t.month(n,{width:"wide",context:"formatting"})}},L:function(r,e,t){const n=r.getMonth();switch(e){case"L":return String(n+1);case"LL":return Pt(n+1,2);case"Lo":return t.ordinalNumber(n+1,{unit:"month"});case"LLL":return t.month(n,{width:"abbreviated",context:"standalone"});case"LLLLL":return t.month(n,{width:"narrow",context:"standalone"});case"LLLL":default:return t.month(n,{width:"wide",context:"standalone"})}},w:function(r,e,t,n){const a=FJ(r,n);return e==="wo"?t.ordinalNumber(a,{unit:"week"}):Pt(a,e.length)},I:function(r,e,t){const n=GJ(r);return e==="Io"?t.ordinalNumber(n,{unit:"week"}):Pt(n,e.length)},d:function(r,e,t){return e==="do"?t.ordinalNumber(r.getDate(),{unit:"date"}):Es.d(r,e)},D:function(r,e,t){const n=VJ(r);return e==="Do"?t.ordinalNumber(n,{unit:"dayOfYear"}):Pt(n,e.length)},E:function(r,e,t){const n=r.getDay();switch(e){case"E":case"EE":case"EEE":return t.day(n,{width:"abbreviated",context:"formatting"});case"EEEEE":return t.day(n,{width:"narrow",context:"formatting"});case"EEEEEE":return t.day(n,{width:"short",context:"formatting"});case"EEEE":default:return t.day(n,{width:"wide",context:"formatting"})}},e:function(r,e,t,n){const a=r.getDay(),i=(a-n.weekStartsOn+8)%7||7;switch(e){case"e":return String(i);case"ee":return Pt(i,2);case"eo":return t.ordinalNumber(i,{unit:"day"});case"eee":return t.day(a,{width:"abbreviated",context:"formatting"});case"eeeee":return t.day(a,{width:"narrow",context:"formatting"});case"eeeeee":return t.day(a,{width:"short",context:"formatting"});case"eeee":default:return t.day(a,{width:"wide",context:"formatting"})}},c:function(r,e,t,n){const a=r.getDay(),i=(a-n.weekStartsOn+8)%7||7;switch(e){case"c":return String(i);case"cc":return Pt(i,e.length);case"co":return t.ordinalNumber(i,{unit:"day"});case"ccc":return t.day(a,{width:"abbreviated",context:"standalone"});case"ccccc":return t.day(a,{width:"narrow",context:"standalone"});case"cccccc":return t.day(a,{width:"short",context:"standalone"});case"cccc":default:return t.day(a,{width:"wide",context:"standalone"})}},i:function(r,e,t){const n=r.getDay(),a=n===0?7:n;switch(e){case"i":return String(a);case"ii":return Pt(a,e.length);case"io":return t.ordinalNumber(a,{unit:"day"});case"iii":return t.day(n,{width:"abbreviated",context:"formatting"});case"iiiii":return t.day(n,{width:"narrow",context:"formatting"});case"iiiiii":return t.day(n,{width:"short",context:"formatting"});case"iiii":default:return t.day(n,{width:"wide",context:"formatting"})}},a:function(r,e,t){const a=r.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return t.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"aaa":return t.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return t.dayPeriod(a,{width:"narrow",context:"formatting"});case"aaaa":default:return t.dayPeriod(a,{width:"wide",context:"formatting"})}},b:function(r,e,t){const n=r.getHours();let a;switch(n===12?a=pf.noon:n===0?a=pf.midnight:a=n/12>=1?"pm":"am",e){case"b":case"bb":return t.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"bbb":return t.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return t.dayPeriod(a,{width:"narrow",context:"formatting"});case"bbbb":default:return t.dayPeriod(a,{width:"wide",context:"formatting"})}},B:function(r,e,t){const n=r.getHours();let a;switch(n>=17?a=pf.evening:n>=12?a=pf.afternoon:n>=4?a=pf.morning:a=pf.night,e){case"B":case"BB":case"BBB":return t.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"BBBBB":return t.dayPeriod(a,{width:"narrow",context:"formatting"});case"BBBB":default:return t.dayPeriod(a,{width:"wide",context:"formatting"})}},h:function(r,e,t){if(e==="ho"){let n=r.getHours()%12;return n===0&&(n=12),t.ordinalNumber(n,{unit:"hour"})}return Es.h(r,e)},H:function(r,e,t){return e==="Ho"?t.ordinalNumber(r.getHours(),{unit:"hour"}):Es.H(r,e)},K:function(r,e,t){const n=r.getHours()%12;return e==="Ko"?t.ordinalNumber(n,{unit:"hour"}):Pt(n,e.length)},k:function(r,e,t){let n=r.getHours();return n===0&&(n=24),e==="ko"?t.ordinalNumber(n,{unit:"hour"}):Pt(n,e.length)},m:function(r,e,t){return e==="mo"?t.ordinalNumber(r.getMinutes(),{unit:"minute"}):Es.m(r,e)},s:function(r,e,t){return e==="so"?t.ordinalNumber(r.getSeconds(),{unit:"second"}):Es.s(r,e)},S:function(r,e){return Es.S(r,e)},X:function(r,e,t){const n=r.getTimezoneOffset();if(n===0)return"Z";switch(e){case"X":return gO(n);case"XXXX":case"XX":return Cu(n);case"XXXXX":case"XXX":default:return Cu(n,":")}},x:function(r,e,t){const n=r.getTimezoneOffset();switch(e){case"x":return gO(n);case"xxxx":case"xx":return Cu(n);case"xxxxx":case"xxx":default:return Cu(n,":")}},O:function(r,e,t){const n=r.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+pO(n,":");case"OOOO":default:return"GMT"+Cu(n,":")}},z:function(r,e,t){const n=r.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+pO(n,":");case"zzzz":default:return"GMT"+Cu(n,":")}},t:function(r,e,t){const n=Math.trunc(+r/1e3);return Pt(n,e.length)},T:function(r,e,t){return Pt(+r,e.length)}};function pO(r,e=""){const t=r>0?"-":"+",n=Math.abs(r),a=Math.trunc(n/60),i=n%60;return i===0?t+String(a):t+String(a)+e+Pt(i,2)}function gO(r,e){return r%60===0?(r>0?"-":"+")+Pt(Math.abs(r)/60,2):Cu(r,e)}function Cu(r,e=""){const t=r>0?"-":"+",n=Math.abs(r),a=Pt(Math.trunc(n/60),2),i=Pt(n%60,2);return t+a+e+i}const mO=(r,e)=>{switch(r){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});case"PPPP":default:return e.date({width:"full"})}},h6=(r,e)=>{switch(r){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});case"pppp":default:return e.time({width:"full"})}},UJ=(r,e)=>{const t=r.match(/(P+)(p+)?/)||[],n=t[1],a=t[2];if(!a)return mO(r,e);let i;switch(n){case"P":i=e.dateTime({width:"short"});break;case"PP":i=e.dateTime({width:"medium"});break;case"PPP":i=e.dateTime({width:"long"});break;case"PPPP":default:i=e.dateTime({width:"full"});break}return i.replace("{{date}}",mO(n,e)).replace("{{time}}",h6(a,e))},YJ={p:h6,P:UJ},WJ=/^D+$/,XJ=/^Y+$/,qJ=["D","DD","YY","YYYY"];function ZJ(r){return WJ.test(r)}function $J(r){return XJ.test(r)}function KJ(r,e,t){const n=QJ(r,e,t);if(console.warn(n),qJ.includes(r))throw new RangeError(n)}function QJ(r,e,t){const n=r[0]==="Y"?"years":"days of the month";return`Use \`${r.toLowerCase()}\` instead of \`${r}\` (in \`${e}\`) for formatting ${n} to the input \`${t}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const JJ=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,eee=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,tee=/^'([^]*?)'?$/,ree=/''/g,nee=/[a-zA-Z]/;function aee(r,e,t){var c,f,d,v,g,y,x,b;const n=jg(),a=(t==null?void 0:t.locale)??n.locale??c6,i=(t==null?void 0:t.firstWeekContainsDate)??((f=(c=t==null?void 0:t.locale)==null?void 0:c.options)==null?void 0:f.firstWeekContainsDate)??n.firstWeekContainsDate??((v=(d=n.locale)==null?void 0:d.options)==null?void 0:v.firstWeekContainsDate)??1,o=(t==null?void 0:t.weekStartsOn)??((y=(g=t==null?void 0:t.locale)==null?void 0:g.options)==null?void 0:y.weekStartsOn)??n.weekStartsOn??((b=(x=n.locale)==null?void 0:x.options)==null?void 0:b.weekStartsOn)??0,s=br(r,t==null?void 0:t.in);if(!JQ(s))throw new RangeError("Invalid time value");let l=e.match(eee).map(w=>{const T=w[0];if(T==="p"||T==="P"){const C=YJ[T];return C(w,a.formatLong)}return w}).join("").match(JJ).map(w=>{if(w==="''")return{isToken:!1,value:"'"};const T=w[0];if(T==="'")return{isToken:!1,value:iee(w)};if(vO[T])return{isToken:!0,value:w};if(T.match(nee))throw new RangeError("Format string contains an unescaped latin alphabet character `"+T+"`");return{isToken:!1,value:w}});a.localize.preprocessor&&(l=a.localize.preprocessor(s,l));const u={firstWeekContainsDate:i,weekStartsOn:o,locale:a};return l.map(w=>{if(!w.isToken)return w.value;const T=w.value;(!(t!=null&&t.useAdditionalWeekYearTokens)&&$J(T)||!(t!=null&&t.useAdditionalDayOfYearTokens)&&ZJ(T))&&KJ(T,e,String(r));const C=vO[T[0]];return C(s,T,a.localize,u)}).join("")}function iee(r){const e=r.match(tee);return e?e[1].replace(ree,"'"):r}function oee(r,e,t){const n=jg(),a=(t==null?void 0:t.locale)??n.locale??c6,i=2520,o=Y0(r,e);if(isNaN(o))throw new RangeError("Invalid time value");const s=Object.assign({},t,{addSuffix:t==null?void 0:t.addSuffix,comparison:o}),[l,u]=H1(t==null?void 0:t.in,...o>0?[e,r]:[r,e]),c=sJ(u,l),f=(_x(u)-_x(l))/1e3,d=Math.round((c-f)/60);let v;if(d<2)return t!=null&&t.includeSeconds?c<5?a.formatDistance("lessThanXSeconds",5,s):c<10?a.formatDistance("lessThanXSeconds",10,s):c<20?a.formatDistance("lessThanXSeconds",20,s):c<40?a.formatDistance("halfAMinute",0,s):c<60?a.formatDistance("lessThanXMinutes",1,s):a.formatDistance("xMinutes",1,s):d===0?a.formatDistance("lessThanXMinutes",1,s):a.formatDistance("xMinutes",d,s);if(d<45)return a.formatDistance("xMinutes",d,s);if(d<90)return a.formatDistance("aboutXHours",1,s);if(d<fO){const g=Math.round(d/60);return a.formatDistance("aboutXHours",g,s)}else{if(d<i)return a.formatDistance("xDays",1,s);if(d<Ty){const g=Math.round(d/fO);return a.formatDistance("xDays",g,s)}else if(d<Ty*2)return v=Math.round(d/Ty),a.formatDistance("aboutXMonths",v,s)}if(v=oJ(u,l),v<12){const g=Math.round(d/Ty);return a.formatDistance("xMonths",g,s)}else{const g=v%12,y=Math.trunc(v/12);return g<3?a.formatDistance("aboutXYears",y,s):g<9?a.formatDistance("overXYears",y,s):a.formatDistance("almostXYears",y+1,s)}}function UM(r,e){return oee(r,KQ(r),e)}function see(r,e){const t=()=>Yi(e==null?void 0:e.in,NaN),a=fee(r);let i;if(a.date){const u=hee(a.date,2);i=dee(u.restDateString,u.year)}if(!i||isNaN(+i))return t();const o=+i;let s=0,l;if(a.time&&(s=vee(a.time),isNaN(s)))return t();if(a.timezone){if(l=pee(a.timezone),isNaN(l))return t()}else{const u=new Date(o+s),c=br(0,e==null?void 0:e.in);return c.setFullYear(u.getUTCFullYear(),u.getUTCMonth(),u.getUTCDate()),c.setHours(u.getUTCHours(),u.getUTCMinutes(),u.getUTCSeconds(),u.getUTCMilliseconds()),c}return br(o+s+l,e==null?void 0:e.in)}const Cy={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},lee=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,uee=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,cee=/^([+-])(\d{2})(?::?(\d{2}))?$/;function fee(r){const e={},t=r.split(Cy.dateTimeDelimiter);let n;if(t.length>2)return e;if(/:/.test(t[0])?n=t[0]:(e.date=t[0],n=t[1],Cy.timeZoneDelimiter.test(e.date)&&(e.date=r.split(Cy.timeZoneDelimiter)[0],n=r.substr(e.date.length,r.length))),n){const a=Cy.timezone.exec(n);a?(e.time=n.replace(a[1],""),e.timezone=a[1]):e.time=n}return e}function hee(r,e){const t=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+e)+"})|(\\d{2}|[+-]\\d{"+(2+e)+"})$)"),n=r.match(t);if(!n)return{year:NaN,restDateString:""};const a=n[1]?parseInt(n[1]):null,i=n[2]?parseInt(n[2]):null;return{year:i===null?a:i*100,restDateString:r.slice((n[1]||n[2]).length)}}function dee(r,e){if(e===null)return new Date(NaN);const t=r.match(lee);if(!t)return new Date(NaN);const n=!!t[4],a=_v(t[1]),i=_v(t[2])-1,o=_v(t[3]),s=_v(t[4]),l=_v(t[5])-1;if(n)return bee(e,s,l)?gee(e,s,l):new Date(NaN);{const u=new Date(0);return!yee(e,i,o)||!xee(e,a)?new Date(NaN):(u.setUTCFullYear(e,i,Math.max(a,o)),u)}}function _v(r){return r?parseInt(r):1}function vee(r){const e=r.match(uee);if(!e)return NaN;const t=ew(e[1]),n=ew(e[2]),a=ew(e[3]);return _ee(t,n,a)?t*s6+n*o6+a*1e3:NaN}function ew(r){return r&&parseFloat(r.replace(",","."))||0}function pee(r){if(r==="Z")return 0;const e=r.match(cee);if(!e)return 0;const t=e[1]==="+"?-1:1,n=parseInt(e[2]),a=e[3]&&parseInt(e[3])||0;return See(n,a)?t*(n*s6+a*o6):NaN}function gee(r,e,t){const n=new Date(0);n.setUTCFullYear(r,0,4);const a=n.getUTCDay()||7,i=(e-1)*7+t+1-a;return n.setUTCDate(n.getUTCDate()+i),n}const mee=[31,null,31,30,31,30,31,31,30,31,30,31];function d6(r){return r%400===0||r%4===0&&r%100!==0}function yee(r,e,t){return e>=0&&e<=11&&t>=1&&t<=(mee[e]||(d6(r)?29:28))}function xee(r,e){return e>=1&&e<=(d6(r)?366:365)}function bee(r,e,t){return e>=1&&e<=53&&t>=0&&t<=6}function _ee(r,e,t){return r===24?e===0&&t===0:t>=0&&t<60&&e>=0&&e<60&&r>=0&&r<25}function See(r,e){return e>=0&&e<=59}const wee={lessThanXSeconds:{one:"1초 미만",other:"{{count}}초 미만"},xSeconds:{one:"1초",other:"{{count}}초"},halfAMinute:"30초",lessThanXMinutes:{one:"1분 미만",other:"{{count}}분 미만"},xMinutes:{one:"1분",other:"{{count}}분"},aboutXHours:{one:"약 1시간",other:"약 {{count}}시간"},xHours:{one:"1시간",other:"{{count}}시간"},xDays:{one:"1일",other:"{{count}}일"},aboutXWeeks:{one:"약 1주",other:"약 {{count}}주"},xWeeks:{one:"1주",other:"{{count}}주"},aboutXMonths:{one:"약 1개월",other:"약 {{count}}개월"},xMonths:{one:"1개월",other:"{{count}}개월"},aboutXYears:{one:"약 1년",other:"약 {{count}}년"},xYears:{one:"1년",other:"{{count}}년"},overXYears:{one:"1년 이상",other:"{{count}}년 이상"},almostXYears:{one:"거의 1년",other:"거의 {{count}}년"}},Tee=(r,e,t)=>{let n;const a=wee[r];return typeof a=="string"?n=a:e===1?n=a.one:n=a.other.replace("{{count}}",e.toString()),t!=null&&t.addSuffix?t.comparison&&t.comparison>0?n+" 후":n+" 전":n},Cee={full:"y년 M월 d일 EEEE",long:"y년 M월 d일",medium:"y.MM.dd",short:"y.MM.dd"},Aee={full:"a H시 mm분 ss초 zzzz",long:"a H:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},Mee={full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},Dee={date:lh({formats:Cee,defaultWidth:"full"}),time:lh({formats:Aee,defaultWidth:"full"}),dateTime:lh({formats:Mee,defaultWidth:"full"})},Nee={lastWeek:"'지난' eeee p",yesterday:"'어제' p",today:"'오늘' p",tomorrow:"'내일' p",nextWeek:"'다음' eeee p",other:"P"},Lee=(r,e,t,n)=>Nee[r],Ree={narrow:["BC","AD"],abbreviated:["BC","AD"],wide:["기원전","서기"]},Eee={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1분기","2분기","3분기","4분기"]},kee={narrow:["1","2","3","4","5","6","7","8","9","10","11","12"],abbreviated:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"],wide:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"]},Iee={narrow:["일","월","화","수","목","금","토"],short:["일","월","화","수","목","금","토"],abbreviated:["일","월","화","수","목","금","토"],wide:["일요일","월요일","화요일","수요일","목요일","금요일","토요일"]},Oee={narrow:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},abbreviated:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},wide:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"}},Pee={narrow:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},abbreviated:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},wide:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"}},jee=(r,e)=>{const t=Number(r);switch(String(e==null?void 0:e.unit)){case"minute":case"second":return String(t);case"date":return t+"일";default:return t+"번째"}},zee={ordinalNumber:jee,era:Ni({values:Ree,defaultWidth:"wide"}),quarter:Ni({values:Eee,defaultWidth:"wide",argumentCallback:r=>r-1}),month:Ni({values:kee,defaultWidth:"wide"}),day:Ni({values:Iee,defaultWidth:"wide"}),dayPeriod:Ni({values:Oee,defaultWidth:"wide",formattingValues:Pee,defaultFormattingWidth:"wide"})},Bee=/^(\d+)(일|번째)?/i,Vee=/\d+/i,Gee={narrow:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(기원전|서기)/i},Hee={any:[/^(bc|기원전)/i,/^(ad|서기)/i]},Fee={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234]사?분기/i},Uee={any:[/1/i,/2/i,/3/i,/4/i]},Yee={narrow:/^(1[012]|[123456789])/,abbreviated:/^(1[012]|[123456789])월/i,wide:/^(1[012]|[123456789])월/i},Wee={any:[/^1월?$/,/^2/,/^3/,/^4/,/^5/,/^6/,/^7/,/^8/,/^9/,/^10/,/^11/,/^12/]},Xee={narrow:/^[일월화수목금토]/,short:/^[일월화수목금토]/,abbreviated:/^[일월화수목금토]/,wide:/^[일월화수목금토]요일/},qee={any:[/^일/,/^월/,/^화/,/^수/,/^목/,/^금/,/^토/]},Zee={any:/^(am|pm|오전|오후|자정|정오|아침|저녁|밤)/i},$ee={any:{am:/^(am|오전)/i,pm:/^(pm|오후)/i,midnight:/^자정/i,noon:/^정오/i,morning:/^아침/i,afternoon:/^오후/i,evening:/^저녁/i,night:/^밤/i}},Kee={ordinalNumber:u6({matchPattern:Bee,parsePattern:Vee,valueCallback:r=>parseInt(r,10)}),era:Li({matchPatterns:Gee,defaultMatchWidth:"wide",parsePatterns:Hee,defaultParseWidth:"any"}),quarter:Li({matchPatterns:Fee,defaultMatchWidth:"wide",parsePatterns:Uee,defaultParseWidth:"any",valueCallback:r=>r+1}),month:Li({matchPatterns:Yee,defaultMatchWidth:"wide",parsePatterns:Wee,defaultParseWidth:"any"}),day:Li({matchPatterns:Xee,defaultMatchWidth:"wide",parsePatterns:qee,defaultParseWidth:"any"}),dayPeriod:Li({matchPatterns:Zee,defaultMatchWidth:"any",parsePatterns:$ee,defaultParseWidth:"any"})},F1={code:"ko",formatDistance:Tee,formatLong:Dee,formatRelative:Lee,localize:zee,match:Kee,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Qee(){const r=window.location.hash.slice(1),e=r.includes("?")?r.split("?")[1]:"",n=new URLSearchParams(e).get("status");return n?new Set(n.split(",")):new Set}const Jee={pending:"결제대기",paid:"결제완료",confirmed:"구매확정",preparing:"발송준비",shipped:"배송중",delivered:"배송완료",cancelled:"취소",returned:"반품",unknown:"알수없음"},yO={pending:"bg-amber-100 text-amber-700 dark:bg-amber-950/50 dark:text-amber-400",paid:"bg-blue-100 text-blue-700 dark:bg-blue-950/50 dark:text-blue-400",confirmed:"bg-emerald-100 text-emerald-700 dark:bg-emerald-950/50 dark:text-emerald-400",preparing:"bg-purple-100 text-purple-700 dark:bg-purple-950/50 dark:text-purple-400",shipped:"bg-sky-100 text-sky-700 dark:bg-sky-950/50 dark:text-sky-400",delivered:"bg-green-100 text-green-700 dark:bg-green-950/50 dark:text-green-400",cancelled:"bg-muted text-muted-foreground",returned:"bg-red-100 text-red-700 dark:bg-red-950/50 dark:text-red-400",unknown:"bg-muted text-muted-foreground"},xO={cafe24:"카페24",coupang:"쿠팡",smartstore:"스마트스토어",shopify:"Shopify","toss-shopping":"토스쇼핑","29cm":"29CM",musinsa:"무신사",kurly:"컬리",ssf:"SSF",bronte:"브론테",ezadmin:"이지어드민"};function bO({status:r}){return _.jsx("span",{className:Ae("inline-block text-[10px] font-medium px-1.5 py-0.5 rounded-full",yO[r]??yO.unknown),children:Jee[r]??r})}function ete(r){if(!r)return"-";try{return aee(see(r),"MM.dd HH:mm",{locale:F1})}catch{return r.slice(0,10)}}function _O({label:r,options:e,selected:t,onToggle:n,onClear:a,renderOption:i}){const[o,s]=q.useState(!1),l=q.useRef(null);return _.jsxs("div",{className:"relative",ref:l,children:[_.jsxs("button",{type:"button",onClick:()=>s(!o),className:Ae("flex items-center gap-1 text-[12px] px-2.5 py-1 rounded-md border cursor-pointer transition-colors",t.size>0?"border-primary/40 bg-primary/5 text-foreground":"border-border bg-card text-muted-foreground"),children:[r,t.size>0&&_.jsx("span",{className:"text-[10px] font-semibold bg-primary/10 text-primary px-1 rounded",children:t.size}),_.jsx(Sn,{size:12,className:Ae("transition-transform",o&&"rotate-180")})]}),o&&_.jsxs(_.Fragment,{children:[_.jsx("div",{className:"fixed inset-0 z-10",onClick:()=>s(!1)}),_.jsxs("div",{className:"absolute top-full left-0 mt-1 z-20 bg-card border border-border rounded-lg shadow-lg py-1 min-w-[160px]",children:[t.size>0&&_.jsxs("button",{type:"button",onClick:()=>{a(),s(!1)},className:"w-full text-left px-3 py-1.5 text-[11px] text-muted-foreground hover:bg-muted/50 flex items-center gap-1",children:[_.jsx(ml,{size:10})," 초기화"]}),e.map(u=>_.jsxs("label",{className:"flex items-center gap-2 px-3 py-1.5 text-[12px] hover:bg-muted/50 cursor-pointer",children:[_.jsx("input",{type:"checkbox",checked:t.has(u),onChange:()=>n(u),className:"rounded border-border"}),i?i(u):u]},u))]})]})]})}function tte({label:r,value:e,onChange:t}){return _.jsxs("div",{className:"relative",children:[_.jsx("input",{type:"text",placeholder:r,value:e,onChange:n=>t(n.target.value),className:Ae("text-[12px] px-2.5 py-1 rounded-md border bg-card w-[140px] outline-none transition-colors",e?"border-primary/40 text-foreground":"border-border text-muted-foreground placeholder:text-muted-foreground/60")}),e&&_.jsx("button",{type:"button",onClick:()=>t(""),className:"absolute right-1.5 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground",children:_.jsx(ml,{size:11})})]})}function rte(){const[r,e]=q.useState(""),[t,n]=q.useState(""),a=!!r||!!t,{data:i,isLoading:o,error:s}=wM(a?{from:r,to:t}:void 0),l=(i==null?void 0:i.orders)??[],{syncing:u,syncResult:c,handleSync:f}=UV(),[d,v]=q.useState(new Set),[g,y]=q.useState(Qee),[x,b]=q.useState(""),w=q.useMemo(()=>[...new Set(l.map(N=>N.channel))].sort(),[l]),T=q.useMemo(()=>[...new Set(l.map(N=>N.status))].sort(),[l]),C=q.useMemo(()=>l.filter(N=>!(d.size>0&&!d.has(N.channel)||g.size>0&&!g.has(N.status)||x&&!N.productName.toLowerCase().includes(x.toLowerCase()))),[l,d,g,x]),D=(N,R)=>{const E=new Set(N);return E.has(R)?E.delete(R):E.add(R),E},M=d.size>0||g.size>0||x;return _.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center justify-between mb-4",children:[_.jsx("h2",{className:"text-xl font-medium",children:"주문 현황"}),_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx("span",{className:"text-[12px] text-muted-foreground",children:M?`${C.length.toLocaleString()} / ${((i==null?void 0:i.total)??0).toLocaleString()}건`:`총 ${((i==null?void 0:i.total)??0).toLocaleString()}건`}),c&&_.jsx("span",{className:"text-[11px] text-muted-foreground",children:c}),_.jsxs("button",{type:"button",onClick:f,disabled:u,className:"flex items-center gap-1.5 text-[12px] text-muted-foreground hover:text-foreground border border-border rounded px-2.5 py-1 transition-colors disabled:opacity-50",children:[_.jsx(rG,{size:12,className:u?"animate-spin":""}),u?"동기화 중...":"주문 동기화"]})]})]}),_.jsx(FM,{from:r,to:t,onChange:(N,R)=>{e(N),n(R)},className:"mb-4"}),l.length>0&&_.jsxs("div",{className:"flex flex-wrap items-center gap-2 mb-4",children:[_.jsx(_O,{label:"채널",options:w,selected:d,onToggle:N=>v(D(d,N)),onClear:()=>v(new Set),renderOption:N=>_.jsx("span",{children:xO[N]??N})}),_.jsx(_O,{label:"상태",options:T,selected:g,onToggle:N=>y(D(g,N)),onClear:()=>y(new Set),renderOption:N=>_.jsx(bO,{status:N})}),_.jsx(tte,{label:"상품 검색",value:x,onChange:b}),M&&_.jsxs("button",{type:"button",onClick:()=>{v(new Set),y(new Set),b("")},className:"text-[11px] text-muted-foreground hover:text-foreground flex items-center gap-0.5 cursor-pointer",children:[_.jsx(ml,{size:11})," 전체 초기화"]})]}),o?_.jsx("div",{className:"text-sm text-muted-foreground py-8 text-center",children:"불러오는 중..."}):s?_.jsx("div",{className:"text-sm text-destructive py-8 text-center",children:"주문 조회 실패"}):l.length===0?_.jsxs("div",{className:"border border-dashed border-border rounded-lg p-12 text-center text-muted-foreground text-sm",children:["주문 데이터가 없습니다.",_.jsxs("div",{className:"text-[11px] mt-2 space-y-1",children:[_.jsxs("p",{children:["위의 ",_.jsx("strong",{children:"주문 동기화"})," 버튼을 눌러 연결된 채널에서 주문을 가져오거나,"]}),_.jsxs("p",{children:[_.jsx("code",{className:"bg-muted px-1 py-0.5 rounded text-[10px]",children:"sppt import"}),"로 CSV/엑셀 파일을 불러올 수 있습니다."]}),_.jsx("p",{className:"pt-1 text-muted-foreground/70",children:'터미널에서 AI에게 "주문 동기화해줘", "이 CSV 불러와줘" 라고 말해도 됩니다.'})]})]}):_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"채널"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"상품"}),_.jsx("th",{className:"px-3 py-2 text-left w-[90px]",children:"주문번호"}),_.jsx("th",{className:"px-3 py-2 text-center",children:"상태"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"금액"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"주문일"})]})}),_.jsxs("tbody",{className:"bg-card",children:[C.map((N,R)=>{const E=N.salePrice!=null?(N.salePrice*N.quantity).toLocaleString():null;return _.jsxs("tr",{className:Ae("border-b border-border/60",R%2!==0&&"bg-muted/5"),children:[_.jsx("td",{className:"px-3 py-2",children:xO[N.channel]??N.channel}),_.jsx("td",{className:"px-3 py-2 max-w-[280px] truncate",title:N.productName,children:N.productName}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground font-mono text-[10px] w-[90px] max-w-[90px] truncate",title:N.channelOrderId,children:N.channelOrderId}),_.jsx("td",{className:"px-3 py-2 text-center",children:_.jsx(bO,{status:N.status})}),_.jsx("td",{className:"px-3 py-2 text-right",children:E!=null?`${E}원`:"-"}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground text-right",children:ete(N.orderDate)})]},`${N.channelOrderId}-${R}`)}),C.length===0&&_.jsx("tr",{children:_.jsx("td",{colSpan:6,className:"px-3 py-8 text-center text-muted-foreground text-[13px]",children:"필터 조건에 맞는 주문이 없습니다."})})]})]})}),_.jsx("p",{className:"text-[11px] text-muted-foreground/60 mt-4",children:"주문 동기화 · CSV 불러오기 · 수동 입력 등 터미널에서 AI에게 요청할 수 있습니다."})]})}function Jr({label:r,value:e,sub:t,highlight:n,warn:a,accent:i,onClick:o}){const s=Ae("border border-border rounded-lg p-4 bg-card text-left w-full",n&&"border-primary/50 bg-primary/5",a&&"border-amber-500/50",o&&"cursor-pointer hover:border-primary/70 transition-colors"),l=Ae("text-2xl font-semibold",n&&"text-primary",a&&"text-amber-500",i&&"text-emerald-600 dark:text-emerald-400"),u=_.jsxs(_.Fragment,{children:[_.jsx("div",{className:"text-[11px] text-muted-foreground mb-1",children:r}),_.jsx("div",{className:l,children:e}),t&&_.jsx("div",{className:"text-[11px] text-muted-foreground mt-0.5",children:t})]});return o?_.jsx("button",{type:"button",className:s,onClick:o,children:u}):_.jsx("div",{className:s,children:u})}/*! *****************************************************************************
244
- Copyright (c) Microsoft Corporation.
245
-
246
- Permission to use, copy, modify, and/or distribute this software for any
247
- purpose with or without fee is hereby granted.
248
-
249
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
250
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
251
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
252
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
253
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
254
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
255
- PERFORMANCE OF THIS SOFTWARE.
256
- ***************************************************************************** */var iC=function(r,e){return iC=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])},iC(r,e)};function K(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");iC(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var Sp=function(){return Sp=Object.assign||function(e){for(var t,n=1,a=arguments.length;n<a;n++){t=arguments[n];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},Sp.apply(this,arguments)};function nte(r,e){var t={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(t[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(r);a<n.length;a++)e.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(r,n[a])&&(t[n[a]]=r[n[a]]);return t}function SO(r,e,t,n){function a(i){return i instanceof t?i:new t(function(o){o(i)})}return new(t||(t=Promise))(function(i,o){function s(c){try{u(n.next(c))}catch(f){o(f)}}function l(c){try{u(n.throw(c))}catch(f){o(f)}}function u(c){c.done?i(c.value):a(c.value).then(s,l)}u((n=n.apply(r,[])).next())})}function wO(r,e){var t={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,a,i,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(c){return l([u,c])}}function l(u){if(n)throw new TypeError("Generator is already executing.");for(;t;)try{if(n=1,a&&(i=u[0]&2?a.return:u[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,u[1])).done)return i;switch(a=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return t.label++,{value:u[1],done:!1};case 5:t.label++,a=u[1],u=[0];continue;case 7:u=t.ops.pop(),t.trys.pop();continue;default:if(i=t.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){t=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){t.label=u[1];break}if(u[0]===6&&t.label<i[1]){t.label=i[1],i=u;break}if(i&&t.label<i[2]){t.label=i[2],t.ops.push(u);break}i[2]&&t.ops.pop(),t.trys.pop();continue}u=e.call(r,t)}catch(c){u=[6,c],a=0}finally{n=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}var ate=(function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r})(),ite=(function(){function r(){this.browser=new ate,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"}return r})(),nt=new ite;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(nt.wxa=!0,nt.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?nt.worker=!0:!nt.hasGlobalWindow||"Deno"in window||typeof navigator<"u"&&typeof navigator.userAgent=="string"&&navigator.userAgent.indexOf("Node.js")>-1?(nt.node=!0,nt.svgSupported=!0):ote(navigator.userAgent,nt);function ote(r,e){var t=e.browser,n=r.match(/Firefox\/([\d.]+)/),a=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),i=r.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(r);n&&(t.firefox=!0,t.version=n[1]),a&&(t.ie=!0,t.version=a[1]),i&&(t.edge=!0,t.version=i[1],t.newEdge=+i[1].split(".")[0]>18),o&&(t.weChat=!0),e.svgSupported=typeof SVGRect<"u",e.touchEventsSupported="ontouchstart"in window&&!t.ie&&!t.edge,e.pointerEventsSupported="onpointerdown"in window&&(t.edge||t.ie&&+t.version>=11);var s=e.domSupported=typeof document<"u";if(s){var l=document.documentElement.style;e.transform3dSupported=(t.ie&&"transition"in l||t.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in l)&&!("OTransition"in l),e.transformSupported=e.transform3dSupported||t.ie&&+t.version>=9}}var YM=12,v6="sans-serif",qo=YM+"px "+v6,ste=20,lte=100,ute="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function cte(r){var e={};if(typeof JSON>"u")return e;for(var t=0;t<r.length;t++){var n=String.fromCharCode(t+32),a=(r.charCodeAt(t)-ste)/lte;e[n]=a}return e}var fte=cte(ute),Bn={createCanvas:function(){return typeof document<"u"&&document.createElement("canvas")},measureText:(function(){var r,e;return function(t,n){if(!r){var a=Bn.createCanvas();r=a&&a.getContext("2d")}if(r)return e!==n&&(e=r.font=n||qo),r.measureText(t);t=t||"",n=n||qo;var i=/((?:\d+)?\.?\d*)px/.exec(n),o=i&&+i[1]||YM,s=0;if(n.indexOf("mono")>=0)s=o*t.length;else for(var l=0;l<t.length;l++){var u=fte[t[l]];s+=u==null?o:u*o}return{width:s}}})(),loadImage:function(r,e,t){var n=new Image;return n.onload=e,n.onerror=t,n.src=r,n}};function p6(r){for(var e in Bn)r[e]&&(Bn[e]=r[e])}var g6=Ia(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(r,e){return r["[object "+e+"]"]=!0,r},{}),m6=Ia(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(r,e){return r["[object "+e+"Array]"]=!0,r},{}),Kh=Object.prototype.toString,U1=Array.prototype,hte=U1.forEach,dte=U1.filter,WM=U1.slice,vte=U1.map,TO=(function(){}).constructor,Ay=TO?TO.prototype:null,XM="__proto__",pte=2311;function qM(){return pte++}function Y1(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];typeof console<"u"&&console.error.apply(console,r)}function De(r){if(r==null||typeof r!="object")return r;var e=r,t=Kh.call(r);if(t==="[object Array]"){if(!uh(r)){e=[];for(var n=0,a=r.length;n<a;n++)e[n]=De(r[n])}}else if(m6[t]){if(!uh(r)){var i=r.constructor;if(i.from)e=i.from(r);else{e=new i(r.length);for(var n=0,a=r.length;n<a;n++)e[n]=r[n]}}}else if(!g6[t]&&!uh(r)&&!sc(r)){e={};for(var o in r)r.hasOwnProperty(o)&&o!==XM&&(e[o]=De(r[o]))}return e}function Ye(r,e,t){if(!Ee(e)||!Ee(r))return t?De(e):r;for(var n in e)if(e.hasOwnProperty(n)&&n!==XM){var a=r[n],i=e[n];Ee(i)&&Ee(a)&&!ce(i)&&!ce(a)&&!sc(i)&&!sc(a)&&!oC(i)&&!oC(a)&&!uh(i)&&!uh(a)?Ye(a,i,t):(t||!(n in r))&&(r[n]=De(e[n]))}return r}function W1(r,e){for(var t=r[0],n=1,a=r.length;n<a;n++)t=Ye(t,r[n],e);return t}function ie(r,e){if(Object.assign)Object.assign(r,e);else for(var t in e)e.hasOwnProperty(t)&&t!==XM&&(r[t]=e[t]);return r}function Re(r,e,t){for(var n=it(e),a=0,i=n.length;a<i;a++){var o=n[a];(t?e[o]!=null:r[o]==null)&&(r[o]=e[o])}return r}var gte=Bn.createCanvas;function Fe(r,e){if(r){if(r.indexOf)return r.indexOf(e);for(var t=0,n=r.length;t<n;t++)if(r[t]===e)return t}return-1}function ZM(r,e){var t=r.prototype;function n(){}n.prototype=e.prototype,r.prototype=new n;for(var a in t)t.hasOwnProperty(a)&&(r.prototype[a]=t[a]);r.prototype.constructor=r,r.superClass=e}function Jt(r,e,t){if(r="prototype"in r?r.prototype:r,e="prototype"in e?e.prototype:e,Object.getOwnPropertyNames)for(var n=Object.getOwnPropertyNames(e),a=0;a<n.length;a++){var i=n[a];i!=="constructor"&&(t?e[i]!=null:r[i]==null)&&(r[i]=e[i])}else Re(r,e,t)}function tn(r){return!r||typeof r=="string"?!1:typeof r.length=="number"}function O(r,e,t){if(r&&e)if(r.forEach&&r.forEach===hte)r.forEach(e,t);else if(r.length===+r.length)for(var n=0,a=r.length;n<a;n++)e.call(t,r[n],n,r);else for(var i in r)r.hasOwnProperty(i)&&e.call(t,r[i],i,r)}function fe(r,e,t){if(!r)return[];if(!e)return X1(r);if(r.map&&r.map===vte)return r.map(e,t);for(var n=[],a=0,i=r.length;a<i;a++)n.push(e.call(t,r[a],a,r));return n}function Ia(r,e,t,n){if(r&&e){for(var a=0,i=r.length;a<i;a++)t=e.call(n,t,r[a],a,r);return t}}function dt(r,e,t){if(!r)return[];if(!e)return X1(r);if(r.filter&&r.filter===dte)return r.filter(e,t);for(var n=[],a=0,i=r.length;a<i;a++)e.call(t,r[a],a,r)&&n.push(r[a]);return n}function Dl(r,e,t){if(r&&e){for(var n=0,a=r.length;n<a;n++)if(e.call(t,r[n],n,r))return r[n]}}function it(r){if(!r)return[];if(Object.keys)return Object.keys(r);var e=[];for(var t in r)r.hasOwnProperty(t)&&e.push(t);return e}function mte(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return function(){return r.apply(e,t.concat(WM.call(arguments)))}}var xe=Ay&&Me(Ay.bind)?Ay.call.bind(Ay.bind):mte;function He(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return function(){return r.apply(this,e.concat(WM.call(arguments)))}}function ce(r){return Array.isArray?Array.isArray(r):Kh.call(r)==="[object Array]"}function Me(r){return typeof r=="function"}function ye(r){return typeof r=="string"}function Sx(r){return Kh.call(r)==="[object String]"}function st(r){return typeof r=="number"}function Ee(r){var e=typeof r;return e==="function"||!!r&&e==="object"}function oC(r){return!!g6[Kh.call(r)]}function Tn(r){return!!m6[Kh.call(r)]}function sc(r){return typeof r=="object"&&typeof r.nodeType=="number"&&typeof r.ownerDocument=="object"}function zg(r){return r.colorStops!=null}function y6(r){return r.image!=null}function x6(r){return Kh.call(r)==="[object RegExp]"}function en(r){return r!==r}function Fr(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];for(var t=0,n=r.length;t<n;t++)if(r[t]!=null)return r[t]}function Ce(r,e){return r??e}function zn(r,e,t){return r??e??t}function X1(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return WM.apply(r,e)}function Bg(r){if(typeof r=="number")return[r,r,r,r];var e=r.length;return e===2?[r[0],r[1],r[0],r[1]]:e===3?[r[0],r[1],r[2],r[1]]:r}function rn(r,e){if(!r)throw new Error(e)}function ra(r){return r==null?null:typeof r.trim=="function"?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var b6="__ec_primitive__";function Xp(r){r[b6]=!0}function uh(r){return r[b6]}var yte=(function(){function r(){this.data={}}return r.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},r.prototype.has=function(e){return this.data.hasOwnProperty(e)},r.prototype.get=function(e){return this.data[e]},r.prototype.set=function(e,t){return this.data[e]=t,this},r.prototype.keys=function(){return it(this.data)},r.prototype.forEach=function(e){var t=this.data;for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)},r})(),_6=typeof Map=="function";function xte(){return _6?new Map:new yte}var S6=(function(){function r(e){var t=ce(e);this.data=xte();var n=this;e instanceof r?e.each(a):e&&O(e,a);function a(i,o){t?n.set(i,o):n.set(o,i)}}return r.prototype.hasKey=function(e){return this.data.has(e)},r.prototype.get=function(e){return this.data.get(e)},r.prototype.set=function(e,t){return this.data.set(e,t),t},r.prototype.each=function(e,t){this.data.forEach(function(n,a){e.call(t,n,a)})},r.prototype.keys=function(){var e=this.data.keys();return _6?Array.from(e):e},r.prototype.removeKey=function(e){this.data.delete(e)},r})();function Te(r){return new S6(r)}function Lh(r,e){for(var t=new r.constructor(r.length+e.length),n=0;n<r.length;n++)t[n]=r[n];for(var a=r.length,n=0;n<e.length;n++)t[n+a]=e[n];return t}function Vg(r,e){var t;if(Object.create)t=Object.create(r);else{var n=function(){};n.prototype=r,t=new n}return e&&ie(t,e),t}function $M(r){var e=r.style;e.webkitUserSelect="none",e.userSelect="none",e.webkitTapHighlightColor="rgba(0,0,0,0)",e["-webkit-touch-callout"]="none"}function _e(r,e){return r.hasOwnProperty(e)}function Kt(){}var wp=180/Math.PI,bte=Number.EPSILON||Math.pow(2,-52);const _te=Object.freeze(Object.defineProperty({__proto__:null,EPSILON:bte,HashMap:S6,RADIAN_TO_DEGREE:wp,assert:rn,bind:xe,clone:De,concatArray:Lh,createCanvas:gte,createHashMap:Te,createObject:Vg,curry:He,defaults:Re,disableUserSelect:$M,each:O,eqNaN:en,extend:ie,filter:dt,find:Dl,guid:qM,hasOwn:_e,indexOf:Fe,inherits:ZM,isArray:ce,isArrayLike:tn,isBuiltInObject:oC,isDom:sc,isFunction:Me,isGradientObject:zg,isImagePatternObject:y6,isNumber:st,isObject:Ee,isPrimitive:uh,isRegExp:x6,isString:ye,isStringSafe:Sx,isTypedArray:Tn,keys:it,logError:Y1,map:fe,merge:Ye,mergeAll:W1,mixin:Jt,noop:Kt,normalizeCssArray:Bg,reduce:Ia,retrieve:Fr,retrieve2:Ce,retrieve3:zn,setAsPrimitive:Xp,slice:X1,trim:ra},Symbol.toStringTag,{value:"Module"}));function Nl(r,e){return r==null&&(r=0),e==null&&(e=0),[r,e]}function fn(r,e){return r[0]=e[0],r[1]=e[1],r}function Hi(r){return[r[0],r[1]]}function q1(r,e,t){return r[0]=e,r[1]=t,r}function sC(r,e,t){return r[0]=e[0]+t[0],r[1]=e[1]+t[1],r}function Tx(r,e,t,n){return r[0]=e[0]+t[0]*n,r[1]=e[1]+t[1]*n,r}function el(r,e,t){return r[0]=e[0]-t[0],r[1]=e[1]-t[1],r}function qp(r){return Math.sqrt(KM(r))}var Ste=qp;function KM(r){return r[0]*r[0]+r[1]*r[1]}var wte=KM;function Tte(r,e,t){return r[0]=e[0]*t[0],r[1]=e[1]*t[1],r}function Cte(r,e,t){return r[0]=e[0]/t[0],r[1]=e[1]/t[1],r}function Ate(r,e){return r[0]*e[0]+r[1]*e[1]}function Tp(r,e,t){return r[0]=e[0]*t,r[1]=e[1]*t,r}function xc(r,e){var t=qp(e);return t===0?(r[0]=0,r[1]=0):(r[0]=e[0]/t,r[1]=e[1]/t),r}function Cx(r,e){return Math.sqrt((r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1]))}var Io=Cx;function w6(r,e){return(r[0]-e[0])*(r[0]-e[0])+(r[1]-e[1])*(r[1]-e[1])}var ul=w6;function Mte(r,e){return r[0]=-e[0],r[1]=-e[1],r}function Cp(r,e,t,n){return r[0]=e[0]+n*(t[0]-e[0]),r[1]=e[1]+n*(t[1]-e[1]),r}function Qt(r,e,t){var n=e[0],a=e[1];return r[0]=t[0]*n+t[2]*a+t[4],r[1]=t[1]*n+t[3]*a+t[5],r}function Oo(r,e,t){return r[0]=Math.min(e[0],t[0]),r[1]=Math.min(e[1],t[1]),r}function Po(r,e,t){return r[0]=Math.max(e[0],t[0]),r[1]=Math.max(e[1],t[1]),r}const Dte=Object.freeze(Object.defineProperty({__proto__:null,add:sC,applyTransform:Qt,clone:Hi,copy:fn,create:Nl,dist:Io,distSquare:ul,distance:Cx,distanceSquare:w6,div:Cte,dot:Ate,len:qp,lenSquare:KM,length:Ste,lengthSquare:wte,lerp:Cp,max:Po,min:Oo,mul:Tte,negate:Mte,normalize:xc,scale:Tp,scaleAndAdd:Tx,set:q1,sub:el},Symbol.toStringTag,{value:"Module"}));var gf=(function(){function r(e,t){this.target=e,this.topTarget=t&&t.topTarget}return r})(),Nte=(function(){function r(e){this.handler=e,e.on("mousedown",this._dragStart,this),e.on("mousemove",this._drag,this),e.on("mouseup",this._dragEnd,this)}return r.prototype._dragStart=function(e){for(var t=e.target;t&&!t.draggable;)t=t.parent||t.__hostTarget;t&&(this._draggingTarget=t,t.dragging=!0,this._x=e.offsetX,this._y=e.offsetY,this.handler.dispatchToElement(new gf(t,e),"dragstart",e.event))},r.prototype._drag=function(e){var t=this._draggingTarget;if(t){var n=e.offsetX,a=e.offsetY,i=n-this._x,o=a-this._y;this._x=n,this._y=a,t.drift(i,o,e),this.handler.dispatchToElement(new gf(t,e),"drag",e.event);var s=this.handler.findHover(n,a,t).target,l=this._dropTarget;this._dropTarget=s,t!==s&&(l&&s!==l&&this.handler.dispatchToElement(new gf(l,e),"dragleave",e.event),s&&s!==l&&this.handler.dispatchToElement(new gf(s,e),"dragenter",e.event))}},r.prototype._dragEnd=function(e){var t=this._draggingTarget;t&&(t.dragging=!1),this.handler.dispatchToElement(new gf(t,e),"dragend",e.event),this._dropTarget&&this.handler.dispatchToElement(new gf(this._dropTarget,e),"drop",e.event),this._draggingTarget=null,this._dropTarget=null},r})(),za=(function(){function r(e){e&&(this._$eventProcessor=e)}return r.prototype.on=function(e,t,n,a){this._$handlers||(this._$handlers={});var i=this._$handlers;if(typeof t=="function"&&(a=n,n=t,t=null),!n||!e)return this;var o=this._$eventProcessor;t!=null&&o&&o.normalizeQuery&&(t=o.normalizeQuery(t)),i[e]||(i[e]=[]);for(var s=0;s<i[e].length;s++)if(i[e][s].h===n)return this;var l={h:n,query:t,ctx:a||this,callAtLast:n.zrEventfulCallAtLast},u=i[e].length-1,c=i[e][u];return c&&c.callAtLast?i[e].splice(u,0,l):i[e].push(l),this},r.prototype.isSilent=function(e){var t=this._$handlers;return!t||!t[e]||!t[e].length},r.prototype.off=function(e,t){var n=this._$handlers;if(!n)return this;if(!e)return this._$handlers={},this;if(t){if(n[e]){for(var a=[],i=0,o=n[e].length;i<o;i++)n[e][i].h!==t&&a.push(n[e][i]);n[e]=a}n[e]&&n[e].length===0&&delete n[e]}else delete n[e];return this},r.prototype.trigger=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];if(!this._$handlers)return this;var a=this._$handlers[e],i=this._$eventProcessor;if(a)for(var o=t.length,s=a.length,l=0;l<s;l++){var u=a[l];if(!(i&&i.filter&&u.query!=null&&!i.filter(e,u.query)))switch(o){case 0:u.h.call(u.ctx);break;case 1:u.h.call(u.ctx,t[0]);break;case 2:u.h.call(u.ctx,t[0],t[1]);break;default:u.h.apply(u.ctx,t);break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r.prototype.triggerWithContext=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];if(!this._$handlers)return this;var a=this._$handlers[e],i=this._$eventProcessor;if(a)for(var o=t.length,s=t[o-1],l=a.length,u=0;u<l;u++){var c=a[u];if(!(i&&i.filter&&c.query!=null&&!i.filter(e,c.query)))switch(o){case 0:c.h.call(s);break;case 1:c.h.call(s,t[0]);break;case 2:c.h.call(s,t[0],t[1]);break;default:c.h.apply(s,t.slice(1,o-1));break}}return i&&i.afterTrigger&&i.afterTrigger(e),this},r})(),Lte=Math.log(2);function lC(r,e,t,n,a,i){var o=n+"-"+a,s=r.length;if(i.hasOwnProperty(o))return i[o];if(e===1){var l=Math.round(Math.log((1<<s)-1&~a)/Lte);return r[t][l]}for(var u=n|1<<t,c=t+1;n&1<<c;)c++;for(var f=0,d=0,v=0;d<s;d++){var g=1<<d;g&a||(f+=(v%2?-1:1)*r[t][d]*lC(r,e-1,c,u,a|g,i),v++)}return i[o]=f,f}function CO(r,e){var t=[[r[0],r[1],1,0,0,0,-e[0]*r[0],-e[0]*r[1]],[0,0,0,r[0],r[1],1,-e[1]*r[0],-e[1]*r[1]],[r[2],r[3],1,0,0,0,-e[2]*r[2],-e[2]*r[3]],[0,0,0,r[2],r[3],1,-e[3]*r[2],-e[3]*r[3]],[r[4],r[5],1,0,0,0,-e[4]*r[4],-e[4]*r[5]],[0,0,0,r[4],r[5],1,-e[5]*r[4],-e[5]*r[5]],[r[6],r[7],1,0,0,0,-e[6]*r[6],-e[6]*r[7]],[0,0,0,r[6],r[7],1,-e[7]*r[6],-e[7]*r[7]]],n={},a=lC(t,8,0,0,0,n);if(a!==0){for(var i=[],o=0;o<8;o++)for(var s=0;s<8;s++)i[s]==null&&(i[s]=0),i[s]+=((o+s)%2?-1:1)*lC(t,7,o===0?1:0,1<<o,1<<s,n)/a*e[o];return function(l,u,c){var f=u*i[6]+c*i[7]+1;l[0]=(u*i[0]+c*i[1]+i[2])/f,l[1]=(u*i[3]+c*i[4]+i[5])/f}}}var Ax="___zrEVENTSAVED",tw=[];function Rte(r,e,t,n,a){return uC(tw,e,n,a,!0)&&uC(r,t,tw[0],tw[1])}function Ete(r,e){r&&t(r),e&&t(e);function t(n){var a=n[Ax];a&&(a.clearMarkers&&a.clearMarkers(),delete n[Ax])}}function uC(r,e,t,n,a){if(e.getBoundingClientRect&&nt.domSupported&&!T6(e)){var i=e[Ax]||(e[Ax]={}),o=kte(e,i),s=Ite(o,i,a);if(s)return s(r,t,n),!0}return!1}function kte(r,e){var t=e.markers;if(t)return t;t=e.markers=[];for(var n=["left","right"],a=["top","bottom"],i=0;i<4;i++){var o=document.createElement("div"),s=o.style,l=i%2,u=(i>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",n[l]+":0",a[u]+":0",n[1-l]+":auto",a[1-u]+":auto",""].join("!important;"),r.appendChild(o),t.push(o)}return e.clearMarkers=function(){O(t,function(c){c.parentNode&&c.parentNode.removeChild(c)})},t}function Ite(r,e,t){for(var n=t?"invTrans":"trans",a=e[n],i=e.srcCoords,o=[],s=[],l=!0,u=0;u<4;u++){var c=r[u].getBoundingClientRect(),f=2*u,d=c.left,v=c.top;o.push(d,v),l=l&&i&&d===i[f]&&v===i[f+1],s.push(r[u].offsetLeft,r[u].offsetTop)}return l&&a?a:(e.srcCoords=o,e[n]=t?CO(s,o):CO(o,s))}function T6(r){return r.nodeName.toUpperCase()==="CANVAS"}var Ote=/([&<>"'])/g,Pte={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function dn(r){return r==null?"":(r+"").replace(Ote,function(e,t){return Pte[t]})}var jte=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,rw=[],zte=nt.browser.firefox&&+nt.browser.version.split(".")[0]<39;function cC(r,e,t,n){return t=t||{},n?AO(r,e,t):zte&&e.layerX!=null&&e.layerX!==e.offsetX?(t.zrX=e.layerX,t.zrY=e.layerY):e.offsetX!=null?(t.zrX=e.offsetX,t.zrY=e.offsetY):AO(r,e,t),t}function AO(r,e,t){if(nt.domSupported&&r.getBoundingClientRect){var n=e.clientX,a=e.clientY;if(T6(r)){var i=r.getBoundingClientRect();t.zrX=n-i.left,t.zrY=a-i.top;return}else if(uC(rw,r,n,a)){t.zrX=rw[0],t.zrY=rw[1];return}}t.zrX=t.zrY=0}function QM(r){return r||window.event}function wa(r,e,t){if(e=QM(e),e.zrX!=null)return e;var n=e.type,a=n&&n.indexOf("touch")>=0;if(a){var o=n!=="touchend"?e.targetTouches[0]:e.changedTouches[0];o&&cC(r,o,e,t)}else{cC(r,e,e,t);var i=Bte(e);e.zrDelta=i?i/120:-(e.detail||0)/3}var s=e.button;return e.which==null&&s!==void 0&&jte.test(e.type)&&(e.which=s&1?1:s&2?3:s&4?2:0),e}function Bte(r){var e=r.wheelDelta;if(e)return e;var t=r.deltaX,n=r.deltaY;if(t==null||n==null)return e;var a=Math.abs(n!==0?n:t),i=n>0?-1:n<0?1:t>0?-1:1;return 3*a*i}function fC(r,e,t,n){r.addEventListener(e,t,n)}function Vte(r,e,t,n){r.removeEventListener(e,t,n)}var Zo=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function MO(r){return r.which===2||r.which===3}var Gte=(function(){function r(){this._track=[]}return r.prototype.recognize=function(e,t,n){return this._doTrack(e,t,n),this._recognize(e)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(e,t,n){var a=e.touches;if(a){for(var i={points:[],touches:[],target:t,event:e},o=0,s=a.length;o<s;o++){var l=a[o],u=cC(n,l,{});i.points.push([u.zrX,u.zrY]),i.touches.push(l)}this._track.push(i)}},r.prototype._recognize=function(e){for(var t in nw)if(nw.hasOwnProperty(t)){var n=nw[t](this._track,e);if(n)return n}},r})();function DO(r){var e=r[1][0]-r[0][0],t=r[1][1]-r[0][1];return Math.sqrt(e*e+t*t)}function Hte(r){return[(r[0][0]+r[1][0])/2,(r[0][1]+r[1][1])/2]}var nw={pinch:function(r,e){var t=r.length;if(t){var n=(r[t-1]||{}).points,a=(r[t-2]||{}).points||n;if(a&&a.length>1&&n&&n.length>1){var i=DO(n)/DO(a);!isFinite(i)&&(i=1),e.pinchScale=i;var o=Hte(n);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:r[0].target,event:e}}}}};function Rr(){return[1,0,0,1,0,0]}function Gg(r){return r[0]=1,r[1]=0,r[2]=0,r[3]=1,r[4]=0,r[5]=0,r}function Hg(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4],r[5]=e[5],r}function Ja(r,e,t){var n=e[0]*t[0]+e[2]*t[1],a=e[1]*t[0]+e[3]*t[1],i=e[0]*t[2]+e[2]*t[3],o=e[1]*t[2]+e[3]*t[3],s=e[0]*t[4]+e[2]*t[5]+e[4],l=e[1]*t[4]+e[3]*t[5]+e[5];return r[0]=n,r[1]=a,r[2]=i,r[3]=o,r[4]=s,r[5]=l,r}function ii(r,e,t){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4]+t[0],r[5]=e[5]+t[1],r}function ns(r,e,t,n){n===void 0&&(n=[0,0]);var a=e[0],i=e[2],o=e[4],s=e[1],l=e[3],u=e[5],c=Math.sin(t),f=Math.cos(t);return r[0]=a*f+s*c,r[1]=-a*c+s*f,r[2]=i*f+l*c,r[3]=-i*c+f*l,r[4]=f*(o-n[0])+c*(u-n[1])+n[0],r[5]=f*(u-n[1])-c*(o-n[0])+n[1],r}function Z1(r,e,t){var n=t[0],a=t[1];return r[0]=e[0]*n,r[1]=e[1]*a,r[2]=e[2]*n,r[3]=e[3]*a,r[4]=e[4]*n,r[5]=e[5]*a,r}function Oa(r,e){var t=e[0],n=e[2],a=e[4],i=e[1],o=e[3],s=e[5],l=t*o-i*n;return l?(l=1/l,r[0]=o*l,r[1]=-i*l,r[2]=-n*l,r[3]=t*l,r[4]=(n*s-o*a)*l,r[5]=(i*a-t*s)*l,r):null}function C6(r){var e=Rr();return Hg(e,r),e}const Fte=Object.freeze(Object.defineProperty({__proto__:null,clone:C6,copy:Hg,create:Rr,identity:Gg,invert:Oa,mul:Ja,rotate:ns,scale:Z1,translate:ii},Symbol.toStringTag,{value:"Module"}));var Ie=(function(){function r(e,t){this.x=e||0,this.y=t||0}return r.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},r.prototype.clone=function(){return new r(this.x,this.y)},r.prototype.set=function(e,t){return this.x=e,this.y=t,this},r.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},r.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},r.prototype.scale=function(e){this.x*=e,this.y*=e},r.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},r.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},r.prototype.dot=function(e){return this.x*e.x+this.y*e.y},r.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},r.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},r.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},r.prototype.distance=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},r.prototype.distanceSquare=function(e){var t=this.x-e.x,n=this.y-e.y;return t*t+n*n},r.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},r.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}},r.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},r.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},r.set=function(e,t,n){e.x=t,e.y=n},r.copy=function(e,t){e.x=t.x,e.y=t.y},r.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},r.lenSquare=function(e){return e.x*e.x+e.y*e.y},r.dot=function(e,t){return e.x*t.x+e.y*t.y},r.add=function(e,t,n){e.x=t.x+n.x,e.y=t.y+n.y},r.sub=function(e,t,n){e.x=t.x-n.x,e.y=t.y-n.y},r.scale=function(e,t,n){e.x=t.x*n,e.y=t.y*n},r.scaleAndAdd=function(e,t,n,a){e.x=t.x+n.x*a,e.y=t.y+n.y*a},r.lerp=function(e,t,n,a){var i=1-a;e.x=i*t.x+a*n.x,e.y=i*t.y+a*n.y},r})(),ju=Math.min,Qf=Math.max,hC=Math.abs,NO=["x","y"],Ute=["width","height"],Jl=new Ie,eu=new Ie,tu=new Ie,ru=new Ie,Qn=A6(),lp=Qn.minTv,dC=Qn.maxTv,Ap=[0,0],Oe=(function(){function r(e,t,n,a){r.set(this,e,t,n,a)}return r.set=function(e,t,n,a,i){return a<0&&(t=t+a,a=-a),i<0&&(n=n+i,i=-i),e.x=t,e.y=n,e.width=a,e.height=i,e},r.prototype.union=function(e){var t=ju(e.x,this.x),n=ju(e.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=Qf(e.x+e.width,this.x+this.width)-t:this.width=e.width,isFinite(this.y)&&isFinite(this.height)?this.height=Qf(e.y+e.height,this.y+this.height)-n:this.height=e.height,this.x=t,this.y=n},r.prototype.applyTransform=function(e){r.applyTransform(this,this,e)},r.prototype.calculateTransform=function(e){var t=this,n=e.width/t.width,a=e.height/t.height,i=Rr();return ii(i,i,[-t.x,-t.y]),Z1(i,i,[n,a]),ii(i,i,[e.x,e.y]),i},r.prototype.intersect=function(e,t,n){return r.intersect(this,e,t,n)},r.intersect=function(e,t,n,a){n&&Ie.set(n,0,0);var i=a&&a.outIntersectRect||null,o=a&&a.clamp;if(i&&(i.x=i.y=i.width=i.height=NaN),!e||!t)return!1;e instanceof r||(e=r.set(Yte,e.x,e.y,e.width,e.height)),t instanceof r||(t=r.set(Wte,t.x,t.y,t.width,t.height));var s=!!n;Qn.reset(a,s);var l=Qn.touchThreshold,u=e.x+l,c=e.x+e.width-l,f=e.y+l,d=e.y+e.height-l,v=t.x+l,g=t.x+t.width-l,y=t.y+l,x=t.y+t.height-l;if(u>c||f>d||v>g||y>x)return!1;var b=!(c<v||g<u||d<y||x<f);return(s||i)&&(Ap[0]=1/0,Ap[1]=0,LO(u,c,v,g,0,s,i,o),LO(f,d,y,x,1,s,i,o),s&&Ie.copy(n,b?Qn.useDir?Qn.dirMinTv:lp:dC)),b},r.contain=function(e,t,n){return t>=e.x&&t<=e.x+e.width&&n>=e.y&&n<=e.y+e.height},r.prototype.contain=function(e,t){return r.contain(this,e,t)},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.copy=function(e){r.copy(this,e)},r.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},r.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},r.prototype.isZero=function(){return this.width===0||this.height===0},r.create=function(e){return new r(e.x,e.y,e.width,e.height)},r.copy=function(e,t){return e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height,e},r.applyTransform=function(e,t,n){if(!n){e!==t&&r.copy(e,t);return}if(n[1]<1e-5&&n[1]>-1e-5&&n[2]<1e-5&&n[2]>-1e-5){var a=n[0],i=n[3],o=n[4],s=n[5];e.x=t.x*a+o,e.y=t.y*i+s,e.width=t.width*a,e.height=t.height*i,e.width<0&&(e.x+=e.width,e.width=-e.width),e.height<0&&(e.y+=e.height,e.height=-e.height);return}Jl.x=tu.x=t.x,Jl.y=ru.y=t.y,eu.x=ru.x=t.x+t.width,eu.y=tu.y=t.y+t.height,Jl.transform(n),ru.transform(n),eu.transform(n),tu.transform(n),e.x=ju(Jl.x,eu.x,tu.x,ru.x),e.y=ju(Jl.y,eu.y,tu.y,ru.y);var l=Qf(Jl.x,eu.x,tu.x,ru.x),u=Qf(Jl.y,eu.y,tu.y,ru.y);e.width=l-e.x,e.height=u-e.y},r})(),Yte=new Oe(0,0,0,0),Wte=new Oe(0,0,0,0);function LO(r,e,t,n,a,i,o,s){var l=hC(e-t),u=hC(n-r),c=ju(l,u),f=NO[a],d=NO[1-a],v=Ute[a];e<t||n<r?l<u?(i&&(dC[f]=-l),s&&(o[f]=e,o[v]=0)):(i&&(dC[f]=u),s&&(o[f]=r,o[v]=0)):(o&&(o[f]=Qf(r,t),o[v]=ju(e,n)-o[f]),i&&(c<Ap[0]||Qn.useDir)&&(Ap[0]=ju(c,Ap[0]),(l<u||!Qn.bidirectional)&&(lp[f]=l,lp[d]=0,Qn.useDir&&Qn.calcDirMTV()),(l>=u||!Qn.bidirectional)&&(lp[f]=-u,lp[d]=0,Qn.useDir&&Qn.calcDirMTV())))}function A6(){var r=0,e=new Ie,t=new Ie,n={minTv:new Ie,maxTv:new Ie,useDir:!1,dirMinTv:new Ie,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(i,o){n.touchThreshold=0,i&&i.touchThreshold!=null&&(n.touchThreshold=Qf(0,i.touchThreshold)),n.negativeSize=!1,o&&(n.minTv.set(1/0,1/0),n.maxTv.set(0,0),n.useDir=!1,i&&i.direction!=null&&(n.useDir=!0,n.dirMinTv.copy(n.minTv),t.copy(n.minTv),r=i.direction,n.bidirectional=i.bidirectional==null||!!i.bidirectional,n.bidirectional||e.set(Math.cos(r),Math.sin(r))))},calcDirMTV:function(){var i=n.minTv,o=n.dirMinTv,s=i.y*i.y+i.x*i.x,l=Math.sin(r),u=Math.cos(r),c=l*i.y+u*i.x;if(a(c)){a(i.x)&&a(i.y)&&o.set(0,0);return}if(t.x=s*u/c,t.y=s*l/c,a(t.x)&&a(t.y)){o.set(0,0);return}(n.bidirectional||e.dot(t)>0)&&t.len()<o.len()&&o.copy(t)}};function a(i){return hC(i)<1e-10}return n}var M6="silent";function Xte(r,e,t){return{type:r,event:t,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:t.zrX,offsetY:t.zrY,gestureEvent:t.gestureEvent,pinchX:t.pinchX,pinchY:t.pinchY,pinchScale:t.pinchScale,wheelDelta:t.zrDelta,zrByTouch:t.zrByTouch,which:t.which,stop:qte}}function qte(){Zo(this.event)}var Zte=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.handler=null,t}return e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e})(za),Sv=(function(){function r(e,t){this.x=e,this.y=t}return r})(),$te=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],aw=new Oe(0,0,0,0),D6=(function(r){K(e,r);function e(t,n,a,i,o){var s=r.call(this)||this;return s._hovered=new Sv(0,0),s.storage=t,s.painter=n,s.painterRoot=i,s._pointerSize=o,a=a||new Zte,s.proxy=null,s.setHandlerProxy(a),s._draggingMgr=new Nte(s),s}return e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(O($te,function(n){t.on&&t.on(n,this[n],this)},this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var n=t.zrX,a=t.zrY,i=N6(this,n,a),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var l=this._hovered=i?new Sv(n,a):this.findHover(n,a),u=l.target,c=this.proxy;c.setCursor&&c.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(o,"mouseout",t),this.dispatchToElement(l,"mousemove",t),u&&u!==s&&this.dispatchToElement(l,"mouseover",t)},e.prototype.mouseout=function(t){var n=t.zrEventControl;n!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",t),n!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new Sv(0,0)},e.prototype.dispatch=function(t,n){var a=this[t];a&&a.call(this,n)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var n=this.proxy;n.setCursor&&n.setCursor(t)},e.prototype.dispatchToElement=function(t,n,a){t=t||{};var i=t.target;if(!(i&&i.silent)){for(var o="on"+n,s=Xte(n,t,a);i&&(i[o]&&(s.cancelBubble=!!i[o].call(i,s)),i.trigger(n,s),i=i.__hostTarget?i.__hostTarget:i.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(n,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[o]=="function"&&l[o].call(l,s),l.trigger&&l.trigger(n,s)}))}},e.prototype.findHover=function(t,n,a){var i=this.storage.getDisplayList(),o=new Sv(t,n);if(RO(i,o,t,n,a),this._pointerSize&&!o.target){for(var s=[],l=this._pointerSize,u=l/2,c=new Oe(t-u,n-u,l,l),f=i.length-1;f>=0;f--){var d=i[f];d!==a&&!d.ignore&&!d.ignoreCoarsePointer&&(!d.parent||!d.parent.ignoreCoarsePointer)&&(aw.copy(d.getBoundingRect()),d.transform&&aw.applyTransform(d.transform),aw.intersect(c)&&s.push(d))}if(s.length)for(var v=4,g=Math.PI/12,y=Math.PI*2,x=0;x<u;x+=v)for(var b=0;b<y;b+=g){var w=t+x*Math.cos(b),T=n+x*Math.sin(b);if(RO(s,o,w,T,a),o.target)return o}}return o},e.prototype.processGesture=function(t,n){this._gestureMgr||(this._gestureMgr=new Gte);var a=this._gestureMgr;n==="start"&&a.clear();var i=a.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if(n==="end"&&a.clear(),i){var o=i.type;t.gestureEvent=o;var s=new Sv;s.target=i.target,this.dispatchToElement(s,o,i.event)}},e})(za);O(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(r){D6.prototype[r]=function(e){var t=e.zrX,n=e.zrY,a=N6(this,t,n),i,o;if((r!=="mouseup"||!a)&&(i=this.findHover(t,n),o=i.target),r==="mousedown")this._downEl=o,this._downPoint=[e.zrX,e.zrY],this._upEl=o;else if(r==="mouseup")this._upEl=o;else if(r==="click"){if(this._downEl!==this._upEl||!this._downPoint||Io(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(i,r,e)}});function Kte(r,e,t){if(r[r.rectHover?"rectContain":"contain"](e,t)){for(var n=r,a=void 0,i=!1;n;){if(n.ignoreClip&&(i=!0),!i){var o=n.getClipPath();if(o&&!o.contain(e,t))return!1}n.silent&&(a=!0);var s=n.__hostTarget;n=s?n.ignoreHostSilent?null:s:n.parent}return a?M6:!0}return!1}function RO(r,e,t,n,a){for(var i=r.length-1;i>=0;i--){var o=r[i],s=void 0;if(o!==a&&!o.ignore&&(s=Kte(o,t,n))&&(!e.topTarget&&(e.topTarget=o),s!==M6)){e.target=o;break}}}function N6(r,e,t){var n=r.painter;return e<0||e>n.getWidth()||t<0||t>n.getHeight()}var L6=32,wv=7;function Qte(r){for(var e=0;r>=L6;)e|=r&1,r>>=1;return r+e}function EO(r,e,t,n){var a=e+1;if(a===t)return 1;if(n(r[a++],r[e])<0){for(;a<t&&n(r[a],r[a-1])<0;)a++;Jte(r,e,a)}else for(;a<t&&n(r[a],r[a-1])>=0;)a++;return a-e}function Jte(r,e,t){for(t--;e<t;){var n=r[e];r[e++]=r[t],r[t--]=n}}function kO(r,e,t,n,a){for(n===e&&n++;n<t;n++){for(var i=r[n],o=e,s=n,l;o<s;)l=o+s>>>1,a(i,r[l])<0?s=l:o=l+1;var u=n-o;switch(u){case 3:r[o+3]=r[o+2];case 2:r[o+2]=r[o+1];case 1:r[o+1]=r[o];break;default:for(;u>0;)r[o+u]=r[o+u-1],u--}r[o]=i}}function iw(r,e,t,n,a,i){var o=0,s=0,l=1;if(i(r,e[t+a])>0){for(s=n-a;l<s&&i(r,e[t+a+l])>0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=a,l+=a}else{for(s=a+1;l<s&&i(r,e[t+a-l])<=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=a-l,l=a-u}for(o++;o<l;){var c=o+(l-o>>>1);i(r,e[t+c])>0?o=c+1:l=c}return l}function ow(r,e,t,n,a,i){var o=0,s=0,l=1;if(i(r,e[t+a])<0){for(s=a+1;l<s&&i(r,e[t+a-l])<0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=a-l,l=a-u}else{for(s=n-a;l<s&&i(r,e[t+a+l])>=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=a,l+=a}for(o++;o<l;){var c=o+(l-o>>>1);i(r,e[t+c])<0?l=c:o=c+1}return l}function ere(r,e){var t=wv,n,a,i=0,o=[];n=[],a=[];function s(v,g){n[i]=v,a[i]=g,i+=1}function l(){for(;i>1;){var v=i-2;if(v>=1&&a[v-1]<=a[v]+a[v+1]||v>=2&&a[v-2]<=a[v]+a[v-1])a[v-1]<a[v+1]&&v--;else if(a[v]>a[v+1])break;c(v)}}function u(){for(;i>1;){var v=i-2;v>0&&a[v-1]<a[v+1]&&v--,c(v)}}function c(v){var g=n[v],y=a[v],x=n[v+1],b=a[v+1];a[v]=y+b,v===i-3&&(n[v+1]=n[v+2],a[v+1]=a[v+2]),i--;var w=ow(r[x],r,g,y,0,e);g+=w,y-=w,y!==0&&(b=iw(r[g+y-1],r,x,b,b-1,e),b!==0&&(y<=b?f(g,y,x,b):d(g,y,x,b)))}function f(v,g,y,x){var b=0;for(b=0;b<g;b++)o[b]=r[v+b];var w=0,T=y,C=v;if(r[C++]=r[T++],--x===0){for(b=0;b<g;b++)r[C+b]=o[w+b];return}if(g===1){for(b=0;b<x;b++)r[C+b]=r[T+b];r[C+x]=o[w];return}for(var D=t,M,N,R;;){M=0,N=0,R=!1;do if(e(r[T],o[w])<0){if(r[C++]=r[T++],N++,M=0,--x===0){R=!0;break}}else if(r[C++]=o[w++],M++,N=0,--g===1){R=!0;break}while((M|N)<D);if(R)break;do{if(M=ow(r[T],o,w,g,0,e),M!==0){for(b=0;b<M;b++)r[C+b]=o[w+b];if(C+=M,w+=M,g-=M,g<=1){R=!0;break}}if(r[C++]=r[T++],--x===0){R=!0;break}if(N=iw(o[w],r,T,x,0,e),N!==0){for(b=0;b<N;b++)r[C+b]=r[T+b];if(C+=N,T+=N,x-=N,x===0){R=!0;break}}if(r[C++]=o[w++],--g===1){R=!0;break}D--}while(M>=wv||N>=wv);if(R)break;D<0&&(D=0),D+=2}if(t=D,t<1&&(t=1),g===1){for(b=0;b<x;b++)r[C+b]=r[T+b];r[C+x]=o[w]}else{if(g===0)throw new Error;for(b=0;b<g;b++)r[C+b]=o[w+b]}}function d(v,g,y,x){var b=0;for(b=0;b<x;b++)o[b]=r[y+b];var w=v+g-1,T=x-1,C=y+x-1,D=0,M=0;if(r[C--]=r[w--],--g===0){for(D=C-(x-1),b=0;b<x;b++)r[D+b]=o[b];return}if(x===1){for(C-=g,w-=g,M=C+1,D=w+1,b=g-1;b>=0;b--)r[M+b]=r[D+b];r[C]=o[T];return}for(var N=t;;){var R=0,E=0,k=!1;do if(e(o[T],r[w])<0){if(r[C--]=r[w--],R++,E=0,--g===0){k=!0;break}}else if(r[C--]=o[T--],E++,R=0,--x===1){k=!0;break}while((R|E)<N);if(k)break;do{if(R=g-ow(o[T],r,v,g,g-1,e),R!==0){for(C-=R,w-=R,g-=R,M=C+1,D=w+1,b=R-1;b>=0;b--)r[M+b]=r[D+b];if(g===0){k=!0;break}}if(r[C--]=o[T--],--x===1){k=!0;break}if(E=x-iw(r[w],o,0,x,x-1,e),E!==0){for(C-=E,T-=E,x-=E,M=C+1,D=T+1,b=0;b<E;b++)r[M+b]=o[D+b];if(x<=1){k=!0;break}}if(r[C--]=r[w--],--g===0){k=!0;break}N--}while(R>=wv||E>=wv);if(k)break;N<0&&(N=0),N+=2}if(t=N,t<1&&(t=1),x===1){for(C-=g,w-=g,M=C+1,D=w+1,b=g-1;b>=0;b--)r[M+b]=r[D+b];r[C]=o[T]}else{if(x===0)throw new Error;for(D=C-(x-1),b=0;b<x;b++)r[D+b]=o[b]}}return{mergeRuns:l,forceMergeRuns:u,pushRun:s}}function W0(r,e,t,n){t||(t=0),n||(n=r.length);var a=n-t;if(!(a<2)){var i=0;if(a<L6){i=EO(r,t,n,e),kO(r,t,n,t+i,e);return}var o=ere(r,e),s=Qte(a);do{if(i=EO(r,t,n,e),i<s){var l=a;l>s&&(l=s),kO(r,t,t+l,t+i,e),i=l}o.pushRun(t,i),o.mergeRuns(),a-=i,t+=i}while(a!==0);o.forceMergeRuns()}}var ea=1,up=2,Xf=4,IO=!1;function sw(){IO||(IO=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function OO(r,e){return r.zlevel===e.zlevel?r.z===e.z?r.z2-e.z2:r.z-e.z:r.zlevel-e.zlevel}var tre=(function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=OO}return r.prototype.traverse=function(e,t){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(e,t)},r.prototype.getDisplayList=function(e,t){t=t||!1;var n=this._displayList;return(e||!n.length)&&this.updateDisplayList(t),n},r.prototype.updateDisplayList=function(e){this._displayListLen=0;for(var t=this._roots,n=this._displayList,a=0,i=t.length;a<i;a++)this._updateAndAddDisplayable(t[a],null,e);n.length=this._displayListLen,W0(n,OO)},r.prototype._updateAndAddDisplayable=function(e,t,n){if(!(e.ignore&&!n)){e.beforeUpdate(),e.update(),e.afterUpdate();var a=e.getClipPath(),i=t&&t.length,o=0,s=e.__clipPaths;if(!e.ignoreClip&&(i||a)){if(s||(s=e.__clipPaths=[]),i)for(var l=0;l<t.length;l++)s[o++]=t[l];for(var u=a,c=e;u;)u.parent=c,u.updateTransform(),s[o++]=u,c=u,u=u.getClipPath()}if(s&&(s.length=o),e.childrenRef){for(var f=e.childrenRef(),d=0;d<f.length;d++){var v=f[d];e.__dirty&&(v.__dirty|=ea),this._updateAndAddDisplayable(v,s,n)}e.__dirty=0}else{var g=e;isNaN(g.z)&&(sw(),g.z=0),isNaN(g.z2)&&(sw(),g.z2=0),isNaN(g.zlevel)&&(sw(),g.zlevel=0),this._displayList[this._displayListLen++]=g}var y=e.getDecalElement&&e.getDecalElement();y&&this._updateAndAddDisplayable(y,s,n);var x=e.getTextGuideLine();x&&this._updateAndAddDisplayable(x,s,n);var b=e.getTextContent();b&&this._updateAndAddDisplayable(b,s,n)}},r.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},r.prototype.delRoot=function(e){if(e instanceof Array){for(var t=0,n=e.length;t<n;t++)this.delRoot(e[t]);return}var a=Fe(this._roots,e);a>=0&&this._roots.splice(a,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r})(),Mx;Mx=nt.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};var Mp={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var e,t=.1,n=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=n/4):e=n*Math.asin(1/t)/(2*Math.PI),-(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/n)))},elasticOut:function(r){var e,t=.1,n=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=n/4):e=n*Math.asin(1/t)/(2*Math.PI),t*Math.pow(2,-10*r)*Math.sin((r-e)*(2*Math.PI)/n)+1)},elasticInOut:function(r){var e,t=.1,n=.4;return r===0?0:r===1?1:(!t||t<1?(t=1,e=n/4):e=n*Math.asin(1/t)/(2*Math.PI),(r*=2)<1?-.5*(t*Math.pow(2,10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/n)):t*Math.pow(2,-10*(r-=1))*Math.sin((r-e)*(2*Math.PI)/n)*.5+1)},backIn:function(r){var e=1.70158;return r*r*((e+1)*r-e)},backOut:function(r){var e=1.70158;return--r*r*((e+1)*r+e)+1},backInOut:function(r){var e=2.5949095;return(r*=2)<1?.5*(r*r*((e+1)*r-e)):.5*((r-=2)*r*((e+1)*r+e)+2)},bounceIn:function(r){return 1-Mp.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?Mp.bounceIn(r*2)*.5:Mp.bounceOut(r*2-1)*.5+.5}},My=Math.pow,cl=Math.sqrt,Dx=1e-8,R6=1e-4,PO=cl(3),Dy=1/3,Ri=Nl(),Na=Nl(),ch=Nl();function tl(r){return r>-Dx&&r<Dx}function E6(r){return r>Dx||r<-Dx}function Nr(r,e,t,n,a){var i=1-a;return i*i*(i*r+3*a*e)+a*a*(a*n+3*i*t)}function jO(r,e,t,n,a){var i=1-a;return 3*(((e-r)*i+2*(t-e)*a)*i+(n-t)*a*a)}function Nx(r,e,t,n,a,i){var o=n+3*(e-t)-r,s=3*(t-e*2+r),l=3*(e-r),u=r-a,c=s*s-3*o*l,f=s*l-9*o*u,d=l*l-3*s*u,v=0;if(tl(c)&&tl(f))if(tl(s))i[0]=0;else{var g=-l/s;g>=0&&g<=1&&(i[v++]=g)}else{var y=f*f-4*c*d;if(tl(y)){var x=f/c,g=-s/o+x,b=-x/2;g>=0&&g<=1&&(i[v++]=g),b>=0&&b<=1&&(i[v++]=b)}else if(y>0){var w=cl(y),T=c*s+1.5*o*(-f+w),C=c*s+1.5*o*(-f-w);T<0?T=-My(-T,Dy):T=My(T,Dy),C<0?C=-My(-C,Dy):C=My(C,Dy);var g=(-s-(T+C))/(3*o);g>=0&&g<=1&&(i[v++]=g)}else{var D=(2*c*s-3*o*f)/(2*cl(c*c*c)),M=Math.acos(D)/3,N=cl(c),R=Math.cos(M),g=(-s-2*N*R)/(3*o),b=(-s+N*(R+PO*Math.sin(M)))/(3*o),E=(-s+N*(R-PO*Math.sin(M)))/(3*o);g>=0&&g<=1&&(i[v++]=g),b>=0&&b<=1&&(i[v++]=b),E>=0&&E<=1&&(i[v++]=E)}}return v}function k6(r,e,t,n,a){var i=6*t-12*e+6*r,o=9*e+3*n-3*r-9*t,s=3*e-3*r,l=0;if(tl(o)){if(E6(i)){var u=-s/i;u>=0&&u<=1&&(a[l++]=u)}}else{var c=i*i-4*o*s;if(tl(c))a[0]=-i/(2*o);else if(c>0){var f=cl(c),u=(-i+f)/(2*o),d=(-i-f)/(2*o);u>=0&&u<=1&&(a[l++]=u),d>=0&&d<=1&&(a[l++]=d)}}return l}function _l(r,e,t,n,a,i){var o=(e-r)*a+r,s=(t-e)*a+e,l=(n-t)*a+t,u=(s-o)*a+o,c=(l-s)*a+s,f=(c-u)*a+u;i[0]=r,i[1]=o,i[2]=u,i[3]=f,i[4]=f,i[5]=c,i[6]=l,i[7]=n}function I6(r,e,t,n,a,i,o,s,l,u,c){var f,d=.005,v=1/0,g,y,x,b;Ri[0]=l,Ri[1]=u;for(var w=0;w<1;w+=.05)Na[0]=Nr(r,t,a,o,w),Na[1]=Nr(e,n,i,s,w),x=ul(Ri,Na),x<v&&(f=w,v=x);v=1/0;for(var T=0;T<32&&!(d<R6);T++)g=f-d,y=f+d,Na[0]=Nr(r,t,a,o,g),Na[1]=Nr(e,n,i,s,g),x=ul(Na,Ri),g>=0&&x<v?(f=g,v=x):(ch[0]=Nr(r,t,a,o,y),ch[1]=Nr(e,n,i,s,y),b=ul(ch,Ri),y<=1&&b<v?(f=y,v=b):d*=.5);return c&&(c[0]=Nr(r,t,a,o,f),c[1]=Nr(e,n,i,s,f)),cl(v)}function rre(r,e,t,n,a,i,o,s,l){for(var u=r,c=e,f=0,d=1/l,v=1;v<=l;v++){var g=v*d,y=Nr(r,t,a,o,g),x=Nr(e,n,i,s,g),b=y-u,w=x-c;f+=Math.sqrt(b*b+w*w),u=y,c=x}return f}function Hr(r,e,t,n){var a=1-n;return a*(a*r+2*n*e)+n*n*t}function vC(r,e,t,n){return 2*((1-n)*(e-r)+n*(t-e))}function nre(r,e,t,n,a){var i=r-2*e+t,o=2*(e-r),s=r-n,l=0;if(tl(i)){if(E6(o)){var u=-s/o;u>=0&&u<=1&&(a[l++]=u)}}else{var c=o*o-4*i*s;if(tl(c)){var u=-o/(2*i);u>=0&&u<=1&&(a[l++]=u)}else if(c>0){var f=cl(c),u=(-o+f)/(2*i),d=(-o-f)/(2*i);u>=0&&u<=1&&(a[l++]=u),d>=0&&d<=1&&(a[l++]=d)}}return l}function O6(r,e,t){var n=r+t-2*e;return n===0?.5:(r-e)/n}function Zp(r,e,t,n,a){var i=(e-r)*n+r,o=(t-e)*n+e,s=(o-i)*n+i;a[0]=r,a[1]=i,a[2]=s,a[3]=s,a[4]=o,a[5]=t}function P6(r,e,t,n,a,i,o,s,l){var u,c=.005,f=1/0;Ri[0]=o,Ri[1]=s;for(var d=0;d<1;d+=.05){Na[0]=Hr(r,t,a,d),Na[1]=Hr(e,n,i,d);var v=ul(Ri,Na);v<f&&(u=d,f=v)}f=1/0;for(var g=0;g<32&&!(c<R6);g++){var y=u-c,x=u+c;Na[0]=Hr(r,t,a,y),Na[1]=Hr(e,n,i,y);var v=ul(Na,Ri);if(y>=0&&v<f)u=y,f=v;else{ch[0]=Hr(r,t,a,x),ch[1]=Hr(e,n,i,x);var b=ul(ch,Ri);x<=1&&b<f?(u=x,f=b):c*=.5}}return l&&(l[0]=Hr(r,t,a,u),l[1]=Hr(e,n,i,u)),cl(f)}function are(r,e,t,n,a,i,o){for(var s=r,l=e,u=0,c=1/o,f=1;f<=o;f++){var d=f*c,v=Hr(r,t,a,d),g=Hr(e,n,i,d),y=v-s,x=g-l;u+=Math.sqrt(y*y+x*x),s=v,l=g}return u}var ire=/cubic-bezier\(([0-9,\.e ]+)\)/;function JM(r){var e=r&&ire.exec(r);if(e){var t=e[1].split(","),n=+ra(t[0]),a=+ra(t[1]),i=+ra(t[2]),o=+ra(t[3]);if(isNaN(n+a+i+o))return;var s=[];return function(l){return l<=0?0:l>=1?1:Nx(0,n,i,1,l,s)&&Nr(0,a,o,1,s[0])}}}var ore=(function(){function r(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||Kt,this.ondestroy=e.ondestroy||Kt,this.onrestart=e.onrestart||Kt,e.easing&&this.setEasing(e.easing)}return r.prototype.step=function(e,t){if(this._inited||(this._startTime=e+this._delay,this._inited=!0),this._paused){this._pausedTime+=t;return}var n=this._life,a=e-this._startTime-this._pausedTime,i=a/n;i<0&&(i=0),i=Math.min(i,1);var o=this.easingFunc,s=o?o(i):i;if(this.onframe(s),i===1)if(this.loop){var l=a%n;this._startTime=e-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(e){this.easing=e,this.easingFunc=Me(e)?e:Mp[e]||JM(e)},r})(),j6=(function(){function r(e){this.value=e}return r})(),sre=(function(){function r(){this._len=0}return r.prototype.insert=function(e){var t=new j6(e);return this.insertEntry(t),t},r.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},r.prototype.remove=function(e){var t=e.prev,n=e.next;t?t.next=n:this.head=n,n?n.prev=t:this.tail=t,e.next=e.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r})(),Rh=(function(){function r(e){this._list=new sre,this._maxSize=10,this._map={},this._maxSize=e}return r.prototype.put=function(e,t){var n=this._list,a=this._map,i=null;if(a[e]==null){var o=n.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var l=n.head;n.remove(l),delete a[l.key],i=l.value,this._lastRemovedEntry=l}s?s.value=t:s=new j6(t),s.key=e,n.insertEntry(s),a[e]=s}return i},r.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},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r})(),zO={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 ei(r){return r=Math.round(r),r<0?0:r>255?255:r}function lre(r){return r=Math.round(r),r<0?0:r>360?360:r}function $p(r){return r<0?0:r>1?1:r}function X0(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?ei(parseFloat(e)/100*255):ei(parseInt(e,10))}function Vo(r){var e=r;return e.length&&e.charAt(e.length-1)==="%"?$p(parseFloat(e)/100):$p(parseFloat(e))}function lw(r,e,t){return t<0?t+=1:t>1&&(t-=1),t*6<1?r+(e-r)*t*6:t*2<1?e:t*3<2?r+(e-r)*(2/3-t)*6:r}function rl(r,e,t){return r+(e-r)*t}function Sa(r,e,t,n,a){return r[0]=e,r[1]=t,r[2]=n,r[3]=a,r}function pC(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r}var z6=new Rh(20),Ny=null;function mf(r,e){Ny&&pC(Ny,e),Ny=z6.put(r,Ny||e.slice())}function vn(r,e){if(r){e=e||[];var t=z6.get(r);if(t)return pC(e,t);r=r+"";var n=r.replace(/ /g,"").toLowerCase();if(n in zO)return pC(e,zO[n]),mf(r,e),e;var a=n.length;if(n.charAt(0)==="#"){if(a===4||a===5){var i=parseInt(n.slice(1,4),16);if(!(i>=0&&i<=4095)){Sa(e,0,0,0,1);return}return Sa(e,(i&3840)>>4|(i&3840)>>8,i&240|(i&240)>>4,i&15|(i&15)<<4,a===5?parseInt(n.slice(4),16)/15:1),mf(r,e),e}else if(a===7||a===9){var i=parseInt(n.slice(1,7),16);if(!(i>=0&&i<=16777215)){Sa(e,0,0,0,1);return}return Sa(e,(i&16711680)>>16,(i&65280)>>8,i&255,a===9?parseInt(n.slice(7),16)/255:1),mf(r,e),e}return}var o=n.indexOf("("),s=n.indexOf(")");if(o!==-1&&s+1===a){var l=n.substr(0,o),u=n.substr(o+1,s-(o+1)).split(","),c=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?Sa(e,+u[0],+u[1],+u[2],1):Sa(e,0,0,0,1);c=Vo(u.pop());case"rgb":if(u.length>=3)return Sa(e,X0(u[0]),X0(u[1]),X0(u[2]),u.length===3?c:Vo(u[3])),mf(r,e),e;Sa(e,0,0,0,1);return;case"hsla":if(u.length!==4){Sa(e,0,0,0,1);return}return u[3]=Vo(u[3]),gC(u,e),mf(r,e),e;case"hsl":if(u.length!==3){Sa(e,0,0,0,1);return}return gC(u,e),mf(r,e),e;default:return}}Sa(e,0,0,0,1)}}function gC(r,e){var t=(parseFloat(r[0])%360+360)%360/360,n=Vo(r[1]),a=Vo(r[2]),i=a<=.5?a*(n+1):a+n-a*n,o=a*2-i;return e=e||[],Sa(e,ei(lw(o,i,t+1/3)*255),ei(lw(o,i,t)*255),ei(lw(o,i,t-1/3)*255),1),r.length===4&&(e[3]=r[3]),e}function ure(r){if(r){var e=r[0]/255,t=r[1]/255,n=r[2]/255,a=Math.min(e,t,n),i=Math.max(e,t,n),o=i-a,s=(i+a)/2,l,u;if(o===0)l=0,u=0;else{s<.5?u=o/(i+a):u=o/(2-i-a);var c=((i-e)/6+o/2)/o,f=((i-t)/6+o/2)/o,d=((i-n)/6+o/2)/o;e===i?l=d-f:t===i?l=1/3+c-d:n===i&&(l=2/3+f-c),l<0&&(l+=1),l>1&&(l-=1)}var v=[l*360,u,s];return r[3]!=null&&v.push(r[3]),v}}function Lx(r,e){var t=vn(r);if(t){for(var n=0;n<3;n++)e<0?t[n]=t[n]*(1-e)|0:t[n]=(255-t[n])*e+t[n]|0,t[n]>255?t[n]=255:t[n]<0&&(t[n]=0);return Ea(t,t.length===4?"rgba":"rgb")}}function cre(r){var e=vn(r);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function Dp(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){t=t||[];var n=r*(e.length-1),a=Math.floor(n),i=Math.ceil(n),o=e[a],s=e[i],l=n-a;return t[0]=ei(rl(o[0],s[0],l)),t[1]=ei(rl(o[1],s[1],l)),t[2]=ei(rl(o[2],s[2],l)),t[3]=$p(rl(o[3],s[3],l)),t}}var fre=Dp;function eD(r,e,t){if(!(!(e&&e.length)||!(r>=0&&r<=1))){var n=r*(e.length-1),a=Math.floor(n),i=Math.ceil(n),o=vn(e[a]),s=vn(e[i]),l=n-a,u=Ea([ei(rl(o[0],s[0],l)),ei(rl(o[1],s[1],l)),ei(rl(o[2],s[2],l)),$p(rl(o[3],s[3],l))],"rgba");return t?{color:u,leftIndex:a,rightIndex:i,value:n}:u}}var hre=eD;function Go(r,e,t,n){var a=vn(r);if(r)return a=ure(a),e!=null&&(a[0]=lre(Me(e)?e(a[0]):e)),t!=null&&(a[1]=Vo(Me(t)?t(a[1]):t)),n!=null&&(a[2]=Vo(Me(n)?n(a[2]):n)),Ea(gC(a),"rgba")}function Kp(r,e){var t=vn(r);if(t&&e!=null)return t[3]=$p(e),Ea(t,"rgba")}function Ea(r,e){if(!(!r||!r.length)){var t=r[0]+","+r[1]+","+r[2];return(e==="rgba"||e==="hsva"||e==="hsla")&&(t+=","+r[3]),e+"("+t+")"}}function Qp(r,e){var t=vn(r);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}function dre(){return Ea([Math.round(Math.random()*255),Math.round(Math.random()*255),Math.round(Math.random()*255)],"rgb")}var BO=new Rh(100);function Rx(r){if(ye(r)){var e=BO.get(r);return e||(e=Lx(r,-.1),BO.put(r,e)),e}else if(zg(r)){var t=ie({},r);return t.colorStops=fe(r.colorStops,function(n){return{offset:n.offset,color:Lx(n.color,-.1)}}),t}return r}const vre=Object.freeze(Object.defineProperty({__proto__:null,fastLerp:Dp,fastMapToColor:fre,lerp:eD,lift:Lx,liftColor:Rx,lum:Qp,mapToColor:hre,modifyAlpha:Kp,modifyHSL:Go,parse:vn,parseCssFloat:Vo,parseCssInt:X0,random:dre,stringify:Ea,toHex:cre},Symbol.toStringTag,{value:"Module"}));var Ex=Math.round;function Jp(r){var e;if(!r||r==="transparent")r="none";else if(typeof r=="string"&&r.indexOf("rgba")>-1){var t=vn(r);t&&(r="rgb("+t[0]+","+t[1]+","+t[2]+")",e=t[3])}return{color:r,opacity:e??1}}var VO=1e-4;function nl(r){return r<VO&&r>-VO}function Ly(r){return Ex(r*1e3)/1e3}function mC(r){return Ex(r*1e4)/1e4}function pre(r){return"matrix("+Ly(r[0])+","+Ly(r[1])+","+Ly(r[2])+","+Ly(r[3])+","+mC(r[4])+","+mC(r[5])+")"}var gre={left:"start",right:"end",center:"middle",middle:"middle"};function mre(r,e,t){return t==="top"?r+=e/2:t==="bottom"&&(r-=e/2),r}function yre(r){return r&&(r.shadowBlur||r.shadowOffsetX||r.shadowOffsetY)}function xre(r){var e=r.style,t=r.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),t[0],t[1]].join(",")}function B6(r){return r&&!!r.image}function bre(r){return r&&!!r.svgElement}function tD(r){return B6(r)||bre(r)}function V6(r){return r.type==="linear"}function G6(r){return r.type==="radial"}function H6(r){return r&&(r.type==="linear"||r.type==="radial")}function $1(r){return"url(#"+r+")"}function F6(r){var e=r.getGlobalScale(),t=Math.max(e[0],e[1]);return Math.max(Math.ceil(Math.log(t)/Math.log(10)),1)}function U6(r){var e=r.x||0,t=r.y||0,n=(r.rotation||0)*wp,a=Ce(r.scaleX,1),i=Ce(r.scaleY,1),o=r.skewX||0,s=r.skewY||0,l=[];return(e||t)&&l.push("translate("+e+"px,"+t+"px)"),n&&l.push("rotate("+n+")"),(a!==1||i!==1)&&l.push("scale("+a+","+i+")"),(o||s)&&l.push("skew("+Ex(o*wp)+"deg, "+Ex(s*wp)+"deg)"),l.join(" ")}var _re=(function(){return nt.hasGlobalWindow&&Me(window.btoa)?function(r){return window.btoa(unescape(encodeURIComponent(r)))}:typeof Buffer<"u"?function(r){return Buffer.from(r).toString("base64")}:function(r){return null}})(),yC=Array.prototype.slice;function Do(r,e,t){return(e-r)*t+r}function uw(r,e,t,n){for(var a=e.length,i=0;i<a;i++)r[i]=Do(e[i],t[i],n);return r}function Sre(r,e,t,n){for(var a=e.length,i=a&&e[0].length,o=0;o<a;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=Do(e[o][s],t[o][s],n)}return r}function Ry(r,e,t,n){for(var a=e.length,i=0;i<a;i++)r[i]=e[i]+t[i]*n;return r}function GO(r,e,t,n){for(var a=e.length,i=a&&e[0].length,o=0;o<a;o++){r[o]||(r[o]=[]);for(var s=0;s<i;s++)r[o][s]=e[o][s]+t[o][s]*n}return r}function wre(r,e){for(var t=r.length,n=e.length,a=t>n?e:r,i=Math.min(t,n),o=a[i-1]||{color:[0,0,0,0],offset:0},s=i;s<Math.max(t,n);s++)a.push({offset:o.offset,color:o.color.slice()})}function Tre(r,e,t){var n=r,a=e;if(!(!n.push||!a.push)){var i=n.length,o=a.length;if(i!==o){var s=i>o;if(s)n.length=o;else for(var l=i;l<o;l++)n.push(t===1?a[l]:yC.call(a[l]))}for(var u=n[0]&&n[0].length,l=0;l<n.length;l++)if(t===1)isNaN(n[l])&&(n[l]=a[l]);else for(var c=0;c<u;c++)isNaN(n[l][c])&&(n[l][c]=a[l][c])}}function Np(r){if(tn(r)){var e=r.length;if(tn(r[0])){for(var t=[],n=0;n<e;n++)t.push(yC.call(r[n]));return t}return yC.call(r)}return r}function q0(r){return r[0]=Math.floor(r[0])||0,r[1]=Math.floor(r[1])||0,r[2]=Math.floor(r[2])||0,r[3]=r[3]==null?1:r[3],"rgba("+r.join(",")+")"}function Cre(r){return tn(r&&r[0])?2:1}var Ey=0,Z0=1,Y6=2,cp=3,xC=4,bC=5,HO=6;function FO(r){return r===xC||r===bC}function ky(r){return r===Z0||r===Y6}var Tv=[0,0,0,0],Are=(function(){function r(e){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=e}return r.prototype.isFinished=function(){return this._finished},r.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},r.prototype.needsAnimate=function(){return this.keyframes.length>=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(e,t,n){this._needsSort=!0;var a=this.keyframes,i=a.length,o=!1,s=HO,l=t;if(tn(t)){var u=Cre(t);s=u,(u===1&&!st(t[0])||u===2&&!st(t[0][0]))&&(o=!0)}else if(st(t)&&!en(t))s=Ey;else if(ye(t))if(!isNaN(+t))s=Ey;else{var c=vn(t);c&&(l=c,s=cp)}else if(zg(t)){var f=ie({},l);f.colorStops=fe(t.colorStops,function(v){return{offset:v.offset,color:vn(v.color)}}),V6(t)?s=xC:G6(t)&&(s=bC),l=f}i===0?this.valType=s:(s!==this.valType||s===HO)&&(o=!0),this.discrete=this.discrete||o;var d={time:e,value:l,rawValue:t,percent:0};return n&&(d.easing=n,d.easingFunc=Me(n)?n:Mp[n]||JM(n)),a.push(d),d},r.prototype.prepare=function(e,t){var n=this.keyframes;this._needsSort&&n.sort(function(y,x){return y.time-x.time});for(var a=this.valType,i=n.length,o=n[i-1],s=this.discrete,l=ky(a),u=FO(a),c=0;c<i;c++){var f=n[c],d=f.value,v=o.value;f.percent=f.time/e,s||(l&&c!==i-1?Tre(d,v,a):u&&wre(d.colorStops,v.colorStops))}if(!s&&a!==bC&&t&&this.needsAnimate()&&t.needsAnimate()&&a===t.valType&&!t._finished){this._additiveTrack=t;for(var g=n[0].value,c=0;c<i;c++)a===Ey?n[c].additiveValue=n[c].value-g:a===cp?n[c].additiveValue=Ry([],n[c].value,g,-1):ky(a)&&(n[c].additiveValue=a===Z0?Ry([],n[c].value,g,-1):GO([],n[c].value,g,-1))}},r.prototype.step=function(e,t){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n=this._additiveTrack!=null,a=n?"additiveValue":"value",i=this.valType,o=this.keyframes,s=o.length,l=this.propName,u=i===cp,c,f=this._lastFr,d=Math.min,v,g;if(s===1)v=g=o[0];else{if(t<0)c=0;else if(t<this._lastFrP){var y=d(f+1,s-1);for(c=y;c>=0&&!(o[c].percent<=t);c--);c=d(c,s-2)}else{for(c=f;c<s&&!(o[c].percent>t);c++);c=d(c-1,s-2)}g=o[c+1],v=o[c]}if(v&&g){this._lastFr=c,this._lastFrP=t;var x=g.percent-v.percent,b=x===0?1:d((t-v.percent)/x,1);g.easingFunc&&(b=g.easingFunc(b));var w=n?this._additiveValue:u?Tv:e[l];if((ky(i)||u)&&!w&&(w=this._additiveValue=[]),this.discrete)e[l]=b<1?v.rawValue:g.rawValue;else if(ky(i))i===Z0?uw(w,v[a],g[a],b):Sre(w,v[a],g[a],b);else if(FO(i)){var T=v[a],C=g[a],D=i===xC;e[l]={type:D?"linear":"radial",x:Do(T.x,C.x,b),y:Do(T.y,C.y,b),colorStops:fe(T.colorStops,function(N,R){var E=C.colorStops[R];return{offset:Do(N.offset,E.offset,b),color:q0(uw([],N.color,E.color,b))}}),global:C.global},D?(e[l].x2=Do(T.x2,C.x2,b),e[l].y2=Do(T.y2,C.y2,b)):e[l].r=Do(T.r,C.r,b)}else if(u)uw(w,v[a],g[a],b),n||(e[l]=q0(w));else{var M=Do(v[a],g[a],b);n?this._additiveValue=M:e[l]=M}n&&this._addToTarget(e)}}},r.prototype._addToTarget=function(e){var t=this.valType,n=this.propName,a=this._additiveValue;t===Ey?e[n]=e[n]+a:t===cp?(vn(e[n],Tv),Ry(Tv,Tv,a,1),e[n]=q0(Tv)):t===Z0?Ry(e[n],e[n],a,1):t===Y6&&GO(e[n],e[n],a,1)},r})(),rD=(function(){function r(e,t,n,a){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=e,this._loop=t,t&&a){Y1("Can' use additive animation on looped animation.");return}this._additiveAnimators=a,this._allowDiscrete=n}return r.prototype.getMaxTime=function(){return this._maxTime},r.prototype.getDelay=function(){return this._delay},r.prototype.getLoop=function(){return this._loop},r.prototype.getTarget=function(){return this._target},r.prototype.changeTarget=function(e){this._target=e},r.prototype.when=function(e,t,n){return this.whenWithKeys(e,t,it(t),n)},r.prototype.whenWithKeys=function(e,t,n,a){for(var i=this._tracks,o=0;o<n.length;o++){var s=n[o],l=i[s];if(!l){l=i[s]=new Are(s);var u=void 0,c=this._getAdditiveTrack(s);if(c){var f=c.keyframes,d=f[f.length-1];u=d&&d.value,c.valType===cp&&u&&(u=q0(u))}else u=this._target[s];if(u==null)continue;e>0&&l.addKeyframe(0,Np(u),a),this._trackKeys.push(s)}l.addKeyframe(e,Np(t[s]),a)}return this._maxTime=Math.max(this._maxTime,e),this},r.prototype.pause=function(){this._clip.pause(),this._paused=!0},r.prototype.resume=function(){this._clip.resume(),this._paused=!1},r.prototype.isPaused=function(){return!!this._paused},r.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},r.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)},r.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)},r.prototype._setTracksFinished=function(){for(var e=this._tracks,t=this._trackKeys,n=0;n<t.length;n++)e[t[n]].setFinished()},r.prototype._getAdditiveTrack=function(e){var t,n=this._additiveAnimators;if(n)for(var a=0;a<n.length;a++){var i=n[a].getTrack(e);i&&(t=i)}return t},r.prototype.start=function(e){if(!(this._started>0)){this._started=1;for(var t=this,n=[],a=this._maxTime||0,i=0;i<this._trackKeys.length;i++){var o=this._trackKeys[i],s=this._tracks[o],l=this._getAdditiveTrack(o),u=s.keyframes,c=u.length;if(s.prepare(a,l),s.needsAnimate())if(!this._allowDiscrete&&s.discrete){var f=u[c-1];f&&(t._target[s.propName]=f.rawValue),s.setFinished()}else n.push(s)}if(n.length||this._force){var d=new ore({life:a,loop:this._loop,delay:this._delay||0,onframe:function(v){t._started=2;var g=t._additiveAnimators;if(g){for(var y=!1,x=0;x<g.length;x++)if(g[x]._clip){y=!0;break}y||(t._additiveAnimators=null)}for(var x=0;x<n.length;x++)n[x].step(t._target,v);var b=t._onframeCbs;if(b)for(var x=0;x<b.length;x++)b[x](t._target,v)},ondestroy:function(){t._doneCallback()}});this._clip=d,this.animation&&this.animation.addClip(d),e&&d.setEasing(e)}else this._doneCallback();return this}},r.prototype.stop=function(e){if(this._clip){var t=this._clip;e&&t.onframe(1),this._abortedCallback()}},r.prototype.delay=function(e){return this._delay=e,this},r.prototype.during=function(e){return e&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(e)),this},r.prototype.done=function(e){return e&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(e)),this},r.prototype.aborted=function(e){return e&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(e)),this},r.prototype.getClip=function(){return this._clip},r.prototype.getTrack=function(e){return this._tracks[e]},r.prototype.getTracks=function(){var e=this;return fe(this._trackKeys,function(t){return e._tracks[t]})},r.prototype.stopTracks=function(e,t){if(!e.length||!this._clip)return!0;for(var n=this._tracks,a=this._trackKeys,i=0;i<e.length;i++){var o=n[e[i]];o&&!o.isFinished()&&(t?o.step(this._target,1):this._started===1&&o.step(this._target,0),o.setFinished())}for(var s=!0,i=0;i<a.length;i++)if(!n[a[i]].isFinished()){s=!1;break}return s&&this._abortedCallback(),s},r.prototype.saveTo=function(e,t,n){if(e){t=t||this._trackKeys;for(var a=0;a<t.length;a++){var i=t[a],o=this._tracks[i];if(!(!o||o.isFinished())){var s=o.keyframes,l=s[n?0:s.length-1];l&&(e[i]=Np(l.rawValue))}}}},r.prototype.__changeFinalValue=function(e,t){t=t||it(e);for(var n=0;n<t.length;n++){var a=t[n],i=this._tracks[a];if(i){var o=i.keyframes;if(o.length>1){var s=o.pop();i.addKeyframe(s.time,e[a]),i.prepare(this._maxTime,i.getAdditiveTrack())}}}},r})();function Jf(){return new Date().getTime()}var Mre=(function(r){K(e,r);function e(t){var n=r.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,t=t||{},n.stage=t.stage||{},n}return e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var n=t.getClip();n&&this.addClip(n)},e.prototype.removeClip=function(t){if(t.animation){var n=t.prev,a=t.next;n?n.next=a:this._head=a,a?a.prev=n:this._tail=n,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var n=t.getClip();n&&this.removeClip(n),t.animation=null},e.prototype.update=function(t){for(var n=Jf()-this._pausedTime,a=n-this._time,i=this._head;i;){var o=i.next,s=i.step(n,a);s&&(i.ondestroy(),this.removeClip(i)),i=o}this._time=n,t||(this.trigger("frame",a),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;this._running=!0;function n(){t._running&&(Mx(n),!t._paused&&t.update())}Mx(n)},e.prototype.start=function(){this._running||(this._time=Jf(),this._pausedTime=0,this._startLoop())},e.prototype.stop=function(){this._running=!1},e.prototype.pause=function(){this._paused||(this._pauseStart=Jf(),this._paused=!0)},e.prototype.resume=function(){this._paused&&(this._pausedTime+=Jf()-this._pauseStart,this._paused=!1)},e.prototype.clear=function(){for(var t=this._head;t;){var n=t.next;t.prev=t.next=t.animation=null,t=n}this._head=this._tail=null},e.prototype.isFinished=function(){return this._head==null},e.prototype.animate=function(t,n){n=n||{},this.start();var a=new rD(t,n.loop);return this.addAnimator(a),a},e})(za),Dre=300,cw=nt.domSupported,fw=(function(){var r=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],e=["touchstart","touchend","touchmove"],t={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},n=fe(r,function(a){var i=a.replace("mouse","pointer");return t.hasOwnProperty(i)?i:a});return{mouse:r,touch:e,pointer:n}})(),UO={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},YO=!1;function _C(r){var e=r.pointerType;return e==="pen"||e==="touch"}function Nre(r){r.touching=!0,r.touchTimer!=null&&(clearTimeout(r.touchTimer),r.touchTimer=null),r.touchTimer=setTimeout(function(){r.touching=!1,r.touchTimer=null},700)}function hw(r){r&&(r.zrByTouch=!0)}function Lre(r,e){return wa(r.dom,new Rre(r,e),!0)}function W6(r,e){for(var t=e,n=!1;t&&t.nodeType!==9&&!(n=t.domBelongToZr||t!==e&&t===r.painterRoot);)t=t.parentNode;return n}var Rre=(function(){function r(e,t){this.stopPropagation=Kt,this.stopImmediatePropagation=Kt,this.preventDefault=Kt,this.type=t.type,this.target=this.currentTarget=e.dom,this.pointerType=t.pointerType,this.clientX=t.clientX,this.clientY=t.clientY}return r})(),Xa={mousedown:function(r){r=wa(this.dom,r),this.__mayPointerCapture=[r.zrX,r.zrY],this.trigger("mousedown",r)},mousemove:function(r){r=wa(this.dom,r);var e=this.__mayPointerCapture;e&&(r.zrX!==e[0]||r.zrY!==e[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",r)},mouseup:function(r){r=wa(this.dom,r),this.__togglePointerCapture(!1),this.trigger("mouseup",r)},mouseout:function(r){r=wa(this.dom,r);var e=r.toElement||r.relatedTarget;W6(this,e)||(this.__pointerCapturing&&(r.zrEventControl="no_globalout"),this.trigger("mouseout",r))},wheel:function(r){YO=!0,r=wa(this.dom,r),this.trigger("mousewheel",r)},mousewheel:function(r){YO||(r=wa(this.dom,r),this.trigger("mousewheel",r))},touchstart:function(r){r=wa(this.dom,r),hw(r),this.__lastTouchMoment=new Date,this.handler.processGesture(r,"start"),Xa.mousemove.call(this,r),Xa.mousedown.call(this,r)},touchmove:function(r){r=wa(this.dom,r),hw(r),this.handler.processGesture(r,"change"),Xa.mousemove.call(this,r)},touchend:function(r){r=wa(this.dom,r),hw(r),this.handler.processGesture(r,"end"),Xa.mouseup.call(this,r),+new Date-+this.__lastTouchMoment<Dre&&Xa.click.call(this,r)},pointerdown:function(r){Xa.mousedown.call(this,r)},pointermove:function(r){_C(r)||Xa.mousemove.call(this,r)},pointerup:function(r){Xa.mouseup.call(this,r)},pointerout:function(r){_C(r)||Xa.mouseout.call(this,r)}};O(["click","dblclick","contextmenu"],function(r){Xa[r]=function(e){e=wa(this.dom,e),this.trigger(r,e)}});var SC={pointermove:function(r){_C(r)||SC.mousemove.call(this,r)},pointerup:function(r){SC.mouseup.call(this,r)},mousemove:function(r){this.trigger("mousemove",r)},mouseup:function(r){var e=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",r),e&&(r.zrEventControl="only_globalout",this.trigger("mouseout",r))}};function Ere(r,e){var t=e.domHandlers;nt.pointerEventsSupported?O(fw.pointer,function(n){$0(e,n,function(a){t[n].call(r,a)})}):(nt.touchEventsSupported&&O(fw.touch,function(n){$0(e,n,function(a){t[n].call(r,a),Nre(e)})}),O(fw.mouse,function(n){$0(e,n,function(a){a=QM(a),e.touching||t[n].call(r,a)})}))}function kre(r,e){nt.pointerEventsSupported?O(UO.pointer,t):nt.touchEventsSupported||O(UO.mouse,t);function t(n){function a(i){i=QM(i),W6(r,i.target)||(i=Lre(r,i),e.domHandlers[n].call(r,i))}$0(e,n,a,{capture:!0})}}function $0(r,e,t,n){r.mounted[e]=t,r.listenerOpts[e]=n,fC(r.domTarget,e,t,n)}function dw(r){var e=r.mounted;for(var t in e)e.hasOwnProperty(t)&&Vte(r.domTarget,t,e[t],r.listenerOpts[t]);r.mounted={}}var WO=(function(){function r(e,t){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=e,this.domHandlers=t}return r})(),Ire=(function(r){K(e,r);function e(t,n){var a=r.call(this)||this;return a.__pointerCapturing=!1,a.dom=t,a.painterRoot=n,a._localHandlerScope=new WO(t,Xa),cw&&(a._globalHandlerScope=new WO(document,SC)),Ere(a,a._localHandlerScope),a}return e.prototype.dispose=function(){dw(this._localHandlerScope),cw&&dw(this._globalHandlerScope)},e.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},e.prototype.__togglePointerCapture=function(t){if(this.__mayPointerCapture=null,cw&&+this.__pointerCapturing^+t){this.__pointerCapturing=t;var n=this._globalHandlerScope;t?kre(this,n):dw(n)}},e})(za),X6=1;nt.hasGlobalWindow&&(X6=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var kx=X6,wC=.4,TC="#333",CC="#ccc",Ore="#eee",XO=Gg,qO=5e-5;function nu(r){return r>qO||r<-qO}var au=[],yf=[],vw=Rr(),pw=Math.abs,jo=(function(){function r(){}return r.prototype.getLocalTransform=function(e){return r.getLocalTransform(this,e)},r.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},r.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},r.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},r.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},r.prototype.needLocalTransform=function(){return nu(this.rotation)||nu(this.x)||nu(this.y)||nu(this.scaleX-1)||nu(this.scaleY-1)||nu(this.skewX)||nu(this.skewY)},r.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),n=this.transform;if(!(t||e)){n&&(XO(n),this.invTransform=null);return}n=n||Rr(),t?this.getLocalTransform(n):XO(n),e&&(t?Ja(n,e,n):Hg(n,e)),this.transform=n,this._resolveGlobalScaleRatio(n)},r.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(t!=null&&t!==1){this.getGlobalScale(au);var n=au[0]<0?-1:1,a=au[1]<0?-1:1,i=((au[0]-n)*t+n)/au[0]||0,o=((au[1]-a)*t+a)/au[1]||0;e[0]*=i,e[1]*=i,e[2]*=o,e[3]*=o}this.invTransform=this.invTransform||Rr(),Oa(this.invTransform,e)},r.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},r.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],a=Math.atan2(e[1],e[0]),i=Math.PI/2+a-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=-a,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=n,this.originX=0,this.originY=0}},r.prototype.decomposeTransform=function(){if(this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(e.invTransform=e.invTransform||Rr(),Ja(yf,e.invTransform,t),t=yf);var n=this.originX,a=this.originY;(n||a)&&(vw[4]=n,vw[5]=a,Ja(yf,t,vw),yf[4]-=n,yf[5]-=a,t=yf),this.setLocalTransform(t)}},r.prototype.getGlobalScale=function(e){var t=this.transform;return e=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)},r.prototype.transformCoordToLocal=function(e,t){var n=[e,t],a=this.invTransform;return a&&Qt(n,n,a),n},r.prototype.transformCoordToGlobal=function(e,t){var n=[e,t],a=this.transform;return a&&Qt(n,n,a),n},r.prototype.getLineScale=function(){var e=this.transform;return e&&pw(e[0]-1)>1e-10&&pw(e[3]-1)>1e-10?Math.sqrt(pw(e[0]*e[3]-e[2]*e[1])):1},r.prototype.copyTransform=function(e){Ix(this,e)},r.getLocalTransform=function(e,t){t=t||[];var n=e.originX||0,a=e.originY||0,i=e.scaleX,o=e.scaleY,s=e.anchorX,l=e.anchorY,u=e.rotation||0,c=e.x,f=e.y,d=e.skewX?Math.tan(e.skewX):0,v=e.skewY?Math.tan(-e.skewY):0;if(n||a||s||l){var g=n+s,y=a+l;t[4]=-g*i-d*y*o,t[5]=-y*o-v*g*i}else t[4]=t[5]=0;return t[0]=i,t[3]=o,t[1]=v*i,t[2]=d*o,u&&ns(t,t,u),t[4]+=n+c,t[5]+=a+f,t},r.initDefaultProps=(function(){var e=r.prototype;e.scaleX=e.scaleY=e.globalScaleRatio=1,e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0})(),r})(),Wi=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function Ix(r,e){for(var t=0;t<Wi.length;t++){var n=Wi[t];r[n]=e[n]}}function Fi(r){Iy||(Iy=new Rh(100)),r=r||qo;var e=Iy.get(r);return e||(e={font:r,strWidthCache:new Rh(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:Bn.measureText("国",r).width,asciiCharWidth:Bn.measureText("a",r).width},Iy.put(r,e)),e}var Iy;function Pre(r){if(!(gw>=ZO)){r=r||qo;for(var e=[],t=+new Date,n=0;n<=127;n++)e[n]=Bn.measureText(String.fromCharCode(n),r).width;var a=+new Date-t;return a>16?gw=ZO:a>2&&gw++,e}}var gw=0,ZO=5;function q6(r,e){return r.asciiWidthMapTried||(r.asciiWidthMap=Pre(r.font),r.asciiWidthMapTried=!0),0<=e&&e<=127?r.asciiWidthMap!=null?r.asciiWidthMap[e]:r.asciiCharWidth:r.stWideCharWidth}function Ui(r,e){var t=r.strWidthCache,n=t.get(e);return n==null&&(n=Bn.measureText(e,r.font).width,t.put(e,n)),n}function $O(r,e,t,n){var a=Ui(Fi(e),r),i=Fg(e),o=Eh(0,a,t),s=Ju(0,i,n),l=new Oe(o,s,a,i);return l}function K1(r,e,t,n){var a=((r||"")+"").split(`
257
- `),i=a.length;if(i===1)return $O(a[0],e,t,n);for(var o=new Oe(0,0,0,0),s=0;s<a.length;s++){var l=$O(a[s],e,t,n);s===0?o.copy(l):o.union(l)}return o}function Eh(r,e,t,n){return t==="right"?n?r+=e:r-=e:t==="center"&&(n?r+=e/2:r-=e/2),r}function Ju(r,e,t,n){return t==="middle"?n?r+=e/2:r-=e/2:t==="bottom"&&(n?r+=e:r-=e),r}function Fg(r){return Fi(r).stWideCharWidth}function oi(r,e){return typeof r=="string"?r.lastIndexOf("%")>=0?parseFloat(r)/100*e:parseFloat(r):r}function Ox(r,e,t){var n=e.position||"inside",a=e.distance!=null?e.distance:5,i=t.height,o=t.width,s=i/2,l=t.x,u=t.y,c="left",f="top";if(n instanceof Array)l+=oi(n[0],t.width),u+=oi(n[1],t.height),c=null,f=null;else switch(n){case"left":l-=a,u+=s,c="right",f="middle";break;case"right":l+=a+o,u+=s,f="middle";break;case"top":l+=o/2,u-=a,c="center",f="bottom";break;case"bottom":l+=o/2,u+=i+a,c="center";break;case"inside":l+=o/2,u+=s,c="center",f="middle";break;case"insideLeft":l+=a,u+=s,f="middle";break;case"insideRight":l+=o-a,u+=s,c="right",f="middle";break;case"insideTop":l+=o/2,u+=a,c="center";break;case"insideBottom":l+=o/2,u+=i-a,c="center",f="bottom";break;case"insideTopLeft":l+=a,u+=a;break;case"insideTopRight":l+=o-a,u+=a,c="right";break;case"insideBottomLeft":l+=a,u+=i-a,f="bottom";break;case"insideBottomRight":l+=o-a,u+=i-a,c="right",f="bottom";break}return r=r||{},r.x=l,r.y=u,r.align=c,r.verticalAlign=f,r}var mw="__zr_normal__",yw=Wi.concat(["ignore"]),jre=Ia(Wi,function(r,e){return r[e]=!0,r},{ignore:!1}),xf={},zre=new Oe(0,0,0,0),Oy=[],Q1=(function(){function r(e){this.id=qM(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return r.prototype._init=function(e){this.attr(e)},r.prototype.drift=function(e,t,n){switch(this.draggable){case"horizontal":t=0;break;case"vertical":e=0;break}var a=this.transform;a||(a=this.transform=[1,0,0,1,0,0]),a[4]+=e,a[5]+=t,this.decomposeTransform(),this.markRedraw()},r.prototype.beforeUpdate=function(){},r.prototype.afterUpdate=function(){},r.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},r.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||(this.textConfig={});var n=this.textConfig,a=n.local,i=t.innerTransformable,o=void 0,s=void 0,l=!1;i.parent=a?this:null;var u=!1;i.copyTransform(t);var c=n.position!=null,f=n.autoOverflowArea,d=void 0;if((f||c)&&(d=zre,n.layoutRect?d.copy(n.layoutRect):d.copy(this.getBoundingRect()),a||d.applyTransform(this.transform)),c){this.calculateTextPosition?this.calculateTextPosition(xf,n,d):Ox(xf,n,d),i.x=xf.x,i.y=xf.y,o=xf.align,s=xf.verticalAlign;var v=n.origin;if(v&&n.rotation!=null){var g=void 0,y=void 0;v==="center"?(g=d.width*.5,y=d.height*.5):(g=oi(v[0],d.width),y=oi(v[1],d.height)),u=!0,i.originX=-i.x+g+(a?0:d.x),i.originY=-i.y+y+(a?0:d.y)}}n.rotation!=null&&(i.rotation=n.rotation);var x=n.offset;x&&(i.x+=x[0],i.y+=x[1],u||(i.originX=-x[0],i.originY=-x[1]));var b=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={});if(f){var w=b.overflowRect=b.overflowRect||new Oe(0,0,0,0);i.getLocalTransform(Oy),Oa(Oy,Oy),Oe.copy(w,d),w.applyTransform(Oy)}else b.overflowRect=null;var T=n.inside==null?typeof n.position=="string"&&n.position.indexOf("inside")>=0:n.inside,C=void 0,D=void 0,M=void 0;T&&this.canBeInsideText()?(C=n.insideFill,D=n.insideStroke,(C==null||C==="auto")&&(C=this.getInsideTextFill()),(D==null||D==="auto")&&(D=this.getInsideTextStroke(C),M=!0)):(C=n.outsideFill,D=n.outsideStroke,(C==null||C==="auto")&&(C=this.getOutsideFill()),(D==null||D==="auto")&&(D=this.getOutsideStroke(C),M=!0)),C=C||"#000",(C!==b.fill||D!==b.stroke||M!==b.autoStroke||o!==b.align||s!==b.verticalAlign)&&(l=!0,b.fill=C,b.stroke=D,b.autoStroke=M,b.align=o,b.verticalAlign=s,t.setDefaultTextStyle(b)),t.__dirty|=ea,l&&t.dirtyStyle(!0)}},r.prototype.canBeInsideText=function(){return!0},r.prototype.getInsideTextFill=function(){return"#fff"},r.prototype.getInsideTextStroke=function(e){return"#000"},r.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?CC:TC},r.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),n=typeof t=="string"&&vn(t);n||(n=[255,255,255,1]);for(var a=n[3],i=this.__zr.isDarkMode(),o=0;o<3;o++)n[o]=n[o]*a+(i?0:255)*(1-a);return n[3]=1,Ea(n,"rgba")},r.prototype.traverse=function(e,t){},r.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||{},ie(this.extra,t)):this[e]=t},r.prototype.hide=function(){this.ignore=!0,this.markRedraw()},r.prototype.show=function(){this.ignore=!1,this.markRedraw()},r.prototype.attr=function(e,t){if(typeof e=="string")this.attrKV(e,t);else if(Ee(e))for(var n=e,a=it(n),i=0;i<a.length;i++){var o=a[i];this.attrKV(o,e[o])}return this.markRedraw(),this},r.prototype.saveCurrentToNormalState=function(e){this._innerSaveToNormal(e);for(var t=this._normalState,n=0;n<this.animators.length;n++){var a=this.animators[n],i=a.__fromStateTransition;if(!(a.getLoop()||i&&i!==mw)){var o=a.targetName,s=o?t[o]:t;a.saveTo(s)}}},r.prototype._innerSaveToNormal=function(e){var t=this._normalState;t||(t=this._normalState={}),e.textConfig&&!t.textConfig&&(t.textConfig=this.textConfig),this._savePrimaryToNormal(e,t,yw)},r.prototype._savePrimaryToNormal=function(e,t,n){for(var a=0;a<n.length;a++){var i=n[a];e[i]!=null&&!(i in t)&&(t[i]=this[i])}},r.prototype.hasState=function(){return this.currentStates.length>0},r.prototype.getState=function(e){return this.states[e]},r.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},r.prototype.clearStates=function(e){this.useState(mw,!1,e)},r.prototype.useState=function(e,t,n,a){var i=e===mw,o=this.hasState();if(!(!o&&i)){var s=this.currentStates,l=this.stateTransition;if(!(Fe(s,e)>=0&&(t||s.length===1))){var u;if(this.stateProxy&&!i&&(u=this.stateProxy(e)),u||(u=this.states&&this.states[e]),!u&&!i){Y1("State "+e+" not exists.");return}i||this.saveCurrentToNormalState(u);var c=!!(u&&u.hoverLayer||a);c&&this._toggleHoverLayerFlag(!0),this._applyStateObj(e,u,this._normalState,t,!n&&!this.__inHover&&l&&l.duration>0,l);var f=this._textContent,d=this._textGuide;return f&&f.useState(e,t,n,c),d&&d.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&=~ea),u}}},r.prototype.useStates=function(e,t,n){if(!e.length)this.clearStates();else{var a=[],i=this.currentStates,o=e.length,s=o===i.length;if(s){for(var l=0;l<o;l++)if(e[l]!==i[l]){s=!1;break}}if(s)return;for(var l=0;l<o;l++){var u=e[l],c=void 0;this.stateProxy&&(c=this.stateProxy(u,e)),c||(c=this.states[u]),c&&a.push(c)}var f=a[o-1],d=!!(f&&f.hoverLayer||n);d&&this._toggleHoverLayerFlag(!0);var v=this._mergeStates(a),g=this.stateTransition;this.saveCurrentToNormalState(v),this._applyStateObj(e.join(","),v,this._normalState,!1,!t&&!this.__inHover&&g&&g.duration>0,g);var y=this._textContent,x=this._textGuide;y&&y.useStates(e,t,d),x&&x.useStates(e,t,d),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!d&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~ea)}},r.prototype.isSilent=function(){for(var e=this;e;){if(e.silent)return!0;var t=e.__hostTarget;e=t?e.ignoreHostSilent?null:t:e.parent}return!1},r.prototype._updateAnimationTargets=function(){for(var e=0;e<this.animators.length;e++){var t=this.animators[e];t.targetName&&t.changeTarget(this[t.targetName])}},r.prototype.removeState=function(e){var t=Fe(this.currentStates,e);if(t>=0){var n=this.currentStates.slice();n.splice(t,1),this.useStates(n)}},r.prototype.replaceState=function(e,t,n){var a=this.currentStates.slice(),i=Fe(a,e),o=Fe(a,t)>=0;i>=0?o?a.splice(i,1):a[i]=t:n&&!o&&a.push(t),this.useStates(a)},r.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},r.prototype._mergeStates=function(e){for(var t={},n,a=0;a<e.length;a++){var i=e[a];ie(t,i),i.textConfig&&(n=n||{},ie(n,i.textConfig))}return n&&(t.textConfig=n),t},r.prototype._applyStateObj=function(e,t,n,a,i,o){var s=!(t&&a);t&&t.textConfig?(this.textConfig=ie({},a?this.textConfig:n.textConfig),ie(this.textConfig,t.textConfig)):s&&n.textConfig&&(this.textConfig=n.textConfig);for(var l={},u=!1,c=0;c<yw.length;c++){var f=yw[c],d=i&&jre[f];t&&t[f]!=null?d?(u=!0,l[f]=t[f]):this[f]=t[f]:s&&n[f]!=null&&(d?(u=!0,l[f]=n[f]):this[f]=n[f])}if(!i)for(var c=0;c<this.animators.length;c++){var v=this.animators[c],g=v.targetName;v.getLoop()||v.__changeFinalValue(g?(t||n)[g]:t||n)}u&&this._transitionState(e,l,o)},r.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}},r.prototype._detachComponent=function(e){e.__zr&&e.removeSelfFromZr(e.__zr),e.__zr=null,e.__hostTarget=null},r.prototype.getClipPath=function(){return this._clipPath},r.prototype.setClipPath=function(e){this._clipPath&&this._clipPath!==e&&this.removeClipPath(),this._attachComponent(e),this._clipPath=e,this.markRedraw()},r.prototype.removeClipPath=function(){var e=this._clipPath;e&&(this._detachComponent(e),this._clipPath=null,this.markRedraw())},r.prototype.getTextContent=function(){return this._textContent},r.prototype.setTextContent=function(e){var t=this._textContent;t!==e&&(t&&t!==e&&this.removeTextContent(),e.innerTransformable=new jo,this._attachComponent(e),this._textContent=e,this.markRedraw())},r.prototype.setTextConfig=function(e){this.textConfig||(this.textConfig={}),ie(this.textConfig,e),this.markRedraw()},r.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},r.prototype.removeTextContent=function(){var e=this._textContent;e&&(e.innerTransformable=null,this._detachComponent(e),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},r.prototype.getTextGuideLine=function(){return this._textGuide},r.prototype.setTextGuideLine=function(e){this._textGuide&&this._textGuide!==e&&this.removeTextGuideLine(),this._attachComponent(e),this._textGuide=e,this.markRedraw()},r.prototype.removeTextGuideLine=function(){var e=this._textGuide;e&&(this._detachComponent(e),this._textGuide=null,this.markRedraw())},r.prototype.markRedraw=function(){this.__dirty|=ea;var e=this.__zr;e&&(this.__inHover?e.refreshHover():e.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},r.prototype.dirty=function(){this.markRedraw()},r.prototype._toggleHoverLayerFlag=function(e){this.__inHover=e;var t=this._textContent,n=this._textGuide;t&&(t.__inHover=e),n&&(n.__inHover=e)},r.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)}},r.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)}},r.prototype.animate=function(e,t,n){var a=e?this[e]:this,i=new rD(a,t,n);return e&&(i.targetName=e),this.addAnimator(i,e),i},r.prototype.addAnimator=function(e,t){var n=this.__zr,a=this;e.during(function(){a.updateDuringAnimation(t)}).done(function(){var i=a.animators,o=Fe(i,e);o>=0&&i.splice(o,1)}),this.animators.push(e),n&&n.animation.addAnimator(e),n&&n.wakeUp()},r.prototype.updateDuringAnimation=function(e){this.markRedraw()},r.prototype.stopAnimation=function(e,t){for(var n=this.animators,a=n.length,i=[],o=0;o<a;o++){var s=n[o];!e||e===s.scope?s.stop(t):i.push(s)}return this.animators=i,this},r.prototype.animateTo=function(e,t,n){xw(this,e,t,n)},r.prototype.animateFrom=function(e,t,n){xw(this,e,t,n,!0)},r.prototype._transitionState=function(e,t,n,a){for(var i=xw(this,t,n,a),o=0;o<i.length;o++)i[o].__fromStateTransition=e},r.prototype.getBoundingRect=function(){return null},r.prototype.getPaintRect=function(){return null},r.initDefaultProps=(function(){var e=r.prototype;e.type="element",e.name="",e.ignore=e.silent=e.ignoreHostSilent=e.isGroup=e.draggable=e.dragging=e.ignoreClip=e.__inHover=!1,e.__dirty=ea;function t(n,a,i,o){Object.defineProperty(e,n,{get:function(){if(!this[a]){var l=this[a]=[];s(this,l)}return this[a]},set:function(l){this[i]=l[0],this[o]=l[1],this[a]=l,s(this,l)}});function s(l,u){Object.defineProperty(u,0,{get:function(){return l[i]},set:function(c){l[i]=c}}),Object.defineProperty(u,1,{get:function(){return l[o]},set:function(c){l[o]=c}})}}Object.defineProperty&&(t("position","_legacyPos","x","y"),t("scale","_legacyScale","scaleX","scaleY"),t("origin","_legacyOrigin","originX","originY"))})(),r})();Jt(Q1,za);Jt(Q1,jo);function xw(r,e,t,n,a){t=t||{};var i=[];Z6(r,"",r,e,t,n,i,a);var o=i.length,s=!1,l=t.done,u=t.aborted,c=function(){s=!0,o--,o<=0&&(s?l&&l():u&&u())},f=function(){o--,o<=0&&(s?l&&l():u&&u())};o||l&&l(),i.length>0&&t.during&&i[0].during(function(g,y){t.during(y)});for(var d=0;d<i.length;d++){var v=i[d];c&&v.done(c),f&&v.aborted(f),t.force&&v.duration(t.duration),v.start(t.easing)}return i}function bw(r,e,t){for(var n=0;n<t;n++)r[n]=e[n]}function Bre(r){return tn(r[0])}function Vre(r,e,t){if(tn(e[t]))if(tn(r[t])||(r[t]=[]),Tn(e[t])){var n=e[t].length;r[t].length!==n&&(r[t]=new e[t].constructor(n),bw(r[t],e[t],n))}else{var a=e[t],i=r[t],o=a.length;if(Bre(a))for(var s=a[0].length,l=0;l<o;l++)i[l]?bw(i[l],a[l],s):i[l]=Array.prototype.slice.call(a[l]);else bw(i,a,o);i.length=a.length}else r[t]=e[t]}function Gre(r,e){return r===e||tn(r)&&tn(e)&&Hre(r,e)}function Hre(r,e){var t=r.length;if(t!==e.length)return!1;for(var n=0;n<t;n++)if(r[n]!==e[n])return!1;return!0}function Z6(r,e,t,n,a,i,o,s){for(var l=it(n),u=a.duration,c=a.delay,f=a.additive,d=a.setToFinal,v=!Ee(i),g=r.animators,y=[],x=0;x<l.length;x++){var b=l[x],w=n[b];if(w!=null&&t[b]!=null&&(v||i[b]))if(Ee(w)&&!tn(w)&&!zg(w)){if(e){s||(t[b]=w,r.updateDuringAnimation(e));continue}Z6(r,b,t[b],w,a,i&&i[b],o,s)}else y.push(b);else s||(t[b]=w,r.updateDuringAnimation(e),y.push(b))}var T=y.length;if(!f&&T)for(var C=0;C<g.length;C++){var D=g[C];if(D.targetName===e){var M=D.stopTracks(y);if(M){var N=Fe(g,D);g.splice(N,1)}}}if(a.force||(y=dt(y,function(I){return!Gre(n[I],t[I])}),T=y.length),T>0||a.force&&!o.length){var R=void 0,E=void 0,k=void 0;if(s){E={},d&&(R={});for(var C=0;C<T;C++){var b=y[C];E[b]=t[b],d?R[b]=n[b]:t[b]=n[b]}}else if(d){k={};for(var C=0;C<T;C++){var b=y[C];k[b]=Np(t[b]),Vre(t,n,b)}}var D=new rD(t,!1,!1,f?dt(g,function(B){return B.targetName===e}):null);D.targetName=e,a.scope&&(D.scope=a.scope),d&&R&&D.whenWithKeys(0,R,y),k&&D.whenWithKeys(0,k,y),D.whenWithKeys(u??500,s?E:n,y).delay(c||0),r.addAnimator(D,e),o.push(D)}}var Ne=(function(r){K(e,r);function e(t){var n=r.call(this)||this;return n.isGroup=!0,n._children=[],n.attr(t),n}return e.prototype.childrenRef=function(){return this._children},e.prototype.children=function(){return this._children.slice()},e.prototype.childAt=function(t){return this._children[t]},e.prototype.childOfName=function(t){for(var n=this._children,a=0;a<n.length;a++)if(n[a].name===t)return n[a]},e.prototype.childCount=function(){return this._children.length},e.prototype.add=function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},e.prototype.addBefore=function(t,n){if(t&&t!==this&&t.parent!==this&&n&&n.parent===this){var a=this._children,i=a.indexOf(n);i>=0&&(a.splice(i,0,t),this._doAdd(t))}return this},e.prototype.replace=function(t,n){var a=Fe(this._children,t);return a>=0&&this.replaceAt(n,a),this},e.prototype.replaceAt=function(t,n){var a=this._children,i=a[n];if(t&&t!==this&&t.parent!==this&&t!==i){a[n]=t,i.parent=null;var o=this.__zr;o&&i.removeSelfFromZr(o),this._doAdd(t)}return this},e.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var n=this.__zr;n&&n!==t.__zr&&t.addSelfToZr(n),n&&n.refresh()},e.prototype.remove=function(t){var n=this.__zr,a=this._children,i=Fe(a,t);return i<0?this:(a.splice(i,1),t.parent=null,n&&t.removeSelfFromZr(n),n&&n.refresh(),this)},e.prototype.removeAll=function(){for(var t=this._children,n=this.__zr,a=0;a<t.length;a++){var i=t[a];n&&i.removeSelfFromZr(n),i.parent=null}return t.length=0,this},e.prototype.eachChild=function(t,n){for(var a=this._children,i=0;i<a.length;i++){var o=a[i];t.call(n,o,i)}return this},e.prototype.traverse=function(t,n){for(var a=0;a<this._children.length;a++){var i=this._children[a],o=t.call(n,i);i.isGroup&&!o&&i.traverse(t,n)}return this},e.prototype.addSelfToZr=function(t){r.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++){var a=this._children[n];a.addSelfToZr(t)}},e.prototype.removeSelfFromZr=function(t){r.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++){var a=this._children[n];a.removeSelfFromZr(t)}},e.prototype.getBoundingRect=function(t){for(var n=new Oe(0,0,0,0),a=t||this._children,i=[],o=null,s=0;s<a.length;s++){var l=a[s];if(!(l.ignore||l.invisible)){var u=l.getBoundingRect(),c=l.getLocalTransform(i);c?(Oe.applyTransform(n,u,c),o=o||n.clone(),o.union(n)):(o=o||u.clone(),o.union(u))}}return o||n},e})(Q1);Ne.prototype.type="group";/*!
258
- * ZRender, a high performance 2d drawing library.
259
- *
260
- * Copyright (c) 2013, Baidu Inc.
261
- * All rights reserved.
262
- *
263
- * LICENSE
264
- * https://github.com/ecomfe/zrender/blob/master/LICENSE.txt
265
- */var K0={},zu={};function Fre(r){delete zu[r]}function Ure(r){if(!r)return!1;if(typeof r=="string")return Qp(r,1)<wC;if(r.colorStops){for(var e=r.colorStops,t=0,n=e.length,a=0;a<n;a++)t+=Qp(e[a].color,1);return t/=n,t<wC}return!1}var Yre=(function(){function r(e,t,n){var a=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,n=n||{},this.dom=t,this.id=e;var i=new tre,o=n.renderer||"canvas";K0[o]||(o=it(K0)[0]),n.useDirtyRect=n.useDirtyRect==null?!1:n.useDirtyRect;var s=new K0[o](t,i,n,e),l=n.ssr||s.ssrOnly;this.storage=i,this.painter=s;var u=!nt.node&&!nt.worker&&!l?new Ire(s.getViewportRoot(),s.root):null,c=n.useCoarsePointer,f=c==null||c==="auto"?nt.touchEventsSupported:!!c,d=44,v;f&&(v=Ce(n.pointerSize,d)),this.handler=new D6(i,s,u,s.root,v),this.animation=new Mre({stage:{update:l?null:function(){return a._flush(!0)}}}),l||this.animation.start()}return r.prototype.add=function(e){this._disposed||!e||(this.storage.addRoot(e),e.addSelfToZr(this),this.refresh())},r.prototype.remove=function(e){this._disposed||!e||(this.storage.delRoot(e),e.removeSelfFromZr(this),this.refresh())},r.prototype.configLayer=function(e,t){this._disposed||(this.painter.configLayer&&this.painter.configLayer(e,t),this.refresh())},r.prototype.setBackgroundColor=function(e){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(e),this.refresh(),this._backgroundColor=e,this._darkMode=Ure(e))},r.prototype.getBackgroundColor=function(){return this._backgroundColor},r.prototype.setDarkMode=function(e){this._darkMode=e},r.prototype.isDarkMode=function(){return this._darkMode},r.prototype.refreshImmediately=function(e){this._disposed||(e||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1)},r.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},r.prototype.flush=function(){this._disposed||this._flush(!1)},r.prototype._flush=function(e){var t,n=Jf();this._needsRefresh&&(t=!0,this.refreshImmediately(e)),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately());var a=Jf();t?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:a-n})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},r.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},r.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},r.prototype.refreshHover=function(){this._needsRefreshHover=!0},r.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover())},r.prototype.resize=function(e){this._disposed||(e=e||{},this.painter.resize(e.width,e.height),this.handler.resize())},r.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},r.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},r.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},r.prototype.setCursorStyle=function(e){this._disposed||this.handler.setCursorStyle(e)},r.prototype.findHover=function(e,t){if(!this._disposed)return this.handler.findHover(e,t)},r.prototype.on=function(e,t,n){return this._disposed||this.handler.on(e,t,n),this},r.prototype.off=function(e,t){this._disposed||this.handler.off(e,t)},r.prototype.trigger=function(e,t){this._disposed||this.handler.trigger(e,t)},r.prototype.clear=function(){if(!this._disposed){for(var e=this.storage.getRoots(),t=0;t<e.length;t++)e[t]instanceof Ne&&e[t].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},r.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,Fre(this.id))},r})();function AC(r,e){var t=new Yre(qM(),r,e);return zu[t.id]=t,t}function Wre(r){r.dispose()}function Xre(){for(var r in zu)zu.hasOwnProperty(r)&&zu[r].dispose();zu={}}function qre(r){return zu[r]}function $6(r,e){K0[r]=e}var MC;function K6(r){if(typeof MC=="function")return MC(r)}function Q6(r){MC=r}var Zre="6.0.0";const $re=Object.freeze(Object.defineProperty({__proto__:null,dispose:Wre,disposeAll:Xre,getElementSSRData:K6,getInstance:qre,init:AC,registerPainter:$6,registerSSRDataGetter:Q6,version:Zre},Symbol.toStringTag,{value:"Module"}));var KO=1e-4,J6=20;function Kre(r){return r.replace(/^\s+|\s+$/g,"")}var sa=Math.min,or=Math.max,Pi=Math.abs;function pt(r,e,t,n){var a=e[0],i=e[1],o=t[0],s=t[1],l=i-a,u=s-o;if(l===0)return u===0?o:(o+s)/2;if(n)if(l>0){if(r<=a)return o;if(r>=i)return s}else{if(r>=a)return o;if(r<=i)return s}else{if(r===a)return o;if(r===i)return s}return(r-a)/l*u+o}var me=Qre;function Qre(r,e,t){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return Px(r,e,t)}function Px(r,e,t){return ye(r)?Kre(r).match(/%$/)?parseFloat(r)/100*e+(t||0):parseFloat(r):r==null?NaN:+r}function sr(r,e,t){return e==null&&(e=10),e=Math.min(Math.max(0,e),J6),r=(+r).toFixed(e),t?r:+r}function na(r){return r.sort(function(e,t){return e-t}),r}function Ka(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var e=1,t=0;t<15;t++,e*=10)if(Math.round(r*e)/e===r)return t}return eH(r)}function eH(r){var e=r.toString().toLowerCase(),t=e.indexOf("e"),n=t>0?+e.slice(t+1):0,a=t>0?t:e.length,i=e.indexOf("."),o=i<0?0:a-1-i;return Math.max(0,o-n)}function nD(r,e){var t=Math.log,n=Math.LN10,a=Math.floor(t(r[1]-r[0])/n),i=Math.round(t(Pi(e[1]-e[0]))/n),o=Math.min(Math.max(-a+i,0),20);return isFinite(o)?o:20}function Jre(r,e,t){if(!r[e])return 0;var n=tH(r,t);return n[e]||0}function tH(r,e){var t=Ia(r,function(v,g){return v+(isNaN(g)?0:g)},0);if(t===0)return[];for(var n=Math.pow(10,e),a=fe(r,function(v){return(isNaN(v)?0:v)/t*n*100}),i=n*100,o=fe(a,function(v){return Math.floor(v)}),s=Ia(o,function(v,g){return v+g},0),l=fe(a,function(v,g){return v-o[g]});s<i;){for(var u=Number.NEGATIVE_INFINITY,c=null,f=0,d=l.length;f<d;++f)l[f]>u&&(u=l[f],c=f);++o[c],l[c]=0,++s}return fe(o,function(v){return v/n})}function ene(r,e){var t=Math.max(Ka(r),Ka(e)),n=r+e;return t>J6?n:sr(n,t)}var DC=9007199254740991;function aD(r){var e=Math.PI*2;return(r%e+e)%e}function kh(r){return r>-KO&&r<KO}var tne=/^(?:(\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 Ji(r){if(r instanceof Date)return r;if(ye(r)){var e=tne.exec(r);if(!e)return new Date(NaN);if(e[8]){var t=+e[4]||0;return e[8].toUpperCase()!=="Z"&&(t-=+e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,t,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0))}else return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0)}else if(r==null)return new Date(NaN);return new Date(Math.round(r))}function rH(r){return Math.pow(10,J1(r))}function J1(r){if(r===0)return 0;var e=Math.floor(Math.log(r)/Math.LN10);return r/Math.pow(10,e)>=10&&e++,e}function iD(r,e){var t=J1(r),n=Math.pow(10,t),a=r/n,i;return e?a<1.5?i=1:a<2.5?i=2:a<4?i=3:a<7?i=5:i=10:a<1?i=1:a<2?i=2:a<3?i=3:a<5?i=5:i=10,r=i*n,t>=-20?+r.toFixed(t<0?-t:0):r}function Q0(r,e){var t=(r.length-1)*e+1,n=Math.floor(t),a=+r[n-1],i=t-n;return i?a+i*(r[n]-a):a}function NC(r){r.sort(function(l,u){return s(l,u,0)?-1:1});for(var e=-1/0,t=1,n=0;n<r.length;){for(var a=r[n].interval,i=r[n].close,o=0;o<2;o++)a[o]<=e&&(a[o]=e,i[o]=o?1:1-t),e=a[o],t=i[o];a[0]===a[1]&&i[0]*i[1]!==1?r.splice(n,1):n++}return r;function s(l,u,c){return l.interval[c]<u.interval[c]||l.interval[c]===u.interval[c]&&(l.close[c]-u.close[c]===(c?-1:1)||!c&&s(l,u,1))}}function Xi(r){var e=parseFloat(r);return e==r&&(e!==0||!ye(r)||r.indexOf("x")<=0)?e:NaN}function oD(r){return!isNaN(Xi(r))}function nH(){return Math.round(Math.random()*9)}function aH(r,e){return e===0?r:aH(e,r%e)}function QO(r,e){return r==null?e:e==null?r:r*e/aH(r,e)}var rne="[ECharts] ",nne=typeof console<"u"&&console.warn&&console.log;function ane(r,e,t){nne&&console[r](rne+e)}function iH(r,e){ane("error",r)}function gt(r){throw new Error(r)}function JO(r,e,t){return(e-r)*t+r}var oH="series\0",sH="\0_ec_\0";function Lt(r){return r instanceof Array?r:r==null?[]:[r]}function lc(r,e,t){if(r){r[e]=r[e]||{},r.emphasis=r.emphasis||{},r.emphasis[e]=r.emphasis[e]||{};for(var n=0,a=t.length;n<a;n++){var i=t[n];!r.emphasis[e].hasOwnProperty(i)&&r[e].hasOwnProperty(i)&&(r.emphasis[e][i]=r[e][i])}}}var eP=["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"];function Qh(r){return Ee(r)&&!ce(r)&&!(r instanceof Date)?r.value:r}function ine(r){return Ee(r)&&!(r instanceof Array)}function lH(r,e,t){var n=t==="normalMerge",a=t==="replaceMerge",i=t==="replaceAll";r=r||[],e=(e||[]).slice();var o=Te();O(e,function(l,u){if(!Ee(l)){e[u]=null;return}});var s=one(r,o,t);return(n||a)&&sne(s,r,o,e),n&&lne(s,e),n||a?une(s,e,a):i&&cne(s,e),fne(s),s}function one(r,e,t){var n=[];if(t==="replaceAll")return n;for(var a=0;a<r.length;a++){var i=r[a];i&&i.id!=null&&e.set(i.id,a),n.push({existing:t==="replaceMerge"||eg(i)?null:i,newOption:null,keyInfo:null,brandNew:null})}return n}function sne(r,e,t,n){O(n,function(a,i){if(!(!a||a.id==null)){var o=Lp(a.id),s=t.get(o);if(s!=null){var l=r[s];rn(!l.newOption,'Duplicated option on id "'+o+'".'),l.newOption=a,l.existing=e[s],n[i]=null}}})}function lne(r,e){O(e,function(t,n){if(!(!t||t.name==null))for(var a=0;a<r.length;a++){var i=r[a].existing;if(!r[a].newOption&&i&&(i.id==null||t.id==null)&&!eg(t)&&!eg(i)&&uH("name",i,t)){r[a].newOption=t,e[n]=null;return}}})}function une(r,e,t){O(e,function(n){if(n){for(var a,i=0;(a=r[i])&&(a.newOption||eg(a.existing)||a.existing&&n.id!=null&&!uH("id",n,a.existing));)i++;a?(a.newOption=n,a.brandNew=t):r.push({newOption:n,brandNew:t,existing:null,keyInfo:null}),i++}})}function cne(r,e){O(e,function(t){r.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function fne(r){var e=Te();O(r,function(t){var n=t.existing;n&&e.set(n.id,t)}),O(r,function(t){var n=t.newOption;rn(!n||n.id==null||!e.get(n.id)||e.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&n.id!=null&&e.set(n.id,t),!t.keyInfo&&(t.keyInfo={})}),O(r,function(t,n){var a=t.existing,i=t.newOption,o=t.keyInfo;if(Ee(i)){if(o.name=i.name!=null?Lp(i.name):a?a.name:oH+n,a)o.id=Lp(a.id);else if(i.id!=null)o.id=Lp(i.id);else{var s=0;do o.id="\0"+o.name+"\0"+s++;while(e.get(o.id))}e.set(o.id,t)}})}function uH(r,e,t){var n=xr(e[r],null),a=xr(t[r],null);return n!=null&&a!=null&&n===a}function Lp(r){return xr(r,"")}function xr(r,e){return r==null?e:ye(r)?r:st(r)||Sx(r)?r+"":e}function sD(r){var e=r.name;return!!(e&&e.indexOf(oH))}function eg(r){return r&&r.id!=null&&Lp(r.id).indexOf(sH)===0}function hne(r){return sH+r}function dne(r,e,t){O(r,function(n){var a=n.newOption;Ee(a)&&(n.keyInfo.mainType=e,n.keyInfo.subType=vne(e,a,n.existing,t))})}function vne(r,e,t,n){var a=e.type?e.type:t?t.subType:n.determineSubType(r,e);return a}function pne(r,e){var t={},n={};return a(r||[],t),a(e||[],n,t),[i(t),i(n)];function a(o,s,l){for(var u=0,c=o.length;u<c;u++){var f=xr(o[u].seriesId,null);if(f==null)return;for(var d=Lt(o[u].dataIndex),v=l&&l[f],g=0,y=d.length;g<y;g++){var x=d[g];v&&v[x]?v[x]=null:(s[f]||(s[f]={}))[x]=1}}}function i(o,s){var l=[];for(var u in o)if(o.hasOwnProperty(u)&&o[u]!=null)if(s)l.push(+u);else{var c=i(o[u],!0);c.length&&l.push({seriesId:u,dataIndex:c})}return l}}function uc(r,e){if(e.dataIndexInside!=null)return e.dataIndexInside;if(e.dataIndex!=null)return ce(e.dataIndex)?fe(e.dataIndex,function(t){return r.indexOfRawIndex(t)}):r.indexOfRawIndex(e.dataIndex);if(e.name!=null)return ce(e.name)?fe(e.name,function(t){return r.indexOfName(t)}):r.indexOfName(e.name)}function Je(){var r="__ec_inner_"+gne++;return function(e){return e[r]||(e[r]={})}}var gne=nH();function fh(r,e,t){var n=lD(e,t),a=n.mainTypeSpecified,i=n.queryOptionMap,o=n.others,s=o,l=t?t.defaultMainType:null;return!a&&l&&i.set(l,{}),i.each(function(u,c){var f=Jh(r,c,u,{useDefault:l===c,enableAll:t&&t.enableAll!=null?t.enableAll:!0,enableNone:t&&t.enableNone!=null?t.enableNone:!0});s[c+"Models"]=f.models,s[c+"Model"]=f.models[0]}),s}function lD(r,e){var t;if(ye(r)){var n={};n[r+"Index"]=0,t=n}else t=r;var a=Te(),i={},o=!1;return O(t,function(s,l){if(l==="dataIndex"||l==="dataIndexInside"){i[l]=s;return}var u=l.match(/^(\w+)(Index|Id|Name)$/)||[],c=u[1],f=(u[2]||"").toLowerCase();if(!(!c||!f||e&&e.includeMainTypes&&Fe(e.includeMainTypes,c)<0)){o=o||!!c;var d=a.get(c)||a.set(c,{});d[f]=s}}),{mainTypeSpecified:o,queryOptionMap:a,others:i}}var Zt={useDefault:!0,enableAll:!1,enableNone:!1},mne={useDefault:!1,enableAll:!0,enableNone:!0};function Jh(r,e,t,n){n=n||Zt;var a=t.index,i=t.id,o=t.name,s={models:null,specified:a!=null||i!=null||o!=null};if(!s.specified){var l=void 0;return s.models=n.useDefault&&(l=r.getComponent(e))?[l]:[],s}if(a==="none"||a===!1){if(n.enableNone)return s.models=[],s;a=-1}return a==="all"&&(n.enableAll?a=i=o=null:a=-1),s.models=r.queryComponents({mainType:e,index:a,id:i,name:o}),s}function cH(r,e,t){r.setAttribute?r.setAttribute(e,t):r[e]=t}function yne(r,e){return r.getAttribute?r.getAttribute(e):r[e]}function xne(r){return r==="auto"?nt.domSupported?"html":"richText":r||"html"}function LC(r,e){var t=Te(),n=[];return O(r,function(a){var i=e(a);(t.get(i)||(n.push(i),t.set(i,[]))).push(a)}),{keys:n,buckets:t}}function fH(r,e,t,n,a){var i=e==null||e==="auto";if(n==null)return n;if(st(n)){var o=JO(t||0,n,a);return sr(o,i?Math.max(Ka(t||0),Ka(n)):e)}else{if(ye(n))return a<1?t:n;for(var s=[],l=t,u=n,c=Math.max(l?l.length:0,u.length),f=0;f<c;++f){var d=r.getDimensionInfo(f);if(d&&d.type==="ordinal")s[f]=(a<1&&l?l:u)[f];else{var v=l&&l[f]?l[f]:0,g=u[f],o=JO(v,g,a);s[f]=sr(o,i?Math.max(Ka(v),Ka(g)):e)}}return s}}var fl=(function(){function r(){}return r.prototype.reset=function(e,t,n,a){return this._list=e,this._step=a=a||1,this._idx=t,this._end=n??(a>0?e.length:0),this.item=null,this.key=NaN,this},r.prototype.next=function(){return(this._step>0?this._idx<this._end:this._idx>=this._end)?(this.item=this._list[this._idx],this.key=this._idx=this._idx+this._step,!0):!1},r})();function _w(r){r.option=r.parentModel=r.ecModel=null}var bne=".",iu="___EC__COMPONENT__CONTAINER___",hH="___EC__EXTENDED_CLASS___";function ji(r){var e={main:"",sub:""};if(r){var t=r.split(bne);e.main=t[0]||"",e.sub=t[1]||""}return e}function _ne(r){rn(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(r),'componentType "'+r+'" illegal')}function Sne(r){return!!(r&&r[hH])}function uD(r,e){r.$constructor=r,r.extend=function(t){var n=this,a;return wne(n)?a=(function(i){K(o,i);function o(){return i.apply(this,arguments)||this}return o})(n):(a=function(){(t.$constructor||n).apply(this,arguments)},ZM(a,this)),ie(a.prototype,t),a[hH]=!0,a.extend=this.extend,a.superCall=Ane,a.superApply=Mne,a.superClass=n,a}}function wne(r){return Me(r)&&/^class\s/.test(Function.prototype.toString.call(r))}function dH(r,e){r.extend=e.extend}var Tne=Math.round(Math.random()*10);function Cne(r){var e=["__\0is_clz",Tne++].join("_");r.prototype[e]=!0,r.isInstance=function(t){return!!(t&&t[e])}}function Ane(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];return this.superClass.prototype[e].apply(r,t)}function Mne(r,e,t){return this.superClass.prototype[e].apply(r,t)}function eb(r){var e={};r.registerClass=function(n){var a=n.type||n.prototype.type;if(a){_ne(a),n.prototype.type=a;var i=ji(a);if(!i.sub)e[i.main]=n;else if(i.sub!==iu){var o=t(i);o[i.sub]=n}}return n},r.getClass=function(n,a,i){var o=e[n];if(o&&o[iu]&&(o=a?o[a]:null),i&&!o)throw new Error(a?"Component "+n+"."+(a||"")+" is used but not imported.":n+".type should be specified.");return o},r.getClassesByMainType=function(n){var a=ji(n),i=[],o=e[a.main];return o&&o[iu]?O(o,function(s,l){l!==iu&&i.push(s)}):i.push(o),i},r.hasClass=function(n){var a=ji(n);return!!e[a.main]},r.getAllClassMainTypes=function(){var n=[];return O(e,function(a,i){n.push(i)}),n},r.hasSubTypes=function(n){var a=ji(n),i=e[a.main];return i&&i[iu]};function t(n){var a=e[n.main];return(!a||!a[iu])&&(a=e[n.main]={},a[iu]=!0),a}}function cc(r,e){for(var t=0;t<r.length;t++)r[t][1]||(r[t][1]=r[t][0]);return e=e||!1,function(n,a,i){for(var o={},s=0;s<r.length;s++){var l=r[s][1];if(!(a&&Fe(a,l)>=0||i&&Fe(i,l)<0)){var u=n.getShallow(l,e);u!=null&&(o[r[s][0]]=u)}}return o}}var Dne=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],Nne=cc(Dne),Lne=(function(){function r(){}return r.prototype.getAreaStyle=function(e,t){return Nne(this,e,t)},r})(),RC=new Rh(50);function Rne(r){if(typeof r=="string"){var e=RC.get(r);return e&&e.image}else return r}function cD(r,e,t,n,a){if(r)if(typeof r=="string"){if(e&&e.__zrImageSrc===r||!t)return e;var i=RC.get(r),o={hostEl:t,cb:n,cbPayload:a};return i?(e=i.image,!tb(e)&&i.pending.push(o)):(e=Bn.loadImage(r,tP,tP),e.__zrImageSrc=r,RC.put(r,e.__cachedImgObj={image:e,pending:[o]})),e}else return r;else return e}function tP(){var r=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e<r.pending.length;e++){var t=r.pending[e],n=t.cb;n&&n(this,t.cbPayload),t.hostEl.dirty()}r.pending.length=0}function tb(r){return r&&r.width&&r.height}var Sw=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function Ene(r,e,t,n,a){var i={};return vH(i,r,e,t,n,a),i.text}function vH(r,e,t,n,a,i){if(!t){r.text="",r.isTruncated=!1;return}var o=(e+"").split(`
266
- `);i=pH(t,n,a,i);for(var s=!1,l={},u=0,c=o.length;u<c;u++)gH(l,o[u],i),o[u]=l.textLine,s=s||l.isTruncated;r.text=o.join(`
267
- `),r.isTruncated=s}function pH(r,e,t,n){n=n||{};var a=ie({},n);t=Ce(t,"..."),a.maxIterations=Ce(n.maxIterations,2);var i=a.minChar=Ce(n.minChar,0),o=a.fontMeasureInfo=Fi(e),s=o.asciiCharWidth;a.placeholder=Ce(n.placeholder,"");for(var l=r=Math.max(0,r-1),u=0;u<i&&l>=s;u++)l-=s;var c=Ui(o,t);return c>l&&(t="",c=0),l=r-c,a.ellipsis=t,a.ellipsisWidth=c,a.contentWidth=l,a.containerWidth=r,a}function gH(r,e,t){var n=t.containerWidth,a=t.contentWidth,i=t.fontMeasureInfo;if(!n){r.textLine="",r.isTruncated=!1;return}var o=Ui(i,e);if(o<=n){r.textLine=e,r.isTruncated=!1;return}for(var s=0;;s++){if(o<=a||s>=t.maxIterations){e+=t.ellipsis;break}var l=s===0?kne(e,a,i):o>0?Math.floor(e.length*a/o):0;e=e.substr(0,l),o=Ui(i,e)}e===""&&(e=t.placeholder),r.textLine=e,r.isTruncated=!0}function kne(r,e,t){for(var n=0,a=0,i=r.length;a<i&&n<e;a++)n+=q6(t,r.charCodeAt(a));return a}function Ine(r,e,t,n){var a=fD(r),i=e.overflow,o=e.padding,s=o?o[1]+o[3]:0,l=o?o[0]+o[2]:0,u=e.font,c=i==="truncate",f=Fg(u),d=Ce(e.lineHeight,f),v=e.lineOverflow==="truncate",g=!1,y=e.width;y==null&&t!=null&&(y=t-s);var x=e.height;x==null&&n!=null&&(x=n-l);var b;y!=null&&(i==="break"||i==="breakAll")?b=a?mH(a,e.font,y,i==="breakAll",0).lines:[]:b=a?a.split(`
268
- `):[];var w=b.length*d;if(x==null&&(x=w),w>x&&v){var T=Math.floor(x/d);g=g||b.length>T,b=b.slice(0,T),w=b.length*d}if(a&&c&&y!=null)for(var C=pH(y,u,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),D={},M=0;M<b.length;M++)gH(D,b[M],C),b[M]=D.textLine,g=g||D.isTruncated;for(var N=x,R=0,E=Fi(u),M=0;M<b.length;M++)R=Math.max(Ui(E,b[M]),R);y==null&&(y=R);var k=y;return N+=l,k+=s,{lines:b,height:x,outerWidth:k,outerHeight:N,lineHeight:d,calculatedLineHeight:f,contentWidth:R,contentHeight:w,width:y,isTruncated:g}}var One=(function(){function r(){}return r})(),rP=(function(){function r(e){this.tokens=[],e&&(this.tokens=e)}return r})(),Pne=(function(){function r(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return r})();function jne(r,e,t,n,a){var i=new Pne,o=fD(r);if(!o)return i;var s=e.padding,l=s?s[1]+s[3]:0,u=s?s[0]+s[2]:0,c=e.width;c==null&&t!=null&&(c=t-l);var f=e.height;f==null&&n!=null&&(f=n-u);for(var d=e.overflow,v=(d==="break"||d==="breakAll")&&c!=null?{width:c,accumWidth:0,breakAll:d==="breakAll"}:null,g=Sw.lastIndex=0,y;(y=Sw.exec(o))!=null;){var x=y.index;x>g&&ww(i,o.substring(g,x),e,v),ww(i,y[2],e,v,y[1]),g=Sw.lastIndex}g<o.length&&ww(i,o.substring(g,o.length),e,v);var b=[],w=0,T=0,C=d==="truncate",D=e.lineOverflow==="truncate",M={};function N(Se,Xe,be){Se.width=Xe,Se.lineHeight=be,w+=be,T=Math.max(T,Xe)}e:for(var R=0;R<i.lines.length;R++){for(var E=i.lines[R],k=0,I=0,B=0;B<E.tokens.length;B++){var P=E.tokens[B],H=P.styleName&&e.rich[P.styleName]||{},V=P.textPadding=H.padding,j=V?V[1]+V[3]:0,U=P.font=H.font||e.font;P.contentHeight=Fg(U);var F=Ce(H.height,P.contentHeight);if(P.innerHeight=F,V&&(F+=V[0]+V[2]),P.height=F,P.lineHeight=zn(H.lineHeight,e.lineHeight,F),P.align=H&&H.align||a,P.verticalAlign=H&&H.verticalAlign||"middle",D&&f!=null&&w+P.lineHeight>f){var X=i.lines.length;B>0?(E.tokens=E.tokens.slice(0,B),N(E,I,k),i.lines=i.lines.slice(0,R+1)):i.lines=i.lines.slice(0,R),i.isTruncated=i.isTruncated||i.lines.length<X;break e}var G=H.width,W=G==null||G==="auto";if(typeof G=="string"&&G.charAt(G.length-1)==="%")P.percentWidth=G,b.push(P),P.contentWidth=Ui(Fi(U),P.text);else{if(W){var $=H.backgroundColor,te=$&&$.image;te&&(te=Rne(te),tb(te)&&(P.width=Math.max(P.width,te.width*F/te.height)))}var ue=C&&c!=null?c-I:null;ue!=null&&ue<P.width?!W||ue<j?(P.text="",P.width=P.contentWidth=0):(vH(M,P.text,ue-j,U,e.ellipsis,{minChar:e.truncateMinChar}),P.text=M.text,i.isTruncated=i.isTruncated||M.isTruncated,P.width=P.contentWidth=Ui(Fi(U),P.text)):P.contentWidth=Ui(Fi(U),P.text)}P.width+=j,I+=P.width,H&&(k=Math.max(k,P.lineHeight))}N(E,I,k)}i.outerWidth=i.width=Ce(c,T),i.outerHeight=i.height=Ce(f,w),i.contentHeight=w,i.contentWidth=T,i.outerWidth+=l,i.outerHeight+=u;for(var R=0;R<b.length;R++){var P=b[R],ge=P.percentWidth;P.width=parseInt(ge,10)/100*i.width}return i}function ww(r,e,t,n,a){var i=e==="",o=a&&t.rich[a]||{},s=r.lines,l=o.font||t.font,u=!1,c,f;if(n){var d=o.padding,v=d?d[1]+d[3]:0;if(o.width!=null&&o.width!=="auto"){var g=oi(o.width,n.width)+v;s.length>0&&g+n.accumWidth>n.width&&(c=e.split(`
269
- `),u=!0),n.accumWidth=g}else{var y=mH(e,l,n.width,n.breakAll,n.accumWidth);n.accumWidth=y.accumWidth+v,f=y.linesWidths,c=y.lines}}c||(c=e.split(`
270
- `));for(var x=Fi(l),b=0;b<c.length;b++){var w=c[b],T=new One;if(T.styleName=a,T.text=w,T.isLineHolder=!w&&!i,typeof o.width=="number"?T.width=o.width:T.width=f?f[b]:Ui(x,w),!b&&!u){var C=(s[s.length-1]||(s[0]=new rP)).tokens,D=C.length;D===1&&C[0].isLineHolder?C[0]=T:(w||!D||i)&&C.push(T)}else s.push(new rP([T]))}}function zne(r){var e=r.charCodeAt(0);return e>=32&&e<=591||e>=880&&e<=4351||e>=4608&&e<=5119||e>=7680&&e<=8303}var Bne=Ia(",&?/;] ".split(""),function(r,e){return r[e]=!0,r},{});function Vne(r){return zne(r)?!!Bne[r]:!0}function mH(r,e,t,n,a){for(var i=[],o=[],s="",l="",u=0,c=0,f=Fi(e),d=0;d<r.length;d++){var v=r.charAt(d);if(v===`
271
- `){l&&(s+=l,c+=u),i.push(s),o.push(c),s="",l="",u=0,c=0;continue}var g=q6(f,v.charCodeAt(0)),y=n?!1:!Vne(v);if(i.length?c+g>t:a+c+g>t){c?(s||l)&&(y?(s||(s=l,l="",u=0,c=u),i.push(s),o.push(c-u),l+=v,u+=g,s="",c=u):(l&&(s+=l,l="",u=0),i.push(s),o.push(c),s=v,c=g)):y?(i.push(l),o.push(u),l=v,u=g):(i.push(v),o.push(g));continue}c+=g,y?(l+=v,u+=g):(l&&(s+=l,l="",u=0),s+=v)}return l&&(s+=l),s&&(i.push(s),o.push(c)),i.length===1&&(c+=a),{accumWidth:c,lines:i,linesWidths:o}}function nP(r,e,t,n,a,i){if(r.baseX=t,r.baseY=n,r.outerWidth=r.outerHeight=null,!!e){var o=e.width*2,s=e.height*2;Oe.set(aP,Eh(t,o,a),Ju(n,s,i),o,s),Oe.intersect(e,aP,null,iP);var l=iP.outIntersectRect;r.outerWidth=l.width,r.outerHeight=l.height,r.baseX=Eh(l.x,l.width,a,!0),r.baseY=Ju(l.y,l.height,i,!0)}}var aP=new Oe(0,0,0,0),iP={outIntersectRect:{},clamp:!0};function fD(r){return r!=null?r+="":r=""}function Gne(r){var e=fD(r.text),t=r.font,n=Ui(Fi(t),e),a=Fg(t);return EC(r,n,a,null)}function EC(r,e,t,n){var a=new Oe(Eh(r.x||0,e,r.textAlign),Ju(r.y||0,t,r.textBaseline),e,t),i=n??(yH(r)?r.lineWidth:0);return i>0&&(a.x-=i/2,a.y-=i/2,a.width+=i,a.height+=i),a}function yH(r){var e=r.stroke;return e!=null&&e!=="none"&&r.lineWidth>0}var kC="__zr_style_"+Math.round(Math.random()*10),ec={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},rb={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};ec[kC]=!0;var oP=["z","z2","invisible"],Hne=["invisible"],Pa=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype._init=function(t){for(var n=it(t),a=0;a<n.length;a++){var i=n[a];i==="style"?this.useStyle(t[i]):r.prototype.attrKV.call(this,i,t[i])}this.style||this.useStyle({})},e.prototype.beforeBrush=function(){},e.prototype.afterBrush=function(){},e.prototype.innerBeforeBrush=function(){},e.prototype.innerAfterBrush=function(){},e.prototype.shouldBePainted=function(t,n,a,i){var o=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&Fne(this,t,n)||o&&!o[0]&&!o[3])return!1;if(a&&this.__clipPaths&&this.__clipPaths.length){for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1}if(i&&this.parent)for(var l=this.parent;l;){if(l.ignore)return!1;l=l.parent}return!0},e.prototype.contain=function(t,n){return this.rectContain(t,n)},e.prototype.traverse=function(t,n){t.call(n,this)},e.prototype.rectContain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();return i.contain(a[0],a[1])},e.prototype.getPaintRect=function(){var t=this._paintRect;if(!this._paintRect||this.__dirty){var n=this.transform,a=this.getBoundingRect(),i=this.style,o=i.shadowBlur||0,s=i.shadowOffsetX||0,l=i.shadowOffsetY||0;t=this._paintRect||(this._paintRect=new Oe(0,0,0,0)),n?Oe.applyTransform(t,a,n):t.copy(a),(o||s||l)&&(t.width+=o*2+Math.abs(s),t.height+=o*2+Math.abs(l),t.x=Math.min(t.x,t.x+s-o),t.y=Math.min(t.y,t.y+l-o));var u=this.dirtyRectTolerance;t.isZero()||(t.x=Math.floor(t.x-u),t.y=Math.floor(t.y-u),t.width=Math.ceil(t.width+1+u*2),t.height=Math.ceil(t.height+1+u*2))}return t},e.prototype.setPrevPaintRect=function(t){t?(this._prevPaintRect=this._prevPaintRect||new Oe(0,0,0,0),this._prevPaintRect.copy(t)):this._prevPaintRect=null},e.prototype.getPrevPaintRect=function(){return this._prevPaintRect},e.prototype.animateStyle=function(t){return this.animate("style",t)},e.prototype.updateDuringAnimation=function(t){t==="style"?this.dirtyStyle():this.markRedraw()},e.prototype.attrKV=function(t,n){t!=="style"?r.prototype.attrKV.call(this,t,n):this.style?this.setStyle(n):this.useStyle(n)},e.prototype.setStyle=function(t,n){return typeof t=="string"?this.style[t]=n:ie(this.style,t),this.dirtyStyle(),this},e.prototype.dirtyStyle=function(t){t||this.markRedraw(),this.__dirty|=up,this._rect&&(this._rect=null)},e.prototype.dirty=function(){this.dirtyStyle()},e.prototype.styleChanged=function(){return!!(this.__dirty&up)},e.prototype.styleUpdated=function(){this.__dirty&=~up},e.prototype.createStyle=function(t){return Vg(ec,t)},e.prototype.useStyle=function(t){t[kC]||(t=this.createStyle(t)),this.__inHover?this.__hoverStyle=t:this.style=t,this.dirtyStyle()},e.prototype.isStyleObject=function(t){return t[kC]},e.prototype._innerSaveToNormal=function(t){r.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,oP)},e.prototype._applyStateObj=function(t,n,a,i,o,s){r.prototype._applyStateObj.call(this,t,n,a,i,o,s);var l=!(n&&i),u;if(n&&n.style?o?i?u=n.style:(u=this._mergeStyle(this.createStyle(),a.style),this._mergeStyle(u,n.style)):(u=this._mergeStyle(this.createStyle(),i?this.style:a.style),this._mergeStyle(u,n.style)):l&&(u=a.style),u)if(o){var c=this.style;if(this.style=this.createStyle(l?{}:c),l)for(var f=it(c),d=0;d<f.length;d++){var v=f[d];v in u&&(u[v]=u[v],this.style[v]=c[v])}for(var g=it(u),d=0;d<g.length;d++){var v=g[d];this.style[v]=this.style[v]}this._transitionState(t,{style:u},s,this.getAnimationStyleProps())}else this.useStyle(u);for(var y=this.__inHover?Hne:oP,d=0;d<y.length;d++){var v=y[d];n&&n[v]!=null?this[v]=n[v]:l&&a[v]!=null&&(this[v]=a[v])}},e.prototype._mergeStates=function(t){for(var n=r.prototype._mergeStates.call(this,t),a,i=0;i<t.length;i++){var o=t[i];o.style&&(a=a||{},this._mergeStyle(a,o.style))}return a&&(n.style=a),n},e.prototype._mergeStyle=function(t,n){return ie(t,n),t},e.prototype.getAnimationStyleProps=function(){return rb},e.initDefaultProps=(function(){var t=e.prototype;t.type="displayable",t.invisible=!1,t.z=0,t.z2=0,t.zlevel=0,t.culling=!1,t.cursor="pointer",t.rectHover=!1,t.incremental=!1,t._rect=null,t.dirtyRectTolerance=0,t.__dirty=ea|up})(),e})(Q1),Tw=new Oe(0,0,0,0),Cw=new Oe(0,0,0,0);function Fne(r,e,t){return Tw.copy(r.getBoundingRect()),r.transform&&Tw.applyTransform(r.transform),Cw.width=e,Cw.height=t,!Tw.intersect(Cw)}var In=Math.min,On=Math.max,Aw=Math.sin,Mw=Math.cos,ou=Math.PI*2,Py=Nl(),jy=Nl(),zy=Nl();function nb(r,e,t){if(r.length!==0){for(var n=r[0],a=n[0],i=n[0],o=n[1],s=n[1],l=1;l<r.length;l++)n=r[l],a=In(a,n[0]),i=On(i,n[0]),o=In(o,n[1]),s=On(s,n[1]);e[0]=a,e[1]=o,t[0]=i,t[1]=s}}function sP(r,e,t,n,a,i){a[0]=In(r,t),a[1]=In(e,n),i[0]=On(r,t),i[1]=On(e,n)}var lP=[],uP=[];function Une(r,e,t,n,a,i,o,s,l,u){var c=k6,f=Nr,d=c(r,t,a,o,lP);l[0]=1/0,l[1]=1/0,u[0]=-1/0,u[1]=-1/0;for(var v=0;v<d;v++){var g=f(r,t,a,o,lP[v]);l[0]=In(g,l[0]),u[0]=On(g,u[0])}d=c(e,n,i,s,uP);for(var v=0;v<d;v++){var y=f(e,n,i,s,uP[v]);l[1]=In(y,l[1]),u[1]=On(y,u[1])}l[0]=In(r,l[0]),u[0]=On(r,u[0]),l[0]=In(o,l[0]),u[0]=On(o,u[0]),l[1]=In(e,l[1]),u[1]=On(e,u[1]),l[1]=In(s,l[1]),u[1]=On(s,u[1])}function Yne(r,e,t,n,a,i,o,s){var l=O6,u=Hr,c=On(In(l(r,t,a),1),0),f=On(In(l(e,n,i),1),0),d=u(r,t,a,c),v=u(e,n,i,f);o[0]=In(r,a,d),o[1]=In(e,i,v),s[0]=On(r,a,d),s[1]=On(e,i,v)}function Wne(r,e,t,n,a,i,o,s,l){var u=Oo,c=Po,f=Math.abs(a-i);if(f%ou<1e-4&&f>1e-4){s[0]=r-t,s[1]=e-n,l[0]=r+t,l[1]=e+n;return}if(Py[0]=Mw(a)*t+r,Py[1]=Aw(a)*n+e,jy[0]=Mw(i)*t+r,jy[1]=Aw(i)*n+e,u(s,Py,jy),c(l,Py,jy),a=a%ou,a<0&&(a=a+ou),i=i%ou,i<0&&(i=i+ou),a>i&&!o?i+=ou:a<i&&o&&(a+=ou),o){var d=i;i=a,a=d}for(var v=0;v<i;v+=Math.PI/2)v>a&&(zy[0]=Mw(v)*t+r,zy[1]=Aw(v)*n+e,u(s,zy,s),c(l,zy,l))}var Et={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},su=[],lu=[],gi=[],ks=[],mi=[],yi=[],Dw=Math.min,Nw=Math.max,uu=Math.cos,cu=Math.sin,xo=Math.abs,IC=Math.PI,Hs=IC*2,Lw=typeof Float32Array<"u",Cv=[];function Rw(r){var e=Math.round(r/IC*1e8)/1e8;return e%2*IC}function ab(r,e){var t=Rw(r[0]);t<0&&(t+=Hs);var n=t-r[0],a=r[1];a+=n,!e&&a-t>=Hs?a=t+Hs:e&&t-a>=Hs?a=t-Hs:!e&&t>a?a=t+(Hs-Rw(t-a)):e&&t<a&&(a=t-(Hs-Rw(a-t))),r[0]=t,r[1]=a}var qi=(function(){function r(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 r.prototype.increaseVersion=function(){this._version++},r.prototype.getVersion=function(){return this._version},r.prototype.setScale=function(e,t,n){n=n||0,n>0&&(this._ux=xo(n/kx/e)||0,this._uy=xo(n/kx/t)||0)},r.prototype.setDPR=function(e){this.dpr=e},r.prototype.setContext=function(e){this._ctx=e},r.prototype.getContext=function(){return this._ctx},r.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},r.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},r.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData(Et.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},r.prototype.lineTo=function(e,t){var n=xo(e-this._xi),a=xo(t-this._yi),i=n>this._ux||a>this._uy;if(this.addData(Et.L,e,t),this._ctx&&i&&this._ctx.lineTo(e,t),i)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var o=n*n+a*a;o>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=o)}return this},r.prototype.bezierCurveTo=function(e,t,n,a,i,o){return this._drawPendingPt(),this.addData(Et.C,e,t,n,a,i,o),this._ctx&&this._ctx.bezierCurveTo(e,t,n,a,i,o),this._xi=i,this._yi=o,this},r.prototype.quadraticCurveTo=function(e,t,n,a){return this._drawPendingPt(),this.addData(Et.Q,e,t,n,a),this._ctx&&this._ctx.quadraticCurveTo(e,t,n,a),this._xi=n,this._yi=a,this},r.prototype.arc=function(e,t,n,a,i,o){this._drawPendingPt(),Cv[0]=a,Cv[1]=i,ab(Cv,o),a=Cv[0],i=Cv[1];var s=i-a;return this.addData(Et.A,e,t,n,n,a,s,0,o?0:1),this._ctx&&this._ctx.arc(e,t,n,a,i,o),this._xi=uu(i)*n+e,this._yi=cu(i)*n+t,this},r.prototype.arcTo=function(e,t,n,a,i){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,n,a,i),this},r.prototype.rect=function(e,t,n,a){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,n,a),this.addData(Et.R,e,t,n,a),this},r.prototype.closePath=function(){this._drawPendingPt(),this.addData(Et.Z);var e=this._ctx,t=this._x0,n=this._y0;return e&&e.closePath(),this._xi=t,this._yi=n,this},r.prototype.fill=function(e){e&&e.fill(),this.toStatic()},r.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},r.prototype.len=function(){return this._len},r.prototype.setData=function(e){if(this._saveData){var t=e.length;!(this.data&&this.data.length===t)&&Lw&&(this.data=new Float32Array(t));for(var n=0;n<t;n++)this.data[n]=e[n];this._len=t}},r.prototype.appendPath=function(e){if(this._saveData){e instanceof Array||(e=[e]);for(var t=e.length,n=0,a=this._len,i=0;i<t;i++)n+=e[i].len();var o=this.data;if(Lw&&(o instanceof Float32Array||!o)&&(this.data=new Float32Array(a+n),a>0&&o))for(var s=0;s<a;s++)this.data[s]=o[s];for(var i=0;i<t;i++)for(var l=e[i].data,s=0;s<l.length;s++)this.data[a++]=l[s];this._len=a}},r.prototype.addData=function(e,t,n,a,i,o,s,l,u){if(this._saveData){var c=this.data;this._len+arguments.length>c.length&&(this._expandData(),c=this.data);for(var f=0;f<arguments.length;f++)c[this._len++]=arguments[f]}},r.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},r.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}},r.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var e=this.data;e instanceof Array&&(e.length=this._len,Lw&&this._len>11&&(this.data=new Float32Array(e)))}},r.prototype.getBoundingRect=function(){gi[0]=gi[1]=mi[0]=mi[1]=Number.MAX_VALUE,ks[0]=ks[1]=yi[0]=yi[1]=-Number.MAX_VALUE;var e=this.data,t=0,n=0,a=0,i=0,o;for(o=0;o<this._len;){var s=e[o++],l=o===1;switch(l&&(t=e[o],n=e[o+1],a=t,i=n),s){case Et.M:t=a=e[o++],n=i=e[o++],mi[0]=a,mi[1]=i,yi[0]=a,yi[1]=i;break;case Et.L:sP(t,n,e[o],e[o+1],mi,yi),t=e[o++],n=e[o++];break;case Et.C:Une(t,n,e[o++],e[o++],e[o++],e[o++],e[o],e[o+1],mi,yi),t=e[o++],n=e[o++];break;case Et.Q:Yne(t,n,e[o++],e[o++],e[o],e[o+1],mi,yi),t=e[o++],n=e[o++];break;case Et.A:var u=e[o++],c=e[o++],f=e[o++],d=e[o++],v=e[o++],g=e[o++]+v;o+=1;var y=!e[o++];l&&(a=uu(v)*f+u,i=cu(v)*d+c),Wne(u,c,f,d,v,g,y,mi,yi),t=uu(g)*f+u,n=cu(g)*d+c;break;case Et.R:a=t=e[o++],i=n=e[o++];var x=e[o++],b=e[o++];sP(a,i,a+x,i+b,mi,yi);break;case Et.Z:t=a,n=i;break}Oo(gi,gi,mi),Po(ks,ks,yi)}return o===0&&(gi[0]=gi[1]=ks[0]=ks[1]=0),new Oe(gi[0],gi[1],ks[0]-gi[0],ks[1]-gi[1])},r.prototype._calculateLength=function(){var e=this.data,t=this._len,n=this._ux,a=this._uy,i=0,o=0,s=0,l=0;this._pathSegLen||(this._pathSegLen=[]);for(var u=this._pathSegLen,c=0,f=0,d=0;d<t;){var v=e[d++],g=d===1;g&&(i=e[d],o=e[d+1],s=i,l=o);var y=-1;switch(v){case Et.M:i=s=e[d++],o=l=e[d++];break;case Et.L:{var x=e[d++],b=e[d++],w=x-i,T=b-o;(xo(w)>n||xo(T)>a||d===t-1)&&(y=Math.sqrt(w*w+T*T),i=x,o=b);break}case Et.C:{var C=e[d++],D=e[d++],x=e[d++],b=e[d++],M=e[d++],N=e[d++];y=rre(i,o,C,D,x,b,M,N,10),i=M,o=N;break}case Et.Q:{var C=e[d++],D=e[d++],x=e[d++],b=e[d++];y=are(i,o,C,D,x,b,10),i=x,o=b;break}case Et.A:var R=e[d++],E=e[d++],k=e[d++],I=e[d++],B=e[d++],P=e[d++],H=P+B;d+=1,g&&(s=uu(B)*k+R,l=cu(B)*I+E),y=Nw(k,I)*Dw(Hs,Math.abs(P)),i=uu(H)*k+R,o=cu(H)*I+E;break;case Et.R:{s=i=e[d++],l=o=e[d++];var V=e[d++],j=e[d++];y=V*2+j*2;break}case Et.Z:{var w=s-i,T=l-o;y=Math.sqrt(w*w+T*T),i=s,o=l;break}}y>=0&&(u[f++]=y,c+=y)}return this._pathLen=c,c},r.prototype.rebuildPath=function(e,t){var n=this.data,a=this._ux,i=this._uy,o=this._len,s,l,u,c,f,d,v=t<1,g,y,x=0,b=0,w,T=0,C,D;if(!(v&&(this._pathSegLen||this._calculateLength(),g=this._pathSegLen,y=this._pathLen,w=t*y,!w)))e:for(var M=0;M<o;){var N=n[M++],R=M===1;switch(R&&(u=n[M],c=n[M+1],s=u,l=c),N!==Et.L&&T>0&&(e.lineTo(C,D),T=0),N){case Et.M:s=u=n[M++],l=c=n[M++],e.moveTo(u,c);break;case Et.L:{f=n[M++],d=n[M++];var E=xo(f-u),k=xo(d-c);if(E>a||k>i){if(v){var I=g[b++];if(x+I>w){var B=(w-x)/I;e.lineTo(u*(1-B)+f*B,c*(1-B)+d*B);break e}x+=I}e.lineTo(f,d),u=f,c=d,T=0}else{var P=E*E+k*k;P>T&&(C=f,D=d,T=P)}break}case Et.C:{var H=n[M++],V=n[M++],j=n[M++],U=n[M++],F=n[M++],X=n[M++];if(v){var I=g[b++];if(x+I>w){var B=(w-x)/I;_l(u,H,j,F,B,su),_l(c,V,U,X,B,lu),e.bezierCurveTo(su[1],lu[1],su[2],lu[2],su[3],lu[3]);break e}x+=I}e.bezierCurveTo(H,V,j,U,F,X),u=F,c=X;break}case Et.Q:{var H=n[M++],V=n[M++],j=n[M++],U=n[M++];if(v){var I=g[b++];if(x+I>w){var B=(w-x)/I;Zp(u,H,j,B,su),Zp(c,V,U,B,lu),e.quadraticCurveTo(su[1],lu[1],su[2],lu[2]);break e}x+=I}e.quadraticCurveTo(H,V,j,U),u=j,c=U;break}case Et.A:var G=n[M++],W=n[M++],$=n[M++],te=n[M++],ue=n[M++],ge=n[M++],Se=n[M++],Xe=!n[M++],be=$>te?$:te,we=xo($-te)>.001,ze=ue+ge,oe=!1;if(v){var I=g[b++];x+I>w&&(ze=ue+ge*(w-x)/I,oe=!0),x+=I}if(we&&e.ellipse?e.ellipse(G,W,$,te,Se,ue,ze,Xe):e.arc(G,W,be,ue,ze,Xe),oe)break e;R&&(s=uu(ue)*$+G,l=cu(ue)*te+W),u=uu(ze)*$+G,c=cu(ze)*te+W;break;case Et.R:s=u=n[M],l=c=n[M+1],f=n[M++],d=n[M++];var pe=n[M++],Be=n[M++];if(v){var I=g[b++];if(x+I>w){var Le=w-x;e.moveTo(f,d),e.lineTo(f+Dw(Le,pe),d),Le-=pe,Le>0&&e.lineTo(f+pe,d+Dw(Le,Be)),Le-=Be,Le>0&&e.lineTo(f+Nw(pe-Le,0),d+Be),Le-=pe,Le>0&&e.lineTo(f,d+Nw(Be-Le,0));break e}x+=I}e.rect(f,d,pe,Be);break;case Et.Z:if(v){var I=g[b++];if(x+I>w){var B=(w-x)/I;e.lineTo(u*(1-B)+s*B,c*(1-B)+l*B);break e}x+=I}e.closePath(),u=s,c=l}}},r.prototype.clone=function(){var e=new r,t=this.data;return e.data=t.slice?t.slice():Array.prototype.slice.call(t),e._len=this._len,e},r.prototype.canSave=function(){return!!this._saveData},r.CMD=Et,r.initDefaultProps=(function(){var e=r.prototype;e._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0})(),r})();function Us(r,e,t,n,a,i,o){if(a===0)return!1;var s=a,l=0,u=r;if(o>e+s&&o>n+s||o<e-s&&o<n-s||i>r+s&&i>t+s||i<r-s&&i<t-s)return!1;if(r!==t)l=(e-n)/(r-t),u=(r*n-t*e)/(r-t);else return Math.abs(i-r)<=s/2;var c=l*i-o+u,f=c*c/(l*l+1);return f<=s/2*s/2}function Xne(r,e,t,n,a,i,o,s,l,u,c){if(l===0)return!1;var f=l;if(c>e+f&&c>n+f&&c>i+f&&c>s+f||c<e-f&&c<n-f&&c<i-f&&c<s-f||u>r+f&&u>t+f&&u>a+f&&u>o+f||u<r-f&&u<t-f&&u<a-f&&u<o-f)return!1;var d=I6(r,e,t,n,a,i,o,s,u,c,null);return d<=f/2}function xH(r,e,t,n,a,i,o,s,l){if(o===0)return!1;var u=o;if(l>e+u&&l>n+u&&l>i+u||l<e-u&&l<n-u&&l<i-u||s>r+u&&s>t+u&&s>a+u||s<r-u&&s<t-u&&s<a-u)return!1;var c=P6(r,e,t,n,a,i,s,l,null);return c<=u/2}var cP=Math.PI*2;function aa(r){return r%=cP,r<0&&(r+=cP),r}var Av=Math.PI*2;function qne(r,e,t,n,a,i,o,s,l){if(o===0)return!1;var u=o;s-=r,l-=e;var c=Math.sqrt(s*s+l*l);if(c-u>t||c+u<t)return!1;if(Math.abs(n-a)%Av<1e-4)return!0;if(i){var f=n;n=aa(a),a=aa(f)}else n=aa(n),a=aa(a);n>a&&(a+=Av);var d=Math.atan2(l,s);return d<0&&(d+=Av),d>=n&&d<=a||d+Av>=n&&d+Av<=a}function No(r,e,t,n,a,i){if(i>e&&i>n||i<e&&i<n||n===e)return 0;var o=(i-e)/(n-e),s=n<e?1:-1;(o===1||o===0)&&(s=n<e?.5:-.5);var l=o*(t-r)+r;return l===a?1/0:l>a?s:0}var Is=qi.CMD,fu=Math.PI*2,Zne=1e-4;function $ne(r,e){return Math.abs(r-e)<Zne}var xn=[-1,-1,-1],Aa=[-1,-1];function Kne(){var r=Aa[0];Aa[0]=Aa[1],Aa[1]=r}function Qne(r,e,t,n,a,i,o,s,l,u){if(u>e&&u>n&&u>i&&u>s||u<e&&u<n&&u<i&&u<s)return 0;var c=Nx(e,n,i,s,u,xn);if(c===0)return 0;for(var f=0,d=-1,v=void 0,g=void 0,y=0;y<c;y++){var x=xn[y],b=x===0||x===1?.5:1,w=Nr(r,t,a,o,x);w<l||(d<0&&(d=k6(e,n,i,s,Aa),Aa[1]<Aa[0]&&d>1&&Kne(),v=Nr(e,n,i,s,Aa[0]),d>1&&(g=Nr(e,n,i,s,Aa[1]))),d===2?x<Aa[0]?f+=v<e?b:-b:x<Aa[1]?f+=g<v?b:-b:f+=s<g?b:-b:x<Aa[0]?f+=v<e?b:-b:f+=s<v?b:-b)}return f}function Jne(r,e,t,n,a,i,o,s){if(s>e&&s>n&&s>i||s<e&&s<n&&s<i)return 0;var l=nre(e,n,i,s,xn);if(l===0)return 0;var u=O6(e,n,i);if(u>=0&&u<=1){for(var c=0,f=Hr(e,n,i,u),d=0;d<l;d++){var v=xn[d]===0||xn[d]===1?.5:1,g=Hr(r,t,a,xn[d]);g<o||(xn[d]<u?c+=f<e?v:-v:c+=i<f?v:-v)}return c}else{var v=xn[0]===0||xn[0]===1?.5:1,g=Hr(r,t,a,xn[0]);return g<o?0:i<e?v:-v}}function eae(r,e,t,n,a,i,o,s){if(s-=e,s>t||s<-t)return 0;var l=Math.sqrt(t*t-s*s);xn[0]=-l,xn[1]=l;var u=Math.abs(n-a);if(u<1e-4)return 0;if(u>=fu-1e-4){n=0,a=fu;var c=i?1:-1;return o>=xn[0]+r&&o<=xn[1]+r?c:0}if(n>a){var f=n;n=a,a=f}n<0&&(n+=fu,a+=fu);for(var d=0,v=0;v<2;v++){var g=xn[v];if(g+r>o){var y=Math.atan2(s,g),c=i?1:-1;y<0&&(y=fu+y),(y>=n&&y<=a||y+fu>=n&&y+fu<=a)&&(y>Math.PI/2&&y<Math.PI*1.5&&(c=-c),d+=c)}}return d}function bH(r,e,t,n,a){for(var i=r.data,o=r.len(),s=0,l=0,u=0,c=0,f=0,d,v,g=0;g<o;){var y=i[g++],x=g===1;switch(y===Is.M&&g>1&&(t||(s+=No(l,u,c,f,n,a))),x&&(l=i[g],u=i[g+1],c=l,f=u),y){case Is.M:c=i[g++],f=i[g++],l=c,u=f;break;case Is.L:if(t){if(Us(l,u,i[g],i[g+1],e,n,a))return!0}else s+=No(l,u,i[g],i[g+1],n,a)||0;l=i[g++],u=i[g++];break;case Is.C:if(t){if(Xne(l,u,i[g++],i[g++],i[g++],i[g++],i[g],i[g+1],e,n,a))return!0}else s+=Qne(l,u,i[g++],i[g++],i[g++],i[g++],i[g],i[g+1],n,a)||0;l=i[g++],u=i[g++];break;case Is.Q:if(t){if(xH(l,u,i[g++],i[g++],i[g],i[g+1],e,n,a))return!0}else s+=Jne(l,u,i[g++],i[g++],i[g],i[g+1],n,a)||0;l=i[g++],u=i[g++];break;case Is.A:var b=i[g++],w=i[g++],T=i[g++],C=i[g++],D=i[g++],M=i[g++];g+=1;var N=!!(1-i[g++]);d=Math.cos(D)*T+b,v=Math.sin(D)*C+w,x?(c=d,f=v):s+=No(l,u,d,v,n,a);var R=(n-b)*C/T+b;if(t){if(qne(b,w,C,D,D+M,N,e,R,a))return!0}else s+=eae(b,w,C,D,D+M,N,R,a);l=Math.cos(D+M)*T+b,u=Math.sin(D+M)*C+w;break;case Is.R:c=l=i[g++],f=u=i[g++];var E=i[g++],k=i[g++];if(d=c+E,v=f+k,t){if(Us(c,f,d,f,e,n,a)||Us(d,f,d,v,e,n,a)||Us(d,v,c,v,e,n,a)||Us(c,v,c,f,e,n,a))return!0}else s+=No(d,f,d,v,n,a),s+=No(c,v,c,f,n,a);break;case Is.Z:if(t){if(Us(l,u,c,f,e,n,a))return!0}else s+=No(l,u,c,f,n,a);l=c,u=f;break}}return!t&&!$ne(u,f)&&(s+=No(l,u,c,f,n,a)||0),s!==0}function tae(r,e,t){return bH(r,0,!1,e,t)}function rae(r,e,t,n){return bH(r,e,!0,t,n)}var jx=Re({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},ec),nae={style:Re({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},rb.style)},Ew=Wi.concat(["invisible","culling","z","z2","zlevel","parent"]),tt=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.update=function(){var t=this;r.prototype.update.call(this);var n=this.style;if(n.decal){var a=this._decalEl=this._decalEl||new e;a.buildPath===e.prototype.buildPath&&(a.buildPath=function(l){t.buildPath(l,t.shape)}),a.silent=!0;var i=a.style;for(var o in n)i[o]!==n[o]&&(i[o]=n[o]);i.fill=n.fill?n.decal:null,i.decal=null,i.shadowColor=null,n.strokeFirst&&(i.stroke=null);for(var s=0;s<Ew.length;++s)a[Ew[s]]=this[Ew[s]];a.__dirty|=ea}else this._decalEl&&(this._decalEl=null)},e.prototype.getDecalElement=function(){return this._decalEl},e.prototype._init=function(t){var n=it(t);this.shape=this.getDefaultShape();var a=this.getDefaultStyle();a&&this.useStyle(a);for(var i=0;i<n.length;i++){var o=n[i],s=t[o];o==="style"?this.style?ie(this.style,s):this.useStyle(s):o==="shape"?ie(this.shape,s):r.prototype.attrKV.call(this,o,s)}this.style||this.useStyle({})},e.prototype.getDefaultStyle=function(){return null},e.prototype.getDefaultShape=function(){return{}},e.prototype.canBeInsideText=function(){return this.hasFill()},e.prototype.getInsideTextFill=function(){var t=this.style.fill;if(t!=="none"){if(ye(t)){var n=Qp(t,0);return n>.5?TC:n>.2?Ore:CC}else if(t)return CC}return TC},e.prototype.getInsideTextStroke=function(t){var n=this.style.fill;if(ye(n)){var a=this.__zr,i=!!(a&&a.isDarkMode()),o=Qp(t,0)<wC;if(i===o)return n}},e.prototype.buildPath=function(t,n,a){},e.prototype.pathUpdated=function(){this.__dirty&=~Xf},e.prototype.getUpdatedPathProxy=function(t){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,t),this.path},e.prototype.createPathProxy=function(){this.path=new qi(!1)},e.prototype.hasStroke=function(){var t=this.style,n=t.stroke;return!(n==null||n==="none"||!(t.lineWidth>0))},e.prototype.hasFill=function(){var t=this.style,n=t.fill;return n!=null&&n!=="none"},e.prototype.getBoundingRect=function(){var t=this._rect,n=this.style,a=!t;if(a){var i=!1;this.path||(i=!0,this.createPathProxy());var o=this.path;(i||this.__dirty&Xf)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),t=o.getBoundingRect()}if(this._rect=t,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=t.clone());if(this.__dirty||a){s.copy(t);var l=n.strokeNoScale?this.getLineScale():1,u=n.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;u=Math.max(u,c??4)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return t},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect(),o=this.style;if(t=a[0],n=a[1],i.contain(t,n)){var s=this.path;if(this.hasStroke()){var l=o.lineWidth,u=o.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),rae(s,l/u,t,n)))return!0}if(this.hasFill())return tae(s,t,n)}return!1},e.prototype.dirtyShape=function(){this.__dirty|=Xf,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},e.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},e.prototype.animateShape=function(t){return this.animate("shape",t)},e.prototype.updateDuringAnimation=function(t){t==="style"?this.dirtyStyle():t==="shape"?this.dirtyShape():this.markRedraw()},e.prototype.attrKV=function(t,n){t==="shape"?this.setShape(n):r.prototype.attrKV.call(this,t,n)},e.prototype.setShape=function(t,n){var a=this.shape;return a||(a=this.shape={}),typeof t=="string"?a[t]=n:ie(a,t),this.dirtyShape(),this},e.prototype.shapeChanged=function(){return!!(this.__dirty&Xf)},e.prototype.createStyle=function(t){return Vg(jx,t)},e.prototype._innerSaveToNormal=function(t){r.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.shape&&!n.shape&&(n.shape=ie({},this.shape))},e.prototype._applyStateObj=function(t,n,a,i,o,s){r.prototype._applyStateObj.call(this,t,n,a,i,o,s);var l=!(n&&i),u;if(n&&n.shape?o?i?u=n.shape:(u=ie({},a.shape),ie(u,n.shape)):(u=ie({},i?this.shape:a.shape),ie(u,n.shape)):l&&(u=a.shape),u)if(o){this.shape=ie({},this.shape);for(var c={},f=it(u),d=0;d<f.length;d++){var v=f[d];typeof u[v]=="object"?this.shape[v]=u[v]:c[v]=u[v]}this._transitionState(t,{shape:c},s)}else this.shape=u,this.dirtyShape()},e.prototype._mergeStates=function(t){for(var n=r.prototype._mergeStates.call(this,t),a,i=0;i<t.length;i++){var o=t[i];o.shape&&(a=a||{},this._mergeStyle(a,o.shape))}return a&&(n.shape=a),n},e.prototype.getAnimationStyleProps=function(){return nae},e.prototype.isZeroArea=function(){return!1},e.extend=function(t){var n=(function(i){K(o,i);function o(s){var l=i.call(this,s)||this;return t.init&&t.init.call(l,s),l}return o.prototype.getDefaultStyle=function(){return De(t.style)},o.prototype.getDefaultShape=function(){return De(t.shape)},o})(e);for(var a in t)typeof t[a]=="function"&&(n.prototype[a]=t[a]);return n},e.initDefaultProps=(function(){var t=e.prototype;t.type="path",t.strokeContainThreshold=5,t.segmentIgnoreThreshold=0,t.subPixelOptimize=!1,t.autoBatch=!1,t.__dirty=ea|up|Xf})(),e})(Pa),aae=Re({strokeFirst:!0,font:qo,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},jx),Ih=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.hasStroke=function(){return yH(this.style)},e.prototype.hasFill=function(){var t=this.style,n=t.fill;return n!=null&&n!=="none"},e.prototype.createStyle=function(t){return Vg(aae,t)},e.prototype.setBoundingRect=function(t){this._rect=t},e.prototype.getBoundingRect=function(){return this._rect||(this._rect=Gne(this.style)),this._rect},e.initDefaultProps=(function(){var t=e.prototype;t.dirtyRectTolerance=10})(),e})(Pa);Ih.prototype.type="tspan";var iae=Re({x:0,y:0},ec),oae={style:Re({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},rb.style)};function sae(r){return!!(r&&typeof r!="string"&&r.width&&r.height)}var Ir=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.createStyle=function(t){return Vg(iae,t)},e.prototype._getSize=function(t){var n=this.style,a=n[t];if(a!=null)return a;var i=sae(n.image)?n.image:this.__image;if(!i)return 0;var o=t==="width"?"height":"width",s=n[o];return s==null?i[t]:i[t]/i[o]*s},e.prototype.getWidth=function(){return this._getSize("width")},e.prototype.getHeight=function(){return this._getSize("height")},e.prototype.getAnimationStyleProps=function(){return oae},e.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new Oe(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},e})(Pa);Ir.prototype.type="image";function lae(r,e){var t=e.x,n=e.y,a=e.width,i=e.height,o=e.r,s,l,u,c;a<0&&(t=t+a,a=-a),i<0&&(n=n+i,i=-i),typeof o=="number"?s=l=u=c=o:o instanceof Array?o.length===1?s=l=u=c=o[0]:o.length===2?(s=u=o[0],l=c=o[1]):o.length===3?(s=o[0],l=c=o[1],u=o[2]):(s=o[0],l=o[1],u=o[2],c=o[3]):s=l=u=c=0;var f;s+l>a&&(f=s+l,s*=a/f,l*=a/f),u+c>a&&(f=u+c,u*=a/f,c*=a/f),l+u>i&&(f=l+u,l*=i/f,u*=i/f),s+c>i&&(f=s+c,s*=i/f,c*=i/f),r.moveTo(t+s,n),r.lineTo(t+a-l,n),l!==0&&r.arc(t+a-l,n+l,l,-Math.PI/2,0),r.lineTo(t+a,n+i-u),u!==0&&r.arc(t+a-u,n+i-u,u,0,Math.PI/2),r.lineTo(t+c,n+i),c!==0&&r.arc(t+c,n+i-c,c,Math.PI/2,Math.PI),r.lineTo(t,n+s),s!==0&&r.arc(t+s,n+s,s,Math.PI,Math.PI*1.5)}var eh=Math.round;function ib(r,e,t){if(e){var n=e.x1,a=e.x2,i=e.y1,o=e.y2;r.x1=n,r.x2=a,r.y1=i,r.y2=o;var s=t&&t.lineWidth;return s&&(eh(n*2)===eh(a*2)&&(r.x1=r.x2=ia(n,s,!0)),eh(i*2)===eh(o*2)&&(r.y1=r.y2=ia(i,s,!0))),r}}function _H(r,e,t){if(e){var n=e.x,a=e.y,i=e.width,o=e.height;r.x=n,r.y=a,r.width=i,r.height=o;var s=t&&t.lineWidth;return s&&(r.x=ia(n,s,!0),r.y=ia(a,s,!0),r.width=Math.max(ia(n+i,s,!1)-r.x,i===0?0:1),r.height=Math.max(ia(a+o,s,!1)-r.y,o===0?0:1)),r}}function ia(r,e,t){if(!e)return r;var n=eh(r*2);return(n+eh(e))%2===0?n/2:(n+(t?1:-1))/2}var uae=(function(){function r(){this.x=0,this.y=0,this.width=0,this.height=0}return r})(),cae={},qe=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new uae},e.prototype.buildPath=function(t,n){var a,i,o,s;if(this.subPixelOptimize){var l=_H(cae,n,this.style);a=l.x,i=l.y,o=l.width,s=l.height,l.r=n.r,n=l}else a=n.x,i=n.y,o=n.width,s=n.height;n.r?lae(t,n):t.rect(a,i,o,s)},e.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},e})(tt);qe.prototype.type="rect";var fP={fill:"#000"},hP=2,xi={},fae={style:Re({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},rb.style)},ot=(function(r){K(e,r);function e(t){var n=r.call(this)||this;return n.type="text",n._children=[],n._defaultStyle=fP,n.attr(t),n}return e.prototype.childrenRef=function(){return this._children},e.prototype.update=function(){r.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}},e.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):r.prototype.updateTransform.call(this)},e.prototype.getLocalTransform=function(t){var n=this.innerTransformable;return n?n.getLocalTransform(t):r.prototype.getLocalTransform.call(this,t)},e.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),r.prototype.getComputedTransform.call(this)},e.prototype._updateSubTexts=function(){this._childCursor=0,vae(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},e.prototype.addSelfToZr=function(t){r.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=t},e.prototype.removeSelfFromZr=function(t){r.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=null},e.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var t=new Oe(0,0,0,0),n=this._children,a=[],i=null,o=0;o<n.length;o++){var s=n[o],l=s.getBoundingRect(),u=s.getLocalTransform(a);u?(t.copy(l),t.applyTransform(u),i=i||t.clone(),i.union(t)):(i=i||l.clone(),i.union(l))}this._rect=i||t}return this._rect},e.prototype.setDefaultTextStyle=function(t){this._defaultStyle=t||fP},e.prototype.setTextContent=function(t){},e.prototype._mergeStyle=function(t,n){if(!n)return t;var a=n.rich,i=t.rich||a&&{};return ie(t,n),a&&i?(this._mergeRich(i,a),t.rich=i):i&&(t.rich=i),t},e.prototype._mergeRich=function(t,n){for(var a=it(n),i=0;i<a.length;i++){var o=a[i];t[o]=t[o]||{},ie(t[o],n[o])}},e.prototype.getAnimationStyleProps=function(){return fae},e.prototype._getOrCreateChild=function(t){var n=this._children[this._childCursor];return(!n||!(n instanceof t))&&(n=new t),this._children[this._childCursor++]=n,n.__zr=this.__zr,n.parent=this,n},e.prototype._updatePlainTexts=function(){var t=this.style,n=t.font||qo,a=t.padding,i=this._defaultStyle,o=t.x||0,s=t.y||0,l=t.align||i.align||"left",u=t.verticalAlign||i.verticalAlign||"top";nP(xi,i.overflowRect,o,s,l,u),o=xi.baseX,s=xi.baseY;var c=xP(t),f=Ine(c,t,xi.outerWidth,xi.outerHeight),d=kw(t),v=!!t.backgroundColor,g=f.outerHeight,y=f.outerWidth,x=f.lines,b=f.lineHeight;this.isTruncated=!!f.isTruncated;var w=o,T=Ju(s,f.contentHeight,u);if(d||a){var C=Eh(o,y,l),D=Ju(s,g,u);d&&this._renderBackground(t,t,C,D,y,g)}T+=b/2,a&&(w=yP(o,l,a),u==="top"?T+=a[0]:u==="bottom"&&(T-=a[2]));for(var M=0,N=!1,R=!1,E=mP("fill"in t?t.fill:(R=!0,i.fill)),k=gP("stroke"in t?t.stroke:!v&&(!i.autoStroke||R)?(M=hP,N=!0,i.stroke):null),I=t.textShadowBlur>0,B=0;B<x.length;B++){var P=this._getOrCreateChild(Ih),H=P.createStyle();P.useStyle(H),H.text=x[B],H.x=w,H.y=T,H.textAlign=l,H.textBaseline="middle",H.opacity=t.opacity,H.strokeFirst=!0,I&&(H.shadowBlur=t.textShadowBlur||0,H.shadowColor=t.textShadowColor||"transparent",H.shadowOffsetX=t.textShadowOffsetX||0,H.shadowOffsetY=t.textShadowOffsetY||0),H.stroke=k,H.fill=E,k&&(H.lineWidth=t.lineWidth||M,H.lineDash=t.lineDash,H.lineDashOffset=t.lineDashOffset||0),H.font=n,vP(H,t),T+=b,P.setBoundingRect(EC(H,f.contentWidth,f.calculatedLineHeight,N?0:null))}},e.prototype._updateRichTexts=function(){var t=this.style,n=this._defaultStyle,a=t.align||n.align,i=t.verticalAlign||n.verticalAlign,o=t.x||0,s=t.y||0;nP(xi,n.overflowRect,o,s,a,i),o=xi.baseX,s=xi.baseY;var l=xP(t),u=jne(l,t,xi.outerWidth,xi.outerHeight,a),c=u.width,f=u.outerWidth,d=u.outerHeight,v=t.padding;this.isTruncated=!!u.isTruncated;var g=Eh(o,f,a),y=Ju(s,d,i),x=g,b=y;v&&(x+=v[3],b+=v[0]);var w=x+c;kw(t)&&this._renderBackground(t,t,g,y,f,d);for(var T=!!t.backgroundColor,C=0;C<u.lines.length;C++){for(var D=u.lines[C],M=D.tokens,N=M.length,R=D.lineHeight,E=D.width,k=0,I=x,B=w,P=N-1,H=void 0;k<N&&(H=M[k],!H.align||H.align==="left");)this._placeToken(H,t,R,b,I,"left",T),E-=H.width,I+=H.width,k++;for(;P>=0&&(H=M[P],H.align==="right");)this._placeToken(H,t,R,b,B,"right",T),E-=H.width,B-=H.width,P--;for(I+=(c-(I-x)-(w-B)-E)/2;k<=P;)H=M[k],this._placeToken(H,t,R,b,I+H.width/2,"center",T),I+=H.width,k++;b+=R}},e.prototype._placeToken=function(t,n,a,i,o,s,l){var u=n.rich[t.styleName]||{};u.text=t.text;var c=t.verticalAlign,f=i+a/2;c==="top"?f=i+t.height/2:c==="bottom"&&(f=i+a-t.height/2);var d=!t.isLineHolder&&kw(u);d&&this._renderBackground(u,n,s==="right"?o-t.width:s==="center"?o-t.width/2:o,f-t.height/2,t.width,t.height);var v=!!u.backgroundColor,g=t.textPadding;g&&(o=yP(o,s,g),f-=t.height/2-g[0]-t.innerHeight/2);var y=this._getOrCreateChild(Ih),x=y.createStyle();y.useStyle(x);var b=this._defaultStyle,w=!1,T=0,C=!1,D=mP("fill"in u?u.fill:"fill"in n?n.fill:(w=!0,b.fill)),M=gP("stroke"in u?u.stroke:"stroke"in n?n.stroke:!v&&!l&&(!b.autoStroke||w)?(T=hP,C=!0,b.stroke):null),N=u.textShadowBlur>0||n.textShadowBlur>0;x.text=t.text,x.x=o,x.y=f,N&&(x.shadowBlur=u.textShadowBlur||n.textShadowBlur||0,x.shadowColor=u.textShadowColor||n.textShadowColor||"transparent",x.shadowOffsetX=u.textShadowOffsetX||n.textShadowOffsetX||0,x.shadowOffsetY=u.textShadowOffsetY||n.textShadowOffsetY||0),x.textAlign=s,x.textBaseline="middle",x.font=t.font||qo,x.opacity=zn(u.opacity,n.opacity,1),vP(x,u),M&&(x.lineWidth=zn(u.lineWidth,n.lineWidth,T),x.lineDash=Ce(u.lineDash,n.lineDash),x.lineDashOffset=n.lineDashOffset||0,x.stroke=M),D&&(x.fill=D),y.setBoundingRect(EC(x,t.contentWidth,t.contentHeight,C?0:null))},e.prototype._renderBackground=function(t,n,a,i,o,s){var l=t.backgroundColor,u=t.borderWidth,c=t.borderColor,f=l&&l.image,d=l&&!f,v=t.borderRadius,g=this,y,x;if(d||t.lineHeight||u&&c){y=this._getOrCreateChild(qe),y.useStyle(y.createStyle()),y.style.fill=null;var b=y.shape;b.x=a,b.y=i,b.width=o,b.height=s,b.r=v,y.dirtyShape()}if(d){var w=y.style;w.fill=l||null,w.fillOpacity=Ce(t.fillOpacity,1)}else if(f){x=this._getOrCreateChild(Ir),x.onload=function(){g.dirtyStyle()};var T=x.style;T.image=l.image,T.x=a,T.y=i,T.width=o,T.height=s}if(u&&c){var w=y.style;w.lineWidth=u,w.stroke=c,w.strokeOpacity=Ce(t.strokeOpacity,1),w.lineDash=t.borderDash,w.lineDashOffset=t.borderDashOffset||0,y.strokeContainThreshold=0,y.hasFill()&&y.hasStroke()&&(w.strokeFirst=!0,w.lineWidth*=2)}var C=(y||x).style;C.shadowBlur=t.shadowBlur||0,C.shadowColor=t.shadowColor||"transparent",C.shadowOffsetX=t.shadowOffsetX||0,C.shadowOffsetY=t.shadowOffsetY||0,C.opacity=zn(t.opacity,n.opacity,1)},e.makeFont=function(t){var n="";return wH(t)&&(n=[t.fontStyle,t.fontWeight,SH(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),n&&ra(n)||t.textFont||t.font},e})(Pa),hae={left:!0,right:1,center:1},dae={top:1,bottom:1,middle:1},dP=["fontStyle","fontWeight","fontSize","fontFamily"];function SH(r){return typeof r=="string"&&(r.indexOf("px")!==-1||r.indexOf("rem")!==-1||r.indexOf("em")!==-1)?r:isNaN(+r)?YM+"px":r+"px"}function vP(r,e){for(var t=0;t<dP.length;t++){var n=dP[t],a=e[n];a!=null&&(r[n]=a)}}function wH(r){return r.fontSize!=null||r.fontFamily||r.fontWeight}function vae(r){return pP(r),O(r.rich,pP),r}function pP(r){if(r){r.font=ot.makeFont(r);var e=r.align;e==="middle"&&(e="center"),r.align=e==null||hae[e]?e:"left";var t=r.verticalAlign;t==="center"&&(t="middle"),r.verticalAlign=t==null||dae[t]?t:"top";var n=r.padding;n&&(r.padding=Bg(r.padding))}}function gP(r,e){return r==null||e<=0||r==="transparent"||r==="none"?null:r.image||r.colorStops?"#000":r}function mP(r){return r==null||r==="none"?null:r.image||r.colorStops?"#000":r}function yP(r,e,t){return e==="right"?r-t[1]:e==="center"?r+t[3]/2-t[1]/2:r+t[3]}function xP(r){var e=r.text;return e!=null&&(e+=""),e}function kw(r){return!!(r.backgroundColor||r.lineHeight||r.borderWidth&&r.borderColor)}var je=Je(),OC=function(r,e,t,n){if(n){var a=je(n);a.dataIndex=t,a.dataType=e,a.seriesIndex=r,a.ssrType="chart",n.type==="group"&&n.traverse(function(i){var o=je(i);o.seriesIndex=r,o.dataIndex=t,o.dataType=e,o.ssrType="chart"})}},bP=1,_P={},TH=Je(),hD=Je(),dD=0,Ug=1,ob=2,Cn=["emphasis","blur","select"],tg=["normal","emphasis","blur","select"],ed=10,pae=9,tc="highlight",J0="downplay",zx="select",PC="unselect",Bx="toggleSelect",vD="selectchanged";function bf(r){return r!=null&&r!=="none"}function sb(r,e,t){r.onHoverStateChange&&(r.hoverState||0)!==t&&r.onHoverStateChange(e),r.hoverState=t}function CH(r){sb(r,"emphasis",ob)}function AH(r){r.hoverState===ob&&sb(r,"normal",dD)}function pD(r){sb(r,"blur",Ug)}function MH(r){r.hoverState===Ug&&sb(r,"normal",dD)}function gae(r){r.selected=!0}function mae(r){r.selected=!1}function SP(r,e,t){e(r,t)}function as(r,e,t){SP(r,e,t),r.isGroup&&r.traverse(function(n){SP(n,e,t)})}function Vx(r,e){switch(e){case"emphasis":r.hoverState=ob;break;case"normal":r.hoverState=dD;break;case"blur":r.hoverState=Ug;break;case"select":r.selected=!0}}function yae(r,e,t,n){for(var a=r.style,i={},o=0;o<e.length;o++){var s=e[o],l=a[s];i[s]=l??(n&&n[s])}for(var o=0;o<r.animators.length;o++){var u=r.animators[o];u.__fromStateTransition&&u.__fromStateTransition.indexOf(t)<0&&u.targetName==="style"&&u.saveTo(i,e)}return i}function xae(r,e,t,n){var a=t&&Fe(t,"select")>=0,i=!1;if(r instanceof tt){var o=TH(r),s=a&&o.selectFill||o.normalFill,l=a&&o.selectStroke||o.normalStroke;if(bf(s)||bf(l)){n=n||{};var u=n.style||{};u.fill==="inherit"?(i=!0,n=ie({},n),u=ie({},u),u.fill=s):!bf(u.fill)&&bf(s)?(i=!0,n=ie({},n),u=ie({},u),u.fill=Rx(s)):!bf(u.stroke)&&bf(l)&&(i||(n=ie({},n),u=ie({},u)),u.stroke=Rx(l)),n.style=u}}if(n&&n.z2==null){i||(n=ie({},n));var c=r.z2EmphasisLift;n.z2=r.z2+(c??ed)}return n}function bae(r,e,t){if(t&&t.z2==null){t=ie({},t);var n=r.z2SelectLift;t.z2=r.z2+(n??pae)}return t}function _ae(r,e,t){var n=Fe(r.currentStates,e)>=0,a=r.style.opacity,i=n?null:yae(r,["opacity"],e,{opacity:1});t=t||{};var o=t.style||{};return o.opacity==null&&(t=ie({},t),o=ie({opacity:n?a:i.opacity*.1},o),t.style=o),t}function Iw(r,e){var t=this.states[r];if(this.style){if(r==="emphasis")return xae(this,r,e,t);if(r==="blur")return _ae(this,r,t);if(r==="select")return bae(this,r,t)}return t}function fc(r){r.stateProxy=Iw;var e=r.getTextContent(),t=r.getTextGuideLine();e&&(e.stateProxy=Iw),t&&(t.stateProxy=Iw)}function wP(r,e){!RH(r,e)&&!r.__highByOuter&&as(r,CH)}function TP(r,e){!RH(r,e)&&!r.__highByOuter&&as(r,AH)}function $o(r,e){r.__highByOuter|=1<<(e||0),as(r,CH)}function Ko(r,e){!(r.__highByOuter&=~(1<<(e||0)))&&as(r,AH)}function DH(r){as(r,pD)}function gD(r){as(r,MH)}function NH(r){as(r,gae)}function LH(r){as(r,mae)}function RH(r,e){return r.__highDownSilentOnTouch&&e.zrByTouch}function EH(r){var e=r.getModel(),t=[],n=[];e.eachComponent(function(a,i){var o=hD(i),s=a==="series",l=s?r.getViewOfSeriesModel(i):r.getViewOfComponentModel(i);!s&&n.push(l),o.isBlured&&(l.group.traverse(function(u){MH(u)}),s&&t.push(i)),o.isBlured=!1}),O(n,function(a){a&&a.toggleBlurSeries&&a.toggleBlurSeries(t,!1,e)})}function jC(r,e,t,n){var a=n.getModel();t=t||"coordinateSystem";function i(u,c){for(var f=0;f<c.length;f++){var d=u.getItemGraphicEl(c[f]);d&&gD(d)}}if(r!=null&&!(!e||e==="none")){var o=a.getSeriesByIndex(r),s=o.coordinateSystem;s&&s.master&&(s=s.master);var l=[];a.eachSeries(function(u){var c=o===u,f=u.coordinateSystem;f&&f.master&&(f=f.master);var d=f&&s?f===s:c;if(!(t==="series"&&!c||t==="coordinateSystem"&&!d||e==="series"&&c)){var v=n.getViewOfSeriesModel(u);if(v.group.traverse(function(x){x.__highByOuter&&c&&e==="self"||pD(x)}),tn(e))i(u.getData(),e);else if(Ee(e))for(var g=it(e),y=0;y<g.length;y++)i(u.getData(g[y]),e[g[y]]);l.push(u),hD(u).isBlured=!0}}),a.eachComponent(function(u,c){if(u!=="series"){var f=n.getViewOfComponentModel(c);f&&f.toggleBlurSeries&&f.toggleBlurSeries(l,!0,a)}})}}function zC(r,e,t){if(!(r==null||e==null)){var n=t.getModel().getComponent(r,e);if(n){hD(n).isBlured=!0;var a=t.getViewOfComponentModel(n);!a||!a.focusBlurEnabled||a.group.traverse(function(i){pD(i)})}}}function Sae(r,e,t){var n=r.seriesIndex,a=r.getData(e.dataType);if(a){var i=uc(a,e);i=(ce(i)?i[0]:i)||0;var o=a.getItemGraphicEl(i);if(!o)for(var s=a.count(),l=0;!o&&l<s;)o=a.getItemGraphicEl(l++);if(o){var u=je(o);jC(n,u.focus,u.blurScope,t)}else{var c=r.get(["emphasis","focus"]),f=r.get(["emphasis","blurScope"]);c!=null&&jC(n,c,f,t)}}}function mD(r,e,t,n){var a={focusSelf:!1,dispatchers:null};if(r==null||r==="series"||e==null||t==null)return a;var i=n.getModel().getComponent(r,e);if(!i)return a;var o=n.getViewOfComponentModel(i);if(!o||!o.findHighDownDispatchers)return a;for(var s=o.findHighDownDispatchers(t),l,u=0;u<s.length;u++)if(je(s[u]).focus==="self"){l=!0;break}return{focusSelf:l,dispatchers:s}}function wae(r,e,t){var n=je(r),a=mD(n.componentMainType,n.componentIndex,n.componentHighDownName,t),i=a.dispatchers,o=a.focusSelf;i?(o&&zC(n.componentMainType,n.componentIndex,t),O(i,function(s){return wP(s,e)})):(jC(n.seriesIndex,n.focus,n.blurScope,t),n.focus==="self"&&zC(n.componentMainType,n.componentIndex,t),wP(r,e))}function Tae(r,e,t){EH(t);var n=je(r),a=mD(n.componentMainType,n.componentIndex,n.componentHighDownName,t).dispatchers;a?O(a,function(i){return TP(i,e)}):TP(r,e)}function Cae(r,e,t){if(VC(e)){var n=e.dataType,a=r.getData(n),i=uc(a,e);ce(i)||(i=[i]),r[e.type===Bx?"toggleSelect":e.type===zx?"select":"unselect"](i,n)}}function CP(r){var e=r.getAllData();O(e,function(t){var n=t.data,a=t.type;n.eachItemGraphicEl(function(i,o){r.isSelected(o,a)?NH(i):LH(i)})})}function Aae(r){var e=[];return r.eachSeries(function(t){var n=t.getAllData();O(n,function(a){a.data;var i=a.type,o=t.getSelectedDataIndices();if(o.length>0){var s={dataIndex:o,seriesIndex:t.seriesIndex};i!=null&&(s.dataType=i),e.push(s)}})}),e}function hl(r,e,t){Bu(r,!0),as(r,fc),BC(r,e,t)}function Mae(r){Bu(r,!1)}function Ut(r,e,t,n){n?Mae(r):hl(r,e,t)}function BC(r,e,t){var n=je(r);e!=null?(n.focus=e,n.blurScope=t):n.focus&&(n.focus=null)}var AP=["emphasis","blur","select"],Dae={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function _r(r,e,t,n){t=t||"itemStyle";for(var a=0;a<AP.length;a++){var i=AP[a],o=e.getModel([i,t]),s=r.ensureState(i);s.style=n?n(o):o[Dae[t]]()}}function Bu(r,e){var t=e===!1,n=r;r.highDownSilentOnTouch&&(n.__highDownSilentOnTouch=r.highDownSilentOnTouch),(!t||n.__highDownDispatcher)&&(n.__highByOuter=n.__highByOuter||0,n.__highDownDispatcher=!t)}function rg(r){return!!(r&&r.__highDownDispatcher)}function Nae(r,e,t){var n=je(r);n.componentMainType=e.mainType,n.componentIndex=e.componentIndex,n.componentHighDownName=t}function Lae(r){var e=_P[r];return e==null&&bP<=32&&(e=_P[r]=bP++),e}function VC(r){var e=r.type;return e===zx||e===PC||e===Bx}function MP(r){var e=r.type;return e===tc||e===J0}function Rae(r){var e=TH(r);e.normalFill=r.style.fill,e.normalStroke=r.style.stroke;var t=r.states.select||{};e.selectFill=t.style&&t.style.fill||null,e.selectStroke=t.style&&t.style.stroke||null}var _f=qi.CMD,Eae=[[],[],[]],DP=Math.sqrt,kae=Math.atan2;function kH(r,e){if(e){var t=r.data,n=r.len(),a,i,o,s,l,u,c=_f.M,f=_f.C,d=_f.L,v=_f.R,g=_f.A,y=_f.Q;for(o=0,s=0;o<n;){switch(a=t[o++],s=o,i=0,a){case c:i=1;break;case d:i=1;break;case f:i=3;break;case y:i=2;break;case g:var x=e[4],b=e[5],w=DP(e[0]*e[0]+e[1]*e[1]),T=DP(e[2]*e[2]+e[3]*e[3]),C=kae(-e[1]/T,e[0]/w);t[o]*=w,t[o++]+=x,t[o]*=T,t[o++]+=b,t[o++]*=w,t[o++]*=T,t[o++]+=C,t[o++]+=C,o+=2,s=o;break;case v:u[0]=t[o++],u[1]=t[o++],Qt(u,u,e),t[s++]=u[0],t[s++]=u[1],u[0]+=t[o++],u[1]+=t[o++],Qt(u,u,e),t[s++]=u[0],t[s++]=u[1]}for(l=0;l<i;l++){var D=Eae[l];D[0]=t[o++],D[1]=t[o++],Qt(D,D,e),t[s++]=D[0],t[s++]=D[1]}}r.increaseVersion()}}var Ow=Math.sqrt,By=Math.sin,Vy=Math.cos,Mv=Math.PI;function NP(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function GC(r,e){return(r[0]*e[0]+r[1]*e[1])/(NP(r)*NP(e))}function LP(r,e){return(r[0]*e[1]<r[1]*e[0]?-1:1)*Math.acos(GC(r,e))}function RP(r,e,t,n,a,i,o,s,l,u,c){var f=l*(Mv/180),d=Vy(f)*(r-t)/2+By(f)*(e-n)/2,v=-1*By(f)*(r-t)/2+Vy(f)*(e-n)/2,g=d*d/(o*o)+v*v/(s*s);g>1&&(o*=Ow(g),s*=Ow(g));var y=(a===i?-1:1)*Ow((o*o*(s*s)-o*o*(v*v)-s*s*(d*d))/(o*o*(v*v)+s*s*(d*d)))||0,x=y*o*v/s,b=y*-s*d/o,w=(r+t)/2+Vy(f)*x-By(f)*b,T=(e+n)/2+By(f)*x+Vy(f)*b,C=LP([1,0],[(d-x)/o,(v-b)/s]),D=[(d-x)/o,(v-b)/s],M=[(-1*d-x)/o,(-1*v-b)/s],N=LP(D,M);if(GC(D,M)<=-1&&(N=Mv),GC(D,M)>=1&&(N=0),N<0){var R=Math.round(N/Mv*1e6)/1e6;N=Mv*2+R%2*Mv}c.addData(u,w,T,o,s,C,N,f,i)}var Iae=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,Oae=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function Pae(r){var e=new qi;if(!r)return e;var t=0,n=0,a=t,i=n,o,s=qi.CMD,l=r.match(Iae);if(!l)return e;for(var u=0;u<l.length;u++){for(var c=l[u],f=c.charAt(0),d=void 0,v=c.match(Oae)||[],g=v.length,y=0;y<g;y++)v[y]=parseFloat(v[y]);for(var x=0;x<g;){var b=void 0,w=void 0,T=void 0,C=void 0,D=void 0,M=void 0,N=void 0,R=t,E=n,k=void 0,I=void 0;switch(f){case"l":t+=v[x++],n+=v[x++],d=s.L,e.addData(d,t,n);break;case"L":t=v[x++],n=v[x++],d=s.L,e.addData(d,t,n);break;case"m":t+=v[x++],n+=v[x++],d=s.M,e.addData(d,t,n),a=t,i=n,f="l";break;case"M":t=v[x++],n=v[x++],d=s.M,e.addData(d,t,n),a=t,i=n,f="L";break;case"h":t+=v[x++],d=s.L,e.addData(d,t,n);break;case"H":t=v[x++],d=s.L,e.addData(d,t,n);break;case"v":n+=v[x++],d=s.L,e.addData(d,t,n);break;case"V":n=v[x++],d=s.L,e.addData(d,t,n);break;case"C":d=s.C,e.addData(d,v[x++],v[x++],v[x++],v[x++],v[x++],v[x++]),t=v[x-2],n=v[x-1];break;case"c":d=s.C,e.addData(d,v[x++]+t,v[x++]+n,v[x++]+t,v[x++]+n,v[x++]+t,v[x++]+n),t+=v[x-2],n+=v[x-1];break;case"S":b=t,w=n,k=e.len(),I=e.data,o===s.C&&(b+=t-I[k-4],w+=n-I[k-3]),d=s.C,R=v[x++],E=v[x++],t=v[x++],n=v[x++],e.addData(d,b,w,R,E,t,n);break;case"s":b=t,w=n,k=e.len(),I=e.data,o===s.C&&(b+=t-I[k-4],w+=n-I[k-3]),d=s.C,R=t+v[x++],E=n+v[x++],t+=v[x++],n+=v[x++],e.addData(d,b,w,R,E,t,n);break;case"Q":R=v[x++],E=v[x++],t=v[x++],n=v[x++],d=s.Q,e.addData(d,R,E,t,n);break;case"q":R=v[x++]+t,E=v[x++]+n,t+=v[x++],n+=v[x++],d=s.Q,e.addData(d,R,E,t,n);break;case"T":b=t,w=n,k=e.len(),I=e.data,o===s.Q&&(b+=t-I[k-4],w+=n-I[k-3]),t=v[x++],n=v[x++],d=s.Q,e.addData(d,b,w,t,n);break;case"t":b=t,w=n,k=e.len(),I=e.data,o===s.Q&&(b+=t-I[k-4],w+=n-I[k-3]),t+=v[x++],n+=v[x++],d=s.Q,e.addData(d,b,w,t,n);break;case"A":T=v[x++],C=v[x++],D=v[x++],M=v[x++],N=v[x++],R=t,E=n,t=v[x++],n=v[x++],d=s.A,RP(R,E,t,n,M,N,T,C,D,d,e);break;case"a":T=v[x++],C=v[x++],D=v[x++],M=v[x++],N=v[x++],R=t,E=n,t+=v[x++],n+=v[x++],d=s.A,RP(R,E,t,n,M,N,T,C,D,d,e);break}}(f==="z"||f==="Z")&&(d=s.Z,e.addData(d),t=a,n=i),o=d}return e.toStatic(),e}var IH=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.applyTransform=function(t){},e})(tt);function OH(r){return r.setData!=null}function PH(r,e){var t=Pae(r),n=ie({},e);return n.buildPath=function(a){var i=OH(a);if(i&&a.canSave()){a.appendPath(t);var o=a.getContext();o&&a.rebuildPath(o,1)}else{var o=i?a.getContext():a;o&&t.rebuildPath(o,1)}},n.applyTransform=function(a){kH(t,a),this.dirtyShape()},n}function jH(r,e){return new IH(PH(r,e))}function jae(r,e){var t=PH(r,e),n=(function(a){K(i,a);function i(o){var s=a.call(this,o)||this;return s.applyTransform=t.applyTransform,s.buildPath=t.buildPath,s}return i})(IH);return n}function zae(r,e){for(var t=[],n=r.length,a=0;a<n;a++){var i=r[a];t.push(i.getUpdatedPathProxy(!0))}var o=new tt(e);return o.createPathProxy(),o.buildPath=function(s){if(OH(s)){s.appendPath(t);var l=s.getContext();l&&s.rebuildPath(l,1)}},o}function yD(r,e){e=e||{};var t=new tt;return r.shape&&t.setShape(r.shape),t.setStyle(r.style),e.bakeTransform?kH(t.path,r.getComputedTransform()):e.toLocal?t.setLocalTransform(r.getComputedTransform()):t.copyTransform(r),t.buildPath=r.buildPath,t.applyTransform=t.applyTransform,t.z=r.z,t.z2=r.z2,t.zlevel=r.zlevel,t}var Bae=(function(){function r(){this.cx=0,this.cy=0,this.r=0}return r})(),eo=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new Bae},e.prototype.buildPath=function(t,n){t.moveTo(n.cx+n.r,n.cy),t.arc(n.cx,n.cy,n.r,0,Math.PI*2)},e})(tt);eo.prototype.type="circle";var Vae=(function(){function r(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return r})(),Yg=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new Vae},e.prototype.buildPath=function(t,n){var a=.5522848,i=n.cx,o=n.cy,s=n.rx,l=n.ry,u=s*a,c=l*a;t.moveTo(i-s,o),t.bezierCurveTo(i-s,o-c,i-u,o-l,i,o-l),t.bezierCurveTo(i+u,o-l,i+s,o-c,i+s,o),t.bezierCurveTo(i+s,o+c,i+u,o+l,i,o+l),t.bezierCurveTo(i-u,o+l,i-s,o+c,i-s,o),t.closePath()},e})(tt);Yg.prototype.type="ellipse";var zH=Math.PI,Pw=zH*2,hu=Math.sin,Sf=Math.cos,Gae=Math.acos,un=Math.atan2,EP=Math.abs,Rp=Math.sqrt,fp=Math.max,bi=Math.min,Wa=1e-4;function Hae(r,e,t,n,a,i,o,s){var l=t-r,u=n-e,c=o-a,f=s-i,d=f*l-c*u;if(!(d*d<Wa))return d=(c*(e-i)-f*(r-a))/d,[r+d*l,e+d*u]}function Gy(r,e,t,n,a,i,o){var s=r-t,l=e-n,u=(o?i:-i)/Rp(s*s+l*l),c=u*l,f=-u*s,d=r+c,v=e+f,g=t+c,y=n+f,x=(d+g)/2,b=(v+y)/2,w=g-d,T=y-v,C=w*w+T*T,D=a-i,M=d*y-g*v,N=(T<0?-1:1)*Rp(fp(0,D*D*C-M*M)),R=(M*T-w*N)/C,E=(-M*w-T*N)/C,k=(M*T+w*N)/C,I=(-M*w+T*N)/C,B=R-x,P=E-b,H=k-x,V=I-b;return B*B+P*P>H*H+V*V&&(R=k,E=I),{cx:R,cy:E,x0:-c,y0:-f,x1:R*(a/D-1),y1:E*(a/D-1)}}function Fae(r){var e;if(ce(r)){var t=r.length;if(!t)return r;t===1?e=[r[0],r[0],0,0]:t===2?e=[r[0],r[0],r[1],r[1]]:t===3?e=r.concat(r[2]):e=r}else e=[r,r,r,r];return e}function Uae(r,e){var t,n=fp(e.r,0),a=fp(e.r0||0,0),i=n>0,o=a>0;if(!(!i&&!o)){if(i||(n=a,a=0),a>n){var s=n;n=a,a=s}var l=e.startAngle,u=e.endAngle;if(!(isNaN(l)||isNaN(u))){var c=e.cx,f=e.cy,d=!!e.clockwise,v=EP(u-l),g=v>Pw&&v%Pw;if(g>Wa&&(v=g),!(n>Wa))r.moveTo(c,f);else if(v>Pw-Wa)r.moveTo(c+n*Sf(l),f+n*hu(l)),r.arc(c,f,n,l,u,!d),a>Wa&&(r.moveTo(c+a*Sf(u),f+a*hu(u)),r.arc(c,f,a,u,l,d));else{var y=void 0,x=void 0,b=void 0,w=void 0,T=void 0,C=void 0,D=void 0,M=void 0,N=void 0,R=void 0,E=void 0,k=void 0,I=void 0,B=void 0,P=void 0,H=void 0,V=n*Sf(l),j=n*hu(l),U=a*Sf(u),F=a*hu(u),X=v>Wa;if(X){var G=e.cornerRadius;G&&(t=Fae(G),y=t[0],x=t[1],b=t[2],w=t[3]);var W=EP(n-a)/2;if(T=bi(W,b),C=bi(W,w),D=bi(W,y),M=bi(W,x),E=N=fp(T,C),k=R=fp(D,M),(N>Wa||R>Wa)&&(I=n*Sf(u),B=n*hu(u),P=a*Sf(l),H=a*hu(l),v<zH)){var $=Hae(V,j,P,H,I,B,U,F);if($){var te=V-$[0],ue=j-$[1],ge=I-$[0],Se=B-$[1],Xe=1/hu(Gae((te*ge+ue*Se)/(Rp(te*te+ue*ue)*Rp(ge*ge+Se*Se)))/2),be=Rp($[0]*$[0]+$[1]*$[1]);E=bi(N,(n-be)/(Xe+1)),k=bi(R,(a-be)/(Xe-1))}}}if(!X)r.moveTo(c+V,f+j);else if(E>Wa){var we=bi(b,E),ze=bi(w,E),oe=Gy(P,H,V,j,n,we,d),pe=Gy(I,B,U,F,n,ze,d);r.moveTo(c+oe.cx+oe.x0,f+oe.cy+oe.y0),E<N&&we===ze?r.arc(c+oe.cx,f+oe.cy,E,un(oe.y0,oe.x0),un(pe.y0,pe.x0),!d):(we>0&&r.arc(c+oe.cx,f+oe.cy,we,un(oe.y0,oe.x0),un(oe.y1,oe.x1),!d),r.arc(c,f,n,un(oe.cy+oe.y1,oe.cx+oe.x1),un(pe.cy+pe.y1,pe.cx+pe.x1),!d),ze>0&&r.arc(c+pe.cx,f+pe.cy,ze,un(pe.y1,pe.x1),un(pe.y0,pe.x0),!d))}else r.moveTo(c+V,f+j),r.arc(c,f,n,l,u,!d);if(!(a>Wa)||!X)r.lineTo(c+U,f+F);else if(k>Wa){var we=bi(y,k),ze=bi(x,k),oe=Gy(U,F,I,B,a,-ze,d),pe=Gy(V,j,P,H,a,-we,d);r.lineTo(c+oe.cx+oe.x0,f+oe.cy+oe.y0),k<R&&we===ze?r.arc(c+oe.cx,f+oe.cy,k,un(oe.y0,oe.x0),un(pe.y0,pe.x0),!d):(ze>0&&r.arc(c+oe.cx,f+oe.cy,ze,un(oe.y0,oe.x0),un(oe.y1,oe.x1),!d),r.arc(c,f,a,un(oe.cy+oe.y1,oe.cx+oe.x1),un(pe.cy+pe.y1,pe.cx+pe.x1),d),we>0&&r.arc(c+pe.cx,f+pe.cy,we,un(pe.y1,pe.x1),un(pe.y0,pe.x0),!d))}else r.lineTo(c+U,f+F),r.arc(c,f,a,u,l,d)}r.closePath()}}}var Yae=(function(){function r(){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 r})(),nn=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new Yae},e.prototype.buildPath=function(t,n){Uae(t,n)},e.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},e})(tt);nn.prototype.type="sector";var Wae=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return r})(),td=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new Wae},e.prototype.buildPath=function(t,n){var a=n.cx,i=n.cy,o=Math.PI*2;t.moveTo(a+n.r,i),t.arc(a,i,n.r,0,o,!1),t.moveTo(a+n.r0,i),t.arc(a,i,n.r0,0,o,!0)},e})(tt);td.prototype.type="ring";function Xae(r,e,t,n){var a=[],i=[],o=[],s=[],l,u,c,f;if(n){c=[1/0,1/0],f=[-1/0,-1/0];for(var d=0,v=r.length;d<v;d++)Oo(c,c,r[d]),Po(f,f,r[d]);Oo(c,c,n[0]),Po(f,f,n[1])}for(var d=0,v=r.length;d<v;d++){var g=r[d];if(t)l=r[d?d-1:v-1],u=r[(d+1)%v];else if(d===0||d===v-1){a.push(Hi(r[d]));continue}else l=r[d-1],u=r[d+1];el(i,u,l),Tp(i,i,e);var y=Cx(g,l),x=Cx(g,u),b=y+x;b!==0&&(y/=b,x/=b),Tp(o,i,-y),Tp(s,i,x);var w=sC([],g,o),T=sC([],g,s);n&&(Po(w,w,c),Oo(w,w,f),Po(T,T,c),Oo(T,T,f)),a.push(w),a.push(T)}return t&&a.push(a.shift()),a}function BH(r,e,t){var n=e.smooth,a=e.points;if(a&&a.length>=2){if(n){var i=Xae(a,n,t,e.smoothConstraint);r.moveTo(a[0][0],a[0][1]);for(var o=a.length,s=0;s<(t?o:o-1);s++){var l=i[s*2],u=i[s*2+1],c=a[(s+1)%o];r.bezierCurveTo(l[0],l[1],u[0],u[1],c[0],c[1])}}else{r.moveTo(a[0][0],a[0][1]);for(var s=1,f=a.length;s<f;s++)r.lineTo(a[s][0],a[s][1])}t&&r.closePath()}}var qae=(function(){function r(){this.points=null,this.smooth=0,this.smoothConstraint=null}return r})(),an=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new qae},e.prototype.buildPath=function(t,n){BH(t,n,!0)},e})(tt);an.prototype.type="polygon";var Zae=(function(){function r(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return r})(),Ur=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Zae},e.prototype.buildPath=function(t,n){BH(t,n,!1)},e})(tt);Ur.prototype.type="polyline";var $ae={},Kae=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})(),lr=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Kae},e.prototype.buildPath=function(t,n){var a,i,o,s;if(this.subPixelOptimize){var l=ib($ae,n,this.style);a=l.x1,i=l.y1,o=l.x2,s=l.y2}else a=n.x1,i=n.y1,o=n.x2,s=n.y2;var u=n.percent;u!==0&&(t.moveTo(a,i),u<1&&(o=a*(1-u)+o*u,s=i*(1-u)+s*u),t.lineTo(o,s))},e.prototype.pointAt=function(t){var n=this.shape;return[n.x1*(1-t)+n.x2*t,n.y1*(1-t)+n.y2*t]},e})(tt);lr.prototype.type="line";var Rn=[],Qae=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return r})();function kP(r,e,t){var n=r.cpx2,a=r.cpy2;return n!=null||a!=null?[(t?jO:Nr)(r.x1,r.cpx1,r.cpx2,r.x2,e),(t?jO:Nr)(r.y1,r.cpy1,r.cpy2,r.y2,e)]:[(t?vC:Hr)(r.x1,r.cpx1,r.x2,e),(t?vC:Hr)(r.y1,r.cpy1,r.y2,e)]}var rd=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Qae},e.prototype.buildPath=function(t,n){var a=n.x1,i=n.y1,o=n.x2,s=n.y2,l=n.cpx1,u=n.cpy1,c=n.cpx2,f=n.cpy2,d=n.percent;d!==0&&(t.moveTo(a,i),c==null||f==null?(d<1&&(Zp(a,l,o,d,Rn),l=Rn[1],o=Rn[2],Zp(i,u,s,d,Rn),u=Rn[1],s=Rn[2]),t.quadraticCurveTo(l,u,o,s)):(d<1&&(_l(a,l,c,o,d,Rn),l=Rn[1],c=Rn[2],o=Rn[3],_l(i,u,f,s,d,Rn),u=Rn[1],f=Rn[2],s=Rn[3]),t.bezierCurveTo(l,u,c,f,o,s)))},e.prototype.pointAt=function(t){return kP(this.shape,t,!1)},e.prototype.tangentAt=function(t){var n=kP(this.shape,t,!0);return xc(n,n)},e})(tt);rd.prototype.type="bezier-curve";var Jae=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r})(),Wg=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Jae},e.prototype.buildPath=function(t,n){var a=n.cx,i=n.cy,o=Math.max(n.r,0),s=n.startAngle,l=n.endAngle,u=n.clockwise,c=Math.cos(s),f=Math.sin(s);t.moveTo(c*o+a,f*o+i),t.arc(a,i,o,s,l,!u)},e})(tt);Wg.prototype.type="arc";var Xg=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="compound",t}return e.prototype._updatePathDirty=function(){for(var t=this.shape.paths,n=this.shapeChanged(),a=0;a<t.length;a++)n=n||t[a].shapeChanged();n&&this.dirtyShape()},e.prototype.beforeBrush=function(){this._updatePathDirty();for(var t=this.shape.paths||[],n=this.getGlobalScale(),a=0;a<t.length;a++)t[a].path||t[a].createPathProxy(),t[a].path.setScale(n[0],n[1],t[a].segmentIgnoreThreshold)},e.prototype.buildPath=function(t,n){for(var a=n.paths||[],i=0;i<a.length;i++)a[i].buildPath(t,a[i].shape,!0)},e.prototype.afterBrush=function(){for(var t=this.shape.paths||[],n=0;n<t.length;n++)t[n].pathUpdated()},e.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),tt.prototype.getBoundingRect.call(this)},e})(tt),VH=(function(){function r(e){this.colorStops=e||[]}return r.prototype.addColorStop=function(e,t){this.colorStops.push({offset:e,color:t})},r})(),bc=(function(r){K(e,r);function e(t,n,a,i,o,s){var l=r.call(this,o)||this;return l.x=t??0,l.y=n??0,l.x2=a??1,l.y2=i??0,l.type="linear",l.global=s||!1,l}return e})(VH),xD=(function(r){K(e,r);function e(t,n,a,i,o){var s=r.call(this,i)||this;return s.x=t??.5,s.y=n??.5,s.r=a??.5,s.type="radial",s.global=o||!1,s}return e})(VH),jw=Math.min,eie=Math.max,Hy=Math.abs,du=[0,0],vu=[0,0],Vr=A6(),Fy=Vr.minTv,Uy=Vr.maxTv,GH=(function(){function r(e,t){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new Ie;for(var n=0;n<2;n++)this._axes[n]=new Ie;e&&this.fromBoundingRect(e,t)}return r.prototype.fromBoundingRect=function(e,t){var n=this._corners,a=this._axes,i=e.x,o=e.y,s=i+e.width,l=o+e.height;if(n[0].set(i,o),n[1].set(s,o),n[2].set(s,l),n[3].set(i,l),t)for(var u=0;u<4;u++)n[u].transform(t);Ie.sub(a[0],n[1],n[0]),Ie.sub(a[1],n[3],n[0]),a[0].normalize(),a[1].normalize();for(var u=0;u<2;u++)this._origin[u]=a[u].dot(n[0])},r.prototype.intersect=function(e,t,n){var a=!0,i=!t;return t&&Ie.set(t,0,0),Vr.reset(n,!i),!this._intersectCheckOneSide(this,e,i,1)&&(a=!1,i)||!this._intersectCheckOneSide(e,this,i,-1)&&(a=!1,i)||!i&&!Vr.negativeSize&&Ie.copy(t,a?Vr.useDir?Vr.dirMinTv:Fy:Uy),a},r.prototype._intersectCheckOneSide=function(e,t,n,a){for(var i=!0,o=0;o<2;o++){var s=e._axes[o];if(e._getProjMinMaxOnAxis(o,e._corners,du),e._getProjMinMaxOnAxis(o,t._corners,vu),Vr.negativeSize||du[1]<vu[0]||du[0]>vu[1]){if(i=!1,Vr.negativeSize||n)return i;var l=Hy(vu[0]-du[1]),u=Hy(du[0]-vu[1]);jw(l,u)>Uy.len()&&(l<u?Ie.scale(Uy,s,-l*a):Ie.scale(Uy,s,u*a))}else if(!n){var l=Hy(vu[0]-du[1]),u=Hy(du[0]-vu[1]);(Vr.useDir||jw(l,u)<Fy.len())&&((l<u||!Vr.bidirectional)&&(Ie.scale(Fy,s,l*a),Vr.useDir&&Vr.calcDirMTV()),(l>=u||!Vr.bidirectional)&&(Ie.scale(Fy,s,-u*a),Vr.useDir&&Vr.calcDirMTV()))}}return i},r.prototype._getProjMinMaxOnAxis=function(e,t,n){for(var a=this._axes[e],i=this._origin,o=t[0].dot(a)+i[e],s=o,l=o,u=1;u<t.length;u++){var c=t[u].dot(a)+i[e];s=jw(c,s),l=eie(c,l)}n[0]=s+Vr.touchThreshold,n[1]=l-Vr.touchThreshold,Vr.negativeSize=n[1]<n[0]},r})(),tie=[],HH=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.notClear=!0,t.incremental=!0,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}return e.prototype.traverse=function(t,n){t.call(n,this)},e.prototype.useStyle=function(){this.style={}},e.prototype.getCursor=function(){return this._cursor},e.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},e.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},e.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},e.prototype.addDisplayable=function(t,n){n?this._temporaryDisplayables.push(t):this._displayables.push(t),this.markRedraw()},e.prototype.addDisplayables=function(t,n){n=n||!1;for(var a=0;a<t.length;a++)this.addDisplayable(t[a],n)},e.prototype.getDisplayables=function(){return this._displayables},e.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},e.prototype.eachPendingDisplayable=function(t){for(var n=this._cursor;n<this._displayables.length;n++)t&&t(this._displayables[n]);for(var n=0;n<this._temporaryDisplayables.length;n++)t&&t(this._temporaryDisplayables[n])},e.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){var n=this._displayables[t];n.parent=this,n.update(),n.parent=null}for(var t=0;t<this._temporaryDisplayables.length;t++){var n=this._temporaryDisplayables[t];n.parent=this,n.update(),n.parent=null}},e.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new Oe(1/0,1/0,-1/0,-1/0),n=0;n<this._displayables.length;n++){var a=this._displayables[n],i=a.getBoundingRect().clone();a.needLocalTransform()&&i.applyTransform(a.getLocalTransform(tie)),t.union(i)}this._rect=t}return this._rect},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();if(i.contain(a[0],a[1]))for(var o=0;o<this._displayables.length;o++){var s=this._displayables[o];if(s.contain(t,n))return!0}return!1},e})(Pa),FH=Je();function nd(r,e,t,n,a){var i;if(e&&e.ecModel){var o=e.ecModel.getUpdatePayload();i=o&&o.animation}var s=e&&e.isAnimationEnabled(),l=r==="update";if(s){var u=void 0,c=void 0,f=void 0;n?(u=Ce(n.duration,200),c=Ce(n.easing,"cubicOut"),f=0):(u=e.getShallow(l?"animationDurationUpdate":"animationDuration"),c=e.getShallow(l?"animationEasingUpdate":"animationEasing"),f=e.getShallow(l?"animationDelayUpdate":"animationDelay")),i&&(i.duration!=null&&(u=i.duration),i.easing!=null&&(c=i.easing),i.delay!=null&&(f=i.delay)),Me(f)&&(f=f(t,a)),Me(u)&&(u=u(t));var d={duration:u||0,delay:f,easing:c};return d}else return null}function bD(r,e,t,n,a,i,o){var s=!1,l;Me(a)?(o=i,i=a,a=null):Ee(a)&&(i=a.cb,o=a.during,s=a.isFrom,l=a.removeOpt,a=a.dataIndex);var u=r==="leave";u||e.stopAnimation("leave");var c=nd(r,n,a,u?l||{}:null,n&&n.getAnimationDelayParams?n.getAnimationDelayParams(e,a):null);if(c&&c.duration>0){var f=c.duration,d=c.delay,v=c.easing,g={duration:f,delay:d||0,easing:v,done:i,force:!!i||!!o,setToFinal:!u,scope:r,during:o};s?e.animateFrom(t,g):e.animateTo(t,g)}else e.stopAnimation(),!s&&e.attr(t),o&&o(1),i&&i()}function lt(r,e,t,n,a,i){bD("update",r,e,t,n,a,i)}function zt(r,e,t,n,a,i){bD("enter",r,e,t,n,a,i)}function hh(r){if(!r.__zr)return!0;for(var e=0;e<r.animators.length;e++){var t=r.animators[e];if(t.scope==="leave")return!0}return!1}function Sl(r,e,t,n,a,i){hh(r)||bD("leave",r,e,t,n,a,i)}function IP(r,e,t,n){r.removeTextContent(),r.removeTextGuideLine(),Sl(r,{style:{opacity:0}},e,t,n)}function Ho(r,e,t){function n(){r.parent&&r.parent.remove(r)}r.isGroup?r.traverse(function(a){a.isGroup||IP(a,e,t,n)}):IP(r,e,t,n)}function ja(r){FH(r).oldStyle=r.style}function rie(r){return FH(r).oldStyle}var HC={},Ge=["x","y"],vr=["width","height"];function UH(r){return tt.extend(r)}var nie=jae;function YH(r,e){return nie(r,e)}function Ba(r,e){HC[r]=e}function ng(r){if(HC.hasOwnProperty(r))return HC[r]}function Oh(r,e,t,n){var a=jH(r,e);return t&&(n==="center"&&(t=WH(t,a.getBoundingRect())),SD(a,t)),a}function _D(r,e,t){var n=new Ir({style:{image:r,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(a){if(t==="center"){var i={width:a.width,height:a.height};n.setStyle(WH(e,i))}}});return n}function WH(r,e){var t=e.width/e.height,n=r.height*t,a;n<=r.width?a=r.height:(n=r.width,a=n/t);var i=r.x+r.width/2,o=r.y+r.height/2;return{x:i-n/2,y:o-a/2,width:n,height:a}}var ta=zae;function SD(r,e){if(r.applyTransform){var t=r.getBoundingRect(),n=t.calculateTransform(e);r.applyTransform(n)}}function Ph(r,e){return ib(r,r,{lineWidth:e}),r}function aie(r,e){return _H(r,r,e),r}var ex=ia;function dl(r,e){for(var t=Gg([]);r&&r!==e;)Ja(t,r.getLocalTransform(),t),r=r.parent;return t}function ti(r,e,t){return e&&!tn(e)&&(e=jo.getLocalTransform(e)),t&&(e=Oa([],e)),Qt([],r,e)}function lb(r,e,t){var n=e[4]===0||e[5]===0||e[0]===0?1:Pi(2*e[4]/e[0]),a=e[4]===0||e[5]===0||e[2]===0?1:Pi(2*e[4]/e[2]),i=[r==="left"?-n:r==="right"?n:0,r==="top"?-a:r==="bottom"?a:0];return i=ti(i,e,t),Pi(i[0])>Pi(i[1])?i[0]>0?"right":"left":i[1]>0?"bottom":"top"}function OP(r){return!r.isGroup}function iie(r){return r.shape!=null}function qg(r,e,t){if(!r||!e)return;function n(o){var s={};return o.traverse(function(l){OP(l)&&l.anid&&(s[l.anid]=l)}),s}function a(o){var s={x:o.x,y:o.y,rotation:o.rotation};return iie(o)&&(s.shape=De(o.shape)),s}var i=n(r);e.traverse(function(o){if(OP(o)&&o.anid){var s=i[o.anid];if(s){var l=a(o);o.attr(a(s)),lt(o,l,t,je(o).dataIndex)}}})}function wD(r,e){return fe(r,function(t){var n=t[0];n=or(n,e.x),n=sa(n,e.x+e.width);var a=t[1];return a=or(a,e.y),a=sa(a,e.y+e.height),[n,a]})}function XH(r,e){var t=or(r.x,e.x),n=sa(r.x+r.width,e.x+e.width),a=or(r.y,e.y),i=sa(r.y+r.height,e.y+e.height);if(n>=t&&i>=a)return{x:t,y:a,width:n-t,height:i-a}}function ad(r,e,t){var n=ie({rectHover:!0},e),a=n.style={strokeNoScale:!0};if(t=t||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(a.image=r.slice(8),Re(a,t),new Ir(n)):Oh(r.replace("path://",""),n,t,"center")}function hp(r,e,t,n,a){for(var i=0,o=a[a.length-1];i<a.length;i++){var s=a[i];if(qH(r,e,t,n,s[0],s[1],o[0],o[1]))return!0;o=s}}function qH(r,e,t,n,a,i,o,s){var l=t-r,u=n-e,c=o-a,f=s-i,d=zw(c,f,l,u);if(oie(d))return!1;var v=r-a,g=e-i,y=zw(v,g,l,u)/d;if(y<0||y>1)return!1;var x=zw(v,g,c,f)/d;return!(x<0||x>1)}function zw(r,e,t,n){return r*n-t*e}function oie(r){return r<=1e-6&&r>=-1e-6}function hc(r,e,t,n,a){return e==null||(st(e)?Wt[0]=Wt[1]=Wt[2]=Wt[3]=e:(Wt[0]=e[0],Wt[1]=e[1],Wt[2]=e[2],Wt[3]=e[3]),n&&(Wt[0]=or(0,Wt[0]),Wt[1]=or(0,Wt[1]),Wt[2]=or(0,Wt[2]),Wt[3]=or(0,Wt[3])),t&&(Wt[0]=-Wt[0],Wt[1]=-Wt[1],Wt[2]=-Wt[2],Wt[3]=-Wt[3]),PP(r,Wt,"x","width",3,1,a&&a[0]||0),PP(r,Wt,"y","height",0,2,a&&a[1]||0)),r}var Wt=[0,0,0,0];function PP(r,e,t,n,a,i,o){var s=e[i]+e[a],l=r[n];r[n]+=s,o=or(0,sa(o,l)),r[n]<o?(r[n]=o,r[t]+=e[a]>=0?-e[a]:e[i]>=0?l+e[i]:Pi(s)>1e-8?(l-o)*e[a]/s:0):r[t]-=e[a]}function is(r){var e=r.itemTooltipOption,t=r.componentModel,n=r.itemName,a=ye(e)?{formatter:e}:e,i=t.mainType,o=t.componentIndex,s={componentType:i,name:n,$vars:["name"]};s[i+"Index"]=o;var l=r.formatterParamsExtra;l&&O(it(l),function(c){_e(s,c)||(s[c]=l[c],s.$vars.push(c))});var u=je(r.el);u.componentMainType=i,u.componentIndex=o,u.tooltipConfig={name:n,option:Re({content:n,encodeHTMLContent:!0,formatterParams:s},a)}}function FC(r,e){var t;r.isGroup&&(t=e(r)),t||r.traverse(e)}function Ll(r,e){if(r)if(ce(r))for(var t=0;t<r.length;t++)FC(r[t],e);else FC(r,e)}function TD(r){return!r||Pi(r[1])<Yy&&Pi(r[2])<Yy||Pi(r[0])<Yy&&Pi(r[3])<Yy}var Yy=1e-5;function ag(r,e){return r?Oe.copy(r,e):e.clone()}function CD(r,e){return e?Hg(r||Rr(),e):void 0}function dc(r){return{z:r.get("z")||0,zlevel:r.get("zlevel")||0}}function ZH(r){var e=-1/0,t=1/0;FC(r,function(i){n(i),n(i.getTextContent()),n(i.getTextGuideLine())});function n(i){if(!(!i||i.isGroup)){var o=i.currentStates;if(o.length)for(var s=0;s<o.length;s++)a(i.states[o[s]]);a(i)}}function a(i){if(i){var o=i.z2;o>e&&(e=o),o<t&&(t=o)}}return t>e&&(t=e=0),{min:t,max:e}}function ub(r,e,t){$H(r,e,t,-1/0)}function $H(r,e,t,n){if(r.ignoreModelZ)return n;var a=r.getTextContent(),i=r.getTextGuideLine(),o=r.isGroup;if(o)for(var s=r.childrenRef(),l=0;l<s.length;l++)n=or($H(s[l],e,t,n),n);else r.z=e,r.zlevel=t,n=or(r.z2||0,n);if(a&&(a.z=e,a.zlevel=t,isFinite(n)&&(a.z2=n+2)),i){var u=r.textGuideLineConfig;i.z=e,i.zlevel=t,isFinite(n)&&(i.z2=n+(u&&u.showAbove?1:-1))}return n}Ba("circle",eo);Ba("ellipse",Yg);Ba("sector",nn);Ba("ring",td);Ba("polygon",an);Ba("polyline",Ur);Ba("rect",qe);Ba("line",lr);Ba("bezierCurve",rd);Ba("arc",Wg);const _c=Object.freeze(Object.defineProperty({__proto__:null,Arc:Wg,BezierCurve:rd,BoundingRect:Oe,Circle:eo,CompoundPath:Xg,Ellipse:Yg,Group:Ne,Image:Ir,IncrementalDisplayable:HH,Line:lr,LinearGradient:bc,OrientedBoundingRect:GH,Path:tt,Point:Ie,Polygon:an,Polyline:Ur,RadialGradient:xD,Rect:qe,Ring:td,Sector:nn,Text:ot,WH:vr,XY:Ge,applyTransform:ti,calcZ2Range:ZH,clipPointsByRect:wD,clipRectByRect:XH,createIcon:ad,ensureCopyRect:ag,ensureCopyTransform:CD,expandOrShrinkRect:hc,extendPath:YH,extendShape:UH,getShapeClass:ng,getTransform:dl,groupTransition:qg,initProps:zt,isBoundingRectAxisAligned:TD,isElementRemoved:hh,lineLineIntersect:qH,linePolygonIntersect:hp,makeImage:_D,makePath:Oh,mergePath:ta,registerShape:Ba,removeElement:Sl,removeElementWithFadeOut:Ho,resizePath:SD,retrieveZInfo:dc,setTooltipConfig:is,subPixelOptimize:ex,subPixelOptimizeLine:Ph,subPixelOptimizeRect:aie,transformDirection:lb,traverseElements:Ll,traverseUpdateZ:ub,updateProps:lt},Symbol.toStringTag,{value:"Module"}));var cb={};function KH(r,e){for(var t=0;t<Cn.length;t++){var n=Cn[t],a=e[n],i=r.ensureState(n);i.style=i.style||{},i.style.text=a}var o=r.currentStates.slice();r.clearStates(!0),r.setStyle({text:e.normal}),r.useStates(o,!0)}function UC(r,e,t){var n=r.labelFetcher,a=r.labelDataIndex,i=r.labelDimIndex,o=e.normal,s;n&&(s=n.getFormattedLabel(a,"normal",null,i,o&&o.get("formatter"),t!=null?{interpolatedValue:t}:null)),s==null&&(s=Me(r.defaultText)?r.defaultText(a,r,t):r.defaultText);for(var l={normal:s},u=0;u<Cn.length;u++){var c=Cn[u],f=e[c];l[c]=Ce(n?n.getFormattedLabel(a,c,null,i,f&&f.get("formatter")):null,s)}return l}function kr(r,e,t,n){t=t||cb;for(var a=r instanceof ot,i=!1,o=0;o<tg.length;o++){var s=e[tg[o]];if(s&&s.getShallow("show")){i=!0;break}}var l=a?r:r.getTextContent();if(i){a||(l||(l=new ot,r.setTextContent(l)),r.stateProxy&&(l.stateProxy=r.stateProxy));var u=UC(t,e),c=e.normal,f=!!c.getShallow("show"),d=Nt(c,n&&n.normal,t,!1,!a);d.text=u.normal,a||r.setTextConfig(Gx(c,t,!1));for(var o=0;o<Cn.length;o++){var v=Cn[o],s=e[v];if(s){var g=l.ensureState(v),y=!!Ce(s.getShallow("show"),f);if(y!==f&&(g.ignore=!y),g.style=Nt(s,n&&n[v],t,!0,!a),g.style.text=u[v],!a){var x=r.ensureState(v);x.textConfig=Gx(s,t,!0)}}}l.silent=!!c.getShallow("silent"),l.style.x!=null&&(d.x=l.style.x),l.style.y!=null&&(d.y=l.style.y),l.ignore=!f,l.useStyle(d),l.dirty(),t.enableTextSetter&&(id(l).setLabelText=function(b){var w=UC(t,e,b);KH(l,w)})}else l&&(l.ignore=!0);r.dirty()}function Sr(r,e){e=e||"label";for(var t={normal:r.getModel(e)},n=0;n<Cn.length;n++){var a=Cn[n];t[a]=r.getModel([a,e])}return t}function Nt(r,e,t,n,a){var i={};return sie(i,r,t,n,a),e&&ie(i,e),i}function Gx(r,e,t){e=e||{};var n={},a,i=r.getShallow("rotate"),o=Ce(r.getShallow("distance"),t?null:5),s=r.getShallow("offset");return a=r.getShallow("position")||(t?null:"inside"),a==="outside"&&(a=e.defaultOutsidePosition||"top"),a!=null&&(n.position=a),s!=null&&(n.offset=s),i!=null&&(i*=Math.PI/180,n.rotation=i),o!=null&&(n.distance=o),n.outsideFill=r.get("color")==="inherit"?e.inheritColor||null:"auto",e.autoOverflowArea!=null&&(n.autoOverflowArea=e.autoOverflowArea),e.layoutRect!=null&&(n.layoutRect=e.layoutRect),n}function sie(r,e,t,n,a){t=t||cb;var i=e.ecModel,o=i&&i.option.textStyle,s=lie(e),l;if(s){l={};var u="richInheritPlainLabel",c=Ce(e.get(u),i?i.get(u):void 0);for(var f in s)if(s.hasOwnProperty(f)){var d=e.getModel(["rich",f]);VP(l[f]={},d,o,e,c,t,n,a,!1,!0)}}l&&(r.rich=l);var v=e.get("overflow");v&&(r.overflow=v);var g=e.get("lineOverflow");g&&(r.lineOverflow=g);var y=r,x=e.get("minMargin");if(x!=null)x=st(x)?x/2:0,y.margin=[x,x,x,x],y.__marginType=th.minMargin;else{var b=e.get("textMargin");b!=null&&(y.margin=Bg(b),y.__marginType=th.textMargin)}VP(r,e,o,null,null,t,n,a,!0,!1)}function lie(r){for(var e;r&&r!==r.ecModel;){var t=(r.option||cb).rich;if(t){e=e||{};for(var n=it(t),a=0;a<n.length;a++){var i=n[a];e[i]=1}}r=r.parentModel}return e}var jP=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],zP=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],BP=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function VP(r,e,t,n,a,i,o,s,l,u){t=!o&&t||cb;var c=i&&i.inheritColor,f=e.getShallow("color"),d=e.getShallow("textBorderColor"),v=Ce(e.getShallow("opacity"),t.opacity);(f==="inherit"||f==="auto")&&(c?f=c:f=null),(d==="inherit"||d==="auto")&&(c?d=c:d=null),s||(f=f||t.color,d=d||t.textBorderColor),f!=null&&(r.fill=f),d!=null&&(r.stroke=d);var g=Ce(e.getShallow("textBorderWidth"),t.textBorderWidth);g!=null&&(r.lineWidth=g);var y=Ce(e.getShallow("textBorderType"),t.textBorderType);y!=null&&(r.lineDash=y);var x=Ce(e.getShallow("textBorderDashOffset"),t.textBorderDashOffset);x!=null&&(r.lineDashOffset=x),!o&&v==null&&!u&&(v=i&&i.defaultOpacity),v!=null&&(r.opacity=v),!o&&!s&&r.fill==null&&i.inheritColor&&(r.fill=i.inheritColor);for(var b=0;b<jP.length;b++){var w=jP[b],T=a!==!1&&n?zn(e.getShallow(w),n.getShallow(w),t[w]):Ce(e.getShallow(w),t[w]);T!=null&&(r[w]=T)}for(var b=0;b<zP.length;b++){var w=zP[b],T=e.getShallow(w);T!=null&&(r[w]=T)}if(r.verticalAlign==null){var C=e.getShallow("baseline");C!=null&&(r.verticalAlign=C)}if(!l||!i.disableBox){for(var b=0;b<BP.length;b++){var w=BP[b],T=e.getShallow(w);T!=null&&(r[w]=T)}var D=e.getShallow("borderType");D!=null&&(r.borderDash=D),(r.backgroundColor==="auto"||r.backgroundColor==="inherit")&&c&&(r.backgroundColor=c),(r.borderColor==="auto"||r.borderColor==="inherit")&&c&&(r.borderColor=c)}}function AD(r,e){var t=e&&e.getModel("textStyle");return ra([r.fontStyle||t&&t.getShallow("fontStyle")||"",r.fontWeight||t&&t.getShallow("fontWeight")||"",(r.fontSize||t&&t.getShallow("fontSize")||12)+"px",r.fontFamily||t&&t.getShallow("fontFamily")||"sans-serif"].join(" "))}var id=Je();function QH(r,e,t,n){if(r){var a=id(r);a.prevValue=a.value,a.value=t;var i=e.normal;a.valueAnimation=i.get("valueAnimation"),a.valueAnimation&&(a.precision=i.get("precision"),a.defaultInterpolatedText=n,a.statesModels=e)}}function JH(r,e,t,n,a){var i=id(r);if(!i.valueAnimation||i.prevValue===i.value)return;var o=i.defaultInterpolatedText,s=Ce(i.interpolatedValue,i.prevValue),l=i.value;function u(c){var f=fH(t,i.precision,s,l,c);i.interpolatedValue=c===1?null:f;var d=UC({labelDataIndex:e,labelFetcher:a,defaultText:o?o(f):f+""},i.statesModels,f);KH(r,d)}r.percent=0,(i.prevValue==null?zt:lt)(r,{percent:1},n,e,null,u)}var th={minMargin:1,textMargin:2},uie=["textStyle","color"],Bw=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],Vw=new ot,cie=(function(){function r(){}return r.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow("color")||(!e&&t?t.get(uie):null)},r.prototype.getFont=function(){return AD({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},r.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},n=0;n<Bw.length;n++)t[Bw[n]]=this.getShallow(Bw[n]);return Vw.useStyle(t),Vw.update(),Vw.getBoundingRect()},r})(),e8=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],fie=cc(e8),hie=(function(){function r(){}return r.prototype.getLineStyle=function(e){return fie(this,e)},r})(),t8=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],die=cc(t8),vie=(function(){function r(){}return r.prototype.getItemStyle=function(e,t){return die(this,e,t)},r})(),et=(function(){function r(e,t,n){this.parentModel=t,this.ecModel=n,this.option=e}return r.prototype.init=function(e,t,n){},r.prototype.mergeOption=function(e,t){Ye(this.option,e,!0)},r.prototype.get=function(e,t){return e==null?this.option:this._doGet(this.parsePath(e),!t&&this.parentModel)},r.prototype.getShallow=function(e,t){var n=this.option,a=n==null?n:n[e];if(a==null&&!t){var i=this.parentModel;i&&(a=i.getShallow(e))}return a},r.prototype.getModel=function(e,t){var n=e!=null,a=n?this.parsePath(e):null,i=n?this._doGet(a):this.option;return t=t||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(a)),new r(i,t,this.ecModel)},r.prototype.isEmpty=function(){return this.option==null},r.prototype.restoreData=function(){},r.prototype.clone=function(){var e=this.constructor;return new e(De(this.option))},r.prototype.parsePath=function(e){return typeof e=="string"?e.split("."):e},r.prototype.resolveParentPath=function(e){return e},r.prototype.isAnimationEnabled=function(){if(!nt.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},r.prototype._doGet=function(e,t){var n=this.option;if(!e)return n;for(var a=0;a<e.length&&!(e[a]&&(n=n&&typeof n=="object"?n[e[a]]:null,n==null));a++);return n==null&&t&&(n=t._doGet(this.resolveParentPath(e),t.parentModel)),n},r})();uD(et);Cne(et);Jt(et,hie);Jt(et,vie);Jt(et,Lne);Jt(et,cie);var pie=Math.round(Math.random()*10);function od(r){return[r||"",pie++].join("_")}function gie(r){var e={};r.registerSubTypeDefaulter=function(t,n){var a=ji(t);e[a.main]=n},r.determineSubType=function(t,n){var a=n.type;if(!a){var i=ji(t).main;r.hasSubTypes(t)&&e[i]&&(a=e[i](n))}return a}}function mie(r,e){r.topologicalTravel=function(i,o,s,l){if(!i.length)return;var u=t(o),c=u.graph,f=u.noEntryList,d={};for(O(i,function(w){d[w]=!0});f.length;){var v=f.pop(),g=c[v],y=!!d[v];y&&(s.call(l,v,g.originalDeps.slice()),delete d[v]),O(g.successor,y?b:x)}O(d,function(){var w="";throw new Error(w)});function x(w){c[w].entryCount--,c[w].entryCount===0&&f.push(w)}function b(w){d[w]=!0,x(w)}};function t(i){var o={},s=[];return O(i,function(l){var u=n(o,l),c=u.originalDeps=e(l),f=a(c,i);u.entryCount=f.length,u.entryCount===0&&s.push(l),O(f,function(d){Fe(u.predecessor,d)<0&&u.predecessor.push(d);var v=n(o,d);Fe(v.successor,d)<0&&v.successor.push(l)})}),{graph:o,noEntryList:s}}function n(i,o){return i[o]||(i[o]={predecessor:[],successor:[]}),i[o]}function a(i,o){var s=[];return O(i,function(l){Fe(o,l)>=0&&s.push(l)}),s}}function Rl(r,e){return Ye(Ye({},r,!0),e,!0)}const yie={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:". "}}}},xie={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:""}}}};var Hx="ZH",MD="EN",dh=MD,tx={},DD={},r8=nt.domSupported?(function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage||dh).toUpperCase();return r.indexOf(Hx)>-1?Hx:dh})():dh;function ND(r,e){r=r.toUpperCase(),DD[r]=new et(e),tx[r]=e}function bie(r){if(ye(r)){var e=tx[r.toUpperCase()]||{};return r===Hx||r===MD?De(e):Ye(De(e),De(tx[dh]),!1)}else return Ye(De(r),De(tx[dh]),!1)}function YC(r){return DD[r]}function _ie(){return DD[dh]}ND(MD,yie);ND(Hx,xie);var WC=null;function Sie(r){WC||(WC=r)}function dr(){return WC}var LD=1e3,RD=LD*60,Ep=RD*60,Ra=Ep*24,GP=Ra*365,wie={year:/({yyyy}|{yy})/,month:/({MMMM}|{MMM}|{MM}|{M})/,day:/({dd}|{d})/,hour:/({HH}|{H}|{hh}|{h})/,minute:/({mm}|{m})/,second:/({ss}|{s})/,millisecond:/({SSS}|{S})/},rx={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}"},Tie="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}",Wy="{yyyy}-{MM}-{dd}",HP={year:"{yyyy}",month:"{yyyy}-{MM}",day:Wy,hour:Wy+" "+rx.hour,minute:Wy+" "+rx.minute,second:Wy+" "+rx.second,millisecond:Tie},$n=["year","month","day","hour","minute","second","millisecond"],Cie=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function Aie(r){return!ye(r)&&!Me(r)?Mie(r):r}function Mie(r){r=r||{};var e={},t=!0;return O($n,function(n){t&&(t=r[n]==null)}),O($n,function(n,a){var i=r[n];e[n]={};for(var o=null,s=a;s>=0;s--){var l=$n[s],u=Ee(i)&&!ce(i)?i[l]:i,c=void 0;ce(u)?(c=u.slice(),o=c[0]||""):ye(u)?(o=u,c=[o]):(o==null?o=rx[n]:wie[l].test(o)||(o=e[l][l][0]+" "+o),c=[o],t&&(c[1]="{primary|"+o+"}")),e[n][l]=c}}),e}function bn(r,e){return r+="","0000".substr(0,e-r.length)+r}function kp(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function Die(r){return r===kp(r)}function Nie(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function Zg(r,e,t,n){var a=Ji(r),i=a[n8(t)](),o=a[ED(t)]()+1,s=Math.floor((o-1)/3)+1,l=a[kD(t)](),u=a["get"+(t?"UTC":"")+"Day"](),c=a[ID(t)](),f=(c-1)%12+1,d=a[OD(t)](),v=a[PD(t)](),g=a[jD(t)](),y=c>=12?"pm":"am",x=y.toUpperCase(),b=n instanceof et?n:YC(n||r8)||_ie(),w=b.getModel("time"),T=w.get("month"),C=w.get("monthAbbr"),D=w.get("dayOfWeek"),M=w.get("dayOfWeekAbbr");return(e||"").replace(/{a}/g,y+"").replace(/{A}/g,x+"").replace(/{yyyy}/g,i+"").replace(/{yy}/g,bn(i%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,T[o-1]).replace(/{MMM}/g,C[o-1]).replace(/{MM}/g,bn(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,bn(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,D[u]).replace(/{ee}/g,M[u]).replace(/{e}/g,u+"").replace(/{HH}/g,bn(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,bn(f+"",2)).replace(/{h}/g,f+"").replace(/{mm}/g,bn(d,2)).replace(/{m}/g,d+"").replace(/{ss}/g,bn(v,2)).replace(/{s}/g,v+"").replace(/{SSS}/g,bn(g,3)).replace(/{S}/g,g+"")}function Lie(r,e,t,n,a){var i=null;if(ye(t))i=t;else if(Me(t)){var o={time:r.time,level:r.time.level},s=dr();s&&s.makeAxisLabelFormatterParamBreak(o,r.break),i=t(r.value,e,o)}else{var l=r.time;if(l){var u=t[l.lowerTimeUnit][l.upperTimeUnit];i=u[Math.min(l.level,u.length-1)]||""}else{var c=rh(r.value,a);i=t[c][c][0]}}return Zg(new Date(r.value),i,a,n)}function rh(r,e){var t=Ji(r),n=t[ED(e)]()+1,a=t[kD(e)](),i=t[ID(e)](),o=t[OD(e)](),s=t[PD(e)](),l=t[jD(e)](),u=l===0,c=u&&s===0,f=c&&o===0,d=f&&i===0,v=d&&a===1,g=v&&n===1;return g?"year":v?"month":d?"day":f?"hour":c?"minute":u?"second":"millisecond"}function Fx(r,e,t){switch(e){case"year":r[a8(t)](0);case"month":r[i8(t)](1);case"day":r[o8(t)](0);case"hour":r[s8(t)](0);case"minute":r[l8(t)](0);case"second":r[u8(t)](0)}return r}function n8(r){return r?"getUTCFullYear":"getFullYear"}function ED(r){return r?"getUTCMonth":"getMonth"}function kD(r){return r?"getUTCDate":"getDate"}function ID(r){return r?"getUTCHours":"getHours"}function OD(r){return r?"getUTCMinutes":"getMinutes"}function PD(r){return r?"getUTCSeconds":"getSeconds"}function jD(r){return r?"getUTCMilliseconds":"getMilliseconds"}function Rie(r){return r?"setUTCFullYear":"setFullYear"}function a8(r){return r?"setUTCMonth":"setMonth"}function i8(r){return r?"setUTCDate":"setDate"}function o8(r){return r?"setUTCHours":"setHours"}function s8(r){return r?"setUTCMinutes":"setMinutes"}function l8(r){return r?"setUTCSeconds":"setSeconds"}function u8(r){return r?"setUTCMilliseconds":"setMilliseconds"}function Eie(r,e,t,n,a,i,o,s){var l=new ot({style:{text:r,font:e,align:t,verticalAlign:n,padding:a,rich:i,overflow:o?"truncate":null,lineHeight:s}});return l.getBoundingRect()}function zD(r){if(!oD(r))return ye(r)?r:"-";var e=(r+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function BD(r,e){return r=(r||"").toLowerCase().replace(/-(.)/g,function(t,n){return n.toUpperCase()}),e&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var sd=Bg;function XC(r,e,t){var n="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function a(c){return c&&ra(c)?c:"-"}function i(c){return!!(c!=null&&!isNaN(c)&&isFinite(c))}var o=e==="time",s=r instanceof Date;if(o||s){var l=o?Ji(r):r;if(isNaN(+l)){if(s)return"-"}else return Zg(l,n,t)}if(e==="ordinal")return Sx(r)?a(r):st(r)&&i(r)?r+"":"-";var u=Xi(r);return i(u)?zD(u):Sx(r)?a(r):typeof r=="boolean"?r+"":"-"}var FP=["a","b","c","d","e","f","g"],Gw=function(r,e){return"{"+r+(e??"")+"}"};function VD(r,e,t){ce(e)||(e=[e]);var n=e.length;if(!n)return"";for(var a=e[0].$vars||[],i=0;i<a.length;i++){var o=FP[i];r=r.replace(Gw(o),Gw(o,0))}for(var s=0;s<n;s++)for(var l=0;l<a.length;l++){var u=e[s][a[l]];r=r.replace(Gw(FP[l],s),t?dn(u):u)}return r}function kie(r,e,t){return O(e,function(n,a){r=r.replace("{"+a+"}",n)}),r}function c8(r,e){var t=ye(r)?{color:r,extraCssText:e}:r||{},n=t.color,a=t.type;e=t.extraCssText;var i=t.renderMode||"html";if(!n)return"";if(i==="html")return a==="subItem"?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+dn(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+dn(n)+";"+(e||"")+'"></span>';var o=t.markerId||"markerX";return{renderMode:i,content:"{"+o+"|} ",style:a==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:n}:{width:10,height:10,borderRadius:5,backgroundColor:n}}}function Iie(r,e,t){(r==="week"||r==="month"||r==="quarter"||r==="half-year"||r==="year")&&(r=`MM-dd
272
- yyyy`);var n=Ji(e),a=t?"getUTC":"get",i=n[a+"FullYear"](),o=n[a+"Month"]()+1,s=n[a+"Date"](),l=n[a+"Hours"](),u=n[a+"Minutes"](),c=n[a+"Seconds"](),f=n[a+"Milliseconds"]();return r=r.replace("MM",bn(o,2)).replace("M",o).replace("yyyy",i).replace("yy",bn(i%100+"",2)).replace("dd",bn(s,2)).replace("d",s).replace("hh",bn(l,2)).replace("h",l).replace("mm",bn(u,2)).replace("m",u).replace("ss",bn(c,2)).replace("s",c).replace("SSS",bn(f,3)),r}function Oie(r){return r&&r.charAt(0).toUpperCase()+r.substr(1)}function vc(r,e){return e=e||"transparent",ye(r)?r:Ee(r)&&r.colorStops&&(r.colorStops[0]||{}).color||e}function Ux(r,e){if(e==="_blank"||e==="blank"){var t=window.open();t.opener=null,t.location.href=r}else window.open(r,e)}var nx={},Hw={},ld=(function(){function r(){this._normalMasterList=[],this._nonSeriesBoxMasterList=[]}return r.prototype.create=function(e,t){this._nonSeriesBoxMasterList=n(nx),this._normalMasterList=n(Hw);function n(a,i){var o=[];return O(a,function(s,l){var u=s.create(e,t);o=o.concat(u||[])}),o}},r.prototype.update=function(e,t){O(this._normalMasterList,function(n){n.update&&n.update(e,t)})},r.prototype.getCoordinateSystems=function(){return this._normalMasterList.concat(this._nonSeriesBoxMasterList)},r.register=function(e,t){if(e==="matrix"||e==="calendar"){nx[e]=t;return}Hw[e]=t},r.get=function(e){return Hw[e]||nx[e]},r})();function Pie(r){return!!nx[r]}var qC={coord:1,coord2:2};function jie(r){f8.set(r.fullType,{getCoord2:void 0}).getCoord2=r.getCoord2}var f8=Te();function zie(r){var e=r.getShallow("coord",!0),t=qC.coord;if(e==null){var n=f8.get(r.type);n&&n.getCoord2&&(t=qC.coord2,e=n.getCoord2(r))}return{coord:e,from:t}}var Ei={none:0,dataCoordSys:1,boxCoordSys:2};function h8(r,e){var t=r.getShallow("coordinateSystem"),n=r.getShallow("coordinateSystemUsage",!0),a=Ei.none;if(t){var i=r.mainType==="series";n==null&&(n=i?"data":"box"),n==="data"?(a=Ei.dataCoordSys,i||(a=Ei.none)):n==="box"&&(a=Ei.boxCoordSys,!i&&!Pie(t)&&(a=Ei.none))}return{coordSysType:t,kind:a}}function $g(r){var e=r.targetModel,t=r.coordSysType,n=r.coordSysProvider,a=r.isDefaultDataCoordSys;r.allowNotFound;var i=h8(e),o=i.kind,s=i.coordSysType;if(a&&o!==Ei.dataCoordSys&&(o=Ei.dataCoordSys,s=t),o===Ei.none||s!==t)return!1;var l=n(t,e);return l?(o===Ei.dataCoordSys?e.coordinateSystem=l:e.boxCoordinateSystem=l,!0):!1}var d8=function(r,e){var t=e.getReferringComponents(r,Zt).models[0];return t&&t.coordinateSystem},ax=O,v8=["left","right","top","bottom","width","height"],Vu=[["width","left","right"],["height","top","bottom"]];function GD(r,e,t,n,a){var i=0,o=0;n==null&&(n=1/0),a==null&&(a=1/0);var s=0;e.eachChild(function(l,u){var c=l.getBoundingRect(),f=e.childAt(u+1),d=f&&f.getBoundingRect(),v,g;if(r==="horizontal"){var y=c.width+(d?-d.x+c.x:0);v=i+y,v>n||l.newline?(i=0,v=y,o+=s+t,s=c.height):s=Math.max(s,c.height)}else{var x=c.height+(d?-d.y+c.y:0);g=o+x,g>a||l.newline?(i+=s+t,o=0,g=x,s=c.width):s=Math.max(s,c.width)}l.newline||(l.x=i,l.y=o,l.markRedraw(),r==="horizontal"?i=v+t:o=g+t)})}var rc=GD;He(GD,"vertical");He(GD,"horizontal");function p8(r,e){return{left:r.getShallow("left",e),top:r.getShallow("top",e),right:r.getShallow("right",e),bottom:r.getShallow("bottom",e),width:r.getShallow("width",e),height:r.getShallow("height",e)}}function Bie(r,e){var t=Cr(r,e,{enableLayoutOnlyByCenter:!0}),n=r.getBoxLayoutParams(),a,i;if(t.type===dp.point)i=t.refPoint,a=Ht(n,{width:e.getWidth(),height:e.getHeight()});else{var o=r.get("center"),s=ce(o)?o:[o,o];a=Ht(n,t.refContainer),i=t.boxCoordFrom===qC.coord2?t.refPoint:[me(s[0],a.width)+a.x,me(s[1],a.height)+a.y]}return{viewRect:a,center:i}}function g8(r,e){var t=Bie(r,e),n=t.viewRect,a=t.center,i=r.get("radius");ce(i)||(i=[0,i]);var o=me(n.width,e.getWidth()),s=me(n.height,e.getHeight()),l=Math.min(o,s),u=me(i[0],l/2),c=me(i[1],l/2);return{cx:a[0],cy:a[1],r0:u,r:c,viewRect:n}}function Ht(r,e,t){t=sd(t||0);var n=e.width,a=e.height,i=me(r.left,n),o=me(r.top,a),s=me(r.right,n),l=me(r.bottom,a),u=me(r.width,n),c=me(r.height,a),f=t[2]+t[0],d=t[1]+t[3],v=r.aspect;switch(isNaN(u)&&(u=n-s-d-i),isNaN(c)&&(c=a-l-f-o),v!=null&&(isNaN(u)&&isNaN(c)&&(v>n/a?u=n*.8:c=a*.8),isNaN(u)&&(u=v*c),isNaN(c)&&(c=u/v)),isNaN(i)&&(i=n-s-u-d),isNaN(o)&&(o=a-l-c-f),r.left||r.right){case"center":i=n/2-u/2-t[3];break;case"right":i=n-u-d;break}switch(r.top||r.bottom){case"middle":case"center":o=a/2-c/2-t[0];break;case"bottom":o=a-c-f;break}i=i||0,o=o||0,isNaN(u)&&(u=n-d-i-(s||0)),isNaN(c)&&(c=a-f-o-(l||0));var g=new Oe((e.x||0)+i+t[3],(e.y||0)+o+t[0],u,c);return g.margin=t,g}function m8(r,e,t){var n=r.getShallow("preserveAspect",!0);if(!n)return e;var a=e.width/e.height;if(Math.abs(Math.atan(t)-Math.atan(a))<1e-9)return e;var i=r.getShallow("preserveAspectAlign",!0),o=r.getShallow("preserveAspectVerticalAlign",!0),s={width:e.width,height:e.height},l=n==="cover";return a>t&&!l||a<t&&l?(s.width=e.height*t,i==="left"?s.left=0:i==="right"?s.right=0:s.left="center"):(s.height=e.width/t,o==="top"?s.top=0:o==="bottom"?s.bottom=0:s.top="middle"),Ht(s,e)}var dp={rect:1,point:2};function Cr(r,e,t){var n,a,i,o=r.boxCoordinateSystem,s;if(o){var l=zie(r),u=l.coord,c=l.from;if(o.dataToLayout){i=dp.rect,s=c;var f=o.dataToLayout(u);n=f.contentRect||f.rect}else t&&t.enableLayoutOnlyByCenter&&o.dataToPoint&&(i=dp.point,s=c,a=o.dataToPoint(u))}return i==null&&(i=dp.rect),i===dp.rect&&(n||(n={x:0,y:0,width:e.getWidth(),height:e.getHeight()}),a=[n.x+n.width/2,n.y+n.height/2]),{type:i,refContainer:n,refPoint:a,boxCoordFrom:s}}function fb(r,e,t,n,a,i){var o=!a||!a.hv||a.hv[0],s=!a||!a.hv||a.hv[1],l=a&&a.boundingMode||"all";if(i=i||r,i.x=r.x,i.y=r.y,!o&&!s)return!1;var u;if(l==="raw")u=r.type==="group"?new Oe(0,0,+e.width||0,+e.height||0):r.getBoundingRect();else if(u=r.getBoundingRect(),r.needLocalTransform()){var c=r.getLocalTransform();u=u.clone(),u.applyTransform(c)}var f=Ht(Re({width:u.width,height:u.height},e),t,n),d=o?f.x-u.x:0,v=s?f.y-u.y:0;return l==="raw"?(i.x=d,i.y=v):(i.x+=d,i.y+=v),i===r&&r.markRedraw(),!0}function Vie(r,e){return r[Vu[e][0]]!=null||r[Vu[e][1]]!=null&&r[Vu[e][2]]!=null}function ig(r){var e=r.layoutMode||r.constructor.layoutMode;return Ee(e)?e:e?{type:e}:null}function Zi(r,e,t){var n=t&&t.ignoreSize;!ce(n)&&(n=[n,n]);var a=o(Vu[0],0),i=o(Vu[1],1);l(Vu[0],r,a),l(Vu[1],r,i);function o(u,c){var f={},d=0,v={},g=0,y=2;if(ax(u,function(w){v[w]=r[w]}),ax(u,function(w){_e(e,w)&&(f[w]=v[w]=e[w]),s(f,w)&&d++,s(v,w)&&g++}),n[c])return s(e,u[1])?v[u[2]]=null:s(e,u[2])&&(v[u[1]]=null),v;if(g===y||!d)return v;if(d>=y)return f;for(var x=0;x<u.length;x++){var b=u[x];if(!_e(f,b)&&_e(r,b)){f[b]=r[b];break}}return f}function s(u,c){return u[c]!=null&&u[c]!=="auto"}function l(u,c,f){ax(u,function(d){c[d]=f[d]})}}function Sc(r){return y8({},r)}function y8(r,e){return e&&r&&ax(v8,function(t){_e(e,t)&&(r[t]=e[t])}),r}var Gie=Je(),Qe=(function(r){K(e,r);function e(t,n,a){var i=r.call(this,t,n,a)||this;return i.uid=od("ec_cpt_model"),i}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a)},e.prototype.mergeDefaultAndTheme=function(t,n){var a=ig(this),i=a?Sc(t):{},o=n.getTheme();Ye(t,o.get(this.mainType)),Ye(t,this.getDefaultOption()),a&&Zi(t,i,a)},e.prototype.mergeOption=function(t,n){Ye(this.option,t,!0);var a=ig(this);a&&Zi(this.option,t,a)},e.prototype.optionUpdated=function(t,n){},e.prototype.getDefaultOption=function(){var t=this.constructor;if(!Sne(t))return t.defaultOption;var n=Gie(this);if(!n.defaultOption){for(var a=[],i=t;i;){var o=i.prototype.defaultOption;o&&a.push(o),i=i.superClass}for(var s={},l=a.length-1;l>=0;l--)s=Ye(s,a[l],!0);n.defaultOption=s}return n.defaultOption},e.prototype.getReferringComponents=function(t,n){var a=t+"Index",i=t+"Id";return Jh(this.ecModel,t,{index:this.get(a,!0),id:this.get(i,!0)},n)},e.prototype.getBoxLayoutParams=function(){return p8(this,!1)},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=(function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0})(),e})(et);dH(Qe,et);eb(Qe);gie(Qe);mie(Qe,Hie);function Hie(r){var e=[];return O(Qe.getClassesByMainType(r),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=fe(e,function(t){return ji(t).main}),r!=="dataset"&&Fe(e,"dataset")<=0&&e.unshift("dataset"),e}var ee={color:{},darkColor:{},size:{}},ar=ee.color={theme:["#5070dd","#b6d634","#505372","#ff994d","#0ca8df","#ffd10a","#fb628b","#785db0","#3fbe95"],neutral00:"#fff",neutral05:"#f4f7fd",neutral10:"#e8ebf0",neutral15:"#dbdee4",neutral20:"#cfd2d7",neutral25:"#c3c5cb",neutral30:"#b7b9be",neutral35:"#aaacb2",neutral40:"#9ea0a5",neutral45:"#929399",neutral50:"#86878c",neutral55:"#797b7f",neutral60:"#6d6e73",neutral65:"#616266",neutral70:"#54555a",neutral75:"#48494d",neutral80:"#3c3c41",neutral85:"#303034",neutral90:"#232328",neutral95:"#17171b",neutral99:"#000",accent05:"#eff1f9",accent10:"#e0e4f2",accent15:"#d0d6ec",accent20:"#c0c9e6",accent25:"#b1bbdf",accent30:"#a1aed9",accent35:"#91a0d3",accent40:"#8292cc",accent45:"#7285c6",accent50:"#6578ba",accent55:"#5c6da9",accent60:"#536298",accent65:"#4a5787",accent70:"#404c76",accent75:"#374165",accent80:"#2e3654",accent85:"#252b43",accent90:"#1b2032",accent95:"#121521",transparent:"rgba(0,0,0,0)",highlight:"rgba(255,231,130,0.8)"};ie(ar,{primary:ar.neutral80,secondary:ar.neutral70,tertiary:ar.neutral60,quaternary:ar.neutral50,disabled:ar.neutral20,border:ar.neutral30,borderTint:ar.neutral20,borderShade:ar.neutral40,background:ar.neutral05,backgroundTint:"rgba(234,237,245,0.5)",backgroundTransparent:"rgba(255,255,255,0)",backgroundShade:ar.neutral10,shadow:"rgba(0,0,0,0.2)",shadowTint:"rgba(129,130,136,0.2)",axisLine:ar.neutral70,axisLineTint:ar.neutral40,axisTick:ar.neutral70,axisTickMinor:ar.neutral60,axisLabel:ar.neutral70,axisSplitLine:ar.neutral15,axisMinorSplitLine:ar.neutral05});for(var pu in ar)if(ar.hasOwnProperty(pu)){var UP=ar[pu];pu==="theme"?ee.darkColor.theme=ar.theme.slice():pu==="highlight"?ee.darkColor.highlight="rgba(255,231,130,0.4)":pu.indexOf("accent")===0?ee.darkColor[pu]=Go(UP,null,function(r){return r*.5},function(r){return Math.min(1,1.3-r)}):ee.darkColor[pu]=Go(UP,null,function(r){return r*.9},function(r){return 1-Math.pow(r,1.5)})}ee.size={xxs:2,xs:5,s:10,m:15,l:20,xl:30,xxl:40,xxxl:50};var x8="";typeof navigator<"u"&&(x8=navigator.platform||"");var wf="rgba(0, 0, 0, 0.2)",b8=ee.color.theme[0],Fie=Go(b8,null,null,.9);const Uie={darkMode:"auto",colorBy:"series",color:ee.color.theme,gradientColor:[Fie,b8],aria:{decal:{decals:[{color:wf,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:wf,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:wf,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:wf,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:wf,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:wf,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:x8.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};var _8=Te(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),la="original",Yr="arrayRows",ua="objectRows",li="keyedColumns",vl="typedArray",S8="unknown",ri="column",wc="row",$r={Must:1,Might:2,Not:3},w8=Je();function Yie(r){w8(r).datasetMap=Te()}function T8(r,e,t){var n={},a=FD(e);if(!a||!r)return n;var i=[],o=[],s=e.ecModel,l=w8(s).datasetMap,u=a.uid+"_"+t.seriesLayoutBy,c,f;r=r.slice(),O(r,function(y,x){var b=Ee(y)?y:r[x]={name:y};b.type==="ordinal"&&c==null&&(c=x,f=g(b)),n[b.name]=[]});var d=l.get(u)||l.set(u,{categoryWayDim:f,valueWayDim:0});O(r,function(y,x){var b=y.name,w=g(y);if(c==null){var T=d.valueWayDim;v(n[b],T,w),v(o,T,w),d.valueWayDim+=w}else if(c===x)v(n[b],0,w),v(i,0,w);else{var T=d.categoryWayDim;v(n[b],T,w),v(o,T,w),d.categoryWayDim+=w}});function v(y,x,b){for(var w=0;w<b;w++)y.push(x+w)}function g(y){var x=y.dimsDef;return x?x.length:1}return i.length&&(n.itemName=i),o.length&&(n.seriesName=o),n}function HD(r,e,t){var n={},a=FD(r);if(!a)return n;var i=e.sourceFormat,o=e.dimensionsDefine,s;(i===ua||i===li)&&O(o,function(c,f){(Ee(c)?c.name:c)==="name"&&(s=f)});var l=(function(){for(var c={},f={},d=[],v=0,g=Math.min(5,t);v<g;v++){var y=A8(e.data,i,e.seriesLayoutBy,o,e.startIndex,v);d.push(y);var x=y===$r.Not;if(x&&c.v==null&&v!==s&&(c.v=v),(c.n==null||c.n===c.v||!x&&d[c.n]===$r.Not)&&(c.n=v),b(c)&&d[c.n]!==$r.Not)return c;x||(y===$r.Might&&f.v==null&&v!==s&&(f.v=v),(f.n==null||f.n===f.v)&&(f.n=v))}function b(w){return w.v!=null&&w.n!=null}return b(c)?c:b(f)?f:null})();if(l){n.value=[l.v];var u=s??l.n;n.itemName=[u],n.seriesName=[u]}return n}function FD(r){var e=r.get("data",!0);if(!e)return Jh(r.ecModel,"dataset",{index:r.get("datasetIndex",!0),id:r.get("datasetId",!0)},Zt).models[0]}function Wie(r){return!r.get("transform",!0)&&!r.get("fromTransformResult",!0)?[]:Jh(r.ecModel,"dataset",{index:r.get("fromDatasetIndex",!0),id:r.get("fromDatasetId",!0)},Zt).models}function C8(r,e){return A8(r.data,r.sourceFormat,r.seriesLayoutBy,r.dimensionsDefine,r.startIndex,e)}function A8(r,e,t,n,a,i){var o,s=5;if(Tn(r))return $r.Not;var l,u;if(n){var c=n[i];Ee(c)?(l=c.name,u=c.type):ye(c)&&(l=c)}if(u!=null)return u==="ordinal"?$r.Must:$r.Not;if(e===Yr){var f=r;if(t===wc){for(var d=f[i],v=0;v<(d||[]).length&&v<s;v++)if((o=C(d[a+v]))!=null)return o}else for(var v=0;v<f.length&&v<s;v++){var g=f[a+v];if(g&&(o=C(g[i]))!=null)return o}}else if(e===ua){var y=r;if(!l)return $r.Not;for(var v=0;v<y.length&&v<s;v++){var x=y[v];if(x&&(o=C(x[l]))!=null)return o}}else if(e===li){var b=r;if(!l)return $r.Not;var d=b[l];if(!d||Tn(d))return $r.Not;for(var v=0;v<d.length&&v<s;v++)if((o=C(d[v]))!=null)return o}else if(e===la)for(var w=r,v=0;v<w.length&&v<s;v++){var x=w[v],T=Qh(x);if(!ce(T))return $r.Not;if((o=C(T[i]))!=null)return o}function C(D){var M=ye(D);if(D!=null&&Number.isFinite(Number(D))&&D!=="")return M?$r.Might:$r.Not;if(M&&D!=="-")return $r.Must}return $r.Not}var ZC=Te();function Xie(r,e){rn(ZC.get(r)==null&&e),ZC.set(r,e)}function qie(r,e,t){var n=ZC.get(e);if(!n)return t;var a=n(r);return a?t.concat(a):t}var YP=Je(),Zie=Je(),UD=(function(){function r(){}return r.prototype.getColorFromPalette=function(e,t,n){var a=Lt(this.get("color",!0)),i=this.get("colorLayer",!0);return M8(this,YP,a,i,e,t,n)},r.prototype.clearColorPalette=function(){Kie(this,YP)},r})();function $C(r,e,t,n){var a=Lt(r.get(["aria","decal","decals"]));return M8(r,Zie,a,null,e,t,n)}function $ie(r,e){for(var t=r.length,n=0;n<t;n++)if(r[n].length>e)return r[n];return r[t-1]}function M8(r,e,t,n,a,i,o){i=i||r;var s=e(i),l=s.paletteIdx||0,u=s.paletteNameMap=s.paletteNameMap||{};if(u.hasOwnProperty(a))return u[a];var c=o==null||!n?t:$ie(n,o);if(c=c||t,!(!c||!c.length)){var f=c[l];return a&&(u[a]=f),s.paletteIdx=(l+1)%c.length,f}}function Kie(r,e){e(r).paletteIdx=0,e(r).paletteNameMap={}}var Xy,Dv,WP,XP="\0_ec_inner",Qie=1,YD=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t,n,a,i,o,s){i=i||{},this.option=null,this._theme=new et(i),this._locale=new et(o),this._optionManager=s},e.prototype.setOption=function(t,n,a){var i=$P(n);this._optionManager.setOption(t,a,i),this._resetOption(null,i)},e.prototype.resetOption=function(t,n){return this._resetOption(t,$P(n))},e.prototype._resetOption=function(t,n){var a=!1,i=this._optionManager;if(!t||t==="recreate"){var o=i.mountOption(t==="recreate");!this.option||t==="recreate"?WP(this,o):(this.restoreData(),this._mergeOption(o,n)),a=!0}if((t==="timeline"||t==="media")&&this.restoreData(),!t||t==="recreate"||t==="timeline"){var s=i.getTimelineOption(this);s&&(a=!0,this._mergeOption(s,n))}if(!t||t==="recreate"||t==="media"){var l=i.getMediaOption(this);l.length&&O(l,function(u){a=!0,this._mergeOption(u,n)},this)}return a},e.prototype.mergeOption=function(t){this._mergeOption(t,null)},e.prototype._mergeOption=function(t,n){var a=this.option,i=this._componentsMap,o=this._componentsCount,s=[],l=Te(),u=n&&n.replaceMergeMainTypeMap;Yie(this),O(t,function(f,d){f!=null&&(Qe.hasClass(d)?d&&(s.push(d),l.set(d,!0)):a[d]=a[d]==null?De(f):Ye(a[d],f,!0))}),u&&u.each(function(f,d){Qe.hasClass(d)&&!l.get(d)&&(s.push(d),l.set(d,!0))}),Qe.topologicalTravel(s,Qe.getAllClassMainTypes(),c,this);function c(f){var d=qie(this,f,Lt(t[f])),v=i.get(f),g=v?u&&u.get(f)?"replaceMerge":"normalMerge":"replaceAll",y=lH(v,d,g);dne(y,f,Qe),a[f]=null,i.set(f,null),o.set(f,0);var x=[],b=[],w=0,T;O(y,function(C,D){var M=C.existing,N=C.newOption;if(!N)M&&(M.mergeOption({},this),M.optionUpdated({},!1));else{var R=f==="series",E=Qe.getClass(f,C.keyInfo.subType,!R);if(!E)return;if(f==="tooltip"){if(T)return;T=!0}if(M&&M.constructor===E)M.name=C.keyInfo.name,M.mergeOption(N,this),M.optionUpdated(N,!1);else{var k=ie({componentIndex:D},C.keyInfo);M=new E(N,this,this,k),ie(M,k),C.brandNew&&(M.__requireNewView=!0),M.init(N,this,this),M.optionUpdated(null,!0)}}M?(x.push(M.option),b.push(M),w++):(x.push(void 0),b.push(void 0))},this),a[f]=x,i.set(f,b),o.set(f,w),f==="series"&&Xy(this)}this._seriesIndices||Xy(this)},e.prototype.getOption=function(){var t=De(this.option);return O(t,function(n,a){if(Qe.hasClass(a)){for(var i=Lt(n),o=i.length,s=!1,l=o-1;l>=0;l--)i[l]&&!eg(i[l])?s=!0:(i[l]=null,!s&&o--);i.length=o,t[a]=i}}),delete t[XP],t},e.prototype.setTheme=function(t){this._theme=new et(t),this._resetOption("recreate",null)},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,n){var a=this._componentsMap.get(t);if(a){var i=a[n||0];if(i)return i;if(n==null){for(var o=0;o<a.length;o++)if(a[o])return a[o]}}},e.prototype.queryComponents=function(t){var n=t.mainType;if(!n)return[];var a=t.index,i=t.id,o=t.name,s=this._componentsMap.get(n);if(!s||!s.length)return[];var l;return a!=null?(l=[],O(Lt(a),function(u){s[u]&&l.push(s[u])})):i!=null?l=qP("id",i,s):o!=null?l=qP("name",o,s):l=dt(s,function(u){return!!u}),ZP(l,t)},e.prototype.findComponents=function(t){var n=t.query,a=t.mainType,i=s(n),o=i?this.queryComponents(i):dt(this._componentsMap.get(a),function(u){return!!u});return l(ZP(o,t));function s(u){var c=a+"Index",f=a+"Id",d=a+"Name";return u&&(u[c]!=null||u[f]!=null||u[d]!=null)?{mainType:a,index:u[c],id:u[f],name:u[d]}:null}function l(u){return t.filter?dt(u,t.filter):u}},e.prototype.eachComponent=function(t,n,a){var i=this._componentsMap;if(Me(t)){var o=n,s=t;i.each(function(f,d){for(var v=0;f&&v<f.length;v++){var g=f[v];g&&s.call(o,d,g,g.componentIndex)}})}else for(var l=ye(t)?i.get(t):Ee(t)?this.findComponents(t):null,u=0;l&&u<l.length;u++){var c=l[u];c&&n.call(a,c,c.componentIndex)}},e.prototype.getSeriesByName=function(t){var n=xr(t,null);return dt(this._componentsMap.get("series"),function(a){return!!a&&n!=null&&a.name===n})},e.prototype.getSeriesByIndex=function(t){return this._componentsMap.get("series")[t]},e.prototype.getSeriesByType=function(t){return dt(this._componentsMap.get("series"),function(n){return!!n&&n.subType===t})},e.prototype.getSeries=function(){return dt(this._componentsMap.get("series"),function(t){return!!t})},e.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},e.prototype.eachSeries=function(t,n){Dv(this),O(this._seriesIndices,function(a){var i=this._componentsMap.get("series")[a];t.call(n,i,a)},this)},e.prototype.eachRawSeries=function(t,n){O(this._componentsMap.get("series"),function(a){a&&t.call(n,a,a.componentIndex)})},e.prototype.eachSeriesByType=function(t,n,a){Dv(this),O(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];o.subType===t&&n.call(a,o,i)},this)},e.prototype.eachRawSeriesByType=function(t,n,a){return O(this.getSeriesByType(t),n,a)},e.prototype.isSeriesFiltered=function(t){return Dv(this),this._seriesIndicesMap.get(t.componentIndex)==null},e.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},e.prototype.filterSeries=function(t,n){Dv(this);var a=[];O(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];t.call(n,o,i)&&a.push(i)},this),this._seriesIndices=a,this._seriesIndicesMap=Te(a)},e.prototype.restoreData=function(t){Xy(this);var n=this._componentsMap,a=[];n.each(function(i,o){Qe.hasClass(o)&&a.push(o)}),Qe.topologicalTravel(a,Qe.getAllClassMainTypes(),function(i){O(n.get(i),function(o){o&&(i!=="series"||!Jie(o,t))&&o.restoreData()})})},e.internalField=(function(){Xy=function(t){var n=t._seriesIndices=[];O(t._componentsMap.get("series"),function(a){a&&n.push(a.componentIndex)}),t._seriesIndicesMap=Te(n)},Dv=function(t){},WP=function(t,n){t.option={},t.option[XP]=Qie,t._componentsMap=Te({series:[]}),t._componentsCount=Te();var a=n.aria;Ee(a)&&a.enabled==null&&(a.enabled=!0),eoe(n,t._theme.option),Ye(n,Uie,!1),t._mergeOption(n,null)}})(),e})(et);function Jie(r,e){if(e){var t=e.seriesIndex,n=e.seriesId,a=e.seriesName;return t!=null&&r.componentIndex!==t||n!=null&&r.id!==n||a!=null&&r.name!==a}}function eoe(r,e){var t=r.color&&!r.colorLayer;O(e,function(n,a){a==="colorLayer"&&t||a==="color"&&r.color||Qe.hasClass(a)||(typeof n=="object"?r[a]=r[a]?Ye(r[a],n,!1):De(n):r[a]==null&&(r[a]=n))})}function qP(r,e,t){if(ce(e)){var n=Te();return O(e,function(i){if(i!=null){var o=xr(i,null);o!=null&&n.set(i,!0)}}),dt(t,function(i){return i&&n.get(i[r])})}else{var a=xr(e,null);return dt(t,function(i){return i&&a!=null&&i[r]===a})}}function ZP(r,e){return e.hasOwnProperty("subType")?dt(r,function(t){return t&&t.subType===e.subType}):r}function $P(r){var e=Te();return r&&O(Lt(r.replaceMerge),function(t){e.set(t,!0)}),{replaceMergeMainTypeMap:e}}Jt(YD,UD);var toe=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],D8=(function(){function r(e){O(toe,function(t){this[t]=xe(e[t],e)},this)}return r})(),roe=/^(min|max)?(.+)$/,noe=(function(){function r(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return r.prototype.setOption=function(e,t,n){e&&(O(Lt(e.series),function(o){o&&o.data&&Tn(o.data)&&Xp(o.data)}),O(Lt(e.dataset),function(o){o&&o.source&&Tn(o.source)&&Xp(o.source)})),e=De(e);var a=this._optionBackup,i=aoe(e,t,!a);this._newBaseOption=i.baseOption,a?(i.timelineOptions.length&&(a.timelineOptions=i.timelineOptions),i.mediaList.length&&(a.mediaList=i.mediaList),i.mediaDefault&&(a.mediaDefault=i.mediaDefault)):this._optionBackup=i},r.prototype.mountOption=function(e){var t=this._optionBackup;return this._timelineOptions=t.timelineOptions,this._mediaList=t.mediaList,this._mediaDefault=t.mediaDefault,this._currentMediaIndices=[],De(e?t.baseOption:this._newBaseOption)},r.prototype.getTimelineOption=function(e){var t,n=this._timelineOptions;if(n.length){var a=e.getComponent("timeline");a&&(t=De(n[a.getCurrentIndex()]))}return t},r.prototype.getMediaOption=function(e){var t=this._api.getWidth(),n=this._api.getHeight(),a=this._mediaList,i=this._mediaDefault,o=[],s=[];if(!a.length&&!i)return s;for(var l=0,u=a.length;l<u;l++)ioe(a[l].query,t,n)&&o.push(l);return!o.length&&i&&(o=[-1]),o.length&&!soe(o,this._currentMediaIndices)&&(s=fe(o,function(c){return De(c===-1?i.option:a[c].option)})),this._currentMediaIndices=o,s},r})();function aoe(r,e,t){var n=[],a,i,o=r.baseOption,s=r.timeline,l=r.options,u=r.media,c=!!r.media,f=!!(l||s||o&&o.timeline);o?(i=o,i.timeline||(i.timeline=s)):((f||c)&&(r.options=r.media=null),i=r),c&&ce(u)&&O(u,function(v){v&&v.option&&(v.query?n.push(v):a||(a=v))}),d(i),O(l,function(v){return d(v)}),O(n,function(v){return d(v.option)});function d(v){O(e,function(g){g(v,t)})}return{baseOption:i,timelineOptions:l||[],mediaDefault:a,mediaList:n}}function ioe(r,e,t){var n={width:e,height:t,aspectratio:e/t},a=!0;return O(r,function(i,o){var s=o.match(roe);if(!(!s||!s[1]||!s[2])){var l=s[1],u=s[2].toLowerCase();ooe(n[u],i,l)||(a=!1)}}),a}function ooe(r,e,t){return t==="min"?r>=e:t==="max"?r<=e:r===e}function soe(r,e){return r.join(",")===e.join(",")}var Ya=O,og=Ee,KP=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Fw(r){var e=r&&r.itemStyle;if(e)for(var t=0,n=KP.length;t<n;t++){var a=KP[t],i=e.normal,o=e.emphasis;i&&i[a]&&(r[a]=r[a]||{},r[a].normal?Ye(r[a].normal,i[a]):r[a].normal=i[a],i[a]=null),o&&o[a]&&(r[a]=r[a]||{},r[a].emphasis?Ye(r[a].emphasis,o[a]):r[a].emphasis=o[a],o[a]=null)}}function hn(r,e,t){if(r&&r[e]&&(r[e].normal||r[e].emphasis)){var n=r[e].normal,a=r[e].emphasis;n&&(t?(r[e].normal=r[e].emphasis=null,Re(r[e],n)):r[e]=n),a&&(r.emphasis=r.emphasis||{},r.emphasis[e]=a,a.focus&&(r.emphasis.focus=a.focus),a.blurScope&&(r.emphasis.blurScope=a.blurScope))}}function vp(r){hn(r,"itemStyle"),hn(r,"lineStyle"),hn(r,"areaStyle"),hn(r,"label"),hn(r,"labelLine"),hn(r,"upperLabel"),hn(r,"edgeLabel")}function hr(r,e){var t=og(r)&&r[e],n=og(t)&&t.textStyle;if(n)for(var a=0,i=eP.length;a<i;a++){var o=eP[a];n.hasOwnProperty(o)&&(t[o]=n[o])}}function Ta(r){r&&(vp(r),hr(r,"label"),r.emphasis&&hr(r.emphasis,"label"))}function loe(r){if(og(r)){Fw(r),vp(r),hr(r,"label"),hr(r,"upperLabel"),hr(r,"edgeLabel"),r.emphasis&&(hr(r.emphasis,"label"),hr(r.emphasis,"upperLabel"),hr(r.emphasis,"edgeLabel"));var e=r.markPoint;e&&(Fw(e),Ta(e));var t=r.markLine;t&&(Fw(t),Ta(t));var n=r.markArea;n&&Ta(n);var a=r.data;if(r.type==="graph"){a=a||r.nodes;var i=r.links||r.edges;if(i&&!Tn(i))for(var o=0;o<i.length;o++)Ta(i[o]);O(r.categories,function(u){vp(u)})}if(a&&!Tn(a))for(var o=0;o<a.length;o++)Ta(a[o]);if(e=r.markPoint,e&&e.data)for(var s=e.data,o=0;o<s.length;o++)Ta(s[o]);if(t=r.markLine,t&&t.data)for(var l=t.data,o=0;o<l.length;o++)ce(l[o])?(Ta(l[o][0]),Ta(l[o][1])):Ta(l[o]);r.type==="gauge"?(hr(r,"axisLabel"),hr(r,"title"),hr(r,"detail")):r.type==="treemap"?(hn(r.breadcrumb,"itemStyle"),O(r.levels,function(u){vp(u)})):r.type==="tree"&&vp(r.leaves)}}function bo(r){return ce(r)?r:r?[r]:[]}function QP(r){return(ce(r)?r[0]:r)||{}}function uoe(r,e){Ya(bo(r.series),function(n){og(n)&&loe(n)});var t=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&t.push("valueAxis","categoryAxis","logAxis","timeAxis"),Ya(t,function(n){Ya(bo(r[n]),function(a){a&&(hr(a,"axisLabel"),hr(a.axisPointer,"label"))})}),Ya(bo(r.parallel),function(n){var a=n&&n.parallelAxisDefault;hr(a,"axisLabel"),hr(a&&a.axisPointer,"label")}),Ya(bo(r.calendar),function(n){hn(n,"itemStyle"),hr(n,"dayLabel"),hr(n,"monthLabel"),hr(n,"yearLabel")}),Ya(bo(r.radar),function(n){hr(n,"name"),n.name&&n.axisName==null&&(n.axisName=n.name,delete n.name),n.nameGap!=null&&n.axisNameGap==null&&(n.axisNameGap=n.nameGap,delete n.nameGap)}),Ya(bo(r.geo),function(n){og(n)&&(Ta(n),Ya(bo(n.regions),function(a){Ta(a)}))}),Ya(bo(r.timeline),function(n){Ta(n),hn(n,"label"),hn(n,"itemStyle"),hn(n,"controlStyle",!0);var a=n.data;ce(a)&&O(a,function(i){Ee(i)&&(hn(i,"label"),hn(i,"itemStyle"))})}),Ya(bo(r.toolbox),function(n){hn(n,"iconStyle"),Ya(n.feature,function(a){hn(a,"iconStyle")})}),hr(QP(r.axisPointer),"label"),hr(QP(r.tooltip).axisPointer,"label")}function coe(r,e){for(var t=e.split(","),n=r,a=0;a<t.length&&(n=n&&n[t[a]],n!=null);a++);return n}function foe(r,e,t,n){for(var a=e.split(","),i=r,o,s=0;s<a.length-1;s++)o=a[s],i[o]==null&&(i[o]={}),i=i[o];i[a[s]]==null&&(i[a[s]]=t)}function JP(r){r&&O(hoe,function(e){e[0]in r&&!(e[1]in r)&&(r[e[1]]=r[e[0]])})}var hoe=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],doe=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],Uw=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function Nv(r){var e=r&&r.itemStyle;if(e)for(var t=0;t<Uw.length;t++){var n=Uw[t][1],a=Uw[t][0];e[n]!=null&&(e[a]=e[n])}}function e5(r){r&&r.alignTo==="edge"&&r.margin!=null&&r.edgeDistance==null&&(r.edgeDistance=r.margin)}function t5(r){r&&r.downplay&&!r.blur&&(r.blur=r.downplay)}function voe(r){r&&r.focusNodeAdjacency!=null&&(r.emphasis=r.emphasis||{},r.emphasis.focus==null&&(r.emphasis.focus="adjacency"))}function N8(r,e){if(r)for(var t=0;t<r.length;t++)e(r[t]),r[t]&&N8(r[t].children,e)}function L8(r,e){uoe(r,e),r.series=Lt(r.series),O(r.series,function(t){if(Ee(t)){var n=t.type;if(n==="line")t.clipOverflow!=null&&(t.clip=t.clipOverflow);else if(n==="pie"||n==="gauge"){t.clockWise!=null&&(t.clockwise=t.clockWise),e5(t.label);var a=t.data;if(a&&!Tn(a))for(var i=0;i<a.length;i++)e5(a[i]);t.hoverOffset!=null&&(t.emphasis=t.emphasis||{},(t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset))}else if(n==="gauge"){var o=coe(t,"pointer.color");o!=null&&foe(t,"itemStyle.color",o)}else if(n==="bar"){Nv(t),Nv(t.backgroundStyle),Nv(t.emphasis);var a=t.data;if(a&&!Tn(a))for(var i=0;i<a.length;i++)typeof a[i]=="object"&&(Nv(a[i]),Nv(a[i]&&a[i].emphasis))}else if(n==="sunburst"){var s=t.highlightPolicy;s&&(t.emphasis=t.emphasis||{},t.emphasis.focus||(t.emphasis.focus=s)),t5(t),N8(t.data,t5)}else n==="graph"||n==="sankey"?voe(t):n==="map"&&(t.mapType&&!t.map&&(t.map=t.mapType),t.mapLocation&&Re(t,t.mapLocation));t.hoverAnimation!=null&&(t.emphasis=t.emphasis||{},t.emphasis&&t.emphasis.scale==null&&(t.emphasis.scale=t.hoverAnimation)),JP(t)}}),r.dataRange&&(r.visualMap=r.dataRange),O(doe,function(t){var n=r[t];n&&(ce(n)||(n=[n]),O(n,function(a){JP(a)}))})}function poe(r){var e=Te();r.eachSeries(function(t){var n=t.get("stack");if(n){var a=e.get(n)||e.set(n,[]),i=t.getData(),o={stackResultDimension:i.getCalculationInfo("stackResultDimension"),stackedOverDimension:i.getCalculationInfo("stackedOverDimension"),stackedDimension:i.getCalculationInfo("stackedDimension"),stackedByDimension:i.getCalculationInfo("stackedByDimension"),isStackedByIndex:i.getCalculationInfo("isStackedByIndex"),data:i,seriesModel:t};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;a.push(o)}}),e.each(function(t){if(t.length!==0){var n=t[0].seriesModel,a=n.get("stackOrder")||"seriesAsc";a==="seriesDesc"&&t.reverse(),O(t,function(i,o){i.data.setCalculationInfo("stackedOnSeries",o>0?t[o-1].seriesModel:null)}),goe(t)}})}function goe(r){O(r,function(e,t){var n=[],a=[NaN,NaN],i=[e.stackResultDimension,e.stackedOverDimension],o=e.data,s=e.isStackedByIndex,l=e.seriesModel.get("stackStrategy")||"samesign";o.modify(i,function(u,c,f){var d=o.get(e.stackedDimension,f);if(isNaN(d))return a;var v,g;s?g=o.getRawIndex(f):v=o.get(e.stackedByDimension,f);for(var y=NaN,x=t-1;x>=0;x--){var b=r[x];if(s||(g=b.data.rawIndexOf(b.stackedByDimension,v)),g>=0){var w=b.data.getByRawIndex(b.stackResultDimension,g);if(l==="all"||l==="positive"&&w>0||l==="negative"&&w<0||l==="samesign"&&d>=0&&w>0||l==="samesign"&&d<=0&&w<0){d=ene(d,w),y=w;break}}}return n[0]=d,n[1]=y,n})})}var hb=(function(){function r(e){this.data=e.data||(e.sourceFormat===li?{}:[]),this.sourceFormat=e.sourceFormat||S8,this.seriesLayoutBy=e.seriesLayoutBy||ri,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 a=t[n];a.type==null&&C8(this,n)===$r.Must&&(a.type="ordinal")}}return r})();function WD(r){return r instanceof hb}function KC(r,e,t){t=t||R8(r);var n=e.seriesLayoutBy,a=yoe(r,t,n,e.sourceHeader,e.dimensions),i=new hb({data:r,sourceFormat:t,seriesLayoutBy:n,dimensionsDefine:a.dimensionsDefine,startIndex:a.startIndex,dimensionsDetectedCount:a.dimensionsDetectedCount,metaRawOption:De(e)});return i}function XD(r){return new hb({data:r,sourceFormat:Tn(r)?vl:la})}function moe(r){return new hb({data:r.data,sourceFormat:r.sourceFormat,seriesLayoutBy:r.seriesLayoutBy,dimensionsDefine:De(r.dimensionsDefine),startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount})}function R8(r){var e=S8;if(Tn(r))e=vl;else if(ce(r)){r.length===0&&(e=Yr);for(var t=0,n=r.length;t<n;t++){var a=r[t];if(a!=null){if(ce(a)||Tn(a)){e=Yr;break}else if(Ee(a)){e=ua;break}}}}else if(Ee(r)){for(var i in r)if(_e(r,i)&&tn(r[i])){e=li;break}}return e}function yoe(r,e,t,n,a){var i,o;if(!r)return{dimensionsDefine:r5(a),startIndex:o,dimensionsDetectedCount:i};if(e===Yr){var s=r;n==="auto"||n==null?n5(function(u){u!=null&&u!=="-"&&(ye(u)?o==null&&(o=1):o=0)},t,s,10):o=st(n)?n:n?1:0,!a&&o===1&&(a=[],n5(function(u,c){a[c]=u!=null?u+"":""},t,s,1/0)),i=a?a.length:t===wc?s.length:s[0]?s[0].length:null}else if(e===ua)a||(a=xoe(r));else if(e===li)a||(a=[],O(r,function(u,c){a.push(c)}));else if(e===la){var l=Qh(r[0]);i=ce(l)&&l.length||1}return{startIndex:o,dimensionsDefine:r5(a),dimensionsDetectedCount:i}}function xoe(r){for(var e=0,t;e<r.length&&!(t=r[e++]););if(t)return it(t)}function r5(r){if(r){var e=Te();return fe(r,function(t,n){t=Ee(t)?t:{name:t};var a={name:t.name,displayName:t.displayName,type:t.type};if(a.name==null)return a;a.name+="",a.displayName==null&&(a.displayName=a.name);var i=e.get(a.name);return i?a.name+="-"+i.count++:e.set(a.name,{count:1}),a})}}function n5(r,e,t,n){if(e===wc)for(var a=0;a<t.length&&a<n;a++)r(t[a]?t[a][0]:null,a);else for(var i=t[0]||[],a=0;a<i.length&&a<n;a++)r(i[a],a)}function E8(r){var e=r.sourceFormat;return e===ua||e===li}var gu,mu,yu,xu,a5,i5,k8=(function(){function r(e,t){var n=WD(e)?e:XD(e);this._source=n;var a=this._data=n.data,i=n.sourceFormat;n.seriesLayoutBy,i===vl&&(this._offset=0,this._dimSize=t,this._data=a),i5(this,a,n)}return r.prototype.getSource=function(){return this._source},r.prototype.count=function(){return 0},r.prototype.getItem=function(e,t){},r.prototype.appendData=function(e){},r.prototype.clean=function(){},r.protoInitialize=(function(){var e=r.prototype;e.pure=!1,e.persistent=!0})(),r.internalField=(function(){var e;i5=function(o,s,l){var u=l.sourceFormat,c=l.seriesLayoutBy,f=l.startIndex,d=l.dimensionsDefine,v=a5[qD(u,c)];if(ie(o,v),u===vl)o.getItem=t,o.count=a,o.fillStorage=n;else{var g=I8(u,c);o.getItem=xe(g,null,s,f,d);var y=O8(u,c);o.count=xe(y,null,s,f,d)}};var t=function(o,s){o=o-this._offset,s=s||[];for(var l=this._data,u=this._dimSize,c=u*o,f=0;f<u;f++)s[f]=l[c+f];return s},n=function(o,s,l,u){for(var c=this._data,f=this._dimSize,d=0;d<f;d++){for(var v=u[d],g=v[0]==null?1/0:v[0],y=v[1]==null?-1/0:v[1],x=s-o,b=l[d],w=0;w<x;w++){var T=c[w*f+d];b[o+w]=T,T<g&&(g=T),T>y&&(y=T)}v[0]=g,v[1]=y}},a=function(){return this._data?this._data.length/this._dimSize:0};a5=(e={},e[Yr+"_"+ri]={pure:!0,appendData:i},e[Yr+"_"+wc]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[ua]={pure:!0,appendData:i},e[li]={pure:!0,appendData:function(o){var s=this._data;O(o,function(l,u){for(var c=s[u]||(s[u]=[]),f=0;f<(l||[]).length;f++)c.push(l[f])})}},e[la]={appendData:i},e[vl]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},e);function i(o){for(var s=0;s<o.length;s++)this._data.push(o[s])}})(),r})(),qy=function(r){ce(r)||iH("series.data or dataset.source must be an array.")};gu={},gu[Yr+"_"+ri]=qy,gu[Yr+"_"+wc]=qy,gu[ua]=qy,gu[li]=function(r,e){for(var t=0;t<e.length;t++){var n=e[t].name;n==null&&iH("dimension name must not be null/undefined.")}},gu[la]=qy;var o5=function(r,e,t,n){return r[n]},boe=(mu={},mu[Yr+"_"+ri]=function(r,e,t,n){return r[n+e]},mu[Yr+"_"+wc]=function(r,e,t,n,a){n+=e;for(var i=a||[],o=r,s=0;s<o.length;s++){var l=o[s];i[s]=l?l[n]:null}return i},mu[ua]=o5,mu[li]=function(r,e,t,n,a){for(var i=a||[],o=0;o<t.length;o++){var s=t[o].name,l=s!=null?r[s]:null;i[o]=l?l[n]:null}return i},mu[la]=o5,mu);function I8(r,e){var t=boe[qD(r,e)];return t}var s5=function(r,e,t){return r.length},_oe=(yu={},yu[Yr+"_"+ri]=function(r,e,t){return Math.max(0,r.length-e)},yu[Yr+"_"+wc]=function(r,e,t){var n=r[0];return n?Math.max(0,n.length-e):0},yu[ua]=s5,yu[li]=function(r,e,t){var n=t[0].name,a=n!=null?r[n]:null;return a?a.length:0},yu[la]=s5,yu);function O8(r,e){var t=_oe[qD(r,e)];return t}var Yw=function(r,e,t){return r[e]},Soe=(xu={},xu[Yr]=Yw,xu[ua]=function(r,e,t){return r[t]},xu[li]=Yw,xu[la]=function(r,e,t){var n=Qh(r);return n instanceof Array?n[e]:n},xu[vl]=Yw,xu);function P8(r){var e=Soe[r];return e}function qD(r,e){return r===Yr?r+"_"+e:r}function jh(r,e,t){if(r){var n=r.getRawDataItem(e);if(n!=null){var a=r.getStore(),i=a.getSource().sourceFormat;if(t!=null){var o=r.getDimensionIndex(t),s=a.getDimensionProperty(o);return P8(i)(n,o,s)}else{var l=n;return i===la&&(l=Qh(n)),l}}}}var woe=/\{@(.+?)\}/g,db=(function(){function r(){}return r.prototype.getDataParams=function(e,t){var n=this.getData(t),a=this.getRawValue(e,t),i=n.getRawIndex(e),o=n.getName(e),s=n.getRawDataItem(e),l=n.getItemVisual(e,"style"),u=l&&l[n.getItemVisual(e,"drawType")||"fill"],c=l&&l.stroke,f=this.mainType,d=f==="series",v=n.userOutput&&n.userOutput.get();return{componentType:f,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:o,dataIndex:i,data:s,dataType:t,value:a,color:u,borderColor:c,dimensionNames:v?v.fullDimensions:null,encode:v?v.encode:null,$vars:["seriesName","name","value"]}},r.prototype.getFormattedLabel=function(e,t,n,a,i,o){t=t||"normal";var s=this.getData(n),l=this.getDataParams(e,n);if(o&&(l.value=o.interpolatedValue),a!=null&&ce(l.value)&&(l.value=l.value[a]),!i){var u=s.getItemModel(e);i=u.get(t==="normal"?["label","formatter"]:[t,"label","formatter"])}if(Me(i))return l.status=t,l.dimensionIndex=a,i(l);if(ye(i)){var c=VD(i,l);return c.replace(woe,function(f,d){var v=d.length,g=d;g.charAt(0)==="["&&g.charAt(v-1)==="]"&&(g=+g.slice(1,v-1));var y=jh(s,e,g);if(o&&ce(o.interpolatedValue)){var x=s.getDimensionIndex(g);x>=0&&(y=o.interpolatedValue[x])}return y!=null?y+"":""})}},r.prototype.getRawValue=function(e,t){return jh(this.getData(t),e)},r.prototype.formatTooltip=function(e,t,n){},r})();function l5(r){var e,t;return Ee(r)?r.type&&(t=r):e=r,{text:e,frag:t}}function Ip(r){return new Toe(r)}var Toe=(function(){function r(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return r.prototype.perform=function(e){var t=this._upstream,n=e&&e.skip;if(this._dirty&&t){var a=this.context;a.data=a.outputData=t.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var i;this._plan&&!n&&(i=this._plan(this.context));var o=c(this._modBy),s=this._modDataCount||0,l=c(e&&e.modBy),u=e&&e.modDataCount||0;(o!==l||s!==u)&&(i="reset");function c(w){return!(w>=1)&&(w=1),w}var f;(this._dirty||i==="reset")&&(this._dirty=!1,f=this._doReset(n)),this._modBy=l,this._modDataCount=u;var d=e&&e.step;if(t?this._dueEnd=t._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var v=this._dueIndex,g=Math.min(d!=null?this._dueIndex+d:1/0,this._dueEnd);if(!n&&(f||v<g)){var y=this._progress;if(ce(y))for(var x=0;x<y.length;x++)this._doProgress(y[x],v,g,l,u);else this._doProgress(y,v,g,l,u)}this._dueIndex=g;var b=this._settedOutputEnd!=null?this._settedOutputEnd:g;this._outputDueEnd=b}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},r.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},r.prototype._doProgress=function(e,t,n,a,i){u5.reset(t,n,a,i),this._callingProgress=e,this._callingProgress({start:t,end:n,count:n-t,next:u5.next},this.context)},r.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),ce(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var a=this._downstream;return a&&a.dirty(),n},r.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},r.prototype.pipe=function(e){(this._downstream!==e||this._dirty)&&(this._downstream=e,e._upstream=this,e.dirty())},r.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},r.prototype.getUpstream=function(){return this._upstream},r.prototype.getDownstream=function(){return this._downstream},r.prototype.setOutputEnd=function(e){this._outputDueEnd=this._settedOutputEnd=e},r})(),u5=(function(){var r,e,t,n,a,i={reset:function(l,u,c,f){e=l,r=u,t=c,n=f,a=Math.ceil(n/t),i.next=t>1&&n>0?s:o}};return i;function o(){return e<r?e++:null}function s(){var l=e%a*t+Math.ceil(e/a),u=e>=r?null:l<n?l:e;return e++,u}})();function pl(r,e){var t=e&&e.type;return t==="ordinal"?r:(t==="time"&&!st(r)&&r!=null&&r!=="-"&&(r=+Ji(r)),r==null||r===""?NaN:Number(r))}var Coe=Te({number:function(r){return parseFloat(r)},time:function(r){return+Ji(r)},trim:function(r){return ye(r)?ra(r):r}});function j8(r){return Coe.get(r)}var z8={lt:function(r,e){return r<e},lte:function(r,e){return r<=e},gt:function(r,e){return r>e},gte:function(r,e){return r>=e}},Aoe=(function(){function r(e,t){if(!st(t)){var n="";gt(n)}this._opFn=z8[e],this._rvalFloat=Xi(t)}return r.prototype.evaluate=function(e){return st(e)?this._opFn(e,this._rvalFloat):this._opFn(Xi(e),this._rvalFloat)},r})(),B8=(function(){function r(e,t){var n=e==="desc";this._resultLT=n?1:-1,t==null&&(t=n?"min":"max"),this._incomparable=t==="min"?-1/0:1/0}return r.prototype.evaluate=function(e,t){var n=st(e)?e:Xi(e),a=st(t)?t:Xi(t),i=isNaN(n),o=isNaN(a);if(i&&(n=this._incomparable),o&&(a=this._incomparable),i&&o){var s=ye(e),l=ye(t);s&&(n=l?e:0),l&&(a=s?t:0)}return n<a?this._resultLT:n>a?-this._resultLT:0},r})(),Moe=(function(){function r(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=Xi(t)}return r.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var n=typeof e;n!==this._rvalTypeof&&(n==="number"||this._rvalTypeof==="number")&&(t=Xi(e)===this._rvalFloat)}return this._isEQ?t:!t},r})();function Doe(r,e){return r==="eq"||r==="ne"?new Moe(r==="eq",e):_e(z8,r)?new Aoe(r,e):null}var Noe=(function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(e){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(e){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(e,t){},r.prototype.retrieveValueFromItem=function(e,t){},r.prototype.convertValue=function(e,t){return pl(e,t)},r})();function Loe(r,e){var t=new Noe,n=r.data,a=t.sourceFormat=r.sourceFormat,i=r.startIndex,o="";r.seriesLayoutBy!==ri&&gt(o);var s=[],l={},u=r.dimensionsDefine;if(u)O(u,function(y,x){var b=y.name,w={index:x,name:b,displayName:y.displayName};if(s.push(w),b!=null){var T="";_e(l,b)&&gt(T),l[b]=w}});else for(var c=0;c<r.dimensionsDetectedCount;c++)s.push({index:c});var f=I8(a,ri);e.__isBuiltIn&&(t.getRawDataItem=function(y){return f(n,i,s,y)},t.getRawData=xe(Roe,null,r)),t.cloneRawData=xe(Eoe,null,r);var d=O8(a,ri);t.count=xe(d,null,n,i,s);var v=P8(a);t.retrieveValue=function(y,x){var b=f(n,i,s,y);return g(b,x)};var g=t.retrieveValueFromItem=function(y,x){if(y!=null){var b=s[x];if(b)return v(y,x,b.name)}};return t.getDimensionInfo=xe(koe,null,s,l),t.cloneAllDimensionInfo=xe(Ioe,null,s),t}function Roe(r){var e=r.sourceFormat;if(!ZD(e)){var t="";gt(t)}return r.data}function Eoe(r){var e=r.sourceFormat,t=r.data;if(!ZD(e)){var n="";gt(n)}if(e===Yr){for(var a=[],i=0,o=t.length;i<o;i++)a.push(t[i].slice());return a}else if(e===ua){for(var a=[],i=0,o=t.length;i<o;i++)a.push(ie({},t[i]));return a}}function koe(r,e,t){if(t!=null){if(st(t)||!isNaN(t)&&!_e(e,t))return r[t];if(_e(e,t))return e[t]}}function Ioe(r){return De(r)}var V8=Te();function Ooe(r){r=De(r);var e=r.type,t="";e||gt(t);var n=e.split(":");n.length!==2&&gt(t);var a=!1;n[0]==="echarts"&&(e=n[1],a=!0),r.__isBuiltIn=a,V8.set(e,r)}function Poe(r,e,t){var n=Lt(r),a=n.length,i="";a||gt(i);for(var o=0,s=a;o<s;o++){var l=n[o];e=joe(l,e),o!==s-1&&(e.length=Math.max(e.length,1))}return e}function joe(r,e,t,n){var a="";e.length||gt(a),Ee(r)||gt(a);var i=r.type,o=V8.get(i);o||gt(a);var s=fe(e,function(u){return Loe(u,o)}),l=Lt(o.transform({upstream:s[0],upstreamList:s,config:De(r.config)}));return fe(l,function(u,c){var f="";Ee(u)||gt(f),u.data||gt(f);var d=R8(u.data);ZD(d)||gt(f);var v,g=e[0];if(g&&c===0&&!u.dimensions){var y=g.startIndex;y&&(u.data=g.data.slice(0,y).concat(u.data)),v={seriesLayoutBy:ri,sourceHeader:y,dimensions:g.metaRawOption.dimensions}}else v={seriesLayoutBy:ri,sourceHeader:0,dimensions:u.dimensions};return KC(u.data,v,null)})}function ZD(r){return r===Yr||r===ua}var vb="undefined",zoe=typeof Uint32Array===vb?Array:Uint32Array,Boe=typeof Uint16Array===vb?Array:Uint16Array,G8=typeof Int32Array===vb?Array:Int32Array,c5=typeof Float64Array===vb?Array:Float64Array,H8={float:c5,int:G8,ordinal:Array,number:Array,time:c5},Ww;function Tf(r){return r>65535?zoe:Boe}function Cf(){return[1/0,-1/0]}function Voe(r){var e=r.constructor;return e===Array?r.slice():new e(r)}function f5(r,e,t,n,a){var i=H8[t||"float"];if(a){var o=r[e],s=o&&o.length;if(s!==n){for(var l=new i(n),u=0;u<s;u++)l[u]=o[u];r[e]=l}}else r[e]=new i(n)}var QC=(function(){function r(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=Te()}return r.prototype.initData=function(e,t,n){this._provider=e,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var a=e.getSource(),i=this.defaultDimValueGetter=Ww[a.sourceFormat];this._dimValueGetter=n||i,this._rawExtent=[],E8(a),this._dimensions=fe(t,function(o){return{type:o.type,property:o.property}}),this._initDataFromProvider(0,e.count())},r.prototype.getProvider=function(){return this._provider},r.prototype.getSource=function(){return this._provider.getSource()},r.prototype.ensureCalculationDimension=function(e,t){var n=this._calcDimNameToIdx,a=this._dimensions,i=n.get(e);if(i!=null){if(a[i].type===t)return i}else i=a.length;return a[i]={type:t},n.set(e,i),this._chunks[i]=new H8[t||"float"](this._rawCount),this._rawExtent[i]=Cf(),i},r.prototype.collectOrdinalMeta=function(e,t){var n=this._chunks[e],a=this._dimensions[e],i=this._rawExtent,o=a.ordinalOffset||0,s=n.length;o===0&&(i[e]=Cf());for(var l=i[e],u=o;u<s;u++){var c=n[u]=t.parseAndCollect(n[u]);isNaN(c)||(l[0]=Math.min(c,l[0]),l[1]=Math.max(c,l[1]))}a.ordinalMeta=t,a.ordinalOffset=s,a.type="ordinal"},r.prototype.getOrdinalMeta=function(e){var t=this._dimensions[e],n=t.ordinalMeta;return n},r.prototype.getDimensionProperty=function(e){var t=this._dimensions[e];return t&&t.property},r.prototype.appendData=function(e){var t=this._provider,n=this.count();t.appendData(e);var a=t.count();return t.persistent||(a+=n),n<a&&this._initDataFromProvider(n,a,!0),[n,a]},r.prototype.appendValues=function(e,t){for(var n=this._chunks,a=this._dimensions,i=a.length,o=this._rawExtent,s=this.count(),l=s+Math.max(e.length,t||0),u=0;u<i;u++){var c=a[u];f5(n,u,c.type,l,!0)}for(var f=[],d=s;d<l;d++)for(var v=d-s,g=0;g<i;g++){var c=a[g],y=Ww.arrayRows.call(this,e[v]||f,c.property,v,g);n[g][d]=y;var x=o[g];y<x[0]&&(x[0]=y),y>x[1]&&(x[1]=y)}return this._rawCount=this._count=l,{start:s,end:l}},r.prototype._initDataFromProvider=function(e,t,n){for(var a=this._provider,i=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=fe(o,function(w){return w.property}),c=0;c<s;c++){var f=o[c];l[c]||(l[c]=Cf()),f5(i,c,f.type,t,n)}if(a.fillStorage)a.fillStorage(e,t,i,l);else for(var d=[],v=e;v<t;v++){d=a.getItem(v,d);for(var g=0;g<s;g++){var y=i[g],x=this._dimValueGetter(d,u[g],v,g);y[v]=x;var b=l[g];x<b[0]&&(b[0]=x),x>b[1]&&(b[1]=x)}}!a.persistent&&a.clean&&a.clean(),this._rawCount=this._count=t,this._extent=[]},r.prototype.count=function(){return this._count},r.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},r.prototype.getValues=function(e,t){var n=[],a=[];if(t==null){t=e,e=[];for(var i=0;i<this._dimensions.length;i++)a.push(i)}else a=e;for(var i=0,o=a.length;i<o;i++)n.push(this.get(a[i],t));return n},r.prototype.getByRawIndex=function(e,t){if(!(t>=0&&t<this._rawCount))return NaN;var n=this._chunks[e];return n?n[t]:NaN},r.prototype.getSum=function(e){var t=this._chunks[e],n=0;if(t)for(var a=0,i=this.count();a<i;a++){var o=this.get(e,a);isNaN(o)||(n+=o)}return n},r.prototype.getMedian=function(e){var t=[];this.each([e],function(i){isNaN(i)||t.push(i)});var n=t.sort(function(i,o){return i-o}),a=this.count();return a===0?0:a%2===1?n[(a-1)/2]:(n[a/2]+n[a/2-1])/2},r.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 a=0,i=this._count-1;a<=i;){var o=(a+i)/2|0;if(t[o]<e)a=o+1;else if(t[o]>e)i=o-1;else return o}return-1},r.prototype.getIndices=function(){var e,t=this._indices;if(t){var n=t.constructor,a=this._count;if(n===Array){e=new n(a);for(var i=0;i<a;i++)e[i]=t[i]}else e=new n(t.buffer,0,a)}else{var n=Tf(this._rawCount);e=new n(this.count());for(var i=0;i<e.length;i++)e[i]=i}return e},r.prototype.filter=function(e,t){if(!this._count)return this;for(var n=this.clone(),a=n.count(),i=Tf(n._rawCount),o=new i(a),s=[],l=e.length,u=0,c=e[0],f=n._chunks,d=0;d<a;d++){var v=void 0,g=n.getRawIndex(d);if(l===0)v=t(d);else if(l===1){var y=f[c][g];v=t(y,d)}else{for(var x=0;x<l;x++)s[x]=f[e[x]][g];s[x]=d,v=t.apply(null,s)}v&&(o[u++]=g)}return u<a&&(n._indices=o),n._count=u,n._extent=[],n._updateGetRawIdx(),n},r.prototype.selectRange=function(e){var t=this.clone(),n=t._count;if(!n)return this;var a=it(e),i=a.length;if(!i)return this;var o=t.count(),s=Tf(t._rawCount),l=new s(o),u=0,c=a[0],f=e[c][0],d=e[c][1],v=t._chunks,g=!1;if(!t._indices){var y=0;if(i===1){for(var x=v[a[0]],b=0;b<n;b++){var w=x[b];(w>=f&&w<=d||isNaN(w))&&(l[u++]=y),y++}g=!0}else if(i===2){for(var x=v[a[0]],T=v[a[1]],C=e[a[1]][0],D=e[a[1]][1],b=0;b<n;b++){var w=x[b],M=T[b];(w>=f&&w<=d||isNaN(w))&&(M>=C&&M<=D||isNaN(M))&&(l[u++]=y),y++}g=!0}}if(!g)if(i===1)for(var b=0;b<o;b++){var N=t.getRawIndex(b),w=v[a[0]][N];(w>=f&&w<=d||isNaN(w))&&(l[u++]=N)}else for(var b=0;b<o;b++){for(var R=!0,N=t.getRawIndex(b),E=0;E<i;E++){var k=a[E],w=v[k][N];(w<e[k][0]||w>e[k][1])&&(R=!1)}R&&(l[u++]=t.getRawIndex(b))}return u<o&&(t._indices=l),t._count=u,t._extent=[],t._updateGetRawIdx(),t},r.prototype.map=function(e,t){var n=this.clone(e);return this._updateDims(n,e,t),n},r.prototype.modify=function(e,t){this._updateDims(this,e,t)},r.prototype._updateDims=function(e,t,n){for(var a=e._chunks,i=[],o=t.length,s=e.count(),l=[],u=e._rawExtent,c=0;c<t.length;c++)u[t[c]]=Cf();for(var f=0;f<s;f++){for(var d=e.getRawIndex(f),v=0;v<o;v++)l[v]=a[t[v]][d];l[o]=f;var g=n&&n.apply(null,l);if(g!=null){typeof g!="object"&&(i[0]=g,g=i);for(var c=0;c<g.length;c++){var y=t[c],x=g[c],b=u[y],w=a[y];w&&(w[d]=x),x<b[0]&&(b[0]=x),x>b[1]&&(b[1]=x)}}}},r.prototype.lttbDownSample=function(e,t){var n=this.clone([e],!0),a=n._chunks,i=a[e],o=this.count(),s=0,l=Math.floor(1/t),u=this.getRawIndex(0),c,f,d,v=new(Tf(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));v[s++]=u;for(var g=1;g<o-1;g+=l){for(var y=Math.min(g+l,o-1),x=Math.min(g+l*2,o),b=(x+y)/2,w=0,T=y;T<x;T++){var C=this.getRawIndex(T),D=i[C];isNaN(D)||(w+=D)}w/=x-y;var M=g,N=Math.min(g+l,o),R=g-1,E=i[u];c=-1,d=M;for(var k=-1,I=0,T=M;T<N;T++){var C=this.getRawIndex(T),D=i[C];if(isNaN(D)){I++,k<0&&(k=C);continue}f=Math.abs((R-b)*(D-E)-(R-T)*(w-E)),f>c&&(c=f,d=C)}I>0&&I<N-M&&(v[s++]=Math.min(k,d),d=Math.max(k,d)),v[s++]=d,u=d}return v[s++]=this.getRawIndex(o-1),n._count=s,n._indices=v,n.getRawIndex=this._getRawIdx,n},r.prototype.minmaxDownSample=function(e,t){for(var n=this.clone([e],!0),a=n._chunks,i=Math.floor(1/t),o=a[e],s=this.count(),l=new(Tf(this._rawCount))(Math.ceil(s/i)*2),u=0,c=0;c<s;c+=i){var f=c,d=o[this.getRawIndex(f)],v=c,g=o[this.getRawIndex(v)],y=i;c+i>s&&(y=s-c);for(var x=0;x<y;x++){var b=this.getRawIndex(c+x),w=o[b];w<d&&(d=w,f=c+x),w>g&&(g=w,v=c+x)}var T=this.getRawIndex(f),C=this.getRawIndex(v);f<v?(l[u++]=T,l[u++]=C):(l[u++]=C,l[u++]=T)}return n._count=u,n._indices=l,n._updateGetRawIdx(),n},r.prototype.downSample=function(e,t,n,a){for(var i=this.clone([e],!0),o=i._chunks,s=[],l=Math.floor(1/t),u=o[e],c=this.count(),f=i._rawExtent[e]=Cf(),d=new(Tf(this._rawCount))(Math.ceil(c/l)),v=0,g=0;g<c;g+=l){l>c-g&&(l=c-g,s.length=l);for(var y=0;y<l;y++){var x=this.getRawIndex(g+y);s[y]=u[x]}var b=n(s),w=this.getRawIndex(Math.min(g+a(s,b)||0,c-1));u[w]=b,b<f[0]&&(f[0]=b),b>f[1]&&(f[1]=b),d[v++]=w}return i._count=v,i._indices=d,i._updateGetRawIdx(),i},r.prototype.each=function(e,t){if(this._count)for(var n=e.length,a=this._chunks,i=0,o=this.count();i<o;i++){var s=this.getRawIndex(i);switch(n){case 0:t(i);break;case 1:t(a[e[0]][s],i);break;case 2:t(a[e[0]][s],a[e[1]][s],i);break;default:for(var l=0,u=[];l<n;l++)u[l]=a[e[l]][s];u[l]=i,t.apply(null,u)}}},r.prototype.getDataExtent=function(e){var t=this._chunks[e],n=Cf();if(!t)return n;var a=this.count(),i=!this._indices,o;if(i)return this._rawExtent[e].slice();if(o=this._extent[e],o)return o.slice();o=n;for(var s=o[0],l=o[1],u=0;u<a;u++){var c=this.getRawIndex(u),f=t[c];f<s&&(s=f),f>l&&(l=f)}return o=[s,l],this._extent[e]=o,o},r.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var n=[],a=this._chunks,i=0;i<a.length;i++)n.push(a[i][t]);return n},r.prototype.clone=function(e,t){var n=new r,a=this._chunks,i=e&&Ia(e,function(s,l){return s[l]=!0,s},{});if(i)for(var o=0;o<a.length;o++)n._chunks[o]=i[o]?Voe(a[o]):a[o];else n._chunks=a;return this._copyCommonProps(n),t||(n._indices=this._cloneIndices()),n._updateGetRawIdx(),n},r.prototype._copyCommonProps=function(e){e._count=this._count,e._rawCount=this._rawCount,e._provider=this._provider,e._dimensions=this._dimensions,e._extent=De(this._extent),e._rawExtent=De(this._rawExtent)},r.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 a=0;a<n;a++)t[a]=this._indices[a]}else t=new e(this._indices);return t}return null},r.prototype._getRawIdxIdentity=function(e){return e},r.prototype._getRawIdx=function(e){return e<this._count&&e>=0?this._indices[e]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=(function(){function e(t,n,a,i){return pl(t[i],this._dimensions[i])}Ww={arrayRows:e,objectRows:function(t,n,a,i){return pl(t[n],this._dimensions[i])},keyedColumns:e,original:function(t,n,a,i){var o=t&&(t.value==null?t:t.value);return pl(o instanceof Array?o[i]:o,this._dimensions[i])},typedArray:function(t,n,a,i){return t[i]}}})(),r})(),F8=(function(){function r(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,t=this._getUpstreamSourceManagers(),n=!!t.length,a,i;if(Zy(e)){var o=e,s=void 0,l=void 0,u=void 0;if(n){var c=t[0];c.prepareSource(),u=c.getSource(),s=u.data,l=u.sourceFormat,i=[c._getVersionSign()]}else s=o.get("data",!0),l=Tn(s)?vl:la,i=[];var f=this._getSourceMetaRawOption()||{},d=u&&u.metaRawOption||{},v=Ce(f.seriesLayoutBy,d.seriesLayoutBy)||null,g=Ce(f.sourceHeader,d.sourceHeader),y=Ce(f.dimensions,d.dimensions),x=v!==d.seriesLayoutBy||!!g!=!!d.sourceHeader||y;a=x?[KC(s,{seriesLayoutBy:v,sourceHeader:g,dimensions:y},l)]:[]}else{var b=e;if(n){var w=this._applyTransform(t);a=w.sourceList,i=w.upstreamSignList}else{var T=b.get("source",!0);a=[KC(T,this._getSourceMetaRawOption(),null)],i=[]}}this._setLocalSource(a,i)},r.prototype._applyTransform=function(e){var t=this._sourceHost,n=t.get("transform",!0),a=t.get("fromTransformResult",!0);if(a!=null){var i="";e.length!==1&&d5(i)}var o,s=[],l=[];return O(e,function(u){u.prepareSource();var c=u.getSource(a||0),f="";a!=null&&!c&&d5(f),s.push(c),l.push(u._getVersionSign())}),n?o=Poe(n,s,{datasetIndex:t.componentIndex}):a!=null&&(o=[moe(s[0])]),{sourceList:o,upstreamSignList:l}},r.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}},r.prototype.getSource=function(e){e=e||0;var t=this._sourceList[e];if(!t){var n=this._getUpstreamSourceManagers();return n[0]&&n[0].getSource(e)}return t},r.prototype.getSharedDataStore=function(e){var t=e.makeStoreSchema();return this._innerGetDataStore(t.dimensions,e.source,t.hash)},r.prototype._innerGetDataStore=function(e,t,n){var a=0,i=this._storeList,o=i[a];o||(o=i[a]={});var s=o[n];if(!s){var l=this._getUpstreamSourceManagers()[0];Zy(this._sourceHost)&&l?s=l._innerGetDataStore(e,t,n):(s=new QC,s.initData(new k8(t,e.length),e)),o[n]=s}return s},r.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if(Zy(e)){var t=FD(e);return t?[t.getSourceManager()]:[]}else return fe(Wie(e),function(n){return n.getSourceManager()})},r.prototype._getSourceMetaRawOption=function(){var e=this._sourceHost,t,n,a;if(Zy(e))t=e.get("seriesLayoutBy",!0),n=e.get("sourceHeader",!0),a=e.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var i=e;t=i.get("seriesLayoutBy",!0),n=i.get("sourceHeader",!0),a=i.get("dimensions",!0)}return{seriesLayoutBy:t,sourceHeader:n,dimensions:a}},r})();function h5(r){var e=r.option.transform;e&&Xp(r.option.transform)}function Zy(r){return r.mainType==="series"}function d5(r){throw new Error(r)}var Goe="line-height:1";function U8(r){var e=r.lineHeight;return e==null?Goe:"line-height:"+dn(e+"")+"px"}function Y8(r,e){var t=r.color||ee.color.tertiary,n=r.fontSize||12,a=r.fontWeight||"400",i=r.color||ee.color.secondary,o=r.fontSize||14,s=r.fontWeight||"900";return e==="html"?{nameStyle:"font-size:"+dn(n+"")+"px;color:"+dn(t)+";font-weight:"+dn(a+""),valueStyle:"font-size:"+dn(o+"")+"px;color:"+dn(i)+";font-weight:"+dn(s+"")}:{nameStyle:{fontSize:n,fill:t,fontWeight:a},valueStyle:{fontSize:o,fill:i,fontWeight:s}}}var Hoe=[0,10,20,30],Foe=["",`
273
- `,`
274
-
275
- `,`
276
-
277
-
278
- `];function pr(r,e){return e.type=r,e}function JC(r){return r.type==="section"}function W8(r){return JC(r)?Uoe:Yoe}function X8(r){if(JC(r)){var e=0,t=r.blocks.length,n=t>1||t>0&&!r.noHeader;return O(r.blocks,function(a){var i=X8(a);i>=e&&(e=i+ +(n&&(!i||JC(a)&&!a.noHeader)))}),e}return 0}function Uoe(r,e,t,n){var a=e.noHeader,i=Woe(X8(e)),o=[],s=e.blocks||[];rn(!s||ce(s)),s=s||[];var l=r.orderMode;if(e.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(_e(u,l)){var c=new B8(u[l],null);s.sort(function(y,x){return c.evaluate(y.sortParam,x.sortParam)})}else l==="seriesDesc"&&s.reverse()}O(s,function(y,x){var b=e.valueFormatter,w=W8(y)(b?ie(ie({},r),{valueFormatter:b}):r,y,x>0?i.html:0,n);w!=null&&o.push(w)});var f=r.renderMode==="richText"?o.join(i.richText):eA(n,o.join(""),a?t:i.html);if(a)return f;var d=XC(e.header,"ordinal",r.useUTC),v=Y8(n,r.renderMode).nameStyle,g=U8(n);return r.renderMode==="richText"?q8(r,d,v)+i.richText+f:eA(n,'<div style="'+v+";"+g+';">'+dn(d)+"</div>"+f,t)}function Yoe(r,e,t,n){var a=r.renderMode,i=e.noName,o=e.noValue,s=!e.markerType,l=e.name,u=r.useUTC,c=e.valueFormatter||r.valueFormatter||function(C){return C=ce(C)?C:[C],fe(C,function(D,M){return XC(D,ce(v)?v[M]:v,u)})};if(!(i&&o)){var f=s?"":r.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||ee.color.secondary,a),d=i?"":XC(l,"ordinal",u),v=e.valueType,g=o?[]:c(e.value,e.dataIndex),y=!s||!i,x=!s&&i,b=Y8(n,a),w=b.nameStyle,T=b.valueStyle;return a==="richText"?(s?"":f)+(i?"":q8(r,d,w))+(o?"":Zoe(r,g,y,x,T)):eA(n,(s?"":f)+(i?"":Xoe(d,!s,w))+(o?"":qoe(g,y,x,T)),t)}}function v5(r,e,t,n,a,i){if(r){var o=W8(r),s={useUTC:a,renderMode:t,orderMode:n,markupStyleCreator:e,valueFormatter:r.valueFormatter};return o(s,r,0,i)}}function Woe(r){return{html:Hoe[r],richText:Foe[r]}}function eA(r,e,t){var n='<div style="clear:both"></div>',a="margin: "+t+"px 0 0",i=U8(r);return'<div style="'+a+";"+i+';">'+e+n+"</div>"}function Xoe(r,e,t){var n=e?"margin-left:2px":"";return'<span style="'+t+";"+n+'">'+dn(r)+"</span>"}function qoe(r,e,t,n){var a=t?"10px":"20px",i=e?"float:right;margin-left:"+a:"";return r=ce(r)?r:[r],'<span style="'+i+";"+n+'">'+fe(r,function(o){return dn(o)}).join("&nbsp;&nbsp;")+"</span>"}function q8(r,e,t){return r.markupStyleCreator.wrapRichTextStyle(e,t)}function Zoe(r,e,t,n,a){var i=[a],o=n?10:20;return t&&i.push({padding:[0,0,0,o],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(ce(e)?e.join(" "):e,i)}function Z8(r,e){var t=r.getData().getItemVisual(e,"style"),n=t[r.visualDrawType];return vc(n)}function $8(r,e){var t=r.get("padding");return t??(e==="richText"?[8,10]:10)}var Xw=(function(){function r(){this.richTextStyles={},this._nextStyleNameId=nH()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(e,t,n){var a=n==="richText"?this._generateStyleName():null,i=c8({color:t,type:e,renderMode:n,markerId:a});return ye(i)?i:(this.richTextStyles[a]=i.style,i.content)},r.prototype.wrapRichTextStyle=function(e,t){var n={};ce(t)?O(t,function(i){return ie(n,i)}):ie(n,t);var a=this._generateStyleName();return this.richTextStyles[a]=n,"{"+a+"|"+e+"}"},r})();function K8(r){var e=r.series,t=r.dataIndex,n=r.multipleSeries,a=e.getData(),i=a.mapDimensionsAll("defaultedTooltip"),o=i.length,s=e.getRawValue(t),l=ce(s),u=Z8(e,t),c,f,d,v;if(o>1||l&&!o){var g=$oe(s,e,t,i,u);c=g.inlineValues,f=g.inlineValueTypes,d=g.blocks,v=g.inlineValues[0]}else if(o){var y=a.getDimensionInfo(i[0]);v=c=jh(a,t,i[0]),f=y.type}else v=c=l?s[0]:s;var x=sD(e),b=x&&e.name||"",w=a.getName(t),T=n?b:w;return pr("section",{header:b,noHeader:n||!x,sortParam:v,blocks:[pr("nameValue",{markerType:"item",markerColor:u,name:T,noName:!ra(T),value:c,valueType:f,dataIndex:t})].concat(d||[])})}function $oe(r,e,t,n,a){var i=e.getData(),o=Ia(r,function(f,d,v){var g=i.getDimensionInfo(v);return f=f||g&&g.tooltip!==!1&&g.displayName!=null},!1),s=[],l=[],u=[];n.length?O(n,function(f){c(jh(i,t,f),f)}):O(r,c);function c(f,d){var v=i.getDimensionInfo(d);!v||v.otherDims.tooltip===!1||(o?u.push(pr("nameValue",{markerType:"subItem",markerColor:a,name:v.displayName,value:f,valueType:v.type})):(s.push(f),l.push(v.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var Os=Je();function $y(r,e){return r.getName(e)||r.getId(e)}var ix="__universalTransitionEnabled",Ct=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return e.prototype.init=function(t,n,a){this.seriesIndex=this.componentIndex,this.dataTask=Ip({count:Qoe,reset:Joe}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,a);var i=Os(this).sourceManager=new F8(this);i.prepareSource();var o=this.getInitialData(t,a);g5(o,this),this.dataTask.context.data=o,Os(this).dataBeforeProcessed=o,p5(this),this._initSelectedMapFromData(o)},e.prototype.mergeDefaultAndTheme=function(t,n){var a=ig(this),i=a?Sc(t):{},o=this.subType;Qe.hasClass(o)&&(o+="Series"),Ye(t,n.getTheme().get(this.subType)),Ye(t,this.getDefaultOption()),lc(t,"label",["show"]),this.fillDataTextStyle(t.data),a&&Zi(t,i,a)},e.prototype.mergeOption=function(t,n){t=Ye(this.option,t,!0),this.fillDataTextStyle(t.data);var a=ig(this);a&&Zi(this.option,t,a);var i=Os(this).sourceManager;i.dirty(),i.prepareSource();var o=this.getInitialData(t,n);g5(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,Os(this).dataBeforeProcessed=o,p5(this),this._initSelectedMapFromData(o)},e.prototype.fillDataTextStyle=function(t){if(t&&!Tn(t))for(var n=["show"],a=0;a<t.length;a++)t[a]&&t[a].label&&lc(t[a],"label",n)},e.prototype.getInitialData=function(t,n){},e.prototype.appendData=function(t){var n=this.getRawData();n.appendData(t.data)},e.prototype.getData=function(t){var n=tA(this);if(n){var a=n.context.data;return t==null||!a.getLinkedData?a:a.getLinkedData(t)}else return Os(this).data},e.prototype.getAllData=function(){var t=this.getData();return t&&t.getLinkedDataAll?t.getLinkedDataAll():[{data:t}]},e.prototype.setData=function(t){var n=tA(this);if(n){var a=n.context;a.outputData=t,n!==this.dataTask&&(a.data=t)}Os(this).data=t},e.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return Te(t)},e.prototype.getSourceManager=function(){return Os(this).sourceManager},e.prototype.getSource=function(){return this.getSourceManager().getSource()},e.prototype.getRawData=function(){return Os(this).dataBeforeProcessed},e.prototype.getColorBy=function(){var t=this.get("colorBy");return t||"series"},e.prototype.isColorBySeries=function(){return this.getColorBy()==="series"},e.prototype.getBaseAxis=function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},e.prototype.indicesOfNearest=function(t,n,a,i){var o=this.getData(),s=this.coordinateSystem,l=s&&s.getAxis(t);if(!s||!l)return[];var u=l.dataToCoord(a);i==null&&(i=1/0);var c=[],f=1/0,d=-1,v=0;return o.each(n,function(g,y){var x=l.dataToCoord(g),b=u-x,w=Math.abs(b);w<=i&&((w<f||w===f&&b>=0&&d<0)&&(f=w,d=b,v=0),b===d&&(c[v++]=y))}),c.length=v,c},e.prototype.formatTooltip=function(t,n,a){return K8({series:this,dataIndex:t,multipleSeries:n})},e.prototype.isAnimationEnabled=function(){var t=this.ecModel;if(nt.node&&!(t&&t.ssr))return!1;var n=this.getShallow("animation");return n&&this.getData().count()>this.getShallow("animationThreshold")&&(n=!1),!!n},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,n,a){var i=this.ecModel,o=UD.prototype.getColorFromPalette.call(this,t,n,a);return o||(o=i.getColorFromPalette(t,n,a)),o},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,n){this._innerSelect(this.getData(n),t)},e.prototype.unselect=function(t,n){var a=this.option.selectedMap;if(a){var i=this.option.selectedMode,o=this.getData(n);if(i==="series"||a==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s<t.length;s++){var l=t[s],u=$y(o,l);a[u]=!1,this._selectedDataIndicesMap[u]=-1}}},e.prototype.toggleSelect=function(t,n){for(var a=[],i=0;i<t.length;i++)a[0]=t[i],this.isSelected(t[i],n)?this.unselect(a,n):this.select(a,n)},e.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap==="all")return[].slice.call(this.getData().getIndices());for(var t=this._selectedDataIndicesMap,n=it(t),a=[],i=0;i<n.length;i++){var o=t[n[i]];o>=0&&a.push(o)}return a},e.prototype.isSelected=function(t,n){var a=this.option.selectedMap;if(!a)return!1;var i=this.getData(n);return(a==="all"||a[$y(i,t)])&&!i.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[ix])return!0;var t=this.option.universalTransition;return t?t===!0?!0:t&&t.enabled:!1},e.prototype._innerSelect=function(t,n){var a,i,o=this.option,s=o.selectedMode,l=n.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){Ee(o.selectedMap)||(o.selectedMap={});for(var u=o.selectedMap,c=0;c<l;c++){var f=n[c],d=$y(t,f);u[d]=!0,this._selectedDataIndicesMap[d]=t.getRawIndex(f)}}else if(s==="single"||s===!0){var v=n[l-1],d=$y(t,v);o.selectedMap=(a={},a[d]=!0,a),this._selectedDataIndicesMap=(i={},i[d]=t.getRawIndex(v),i)}}},e.prototype._initSelectedMapFromData=function(t){if(!this.option.selectedMap){var n=[];t.hasItemOption&&t.each(function(a){var i=t.getRawDataItem(a);i&&i.selected&&n.push(a)}),n.length>0&&this._innerSelect(t,n)}},e.registerClass=function(t){return Qe.registerClass(t)},e.protoInitialize=(function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"})(),e})(Qe);Jt(Ct,db);Jt(Ct,UD);dH(Ct,Qe);function p5(r){var e=r.name;sD(r)||(r.name=Koe(r)||e)}function Koe(r){var e=r.getRawData(),t=e.mapDimensionsAll("seriesName"),n=[];return O(t,function(a){var i=e.getDimensionInfo(a);i.displayName&&n.push(i.displayName)}),n.join(" ")}function Qoe(r){return r.model.getRawData().count()}function Joe(r){var e=r.model;return e.setData(e.getRawData().cloneShallow()),ese}function ese(r,e){e.outputData&&r.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function g5(r,e){O(Lh(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(t){r.wrapMethod(t,He(tse,e))})}function tse(r,e){var t=tA(r);return t&&t.setOutputEnd((e||this).count()),e}function tA(r){var e=(r.ecModel||{}).scheduler,t=e&&e.getPipeline(r.uid);if(t){var n=t.currentTask;if(n){var a=n.agentStubMap;a&&(n=a.get(r.uid))}return n}}var Rt=(function(){function r(){this.group=new Ne,this.uid=od("viewComponent")}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,n,a){},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,n,a){},r.prototype.updateLayout=function(e,t,n,a){},r.prototype.updateVisual=function(e,t,n,a){},r.prototype.toggleBlurSeries=function(e,t,n){},r.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},r})();uD(Rt);eb(Rt);function ud(){var r=Je();return function(e){var t=r(e),n=e.pipelineContext,a=!!t.large,i=!!t.progressiveRender,o=t.large=!!(n&&n.large),s=t.progressiveRender=!!(n&&n.progressiveRender);return(a!==o||i!==s)&&"reset"}}var Q8=Je(),rse=ud(),St=(function(){function r(){this.group=new Ne,this.uid=od("viewChart"),this.renderTask=Ip({plan:nse,reset:ase}),this.renderTask.context={view:this}}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,n,a){},r.prototype.highlight=function(e,t,n,a){var i=e.getData(a&&a.dataType);i&&y5(i,a,"emphasis")},r.prototype.downplay=function(e,t,n,a){var i=e.getData(a&&a.dataType);i&&y5(i,a,"normal")},r.prototype.remove=function(e,t){this.group.removeAll()},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,n,a){this.render(e,t,n,a)},r.prototype.updateLayout=function(e,t,n,a){this.render(e,t,n,a)},r.prototype.updateVisual=function(e,t,n,a){this.render(e,t,n,a)},r.prototype.eachRendered=function(e){Ll(this.group,e)},r.markUpdateMethod=function(e,t){Q8(e).updateMethod=t},r.protoInitialize=(function(){var e=r.prototype;e.type="chart"})(),r})();function m5(r,e,t){r&&rg(r)&&(e==="emphasis"?$o:Ko)(r,t)}function y5(r,e,t){var n=uc(r,e),a=e&&e.highlightKey!=null?Lae(e.highlightKey):null;n!=null?O(Lt(n),function(i){m5(r.getItemGraphicEl(i),t,a)}):r.eachItemGraphicEl(function(i){m5(i,t,a)})}uD(St);eb(St);function nse(r){return rse(r.model)}function ase(r){var e=r.model,t=r.ecModel,n=r.api,a=r.payload,i=e.pipelineContext.progressiveRender,o=r.view,s=a&&Q8(a).updateMethod,l=i?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](e,t,n,a),ise[l]}var ise={incrementalPrepareRender:{progress:function(r,e){e.view.incrementalRender(r,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(r,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},Yx="\0__throttleOriginMethod",x5="\0__throttleRate",b5="\0__throttleType";function pb(r,e,t){var n,a=0,i=0,o=null,s,l,u,c;e=e||0;function f(){i=new Date().getTime(),o=null,r.apply(l,u||[])}var d=function(){for(var v=[],g=0;g<arguments.length;g++)v[g]=arguments[g];n=new Date().getTime(),l=this,u=v;var y=c||e,x=c||t;c=null,s=n-(x?a:i)-y,clearTimeout(o),x?o=setTimeout(f,y):s>=0?f():o=setTimeout(f,-s),a=n};return d.clear=function(){o&&(clearTimeout(o),o=null)},d.debounceNextCall=function(v){c=v},d}function cd(r,e,t,n){var a=r[e];if(a){var i=a[Yx]||a,o=a[b5],s=a[x5];if(s!==t||o!==n){if(t==null||!n)return r[e]=i;a=r[e]=pb(i,t,n==="debounce"),a[Yx]=i,a[b5]=n,a[x5]=t}return a}}function sg(r,e){var t=r[e];t&&t[Yx]&&(t.clear&&t.clear(),r[e]=t[Yx])}var _5=Je(),S5={itemStyle:cc(t8,!0),lineStyle:cc(e8,!0)},ose={lineStyle:"stroke",itemStyle:"fill"};function J8(r,e){var t=r.visualStyleMapper||S5[e];return t||(console.warn("Unknown style type '"+e+"'."),S5.itemStyle)}function eF(r,e){var t=r.visualDrawType||ose[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var sse={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData(),n=r.visualStyleAccessPath||"itemStyle",a=r.getModel(n),i=J8(r,n),o=i(a),s=a.getShallow("decal");s&&(t.setVisual("decal",s),s.dirty=!0);var l=eF(r,n),u=o[l],c=Me(u)?u:null,f=o.fill==="auto"||o.stroke==="auto";if(!o[l]||c||f){var d=r.getColorFromPalette(r.name,null,e.getSeriesCount());o[l]||(o[l]=d,t.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||Me(o.fill)?d:o.fill,o.stroke=o.stroke==="auto"||Me(o.stroke)?d:o.stroke}if(t.setVisual("style",o),t.setVisual("drawType",l),!e.isSeriesFiltered(r)&&c)return t.setVisual("colorFromPalette",!1),{dataEach:function(v,g){var y=r.getDataParams(g),x=ie({},o);x[l]=c(y),v.setItemVisual(g,"style",x)}}}},Lv=new et,lse={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!(r.ignoreStyleOnData||e.isSeriesFiltered(r))){var t=r.getData(),n=r.visualStyleAccessPath||"itemStyle",a=J8(r,n),i=t.getVisual("drawType");return{dataEach:t.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[n]){Lv.option=l[n];var u=a(Lv),c=o.ensureUniqueItemVisual(s,"style");ie(c,u),Lv.option.decal&&(o.setItemVisual(s,"decal",Lv.option.decal),Lv.option.decal.dirty=!0),i in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},use={performRawSeries:!0,overallReset:function(r){var e=Te();r.eachSeries(function(t){var n=t.getColorBy();if(!t.isColorBySeries()){var a=t.type+"-"+n,i=e.get(a);i||(i={},e.set(a,i)),_5(t).scope=i}}),r.eachSeries(function(t){if(!(t.isColorBySeries()||r.isSeriesFiltered(t))){var n=t.getRawData(),a={},i=t.getData(),o=_5(t).scope,s=t.visualStyleAccessPath||"itemStyle",l=eF(t,s);i.each(function(u){var c=i.getRawIndex(u);a[c]=u}),n.each(function(u){var c=a[u],f=i.getItemVisual(c,"colorFromPalette");if(f){var d=i.ensureUniqueItemVisual(c,"style"),v=n.getName(u)||u+"",g=n.count();d[l]=t.getColorFromPalette(v,o,g)}})}})}},Ky=Math.PI;function cse(r,e){e=e||{},Re(e,{text:"loading",textColor:ee.color.primary,fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255,255,255,0.8)",showSpinner:!0,color:ee.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var t=new Ne,n=new qe({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});t.add(n);var a=new ot({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),i=new qe({style:{fill:"none"},textContent:a,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});t.add(i);var o;return e.showSpinner&&(o=new Wg({shape:{startAngle:-Ky/2,endAngle:-Ky/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:Ky*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:Ky*3/2}).delay(300).start("circularInOut"),t.add(o)),t.resize=function(){var s=a.getBoundingRect().width,l=e.showSpinner?e.spinnerRadius:0,u=(r.getWidth()-l*2-(e.showSpinner&&s?10:0)-s)/2-(e.showSpinner&&s?0:5+s/2)+(e.showSpinner?0:s/2)+(s?0:l),c=r.getHeight()/2;e.showSpinner&&o.setShape({cx:u,cy:c}),i.setShape({x:u-l,y:c-l,width:l*2,height:l*2}),n.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},t.resize(),t}var tF=(function(){function r(e,t,n,a){this._stageTaskMap=Te(),this.ecInstance=e,this.api=t,n=this._dataProcessorHandlers=n.slice(),a=this._visualHandlers=a.slice(),this._allHandlers=n.concat(a)}return r.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(n){var a=n.overallTask;a&&a.dirty()})},r.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var n=this._pipelineMap.get(e.__pipeline.id),a=n.context,i=!t&&n.progressiveEnabled&&(!a||a.progressiveRender)&&e.__idxInPipeline>n.blockIndex,o=i?n.step:null,s=a&&a.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},r.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},r.prototype.updateStreamModes=function(e,t){var n=this._pipelineMap.get(e.uid),a=e.getData(),i=a.count(),o=n.progressiveEnabled&&t.incrementalPrepareRender&&i>=n.threshold,s=e.get("large")&&i>=e.get("largeThreshold"),l=e.get("progressiveChunkMode")==="mod"?i:null;e.pipelineContext=n.context={progressiveRender:o,modDataCount:l,large:s}},r.prototype.restorePipelines=function(e){var t=this,n=t._pipelineMap=Te();e.eachSeries(function(a){var i=a.getProgressive(),o=a.uid;n.set(o,{id:o,head:null,tail:null,threshold:a.getProgressiveThreshold(),progressiveEnabled:i&&!(a.preventIncremental&&a.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),t._pipe(a,a.dataTask)})},r.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),n=this.api;O(this._allHandlers,function(a){var i=e.get(a.uid)||e.set(a.uid,{}),o="";rn(!(a.reset&&a.overallReset),o),a.reset&&this._createSeriesStageTask(a,i,t,n),a.overallReset&&this._createOverallStageTask(a,i,t,n)},this)},r.prototype.prepareView=function(e,t,n,a){var i=e.renderTask,o=i.context;o.model=t,o.ecModel=n,o.api=a,i.__block=!e.incrementalPrepareRender,this._pipe(t,i)},r.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},r.prototype.performVisualTasks=function(e,t,n){this._performStageTasks(this._visualHandlers,e,t,n)},r.prototype._performStageTasks=function(e,t,n,a){a=a||{};var i=!1,o=this;O(e,function(l,u){if(!(a.visualType&&a.visualType!==l.visualType)){var c=o._stageTaskMap.get(l.uid),f=c.seriesTaskMap,d=c.overallTask;if(d){var v,g=d.agentStubMap;g.each(function(x){s(a,x)&&(x.dirty(),v=!0)}),v&&d.dirty(),o.updatePayload(d,n);var y=o.getPerformArgs(d,a.block);g.each(function(x){x.perform(y)}),d.perform(y)&&(i=!0)}else f&&f.each(function(x,b){s(a,x)&&x.dirty();var w=o.getPerformArgs(x,a.block);w.skip=!l.performRawSeries&&t.isSeriesFiltered(x.context.model),o.updatePayload(x,n),x.perform(w)&&(i=!0)})}});function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=i||this.unfinished},r.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(n){t=n.dataTask.perform()||t}),this.unfinished=t||this.unfinished},r.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)})},r.prototype.updatePayload=function(e,t){t!=="remain"&&(e.context.payload=t)},r.prototype._createSeriesStageTask=function(e,t,n,a){var i=this,o=t.seriesTaskMap,s=t.seriesTaskMap=Te(),l=e.seriesType,u=e.getTargetSeries;e.createOnAllSeries?n.eachRawSeries(c):l?n.eachRawSeriesByType(l,c):u&&u(n,a).each(c);function c(f){var d=f.uid,v=s.set(d,o&&o.get(d)||Ip({plan:pse,reset:gse,count:yse}));v.context={model:f,ecModel:n,api:a,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:i},i._pipe(f,v)}},r.prototype._createOverallStageTask=function(e,t,n,a){var i=this,o=t.overallTask=t.overallTask||Ip({reset:fse});o.context={ecModel:n,api:a,overallReset:e.overallReset,scheduler:i};var s=o.agentStubMap,l=o.agentStubMap=Te(),u=e.seriesType,c=e.getTargetSeries,f=!0,d=!1,v="";rn(!e.createOnAllSeries,v),u?n.eachRawSeriesByType(u,g):c?c(n,a).each(g):(f=!1,O(n.getSeries(),g));function g(y){var x=y.uid,b=l.set(x,s&&s.get(x)||(d=!0,Ip({reset:hse,onDirty:vse})));b.context={model:y,overallProgress:f},b.agent=o,b.__block=f,i._pipe(y,b)}d&&o.dirty()},r.prototype._pipe=function(e,t){var n=e.uid,a=this._pipelineMap.get(n);!a.head&&(a.head=t),a.tail&&a.tail.pipe(t),a.tail=t,t.__idxInPipeline=a.count++,t.__pipeline=a},r.wrapStageHandler=function(e,t){return Me(e)&&(e={overallReset:e,seriesType:xse(e)}),e.uid=od("stageHandler"),t&&(e.visualType=t),e},r})();function fse(r){r.overallReset(r.ecModel,r.api,r.payload)}function hse(r){return r.overallProgress&&dse}function dse(){this.agent.dirty(),this.getDownstream().dirty()}function vse(){this.agent&&this.agent.dirty()}function pse(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function gse(r){r.useClearVisual&&r.data.clearAllVisual();var e=r.resetDefines=Lt(r.reset(r.model,r.ecModel,r.api,r.payload));return e.length>1?fe(e,function(t,n){return rF(n)}):mse}var mse=rF(0);function rF(r){return function(e,t){var n=t.data,a=t.resetDefines[r];if(a&&a.dataEach)for(var i=e.start;i<e.end;i++)a.dataEach(n,i);else a&&a.progress&&a.progress(e,n)}}function yse(r){return r.data.count()}function xse(r){Wx=null;try{r(lg,nF)}catch{}return Wx}var lg={},nF={},Wx;aF(lg,YD);aF(nF,D8);lg.eachSeriesByType=lg.eachRawSeriesByType=function(r){Wx=r};lg.eachComponent=function(r){r.mainType==="series"&&r.subType&&(Wx=r.subType)};function aF(r,e){for(var t in e.prototype)r[t]=Kt}var ke=ee.darkColor,bse=ke.background,Rv=function(){return{axisLine:{lineStyle:{color:ke.axisLine}},splitLine:{lineStyle:{color:ke.axisSplitLine}},splitArea:{areaStyle:{color:[ke.backgroundTint,ke.backgroundTransparent]}},minorSplitLine:{lineStyle:{color:ke.axisMinorSplitLine}},axisLabel:{color:ke.axisLabel},axisName:{}}},w5={label:{color:ke.secondary},itemStyle:{borderColor:ke.borderTint},dividerLineStyle:{color:ke.border}},iF={darkMode:!0,color:ke.theme,backgroundColor:bse,axisPointer:{lineStyle:{color:ke.border},crossStyle:{color:ke.borderShade},label:{color:ke.tertiary}},legend:{textStyle:{color:ke.secondary},pageTextStyle:{color:ke.tertiary}},textStyle:{color:ke.secondary},title:{textStyle:{color:ke.primary},subtextStyle:{color:ke.quaternary}},toolbox:{iconStyle:{borderColor:ke.accent50}},tooltip:{backgroundColor:ke.neutral20,defaultBorderColor:ke.border,textStyle:{color:ke.tertiary}},dataZoom:{borderColor:ke.accent10,textStyle:{color:ke.tertiary},brushStyle:{color:ke.backgroundTint},handleStyle:{color:ke.neutral00,borderColor:ke.accent20},moveHandleStyle:{color:ke.accent40},emphasis:{handleStyle:{borderColor:ke.accent50}},dataBackground:{lineStyle:{color:ke.accent30},areaStyle:{color:ke.accent20}},selectedDataBackground:{lineStyle:{color:ke.accent50},areaStyle:{color:ke.accent30}}},visualMap:{textStyle:{color:ke.secondary},handleStyle:{borderColor:ke.neutral30}},timeline:{lineStyle:{color:ke.accent10},label:{color:ke.tertiary},controlStyle:{color:ke.accent30,borderColor:ke.accent30}},calendar:{itemStyle:{color:ke.neutral00,borderColor:ke.neutral20},dayLabel:{color:ke.tertiary},monthLabel:{color:ke.secondary},yearLabel:{color:ke.secondary}},matrix:{x:w5,y:w5,backgroundColor:{borderColor:ke.axisLine},body:{itemStyle:{borderColor:ke.borderTint}}},timeAxis:Rv(),logAxis:Rv(),valueAxis:Rv(),categoryAxis:Rv(),line:{symbol:"circle"},graph:{color:ke.theme},gauge:{title:{color:ke.secondary},axisLine:{lineStyle:{color:[[1,ke.neutral05]]}},axisLabel:{color:ke.axisLabel},detail:{color:ke.primary}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}},funnel:{itemStyle:{borderColor:ke.background}},radar:(function(){var r=Rv();return r.axisName={color:ke.axisLabel},r.axisLine.lineStyle.color=ke.neutral20,r})(),treemap:{breadcrumb:{itemStyle:{color:ke.neutral20,textStyle:{color:ke.secondary}},emphasis:{itemStyle:{color:ke.neutral30}}}},sunburst:{itemStyle:{borderColor:ke.background}},map:{itemStyle:{borderColor:ke.border,areaColor:ke.neutral10},label:{color:ke.tertiary},emphasis:{label:{color:ke.primary},itemStyle:{areaColor:ke.highlight}},select:{label:{color:ke.primary},itemStyle:{areaColor:ke.highlight}}},geo:{itemStyle:{borderColor:ke.border,areaColor:ke.neutral10},emphasis:{label:{color:ke.primary},itemStyle:{areaColor:ke.highlight}},select:{label:{color:ke.primary},itemStyle:{color:ke.highlight}}}};iF.categoryAxis.splitLine.show=!1;var _se=(function(){function r(){}return r.prototype.normalizeQuery=function(e){var t={},n={},a={};if(ye(e)){var i=ji(e);t.mainType=i.main||null,t.subType=i.sub||null}else{var o=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1};O(e,function(l,u){for(var c=!1,f=0;f<o.length;f++){var d=o[f],v=u.lastIndexOf(d);if(v>0&&v===u.length-d.length){var g=u.slice(0,v);g!=="data"&&(t.mainType=g,t[d.toLowerCase()]=l,c=!0)}}s.hasOwnProperty(u)&&(n[u]=l,c=!0),c||(a[u]=l)})}return{cptQuery:t,dataQuery:n,otherQuery:a}},r.prototype.filter=function(e,t){var n=this.eventInfo;if(!n)return!0;var a=n.targetEl,i=n.packedEvent,o=n.model,s=n.view;if(!o||!s)return!0;var l=t.cptQuery,u=t.dataQuery;return c(l,o,"mainType")&&c(l,o,"subType")&&c(l,o,"index","componentIndex")&&c(l,o,"name")&&c(l,o,"id")&&c(u,i,"name")&&c(u,i,"dataIndex")&&c(u,i,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(e,t.otherQuery,a,i));function c(f,d,v,g){return f[v]==null||d[g||v]===f[v]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r})(),rA=["symbol","symbolSize","symbolRotate","symbolOffset"],T5=rA.concat(["symbolKeepAspect"]),Sse={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData();if(r.legendIcon&&t.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var n={},a={},i=!1,o=0;o<rA.length;o++){var s=rA[o],l=r.get(s);Me(l)?(i=!0,a[s]=l):n[s]=l}if(n.symbol=n.symbol||r.defaultSymbol,t.setVisual(ie({legendIcon:r.legendIcon||n.symbol,symbolKeepAspect:r.get("symbolKeepAspect")},n)),e.isSeriesFiltered(r))return;var u=it(a);function c(f,d){for(var v=r.getRawValue(d),g=r.getDataParams(d),y=0;y<u.length;y++){var x=u[y];f.setItemVisual(d,x,a[x](v,g))}}return{dataEach:i?c:null}}},wse={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!r.hasSymbolVisual||e.isSeriesFiltered(r))return;var t=r.getData();function n(a,i){for(var o=a.getItemModel(i),s=0;s<T5.length;s++){var l=T5[s],u=o.getShallow(l,!0);u!=null&&a.setItemVisual(i,l,u)}}return{dataEach:t.hasItemOption?n:null}}};function $D(r,e,t){switch(t){case"color":var n=r.getItemVisual(e,"style");return n[r.getVisual("drawType")];case"opacity":return r.getItemVisual(e,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getItemVisual(e,t)}}function Kg(r,e){switch(e){case"color":var t=r.getVisual("style");return t[r.getVisual("drawType")];case"opacity":return r.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getVisual(e)}}function oF(r,e,t,n){switch(t){case"color":var a=r.ensureUniqueItemVisual(e,"style");a[r.getVisual("drawType")]=n,r.setItemVisual(e,"colorFromPalette",!1);break;case"opacity":r.ensureUniqueItemVisual(e,"style").opacity=n;break;case"symbol":case"symbolSize":case"liftZ":r.setItemVisual(e,t,n);break}}function sF(r,e){function t(n,a){var i=[];return n.eachComponent({mainType:"series",subType:r,query:a},function(o){i.push(o.seriesIndex)}),i}O([[r+"ToggleSelect","toggleSelect"],[r+"Select","select"],[r+"UnSelect","unselect"]],function(n){e(n[0],function(a,i,o){a=ie({},a),o.dispatchAction(ie(a,{type:n[1],seriesIndex:t(i,a)}))})})}function Af(r,e,t,n,a){var i=r+e;t.isSilent(i)||n.eachComponent({mainType:"series",subType:"pie"},function(o){for(var s=o.seriesIndex,l=o.option.selectedMap,u=a.selected,c=0;c<u.length;c++)if(u[c].seriesIndex===s){var f=o.getData(),d=uc(f,a.fromActionPayload);t.trigger(i,{type:i,seriesId:o.id,name:ce(d)?f.getName(d[0]):f.getName(d),selected:ye(l)?l:ie({},l)})}})}function Tse(r,e,t){r.on("selectchanged",function(n){var a=t.getModel();n.isFromClick?(Af("map","selectchanged",e,a,n),Af("pie","selectchanged",e,a,n)):n.fromAction==="select"?(Af("map","selected",e,a,n),Af("pie","selected",e,a,n)):n.fromAction==="unselect"&&(Af("map","unselected",e,a,n),Af("pie","unselected",e,a,n))})}function Gu(r,e,t){for(var n;r&&!(e(r)&&(n=r,t));)r=r.__hostTarget||r.parent;return n}var Cse=Math.round(Math.random()*9),Ase=typeof Object.defineProperty=="function",Mse=(function(){function r(){this._id="__ec_inner_"+Cse++}return r.prototype.get=function(e){return this._guard(e)[this._id]},r.prototype.set=function(e,t){var n=this._guard(e);return Ase?Object.defineProperty(n,this._id,{value:t,enumerable:!1,configurable:!0}):n[this._id]=t,this},r.prototype.delete=function(e){return this.has(e)?(delete this._guard(e)[this._id],!0):!1},r.prototype.has=function(e){return!!this._guard(e)[this._id]},r.prototype._guard=function(e){if(e!==Object(e))throw TypeError("Value of WeakMap is not a non-null object.");return e},r})(),Dse=tt.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,n=e.cy,a=e.width/2,i=e.height/2;r.moveTo(t,n-i),r.lineTo(t+a,n+i),r.lineTo(t-a,n+i),r.closePath()}}),Nse=tt.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,n=e.cy,a=e.width/2,i=e.height/2;r.moveTo(t,n-i),r.lineTo(t+a,n),r.lineTo(t,n+i),r.lineTo(t-a,n),r.closePath()}}),Lse=tt.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.x,n=e.y,a=e.width/5*3,i=Math.max(a,e.height),o=a/2,s=o*o/(i-o),l=n-i+o+s,u=Math.asin(s/o),c=Math.cos(u)*o,f=Math.sin(u),d=Math.cos(u),v=o*.6,g=o*.7;r.moveTo(t-c,l+s),r.arc(t,l,o,Math.PI-u,Math.PI*2+u),r.bezierCurveTo(t+c-f*v,l+s+d*v,t,n-g,t,n),r.bezierCurveTo(t,n-g,t-c+f*v,l+s+d*v,t-c,l+s),r.closePath()}}),Rse=tt.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.height,n=e.width,a=e.x,i=e.y,o=n/3*2;r.moveTo(a,i),r.lineTo(a+o,i+t),r.lineTo(a,i+t/4*3),r.lineTo(a-o,i+t),r.lineTo(a,i),r.closePath()}}),Ese={line:lr,rect:qe,roundRect:qe,square:qe,circle:eo,diamond:Nse,pin:Lse,arrow:Rse,triangle:Dse},kse={line:function(r,e,t,n,a){a.x1=r,a.y1=e+n/2,a.x2=r+t,a.y2=e+n/2},rect:function(r,e,t,n,a){a.x=r,a.y=e,a.width=t,a.height=n},roundRect:function(r,e,t,n,a){a.x=r,a.y=e,a.width=t,a.height=n,a.r=Math.min(t,n)/4},square:function(r,e,t,n,a){var i=Math.min(t,n);a.x=r,a.y=e,a.width=i,a.height=i},circle:function(r,e,t,n,a){a.cx=r+t/2,a.cy=e+n/2,a.r=Math.min(t,n)/2},diamond:function(r,e,t,n,a){a.cx=r+t/2,a.cy=e+n/2,a.width=t,a.height=n},pin:function(r,e,t,n,a){a.x=r+t/2,a.y=e+n/2,a.width=t,a.height=n},arrow:function(r,e,t,n,a){a.x=r+t/2,a.y=e+n/2,a.width=t,a.height=n},triangle:function(r,e,t,n,a){a.cx=r+t/2,a.cy=e+n/2,a.width=t,a.height=n}},Xx={};O(Ese,function(r,e){Xx[e]=new r});var Ise=tt.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(r,e,t){var n=Ox(r,e,t),a=this.shape;return a&&a.symbolType==="pin"&&e.position==="inside"&&(n.y=t.y+t.height*.4),n},buildPath:function(r,e,t){var n=e.symbolType;if(n!=="none"){var a=Xx[n];a||(n="rect",a=Xx[n]),kse[n](e.x,e.y,e.width,e.height,a.shape),a.buildPath(r,a.shape,t)}}});function Ose(r,e){if(this.type!=="image"){var t=this.style;this.__isEmptyBrush?(t.stroke=r,t.fill=e||ee.color.neutral00,t.lineWidth=2):this.shape.symbolType==="line"?t.stroke=r:t.fill=r,this.markRedraw()}}function ur(r,e,t,n,a,i,o){var s=r.indexOf("empty")===0;s&&(r=r.substr(5,1).toLowerCase()+r.substr(6));var l;return r.indexOf("image://")===0?l=_D(r.slice(8),new Oe(e,t,n,a),o?"center":"cover"):r.indexOf("path://")===0?l=Oh(r.slice(7),{},new Oe(e,t,n,a),o?"center":"cover"):l=new Ise({shape:{symbolType:r,x:e,y:t,width:n,height:a}}),l.__isEmptyBrush=s,l.setColor=Ose,i&&l.setColor(i),l}function fd(r){return ce(r)||(r=[+r,+r]),[r[0]||0,r[1]||0]}function Tc(r,e){if(r!=null)return ce(r)||(r=[r,r]),[me(r[0],e[0])||0,me(Ce(r[1],r[0]),e[1])||0]}function Hu(r){return isFinite(r)}function Pse(r,e,t){var n=e.x==null?0:e.x,a=e.x2==null?1:e.x2,i=e.y==null?0:e.y,o=e.y2==null?0:e.y2;e.global||(n=n*t.width+t.x,a=a*t.width+t.x,i=i*t.height+t.y,o=o*t.height+t.y),n=Hu(n)?n:0,a=Hu(a)?a:1,i=Hu(i)?i:0,o=Hu(o)?o:0;var s=r.createLinearGradient(n,i,a,o);return s}function jse(r,e,t){var n=t.width,a=t.height,i=Math.min(n,a),o=e.x==null?.5:e.x,s=e.y==null?.5:e.y,l=e.r==null?.5:e.r;e.global||(o=o*n+t.x,s=s*a+t.y,l=l*i),o=Hu(o)?o:.5,s=Hu(s)?s:.5,l=l>=0&&Hu(l)?l:.5;var u=r.createRadialGradient(o,s,0,o,s,l);return u}function nA(r,e,t){for(var n=e.type==="radial"?jse(r,e,t):Pse(r,e,t),a=e.colorStops,i=0;i<a.length;i++)n.addColorStop(a[i].offset,a[i].color);return n}function zse(r,e){if(r===e||!r&&!e)return!1;if(!r||!e||r.length!==e.length)return!0;for(var t=0;t<r.length;t++)if(r[t]!==e[t])return!0;return!1}function Qy(r){return parseInt(r,10)}function nh(r,e,t){var n=["width","height"][e],a=["clientWidth","clientHeight"][e],i=["paddingLeft","paddingTop"][e],o=["paddingRight","paddingBottom"][e];if(t[n]!=null&&t[n]!=="auto")return parseFloat(t[n]);var s=document.defaultView.getComputedStyle(r);return(r[a]||Qy(s[n])||Qy(r.style[n]))-(Qy(s[i])||0)-(Qy(s[o])||0)|0}function Bse(r,e){return!r||r==="solid"||!(e>0)?null:r==="dashed"?[4*e,2*e]:r==="dotted"?[e]:st(r)?[r]:ce(r)?r:null}function KD(r){var e=r.style,t=e.lineDash&&e.lineWidth>0&&Bse(e.lineDash,e.lineWidth),n=e.lineDashOffset;if(t){var a=e.strokeNoScale&&r.getLineScale?r.getLineScale():1;a&&a!==1&&(t=fe(t,function(i){return i/a}),n/=a)}return[t,n]}var Vse=new qi(!0);function qx(r){var e=r.stroke;return!(e==null||e==="none"||!(r.lineWidth>0))}function C5(r){return typeof r=="string"&&r!=="none"}function Zx(r){var e=r.fill;return e!=null&&e!=="none"}function A5(r,e){if(e.fillOpacity!=null&&e.fillOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.fillOpacity*e.opacity,r.fill(),r.globalAlpha=t}else r.fill()}function M5(r,e){if(e.strokeOpacity!=null&&e.strokeOpacity!==1){var t=r.globalAlpha;r.globalAlpha=e.strokeOpacity*e.opacity,r.stroke(),r.globalAlpha=t}else r.stroke()}function aA(r,e,t){var n=cD(e.image,e.__image,t);if(tb(n)){var a=r.createPattern(n,e.repeat||"repeat");if(typeof DOMMatrix=="function"&&a&&a.setTransform){var i=new DOMMatrix;i.translateSelf(e.x||0,e.y||0),i.rotateSelf(0,0,(e.rotation||0)*wp),i.scaleSelf(e.scaleX||1,e.scaleY||1),a.setTransform(i)}return a}}function Gse(r,e,t,n){var a,i=qx(t),o=Zx(t),s=t.strokePercent,l=s<1,u=!e.path;(!e.silent||l)&&u&&e.createPathProxy();var c=e.path||Vse,f=e.__dirty;if(!n){var d=t.fill,v=t.stroke,g=o&&!!d.colorStops,y=i&&!!v.colorStops,x=o&&!!d.image,b=i&&!!v.image,w=void 0,T=void 0,C=void 0,D=void 0,M=void 0;(g||y)&&(M=e.getBoundingRect()),g&&(w=f?nA(r,d,M):e.__canvasFillGradient,e.__canvasFillGradient=w),y&&(T=f?nA(r,v,M):e.__canvasStrokeGradient,e.__canvasStrokeGradient=T),x&&(C=f||!e.__canvasFillPattern?aA(r,d,e):e.__canvasFillPattern,e.__canvasFillPattern=C),b&&(D=f||!e.__canvasStrokePattern?aA(r,v,e):e.__canvasStrokePattern,e.__canvasStrokePattern=D),g?r.fillStyle=w:x&&(C?r.fillStyle=C:o=!1),y?r.strokeStyle=T:b&&(D?r.strokeStyle=D:i=!1)}var N=e.getGlobalScale();c.setScale(N[0],N[1],e.segmentIgnoreThreshold);var R,E;r.setLineDash&&t.lineDash&&(a=KD(e),R=a[0],E=a[1]);var k=!0;(u||f&Xf)&&(c.setDPR(r.dpr),l?c.setContext(null):(c.setContext(r),k=!1),c.reset(),e.buildPath(c,e.shape,n),c.toStatic(),e.pathUpdated()),k&&c.rebuildPath(r,l?s:1),R&&(r.setLineDash(R),r.lineDashOffset=E),n||(t.strokeFirst?(i&&M5(r,t),o&&A5(r,t)):(o&&A5(r,t),i&&M5(r,t))),R&&r.setLineDash([])}function Hse(r,e,t){var n=e.__image=cD(t.image,e.__image,e,e.onload);if(!(!n||!tb(n))){var a=t.x||0,i=t.y||0,o=e.getWidth(),s=e.getHeight(),l=n.width/n.height;if(o==null&&s!=null?o=s*l:s==null&&o!=null?s=o/l:o==null&&s==null&&(o=n.width,s=n.height),t.sWidth&&t.sHeight){var u=t.sx||0,c=t.sy||0;r.drawImage(n,u,c,t.sWidth,t.sHeight,a,i,o,s)}else if(t.sx&&t.sy){var u=t.sx,c=t.sy,f=o-u,d=s-c;r.drawImage(n,u,c,f,d,a,i,o,s)}else r.drawImage(n,a,i,o,s)}}function Fse(r,e,t){var n,a=t.text;if(a!=null&&(a+=""),a){r.font=t.font||qo,r.textAlign=t.textAlign,r.textBaseline=t.textBaseline;var i=void 0,o=void 0;r.setLineDash&&t.lineDash&&(n=KD(e),i=n[0],o=n[1]),i&&(r.setLineDash(i),r.lineDashOffset=o),t.strokeFirst?(qx(t)&&r.strokeText(a,t.x,t.y),Zx(t)&&r.fillText(a,t.x,t.y)):(Zx(t)&&r.fillText(a,t.x,t.y),qx(t)&&r.strokeText(a,t.x,t.y)),i&&r.setLineDash([])}}var D5=["shadowBlur","shadowOffsetX","shadowOffsetY"],N5=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function lF(r,e,t,n,a){var i=!1;if(!n&&(t=t||{},e===t))return!1;if(n||e.opacity!==t.opacity){jn(r,a),i=!0;var o=Math.max(Math.min(e.opacity,1),0);r.globalAlpha=isNaN(o)?ec.opacity:o}(n||e.blend!==t.blend)&&(i||(jn(r,a),i=!0),r.globalCompositeOperation=e.blend||ec.blend);for(var s=0;s<D5.length;s++){var l=D5[s];(n||e[l]!==t[l])&&(i||(jn(r,a),i=!0),r[l]=r.dpr*(e[l]||0))}return(n||e.shadowColor!==t.shadowColor)&&(i||(jn(r,a),i=!0),r.shadowColor=e.shadowColor||ec.shadowColor),i}function L5(r,e,t,n,a){var i=ug(e,a.inHover),o=n?null:t&&ug(t,a.inHover)||{};if(i===o)return!1;var s=lF(r,i,o,n,a);if((n||i.fill!==o.fill)&&(s||(jn(r,a),s=!0),C5(i.fill)&&(r.fillStyle=i.fill)),(n||i.stroke!==o.stroke)&&(s||(jn(r,a),s=!0),C5(i.stroke)&&(r.strokeStyle=i.stroke)),(n||i.opacity!==o.opacity)&&(s||(jn(r,a),s=!0),r.globalAlpha=i.opacity==null?1:i.opacity),e.hasStroke()){var l=i.lineWidth,u=l/(i.strokeNoScale&&e.getLineScale?e.getLineScale():1);r.lineWidth!==u&&(s||(jn(r,a),s=!0),r.lineWidth=u)}for(var c=0;c<N5.length;c++){var f=N5[c],d=f[0];(n||i[d]!==o[d])&&(s||(jn(r,a),s=!0),r[d]=i[d]||f[1])}return s}function Use(r,e,t,n,a){return lF(r,ug(e,a.inHover),t&&ug(t,a.inHover),n,a)}function uF(r,e){var t=e.transform,n=r.dpr||1;t?r.setTransform(n*t[0],n*t[1],n*t[2],n*t[3],n*t[4],n*t[5]):r.setTransform(n,0,0,n,0,0)}function Yse(r,e,t){for(var n=!1,a=0;a<r.length;a++){var i=r[a];n=n||i.isZeroArea(),uF(e,i),e.beginPath(),i.buildPath(e,i.shape),e.clip()}t.allClipped=n}function Wse(r,e){return r&&e?r[0]!==e[0]||r[1]!==e[1]||r[2]!==e[2]||r[3]!==e[3]||r[4]!==e[4]||r[5]!==e[5]:!(!r&&!e)}var R5=1,E5=2,k5=3,I5=4;function Xse(r){var e=Zx(r),t=qx(r);return!(r.lineDash||!(+e^+t)||e&&typeof r.fill!="string"||t&&typeof r.stroke!="string"||r.strokePercent<1||r.strokeOpacity<1||r.fillOpacity<1)}function jn(r,e){e.batchFill&&r.fill(),e.batchStroke&&r.stroke(),e.batchFill="",e.batchStroke=""}function ug(r,e){return e&&r.__hoverStyle||r.style}function QD(r,e){Fu(r,e,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function Fu(r,e,t,n){var a=e.transform;if(!e.shouldBePainted(t.viewWidth,t.viewHeight,!1,!1)){e.__dirty&=~ea,e.__isRendered=!1;return}var i=e.__clipPaths,o=t.prevElClipPaths,s=!1,l=!1;if((!o||zse(i,o))&&(o&&o.length&&(jn(r,t),r.restore(),l=s=!0,t.prevElClipPaths=null,t.allClipped=!1,t.prevEl=null),i&&i.length&&(jn(r,t),r.save(),Yse(i,r,t),s=!0),t.prevElClipPaths=i),t.allClipped){e.__isRendered=!1;return}e.beforeBrush&&e.beforeBrush(),e.innerBeforeBrush();var u=t.prevEl;u||(l=s=!0);var c=e instanceof tt&&e.autoBatch&&Xse(e.style);s||Wse(a,u.transform)?(jn(r,t),uF(r,e)):c||jn(r,t);var f=ug(e,t.inHover);e instanceof tt?(t.lastDrawType!==R5&&(l=!0,t.lastDrawType=R5),L5(r,e,u,l,t),(!c||!t.batchFill&&!t.batchStroke)&&r.beginPath(),Gse(r,e,f,c),c&&(t.batchFill=f.fill||"",t.batchStroke=f.stroke||"")):e instanceof Ih?(t.lastDrawType!==k5&&(l=!0,t.lastDrawType=k5),L5(r,e,u,l,t),Fse(r,e,f)):e instanceof Ir?(t.lastDrawType!==E5&&(l=!0,t.lastDrawType=E5),Use(r,e,u,l,t),Hse(r,e,f)):e.getTemporalDisplayables&&(t.lastDrawType!==I5&&(l=!0,t.lastDrawType=I5),qse(r,e,t)),c&&n&&jn(r,t),e.innerAfterBrush(),e.afterBrush&&e.afterBrush(),t.prevEl=e,e.__dirty=0,e.__isRendered=!0}function qse(r,e,t){var n=e.getDisplayables(),a=e.getTemporalDisplayables();r.save();var i={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:t.viewWidth,viewHeight:t.viewHeight,inHover:t.inHover},o,s;for(o=e.getCursor(),s=n.length;o<s;o++){var l=n[o];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),Fu(r,l,i,o===s-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),i.prevEl=l}for(var u=0,c=a.length;u<c;u++){var l=a[u];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),Fu(r,l,i,u===c-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),i.prevEl=l}e.clearTemporalDisplayables(),e.notClear=!0,r.restore()}var qw=new Mse,O5=new Rh(100),P5=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function zh(r,e){if(r==="none")return null;var t=e.getDevicePixelRatio(),n=e.getZr(),a=n.painter.type==="svg";r.dirty&&qw.delete(r);var i=qw.get(r);if(i)return i;var o=Re(r,{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 l(s),s.rotation=o.rotation,s.scaleX=s.scaleY=a?1:1/t,qw.set(r,s),r.dirty=!1,s;function l(u){for(var c=[t],f=!0,d=0;d<P5.length;++d){var v=o[P5[d]];if(v!=null&&!ce(v)&&!ye(v)&&!st(v)&&typeof v!="boolean"){f=!1;break}c.push(v)}var g;if(f){g=c.join(",")+(a?"-svg":"");var y=O5.get(g);y&&(a?u.svgElement=y:u.image=y)}var x=fF(o.dashArrayX),b=Zse(o.dashArrayY),w=cF(o.symbol),T=$se(x),C=hF(b),D=!a&&Bn.createCanvas(),M=a&&{tag:"g",attrs:{},key:"dcl",children:[]},N=E(),R;D&&(D.width=N.width*t,D.height=N.height*t,R=D.getContext("2d")),k(),f&&O5.put(g,D||M),u.image=D,u.svgElement=M,u.svgWidth=N.width,u.svgHeight=N.height;function E(){for(var I=1,B=0,P=T.length;B<P;++B)I=QO(I,T[B]);for(var H=1,B=0,P=w.length;B<P;++B)H=QO(H,w[B].length);I*=H;var V=C*T.length*w.length;return{width:Math.max(1,Math.min(I,o.maxTileWidth)),height:Math.max(1,Math.min(V,o.maxTileHeight))}}function k(){R&&(R.clearRect(0,0,D.width,D.height),o.backgroundColor&&(R.fillStyle=o.backgroundColor,R.fillRect(0,0,D.width,D.height)));for(var I=0,B=0;B<b.length;++B)I+=b[B];if(I<=0)return;for(var P=-C,H=0,V=0,j=0;P<N.height;){if(H%2===0){for(var U=V/2%w.length,F=0,X=0,G=0;F<N.width*2;){for(var W=0,B=0;B<x[j].length;++B)W+=x[j][B];if(W<=0)break;if(X%2===0){var $=(1-o.symbolSize)*.5,te=F+x[j][X]*$,ue=P+b[H]*$,ge=x[j][X]*o.symbolSize,Se=b[H]*o.symbolSize,Xe=G/2%w[U].length;be(te,ue,ge,Se,w[U][Xe])}F+=x[j][X],++G,++X,X===x[j].length&&(X=0)}++j,j===x.length&&(j=0)}P+=b[H],++V,++H,H===b.length&&(H=0)}function be(we,ze,oe,pe,Be){var Le=a?1:t,at=ur(Be,we*Le,ze*Le,oe*Le,pe*Le,o.color,o.symbolKeepAspect);if(a){var ft=n.painter.renderOneToVNode(at);ft&&M.children.push(ft)}else QD(R,at)}}}}function cF(r){if(!r||r.length===0)return[["rect"]];if(ye(r))return[[r]];for(var e=!0,t=0;t<r.length;++t)if(!ye(r[t])){e=!1;break}if(e)return cF([r]);for(var n=[],t=0;t<r.length;++t)ye(r[t])?n.push([r[t]]):n.push(r[t]);return n}function fF(r){if(!r||r.length===0)return[[0,0]];if(st(r)){var e=Math.ceil(r);return[[e,e]]}for(var t=!0,n=0;n<r.length;++n)if(!st(r[n])){t=!1;break}if(t)return fF([r]);for(var a=[],n=0;n<r.length;++n)if(st(r[n])){var e=Math.ceil(r[n]);a.push([e,e])}else{var e=fe(r[n],function(s){return Math.ceil(s)});e.length%2===1?a.push(e.concat(e)):a.push(e)}return a}function Zse(r){if(!r||typeof r=="object"&&r.length===0)return[0,0];if(st(r)){var e=Math.ceil(r);return[e,e]}var t=fe(r,function(n){return Math.ceil(n)});return r.length%2?t.concat(t):t}function $se(r){return fe(r,function(e){return hF(e)})}function hF(r){for(var e=0,t=0;t<r.length;++t)e+=r[t];return r.length%2===1?e*2:e}function Kse(r,e){r.eachRawSeries(function(t){if(!r.isSeriesFiltered(t)){var n=t.getData();n.hasItemVisual()&&n.each(function(o){var s=n.getItemVisual(o,"decal");if(s){var l=n.ensureUniqueItemVisual(o,"style");l.decal=zh(s,e)}});var a=n.getVisual("decal");if(a){var i=n.getVisual("style");i.decal=zh(a,e)}}})}var qa=new za,dF={};function Qse(r,e){dF[r]=e}function vF(r){return dF[r]}var pF={};function gF(r,e){pF[r]=e}function Jse(r){return pF[r]}var ele="6.0.0",tle={zrender:"6.0.0"},rle=1,nle=800,ale=900,ile=1e3,ole=2e3,sle=5e3,mF=1e3,lle=1100,JD=2e3,yF=3e3,ule=4e3,gb=4500,cle=4600,fle=5e3,hle=6e3,xF=7e3,bF={PROCESSOR:{FILTER:ile,SERIES_FILTER:nle,STATISTIC:sle},VISUAL:{LAYOUT:mF,PROGRESSIVE_LAYOUT:lle,GLOBAL:JD,CHART:yF,POST_CHART_LAYOUT:cle,COMPONENT:ule,BRUSH:fle,CHART_ITEM:gb,ARIA:hle,DECAL:xF}},yr="__flagInMainProcess",Jy="__mainProcessVersion",Br="__pendingUpdate",Zw="__needsUpdateStatus",j5=/^[a-zA-Z0-9_]+$/,$w="__connectUpdateStatus",z5=0,dle=1,vle=2;function _F(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(this.isDisposed()){this.id;return}return wF(this,r,e)}}function SF(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return wF(this,r,e)}}function wF(r,e,t){return t[0]=t[0]&&t[0].toLowerCase(),za.prototype[e].apply(r,t)}var TF=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(za),CF=TF.prototype;CF.on=SF("on");CF.off=SF("off");var bu,Kw,e0,_o,t0,Qw,Jw,Mf,Df,B5,V5,e2,G5,r0,H5,AF,xa,F5,Nf,$x=(function(r){K(e,r);function e(t,n,a){var i=r.call(this,new _se)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],a=a||{},i._dom=t;var o="canvas",s="auto",l=!1;i[Jy]=1,a.ssr&&Q6(function(d){var v=je(d),g=v.dataIndex;if(g!=null){var y=Te();return y.set("series_index",v.seriesIndex),y.set("data_index",g),v.ssrType&&y.set("ssr_type",v.ssrType),y}});var u=i._zr=AC(t,{renderer:a.renderer||o,devicePixelRatio:a.devicePixelRatio,width:a.width,height:a.height,ssr:a.ssr,useDirtyRect:Ce(a.useDirtyRect,l),useCoarsePointer:Ce(a.useCoarsePointer,s),pointerSize:a.pointerSize});i._ssr=a.ssr,i._throttledZrFlush=pb(xe(u.flush,u),17),i._updateTheme(n),i._locale=bie(a.locale||r8),i._coordSysMgr=new ld;var c=i._api=H5(i);function f(d,v){return d.__prio-v.__prio}return W0(Qx,f),W0(sA,f),i._scheduler=new tF(i,c,sA,Qx),i._messageCenter=new TF,i._initEvents(),i.resize=xe(i.resize,i),u.animation.on("frame",i._onframe,i),B5(u,i),V5(u,i),Xp(i),i}return e.prototype._onframe=function(){if(!this._disposed){F5(this);var t=this._scheduler;if(this[Br]){var n=this[Br].silent;this[yr]=!0,Nf(this);try{bu(this),_o.update.call(this,null,this[Br].updateParams)}catch(l){throw this[yr]=!1,this[Br]=null,l}this._zr.flush(),this[yr]=!1,this[Br]=null,Mf.call(this,n),Df.call(this,n)}else if(t.unfinished){var a=rle,i=this._model,o=this._api;t.unfinished=!1;do{var s=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),Qw(this,i),t.performVisualTasks(i),r0(this,this._model,o,"remain",{}),a-=+new Date-s}while(a>0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,n,a){if(!this[yr]){if(this._disposed){this.id;return}var i,o,s;if(Ee(n)&&(a=n.lazyUpdate,i=n.silent,o=n.replaceMerge,s=n.transition,n=n.notMerge),this[yr]=!0,Nf(this),!this._model||n){var l=new noe(this._api),u=this._theme,c=this._model=new YD;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,u,this._locale,l)}this._model.setOption(t,{replaceMerge:o},lA);var f={seriesTransition:s,optionChanged:!0};if(a)this[Br]={silent:i,updateParams:f},this[yr]=!1,this.getZr().wakeUp();else{try{bu(this),_o.update.call(this,null,f)}catch(d){throw this[Br]=null,this[yr]=!1,d}this._ssr||this._zr.flush(),this[Br]=null,this[yr]=!1,Mf.call(this,i),Df.call(this,i)}}},e.prototype.setTheme=function(t,n){if(!this[yr]){if(this._disposed){this.id;return}var a=this._model;if(a){var i=n&&n.silent,o=null;this[Br]&&(i==null&&(i=this[Br].silent),o=this[Br].updateParams,this[Br]=null),this[yr]=!0,Nf(this);try{this._updateTheme(t),a.setTheme(this._theme),bu(this),_o.update.call(this,{type:"setTheme"},o)}catch(s){throw this[yr]=!1,s}this[yr]=!1,Mf.call(this,i),Df.call(this,i)}}},e.prototype._updateTheme=function(t){ye(t)&&(t=MF[t]),t&&(t=De(t),t&&L8(t,!0),this._theme=t)},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||nt.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var n=this._zr.painter;return n.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var n=this._zr.painter;return n.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){var t=this._zr,n=t.storage.getDisplayList();return O(n,function(a){a.stopAnimation(null,!0)}),t.painter.toDataURL()},e.prototype.getDataURL=function(t){if(this._disposed){this.id;return}t=t||{};var n=t.excludeComponents,a=this._model,i=[],o=this;O(n,function(l){a.eachComponent({mainType:l},function(u){var c=o._componentsMap[u.__viewId];c.group.ignore||(i.push(c),c.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return O(i,function(l){l.group.ignore=!1}),s},e.prototype.getConnectedDataURL=function(t){if(this._disposed){this.id;return}var n=t.type==="svg",a=this.group,i=Math.min,o=Math.max,s=1/0;if(Jx[a]){var l=s,u=s,c=-s,f=-s,d=[],v=t&&t.pixelRatio||this.getDevicePixelRatio();O(nc,function(T,C){if(T.group===a){var D=n?T.getZr().painter.getSvgDom().innerHTML:T.renderToCanvas(De(t)),M=T.getDom().getBoundingClientRect();l=i(M.left,l),u=i(M.top,u),c=o(M.right,c),f=o(M.bottom,f),d.push({dom:D,left:M.left,top:M.top})}}),l*=v,u*=v,c*=v,f*=v;var g=c-l,y=f-u,x=Bn.createCanvas(),b=AC(x,{renderer:n?"svg":"canvas"});if(b.resize({width:g,height:y}),n){var w="";return O(d,function(T){var C=T.left-l,D=T.top-u;w+='<g transform="translate('+C+","+D+')">'+T.dom+"</g>"}),b.painter.getSvgRoot().innerHTML=w,t.connectedBackgroundColor&&b.painter.setBackgroundColor(t.connectedBackgroundColor),b.refreshImmediately(),b.painter.toDataURL()}else return t.connectedBackgroundColor&&b.add(new qe({shape:{x:0,y:0,width:g,height:y},style:{fill:t.connectedBackgroundColor}})),O(d,function(T){var C=new Ir({style:{x:T.left*v-l,y:T.top*v-u,image:T.dom}});b.add(C)}),b.refreshImmediately(),x.toDataURL("image/"+(t&&t.type||"png"))}else return this.getDataURL(t)},e.prototype.convertToPixel=function(t,n,a){return t0(this,"convertToPixel",t,n,a)},e.prototype.convertToLayout=function(t,n,a){return t0(this,"convertToLayout",t,n,a)},e.prototype.convertFromPixel=function(t,n,a){return t0(this,"convertFromPixel",t,n,a)},e.prototype.containPixel=function(t,n){if(this._disposed){this.id;return}var a=this._model,i,o=fh(a,t);return O(o,function(s,l){l.indexOf("Models")>=0&&O(s,function(u){var c=u.coordinateSystem;if(c&&c.containPoint)i=i||!!c.containPoint(n);else if(l==="seriesModels"){var f=this._chartsMap[u.__viewId];f&&f.containPoint&&(i=i||f.containPoint(n,u))}},this)},this),!!i},e.prototype.getVisual=function(t,n){var a=this._model,i=fh(a,t,{defaultMainType:"series"}),o=i.seriesModel,s=o.getData(),l=i.hasOwnProperty("dataIndexInside")?i.dataIndexInside:i.hasOwnProperty("dataIndex")?s.indexOfRawIndex(i.dataIndex):null;return l!=null?$D(s,l,n):Kg(s,n)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t=this;O(ple,function(a){var i=function(o){var s=t.getModel(),l=o.target,u,c=a==="globalout";if(c?u={}:l&&Gu(l,function(y){var x=je(y);if(x&&x.dataIndex!=null){var b=x.dataModel||s.getSeriesByIndex(x.seriesIndex);return u=b&&b.getDataParams(x.dataIndex,x.dataType,l)||{},!0}else if(x.eventData)return u=ie({},x.eventData),!0},!0),u){var f=u.componentType,d=u.componentIndex;(f==="markLine"||f==="markPoint"||f==="markArea")&&(f="series",d=u.seriesIndex);var v=f&&d!=null&&s.getComponent(f,d),g=v&&t[v.mainType==="series"?"_chartsMap":"_componentsMap"][v.__viewId];u.event=o,u.type=a,t._$eventProcessor.eventInfo={targetEl:l,packedEvent:u,model:v,view:g},t.trigger(a,u)}};i.zrEventfulCallAtLast=!0,t._zr.on(a,i,t)});var n=this._messageCenter;O(oA,function(a,i){n.on(i,function(o){t.trigger(i,o)})}),Tse(n,this,this._api)},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var t=this.getDom();t&&cH(this.getDom(),tN,"");var n=this,a=n._api,i=n._model;O(n._componentsViews,function(o){o.dispose(i,a)}),O(n._chartsViews,function(o){o.dispose(i,a)}),n._zr.dispose(),n._dom=n._model=n._chartsMap=n._componentsMap=n._chartsViews=n._componentsViews=n._scheduler=n._api=n._zr=n._throttledZrFlush=n._theme=n._coordSysMgr=n._messageCenter=null,delete nc[n.id]},e.prototype.resize=function(t){if(!this[yr]){if(this._disposed){this.id;return}this._zr.resize(t);var n=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!n){var a=n.resetOption("media"),i=t&&t.silent;this[Br]&&(i==null&&(i=this[Br].silent),a=!0,this[Br]=null),this[yr]=!0,Nf(this);try{a&&bu(this),_o.update.call(this,{type:"resize",animation:ie({duration:0},t&&t.animation)})}catch(o){throw this[yr]=!1,o}this[yr]=!1,Mf.call(this,i),Df.call(this,i)}}},e.prototype.showLoading=function(t,n){if(this._disposed){this.id;return}if(Ee(t)&&(n=t,t=""),t=t||"default",this.hideLoading(),!!uA[t]){var a=uA[t](this._api,n),i=this._zr;this._loadingFX=a,i.add(a)}},e.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},e.prototype.makeActionFromEvent=function(t){var n=ie({},t);return n.type=iA[t.type],n},e.prototype.dispatchAction=function(t,n){if(this._disposed){this.id;return}if(Ee(n)||(n={silent:!!n}),!!Kx[t.type]&&this._model){if(this[yr]){this._pendingActions.push(t);return}var a=n.silent;Jw.call(this,t,a);var i=n.flush;i?this._zr.flush():i!==!1&&nt.browser.weChat&&this._throttledZrFlush(),Mf.call(this,a),Df.call(this,a)}},e.prototype.updateLabelLayout=function(){qa.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed){this.id;return}var n=t.seriesIndex,a=this.getModel(),i=a.getSeriesByIndex(n);i.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()},e.internalField=(function(){bu=function(f){var d=f._scheduler;d.restorePipelines(f._model),d.prepareStageTasks(),Kw(f,!0),Kw(f,!1),d.plan()},Kw=function(f,d){for(var v=f._model,g=f._scheduler,y=d?f._componentsViews:f._chartsViews,x=d?f._componentsMap:f._chartsMap,b=f._zr,w=f._api,T=0;T<y.length;T++)y[T].__alive=!1;d?v.eachComponent(function(M,N){M!=="series"&&C(N)}):v.eachSeries(C);function C(M){var N=M.__requireNewView;M.__requireNewView=!1;var R="_ec_"+M.id+"_"+M.type,E=!N&&x[R];if(!E){var k=ji(M.type),I=d?Rt.getClass(k.main,k.sub):St.getClass(k.sub);E=new I,E.init(v,w),x[R]=E,y.push(E),b.add(E.group)}M.__viewId=E.__id=R,E.__alive=!0,E.__model=M,E.group.__ecComponentInfo={mainType:M.mainType,index:M.componentIndex},!d&&g.prepareView(E,M,v,w)}for(var T=0;T<y.length;){var D=y[T];D.__alive?T++:(!d&&D.renderTask.dispose(),b.remove(D.group),D.dispose(v,w),y.splice(T,1),x[D.__id]===D&&delete x[D.__id],D.__id=D.group.__ecComponentInfo=null)}},e0=function(f,d,v,g,y){var x=f._model;if(x.setUpdatePayload(v),!g){O([].concat(f._componentsViews).concat(f._chartsViews),D);return}var b={};b[g+"Id"]=v[g+"Id"],b[g+"Index"]=v[g+"Index"],b[g+"Name"]=v[g+"Name"];var w={mainType:g,query:b};y&&(w.subType=y);var T=v.excludeSeriesId,C;T!=null&&(C=Te(),O(Lt(T),function(M){var N=xr(M,null);N!=null&&C.set(N,!0)})),x&&x.eachComponent(w,function(M){var N=C&&C.get(M.id)!=null;if(!N)if(MP(v))if(M instanceof Ct)v.type===tc&&!v.notBlur&&!M.get(["emphasis","disabled"])&&Sae(M,v,f._api);else{var R=mD(M.mainType,M.componentIndex,v.name,f._api),E=R.focusSelf,k=R.dispatchers;v.type===tc&&E&&!v.notBlur&&zC(M.mainType,M.componentIndex,f._api),k&&O(k,function(I){v.type===tc?$o(I):Ko(I)})}else VC(v)&&M instanceof Ct&&(Cae(M,v,f._api),CP(M),xa(f))},f),x&&x.eachComponent(w,function(M){var N=C&&C.get(M.id)!=null;N||D(f[g==="series"?"_chartsMap":"_componentsMap"][M.__viewId])},f);function D(M){M&&M.__alive&&M[d]&&M[d](M.__model,x,f._api,v)}},_o={prepareAndUpdate:function(f){bu(this),_o.update.call(this,f,f&&{optionChanged:f.newOption!=null})},update:function(f,d){var v=this._model,g=this._api,y=this._zr,x=this._coordSysMgr,b=this._scheduler;if(v){v.setUpdatePayload(f),b.restoreData(v,f),b.performSeriesTasks(v),x.create(v,g),b.performDataProcessorTasks(v,f),Qw(this,v),x.update(v,g),n(v),b.performVisualTasks(v,f);var w=v.get("backgroundColor")||"transparent";y.setBackgroundColor(w);var T=v.get("darkMode");T!=null&&T!=="auto"&&y.setDarkMode(T),e2(this,v,g,f,d),qa.trigger("afterupdate",v,g)}},updateTransform:function(f){var d=this,v=this._model,g=this._api;if(v){v.setUpdatePayload(f);var y=[];v.eachComponent(function(b,w){if(b!=="series"){var T=d.getViewOfComponentModel(w);if(T&&T.__alive)if(T.updateTransform){var C=T.updateTransform(w,v,g,f);C&&C.update&&y.push(T)}else y.push(T)}});var x=Te();v.eachSeries(function(b){var w=d._chartsMap[b.__viewId];if(w.updateTransform){var T=w.updateTransform(b,v,g,f);T&&T.update&&x.set(b.uid,1)}else x.set(b.uid,1)}),n(v),this._scheduler.performVisualTasks(v,f,{setDirty:!0,dirtyMap:x}),r0(this,v,g,f,{},x),qa.trigger("afterupdate",v,g)}},updateView:function(f){var d=this._model;d&&(d.setUpdatePayload(f),St.markUpdateMethod(f,"updateView"),n(d),this._scheduler.performVisualTasks(d,f,{setDirty:!0}),e2(this,d,this._api,f,{}),qa.trigger("afterupdate",d,this._api))},updateVisual:function(f){var d=this,v=this._model;v&&(v.setUpdatePayload(f),v.eachSeries(function(g){g.getData().clearAllVisual()}),St.markUpdateMethod(f,"updateVisual"),n(v),this._scheduler.performVisualTasks(v,f,{visualType:"visual",setDirty:!0}),v.eachComponent(function(g,y){if(g!=="series"){var x=d.getViewOfComponentModel(y);x&&x.__alive&&x.updateVisual(y,v,d._api,f)}}),v.eachSeries(function(g){var y=d._chartsMap[g.__viewId];y.updateVisual(g,v,d._api,f)}),qa.trigger("afterupdate",v,this._api))},updateLayout:function(f){_o.update.call(this,f)}};function t(f,d,v,g,y){if(f._disposed){f.id;return}for(var x=f._model,b=f._coordSysMgr.getCoordinateSystems(),w,T=fh(x,v),C=0;C<b.length;C++){var D=b[C];if(D[d]&&(w=D[d](x,T,g,y))!=null)return w}}t0=t,Qw=function(f,d){var v=f._chartsMap,g=f._scheduler;d.eachSeries(function(y){g.updateStreamModes(y,v[y.__viewId])})},Jw=function(f,d){var v=this,g=this.getModel(),y=f.type,x=f.escapeConnect,b=Kx[y],w=(b.update||"update").split(":"),T=w.pop(),C=w[0]!=null&&ji(w[0]);this[yr]=!0,Nf(this);var D=[f],M=!1;f.batch&&(M=!0,D=fe(f.batch,function(j){return j=Re(ie({},j),f),j.batch=null,j}));var N=[],R,E=[],k=b.nonRefinedEventType,I=VC(f),B=MP(f);if(B&&EH(this._api),O(D,function(j){var U=b.action(j,g,v._api);if(b.refineEvent?E.push(U):R=U,R=R||ie({},j),R.type=k,N.push(R),B){var F=lD(f),X=F.queryOptionMap,G=F.mainTypeSpecified,W=G?X.keys()[0]:"series";e0(v,T,j,W),xa(v)}else I?(e0(v,T,j,"series"),xa(v)):C&&e0(v,T,j,C.main,C.sub)}),T!=="none"&&!B&&!I&&!C)try{this[Br]?(bu(this),_o.update.call(this,f),this[Br]=null):_o[T].call(this,f)}catch(j){throw this[yr]=!1,j}if(M?R={type:k,escapeConnect:x,batch:N}:R=N[0],this[yr]=!1,!d){var P=void 0;if(b.refineEvent){var H=b.refineEvent(E,f,g,this._api).eventContent;rn(Ee(H)),P=Re({type:b.refinedEventType},H),P.fromAction=f.type,P.fromActionPayload=f,P.escapeConnect=!0}var V=this._messageCenter;V.trigger(R.type,R),P&&V.trigger(P.type,P)}},Mf=function(f){for(var d=this._pendingActions;d.length;){var v=d.shift();Jw.call(this,v,f)}},Df=function(f){!f&&this.trigger("updated")},B5=function(f,d){f.on("rendered",function(v){d.trigger("rendered",v),f.animation.isFinished()&&!d[Br]&&!d._scheduler.unfinished&&!d._pendingActions.length&&d.trigger("finished")})},V5=function(f,d){f.on("mouseover",function(v){var g=v.target,y=Gu(g,rg);y&&(wae(y,v,d._api),xa(d))}).on("mouseout",function(v){var g=v.target,y=Gu(g,rg);y&&(Tae(y,v,d._api),xa(d))}).on("click",function(v){var g=v.target,y=Gu(g,function(w){return je(w).dataIndex!=null},!0);if(y){var x=y.selected?"unselect":"select",b=je(y);d._api.dispatchAction({type:x,dataType:b.dataType,dataIndexInside:b.dataIndex,seriesIndex:b.seriesIndex,isFromClick:!0})}})};function n(f){f.clearColorPalette(),f.eachSeries(function(d){d.clearColorPalette()})}function a(f){var d=[],v=[],g=!1;if(f.eachComponent(function(w,T){var C=T.get("zlevel")||0,D=T.get("z")||0,M=T.getZLevelKey();g=g||!!M,(w==="series"?v:d).push({zlevel:C,z:D,idx:T.componentIndex,type:w,key:M})}),g){var y=d.concat(v),x,b;W0(y,function(w,T){return w.zlevel===T.zlevel?w.z-T.z:w.zlevel-T.zlevel}),O(y,function(w){var T=f.getComponent(w.type,w.idx),C=w.zlevel,D=w.key;x!=null&&(C=Math.max(x,C)),D?(C===x&&D!==b&&C++,b=D):b&&(C===x&&C++,b=""),x=C,T.setZLevel(C)})}}e2=function(f,d,v,g,y){a(d),G5(f,d,v,g,y),O(f._chartsViews,function(x){x.__alive=!1}),r0(f,d,v,g,y),O(f._chartsViews,function(x){x.__alive||x.remove(d,v)})},G5=function(f,d,v,g,y,x){O(x||f._componentsViews,function(b){var w=b.__model;u(w,b),b.render(w,d,v,g),l(w,b),c(w,b)})},r0=function(f,d,v,g,y,x){var b=f._scheduler;y=ie(y||{},{updatedSeries:d.getSeries()}),qa.trigger("series:beforeupdate",d,v,y);var w=!1;d.eachSeries(function(T){var C=f._chartsMap[T.__viewId];C.__alive=!0;var D=C.renderTask;b.updatePayload(D,g),u(T,C),x&&x.get(T.uid)&&D.dirty(),D.perform(b.getPerformArgs(D))&&(w=!0),C.group.silent=!!T.get("silent"),s(T,C),CP(T)}),b.unfinished=w||b.unfinished,qa.trigger("series:layoutlabels",d,v,y),qa.trigger("series:transition",d,v,y),d.eachSeries(function(T){var C=f._chartsMap[T.__viewId];l(T,C),c(T,C)}),o(f,d),qa.trigger("series:afterupdate",d,v,y)},xa=function(f){f[Zw]=!0,f.getZr().wakeUp()},Nf=function(f){f[Jy]=(f[Jy]+1)%1e3},F5=function(f){f[Zw]&&(f.getZr().storage.traverse(function(d){hh(d)||i(d)}),f[Zw]=!1)};function i(f){for(var d=[],v=f.currentStates,g=0;g<v.length;g++){var y=v[g];y==="emphasis"||y==="blur"||y==="select"||d.push(y)}f.selected&&f.states.select&&d.push("select"),f.hoverState===ob&&f.states.emphasis?d.push("emphasis"):f.hoverState===Ug&&f.states.blur&&d.push("blur"),f.useStates(d)}function o(f,d){var v=f._zr,g=v.storage,y=0;g.traverse(function(x){x.isGroup||y++}),y>d.get("hoverLayerThreshold")&&!nt.node&&!nt.worker&&d.eachSeries(function(x){if(!x.preventUsingHoverLayer){var b=f._chartsMap[x.__viewId];b.__alive&&b.eachRendered(function(w){w.states.emphasis&&(w.states.emphasis.hoverLayer=!0)})}})}function s(f,d){var v=f.get("blendMode")||null;d.eachRendered(function(g){g.isGroup||(g.style.blend=v)})}function l(f,d){if(!f.preventAutoZ){var v=dc(f);d.eachRendered(function(g){return ub(g,v.z,v.zlevel),!0})}}function u(f,d){d.eachRendered(function(v){if(!hh(v)){var g=v.getTextContent(),y=v.getTextGuideLine();v.stateTransition&&(v.stateTransition=null),g&&g.stateTransition&&(g.stateTransition=null),y&&y.stateTransition&&(y.stateTransition=null),v.hasState()?(v.prevStates=v.currentStates,v.clearStates()):v.prevStates&&(v.prevStates=null)}})}function c(f,d){var v=f.getModel("stateAnimation"),g=f.isAnimationEnabled(),y=v.get("duration"),x=y>0?{duration:y,delay:v.get("delay"),easing:v.get("easing")}:null;d.eachRendered(function(b){if(b.states&&b.states.emphasis){if(hh(b))return;if(b instanceof tt&&Rae(b),b.__dirty){var w=b.prevStates;w&&b.useStates(w)}if(g){b.stateTransition=x;var T=b.getTextContent(),C=b.getTextGuideLine();T&&(T.stateTransition=x),C&&(C.stateTransition=x)}b.__dirty&&i(b)}})}H5=function(f){return new((function(d){K(v,d);function v(){return d!==null&&d.apply(this,arguments)||this}return v.prototype.getCoordinateSystems=function(){return f._coordSysMgr.getCoordinateSystems()},v.prototype.getComponentByElement=function(g){for(;g;){var y=g.__ecComponentInfo;if(y!=null)return f._model.getComponent(y.mainType,y.index);g=g.parent}},v.prototype.enterEmphasis=function(g,y){$o(g,y),xa(f)},v.prototype.leaveEmphasis=function(g,y){Ko(g,y),xa(f)},v.prototype.enterBlur=function(g){DH(g),xa(f)},v.prototype.leaveBlur=function(g){gD(g),xa(f)},v.prototype.enterSelect=function(g){NH(g),xa(f)},v.prototype.leaveSelect=function(g){LH(g),xa(f)},v.prototype.getModel=function(){return f.getModel()},v.prototype.getViewOfComponentModel=function(g){return f.getViewOfComponentModel(g)},v.prototype.getViewOfSeriesModel=function(g){return f.getViewOfSeriesModel(g)},v.prototype.getMainProcessVersion=function(){return f[Jy]},v})(D8))(f)},AF=function(f){function d(v,g){for(var y=0;y<v.length;y++){var x=v[y];x[$w]=g}}O(iA,function(v,g){f._messageCenter.on(g,function(y){if(Jx[f.group]&&f[$w]!==z5){if(y&&y.escapeConnect)return;var x=f.makeActionFromEvent(y),b=[];O(nc,function(w){w!==f&&w.group===f.group&&b.push(w)}),d(b,z5),O(b,function(w){w[$w]!==dle&&w.dispatchAction(x)}),d(b,vle)}})})}})(),e})(za),eN=$x.prototype;eN.on=_F("on");eN.off=_F("off");eN.one=function(r,e,t){var n=this;function a(){for(var i=[],o=0;o<arguments.length;o++)i[o]=arguments[o];e&&e.apply&&e.apply(this,i),n.off(r,a)}this.on.call(this,r,a,t)};var ple=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];var Kx={},iA={},oA={},sA=[],lA=[],Qx=[],MF={},uA={},nc={},Jx={},gle=+new Date-0,mle=+new Date-0,tN="_echarts_instance_";function yle(r,e,t){var n=!(t&&t.ssr);if(n){var a=rN(r);if(a)return a}var i=new $x(r,e,t);return i.id="ec_"+gle++,nc[i.id]=i,n&&cH(r,tN,i.id),AF(i),qa.trigger("afterinit",i),i}function xle(r){if(ce(r)){var e=r;r=null,O(e,function(t){t.group!=null&&(r=t.group)}),r=r||"g_"+mle++,O(e,function(t){t.group=r})}return Jx[r]=!0,r}function DF(r){Jx[r]=!1}var ble=DF;function _le(r){ye(r)?r=nc[r]:r instanceof $x||(r=rN(r)),r instanceof $x&&!r.isDisposed()&&r.dispose()}function rN(r){return nc[yne(r,tN)]}function Sle(r){return nc[r]}function nN(r,e){MF[r]=e}function aN(r){Fe(lA,r)<0&&lA.push(r)}function iN(r,e){oN(sA,r,e,ole)}function NF(r){mb("afterinit",r)}function LF(r){mb("afterupdate",r)}function mb(r,e){qa.on(r,e)}function ui(r,e,t){var n,a,i,o,s;Me(e)&&(t=e,e=""),Ee(r)?(n=r.type,a=r.event,o=r.update,s=r.publishNonRefinedEvent,t||(t=r.action),i=r.refineEvent):(n=r,a=e);function l(c){return c.toLowerCase()}a=l(a||n);var u=i?l(n):a;Kx[n]||(rn(j5.test(n)&&j5.test(a)),i&&rn(a!==n),Kx[n]={actionType:n,refinedEventType:a,nonRefinedEventType:u,update:o,action:t,refineEvent:i},oA[a]=1,i&&s&&(oA[u]=1),iA[u]=n)}function RF(r,e){ld.register(r,e)}function wle(r){var e=ld.get(r);if(e)return e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice()}function Tle(r,e){gF(r,e)}function EF(r,e){oN(Qx,r,e,mF,"layout")}function El(r,e){oN(Qx,r,e,yF,"visual")}var U5=[];function oN(r,e,t,n,a){if((Me(e)||Ee(e))&&(t=e,e=n),!(Fe(U5,t)>=0)){U5.push(t);var i=tF.wrapStageHandler(t,a);i.__prio=e,i.__raw=t,r.push(i)}}function sN(r,e){uA[r]=e}function Cle(r){p6({createCanvas:r})}function kF(r,e,t){var n=vF("registerMap");n&&n(r,e,t)}function Ale(r){var e=vF("getMap");return e&&e(r)}var IF=Ooe;El(JD,sse);El(gb,lse);El(gb,use);El(JD,Sse);El(gb,wse);El(xF,Kse);aN(L8);iN(ale,poe);sN("default",cse);ui({type:tc,event:tc,update:tc},Kt);ui({type:J0,event:J0,update:J0},Kt);ui({type:zx,event:vD,update:zx,action:Kt,refineEvent:lN,publishNonRefinedEvent:!0});ui({type:PC,event:vD,update:PC,action:Kt,refineEvent:lN,publishNonRefinedEvent:!0});ui({type:Bx,event:vD,update:Bx,action:Kt,refineEvent:lN,publishNonRefinedEvent:!0});function lN(r,e,t,n){return{eventContent:{selected:Aae(t),isFromClick:e.isFromClick||!1}}}nN("default",{});nN("dark",iF);var Mle={},Y5=[],Dle={registerPreprocessor:aN,registerProcessor:iN,registerPostInit:NF,registerPostUpdate:LF,registerUpdateLifecycle:mb,registerAction:ui,registerCoordinateSystem:RF,registerLayout:EF,registerVisual:El,registerTransform:IF,registerLoading:sN,registerMap:kF,registerImpl:Qse,PRIORITY:bF,ComponentModel:Qe,ComponentView:Rt,SeriesModel:Ct,ChartView:St,registerComponentModel:function(r){Qe.registerClass(r)},registerComponentView:function(r){Rt.registerClass(r)},registerSeriesModel:function(r){Ct.registerClass(r)},registerChartView:function(r){St.registerClass(r)},registerCustomSeries:function(r,e){gF(r,e)},registerSubTypeDefaulter:function(r,e){Qe.registerSubTypeDefaulter(r,e)},registerPainter:function(r,e){$6(r,e)}};function We(r){if(ce(r)){O(r,function(e){We(e)});return}Fe(Y5,r)>=0||(Y5.push(r),Me(r)&&(r={install:r}),r.install(Dle))}function Ev(r){return r==null?0:r.length||1}function W5(r){return r}var Qo=(function(){function r(e,t,n,a,i,o){this._old=e,this._new=t,this._oldKeyGetter=n||W5,this._newKeyGetter=a||W5,this.context=i,this._diffModeMultiple=o==="multiple"}return r.prototype.add=function(e){return this._add=e,this},r.prototype.update=function(e){return this._update=e,this},r.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},r.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},r.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},r.prototype.remove=function(e){return this._remove=e,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var e=this._old,t=this._new,n={},a=new Array(e.length),i=new Array(t.length);this._initIndexMap(e,null,a,"_oldKeyGetter"),this._initIndexMap(t,n,i,"_newKeyGetter");for(var o=0;o<e.length;o++){var s=a[o],l=n[s],u=Ev(l);if(u>1){var c=l.shift();l.length===1&&(n[s]=l[0]),this._update&&this._update(c,o)}else u===1?(n[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(i,n)},r.prototype._executeMultiple=function(){var e=this._old,t=this._new,n={},a={},i=[],o=[];this._initIndexMap(e,n,i,"_oldKeyGetter"),this._initIndexMap(t,a,o,"_newKeyGetter");for(var s=0;s<i.length;s++){var l=i[s],u=n[l],c=a[l],f=Ev(u),d=Ev(c);if(f>1&&d===1)this._updateManyToOne&&this._updateManyToOne(c,u),a[l]=null;else if(f===1&&d>1)this._updateOneToMany&&this._updateOneToMany(c,u),a[l]=null;else if(f===1&&d===1)this._update&&this._update(c,u),a[l]=null;else if(f>1&&d>1)this._updateManyToMany&&this._updateManyToMany(c,u),a[l]=null;else if(f>1)for(var v=0;v<f;v++)this._remove&&this._remove(u[v]);else this._remove&&this._remove(u)}this._performRestAdd(o,a)},r.prototype._performRestAdd=function(e,t){for(var n=0;n<e.length;n++){var a=e[n],i=t[a],o=Ev(i);if(o>1)for(var s=0;s<o;s++)this._add&&this._add(i[s]);else o===1&&this._add&&this._add(i);t[a]=null}},r.prototype._initIndexMap=function(e,t,n,a){for(var i=this._diffModeMultiple,o=0;o<e.length;o++){var s="_ec_"+this[a](e[o],o);if(i||(n[o]=s),!!t){var l=t[s],u=Ev(l);u===0?(t[s]=o,i&&n.push(s)):u===1?t[s]=[l,o]:l.push(o)}}},r})(),Nle=(function(){function r(e,t){this._encode=e,this._schema=t}return r.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},r.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},r})();function Lle(r,e){var t={},n=t.encode={},a=Te(),i=[],o=[],s={};O(r.dimensions,function(d){var v=r.getDimensionInfo(d),g=v.coordDim;if(g){var y=v.coordDimIndex;t2(n,g)[y]=d,v.isExtraCoord||(a.set(g,1),Rle(v.type)&&(i[0]=d),t2(s,g)[y]=r.getDimensionIndex(v.name)),v.defaultTooltip&&o.push(d)}_8.each(function(x,b){var w=t2(n,b),T=v.otherDims[b];T!=null&&T!==!1&&(w[T]=v.name)})});var l=[],u={};a.each(function(d,v){var g=n[v];u[v]=g[0],l=l.concat(g)}),t.dataDimsOnCoord=l,t.dataDimIndicesOnCoord=fe(l,function(d){return r.getDimensionInfo(d).storeDimIndex}),t.encodeFirstDimNotExtra=u;var c=n.label;c&&c.length&&(i=c.slice());var f=n.tooltip;return f&&f.length?o=f.slice():o.length||(o=i.slice()),n.defaultedLabel=i,n.defaultedTooltip=o,t.userOutput=new Nle(s,e),t}function t2(r,e){return r.hasOwnProperty(e)||(r[e]=[]),r[e]}function e1(r){return r==="category"?"ordinal":r==="time"?"time":"float"}function Rle(r){return!(r==="ordinal"||r==="time")}var ox=(function(){function r(e){this.otherDims={},e!=null&&ie(this,e)}return r})(),Ele=Je(),kle={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},OF=(function(){function r(e){this.dimensions=e.dimensions,this._dimOmitted=e.dimensionOmitted,this.source=e.source,this._fullDimCount=e.fullDimensionCount,this._updateDimOmitted(e.dimensionOmitted)}return r.prototype.isDimensionOmitted=function(){return this._dimOmitted},r.prototype._updateDimOmitted=function(e){this._dimOmitted=e,e&&(this._dimNameMap||(this._dimNameMap=zF(this.source)))},r.prototype.getSourceDimensionIndex=function(e){return Ce(this._dimNameMap.get(e),-1)},r.prototype.getSourceDimension=function(e){var t=this.source.dimensionsDefine;if(t)return t[e]},r.prototype.makeStoreSchema=function(){for(var e=this._fullDimCount,t=E8(this.source),n=!BF(e),a="",i=[],o=0,s=0;o<e;o++){var l=void 0,u=void 0,c=void 0,f=this.dimensions[s];if(f&&f.storeDimIndex===o)l=t?f.name:null,u=f.type,c=f.ordinalMeta,s++;else{var d=this.getSourceDimension(o);d&&(l=t?d.name:null,u=d.type)}i.push({property:l,type:u,ordinalMeta:c}),t&&l!=null&&(!f||!f.isCalculationCoord)&&(a+=n?l.replace(/\`/g,"`1").replace(/\$/g,"`2"):l),a+="$",a+=kle[u]||"f",c&&(a+=c.uid),a+="$"}var v=this.source,g=[v.seriesLayoutBy,v.startIndex,a].join("$$");return{dimensions:i,hash:g}},r.prototype.makeOutputDimensionNames=function(){for(var e=[],t=0,n=0;t<this._fullDimCount;t++){var a=void 0,i=this.dimensions[n];if(i&&i.storeDimIndex===t)i.isCalculationCoord||(a=i.name),n++;else{var o=this.getSourceDimension(t);o&&(a=o.name)}e.push(a)}return e},r.prototype.appendCalculationDimension=function(e){this.dimensions.push(e),e.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},r})();function PF(r){return r instanceof OF}function jF(r){for(var e=Te(),t=0;t<(r||[]).length;t++){var n=r[t],a=Ee(n)?n.name:n;a!=null&&e.get(a)==null&&e.set(a,t)}return e}function zF(r){var e=Ele(r);return e.dimNameMap||(e.dimNameMap=jF(r.dimensionsDefine))}function BF(r){return r>30}var kv=Ee,Ps=fe,Ile=typeof Int32Array>"u"?Array:Int32Array,Ole="e\0\0",X5=-1,Ple=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],jle=["_approximateExtent"],q5,n0,Iv,Ov,r2,Pv,n2,pn=(function(){function r(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,a=!1;PF(e)?(n=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(a=!0,n=e),n=n||["x","y"];for(var i={},o=[],s={},l=!1,u={},c=0;c<n.length;c++){var f=n[c],d=ye(f)?new ox({name:f}):f instanceof ox?f:new ox(f),v=d.name;d.type=d.type||"float",d.coordDim||(d.coordDim=v,d.coordDimIndex=0);var g=d.otherDims=d.otherDims||{};o.push(v),i[v]=d,u[v]!=null&&(l=!0),d.createInvertedIndices&&(s[v]=[]);var y=c;st(d.storeDimIndex)&&(y=d.storeDimIndex),g.itemName===0&&(this._nameDimIdx=y),g.itemId===0&&(this._idDimIdx=y),a&&(d.storeDimIndex=c)}if(this.dimensions=o,this._dimInfos=i,this._initGetDimensionInfo(l),this.hostModel=t,this._invertedIndicesMap=s,this._dimOmitted){var x=this._dimIdxToName=Te();O(o,function(b){x.set(i[b].storeDimIndex,b)})}}return r.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 a=this._schema.getSourceDimension(t);if(a)return a.name},r.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},r.prototype._recognizeDimIndex=function(e){if(st(e)||e!=null&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(e)<0))return+e},r.prototype._getStoreDimIndex=function(e){var t=this.getDimensionIndex(e);return t},r.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},r.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(n){return t.hasOwnProperty(n)?t[n]:void 0}:function(n){return t[n]}},r.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},r.prototype.mapDimension=function(e,t){var n=this._dimSummary;if(t==null)return n.encodeFirstDimNotExtra[e];var a=n.encode[e];return a?a[t]:null},r.prototype.mapDimensionsAll=function(e){var t=this._dimSummary,n=t.encode[e];return(n||[]).slice()},r.prototype.getStore=function(){return this._store},r.prototype.initData=function(e,t,n){var a=this,i;if(e instanceof QC&&(i=e),!i){var o=this.dimensions,s=WD(e)||tn(e)?new k8(e,o.length):e;i=new QC;var l=Ps(o,function(u){return{type:a._dimInfos[u].type,property:u}});i.initData(s,l,n)}this._store=i,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,i.count()),this._dimSummary=Lle(this,this._schema),this.userOutput=this._dimSummary.userOutput},r.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},r.prototype.appendValues=function(e,t){var n=this._store.appendValues(e,t&&t.length),a=n.start,i=n.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var s=a;s<i;s++){var l=s-a;this._nameList[s]=t[l],o&&n2(this,s)}},r.prototype._updateOrdinalMeta=function(){for(var e=this._store,t=this.dimensions,n=0;n<t.length;n++){var a=this._dimInfos[t[n]];a.ordinalMeta&&e.collectOrdinalMeta(a.storeDimIndex,a.ordinalMeta)}},r.prototype._shouldMakeIdFromName=function(){var e=this._store.getProvider();return this._idDimIdx==null&&e.getSource().sourceFormat!==vl&&!e.fillStorage},r.prototype._doInit=function(e,t){if(!(e>=t)){var n=this._store,a=n.getProvider();this._updateOrdinalMeta();var i=this._nameList,o=this._idList,s=a.getSource().sourceFormat,l=s===la;if(l&&!a.pure)for(var u=[],c=e;c<t;c++){var f=a.getItem(c,u);if(!this.hasItemOption&&ine(f)&&(this.hasItemOption=!0),f){var d=f.name;i[c]==null&&d!=null&&(i[c]=xr(d,null));var v=f.id;o[c]==null&&v!=null&&(o[c]=xr(v,null))}}if(this._shouldMakeIdFromName())for(var c=e;c<t;c++)n2(this,c);q5(this)}},r.prototype.getApproximateExtent=function(e){return this._approximateExtent[e]||this._store.getDataExtent(this._getStoreDimIndex(e))},r.prototype.setApproximateExtent=function(e,t){t=this.getDimension(t),this._approximateExtent[t]=e.slice()},r.prototype.getCalculationInfo=function(e){return this._calculationInfo[e]},r.prototype.setCalculationInfo=function(e,t){kv(e)?ie(this._calculationInfo,e):this._calculationInfo[e]=t},r.prototype.getName=function(e){var t=this.getRawIndex(e),n=this._nameList[t];return n==null&&this._nameDimIdx!=null&&(n=Iv(this,this._nameDimIdx,t)),n==null&&(n=""),n},r.prototype._getCategory=function(e,t){var n=this._store.get(e,t),a=this._store.getOrdinalMeta(e);return a?a.categories[n]:n},r.prototype.getId=function(e){return n0(this,this.getRawIndex(e))},r.prototype.count=function(){return this._store.count()},r.prototype.get=function(e,t){var n=this._store,a=this._dimInfos[e];if(a)return n.get(a.storeDimIndex,t)},r.prototype.getByRawIndex=function(e,t){var n=this._store,a=this._dimInfos[e];if(a)return n.getByRawIndex(a.storeDimIndex,t)},r.prototype.getIndices=function(){return this._store.getIndices()},r.prototype.getDataExtent=function(e){return this._store.getDataExtent(this._getStoreDimIndex(e))},r.prototype.getSum=function(e){return this._store.getSum(this._getStoreDimIndex(e))},r.prototype.getMedian=function(e){return this._store.getMedian(this._getStoreDimIndex(e))},r.prototype.getValues=function(e,t){var n=this,a=this._store;return ce(e)?a.getValues(Ps(e,function(i){return n._getStoreDimIndex(i)}),t):a.getValues(e)},r.prototype.hasValue=function(e){for(var t=this._dimSummary.dataDimIndicesOnCoord,n=0,a=t.length;n<a;n++)if(isNaN(this._store.get(t[n],e)))return!1;return!0},r.prototype.indexOfName=function(e){for(var t=0,n=this._store.count();t<n;t++)if(this.getName(t)===e)return t;return-1},r.prototype.getRawIndex=function(e){return this._store.getRawIndex(e)},r.prototype.indexOfRawIndex=function(e){return this._store.indexOfRawIndex(e)},r.prototype.rawIndexOf=function(e,t){var n=e&&this._invertedIndicesMap[e],a=n&&n[t];return a==null||isNaN(a)?X5:a},r.prototype.each=function(e,t,n){Me(e)&&(n=t,t=e,e=[]);var a=n||this,i=Ps(Ov(e),this._getStoreDimIndex,this);this._store.each(i,a?xe(t,a):t)},r.prototype.filterSelf=function(e,t,n){Me(e)&&(n=t,t=e,e=[]);var a=n||this,i=Ps(Ov(e),this._getStoreDimIndex,this);return this._store=this._store.filter(i,a?xe(t,a):t),this},r.prototype.selectRange=function(e){var t=this,n={},a=it(e);return O(a,function(i){var o=t._getStoreDimIndex(i);n[o]=e[i]}),this._store=this._store.selectRange(n),this},r.prototype.mapArray=function(e,t,n){Me(e)&&(n=t,t=e,e=[]),n=n||this;var a=[];return this.each(e,function(){a.push(t&&t.apply(this,arguments))},n),a},r.prototype.map=function(e,t,n,a){var i=n||a||this,o=Ps(Ov(e),this._getStoreDimIndex,this),s=Pv(this);return s._store=this._store.map(o,i?xe(t,i):t),s},r.prototype.modify=function(e,t,n,a){var i=n||a||this,o=Ps(Ov(e),this._getStoreDimIndex,this);this._store.modify(o,i?xe(t,i):t)},r.prototype.downSample=function(e,t,n,a){var i=Pv(this);return i._store=this._store.downSample(this._getStoreDimIndex(e),t,n,a),i},r.prototype.minmaxDownSample=function(e,t){var n=Pv(this);return n._store=this._store.minmaxDownSample(this._getStoreDimIndex(e),t),n},r.prototype.lttbDownSample=function(e,t){var n=Pv(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(e),t),n},r.prototype.getRawDataItem=function(e){return this._store.getRawDataItem(e)},r.prototype.getItemModel=function(e){var t=this.hostModel,n=this.getRawDataItem(e);return new et(n,t,t&&t.ecModel)},r.prototype.diff=function(e){var t=this;return new Qo(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(n){return n0(e,n)},function(n){return n0(t,n)})},r.prototype.getVisual=function(e){var t=this._visual;return t&&t[e]},r.prototype.setVisual=function(e,t){this._visual=this._visual||{},kv(e)?ie(this._visual,e):this._visual[e]=t},r.prototype.getItemVisual=function(e,t){var n=this._itemVisuals[e],a=n&&n[t];return a??this.getVisual(t)},r.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},r.prototype.ensureUniqueItemVisual=function(e,t){var n=this._itemVisuals,a=n[e];a||(a=n[e]={});var i=a[t];return i==null&&(i=this.getVisual(t),ce(i)?i=i.slice():kv(i)&&(i=ie({},i)),a[t]=i),i},r.prototype.setItemVisual=function(e,t,n){var a=this._itemVisuals[e]||{};this._itemVisuals[e]=a,kv(t)?ie(a,t):a[t]=n},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(e,t){kv(e)?ie(this._layout,e):this._layout[e]=t},r.prototype.getLayout=function(e){return this._layout[e]},r.prototype.getItemLayout=function(e){return this._itemLayouts[e]},r.prototype.setItemLayout=function(e,t,n){this._itemLayouts[e]=n?ie(this._itemLayouts[e]||{},t):t},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(e,t){var n=this.hostModel&&this.hostModel.seriesIndex;OC(n,this.dataType,e,t),this._graphicEls[e]=t},r.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},r.prototype.eachItemGraphicEl=function(e,t){O(this._graphicEls,function(n,a){n&&e&&e.call(t,n,a)})},r.prototype.cloneShallow=function(e){return e||(e=new r(this._schema?this._schema:Ps(this.dimensions,this._getDimInfo,this),this.hostModel)),r2(e,this),e._store=this._store,e},r.prototype.wrapMethod=function(e,t){var n=this[e];Me(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var a=n.apply(this,arguments);return t.apply(this,[a].concat(X1(arguments)))})},r.internalField=(function(){q5=function(e){var t=e._invertedIndicesMap;O(t,function(n,a){var i=e._dimInfos[a],o=i.ordinalMeta,s=e._store;if(o){n=t[a]=new Ile(o.categories.length);for(var l=0;l<n.length;l++)n[l]=X5;for(var l=0;l<s.count();l++)n[s.get(i.storeDimIndex,l)]=l}})},Iv=function(e,t,n){return xr(e._getCategory(t,n),null)},n0=function(e,t){var n=e._idList[t];return n==null&&e._idDimIdx!=null&&(n=Iv(e,e._idDimIdx,t)),n==null&&(n=Ole+t),n},Ov=function(e){return ce(e)||(e=e!=null?[e]:[]),e},Pv=function(e){var t=new r(e._schema?e._schema:Ps(e.dimensions,e._getDimInfo,e),e.hostModel);return r2(t,e),t},r2=function(e,t){O(Ple.concat(t.__wrappedMethods||[]),function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e.__wrappedMethods=t.__wrappedMethods,O(jle,function(n){e[n]=De(t[n])}),e._calculationInfo=ie({},t._calculationInfo)},n2=function(e,t){var n=e._nameList,a=e._idList,i=e._nameDimIdx,o=e._idDimIdx,s=n[t],l=a[t];if(s==null&&i!=null&&(n[t]=s=Iv(e,i,t)),l==null&&o!=null&&(a[t]=l=Iv(e,o,t)),l==null&&s!=null){var u=e._nameRepeatCount,c=u[s]=(u[s]||0)+1;l=s,c>1&&(l+="__ec__"+c),a[t]=l}}})(),r})();function zle(r,e){return hd(r,e).dimensions}function hd(r,e){WD(r)||(r=XD(r)),e=e||{};var t=e.coordDimensions||[],n=e.dimensionsDefine||r.dimensionsDefine||[],a=Te(),i=[],o=Vle(r,t,n,e.dimensionsCount),s=e.canOmitUnusedDimensions&&BF(o),l=n===r.dimensionsDefine,u=l?zF(r):jF(n),c=e.encodeDefine;!c&&e.encodeDefaulter&&(c=e.encodeDefaulter(r,o));for(var f=Te(c),d=new G8(o),v=0;v<d.length;v++)d[v]=-1;function g(E){var k=d[E];if(k<0){var I=n[E],B=Ee(I)?I:{name:I},P=new ox,H=B.name;H!=null&&u.get(H)!=null&&(P.name=P.displayName=H),B.type!=null&&(P.type=B.type),B.displayName!=null&&(P.displayName=B.displayName);var V=i.length;return d[E]=V,P.storeDimIndex=E,i.push(P),P}return i[k]}if(!s)for(var v=0;v<o;v++)g(v);f.each(function(E,k){var I=Lt(E).slice();if(I.length===1&&!ye(I[0])&&I[0]<0){f.set(k,!1);return}var B=f.set(k,[]);O(I,function(P,H){var V=ye(P)?u.get(P):P;V!=null&&V<o&&(B[H]=V,x(g(V),k,H))})});var y=0;O(t,function(E){var k,I,B,P;if(ye(E))k=E,P={};else{P=E,k=P.name;var H=P.ordinalMeta;P.ordinalMeta=null,P=ie({},P),P.ordinalMeta=H,I=P.dimsDef,B=P.otherDims,P.name=P.coordDim=P.coordDimIndex=P.dimsDef=P.otherDims=null}var V=f.get(k);if(V!==!1){if(V=Lt(V),!V.length)for(var j=0;j<(I&&I.length||1);j++){for(;y<o&&g(y).coordDim!=null;)y++;y<o&&V.push(y++)}O(V,function(U,F){var X=g(U);if(l&&P.type!=null&&(X.type=P.type),x(Re(X,P),k,F),X.name==null&&I){var G=I[F];!Ee(G)&&(G={name:G}),X.name=X.displayName=G.name,X.defaultTooltip=G.defaultTooltip}B&&Re(X.otherDims,B)})}});function x(E,k,I){_8.get(k)!=null?E.otherDims[k]=I:(E.coordDim=k,E.coordDimIndex=I,a.set(k,!0))}var b=e.generateCoord,w=e.generateCoordCount,T=w!=null;w=b?w||1:0;var C=b||"value";function D(E){E.name==null&&(E.name=E.coordDim)}if(s)O(i,function(E){D(E)}),i.sort(function(E,k){return E.storeDimIndex-k.storeDimIndex});else for(var M=0;M<o;M++){var N=g(M),R=N.coordDim;R==null&&(N.coordDim=Gle(C,a,T),N.coordDimIndex=0,(!b||w<=0)&&(N.isExtraCoord=!0),w--),D(N),N.type==null&&(C8(r,M)===$r.Must||N.isExtraCoord&&(N.otherDims.itemName!=null||N.otherDims.seriesName!=null))&&(N.type="ordinal")}return Ble(i),new OF({source:r,dimensions:i,fullDimensionCount:o,dimensionOmitted:s})}function Ble(r){for(var e=Te(),t=0;t<r.length;t++){var n=r[t],a=n.name,i=e.get(a)||0;i>0&&(n.name=a+(i-1)),i++,e.set(a,i)}}function Vle(r,e,t,n){var a=Math.max(r.dimensionsDetectedCount||1,e.length,t.length,n||0);return O(e,function(i){var o;Ee(i)&&(o=i.dimsDef)&&(a=Math.max(a,o.length))}),a}function Gle(r,e,t){if(t||e.hasKey(r)){for(var n=0;e.hasKey(r+n);)n++;r+=n}return e.set(r,!0),r}var Hle=(function(){function r(e){this.coordSysDims=[],this.axisMap=Te(),this.categoryAxisMap=Te(),this.coordSysName=e}return r})();function Fle(r){var e=r.get("coordinateSystem"),t=new Hle(e),n=Ule[e];if(n)return n(r,t,t.axisMap,t.categoryAxisMap),t}var Ule={cartesian2d:function(r,e,t,n){var a=r.getReferringComponents("xAxis",Zt).models[0],i=r.getReferringComponents("yAxis",Zt).models[0];e.coordSysDims=["x","y"],t.set("x",a),t.set("y",i),Lf(a)&&(n.set("x",a),e.firstCategoryDimIndex=0),Lf(i)&&(n.set("y",i),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},singleAxis:function(r,e,t,n){var a=r.getReferringComponents("singleAxis",Zt).models[0];e.coordSysDims=["single"],t.set("single",a),Lf(a)&&(n.set("single",a),e.firstCategoryDimIndex=0)},polar:function(r,e,t,n){var a=r.getReferringComponents("polar",Zt).models[0],i=a.findAxisModel("radiusAxis"),o=a.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],t.set("radius",i),t.set("angle",o),Lf(i)&&(n.set("radius",i),e.firstCategoryDimIndex=0),Lf(o)&&(n.set("angle",o),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},geo:function(r,e,t,n){e.coordSysDims=["lng","lat"]},parallel:function(r,e,t,n){var a=r.ecModel,i=a.getComponent("parallel",r.get("parallelIndex")),o=e.coordSysDims=i.dimensions.slice();O(i.parallelAxisIndex,function(s,l){var u=a.getComponent("parallelAxis",s),c=o[l];t.set(c,u),Lf(u)&&(n.set(c,u),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=l))})},matrix:function(r,e,t,n){var a=r.getReferringComponents("matrix",Zt).models[0];e.coordSysDims=["x","y"];var i=a.getDimensionModel("x"),o=a.getDimensionModel("y");t.set("x",i),t.set("y",o),n.set("x",i),n.set("y",o)}};function Lf(r){return r.get("type")==="category"}function VF(r,e,t){t=t||{};var n=t.byIndex,a=t.stackedCoordDimension,i,o,s;Yle(e)?i=e:(o=e.schema,i=o.dimensions,s=e.store);var l=!!(r&&r.get("stack")),u,c,f,d;if(O(i,function(w,T){ye(w)&&(i[T]=w={name:w}),l&&!w.isExtraCoord&&(!n&&!u&&w.ordinalMeta&&(u=w),!c&&w.type!=="ordinal"&&w.type!=="time"&&(!a||a===w.coordDim)&&(c=w))}),c&&!n&&!u&&(n=!0),c){f="__\0ecstackresult_"+r.id,d="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var v=c.coordDim,g=c.type,y=0;O(i,function(w){w.coordDim===v&&y++});var x={name:f,coordDim:v,coordDimIndex:y,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},b={name:d,coordDim:d,coordDimIndex:y+1,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};o?(s&&(x.storeDimIndex=s.ensureCalculationDimension(d,g),b.storeDimIndex=s.ensureCalculationDimension(f,g)),o.appendCalculationDimension(x),o.appendCalculationDimension(b)):(i.push(x),i.push(b))}return{stackedDimension:c&&c.name,stackedByDimension:u&&u.name,isStackedByIndex:n,stackedOverDimension:d,stackResultDimension:f}}function Yle(r){return!PF(r.schema)}function Jo(r,e){return!!e&&e===r.getCalculationInfo("stackedDimension")}function uN(r,e){return Jo(r,e)?r.getCalculationInfo("stackResultDimension"):e}function Wle(r,e){var t=r.get("coordinateSystem"),n=ld.get(t),a;return e&&e.coordSysDims&&(a=fe(e.coordSysDims,function(i){var o={name:i},s=e.axisMap.get(i);if(s){var l=s.get("type");o.type=e1(l)}return o})),a||(a=n&&(n.getDimensionsInfo?n.getDimensionsInfo():n.dimensions.slice())||["x","y"]),a}function Xle(r,e,t){var n,a;return t&&O(r,function(i,o){var s=i.coordDim,l=t.categoryAxisMap.get(s);l&&(n==null&&(n=o),i.ordinalMeta=l.getOrdinalMeta(),e&&(i.createInvertedIndices=!0)),i.otherDims.itemName!=null&&(a=!0)}),!a&&n!=null&&(r[n].otherDims.itemName=0),n}function to(r,e,t){t=t||{};var n=e.getSourceManager(),a,i=!1;r?(i=!0,a=XD(r)):(a=n.getSource(),i=a.sourceFormat===la);var o=Fle(e),s=Wle(e,o),l=t.useEncodeDefaulter,u=Me(l)?l:l?He(T8,s,e):null,c={coordDimensions:s,generateCoord:t.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!i},f=hd(a,c),d=Xle(f.dimensions,t.createInvertedIndices,o),v=i?null:n.getSharedDataStore(f),g=VF(e,{schema:f,store:v}),y=new pn(f,e);y.setCalculationInfo(g);var x=d!=null&&qle(a)?function(b,w,T,C){return C===d?T:this.defaultDimValueGetter(b,w,T,C)}:null;return y.hasItemOption=!1,y.initData(i?a:v,null,x),y}function qle(r){if(r.sourceFormat===la){var e=Zle(r.data||[]);return!ce(Qh(e))}}function Zle(r){for(var e=0;e<r.length&&r[e]==null;)e++;return r[e]}function cA(r){return r.type==="interval"||r.type==="log"}function $le(r,e,t,n,a){var i={},o=i.interval=iD(e/t,!0);n!=null&&o<n&&(o=i.interval=n),a!=null&&o>a&&(o=i.interval=a);var s=i.intervalPrecision=cg(o),l=i.niceTickExtent=[sr(Math.ceil(r[0]/o)*o,s),sr(Math.floor(r[1]/o)*o,s)];return Kle(l,r),i}function a2(r){var e=Math.pow(10,J1(r)),t=r/e;return t?t===2?t=3:t===3?t=5:t*=2:t=1,sr(t*e)}function cg(r){return Ka(r)+2}function Z5(r,e,t){r[e]=Math.max(Math.min(r[e],t[1]),t[0])}function Kle(r,e){!isFinite(r[0])&&(r[0]=e[0]),!isFinite(r[1])&&(r[1]=e[1]),Z5(r,0,e),Z5(r,1,e),r[0]>r[1]&&(r[0]=r[1])}function cN(r,e){return r>=e[0]&&r<=e[1]}var Qle=(function(){function r(){this.normalize=$5,this.scale=K5}return r.prototype.updateMethods=function(e){e.hasBreaks()?(this.normalize=xe(e.normalize,e),this.scale=xe(e.scale,e)):(this.normalize=$5,this.scale=K5)},r})();function $5(r,e){return e[1]===e[0]?.5:(r-e[0])/(e[1]-e[0])}function K5(r,e){return r*(e[1]-e[0])+e[0]}function fA(r,e,t){var n=Math.log(r);return[Math.log(t?e[0]:Math.max(0,e[0]))/n,Math.log(t?e[1]:Math.max(0,e[1]))/n]}var kl=(function(){function r(e){this._calculator=new Qle,this._setting=e||{},this._extent=[1/0,-1/0];var t=dr();t&&(this._brkCtx=t.createScaleBreakContext(),this._brkCtx.update(this._extent))}return r.prototype.getSetting=function(e){return this._setting[e]},r.prototype._innerUnionExtent=function(e){var t=this._extent;this._innerSetExtent(e[0]<t[0]?e[0]:t[0],e[1]>t[1]?e[1]:t[1])},r.prototype.unionExtentFromData=function(e,t){this._innerUnionExtent(e.getApproximateExtent(t))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(e,t){this._innerSetExtent(e,t)},r.prototype._innerSetExtent=function(e,t){var n=this._extent;isNaN(e)||(n[0]=e),isNaN(t)||(n[1]=t),this._brkCtx&&this._brkCtx.update(n)},r.prototype.setBreaksFromOption=function(e){var t=dr();t&&this._innerSetBreak(t.parseAxisBreakOption(e,xe(this.parse,this)))},r.prototype._innerSetBreak=function(e){this._brkCtx&&(this._brkCtx.setBreaks(e),this._calculator.updateMethods(this._brkCtx),this._brkCtx.update(this._extent))},r.prototype._innerGetBreaks=function(){return this._brkCtx?this._brkCtx.breaks:[]},r.prototype.hasBreaks=function(){return this._brkCtx?this._brkCtx.hasBreaks():!1},r.prototype._getExtentSpanWithBreaks=function(){return this._brkCtx&&this._brkCtx.hasBreaks()?this._brkCtx.getExtentSpan():this._extent[1]-this._extent[0]},r.prototype.isInExtentRange=function(e){return this._extent[0]<=e&&this._extent[1]>=e},r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(e){this._isBlank=e},r})();eb(kl);var Jle=0,fg=(function(){function r(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++Jle,this._onCollect=e.onCollect}return r.createByAxisModel=function(e){var t=e.option,n=t.data,a=n&&fe(n,eue);return new r({categories:a,needCollect:!a,deduplication:t.dedplication!==!1})},r.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},r.prototype.parseAndCollect=function(e){var t,n=this._needCollect;if(!ye(e)&&!n)return e;if(n&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,this._onCollect&&this._onCollect(e,t),t;var a=this._getOrCreateMap();return t=a.get(e),t==null&&(n?(t=this.categories.length,this.categories[t]=e,a.set(e,t),this._onCollect&&this._onCollect(e,t)):t=NaN),t},r.prototype._getOrCreateMap=function(){return this._map||(this._map=Te(this.categories))},r})();function eue(r){return Ee(r)&&r.value!=null?r.value:r+""}var Bh=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;n.type="ordinal";var a=n.getSetting("ordinalMeta");return a||(a=new fg({})),ce(a)&&(a=new fg({categories:fe(a,function(i){return Ee(i)?i.value:i})})),n._ordinalMeta=a,n._extent=n.getSetting("extent")||[0,a.categories.length-1],n}return e.prototype.parse=function(t){return t==null?NaN:ye(t)?this._ordinalMeta.getOrdinal(t):Math.round(t)},e.prototype.contain=function(t){return cN(t,this._extent)&&t>=0&&t<this._ordinalMeta.categories.length},e.prototype.normalize=function(t){return t=this._getTickNumber(t),this._calculator.normalize(t,this._extent)},e.prototype.scale=function(t){return t=Math.round(this._calculator.scale(t,this._extent)),this.getRawOrdinalNumber(t)},e.prototype.getTicks=function(){for(var t=[],n=this._extent,a=n[0];a<=n[1];)t.push({value:a}),a++;return t},e.prototype.getMinorTicks=function(t){},e.prototype.setSortInfo=function(t){if(t==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var n=t.ordinalNumbers,a=this._ordinalNumbersByTick=[],i=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,l=Math.min(s,n.length);o<l;++o){var u=n[o];a[o]=u,i[u]=o}for(var c=0;o<s;++o){for(;i[c]!=null;)c++;a.push(c),i[c]=o}},e.prototype._getTickNumber=function(t){var n=this._ticksByOrdinalNumber;return n&&t>=0&&t<n.length?n[t]:t},e.prototype.getRawOrdinalNumber=function(t){var n=this._ordinalNumbersByTick;return n&&t>=0&&t<n.length?n[t]:t},e.prototype.getLabel=function(t){if(!this.isBlank()){var n=this.getRawOrdinalNumber(t.value),a=this._ordinalMeta.categories[n];return a==null?"":a+""}},e.prototype.count=function(){return this._extent[1]-this._extent[0]+1},e.prototype.isInExtentRange=function(t){return t=this._getTickNumber(t),this._extent[0]<=t&&this._extent[1]>=t},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.prototype.calcNiceTicks=function(){},e.prototype.calcNiceExtent=function(){},e.type="ordinal",e})(kl);kl.registerClass(Bh);var js=sr,es=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}return e.prototype.parse=function(t){return t==null||t===""?NaN:Number(t)},e.prototype.contain=function(t){return cN(t,this._extent)},e.prototype.normalize=function(t){return this._calculator.normalize(t,this._extent)},e.prototype.scale=function(t){return this._calculator.scale(t,this._extent)},e.prototype.getInterval=function(){return this._interval},e.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=cg(t)},e.prototype.getTicks=function(t){t=t||{};var n=this._interval,a=this._extent,i=this._niceExtent,o=this._intervalPrecision,s=dr(),l=[];if(!n)return l;if(t.breakTicks==="only_break"&&s)return s.addBreaksToTicks(l,this._brkCtx.breaks,this._extent),l;var u=1e4;a[0]<i[0]&&(t.expandToNicedExtent?l.push({value:js(i[0]-n,o)}):l.push({value:a[0]}));for(var c=function(g,y){return Math.round((y-g)/n)},f=i[0];f<=i[1];){if(l.push({value:f}),f=js(f+n,o),this._brkCtx){var d=this._brkCtx.calcNiceTickMultiple(f,c);d>=0&&(f=js(f+d*n,o))}if(l.length>0&&f===l[l.length-1].value)break;if(l.length>u)return[]}var v=l.length?l[l.length-1].value:i[1];return a[1]>v&&(t.expandToNicedExtent?l.push({value:js(v+n,o)}):l.push({value:a[1]})),s&&s.pruneTicksByBreak(t.pruneByBreak,l,this._brkCtx.breaks,function(g){return g.value},this._interval,this._extent),t.breakTicks!=="none"&&s&&s.addBreaksToTicks(l,this._brkCtx.breaks,this._extent),l},e.prototype.getMinorTicks=function(t){for(var n=this.getTicks({expandToNicedExtent:!0}),a=[],i=this.getExtent(),o=1;o<n.length;o++){var s=n[o],l=n[o-1];if(!(l.break||s.break)){for(var u=0,c=[],f=s.value-l.value,d=f/t,v=cg(d);u<t-1;){var g=js(l.value+(u+1)*d,v);g>i[0]&&g<i[1]&&c.push(g),u++}var y=dr();y&&y.pruneTicksByBreak("auto",c,this._getNonTransBreaks(),function(x){return x},this._interval,i),a.push(c)}}return a},e.prototype._getNonTransBreaks=function(){return this._brkCtx?this._brkCtx.breaks:[]},e.prototype.getLabel=function(t,n){if(t==null)return"";var a=n&&n.precision;a==null?a=Ka(t.value)||0:a==="auto"&&(a=this._intervalPrecision);var i=js(t.value,a,!0);return zD(i)},e.prototype.calcNiceTicks=function(t,n,a){t=t||5;var i=this._extent.slice(),o=this._getExtentSpanWithBreaks();if(isFinite(o)){o<0&&(o=-o,i.reverse(),this._innerSetExtent(i[0],i[1]),i=this._extent.slice());var s=$le(i,o,t,n,a);this._intervalPrecision=s.intervalPrecision,this._interval=s.interval,this._niceExtent=s.niceTickExtent}},e.prototype.calcNiceExtent=function(t){var n=this._extent.slice();if(n[0]===n[1])if(n[0]!==0){var a=Math.abs(n[0]);t.fixMax||(n[1]+=a/2),n[0]-=a/2}else n[1]=1;var i=n[1]-n[0];isFinite(i)||(n[0]=0,n[1]=1),this._innerSetExtent(n[0],n[1]),n=this._extent.slice(),this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval);var o=this._interval,s=this._intervalPrecision;t.fixMin||(n[0]=js(Math.floor(n[0]/o)*o,s)),t.fixMax||(n[1]=js(Math.ceil(n[1]/o)*o,s)),this._innerSetExtent(n[0],n[1])},e.prototype.setNiceExtent=function(t,n){this._niceExtent=[t,n]},e.type="interval",e})(kl);kl.registerClass(es);var GF=typeof Float32Array<"u",tue=GF?Float32Array:Array;function zi(r){return ce(r)?GF?new Float32Array(r):r:new tue(r)}var hA="__ec_stack_";function HF(r){return r.get("stack")||hA+r.seriesIndex}function fN(r){return r.dim+r.index}function rue(r){var e=[],t=r.axis,n="axis0";if(t.type==="category"){for(var a=t.getBandWidth(),i=0;i<r.count;i++)e.push(Re({bandWidth:a,axisKey:n,stackId:hA+i},r));for(var o=YF(e),s=[],i=0;i<r.count;i++){var l=o[n][hA+i];l.offsetCenter=l.offset+l.width/2,s.push(l)}return s}}function FF(r,e){var t=[];return e.eachSeriesByType(r,function(n){qF(n)&&t.push(n)}),t}function nue(r){var e={};O(r,function(l){var u=l.coordinateSystem,c=u.getBaseAxis();if(!(c.type!=="time"&&c.type!=="value"))for(var f=l.getData(),d=c.dim+"_"+c.index,v=f.getDimensionIndex(f.mapDimension(c.dim)),g=f.getStore(),y=0,x=g.count();y<x;++y){var b=g.get(v,y);e[d]?e[d].push(b):e[d]=[b]}});var t={};for(var n in e)if(e.hasOwnProperty(n)){var a=e[n];if(a){a.sort(function(l,u){return l-u});for(var i=null,o=1;o<a.length;++o){var s=a[o]-a[o-1];s>0&&(i=i===null?s:Math.min(i,s))}t[n]=i}}return t}function UF(r){var e=nue(r),t=[];return O(r,function(n){var a=n.coordinateSystem,i=a.getBaseAxis(),o=i.getExtent(),s;if(i.type==="category")s=i.getBandWidth();else if(i.type==="value"||i.type==="time"){var l=i.dim+"_"+i.index,u=e[l],c=Math.abs(o[1]-o[0]),f=i.scale.getExtent(),d=Math.abs(f[1]-f[0]);s=u?c/d*u:c}else{var v=n.getData();s=Math.abs(o[1]-o[0])/v.count()}var g=me(n.get("barWidth"),s),y=me(n.get("barMaxWidth"),s),x=me(n.get("barMinWidth")||(ZF(n)?.5:1),s),b=n.get("barGap"),w=n.get("barCategoryGap"),T=n.get("defaultBarGap");t.push({bandWidth:s,barWidth:g,barMaxWidth:y,barMinWidth:x,barGap:b,barCategoryGap:w,defaultBarGap:T,axisKey:fN(i),stackId:HF(n)})}),YF(t)}function YF(r){var e={};O(r,function(n,a){var i=n.axisKey,o=n.bandWidth,s=e[i]||{bandWidth:o,remainedWidth:o,autoWidthCount:0,categoryGap:null,gap:n.defaultBarGap||0,stacks:{}},l=s.stacks;e[i]=s;var u=n.stackId;l[u]||s.autoWidthCount++,l[u]=l[u]||{width:0,maxWidth:0};var c=n.barWidth;c&&!l[u].width&&(l[u].width=c,c=Math.min(s.remainedWidth,c),s.remainedWidth-=c);var f=n.barMaxWidth;f&&(l[u].maxWidth=f);var d=n.barMinWidth;d&&(l[u].minWidth=d);var v=n.barGap;v!=null&&(s.gap=v);var g=n.barCategoryGap;g!=null&&(s.categoryGap=g)});var t={};return O(e,function(n,a){t[a]={};var i=n.stacks,o=n.bandWidth,s=n.categoryGap;if(s==null){var l=it(i).length;s=Math.max(35-l*4,15)+"%"}var u=me(s,o),c=me(n.gap,1),f=n.remainedWidth,d=n.autoWidthCount,v=(f-u)/(d+(d-1)*c);v=Math.max(v,0),O(i,function(b){var w=b.maxWidth,T=b.minWidth;if(b.width){var C=b.width;w&&(C=Math.min(C,w)),T&&(C=Math.max(C,T)),b.width=C,f-=C+c*C,d--}else{var C=v;w&&w<C&&(C=Math.min(w,f)),T&&T>C&&(C=T),C!==v&&(b.width=C,f-=C+c*C,d--)}}),v=(f-u)/(d+(d-1)*c),v=Math.max(v,0);var g=0,y;O(i,function(b,w){b.width||(b.width=v),y=b,g+=b.width*(1+c)}),y&&(g-=y.width*c);var x=-g/2;O(i,function(b,w){t[a][w]=t[a][w]||{bandWidth:o,offset:x,width:b.width},x+=b.width*(1+c)})}),t}function aue(r,e,t){if(r&&e){var n=r[fN(e)];return n}}function WF(r,e){var t=FF(r,e),n=UF(t);O(t,function(a){var i=a.getData(),o=a.coordinateSystem,s=o.getBaseAxis(),l=HF(a),u=n[fN(s)][l],c=u.offset,f=u.width;i.setLayout({bandWidth:u.bandWidth,offset:c,size:f})})}function XF(r){return{seriesType:r,plan:ud(),reset:function(e){if(qF(e)){var t=e.getData(),n=e.coordinateSystem,a=n.getBaseAxis(),i=n.getOtherAxis(a),o=t.getDimensionIndex(t.mapDimension(i.dim)),s=t.getDimensionIndex(t.mapDimension(a.dim)),l=e.get("showBackground",!0),u=t.mapDimension(i.dim),c=t.getCalculationInfo("stackResultDimension"),f=Jo(t,u)&&!!t.getCalculationInfo("stackedOnSeries"),d=i.isHorizontal(),v=iue(a,i),g=ZF(e),y=e.get("barMinHeight")||0,x=c&&t.getDimensionIndex(c),b=t.getLayout("size"),w=t.getLayout("offset");return{progress:function(T,C){for(var D=T.count,M=g&&zi(D*3),N=g&&l&&zi(D*3),R=g&&zi(D),E=n.master.getRect(),k=d?E.width:E.height,I,B=C.getStore(),P=0;(I=T.next())!=null;){var H=B.get(f?x:o,I),V=B.get(s,I),j=v,U=void 0;f&&(U=+H-B.get(o,I));var F=void 0,X=void 0,G=void 0,W=void 0;if(d){var $=n.dataToPoint([H,V]);if(f){var te=n.dataToPoint([U,V]);j=te[0]}F=j,X=$[1]+w,G=$[0]-j,W=b,Math.abs(G)<y&&(G=(G<0?-1:1)*y)}else{var $=n.dataToPoint([V,H]);if(f){var te=n.dataToPoint([V,U]);j=te[1]}F=$[0]+w,X=j,G=b,W=$[1]-j,Math.abs(W)<y&&(W=(W<=0?-1:1)*y)}g?(M[P]=F,M[P+1]=X,M[P+2]=d?G:W,N&&(N[P]=d?E.x:F,N[P+1]=d?X:E.y,N[P+2]=k),R[I]=I):C.setItemLayout(I,{x:F,y:X,width:G,height:W}),P+=3}g&&C.setLayout({largePoints:M,largeDataIndices:R,largeBackgroundPoints:N,valueAxisHorizontal:d})}}}}}}function qF(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function ZF(r){return r.pipelineContext&&r.pipelineContext.large}function iue(r,e){var t=e.model.get("startValue");return t||(t=0),e.toGlobalCoord(e.dataToCoord(e.type==="log"?t>0?t:1:t))}var oue=function(r,e,t,n){for(;t<n;){var a=t+n>>>1;r[a][1]<e?t=a+1:n=a}return t},hN=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="time",n}return e.prototype.getLabel=function(t){var n=this.getSetting("useUTC");return Zg(t.value,HP[Nie(kp(this._minLevelUnit))]||HP.second,n,this.getSetting("locale"))},e.prototype.getFormattedLabel=function(t,n,a){var i=this.getSetting("useUTC"),o=this.getSetting("locale");return Lie(t,n,a,o,i)},e.prototype.getTicks=function(t){t=t||{};var n=this._interval,a=this._extent,i=dr(),o=[];if(!n)return o;var s=this.getSetting("useUTC");if(i&&t.breakTicks==="only_break")return dr().addBreaksToTicks(o,this._brkCtx.breaks,this._extent),o;var l=rh(a[1],s);o.push({value:a[0],time:{level:0,upperTimeUnit:l,lowerTimeUnit:l}});var u=due(this._minLevelUnit,this._approxInterval,s,a,this._getExtentSpanWithBreaks(),this._brkCtx);o=o.concat(u);var c=rh(a[1],s);o.push({value:a[1],time:{level:0,upperTimeUnit:c,lowerTimeUnit:c}});var f=this.getSetting("useUTC"),d=$n.length-1,v=0;return O(o,function(g){d=Math.min(d,Fe($n,g.time.upperTimeUnit)),v=Math.max(v,g.time.level)}),i&&dr().pruneTicksByBreak(t.pruneByBreak,o,this._brkCtx.breaks,function(g){return g.value},this._approxInterval,this._extent),i&&t.breakTicks!=="none"&&dr().addBreaksToTicks(o,this._brkCtx.breaks,this._extent,function(g){for(var y=Math.max(Fe($n,rh(g.vmin,f)),Fe($n,rh(g.vmax,f))),x=0,b=0;b<$n.length;b++)if(!$F($n[b],g.vmin,g.vmax,f)){x=b;break}var w=Math.min(x,d),T=Math.max(w,y);return{level:v,lowerTimeUnit:$n[T],upperTimeUnit:$n[w]}}),o},e.prototype.calcNiceExtent=function(t){var n=this.getExtent();if(n[0]===n[1]&&(n[0]-=Ra,n[1]+=Ra),n[1]===-1/0&&n[0]===1/0){var a=new Date;n[1]=+new Date(a.getFullYear(),a.getMonth(),a.getDate()),n[0]=n[1]-Ra}this._innerSetExtent(n[0],n[1]),this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval)},e.prototype.calcNiceTicks=function(t,n,a){t=t||10;var i=this._getExtentSpanWithBreaks();this._approxInterval=i/t,n!=null&&this._approxInterval<n&&(this._approxInterval=n),a!=null&&this._approxInterval>a&&(this._approxInterval=a);var o=a0.length,s=Math.min(oue(a0,this._approxInterval,0,o),o-1);this._interval=a0[s][1],this._intervalPrecision=cg(this._interval),this._minLevelUnit=a0[Math.max(s-1,0)][0]},e.prototype.parse=function(t){return st(t)?t:+Ji(t)},e.prototype.contain=function(t){return cN(t,this._extent)},e.prototype.normalize=function(t){return this._calculator.normalize(t,this._extent)},e.prototype.scale=function(t){return this._calculator.scale(t,this._extent)},e.type="time",e})(es),a0=[["second",LD],["minute",RD],["hour",Ep],["quarter-day",Ep*6],["half-day",Ep*12],["day",Ra*1.2],["half-week",Ra*3.5],["week",Ra*7],["month",Ra*31],["quarter",Ra*95],["half-year",GP/2],["year",GP]];function $F(r,e,t,n){return Fx(new Date(e),r,n).getTime()===Fx(new Date(t),r,n).getTime()}function sue(r,e){return r/=Ra,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function lue(r){var e=30*Ra;return r/=e,r>6?6:r>3?3:r>2?2:1}function uue(r){return r/=Ep,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function Q5(r,e){return r/=e?RD:LD,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function cue(r){return iD(r,!0)}function fue(r,e,t){var n=Math.max(0,Fe($n,e)-1);return Fx(new Date(r),$n[n],t).getTime()}function hue(r,e){var t=new Date(0);t[r](1);var n=t.getTime();t[r](1+e);var a=t.getTime()-n;return function(i,o){return Math.max(0,Math.round((o-i)/a))}}function due(r,e,t,n,a,i){var o=1e4,s=Cie,l=0;function u(P,H,V,j,U,F,X){for(var G=hue(U,P),W=H,$=new Date(W);W<V&&W<=n[1]&&(X.push({value:W}),!(l++>o));)if($[U]($[j]()+P),W=$.getTime(),i){var te=i.calcNiceTickMultiple(W,G);te>0&&($[U]($[j]()+te*P),W=$.getTime())}X.push({value:W,notAdd:!0})}function c(P,H,V){var j=[],U=!H.length;if(!$F(kp(P),n[0],n[1],t)){U&&(H=[{value:fue(n[0],P,t)},{value:n[1]}]);for(var F=0;F<H.length-1;F++){var X=H[F].value,G=H[F+1].value;if(X!==G){var W=void 0,$=void 0,te=void 0,ue=!1;switch(P){case"year":W=Math.max(1,Math.round(e/Ra/365)),$=n8(t),te=Rie(t);break;case"half-year":case"quarter":case"month":W=lue(e),$=ED(t),te=a8(t);break;case"week":case"half-week":case"day":W=sue(e),$=kD(t),te=i8(t),ue=!0;break;case"half-day":case"quarter-day":case"hour":W=uue(e),$=ID(t),te=o8(t);break;case"minute":W=Q5(e,!0),$=OD(t),te=s8(t);break;case"second":W=Q5(e,!1),$=PD(t),te=l8(t);break;case"millisecond":W=cue(e),$=jD(t),te=u8(t);break}G>=n[0]&&X<=n[1]&&u(W,X,G,$,te,ue,j),P==="year"&&V.length>1&&F===0&&V.unshift({value:V[0].value-W})}}for(var F=0;F<j.length;F++)V.push(j[F])}}for(var f=[],d=[],v=0,g=0,y=0;y<s.length;++y){var x=kp(s[y]);if(Die(s[y])){c(s[y],f[f.length-1]||[],d);var b=s[y+1]?kp(s[y+1]):null;if(x!==b){if(d.length){g=v,d.sort(function(P,H){return P.value-H.value});for(var w=[],T=0;T<d.length;++T){var C=d[T].value;(T===0||d[T-1].value!==C)&&(w.push(d[T]),C>=n[0]&&C<=n[1]&&v++)}var D=a/e;if(v>D*1.5&&g>D/1.5||(f.push(w),v>D||r===s[y]))break}d=[]}}}for(var M=dt(fe(f,function(P){return dt(P,function(H){return H.value>=n[0]&&H.value<=n[1]&&!H.notAdd})}),function(P){return P.length>0}),N=[],R=M.length-1,y=0;y<M.length;++y)for(var E=M[y],k=0;k<E.length;++k){var I=rh(E[k].value,t);N.push({value:E[k].value,time:{level:R-y,upperTimeUnit:I,lowerTimeUnit:I}})}N.sort(function(P,H){return P.value-H.value});for(var B=[],y=0;y<N.length;++y)(y===0||N[y].value!==N[y-1].value)&&B.push(N[y]);return B}kl.registerClass(hN);var dA=sr,vue=Math.floor,pue=Math.ceil,i0=Math.pow,o0=Math.log,KF=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new es,t}return e.prototype.getTicks=function(t){t=t||{};var n=this._extent.slice(),a=this._originalScale.getExtent(),i=r.prototype.getTicks.call(this,t),o=this.base,s=this._originalScale._innerGetBreaks(),l=dr();return fe(i,function(u){var c=u.value,f=null,d=i0(o,c);c===n[0]&&this._fixMin?f=a[0]:c===n[1]&&this._fixMax&&(f=a[1]);var v;if(l){var g=l.getTicksLogTransformBreak(u,o,s,s0);v=g.vBreak,f==null&&(f=g.brkRoundingCriterion)}return f!=null&&(d=s0(d,f)),{value:d,break:v}},this)},e.prototype._getNonTransBreaks=function(){return this._originalScale._innerGetBreaks()},e.prototype.setExtent=function(t,n){this._originalScale.setExtent(t,n);var a=fA(this.base,[t,n]);r.prototype.setExtent.call(this,a[0],a[1])},e.prototype.getExtent=function(){var t=this.base,n=r.prototype.getExtent.call(this);n[0]=i0(t,n[0]),n[1]=i0(t,n[1]);var a=this._originalScale.getExtent();return this._fixMin&&(n[0]=s0(n[0],a[0])),this._fixMax&&(n[1]=s0(n[1],a[1])),n},e.prototype.unionExtentFromData=function(t,n){this._originalScale.unionExtentFromData(t,n);var a=fA(this.base,t.getApproximateExtent(n),!0);this._innerUnionExtent(a)},e.prototype.calcNiceTicks=function(t){t=t||10;var n=this._extent.slice(),a=this._getExtentSpanWithBreaks();if(!(!isFinite(a)||a<=0)){var i=rH(a),o=t/a*i;for(o<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var s=[dA(pue(n[0]/i)*i),dA(vue(n[1]/i)*i)];this._interval=i,this._intervalPrecision=cg(i),this._niceExtent=s}},e.prototype.calcNiceExtent=function(t){r.prototype.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},e.prototype.contain=function(t){return t=o0(t)/o0(this.base),r.prototype.contain.call(this,t)},e.prototype.normalize=function(t){return t=o0(t)/o0(this.base),r.prototype.normalize.call(this,t)},e.prototype.scale=function(t){return t=r.prototype.scale.call(this,t),i0(this.base,t)},e.prototype.setBreaksFromOption=function(t){var n=dr();if(n){var a=n.logarithmicParseBreaksFromOption(t,this.base,xe(this.parse,this)),i=a.parsedOriginal,o=a.parsedLogged;this._originalScale._innerSetBreak(i),this._innerSetBreak(o)}},e.type="log",e})(es);function s0(r,e){return dA(r,Ka(e))}kl.registerClass(KF);var gue=(function(){function r(e,t,n){this._prepareParams(e,t,n)}return r.prototype._prepareParams=function(e,t,n){n[1]<n[0]&&(n=[NaN,NaN]),this._dataMin=n[0],this._dataMax=n[1];var a=this._isOrdinal=e.type==="ordinal";this._needCrossZero=e.type==="interval"&&t.getNeedCrossZero&&t.getNeedCrossZero();var i=t.get("min",!0);i==null&&(i=t.get("startValue",!0));var o=this._modelMinRaw=i;Me(o)?this._modelMinNum=l0(e,o({min:n[0],max:n[1]})):o!=="dataMin"&&(this._modelMinNum=l0(e,o));var s=this._modelMaxRaw=t.get("max",!0);if(Me(s)?this._modelMaxNum=l0(e,s({min:n[0],max:n[1]})):s!=="dataMax"&&(this._modelMaxNum=l0(e,s)),a)this._axisDataLen=t.getCategories().length;else{var l=t.get("boundaryGap"),u=ce(l)?l:[l||0,l||0];typeof u[0]=="boolean"||typeof u[1]=="boolean"?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[oi(u[0],1),oi(u[1],1)]}},r.prototype.calculate=function(){var e=this._isOrdinal,t=this._dataMin,n=this._dataMax,a=this._axisDataLen,i=this._boundaryGapInner,o=e?null:n-t||Math.abs(t),s=this._modelMinRaw==="dataMin"?t:this._modelMinNum,l=this._modelMaxRaw==="dataMax"?n:this._modelMaxNum,u=s!=null,c=l!=null;s==null&&(s=e?a?0:NaN:t-i[0]*o),l==null&&(l=e?a?a-1:NaN:n+i[1]*o),(s==null||!isFinite(s))&&(s=NaN),(l==null||!isFinite(l))&&(l=NaN);var f=en(s)||en(l)||e&&!a;this._needCrossZero&&(s>0&&l>0&&!u&&(s=0),s<0&&l<0&&!c&&(l=0));var d=this._determinedMin,v=this._determinedMax;return d!=null&&(s=d,u=!0),v!=null&&(l=v,c=!0),{min:s,max:l,minFixed:u,maxFixed:c,isBlank:f}},r.prototype.modifyDataMinMax=function(e,t){this[yue[e]]=t},r.prototype.setDeterminedMinMax=function(e,t){var n=mue[e];this[n]=t},r.prototype.freeze=function(){this.frozen=!0},r})(),mue={min:"_determinedMin",max:"_determinedMax"},yue={min:"_dataMin",max:"_dataMax"};function QF(r,e,t){var n=r.rawExtentInfo;return n||(n=new gue(r,e,t),r.rawExtentInfo=n,n)}function l0(r,e){return e==null?null:en(e)?NaN:r.parse(e)}function JF(r,e){var t=r.type,n=QF(r,e,r.getExtent()).calculate();r.setBlank(n.isBlank);var a=n.min,i=n.max,o=e.ecModel;if(o&&t==="time"){var s=FF("bar",o),l=!1;if(O(s,function(f){l=l||f.getBaseAxis()===e.axis}),l){var u=UF(s),c=xue(a,i,e,u);a=c.min,i=c.max}}return{extent:[a,i],fixMin:n.minFixed,fixMax:n.maxFixed}}function xue(r,e,t,n){var a=t.axis.getExtent(),i=Math.abs(a[1]-a[0]),o=aue(n,t.axis);if(o===void 0)return{min:r,max:e};var s=1/0;O(o,function(v){s=Math.min(v.offset,s)});var l=-1/0;O(o,function(v){l=Math.max(v.offset+v.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,c=e-r,f=1-(s+l)/i,d=c/f-c;return e+=d*(l/u),r-=d*(s/u),{min:r,max:e}}function pc(r,e){var t=e,n=JF(r,t),a=n.extent,i=t.get("splitNumber");r instanceof KF&&(r.base=t.get("logBase"));var o=r.type,s=t.get("interval"),l=o==="interval"||o==="time";r.setBreaksFromOption(t7(t)),r.setExtent(a[0],a[1]),r.calcNiceExtent({splitNumber:i,fixMin:n.fixMin,fixMax:n.fixMax,minInterval:l?t.get("minInterval"):null,maxInterval:l?t.get("maxInterval"):null}),s!=null&&r.setInterval&&r.setInterval(s)}function Qg(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new Bh({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new hN({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(kl.getClass(e)||es)}}function bue(r){var e=r.scale.getExtent(),t=e[0],n=e[1];return!(t>0&&n>0||t<0&&n<0)}function dd(r){var e=r.getLabelModel().get("formatter");if(r.type==="time"){var t=Aie(e);return function(a,i){return r.scale.getFormattedLabel(a,i,t)}}else{if(ye(e))return function(a){var i=r.scale.getLabel(a),o=e.replace("{value}",i??"");return o};if(Me(e)){if(r.type==="category")return function(a,i){return e(t1(r,a),a.value-r.scale.getExtent()[0],null)};var n=dr();return function(a,i){var o=null;return n&&(o=n.makeAxisLabelFormatterParamBreak(o,a.break)),e(t1(r,a),i,o)}}else return function(a){return r.scale.getLabel(a)}}}function t1(r,e){return r.type==="category"?r.scale.getLabel(e):e.value}function dN(r){var e=r.get("interval");return e??"auto"}function e7(r){return r.type==="category"&&dN(r.getLabelModel())===0}function r1(r,e){var t={};return O(r.mapDimensionsAll(e),function(n){t[uN(r,n)]=!0}),it(t)}function _ue(r,e,t){e&&O(r1(e,t),function(n){var a=e.getApproximateExtent(n);a[0]<r[0]&&(r[0]=a[0]),a[1]>r[1]&&(r[1]=a[1])})}function Vh(r){return r==="middle"||r==="center"}function hg(r){return r.getShallow("show")}function t7(r){var e=r.get("breaks",!0);if(e!=null)return!dr()||!Sue(r.axis)?void 0:e}function Sue(r){return(r.dim==="x"||r.dim==="y"||r.dim==="z"||r.dim==="single")&&r.type!=="category"}var vd=(function(){function r(){}return r.prototype.getNeedCrossZero=function(){var e=this.option;return!e.scale},r.prototype.getCoordSysModel=function(){},r})();function wue(r){return to(null,r)}var Tue={isDimensionStacked:Jo,enableDataStack:VF,getStackedDimension:uN};function Cue(r,e){var t=e;e instanceof et||(t=new et(e));var n=Qg(t);return n.setExtent(r[0],r[1]),pc(n,t),n}function Aue(r){Jt(r,vd)}function Mue(r,e){return e=e||{},Nt(r,null,null,e.state!=="normal")}const Due=Object.freeze(Object.defineProperty({__proto__:null,createDimensions:zle,createList:wue,createScale:Cue,createSymbol:ur,createTextStyle:Mue,dataStack:Tue,enableHoverEmphasis:hl,getECData:je,getLayoutRect:Ht,mixinAxisModelCommonMethods:Aue},Symbol.toStringTag,{value:"Module"}));var Nue=1e-8;function J5(r,e){return Math.abs(r-e)<Nue}function Eu(r,e,t){var n=0,a=r[0];if(!a)return!1;for(var i=1;i<r.length;i++){var o=r[i];n+=No(a[0],a[1],o[0],o[1],e,t),a=o}var s=r[0];return(!J5(a[0],s[0])||!J5(a[1],s[1]))&&(n+=No(a[0],a[1],s[0],s[1],e,t)),n!==0}var Lue=[];function i2(r,e){for(var t=0;t<r.length;t++)Qt(r[t],r[t],e)}function e3(r,e,t,n){for(var a=0;a<r.length;a++){var i=r[a];n&&(i=n.project(i)),i&&isFinite(i[0])&&isFinite(i[1])&&(Oo(e,e,i),Po(t,t,i))}}function Rue(r){for(var e=0,t=0,n=0,a=r.length,i=r[a-1][0],o=r[a-1][1],s=0;s<a;s++){var l=r[s][0],u=r[s][1],c=i*u-l*o;e+=c,t+=(i+l)*c,n+=(o+u)*c,i=l,o=u}return e?[t/e/3,n/e/3,e]:[r[0][0]||0,r[0][1]||0]}var r7=(function(){function r(e){this.name=e}return r.prototype.setCenter=function(e){this._center=e},r.prototype.getCenter=function(){var e=this._center;return e||(e=this._center=this.calcCenter()),e},r})(),t3=(function(){function r(e,t){this.type="polygon",this.exterior=e,this.interiors=t}return r})(),r3=(function(){function r(e){this.type="linestring",this.points=e}return r})(),n7=(function(r){K(e,r);function e(t,n,a){var i=r.call(this,t)||this;return i.type="geoJSON",i.geometries=n,i._center=a&&[a[0],a[1]],i}return e.prototype.calcCenter=function(){for(var t=this.geometries,n,a=0,i=0;i<t.length;i++){var o=t[i],s=o.exterior,l=s&&s.length;l>a&&(n=o,a=l)}if(n)return Rue(n.exterior);var u=this.getBoundingRect();return[u.x+u.width/2,u.y+u.height/2]},e.prototype.getBoundingRect=function(t){var n=this._rect;if(n&&!t)return n;var a=[1/0,1/0],i=[-1/0,-1/0],o=this.geometries;return O(o,function(s){s.type==="polygon"?e3(s.exterior,a,i,t):O(s.points,function(l){e3(l,a,i,t)})}),isFinite(a[0])&&isFinite(a[1])&&isFinite(i[0])&&isFinite(i[1])||(a[0]=a[1]=i[0]=i[1]=0),n=new Oe(a[0],a[1],i[0]-a[0],i[1]-a[1]),t||(this._rect=n),n},e.prototype.contain=function(t){var n=this.getBoundingRect(),a=this.geometries;if(!n.contain(t[0],t[1]))return!1;e:for(var i=0,o=a.length;i<o;i++){var s=a[i];if(s.type==="polygon"){var l=s.exterior,u=s.interiors;if(Eu(l,t[0],t[1])){for(var c=0;c<(u?u.length:0);c++)if(Eu(u[c],t[0],t[1]))continue e;return!0}}}return!1},e.prototype.transformTo=function(t,n,a,i){var o=this.getBoundingRect(),s=o.width/o.height;a?i||(i=a/s):a=s*i;for(var l=new Oe(t,n,a,i),u=o.calculateTransform(l),c=this.geometries,f=0;f<c.length;f++){var d=c[f];d.type==="polygon"?(i2(d.exterior,u),O(d.interiors,function(v){i2(v,u)})):O(d.points,function(v){i2(v,u)})}o=this._rect,o.copy(l),this._center=[o.x+o.width/2,o.y+o.height/2]},e.prototype.cloneShallow=function(t){t==null&&(t=this.name);var n=new e(t,this.geometries,this._center);return n._rect=this._rect,n.transformTo=null,n},e})(r7),Eue=(function(r){K(e,r);function e(t,n){var a=r.call(this,t)||this;return a.type="geoSVG",a._elOnlyForCalculate=n,a}return e.prototype.calcCenter=function(){for(var t=this._elOnlyForCalculate,n=t.getBoundingRect(),a=[n.x+n.width/2,n.y+n.height/2],i=Gg(Lue),o=t;o&&!o.isGeoSVGGraphicRoot;)Ja(i,o.getLocalTransform(),i),o=o.parent;return Oa(i,i),Qt(a,a,i),a},e})(r7);function kue(r){if(!r.UTF8Encoding)return r;var e=r,t=e.UTF8Scale;t==null&&(t=1024);var n=e.features;return O(n,function(a){var i=a.geometry,o=i.encodeOffsets,s=i.coordinates;if(o)switch(i.type){case"LineString":i.coordinates=a7(s,o,t);break;case"Polygon":o2(s,o,t);break;case"MultiLineString":o2(s,o,t);break;case"MultiPolygon":O(s,function(l,u){return o2(l,o[u],t)})}}),e.UTF8Encoding=!1,e}function o2(r,e,t){for(var n=0;n<r.length;n++)r[n]=a7(r[n],e[n],t)}function a7(r,e,t){for(var n=[],a=e[0],i=e[1],o=0;o<r.length;o+=2){var s=r.charCodeAt(o)-64,l=r.charCodeAt(o+1)-64;s=s>>1^-(s&1),l=l>>1^-(l&1),s+=a,l+=i,a=s,i=l,n.push([s/t,l/t])}return n}function vA(r,e){return r=kue(r),fe(dt(r.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var n=t.properties,a=t.geometry,i=[];switch(a.type){case"Polygon":var o=a.coordinates;i.push(new t3(o[0],o.slice(1)));break;case"MultiPolygon":O(a.coordinates,function(l){l[0]&&i.push(new t3(l[0],l.slice(1)))});break;case"LineString":i.push(new r3([a.coordinates]));break;case"MultiLineString":i.push(new r3(a.coordinates))}var s=new n7(n[e||"name"],i,n.cp);return s.properties=n,s})}const Iue=Object.freeze(Object.defineProperty({__proto__:null,MAX_SAFE_INTEGER:DC,asc:na,getPercentWithPrecision:Jre,getPixelPrecision:nD,getPrecision:Ka,getPrecisionSafe:eH,isNumeric:oD,isRadianAroundZero:kh,linearMap:pt,nice:iD,numericToNumber:Xi,parseDate:Ji,parsePercent:me,quantile:Q0,quantity:rH,quantityExponent:J1,reformIntervals:NC,remRadian:aD,round:sr},Symbol.toStringTag,{value:"Module"})),Oue=Object.freeze(Object.defineProperty({__proto__:null,format:Zg,parse:Ji,roundTime:Fx},Symbol.toStringTag,{value:"Module"})),Pue=Object.freeze(Object.defineProperty({__proto__:null,Arc:Wg,BezierCurve:rd,BoundingRect:Oe,Circle:eo,CompoundPath:Xg,Ellipse:Yg,Group:Ne,Image:Ir,IncrementalDisplayable:HH,Line:lr,LinearGradient:bc,Polygon:an,Polyline:Ur,RadialGradient:xD,Rect:qe,Ring:td,Sector:nn,Text:ot,clipPointsByRect:wD,clipRectByRect:XH,createIcon:ad,extendPath:YH,extendShape:UH,getShapeClass:ng,getTransform:dl,initProps:zt,makeImage:_D,makePath:Oh,mergePath:ta,registerShape:Ba,resizePath:SD,updateProps:lt},Symbol.toStringTag,{value:"Module"})),jue=Object.freeze(Object.defineProperty({__proto__:null,addCommas:zD,capitalFirst:Oie,encodeHTML:dn,formatTime:Iie,formatTpl:VD,getTextRect:Eie,getTooltipMarker:c8,normalizeCssArray:sd,toCamelCase:BD,truncateText:Ene},Symbol.toStringTag,{value:"Module"})),zue=Object.freeze(Object.defineProperty({__proto__:null,bind:xe,clone:De,curry:He,defaults:Re,each:O,extend:ie,filter:dt,indexOf:Fe,inherits:ZM,isArray:ce,isFunction:Me,isObject:Ee,isString:ye,map:fe,merge:Ye,reduce:Ia},Symbol.toStringTag,{value:"Module"}));var Bue=Je(),Op=Je(),si={estimate:1,determine:2};function n1(r){return{out:{noPxChangeTryDetermine:[]},kind:r}}function i7(r,e){var t=fe(e,function(n){return r.scale.parse(n)});return r.type==="time"&&t.length>0&&(t.sort(),t.unshift(t[0]),t.push(t[t.length-1])),t}function Vue(r,e){var t=r.getLabelModel().get("customValues");if(t){var n=dd(r),a=r.scale.getExtent(),i=i7(r,t),o=dt(i,function(s){return s>=a[0]&&s<=a[1]});return{labels:fe(o,function(s){var l={value:s};return{formattedLabel:n(l),rawLabel:r.scale.getLabel(l),tickValue:s,time:void 0,break:void 0}})}}return r.type==="category"?Hue(r,e):Uue(r)}function Gue(r,e,t){var n=r.getTickModel().get("customValues");if(n){var a=r.scale.getExtent(),i=i7(r,n);return{ticks:dt(i,function(o){return o>=a[0]&&o<=a[1]})}}return r.type==="category"?Fue(r,e):{ticks:fe(r.scale.getTicks(t),function(o){return o.value})}}function Hue(r,e){var t=r.getLabelModel(),n=o7(r,t,e);return!t.get("show")||r.scale.isBlank()?{labels:[]}:n}function o7(r,e,t){var n=Wue(r),a=dN(e),i=t.kind===si.estimate;if(!i){var o=l7(n,a);if(o)return o}var s,l;Me(a)?s=f7(r,a):(l=a==="auto"?Xue(r,t):a,s=c7(r,l));var u={labels:s,labelCategoryInterval:l};return i?t.out.noPxChangeTryDetermine.push(function(){return pA(n,a,u),!0}):pA(n,a,u),u}function Fue(r,e){var t=Yue(r),n=dN(e),a=l7(t,n);if(a)return a;var i,o;if((!e.get("show")||r.scale.isBlank())&&(i=[]),Me(n))i=f7(r,n,!0);else if(n==="auto"){var s=o7(r,r.getLabelModel(),n1(si.determine));o=s.labelCategoryInterval,i=fe(s.labels,function(l){return l.tickValue})}else o=n,i=c7(r,o,!0);return pA(t,n,{ticks:i,tickCategoryInterval:o})}function Uue(r){var e=r.scale.getTicks(),t=dd(r);return{labels:fe(e,function(n,a){return{formattedLabel:t(n,a),rawLabel:r.scale.getLabel(n),tickValue:n.value,time:n.time,break:n.break}})}}var Yue=s7("axisTick"),Wue=s7("axisLabel");function s7(r){return function(t){return Op(t)[r]||(Op(t)[r]={list:[]})}}function l7(r,e){for(var t=0;t<r.list.length;t++)if(r.list[t].key===e)return r.list[t].value}function pA(r,e,t){return r.list.push({key:e,value:t}),t}function Xue(r,e){if(e.kind===si.estimate){var t=r.calculateCategoryInterval(e);return e.out.noPxChangeTryDetermine.push(function(){return Op(r).autoInterval=t,!0}),t}var n=Op(r).autoInterval;return n??(Op(r).autoInterval=r.calculateCategoryInterval(e))}function que(r,e){var t=e.kind,n=$ue(r),a=dd(r),i=(n.axisRotate-n.labelRotate)/180*Math.PI,o=r.scale,s=o.getExtent(),l=o.count();if(s[1]-s[0]<1)return 0;var u=1,c=40;l>c&&(u=Math.max(1,Math.floor(l/c)));for(var f=s[0],d=r.dataToCoord(f+1)-r.dataToCoord(f),v=Math.abs(d*Math.cos(i)),g=Math.abs(d*Math.sin(i)),y=0,x=0;f<=s[1];f+=u){var b=0,w=0,T=K1(a({value:f}),n.font,"center","top");b=T.width*1.3,w=T.height*1.3,y=Math.max(y,b,7),x=Math.max(x,w,7)}var C=y/v,D=x/g;isNaN(C)&&(C=1/0),isNaN(D)&&(D=1/0);var M=Math.max(0,Math.floor(Math.min(C,D)));if(t===si.estimate)return e.out.noPxChangeTryDetermine.push(xe(Zue,null,r,M,l)),M;var N=u7(r,M,l);return N??M}function Zue(r,e,t){return u7(r,e,t)==null}function u7(r,e,t){var n=Bue(r.model),a=r.getExtent(),i=n.lastAutoInterval,o=n.lastTickCount;if(i!=null&&o!=null&&Math.abs(i-e)<=1&&Math.abs(o-t)<=1&&i>e&&n.axisExtent0===a[0]&&n.axisExtent1===a[1])return i;n.lastTickCount=t,n.lastAutoInterval=e,n.axisExtent0=a[0],n.axisExtent1=a[1]}function $ue(r){var e=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}function c7(r,e,t){var n=dd(r),a=r.scale,i=a.getExtent(),o=r.getLabelModel(),s=[],l=Math.max((e||0)+1,1),u=i[0],c=a.count();u!==0&&l>1&&c/l>2&&(u=Math.round(Math.ceil(u/l)*l));var f=e7(r),d=o.get("showMinLabel")||f,v=o.get("showMaxLabel")||f;d&&u!==i[0]&&y(i[0]);for(var g=u;g<=i[1];g+=l)y(g);v&&g-l!==i[1]&&y(i[1]);function y(x){var b={value:x};s.push(t?x:{formattedLabel:n(b),rawLabel:a.getLabel(b),tickValue:x,time:void 0,break:void 0})}return s}function f7(r,e,t){var n=r.scale,a=dd(r),i=[];return O(n.getTicks(),function(o){var s=n.getLabel(o),l=o.value;e(o.value,s)&&i.push(t?l:{formattedLabel:a(o),rawLabel:s,tickValue:l,time:void 0,break:void 0})}),i}var n3=[0,1],Va=(function(){function r(e,t,n){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=n||[0,0]}return r.prototype.contain=function(e){var t=this._extent,n=Math.min(t[0],t[1]),a=Math.max(t[0],t[1]);return e>=n&&e<=a},r.prototype.containData=function(e){return this.scale.contain(this.scale.parse(e))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.getPixelPrecision=function(e){return nD(e||this.scale.getExtent(),this._extent)},r.prototype.setExtent=function(e,t){var n=this._extent;n[0]=e,n[1]=t},r.prototype.dataToCoord=function(e,t){var n=this._extent,a=this.scale;return e=a.normalize(a.parse(e)),this.onBand&&a.type==="ordinal"&&(n=n.slice(),a3(n,a.count())),pt(e,n3,n,t)},r.prototype.coordToData=function(e,t){var n=this._extent,a=this.scale;this.onBand&&a.type==="ordinal"&&(n=n.slice(),a3(n,a.count()));var i=pt(e,n,n3,t);return this.scale.scale(i)},r.prototype.pointToData=function(e,t){},r.prototype.getTicksCoords=function(e){e=e||{};var t=e.tickModel||this.getTickModel(),n=Gue(this,t,{breakTicks:e.breakTicks,pruneByBreak:e.pruneByBreak}),a=n.ticks,i=fe(a,function(s){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(s):s),tickValue:s}},this),o=t.get("alignWithLabel");return Kue(this,i,o,e.clamp),i},r.prototype.getMinorTicksCoords=function(){if(this.scale.type==="ordinal")return[];var e=this.model.getModel("minorTick"),t=e.get("splitNumber");t>0&&t<100||(t=5);var n=this.scale.getMinorTicks(t),a=fe(n,function(i){return fe(i,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return a},r.prototype.getViewLabels=function(e){return e=e||n1(si.determine),Vue(this,e).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){var e=this._extent,t=this.scale.getExtent(),n=t[1]-t[0]+(this.onBand?1:0);n===0&&(n=1);var a=Math.abs(e[1]-e[0]);return Math.abs(a)/n},r.prototype.calculateCategoryInterval=function(e){return e=e||n1(si.determine),que(this,e)},r})();function a3(r,e){var t=r[1]-r[0],n=e,a=t/n/2;r[0]+=a,r[1]-=a}function Kue(r,e,t,n){var a=e.length;if(!r.onBand||t||!a)return;var i=r.getExtent(),o,s;if(a===1)e[0].coord=i[0],e[0].onBand=!0,o=e[1]={coord:i[1],tickValue:e[0].tickValue,onBand:!0};else{var l=e[a-1].tickValue-e[0].tickValue,u=(e[a-1].coord-e[0].coord)/l;O(e,function(v){v.coord-=u/2,v.onBand=!0});var c=r.scale.getExtent();s=1+c[1]-e[a-1].tickValue,o={coord:e[a-1].coord+u*s,tickValue:c[1]+1,onBand:!0},e.push(o)}var f=i[0]>i[1];d(e[0].coord,i[0])&&(n?e[0].coord=i[0]:e.shift()),n&&d(i[0],e[0].coord)&&e.unshift({coord:i[0],onBand:!0}),d(i[1],o.coord)&&(n?o.coord=i[1]:e.pop()),n&&d(o.coord,i[1])&&e.push({coord:i[1],onBand:!0});function d(v,g){return v=sr(v),g=sr(g),f?v>g:v<g}}function Que(r){var e=Qe.extend(r);return Qe.registerClass(e),e}function Jue(r){var e=Rt.extend(r);return Rt.registerClass(e),e}function ece(r){var e=Ct.extend(r);return Ct.registerClass(e),e}function tce(r){var e=St.extend(r);return St.registerClass(e),e}var jv=Math.PI*2,_u=qi.CMD,rce=["top","right","bottom","left"];function nce(r,e,t,n,a){var i=t.width,o=t.height;switch(r){case"top":n.set(t.x+i/2,t.y-e),a.set(0,-1);break;case"bottom":n.set(t.x+i/2,t.y+o+e),a.set(0,1);break;case"left":n.set(t.x-e,t.y+o/2),a.set(-1,0);break;case"right":n.set(t.x+i+e,t.y+o/2),a.set(1,0);break}}function ace(r,e,t,n,a,i,o,s,l){o-=r,s-=e;var u=Math.sqrt(o*o+s*s);o/=u,s/=u;var c=o*t+r,f=s*t+e;if(Math.abs(n-a)%jv<1e-4)return l[0]=c,l[1]=f,u-t;if(i){var d=n;n=aa(a),a=aa(d)}else n=aa(n),a=aa(a);n>a&&(a+=jv);var v=Math.atan2(s,o);if(v<0&&(v+=jv),v>=n&&v<=a||v+jv>=n&&v+jv<=a)return l[0]=c,l[1]=f,u-t;var g=t*Math.cos(n)+r,y=t*Math.sin(n)+e,x=t*Math.cos(a)+r,b=t*Math.sin(a)+e,w=(g-o)*(g-o)+(y-s)*(y-s),T=(x-o)*(x-o)+(b-s)*(b-s);return w<T?(l[0]=g,l[1]=y,Math.sqrt(w)):(l[0]=x,l[1]=b,Math.sqrt(T))}function a1(r,e,t,n,a,i,o,s){var l=a-r,u=i-e,c=t-r,f=n-e,d=Math.sqrt(c*c+f*f);c/=d,f/=d;var v=l*c+u*f,g=v/d;s&&(g=Math.min(Math.max(g,0),1)),g*=d;var y=o[0]=r+g*c,x=o[1]=e+g*f;return Math.sqrt((y-a)*(y-a)+(x-i)*(x-i))}function h7(r,e,t,n,a,i,o){t<0&&(r=r+t,t=-t),n<0&&(e=e+n,n=-n);var s=r+t,l=e+n,u=o[0]=Math.min(Math.max(a,r),s),c=o[1]=Math.min(Math.max(i,e),l);return Math.sqrt((u-a)*(u-a)+(c-i)*(c-i))}var Za=[];function ice(r,e,t){var n=h7(e.x,e.y,e.width,e.height,r.x,r.y,Za);return t.set(Za[0],Za[1]),n}function oce(r,e,t){for(var n=0,a=0,i=0,o=0,s,l,u=1/0,c=e.data,f=r.x,d=r.y,v=0;v<c.length;){var g=c[v++];v===1&&(n=c[v],a=c[v+1],i=n,o=a);var y=u;switch(g){case _u.M:i=c[v++],o=c[v++],n=i,a=o;break;case _u.L:y=a1(n,a,c[v],c[v+1],f,d,Za,!0),n=c[v++],a=c[v++];break;case _u.C:y=I6(n,a,c[v++],c[v++],c[v++],c[v++],c[v],c[v+1],f,d,Za),n=c[v++],a=c[v++];break;case _u.Q:y=P6(n,a,c[v++],c[v++],c[v],c[v+1],f,d,Za),n=c[v++],a=c[v++];break;case _u.A:var x=c[v++],b=c[v++],w=c[v++],T=c[v++],C=c[v++],D=c[v++];v+=1;var M=!!(1-c[v++]);s=Math.cos(C)*w+x,l=Math.sin(C)*T+b,v<=1&&(i=s,o=l);var N=(f-x)*T/w+x;y=ace(x,b,T,C,C+D,M,N,d,Za),n=Math.cos(C+D)*w+x,a=Math.sin(C+D)*T+b;break;case _u.R:i=n=c[v++],o=a=c[v++];var R=c[v++],E=c[v++];y=h7(i,o,R,E,f,d,Za);break;case _u.Z:y=a1(n,a,i,o,f,d,Za,!0),n=i,a=o;break}y<u&&(u=y,t.set(Za[0],Za[1]))}return u}var Qa=new Ie,jt=new Ie,ir=new Ie,Bi=new Ie,ki=new Ie;function i3(r,e){if(r){var t=r.getTextGuideLine(),n=r.getTextContent();if(n&&t){var a=r.textGuideLineConfig||{},i=[[0,0],[0,0],[0,0]],o=a.candidates||rce,s=n.getBoundingRect().clone();s.applyTransform(n.getComputedTransform());var l=1/0,u=a.anchor,c=r.getComputedTransform(),f=c&&Oa([],c),d=e.get("length2")||0;u&&ir.copy(u);for(var v=0;v<o.length;v++){var g=o[v];nce(g,0,s,Qa,Bi),Ie.scaleAndAdd(jt,Qa,Bi,d),jt.transform(f);var y=r.getBoundingRect(),x=u?u.distance(jt):r instanceof tt?oce(jt,r.path,ir):ice(jt,y,ir);x<l&&(l=x,jt.transform(c),ir.transform(c),ir.toArray(i[0]),jt.toArray(i[1]),Qa.toArray(i[2]))}d7(i,e.get("minTurnAngle")),t.setShape({points:i})}}}var i1=[],_n=new Ie;function d7(r,e){if(e<=180&&e>0){e=e/180*Math.PI,Qa.fromArray(r[0]),jt.fromArray(r[1]),ir.fromArray(r[2]),Ie.sub(Bi,Qa,jt),Ie.sub(ki,ir,jt);var t=Bi.len(),n=ki.len();if(!(t<.001||n<.001)){Bi.scale(1/t),ki.scale(1/n);var a=Bi.dot(ki),i=Math.cos(e);if(i<a){var o=a1(jt.x,jt.y,ir.x,ir.y,Qa.x,Qa.y,i1,!1);_n.fromArray(i1),_n.scaleAndAdd(ki,o/Math.tan(Math.PI-e));var s=ir.x!==jt.x?(_n.x-jt.x)/(ir.x-jt.x):(_n.y-jt.y)/(ir.y-jt.y);if(isNaN(s))return;s<0?Ie.copy(_n,jt):s>1&&Ie.copy(_n,ir),_n.toArray(r[1])}}}}function sce(r,e,t){if(t<=180&&t>0){t=t/180*Math.PI,Qa.fromArray(r[0]),jt.fromArray(r[1]),ir.fromArray(r[2]),Ie.sub(Bi,jt,Qa),Ie.sub(ki,ir,jt);var n=Bi.len(),a=ki.len();if(!(n<.001||a<.001)){Bi.scale(1/n),ki.scale(1/a);var i=Bi.dot(e),o=Math.cos(t);if(i<o){var s=a1(jt.x,jt.y,ir.x,ir.y,Qa.x,Qa.y,i1,!1);_n.fromArray(i1);var l=Math.PI/2,u=Math.acos(ki.dot(e)),c=l+u-t;if(c>=l)Ie.copy(_n,ir);else{_n.scaleAndAdd(ki,s/Math.tan(Math.PI/2-c));var f=ir.x!==jt.x?(_n.x-jt.x)/(ir.x-jt.x):(_n.y-jt.y)/(ir.y-jt.y);if(isNaN(f))return;f<0?Ie.copy(_n,jt):f>1&&Ie.copy(_n,ir)}_n.toArray(r[1])}}}}function s2(r,e,t,n){var a=t==="normal",i=a?r:r.ensureState(t);i.ignore=e;var o=n.get("smooth");o&&o===!0&&(o=.3),i.shape=i.shape||{},o>0&&(i.shape.smooth=o);var s=n.getModel("lineStyle").getLineStyle();a?r.useStyle(s):i.style=s}function lce(r,e){var t=e.smooth,n=e.points;if(n)if(r.moveTo(n[0][0],n[0][1]),t>0&&n.length>=3){var a=Io(n[0],n[1]),i=Io(n[1],n[2]);if(!a||!i){r.lineTo(n[1][0],n[1][1]),r.lineTo(n[2][0],n[2][1]);return}var o=Math.min(a,i)*t,s=Cp([],n[1],n[0],o/a),l=Cp([],n[1],n[2],o/i),u=Cp([],s,l,.5);r.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),r.bezierCurveTo(l[0],l[1],l[0],l[1],n[2][0],n[2][1])}else for(var c=1;c<n.length;c++)r.lineTo(n[c][0],n[c][1])}function vN(r,e,t){var n=r.getTextGuideLine(),a=r.getTextContent();if(!a){n&&r.removeTextGuideLine();return}for(var i=e.normal,o=i.get("show"),s=a.ignore,l=0;l<tg.length;l++){var u=tg[l],c=e[u],f=u==="normal";if(c){var d=c.get("show"),v=f?s:Ce(a.states[u]&&a.states[u].ignore,s);if(v||!Ce(d,o)){var g=f?n:n&&n.states[u];g&&(g.ignore=!0),n&&s2(n,!0,u,c);continue}n||(n=new Ur,r.setTextGuideLine(n),!f&&(s||!o)&&s2(n,!0,"normal",e.normal),r.stateProxy&&(n.stateProxy=r.stateProxy)),s2(n,!1,u,c)}}if(n){Re(n.style,t),n.style.fill=null;var y=i.get("showAbove"),x=r.textGuideLineConfig=r.textGuideLineConfig||{};x.showAbove=y||!1,n.buildPath=lce}}function pN(r,e){e=e||"labelLine";for(var t={normal:r.getModel(e)},n=0;n<Cn.length;n++){var a=Cn[n];t[a]=r.getModel([a,e])}return t}var o3=["label","labelLine","layoutOption","priority","defaultAttr","marginForce","minMarginForce","marginDefault","suggestIgnore"],uce=1,o1=2,v7=uce|o1;function s1(r,e,t){t=t||v7,e?r.dirty|=t:r.dirty&=~t}function p7(r,e){return e=e||v7,r.dirty==null||!!(r.dirty&e)}function $i(r){if(r)return p7(r)&&g7(r,r.label,r),r}function g7(r,e,t){var n=e.getComputedTransform();r.transform=CD(r.transform,n);var a=r.localRect=ag(r.localRect,e.getBoundingRect()),i=e.style,o=i.margin,s=t&&t.marginForce,l=t&&t.minMarginForce,u=t&&t.marginDefault,c=i.__marginType;c==null&&u&&(o=u,c=th.textMargin);for(var f=0;f<4;f++)l2[f]=c===th.minMargin&&l&&l[f]!=null?l[f]:s&&s[f]!=null?s[f]:o?o[f]:0;c===th.textMargin&&hc(a,l2,!1,!1);var d=r.rect=ag(r.rect,a);return n&&d.applyTransform(n),c===th.minMargin&&hc(d,l2,!1,!1),r.axisAligned=TD(n),(r.label=r.label||{}).ignore=e.ignore,s1(r,!1),s1(r,!0,o1),r}var l2=[0,0,0,0];function cce(r,e,t){return r.transform=CD(r.transform,t),r.localRect=ag(r.localRect,e),r.rect=ag(r.rect,e),t&&r.rect.applyTransform(t),r.axisAligned=TD(t),r.obb=void 0,(r.label=r.label||{}).ignore=!1,r}function gA(r,e){if(r){r.label.x+=e.x,r.label.y+=e.y,r.label.markRedraw();var t=r.transform;t&&(t[4]+=e.x,t[5]+=e.y);var n=r.rect;n&&(n.x+=e.x,n.y+=e.y);var a=r.obb;a&&a.fromBoundingRect(r.localRect,t)}}function mA(r,e){for(var t=0;t<o3.length;t++){var n=o3[t];r[n]==null&&(r[n]=e[n])}return $i(r)}function s3(r){var e=r.obb;return(!e||p7(r,o1))&&(r.obb=e=e||new GH,e.fromBoundingRect(r.localRect,r.transform),s1(r,!1,o1)),e}function yA(r,e,t,n,a){var i=r.length,o=Ge[e],s=vr[e];if(i<2)return!1;r.sort(function(N,R){return N.rect[o]-R.rect[o]});for(var l=0,u,c=!1,f=0;f<i;f++){var d=r[f],v=d.rect;u=v[o]-l,u<0&&(v[o]-=u,d.label[o]-=u,c=!0),l=v[o]+v[s]}var g=r[0],y=r[i-1],x,b;w(),x<0&&D(-x,.8),b<0&&D(b,.8),w(),T(x,b,1),T(b,x,-1),w(),x<0&&M(-x),b<0&&M(b);function w(){x=g.rect[o]-t,b=n-y.rect[o]-y.rect[s]}function T(N,R,E){if(N<0){var k=Math.min(R,-N);if(k>0){C(k*E,0,i);var I=k+N;I<0&&D(-I*E,1)}else D(-N*E,1)}}function C(N,R,E){N!==0&&(c=!0);for(var k=R;k<E;k++){var I=r[k],B=I.rect;B[o]+=N,I.label[o]+=N}}function D(N,R){for(var E=[],k=0,I=1;I<i;I++){var B=r[I-1].rect,P=Math.max(r[I].rect[o]-B[o]-B[s],0);E.push(P),k+=P}if(k){var H=Math.min(Math.abs(N)/k,R);if(N>0)for(var I=0;I<i-1;I++){var V=E[I]*H;C(V,0,I+1)}else for(var I=i-1;I>0;I--){var V=E[I-1]*H;C(-V,I,i)}}}function M(N){var R=N<0?-1:1;N=Math.abs(N);for(var E=Math.ceil(N/(i-1)),k=0;k<i-1;k++)if(R>0?C(E,0,k+1):C(-E,i-k-1,i),N-=E,N<=0)return}return c}function fce(r){for(var e=0;e<r.length;e++){var t=r[e],n=t.defaultAttr,a=t.labelLine;t.label.attr("ignore",n.ignore),a&&a.attr("ignore",n.labelGuideIgnore)}}function m7(r){var e=[];r.sort(function(u,c){return(c.suggestIgnore?1:0)-(u.suggestIgnore?1:0)||c.priority-u.priority});function t(u){if(!u.ignore){var c=u.ensureState("emphasis");c.ignore==null&&(c.ignore=!1)}u.ignore=!0}for(var n=0;n<r.length;n++){var a=$i(r[n]);if(!a.label.ignore){for(var i=a.label,o=a.labelLine,s=!1,l=0;l<e.length;l++)if(yb(a,e[l],null,{touchThreshold:.05})){s=!0;break}s?(t(i),o&&t(o)):e.push(a)}}}function yb(r,e,t,n){return!r||!e||r.label&&r.label.ignore||e.label&&e.label.ignore||!r.rect.intersect(e.rect,t,n)?!1:r.axisAligned&&e.axisAligned?!0:s3(r).intersect(s3(e),t,n)}function hce(r){if(r){for(var e=[],t=0;t<r.length;t++)e.push(r[t].slice());return e}}function dce(r,e){var t=r.label,n=e&&e.getTextGuideLine();return{dataIndex:r.dataIndex,dataType:r.dataType,seriesIndex:r.seriesModel.seriesIndex,text:r.label.style.text,rect:r.hostRect,labelRect:r.rect,align:t.style.align,verticalAlign:t.style.verticalAlign,labelLinePoints:hce(n&&n.shape.points)}}var l3=["align","verticalAlign","width","height","fontSize"],mn=new jo,u2=Je(),vce=Je();function u0(r,e,t){for(var n=0;n<t.length;n++){var a=t[n];e[a]!=null&&(r[a]=e[a])}}var c0=["x","y","rotation"],pce=(function(){function r(){this._labelList=[],this._chartViewList=[]}return r.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},r.prototype._addLabel=function(e,t,n,a,i){var o=a.style,s=a.__hostTarget,l=s.textConfig||{},u=a.getComputedTransform(),c=a.getBoundingRect().plain();Oe.applyTransform(c,c,u),u?mn.setLocalTransform(u):(mn.x=mn.y=mn.rotation=mn.originX=mn.originY=0,mn.scaleX=mn.scaleY=1),mn.rotation=aa(mn.rotation);var f=a.__hostTarget,d;if(f){d=f.getBoundingRect().plain();var v=f.getComputedTransform();Oe.applyTransform(d,d,v)}var g=d&&f.getTextGuideLine();this._labelList.push({label:a,labelLine:g,seriesModel:n,dataIndex:e,dataType:t,layoutOptionOrCb:i,layoutOption:null,rect:c,hostRect:d,priority:d?d.width*d.height:0,defaultAttr:{ignore:a.ignore,labelGuideIgnore:g&&g.ignore,x:mn.x,y:mn.y,scaleX:mn.scaleX,scaleY:mn.scaleY,rotation:mn.rotation,style:{x:o.x,y:o.y,align:o.align,verticalAlign:o.verticalAlign,width:o.width,height:o.height,fontSize:o.fontSize},cursor:a.cursor,attachedPos:l.position,attachedRot:l.rotation}})},r.prototype.addLabelsOfSeries=function(e){var t=this;this._chartViewList.push(e);var n=e.__model,a=n.get("labelLayout");(Me(a)||it(a).length)&&e.group.traverse(function(i){if(i.ignore)return!0;var o=i.getTextContent(),s=je(i);o&&!o.disableLabelLayout&&t._addLabel(s.dataIndex,s.dataType,n,o,a)})},r.prototype.updateLayoutConfig=function(e){var t=e.getWidth(),n=e.getHeight();function a(T,C){return function(){i3(T,C)}}for(var i=0;i<this._labelList.length;i++){var o=this._labelList[i],s=o.label,l=s.__hostTarget,u=o.defaultAttr,c=void 0;Me(o.layoutOptionOrCb)?c=o.layoutOptionOrCb(dce(o,l)):c=o.layoutOptionOrCb,c=c||{},o.layoutOption=c;var f=Math.PI/180;l&&l.setTextConfig({local:!1,position:c.x!=null||c.y!=null?null:u.attachedPos,rotation:c.rotate!=null?c.rotate*f:u.attachedRot,offset:[c.dx||0,c.dy||0]});var d=!1;if(c.x!=null?(s.x=me(c.x,t),s.setStyle("x",0),d=!0):(s.x=u.x,s.setStyle("x",u.style.x)),c.y!=null?(s.y=me(c.y,n),s.setStyle("y",0),d=!0):(s.y=u.y,s.setStyle("y",u.style.y)),c.labelLinePoints){var v=l.getTextGuideLine();v&&(v.setShape({points:c.labelLinePoints}),d=!1)}var g=u2(s);g.needsUpdateLabelLine=d,s.rotation=c.rotate!=null?c.rotate*f:u.rotation,s.scaleX=u.scaleX,s.scaleY=u.scaleY;for(var y=0;y<l3.length;y++){var x=l3[y];s.setStyle(x,c[x]!=null?c[x]:u.style[x])}if(c.draggable){if(s.draggable=!0,s.cursor="move",l){var b=o.seriesModel;if(o.dataIndex!=null){var w=o.seriesModel.getData(o.dataType);b=w.getItemModel(o.dataIndex)}s.on("drag",a(l,b.getModel("labelLine")))}}else s.off("drag"),s.cursor=u.cursor}},r.prototype.layout=function(e){var t=e.getWidth(),n=e.getHeight(),a=[];O(this._labelList,function(l){l.defaultAttr.ignore||a.push(mA({},l))});var i=dt(a,function(l){return l.layoutOption.moveOverlap==="shiftX"}),o=dt(a,function(l){return l.layoutOption.moveOverlap==="shiftY"});yA(i,0,0,t),yA(o,1,0,n);var s=dt(a,function(l){return l.layoutOption.hideOverlap});fce(s),m7(s)},r.prototype.processLabelsOverall=function(){var e=this;O(this._chartViewList,function(t){var n=t.__model,a=t.ignoreLabelLineUpdate,i=n.isAnimationEnabled();t.group.traverse(function(o){if(o.ignore&&!o.forceLabelAnimation)return!0;var s=!a,l=o.getTextContent();!s&&l&&(s=u2(l).needsUpdateLabelLine),s&&e._updateLabelLine(o,n),i&&e._animateLabels(o,n)})})},r.prototype._updateLabelLine=function(e,t){var n=e.getTextContent(),a=je(e),i=a.dataIndex;if(n&&i!=null){var o=t.getData(a.dataType),s=o.getItemModel(i),l={},u=o.getItemVisual(i,"style");if(u){var c=o.getVisual("drawType");l.stroke=u[c]}var f=s.getModel("labelLine");vN(e,pN(s),l),i3(e,f)}},r.prototype._animateLabels=function(e,t){var n=e.getTextContent(),a=e.getTextGuideLine();if(n&&(e.forceLabelAnimation||!n.ignore&&!n.invisible&&!e.disableLabelAnimation&&!hh(e))){var i=u2(n),o=i.oldLayout,s=je(e),l=s.dataIndex,u={x:n.x,y:n.y,rotation:n.rotation},c=t.getData(s.dataType);if(o){n.attr(o);var d=e.prevStates;d&&(Fe(d,"select")>=0&&n.attr(i.oldLayoutSelect),Fe(d,"emphasis")>=0&&n.attr(i.oldLayoutEmphasis)),lt(n,u,t,l)}else if(n.attr(u),!id(n).valueAnimation){var f=Ce(n.style.opacity,1);n.style.opacity=0,zt(n,{style:{opacity:f}},t,l)}if(i.oldLayout=u,n.states.select){var v=i.oldLayoutSelect={};u0(v,u,c0),u0(v,n.states.select,c0)}if(n.states.emphasis){var g=i.oldLayoutEmphasis={};u0(g,u,c0),u0(g,n.states.emphasis,c0)}JH(n,l,c,t,t)}if(a&&!a.ignore&&!a.invisible){var i=vce(a),o=i.oldLayout,y={points:a.shape.points};o?(a.attr({shape:o}),lt(a,{shape:y},t)):(a.setShape(y),a.style.strokePercent=0,zt(a,{style:{strokePercent:1}},t)),i.oldLayout=y}},r})(),c2=Je();function gce(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,n){var a=c2(t).labelManager;a||(a=c2(t).labelManager=new pce),a.clearLabels()}),r.registerUpdateLifecycle("series:layoutlabels",function(e,t,n){var a=c2(t).labelManager;n.updatedSeries.forEach(function(i){a.addLabelsOfSeries(t.getViewOfSeriesModel(i))}),a.updateLayoutConfig(t),a.layout(t),a.processLabelsOverall()})}var f2=Math.sin,h2=Math.cos,y7=Math.PI,Su=Math.PI*2,mce=180/y7,x7=(function(){function r(){}return r.prototype.reset=function(e){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,e||4)},r.prototype.moveTo=function(e,t){this._add("M",e,t)},r.prototype.lineTo=function(e,t){this._add("L",e,t)},r.prototype.bezierCurveTo=function(e,t,n,a,i,o){this._add("C",e,t,n,a,i,o)},r.prototype.quadraticCurveTo=function(e,t,n,a){this._add("Q",e,t,n,a)},r.prototype.arc=function(e,t,n,a,i,o){this.ellipse(e,t,n,n,0,a,i,o)},r.prototype.ellipse=function(e,t,n,a,i,o,s,l){var u=s-o,c=!l,f=Math.abs(u),d=nl(f-Su)||(c?u>=Su:-u>=Su),v=u>0?u%Su:u%Su+Su,g=!1;d?g=!0:nl(f)?g=!1:g=v>=y7==!!c;var y=e+n*h2(o),x=t+a*f2(o);this._start&&this._add("M",y,x);var b=Math.round(i*mce);if(d){var w=1/this._p,T=(c?1:-1)*(Su-w);this._add("A",n,a,b,1,+c,e+n*h2(o+T),t+a*f2(o+T)),w>.01&&this._add("A",n,a,b,0,+c,y,x)}else{var C=e+n*h2(s),D=t+a*f2(s);this._add("A",n,a,b,+g,+c,C,D)}},r.prototype.rect=function(e,t,n,a){this._add("M",e,t),this._add("l",n,0),this._add("l",0,a),this._add("l",-n,0),this._add("Z")},r.prototype.closePath=function(){this._d.length>0&&this._add("Z")},r.prototype._add=function(e,t,n,a,i,o,s,l,u){for(var c=[],f=this._p,d=1;d<arguments.length;d++){var v=arguments[d];if(isNaN(v)){this._invalid=!0;return}c.push(Math.round(v*f)/f)}this._d.push(e+c.join(" ")),this._start=e==="Z"},r.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(""),this._d=[]},r.prototype.getStr=function(){return this._str},r})(),gN="none",yce=Math.round;function xce(r){var e=r.fill;return e!=null&&e!==gN}function bce(r){var e=r.stroke;return e!=null&&e!==gN}var xA=["lineCap","miterLimit","lineJoin"],_ce=fe(xA,function(r){return"stroke-"+r.toLowerCase()});function Sce(r,e,t,n){var a=e.opacity==null?1:e.opacity;if(t instanceof Ir){r("opacity",a);return}if(xce(e)){var i=Jp(e.fill);r("fill",i.color);var o=e.fillOpacity!=null?e.fillOpacity*i.opacity*a:i.opacity*a;o<1&&r("fill-opacity",o)}else r("fill",gN);if(bce(e)){var s=Jp(e.stroke);r("stroke",s.color);var l=e.strokeNoScale?t.getLineScale():1,u=l?(e.lineWidth||0)/l:0,c=e.strokeOpacity!=null?e.strokeOpacity*s.opacity*a:s.opacity*a,f=e.strokeFirst;if(u!==1&&r("stroke-width",u),f&&r("paint-order",f?"stroke":"fill"),c<1&&r("stroke-opacity",c),e.lineDash){var d=KD(t),v=d[0],g=d[1];v&&(g=yce(g||0),r("stroke-dasharray",v.join(",")),(g||n)&&r("stroke-dashoffset",g))}for(var y=0;y<xA.length;y++){var x=xA[y];if(e[x]!==jx[x]){var b=e[x]||jx[x];b&&r(_ce[y],b)}}}}var b7="http://www.w3.org/2000/svg",_7="http://www.w3.org/1999/xlink",wce="http://www.w3.org/2000/xmlns/",Tce="http://www.w3.org/XML/1998/namespace",u3="ecmeta_";function S7(r){return document.createElementNS(b7,r)}function Lr(r,e,t,n,a){return{tag:r,attrs:t||{},children:n,text:a,key:e}}function Cce(r,e){var t=[];if(e)for(var n in e){var a=e[n],i=n;a!==!1&&(a!==!0&&a!=null&&(i+='="'+a+'"'),t.push(i))}return"<"+r+" "+t.join(" ")+">"}function Ace(r){return"</"+r+">"}function mN(r,e){e=e||{};var t=e.newline?`
279
- `:"";function n(a){var i=a.children,o=a.tag,s=a.attrs,l=a.text;return Cce(o,s)+(o!=="style"?dn(l):l||"")+(i?""+t+fe(i,function(u){return n(u)}).join(t)+t:"")+Ace(o)}return n(r)}function Mce(r,e,t){t=t||{};var n=t.newline?`
280
- `:"",a=" {"+n,i=n+"}",o=fe(it(r),function(l){return l+a+fe(it(r[l]),function(u){return u+":"+r[l][u]+";"}).join(n)+i}).join(n),s=fe(it(e),function(l){return"@keyframes "+l+a+fe(it(e[l]),function(u){return u+a+fe(it(e[l][u]),function(c){var f=e[l][u][c];return c==="d"&&(f='path("'+f+'")'),c+":"+f+";"}).join(n)+i}).join(n)+i}).join(n);return!o&&!s?"":["<![CDATA[",o,s,"]]>"].join(n)}function bA(r){return{zrId:r,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function c3(r,e,t,n){return Lr("svg","root",{width:r,height:e,xmlns:b7,"xmlns:xlink":_7,version:"1.1",baseProfile:"full",viewBox:n?"0 0 "+r+" "+e:!1},t)}var Dce=0;function w7(){return Dce++}var f3={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},Au="transform-origin";function Nce(r,e,t){var n=ie({},r.shape);ie(n,e),r.buildPath(t,n);var a=new x7;return a.reset(F6(r)),t.rebuildPath(a,1),a.generateStr(),a.getStr()}function Lce(r,e){var t=e.originX,n=e.originY;(t||n)&&(r[Au]=t+"px "+n+"px")}var Rce={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function T7(r,e){var t=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[t]=r,t}function Ece(r,e,t){var n=r.shape.paths,a={},i,o;if(O(n,function(l){var u=bA(t.zrId);u.animation=!0,xb(l,{},u,!0);var c=u.cssAnims,f=u.cssNodes,d=it(c),v=d.length;if(v){o=d[v-1];var g=c[o];for(var y in g){var x=g[y];a[y]=a[y]||{d:""},a[y].d+=x.d||""}for(var b in f){var w=f[b].animation;w.indexOf(o)>=0&&(i=w)}}}),!!i){e.d=!1;var s=T7(a,t);return i.replace(o,s)}}function h3(r){return ye(r)?f3[r]?"cubic-bezier("+f3[r]+")":JM(r)?r:"":""}function xb(r,e,t,n){var a=r.animators,i=a.length,o=[];if(r instanceof Xg){var s=Ece(r,e,t);if(s)o.push(s);else if(!i)return}else if(!i)return;for(var l={},u=0;u<i;u++){var c=a[u],f=[c.getMaxTime()/1e3+"s"],d=h3(c.getClip().easing),v=c.getDelay();d?f.push(d):f.push("linear"),v&&f.push(v/1e3+"s"),c.getLoop()&&f.push("infinite");var g=f.join(" ");l[g]=l[g]||[g,[]],l[g][1].push(c)}function y(w){var T=w[1],C=T.length,D={},M={},N={},R="animation-timing-function";function E(be,we,ze){for(var oe=be.getTracks(),pe=be.getMaxTime(),Be=0;Be<oe.length;Be++){var Le=oe[Be];if(Le.needsAnimate()){var at=Le.keyframes,ft=Le.propName;if(ze&&(ft=ze(ft)),ft)for(var At=0;At<at.length;At++){var Wr=at[At],er=Math.round(Wr.time/pe*100)+"%",ci=h3(Wr.easing),Ga=Wr.rawValue;(ye(Ga)||st(Ga))&&(we[er]=we[er]||{},we[er][ft]=Wr.rawValue,ci&&(we[er][R]=ci))}}}}for(var k=0;k<C;k++){var I=T[k],B=I.targetName;B?B==="shape"&&E(I,M):!n&&E(I,D)}for(var P in D){var H={};Ix(H,r),ie(H,D[P]);var V=U6(H),j=D[P][R];N[P]=V?{transform:V}:{},Lce(N[P],H),j&&(N[P][R]=j)}var U,F=!0;for(var P in M){N[P]=N[P]||{};var X=!U,j=M[P][R];X&&(U=new qi);var G=U.len();U.reset(),N[P].d=Nce(r,M[P],U);var W=U.len();if(!X&&G!==W){F=!1;break}j&&(N[P][R]=j)}if(!F)for(var P in N)delete N[P].d;if(!n)for(var k=0;k<C;k++){var I=T[k],B=I.targetName;B==="style"&&E(I,N,function(oe){return Rce[oe]})}for(var $=it(N),te=!0,ue,k=1;k<$.length;k++){var ge=$[k-1],Se=$[k];if(N[ge][Au]!==N[Se][Au]){te=!1;break}ue=N[ge][Au]}if(te&&ue){for(var P in N)N[P][Au]&&delete N[P][Au];e[Au]=ue}if(dt($,function(be){return it(N[be]).length>0}).length){var Xe=T7(N,t);return Xe+" "+w[0]+" both"}}for(var x in l){var s=y(l[x]);s&&o.push(s)}if(o.length){var b=t.zrId+"-cls-"+w7();t.cssNodes["."+b]={animation:o.join(",")},e.class=b}}function kce(r,e,t){if(!r.ignore)if(r.isSilent()){var n={"pointer-events":"none"};d3(n,e,t)}else{var a=r.states.emphasis&&r.states.emphasis.style?r.states.emphasis.style:{},i=a.fill;if(!i){var o=r.style&&r.style.fill,s=r.states.select&&r.states.select.style&&r.states.select.style.fill,l=r.currentStates.indexOf("select")>=0&&s||o;l&&(i=Rx(l))}var u=a.lineWidth;if(u){var c=!a.strokeNoScale&&r.transform?r.transform[0]:1;u=u/c}var n={cursor:"pointer"};i&&(n.fill=i),a.stroke&&(n.stroke=a.stroke),u&&(n["stroke-width"]=u),d3(n,e,t)}}function d3(r,e,t,n){var a=JSON.stringify(r),i=t.cssStyleCache[a];i||(i=t.zrId+"-cls-"+w7(),t.cssStyleCache[a]=i,t.cssNodes["."+i+":hover"]=r),e.class=e.class?e.class+" "+i:i}var dg=Math.round;function C7(r){return r&&ye(r.src)}function A7(r){return r&&Me(r.toDataURL)}function yN(r,e,t,n){Sce(function(a,i){var o=a==="fill"||a==="stroke";o&&H6(i)?D7(e,r,a,n):o&&tD(i)?N7(t,r,a,n):r[a]=i,o&&n.ssr&&i==="none"&&(r["pointer-events"]="visible")},e,t,!1),Vce(t,r,n)}function xN(r,e){var t=K6(e);t&&(t.each(function(n,a){n!=null&&(r[(u3+a).toLowerCase()]=n+"")}),e.isSilent()&&(r[u3+"silent"]="true"))}function v3(r){return nl(r[0]-1)&&nl(r[1])&&nl(r[2])&&nl(r[3]-1)}function Ice(r){return nl(r[4])&&nl(r[5])}function bN(r,e,t){if(e&&!(Ice(e)&&v3(e))){var n=1e4;r.transform=v3(e)?"translate("+dg(e[4]*n)/n+" "+dg(e[5]*n)/n+")":pre(e)}}function p3(r,e,t){for(var n=r.points,a=[],i=0;i<n.length;i++)a.push(dg(n[i][0]*t)/t),a.push(dg(n[i][1]*t)/t);e.points=a.join(" ")}function g3(r){return!r.smooth}function Oce(r){var e=fe(r,function(t){return typeof t=="string"?[t,t]:t});return function(t,n,a){for(var i=0;i<e.length;i++){var o=e[i],s=t[o[0]];s!=null&&(n[o[1]]=dg(s*a)/a)}}}var Pce={circle:[Oce(["cx","cy","r"])],polyline:[p3,g3],polygon:[p3,g3]};function jce(r){for(var e=r.animators,t=0;t<e.length;t++)if(e[t].targetName==="shape")return!0;return!1}function M7(r,e){var t=r.style,n=r.shape,a=Pce[r.type],i={},o=e.animation,s="path",l=r.style.strokePercent,u=e.compress&&F6(r)||4;if(a&&!e.willUpdate&&!(a[1]&&!a[1](n))&&!(o&&jce(r))&&!(l<1)){s=r.type;var c=Math.pow(10,u);a[0](n,i,c)}else{var f=!r.path||r.shapeChanged();r.path||r.createPathProxy();var d=r.path;f&&(d.beginPath(),r.buildPath(d,r.shape),r.pathUpdated());var v=d.getVersion(),g=r,y=g.__svgPathBuilder;(g.__svgPathVersion!==v||!y||l!==g.__svgPathStrokePercent)&&(y||(y=g.__svgPathBuilder=new x7),y.reset(u),d.rebuildPath(y,l),y.generateStr(),g.__svgPathVersion=v,g.__svgPathStrokePercent=l),i.d=y.getStr()}return bN(i,r.transform),yN(i,t,r,e),xN(i,r),e.animation&&xb(r,i,e),e.emphasis&&kce(r,i,e),Lr(s,r.id+"",i)}function zce(r,e){var t=r.style,n=t.image;if(n&&!ye(n)&&(C7(n)?n=n.src:A7(n)&&(n=n.toDataURL())),!!n){var a=t.x||0,i=t.y||0,o=t.width,s=t.height,l={href:n,width:o,height:s};return a&&(l.x=a),i&&(l.y=i),bN(l,r.transform),yN(l,t,r,e),xN(l,r),e.animation&&xb(r,l,e),Lr("image",r.id+"",l)}}function Bce(r,e){var t=r.style,n=t.text;if(n!=null&&(n+=""),!(!n||isNaN(t.x)||isNaN(t.y))){var a=t.font||qo,i=t.x||0,o=mre(t.y||0,Fg(a),t.textBaseline),s=gre[t.textAlign]||t.textAlign,l={"dominant-baseline":"central","text-anchor":s};if(wH(t)){var u="",c=t.fontStyle,f=SH(t.fontSize);if(!parseFloat(f))return;var d=t.fontFamily||v6,v=t.fontWeight;u+="font-size:"+f+";font-family:"+d+";",c&&c!=="normal"&&(u+="font-style:"+c+";"),v&&v!=="normal"&&(u+="font-weight:"+v+";"),l.style=u}else l.style="font: "+a;return n.match(/\s/)&&(l["xml:space"]="preserve"),i&&(l.x=i),o&&(l.y=o),bN(l,r.transform),yN(l,t,r,e),xN(l,r),e.animation&&xb(r,l,e),Lr("text",r.id+"",l,void 0,n)}}function m3(r,e){if(r instanceof tt)return M7(r,e);if(r instanceof Ir)return zce(r,e);if(r instanceof Ih)return Bce(r,e)}function Vce(r,e,t){var n=r.style;if(yre(n)){var a=xre(r),i=t.shadowCache,o=i[a];if(!o){var s=r.getGlobalScale(),l=s[0],u=s[1];if(!l||!u)return;var c=n.shadowOffsetX||0,f=n.shadowOffsetY||0,d=n.shadowBlur,v=Jp(n.shadowColor),g=v.opacity,y=v.color,x=d/2/l,b=d/2/u,w=x+" "+b;o=t.zrId+"-s"+t.shadowIdx++,t.defs[o]=Lr("filter",o,{id:o,x:"-100%",y:"-100%",width:"300%",height:"300%"},[Lr("feDropShadow","",{dx:c/l,dy:f/u,stdDeviation:w,"flood-color":y,"flood-opacity":g})]),i[a]=o}e.filter=$1(o)}}function D7(r,e,t,n){var a=r[t],i,o={gradientUnits:a.global?"userSpaceOnUse":"objectBoundingBox"};if(V6(a))i="linearGradient",o.x1=a.x,o.y1=a.y,o.x2=a.x2,o.y2=a.y2;else if(G6(a))i="radialGradient",o.cx=Ce(a.x,.5),o.cy=Ce(a.y,.5),o.r=Ce(a.r,.5);else return;for(var s=a.colorStops,l=[],u=0,c=s.length;u<c;++u){var f=mC(s[u].offset)*100+"%",d=s[u].color,v=Jp(d),g=v.color,y=v.opacity,x={offset:f};x["stop-color"]=g,y<1&&(x["stop-opacity"]=y),l.push(Lr("stop",u+"",x))}var b=Lr(i,"",o,l),w=mN(b),T=n.gradientCache,C=T[w];C||(C=n.zrId+"-g"+n.gradientIdx++,T[w]=C,o.id=C,n.defs[C]=Lr(i,C,o,l)),e[t]=$1(C)}function N7(r,e,t,n){var a=r.style[t],i=r.getBoundingRect(),o={},s=a.repeat,l=s==="no-repeat",u=s==="repeat-x",c=s==="repeat-y",f;if(B6(a)){var d=a.imageWidth,v=a.imageHeight,g=void 0,y=a.image;if(ye(y)?g=y:C7(y)?g=y.src:A7(y)&&(g=y.toDataURL()),typeof Image>"u"){var x="Image width/height must been given explictly in svg-ssr renderer.";rn(d,x),rn(v,x)}else if(d==null||v==null){var b=function(k,I){if(k){var B=k.elm,P=d||I.width,H=v||I.height;k.tag==="pattern"&&(u?(H=1,P/=i.width):c&&(P=1,H/=i.height)),k.attrs.width=P,k.attrs.height=H,B&&(B.setAttribute("width",P),B.setAttribute("height",H))}},w=cD(g,null,r,function(k){l||b(M,k),b(f,k)});w&&w.width&&w.height&&(d=d||w.width,v=v||w.height)}f=Lr("image","img",{href:g,width:d,height:v}),o.width=d,o.height=v}else a.svgElement&&(f=De(a.svgElement),o.width=a.svgWidth,o.height=a.svgHeight);if(f){var T,C;l?T=C=1:u?(C=1,T=o.width/i.width):c?(T=1,C=o.height/i.height):o.patternUnits="userSpaceOnUse",T!=null&&!isNaN(T)&&(o.width=T),C!=null&&!isNaN(C)&&(o.height=C);var D=U6(a);D&&(o.patternTransform=D);var M=Lr("pattern","",o,[f]),N=mN(M),R=n.patternCache,E=R[N];E||(E=n.zrId+"-p"+n.patternIdx++,R[N]=E,o.id=E,M=n.defs[E]=Lr("pattern",E,o,[f])),e[t]=$1(E)}}function Gce(r,e,t){var n=t.clipPathCache,a=t.defs,i=n[r.id];if(!i){i=t.zrId+"-c"+t.clipPathIdx++;var o={id:i};n[r.id]=i,a[i]=Lr("clipPath",i,o,[M7(r,t)])}e["clip-path"]=$1(i)}function y3(r){return document.createTextNode(r)}function ku(r,e,t){r.insertBefore(e,t)}function x3(r,e){r.removeChild(e)}function b3(r,e){r.appendChild(e)}function L7(r){return r.parentNode}function R7(r){return r.nextSibling}function d2(r,e){r.textContent=e}var _3=58,Hce=120,Fce=Lr("","");function _A(r){return r===void 0}function Ci(r){return r!==void 0}function Uce(r,e,t){for(var n={},a=e;a<=t;++a){var i=r[a].key;i!==void 0&&(n[i]=a)}return n}function pp(r,e){var t=r.key===e.key,n=r.tag===e.tag;return n&&t}function vg(r){var e,t=r.children,n=r.tag;if(Ci(n)){var a=r.elm=S7(n);if(_N(Fce,r),ce(t))for(e=0;e<t.length;++e){var i=t[e];i!=null&&b3(a,vg(i))}else Ci(r.text)&&!Ee(r.text)&&b3(a,y3(r.text))}else r.elm=y3(r.text);return r.elm}function E7(r,e,t,n,a){for(;n<=a;++n){var i=t[n];i!=null&&ku(r,vg(i),e)}}function l1(r,e,t,n){for(;t<=n;++t){var a=e[t];if(a!=null)if(Ci(a.tag)){var i=L7(a.elm);x3(i,a.elm)}else x3(r,a.elm)}}function _N(r,e){var t,n=e.elm,a=r&&r.attrs||{},i=e.attrs||{};if(a!==i){for(t in i){var o=i[t],s=a[t];s!==o&&(o===!0?n.setAttribute(t,""):o===!1?n.removeAttribute(t):t==="style"?n.style.cssText=o:t.charCodeAt(0)!==Hce?n.setAttribute(t,o):t==="xmlns:xlink"||t==="xmlns"?n.setAttributeNS(wce,t,o):t.charCodeAt(3)===_3?n.setAttributeNS(Tce,t,o):t.charCodeAt(5)===_3?n.setAttributeNS(_7,t,o):n.setAttribute(t,o))}for(t in a)t in i||n.removeAttribute(t)}}function Yce(r,e,t){for(var n=0,a=0,i=e.length-1,o=e[0],s=e[i],l=t.length-1,u=t[0],c=t[l],f,d,v,g;n<=i&&a<=l;)o==null?o=e[++n]:s==null?s=e[--i]:u==null?u=t[++a]:c==null?c=t[--l]:pp(o,u)?(qf(o,u),o=e[++n],u=t[++a]):pp(s,c)?(qf(s,c),s=e[--i],c=t[--l]):pp(o,c)?(qf(o,c),ku(r,o.elm,R7(s.elm)),o=e[++n],c=t[--l]):pp(s,u)?(qf(s,u),ku(r,s.elm,o.elm),s=e[--i],u=t[++a]):(_A(f)&&(f=Uce(e,n,i)),d=f[u.key],_A(d)?ku(r,vg(u),o.elm):(v=e[d],v.tag!==u.tag?ku(r,vg(u),o.elm):(qf(v,u),e[d]=void 0,ku(r,v.elm,o.elm))),u=t[++a]);(n<=i||a<=l)&&(n>i?(g=t[l+1]==null?null:t[l+1].elm,E7(r,g,t,a,l)):l1(r,e,n,i))}function qf(r,e){var t=e.elm=r.elm,n=r.children,a=e.children;r!==e&&(_N(r,e),_A(e.text)?Ci(n)&&Ci(a)?n!==a&&Yce(t,n,a):Ci(a)?(Ci(r.text)&&d2(t,""),E7(t,null,a,0,a.length-1)):Ci(n)?l1(t,n,0,n.length-1):Ci(r.text)&&d2(t,""):r.text!==e.text&&(Ci(n)&&l1(t,n,0,n.length-1),d2(t,e.text)))}function Wce(r,e){if(pp(r,e))qf(r,e);else{var t=r.elm,n=L7(t);vg(e),n!==null&&(ku(n,e.elm,R7(t)),l1(n,[r],0,0))}return e}var Xce=0,qce=(function(){function r(e,t,n){if(this.type="svg",this.refreshHover=S3(),this.configLayer=S3(),this.storage=t,this._opts=n=ie({},n),this.root=e,this._id="zr"+Xce++,this._oldVNode=c3(n.width,n.height),e&&!n.ssr){var a=this._viewport=document.createElement("div");a.style.cssText="position:relative;overflow:hidden";var i=this._svgDom=this._oldVNode.elm=S7("svg");_N(null,this._oldVNode),a.appendChild(i),e.appendChild(a)}this.resize(n.width,n.height)}return r.prototype.getType=function(){return this.type},r.prototype.getViewportRoot=function(){return this._viewport},r.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},r.prototype.getSvgDom=function(){return this._svgDom},r.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style="position:absolute;left:0;top:0;user-select:none",Wce(this._oldVNode,e),this._oldVNode=e}},r.prototype.renderOneToVNode=function(e){return m3(e,bA(this._id))},r.prototype.renderToVNode=function(e){e=e||{};var t=this.storage.getDisplayList(!0),n=this._width,a=this._height,i=bA(this._id);i.animation=e.animation,i.willUpdate=e.willUpdate,i.compress=e.compress,i.emphasis=e.emphasis,i.ssr=this._opts.ssr;var o=[],s=this._bgVNode=Zce(n,a,this._backgroundColor,i);s&&o.push(s);var l=e.compress?null:this._mainVNode=Lr("g","main",{},[]);this._paintList(t,i,l?l.children:o),l&&o.push(l);var u=fe(it(i.defs),function(d){return i.defs[d]});if(u.length&&o.push(Lr("defs","defs",{},u)),e.animation){var c=Mce(i.cssNodes,i.cssAnims,{newline:!0});if(c){var f=Lr("style","stl",{},[],c);o.push(f)}}return c3(n,a,o,e.useViewBox)},r.prototype.renderToString=function(e){return e=e||{},mN(this.renderToVNode({animation:Ce(e.cssAnimation,!0),emphasis:Ce(e.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:Ce(e.useViewBox,!0)}),{newline:!0})},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e},r.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},r.prototype._paintList=function(e,t,n){for(var a=e.length,i=[],o=0,s,l,u=0,c=0;c<a;c++){var f=e[c];if(!f.invisible){var d=f.__clipPaths,v=d&&d.length||0,g=l&&l.length||0,y=void 0;for(y=Math.max(v-1,g-1);y>=0&&!(d&&l&&d[y]===l[y]);y--);for(var x=g-1;x>y;x--)o--,s=i[o-1];for(var b=y+1;b<v;b++){var w={};Gce(d[b],w,t);var T=Lr("g","clip-g-"+u++,w,[]);(s?s.children:n).push(T),i[o++]=T,s=T}l=d;var C=m3(f,t);C&&(s?s.children:n).push(C)}}},r.prototype.resize=function(e,t){var n=this._opts,a=this.root,i=this._viewport;if(e!=null&&(n.width=e),t!=null&&(n.height=t),a&&i&&(i.style.display="none",e=nh(a,0,n),t=nh(a,1,n),i.style.display=""),this._width!==e||this._height!==t){if(this._width=e,this._height=t,i){var o=i.style;o.width=e+"px",o.height=t+"px"}if(tD(this._backgroundColor))this.refresh();else{var s=this._svgDom;s&&(s.setAttribute("width",e),s.setAttribute("height",t));var l=this._bgVNode&&this._bgVNode.elm;l&&(l.setAttribute("width",e),l.setAttribute("height",t))}}},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r.prototype.dispose=function(){this.root&&(this.root.innerHTML=""),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},r.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},r.prototype.toDataURL=function(e){var t=this.renderToString(),n="data:image/svg+xml;";return e?(t=_re(t),t&&n+"base64,"+t):n+"charset=UTF-8,"+encodeURIComponent(t)},r})();function S3(r){return function(){}}function Zce(r,e,t,n){var a;if(t&&t!=="none")if(a=Lr("rect","bg",{width:r,height:e,x:"0",y:"0"}),H6(t))D7({fill:t},a.attrs,"fill",n);else if(tD(t))N7({style:{fill:t},dirty:Kt,getBoundingRect:function(){return{width:r,height:e}}},a.attrs,"fill",n);else{var i=Jp(t),o=i.color,s=i.opacity;a.attrs.fill=o,s<1&&(a.attrs["fill-opacity"]=s)}return a}function $ce(r){r.registerPainter("svg",qce)}function w3(r,e,t){var n=Bn.createCanvas(),a=e.getWidth(),i=e.getHeight(),o=n.style;return o&&(o.position="absolute",o.left="0",o.top="0",o.width=a+"px",o.height=i+"px",n.setAttribute("data-zr-dom-id",r)),n.width=a*t,n.height=i*t,n}var v2=(function(r){K(e,r);function e(t,n,a){var i=r.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 o;a=a||kx,typeof t=="string"?o=w3(t,n,a):Ee(t)&&(o=t,t=o.id),i.id=t,i.dom=o;var s=o.style;return s&&($M(o),o.onselectstart=function(){return!1},s.padding="0",s.margin="0",s.borderWidth="0"),i.painter=n,i.dpr=a,i}return e.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},e.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},e.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},e.prototype.setUnpainted=function(){this.__firstTimePaint=!0},e.prototype.createBackBuffer=function(){var t=this.dpr;this.domBack=w3("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),t!==1&&this.ctxBack.scale(t,t)},e.prototype.createRepaintRects=function(t,n,a,i){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var o=[],s=this.maxRepaintRectCount,l=!1,u=new Oe(0,0,0,0);function c(w){if(!(!w.isFinite()||w.isZero()))if(o.length===0){var T=new Oe(0,0,0,0);T.copy(w),o.push(T)}else{for(var C=!1,D=1/0,M=0,N=0;N<o.length;++N){var R=o[N];if(R.intersect(w)){var E=new Oe(0,0,0,0);E.copy(R),E.union(w),o[N]=E,C=!0;break}else if(l){u.copy(w),u.union(R);var k=w.width*w.height,I=R.width*R.height,B=u.width*u.height,P=B-k-I;P<D&&(D=P,M=N)}}if(l&&(o[M].union(w),C=!0),!C){var T=new Oe(0,0,0,0);T.copy(w),o.push(T)}l||(l=o.length>=s)}}for(var f=this.__startIndex;f<this.__endIndex;++f){var d=t[f];if(d){var v=d.shouldBePainted(a,i,!0,!0),g=d.__isRendered&&(d.__dirty&ea||!v)?d.getPrevPaintRect():null;g&&c(g);var y=v&&(d.__dirty&ea||!d.__isRendered)?d.getPaintRect():null;y&&c(y)}}for(var f=this.__prevStartIndex;f<this.__prevEndIndex;++f){var d=n[f],v=d&&d.shouldBePainted(a,i,!0,!0);if(d&&(!v||!d.__zr)&&d.__isRendered){var g=d.getPrevPaintRect();g&&c(g)}}var x;do{x=!1;for(var f=0;f<o.length;){if(o[f].isZero()){o.splice(f,1);continue}for(var b=f+1;b<o.length;)o[f].intersect(o[b])?(x=!0,o[f].union(o[b]),o.splice(b,1)):b++;f++}}while(x);return this._paintRects=o,o},e.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},e.prototype.resize=function(t,n){var a=this.dpr,i=this.dom,o=i.style,s=this.domBack;o&&(o.width=t+"px",o.height=n+"px"),i.width=t*a,i.height=n*a,s&&(s.width=t*a,s.height=n*a,a!==1&&this.ctxBack.scale(a,a))},e.prototype.clear=function(t,n,a){var i=this.dom,o=this.ctx,s=i.width,l=i.height;n=n||this.clearColor;var u=this.motionBlur&&!t,c=this.lastFrameAlpha,f=this.dpr,d=this;u&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(i,0,0,s/f,l/f));var v=this.domBack;function g(y,x,b,w){if(o.clearRect(y,x,b,w),n&&n!=="transparent"){var T=void 0;if(zg(n)){var C=n.global||n.__width===b&&n.__height===w;T=C&&n.__canvasGradient||nA(o,n,{x:0,y:0,width:b,height:w}),n.__canvasGradient=T,n.__width=b,n.__height=w}else y6(n)&&(n.scaleX=n.scaleX||f,n.scaleY=n.scaleY||f,T=aA(o,n,{dirty:function(){d.setUnpainted(),d.painter.refresh()}}));o.save(),o.fillStyle=T||n,o.fillRect(y,x,b,w),o.restore()}u&&(o.save(),o.globalAlpha=c,o.drawImage(v,y,x,b,w),o.restore())}!a||u?g(0,0,s,l):a.length&&O(a,function(y){g(y.x*f,y.y*f,y.width*f,y.height*f)})},e})(za),T3=1e5,wu=314159,f0=.01,Kce=.001;function Qce(r){return r?r.__builtin__?!0:!(typeof r.resize!="function"||typeof r.refresh!="function"):!1}function Jce(r,e){var t=document.createElement("div");return t.style.cssText=["position:relative","width:"+r+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",t}var efe=(function(){function r(e,t,n,a){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=ie({},n||{}),this.dpr=n.devicePixelRatio||kx,this._singleCanvas=i,this.root=e;var o=e.style;o&&($M(e),e.innerHTML=""),this.storage=t;var s=this._zlevelList;this._prevDisplayList=[];var l=this._layers;if(i){var c=e,f=c.width,d=c.height;n.width!=null&&(f=n.width),n.height!=null&&(d=n.height),this.dpr=n.devicePixelRatio||1,c.width=f*this.dpr,c.height=d*this.dpr,this._width=f,this._height=d;var v=new v2(c,this,this.dpr);v.__builtin__=!0,v.initContext(),l[wu]=v,v.zlevel=wu,s.push(wu),this._domRoot=e}else{this._width=nh(e,0,n),this._height=nh(e,1,n);var u=this._domRoot=Jce(this._width,this._height);e.appendChild(u)}}return r.prototype.getType=function(){return"canvas"},r.prototype.isSingleCanvas=function(){return this._singleCanvas},r.prototype.getViewportRoot=function(){return this._domRoot},r.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},r.prototype.refresh=function(e){var t=this.storage.getDisplayList(!0),n=this._prevDisplayList,a=this._zlevelList;this._redrawId=Math.random(),this._paintList(t,n,e,this._redrawId);for(var i=0;i<a.length;i++){var o=a[i],s=this._layers[o];if(!s.__builtin__&&s.refresh){var l=i===0?this._backgroundColor:null;s.refresh(l)}}return this._opts.useDirtyRect&&(this._prevDisplayList=t.slice()),this},r.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},r.prototype._paintHoverList=function(e){var t=e.length,n=this._hoverlayer;if(n&&n.clear(),!!t){for(var a={inHover:!0,viewWidth:this._width,viewHeight:this._height},i,o=0;o<t;o++){var s=e[o];s.__inHover&&(n||(n=this._hoverlayer=this.getLayer(T3)),i||(i=n.ctx,i.save()),Fu(i,s,a,o===t-1))}i&&i.restore()}},r.prototype.getHoverLayer=function(){return this.getLayer(T3)},r.prototype.paintOne=function(e,t){QD(e,t)},r.prototype._paintList=function(e,t,n,a){if(this._redrawId===a){n=n||!1,this._updateLayerStatus(e);var i=this._doPaintList(e,t,n),o=i.finished,s=i.needsRefreshHover;if(this._needsManuallyCompositing&&this._compositeManually(),s&&this._paintHoverList(e),o)this.eachLayer(function(u){u.afterBrush&&u.afterBrush()});else{var l=this;Mx(function(){l._paintList(e,t,n,a)})}}},r.prototype._compositeManually=function(){var e=this.getLayer(wu).ctx,t=this._domRoot.width,n=this._domRoot.height;e.clearRect(0,0,t,n),this.eachBuiltinLayer(function(a){a.virtual&&e.drawImage(a.dom,0,0,t,n)})},r.prototype._doPaintList=function(e,t,n){for(var a=this,i=[],o=this._opts.useDirtyRect,s=0;s<this._zlevelList.length;s++){var l=this._zlevelList[s],u=this._layers[l];u.__builtin__&&u!==this._hoverlayer&&(u.__dirty||n)&&i.push(u)}for(var c=!0,f=!1,d=function(y){var x=i[y],b=x.ctx,w=o&&x.createRepaintRects(e,t,v._width,v._height),T=n?x.__startIndex:x.__drawIndex,C=!n&&x.incremental&&Date.now,D=C&&Date.now(),M=x.zlevel===v._zlevelList[0]?v._backgroundColor:null;if(x.__startIndex===x.__endIndex)x.clear(!1,M,w);else if(T===x.__startIndex){var N=e[T];(!N.incremental||!N.notClear||n)&&x.clear(!1,M,w)}T===-1&&(console.error("For some unknown reason. drawIndex is -1"),T=x.__startIndex);var R,E=function(P){var H={inHover:!1,allClipped:!1,prevEl:null,viewWidth:a._width,viewHeight:a._height};for(R=T;R<x.__endIndex;R++){var V=e[R];if(V.__inHover&&(f=!0),a._doPaintEl(V,x,o,P,H,R===x.__endIndex-1),C){var j=Date.now()-D;if(j>15)break}}H.prevElClipPaths&&b.restore()};if(w)if(w.length===0)R=x.__endIndex;else for(var k=v.dpr,I=0;I<w.length;++I){var B=w[I];b.save(),b.beginPath(),b.rect(B.x*k,B.y*k,B.width*k,B.height*k),b.clip(),E(B),b.restore()}else b.save(),E(),b.restore();x.__drawIndex=R,x.__drawIndex<x.__endIndex&&(c=!1)},v=this,g=0;g<i.length;g++)d(g);return nt.wxa&&O(this._layers,function(y){y&&y.ctx&&y.ctx.draw&&y.ctx.draw()}),{finished:c,needsRefreshHover:f}},r.prototype._doPaintEl=function(e,t,n,a,i,o){var s=t.ctx;if(n){var l=e.getPaintRect();(!a||l&&l.intersect(a))&&(Fu(s,e,i,o),e.setPrevPaintRect(l))}else Fu(s,e,i,o)},r.prototype.getLayer=function(e,t){this._singleCanvas&&!this._needsManuallyCompositing&&(e=wu);var n=this._layers[e];return n||(n=new v2("zr_"+e,this,this.dpr),n.zlevel=e,n.__builtin__=!0,this._layerConfig[e]?Ye(n,this._layerConfig[e],!0):this._layerConfig[e-f0]&&Ye(n,this._layerConfig[e-f0],!0),t&&(n.virtual=t),this.insertLayer(e,n),n.initContext()),n},r.prototype.insertLayer=function(e,t){var n=this._layers,a=this._zlevelList,i=a.length,o=this._domRoot,s=null,l=-1;if(!n[e]&&Qce(t)){if(i>0&&e>a[0]){for(l=0;l<i-1&&!(a[l]<e&&a[l+1]>e);l++);s=n[a[l]]}if(a.splice(l+1,0,e),n[e]=t,!t.virtual)if(s){var u=s.dom;u.nextSibling?o.insertBefore(t.dom,u.nextSibling):o.appendChild(t.dom)}else o.firstChild?o.insertBefore(t.dom,o.firstChild):o.appendChild(t.dom);t.painter||(t.painter=this)}},r.prototype.eachLayer=function(e,t){for(var n=this._zlevelList,a=0;a<n.length;a++){var i=n[a];e.call(t,this._layers[i],i)}},r.prototype.eachBuiltinLayer=function(e,t){for(var n=this._zlevelList,a=0;a<n.length;a++){var i=n[a],o=this._layers[i];o.__builtin__&&e.call(t,o,i)}},r.prototype.eachOtherLayer=function(e,t){for(var n=this._zlevelList,a=0;a<n.length;a++){var i=n[a],o=this._layers[i];o.__builtin__||e.call(t,o,i)}},r.prototype.getLayers=function(){return this._layers},r.prototype._updateLayerStatus=function(e){this.eachBuiltinLayer(function(f,d){f.__dirty=f.__used=!1});function t(f){i&&(i.__endIndex!==f&&(i.__dirty=!0),i.__endIndex=f)}if(this._singleCanvas)for(var n=1;n<e.length;n++){var a=e[n];if(a.zlevel!==e[n-1].zlevel||a.incremental){this._needsManuallyCompositing=!0;break}}var i=null,o=0,s,l;for(l=0;l<e.length;l++){var a=e[l],u=a.zlevel,c=void 0;s!==u&&(s=u,o=0),a.incremental?(c=this.getLayer(u+Kce,this._needsManuallyCompositing),c.incremental=!0,o=1):c=this.getLayer(u+(o>0?f0:0),this._needsManuallyCompositing),c.__builtin__||Y1("ZLevel "+u+" has been used by unkown layer "+c.id),c!==i&&(c.__used=!0,c.__startIndex!==l&&(c.__dirty=!0),c.__startIndex=l,c.incremental?c.__drawIndex=-1:c.__drawIndex=l,t(l),i=c),a.__dirty&ea&&!a.__inHover&&(c.__dirty=!0,c.incremental&&c.__drawIndex<0&&(c.__drawIndex=l))}t(l),this.eachBuiltinLayer(function(f,d){!f.__used&&f.getElementCount()>0&&(f.__dirty=!0,f.__startIndex=f.__endIndex=f.__drawIndex=0),f.__dirty&&f.__drawIndex<0&&(f.__drawIndex=f.__startIndex)})},r.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},r.prototype._clearLayer=function(e){e.clear()},r.prototype.setBackgroundColor=function(e){this._backgroundColor=e,O(this._layers,function(t){t.setUnpainted()})},r.prototype.configLayer=function(e,t){if(t){var n=this._layerConfig;n[e]?Ye(n[e],t,!0):n[e]=t;for(var a=0;a<this._zlevelList.length;a++){var i=this._zlevelList[a];if(i===e||i===e+f0){var o=this._layers[i];Ye(o,n[e],!0)}}}},r.prototype.delLayer=function(e){var t=this._layers,n=this._zlevelList,a=t[e];a&&(a.dom.parentNode.removeChild(a.dom),delete t[e],n.splice(Fe(n,e),1))},r.prototype.resize=function(e,t){if(this._domRoot.style){var n=this._domRoot;n.style.display="none";var a=this._opts,i=this.root;if(e!=null&&(a.width=e),t!=null&&(a.height=t),e=nh(i,0,a),t=nh(i,1,a),n.style.display="",this._width!==e||t!==this._height){n.style.width=e+"px",n.style.height=t+"px";for(var o in this._layers)this._layers.hasOwnProperty(o)&&this._layers[o].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(wu).resize(e,t)}return this},r.prototype.clearLayer=function(e){var t=this._layers[e];t&&t.clear()},r.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},r.prototype.getRenderedCanvas=function(e){if(e=e||{},this._singleCanvas&&!this._compositeManually)return this._layers[wu].dom;var t=new v2("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 a=t.dom.width,i=t.dom.height;this.eachLayer(function(f){f.__builtin__?n.drawImage(f.dom,0,0,a,i):f.renderToCanvas&&(n.save(),f.renderToCanvas(n),n.restore())})}else for(var o={inHover:!1,viewWidth:this._width,viewHeight:this._height},s=this.storage.getDisplayList(!0),l=0,u=s.length;l<u;l++){var c=s[l];Fu(n,c,o,l===u-1)}return t.dom},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r})();function tfe(r){r.registerPainter("canvas",efe)}var rfe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t){return to(null,this,{useEncodeDefaulter:!0})},e.prototype.getLegendIcon=function(t){var n=new Ne,a=ur("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1);n.add(a),a.setStyle(t.lineStyle);var i=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),s=i==="none"?"circle":i,l=t.itemHeight*.8,u=ur(s,(t.itemWidth-l)/2,(t.itemHeight-l)/2,l,l,t.itemStyle.fill);n.add(u),u.setStyle(t.itemStyle);var c=t.iconRotate==="inherit"?o:t.iconRotate||0;return u.rotation=c*Math.PI/180,u.setOrigin([t.itemWidth/2,t.itemHeight/2]),s.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill=ee.color.neutral00,u.style.lineWidth=2),n},e.type="series.line",e.dependencies=["grid","polar"],e.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:6,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},e})(Ct);function Gh(r,e){var t=r.mapDimensionsAll("defaultedLabel"),n=t.length;if(n===1){var a=jh(r,e,t[0]);return a!=null?a+"":null}else if(n){for(var i=[],o=0;o<t.length;o++)i.push(jh(r,e,t[o]));return i.join(" ")}}function k7(r,e){var t=r.mapDimensionsAll("defaultedLabel");if(!ce(e))return e+"";for(var n=[],a=0;a<t.length;a++){var i=r.getDimensionIndex(t[a]);i>=0&&n.push(e[i])}return n.join(" ")}var Jg=(function(r){K(e,r);function e(t,n,a,i){var o=r.call(this)||this;return o.updateData(t,n,a,i),o}return e.prototype._createSymbol=function(t,n,a,i,o,s){this.removeAll();var l=ur(t,-1,-1,2,2,null,s);l.attr({z2:Ce(o,100),culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),l.drift=nfe,this._symbolType=t,this.add(l)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){$o(this.childAt(0))},e.prototype.downplay=function(){Ko(this.childAt(0))},e.prototype.setZ=function(t,n){var a=this.childAt(0);a.zlevel=t,a.z=n},e.prototype.setDraggable=function(t,n){var a=this.childAt(0);a.draggable=t,a.cursor=!n&&t?"move":a.cursor},e.prototype.updateData=function(t,n,a,i){this.silent=!1;var o=t.getItemVisual(n,"symbol")||"circle",s=t.hostModel,l=e.getSymbolSize(t,n),u=e.getSymbolZ2(t,n),c=o!==this._symbolType,f=i&&i.disableAnimation;if(c){var d=t.getItemVisual(n,"symbolKeepAspect");this._createSymbol(o,t,n,l,u,d)}else{var v=this.childAt(0);v.silent=!1;var g={scaleX:l[0]/2,scaleY:l[1]/2};f?v.attr(g):lt(v,g,s,n),ja(v)}if(this._updateCommon(t,n,l,a,i),c){var v=this.childAt(0);if(!f){var g={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:v.style.opacity}};v.scaleX=v.scaleY=0,v.style.opacity=0,zt(v,g,s,n)}}f&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,n,a,i,o){var s=this.childAt(0),l=t.hostModel,u,c,f,d,v,g,y,x,b;if(i&&(u=i.emphasisItemStyle,c=i.blurItemStyle,f=i.selectItemStyle,d=i.focus,v=i.blurScope,y=i.labelStatesModels,x=i.hoverScale,b=i.cursorStyle,g=i.emphasisDisabled),!i||t.hasItemOption){var w=i&&i.itemModel?i.itemModel:t.getItemModel(n),T=w.getModel("emphasis");u=T.getModel("itemStyle").getItemStyle(),f=w.getModel(["select","itemStyle"]).getItemStyle(),c=w.getModel(["blur","itemStyle"]).getItemStyle(),d=T.get("focus"),v=T.get("blurScope"),g=T.get("disabled"),y=Sr(w),x=T.getShallow("scale"),b=w.getShallow("cursor")}var C=t.getItemVisual(n,"symbolRotate");s.attr("rotation",(C||0)*Math.PI/180||0);var D=Tc(t.getItemVisual(n,"symbolOffset"),a);D&&(s.x=D[0],s.y=D[1]),b&&s.attr("cursor",b);var M=t.getItemVisual(n,"style"),N=M.fill;if(s instanceof Ir){var R=s.style;s.useStyle(ie({image:R.image,x:R.x,y:R.y,width:R.width,height:R.height},M))}else s.__isEmptyBrush?s.useStyle(ie({},M)):s.useStyle(M),s.style.decal=null,s.setColor(N,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var E=t.getItemVisual(n,"liftZ"),k=this._z2;E!=null?k==null&&(this._z2=s.z2,s.z2+=E):k!=null&&(s.z2=k,this._z2=null);var I=o&&o.useNameLabel;kr(s,y,{labelFetcher:l,labelDataIndex:n,defaultText:B,inheritColor:N,defaultOpacity:M.opacity});function B(V){return I?t.getName(V):Gh(t,V)}this._sizeX=a[0]/2,this._sizeY=a[1]/2;var P=s.ensureState("emphasis");P.style=u,s.ensureState("select").style=f,s.ensureState("blur").style=c;var H=x==null||x===!0?Math.max(1.1,3/this._sizeY):isFinite(x)&&x>0?+x:1;P.scaleX=this._sizeX*H,P.scaleY=this._sizeY*H,this.setSymbolScale(1),Ut(this,d,v,g)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,n,a){var i=this.childAt(0),o=je(this).dataIndex,s=a&&a.animation;if(this.silent=i.silent=!0,a&&a.fadeLabel){var l=i.getTextContent();l&&Sl(l,{style:{opacity:0}},n,{dataIndex:o,removeOpt:s,cb:function(){i.removeTextContent()}})}else i.removeTextContent();Sl(i,{style:{opacity:0},scaleX:0,scaleY:0},n,{dataIndex:o,cb:t,removeOpt:s})},e.getSymbolSize=function(t,n){return fd(t.getItemVisual(n,"symbolSize"))},e.getSymbolZ2=function(t,n){return t.getItemVisual(n,"z2")},e})(Ne);function nfe(r,e){this.parent.drift(r,e)}function p2(r,e,t,n){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(n.isIgnore&&n.isIgnore(t))&&!(n.clipShape&&!n.clipShape.contain(e[0],e[1]))&&r.getItemVisual(t,"symbol")!=="none"}function C3(r){return r!=null&&!Ee(r)&&(r={isIgnore:r}),r||{}}function A3(r){var e=r.hostModel,t=e.getModel("emphasis");return{emphasisItemStyle:t.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:t.get("focus"),blurScope:t.get("blurScope"),emphasisDisabled:t.get("disabled"),hoverScale:t.get("scale"),labelStatesModels:Sr(e),cursorStyle:e.get("cursor")}}var em=(function(){function r(e){this.group=new Ne,this._SymbolCtor=e||Jg}return r.prototype.updateData=function(e,t){this._progressiveEls=null,t=C3(t);var n=this.group,a=e.hostModel,i=this._data,o=this._SymbolCtor,s=t.disableAnimation,l=A3(e),u={disableAnimation:s},c=t.getSymbolPoint||function(f){return e.getItemLayout(f)};i||n.removeAll(),e.diff(i).add(function(f){var d=c(f);if(p2(e,d,f,t)){var v=new o(e,f,l,u);v.setPosition(d),e.setItemGraphicEl(f,v),n.add(v)}}).update(function(f,d){var v=i.getItemGraphicEl(d),g=c(f);if(!p2(e,g,f,t)){n.remove(v);return}var y=e.getItemVisual(f,"symbol")||"circle",x=v&&v.getSymbolType&&v.getSymbolType();if(!v||x&&x!==y)n.remove(v),v=new o(e,f,l,u),v.setPosition(g);else{v.updateData(e,f,l,u);var b={x:g[0],y:g[1]};s?v.attr(b):lt(v,b,a)}n.add(v),e.setItemGraphicEl(f,v)}).remove(function(f){var d=i.getItemGraphicEl(f);d&&d.fadeOut(function(){n.remove(d)},a)}).execute(),this._getSymbolPoint=c,this._data=e},r.prototype.updateLayout=function(){var e=this,t=this._data;t&&t.eachItemGraphicEl(function(n,a){var i=e._getSymbolPoint(a);n.setPosition(i),n.markRedraw()})},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=A3(e),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t,n){this._progressiveEls=[],n=C3(n);function a(l){l.isGroup||(l.incremental=!0,l.ensureState("emphasis").hoverLayer=!0)}for(var i=e.start;i<e.end;i++){var o=t.getItemLayout(i);if(p2(t,o,i,n)){var s=new this._SymbolCtor(t,i,this._seriesScope);s.traverse(a),s.setPosition(o),this.group.add(s),t.setItemGraphicEl(i,s),this._progressiveEls.push(s)}}},r.prototype.eachRendered=function(e){Ll(this._progressiveEls||this.group,e)},r.prototype.remove=function(e){var t=this.group,n=this._data;n&&e?n.eachItemGraphicEl(function(a){a.fadeOut(function(){t.remove(a)},n.hostModel)}):t.removeAll()},r})();function I7(r,e,t){var n=r.getBaseAxis(),a=r.getOtherAxis(n),i=afe(a,t),o=n.dim,s=a.dim,l=e.mapDimension(s),u=e.mapDimension(o),c=s==="x"||s==="radius"?1:0,f=fe(r.dimensions,function(g){return e.mapDimension(g)}),d=!1,v=e.getCalculationInfo("stackResultDimension");return Jo(e,f[0])&&(d=!0,f[0]=v),Jo(e,f[1])&&(d=!0,f[1]=v),{dataDimsForPoint:f,valueStart:i,valueAxisDim:s,baseAxisDim:o,stacked:!!d,valueDim:l,baseDim:u,baseDataOffset:c,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function afe(r,e){var t=0,n=r.scale.getExtent();return e==="start"?t=n[0]:e==="end"?t=n[1]:st(e)&&!isNaN(e)?t=e:n[0]>0?t=n[0]:n[1]<0&&(t=n[1]),t}function O7(r,e,t,n){var a=NaN;r.stacked&&(a=t.get(t.getCalculationInfo("stackedOverDimension"),n)),isNaN(a)&&(a=r.valueStart);var i=r.baseDataOffset,o=[];return o[i]=t.get(r.baseDim,n),o[1-i]=a,e.dataToPoint(o)}function ife(r,e){var t=[];return e.diff(r).add(function(n){t.push({cmd:"+",idx:n})}).update(function(n,a){t.push({cmd:"=",idx:a,idx1:n})}).remove(function(n){t.push({cmd:"-",idx:n})}).execute(),t}function ofe(r,e,t,n,a,i,o,s){for(var l=ife(r,e),u=[],c=[],f=[],d=[],v=[],g=[],y=[],x=I7(a,e,o),b=r.getLayout("points")||[],w=e.getLayout("points")||[],T=0;T<l.length;T++){var C=l[T],D=!0,M=void 0,N=void 0;switch(C.cmd){case"=":M=C.idx*2,N=C.idx1*2;var R=b[M],E=b[M+1],k=w[N],I=w[N+1];(isNaN(R)||isNaN(E))&&(R=k,E=I),u.push(R,E),c.push(k,I),f.push(t[M],t[M+1]),d.push(n[N],n[N+1]),y.push(e.getRawIndex(C.idx1));break;case"+":var B=C.idx,P=x.dataDimsForPoint,H=a.dataToPoint([e.get(P[0],B),e.get(P[1],B)]);N=B*2,u.push(H[0],H[1]),c.push(w[N],w[N+1]);var V=O7(x,a,e,B);f.push(V[0],V[1]),d.push(n[N],n[N+1]),y.push(e.getRawIndex(B));break;case"-":D=!1}D&&(v.push(C),g.push(g.length))}g.sort(function(ge,Se){return y[ge]-y[Se]});for(var j=u.length,U=zi(j),F=zi(j),X=zi(j),G=zi(j),W=[],T=0;T<g.length;T++){var $=g[T],te=T*2,ue=$*2;U[te]=u[ue],U[te+1]=u[ue+1],F[te]=c[ue],F[te+1]=c[ue+1],X[te]=f[ue],X[te+1]=f[ue+1],G[te]=d[ue],G[te+1]=d[ue+1],W[T]=v[$]}return{current:U,next:F,stackedOnCurrent:X,stackedOnNext:G,status:W}}var zs=Math.min,Bs=Math.max;function ac(r,e){return isNaN(r)||isNaN(e)}function SA(r,e,t,n,a,i,o,s,l){for(var u,c,f,d,v,g,y=t,x=0;x<n;x++){var b=e[y*2],w=e[y*2+1];if(y>=a||y<0)break;if(ac(b,w)){if(l){y+=i;continue}break}if(y===t)r[i>0?"moveTo":"lineTo"](b,w),f=b,d=w;else{var T=b-u,C=w-c;if(T*T+C*C<.5){y+=i;continue}if(o>0){for(var D=y+i,M=e[D*2],N=e[D*2+1];M===b&&N===w&&x<n;)x++,D+=i,y+=i,M=e[D*2],N=e[D*2+1],b=e[y*2],w=e[y*2+1],T=b-u,C=w-c;var R=x+1;if(l)for(;ac(M,N)&&R<n;)R++,D+=i,M=e[D*2],N=e[D*2+1];var E=.5,k=0,I=0,B=void 0,P=void 0;if(R>=n||ac(M,N))v=b,g=w;else{k=M-u,I=N-c;var H=b-u,V=M-b,j=w-c,U=N-w,F=void 0,X=void 0;if(s==="x"){F=Math.abs(H),X=Math.abs(V);var G=k>0?1:-1;v=b-G*F*o,g=w,B=b+G*X*o,P=w}else if(s==="y"){F=Math.abs(j),X=Math.abs(U);var W=I>0?1:-1;v=b,g=w-W*F*o,B=b,P=w+W*X*o}else F=Math.sqrt(H*H+j*j),X=Math.sqrt(V*V+U*U),E=X/(X+F),v=b-k*o*(1-E),g=w-I*o*(1-E),B=b+k*o*E,P=w+I*o*E,B=zs(B,Bs(M,b)),P=zs(P,Bs(N,w)),B=Bs(B,zs(M,b)),P=Bs(P,zs(N,w)),k=B-b,I=P-w,v=b-k*F/X,g=w-I*F/X,v=zs(v,Bs(u,b)),g=zs(g,Bs(c,w)),v=Bs(v,zs(u,b)),g=Bs(g,zs(c,w)),k=b-v,I=w-g,B=b+k*X/F,P=w+I*X/F}r.bezierCurveTo(f,d,v,g,b,w),f=B,d=P}else r.lineTo(b,w)}u=b,c=w,y+=i}return x}var P7=(function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r})(),sfe=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="ec-polyline",n}return e.prototype.getDefaultStyle=function(){return{stroke:ee.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new P7},e.prototype.buildPath=function(t,n){var a=n.points,i=0,o=a.length/2;if(n.connectNulls){for(;o>0&&ac(a[o*2-2],a[o*2-1]);o--);for(;i<o&&ac(a[i*2],a[i*2+1]);i++);}for(;i<o;)i+=SA(t,a,i,o,o,1,n.smooth,n.smoothMonotone,n.connectNulls)+1},e.prototype.getPointOn=function(t,n){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var a=this.path,i=a.data,o=qi.CMD,s,l,u=n==="x",c=[],f=0;f<i.length;){var d=i[f++],v=void 0,g=void 0,y=void 0,x=void 0,b=void 0,w=void 0,T=void 0;switch(d){case o.M:s=i[f++],l=i[f++];break;case o.L:if(v=i[f++],g=i[f++],T=u?(t-s)/(v-s):(t-l)/(g-l),T<=1&&T>=0){var C=u?(g-l)*T+l:(v-s)*T+s;return u?[t,C]:[C,t]}s=v,l=g;break;case o.C:v=i[f++],g=i[f++],y=i[f++],x=i[f++],b=i[f++],w=i[f++];var D=u?Nx(s,v,y,b,t,c):Nx(l,g,x,w,t,c);if(D>0)for(var M=0;M<D;M++){var N=c[M];if(N<=1&&N>=0){var C=u?Nr(l,g,x,w,N):Nr(s,v,y,b,N);return u?[t,C]:[C,t]}}s=b,l=w;break}}},e})(tt),lfe=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(P7),j7=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="ec-polygon",n}return e.prototype.getDefaultShape=function(){return new lfe},e.prototype.buildPath=function(t,n){var a=n.points,i=n.stackedOnPoints,o=0,s=a.length/2,l=n.smoothMonotone;if(n.connectNulls){for(;s>0&&ac(a[s*2-2],a[s*2-1]);s--);for(;o<s&&ac(a[o*2],a[o*2+1]);o++);}for(;o<s;){var u=SA(t,a,o,s,s,1,n.smooth,l,n.connectNulls);SA(t,i,o+u-1,u,s,-1,n.stackedOnSmooth,l,n.connectNulls),o+=u+1,t.closePath()}},e})(tt);function z7(r,e,t,n,a){var i=r.getArea(),o=i.x,s=i.y,l=i.width,u=i.height,c=t.get(["lineStyle","width"])||0;o-=c/2,s-=c/2,l+=c,u+=c,l=Math.ceil(l),o!==Math.floor(o)&&(o=Math.floor(o),l++);var f=new qe({shape:{x:o,y:s,width:l,height:u}});if(e){var d=r.getBaseAxis(),v=d.isHorizontal(),g=d.inverse;v?(g&&(f.shape.x+=l),f.shape.width=0):(g||(f.shape.y+=u),f.shape.height=0);var y=Me(a)?function(x){a(x,f)}:null;zt(f,{shape:{width:l,height:u,x:o,y:s}},t,null,n,y)}return f}function B7(r,e,t){var n=r.getArea(),a=sr(n.r0,1),i=sr(n.r,1),o=new nn({shape:{cx:sr(r.cx,1),cy:sr(r.cy,1),r0:a,r:i,startAngle:n.startAngle,endAngle:n.endAngle,clockwise:n.clockwise}});if(e){var s=r.getBaseAxis().dim==="angle";s?o.shape.endAngle=n.startAngle:o.shape.r=a,zt(o,{shape:{endAngle:n.endAngle,r:i}},t)}return o}function tm(r,e,t,n,a){if(r){if(r.type==="polar")return B7(r,e,t);if(r.type==="cartesian2d")return z7(r,e,t,n,a)}else return null;return null}function wl(r,e){return r.type===e}function M3(r,e){if(r.length===e.length){for(var t=0;t<r.length;t++)if(r[t]!==e[t])return;return!0}}function D3(r){for(var e=1/0,t=1/0,n=-1/0,a=-1/0,i=0;i<r.length;){var o=r[i++],s=r[i++];isNaN(o)||(e=Math.min(o,e),n=Math.max(o,n)),isNaN(s)||(t=Math.min(s,t),a=Math.max(s,a))}return[[e,t],[n,a]]}function N3(r,e){var t=D3(r),n=t[0],a=t[1],i=D3(e),o=i[0],s=i[1];return Math.max(Math.abs(n[0]-o[0]),Math.abs(n[1]-o[1]),Math.abs(a[0]-s[0]),Math.abs(a[1]-s[1]))}function L3(r){return st(r)?r:r?.5:0}function ufe(r,e,t){if(!t.valueDim)return[];for(var n=e.count(),a=zi(n*2),i=0;i<n;i++){var o=O7(t,r,e,i);a[i*2]=o[0],a[i*2+1]=o[1]}return a}function Vs(r,e,t,n,a){var i=t.getBaseAxis(),o=i.dim==="x"||i.dim==="radius"?0:1,s=[],l=0,u=[],c=[],f=[],d=[];if(a){for(l=0;l<r.length;l+=2){var v=e||r;!isNaN(v[l])&&!isNaN(v[l+1])&&d.push(r[l],r[l+1])}r=d}for(l=0;l<r.length-2;l+=2)switch(f[0]=r[l+2],f[1]=r[l+3],c[0]=r[l],c[1]=r[l+1],s.push(c[0],c[1]),n){case"end":u[o]=f[o],u[1-o]=c[1-o],s.push(u[0],u[1]);break;case"middle":var g=(c[o]+f[o])/2,y=[];u[o]=y[o]=g,u[1-o]=c[1-o],y[1-o]=f[1-o],s.push(u[0],u[1]),s.push(y[0],y[1]);break;default:u[o]=c[o],u[1-o]=f[1-o],s.push(u[0],u[1])}return s.push(r[l++],r[l++]),s}function cfe(r,e){var t=[],n=r.length,a,i;function o(c,f,d){var v=c.coord,g=(d-v)/(f.coord-v),y=eD(g,[c.color,f.color]);return{coord:d,color:y}}for(var s=0;s<n;s++){var l=r[s],u=l.coord;if(u<0)a=l;else if(u>e){i?t.push(o(i,l,e)):a&&t.push(o(a,l,0),o(a,l,e));break}else a&&(t.push(o(a,l,0)),a=null),t.push(l),i=l}return t}function ffe(r,e,t){var n=r.getVisual("visualMeta");if(!(!n||!n.length||!r.count())&&e.type==="cartesian2d"){for(var a,i,o=n.length-1;o>=0;o--){var s=r.getDimensionInfo(n[o].dimension);if(a=s&&s.coordDim,a==="x"||a==="y"){i=n[o];break}}if(i){var l=e.getAxis(a),u=fe(i.stops,function(T){return{coord:l.toGlobalCoord(l.dataToCoord(T.value)),color:T.color}}),c=u.length,f=i.outerColors.slice();c&&u[0].coord>u[c-1].coord&&(u.reverse(),f.reverse());var d=cfe(u,a==="x"?t.getWidth():t.getHeight()),v=d.length;if(!v&&c)return u[0].coord<0?f[1]?f[1]:u[c-1].color:f[0]?f[0]:u[0].color;var g=10,y=d[0].coord-g,x=d[v-1].coord+g,b=x-y;if(b<.001)return"transparent";O(d,function(T){T.offset=(T.coord-y)/b}),d.push({offset:v?d[v-1].offset:.5,color:f[1]||"transparent"}),d.unshift({offset:v?d[0].offset:.5,color:f[0]||"transparent"});var w=new bc(0,0,0,0,d,!0);return w[a]=y,w[a+"2"]=x,w}}}function hfe(r,e,t){var n=r.get("showAllSymbol"),a=n==="auto";if(!(n&&!a)){var i=t.getAxesByScale("ordinal")[0];if(i&&!(a&&dfe(i,e))){var o=e.mapDimension(i.dim),s={};return O(i.getViewLabels(),function(l){var u=i.scale.getRawOrdinalNumber(l.tickValue);s[u]=1}),function(l){return!s.hasOwnProperty(e.get(o,l))}}}}function dfe(r,e){var t=r.getExtent(),n=Math.abs(t[1]-t[0])/r.scale.count();isNaN(n)&&(n=0);for(var a=e.count(),i=Math.max(1,Math.round(a/5)),o=0;o<a;o+=i)if(Jg.getSymbolSize(e,o)[r.isHorizontal()?1:0]*1.5>n)return!1;return!0}function vfe(r,e){return isNaN(r)||isNaN(e)}function pfe(r){for(var e=r.length/2;e>0&&vfe(r[e*2-2],r[e*2-1]);e--);return e-1}function R3(r,e){return[r[e*2],r[e*2+1]]}function gfe(r,e,t){for(var n=r.length/2,a=t==="x"?0:1,i,o,s=0,l=-1,u=0;u<n;u++)if(o=r[u*2+a],!(isNaN(o)||isNaN(r[u*2+1-a]))){if(u===0){i=o;continue}if(i<=e&&o>=e||i>=e&&o<=e){l=u;break}s=u,i=o}return{range:[s,l],t:(e-i)/(o-i)}}function V7(r){if(r.get(["endLabel","show"]))return!0;for(var e=0;e<Cn.length;e++)if(r.get([Cn[e],"endLabel","show"]))return!0;return!1}function g2(r,e,t,n){if(wl(e,"cartesian2d")){var a=n.getModel("endLabel"),i=a.get("valueAnimation"),o=n.getData(),s={lastFrameIndex:0},l=V7(n)?function(v,g){r._endLabelOnDuring(v,g,o,s,i,a,e)}:null,u=e.getBaseAxis().isHorizontal(),c=z7(e,t,n,function(){var v=r._endLabel;v&&t&&s.originalX!=null&&v.attr({x:s.originalX,y:s.originalY})},l);if(!n.get("clip",!0)){var f=c.shape,d=Math.max(f.width,f.height);u?(f.y-=d,f.height+=d*2):(f.x-=d,f.width+=d*2)}return l&&l(1,c),c}else return B7(e,t,n)}function mfe(r,e){var t=e.getBaseAxis(),n=t.isHorizontal(),a=t.inverse,i=n?a?"right":"left":"center",o=n?"middle":a?"top":"bottom";return{normal:{align:r.get("align")||i,verticalAlign:r.get("verticalAlign")||o}}}var yfe=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(){var t=new Ne,n=new em;this.group.add(n.group),this._symbolDraw=n,this._lineGroup=t,this._changePolyState=xe(this._changePolyState,this)},e.prototype.render=function(t,n,a){var i=t.coordinateSystem,o=this.group,s=t.getData(),l=t.getModel("lineStyle"),u=t.getModel("areaStyle"),c=s.getLayout("points")||[],f=i.type==="polar",d=this._coordSys,v=this._symbolDraw,g=this._polyline,y=this._polygon,x=this._lineGroup,b=!n.ssr&&t.get("animation"),w=!u.isEmpty(),T=u.get("origin"),C=I7(i,s,T),D=w&&ufe(i,s,C),M=t.get("showSymbol"),N=t.get("connectNulls"),R=M&&!f&&hfe(t,s,i),E=this._data;E&&E.eachItemGraphicEl(function(ge,Se){ge.__temp&&(o.remove(ge),E.setItemGraphicEl(Se,null))}),M||v.remove(),o.add(x);var k=f?!1:t.get("step"),I;i&&i.getArea&&t.get("clip",!0)&&(I=i.getArea(),I.width!=null?(I.x-=.1,I.y-=.1,I.width+=.2,I.height+=.2):I.r0&&(I.r0-=.5,I.r+=.5)),this._clipShapeForSymbol=I;var B=ffe(s,i,a)||s.getVisual("style")[s.getVisual("drawType")];if(!(g&&d.type===i.type&&k===this._step))M&&v.updateData(s,{isIgnore:R,clipShape:I,disableAnimation:!0,getSymbolPoint:function(ge){return[c[ge*2],c[ge*2+1]]}}),b&&this._initSymbolLabelAnimation(s,i,I),k&&(D&&(D=Vs(D,c,i,k,N)),c=Vs(c,null,i,k,N)),g=this._newPolyline(c),w?y=this._newPolygon(c,D):y&&(x.remove(y),y=this._polygon=null),f||this._initOrUpdateEndLabel(t,i,vc(B)),x.setClipPath(g2(this,i,!0,t));else{w&&!y?y=this._newPolygon(c,D):y&&!w&&(x.remove(y),y=this._polygon=null),f||this._initOrUpdateEndLabel(t,i,vc(B));var P=x.getClipPath();if(P){var H=g2(this,i,!1,t);zt(P,{shape:H.shape},t)}else x.setClipPath(g2(this,i,!0,t));M&&v.updateData(s,{isIgnore:R,clipShape:I,disableAnimation:!0,getSymbolPoint:function(ge){return[c[ge*2],c[ge*2+1]]}}),(!M3(this._stackedOnPoints,D)||!M3(this._points,c))&&(b?this._doUpdateAnimation(s,D,i,a,k,T,N):(k&&(D&&(D=Vs(D,c,i,k,N)),c=Vs(c,null,i,k,N)),g.setShape({points:c}),y&&y.setShape({points:c,stackedOnPoints:D})))}var V=t.getModel("emphasis"),j=V.get("focus"),U=V.get("blurScope"),F=V.get("disabled");if(g.useStyle(Re(l.getLineStyle(),{fill:"none",stroke:B,lineJoin:"bevel"})),_r(g,t,"lineStyle"),g.style.lineWidth>0&&t.get(["emphasis","lineStyle","width"])==="bolder"){var X=g.getState("emphasis").style;X.lineWidth=+g.style.lineWidth+1}je(g).seriesIndex=t.seriesIndex,Ut(g,j,U,F);var G=L3(t.get("smooth")),W=t.get("smoothMonotone");if(g.setShape({smooth:G,smoothMonotone:W,connectNulls:N}),y){var $=s.getCalculationInfo("stackedOnSeries"),te=0;y.useStyle(Re(u.getAreaStyle(),{fill:B,opacity:.7,lineJoin:"bevel",decal:s.getVisual("style").decal})),$&&(te=L3($.get("smooth"))),y.setShape({smooth:G,stackedOnSmooth:te,smoothMonotone:W,connectNulls:N}),_r(y,t,"areaStyle"),je(y).seriesIndex=t.seriesIndex,Ut(y,j,U,F)}var ue=this._changePolyState;s.eachItemGraphicEl(function(ge){ge&&(ge.onHoverStateChange=ue)}),this._polyline.onHoverStateChange=ue,this._data=s,this._coordSys=i,this._stackedOnPoints=D,this._points=c,this._step=k,this._valueOrigin=T,t.get("triggerLineEvent")&&(this.packEventData(t,g),y&&this.packEventData(t,y))},e.prototype.packEventData=function(t,n){je(n).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},e.prototype.highlight=function(t,n,a,i){var o=t.getData(),s=uc(o,i);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=o.getLayout("points"),u=o.getItemGraphicEl(s);if(!u){var c=l[s*2],f=l[s*2+1];if(isNaN(c)||isNaN(f)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(c,f))return;var d=t.get("zlevel")||0,v=t.get("z")||0;u=new Jg(o,s),u.x=c,u.y=f,u.setZ(d,v);var g=u.getSymbolPath().getTextContent();g&&(g.zlevel=d,g.z=v,g.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else St.prototype.highlight.call(this,t,n,a,i)},e.prototype.downplay=function(t,n,a,i){var o=t.getData(),s=uc(o,i);if(this._changePolyState("normal"),s!=null&&s>=0){var l=o.getItemGraphicEl(s);l&&(l.__temp?(o.setItemGraphicEl(s,null),this.group.remove(l)):l.downplay())}else St.prototype.downplay.call(this,t,n,a,i)},e.prototype._changePolyState=function(t){var n=this._polygon;Vx(this._polyline,t),n&&Vx(n,t)},e.prototype._newPolyline=function(t){var n=this._polyline;return n&&this._lineGroup.remove(n),n=new sfe({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(n),this._polyline=n,n},e.prototype._newPolygon=function(t,n){var a=this._polygon;return a&&this._lineGroup.remove(a),a=new j7({shape:{points:t,stackedOnPoints:n},segmentIgnoreThreshold:2}),this._lineGroup.add(a),this._polygon=a,a},e.prototype._initSymbolLabelAnimation=function(t,n,a){var i,o,s=n.getBaseAxis(),l=s.inverse;n.type==="cartesian2d"?(i=s.isHorizontal(),o=!1):n.type==="polar"&&(i=s.dim==="angle",o=!0);var u=t.hostModel,c=u.get("animationDuration");Me(c)&&(c=c(null));var f=u.get("animationDelay")||0,d=Me(f)?f(null):f;t.eachItemGraphicEl(function(v,g){var y=v;if(y){var x=[v.x,v.y],b=void 0,w=void 0,T=void 0;if(a)if(o){var C=a,D=n.pointToCoord(x);i?(b=C.startAngle,w=C.endAngle,T=-D[1]/180*Math.PI):(b=C.r0,w=C.r,T=D[0])}else{var M=a;i?(b=M.x,w=M.x+M.width,T=v.x):(b=M.y+M.height,w=M.y,T=v.y)}var N=w===b?0:(T-b)/(w-b);l&&(N=1-N);var R=Me(f)?f(g):c*N+d,E=y.getSymbolPath(),k=E.getTextContent();y.attr({scaleX:0,scaleY:0}),y.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:R}),k&&k.animateFrom({style:{opacity:0}},{duration:300,delay:R}),E.disableLabelAnimation=!0}})},e.prototype._initOrUpdateEndLabel=function(t,n,a){var i=t.getModel("endLabel");if(V7(t)){var o=t.getData(),s=this._polyline,l=o.getLayout("points");if(!l){s.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new ot({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var c=pfe(l);c>=0&&(kr(s,Sr(t,"endLabel"),{inheritColor:a,labelFetcher:t,labelDataIndex:c,defaultText:function(f,d,v){return v!=null?k7(o,v):Gh(o,f)},enableTextSetter:!0},mfe(i,n)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,n,a,i,o,s,l){var u=this._endLabel,c=this._polyline;if(u){t<1&&i.originalX==null&&(i.originalX=u.x,i.originalY=u.y);var f=a.getLayout("points"),d=a.hostModel,v=d.get("connectNulls"),g=s.get("precision"),y=s.get("distance")||0,x=l.getBaseAxis(),b=x.isHorizontal(),w=x.inverse,T=n.shape,C=w?b?T.x:T.y+T.height:b?T.x+T.width:T.y,D=(b?y:0)*(w?-1:1),M=(b?0:-y)*(w?-1:1),N=b?"x":"y",R=gfe(f,C,N),E=R.range,k=E[1]-E[0],I=void 0;if(k>=1){if(k>1&&!v){var B=R3(f,E[0]);u.attr({x:B[0]+D,y:B[1]+M}),o&&(I=d.getRawValue(E[0]))}else{var B=c.getPointOn(C,N);B&&u.attr({x:B[0]+D,y:B[1]+M});var P=d.getRawValue(E[0]),H=d.getRawValue(E[1]);o&&(I=fH(a,g,P,H,R.t))}i.lastFrameIndex=E[0]}else{var V=t===1||i.lastFrameIndex>0?E[0]:0,B=R3(f,V);o&&(I=d.getRawValue(V)),u.attr({x:B[0]+D,y:B[1]+M})}if(o){var j=id(u);typeof j.setLabelText=="function"&&j.setLabelText(I)}}},e.prototype._doUpdateAnimation=function(t,n,a,i,o,s,l){var u=this._polyline,c=this._polygon,f=t.hostModel,d=ofe(this._data,t,this._stackedOnPoints,n,this._coordSys,a,this._valueOrigin),v=d.current,g=d.stackedOnCurrent,y=d.next,x=d.stackedOnNext;if(o&&(g=Vs(d.stackedOnCurrent,d.current,a,o,l),v=Vs(d.current,null,a,o,l),x=Vs(d.stackedOnNext,d.next,a,o,l),y=Vs(d.next,null,a,o,l)),N3(v,y)>3e3||c&&N3(g,x)>3e3){u.stopAnimation(),u.setShape({points:y}),c&&(c.stopAnimation(),c.setShape({points:y,stackedOnPoints:x}));return}u.shape.__points=d.current,u.shape.points=v;var b={shape:{points:y}};d.current!==v&&(b.shape.__points=d.next),u.stopAnimation(),lt(u,b,f),c&&(c.setShape({points:v,stackedOnPoints:g}),c.stopAnimation(),lt(c,{shape:{stackedOnPoints:x}},f),u.shape.points!==c.shape.points&&(c.shape.points=u.shape.points));for(var w=[],T=d.status,C=0;C<T.length;C++){var D=T[C].cmd;if(D==="="){var M=t.getItemGraphicEl(T[C].idx1);M&&w.push({el:M,ptIdx:C})}}u.animators&&u.animators.length&&u.animators[0].during(function(){c&&c.dirtyShape();for(var N=u.shape.__points,R=0;R<w.length;R++){var E=w[R].el,k=w[R].ptIdx*2;E.x=N[k],E.y=N[k+1],E.markRedraw()}})},e.prototype.remove=function(t){var n=this.group,a=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),a&&a.eachItemGraphicEl(function(i,o){i.__temp&&(n.remove(i),a.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},e.type="line",e})(St);function rm(r,e){return{seriesType:r,plan:ud(),reset:function(t){var n=t.getData(),a=t.coordinateSystem,i=t.pipelineContext,o=e||i.large;if(a){var s=fe(a.dimensions,function(v){return n.mapDimension(v)}).slice(0,2),l=s.length,u=n.getCalculationInfo("stackResultDimension");Jo(n,s[0])&&(s[0]=u),Jo(n,s[1])&&(s[1]=u);var c=n.getStore(),f=n.getDimensionIndex(s[0]),d=n.getDimensionIndex(s[1]);return l&&{progress:function(v,g){for(var y=v.end-v.start,x=o&&zi(y*l),b=[],w=[],T=v.start,C=0;T<v.end;T++){var D=void 0;if(l===1){var M=c.get(f,T);D=a.dataToPoint(M,null,w)}else b[0]=c.get(f,T),b[1]=c.get(d,T),D=a.dataToPoint(b,null,w);o?(x[C++]=D[0],x[C++]=D[1]):g.setItemLayout(T,D.slice())}o&&g.setLayout("points",x)}}}}}}var xfe={average:function(r){for(var e=0,t=0,n=0;n<r.length;n++)isNaN(r[n])||(e+=r[n],t++);return t===0?NaN:e/t},sum:function(r){for(var e=0,t=0;t<r.length;t++)e+=r[t]||0;return e},max:function(r){for(var e=-1/0,t=0;t<r.length;t++)r[t]>e&&(e=r[t]);return isFinite(e)?e:NaN},min:function(r){for(var e=1/0,t=0;t<r.length;t++)r[t]<e&&(e=r[t]);return isFinite(e)?e:NaN},nearest:function(r){return r[0]}},bfe=function(r){return Math.round(r.length/2)};function G7(r){return{seriesType:r,reset:function(e,t,n){var a=e.getData(),i=e.get("sampling"),o=e.coordinateSystem,s=a.count();if(s>10&&o.type==="cartesian2d"&&i){var l=o.getBaseAxis(),u=o.getOtherAxis(l),c=l.getExtent(),f=n.getDevicePixelRatio(),d=Math.abs(c[1]-c[0])*(f||1),v=Math.round(s/d);if(isFinite(v)&&v>1){i==="lttb"?e.setData(a.lttbDownSample(a.mapDimension(u.dim),1/v)):i==="minmax"&&e.setData(a.minmaxDownSample(a.mapDimension(u.dim),1/v));var g=void 0;ye(i)?g=xfe[i]:Me(i)&&(g=i),g&&e.setData(a.downSample(a.mapDimension(u.dim),1/v,g,bfe))}}}}}function _fe(r){r.registerChartView(yfe),r.registerSeriesModel(rfe),r.registerLayout(rm("line",!0)),r.registerVisual({seriesType:"line",reset:function(e){var t=e.getData(),n=e.getModel("lineStyle").getLineStyle();n&&!n.stroke&&(n.stroke=t.getVisual("style").fill),t.setVisual("legendLineStyle",n)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,G7("line"))}var pg=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,n){return to(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t,n,a){var i=this.coordinateSystem;if(i&&i.clampData){var o=i.clampData(t),s=i.dataToPoint(o);if(a)O(i.getAxes(),function(d,v){if(d.type==="category"&&n!=null){var g=d.getTicksCoords(),y=d.getTickModel().get("alignWithLabel"),x=o[v],b=n[v]==="x1"||n[v]==="y1";if(b&&!y&&(x+=1),g.length<2)return;if(g.length===2){s[v]=d.toGlobalCoord(d.getExtent()[b?1:0]);return}for(var w=void 0,T=void 0,C=1,D=0;D<g.length;D++){var M=g[D].coord,N=D===g.length-1?g[D-1].tickValue+C:g[D].tickValue;if(N===x){T=M;break}else if(N<x)w=M;else if(w!=null&&N>x){T=(M+w)/2;break}D===1&&(C=N-g[0].tickValue)}T==null&&(w?w&&(T=g[g.length-1].coord):T=g[0].coord),s[v]=d.toGlobalCoord(T)}});else{var l=this.getData(),u=l.getLayout("offset"),c=l.getLayout("size"),f=i.getBaseAxis().isHorizontal()?0:1;s[f]+=u+c/2}return s}return[NaN,NaN]},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",defaultBarGap:"10%"},e})(Ct);Ct.registerClass(pg);var Sfe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(){return to(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return this.get("large")?this.get("progressive"):!1},e.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),n=this.get("largeThreshold");return n>t&&(t=n),t},e.prototype.brushSelector=function(t,n,a){return a.rect(n.getItemLayout(t))},e.type="series.bar",e.dependencies=["grid","polar"],e.defaultOption=Rl(pg.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:ee.color.primary,borderWidth:2}},realtimeSort:!1}),e})(pg),wfe=(function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r})(),u1=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="sausage",n}return e.prototype.getDefaultShape=function(){return new wfe},e.prototype.buildPath=function(t,n){var a=n.cx,i=n.cy,o=Math.max(n.r0||0,0),s=Math.max(n.r,0),l=(s-o)*.5,u=o+l,c=n.startAngle,f=n.endAngle,d=n.clockwise,v=Math.PI*2,g=d?f-c<v:c-f<v;g||(c=f-(d?v:-v));var y=Math.cos(c),x=Math.sin(c),b=Math.cos(f),w=Math.sin(f);g?(t.moveTo(y*o+a,x*o+i),t.arc(y*u+a,x*u+i,l,-Math.PI+c,c,!d)):t.moveTo(y*s+a,x*s+i),t.arc(a,i,s,c,f,!d),t.arc(b*u+a,w*u+i,l,f-Math.PI*2,f-Math.PI,!d),o!==0&&t.arc(a,i,o,f,c,d)},e})(tt);function Tfe(r,e){e=e||{};var t=e.isRoundCap;return function(n,a,i){var o=a.position;if(!o||o instanceof Array)return Ox(n,a,i);var s=r(o),l=a.distance!=null?a.distance:5,u=this.shape,c=u.cx,f=u.cy,d=u.r,v=u.r0,g=(d+v)/2,y=u.startAngle,x=u.endAngle,b=(y+x)/2,w=t?Math.abs(d-v)/2:0,T=Math.cos,C=Math.sin,D=c+d*T(y),M=f+d*C(y),N="left",R="top";switch(s){case"startArc":D=c+(v-l)*T(b),M=f+(v-l)*C(b),N="center",R="top";break;case"insideStartArc":D=c+(v+l)*T(b),M=f+(v+l)*C(b),N="center",R="bottom";break;case"startAngle":D=c+g*T(y)+h0(y,l+w,!1),M=f+g*C(y)+d0(y,l+w,!1),N="right",R="middle";break;case"insideStartAngle":D=c+g*T(y)+h0(y,-l+w,!1),M=f+g*C(y)+d0(y,-l+w,!1),N="left",R="middle";break;case"middle":D=c+g*T(b),M=f+g*C(b),N="center",R="middle";break;case"endArc":D=c+(d+l)*T(b),M=f+(d+l)*C(b),N="center",R="bottom";break;case"insideEndArc":D=c+(d-l)*T(b),M=f+(d-l)*C(b),N="center",R="top";break;case"endAngle":D=c+g*T(x)+h0(x,l+w,!0),M=f+g*C(x)+d0(x,l+w,!0),N="left",R="middle";break;case"insideEndAngle":D=c+g*T(x)+h0(x,-l+w,!0),M=f+g*C(x)+d0(x,-l+w,!0),N="right",R="middle";break;default:return Ox(n,a,i)}return n=n||{},n.x=D,n.y=M,n.align=N,n.verticalAlign=R,n}}function Cfe(r,e,t,n){if(st(n)){r.setTextConfig({rotation:n});return}else if(ce(e)){r.setTextConfig({rotation:0});return}var a=r.shape,i=a.clockwise?a.startAngle:a.endAngle,o=a.clockwise?a.endAngle:a.startAngle,s=(i+o)/2,l,u=t(e);switch(u){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":l=s;break;case"startAngle":case"insideStartAngle":l=i;break;case"endAngle":case"insideEndAngle":l=o;break;default:r.setTextConfig({rotation:0});return}var c=Math.PI*1.5-l;u==="middle"&&c>Math.PI/2&&c<Math.PI*1.5&&(c-=Math.PI),r.setTextConfig({rotation:c})}function h0(r,e,t){return e*Math.sin(r)*(t?-1:1)}function d0(r,e,t){return e*Math.cos(r)*(t?1:-1)}function Vi(r,e,t){var n=r.get("borderRadius");if(n==null)return t?{cornerRadius:0}:null;ce(n)||(n=[n,n,n,n]);var a=Math.abs(e.r||0-e.r0||0);return{cornerRadius:fe(n,function(i){return oi(i,a)})}}var m2=Math.max,y2=Math.min;function Afe(r,e){var t=r.getArea&&r.getArea();if(wl(r,"cartesian2d")){var n=r.getBaseAxis();if(n.type!=="category"||!n.onBand){var a=e.getLayout("bandWidth");n.isHorizontal()?(t.x-=a,t.width+=a*2):(t.y-=a,t.height+=a*2)}}return t}var Mfe=(function(r){K(e,r);function e(){var t=r.call(this)||this;return t.type=e.type,t._isFirstFrame=!0,t}return e.prototype.render=function(t,n,a,i){this._model=t,this._removeOnRenderedListener(a),this._updateDrawMode(t);var o=t.get("coordinateSystem");(o==="cartesian2d"||o==="polar")&&(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(t,n,a):this._renderNormal(t,n,a,i))},e.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},e.prototype.incrementalRender=function(t,n){this._progressiveEls=[],this._incrementalRenderLarge(t,n)},e.prototype.eachRendered=function(t){Ll(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var n=t.pipelineContext.large;(this._isLargeDraw==null||n!==this._isLargeDraw)&&(this._isLargeDraw=n,this._clear())},e.prototype._renderNormal=function(t,n,a,i){var o=this.group,s=t.getData(),l=this._data,u=t.coordinateSystem,c=u.getBaseAxis(),f;u.type==="cartesian2d"?f=c.isHorizontal():u.type==="polar"&&(f=c.dim==="angle");var d=t.isAnimationEnabled()?t:null,v=Dfe(t,u);v&&this._enableRealtimeSort(v,s,a);var g=t.get("clip",!0)||v,y=Afe(u,s);o.removeClipPath();var x=t.get("roundCap",!0),b=t.get("showBackground",!0),w=t.getModel("backgroundStyle"),T=w.get("borderRadius")||0,C=[],D=this._backgroundEls,M=i&&i.isInitSort,N=i&&i.type==="changeAxisOrder";function R(I){var B=v0[u.type](s,I);if(!B)return null;var P=Ofe(u,f,B);return P.useStyle(w.getItemStyle()),u.type==="cartesian2d"?P.setShape("r",T):P.setShape("cornerRadius",T),C[I]=P,P}s.diff(l).add(function(I){var B=s.getItemModel(I),P=v0[u.type](s,I,B);if(P&&(b&&R(I),!(!s.hasValue(I)||!P3[u.type](P)))){var H=!1;g&&(H=E3[u.type](y,P));var V=k3[u.type](t,s,I,P,f,d,c.model,!1,x);v&&(V.forceLabelAnimation=!0),j3(V,s,I,B,P,t,f,u.type==="polar"),M?V.attr({shape:P}):v?I3(v,d,V,P,I,f,!1,!1):zt(V,{shape:P},t,I),s.setItemGraphicEl(I,V),o.add(V),V.ignore=H}}).update(function(I,B){var P=s.getItemModel(I),H=v0[u.type](s,I,P);if(H){if(b){var V=void 0;D.length===0?V=R(B):(V=D[B],V.useStyle(w.getItemStyle()),u.type==="cartesian2d"?V.setShape("r",T):V.setShape("cornerRadius",T),C[I]=V);var j=v0[u.type](s,I),U=F7(f,j,u);lt(V,{shape:U},d,I)}var F=l.getItemGraphicEl(B);if(!s.hasValue(I)||!P3[u.type](H)){o.remove(F);return}var X=!1;g&&(X=E3[u.type](y,H),X&&o.remove(F));var G=F&&(F.type==="sector"&&x||F.type==="sausage"&&!x);if(G&&(F&&Ho(F,t,B),F=null),F?ja(F):F=k3[u.type](t,s,I,H,f,d,c.model,!0,x),v&&(F.forceLabelAnimation=!0),N){var W=F.getTextContent();if(W){var $=id(W);$.prevValue!=null&&($.prevValue=$.value)}}else j3(F,s,I,P,H,t,f,u.type==="polar");M?F.attr({shape:H}):v?I3(v,d,F,H,I,f,!0,N):lt(F,{shape:H},t,I,null),s.setItemGraphicEl(I,F),F.ignore=X,o.add(F)}}).remove(function(I){var B=l.getItemGraphicEl(I);B&&Ho(B,t,I)}).execute();var E=this._backgroundGroup||(this._backgroundGroup=new Ne);E.removeAll();for(var k=0;k<C.length;++k)E.add(C[k]);o.add(E),this._backgroundEls=C,this._data=s},e.prototype._renderLarge=function(t,n,a){this._clear(),B3(t,this.group),this._updateLargeClip(t)},e.prototype._incrementalRenderLarge=function(t,n){this._removeBackground(),B3(n,this.group,this._progressiveEls,!0)},e.prototype._updateLargeClip=function(t){var n=t.get("clip",!0)&&tm(t.coordinateSystem,!1,t),a=this.group;n?a.setClipPath(n):a.removeClipPath()},e.prototype._enableRealtimeSort=function(t,n,a){var i=this;if(n.count()){var o=t.baseAxis;if(this._isFirstFrame)this._dispatchInitSort(n,t,a),this._isFirstFrame=!1;else{var s=function(l){var u=n.getItemGraphicEl(l),c=u&&u.shape;return c&&Math.abs(o.isHorizontal()?c.height:c.width)||0};this._onRendered=function(){i._updateSortWithinSameData(n,s,o,a)},a.getZr().on("rendered",this._onRendered)}}},e.prototype._dataSort=function(t,n,a){var i=[];return t.each(t.mapDimension(n.dim),function(o,s){var l=a(s);l=l??NaN,i.push({dataIndex:s,mappedValue:l,ordinalNumber:o})}),i.sort(function(o,s){return s.mappedValue-o.mappedValue}),{ordinalNumbers:fe(i,function(o){return o.ordinalNumber})}},e.prototype._isOrderChangedWithinSameData=function(t,n,a){for(var i=a.scale,o=t.mapDimension(a.dim),s=Number.MAX_VALUE,l=0,u=i.getOrdinalMeta().categories.length;l<u;++l){var c=t.rawIndexOf(o,i.getRawOrdinalNumber(l)),f=c<0?Number.MIN_VALUE:n(t.indexOfRawIndex(c));if(f>s)return!0;s=f}return!1},e.prototype._isOrderDifferentInView=function(t,n){for(var a=n.scale,i=a.getExtent(),o=Math.max(0,i[0]),s=Math.min(i[1],a.getOrdinalMeta().categories.length-1);o<=s;++o)if(t.ordinalNumbers[o]!==a.getRawOrdinalNumber(o))return!0},e.prototype._updateSortWithinSameData=function(t,n,a,i){if(this._isOrderChangedWithinSameData(t,n,a)){var o=this._dataSort(t,a,n);this._isOrderDifferentInView(o,a)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:a.dim+"Axis",axisId:a.index,sortInfo:o}))}},e.prototype._dispatchInitSort=function(t,n,a){var i=n.baseAxis,o=this._dataSort(t,i,function(s){return t.get(t.mapDimension(n.otherAxis.dim),s)});a.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:o})},e.prototype.remove=function(t,n){this._clear(this._model),this._removeOnRenderedListener(n)},e.prototype.dispose=function(t,n){this._removeOnRenderedListener(n)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var n=this.group,a=this._data;t&&t.isAnimationEnabled()&&a&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],a.eachItemGraphicEl(function(i){Ho(i,t,je(i).dataIndex)})):n.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type="bar",e})(St),E3={cartesian2d:function(r,e){var t=e.width<0?-1:1,n=e.height<0?-1:1;t<0&&(e.x+=e.width,e.width=-e.width),n<0&&(e.y+=e.height,e.height=-e.height);var a=r.x+r.width,i=r.y+r.height,o=m2(e.x,r.x),s=y2(e.x+e.width,a),l=m2(e.y,r.y),u=y2(e.y+e.height,i),c=s<o,f=u<l;return e.x=c&&o>a?s:o,e.y=f&&l>i?u:l,e.width=c?0:s-o,e.height=f?0:u-l,t<0&&(e.x+=e.width,e.width=-e.width),n<0&&(e.y+=e.height,e.height=-e.height),c||f},polar:function(r,e){var t=e.r0<=e.r?1:-1;if(t<0){var n=e.r;e.r=e.r0,e.r0=n}var a=y2(e.r,r.r),i=m2(e.r0,r.r0);e.r=a,e.r0=i;var o=a-i<0;if(t<0){var n=e.r;e.r=e.r0,e.r0=n}return o}},k3={cartesian2d:function(r,e,t,n,a,i,o,s,l){var u=new qe({shape:ie({},n),z2:1});if(u.__dataIndex=t,u.name="item",i){var c=u.shape,f=a?"height":"width";c[f]=0}return u},polar:function(r,e,t,n,a,i,o,s,l){var u=!a&&l?u1:nn,c=new u({shape:n,z2:1});c.name="item";var f=H7(a);if(c.calculateTextPosition=Tfe(f,{isRoundCap:u===u1}),i){var d=c.shape,v=a?"r":"endAngle",g={};d[v]=a?n.r0:n.startAngle,g[v]=n[v],(s?lt:zt)(c,{shape:g},i)}return c}};function Dfe(r,e){var t=r.get("realtimeSort",!0),n=e.getBaseAxis();if(t&&n.type==="category"&&e.type==="cartesian2d")return{baseAxis:n,otherAxis:e.getOtherAxis(n)}}function I3(r,e,t,n,a,i,o,s){var l,u;i?(u={x:n.x,width:n.width},l={y:n.y,height:n.height}):(u={y:n.y,height:n.height},l={x:n.x,width:n.width}),s||(o?lt:zt)(t,{shape:l},e,a,null);var c=e?r.baseAxis.model:null;(o?lt:zt)(t,{shape:u},c,a)}function O3(r,e){for(var t=0;t<e.length;t++)if(!isFinite(r[e[t]]))return!0;return!1}var Nfe=["x","y","width","height"],Lfe=["cx","cy","r","startAngle","endAngle"],P3={cartesian2d:function(r){return!O3(r,Nfe)},polar:function(r){return!O3(r,Lfe)}},v0={cartesian2d:function(r,e,t){var n=r.getItemLayout(e);if(!n)return null;var a=t?Efe(t,n):0,i=n.width>0?1:-1,o=n.height>0?1:-1;return{x:n.x+i*a/2,y:n.y+o*a/2,width:n.width-i*a,height:n.height-o*a}},polar:function(r,e,t){var n=r.getItemLayout(e);return{cx:n.cx,cy:n.cy,r0:n.r0,r:n.r,startAngle:n.startAngle,endAngle:n.endAngle,clockwise:n.clockwise}}};function Rfe(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function H7(r){return(function(e){var t=e?"Arc":"Angle";return function(n){switch(n){case"start":case"insideStart":case"end":case"insideEnd":return n+t;default:return n}}})(r)}function j3(r,e,t,n,a,i,o,s){var l=e.getItemVisual(t,"style");if(s){if(!i.get("roundCap")){var c=r.shape,f=Vi(n.getModel("itemStyle"),c,!0);ie(c,f),r.setShape(c)}}else{var u=n.get(["itemStyle","borderRadius"])||0;r.setShape("r",u)}r.useStyle(l);var d=n.getShallow("cursor");d&&r.attr("cursor",d);var v=s?o?a.r>=a.r0?"endArc":"startArc":a.endAngle>=a.startAngle?"endAngle":"startAngle":o?a.height>=0?"bottom":"top":a.width>=0?"right":"left",g=Sr(n);kr(r,g,{labelFetcher:i,labelDataIndex:t,defaultText:Gh(i.getData(),t),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:v});var y=r.getTextContent();if(s&&y){var x=n.get(["label","position"]);r.textConfig.inside=x==="middle"?!0:null,Cfe(r,x==="outside"?v:x,H7(o),n.get(["label","rotate"]))}QH(y,g,i.getRawValue(t),function(w){return k7(e,w)});var b=n.getModel(["emphasis"]);Ut(r,b.get("focus"),b.get("blurScope"),b.get("disabled")),_r(r,n),Rfe(a)&&(r.style.fill="none",r.style.stroke="none",O(r.states,function(w){w.style&&(w.style.fill=w.style.stroke="none")}))}function Efe(r,e){var t=r.get(["itemStyle","borderColor"]);if(!t||t==="none")return 0;var n=r.get(["itemStyle","borderWidth"])||0,a=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),i=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height);return Math.min(n,a,i)}var kfe=(function(){function r(){}return r})(),z3=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="largeBar",n}return e.prototype.getDefaultShape=function(){return new kfe},e.prototype.buildPath=function(t,n){for(var a=n.points,i=this.baseDimIdx,o=1-this.baseDimIdx,s=[],l=[],u=this.barWidth,c=0;c<a.length;c+=3)l[i]=u,l[o]=a[c+2],s[i]=a[c+i],s[o]=a[c+o],t.rect(s[0],s[1],l[0],l[1])},e})(tt);function B3(r,e,t,n){var a=r.getData(),i=a.getLayout("valueAxisHorizontal")?1:0,o=a.getLayout("largeDataIndices"),s=a.getLayout("size"),l=r.getModel("backgroundStyle"),u=a.getLayout("largeBackgroundPoints");if(u){var c=new z3({shape:{points:u},incremental:!!n,silent:!0,z2:0});c.baseDimIdx=i,c.largeDataIndices=o,c.barWidth=s,c.useStyle(l.getItemStyle()),e.add(c),t&&t.push(c)}var f=new z3({shape:{points:a.getLayout("largePoints")},incremental:!!n,ignoreCoarsePointer:!0,z2:1});f.baseDimIdx=i,f.largeDataIndices=o,f.barWidth=s,e.add(f),f.useStyle(a.getVisual("style")),f.style.stroke=null,je(f).seriesIndex=r.seriesIndex,r.get("silent")||(f.on("mousedown",V3),f.on("mousemove",V3)),t&&t.push(f)}var V3=pb(function(r){var e=this,t=Ife(e,r.offsetX,r.offsetY);je(e).dataIndex=t>=0?t:null},30,!1);function Ife(r,e,t){for(var n=r.baseDimIdx,a=1-n,i=r.shape.points,o=r.largeDataIndices,s=[],l=[],u=r.barWidth,c=0,f=i.length/3;c<f;c++){var d=c*3;if(l[n]=u,l[a]=i[d+2],s[n]=i[d+n],s[a]=i[d+a],l[a]<0&&(s[a]+=l[a],l[a]=-l[a]),e>=s[0]&&e<=s[0]+l[0]&&t>=s[1]&&t<=s[1]+l[1])return o[c]}return-1}function F7(r,e,t){if(wl(t,"cartesian2d")){var n=e,a=t.getArea();return{x:r?n.x:a.x,y:r?a.y:n.y,width:r?n.width:a.width,height:r?a.height:n.height}}else{var a=t.getArea(),i=e;return{cx:a.cx,cy:a.cy,r0:r?a.r0:i.r0,r:r?a.r:i.r,startAngle:r?i.startAngle:0,endAngle:r?i.endAngle:Math.PI*2}}}function Ofe(r,e,t){var n=r.type==="polar"?nn:qe;return new n({shape:F7(e,t,r),silent:!0,z2:0})}function Pfe(r){r.registerChartView(Mfe),r.registerSeriesModel(Sfe),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,He(WF,"bar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,XF("bar")),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,G7("bar")),r.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(e,t){var n=e.componentType||"series";t.eachComponent({mainType:n,query:e},function(a){e.sortInfo&&a.axis.setCategorySortInfo(e.sortInfo)})})}var G3=Math.PI*2,p0=Math.PI/180;function jfe(r,e,t){e.eachSeriesByType(r,function(n){var a=n.getData(),i=a.mapDimension("value"),o=g8(n,t),s=o.cx,l=o.cy,u=o.r,c=o.r0,f=o.viewRect,d=-n.get("startAngle")*p0,v=n.get("endAngle"),g=n.get("padAngle")*p0;v=v==="auto"?d-G3:-v*p0;var y=n.get("minAngle")*p0,x=y+g,b=0;a.each(i,function(U){!isNaN(U)&&b++});var w=a.getSum(i),T=Math.PI/(w||b)*2,C=n.get("clockwise"),D=n.get("roseType"),M=n.get("stillShowZeroSum"),N=a.getDataExtent(i);N[0]=0;var R=C?1:-1,E=[d,v],k=R*g/2;ab(E,!C),d=E[0],v=E[1];var I=U7(n);I.startAngle=d,I.endAngle=v,I.clockwise=C,I.cx=s,I.cy=l,I.r=u,I.r0=c;var B=Math.abs(v-d),P=B,H=0,V=d;if(a.setLayout({viewRect:f,r:u}),a.each(i,function(U,F){var X;if(isNaN(U)){a.setItemLayout(F,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:C,cx:s,cy:l,r0:c,r:D?NaN:u});return}D!=="area"?X=w===0&&M?T:U*T:X=B/b,X<x?(X=x,P-=x):H+=U;var G=V+R*X,W=0,$=0;g>X?(W=V+R*X/2,$=W):(W=V+k,$=G-k),a.setItemLayout(F,{angle:X,startAngle:W,endAngle:$,clockwise:C,cx:s,cy:l,r0:c,r:D?pt(U,N,[c,u]):u}),V=G}),P<G3&&b)if(P<=.001){var j=B/b;a.each(i,function(U,F){if(!isNaN(U)){var X=a.getItemLayout(F);X.angle=j;var G=0,W=0;j<g?(G=d+R*(F+1/2)*j,W=G):(G=d+R*F*j+k,W=d+R*(F+1)*j-k),X.startAngle=G,X.endAngle=W}})}else T=P/H,V=d,a.each(i,function(U,F){if(!isNaN(U)){var X=a.getItemLayout(F),G=X.angle===x?x:U*T,W=0,$=0;G<g?(W=V+R*G/2,$=W):(W=V+k,$=V+R*G-k),X.startAngle=W,X.endAngle=$,V+=R*G}})})}var U7=Je();function pd(r){return{seriesType:r,reset:function(e,t){var n=t.findComponents({mainType:"legend"});if(!(!n||!n.length)){var a=e.getData();a.filterSelf(function(i){for(var o=a.getName(i),s=0;s<n.length;s++)if(!n[s].isSelected(o))return!1;return!0})}}}}var zfe=Math.PI/180;function H3(r,e,t,n,a,i,o,s,l,u){if(r.length<2)return;function c(y){for(var x=y.rB,b=x*x,w=0;w<y.list.length;w++){var T=y.list[w],C=Math.abs(T.label.y-t),D=n+T.len,M=D*D,N=Math.sqrt(Math.abs((1-C*C/b)*M)),R=e+(N+T.len2)*a,E=R-T.label.x,k=T.targetTextWidth-E*a;Y7(T,k,!0),T.label.x=R}}function f(y){for(var x={list:[],maxY:0},b={list:[],maxY:0},w=0;w<y.length;w++)if(y[w].labelAlignTo==="none"){var T=y[w],C=T.label.y>t?b:x,D=Math.abs(T.label.y-t);if(D>=C.maxY){var M=T.label.x-e-T.len2*a,N=n+T.len,R=Math.abs(M)<N?Math.sqrt(D*D/(1-M*M/N/N)):N;C.rB=R,C.maxY=D}C.list.push(T)}c(x),c(b)}for(var d=r.length,v=0;v<d;v++)if(r[v].position==="outer"&&r[v].labelAlignTo==="labelLine"){var g=r[v].label.x-u;r[v].linePoints[1][0]+=g,r[v].label.x=u}yA(r,1,l,l+o)&&f(r)}function Bfe(r,e,t,n,a,i,o,s){for(var l=[],u=[],c=Number.MAX_VALUE,f=-Number.MAX_VALUE,d=0;d<r.length;d++){var v=r[d].label;x2(r[d])||(v.x<e?(c=Math.min(c,v.x),l.push(r[d])):(f=Math.max(f,v.x),u.push(r[d])))}for(var d=0;d<r.length;d++){var g=r[d];if(!x2(g)&&g.linePoints){if(g.labelStyleWidth!=null)continue;var v=g.label,y=g.linePoints,x=void 0;g.labelAlignTo==="edge"?v.x<e?x=y[2][0]-g.labelDistance-o-g.edgeDistance:x=o+a-g.edgeDistance-y[2][0]-g.labelDistance:g.labelAlignTo==="labelLine"?v.x<e?x=c-o-g.bleedMargin:x=o+a-f-g.bleedMargin:v.x<e?x=v.x-o-g.bleedMargin:x=o+a-v.x-g.bleedMargin,g.targetTextWidth=x,Y7(g,x,!1)}}H3(u,e,t,n,1,a,i,o,s,f),H3(l,e,t,n,-1,a,i,o,s,c);for(var d=0;d<r.length;d++){var g=r[d];if(!x2(g)&&g.linePoints){var v=g.label,y=g.linePoints,b=g.labelAlignTo==="edge",w=v.style.padding,T=w?w[1]+w[3]:0,C=v.style.backgroundColor?0:T,D=g.rect.width+C,M=y[1][0]-y[2][0];b?v.x<e?y[2][0]=o+g.edgeDistance+D+g.labelDistance:y[2][0]=o+a-g.edgeDistance-D-g.labelDistance:(v.x<e?y[2][0]=v.x+g.labelDistance:y[2][0]=v.x-g.labelDistance,y[1][0]=y[2][0]+M),y[1][1]=y[2][1]=v.y}}}function Y7(r,e,t){if(r.labelStyleWidth==null){var n=r.label,a=n.style,i=r.rect,o=a.backgroundColor,s=a.padding,l=s?s[1]+s[3]:0,u=a.overflow,c=i.width+(o?0:l);if(e<c||t){if(u&&u.match("break")){n.setStyle("backgroundColor",null),n.setStyle("width",e-l);var f=n.getBoundingRect();n.setStyle("width",Math.ceil(f.width)),n.setStyle("backgroundColor",o)}else{var d=e-l,v=e<c?d:t?d>r.unconstrainedWidth?null:d:null;n.setStyle("width",v)}W7(i,n)}}}function W7(r,e){F3.rect=r,g7(F3,e,Vfe)}var Vfe={minMarginForce:[null,0,null,0],marginDefault:[1,0,1,0]},F3={};function x2(r){return r.position==="center"}function Gfe(r){var e=r.getData(),t=[],n,a,i=!1,o=(r.get("minShowLabelAngle")||0)*zfe,s=e.getLayout("viewRect"),l=e.getLayout("r"),u=s.width,c=s.x,f=s.y,d=s.height;function v(M){M.ignore=!0}function g(M){if(!M.ignore)return!0;for(var N in M.states)if(M.states[N].ignore===!1)return!0;return!1}e.each(function(M){var N=e.getItemGraphicEl(M),R=N.shape,E=N.getTextContent(),k=N.getTextGuideLine(),I=e.getItemModel(M),B=I.getModel("label"),P=B.get("position")||I.get(["emphasis","label","position"]),H=B.get("distanceToLabelLine"),V=B.get("alignTo"),j=me(B.get("edgeDistance"),u),U=B.get("bleedMargin");U==null&&(U=Math.min(u,d)>200?10:2);var F=I.getModel("labelLine"),X=F.get("length");X=me(X,u);var G=F.get("length2");if(G=me(G,u),Math.abs(R.endAngle-R.startAngle)<o){O(E.states,v),E.ignore=!0,k&&(O(k.states,v),k.ignore=!0);return}if(g(E)){var W=(R.startAngle+R.endAngle)/2,$=Math.cos(W),te=Math.sin(W),ue,ge,Se,Xe;n=R.cx,a=R.cy;var be=P==="inside"||P==="inner";if(P==="center")ue=R.cx,ge=R.cy,Xe="center";else{var we=(be?(R.r+R.r0)/2*$:R.r*$)+n,ze=(be?(R.r+R.r0)/2*te:R.r*te)+a;if(ue=we+$*3,ge=ze+te*3,!be){var oe=we+$*(X+l-R.r),pe=ze+te*(X+l-R.r),Be=oe+($<0?-1:1)*G,Le=pe;V==="edge"?ue=$<0?c+j:c+u-j:ue=Be+($<0?-H:H),ge=Le,Se=[[we,ze],[oe,pe],[Be,Le]]}Xe=be?"center":V==="edge"?$>0?"right":"left":$>0?"left":"right"}var at=Math.PI,ft=0,At=B.get("rotate");if(st(At))ft=At*(at/180);else if(P==="center")ft=0;else if(At==="radial"||At===!0){var Wr=$<0?-W+at:-W;ft=Wr}else if(At==="tangential"&&P!=="outside"&&P!=="outer"){var er=Math.atan2($,te);er<0&&(er=at*2+er);var ci=te>0;ci&&(er=at+er),ft=er-at}if(i=!!ft,E.x=ue,E.y=ge,E.rotation=ft,E.setStyle({verticalAlign:"middle"}),be){E.setStyle({align:Xe});var yd=E.states.select;yd&&(yd.x+=E.x,yd.y+=E.y)}else{var Ga=new Oe(0,0,0,0);W7(Ga,E),t.push({label:E,labelLine:k,position:P,len:X,len2:G,minTurnAngle:F.get("minTurnAngle"),maxSurfaceAngle:F.get("maxSurfaceAngle"),surfaceNormal:new Ie($,te),linePoints:Se,textAlign:Xe,labelDistance:H,labelAlignTo:V,edgeDistance:j,bleedMargin:U,rect:Ga,unconstrainedWidth:Ga.width,labelStyleWidth:E.style.width})}N.setTextConfig({inside:be})}}),!i&&r.get("avoidLabelOverlap")&&Bfe(t,n,a,l,u,d,c,f);for(var y=0;y<t.length;y++){var x=t[y],b=x.label,w=x.labelLine,T=isNaN(b.x)||isNaN(b.y);if(b){b.setStyle({align:x.textAlign}),T&&(O(b.states,v),b.ignore=!0);var C=b.states.select;C&&(C.x+=b.x,C.y+=b.y)}if(w){var D=x.linePoints;T||!D?(O(w.states,v),w.ignore=!0):(d7(D,x.minTurnAngle),sce(D,x.surfaceNormal,x.maxSurfaceAngle),w.setShape({points:D}),b.__hostTarget.textGuideLineConfig={anchor:new Ie(D[0][0],D[0][1])})}}}var Hfe=(function(r){K(e,r);function e(t,n,a){var i=r.call(this)||this;i.z2=2;var o=new ot;return i.setTextContent(o),i.updateData(t,n,a,!0),i}return e.prototype.updateData=function(t,n,a,i){var o=this,s=t.hostModel,l=t.getItemModel(n),u=l.getModel("emphasis"),c=t.getItemLayout(n),f=ie(Vi(l.getModel("itemStyle"),c,!0),c);if(isNaN(f.startAngle)){o.setShape(f);return}if(i){o.setShape(f);var d=s.getShallow("animationType");s.ecModel.ssr?(zt(o,{scaleX:0,scaleY:0},s,{dataIndex:n,isFrom:!0}),o.originX=f.cx,o.originY=f.cy):d==="scale"?(o.shape.r=c.r0,zt(o,{shape:{r:c.r}},s,n)):a!=null?(o.setShape({startAngle:a,endAngle:a}),zt(o,{shape:{startAngle:c.startAngle,endAngle:c.endAngle}},s,n)):(o.shape.endAngle=c.startAngle,lt(o,{shape:{endAngle:c.endAngle}},s,n))}else ja(o),lt(o,{shape:f},s,n);o.useStyle(t.getItemVisual(n,"style")),_r(o,l);var v=(c.startAngle+c.endAngle)/2,g=s.get("selectedOffset"),y=Math.cos(v)*g,x=Math.sin(v)*g,b=l.getShallow("cursor");b&&o.attr("cursor",b),this._updateLabel(s,t,n),o.ensureState("emphasis").shape=ie({r:c.r+(u.get("scale")&&u.get("scaleSize")||0)},Vi(u.getModel("itemStyle"),c)),ie(o.ensureState("select"),{x:y,y:x,shape:Vi(l.getModel(["select","itemStyle"]),c)}),ie(o.ensureState("blur"),{shape:Vi(l.getModel(["blur","itemStyle"]),c)});var w=o.getTextGuideLine(),T=o.getTextContent();w&&ie(w.ensureState("select"),{x:y,y:x}),ie(T.ensureState("select"),{x:y,y:x}),Ut(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,n,a){var i=this,o=n.getItemModel(a),s=o.getModel("labelLine"),l=n.getItemVisual(a,"style"),u=l&&l.fill,c=l&&l.opacity;kr(i,Sr(o),{labelFetcher:n.hostModel,labelDataIndex:a,inheritColor:u,defaultOpacity:c,defaultText:t.getFormattedLabel(a,"normal")||n.getName(a)});var f=i.getTextContent();i.setTextConfig({position:null,rotation:null}),f.attr({z2:10});var d=o.get(["label","position"]);if(d!=="outside"&&d!=="outer")i.removeTextGuideLine();else{var v=this.getTextGuideLine();v||(v=new Ur,this.setTextGuideLine(v)),vN(this,pN(o),{stroke:u,opacity:zn(s.get(["lineStyle","opacity"]),c,1)})}},e})(nn),Ffe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,n,a,i){var o=t.getData(),s=this._data,l=this.group,u;if(!s&&o.count()>0){for(var c=o.getItemLayout(0),f=1;isNaN(c&&c.startAngle)&&f<o.count();++f)c=o.getItemLayout(f);c&&(u=c.startAngle)}if(this._emptyCircleSector&&l.remove(this._emptyCircleSector),o.count()===0&&t.get("showEmptyCircle")){var d=U7(t),v=new nn({shape:De(d)});v.useStyle(t.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=v,l.add(v)}o.diff(s).add(function(g){var y=new Hfe(o,g,u);o.setItemGraphicEl(g,y),l.add(y)}).update(function(g,y){var x=s.getItemGraphicEl(y);x.updateData(o,g,u),x.off("click"),l.add(x),o.setItemGraphicEl(g,x)}).remove(function(g){var y=s.getItemGraphicEl(g);Ho(y,t,g)}).execute(),Gfe(t),t.get("animationTypeUpdate")!=="expansion"&&(this._data=o)},e.prototype.dispose=function(){},e.prototype.containPoint=function(t,n){var a=n.getData(),i=a.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type="pie",e})(St);function gd(r,e,t){e=ce(e)&&{coordDimensions:e}||ie({encodeDefine:r.getEncode()},e);var n=r.getSource(),a=hd(n,e).dimensions,i=new pn(a,r);return i.initData(n,t),i}var md=(function(){function r(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return r.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},r.prototype.containName=function(e){var t=this._getRawData();return t.indexOfName(e)>=0},r.prototype.indexOfName=function(e){var t=this._getDataWithEncodedVisual();return t.indexOfName(e)},r.prototype.getItemVisual=function(e,t){var n=this._getDataWithEncodedVisual();return n.getItemVisual(e,t)},r})(),Ufe=Je(),X7=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new md(xe(this.getData,this),xe(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return gd(this,{coordDimensions:["value"],encodeDefaulter:He(HD,this)})},e.prototype.getDataParams=function(t){var n=this.getData(),a=Ufe(n),i=a.seats;if(!i){var o=[];n.each(n.mapDimension("value"),function(l){o.push(l)}),i=a.seats=tH(o,n.hostModel.get("percentPrecision"))}var s=r.prototype.getDataParams.call(this,t);return s.percent=i[t]||0,s.$vars.push("percent"),s},e.prototype._defaultLabelLine=function(t){lc(t,"labelLine",["show"]);var n=t.labelLine,a=t.emphasis.labelLine;n.show=n.show&&t.label.show,a.show=a.show&&t.emphasis.label.show},e.type="series.pie",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"50%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,coordinateSystemUsage:"box",left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:30,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e})(Ct);jie({fullType:X7.type,getCoord2:function(r){return r.getShallow("center")}});function Yfe(r){return{seriesType:r,reset:function(e,t){var n=e.getData();n.filterSelf(function(a){var i=n.mapDimension("value"),o=n.get(i,a);return!(st(o)&&!isNaN(o)&&o<0)})}}}function Wfe(r){r.registerChartView(Ffe),r.registerSeriesModel(X7),sF("pie",r.registerAction),r.registerLayout(He(jfe,"pie")),r.registerProcessor(pd("pie")),r.registerProcessor(Yfe("pie"))}var Xfe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,n){return to(null,this,{useEncodeDefaulter:!0})},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?5e3:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?1e4:this.get("progressiveThreshold"))},e.prototype.brushSelector=function(t,n,a){return a.point(n.getItemLayout(t))},e.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},e.type="series.scatter",e.dependencies=["grid","polar","geo","singleAxis","calendar","matrix"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:ee.color.primary}},universalTransition:{divideShape:"clone"}},e})(Ct),q7=4,qfe=(function(){function r(){}return r})(),Zfe=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n._off=0,n.hoverDataIdx=-1,n}return e.prototype.getDefaultShape=function(){return new qfe},e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.buildPath=function(t,n){var a=n.points,i=n.size,o=this.symbolProxy,s=o.shape,l=t.getContext?t.getContext():t,u=l&&i[0]<q7,c=this.softClipShape,f;if(u){this._ctx=l;return}for(this._ctx=null,f=this._off;f<a.length;){var d=a[f++],v=a[f++];isNaN(d)||isNaN(v)||c&&!c.contain(d,v)||(s.x=d-i[0]/2,s.y=v-i[1]/2,s.width=i[0],s.height=i[1],o.buildPath(t,s,!0))}this.incremental&&(this._off=f,this.notClear=!0)},e.prototype.afterBrush=function(){var t=this.shape,n=t.points,a=t.size,i=this._ctx,o=this.softClipShape,s;if(i){for(s=this._off;s<n.length;){var l=n[s++],u=n[s++];isNaN(l)||isNaN(u)||o&&!o.contain(l,u)||i.fillRect(l-a[0]/2,u-a[1]/2,a[0],a[1])}this.incremental&&(this._off=s,this.notClear=!0)}},e.prototype.findDataIndex=function(t,n){for(var a=this.shape,i=a.points,o=a.size,s=Math.max(o[0],4),l=Math.max(o[1],4),u=i.length/2-1;u>=0;u--){var c=u*2,f=i[c]-s/2,d=i[c+1]-l/2;if(t>=f&&n>=d&&t<=f+s&&n<=d+l)return u}return-1},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();if(t=a[0],n=a[1],i.contain(t,n)){var o=this.hoverDataIdx=this.findDataIndex(t,n);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var n=this.shape,a=n.points,i=n.size,o=i[0],s=i[1],l=1/0,u=1/0,c=-1/0,f=-1/0,d=0;d<a.length;){var v=a[d++],g=a[d++];l=Math.min(v,l),c=Math.max(v,c),u=Math.min(g,u),f=Math.max(g,f)}t=this._rect=new Oe(l-o/2,u-s/2,c-l+o,f-u+s)}return t},e})(tt),$fe=(function(){function r(){this.group=new Ne}return r.prototype.updateData=function(e,t){this._clear();var n=this._create();n.setShape({points:e.getLayout("points")}),this._setCommon(n,e,t)},r.prototype.updateLayout=function(e){var t=e.getLayout("points");this.group.eachChild(function(n){if(n.startIndex!=null){var a=(n.endIndex-n.startIndex)*2,i=n.startIndex*4*2;t=new Float32Array(t.buffer,i,a)}n.setShape("points",t),n.reset()})},r.prototype.incrementalPrepareUpdate=function(e){this._clear()},r.prototype.incrementalUpdate=function(e,t,n){var a=this._newAdded[0],i=t.getLayout("points"),o=a&&a.shape.points;if(o&&o.length<2e4){var s=o.length,l=new Float32Array(s+i.length);l.set(o),l.set(i,s),a.endIndex=e.end,a.setShape({points:l})}else{this._newAdded=[];var u=this._create();u.startIndex=e.start,u.endIndex=e.end,u.incremental=!0,u.setShape({points:i}),this._setCommon(u,t,n)}},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new Zfe({cursor:"default"});return e.ignoreCoarsePointer=!0,this.group.add(e),this._newAdded.push(e),e},r.prototype._setCommon=function(e,t,n){var a=t.hostModel;n=n||{};var i=t.getVisual("symbolSize");e.setShape("size",i instanceof Array?i:[i,i]),e.softClipShape=n.clipShape||null,e.symbolProxy=ur(t.getVisual("symbol"),0,0,0,0),e.setColor=e.symbolProxy.setColor;var o=e.shape.size[0]<q7;e.useStyle(a.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var s=t.getVisual("style"),l=s&&s.fill;l&&e.setColor(l);var u=je(e);u.seriesIndex=a.seriesIndex,e.on("mousemove",function(c){u.dataIndex=null;var f=e.hoverDataIdx;f>=0&&(u.dataIndex=f+(e.startIndex||0))})},r.prototype.remove=function(){this._clear()},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r})(),Kfe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.updateData(i,{clipShape:this._getClipShape(t)}),this._finished=!0},e.prototype.incrementalPrepareRender=function(t,n,a){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.incrementalPrepareUpdate(i),this._finished=!1},e.prototype.incrementalRender=function(t,n,a){this._symbolDraw.incrementalUpdate(t,n.getData(),{clipShape:this._getClipShape(n)}),this._finished=t.end===n.getData().count()},e.prototype.updateTransform=function(t,n,a){var i=t.getData();if(this.group.dirty(),!this._finished||i.count()>1e4)return{update:!0};var o=rm("").reset(t,n,a);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},e.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},e.prototype._getClipShape=function(t){if(t.get("clip",!0)){var n=t.coordinateSystem;return n&&n.getArea&&n.getArea(.1)}},e.prototype._updateSymbolDraw=function(t,n){var a=this._symbolDraw,i=n.pipelineContext,o=i.large;return(!a||o!==this._isLargeDraw)&&(a&&a.remove(),a=this._symbolDraw=o?new $fe:new em,this._isLargeDraw=o,this.group.removeAll()),this.group.add(a.group),a},e.prototype.remove=function(t,n){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},e.prototype.dispose=function(){},e.type="scatter",e})(St),Z7={left:0,right:0,top:0,bottom:0},c1=["25%","25%"],Qfe=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.mergeDefaultAndTheme=function(t,n){var a=Sc(t.outerBounds);r.prototype.mergeDefaultAndTheme.apply(this,arguments),a&&t.outerBounds&&Zi(t.outerBounds,a)},e.prototype.mergeOption=function(t,n){r.prototype.mergeOption.apply(this,arguments),this.option.outerBounds&&t.outerBounds&&Zi(this.option.outerBounds,t.outerBounds)},e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"15%",top:65,right:"10%",bottom:80,containLabel:!1,outerBoundsMode:"auto",outerBounds:Z7,outerBoundsContain:"all",outerBoundsClampWidth:c1[0],outerBoundsClampHeight:c1[1],backgroundColor:ee.color.transparent,borderWidth:1,borderColor:ee.color.neutral30},e})(Qe),wA=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Zt).models[0]},e.type="cartesian2dAxis",e})(Qe);Jt(wA,vd);var $7={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:ee.color.axisLine,width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15],breakLine:!0},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12,color:ee.color.axisLabel,textMargin:[0,3]},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:ee.color.axisSplitLine,width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:[ee.color.backgroundTint,ee.color.backgroundTransparent]}},breakArea:{show:!0,itemStyle:{color:ee.color.neutral00,borderColor:ee.color.border,borderWidth:1,borderType:[3,3],opacity:.6},zigzagAmplitude:4,zigzagMinSpan:4,zigzagMaxSpan:20,zigzagZ:100,expandOnClick:!0},breakLabelLayout:{moveOverlap:"auto"}},Jfe=Ye({boundaryGap:!0,deduplication:null,jitter:0,jitterOverlap:!0,jitterMargin:2,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto",show:"auto"},axisLabel:{interval:"auto"}},$7),SN=Ye({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:ee.color.axisMinorSplitLine,width:1}}},$7),ehe=Ye({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},SN),the=Re({logBase:10},SN);const K7={category:Jfe,value:SN,time:ehe,log:the};var rhe={value:1,category:1,time:1,log:1},TA=null;function nhe(r){TA||(TA=r)}function nm(){return TA}function Hh(r,e,t,n){O(rhe,function(a,i){var o=Ye(Ye({},K7[i],!0),n,!0),s=(function(l){K(u,l);function u(){var c=l!==null&&l.apply(this,arguments)||this;return c.type=e+"Axis."+i,c}return u.prototype.mergeDefaultAndTheme=function(c,f){var d=ig(this),v=d?Sc(c):{},g=f.getTheme();Ye(c,g.get(i+"Axis")),Ye(c,this.getDefaultOption()),c.type=U3(c),d&&Zi(c,v,d)},u.prototype.optionUpdated=function(){var c=this.option;c.type==="category"&&(this.__ordinalMeta=fg.createByAxisModel(this))},u.prototype.getCategories=function(c){var f=this.option;if(f.type==="category")return c?f.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.prototype.updateAxisBreaks=function(c){var f=nm();return f?f.updateModelAxisBreak(this,c):{breaks:[]}},u.type=e+"Axis."+i,u.defaultOption=o,u})(t);r.registerComponentModel(s)}),r.registerSubTypeDefaulter(e+"Axis",U3)}function U3(r){return r.type||(r.data?"category":"value")}var ahe=(function(){function r(e){this.type="cartesian",this._dimList=[],this._axes={},this.name=e||""}return r.prototype.getAxis=function(e){return this._axes[e]},r.prototype.getAxes=function(){return fe(this._dimList,function(e){return this._axes[e]},this)},r.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),dt(this.getAxes(),function(t){return t.scale.type===e})},r.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},r})(),CA=["x","y"];function Y3(r){return(r.type==="interval"||r.type==="time")&&!r.hasBreaks()}var ihe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=CA,t}return e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,n=this.getAxis("y").scale;if(!(!Y3(t)||!Y3(n))){var a=t.getExtent(),i=n.getExtent(),o=this.dataToPoint([a[0],i[0]]),s=this.dataToPoint([a[1],i[1]]),l=a[1]-a[0],u=i[1]-i[0];if(!(!l||!u)){var c=(s[0]-o[0])/l,f=(s[1]-o[1])/u,d=o[0]-a[0]*c,v=o[1]-i[0]*f,g=this._transform=[c,0,0,f,d,v];this._invTransform=Oa([],g)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var n=this.getAxis("x"),a=this.getAxis("y");return n.contain(n.toLocalCoord(t[0]))&&a.contain(a.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,n){var a=this.dataToPoint(t),i=this.dataToPoint(n),o=this.getArea(),s=new Oe(a[0],a[1],i[0]-a[0],i[1]-a[1]);return o.intersect(s)},e.prototype.dataToPoint=function(t,n,a){a=a||[];var i=t[0],o=t[1];if(this._transform&&i!=null&&isFinite(i)&&o!=null&&isFinite(o))return Qt(a,t,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return a[0]=s.toGlobalCoord(s.dataToCoord(i,n)),a[1]=l.toGlobalCoord(l.dataToCoord(o,n)),a},e.prototype.clampData=function(t,n){var a=this.getAxis("x").scale,i=this.getAxis("y").scale,o=a.getExtent(),s=i.getExtent(),l=a.parse(t[0]),u=i.parse(t[1]);return n=n||[],n[0]=Math.min(Math.max(Math.min(o[0],o[1]),l),Math.max(o[0],o[1])),n[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),n},e.prototype.pointToData=function(t,n,a){if(a=a||[],this._invTransform)return Qt(a,t,this._invTransform);var i=this.getAxis("x"),o=this.getAxis("y");return a[0]=i.coordToData(i.toLocalCoord(t[0]),n),a[1]=o.coordToData(o.toLocalCoord(t[1]),n),a},e.prototype.getOtherAxis=function(t){return this.getAxis(t.dim==="x"?"y":"x")},e.prototype.getArea=function(t){t=t||0;var n=this.getAxis("x").getGlobalExtent(),a=this.getAxis("y").getGlobalExtent(),i=Math.min(n[0],n[1])-t,o=Math.min(a[0],a[1])-t,s=Math.max(n[0],n[1])-i+t,l=Math.max(a[0],a[1])-o+t;return new Oe(i,o,s,l)},e})(ahe),Q7=(function(r){K(e,r);function e(t,n,a,i,o){var s=r.call(this,t,n,a)||this;return s.index=0,s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.getGlobalExtent=function(t){var n=this.getExtent();return n[0]=this.toGlobalCoord(n[0]),n[1]=this.toGlobalCoord(n[1]),t&&n[0]>n[1]&&n.reverse(),n},e.prototype.pointToData=function(t,n){return this.coordToData(this.toLocalCoord(t[this.dim==="x"?0:1]),n)},e.prototype.setCategorySortInfo=function(t){if(this.type!=="category")return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e})(Va),bb="expandAxisBreak",J7="collapseAxisBreak",eU="toggleAxisBreak",wN="axisbreakchanged",ohe={type:bb,event:wN,update:"update",refineEvent:TN},she={type:J7,event:wN,update:"update",refineEvent:TN},lhe={type:eU,event:wN,update:"update",refineEvent:TN};function TN(r,e,t,n){var a=[];return O(r,function(i){a=a.concat(i.eventBreaks)}),{eventContent:{breaks:a}}}function uhe(r){r.registerAction(ohe,e),r.registerAction(she,e),r.registerAction(lhe,e);function e(t,n){var a=[],i=fh(n,t);function o(s,l){O(i[s],function(u){var c=u.updateAxisBreaks(t);O(c.breaks,function(f){var d;a.push(Re((d={},d[l]=u.componentIndex,d),f))})})}return o("xAxisModels","xAxisIndex"),o("yAxisModels","yAxisIndex"),o("singleAxisModels","singleAxisIndex"),{eventBreaks:a}}}var al=Math.PI,che=[[1,2,1,2],[5,3,5,3],[8,3,8,3]],fhe=[[0,1,0,1],[0,3,0,3],[0,3,0,3]],Fh=Je(),tU=Je(),rU=(function(){function r(e){this.recordMap={},this.resolveAxisNameOverlap=e}return r.prototype.ensureRecord=function(e){var t=e.axis.dim,n=e.componentIndex,a=this.recordMap,i=a[t]||(a[t]=[]);return i[n]||(i[n]={ready:{}})},r})();function hhe(r,e,t,n){var a=t.axis,i=e.ensureRecord(t),o=[],s,l=CN(r.axisName)&&Vh(r.nameLocation);O(n,function(g){var y=$i(g);if(!(!y||y.label.ignore)){o.push(y);var x=i.transGroup;l&&(x.transform?Oa(zv,x.transform):Gg(zv),y.transform&&Ja(zv,zv,y.transform),Oe.copy(g0,y.localRect),g0.applyTransform(zv),s?s.union(g0):Oe.copy(s=new Oe(0,0,0,0),g0))}});var u=Math.abs(i.dirVec.x)>.1?"x":"y",c=i.transGroup[u];if(o.sort(function(g,y){return Math.abs(g.label[u]-c)-Math.abs(y.label[u]-c)}),l&&s){var f=a.getExtent(),d=Math.min(f[0],f[1]),v=Math.max(f[0],f[1])-d;s.union(new Oe(d,0,v,1))}i.stOccupiedRect=s,i.labelInfoList=o}var zv=Rr(),g0=new Oe(0,0,0,0),nU=function(r,e,t,n,a,i){if(Vh(r.nameLocation)){var o=i.stOccupiedRect;o&&aU(cce({},o,i.transGroup.transform),n,a)}else iU(i.labelInfoList,i.dirVec,n,a)};function aU(r,e,t){var n=new Ie;yb(r,e,n,{direction:Math.atan2(t.y,t.x),bidirectional:!1,touchThreshold:.05})&&gA(e,n)}function iU(r,e,t,n){for(var a=Ie.dot(n,e)>=0,i=0,o=r.length;i<o;i++){var s=r[a?i:o-1-i];s.label.ignore||aU(s,t,n)}}var wn=(function(){function r(e,t,n,a){this.group=new Ne,this._axisModel=e,this._api=t,this._local={},this._shared=a||new rU(nU),this._resetCfgDetermined(n)}return r.prototype.updateCfg=function(e){var t=this._cfg.raw;t.position=e.position,t.labelOffset=e.labelOffset,this._resetCfgDetermined(t)},r.prototype.__getRawCfg=function(){return this._cfg.raw},r.prototype._resetCfgDetermined=function(e){var t=this._axisModel,n=t.getDefaultOption?t.getDefaultOption():{},a=Ce(e.axisName,t.get("name")),i=t.get("nameMoveOverlap");(i==null||i==="auto")&&(i=Ce(e.defaultNameMoveOverlap,!0));var o={raw:e,position:e.position,rotation:e.rotation,nameDirection:Ce(e.nameDirection,1),tickDirection:Ce(e.tickDirection,1),labelDirection:Ce(e.labelDirection,1),labelOffset:Ce(e.labelOffset,0),silent:Ce(e.silent,!0),axisName:a,nameLocation:zn(t.get("nameLocation"),n.nameLocation,"end"),shouldNameMoveOverlap:CN(a)&&i,optionHideOverlap:t.get(["axisLabel","hideOverlap"]),showMinorTicks:t.get(["minorTick","show"])};this._cfg=o;var s=new Ne({x:o.position[0],y:o.position[1],rotation:o.rotation});s.updateTransform(),this._transformGroup=s;var l=this._shared.ensureRecord(t);l.transGroup=this._transformGroup,l.dirVec=new Ie(Math.cos(-o.rotation),Math.sin(-o.rotation))},r.prototype.build=function(e,t){var n=this;return e||(e={axisLine:!0,axisTickLabelEstimate:!1,axisTickLabelDetermine:!0,axisName:!0}),O(dhe,function(a){e[a]&&vhe[a](n._cfg,n._local,n._shared,n._axisModel,n.group,n._transformGroup,n._api,t||{})}),this},r.innerTextLayout=function(e,t,n){var a=aD(t-e),i,o;return kh(a)?(o=n>0?"top":"bottom",i="center"):kh(a-al)?(o=n>0?"bottom":"top",i="center"):(o="middle",a>0&&a<al?i=n>0?"right":"left":i=n>0?"left":"right"),{rotation:a,textAlign:i,textVerticalAlign:o}},r.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+"Index"]=e.componentIndex,t},r.isLabelSilent=function(e){var t=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||t&&t.show)},r})(),dhe=["axisLine","axisTickLabelEstimate","axisTickLabelDetermine","axisName"],vhe={axisLine:function(r,e,t,n,a,i,o){var s=n.get(["axisLine","show"]);if(s==="auto"&&(s=!0,r.raw.axisLineAutoShow!=null&&(s=!!r.raw.axisLineAutoShow)),!!s){var l=n.axis.getExtent(),u=i.transform,c=[l[0],0],f=[l[1],0],d=c[0]>f[0];u&&(Qt(c,c,u),Qt(f,f,u));var v=ie({lineCap:"round"},n.getModel(["axisLine","lineStyle"]).getLineStyle()),g={strokeContainThreshold:r.raw.strokeContainThreshold||5,silent:!0,z2:1,style:v};if(n.get(["axisLine","breakLine"])&&n.axis.scale.hasBreaks())nm().buildAxisBreakLine(n,a,i,g);else{var y=new lr(ie({shape:{x1:c[0],y1:c[1],x2:f[0],y2:f[1]}},g));Ph(y.shape,y.style.lineWidth),y.anid="line",a.add(y)}var x=n.get(["axisLine","symbol"]);if(x!=null){var b=n.get(["axisLine","symbolSize"]);ye(x)&&(x=[x,x]),(ye(b)||st(b))&&(b=[b,b]);var w=Tc(n.get(["axisLine","symbolOffset"])||0,b),T=b[0],C=b[1];O([{rotate:r.rotation+Math.PI/2,offset:w[0],r:0},{rotate:r.rotation-Math.PI/2,offset:w[1],r:Math.sqrt((c[0]-f[0])*(c[0]-f[0])+(c[1]-f[1])*(c[1]-f[1]))}],function(D,M){if(x[M]!=="none"&&x[M]!=null){var N=ur(x[M],-T/2,-C/2,T,C,v.stroke,!0),R=D.r+D.offset,E=d?f:c;N.attr({rotation:D.rotate,x:E[0]+R*Math.cos(r.rotation),y:E[1]-R*Math.sin(r.rotation),silent:!0,z2:11}),a.add(N)}})}}},axisTickLabelEstimate:function(r,e,t,n,a,i,o,s){var l=X3(e,a,s);l&&W3(r,e,t,n,a,i,o,si.estimate)},axisTickLabelDetermine:function(r,e,t,n,a,i,o,s){var l=X3(e,a,s);l&&W3(r,e,t,n,a,i,o,si.determine);var u=yhe(r,a,i,n);mhe(r,e.labelLayoutList,u),xhe(r,a,i,n,r.tickDirection)},axisName:function(r,e,t,n,a,i,o,s){var l=t.ensureRecord(n);e.nameEl&&(a.remove(e.nameEl),e.nameEl=l.nameLayout=l.nameLocation=null);var u=r.axisName;if(CN(u)){var c=r.nameLocation,f=r.nameDirection,d=n.getModel("nameTextStyle"),v=n.get("nameGap")||0,g=n.axis.getExtent(),y=n.axis.inverse?-1:1,x=new Ie(0,0),b=new Ie(0,0);c==="start"?(x.x=g[0]-y*v,b.x=-y):c==="end"?(x.x=g[1]+y*v,b.x=y):(x.x=(g[0]+g[1])/2,x.y=r.labelOffset+f*v,b.y=f);var w=Rr();b.transform(ns(w,w,r.rotation));var T=n.get("nameRotate");T!=null&&(T=T*al/180);var C,D;Vh(c)?C=wn.innerTextLayout(r.rotation,T??r.rotation,f):(C=phe(r.rotation,c,T||0,g),D=r.raw.axisNameAvailableWidth,D!=null&&(D=Math.abs(D/Math.sin(C.rotation)),!isFinite(D)&&(D=null)));var M=d.getFont(),N=n.get("nameTruncate",!0)||{},R=N.ellipsis,E=Fr(r.raw.nameTruncateMaxWidth,N.maxWidth,D),k=s.nameMarginLevel||0,I=new ot({x:x.x,y:x.y,rotation:C.rotation,silent:wn.isLabelSilent(n),style:Nt(d,{text:u,font:M,overflow:"truncate",width:E,ellipsis:R,fill:d.getTextColor()||n.get(["axisLine","lineStyle","color"]),align:d.get("align")||C.textAlign,verticalAlign:d.get("verticalAlign")||C.textVerticalAlign}),z2:1});if(is({el:I,componentModel:n,itemName:u}),I.__fullText=u,I.anid="name",n.get("triggerEvent")){var B=wn.makeAxisEventDataBase(n);B.targetType="axisName",B.name=u,je(I).eventData=B}i.add(I),I.updateTransform(),e.nameEl=I;var P=l.nameLayout=$i({label:I,priority:I.z2,defaultAttr:{ignore:I.ignore},marginDefault:Vh(c)?che[k]:fhe[k]});if(l.nameLocation=c,a.add(I),I.decomposeTransform(),r.shouldNameMoveOverlap&&P){var H=t.ensureRecord(n);t.resolveAxisNameOverlap(r,t,n,P,b,H)}}}};function W3(r,e,t,n,a,i,o,s){sU(e)||bhe(r,e,a,s,n,o);var l=e.labelLayoutList;_he(r,n,l,i),The(n,r.rotation,l);var u=r.optionHideOverlap;ghe(n,l,u),u&&m7(dt(l,function(c){return c&&!c.label.ignore})),hhe(r,t,n,l)}function phe(r,e,t,n){var a=aD(t-r),i,o,s=n[0]>n[1],l=e==="start"&&!s||e!=="start"&&s;return kh(a-al/2)?(o=l?"bottom":"top",i="center"):kh(a-al*1.5)?(o=l?"top":"bottom",i="center"):(o="middle",a<al*1.5&&a>al/2?i=l?"left":"right":i=l?"right":"left"),{rotation:a,textAlign:i,textVerticalAlign:o}}function ghe(r,e,t){if(e7(r.axis))return;function n(s,l,u){var c=$i(e[l]),f=$i(e[u]);if(!(!c||!f)){if(s===!1||c.suggestIgnore){gp(c.label);return}if(f.suggestIgnore){gp(f.label);return}var d=.1;if(!t){var v=[0,0,0,0];c=mA({marginForce:v},c),f=mA({marginForce:v},f)}yb(c,f,null,{touchThreshold:d})&&gp(s?f.label:c.label)}}var a=r.get(["axisLabel","showMinLabel"]),i=r.get(["axisLabel","showMaxLabel"]),o=e.length;n(a,0,1),n(i,o-1,o-2)}function mhe(r,e,t){r.showMinorTicks||O(e,function(n){if(n&&n.label.ignore)for(var a=0;a<t.length;a++){var i=t[a],o=tU(i),s=Fh(n.label);if(o.tickValue!=null&&!o.onBand&&o.tickValue===s.tickValue){gp(i);return}}})}function gp(r){r&&(r.ignore=!0)}function oU(r,e,t,n,a){for(var i=[],o=[],s=[],l=0;l<r.length;l++){var u=r[l].coord;o[0]=u,o[1]=0,s[0]=u,s[1]=t,e&&(Qt(o,o,e),Qt(s,s,e));var c=new lr({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:n,z2:2,autoBatch:!0,silent:!0});Ph(c.shape,c.style.lineWidth),c.anid=a+"_"+r[l].tickValue,i.push(c);var f=tU(c);f.onBand=!!r[l].onBand,f.tickValue=r[l].tickValue}return i}function yhe(r,e,t,n){var a=n.axis,i=n.getModel("axisTick"),o=i.get("show");if(o==="auto"&&(o=!0,r.raw.axisTickAutoShow!=null&&(o=!!r.raw.axisTickAutoShow)),!o||a.scale.isBlank())return[];for(var s=i.getModel("lineStyle"),l=r.tickDirection*i.get("length"),u=a.getTicksCoords(),c=oU(u,t.transform,l,Re(s.getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])}),"ticks"),f=0;f<c.length;f++)e.add(c[f]);return c}function xhe(r,e,t,n,a){var i=n.axis,o=n.getModel("minorTick");if(!(!r.showMinorTicks||i.scale.isBlank())){var s=i.getMinorTicksCoords();if(s.length)for(var l=o.getModel("lineStyle"),u=a*o.get("length"),c=Re(l.getLineStyle(),Re(n.getModel("axisTick").getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])})),f=0;f<s.length;f++)for(var d=oU(s[f],t.transform,u,c,"minorticks_"+f),v=0;v<d.length;v++)e.add(d[v])}}function X3(r,e,t){if(sU(r)){var n=r.axisLabelsCreationContext,a=n.out.noPxChangeTryDetermine;if(t.noPxChange){for(var i=!0,o=0;o<a.length;o++)i=i&&a[o]();if(i)return!1}a.length&&(e.remove(r.labelGroup),AA(r,null,null,null))}return!0}function bhe(r,e,t,n,a,i){var o=a.axis,s=Fr(r.raw.axisLabelShow,a.get(["axisLabel","show"])),l=new Ne;t.add(l);var u=n1(n);if(!s||o.scale.isBlank()){AA(e,[],l,u);return}var c=a.getModel("axisLabel"),f=o.getViewLabels(u),d=(Fr(r.raw.labelRotate,c.get("rotate"))||0)*al/180,v=wn.innerTextLayout(r.rotation,d,r.labelDirection),g=a.getCategories&&a.getCategories(!0),y=[],x=a.get("triggerEvent"),b=1/0,w=-1/0;O(f,function(C,D){var M,N=o.scale.type==="ordinal"?o.scale.getRawOrdinalNumber(C.tickValue):C.tickValue,R=C.formattedLabel,E=C.rawLabel,k=c;if(g&&g[N]){var I=g[N];Ee(I)&&I.textStyle&&(k=new et(I.textStyle,c,a.ecModel))}var B=k.getTextColor()||a.get(["axisLine","lineStyle","color"]),P=k.getShallow("align",!0)||v.textAlign,H=Ce(k.getShallow("alignMinLabel",!0),P),V=Ce(k.getShallow("alignMaxLabel",!0),P),j=k.getShallow("verticalAlign",!0)||k.getShallow("baseline",!0)||v.textVerticalAlign,U=Ce(k.getShallow("verticalAlignMinLabel",!0),j),F=Ce(k.getShallow("verticalAlignMaxLabel",!0),j),X=10+(((M=C.time)===null||M===void 0?void 0:M.level)||0);b=Math.min(b,X),w=Math.max(w,X);var G=new ot({x:0,y:0,rotation:0,silent:wn.isLabelSilent(a),z2:X,style:Nt(k,{text:R,align:D===0?H:D===f.length-1?V:P,verticalAlign:D===0?U:D===f.length-1?F:j,fill:Me(B)?B(o.type==="category"?E:o.type==="value"?N+"":N,D):B})});G.anid="label_"+N;var W=Fh(G);if(W.break=C.break,W.tickValue=N,W.layoutRotation=v.rotation,is({el:G,componentModel:a,itemName:R,formatterParamsExtra:{isTruncated:function(){return G.isTruncated},value:E,tickIndex:D}}),x){var $=wn.makeAxisEventDataBase(a);$.targetType="axisLabel",$.value=E,$.tickIndex=D,C.break&&($.break={start:C.break.parsedBreak.vmin,end:C.break.parsedBreak.vmax}),o.type==="category"&&($.dataIndex=N),je(G).eventData=$,C.break&&whe(a,i,G,C.break)}y.push(G),l.add(G)});var T=fe(y,function(C){return{label:C,priority:Fh(C).break?C.z2+(w-b+1):C.z2,defaultAttr:{ignore:C.ignore}}});AA(e,T,l,u)}function sU(r){return!!r.labelLayoutList}function AA(r,e,t,n){r.labelLayoutList=e,r.labelGroup=t,r.axisLabelsCreationContext=n}function _he(r,e,t,n){var a=e.get(["axisLabel","margin"]);O(t,function(i,o){var s=$i(i);if(s){var l=s.label,u=Fh(l);s.suggestIgnore=l.ignore,l.ignore=!1,Ix(So,She),So.x=e.axis.dataToCoord(u.tickValue),So.y=r.labelOffset+r.labelDirection*a,So.rotation=u.layoutRotation,n.add(So),So.updateTransform(),n.remove(So),So.decomposeTransform(),Ix(l,So),l.markRedraw(),s1(s,!0),$i(s)}})}var So=new qe,She=new qe;function CN(r){return!!r}function whe(r,e,t,n){t.on("click",function(a){var i={type:bb,breaks:[{start:n.parsedBreak.breakOption.start,end:n.parsedBreak.breakOption.end}]};i[r.axis.dim+"AxisIndex"]=r.componentIndex,e.dispatchAction(i)})}function The(r,e,t){var n=dr();if(n){var a=n.retrieveAxisBreakPairs(t,function(o){return o&&Fh(o.label).break},!0),i=r.get(["breakLabelLayout","moveOverlap"],!0);(i===!0||i==="auto")&&O(a,function(o){nm().adjustBreakLabelPair(r.axis.inverse,e,[$i(t[o[0]]),$i(t[o[1]])])})}}function f1(r,e,t){t=t||{};var n=e.axis,a={},i=n.getAxesOnZeroOf()[0],o=n.position,s=i?"onZero":o,l=n.dim,u=[r.x,r.x+r.width,r.y,r.y+r.height],c={left:0,right:1,top:0,bottom:1,onZero:2},f=e.get("offset")||0,d=l==="x"?[u[2]-f,u[3]+f]:[u[0]-f,u[1]+f];if(i){var v=i.toGlobalCoord(i.dataToCoord(0));d[c.onZero]=Math.max(Math.min(v,d[1]),d[0])}a.position=[l==="y"?d[c[s]]:u[0],l==="x"?d[c[s]]:u[3]],a.rotation=Math.PI/2*(l==="x"?0:1);var g={top:-1,bottom:1,left:-1,right:1};a.labelDirection=a.tickDirection=a.nameDirection=g[o],a.labelOffset=i?d[c[o]]-d[c.onZero]:0,e.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),Fr(t.labelInside,e.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var y=e.get(["axisLabel","rotate"]);return a.labelRotate=s==="top"?-y:y,a.z2=1,a}function Che(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function q3(r){var e={xAxisModel:null,yAxisModel:null};return O(e,function(t,n){var a=n.replace(/Model$/,""),i=r.getReferringComponents(a,Zt).models[0];e[n]=i}),e}function Ahe(r,e,t,n,a,i){for(var o=f1(r,t),s=!1,l=!1,u=0;u<e.length;u++)cA(e[u].getOtherAxis(t.axis).scale)&&(s=l=!0,t.axis.type==="category"&&t.axis.onBand&&(l=!1));return o.axisLineAutoShow=s,o.axisTickAutoShow=l,o.defaultNameMoveOverlap=i,new wn(t,n,o,a)}function Mhe(r,e,t){var n=f1(e,t);r.updateCfg(n)}function lU(r,e,t){var n=es.prototype,a=n.getTicks.call(t),i=n.getTicks.call(t,{expandToNicedExtent:!0}),o=a.length-1,s=n.getInterval.call(t),l=JF(r,e),u=l.extent,c=l.fixMin,f=l.fixMax;r.type==="log"&&(u=fA(r.base,u,!0)),r.setBreaksFromOption(t7(e)),r.setExtent(u[0],u[1]),r.calcNiceExtent({splitNumber:o,fixMin:c,fixMax:f});var d=n.getExtent.call(r);c&&(u[0]=d[0]),f&&(u[1]=d[1]);var v=n.getInterval.call(r),g=u[0],y=u[1];if(c&&f)v=(y-g)/o;else if(c)for(y=u[0]+v*o;y<u[1]&&isFinite(y)&&isFinite(u[1]);)v=a2(v),y=u[0]+v*o;else if(f)for(g=u[1]-v*o;g>u[0]&&isFinite(g)&&isFinite(u[0]);)v=a2(v),g=u[1]-v*o;else{var x=r.getTicks().length-1;x>o&&(v=a2(v));var b=v*o;y=Math.ceil(u[1]/v)*v,g=sr(y-b),g<0&&u[0]>=0?(g=0,y=sr(b)):y>0&&u[1]<=0&&(y=0,g=-sr(b))}var w=(a[0].value-i[0].value)/s,T=(a[o].value-i[o].value)/s;n.setExtent.call(r,g+v*w,y+v*T),n.setInterval.call(r,v),(w||T)&&n.setNiceExtent.call(r,g+v,y-v)}var Z3=[[3,1],[0,2]],Dhe=(function(){function r(e,t,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=CA,this._initCartesian(e,t,n),this.model=e}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(e,t){var n=this._axesMap;this._updateScale(e,this.model);function a(o){var s,l=it(o),u=l.length;if(u){for(var c=[],f=u-1;f>=0;f--){var d=+l[f],v=o[d],g=v.model,y=v.scale;cA(y)&&g.get("alignTicks")&&g.get("interval")==null?c.push(v):(pc(y,g),cA(y)&&(s=v))}c.length&&(s||(s=c.pop(),pc(s.scale,s.model)),O(c,function(x){lU(x.scale,x.model,s.scale)}))}}a(n.x),a(n.y);var i={};O(n.x,function(o){$3(n,"y",o,i)}),O(n.y,function(o){$3(n,"x",o,i)}),this.resize(this.model,t)},r.prototype.resize=function(e,t,n){var a=Cr(e,t),i=this._rect=Ht(e.getBoxLayoutParams(),a.refContainer),o=this._axesMap,s=this._coordsList,l=e.get("containLabel");if(MA(o,i),!n){var u=Rhe(i,s,o,l,t),c=void 0;if(l)DA?(DA(this._axesList,i),MA(o,i)):c=J3(i.clone(),"axisLabel",null,i,o,u,a);else{var f=Ehe(e,i,a),d=f.outerBoundsRect,v=f.parsedOuterBoundsContain,g=f.outerBoundsClamp;d&&(c=J3(d,v,g,i,o,u,a))}uU(i,o,si.determine,null,c,a)}O(this._coordsList,function(y){y.calcAffineTransform()})},r.prototype.getAxis=function(e,t){var n=this._axesMap[e];if(n!=null)return n[t||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(e,t){if(e!=null&&t!=null){var n="x"+e+"y"+t;return this._coordsMap[n]}Ee(e)&&(t=e.yAxisIndex,e=e.xAxisIndex);for(var a=0,i=this._coordsList;a<i.length;a++)if(i[a].getAxis("x").index===e||i[a].getAxis("y").index===t)return i[a]},r.prototype.getCartesians=function(){return this._coordsList.slice()},r.prototype.convertToPixel=function(e,t,n){var a=this._findConvertTarget(t);return a.cartesian?a.cartesian.dataToPoint(n):a.axis?a.axis.toGlobalCoord(a.axis.dataToCoord(n)):null},r.prototype.convertFromPixel=function(e,t,n){var a=this._findConvertTarget(t);return a.cartesian?a.cartesian.pointToData(n):a.axis?a.axis.coordToData(a.axis.toLocalCoord(n)):null},r.prototype._findConvertTarget=function(e){var t=e.seriesModel,n=e.xAxisModel||t&&t.getReferringComponents("xAxis",Zt).models[0],a=e.yAxisModel||t&&t.getReferringComponents("yAxis",Zt).models[0],i=e.gridModel,o=this._coordsList,s,l;if(t)s=t.coordinateSystem,Fe(o,s)<0&&(s=null);else if(n&&a)s=this.getCartesian(n.componentIndex,a.componentIndex);else if(n)l=this.getAxis("x",n.componentIndex);else if(a)l=this.getAxis("y",a.componentIndex);else if(i){var u=i.coordinateSystem;u===this&&(s=this._coordsList[0])}return{cartesian:s,axis:l}},r.prototype.containPoint=function(e){var t=this._coordsList[0];if(t)return t.containPoint(e)},r.prototype._initCartesian=function(e,t,n){var a=this,i=this,o={left:!1,right:!1,top:!1,bottom:!1},s={x:{},y:{}},l={x:0,y:0};if(t.eachComponent("xAxis",u("x"),this),t.eachComponent("yAxis",u("y"),this),!l.x||!l.y){this._axesMap={},this._axesList=[];return}this._axesMap=s,O(s.x,function(c,f){O(s.y,function(d,v){var g="x"+f+"y"+v,y=new ihe(g);y.master=a,y.model=e,a._coordsMap[g]=y,a._coordsList.push(y),y.addAxis(c),y.addAxis(d)})});function u(c){return function(f,d){if(b2(f,e)){var v=f.get("position");c==="x"?v!=="top"&&v!=="bottom"&&(v=o.bottom?"top":"bottom"):v!=="left"&&v!=="right"&&(v=o.left?"right":"left"),o[v]=!0;var g=new Q7(c,Qg(f),[0,0],f.get("type"),v),y=g.type==="category";g.onBand=y&&f.get("boundaryGap"),g.inverse=f.get("inverse"),f.axis=g,g.model=f,g.grid=i,g.index=d,i._axesList.push(g),s[c][d]=g,l[c]++}}}},r.prototype._updateScale=function(e,t){O(this._axesList,function(a){if(a.scale.setExtent(1/0,-1/0),a.type==="category"){var i=a.model.get("categorySortInfo");a.scale.setSortInfo(i)}}),e.eachSeries(function(a){if(Che(a)){var i=q3(a),o=i.xAxisModel,s=i.yAxisModel;if(!b2(o,t)||!b2(s,t))return;var l=this.getCartesian(o.componentIndex,s.componentIndex),u=a.getData(),c=l.getAxis("x"),f=l.getAxis("y");n(u,c),n(u,f)}},this);function n(a,i){O(r1(a,i.dim),function(o){i.scale.unionExtentFromData(a,o)})}},r.prototype.getTooltipAxes=function(e){var t=[],n=[];return O(this.getCartesians(),function(a){var i=e!=null&&e!=="auto"?a.getAxis(e):a.getBaseAxis(),o=a.getOtherAxis(i);Fe(t,i)<0&&t.push(i),Fe(n,o)<0&&n.push(o)}),{baseAxes:t,otherAxes:n}},r.create=function(e,t){var n=[];return e.eachComponent("grid",function(a,i){var o=new r(a,e,t);o.name="grid_"+i,o.resize(a,t,!0),a.coordinateSystem=o,n.push(o)}),e.eachSeries(function(a){$g({targetModel:a,coordSysType:"cartesian2d",coordSysProvider:i});function i(){var o=q3(a),s=o.xAxisModel,l=o.yAxisModel,u=s.getCoordSysModel(),c=u.coordinateSystem;return c.getCartesian(s.componentIndex,l.componentIndex)}}),n},r.dimensions=CA,r})();function b2(r,e){return r.getCoordSysModel()===e}function $3(r,e,t,n){t.getAxesOnZeroOf=function(){return i?[i]:[]};var a=r[e],i,o=t.model,s=o.get(["axisLine","onZero"]),l=o.get(["axisLine","onZeroAxisIndex"]);if(!s)return;if(l!=null)K3(a[l])&&(i=a[l]);else for(var u in a)if(a.hasOwnProperty(u)&&K3(a[u])&&!n[c(a[u])]){i=a[u];break}i&&(n[c(i)]=!0);function c(f){return f.dim+"_"+f.index}}function K3(r){return r&&r.type!=="category"&&r.type!=="time"&&bue(r)}function Nhe(r,e){var t=r.getExtent(),n=t[0]+t[1];r.toGlobalCoord=r.dim==="x"?function(a){return a+e}:function(a){return n-a+e},r.toLocalCoord=r.dim==="x"?function(a){return a-e}:function(a){return n-a+e}}function MA(r,e){O(r.x,function(t){return Q3(t,e.x,e.width)}),O(r.y,function(t){return Q3(t,e.y,e.height)})}function Q3(r,e,t){var n=[0,t],a=r.inverse?1:0;r.setExtent(n[a],n[1-a]),Nhe(r,e)}var DA;function Lhe(r){DA=r}function J3(r,e,t,n,a,i,o){uU(n,a,si.estimate,e,!1,o);var s=[0,0,0,0];u(0),u(1),c(n,0,NaN),c(n,1,NaN);var l=Dl(s,function(d){return d>0})==null;return hc(n,s,!0,!0,t),MA(a,n),l;function u(d){O(a[Ge[d]],function(v){if(hg(v.model)){var g=i.ensureRecord(v.model),y=g.labelInfoList;if(y)for(var x=0;x<y.length;x++){var b=y[x],w=v.scale.normalize(Fh(b.label).tickValue);w=d===1?1-w:w,c(b.rect,d,w),c(b.rect,1-d,NaN)}var T=g.nameLayout;if(T){var w=Vh(g.nameLocation)?.5:NaN;c(T.rect,d,w),c(T.rect,1-d,NaN)}}})}function c(d,v,g){var y=r[Ge[v]]-d[Ge[v]],x=d[vr[v]]+d[Ge[v]]-(r[vr[v]]+r[Ge[v]]);y=f(y,1-g),x=f(x,g);var b=Z3[v][0],w=Z3[v][1];s[b]=or(s[b],y),s[w]=or(s[w],x)}function f(d,v){return d>0&&!en(v)&&v>1e-4&&(d/=v),d}}function Rhe(r,e,t,n,a){var i=new rU(khe);return O(t,function(o){return O(o,function(s){if(hg(s.model)){var l=!n;s.axisBuilder=Ahe(r,e,s.model,a,i,l)}})}),i}function uU(r,e,t,n,a,i){var o=t===si.determine;O(e,function(u){return O(u,function(c){hg(c.model)&&(Mhe(c.axisBuilder,r,c.model),c.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:a}))})});var s={x:0,y:0};l(0),l(1);function l(u){s[Ge[1-u]]=r[vr[u]]<=i.refContainer[vr[u]]*.5?0:1-u===1?2:1}O(e,function(u,c){return O(u,function(f){hg(f.model)&&((n==="all"||o)&&f.axisBuilder.build({axisName:!0},{nameMarginLevel:s[c]}),o&&f.axisBuilder.build({axisLine:!0}))})})}function Ehe(r,e,t){var n,a=r.get("outerBoundsMode",!0);a==="same"?n=e.clone():(a==null||a==="auto")&&(n=Ht(r.get("outerBounds",!0)||Z7,t.refContainer));var i=r.get("outerBoundsContain",!0),o;i==null||i==="auto"||Fe(["all","axisLabel"],i)<0?o="all":o=i;var s=[Px(Ce(r.get("outerBoundsClampWidth",!0),c1[0]),e.width),Px(Ce(r.get("outerBoundsClampHeight",!0),c1[1]),e.height)];return{outerBoundsRect:n,parsedOuterBoundsContain:o,outerBoundsClamp:s}}var khe=function(r,e,t,n,a,i){var o=t.axis.dim==="x"?"y":"x";nU(r,e,t,n,a,i),Vh(r.nameLocation)||O(e.recordMap[o],function(s){s&&s.labelInfoList&&s.dirVec&&iU(s.labelInfoList,s.dirVec,n,a)})};function Ihe(r,e){var t={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return Ohe(t,r,e),t.seriesInvolved&&jhe(t,r),t}function Ohe(r,e,t){var n=e.getComponent("tooltip"),a=e.getComponent("axisPointer"),i=a.get("link",!0)||[],o=[];O(t.getCoordinateSystems(),function(s){if(!s.axisPointerEnabled)return;var l=gg(s.model),u=r.coordSysAxesInfo[l]={};r.coordSysMap[l]=s;var c=s.model,f=c.getModel("tooltip",n);if(O(s.getAxes(),He(y,!1,null)),s.getTooltipAxes&&n&&f.get("show")){var d=f.get("trigger")==="axis",v=f.get(["axisPointer","type"])==="cross",g=s.getTooltipAxes(f.get(["axisPointer","axis"]));(d||v)&&O(g.baseAxes,He(y,v?"cross":!0,d)),v&&O(g.otherAxes,He(y,"cross",!1))}function y(x,b,w){var T=w.model.getModel("axisPointer",a),C=T.get("show");if(!(!C||C==="auto"&&!x&&!NA(T))){b==null&&(b=T.get("triggerTooltip")),T=x?Phe(w,f,a,e,x,b):T;var D=T.get("snap"),M=T.get("triggerEmphasis"),N=gg(w.model),R=b||D||w.type==="category",E=r.axesInfo[N]={key:N,axis:w,coordSys:s,axisPointerModel:T,triggerTooltip:b,triggerEmphasis:M,involveSeries:R,snap:D,useHandle:NA(T),seriesModels:[],linkGroup:null};u[N]=E,r.seriesInvolved=r.seriesInvolved||R;var k=zhe(i,w);if(k!=null){var I=o[k]||(o[k]={axesInfo:{}});I.axesInfo[N]=E,I.mapper=i[k].mapper,E.linkGroup=I}}}})}function Phe(r,e,t,n,a,i){var o=e.getModel("axisPointer"),s=["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],l={};O(s,function(d){l[d]=De(o.get(d))}),l.snap=r.type!=="category"&&!!i,o.get("type")==="cross"&&(l.type="line");var u=l.label||(l.label={});if(u.show==null&&(u.show=!1),a==="cross"){var c=o.get(["label","show"]);if(u.show=c??!0,!i){var f=l.lineStyle=o.get("crossStyle");f&&Re(u,f.textStyle)}}return r.model.getModel("axisPointer",new et(l,t,n))}function jhe(r,e){e.eachSeries(function(t){var n=t.coordinateSystem,a=t.get(["tooltip","trigger"],!0),i=t.get(["tooltip","show"],!0);!n||!n.model||a==="none"||a===!1||a==="item"||i===!1||t.get(["axisPointer","show"],!0)===!1||O(r.coordSysAxesInfo[gg(n.model)],function(o){var s=o.axis;n.getAxis(s.dim)===s&&(o.seriesModels.push(t),o.seriesDataCount==null&&(o.seriesDataCount=0),o.seriesDataCount+=t.getData().count())})})}function zhe(r,e){for(var t=e.model,n=e.dim,a=0;a<r.length;a++){var i=r[a]||{};if(_2(i[n+"AxisId"],t.id)||_2(i[n+"AxisIndex"],t.componentIndex)||_2(i[n+"AxisName"],t.name))return a}}function _2(r,e){return r==="all"||ce(r)&&Fe(r,e)>=0||r===e}function Bhe(r){var e=AN(r);if(e){var t=e.axisPointerModel,n=e.axis.scale,a=t.option,i=t.get("status"),o=t.get("value");o!=null&&(o=n.parse(o));var s=NA(t);i==null&&(a.status=s?"show":"hide");var l=n.getExtent().slice();l[0]>l[1]&&l.reverse(),(o==null||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),a.value=o,s&&(a.status=e.axis.scale.isBlank()?"hide":"show")}}function AN(r){var e=(r.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[gg(r)]}function Vhe(r){var e=AN(r);return e&&e.axisPointerModel}function NA(r){return!!r.get(["handle","show"])}function gg(r){return r.type+"||"+r.id}var ej={},Cc=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){this.axisPointerClass&&Bhe(t),r.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,a,!0)},e.prototype.updateAxisPointer=function(t,n,a,i){this._doUpdateAxisPointerClass(t,a,!1)},e.prototype.remove=function(t,n){var a=this._axisPointer;a&&a.remove(n)},e.prototype.dispose=function(t,n){this._disposeAxisPointer(n),r.prototype.dispose.apply(this,arguments)},e.prototype._doUpdateAxisPointerClass=function(t,n,a){var i=e.getAxisPointerClass(this.axisPointerClass);if(i){var o=Vhe(t);o?(this._axisPointer||(this._axisPointer=new i)).render(t,o,n,a):this._disposeAxisPointer(n)}},e.prototype._disposeAxisPointer=function(t){this._axisPointer&&this._axisPointer.dispose(t),this._axisPointer=null},e.registerAxisPointerClass=function(t,n){ej[t]=n},e.getAxisPointerClass=function(t){return t&&ej[t]},e.type="axis",e})(Rt),LA=Je();function cU(r,e,t,n){var a=t.axis;if(!a.scale.isBlank()){var i=t.getModel("splitArea"),o=i.getModel("areaStyle"),s=o.get("color"),l=n.coordinateSystem.getRect(),u=a.getTicksCoords({tickModel:i,clamp:!0,breakTicks:"none",pruneByBreak:"preserve_extent_bound"});if(u.length){var c=s.length,f=LA(r).splitAreaColors,d=Te(),v=0;if(f)for(var g=0;g<u.length;g++){var y=f.get(u[g].tickValue);if(y!=null){v=(y+(c-1)*g)%c;break}}var x=a.toGlobalCoord(u[0].coord),b=o.getAreaStyle();s=ce(s)?s:[s];for(var g=1;g<u.length;g++){var w=a.toGlobalCoord(u[g].coord),T=void 0,C=void 0,D=void 0,M=void 0;a.isHorizontal()?(T=x,C=l.y,D=w-T,M=l.height,x=T+D):(T=l.x,C=x,D=l.width,M=w-C,x=C+M);var N=u[g-1].tickValue;N!=null&&d.set(N,v),e.add(new qe({anid:N!=null?"area_"+N:null,shape:{x:T,y:C,width:D,height:M},style:Re({fill:s[v]},b),autoBatch:!0,silent:!0})),v=(v+1)%c}LA(r).splitAreaColors=d}}}function fU(r){LA(r).splitAreaColors=null}var Ghe=["splitArea","splitLine","minorSplitLine","breakArea"],hU=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="CartesianAxisPointer",t}return e.prototype.render=function(t,n,a,i){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new Ne,this.group.add(this._axisGroup),!!hg(t)){this._axisGroup.add(t.axis.axisBuilder.group),O(Ghe,function(l){t.get([l,"show"])&&Hhe[l](this,this._axisGroup,t,t.getCoordSysModel(),a)},this);var s=i&&i.type==="changeAxisOrder"&&i.isInitSort;s||qg(o,this._axisGroup,t),r.prototype.render.call(this,t,n,a,i)}},e.prototype.remove=function(){fU(this)},e.type="cartesianAxis",e})(Cc),Hhe={splitLine:function(r,e,t,n,a){var i=t.axis;if(!i.scale.isBlank()){var o=t.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=o.get("showMinLine")!==!1,c=o.get("showMaxLine")!==!1;l=ce(l)?l:[l];for(var f=n.coordinateSystem.getRect(),d=i.isHorizontal(),v=0,g=i.getTicksCoords({tickModel:o,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),y=[],x=[],b=s.getLineStyle(),w=0;w<g.length;w++){var T=i.toGlobalCoord(g[w].coord);if(!(w===0&&!u||w===g.length-1&&!c)){var C=g[w].tickValue;d?(y[0]=T,y[1]=f.y,x[0]=T,x[1]=f.y+f.height):(y[0]=f.x,y[1]=T,x[0]=f.x+f.width,x[1]=T);var D=v++%l.length,M=new lr({anid:C!=null?"line_"+C:null,autoBatch:!0,shape:{x1:y[0],y1:y[1],x2:x[0],y2:x[1]},style:Re({stroke:l[D]},b),silent:!0});Ph(M.shape,b.lineWidth),e.add(M)}}}},minorSplitLine:function(r,e,t,n,a){var i=t.axis,o=t.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=n.coordinateSystem.getRect(),u=i.isHorizontal(),c=i.getMinorTicksCoords();if(c.length)for(var f=[],d=[],v=s.getLineStyle(),g=0;g<c.length;g++)for(var y=0;y<c[g].length;y++){var x=i.toGlobalCoord(c[g][y].coord);u?(f[0]=x,f[1]=l.y,d[0]=x,d[1]=l.y+l.height):(f[0]=l.x,f[1]=x,d[0]=l.x+l.width,d[1]=x);var b=new lr({anid:"minor_line_"+c[g][y].tickValue,autoBatch:!0,shape:{x1:f[0],y1:f[1],x2:d[0],y2:d[1]},style:v,silent:!0});Ph(b.shape,v.lineWidth),e.add(b)}},splitArea:function(r,e,t,n,a){cU(r,e,t,n)},breakArea:function(r,e,t,n,a){var i=nm(),o=t.axis.scale;i&&o.type!=="ordinal"&&i.rectCoordBuildBreakAxis(e,r,t,n.coordinateSystem.getRect(),a)}},dU=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="xAxis",e})(hU),Fhe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=dU.type,t}return e.type="yAxis",e})(hU),Uhe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="grid",t}return e.prototype.render=function(t,n){this.group.removeAll(),t.get("show")&&this.group.add(new qe({shape:t.coordinateSystem.getRect(),style:Re({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},e.type="grid",e})(Rt),tj={offset:0};function vU(r){r.registerComponentView(Uhe),r.registerComponentModel(Qfe),r.registerCoordinateSystem("cartesian2d",Dhe),Hh(r,"x",wA,tj),Hh(r,"y",wA,tj),r.registerComponentView(dU),r.registerComponentView(Fhe),r.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function Yhe(r,e){var t=r.coordinateSystem,n=t&&t.type,a=t&&t.getBaseAxis&&t.getBaseAxis(),i=a&&a.scale&&a.scale.type,o=n==="cartesian2d"&&i==="ordinal"||n==="single",s=e.model.get("jitter")>0;return o&&s}var Whe=Je();function rj(r,e,t,n){if(r instanceof Q7){var a=r.scale.type;if(a!=="category"&&a!=="ordinal")return t}var i=r.model,o=i.get("jitter"),s=i.get("jitterOverlap"),l=i.get("jitterMargin")||0,u=r.scale.type==="ordinal"?r.getBandWidth():null;return o>0?s?pU(t,o,u,n):Xhe(r,e,t,n,o,l):t}function pU(r,e,t,n){if(t===null)return r+(Math.random()-.5)*e;var a=t-n*2,i=Math.min(Math.max(0,e),a);return r+(Math.random()-.5)*i}function Xhe(r,e,t,n,a,i){var o=Whe(r);o.items||(o.items=[]);var s=o.items,l=nj(s,e,t,n,a,i,1),u=nj(s,e,t,n,a,i,-1),c=Math.abs(l-t)<Math.abs(u-t)?l:u,f=r.scale.type==="ordinal"?r.getBandWidth():null,d=Math.abs(c-t);return d>a/2||f&&d>f/2-n?pU(t,a,f,n):(s.push({fixedCoord:e,floatCoord:c,r:n}),c)}function nj(r,e,t,n,a,i,o){for(var s=t,l=0;l<r.length;l++){var u=r[l],c=e-u.fixedCoord,f=s-u.floatCoord,d=c*c+f*f,v=n+u.r+i;if(d<v*v){var g=u.floatCoord+Math.sqrt(v*v-c*c)*o;if(Math.abs(g-t)>a/2)return Number.MAX_VALUE;if(o===1&&g>s||o===-1&&g<s){s=g,l=-1;continue}}}return s}function qhe(r){r.eachSeriesByType("scatter",function(e){var t=e.coordinateSystem;if(t&&(t.type==="cartesian2d"||t.type==="single")){var n=t.getBaseAxis?t.getBaseAxis():null,a=n&&Yhe(e,n);if(a){var i=e.getData();i.each(function(o){var s=n.dim,l=n.orient,u=l==="horizontal"&&n.type!=="category"||l==="vertical"&&n.type==="category",c=i.getItemLayout(o),f=i.getItemVisual(o,"symbolSize"),d=f instanceof Array?(f[1]+f[0])/2:f;if(s==="y"||s==="single"&&u){var v=rj(n,c[0],c[1],d/2);i.setItemLayout(o,[c[0],v])}else if(s==="x"||s==="single"&&!u){var v=rj(n,c[1],c[0],d/2);i.setItemLayout(o,[v,c[1]])}})}}})}function Zhe(r){We(vU),r.registerSeriesModel(Xfe),r.registerChartView(Kfe),r.registerLayout(rm("scatter"))}function $he(r){r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,qhe)}function Khe(r){r.eachSeriesByType("radar",function(e){var t=e.getData(),n=[],a=e.coordinateSystem;if(a){var i=a.getIndicatorAxes();O(i,function(o,s){t.each(t.mapDimension(i[s].dim),function(l,u){n[u]=n[u]||[];var c=a.dataToPoint(l,s);n[u][s]=aj(c)?c:ij(a)})}),t.each(function(o){var s=Dl(n[o],function(l){return aj(l)})||ij(a);n[o].push(s.slice()),t.setItemLayout(o,n[o])})}})}function aj(r){return!isNaN(r[0])&&!isNaN(r[1])}function ij(r){return[r.cx,r.cy]}function Qhe(r){var e=r.polar;if(e){ce(e)||(e=[e]);var t=[];O(e,function(n,a){n.indicator?(n.type&&!n.shape&&(n.shape=n.type),r.radar=r.radar||[],ce(r.radar)||(r.radar=[r.radar]),r.radar.push(n)):t.push(n)}),r.polar=t}O(r.series,function(n){n&&n.type==="radar"&&n.polarIndex&&(n.radarIndex=n.polarIndex)})}var Jhe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.coordinateSystem,o=this.group,s=t.getData(),l=this._data;function u(d,v){var g=d.getItemVisual(v,"symbol")||"circle";if(g!=="none"){var y=fd(d.getItemVisual(v,"symbolSize")),x=ur(g,-1,-1,2,2),b=d.getItemVisual(v,"symbolRotate")||0;return x.attr({style:{strokeNoScale:!0},z2:100,scaleX:y[0]/2,scaleY:y[1]/2,rotation:b*Math.PI/180||0}),x}}function c(d,v,g,y,x,b){g.removeAll();for(var w=0;w<v.length-1;w++){var T=u(y,x);T&&(T.__dimIdx=w,d[w]?(T.setPosition(d[w]),_c[b?"initProps":"updateProps"](T,{x:v[w][0],y:v[w][1]},t,x)):T.setPosition(v[w]),g.add(T))}}function f(d){return fe(d,function(v){return[i.cx,i.cy]})}s.diff(l).add(function(d){var v=s.getItemLayout(d);if(v){var g=new an,y=new Ur,x={shape:{points:v}};g.shape.points=f(v),y.shape.points=f(v),zt(g,x,t,d),zt(y,x,t,d);var b=new Ne,w=new Ne;b.add(y),b.add(g),b.add(w),c(y.shape.points,v,w,s,d,!0),s.setItemGraphicEl(d,b)}}).update(function(d,v){var g=l.getItemGraphicEl(v),y=g.childAt(0),x=g.childAt(1),b=g.childAt(2),w={shape:{points:s.getItemLayout(d)}};w.shape.points&&(c(y.shape.points,w.shape.points,b,s,d,!1),ja(x),ja(y),lt(y,w,t),lt(x,w,t),s.setItemGraphicEl(d,g))}).remove(function(d){o.remove(l.getItemGraphicEl(d))}).execute(),s.eachItemGraphicEl(function(d,v){var g=s.getItemModel(v),y=d.childAt(0),x=d.childAt(1),b=d.childAt(2),w=s.getItemVisual(v,"style"),T=w.fill;o.add(d),y.useStyle(Re(g.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:T})),_r(y,g,"lineStyle"),_r(x,g,"areaStyle");var C=g.getModel("areaStyle"),D=C.isEmpty()&&C.parentModel.isEmpty();x.ignore=D,O(["emphasis","select","blur"],function(N){var R=g.getModel([N,"areaStyle"]),E=R.isEmpty()&&R.parentModel.isEmpty();x.ensureState(N).ignore=E&&D;var k=g.getModel([N,"lineStyle"]).getLineStyle();y.ensureState(N).style=k;var I=R.getAreaStyle();x.ensureState(N).style=I;var B=g.getModel([N,"itemStyle"]).getItemStyle();b.eachChild(function(P){P.ensureState(N).style=De(B)})}),x.useStyle(Re(g.getModel("areaStyle").getAreaStyle(),{fill:T,opacity:.7,decal:w.decal}));var M=g.getModel("emphasis");b.eachChild(function(N){if(N instanceof Ir){var R=N.style;N.useStyle(ie({image:R.image,x:R.x,y:R.y,width:R.width,height:R.height},w))}else N.useStyle(w),N.setColor(T),N.style.strokeNoScale=!0;var E=s.getStore().get(s.getDimensionIndex(N.__dimIdx),v);(E==null||isNaN(E))&&(E=""),kr(N,Sr(g),{labelFetcher:s.hostModel,labelDataIndex:v,labelDimIndex:N.__dimIdx,defaultText:E,inheritColor:T,defaultOpacity:w.opacity})}),Ut(d,M.get("focus"),M.get("blurScope"),M.get("disabled"))}),this._data=s},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.type="radar",e})(St),ede=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new md(xe(this.getData,this),xe(this.getRawData,this))},e.prototype.getInitialData=function(t,n){return gd(this,{generateCoord:"indicator_",generateCoordCount:1/0})},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=this.coordinateSystem,s=o.getIndicatorAxes(),l=this.getData().getName(t),u=l===""?this.name:l,c=Z8(this,t);return pr("section",{header:u,sortBlocks:!0,blocks:fe(s,function(f){var d=i.get(i.mapDimension(f.dim),t);return pr("nameValue",{markerType:"subItem",markerColor:c,name:f.name,value:d,sortParam:d})})})},e.prototype.getTooltipPosition=function(t){if(t!=null){for(var n=this.getData(),a=this.coordinateSystem,i=n.getValues(fe(a.dimensions,function(u){return n.mapDimension(u)}),t),o=0,s=i.length;o<s;o++)if(!isNaN(i[o])){var l=a.getIndicatorAxes();return a.coordToPoint(l[o].dataToCoord(i[o]),o)}}},e.type="series.radar",e.dependencies=["radar"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},e})(Ct),Bv=K7.value;function m0(r,e){return Re({show:e},r)}var tde=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this.get("boundaryGap"),n=this.get("splitNumber"),a=this.get("scale"),i=this.get("axisLine"),o=this.get("axisTick"),s=this.get("axisLabel"),l=this.get("axisName"),u=this.get(["axisName","show"]),c=this.get(["axisName","formatter"]),f=this.get("axisNameGap"),d=this.get("triggerEvent"),v=fe(this.get("indicator")||[],function(g){g.max!=null&&g.max>0&&!g.min?g.min=0:g.min!=null&&g.min<0&&!g.max&&(g.max=0);var y=l;g.color!=null&&(y=Re({color:g.color},l));var x=Ye(De(g),{boundaryGap:t,splitNumber:n,scale:a,axisLine:i,axisTick:o,axisLabel:s,name:g.text,showName:u,nameLocation:"end",nameGap:f,nameTextStyle:y,triggerEvent:d},!1);if(ye(c)){var b=x.name;x.name=c.replace("{value}",b??"")}else Me(c)&&(x.name=c(x.name,x));var w=new et(x,null,this.ecModel);return Jt(w,vd.prototype),w.mainType="radar",w.componentIndex=this.componentIndex,w},this);this._indicatorModels=v},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"50%",startAngle:90,axisName:{show:!0,color:ee.color.axisLabel},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:Ye({lineStyle:{color:ee.color.neutral20}},Bv.axisLine),axisLabel:m0(Bv.axisLabel,!1),axisTick:m0(Bv.axisTick,!1),splitLine:m0(Bv.splitLine,!0),splitArea:m0(Bv.splitArea,!0),indicator:[]},e})(Qe),rde=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=this.group;i.removeAll(),this._buildAxes(t,a),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t,n){var a=t.coordinateSystem,i=a.getIndicatorAxes(),o=fe(i,function(s){var l=s.model.get("showName")?s.name:"",u=new wn(s.model,n,{axisName:l,position:[a.cx,a.cy],rotation:s.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return u});O(o,function(s){s.build(),this.group.add(s.group)},this)},e.prototype._buildSplitLineAndArea=function(t){var n=t.coordinateSystem,a=n.getIndicatorAxes();if(!a.length)return;var i=t.get("shape"),o=t.getModel("splitLine"),s=t.getModel("splitArea"),l=o.getModel("lineStyle"),u=s.getModel("areaStyle"),c=o.get("show"),f=s.get("show"),d=l.get("color"),v=u.get("color"),g=ce(d)?d:[d],y=ce(v)?v:[v],x=[],b=[];function w(V,j,U){var F=U%j.length;return V[F]=V[F]||[],F}if(i==="circle")for(var T=a[0].getTicksCoords(),C=n.cx,D=n.cy,M=0;M<T.length;M++){if(c){var N=w(x,g,M);x[N].push(new eo({shape:{cx:C,cy:D,r:T[M].coord}}))}if(f&&M<T.length-1){var N=w(b,y,M);b[N].push(new td({shape:{cx:C,cy:D,r0:T[M].coord,r:T[M+1].coord}}))}}else for(var R,E=fe(a,function(V,j){var U=V.getTicksCoords();return R=R==null?U.length-1:Math.min(U.length-1,R),fe(U,function(F){return n.coordToPoint(F.coord,j)})}),k=[],M=0;M<=R;M++){for(var I=[],B=0;B<a.length;B++)I.push(E[B][M]);if(I[0]&&I.push(I[0].slice()),c){var N=w(x,g,M);x[N].push(new Ur({shape:{points:I}}))}if(f&&k){var N=w(b,y,M-1);b[N].push(new an({shape:{points:I.concat(k)}}))}k=I.slice().reverse()}var P=l.getLineStyle(),H=u.getAreaStyle();O(b,function(V,j){this.group.add(ta(V,{style:Re({stroke:"none",fill:y[j%y.length]},H),silent:!0}))},this),O(x,function(V,j){this.group.add(ta(V,{style:Re({fill:"none",stroke:g[j%g.length]},P),silent:!0}))},this)},e.type="radar",e})(Rt),nde=(function(r){K(e,r);function e(t,n,a){var i=r.call(this,t,n,a)||this;return i.type="value",i.angle=0,i.name="",i}return e})(Va),ade=(function(){function r(e,t,n){this.dimensions=[],this._model=e,this._indicatorAxes=fe(e.getIndicatorModels(),function(a,i){var o="indicator_"+i,s=new nde(o,new es);return s.name=a.get("name"),s.model=a,a.axis=s,this.dimensions.push(o),s},this),this.resize(e,n)}return r.prototype.getIndicatorAxes=function(){return this._indicatorAxes},r.prototype.dataToPoint=function(e,t){var n=this._indicatorAxes[t];return this.coordToPoint(n.dataToCoord(e),t)},r.prototype.coordToPoint=function(e,t){var n=this._indicatorAxes[t],a=n.angle,i=this.cx+e*Math.cos(a),o=this.cy-e*Math.sin(a);return[i,o]},r.prototype.pointToData=function(e){var t=e[0]-this.cx,n=e[1]-this.cy,a=Math.sqrt(t*t+n*n);t/=a,n/=a;for(var i=Math.atan2(-n,t),o=1/0,s,l=-1,u=0;u<this._indicatorAxes.length;u++){var c=this._indicatorAxes[u],f=Math.abs(i-c.angle);f<o&&(s=c,l=u,o=f)}return[l,+(s&&s.coordToData(a))]},r.prototype.resize=function(e,t){var n=Cr(e,t).refContainer,a=e.get("center"),i=Math.min(n.width,n.height)/2;this.cx=me(a[0],n.width)+n.x,this.cy=me(a[1],n.height)+n.y,this.startAngle=e.get("startAngle")*Math.PI/180;var o=e.get("radius");(ye(o)||st(o))&&(o=[0,o]),this.r0=me(o[0],i),this.r=me(o[1],i),O(this._indicatorAxes,function(s,l){s.setExtent(this.r0,this.r);var u=this.startAngle+l*Math.PI*2/this._indicatorAxes.length;u=Math.atan2(Math.sin(u),Math.cos(u)),s.angle=u},this)},r.prototype.update=function(e,t){var n=this._indicatorAxes,a=this._model;O(n,function(s){s.scale.setExtent(1/0,-1/0)}),e.eachSeriesByType("radar",function(s,l){if(!(s.get("coordinateSystem")!=="radar"||e.getComponent("radar",s.get("radarIndex"))!==a)){var u=s.getData();O(n,function(c){c.scale.unionExtentFromData(u,u.mapDimension(c.dim))})}},this);var i=a.get("splitNumber"),o=new es;o.setExtent(0,i),o.setInterval(1),O(n,function(s,l){lU(s.scale,s.model,o)})},r.prototype.convertToPixel=function(e,t,n){return console.warn("Not implemented."),null},r.prototype.convertFromPixel=function(e,t,n){return console.warn("Not implemented."),null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.create=function(e,t){var n=[];return e.eachComponent("radar",function(a){var i=new r(a,e,t);n.push(i),a.coordinateSystem=i}),e.eachSeriesByType("radar",function(a){a.get("coordinateSystem")==="radar"&&(a.coordinateSystem=n[a.get("radarIndex")||0])}),n},r.dimensions=[],r})();function ide(r){r.registerCoordinateSystem("radar",ade),r.registerComponentModel(tde),r.registerComponentView(rde),r.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(n){t.setItemVisual(n,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}function ode(r){We(ide),r.registerChartView(Jhe),r.registerSeriesModel(ede),r.registerLayout(Khe),r.registerProcessor(pd("radar")),r.registerPreprocessor(Qhe)}var MN=Je();function sde(r,e,t){MN(r)[e]=t}function lde(r,e,t){var n=MN(r),a=n[e];a===t&&(n[e]=null)}function oj(r,e){return!!MN(r)[e]}ui({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},Kt);var ude={axisPointer:1,tooltip:1,brush:1};function gU(r,e,t){var n=e.getComponentByElement(r.topTarget);if(!n||n===t||ude.hasOwnProperty(n.mainType))return!1;var a=n.coordinateSystem;if(!a||a.model===t)return!1;var i=dc(n),o=dc(t);return!((i.zlevel-o.zlevel||i.z-o.z)<=0)}var Ac=(function(r){K(e,r);function e(t){var n=r.call(this)||this;n._zr=t;var a=xe(n._mousedownHandler,n),i=xe(n._mousemoveHandler,n),o=xe(n._mouseupHandler,n),s=xe(n._mousewheelHandler,n),l=xe(n._pinchHandler,n);return n.enable=function(u,c){var f=c.zInfo,d=dc(f.component),v=d.z,g=d.zlevel,y={component:f.component,z:v,zlevel:g,z2:Ce(f.z2,-1/0)},x=ie({},c.triggerInfo);this._opt=Re(ie({},c),{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0,zInfoParsed:y,triggerInfo:x}),u==null&&(u=!0),(!this._enabled||this._controlType!==u)&&(this._enabled=!0,this.disable(),(u===!0||u==="move"||u==="pan")&&(Gv(t,"mousedown",a,y),Gv(t,"mousemove",i,y),Gv(t,"mouseup",o,y)),(u===!0||u==="scale"||u==="zoom")&&(Gv(t,"mousewheel",s,y),Gv(t,"pinch",l,y)))},n.disable=function(){this._enabled=!1,Hv(t,"mousedown",a),Hv(t,"mousemove",i),Hv(t,"mouseup",o),Hv(t,"mousewheel",s),Hv(t,"pinch",l)},n}return e.prototype.isDragging=function(){return this._dragging},e.prototype.isPinching=function(){return this._pinching},e.prototype._checkPointer=function(t,n,a){var i=this._opt,o=i.zInfoParsed;if(gU(t,i.api,o.component))return!1;var s=i.triggerInfo,l=s.roamTrigger,u=!1;return l==="global"&&(u=!0),u||(u=s.isInSelf(t,n,a)),u&&s.isInClip&&!s.isInClip(t,n,a)&&(u=!1),u},e.prototype._decideCursorStyle=function(t,n,a,i){var o=t.target;if(!o&&this._checkPointer(t,n,a))return"grab";if(i)return o&&o.cursor||"default"},e.prototype.dispose=function(){this.disable()},e.prototype._mousedownHandler=function(t){if(!(MO(t)||Vv(t))){for(var n=t.target;n;){if(n.draggable)return;n=n.__hostTarget||n.parent}var a=t.offsetX,i=t.offsetY;this._checkPointer(t,a,i)&&(this._x=a,this._y=i,this._dragging=!0)}},e.prototype._mousemoveHandler=function(t){var n=this._zr;if(!(t.gestureEvent==="pinch"||oj(n,"globalPan")||Vv(t))){var a=t.offsetX,i=t.offsetY;if(!this._dragging||!sx("moveOnMouseMove",t,this._opt)){var o=this._decideCursorStyle(t,a,i,!1);o&&n.setCursorStyle(o);return}n.setCursorStyle("grabbing");var s=this._x,l=this._y,u=a-s,c=i-l;this._x=a,this._y=i,this._opt.preventDefaultMouseMove&&Zo(t.event),t.__ecRoamConsumed=!0,sj(this,"pan","moveOnMouseMove",t,{dx:u,dy:c,oldX:s,oldY:l,newX:a,newY:i,isAvailableBehavior:null})}},e.prototype._mouseupHandler=function(t){if(!Vv(t)){var n=this._zr;if(!MO(t)){this._dragging=!1;var a=this._decideCursorStyle(t,t.offsetX,t.offsetY,!0);a&&n.setCursorStyle(a)}}},e.prototype._mousewheelHandler=function(t){if(!Vv(t)){var n=sx("zoomOnMouseWheel",t,this._opt),a=sx("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,o=Math.abs(i),s=t.offsetX,l=t.offsetY;if(!(i===0||!n&&!a)){if(n){var u=o>3?1.4:o>1?1.2:1.1,c=i>0?u:1/u;this._checkTriggerMoveZoom(this,"zoom","zoomOnMouseWheel",t,{scale:c,originX:s,originY:l,isAvailableBehavior:null})}if(a){var f=Math.abs(i),d=(i>0?1:-1)*(f>3?.4:f>1?.15:.05);this._checkTriggerMoveZoom(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:d,originX:s,originY:l,isAvailableBehavior:null})}}}},e.prototype._pinchHandler=function(t){if(!(oj(this._zr,"globalPan")||Vv(t))){var n=t.pinchScale>1?1.1:1/1.1;this._checkTriggerMoveZoom(this,"zoom",null,t,{scale:n,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e.prototype._checkTriggerMoveZoom=function(t,n,a,i,o){t._checkPointer(i,o.originX,o.originY)&&(Zo(i.event),i.__ecRoamConsumed=!0,sj(t,n,a,i,o))},e})(za);function Vv(r){return r.__ecRoamConsumed}var cde=Je();function _b(r){var e=cde(r);return e.roam=e.roam||{},e.uniform=e.uniform||{},e}function Gv(r,e,t,n){for(var a=_b(r),i=a.roam,o=i[e]=i[e]||[],s=0;s<o.length;s++){var l=o[s].zInfoParsed;if((l.zlevel-n.zlevel||l.z-n.z||l.z2-n.z2)<=0)break}o.splice(s,0,{listener:t,zInfoParsed:n}),fde(r,e)}function Hv(r,e,t){for(var n=_b(r),a=n.roam[e]||[],i=0;i<a.length;i++)if(a[i].listener===t){a.splice(i,1),a.length||hde(r,e);return}}function fde(r,e){var t=_b(r);t.uniform[e]||r.on(e,t.uniform[e]=function(n){var a=t.roam[e];if(a)for(var i=0;i<a.length;i++)a[i].listener(n)})}function hde(r,e){var t=_b(r),n=t.uniform;n[e]&&(r.off(e,n[e]),n[e]=null)}function sj(r,e,t,n,a){a.isAvailableBehavior=xe(sx,null,t,n),r.trigger(e,a)}function sx(r,e,t){var n=t[r];return!r||n&&(!ye(n)||e.event[n+"Key"])}function DN(r,e,t){var n=r.target;n.x+=e,n.y+=t,n.dirty()}function NN(r,e,t,n){var a=r.target,i=r.zoomLimit,o=r.zoom=r.zoom||1;o*=e,o=LN(o,i);var s=o/r.zoom;r.zoom=o,yU(a,t,n,s),a.dirty()}function mU(r,e,t,n,a,i){var o=new Oe(0,0,0,0);n.enable(r.get("roam"),{api:e,zInfo:{component:r},triggerInfo:{roamTrigger:r.get("roamTrigger"),isInSelf:function(u,c,f){return o.copy(t.getBoundingRect()),o.applyTransform(t.getComputedTransform()),o.contain(c,f)},isInClip:function(u,c,f){return!i||i.contain(c,f)}}}),a.zoomLimit=r.get("scaleLimit");var s=r.coordinateSystem;a.zoom=s?s.getZoom():1;var l=r.subType+"Roam";n.off("pan").off("zoom").on("pan",function(u){DN(a,u.dx,u.dy),e.dispatchAction({seriesId:r.id,type:l,dx:u.dx,dy:u.dy})}).on("zoom",function(u){NN(a,u.scale,u.originX,u.originY),e.dispatchAction({seriesId:r.id,type:l,zoom:u.scale,originX:u.originX,originY:u.originY}),e.updateLabelLayout()})}function lj(r,e){return r.pointToProjected?r.pointToProjected(e):r.pointToData(e)}function Sb(r,e,t){var n=r.getZoom(),a=r.getCenter(),i=e.zoom,o=r.projectedToPoint?r.projectedToPoint(a):r.dataToPoint(a);return e.dx!=null&&e.dy!=null&&(o[0]-=e.dx,o[1]-=e.dy,r.setCenter(lj(r,o))),i!=null&&(i=LN(n*i,t)/n,yU(r,e.originX,e.originY,i),r.updateTransform(),r.setCenter(lj(r,o)),r.setZoom(i*n)),{center:r.getCenter(),zoom:r.getZoom()}}function yU(r,e,t,n){r.x-=(e-r.x)*(n-1),r.y-=(t-r.y)*(n-1),r.scaleX*=n,r.scaleY*=n}function LN(r,e){if(e){var t=e.min||0,n=e.max||1/0;r=Math.max(Math.min(n,r),t)}return r}function xU(r){if(ye(r)){var e=new DOMParser;r=e.parseFromString(r,"text/xml")}var t=r;for(t.nodeType===9&&(t=t.firstChild);t.nodeName.toLowerCase()!=="svg"||t.nodeType!==1;)t=t.nextSibling;return t}var S2,h1={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},uj=it(h1),d1={"alignment-baseline":"textBaseline","stop-color":"stopColor"},cj=it(d1),dde=(function(){function r(){this._defs={},this._root=null}return r.prototype.parse=function(e,t){t=t||{};var n=xU(e);this._defsUsePending=[];var a=new Ne;this._root=a;var i=[],o=n.getAttribute("viewBox")||"",s=parseFloat(n.getAttribute("width")||t.width),l=parseFloat(n.getAttribute("height")||t.height);isNaN(s)&&(s=null),isNaN(l)&&(l=null),Zn(n,a,null,!0,!1);for(var u=n.firstChild;u;)this._parseNode(u,a,i,null,!1,!1),u=u.nextSibling;gde(this._defs,this._defsUsePending),this._defsUsePending=[];var c,f;if(o){var d=wb(o);d.length>=4&&(c={x:parseFloat(d[0]||0),y:parseFloat(d[1]||0),width:parseFloat(d[2]),height:parseFloat(d[3])})}if(c&&s!=null&&l!=null&&(f=_U(c,{x:0,y:0,width:s,height:l}),!t.ignoreViewBox)){var v=a;a=new Ne,a.add(v),v.scaleX=v.scaleY=f.scale,v.x=f.x,v.y=f.y}return!t.ignoreRootClip&&s!=null&&l!=null&&a.setClipPath(new qe({shape:{x:0,y:0,width:s,height:l}})),{root:a,width:s,height:l,viewBoxRect:c,viewBoxTransform:f,named:i}},r.prototype._parseNode=function(e,t,n,a,i,o){var s=e.nodeName.toLowerCase(),l,u=a;if(s==="defs"&&(i=!0),s==="text"&&(o=!0),s==="defs"||s==="switch")l=t;else{if(!i){var c=S2[s];if(c&&_e(S2,s)){l=c.call(this,e,t);var f=e.getAttribute("name");if(f){var d={name:f,namedFrom:null,svgNodeTagLower:s,el:l};n.push(d),s==="g"&&(u=d)}else a&&n.push({name:a.name,namedFrom:a,svgNodeTagLower:s,el:l});t.add(l)}}var v=fj[s];if(v&&_e(fj,s)){var g=v.call(this,e),y=e.getAttribute("id");y&&(this._defs[y]=g)}}if(l&&l.isGroup)for(var x=e.firstChild;x;)x.nodeType===1?this._parseNode(x,l,n,u,i,o):x.nodeType===3&&o&&this._parseText(x,l),x=x.nextSibling},r.prototype._parseText=function(e,t){var n=new Ih({style:{text:e.textContent},silent:!0,x:this._textX||0,y:this._textY||0});ba(t,n),Zn(e,n,this._defsUsePending,!1,!1),vde(n,t);var a=n.style,i=a.fontSize;i&&i<9&&(a.fontSize=9,n.scaleX*=i/9,n.scaleY*=i/9);var o=(a.fontSize||a.fontFamily)&&[a.fontStyle,a.fontWeight,(a.fontSize||12)+"px",a.fontFamily||"sans-serif"].join(" ");a.font=o;var s=n.getBoundingRect();return this._textX+=s.width,t.add(n),n},r.internalField=(function(){S2={g:function(e,t){var n=new Ne;return ba(t,n),Zn(e,n,this._defsUsePending,!1,!1),n},rect:function(e,t){var n=new qe;return ba(t,n),Zn(e,n,this._defsUsePending,!1,!1),n.setShape({x:parseFloat(e.getAttribute("x")||"0"),y:parseFloat(e.getAttribute("y")||"0"),width:parseFloat(e.getAttribute("width")||"0"),height:parseFloat(e.getAttribute("height")||"0")}),n.silent=!0,n},circle:function(e,t){var n=new eo;return ba(t,n),Zn(e,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),r:parseFloat(e.getAttribute("r")||"0")}),n.silent=!0,n},line:function(e,t){var n=new lr;return ba(t,n),Zn(e,n,this._defsUsePending,!1,!1),n.setShape({x1:parseFloat(e.getAttribute("x1")||"0"),y1:parseFloat(e.getAttribute("y1")||"0"),x2:parseFloat(e.getAttribute("x2")||"0"),y2:parseFloat(e.getAttribute("y2")||"0")}),n.silent=!0,n},ellipse:function(e,t){var n=new Yg;return ba(t,n),Zn(e,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),rx:parseFloat(e.getAttribute("rx")||"0"),ry:parseFloat(e.getAttribute("ry")||"0")}),n.silent=!0,n},polygon:function(e,t){var n=e.getAttribute("points"),a;n&&(a=vj(n));var i=new an({shape:{points:a||[]},silent:!0});return ba(t,i),Zn(e,i,this._defsUsePending,!1,!1),i},polyline:function(e,t){var n=e.getAttribute("points"),a;n&&(a=vj(n));var i=new Ur({shape:{points:a||[]},silent:!0});return ba(t,i),Zn(e,i,this._defsUsePending,!1,!1),i},image:function(e,t){var n=new Ir;return ba(t,n),Zn(e,n,this._defsUsePending,!1,!1),n.setStyle({image:e.getAttribute("xlink:href")||e.getAttribute("href"),x:+e.getAttribute("x"),y:+e.getAttribute("y"),width:+e.getAttribute("width"),height:+e.getAttribute("height")}),n.silent=!0,n},text:function(e,t){var n=e.getAttribute("x")||"0",a=e.getAttribute("y")||"0",i=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0";this._textX=parseFloat(n)+parseFloat(i),this._textY=parseFloat(a)+parseFloat(o);var s=new Ne;return ba(t,s),Zn(e,s,this._defsUsePending,!1,!0),s},tspan:function(e,t){var n=e.getAttribute("x"),a=e.getAttribute("y");n!=null&&(this._textX=parseFloat(n)),a!=null&&(this._textY=parseFloat(a));var i=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0",s=new Ne;return ba(t,s),Zn(e,s,this._defsUsePending,!1,!0),this._textX+=parseFloat(i),this._textY+=parseFloat(o),s},path:function(e,t){var n=e.getAttribute("d")||"",a=jH(n);return ba(t,a),Zn(e,a,this._defsUsePending,!1,!1),a.silent=!0,a}}})(),r})(),fj={lineargradient:function(r){var e=parseInt(r.getAttribute("x1")||"0",10),t=parseInt(r.getAttribute("y1")||"0",10),n=parseInt(r.getAttribute("x2")||"10",10),a=parseInt(r.getAttribute("y2")||"0",10),i=new bc(e,t,n,a);return hj(r,i),dj(r,i),i},radialgradient:function(r){var e=parseInt(r.getAttribute("cx")||"0",10),t=parseInt(r.getAttribute("cy")||"0",10),n=parseInt(r.getAttribute("r")||"0",10),a=new xD(e,t,n);return hj(r,a),dj(r,a),a}};function hj(r,e){var t=r.getAttribute("gradientUnits");t==="userSpaceOnUse"&&(e.global=!0)}function dj(r,e){for(var t=r.firstChild;t;){if(t.nodeType===1&&t.nodeName.toLocaleLowerCase()==="stop"){var n=t.getAttribute("offset"),a=void 0;n&&n.indexOf("%")>0?a=parseInt(n,10)/100:n?a=parseFloat(n):a=0;var i={};bU(t,i,i);var o=i.stopColor||t.getAttribute("stop-color")||"#000000",s=i.stopOpacity||t.getAttribute("stop-opacity");if(s){var l=vn(o),u=l&&l[3];u&&(l[3]*=Vo(s),o=Ea(l,"rgba"))}e.colorStops.push({offset:a,color:o})}t=t.nextSibling}}function ba(r,e){r&&r.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),Re(e.__inheritedStyle,r.__inheritedStyle))}function vj(r){for(var e=wb(r),t=[],n=0;n<e.length;n+=2){var a=parseFloat(e[n]),i=parseFloat(e[n+1]);t.push([a,i])}return t}function Zn(r,e,t,n,a){var i=e,o=i.__inheritedStyle=i.__inheritedStyle||{},s={};r.nodeType===1&&(xde(r,e),bU(r,o,s),n||bde(r,o,s)),i.style=i.style||{},o.fill!=null&&(i.style.fill=pj(i,"fill",o.fill,t)),o.stroke!=null&&(i.style.stroke=pj(i,"stroke",o.stroke,t)),O(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(l){o[l]!=null&&(i.style[l]=parseFloat(o[l]))}),O(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign"],function(l){o[l]!=null&&(i.style[l]=o[l])}),a&&(i.__selfStyle=s),o.lineDash&&(i.style.lineDash=fe(wb(o.lineDash),function(l){return parseFloat(l)})),(o.visibility==="hidden"||o.visibility==="collapse")&&(i.invisible=!0),o.display==="none"&&(i.ignore=!0)}function vde(r,e){var t=e.__selfStyle;if(t){var n=t.textBaseline,a=n;!n||n==="auto"||n==="baseline"?a="alphabetic":n==="before-edge"||n==="text-before-edge"?a="top":n==="after-edge"||n==="text-after-edge"?a="bottom":(n==="central"||n==="mathematical")&&(a="middle"),r.style.textBaseline=a}var i=e.__inheritedStyle;if(i){var o=i.textAlign,s=o;o&&(o==="middle"&&(s="center"),r.style.textAlign=s)}}var pde=/^url\(\s*#(.*?)\)/;function pj(r,e,t,n){var a=t&&t.match(pde);if(a){var i=ra(a[1]);n.push([r,e,i]);return}return t==="none"&&(t=null),t}function gde(r,e){for(var t=0;t<e.length;t++){var n=e[t];n[0].style[n[1]]=r[n[2]]}}var mde=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function wb(r){return r.match(mde)||[]}var yde=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.eE,]*)\)/g,w2=Math.PI/180;function xde(r,e){var t=r.getAttribute("transform");if(t){t=t.replace(/,/g," ");var n=[],a=null;t.replace(yde,function(f,d,v){return n.push(d,v),""});for(var i=n.length-1;i>0;i-=2){var o=n[i],s=n[i-1],l=wb(o);switch(a=a||Rr(),s){case"translate":ii(a,a,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":Z1(a,a,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":ns(a,a,-parseFloat(l[0])*w2,[parseFloat(l[1]||"0"),parseFloat(l[2]||"0")]);break;case"skewX":var u=Math.tan(parseFloat(l[0])*w2);Ja(a,[1,0,u,1,0,0],a);break;case"skewY":var c=Math.tan(parseFloat(l[0])*w2);Ja(a,[1,c,0,1,0,0],a);break;case"matrix":a[0]=parseFloat(l[0]),a[1]=parseFloat(l[1]),a[2]=parseFloat(l[2]),a[3]=parseFloat(l[3]),a[4]=parseFloat(l[4]),a[5]=parseFloat(l[5]);break}}e.setLocalTransform(a)}}var gj=/([^\s:;]+)\s*:\s*([^:;]+)/g;function bU(r,e,t){var n=r.getAttribute("style");if(n){gj.lastIndex=0;for(var a;(a=gj.exec(n))!=null;){var i=a[1],o=_e(h1,i)?h1[i]:null;o&&(e[o]=a[2]);var s=_e(d1,i)?d1[i]:null;s&&(t[s]=a[2])}}}function bde(r,e,t){for(var n=0;n<uj.length;n++){var a=uj[n],i=r.getAttribute(a);i!=null&&(e[h1[a]]=i)}for(var n=0;n<cj.length;n++){var a=cj[n],i=r.getAttribute(a);i!=null&&(t[d1[a]]=i)}}function _U(r,e){var t=e.width/r.width,n=e.height/r.height,a=Math.min(t,n);return{scale:a,x:-(r.x+r.width/2)*a+(e.x+e.width/2),y:-(r.y+r.height/2)*a+(e.y+e.height/2)}}function _de(r,e){var t=new dde;return t.parse(r,e)}var Sde=Te(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),wde=(function(){function r(e,t){this.type="geoSVG",this._usedGraphicMap=Te(),this._freedGraphics=[],this._mapName=e,this._parsedXML=xU(t)}return r.prototype.load=function(){var e=this._firstGraphic;if(!e){e=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(e),this._boundingRect=this._firstGraphic.boundingRect.clone();var t=Cde(e.named),n=t.regions,a=t.regionsMap;this._regions=n,this._regionsMap=a}return{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},r.prototype._buildGraphic=function(e){var t,n;try{t=e&&_de(e,{ignoreViewBox:!0,ignoreRootClip:!0})||{},n=t.root,rn(n!=null)}catch(x){throw new Error(`Invalid svg format
281
- `+x.message)}var a=new Ne;a.add(n),a.isGeoSVGGraphicRoot=!0;var i=t.width,o=t.height,s=t.viewBoxRect,l=this._boundingRect;if(!l){var u=void 0,c=void 0,f=void 0,d=void 0;if(i!=null?(u=0,f=i):s&&(u=s.x,f=s.width),o!=null?(c=0,d=o):s&&(c=s.y,d=s.height),u==null||c==null){var v=n.getBoundingRect();u==null&&(u=v.x,f=v.width),c==null&&(c=v.y,d=v.height)}l=this._boundingRect=new Oe(u,c,f,d)}if(s){var g=_U(s,l);n.scaleX=n.scaleY=g.scale,n.x=g.x,n.y=g.y}a.setClipPath(new qe({shape:l.plain()}));var y=[];return O(t.named,function(x){Sde.get(x.svgNodeTagLower)!=null&&(y.push(x),Tde(x.el))}),{root:a,boundingRect:l,named:y}},r.prototype.useGraphic=function(e){var t=this._usedGraphicMap,n=t.get(e);return n||(n=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),t.set(e,n),n)},r.prototype.freeGraphic=function(e){var t=this._usedGraphicMap,n=t.get(e);n&&(t.removeKey(e),this._freedGraphics.push(n))},r})();function Tde(r){r.silent=!1,r.isGroup&&r.traverse(function(e){e.silent=!1})}function Cde(r){var e=[],t=Te();return O(r,function(n){if(n.namedFrom==null){var a=new Eue(n.name,n.el);e.push(a),t.set(n.name,a)}}),{regions:e,regionsMap:t}}var RA=[126,25],mj="南海诸岛",Mu=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]];for(var Tu=0;Tu<Mu.length;Tu++)for(var Rf=0;Rf<Mu[Tu].length;Rf++)Mu[Tu][Rf][0]/=10.5,Mu[Tu][Rf][1]/=-10.5/.75,Mu[Tu][Rf][0]+=RA[0],Mu[Tu][Rf][1]+=RA[1];function Ade(r,e){if(r==="china"){for(var t=0;t<e.length;t++)if(e[t].name===mj)return;e.push(new n7(mj,fe(Mu,function(n){return{type:"polygon",exterior:n}}),RA))}}var Mde={南海诸岛:[32,80],广东:[0,-10],香港:[10,5],澳门:[-10,10],天津:[5,5]};function Dde(r,e){if(r==="china"){var t=Mde[e.name];if(t){var n=e.getCenter();n[0]+=t[0]/10.5,n[1]+=-t[1]/(10.5/.75),e.setCenter(n)}}}var Nde=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];function Lde(r,e){r==="china"&&e.name==="台湾"&&e.geometries.push({type:"polygon",exterior:Nde[0]})}var Rde="name",Ede=(function(){function r(e,t,n){this.type="geoJSON",this._parsedMap=Te(),this._mapName=e,this._specialAreas=n,this._geoJSON=Ide(t)}return r.prototype.load=function(e,t){t=t||Rde;var n=this._parsedMap.get(t);if(!n){var a=this._parseToRegions(t);n=this._parsedMap.set(t,{regions:a,boundingRect:kde(a)})}var i=Te(),o=[];return O(n.regions,function(s){var l=s.name;e&&_e(e,l)&&(s=s.cloneShallow(l=e[l])),o.push(s),i.set(l,s)}),{regions:o,boundingRect:n.boundingRect||new Oe(0,0,0,0),regionsMap:i}},r.prototype._parseToRegions=function(e){var t=this._mapName,n=this._geoJSON,a;try{a=n?vA(n,e):[]}catch(i){throw new Error(`Invalid geoJson format
282
- `+i.message)}return Ade(t,a),O(a,function(i){var o=i.name;Dde(t,i),Lde(t,i);var s=this._specialAreas&&this._specialAreas[o];s&&i.transformTo(s.left,s.top,s.width,s.height)},this),a},r.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}},r})();function kde(r){for(var e,t=0;t<r.length;t++){var n=r[t].getBoundingRect();e=e||n.clone(),e.union(n)}return e}function Ide(r){return ye(r)?typeof JSON<"u"&&JSON.parse?JSON.parse(r):new Function("return ("+r+");")():r}var Fv=Te();const ts={registerMap:function(r,e,t){if(e.svg){var n=new wde(r,e.svg);Fv.set(r,n)}else{var a=e.geoJson||e.geoJSON;a&&!e.features?t=e.specialAreas:a=e;var n=new Ede(r,a,t);Fv.set(r,n)}},getGeoResource:function(r){return Fv.get(r)},getMapForUser:function(r){var e=Fv.get(r);return e&&e.type==="geoJSON"&&e.getMapForUser()},load:function(r,e,t){var n=Fv.get(r);if(n)return n.load(e,t)}};var RN=["rect","circle","line","ellipse","polygon","polyline","path"],Ode=Te(RN),Pde=Te(RN.concat(["g"])),jde=Te(RN.concat(["g"])),SU=Je();function y0(r){var e=r.getItemStyle(),t=r.get("areaColor");return t!=null&&(e.fill=t),e}function yj(r){var e=r.style;e&&(e.stroke=e.stroke||e.fill,e.fill=null)}var wU=(function(){function r(e){var t=this.group=new Ne,n=this._transformGroup=new Ne;t.add(n),this.uid=od("ec_map_draw"),this._controller=new Ac(e.getZr()),this._controllerHost={target:n},n.add(this._regionsGroup=new Ne),n.add(this._svgGroup=new Ne)}return r.prototype.draw=function(e,t,n,a,i){var o=e.mainType==="geo",s=e.getData&&e.getData();o&&t.eachComponent({mainType:"series",subType:"map"},function(T){!s&&T.getHostGeoModel()===e&&(s=T.getData())});var l=e.coordinateSystem,u=this._regionsGroup,c=this._transformGroup,f=l.getTransformInfo(),d=f.raw,v=f.roam,g=!u.childAt(0)||i,y=e.getShallow("clip",!0),x;y?(x=l.getViewRect().clone(),this.group.setClipPath(new qe({shape:x.clone()}))):this.group.removeClipPath(),g?(c.x=v.x,c.y=v.y,c.scaleX=v.scaleX,c.scaleY=v.scaleY,c.dirty()):lt(c,v,e);var b=s&&s.getVisual("visualMeta")&&s.getVisual("visualMeta").length>0,w={api:n,geo:l,mapOrGeoModel:e,data:s,isVisualEncodedByVisualMap:b,isGeo:o,transformInfoRaw:d};l.resourceType==="geoJSON"?this._buildGeoJSON(w):l.resourceType==="geoSVG"&&this._buildSVG(w),this._updateController(e,x,t,n),this._updateMapSelectHandler(e,u,n,a)},r.prototype._buildGeoJSON=function(e){var t=this._regionsGroupByName=Te(),n=Te(),a=this._regionsGroup,i=e.transformInfoRaw,o=e.mapOrGeoModel,s=e.data,l=e.geo.projection,u=l&&l.stream;function c(v,g){return g&&(v=g(v)),v&&[v[0]*i.scaleX+i.x,v[1]*i.scaleY+i.y]}function f(v){for(var g=[],y=!u&&l&&l.project,x=0;x<v.length;++x){var b=c(v[x],y);b&&g.push(b)}return g}function d(v){return{shape:{points:f(v)}}}a.removeAll(),O(e.geo.regions,function(v){var g=v.name,y=t.get(g),x=n.get(g)||{},b=x.dataIdx,w=x.regionModel;if(!y){y=t.set(g,new Ne),a.add(y),b=s?s.indexOfName(g):null,w=e.isGeo?o.getRegionModel(g):s?s.getItemModel(b):null;var T=w.get("silent",!0);T!=null&&(y.silent=T),n.set(g,{dataIdx:b,regionModel:w})}var C=[],D=[];O(v.geometries,function(R){if(R.type==="polygon"){var E=[R.exterior].concat(R.interiors||[]);u&&(E=Tj(E,u)),O(E,function(I){C.push(new an(d(I)))})}else{var k=R.points;u&&(k=Tj(k,u,!0)),O(k,function(I){D.push(new Ur(d(I)))})}});var M=c(v.getCenter(),l&&l.project);function N(R,E){if(R.length){var k=new Xg({culling:!0,segmentIgnoreThreshold:1,shape:{paths:R}});y.add(k),xj(e,k,b,w),bj(e,k,g,w,o,b,M),E&&(yj(k),O(k.states,yj))}}N(C),N(D,!0)}),t.each(function(v,g){var y=n.get(g),x=y.dataIdx,b=y.regionModel;_j(e,v,g,b,o,x),Sj(e,v,g,b,o),wj(e,v,g,b,o)},this)},r.prototype._buildSVG=function(e){var t=e.geo.map,n=e.transformInfoRaw;this._svgGroup.x=n.x,this._svgGroup.y=n.y,this._svgGroup.scaleX=n.scaleX,this._svgGroup.scaleY=n.scaleY,this._svgResourceChanged(t)&&(this._freeSVG(),this._useSVG(t));var a=this._svgDispatcherMap=Te(),i=!1;O(this._svgGraphicRecord.named,function(o){var s=o.name,l=e.mapOrGeoModel,u=e.data,c=o.svgNodeTagLower,f=o.el,d=u?u.indexOfName(s):null,v=l.getRegionModel(s);Ode.get(c)!=null&&f instanceof Pa&&xj(e,f,d,v),f instanceof Pa&&(f.culling=!0);var g=v.get("silent",!0);if(g!=null&&(f.silent=g),f.z2EmphasisLift=0,!o.namedFrom&&(jde.get(c)!=null&&bj(e,f,s,v,l,d,null),_j(e,f,s,v,l,d),Sj(e,f,s,v,l),Pde.get(c)!=null)){var y=wj(e,f,s,v,l);y==="self"&&(i=!0);var x=a.get(s)||a.set(s,[]);x.push(f)}},this),this._enableBlurEntireSVG(i,e)},r.prototype._enableBlurEntireSVG=function(e,t){if(e&&t.isGeo){var n=t.mapOrGeoModel.getModel(["blur","itemStyle"]).getItemStyle(),a=n.opacity;this._svgGraphicRecord.root.traverse(function(i){if(!i.isGroup){fc(i);var o=i.ensureState("blur").style||{};o.opacity==null&&a!=null&&(o.opacity=a),i.ensureState("emphasis")}})}},r.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.dispose(),this._controllerHost=null},r.prototype.findHighDownDispatchers=function(e,t){if(e==null)return[];var n=t.coordinateSystem;if(n.resourceType==="geoJSON"){var a=this._regionsGroupByName;if(a){var i=a.get(e);return i?[i]:[]}}else if(n.resourceType==="geoSVG")return this._svgDispatcherMap&&this._svgDispatcherMap.get(e)||[]},r.prototype._svgResourceChanged=function(e){return this._svgMapName!==e},r.prototype._useSVG=function(e){var t=ts.getGeoResource(e);if(t&&t.type==="geoSVG"){var n=t.useGraphic(this.uid);this._svgGroup.add(n.root),this._svgGraphicRecord=n,this._svgMapName=e}},r.prototype._freeSVG=function(){var e=this._svgMapName;if(e!=null){var t=ts.getGeoResource(e);t&&t.type==="geoSVG"&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null}},r.prototype._updateController=function(e,t,n,a){var i=e.coordinateSystem,o=this._controller,s=this._controllerHost;s.zoomLimit=e.get("scaleLimit"),s.zoom=i.getZoom(),o.enable(e.get("roam")||!1,{api:a,zInfo:{component:e},triggerInfo:{roamTrigger:e.get("roamTrigger"),isInSelf:function(c,f,d){return i.containPoint([f,d])},isInClip:function(c,f,d){return!t||t.contain(f,d)}}});var l=e.mainType;function u(){var c={type:"geoRoam",componentType:l};return c[l+"Id"]=e.id,c}o.off("pan").on("pan",function(c){this._mouseDownFlag=!1,DN(s,c.dx,c.dy),a.dispatchAction(ie(u(),{dx:c.dx,dy:c.dy,animation:{duration:0}}))},this),o.off("zoom").on("zoom",function(c){this._mouseDownFlag=!1,NN(s,c.scale,c.originX,c.originY),a.dispatchAction(ie(u(),{totalZoom:s.zoom,zoom:c.scale,originX:c.originX,originY:c.originY,animation:{duration:0}}))},this)},r.prototype.resetForLabelLayout=function(){this.group.traverse(function(e){var t=e.getTextContent();t&&(t.ignore=SU(t).ignore)})},r.prototype._updateMapSelectHandler=function(e,t,n,a){var i=this;t.off("mousedown"),t.off("click"),e.get("selectedMode")&&(t.on("mousedown",function(){i._mouseDownFlag=!0}),t.on("click",function(o){i._mouseDownFlag&&(i._mouseDownFlag=!1)}))},r})();function xj(r,e,t,n){var a=n.getModel("itemStyle"),i=n.getModel(["emphasis","itemStyle"]),o=n.getModel(["blur","itemStyle"]),s=n.getModel(["select","itemStyle"]),l=y0(a),u=y0(i),c=y0(s),f=y0(o),d=r.data;if(d){var v=d.getItemVisual(t,"style"),g=d.getItemVisual(t,"decal");r.isVisualEncodedByVisualMap&&v.fill&&(l.fill=v.fill),g&&(l.decal=zh(g,r.api))}e.setStyle(l),e.style.strokeNoScale=!0,e.ensureState("emphasis").style=u,e.ensureState("select").style=c,e.ensureState("blur").style=f,fc(e)}function bj(r,e,t,n,a,i,o){var s=r.data,l=r.isGeo,u=s&&isNaN(s.get(s.mapDimension("value"),i)),c=s&&s.getItemLayout(i);if(l||u||c&&c.showLabel){var f=l?t:i,d=void 0;(!s||i>=0)&&(d=a);var v=o?{normal:{align:"center",verticalAlign:"middle"}}:null;kr(e,Sr(n),{labelFetcher:d,labelDataIndex:f,defaultText:t},v);var g=e.getTextContent();if(g&&(SU(g).ignore=g.ignore,e.textConfig&&o)){var y=e.getBoundingRect().clone();e.textConfig.layoutRect=y,e.textConfig.position=[(o[0]-y.x)/y.width*100+"%",(o[1]-y.y)/y.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function _j(r,e,t,n,a,i){r.data?r.data.setItemGraphicEl(i,e):je(e).eventData={componentType:"geo",componentIndex:a.componentIndex,geoIndex:a.componentIndex,name:t,region:n&&n.option||{}}}function Sj(r,e,t,n,a){r.data||is({el:e,componentModel:a,itemName:t,itemTooltipOption:n.get("tooltip")})}function wj(r,e,t,n,a){e.highDownSilentOnTouch=!!a.get("selectedMode");var i=n.getModel("emphasis"),o=i.get("focus");return Ut(e,o,i.get("blurScope"),i.get("disabled")),r.isGeo&&Nae(e,a,t),o}function Tj(r,e,t){var n=[],a;function i(){a=[]}function o(){a.length&&(n.push(a),a=[])}var s=e({polygonStart:i,polygonEnd:o,lineStart:i,lineEnd:o,point:function(l,u){isFinite(l)&&isFinite(u)&&a.push([l,u])},sphere:function(){}});return!t&&s.polygonStart(),O(r,function(l){s.lineStart();for(var u=0;u<l.length;u++)s.point(l[u][0],l[u][1]);s.lineEnd()}),!t&&s.polygonEnd(),n}var zde=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){if(!(i&&i.type==="mapToggleSelect"&&i.from===this.uid)){var o=this.group;if(o.removeAll(),!t.getHostGeoModel()){if(this._mapDraw&&i&&i.type==="geoRoam"&&this._mapDraw.resetForLabelLayout(),i&&i.type==="geoRoam"&&i.componentType==="series"&&i.seriesId===t.id){var s=this._mapDraw;s&&o.add(s.group)}else if(t.needsDrawMap){var s=this._mapDraw||new wU(a);o.add(s.group),s.draw(t,n,a,this,i),this._mapDraw=s}else this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;t.get("showLegendSymbol")&&n.getComponent("legend")&&this._renderSymbols(t,n,a)}}},e.prototype.remove=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},e.prototype._renderSymbols=function(t,n,a){var i=t.originalData,o=this.group;i.each(i.mapDimension("value"),function(s,l){if(!isNaN(s)){var u=i.getItemLayout(l);if(!(!u||!u.point)){var c=u.point,f=u.offset,d=new eo({style:{fill:t.getData().getVisual("style").fill},shape:{cx:c[0]+f*9,cy:c[1],r:3},silent:!0,z2:8+(f?0:ed+1)});if(!f){var v=t.mainSeries.getData(),g=i.getName(l),y=v.indexOfName(g),x=i.getItemModel(l),b=x.getModel("label"),w=v.getItemGraphicEl(y);kr(d,Sr(x),{labelFetcher:{getFormattedLabel:function(T,C){return t.getFormattedLabel(y,C)}},defaultText:g}),d.disableLabelAnimation=!0,b.get("position")||d.setTextConfig({position:"bottom"}),w.onHoverStateChange=function(T){Vx(d,T)}}o.add(d)}}})},e.type="map",e})(St),Bde=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.needsDrawMap=!1,t.seriesGroup=[],t.getTooltipPosition=function(n){if(n!=null){var a=this.getData().getName(n),i=this.coordinateSystem,o=i.getRegion(a);return o&&i.dataToPoint(o.getCenter())}},t}return e.prototype.getInitialData=function(t){for(var n=gd(this,{coordDimensions:["value"],encodeDefaulter:He(HD,this)}),a=Te(),i=[],o=0,s=n.count();o<s;o++){var l=n.getName(o);a.set(l,o)}var u=ts.load(this.getMapType(),this.option.nameMap,this.option.nameProperty);return O(u.regions,function(c){var f=c.name,d=a.get(f),v=c.properties&&c.properties.echartsStyle,g;d==null?(g={name:f},i.push(g)):g=n.getRawDataItem(d),v&&Ye(g,v)}),n.appendData(i),n},e.prototype.getHostGeoModel=function(){if(h8(this).kind!==Ei.boxCoordSys)return this.getReferringComponents("geo",{useDefault:!1,enableAll:!1,enableNone:!1}).models[0]},e.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},e.prototype.getRawValue=function(t){var n=this.getData();return n.get(n.mapDimension("value"),t)},e.prototype.getRegionModel=function(t){var n=this.getData();return n.getItemModel(n.indexOfName(t))},e.prototype.formatTooltip=function(t,n,a){for(var i=this.getData(),o=this.getRawValue(t),s=i.getName(t),l=this.seriesGroup,u=[],c=0;c<l.length;c++){var f=l[c].originalData.indexOfName(s),d=i.mapDimension("value");isNaN(l[c].originalData.get(d,f))||u.push(l[c].name)}return pr("section",{header:u.join(", "),noHeader:!u.length,blocks:[pr("nameValue",{name:s,value:o})]})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.getLegendIcon=function(t){var n=t.icon||"roundRect",a=ur(n,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill);return a.setStyle(t.itemStyle),a.style.stroke="none",n.indexOf("empty")>-1&&(a.style.stroke=a.style.fill,a.style.fill=ee.color.neutral00,a.style.lineWidth=2),a},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:ee.color.tertiary},itemStyle:{borderWidth:.5,borderColor:ee.color.border,areaColor:ee.color.background},emphasis:{label:{show:!0,color:ee.color.primary},itemStyle:{areaColor:ee.color.highlight}},select:{label:{show:!0,color:ee.color.primary},itemStyle:{color:ee.color.highlight}},nameProperty:"name"},e})(Ct);function Vde(r,e){var t={};return O(r,function(n){n.each(n.mapDimension("value"),function(a,i){var o="ec-"+n.getName(i);t[o]=t[o]||[],isNaN(a)||t[o].push(a)})}),r[0].map(r[0].mapDimension("value"),function(n,a){for(var i="ec-"+r[0].getName(a),o=0,s=1/0,l=-1/0,u=t[i].length,c=0;c<u;c++)s=Math.min(s,t[i][c]),l=Math.max(l,t[i][c]),o+=t[i][c];var f;return e==="min"?f=s:e==="max"?f=l:e==="average"?f=o/u:f=o,u===0?NaN:f})}function Gde(r){var e={};r.eachSeriesByType("map",function(t){var n=t.getHostGeoModel(),a=n?"o"+n.id:"i"+t.getMapType();(e[a]=e[a]||[]).push(t)}),O(e,function(t,n){for(var a=Vde(fe(t,function(o){return o.getData()}),t[0].get("mapValueCalculation")),i=0;i<t.length;i++)t[i].originalData=t[i].getData();for(var i=0;i<t.length;i++)t[i].seriesGroup=t,t[i].needsDrawMap=i===0&&!t[i].getHostGeoModel(),t[i].setData(a.cloneShallow()),t[i].mainSeries=t[0]})}function Hde(r){var e={};r.eachSeriesByType("map",function(t){var n=t.getMapType();if(!(t.getHostGeoModel()||e[n])){var a={};O(t.seriesGroup,function(o){var s=o.coordinateSystem,l=o.originalData;o.get("showLegendSymbol")&&r.getComponent("legend")&&l.each(l.mapDimension("value"),function(u,c){var f=l.getName(c),d=s.getRegion(f);if(!(!d||isNaN(u))){var v=a[f]||0,g=s.dataToPoint(d.getCenter());a[f]=v+1,l.setItemLayout(c,{point:g,offset:v})}})});var i=t.getData();i.each(function(o){var s=i.getName(o),l=i.getItemLayout(o)||{};l.showLabel=!a[s],i.setItemLayout(o,l)}),e[n]=!0}})}var Cj=Qt,Mc=(function(r){K(e,r);function e(t,n){var a=r.call(this)||this;return a.type="view",a.dimensions=["x","y"],a._roamTransformable=new jo,a._rawTransformable=new jo,a.name=t,a._opt=n,a}return e.prototype.setBoundingRect=function(t,n,a,i){return this._rect=new Oe(t,n,a,i),this._updateCenterAndZoom(),this._rect},e.prototype.getBoundingRect=function(){return this._rect},e.prototype.setViewRect=function(t,n,a,i){this._transformTo(t,n,a,i),this._viewRect=new Oe(t,n,a,i)},e.prototype._transformTo=function(t,n,a,i){var o=this.getBoundingRect(),s=this._rawTransformable;s.transform=o.calculateTransform(new Oe(t,n,a,i));var l=s.parent;s.parent=null,s.decomposeTransform(),s.parent=l,this._updateTransform()},e.prototype.setCenter=function(t){var n=this._opt;n&&n.api&&n.ecModel&&n.ecModel.getShallow("legacyViewCoordSysCenterBase")&&t&&(t=[me(t[0],n.api.getWidth()),me(t[1],n.api.getWidth())]),this._centerOption=De(t),this._updateCenterAndZoom()},e.prototype.setZoom=function(t){this._zoom=LN(t||1,this.zoomLimit),this._updateCenterAndZoom()},e.prototype.getDefaultCenter=function(){var t=this.getBoundingRect(),n=t.x+t.width/2,a=t.y+t.height/2;return[n,a]},e.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},e.prototype.getZoom=function(){return this._zoom||1},e.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},e.prototype._updateCenterAndZoom=function(){var t=this._centerOption,n=this._rect;t&&n&&(this._center=[me(t[0],n.width,n.x),me(t[1],n.height,n.y)]);var a=this._rawTransformable.getLocalTransform(),i=this._roamTransformable,o=this.getDefaultCenter(),s=this.getCenter(),l=this.getZoom();s=Qt([],s,a),o=Qt([],o,a),i.originX=s[0],i.originY=s[1],i.x=o[0]-s[0],i.y=o[1]-s[1],i.scaleX=i.scaleY=l,this._updateTransform()},e.prototype._updateTransform=function(){var t=this._roamTransformable,n=this._rawTransformable;n.parent=t,t.updateTransform(),n.updateTransform(),Hg(this.transform||(this.transform=[]),n.transform||Rr()),this._rawTransform=n.getLocalTransform(),this.invTransform=this.invTransform||[],Oa(this.invTransform,this.transform),this.decomposeTransform()},e.prototype.getTransformInfo=function(){var t=this._rawTransformable,n=this._roamTransformable,a=new jo;return a.transform=n.transform,a.decomposeTransform(),{roam:{x:a.x,y:a.y,scaleX:a.scaleX,scaleY:a.scaleY},raw:{x:t.x,y:t.y,scaleX:t.scaleX,scaleY:t.scaleY}}},e.prototype.getViewRect=function(){return this._viewRect},e.prototype.getViewRectAfterRoam=function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},e.prototype.dataToPoint=function(t,n,a){var i=n?this._rawTransform:this.transform;return a=a||[],i?Cj(a,t,i):fn(a,t)},e.prototype.pointToData=function(t,n,a){a=a||[];var i=this.invTransform;return i?Cj(a,t,i):(a[0]=t[0],a[1]=t[1],a)},e.prototype.convertToPixel=function(t,n,a){var i=Aj(n);return i===this?i.dataToPoint(a):null},e.prototype.convertFromPixel=function(t,n,a){var i=Aj(n);return i===this?i.pointToData(a):null},e.prototype.containPoint=function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])},e.dimensions=["x","y"],e})(jo);function Aj(r){var e=r.seriesModel;return e?e.coordinateSystem:null}var Fde={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},TU=["lng","lat"],EA=(function(r){K(e,r);function e(t,n,a){var i=r.call(this,t,{api:a.api,ecModel:a.ecModel})||this;i.dimensions=TU,i.type="geo",i._nameCoordMap=Te(),i.map=n;var o=a.projection,s=ts.load(n,a.nameMap,a.nameProperty),l=ts.getGeoResource(n);i.resourceType=l?l.type:null;var u=i.regions=s.regions,c=Fde[l.type];i._regionsMap=s.regionsMap,i.regions=s.regions,i.projection=o;var f;if(o)for(var d=0;d<u.length;d++){var v=u[d].getBoundingRect(o);f=f||v.clone(),f.union(v)}else f=s.boundingRect;return i.setBoundingRect(f.x,f.y,f.width,f.height),i.aspectScale=o?1:Ce(a.aspectScale,c.aspectScale),i._invertLongitute=o?!1:c.invertLongitute,i}return e.prototype._transformTo=function(t,n,a,i){var o=this.getBoundingRect(),s=this._invertLongitute;o=o.clone(),s&&(o.y=-o.y-o.height);var l=this._rawTransformable;l.transform=o.calculateTransform(new Oe(t,n,a,i));var u=l.parent;l.parent=null,l.decomposeTransform(),l.parent=u,s&&(l.scaleY=-l.scaleY),this._updateTransform()},e.prototype.getRegion=function(t){return this._regionsMap.get(t)},e.prototype.getRegionByCoord=function(t){for(var n=this.regions,a=0;a<n.length;a++){var i=n[a];if(i.type==="geoJSON"&&i.contain(t))return n[a]}},e.prototype.addGeoCoord=function(t,n){this._nameCoordMap.set(t,n)},e.prototype.getGeoCoord=function(t){var n=this._regionsMap.get(t);return this._nameCoordMap.get(t)||n&&n.getCenter()},e.prototype.dataToPoint=function(t,n,a){if(ye(t)&&(t=this.getGeoCoord(t)),t){var i=this.projection;return i&&(t=i.project(t)),t&&this.projectedToPoint(t,n,a)}},e.prototype.pointToData=function(t,n,a){var i=this.projection;return i&&(t=i.unproject(t)),t&&this.pointToProjected(t,a)},e.prototype.pointToProjected=function(t,n){return r.prototype.pointToData.call(this,t,0,n)},e.prototype.projectedToPoint=function(t,n,a){return r.prototype.dataToPoint.call(this,t,n,a)},e.prototype.convertToPixel=function(t,n,a){var i=Mj(n);return i===this?i.dataToPoint(a):null},e.prototype.convertFromPixel=function(t,n,a){var i=Mj(n);return i===this?i.pointToData(a):null},e})(Mc);Jt(EA,Mc);function Mj(r){var e=r.geoModel,t=r.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",Zt).models[0]||{}).coordinateSystem:null}function Dj(r,e){var t=r.get("boundingCoords");if(t!=null){var n=t[0],a=t[1];if(isFinite(n[0])&&isFinite(n[1])&&isFinite(a[0])&&isFinite(a[1])){var i=this.projection;if(i){var o=n[0],s=n[1],l=a[0],u=a[1];n=[1/0,1/0],a=[-1/0,-1/0];var c=function(D,M,N,R){for(var E=N-D,k=R-M,I=0;I<=100;I++){var B=I/100,P=i.project([D+E*B,M+k*B]);Oo(n,n,P),Po(a,a,P)}};c(o,s,l,s),c(l,s,l,u),c(l,u,o,u),c(o,u,l,s)}this.setBoundingRect(n[0],n[1],a[0]-n[0],a[1]-n[1])}}var f=this.getBoundingRect(),d=r.get("layoutCenter"),v=r.get("layoutSize"),g=Cr(r,e).refContainer,y=f.width/f.height*this.aspectScale,x=!1,b,w;d&&v&&(b=[me(d[0],g.width)+g.x,me(d[1],g.height)+g.y],w=me(v,Math.min(g.width,g.height)),!isNaN(b[0])&&!isNaN(b[1])&&!isNaN(w)&&(x=!0));var T;if(x)T={},y>1?(T.width=w,T.height=w/y):(T.height=w,T.width=w*y),T.y=b[1]-T.height/2,T.x=b[0]-T.width/2;else{var C=r.getBoxLayoutParams();C.aspect=y,T=Ht(C,g),T=m8(r,T,y)}this.setViewRect(T.x,T.y,T.width,T.height),this.setCenter(r.get("center")),this.setZoom(r.get("zoom"))}function Ude(r,e){O(e.get("geoCoord"),function(t,n){r.addGeoCoord(n,t)})}var Yde=(function(){function r(){this.dimensions=TU}return r.prototype.create=function(e,t){var n=[];function a(o){return{nameProperty:o.get("nameProperty"),aspectScale:o.get("aspectScale"),projection:o.get("projection")}}e.eachComponent("geo",function(o,s){var l=o.get("map"),u=new EA(l+s,l,ie({nameMap:o.get("nameMap"),api:t,ecModel:e},a(o)));u.zoomLimit=o.get("scaleLimit"),n.push(u),o.coordinateSystem=u,u.model=o,u.resize=Dj,u.resize(o,t)}),e.eachSeries(function(o){$g({targetModel:o,coordSysType:"geo",coordSysProvider:function(){var s=o.subType==="map"?o.getHostGeoModel():o.getReferringComponents("geo",Zt).models[0];return s&&s.coordinateSystem},allowNotFound:!0})});var i={};return e.eachSeriesByType("map",function(o){if(!o.getHostGeoModel()){var s=o.getMapType();i[s]=i[s]||[],i[s].push(o)}}),O(i,function(o,s){var l=fe(o,function(c){return c.get("nameMap")}),u=new EA(s,s,ie({nameMap:W1(l),api:t,ecModel:e},a(o[0])));u.zoomLimit=Fr.apply(null,fe(o,function(c){return c.get("scaleLimit")})),n.push(u),u.resize=Dj,u.resize(o[0],t),O(o,function(c){c.coordinateSystem=u,Ude(u,c)})}),n},r.prototype.getFilledRegions=function(e,t,n,a){for(var i=(e||[]).slice(),o=Te(),s=0;s<i.length;s++)o.set(i[s].name,i[s]);var l=ts.load(t,n,a);return O(l.regions,function(u){var c=u.name,f=o.get(c),d=u.properties&&u.properties.echartsStyle;f||(f={name:c},i.push(f)),d&&Ye(f,d)}),i},r})(),CU=new Yde,Wde=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a);var i=ts.getGeoResource(t.map);if(i&&i.type==="geoJSON"){var o=t.itemStyle=t.itemStyle||{};"color"in o||(o.color=t.defaultItemStyleColor||ee.color.backgroundTint)}lc(t,"label",["show"])},e.prototype.optionUpdated=function(){var t=this,n=this.option;n.regions=CU.getFilledRegions(n.regions,n.map,n.nameMap,n.nameProperty);var a={};this._optionModelMap=Ia(n.regions||[],function(i,o){var s=o.name;return s&&(i.set(s,new et(o,t,t.ecModel)),o.selected&&(a[s]=!0)),i},Te()),n.selectedMap||(n.selectedMap=a)},e.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new et(null,this,this.ecModel)},e.prototype.getFormattedLabel=function(t,n){var a=this.getRegionModel(t),i=n==="normal"?a.get(["label","formatter"]):a.get(["emphasis","label","formatter"]),o={name:t};if(Me(i))return o.status=n,i(o);if(ye(i))return i.replace("{a}",t??"")},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.select=function(t){var n=this.option,a=n.selectedMode;if(a){a!=="multiple"&&(n.selectedMap=null);var i=n.selectedMap||(n.selectedMap={});i[t]=!0}},e.prototype.unSelect=function(t){var n=this.option.selectedMap;n&&(n[t]=!1)},e.prototype.toggleSelected=function(t){this[this.isSelected(t)?"unSelect":"select"](t)},e.prototype.isSelected=function(t){var n=this.option.selectedMap;return!!(n&&n[t])},e.type="geo",e.layoutMode="box",e.defaultOption={z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:ee.color.tertiary},itemStyle:{borderWidth:.5,borderColor:ee.color.border},emphasis:{label:{show:!0,color:ee.color.primary},itemStyle:{color:ee.color.highlight}},select:{label:{show:!0,color:ee.color.primary},itemStyle:{color:ee.color.highlight}},regions:[]},e})(Qe),Xde=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.focusBlurEnabled=!0,t}return e.prototype.init=function(t,n){this._api=n},e.prototype.render=function(t,n,a,i){if(this._model=t,!t.get("show")){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;return}this._mapDraw||(this._mapDraw=new wU(a));var o=this._mapDraw;o.draw(t,n,a,this,i),o.group.on("click",this._handleRegionClick,this),o.group.silent=t.get("silent"),this.group.add(o.group),this.updateSelectStatus(t,n,a)},e.prototype._handleRegionClick=function(t){var n;Gu(t.target,function(a){return(n=je(a).eventData)!=null},!0),n&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:n.name})},e.prototype.updateSelectStatus=function(t,n,a){var i=this;this._mapDraw.group.traverse(function(o){var s=je(o).eventData;if(s)return i._model.isSelected(s.name)?a.enterSelect(o):a.leaveSelect(o),!0})},e.prototype.findHighDownDispatchers=function(t){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(t,this._model)},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},e.type="geo",e})(Rt);function qde(r,e,t){ts.registerMap(r,e,t)}function AU(r){r.registerCoordinateSystem("geo",CU),r.registerComponentModel(Wde),r.registerComponentView(Xde),r.registerImpl("registerMap",qde),r.registerImpl("getMap",function(t){return ts.getMapForUser(t)});function e(t,n){n.update="geo:updateSelectStatus",r.registerAction(n,function(a,i){var o={},s=[];return i.eachComponent({mainType:"geo",query:a},function(l){l[t](a.name);var u=l.coordinateSystem;O(u.regions,function(f){o[f.name]=l.isSelected(f.name)||!1});var c=[];O(o,function(f,d){o[d]&&c.push(d)}),s.push({geoIndex:l.componentIndex,name:c})}),{selected:o,allSelected:s,name:a.name}})}e("toggleSelected",{type:"geoToggleSelect",event:"geoselectchanged"}),e("select",{type:"geoSelect",event:"geoselected"}),e("unSelect",{type:"geoUnSelect",event:"geounselected"}),r.registerAction({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(t,n,a){var i=t.componentType;i||(t.geoId!=null?i="geo":t.seriesId!=null&&(i="series")),i||(i="series"),n.eachComponent({mainType:i,query:t},function(o){var s=o.coordinateSystem;if(s.type==="geo"){var l=Sb(s,t,o.get("scaleLimit"));o.setCenter&&o.setCenter(l.center),o.setZoom&&o.setZoom(l.zoom),i==="series"&&O(o.seriesGroup,function(u){u.setCenter(l.center),u.setZoom(l.zoom)})}})})}function Zde(r){We(AU),r.registerChartView(zde),r.registerSeriesModel(Bde),r.registerLayout(Hde),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,Gde),sF("map",r.registerAction)}function $de(r){var e=r;e.hierNode={defaultAncestor:null,ancestor:e,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var t=[e],n,a;n=t.pop();)if(a=n.children,n.isExpand&&a.length)for(var i=a.length,o=i-1;o>=0;o--){var s=a[o];s.hierNode={defaultAncestor:null,ancestor:s,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},t.push(s)}}function Kde(r,e){var t=r.isExpand?r.children:[],n=r.parentNode.children,a=r.hierNode.i?n[r.hierNode.i-1]:null;if(t.length){Jde(r);var i=(t[0].hierNode.prelim+t[t.length-1].hierNode.prelim)/2;a?(r.hierNode.prelim=a.hierNode.prelim+e(r,a),r.hierNode.modifier=r.hierNode.prelim-i):r.hierNode.prelim=i}else a&&(r.hierNode.prelim=a.hierNode.prelim+e(r,a));r.parentNode.hierNode.defaultAncestor=eve(r,a,r.parentNode.hierNode.defaultAncestor||n[0],e)}function Qde(r){var e=r.hierNode.prelim+r.parentNode.hierNode.modifier;r.setLayout({x:e},!0),r.hierNode.modifier+=r.parentNode.hierNode.modifier}function Nj(r){return arguments.length?r:nve}function mp(r,e){return r-=Math.PI/2,{x:e*Math.cos(r),y:e*Math.sin(r)}}function Jde(r){for(var e=r.children,t=e.length,n=0,a=0;--t>=0;){var i=e[t];i.hierNode.prelim+=n,i.hierNode.modifier+=n,a+=i.hierNode.change,n+=i.hierNode.shift+a}}function eve(r,e,t,n){if(e){for(var a=r,i=r,o=i.parentNode.children[0],s=e,l=a.hierNode.modifier,u=i.hierNode.modifier,c=o.hierNode.modifier,f=s.hierNode.modifier;s=T2(s),i=C2(i),s&&i;){a=T2(a),o=C2(o),a.hierNode.ancestor=r;var d=s.hierNode.prelim+f-i.hierNode.prelim-u+n(s,i);d>0&&(rve(tve(s,r,t),r,d),u+=d,l+=d),f+=s.hierNode.modifier,u+=i.hierNode.modifier,l+=a.hierNode.modifier,c+=o.hierNode.modifier}s&&!T2(a)&&(a.hierNode.thread=s,a.hierNode.modifier+=f-l),i&&!C2(o)&&(o.hierNode.thread=i,o.hierNode.modifier+=u-c,t=r)}return t}function T2(r){var e=r.children;return e.length&&r.isExpand?e[e.length-1]:r.hierNode.thread}function C2(r){var e=r.children;return e.length&&r.isExpand?e[0]:r.hierNode.thread}function tve(r,e,t){return r.hierNode.ancestor.parentNode===e.parentNode?r.hierNode.ancestor:t}function rve(r,e,t){var n=t/(e.hierNode.i-r.hierNode.i);e.hierNode.change-=n,e.hierNode.shift+=t,e.hierNode.modifier+=t,e.hierNode.prelim+=t,r.hierNode.change+=n}function nve(r,e){return r.parentNode===e.parentNode?1:2}var ave=(function(){function r(){this.parentPoint=[],this.childPoints=[]}return r})(),ive=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:ee.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new ave},e.prototype.buildPath=function(t,n){var a=n.childPoints,i=a.length,o=n.parentPoint,s=a[0],l=a[i-1];if(i===1){t.moveTo(o[0],o[1]),t.lineTo(s[0],s[1]);return}var u=n.orient,c=u==="TB"||u==="BT"?0:1,f=1-c,d=me(n.forkPosition,1),v=[];v[c]=o[c],v[f]=o[f]+(l[f]-o[f])*d,t.moveTo(o[0],o[1]),t.lineTo(v[0],v[1]),t.moveTo(s[0],s[1]),v[c]=s[c],t.lineTo(v[0],v[1]),v[c]=l[c],t.lineTo(v[0],v[1]),t.lineTo(l[0],l[1]);for(var g=1;g<i-1;g++){var y=a[g];t.moveTo(y[0],y[1]),v[c]=y[c],t.lineTo(v[0],v[1])}},e})(tt),ove=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._mainGroup=new Ne,t}return e.prototype.init=function(t,n){this._controller=new Ac(n.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},e.prototype.render=function(t,n,a){var i=t.getData(),o=t.layoutInfo,s=this._mainGroup,l=t.get("layout");l==="radial"?(s.x=o.x+o.width/2,s.y=o.y+o.height/2):(s.x=o.x,s.y=o.y),this._updateViewCoordSys(t,a),this._updateController(t,null,n,a);var u=this._data;i.diff(u).add(function(c){Lj(i,c)&&Rj(i,c,null,s,t)}).update(function(c,f){var d=u.getItemGraphicEl(f);if(!Lj(i,c)){d&&kj(u,f,d,s,t);return}Rj(i,c,d,s,t)}).remove(function(c){var f=u.getItemGraphicEl(c);f&&kj(u,c,f,s,t)}).execute(),this._nodeScaleRatio=t.get("nodeScaleRatio"),this._updateNodeAndLinkScale(t),t.get("expandAndCollapse")===!0&&i.eachItemGraphicEl(function(c,f){c.off("click").on("click",function(){a.dispatchAction({type:"treeExpandAndCollapse",seriesId:t.id,dataIndex:f})})}),this._data=i},e.prototype._updateViewCoordSys=function(t,n){var a=t.getData(),i=[];a.each(function(f){var d=a.getItemLayout(f);d&&!isNaN(d.x)&&!isNaN(d.y)&&i.push([+d.x,+d.y])});var o=[],s=[];nb(i,o,s);var l=this._min,u=this._max;s[0]-o[0]===0&&(o[0]=l?l[0]:o[0]-1,s[0]=u?u[0]:s[0]+1),s[1]-o[1]===0&&(o[1]=l?l[1]:o[1]-1,s[1]=u?u[1]:s[1]+1);var c=t.coordinateSystem=new Mc(null,{api:n,ecModel:t.ecModel});c.zoomLimit=t.get("scaleLimit"),c.setBoundingRect(o[0],o[1],s[0]-o[0],s[1]-o[1]),c.setCenter(t.get("center")),c.setZoom(t.get("zoom")),this.group.attr({x:c.x,y:c.y,scaleX:c.scaleX,scaleY:c.scaleY}),this._min=o,this._max=s},e.prototype._updateController=function(t,n,a,i){var o=this;mU(t,i,this.group,this._controller,this._controllerHost,n),this._controller.on("zoom",function(s){o._updateNodeAndLinkScale(t)})},e.prototype._updateNodeAndLinkScale=function(t){var n=t.getData(),a=this._getNodeGlobalScale(t);n.eachItemGraphicEl(function(i,o){i.setSymbolScale(a)})},e.prototype._getNodeGlobalScale=function(t){var n=t.coordinateSystem;if(n.type!=="view")return 1;var a=this._nodeScaleRatio,i=n.scaleX||1,o=n.getZoom(),s=(o-1)*a+1;return s/i},e.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},e.type="tree",e})(St);function Lj(r,e){var t=r.getItemLayout(e);return t&&!isNaN(t.x)&&!isNaN(t.y)}function Rj(r,e,t,n,a){var i=!t,o=r.tree.getNodeByDataIndex(e),s=o.getModel(),l=o.getVisual("style").fill,u=o.isExpand===!1&&o.children.length!==0?l:ee.color.neutral00,c=r.tree.root,f=o.parentNode===c?o:o.parentNode||o,d=r.getItemGraphicEl(f.dataIndex),v=f.getLayout(),g=d?{x:d.__oldX,y:d.__oldY,rawX:d.__radialOldRawX,rawY:d.__radialOldRawY}:v,y=o.getLayout();i?(t=new Jg(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.x=g.x,t.y=g.y):t.updateData(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.__radialOldRawX=t.__radialRawX,t.__radialOldRawY=t.__radialRawY,t.__radialRawX=y.rawX,t.__radialRawY=y.rawY,n.add(t),r.setItemGraphicEl(e,t),t.__oldX=t.x,t.__oldY=t.y,lt(t,{x:y.x,y:y.y},a);var x=t.getSymbolPath();if(a.get("layout")==="radial"){var b=c.children[0],w=b.getLayout(),T=b.children.length,C=void 0,D=void 0;if(y.x===w.x&&o.isExpand===!0&&b.children.length){var M={x:(b.children[0].getLayout().x+b.children[T-1].getLayout().x)/2,y:(b.children[0].getLayout().y+b.children[T-1].getLayout().y)/2};C=Math.atan2(M.y-w.y,M.x-w.x),C<0&&(C=Math.PI*2+C),D=M.x<w.x,D&&(C=C-Math.PI)}else C=Math.atan2(y.y-w.y,y.x-w.x),C<0&&(C=Math.PI*2+C),o.children.length===0||o.children.length!==0&&o.isExpand===!1?(D=y.x<w.x,D&&(C=C-Math.PI)):(D=y.x>w.x,D||(C=C-Math.PI));var N=D?"left":"right",R=s.getModel("label"),E=R.get("rotate"),k=E*(Math.PI/180),I=x.getTextContent();I&&(x.setTextConfig({position:R.get("position")||N,rotation:E==null?-C:k,origin:"center"}),I.setStyle("verticalAlign","middle"))}var B=s.get(["emphasis","focus"]),P=B==="relative"?Lh(o.getAncestorsIndices(),o.getDescendantIndices()):B==="ancestor"?o.getAncestorsIndices():B==="descendant"?o.getDescendantIndices():null;P&&(je(t).focus=P),sve(a,o,c,t,g,v,y,n),t.__edge&&(t.onHoverStateChange=function(H){if(H!=="blur"){var V=o.parentNode&&r.getItemGraphicEl(o.parentNode.dataIndex);V&&V.hoverState===Ug||Vx(t.__edge,H)}})}function sve(r,e,t,n,a,i,o,s){var l=e.getModel(),u=r.get("edgeShape"),c=r.get("layout"),f=r.getOrient(),d=r.get(["lineStyle","curveness"]),v=r.get("edgeForkPosition"),g=l.getModel("lineStyle").getLineStyle(),y=n.__edge;if(u==="curve")e.parentNode&&e.parentNode!==t&&(y||(y=n.__edge=new rd({shape:kA(c,f,d,a,a)})),lt(y,{shape:kA(c,f,d,i,o)},r));else if(u==="polyline"&&c==="orthogonal"&&e!==t&&e.children&&e.children.length!==0&&e.isExpand===!0){for(var x=e.children,b=[],w=0;w<x.length;w++){var T=x[w].getLayout();b.push([T.x,T.y])}y||(y=n.__edge=new ive({shape:{parentPoint:[o.x,o.y],childPoints:[[o.x,o.y]],orient:f,forkPosition:v}})),lt(y,{shape:{parentPoint:[o.x,o.y],childPoints:b}},r)}y&&!(u==="polyline"&&!e.isExpand)&&(y.useStyle(Re({strokeNoScale:!0,fill:null},g)),_r(y,l,"lineStyle"),fc(y),s.add(y))}function Ej(r,e,t,n,a){var i=e.tree.root,o=MU(i,r),s=o.source,l=o.sourceLayout,u=e.getItemGraphicEl(r.dataIndex);if(u){var c=e.getItemGraphicEl(s.dataIndex),f=c.__edge,d=u.__edge||(s.isExpand===!1||s.children.length===1?f:void 0),v=n.get("edgeShape"),g=n.get("layout"),y=n.get("orient"),x=n.get(["lineStyle","curveness"]);d&&(v==="curve"?Sl(d,{shape:kA(g,y,x,l,l),style:{opacity:0}},n,{cb:function(){t.remove(d)},removeOpt:a}):v==="polyline"&&n.get("layout")==="orthogonal"&&Sl(d,{shape:{parentPoint:[l.x,l.y],childPoints:[[l.x,l.y]]},style:{opacity:0}},n,{cb:function(){t.remove(d)},removeOpt:a}))}}function MU(r,e){for(var t=e.parentNode===r?e:e.parentNode||e,n;n=t.getLayout(),n==null;)t=t.parentNode===r?t:t.parentNode||t;return{source:t,sourceLayout:n}}function kj(r,e,t,n,a){var i=r.tree.getNodeByDataIndex(e),o=r.tree.root,s=MU(o,i).sourceLayout,l={duration:a.get("animationDurationUpdate"),easing:a.get("animationEasingUpdate")};Sl(t,{x:s.x+1,y:s.y+1},a,{cb:function(){n.remove(t),r.setItemGraphicEl(e,null)},removeOpt:l}),t.fadeOut(null,r.hostModel,{fadeLabel:!0,animation:l}),i.children.forEach(function(u){Ej(u,r,n,a,l)}),Ej(i,r,n,a,l)}function kA(r,e,t,n,a){var i,o,s,l,u,c,f,d;if(r==="radial"){u=n.rawX,f=n.rawY,c=a.rawX,d=a.rawY;var v=mp(u,f),g=mp(u,f+(d-f)*t),y=mp(c,d+(f-d)*t),x=mp(c,d);return{x1:v.x||0,y1:v.y||0,x2:x.x||0,y2:x.y||0,cpx1:g.x||0,cpy1:g.y||0,cpx2:y.x||0,cpy2:y.y||0}}else u=n.x,f=n.y,c=a.x,d=a.y,(e==="LR"||e==="RL")&&(i=u+(c-u)*t,o=f,s=c+(u-c)*t,l=d),(e==="TB"||e==="BT")&&(i=u,o=f+(d-f)*t,s=c,l=d+(f-d)*t);return{x1:u,y1:f,x2:c,y2:d,cpx1:i,cpy1:o,cpx2:s,cpy2:l}}var ka=Je();function DU(r){var e=r.mainData,t=r.datas;t||(t={main:e},r.datasAttr={main:"data"}),r.datas=r.mainData=null,NU(e,t,r),O(t,function(n){O(e.TRANSFERABLE_METHODS,function(a){n.wrapMethod(a,He(lve,r))})}),e.wrapMethod("cloneShallow",He(cve,r)),O(e.CHANGABLE_METHODS,function(n){e.wrapMethod(n,He(uve,r))}),rn(t[e.dataType]===e)}function lve(r,e){if(dve(this)){var t=ie({},ka(this).datas);t[this.dataType]=e,NU(e,t,r)}else EN(e,this.dataType,ka(this).mainData,r);return e}function uve(r,e){return r.struct&&r.struct.update(),e}function cve(r,e){return O(ka(e).datas,function(t,n){t!==e&&EN(t.cloneShallow(),n,e,r)}),e}function fve(r){var e=ka(this).mainData;return r==null||e==null?e:ka(e).datas[r]}function hve(){var r=ka(this).mainData;return r==null?[{data:r}]:fe(it(ka(r).datas),function(e){return{type:e,data:ka(r).datas[e]}})}function dve(r){return ka(r).mainData===r}function NU(r,e,t){ka(r).datas={},O(e,function(n,a){EN(n,a,r,t)})}function EN(r,e,t,n){ka(t).datas[e]=r,ka(r).mainData=t,r.dataType=e,n.struct&&(r[n.structAttr]=n.struct,n.struct[n.datasAttr[e]]=r),r.getLinkedData=fve,r.getLinkedDataAll=hve}var vve=(function(){function r(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 r.prototype.isRemoved=function(){return this.dataIndex<0},r.prototype.eachNode=function(e,t,n){Me(e)&&(n=t,t=e,e=null),e=e||{},ye(e)&&(e={order:e});var a=e.order||"preorder",i=this[e.attr||"children"],o;a==="preorder"&&(o=t.call(n,this));for(var s=0;!o&&s<i.length;s++)i[s].eachNode(e,t,n);a==="postorder"&&t.call(n,this)},r.prototype.updateDepthAndHeight=function(e){var t=0;this.depth=e;for(var n=0;n<this.children.length;n++){var a=this.children[n];a.updateDepthAndHeight(e+1),a.height>t&&(t=a.height)}this.height=t+1},r.prototype.getNodeById=function(e){if(this.getId()===e)return this;for(var t=0,n=this.children,a=n.length;t<a;t++){var i=n[t].getNodeById(e);if(i)return i}},r.prototype.contains=function(e){if(e===this)return!0;for(var t=0,n=this.children,a=n.length;t<a;t++){var i=n[t].contains(e);if(i)return i}},r.prototype.getAncestors=function(e){for(var t=[],n=e?this:this.parentNode;n;)t.push(n),n=n.parentNode;return t.reverse(),t},r.prototype.getAncestorsIndices=function(){for(var e=[],t=this;t;)e.push(t.dataIndex),t=t.parentNode;return e.reverse(),e},r.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},r.prototype.getValue=function(e){var t=this.hostTree.data;return t.getStore().get(t.getDimensionIndex(e||"value"),this.dataIndex)},r.prototype.setLayout=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemLayout(this.dataIndex,e,t)},r.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostTree,n=t.data.getItemModel(this.dataIndex);return n.getModel(e)}},r.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},r.prototype.setVisual=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,e,t)},r.prototype.getVisual=function(e){return this.hostTree.data.getItemVisual(this.dataIndex,e)},r.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},r.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},r.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},r.prototype.isAncestorOf=function(e){for(var t=e.parentNode;t;){if(t===this)return!0;t=t.parentNode}return!1},r.prototype.isDescendantOf=function(e){return e!==this&&e.isAncestorOf(this)},r})(),kN=(function(){function r(e){this.type="tree",this._nodes=[],this.hostModel=e}return r.prototype.eachNode=function(e,t,n){this.root.eachNode(e,t,n)},r.prototype.getNodeByDataIndex=function(e){var t=this.data.getRawIndex(e);return this._nodes[t]},r.prototype.getNodeById=function(e){return this.root.getNodeById(e)},r.prototype.update=function(){for(var e=this.data,t=this._nodes,n=0,a=t.length;n<a;n++)t[n].dataIndex=-1;for(var n=0,a=e.count();n<a;n++)t[e.getRawIndex(n)].dataIndex=n},r.prototype.clearLayouts=function(){this.data.clearItemLayouts()},r.createTree=function(e,t,n){var a=new r(t),i=[],o=1;s(e);function s(c,f){var d=c.value;o=Math.max(o,ce(d)?d.length:1),i.push(c);var v=new vve(xr(c.name,""),a);f?pve(v,f):a.root=v,a._nodes.push(v);var g=c.children;if(g)for(var y=0;y<g.length;y++)s(g[y],v)}a.root.updateDepthAndHeight(0);var l=hd(i,{coordDimensions:["value"],dimensionsCount:o}).dimensions,u=new pn(l,t);return u.initData(i),n&&n(u),DU({mainData:u,struct:a,structAttr:"tree"}),a.update(),a},r})();function pve(r,e){var t=e.children;r.parentNode!==e&&(t.push(r),r.parentNode=e)}function mg(r,e,t){if(r&&Fe(e,r.type)>=0){var n=t.getData().tree.root,a=r.targetNode;if(ye(a)&&(a=n.getNodeById(a)),a&&n.contains(a))return{node:a};var i=r.targetNodeId;if(i!=null&&(a=n.getNodeById(i)))return{node:a}}}function LU(r){for(var e=[];r;)r=r.parentNode,r&&e.push(r);return e.reverse()}function IN(r,e){var t=LU(r);return Fe(t,e)>=0}function Tb(r,e){for(var t=[];r;){var n=r.dataIndex;t.push({name:r.name,dataIndex:n,value:e.getRawValue(n)}),r=r.parentNode}return t.reverse(),t}var gve=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t){var n={name:t.name,children:t.data},a=t.leaves||{},i=new et(a,this,this.ecModel),o=kN.createTree(n,this,s);function s(f){f.wrapMethod("getItemModel",function(d,v){var g=o.getNodeByDataIndex(v);return g&&g.children.length&&g.isExpand||(d.parentModel=i),d})}var l=0;o.eachNode("preorder",function(f){f.depth>l&&(l=f.depth)});var u=t.expandAndCollapse,c=u&&t.initialTreeDepth>=0?t.initialTreeDepth:l;return o.root.eachNode("preorder",function(f){var d=f.hostTree.data.getRawDataItem(f.dataIndex);f.isExpand=d&&d.collapsed!=null?!d.collapsed:f.depth<=c}),o.data},e.prototype.getOrient=function(){var t=this.get("orient");return t==="horizontal"?t="LR":t==="vertical"&&(t="TB"),t},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.formatTooltip=function(t,n,a){for(var i=this.getData().tree,o=i.root.children[0],s=i.getNodeByDataIndex(t),l=s.getValue(),u=s.name;s&&s!==o;)u=s.parentNode.name+"."+u,s=s.parentNode;return pr("nameValue",{name:u,value:l,noValue:isNaN(l)||l==null})},e.prototype.getDataParams=function(t){var n=r.prototype.getDataParams.apply(this,arguments),a=this.getData().tree.getNodeByDataIndex(t);return n.treeAncestors=Tb(a,this),n.collapsed=!a.isExpand,n},e.type="series.tree",e.layoutMode="box",e.defaultOption={z:2,coordinateSystemUsage:"box",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,roamTrigger:"global",nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:ee.color.borderTint,width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},e})(Ct);function mve(r,e,t){for(var n=[r],a=[],i;i=n.pop();)if(a.push(i),i.isExpand){var o=i.children;if(o.length)for(var s=0;s<o.length;s++)n.push(o[s])}for(;i=a.pop();)e(i,t)}function Uv(r,e){for(var t=[r],n;n=t.pop();)if(e(n),n.isExpand){var a=n.children;if(a.length)for(var i=a.length-1;i>=0;i--)t.push(a[i])}}function yve(r,e){r.eachSeriesByType("tree",function(t){xve(t,e)})}function xve(r,e){var t=Cr(r,e).refContainer,n=Ht(r.getBoxLayoutParams(),t);r.layoutInfo=n;var a=r.get("layout"),i=0,o=0,s=null;a==="radial"?(i=2*Math.PI,o=Math.min(n.height,n.width)/2,s=Nj(function(C,D){return(C.parentNode===D.parentNode?1:2)/C.depth})):(i=n.width,o=n.height,s=Nj());var l=r.getData().tree.root,u=l.children[0];if(u){$de(l),mve(u,Kde,s),l.hierNode.modifier=-u.hierNode.prelim,Uv(u,Qde);var c=u,f=u,d=u;Uv(u,function(C){var D=C.getLayout().x;D<c.getLayout().x&&(c=C),D>f.getLayout().x&&(f=C),C.depth>d.depth&&(d=C)});var v=c===f?1:s(c,f)/2,g=v-c.getLayout().x,y=0,x=0,b=0,w=0;if(a==="radial")y=i/(f.getLayout().x+v+g),x=o/(d.depth-1||1),Uv(u,function(C){b=(C.getLayout().x+g)*y,w=(C.depth-1)*x;var D=mp(b,w);C.setLayout({x:D.x,y:D.y,rawX:b,rawY:w},!0)});else{var T=r.getOrient();T==="RL"||T==="LR"?(x=o/(f.getLayout().x+v+g),y=i/(d.depth-1||1),Uv(u,function(C){w=(C.getLayout().x+g)*x,b=T==="LR"?(C.depth-1)*y:i-(C.depth-1)*y,C.setLayout({x:b,y:w},!0)})):(T==="TB"||T==="BT")&&(y=i/(f.getLayout().x+v+g),x=o/(d.depth-1||1),Uv(u,function(C){b=(C.getLayout().x+g)*y,w=T==="TB"?(C.depth-1)*x:o-(C.depth-1)*x,C.setLayout({x:b,y:w},!0)}))}}}function bve(r){r.eachSeriesByType("tree",function(e){var t=e.getData(),n=t.tree;n.eachNode(function(a){var i=a.getModel(),o=i.getModel("itemStyle").getItemStyle(),s=t.ensureUniqueItemVisual(a.dataIndex,"style");ie(s,o)})})}function _ve(r){r.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"tree",query:e},function(n){var a=e.dataIndex,i=n.getData().tree,o=i.getNodeByDataIndex(a);o.isExpand=!o.isExpand})}),r.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},function(e,t,n){t.eachComponent({mainType:"series",subType:"tree",query:e},function(a){var i=a.coordinateSystem,o=Sb(i,e,a.get("scaleLimit"));a.setCenter(o.center),a.setZoom(o.zoom)})})}function Sve(r){r.registerChartView(ove),r.registerSeriesModel(gve),r.registerLayout(yve),r.registerVisual(bve),_ve(r)}var Ij=["treemapZoomToNode","treemapRender","treemapMove"];function wve(r){for(var e=0;e<Ij.length;e++)r.registerAction({type:Ij[e],update:"updateView"},Kt);r.registerAction({type:"treemapRootToNode",update:"updateView"},function(t,n){n.eachComponent({mainType:"series",subType:"treemap",query:t},a);function a(i,o){var s=["treemapZoomToNode","treemapRootToNode"],l=mg(t,s,i);if(l){var u=i.getViewRoot();u&&(t.direction=IN(u,l.node)?"rollUp":"drillDown"),i.resetViewRoot(l.node)}}})}function RU(r){var e=r.getData(),t=e.tree,n={};t.eachNode(function(a){for(var i=a;i&&i.depth>1;)i=i.parentNode;var o=$C(r.ecModel,i.name||i.dataIndex+"",n);a.setVisual("decal",o)})}var Tve=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventUsingHoverLayer=!0,t}return e.prototype.getInitialData=function(t,n){var a={name:t.name,children:t.data};EU(a);var i=t.levels||[],o=this.designatedVisualItemStyle={},s=new et({itemStyle:o},this,n);i=t.levels=Cve(i,n);var l=fe(i||[],function(f){return new et(f,s,n)},this),u=kN.createTree(a,this,c);function c(f){f.wrapMethod("getItemModel",function(d,v){var g=u.getNodeByDataIndex(v),y=g?l[g.depth]:null;return d.parentModel=y||s,d})}return u.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return pr("nameValue",{name:s,value:o})},e.prototype.getDataParams=function(t){var n=r.prototype.getDataParams.apply(this,arguments),a=this.getData().tree.getNodeByDataIndex(t);return n.treeAncestors=Tb(a,this),n.treePathInfo=n.treeAncestors,n},e.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},ie(this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var n=this._idIndexMap;n||(n=this._idIndexMap=Te(),this._idIndexMapCount=0);var a=n.get(t);return a==null&&n.set(t,a=this._idIndexMapCount++),a},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var n=this.getRawData().tree.root;(!t||t!==n&&!n.contains(t))&&(this._viewRoot=n)},e.prototype.enableAriaDecal=function(){RU(this)},e.type="series.treemap",e.layoutMode="box",e.defaultOption={progressive:0,coordinateSystemUsage:"box",left:ee.size.l,top:ee.size.xxxl,right:ee.size.l,bottom:ee.size.xxxl,sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.32*.32,scaleLimit:{max:5,min:.2},roam:!0,roamTrigger:"global",nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",bottom:ee.size.m,emptyItemWidth:25,itemStyle:{color:ee.color.backgroundShade,textStyle:{color:ee.color.secondary}},emphasis:{itemStyle:{color:ee.color.background}}},label:{show:!0,distance:0,padding:5,position:"inside",color:ee.color.neutral00,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:ee.color.neutral00,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:[]},e})(Ct);function EU(r){var e=0;O(r.children,function(n){EU(n);var a=n.value;ce(a)&&(a=a[0]),e+=a});var t=r.value;ce(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),ce(r.value)?r.value[0]=t:r.value=t}function Cve(r,e){var t=Lt(e.get("color")),n=Lt(e.get(["aria","decal","decals"]));if(t){r=r||[];var a,i;O(r,function(s){var l=new et(s),u=l.get("color"),c=l.get("decal");(l.get(["itemStyle","color"])||u&&u!=="none")&&(a=!0),(l.get(["itemStyle","decal"])||c&&c!=="none")&&(i=!0)});var o=r[0]||(r[0]={});return a||(o.color=t.slice()),!i&&n&&(o.decal=n.slice()),r}}var Ave=8,Oj=8,A2=5,Mve=(function(){function r(e){this.group=new Ne,e.add(this.group)}return r.prototype.render=function(e,t,n,a){var i=e.getModel("breadcrumb"),o=this.group;if(o.removeAll(),!(!i.get("show")||!n)){var s=i.getModel("itemStyle"),l=i.getModel("emphasis"),u=s.getModel("textStyle"),c=l.getModel(["itemStyle","textStyle"]),f=Cr(e,t).refContainer,d={left:i.get("left"),right:i.get("right"),top:i.get("top"),bottom:i.get("bottom")},v={emptyItemWidth:i.get("emptyItemWidth"),totalWidth:0,renderList:[]},g=Ht(d,f);this._prepare(n,v,u),this._renderContent(e,v,g,s,l,u,c,a),fb(o,d,f)}},r.prototype._prepare=function(e,t,n){for(var a=e;a;a=a.parentNode){var i=xr(a.getModel().get("name"),""),o=n.getTextRect(i),s=Math.max(o.width+Ave*2,t.emptyItemWidth);t.totalWidth+=s+Oj,t.renderList.push({node:a,text:i,width:s})}},r.prototype._renderContent=function(e,t,n,a,i,o,s,l){for(var u=0,c=t.emptyItemWidth,f=e.get(["breadcrumb","height"]),d=t.totalWidth,v=t.renderList,g=i.getModel("itemStyle").getItemStyle(),y=v.length-1;y>=0;y--){var x=v[y],b=x.node,w=x.width,T=x.text;d>n.width&&(d-=w-c,w=c,T=null);var C=new an({shape:{points:Dve(u,0,w,f,y===v.length-1,y===0)},style:Re(a.getItemStyle(),{lineJoin:"bevel"}),textContent:new ot({style:Nt(o,{text:T})}),textConfig:{position:"inside"},z2:ed*1e4,onclick:He(l,b)});C.disableLabelAnimation=!0,C.getTextContent().ensureState("emphasis").style=Nt(s,{text:T}),C.ensureState("emphasis").style=g,Ut(C,i.get("focus"),i.get("blurScope"),i.get("disabled")),this.group.add(C),Nve(C,e,b),u+=w+Oj}},r.prototype.remove=function(){this.group.removeAll()},r})();function Dve(r,e,t,n,a,i){var o=[[a?r:r-A2,e],[r+t,e],[r+t,e+n],[a?r:r-A2,e+n]];return!i&&o.splice(2,0,[r+t+A2,e+n/2]),!a&&o.push([r,e+n/2]),o}function Nve(r,e,t){je(r).eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:t&&t.dataIndex,name:t&&t.name},treePathInfo:t&&Tb(t,e)}}var Lve=(function(){function r(){this._storage=[],this._elExistsMap={}}return r.prototype.add=function(e,t,n,a,i){return this._elExistsMap[e.id]?!1:(this._elExistsMap[e.id]=!0,this._storage.push({el:e,target:t,duration:n,delay:a,easing:i}),!0)},r.prototype.finished=function(e){return this._finishedCallback=e,this},r.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())},a=0,i=this._storage.length;a<i;a++){var o=this._storage[a];o.el.animateTo(o.target,{duration:o.duration,delay:o.delay,easing:o.easing,setToFinal:!0,done:n,aborted:n})}return this},r})();function Rve(){return new Lve}var IA=Ne,Pj=qe,jj=3,zj="label",Bj="upperLabel",Eve=ed*10,kve=ed*2,Ive=ed*3,Du=cc([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Vj=function(r){var e=Du(r);return e.stroke=e.fill=e.lineWidth=null,e},v1=Je(),Ove=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._state="ready",t._storage=Yv(),t}return e.prototype.render=function(t,n,a,i){var o=n.findComponents({mainType:"series",subType:"treemap",query:i});if(!(Fe(o,t)<0)){this.seriesModel=t,this.api=a,this.ecModel=n;var s=["treemapZoomToNode","treemapRootToNode"],l=mg(i,s,t),u=i&&i.type,c=t.layoutInfo,f=!this._oldTree,d=this._storage,v=u==="treemapRootToNode"&&l&&d?{rootNodeGroup:d.nodeGroup[l.node.getRawIndex()],direction:i.direction}:null,g=this._giveContainerGroup(c),y=t.get("animation"),x=this._doRender(g,t,v);y&&!f&&(!u||u==="treemapZoomToNode"||u==="treemapRootToNode")?this._doAnimation(g,x,t,v):x.renderFinally(),this._resetController(a),this._renderBreadcrumb(t,a,l)}},e.prototype._giveContainerGroup=function(t){var n=this._containerGroup;return n||(n=this._containerGroup=new IA,this._initEvents(n),this.group.add(n)),n.x=t.x,n.y=t.y,n},e.prototype._doRender=function(t,n,a){var i=n.getData().tree,o=this._oldTree,s=Yv(),l=Yv(),u=this._storage,c=[];function f(w,T,C,D){return Pve(n,l,u,a,s,c,w,T,C,D)}y(i.root?[i.root]:[],o&&o.root?[o.root]:[],t,i===o||!o,0);var d=x(u);if(this._oldTree=i,this._storage=l,this._controllerHost){var v=this.seriesModel.layoutInfo,g=i.root.getLayout();g.width===v.width&&g.height===v.height&&(this._controllerHost.zoom=1)}return{lastsForAnimation:s,willDeleteEls:d,renderFinally:b};function y(w,T,C,D,M){D?(T=w,O(w,function(E,k){!E.isRemoved()&&R(k,k)})):new Qo(T,w,N,N).add(R).update(R).remove(He(R,null)).execute();function N(E){return E.getId()}function R(E,k){var I=E!=null?w[E]:null,B=k!=null?T[k]:null,P=f(I,B,C,M);P&&y(I&&I.viewChildren||[],B&&B.viewChildren||[],P,D,M+1)}}function x(w){var T=Yv();return w&&O(w,function(C,D){var M=T[D];O(C,function(N){N&&(M.push(N),v1(N).willDelete=!0)})}),T}function b(){O(d,function(w){O(w,function(T){T.parent&&T.parent.remove(T)})}),O(c,function(w){w.invisible=!0,w.dirty()})}},e.prototype._doAnimation=function(t,n,a,i){var o=a.get("animationDurationUpdate"),s=a.get("animationEasing"),l=(Me(o)?0:o)||0,u=(Me(s)?null:s)||"cubicOut",c=Rve();O(n.willDeleteEls,function(f,d){O(f,function(v,g){if(!v.invisible){var y=v.parent,x,b=v1(y);if(i&&i.direction==="drillDown")x=y===i.rootNodeGroup?{shape:{x:0,y:0,width:b.nodeWidth,height:b.nodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var w=0,T=0;b.willDelete||(w=b.nodeWidth/2,T=b.nodeHeight/2),x=d==="nodeGroup"?{x:w,y:T,style:{opacity:0}}:{shape:{x:w,y:T,width:0,height:0},style:{opacity:0}}}x&&c.add(v,x,l,0,u)}})}),O(this._storage,function(f,d){O(f,function(v,g){var y=n.lastsForAnimation[d][g],x={};y&&(v instanceof Ne?y.oldX!=null&&(x.x=v.x,x.y=v.y,v.x=y.oldX,v.y=y.oldY):(y.oldShape&&(x.shape=ie({},v.shape),v.setShape(y.oldShape)),y.fadein?(v.setStyle("opacity",0),x.style={opacity:1}):v.style.opacity!==1&&(x.style={opacity:1})),c.add(v,x,l,0,u))})},this),this._state="animating",c.finished(xe(function(){this._state="ready",n.renderFinally()},this)).start()},e.prototype._resetController=function(t){var n=this,a=this._controller,i=this._controllerHost;i||(this._controllerHost={target:this.group},i=this._controllerHost);var o=this.seriesModel;a||(a=this._controller=new Ac(t.getZr()),a.on("pan",xe(this._onPan,this)),a.on("zoom",xe(this._onZoom,this))),a.enable(o.get("roam"),{api:t,zInfo:{component:o},triggerInfo:{roamTrigger:o.get("roamTrigger"),isInSelf:function(s,l,u){var c=n._containerGroup;return c?c.getBoundingRect().contain(l-c.x,u-c.y):!1}}}),i.zoomLimit=o.get("scaleLimit"),i.zoom=o.get("zoom")},e.prototype._clearController=function(){var t=this._controller;this._controllerHost=null,t&&(t.dispose(),t=null)},e.prototype._onPan=function(t){if(this._state!=="animating"&&(Math.abs(t.dx)>jj||Math.abs(t.dy)>jj)){var n=this.seriesModel.getData().tree.root;if(!n)return;var a=n.getLayout();if(!a)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:a.x+t.dx,y:a.y+t.dy,width:a.width,height:a.height}})}},e.prototype._onZoom=function(t){var n=t.originX,a=t.originY,i=t.scale;if(this._state!=="animating"){var o=this.seriesModel.getData().tree.root;if(!o)return;var s=o.getLayout();if(!s)return;var l=new Oe(s.x,s.y,s.width,s.height),u=null,c=this._controllerHost;u=c.zoomLimit;var f=c.zoom=c.zoom||1;if(f*=i,u){var d=u.min||0,v=u.max||1/0;f=Math.max(Math.min(v,f),d)}var g=f/c.zoom;c.zoom=f;var y=this.seriesModel.layoutInfo;n-=y.x,a-=y.y;var x=Rr();ii(x,x,[-n,-a]),Z1(x,x,[g,g]),ii(x,x,[n,a]),l.applyTransform(x),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:l.x,y:l.y,width:l.width,height:l.height}})}},e.prototype._initEvents=function(t){var n=this;t.on("click",function(a){if(n._state==="ready"){var i=n.seriesModel.get("nodeClick",!0);if(i){var o=n.findTarget(a.offsetX,a.offsetY);if(o){var s=o.node;if(s.getLayout().isLeafRoot)n._rootToNode(o);else if(i==="zoomToNode")n._zoomToNode(o);else if(i==="link"){var l=s.hostTree.data.getItemModel(s.dataIndex),u=l.get("link",!0),c=l.get("target",!0)||"blank";u&&Ux(u,c)}}}}},this)},e.prototype._renderBreadcrumb=function(t,n,a){var i=this;a||(a=t.get("leafDepth",!0)!=null?{node:t.getViewRoot()}:this.findTarget(n.getWidth()/2,n.getHeight()/2),a||(a={node:t.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new Mve(this.group))).render(t,n,a.node,function(o){i._state!=="animating"&&(IN(t.getViewRoot(),o)?i._rootToNode({node:o}):i._zoomToNode({node:o}))})},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=Yv(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},e.prototype.dispose=function(){this._clearController()},e.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype.findTarget=function(t,n){var a,i=this.seriesModel.getViewRoot();return i.eachNode({attr:"viewChildren",order:"preorder"},function(o){var s=this._storage.background[o.getRawIndex()];if(s){var l=s.transformCoordToLocal(t,n),u=s.shape;if(u.x<=l[0]&&l[0]<=u.x+u.width&&u.y<=l[1]&&l[1]<=u.y+u.height)a={node:o,offsetX:l[0],offsetY:l[1]};else return!1}},this),a},e.type="treemap",e})(St);function Yv(){return{nodeGroup:[],background:[],content:[]}}function Pve(r,e,t,n,a,i,o,s,l,u){if(!o)return;var c=o.getLayout(),f=r.getData(),d=o.getModel();if(f.setItemGraphicEl(o.dataIndex,null),!c||!c.isInView)return;var v=c.width,g=c.height,y=c.borderWidth,x=c.invisible,b=o.getRawIndex(),w=s&&s.getRawIndex(),T=o.viewChildren,C=c.upperHeight,D=T&&T.length,M=d.getModel("itemStyle"),N=d.getModel(["emphasis","itemStyle"]),R=d.getModel(["blur","itemStyle"]),E=d.getModel(["select","itemStyle"]),k=M.get("borderRadius")||0,I=ge("nodeGroup",IA);if(!I)return;if(l.add(I),I.x=c.x||0,I.y=c.y||0,I.markRedraw(),v1(I).nodeWidth=v,v1(I).nodeHeight=g,c.isAboveViewRoot)return I;var B=ge("background",Pj,u,kve);B&&G(I,B,D&&c.upperLabelHeight);var P=d.getModel("emphasis"),H=P.get("focus"),V=P.get("blurScope"),j=P.get("disabled"),U=H==="ancestor"?o.getAncestorsIndices():H==="descendant"?o.getDescendantIndices():H;if(D)rg(I)&&Bu(I,!1),B&&(Bu(B,!j),f.setItemGraphicEl(o.dataIndex,B),BC(B,U,V));else{var F=ge("content",Pj,u,Ive);F&&W(I,F),B.disableMorphing=!0,B&&rg(B)&&Bu(B,!1),Bu(I,!j),f.setItemGraphicEl(o.dataIndex,I);var X=d.getShallow("cursor");X&&F.attr("cursor",X),BC(I,U,V)}return I;function G(be,we,ze){var oe=je(we);if(oe.dataIndex=o.dataIndex,oe.seriesIndex=r.seriesIndex,we.setShape({x:0,y:0,width:v,height:g,r:k}),x)$(we);else{we.invisible=!1;var pe=o.getVisual("style"),Be=pe.stroke,Le=Vj(M);Le.fill=Be;var at=Du(N);at.fill=N.get("borderColor");var ft=Du(R);ft.fill=R.get("borderColor");var At=Du(E);if(At.fill=E.get("borderColor"),ze){var Wr=v-2*y;te(we,Be,pe.opacity,{x:y,y:0,width:Wr,height:C})}else we.removeTextContent();we.setStyle(Le),we.ensureState("emphasis").style=at,we.ensureState("blur").style=ft,we.ensureState("select").style=At,fc(we)}be.add(we)}function W(be,we){var ze=je(we);ze.dataIndex=o.dataIndex,ze.seriesIndex=r.seriesIndex;var oe=Math.max(v-2*y,0),pe=Math.max(g-2*y,0);if(we.culling=!0,we.setShape({x:y,y,width:oe,height:pe,r:k}),x)$(we);else{we.invisible=!1;var Be=o.getVisual("style"),Le=Be.fill,at=Vj(M);at.fill=Le,at.decal=Be.decal;var ft=Du(N),At=Du(R),Wr=Du(E);te(we,Le,Be.opacity,null),we.setStyle(at),we.ensureState("emphasis").style=ft,we.ensureState("blur").style=At,we.ensureState("select").style=Wr,fc(we)}be.add(we)}function $(be){!be.invisible&&i.push(be)}function te(be,we,ze,oe){var pe=d.getModel(oe?Bj:zj),Be=xr(d.get("name"),null),Le=pe.getShallow("show");kr(be,Sr(d,oe?Bj:zj),{defaultText:Le?Be:null,inheritColor:we,defaultOpacity:ze,labelFetcher:r,labelDataIndex:o.dataIndex});var at=be.getTextContent();if(at){var ft=at.style,At=Bg(ft.padding||0);oe&&(be.setTextConfig({layoutRect:oe}),at.disableLabelLayout=!0),at.beforeUpdate=function(){var er=Math.max((oe?oe.width:be.shape.width)-At[1]-At[3],0),ci=Math.max((oe?oe.height:be.shape.height)-At[0]-At[2],0);(ft.width!==er||ft.height!==ci)&&at.setStyle({width:er,height:ci})},ft.truncateMinChar=2,ft.lineOverflow="truncate",ue(ft,oe,c);var Wr=at.getState("emphasis");ue(Wr?Wr.style:null,oe,c)}}function ue(be,we,ze){var oe=be?be.text:null;if(!we&&ze.isLeafRoot&&oe!=null){var pe=r.get("drillDownIcon",!0);be.text=pe?pe+" "+oe:oe}}function ge(be,we,ze,oe){var pe=w!=null&&t[be][w],Be=a[be];return pe?(t[be][w]=null,Se(Be,pe)):x||(pe=new we,pe instanceof Pa&&(pe.z2=jve(ze,oe)),Xe(Be,pe)),e[be][b]=pe}function Se(be,we){var ze=be[b]={};we instanceof IA?(ze.oldX=we.x,ze.oldY=we.y):ze.oldShape=ie({},we.shape)}function Xe(be,we){var ze=be[b]={},oe=o.parentNode,pe=we instanceof Ne;if(oe&&(!n||n.direction==="drillDown")){var Be=0,Le=0,at=a.background[oe.getRawIndex()];!n&&at&&at.oldShape&&(Be=at.oldShape.width,Le=at.oldShape.height),pe?(ze.oldX=0,ze.oldY=Le):ze.oldShape={x:Be,y:Le,width:0,height:0}}ze.fadein=!pe}}function jve(r,e){return r*Eve+e}var yg=O,zve=Ee,p1=-1,Er=(function(){function r(e){var t=e.mappingMethod,n=e.type,a=this.option=De(e);this.type=n,this.mappingMethod=t,this._normalizeData=Gve[t];var i=r.visualHandlers[n];this.applyVisual=i.applyVisual,this.getColorMapper=i.getColorMapper,this._normalizedToVisual=i._normalizedToVisual[t],t==="piecewise"?(M2(a),Bve(a)):t==="category"?a.categories?Vve(a):M2(a,!0):(rn(t!=="linear"||a.dataExtent),M2(a))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return xe(this._normalizeData,this)},r.listVisualTypes=function(){return it(r.visualHandlers)},r.isValidType=function(e){return r.visualHandlers.hasOwnProperty(e)},r.eachVisual=function(e,t,n){Ee(e)?O(e,t,n):t.call(n,e)},r.mapVisual=function(e,t,n){var a,i=ce(e)?[]:Ee(e)?{}:(a=!0,null);return r.eachVisual(e,function(o,s){var l=t.call(n,o,s);a?i=l:i[s]=l}),i},r.retrieveVisuals=function(e){var t={},n;return e&&yg(r.visualHandlers,function(a,i){e.hasOwnProperty(i)&&(t[i]=e[i],n=!0)}),n?t:null},r.prepareVisualTypes=function(e){if(ce(e))e=e.slice();else if(zve(e)){var t=[];yg(e,function(n,a){t.push(a)}),e=t}else return[];return e.sort(function(n,a){return a==="color"&&n!=="color"&&n.indexOf("color")===0?1:-1}),e},r.dependsOn=function(e,t){return t==="color"?!!(e&&e.indexOf(t)===0):e===t},r.findPieceIndex=function(e,t,n){for(var a,i=1/0,o=0,s=t.length;o<s;o++){var l=t[o].value;if(l!=null){if(l===e||ye(l)&&l===e+"")return o;n&&d(l,o)}}for(var o=0,s=t.length;o<s;o++){var u=t[o],c=u.interval,f=u.close;if(c){if(c[0]===-1/0){if(b0(f[1],e,c[1]))return o}else if(c[1]===1/0){if(b0(f[0],c[0],e))return o}else if(b0(f[0],c[0],e)&&b0(f[1],e,c[1]))return o;n&&d(c[0],o),n&&d(c[1],o)}}if(n)return e===1/0?t.length-1:e===-1/0?0:a;function d(v,g){var y=Math.abs(v-e);y<i&&(i=y,a=g)}},r.visualHandlers={color:{applyVisual:Wv("color"),getColorMapper:function(){var e=this.option;return xe(e.mappingMethod==="category"?function(t,n){return!n&&(t=this._normalizeData(t)),yp.call(this,t)}:function(t,n,a){var i=!!a;return!n&&(t=this._normalizeData(t)),a=Dp(t,e.parsedVisual,a),i?a:Ea(a,"rgba")},this)},_normalizedToVisual:{linear:function(e){return Ea(Dp(e,this.option.parsedVisual),"rgba")},category:yp,piecewise:function(e,t){var n=PA.call(this,t);return n==null&&(n=Ea(Dp(e,this.option.parsedVisual),"rgba")),n},fixed:Nu}},colorHue:x0(function(e,t){return Go(e,t)}),colorSaturation:x0(function(e,t){return Go(e,null,t)}),colorLightness:x0(function(e,t){return Go(e,null,null,t)}),colorAlpha:x0(function(e,t){return Kp(e,t)}),decal:{applyVisual:Wv("decal"),_normalizedToVisual:{linear:null,category:yp,piecewise:null,fixed:null}},opacity:{applyVisual:Wv("opacity"),_normalizedToVisual:OA([0,1])},liftZ:{applyVisual:Wv("liftZ"),_normalizedToVisual:{linear:Nu,category:Nu,piecewise:Nu,fixed:Nu}},symbol:{applyVisual:function(e,t,n){var a=this.mapValueToVisual(e);n("symbol",a)},_normalizedToVisual:{linear:Gj,category:yp,piecewise:function(e,t){var n=PA.call(this,t);return n==null&&(n=Gj.call(this,e)),n},fixed:Nu}},symbolSize:{applyVisual:Wv("symbolSize"),_normalizedToVisual:OA([0,1])}},r})();function Bve(r){var e=r.pieceList;r.hasSpecialVisual=!1,O(e,function(t,n){t.originIndex=n,t.visual!=null&&(r.hasSpecialVisual=!0)})}function Vve(r){var e=r.categories,t=r.categoryMap={},n=r.visual;if(yg(e,function(o,s){t[o]=s}),!ce(n)){var a=[];Ee(n)?yg(n,function(o,s){var l=t[s];a[l??p1]=o}):a[p1]=n,n=kU(r,a)}for(var i=e.length-1;i>=0;i--)n[i]==null&&(delete t[e[i]],e.pop())}function M2(r,e){var t=r.visual,n=[];Ee(t)?yg(t,function(i){n.push(i)}):t!=null&&n.push(t);var a={color:1,symbol:1};!e&&n.length===1&&!a.hasOwnProperty(r.type)&&(n[1]=n[0]),kU(r,n)}function x0(r){return{applyVisual:function(e,t,n){var a=this.mapValueToVisual(e);n("color",r(t("color"),a))},_normalizedToVisual:OA([0,1])}}function Gj(r){var e=this.option.visual;return e[Math.round(pt(r,[0,1],[0,e.length-1],!0))]||{}}function Wv(r){return function(e,t,n){n(r,this.mapValueToVisual(e))}}function yp(r){var e=this.option.visual;return e[this.option.loop&&r!==p1?r%e.length:r]}function Nu(){return this.option.visual[0]}function OA(r){return{linear:function(e){return pt(e,r,this.option.visual,!0)},category:yp,piecewise:function(e,t){var n=PA.call(this,t);return n==null&&(n=pt(e,r,this.option.visual,!0)),n},fixed:Nu}}function PA(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var n=Er.findPieceIndex(r,t),a=t[n];if(a&&a.visual)return a.visual[this.type]}}function kU(r,e){return r.visual=e,r.type==="color"&&(r.parsedVisual=fe(e,function(t){var n=vn(t);return n||[0,0,0,1]})),e}var Gve={linear:function(r){return pt(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=Er.findPieceIndex(r,e,!0);if(t!=null)return pt(t,[0,e.length-1],[0,1],!0)},category:function(r){var e=this.option.categories?this.option.categoryMap[r]:r;return e??p1},fixed:Kt};function b0(r,e,t){return r?e<=t:e<t}var Hve="itemStyle",IU=Je();const Fve={seriesType:"treemap",reset:function(r){var e=r.getData().tree,t=e.root;t.isRemoved()||OU(t,{},r.getViewRoot().getAncestors(),r)}};function OU(r,e,t,n){var a=r.getModel(),i=r.getLayout(),o=r.hostTree.data;if(!(!i||i.invisible||!i.isInView)){var s=a.getModel(Hve),l=Uve(s,e,n),u=o.ensureUniqueItemVisual(r.dataIndex,"style"),c=s.get("borderColor"),f=s.get("borderColorSaturation"),d;f!=null&&(d=Hj(l),c=Yve(f,d)),u.stroke=c;var v=r.viewChildren;if(!v||!v.length)d=Hj(l),u.fill=d;else{var g=Wve(r,a,i,s,l,v);O(v,function(y,x){if(y.depth>=t.length||y===t[y.depth]){var b=Xve(a,l,y,x,g,n);OU(y,b,t,n)}})}}}function Uve(r,e,t){var n=ie({},e),a=t.designatedVisualItemStyle;return O(["color","colorAlpha","colorSaturation"],function(i){a[i]=e[i];var o=r.get(i);a[i]=null,o!=null&&(n[i]=o)}),n}function Hj(r){var e=D2(r,"color");if(e){var t=D2(r,"colorAlpha"),n=D2(r,"colorSaturation");return n&&(e=Go(e,null,null,n)),t&&(e=Kp(e,t)),e}}function Yve(r,e){return e!=null?Go(e,null,null,r):null}function D2(r,e){var t=r[e];if(t!=null&&t!=="none")return t}function Wve(r,e,t,n,a,i){if(!(!i||!i.length)){var o=N2(e,"color")||a.color!=null&&a.color!=="none"&&(N2(e,"colorAlpha")||N2(e,"colorSaturation"));if(o){var s=e.get("visualMin"),l=e.get("visualMax"),u=t.dataExtent.slice();s!=null&&s<u[0]&&(u[0]=s),l!=null&&l>u[1]&&(u[1]=l);var c=e.get("colorMappingBy"),f={type:o.name,dataExtent:u,visual:o.range};f.type==="color"&&(c==="index"||c==="id")?(f.mappingMethod="category",f.loop=!0):f.mappingMethod="linear";var d=new Er(f);return IU(d).drColorMappingBy=c,d}}}function N2(r,e){var t=r.get(e);return ce(t)&&t.length?{name:e,range:t}:null}function Xve(r,e,t,n,a,i){var o=ie({},e);if(a){var s=a.type,l=s==="color"&&IU(a).drColorMappingBy,u=l==="index"?n:l==="id"?i.mapIdToIndex(t.getId()):t.getValue(r.get("visualDimension"));o[s]=a.mapValueToVisual(u)}return o}var xg=Math.max,g1=Math.min,Fj=Fr,ON=O,PU=["itemStyle","borderWidth"],qve=["itemStyle","gapWidth"],Zve=["upperLabel","show"],$ve=["upperLabel","height"];const Kve={seriesType:"treemap",reset:function(r,e,t,n){var a=r.option,i=Cr(r,t).refContainer,o=Ht(r.getBoxLayoutParams(),i),s=a.size||[],l=me(Fj(o.width,s[0]),i.width),u=me(Fj(o.height,s[1]),i.height),c=n&&n.type,f=["treemapZoomToNode","treemapRootToNode"],d=mg(n,f,r),v=c==="treemapRender"||c==="treemapMove"?n.rootRect:null,g=r.getViewRoot(),y=LU(g);if(c!=="treemapMove"){var x=c==="treemapZoomToNode"?npe(r,d,g,l,u):v?[v.width,v.height]:[l,u],b=a.sort;b&&b!=="asc"&&b!=="desc"&&(b="desc");var w={squareRatio:a.squareRatio,sort:b,leafDepth:a.leafDepth};g.hostTree.clearLayouts();var T={x:0,y:0,width:x[0],height:x[1],area:x[0]*x[1]};g.setLayout(T),jU(g,w,!1,0),T=g.getLayout(),ON(y,function(D,M){var N=(y[M+1]||g).getValue();D.setLayout(ie({dataExtent:[N,N],borderWidth:0,upperHeight:0},T))})}var C=r.getData().tree.root;C.setLayout(ape(o,v,d),!0),r.setLayoutInfo(o),zU(C,new Oe(-o.x,-o.y,t.getWidth(),t.getHeight()),y,g,0)}};function jU(r,e,t,n){var a,i;if(!r.isRemoved()){var o=r.getLayout();a=o.width,i=o.height;var s=r.getModel(),l=s.get(PU),u=s.get(qve)/2,c=BU(s),f=Math.max(l,c),d=l-u,v=f-u;r.setLayout({borderWidth:l,upperHeight:f,upperLabelHeight:c},!0),a=xg(a-2*d,0),i=xg(i-d-v,0);var g=a*i,y=Qve(r,s,g,e,t,n);if(y.length){var x={x:d,y:v,width:a,height:i},b=g1(a,i),w=1/0,T=[];T.area=0;for(var C=0,D=y.length;C<D;){var M=y[C];T.push(M),T.area+=M.getLayout().area;var N=rpe(T,b,e.squareRatio);N<=w?(C++,w=N):(T.area-=T.pop().getLayout().area,Uj(T,b,x,u,!1),b=g1(x.width,x.height),T.length=T.area=0,w=1/0)}if(T.length&&Uj(T,b,x,u,!0),!t){var R=s.get("childrenVisibleMin");R!=null&&g<R&&(t=!0)}for(var C=0,D=y.length;C<D;C++)jU(y[C],e,t,n+1)}}}function Qve(r,e,t,n,a,i){var o=r.children||[],s=n.sort;s!=="asc"&&s!=="desc"&&(s=null);var l=n.leafDepth!=null&&n.leafDepth<=i;if(a&&!l)return r.viewChildren=[];o=dt(o,function(v){return!v.isRemoved()}),epe(o,s);var u=tpe(e,o,s);if(u.sum===0)return r.viewChildren=[];if(u.sum=Jve(e,t,u.sum,s,o),u.sum===0)return r.viewChildren=[];for(var c=0,f=o.length;c<f;c++){var d=o[c].getValue()/u.sum*t;o[c].setLayout({area:d})}return l&&(o.length&&r.setLayout({isLeafRoot:!0},!0),o.length=0),r.viewChildren=o,r.setLayout({dataExtent:u.dataExtent},!0),o}function Jve(r,e,t,n,a){if(!n)return t;for(var i=r.get("visibleMin"),o=a.length,s=o,l=o-1;l>=0;l--){var u=a[n==="asc"?o-l-1:l].getValue();u/t*e<i&&(s=l,t-=u)}return n==="asc"?a.splice(0,o-s):a.splice(s,o-s),t}function epe(r,e){return e&&r.sort(function(t,n){var a=e==="asc"?t.getValue()-n.getValue():n.getValue()-t.getValue();return a===0?e==="asc"?t.dataIndex-n.dataIndex:n.dataIndex-t.dataIndex:a}),r}function tpe(r,e,t){for(var n=0,a=0,i=e.length;a<i;a++)n+=e[a].getValue();var o=r.get("visualDimension"),s;return!e||!e.length?s=[NaN,NaN]:o==="value"&&t?(s=[e[e.length-1].getValue(),e[0].getValue()],t==="asc"&&s.reverse()):(s=[1/0,-1/0],ON(e,function(l){var u=l.getValue(o);u<s[0]&&(s[0]=u),u>s[1]&&(s[1]=u)})),{sum:n,dataExtent:s}}function rpe(r,e,t){for(var n=0,a=1/0,i=0,o=void 0,s=r.length;i<s;i++)o=r[i].getLayout().area,o&&(o<a&&(a=o),o>n&&(n=o));var l=r.area*r.area,u=e*e*t;return l?xg(u*n/l,l/(u*a)):1/0}function Uj(r,e,t,n,a){var i=e===t.width?0:1,o=1-i,s=["x","y"],l=["width","height"],u=t[s[i]],c=e?r.area/e:0;(a||c>t[l[o]])&&(c=t[l[o]]);for(var f=0,d=r.length;f<d;f++){var v=r[f],g={},y=c?v.getLayout().area/c:0,x=g[l[o]]=xg(c-2*n,0),b=t[s[i]]+t[l[i]]-u,w=f===d-1||b<y?b:y,T=g[l[i]]=xg(w-2*n,0);g[s[o]]=t[s[o]]+g1(n,x/2),g[s[i]]=u+g1(n,T/2),u+=w,v.setLayout(g,!0)}t[s[o]]+=c,t[l[o]]-=c}function npe(r,e,t,n,a){var i=(e||{}).node,o=[n,a];if(!i||i===t)return o;for(var s,l=n*a,u=l*r.option.zoomToNodeRatio;s=i.parentNode;){for(var c=0,f=s.children,d=0,v=f.length;d<v;d++)c+=f[d].getValue();var g=i.getValue();if(g===0)return o;u*=c/g;var y=s.getModel(),x=y.get(PU),b=Math.max(x,BU(y));u+=4*x*x+(3*x+b)*Math.pow(u,.5),u>DC&&(u=DC),i=s}u<l&&(u=l);var w=Math.pow(u/l,.5);return[n*w,a*w]}function ape(r,e,t){if(e)return{x:e.x,y:e.y};var n={x:0,y:0};if(!t)return n;var a=t.node,i=a.getLayout();if(!i)return n;for(var o=[i.width/2,i.height/2],s=a;s;){var l=s.getLayout();o[0]+=l.x,o[1]+=l.y,s=s.parentNode}return{x:r.width/2-o[0],y:r.height/2-o[1]}}function zU(r,e,t,n,a){var i=r.getLayout(),o=t[a],s=o&&o===r;if(!(o&&!s||a===t.length&&r!==n)){r.setLayout({isInView:!0,invisible:!s&&!e.intersect(i),isAboveViewRoot:s},!0);var l=new Oe(e.x-i.x,e.y-i.y,e.width,e.height);ON(r.viewChildren||[],function(u){zU(u,l,t,n,a+1)})}}function BU(r){return r.get(Zve)?r.get($ve):0}function ipe(r){r.registerSeriesModel(Tve),r.registerChartView(Ove),r.registerVisual(Fve),r.registerLayout(Kve),wve(r)}function ope(r){var e=r.findComponents({mainType:"legend"});!e||!e.length||r.eachSeriesByType("graph",function(t){var n=t.getCategoriesData(),a=t.getGraph(),i=a.data,o=n.mapArray(n.getName);i.filterSelf(function(s){var l=i.getItemModel(s),u=l.getShallow("category");if(u!=null){st(u)&&(u=o[u]);for(var c=0;c<e.length;c++)if(!e[c].isSelected(u))return!1}return!0})})}function spe(r){var e={};r.eachSeriesByType("graph",function(t){var n=t.getCategoriesData(),a=t.getData(),i={};n.each(function(o){var s=n.getName(o);i["ec-"+s]=o;var l=n.getItemModel(o),u=l.getModel("itemStyle").getItemStyle();u.fill||(u.fill=t.getColorFromPalette(s,e)),n.setItemVisual(o,"style",u);for(var c=["symbol","symbolSize","symbolKeepAspect"],f=0;f<c.length;f++){var d=l.getShallow(c[f],!0);d!=null&&n.setItemVisual(o,c[f],d)}}),n.count()&&a.each(function(o){var s=a.getItemModel(o),l=s.getShallow("category");if(l!=null){ye(l)&&(l=i["ec-"+l]);var u=n.getItemVisual(l,"style"),c=a.ensureUniqueItemVisual(o,"style");ie(c,u);for(var f=["symbol","symbolSize","symbolKeepAspect"],d=0;d<f.length;d++)a.setItemVisual(o,f[d],n.getItemVisual(l,f[d]))}})})}function _0(r){return r instanceof Array||(r=[r,r]),r}function lpe(r){r.eachSeriesByType("graph",function(e){var t=e.getGraph(),n=e.getEdgeData(),a=_0(e.get("edgeSymbol")),i=_0(e.get("edgeSymbolSize"));n.setVisual("fromSymbol",a&&a[0]),n.setVisual("toSymbol",a&&a[1]),n.setVisual("fromSymbolSize",i&&i[0]),n.setVisual("toSymbolSize",i&&i[1]),n.setVisual("style",e.getModel("lineStyle").getLineStyle()),n.each(function(o){var s=n.getItemModel(o),l=t.getEdgeByIndex(o),u=_0(s.getShallow("symbol",!0)),c=_0(s.getShallow("symbolSize",!0)),f=s.getModel("lineStyle").getLineStyle(),d=n.ensureUniqueItemVisual(o,"style");switch(ie(d,f),d.stroke){case"source":{var v=l.node1.getVisual("style");d.stroke=v&&v.fill;break}case"target":{var v=l.node2.getVisual("style");d.stroke=v&&v.fill;break}}u[0]&&l.setVisual("fromSymbol",u[0]),u[1]&&l.setVisual("toSymbol",u[1]),c[0]&&l.setVisual("fromSymbolSize",c[0]),c[1]&&l.setVisual("toSymbolSize",c[1])})})}var jA="-->",Cb=function(r){return r.get("autoCurveness")||null},VU=function(r,e){var t=Cb(r),n=20,a=[];if(st(t))n=t;else if(ce(t)){r.__curvenessList=t;return}e>n&&(n=e);var i=n%2?n+2:n+3;a=[];for(var o=0;o<i;o++)a.push((o%2?o+1:o)/10*(o%2?-1:1));r.__curvenessList=a},bg=function(r,e,t){var n=[r.id,r.dataIndex].join("."),a=[e.id,e.dataIndex].join(".");return[t.uid,n,a].join(jA)},GU=function(r){var e=r.split(jA);return[e[0],e[2],e[1]].join(jA)},upe=function(r,e){var t=bg(r.node1,r.node2,e);return e.__edgeMap[t]},cpe=function(r,e){var t=zA(bg(r.node1,r.node2,e),e),n=zA(bg(r.node2,r.node1,e),e);return t+n},zA=function(r,e){var t=e.__edgeMap;return t[r]?t[r].length:0};function fpe(r){Cb(r)&&(r.__curvenessList=[],r.__edgeMap={},VU(r))}function hpe(r,e,t,n){if(Cb(t)){var a=bg(r,e,t),i=t.__edgeMap,o=i[GU(a)];i[a]&&!o?i[a].isForward=!0:o&&i[a]&&(o.isForward=!0,i[a].isForward=!1),i[a]=i[a]||[],i[a].push(n)}}function PN(r,e,t,n){var a=Cb(e),i=ce(a);if(!a)return null;var o=upe(r,e);if(!o)return null;for(var s=-1,l=0;l<o.length;l++)if(o[l]===t){s=l;break}var u=cpe(r,e);VU(e,u),r.lineStyle=r.lineStyle||{};var c=bg(r.node1,r.node2,e),f=e.__curvenessList,d=i||u%2?0:1;if(o.isForward)return f[d+s];var v=GU(c),g=zA(v,e),y=f[s+g+d];return n?i?a&&a[0]===0?(g+d)%2?y:-y:((g%2?0:1)+d)%2?y:-y:(g+d)%2?y:-y:f[s+g+d]}function HU(r){var e=r.coordinateSystem;if(!(e&&e.type!=="view")){var t=r.getGraph();t.eachNode(function(n){var a=n.getModel();n.setLayout([+a.get("x"),+a.get("y")])}),jN(t,r)}}function jN(r,e){r.eachEdge(function(t,n){var a=zn(t.getModel().get(["lineStyle","curveness"]),-PN(t,e,n,!0),0),i=Hi(t.node1.getLayout()),o=Hi(t.node2.getLayout()),s=[i,o];+a&&s.push([(i[0]+o[0])/2-(i[1]-o[1])*a,(i[1]+o[1])/2-(o[0]-i[0])*a]),t.setLayout(s)})}function dpe(r,e){r.eachSeriesByType("graph",function(t){var n=t.get("layout"),a=t.coordinateSystem;if(a&&a.type!=="view"){var i=t.getData(),o=[];O(a.dimensions,function(d){o=o.concat(i.mapDimensionsAll(d))});for(var s=0;s<i.count();s++){for(var l=[],u=!1,c=0;c<o.length;c++){var f=i.get(o[c],s);isNaN(f)||(u=!0),l.push(f)}u?i.setItemLayout(s,a.dataToPoint(l)):i.setItemLayout(s,[NaN,NaN])}jN(i.graph,t)}else(!n||n==="none")&&HU(t)})}function xp(r){var e=r.coordinateSystem;if(e.type!=="view")return 1;var t=r.option.nodeScaleRatio,n=e.scaleX,a=e.getZoom(),i=(a-1)*t+1;return i/n}function bp(r){var e=r.getVisual("symbolSize");return e instanceof Array&&(e=(e[0]+e[1])/2),+e}var Yj=Math.PI,L2=[];function zN(r,e,t,n){var a=r.coordinateSystem;if(!(a&&a.type!=="view")){var i=a.getBoundingRect(),o=r.getData(),s=o.graph,l=i.width/2+i.x,u=i.height/2+i.y,c=Math.min(i.width,i.height)/2,f=o.count();if(o.setLayout({cx:l,cy:u}),!!f){if(t){var d=a.pointToData(n),v=d[0],g=d[1],y=[v-l,g-u];xc(y,y),Tp(y,y,c),t.setLayout([l+y[0],u+y[1]],!0);var x=r.get(["circular","rotateLabel"]);FU(t,x,l,u)}vpe[e](r,s,o,c,l,u,f),s.eachEdge(function(b,w){var T=zn(b.getModel().get(["lineStyle","curveness"]),PN(b,r,w),0),C=Hi(b.node1.getLayout()),D=Hi(b.node2.getLayout()),M,N=(C[0]+D[0])/2,R=(C[1]+D[1])/2;+T&&(T*=3,M=[l*T+N*(1-T),u*T+R*(1-T)]),b.setLayout([C,D,M])})}}}var vpe={value:function(r,e,t,n,a,i,o){var s=0,l=t.getSum("value"),u=Math.PI*2/(l||o);e.eachNode(function(c){var f=c.getValue("value"),d=u*(l?f:1)/2;s+=d,c.setLayout([n*Math.cos(s)+a,n*Math.sin(s)+i]),s+=d})},symbolSize:function(r,e,t,n,a,i,o){var s=0;L2.length=o;var l=xp(r);e.eachNode(function(f){var d=bp(f);isNaN(d)&&(d=2),d<0&&(d=0),d*=l;var v=Math.asin(d/2/n);isNaN(v)&&(v=Yj/2),L2[f.dataIndex]=v,s+=v*2});var u=(2*Yj-s)/o/2,c=0;e.eachNode(function(f){var d=u+L2[f.dataIndex];c+=d,(!f.getLayout()||!f.getLayout().fixed)&&f.setLayout([n*Math.cos(c)+a,n*Math.sin(c)+i]),c+=d})}};function FU(r,e,t,n){var a=r.getGraphicEl();if(a){var i=r.getModel(),o=i.get(["label","rotate"])||0,s=a.getSymbolPath();if(e){var l=r.getLayout(),u=Math.atan2(l[1]-n,l[0]-t);u<0&&(u=Math.PI*2+u);var c=l[0]<t;c&&(u=u-Math.PI);var f=c?"left":"right";s.setTextConfig({rotation:-u,position:f,origin:"center"});var d=s.ensureState("emphasis");ie(d.textConfig||(d.textConfig={}),{position:f})}else s.setTextConfig({rotation:o*=Math.PI/180})}}function ppe(r){r.eachSeriesByType("graph",function(e){e.get("layout")==="circular"&&zN(e,"symbolSize")})}var Ef=Tx;function gpe(r,e,t){for(var n=r,a=e,i=t.rect,o=i.width,s=i.height,l=[i.x+o/2,i.y+s/2],u=t.gravity==null?.1:t.gravity,c=0;c<n.length;c++){var f=n[c];f.p||(f.p=Nl(o*(Math.random()-.5)+l[0],s*(Math.random()-.5)+l[1])),f.pp=Hi(f.p),f.edges=null}var d=t.friction==null?.6:t.friction,v=d,g,y;return{warmUp:function(){v=d*.8},setFixed:function(x){n[x].fixed=!0},setUnfixed:function(x){n[x].fixed=!1},beforeStep:function(x){g=x},afterStep:function(x){y=x},step:function(x){g&&g(n,a);for(var b=[],w=n.length,T=0;T<a.length;T++){var C=a[T];if(!C.ignoreForceLayout){var D=C.n1,M=C.n2;el(b,M.p,D.p);var N=qp(b)-C.d,R=M.w/(D.w+M.w);isNaN(R)&&(R=0),xc(b,b),!D.fixed&&Ef(D.p,D.p,b,R*N*v),!M.fixed&&Ef(M.p,M.p,b,-(1-R)*N*v)}}for(var T=0;T<w;T++){var E=n[T];E.fixed||(el(b,l,E.p),Ef(E.p,E.p,b,u*v))}for(var T=0;T<w;T++)for(var D=n[T],k=T+1;k<w;k++){var M=n[k];el(b,M.p,D.p);var N=qp(b);N===0&&(q1(b,Math.random()-.5,Math.random()-.5),N=1);var I=(D.rep+M.rep)/N/N;!D.fixed&&Ef(D.pp,D.pp,b,I),!M.fixed&&Ef(M.pp,M.pp,b,-I)}for(var B=[],T=0;T<w;T++){var E=n[T];E.fixed||(el(B,E.p,E.pp),Ef(E.p,E.p,B,v),fn(E.pp,E.p))}v=v*.992;var P=v<.01;y&&y(n,a,P),x&&x(P)}}}function mpe(r){r.eachSeriesByType("graph",function(e){var t=e.coordinateSystem;if(!(t&&t.type!=="view"))if(e.get("layout")==="force"){var n=e.preservedPoints||{},a=e.getGraph(),i=a.data,o=a.edgeData,s=e.getModel("force"),l=s.get("initLayout");e.preservedPoints?i.each(function(T){var C=i.getId(T);i.setItemLayout(T,n[C]||[NaN,NaN])}):!l||l==="none"?HU(e):l==="circular"&&zN(e,"value");var u=i.getDataExtent("value"),c=o.getDataExtent("value"),f=s.get("repulsion"),d=s.get("edgeLength"),v=ce(f)?f:[f,f],g=ce(d)?d:[d,d];g=[g[1],g[0]];var y=i.mapArray("value",function(T,C){var D=i.getItemLayout(C),M=pt(T,u,v);return isNaN(M)&&(M=(v[0]+v[1])/2),{w:M,rep:M,fixed:i.getItemModel(C).get("fixed"),p:!D||isNaN(D[0])||isNaN(D[1])?null:D}}),x=o.mapArray("value",function(T,C){var D=a.getEdgeByIndex(C),M=pt(T,c,g);isNaN(M)&&(M=(g[0]+g[1])/2);var N=D.getModel(),R=zn(D.getModel().get(["lineStyle","curveness"]),-PN(D,e,C,!0),0);return{n1:y[D.node1.dataIndex],n2:y[D.node2.dataIndex],d:M,curveness:R,ignoreForceLayout:N.get("ignoreForceLayout")}}),b=t.getBoundingRect(),w=gpe(y,x,{rect:b,gravity:s.get("gravity"),friction:s.get("friction")});w.beforeStep(function(T,C){for(var D=0,M=T.length;D<M;D++)T[D].fixed&&fn(T[D].p,a.getNodeByIndex(D).getLayout())}),w.afterStep(function(T,C,D){for(var M=0,N=T.length;M<N;M++)T[M].fixed||a.getNodeByIndex(M).setLayout(T[M].p),n[i.getId(M)]=T[M].p;for(var M=0,N=C.length;M<N;M++){var R=C[M],E=a.getEdgeByIndex(M),k=R.n1.p,I=R.n2.p,B=E.getLayout();B=B?B.slice():[],B[0]=B[0]||[],B[1]=B[1]||[],fn(B[0],k),fn(B[1],I),+R.curveness&&(B[2]=[(k[0]+I[0])/2-(k[1]-I[1])*R.curveness,(k[1]+I[1])/2-(I[0]-k[0])*R.curveness]),E.setLayout(B)}}),e.forceLayout=w,e.preservedPoints=n,w.step()}else e.forceLayout=null})}function ype(r,e,t){var n=Cr(r,e),a=ie(r.getBoxLayoutParams(),{aspect:t}),i=Ht(a,n.refContainer);return m8(r,i,t)}function xpe(r,e){var t=[];return r.eachSeriesByType("graph",function(n){$g({targetModel:n,coordSysType:"view",coordSysProvider:a,isDefaultDataCoordSys:!0});function a(){var i=n.getData(),o=i.mapArray(function(g){var y=i.getItemModel(g);return[+y.get("x"),+y.get("y")]}),s=[],l=[];nb(o,s,l),l[0]-s[0]===0&&(l[0]+=1,s[0]-=1),l[1]-s[1]===0&&(l[1]+=1,s[1]-=1);var u=(l[0]-s[0])/(l[1]-s[1]),c=ype(n,e,u);isNaN(u)&&(s=[c.x,c.y],l=[c.x+c.width,c.y+c.height]);var f=l[0]-s[0],d=l[1]-s[1],v=new Mc(null,{api:e,ecModel:r});return v.zoomLimit=n.get("scaleLimit"),v.setBoundingRect(s[0],s[1],f,d),v.setViewRect(c.x,c.y,c.width,c.height),v.setCenter(n.get("center")),v.setZoom(n.get("zoom")),t.push(v),v}}),t}var Wj=lr.prototype,R2=rd.prototype,UU=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})();(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(UU);function E2(r){return isNaN(+r.cpx1)||isNaN(+r.cpy1)}var YU=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="ec-line",n}return e.prototype.getDefaultStyle=function(){return{stroke:ee.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new UU},e.prototype.buildPath=function(t,n){E2(n)?Wj.buildPath.call(this,t,n):R2.buildPath.call(this,t,n)},e.prototype.pointAt=function(t){return E2(this.shape)?Wj.pointAt.call(this,t):R2.pointAt.call(this,t)},e.prototype.tangentAt=function(t){var n=this.shape,a=E2(n)?[n.x2-n.x1,n.y2-n.y1]:R2.tangentAt.call(this,t);return xc(a,a)},e})(tt),k2=["fromSymbol","toSymbol"];function Xj(r){return"_"+r+"Type"}function qj(r,e,t){var n=e.getItemVisual(t,r);if(!n||n==="none")return n;var a=e.getItemVisual(t,r+"Size"),i=e.getItemVisual(t,r+"Rotate"),o=e.getItemVisual(t,r+"Offset"),s=e.getItemVisual(t,r+"KeepAspect"),l=fd(a),u=Tc(o||0,l);return n+l+u+(i||"")+(s||"")}function Zj(r,e,t){var n=e.getItemVisual(t,r);if(!(!n||n==="none")){var a=e.getItemVisual(t,r+"Size"),i=e.getItemVisual(t,r+"Rotate"),o=e.getItemVisual(t,r+"Offset"),s=e.getItemVisual(t,r+"KeepAspect"),l=fd(a),u=Tc(o||0,l),c=ur(n,-l[0]/2+u[0],-l[1]/2+u[1],l[0],l[1],null,s);return c.__specifiedRotation=i==null||isNaN(i)?void 0:+i*Math.PI/180||0,c.name=r,c}}function bpe(r){var e=new YU({name:"line",subPixelOptimize:!0});return BA(e.shape,r),e}function BA(r,e){r.x1=e[0][0],r.y1=e[0][1],r.x2=e[1][0],r.y2=e[1][1],r.percent=1;var t=e[2];t?(r.cpx1=t[0],r.cpy1=t[1]):(r.cpx1=NaN,r.cpy1=NaN)}var BN=(function(r){K(e,r);function e(t,n,a){var i=r.call(this)||this;return i._createLine(t,n,a),i}return e.prototype._createLine=function(t,n,a){var i=t.hostModel,o=t.getItemLayout(n),s=t.getItemVisual(n,"z2"),l=bpe(o);l.shape.percent=0,zt(l,{z2:Ce(s,0),shape:{percent:1}},i,n),this.add(l),O(k2,function(u){var c=Zj(u,t,n);this.add(c),this[Xj(u)]=qj(u,t,n)},this),this._updateCommonStl(t,n,a)},e.prototype.updateData=function(t,n,a){var i=t.hostModel,o=this.childOfName("line"),s=t.getItemLayout(n),l={shape:{}};BA(l.shape,s),lt(o,l,i,n),O(k2,function(u){var c=qj(u,t,n),f=Xj(u);if(this[f]!==c){this.remove(this.childOfName(u));var d=Zj(u,t,n);this.add(d)}this[f]=c},this),this._updateCommonStl(t,n,a)},e.prototype.getLinePath=function(){return this.childAt(0)},e.prototype._updateCommonStl=function(t,n,a){var i=t.hostModel,o=this.childOfName("line"),s=a&&a.emphasisLineStyle,l=a&&a.blurLineStyle,u=a&&a.selectLineStyle,c=a&&a.labelStatesModels,f=a&&a.emphasisDisabled,d=a&&a.focus,v=a&&a.blurScope;if(!a||t.hasItemOption){var g=t.getItemModel(n),y=g.getModel("emphasis");s=y.getModel("lineStyle").getLineStyle(),l=g.getModel(["blur","lineStyle"]).getLineStyle(),u=g.getModel(["select","lineStyle"]).getLineStyle(),f=y.get("disabled"),d=y.get("focus"),v=y.get("blurScope"),c=Sr(g)}var x=t.getItemVisual(n,"style"),b=x.stroke;o.useStyle(x),o.style.fill=null,o.style.strokeNoScale=!0,o.ensureState("emphasis").style=s,o.ensureState("blur").style=l,o.ensureState("select").style=u,O(k2,function(M){var N=this.childOfName(M);if(N){N.setColor(b),N.style.opacity=x.opacity;for(var R=0;R<Cn.length;R++){var E=Cn[R],k=o.getState(E);if(k){var I=k.style||{},B=N.ensureState(E),P=B.style||(B.style={});I.stroke!=null&&(P[N.__isEmptyBrush?"stroke":"fill"]=I.stroke),I.opacity!=null&&(P.opacity=I.opacity)}}N.markRedraw()}},this);var w=i.getRawValue(n);kr(this,c,{labelDataIndex:n,labelFetcher:{getFormattedLabel:function(M,N){return i.getFormattedLabel(M,N,t.dataType)}},inheritColor:b||ee.color.neutral99,defaultOpacity:x.opacity,defaultText:(w==null?t.getName(n):isFinite(w)?sr(w):w)+""});var T=this.getTextContent();if(T){var C=c.normal;T.__align=T.style.align,T.__verticalAlign=T.style.verticalAlign,T.__position=C.get("position")||"middle";var D=C.get("distance");ce(D)||(D=[D,D]),T.__labelDistance=D}this.setTextConfig({position:null,local:!0,inside:!1}),Ut(this,d,v,f)},e.prototype.highlight=function(){$o(this)},e.prototype.downplay=function(){Ko(this)},e.prototype.updateLayout=function(t,n){this.setLinePoints(t.getItemLayout(n))},e.prototype.setLinePoints=function(t){var n=this.childOfName("line");BA(n.shape,t),n.dirty()},e.prototype.beforeUpdate=function(){var t=this,n=t.childOfName("fromSymbol"),a=t.childOfName("toSymbol"),i=t.getTextContent();if(!n&&!a&&(!i||i.ignore))return;for(var o=1,s=this.parent;s;)s.scaleX&&(o/=s.scaleX),s=s.parent;var l=t.childOfName("line");if(!this.__dirty&&!l.__dirty)return;var u=l.shape.percent,c=l.pointAt(0),f=l.pointAt(u),d=el([],f,c);xc(d,d);function v(k,I){var B=k.__specifiedRotation;if(B==null){var P=l.tangentAt(I);k.attr("rotation",(I===1?-1:1)*Math.PI/2-Math.atan2(P[1],P[0]))}else k.attr("rotation",B)}if(n&&(n.setPosition(c),v(n,0),n.scaleX=n.scaleY=o*u,n.markRedraw()),a&&(a.setPosition(f),v(a,1),a.scaleX=a.scaleY=o*u,a.markRedraw()),i&&!i.ignore){i.x=i.y=0,i.originX=i.originY=0;var g=void 0,y=void 0,x=i.__labelDistance,b=x[0]*o,w=x[1]*o,T=u/2,C=l.tangentAt(T),D=[C[1],-C[0]],M=l.pointAt(T);D[1]>0&&(D[0]=-D[0],D[1]=-D[1]);var N=C[0]<0?-1:1;if(i.__position!=="start"&&i.__position!=="end"){var R=-Math.atan2(C[1],C[0]);f[0]<c[0]&&(R=Math.PI+R),i.rotation=R}var E=void 0;switch(i.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":E=-w,y="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":E=w,y="top";break;default:E=0,y="middle"}switch(i.__position){case"end":i.x=d[0]*b+f[0],i.y=d[1]*w+f[1],g=d[0]>.8?"left":d[0]<-.8?"right":"center",y=d[1]>.8?"top":d[1]<-.8?"bottom":"middle";break;case"start":i.x=-d[0]*b+c[0],i.y=-d[1]*w+c[1],g=d[0]>.8?"right":d[0]<-.8?"left":"center",y=d[1]>.8?"bottom":d[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=b*N+c[0],i.y=c[1]+E,g=C[0]<0?"right":"left",i.originX=-b*N,i.originY=-E;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=M[0],i.y=M[1]+E,g="center",i.originY=-E;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-b*N+f[0],i.y=f[1]+E,g=C[0]>=0?"right":"left",i.originX=b*N,i.originY=-E;break}i.scaleX=i.scaleY=o,i.setStyle({verticalAlign:i.__verticalAlign||y,align:i.__align||g})}},e})(Ne),VN=(function(){function r(e){this.group=new Ne,this._LineCtor=e||BN}return r.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var n=this,a=n.group,i=n._lineData;n._lineData=e,i||a.removeAll();var o=$j(e);e.diff(i).add(function(s){t._doAdd(e,s,o)}).update(function(s,l){t._doUpdate(i,e,l,s,o)}).remove(function(s){a.remove(i.getItemGraphicEl(s))}).execute()},r.prototype.updateLayout=function(){var e=this._lineData;e&&e.eachItemGraphicEl(function(t,n){t.updateLayout(e,n)},this)},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=$j(e),this._lineData=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t){this._progressiveEls=[];function n(s){!s.isGroup&&!_pe(s)&&(s.incremental=!0,s.ensureState("emphasis").hoverLayer=!0)}for(var a=e.start;a<e.end;a++){var i=t.getItemLayout(a);if(I2(i)){var o=new this._LineCtor(t,a,this._seriesScope);o.traverse(n),this.group.add(o),t.setItemGraphicEl(a,o),this._progressiveEls.push(o)}}},r.prototype.remove=function(){this.group.removeAll()},r.prototype.eachRendered=function(e){Ll(this._progressiveEls||this.group,e)},r.prototype._doAdd=function(e,t,n){var a=e.getItemLayout(t);if(I2(a)){var i=new this._LineCtor(e,t,n);e.setItemGraphicEl(t,i),this.group.add(i)}},r.prototype._doUpdate=function(e,t,n,a,i){var o=e.getItemGraphicEl(n);if(!I2(t.getItemLayout(a))){this.group.remove(o);return}o?o.updateData(t,a,i):o=new this._LineCtor(t,a,i),t.setItemGraphicEl(a,o),this.group.add(o)},r})();function _pe(r){return r.animators&&r.animators.length>0}function $j(r){var e=r.hostModel,t=e.getModel("emphasis");return{lineStyle:e.getModel("lineStyle").getLineStyle(),emphasisLineStyle:t.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:e.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:e.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:t.get("disabled"),blurScope:t.get("blurScope"),focus:t.get("focus"),labelStatesModels:Sr(e)}}function Kj(r){return isNaN(r[0])||isNaN(r[1])}function I2(r){return r&&!Kj(r[0])&&!Kj(r[1])}var O2=[],P2=[],j2=[],kf=Hr,z2=ul,Qj=Math.abs;function Jj(r,e,t){for(var n=r[0],a=r[1],i=r[2],o=1/0,s,l=t*t,u=.1,c=.1;c<=.9;c+=.1){O2[0]=kf(n[0],a[0],i[0],c),O2[1]=kf(n[1],a[1],i[1],c);var f=Qj(z2(O2,e)-l);f<o&&(o=f,s=c)}for(var d=0;d<32;d++){var v=s+u;P2[0]=kf(n[0],a[0],i[0],s),P2[1]=kf(n[1],a[1],i[1],s),j2[0]=kf(n[0],a[0],i[0],v),j2[1]=kf(n[1],a[1],i[1],v);var f=z2(P2,e)-l;if(Qj(f)<.01)break;var g=z2(j2,e)-l;u/=2,f<0?g>=0?s=s+u:s=s-u:g>=0?s=s-u:s=s+u}return s}function B2(r,e){var t=[],n=Zp,a=[[],[],[]],i=[[],[]],o=[];e/=2,r.eachEdge(function(s,l){var u=s.getLayout(),c=s.getVisual("fromSymbol"),f=s.getVisual("toSymbol");u.__original||(u.__original=[Hi(u[0]),Hi(u[1])],u[2]&&u.__original.push(Hi(u[2])));var d=u.__original;if(u[2]!=null){if(fn(a[0],d[0]),fn(a[1],d[2]),fn(a[2],d[1]),c&&c!=="none"){var v=bp(s.node1),g=Jj(a,d[0],v*e);n(a[0][0],a[1][0],a[2][0],g,t),a[0][0]=t[3],a[1][0]=t[4],n(a[0][1],a[1][1],a[2][1],g,t),a[0][1]=t[3],a[1][1]=t[4]}if(f&&f!=="none"){var v=bp(s.node2),g=Jj(a,d[1],v*e);n(a[0][0],a[1][0],a[2][0],g,t),a[1][0]=t[1],a[2][0]=t[2],n(a[0][1],a[1][1],a[2][1],g,t),a[1][1]=t[1],a[2][1]=t[2]}fn(u[0],a[0]),fn(u[1],a[2]),fn(u[2],a[1])}else{if(fn(i[0],d[0]),fn(i[1],d[1]),el(o,i[1],i[0]),xc(o,o),c&&c!=="none"){var v=bp(s.node1);Tx(i[0],i[0],o,v*e)}if(f&&f!=="none"){var v=bp(s.node2);Tx(i[1],i[1],o,-v*e)}fn(u[0],i[0]),fn(u[1],i[1])}})}var WU=Je();function Spe(r){if(r)return WU(r).bridge}function ez(r,e){r&&(WU(r).bridge=e)}function tz(r){return r.type==="view"}var wpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){var a=new em,i=new VN,o=this.group,s=new Ne;this._controller=new Ac(n.getZr()),this._controllerHost={target:s},s.add(a.group),s.add(i.group),o.add(s),this._symbolDraw=a,this._lineDraw=i,this._mainGroup=s,this._firstRender=!0},e.prototype.render=function(t,n,a){var i=this,o=t.coordinateSystem,s=!1;this._model=t,this._api=a,this._active=!0;var l=this._getThumbnailInfo();l&&l.bridge.reset(a);var u=this._symbolDraw,c=this._lineDraw;if(tz(o)){var f={x:o.x,y:o.y,scaleX:o.scaleX,scaleY:o.scaleY};this._firstRender?this._mainGroup.attr(f):lt(this._mainGroup,f,t)}B2(t.getGraph(),xp(t));var d=t.getData();u.updateData(d);var v=t.getEdgeData();c.updateData(v),this._updateNodeAndLinkScale(),this._updateController(null,t,a),clearTimeout(this._layoutTimeout);var g=t.forceLayout,y=t.get(["force","layoutAnimation"]);g&&(s=!0,this._startForceLayoutIteration(g,a,y));var x=t.get("layout");d.graph.eachNode(function(C){var D=C.dataIndex,M=C.getGraphicEl(),N=C.getModel();if(M){M.off("drag").off("dragend");var R=N.get("draggable");R&&M.on("drag",function(k){switch(x){case"force":g.warmUp(),!i._layouting&&i._startForceLayoutIteration(g,a,y),g.setFixed(D),d.setItemLayout(D,[M.x,M.y]);break;case"circular":d.setItemLayout(D,[M.x,M.y]),C.setLayout({fixed:!0},!0),zN(t,"symbolSize",C,[k.offsetX,k.offsetY]),i.updateLayout(t);break;case"none":default:d.setItemLayout(D,[M.x,M.y]),jN(t.getGraph(),t),i.updateLayout(t);break}}).on("dragend",function(){g&&g.setUnfixed(D)}),M.setDraggable(R,!!N.get("cursor"));var E=N.get(["emphasis","focus"]);E==="adjacency"&&(je(M).focus=C.getAdjacentDataIndices())}}),d.graph.eachEdge(function(C){var D=C.getGraphicEl(),M=C.getModel().get(["emphasis","focus"]);D&&M==="adjacency"&&(je(D).focus={edge:[C.dataIndex],node:[C.node1.dataIndex,C.node2.dataIndex]})});var b=t.get("layout")==="circular"&&t.get(["circular","rotateLabel"]),w=d.getLayout("cx"),T=d.getLayout("cy");d.graph.eachNode(function(C){FU(C,b,w,T)}),this._firstRender=!1,s||this._renderThumbnail(t,a,this._symbolDraw,this._lineDraw)},e.prototype.dispose=function(){this.remove(),this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype._startForceLayoutIteration=function(t,n,a){var i=this,o=!1;(function s(){t.step(function(l){i.updateLayout(i._model),(l||!o)&&(o=!0,i._renderThumbnail(i._model,n,i._symbolDraw,i._lineDraw)),(i._layouting=!l)&&(a?i._layoutTimeout=setTimeout(s,16):s())})})()},e.prototype._updateController=function(t,n,a){var i=this._controller,o=this._controllerHost,s=n.coordinateSystem;if(!tz(s)){i.disable();return}i.enable(n.get("roam"),{api:a,zInfo:{component:n},triggerInfo:{roamTrigger:n.get("roamTrigger"),isInSelf:function(l,u,c){return s.containPoint([u,c])},isInClip:function(l,u,c){return!t||t.contain(u,c)}}}),o.zoomLimit=n.get("scaleLimit"),o.zoom=s.getZoom(),i.off("pan").off("zoom").on("pan",function(l){a.dispatchAction({seriesId:n.id,type:"graphRoam",dx:l.dx,dy:l.dy})}).on("zoom",function(l){a.dispatchAction({seriesId:n.id,type:"graphRoam",zoom:l.scale,originX:l.originX,originY:l.originY})})},e.prototype.updateViewOnPan=function(t,n,a){this._active&&(DN(this._controllerHost,a.dx,a.dy),this._updateThumbnailWindow())},e.prototype.updateViewOnZoom=function(t,n,a){this._active&&(NN(this._controllerHost,a.zoom,a.originX,a.originY),this._updateNodeAndLinkScale(),B2(t.getGraph(),xp(t)),this._lineDraw.updateLayout(),n.updateLabelLayout(),this._updateThumbnailWindow())},e.prototype._updateNodeAndLinkScale=function(){var t=this._model,n=t.getData(),a=xp(t);n.eachItemGraphicEl(function(i,o){i&&i.setSymbolScale(a)})},e.prototype.updateLayout=function(t){this._active&&(B2(t.getGraph(),xp(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout())},e.prototype.remove=function(){this._active=!1,clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove(),this._controller&&this._controller.disable()},e.prototype._getThumbnailInfo=function(){var t=this._model,n=t.coordinateSystem;if(n.type==="view"){var a=Spe(t);if(a)return{bridge:a,coordSys:n}}},e.prototype._updateThumbnailWindow=function(){var t=this._getThumbnailInfo();t&&t.bridge.updateWindow(t.coordSys.transform,this._api)},e.prototype._renderThumbnail=function(t,n,a,i){var o=this._getThumbnailInfo();if(o){var s=new Ne,l=a.group.children(),u=i.group.children(),c=new Ne,f=new Ne;s.add(f),s.add(c);for(var d=0;d<l.length;d++){var v=l[d],g=v.children()[0],y=v.x,x=v.y,b=De(g.shape),w=ie(b,{width:g.scaleX,height:g.scaleY,x:y-g.scaleX/2,y:x-g.scaleY/2}),T=De(g.style),C=new g.constructor({shape:w,style:T,z2:151});f.add(C)}for(var d=0;d<u.length;d++){var v=u[d],D=v.children()[0],T=De(D.style),w=De(D.shape),M=new YU({style:T,shape:w,z2:151});c.add(M)}o.bridge.renderContent({api:n,roamType:t.get("roam"),viewportRect:null,group:s,targetTrans:o.coordSys.transform})}},e.type="graph",e})(St);function If(r){return"_EC_"+r}var Tpe=(function(){function r(e){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=e||!1}return r.prototype.isDirected=function(){return this._directed},r.prototype.addNode=function(e,t){e=e==null?""+t:""+e;var n=this._nodesMap;if(!n[If(e)]){var a=new Lu(e,t);return a.hostGraph=this,this.nodes.push(a),n[If(e)]=a,a}},r.prototype.getNodeByIndex=function(e){var t=this.data.getRawIndex(e);return this.nodes[t]},r.prototype.getNodeById=function(e){return this._nodesMap[If(e)]},r.prototype.addEdge=function(e,t,n){var a=this._nodesMap,i=this._edgesMap;if(st(e)&&(e=this.nodes[e]),st(t)&&(t=this.nodes[t]),e instanceof Lu||(e=a[If(e)]),t instanceof Lu||(t=a[If(t)]),!(!e||!t)){var o=e.id+"-"+t.id,s=new XU(e,t,n);return s.hostGraph=this,this._directed&&(e.outEdges.push(s),t.inEdges.push(s)),e.edges.push(s),e!==t&&t.edges.push(s),this.edges.push(s),i[o]=s,s}},r.prototype.getEdgeByIndex=function(e){var t=this.edgeData.getRawIndex(e);return this.edges[t]},r.prototype.getEdge=function(e,t){e instanceof Lu&&(e=e.id),t instanceof Lu&&(t=t.id);var n=this._edgesMap;return this._directed?n[e+"-"+t]:n[e+"-"+t]||n[t+"-"+e]},r.prototype.eachNode=function(e,t){for(var n=this.nodes,a=n.length,i=0;i<a;i++)n[i].dataIndex>=0&&e.call(t,n[i],i)},r.prototype.eachEdge=function(e,t){for(var n=this.edges,a=n.length,i=0;i<a;i++)n[i].dataIndex>=0&&n[i].node1.dataIndex>=0&&n[i].node2.dataIndex>=0&&e.call(t,n[i],i)},r.prototype.breadthFirstTraverse=function(e,t,n,a){if(t instanceof Lu||(t=this._nodesMap[If(t)]),!!t){for(var i=n==="out"?"outEdges":n==="in"?"inEdges":"edges",o=0;o<this.nodes.length;o++)this.nodes[o].__visited=!1;if(!e.call(a,t,null))for(var s=[t];s.length;)for(var l=s.shift(),u=l[i],o=0;o<u.length;o++){var c=u[o],f=c.node1===l?c.node2:c.node1;if(!f.__visited){if(e.call(a,f,l))return;s.push(f),f.__visited=!0}}}},r.prototype.update=function(){for(var e=this.data,t=this.edgeData,n=this.nodes,a=this.edges,i=0,o=n.length;i<o;i++)n[i].dataIndex=-1;for(var i=0,o=e.count();i<o;i++)n[e.getRawIndex(i)].dataIndex=i;t.filterSelf(function(s){var l=a[t.getRawIndex(s)];return l.node1.dataIndex>=0&&l.node2.dataIndex>=0});for(var i=0,o=a.length;i<o;i++)a[i].dataIndex=-1;for(var i=0,o=t.count();i<o;i++)a[t.getRawIndex(i)].dataIndex=i},r.prototype.clone=function(){for(var e=new r(this._directed),t=this.nodes,n=this.edges,a=0;a<t.length;a++)e.addNode(t[a].id,t[a].dataIndex);for(var a=0;a<n.length;a++){var i=n[a];e.addEdge(i.node1.id,i.node2.id,i.dataIndex)}return e},r})(),Lu=(function(){function r(e,t){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=e??"",this.dataIndex=t??-1}return r.prototype.degree=function(){return this.edges.length},r.prototype.inDegree=function(){return this.inEdges.length},r.prototype.outDegree=function(){return this.outEdges.length},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,n=t.data.getItemModel(this.dataIndex);return n.getModel(e)}},r.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},r.prototype.getTrajectoryDataIndices=function(){for(var e=Te(),t=Te(),n=0,a=this.edges.length;n<a;n++){var i=this.edges[n];if(!(i.dataIndex<0)){e.set(i.dataIndex,!0);for(var o=[i.node1],s=[i.node2],l=0;l<o.length;){var u=o[l];l++,t.set(u.dataIndex,!0);for(var c=u.inEdges,f=0,d=c.length,v=void 0,g=void 0;f<d;f++)v=c[f],g=v.dataIndex,g>=0&&!e.hasKey(g)&&(e.set(g,!0),o.push(v.node1))}for(l=0;l<s.length;){var y=s[l];l++,t.set(y.dataIndex,!0);for(var x=y.outEdges,f=0,b=x.length,w=void 0,T=void 0;f<b;f++)w=x[f],T=w.dataIndex,T>=0&&!e.hasKey(T)&&(e.set(T,!0),s.push(w.node2))}}}return{edge:e.keys(),node:t.keys()}},r})(),XU=(function(){function r(e,t,n){this.dataIndex=-1,this.node1=e,this.node2=t,this.dataIndex=n??-1}return r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,n=t.edgeData.getItemModel(this.dataIndex);return n.getModel(e)}},r.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},r.prototype.getTrajectoryDataIndices=function(){var e=Te(),t=Te();e.set(this.dataIndex,!0);for(var n=[this.node1],a=[this.node2],i=0;i<n.length;){var o=n[i];i++,t.set(o.dataIndex,!0);for(var s=o.inEdges,l=0,u=s.length,c=void 0,f=void 0;l<u;l++)c=o.inEdges[l],f=c.dataIndex,f>=0&&!e.hasKey(f)&&(e.set(f,!0),n.push(c.node1))}for(i=0;i<a.length;){var d=a[i];i++,t.set(d.dataIndex,!0);for(var v=d.outEdges,l=0,u=v.length,g=void 0,y=void 0;l<u;l++)g=d.outEdges[l],y=g.dataIndex,y>=0&&!e.hasKey(y)&&(e.set(y,!0),a.push(g.node2))}return{edge:e.keys(),node:t.keys()}},r})();function qU(r,e){return{getValue:function(t){var n=this[r][e];return n.getStore().get(n.getDimensionIndex(t||"value"),this.dataIndex)},setVisual:function(t,n){this.dataIndex>=0&&this[r][e].setItemVisual(this.dataIndex,t,n)},getVisual:function(t){return this[r][e].getItemVisual(this.dataIndex,t)},setLayout:function(t,n){this.dataIndex>=0&&this[r][e].setItemLayout(this.dataIndex,t,n)},getLayout:function(){return this[r][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[r][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[r][e].getRawIndex(this.dataIndex)}}}Jt(Lu,qU("hostGraph","data"));Jt(XU,qU("hostGraph","edgeData"));function GN(r,e,t,n,a){for(var i=new Tpe(n),o=0;o<r.length;o++)i.addNode(Fr(r[o].id,r[o].name,o),o);for(var s=[],l=[],u=0,o=0;o<e.length;o++){var c=e[o],f=c.source,d=c.target;i.addEdge(f,d,u)&&(l.push(c),s.push(Fr(xr(c.id,null),f+" > "+d)),u++)}var v=t.get("coordinateSystem"),g;if(v==="cartesian2d"||v==="polar"||v==="matrix")g=to(r,t);else{var y=ld.get(v),x=y?y.dimensions||[]:[];Fe(x,"value")<0&&x.concat(["value"]);var b=hd(r,{coordDimensions:x,encodeDefine:t.getEncode()}).dimensions;g=new pn(b,t),g.initData(r)}var w=new pn(["value"],t);return w.initData(l,s),a&&a(g,w),DU({mainData:g,struct:i,structAttr:"graph",datas:{node:g,edge:w},datasAttr:{node:"data",edge:"edgeData"}}),i.update(),i}var Cpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments);var n=this;function a(){return n._categoriesData}this.legendVisualProvider=new md(a,a),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeDefaultAndTheme=function(t){r.prototype.mergeDefaultAndTheme.apply(this,arguments),lc(t,"edgeLabel",["show"])},e.prototype.getInitialData=function(t,n){var a=t.edges||t.links||[],i=t.data||t.nodes||[],o=this;if(i&&a){fpe(this);var s=GN(i,a,this,!0,l);return O(s.edges,function(u){hpe(u.node1,u.node2,this,u.dataIndex)},this),s.data}function l(u,c){u.wrapMethod("getItemModel",function(g){var y=o._categoriesModels,x=g.getShallow("category"),b=y[x];return b&&(b.parentModel=g.parentModel,g.parentModel=b),g});var f=et.prototype.getModel;function d(g,y){var x=f.call(this,g,y);return x.resolveParentPath=v,x}c.wrapMethod("getItemModel",function(g){return g.resolveParentPath=v,g.getModel=d,g});function v(g){if(g&&(g[0]==="label"||g[1]==="label")){var y=g.slice();return g[0]==="label"?y[0]="edgeLabel":g[1]==="label"&&(y[1]="edgeLabel"),y}return g}}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.getCategoriesData=function(){return this._categoriesData},e.prototype.formatTooltip=function(t,n,a){if(a==="edge"){var i=this.getData(),o=this.getDataParams(t,a),s=i.graph.getEdgeByIndex(t),l=i.getName(s.node1.dataIndex),u=i.getName(s.node2.dataIndex),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),pr("nameValue",{name:c.join(" > "),value:o.value,noValue:o.value==null})}var f=K8({series:this,dataIndex:t,multipleSeries:n});return f},e.prototype._updateCategoriesData=function(){var t=fe(this.option.categories||[],function(a){return a.value!=null?a:ie({value:0},a)}),n=new pn(["value"],this);n.initData(t),this._categoriesData=n,this._categoriesModels=n.mapArray(function(a){return n.getItemModel(a)})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.isAnimationEnabled=function(){return r.prototype.isAnimationEnabled.call(this)&&!(this.get("layout")==="force"&&this.get(["force","layoutAnimation"]))},e.type="series.graph",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.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:ee.color.neutral50,width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:ee.color.primary}}},e})(Ct);function Ape(r){r.registerChartView(wpe),r.registerSeriesModel(Cpe),r.registerProcessor(ope),r.registerVisual(spe),r.registerVisual(lpe),r.registerLayout(dpe),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,ppe),r.registerLayout(mpe),r.registerCoordinateSystem("graphView",{dimensions:Mc.dimensions,create:xpe}),r.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},Kt),r.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},Kt),r.registerAction({type:"graphRoam",event:"graphRoam",update:"none"},function(e,t,n){t.eachComponent({mainType:"series",query:e},function(a){var i=n.getViewOfSeriesModel(a);i&&(e.dx!=null&&e.dy!=null&&i.updateViewOnPan(a,n,e),e.zoom!=null&&e.originX!=null&&e.originY!=null&&i.updateViewOnZoom(a,n,e));var o=a.coordinateSystem,s=Sb(o,e,a.get("scaleLimit"));a.setCenter&&a.setCenter(s.center),a.setZoom&&a.setZoom(s.zoom)})})}var rz=(function(r){K(e,r);function e(t,n,a){var i=r.call(this)||this;je(i).dataType="node",i.z2=2;var o=new ot;return i.setTextContent(o),i.updateData(t,n,a,!0),i}return e.prototype.updateData=function(t,n,a,i){var o=this,s=t.graph.getNodeByIndex(n),l=t.hostModel,u=s.getModel(),c=u.getModel("emphasis"),f=t.getItemLayout(n),d=ie(Vi(u.getModel("itemStyle"),f,!0),f),v=this;if(isNaN(d.startAngle)){v.setShape(d);return}i?v.setShape(d):lt(v,{shape:d},l,n);var g=ie(Vi(u.getModel("itemStyle"),f,!0),f);o.setShape(g),o.useStyle(t.getItemVisual(n,"style")),_r(o,u),this._updateLabel(l,u,s),t.setItemGraphicEl(n,v),_r(v,u,"itemStyle");var y=c.get("focus");Ut(this,y==="adjacency"?s.getAdjacentDataIndices():y,c.get("blurScope"),c.get("disabled"))},e.prototype._updateLabel=function(t,n,a){var i=this.getTextContent(),o=a.getLayout(),s=(o.startAngle+o.endAngle)/2,l=Math.cos(s),u=Math.sin(s),c=n.getModel("label");i.ignore=!c.get("show");var f=Sr(n),d=a.getVisual("style");kr(i,f,{labelFetcher:{getFormattedLabel:function(w,T,C,D,M,N){return t.getFormattedLabel(w,T,"node",D,zn(M,f.normal&&f.normal.get("formatter"),n.get("name")),N)}},labelDataIndex:a.dataIndex,defaultText:a.dataIndex+"",inheritColor:d.fill,defaultOpacity:d.opacity,defaultOutsidePosition:"startArc"});var v=c.get("position")||"outside",g=c.get("distance")||0,y;v==="outside"?y=o.r+g:y=(o.r+o.r0)/2,this.textConfig={inside:v!=="outside"};var x=v!=="outside"?c.get("align")||"center":l>0?"left":"right",b=v!=="outside"?c.get("verticalAlign")||"middle":u>0?"top":"bottom";i.attr({x:l*y+o.cx,y:u*y+o.cy,rotation:0,style:{align:x,verticalAlign:b}})},e})(nn),Mpe=(function(r){K(e,r);function e(t,n,a,i){var o=r.call(this)||this;return je(o).dataType="edge",o.updateData(t,n,a,i,!0),o}return e.prototype.buildPath=function(t,n){t.moveTo(n.s1[0],n.s1[1]);var a=.7,i=n.clockwise;t.arc(n.cx,n.cy,n.r,n.sStartAngle,n.sEndAngle,!i),t.bezierCurveTo((n.cx-n.s2[0])*a+n.s2[0],(n.cy-n.s2[1])*a+n.s2[1],(n.cx-n.t1[0])*a+n.t1[0],(n.cy-n.t1[1])*a+n.t1[1],n.t1[0],n.t1[1]),t.arc(n.cx,n.cy,n.r,n.tStartAngle,n.tEndAngle,!i),t.bezierCurveTo((n.cx-n.t2[0])*a+n.t2[0],(n.cy-n.t2[1])*a+n.t2[1],(n.cx-n.s1[0])*a+n.s1[0],(n.cy-n.s1[1])*a+n.s1[1],n.s1[0],n.s1[1]),t.closePath()},e.prototype.updateData=function(t,n,a,i,o){var s=t.hostModel,l=n.graph.getEdgeByIndex(a),u=l.getLayout(),c=l.node1.getModel(),f=n.getItemModel(l.dataIndex),d=f.getModel("lineStyle"),v=f.getModel("emphasis"),g=v.get("focus"),y=ie(Vi(c.getModel("itemStyle"),u,!0),u),x=this;if(isNaN(y.sStartAngle)||isNaN(y.tStartAngle)){x.setShape(y);return}o?(x.setShape(y),nz(x,l,t,d)):(ja(x),nz(x,l,t,d),lt(x,{shape:y},s,a)),Ut(this,g==="adjacency"?l.getAdjacentDataIndices():g,v.get("blurScope"),v.get("disabled")),_r(x,f,"lineStyle"),n.setItemGraphicEl(l.dataIndex,x)},e})(tt);function nz(r,e,t,n){var a=e.node1,i=e.node2,o=r.style;r.setStyle(n.getLineStyle());var s=n.get("color");switch(s){case"source":o.fill=t.getItemVisual(a.dataIndex,"style").fill,o.decal=a.getVisual("style").decal;break;case"target":o.fill=t.getItemVisual(i.dataIndex,"style").fill,o.decal=i.getVisual("style").decal;break;case"gradient":var l=t.getItemVisual(a.dataIndex,"style").fill,u=t.getItemVisual(i.dataIndex,"style").fill;if(ye(l)&&ye(u)){var c=r.shape,f=(c.s1[0]+c.s2[0])/2,d=(c.s1[1]+c.s2[1])/2,v=(c.t1[0]+c.t2[0])/2,g=(c.t1[1]+c.t2[1])/2;o.fill=new bc(f,d,v,g,[{offset:0,color:l},{offset:1,color:u}],!0)}break}}var Dpe=Math.PI/180,Npe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){},e.prototype.render=function(t,n,a){var i=t.getData(),o=this._data,s=this.group,l=-t.get("startAngle")*Dpe;if(i.diff(o).add(function(c){var f=i.getItemLayout(c);if(f){var d=new rz(i,c,l);je(d).dataIndex=c,s.add(d)}}).update(function(c,f){var d=o.getItemGraphicEl(f),v=i.getItemLayout(c);if(!v){d&&Ho(d,t,f);return}d?d.updateData(i,c,l):d=new rz(i,c,l),s.add(d)}).remove(function(c){var f=o.getItemGraphicEl(c);f&&Ho(f,t,c)}).execute(),!o){var u=t.get("center");this.group.scaleX=.01,this.group.scaleY=.01,this.group.originX=me(u[0],a.getWidth()),this.group.originY=me(u[1],a.getHeight()),zt(this.group,{scaleX:1,scaleY:1},t)}this._data=i,this.renderEdges(t,l)},e.prototype.renderEdges=function(t,n){var a=t.getData(),i=t.getEdgeData(),o=this._edgeData,s=this.group;i.diff(o).add(function(l){var u=new Mpe(a,i,l,n);je(u).dataIndex=l,s.add(u)}).update(function(l,u){var c=o.getItemGraphicEl(u);c.updateData(a,i,l,n),s.add(c)}).remove(function(l){var u=o.getItemGraphicEl(l);u&&Ho(u,t,l)}).execute(),this._edgeData=i},e.prototype.dispose=function(){},e.type="chord",e})(St),Lpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this.legendVisualProvider=new md(xe(this.getData,this),xe(this.getRawData,this))},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links)},e.prototype.getInitialData=function(t,n){var a=t.edges||t.links||[],i=t.data||t.nodes||[];if(i&&a){var o=GN(i,a,this,!0,s);return o.data}function s(l,u){var c=et.prototype.getModel;function f(v,g){var y=c.call(this,v,g);return y.resolveParentPath=d,y}u.wrapMethod("getItemModel",function(v){return v.resolveParentPath=d,v.getModel=f,v});function d(v){if(v&&(v[0]==="label"||v[1]==="label")){var g=v.slice();return v[0]==="label"?g[0]="edgeLabel":v[1]==="label"&&(g[1]="edgeLabel"),g}return v}}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,n,a){var i=this.getDataParams(t,a);if(a==="edge"){var o=this.getData(),s=o.graph.getEdgeByIndex(t),l=o.getName(s.node1.dataIndex),u=o.getName(s.node2.dataIndex),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),pr("nameValue",{name:c.join(" > "),value:i.value,noValue:i.value==null})}return pr("nameValue",{name:i.name,value:i.value,noValue:i.value==null})},e.prototype.getDataParams=function(t,n){var a=r.prototype.getDataParams.call(this,t,n);if(n==="node"){var i=this.getData(),o=this.getGraph().getNodeByIndex(t);if(a.name==null&&(a.name=i.getName(t)),a.value==null){var s=o.getLayout().value;a.value=s}}return a},e.type="series.chord",e.defaultOption={z:2,coordinateSystem:"none",legendHoverLink:!0,colorBy:"data",left:0,top:0,right:0,bottom:0,width:null,height:null,center:["50%","50%"],radius:["70%","80%"],clockwise:!0,startAngle:90,endAngle:"auto",minAngle:0,padAngle:3,itemStyle:{borderRadius:[0,0,5,5]},lineStyle:{width:0,color:"source",opacity:.2},label:{show:!0,position:"outside",distance:5},emphasis:{focus:"adjacency",lineStyle:{opacity:.5}}},e})(Ct),V2=Math.PI/180;function Rpe(r,e){r.eachSeriesByType("chord",function(t){Epe(t,e)})}function Epe(r,e){var t=r.getData(),n=t.graph,a=r.getEdgeData(),i=a.count();if(i){var o=g8(r,e),s=o.cx,l=o.cy,u=o.r,c=o.r0,f=Math.max((r.get("padAngle")||0)*V2,0),d=Math.max((r.get("minAngle")||0)*V2,0),v=-r.get("startAngle")*V2,g=v+Math.PI*2,y=r.get("clockwise"),x=y?1:-1,b=[v,g];ab(b,!y);var w=b[0],T=b[1],C=T-w,D=t.getSum("value")===0&&a.getSum("value")===0,M=[],N=0;n.eachEdge(function(F){var X=D?1:F.getValue("value");D&&(X>0||d)&&(N+=2);var G=F.node1.dataIndex,W=F.node2.dataIndex;M[G]=(M[G]||0)+X,M[W]=(M[W]||0)+X});var R=0;if(n.eachNode(function(F){var X=F.getValue("value");isNaN(X)||(M[F.dataIndex]=Math.max(X,M[F.dataIndex]||0)),!D&&(M[F.dataIndex]>0||d)&&N++,R+=M[F.dataIndex]||0}),!(N===0||R===0)){f*N>=Math.abs(C)&&(f=Math.max(0,(Math.abs(C)-d*N)/N)),(f+d)*N>=Math.abs(C)&&(d=(Math.abs(C)-f*N)/N);var E=(C-f*N*x)/R,k=0,I=0,B=0;n.eachNode(function(F){var X=M[F.dataIndex]||0,G=E*(R?X:1)*x;Math.abs(G)<d?k+=d-Math.abs(G):(I+=Math.abs(G)-d,B+=Math.abs(G)),F.setLayout({angle:G,value:X})});var P=!1;if(k>I){var H=k/I;n.eachNode(function(F){var X=F.getLayout().angle;Math.abs(X)>=d?F.setLayout({angle:X*H,ratio:H},!0):F.setLayout({angle:d,ratio:d===0?1:X/d},!0)})}else n.eachNode(function(F){if(!P){var X=F.getLayout().angle,G=Math.min(X/B,1),W=G*k;X-W<d&&(P=!0)}});var V=k;n.eachNode(function(F){if(!(V<=0)){var X=F.getLayout().angle;if(X>d&&d>0){var G=P?1:Math.min(X/B,1),W=X-d,$=Math.min(W,Math.min(V,k*G));V-=$,F.setLayout({angle:X-$,ratio:(X-$)/X},!0)}else d>0&&F.setLayout({angle:d,ratio:X===0?1:d/X},!0)}});var j=w,U=[];n.eachNode(function(F){var X=Math.max(F.getLayout().angle,d);F.setLayout({cx:s,cy:l,r0:c,r:u,startAngle:j,endAngle:j+X*x,clockwise:y},!0),U[F.dataIndex]=j,j+=(X+f)*x}),n.eachEdge(function(F){var X=D?1:F.getValue("value"),G=E*(R?X:1)*x,W=F.node1.dataIndex,$=U[W]||0,te=Math.abs((F.node1.getLayout().ratio||1)*G),ue=$+te*x,ge=[s+c*Math.cos($),l+c*Math.sin($)],Se=[s+c*Math.cos(ue),l+c*Math.sin(ue)],Xe=F.node2.dataIndex,be=U[Xe]||0,we=Math.abs((F.node2.getLayout().ratio||1)*G),ze=be+we*x,oe=[s+c*Math.cos(be),l+c*Math.sin(be)],pe=[s+c*Math.cos(ze),l+c*Math.sin(ze)];F.setLayout({s1:ge,s2:Se,sStartAngle:$,sEndAngle:ue,t1:oe,t2:pe,tStartAngle:be,tEndAngle:ze,cx:s,cy:l,r:c,value:X,clockwise:y}),U[W]=ue,U[Xe]=ze})}}}function kpe(r){r.registerChartView(Npe),r.registerSeriesModel(Lpe),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,Rpe),r.registerProcessor(pd("chord"))}var Ipe=(function(){function r(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return r})(),Ope=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="pointer",n}return e.prototype.getDefaultShape=function(){return new Ipe},e.prototype.buildPath=function(t,n){var a=Math.cos,i=Math.sin,o=n.r,s=n.width,l=n.angle,u=n.x-a(l)*s*(s>=o/3?1:2),c=n.y-i(l)*s*(s>=o/3?1:2);l=n.angle-Math.PI/2,t.moveTo(u,c),t.lineTo(n.x+a(l)*s,n.y+i(l)*s),t.lineTo(n.x+a(n.angle)*o,n.y+i(n.angle)*o),t.lineTo(n.x-a(l)*s,n.y-i(l)*s),t.lineTo(u,c)},e})(tt);function Ppe(r,e){var t=r.get("center"),n=e.getWidth(),a=e.getHeight(),i=Math.min(n,a),o=me(t[0],e.getWidth()),s=me(t[1],e.getHeight()),l=me(r.get("radius"),i/2);return{cx:o,cy:s,r:l}}function S0(r,e){var t=r==null?"":r+"";return e&&(ye(e)?t=e.replace("{value}",t):Me(e)&&(t=e(r))),t}var jpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){this.group.removeAll();var i=t.get(["axisLine","lineStyle","color"]),o=Ppe(t,a);this._renderMain(t,n,a,i,o),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,n,a,i,o){var s=this.group,l=t.get("clockwise"),u=-t.get("startAngle")/180*Math.PI,c=-t.get("endAngle")/180*Math.PI,f=t.getModel("axisLine"),d=f.get("roundCap"),v=d?u1:nn,g=f.get("show"),y=f.getModel("lineStyle"),x=y.get("width"),b=[u,c];ab(b,!l),u=b[0],c=b[1];for(var w=c-u,T=u,C=[],D=0;g&&D<i.length;D++){var M=Math.min(Math.max(i[D][0],0),1);c=u+w*M;var N=new v({shape:{startAngle:T,endAngle:c,cx:o.cx,cy:o.cy,clockwise:l,r0:o.r-x,r:o.r},silent:!0});N.setStyle({fill:i[D][1]}),N.setStyle(y.getLineStyle(["color","width"])),C.push(N),T=c}C.reverse(),O(C,function(E){return s.add(E)});var R=function(E){if(E<=0)return i[0][1];var k;for(k=0;k<i.length;k++)if(i[k][0]>=E&&(k===0?0:i[k-1][0])<E)return i[k][1];return i[k-1][1]};this._renderTicks(t,n,a,R,o,u,c,l,x),this._renderTitleAndDetail(t,n,a,R,o),this._renderAnchor(t,o),this._renderPointer(t,n,a,R,o,u,c,l,x)},e.prototype._renderTicks=function(t,n,a,i,o,s,l,u,c){for(var f=this.group,d=o.cx,v=o.cy,g=o.r,y=+t.get("min"),x=+t.get("max"),b=t.getModel("splitLine"),w=t.getModel("axisTick"),T=t.getModel("axisLabel"),C=t.get("splitNumber"),D=w.get("splitNumber"),M=me(b.get("length"),g),N=me(w.get("length"),g),R=s,E=(l-s)/C,k=E/D,I=b.getModel("lineStyle").getLineStyle(),B=w.getModel("lineStyle").getLineStyle(),P=b.get("distance"),H,V,j=0;j<=C;j++){if(H=Math.cos(R),V=Math.sin(R),b.get("show")){var U=P?P+c:c,F=new lr({shape:{x1:H*(g-U)+d,y1:V*(g-U)+v,x2:H*(g-M-U)+d,y2:V*(g-M-U)+v},style:I,silent:!0});I.stroke==="auto"&&F.setStyle({stroke:i(j/C)}),f.add(F)}if(T.get("show")){var U=T.get("distance")+P,X=S0(sr(j/C*(x-y)+y),T.get("formatter")),G=i(j/C),W=H*(g-M-U)+d,$=V*(g-M-U)+v,te=T.get("rotate"),ue=0;te==="radial"?(ue=-R+2*Math.PI,ue>Math.PI/2&&(ue+=Math.PI)):te==="tangential"?ue=-R-Math.PI/2:st(te)&&(ue=te*Math.PI/180),ue===0?f.add(new ot({style:Nt(T,{text:X,x:W,y:$,verticalAlign:V<-.8?"top":V>.8?"bottom":"middle",align:H<-.4?"left":H>.4?"right":"center"},{inheritColor:G}),silent:!0})):f.add(new ot({style:Nt(T,{text:X,x:W,y:$,verticalAlign:"middle",align:"center"},{inheritColor:G}),silent:!0,originX:W,originY:$,rotation:ue}))}if(w.get("show")&&j!==C){var U=w.get("distance");U=U?U+c:c;for(var ge=0;ge<=D;ge++){H=Math.cos(R),V=Math.sin(R);var Se=new lr({shape:{x1:H*(g-U)+d,y1:V*(g-U)+v,x2:H*(g-N-U)+d,y2:V*(g-N-U)+v},silent:!0,style:B});B.stroke==="auto"&&Se.setStyle({stroke:i((j+ge/D)/C)}),f.add(Se),R+=k}R-=k}else R+=E}},e.prototype._renderPointer=function(t,n,a,i,o,s,l,u,c){var f=this.group,d=this._data,v=this._progressEls,g=[],y=t.get(["pointer","show"]),x=t.getModel("progress"),b=x.get("show"),w=t.getData(),T=w.mapDimension("value"),C=+t.get("min"),D=+t.get("max"),M=[C,D],N=[s,l];function R(k,I){var B=w.getItemModel(k),P=B.getModel("pointer"),H=me(P.get("width"),o.r),V=me(P.get("length"),o.r),j=t.get(["pointer","icon"]),U=P.get("offsetCenter"),F=me(U[0],o.r),X=me(U[1],o.r),G=P.get("keepAspect"),W;return j?W=ur(j,F-H/2,X-V,H,V,null,G):W=new Ope({shape:{angle:-Math.PI/2,width:H,r:V,x:F,y:X}}),W.rotation=-(I+Math.PI/2),W.x=o.cx,W.y=o.cy,W}function E(k,I){var B=x.get("roundCap"),P=B?u1:nn,H=x.get("overlap"),V=H?x.get("width"):c/w.count(),j=H?o.r-V:o.r-(k+1)*V,U=H?o.r:o.r-k*V,F=new P({shape:{startAngle:s,endAngle:I,cx:o.cx,cy:o.cy,clockwise:u,r0:j,r:U}});return H&&(F.z2=pt(w.get(T,k),[C,D],[100,0],!0)),F}(b||y)&&(w.diff(d).add(function(k){var I=w.get(T,k);if(y){var B=R(k,s);zt(B,{rotation:-((isNaN(+I)?N[0]:pt(I,M,N,!0))+Math.PI/2)},t),f.add(B),w.setItemGraphicEl(k,B)}if(b){var P=E(k,s),H=x.get("clip");zt(P,{shape:{endAngle:pt(I,M,N,H)}},t),f.add(P),OC(t.seriesIndex,w.dataType,k,P),g[k]=P}}).update(function(k,I){var B=w.get(T,k);if(y){var P=d.getItemGraphicEl(I),H=P?P.rotation:s,V=R(k,H);V.rotation=H,lt(V,{rotation:-((isNaN(+B)?N[0]:pt(B,M,N,!0))+Math.PI/2)},t),f.add(V),w.setItemGraphicEl(k,V)}if(b){var j=v[I],U=j?j.shape.endAngle:s,F=E(k,U),X=x.get("clip");lt(F,{shape:{endAngle:pt(B,M,N,X)}},t),f.add(F),OC(t.seriesIndex,w.dataType,k,F),g[k]=F}}).execute(),w.each(function(k){var I=w.getItemModel(k),B=I.getModel("emphasis"),P=B.get("focus"),H=B.get("blurScope"),V=B.get("disabled");if(y){var j=w.getItemGraphicEl(k),U=w.getItemVisual(k,"style"),F=U.fill;if(j instanceof Ir){var X=j.style;j.useStyle(ie({image:X.image,x:X.x,y:X.y,width:X.width,height:X.height},U))}else j.useStyle(U),j.type!=="pointer"&&j.setColor(F);j.setStyle(I.getModel(["pointer","itemStyle"]).getItemStyle()),j.style.fill==="auto"&&j.setStyle("fill",i(pt(w.get(T,k),M,[0,1],!0))),j.z2EmphasisLift=0,_r(j,I),Ut(j,P,H,V)}if(b){var G=g[k];G.useStyle(w.getItemVisual(k,"style")),G.setStyle(I.getModel(["progress","itemStyle"]).getItemStyle()),G.z2EmphasisLift=0,_r(G,I),Ut(G,P,H,V)}}),this._progressEls=g)},e.prototype._renderAnchor=function(t,n){var a=t.getModel("anchor"),i=a.get("show");if(i){var o=a.get("size"),s=a.get("icon"),l=a.get("offsetCenter"),u=a.get("keepAspect"),c=ur(s,n.cx-o/2+me(l[0],n.r),n.cy-o/2+me(l[1],n.r),o,o,null,u);c.z2=a.get("showAbove")?1:0,c.setStyle(a.getModel("itemStyle").getItemStyle()),this.group.add(c)}},e.prototype._renderTitleAndDetail=function(t,n,a,i,o){var s=this,l=t.getData(),u=l.mapDimension("value"),c=+t.get("min"),f=+t.get("max"),d=new Ne,v=[],g=[],y=t.isAnimationEnabled(),x=t.get(["pointer","showAbove"]);l.diff(this._data).add(function(b){v[b]=new ot({silent:!0}),g[b]=new ot({silent:!0})}).update(function(b,w){v[b]=s._titleEls[w],g[b]=s._detailEls[w]}).execute(),l.each(function(b){var w=l.getItemModel(b),T=l.get(u,b),C=new Ne,D=i(pt(T,[c,f],[0,1],!0)),M=w.getModel("title");if(M.get("show")){var N=M.get("offsetCenter"),R=o.cx+me(N[0],o.r),E=o.cy+me(N[1],o.r),k=v[b];k.attr({z2:x?0:2,style:Nt(M,{x:R,y:E,text:l.getName(b),align:"center",verticalAlign:"middle"},{inheritColor:D})}),C.add(k)}var I=w.getModel("detail");if(I.get("show")){var B=I.get("offsetCenter"),P=o.cx+me(B[0],o.r),H=o.cy+me(B[1],o.r),V=me(I.get("width"),o.r),j=me(I.get("height"),o.r),U=t.get(["progress","show"])?l.getItemVisual(b,"style").fill:D,k=g[b],F=I.get("formatter");k.attr({z2:x?0:2,style:Nt(I,{x:P,y:H,text:S0(T,F),width:isNaN(V)?null:V,height:isNaN(j)?null:j,align:"center",verticalAlign:"middle"},{inheritColor:U})}),QH(k,{normal:I},T,function(G){return S0(G,F)}),y&&JH(k,b,l,t,{getFormattedLabel:function(G,W,$,te,ue,ge){return S0(ge?ge.interpolatedValue:T,F)}}),C.add(k)}d.add(C)}),this.group.add(d),this._titleEls=v,this._detailEls=g},e.type="gauge",e})(St),zpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="itemStyle",t}return e.prototype.getInitialData=function(t,n){return gd(this,["value"])},e.type="series.gauge",e.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,ee.color.neutral10]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:ee.color.axisTick,width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:ee.color.axisTickMinor,width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:ee.color.axisLabel,fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:ee.color.neutral00,borderWidth:0,borderColor:ee.color.theme[0]}},title:{show:!0,offsetCenter:[0,"20%"],color:ee.color.secondary,fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:ee.color.transparent,borderWidth:0,borderColor:ee.color.neutral40,width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:ee.color.primary,fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e})(Ct);function Bpe(r){r.registerChartView(jpe),r.registerSeriesModel(zpe)}var Vpe=["itemStyle","opacity"],Gpe=(function(r){K(e,r);function e(t,n){var a=r.call(this)||this,i=a,o=new Ur,s=new ot;return i.setTextContent(s),a.setTextGuideLine(o),a.updateData(t,n,!0),a}return e.prototype.updateData=function(t,n,a){var i=this,o=t.hostModel,s=t.getItemModel(n),l=t.getItemLayout(n),u=s.getModel("emphasis"),c=s.get(Vpe);c=c??1,a||ja(i),i.useStyle(t.getItemVisual(n,"style")),i.style.lineJoin="round",a?(i.setShape({points:l.points}),i.style.opacity=0,zt(i,{style:{opacity:c}},o,n)):lt(i,{style:{opacity:c},shape:{points:l.points}},o,n),_r(i,s),this._updateLabel(t,n),Ut(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,n){var a=this,i=this.getTextGuideLine(),o=a.getTextContent(),s=t.hostModel,l=t.getItemModel(n),u=t.getItemLayout(n),c=u.label,f=t.getItemVisual(n,"style"),d=f.fill;kr(o,Sr(l),{labelFetcher:t.hostModel,labelDataIndex:n,defaultOpacity:f.opacity,defaultText:t.getName(n)},{normal:{align:c.textAlign,verticalAlign:c.verticalAlign}});var v=l.getModel("label"),g=v.get("color"),y=g==="inherit"?d:null;a.setTextConfig({local:!0,inside:!!c.inside,insideStroke:y,outsideFill:y});var x=c.linePoints;i.setShape({points:x}),a.textGuideLineConfig={anchor:x?new Ie(x[0][0],x[0][1]):null},lt(o,{style:{x:c.x,y:c.y}},s,n),o.attr({rotation:c.rotation,originX:c.x,originY:c.y,z2:10}),vN(a,pN(l),{stroke:d})},e})(an),Hpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this._data,s=this.group;i.diff(o).add(function(l){var u=new Gpe(i,l);i.setItemGraphicEl(l,u),s.add(u)}).update(function(l,u){var c=o.getItemGraphicEl(u);c.updateData(i,l),s.add(c),i.setItemGraphicEl(l,c)}).remove(function(l){var u=o.getItemGraphicEl(l);Ho(u,t,l)}).execute(),this._data=i},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.prototype.dispose=function(){},e.type="funnel",e})(St),Fpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new md(xe(this.getData,this),xe(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.getInitialData=function(t,n){return gd(this,{coordDimensions:["value"],encodeDefaulter:He(HD,this)})},e.prototype._defaultLabelLine=function(t){lc(t,"labelLine",["show"]);var n=t.labelLine,a=t.emphasis.labelLine;n.show=n.show&&t.label.show,a.show=a.show&&t.emphasis.label.show},e.prototype.getDataParams=function(t){var n=this.getData(),a=r.prototype.getDataParams.call(this,t),i=n.mapDimension("value"),o=n.getSum(i);return a.percent=o?+(n.get(i,t)/o*100).toFixed(2):0,a.$vars.push("percent"),a},e.type="series.funnel",e.defaultOption={coordinateSystemUsage:"box",z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:65,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:ee.color.neutral00,borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:ee.color.primary}}},e})(Ct);function Upe(r,e){for(var t=r.mapDimension("value"),n=r.mapArray(t,function(l){return l}),a=[],i=e==="ascending",o=0,s=r.count();o<s;o++)a[o]=o;return Me(e)?a.sort(e):e!=="none"&&a.sort(function(l,u){return i?n[l]-n[u]:n[u]-n[l]}),a}function Ype(r){var e=r.hostModel,t=e.get("orient");r.each(function(n){var a=r.getItemModel(n),i=a.getModel("label"),o=i.get("position"),s=a.getModel("labelLine"),l=r.getItemLayout(n),u=l.points,c=o==="inner"||o==="inside"||o==="center"||o==="insideLeft"||o==="insideRight",f,d,v,g;if(c)o==="insideLeft"?(d=(u[0][0]+u[3][0])/2+5,v=(u[0][1]+u[3][1])/2,f="left"):o==="insideRight"?(d=(u[1][0]+u[2][0])/2-5,v=(u[1][1]+u[2][1])/2,f="right"):(d=(u[0][0]+u[1][0]+u[2][0]+u[3][0])/4,v=(u[0][1]+u[1][1]+u[2][1]+u[3][1])/4,f="center"),g=[[d,v],[d,v]];else{var y=void 0,x=void 0,b=void 0,w=void 0,T=s.get("length");o==="left"?(y=(u[3][0]+u[0][0])/2,x=(u[3][1]+u[0][1])/2,b=y-T,d=b-5,f="right"):o==="right"?(y=(u[1][0]+u[2][0])/2,x=(u[1][1]+u[2][1])/2,b=y+T,d=b+5,f="left"):o==="top"?(y=(u[3][0]+u[0][0])/2,x=(u[3][1]+u[0][1])/2,w=x-T,v=w-5,f="center"):o==="bottom"?(y=(u[1][0]+u[2][0])/2,x=(u[1][1]+u[2][1])/2,w=x+T,v=w+5,f="center"):o==="rightTop"?(y=t==="horizontal"?u[3][0]:u[1][0],x=t==="horizontal"?u[3][1]:u[1][1],t==="horizontal"?(w=x-T,v=w-5,f="center"):(b=y+T,d=b+5,f="top")):o==="rightBottom"?(y=u[2][0],x=u[2][1],t==="horizontal"?(w=x+T,v=w+5,f="center"):(b=y+T,d=b+5,f="bottom")):o==="leftTop"?(y=u[0][0],x=t==="horizontal"?u[0][1]:u[1][1],t==="horizontal"?(w=x-T,v=w-5,f="center"):(b=y-T,d=b-5,f="right")):o==="leftBottom"?(y=t==="horizontal"?u[1][0]:u[3][0],x=t==="horizontal"?u[1][1]:u[2][1],t==="horizontal"?(w=x+T,v=w+5,f="center"):(b=y-T,d=b-5,f="right")):(y=(u[1][0]+u[2][0])/2,x=(u[1][1]+u[2][1])/2,t==="horizontal"?(w=x+T,v=w+5,f="center"):(b=y+T,d=b+5,f="left")),t==="horizontal"?(b=y,d=b):(w=x,v=w),g=[[y,x],[b,w]]}l.label={linePoints:g,x:d,y:v,verticalAlign:"middle",textAlign:f,inside:c}})}function Wpe(r,e){r.eachSeriesByType("funnel",function(t){var n=t.getData(),a=n.mapDimension("value"),i=t.get("sort"),o=Cr(t,e),s=Ht(t.getBoxLayoutParams(),o.refContainer),l=t.get("orient"),u=s.width,c=s.height,f=Upe(n,i),d=s.x,v=s.y,g=l==="horizontal"?[me(t.get("minSize"),c),me(t.get("maxSize"),c)]:[me(t.get("minSize"),u),me(t.get("maxSize"),u)],y=n.getDataExtent(a),x=t.get("min"),b=t.get("max");x==null&&(x=Math.min(y[0],0)),b==null&&(b=y[1]);var w=t.get("funnelAlign"),T=t.get("gap"),C=l==="horizontal"?u:c,D=(C-T*(n.count()-1))/n.count(),M=function(V,j){if(l==="horizontal"){var U=n.get(a,V)||0,F=pt(U,[x,b],g,!0),X=void 0;switch(w){case"top":X=v;break;case"center":X=v+(c-F)/2;break;case"bottom":X=v+(c-F);break}return[[j,X],[j,X+F]]}var G=n.get(a,V)||0,W=pt(G,[x,b],g,!0),$;switch(w){case"left":$=d;break;case"center":$=d+(u-W)/2;break;case"right":$=d+u-W;break}return[[$,j],[$+W,j]]};i==="ascending"&&(D=-D,T=-T,l==="horizontal"?d+=u:v+=c,f=f.reverse());for(var N=0;N<f.length;N++){var R=f[N],E=f[N+1],k=n.getItemModel(R);if(l==="horizontal"){var I=k.get(["itemStyle","width"]);I==null?I=D:(I=me(I,u),i==="ascending"&&(I=-I));var B=M(R,d),P=M(E,d+I);d+=I+T,n.setItemLayout(R,{points:B.concat(P.slice().reverse())})}else{var H=k.get(["itemStyle","height"]);H==null?H=D:(H=me(H,c),i==="ascending"&&(H=-H));var B=M(R,v),P=M(E,v+H);v+=H+T,n.setItemLayout(R,{points:B.concat(P.slice().reverse())})}}Ype(n)})}function Xpe(r){r.registerChartView(Hpe),r.registerSeriesModel(Fpe),r.registerLayout(Wpe),r.registerProcessor(pd("funnel"))}var qpe=.3,Zpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._dataGroup=new Ne,t._initialized=!1,t}return e.prototype.init=function(){this.group.add(this._dataGroup)},e.prototype.render=function(t,n,a,i){this._progressiveEls=null;var o=this._dataGroup,s=t.getData(),l=this._data,u=t.coordinateSystem,c=u.dimensions,f=iz(t);s.diff(l).add(d).update(v).remove(g).execute();function d(x){var b=az(s,o,x,c,u);G2(b,s,x,f)}function v(x,b){var w=l.getItemGraphicEl(b),T=ZU(s,x,c,u);s.setItemGraphicEl(x,w),lt(w,{shape:{points:T}},t,x),ja(w),G2(w,s,x,f)}function g(x){var b=l.getItemGraphicEl(x);o.remove(b)}if(!this._initialized){this._initialized=!0;var y=$pe(u,t,function(){setTimeout(function(){o.removeClipPath()})});o.setClipPath(y)}this._data=s},e.prototype.incrementalPrepareRender=function(t,n,a){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},e.prototype.incrementalRender=function(t,n,a){for(var i=n.getData(),o=n.coordinateSystem,s=o.dimensions,l=iz(n),u=this._progressiveEls=[],c=t.start;c<t.end;c++){var f=az(i,this._dataGroup,c,s,o);f.incremental=!0,G2(f,i,c,l),u.push(f)}},e.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},e.type="parallel",e})(St);function $pe(r,e,t){var n=r.model,a=r.getRect(),i=new qe({shape:{x:a.x,y:a.y,width:a.width,height:a.height}}),o=n.get("layout")==="horizontal"?"width":"height";return i.setShape(o,0),zt(i,{shape:{width:a.width,height:a.height}},e,t),i}function ZU(r,e,t,n){for(var a=[],i=0;i<t.length;i++){var o=t[i],s=r.get(r.mapDimension(o),e);Kpe(s,n.getAxis(o).type)||a.push(n.dataToPoint(s,o))}return a}function az(r,e,t,n,a){var i=ZU(r,t,n,a),o=new Ur({shape:{points:i},z2:10});return e.add(o),r.setItemGraphicEl(t,o),o}function iz(r){var e=r.get("smooth",!0);return e===!0&&(e=qpe),e=Xi(e),en(e)&&(e=0),{smooth:e}}function G2(r,e,t,n){r.useStyle(e.getItemVisual(t,"style")),r.style.fill=null,r.setShape("smooth",n.smooth);var a=e.getItemModel(t),i=a.getModel("emphasis");_r(r,a,"lineStyle"),Ut(r,i.get("focus"),i.get("blurScope"),i.get("disabled"))}function Kpe(r,e){return e==="category"?r==null:r==null||isNaN(r)}var Qpe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.getInitialData=function(t,n){return to(null,this,{useEncodeDefaulter:xe(Jpe,null,this)})},e.prototype.getRawIndicesByActiveState=function(t){var n=this.coordinateSystem,a=this.getData(),i=[];return n.eachActiveState(a,function(o,s){t===o&&i.push(a.getRawIndex(s))}),i},e.type="series.parallel",e.dependencies=["parallel"],e.defaultOption={z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:500,smooth:!1,animationEasing:"linear"},e})(Ct);function Jpe(r){var e=r.ecModel.getComponent("parallel",r.get("parallelIndex"));if(e){var t={};return O(e.dimensions,function(n){var a=ege(n);t[n]=a}),t}}function ege(r){return+r.replace("dim","")}var tge=["lineStyle","opacity"],rge={seriesType:"parallel",reset:function(r,e){var t=r.coordinateSystem,n={normal:r.get(["lineStyle","opacity"]),active:r.get("activeOpacity"),inactive:r.get("inactiveOpacity")};return{progress:function(a,i){t.eachActiveState(i,function(o,s){var l=n[o];if(o==="normal"&&i.hasItemOption){var u=i.getItemModel(s).get(tge,!0);u!=null&&(l=u)}var c=i.ensureUniqueItemVisual(s,"style");c.opacity=l},a.start,a.end)}}}};function nge(r){age(r),ige(r)}function age(r){if(!r.parallel){var e=!1;O(r.series,function(t){t&&t.type==="parallel"&&(e=!0)}),e&&(r.parallel=[{}])}}function ige(r){var e=Lt(r.parallelAxis);O(e,function(t){if(Ee(t)){var n=t.parallelIndex||0,a=Lt(r.parallel)[n];a&&a.parallelAxisDefault&&Ye(t,a.parallelAxisDefault,!1)}})}var oge=5,sge=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){this._model=t,this._api=a,this._handlers||(this._handlers={},O(lge,function(i,o){a.getZr().on(o,this._handlers[o]=xe(i,this))},this)),cd(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},e.prototype.dispose=function(t,n){sg(this,"_throttledDispatchExpand"),O(this._handlers,function(a,i){n.getZr().off(i,a)}),this._handlers=null},e.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},e.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(ie({type:"parallelAxisExpand"},t))},e.type="parallel",e})(Rt),lge={mousedown:function(r){H2(this,"click")&&(this._mouseDownPoint=[r.offsetX,r.offsetY])},mouseup:function(r){var e=this._mouseDownPoint;if(H2(this,"click")&&e){var t=[r.offsetX,r.offsetY],n=Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2);if(n>oge)return;var a=this._model.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]);a.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:a.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(r){if(!(this._mouseDownPoint||!H2(this,"mousemove"))){var e=this._model,t=e.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]),n=t.behavior;n==="jump"&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand(n==="none"?null:{axisExpandWindow:t.axisExpandWindow,animation:n==="jump"?null:{duration:0}})}}};function H2(r,e){var t=r._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}var uge=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){r.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var n=this.option;t&&Ye(n,t,!0),this._initDimensions()},e.prototype.contains=function(t,n){var a=t.get("parallelIndex");return a!=null&&n.getComponent("parallel",a)===this},e.prototype.setAxisExpand=function(t){O(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(n){t.hasOwnProperty(n)&&(this.option[n]=t[n])},this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],n=this.parallelAxisIndex=[],a=dt(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(i){return(i.get("parallelIndex")||0)===this.componentIndex},this);O(a,function(i){t.push("dim"+i.get("dim")),n.push(i.componentIndex)})},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e})(Qe),cge=(function(r){K(e,r);function e(t,n,a,i,o){var s=r.call(this,t,n,a)||this;return s.type=i||"value",s.axisIndex=o,s}return e.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},e})(Va);function Tl(r,e,t,n,a,i){r=r||0;var o=t[1]-t[0];if(a!=null&&(a=Of(a,[0,o])),i!=null&&(i=Math.max(i,a??0)),n==="all"){var s=Math.abs(e[1]-e[0]);s=Of(s,[0,o]),a=i=Of(s,[a,i]),n=0}e[0]=Of(e[0],t),e[1]=Of(e[1],t);var l=F2(e,n);e[n]+=r;var u=a||0,c=t.slice();l.sign<0?c[0]+=u:c[1]-=u,e[n]=Of(e[n],c);var f;return f=F2(e,n),a!=null&&(f.sign!==l.sign||f.span<a)&&(e[1-n]=e[n]+l.sign*a),f=F2(e,n),i!=null&&f.span>i&&(e[1-n]=e[n]+f.sign*i),e}function F2(r,e){var t=r[e]-r[1-e];return{span:Math.abs(t),sign:t>0?-1:t<0?1:e?-1:1}}function Of(r,e){return Math.min(e[1]!=null?e[1]:1/0,Math.max(e[0]!=null?e[0]:-1/0,r))}var U2=O,$U=Math.min,KU=Math.max,oz=Math.floor,fge=Math.ceil,sz=sr,hge=Math.PI,dge=(function(){function r(e,t,n){this.type="parallel",this._axesMap=Te(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,n)}return r.prototype._init=function(e,t,n){var a=e.dimensions,i=e.parallelAxisIndex;U2(a,function(o,s){var l=i[s],u=t.getComponent("parallelAxis",l),c=this._axesMap.set(o,new cge(o,Qg(u),[0,0],u.get("type"),l)),f=c.type==="category";c.onBand=f&&u.get("boundaryGap"),c.inverse=u.get("inverse"),u.axis=c,c.model=u,c.coordinateSystem=u.coordinateSystem=this},this)},r.prototype.update=function(e,t){this._updateAxesFromSeries(this._model,e)},r.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),n=t.axisBase,a=t.layoutBase,i=t.pixelDimIndex,o=e[1-i],s=e[i];return o>=n&&o<=n+t.axisLength&&s>=a&&s<=a+t.layoutLength},r.prototype.getModel=function(){return this._model},r.prototype._updateAxesFromSeries=function(e,t){t.eachSeries(function(n){if(e.contains(n,t)){var a=n.getData();U2(this.dimensions,function(i){var o=this._axesMap.get(i);o.scale.unionExtentFromData(a,a.mapDimension(i)),pc(o.scale,o.model)},this)}},this)},r.prototype.resize=function(e,t){var n=Cr(e,t).refContainer;this._rect=Ht(e.getBoxLayoutParams(),n),this._layoutAxes()},r.prototype.getRect=function(){return this._rect},r.prototype._makeLayoutInfo=function(){var e=this._model,t=this._rect,n=["x","y"],a=["width","height"],i=e.get("layout"),o=i==="horizontal"?0:1,s=t[a[o]],l=[0,s],u=this.dimensions.length,c=w0(e.get("axisExpandWidth"),l),f=w0(e.get("axisExpandCount")||0,[0,u]),d=e.get("axisExpandable")&&u>3&&u>f&&f>1&&c>0&&s>0,v=e.get("axisExpandWindow"),g;if(v)g=w0(v[1]-v[0],l),v[1]=v[0]+g;else{g=w0(c*(f-1),l);var y=e.get("axisExpandCenter")||oz(u/2);v=[c*y-g/2],v[1]=v[0]+g}var x=(s-g)/(u-f);x<3&&(x=0);var b=[oz(sz(v[0]/c,1))+1,fge(sz(v[1]/c,1))-1],w=x/c*v[0];return{layout:i,pixelDimIndex:o,layoutBase:t[n[o]],layoutLength:s,axisBase:t[n[1-o]],axisLength:t[a[1-o]],axisExpandable:d,axisExpandWidth:c,axisCollapseWidth:x,axisExpandWindow:v,axisCount:u,winInnerIndices:b,axisExpandWindow0Pos:w}},r.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,n=this.dimensions,a=this._makeLayoutInfo(),i=a.layout;t.each(function(o){var s=[0,a.axisLength],l=o.inverse?1:0;o.setExtent(s[l],s[1-l])}),U2(n,function(o,s){var l=(a.axisExpandable?pge:vge)(s,a),u={horizontal:{x:l.position,y:a.axisLength},vertical:{x:0,y:l.position}},c={horizontal:hge/2,vertical:0},f=[u[i].x+e.x,u[i].y+e.y],d=c[i],v=Rr();ns(v,v,d),ii(v,v,f),this._axesLayout[o]={position:f,rotation:d,transform:v,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},r.prototype.getAxis=function(e){return this._axesMap.get(e)},r.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},r.prototype.eachActiveState=function(e,t,n,a){n==null&&(n=0),a==null&&(a=e.count());var i=this._axesMap,o=this.dimensions,s=[],l=[];O(o,function(x){s.push(e.mapDimension(x)),l.push(i.get(x).model)});for(var u=this.hasAxisBrushed(),c=n;c<a;c++){var f=void 0;if(!u)f="normal";else{f="active";for(var d=e.getValues(s,c),v=0,g=o.length;v<g;v++){var y=l[v].getActiveState(d[v]);if(y==="inactive"){f="inactive";break}}}t(f,c)}},r.prototype.hasAxisBrushed=function(){for(var e=this.dimensions,t=this._axesMap,n=!1,a=0,i=e.length;a<i;a++)t.get(e[a]).model.getActiveState()!=="normal"&&(n=!0);return n},r.prototype.axisCoordToPoint=function(e,t){var n=this._axesLayout[t];return ti([e,0],n.transform)},r.prototype.getAxisLayout=function(e){return De(this._axesLayout[e])},r.prototype.getSlidedAxisExpandWindow=function(e){var t=this._makeLayoutInfo(),n=t.pixelDimIndex,a=t.axisExpandWindow.slice(),i=a[1]-a[0],o=[0,t.axisExpandWidth*(t.axisCount-1)];if(!this.containPoint(e))return{behavior:"none",axisExpandWindow:a};var s=e[n]-t.layoutBase-t.axisExpandWindow0Pos,l,u="slide",c=t.axisCollapseWidth,f=this._model.get("axisExpandSlideTriggerArea"),d=f[0]!=null;if(c)d&&c&&s<i*f[0]?(u="jump",l=s-i*f[2]):d&&c&&s>i*(1-f[0])?(u="jump",l=s-i*(1-f[2])):(l=s-i*f[1])>=0&&(l=s-i*(1-f[1]))<=0&&(l=0),l*=t.axisExpandWidth/c,l?Tl(l,a,o,"all"):u="none";else{var v=a[1]-a[0],g=o[1]*s/v;a=[KU(0,g-v/2)],a[1]=$U(o[1],a[0]+v),a[0]=a[1]-v}return{axisExpandWindow:a,behavior:u}},r})();function w0(r,e){return $U(KU(r,e[0]),e[1])}function vge(r,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*r,axisNameAvailableWidth:t,axisLabelShow:!0}}function pge(r,e){var t=e.layoutLength,n=e.axisExpandWidth,a=e.axisCount,i=e.axisCollapseWidth,o=e.winInnerIndices,s,l=i,u=!1,c;return r<o[0]?(s=r*i,c=i):r<=o[1]?(s=e.axisExpandWindow0Pos+r*n-e.axisExpandWindow[0],l=n,u=!0):(s=t-(a-1-r)*i,c=i),{position:s,axisNameAvailableWidth:l,axisLabelShow:u,nameTruncateMaxWidth:c}}function gge(r,e){var t=[];return r.eachComponent("parallel",function(n,a){var i=new dge(n,r,e);i.name="parallel_"+a,i.resize(n,e),n.coordinateSystem=i,i.model=n,t.push(i)}),r.eachSeries(function(n){if(n.get("coordinateSystem")==="parallel"){var a=n.getReferringComponents("parallel",Zt).models[0];n.coordinateSystem=a.coordinateSystem}}),t}var mge={create:gge},VA=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.activeIntervals=[],t}return e.prototype.getAreaSelectStyle=function(){return cc([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},e.prototype.setActiveIntervals=function(t){var n=this.activeIntervals=De(t);if(n)for(var a=n.length-1;a>=0;a--)na(n[a])},e.prototype.getActiveState=function(t){var n=this.activeIntervals;if(!n.length)return"normal";if(t==null||isNaN(+t))return"inactive";if(n.length===1){var a=n[0];if(a[0]<=t&&t<=a[1])return"active"}else for(var i=0,o=n.length;i<o;i++)if(n[i][0]<=t&&t<=n[i][1])return"active";return"inactive"},e})(Qe);Jt(VA,vd);var gc=!0,_g=Math.min,Uh=Math.max,yge=Math.pow,xge=1e4,bge=6,_ge=6,lz="globalPan",Sge={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},wge={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},uz={brushStyle:{lineWidth:2,stroke:ee.color.backgroundTint,fill:ee.color.borderTint},transformable:!0,brushMode:"single",removeOnClick:!1},Tge=0,HN=(function(r){K(e,r);function e(t){var n=r.call(this)||this;return n._track=[],n._covers=[],n._handlers={},n._zr=t,n.group=new Ne,n._uid="brushController_"+Tge++,O(Rge,function(a,i){this._handlers[i]=xe(a,this)},n),n}return e.prototype.enableBrush=function(t){return this._brushType&&this._doDisableBrush(),t.brushType&&this._doEnableBrush(t),this},e.prototype._doEnableBrush=function(t){var n=this._zr;this._enableGlobalPan||sde(n,lz,this._uid),O(this._handlers,function(a,i){n.on(i,a)}),this._brushType=t.brushType,this._brushOption=Ye(De(uz),t,!0)},e.prototype._doDisableBrush=function(){var t=this._zr;lde(t,lz,this._uid),O(this._handlers,function(n,a){t.off(a,n)}),this._brushType=this._brushOption=null},e.prototype.setPanels=function(t){if(t&&t.length){var n=this._panels={};O(t,function(a){n[a.panelId]=De(a)})}else this._panels=null;return this},e.prototype.mount=function(t){t=t||{},this._enableGlobalPan=t.enableGlobalPan;var n=this.group;return this._zr.add(n),n.attr({x:t.x||0,y:t.y||0,rotation:t.rotation||0,scaleX:t.scaleX||1,scaleY:t.scaleY||1}),this._transform=n.getLocalTransform(),this},e.prototype.updateCovers=function(t){t=fe(t,function(d){return Ye(De(uz),d,!0)});var n="\0-brush-index-",a=this._covers,i=this._covers=[],o=this,s=this._creatingCover;return new Qo(a,t,u,l).add(c).update(c).remove(f).execute(),this;function l(d,v){return(d.id!=null?d.id:n+v)+"-"+d.brushType}function u(d,v){return l(d.__brushOption,v)}function c(d,v){var g=t[d];if(v!=null&&a[v]===s)i[d]=a[v];else{var y=i[d]=v!=null?(a[v].__brushOption=g,a[v]):JU(o,QU(o,g));FN(o,y)}}function f(d){a[d]!==s&&o.group.remove(a[d])}},e.prototype.unmount=function(){return this.enableBrush(!1),GA(this),this._zr.remove(this.group),this},e.prototype.dispose=function(){this.unmount(),this.off()},e})(za);function QU(r,e){var t=Ab[e.brushType].createCover(r,e);return t.__brushOption=e,t9(t,e),r.group.add(t),t}function JU(r,e){var t=UN(e);return t.endCreating&&(t.endCreating(r,e),t9(e,e.__brushOption)),e}function e9(r,e){var t=e.__brushOption;UN(e).updateCoverShape(r,e,t.range,t)}function t9(r,e){var t=e.z;t==null&&(t=xge),r.traverse(function(n){n.z=t,n.z2=t})}function FN(r,e){UN(e).updateCommon(r,e),e9(r,e)}function UN(r){return Ab[r.__brushOption.brushType]}function YN(r,e,t){var n=r._panels;if(!n)return gc;var a,i=r._transform;return O(n,function(o){o.isTargetByCursor(e,t,i)&&(a=o)}),a}function r9(r,e){var t=r._panels;if(!t)return gc;var n=e.__brushOption.panelId;return n!=null?t[n]:gc}function GA(r){var e=r._covers,t=e.length;return O(e,function(n){r.group.remove(n)},r),e.length=0,!!t}function mc(r,e){var t=fe(r._covers,function(n){var a=n.__brushOption,i=De(a.range);return{brushType:a.brushType,panelId:a.panelId,range:i}});r.trigger("brush",{areas:t,isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function Cge(r){var e=r._track;if(!e.length)return!1;var t=e[e.length-1],n=e[0],a=t[0]-n[0],i=t[1]-n[1],o=yge(a*a+i*i,.5);return o>bge}function n9(r){var e=r.length-1;return e<0&&(e=0),[r[0],r[e]]}function a9(r,e,t,n){var a=new Ne;return a.add(new qe({name:"main",style:WN(t),silent:!0,draggable:!0,cursor:"move",drift:He(cz,r,e,a,["n","s","w","e"]),ondragend:He(mc,e,{isEnd:!0})})),O(n,function(i){a.add(new qe({name:i.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:He(cz,r,e,a,i),ondragend:He(mc,e,{isEnd:!0})}))}),a}function i9(r,e,t,n){var a=n.brushStyle.lineWidth||0,i=Uh(a,_ge),o=t[0][0],s=t[1][0],l=o-a/2,u=s-a/2,c=t[0][1],f=t[1][1],d=c-i+a/2,v=f-i+a/2,g=c-o,y=f-s,x=g+a,b=y+a;wo(r,e,"main",o,s,g,y),n.transformable&&(wo(r,e,"w",l,u,i,b),wo(r,e,"e",d,u,i,b),wo(r,e,"n",l,u,x,i),wo(r,e,"s",l,v,x,i),wo(r,e,"nw",l,u,i,i),wo(r,e,"ne",d,u,i,i),wo(r,e,"sw",l,v,i,i),wo(r,e,"se",d,v,i,i))}function HA(r,e){var t=e.__brushOption,n=t.transformable,a=e.childAt(0);a.useStyle(WN(t)),a.attr({silent:!n,cursor:n?"move":"default"}),O([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(i){var o=e.childOfName(i.join("")),s=i.length===1?FA(r,i[0]):Mge(r,i);o&&o.attr({silent:!n,invisible:!n,cursor:n?wge[s]+"-resize":null})})}function wo(r,e,t,n,a,i,o){var s=e.childOfName(t);s&&s.setShape(Nge(XN(r,e,[[n,a],[n+i,a+o]])))}function WN(r){return Re({strokeNoScale:!0},r.brushStyle)}function o9(r,e,t,n){var a=[_g(r,t),_g(e,n)],i=[Uh(r,t),Uh(e,n)];return[[a[0],i[0]],[a[1],i[1]]]}function Age(r){return dl(r.group)}function FA(r,e){var t={w:"left",e:"right",n:"top",s:"bottom"},n={left:"w",right:"e",top:"n",bottom:"s"},a=lb(t[e],Age(r));return n[a]}function Mge(r,e){var t=[FA(r,e[0]),FA(r,e[1])];return(t[0]==="e"||t[0]==="w")&&t.reverse(),t.join("")}function cz(r,e,t,n,a,i){var o=t.__brushOption,s=r.toRectRange(o.range),l=s9(e,a,i);O(n,function(u){var c=Sge[u];s[c[0]][c[1]]+=l[c[0]]}),o.range=r.fromRectRange(o9(s[0][0],s[1][0],s[0][1],s[1][1])),FN(e,t),mc(e,{isEnd:!1})}function Dge(r,e,t,n){var a=e.__brushOption.range,i=s9(r,t,n);O(a,function(o){o[0]+=i[0],o[1]+=i[1]}),FN(r,e),mc(r,{isEnd:!1})}function s9(r,e,t){var n=r.group,a=n.transformCoordToLocal(e,t),i=n.transformCoordToLocal(0,0);return[a[0]-i[0],a[1]-i[1]]}function XN(r,e,t){var n=r9(r,e);return n&&n!==gc?n.clipPath(t,r._transform):De(t)}function Nge(r){var e=_g(r[0][0],r[1][0]),t=_g(r[0][1],r[1][1]),n=Uh(r[0][0],r[1][0]),a=Uh(r[0][1],r[1][1]);return{x:e,y:t,width:n-e,height:a-t}}function Lge(r,e,t){if(!(!r._brushType||Ege(r,e.offsetX,e.offsetY))){var n=r._zr,a=r._covers,i=YN(r,e,t);if(!r._dragging)for(var o=0;o<a.length;o++){var s=a[o].__brushOption;if(i&&(i===gc||s.panelId===i.panelId)&&Ab[s.brushType].contain(a[o],t[0],t[1]))return}i&&n.setCursorStyle("crosshair")}}function UA(r){var e=r.event;e.preventDefault&&e.preventDefault()}function YA(r,e,t){return r.childOfName("main").contain(e,t)}function l9(r,e,t,n){var a=r._creatingCover,i=r._creatingPanel,o=r._brushOption,s;if(r._track.push(t.slice()),Cge(r)||a){if(i&&!a){o.brushMode==="single"&&GA(r);var l=De(o);l.brushType=fz(l.brushType,i),l.panelId=i===gc?null:i.panelId,a=r._creatingCover=QU(r,l),r._covers.push(a)}if(a){var u=Ab[fz(r._brushType,i)],c=a.__brushOption;c.range=u.getCreatingRange(XN(r,a,r._track)),n&&(JU(r,a),u.updateCommon(r,a)),e9(r,a),s={isEnd:n}}}else n&&o.brushMode==="single"&&o.removeOnClick&&YN(r,e,t)&&GA(r)&&(s={isEnd:n,removeOnClick:!0});return s}function fz(r,e){return r==="auto"?e.defaultBrushType:r}var Rge={mousedown:function(r){if(this._dragging)hz(this,r);else if(!r.target||!r.target.draggable){UA(r);var e=this.group.transformCoordToLocal(r.offsetX,r.offsetY);this._creatingCover=null;var t=this._creatingPanel=YN(this,r,e);t&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(r){var e=r.offsetX,t=r.offsetY,n=this.group.transformCoordToLocal(e,t);if(Lge(this,r,n),this._dragging){UA(r);var a=l9(this,r,n,!1);a&&mc(this,a)}},mouseup:function(r){hz(this,r)}};function hz(r,e){if(r._dragging){UA(e);var t=e.offsetX,n=e.offsetY,a=r.group.transformCoordToLocal(t,n),i=l9(r,e,a,!0);r._dragging=!1,r._track=[],r._creatingCover=null,i&&mc(r,i)}}function Ege(r,e,t){var n=r._zr;return e<0||e>n.getWidth()||t<0||t>n.getHeight()}var Ab={lineX:dz(0),lineY:dz(1),rect:{createCover:function(r,e){function t(n){return n}return a9({toRectRange:t,fromRectRange:t},r,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var e=n9(r);return o9(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(r,e,t,n){i9(r,e,t,n)},updateCommon:HA,contain:YA},polygon:{createCover:function(r,e){var t=new Ne;return t.add(new Ur({name:"main",style:WN(e),silent:!0})),t},getCreatingRange:function(r){return r},endCreating:function(r,e){e.remove(e.childAt(0)),e.add(new an({name:"main",draggable:!0,drift:He(Dge,r,e),ondragend:He(mc,r,{isEnd:!0})}))},updateCoverShape:function(r,e,t,n){e.childAt(0).setShape({points:XN(r,e,t)})},updateCommon:HA,contain:YA}};function dz(r){return{createCover:function(e,t){return a9({toRectRange:function(n){var a=[n,[0,100]];return r&&a.reverse(),a},fromRectRange:function(n){return n[r]}},e,t,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(e){var t=n9(e),n=_g(t[0][r],t[1][r]),a=Uh(t[0][r],t[1][r]);return[n,a]},updateCoverShape:function(e,t,n,a){var i,o=r9(e,t);if(o!==gc&&o.getLinearBrushOtherExtent)i=o.getLinearBrushOtherExtent(r);else{var s=e._zr;i=[0,[s.getWidth(),s.getHeight()][1-r]]}var l=[n,i];r&&l.reverse(),i9(e,t,l,a)},updateCommon:HA,contain:YA}}function u9(r){return r=qN(r),function(e){return wD(e,r)}}function c9(r,e){return r=qN(r),function(t){var n=e??t,a=n?r.width:r.height,i=n?r.x:r.y;return[i,i+(a||0)]}}function f9(r,e,t){var n=qN(r);return function(a,i){return n.contain(i[0],i[1])&&!gU(a,e,t)}}function qN(r){return Oe.create(r)}var kge=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){r.prototype.init.apply(this,arguments),(this._brushController=new HN(n.getZr())).on("brush",xe(this._onBrush,this))},e.prototype.render=function(t,n,a,i){if(!Ige(t,n,i)){this.axisModel=t,this.api=a,this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new Ne,this.group.add(this._axisGroup),!!t.get("show")){var s=Pge(t,n),l=s.coordinateSystem,u=t.getAreaSelectStyle(),c=u.width,f=t.axis.dim,d=l.getAxisLayout(f),v=ie({strokeContainThreshold:c},d),g=new wn(t,a,v);g.build(),this._axisGroup.add(g.group),this._refreshBrushController(v,u,t,s,c,a),qg(o,this._axisGroup,t)}}},e.prototype._refreshBrushController=function(t,n,a,i,o,s){var l=a.axis.getExtent(),u=l[1]-l[0],c=Math.min(30,Math.abs(u)*.1),f=Oe.create({x:l[0],y:-o/2,width:u,height:o});f.x-=c,f.width+=2*c,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:u9(f),isTargetByCursor:f9(f,s,i),getLinearBrushOtherExtent:c9(f,0)}]).enableBrush({brushType:"lineX",brushStyle:n,removeOnClick:!0}).updateCovers(Oge(a))},e.prototype._onBrush=function(t){var n=t.areas,a=this.axisModel,i=a.axis,o=fe(n,function(s){return[i.coordToData(s.range[0],!0),i.coordToData(s.range[1],!0)]});(!a.option.realtime===t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:a.id,intervals:o})},e.prototype.dispose=function(){this._brushController.dispose()},e.type="parallelAxis",e})(Rt);function Ige(r,e,t){return t&&t.type==="axisAreaSelect"&&e.findComponents({mainType:"parallelAxis",query:t})[0]===r}function Oge(r){var e=r.axis;return fe(r.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[e.dataToCoord(t[0],!0),e.dataToCoord(t[1],!0)]}})}function Pge(r,e){return e.getComponent("parallel",r.get("parallelIndex"))}var jge={type:"axisAreaSelect",event:"axisAreaSelected"};function zge(r){r.registerAction(jge,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(n){n.axis.model.setActiveIntervals(e.intervals)})}),r.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(n){n.setAxisExpand(e)})})}var Bge={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function h9(r){r.registerComponentView(sge),r.registerComponentModel(uge),r.registerCoordinateSystem("parallel",mge),r.registerPreprocessor(nge),r.registerComponentModel(VA),r.registerComponentView(kge),Hh(r,"parallel",VA,Bge),zge(r)}function Vge(r){We(h9),r.registerChartView(Zpe),r.registerSeriesModel(Qpe),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,rge)}var Gge=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0}return r})(),Hge=(function(r){K(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new Gge},e.prototype.buildPath=function(t,n){var a=n.extent;t.moveTo(n.x1,n.y1),t.bezierCurveTo(n.cpx1,n.cpy1,n.cpx2,n.cpy2,n.x2,n.y2),n.orient==="vertical"?(t.lineTo(n.x2+a,n.y2),t.bezierCurveTo(n.cpx2+a,n.cpy2,n.cpx1+a,n.cpy1,n.x1+a,n.y1)):(t.lineTo(n.x2,n.y2+a),t.bezierCurveTo(n.cpx2,n.cpy2+a,n.cpx1,n.cpy1+a,n.x1,n.y1+a)),t.closePath()},e.prototype.highlight=function(){$o(this)},e.prototype.downplay=function(){Ko(this)},e})(tt),Fge=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._mainGroup=new Ne,t._focusAdjacencyDisabled=!1,t}return e.prototype.init=function(t,n){this._controller=new Ac(n.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},e.prototype.render=function(t,n,a){var i=this,o=t.getGraph(),s=this._mainGroup,l=t.layoutInfo,u=l.width,c=l.height,f=t.getData(),d=t.getData("edge"),v=t.get("orient");this._model=t,s.removeAll(),s.x=l.x,s.y=l.y,this._updateViewCoordSys(t,a),mU(t,a,s,this._controller,this._controllerHost,null),o.eachEdge(function(g){var y=new Hge,x=je(y);x.dataIndex=g.dataIndex,x.seriesIndex=t.seriesIndex,x.dataType="edge";var b=g.getModel(),w=b.getModel("lineStyle"),T=w.get("curveness"),C=g.node1.getLayout(),D=g.node1.getModel(),M=D.get("localX"),N=D.get("localY"),R=g.node2.getLayout(),E=g.node2.getModel(),k=E.get("localX"),I=E.get("localY"),B=g.getLayout(),P,H,V,j,U,F,X,G;y.shape.extent=Math.max(1,B.dy),y.shape.orient=v,v==="vertical"?(P=(M!=null?M*u:C.x)+B.sy,H=(N!=null?N*c:C.y)+C.dy,V=(k!=null?k*u:R.x)+B.ty,j=I!=null?I*c:R.y,U=P,F=H*(1-T)+j*T,X=V,G=H*T+j*(1-T)):(P=(M!=null?M*u:C.x)+C.dx,H=(N!=null?N*c:C.y)+B.sy,V=k!=null?k*u:R.x,j=(I!=null?I*c:R.y)+B.ty,U=P*(1-T)+V*T,F=H,X=P*T+V*(1-T),G=j),y.setShape({x1:P,y1:H,x2:V,y2:j,cpx1:U,cpy1:F,cpx2:X,cpy2:G}),y.useStyle(w.getItemStyle()),vz(y.style,v,g);var W=""+b.get("value"),$=Sr(b,"edgeLabel");kr(y,$,{labelFetcher:{getFormattedLabel:function(ge,Se,Xe,be,we,ze){return t.getFormattedLabel(ge,Se,"edge",be,zn(we,$.normal&&$.normal.get("formatter"),W),ze)}},labelDataIndex:g.dataIndex,defaultText:W}),y.setTextConfig({position:"inside"});var te=b.getModel("emphasis");_r(y,b,"lineStyle",function(ge){var Se=ge.getItemStyle();return vz(Se,v,g),Se}),s.add(y),d.setItemGraphicEl(g.dataIndex,y);var ue=te.get("focus");Ut(y,ue==="adjacency"?g.getAdjacentDataIndices():ue==="trajectory"?g.getTrajectoryDataIndices():ue,te.get("blurScope"),te.get("disabled"))}),o.eachNode(function(g){var y=g.getLayout(),x=g.getModel(),b=x.get("localX"),w=x.get("localY"),T=x.getModel("emphasis"),C=x.get(["itemStyle","borderRadius"])||0,D=new qe({shape:{x:b!=null?b*u:y.x,y:w!=null?w*c:y.y,width:y.dx,height:y.dy,r:C},style:x.getModel("itemStyle").getItemStyle(),z2:10});kr(D,Sr(x),{labelFetcher:{getFormattedLabel:function(N,R){return t.getFormattedLabel(N,R,"node")}},labelDataIndex:g.dataIndex,defaultText:g.id}),D.disableLabelAnimation=!0,D.setStyle("fill",g.getVisual("color")),D.setStyle("decal",g.getVisual("style").decal),_r(D,x),s.add(D),f.setItemGraphicEl(g.dataIndex,D),je(D).dataType="node";var M=T.get("focus");Ut(D,M==="adjacency"?g.getAdjacentDataIndices():M==="trajectory"?g.getTrajectoryDataIndices():M,T.get("blurScope"),T.get("disabled"))}),f.eachItemGraphicEl(function(g,y){var x=f.getItemModel(y);x.get("draggable")&&(g.drift=function(b,w){i._focusAdjacencyDisabled=!0,this.shape.x+=b,this.shape.y+=w,this.dirty(),a.dispatchAction({type:"dragNode",seriesId:t.id,dataIndex:f.getRawIndex(y),localX:this.shape.x/u,localY:this.shape.y/c})},g.ondragend=function(){i._focusAdjacencyDisabled=!1},g.draggable=!0,g.cursor="move")}),!this._data&&t.isAnimationEnabled()&&s.setClipPath(Uge(s.getBoundingRect(),t,function(){s.removeClipPath()})),this._data=t.getData()},e.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype._updateViewCoordSys=function(t,n){var a=t.layoutInfo,i=a.width,o=a.height,s=t.coordinateSystem=new Mc(null,{api:n,ecModel:t.ecModel});s.zoomLimit=t.get("scaleLimit"),s.setBoundingRect(0,0,i,o),s.setCenter(t.get("center")),s.setZoom(t.get("zoom")),this._controllerHost.target.attr({x:s.x,y:s.y,scaleX:s.scaleX,scaleY:s.scaleY})},e.type="sankey",e})(St);function vz(r,e,t){switch(r.fill){case"source":r.fill=t.node1.getVisual("color"),r.decal=t.node1.getVisual("style").decal;break;case"target":r.fill=t.node2.getVisual("color"),r.decal=t.node2.getVisual("style").decal;break;case"gradient":var n=t.node1.getVisual("color"),a=t.node2.getVisual("color");ye(n)&&ye(a)&&(r.fill=new bc(0,0,+(e==="horizontal"),+(e==="vertical"),[{color:n,offset:0},{color:a,offset:1}]))}}function Uge(r,e,t){var n=new qe({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return zt(n,{shape:{width:r.width+20}},e,t),n}var Yge=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,n){var a=t.edges||t.links||[],i=t.data||t.nodes||[],o=t.levels||[];this.levelModels=[];for(var s=this.levelModels,l=0;l<o.length;l++)o[l].depth!=null&&o[l].depth>=0&&(s[o[l].depth]=new et(o[l],this,n));var u=GN(i,a,this,!0,c);return u.data;function c(f,d){f.wrapMethod("getItemModel",function(v,g){var y=v.parentModel,x=y.getData().getItemLayout(g);if(x){var b=x.depth,w=y.levelModels[b];w&&(v.parentModel=w)}return v}),d.wrapMethod("getItemModel",function(v,g){var y=v.parentModel,x=y.getGraph().getEdgeByIndex(g),b=x.node1.getLayout();if(b){var w=b.depth,T=y.levelModels[w];T&&(v.parentModel=T)}return v})}},e.prototype.setNodePosition=function(t,n){var a=this.option.data||this.option.nodes,i=a[t];i.localX=n[0],i.localY=n[1]},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,n,a){function i(v){return isNaN(v)||v==null}if(a==="edge"){var o=this.getDataParams(t,a),s=o.data,l=o.value,u=s.source+" -- "+s.target;return pr("nameValue",{name:u,value:l,noValue:i(l)})}else{var c=this.getGraph().getNodeByIndex(t),f=c.getLayout().value,d=this.getDataParams(t,a).data.name;return pr("nameValue",{name:d!=null?d+"":null,value:f,noValue:i(f)})}},e.prototype.optionUpdated=function(){},e.prototype.getDataParams=function(t,n){var a=r.prototype.getDataParams.call(this,t,n);if(a.value==null&&n==="node"){var i=this.getGraph().getNodeByIndex(t),o=i.getLayout().value;a.value=o}return a},e.type="series.sankey",e.layoutMode="box",e.defaultOption={z:2,coordinateSystemUsage:"box",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,roam:!1,roamTrigger:"global",center:null,zoom:1,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:ee.color.neutral50,opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:ee.color.primary}},animationEasing:"linear",animationDuration:1e3},e})(Ct);function Wge(r,e){r.eachSeriesByType("sankey",function(t){var n=t.get("nodeWidth"),a=t.get("nodeGap"),i=Cr(t,e).refContainer,o=Ht(t.getBoxLayoutParams(),i);t.layoutInfo=o;var s=o.width,l=o.height,u=t.getGraph(),c=u.nodes,f=u.edges;qge(c);var d=dt(c,function(x){return x.getLayout().value===0}),v=d.length!==0?0:t.get("layoutIterations"),g=t.get("orient"),y=t.get("nodeAlign");Xge(c,f,n,a,s,l,v,g,y)})}function Xge(r,e,t,n,a,i,o,s,l){Zge(r,e,t,a,i,s,l),Jge(r,e,i,a,n,o,s),lme(r,s)}function qge(r){O(r,function(e){var t=gl(e.outEdges,m1),n=gl(e.inEdges,m1),a=e.getValue()||0,i=Math.max(t,n,a);e.setLayout({value:i},!0)})}function Zge(r,e,t,n,a,i,o){for(var s=[],l=[],u=[],c=[],f=0,d=0;d<e.length;d++)s[d]=1;for(var d=0;d<r.length;d++)l[d]=r[d].inEdges.length,l[d]===0&&u.push(r[d]);for(var v=-1;u.length;){for(var g=0;g<u.length;g++){var y=u[g],x=y.hostGraph.data.getRawDataItem(y.dataIndex),b=x.depth!=null&&x.depth>=0;b&&x.depth>v&&(v=x.depth),y.setLayout({depth:b?x.depth:f},!0),i==="vertical"?y.setLayout({dy:t},!0):y.setLayout({dx:t},!0);for(var w=0;w<y.outEdges.length;w++){var T=y.outEdges[w],C=e.indexOf(T);s[C]=0;var D=T.node2,M=r.indexOf(D);--l[M]===0&&c.indexOf(D)<0&&c.push(D)}}++f,u=c,c=[]}for(var d=0;d<s.length;d++)if(s[d]===1)throw new Error("Sankey is a DAG, the original data has cycle!");var N=v>f-1?v:f-1;o&&o!=="left"&&$ge(r,o,i,N);var R=i==="vertical"?(a-t)/N:(n-t)/N;Qge(r,R,i)}function d9(r){var e=r.hostGraph.data.getRawDataItem(r.dataIndex);return e.depth!=null&&e.depth>=0}function $ge(r,e,t,n){if(e==="right"){for(var a=[],i=r,o=0;i.length;){for(var s=0;s<i.length;s++){var l=i[s];l.setLayout({skNodeHeight:o},!0);for(var u=0;u<l.inEdges.length;u++){var c=l.inEdges[u];a.indexOf(c.node1)<0&&a.push(c.node1)}}i=a,a=[],++o}O(r,function(f){d9(f)||f.setLayout({depth:Math.max(0,n-f.getLayout().skNodeHeight)},!0)})}else e==="justify"&&Kge(r,n)}function Kge(r,e){O(r,function(t){!d9(t)&&!t.outEdges.length&&t.setLayout({depth:e},!0)})}function Qge(r,e,t){O(r,function(n){var a=n.getLayout().depth*e;t==="vertical"?n.setLayout({y:a},!0):n.setLayout({x:a},!0)})}function Jge(r,e,t,n,a,i,o){var s=eme(r,o);tme(s,e,t,n,a,o),Y2(s,a,t,n,o);for(var l=1;i>0;i--)l*=.99,rme(s,l,o),Y2(s,a,t,n,o),sme(s,l,o),Y2(s,a,t,n,o)}function eme(r,e){var t=[],n=e==="vertical"?"y":"x",a=LC(r,function(i){return i.getLayout()[n]});return a.keys.sort(function(i,o){return i-o}),O(a.keys,function(i){t.push(a.buckets.get(i))}),t}function tme(r,e,t,n,a,i){var o=1/0;O(r,function(s){var l=s.length,u=0;O(s,function(f){u+=f.getLayout().value});var c=i==="vertical"?(n-(l-1)*a)/u:(t-(l-1)*a)/u;c<o&&(o=c)}),O(r,function(s){O(s,function(l,u){var c=l.getLayout().value*o;i==="vertical"?(l.setLayout({x:u},!0),l.setLayout({dx:c},!0)):(l.setLayout({y:u},!0),l.setLayout({dy:c},!0))})}),O(e,function(s){var l=+s.getValue()*o;s.setLayout({dy:l},!0)})}function Y2(r,e,t,n,a){var i=a==="vertical"?"x":"y";O(r,function(o){o.sort(function(y,x){return y.getLayout()[i]-x.getLayout()[i]});for(var s,l,u,c=0,f=o.length,d=a==="vertical"?"dx":"dy",v=0;v<f;v++)l=o[v],u=c-l.getLayout()[i],u>0&&(s=l.getLayout()[i]+u,a==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),c=l.getLayout()[i]+l.getLayout()[d]+e;var g=a==="vertical"?n:t;if(u=c-e-g,u>0){s=l.getLayout()[i]-u,a==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0),c=s;for(var v=f-2;v>=0;--v)l=o[v],u=l.getLayout()[i]+l.getLayout()[d]+e-c,u>0&&(s=l.getLayout()[i]-u,a==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),c=l.getLayout()[i]}})}function rme(r,e,t){O(r.slice().reverse(),function(n){O(n,function(a){if(a.outEdges.length){var i=gl(a.outEdges,nme,t)/gl(a.outEdges,m1);if(isNaN(i)){var o=a.outEdges.length;i=o?gl(a.outEdges,ame,t)/o:0}if(t==="vertical"){var s=a.getLayout().x+(i-Cl(a,t))*e;a.setLayout({x:s},!0)}else{var l=a.getLayout().y+(i-Cl(a,t))*e;a.setLayout({y:l},!0)}}})})}function nme(r,e){return Cl(r.node2,e)*r.getValue()}function ame(r,e){return Cl(r.node2,e)}function ime(r,e){return Cl(r.node1,e)*r.getValue()}function ome(r,e){return Cl(r.node1,e)}function Cl(r,e){return e==="vertical"?r.getLayout().x+r.getLayout().dx/2:r.getLayout().y+r.getLayout().dy/2}function m1(r){return r.getValue()}function gl(r,e,t){for(var n=0,a=r.length,i=-1;++i<a;){var o=+e(r[i],t);isNaN(o)||(n+=o)}return n}function sme(r,e,t){O(r,function(n){O(n,function(a){if(a.inEdges.length){var i=gl(a.inEdges,ime,t)/gl(a.inEdges,m1);if(isNaN(i)){var o=a.inEdges.length;i=o?gl(a.inEdges,ome,t)/o:0}if(t==="vertical"){var s=a.getLayout().x+(i-Cl(a,t))*e;a.setLayout({x:s},!0)}else{var l=a.getLayout().y+(i-Cl(a,t))*e;a.setLayout({y:l},!0)}}})})}function lme(r,e){var t=e==="vertical"?"x":"y";O(r,function(n){n.outEdges.sort(function(a,i){return a.node2.getLayout()[t]-i.node2.getLayout()[t]}),n.inEdges.sort(function(a,i){return a.node1.getLayout()[t]-i.node1.getLayout()[t]})}),O(r,function(n){var a=0,i=0;O(n.outEdges,function(o){o.setLayout({sy:a},!0),a+=o.getLayout().dy}),O(n.inEdges,function(o){o.setLayout({ty:i},!0),i+=o.getLayout().dy})})}function ume(r){r.eachSeriesByType("sankey",function(e){var t=e.getGraph(),n=t.nodes,a=t.edges;if(n.length){var i=1/0,o=-1/0;O(n,function(s){var l=s.getLayout().value;l<i&&(i=l),l>o&&(o=l)}),O(n,function(s){var l=new Er({type:"color",mappingMethod:"linear",dataExtent:[i,o],visual:e.get("color")}),u=l.mapValueToVisual(s.getLayout().value),c=s.getModel().get(["itemStyle","color"]);c!=null?(s.setVisual("color",c),s.setVisual("style",{fill:c})):(s.setVisual("color",u),s.setVisual("style",{fill:u}))})}a.length&&O(a,function(s){var l=s.getModel().get("lineStyle");s.setVisual("style",l)})})}function cme(r){r.registerChartView(Fge),r.registerSeriesModel(Yge),r.registerLayout(Wge),r.registerVisual(ume),r.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"sankey",query:e},function(n){n.setNodePosition(e.dataIndex,[e.localX,e.localY])})}),r.registerAction({type:"sankeyRoam",event:"sankeyRoam",update:"none"},function(e,t,n){t.eachComponent({mainType:"series",subType:"sankey",query:e},function(a){var i=a.coordinateSystem,o=Sb(i,e,a.get("scaleLimit"));a.setCenter(o.center),a.setZoom(o.zoom)})})}var v9=(function(){function r(){}return r.prototype._hasEncodeRule=function(e){var t=this.getEncode();return t&&t.get(e)!=null},r.prototype.getInitialData=function(e,t){var n,a=t.getComponent("xAxis",this.get("xAxisIndex")),i=t.getComponent("yAxis",this.get("yAxisIndex")),o=a.get("type"),s=i.get("type"),l;o==="category"?(e.layout="horizontal",n=a.getOrdinalMeta(),l=!this._hasEncodeRule("x")):s==="category"?(e.layout="vertical",n=i.getOrdinalMeta(),l=!this._hasEncodeRule("y")):e.layout=e.layout||"horizontal";var u=["x","y"],c=e.layout==="horizontal"?0:1,f=this._baseAxisDim=u[c],d=u[1-c],v=[a,i],g=v[c].get("type"),y=v[1-c].get("type"),x=e.data;if(x&&l){var b=[];O(x,function(C,D){var M;ce(C)?(M=C.slice(),C.unshift(D)):ce(C.value)?(M=ie({},C),M.value=M.value.slice(),C.value.unshift(D)):M=C,b.push(M)}),e.data=b}var w=this.defaultValueDimensions,T=[{name:f,type:e1(g),ordinalMeta:n,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:d,type:e1(y),dimsDef:w.slice()}];return gd(this,{coordDimensions:T,dimensionsCount:w.length+1,encodeDefaulter:He(T8,T,this)})},r.prototype.getBaseAxis=function(){var e=this._baseAxisDim;return this.ecModel.getComponent(e+"Axis",this.get(e+"AxisIndex")).axis},r})(),p9=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],t.visualDrawType="stroke",t}return e.type="series.boxplot",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:ee.color.neutral00,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:ee.color.shadow}},animationDuration:800},e})(Ct);Jt(p9,v9,!0);var fme=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this.group,s=this._data;this._data||o.removeAll();var l=t.get("layout")==="horizontal"?1:0;i.diff(s).add(function(u){if(i.hasValue(u)){var c=i.getItemLayout(u),f=pz(c,i,u,l,!0);i.setItemGraphicEl(u,f),o.add(f)}}).update(function(u,c){var f=s.getItemGraphicEl(c);if(!i.hasValue(u)){o.remove(f);return}var d=i.getItemLayout(u);f?(ja(f),g9(d,f,i,u)):f=pz(d,i,u,l),o.add(f),i.setItemGraphicEl(u,f)}).remove(function(u){var c=s.getItemGraphicEl(u);c&&o.remove(c)}).execute(),this._data=i},e.prototype.remove=function(t){var n=this.group,a=this._data;this._data=null,a&&a.eachItemGraphicEl(function(i){i&&n.remove(i)})},e.type="boxplot",e})(St),hme=(function(){function r(){}return r})(),dme=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="boxplotBoxPath",n}return e.prototype.getDefaultShape=function(){return new hme},e.prototype.buildPath=function(t,n){var a=n.points,i=0;for(t.moveTo(a[i][0],a[i][1]),i++;i<4;i++)t.lineTo(a[i][0],a[i][1]);for(t.closePath();i<a.length;i++)t.moveTo(a[i][0],a[i][1]),i++,t.lineTo(a[i][0],a[i][1])},e})(tt);function pz(r,e,t,n,a){var i=r.ends,o=new dme({shape:{points:a?vme(i,n,r):i}});return g9(r,o,e,t,a),o}function g9(r,e,t,n,a){var i=t.hostModel,o=_c[a?"initProps":"updateProps"];o(e,{shape:{points:r.ends}},i,n),e.useStyle(t.getItemVisual(n,"style")),e.style.strokeNoScale=!0,e.z2=100;var s=t.getItemModel(n),l=s.getModel("emphasis");_r(e,s),Ut(e,l.get("focus"),l.get("blurScope"),l.get("disabled"))}function vme(r,e,t){return fe(r,function(n){return n=n.slice(),n[e]=t.initBaseline,n})}var Pp=O;function pme(r){var e=gme(r);Pp(e,function(t){var n=t.seriesModels;n.length&&(mme(t),Pp(n,function(a,i){yme(a,t.boxOffsetList[i],t.boxWidthList[i])}))})}function gme(r){var e=[],t=[];return r.eachSeriesByType("boxplot",function(n){var a=n.getBaseAxis(),i=Fe(t,a);i<0&&(i=t.length,t[i]=a,e[i]={axis:a,seriesModels:[]}),e[i].seriesModels.push(n)}),e}function mme(r){var e=r.axis,t=r.seriesModels,n=t.length,a=r.boxWidthList=[],i=r.boxOffsetList=[],o=[],s;if(e.type==="category")s=e.getBandWidth();else{var l=0;Pp(t,function(g){l=Math.max(l,g.getData().count())});var u=e.getExtent();s=Math.abs(u[1]-u[0])/l}Pp(t,function(g){var y=g.get("boxWidth");ce(y)||(y=[y,y]),o.push([me(y[0],s)||0,me(y[1],s)||0])});var c=s*.8-2,f=c/n*.3,d=(c-f*(n-1))/n,v=d/2-c/2;Pp(t,function(g,y){i.push(v),v+=f+d,a.push(Math.min(Math.max(d,o[y][0]),o[y][1]))})}function yme(r,e,t){var n=r.coordinateSystem,a=r.getData(),i=t/2,o=r.get("layout")==="horizontal"?0:1,s=1-o,l=["x","y"],u=a.mapDimension(l[o]),c=a.mapDimensionsAll(l[s]);if(u==null||c.length<5)return;for(var f=0;f<a.count();f++){var d=a.get(u,f),v=T(d,c[2],f),g=T(d,c[0],f),y=T(d,c[1],f),x=T(d,c[3],f),b=T(d,c[4],f),w=[];C(w,y,!1),C(w,x,!0),w.push(g,y,b,x),D(w,g),D(w,b),D(w,v),a.setItemLayout(f,{initBaseline:v[s],ends:w})}function T(M,N,R){var E=a.get(N,R),k=[];k[o]=M,k[s]=E;var I;return isNaN(M)||isNaN(E)?I=[NaN,NaN]:(I=n.dataToPoint(k),I[o]+=e),I}function C(M,N,R){var E=N.slice(),k=N.slice();E[o]+=i,k[o]-=i,R?M.push(E,k):M.push(k,E)}function D(M,N){var R=N.slice(),E=N.slice();R[o]-=i,E[o]+=i,M.push(R,E)}}function xme(r,e){e=e||{};for(var t=[],n=[],a=e.boundIQR,i=a==="none"||a===0,o=0;o<r.length;o++){var s=na(r[o].slice()),l=Q0(s,.25),u=Q0(s,.5),c=Q0(s,.75),f=s[0],d=s[s.length-1],v=(a??1.5)*(c-l),g=i?f:Math.max(f,l-v),y=i?d:Math.min(d,c+v),x=e.itemNameFormatter,b=Me(x)?x({value:o}):ye(x)?x.replace("{value}",o+""):o+"";t.push([b,g,l,u,c,y]);for(var w=0;w<s.length;w++){var T=s[w];if(T<g||T>y){var C=[b,T];n.push(C)}}}return{boxData:t,outliers:n}}var bme={type:"echarts:boxplot",transform:function(e){var t=e.upstream;if(t.sourceFormat!==Yr){var n="";gt(n)}var a=xme(t.getRawData(),e.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:a.boxData},{data:a.outliers}]}};function _me(r){r.registerSeriesModel(p9),r.registerChartView(fme),r.registerLayout(pme),r.registerTransform(bme)}var Sme=["itemStyle","borderColor"],wme=["itemStyle","borderColor0"],Tme=["itemStyle","borderColorDoji"],Cme=["itemStyle","color"],Ame=["itemStyle","color0"];function ZN(r,e){return e.get(r>0?Cme:Ame)}function $N(r,e){return e.get(r===0?Tme:r>0?Sme:wme)}var Mme={seriesType:"candlestick",plan:ud(),performRawSeries:!0,reset:function(r,e){if(!e.isSeriesFiltered(r)){var t=r.pipelineContext.large;return!t&&{progress:function(n,a){for(var i;(i=n.next())!=null;){var o=a.getItemModel(i),s=a.getItemLayout(i).sign,l=o.getItemStyle();l.fill=ZN(s,o),l.stroke=$N(s,o)||l.fill;var u=a.ensureUniqueItemVisual(i,"style");ie(u,l)}}}}}},Dme=["color","borderColor"],Nme=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},e.prototype.incrementalPrepareRender=function(t,n,a){this._clear(),this._updateDrawMode(t)},e.prototype.incrementalRender=function(t,n,a,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,n):this._incrementalRenderNormal(t,n)},e.prototype.eachRendered=function(t){Ll(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var n=t.pipelineContext.large;(this._isLargeDraw==null||n!==this._isLargeDraw)&&(this._isLargeDraw=n,this._clear())},e.prototype._renderNormal=function(t){var n=t.getData(),a=this._data,i=this.group,o=n.getLayout("isSimpleBox"),s=t.get("clip",!0),l=t.coordinateSystem,u=l.getArea&&l.getArea();this._data||i.removeAll(),n.diff(a).add(function(c){if(n.hasValue(c)){var f=n.getItemLayout(c);if(s&&gz(u,f))return;var d=W2(f,c,!0);zt(d,{shape:{points:f.ends}},t,c),X2(d,n,c,o),i.add(d),n.setItemGraphicEl(c,d)}}).update(function(c,f){var d=a.getItemGraphicEl(f);if(!n.hasValue(c)){i.remove(d);return}var v=n.getItemLayout(c);if(s&&gz(u,v)){i.remove(d);return}d?(lt(d,{shape:{points:v.ends}},t,c),ja(d)):d=W2(v),X2(d,n,c,o),i.add(d),n.setItemGraphicEl(c,d)}).remove(function(c){var f=a.getItemGraphicEl(c);f&&i.remove(f)}).execute(),this._data=n},e.prototype._renderLarge=function(t){this._clear(),mz(t,this.group);var n=t.get("clip",!0)?tm(t.coordinateSystem,!1,t):null;n?this.group.setClipPath(n):this.group.removeClipPath()},e.prototype._incrementalRenderNormal=function(t,n){for(var a=n.getData(),i=a.getLayout("isSimpleBox"),o;(o=t.next())!=null;){var s=a.getItemLayout(o),l=W2(s);X2(l,a,o,i),l.incremental=!0,this.group.add(l),this._progressiveEls.push(l)}},e.prototype._incrementalRenderLarge=function(t,n){mz(n,this.group,this._progressiveEls,!0)},e.prototype.remove=function(t){this._clear()},e.prototype._clear=function(){this.group.removeAll(),this._data=null},e.type="candlestick",e})(St),Lme=(function(){function r(){}return r})(),Rme=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="normalCandlestickBox",n}return e.prototype.getDefaultShape=function(){return new Lme},e.prototype.buildPath=function(t,n){var a=n.points;this.__simpleBox?(t.moveTo(a[4][0],a[4][1]),t.lineTo(a[6][0],a[6][1])):(t.moveTo(a[0][0],a[0][1]),t.lineTo(a[1][0],a[1][1]),t.lineTo(a[2][0],a[2][1]),t.lineTo(a[3][0],a[3][1]),t.closePath(),t.moveTo(a[4][0],a[4][1]),t.lineTo(a[5][0],a[5][1]),t.moveTo(a[6][0],a[6][1]),t.lineTo(a[7][0],a[7][1]))},e})(tt);function W2(r,e,t){var n=r.ends;return new Rme({shape:{points:t?Eme(n,r):n},z2:100})}function gz(r,e){for(var t=!0,n=0;n<e.ends.length;n++)if(r.contain(e.ends[n][0],e.ends[n][1])){t=!1;break}return t}function X2(r,e,t,n){var a=e.getItemModel(t);r.useStyle(e.getItemVisual(t,"style")),r.style.strokeNoScale=!0,r.__simpleBox=n,_r(r,a);var i=e.getItemLayout(t).sign;O(r.states,function(s,l){var u=a.getModel(l),c=ZN(i,u),f=$N(i,u)||c,d=s.style||(s.style={});c&&(d.fill=c),f&&(d.stroke=f)});var o=a.getModel("emphasis");Ut(r,o.get("focus"),o.get("blurScope"),o.get("disabled"))}function Eme(r,e){return fe(r,function(t){return t=t.slice(),t[1]=e.initBaseline,t})}var kme=(function(){function r(){}return r})(),q2=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.type="largeCandlestickBox",n}return e.prototype.getDefaultShape=function(){return new kme},e.prototype.buildPath=function(t,n){for(var a=n.points,i=0;i<a.length;)if(this.__sign===a[i++]){var o=a[i++];t.moveTo(o,a[i++]),t.lineTo(o,a[i++])}else i+=3},e})(tt);function mz(r,e,t,n){var a=r.getData(),i=a.getLayout("largePoints"),o=new q2({shape:{points:i},__sign:1,ignoreCoarsePointer:!0});e.add(o);var s=new q2({shape:{points:i},__sign:-1,ignoreCoarsePointer:!0});e.add(s);var l=new q2({shape:{points:i},__sign:0,ignoreCoarsePointer:!0});e.add(l),Z2(1,o,r),Z2(-1,s,r),Z2(0,l,r),n&&(o.incremental=!0,s.incremental=!0),t&&t.push(o,s)}function Z2(r,e,t,n){var a=$N(r,t)||ZN(r,t),i=t.getModel("itemStyle").getItemStyle(Dme);e.useStyle(i),e.style.fill=null,e.style.stroke=a}var m9=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],t}return e.prototype.getShadowDim=function(){return"open"},e.prototype.brushSelector=function(t,n,a){var i=n.getItemLayout(t);return i&&a.rect(i.brushRect)},e.type="series.candlestick",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e})(Ct);Jt(m9,v9,!0);function Ime(r){!r||!ce(r.series)||O(r.series,function(e){Ee(e)&&e.type==="k"&&(e.type="candlestick")})}var Ome={seriesType:"candlestick",plan:ud(),reset:function(r){var e=r.coordinateSystem,t=r.getData(),n=Pme(r,t),a=0,i=1,o=["x","y"],s=t.getDimensionIndex(t.mapDimension(o[a])),l=fe(t.mapDimensionsAll(o[i]),t.getDimensionIndex,t),u=l[0],c=l[1],f=l[2],d=l[3];if(t.setLayout({candleWidth:n,isSimpleBox:n<=1.3}),s<0||l.length<4)return;return{progress:r.pipelineContext.large?g:v};function v(y,x){for(var b,w=x.getStore();(b=y.next())!=null;){var T=w.get(s,b),C=w.get(u,b),D=w.get(c,b),M=w.get(f,b),N=w.get(d,b),R=Math.min(C,D),E=Math.max(C,D),k=U(R,T),I=U(E,T),B=U(M,T),P=U(N,T),H=[];F(H,I,0),F(H,k,1),H.push(G(P),G(I),G(B),G(k));var V=x.getItemModel(b),j=!!V.get(["itemStyle","borderColorDoji"]);x.setItemLayout(b,{sign:yz(w,b,C,D,c,j),initBaseline:C>D?I[i]:k[i],ends:H,brushRect:X(M,N,T)})}function U(W,$){var te=[];return te[a]=$,te[i]=W,isNaN($)||isNaN(W)?[NaN,NaN]:e.dataToPoint(te)}function F(W,$,te){var ue=$.slice(),ge=$.slice();ue[a]=ex(ue[a]+n/2,1,!1),ge[a]=ex(ge[a]-n/2,1,!0),te?W.push(ue,ge):W.push(ge,ue)}function X(W,$,te){var ue=U(W,te),ge=U($,te);return ue[a]-=n/2,ge[a]-=n/2,{x:ue[0],y:ue[1],width:n,height:ge[1]-ue[1]}}function G(W){return W[a]=ex(W[a],1),W}}function g(y,x){for(var b=zi(y.count*4),w=0,T,C=[],D=[],M,N=x.getStore(),R=!!r.get(["itemStyle","borderColorDoji"]);(M=y.next())!=null;){var E=N.get(s,M),k=N.get(u,M),I=N.get(c,M),B=N.get(f,M),P=N.get(d,M);if(isNaN(E)||isNaN(B)||isNaN(P)){b[w++]=NaN,w+=3;continue}b[w++]=yz(N,M,k,I,c,R),C[a]=E,C[i]=B,T=e.dataToPoint(C,null,D),b[w++]=T?T[0]:NaN,b[w++]=T?T[1]:NaN,C[i]=P,T=e.dataToPoint(C,null,D),b[w++]=T?T[1]:NaN}x.setLayout("largePoints",b)}}};function yz(r,e,t,n,a,i){var o;return t>n?o=-1:t<n?o=1:o=i?0:e>0?r.get(a,e-1)<=n?1:-1:1,o}function Pme(r,e){var t=r.getBaseAxis(),n,a=t.type==="category"?t.getBandWidth():(n=t.getExtent(),Math.abs(n[1]-n[0])/e.count()),i=me(Ce(r.get("barMaxWidth"),a),a),o=me(Ce(r.get("barMinWidth"),1),a),s=r.get("barWidth");return s!=null?me(s,a):Math.max(Math.min(a/2,i),o)}function jme(r){r.registerChartView(Nme),r.registerSeriesModel(m9),r.registerPreprocessor(Ime),r.registerVisual(Mme),r.registerLayout(Ome)}function xz(r,e){var t=e.rippleEffectColor||e.color;r.eachChild(function(n){n.attr({z:e.z,zlevel:e.zlevel,style:{stroke:e.brushType==="stroke"?t:null,fill:e.brushType==="fill"?t:null}})})}var zme=(function(r){K(e,r);function e(t,n){var a=r.call(this)||this,i=new Jg(t,n),o=new Ne;return a.add(i),a.add(o),a.updateData(t,n),a}return e.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},e.prototype.startEffectAnimation=function(t){for(var n=t.symbolType,a=t.color,i=t.rippleNumber,o=this.childAt(1),s=0;s<i;s++){var l=ur(n,-1,-1,2,2,a);l.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5});var u=-s/i*t.period+t.effectOffset;l.animate("",!0).when(t.period,{scaleX:t.rippleScale/2,scaleY:t.rippleScale/2}).delay(u).start(),l.animateStyle(!0).when(t.period,{opacity:0}).delay(u).start(),o.add(l)}xz(o,t)},e.prototype.updateEffectAnimation=function(t){for(var n=this._effectCfg,a=this.childAt(1),i=["symbolType","period","rippleScale","rippleNumber"],o=0;o<i.length;o++){var s=i[o];if(n[s]!==t[s]){this.stopEffectAnimation(),this.startEffectAnimation(t);return}}xz(a,t)},e.prototype.highlight=function(){$o(this)},e.prototype.downplay=function(){Ko(this)},e.prototype.getSymbolType=function(){var t=this.childAt(0);return t&&t.getSymbolType()},e.prototype.updateData=function(t,n){var a=this,i=t.hostModel;this.childAt(0).updateData(t,n);var o=this.childAt(1),s=t.getItemModel(n),l=t.getItemVisual(n,"symbol"),u=fd(t.getItemVisual(n,"symbolSize")),c=t.getItemVisual(n,"style"),f=c&&c.fill,d=s.getModel("emphasis");o.setScale(u),o.traverse(function(x){x.setStyle("fill",f)});var v=Tc(t.getItemVisual(n,"symbolOffset"),u);v&&(o.x=v[0],o.y=v[1]);var g=t.getItemVisual(n,"symbolRotate");o.rotation=(g||0)*Math.PI/180||0;var y={};y.showEffectOn=i.get("showEffectOn"),y.rippleScale=s.get(["rippleEffect","scale"]),y.brushType=s.get(["rippleEffect","brushType"]),y.period=s.get(["rippleEffect","period"])*1e3,y.effectOffset=n/t.count(),y.z=i.getShallow("z")||0,y.zlevel=i.getShallow("zlevel")||0,y.symbolType=l,y.color=f,y.rippleEffectColor=s.get(["rippleEffect","color"]),y.rippleNumber=s.get(["rippleEffect","number"]),y.showEffectOn==="render"?(this._effectCfg?this.updateEffectAnimation(y):this.startEffectAnimation(y),this._effectCfg=y):(this._effectCfg=null,this.stopEffectAnimation(),this.onHoverStateChange=function(x){x==="emphasis"?y.showEffectOn!=="render"&&a.startEffectAnimation(y):x==="normal"&&y.showEffectOn!=="render"&&a.stopEffectAnimation()}),this._effectCfg=y,Ut(this,d.get("focus"),d.get("blurScope"),d.get("disabled"))},e.prototype.fadeOut=function(t){t&&t()},e})(Ne),Bme=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._symbolDraw=new em(zme)},e.prototype.render=function(t,n,a){var i=t.getData(),o=this._symbolDraw;o.updateData(i,{clipShape:this._getClipShape(t)}),this.group.add(o.group)},e.prototype._getClipShape=function(t){var n=t.coordinateSystem,a=n&&n.getArea&&n.getArea();return t.get("clip",!0)?a:null},e.prototype.updateTransform=function(t,n,a){var i=t.getData();this.group.dirty();var o=rm("").reset(t,n,a);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout()},e.prototype._updateGroupTransform=function(t){var n=t.coordinateSystem;n&&n.getRoamTransform&&(this.group.transform=C6(n.getRoamTransform()),this.group.decomposeTransform())},e.prototype.remove=function(t,n){this._symbolDraw&&this._symbolDraw.remove(!0)},e.type="effectScatter",e})(St),Vme=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,n){return to(null,this,{useEncodeDefaulter:!0})},e.prototype.brushSelector=function(t,n,a){return a.point(n.getItemLayout(t))},e.type="series.effectScatter",e.dependencies=["grid","polar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10},e})(Ct);function Gme(r){r.registerChartView(Bme),r.registerSeriesModel(Vme),r.registerLayout(rm("effectScatter"))}var y9=(function(r){K(e,r);function e(t,n,a){var i=r.call(this)||this;return i.add(i.createLine(t,n,a)),i._updateEffectSymbol(t,n),i}return e.prototype.createLine=function(t,n,a){return new BN(t,n,a)},e.prototype._updateEffectSymbol=function(t,n){var a=t.getItemModel(n),i=a.getModel("effect"),o=i.get("symbolSize"),s=i.get("symbol");ce(o)||(o=[o,o]);var l=t.getItemVisual(n,"style"),u=i.get("color")||l&&l.stroke,c=this.childAt(1);this._symbolType!==s&&(this.remove(c),c=ur(s,-.5,-.5,1,1,u),c.z2=100,c.culling=!0,this.add(c)),c&&(c.setStyle("shadowColor",u),c.setStyle(i.getItemStyle(["color"])),c.scaleX=o[0],c.scaleY=o[1],c.setColor(u),this._symbolType=s,this._symbolScale=o,this._updateEffectAnimation(t,i,n))},e.prototype._updateEffectAnimation=function(t,n,a){var i=this.childAt(1);if(i){var o=t.getItemLayout(a),s=n.get("period")*1e3,l=n.get("loop"),u=n.get("roundTrip"),c=n.get("constantSpeed"),f=Fr(n.get("delay"),function(v){return v/t.count()*s/3});if(i.ignore=!0,this._updateAnimationPoints(i,o),c>0&&(s=this._getLineLength(i)/c*1e3),s!==this._period||l!==this._loop||u!==this._roundTrip){i.stopAnimation();var d=void 0;Me(f)?d=f(a):d=f,i.__t>0&&(d=-s*i.__t),this._animateSymbol(i,s,d,l,u)}this._period=s,this._loop=l,this._roundTrip=u}},e.prototype._animateSymbol=function(t,n,a,i,o){if(n>0){t.__t=0;var s=this,l=t.animate("",i).when(o?n*2:n,{__t:o?2:1}).delay(a).during(function(){s._updateSymbolPosition(t)});i||l.done(function(){s.remove(t)}),l.start()}},e.prototype._getLineLength=function(t){return Io(t.__p1,t.__cp1)+Io(t.__cp1,t.__p2)},e.prototype._updateAnimationPoints=function(t,n){t.__p1=n[0],t.__p2=n[1],t.__cp1=n[2]||[(n[0][0]+n[1][0])/2,(n[0][1]+n[1][1])/2]},e.prototype.updateData=function(t,n,a){this.childAt(0).updateData(t,n,a),this._updateEffectSymbol(t,n)},e.prototype._updateSymbolPosition=function(t){var n=t.__p1,a=t.__p2,i=t.__cp1,o=t.__t<1?t.__t:2-t.__t,s=[t.x,t.y],l=s.slice(),u=Hr,c=vC;s[0]=u(n[0],i[0],a[0],o),s[1]=u(n[1],i[1],a[1],o);var f=t.__t<1?c(n[0],i[0],a[0],o):c(a[0],i[0],n[0],1-o),d=t.__t<1?c(n[1],i[1],a[1],o):c(a[1],i[1],n[1],1-o);t.rotation=-Math.atan2(d,f)-Math.PI/2,(this._symbolType==="line"||this._symbolType==="rect"||this._symbolType==="roundRect")&&(t.__lastT!==void 0&&t.__lastT<t.__t?(t.scaleY=Io(l,s)*1.05,o===1&&(s[0]=l[0]+(s[0]-l[0])/2,s[1]=l[1]+(s[1]-l[1])/2)):t.__lastT===1?t.scaleY=2*Io(n,s):t.scaleY=this._symbolScale[1]),t.__lastT=t.__t,t.ignore=!1,t.x=s[0],t.y=s[1]},e.prototype.updateLayout=function(t,n){this.childAt(0).updateLayout(t,n);var a=t.getItemModel(n).getModel("effect");this._updateEffectAnimation(t,a,n)},e})(Ne),x9=(function(r){K(e,r);function e(t,n,a){var i=r.call(this)||this;return i._createPolyline(t,n,a),i}return e.prototype._createPolyline=function(t,n,a){var i=t.getItemLayout(n),o=new Ur({shape:{points:i}});this.add(o),this._updateCommonStl(t,n,a)},e.prototype.updateData=function(t,n,a){var i=t.hostModel,o=this.childAt(0),s={shape:{points:t.getItemLayout(n)}};lt(o,s,i,n),this._updateCommonStl(t,n,a)},e.prototype._updateCommonStl=function(t,n,a){var i=this.childAt(0),o=t.getItemModel(n),s=a&&a.emphasisLineStyle,l=a&&a.focus,u=a&&a.blurScope,c=a&&a.emphasisDisabled;if(!a||t.hasItemOption){var f=o.getModel("emphasis");s=f.getModel("lineStyle").getLineStyle(),c=f.get("disabled"),l=f.get("focus"),u=f.get("blurScope")}i.useStyle(t.getItemVisual(n,"style")),i.style.fill=null,i.style.strokeNoScale=!0;var d=i.ensureState("emphasis");d.style=s,Ut(this,l,u,c)},e.prototype.updateLayout=function(t,n){var a=this.childAt(0);a.setShape("points",t.getItemLayout(n))},e})(Ne),Hme=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._lastFrame=0,t._lastFramePercent=0,t}return e.prototype.createLine=function(t,n,a){return new x9(t,n,a)},e.prototype._updateAnimationPoints=function(t,n){this._points=n;for(var a=[0],i=0,o=1;o<n.length;o++){var s=n[o-1],l=n[o];i+=Io(s,l),a.push(i)}if(i===0){this._length=0;return}for(var o=0;o<a.length;o++)a[o]/=i;this._offsets=a,this._length=i},e.prototype._getLineLength=function(){return this._length},e.prototype._updateSymbolPosition=function(t){var n=t.__t<1?t.__t:2-t.__t,a=this._points,i=this._offsets,o=a.length;if(i){var s=this._lastFrame,l;if(n<this._lastFramePercent){var u=Math.min(s+1,o-1);for(l=u;l>=0&&!(i[l]<=n);l--);l=Math.min(l,o-2)}else{for(l=s;l<o&&!(i[l]>n);l++);l=Math.min(l-1,o-2)}var c=(n-i[l])/(i[l+1]-i[l]),f=a[l],d=a[l+1];t.x=f[0]*(1-c)+c*d[0],t.y=f[1]*(1-c)+c*d[1];var v=t.__t<1?d[0]-f[0]:f[0]-d[0],g=t.__t<1?d[1]-f[1]:f[1]-d[1];t.rotation=-Math.atan2(g,v)-Math.PI/2,this._lastFrame=l,this._lastFramePercent=n,t.ignore=!1}},e})(y9),Fme=(function(){function r(){this.polyline=!1,this.curveness=0,this.segs=[]}return r})(),Ume=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n._off=0,n.hoverDataIdx=-1,n}return e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.getDefaultStyle=function(){return{stroke:ee.color.neutral99,fill:null}},e.prototype.getDefaultShape=function(){return new Fme},e.prototype.buildPath=function(t,n){var a=n.segs,i=n.curveness,o;if(n.polyline)for(o=this._off;o<a.length;){var s=a[o++];if(s>0){t.moveTo(a[o++],a[o++]);for(var l=1;l<s;l++)t.lineTo(a[o++],a[o++])}}else for(o=this._off;o<a.length;){var u=a[o++],c=a[o++],f=a[o++],d=a[o++];if(t.moveTo(u,c),i>0){var v=(u+f)/2-(c-d)*i,g=(c+d)/2-(f-u)*i;t.quadraticCurveTo(v,g,f,d)}else t.lineTo(f,d)}this.incremental&&(this._off=o,this.notClear=!0)},e.prototype.findDataIndex=function(t,n){var a=this.shape,i=a.segs,o=a.curveness,s=this.style.lineWidth;if(a.polyline)for(var l=0,u=0;u<i.length;){var c=i[u++];if(c>0)for(var f=i[u++],d=i[u++],v=1;v<c;v++){var g=i[u++],y=i[u++];if(Us(f,d,g,y,s,t,n))return l}l++}else for(var l=0,u=0;u<i.length;){var f=i[u++],d=i[u++],g=i[u++],y=i[u++];if(o>0){var x=(f+g)/2-(d-y)*o,b=(d+y)/2-(g-f)*o;if(xH(f,d,x,b,g,y,s,t,n))return l}else if(Us(f,d,g,y,s,t,n))return l;l++}return-1},e.prototype.contain=function(t,n){var a=this.transformCoordToLocal(t,n),i=this.getBoundingRect();if(t=a[0],n=a[1],i.contain(t,n)){var o=this.hoverDataIdx=this.findDataIndex(t,n);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var n=this.shape,a=n.segs,i=1/0,o=1/0,s=-1/0,l=-1/0,u=0;u<a.length;){var c=a[u++],f=a[u++];i=Math.min(c,i),s=Math.max(c,s),o=Math.min(f,o),l=Math.max(f,l)}t=this._rect=new Oe(i,o,s,l)}return t},e})(tt),Yme=(function(){function r(){this.group=new Ne}return r.prototype.updateData=function(e){this._clear();var t=this._create();t.setShape({segs:e.getLayout("linesPoints")}),this._setCommon(t,e)},r.prototype.incrementalPrepareUpdate=function(e){this.group.removeAll(),this._clear()},r.prototype.incrementalUpdate=function(e,t){var n=this._newAdded[0],a=t.getLayout("linesPoints"),i=n&&n.shape.segs;if(i&&i.length<2e4){var o=i.length,s=new Float32Array(o+a.length);s.set(i),s.set(a,o),n.setShape({segs:s})}else{this._newAdded=[];var l=this._create();l.incremental=!0,l.setShape({segs:a}),this._setCommon(l,t),l.__startIndex=e.start}},r.prototype.remove=function(){this._clear()},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new Ume({cursor:"default",ignoreCoarsePointer:!0});return this._newAdded.push(e),this.group.add(e),e},r.prototype._setCommon=function(e,t,n){var a=t.hostModel;e.setShape({polyline:a.get("polyline"),curveness:a.get(["lineStyle","curveness"])}),e.useStyle(a.getModel("lineStyle").getLineStyle()),e.style.strokeNoScale=!0;var i=t.getVisual("style");i&&i.stroke&&e.setStyle("stroke",i.stroke),e.setStyle("fill",null);var o=je(e);o.seriesIndex=a.seriesIndex,e.on("mousemove",function(s){o.dataIndex=null;var l=e.hoverDataIdx;l>0&&(o.dataIndex=l+e.__startIndex)})},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r})(),b9={seriesType:"lines",plan:ud(),reset:function(r){var e=r.coordinateSystem;if(e){var t=r.get("polyline"),n=r.pipelineContext.large;return{progress:function(a,i){var o=[];if(n){var s=void 0,l=a.end-a.start;if(t){for(var u=0,c=a.start;c<a.end;c++)u+=r.getLineCoordsCount(c);s=new Float32Array(l+u*2)}else s=new Float32Array(l*4);for(var f=0,d=[],c=a.start;c<a.end;c++){var v=r.getLineCoords(c,o);t&&(s[f++]=v);for(var g=0;g<v;g++)d=e.dataToPoint(o[g],!1,d),s[f++]=d[0],s[f++]=d[1]}i.setLayout("linesPoints",s)}else for(var c=a.start;c<a.end;c++){var y=i.getItemModel(c),v=r.getLineCoords(c,o),x=[];if(t)for(var b=0;b<v;b++)x.push(e.dataToPoint(o[b]));else{x[0]=e.dataToPoint(o[0]),x[1]=e.dataToPoint(o[1]);var w=y.get(["lineStyle","curveness"]);+w&&(x[2]=[(x[0][0]+x[1][0])/2-(x[0][1]-x[1][1])*w,(x[0][1]+x[1][1])/2-(x[1][0]-x[0][0])*w])}i.setItemLayout(c,x)}}}}}},Wme=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this._updateLineDraw(i,t),s=t.get("zlevel"),l=t.get(["effect","trailLength"]),u=a.getZr(),c=u.painter.getType()==="svg";c||u.painter.getLayer(s).clear(!0),this._lastZlevel!=null&&!c&&u.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(t)&&l>0&&(c||u.configLayer(s,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(l/10+.9,1),0)})),o.updateData(i);var f=t.get("clip",!0)&&tm(t.coordinateSystem,!1,t);f?this.group.setClipPath(f):this.group.removeClipPath(),this._lastZlevel=s,this._finished=!0},e.prototype.incrementalPrepareRender=function(t,n,a){var i=t.getData(),o=this._updateLineDraw(i,t);o.incrementalPrepareUpdate(i),this._clearLayer(a),this._finished=!1},e.prototype.incrementalRender=function(t,n,a){this._lineDraw.incrementalUpdate(t,n.getData()),this._finished=t.end===n.getData().count()},e.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},e.prototype.updateTransform=function(t,n,a){var i=t.getData(),o=t.pipelineContext;if(!this._finished||o.large||o.progressiveRender)return{update:!0};var s=b9.reset(t,n,a);s.progress&&s.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(a)},e.prototype._updateLineDraw=function(t,n){var a=this._lineDraw,i=this._showEffect(n),o=!!n.get("polyline"),s=n.pipelineContext,l=s.large;return(!a||i!==this._hasEffet||o!==this._isPolyline||l!==this._isLargeDraw)&&(a&&a.remove(),a=this._lineDraw=l?new Yme:new VN(o?i?Hme:x9:i?y9:BN),this._hasEffet=i,this._isPolyline=o,this._isLargeDraw=l),this.group.add(a.group),a},e.prototype._showEffect=function(t){return!!t.get(["effect","show"])},e.prototype._clearLayer=function(t){var n=t.getZr(),a=n.painter.getType()==="svg";!a&&this._lastZlevel!=null&&n.painter.getLayer(this._lastZlevel).clear(!0)},e.prototype.remove=function(t,n){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(n)},e.prototype.dispose=function(t,n){this.remove(t,n)},e.type="lines",e})(St),Xme=typeof Uint32Array>"u"?Array:Uint32Array,qme=typeof Float64Array>"u"?Array:Float64Array;function bz(r){var e=r.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(r.data=fe(e,function(t){var n=[t[0].coord,t[1].coord],a={coords:n};return t[0].name&&(a.fromName=t[0].name),t[1].name&&(a.toName=t[1].name),W1([a,t[0],t[1]])}))}var Zme=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.init=function(t){t.data=t.data||[],bz(t);var n=this._processFlatCoordsArray(t.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(t.data=new Float32Array(n.count)),r.prototype.init.apply(this,arguments)},e.prototype.mergeOption=function(t){if(bz(t),t.data){var n=this._processFlatCoordsArray(t.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(t.data=new Float32Array(n.count))}r.prototype.mergeOption.apply(this,arguments)},e.prototype.appendData=function(t){var n=this._processFlatCoordsArray(t.data);n.flatCoords&&(this._flatCoords?(this._flatCoords=Lh(this._flatCoords,n.flatCoords),this._flatCoordsOffset=Lh(this._flatCoordsOffset,n.flatCoordsOffset)):(this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset),t.data=new Float32Array(n.count)),this.getRawData().appendData(t.data)},e.prototype._getCoordsFromItemModel=function(t){var n=this.getData().getItemModel(t),a=n.option instanceof Array?n.option:n.getShallow("coords");return a},e.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[t*2+1]:this._getCoordsFromItemModel(t).length},e.prototype.getLineCoords=function(t,n){if(this._flatCoordsOffset){for(var a=this._flatCoordsOffset[t*2],i=this._flatCoordsOffset[t*2+1],o=0;o<i;o++)n[o]=n[o]||[],n[o][0]=this._flatCoords[a+o*2],n[o][1]=this._flatCoords[a+o*2+1];return i}else{for(var s=this._getCoordsFromItemModel(t),o=0;o<s.length;o++)n[o]=n[o]||[],n[o][0]=s[o][0],n[o][1]=s[o][1];return s.length}},e.prototype._processFlatCoordsArray=function(t){var n=0;if(this._flatCoords&&(n=this._flatCoords.length),st(t[0])){for(var a=t.length,i=new Xme(a),o=new qme(a),s=0,l=0,u=0,c=0;c<a;){u++;var f=t[c++];i[l++]=s+n,i[l++]=f;for(var d=0;d<f;d++){var v=t[c++],g=t[c++];o[s++]=v,o[s++]=g}}return{flatCoordsOffset:new Uint32Array(i.buffer,0,l),flatCoords:o,count:u}}return{flatCoordsOffset:null,flatCoords:null,count:t.length}},e.prototype.getInitialData=function(t,n){var a=new pn(["value"],this);return a.hasItemOption=!1,a.initData(t.data,[],function(i,o,s,l){if(i instanceof Array)return NaN;a.hasItemOption=!0;var u=i.value;if(u!=null)return u instanceof Array?u[l]:u}),a},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=i.getItemModel(t),s=o.get("name");if(s)return s;var l=o.get("fromName"),u=o.get("toName"),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),pr("nameValue",{name:c.join(" > ")})},e.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?1e4:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?2e4:this.get("progressiveThreshold"))},e.prototype.getZLevelKey=function(){var t=this.getModel("effect"),n=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&n>0?n+"":""},e.type="series.lines",e.dependencies=["grid","polar","geo","calendar"],e.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},e})(Ct);function T0(r){return r instanceof Array||(r=[r,r]),r}var $me={seriesType:"lines",reset:function(r){var e=T0(r.get("symbol")),t=T0(r.get("symbolSize")),n=r.getData();n.setVisual("fromSymbol",e&&e[0]),n.setVisual("toSymbol",e&&e[1]),n.setVisual("fromSymbolSize",t&&t[0]),n.setVisual("toSymbolSize",t&&t[1]);function a(i,o){var s=i.getItemModel(o),l=T0(s.getShallow("symbol",!0)),u=T0(s.getShallow("symbolSize",!0));l[0]&&i.setItemVisual(o,"fromSymbol",l[0]),l[1]&&i.setItemVisual(o,"toSymbol",l[1]),u[0]&&i.setItemVisual(o,"fromSymbolSize",u[0]),u[1]&&i.setItemVisual(o,"toSymbolSize",u[1])}return{dataEach:n.hasItemOption?a:null}}};function Kme(r){r.registerChartView(Wme),r.registerSeriesModel(Zme),r.registerLayout(b9),r.registerVisual($me)}var Qme=256,Jme=(function(){function r(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var e=Bn.createCanvas();this.canvas=e}return r.prototype.update=function(e,t,n,a,i,o){var s=this._getBrush(),l=this._getGradient(i,"inRange"),u=this._getGradient(i,"outOfRange"),c=this.pointSize+this.blurSize,f=this.canvas,d=f.getContext("2d"),v=e.length;f.width=t,f.height=n;for(var g=0;g<v;++g){var y=e[g],x=y[0],b=y[1],w=y[2],T=a(w);d.globalAlpha=T,d.drawImage(s,x-c,b-c)}if(!f.width||!f.height)return f;for(var C=d.getImageData(0,0,f.width,f.height),D=C.data,M=0,N=D.length,R=this.minOpacity,E=this.maxOpacity,k=E-R;M<N;){var T=D[M+3]/256,I=Math.floor(T*(Qme-1))*4;if(T>0){var B=o(T)?l:u;T>0&&(T=T*k+R),D[M++]=B[I],D[M++]=B[I+1],D[M++]=B[I+2],D[M++]=B[I+3]*T*256}else M+=4}return d.putImageData(C,0,0),f},r.prototype._getBrush=function(){var e=this._brushCanvas||(this._brushCanvas=Bn.createCanvas()),t=this.pointSize+this.blurSize,n=t*2;e.width=n,e.height=n;var a=e.getContext("2d");return a.clearRect(0,0,n,n),a.shadowOffsetX=n,a.shadowBlur=this.blurSize,a.shadowColor=ee.color.neutral99,a.beginPath(),a.arc(-t,t,this.pointSize,0,Math.PI*2,!0),a.closePath(),a.fill(),e},r.prototype._getGradient=function(e,t){for(var n=this._gradientPixels,a=n[t]||(n[t]=new Uint8ClampedArray(256*4)),i=[0,0,0,0],o=0,s=0;s<256;s++)e[t](s/255,!0,i),a[o++]=i[0],a[o++]=i[1],a[o++]=i[2],a[o++]=i[3];return a},r})();function eye(r,e,t){var n=r[1]-r[0];e=fe(e,function(o){return{interval:[(o.interval[0]-r[0])/n,(o.interval[1]-r[0])/n]}});var a=e.length,i=0;return function(o){var s;for(s=i;s<a;s++){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}if(s===a)for(s=i-1;s>=0;s--){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}return s>=0&&s<a&&t[s]}}function tye(r,e){var t=r[1]-r[0];return e=[(e[0]-r[0])/t,(e[1]-r[0])/t],function(n){return n>=e[0]&&n<=e[1]}}function _z(r){var e=r.dimensions;return e[0]==="lng"&&e[1]==="lat"}var rye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i;n.eachComponent("visualMap",function(s){s.eachTargetSeries(function(l){l===t&&(i=s)})}),this._progressiveEls=null,this.group.removeAll();var o=t.coordinateSystem;o.type==="cartesian2d"||o.type==="calendar"||o.type==="matrix"?this._renderOnGridLike(t,a,0,t.getData().count()):_z(o)&&this._renderOnGeo(o,t,i,a)},e.prototype.incrementalPrepareRender=function(t,n,a){this.group.removeAll()},e.prototype.incrementalRender=function(t,n,a,i){var o=n.coordinateSystem;o&&(_z(o)?this.render(n,a,i):(this._progressiveEls=[],this._renderOnGridLike(n,i,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){Ll(this._progressiveEls||this.group,t)},e.prototype._renderOnGridLike=function(t,n,a,i,o){var s=t.coordinateSystem,l=wl(s,"cartesian2d"),u=wl(s,"matrix"),c,f,d,v;if(l){var g=s.getAxis("x"),y=s.getAxis("y");c=g.getBandWidth()+.5,f=y.getBandWidth()+.5,d=g.scale.getExtent(),v=y.scale.getExtent()}for(var x=this.group,b=t.getData(),w=t.getModel(["emphasis","itemStyle"]).getItemStyle(),T=t.getModel(["blur","itemStyle"]).getItemStyle(),C=t.getModel(["select","itemStyle"]).getItemStyle(),D=t.get(["itemStyle","borderRadius"]),M=Sr(t),N=t.getModel("emphasis"),R=N.get("focus"),E=N.get("blurScope"),k=N.get("disabled"),I=l||u?[b.mapDimension("x"),b.mapDimension("y"),b.mapDimension("value")]:[b.mapDimension("time"),b.mapDimension("value")],B=a;B<i;B++){var P=void 0,H=b.getItemVisual(B,"style");if(l){var V=b.get(I[0],B),j=b.get(I[1],B);if(isNaN(b.get(I[2],B))||isNaN(V)||isNaN(j)||V<d[0]||V>d[1]||j<v[0]||j>v[1])continue;var U=s.dataToPoint([V,j]);P=new qe({shape:{x:U[0]-c/2,y:U[1]-f/2,width:c,height:f},style:H})}else if(u){var F=s.dataToLayout([b.get(I[0],B),b.get(I[1],B)]).rect;if(en(F.x))continue;P=new qe({z2:1,shape:F,style:H})}else{if(isNaN(b.get(I[1],B)))continue;var X=s.dataToLayout([b.get(I[0],B)]),F=X.contentRect||X.rect;if(en(F.x)||en(F.y))continue;P=new qe({z2:1,shape:F,style:H})}if(b.hasItemOption){var G=b.getItemModel(B),W=G.getModel("emphasis");w=W.getModel("itemStyle").getItemStyle(),T=G.getModel(["blur","itemStyle"]).getItemStyle(),C=G.getModel(["select","itemStyle"]).getItemStyle(),D=G.get(["itemStyle","borderRadius"]),R=W.get("focus"),E=W.get("blurScope"),k=W.get("disabled"),M=Sr(G)}P.shape.r=D;var $=t.getRawValue(B),te="-";$&&$[2]!=null&&(te=$[2]+""),kr(P,M,{labelFetcher:t,labelDataIndex:B,defaultOpacity:H.opacity,defaultText:te}),P.ensureState("emphasis").style=w,P.ensureState("blur").style=T,P.ensureState("select").style=C,Ut(P,R,E,k),P.incremental=o,o&&(P.states.emphasis.hoverLayer=!0),x.add(P),b.setItemGraphicEl(B,P),this._progressiveEls&&this._progressiveEls.push(P)}},e.prototype._renderOnGeo=function(t,n,a,i){var o=a.targetVisuals.inRange,s=a.targetVisuals.outOfRange,l=n.getData(),u=this._hmLayer||this._hmLayer||new Jme;u.blurSize=n.get("blurSize"),u.pointSize=n.get("pointSize"),u.minOpacity=n.get("minOpacity"),u.maxOpacity=n.get("maxOpacity");var c=t.getViewRect().clone(),f=t.getRoamTransform();c.applyTransform(f);var d=Math.max(c.x,0),v=Math.max(c.y,0),g=Math.min(c.width+c.x,i.getWidth()),y=Math.min(c.height+c.y,i.getHeight()),x=g-d,b=y-v,w=[l.mapDimension("lng"),l.mapDimension("lat"),l.mapDimension("value")],T=l.mapArray(w,function(N,R,E){var k=t.dataToPoint([N,R]);return k[0]-=d,k[1]-=v,k.push(E),k}),C=a.getExtent(),D=a.type==="visualMap.continuous"?tye(C,a.option.range):eye(C,a.getPieceList(),a.option.selected);u.update(T,x,b,o.color.getNormalizer(),{inRange:o.color.getColorMapper(),outOfRange:s.color.getColorMapper()},D);var M=new Ir({style:{width:x,height:b,x:d,y:v,image:u.canvas},silent:!0});this.group.add(M)},e.type="heatmap",e})(St),nye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,n){return to(null,this,{generateCoord:"value"})},e.prototype.preventIncremental=function(){var t=ld.get(this.get("coordinateSystem"));if(t&&t.dimensions)return t.dimensions[0]==="lng"&&t.dimensions[1]==="lat"},e.type="series.heatmap",e.dependencies=["grid","geo","calendar","matrix"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:ee.color.primary}}},e})(Ct);function aye(r){r.registerChartView(rye),r.registerSeriesModel(nye)}var iye=["itemStyle","borderWidth"],Sz=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],$2=new eo,oye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=this.group,o=t.getData(),s=this._data,l=t.coordinateSystem,u=l.getBaseAxis(),c=u.isHorizontal(),f=l.master.getRect(),d={ecSize:{width:a.getWidth(),height:a.getHeight()},seriesModel:t,coordSys:l,coordSysExtent:[[f.x,f.x+f.width],[f.y,f.y+f.height]],isHorizontal:c,valueDim:Sz[+c],categoryDim:Sz[1-+c]};o.diff(s).add(function(g){if(o.hasValue(g)){var y=Tz(o,g),x=wz(o,g,y,d),b=Cz(o,d,x);o.setItemGraphicEl(g,b),i.add(b),Mz(b,d,x)}}).update(function(g,y){var x=s.getItemGraphicEl(y);if(!o.hasValue(g)){i.remove(x);return}var b=Tz(o,g),w=wz(o,g,b,d),T=A9(o,w);x&&T!==x.__pictorialShapeStr&&(i.remove(x),o.setItemGraphicEl(g,null),x=null),x?dye(x,d,w):x=Cz(o,d,w,!0),o.setItemGraphicEl(g,x),x.__pictorialSymbolMeta=w,i.add(x),Mz(x,d,w)}).remove(function(g){var y=s.getItemGraphicEl(g);y&&Az(s,g,y.__pictorialSymbolMeta.animationModel,y)}).execute();var v=t.get("clip",!0)?tm(t.coordinateSystem,!1,t):null;return v?i.setClipPath(v):i.removeClipPath(),this._data=o,this.group},e.prototype.remove=function(t,n){var a=this.group,i=this._data;t.get("animation")?i&&i.eachItemGraphicEl(function(o){Az(i,je(o).dataIndex,t,o)}):a.removeAll()},e.type="pictorialBar",e})(St);function wz(r,e,t,n){var a=r.getItemLayout(e),i=t.get("symbolRepeat"),o=t.get("symbolClip"),s=t.get("symbolPosition")||"start",l=t.get("symbolRotate"),u=(l||0)*Math.PI/180||0,c=t.get("symbolPatternSize")||2,f=t.isAnimationEnabled(),d={dataIndex:e,layout:a,itemModel:t,symbolType:r.getItemVisual(e,"symbol")||"circle",style:r.getItemVisual(e,"style"),symbolClip:o,symbolRepeat:i,symbolRepeatDirection:t.get("symbolRepeatDirection"),symbolPatternSize:c,rotation:u,animationModel:f?t:null,hoverScale:f&&t.get(["emphasis","scale"]),z2:t.getShallow("z",!0)||0};sye(t,i,a,n,d),lye(r,e,a,i,o,d.boundingLength,d.pxSign,c,n,d),uye(t,d.symbolScale,u,n,d);var v=d.symbolSize,g=Tc(t.get("symbolOffset"),v);return cye(t,v,a,i,o,g,s,d.valueLineWidth,d.boundingLength,d.repeatCutLength,n,d),d}function sye(r,e,t,n,a){var i=n.valueDim,o=r.get("symbolBoundingData"),s=n.coordSys.getOtherAxis(n.coordSys.getBaseAxis()),l=s.toGlobalCoord(s.dataToCoord(0)),u=1-+(t[i.wh]<=0),c;if(ce(o)){var f=[K2(s,o[0])-l,K2(s,o[1])-l];f[1]<f[0]&&f.reverse(),c=f[u]}else o!=null?c=K2(s,o)-l:e?c=n.coordSysExtent[i.index][u]-l:c=t[i.wh];a.boundingLength=c,e&&(a.repeatCutLength=t[i.wh]);var d=i.xy==="x",v=s.inverse;a.pxSign=d&&!v||!d&&v?c>=0?1:-1:c>0?1:-1}function K2(r,e){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(e)))}function lye(r,e,t,n,a,i,o,s,l,u){var c=l.valueDim,f=l.categoryDim,d=Math.abs(t[f.wh]),v=r.getItemVisual(e,"symbolSize"),g;ce(v)?g=v.slice():v==null?g=["100%","100%"]:g=[v,v],g[f.index]=me(g[f.index],d),g[c.index]=me(g[c.index],n?d:Math.abs(i)),u.symbolSize=g;var y=u.symbolScale=[g[0]/s,g[1]/s];y[c.index]*=(l.isHorizontal?-1:1)*o}function uye(r,e,t,n,a){var i=r.get(iye)||0;i&&($2.attr({scaleX:e[0],scaleY:e[1],rotation:t}),$2.updateTransform(),i/=$2.getLineScale(),i*=e[n.valueDim.index]),a.valueLineWidth=i||0}function cye(r,e,t,n,a,i,o,s,l,u,c,f){var d=c.categoryDim,v=c.valueDim,g=f.pxSign,y=Math.max(e[v.index]+s,0),x=y;if(n){var b=Math.abs(l),w=Fr(r.get("symbolMargin"),"15%")+"",T=!1;w.lastIndexOf("!")===w.length-1&&(T=!0,w=w.slice(0,w.length-1));var C=me(w,e[v.index]),D=Math.max(y+C*2,0),M=T?0:C*2,N=oD(n),R=N?n:Dz((b+M)/D),E=b-R*y;C=E/2/(T?R:Math.max(R-1,1)),D=y+C*2,M=T?0:C*2,!N&&n!=="fixed"&&(R=u?Dz((Math.abs(u)+M)/D):0),x=R*D-M,f.repeatTimes=R,f.symbolMargin=C}var k=g*(x/2),I=f.pathPosition=[];I[d.index]=t[d.wh]/2,I[v.index]=o==="start"?k:o==="end"?l-k:l/2,i&&(I[0]+=i[0],I[1]+=i[1]);var B=f.bundlePosition=[];B[d.index]=t[d.xy],B[v.index]=t[v.xy];var P=f.barRectShape=ie({},t);P[v.wh]=g*Math.max(Math.abs(t[v.wh]),Math.abs(I[v.index]+k)),P[d.wh]=t[d.wh];var H=f.clipShape={};H[d.xy]=-t[d.xy],H[d.wh]=c.ecSize[d.wh],H[v.xy]=0,H[v.wh]=t[v.wh]}function _9(r){var e=r.symbolPatternSize,t=ur(r.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function S9(r,e,t,n){var a=r.__pictorialBundle,i=t.symbolSize,o=t.valueLineWidth,s=t.pathPosition,l=e.valueDim,u=t.repeatTimes||0,c=0,f=i[e.valueDim.index]+o+t.symbolMargin*2;for(KN(r,function(y){y.__pictorialAnimationIndex=c,y.__pictorialRepeatTimes=u,c<u?vh(y,null,g(c),t,n):vh(y,null,{scaleX:0,scaleY:0},t,n,function(){a.remove(y)}),c++});c<u;c++){var d=_9(t);d.__pictorialAnimationIndex=c,d.__pictorialRepeatTimes=u,a.add(d);var v=g(c);vh(d,{x:v.x,y:v.y,scaleX:0,scaleY:0},{scaleX:v.scaleX,scaleY:v.scaleY,rotation:v.rotation},t,n)}function g(y){var x=s.slice(),b=t.pxSign,w=y;return(t.symbolRepeatDirection==="start"?b>0:b<0)&&(w=u-1-y),x[l.index]=f*(w-u/2+.5)+s[l.index],{x:x[0],y:x[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation}}}function w9(r,e,t,n){var a=r.__pictorialBundle,i=r.__pictorialMainPath;i?vh(i,null,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation},t,n):(i=r.__pictorialMainPath=_9(t),a.add(i),vh(i,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:0,scaleY:0,rotation:t.rotation},{scaleX:t.symbolScale[0],scaleY:t.symbolScale[1]},t,n))}function T9(r,e,t){var n=ie({},e.barRectShape),a=r.__pictorialBarRect;a?vh(a,null,{shape:n},e,t):(a=r.__pictorialBarRect=new qe({z2:2,shape:n,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),a.disableMorphing=!0,r.add(a))}function C9(r,e,t,n){if(t.symbolClip){var a=r.__pictorialClipPath,i=ie({},t.clipShape),o=e.valueDim,s=t.animationModel,l=t.dataIndex;if(a)lt(a,{shape:i},s,l);else{i[o.wh]=0,a=new qe({shape:i}),r.__pictorialBundle.setClipPath(a),r.__pictorialClipPath=a;var u={};u[o.wh]=t.clipShape[o.wh],_c[n?"updateProps":"initProps"](a,{shape:u},s,l)}}}function Tz(r,e){var t=r.getItemModel(e);return t.getAnimationDelayParams=fye,t.isAnimationEnabled=hye,t}function fye(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function hye(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function Cz(r,e,t,n){var a=new Ne,i=new Ne;return a.add(i),a.__pictorialBundle=i,i.x=t.bundlePosition[0],i.y=t.bundlePosition[1],t.symbolRepeat?S9(a,e,t):w9(a,e,t),T9(a,t,n),C9(a,e,t,n),a.__pictorialShapeStr=A9(r,t),a.__pictorialSymbolMeta=t,a}function dye(r,e,t){var n=t.animationModel,a=t.dataIndex,i=r.__pictorialBundle;lt(i,{x:t.bundlePosition[0],y:t.bundlePosition[1]},n,a),t.symbolRepeat?S9(r,e,t,!0):w9(r,e,t,!0),T9(r,t,!0),C9(r,e,t,!0)}function Az(r,e,t,n){var a=n.__pictorialBarRect;a&&a.removeTextContent();var i=[];KN(n,function(o){i.push(o)}),n.__pictorialMainPath&&i.push(n.__pictorialMainPath),n.__pictorialClipPath&&(t=null),O(i,function(o){Sl(o,{scaleX:0,scaleY:0},t,e,function(){n.parent&&n.parent.remove(n)})}),r.setItemGraphicEl(e,null)}function A9(r,e){return[r.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function KN(r,e,t){O(r.__pictorialBundle.children(),function(n){n!==r.__pictorialBarRect&&e.call(t,n)})}function vh(r,e,t,n,a,i){e&&r.attr(e),n.symbolClip&&!a?t&&r.attr(t):t&&_c[a?"updateProps":"initProps"](r,t,n.animationModel,n.dataIndex,i)}function Mz(r,e,t){var n=t.dataIndex,a=t.itemModel,i=a.getModel("emphasis"),o=i.getModel("itemStyle").getItemStyle(),s=a.getModel(["blur","itemStyle"]).getItemStyle(),l=a.getModel(["select","itemStyle"]).getItemStyle(),u=a.getShallow("cursor"),c=i.get("focus"),f=i.get("blurScope"),d=i.get("scale");KN(r,function(y){if(y instanceof Ir){var x=y.style;y.useStyle(ie({image:x.image,x:x.x,y:x.y,width:x.width,height:x.height},t.style))}else y.useStyle(t.style);var b=y.ensureState("emphasis");b.style=o,d&&(b.scaleX=y.scaleX*1.1,b.scaleY=y.scaleY*1.1),y.ensureState("blur").style=s,y.ensureState("select").style=l,u&&(y.cursor=u),y.z2=t.z2});var v=e.valueDim.posDesc[+(t.boundingLength>0)],g=r.__pictorialBarRect;g.ignoreClip=!0,kr(g,Sr(a),{labelFetcher:e.seriesModel,labelDataIndex:n,defaultText:Gh(e.seriesModel.getData(),n),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:v}),Ut(r,c,f,i.get("disabled"))}function Dz(r){var e=Math.round(r);return Math.abs(r-e)<1e-4?e:Math.ceil(r)}var vye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}return e.prototype.getInitialData=function(t){return t.stack=null,r.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=Rl(pg.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",clip:!1,progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:ee.color.primary}}}),e})(pg);function pye(r){r.registerChartView(oye),r.registerSeriesModel(vye),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,He(WF,"pictorialBar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,XF("pictorialBar"))}var gye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._layers=[],t}return e.prototype.render=function(t,n,a){var i=t.getData(),o=this,s=this.group,l=t.getLayerSeries(),u=i.getLayout("layoutInfo"),c=u.rect,f=u.boundaryGap;s.x=0,s.y=c.y+f[0];function d(x){return x.name}var v=new Qo(this._layersSeries||[],l,d,d),g=[];v.add(xe(y,this,"add")).update(xe(y,this,"update")).remove(xe(y,this,"remove")).execute();function y(x,b,w){var T=o._layers;if(x==="remove"){s.remove(T[b]);return}for(var C=[],D=[],M,N=l[b].indices,R=0;R<N.length;R++){var E=i.getItemLayout(N[R]),k=E.x,I=E.y0,B=E.y;C.push(k,I),D.push(k,I+B),M=i.getItemVisual(N[R],"style")}var P,H=i.getItemLayout(N[0]),V=t.getModel("label"),j=V.get("margin"),U=t.getModel("emphasis");if(x==="add"){var F=g[b]=new Ne;P=new j7({shape:{points:C,stackedOnPoints:D,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),F.add(P),s.add(F),t.isAnimationEnabled()&&P.setClipPath(mye(P.getBoundingRect(),t,function(){P.removeClipPath()}))}else{var F=T[w];P=F.childAt(0),s.add(F),g[b]=F,lt(P,{shape:{points:C,stackedOnPoints:D}},t),ja(P)}kr(P,Sr(t),{labelDataIndex:N[R-1],defaultText:i.getName(N[R-1]),inheritColor:M.fill},{normal:{verticalAlign:"middle"}}),P.setTextConfig({position:null,local:!0});var X=P.getTextContent();X&&(X.x=H.x-j,X.y=H.y0+H.y/2),P.useStyle(M),i.setItemGraphicEl(b,P),_r(P,t),Ut(P,U.get("focus"),U.get("blurScope"),U.get("disabled"))}this._layersSeries=l,this._layers=g},e.type="themeRiver",e})(St);function mye(r,e,t){var n=new qe({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return zt(n,{shape:{x:r.x-50,width:r.width+100,height:r.height+20}},e,t),n}var Q2=2,yye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new md(xe(this.getData,this),xe(this.getRawData,this))},e.prototype.fixData=function(t){var n=t.length,a={},i=LC(t,function(d){return a.hasOwnProperty(d[0]+"")||(a[d[0]+""]=-1),d[2]}),o=[];i.buckets.each(function(d,v){o.push({name:v,dataList:d})});for(var s=o.length,l=0;l<s;++l){for(var u=o[l].name,c=0;c<o[l].dataList.length;++c){var f=o[l].dataList[c][0]+"";a[f]=l}for(var f in a)a.hasOwnProperty(f)&&a[f]!==l&&(a[f]=l,t[n]=[f,0,u],n++)}return t},e.prototype.getInitialData=function(t,n){for(var a=this.getReferringComponents("singleAxis",Zt).models[0],i=a.get("type"),o=dt(t.data,function(g){return g[2]!==void 0}),s=this.fixData(o||[]),l=[],u=this.nameMap=Te(),c=0,f=0;f<s.length;++f)l.push(s[f][Q2]),u.get(s[f][Q2])||(u.set(s[f][Q2],c),c++);var d=hd(s,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:e1(i)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,v=new pn(d,this);return v.initData(s),v},e.prototype.getLayerSeries=function(){for(var t=this.getData(),n=t.count(),a=[],i=0;i<n;++i)a[i]=i;var o=t.mapDimension("single"),s=LC(a,function(u){return t.get("name",u)}),l=[];return s.buckets.each(function(u,c){u.sort(function(f,d){return t.get(o,f)-t.get(o,d)}),l.push({name:c,indices:u})}),l},e.prototype.getAxisTooltipData=function(t,n,a){ce(t)||(t=t?[t]:[]);for(var i=this.getData(),o=this.getLayerSeries(),s=[],l=o.length,u,c=0;c<l;++c){for(var f=Number.MAX_VALUE,d=-1,v=o[c].indices.length,g=0;g<v;++g){var y=i.get(t[0],o[c].indices[g]),x=Math.abs(y-n);x<=f&&(u=y,f=x,d=o[c].indices[g])}s.push(d)}return{dataIndices:s,nestestValue:u}},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=i.getName(t),s=i.get(i.mapDimension("value"),t);return pr("nameValue",{name:o,value:s})},e.type="series.themeRiver",e.dependencies=["singleAxis"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}},e})(Ct);function xye(r,e){r.eachSeriesByType("themeRiver",function(t){var n=t.getData(),a=t.coordinateSystem,i={},o=a.getRect();i.rect=o;var s=t.get("boundaryGap"),l=a.getAxis();if(i.boundaryGap=s,l.orient==="horizontal"){s[0]=me(s[0],o.height),s[1]=me(s[1],o.height);var u=o.height-s[0]-s[1];Nz(n,t,u)}else{s[0]=me(s[0],o.width),s[1]=me(s[1],o.width);var c=o.width-s[0]-s[1];Nz(n,t,c)}n.setLayout("layoutInfo",i)})}function Nz(r,e,t){if(r.count())for(var n=e.coordinateSystem,a=e.getLayerSeries(),i=r.mapDimension("single"),o=r.mapDimension("value"),s=fe(a,function(x){return fe(x.indices,function(b){var w=n.dataToPoint(r.get(i,b));return w[1]=r.get(o,b),w})}),l=bye(s),u=l.y0,c=t/l.max,f=a.length,d=a[0].indices.length,v,g=0;g<d;++g){v=u[g]*c,r.setItemLayout(a[0].indices[g],{layerIndex:0,x:s[0][g][0],y0:v,y:s[0][g][1]*c});for(var y=1;y<f;++y)v+=s[y-1][g][1]*c,r.setItemLayout(a[y].indices[g],{layerIndex:y,x:s[y][g][0],y0:v,y:s[y][g][1]*c})}}function bye(r){for(var e=r.length,t=r[0].length,n=[],a=[],i=0,o=0;o<t;++o){for(var s=0,l=0;l<e;++l)s+=r[l][o][1];s>i&&(i=s),n.push(s)}for(var u=0;u<t;++u)a[u]=(i-n[u])/2;i=0;for(var c=0;c<t;++c){var f=n[c]+a[c];f>i&&(i=f)}return{y0:a,max:i}}function _ye(r){r.registerChartView(gye),r.registerSeriesModel(yye),r.registerLayout(xye),r.registerProcessor(pd("themeRiver"))}var Sye=2,wye=4,Lz=(function(r){K(e,r);function e(t,n,a,i){var o=r.call(this)||this;o.z2=Sye,o.textConfig={inside:!0},je(o).seriesIndex=n.seriesIndex;var s=new ot({z2:wye,silent:t.getModel().get(["label","silent"])});return o.setTextContent(s),o.updateData(!0,t,n,a,i),o}return e.prototype.updateData=function(t,n,a,i,o){this.node=n,n.piece=this,a=a||this._seriesModel,i=i||this._ecModel;var s=this;je(s).dataIndex=n.dataIndex;var l=n.getModel(),u=l.getModel("emphasis"),c=n.getLayout(),f=ie({},c);f.label=null;var d=n.getVisual("style");d.lineJoin="bevel";var v=n.getVisual("decal");v&&(d.decal=zh(v,o));var g=Vi(l.getModel("itemStyle"),f,!0);ie(f,g),O(Cn,function(w){var T=s.ensureState(w),C=l.getModel([w,"itemStyle"]);T.style=C.getItemStyle();var D=Vi(C,f);D&&(T.shape=D)}),t?(s.setShape(f),s.shape.r=c.r0,zt(s,{shape:{r:c.r}},a,n.dataIndex)):(lt(s,{shape:f},a),ja(s)),s.useStyle(d),this._updateLabel(a);var y=l.getShallow("cursor");y&&s.attr("cursor",y),this._seriesModel=a||this._seriesModel,this._ecModel=i||this._ecModel;var x=u.get("focus"),b=x==="relative"?Lh(n.getAncestorsIndices(),n.getDescendantIndices()):x==="ancestor"?n.getAncestorsIndices():x==="descendant"?n.getDescendantIndices():x;Ut(this,b,u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t){var n=this,a=this.node.getModel(),i=a.getModel("label"),o=this.node.getLayout(),s=o.endAngle-o.startAngle,l=(o.startAngle+o.endAngle)/2,u=Math.cos(l),c=Math.sin(l),f=this,d=f.getTextContent(),v=this.node.dataIndex,g=i.get("minAngle")/180*Math.PI,y=i.get("show")&&!(g!=null&&Math.abs(s)<g);d.ignore=!y,O(tg,function(b){var w=b==="normal"?a.getModel("label"):a.getModel([b,"label"]),T=b==="normal",C=T?d:d.ensureState(b),D=t.getFormattedLabel(v,b);T&&(D=D||n.node.name),C.style=Nt(w,{},null,b!=="normal",!0),D&&(C.style.text=D);var M=w.get("show");M!=null&&!T&&(C.ignore=!M);var N=x(w,"position"),R=T?f:f.states[b],E=R.style.fill;R.textConfig={outsideFill:w.get("color")==="inherit"?E:null,inside:N!=="outside"};var k,I=x(w,"distance")||0,B=x(w,"align"),P=x(w,"rotate"),H=Math.PI*.5,V=Math.PI*1.5,j=aa(P==="tangential"?Math.PI/2-l:l),U=j>H&&!kh(j-H)&&j<V;N==="outside"?(k=o.r+I,B=U?"right":"left"):!B||B==="center"?(s===2*Math.PI&&o.r0===0?k=0:k=(o.r+o.r0)/2,B="center"):B==="left"?(k=o.r0+I,B=U?"right":"left"):B==="right"&&(k=o.r-I,B=U?"left":"right"),C.style.align=B,C.style.verticalAlign=x(w,"verticalAlign")||"middle",C.x=k*u+o.cx,C.y=k*c+o.cy;var F=0;P==="radial"?F=aa(-l)+(U?Math.PI:0):P==="tangential"?F=aa(Math.PI/2-l)+(U?Math.PI:0):st(P)&&(F=P*Math.PI/180),C.rotation=aa(F)});function x(b,w){var T=b.get(w);return T??i.get(w)}d.dirtyStyle()},e})(nn),WA="sunburstRootToNode",Rz="sunburstHighlight",Tye="sunburstUnhighlight";function Cye(r){r.registerAction({type:WA,update:"updateView"},function(e,t){t.eachComponent({mainType:"series",subType:"sunburst",query:e},n);function n(a,i){var o=mg(e,[WA],a);if(o){var s=a.getViewRoot();s&&(e.direction=IN(s,o.node)?"rollUp":"drillDown"),a.resetViewRoot(o.node)}}}),r.registerAction({type:Rz,update:"none"},function(e,t,n){e=ie({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},a);function a(i){var o=mg(e,[Rz],i);o&&(e.dataIndex=o.node.dataIndex)}n.dispatchAction(ie(e,{type:"highlight"}))}),r.registerAction({type:Tye,update:"updateView"},function(e,t,n){e=ie({},e),n.dispatchAction(ie(e,{type:"downplay"}))})}var Aye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){var o=this;this.seriesModel=t,this.api=a,this.ecModel=n;var s=t.getData(),l=s.tree.root,u=t.getViewRoot(),c=this.group,f=t.get("renderLabelForZeroData"),d=[];u.eachNode(function(w){d.push(w)});var v=this._oldChildren||[];g(d,v),b(l,u),this._initEvents(),this._oldChildren=d;function g(w,T){if(w.length===0&&T.length===0)return;new Qo(T,w,C,C).add(D).update(D).remove(He(D,null)).execute();function C(M){return M.getId()}function D(M,N){var R=M==null?null:w[M],E=N==null?null:T[N];y(R,E)}}function y(w,T){if(!f&&w&&!w.getValue()&&(w=null),w!==l&&T!==l){if(T&&T.piece)w?(T.piece.updateData(!1,w,t,n,a),s.setItemGraphicEl(w.dataIndex,T.piece)):x(T);else if(w){var C=new Lz(w,t,n,a);c.add(C),s.setItemGraphicEl(w.dataIndex,C)}}}function x(w){w&&w.piece&&(c.remove(w.piece),w.piece=null)}function b(w,T){T.depth>0?(o.virtualPiece?o.virtualPiece.updateData(!1,w,t,n,a):(o.virtualPiece=new Lz(w,t,n,a),c.add(o.virtualPiece)),T.piece.off("click"),o.virtualPiece.on("click",function(C){o._rootToNode(T.parentNode)})):o.virtualPiece&&(c.remove(o.virtualPiece),o.virtualPiece=null)}},e.prototype._initEvents=function(){var t=this;this.group.off("click"),this.group.on("click",function(n){var a=!1,i=t.seriesModel.getViewRoot();i.eachNode(function(o){if(!a&&o.piece&&o.piece===n.target){var s=o.getModel().get("nodeClick");if(s==="rootToNode")t._rootToNode(o);else if(s==="link"){var l=o.getModel(),u=l.get("link");if(u){var c=l.get("target",!0)||"_blank";Ux(u,c)}}a=!0}})})},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:WA,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},e.prototype.containPoint=function(t,n){var a=n.getData(),i=a.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type="sunburst",e})(St),Mye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t,n){var a={name:t.name,children:t.data};M9(a);var i=this._levelModels=fe(t.levels||[],function(l){return new et(l,this,n)},this),o=kN.createTree(a,this,s);function s(l){l.wrapMethod("getItemModel",function(u,c){var f=o.getNodeByDataIndex(c),d=i[f.depth];return d&&(u.parentModel=d),u})}return o.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.getDataParams=function(t){var n=r.prototype.getDataParams.apply(this,arguments),a=this.getData().tree.getNodeByDataIndex(t);return n.treePathInfo=Tb(a,this),n},e.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var n=this.getRawData().tree.root;(!t||t!==n&&!n.contains(t))&&(this._viewRoot=n)},e.prototype.enableAriaDecal=function(){RU(this)},e.type="series.sunburst",e.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},e})(Ct);function M9(r){var e=0;O(r.children,function(n){M9(n);var a=n.value;ce(a)&&(a=a[0]),e+=a});var t=r.value;ce(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),ce(r.value)?r.value[0]=t:r.value=t}var Ez=Math.PI/180;function Dye(r,e,t){e.eachSeriesByType(r,function(n){var a=n.get("center"),i=n.get("radius");ce(i)||(i=[0,i]),ce(a)||(a=[a,a]);var o=t.getWidth(),s=t.getHeight(),l=Math.min(o,s),u=me(a[0],o),c=me(a[1],s),f=me(i[0],l/2),d=me(i[1],l/2),v=-n.get("startAngle")*Ez,g=n.get("minAngle")*Ez,y=n.getData().tree.root,x=n.getViewRoot(),b=x.depth,w=n.get("sort");w!=null&&D9(x,w);var T=0;O(x.children,function(j){!isNaN(j.getValue())&&T++});var C=x.getValue(),D=Math.PI/(C||T)*2,M=x.depth>0,N=x.height-(M?-1:1),R=(d-f)/(N||1),E=n.get("clockwise"),k=n.get("stillShowZeroSum"),I=E?1:-1,B=function(j,U){if(j){var F=U;if(j!==y){var X=j.getValue(),G=C===0&&k?D:X*D;G<g&&(G=g),F=U+I*G;var W=j.depth-b-(M?-1:1),$=f+R*W,te=f+R*(W+1),ue=n.getLevelModel(j);if(ue){var ge=ue.get("r0",!0),Se=ue.get("r",!0),Xe=ue.get("radius",!0);Xe!=null&&(ge=Xe[0],Se=Xe[1]),ge!=null&&($=me(ge,l/2)),Se!=null&&(te=me(Se,l/2))}j.setLayout({angle:G,startAngle:U,endAngle:F,clockwise:E,cx:u,cy:c,r0:$,r:te})}if(j.children&&j.children.length){var be=0;O(j.children,function(we){be+=B(we,U+be)})}return F-U}};if(M){var P=f,H=f+R,V=Math.PI*2;y.setLayout({angle:V,startAngle:v,endAngle:v+V,clockwise:E,cx:u,cy:c,r0:P,r:H})}B(x,v)})}function D9(r,e){var t=r.children||[];r.children=Nye(t,e),t.length&&O(r.children,function(n){D9(n,e)})}function Nye(r,e){if(Me(e)){var t=fe(r,function(a,i){var o=a.getValue();return{params:{depth:a.depth,height:a.height,dataIndex:a.dataIndex,getValue:function(){return o}},index:i}});return t.sort(function(a,i){return e(a.params,i.params)}),fe(t,function(a){return r[a.index]})}else{var n=e==="asc";return r.sort(function(a,i){var o=(a.getValue()-i.getValue())*(n?1:-1);return o===0?(a.dataIndex-i.dataIndex)*(n?-1:1):o})}}function Lye(r){var e={};function t(n,a,i){if(n.depth===0)return ee.color.neutral50;for(var o=n;o&&o.depth>1;)o=o.parentNode;var s=a.getColorFromPalette(o.name||o.dataIndex+"",e);return n.depth>1&&ye(s)&&(s=Lx(s,(n.depth-1)/(i-1)*.5)),s}r.eachSeriesByType("sunburst",function(n){var a=n.getData(),i=a.tree;i.eachNode(function(o){var s=o.getModel(),l=s.getModel("itemStyle").getItemStyle();l.fill||(l.fill=t(o,n,i.root.height));var u=a.ensureUniqueItemVisual(o.dataIndex,"style");ie(u,l)})})}function Rye(r){r.registerChartView(Aye),r.registerSeriesModel(Mye),r.registerLayout(He(Dye,"sunburst")),r.registerProcessor(He(pd,"sunburst")),r.registerVisual(Lye),Cye(r)}var kz={color:"fill",borderColor:"stroke"},Eye={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},Fo=Je(),kye=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},e.prototype.getInitialData=function(t,n){return to(null,this)},e.prototype.getDataParams=function(t,n,a){var i=r.prototype.getDataParams.call(this,t,n);return a&&(i.info=Fo(a).info),i},e.type="series.custom",e.dependencies=["grid","polar","geo","singleAxis","calendar","matrix"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},e})(Ct);function Iye(r,e){return e=e||[0,0],fe(["x","y"],function(t,n){var a=this.getAxis(t),i=e[n],o=r[n]/2;return a.type==="category"?a.getBandWidth():Math.abs(a.dataToCoord(i-o)-a.dataToCoord(i+o))},this)}function Oye(r){var e=r.master.getRect();return{coordSys:{type:"cartesian2d",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:xe(Iye,r)}}}function Pye(r,e){return e=e||[0,0],fe([0,1],function(t){var n=e[t],a=r[t]/2,i=[],o=[];return i[t]=n-a,o[t]=n+a,i[1-t]=o[1-t]=e[1-t],Math.abs(this.dataToPoint(i)[t]-this.dataToPoint(o)[t])},this)}function jye(r){var e=r.getBoundingRect();return{coordSys:{type:"geo",x:e.x,y:e.y,width:e.width,height:e.height,zoom:r.getZoom()},api:{coord:function(t){return r.dataToPoint(t)},size:xe(Pye,r)}}}function zye(r,e){var t=this.getAxis(),n=e instanceof Array?e[0]:e,a=(r instanceof Array?r[0]:r)/2;return t.type==="category"?t.getBandWidth():Math.abs(t.dataToCoord(n-a)-t.dataToCoord(n+a))}function Bye(r){var e=r.getRect();return{coordSys:{type:"singleAxis",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:xe(zye,r)}}}function Vye(r,e){return e=e||[0,0],fe(["Radius","Angle"],function(t,n){var a="get"+t+"Axis",i=this[a](),o=e[n],s=r[n]/2,l=i.type==="category"?i.getBandWidth():Math.abs(i.dataToCoord(o-s)-i.dataToCoord(o+s));return t==="Angle"&&(l=l*Math.PI/180),l},this)}function Gye(r){var e=r.getRadiusAxis(),t=r.getAngleAxis(),n=e.getExtent();return n[0]>n[1]&&n.reverse(),{coordSys:{type:"polar",cx:r.cx,cy:r.cy,r:n[1],r0:n[0]},api:{coord:function(a){var i=e.dataToRadius(a[0]),o=t.dataToAngle(a[1]),s=r.coordToPoint([i,o]);return s.push(i,o*Math.PI/180),s},size:xe(Vye,r)}}}function Hye(r){var e=r.getRect(),t=r.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:r.getCellWidth(),cellHeight:r.getCellHeight(),rangeInfo:{start:t.start,end:t.end,weeks:t.weeks,dayCount:t.allDay}},api:{coord:function(n,a){return r.dataToPoint(n,a)},layout:function(n,a){return r.dataToLayout(n,a)}}}}function Fye(r){var e=r.getRect();return{coordSys:{type:"matrix",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t,n){return r.dataToPoint(t,n)},layout:function(t,n){return r.dataToLayout(t,n)}}}}function N9(r,e,t,n){return r&&(r.legacy||r.legacy!==!1&&!t&&!n&&e!=="tspan"&&(e==="text"||_e(r,"text")))}function L9(r,e,t){var n=r,a,i,o;if(e==="text")o=n;else{o={},_e(n,"text")&&(o.text=n.text),_e(n,"rich")&&(o.rich=n.rich),_e(n,"textFill")&&(o.fill=n.textFill),_e(n,"textStroke")&&(o.stroke=n.textStroke),_e(n,"fontFamily")&&(o.fontFamily=n.fontFamily),_e(n,"fontSize")&&(o.fontSize=n.fontSize),_e(n,"fontStyle")&&(o.fontStyle=n.fontStyle),_e(n,"fontWeight")&&(o.fontWeight=n.fontWeight),i={type:"text",style:o,silent:!0},a={};var s=_e(n,"textPosition");t?a.position=s?n.textPosition:"inside":s&&(a.position=n.textPosition),_e(n,"textPosition")&&(a.position=n.textPosition),_e(n,"textOffset")&&(a.offset=n.textOffset),_e(n,"textRotation")&&(a.rotation=n.textRotation),_e(n,"textDistance")&&(a.distance=n.textDistance)}return Iz(o,r),O(o.rich,function(l){Iz(l,l)}),{textConfig:a,textContent:i}}function Iz(r,e){e&&(e.font=e.textFont||e.font,_e(e,"textStrokeWidth")&&(r.lineWidth=e.textStrokeWidth),_e(e,"textAlign")&&(r.align=e.textAlign),_e(e,"textVerticalAlign")&&(r.verticalAlign=e.textVerticalAlign),_e(e,"textLineHeight")&&(r.lineHeight=e.textLineHeight),_e(e,"textWidth")&&(r.width=e.textWidth),_e(e,"textHeight")&&(r.height=e.textHeight),_e(e,"textBackgroundColor")&&(r.backgroundColor=e.textBackgroundColor),_e(e,"textPadding")&&(r.padding=e.textPadding),_e(e,"textBorderColor")&&(r.borderColor=e.textBorderColor),_e(e,"textBorderWidth")&&(r.borderWidth=e.textBorderWidth),_e(e,"textBorderRadius")&&(r.borderRadius=e.textBorderRadius),_e(e,"textBoxShadowColor")&&(r.shadowColor=e.textBoxShadowColor),_e(e,"textBoxShadowBlur")&&(r.shadowBlur=e.textBoxShadowBlur),_e(e,"textBoxShadowOffsetX")&&(r.shadowOffsetX=e.textBoxShadowOffsetX),_e(e,"textBoxShadowOffsetY")&&(r.shadowOffsetY=e.textBoxShadowOffsetY))}function Oz(r,e,t){var n=r;n.textPosition=n.textPosition||t.position||"inside",t.offset!=null&&(n.textOffset=t.offset),t.rotation!=null&&(n.textRotation=t.rotation),t.distance!=null&&(n.textDistance=t.distance);var a=n.textPosition.indexOf("inside")>=0,i=r.fill||ee.color.neutral99;Pz(n,e);var o=n.textFill==null;return a?o&&(n.textFill=t.insideFill||ee.color.neutral00,!n.textStroke&&t.insideStroke&&(n.textStroke=t.insideStroke),!n.textStroke&&(n.textStroke=i),n.textStrokeWidth==null&&(n.textStrokeWidth=2)):(o&&(n.textFill=r.fill||t.outsideFill||ee.color.neutral00),!n.textStroke&&t.outsideStroke&&(n.textStroke=t.outsideStroke)),n.text=e.text,n.rich=e.rich,O(e.rich,function(s){Pz(s,s)}),n}function Pz(r,e){e&&(_e(e,"fill")&&(r.textFill=e.fill),_e(e,"stroke")&&(r.textStroke=e.fill),_e(e,"lineWidth")&&(r.textStrokeWidth=e.lineWidth),_e(e,"font")&&(r.font=e.font),_e(e,"fontStyle")&&(r.fontStyle=e.fontStyle),_e(e,"fontWeight")&&(r.fontWeight=e.fontWeight),_e(e,"fontSize")&&(r.fontSize=e.fontSize),_e(e,"fontFamily")&&(r.fontFamily=e.fontFamily),_e(e,"align")&&(r.textAlign=e.align),_e(e,"verticalAlign")&&(r.textVerticalAlign=e.verticalAlign),_e(e,"lineHeight")&&(r.textLineHeight=e.lineHeight),_e(e,"width")&&(r.textWidth=e.width),_e(e,"height")&&(r.textHeight=e.height),_e(e,"backgroundColor")&&(r.textBackgroundColor=e.backgroundColor),_e(e,"padding")&&(r.textPadding=e.padding),_e(e,"borderColor")&&(r.textBorderColor=e.borderColor),_e(e,"borderWidth")&&(r.textBorderWidth=e.borderWidth),_e(e,"borderRadius")&&(r.textBorderRadius=e.borderRadius),_e(e,"shadowColor")&&(r.textBoxShadowColor=e.shadowColor),_e(e,"shadowBlur")&&(r.textBoxShadowBlur=e.shadowBlur),_e(e,"shadowOffsetX")&&(r.textBoxShadowOffsetX=e.shadowOffsetX),_e(e,"shadowOffsetY")&&(r.textBoxShadowOffsetY=e.shadowOffsetY),_e(e,"textShadowColor")&&(r.textShadowColor=e.textShadowColor),_e(e,"textShadowBlur")&&(r.textShadowBlur=e.textShadowBlur),_e(e,"textShadowOffsetX")&&(r.textShadowOffsetX=e.textShadowOffsetX),_e(e,"textShadowOffsetY")&&(r.textShadowOffsetY=e.textShadowOffsetY))}var R9={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},jz=it(R9);Ia(Wi,function(r,e){return r[e]=1,r},{});Wi.join(", ");var y1=["","style","shape","extra"],Yh=Je();function QN(r,e,t,n,a){var i=r+"Animation",o=nd(r,n,a)||{},s=Yh(e).userDuring;return o.duration>0&&(o.during=s?xe(qye,{el:e,userDuring:s}):null,o.setToFinal=!0,o.scope=r),ie(o,t[i]),o}function lx(r,e,t,n){n=n||{};var a=n.dataIndex,i=n.isInit,o=n.clearStyle,s=t.isAnimationEnabled(),l=Yh(r),u=e.style;l.userDuring=e.during;var c={},f={};if($ye(r,e,f),r.type==="compound")for(var d=r.shape.paths,v=e.shape.paths,g=0;g<v.length;g++){var y=v[g];J2("shape",y,d[g])}else J2("shape",e,f),J2("extra",e,f);if(!i&&s&&(Zye(r,e,c),zz("shape",r,e,c),zz("extra",r,e,c),Kye(r,e,u,c)),f.style=u,Uye(r,f,o),Wye(r,e),s)if(i){var x={};O(y1,function(w){var T=w?e[w]:e;T&&T.enterFrom&&(w&&(x[w]=x[w]||{}),ie(w?x[w]:x,T.enterFrom))});var b=QN("enter",r,e,t,a);b.duration>0&&r.animateFrom(x,b)}else Yye(r,e,a||0,t,c);E9(r,e),u?r.dirty():r.markRedraw()}function E9(r,e){for(var t=Yh(r).leaveToProps,n=0;n<y1.length;n++){var a=y1[n],i=a?e[a]:e;i&&i.leaveTo&&(t||(t=Yh(r).leaveToProps={}),a&&(t[a]=t[a]||{}),ie(a?t[a]:t,i.leaveTo))}}function Mb(r,e,t,n){if(r){var a=r.parent,i=Yh(r).leaveToProps;if(i){var o=QN("update",r,e,t,0);o.done=function(){a&&a.remove(r)},r.animateTo(i,o)}else a&&a.remove(r)}}function ic(r){return r==="all"}function Uye(r,e,t){var n=e.style;if(!r.isGroup&&n){if(t){r.useStyle({});for(var a=r.animators,i=0;i<a.length;i++){var o=a[i];o.targetName==="style"&&o.changeTarget(r.style)}}r.setStyle(n)}e&&(e.style=null,e&&r.attr(e),e.style=n)}function Yye(r,e,t,n,a){if(a){var i=QN("update",r,e,n,t);i.duration>0&&r.animateFrom(a,i)}}function Wye(r,e){_e(e,"silent")&&(r.silent=e.silent),_e(e,"ignore")&&(r.ignore=e.ignore),r instanceof Pa&&_e(e,"invisible")&&(r.invisible=e.invisible),r instanceof tt&&_e(e,"autoBatch")&&(r.autoBatch=e.autoBatch)}var wi={},Xye={setTransform:function(r,e){return wi.el[r]=e,this},getTransform:function(r){return wi.el[r]},setShape:function(r,e){var t=wi.el,n=t.shape||(t.shape={});return n[r]=e,t.dirtyShape&&t.dirtyShape(),this},getShape:function(r){var e=wi.el.shape;if(e)return e[r]},setStyle:function(r,e){var t=wi.el,n=t.style;return n&&(n[r]=e,t.dirtyStyle&&t.dirtyStyle()),this},getStyle:function(r){var e=wi.el.style;if(e)return e[r]},setExtra:function(r,e){var t=wi.el.extra||(wi.el.extra={});return t[r]=e,this},getExtra:function(r){var e=wi.el.extra;if(e)return e[r]}};function qye(){var r=this,e=r.el;if(e){var t=Yh(e).userDuring,n=r.userDuring;if(t!==n){r.el=r.userDuring=null;return}wi.el=e,n(Xye)}}function zz(r,e,t,n){var a=t[r];if(a){var i=e[r],o;if(i){var s=t.transition,l=a.transition;if(l)if(!o&&(o=n[r]={}),ic(l))ie(o,i);else for(var u=Lt(l),c=0;c<u.length;c++){var f=u[c],d=i[f];o[f]=d}else if(ic(s)||Fe(s,r)>=0){!o&&(o=n[r]={});for(var v=it(i),c=0;c<v.length;c++){var f=v[c],d=i[f];Qye(a[f],d)&&(o[f]=d)}}}}}function J2(r,e,t){var n=e[r];if(n)for(var a=t[r]={},i=it(n),o=0;o<i.length;o++){var s=i[o];a[s]=Np(n[s])}}function Zye(r,e,t){for(var n=e.transition,a=ic(n)?Wi:Lt(n||[]),i=0;i<a.length;i++){var o=a[i];if(!(o==="style"||o==="shape"||o==="extra")){var s=r[o];t[o]=s}}}function $ye(r,e,t){for(var n=0;n<jz.length;n++){var a=jz[n],i=R9[a],o=e[a];o&&(t[i[0]]=o[0],t[i[1]]=o[1])}for(var n=0;n<Wi.length;n++){var s=Wi[n];e[s]!=null&&(t[s]=e[s])}}function Kye(r,e,t,n){if(t){var a=r.style,i;if(a){var o=t.transition,s=e.transition;if(o&&!ic(o)){var l=Lt(o);!i&&(i=n.style={});for(var u=0;u<l.length;u++){var c=l[u],f=a[c];i[c]=f}}else if(r.getAnimationStyleProps&&(ic(s)||ic(o)||Fe(s,"style")>=0)){var d=r.getAnimationStyleProps(),v=d?d.style:null;if(v){!i&&(i=n.style={});for(var g=it(t),u=0;u<g.length;u++){var c=g[u];if(v[c]){var f=a[c];i[c]=f}}}}}}}function Qye(r,e){return tn(r)?r!==e:r!=null&&isFinite(r)}var k9=Je(),Jye=["percent","easing","shape","style","extra"];function I9(r){r.stopAnimation("keyframe"),r.attr(k9(r))}function x1(r,e,t){if(!(!t.isAnimationEnabled()||!e)){if(ce(e)){O(e,function(s){x1(r,s,t)});return}var n=e.keyframes,a=e.duration;if(t&&a==null){var i=nd("enter",t,0);a=i&&i.duration}if(!(!n||!a)){var o=k9(r);O(y1,function(s){if(!(s&&!r[s])){var l;n.sort(function(u,c){return u.percent-c.percent}),O(n,function(u){var c=r.animators,f=s?u[s]:u;if(f){var d=it(f);if(s||(d=dt(d,function(y){return Fe(Jye,y)<0})),!!d.length){l||(l=r.animate(s,e.loop,!0),l.scope="keyframe");for(var v=0;v<c.length;v++)c[v]!==l&&c[v].targetName===l.targetName&&c[v].stopTracks(d);s&&(o[s]=o[s]||{});var g=s?o[s]:o;O(d,function(y){g[y]=((s?r[s]:r)||{})[y]}),l.whenWithKeys(a*u.percent,f,d,u.easing)}}}),l&&l.delay(e.delay||0).duration(a).start(e.easing)}})}}}var Uo="emphasis",il="normal",JN="blur",eL="select",Al=[il,Uo,JN,eL],eT={normal:["itemStyle"],emphasis:[Uo,"itemStyle"],blur:[JN,"itemStyle"],select:[eL,"itemStyle"]},tT={normal:["label"],emphasis:[Uo,"label"],blur:[JN,"label"],select:[eL,"label"]},e0e=["x","y"],t0e="e\0\0",_a={normal:{},emphasis:{},blur:{},select:{}},r0e={cartesian2d:Oye,geo:jye,single:Bye,polar:Gye,calendar:Hye,matrix:Fye};function XA(r){return r instanceof tt}function qA(r){return r instanceof Pa}function n0e(r,e){e.copyTransform(r),qA(e)&&qA(r)&&(e.setStyle(r.style),e.z=r.z,e.z2=r.z2,e.zlevel=r.zlevel,e.invisible=r.invisible,e.ignore=r.ignore,XA(e)&&XA(r)&&e.setShape(r.shape))}var a0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){this._progressiveEls=null;var o=this._data,s=t.getData(),l=this.group,u=Bz(t,s,n,a);o||l.removeAll(),s.diff(o).add(function(f){rT(a,null,f,u(f,i),t,l,s)}).remove(function(f){var d=o.getItemGraphicEl(f);d&&Mb(d,Fo(d).option,t)}).update(function(f,d){var v=o.getItemGraphicEl(d);rT(a,v,f,u(f,i),t,l,s)}).execute();var c=t.get("clip",!0)?tm(t.coordinateSystem,!1,t):null;c?l.setClipPath(c):l.removeClipPath(),this._data=s},e.prototype.incrementalPrepareRender=function(t,n,a){this.group.removeAll(),this._data=null},e.prototype.incrementalRender=function(t,n,a,i,o){var s=n.getData(),l=Bz(n,s,a,i),u=this._progressiveEls=[];function c(v){v.isGroup||(v.incremental=!0,v.ensureState("emphasis").hoverLayer=!0)}for(var f=t.start;f<t.end;f++){var d=rT(null,null,f,l(f,o),n,this.group,s);d&&(d.traverse(c),u.push(d))}},e.prototype.eachRendered=function(t){Ll(this._progressiveEls||this.group,t)},e.prototype.filterForExposedEvent=function(t,n,a,i){var o=n.element;if(o==null||a.name===o)return!0;for(;(a=a.__hostTarget||a.parent)&&a!==this.group;)if(a.name===o)return!0;return!1},e.type="custom",e})(St);function tL(r){var e=r.type,t;if(e==="path"){var n=r.shape,a=n.width!=null&&n.height!=null?{x:n.x||0,y:n.y||0,width:n.width,height:n.height}:null,i=j9(n);t=Oh(i,null,a,n.layout||"center"),Fo(t).customPathData=i}else if(e==="image")t=new Ir({}),Fo(t).customImagePath=r.style.image;else if(e==="text")t=new ot({});else if(e==="group")t=new Ne;else if(e==="compoundPath"){var n=r.shape;if(!n||!n.paths){var o="";gt(o)}var s=fe(n.paths,function(c){if(c.type==="path")return Oh(c.shape.pathData,c,null);var f=ng(c.type);if(!f){var d="";gt(d)}return new f});t=new Xg({shape:{paths:s}})}else{var l=ng(e);if(!l){var o="";gt(o)}t=new l}return Fo(t).customGraphicType=e,t.name=r.name,t.z2EmphasisLift=1,t.z2SelectLift=1,t}function rL(r,e,t,n,a,i,o){I9(e);var s=a&&a.normal.cfg;s&&e.setTextConfig(s),n&&n.transition==null&&(n.transition=e0e);var l=n&&n.style;if(l){if(e.type==="text"){var u=l;_e(u,"textFill")&&(u.fill=u.textFill),_e(u,"textStroke")&&(u.stroke=u.textStroke)}var c=void 0,f=XA(e)?l.decal:null;r&&f&&(f.dirty=!0,c=zh(f,r)),l.__decalPattern=c}if(qA(e)&&l){var c=l.__decalPattern;c&&(l.decal=c)}lx(e,n,i,{dataIndex:t,isInit:o,clearStyle:!0}),x1(e,n.keyframeAnimation,i)}function O9(r,e,t,n,a){var i=e.isGroup?null:e,o=a&&a[r].cfg;if(i){var s=i.ensureState(r);if(n===!1){var l=i.getState(r);l&&(l.style=null)}else s.style=n||null;o&&(s.textConfig=o),fc(i)}}function i0e(r,e,t){if(!r.isGroup){var n=r,a=t.currentZ,i=t.currentZLevel;n.z=a,n.zlevel=i;var o=e.z2;o!=null&&(n.z2=o||0);for(var s=0;s<Al.length;s++)o0e(n,e,Al[s])}}function o0e(r,e,t){var n=t===il,a=n?e:b1(e,t),i=a?a.z2:null,o;i!=null&&(o=n?r:r.ensureState(t),o.z2=i||0)}function Bz(r,e,t,n){var a=r.get("renderItem");if(typeof a=="string"){var i=Jse(a);i&&(a=i)}var o=r.coordinateSystem,s={};o&&(s=o.prepareCustoms?o.prepareCustoms(o):r0e[o.type](o));for(var l=Re({getWidth:n.getWidth,getHeight:n.getHeight,getZr:n.getZr,getDevicePixelRatio:n.getDevicePixelRatio,value:D,style:N,ordinalRawValue:M,styleEmphasis:R,visual:I,barLayout:B,currentSeriesIndices:P,font:H},s.api||{}),u={context:{},seriesId:r.id,seriesName:r.name,seriesIndex:r.seriesIndex,coordSys:s.coordSys,dataInsideLength:e.count(),encode:s0e(r.getData()),itemPayload:r.get("itemPayload")||{}},c,f,d={},v={},g={},y={},x=0;x<Al.length;x++){var b=Al[x];g[b]=r.getModel(eT[b]),y[b]=r.getModel(tT[b])}function w(V){return V===c?f||(f=e.getItemModel(V)):e.getItemModel(V)}function T(V,j){return e.hasItemOption?V===c?d[j]||(d[j]=w(V).getModel(eT[j])):w(V).getModel(eT[j]):g[j]}function C(V,j){return e.hasItemOption?V===c?v[j]||(v[j]=w(V).getModel(tT[j])):w(V).getModel(tT[j]):y[j]}return function(V,j){return c=V,f=null,d={},v={},a&&a(Re({dataIndexInside:V,dataIndex:e.getRawIndex(V),actionType:j?j.type:null},u),l)};function D(V,j){return j==null&&(j=c),e.getStore().get(e.getDimensionIndex(V||0),j)}function M(V,j){j==null&&(j=c),V=V||0;var U=e.getDimensionInfo(V);if(!U){var F=e.getDimensionIndex(V);return F>=0?e.getStore().get(F,j):void 0}var X=e.get(U.name,j),G=U&&U.ordinalMeta;return G?G.categories[X]:X}function N(V,j){j==null&&(j=c);var U=e.getItemVisual(j,"style"),F=U&&U.fill,X=U&&U.opacity,G=T(j,il).getItemStyle();F!=null&&(G.fill=F),X!=null&&(G.opacity=X);var W={inheritColor:ye(F)?F:ee.color.neutral99},$=C(j,il),te=Nt($,null,W,!1,!0);te.text=$.getShallow("show")?Ce(r.getFormattedLabel(j,il),Gh(e,j)):null;var ue=Gx($,W,!1);return k(V,G),G=Oz(G,te,ue),V&&E(G,V),G.legacy=!0,G}function R(V,j){j==null&&(j=c);var U=T(j,Uo).getItemStyle(),F=C(j,Uo),X=Nt(F,null,null,!0,!0);X.text=F.getShallow("show")?zn(r.getFormattedLabel(j,Uo),r.getFormattedLabel(j,il),Gh(e,j)):null;var G=Gx(F,null,!0);return k(V,U),U=Oz(U,X,G),V&&E(U,V),U.legacy=!0,U}function E(V,j){for(var U in j)_e(j,U)&&(V[U]=j[U])}function k(V,j){V&&(V.textFill&&(j.textFill=V.textFill),V.textPosition&&(j.textPosition=V.textPosition))}function I(V,j){if(j==null&&(j=c),_e(kz,V)){var U=e.getItemVisual(j,"style");return U?U[kz[V]]:null}if(_e(Eye,V))return e.getItemVisual(j,V)}function B(V){if(o.type==="cartesian2d"){var j=o.getBaseAxis();return rue(Re({axis:j},V))}}function P(){return t.getCurrentSeriesIndices()}function H(V){return AD(V,t)}}function s0e(r){var e={};return O(r.dimensions,function(t){var n=r.getDimensionInfo(t);if(!n.isExtraCoord){var a=n.coordDim,i=e[a]=e[a]||[];i[n.coordDimIndex]=r.getDimensionIndex(t)}}),e}function rT(r,e,t,n,a,i,o){if(!n){i.remove(e);return}var s=nL(r,e,t,n,a,i);return s&&o.setItemGraphicEl(t,s),s&&Ut(s,n.focus,n.blurScope,n.emphasisDisabled),s}function nL(r,e,t,n,a,i){var o=-1,s=e;e&&P9(e,n,a)&&(o=Fe(i.childrenRef(),e),e=null);var l=!e,u=e;u?u.clearStates():(u=tL(n),s&&n0e(s,u)),n.morph===!1?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),n.tooltipDisabled&&(u.tooltipDisabled=!0),_a.normal.cfg=_a.normal.conOpt=_a.emphasis.cfg=_a.emphasis.conOpt=_a.blur.cfg=_a.blur.conOpt=_a.select.cfg=_a.select.conOpt=null,_a.isLegacy=!1,u0e(u,t,n,a,l,_a),l0e(u,t,n,a,l),rL(r,u,t,n,_a,a,l),_e(n,"info")&&(Fo(u).info=n.info);for(var c=0;c<Al.length;c++){var f=Al[c];if(f!==il){var d=b1(n,f),v=aL(n,d,f);O9(f,u,d,v,_a)}}return i0e(u,n,a),n.type==="group"&&c0e(r,u,t,n,a),o>=0?i.replaceAt(u,o):i.add(u),u}function P9(r,e,t){var n=Fo(r),a=e.type,i=e.shape,o=e.style;return t.isUniversalTransitionEnabled()||a!=null&&a!==n.customGraphicType||a==="path"&&v0e(i)&&j9(i)!==n.customPathData||a==="image"&&_e(o,"image")&&o.image!==n.customImagePath}function l0e(r,e,t,n,a){var i=t.clipPath;if(i===!1)r&&r.getClipPath()&&r.removeClipPath();else if(i){var o=r.getClipPath();o&&P9(o,i,n)&&(o=null),o||(o=tL(i),r.setClipPath(o)),rL(null,o,e,i,null,n,a)}}function u0e(r,e,t,n,a,i){if(!(r.isGroup||r.type==="compoundPath")){Vz(t,null,i),Vz(t,Uo,i);var o=i.normal.conOpt,s=i.emphasis.conOpt,l=i.blur.conOpt,u=i.select.conOpt;if(o!=null||s!=null||u!=null||l!=null){var c=r.getTextContent();if(o===!1)c&&r.removeTextContent();else{o=i.normal.conOpt=o||{type:"text"},c?c.clearStates():(c=tL(o),r.setTextContent(c)),rL(null,c,e,o,null,n,a);for(var f=o&&o.style,d=0;d<Al.length;d++){var v=Al[d];if(v!==il){var g=i[v].conOpt;O9(v,c,g,aL(o,g,v),null)}}f?c.dirty():c.markRedraw()}}}}function Vz(r,e,t){var n=e?b1(r,e):r,a=e?aL(r,n,Uo):r.style,i=r.type,o=n?n.textConfig:null,s=r.textContent,l=s?e?b1(s,e):s:null;if(a&&(t.isLegacy||N9(a,i,!!o,!!l))){t.isLegacy=!0;var u=L9(a,i,!e);!o&&u.textConfig&&(o=u.textConfig),!l&&u.textContent&&(l=u.textContent)}if(!e&&l){var c=l;!c.type&&(c.type="text")}var f=e?t[e]:t.normal;f.cfg=o,f.conOpt=l}function b1(r,e){return e?r?r[e]:null:r}function aL(r,e,t){var n=e&&e.style;return n==null&&t===Uo&&r&&(n=r.styleEmphasis),n}function c0e(r,e,t,n,a){var i=n.children,o=i?i.length:0,s=n.$mergeChildren,l=s==="byName"||n.diffChildrenByName,u=s===!1;if(!(!o&&!l&&!u)){if(l){h0e({api:r,oldChildren:e.children()||[],newChildren:i||[],dataIndex:t,seriesModel:a,group:e});return}u&&e.removeAll();for(var c=0;c<o;c++){var f=i[c],d=e.childAt(c);f?(f.ignore==null&&(f.ignore=!1),nL(r,d,t,f,a,e)):d.ignore=!0}for(var v=e.childCount()-1;v>=c;v--){var g=e.childAt(v);f0e(e,g,a)}}}function f0e(r,e,t){e&&Mb(e,Fo(r).option,t)}function h0e(r){new Qo(r.oldChildren,r.newChildren,Gz,Gz,r).add(Hz).update(Hz).remove(d0e).execute()}function Gz(r,e){var t=r&&r.name;return t??t0e+e}function Hz(r,e){var t=this.context,n=r!=null?t.newChildren[r]:null,a=e!=null?t.oldChildren[e]:null;nL(t.api,a,t.dataIndex,n,t.seriesModel,t.group)}function d0e(r){var e=this.context,t=e.oldChildren[r];t&&Mb(t,Fo(t).option,e.seriesModel)}function j9(r){return r&&(r.pathData||r.d)}function v0e(r){return r&&(_e(r,"pathData")||_e(r,"d"))}function p0e(r){r.registerChartView(a0e),r.registerSeriesModel(kye)}var Iu=Je(),Fz=De,nT=xe,iL=(function(){function r(){this._dragging=!1,this.animationThreshold=15}return r.prototype.render=function(e,t,n,a){var i=t.get("value"),o=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=n,!(!a&&this._lastValue===i&&this._lastStatus===o)){this._lastValue=i,this._lastStatus=o;var s=this._group,l=this._handle;if(!o||o==="hide"){s&&s.hide(),l&&l.hide();return}s&&s.show(),l&&l.show();var u={};this.makeElOption(u,i,e,t,n);var c=u.graphicKey;c!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=c;var f=this._moveAnimation=this.determineAnimation(e,t);if(!s)s=this._group=new Ne,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),n.getZr().add(s);else{var d=He(Uz,t,f);this.updatePointerEl(s,u,d),this.updateLabelEl(s,u,d,t)}Wz(s,t,!0),this._renderHandle(i)}},r.prototype.remove=function(e){this.clear(e)},r.prototype.dispose=function(e){this.clear(e)},r.prototype.determineAnimation=function(e,t){var n=t.get("animation"),a=e.axis,i=a.type==="category",o=t.get("snap");if(!o&&!i)return!1;if(n==="auto"||n==null){var s=this.animationThreshold;if(i&&a.getBandWidth()>s)return!0;if(o){var l=AN(e).seriesDataCount,u=a.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return n===!0},r.prototype.makeElOption=function(e,t,n,a,i){},r.prototype.createPointerEl=function(e,t,n,a){var i=t.pointer;if(i){var o=Iu(e).pointerEl=new _c[i.type](Fz(t.pointer));e.add(o)}},r.prototype.createLabelEl=function(e,t,n,a){if(t.label){var i=Iu(e).labelEl=new ot(Fz(t.label));e.add(i),Yz(i,a)}},r.prototype.updatePointerEl=function(e,t,n){var a=Iu(e).pointerEl;a&&t.pointer&&(a.setStyle(t.pointer.style),n(a,{shape:t.pointer.shape}))},r.prototype.updateLabelEl=function(e,t,n,a){var i=Iu(e).labelEl;i&&(i.setStyle(t.label.style),n(i,{x:t.label.x,y:t.label.y}),Yz(i,a))},r.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,n=this._api.getZr(),a=this._handle,i=t.getModel("handle"),o=t.get("status");if(!i.get("show")||!o||o==="hide"){a&&n.remove(a),this._handle=null;return}var s;this._handle||(s=!0,a=this._handle=ad(i.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){Zo(u.event)},onmousedown:nT(this._onHandleDragMove,this,0,0),drift:nT(this._onHandleDragMove,this),ondragend:nT(this._onHandleDragEnd,this)}),n.add(a)),Wz(a,t,!1),a.setStyle(i.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=i.get("size");ce(l)||(l=[l,l]),a.scaleX=l[0]/2,a.scaleY=l[1]/2,cd(this,"_doDispatchAxisPointer",i.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},r.prototype._moveHandleToValue=function(e,t){Uz(this._axisPointerModel,!t&&this._moveAnimation,this._handle,aT(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(e,t){var n=this._handle;if(n){this._dragging=!0;var a=this.updateHandleTransform(aT(n),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=a,n.stopAnimation(),n.attr(aT(a)),Iu(n).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var e=this._handle;if(e){var t=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var e=this._handle;if(e){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),n=this._group,a=this._handle;t&&n&&(this._lastGraphicKey=null,n&&t.remove(n),a&&t.remove(a),this._group=null,this._handle=null,this._payloadInfo=null),sg(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(e,t,n){return n=n||0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}},r})();function Uz(r,e,t,n){z9(Iu(t).lastProp,n)||(Iu(t).lastProp=n,e?lt(t,n,r):(t.stopAnimation(),t.attr(n)))}function z9(r,e){if(Ee(r)&&Ee(e)){var t=!0;return O(e,function(n,a){t=t&&z9(r[a],n)}),!!t}else return r===e}function Yz(r,e){r[e.get(["label","show"])?"show":"hide"]()}function aT(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function Wz(r,e,t){var n=e.get("z"),a=e.get("zlevel");r&&r.traverse(function(i){i.type!=="group"&&(n!=null&&(i.z=n),a!=null&&(i.zlevel=a),i.silent=t)})}function oL(r){var e=r.get("type"),t=r.getModel(e+"Style"),n;return e==="line"?(n=t.getLineStyle(),n.fill=null):e==="shadow"&&(n=t.getAreaStyle(),n.stroke=null),n}function B9(r,e,t,n,a){var i=t.get("value"),o=V9(i,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),s=t.getModel("label"),l=sd(s.get("padding")||0),u=s.getFont(),c=K1(o,u),f=a.position,d=c.width+l[1]+l[3],v=c.height+l[0]+l[2],g=a.align;g==="right"&&(f[0]-=d),g==="center"&&(f[0]-=d/2);var y=a.verticalAlign;y==="bottom"&&(f[1]-=v),y==="middle"&&(f[1]-=v/2),g0e(f,d,v,n);var x=s.get("backgroundColor");(!x||x==="auto")&&(x=e.get(["axisLine","lineStyle","color"])),r.label={x:f[0],y:f[1],style:Nt(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:x}),z2:10}}function g0e(r,e,t,n){var a=n.getWidth(),i=n.getHeight();r[0]=Math.min(r[0]+e,a)-e,r[1]=Math.min(r[1]+t,i)-t,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function V9(r,e,t,n,a){r=e.scale.parse(r);var i=e.scale.getLabel({value:r},{precision:a.precision}),o=a.formatter;if(o){var s={value:t1(e,{value:r}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};O(n,function(l){var u=t.getSeriesByIndex(l.seriesIndex),c=l.dataIndexInside,f=u&&u.getDataParams(c);f&&s.seriesData.push(f)}),ye(o)?i=o.replace("{value}",i):Me(o)&&(i=o(s))}return i}function sL(r,e,t){var n=Rr();return ns(n,n,t.rotation),ii(n,n,t.position),ti([r.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],n)}function G9(r,e,t,n,a,i){var o=wn.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=a.get(["label","margin"]),B9(e,n,a,i,{position:sL(n.axis,r,t),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function lL(r,e,t){return t=t||0,{x1:r[t],y1:r[1-t],x2:e[t],y2:e[1-t]}}function H9(r,e,t){return t=t||0,{x:r[t],y:r[1-t],width:e[t],height:e[1-t]}}function Xz(r,e,t,n,a,i){return{cx:r,cy:e,r0:t,r:n,startAngle:a,endAngle:i,clockwise:!0}}var m0e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,n,a,i,o){var s=a.axis,l=s.grid,u=i.get("type"),c=qz(l,s).getOtherAxis(s).getGlobalExtent(),f=s.toGlobalCoord(s.dataToCoord(n,!0));if(u&&u!=="none"){var d=oL(i),v=y0e[u](s,f,c);v.style=d,t.graphicKey=v.type,t.pointer=v}var g=f1(l.getRect(),a);G9(n,t,g,a,i,o)},e.prototype.getHandleTransform=function(t,n,a){var i=f1(n.axis.grid.getRect(),n,{labelInside:!1});i.labelMargin=a.get(["handle","margin"]);var o=sL(n.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,n,a,i){var o=a.axis,s=o.grid,l=o.getGlobalExtent(!0),u=qz(s,o).getOtherAxis(o).getGlobalExtent(),c=o.dim==="x"?0:1,f=[t.x,t.y];f[c]+=n[c],f[c]=Math.min(l[1],f[c]),f[c]=Math.max(l[0],f[c]);var d=(u[1]+u[0])/2,v=[d,d];v[c]=f[c];var g=[{verticalAlign:"middle"},{align:"center"}];return{x:f[0],y:f[1],rotation:t.rotation,cursorPoint:v,tooltipOption:g[c]}},e})(iL);function qz(r,e){var t={};return t[e.dim+"AxisIndex"]=e.index,r.getCartesian(t)}var y0e={line:function(r,e,t){var n=lL([e,t[0]],[e,t[1]],Zz(r));return{type:"Line",subPixelOptimize:!0,shape:n}},shadow:function(r,e,t){var n=Math.max(1,r.getBandWidth()),a=t[1]-t[0];return{type:"Rect",shape:H9([e-n/2,t[0]],[n,a],Zz(r))}}};function Zz(r){return r.dim==="x"?0:1}var x0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:ee.color.border,width:1,type:"dashed"},shadowStyle:{color:ee.color.shadowTint},label:{show:!0,formatter:null,precision:"auto",margin:3,color:ee.color.neutral00,padding:[5,7,5,7],backgroundColor:ee.color.accent60,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:ee.color.accent40,throttle:40}},e})(Qe),zo=Je(),b0e=O;function F9(r,e,t){if(!nt.node){var n=e.getZr();zo(n).records||(zo(n).records={}),_0e(n,e);var a=zo(n).records[r]||(zo(n).records[r]={});a.handler=t}}function _0e(r,e){if(zo(r).initialized)return;zo(r).initialized=!0,t("click",He($z,"click")),t("mousemove",He($z,"mousemove")),t("globalout",w0e);function t(n,a){r.on(n,function(i){var o=T0e(e);b0e(zo(r).records,function(s){s&&a(s,i,o.dispatchAction)}),S0e(o.pendings,e)})}}function S0e(r,e){var t=r.showTip.length,n=r.hideTip.length,a;t?a=r.showTip[t-1]:n&&(a=r.hideTip[n-1]),a&&(a.dispatchAction=null,e.dispatchAction(a))}function w0e(r,e,t){r.handler("leave",null,t)}function $z(r,e,t,n){e.handler(r,t,n)}function T0e(r){var e={showTip:[],hideTip:[]},t=function(n){var a=e[n.type];a?a.push(n):(n.dispatchAction=t,r.dispatchAction(n))};return{dispatchAction:t,pendings:e}}function ZA(r,e){if(!nt.node){var t=e.getZr(),n=(zo(t).records||{})[r];n&&(zo(t).records[r]=null)}}var C0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=n.getComponent("tooltip"),o=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";F9("axisPointer",a,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,n){ZA("axisPointer",n)},e.prototype.dispose=function(t,n){ZA("axisPointer",n)},e.type="axisPointer",e})(Rt);function U9(r,e){var t=[],n=r.seriesIndex,a;if(n==null||!(a=e.getSeriesByIndex(n)))return{point:[]};var i=a.getData(),o=uc(i,r);if(o==null||o<0||ce(o))return{point:[]};var s=i.getItemGraphicEl(o),l=a.coordinateSystem;if(a.getTooltipPosition)t=a.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(r.isStacked){var u=l.getBaseAxis(),c=l.getOtherAxis(u),f=c.dim,d=u.dim,v=f==="x"||f==="radius"?1:0,g=i.mapDimension(d),y=[];y[v]=i.get(g,o),y[1-v]=i.get(i.getCalculationInfo("stackResultDimension"),o),t=l.dataToPoint(y)||[]}else t=l.dataToPoint(i.getValues(fe(l.dimensions,function(b){return i.mapDimension(b)}),o))||[];else if(s){var x=s.getBoundingRect().clone();x.applyTransform(s.transform),t=[x.x+x.width/2,x.y+x.height/2]}return{point:t,el:s}}var Kz=Je();function A0e(r,e,t){var n=r.currTrigger,a=[r.x,r.y],i=r,o=r.dispatchAction||xe(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){ux(a)&&(a=U9({seriesIndex:i.seriesIndex,dataIndex:i.dataIndex},e).point);var l=ux(a),u=i.axesInfo,c=s.axesInfo,f=n==="leave"||ux(a),d={},v={},g={list:[],map:{}},y={showPointer:He(D0e,v),showTooltip:He(N0e,g)};O(s.coordSysMap,function(b,w){var T=l||b.containPoint(a);O(s.coordSysAxesInfo[w],function(C,D){var M=C.axis,N=k0e(u,C);if(!f&&T&&(!u||N)){var R=N&&N.value;R==null&&!l&&(R=M.pointToData(a)),R!=null&&Qz(C,R,y,!1,d)}})});var x={};return O(c,function(b,w){var T=b.linkGroup;T&&!v[w]&&O(T.axesInfo,function(C,D){var M=v[D];if(C!==b&&M){var N=M.value;T.mapper&&(N=b.axis.scale.parse(T.mapper(N,Jz(C),Jz(b)))),x[b.key]=N}})}),O(x,function(b,w){Qz(c[w],b,y,!0,d)}),L0e(v,c,d),R0e(g,a,r,o),E0e(c,o,t),d}}function Qz(r,e,t,n,a){var i=r.axis;if(!(i.scale.isBlank()||!i.containData(e))){if(!r.involveSeries){t.showPointer(r,e);return}var o=M0e(e,r),s=o.payloadBatch,l=o.snapToValue;s[0]&&a.seriesIndex==null&&ie(a,s[0]),!n&&r.snap&&i.containData(l)&&l!=null&&(e=l),t.showPointer(r,e,s),t.showTooltip(r,o,l)}}function M0e(r,e){var t=e.axis,n=t.dim,a=r,i=[],o=Number.MAX_VALUE,s=-1;return O(e.seriesModels,function(l,u){var c=l.getData().mapDimensionsAll(n),f,d;if(l.getAxisTooltipData){var v=l.getAxisTooltipData(c,r,t);d=v.dataIndices,f=v.nestestValue}else{if(d=l.indicesOfNearest(n,c[0],r,t.type==="category"?.5:null),!d.length)return;f=l.getData().get(c[0],d[0])}if(!(f==null||!isFinite(f))){var g=r-f,y=Math.abs(g);y<=o&&((y<o||g>=0&&s<0)&&(o=y,s=g,a=f,i.length=0),O(d,function(x){i.push({seriesIndex:l.seriesIndex,dataIndexInside:x,dataIndex:l.getData().getRawIndex(x)})}))}}),{payloadBatch:i,snapToValue:a}}function D0e(r,e,t,n){r[e.key]={value:t,payloadBatch:n}}function N0e(r,e,t,n){var a=t.payloadBatch,i=e.axis,o=i.model,s=e.axisPointerModel;if(!(!e.triggerTooltip||!a.length)){var l=e.coordSys.model,u=gg(l),c=r.map[u];c||(c=r.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},r.list.push(c)),c.dataByAxis.push({axisDim:i.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:n,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:a.slice()})}}function L0e(r,e,t){var n=t.axesInfo=[];O(e,function(a,i){var o=a.axisPointerModel.option,s=r[i];s?(!a.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!a.useHandle&&(o.status="hide"),o.status==="show"&&n.push({axisDim:a.axis.dim,axisIndex:a.axis.model.componentIndex,value:o.value})})}function R0e(r,e,t,n){if(ux(e)||!r.list.length){n({type:"hideTip"});return}var a=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};n({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:t.tooltipOption,position:t.position,dataIndexInside:a.dataIndexInside,dataIndex:a.dataIndex,seriesIndex:a.seriesIndex,dataByCoordSys:r.list})}function E0e(r,e,t){var n=t.getZr(),a="axisPointerLastHighlights",i=Kz(n)[a]||{},o=Kz(n)[a]={};O(r,function(u,c){var f=u.axisPointerModel.option;f.status==="show"&&u.triggerEmphasis&&O(f.seriesDataIndices,function(d){var v=d.seriesIndex+" | "+d.dataIndex;o[v]=d})});var s=[],l=[];O(i,function(u,c){!o[c]&&l.push(u)}),O(o,function(u,c){!i[c]&&s.push(u)}),l.length&&t.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&t.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function k0e(r,e){for(var t=0;t<(r||[]).length;t++){var n=r[t];if(e.axis.dim===n.axisDim&&e.axis.model.componentIndex===n.axisIndex)return n}}function Jz(r){var e=r.axis.model,t={},n=t.axisDim=r.axis.dim;return t.axisIndex=t[n+"AxisIndex"]=e.componentIndex,t.axisName=t[n+"AxisName"]=e.name,t.axisId=t[n+"AxisId"]=e.id,t}function ux(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function am(r){Cc.registerAxisPointerClass("CartesianAxisPointer",m0e),r.registerComponentModel(x0e),r.registerComponentView(C0e),r.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!ce(t)&&(e.axisPointer.link=[t])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=Ihe(e,t)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},A0e)}function I0e(r){We(vU),We(am)}var O0e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,n,a,i,o){var s=a.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=l.getOtherAxis(s),c=u.getExtent(),f=s.dataToCoord(n),d=i.get("type");if(d&&d!=="none"){var v=oL(i),g=j0e[d](s,l,f,c);g.style=v,t.graphicKey=g.type,t.pointer=g}var y=i.get(["label","margin"]),x=P0e(n,a,i,l,y);B9(t,a,i,o,x)},e})(iL);function P0e(r,e,t,n,a){var i=e.axis,o=i.dataToCoord(r),s=n.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=n.getRadiusAxis().getExtent(),u,c,f;if(i.dim==="radius"){var d=Rr();ns(d,d,s),ii(d,d,[n.cx,n.cy]),u=ti([o,-a],d);var v=e.getModel("axisLabel").get("rotate")||0,g=wn.innerTextLayout(s,v*Math.PI/180,-1);c=g.textAlign,f=g.textVerticalAlign}else{var y=l[1];u=n.coordToPoint([y+a,o]);var x=n.cx,b=n.cy;c=Math.abs(u[0]-x)/y<.3?"center":u[0]>x?"left":"right",f=Math.abs(u[1]-b)/y<.3?"middle":u[1]>b?"top":"bottom"}return{position:u,align:c,verticalAlign:f}}var j0e={line:function(r,e,t,n){return r.dim==="angle"?{type:"Line",shape:lL(e.coordToPoint([n[0],t]),e.coordToPoint([n[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(r,e,t,n){var a=Math.max(1,r.getBandWidth()),i=Math.PI/180;return r.dim==="angle"?{type:"Sector",shape:Xz(e.cx,e.cy,n[0],n[1],(-t-a/2)*i,(-t+a/2)*i)}:{type:"Sector",shape:Xz(e.cx,e.cy,t-a/2,t+a/2,0,Math.PI*2)}}},z0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var n,a=this.ecModel;return a.eachComponent(t,function(i){i.getCoordSysModel()===this&&(n=i)},this),n},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e})(Qe),uL=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Zt).models[0]},e.type="polarAxis",e})(Qe);Jt(uL,vd);var B0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e})(uL),V0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e})(uL),cL=(function(r){K(e,r);function e(t,n){return r.call(this,"radius",t,n)||this}return e.prototype.pointToData=function(t,n){return this.polar.pointToData(t,n)[this.dim==="radius"?0:1]},e})(Va);cL.prototype.dataToRadius=Va.prototype.dataToCoord;cL.prototype.radiusToData=Va.prototype.coordToData;var G0e=Je(),fL=(function(r){K(e,r);function e(t,n){return r.call(this,"angle",t,n||[0,360])||this}return e.prototype.pointToData=function(t,n){return this.polar.pointToData(t,n)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,n=t.getLabelModel(),a=t.scale,i=a.getExtent(),o=a.count();if(i[1]-i[0]<1)return 0;var s=i[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l),c=K1(s==null?"":s+"",n.getFont(),"center","top"),f=Math.max(c.height,7),d=f/u;isNaN(d)&&(d=1/0);var v=Math.max(0,Math.floor(d)),g=G0e(t.model),y=g.lastAutoInterval,x=g.lastTickCount;return y!=null&&x!=null&&Math.abs(y-v)<=1&&Math.abs(x-o)<=1&&y>v?v=y:(g.lastTickCount=o,g.lastAutoInterval=v),v},e})(Va);fL.prototype.dataToAngle=Va.prototype.dataToCoord;fL.prototype.angleToData=Va.prototype.coordToData;var Y9=["radius","angle"],H0e=(function(){function r(e){this.dimensions=Y9,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new cL,this._angleAxis=new fL,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return r.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},r.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},r.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},r.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},r.prototype.getAxesByScale=function(e){var t=[],n=this._angleAxis,a=this._radiusAxis;return n.scale.type===e&&t.push(n),a.scale.type===e&&t.push(a),t},r.prototype.getAngleAxis=function(){return this._angleAxis},r.prototype.getRadiusAxis=function(){return this._radiusAxis},r.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},r.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},r.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},r.prototype.dataToPoint=function(e,t,n){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)],n)},r.prototype.pointToData=function(e,t,n){n=n||[];var a=this.pointToCoord(e);return n[0]=this._radiusAxis.radiusToData(a[0],t),n[1]=this._angleAxis.angleToData(a[1],t),n},r.prototype.pointToCoord=function(e){var t=e[0]-this.cx,n=e[1]-this.cy,a=this.getAngleAxis(),i=a.getExtent(),o=Math.min(i[0],i[1]),s=Math.max(i[0],i[1]);a.inverse?o=s-360:s=o+360;var l=Math.sqrt(t*t+n*n);t/=l,n/=l;for(var u=Math.atan2(-n,t)/Math.PI*180,c=u<o?1:-1;u<o||u>s;)u+=c*360;return[l,u]},r.prototype.coordToPoint=function(e,t){t=t||[];var n=e[0],a=e[1]/180*Math.PI;return t[0]=Math.cos(a)*n+this.cx,t[1]=-Math.sin(a)*n+this.cy,t},r.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),n=t.getExtent().slice();n[0]>n[1]&&n.reverse();var a=e.getExtent(),i=Math.PI/180,o=1e-4;return{cx:this.cx,cy:this.cy,r0:n[0],r:n[1],startAngle:-a[0]*i,endAngle:-a[1]*i,clockwise:e.inverse,contain:function(s,l){var u=s-this.cx,c=l-this.cy,f=u*u+c*c,d=this.r,v=this.r0;return d!==v&&f-o<=d*d&&f+o>=v*v},x:this.cx-n[1],y:this.cy-n[1],width:n[1]*2,height:n[1]*2}},r.prototype.convertToPixel=function(e,t,n){var a=eB(t);return a===this?this.dataToPoint(n):null},r.prototype.convertFromPixel=function(e,t,n){var a=eB(t);return a===this?this.pointToData(n):null},r})();function eB(r){var e=r.seriesModel,t=r.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function F0e(r,e,t){var n=e.get("center"),a=Cr(e,t).refContainer;r.cx=me(n[0],a.width)+a.x,r.cy=me(n[1],a.height)+a.y;var i=r.getRadiusAxis(),o=Math.min(a.width,a.height)/2,s=e.get("radius");s==null?s=[0,"100%"]:ce(s)||(s=[0,s]);var l=[me(s[0],o),me(s[1],o)];i.inverse?i.setExtent(l[1],l[0]):i.setExtent(l[0],l[1])}function U0e(r,e){var t=this,n=t.getAngleAxis(),a=t.getRadiusAxis();if(n.scale.setExtent(1/0,-1/0),a.scale.setExtent(1/0,-1/0),r.eachSeries(function(s){if(s.coordinateSystem===t){var l=s.getData();O(r1(l,"radius"),function(u){a.scale.unionExtentFromData(l,u)}),O(r1(l,"angle"),function(u){n.scale.unionExtentFromData(l,u)})}}),pc(n.scale,n.model),pc(a.scale,a.model),n.type==="category"&&!n.onBand){var i=n.getExtent(),o=360/n.scale.count();n.inverse?i[1]+=o:i[1]-=o,n.setExtent(i[0],i[1])}}function Y0e(r){return r.mainType==="angleAxis"}function tB(r,e){var t;if(r.type=e.get("type"),r.scale=Qg(e),r.onBand=e.get("boundaryGap")&&r.type==="category",r.inverse=e.get("inverse"),Y0e(e)){r.inverse=r.inverse!==e.get("clockwise");var n=e.get("startAngle"),a=(t=e.get("endAngle"))!==null&&t!==void 0?t:n+(r.inverse?-360:360);r.setExtent(n,a)}e.axis=r,r.model=e}var W0e={dimensions:Y9,create:function(r,e){var t=[];return r.eachComponent("polar",function(n,a){var i=new H0e(a+"");i.update=U0e;var o=i.getRadiusAxis(),s=i.getAngleAxis(),l=n.findAxisModel("radiusAxis"),u=n.findAxisModel("angleAxis");tB(o,l),tB(s,u),F0e(i,n,e),t.push(i),n.coordinateSystem=i,i.model=n}),r.eachSeries(function(n){if(n.get("coordinateSystem")==="polar"){var a=n.getReferringComponents("polar",Zt).models[0];n.coordinateSystem=a.coordinateSystem}}),t}},X0e=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function C0(r,e,t){e[1]>e[0]&&(e=e.slice().reverse());var n=r.coordToPoint([e[0],t]),a=r.coordToPoint([e[1],t]);return{x1:n[0],y1:n[1],x2:a[0],y2:a[1]}}function A0(r){var e=r.getRadiusAxis();return e.inverse?0:1}function rB(r){var e=r[0],t=r[r.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&r.pop()}var q0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,n){if(this.group.removeAll(),!!t.get("show")){var a=t.axis,i=a.polar,o=i.getRadiusAxis().getExtent(),s=a.getTicksCoords({breakTicks:"none"}),l=a.getMinorTicksCoords(),u=fe(a.getViewLabels(),function(c){c=De(c);var f=a.scale,d=f.type==="ordinal"?f.getRawOrdinalNumber(c.tickValue):c.tickValue;return c.coord=a.dataToCoord(d),c});rB(u),rB(s),O(X0e,function(c){t.get([c,"show"])&&(!a.scale.isBlank()||c==="axisLine")&&Z0e[c](this.group,t,i,s,l,o,u)},this)}},e.type="angleAxis",e})(Cc),Z0e={axisLine:function(r,e,t,n,a,i){var o=e.getModel(["axisLine","lineStyle"]),s=t.getAngleAxis(),l=Math.PI/180,u=s.getExtent(),c=A0(t),f=c?0:1,d,v=Math.abs(u[1]-u[0])===360?"Circle":"Arc";i[f]===0?d=new _c[v]({shape:{cx:t.cx,cy:t.cy,r:i[c],startAngle:-u[0]*l,endAngle:-u[1]*l,clockwise:s.inverse},style:o.getLineStyle(),z2:1,silent:!0}):d=new td({shape:{cx:t.cx,cy:t.cy,r:i[c],r0:i[f]},style:o.getLineStyle(),z2:1,silent:!0}),d.style.fill=null,r.add(d)},axisTick:function(r,e,t,n,a,i){var o=e.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=i[A0(t)],u=fe(n,function(c){return new lr({shape:C0(t,[l,l+s],c.coord)})});r.add(ta(u,{style:Re(o.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(r,e,t,n,a,i){if(a.length){for(var o=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=i[A0(t)],c=[],f=0;f<a.length;f++)for(var d=0;d<a[f].length;d++)c.push(new lr({shape:C0(t,[u,u+l],a[f][d].coord)}));r.add(ta(c,{style:Re(s.getModel("lineStyle").getLineStyle(),Re(o.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(r,e,t,n,a,i,o){var s=e.getCategories(!0),l=e.getModel("axisLabel"),u=l.get("margin"),c=e.get("triggerEvent");O(o,function(f,d){var v=l,g=f.tickValue,y=i[A0(t)],x=t.coordToPoint([y+u,f.coord]),b=t.cx,w=t.cy,T=Math.abs(x[0]-b)/y<.3?"center":x[0]>b?"left":"right",C=Math.abs(x[1]-w)/y<.3?"middle":x[1]>w?"top":"bottom";if(s&&s[g]){var D=s[g];Ee(D)&&D.textStyle&&(v=new et(D.textStyle,l,l.ecModel))}var M=new ot({silent:wn.isLabelSilent(e),style:Nt(v,{x:x[0],y:x[1],fill:v.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:f.formattedLabel,align:T,verticalAlign:C})});if(r.add(M),is({el:M,componentModel:e,itemName:f.formattedLabel,formatterParamsExtra:{isTruncated:function(){return M.isTruncated},value:f.rawLabel,tickIndex:d}}),c){var N=wn.makeAxisEventDataBase(e);N.targetType="axisLabel",N.value=f.rawLabel,je(M).eventData=N}},this)},splitLine:function(r,e,t,n,a,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],f=0;f<n.length;f++){var d=u++%l.length;c[d]=c[d]||[],c[d].push(new lr({shape:C0(t,i,n[f].coord)}))}for(var f=0;f<c.length;f++)r.add(ta(c[f],{style:Re({stroke:l[f%l.length]},s.getLineStyle()),silent:!0,z:e.get("z")}))},minorSplitLine:function(r,e,t,n,a,i){if(a.length){for(var o=e.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=[],u=0;u<a.length;u++)for(var c=0;c<a[u].length;c++)l.push(new lr({shape:C0(t,i,a[u][c].coord)}));r.add(ta(l,{style:s.getLineStyle(),silent:!0,z:e.get("z")}))}},splitArea:function(r,e,t,n,a,i){if(n.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],f=Math.PI/180,d=-n[0].coord*f,v=Math.min(i[0],i[1]),g=Math.max(i[0],i[1]),y=e.get("clockwise"),x=1,b=n.length;x<=b;x++){var w=x===b?n[0].coord:n[x].coord,T=u++%l.length;c[T]=c[T]||[],c[T].push(new nn({shape:{cx:t.cx,cy:t.cy,r0:v,r:g,startAngle:d,endAngle:-w*f,clockwise:y},silent:!0})),d=-w*f}for(var x=0;x<c.length;x++)r.add(ta(c[x],{style:Re({fill:l[x%l.length]},s.getAreaStyle()),silent:!0}))}}},$0e=["splitLine","splitArea","minorSplitLine"],K0e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,n,a){if(this.group.removeAll(),!!t.get("show")){var i=this._axisGroup,o=this._axisGroup=new Ne;this.group.add(o);var s=t.axis,l=s.polar,u=l.getAngleAxis(),c=s.getTicksCoords(),f=s.getMinorTicksCoords(),d=u.getExtent()[0],v=s.getExtent(),g=J0e(l,t,d),y=new wn(t,a,g);y.build(),o.add(y.group),qg(i,o,t),O($0e,function(x){t.get([x,"show"])&&!s.scale.isBlank()&&Q0e[x](this.group,t,l,d,v,c,f)},this)}},e.type="radiusAxis",e})(Cc),Q0e={splitLine:function(r,e,t,n,a,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0,c=t.getAngleAxis(),f=Math.PI/180,d=c.getExtent(),v=Math.abs(d[1]-d[0])===360?"Circle":"Arc";l=l instanceof Array?l:[l];for(var g=[],y=0;y<i.length;y++){var x=u++%l.length;g[x]=g[x]||[],g[x].push(new _c[v]({shape:{cx:t.cx,cy:t.cy,r:Math.max(i[y].coord,0),startAngle:-d[0]*f,endAngle:-d[1]*f,clockwise:c.inverse}}))}for(var y=0;y<g.length;y++)r.add(ta(g[y],{style:Re({stroke:l[y%l.length],fill:null},s.getLineStyle()),silent:!0}))},minorSplitLine:function(r,e,t,n,a,i,o){if(o.length){for(var s=e.getModel("minorSplitLine"),l=s.getModel("lineStyle"),u=[],c=0;c<o.length;c++)for(var f=0;f<o[c].length;f++)u.push(new eo({shape:{cx:t.cx,cy:t.cy,r:o[c][f].coord}}));r.add(ta(u,{style:Re({fill:null},l.getLineStyle()),silent:!0}))}},splitArea:function(r,e,t,n,a,i){if(i.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],f=i[0].coord,d=1;d<i.length;d++){var v=u++%l.length;c[v]=c[v]||[],c[v].push(new nn({shape:{cx:t.cx,cy:t.cy,r0:f,r:i[d].coord,startAngle:0,endAngle:Math.PI*2},silent:!0})),f=i[d].coord}for(var d=0;d<c.length;d++)r.add(ta(c[d],{style:Re({fill:l[d%l.length]},s.getAreaStyle()),silent:!0}))}}};function J0e(r,e,t){return{position:[r.cx,r.cy],rotation:t/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1}}function W9(r){return r.get("stack")||"__ec_stack_"+r.seriesIndex}function X9(r,e){return e.dim+r.model.componentIndex}function exe(r,e,t){var n={},a=txe(dt(e.getSeriesByType(r),function(i){return!e.isSeriesFiltered(i)&&i.coordinateSystem&&i.coordinateSystem.type==="polar"}));e.eachSeriesByType(r,function(i){if(i.coordinateSystem.type==="polar"){var o=i.getData(),s=i.coordinateSystem,l=s.getBaseAxis(),u=X9(s,l),c=W9(i),f=a[u][c],d=f.offset,v=f.width,g=s.getOtherAxis(l),y=i.coordinateSystem.cx,x=i.coordinateSystem.cy,b=i.get("barMinHeight")||0,w=i.get("barMinAngle")||0;n[c]=n[c]||[];for(var T=o.mapDimension(g.dim),C=o.mapDimension(l.dim),D=Jo(o,T),M=l.dim!=="radius"||!i.get("roundCap",!0),N=g.model,R=N.get("startValue"),E=g.dataToCoord(R||0),k=0,I=o.count();k<I;k++){var B=o.get(T,k),P=o.get(C,k),H=B>=0?"p":"n",V=E;D&&(n[c][P]||(n[c][P]={p:E,n:E}),V=n[c][P][H]);var j=void 0,U=void 0,F=void 0,X=void 0;if(g.dim==="radius"){var G=g.dataToCoord(B)-E,W=l.dataToCoord(P);Math.abs(G)<b&&(G=(G<0?-1:1)*b),j=V,U=V+G,F=W-d,X=F-v,D&&(n[c][P][H]=U)}else{var $=g.dataToCoord(B,M)-E,te=l.dataToCoord(P);Math.abs($)<w&&($=($<0?-1:1)*w),j=te+d,U=j+v,F=V,X=V+$,D&&(n[c][P][H]=X)}o.setItemLayout(k,{cx:y,cy:x,r0:j,r:U,startAngle:-F*Math.PI/180,endAngle:-X*Math.PI/180,clockwise:F>=X})}}})}function txe(r){var e={};O(r,function(n,a){var i=n.getData(),o=n.coordinateSystem,s=o.getBaseAxis(),l=X9(o,s),u=s.getExtent(),c=s.type==="category"?s.getBandWidth():Math.abs(u[1]-u[0])/i.count(),f=e[l]||{bandWidth:c,remainedWidth:c,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},d=f.stacks;e[l]=f;var v=W9(n);d[v]||f.autoWidthCount++,d[v]=d[v]||{width:0,maxWidth:0};var g=me(n.get("barWidth"),c),y=me(n.get("barMaxWidth"),c),x=n.get("barGap"),b=n.get("barCategoryGap");g&&!d[v].width&&(g=Math.min(f.remainedWidth,g),d[v].width=g,f.remainedWidth-=g),y&&(d[v].maxWidth=y),x!=null&&(f.gap=x),b!=null&&(f.categoryGap=b)});var t={};return O(e,function(n,a){t[a]={};var i=n.stacks,o=n.bandWidth,s=me(n.categoryGap,o),l=me(n.gap,1),u=n.remainedWidth,c=n.autoWidthCount,f=(u-s)/(c+(c-1)*l);f=Math.max(f,0),O(i,function(y,x){var b=y.maxWidth;b&&b<f&&(b=Math.min(b,u),y.width&&(b=Math.min(b,y.width)),u-=b,y.width=b,c--)}),f=(u-s)/(c+(c-1)*l),f=Math.max(f,0);var d=0,v;O(i,function(y,x){y.width||(y.width=f),v=y,d+=y.width*(1+l)}),v&&(d-=v.width*l);var g=-d/2;O(i,function(y,x){t[a][x]=t[a][x]||{offset:g,width:y.width},g+=y.width*(1+l)})}),t}var rxe={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},nxe={splitNumber:5},axe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="polar",e})(Rt);function ixe(r){We(am),Cc.registerAxisPointerClass("PolarAxisPointer",O0e),r.registerCoordinateSystem("polar",W0e),r.registerComponentModel(z0e),r.registerComponentView(axe),Hh(r,"angle",B0e,rxe),Hh(r,"radius",V0e,nxe),r.registerComponentView(q0e),r.registerComponentView(K0e),r.registerLayout(He(exe,"bar"))}function $A(r,e){e=e||{};var t=r.coordinateSystem,n=r.axis,a={},i=n.position,o=n.orient,s=t.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],u={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};a.position=[o==="vertical"?u.vertical[i]:l[0],o==="horizontal"?u.horizontal[i]:l[3]];var c={horizontal:0,vertical:1};a.rotation=Math.PI/2*c[o];var f={top:-1,bottom:1,right:1,left:-1};a.labelDirection=a.tickDirection=a.nameDirection=f[i],r.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),Fr(e.labelInside,r.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var d=r.get(["axisLabel","rotate"]);return a.labelRotate=i==="top"?-d:d,a.z2=1,a}var oxe=["splitArea","splitLine","breakArea"],sxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="SingleAxisPointer",t}return e.prototype.render=function(t,n,a,i){var o=this.group;o.removeAll();var s=this._axisGroup;this._axisGroup=new Ne;var l=$A(t),u=new wn(t,a,l);u.build(),o.add(this._axisGroup),o.add(u.group),O(oxe,function(c){t.get([c,"show"])&&lxe[c](this,this.group,this._axisGroup,t,a)},this),qg(s,this._axisGroup,t),r.prototype.render.call(this,t,n,a,i)},e.prototype.remove=function(){fU(this)},e.type="singleAxis",e})(Cc),lxe={splitLine:function(r,e,t,n,a){var i=n.axis;if(!i.scale.isBlank()){var o=n.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color");l=l instanceof Array?l:[l];for(var u=s.get("width"),c=n.coordinateSystem.getRect(),f=i.isHorizontal(),d=[],v=0,g=i.getTicksCoords({tickModel:o,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),y=[],x=[],b=0;b<g.length;++b){var w=i.toGlobalCoord(g[b].coord);f?(y[0]=w,y[1]=c.y,x[0]=w,x[1]=c.y+c.height):(y[0]=c.x,y[1]=w,x[0]=c.x+c.width,x[1]=w);var T=new lr({shape:{x1:y[0],y1:y[1],x2:x[0],y2:x[1]},silent:!0});Ph(T.shape,u);var C=v++%l.length;d[C]=d[C]||[],d[C].push(T)}for(var D=s.getLineStyle(["color"]),b=0;b<d.length;++b)e.add(ta(d[b],{style:Re({stroke:l[b%l.length]},D),silent:!0}))}},splitArea:function(r,e,t,n,a){cU(r,t,n,n)},breakArea:function(r,e,t,n,a){var i=nm(),o=n.axis.scale;i&&o.type!=="ordinal"&&i.rectCoordBuildBreakAxis(e,r,n,n.coordinateSystem.getRect(),a)}},cx=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getCoordSysModel=function(){return this},e.type="singleAxis",e.layoutMode="box",e.defaultOption={left:"5%",top:"5%",right:"5%",bottom:"5%",type:"value",position:"bottom",orient:"horizontal",axisLine:{show:!0,lineStyle:{width:1,type:"solid"}},tooltip:{show:!0},axisTick:{show:!0,length:6,lineStyle:{width:1}},axisLabel:{show:!0,interval:"auto"},splitLine:{show:!0,lineStyle:{type:"dashed",opacity:.2}},jitter:0,jitterOverlap:!0,jitterMargin:2},e})(Qe);Jt(cx,vd.prototype);var uxe=(function(r){K(e,r);function e(t,n,a,i,o){var s=r.call(this,t,n,a)||this;return s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.pointToData=function(t,n){return this.coordinateSystem.pointToData(t)[0]},e})(Va),q9=["single"],cxe=(function(){function r(e,t,n){this.type="single",this.dimension="single",this.dimensions=q9,this.axisPointerEnabled=!0,this.model=e,this._init(e,t,n)}return r.prototype._init=function(e,t,n){var a=this.dimension,i=new uxe(a,Qg(e),[0,0],e.get("type"),e.get("position")),o=i.type==="category";i.onBand=o&&e.get("boundaryGap"),i.inverse=e.get("inverse"),i.orient=e.get("orient"),e.axis=i,i.model=e,i.coordinateSystem=this,this._axis=i},r.prototype.update=function(e,t){e.eachSeries(function(n){if(n.coordinateSystem===this){var a=n.getData();O(a.mapDimensionsAll(this.dimension),function(i){this._axis.scale.unionExtentFromData(a,i)},this),pc(this._axis.scale,this._axis.model)}},this)},r.prototype.resize=function(e,t){var n=Cr(e,t).refContainer;this._rect=Ht(e.getBoxLayoutParams(),n),this._adjustAxis()},r.prototype.getRect=function(){return this._rect},r.prototype._adjustAxis=function(){var e=this._rect,t=this._axis,n=t.isHorizontal(),a=n?[0,e.width]:[0,e.height],i=t.inverse?1:0;t.setExtent(a[i],a[1-i]),this._updateAxisTransform(t,n?e.x:e.y)},r.prototype._updateAxisTransform=function(e,t){var n=e.getExtent(),a=n[0]+n[1],i=e.isHorizontal();e.toGlobalCoord=i?function(o){return o+t}:function(o){return a-o+t},e.toLocalCoord=i?function(o){return o-t}:function(o){return a-o+t}},r.prototype.getAxis=function(){return this._axis},r.prototype.getBaseAxis=function(){return this._axis},r.prototype.getAxes=function(){return[this._axis]},r.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},r.prototype.containPoint=function(e){var t=this.getRect(),n=this.getAxis(),a=n.orient;return a==="horizontal"?n.contain(n.toLocalCoord(e[0]))&&e[1]>=t.y&&e[1]<=t.y+t.height:n.contain(n.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},r.prototype.pointToData=function(e,t,n){n=n||[];var a=this.getAxis();return n[0]=a.coordToData(a.toLocalCoord(e[a.orient==="horizontal"?0:1])),n},r.prototype.dataToPoint=function(e,t,n){var a=this.getAxis(),i=this.getRect();n=n||[];var o=a.orient==="horizontal"?0:1;return e instanceof Array&&(e=e[0]),n[o]=a.toGlobalCoord(a.dataToCoord(+e)),n[1-o]=o===0?i.y+i.height/2:i.x+i.width/2,n},r.prototype.convertToPixel=function(e,t,n){var a=nB(t);return a===this?this.dataToPoint(n):null},r.prototype.convertFromPixel=function(e,t,n){var a=nB(t);return a===this?this.pointToData(n):null},r})();function nB(r){var e=r.seriesModel,t=r.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function fxe(r,e){var t=[];return r.eachComponent("singleAxis",function(n,a){var i=new cxe(n,r,e);i.name="single_"+a,i.resize(n,e),n.coordinateSystem=i,t.push(i)}),r.eachSeries(function(n){if(n.get("coordinateSystem")==="singleAxis"){var a=n.getReferringComponents("singleAxis",Zt).models[0];n.coordinateSystem=a&&a.coordinateSystem}}),t}var hxe={create:fxe,dimensions:q9},aB=["x","y"],dxe=["width","height"],vxe=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,n,a,i,o){var s=a.axis,l=s.coordinateSystem,u=iT(l,1-_1(s)),c=l.dataToPoint(n)[0],f=i.get("type");if(f&&f!=="none"){var d=oL(i),v=pxe[f](s,c,u);v.style=d,t.graphicKey=v.type,t.pointer=v}var g=$A(a);G9(n,t,g,a,i,o)},e.prototype.getHandleTransform=function(t,n,a){var i=$A(n,{labelInside:!1});i.labelMargin=a.get(["handle","margin"]);var o=sL(n.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,n,a,i){var o=a.axis,s=o.coordinateSystem,l=_1(o),u=iT(s,l),c=[t.x,t.y];c[l]+=n[l],c[l]=Math.min(u[1],c[l]),c[l]=Math.max(u[0],c[l]);var f=iT(s,1-l),d=(f[1]+f[0])/2,v=[d,d];return v[l]=c[l],{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:v,tooltipOption:{verticalAlign:"middle"}}},e})(iL),pxe={line:function(r,e,t){var n=lL([e,t[0]],[e,t[1]],_1(r));return{type:"Line",subPixelOptimize:!0,shape:n}},shadow:function(r,e,t){var n=r.getBandWidth(),a=t[1]-t[0];return{type:"Rect",shape:H9([e-n/2,t[0]],[n,a],_1(r))}}};function _1(r){return r.isHorizontal()?0:1}function iT(r,e){var t=r.getRect();return[t[aB[e]],t[aB[e]]+t[dxe[e]]]}var gxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e})(Rt);function mxe(r){We(am),Cc.registerAxisPointerClass("SingleAxisPointer",vxe),r.registerComponentView(gxe),r.registerComponentView(sxe),r.registerComponentModel(cx),Hh(r,"single",cx,cx.defaultOption),r.registerCoordinateSystem("single",hxe)}var yxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n,a){var i=Sc(t);r.prototype.init.apply(this,arguments),iB(t,i)},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),iB(this.option,t)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.layoutMode="box",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:ee.color.axisLine,width:1,type:"solid"}},itemStyle:{color:ee.color.neutral00,borderWidth:1,borderColor:ee.color.neutral10},dayLabel:{show:!0,firstDay:0,position:"start",margin:ee.size.s,color:ee.color.secondary},monthLabel:{show:!0,position:"start",margin:ee.size.s,align:"center",formatter:null,color:ee.color.secondary},yearLabel:{show:!0,position:null,margin:ee.size.xl,formatter:null,color:ee.color.quaternary,fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e})(Qe);function iB(r,e){var t=r.cellSize,n;ce(t)?n=t:n=r.cellSize=[t,t],n.length===1&&(n[1]=n[0]);var a=fe([0,1],function(i){return Vie(e,i)&&(n[i]="auto"),n[i]!=null&&n[i]!=="auto"});Zi(r,e,{type:"box",ignoreSize:a})}var xxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){var i=this.group;i.removeAll();var o=t.coordinateSystem,s=o.getRangeInfo(),l=o.getOrient(),u=n.getLocaleModel();this._renderDayRect(t,s,i),this._renderLines(t,s,l,i),this._renderYearText(t,s,l,i),this._renderMonthText(t,u,l,i),this._renderWeekText(t,u,s,l,i)},e.prototype._renderDayRect=function(t,n,a){for(var i=t.coordinateSystem,o=t.getModel("itemStyle").getItemStyle(),s=i.getCellWidth(),l=i.getCellHeight(),u=n.start.time;u<=n.end.time;u=i.getNextNDay(u,1).time){var c=i.dataToCalendarLayout([u],!1).tl,f=new qe({shape:{x:c[0],y:c[1],width:s,height:l},cursor:"default",style:o});a.add(f)}},e.prototype._renderLines=function(t,n,a,i){var o=this,s=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),c=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var f=n.start,d=0;f.time<=n.end.time;d++){g(f.formatedDate),d===0&&(f=s.getDateInfo(n.start.y+"-"+n.start.m));var v=f.date;v.setMonth(v.getMonth()+1),f=s.getDateInfo(v)}g(s.getNextNDay(n.end.time,1).formatedDate);function g(y){o._firstDayOfMonth.push(s.getDateInfo(y)),o._firstDayPoints.push(s.dataToCalendarLayout([y],!1).tl);var x=o._getLinePointsOfOneWeek(t,y,a);o._tlpoints.push(x[0]),o._blpoints.push(x[x.length-1]),u&&o._drawSplitline(x,l,i)}u&&this._drawSplitline(o._getEdgesPoints(o._tlpoints,c,a),l,i),u&&this._drawSplitline(o._getEdgesPoints(o._blpoints,c,a),l,i)},e.prototype._getEdgesPoints=function(t,n,a){var i=[t[0].slice(),t[t.length-1].slice()],o=a==="horizontal"?0:1;return i[0][o]=i[0][o]-n/2,i[1][o]=i[1][o]+n/2,i},e.prototype._drawSplitline=function(t,n,a){var i=new Ur({z2:20,shape:{points:t},style:n});a.add(i)},e.prototype._getLinePointsOfOneWeek=function(t,n,a){for(var i=t.coordinateSystem,o=i.getDateInfo(n),s=[],l=0;l<7;l++){var u=i.getNextNDay(o.time,l),c=i.dataToCalendarLayout([u.time],!1);s[2*u.day]=c.tl,s[2*u.day+1]=c[a==="horizontal"?"bl":"tr"]}return s},e.prototype._formatterLabel=function(t,n){return ye(t)&&t?kie(t,n):Me(t)?t(n):n.nameMap},e.prototype._yearTextPositionControl=function(t,n,a,i,o){var s=n[0],l=n[1],u=["center","bottom"];i==="bottom"?(l+=o,u=["center","top"]):i==="left"?s-=o:i==="right"?(s+=o,u=["center","top"]):l-=o;var c=0;return(i==="left"||i==="right")&&(c=Math.PI/2),{rotation:c,x:s,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,n,a,i){var o=t.getModel("yearLabel");if(o.get("show")){var s=o.get("margin"),l=o.get("position");l||(l=a!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],c=(u[0][0]+u[1][0])/2,f=(u[0][1]+u[1][1])/2,d=a==="horizontal"?0:1,v={top:[c,u[d][1]],bottom:[c,u[1-d][1]],left:[u[1-d][0],f],right:[u[d][0],f]},g=n.start.y;+n.end.y>+n.start.y&&(g=g+"-"+n.end.y);var y=o.get("formatter"),x={start:n.start.y,end:n.end.y,nameMap:g},b=this._formatterLabel(y,x),w=new ot({z2:30,style:Nt(o,{text:b}),silent:o.get("silent")});w.attr(this._yearTextPositionControl(w,v[l],a,l,s)),i.add(w)}},e.prototype._monthTextPositionControl=function(t,n,a,i,o){var s="left",l="top",u=t[0],c=t[1];return a==="horizontal"?(c=c+o,n&&(s="center"),i==="start"&&(l="bottom")):(u=u+o,n&&(l="middle"),i==="start"&&(s="right")),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderMonthText=function(t,n,a,i){var o=t.getModel("monthLabel");if(o.get("show")){var s=o.get("nameMap"),l=o.get("margin"),u=o.get("position"),c=o.get("align"),f=[this._tlpoints,this._blpoints];(!s||ye(s))&&(s&&(n=YC(s)||n),s=n.get(["time","monthAbbr"])||[]);var d=u==="start"?0:1,v=a==="horizontal"?0:1;l=u==="start"?-l:l;for(var g=c==="center",y=o.get("silent"),x=0;x<f[d].length-1;x++){var b=f[d][x].slice(),w=this._firstDayOfMonth[x];if(g){var T=this._firstDayPoints[x];b[v]=(T[v]+f[0][x+1][v])/2}var C=o.get("formatter"),D=s[+w.m-1],M={yyyy:w.y,yy:(w.y+"").slice(2),MM:w.m,M:+w.m,nameMap:D},N=this._formatterLabel(C,M),R=new ot({z2:30,style:ie(Nt(o,{text:N}),this._monthTextPositionControl(b,g,a,u,l)),silent:y});i.add(R)}}},e.prototype._weekTextPositionControl=function(t,n,a,i,o){var s="center",l="middle",u=t[0],c=t[1],f=a==="start";return n==="horizontal"?(u=u+i+(f?1:-1)*o[0]/2,s=f?"right":"left"):(c=c+i+(f?1:-1)*o[1]/2,l=f?"bottom":"top"),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderWeekText=function(t,n,a,i,o){var s=t.getModel("dayLabel");if(s.get("show")){var l=t.coordinateSystem,u=s.get("position"),c=s.get("nameMap"),f=s.get("margin"),d=l.getFirstDayOfWeek();if(!c||ye(c)){c&&(n=YC(c)||n);var v=n.get(["time","dayOfWeekShort"]);c=v||fe(n.get(["time","dayOfWeekAbbr"]),function(M){return M[0]})}var g=l.getNextNDay(a.end.time,7-a.lweek).time,y=[l.getCellWidth(),l.getCellHeight()];f=me(f,Math.min(y[1],y[0])),u==="start"&&(g=l.getNextNDay(a.start.time,-(7+a.fweek)).time,f=-f);for(var x=s.get("silent"),b=0;b<7;b++){var w=l.getNextNDay(g,b),T=l.dataToCalendarLayout([w.time],!1).center,C=b;C=Math.abs((b+d)%7);var D=new ot({z2:30,style:ie(Nt(s,{text:c[C]}),this._weekTextPositionControl(T,i,u,f,y)),silent:x});o.add(D)}}},e.type="calendar",e})(Rt),oT=864e5,bxe=(function(){function r(e,t,n){this.type="calendar",this.dimensions=r.dimensions,this.getDimensionsInfo=r.getDimensionsInfo,this._model=e,this._update(t,n)}return r.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},r.prototype.getRangeInfo=function(){return this._rangeInfo},r.prototype.getModel=function(){return this._model},r.prototype.getRect=function(){return this._rect},r.prototype.getCellWidth=function(){return this._sw},r.prototype.getCellHeight=function(){return this._sh},r.prototype.getOrient=function(){return this._orient},r.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},r.prototype.getDateInfo=function(e){e=Ji(e);var t=e.getFullYear(),n=e.getMonth()+1,a=n<10?"0"+n:""+n,i=e.getDate(),o=i<10?"0"+i:""+i,s=e.getDay();return s=Math.abs((s+7-this.getFirstDayOfWeek())%7),{y:t+"",m:a,d:o,day:s,time:e.getTime(),formatedDate:t+"-"+a+"-"+o,date:e}},r.prototype.getNextNDay=function(e,t){return t=t||0,t===0?this.getDateInfo(e):(e=new Date(this.getDateInfo(e).time),e.setDate(e.getDate()+t),this.getDateInfo(e))},r.prototype._update=function(e,t){this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var n=this._rangeInfo.weeks||1,a=["width","height"],i=this._model.getCellSize().slice(),o=this._model.getBoxLayoutParams(),s=this._orient==="horizontal"?[n,7]:[7,n];O([0,1],function(f){c(i,f)&&(o[a[f]]=i[f]*s[f])});var l={width:t.getWidth(),height:t.getHeight()},u=this._rect=Ht(o,l);O([0,1],function(f){c(i,f)||(i[f]=u[a[f]]/s[f])});function c(f,d){return f[d]!=null&&f[d]!=="auto"}this._sw=i[0],this._sh=i[1]},r.prototype.dataToPoint=function(e,t,n){n=n||[],ce(e)&&(e=e[0]),t==null&&(t=!0);var a=this.getDateInfo(e),i=this._rangeInfo,o=a.formatedDate;if(t&&!(a.time>=i.start.time&&a.time<i.end.time+oT))return n[0]=n[1]=NaN,n;var s=a.day,l=this._getRangeInfo([i.start.time,o]).nthWeek;return this._orient==="vertical"?(n[0]=this._rect.x+s*this._sw+this._sw/2,n[1]=this._rect.y+l*this._sh+this._sh/2):(n[0]=this._rect.x+l*this._sw+this._sw/2,n[1]=this._rect.y+s*this._sh+this._sh/2),n},r.prototype.pointToData=function(e){var t=this.pointToDate(e);return t&&t.time},r.prototype.dataToLayout=function(e,t,n){n=n||{};var a=n.rect=n.rect||{},i=n.contentRect=n.contentRect||{},o=this.dataToPoint(e,t);return a.x=o[0]-this._sw/2,a.y=o[1]-this._sh/2,a.width=this._sw,a.height=this._sh,Oe.copy(i,a),hc(i,this._lineWidth/2,!0,!0),n},r.prototype.dataToCalendarLayout=function(e,t){var n=this.dataToPoint(e,t);return{center:n,tl:[n[0]-this._sw/2,n[1]-this._sh/2],tr:[n[0]+this._sw/2,n[1]-this._sh/2],br:[n[0]+this._sw/2,n[1]+this._sh/2],bl:[n[0]-this._sw/2,n[1]+this._sh/2]}},r.prototype.pointToDate=function(e){var t=Math.floor((e[0]-this._rect.x)/this._sw)+1,n=Math.floor((e[1]-this._rect.y)/this._sh)+1,a=this._rangeInfo.range;return this._orient==="vertical"?this._getDateByWeeksAndDay(n,t-1,a):this._getDateByWeeksAndDay(t,n-1,a)},r.prototype.convertToPixel=function(e,t,n){var a=sT(t);return a===this?a.dataToPoint(n):null},r.prototype.convertToLayout=function(e,t,n){var a=sT(t);return a===this?a.dataToLayout(n):null},r.prototype.convertFromPixel=function(e,t,n){var a=sT(t);return a===this?a.pointToData(n):null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.prototype._initRangeOption=function(){var e=this._model.get("range"),t;if(ce(e)&&e.length===1&&(e=e[0]),ce(e))t=e;else{var n=e.toString();if(/^\d{4}$/.test(n)&&(t=[n+"-01-01",n+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(n)){var a=this.getDateInfo(n),i=a.date;i.setMonth(i.getMonth()+1);var o=this.getNextNDay(i,-1);t=[a.formatedDate,o.formatedDate]}/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(n)&&(t=[n,n])}if(!t)return e;var s=this._getRangeInfo(t);return s.start.time>s.end.time&&t.reverse(),t},r.prototype._getRangeInfo=function(e){var t=[this.getDateInfo(e[0]),this.getDateInfo(e[1])],n;t[0].time>t[1].time&&(n=!0,t.reverse());var a=Math.floor(t[1].time/oT)-Math.floor(t[0].time/oT)+1,i=new Date(t[0].time),o=i.getDate(),s=t[1].date.getDate();i.setDate(o+a-1);var l=i.getDate();if(l!==s)for(var u=i.getTime()-t[1].time>0?1:-1;(l=i.getDate())!==s&&(i.getTime()-t[1].time)*u>0;)a-=u,i.setDate(l-u);var c=Math.floor((a+t[0].day+6)/7),f=n?-c+1:c-1;return n&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:a,weeks:c,nthWeek:f,fweek:t[0].day,lweek:t[1].day}},r.prototype._getDateByWeeksAndDay=function(e,t,n){var a=this._getRangeInfo(n);if(e>a.weeks||e===0&&t<a.fweek||e===a.weeks&&t>a.lweek)return null;var i=(e-1)*7-a.fweek+t,o=new Date(a.start.time);return o.setDate(+a.start.d+i),this.getDateInfo(o)},r.create=function(e,t){var n=[];return e.eachComponent("calendar",function(a){var i=new r(a,e,t);n.push(i),a.coordinateSystem=i}),e.eachComponent(function(a,i){$g({targetModel:i,coordSysType:"calendar",coordSysProvider:d8})}),n},r.dimensions=["time","value"],r})();function sT(r){var e=r.calendarModel,t=r.seriesModel,n=e?e.coordinateSystem:t?t.coordinateSystem:null;return n}function _xe(r){r.registerComponentModel(yxe),r.registerComponentView(xxe),r.registerCoordinateSystem("calendar",bxe)}var ko={level:1,leaf:2,nonLeaf:3},Yo={none:0,all:1,body:2,corner:3};function KA(r,e,t){var n=e[Ge[t]].getCell(r);return!n&&st(r)&&r<0&&(n=e[Ge[1-t]].getUnitLayoutInfo(t,Math.round(r))),n}function Z9(r){var e=r||[];return e[0]=e[0]||[],e[1]=e[1]||[],e[0][0]=e[0][1]=e[1][0]=e[1][1]=NaN,e}function $9(r,e,t,n,a){oB(r[0],e,a,t,n,0),oB(r[1],e,a,t,n,1)}function oB(r,e,t,n,a,i){r[0]=1/0,r[1]=-1/0;var o=n[i],s=ce(o)?o:[o],l=s.length,u=!!t;if(l>=1?(sB(r,e,s,u,a,i,0),l>1&&sB(r,e,s,u,a,i,l-1)):r[0]=r[1]=NaN,u){var c=-a[Ge[1-i]].getLocatorCount(i),f=a[Ge[i]].getLocatorCount(i)-1;t===Yo.body?c=or(0,c):t===Yo.corner&&(f=sa(-1,f)),f<c&&(c=f=NaN),en(r[0])&&(r[0]=c),en(r[1])&&(r[1]=f),r[0]=or(sa(r[0],f),c),r[1]=or(sa(r[1],f),c)}}function sB(r,e,t,n,a,i,o){var s=KA(t[o],a,i);if(!s){r[0]=r[1]=NaN;return}var l=s.id[Ge[i]],u=l,c=Cxe(s);c&&(u+=c.span[Ge[i]]-1),r[0]=sa(r[0],l,u),r[1]=or(r[1],l,u)}function M0(r,e){return en(r[e][0])||en(r[e][1])}function lB(r,e,t,n){e=e||Sxe;for(var a=0;a<n;a++)e[a]=!1;for(;;){for(var i=!1,a=0;a<n;a++){var o=t[a];!e[a]&&o.cellMergeOwner&&wxe(r,o.locatorRange)&&(e[a]=!0,i=!0)}if(!i)break}}var Sxe=[];function wxe(r,e){return!uB(r[0],e[0])||!uB(r[1],e[1])?!1:(r[0][0]=sa(r[0][0],e[0][0]),r[0][1]=or(r[0][1],e[0][1]),r[1][0]=sa(r[1][0],e[1][0]),r[1][1]=or(r[1][1],e[1][1]),!0)}function uB(r,e){return r[1]>=e[0]&&r[0]<=e[1]}function cB(r,e){r.id.set(e[0][0],e[1][0]),r.span.set(e[0][1]-r.id.x+1,e[1][1]-r.id.y+1)}function Txe(r,e){r[0][0]=e[0][0],r[0][1]=e[0][1],r[1][0]=e[1][0],r[1][1]=e[1][1]}function fB(r,e,t,n){var a=KA(e[n][0],t,n),i=KA(e[n][1],t,n);r[Ge[n]]=r[vr[n]]=NaN,a&&i&&(r[Ge[n]]=a.xy,r[vr[n]]=i.xy+i.wh-a.xy)}function Xv(r,e,t,n){return r[Ge[e]]=t,r[Ge[1-e]]=n,r}function Cxe(r){return r&&(r.type===ko.leaf||r.type===ko.nonLeaf)?r:null}function S1(){return{x:NaN,y:NaN,width:NaN,height:NaN}}var hB=(function(){function r(e,t){this._cells=[],this._levels=[],this.dim=e,this.dimIdx=e==="x"?0:1,this._model=t,this._uniqueValueGen=Axe(e);var n=t.get("data",!0);n!=null&&!ce(n)&&(n=[]),n?this._initByDimModelData(n):this._initBySeriesData()}return r.prototype._initByDimModelData=function(e){var t=this,n=t._cells,a=t._levels,i=[],o=0;t._leavesCount=s(e,0,0),l();return;function s(u,c,f){var d=0;return u&&O(u,function(v,g){var y;ye(v)?y={value:v}:Ee(v)?(y=v,v.value!=null&&!ye(v.value)&&(y={value:null})):y={value:null};var x={type:ko.nonLeaf,ordinal:NaN,level:f,firstLeafLocator:c,id:new Ie,span:Xv(new Ie,t.dimIdx,1,1),option:y,xy:NaN,wh:NaN,dim:t,rect:S1()};o++,(i[c]||(i[c]=[])).push(x),a[f]||(a[f]={type:ko.level,xy:NaN,wh:NaN,option:null,id:new Ie,dim:t});var b=s(y.children,c,f+1),w=Math.max(1,b);x.span[Ge[t.dimIdx]]=w,d+=w,c+=w}),d}function l(){for(var u=[];n.length<o;)for(var c=0;c<i.length;c++){var f=i[c].pop();if(f){f.ordinal=u.length;var d=f.option.value;u.push(d),n.push(f),t._uniqueValueGen.calcDupBase(d)}}t._uniqueValueGen.ensureValueUnique(u,n);var v=t._ordinalMeta=new fg({categories:u,needCollect:!1,deduplication:!1});t._scale=new Bh({ordinalMeta:v});for(var g=0;g<t._leavesCount;g++){var y=t._cells[g];y.type=ko.leaf,y.span[Ge[1-t.dimIdx]]=t._levels.length-y.level}t._initCellsId(),t._initLevelIdOptions()}},r.prototype._initBySeriesData=function(){var e=this;e._leavesCount=0,e._levels=[{type:ko.level,xy:NaN,wh:NaN,option:null,id:new Ie,dim:e}],e._initLevelIdOptions();var t=e._ordinalMeta=new fg({needCollect:!0,deduplication:!0,onCollect:function(n,a){var i=e._cells[a]={type:ko.leaf,ordinal:a,level:0,firstLeafLocator:a,id:new Ie,span:Xv(new Ie,e.dimIdx,1,1),option:{value:n+""},xy:NaN,wh:NaN,dim:e,rect:S1()};e._leavesCount++,e._setCellId(i)}});e._scale=new Bh({ordinalMeta:t})},r.prototype._setCellId=function(e){var t=this._levels.length,n=this.dimIdx;Xv(e.id,n,e.firstLeafLocator,e.level-t)},r.prototype._initCellsId=function(){var e=this._levels.length,t=this.dimIdx;O(this._cells,function(n){Xv(n.id,t,n.firstLeafLocator,n.level-e)})},r.prototype._initLevelIdOptions=function(){var e=this._levels.length,t=this.dimIdx,n=this._model.get("levels",!0);n=ce(n)?n:[],O(this._levels,function(a,i){Xv(a.id,t,0,i-e),a.option=n[i]})},r.prototype.shouldShow=function(){return!!this._model.getShallow("show",!0)},r.prototype.resetLayoutIterator=function(e,t,n,a){if(e=e||new fl,t===this.dimIdx){var i=this._leavesCount,o=n!=null?Math.max(0,n):0;a=a!=null?Math.min(a,i):i,e.reset(this._cells,o,o+a)}else{var i=this._levels.length,o=n!=null?Math.max(0,n+i):0;a=a!=null?Math.min(a,i):i,e.reset(this._levels,o,o+a)}return e},r.prototype.resetCellIterator=function(e){return(e||new fl).reset(this._cells,0)},r.prototype.resetLevelIterator=function(e){return(e||new fl).reset(this._levels,0)},r.prototype.getLayout=function(e,t,n){var a=this.getUnitLayoutInfo(t,n);e[Ge[t]]=a?a.xy:NaN,e[vr[t]]=a?a.wh:NaN},r.prototype.getUnitLayoutInfo=function(e,t){return e===this.dimIdx?t<this._leavesCount?this._cells[t]:void 0:this._levels[t+this._levels.length]},r.prototype.getCell=function(e){var t=this._scale.parse(e);return en(t)?void 0:this._cells[t]},r.prototype.getLocatorCount=function(e){return e===this.dimIdx?this._leavesCount:this._levels.length},r.prototype.getOrdinalMeta=function(){return this._ordinalMeta},r})();function Axe(r){var e=r.toUpperCase(),t=new RegExp("^"+e+"([0-9]+)$"),n=0;function a(s){var l;s!=null&&(l=s.match(t))&&(n=or(n,+l[1]+1))}function i(){return""+e+n++}function o(s,l){for(var u=Te(),c=0;c<s.length;c++){var f=s[c];(f==null||u.get(f)!=null)&&(s[c]=f=i(),l[c].option=Re({value:f},l[c].option)),u.set(f,!0)}}return{calcDupBase:a,ensureValueUnique:o}}var dB=(function(){function r(e,t,n){this._model=t,this._dims=n,this._kind=e,this._cellMergeOwnerList=[]}return r.prototype._ensureCellMap=function(){var e=this,t=e._cellMap;return t||(t=e._cellMap=Te(),n()),t;function n(){var i=[],o=e._model.getShallow("data");o&&!ce(o)&&(o=null),O(o,function(g,y){if(!(!Ee(g)||!ce(g.coord))){var x=Z9([]),b=null;if($9(x,b,g.coord,e._dims,g.coordClamp?Yo[e._kind]:Yo.none),!(M0(x,0)||M0(x,1))){var w=g&&g.mergeCells,T={id:new Ie,span:new Ie,locatorRange:x,option:g,cellMergeOwner:w};cB(T,x),i.push(T)}}});for(var s=[],l=0;l<i.length;l++){var u=i[l];if(u.cellMergeOwner){var c=u.locatorRange;lB(c,s,i,l);for(var f=0;f<l;f++)s[f]&&(i[f].cellMergeOwner=!1);if(c[0][0]!==u.id.x||c[1][0]!==u.id.y){u.cellMergeOwner=!1;var d=ie({},u.option);d.coord=null;var v={id:new Ie,span:new Ie,locatorRange:c,option:d,cellMergeOwner:!0};cB(v,c),i.push(v)}}}O(i,function(g){var y=a(g.id.x,g.id.y);if(g.cellMergeOwner&&(y.cellMergeOwner=!0,y.span=g.span,y.locatorRange=g.locatorRange,y.spanRect=S1(),e._cellMergeOwnerList.push(y)),!(!g.cellMergeOwner&&!g.option))for(var x=0;x<g.span.y;x++)for(var b=0;b<g.span.x;b++){var w=a(g.id.x+b,g.id.y+x);w.option=g.option,g.cellMergeOwner&&(w.inSpanOf=y)}})}function a(i,o){var s=vB(i,o),l=t.get(s);return l||(l=t.set(s,{id:new Ie(i,o),option:null,inSpanOf:null,span:null,spanRect:null,locatorRange:null,cellMergeOwner:!1})),l}},r.prototype.getCell=function(e){return this._ensureCellMap().get(vB(e[0],e[1]))},r.prototype.travelExistingCells=function(e){this._ensureCellMap().each(e)},r.prototype.expandRangeByCellMerge=function(e){if(!M0(e,0)&&!M0(e,1)&&e[0][0]===e[0][1]&&e[1][0]===e[1][1]){lT[0]=e[0][0],lT[1]=e[1][0];var t=this.getCell(lT),n=t&&t.inSpanOf;if(n){Txe(e,n.locatorRange);return}}var a=this._cellMergeOwnerList;lB(e,null,a,a.length)},r})(),lT=[];function vB(r,e){return r+"|"+e}var hL={show:!0,color:ee.color.secondary,overflow:"break",lineOverflow:"truncate",padding:[2,3,2,3],distance:0};function dL(r){return{color:"none",borderWidth:1,borderColor:r?"none":ee.color.borderTint}}var pB={show:!0,label:hL,itemStyle:dL(!1),silent:void 0,dividerLineStyle:{width:1,color:ee.color.border}},Mxe={label:hL,itemStyle:dL(!1),silent:void 0},Dxe={label:hL,itemStyle:dL(!0),silent:void 0},Nxe={z:-50,left:"10%",top:"10%",right:"10%",bottom:"10%",x:pB,y:pB,body:Mxe,corner:Dxe,backgroundStyle:{color:"none",borderColor:ee.color.axisLine,borderWidth:1}},Lxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this._dimModels={x:new gB(this.get("x",!0)||{}),y:new gB(this.get("y",!0)||{})};t.x.option.type=t.y.option.type="category";var n=t.x.dim=new hB("x",t.x),a=t.y.dim=new hB("y",t.y),i={x:n,y:a};this._body=new dB("body",new et(this.getShallow("body")),i),this._corner=new dB("corner",new et(this.getShallow("corner")),i)},e.prototype.getDimensionModel=function(t){return this._dimModels[t]},e.prototype.getBody=function(){return this._body},e.prototype.getCorner=function(){return this._corner},e.type="matrix",e.layoutMode="box",e.defaultOption=Nxe,e})(Qe),gB=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getOrdinalMeta=function(){return this.dim.getOrdinalMeta()},e})(et),D0=Math.round,Rxe=0,Exe=99,kxe={normal:25,special:100},Ixe={normal:50,special:125},Oxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n){this.group.removeAll();var a=this.group,i=t.coordinateSystem,o=i.getRect(),s=t.getDimensionModel("x"),l=t.getDimensionModel("y"),u=s.dim,c=l.dim;Pxe(a,t,n),jxe(a,t,u,c,n);var f=t.getShallow("borderZ2",!0),d=Ce(f,Exe),v=d-1,g=t.getModel("backgroundStyle").getItemStyle(["borderWidth"]);g.lineWidth=0;var y=t.getModel("backgroundStyle").getItemStyle(["color","decal","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]);y.fill="none";var x=QA(o.clone(),g,Rxe),b=QA(o.clone(),y,d);x.silent=!0,b.silent=!0,a.add(x),a.add(b);var w=u.getUnitLayoutInfo(0,0),T=c.getUnitLayoutInfo(1,0);w&&T&&(u.shouldShow()&&a.add(mB({x1:o.x,y1:T.xy,x2:o.x+o.width,y2:T.xy},s.getModel("dividerLineStyle").getLineStyle(),v)),c.shouldShow()&&a.add(mB({x1:w.xy,y1:o.y,x2:w.xy,y2:o.y+o.height},l.getModel("dividerLineStyle").getLineStyle(),v)))},e.type="matrix",e})(Rt);function Pxe(r,e,t){n(0),n(1);function n(a){var i=e.getDimensionModel(Ge[a]),o=i.dim;if(o.shouldShow())for(var s=i.getModel("itemStyle"),l=i.getModel("label"),u=e.getShallow("tooltip",!0),c=[],f=o.resetCellIterator();f.next();){var d=f.item,v={};Oe.copy(v,d.rect),q1(c,d.id.x,d.id.y),K9(c,e,r,t,d.option,s,l,i,v,d.option.value,Ixe,u)}}}function jxe(r,e,t,n,a){i("body",e.getBody(),t,n),t.shouldShow()&&n.shouldShow()&&i("corner",e.getCorner(),n,t);function i(o,s,l,u){var c=new et(e.getShallow(o,!0)),f=c.getModel("itemStyle"),d=c.getModel("label"),v=new fl,g=new fl,y=[],x=e.getShallow("tooltip",!0);for(u.resetLayoutIterator(g,1);g.next();)for(l.resetLayoutIterator(v,0);v.next();){var b=v.item,w=g.item;q1(y,b.id.x,w.id.y);var T=s.getCell(y);if(!(T&&T.inSpanOf&&T.inSpanOf!==T)){var C={};T&&T.span?Oe.copy(C,T.spanRect):(b.dim.getLayout(C,0,y[0]),w.dim.getLayout(C,1,y[1]));var D=T?T.option:null;K9(y,e,r,a,D,f,d,c,C,D?D.value:null,kxe,x)}}}}function K9(r,e,t,n,a,i,o,s,l,u,c,f){var d;N0.option=a?a.itemStyle:null,N0.parentModel=i,Pf.option=a,Pf.parentModel=s;var v=Ce(Pf.getShallow("z2"),a&&a.itemStyle?c.special:c.normal),g=f&&f.show,y=QA(l,N0.getItemStyle(),v);t.add(y);var x=Pf.get("cursor");x!=null&&y.attr("cursor",x);var b;if(u!=null){var w=u+"";if(jf.option=a?a.label:null,jf.parentModel=o,jf.ecModel=n,kr(y,{normal:jf},{defaultText:w,autoOverflowArea:!0,layoutRect:De(y.shape)}),b=y.getTextContent(),b){b.z2=v+1;var T=b.style;if(T&&T.overflow&&T.overflow!=="none"&&T.lineOverflow){var C={};Oe.copy(C,l),hc(C,(((d=y.style)===null||d===void 0?void 0:d.lineWidth)||0)/2,!0,!0),y.updateInnerText(),b.getLocalTransform(L0),Oa(L0,L0),Oe.applyTransform(C,C,L0),b.setClipPath(new qe({shape:C}))}}is({el:y,componentModel:e,itemName:w,itemTooltipOption:f,formatterParamsExtra:{xyLocator:r.slice()}})}if(b){var D=jf.get("silent");D==null&&(D=!g),b.silent=D,b.ignoreHostSilent=!0}var M=Pf.get("silent");M==null&&(M=!y.style||y.style.fill==="none"||!y.style.fill),y.silent=M,_w(Pf),_w(N0),_w(jf)}var Pf=new et,N0=new et,jf=new et,L0=[];function QA(r,e,t){var n=e.lineWidth;if(n){var a=r.x+r.width,i=r.y+r.height;r.x=ia(r.x,n,!0),r.y=ia(r.y,n,!0),r.width=ia(a,n,!0)-r.x,r.height=ia(i,n,!0)-r.y}return new qe({shape:r,style:e,z2:t})}function mB(r,e,t){var n=e.lineWidth;return n&&(D0(r.x1*2)===D0(r.x2*2)&&(r.x1=r.x2=ia(r.x1,n,!0)),D0(r.y1*2)===D0(r.y2*2)&&(r.y1=r.y2=ia(r.y1,n,!0))),new lr({shape:r,style:e,silent:!0,z2:t})}var zxe=(function(){function r(e,t,n){this.dimensions=r.dimensions,this.type="matrix",this._model=e;var a=this._dimModels={x:e.getDimensionModel("x"),y:e.getDimensionModel("y")};this._dims={x:a.x.dim,y:a.y.dim},this._resize(e,n)}return r.getDimensionsInfo=function(){return[{name:"x",type:"ordinal"},{name:"y",type:"ordinal"},{name:"value"}]},r.create=function(e,t){var n=[];return e.eachComponent("matrix",function(a){var i=new r(a,e,t);n.push(i),a.coordinateSystem=i}),e.eachComponent(function(a,i){$g({targetModel:i,coordSysType:"matrix",coordSysProvider:d8})}),n},r.prototype.getRect=function(){return this._rect},r.prototype._resize=function(e,t){var n=this._dims,a=this._dimModels,i=this._rect=Ht(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()});yB(a,n,i,0),yB(a,n,i,1),xB(0,n),xB(1,n),bB(this._model.getBody(),n),bB(this._model.getCorner(),n)},r.prototype.dataToPoint=function(e,t,n){return n=n||[],this.dataToLayout(e,t,qv),n[0]=qv.rect.x+qv.rect.width/2,n[1]=qv.rect.y+qv.rect.height/2,n},r.prototype.dataToLayout=function(e,t,n){var a=this._dims;n=n||{};var i=n.rect=n.rect||{};i.x=i.y=i.width=i.height=NaN;var o=n.matrixXYLocatorRange=Z9(n.matrixXYLocatorRange);return ce(e)&&($9(o,null,e,a,Ce(t&&t.clamp,Yo.none)),(!t||!t.ignoreMergeCells)&&((!t||t.clamp!==Yo.corner)&&this._model.getBody().expandRangeByCellMerge(o),(!t||t.clamp!==Yo.body)&&this._model.getCorner().expandRangeByCellMerge(o)),fB(i,o,a,0),fB(i,o,a,1)),n},r.prototype.pointToData=function(e,t,n){var a=this._dims;return _B(_i,0,a,e,t&&t.clamp),_B(_i,1,a,e,t&&t.clamp),n=n||[],n[0]=n[1]=NaN,_i.y===Kr.inCorner&&_i.x===Kr.inBody?SB(_i,n,0,a):_i.x===Kr.inCorner&&_i.y===Kr.inBody?SB(_i,n,1,a):(wB(_i,n,0,a),wB(_i,n,1,a)),n},r.prototype.convertToPixel=function(e,t,n,a){var i=cT(t);return i===this?i.dataToPoint(n,a):void 0},r.prototype.convertToLayout=function(e,t,n,a){var i=cT(t);return i===this?i.dataToLayout(n,a):void 0},r.prototype.convertFromPixel=function(e,t,n,a){var i=cT(t);return i===this?i.pointToData(n,a):void 0},r.prototype.containPoint=function(e){return this._rect.contain(e[0],e[1])},r.dimensions=["x","y","value"],r})(),qv={rect:S1()},R0=new fl,uT=new fl;function yB(r,e,t,n){for(var a=1-n,i=e[Ge[n]],o=e[Ge[a]],s=o.shouldShow(),l=i.resetCellIterator();l.next();)l.item.wh=l.item.xy=NaN;for(var u=o.resetLayoutIterator(null,n);u.next();)u.item.wh=u.item.xy=NaN;for(var c=t[vr[n]],f=i.getLocatorCount(n)+o.getLocatorCount(n),d=new et,v=o.resetLevelIterator();v.next();)d.option=v.item.option,d.parentModel=r[Ge[a]],x(v.item,s?d.get("levelSize"):0);for(var g=new et,y=i.resetCellIterator();y.next();)y.item.type===ko.leaf&&(g.option=y.item.option,g.parentModel=void 0,x(y.item,g.get("size")));function x(N,R){var E=Bxe(R,n,t);en(E)||(N.wh=JA(E,c),c=JA(c-N.wh),f--)}var b=f?c/f:0,w=!f&&c>=1,T=t[Ge[n]],C=i.getLocatorCount(n)-1,D=new fl;for(o.resetLayoutIterator(D,n);D.next();)M(D.item);for(i.resetLayoutIterator(D,n);D.next();)M(D.item);function M(N){en(N.wh)&&(N.wh=b),N.xy=T,N.id[Ge[n]]===C&&!w&&(N.wh=t[Ge[n]]+t[vr[n]]-N.xy),T+=N.wh}}function xB(r,e){for(var t=e[Ge[r]].resetCellIterator();t.next();){var n=t.item;w1(n.rect,r,n.id,n.span,e),w1(n.rect,1-r,n.id,n.span,e),n.type===ko.nonLeaf&&(n.xy=n.rect[Ge[r]],n.wh=n.rect[vr[r]])}}function bB(r,e){r.travelExistingCells(function(t){var n=t.span;if(n){var a=t.spanRect,i=t.id;w1(a,0,i,n,e),w1(a,1,i,n,e)}})}function w1(r,e,t,n,a){r[vr[e]]=0;var i=t[Ge[e]],o=i<0?a[Ge[1-e]]:a[Ge[e]],s=o.getUnitLayoutInfo(e,t[Ge[e]]);if(r[Ge[e]]=s.xy,r[vr[e]]=s.wh,n[Ge[e]]>1){var l=o.getUnitLayoutInfo(e,t[Ge[e]]+n[Ge[e]]-1);r[vr[e]]=l.xy+l.wh-s.xy}}function Bxe(r,e,t){var n=Px(r,t[vr[e]]);return JA(n,t[vr[e]])}function JA(r,e){return Math.max(Math.min(r,Ce(e,1/0)),0)}function cT(r){var e=r.matrixModel,t=r.seriesModel,n=e?e.coordinateSystem:t?t.coordinateSystem:null;return n}var Kr={inBody:1,inCorner:2,outside:3},_i={x:null,y:null,point:[]};function _B(r,e,t,n,a){var i=t[Ge[e]],o=t[Ge[1-e]],s=i.getUnitLayoutInfo(e,i.getLocatorCount(e)-1),l=i.getUnitLayoutInfo(e,0),u=o.getUnitLayoutInfo(e,-o.getLocatorCount(e)),c=o.shouldShow()?o.getUnitLayoutInfo(e,-1):null,f=r.point[e]=n[e];if(!l&&!c){r[Ge[e]]=Kr.outside;return}if(a===Yo.body){l?(r[Ge[e]]=Kr.inBody,f=sa(s.xy+s.wh,or(l.xy,f)),r.point[e]=f):r[Ge[e]]=Kr.outside;return}else if(a===Yo.corner){c?(r[Ge[e]]=Kr.inCorner,f=sa(c.xy+c.wh,or(u.xy,f)),r.point[e]=f):r[Ge[e]]=Kr.outside;return}var d=l?l.xy:c?c.xy+c.wh:NaN,v=u?u.xy:d,g=s?s.xy+s.wh:d;if(f<v){if(!a){r[Ge[e]]=Kr.outside;return}f=v}else if(f>g){if(!a){r[Ge[e]]=Kr.outside;return}f=g}r.point[e]=f,r[Ge[e]]=d<=f&&f<=g?Kr.inBody:v<=f&&f<=d?Kr.inCorner:Kr.outside}function SB(r,e,t,n){var a=1-t;if(r[Ge[t]]!==Kr.outside)for(n[Ge[t]].resetCellIterator(uT);uT.next();){var i=uT.item;if(TB(r.point[t],i.rect,t)&&TB(r.point[a],i.rect,a)){e[t]=i.ordinal,e[a]=i.id[Ge[a]];return}}}function wB(r,e,t,n){if(r[Ge[t]]!==Kr.outside){var a=r[Ge[t]]===Kr.inCorner?n[Ge[1-t]]:n[Ge[t]];for(a.resetLayoutIterator(R0,t);R0.next();)if(Vxe(r.point[t],R0.item)){e[t]=R0.item.id[Ge[t]];return}}}function Vxe(r,e){return e.xy<=r&&r<=e.xy+e.wh}function TB(r,e,t){return e[Ge[t]]<=r&&r<=e[Ge[t]]+e[vr[t]]}function Gxe(r){r.registerComponentModel(Lxe),r.registerComponentView(Oxe),r.registerCoordinateSystem("matrix",zxe)}function Hxe(r,e){var t=r.existing;if(e.id=r.keyInfo.id,!e.type&&t&&(e.type=t.type),e.parentId==null){var n=e.parentOption;n?e.parentId=n.id:t&&(e.parentId=t.parentId)}e.parentOption=null}function CB(r,e){var t;return O(e,function(n){r[n]!=null&&r[n]!=="auto"&&(t=!0)}),t}function Fxe(r,e,t){var n=ie({},t),a=r[e],i=t.$action||"merge";i==="merge"?a?(Ye(a,n,!0),Zi(a,n,{ignoreSize:!0}),y8(t,a),E0(t,a),E0(t,a,"shape"),E0(t,a,"style"),E0(t,a,"extra"),t.clipPath=a.clipPath):r[e]=n:i==="replace"?r[e]=n:i==="remove"&&a&&(r[e]=null)}var Q9=["transition","enterFrom","leaveTo"],Uxe=Q9.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function E0(r,e,t){if(t&&(!r[t]&&e[t]&&(r[t]={}),r=r[t],e=e[t]),!(!r||!e))for(var n=t?Q9:Uxe,a=0;a<n.length;a++){var i=n[a];r[i]==null&&e[i]!=null&&(r[i]=e[i])}}function Yxe(r,e){if(r&&(r.hv=e.hv=[CB(e,["left","right"]),CB(e,["top","bottom"])],r.type==="group")){var t=r,n=e;t.width==null&&(t.width=n.width=0),t.height==null&&(t.height=n.height=0)}}var Wxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.mergeOption=function(t,n){var a=this.option.elements;this.option.elements=null,r.prototype.mergeOption.call(this,t,n),this.option.elements=a},e.prototype.optionUpdated=function(t,n){var a=this.option,i=(n?a:t).elements,o=a.elements=n?[]:a.elements,s=[];this._flatten(i,s,null);var l=lH(o,s,"normalMerge"),u=this._elOptionsToUpdate=[];O(l,function(c,f){var d=c.newOption;d&&(u.push(d),Hxe(c,d),Fxe(o,f,d),Yxe(o[f],d))},this),a.elements=dt(o,function(c){return c&&delete c.$action,c!=null})},e.prototype._flatten=function(t,n,a){O(t,function(i){if(i){a&&(i.parentOption=a),n.push(i);var o=i.children;o&&o.length&&this._flatten(o,n,i),delete i.children}},this)},e.prototype.useElOptionsToUpdate=function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t},e.type="graphic",e.defaultOption={elements:[]},e})(Qe),AB={path:null,compoundPath:null,group:Ne,image:Ir,text:ot},Ma=Je(),Xxe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._elMap=Te()},e.prototype.render=function(t,n,a){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,a)},e.prototype._updateElements=function(t){var n=t.useElOptionsToUpdate();if(n){var a=this._elMap,i=this.group,o=t.get("z"),s=t.get("zlevel");O(n,function(l){var u=xr(l.id,null),c=u!=null?a.get(u):null,f=xr(l.parentId,null),d=f!=null?a.get(f):i,v=l.type,g=l.style;v==="text"&&g&&l.hv&&l.hv[1]&&(g.textVerticalAlign=g.textBaseline=g.verticalAlign=g.align=null);var y=l.textContent,x=l.textConfig;if(g&&N9(g,v,!!x,!!y)){var b=L9(g,v,!0);!x&&b.textConfig&&(x=l.textConfig=b.textConfig),!y&&b.textContent&&(y=b.textContent)}var w=qxe(l),T=l.$action||"merge",C=T==="merge",D=T==="replace";if(C){var M=!c,N=c;M?N=MB(u,d,l.type,a):(N&&(Ma(N).isNew=!1),I9(N)),N&&(lx(N,w,t,{isInit:M}),DB(N,l,o,s))}else if(D){fx(c,l,a,t);var R=MB(u,d,l.type,a);R&&(lx(R,w,t,{isInit:!0}),DB(R,l,o,s))}else T==="remove"&&(E9(c,l),fx(c,l,a,t));var E=a.get(u);if(E&&y)if(C){var k=E.getTextContent();k?k.attr(y):E.setTextContent(new ot(y))}else D&&E.setTextContent(new ot(y));if(E){var I=l.clipPath;if(I){var B=I.type,P=void 0,M=!1;if(C){var H=E.getClipPath();M=!H||Ma(H).type!==B,P=M?eM(B):H}else D&&(M=!0,P=eM(B));E.setClipPath(P),lx(P,I,t,{isInit:M}),x1(P,I.keyframeAnimation,t)}var V=Ma(E);E.setTextConfig(x),V.option=l,Zxe(E,t,l),is({el:E,componentModel:t,itemName:E.name,itemTooltipOption:l.tooltip}),x1(E,l.keyframeAnimation,t)}})}},e.prototype._relocate=function(t,n){for(var a=t.option.elements,i=this.group,o=this._elMap,s=n.getWidth(),l=n.getHeight(),u=["x","y"],c=0;c<a.length;c++){var f=a[c],d=xr(f.id,null),v=d!=null?o.get(d):null;if(!(!v||!v.isGroup)){var g=v.parent,y=g===i,x=Ma(v),b=Ma(g);x.width=me(x.option.width,y?s:b.width)||0,x.height=me(x.option.height,y?l:b.height)||0}}for(var c=a.length-1;c>=0;c--){var f=a[c],d=xr(f.id,null),v=d!=null?o.get(d):null;if(v){var g=v.parent,b=Ma(g),w=g===i?{width:s,height:l}:{width:b.width,height:b.height},T={},C=fb(v,f,w,null,{hv:f.hv,boundingMode:f.bounding},T);if(!Ma(v).isNew&&C){for(var D=f.transition,M={},N=0;N<u.length;N++){var R=u[N],E=T[R];D&&(ic(D)||Fe(D,R)>=0)?M[R]=E:v[R]=E}lt(v,M,t,0)}else v.attr(T)}}},e.prototype._clear=function(){var t=this,n=this._elMap;n.each(function(a){fx(a,Ma(a).option,n,t._lastGraphicModel)}),this._elMap=Te()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e})(Rt);function eM(r){var e=_e(AB,r)?AB[r]:ng(r),t=new e({});return Ma(t).type=r,t}function MB(r,e,t,n){var a=eM(t);return e.add(a),n.set(r,a),Ma(a).id=r,Ma(a).isNew=!0,a}function fx(r,e,t,n){var a=r&&r.parent;a&&(r.type==="group"&&r.traverse(function(i){fx(i,e,t,n)}),Mb(r,e,n),t.removeKey(Ma(r).id))}function DB(r,e,t,n){r.isGroup||O([["cursor",Pa.prototype.cursor],["zlevel",n||0],["z",t||0],["z2",0]],function(a){var i=a[0];_e(e,i)?r[i]=Ce(e[i],a[1]):r[i]==null&&(r[i]=a[1])}),O(it(e),function(a){if(a.indexOf("on")===0){var i=e[a];r[a]=Me(i)?i:null}}),_e(e,"draggable")&&(r.draggable=e.draggable),e.name!=null&&(r.name=e.name),e.id!=null&&(r.id=e.id)}function qxe(r){return r=ie({},r),O(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(v8),function(e){delete r[e]}),r}function Zxe(r,e,t){var n=je(r).eventData;!r.silent&&!r.ignore&&!n&&(n=je(r).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:r.name}),n&&(n.info=t.info)}function $xe(r){r.registerComponentModel(Wxe),r.registerComponentView(Xxe),r.registerPreprocessor(function(e){var t=e.graphic;ce(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var NB=["x","y","radius","angle","single"],Kxe=["cartesian2d","polar","singleAxis"];function Qxe(r){var e=r.get("coordinateSystem");return Fe(Kxe,e)>=0}function ol(r){return r+"Axis"}function Jxe(r,e){var t=Te(),n=[],a=Te();r.eachComponent({mainType:"dataZoom",query:e},function(c){a.get(c.uid)||s(c)});var i;do i=!1,r.eachComponent("dataZoom",o);while(i);function o(c){!a.get(c.uid)&&l(c)&&(s(c),i=!0)}function s(c){a.set(c.uid,!0),n.push(c),u(c)}function l(c){var f=!1;return c.eachTargetAxis(function(d,v){var g=t.get(d);g&&g[v]&&(f=!0)}),f}function u(c){c.eachTargetAxis(function(f,d){(t.get(f)||t.set(f,[]))[d]=!0})}return n}function J9(r){var e=r.ecModel,t={infoList:[],infoMap:Te()};return r.eachTargetAxis(function(n,a){var i=e.getComponent(ol(n),a);if(i){var o=i.getCoordSysModel();if(o){var s=o.uid,l=t.infoMap.get(s);l||(l={model:o,axisModels:[]},t.infoList.push(l),t.infoMap.set(s,l)),l.axisModels.push(i)}}}),t}var fT=(function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},r})(),Sg=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}return e.prototype.init=function(t,n,a){var i=LB(t);this.settledOption=i,this.mergeDefaultAndTheme(t,a),this._doInit(i)},e.prototype.mergeOption=function(t){var n=LB(t);Ye(this.option,t,!0),Ye(this.settledOption,n,!0),this._doInit(n)},e.prototype._doInit=function(t){var n=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var a=this.settledOption;O([["start","startValue"],["end","endValue"]],function(i,o){this._rangePropMode[o]==="value"&&(n[i[0]]=a[i[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),n=this._targetAxisInfoMap=Te(),a=this._fillSpecifiedTargetAxis(n);a?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(n,this._orient)),this._noTarget=!0,n.each(function(i){i.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var n=!1;return O(NB,function(a){var i=this.getReferringComponents(ol(a),mne);if(i.specified){n=!0;var o=new fT;O(i.models,function(s){o.add(s.componentIndex)}),t.set(a,o)}},this),n},e.prototype._fillAutoTargetAxisByOrient=function(t,n){var a=this.ecModel,i=!0;if(i){var o=n==="vertical"?"y":"x",s=a.findComponents({mainType:o+"Axis"});l(s,o)}if(i){var s=a.findComponents({mainType:"singleAxis",filter:function(c){return c.get("orient",!0)===n}});l(s,"single")}function l(u,c){var f=u[0];if(f){var d=new fT;if(d.add(f.componentIndex),t.set(c,d),i=!1,c==="x"||c==="y"){var v=f.getReferringComponents("grid",Zt).models[0];v&&O(u,function(g){f.componentIndex!==g.componentIndex&&v===g.getReferringComponents("grid",Zt).models[0]&&d.add(g.componentIndex)})}}}i&&O(NB,function(u){if(i){var c=a.findComponents({mainType:ol(u),filter:function(d){return d.get("type",!0)==="category"}});if(c[0]){var f=new fT;f.add(c[0].componentIndex),t.set(u,f),i=!1}}},this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis(function(n){!t&&(t=n)},this),t==="y"?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var n=this.ecModel.option;this.option.throttle=n.animation&&n.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var n=this._rangePropMode,a=this.get("rangeMode");O([["start","startValue"],["end","endValue"]],function(i,o){var s=t[i[0]]!=null,l=t[i[1]]!=null;s&&!l?n[o]="percent":!s&&l?n[o]="value":a?n[o]=a[o]:s&&(n[o]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(n,a){t==null&&(t=this.ecModel.getComponent(ol(n),a))},this),t},e.prototype.eachTargetAxis=function(t,n){this._targetAxisInfoMap.each(function(a,i){O(a.indexList,function(o){t.call(n,i,o)})})},e.prototype.getAxisProxy=function(t,n){var a=this.getAxisModel(t,n);if(a)return a.__dzAxisProxy},e.prototype.getAxisModel=function(t,n){var a=this._targetAxisInfoMap.get(t);if(a&&a.indexMap[n])return this.ecModel.getComponent(ol(t),n)},e.prototype.setRawRange=function(t){var n=this.option,a=this.settledOption;O([["start","startValue"],["end","endValue"]],function(i){(t[i[0]]!=null||t[i[1]]!=null)&&(n[i[0]]=a[i[0]]=t[i[0]],n[i[1]]=a[i[1]]=t[i[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var n=this.option;O(["start","startValue","end","endValue"],function(a){n[a]=t[a]})},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},e.prototype.getValueRange=function(t,n){if(t==null&&n==null){var a=this.findRepresentativeAxisProxy();if(a)return a.getDataValueWindow()}else return this.getAxisProxy(t,n).getDataValueWindow()},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var n,a=this._targetAxisInfoMap.keys(),i=0;i<a.length;i++)for(var o=a[i],s=this._targetAxisInfoMap.get(o),l=0;l<s.indexList.length;l++){var u=this.getAxisProxy(o,s.indexList[l]);if(u.hostedBy(this))return u;n||(n=u)}return n},e.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},e.prototype.getOrient=function(){return this._orient},e.type="dataZoom",e.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],e.defaultOption={z:4,filterMode:"filter",start:0,end:100},e})(Qe);function LB(r){var e={};return O(["start","end","startValue","endValue","throttle"],function(t){r.hasOwnProperty(t)&&(e[t]=r[t])}),e}var e1e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e})(Sg),vL=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a,i){this.dataZoomModel=t,this.ecModel=n,this.api=a},e.type="dataZoom",e})(Rt),t1e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e})(vL),Zf=O,RB=na,r1e=(function(){function r(e,t,n,a){this._dimName=e,this._axisIndex=t,this.ecModel=a,this._dataZoomModel=n}return r.prototype.hostedBy=function(e){return this._dataZoomModel===e},r.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},r.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},r.prototype.getTargetSeriesModels=function(){var e=[];return this.ecModel.eachSeries(function(t){if(Qxe(t)){var n=ol(this._dimName),a=t.getReferringComponents(n,Zt).models[0];a&&this._axisIndex===a.componentIndex&&e.push(t)}},this),e},r.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},r.prototype.getMinMaxSpan=function(){return De(this._minMaxSpan)},r.prototype.calculateDataWindow=function(e){var t=this._dataExtent,n=this.getAxisModel(),a=n.axis.scale,i=this._dataZoomModel.getRangePropMode(),o=[0,100],s=[],l=[],u;Zf(["start","end"],function(d,v){var g=e[d],y=e[d+"Value"];i[v]==="percent"?(g==null&&(g=o[v]),y=a.parse(pt(g,o,t))):(u=!0,y=y==null?t[v]:a.parse(y),g=pt(y,t,o)),l[v]=y==null||isNaN(y)?t[v]:y,s[v]=g==null||isNaN(g)?o[v]:g}),RB(l),RB(s);var c=this._minMaxSpan;u?f(l,s,t,o,!1):f(s,l,o,t,!0);function f(d,v,g,y,x){var b=x?"Span":"ValueSpan";Tl(0,d,g,"all",c["min"+b],c["max"+b]);for(var w=0;w<2;w++)v[w]=pt(d[w],g,y,!0),x&&(v[w]=a.parse(v[w]))}return{valueWindow:l,percentWindow:s}},r.prototype.reset=function(e){if(e===this._dataZoomModel){var t=this.getTargetSeriesModels();this._dataExtent=n1e(this,this._dimName,t),this._updateMinMaxSpan();var n=this.calculateDataWindow(e.settledOption);this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,this._setAxisModel()}},r.prototype.filterData=function(e,t){if(e!==this._dataZoomModel)return;var n=this._dimName,a=this.getTargetSeriesModels(),i=e.get("filterMode"),o=this._valueWindow;if(i==="none")return;Zf(a,function(l){var u=l.getData(),c=u.mapDimensionsAll(n);if(c.length){if(i==="weakFilter"){var f=u.getStore(),d=fe(c,function(v){return u.getDimensionIndex(v)},u);u.filterSelf(function(v){for(var g,y,x,b=0;b<c.length;b++){var w=f.get(d[b],v),T=!isNaN(w),C=w<o[0],D=w>o[1];if(T&&!C&&!D)return!0;T&&(x=!0),C&&(g=!0),D&&(y=!0)}return x&&g&&y})}else Zf(c,function(v){if(i==="empty")l.setData(u=u.map(v,function(y){return s(y)?y:NaN}));else{var g={};g[v]=o,u.selectRange(g)}});Zf(c,function(v){u.setApproximateExtent(o,v)})}});function s(l){return l>=o[0]&&l<=o[1]}},r.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,n=this._dataExtent;Zf(["min","max"],function(a){var i=t.get(a+"Span"),o=t.get(a+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?i=pt(n[0]+o,n,[0,100],!0):i!=null&&(o=pt(i,[0,100],n,!0)-n[0]),e[a+"Span"]=i,e[a+"ValueSpan"]=o},this)},r.prototype._setAxisModel=function(){var e=this.getAxisModel(),t=this._percentWindow,n=this._valueWindow;if(t){var a=nD(n,[0,500]);a=Math.min(a,20);var i=e.axis.scale.rawExtentInfo;t[0]!==0&&i.setDeterminedMinMax("min",+n[0].toFixed(a)),t[1]!==100&&i.setDeterminedMinMax("max",+n[1].toFixed(a)),i.freeze()}},r})();function n1e(r,e,t){var n=[1/0,-1/0];Zf(t,function(o){_ue(n,o.getData(),e)});var a=r.getAxisModel(),i=QF(a.axis.scale,a,n).calculate();return[i.min,i.max]}var a1e={getTargetSeries:function(r){function e(a){r.eachComponent("dataZoom",function(i){i.eachTargetAxis(function(o,s){var l=r.getComponent(ol(o),s);a(o,s,l,i)})})}e(function(a,i,o,s){o.__dzAxisProxy=null});var t=[];e(function(a,i,o,s){o.__dzAxisProxy||(o.__dzAxisProxy=new r1e(a,i,s,r),t.push(o.__dzAxisProxy))});var n=Te();return O(t,function(a){O(a.getTargetSeriesModels(),function(i){n.set(i.uid,i)})}),n},overallReset:function(r,e){r.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(n,a){t.getAxisProxy(n,a).reset(t)}),t.eachTargetAxis(function(n,a){t.getAxisProxy(n,a).filterData(t,e)})}),r.eachComponent("dataZoom",function(t){var n=t.findRepresentativeAxisProxy();if(n){var a=n.getDataPercentWindow(),i=n.getDataValueWindow();t.setCalculatedRange({start:a[0],end:a[1],startValue:i[0],endValue:i[1]})}})}};function i1e(r){r.registerAction("dataZoom",function(e,t){var n=Jxe(t,e);O(n,function(a){a.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var EB=!1;function pL(r){EB||(EB=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,a1e),i1e(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function o1e(r){r.registerComponentModel(e1e),r.registerComponentView(t1e),pL(r)}var La=(function(){function r(){}return r})(),eY={};function $f(r,e){eY[r]=e}function tY(r){return eY[r]}var s1e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){r.prototype.optionUpdated.apply(this,arguments);var t=this.ecModel;O(this.option.feature,function(n,a){var i=tY(a);i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(t)),Ye(n,i.defaultOption))})},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:ee.color.border,borderRadius:0,borderWidth:0,padding:ee.size.m,itemSize:15,itemGap:ee.size.s,showTitle:!0,iconStyle:{borderColor:ee.color.accent50,color:"none"},emphasis:{iconStyle:{borderColor:ee.color.accent50}},tooltip:{show:!1,position:"bottom"}},e})(Qe);function rY(r,e){var t=sd(e.get("padding")),n=e.getItemStyle(["color","opacity"]);n.fill=e.get("backgroundColor");var a=new qe({shape:{x:r.x-t[3],y:r.y-t[0],width:r.width+t[1]+t[3],height:r.height+t[0]+t[2],r:e.get("borderRadius")},style:n,silent:!0,z2:-1});return a}var l1e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,n,a,i){var o=this.group;if(o.removeAll(),!t.get("show"))return;var s=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},c=this._features||(this._features={}),f=[];O(u,function(w,T){f.push(T)}),new Qo(this._featureNames||[],f).add(d).update(d).remove(He(d,null)).execute(),this._featureNames=f;function d(w,T){var C=f[w],D=f[T],M=u[C],N=new et(M,t,t.ecModel),R;if(i&&i.newTitle!=null&&i.featureName===C&&(M.title=i.newTitle),C&&!D){if(u1e(C))R={onclick:N.option.onclick,featureName:C};else{var E=tY(C);if(!E)return;R=new E}c[C]=R}else if(R=c[D],!R)return;R.uid=od("toolbox-feature"),R.model=N,R.ecModel=n,R.api=a;var k=R instanceof La;if(!C&&D){k&&R.dispose&&R.dispose(n,a);return}if(!N.get("show")||k&&R.unusable){k&&R.remove&&R.remove(n,a);return}v(N,R,C),N.setIconStatus=function(I,B){var P=this.option,H=this.iconPaths;P.iconStatus=P.iconStatus||{},P.iconStatus[I]=B,H[I]&&(B==="emphasis"?$o:Ko)(H[I])},R instanceof La&&R.render&&R.render(N,n,a,i)}function v(w,T,C){var D=w.getModel("iconStyle"),M=w.getModel(["emphasis","iconStyle"]),N=T instanceof La&&T.getIcons?T.getIcons():w.get("icon"),R=w.get("title")||{},E,k;ye(N)?(E={},E[C]=N):E=N,ye(R)?(k={},k[C]=R):k=R;var I=w.iconPaths={};O(E,function(B,P){var H=ad(B,{},{x:-s/2,y:-s/2,width:s,height:s});H.setStyle(D.getItemStyle());var V=H.ensureState("emphasis");V.style=M.getItemStyle();var j=new ot({style:{text:k[P],align:M.get("textAlign"),borderRadius:M.get("textBorderRadius"),padding:M.get("textPadding"),fill:null,font:AD({fontStyle:M.get("textFontStyle"),fontFamily:M.get("textFontFamily"),fontSize:M.get("textFontSize"),fontWeight:M.get("textFontWeight")},n)},ignore:!0});H.setTextContent(j),is({el:H,componentModel:t,itemName:P,formatterParamsExtra:{title:k[P]}}),H.__title=k[P],H.on("mouseover",function(){var U=M.getItemStyle(),F=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";j.setStyle({fill:M.get("textFill")||U.fill||U.stroke||ee.color.neutral99,backgroundColor:M.get("textBackgroundColor")}),H.setTextConfig({position:M.get("textPosition")||F}),j.ignore=!t.get("showTitle"),a.enterEmphasis(this)}).on("mouseout",function(){w.get(["iconStatus",P])!=="emphasis"&&a.leaveEmphasis(this),j.hide()}),(w.get(["iconStatus",P])==="emphasis"?$o:Ko)(H),o.add(H),H.on("click",xe(T.onclick,T,n,a,P)),I[P]=H})}var g=Cr(t,a).refContainer,y=t.getBoxLayoutParams(),x=t.get("padding"),b=Ht(y,g,x);rc(t.get("orient"),o,t.get("itemGap"),b.width,b.height),fb(o,y,g,x),o.add(rY(o.getBoundingRect(),t)),l||o.eachChild(function(w){var T=w.__title,C=w.ensureState("emphasis"),D=C.textConfig||(C.textConfig={}),M=w.getTextContent(),N=M&&M.ensureState("emphasis");if(N&&!Me(N)&&T){var R=N.style||(N.style={}),E=K1(T,ot.makeFont(R)),k=w.x+o.x,I=w.y+o.y+s,B=!1;I+E.height>a.getHeight()&&(D.position="top",B=!0);var P=B?-5-E.height:s+10;k+E.width/2>a.getWidth()?(D.position=["100%",P],R.align="right"):k-E.width/2<0&&(D.position=[0,P],R.align="left")}})},e.prototype.updateView=function(t,n,a,i){O(this._features,function(o){o instanceof La&&o.updateView&&o.updateView(o.model,n,a,i)})},e.prototype.remove=function(t,n){O(this._features,function(a){a instanceof La&&a.remove&&a.remove(t,n)}),this.group.removeAll()},e.prototype.dispose=function(t,n){O(this._features,function(a){a instanceof La&&a.dispose&&a.dispose(t,n)})},e.type="toolbox",e})(Rt);function u1e(r){return r.indexOf("my")===0}var c1e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,n){var a=this.model,i=a.get("name")||t.get("title.0.text")||"echarts",o=n.getZr().painter.getType()==="svg",s=o?"svg":a.get("type",!0)||"png",l=n.getConnectedDataURL({type:s,backgroundColor:a.get("backgroundColor",!0)||t.get("backgroundColor")||ee.color.neutral00,connectedBackgroundColor:a.get("connectedBackgroundColor"),excludeComponents:a.get("excludeComponents"),pixelRatio:a.get("pixelRatio")}),u=nt.browser;if(typeof MouseEvent=="function"&&(u.newEdge||!u.ie&&!u.edge)){var c=document.createElement("a");c.download=i+"."+s,c.target="_blank",c.href=l;var f=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});c.dispatchEvent(f)}else if(window.navigator.msSaveOrOpenBlob||o){var d=l.split(","),v=d[0].indexOf("base64")>-1,g=o?decodeURIComponent(d[1]):d[1];v&&(g=window.atob(g));var y=i+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var x=g.length,b=new Uint8Array(x);x--;)b[x]=g.charCodeAt(x);var w=new Blob([b]);window.navigator.msSaveOrOpenBlob(w,y)}else{var T=document.createElement("iframe");document.body.appendChild(T);var C=T.contentWindow,D=C.document;D.open("image/svg+xml","replace"),D.write(g),D.close(),C.focus(),D.execCommand("SaveAs",!0,y),document.body.removeChild(T)}}else{var M=a.get("lang"),N='<body style="margin:0;"><img src="'+l+'" style="max-width:100%;" title="'+(M&&M[0]||"")+'" /></body>',R=window.open();R.document.write(N),R.document.title=i}},e.getDefaultOption=function(t){var n={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:ee.color.neutral00,name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return n},e})(La),kB="__ec_magicType_stack__",f1e=[["line","bar"],["stack"]],h1e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getIcons=function(){var t=this.model,n=t.get("icon"),a={};return O(t.get("type"),function(i){n[i]&&(a[i]=n[i])}),a},e.getDefaultOption=function(t){var n={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return n},e.prototype.onclick=function(t,n,a){var i=this.model,o=i.get(["seriesIndex",a]);if(IB[a]){var s={series:[]},l=function(f){var d=f.subType,v=f.id,g=IB[a](d,v,f,i);g&&(Re(g,f.option),s.series.push(g));var y=f.coordinateSystem;if(y&&y.type==="cartesian2d"&&(a==="line"||a==="bar")){var x=y.getAxesByScale("ordinal")[0];if(x){var b=x.dim,w=b+"Axis",T=f.getReferringComponents(w,Zt).models[0],C=T.componentIndex;s[w]=s[w]||[];for(var D=0;D<=C;D++)s[w][C]=s[w][C]||{};s[w][C].boundaryGap=a==="bar"}}};O(f1e,function(f){Fe(f,a)>=0&&O(f,function(d){i.setIconStatus(d,"normal")})}),i.setIconStatus(a,"emphasis"),t.eachComponent({mainType:"series",query:o==null?null:{seriesIndex:o}},l);var u,c=a;a==="stack"&&(u=Ye({stack:i.option.title.tiled,tiled:i.option.title.stack},i.option.title),i.get(["iconStatus",a])!=="emphasis"&&(c="tiled")),n.dispatchAction({type:"changeMagicType",currentType:c,newOption:s,newTitle:u,featureName:"magicType"})}},e})(La),IB={line:function(r,e,t,n){if(r==="bar")return Ye({id:e,type:"line",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},n.get(["option","line"])||{},!0)},bar:function(r,e,t,n){if(r==="line")return Ye({id:e,type:"bar",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},n.get(["option","bar"])||{},!0)},stack:function(r,e,t,n){var a=t.get("stack")===kB;if(r==="line"||r==="bar")return n.setIconStatus("stack",a?"normal":"emphasis"),Ye({id:e,stack:a?"":kB},n.get(["option","stack"])||{},!0)}};ui({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(r,e){e.mergeOption(r.newOption)});var Db=new Array(60).join("-"),Wh=" ";function d1e(r){var e={},t=[],n=[];return r.eachRawSeries(function(a){var i=a.coordinateSystem;if(i&&(i.type==="cartesian2d"||i.type==="polar")){var o=i.getBaseAxis();if(o.type==="category"){var s=o.dim+"_"+o.index;e[s]||(e[s]={categoryAxis:o,valueAxis:i.getOtherAxis(o),series:[]},n.push({axisDim:o.dim,axisIndex:o.index})),e[s].series.push(a)}else t.push(a)}else t.push(a)}),{seriesGroupByCategoryAxis:e,other:t,meta:n}}function v1e(r){var e=[];return O(r,function(t,n){var a=t.categoryAxis,i=t.valueAxis,o=i.dim,s=[" "].concat(fe(t.series,function(v){return v.name})),l=[a.model.getCategories()];O(t.series,function(v){var g=v.getRawData();l.push(v.getRawData().mapArray(g.mapDimension(o),function(y){return y}))});for(var u=[s.join(Wh)],c=0;c<l[0].length;c++){for(var f=[],d=0;d<l.length;d++)f.push(l[d][c]);u.push(f.join(Wh))}e.push(u.join(`
283
- `))}),e.join(`
284
-
285
- `+Db+`
286
-
287
- `)}function p1e(r){return fe(r,function(e){var t=e.getRawData(),n=[e.name],a=[];return t.each(t.dimensions,function(){for(var i=arguments.length,o=arguments[i-1],s=t.getName(o),l=0;l<i-1;l++)a[l]=arguments[l];n.push((s?s+Wh:"")+a.join(Wh))}),n.join(`
288
- `)}).join(`
289
-
290
- `+Db+`
291
-
292
- `)}function g1e(r){var e=d1e(r);return{value:dt([v1e(e.seriesGroupByCategoryAxis),p1e(e.other)],function(t){return!!t.replace(/[\n\t\s]/g,"")}).join(`
293
-
294
- `+Db+`
295
-
296
- `),meta:e.meta}}function T1(r){return r.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function m1e(r){var e=r.slice(0,r.indexOf(`
297
- `));if(e.indexOf(Wh)>=0)return!0}var tM=new RegExp("["+Wh+"]+","g");function y1e(r){for(var e=r.split(/\n+/g),t=T1(e.shift()).split(tM),n=[],a=fe(t,function(l){return{name:l,data:[]}}),i=0;i<e.length;i++){var o=T1(e[i]).split(tM);n.push(o.shift());for(var s=0;s<o.length;s++)a[s]&&(a[s].data[i]=o[s])}return{series:a,categories:n}}function x1e(r){for(var e=r.split(/\n+/g),t=T1(e.shift()),n=[],a=0;a<e.length;a++){var i=T1(e[a]);if(i){var o=i.split(tM),s="",l=void 0,u=!1;isNaN(o[0])?(u=!0,s=o[0],o=o.slice(1),n[a]={name:s,value:[]},l=n[a].value):l=n[a]=[];for(var c=0;c<o.length;c++)l.push(+o[c]);l.length===1&&(u?n[a].value=l[0]:n[a]=l[0])}}return{name:t,data:n}}function b1e(r,e){var t=r.split(new RegExp(`
298
- *`+Db+`
299
- *`,"g")),n={series:[]};return O(t,function(a,i){if(m1e(a)){var o=y1e(a),s=e[i],l=s.axisDim+"Axis";s&&(n[l]=n[l]||[],n[l][s.axisIndex]={data:o.categories},n.series=n.series.concat(o.series))}else{var o=x1e(a);n.series.push(o)}}),n}var _1e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,n){setTimeout(function(){n.dispatchAction({type:"hideTip"})});var a=n.getDom(),i=this.model;this._dom&&a.removeChild(this._dom);var o=document.createElement("div");o.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;padding:5px",o.style.backgroundColor=i.get("backgroundColor")||ee.color.neutral00;var s=document.createElement("h4"),l=i.get("lang")||[];s.innerHTML=l[0]||i.get("title"),s.style.cssText="margin:10px 20px",s.style.color=i.get("textColor");var u=document.createElement("div"),c=document.createElement("textarea");u.style.cssText="overflow:auto";var f=i.get("optionToContent"),d=i.get("contentToOption"),v=g1e(t);if(Me(f)){var g=f(n.getOption());ye(g)?u.innerHTML=g:sc(g)&&u.appendChild(g)}else{c.readOnly=i.get("readOnly");var y=c.style;y.cssText="display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none",y.color=i.get("textColor"),y.borderColor=i.get("textareaBorderColor"),y.backgroundColor=i.get("textareaColor"),c.value=v.value,u.appendChild(c)}var x=v.meta,b=document.createElement("div");b.style.cssText="position:absolute;bottom:5px;left:0;right:0";var w="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",T=document.createElement("div"),C=document.createElement("div");w+=";background-color:"+i.get("buttonColor"),w+=";color:"+i.get("buttonTextColor");var D=this;function M(){a.removeChild(o),D._dom=null}fC(T,"click",M),fC(C,"click",function(){if(d==null&&f!=null||d!=null&&f==null){M();return}var N;try{Me(d)?N=d(u,n.getOption()):N=b1e(c.value,x)}catch(R){throw M(),new Error("Data view format error "+R)}N&&n.dispatchAction({type:"changeDataView",newOption:N}),M()}),T.innerHTML=l[1],C.innerHTML=l[2],C.style.cssText=T.style.cssText=w,!i.get("readOnly")&&b.appendChild(C),b.appendChild(T),o.appendChild(s),o.appendChild(u),o.appendChild(b),u.style.height=a.clientHeight-80+"px",a.appendChild(o),this._dom=o},e.prototype.remove=function(t,n){this._dom&&n.getDom().removeChild(this._dom)},e.prototype.dispose=function(t,n){this.remove(t,n)},e.getDefaultOption=function(t){var n={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:t.getLocaleModel().get(["toolbox","dataView","title"]),lang:t.getLocaleModel().get(["toolbox","dataView","lang"]),backgroundColor:ee.color.background,textColor:ee.color.primary,textareaColor:ee.color.background,textareaBorderColor:ee.color.border,buttonColor:ee.color.accent50,buttonTextColor:ee.color.neutral00};return n},e})(La);function S1e(r,e){return fe(r,function(t,n){var a=e&&e[n];if(Ee(a)&&!ce(a)){var i=Ee(t)&&!ce(t);i||(t={value:t});var o=a.name!=null&&t.name==null;return t=Re(t,a),o&&delete t.name,t}else return t})}ui({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(r,e){var t=[];O(r.newOption.series,function(n){var a=e.getSeriesByName(n.name)[0];if(!a)t.push(ie({type:"scatter"},n));else{var i=a.get("data");t.push({name:n.name,data:S1e(n.data,i)})}}),e.mergeOption(Re({series:t},r.newOption))});var nY=O,aY=Je();function w1e(r,e){var t=gL(r);nY(e,function(n,a){for(var i=t.length-1;i>=0;i--){var o=t[i];if(o[a])break}if(i<0){var s=r.queryComponents({mainType:"dataZoom",subType:"select",id:a})[0];if(s){var l=s.getPercentRange();t[0][a]={dataZoomId:a,start:l[0],end:l[1]}}}}),t.push(e)}function T1e(r){var e=gL(r),t=e[e.length-1];e.length>1&&e.pop();var n={};return nY(t,function(a,i){for(var o=e.length-1;o>=0;o--)if(a=e[o][i],a){n[i]=a;break}}),n}function C1e(r){aY(r).snapshots=null}function A1e(r){return gL(r).length}function gL(r){var e=aY(r);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var M1e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,n){C1e(t),n.dispatchAction({type:"restore",from:this.uid})},e.getDefaultOption=function(t){var n={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:t.getLocaleModel().get(["toolbox","restore","title"])};return n},e})(La);ui({type:"restore",event:"restore",update:"prepareAndUpdate"},function(r,e){e.resetOption("recreate")});var D1e=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],mL=(function(){function r(e,t,n){var a=this;this._targetInfoList=[];var i=OB(t,e);O(N1e,function(o,s){(!n||!n.include||Fe(n.include,s)>=0)&&o(i,a._targetInfoList)})}return r.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(n,a,i){if((n.coordRanges||(n.coordRanges=[])).push(a),!n.coordRange){n.coordRange=a;var o=hT[n.brushType](0,i,a);n.__rangeOffset={offset:BB[n.brushType](o.values,n.range,[1,1]),xyMinMax:o.xyMinMax}}}),e},r.prototype.matchOutputRanges=function(e,t,n){O(e,function(a){var i=this.findTargetInfo(a,t);i&&i!==!0&&O(i.coordSyses,function(o){var s=hT[a.brushType](1,o,a.range,!0);n(a,s.values,o,t)})},this)},r.prototype.setInputRanges=function(e,t){O(e,function(n){var a=this.findTargetInfo(n,t);if(n.range=n.range||[],a&&a!==!0){n.panelId=a.panelId;var i=hT[n.brushType](0,a.coordSys,n.coordRange),o=n.__rangeOffset;n.range=o?BB[n.brushType](i.values,o.offset,L1e(i.xyMinMax,o.xyMinMax)):i.values}},this)},r.prototype.makePanelOpts=function(e,t){return fe(this._targetInfoList,function(n){var a=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:t?t(n):null,clipPath:u9(a),isTargetByCursor:f9(a,e,n.coordSysModel),getLinearBrushOtherExtent:c9(a)}})},r.prototype.controlSeries=function(e,t,n){var a=this.findTargetInfo(e,n);return a===!0||a&&Fe(a.coordSyses,t.coordinateSystem)>=0},r.prototype.findTargetInfo=function(e,t){for(var n=this._targetInfoList,a=OB(t,e),i=0;i<n.length;i++){var o=n[i],s=e.panelId;if(s){if(o.panelId===s)return o}else for(var l=0;l<PB.length;l++)if(PB[l](a,o))return o}return!0},r})();function rM(r){return r[0]>r[1]&&r.reverse(),r}function OB(r,e){return fh(r,e,{includeMainTypes:D1e})}var N1e={grid:function(r,e){var t=r.xAxisModels,n=r.yAxisModels,a=r.gridModels,i=Te(),o={},s={};!t&&!n&&!a||(O(t,function(l){var u=l.axis.grid.model;i.set(u.id,u),o[u.id]=!0}),O(n,function(l){var u=l.axis.grid.model;i.set(u.id,u),s[u.id]=!0}),O(a,function(l){i.set(l.id,l),o[l.id]=!0,s[l.id]=!0}),i.each(function(l){var u=l.coordinateSystem,c=[];O(u.getCartesians(),function(f,d){(Fe(t,f.getAxis("x").model)>=0||Fe(n,f.getAxis("y").model)>=0)&&c.push(f)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:c[0],coordSyses:c,getPanelRect:jB.grid,xAxisDeclared:o[l.id],yAxisDeclared:s[l.id]})}))},geo:function(r,e){O(r.geoModels,function(t){var n=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:n,coordSyses:[n],getPanelRect:jB.geo})})}},PB=[function(r,e){var t=r.xAxisModel,n=r.yAxisModel,a=r.gridModel;return!a&&t&&(a=t.axis.grid.model),!a&&n&&(a=n.axis.grid.model),a&&a===e.gridModel},function(r,e){var t=r.geoModel;return t&&t===e.geoModel}],jB={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys,e=r.getBoundingRect().clone();return e.applyTransform(dl(r)),e}},hT={lineX:He(zB,0),lineY:He(zB,1),rect:function(r,e,t,n){var a=r?e.pointToData([t[0][0],t[1][0]],n):e.dataToPoint([t[0][0],t[1][0]],n),i=r?e.pointToData([t[0][1],t[1][1]],n):e.dataToPoint([t[0][1],t[1][1]],n),o=[rM([a[0],i[0]]),rM([a[1],i[1]])];return{values:o,xyMinMax:o}},polygon:function(r,e,t,n){var a=[[1/0,-1/0],[1/0,-1/0]],i=fe(t,function(o){var s=r?e.pointToData(o,n):e.dataToPoint(o,n);return a[0][0]=Math.min(a[0][0],s[0]),a[1][0]=Math.min(a[1][0],s[1]),a[0][1]=Math.max(a[0][1],s[0]),a[1][1]=Math.max(a[1][1],s[1]),s});return{values:i,xyMinMax:a}}};function zB(r,e,t,n){var a=t.getAxis(["x","y"][r]),i=rM(fe([0,1],function(s){return e?a.coordToData(a.toLocalCoord(n[s]),!0):a.toGlobalCoord(a.dataToCoord(n[s]))})),o=[];return o[r]=i,o[1-r]=[NaN,NaN],{values:i,xyMinMax:o}}var BB={lineX:He(VB,0),lineY:He(VB,1),rect:function(r,e,t){return[[r[0][0]-t[0]*e[0][0],r[0][1]-t[0]*e[0][1]],[r[1][0]-t[1]*e[1][0],r[1][1]-t[1]*e[1][1]]]},polygon:function(r,e,t){return fe(r,function(n,a){return[n[0]-t[0]*e[a][0],n[1]-t[1]*e[a][1]]})}};function VB(r,e,t,n){return[e[0]-n[r]*t[0],e[1]-n[r]*t[1]]}function L1e(r,e){var t=GB(r),n=GB(e),a=[t[0]/n[0],t[1]/n[1]];return isNaN(a[0])&&(a[0]=1),isNaN(a[1])&&(a[1]=1),a}function GB(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}var nM=O,R1e=hne("toolbox-dataZoom_"),E1e=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,n,a,i){this._brushController||(this._brushController=new HN(a.getZr()),this._brushController.on("brush",xe(this._onBrush,this)).mount()),O1e(t,n,this,i,a),I1e(t,n)},e.prototype.onclick=function(t,n,a){k1e[a].call(this)},e.prototype.remove=function(t,n){this._brushController&&this._brushController.unmount()},e.prototype.dispose=function(t,n){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var n=t.areas;if(!t.isEnd||!n.length)return;var a={},i=this.ecModel;this._brushController.updateCovers([]);var o=new mL(yL(this.model),i,{include:["grid"]});o.matchOutputRanges(n,i,function(u,c,f){if(f.type==="cartesian2d"){var d=u.brushType;d==="rect"?(s("x",f,c[0]),s("y",f,c[1])):s({lineX:"x",lineY:"y"}[d],f,c)}}),w1e(i,a),this._dispatchZoomAction(a);function s(u,c,f){var d=c.getAxis(u),v=d.model,g=l(u,v,i),y=g.findRepresentativeAxisProxy(v).getMinMaxSpan();(y.minValueSpan!=null||y.maxValueSpan!=null)&&(f=Tl(0,f.slice(),d.scale.getExtent(),0,y.minValueSpan,y.maxValueSpan)),g&&(a[g.id]={dataZoomId:g.id,startValue:f[0],endValue:f[1]})}function l(u,c,f){var d;return f.eachComponent({mainType:"dataZoom",subType:"select"},function(v){var g=v.getAxisModel(u,c.componentIndex);g&&(d=v)}),d}},e.prototype._dispatchZoomAction=function(t){var n=[];nM(t,function(a,i){n.push(De(a))}),n.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:n})},e.getDefaultOption=function(t){var n={show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:ee.color.backgroundTint}};return n},e})(La),k1e={zoom:function(){var r=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:r})},back:function(){this._dispatchZoomAction(T1e(this.ecModel))}};function yL(r){var e={xAxisIndex:r.get("xAxisIndex",!0),yAxisIndex:r.get("yAxisIndex",!0),xAxisId:r.get("xAxisId",!0),yAxisId:r.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}function I1e(r,e){r.setIconStatus("back",A1e(e)>1?"emphasis":"normal")}function O1e(r,e,t,n,a){var i=t._isZoomActive;n&&n.type==="takeGlobalCursor"&&(i=n.key==="dataZoomSelect"?n.dataZoomSelectActive:!1),t._isZoomActive=i,r.setIconStatus("zoom",i?"emphasis":"normal");var o=new mL(yL(r),e,{include:["grid"]}),s=o.makePanelOpts(a,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});t._brushController.setPanels(s).enableBrush(i&&s.length?{brushType:"auto",brushStyle:r.getModel("brushStyle").getItemStyle()}:!1)}Xie("dataZoom",function(r){var e=r.getComponent("toolbox",0),t=["feature","dataZoom"];if(!e||e.get(t)==null)return;var n=e.getModel(t),a=[],i=yL(n),o=fh(r,i);nM(o.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),nM(o.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,c){var f=l.componentIndex,d={type:"select",$fromToolbox:!0,filterMode:n.get("filterMode",!0)||"filter",id:R1e+u+f};d[c]=f,a.push(d)}return a});function P1e(r){r.registerComponentModel(s1e),r.registerComponentView(l1e),$f("saveAsImage",c1e),$f("magicType",h1e),$f("dataView",_1e),$f("dataZoom",E1e),$f("restore",M1e),We(o1e)}var j1e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,displayTransition:!0,enterable:!1,backgroundColor:ee.color.neutral00,shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:ee.color.border,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:ee.color.borderShade,width:1,type:"dashed",textStyle:{}}},textStyle:{color:ee.color.tertiary,fontSize:14}},e})(Qe);function iY(r){var e=r.get("confine");return e!=null?!!e:r.get("renderMode")==="richText"}function oY(r){if(nt.domSupported){for(var e=document.documentElement.style,t=0,n=r.length;t<n;t++)if(r[t]in e)return r[t]}}var sY=oY(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),z1e=oY(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function lY(r,e){if(!r)return e;e=BD(e,!0);var t=r.indexOf(e);return r=t===-1?e:"-"+r.slice(0,t)+"-"+e,r.toLowerCase()}function B1e(r,e){var t=r.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(r);return t?t[e]:null}var V1e=lY(z1e,"transition"),xL=lY(sY,"transform"),G1e="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(nt.transform3dSupported?"will-change:transform;":"");function H1e(r){return r=r==="left"?"right":r==="right"?"left":r==="top"?"bottom":"top",r}function F1e(r,e,t){if(!ye(t)||t==="inside")return"";var n=r.get("backgroundColor"),a=r.get("borderWidth");e=vc(e);var i=H1e(t),o=Math.max(Math.round(a)*1.5,6),s="",l=xL+":",u;Fe(["left","right"],i)>-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=i==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=i==="top"?225:45)+"deg)");var c=u*Math.PI/180,f=o+a,d=f*Math.abs(Math.cos(c))+f*Math.abs(Math.sin(c)),v=Math.round(((d-Math.SQRT2*a)/2+Math.SQRT2*a-(d-f)/2)*100)/100;s+=";"+i+":-"+v+"px";var g=e+" solid "+a+"px;",y=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+g,"border-right:"+g,"background-color:"+n+";"];return'<div style="'+y.join("")+'"></div>'}function U1e(r,e,t){var n="cubic-bezier(0.23,1,0.32,1)",a="",i="";return t&&(a=" "+r/2+"s "+n,i="opacity"+a+",visibility"+a),e||(a=" "+r+"s "+n,i+=(i.length?",":"")+(nt.transformSupported?""+xL+a:",left"+a+",top"+a)),V1e+":"+i}function HB(r,e,t){var n=r.toFixed(0)+"px",a=e.toFixed(0)+"px";if(!nt.transformSupported)return t?"top:"+a+";left:"+n+";":[["top",a],["left",n]];var i=nt.transform3dSupported,o="translate"+(i?"3d":"")+"("+n+","+a+(i?",0":"")+")";return t?"top:0;left:0;"+xL+":"+o+";":[["top",0],["left",0],[sY,o]]}function Y1e(r){var e=[],t=r.get("fontSize"),n=r.getTextColor();n&&e.push("color:"+n),e.push("font:"+r.getFont());var a=Ce(r.get("lineHeight"),Math.round(t*3/2));t&&e.push("line-height:"+a+"px");var i=r.get("textShadowColor"),o=r.get("textShadowBlur")||0,s=r.get("textShadowOffsetX")||0,l=r.get("textShadowOffsetY")||0;return i&&o&&e.push("text-shadow:"+s+"px "+l+"px "+o+"px "+i),O(["decoration","align"],function(u){var c=r.get(u);c&&e.push("text-"+u+":"+c)}),e.join(";")}function W1e(r,e,t,n){var a=[],i=r.get("transitionDuration"),o=r.get("backgroundColor"),s=r.get("shadowBlur"),l=r.get("shadowColor"),u=r.get("shadowOffsetX"),c=r.get("shadowOffsetY"),f=r.getModel("textStyle"),d=$8(r,"html"),v=u+"px "+c+"px "+s+"px "+l;return a.push("box-shadow:"+v),e&&i>0&&a.push(U1e(i,t,n)),o&&a.push("background-color:"+o),O(["width","color","radius"],function(g){var y="border-"+g,x=BD(y),b=r.get(x);b!=null&&a.push(y+":"+b+(g==="color"?"":"px"))}),a.push(Y1e(f)),d!=null&&a.push("padding:"+sd(d).join("px ")+"px"),a.join(";")+";"}function FB(r,e,t,n,a){var i=e&&e.painter;if(t){var o=i&&i.getViewportRoot();o&&Rte(r,o,t,n,a)}else{r[0]=n,r[1]=a;var s=i&&i.getViewportRootOffset();s&&(r[0]+=s.offsetLeft,r[1]+=s.offsetTop)}r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var X1e=(function(){function r(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,nt.wxa)return null;var n=document.createElement("div");n.domBelongToZr=!0,this.el=n;var a=this._zr=e.getZr(),i=t.appendTo,o=i&&(ye(i)?document.querySelector(i):sc(i)?i:Me(i)&&i(e.getDom()));FB(this._styleCoord,a,o,e.getWidth()/2,e.getHeight()/2),(o||e.getDom()).appendChild(n),this._api=e,this._container=o;var s=this;n.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},n.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=a.handler,c=a.painter.getViewportRoot();wa(c,l,!0),u.dispatch("mousemove",l)}},n.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),n=B1e(t,"position"),a=t.style;a.position!=="absolute"&&n!=="absolute"&&(a.position="relative")}var i=e.get("alwaysShowContent");i&&this._moveIfResized(),this._alwaysShowContent=i,this._enableDisplayTransition=e.get("displayTransition")&&e.get("transitionDuration")>0,this.el.className=e.get("className")||""},r.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,a=n.style,i=this._styleCoord;n.innerHTML?a.cssText=G1e+W1e(e,!this._firstShow,this._longHide,this._enableDisplayTransition)+HB(i[0],i[1],!0)+("border-color:"+vc(t)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):a.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(e,t,n,a,i){var o=this.el;if(e==null){o.innerHTML="";return}var s="";if(ye(i)&&n.get("trigger")==="item"&&!iY(n)&&(s=F1e(n,a,i)),ye(e))o.innerHTML=e+s;else if(e){o.innerHTML="",ce(e)||(e=[e]);for(var l=0;l<e.length;l++)sc(e[l])&&e[l].parentNode!==o&&o.appendChild(e[l]);if(s&&o.childNodes.length){var u=document.createElement("div");u.innerHTML=s,o.appendChild(u)}}},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el;return e?[e.offsetWidth,e.offsetHeight]:[0,0]},r.prototype.moveTo=function(e,t){if(this.el){var n=this._styleCoord;if(FB(n,this._zr,this._container,e,t),n[0]!=null&&n[1]!=null){var a=this.el.style,i=HB(n[0],n[1]);O(i,function(o){a[o[0]]=o[1]})}}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){var e=this,t=this.el.style;this._enableDisplayTransition?(t.visibility="hidden",t.opacity="0"):t.display="none",nt.transform3dSupported&&(t.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(xe(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var e=this._zr;Ete(e&&e.painter&&e.painter.getViewportRoot(),this._container);var t=this.el;if(t){t.onmouseenter=t.onmousemove=t.onmouseleave=null;var n=t.parentNode;n&&n.removeChild(t)}this.el=this._container=null},r})(),q1e=(function(){function r(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),YB(this._styleCoord,this._zr,e.getWidth()/2,e.getHeight()/2)}return r.prototype.update=function(e){var t=e.get("alwaysShowContent");t&&this._moveIfResized(),this._alwaysShowContent=t},r.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},r.prototype.setContent=function(e,t,n,a,i){var o=this;Ee(e)&&gt(""),this.el&&this._zr.remove(this.el);var s=n.getModel("textStyle");this.el=new ot({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:a,textShadowColor:s.get("textShadowColor"),fill:n.get(["textStyle","color"]),padding:$8(n,"richText"),verticalAlign:"top",align:"left"},z:n.get("z")}),O(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(u){o.el.style[u]=n.get(u)}),O(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(u){o.el.style[u]=s.get(u)||0}),this._zr.add(this.el);var l=this;this.el.on("mouseover",function(){l._enterable&&(clearTimeout(l._hideTimeout),l._show=!0),l._inContent=!0}),this.el.on("mouseout",function(){l._enterable&&l._show&&l.hideLater(l._hideDelay),l._inContent=!1})},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),n=UB(e.style);return[t.width+n.left+n.right,t.height+n.top+n.bottom]},r.prototype.moveTo=function(e,t){var n=this.el;if(n){var a=this._styleCoord;YB(a,this._zr,e,t),e=a[0],t=a[1];var i=n.style,o=Fs(i.borderWidth||0),s=UB(i);n.x=e+o+s.left,n.y=t+o+s.top,n.markRedraw()}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(xe(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this._zr.remove(this.el)},r})();function Fs(r){return Math.max(0,r)}function UB(r){var e=Fs(r.shadowBlur||0),t=Fs(r.shadowOffsetX||0),n=Fs(r.shadowOffsetY||0);return{left:Fs(e-t),right:Fs(e+t),top:Fs(e-n),bottom:Fs(e+n)}}function YB(r,e,t,n){r[0]=t,r[1]=n,r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var Z1e=new qe({shape:{x:-1,y:-1,width:2,height:2}}),$1e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){if(!(nt.node||!n.getDom())){var a=t.getComponent("tooltip"),i=this._renderMode=xne(a.get("renderMode"));this._tooltipContent=i==="richText"?new q1e(n):new X1e(n,{appendTo:a.get("appendToBody",!0)?"body":a.get("appendTo",!0)})}},e.prototype.render=function(t,n,a){if(!(nt.node||!a.getDom())){this.group.removeAll(),this._tooltipModel=t,this._ecModel=n,this._api=a;var i=this._tooltipContent;i.update(t),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&t.get("transitionDuration")?cd(this,"_updatePosition",50,"fixRate"):sg(this,"_updatePosition")}},e.prototype._initGlobalListener=function(){var t=this._tooltipModel,n=t.get("triggerOn");F9("itemTooltip",this._api,xe(function(a,i,o){n!=="none"&&(n.indexOf(a)>=0?this._tryShow(i,o):a==="leave"&&this._hide(o))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,n=this._ecModel,a=this._api,i=t.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&i!=="none"&&i!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!a.isDisposed()&&o.manuallyShowTip(t,n,a,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,n,a,i){if(!(i.from===this.uid||nt.node||!a.getDom())){var o=WB(i,a);this._ticket="";var s=i.dataByCoordSys,l=ebe(i,n,a);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:i.position,positionDefault:"bottom"},o)}else if(i.tooltip&&i.x!=null&&i.y!=null){var c=Z1e;c.x=i.x,c.y=i.y,c.update(),je(c).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:c},o)}else if(s)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:s,tooltipOption:i.tooltipOption},o);else if(i.seriesIndex!=null){if(this._manuallyAxisShowTip(t,n,a,i))return;var f=U9(i,n),d=f.point[0],v=f.point[1];d!=null&&v!=null&&this._tryShow({offsetX:d,offsetY:v,target:f.el,position:i.position,positionDefault:"bottom"},o)}else i.x!=null&&i.y!=null&&(a.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:a.getZr().findHover(i.x,i.y).target},o))}},e.prototype.manuallyHideTip=function(t,n,a,i){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(WB(i,a))},e.prototype._manuallyAxisShowTip=function(t,n,a,i){var o=i.seriesIndex,s=i.dataIndex,l=n.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=n.getSeriesByIndex(o);if(u){var c=u.getData(),f=Zv([c.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(f.get("trigger")==="axis")return a.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:i.position}),!0}}},e.prototype._tryShow=function(t,n){var a=t.target,i=this._tooltipModel;if(i){this._lastX=t.offsetX,this._lastY=t.offsetY;var o=t.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,t);else if(a){var s=je(a);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null;var l,u;Gu(a,function(c){if(c.tooltipDisabled)return l=u=null,!0;l||u||(je(c).dataIndex!=null?l=c:je(c).tooltipConfig!=null&&(u=c))},!0),l?this._showSeriesItemTooltip(t,l,n):u?this._showComponentItemTooltip(t,u,n):this._hide(n)}else this._lastDataByCoordSys=null,this._hide(n)}},e.prototype._showOrMove=function(t,n){var a=t.get("showDelay");n=xe(n,this),clearTimeout(this._showTimout),a>0?this._showTimout=setTimeout(n,a):n()},e.prototype._showAxisTooltip=function(t,n){var a=this._ecModel,i=this._tooltipModel,o=[n.offsetX,n.offsetY],s=Zv([n.tooltipOption],i),l=this._renderMode,u=[],c=pr("section",{blocks:[],noHeader:!0}),f=[],d=new Xw;O(t,function(w){O(w.dataByAxis,function(T){var C=a.getComponent(T.axisDim+"Axis",T.axisIndex),D=T.value;if(!(!C||D==null)){var M=V9(D,C.axis,a,T.seriesDataIndices,T.valueLabelOpt),N=pr("section",{header:M,noHeader:!ra(M),sortBlocks:!0,blocks:[]});c.blocks.push(N),O(T.seriesDataIndices,function(R){var E=a.getSeriesByIndex(R.seriesIndex),k=R.dataIndexInside,I=E.getDataParams(k);if(!(I.dataIndex<0)){I.axisDim=T.axisDim,I.axisIndex=T.axisIndex,I.axisType=T.axisType,I.axisId=T.axisId,I.axisValue=t1(C.axis,{value:D}),I.axisValueLabel=M,I.marker=d.makeTooltipMarker("item",vc(I.color),l);var B=l5(E.formatTooltip(k,!0,null)),P=B.frag;if(P){var H=Zv([E],i).get("valueFormatter");N.blocks.push(H?ie({valueFormatter:H},P):P)}B.text&&f.push(B.text),u.push(I)}})}})}),c.blocks.reverse(),f.reverse();var v=n.position,g=s.get("order"),y=v5(c,d,l,g,a.get("useUTC"),s.get("textStyle"));y&&f.unshift(y);var x=l==="richText"?`
300
-
301
- `:"<br/>",b=f.join(x);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(s,v,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,b,u,Math.random()+"",o[0],o[1],v,null,d)})},e.prototype._showSeriesItemTooltip=function(t,n,a){var i=this._ecModel,o=je(n),s=o.seriesIndex,l=i.getSeriesByIndex(s),u=o.dataModel||l,c=o.dataIndex,f=o.dataType,d=u.getData(f),v=this._renderMode,g=t.positionDefault,y=Zv([d.getItemModel(c),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,g?{position:g}:null),x=y.get("trigger");if(!(x!=null&&x!=="item")){var b=u.getDataParams(c,f),w=new Xw;b.marker=w.makeTooltipMarker("item",vc(b.color),v);var T=l5(u.formatTooltip(c,!1,f)),C=y.get("order"),D=y.get("valueFormatter"),M=T.frag,N=M?v5(D?ie({valueFormatter:D},M):M,w,v,C,i.get("useUTC"),y.get("textStyle")):T.text,R="item_"+u.name+"_"+c;this._showOrMove(y,function(){this._showTooltipContent(y,N,b,R,t.offsetX,t.offsetY,t.position,t.target,w)}),a({type:"showTip",dataIndexInside:c,dataIndex:d.getRawIndex(c),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,n,a){var i=this._renderMode==="html",o=je(n),s=o.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(ye(l)){var c=l;l={content:c,formatter:c},u=!0}u&&i&&l.content&&(l=De(l),l.content=dn(l.content));var f=[l],d=this._ecModel.getComponent(o.componentMainType,o.componentIndex);d&&f.push(d),f.push({formatter:l.content});var v=t.positionDefault,g=Zv(f,this._tooltipModel,v?{position:v}:null),y=g.get("content"),x=Math.random()+"",b=new Xw;this._showOrMove(g,function(){var w=De(g.get("formatterParams")||{});this._showTooltipContent(g,y,w,x,t.offsetX,t.offsetY,t.position,n,b)}),a({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,n,a,i,o,s,l,u,c){if(this._ticket="",!(!t.get("showContent")||!t.get("show"))){var f=this._tooltipContent;f.setEnterable(t.get("enterable"));var d=t.get("formatter");l=l||t.get("position");var v=n,g=this._getNearestPoint([o,s],a,t.get("trigger"),t.get("borderColor"),t.get("defaultBorderColor",!0)),y=g.color;if(d)if(ye(d)){var x=t.ecModel.get("useUTC"),b=ce(a)?a[0]:a,w=b&&b.axisType&&b.axisType.indexOf("time")>=0;v=d,w&&(v=Zg(b.axisValue,v,x)),v=VD(v,a,!0)}else if(Me(d)){var T=xe(function(C,D){C===this._ticket&&(f.setContent(D,c,t,y,l),this._updatePosition(t,l,o,s,f,a,u))},this);this._ticket=i,v=d(a,i,T)}else v=d;f.setContent(v,c,t,y,l),f.show(t,y),this._updatePosition(t,l,o,s,f,a,u)}},e.prototype._getNearestPoint=function(t,n,a,i,o){if(a==="axis"||ce(n))return{color:i||o};if(!ce(n))return{color:i||n.color||n.borderColor}},e.prototype._updatePosition=function(t,n,a,i,o,s,l){var u=this._api.getWidth(),c=this._api.getHeight();n=n||t.get("position");var f=o.getSize(),d=t.get("align"),v=t.get("verticalAlign"),g=l&&l.getBoundingRect().clone();if(l&&g.applyTransform(l.transform),Me(n)&&(n=n([a,i],s,o.el,g,{viewSize:[u,c],contentSize:f.slice()})),ce(n))a=me(n[0],u),i=me(n[1],c);else if(Ee(n)){var y=n;y.width=f[0],y.height=f[1];var x=Ht(y,{width:u,height:c});a=x.x,i=x.y,d=null,v=null}else if(ye(n)&&l){var b=J1e(n,g,f,t.get("borderWidth"));a=b[0],i=b[1]}else{var b=K1e(a,i,o,u,c,d?null:20,v?null:20);a=b[0],i=b[1]}if(d&&(a-=XB(d)?f[0]/2:d==="right"?f[0]:0),v&&(i-=XB(v)?f[1]/2:v==="bottom"?f[1]:0),iY(t)){var b=Q1e(a,i,o,u,c);a=b[0],i=b[1]}o.moveTo(a,i)},e.prototype._updateContentNotChangedOnAxis=function(t,n){var a=this._lastDataByCoordSys,i=this._cbParamsList,o=!!a&&a.length===t.length;return o&&O(a,function(s,l){var u=s.dataByAxis||[],c=t[l]||{},f=c.dataByAxis||[];o=o&&u.length===f.length,o&&O(u,function(d,v){var g=f[v]||{},y=d.seriesDataIndices||[],x=g.seriesDataIndices||[];o=o&&d.value===g.value&&d.axisType===g.axisType&&d.axisId===g.axisId&&y.length===x.length,o&&O(y,function(b,w){var T=x[w];o=o&&b.seriesIndex===T.seriesIndex&&b.dataIndex===T.dataIndex}),i&&O(d.seriesDataIndices,function(b){var w=b.seriesIndex,T=n[w],C=i[w];T&&C&&C.data!==T.data&&(o=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=n,!!o},e.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,n){nt.node||!n.getDom()||(sg(this,"_updatePosition"),this._tooltipContent.dispose(),ZA("itemTooltip",n))},e.type="tooltip",e})(Rt);function Zv(r,e,t){var n=e.ecModel,a;t?(a=new et(t,n,n),a=new et(e.option,a,n)):a=e;for(var i=r.length-1;i>=0;i--){var o=r[i];o&&(o instanceof et&&(o=o.get("tooltip",!0)),ye(o)&&(o={formatter:o}),o&&(a=new et(o,a,n)))}return a}function WB(r,e){return r.dispatchAction||xe(e.dispatchAction,e)}function K1e(r,e,t,n,a,i,o){var s=t.getSize(),l=s[0],u=s[1];return i!=null&&(r+l+i+2>n?r-=l+i:r+=i),o!=null&&(e+u+o>a?e-=u+o:e+=o),[r,e]}function Q1e(r,e,t,n,a){var i=t.getSize(),o=i[0],s=i[1];return r=Math.min(r+o,n)-o,e=Math.min(e+s,a)-s,r=Math.max(r,0),e=Math.max(e,0),[r,e]}function J1e(r,e,t,n){var a=t[0],i=t[1],o=Math.ceil(Math.SQRT2*n)+8,s=0,l=0,u=e.width,c=e.height;switch(r){case"inside":s=e.x+u/2-a/2,l=e.y+c/2-i/2;break;case"top":s=e.x+u/2-a/2,l=e.y-i-o;break;case"bottom":s=e.x+u/2-a/2,l=e.y+c+o;break;case"left":s=e.x-a-o,l=e.y+c/2-i/2;break;case"right":s=e.x+u+o,l=e.y+c/2-i/2}return[s,l]}function XB(r){return r==="center"||r==="middle"}function ebe(r,e,t){var n=lD(r).queryOptionMap,a=n.keys()[0];if(!(!a||a==="series")){var i=Jh(e,a,n.get(a),{useDefault:!1,enableAll:!1,enableNone:!1}),o=i.models[0];if(o){var s=t.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var c=je(u).tooltipConfig;if(c&&c.name===r.name)return l=u,!0}),l)return{componentMainType:a,componentIndex:o.componentIndex,el:l}}}}function tbe(r){We(am),r.registerComponentModel(j1e),r.registerComponentView($1e),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},Kt),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},Kt)}var rbe=["rect","polygon","keep","clear"];function nbe(r,e){var t=Lt(r?r.brush:[]);if(t.length){var n=[];O(t,function(l){var u=l.hasOwnProperty("toolbox")?l.toolbox:[];u instanceof Array&&(n=n.concat(u))});var a=r&&r.toolbox;ce(a)&&(a=a[0]),a||(a={feature:{}},r.toolbox=[a]);var i=a.feature||(a.feature={}),o=i.brush||(i.brush={}),s=o.type||(o.type=[]);s.push.apply(s,n),abe(s),e&&!s.length&&s.push.apply(s,rbe)}}function abe(r){var e={};O(r,function(t){e[t]=1}),r.length=0,O(e,function(t,n){r.push(n)})}var qB=O;function ZB(r){if(r){for(var e in r)if(r.hasOwnProperty(e))return!0}}function aM(r,e,t){var n={};return qB(e,function(i){var o=n[i]=a();qB(r[i],function(s,l){if(Er.isValidType(l)){var u={type:l,visual:s};t&&t(u,i),o[l]=new Er(u),l==="opacity"&&(u=De(u),u.type="colorAlpha",o.__hidden.__alphaForOpacity=new Er(u))}})}),n;function a(){var i=function(){};i.prototype.__hidden=i.prototype;var o=new i;return o}}function uY(r,e,t){var n;O(t,function(a){e.hasOwnProperty(a)&&ZB(e[a])&&(n=!0)}),n&&O(t,function(a){e.hasOwnProperty(a)&&ZB(e[a])?r[a]=De(e[a]):delete r[a]})}function ibe(r,e,t,n,a,i){var o={};O(r,function(f){var d=Er.prepareVisualTypes(e[f]);o[f]=d});var s;function l(f){return $D(t,s,f)}function u(f,d){oF(t,s,f,d)}t.each(c);function c(f,d){s=f;var v=t.getRawDataItem(s);if(!(v&&v.visualMap===!1))for(var g=n.call(a,f),y=e[g],x=o[g],b=0,w=x.length;b<w;b++){var T=x[b];y[T]&&y[T].applyVisual(f,l,u)}}}function obe(r,e,t,n){var a={};return O(r,function(i){var o=Er.prepareVisualTypes(e[i]);a[i]=o}),{progress:function(o,s){var l;n!=null&&(l=s.getDimensionIndex(n));function u(D){return $D(s,f,D)}function c(D,M){oF(s,f,D,M)}for(var f,d=s.getStore();(f=o.next())!=null;){var v=s.getRawDataItem(f);if(!(v&&v.visualMap===!1))for(var g=n!=null?d.get(l,f):f,y=t(g),x=e[y],b=a[y],w=0,T=b.length;w<T;w++){var C=b[w];x[C]&&x[C].applyVisual(g,u,c)}}}}}function sbe(r){var e=r.brushType,t={point:function(n){return $B[e].point(n,t,r)},rect:function(n){return $B[e].rect(n,t,r)}};return t}var $B={lineX:KB(0),lineY:KB(1),rect:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])},rect:function(r,e,t){return r&&t.boundingRect.intersect(r)}},polygon:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])&&Eu(t.range,r[0],r[1])},rect:function(r,e,t){var n=t.range;if(!r||n.length<=1)return!1;var a=r.x,i=r.y,o=r.width,s=r.height,l=n[0];if(Eu(n,a,i)||Eu(n,a+o,i)||Eu(n,a,i+s)||Eu(n,a+o,i+s)||Oe.create(r).contain(l[0],l[1])||hp(a,i,a+o,i,n)||hp(a,i,a,i+s,n)||hp(a+o,i,a+o,i+s,n)||hp(a,i+s,a+o,i+s,n))return!0}}};function KB(r){var e=["x","y"],t=["width","height"];return{point:function(n,a,i){if(n){var o=i.range,s=n[r];return $v(s,o)}},rect:function(n,a,i){if(n){var o=i.range,s=[n[e[r]],n[e[r]]+n[t[r]]];return s[1]<s[0]&&s.reverse(),$v(s[0],o)||$v(s[1],o)||$v(o[0],s)||$v(o[1],s)}}}}function $v(r,e){return e[0]<=r&&r<=e[1]}var QB=["inBrush","outOfBrush"],dT="__ecBrushSelect",iM="__ecInBrushSelectEvent";function cY(r){r.eachComponent({mainType:"brush"},function(e){var t=e.brushTargetManager=new mL(e.option,r);t.setInputRanges(e.areas,r)})}function lbe(r,e,t){var n=[],a,i;r.eachComponent({mainType:"brush"},function(o){t&&t.type==="takeGlobalCursor"&&o.setBrushOption(t.key==="brush"?t.brushOption:{brushType:!1})}),cY(r),r.eachComponent({mainType:"brush"},function(o,s){var l={brushId:o.id,brushIndex:s,brushName:o.name,areas:De(o.areas),selected:[]};n.push(l);var u=o.option,c=u.brushLink,f=[],d=[],v=[],g=!1;s||(a=u.throttleType,i=u.throttleDelay);var y=fe(o.areas,function(D){var M=hbe[D.brushType],N=Re({boundingRect:M?M(D):void 0},D);return N.selectors=sbe(N),N}),x=aM(o.option,QB,function(D){D.mappingMethod="fixed"});ce(c)&&O(c,function(D){f[D]=1});function b(D){return c==="all"||!!f[D]}function w(D){return!!D.length}r.eachSeries(function(D,M){var N=v[M]=[];D.subType==="parallel"?T(D,M):C(D,M,N)});function T(D,M){var N=D.coordinateSystem;g=g||N.hasAxisBrushed(),b(M)&&N.eachActiveState(D.getData(),function(R,E){R==="active"&&(d[E]=1)})}function C(D,M,N){if(!(!D.brushSelector||fbe(o,M))&&(O(y,function(E){o.brushTargetManager.controlSeries(E,D,r)&&N.push(E),g=g||w(N)}),b(M)&&w(N))){var R=D.getData();R.each(function(E){JB(D,N,R,E)&&(d[E]=1)})}}r.eachSeries(function(D,M){var N={seriesId:D.id,seriesIndex:M,seriesName:D.name,dataIndex:[]};l.selected.push(N);var R=v[M],E=D.getData(),k=b(M)?function(I){return d[I]?(N.dataIndex.push(E.getRawIndex(I)),"inBrush"):"outOfBrush"}:function(I){return JB(D,R,E,I)?(N.dataIndex.push(E.getRawIndex(I)),"inBrush"):"outOfBrush"};(b(M)?g:w(R))&&ibe(QB,x,E,k)})}),ube(e,a,i,n,t)}function ube(r,e,t,n,a){if(a){var i=r.getZr();if(!i[iM]){i[dT]||(i[dT]=cbe);var o=cd(i,dT,t,e);o(r,n)}}}function cbe(r,e){if(!r.isDisposed()){var t=r.getZr();t[iM]=!0,r.dispatchAction({type:"brushSelect",batch:e}),t[iM]=!1}}function JB(r,e,t,n){for(var a=0,i=e.length;a<i;a++){var o=e[a];if(r.brushSelector(n,t,o.selectors,o))return!0}}function fbe(r,e){var t=r.option.seriesIndex;return t!=null&&t!=="all"&&(ce(t)?Fe(t,e)<0:e!==t)}var hbe={rect:function(r){return e4(r.range)},polygon:function(r){for(var e,t=r.range,n=0,a=t.length;n<a;n++){e=e||[[1/0,-1/0],[1/0,-1/0]];var i=t[n];i[0]<e[0][0]&&(e[0][0]=i[0]),i[0]>e[0][1]&&(e[0][1]=i[0]),i[1]<e[1][0]&&(e[1][0]=i[1]),i[1]>e[1][1]&&(e[1][1]=i[1])}return e&&e4(e)}};function e4(r){return new Oe(r[0][0],r[1][0],r[0][1]-r[0][0],r[1][1]-r[1][0])}var dbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){this.ecModel=t,this.api=n,this.model,(this._brushController=new HN(n.getZr())).on("brush",xe(this._onBrush,this)).mount()},e.prototype.render=function(t,n,a,i){this.model=t,this._updateController(t,n,a,i)},e.prototype.updateTransform=function(t,n,a,i){cY(n),this._updateController(t,n,a,i)},e.prototype.updateVisual=function(t,n,a,i){this.updateTransform(t,n,a,i)},e.prototype.updateView=function(t,n,a,i){this._updateController(t,n,a,i)},e.prototype._updateController=function(t,n,a,i){(!i||i.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(a)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var n=this.model.id,a=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:n,areas:De(a),$from:n}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:n,areas:De(a),$from:n})},e.type="brush",e})(Rt),vbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.areas=[],t.brushOption={},t}return e.prototype.optionUpdated=function(t,n){var a=this.option;!n&&uY(a,t,["inBrush","outOfBrush"]);var i=a.inBrush=a.inBrush||{};a.outOfBrush=a.outOfBrush||{color:this.option.defaultOutOfBrushColor},i.hasOwnProperty("liftZ")||(i.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=fe(t,function(n){return t4(this.option,n)},this))},e.prototype.setBrushOption=function(t){this.brushOption=t4(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:ee.color.backgroundTint,borderColor:ee.color.borderTint},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4,defaultOutOfBrushColor:ee.color.disabled},e})(Qe);function t4(r,e){return Ye({brushType:r.brushType,brushMode:r.brushMode,transformable:r.transformable,brushStyle:new et(r.brushStyle).getItemStyle(),removeOnClick:r.removeOnClick,z:r.z},e,!0)}var pbe=["rect","polygon","lineX","lineY","keep","clear"],gbe=(function(r){K(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,n,a){var i,o,s;n.eachComponent({mainType:"brush"},function(l){i=l.brushType,o=l.brushOption.brushMode||"single",s=s||!!l.areas.length}),this._brushType=i,this._brushMode=o,O(t.get("type",!0),function(l){t.setIconStatus(l,(l==="keep"?o==="multiple":l==="clear"?s:l===i)?"emphasis":"normal")})},e.prototype.updateView=function(t,n,a){this.render(t,n,a)},e.prototype.getIcons=function(){var t=this.model,n=t.get("icon",!0),a={};return O(t.get("type",!0),function(i){n[i]&&(a[i]=n[i])}),a},e.prototype.onclick=function(t,n,a){var i=this._brushType,o=this._brushMode;a==="clear"?(n.dispatchAction({type:"axisAreaSelect",intervals:[]}),n.dispatchAction({type:"brush",command:"clear",areas:[]})):n.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:a==="keep"?i:i===a?!1:a,brushMode:a==="keep"?o==="multiple"?"single":"multiple":o}})},e.getDefaultOption=function(t){var n={show:!0,type:pbe.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])};return n},e})(La);function mbe(r){r.registerComponentView(dbe),r.registerComponentModel(vbe),r.registerPreprocessor(nbe),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,lbe),r.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(n){n.setAreas(e.areas)})}),r.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},Kt),r.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},Kt),$f("brush",gbe)}var ybe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:"center",top:ee.size.m,backgroundColor:ee.color.transparent,borderColor:ee.color.primary,borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:ee.color.primary},subtextStyle:{fontSize:12,color:ee.color.quaternary}},e})(Qe),xbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){if(this.group.removeAll(),!!t.get("show")){var i=this.group,o=t.getModel("textStyle"),s=t.getModel("subtextStyle"),l=t.get("textAlign"),u=Ce(t.get("textBaseline"),t.get("textVerticalAlign")),c=new ot({style:Nt(o,{text:t.get("text"),fill:o.getTextColor()},{disableBox:!0}),z2:10}),f=c.getBoundingRect(),d=t.get("subtext"),v=new ot({style:Nt(s,{text:d,fill:s.getTextColor(),y:f.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),g=t.get("link"),y=t.get("sublink"),x=t.get("triggerEvent",!0);c.silent=!g&&!x,v.silent=!y&&!x,g&&c.on("click",function(){Ux(g,"_"+t.get("target"))}),y&&v.on("click",function(){Ux(y,"_"+t.get("subtarget"))}),je(c).eventData=je(v).eventData=x?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(c),d&&i.add(v);var b=i.getBoundingRect(),w=t.getBoxLayoutParams();w.width=b.width,w.height=b.height;var T=Cr(t,a),C=Ht(w,T.refContainer,t.get("padding"));l||(l=t.get("left")||t.get("right"),l==="middle"&&(l="center"),l==="right"?C.x+=C.width:l==="center"&&(C.x+=C.width/2)),u||(u=t.get("top")||t.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?C.y+=C.height:u==="middle"&&(C.y+=C.height/2),u=u||"top"),i.x=C.x,i.y=C.y,i.markRedraw();var D={align:l,verticalAlign:u};c.setStyle(D),v.setStyle(D),b=i.getBoundingRect();var M=C.margin,N=t.getItemStyle(["color","opacity"]);N.fill=t.get("backgroundColor");var R=new qe({shape:{x:b.x-M[3],y:b.y-M[0],width:b.width+M[1]+M[3],height:b.height+M[0]+M[2],r:t.get("borderRadius")},style:N,subPixelOptimize:!0,silent:!0});i.add(R)}},e.type="title",e})(Rt);function bbe(r){r.registerComponentModel(ybe),r.registerComponentView(xbe)}var r4=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a),this._initData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){t==null&&(t=this.option.currentIndex);var n=this._data.count();this.option.loop?t=(t%n+n)%n:(t>=n&&(t=n-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t=this.option,n=t.data||[],a=t.axisType,i=this._names=[],o;a==="category"?(o=[],O(n,function(u,c){var f=xr(Qh(u),""),d;Ee(u)?(d=De(u),d.value=c):d=c,o.push(d),i.push(f)})):o=n;var s={category:"ordinal",time:"time",value:"number"}[a]||"number",l=this._data=new pn([{name:"value",type:s}],this);l.initData(o,i)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if(this.get("axisType")==="category")return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:ee.size.m,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:ee.color.secondary},data:[]},e})(Qe),fY=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=Rl(r4.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:ee.color.border,borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:ee.color.accent10},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:ee.color.tertiary},itemStyle:{color:ee.color.accent20,borderWidth:0},checkpointStyle:{symbol:"circle",symbolSize:15,color:ee.color.accent50,borderColor:ee.color.accent50,borderWidth:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0, 0, 0, 0)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10.6699C11.5 9.90014 12.3333 9.41887 13 9.80371L20.5 14.1338C21.1667 14.5187 21.1667 15.4813 20.5 15.8662L13 20.1963C12.3333 20.5811 11.5 20.0999 11.5 19.3301V10.6699Z",stopIcon:"path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10C12.3284 10 13 10.6716 13 11.5V18.5C13 19.3284 12.3284 20 11.5 20C10.6716 20 10 19.3284 10 18.5V11.5C10 10.6716 10.6716 10 11.5 10ZM18.5 10C19.3284 10 20 10.6716 20 11.5V18.5C20 19.3284 19.3284 20 18.5 20C17.6716 20 17 19.3284 17 18.5V11.5C17 10.6716 17.6716 10 18.5 10Z",nextIcon:"path://M0.838834 18.7383C0.253048 18.1525 0.253048 17.2028 0.838834 16.617L7.55635 9.89949L0.838834 3.18198C0.253048 2.59619 0.253048 1.64645 0.838834 1.06066C1.42462 0.474874 2.37437 0.474874 2.96015 1.06066L10.7383 8.83883L10.8412 8.95277C11.2897 9.50267 11.2897 10.2963 10.8412 10.8462L10.7383 10.9602L2.96015 18.7383C2.37437 19.3241 1.42462 19.3241 0.838834 18.7383Z",prevIcon:"path://M10.9602 1.06066C11.5459 1.64645 11.5459 2.59619 10.9602 3.18198L4.24264 9.89949L10.9602 16.617C11.5459 17.2028 11.5459 18.1525 10.9602 18.7383C10.3744 19.3241 9.42462 19.3241 8.83883 18.7383L1.06066 10.9602L0.957771 10.8462C0.509245 10.2963 0.509245 9.50267 0.957771 8.95277L1.06066 8.83883L8.83883 1.06066C9.42462 0.474874 10.3744 0.474874 10.9602 1.06066Z",prevBtnSize:18,nextBtnSize:18,color:ee.color.accent50,borderColor:ee.color.accent50,borderWidth:0},emphasis:{label:{show:!0,color:ee.color.accent60},itemStyle:{color:ee.color.accent60,borderColor:ee.color.accent60},controlStyle:{color:ee.color.accent70,borderColor:ee.color.accent70}},progress:{lineStyle:{color:ee.color.accent30},itemStyle:{color:ee.color.accent40}},data:[]}),e})(r4);Jt(fY,db.prototype);var _be=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e})(Rt),Sbe=(function(r){K(e,r);function e(t,n,a,i){var o=r.call(this,t,n,a)||this;return o.type=i||"value",o}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e})(Va),vT=Math.PI,n4=Je(),wbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,n){this.api=n},e.prototype.render=function(t,n,a){if(this.model=t,this.api=a,this.ecModel=n,this.group.removeAll(),t.get("show",!0)){var i=this._layout(t,a),o=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(i,t);t.formatTooltip=function(u){var c=l.scale.getLabel({value:u});return pr("nameValue",{noName:!0,value:c})},O(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](i,o,l,t)},this),this._renderAxisLabel(i,s,l,t),this._position(i,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,n){var a=t.get(["label","position"]),i=t.get("orient"),o=Cbe(t,n),s;a==null||a==="auto"?s=i==="horizontal"?o.y+o.height/2<n.getHeight()/2?"-":"+":o.x+o.width/2<n.getWidth()/2?"+":"-":ye(a)?s={horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[i][a]:s=a;var l={horizontal:"center",vertical:s>=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:vT/2},f=i==="vertical"?o.height:o.width,d=t.getModel("controlStyle"),v=d.get("show",!0),g=v?d.get("itemSize"):0,y=v?d.get("itemGap"):0,x=g+y,b=t.get(["label","rotate"])||0;b=b*vT/180;var w,T,C,D=d.get("position",!0),M=v&&d.get("showPlayBtn",!0),N=v&&d.get("showPrevBtn",!0),R=v&&d.get("showNextBtn",!0),E=0,k=f;D==="left"||D==="bottom"?(M&&(w=[0,0],E+=x),N&&(T=[E,0],E+=x),R&&(C=[k-g,0],k-=x)):(M&&(w=[k-g,0],k-=x),N&&(T=[0,0],E+=x),R&&(C=[k-g,0],k-=x));var I=[E,k];return t.get("inverse")&&I.reverse(),{viewRect:o,mainLength:f,orient:i,rotation:c[i],labelRotation:b,labelPosOpt:s,labelAlign:t.get(["label","align"])||l[i],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[i],playPosition:w,prevBtnPosition:T,nextBtnPosition:C,axisExtent:I,controlSize:g,controlGap:y}},e.prototype._position=function(t,n){var a=this._mainGroup,i=this._labelGroup,o=t.viewRect;if(t.orient==="vertical"){var s=Rr(),l=o.x,u=o.y+o.height;ii(s,s,[-l,-u]),ns(s,s,-vT/2),ii(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var c=w(o),f=w(a.getBoundingRect()),d=w(i.getBoundingRect()),v=[a.x,a.y],g=[i.x,i.y];g[0]=v[0]=c[0][0];var y=t.labelPosOpt;if(y==null||ye(y)){var x=y==="+"?0:1;T(v,f,c,1,x),T(g,d,c,1,1-x)}else{var x=y>=0?0:1;T(v,f,c,1,x),g[1]=v[1]+y}a.setPosition(v),i.setPosition(g),a.rotation=i.rotation=t.rotation,b(a),b(i);function b(C){C.originX=c[0][0]-C.x,C.originY=c[1][0]-C.y}function w(C){return[[C.x,C.x+C.width],[C.y,C.y+C.height]]}function T(C,D,M,N,R){C[N]+=M[N][R]-D[N][R]}},e.prototype._createAxis=function(t,n){var a=n.getData(),i=n.get("axisType"),o=Tbe(n,i);o.getTicks=function(){return a.mapArray(["value"],function(u){return{value:u}})};var s=a.getDataExtent("value");o.setExtent(s[0],s[1]),o.calcNiceTicks();var l=new Sbe("value",o,t.axisExtent,i);return l.model=n,l},e.prototype._createGroup=function(t){var n=this[t]=new Ne;return this.group.add(n),n},e.prototype._renderAxisLine=function(t,n,a,i){var o=a.getExtent();if(i.get(["lineStyle","show"])){var s=new lr({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:ie({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});n.add(s);var l=this._progressLine=new lr({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:Re({lineCap:"round",lineWidth:s.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});n.add(l)}},e.prototype._renderAxisTick=function(t,n,a,i){var o=this,s=i.getData(),l=a.scale.getTicks();this._tickSymbols=[],O(l,function(u){var c=a.dataToCoord(u.value),f=s.getItemModel(u.value),d=f.getModel("itemStyle"),v=f.getModel(["emphasis","itemStyle"]),g=f.getModel(["progress","itemStyle"]),y={x:c,y:0,onclick:xe(o._changeTimeline,o,u.value)},x=a4(f,d,n,y);x.ensureState("emphasis").style=v.getItemStyle(),x.ensureState("progress").style=g.getItemStyle(),hl(x);var b=je(x);f.get("tooltip")?(b.dataIndex=u.value,b.dataModel=i):b.dataIndex=b.dataModel=null,o._tickSymbols.push(x)})},e.prototype._renderAxisLabel=function(t,n,a,i){var o=this,s=a.getLabelModel();if(s.get("show")){var l=i.getData(),u=a.getViewLabels();this._tickLabels=[],O(u,function(c){var f=c.tickValue,d=l.getItemModel(f),v=d.getModel("label"),g=d.getModel(["emphasis","label"]),y=d.getModel(["progress","label"]),x=a.dataToCoord(c.tickValue),b=new ot({x,y:0,rotation:t.labelRotation-t.rotation,onclick:xe(o._changeTimeline,o,f),silent:!1,style:Nt(v,{text:c.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});b.ensureState("emphasis").style=Nt(g),b.ensureState("progress").style=Nt(y),n.add(b),hl(b),n4(b).dataIndex=f,o._tickLabels.push(b)})}},e.prototype._renderControl=function(t,n,a,i){var o=t.controlSize,s=t.rotation,l=i.getModel("controlStyle").getItemStyle(),u=i.getModel(["emphasis","controlStyle"]).getItemStyle(),c=i.getPlayState(),f=i.get("inverse",!0);d(t.nextBtnPosition,"next",xe(this._changeTimeline,this,f?"-":"+")),d(t.prevBtnPosition,"prev",xe(this._changeTimeline,this,f?"+":"-")),d(t.playPosition,c?"stop":"play",xe(this._handlePlayClick,this,!c),!0);function d(v,g,y,x){if(v){var b=oi(Ce(i.get(["controlStyle",g+"BtnSize"]),o),o),w=[0,-b/2,b,b],T=Abe(i,g+"Icon",w,{x:v[0],y:v[1],originX:o/2,originY:0,rotation:x?-s:0,rectHover:!0,style:l,onclick:y});T.ensureState("emphasis").style=u,n.add(T),hl(T)}}},e.prototype._renderCurrentPointer=function(t,n,a,i){var o=i.getData(),s=i.getCurrentIndex(),l=o.getItemModel(s).getModel("checkpointStyle"),u=this,c={onCreate:function(f){f.draggable=!0,f.drift=xe(u._handlePointerDrag,u),f.ondragend=xe(u._handlePointerDragend,u),i4(f,u._progressLine,s,a,i,!0)},onUpdate:function(f){i4(f,u._progressLine,s,a,i)}};this._currentPointer=a4(l,l,this._mainGroup,{},this._currentPointer,c)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,n,a){this._clearTimer(),this._pointerChangeTimeline([a.offsetX,a.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,n){var a=this._toAxisCoord(t)[0],i=this._axis,o=na(i.getExtent().slice());a>o[1]&&(a=o[1]),a<o[0]&&(a=o[0]),this._currentPointer.x=a,this._currentPointer.markRedraw();var s=this._progressLine;s&&(s.shape.x2=a,s.dirty());var l=this._findNearestTick(a),u=this.model;(n||l!==u.getCurrentIndex()&&u.get("realtime"))&&this._changeTimeline(l)},e.prototype._doPlayStop=function(){var t=this;this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(function(){var n=t.model;t._changeTimeline(n.getCurrentIndex()+(n.get("rewind",!0)?-1:1))},this.model.get("playInterval")))},e.prototype._toAxisCoord=function(t){var n=this._mainGroup.getLocalTransform();return ti(t,n,!0)},e.prototype._findNearestTick=function(t){var n=this.model.getData(),a=1/0,i,o=this._axis;return n.each(["value"],function(s,l){var u=o.dataToCoord(s),c=Math.abs(u-t);c<a&&(a=c,i=l)}),i},e.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},e.prototype._changeTimeline=function(t){var n=this.model.getCurrentIndex();t==="+"?t=n+1:t==="-"&&(t=n-1),this.api.dispatchAction({type:"timelineChange",currentIndex:t,from:this.uid})},e.prototype._updateTicksStatus=function(){var t=this.model.getCurrentIndex(),n=this._tickSymbols,a=this._tickLabels;if(n)for(var i=0;i<n.length;i++)n&&n[i]&&n[i].toggleState("progress",i<t);if(a)for(var i=0;i<a.length;i++)a&&a[i]&&a[i].toggleState("progress",n4(a[i]).dataIndex<=t)},e.type="timeline.slider",e})(_be);function Tbe(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new Bh({ordinalMeta:r.getCategories(),extent:[1/0,-1/0]});case"time":return new hN({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new es}}function Cbe(r,e){return Ht(r.getBoxLayoutParams(),Cr(r,e).refContainer,r.get("padding"))}function Abe(r,e,t,n){var a=n.style,i=ad(r.get(["controlStyle",e]),n||{},new Oe(t[0],t[1],t[2],t[3]));return a&&i.setStyle(a),i}function a4(r,e,t,n,a,i){var o=e.get("color");if(a)a.setColor(o),t.add(a),i&&i.onUpdate(a);else{var s=r.get("symbol");a=ur(s,-1,-1,2,2,o),a.setStyle("strokeNoScale",!0),t.add(a),i&&i.onCreate(a)}var l=e.getItemStyle(["color"]);a.setStyle(l),n=Ye({rectHover:!0,z2:100},n,!0);var u=fd(r.get("symbolSize"));n.scaleX=u[0]/2,n.scaleY=u[1]/2;var c=Tc(r.get("symbolOffset"),u);c&&(n.x=(n.x||0)+c[0],n.y=(n.y||0)+c[1]);var f=r.get("symbolRotate");return n.rotation=(f||0)*Math.PI/180||0,a.attr(n),a.updateTransform(),a}function i4(r,e,t,n,a,i){if(!r.dragging){var o=a.getModel("checkpointStyle"),s=n.dataToCoord(a.getData().get("value",t));if(i||!o.get("animation",!0))r.attr({x:s,y:0}),e&&e.attr({shape:{x2:s}});else{var l={duration:o.get("animationDuration",!0),easing:o.get("animationEasing",!0)};r.stopAnimation(null,!0),r.animateTo({x:s,y:0},l),e&&e.animateTo({shape:{x2:s}},l)}}}function Mbe(r){r.registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(e,t,n){var a=t.getComponent("timeline");return a&&e.currentIndex!=null&&(a.setCurrentIndex(e.currentIndex),!a.get("loop",!0)&&a.isIndexMax()&&a.getPlayState()&&(a.setPlayState(!1),n.dispatchAction({type:"timelinePlayChange",playState:!1,from:e.from}))),t.resetOption("timeline",{replaceMerge:a.get("replaceMerge",!0)}),Re({currentIndex:a.option.currentIndex},e)}),r.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(e,t){var n=t.getComponent("timeline");n&&e.playState!=null&&n.setPlayState(e.playState)})}function Dbe(r){var e=r&&r.timeline;ce(e)||(e=e?[e]:[]),O(e,function(t){t&&Nbe(t)})}function Nbe(r){var e=r.type,t={number:"value",time:"time"};if(t[e]&&(r.axisType=t[e],delete r.type),o4(r),Ou(r,"controlPosition")){var n=r.controlStyle||(r.controlStyle={});Ou(n,"position")||(n.position=r.controlPosition),n.position==="none"&&!Ou(n,"show")&&(n.show=!1,delete n.position),delete r.controlPosition}O(r.data||[],function(a){Ee(a)&&!ce(a)&&(!Ou(a,"value")&&Ou(a,"name")&&(a.value=a.name),o4(a))})}function o4(r){var e=r.itemStyle||(r.itemStyle={}),t=e.emphasis||(e.emphasis={}),n=r.label||r.label||{},a=n.normal||(n.normal={}),i={normal:1,emphasis:1};O(n,function(o,s){!i[s]&&!Ou(a,s)&&(a[s]=o)}),t.label&&!Ou(n,"emphasis")&&(n.emphasis=t.label,delete t.label)}function Ou(r,e){return r.hasOwnProperty(e)}function Lbe(r){r.registerComponentModel(fY),r.registerComponentView(wbe),r.registerSubTypeDefaulter("timeline",function(){return"slider"}),Mbe(r),r.registerPreprocessor(Dbe)}function bL(r,e){if(!r)return!1;for(var t=ce(r)?r:[r],n=0;n<t.length;n++)if(t[n]&&t[n][e])return!0;return!1}function k0(r){lc(r,"label",["show"])}var I0=Je(),Ki=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.createdBySelf=!1,t.preventAutoZ=!0,t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a),this._mergeOption(t,a,!1,!0)},e.prototype.isAnimationEnabled=function(){if(nt.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},e.prototype.mergeOption=function(t,n){this._mergeOption(t,n,!1,!1)},e.prototype._mergeOption=function(t,n,a,i){var o=this.mainType;a||n.eachSeries(function(s){var l=s.get(this.mainType,!0),u=I0(s)[o];if(!l||!l.data){I0(s)[o]=null;return}u?u._mergeOption(l,n,!0):(i&&k0(l),O(l.data,function(c){c instanceof Array?(k0(c[0]),k0(c[1])):k0(c)}),u=this.createMarkerModelFromSeries(l,this,n),ie(u,{mainType:this.mainType,seriesIndex:s.seriesIndex,name:s.name,createdBySelf:!0}),u.__hostSeries=s),I0(s)[o]=u},this)},e.prototype.formatTooltip=function(t,n,a){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return pr("section",{header:this.name,blocks:[pr("nameValue",{name:s,value:o,noName:!s,noValue:o==null})]})},e.prototype.getData=function(){return this._data},e.prototype.setData=function(t){this._data=t},e.prototype.getDataParams=function(t,n){var a=db.prototype.getDataParams.call(this,t,n),i=this.__hostSeries;return i&&(a.seriesId=i.id,a.seriesName=i.name,a.seriesType=i.subType),a},e.getMarkerModelFromSeries=function(t,n){return I0(t)[n]},e.type="marker",e.dependencies=["series","grid","polar","geo"],e})(Qe);Jt(Ki,db.prototype);var Rbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,n,a){return new e(t,n,a)},e.type="markPoint",e.defaultOption={z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},e})(Ki);function oM(r){return!(isNaN(parseFloat(r.x))&&isNaN(parseFloat(r.y)))}function Ebe(r){return!isNaN(parseFloat(r.x))&&!isNaN(parseFloat(r.y))}function O0(r,e,t,n,a,i,o){var s=[],l=Jo(e,a),u=l?e.getCalculationInfo("stackResultDimension"):a,c=C1(e,u,r),f=e.hostModel,d=f.indicesOfNearest(t,u,c)[0];s[i]=e.get(n,d),s[o]=e.get(u,d);var v=e.get(a,d),g=Ka(e.get(a,d));return g=Math.min(g,20),g>=0&&(s[o]=+s[o].toFixed(g)),[s,v]}var P0={min:He(O0,"min"),max:He(O0,"max"),average:He(O0,"average"),median:He(O0,"median")};function wg(r,e){if(e){var t=r.getData(),n=r.coordinateSystem,a=n&&n.dimensions;if(!Ebe(e)&&!ce(e.coord)&&ce(a)){var i=hY(e,t,n,r);if(e=De(e),e.type&&P0[e.type]&&i.baseAxis&&i.valueAxis){var o=Fe(a,i.baseAxis.dim),s=Fe(a,i.valueAxis.dim),l=P0[e.type](t,i.valueAxis.dim,i.baseDataDim,i.valueDataDim,o,s);e.coord=l[0],e.value=l[1]}else e.coord=[e.xAxis!=null?e.xAxis:e.radiusAxis,e.yAxis!=null?e.yAxis:e.angleAxis]}if(e.coord==null||!ce(a)){e.coord=[];var u=r.getBaseAxis();if(u&&e.type&&P0[e.type]){var c=n.getOtherAxis(u);c&&(e.value=C1(t,t.mapDimension(c.dim),e.type))}}else for(var f=e.coord,d=0;d<2;d++)P0[f[d]]&&(f[d]=C1(t,t.mapDimension(a[d]),f[d]));return e}}function hY(r,e,t,n){var a={};return r.valueIndex!=null||r.valueDim!=null?(a.valueDataDim=r.valueIndex!=null?e.getDimension(r.valueIndex):r.valueDim,a.valueAxis=t.getAxis(kbe(n,a.valueDataDim)),a.baseAxis=t.getOtherAxis(a.valueAxis),a.baseDataDim=e.mapDimension(a.baseAxis.dim)):(a.baseAxis=n.getBaseAxis(),a.valueAxis=t.getOtherAxis(a.baseAxis),a.baseDataDim=e.mapDimension(a.baseAxis.dim),a.valueDataDim=e.mapDimension(a.valueAxis.dim)),a}function kbe(r,e){var t=r.getData().getDimensionInfo(e);return t&&t.coordDim}function Tg(r,e){return r&&r.containData&&e.coord&&!oM(e)?r.containData(e.coord):!0}function Ibe(r,e,t){return r&&r.containZone&&e.coord&&t.coord&&!oM(e)&&!oM(t)?r.containZone(e.coord,t.coord):!0}function dY(r,e){return r?function(t,n,a,i){var o=i<2?t.coord&&t.coord[i]:t.value;return pl(o,e[i])}:function(t,n,a,i){return pl(t.value,e[i])}}function C1(r,e,t){if(t==="average"){var n=0,a=0;return r.each(e,function(i,o){isNaN(i)||(n+=i,a++)}),n/a}else return t==="median"?r.getMedian(e):r.getDataExtent(e)[t==="max"?1:0]}var pT=Je(),_L=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this.markerGroupMap=Te()},e.prototype.render=function(t,n,a){var i=this,o=this.markerGroupMap;o.each(function(s){pT(s).keep=!1}),n.eachSeries(function(s){var l=Ki.getMarkerModelFromSeries(s,i.type);l&&i.renderSeries(s,l,n,a)}),o.each(function(s){!pT(s).keep&&i.group.remove(s.group)}),Obe(n,o,this.type)},e.prototype.markKeep=function(t){pT(t).keep=!0},e.prototype.toggleBlurSeries=function(t,n){var a=this;O(t,function(i){var o=Ki.getMarkerModelFromSeries(i,a.type);if(o){var s=o.getData();s.eachItemGraphicEl(function(l){l&&(n?DH(l):gD(l))})}})},e.type="marker",e})(Rt);function Obe(r,e,t){r.eachSeries(function(n){var a=Ki.getMarkerModelFromSeries(n,t),i=e.get(n.id);if(a&&i&&i.group){var o=dc(a),s=o.z,l=o.zlevel;ub(i.group,s,l)}})}function s4(r,e,t){var n=e.coordinateSystem,a=t.getWidth(),i=t.getHeight(),o=n&&n.getArea&&n.getArea();r.each(function(s){var l=r.getItemModel(s),u=l.get("relativeTo")==="coordinate",c=u?o?o.width:0:a,f=u?o?o.height:0:i,d=u&&o?o.x:0,v=u&&o?o.y:0,g,y=me(l.get("x"),c)+d,x=me(l.get("y"),f)+v;if(!isNaN(y)&&!isNaN(x))g=[y,x];else if(e.getMarkerPosition)g=e.getMarkerPosition(r.getValues(r.dimensions,s));else if(n){var b=r.get(n.dimensions[0],s),w=r.get(n.dimensions[1],s);g=n.dataToPoint([b,w])}isNaN(y)||(g[0]=y),isNaN(x)||(g[1]=x),r.setItemLayout(s,g)})}var Pbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,n,a){n.eachSeries(function(i){var o=Ki.getMarkerModelFromSeries(i,"markPoint");o&&(s4(o.getData(),i,a),this.markerGroupMap.get(i.id).updateLayout())},this)},e.prototype.renderSeries=function(t,n,a,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new em),f=jbe(o,t,n);n.setData(f),s4(n.getData(),t,i),f.each(function(d){var v=f.getItemModel(d),g=v.getShallow("symbol"),y=v.getShallow("symbolSize"),x=v.getShallow("symbolRotate"),b=v.getShallow("symbolOffset"),w=v.getShallow("symbolKeepAspect");if(Me(g)||Me(y)||Me(x)||Me(b)){var T=n.getRawValue(d),C=n.getDataParams(d);Me(g)&&(g=g(T,C)),Me(y)&&(y=y(T,C)),Me(x)&&(x=x(T,C)),Me(b)&&(b=b(T,C))}var D=v.getModel("itemStyle").getItemStyle(),M=v.get("z2"),N=Kg(l,"color");D.fill||(D.fill=N),f.setItemVisual(d,{z2:Ce(M,0),symbol:g,symbolSize:y,symbolRotate:x,symbolOffset:b,symbolKeepAspect:w,style:D})}),c.updateData(f),this.group.add(c.group),f.eachItemGraphicEl(function(d){d.traverse(function(v){je(v).dataModel=n})}),this.markKeep(c),c.group.silent=n.get("silent")||t.get("silent")},e.type="markPoint",e})(_L);function jbe(r,e,t){var n;r?n=fe(r&&r.dimensions,function(s){var l=e.getData().getDimensionInfo(e.getData().mapDimension(s))||{};return ie(ie({},l),{name:s,ordinalMeta:null})}):n=[{name:"value",type:"float"}];var a=new pn(n,t),i=fe(t.get("data"),He(wg,e));r&&(i=dt(i,He(Tg,r)));var o=dY(!!r,n);return a.initData(i,null,o),a}function zbe(r){r.registerComponentModel(Rbe),r.registerComponentView(Pbe),r.registerPreprocessor(function(e){bL(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var Bbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,n,a){return new e(t,n,a)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e})(Ki),j0=Je(),Vbe=function(r,e,t,n){var a=r.getData(),i;if(ce(n))i=n;else{var o=n.type;if(o==="min"||o==="max"||o==="average"||o==="median"||n.xAxis!=null||n.yAxis!=null){var s=void 0,l=void 0;if(n.yAxis!=null||n.xAxis!=null)s=e.getAxis(n.yAxis!=null?"y":"x"),l=Fr(n.yAxis,n.xAxis);else{var u=hY(n,a,e,r);s=u.valueAxis;var c=uN(a,u.valueDataDim);l=C1(a,c,o)}var f=s.dim==="x"?0:1,d=1-f,v=De(n),g={coord:[]};v.type=null,v.coord=[],v.coord[d]=-1/0,g.coord[d]=1/0;var y=t.get("precision");y>=0&&st(l)&&(l=+l.toFixed(Math.min(y,20))),v.coord[f]=g.coord[f]=l,i=[v,g,{type:o,valueIndex:n.valueIndex,value:l}]}else i=[]}var x=[wg(r,i[0]),wg(r,i[1]),ie({},i[2])];return x[2].type=x[2].type||null,Ye(x[2],x[0]),Ye(x[2],x[1]),x};function A1(r){return!isNaN(r)&&!isFinite(r)}function l4(r,e,t,n){var a=1-r,i=n.dimensions[r];return A1(e[a])&&A1(t[a])&&e[r]===t[r]&&n.getAxis(i).containData(e[r])}function Gbe(r,e){if(r.type==="cartesian2d"){var t=e[0].coord,n=e[1].coord;if(t&&n&&(l4(1,t,n,r)||l4(0,t,n,r)))return!0}return Tg(r,e[0])&&Tg(r,e[1])}function gT(r,e,t,n,a){var i=n.coordinateSystem,o=r.getItemModel(e),s,l=me(o.get("x"),a.getWidth()),u=me(o.get("y"),a.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(n.getMarkerPosition)s=n.getMarkerPosition(r.getValues(r.dimensions,e));else{var c=i.dimensions,f=r.get(c[0],e),d=r.get(c[1],e);s=i.dataToPoint([f,d])}if(wl(i,"cartesian2d")){var v=i.getAxis("x"),g=i.getAxis("y"),c=i.dimensions;A1(r.get(c[0],e))?s[0]=v.toGlobalCoord(v.getExtent()[t?0:1]):A1(r.get(c[1],e))&&(s[1]=g.toGlobalCoord(g.getExtent()[t?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}r.setItemLayout(e,s)}var Hbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,n,a){n.eachSeries(function(i){var o=Ki.getMarkerModelFromSeries(i,"markLine");if(o){var s=o.getData(),l=j0(o).from,u=j0(o).to;l.each(function(c){gT(l,c,!0,i,a),gT(u,c,!1,i,a)}),s.each(function(c){s.setItemLayout(c,[l.getItemLayout(c),u.getItemLayout(c)])}),this.markerGroupMap.get(i.id).updateLayout()}},this)},e.prototype.renderSeries=function(t,n,a,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new VN);this.group.add(c.group);var f=Fbe(o,t,n),d=f.from,v=f.to,g=f.line;j0(n).from=d,j0(n).to=v,n.setData(g);var y=n.get("symbol"),x=n.get("symbolSize"),b=n.get("symbolRotate"),w=n.get("symbolOffset");ce(y)||(y=[y,y]),ce(x)||(x=[x,x]),ce(b)||(b=[b,b]),ce(w)||(w=[w,w]),f.from.each(function(C){T(d,C,!0),T(v,C,!1)}),g.each(function(C){var D=g.getItemModel(C),M=D.getModel("lineStyle").getLineStyle();g.setItemLayout(C,[d.getItemLayout(C),v.getItemLayout(C)]);var N=D.get("z2");M.stroke==null&&(M.stroke=d.getItemVisual(C,"style").fill),g.setItemVisual(C,{z2:Ce(N,0),fromSymbolKeepAspect:d.getItemVisual(C,"symbolKeepAspect"),fromSymbolOffset:d.getItemVisual(C,"symbolOffset"),fromSymbolRotate:d.getItemVisual(C,"symbolRotate"),fromSymbolSize:d.getItemVisual(C,"symbolSize"),fromSymbol:d.getItemVisual(C,"symbol"),toSymbolKeepAspect:v.getItemVisual(C,"symbolKeepAspect"),toSymbolOffset:v.getItemVisual(C,"symbolOffset"),toSymbolRotate:v.getItemVisual(C,"symbolRotate"),toSymbolSize:v.getItemVisual(C,"symbolSize"),toSymbol:v.getItemVisual(C,"symbol"),style:M})}),c.updateData(g),f.line.eachItemGraphicEl(function(C){je(C).dataModel=n,C.traverse(function(D){je(D).dataModel=n})});function T(C,D,M){var N=C.getItemModel(D);gT(C,D,M,t,i);var R=N.getModel("itemStyle").getItemStyle();R.fill==null&&(R.fill=Kg(l,"color")),C.setItemVisual(D,{symbolKeepAspect:N.get("symbolKeepAspect"),symbolOffset:Ce(N.get("symbolOffset",!0),w[M?0:1]),symbolRotate:Ce(N.get("symbolRotate",!0),b[M?0:1]),symbolSize:Ce(N.get("symbolSize"),x[M?0:1]),symbol:Ce(N.get("symbol",!0),y[M?0:1]),style:R})}this.markKeep(c),c.group.silent=n.get("silent")||t.get("silent")},e.type="markLine",e})(_L);function Fbe(r,e,t){var n;r?n=fe(r&&r.dimensions,function(u){var c=e.getData().getDimensionInfo(e.getData().mapDimension(u))||{};return ie(ie({},c),{name:u,ordinalMeta:null})}):n=[{name:"value",type:"float"}];var a=new pn(n,t),i=new pn(n,t),o=new pn([],t),s=fe(t.get("data"),He(Vbe,e,r,t));r&&(s=dt(s,He(Gbe,r)));var l=dY(!!r,n);return a.initData(fe(s,function(u){return u[0]}),null,l),i.initData(fe(s,function(u){return u[1]}),null,l),o.initData(fe(s,function(u){return u[2]})),o.hasItemOption=!0,{from:a,to:i,line:o}}function Ube(r){r.registerComponentModel(Bbe),r.registerComponentView(Hbe),r.registerPreprocessor(function(e){bL(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var Ybe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,n,a){return new e(t,n,a)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e})(Ki),z0=Je(),Wbe=function(r,e,t,n){var a=n[0],i=n[1];if(!(!a||!i)){var o=wg(r,a),s=wg(r,i),l=o.coord,u=s.coord;l[0]=Fr(l[0],-1/0),l[1]=Fr(l[1],-1/0),u[0]=Fr(u[0],1/0),u[1]=Fr(u[1],1/0);var c=W1([{},o,s]);return c.coord=[o.coord,s.coord],c.x0=o.x,c.y0=o.y,c.x1=s.x,c.y1=s.y,c}};function M1(r){return!isNaN(r)&&!isFinite(r)}function u4(r,e,t,n){var a=1-r;return M1(e[a])&&M1(t[a])}function Xbe(r,e){var t=e.coord[0],n=e.coord[1],a={coord:t,x:e.x0,y:e.y0},i={coord:n,x:e.x1,y:e.y1};return wl(r,"cartesian2d")?t&&n&&(u4(1,t,n)||u4(0,t,n))?!0:Ibe(r,a,i):Tg(r,a)||Tg(r,i)}function c4(r,e,t,n,a){var i=n.coordinateSystem,o=r.getItemModel(e),s,l=me(o.get(t[0]),a.getWidth()),u=me(o.get(t[1]),a.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(n.getMarkerPosition){var c=r.getValues(["x0","y0"],e),f=r.getValues(["x1","y1"],e),d=i.clampData(c),v=i.clampData(f),g=[];t[0]==="x0"?g[0]=d[0]>v[0]?f[0]:c[0]:g[0]=d[0]>v[0]?c[0]:f[0],t[1]==="y0"?g[1]=d[1]>v[1]?f[1]:c[1]:g[1]=d[1]>v[1]?c[1]:f[1],s=n.getMarkerPosition(g,t,!0)}else{var y=r.get(t[0],e),x=r.get(t[1],e),b=[y,x];i.clampData&&i.clampData(b,b),s=i.dataToPoint(b,!0)}if(wl(i,"cartesian2d")){var w=i.getAxis("x"),T=i.getAxis("y"),y=r.get(t[0],e),x=r.get(t[1],e);M1(y)?s[0]=w.toGlobalCoord(w.getExtent()[t[0]==="x0"?0:1]):M1(x)&&(s[1]=T.toGlobalCoord(T.getExtent()[t[1]==="y0"?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}return s}var f4=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],qbe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,n,a){n.eachSeries(function(i){var o=Ki.getMarkerModelFromSeries(i,"markArea");if(o){var s=o.getData();s.each(function(l){var u=fe(f4,function(f){return c4(s,l,f,i,a)});s.setItemLayout(l,u);var c=s.getItemGraphicEl(l);c.setShape("points",u)})}},this)},e.prototype.renderSeries=function(t,n,a,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,{group:new Ne});this.group.add(c.group),this.markKeep(c);var f=Zbe(o,t,n);n.setData(f),f.each(function(d){var v=fe(f4,function(k){return c4(f,d,k,t,i)}),g=o.getAxis("x").scale,y=o.getAxis("y").scale,x=g.getExtent(),b=y.getExtent(),w=[g.parse(f.get("x0",d)),g.parse(f.get("x1",d))],T=[y.parse(f.get("y0",d)),y.parse(f.get("y1",d))];na(w),na(T);var C=!(x[0]>w[1]||x[1]<w[0]||b[0]>T[1]||b[1]<T[0]),D=!C;f.setItemLayout(d,{points:v,allClipped:D});var M=f.getItemModel(d),N=M.getModel("itemStyle").getItemStyle(),R=M.get("z2"),E=Kg(l,"color");N.fill||(N.fill=E,ye(N.fill)&&(N.fill=Kp(N.fill,.4))),N.stroke||(N.stroke=E),f.setItemVisual(d,"style",N),f.setItemVisual(d,"z2",Ce(R,0))}),f.diff(z0(c).data).add(function(d){var v=f.getItemLayout(d),g=f.getItemVisual(d,"z2");if(!v.allClipped){var y=new an({z2:Ce(g,0),shape:{points:v.points}});f.setItemGraphicEl(d,y),c.group.add(y)}}).update(function(d,v){var g=z0(c).data.getItemGraphicEl(v),y=f.getItemLayout(d),x=f.getItemVisual(d,"z2");y.allClipped?g&&c.group.remove(g):(g?lt(g,{z2:Ce(x,0),shape:{points:y.points}},n,d):g=new an({shape:{points:y.points}}),f.setItemGraphicEl(d,g),c.group.add(g))}).remove(function(d){var v=z0(c).data.getItemGraphicEl(d);c.group.remove(v)}).execute(),f.eachItemGraphicEl(function(d,v){var g=f.getItemModel(v),y=f.getItemVisual(v,"style");d.useStyle(f.getItemVisual(v,"style")),kr(d,Sr(g),{labelFetcher:n,labelDataIndex:v,defaultText:f.getName(v)||"",inheritColor:ye(y.fill)?Kp(y.fill,1):ee.color.neutral99}),_r(d,g),Ut(d,null,null,g.get(["emphasis","disabled"])),je(d).dataModel=n}),z0(c).data=f,c.group.silent=n.get("silent")||t.get("silent")},e.type="markArea",e})(_L);function Zbe(r,e,t){var n,a,i=["x0","y0","x1","y1"];if(r){var o=fe(r&&r.dimensions,function(u){var c=e.getData(),f=c.getDimensionInfo(c.mapDimension(u))||{};return ie(ie({},f),{name:u,ordinalMeta:null})});a=fe(i,function(u,c){return{name:u,type:o[c%2].type}}),n=new pn(a,t)}else a=[{name:"value",type:"float"}],n=new pn(a,t);var s=fe(t.get("data"),He(Wbe,e,r,t));r&&(s=dt(s,He(Xbe,r)));var l=r?function(u,c,f,d){var v=u.coord[Math.floor(d/2)][d%2];return pl(v,a[d])}:function(u,c,f,d){return pl(u.value,a[d])};return n.initData(s,null,l),n.hasItemOption=!0,n}function $be(r){r.registerComponentModel(Ybe),r.registerComponentView(qbe),r.registerPreprocessor(function(e){bL(e.series,"markArea")&&(e.markArea=e.markArea||{})})}var Kbe=function(r,e){if(e==="all")return{type:"all",title:r.getLocaleModel().get(["legend","selector","all"])};if(e==="inverse")return{type:"inverse",title:r.getLocaleModel().get(["legend","selector","inverse"])}},sM=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a),t.selected=t.selected||{},this._updateSelector(t)},e.prototype.mergeOption=function(t,n){r.prototype.mergeOption.call(this,t,n),this._updateSelector(t)},e.prototype._updateSelector=function(t){var n=t.selector,a=this.ecModel;n===!0&&(n=t.selector=["all","inverse"]),ce(n)&&O(n,function(i,o){ye(i)&&(i={type:i}),n[o]=Ye(i,Kbe(a,i.type))})},e.prototype.optionUpdated=function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&this.get("selectedMode")==="single"){for(var n=!1,a=0;a<t.length;a++){var i=t[a].get("name");if(this.isSelected(i)){this.select(i),n=!0;break}}!n&&this.select(t[0].get("name"))}},e.prototype._updateData=function(t){var n=[],a=[];t.eachRawSeries(function(l){var u=l.name;a.push(u);var c;if(l.legendVisualProvider){var f=l.legendVisualProvider,d=f.getAllNames();t.isSeriesFiltered(l)||(a=a.concat(d)),d.length?n=n.concat(d):c=!0}else c=!0;c&&sD(l)&&n.push(l.name)}),this._availableNames=a;var i=this.get("data")||n,o=Te(),s=fe(i,function(l){return(ye(l)||st(l))&&(l={name:l}),o.get(l.name)?null:(o.set(l.name,!0),new et(l,this,this.ecModel))},this);this._data=dt(s,function(l){return!!l})},e.prototype.getData=function(){return this._data},e.prototype.select=function(t){var n=this.option.selected,a=this.get("selectedMode");if(a==="single"){var i=this._data;O(i,function(o){n[o.get("name")]=!1})}n[t]=!0},e.prototype.unSelect=function(t){this.get("selectedMode")!=="single"&&(this.option.selected[t]=!1)},e.prototype.toggleSelected=function(t){var n=this.option.selected;n.hasOwnProperty(t)||(n[t]=!0),this[n[t]?"unSelect":"select"](t)},e.prototype.allSelect=function(){var t=this._data,n=this.option.selected;O(t,function(a){n[a.get("name",!0)]=!0})},e.prototype.inverseSelect=function(){var t=this._data,n=this.option.selected;O(t,function(a){var i=a.get("name",!0);n.hasOwnProperty(i)||(n[i]=!0),n[i]=!n[i]})},e.prototype.isSelected=function(t){var n=this.option.selected;return!(n.hasOwnProperty(t)&&!n[t])&&Fe(this._availableNames,t)>=0},e.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",bottom:ee.size.m,align:"auto",backgroundColor:ee.color.transparent,borderColor:ee.color.border,borderRadius:0,borderWidth:0,padding:5,itemGap:8,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:ee.color.disabled,inactiveBorderColor:ee.color.disabled,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:ee.color.disabled,inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:ee.color.secondary},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:ee.color.tertiary,borderWidth:1,borderColor:ee.color.border},emphasis:{selectorLabel:{show:!0,color:ee.color.quaternary}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1},triggerEvent:!1},e})(Qe),zf=He,lM=O,B0=Ne,vY=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return e.prototype.init=function(){this.group.add(this._contentGroup=new B0),this.group.add(this._selectorGroup=new B0),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,n,a){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!t.get("show",!0)){var o=t.get("align"),s=t.get("orient");(!o||o==="auto")&&(o=t.get("left")==="right"&&s==="vertical"?"right":"left");var l=t.get("selector",!0),u=t.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,t,n,a,l,s,u);var c=Cr(t,a).refContainer,f=t.getBoxLayoutParams(),d=t.get("padding"),v=Ht(f,c,d),g=this.layoutInner(t,o,v,i,l,u),y=Ht(Re({width:g.width,height:g.height},f),c,d);this.group.x=y.x-g.x,this.group.y=y.y-g.y,this.group.markRedraw(),this.group.add(this._backgroundEl=rY(g,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,n,a,i,o,s,l){var u=this.getContentGroup(),c=Te(),f=n.get("selectedMode"),d=n.get("triggerEvent"),v=[];a.eachRawSeries(function(g){!g.get("legendHoverLink")&&v.push(g.id)}),lM(n.getData(),function(g,y){var x=this,b=g.get("name");if(!this.newlineDisabled&&(b===""||b===`
302
- `)){var w=new B0;w.newline=!0,u.add(w);return}var T=a.getSeriesByName(b)[0];if(!c.get(b))if(T){var C=T.getData(),D=C.getVisual("legendLineStyle")||{},M=C.getVisual("legendIcon"),N=C.getVisual("style"),R=this._createItem(T,b,y,g,n,t,D,N,M,f,i);R.on("click",zf(h4,b,null,i,v)).on("mouseover",zf(uM,T.name,null,i,v)).on("mouseout",zf(cM,T.name,null,i,v)),a.ssr&&R.eachChild(function(E){var k=je(E);k.seriesIndex=T.seriesIndex,k.dataIndex=y,k.ssrType="legend"}),d&&R.eachChild(function(E){x.packEventData(E,n,T,y,b)}),c.set(b,!0)}else a.eachRawSeries(function(E){var k=this;if(!c.get(b)&&E.legendVisualProvider){var I=E.legendVisualProvider;if(!I.containName(b))return;var B=I.indexOfName(b),P=I.getItemVisual(B,"style"),H=I.getItemVisual(B,"legendIcon"),V=vn(P.fill);V&&V[3]===0&&(V[3]=.2,P=ie(ie({},P),{fill:Ea(V,"rgba")}));var j=this._createItem(E,b,y,g,n,t,{},P,H,f,i);j.on("click",zf(h4,null,b,i,v)).on("mouseover",zf(uM,null,b,i,v)).on("mouseout",zf(cM,null,b,i,v)),a.ssr&&j.eachChild(function(U){var F=je(U);F.seriesIndex=E.seriesIndex,F.dataIndex=y,F.ssrType="legend"}),d&&j.eachChild(function(U){k.packEventData(U,n,E,y,b)}),c.set(b,!0)}},this)},this),o&&this._createSelector(o,n,i,s,l)},e.prototype.packEventData=function(t,n,a,i,o){var s={componentType:"legend",componentIndex:n.componentIndex,dataIndex:i,value:o,seriesIndex:a.seriesIndex};je(t).eventData=s},e.prototype._createSelector=function(t,n,a,i,o){var s=this.getSelectorGroup();lM(t,function(u){var c=u.type,f=new ot({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){a.dispatchAction({type:c==="all"?"legendAllSelect":"legendInverseSelect",legendId:n.id})}});s.add(f);var d=n.getModel("selectorLabel"),v=n.getModel(["emphasis","selectorLabel"]);kr(f,{normal:d,emphasis:v},{defaultText:u.title}),hl(f)})},e.prototype._createItem=function(t,n,a,i,o,s,l,u,c,f,d){var v=t.visualDrawType,g=o.get("itemWidth"),y=o.get("itemHeight"),x=o.isSelected(n),b=i.get("symbolRotate"),w=i.get("symbolKeepAspect"),T=i.get("icon");c=T||c||"roundRect";var C=Qbe(c,i,l,u,v,x,d),D=new B0,M=i.getModel("textStyle");if(Me(t.getLegendIcon)&&(!T||T==="inherit"))D.add(t.getLegendIcon({itemWidth:g,itemHeight:y,icon:c,iconRotate:b,itemStyle:C.itemStyle,lineStyle:C.lineStyle,symbolKeepAspect:w}));else{var N=T==="inherit"&&t.getData().getVisual("symbol")?b==="inherit"?t.getData().getVisual("symbolRotate"):b:0;D.add(Jbe({itemWidth:g,itemHeight:y,icon:c,iconRotate:N,itemStyle:C.itemStyle,symbolKeepAspect:w}))}var R=s==="left"?g+5:-5,E=s,k=o.get("formatter"),I=n;ye(k)&&k?I=k.replace("{name}",n??""):Me(k)&&(I=k(n));var B=x?M.getTextColor():i.get("inactiveColor");D.add(new ot({style:Nt(M,{text:I,x:R,y:y/2,fill:B,align:E,verticalAlign:"middle"},{inheritColor:B})}));var P=new qe({shape:D.getBoundingRect(),style:{fill:"transparent"}}),H=i.getModel("tooltip");return H.get("show")&&is({el:P,componentModel:o,itemName:n,itemTooltipOption:H.option}),D.add(P),D.eachChild(function(V){V.silent=!0}),P.silent=!f,this.getContentGroup().add(D),hl(D),D.__legendDataIndex=a,D},e.prototype.layoutInner=function(t,n,a,i,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();rc(t.get("orient"),l,t.get("itemGap"),a.width,a.height);var c=l.getBoundingRect(),f=[-c.x,-c.y];if(u.markRedraw(),l.markRedraw(),o){rc("horizontal",u,t.get("selectorItemGap",!0));var d=u.getBoundingRect(),v=[-d.x,-d.y],g=t.get("selectorButtonGap",!0),y=t.getOrient().index,x=y===0?"width":"height",b=y===0?"height":"width",w=y===0?"y":"x";s==="end"?v[y]+=c[x]+g:f[y]+=d[x]+g,v[1-y]+=c[b]/2-d[b]/2,u.x=v[0],u.y=v[1],l.x=f[0],l.y=f[1];var T={x:0,y:0};return T[x]=c[x]+g+d[x],T[b]=Math.max(c[b],d[b]),T[w]=Math.min(0,d[w]+v[1-y]),T}else return l.x=f[0],l.y=f[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e})(Rt);function Qbe(r,e,t,n,a,i,o){function s(x,b){x.lineWidth==="auto"&&(x.lineWidth=b.lineWidth>0?2:0),lM(x,function(w,T){x[T]==="inherit"&&(x[T]=b[T])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),c=r.lastIndexOf("empty",0)===0?"fill":"stroke",f=l.getShallow("decal");u.decal=!f||f==="inherit"?n.decal:zh(f,o),u.fill==="inherit"&&(u.fill=n[a]),u.stroke==="inherit"&&(u.stroke=n[c]),u.opacity==="inherit"&&(u.opacity=(a==="fill"?n:t).opacity),s(u,n);var d=e.getModel("lineStyle"),v=d.getLineStyle();if(s(v,t),u.fill==="auto"&&(u.fill=n.fill),u.stroke==="auto"&&(u.stroke=n.fill),v.stroke==="auto"&&(v.stroke=n.fill),!i){var g=e.get("inactiveBorderWidth"),y=u[c];u.lineWidth=g==="auto"?n.lineWidth>0&&y?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),v.stroke=d.get("inactiveColor"),v.lineWidth=d.get("inactiveWidth")}return{itemStyle:u,lineStyle:v}}function Jbe(r){var e=r.icon||"roundRect",t=ur(e,0,0,r.itemWidth,r.itemHeight,r.itemStyle.fill,r.symbolKeepAspect);return t.setStyle(r.itemStyle),t.rotation=(r.iconRotate||0)*Math.PI/180,t.setOrigin([r.itemWidth/2,r.itemHeight/2]),e.indexOf("empty")>-1&&(t.style.stroke=t.style.fill,t.style.fill=ee.color.neutral00,t.style.lineWidth=2),t}function h4(r,e,t,n){cM(r,e,t,n),t.dispatchAction({type:"legendToggleSelect",name:r??e}),uM(r,e,t,n)}function pY(r){for(var e=r.getZr().storage.getDisplayList(),t,n=0,a=e.length;n<a&&!(t=e[n].states.emphasis);)n++;return t&&t.hoverLayer}function uM(r,e,t,n){pY(t)||t.dispatchAction({type:"highlight",seriesName:r,name:e,excludeSeriesId:n})}function cM(r,e,t,n){pY(t)||t.dispatchAction({type:"downplay",seriesName:r,name:e,excludeSeriesId:n})}function e_e(r){var e=r.findComponents({mainType:"legend"});e&&e.length&&r.filterSeries(function(t){for(var n=0;n<e.length;n++)if(!e[n].isSelected(t.name))return!1;return!0})}function Kv(r,e,t){var n=r==="allSelect"||r==="inverseSelect",a={},i=[];t.eachComponent({mainType:"legend",query:e},function(s){n?s[r]():s[r](e.name),d4(s,a),i.push(s.componentIndex)});var o={};return t.eachComponent("legend",function(s){O(a,function(l,u){s[l?"select":"unSelect"](u)}),d4(s,o)}),n?{selected:o,legendIndex:i}:{name:e.name,selected:o}}function d4(r,e){var t=e||{};return O(r.getData(),function(n){var a=n.get("name");if(!(a===`
303
- `||a==="")){var i=r.isSelected(a);_e(t,a)?t[a]=t[a]&&i:t[a]=i}}),t}function t_e(r){r.registerAction("legendToggleSelect","legendselectchanged",He(Kv,"toggleSelected")),r.registerAction("legendAllSelect","legendselectall",He(Kv,"allSelect")),r.registerAction("legendInverseSelect","legendinverseselect",He(Kv,"inverseSelect")),r.registerAction("legendSelect","legendselected",He(Kv,"select")),r.registerAction("legendUnSelect","legendunselected",He(Kv,"unSelect"))}function gY(r){r.registerComponentModel(sM),r.registerComponentView(vY),r.registerProcessor(r.PRIORITY.PROCESSOR.SERIES_FILTER,e_e),r.registerSubTypeDefaulter("legend",function(){return"plain"}),t_e(r)}var r_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.setScrollDataIndex=function(t){this.option.scrollDataIndex=t},e.prototype.init=function(t,n,a){var i=Sc(t);r.prototype.init.call(this,t,n,a),v4(this,t,i)},e.prototype.mergeOption=function(t,n){r.prototype.mergeOption.call(this,t,n),v4(this,this.option,t)},e.type="legend.scroll",e.defaultOption=Rl(sM.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:ee.color.accent50,pageIconInactiveColor:ee.color.accent10,pageIconSize:15,pageTextStyle:{color:ee.color.tertiary},animationDurationUpdate:800}),e})(sM);function v4(r,e,t){var n=r.getOrient(),a=[1,1];a[n.index]=0,Zi(e,t,{type:"box",ignoreSize:!!a})}var p4=Ne,mT=["width","height"],yT=["x","y"],n_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!0,t._currentIndex=0,t}return e.prototype.init=function(){r.prototype.init.call(this),this.group.add(this._containerGroup=new p4),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new p4)},e.prototype.resetInner=function(){r.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},e.prototype.renderInner=function(t,n,a,i,o,s,l){var u=this;r.prototype.renderInner.call(this,t,n,a,i,o,s,l);var c=this._controllerGroup,f=n.get("pageIconSize",!0),d=ce(f)?f:[f,f];g("pagePrev",0);var v=n.getModel("pageTextStyle");c.add(new ot({name:"pageText",style:{text:"xx/xx",fill:v.getTextColor(),font:v.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),g("pageNext",1);function g(y,x){var b=y+"DataIndex",w=ad(n.get("pageIcons",!0)[n.getOrient().name][x],{onclick:xe(u._pageGo,u,b,n,i)},{x:-d[0]/2,y:-d[1]/2,width:d[0],height:d[1]});w.name=y,c.add(w)}},e.prototype.layoutInner=function(t,n,a,i,o,s){var l=this.getSelectorGroup(),u=t.getOrient().index,c=mT[u],f=yT[u],d=mT[1-u],v=yT[1-u];o&&rc("horizontal",l,t.get("selectorItemGap",!0));var g=t.get("selectorButtonGap",!0),y=l.getBoundingRect(),x=[-y.x,-y.y],b=De(a);o&&(b[c]=a[c]-y[c]-g);var w=this._layoutContentAndController(t,i,b,u,c,d,v,f);if(o){if(s==="end")x[u]+=w[c]+g;else{var T=y[c]+g;x[u]-=T,w[f]-=T}w[c]+=y[c]+g,x[1-u]+=w[v]+w[d]/2-y[d]/2,w[d]=Math.max(w[d],y[d]),w[v]=Math.min(w[v],y[v]+x[1-u]),l.x=x[0],l.y=x[1],l.markRedraw()}return w},e.prototype._layoutContentAndController=function(t,n,a,i,o,s,l,u){var c=this.getContentGroup(),f=this._containerGroup,d=this._controllerGroup;rc(t.get("orient"),c,t.get("itemGap"),i?a.width:null,i?null:a.height),rc("horizontal",d,t.get("pageButtonItemGap",!0));var v=c.getBoundingRect(),g=d.getBoundingRect(),y=this._showController=v[o]>a[o],x=[-v.x,-v.y];n||(x[i]=c[u]);var b=[0,0],w=[-g.x,-g.y],T=Ce(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(y){var C=t.get("pageButtonPosition",!0);C==="end"?w[i]+=a[o]-g[o]:b[i]+=g[o]+T}w[1-i]+=v[s]/2-g[s]/2,c.setPosition(x),f.setPosition(b),d.setPosition(w);var D={x:0,y:0};if(D[o]=y?a[o]:v[o],D[s]=Math.max(v[s],g[s]),D[l]=Math.min(0,g[l]+w[1-i]),f.__rectSize=a[o],y){var M={x:0,y:0};M[o]=Math.max(a[o]-g[o]-T,0),M[s]=D[s],f.setClipPath(new qe({shape:M})),f.__rectSize=M[o]}else d.eachChild(function(R){R.attr({invisible:!0,silent:!0})});var N=this._getPageInfo(t);return N.pageIndex!=null&&lt(c,{x:N.contentPosition[0],y:N.contentPosition[1]},y?t:null),this._updatePageInfoView(t,N),D},e.prototype._pageGo=function(t,n,a){var i=this._getPageInfo(n)[t];i!=null&&a.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:n.id})},e.prototype._updatePageInfoView=function(t,n){var a=this._controllerGroup;O(["pagePrev","pageNext"],function(c){var f=c+"DataIndex",d=n[f]!=null,v=a.childOfName(c);v&&(v.setStyle("fill",d?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),v.cursor=d?"pointer":"default")});var i=a.childOfName("pageText"),o=t.get("pageFormatter"),s=n.pageIndex,l=s!=null?s+1:0,u=n.pageCount;i&&o&&i.setStyle("text",ye(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},e.prototype._getPageInfo=function(t){var n=t.get("scrollDataIndex",!0),a=this.getContentGroup(),i=this._containerGroup.__rectSize,o=t.getOrient().index,s=mT[o],l=yT[o],u=this._findTargetItemIndex(n),c=a.children(),f=c[u],d=c.length,v=d?1:0,g={contentPosition:[a.x,a.y],pageCount:v,pageIndex:v-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!f)return g;var y=C(f);g.contentPosition[o]=-y.s;for(var x=u+1,b=y,w=y,T=null;x<=d;++x)T=C(c[x]),(!T&&w.e>b.s+i||T&&!D(T,b.s))&&(w.i>b.i?b=w:b=T,b&&(g.pageNextDataIndex==null&&(g.pageNextDataIndex=b.i),++g.pageCount)),w=T;for(var x=u-1,b=y,w=y,T=null;x>=-1;--x)T=C(c[x]),(!T||!D(w,T.s))&&b.i<w.i&&(w=b,g.pagePrevDataIndex==null&&(g.pagePrevDataIndex=b.i),++g.pageCount,++g.pageIndex),b=T;return g;function C(M){if(M){var N=M.getBoundingRect(),R=N[l]+M[l];return{s:R,e:R+N[s],i:M.__legendDataIndex}}}function D(M,N){return M.e>=N&&M.s<=N+i}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var n,a=this.getContentGroup(),i;return a.eachChild(function(o,s){var l=o.__legendDataIndex;i==null&&l!=null&&(i=s),l===t&&(n=s)}),n??i},e.type="legend.scroll",e})(vY);function a_e(r){r.registerAction("legendScroll","legendscroll",function(e,t){var n=e.scrollDataIndex;n!=null&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(a){a.setScrollDataIndex(n)})})}function i_e(r){We(gY),r.registerComponentModel(r_e),r.registerComponentView(n_e),a_e(r)}function o_e(r){We(gY),We(i_e)}var s_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=Rl(Sg.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e})(Sg),SL=Je();function l_e(r,e,t){SL(r).coordSysRecordMap.each(function(n){var a=n.dataZoomInfoMap.get(e.uid);a&&(a.getRange=t)})}function u_e(r,e){for(var t=SL(r).coordSysRecordMap,n=t.keys(),a=0;a<n.length;a++){var i=n[a],o=t.get(i),s=o.dataZoomInfoMap;if(s){var l=e.uid,u=s.get(l);u&&(s.removeKey(l),s.keys().length||mY(t,o))}}}function mY(r,e){if(e){r.removeKey(e.model.uid);var t=e.controller;t&&t.dispose()}}function c_e(r,e){var t={model:e,containsPoint:He(h_e,e),dispatchAction:He(f_e,r),dataZoomInfoMap:null,controller:null},n=t.controller=new Ac(r.getZr());return O(["pan","zoom","scrollMove"],function(a){n.on(a,function(i){var o=[];t.dataZoomInfoMap.each(function(s){if(i.isAvailableBehavior(s.model.option)){var l=(s.getRange||{})[a],u=l&&l(s.dzReferCoordSysInfo,t.model.mainType,t.controller,i);!s.model.get("disabled",!0)&&u&&o.push({dataZoomId:s.model.id,start:u[0],end:u[1]})}}),o.length&&t.dispatchAction(o)})}),t}function f_e(r,e){r.isDisposed()||r.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function h_e(r,e,t,n){return r.coordinateSystem.containPoint([t,n])}function d_e(r,e,t){var n,a="type_",i={type_true:2,type_move:1,type_false:0,type_undefined:-1},o=!0;return r.each(function(s){var l=s.model,u=l.get("disabled",!0)?!1:l.get("zoomLock",!0)?"move":!0;i[a+u]>i[a+n]&&(n=u),o=o&&l.get("preventDefaultMouseMove",!0)}),{controlType:n,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!o,api:t,zInfo:{component:e.model},triggerInfo:{roamTrigger:null,isInSelf:e.containsPoint}}}}function v_e(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(e,t){var n=SL(t),a=n.coordSysRecordMap||(n.coordSysRecordMap=Te());a.each(function(i){i.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(i){var o=J9(i);O(o.infoList,function(s){var l=s.model.uid,u=a.get(l)||a.set(l,c_e(t,s.model)),c=u.dataZoomInfoMap||(u.dataZoomInfoMap=Te());c.set(i.uid,{dzReferCoordSysInfo:s,model:i,getRange:null})})}),a.each(function(i){var o=i.controller,s,l=i.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){mY(a,i);return}var c=d_e(l,i,t);o.enable(c.controlType,c.opt),cd(i,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var p_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,n,a){if(r.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),l_e(a,t,{pan:xe(xT.pan,this),zoom:xe(xT.zoom,this),scrollMove:xe(xT.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){u_e(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e})(vL),xT={zoom:function(r,e,t,n){var a=this.range,i=a.slice(),o=r.axisModels[0];if(o){var s=bT[e](null,[n.originX,n.originY],o,t,r),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(i[1]-i[0])+i[0],u=Math.max(1/n.scale,0);i[0]=(i[0]-l)*u+l,i[1]=(i[1]-l)*u+l;var c=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Tl(0,i,[0,100],0,c.minSpan,c.maxSpan),this.range=i,a[0]!==i[0]||a[1]!==i[1])return i}},pan:g4(function(r,e,t,n,a,i){var o=bT[n]([i.oldX,i.oldY],[i.newX,i.newY],e,a,t);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:g4(function(r,e,t,n,a,i){var o=bT[n]([0,0],[i.scrollDelta,i.scrollDelta],e,a,t);return o.signal*(r[1]-r[0])*i.scrollDelta})};function g4(r){return function(e,t,n,a){var i=this.range,o=i.slice(),s=e.axisModels[0];if(s){var l=r(o,s,e,t,n,a);if(Tl(l,o,[0,100],"all"),this.range=o,i[0]!==o[0]||i[1]!==o[1])return o}}}var bT={grid:function(r,e,t,n,a){var i=t.axis,o={},s=a.model.coordinateSystem.getRect();return r=r||[0,0],i.dim==="x"?(o.pixel=e[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=i.inverse?-1:1),o},polar:function(r,e,t,n,a){var i=t.axis,o={},s=a.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return r=r?s.pointToCoord(r):[0,0],e=s.pointToCoord(e),t.mainType==="radiusAxis"?(o.pixel=e[0]-r[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=i.inverse?-1:1),o},singleAxis:function(r,e,t,n,a){var i=t.axis,o=a.model.coordinateSystem.getRect(),s={};return r=r||[0,0],i.orient==="horizontal"?(s.pixel=e[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=i.inverse?1:-1):(s.pixel=e[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=i.inverse?-1:1),s}};function yY(r){pL(r),r.registerComponentModel(s_e),r.registerComponentView(p_e),v_e(r)}var g_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=Rl(Sg.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:ee.color.accent10,borderRadius:0,backgroundColor:ee.color.transparent,dataBackground:{lineStyle:{color:ee.color.accent30,width:.5},areaStyle:{color:ee.color.accent20,opacity:.2}},selectedDataBackground:{lineStyle:{color:ee.color.accent40,width:.5},areaStyle:{color:ee.color.accent20,opacity:.3}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:ee.color.neutral00,borderColor:ee.color.accent20},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:ee.color.accent40,opacity:.5},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:ee.color.tertiary},brushSelect:!0,brushStyle:{color:ee.color.accent30,opacity:.3},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:ee.color.accent40},moveHandleStyle:{opacity:.8}},defaultLocationEdgeGap:15}),e})(Sg),Qv=qe,m_e=1,_T=30,y_e=7,Jv="horizontal",m4="vertical",x_e=5,b_e=["line","bar","candlestick","scatter"],__e={easing:"cubicOut",duration:100,delay:0},S_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._displayables={},t}return e.prototype.init=function(t,n){this.api=n,this._onBrush=xe(this._onBrush,this),this._onBrushEnd=xe(this._onBrushEnd,this)},e.prototype.render=function(t,n,a,i){if(r.prototype.render.apply(this,arguments),cd(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),t.get("show")===!1){this.group.removeAll();return}if(t.noTarget()){this._clear(),this.group.removeAll();return}(!i||i.type!=="dataZoom"||i.from!==this.uid)&&this._buildView(),this._updateView()},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){sg(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var n=this._displayables.sliderGroup=new Ne;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(n),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,n=this.api,a=t.get("brushSelect"),i=a?y_e:0,o=Cr(t,n).refContainer,s=this._findCoordRect(),l=t.get("defaultLocationEdgeGap",!0)||0,u=this._orient===Jv?{right:o.width-s.x-s.width,top:o.height-_T-l-i,width:s.width,height:_T}:{right:l,top:s.y,width:_T,height:s.height},c=Sc(t.option);O(["right","top","width","height"],function(d){c[d]==="ph"&&(c[d]=u[d])});var f=Ht(c,o);this._location={x:f.x,y:f.y},this._size=[f.width,f.height],this._orient===m4&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,n=this._location,a=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),o=i&&i.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(a===Jv&&!o?{scaleY:l?1:-1,scaleX:1}:a===Jv&&o?{scaleY:l?1:-1,scaleX:-1}:a===m4&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=t.getBoundingRect([s]);t.x=n.x-u.x,t.y=n.y-u.y,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,n=this._size,a=this._displayables.sliderGroup,i=t.get("brushSelect");a.add(new Qv({silent:!0,shape:{x:0,y:0,width:n[0],height:n[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var o=new Qv({shape:{x:0,y:0,width:n[0],height:n[1]},style:{fill:"transparent"},z2:0,onclick:xe(this._onClickPanel,this)}),s=this.api.getZr();i?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),a.add(o)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var n=this._size,a=this._shadowSize||[],i=t.series,o=i.getRawData(),s=i.getShadowDim&&i.getShadowDim(),l=s&&o.getDimensionInfo(s)?i.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,c=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||n[0]!==a[0]||n[1]!==a[1]){var f=o.getDataExtent(t.thisDim),d=o.getDataExtent(l),v=(d[1]-d[0])*.3;d=[d[0]-v,d[1]+v];var g=[0,n[1]],y=[0,n[0]],x=[[n[0],0],[0,0]],b=[],w=y[1]/Math.max(1,o.count()-1),T=n[0]/(f[1]-f[0]),C=t.thisAxis.type==="time",D=-w,M=Math.round(o.count()/n[0]),N;o.each([t.thisDim,l],function(B,P,H){if(M>0&&H%M){C||(D+=w);return}D=C?(+B-f[0])*T:D+w;var V=P==null||isNaN(P)||P==="",j=V?0:pt(P,d,g,!0);V&&!N&&H?(x.push([x[x.length-1][0],0]),b.push([b[b.length-1][0],0])):!V&&N&&(x.push([D,0]),b.push([D,0])),V||(x.push([D,j]),b.push([D,j])),N=V}),u=this._shadowPolygonPts=x,c=this._shadowPolylinePts=b}this._shadowData=o,this._shadowDim=l,this._shadowSize=[n[0],n[1]];var R=this.dataZoomModel;function E(B){var P=R.getModel(B?"selectedDataBackground":"dataBackground"),H=new Ne,V=new an({shape:{points:u},segmentIgnoreThreshold:1,style:P.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),j=new Ur({shape:{points:c},segmentIgnoreThreshold:1,style:P.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return H.add(V),H.add(j),H}for(var k=0;k<3;k++){var I=E(k===1);this._displayables.sliderGroup.add(I),this._displayables.dataShadowSegs.push(I)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,n=t.get("showDataShadow");if(n!==!1){var a,i=this.ecModel;return t.eachTargetAxis(function(o,s){var l=t.getAxisProxy(o,s).getTargetSeriesModels();O(l,function(u){if(!a&&!(n!==!0&&Fe(b_e,u.get("type"))<0)){var c=i.getComponent(ol(o),s).axis,f=w_e(o),d,v=u.coordinateSystem;f!=null&&v.getOtherAxis&&(d=v.getOtherAxis(c).inverse),f=u.getData().mapDimension(f);var g=u.getData().mapDimension(o);a={thisAxis:c,series:u,thisDim:g,otherDim:f,otherAxisInverse:d}}},this)},this),a}},e.prototype._renderHandle=function(){var t=this.group,n=this._displayables,a=n.handles=[null,null],i=n.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,c=l.get("borderRadius")||0,f=l.get("brushSelect"),d=n.filler=new Qv({silent:f,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(d),o.add(new Qv({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:c},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:m_e,fill:ee.color.transparent}})),O([0,1],function(T){var C=l.get("handleIcon");!Xx[C]&&C.indexOf("path://")<0&&C.indexOf("image://")<0&&(C="path://"+C);var D=ur(C,-1,0,2,2,null,!0);D.attr({cursor:T_e(this._orient),draggable:!0,drift:xe(this._onDragMove,this,T),ondragend:xe(this._onDragEnd,this),onmouseover:xe(this._showDataInfo,this,!0),onmouseout:xe(this._showDataInfo,this,!1),z2:5});var M=D.getBoundingRect(),N=l.get("handleSize");this._handleHeight=me(N,this._size[1]),this._handleWidth=M.width/M.height*this._handleHeight,D.setStyle(l.getModel("handleStyle").getItemStyle()),D.style.strokeNoScale=!0,D.rectHover=!0,D.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),hl(D);var R=l.get("handleColor");R!=null&&(D.style.fill=R),o.add(a[T]=D);var E=l.getModel("textStyle"),k=l.get("handleLabel")||{},I=k.show||!1;t.add(i[T]=new ot({silent:!0,invisible:!I,style:Nt(E,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:E.getTextColor(),font:E.getFont()}),z2:10}))},this);var v=d;if(f){var g=me(l.get("moveHandleSize"),s[1]),y=n.moveHandle=new qe({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:g}}),x=g*.8,b=n.moveHandleIcon=ur(l.get("moveHandleIcon"),-x/2,-x/2,x,x,ee.color.neutral00,!0);b.silent=!0,b.y=s[1]+g/2-.5,y.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var w=Math.min(s[1]/2,Math.max(g,10));v=n.moveZone=new qe({invisible:!0,shape:{y:s[1]-w,height:g+w}}),v.on("mouseover",function(){u.enterEmphasis(y)}).on("mouseout",function(){u.leaveEmphasis(y)}),o.add(y),o.add(b),o.add(v)}v.attr({draggable:!0,cursor:"default",drift:xe(this._onDragMove,this,"all"),ondragstart:xe(this._showDataInfo,this,!0),ondragend:xe(this._onDragEnd,this),onmouseover:xe(this._showDataInfo,this,!0),onmouseout:xe(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),n=this._getViewExtent();this._handleEnds=[pt(t[0],[0,100],n,!0),pt(t[1],[0,100],n,!0)]},e.prototype._updateInterval=function(t,n){var a=this.dataZoomModel,i=this._handleEnds,o=this._getViewExtent(),s=a.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];Tl(n,i,o,a.get("zoomLock")?"all":t,s.minSpan!=null?pt(s.minSpan,l,o,!0):null,s.maxSpan!=null?pt(s.maxSpan,l,o,!0):null);var u=this._range,c=this._range=na([pt(i[0],o,l,!0),pt(i[1],o,l,!0)]);return!u||u[0]!==c[0]||u[1]!==c[1]},e.prototype._updateView=function(t){var n=this._displayables,a=this._handleEnds,i=na(a.slice()),o=this._size;O([0,1],function(v){var g=n.handles[v],y=this._handleHeight;g.attr({scaleX:y/2,scaleY:y/2,x:a[v]+(v?-1:1),y:o[1]/2-y/2})},this),n.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:o[1]});var s={x:i[0],width:i[1]-i[0]};n.moveHandle&&(n.moveHandle.setShape(s),n.moveZone.setShape(s),n.moveZone.getBoundingRect(),n.moveHandleIcon&&n.moveHandleIcon.attr("x",s.x+s.width/2));for(var l=n.dataShadowSegs,u=[0,i[0],i[1],o[0]],c=0;c<l.length;c++){var f=l[c],d=f.getClipPath();d||(d=new qe,f.setClipPath(d)),d.setShape({x:u[c],y:0,width:u[c+1]-u[c],height:o[1]})}this._updateDataInfo(t)},e.prototype._updateDataInfo=function(t){var n=this.dataZoomModel,a=this._displayables,i=a.handleLabels,o=this._orient,s=["",""];if(n.get("showDetail")){var l=n.findRepresentativeAxisProxy();if(l){var u=l.getAxisModel().axis,c=this._range,f=t?l.calculateDataWindow({start:c[0],end:c[1]}).valueWindow:l.getDataValueWindow();s=[this._formatLabel(f[0],u),this._formatLabel(f[1],u)]}}var d=na(this._handleEnds.slice());v.call(this,0),v.call(this,1);function v(g){var y=dl(a.handles[g].parent,this.group),x=lb(g===0?"right":"left",y),b=this._handleWidth/2+x_e,w=ti([d[g]+(g===0?-b:b),this._size[1]/2],y);i[g].setStyle({x:w[0],y:w[1],verticalAlign:o===Jv?"middle":x,align:o===Jv?x:"center",text:s[g]})}},e.prototype._formatLabel=function(t,n){var a=this.dataZoomModel,i=a.get("labelFormatter"),o=a.get("labelPrecision");(o==null||o==="auto")&&(o=n.getPixelPrecision());var s=t==null||isNaN(t)?"":n.type==="category"||n.type==="time"?n.scale.getLabel({value:Math.round(t)}):t.toFixed(Math.min(o,20));return Me(i)?i(t,s):ye(i)?i.replace("{value}",s):s},e.prototype._showDataInfo=function(t){var n=this.dataZoomModel.get("handleLabel")||{},a=n.show||!1,i=this.dataZoomModel.getModel(["emphasis","handleLabel"]),o=i.get("show")||!1,s=t||this._dragging?o:a,l=this._displayables,u=l.handleLabels;u[0].attr("invisible",!s),u[1].attr("invisible",!s),l.moveHandle&&this.api[s?"enterEmphasis":"leaveEmphasis"](l.moveHandle,1)},e.prototype._onDragMove=function(t,n,a,i){this._dragging=!0,Zo(i.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=ti([n,a],o,!0),l=this._updateInterval(t,s[0]),u=this.dataZoomModel.get("realtime");this._updateView(!u),l&&u&&this._dispatchZoomAction(!0)},e.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1);var t=this.dataZoomModel.get("realtime");!t&&this._dispatchZoomAction(!1)},e.prototype._onClickPanel=function(t){var n=this._size,a=this._displayables.sliderGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(a[0]<0||a[0]>n[0]||a[1]<0||a[1]>n[1])){var i=this._handleEnds,o=(i[0]+i[1])/2,s=this._updateInterval("all",a[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var n=t.offsetX,a=t.offsetY;this._brushStart=new Ie(n,a),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var n=this._displayables.brushRect;if(this._brushing=!1,!!n){n.attr("ignore",!0);var a=n.shape,i=+new Date;if(!(i-this._brushStartTime<200&&Math.abs(a.width)<5)){var o=this._getViewExtent(),s=[0,100],l=this._handleEnds=[a.x,a.x+a.width],u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();Tl(0,l,o,0,u.minSpan!=null?pt(u.minSpan,s,o,!0):null,u.maxSpan!=null?pt(u.maxSpan,s,o,!0):null),this._range=na([pt(l[0],o,s,!0),pt(l[1],o,s,!0)]),this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(Zo(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,n){var a=this._displayables,i=this.dataZoomModel,o=a.brushRect;o||(o=a.brushRect=new Qv({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),a.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,n),c=l.transformCoordToLocal(s.x,s.y),f=this._size;u[0]=Math.max(Math.min(f[0],u[0]),0),o.setShape({x:c[0],y:0,width:u[0]-c[0],height:f[1]})},e.prototype._dispatchZoomAction=function(t){var n=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?__e:null,start:n[0],end:n[1]})},e.prototype._findCoordRect=function(){var t,n=J9(this.dataZoomModel).infoList;if(!t&&n.length){var a=n[0].model.coordinateSystem;t=a.getRect&&a.getRect()}if(!t){var i=this.api.getWidth(),o=this.api.getHeight();t={x:i*.2,y:o*.2,width:i*.6,height:o*.6}}return t},e.type="dataZoom.slider",e})(vL);function w_e(r){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[r]}function T_e(r){return r==="vertical"?"ns-resize":"ew-resize"}function xY(r){r.registerComponentModel(g_e),r.registerComponentView(S_e),pL(r)}function C_e(r){We(yY),We(xY)}var bY={get:function(r,e,t){var n=De((A_e[r]||{})[e]);return t&&ce(n)?n[n.length-1]:n}},A_e={color:{active:["#006edd","#e0ffff"],inactive:[ee.color.transparent]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},y4=Er.mapVisual,M_e=Er.eachVisual,D_e=ce,x4=O,N_e=na,L_e=pt,D1=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}return e.prototype.init=function(t,n,a){this.mergeDefaultAndTheme(t,a)},e.prototype.optionUpdated=function(t,n){var a=this.option;!n&&uY(a,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var n=this.stateList;t=xe(t,this),this.controllerVisuals=aM(this.option.controller,n,t),this.targetVisuals=aM(this.option.target,n,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesId,n=this.option.seriesIndex;n==null&&t==null&&(n="all");var a=Jh(this.ecModel,"series",{index:n,id:t},{useDefault:!1,enableAll:!0,enableNone:!1}).models;return fe(a,function(i){return i.componentIndex})},e.prototype.eachTargetSeries=function(t,n){O(this.getTargetSeriesIndices(),function(a){var i=this.ecModel.getSeriesByIndex(a);i&&t.call(n,i)},this)},e.prototype.isTargetSeries=function(t){var n=!1;return this.eachTargetSeries(function(a){a===t&&(n=!0)}),n},e.prototype.formatValueText=function(t,n,a){var i=this.option,o=i.precision,s=this.dataBound,l=i.formatter,u;a=a||["<",">"],ce(t)&&(t=t.slice(),u=!0);var c=n?t:u?[f(t[0]),f(t[1])]:f(t);if(ye(l))return l.replace("{value}",u?c[0]:c).replace("{value2}",u?c[1]:c);if(Me(l))return u?l(t[0],t[1]):l(t);if(u)return t[0]===s[0]?a[0]+" "+c[1]:t[1]===s[1]?a[1]+" "+c[0]:c[0]+" - "+c[1];return c;function f(d){return d===s[0]?"min":d===s[1]?"max":(+d).toFixed(Math.min(o,20))}},e.prototype.resetExtent=function(){var t=this.option,n=N_e([t.min,t.max]);this._dataExtent=n},e.prototype.getDataDimensionIndex=function(t){var n=this.option.dimension;if(n!=null)return t.getDimensionIndex(n);for(var a=t.dimensions,i=a.length-1;i>=0;i--){var o=a[i],s=t.getDimensionInfo(o);if(!s.isCalculationCoord)return s.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,n=this.option,a={inRange:n.inRange,outOfRange:n.outOfRange},i=n.target||(n.target={}),o=n.controller||(n.controller={});Ye(i,a),Ye(o,a);var s=this.isCategory();l.call(this,i),l.call(this,o),u.call(this,i,"inRange","outOfRange"),c.call(this,o);function l(f){D_e(n.color)&&!f.inRange&&(f.inRange={color:n.color.slice().reverse()}),f.inRange=f.inRange||{color:t.get("gradientColor")}}function u(f,d,v){var g=f[d],y=f[v];g&&!y&&(y=f[v]={},x4(g,function(x,b){if(Er.isValidType(b)){var w=bY.get(b,"inactive",s);w!=null&&(y[b]=w,b==="color"&&!y.hasOwnProperty("opacity")&&!y.hasOwnProperty("colorAlpha")&&(y.opacity=[0,0]))}}))}function c(f){var d=(f.inRange||{}).symbol||(f.outOfRange||{}).symbol,v=(f.inRange||{}).symbolSize||(f.outOfRange||{}).symbolSize,g=this.get("inactiveColor"),y=this.getItemSymbol(),x=y||"roundRect";x4(this.stateList,function(b){var w=this.itemSize,T=f[b];T||(T=f[b]={color:s?g:[g]}),T.symbol==null&&(T.symbol=d&&De(d)||(s?x:[x])),T.symbolSize==null&&(T.symbolSize=v&&De(v)||(s?w[0]:[w[0],w[0]])),T.symbol=y4(T.symbol,function(M){return M==="none"?x:M});var C=T.symbolSize;if(C!=null){var D=-1/0;M_e(C,function(M){M>D&&(D=M)}),T.symbolSize=y4(C,function(M){return L_e(M,[0,D],[0,w[0]],!0)})}},this)}},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:ee.color.transparent,borderColor:ee.color.borderTint,contentColor:ee.color.theme[0],inactiveColor:ee.color.disabled,borderWidth:0,padding:ee.size.m,textGap:10,precision:0,textStyle:{color:ee.color.secondary}},e})(Qe),b4=[20,140],R_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(t,n){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(a){a.mappingMethod="linear",a.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){r.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=b4[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=b4[1])},e.prototype._resetRange=function(){var t=this.getExtent(),n=this.option.range;!n||n.auto?(t.auto=1,this.option.range=t):ce(n)&&(n[0]>n[1]&&n.reverse(),n[0]=Math.max(n[0],t[0]),n[1]=Math.min(n[1],t[1]))},e.prototype.completeVisualOption=function(){r.prototype.completeVisualOption.apply(this,arguments),O(this.stateList,function(t){var n=this.option.controller[t].symbolSize;n&&n[0]!==n[1]&&(n[0]=n[1]/3)},this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),n=na((this.get("range")||[]).slice());return n[0]>t[1]&&(n[0]=t[1]),n[1]>t[1]&&(n[1]=t[1]),n[0]<t[0]&&(n[0]=t[0]),n[1]<t[0]&&(n[1]=t[0]),n},e.prototype.getValueState=function(t){var n=this.option.range,a=this.getExtent(),i=Ce(this.option.unboundedRange,!0);return(i&&n[0]<=a[0]||n[0]<=t)&&(i&&n[1]>=a[1]||t<=n[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var n=[];return this.eachTargetSeries(function(a){var i=[],o=a.getData();o.each(this.getDataDimensionIndex(o),function(s,l){t[0]<=s&&s<=t[1]&&i.push(l)},this),n.push({seriesId:a.id,dataIndex:i})},this),n},e.prototype.getVisualMeta=function(t){var n=_4(this,"outOfRange",this.getExtent()),a=_4(this,"inRange",this.option.range.slice()),i=[];function o(v,g){i.push({value:v,color:t(v,g)})}for(var s=0,l=0,u=a.length,c=n.length;l<c&&(!a.length||n[l]<=a[0]);l++)n[l]<a[s]&&o(n[l],"outOfRange");for(var f=1;s<u;s++,f=0)f&&i.length&&o(a[s],"outOfRange"),o(a[s],"inRange");for(var f=1;l<c;l++)(!a.length||a[a.length-1]<n[l])&&(f&&(i.length&&o(i[i.length-1].value,"outOfRange"),f=0),o(n[l],"outOfRange"));var d=i.length;return{stops:i,outerColors:[d?i[0].color:"transparent",d?i[d-1].color:"transparent"]}},e.type="visualMap.continuous",e.defaultOption=Rl(D1.defaultOption,{align:"auto",calculable:!1,hoverLink:!0,realtime:!0,handleIcon:"path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z",handleSize:"120%",handleStyle:{borderColor:ee.color.neutral00,borderWidth:1},indicatorIcon:"circle",indicatorSize:"50%",indicatorStyle:{borderColor:ee.color.neutral00,borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:ee.color.shadow}}),e})(D1);function _4(r,e,t){if(t[0]===t[1])return t.slice();for(var n=200,a=(t[1]-t[0])/n,i=t[0],o=[],s=0;s<=n&&i<t[1];s++)o.push(i),i+=a;return o.push(t[1]),o}var _Y=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.autoPositionValues={left:1,right:1,top:1,bottom:1},t}return e.prototype.init=function(t,n){this.ecModel=t,this.api=n},e.prototype.render=function(t,n,a,i){if(this.visualMapModel=t,t.get("show")===!1){this.group.removeAll();return}this.doRender(t,n,a,i)},e.prototype.renderBackground=function(t){var n=this.visualMapModel,a=sd(n.get("padding")||0),i=t.getBoundingRect();t.add(new qe({z2:-1,silent:!0,shape:{x:i.x-a[3],y:i.y-a[0],width:i.width+a[3]+a[1],height:i.height+a[0]+a[2]},style:{fill:n.get("backgroundColor"),stroke:n.get("borderColor"),lineWidth:n.get("borderWidth")}}))},e.prototype.getControllerVisual=function(t,n,a){a=a||{};var i=a.forceState,o=this.visualMapModel,s={};if(n==="color"){var l=o.get("contentColor");s.color=l}function u(v){return s[v]}function c(v,g){s[v]=g}var f=o.controllerVisuals[i||o.getValueState(t)],d=Er.prepareVisualTypes(f);return O(d,function(v){var g=f[v];a.convertOpacityToAlpha&&v==="opacity"&&(v="colorAlpha",g=f.__alphaForOpacity),Er.dependsOn(v,n)&&g&&g.applyVisual(t,u,c)}),s[n]},e.prototype.positionGroup=function(t){var n=this.visualMapModel,a=this.api,i=Cr(n,a).refContainer;fb(t,n.getBoxLayoutParams(),i)},e.prototype.doRender=function(t,n,a,i){},e.type="visualMap",e})(Rt),S4=[["left","right","width"],["top","bottom","height"]];function SY(r,e,t){var n=r.option,a=n.align;if(a!=null&&a!=="auto")return a;for(var i={width:e.getWidth(),height:e.getHeight()},o=n.orient==="horizontal"?1:0,s=S4[o],l=[0,null,10],u={},c=0;c<3;c++)u[S4[1-o][c]]=l[c],u[s[c]]=c===2?t[0]:n[s[c]];var f=[["x","width",3],["y","height",0]][o],d=Ht(u,i,n.padding);return s[(d.margin[f[2]]||0)+d[f[0]]+d[f[1]]*.5<i[f[1]]*.5?0:1]}function hx(r,e){return O(r||[],function(t){t.dataIndex!=null&&(t.dataIndexInside=t.dataIndex,t.dataIndex=null),t.highlightKey="visualMap"+(e?e.componentIndex:"")}),r}var Ti=pt,E_e=O,w4=Math.min,ST=Math.max,k_e=12,I_e=6,O_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._shapes={},t._dataInterval=[],t._handleEnds=[],t._hoverLinkDataIndices=[],t}return e.prototype.init=function(t,n){r.prototype.init.call(this,t,n),this._hoverLinkFromSeriesMouseOver=xe(this._hoverLinkFromSeriesMouseOver,this),this._hideIndicator=xe(this._hideIndicator,this)},e.prototype.doRender=function(t,n,a,i){(!i||i.type!=="selectDataRange"||i.from!==this.uid)&&this._buildView()},e.prototype._buildView=function(){this.group.removeAll();var t=this.visualMapModel,n=this.group;this._orient=t.get("orient"),this._useHandle=t.get("calculable"),this._resetInterval(),this._renderBar(n);var a=t.get("text");this._renderEndsText(n,a,0),this._renderEndsText(n,a,1),this._updateView(!0),this.renderBackground(n),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(n)},e.prototype._renderEndsText=function(t,n,a){if(n){var i=n[1-a];i=i!=null?i+"":"";var o=this.visualMapModel,s=o.get("textGap"),l=o.itemSize,u=this._shapes.mainGroup,c=this._applyTransform([l[0]/2,a===0?-s:l[1]+s],u),f=this._applyTransform(a===0?"bottom":"top",u),d=this._orient,v=this.visualMapModel.textStyleModel;this.group.add(new ot({style:Nt(v,{x:c[0],y:c[1],verticalAlign:v.get("verticalAlign")||(d==="horizontal"?"middle":f),align:v.get("align")||(d==="horizontal"?f:"center"),text:i})}))}},e.prototype._renderBar=function(t){var n=this.visualMapModel,a=this._shapes,i=n.itemSize,o=this._orient,s=this._useHandle,l=SY(n,this.api,i),u=a.mainGroup=this._createBarGroup(l),c=new Ne;u.add(c),c.add(a.outOfRange=T4()),c.add(a.inRange=T4(null,s?A4(this._orient):null,xe(this._dragHandle,this,"all",!1),xe(this._dragHandle,this,"all",!0))),c.setClipPath(new qe({shape:{x:0,y:0,width:i[0],height:i[1],r:3}}));var f=n.textStyleModel.getTextRect("国"),d=ST(f.width,f.height);s&&(a.handleThumbs=[],a.handleLabels=[],a.handleLabelPoints=[],this._createHandle(n,u,0,i,d,o),this._createHandle(n,u,1,i,d,o)),this._createIndicator(n,u,i,d,o),t.add(u)},e.prototype._createHandle=function(t,n,a,i,o,s){var l=xe(this._dragHandle,this,a,!1),u=xe(this._dragHandle,this,a,!0),c=oi(t.get("handleSize"),i[0]),f=ur(t.get("handleIcon"),-c/2,-c/2,c,c,null,!0),d=A4(this._orient);f.attr({cursor:d,draggable:!0,drift:l,ondragend:u,onmousemove:function(b){Zo(b.event)}}),f.x=i[0]/2,f.useStyle(t.getModel("handleStyle").getItemStyle()),f.setStyle({strokeNoScale:!0,strokeFirst:!0}),f.style.lineWidth*=2,f.ensureState("emphasis").style=t.getModel(["emphasis","handleStyle"]).getItemStyle(),Bu(f,!0),n.add(f);var v=this.visualMapModel.textStyleModel,g=new ot({cursor:d,draggable:!0,drift:l,onmousemove:function(b){Zo(b.event)},ondragend:u,style:Nt(v,{x:0,y:0,text:""})});g.ensureState("blur").style={opacity:.1},g.stateTransition={duration:200},this.group.add(g);var y=[c,0],x=this._shapes;x.handleThumbs[a]=f,x.handleLabelPoints[a]=y,x.handleLabels[a]=g},e.prototype._createIndicator=function(t,n,a,i,o){var s=oi(t.get("indicatorSize"),a[0]),l=ur(t.get("indicatorIcon"),-s/2,-s/2,s,s,null,!0);l.attr({cursor:"move",invisible:!0,silent:!0,x:a[0]/2});var u=t.getModel("indicatorStyle").getItemStyle();if(l instanceof Ir){var c=l.style;l.useStyle(ie({image:c.image,x:c.x,y:c.y,width:c.width,height:c.height},u))}else l.useStyle(u);n.add(l);var f=this.visualMapModel.textStyleModel,d=new ot({silent:!0,invisible:!0,style:Nt(f,{x:0,y:0,text:""})});this.group.add(d);var v=[(o==="horizontal"?i/2:I_e)+a[0]/2,0],g=this._shapes;g.indicator=l,g.indicatorLabel=d,g.indicatorLabelPoint=v,this._firstShowIndicator=!0},e.prototype._dragHandle=function(t,n,a,i){if(this._useHandle){if(this._dragging=!n,!n){var o=this._applyTransform([a,i],this._shapes.mainGroup,!0);this._updateInterval(t,o[1]),this._hideIndicator(),this._updateView()}n===!this.visualMapModel.get("realtime")&&this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),n?!this._hovering&&this._clearHoverLinkToSeries():C4(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[t],!1)}},e.prototype._resetInterval=function(){var t=this.visualMapModel,n=this._dataInterval=t.getSelected(),a=t.getExtent(),i=[0,t.itemSize[1]];this._handleEnds=[Ti(n[0],a,i,!0),Ti(n[1],a,i,!0)]},e.prototype._updateInterval=function(t,n){n=n||0;var a=this.visualMapModel,i=this._handleEnds,o=[0,a.itemSize[1]];Tl(n,i,o,t,0);var s=a.getExtent();this._dataInterval=[Ti(i[0],o,s,!0),Ti(i[1],o,s,!0)]},e.prototype._updateView=function(t){var n=this.visualMapModel,a=n.getExtent(),i=this._shapes,o=[0,n.itemSize[1]],s=t?o:this._handleEnds,l=this._createBarVisual(this._dataInterval,a,s,"inRange"),u=this._createBarVisual(a,a,o,"outOfRange");i.inRange.setStyle({fill:l.barColor}).setShape("points",l.barPoints),i.outOfRange.setStyle({fill:u.barColor}).setShape("points",u.barPoints),this._updateHandle(s,l)},e.prototype._createBarVisual=function(t,n,a,i){var o={forceState:i,convertOpacityToAlpha:!0},s=this._makeColorGradient(t,o),l=[this.getControllerVisual(t[0],"symbolSize",o),this.getControllerVisual(t[1],"symbolSize",o)],u=this._createBarPoints(a,l);return{barColor:new bc(0,0,0,1,s),barPoints:u,handlesColor:[s[0].color,s[s.length-1].color]}},e.prototype._makeColorGradient=function(t,n){var a=100,i=[],o=(t[1]-t[0])/a;i.push({color:this.getControllerVisual(t[0],"color",n),offset:0});for(var s=1;s<a;s++){var l=t[0]+o*s;if(l>t[1])break;i.push({color:this.getControllerVisual(l,"color",n),offset:s/a})}return i.push({color:this.getControllerVisual(t[1],"color",n),offset:1}),i},e.prototype._createBarPoints=function(t,n){var a=this.visualMapModel.itemSize;return[[a[0]-n[0],t[0]],[a[0],t[0]],[a[0],t[1]],[a[0]-n[1],t[1]]]},e.prototype._createBarGroup=function(t){var n=this._orient,a=this.visualMapModel.get("inverse");return new Ne(n==="horizontal"&&!a?{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2}:n==="horizontal"&&a?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:n==="vertical"&&!a?{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="left"?1:-1})},e.prototype._updateHandle=function(t,n){if(this._useHandle){var a=this._shapes,i=this.visualMapModel,o=a.handleThumbs,s=a.handleLabels,l=i.itemSize,u=i.getExtent(),c=this._applyTransform("left",a.mainGroup);E_e([0,1],function(f){var d=o[f];d.setStyle("fill",n.handlesColor[f]),d.y=t[f];var v=Ti(t[f],[0,l[1]],u,!0),g=this.getControllerVisual(v,"symbolSize");d.scaleX=d.scaleY=g/l[0],d.x=l[0]-g/2;var y=ti(a.handleLabelPoints[f],dl(d,this.group));if(this._orient==="horizontal"){var x=c==="left"||c==="top"?(l[0]-g)/2:(l[0]-g)/-2;y[1]+=x}s[f].setStyle({x:y[0],y:y[1],text:i.formatValueText(this._dataInterval[f]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",a.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,n,a,i){var o=this.visualMapModel,s=o.getExtent(),l=o.itemSize,u=[0,l[1]],c=this._shapes,f=c.indicator;if(f){f.attr("invisible",!1);var d={convertOpacityToAlpha:!0},v=this.getControllerVisual(t,"color",d),g=this.getControllerVisual(t,"symbolSize"),y=Ti(t,s,u,!0),x=l[0]-g/2,b={x:f.x,y:f.y};f.y=y,f.x=x;var w=ti(c.indicatorLabelPoint,dl(f,this.group)),T=c.indicatorLabel;T.attr("invisible",!1);var C=this._applyTransform("left",c.mainGroup),D=this._orient,M=D==="horizontal";T.setStyle({text:(a||"")+o.formatValueText(n),verticalAlign:M?C:"middle",align:M?"center":C});var N={x,y,style:{fill:v}},R={style:{x:w[0],y:w[1]}};if(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var E={duration:100,easing:"cubicInOut",additive:!0};f.x=b.x,f.y=b.y,f.animateTo(N,E),T.animateTo(R,E)}else f.attr(N),T.attr(R);this._firstShowIndicator=!1;var k=this._shapes.handleLabels;if(k)for(var I=0;I<k.length;I++)this.api.enterBlur(k[I])}},e.prototype._enableHoverLinkToSeries=function(){var t=this;this._shapes.mainGroup.on("mousemove",function(n){if(t._hovering=!0,!t._dragging){var a=t.visualMapModel.itemSize,i=t._applyTransform([n.offsetX,n.offsetY],t._shapes.mainGroup,!0,!0);i[1]=w4(ST(0,i[1]),a[1]),t._doHoverLinkToSeries(i[1],0<=i[0]&&i[0]<=a[0])}}).on("mouseout",function(){t._hovering=!1,!t._dragging&&t._clearHoverLinkToSeries()})},e.prototype._enableHoverLinkFromSeries=function(){var t=this.api.getZr();this.visualMapModel.option.hoverLink?(t.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),t.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},e.prototype._doHoverLinkToSeries=function(t,n){var a=this.visualMapModel,i=a.itemSize;if(a.option.hoverLink){var o=[0,i[1]],s=a.getExtent();t=w4(ST(o[0],t),o[1]);var l=P_e(a,s,o),u=[t-l,t+l],c=Ti(t,o,s,!0),f=[Ti(u[0],o,s,!0),Ti(u[1],o,s,!0)];u[0]<o[0]&&(f[0]=-1/0),u[1]>o[1]&&(f[1]=1/0),n&&(f[0]===-1/0?this._showIndicator(c,f[1],"< ",l):f[1]===1/0?this._showIndicator(c,f[0],"> ",l):this._showIndicator(c,c,"≈ ",l));var d=this._hoverLinkDataIndices,v=[];(n||C4(a))&&(v=this._hoverLinkDataIndices=a.findTargetDataIndices(f));var g=pne(d,v);this._dispatchHighDown("downplay",hx(g[0],a)),this._dispatchHighDown("highlight",hx(g[1],a))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var n;if(Gu(t.target,function(l){var u=je(l);if(u.dataIndex!=null)return n=u,!0},!0),!!n){var a=this.ecModel.getSeriesByIndex(n.seriesIndex),i=this.visualMapModel;if(i.isTargetSeries(a)){var o=a.getData(n.dataType),s=o.getStore().get(i.getDataDimensionIndex(o),n.dataIndex);isNaN(s)||this._showIndicator(s,s)}}},e.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var n=this._shapes.handleLabels;if(n)for(var a=0;a<n.length;a++)this.api.leaveBlur(n[a])},e.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",hx(t,this.visualMapModel)),t.length=0},e.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},e.prototype._applyTransform=function(t,n,a,i){var o=dl(n,i?null:this.group);return ce(t)?ti(t,o,a):lb(t,o,a)},e.prototype._dispatchHighDown=function(t,n){n&&n.length&&this.api.dispatchAction({type:t,batch:n})},e.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},e.type="visualMap.continuous",e})(_Y);function T4(r,e,t,n){return new an({shape:{points:r},draggable:!!t,cursor:e,drift:t,onmousemove:function(a){Zo(a.event)},ondragend:n})}function P_e(r,e,t){var n=k_e/2,a=r.get("hoverLinkDataSize");return a&&(n=Ti(a,e,t,!0)/2),n}function C4(r){var e=r.get("hoverLinkOnHandle");return!!(e??r.get("realtime"))}function A4(r){return r==="vertical"?"ns-resize":"ew-resize"}var j_e={type:"selectDataRange",event:"dataRangeSelected",update:"update"},z_e=function(r,e){e.eachComponent({mainType:"visualMap",query:r},function(t){t.setSelected(r.selected)})},B_e=[{createOnAllSeries:!0,reset:function(r,e){var t=[];return e.eachComponent("visualMap",function(n){var a=r.pipelineContext;!n.isTargetSeries(r)||a&&a.large||t.push(obe(n.stateList,n.targetVisuals,xe(n.getValueState,n),n.getDataDimensionIndex(r.getData())))}),t}},{createOnAllSeries:!0,reset:function(r,e){var t=r.getData(),n=[];e.eachComponent("visualMap",function(a){if(a.isTargetSeries(r)){var i=a.getVisualMeta(xe(V_e,null,r,a))||{stops:[],outerColors:[]},o=a.getDataDimensionIndex(t);o>=0&&(i.dimension=o,n.push(i))}}),r.getData().setVisual("visualMeta",n)}}];function V_e(r,e,t,n){for(var a=e.targetVisuals[n],i=Er.prepareVisualTypes(a),o={color:Kg(r.getData(),"color")},s=0,l=i.length;s<l;s++){var u=i[s],c=a[u==="opacity"?"__alphaForOpacity":u];c&&c.applyVisual(t,f,d)}return o.color;function f(v){return o[v]}function d(v,g){o[v]=g}}var M4=O;function G_e(r){var e=r&&r.visualMap;ce(e)||(e=e?[e]:[]),M4(e,function(t){if(t){Bf(t,"splitList")&&!Bf(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList);var n=t.pieces;n&&ce(n)&&M4(n,function(a){Ee(a)&&(Bf(a,"start")&&!Bf(a,"min")&&(a.min=a.start),Bf(a,"end")&&!Bf(a,"max")&&(a.max=a.end))})}})}function Bf(r,e){return r&&r.hasOwnProperty&&r.hasOwnProperty(e)}var D4=!1;function wY(r){D4||(D4=!0,r.registerSubTypeDefaulter("visualMap",function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),r.registerAction(j_e,z_e),O(B_e,function(e){r.registerVisual(r.PRIORITY.VISUAL.COMPONENT,e)}),r.registerPreprocessor(G_e))}function TY(r){r.registerComponentModel(R_e),r.registerComponentView(O_e),wY(r)}var H_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return e.prototype.optionUpdated=function(t,n){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var a=this._mode=this._determineMode();this._pieceList=[],F_e[this._mode].call(this,this._pieceList),this._resetSelected(t,n);var i=this.option.categories;this.resetVisual(function(o,s){a==="categories"?(o.mappingMethod="category",o.categories=De(i)):(o.dataExtent=this.getExtent(),o.mappingMethod="piecewise",o.pieceList=fe(this._pieceList,function(l){return l=De(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,n={},a=Er.listVisualTypes(),i=this.isCategory();O(t.pieces,function(s){O(a,function(l){s.hasOwnProperty(l)&&(n[l]=1)})}),O(n,function(s,l){var u=!1;O(this.stateList,function(c){u=u||o(t,c,l)||o(t.target,c,l)},this),!u&&O(this.stateList,function(c){(t[c]||(t[c]={}))[l]=bY.get(l,c==="inRange"?"active":"inactive",i)})},this);function o(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}r.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,n){var a=this.option,i=this._pieceList,o=(n?a:t).selected||{};if(a.selected=o,O(i,function(l,u){var c=this.getSelectedMapKey(l);o.hasOwnProperty(c)||(o[c]=!0)},this),a.selectedMode==="single"){var s=!1;O(i,function(l,u){var c=this.getSelectedMapKey(l);o[c]&&(s?o[c]=!1:s=!0)},this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return this._mode==="categories"?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=De(t)},e.prototype.getValueState=function(t){var n=Er.findPieceIndex(t,this._pieceList);return n!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[n])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var n=[],a=this._pieceList;return this.eachTargetSeries(function(i){var o=[],s=i.getData();s.each(this.getDataDimensionIndex(s),function(l,u){var c=Er.findPieceIndex(l,a);c===t&&o.push(u)},this),n.push({seriesId:i.id,dataIndex:o})},this),n},e.prototype.getRepresentValue=function(t){var n;if(this.isCategory())n=t.value;else if(t.value!=null)n=t.value;else{var a=t.interval||[];n=a[0]===-1/0&&a[1]===1/0?0:(a[0]+a[1])/2}return n},e.prototype.getVisualMeta=function(t){if(this.isCategory())return;var n=[],a=["",""],i=this;function o(c,f){var d=i.getRepresentValue({interval:c});f||(f=i.getValueState(d));var v=t(d,f);c[0]===-1/0?a[0]=v:c[1]===1/0?a[1]=v:n.push({value:c[0],color:v},{value:c[1],color:v})}var s=this._pieceList.slice();if(!s.length)s.push({interval:[-1/0,1/0]});else{var l=s[0].interval[0];l!==-1/0&&s.unshift({interval:[-1/0,l]}),l=s[s.length-1].interval[1],l!==1/0&&s.push({interval:[l,1/0]})}var u=-1/0;return O(s,function(c){var f=c.interval;f&&(f[0]>u&&o([u,f[0]],"outOfRange"),o(f.slice()),u=f[1])},this),{stops:n,outerColors:a}},e.type="visualMap.piecewise",e.defaultOption=Rl(D1.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e})(D1),F_e={splitNumber:function(r){var e=this.option,t=Math.min(e.precision,20),n=this.getExtent(),a=e.splitNumber;a=Math.max(parseInt(a,10),1),e.splitNumber=a;for(var i=(n[1]-n[0])/a;+i.toFixed(t)!==i&&t<5;)t++;e.precision=t,i=+i.toFixed(t),e.minOpen&&r.push({interval:[-1/0,n[0]],close:[0,0]});for(var o=0,s=n[0];o<a;s+=i,o++){var l=o===a-1?n[1]:s+i;r.push({interval:[s,l],close:[1,1]})}e.maxOpen&&r.push({interval:[n[1],1/0],close:[0,0]}),NC(r),O(r,function(u,c){u.index=c,u.text=this.formatValueText(u.interval)},this)},categories:function(r){var e=this.option;O(e.categories,function(t){r.push({text:this.formatValueText(t,!0),value:t})},this),N4(e,r)},pieces:function(r){var e=this.option;O(e.pieces,function(t,n){Ee(t)||(t={value:t});var a={text:"",index:n};if(t.label!=null&&(a.text=t.label),t.hasOwnProperty("value")){var i=a.value=t.value;a.interval=[i,i],a.close=[1,1]}else{for(var o=a.interval=[],s=a.close=[0,0],l=[1,0,1],u=[-1/0,1/0],c=[],f=0;f<2;f++){for(var d=[["gte","gt","min"],["lte","lt","max"]][f],v=0;v<3&&o[f]==null;v++)o[f]=t[d[v]],s[f]=l[v],c[f]=v===2;o[f]==null&&(o[f]=u[f])}c[0]&&o[1]===1/0&&(s[0]=0),c[1]&&o[0]===-1/0&&(s[1]=0),o[0]===o[1]&&s[0]&&s[1]&&(a.value=o[0])}a.visual=Er.retrieveVisuals(t),r.push(a)},this),N4(e,r),NC(r),O(r,function(t){var n=t.close,a=[["<","≤"][n[1]],[">","≥"][n[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,a)},this)}};function N4(r,e){var t=r.inverse;(r.orient==="vertical"?!t:t)&&e.reverse()}var U_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.doRender=function(){var t=this.group;t.removeAll();var n=this.visualMapModel,a=n.get("textGap"),i=n.textStyleModel,o=this._getItemAlign(),s=n.itemSize,l=this._getViewData(),u=l.endsText,c=Fr(n.get("showLabel",!0),!u),f=!n.get("selectedMode");u&&this._renderEndsText(t,u[0],s,c,o),O(l.viewPieceList,function(d){var v=d.piece,g=new Ne;g.onclick=xe(this._onItemClick,this,v),this._enableHoverLink(g,d.indexInModelPieceList);var y=n.getRepresentValue(v);if(this._createItemSymbol(g,y,[0,0,s[0],s[1]],f),c){var x=this.visualMapModel.getValueState(y),b=i.get("align")||o;g.add(new ot({style:Nt(i,{x:b==="right"?-a:s[0]+a,y:s[1]/2,text:v.text,verticalAlign:i.get("verticalAlign")||"middle",align:b,opacity:Ce(i.get("opacity"),x==="outOfRange"?.5:1)}),silent:f}))}t.add(g)},this),u&&this._renderEndsText(t,u[1],s,c,o),rc(n.get("orient"),t,n.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,n){var a=this;t.on("mouseover",function(){return i("highlight")}).on("mouseout",function(){return i("downplay")});var i=function(o){var s=a.visualMapModel;s.option.hoverLink&&a.api.dispatchAction({type:o,batch:hx(s.findTargetDataIndices(n),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,n=t.option;if(n.orient==="vertical")return SY(t,this.api,t.itemSize);var a=n.align;return(!a||a==="auto")&&(a="left"),a},e.prototype._renderEndsText=function(t,n,a,i,o){if(n){var s=new Ne,l=this.visualMapModel.textStyleModel;s.add(new ot({style:Nt(l,{x:i?o==="right"?a[0]:0:a[0]/2,y:a[1]/2,verticalAlign:"middle",align:i?o:"center",text:n})})),t.add(s)}},e.prototype._getViewData=function(){var t=this.visualMapModel,n=fe(t.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),a=t.get("text"),i=t.get("orient"),o=t.get("inverse");return(i==="horizontal"?o:!o)?n.reverse():a&&(a=a.slice().reverse()),{viewPieceList:n,endsText:a}},e.prototype._createItemSymbol=function(t,n,a,i){var o=ur(this.getControllerVisual(n,"symbol"),a[0],a[1],a[2],a[3],this.getControllerVisual(n,"color"));o.silent=i,t.add(o)},e.prototype._onItemClick=function(t){var n=this.visualMapModel,a=n.option,i=a.selectedMode;if(i){var o=De(a.selected),s=n.getSelectedMapKey(t);i==="single"||i===!0?(o[s]=!0,O(o,function(l,u){o[u]=u===s})):o[s]=!o[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:o})}},e.type="visualMap.piecewise",e})(_Y);function CY(r){r.registerComponentModel(H_e),r.registerComponentView(U_e),wY(r)}function Y_e(r){We(TY),We(CY)}var W_e=(function(){function r(e){this._thumbnailModel=e}return r.prototype.reset=function(e){this._renderVersion=e.getMainProcessVersion()},r.prototype.renderContent=function(e){var t=e.api.getViewOfComponentModel(this._thumbnailModel);t&&(e.group.silent=!0,t.renderContent({group:e.group,targetTrans:e.targetTrans,z2Range:ZH(e.group),roamType:e.roamType,viewportRect:e.viewportRect,renderVersion:this._renderVersion}))},r.prototype.updateWindow=function(e,t){var n=t.getViewOfComponentModel(this._thumbnailModel);n&&n.updateWindow({targetTrans:e,renderVersion:this._renderVersion})},r})(),X_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.optionUpdated=function(t,n){this._updateBridge()},e.prototype._updateBridge=function(){var t=this._birdge=this._birdge||new W_e(this);if(this._target=null,this.ecModel.eachSeries(function(a){ez(a,null)}),this.shouldShow()){var n=this.getTarget();ez(n.baseMapProvider,t)}},e.prototype.shouldShow=function(){return this.getShallow("show",!0)},e.prototype.getBridge=function(){return this._birdge},e.prototype.getTarget=function(){if(this._target)return this._target;var t=this.getReferringComponents("series",{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];return t?t.subType!=="graph"&&(t=null):t=this.ecModel.queryComponents({mainType:"series",subType:"graph"})[0],this._target={baseMapProvider:t},this._target},e.type="thumbnail",e.layoutMode="box",e.dependencies=["series","geo"],e.defaultOption={show:!0,right:1,bottom:1,height:"25%",width:"25%",itemStyle:{borderColor:ee.color.border,borderWidth:2},windowStyle:{borderWidth:1,color:ee.color.neutral30,borderColor:ee.color.neutral40,opacity:.3},z:10},e})(Qe),q_e=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,n,a){if(this._api=a,this._model=t,this._coordSys||(this._coordSys=new Mc),!this._isEnabled()){this._clear();return}this._renderVersion=a.getMainProcessVersion();var i=this.group;i.removeAll();var o=t.getModel("itemStyle"),s=o.getItemStyle();s.fill==null&&(s.fill=n.get("backgroundColor")||ee.color.neutral00);var l=Cr(t,a).refContainer,u=Ht(p8(t,!0),l),c=s.lineWidth||0,f=this._contentRect=hc(u.clone(),c/2,!0,!0),d=new Ne;i.add(d),d.setClipPath(new qe({shape:f.plain()}));var v=this._targetGroup=new Ne;d.add(v);var g=u.plain();g.r=o.getShallow("borderRadius",!0),i.add(this._bgRect=new qe({style:s,shape:g,silent:!1,cursor:"grab"}));var y=t.getModel("windowStyle"),x=y.getShallow("borderRadius",!0);d.add(this._windowRect=new qe({shape:{x:0,y:0,width:0,height:0,r:x},style:y.getItemStyle(),silent:!1,cursor:"grab"})),this._dealRenderContent(),this._dealUpdateWindow(),R4(t,this)},e.prototype.renderContent=function(t){this._bridgeRendered=t,this._isEnabled()&&(this._dealRenderContent(),this._dealUpdateWindow(),R4(this._model,this))},e.prototype._dealRenderContent=function(){var t=this._bridgeRendered;if(!(!t||t.renderVersion!==this._renderVersion)){var n=this._targetGroup,a=this._coordSys,i=this._contentRect;if(n.removeAll(),!!t){var o=t.group,s=o.getBoundingRect();n.add(o),this._bgRect.z2=t.z2Range.min-10,a.setBoundingRect(s.x,s.y,s.width,s.height);var l=Ht({left:"center",top:"center",aspect:s.width/s.height},i);a.setViewRect(l.x,l.y,l.width,l.height),o.attr(a.getTransformInfo().raw),this._windowRect.z2=t.z2Range.max+10,this._resetRoamController(t.roamType)}}},e.prototype.updateWindow=function(t){var n=this._bridgeRendered;n&&n.renderVersion===t.renderVersion&&(n.targetTrans=t.targetTrans),this._isEnabled()&&this._dealUpdateWindow()},e.prototype._dealUpdateWindow=function(){var t=this._bridgeRendered;if(!(!t||t.renderVersion!==this._renderVersion)){var n=Oa([],t.targetTrans),a=Ja([],this._coordSys.transform,n);this._transThisToTarget=Oa([],a);var i=t.viewportRect;i?i=i.clone():i=new Oe(0,0,this._api.getWidth(),this._api.getHeight()),i.applyTransform(a);var o=this._windowRect,s=o.shape.r;o.setShape(Re({r:s},i))}},e.prototype._resetRoamController=function(t){var n=this,a=this._api,i=this._roamController;if(i||(i=this._roamController=new Ac(a.getZr())),!t||!this._isEnabled()){i.disable();return}i.enable(t,{api:a,zInfo:{component:this._model},triggerInfo:{roamTrigger:null,isInSelf:function(o,s,l){return n._contentRect.contain(s,l)}}}),i.off("pan").off("zoom").on("pan",xe(this._onPan,this)).on("zoom",xe(this._onZoom,this))},e.prototype._onPan=function(t){var n=this._transThisToTarget;if(!(!this._isEnabled()||!n)){var a=Qt([],[t.oldX,t.oldY],n),i=Qt([],[t.oldX-t.dx,t.oldY-t.dy],n);this._api.dispatchAction(L4(this._model.getTarget().baseMapProvider,{dx:i[0]-a[0],dy:i[1]-a[1]}))}},e.prototype._onZoom=function(t){var n=this._transThisToTarget;if(!(!this._isEnabled()||!n)){var a=Qt([],[t.originX,t.originY],n);this._api.dispatchAction(L4(this._model.getTarget().baseMapProvider,{zoom:1/t.scale,originX:a[0],originY:a[1]}))}},e.prototype._isEnabled=function(){var t=this._model;if(!t||!t.shouldShow())return!1;var n=t.getTarget().baseMapProvider;return!!n},e.prototype._clear=function(){this.group.removeAll(),this._bridgeRendered=null,this._roamController&&this._roamController.disable()},e.prototype.remove=function(){this._clear()},e.prototype.dispose=function(){this._clear()},e.type="thumbnail",e})(Rt);function L4(r,e){var t=r.mainType==="series"?r.subType+"Roam":r.mainType+"Roam",n={type:t};return n[r.mainType+"Id"]=r.id,ie(n,e),n}function R4(r,e){var t=dc(r);ub(e.group,t.z,t.zlevel)}function Z_e(r){r.registerComponentModel(X_e),r.registerComponentView(q_e)}var $_e={label:{enabled:!0},decal:{show:!1}},E4=Je(),K_e={};function Q_e(r,e){var t=r.getModel("aria");if(!t.get("enabled"))return;var n=De($_e);Ye(n.label,r.getLocaleModel().get("aria"),!1),Ye(t.option,n,!1),a(),i();function a(){var u=t.getModel("decal"),c=u.get("show");if(c){var f=Te();r.eachSeries(function(d){if(!d.isColorBySeries()){var v=f.get(d.type);v||(v={},f.set(d.type,v)),E4(d).scope=v}}),r.eachRawSeries(function(d){if(r.isSeriesFiltered(d))return;if(Me(d.enableAriaDecal)){d.enableAriaDecal();return}var v=d.getData();if(d.isColorBySeries()){var w=$C(d.ecModel,d.name,K_e,r.getSeriesCount()),T=v.getVisual("decal");v.setVisual("decal",C(T,w))}else{var g=d.getRawData(),y={},x=E4(d).scope;v.each(function(D){var M=v.getRawIndex(D);y[M]=D});var b=g.count();g.each(function(D){var M=y[D],N=g.getName(D)||D+"",R=$C(d.ecModel,N,x,b),E=v.getItemVisual(M,"decal");v.setItemVisual(M,"decal",C(E,R))})}function C(D,M){var N=D?ie(ie({},M),D):M;return N.dirty=!0,N}})}}function i(){var u=e.getZr().dom;if(u){var c=r.getLocaleModel().get("aria"),f=t.getModel("label");if(f.option=Re(f.option,c),!!f.get("enabled")){if(u.setAttribute("role","img"),f.get("description")){u.setAttribute("aria-label",f.get("description"));return}var d=r.getSeriesCount(),v=f.get(["data","maxCount"])||10,g=f.get(["series","maxCount"])||10,y=Math.min(d,g),x;if(!(d<1)){var b=s();if(b){var w=f.get(["general","withTitle"]);x=o(w,{title:b})}else x=f.get(["general","withoutTitle"]);var T=[],C=d>1?f.get(["series","multiple","prefix"]):f.get(["series","single","prefix"]);x+=o(C,{seriesCount:d}),r.eachSeries(function(R,E){if(E<y){var k=void 0,I=R.get("name"),B=I?"withName":"withoutName";k=d>1?f.get(["series","multiple",B]):f.get(["series","single",B]),k=o(k,{seriesId:R.seriesIndex,seriesName:R.get("name"),seriesType:l(R.subType)});var P=R.getData();if(P.count()>v){var H=f.get(["data","partialData"]);k+=o(H,{displayCnt:v})}else k+=f.get(["data","allData"]);for(var V=f.get(["data","separator","middle"]),j=f.get(["data","separator","end"]),U=f.get(["data","excludeDimensionId"]),F=[],X=0;X<P.count();X++)if(X<v){var G=P.getName(X),W=U?dt(P.getValues(X),function(te,ue){return Fe(U,ue)===-1}):P.getValues(X),$=f.get(["data",G?"withName":"withoutName"]);F.push(o($,{name:G,value:W.join(V)}))}k+=F.join(V)+j,T.push(k)}});var D=f.getModel(["series","multiple","separator"]),M=D.get("middle"),N=D.get("end");x+=T.join(M)+N,u.setAttribute("aria-label",x)}}}}function o(u,c){if(!ye(u))return u;var f=u;return O(c,function(d,v){f=f.replace(new RegExp("\\{\\s*"+v+"\\s*\\}","g"),d)}),f}function s(){var u=r.get("title");return u&&u.length&&(u=u[0]),u&&u.text}function l(u){var c=r.getLocaleModel().get(["series","typeNames"]);return c[u]||c.chart}}function J_e(r){if(!(!r||!r.aria)){var e=r.aria;e.show!=null&&(e.enabled=e.show),e.label=e.label||{},O(["description","general","series","data"],function(t){e[t]!=null&&(e.label[t]=e[t])})}}function eSe(r){r.registerPreprocessor(J_e),r.registerVisual(r.PRIORITY.VISUAL.ARIA,Q_e)}var k4={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},tSe=(function(){function r(e){var t=this._condVal=ye(e)?new RegExp(e):x6(e)?e:null;if(t==null){var n="";gt(n)}}return r.prototype.evaluate=function(e){var t=typeof e;return ye(t)?this._condVal.test(e):st(t)?this._condVal.test(e+""):!1},r})(),rSe=(function(){function r(){}return r.prototype.evaluate=function(){return this.value},r})(),nSe=(function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(!e[t].evaluate())return!1;return!0},r})(),aSe=(function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(e[t].evaluate())return!0;return!1},r})(),iSe=(function(){function r(){}return r.prototype.evaluate=function(){return!this.child.evaluate()},r})(),oSe=(function(){function r(){}return r.prototype.evaluate=function(){for(var e=!!this.valueParser,t=this.getValue,n=t(this.valueGetterParam),a=e?this.valueParser(n):null,i=0;i<this.subCondList.length;i++)if(!this.subCondList[i].evaluate(e?a:n))return!1;return!0},r})();function wL(r,e){if(r===!0||r===!1){var t=new rSe;return t.value=r,t}var n="";return AY(r)||gt(n),r.and?I4("and",r,e):r.or?I4("or",r,e):r.not?sSe(r,e):lSe(r,e)}function I4(r,e,t){var n=e[r],a="";ce(n)||gt(a),n.length||gt(a);var i=r==="and"?new nSe:new aSe;return i.children=fe(n,function(o){return wL(o,t)}),i.children.length||gt(a),i}function sSe(r,e){var t=r.not,n="";AY(t)||gt(n);var a=new iSe;return a.child=wL(t,e),a.child||gt(n),a}function lSe(r,e){for(var t="",n=e.prepareGetValue(r),a=[],i=it(r),o=r.parser,s=o?j8(o):null,l=0;l<i.length;l++){var u=i[l];if(!(u==="parser"||e.valueGetterAttrMap.get(u))){var c=_e(k4,u)?k4[u]:u,f=r[u],d=s?s(f):f,v=Doe(c,d)||c==="reg"&&new tSe(d);v||gt(t),a.push(v)}}a.length||gt(t);var g=new oSe;return g.valueGetterParam=n,g.valueParser=s,g.getValue=e.getValue,g.subCondList=a,g}function AY(r){return Ee(r)&&!tn(r)}var uSe=(function(){function r(e,t){this._cond=wL(e,t)}return r.prototype.evaluate=function(){return this._cond.evaluate()},r})();function cSe(r,e){return new uSe(r,e)}var fSe={type:"echarts:filter",transform:function(r){for(var e=r.upstream,t,n=cSe(r.config,{valueGetterAttrMap:Te({dimension:!0}),prepareGetValue:function(s){var l="",u=s.dimension;_e(s,"dimension")||gt(l);var c=e.getDimensionInfo(u);return c||gt(l),{dimIdx:c.index}},getValue:function(s){return e.retrieveValueFromItem(t,s.dimIdx)}}),a=[],i=0,o=e.count();i<o;i++)t=e.getRawDataItem(i),n.evaluate()&&a.push(t);return{data:a}}},hSe={type:"echarts:sort",transform:function(r){var e=r.upstream,t=r.config,n="",a=Lt(t);a.length||gt(n);var i=[];O(a,function(c){var f=c.dimension,d=c.order,v=c.parser,g=c.incomparable;if(f==null&&gt(n),d!=="asc"&&d!=="desc"&&gt(n),g&&g!=="min"&&g!=="max"){var y="";gt(y)}if(d!=="asc"&&d!=="desc"){var x="";gt(x)}var b=e.getDimensionInfo(f);b||gt(n);var w=v?j8(v):null;v&&!w&&gt(n),i.push({dimIdx:b.index,parser:w,comparator:new B8(d,g)})});var o=e.sourceFormat;o!==Yr&&o!==ua&&gt(n);for(var s=[],l=0,u=e.count();l<u;l++)s.push(e.getRawDataItem(l));return s.sort(function(c,f){for(var d=0;d<i.length;d++){var v=i[d],g=e.retrieveValueFromItem(c,v.dimIdx),y=e.retrieveValueFromItem(f,v.dimIdx);v.parser&&(g=v.parser(g),y=v.parser(y));var x=v.comparator.evaluate(g,y);if(x!==0)return x}return 0}),{data:s}}};function dSe(r){r.registerTransform(fSe),r.registerTransform(hSe)}var vSe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.prototype.init=function(t,n,a){r.prototype.init.call(this,t,n,a),this._sourceManager=new F8(this),h5(this)},e.prototype.mergeOption=function(t,n){r.prototype.mergeOption.call(this,t,n),h5(this)},e.prototype.optionUpdated=function(){this._sourceManager.dirty()},e.prototype.getSourceManager=function(){return this._sourceManager},e.type="dataset",e.defaultOption={seriesLayoutBy:ri},e})(Qe),pSe=(function(r){K(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.type="dataset",e})(Rt);function gSe(r){r.registerComponentModel(vSe),r.registerComponentView(pSe)}var Si=qi.CMD;function ah(r,e){return Math.abs(r-e)<1e-5}function fM(r){var e=r.data,t=r.len(),n=[],a,i=0,o=0,s=0,l=0;function u(P,H){a&&a.length>2&&n.push(a),a=[P,H]}function c(P,H,V,j){ah(P,V)&&ah(H,j)||a.push(P,H,V,j,V,j)}function f(P,H,V,j,U,F){var X=Math.abs(H-P),G=Math.tan(X/4)*4/3,W=H<P?-1:1,$=Math.cos(P),te=Math.sin(P),ue=Math.cos(H),ge=Math.sin(H),Se=$*U+V,Xe=te*F+j,be=ue*U+V,we=ge*F+j,ze=U*G*W,oe=F*G*W;a.push(Se-ze*te,Xe+oe*$,be+ze*ge,we-oe*ue,be,we)}for(var d,v,g,y,x=0;x<t;){var b=e[x++],w=x===1;switch(w&&(i=e[x],o=e[x+1],s=i,l=o,(b===Si.L||b===Si.C||b===Si.Q)&&(a=[s,l])),b){case Si.M:i=s=e[x++],o=l=e[x++],u(s,l);break;case Si.L:d=e[x++],v=e[x++],c(i,o,d,v),i=d,o=v;break;case Si.C:a.push(e[x++],e[x++],e[x++],e[x++],i=e[x++],o=e[x++]);break;case Si.Q:d=e[x++],v=e[x++],g=e[x++],y=e[x++],a.push(i+2/3*(d-i),o+2/3*(v-o),g+2/3*(d-g),y+2/3*(v-y),g,y),i=g,o=y;break;case Si.A:var T=e[x++],C=e[x++],D=e[x++],M=e[x++],N=e[x++],R=e[x++]+N;x+=1;var E=!e[x++];d=Math.cos(N)*D+T,v=Math.sin(N)*M+C,w?(s=d,l=v,u(s,l)):c(i,o,d,v),i=Math.cos(R)*D+T,o=Math.sin(R)*M+C;for(var k=(E?-1:1)*Math.PI/2,I=N;E?I>R:I<R;I+=k){var B=E?Math.max(I+k,R):Math.min(I+k,R);f(I,B,T,C,D,M)}break;case Si.R:s=i=e[x++],l=o=e[x++],d=s+e[x++],v=l+e[x++],u(d,l),c(d,l,d,v),c(d,v,s,v),c(s,v,s,l),c(s,l,d,l);break;case Si.Z:a&&c(i,o,s,l),i=s,o=l;break}}return a&&a.length>2&&n.push(a),n}function hM(r,e,t,n,a,i,o,s,l,u){if(ah(r,t)&&ah(e,n)&&ah(a,o)&&ah(i,s)){l.push(o,s);return}var c=2/u,f=c*c,d=o-r,v=s-e,g=Math.sqrt(d*d+v*v);d/=g,v/=g;var y=t-r,x=n-e,b=a-o,w=i-s,T=y*y+x*x,C=b*b+w*w;if(T<f&&C<f){l.push(o,s);return}var D=d*y+v*x,M=-d*b-v*w,N=T-D*D,R=C-M*M;if(N<f&&D>=0&&R<f&&M>=0){l.push(o,s);return}var E=[],k=[];_l(r,t,a,o,.5,E),_l(e,n,i,s,.5,k),hM(E[0],k[0],E[1],k[1],E[2],k[2],E[3],k[3],l,u),hM(E[4],k[4],E[5],k[5],E[6],k[6],E[7],k[7],l,u)}function mSe(r,e){var t=fM(r),n=[];e=e||1;for(var a=0;a<t.length;a++){var i=t[a],o=[],s=i[0],l=i[1];o.push(s,l);for(var u=2;u<i.length;){var c=i[u++],f=i[u++],d=i[u++],v=i[u++],g=i[u++],y=i[u++];hM(s,l,c,f,d,v,g,y,o,e),s=g,l=y}n.push(o)}return n}function MY(r,e,t){var n=r[e],a=r[1-e],i=Math.abs(n/a),o=Math.ceil(Math.sqrt(i*t)),s=Math.floor(t/o);s===0&&(s=1,o=t);for(var l=[],u=0;u<o;u++)l.push(s);var c=o*s,f=t-c;if(f>0)for(var u=0;u<f;u++)l[u%o]+=1;return l}function O4(r,e,t){for(var n=r.r0,a=r.r,i=r.startAngle,o=r.endAngle,s=Math.abs(o-i),l=s*a,u=a-n,c=l>Math.abs(u),f=MY([l,u],c?0:1,e),d=(c?s:u)/f.length,v=0;v<f.length;v++)for(var g=(c?u:s)/f[v],y=0;y<f[v];y++){var x={};c?(x.startAngle=i+d*v,x.endAngle=i+d*(v+1),x.r0=n+g*y,x.r=n+g*(y+1)):(x.startAngle=i+g*y,x.endAngle=i+g*(y+1),x.r0=n+d*v,x.r=n+d*(v+1)),x.clockwise=r.clockwise,x.cx=r.cx,x.cy=r.cy,t.push(x)}}function ySe(r,e,t){for(var n=r.width,a=r.height,i=n>a,o=MY([n,a],i?0:1,e),s=i?"width":"height",l=i?"height":"width",u=i?"x":"y",c=i?"y":"x",f=r[s]/o.length,d=0;d<o.length;d++)for(var v=r[l]/o[d],g=0;g<o[d];g++){var y={};y[u]=d*f,y[c]=g*v,y[s]=f,y[l]=v,y.x+=r.x,y.y+=r.y,t.push(y)}}function P4(r,e,t,n){return r*n-t*e}function xSe(r,e,t,n,a,i,o,s){var l=t-r,u=n-e,c=o-a,f=s-i,d=P4(c,f,l,u);if(Math.abs(d)<1e-6)return null;var v=r-a,g=e-i,y=P4(v,g,c,f)/d;return y<0||y>1?null:new Ie(y*l+r,y*u+e)}function bSe(r,e,t){var n=new Ie;Ie.sub(n,t,e),n.normalize();var a=new Ie;Ie.sub(a,r,e);var i=a.dot(n);return i}function Vf(r,e){var t=r[r.length-1];t&&t[0]===e[0]&&t[1]===e[1]||r.push(e)}function _Se(r,e,t){for(var n=r.length,a=[],i=0;i<n;i++){var o=r[i],s=r[(i+1)%n],l=xSe(o[0],o[1],s[0],s[1],e.x,e.y,t.x,t.y);l&&a.push({projPt:bSe(l,e,t),pt:l,idx:i})}if(a.length<2)return[{points:r},{points:r}];a.sort(function(x,b){return x.projPt-b.projPt});var u=a[0],c=a[a.length-1];if(c.idx<u.idx){var f=u;u=c,c=f}for(var d=[u.pt.x,u.pt.y],v=[c.pt.x,c.pt.y],g=[d],y=[v],i=u.idx+1;i<=c.idx;i++)Vf(g,r[i].slice());Vf(g,v),Vf(g,d);for(var i=c.idx+1;i<=u.idx+n;i++)Vf(y,r[i%n].slice());return Vf(y,d),Vf(y,v),[{points:g},{points:y}]}function j4(r){var e=r.points,t=[],n=[];nb(e,t,n);var a=new Oe(t[0],t[1],n[0]-t[0],n[1]-t[1]),i=a.width,o=a.height,s=a.x,l=a.y,u=new Ie,c=new Ie;return i>o?(u.x=c.x=s+i/2,u.y=l,c.y=l+o):(u.y=c.y=l+o/2,u.x=s,c.x=s+i),_Se(e,u,c)}function N1(r,e,t,n){if(t===1)n.push(e);else{var a=Math.floor(t/2),i=r(e);N1(r,i[0],a,n),N1(r,i[1],t-a,n)}return n}function SSe(r,e){for(var t=[],n=0;n<e;n++)t.push(yD(r));return t}function wSe(r,e){e.setStyle(r.style),e.z=r.z,e.z2=r.z2,e.zlevel=r.zlevel}function TSe(r){for(var e=[],t=0;t<r.length;)e.push([r[t++],r[t++]]);return e}function CSe(r,e){var t=[],n=r.shape,a;switch(r.type){case"rect":ySe(n,e,t),a=qe;break;case"sector":O4(n,e,t),a=nn;break;case"circle":O4({r0:0,r:n.r,startAngle:0,endAngle:Math.PI*2,cx:n.cx,cy:n.cy},e,t),a=nn;break;default:var i=r.getComputedTransform(),o=i?Math.sqrt(Math.max(i[0]*i[0]+i[1]*i[1],i[2]*i[2]+i[3]*i[3])):1,s=fe(mSe(r.getUpdatedPathProxy(),o),function(b){return TSe(b)}),l=s.length;if(l===0)N1(j4,{points:s[0]},e,t);else if(l===e)for(var u=0;u<l;u++)t.push({points:s[u]});else{var c=0,f=fe(s,function(b){var w=[],T=[];nb(b,w,T);var C=(T[1]-w[1])*(T[0]-w[0]);return c+=C,{poly:b,area:C}});f.sort(function(b,w){return w.area-b.area});for(var d=e,u=0;u<l;u++){var v=f[u];if(d<=0)break;var g=u===l-1?d:Math.ceil(v.area/c*e);g<0||(N1(j4,{points:v.poly},g,t),d-=g)}}a=an;break}if(!a)return SSe(r,e);for(var y=[],u=0;u<t.length;u++){var x=new a;x.setShape(t[u]),wSe(r,x),y.push(x)}return y}function ASe(r,e){var t=r.length,n=e.length;if(t===n)return[r,e];for(var a=[],i=[],o=t<n?r:e,s=Math.min(t,n),l=Math.abs(n-t)/6,u=(s-2)/6,c=Math.ceil(l/u)+1,f=[o[0],o[1]],d=l,v=2;v<s;){var g=o[v-2],y=o[v-1],x=o[v++],b=o[v++],w=o[v++],T=o[v++],C=o[v++],D=o[v++];if(d<=0){f.push(x,b,w,T,C,D);continue}for(var M=Math.min(d,c-1)+1,N=1;N<=M;N++){var R=N/M;_l(g,x,w,C,R,a),_l(y,b,T,D,R,i),g=a[3],y=i[3],f.push(a[1],i[1],a[2],i[2],g,y),x=a[5],b=i[5],w=a[6],T=i[6]}d-=M-1}return o===r?[f,e]:[r,f]}function z4(r,e){for(var t=r.length,n=r[t-2],a=r[t-1],i=[],o=0;o<e.length;)i[o++]=n,i[o++]=a;return i}function MSe(r,e){for(var t,n,a,i=[],o=[],s=0;s<Math.max(r.length,e.length);s++){var l=r[s],u=e[s],c=void 0,f=void 0;l?u?(t=ASe(l,u),c=t[0],f=t[1],n=c,a=f):(f=z4(a||l,l),c=l):(c=z4(n||u,u),f=u),i.push(c),o.push(f)}return[i,o]}function B4(r){for(var e=0,t=0,n=0,a=r.length,i=0,o=a-2;i<a;o=i,i+=2){var s=r[o],l=r[o+1],u=r[i],c=r[i+1],f=s*c-u*l;e+=f,t+=(s+u)*f,n+=(l+c)*f}return e===0?[r[0]||0,r[1]||0]:[t/e/3,n/e/3,e]}function DSe(r,e,t,n){for(var a=(r.length-2)/6,i=1/0,o=0,s=r.length,l=s-2,u=0;u<a;u++){for(var c=u*6,f=0,d=0;d<s;d+=2){var v=d===0?c:(c+d-2)%l+2,g=r[v]-t[0],y=r[v+1]-t[1],x=e[d]-n[0],b=e[d+1]-n[1],w=x-g,T=b-y;f+=w*w+T*T}f<i&&(i=f,o=u)}return o}function NSe(r){for(var e=[],t=r.length,n=0;n<t;n+=2)e[n]=r[t-n-2],e[n+1]=r[t-n-1];return e}function LSe(r,e,t,n){for(var a=[],i,o=0;o<r.length;o++){var s=r[o],l=e[o],u=B4(s),c=B4(l);i==null&&(i=u[2]<0!=c[2]<0);var f=[],d=[],v=0,g=1/0,y=[],x=s.length;i&&(s=NSe(s));for(var b=DSe(s,l,u,c)*6,w=x-2,T=0;T<w;T+=2){var C=(b+T)%w+2;f[T+2]=s[C]-u[0],f[T+3]=s[C+1]-u[1]}f[0]=s[b]-u[0],f[1]=s[b+1]-u[1];for(var D=n/t,M=-n/2;M<=n/2;M+=D){for(var N=Math.sin(M),R=Math.cos(M),E=0,T=0;T<s.length;T+=2){var k=f[T],I=f[T+1],B=l[T]-c[0],P=l[T+1]-c[1],H=B*R-P*N,V=B*N+P*R;y[T]=H,y[T+1]=V;var j=H-k,U=V-I;E+=j*j+U*U}if(E<g){g=E,v=M;for(var F=0;F<y.length;F++)d[F]=y[F]}}a.push({from:f,to:d,fromCp:u,toCp:c,rotation:-v})}return a}function L1(r){return r.__isCombineMorphing}var DY="__mOriginal_";function R1(r,e,t){var n=DY+e,a=r[n]||r[e];r[n]||(r[n]=r[e]);var i=t.replace,o=t.after,s=t.before;r[e]=function(){var l=arguments,u;return s&&s.apply(this,l),i?u=i.apply(this,l):u=a.apply(this,l),o&&o.apply(this,l),u}}function jp(r,e){var t=DY+e;r[t]&&(r[e]=r[t],r[t]=null)}function V4(r,e){for(var t=0;t<r.length;t++)for(var n=r[t],a=0;a<n.length;){var i=n[a],o=n[a+1];n[a++]=e[0]*i+e[2]*o+e[4],n[a++]=e[1]*i+e[3]*o+e[5]}}function NY(r,e){var t=r.getUpdatedPathProxy(),n=e.getUpdatedPathProxy(),a=MSe(fM(t),fM(n)),i=a[0],o=a[1],s=r.getComputedTransform(),l=e.getComputedTransform();function u(){this.transform=null}s&&V4(i,s),l&&V4(o,l),R1(e,"updateTransform",{replace:u}),e.transform=null;var c=LSe(i,o,10,Math.PI),f=[];R1(e,"buildPath",{replace:function(d){for(var v=e.__morphT,g=1-v,y=[],x=0;x<c.length;x++){var b=c[x],w=b.from,T=b.to,C=b.rotation*v,D=b.fromCp,M=b.toCp,N=Math.sin(C),R=Math.cos(C);Cp(y,D,M,v);for(var E=0;E<w.length;E+=2){var k=w[E],I=w[E+1],B=T[E],P=T[E+1],H=k*g+B*v,V=I*g+P*v;f[E]=H*R-V*N+y[0],f[E+1]=H*N+V*R+y[1]}var j=f[0],U=f[1];d.moveTo(j,U);for(var E=2;E<w.length;){var B=f[E++],P=f[E++],F=f[E++],X=f[E++],G=f[E++],W=f[E++];j===B&&U===P&&F===G&&X===W?d.lineTo(G,W):d.bezierCurveTo(B,P,F,X,G,W),j=G,U=W}}}})}function TL(r,e,t){if(!r||!e)return e;var n=t.done,a=t.during;NY(r,e),e.__morphT=0;function i(){jp(e,"buildPath"),jp(e,"updateTransform"),e.__morphT=-1,e.createPathProxy(),e.dirtyShape()}return e.animateTo({__morphT:1},Re({during:function(o){e.dirtyShape(),a&&a(o)},done:function(){i(),n&&n()}},t)),e}function RSe(r,e,t,n,a,i){var o=16;r=a===t?0:Math.round(32767*(r-t)/(a-t)),e=i===n?0:Math.round(32767*(e-n)/(i-n));for(var s=0,l,u=(1<<o)/2;u>0;u/=2){var c=0,f=0;(r&u)>0&&(c=1),(e&u)>0&&(f=1),s+=u*u*(3*c^f),f===0&&(c===1&&(r=u-1-r,e=u-1-e),l=r,r=e,e=l)}return s}function E1(r){var e=1/0,t=1/0,n=-1/0,a=-1/0,i=fe(r,function(s){var l=s.getBoundingRect(),u=s.getComputedTransform(),c=l.x+l.width/2+(u?u[4]:0),f=l.y+l.height/2+(u?u[5]:0);return e=Math.min(c,e),t=Math.min(f,t),n=Math.max(c,n),a=Math.max(f,a),[c,f]}),o=fe(i,function(s,l){return{cp:s,z:RSe(s[0],s[1],e,t,n,a),path:r[l]}});return o.sort(function(s,l){return s.z-l.z}).map(function(s){return s.path})}function LY(r){return CSe(r.path,r.count)}function dM(){return{fromIndividuals:[],toIndividuals:[],count:0}}function ESe(r,e,t){var n=[];function a(D){for(var M=0;M<D.length;M++){var N=D[M];L1(N)?a(N.childrenRef()):N instanceof tt&&n.push(N)}}a(r);var i=n.length;if(!i)return dM();var o=t.dividePath||LY,s=o({path:e,count:i});if(s.length!==i)return console.error("Invalid morphing: unmatched splitted path"),dM();n=E1(n),s=E1(s);for(var l=t.done,u=t.during,c=t.individualDelay,f=new jo,d=0;d<i;d++){var v=n[d],g=s[d];g.parent=e,g.copyTransform(f),c||NY(v,g)}e.__isCombineMorphing=!0,e.childrenRef=function(){return s};function y(D){for(var M=0;M<s.length;M++)s[M].addSelfToZr(D)}R1(e,"addSelfToZr",{after:function(D){y(D)}}),R1(e,"removeSelfFromZr",{after:function(D){for(var M=0;M<s.length;M++)s[M].removeSelfFromZr(D)}});function x(){e.__isCombineMorphing=!1,e.__morphT=-1,e.childrenRef=null,jp(e,"addSelfToZr"),jp(e,"removeSelfFromZr")}var b=s.length;if(c)for(var w=b,T=function(){w--,w===0&&(x(),l&&l())},d=0;d<b;d++){var C=c?Re({delay:(t.delay||0)+c(d,b,n[d],s[d]),done:T},t):t;TL(n[d],s[d],C)}else e.__morphT=0,e.animateTo({__morphT:1},Re({during:function(D){for(var M=0;M<b;M++){var N=s[M];N.__morphT=e.__morphT,N.dirtyShape()}u&&u(D)},done:function(){x();for(var D=0;D<r.length;D++)jp(r[D],"updateTransform");l&&l()}},t));return e.__zr&&y(e.__zr),{fromIndividuals:n,toIndividuals:s,count:b}}function kSe(r,e,t){var n=e.length,a=[],i=t.dividePath||LY;function o(v){for(var g=0;g<v.length;g++){var y=v[g];L1(y)?o(y.childrenRef()):y instanceof tt&&a.push(y)}}if(L1(r)){o(r.childrenRef());var s=a.length;if(s<n)for(var l=0,u=s;u<n;u++)a.push(yD(a[l++%s]));a.length=n}else{a=i({path:r,count:n});for(var c=r.getComputedTransform(),u=0;u<a.length;u++)a[u].setLocalTransform(c);if(a.length!==n)return console.error("Invalid morphing: unmatched splitted path"),dM()}a=E1(a),e=E1(e);for(var f=t.individualDelay,u=0;u<n;u++){var d=f?Re({delay:(t.delay||0)+f(u,n,a[u],e[u])},t):t;TL(a[u],e[u],d)}return{fromIndividuals:a,toIndividuals:e,count:e.length}}function G4(r){return ce(r[0])}function H4(r,e){for(var t=[],n=r.length,a=0;a<n;a++)t.push({one:r[a],many:[]});for(var a=0;a<e.length;a++){var i=e[a].length,o=void 0;for(o=0;o<i;o++)t[o%n].many.push(e[a][o])}for(var s=0,a=n-1;a>=0;a--)if(!t[a].many.length){var l=t[s].many;if(l.length<=1)if(s)s=0;else return t;var i=l.length,u=Math.ceil(i/2);t[a].many=l.slice(u,i),t[s].many=l.slice(0,u),s++}return t}var ISe={clone:function(r){for(var e=[],t=1-Math.pow(1-r.path.style.opacity,1/r.count),n=0;n<r.count;n++){var a=yD(r.path);a.setStyle("opacity",t),e.push(a)}return e},split:null};function wT(r,e,t,n,a,i){if(!r.length||!e.length)return;var o=nd("update",n,a);if(!(o&&o.duration>0))return;var s=n.getModel("universalTransition").get("delay"),l=Object.assign({setToFinal:!0},o),u,c;G4(r)&&(u=r,c=e),G4(e)&&(u=e,c=r);function f(b,w,T,C,D){var M=b.many,N=b.one;if(M.length===1&&!D){var R=w?M[0]:N,E=w?N:M[0];if(L1(R))f({many:[R],one:E},!0,T,C,!0);else{var k=s?Re({delay:s(T,C)},l):l;TL(R,E,k),i(R,E,R,E,k)}}else for(var I=Re({dividePath:ISe[t],individualDelay:s&&function(U,F,X,G){return s(U+T,C)}},l),B=w?ESe(M,N,I):kSe(N,M,I),P=B.fromIndividuals,H=B.toIndividuals,V=P.length,j=0;j<V;j++){var k=s?Re({delay:s(j,V)},l):l;i(P[j],H[j],w?M[j]:b.one,w?b.one:M[j],k)}}for(var d=u?u===r:r.length>e.length,v=u?H4(c,u):H4(d?e:r,[d?r:e]),g=0,y=0;y<v.length;y++)g+=v[y].many.length;for(var x=0,y=0;y<v.length;y++)f(v[y],d,x,g),x+=v[y].many.length}function Ru(r){if(!r)return[];if(ce(r)){for(var e=[],t=0;t<r.length;t++)e.push(Ru(r[t]));return e}var n=[];return r.traverse(function(a){a instanceof tt&&!a.disableMorphing&&!a.invisible&&!a.ignore&&n.push(a)}),n}var RY=1e4,OSe=0,F4=1,U4=2,PSe=Je();function jSe(r,e){for(var t=r.dimensions,n=0;n<t.length;n++){var a=r.getDimensionInfo(t[n]);if(a&&a.otherDims[e]===0)return t[n]}}function zSe(r,e,t){var n=r.getDimensionInfo(t),a=n&&n.ordinalMeta;if(n){var i=r.get(n.name,e);return a&&a.categories[i]||i+""}}function Y4(r,e,t,n){var a=n?"itemChildGroupId":"itemGroupId",i=jSe(r,a);if(i){var o=zSe(r,e,i);return o}var s=r.getRawDataItem(e),l=n?"childGroupId":"groupId";if(s&&s[l])return s[l]+"";if(!n)return t||r.getId(e)}function W4(r){var e=[];return O(r,function(t){var n=t.data,a=t.dataGroupId;if(!(n.count()>RY))for(var i=n.getIndices(),o=0;o<i.length;o++)e.push({data:n,groupId:Y4(n,o,a,!1),childGroupId:Y4(n,o,a,!0),divide:t.divide,dataIndex:o})}),e}function TT(r,e,t){r.traverse(function(n){n instanceof tt&&zt(n,{style:{opacity:0}},e,{dataIndex:t,isFrom:!0})})}function CT(r){if(r.parent){var e=r.getComputedTransform();r.setLocalTransform(e),r.parent.remove(r)}}function Gf(r){r.stopAnimation(),r.isGroup&&r.traverse(function(e){e.stopAnimation()})}function BSe(r,e,t){var n=nd("update",t,e);n&&r.traverse(function(a){if(a instanceof Pa){var i=rie(a);i&&a.animateFrom({style:i},n)}})}function VSe(r,e){var t=r.length;if(t!==e.length)return!1;for(var n=0;n<t;n++){var a=r[n],i=e[n];if(a.data.getId(a.dataIndex)!==i.data.getId(i.dataIndex))return!1}return!0}function EY(r,e,t){var n=W4(r),a=W4(e);function i(T,C,D,M,N){(D||T)&&C.animateFrom({style:D&&D!==T?ie(ie({},D.style),T.style):T.style},N)}var o=!1,s=OSe,l=Te(),u=Te();n.forEach(function(T){T.groupId&&l.set(T.groupId,!0),T.childGroupId&&u.set(T.childGroupId,!0)});for(var c=0;c<a.length;c++){var f=a[c].groupId;if(u.get(f)){s=F4;break}var d=a[c].childGroupId;if(d&&l.get(d)){s=U4;break}}function v(T,C){return function(D){var M=D.data,N=D.dataIndex;return C?M.getId(N):T?s===F4?D.childGroupId:D.groupId:s===U4?D.childGroupId:D.groupId}}var g=VSe(n,a),y={};if(!g)for(var c=0;c<a.length;c++){var x=a[c],b=x.data.getItemGraphicEl(x.dataIndex);b&&(y[b.id]=!0)}function w(T,C){var D=n[C],M=a[T],N=M.data.hostModel,R=D.data.getItemGraphicEl(D.dataIndex),E=M.data.getItemGraphicEl(M.dataIndex);if(R===E){E&&BSe(E,M.dataIndex,N);return}R&&y[R.id]||E&&(Gf(E),R?(Gf(R),CT(R),o=!0,wT(Ru(R),Ru(E),M.divide,N,T,i)):TT(E,N,T))}new Qo(n,a,v(!0,g),v(!1,g),null,"multiple").update(w).updateManyToOne(function(T,C){var D=a[T],M=D.data,N=M.hostModel,R=M.getItemGraphicEl(D.dataIndex),E=dt(fe(C,function(k){return n[k].data.getItemGraphicEl(n[k].dataIndex)}),function(k){return k&&k!==R&&!y[k.id]});R&&(Gf(R),E.length?(O(E,function(k){Gf(k),CT(k)}),o=!0,wT(Ru(E),Ru(R),D.divide,N,T,i)):TT(R,N,D.dataIndex))}).updateOneToMany(function(T,C){var D=n[C],M=D.data.getItemGraphicEl(D.dataIndex);if(!(M&&y[M.id])){var N=dt(fe(T,function(E){return a[E].data.getItemGraphicEl(a[E].dataIndex)}),function(E){return E&&E!==M}),R=a[T[0]].data.hostModel;N.length&&(O(N,function(E){return Gf(E)}),M?(Gf(M),CT(M),o=!0,wT(Ru(M),Ru(N),D.divide,R,T[0],i)):O(N,function(E){return TT(E,R,T[0])}))}}).updateManyToMany(function(T,C){new Qo(C,T,function(D){return n[D].data.getId(n[D].dataIndex)},function(D){return a[D].data.getId(a[D].dataIndex)}).update(function(D,M){w(T[D],C[M])}).execute()}).execute(),o&&O(e,function(T){var C=T.data,D=C.hostModel,M=D&&t.getViewOfSeriesModel(D),N=nd("update",D,0);M&&D.isAnimationEnabled()&&N&&N.duration>0&&M.group.traverse(function(R){R instanceof tt&&!R.animators.length&&R.animateFrom({style:{opacity:0}},N)})})}function X4(r){var e=r.getModel("universalTransition").get("seriesKey");return e||r.id}function q4(r){return ce(r)?r.sort().join(","):r}function Ys(r){if(r.hostModel)return r.hostModel.getModel("universalTransition").get("divideShape")}function GSe(r,e){var t=Te(),n=Te(),a=Te();return O(r.oldSeries,function(i,o){var s=r.oldDataGroupIds[o],l=r.oldData[o],u=X4(i),c=q4(u);n.set(c,{dataGroupId:s,data:l}),ce(u)&&O(u,function(f){a.set(f,{key:c,dataGroupId:s,data:l})})}),O(e.updatedSeries,function(i){if(i.isUniversalTransitionEnabled()&&i.isAnimationEnabled()){var o=i.get("dataGroupId"),s=i.getData(),l=X4(i),u=q4(l),c=n.get(u);if(c)t.set(u,{oldSeries:[{dataGroupId:c.dataGroupId,divide:Ys(c.data),data:c.data}],newSeries:[{dataGroupId:o,divide:Ys(s),data:s}]});else if(ce(l)){var f=[];O(l,function(g){var y=n.get(g);y.data&&f.push({dataGroupId:y.dataGroupId,divide:Ys(y.data),data:y.data})}),f.length&&t.set(u,{oldSeries:f,newSeries:[{dataGroupId:o,data:s,divide:Ys(s)}]})}else{var d=a.get(l);if(d){var v=t.get(d.key);v||(v={oldSeries:[{dataGroupId:d.dataGroupId,data:d.data,divide:Ys(d.data)}],newSeries:[]},t.set(d.key,v)),v.newSeries.push({dataGroupId:o,data:s,divide:Ys(s)})}}}}),t}function Z4(r,e){for(var t=0;t<r.length;t++){var n=e.seriesIndex!=null&&e.seriesIndex===r[t].seriesIndex||e.seriesId!=null&&e.seriesId===r[t].id;if(n)return t}}function HSe(r,e,t,n){var a=[],i=[];O(Lt(r.from),function(o){var s=Z4(e.oldSeries,o);s>=0&&a.push({dataGroupId:e.oldDataGroupIds[s],data:e.oldData[s],divide:Ys(e.oldData[s]),groupIdDim:o.dimension})}),O(Lt(r.to),function(o){var s=Z4(t.updatedSeries,o);if(s>=0){var l=t.updatedSeries[s].getData();i.push({dataGroupId:e.oldDataGroupIds[s],data:l,divide:Ys(l),groupIdDim:o.dimension})}}),a.length>0&&i.length>0&&EY(a,i,n)}function FSe(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,n){O(Lt(n.seriesTransition),function(a){O(Lt(a.to),function(i){for(var o=n.updatedSeries,s=0;s<o.length;s++)(i.seriesIndex!=null&&i.seriesIndex===o[s].seriesIndex||i.seriesId!=null&&i.seriesId===o[s].id)&&(o[s][ix]=!0)})})}),r.registerUpdateLifecycle("series:transition",function(e,t,n){var a=PSe(t);if(a.oldSeries&&n.updatedSeries&&n.optionChanged){var i=n.seriesTransition;if(i)O(Lt(i),function(v){HSe(v,a,n,t)});else{var o=GSe(a,n);O(o.keys(),function(v){var g=o.get(v);EY(g.oldSeries,g.newSeries,t)})}O(n.updatedSeries,function(v){v[ix]&&(v[ix]=!1)})}for(var s=e.getSeries(),l=a.oldSeries=[],u=a.oldDataGroupIds=[],c=a.oldData=[],f=0;f<s.length;f++){var d=s[f].getData();d.count()<RY&&(l.push(s[f]),u.push(s[f].get("dataGroupId")),c.push(d))}})}var USe=(function(){function r(){this.breaks=[],this._elapsedExtent=[1/0,-1/0]}return r.prototype.setBreaks=function(e){this.breaks=e.breaks},r.prototype.update=function(e){WSe(this,e);var t=this._elapsedExtent;t[0]=this.elapse(e[0]),t[1]=this.elapse(e[1])},r.prototype.hasBreaks=function(){return!!this.breaks.length},r.prototype.calcNiceTickMultiple=function(e,t){for(var n=0;n<this.breaks.length;n++){var a=this.breaks[n];if(a.vmin<e&&e<a.vmax){var i=t(e,a.vmax);return i}}return 0},r.prototype.getExtentSpan=function(){return this._elapsedExtent[1]-this._elapsedExtent[0]},r.prototype.normalize=function(e){var t=this._elapsedExtent[1]-this._elapsedExtent[0];return t===0?.5:(this.elapse(e)-this._elapsedExtent[0])/t},r.prototype.scale=function(e){return this.unelapse(e*(this._elapsedExtent[1]-this._elapsedExtent[0])+this._elapsedExtent[0])},r.prototype.elapse=function(e){for(var t=$4,n=K4,a=!0,i=0;i<this.breaks.length;i++){var o=this.breaks[i];if(e<=o.vmax){e>o.vmin?t+=o.vmin-n+(e-o.vmin)/(o.vmax-o.vmin)*o.gapReal:t+=e-n,n=o.vmax,a=!1;break}t+=o.vmin-n+o.gapReal,n=o.vmax}return a&&(t+=e-n),t},r.prototype.unelapse=function(e){for(var t=$4,n=K4,a=!0,i=0,o=0;o<this.breaks.length;o++){var s=this.breaks[o],l=t+s.vmin-n,u=l+s.gapReal;if(e<=u){e>l?i=s.vmin+(e-l)/(u-l)*(s.vmax-s.vmin):i=n+e-t,n=s.vmax,a=!1;break}t=u,n=s.vmax}return a&&(i=n+e-t),i},r})();function YSe(){return new USe}var $4=0,K4=0;function WSe(r,e){var t=0,n={tpAbs:{span:0,val:0},tpPrct:{span:0,val:0}},a=function(){return{has:!1,span:NaN,inExtFrac:NaN,val:NaN}},i={S:{tpAbs:a(),tpPrct:a()},E:{tpAbs:a(),tpPrct:a()}};O(r.breaks,function(s){var l=s.gapParsed;l.type==="tpPrct"&&(t+=l.val);var u=CL(s,e);if(u){var c=u.vmin!==s.vmin,f=u.vmax!==s.vmax,d=u.vmax-u.vmin;if(!(c&&f))if(c||f){var v=c?"S":"E";i[v][l.type].has=!0,i[v][l.type].span=d,i[v][l.type].inExtFrac=d/(s.vmax-s.vmin),i[v][l.type].val=l.val}else n[l.type].span+=d,n[l.type].val+=l.val}});var o=t*(0+(e[1]-e[0])+(n.tpAbs.val-n.tpAbs.span)+(i.S.tpAbs.has?(i.S.tpAbs.val-i.S.tpAbs.span)*i.S.tpAbs.inExtFrac:0)+(i.E.tpAbs.has?(i.E.tpAbs.val-i.E.tpAbs.span)*i.E.tpAbs.inExtFrac:0)-n.tpPrct.span-(i.S.tpPrct.has?i.S.tpPrct.span*i.S.tpPrct.inExtFrac:0)-(i.E.tpPrct.has?i.E.tpPrct.span*i.E.tpPrct.inExtFrac:0))/(1-n.tpPrct.val-(i.S.tpPrct.has?i.S.tpPrct.val*i.S.tpPrct.inExtFrac:0)-(i.E.tpPrct.has?i.E.tpPrct.val*i.E.tpPrct.inExtFrac:0));O(r.breaks,function(s){var l=s.gapParsed;l.type==="tpPrct"&&(s.gapReal=t!==0?Math.max(o,0)*l.val/t:0),l.type==="tpAbs"&&(s.gapReal=l.val),s.gapReal==null&&(s.gapReal=0)})}function XSe(r,e,t,n,a,i){r!=="no"&&O(t,function(o){var s=CL(o,i);if(s)for(var l=e.length-1;l>=0;l--){var u=e[l],c=n(u),f=a*3/4;c>s.vmin-f&&c<s.vmax+f&&(r!=="preserve_extent_bound"||c!==i[0]&&c!==i[1])&&e.splice(l,1)}})}function qSe(r,e,t,n){O(e,function(a){var i=CL(a,t);i&&(r.push({value:i.vmin,break:{type:"vmin",parsedBreak:i},time:n?n(i):void 0}),r.push({value:i.vmax,break:{type:"vmax",parsedBreak:i},time:n?n(i):void 0}))}),e.length&&r.sort(function(a,i){return a.value-i.value})}function CL(r,e){var t=Math.max(r.vmin,e[0]),n=Math.min(r.vmax,e[1]);return t<n||t===n&&t>e[0]&&t<e[1]?{vmin:t,vmax:n,breakOption:r.breakOption,gapParsed:r.gapParsed,gapReal:r.gapReal}:null}function vM(r,e,t){var n=[];if(!r)return{breaks:n};function a(o,s){return o>=0&&o<1-1e-5}O(r,function(o){if(!(!o||o.start==null||o.end==null)&&!o.isExpanded){var s={breakOption:De(o),vmin:e(o.start),vmax:e(o.end),gapParsed:{type:"tpAbs",val:0},gapReal:null};if(o.gap!=null){var l=!1;if(ye(o.gap)){var u=ra(o.gap);if(u.match(/%$/)){var c=parseFloat(u)/100;a(c)||(c=0),s.gapParsed.type="tpPrct",s.gapParsed.val=c,l=!0}}if(!l){var f=e(o.gap);(!isFinite(f)||f<0)&&(f=0),s.gapParsed.type="tpAbs",s.gapParsed.val=f}}if(s.vmin===s.vmax&&(s.gapParsed.type="tpAbs",s.gapParsed.val=0),t&&t.noNegative&&O(["vmin","vmax"],function(v){s[v]<0&&(s[v]=0)}),s.vmin>s.vmax){var d=s.vmax;s.vmax=s.vmin,s.vmin=d}n.push(s)}}),n.sort(function(o,s){return o.vmin-s.vmin});var i=-1/0;return O(n,function(o,s){i>o.vmin&&(n[s]=null),i=o.vmax}),{breaks:n.filter(function(o){return!!o})}}function AL(r,e){return pM(e)===pM(r)}function pM(r){return r.start+"_\0_"+r.end}function ZSe(r,e,t){var n=[];O(r,function(i,o){var s=e(i);s&&s.type==="vmin"&&n.push([o])}),O(r,function(i,o){var s=e(i);if(s&&s.type==="vmax"){var l=Dl(n,function(u){return AL(e(r[u[0]]).parsedBreak.breakOption,s.parsedBreak.breakOption)});l&&l.push(o)}});var a=[];return O(n,function(i){i.length===2&&a.push(t?i:[r[i[0]],r[i[1]]])}),a}function $Se(r,e,t,n){var a,i;if(r.break){var o=r.break.parsedBreak,s=Dl(t,function(f){return AL(f.breakOption,r.break.parsedBreak.breakOption)}),l=n(Math.pow(e,o.vmin),s.vmin),u=n(Math.pow(e,o.vmax),s.vmax),c={type:o.gapParsed.type,val:o.gapParsed.type==="tpAbs"?sr(Math.pow(e,o.vmin+o.gapParsed.val))-l:o.gapParsed.val};a={type:r.break.type,parsedBreak:{breakOption:o.breakOption,vmin:l,vmax:u,gapParsed:c,gapReal:o.gapReal}},i=s[r.break.type]}return{brkRoundingCriterion:i,vBreak:a}}function KSe(r,e,t){var n={noNegative:!0},a=vM(r,t,n),i=vM(r,t,n),o=Math.log(e);return i.breaks=fe(i.breaks,function(s){var l=Math.log(s.vmin)/o,u=Math.log(s.vmax)/o,c={type:s.gapParsed.type,val:s.gapParsed.type==="tpAbs"?Math.log(s.vmin+s.gapParsed.val)/o-l:s.gapParsed.val};return{vmin:l,vmax:u,gapParsed:c,gapReal:s.gapReal,breakOption:s.breakOption}}),{parsedOriginal:a,parsedLogged:i}}var QSe={vmin:"start",vmax:"end"};function JSe(r,e){return e&&(r=r||{},r.break={type:QSe[e.type],start:e.parsedBreak.vmin,end:e.parsedBreak.vmax}),r}function ewe(){Sie({createScaleBreakContext:YSe,pruneTicksByBreak:XSe,addBreaksToTicks:qSe,parseAxisBreakOption:vM,identifyAxisBreak:AL,serializeAxisBreakIdentifier:pM,retrieveAxisBreakPairs:ZSe,getTicksLogTransformBreak:$Se,logarithmicParseBreaksFromOption:KSe,makeAxisLabelFormatterParamBreak:JSe})}var Q4=Je();function twe(r,e){var t=Dl(r,function(n){return dr().identifyAxisBreak(n.parsedBreak.breakOption,e.breakOption)});return t||r.push(t={zigzagRandomList:[],parsedBreak:e,shouldRemove:!1}),t}function rwe(r){O(r,function(e){return e.shouldRemove=!0})}function nwe(r){for(var e=r.length-1;e>=0;e--)r[e].shouldRemove&&r.splice(e,1)}function awe(r,e,t,n,a){var i=t.axis;if(i.scale.isBlank()||!dr())return;var o=dr().retrieveAxisBreakPairs(i.scale.getTicks({breakTicks:"only_break"}),function(E){return E.break},!1);if(!o.length)return;var s=t.getModel("breakArea"),l=s.get("zigzagAmplitude"),u=s.get("zigzagMinSpan"),c=s.get("zigzagMaxSpan");u=Math.max(2,u||0),c=Math.max(u,c||0);var f=s.get("expandOnClick"),d=s.get("zigzagZ"),v=s.getModel("itemStyle"),g=v.getItemStyle(),y=g.stroke,x=g.lineWidth,b=g.lineDash,w=g.fill,T=new Ne({ignoreModelZ:!0}),C=i.isHorizontal(),D=Q4(e).visualList||(Q4(e).visualList=[]);rwe(D);for(var M=function(E){var k=o[E][0].break.parsedBreak,I=[];I[0]=i.toGlobalCoord(i.dataToCoord(k.vmin,!0)),I[1]=i.toGlobalCoord(i.dataToCoord(k.vmax,!0)),I[1]<I[0]&&I.reverse();var B=twe(D,k);B.shouldRemove=!1;var P=new Ne;R(B.zigzagRandomList,P,I[0],I[1],C,k),f&&P.on("click",function(){var H={type:bb,breaks:[{start:k.breakOption.start,end:k.breakOption.end}]};H[i.dim+"AxisIndex"]=t.componentIndex,a.dispatchAction(H)}),P.silent=!f,T.add(P)},N=0;N<o.length;N++)M(N);r.add(T),nwe(D);function R(E,k,I,B,P,H){var V={stroke:y,lineWidth:x,lineDash:b,fill:"none"},j=P?0:1,U=1-j,F=n[Ge[U]]+n[vr[U]];function X(Be){var Le=[],at=[];Le[j]=at[j]=Be,Le[U]=n[Ge[U]],at[U]=F;var ft={x1:Le[0],y1:Le[1],x2:at[0],y2:at[1]};return ib(ft,ft,{lineWidth:1}),Le[0]=ft.x1,Le[1]=ft.y1,Le[j]}I=X(I),B=X(B);for(var G=[],W=[],$=!0,te=n[Ge[U]],ue=0;;ue++){var ge=te===n[Ge[U]],Se=te>=F;Se&&(te=F);var Xe=[],be=[];Xe[j]=I,be[j]=B,!ge&&!Se&&(Xe[j]+=$?-l:l,be[j]-=$?l:-l),Xe[U]=te,be[U]=te,G.push(Xe),W.push(be);var we=void 0;if(ue<E.length?we=E[ue]:(we=Math.random(),E.push(we)),te+=we*(c-u)+u,$=!$,Se)break}var ze=dr().serializeAxisBreakIdentifier(H.breakOption);if(k.add(new Ur({anid:"break_a_"+ze,shape:{points:G},style:V,z:d})),H.gapReal!==0){k.add(new Ur({anid:"break_b_"+ze,shape:{points:W},style:V,z:d}));var oe=W.slice();oe.reverse();var pe=G.concat(oe);k.add(new an({anid:"break_c_"+ze,shape:{points:pe},style:{fill:w,opacity:g.opacity},z:d}))}}}function iwe(r,e,t,n){var a=r.axis,i=t.transform;rn(n.style);var o=a.getExtent();a.inverse&&(o=o.slice(),o.reverse());var s=dr().retrieveAxisBreakPairs(a.scale.getTicks({breakTicks:"only_break"}),function(x){return x.break},!1),l=fe(s,function(x){var b=x[0].break.parsedBreak,w=[a.dataToCoord(b.vmin,!0),a.dataToCoord(b.vmax,!0)];return w[0]>w[1]&&w.reverse(),{coordPair:w,brkId:dr().serializeAxisBreakIdentifier(b.breakOption)}});l.sort(function(x,b){return x.coordPair[0]-b.coordPair[0]});for(var u=o[0],c=null,f=0;f<l.length;f++){var d=l[f],v=Math.max(d.coordPair[0],o[0]),g=Math.min(d.coordPair[1],o[1]);u<=v&&y(u,v,c,d),u=g,c=d}u<=o[1]&&y(u,o[1],c,null);function y(x,b,w,T){function C(I,B){i&&(Qt(I,I,i),Qt(B,B,i))}function D(I,B){var P={x1:I[0],y1:I[1],x2:B[0],y2:B[1]};ib(P,P,n.style),I[0]=P.x1,I[1]=P.y1,B[0]=P.x2,B[1]=P.y2}var M=[x,0],N=[b,0],R=[x,5],E=[b,5];C(M,R),D(M,R),C(N,E),D(N,E),D(M,N);var k=new lr(ie({shape:{x1:M[0],y1:M[1],x2:N[0],y2:N[1]}},n));e.add(k),k.anid="breakLine_"+(w?w.brkId:"\0")+"_\0_"+(T?T.brkId:"\0")}}function owe(r,e,t){if(Dl(t,function(w){return!w}))return;var n=new Ie;if(!yb(t[0],t[1],n,{direction:-(r?e+Math.PI:e),touchThreshold:0,bidirectional:!1}))return;var a=Rr();ns(a,a,-e);var i=fe(t,function(w){return w.transform?Ja(Rr(),a,w.transform):a});function o(w){var T=t[0].localRect,C=new Ie(T[vr[w]]*i[0][0],T[vr[w]]*i[0][1]);return Math.abs(C.y)<1e-5}var s=.5;if(o(0)||o(1)){var l=fe(t,function(w,T){var C=w.localRect.clone();return C.applyTransform(i[T]),C}),u=new Ie;u.copy(t[0].label).add(t[1].label).scale(.5),u.transform(a);var c=n.clone().transform(a),f=l[0].x+l[1].x+(c.x>=0?l[0].width:l[1].width),d=(f+c.x)/2-u.x,v=Math.min(d,d-c.x),g=Math.max(d,d-c.x),y=g<0?g:v>0?v:0;s=(d-y)/c.x}var x=new Ie,b=new Ie;Ie.scale(x,n,-s),Ie.scale(b,n,1-s),gA(t[0],x),gA(t[1],b)}function swe(r,e){var t={breaks:[]};return O(e.breaks,function(n){if(n){var a=Dl(r.get("breaks",!0),function(s){return dr().identifyAxisBreak(s,n)});if(a){var i=e.type,o={isExpanded:!!a.isExpanded};a.isExpanded=i===bb?!0:i===J7?!1:i===eU?!a.isExpanded:a.isExpanded,t.breaks.push({start:a.start,end:a.end,isExpanded:!!a.isExpanded,old:o})}}}),t}function lwe(){nhe({adjustBreakLabelPair:owe,buildAxisBreakLine:iwe,rectCoordBuildBreakAxis:awe,updateModelAxisBreak:swe})}function uwe(r){uhe(r),ewe(),lwe()}function cwe(){Lhe(fwe)}function fwe(r,e){O(r,function(t){if(!t.model.get(["axisLabel","inside"])){var n=hwe(t);if(n){var a=t.isHorizontal()?"height":"width",i=t.model.get(["axisLabel","margin"]);e[a]-=n[a]+i,t.position==="top"?e.y+=n.height+i:t.position==="left"&&(e.x+=n.width+i)}}})}function hwe(r){var e=r.model,t=r.scale;if(!e.get(["axisLabel","show"])||t.isBlank())return;var n,a,i=t.getExtent();t instanceof Bh?a=t.count():(n=t.getTicks(),a=n.length);var o=r.getLabelModel(),s=dd(r),l,u=1;a>40&&(u=Math.ceil(a/40));for(var c=0;c<a;c+=u){var f=n?n[c]:{value:i[0]+c},d=s(f,c),v=o.getTextRect(d),g=y(v,o.get("rotate")||0);l?l.union(g):l=g}return l;function y(x,b){var w=b*Math.PI/180,T=x.width,C=x.height,D=T*Math.abs(Math.cos(w))+Math.abs(C*Math.sin(w)),M=T*Math.abs(Math.sin(w))+Math.abs(C*Math.cos(w)),N=new Oe(x.x,x.y,D,M);return N}}We([tfe]);We([$ce]);We([_fe,Pfe,Wfe,Zhe,ode,Zde,Sve,ipe,Ape,kpe,Bpe,Xpe,Vge,cme,_me,jme,Gme,Kme,aye,pye,_ye,Rye,p0e]);We(I0e);We(ixe);We(AU);We(mxe);We(h9);We(_xe);We(Gxe);We($xe);We(P1e);We(tbe);We(am);We(mbe);We(bbe);We(Lbe);We(zbe);We(Ube);We($be);We(o_e);We(C_e);We(yY);We(xY);We(Y_e);We(TY);We(CY);We(Z_e);We(eSe);We(dSe);We(gSe);We(FSe);We(gce);We(uwe);We(cwe);We($he);const dwe=Object.freeze(Object.defineProperty({__proto__:null,Axis:Va,ChartView:St,ComponentModel:Qe,ComponentView:Rt,List:pn,Model:et,PRIORITY:bF,SeriesModel:Ct,color:vre,connect:xle,dataTool:Mle,dependencies:tle,disConnect:ble,disconnect:DF,dispose:_le,env:nt,extendChartView:tce,extendComponentModel:Que,extendComponentView:Jue,extendSeriesModel:ece,format:jue,getCoordinateSystemDimensions:wle,getInstanceByDom:rN,getInstanceById:Sle,getMap:Ale,graphic:Pue,helper:Due,init:yle,innerDrawElementOnCanvas:QD,matrix:Fte,number:Iue,parseGeoJSON:vA,parseGeoJson:vA,registerAction:ui,registerCoordinateSystem:RF,registerCustomSeries:Tle,registerLayout:EF,registerLoading:sN,registerLocale:ND,registerMap:kF,registerPostInit:NF,registerPostUpdate:LF,registerPreprocessor:aN,registerProcessor:iN,registerTheme:nN,registerTransform:IF,registerUpdateLifecycle:mb,registerVisual:El,setCanvasCreator:Cle,setPlatformAPI:p6,throttle:pb,time:Oue,use:We,util:zue,vector:Dte,version:ele,zrUtil:_te,zrender:$re},Symbol.toStringTag,{value:"Module"}));var To={},Co={},AT={},J4;function vwe(){return J4||(J4=1,(function(r){Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var e=1;r.default=function(){return"".concat(e++)}})(AT)),AT}var ep={},tp={},MT={},eV;function kY(){return eV||(eV=1,(function(r){Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0,r.default=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:60,a=null;return function(){for(var i=this,o=arguments.length,s=new Array(o),l=0;l<o;l++)s[l]=arguments[l];clearTimeout(a),a=setTimeout(function(){t.apply(i,s)},n)}}})(MT)),MT}var Ao={},tV;function ML(){return tV||(tV=1,Object.defineProperty(Ao,"__esModule",{value:!0}),Ao.SizeSensorId=Ao.SensorTabIndex=Ao.SensorClassName=void 0,Ao.SizeSensorId="size-sensor-id",Ao.SensorClassName="size-sensor-object",Ao.SensorTabIndex="-1"),Ao}var rV;function pwe(){if(rV)return tp;rV=1,Object.defineProperty(tp,"__esModule",{value:!0}),tp.createSensor=void 0;var r=t(kY()),e=ML();function t(n){return n&&n.__esModule?n:{default:n}}return tp.createSensor=function(a,i){var o=void 0,s=[],l=function(){getComputedStyle(a).position==="static"&&(a.style.position="relative");var g=document.createElement("object");return g.onload=function(){g.contentDocument.defaultView.addEventListener("resize",u),u()},g.style.display="block",g.style.position="absolute",g.style.top="0",g.style.left="0",g.style.height="100%",g.style.width="100%",g.style.overflow="hidden",g.style.pointerEvents="none",g.style.zIndex="-1",g.style.opacity="0",g.setAttribute("class",e.SensorClassName),g.setAttribute("tabindex",e.SensorTabIndex),g.type="text/html",a.appendChild(g),g.data="about:blank",g},u=(0,r.default)(function(){s.forEach(function(v){v(a)})}),c=function(g){o||(o=l()),s.indexOf(g)===-1&&s.push(g)},f=function(){o&&o.parentNode&&(o.contentDocument&&o.contentDocument.defaultView.removeEventListener("resize",u),o.parentNode.removeChild(o),a.removeAttribute(e.SizeSensorId),o=void 0,s=[],i&&i())},d=function(g){var y=s.indexOf(g);y!==-1&&s.splice(y,1),s.length===0&&o&&f()};return{element:a,bind:c,destroy:f,unbind:d}},tp}var rp={},nV;function gwe(){if(nV)return rp;nV=1,Object.defineProperty(rp,"__esModule",{value:!0}),rp.createSensor=void 0;var r=ML(),e=t(kY());function t(n){return n&&n.__esModule?n:{default:n}}return rp.createSensor=function(a,i){var o=void 0,s=[],l=(0,e.default)(function(){s.forEach(function(v){v(a)})}),u=function(){var g=new ResizeObserver(l);return g.observe(a),l(),g},c=function(g){o||(o=u()),s.indexOf(g)===-1&&s.push(g)},f=function(){o&&o.disconnect(),s=[],o=void 0,a.removeAttribute(r.SizeSensorId),i&&i()},d=function(g){var y=s.indexOf(g);y!==-1&&s.splice(y,1),s.length===0&&o&&f()};return{element:a,bind:c,destroy:f,unbind:d}},rp}var aV;function mwe(){if(aV)return ep;aV=1,Object.defineProperty(ep,"__esModule",{value:!0}),ep.createSensor=void 0;var r=pwe(),e=gwe();return ep.createSensor=typeof ResizeObserver<"u"?e.createSensor:r.createSensor,ep}var iV;function ywe(){if(iV)return Co;iV=1,Object.defineProperty(Co,"__esModule",{value:!0}),Co.removeSensor=Co.getSensor=Co.Sensors=void 0;var r=n(vwe()),e=mwe(),t=ML();function n(o){return o&&o.__esModule?o:{default:o}}var a=Co.Sensors={};function i(o){o&&a[o]&&delete a[o]}return Co.getSensor=function(s){var l=s.getAttribute(t.SizeSensorId);if(l&&a[l])return a[l];var u=(0,r.default)();s.setAttribute(t.SizeSensorId,u);var c=(0,e.createSensor)(s,function(){return i(u)});return a[u]=c,c},Co.removeSensor=function(s){var l=s.element.getAttribute(t.SizeSensorId);s.destroy(),i(l)},Co}var oV;function xwe(){if(oV)return To;oV=1,Object.defineProperty(To,"__esModule",{value:!0}),To.ver=To.clear=To.bind=void 0;var r=ywe();return To.bind=function(t,n){var a=(0,r.getSensor)(t);return a.bind(n),function(){a.unbind(n)}},To.clear=function(t){var n=(0,r.getSensor)(t);(0,r.removeSensor)(n)},To.ver="1.0.3",To}var sV=xwe();function lV(r,e){var t={};return e.forEach(function(n){t[n]=r[n]}),t}function DT(r){return typeof r=="function"}function bwe(r){return typeof r=="string"}var NT,uV;function _we(){return uV||(uV=1,NT=function r(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,a,i;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(a=n;a--!==0;)if(!r(e[a],t[a]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(a=n;a--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[a]))return!1;for(a=n;a--!==0;){var o=i[a];if(!r(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}),NT}var Swe=_we();const Hf=mM(Swe);var wwe=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.echarts=t.echarts,n.ele=null,n.isInitialResize=!0,n.eventHandlerRefs={},n}return e.prototype.componentDidMount=function(){this.renderNewEcharts()},e.prototype.componentDidUpdate=function(t){var n=this.props.shouldSetOption;if(!(DT(n)&&!n(t,this.props))){if(!Hf(t.theme,this.props.theme)||!Hf(t.opts,this.props.opts)){this.dispose(),this.renderNewEcharts();return}var a=this.getEchartsInstance();Hf(t.onEvents,this.props.onEvents)||(this.unbindEvents(a),this.bindEvents(a,this.props.onEvents));var i=["option","notMerge","replaceMerge","lazyUpdate","showLoading","loadingOption"];Hf(lV(this.props,i),lV(t,i))||this.updateEChartsOption(),(!Hf(t.style,this.props.style)||!Hf(t.className,this.props.className))&&this.resize()}},e.prototype.componentWillUnmount=function(){this.dispose()},e.prototype.initEchartsInstance=function(){return SO(this,void 0,void 0,function(){var t=this;return wO(this,function(n){return[2,new Promise(function(a){t.echarts.init(t.ele,t.props.theme,t.props.opts);var i=t.getEchartsInstance();i.on("finished",function(){var o=t.ele.clientWidth,s=t.ele.clientHeight;t.echarts.dispose(t.ele);var l=Sp({width:o,height:s},t.props.opts);a(t.echarts.init(t.ele,t.props.theme,l))})})]})})},e.prototype.getEchartsInstance=function(){return this.echarts.getInstanceByDom(this.ele)},e.prototype.dispose=function(){if(this.ele){try{sV.clear(this.ele)}catch(t){console.warn(t)}this.echarts.dispose(this.ele)}},e.prototype.renderNewEcharts=function(){return SO(this,void 0,void 0,function(){var t,n,a,i,o,s,l=this;return wO(this,function(u){switch(u.label){case 0:return t=this.props,n=t.onEvents,a=t.onChartReady,i=t.autoResize,o=i===void 0?!0:i,[4,this.initEchartsInstance()];case 1:return u.sent(),s=this.updateEChartsOption(),this.bindEvents(s,n||{}),DT(a)&&a(s),this.ele&&o&&sV.bind(this.ele,function(){l.resize()}),[2]}})})},e.prototype.bindEvents=function(t,n){var a=this,i=function(s,l){if(bwe(s)&&DT(l)){var u=function(c){l(c,t)};t.on(s,u),a.eventHandlerRefs[s]=u}};for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&i(o,n[o])},e.prototype.unbindEvents=function(t){for(var n=0,a=Object.entries(this.eventHandlerRefs);n<a.length;n++){var i=a[n],o=i[0],s=i[1];t.off(o,s)}this.eventHandlerRefs={}},e.prototype.updateEChartsOption=function(){var t=this.props,n=t.option,a=t.notMerge,i=a===void 0?!1:a,o=t.replaceMerge,s=o===void 0?null:o,l=t.lazyUpdate,u=l===void 0?!1:l,c=t.showLoading,f=t.loadingOption,d=f===void 0?null:f,v=this.getEchartsInstance();return v.setOption(n,{notMerge:i,replaceMerge:s,lazyUpdate:u}),c?v.showLoading(d):v.hideLoading(),v},e.prototype.resize=function(){var t=this.getEchartsInstance();if(!this.isInitialResize)try{t.resize({width:"auto",height:"auto"})}catch(n){console.warn(n)}this.isInitialResize=!1},e.prototype.render=function(){var t=this,n=this.props,a=n.style,i=n.className,o=i===void 0?"":i;n.echarts,n.option,n.theme,n.notMerge,n.replaceMerge,n.lazyUpdate,n.showLoading,n.loadingOption,n.opts,n.onChartReady,n.onEvents,n.shouldSetOption,n.autoResize;var s=nte(n,["style","className","echarts","option","theme","notMerge","replaceMerge","lazyUpdate","showLoading","loadingOption","opts","onChartReady","onEvents","shouldSetOption","autoResize"]),l=Sp({height:300},a);return OV.createElement("div",Sp({ref:function(u){t.ele=u},style:l,className:"echarts-for-react ".concat(o)},s))},e})(q.PureComponent),Twe=(function(r){K(e,r);function e(t){var n=r.call(this,t)||this;return n.echarts=dwe,n}return e})(wwe);function Cwe({connected:r}){return _.jsx("span",{className:Ae("inline-block w-2 h-2 rounded-full shrink-0",r?"bg-green-500":"bg-muted-foreground/40")})}function Awe({log:r}){return _.jsxs("div",{className:"flex items-start gap-3 py-1.5 border-b border-border/50 last:border-0",children:[_.jsx("span",{className:"text-[11px] text-muted-foreground font-mono shrink-0 pt-px",children:r.time}),_.jsx("span",{className:"text-[11px] text-muted-foreground/70 shrink-0 w-[88px] truncate",children:r.channel}),_.jsx("span",{className:"text-[12px] text-foreground",children:r.message})]})}function Mwe({thisYear:r,lastYear:e}){const t=Array.from({length:52},(o,s)=>{const l=r.find(u=>u.week===s+1);return(l==null?void 0:l.count)??null}),n=Array.from({length:52},(o,s)=>{const l=e.find(u=>u.week===s+1);return(l==null?void 0:l.count)??null}),a=Array.from({length:52},(o,s)=>`${s+1}주`),i={animation:!0,grid:{top:8,right:8,bottom:24,left:36},xAxis:{type:"category",data:a,axisLabel:{interval:3,formatter:(o,s)=>{const u=[0,4,8,13,17,21,26,30,34,39,43,47].indexOf(s);return u>=0?`${u+1}월`:""},fontSize:10,color:"#999"},axisTick:{show:!1},axisLine:{show:!1},splitLine:{show:!0,interval:(o,s)=>["1주","5주","9주","14주","18주","22주","27주","31주","35주","40주","44주","48주"].includes(s),lineStyle:{color:"#e5e7eb",width:1}}},yAxis:{type:"value",axisLabel:{fontSize:10,color:"#999"},splitLine:{lineStyle:{color:"#f3f4f6"}},minInterval:1},series:[{name:"올해",type:"line",data:t,smooth:!0,symbol:"none",connectNulls:!1,lineStyle:{width:2.5,color:"hsl(var(--primary))"},itemStyle:{color:"hsl(var(--primary))"},emphasis:{focus:"none",lineStyle:{width:2.5,opacity:1}},blur:{lineStyle:{opacity:1,width:2.5}}},{name:"작년",type:"line",data:n,smooth:!0,symbol:"none",connectNulls:!1,lineStyle:{width:1.5,color:"#999",type:"dashed"},itemStyle:{color:"#999"},emphasis:{focus:"none",lineStyle:{width:1.5,opacity:1}},blur:{lineStyle:{opacity:1,width:1.5}}}],tooltip:{trigger:"axis",formatter:o=>{var u;const s=((u=o[0])==null?void 0:u.dataIndex)+1,l=o.filter(c=>c.value!=null).map(c=>`${c.seriesName}: ${c.value}건`).join("<br/>");return`${s}주차<br/>${l}`}},legend:{show:!1}};return _.jsx(Twe,{option:i,style:{height:160}})}function Dwe(){const{data:r,isLoading:e}=qq(),{data:t}=Xh(),{data:n}=GV(),{data:a}=uZ(),{data:i}=lZ(),{data:o,isLoading:s}=HV(),{syncing:l,syncResult:u,handleSync:c}=UV(),[f,d]=q.useState("product");t==null||t.channels.filter(M=>M.connected).length;const v=(r==null?void 0:r.operations.actionNeeded)??0;function g(M,N){return N?Math.round((M-N)/N*100):null}function y(M){return M===null?"-":M>=0?`+${M}%`:`${M}%`}const x=g((a==null?void 0:a.thisMonth.revenue)??0,(a==null?void 0:a.lastMonth.revenue)??0),b=g((a==null?void 0:a.thisMonth.revenue)??0,(a==null?void 0:a.lastYearSameMonth.revenue)??0),w=g((a==null?void 0:a.thisWeek.count)??0,(a==null?void 0:a.lastWeek.count)??0),T={pending:"결제대기",paid:"결제완료",preparing:"발송준비",shipped:"배송중",delivered:"배송완료",cancelled:"취소"},C=(n==null?void 0:n.settlement)??[],D=Math.max(...C.map(M=>M.netRevenue??0),1);return e?_.jsxs("div",{children:[_.jsx("h2",{className:"text-xl font-medium mb-6",children:"Overview"}),_.jsx("div",{className:"text-sm text-muted-foreground",children:"로딩 중..."})]}):_.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center justify-between mb-6",children:[_.jsx("h2",{className:"text-xl font-medium",children:"Overview"}),_.jsxs("div",{className:"flex items-center gap-2",children:[v>0&&_.jsxs("div",{className:"flex items-center gap-1.5 text-[12px] text-amber-600 bg-amber-50 dark:bg-amber-950/30 dark:text-amber-400 border border-amber-200 dark:border-amber-800 rounded px-2.5 py-1",children:[_.jsx(DM,{size:12}),"처리 필요 주문 ",v,"건"]}),u&&_.jsx("span",{className:"text-[11px] text-muted-foreground",children:u}),_.jsxs("button",{type:"button",onClick:c,disabled:l,className:"flex items-center gap-1.5 text-[12px] text-muted-foreground hover:text-foreground border border-border rounded px-2.5 py-1 transition-colors disabled:opacity-50",children:[_.jsx(rG,{size:12,className:l?"animate-spin":""}),l?"동기화 중...":"주문 동기화"]})]})]}),_.jsxs("div",{className:"grid grid-cols-6 gap-3 mb-6",children:[_.jsx(Jr,{label:"오늘 주문",value:(a==null?void 0:a.today.count)??"-",sub:"건"}),_.jsx(Jr,{label:"처리 필요 주문",value:v,sub:"결제대기 + 결제완료",highlight:v>0,onClick:()=>{window.location.hash="orders?status=pending,paid"}}),_.jsx(Jr,{label:"이번 달 매출",value:a?`${Math.round(a.thisMonth.revenue/1e4).toLocaleString()}만`:"-",sub:x!==null?`전월比 ${y(x)}`:"전월 데이터 없음",highlight:x!==null&&x>0}),_.jsx(Jr,{label:"이번 달 주문",value:(a==null?void 0:a.thisMonth.count)??"-",sub:"건"}),_.jsx(Jr,{label:"누적 주문",value:(n==null?void 0:n.totalOrders.toLocaleString())??"-"}),_.jsx(Jr,{label:"누적 매출",value:`${Math.round(((n==null?void 0:n.totalRevenue)??0)/1e4).toLocaleString()}만원`})]}),_.jsxs("div",{className:"grid grid-cols-3 gap-4 mb-6",children:[_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4",children:[_.jsxs("div",{className:"flex items-center gap-1.5 text-[12px] font-medium",children:[_.jsx(px,{size:13}),"판매채널"]}),_.jsx("div",{className:"text-[10px] text-muted-foreground opacity-60 mb-3",children:"API 연결 상태"}),_.jsx("div",{className:"space-y-1.5 mb-3",children:((r==null?void 0:r.listing.channels)??(t==null?void 0:t.channels)??[]).map(M=>_.jsxs("div",{className:"flex items-center gap-2 text-[12px]",children:[_.jsx(Cwe,{connected:M.connected}),_.jsx("span",{className:"text-foreground",children:M.channel}),M.connected?_.jsx("span",{className:"ml-auto text-[11px] text-muted-foreground",children:M.storeId}):_.jsx("span",{className:"ml-auto text-[11px] text-muted-foreground",children:"미연결"})]},M.channel))}),((r==null?void 0:r.listing.recentLogs)??[]).length>0&&_.jsx("div",{className:"pt-2 border-t border-border/50",children:r==null?void 0:r.listing.recentLogs.map((M,N)=>_.jsx("div",{className:"text-[11px] text-muted-foreground py-0.5 truncate",children:M.message},`${N}-${M.message}`))})]}),_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4",children:[_.jsxs("div",{className:"flex items-center gap-1.5 text-[12px] font-medium",children:[_.jsx(Hp,{size:13}),"채널별 주문"]}),_.jsx("div",{className:"text-[10px] text-muted-foreground opacity-60 mb-3",children:"임포트 데이터 기준 (API+CSV 포함)"}),C.length>0?(()=>{const M=Math.max(...C.map(N=>N.orderCount),1);return _.jsx("div",{className:"space-y-2",children:[...C].sort((N,R)=>R.orderCount-N.orderCount).map(N=>_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx("span",{className:"text-[11px] w-[72px] shrink-0 truncate",children:Dr[N.channel]??N.channel}),_.jsx("div",{className:"flex-1 min-w-0",children:_.jsx("div",{className:"w-full bg-muted rounded-full h-1.5",children:_.jsx("div",{className:"h-full bg-primary/50 rounded-full",style:{width:`${N.orderCount/M*100}%`}})})}),_.jsx("span",{className:"text-[11px] text-muted-foreground shrink-0 w-8 text-right",children:N.orderCount.toLocaleString()})]},N.channel))})})():_.jsx("div",{className:"text-[12px] text-muted-foreground",children:"데이터 없음"})]}),_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4",children:[_.jsxs("div",{className:"flex items-center gap-1.5 mb-3 text-[12px] font-medium",children:[_.jsx(nG,{size:13}),"주문상태"]}),r!=null&&r.operations.orderSummary&&Object.keys(r.operations.orderSummary).length>0?_.jsx("div",{className:"space-y-1 mb-3",children:Object.entries(r.operations.orderSummary).map(([M,N])=>_.jsxs("div",{className:"flex items-center justify-between text-[12px]",children:[_.jsx("span",{className:"text-muted-foreground",children:T[M]??M}),_.jsxs("span",{className:"font-medium",children:[N,"건"]})]},M))}):_.jsx("div",{className:"text-[12px] text-muted-foreground mb-3",children:"주문 데이터 없음"}),(r==null?void 0:r.operations.orderCacheAge)!==null&&(r==null?void 0:r.operations.orderCacheAge)!==void 0&&_.jsxs("div",{className:"text-[10px] text-muted-foreground/60 pt-2 border-t border-border/50",children:[Math.floor(r.operations.orderCacheAge/60),"분 전 갱신"]})]})]}),_.jsxs("div",{className:"grid grid-cols-[1fr_2fr_1fr] gap-4 mb-6",children:[_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4",children:[_.jsxs("div",{className:"flex items-center justify-between mb-3",children:[_.jsxs("div",{className:"flex items-center gap-1.5 text-[12px] font-medium",children:[_.jsx(Hp,{size:13}),"매출 랭킹"]}),_.jsx("div",{className:"flex gap-0.5",children:["product","sku","category","line"].map(M=>_.jsx("button",{type:"button",onClick:()=>d(M),className:Ae("text-[10px] px-1.5 py-0.5 rounded transition-colors",f===M?"bg-primary text-primary-foreground":"text-muted-foreground hover:text-foreground"),children:M==="product"?"상품":M==="sku"?"SKU":M==="category"?"카테고리":"제품라인"},M))})]}),s?_.jsx("div",{className:"text-[11px] text-muted-foreground",children:"로딩 중..."}):(()=>{var R;let M=[];if(f==="product"?M=[...(o==null?void 0:o.catalog)??[]].sort((E,k)=>k.totalRevenue-E.totalRevenue).slice(0,8).map(E=>({key:E.productName,label:E.productName,totalRevenue:E.totalRevenue})):f==="sku"?M=[...(o==null?void 0:o.catalog)??[]].sort((E,k)=>k.totalRevenue-E.totalRevenue).slice(0,8).map(E=>({key:E.sku,label:E.sku||E.productName,totalRevenue:E.totalRevenue})):f==="category"?M=[...(o==null?void 0:o.byCategory)??[]].sort((E,k)=>k.totalRevenue-E.totalRevenue).slice(0,8).map(E=>({key:E.category,label:E.category||"미분류",totalRevenue:E.totalRevenue})):M=[...(o==null?void 0:o.byLine)??[]].sort((E,k)=>k.totalRevenue-E.totalRevenue).slice(0,8).map(E=>({key:E.productLine,label:E.productLine||"미분류",totalRevenue:E.totalRevenue})),M.length===0)return _.jsx("div",{className:"text-[11px] text-muted-foreground",children:"데이터 없음"});const N=((R=M[0])==null?void 0:R.totalRevenue)??1;return _.jsx("div",{className:"space-y-2",children:M.map((E,k)=>_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx("span",{className:"text-[10px] text-muted-foreground w-3 text-right shrink-0",children:k+1}),_.jsxs("div",{className:"flex-1 min-w-0",children:[_.jsxs("div",{className:"flex items-center justify-between mb-0.5",children:[_.jsx("span",{className:"text-[11px] truncate",children:E.label}),_.jsxs("span",{className:"text-[10px] text-muted-foreground ml-1 shrink-0",children:[Math.round(E.totalRevenue/1e4).toLocaleString(),"만"]})]}),_.jsx("div",{className:"w-full bg-muted rounded-full h-1",children:_.jsx("div",{className:"h-full bg-primary/50 rounded-full",style:{width:`${E.totalRevenue/N*100}%`}})})]})]},E.key||k))})})(),(f==="category"||f==="line")&&((o==null?void 0:o.unmappedCount)??0)>0&&_.jsxs("div",{className:"mt-2 text-[10px] text-muted-foreground/60 border-t border-border/50 pt-1.5",children:["미매핑 ",o==null?void 0:o.unmappedCount,"건 제외"]})]}),C.length>0?_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4",children:[_.jsx("div",{className:"text-[12px] font-medium mb-3",children:"채널별 정산 현황"}),_.jsxs("table",{className:"w-full text-[12px]",style:{borderCollapse:"collapse"},children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border",children:[_.jsx("th",{className:"py-1.5 text-left text-[11px] font-semibold text-muted-foreground",children:"채널"}),_.jsx("th",{className:"py-1.5 text-right text-[11px] font-semibold text-muted-foreground",children:"주문"}),_.jsx("th",{className:"py-1.5 text-right text-[11px] font-semibold text-muted-foreground",children:"매출"}),_.jsx("th",{className:"py-1.5 text-right text-[11px] font-semibold text-muted-foreground",children:"수수료율"}),_.jsx("th",{className:"py-1.5 text-right text-[11px] font-semibold text-muted-foreground",children:"순수익"})]})}),_.jsx("tbody",{children:C.map(M=>_.jsxs("tr",{className:"border-b border-border/50",children:[_.jsx("td",{className:"py-1.5",children:Dr[M.channel]??M.channel}),_.jsx("td",{className:"py-1.5 text-right text-muted-foreground",children:M.orderCount.toLocaleString()}),_.jsxs("td",{className:"py-1.5 text-right font-medium",children:[Math.round(M.totalRevenue/1e4).toLocaleString(),"만"]}),_.jsx("td",{className:"py-1.5 text-right text-muted-foreground",children:M.avgCommissionRate!=null?`${(M.avgCommissionRate*100).toFixed(1)}%`:"-"}),_.jsx("td",{className:"py-1.5 text-right text-emerald-600 dark:text-emerald-400 font-medium",children:M.netRevenue!=null?`${Math.round(M.netRevenue/1e4).toLocaleString()}만`:"-"})]},M.channel))})]})]}):_.jsx("div",{className:"border border-border rounded-lg bg-card p-4 flex items-center justify-center text-[12px] text-muted-foreground",children:"정산 데이터 없음"}),_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4",children:[_.jsxs("div",{className:"flex items-center gap-1.5 mb-3 text-[12px] font-medium",children:[_.jsx(XZ,{size:13}),"공헌이익 순위"]}),C.length>0?_.jsxs(_.Fragment,{children:[_.jsx("div",{className:"space-y-2",children:[...C].filter(M=>M.netRevenue!=null).sort((M,N)=>(N.netRevenue??0)-(M.netRevenue??0)).slice(0,8).map((M,N)=>{const R=(M.netRevenue??0)/D*100;return _.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx("span",{className:"text-[10px] text-muted-foreground w-3 text-right shrink-0",children:N+1}),_.jsxs("div",{className:"flex-1 min-w-0",children:[_.jsxs("div",{className:"flex items-center justify-between mb-0.5",children:[_.jsx("span",{className:"text-[11px] truncate",children:Dr[M.channel]??M.channel}),_.jsxs("span",{className:"text-[10px] text-emerald-600 dark:text-emerald-400 ml-1 shrink-0",children:[Math.round((M.netRevenue??0)/1e4).toLocaleString(),"만"]})]}),_.jsx("div",{className:"w-full bg-muted rounded-full h-1",children:_.jsx("div",{className:"h-full bg-emerald-500/50 rounded-full",style:{width:`${R}%`}})})]})]},M.channel)})}),_.jsx("div",{className:"mt-2 text-[10px] text-muted-foreground/60 border-t border-border/50 pt-1.5",children:"채널별 순수익 기준 · 채널×카테고리 조합 추후 지원"})]}):_.jsx("div",{className:"text-[12px] text-muted-foreground",children:"데이터 없음"})]})]}),(a||i)&&_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4 mb-6",children:[_.jsxs("div",{className:"flex items-center gap-1.5 mb-4 text-[12px] font-medium",children:[_.jsx(ll,{size:13}),"성장 트렌드"]}),_.jsxs("div",{className:"grid grid-cols-[200px_1fr] gap-6",children:[_.jsx("div",{className:"space-y-3",children:[{label:"전월비 MoM",pct:x,sub:"이번달 매출 기준"},{label:"전년동월비 YoY",pct:b,sub:"이번달 매출 기준"},{label:"전주비 WoW",pct:w,sub:"이번주 주문 기준"}].map(({label:M,pct:N,sub:R})=>_.jsxs("div",{children:[_.jsx("div",{className:"text-[10px] text-muted-foreground opacity-60",children:M}),_.jsxs("div",{className:Ae("text-[18px] font-semibold flex items-center gap-1",N===null?"text-muted-foreground":N>=0?"text-emerald-600 dark:text-emerald-400":"text-red-500"),children:[N!==null&&(N>=0?_.jsx(ll,{size:14}):_.jsx(aG,{size:14})),y(N)]}),_.jsx("div",{className:"text-[10px] text-muted-foreground opacity-60",children:R})]},M))}),_.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center gap-3 mb-2 text-[10px] text-muted-foreground",children:[_.jsxs("span",{className:"flex items-center gap-1",children:[_.jsx("span",{className:"inline-block w-4 h-0.5 bg-primary rounded"}),"올해"]}),_.jsxs("span",{className:"flex items-center gap-1 opacity-40",children:[_.jsx("span",{className:"inline-block w-4 h-0.5 bg-muted-foreground rounded"}),"작년"]}),_.jsx("span",{className:"ml-auto opacity-60",children:"주간 주문 건수"})]}),i?_.jsx(Mwe,{thisYear:i.thisYear,lastYear:i.lastYear}):_.jsx("div",{className:"h-[72px] flex items-center justify-center text-[11px] text-muted-foreground",children:"로딩 중..."})]})]})]}),_.jsxs("div",{className:"border border-border rounded-lg bg-card p-4",children:[_.jsxs("div",{className:"text-[12px] font-medium mb-3 flex items-center gap-1.5",children:[_.jsx(i$,{size:12}),"최근 활동"]}),((r==null?void 0:r.logs)??[]).length===0?_.jsx("div",{className:"text-[12px] text-muted-foreground py-3 text-center",children:"활동 없음"}):_.jsx("div",{children:((r==null?void 0:r.logs)??[]).slice(0,10).map((M,N)=>_.jsx(Awe,{log:M},N))})]})]})}function V0(r){return`${Math.round(r/1e4).toLocaleString()}만원`}function cV({label:r,options:e,selected:t,onToggle:n,onClear:a}){const[i,o]=q.useState(!1);return _.jsxs("div",{className:"relative",children:[_.jsxs("button",{type:"button",onClick:()=>o(!i),className:Ae("flex items-center gap-1 text-[12px] px-2.5 py-1 rounded-md border cursor-pointer transition-colors",t.size>0?"border-primary/40 bg-primary/5 text-foreground":"border-border bg-card text-muted-foreground"),children:[r,t.size>0&&_.jsx("span",{className:"text-[10px] font-semibold bg-primary/10 text-primary px-1 rounded",children:t.size}),_.jsx(Sn,{size:12,className:Ae("transition-transform",i&&"rotate-180")})]}),i&&_.jsxs(_.Fragment,{children:[_.jsx("div",{className:"fixed inset-0 z-10",onClick:()=>o(!1)}),_.jsxs("div",{className:"absolute top-full left-0 mt-1 z-20 bg-card border border-border rounded-lg shadow-lg py-1 min-w-[160px] max-h-[280px] overflow-y-auto",children:[t.size>0&&_.jsxs("button",{type:"button",onClick:()=>{a(),o(!1)},className:"w-full text-left px-3 py-1.5 text-[11px] text-muted-foreground hover:bg-muted/50 flex items-center gap-1",children:[_.jsx(ml,{size:10})," 초기화"]}),e.map(s=>_.jsxs("label",{className:"flex items-center gap-2 px-3 py-1.5 text-[12px] hover:bg-muted/50 cursor-pointer",children:[_.jsx("input",{type:"checkbox",checked:t.has(s),onChange:()=>n(s),className:"rounded border-border"}),s||"(미분류)"]},s))]})]})]})}function Nwe(){const[r,e]=q.useState(""),[t,n]=q.useState(""),a=q.useMemo(()=>{const oe={};return r&&(oe.from=r),t&&(oe.to=t),Object.keys(oe).length>0?oe:void 0},[r,t]),{data:i,isLoading:o,error:s}=HV(a),[l,u]=q.useState("category"),[c,f]=q.useState(new Set),[d,v]=q.useState(new Set),[g,y]=q.useState(new Set),[x,b]=q.useState(!1),[w,T]=q.useState(null),[C,D]=q.useState(""),[M,N]=q.useState(!1),[R,E]=q.useState(""),[k,I]=q.useState(!1),B=q.useCallback(async()=>{if(x){b(!1),N(!1);return}try{const pe=await(await fetch("/api/product-rules")).json();T(pe.content),D(pe.path),b(!0)}catch{b(!0)}},[x]),P=q.useCallback(()=>{E(w??""),N(!0)},[w]),H=q.useCallback(async()=>{I(!0);try{await fetch("/api/product-rules",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({content:R})}),T(R),N(!1)}finally{I(!1)}},[R]),V=(i==null?void 0:i.catalog)??[],j=(i==null?void 0:i.byCategory)??[],U=(i==null?void 0:i.byLine)??[],F=q.useMemo(()=>V.filter(oe=>!(d.size>0&&!d.has(oe.category??"")||g.size>0&&!g.has(oe.productLine??""))),[V,d,g]),X=q.useMemo(()=>[...F].sort((oe,pe)=>pe.totalRevenue-oe.totalRevenue),[F]),G=q.useMemo(()=>{const oe=new Map;for(const pe of X){const Be=`${pe.productName}||${pe.brand??""}||${pe.productLine??""}`,Le=oe.get(Be);Le?(Le.skus.push(pe),Le.totalQuantity+=pe.totalQuantity,Le.totalRevenue+=pe.totalRevenue,Le.orderCount+=pe.orderCount):oe.set(Be,{key:Be,productName:pe.productName,brand:pe.brand,productLine:pe.productLine,category:pe.category,skus:[pe],totalQuantity:pe.totalQuantity,totalRevenue:pe.totalRevenue,orderCount:pe.orderCount})}return[...oe.values()].sort((pe,Be)=>Be.totalRevenue-pe.totalRevenue)},[X]),W=oe=>{f(pe=>{const Be=new Set(pe);return Be.has(oe)?Be.delete(oe):Be.add(oe),Be})},$=q.useMemo(()=>V.reduce((oe,pe)=>oe+pe.totalQuantity,0),[V]),te=q.useMemo(()=>V.reduce((oe,pe)=>oe+pe.totalRevenue,0),[V]),ue=q.useMemo(()=>[...new Set(V.map(oe=>oe.category??""))].sort(),[V]),ge=q.useMemo(()=>[...new Set(V.map(oe=>oe.productLine??""))].sort(),[V]),Se=q.useMemo(()=>Math.max(...j.map(oe=>oe.totalRevenue),1),[j]),Xe=q.useMemo(()=>Math.max(...U.map(oe=>oe.totalRevenue),1),[U]),be=(oe,pe)=>{const Be=new Set(oe);return Be.has(pe)?Be.delete(pe):Be.add(pe),Be},we=d.size>0||g.size>0,ze=!!r||!!t;return o?_.jsxs("div",{children:[_.jsx("h2",{className:"text-xl font-medium mb-6",children:"상품"}),_.jsx("div",{className:"text-sm text-muted-foreground py-8 text-center",children:"불러오는 중..."})]}):s?_.jsxs("div",{children:[_.jsx("h2",{className:"text-xl font-medium mb-6",children:"상품"}),_.jsx("div",{className:"text-sm text-destructive py-8 text-center",children:"카탈로그 조회 실패"})]}):V.length===0&&!ze?_.jsxs("div",{children:[_.jsx("h2",{className:"text-xl font-medium mb-6",children:"상품"}),_.jsxs("div",{className:"border border-dashed border-border rounded-lg p-12 text-center text-muted-foreground text-sm",children:["상품 카탈로그가 비어있습니다.",_.jsx("div",{className:"text-[11px] mt-1",children:"sppt product parse 스킬로 상품명을 해체하세요."})]})]}):_.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center justify-between mb-4",children:[_.jsx("h2",{className:"text-xl font-medium",children:"상품"}),_.jsxs("div",{className:"flex items-center gap-3",children:[_.jsxs("button",{type:"button",onClick:B,className:Ae("flex items-center gap-1.5 text-[12px] px-2.5 py-1 rounded-md border cursor-pointer transition-colors",x?"border-primary bg-primary text-primary-foreground":"border-primary bg-primary text-primary-foreground hover:opacity-90"),children:[_.jsx(WI,{size:12}),"분류 규칙"]}),_.jsxs("span",{className:"text-[12px] text-muted-foreground",children:["총 ",V.length.toLocaleString(),"개 SKU"]})]})]}),_.jsx(FM,{from:r,to:t,onChange:(oe,pe)=>{e(oe),n(pe)},className:"mb-5"}),x&&_.jsxs("div",{className:"border border-border rounded-lg bg-card mb-6 overflow-hidden",children:[_.jsxs("div",{className:"flex items-center justify-between px-4 py-2 border-b border-border bg-muted/40",children:[_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx(WI,{size:13,className:"text-muted-foreground"}),_.jsx("span",{className:"text-[12px] font-medium",children:"분류 규칙"}),C&&_.jsx("span",{className:"text-[10px] text-muted-foreground font-mono",children:C})]}),_.jsxs("div",{className:"flex items-center gap-2",children:[M?_.jsxs(_.Fragment,{children:[_.jsx("button",{type:"button",onClick:()=>N(!1),className:"text-[11px] px-2 py-0.5 rounded border border-border text-muted-foreground hover:text-foreground cursor-pointer",children:"취소"}),_.jsx("button",{type:"button",onClick:H,disabled:k,className:"text-[11px] px-2.5 py-0.5 rounded bg-primary text-primary-foreground cursor-pointer disabled:opacity-50",children:k?"저장 중...":"저장"})]}):_.jsx("button",{type:"button",onClick:P,className:"text-[11px] px-2.5 py-0.5 rounded border border-border bg-secondary text-foreground hover:bg-muted cursor-pointer",children:"편집"}),_.jsx("button",{type:"button",onClick:()=>{b(!1),N(!1)},className:"text-muted-foreground hover:text-foreground cursor-pointer",children:_.jsx(ml,{size:14})})]})]}),_.jsx("div",{className:"px-4 py-2 text-[11px] text-muted-foreground border-b border-border/50 bg-muted/20",children:"AI가 이 규칙을 바탕으로 주문 데이터의 상품명을 SKU, 카테고리, 제품라인 단위로 자동 분류합니다."}),_.jsx("div",{className:"px-4 py-3 max-h-[400px] overflow-y-auto",children:M?_.jsx("textarea",{value:R,onChange:oe=>E(oe.target.value),className:"w-full h-[350px] text-[11px] leading-relaxed bg-transparent outline-none resize-none font-sans text-foreground/90",placeholder:`예시:
304
-
305
- ## 카테고리 분류
306
- - 프라이팬/웍: '팬', '웍' 류
307
- - 냄비: '냄비', '쿠커' 포함
308
-
309
- ## 제품 라인
310
- - 디피니티, 엑스클립스 ...`}):w?_.jsx("pre",{className:"text-[11px] leading-relaxed text-foreground/80 whitespace-pre-wrap font-sans",children:w}):_.jsxs("div",{className:"text-[12px] text-muted-foreground py-4 text-center",children:["분류 규칙이 등록되지 않았습니다.",_.jsxs("div",{className:"text-[11px] mt-1",children:[_.jsx("button",{type:"button",onClick:P,className:"underline cursor-pointer",children:"여기서 직접 작성"}),"하거나 AI(e.g. Claude Code 등)에서 알려주세요."]})]})}),_.jsxs("div",{className:"px-4 py-2.5 border-t border-border bg-muted/20 text-[11px] text-muted-foreground",children:[_.jsx("span",{className:"font-medium text-foreground/70",children:"Tip"})," 분류 규칙은 자연어로 자유롭게 작성하세요. AI(e.g. Claude Code 등)에서"," ",_.jsx("span",{className:"font-mono bg-muted/40 px-1 rounded text-[10px]",children:"우리 상품 분류 규칙 이렇게 바꿔줘"})," ","라고 하면 AI가 이 파일을 직접 수정합니다. 규칙 작성 후"," ",_.jsx("span",{className:"font-mono bg-muted/40 px-1 rounded text-[10px]",children:"상품명 분석해줘"})," ","로 카탈로그를 자동 구축할 수 있습니다."]})]}),_.jsxs("div",{className:"grid grid-cols-4 gap-3 mb-4",children:[_.jsx(Jr,{label:"카탈로그 SKU",value:V.length.toLocaleString()}),_.jsx(Jr,{label:"미매핑 상품",value:(i==null?void 0:i.unmappedCount)??0,warn:((i==null?void 0:i.unmappedCount)??0)>0}),_.jsx(Jr,{label:"총 판매 수량",value:$.toLocaleString(),sub:"개"}),_.jsx(Jr,{label:"총 매출",value:V0(te)})]}),_.jsxs("div",{className:"border border-border/50 rounded-lg bg-muted/10 px-4 py-3 mb-6 text-[11px] text-muted-foreground space-y-1.5",children:[_.jsxs("div",{className:"flex gap-6",children:[_.jsx("span",{className:"shrink-0 font-medium text-foreground/50 w-16",children:"상품 분류"}),_.jsxs("span",{children:["위 ",_.jsx("span",{className:"text-foreground/70 font-medium",children:"분류 규칙"})," 버튼에서 규칙을 작성해두면, AI에서"," ",_.jsx("span",{className:"font-mono bg-muted/60 px-1 rounded",children:"상품명 분석해줘"})," 한마디로 상품 목록이 자동으로 구축됩니다."]})]}),_.jsxs("div",{className:"flex gap-6",children:[_.jsx("span",{className:"shrink-0 font-medium text-foreground/50 w-16",children:"원가 등록"}),_.jsxs("span",{children:["매입단가·택배비 등이 담긴 엑셀 파일을 AI에 붙여넣고 입력해달라고 하면,"," ",_.jsx("span",{className:"font-mono bg-muted/60 px-1 rounded",children:"sppt cost set"})," 커맨드로 알아서 처리해줍니다. 단품 기준으로 공헌이익이 계산됩니다."]})]})]}),_.jsxs("div",{className:"flex items-center justify-between mb-4",children:[_.jsx("span",{className:"text-[13px] font-medium",children:"판매요약"}),_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx("button",{type:"button",onClick:()=>u("category"),className:Ae("text-[12px] px-3 py-1.5 rounded-md border transition-colors cursor-pointer",l==="category"?"border-primary/40 bg-primary/5 text-foreground font-medium":"border-border bg-card text-muted-foreground"),children:"카테고리별"}),_.jsx("button",{type:"button",onClick:()=>u("line"),className:Ae("text-[12px] px-3 py-1.5 rounded-md border transition-colors cursor-pointer",l==="line"?"border-primary/40 bg-primary/5 text-foreground font-medium":"border-border bg-card text-muted-foreground"),children:"제품라인별"})]})]}),_.jsx("div",{className:"border border-border rounded-lg overflow-hidden mb-6",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:l==="category"?"카테고리":"제품라인"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"주문수"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"판매 수량"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"매출"}),_.jsx("th",{className:"px-3 py-2 text-right w-[60px]",children:"비중(%)"}),_.jsx("th",{className:"px-3 py-2 w-[120px]"})]})}),_.jsx("tbody",{className:"bg-card",children:(l==="category"?j:U).map((oe,pe)=>{const Be=l==="category"?oe.category:oe.productLine,Le=l==="category"?Se:Xe,at=te>0?oe.totalRevenue/te*100:0,ft=Le>0?oe.totalRevenue/Le*100:0;return _.jsxs("tr",{className:Ae("border-b border-border/60",pe%2!==0&&"bg-muted/5"),children:[_.jsx("td",{className:"px-3 py-2",children:Be||"(미분류)"}),_.jsx("td",{className:"px-3 py-2 text-right",children:oe.orderCount.toLocaleString()}),_.jsx("td",{className:"px-3 py-2 text-right",children:oe.totalQuantity.toLocaleString()}),_.jsx("td",{className:"px-3 py-2 text-right",children:V0(oe.totalRevenue)}),_.jsx("td",{className:"px-3 py-2 text-right",children:at.toFixed(1)}),_.jsx("td",{className:"px-3 py-2",children:_.jsx("div",{className:"h-2 rounded-full bg-muted/30 overflow-hidden",children:_.jsx("div",{className:"h-full rounded-full bg-primary/60",style:{width:`${ft}%`}})})})]},Be)})})]})}),_.jsxs("div",{className:"flex items-center justify-between mb-3",children:[_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx("span",{className:"text-[12px] font-medium",children:"상품 목록"}),_.jsx(cV,{label:"카테고리",options:ue,selected:d,onToggle:oe=>v(be(d,oe)),onClear:()=>v(new Set)}),_.jsx(cV,{label:"제품라인",options:ge,selected:g,onToggle:oe=>y(be(g,oe)),onClear:()=>y(new Set)}),we&&_.jsxs(_.Fragment,{children:[_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:[G.length,"개 상품"]}),_.jsxs("button",{type:"button",onClick:()=>{v(new Set),y(new Set)},className:"text-[11px] text-muted-foreground hover:text-foreground flex items-center gap-0.5 cursor-pointer",children:[_.jsx(ml,{size:11})," 초기화"]})]})]}),_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:[G.length,"개 상품 · ",X.length,"개 품목"]})]}),_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left w-6"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"상품명"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"브랜드"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"제품라인"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"카테고리"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"SKU수"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"수량"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"매출"})]})}),_.jsxs("tbody",{className:"bg-card",children:[G.map((oe,pe)=>{const Be=c.has(oe.key);return _.jsxs(_.Fragment,{children:[_.jsxs("tr",{className:Ae("border-b border-border/60 cursor-pointer hover:bg-muted/30 transition-colors",pe%2!==0&&"bg-muted/5",Be&&"bg-primary/5 border-primary/20"),onClick:()=>W(oe.key),onKeyDown:Le=>{(Le.key==="Enter"||Le.key===" ")&&W(oe.key)},children:[_.jsx("td",{className:"px-3 py-2 text-muted-foreground/50 w-6",children:Be?_.jsx(Sn,{size:13}):_.jsx(Pn,{size:13})}),_.jsx("td",{className:"px-3 py-2 font-medium max-w-[260px] truncate",title:oe.productName,children:oe.productName}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground",children:oe.brand??"-"}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground",children:oe.productLine||"(미분류)"}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground",children:oe.category||"(미분류)"}),_.jsx("td",{className:"px-3 py-2 text-right text-muted-foreground",children:oe.skus.length}),_.jsx("td",{className:"px-3 py-2 text-right",children:oe.totalQuantity.toLocaleString()}),_.jsx("td",{className:"px-3 py-2 text-right",children:V0(oe.totalRevenue)})]},oe.key),Be&&oe.skus.map(Le=>{const at=Le.contributionMargin,ft=at===null?"text-muted-foreground/40":at>=0?"text-emerald-600 dark:text-emerald-400":"text-red-500";return _.jsxs("tr",{className:"border-b border-border/40 bg-muted/20",children:[_.jsx("td",{className:"py-1.5 w-6"}),_.jsx("td",{className:"pl-6 pr-3 py-1.5 text-muted-foreground",colSpan:1,children:_.jsxs("div",{className:"flex items-center gap-2",children:[_.jsx("span",{className:"font-mono text-[10px] bg-muted/60 px-1.5 py-0.5 rounded shrink-0",children:Le.sku}),_.jsx("span",{className:"text-[11px] text-foreground/80",children:[Le.productName,Le.option].filter(Boolean).join(" / ")})]})}),_.jsxs("td",{colSpan:3,className:"px-3 py-1.5 text-[11px] text-muted-foreground/60",children:["판매단가"," ",Le.totalQuantity>0?`${Math.round(Le.totalRevenue/Le.totalQuantity).toLocaleString()}원`:"-",Le.totalVariableCost!==null&&_.jsxs("span",{className:"ml-2",children:["· 변동비 ",Math.round(Le.totalVariableCost).toLocaleString(),"원"]}),at!==null&&_.jsxs("span",{className:Ae("ml-2 font-medium",ft),children:["· 공헌이익 ",Math.round(at).toLocaleString(),"원"]})]}),_.jsx("td",{className:"px-3 py-1.5 text-right text-[11px] text-muted-foreground",children:Le.totalQuantity.toLocaleString()}),_.jsx("td",{className:"px-3 py-1.5 text-right text-[11px]",colSpan:2,children:V0(Le.totalRevenue)})]},Le.sku)})]})}),G.length===0&&_.jsx("tr",{children:_.jsx("td",{colSpan:8,className:"px-3 py-8 text-center text-muted-foreground text-[13px]",children:"필터 조건에 맞는 상품이 없습니다."})})]})]})})]})}function Lwe(r){if(!r.startedAt)return"";const t=(r.endedAt??Date.now())-r.startedAt;return t<1e3?`${t}ms`:`${(t/1e3).toFixed(1)}s`}function Rwe({status:r}){return r==="pending"?_.jsx("span",{className:"w-4 h-4 rounded-full border-2 border-muted-foreground/40 flex-shrink-0"}):r==="running"?_.jsx("span",{className:"w-4 h-4 flex-shrink-0 flex items-center justify-center",children:_.jsx("span",{className:"w-3.5 h-3.5 border-2 border-blue-500 border-t-transparent rounded-full animate-spin"})}):r==="completed"?_.jsx("span",{className:"w-4 h-4 rounded-full bg-green-500/15 flex-shrink-0 flex items-center justify-center",children:_.jsx("svg",{width:"10",height:"10",viewBox:"0 0 10 10",fill:"none","aria-hidden":"true",children:_.jsx("path",{d:"M2 5l2.5 2.5L8 3",stroke:"#22c55e",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}):_.jsx("span",{className:"w-4 h-4 rounded-full bg-red-500/15 flex-shrink-0 flex items-center justify-center",children:_.jsx("svg",{width:"10",height:"10",viewBox:"0 0 10 10",fill:"none","aria-hidden":"true",children:_.jsx("path",{d:"M3 3l4 4M7 3l-4 4",stroke:"#ef4444",strokeWidth:"1.5",strokeLinecap:"round"})})})}function Ewe({session:r}){if(!r)return _.jsx("div",{className:"bg-card border border-border rounded-xl flex items-center justify-center min-h-[120px]",children:_.jsx("p",{className:"text-[13px] text-muted-foreground",children:"세션을 선택하세요"})});const e=r.tasks.length>0?"태스크":"출력";return _.jsxs("div",{className:"bg-card border border-border rounded-xl overflow-hidden",children:[_.jsxs("div",{className:"px-4 py-2.5 border-b border-border flex items-center gap-2",children:[_.jsx("span",{className:"text-[11px] font-semibold text-muted-foreground uppercase tracking-wide",children:e}),_.jsx("span",{className:"font-mono text-[11px] text-foreground/70 truncate",children:r.command.replace(/^sppt\s+/,"")})]}),r.tasks.length>0?_.jsx("ul",{className:"divide-y divide-border",children:r.tasks.map(t=>_.jsxs("li",{className:"flex items-center gap-3 px-4 py-2.5",children:[_.jsx(Rwe,{status:t.status}),_.jsx("span",{className:"text-[12px] flex-1 truncate",children:t.name}),t.detail&&_.jsx("span",{className:"text-[11px] text-muted-foreground truncate max-w-[120px]",children:t.detail}),t.startedAt&&_.jsx("span",{className:"text-[10px] text-muted-foreground flex-shrink-0",children:Lwe(t)})]},t.id))}):r.output?_.jsx("pre",{className:"px-4 py-3 text-[12px] leading-relaxed text-foreground/80 whitespace-pre-wrap font-mono overflow-x-auto",children:r.output}):_.jsx("div",{className:"flex items-center justify-center py-8",children:_.jsx("p",{className:"text-[12px] text-muted-foreground",children:"출력 없음"})})]})}function kwe({sessions:r,selectedId:e,onSelect:t}){return r.length===0?_.jsx("div",{className:"bg-card border border-border rounded-xl flex items-center justify-center p-4",children:_.jsxs("p",{className:"text-[12px] text-muted-foreground text-center",children:["CLI 커맨드를 실행하면",_.jsx("br",{}),"여기에 표시됩니다"]})}):_.jsxs("div",{className:"bg-card border border-border rounded-xl overflow-hidden flex flex-col max-h-[70vh]",children:[_.jsx("div",{className:"px-3 py-2 border-b border-border flex-shrink-0",children:_.jsx("span",{className:"text-[11px] font-semibold text-muted-foreground uppercase tracking-wide",children:"세션"})}),_.jsx("ul",{className:"overflow-y-auto flex-1",children:r.map(n=>{const a=n.tasks.filter(u=>u.status==="completed").length,i=n.tasks.length,o=n.tasks.some(u=>u.status==="running"),s=n.id===e,l=UM(new Date(n.createdAt),{addSuffix:!0,locale:F1});return _.jsx("li",{children:_.jsxs("button",{type:"button",onClick:()=>t(n.id),className:["w-full text-left pl-2 pr-3 py-2.5 hover:bg-muted/60 transition-colors border-b border-border last:border-b-0",s?"bg-muted":""].join(" "),children:[_.jsxs("div",{className:"flex items-center gap-1.5 mb-1",children:[_.jsx("span",{className:["w-1.5 h-1.5 rounded-full flex-shrink-0",o?"bg-green-500 animate-pulse":"bg-muted-foreground/40"].join(" ")}),_.jsx("span",{className:"text-[12px] font-medium truncate flex-1 font-mono",children:n.command.replace(/^sppt\s+/,"")})]}),_.jsxs("div",{className:"flex items-center justify-between pl-2",children:[_.jsx("span",{className:"text-[11px] text-muted-foreground",children:i>0?`${a}/${i} 완료`:"태스크 없음"}),_.jsx("span",{className:"text-[10px] text-muted-foreground",children:l})]})]})},n.id)})})]})}function Iwe(){const r=window.location.hash.slice(1),e=r.includes("?")?r.split("?")[1]:"";return new URLSearchParams(e).get("id")}function Owe(){const{data:r=[]}=Zq(),[e,t]=q.useState(Iwe),n=q.useCallback(i=>{t(i);const o=window.location.hash.split("?")[0];window.history.replaceState(null,"",`${o}?id=${i}`)},[]);q.useEffect(()=>{r.length>0&&!e&&n(r[0].id)},[r,e,n]);const a=r.find(i=>i.id===e)??null;return _.jsxs("div",{children:[_.jsx("div",{className:"flex items-center justify-between mb-6",children:_.jsx("h2",{className:"text-xl font-medium",children:"Session"})}),_.jsxs("div",{className:"grid grid-cols-[260px_1fr] gap-4 mb-8",children:[_.jsx(kwe,{sessions:r,selectedId:e,onSelect:n}),_.jsx(Ewe,{session:a})]})]})}function Ii({content:r,size:e=10,side:t,contentClassName:n}){return _.jsx(Bo,{content:r,side:t,contentClassName:n,children:_.jsx("span",{className:"cursor-help text-muted-foreground inline-flex items-center",children:_.jsx(eG,{size:e})})})}function DL({channel:r}){return _.jsx("span",{className:Ae("inline-block w-2 h-2 rounded-full shrink-0",AQ[r]??"bg-muted-foreground")})}function Pwe(r){return r==null?"무제한":r>=1e8?`${(r/1e8).toFixed(0)}억원 미만`:r>=1e7?`${(r/1e7).toFixed(0)}천만원 미만`:`${r.toLocaleString()}원 미만`}function LT({url:r}){return r?_.jsxs("a",{href:r,target:"_blank",rel:"noopener noreferrer",className:"ml-1 inline-flex items-center gap-0.5 text-[9px] opacity-50 hover:opacity-100 transition-opacity",onClick:e=>e.stopPropagation(),children:[_.jsx(kg,{size:8}),"출처"]}):null}function np({children:r}){return _.jsx("span",{className:"inline-flex items-center text-[10px] font-medium bg-muted text-muted-foreground px-1.5 py-0.5 rounded-full",children:r})}function Cg(r,e){if(!(r!=null&&r.length)||e==null)return null;const t=r.findIndex(n=>n.maxAnnualRevenue==null||e<=n.maxAnnualRevenue);return t>=0?t:r.length-1}function jwe({d:r,annualRevenue:e,channel:t}){var T,C,D,M,N,R,E,k,I,B,P,H;const[n,a]=q.useState(!1),[i,o]=q.useState(!1),[s,l]=q.useState(!1),[u,c]=q.useState(!1),[f,d]=q.useState(!1),v=r.categoryRates&&Object.keys(r.categoryRates).length>0,g=r.pgRateByPayment&&Object.keys(r.pgRateByPayment).length>0,y=r.revenueTiers&&r.revenueTiers.length>0,x=r.verticalRates&&Object.keys(r.verticalRates).length>0,b=r.discrepancyHints&&r.discrepancyHints.length>0,w=r.sources&&r.sources.length>0;return!v&&!g&&!y&&!x&&!b&&!w?null:_.jsx("tr",{className:"border-b border-border/40 bg-muted/5",children:_.jsx("td",{colSpan:7,className:"px-3 pb-3 pt-0",children:_.jsxs("div",{className:"flex flex-wrap gap-3 mt-2",children:[v&&_.jsxs("div",{className:"w-full",children:[_.jsxs("button",{type:"button",onClick:()=>a(V=>!V),className:"flex items-center gap-1 text-[11px] text-muted-foreground hover:text-foreground transition-colors",children:[n?_.jsx(Sn,{size:11}):_.jsx(Pn,{size:11}),_.jsx("span",{className:"font-medium text-foreground/70",children:"카테고리별 수수료"}),_.jsxs(np,{children:[Object.keys(r.categoryRates??{}).length,"개"]})]}),n&&_.jsx("div",{className:"mt-1.5 ml-4 border border-border/60 rounded overflow-hidden",children:_.jsxs("table",{className:"w-full text-[11px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"bg-muted/50 text-muted-foreground",children:[_.jsx("th",{className:"px-2 py-1 text-left font-medium",children:"카테고리"}),_.jsx("th",{className:"px-2 py-1 text-right font-medium",children:"수수료율"})]})}),_.jsx("tbody",{children:Object.entries(r.categoryRates??{}).sort((V,j)=>V[1]-j[1]).map(([V,j])=>_.jsxs("tr",{className:"border-t border-border/40",children:[_.jsx("td",{className:"px-2 py-1",children:V}),_.jsxs("td",{className:"px-2 py-1 text-right font-medium",children:[j,"%"]})]},V))})]})})]}),g&&_.jsxs("div",{className:"w-full",children:[_.jsxs("button",{type:"button",onClick:()=>o(V=>!V),className:"flex items-center gap-1 text-[11px] text-muted-foreground hover:text-foreground transition-colors",children:[i?_.jsx(Sn,{size:11}):_.jsx(Pn,{size:11}),_.jsx("span",{className:"font-medium text-foreground/70",children:"결제수단별 PG 수수료"}),_.jsxs(np,{children:[Object.keys(r.pgRateByPayment??{}).length,"종"]})]}),i&&_.jsx("div",{className:"mt-1.5 ml-4 border border-border/60 rounded overflow-hidden",children:_.jsxs("table",{className:"w-full text-[11px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"bg-muted/50 text-muted-foreground",children:[_.jsx("th",{className:"px-2 py-1 text-left font-medium",children:"결제수단"}),_.jsx("th",{className:"px-2 py-1 text-right font-medium",children:"수수료율"})]})}),_.jsx("tbody",{children:Object.entries(r.pgRateByPayment??{}).map(([V,j])=>_.jsxs("tr",{className:"border-t border-border/40",children:[_.jsx("td",{className:"px-2 py-1",children:j.label}),_.jsxs("td",{className:"px-2 py-1 text-right font-medium",children:[j.rate,"%"]})]},V))})]})})]}),y&&_.jsxs("div",{className:"w-full",children:[_.jsxs("button",{type:"button",onClick:()=>l(V=>!V),className:"flex items-center gap-1 text-[11px] text-muted-foreground hover:text-foreground transition-colors",children:[s?_.jsx(Sn,{size:11}):_.jsx(Pn,{size:11}),_.jsx("span",{className:"font-medium text-foreground/70",children:"매출 등급별 수수료"}),_.jsxs(np,{children:[(T=r.revenueTiers)==null?void 0:T.length,"구간"]}),(()=>{var U;const V=Cg(r.revenueTiers,e),j=V!=null?(U=r.revenueTiers)==null?void 0:U[V]:null;return j?_.jsxs("span",{className:"inline-flex items-center text-[10px] font-medium bg-emerald-100 text-emerald-700 dark:bg-emerald-950/50 dark:text-emerald-400 px-1.5 py-0.5 rounded-full ml-1",children:["현재 ",j.label]}):_.jsx("span",{className:"inline-flex items-center text-[10px] text-amber-500 px-1 ml-1",children:"연매출 미설정"})})()]}),s&&_.jsxs("div",{className:"mt-1.5 ml-4 border border-border/60 rounded overflow-hidden",children:[_.jsxs("table",{className:"w-full text-[11px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"bg-muted/50 text-muted-foreground",children:[_.jsx("th",{className:"px-2 py-1 text-left font-medium",children:"등급"}),_.jsx("th",{className:"px-2 py-1 text-left font-medium",children:"연매출 기준"}),((C=r.revenueTiers)==null?void 0:C.some(V=>V.pgRate!=null))&&_.jsx("th",{className:"px-2 py-1 text-right font-medium",children:"PG수수료"}),((D=r.revenueTiers)==null?void 0:D.some(V=>V.commissionRate!=null))&&_.jsx("th",{className:"px-2 py-1 text-right font-medium",children:"판매수수료"}),_.jsx("th",{className:"px-2 py-1 text-right font-medium",children:"적용"})]})}),_.jsx("tbody",{children:(M=r.revenueTiers)==null?void 0:M.map((V,j)=>{var X,G;const F=Cg(r.revenueTiers,e)===j;return _.jsxs("tr",{className:Ae("border-t border-border/40",F&&"bg-emerald-50 dark:bg-emerald-950/30"),children:[_.jsx("td",{className:Ae("px-2 py-1 font-medium",F&&"text-emerald-700 dark:text-emerald-400"),children:V.label}),_.jsx("td",{className:"px-2 py-1 text-muted-foreground",children:Pwe(V.maxAnnualRevenue)}),((X=r.revenueTiers)==null?void 0:X.some(W=>W.pgRate!=null))&&_.jsx("td",{className:Ae("px-2 py-1 text-right",F&&"font-semibold text-emerald-700 dark:text-emerald-400"),children:V.pgRate!=null?`${V.pgRate}%`:"-"}),((G=r.revenueTiers)==null?void 0:G.some(W=>W.commissionRate!=null))&&_.jsx("td",{className:Ae("px-2 py-1 text-right",F&&"font-semibold text-emerald-700 dark:text-emerald-400"),children:V.commissionRate!=null?`${V.commissionRate}%`:"-"}),_.jsx("td",{className:"px-2 py-1 text-right",children:F?_.jsx("span",{className:"text-emerald-600 dark:text-emerald-400 font-medium",children:"◀ 현재"}):null})]},V.label)})})]}),e==null&&_.jsxs("div",{className:"px-2 py-1.5 bg-amber-50/50 dark:bg-amber-950/20 border-t border-amber-200/50 dark:border-amber-900/50 text-[10px] text-amber-700 dark:text-amber-400",children:["연매출을 설정하면 현재 적용 등급을 확인할 수 있습니다."," ",_.jsx("button",{type:"button",onClick:()=>vx({type:"annualRevenue"}),className:"underline underline-offset-2 hover:text-foreground transition-colors",children:"연 매출 설정→"})]})]})]}),x&&_.jsxs("div",{className:"w-full",children:[_.jsxs("button",{type:"button",onClick:()=>c(V=>!V),className:"flex items-center gap-1 text-[11px] text-muted-foreground hover:text-foreground transition-colors",children:[u?_.jsx(Sn,{size:11}):_.jsx(Pn,{size:11}),_.jsx("span",{className:"font-medium text-foreground/70",children:"버티컬/솔루션 추가 수수료"}),_.jsxs(np,{children:[Object.keys(r.verticalRates??{}).length,"종"]})]}),u&&_.jsxs("div",{className:"mt-1.5 ml-4 border border-border/60 rounded overflow-hidden",children:[_.jsxs("table",{className:"w-full text-[11px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"bg-muted/50 text-muted-foreground",children:[_.jsx("th",{className:"px-2 py-1 text-left font-medium",children:"서비스"}),_.jsx("th",{className:"px-2 py-1 text-right font-medium",children:"추가 수수료율"}),_.jsx("th",{className:"px-2 py-1 text-left font-medium",children:"비고"})]})}),_.jsx("tbody",{children:Object.entries(r.verticalRates??{}).map(([V,j])=>_.jsxs("tr",{className:"border-t border-border/40",children:[_.jsx("td",{className:"px-2 py-1 font-medium",children:V}),_.jsxs("td",{className:"px-2 py-1 text-right text-red-500",children:["+",j.rate,"%"]}),_.jsx("td",{className:"px-2 py-1 text-muted-foreground",children:j.label})]},V))})]}),_.jsx("div",{className:"px-2 py-1.5 bg-muted/30 text-[10px] text-muted-foreground border-t border-border/40",children:"판매수수료에 중복 부과됩니다. 쇼핑라이브·렌탈 등 해당 서비스 이용 시만 적용."})]})]}),b&&_.jsxs("div",{className:"w-full",children:[_.jsxs("button",{type:"button",onClick:()=>d(V=>!V),className:"flex items-center gap-1 text-[11px] text-amber-600 dark:text-amber-400 hover:text-foreground transition-colors",children:[f?_.jsx(Sn,{size:11}):_.jsx(Pn,{size:11}),_.jsx("span",{className:"font-medium",children:"실정산 차이 발생 가능 원인"}),_.jsxs(np,{children:[(N=r.discrepancyHints)==null?void 0:N.length,"가지"]})]}),f&&_.jsxs("div",{className:"mt-1.5 ml-4 space-y-1.5",children:[((R=r.discrepancyHints)==null?void 0:R.some(V=>V.type==="fix"))&&_.jsxs("div",{className:"border border-emerald-200 dark:border-emerald-900/60 rounded bg-emerald-50/50 dark:bg-emerald-950/20 p-2",children:[_.jsx("p",{className:"text-[9px] font-semibold text-emerald-700 dark:text-emerald-400 uppercase tracking-wide mb-1",children:"설정으로 개선 가능"}),_.jsx("ul",{className:"space-y-1",children:(E=r.discrepancyHints)==null?void 0:E.filter(V=>V.type==="fix").map(V=>_.jsxs("li",{className:"text-[10px] text-emerald-800 dark:text-emerald-300 flex items-start gap-1.5",children:[_.jsx("span",{className:"shrink-0 mt-0.5",children:"✓"}),_.jsxs("span",{children:[V.text,V.configHref&&_.jsx("button",{type:"button",onClick:()=>{const j=V.text.includes("annualRevenue");vx(j?{type:"annualRevenue"}:{type:"channel",channel:t??""})},className:"ml-1.5 underline underline-offset-2 text-emerald-600 dark:text-emerald-400 hover:text-foreground transition-colors",children:"설정 →"}),_.jsx(LT,{url:V.source})]})]},V.text))})]}),((k=r.discrepancyHints)==null?void 0:k.some(V=>V.type==="auto"))&&_.jsxs("div",{className:"border border-blue-200 dark:border-blue-900/60 rounded bg-blue-50/50 dark:bg-blue-950/20 p-2",children:[_.jsx("p",{className:"text-[9px] font-semibold text-blue-700 dark:text-blue-400 uppercase tracking-wide mb-1",children:"데이터 수집 시 자동 처리"}),_.jsx("ul",{className:"space-y-1",children:(I=r.discrepancyHints)==null?void 0:I.filter(V=>V.type==="auto").map(V=>_.jsxs("li",{className:"text-[10px] text-blue-800 dark:text-blue-300 flex items-start gap-1.5",children:[_.jsx("span",{className:"shrink-0 mt-0.5",children:"↻"}),_.jsxs("span",{children:[V.text,_.jsx(LT,{url:V.source})]})]},V.text))})]}),((B=r.discrepancyHints)==null?void 0:B.some(V=>V.type==="info"))&&_.jsxs("div",{className:"border border-amber-200 dark:border-amber-900/60 rounded bg-amber-50/50 dark:bg-amber-950/20 p-2",children:[_.jsx("p",{className:"text-[9px] font-semibold text-amber-600 dark:text-amber-500 uppercase tracking-wide mb-1",children:"계산 범위 밖 참고 항목"}),_.jsx("ul",{className:"space-y-1",children:(P=r.discrepancyHints)==null?void 0:P.filter(V=>V.type==="info").map(V=>_.jsxs("li",{className:"text-[10px] text-amber-700 dark:text-amber-400 flex gap-1.5",children:[_.jsx("span",{className:"shrink-0 mt-0.5",children:"·"}),_.jsxs("span",{children:[V.text,_.jsx(LT,{url:V.source})]})]},V.text))})]})]})]}),w&&_.jsxs("div",{className:"flex flex-wrap gap-2 pt-0.5 border-t border-border/30 w-full",children:[_.jsx("span",{className:"text-[10px] text-muted-foreground/50 self-center",children:"출처"}),(H=r.sources)==null?void 0:H.map(V=>{const j=new URL(V).hostname.replace(/^www\./,"");return _.jsxs("a",{href:V,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-0.5 text-[10px] text-muted-foreground/70 hover:text-foreground transition-colors underline underline-offset-2",children:[_.jsx(kg,{size:9}),j]},V)})]})]})})})}function _t(r){return r==null?"-":`${Math.round(r).toLocaleString()}원`}const Ff=10;function zwe({channel:r,dateFrom:e,dateTo:t}){const[n,a]=q.useState(0),{data:i,isLoading:o}=wM({channel:r,from:e,to:t,limit:"500"}),s=(i==null?void 0:i.orders)??[],l=Math.max(1,Math.ceil(s.length/Ff)),u=s.slice(n*Ff,(n+1)*Ff);return _.jsxs("div",{className:"bg-muted/10 border-t border-border/30 px-4 py-3 space-y-2",children:[_.jsxs("div",{className:"flex items-center justify-between",children:[_.jsx("span",{className:"text-[12px] font-semibold",children:"주문내역"}),_.jsxs("div",{className:"flex items-center gap-3",children:[s.length>Ff&&_.jsxs("div",{className:"flex items-center gap-1",children:[_.jsx("button",{type:"button",onClick:()=>a(c=>Math.max(0,c-1)),disabled:n===0,className:"px-2 py-1 text-[11px] border border-border rounded hover:bg-muted/50 disabled:opacity-30 disabled:cursor-not-allowed transition-colors",children:"←"}),_.jsxs("span",{className:"text-[11px] text-muted-foreground px-1",children:[n*Ff+1,"–",Math.min((n+1)*Ff,s.length)," /"," ",s.length,"건"]}),_.jsx("button",{type:"button",onClick:()=>a(c=>Math.min(l-1,c+1)),disabled:n>=l-1,className:"px-2 py-1 text-[11px] border border-border rounded hover:bg-muted/50 disabled:opacity-30 disabled:cursor-not-allowed transition-colors",children:"→"})]}),_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:[e," ~ ",t," · 총 ",s.length,"건"]})]})]}),o?_.jsx("div",{className:"text-[12px] text-muted-foreground py-3 text-center",children:"불러오는 중…"}):u.length===0?_.jsx("div",{className:"text-[12px] text-muted-foreground py-2",children:"해당 기간 주문 없음"}):_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"주문일"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"주문번호"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"상품명"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"판매가"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"상태"})]})}),_.jsx("tbody",{className:"bg-card divide-y divide-border/50",children:u.map((c,f)=>{var d;return _.jsxs("tr",{className:Ae(f%2!==0&&"bg-muted/20"),children:[_.jsx("td",{className:"px-3 py-2 text-muted-foreground",children:((d=c.orderDate)==null?void 0:d.slice(0,10))??"-"}),_.jsx("td",{className:"px-3 py-2 font-mono text-[11px] text-muted-foreground",children:c.channelOrderId.slice(-10)}),_.jsx("td",{className:"px-3 py-2 max-w-[200px] truncate",children:c.productName}),_.jsx("td",{className:"px-3 py-2 text-right font-medium",children:c.salePrice!=null?_t(c.salePrice*c.quantity):"-"}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground text-[11px]",children:c.status})]},c.channelOrderId)})})]})})]})}function Bwe({data:r,isLoading:e}){if(e)return _.jsx("div",{className:"text-[12px] text-muted-foreground py-4",children:"조회 중…"});if(!r)return null;const t=Array.isArray(r)?r:r.data??[];return t.length?_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"매출인식월"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"정산대상금액"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"서비스수수료"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"공제금액"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"최종 정산금액"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"정산예정일"})]})}),_.jsx("tbody",{className:"bg-card divide-y divide-border/50",children:t.map((n,a)=>_.jsxs("tr",{className:Ae(a%2!==0&&"bg-muted/20"),children:[_.jsx("td",{className:"px-3 py-2 font-medium",children:n.revenueRecognitionMonth??"-"}),_.jsx("td",{className:"px-3 py-2 text-right",children:_t(n.settlementTargetAmount)}),_.jsx("td",{className:"px-3 py-2 text-right text-red-600 dark:text-red-400",children:n.serviceFee!=null?_t(Math.abs(n.serviceFee)):"-"}),_.jsx("td",{className:"px-3 py-2 text-right text-muted-foreground",children:n.deductionAmount!=null?_t(Math.abs(n.deductionAmount)):"-"}),_.jsx("td",{className:"px-3 py-2 text-right font-medium text-emerald-600 dark:text-emerald-400",children:_t(n.finalSettlementAmount)}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground",children:n.settlementDate??n.finalSettlementDate??"-"})]},a))})]})}):_.jsx("div",{className:"text-[12px] text-muted-foreground py-2",children:"해당 월 정산 내역 없음"})}function Vwe({data:r,isLoading:e}){if(e)return _.jsx("div",{className:"text-[12px] text-muted-foreground py-4",children:"조회 중… (매출인식일별 조회로 시간이 걸릴 수 있습니다)"});if(!r)return null;const{items:t,totalActual:n,totalPredicted:a,totalDiff:i,accuracy:o,scannedDates:s}=r;if(!t.length)return _.jsx("div",{className:"text-[12px] text-muted-foreground py-2",children:"해당 기간 매출인식 데이터 없음 — 구매확정 주문이 있는지 확인하세요"});const l=o>=99?"text-emerald-600 dark:text-emerald-400":o>=95?"text-amber-600":"text-red-600";return _.jsxs("div",{className:"space-y-2",children:[_.jsxs("div",{className:"grid grid-cols-3 gap-2",children:[_.jsx(Jr,{label:"실 정산 합계",value:_t(n)}),_.jsx(Jr,{label:"예상 정산 합계",value:_t(a)}),_.jsx(Jr,{label:"예측 정확도",value:`${o.toFixed(1)}%`,sub:i!==0?`실정산이 예상보다 ${i>0?"+":""}${_t(i)}`:"완전 일치",accent:o>=99})]}),_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"주문번호"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"상품명"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"결제금액"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"실정산"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"예상정산"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"차이"})]})}),_.jsx("tbody",{className:"bg-card divide-y divide-border/50",children:t.map((u,c)=>_.jsxs("tr",{className:Ae(c%2!==0&&"bg-muted/20"),children:[_.jsx("td",{className:"px-3 py-2 font-mono text-[11px] text-muted-foreground",children:u.orderId.slice(-10)}),_.jsx("td",{className:"px-3 py-2 max-w-[180px] truncate",children:u.productName}),_.jsx("td",{className:"px-3 py-2 text-right",children:_t(u.gross)}),_.jsx("td",{className:"px-3 py-2 text-right font-medium",children:_t(u.actual)}),_.jsx("td",{className:"px-3 py-2 text-right text-muted-foreground",children:_t(u.predicted)}),_.jsxs("td",{className:Ae("px-3 py-2 text-right",Math.abs(u.diff)>500?"text-amber-600 font-medium":"text-muted-foreground"),children:[u.diff>=0?"+":"",_t(u.diff)]})]},c))})]})}),_.jsxs("p",{className:Ae("text-[11px]",l),children:["예측 정확도 ",o.toFixed(1),"% · ",s,"개 매출인식일 조회"]})]})}function Gwe({dateFrom:r,dateTo:e}){const t=(r||new Date().toISOString()).slice(0,7),[n,a]=q.useState(t),[i,o]=q.useState("monthly"),{data:s,isLoading:l}=rZ(n,i==="monthly"),{data:u,isLoading:c}=nZ(r,e,i==="reconcile");return _.jsxs("div",{className:"bg-muted/10 border-t border-border/30 px-4 py-4 space-y-3",children:[_.jsxs("div",{className:"flex items-center justify-between",children:[_.jsx("span",{className:"text-[12px] font-semibold",children:"쿠팡 실정산"}),_.jsx("span",{className:"text-[11px] text-muted-foreground",children:"쿠팡 Wing API 직접 조회"})]}),_.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[_.jsx("div",{className:"flex rounded border border-border overflow-hidden text-[11px]",children:["monthly","reconcile"].map(f=>_.jsx("button",{type:"button",onClick:()=>o(f),className:Ae("px-3 py-1 transition-colors",i===f?"bg-primary text-primary-foreground":"hover:bg-muted/50 text-muted-foreground"),children:f==="monthly"?"월별 정산":"예상 비교"},f))}),i==="monthly"&&_.jsx("input",{type:"month",value:n,onChange:f=>a(f.target.value),className:"h-7 px-2 border border-border rounded bg-background text-[12px] focus:outline-none focus:ring-1 focus:ring-primary/50"}),i==="reconcile"&&_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:[r," ~ ",e," 기간 조회"]})]}),i==="monthly"&&_.jsx(Bwe,{data:s,isLoading:l}),i==="reconcile"&&_.jsx(Vwe,{data:u,isLoading:c})]})}function Hwe({order:r}){var o;const e=((o=r.orderDate)==null?void 0:o.slice(0,10))??"",t=r.channelOrderId??"",{data:n,isLoading:a}=tZ(t,e),i=(n==null?void 0:n.elements)??[];return a?_.jsx("div",{className:"text-[11px] text-muted-foreground py-2 pl-4",children:"건별 정산 조회 중…"}):i.length?_.jsx("div",{className:"border-t border-border/40 bg-muted/10",children:_.jsxs("table",{className:"w-full text-[11px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"text-[10px] text-muted-foreground/70",children:[_.jsx("th",{className:"px-4 py-1 text-left",children:"상품주문번호"}),_.jsx("th",{className:"px-3 py-1 text-left",children:"상품명"}),_.jsx("th",{className:"px-3 py-1 text-right",children:"결제금액"}),_.jsx("th",{className:"px-3 py-1 text-right",children:"수수료"}),_.jsx("th",{className:"px-3 py-1 text-right",children:"실수령"}),_.jsx("th",{className:"px-3 py-1 text-left",children:"정산완료일"})]})}),_.jsx("tbody",{children:i.map((s,l)=>{var u;return _.jsxs("tr",{className:Ae(l%2!==0&&"bg-muted/20"),children:[_.jsx("td",{className:"px-4 py-1 font-mono text-[10px] text-muted-foreground",children:((u=s.productOrderId)==null?void 0:u.slice(-10))??"-"}),_.jsx("td",{className:"px-3 py-1 max-w-[160px] truncate text-muted-foreground",children:s.productName??"-"}),_.jsx("td",{className:"px-3 py-1 text-right",children:_t(s.paySettleAmount)}),_.jsx("td",{className:"px-3 py-1 text-right text-red-600 dark:text-red-400",children:s.totalPayCommissionAmount!=null?_t(Math.abs(s.totalPayCommissionAmount)):"-"}),_.jsx("td",{className:"px-3 py-1 text-right text-emerald-600 dark:text-emerald-400 font-medium",children:_t(s.settleExpectAmount)}),_.jsx("td",{className:"px-3 py-1 text-muted-foreground",children:s.settleCompleteDate??"-"})]},l)})})]})}):_.jsx("div",{className:"text-[11px] text-muted-foreground py-2 pl-4",children:"건별 정산 내역 없음"})}const Uf=10;function Fwe({dateFrom:r,dateTo:e}){const[t,n]=q.useState(new Set),[a,i]=q.useState(0),{data:o,isLoading:s}=wM({channel:"smartstore",from:r,to:e,limit:"500"}),l=(o==null?void 0:o.orders)??[],u=Math.max(1,Math.ceil(l.length/Uf)),c=l.slice(a*Uf,(a+1)*Uf);function f(d){n(v=>{const g=new Set(v);return g.has(d)?g.delete(d):g.add(d),g})}return _.jsxs("div",{className:"bg-muted/10 border-t border-border/30 px-4 py-3 space-y-2",children:[_.jsxs("div",{className:"flex items-center justify-between",children:[_.jsx("span",{className:"text-[12px] font-semibold",children:"주문내역 (클릭 시 실정산내역)"}),_.jsxs("div",{className:"flex items-center gap-3",children:[l.length>Uf&&_.jsxs("div",{className:"flex items-center gap-1",children:[_.jsx("button",{type:"button",onClick:()=>{i(d=>Math.max(0,d-1)),n(new Set)},disabled:a===0,className:"px-2 py-1 text-[11px] border border-border rounded hover:bg-muted/50 disabled:opacity-30 disabled:cursor-not-allowed transition-colors",children:"←"}),_.jsxs("span",{className:"text-[11px] text-muted-foreground px-1",children:[a*Uf+1,"–",Math.min((a+1)*Uf,l.length)," /"," ",l.length,"건"]}),_.jsx("button",{type:"button",onClick:()=>{i(d=>Math.min(u-1,d+1)),n(new Set)},disabled:a>=u-1,className:"px-2 py-1 text-[11px] border border-border rounded hover:bg-muted/50 disabled:opacity-30 disabled:cursor-not-allowed transition-colors",children:"→"})]}),_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:[r," ~ ",e," · 총 ",l.length,"건"]})]})]}),s?_.jsx("div",{className:"text-[12px] text-muted-foreground py-3 text-center",children:"불러오는 중…"}):c.length===0?_.jsx("div",{className:"text-[12px] text-muted-foreground py-2",children:"해당 기간 주문 없음"}):_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px]",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"주문일"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"주문번호"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"상품명"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"판매가"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"상태"})]})}),_.jsx("tbody",{className:"bg-card divide-y divide-border/50",children:c.map((d,v)=>{var x;const g=d.channelOrderId,y=t.has(g);return _.jsxs(q.Fragment,{children:[_.jsxs("tr",{className:Ae(v%2!==0&&"bg-muted/20","cursor-pointer hover:bg-muted/30 transition-colors"),onClick:()=>f(g),onKeyDown:b=>{(b.key==="Enter"||b.key===" ")&&f(g)},tabIndex:0,children:[_.jsx("td",{className:"px-3 py-2 text-muted-foreground",children:((x=d.orderDate)==null?void 0:x.slice(0,10))??"-"}),_.jsx("td",{className:"px-3 py-2 font-mono text-[11px] text-muted-foreground",children:_.jsxs("span",{className:"inline-flex items-center gap-1",children:[y?_.jsx(Sn,{size:11,className:"shrink-0"}):_.jsx(Pn,{size:11,className:"shrink-0"}),g.slice(-10)]})}),_.jsx("td",{className:"px-3 py-2 max-w-[200px] truncate",children:d.productName}),_.jsx("td",{className:"px-3 py-2 text-right font-medium",children:d.salePrice!=null?_t(d.salePrice*d.quantity):"-"}),_.jsx("td",{className:"px-3 py-2 text-muted-foreground text-[11px]",children:d.status})]}),y&&_.jsx("tr",{children:_.jsx("td",{colSpan:5,className:"p-0",children:_.jsx(Hwe,{order:d})})})]},g)})})]})})]})}function Uwe(r,e,t,n){var N,R;const a=r.avgCommissionRate;if(a==null)return null;const i=a>1?a:a*100,o=t[r.channel],s=o?o.commissionRate+o.pgRate:null,l=e.filter(E=>E.channel===r.channel),u=(o==null?void 0:o.discrepancyHints)??[],c=E=>({k:"text",v:E}),f=(E,k,I)=>({k:"row",label:E,value:k,accent:I}),d={k:"divider"},v=(E,k)=>({k:"section",v:E,accent:k}),g=E=>({k:"bullet",v:E}),y=(E,k)=>({k:"fixbullet",v:E,href:k}),x=u.filter(E=>E.type==="fix"),b=u.filter(E=>E.type==="auto"),w=u.filter(E=>E.type==="info");function T(E={fix:3,auto:2,info:2}){const k=[];if(x.length>0){k.push(v("설정으로 개선 가능","fix"));for(const I of x.slice(0,E.fix))k.push(y(I.text,I.configHref))}if(b.length>0){k.push(v("자동 처리","info"));for(const I of b.slice(0,E.auto))k.push(g(I.text))}if(w.length>0){k.push(v("참고 항목","info"));for(const I of w.slice(0,E.info))k.push(g(I.text))}return k}const C=l.find(E=>{const k=(E.commissionRate??0)+(E.pgRate??0);return Math.abs(k-i)<.5}),D=x.length>0||b.length>0||w.length>0;if(s!=null&&Math.abs(s-i)<.1){const E=Cg(o.revenueTiers,n),k=E!=null?(N=o.revenueTiers)==null?void 0:N[E]:null,I=(k==null?void 0:k.pgRate)??o.pgRate,B=o.commissionRate+I;return{method:"default",label:"채널 기본 요율 적용",lines:[c("실 정산 데이터 없음 — 추정값"),...o.commissionRate>0?[f("판매수수료",`${o.commissionRate}%`,"muted")]:[],...I>0?[f(`PG${k?` (${k.label})`:""}`,`${I}%`,"muted")]:[],f("합계",`${B.toFixed(2)}%`),...n==null&&((R=o.revenueTiers)!=null&&R.length)?[c("⚠ 연매출 미설정 — 일반 등급 기준")]:[],...D?[d,...T({fix:3,auto:2,info:2})]:[]]}}for(const E of l){const k=(E.commissionRate??0)+(E.pgRate??0);if(Math.abs(k-i)<.5)return{method:"custom_rule",label:"커스텀 규칙 적용",lines:[f("규칙 ID",E.id,"muted"),...E.commissionRate!=null?[f("판매수수료",`${E.commissionRate}%`)]:[],...E.pgRate!=null?[f("PG수수료",`${E.pgRate}%`)]:[],...E.note?[f("메모",E.note,"muted")]:[],...D?[d,...T({fix:2,auto:1,info:2})]:[]]}}const M=s!=null?i-s:null;return{method:"order_data",label:"주문 데이터 평균",lines:[c("주문별 수수료율의 평균값"),f("적용 요율",`${i.toFixed(2)}%`),...s!=null?[f("채널 기준",`${s.toFixed(2)}%`,"muted"),...M!=null&&Math.abs(M)>=.1?[f("차이",`${M>0?"+":""}${M.toFixed(2)}%p`,M>.5?"warn":M<-.5?"green":"muted")]:[],...C?[c(`커스텀 규칙 적용 중${C.note?` (${C.note})`:""}`)]:[]]:[],...D?[d,...T({fix:2,auto:1,info:2})]:[]]}}function Ywe(r){return r==null?"-":`${(r>1?r:r*100).toFixed(1)}%`}function Wwe({lines:r,channel:e}){return _.jsx("div",{className:"space-y-0.5",children:r.map((t,n)=>{const a=`${t.k}-${n}`;if(t.k==="divider")return _.jsx("div",{className:"border-t border-border/40 my-1"},a);if(t.k==="section")return _.jsx("p",{className:Ae("text-[9px] font-semibold uppercase tracking-wide pt-0.5",t.accent==="fix"?"text-emerald-600 dark:text-emerald-400":t.accent==="info"?"text-amber-600 dark:text-amber-400":"text-foreground/50"),children:t.v},a);if(t.k==="fixbullet")return _.jsxs("div",{className:"flex gap-1.5 text-[10px] leading-snug",children:[_.jsx("span",{className:"text-foreground/40 shrink-0 mt-px",children:"✓"}),_.jsxs("span",{children:[t.v,t.href&&_.jsx("button",{type:"button",onClick:()=>{const i=t.v.includes("annualRevenue");vx(i?{type:"annualRevenue"}:{type:"channel",channel:e??""})},className:"ml-1 text-emerald-600 dark:text-emerald-400 underline underline-offset-2 hover:opacity-80 transition-opacity",children:"설정→"})]})]},a);if(t.k==="bullet")return _.jsxs("div",{className:"flex gap-1.5 text-muted-foreground text-[10px] leading-snug",children:[_.jsx("span",{className:"text-foreground/40 shrink-0 mt-px",children:"•"}),_.jsx("span",{children:t.v})]},a);if(t.k==="row"){const i=t.accent==="muted"?"text-muted-foreground":t.accent==="green"?"text-emerald-500 tabular-nums":t.accent==="red"?"text-red-500 tabular-nums":t.accent==="warn"?"text-amber-500 tabular-nums":"tabular-nums";return _.jsxs("div",{className:"flex justify-between gap-4 text-[11px]",children:[_.jsx("span",{className:"text-muted-foreground shrink-0",children:t.label}),_.jsx("span",{className:i,children:t.value})]},a)}return _.jsx("p",{className:"text-muted-foreground text-[11px]",children:t.v},a)})})}function Xwe({channels:r,rules:e,defaults:t,annualRevenue:n,quickSettlement:a,totalRevenue:i,totalOrders:o,totalCommission:s,netRevenue:l,commissionRate:u,isLoading:c,ssDaily:f,dateFrom:d,dateTo:v}){var T;const[g,y]=q.useState(null),{data:x}=Xh(),b=((T=x==null?void 0:x.channels)==null?void 0:T.some(C=>C.channel==="coupang"&&C.connected))??!1,w=(()=>{const C=(f==null?void 0:f.elements)??[];if(!C.length)return null;const D=C.reduce((E,k)=>E+(k.paySettleAmount??0),0),M=C.reduce((E,k)=>E+(k.commissionSettleAmount??0),0),N=C.reduce((E,k)=>E+(k.settleAmount??0),0),R=D>0?Math.abs(M)/D*100:null;return{totalPay:D,totalComm:M,totalNet:N,rate:R}})();return c?_.jsx("div",{className:"text-sm text-muted-foreground py-6 text-center",children:"불러오는 중..."}):r.length===0?_.jsxs("div",{className:"border border-dashed border-border rounded-lg p-10 text-center text-muted-foreground text-sm",children:["정산 데이터가 없습니다.",_.jsxs("div",{className:"text-[11px] mt-1",children:[_.jsx("code",{className:"bg-muted px-1 rounded",children:"sppt import"}),"로 주문 데이터를 가져오거나 채널을 동기화하세요."]})]}):_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"채널"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"주문수"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"총 매출"}),_.jsx("th",{className:"px-3 py-2 text-right",children:_.jsxs("span",{className:"inline-flex items-center gap-1 justify-end",children:["수수료",_.jsx(Ii,{side:"top",content:_.jsxs("div",{className:"space-y-1",children:[_.jsx("p",{className:"font-medium",children:"수수료 계산 기준"}),_.jsx("p",{children:"채널별 수수료 정책 기반 추정"}),_.jsx("p",{className:"pl-2 text-muted-foreground",children:"커스텀 규칙 → 채널 기본 요율 순 적용"})]})})]})}),_.jsx("th",{className:"px-3 py-2 text-right",children:_.jsxs("span",{className:"inline-flex items-center gap-1 justify-end",children:["평균 수수료율",_.jsx(Ii,{side:"top",contentClassName:"max-w-[340px]",content:_.jsxs("div",{className:"space-y-2",children:[_.jsx("p",{className:"font-medium",children:"수수료율 결정 우선순위"}),_.jsxs("div",{className:"space-y-0.5 text-muted-foreground",children:[_.jsx("p",{children:"① 주문별 수수료율 데이터 평균"}),_.jsx("p",{className:"pl-3 text-[10px]",children:"채널 CSV에 수수료율 컬럼이 있을 때"}),_.jsx("p",{children:"② 커스텀 fee rule"}),_.jsx("p",{className:"pl-3 text-[10px]",children:"직접 설정한 규칙이 있을 때"}),_.jsx("p",{children:"③ 채널 기본 요율"}),_.jsx("p",{className:"pl-3 text-[10px]",children:"공식 자료 기반 기본값 (추정)"})]}),Object.keys(t).length>0&&_.jsxs(_.Fragment,{children:[_.jsxs("div",{className:"border-t border-border/40 pt-1.5",children:[_.jsxs("p",{className:"font-medium mb-0.5",children:["채널별 기본 수수료",n!=null?` (연매출 ${(n/1e8).toFixed(1)}억 기준)`:" (일반 등급 기준, 추정)"]}),n==null&&_.jsxs("p",{className:"text-[10px] text-amber-500 mb-1",children:["연매출 미설정 — 등급별 실제 요율과 다를 수 있음"," ",_.jsx("button",{type:"button",onClick:()=>vx({type:"annualRevenue"}),className:"underline underline-offset-2 hover:opacity-80",children:"설정→"})]}),_.jsx("div",{className:"space-y-0.5",children:Object.entries(t).map(([C,D])=>{var P;const M=Cg(D.revenueTiers,n),N=M!=null?(P=D.revenueTiers)==null?void 0:P[M]:null,R=(N==null?void 0:N.pgRate)??D.pgRate,E=D.commissionRate+R,k=e.some(H=>H.channel===C),I=e.find(H=>H.channel===C&&!H.from&&!H.to&&!H.paymentMethod&&!H.category),B=I?(I.commissionRate??0)+(I.pgRate??0):null;return _.jsxs("div",{className:"flex justify-between gap-4 text-[10px]",children:[_.jsx("span",{className:"text-muted-foreground",children:Dr[C]??C}),_.jsx("span",{children:I&&B!=null?_.jsxs("span",{className:"text-amber-400",children:[B.toFixed(1),"%"," ",_.jsxs("span",{className:"text-muted-foreground/50",children:["(기본 ",E.toFixed(1),"% ✎)"]})]}):k?_.jsxs("span",{className:Ae(N?"text-emerald-400":""),children:[E.toFixed(1),"%"," ",_.jsx("span",{className:"text-amber-400/70",children:"✎"})]}):_.jsxs("span",{className:N?"text-emerald-400":"",children:[E.toFixed(1),"%",N?` (${N.label})`:""]})})]},C)})}),_.jsx("p",{className:"text-[10px] text-muted-foreground/60 mt-1",children:"✎ 커스텀 규칙 · 초록 = 등급 적용"})]}),_.jsx("p",{className:"text-[10px] text-muted-foreground/60 border-t border-border/40 pt-1.5",children:"정확한 등급 요율 → 아래 '채널 기본 수수료 규칙' 펼치기"})]})]})})]})}),_.jsx("th",{className:"px-3 py-2 text-right",children:"실수령 예상"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"매출 비중"})]})}),_.jsx("tbody",{className:"bg-card",children:r.map((C,D)=>{var X;const M=C.channel==="smartstore",N=C.channel==="coupang",R=M?w:null,E=M?f==null?void 0:f.settleMeta:void 0,k=R?Math.abs(R.totalComm):C.totalCommission!=null?C.totalCommission:C.totalRevenue-(C.netRevenue??0),I=R?R.totalNet:C.netRevenue,B=(R==null?void 0:R.rate)??C.avgCommissionRate,P=M&&t.smartstore?(t.smartstore.commissionRate??0)+(t.smartstore.pgRate??0):null,H=(R==null?void 0:R.rate)!=null&&P!=null?R.rate-P:null,V=H!=null&&Math.abs(H)>.5,j=i>0?(C.totalRevenue/i*100).toFixed(1):"0",U=Uwe(C,e,t,n),F=g===C.channel;return _.jsxs(q.Fragment,{children:[_.jsxs("tr",{className:Ae("border-b border-border/60 cursor-pointer hover:bg-muted/20",D%2!==0&&"bg-muted/30"),onClick:()=>y(F?null:C.channel),onKeyDown:G=>{(G.key==="Enter"||G.key===" ")&&y(F?null:C.channel)},tabIndex:0,children:[_.jsx("td",{className:"px-3 py-2.5",children:_.jsxs("div",{className:"flex items-center gap-1.5 flex-wrap",children:[F?_.jsx(Sn,{size:12,className:"text-muted-foreground shrink-0"}):_.jsx(Pn,{size:12,className:"text-muted-foreground shrink-0"}),_.jsx(DL,{channel:C.channel}),Dr[C.channel]??C.channel,M&&R&&_.jsx("span",{className:"text-[10px] text-muted-foreground/60",children:"실정산"}),N&&b&&_.jsx("span",{className:"text-[10px] text-muted-foreground/60",children:"API 연동"}),C.channel==="smartstore"&&a&&_.jsx("span",{className:"inline-flex items-center text-[10px] font-medium bg-blue-100 text-blue-700 dark:bg-blue-950/50 dark:text-blue-400 px-1.5 py-0.5 rounded-full",children:"⚡ 빠른정산"})]})}),_.jsxs("td",{className:"px-3 py-2.5 text-right text-muted-foreground",children:[C.orderCount.toLocaleString(),"건"]}),_.jsx("td",{className:"px-3 py-2.5 text-right font-medium",children:_t(C.totalRevenue)}),_.jsx("td",{className:"px-3 py-2.5 text-right text-red-600 dark:text-red-400",children:_t(k)}),_.jsx("td",{className:"px-3 py-2.5 text-right text-muted-foreground",children:_.jsxs("span",{className:"inline-flex items-center gap-1 justify-end",onClick:G=>G.stopPropagation(),children:[Ywe(B),V&&_.jsx(Bo,{side:"left",contentClassName:"max-w-[300px]",content:_.jsxs("div",{className:"space-y-1.5",children:[_.jsx("p",{className:"font-medium text-[11px] text-amber-500",children:"수수료율 불일치"}),_.jsxs("div",{className:"space-y-0.5 text-[11px]",children:[_.jsxs("div",{className:"flex justify-between gap-4",children:[_.jsx("span",{className:"text-muted-foreground",children:"설정값"}),_.jsxs("span",{children:[P==null?void 0:P.toFixed(1),"%"]})]}),_.jsxs("div",{className:"flex justify-between gap-4",children:[_.jsx("span",{className:"text-muted-foreground",children:"실측"}),_.jsxs("span",{className:"text-amber-500",children:[(X=R==null?void 0:R.rate)==null?void 0:X.toFixed(1),"%"]})]}),_.jsxs("div",{className:"flex justify-between gap-4",children:[_.jsx("span",{className:"text-muted-foreground",children:"차이"}),_.jsxs("span",{className:"text-amber-500",children:[H!=null&&H>=0?"+":"",H==null?void 0:H.toFixed(1),"%p"]})]})]}),E&&_.jsx("div",{className:"border-t border-border/40 pt-1 text-[10px] text-muted-foreground/70",children:_.jsxs("p",{children:["📅 정산완료일 기준 · 주문일+",E.offsetDays.min,"~",E.offsetDays.max,"일 오프셋 적용"]})})]}),children:_.jsx("span",{className:"cursor-help inline-flex items-center",children:_.jsx(iG,{size:11,className:"text-amber-500"})})}),!V&&R&&E&&_.jsx(Ii,{side:"left",contentClassName:"max-w-[320px]",content:_.jsxs("div",{className:"space-y-1.5",children:[_.jsx("p",{className:"font-medium text-[11px]",children:"실정산 수수료율"}),_.jsxs("div",{className:"space-y-0.5 text-[11px]",children:[_.jsxs("div",{className:"flex justify-between gap-4",children:[_.jsx("span",{className:"text-muted-foreground",children:"결제 기준금액"}),_.jsx("span",{children:_t(R.totalPay)})]}),_.jsxs("div",{className:"flex justify-between gap-4",children:[_.jsx("span",{className:"text-muted-foreground",children:"수수료 합계"}),_.jsx("span",{className:"text-red-500",children:_t(Math.abs(R.totalComm))})]}),_.jsxs("div",{className:"flex justify-between gap-4",children:[_.jsx("span",{className:"text-muted-foreground",children:"실수령"}),_.jsx("span",{className:"text-emerald-500",children:_t(R.totalNet)})]})]}),_.jsxs("div",{className:"border-t border-border/40 pt-1 text-[10px] text-muted-foreground/70 space-y-1",children:[_.jsx("p",{className:"font-medium text-foreground/60",children:"조회 방식"}),_.jsxs("p",{children:["주문일(",E.orderFrom,"~",E.orderTo,")에 배송·구매확정 소요일(+",E.offsetDays.min,"~",E.offsetDays.max,"일)을 더해 정산완료일 범위로 조회합니다."]}),_.jsx("p",{children:"월 경계 주문은 실제 정산일과 다소 차이가 날 수 있습니다."}),_.jsx("p",{className:"text-foreground/50",children:"행 클릭 → 주문건별 정산 상세 확인 가능"})]})]})}),!R&&U&&_.jsx(Ii,{side:"left",contentClassName:"max-w-[300px]",content:_.jsxs("div",{className:"space-y-1.5",children:[_.jsx("p",{className:"font-medium text-[11px]",children:U.label}),_.jsx(Wwe,{lines:U.lines,channel:C.channel}),M&&_.jsxs("div",{className:"mt-1.5 pt-1.5 border-t border-border/40 text-[10px] text-muted-foreground/60 space-y-0.5",children:[_.jsx("p",{children:"현재 추정값입니다. 정산 데이터가 있는 기간 선택 시 네이버 실정산 기준으로 자동 교체됩니다."}),_.jsx("p",{children:"주문일에 배송·구매확정 소요일(+1~15일)을 더해 정산완료일 범위로 조회하며, 월 경계 주문은 다소 차이가 날 수 있습니다."}),_.jsx("p",{className:"text-foreground/40",children:"행 클릭 → 주문건별 정산 상세 확인 가능"})]})]})})]})}),_.jsx("td",{className:"px-3 py-2.5 text-right text-emerald-600 dark:text-emerald-400 font-medium",children:_t(I)}),_.jsx("td",{className:"px-3 py-2.5 text-right",children:_.jsxs("div",{className:"flex items-center justify-end gap-2",children:[_.jsx("div",{className:"w-[60px] bg-muted rounded-full h-1.5 overflow-hidden",children:_.jsx("div",{className:"h-full bg-primary/60 rounded-full",style:{width:`${j}%`}})}),_.jsxs("span",{className:"text-muted-foreground text-[11px] w-[32px] text-right",children:[j,"%"]})]})})]}),F&&_.jsx("tr",{className:"border-b border-border/60",children:_.jsx("td",{colSpan:7,className:"p-0",children:M?_.jsx(Fwe,{dateFrom:d||new Date(Date.now()-720*60*60*1e3).toISOString().slice(0,10),dateTo:v||new Date().toISOString().slice(0,10)}):N&&b?_.jsx(Gwe,{dateFrom:d||new Date(Date.now()-720*60*60*1e3).toISOString().slice(0,10),dateTo:v||new Date().toISOString().slice(0,10)}):_.jsx(zwe,{channel:C.channel,dateFrom:d||new Date(Date.now()-720*60*60*1e3).toISOString().slice(0,10),dateTo:v||new Date().toISOString().slice(0,10)})})})]},C.channel)})}),r.length>1&&_.jsx("tfoot",{children:_.jsxs("tr",{className:"border-t border-border bg-muted/30 text-[12px] font-semibold",children:[_.jsx("td",{className:"px-3 py-2.5",children:"합계"}),_.jsxs("td",{className:"px-3 py-2.5 text-right text-muted-foreground",children:[o.toLocaleString(),"건"]}),_.jsx("td",{className:"px-3 py-2.5 text-right",children:_t(i)}),_.jsx("td",{className:"px-3 py-2.5 text-right text-red-600 dark:text-red-400",children:_t(s)}),_.jsxs("td",{className:"px-3 py-2.5 text-right text-muted-foreground",children:[u.toFixed(1),"%"]}),_.jsx("td",{className:"px-3 py-2.5 text-right text-emerald-600 dark:text-emerald-400",children:_t(l)}),_.jsx("td",{})]})})]})})}function qwe({defaults:r,rules:e,annualRevenue:t,isLoading:n}){const a={ordered:"주문일",paid:"결제일",confirmed:"구매확정일"};return n?_.jsx("div",{className:"text-sm text-muted-foreground py-4 text-center",children:"불러오는 중..."}):_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"채널"}),_.jsx("th",{className:"px-3 py-2 text-right",children:_.jsxs("span",{className:"inline-flex items-center gap-1 justify-end",children:["판매수수료",_.jsx(Ii,{side:"top",content:_.jsx("p",{children:"네이버쇼핑·일반 유입 기준 요율. 마케팅 링크 유입 시 별도 요율 적용 (셀별 ℹ 확인)"})})]})}),_.jsx("th",{className:"px-3 py-2 text-right",children:"PG수수료"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"합계"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"정산 기준"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"정산 주기"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"커스텀 규칙"})]})}),_.jsx("tbody",{className:"bg-card",children:Object.entries(r).map(([i,o],s)=>{const l=e.filter(c=>c.channel===i).length,u=o.commissionRate+o.pgRate;return _.jsxs(_.Fragment,{children:[_.jsxs("tr",{className:Ae("border-b border-border/60",s%2!==0&&"bg-muted/30"),children:[_.jsx("td",{className:"px-3 py-2.5",children:_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx(DL,{channel:i}),Dr[i]??i]})}),_.jsx("td",{className:"px-3 py-2.5 text-right",children:o.commissionRate>0?_.jsxs("span",{className:"inline-flex items-center gap-1 justify-end",children:[_.jsxs("span",{className:"font-medium",children:[o.commissionRate,"%"]}),o.marketingLinkCommissionRate!=null&&_.jsx(Ii,{side:"top",content:_.jsxs("div",{className:"space-y-0.5",children:[_.jsx("p",{className:"font-medium",children:"판매수수료 2종 (택1)"}),_.jsxs("p",{children:["일반 유입: ",o.commissionRate,"%"]}),_.jsxs("p",{children:["마케팅 링크 유입: ",o.marketingLinkCommissionRate,"%"]})]})})]}):_.jsx("span",{className:"text-muted-foreground",children:"-"})}),_.jsx("td",{className:"px-3 py-2.5 text-right",children:o.pgRate>0?_.jsxs("span",{className:"inline-flex items-center gap-1 justify-end",children:[(()=>{var v;const c=Cg(o.revenueTiers,t),f=c!=null?(v=o.revenueTiers)==null?void 0:v[c]:null,d=(f==null?void 0:f.pgRate)??null;return d!=null&&d!==o.pgRate?_.jsxs("span",{className:"inline-flex items-center gap-1",children:[_.jsxs("span",{className:"font-semibold text-emerald-600 dark:text-emerald-400",children:[d,"%"]}),_.jsx(Ii,{side:"top",content:_.jsxs("div",{className:"space-y-0.5",children:[_.jsxs("p",{className:"font-medium text-emerald-400",children:["현재 적용: ",d,"% (",f==null?void 0:f.label,")"]}),_.jsxs("p",{className:"text-muted-foreground",children:["기본(일반): ",o.pgRate,"%"]}),t!=null&&_.jsxs("p",{className:"text-muted-foreground text-[10px]",children:["연매출 ",(t/1e8).toFixed(1),"억 기준"]})]})})]}):_.jsxs("span",{className:"font-medium",children:[o.pgRate,"%"]})})(),o.pgRateAppliesToShipping&&_.jsx(Ii,{side:"top",content:_.jsx("p",{children:"배송비 포함 금액에도 적용 (스마트스토어 Npay 수수료)"})})]}):_.jsx("span",{className:"text-muted-foreground",children:"-"})}),_.jsx("td",{className:"px-3 py-2.5 text-right text-muted-foreground",children:u>0?_.jsxs("span",{children:[u.toFixed(2),"%",o.shippingCommissionRate!=null&&o.shippingCommissionRate>0&&_.jsx(Ii,{side:"top",content:_.jsxs("p",{children:["배송비 수수료 ",o.shippingCommissionRate,"% 별도"]})})]}):"-"}),_.jsx("td",{className:"px-3 py-2.5 text-muted-foreground",children:a[o.settlementDayBasis]??o.settlementDayBasis}),_.jsxs("td",{className:"px-3 py-2.5 text-right text-muted-foreground",children:[o.settlementCycleDays,"일"]}),_.jsx("td",{className:"px-3 py-2.5",children:l>0?_.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] font-medium bg-amber-100 text-amber-700 dark:bg-amber-950/50 dark:text-amber-400 px-1.5 py-0.5 rounded-full",children:[l,"개 규칙 적용"]}):_.jsx("span",{className:"text-[11px] text-muted-foreground",children:"기본값"})})]},i),_.jsx(jwe,{d:o,annualRevenue:t,channel:i},`${i}-detail`)]})})})]})})}const Zwe=/^\d{4}-\d{2}-\d{2}$/,$we=["일","월","화","수","목","금","토"];function _p(r,e){const t=new Date(`${r}T00:00:00Z`);return Number.isNaN(t.getTime())?r:(t.setUTCDate(t.getUTCDate()+e),t.toISOString().slice(0,10))}function fV(r){if(!Zwe.test(r))return null;const e=new Date(`${r}T00:00:00Z`);if(Number.isNaN(e.getTime()))return null;const t=e.getUTCDay();return e.setUTCDate(e.getUTCDate()+(t===0?-6:1-t)),e.toISOString().slice(0,10)}function NL(r){const e=new Date(`${r}T00:00:00Z`);return $we[e.getUTCDay()]??""}function IY(r){return r>=1e8?`${(r/1e8).toFixed(1)}억`:r>=1e4?`${Math.round(r/1e4)}만`:r>=1e3?`${Math.round(r/1e3)}천`:r.toLocaleString()}function ph(r){return r.slice(5).replace("-","/")}function Kwe({dateStr:r,channels:e,total:t}){return _.jsxs("div",{className:"min-w-[180px] space-y-1",children:[_.jsxs("div",{className:"text-[10px] text-muted-foreground font-medium mb-0.5",children:[ph(r)," (",NL(r),")"]}),e.map(n=>_.jsxs("div",{className:"flex items-center justify-between gap-4 text-[11px]",children:[_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx("span",{className:"w-1.5 h-1.5 rounded-full shrink-0",style:{backgroundColor:GM[n.channel]??"#888"}}),_.jsx("span",{className:"text-muted-foreground",children:Dr[n.channel]??n.channel})]}),_.jsx("span",{className:"font-medium tabular-nums",children:_t(n.amount)})]},n.channel)),_.jsxs("div",{className:"flex justify-between gap-4 text-[11px] font-semibold pt-1 border-t border-border/40",children:[_.jsx("span",{children:"합계"}),_.jsx("span",{className:"tabular-nums text-emerald-500",children:_t(t)})]})]})}function Qwe({wk:r,days:e,total:t}){const n=_p(r,6);return _.jsxs("div",{className:"min-w-[200px] space-y-2",children:[_.jsxs("div",{className:"text-[10px] text-muted-foreground font-medium",children:[ph(r)," ~ ",ph(n)]}),e.length===0?_.jsx("p",{className:"text-[11px] text-muted-foreground",children:"입금 없음"}):_.jsxs(_.Fragment,{children:[e.map(a=>_.jsxs("div",{children:[_.jsxs("div",{className:"text-[10px] text-muted-foreground/70 mb-0.5",children:[ph(a.date)," (",NL(a.date),")"]}),a.channels.map(i=>_.jsxs("div",{className:"flex items-center justify-between gap-4 text-[11px]",children:[_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx("span",{className:"w-1.5 h-1.5 rounded-full shrink-0",style:{backgroundColor:GM[i.channel]??"#888"}}),_.jsx("span",{className:"text-muted-foreground",children:Dr[i.channel]??i.channel})]}),_.jsx("span",{className:"font-medium tabular-nums",children:_t(i.amount)})]},i.channel))]},a.date)),_.jsxs("div",{className:"flex justify-between gap-4 text-[11px] font-semibold pt-1 border-t border-border/40",children:[_.jsx("span",{children:"주간 합계"}),_.jsx("span",{className:"tabular-nums text-emerald-500",children:_t(t)})]})]})]})}const ap=64,RT=20;function Jwe({schedule:r,today:e,maxAmount:t}){const n=new Map;for(const c of r){const f=fV(c.depositDate);if(!f)continue;const d=c.byChannel.reduce((g,y)=>y.amount>g.amount?y:g,c.byChannel[0]),v=n.get(f);n.set(f,{amount:((v==null?void 0:v.amount)??0)+c.totalAmount,topChannel:(v==null?void 0:v.topChannel)??(d==null?void 0:d.channel)??"",days:[...(v==null?void 0:v.days)??[],{date:c.depositDate,amount:c.totalAmount,channels:c.byChannel}].sort((g,y)=>g.date.localeCompare(y.date))})}const a=fV(e)??e,i=[...n.keys()].sort(),o=[_p(a,-28),i[0]??a].sort()[0],s=[_p(a,56),i[i.length-1]??a].sort().at(-1),l=[];let u=o;for(;u<=s;)l.push(u),u=_p(u,7);for(;l.length<20;)l.push(_p(l[l.length-1],7));return _.jsxs("div",{className:"relative flex",style:{height:`${ap+RT}px`},children:[_.jsx("div",{className:"absolute bottom-[20px] left-0 right-0 border-b border-border/40 pointer-events-none"}),l.map(c=>{const f=n.get(c),d=(f==null?void 0:f.amount)??0,v=d>0?Math.max(5,Math.round(d/t*ap)):0,g=c===a,y=d>0?.2+d/t*.72:0;return _.jsx(Bo,{content:_.jsx(Qwe,{wk:c,days:(f==null?void 0:f.days)??[],total:(f==null?void 0:f.amount)??0}),side:"top",contentClassName:"max-w-[260px]",children:_.jsxs("div",{className:"relative flex flex-col flex-1 min-w-0 cursor-default px-0.5",style:{height:`${ap+RT}px`},children:[g&&_.jsx("div",{className:"absolute left-1/2 -translate-x-1/2 w-px bg-primary/50 pointer-events-none",style:{top:0,height:`${ap}px`}}),g&&_.jsx("span",{className:"absolute top-0 left-0 right-0 text-center text-[7px] text-primary font-semibold leading-none bg-card/80 pointer-events-none",children:"이번주"}),_.jsx("div",{style:{height:`${ap-v}px`,flexShrink:0}}),v>0&&_.jsx("div",{className:"w-full rounded-t",style:{height:`${v}px`,backgroundColor:`hsl(var(--primary) / ${y})`,flexShrink:0}}),_.jsx("div",{className:Ae("text-center mt-1 leading-none truncate text-[7px]",g?"text-primary font-semibold":"text-muted-foreground/50"),children:ph(c)}),v>=20&&_.jsx("div",{className:"absolute left-0 right-0 text-center text-[7px] font-medium text-white/90 pointer-events-none",style:{bottom:`${RT+2}px`},children:IY(d)})]})},c)})]})}function e2e({year:r,month:e,depositMap:t,today:n,maxAmount:a}){const i=new Date(`${r}-${String(e).padStart(2,"0")}-01T00:00:00Z`).getUTCDay(),o=new Date(r,e,0).getDate(),s=[...Array(i).fill(null),...Array.from({length:o},(l,u)=>u+1)];return _.jsxs("div",{children:[_.jsxs("div",{className:"text-[11px] font-medium text-muted-foreground mb-2",children:[r,"년 ",e,"월"]}),_.jsxs("div",{className:"grid grid-cols-7 gap-[2px]",children:[["일","월","화","수","목","금","토"].map(l=>_.jsx("div",{className:"text-center text-[9px] text-muted-foreground/50 py-0.5 font-medium",children:l},l)),s.map((l,u)=>{if(!l)return _.jsx("div",{className:"h-[40px]"},`e-${u}`);const c=`${r}-${String(e).padStart(2,"0")}-${String(l).padStart(2,"0")}`,f=t.get(c),d=c===n,v=f?.07+f.totalAmount/a*.28:0,g=_.jsxs("div",{className:Ae("h-[40px] flex flex-col items-center justify-center gap-0.5 rounded cursor-default",d&&"ring-1 ring-inset ring-primary/50"),style:f?{backgroundColor:`hsl(var(--primary) / ${v})`}:void 0,children:[_.jsx("span",{className:Ae("text-[10px] leading-none",d?"font-bold text-primary":f?"font-medium text-foreground":"text-muted-foreground/60"),children:l}),f&&_.jsx("span",{className:"text-[8px] font-semibold leading-none text-foreground/80",children:IY(f.totalAmount)})]});return f?_.jsx(Bo,{content:_.jsx(Kwe,{dateStr:c,channels:f.byChannel,total:f.totalAmount}),side:"top",contentClassName:"max-w-[240px]",children:g},c):_.jsx("div",{children:g},c)})]})]})}function t2e({schedule:r,today:e}){const t=r.filter(n=>n.depositDate>=e).sort((n,a)=>n.depositDate.localeCompare(a.depositDate));return _.jsxs("div",{className:"border border-border rounded-lg bg-card overflow-y-auto h-full",children:[_.jsx("div",{className:"px-3 pt-3 pb-2 text-[11px] font-medium text-muted-foreground border-b border-border/50",children:"예정 입금"}),t.length===0?_.jsx("p",{className:"text-[12px] text-muted-foreground px-3 py-3",children:"향후 예정 없음"}):_.jsx("div",{className:"divide-y divide-border/50",children:t.map(n=>_.jsxs("div",{className:"px-3 py-2.5",children:[_.jsxs("div",{className:"text-[10px] font-semibold text-foreground/70 mb-1.5",children:[ph(n.depositDate)," ",_.jsxs("span",{className:"font-normal text-muted-foreground/60",children:["(",NL(n.depositDate),")"]})]}),_.jsxs("div",{className:"space-y-1",children:[n.byChannel.map(a=>_.jsxs("div",{className:"flex items-center justify-between gap-2 text-[11px]",children:[_.jsxs("div",{className:"flex items-center gap-1.5 min-w-0",children:[_.jsx("span",{className:"w-1.5 h-1.5 rounded-full shrink-0",style:{backgroundColor:GM[a.channel]??"#888"}}),_.jsx("span",{className:"text-muted-foreground truncate",children:Dr[a.channel]??a.channel})]}),_.jsx("span",{className:"font-medium tabular-nums text-foreground shrink-0",children:_t(a.amount)})]},a.channel)),n.byChannel.length>1&&_.jsxs("div",{className:"flex justify-between text-[10px] font-semibold pt-1 border-t border-border/30",children:[_.jsx("span",{className:"text-muted-foreground/60",children:"합계"}),_.jsx("span",{className:"text-emerald-600 dark:text-emerald-400 tabular-nums",children:_t(n.totalAmount)})]})]})]},n.depositDate))})]})}function r2e({schedule:r,isLoading:e}){const t=new Date().toISOString().slice(0,10),n=new Map(r.map(f=>[f.depositDate,f])),[a,i]=t.split("-").map(Number),o=[{year:a,month:i},{year:i===12?a+1:a,month:i===12?1:i+1}],s=Math.max(...r.map(f=>f.totalAmount),1),l=r.filter(f=>f.depositDate>=t),u=l.reduce((f,d)=>f+d.totalAmount,0),c=l.reduce((f,d)=>f+d.orderCount,0);return _.jsx(WG,{delayDuration:80,children:_.jsxs("div",{className:"mt-6",children:[_.jsxs("div",{className:"flex items-center justify-between mb-3",children:[_.jsx("h3",{className:"text-[13px] font-medium",children:"입금 스케줄"}),u>0&&_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:["향후"," ",_.jsx("span",{className:"text-emerald-600 dark:text-emerald-400 font-medium",children:_t(u)})," ","예정 · ",c,"건"]})]}),e?_.jsx("div",{className:"text-sm text-muted-foreground py-4 text-center",children:"불러오는 중..."}):r.length===0?_.jsx("div",{className:"border border-dashed border-border rounded-lg px-4 py-5 text-[12px] text-muted-foreground text-center",children:"정산 데이터가 없어 입금 스케줄을 계산할 수 없습니다."}):_.jsxs("div",{className:"flex gap-3 items-start",children:[_.jsxs("div",{className:"flex-[2] min-w-0",children:[_.jsx("div",{className:"border border-border rounded-lg bg-card px-3 pt-7 pb-2 mb-3",children:_.jsx(Jwe,{schedule:r,today:t,maxAmount:s})}),_.jsx("div",{className:"border border-border rounded-lg bg-card p-4",children:_.jsx("div",{className:"grid grid-cols-2 gap-6",children:o.map(({year:f,month:d})=>_.jsx(e2e,{year:f,month:d,depositMap:n,today:t,maxAmount:s},`${f}-${d}`))})})]}),_.jsx("div",{className:"flex-[1] min-w-0 self-stretch",children:_.jsx(t2e,{schedule:r,today:t})})]})]})})}function n2e({rule:r}){const e=r.from||r.to;return _.jsxs("tr",{className:"border-b border-border/60 text-[12px]",children:[_.jsx("td",{className:"px-3 py-2.5 font-mono text-[10px] text-muted-foreground",children:r.id}),_.jsx("td",{className:"px-3 py-2.5",children:_.jsxs("div",{className:"flex items-center gap-1.5",children:[_.jsx(DL,{channel:r.channel}),Dr[r.channel]??r.channel]})}),_.jsx("td",{className:"px-3 py-2.5 text-right",children:r.commissionRate!=null?_.jsxs("span",{className:"font-medium",children:[r.commissionRate,"%"]}):_.jsx("span",{className:"text-muted-foreground text-[11px]",children:"기본값"})}),_.jsx("td",{className:"px-3 py-2.5 text-right",children:r.pgRate!=null?_.jsxs("span",{className:"font-medium",children:[r.pgRate,"%"]}):_.jsx("span",{className:"text-muted-foreground text-[11px]",children:"기본값"})}),_.jsx("td",{className:"px-3 py-2.5 text-muted-foreground",children:e?_.jsxs("span",{children:[r.from??"~"," ~ ",r.to??""]}):_.jsx("span",{className:"text-[11px]",children:"상시"})}),_.jsx("td",{className:"px-3 py-2.5 text-muted-foreground",children:r.paymentMethod??_.jsx("span",{className:"text-[11px]",children:"전체"})}),_.jsx("td",{className:"px-3 py-2.5 text-muted-foreground max-w-[160px] truncate",title:r.note,children:r.note??"-"})]})}function a2e(){var B;const[r,e]=q.useState(""),[t,n]=q.useState(""),a=!!r||!!t,{data:i,isLoading:o}=GV(a?{from:r,to:t}:void 0),{data:s,isLoading:l}=Qq(),{data:u=[],isLoading:c}=Jq(r||void 0,t||void 0),f=(s==null?void 0:s.defaults)??{},{data:d}=Xh(),v=((B=d==null?void 0:d.channels)==null?void 0:B.some(P=>P.channel==="smartstore"&&P.connected))??!1,{data:g}=eZ(r||new Date(Date.now()-720*60*60*1e3).toISOString().slice(0,10),t||new Date().toISOString().slice(0,10),v),[y,x]=q.useState(!1),[b,w]=q.useState(!1),T=(i==null?void 0:i.settlement)??[],C=(i==null?void 0:i.totalRevenue)??0,D=(i==null?void 0:i.netRevenue)??0,M=(i==null?void 0:i.totalOrders)??0,N=C-D,R=C>0?N/C*100:0,E=(s==null?void 0:s.rules)??[],k=(s==null?void 0:s.annualRevenue)??null,I=(s==null?void 0:s.quickSettlement)??!1;return _.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center justify-between mb-4",children:[_.jsx("h2",{className:"text-xl font-medium",children:"정산"}),_.jsxs("div",{className:"flex items-center gap-1.5 text-[11px] text-muted-foreground",children:[_.jsx(eG,{size:12}),"orders.jsonl 기반 추정값 · 실제 정산과 차이 있을 수 있음"]})]}),_.jsx(FM,{from:r,to:t,onChange:(P,H)=>{e(P),n(H)},className:"mb-6"}),_.jsxs("div",{className:"grid grid-cols-4 gap-3 mb-6",children:[_.jsx(Jr,{label:"총 매출",value:_t(C),sub:`주문 ${M.toLocaleString()}건`}),_.jsx(Jr,{label:"수수료 · PG 합계",value:_t(N),sub:`평균 ${R.toFixed(1)}%`}),_.jsx(Jr,{label:"실수령 예상",value:_t(D),accent:!0}),_.jsx(Jr,{label:"수수료 규칙",value:`${E.length}개`,sub:E.length===0?"기본값 적용 중":"커스텀 규칙 적용"})]}),_.jsxs("div",{className:"mb-6",children:[_.jsx("h3",{className:"text-[13px] font-medium mb-3",children:"채널별 정산 현황"}),_.jsx(Xwe,{channels:T,rules:E,defaults:f,annualRevenue:k,quickSettlement:I,totalRevenue:C,totalOrders:M,totalCommission:N,netRevenue:D,commissionRate:R,isLoading:o,ssDaily:g,dateFrom:r,dateTo:t})]}),_.jsxs("div",{className:"mb-4",children:[_.jsxs("button",{type:"button",onClick:()=>x(P=>!P),className:"flex items-center gap-2 w-full text-left group mb-0",children:[y?_.jsx(Sn,{size:13,className:"shrink-0 text-muted-foreground"}):_.jsx(Pn,{size:13,className:"shrink-0 text-muted-foreground"}),_.jsx("span",{className:"text-[13px] font-medium group-hover:text-foreground/80 transition-colors",children:"채널 기본 수수료 규칙"}),_.jsx(Ii,{size:12,contentClassName:"max-w-[300px]",content:_.jsxs("div",{className:"space-y-1.5",children:[_.jsx("p",{className:"font-medium",children:"채널 기본 수수료 규칙이란?"}),_.jsxs("div",{className:"space-y-1 text-muted-foreground",children:[_.jsx("p",{children:"공식 자료·실데이터 기반 채널별 표준 요율입니다."}),_.jsx("p",{children:"커스텀 규칙이 없을 때 정산 추정에 사용됩니다."}),_.jsx("p",{children:"실제 계약 조건이 다르면 커스텀 규칙으로 오버라이드하세요."})]})]})})]}),y&&_.jsx("div",{className:"mt-3",children:_.jsx(qwe,{defaults:f,rules:E,annualRevenue:k,isLoading:l})})]}),_.jsxs("div",{children:[_.jsxs("button",{type:"button",onClick:()=>w(P=>!P),className:"flex items-center gap-2 w-full text-left group mb-0",children:[b?_.jsx(Sn,{size:13,className:"shrink-0 text-muted-foreground"}):_.jsx(Pn,{size:13,className:"shrink-0 text-muted-foreground"}),_.jsx("span",{className:"text-[13px] font-medium group-hover:text-foreground/80 transition-colors",children:"커스텀 수수료 규칙"}),E.length>0&&_.jsxs("span",{className:"inline-flex items-center text-[10px] font-medium bg-amber-100 text-amber-700 dark:bg-amber-950/50 dark:text-amber-400 px-1.5 py-0.5 rounded-full",children:[E.length,"개"]}),_.jsx("span",{className:"ml-auto text-[11px] text-muted-foreground flex items-center gap-1",children:_.jsx("code",{className:"bg-muted px-1 rounded text-[10px] mr-2",children:"sppt settlement fee set <channel>"})})]}),b&&_.jsx("div",{className:"mt-3",children:l?_.jsx("div",{className:"text-sm text-muted-foreground py-4 text-center",children:"불러오는 중..."}):E.length===0?_.jsxs("div",{className:"border border-dashed border-border rounded-lg px-4 py-5 text-[12px] text-muted-foreground flex items-center gap-2",children:[_.jsx(DM,{size:13,className:"shrink-0"}),"등록된 커스텀 규칙 없음 — 채널 기본 수수료 규칙이 적용됩니다."]}):_.jsxs("div",{className:"border border-border rounded-lg overflow-hidden",children:[_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left w-[72px]",children:"ID"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"채널"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"판매수수료"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"PG수수료"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"적용 기간"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"결제수단"}),_.jsx("th",{className:"px-3 py-2 text-left",children:"메모"})]})}),_.jsx("tbody",{className:"bg-card",children:E.map(P=>_.jsx(n2e,{rule:P},P.id))})]}),_.jsxs("div",{className:"px-3 py-2 border-t border-border bg-muted/20 flex items-center gap-1.5 text-[11px] text-muted-foreground",children:[_.jsx(aG,{size:11}),"조건이 많이 맞는 규칙이 우선 적용 (기간 > 결제수단 > 카테고리 순)"]})]})})]}),_.jsx(r2e,{schedule:u,isLoading:c})]})}function i2e({trendPoints:r,direction:e}){const[t,n]=q.useState(null);if(!r||r.length<2)return _.jsx("span",{className:"inline-block w-[50px] h-[24px]"});const a=50,i=24,o=2,s=r.map(x=>x.ratio),l=Math.min(...s),c=Math.max(...s)-l||1,f=r.map((x,b)=>({x:o+b/(r.length-1)*(a-o*2),y:i-o-(x.ratio-l)/c*(i-o*2),period:x.period,ratio:x.ratio})),d=f.map(x=>`${x.x},${x.y}`).join(" "),v=e==="상승"?"#22c55e":e==="하락"?"#ef4444":"#94a3b8",g=f.map((x,b)=>{const w=b>0?(f[b-1].x+x.x)/2:0,T=b<f.length-1?(x.x+f[b+1].x)/2:a;return{x:w,width:T-w}}),y=t!==null?f[t]:null;return _.jsxs("svg",{width:a,height:i,viewBox:`0 0 ${a} ${i}`,className:"inline-block overflow-visible","aria-hidden":"true",children:[_.jsx("polyline",{points:d,fill:"none",stroke:v,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),y&&_.jsxs(_.Fragment,{children:[_.jsx("line",{x1:y.x,y1:0,x2:y.x,y2:i,stroke:v,strokeWidth:1,strokeDasharray:"2 2",strokeOpacity:.5}),_.jsx("circle",{cx:y.x,cy:y.y,r:2.5,fill:v,stroke:"white",strokeWidth:1})]}),g.map((x,b)=>_.jsx(Bo,{side:"top",content:_.jsxs("span",{children:[_.jsx("span",{className:"font-medium",children:f[b].period}),_.jsx("br",{}),"상대 검색량 ",_.jsx("span",{className:"font-semibold",children:Math.round(f[b].ratio)}),_.jsx("span",{className:"opacity-60",children:" / 100"})]}),children:_.jsx("rect",{x:x.x,y:0,width:x.width,height:i,fill:"transparent",stroke:"none",className:"cursor-default",onMouseEnter:()=>n(b),onMouseLeave:()=>n(null)})},f[b].period))]})}const o2e={낮음:"bg-green-500/15 text-green-600",보통:"bg-yellow-500/15 text-yellow-600",높음:"bg-orange-500/15 text-orange-600",매우높음:"bg-red-500/15 text-red-600"},s2e={상승:{icon:"↑",cls:"text-green-500"},하락:{icon:"↓",cls:"text-red-500"},보합:{icon:"→",cls:"text-muted-foreground"}};function hV(r){return r==null?"—":r.toLocaleString("ko-KR")}function G0(r){return r==null?"—":`${r.toLocaleString("ko-KR")}원`}function l2e(r,e,t,n){const a=(e+t)/2,i=Math.max(n,t);return r<=a?{dot:"🟢",label:"신규진입 가능 — 하위 ~20%, 리뷰 없어도 경쟁 가능",cls:"text-green-600 font-semibold"}:r<=i?{dot:"🟡",label:"판매 가능 — 시장 평균 이하, 경쟁력 있음",cls:"text-yellow-600 font-medium"}:{dot:"🔴",label:"판매 어려움 — 시장가 초과",cls:"text-red-500"}}function u2e(r){var n;const e=new Set,t=[];for(const a of r)for(const i of((n=a.analysis.marginAnalysis)==null?void 0:n.platforms)??[])e.has(i.platform)||(e.add(i.platform),t.push(i.platform));return t}function c2e({entries:r}){const e=u2e(r),t=e.length>0;return _.jsx("div",{className:"overflow-x-auto rounded-xl border border-border",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsxs("thead",{children:[_.jsxs("tr",{className:"border-b border-border bg-muted/40",children:[_.jsx(H0,{align:"left",children:"키워드"}),_.jsx(H0,{align:"left",children:"소싱 채널"}),_.jsx(ip,{tip:"도매 소싱가",children:"소싱가"}),_.jsxs(ip,{tip:"네이버쇼핑 검색결과 기준. 중앙값은 저가 잡상품에 왜곡될 수 있어, avg가 중앙값보다 높으면 avg를 함께 표시합니다.",children:["시장판매가",_.jsx("br",{}),_.jsx("span",{className:"font-normal text-[10px] opacity-60",children:"(중앙값 / avg)"})]}),_.jsxs(ip,{tip:"네이버쇼핑 기준 해당 키워드 검색 시 노출되는 경쟁 상품 수",children:["경쟁상품수",_.jsx("br",{}),_.jsx("span",{className:"font-normal text-[10px] opacity-60",children:"(네이버쇼핑)"})]}),_.jsxs(ip,{tip:"최근 1개월 네이버 검색량 (PC+모바일)",children:["월검색량",_.jsx("br",{}),_.jsx("span",{className:"font-normal text-[10px] opacity-60",children:"(트렌드)"})]}),_.jsx(H0,{children:"경쟁도"}),t&&_.jsxs(ip,{colSpan:e.length,tip:"소싱가 기준 플랫폼 수수료 포함, 각 마진율 달성 최소판매가. 30% * = 세전 최소기준선(≈×1.7). 🟢 신규진입 가능(하위~20%) 🟡 판매 가능(시장 평균↓) 🔴 판매 어려움(시장가 초과)",children:["채널별 최소판매가",_.jsx("br",{}),_.jsx("span",{className:"font-normal text-[10px] opacity-60",children:"(수수료 포함, 5·10·20·30% * 기준)"})]}),_.jsx(H0,{children:"검토"})]}),t&&_.jsxs("tr",{className:"border-b border-border bg-muted/20",children:[Array.from({length:7}).map((n,a)=>_.jsx("td",{},a)),e.map(n=>_.jsx("td",{className:"px-3 py-1 text-center text-[10px] text-muted-foreground font-medium border-l border-border",children:n},n)),_.jsx("td",{})]})]}),_.jsx("tbody",{className:"bg-white dark:bg-card",children:r.map((n,a)=>{const{analysis:i,keyword:o,productName:s,sourceChannel:l,sourcingPrice:u,savedAt:c}=n,{demand:f,marginAnalysis:d,price:v,competitionLevel:g,totalListings:y}=i,x=UM(new Date(c),{addSuffix:!0,locale:F1}),b=(f==null?void 0:f.trendDirection)??null,w=b?s2e[b]:null,T=f==null?void 0:f.monthlyTotal,C=u&&v.median>0?Math.round((v.median-u)/u*100):null,D=new Map((d==null?void 0:d.platforms.map(N=>[N.platform,N]))??[]),M=v.avg>v.median*1.5;return _.jsxs("tr",{className:["border-b border-border/60 hover:bg-blue-50/40 dark:hover:bg-muted/20 transition-colors",a%2!==0?"bg-gray-50/60 dark:bg-muted/5":""].join(" "),children:[_.jsxs("td",{className:"px-3 py-2.5 max-w-[140px]",children:[_.jsx("div",{className:"font-semibold truncate",children:o}),s&&_.jsx("div",{className:"text-[10px] text-muted-foreground truncate mt-0.5",children:s})]}),_.jsx("td",{className:"px-3 py-2.5 text-center whitespace-nowrap",children:l??"—"}),_.jsx("td",{className:"px-3 py-2.5 text-right whitespace-nowrap",children:u?_.jsx("span",{className:"font-medium",children:G0(u)}):_.jsx("span",{className:"text-muted-foreground",children:"—"})}),_.jsxs("td",{className:"px-3 py-2.5 text-right whitespace-nowrap",children:[_.jsxs("div",{className:"flex items-baseline justify-end gap-1",children:[_.jsx("span",{className:"font-medium",children:G0(v.median)}),C!=null&&_.jsx(Bo,{content:`소싱가 대비 ${C>=0?"+":""}${C}%`,children:_.jsxs("span",{className:["text-[10px] cursor-default",C>=0?"text-green-500":"text-red-500"].join(" "),children:[C>=0?"+":"",C,"%"]})})]}),M&&_.jsx(Bo,{content:"평균가 — 중앙값이 저가 잡상품에 왜곡된 경우 이 값이 실거래 기준이 됩니다. 티어 판정(🟢🟡🔴)에 사용됩니다.",children:_.jsxs("div",{className:"text-[10px] text-blue-500 mt-0.5 cursor-default",children:["avg ",G0(v.avg)]})})]}),_.jsxs("td",{className:"px-3 py-2.5 text-right whitespace-nowrap",children:[hV(y),"개"]}),_.jsx("td",{className:"px-3 py-2.5 whitespace-nowrap",children:T!=null?_.jsxs("div",{className:"flex items-center justify-end gap-1.5",children:[_.jsxs("span",{children:[hV(T),"회"]}),w&&_.jsx("span",{className:["font-medium text-[10px]",w.cls].join(" "),children:w.icon}),f&&f.trendPoints.length>=2&&_.jsx(i2e,{trendPoints:f.trendPoints,direction:b})]}):_.jsx("span",{className:"text-muted-foreground float-right",children:"—"})}),_.jsx("td",{className:"px-3 py-2.5 text-center",children:_.jsx("span",{className:["text-[10px] font-semibold px-2 py-0.5 rounded-full whitespace-nowrap",o2e[g]??"bg-muted text-muted-foreground"].join(" "),children:g})}),e.map(N=>{const R=D.get(N),E=R&&(R.sell5||R.sell10||R.sell20||R.sell30),k=E?[{label:"5%",sell:R.sell5||null,isMin:!1},{label:"10%",sell:R.sell10||null,isMin:!1},{label:"20%",sell:R.sell20||null,isMin:!1},{label:"30% *",sell:R.sell30||null,isMin:!0}]:[];return _.jsx("td",{className:"px-3 py-2 border-l border-border/40 align-top",children:E?_.jsx("div",{className:"flex flex-col gap-0.5",children:k.map(({label:I,sell:B,isMin:P})=>{if(B==null)return null;const H=l2e(B,v.min,v.median,v.avg);return _.jsx(Bo,{content:P?`[최소기준선] ${H.label}`:H.label,children:_.jsxs("div",{className:["flex items-center justify-between gap-1.5 text-[11px] cursor-default",P?"font-semibold":""].join(" "),children:[_.jsx("span",{className:["w-10 shrink-0 whitespace-nowrap",P?"text-foreground/70":"text-muted-foreground"].join(" "),children:I}),_.jsx("span",{className:[H.cls,"whitespace-nowrap"].join(" "),children:G0(B)}),_.jsx("span",{children:H.dot})]})},I)})}):_.jsx("span",{className:"text-muted-foreground",children:"—"})},N)}),_.jsx("td",{className:"px-3 py-2.5 text-right whitespace-nowrap text-muted-foreground",children:x})]},n.id)})})]})})}function H0({children:r,align:e="center",colSpan:t}){return _.jsx("th",{colSpan:t,className:["px-3 py-2 text-[11px] font-semibold text-muted-foreground leading-tight whitespace-nowrap",e==="left"?"text-left":e==="right"?"text-right":"text-center"].join(" "),children:r})}function ip({children:r,tip:e,align:t="center",colSpan:n}){return _.jsx("th",{colSpan:n,className:["px-3 py-2 text-[11px] font-semibold text-muted-foreground leading-tight whitespace-nowrap",t==="left"?"text-left":t==="right"?"text-right":"text-center"].join(" "),children:_.jsx(Bo,{content:e,children:_.jsx("span",{className:"cursor-help underline decoration-dotted decoration-muted-foreground/40",children:r})})})}const op=20;function f2e(r){var l;const e=(l=r.analysis.marginAnalysis)==null?void 0:l.platforms;if(!(e!=null&&e.length))return"🔴";const{min:t,median:n,avg:a}=r.analysis.price,i=(t+n)/2,o=Math.max(a,n);let s="🔴";for(const u of e){const c=u.sell30;if(c){if(c<=i)return"🟢";c<=o&&s!=="🟢"&&(s="🟡")}}return s}function h2e(r,e){return e?r.filter(t=>f2e(t)===e):r}const d2e={domeggook:"도매꾹",specialoffer:"특가몰",cjdropshipping:"CJ Dropshipping"};function v2e({channel:r,connected:e,rateLimit:t,dailyLimit:n}){const a=d2e[r]??r;return _.jsxs("div",{className:"flex items-center gap-3 py-3 border-b border-border/60 last:border-0",children:[_.jsx("span",{className:Ae("w-2 h-2 rounded-full shrink-0",e?"bg-green-500":"bg-muted-foreground/30")}),_.jsx("span",{className:"text-[13px] font-medium",children:a}),e?_.jsxs("div",{className:"ml-auto flex gap-3 text-[11px] text-muted-foreground",children:[_.jsxs("span",{children:[t," rps"]}),n&&_.jsxs("span",{children:["일 ",n.toLocaleString(),"회"]}),_.jsx("span",{className:"text-green-600 font-medium",children:"연결됨"})]}):_.jsxs("div",{className:"ml-auto text-[11px] text-muted-foreground",children:["미연결 · ",_.jsx("code",{className:"font-mono",children:"sppt init"})]})]})}function p2e(){const{data:r}=Xh(),{data:e=[],refetch:t,isFetching:n}=$q(),{data:a=[]}=Kq(),[i,o]=q.useState(1),[s,l]=q.useState(null),u=(r==null?void 0:r.sourceChannels)??[],c=u.filter(x=>x.connected).length,f=h2e(e,s),d=Math.max(1,Math.ceil(f.length/op)),v=Math.min(i,d),g=f.slice((v-1)*op,v*op);function y(x){l(b=>b===x?null:x),o(1)}return _.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center justify-between mb-6",children:[_.jsx("h2",{className:"text-xl font-medium",children:"소싱 채널"}),_.jsxs("div",{className:"text-[12px] text-muted-foreground",children:[c,"/",u.length," 연결됨"]})]}),_.jsxs("div",{className:"border border-border rounded-lg px-4 py-1 mb-8",children:[u.map(x=>_.jsx(v2e,{channel:x.channel,connected:x.connected,rateLimit:x.rateLimit,dailyLimit:x.dailyLimit},x.channel)),u.length===0&&_.jsx("div",{className:"py-4 text-center text-[12px] text-muted-foreground",children:"로딩 중..."})]}),_.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[_.jsx(Hp,{size:13,className:"text-muted-foreground"}),_.jsx("span",{className:"text-[13px] font-semibold text-muted-foreground",children:"소싱 검토 이력"}),e.length>0&&_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:[s?`${f.length} / `:"",e.length,"건"]}),e.length>0&&_.jsx("div",{className:"flex items-center gap-1 ml-2",children:["🟢","🟡","🔴"].map(x=>_.jsx("button",{type:"button",onClick:()=>y(x),className:Ae("px-2 py-0.5 rounded-full text-[11px] border transition-colors",s===x?"border-foreground/50 bg-muted text-foreground font-medium":"border-border text-muted-foreground hover:border-foreground/30"),children:x},x))}),_.jsxs("button",{type:"button",onClick:()=>t(),className:Ae("ml-auto flex items-center gap-1 text-[11px] border border-border rounded px-2 py-1 hover:border-foreground/40 transition-colors",n&&"opacity-50 pointer-events-none"),children:[_.jsx(F0,{size:10,className:Ae(n&&"animate-spin")}),"새로고침"]})]}),e.length===0||f.length===0?_.jsxs("div",{className:"border border-dashed border-border rounded-lg p-10 text-center text-muted-foreground text-sm",children:[_.jsx(ll,{size:24,className:"mx-auto mb-3 opacity-30"}),e.length===0?"소싱 상품 시장 분석 이력이 없습니다.":`${s} 해당 항목이 없습니다.`,_.jsxs("div",{className:"mt-3 space-y-1",children:[_.jsx("code",{className:"block bg-muted rounded px-2 py-1 text-[11px] text-foreground font-mono",children:"sppt source market-check <keyword>"}),_.jsx("code",{className:"block bg-muted rounded px-2 py-1 text-[11px] text-foreground font-mono",children:"sppt source detail <id> --market-check"})]})]}):_.jsxs(_.Fragment,{children:[_.jsx(c2e,{entries:g}),d>1&&_.jsxs("div",{className:"flex items-center justify-between mt-3 text-[12px] text-muted-foreground",children:[_.jsxs("span",{children:[(v-1)*op+1,"–",Math.min(v*op,f.length)," ","/ ",f.length,"건"]}),_.jsxs("div",{className:"flex items-center gap-1",children:[_.jsx("button",{type:"button",onClick:()=>o(x=>Math.max(1,x-1)),disabled:v===1,className:"p-1 rounded hover:bg-muted disabled:opacity-30 disabled:pointer-events-none",children:_.jsx(qZ,{size:14})}),Array.from({length:d},(x,b)=>b+1).map(x=>_.jsx("button",{type:"button",onClick:()=>o(x),className:Ae("w-6 h-6 rounded text-[11px] hover:bg-muted",x===v&&"bg-muted font-semibold text-foreground"),children:x},x)),_.jsx("button",{type:"button",onClick:()=>o(x=>Math.min(d,x+1)),disabled:v===d,className:"p-1 rounded hover:bg-muted disabled:opacity-30 disabled:pointer-events-none",children:_.jsx(Pn,{size:14})})]})]})]})]}),a.length>0&&_.jsxs("div",{className:"mt-8",children:[_.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[_.jsx(a$,{size:13,className:"text-muted-foreground"}),_.jsx("span",{className:"text-[13px] font-semibold text-muted-foreground",children:"공급처 검증 이력"}),_.jsxs("span",{className:"text-[11px] text-muted-foreground",children:[a.length,"건"]})]}),_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full text-[12px] border-collapse",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40 text-[11px] font-semibold text-muted-foreground",children:[_.jsx("th",{className:"px-3 py-2 text-left",children:"공급처"}),_.jsx("th",{className:"px-3 py-2 text-center",children:"채널"}),_.jsx("th",{className:"px-3 py-2 text-center",children:"판정"}),_.jsx("th",{className:"px-3 py-2 text-center",children:"재고(평균)"}),_.jsx("th",{className:"px-3 py-2 text-center",children:"품절율"}),_.jsx("th",{className:"px-3 py-2 text-center",children:"즉시출고"}),_.jsx("th",{className:"px-3 py-2 text-center",children:"자동검증"}),_.jsx("th",{className:"px-3 py-2 text-right",children:"검토"})]})}),_.jsx("tbody",{children:a.map((x,b)=>_.jsxs("tr",{className:Ae("border-b border-border/60",b%2!==0&&"bg-muted/5"),children:[_.jsxs("td",{className:"px-3 py-2",children:[_.jsx("div",{className:"font-medium",children:x.supplierNick??x.productId}),x.isPowerSeller&&_.jsx("span",{className:"text-[10px] text-blue-500",children:"파워셀러"}),x.isGoodSeller&&_.jsx("span",{className:"text-[10px] text-green-500 ml-1",children:"우수셀러"})]}),_.jsx("td",{className:"px-3 py-2 text-center text-muted-foreground",children:x.channel}),_.jsx("td",{className:"px-3 py-2 text-center text-base",children:x.tier}),_.jsx("td",{className:"px-3 py-2 text-center",children:x.avgStock!==void 0?_.jsxs("span",{className:x.avgStock>=30?"text-green-600":"text-red-500",children:[x.avgStock,"개"]}):"—"}),_.jsx("td",{className:"px-3 py-2 text-center",children:x.outOfStockRatioPct!==void 0?_.jsxs("span",{className:x.outOfStockRatioPct<30?"text-green-600":"text-red-500",children:[x.outOfStockRatioPct,"%"]}):"—"}),_.jsx("td",{className:"px-3 py-2 text-center",children:x.immediateShipPct!==void 0?_.jsxs("span",{className:x.immediateShipPct>=50?"text-green-600":"text-yellow-600",children:[x.immediateShipPct,"%"]}):"—"}),_.jsxs("td",{className:"px-3 py-2 text-center text-muted-foreground",children:[x.autoPassCount,"/",x.autoTotalCount]}),_.jsx("td",{className:"px-3 py-2 text-right text-muted-foreground whitespace-nowrap",children:UM(new Date(x.savedAt),{addSuffix:!0,locale:F1})})]},x.id))})]})})]})]})}const g2e=[{id:"musinsa",label:"무신사"},{id:"hwahae",label:"화해"}];function zp(r){return r==null?"-":r==="<10"?"<10":typeof r=="number"?r.toLocaleString():String(r)}function LL(r){return r==="낮음"?"text-green-600":r==="보통"?"text-yellow-600":"text-red-500"}function ET(r){const e=Date.now()-new Date(r).getTime(),t=Math.floor(e/6e4);if(t<1)return"방금";if(t<60)return`${t}분 전`;const n=Math.floor(t/60);return n<24?`${n}시간 전`:`${Math.floor(n/24)}일 전`}function m2e({data:r}){const e=Math.max(...r.map(t=>t.ratio),1);return _.jsx("div",{className:"flex items-end gap-0.5 h-12",children:r.map(t=>_.jsxs("div",{className:"flex flex-col items-center flex-1 gap-0.5 group relative",children:[_.jsx("div",{className:"w-full bg-primary/70 rounded-sm transition-all",style:{height:`${Math.round(t.ratio/e*100)}%`}}),_.jsxs("div",{className:"absolute -top-6 left-1/2 -translate-x-1/2 hidden group-hover:block text-[10px] bg-popover border border-border rounded px-1 py-0.5 whitespace-nowrap z-10",children:[t.period,": ",t.ratio]})]},t.period))})}function y2e({kw:r,highlight:e}){const t=typeof r.monthlyPcQcCnt=="number"?r.monthlyPcQcCnt:0,n=typeof r.monthlyMobileQcCnt=="number"?r.monthlyMobileQcCnt:0,a=t+n;return _.jsxs("tr",{className:Ae("border-b border-border/50 text-[12px]",e&&"bg-muted/50"),children:[_.jsx("td",{className:"py-2 px-3 font-medium text-foreground",children:r.relKeyword}),_.jsx("td",{className:"py-2 px-3 text-right tabular-nums text-muted-foreground",children:zp(r.monthlyPcQcCnt)}),_.jsx("td",{className:"py-2 px-3 text-right tabular-nums text-muted-foreground",children:zp(r.monthlyMobileQcCnt)}),_.jsx("td",{className:"py-2 px-3 text-right tabular-nums font-medium",children:a>0?a.toLocaleString():zp(r.monthlyPcQcCnt)}),_.jsx("td",{className:Ae("py-2 px-3 text-center font-medium",LL(r.compIdx)),children:r.compIdx})]})}function x2e({ranking:r}){return r?_.jsxs("div",{children:[_.jsx("div",{className:"flex items-center gap-2 mb-3",children:_.jsxs("span",{className:"text-[12px] text-muted-foreground",children:[r.platformLabel," · ",r.items.length,"개 ·"," ",new Date(r.fetchedAt).toLocaleTimeString("ko-KR",{hour:"2-digit",minute:"2-digit"})," ","기준"]})}),_.jsx("div",{className:"border border-border rounded-lg overflow-hidden",children:_.jsxs("table",{className:"w-full",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/40",children:[_.jsx("th",{className:"py-2 px-3 text-left text-[11px] text-muted-foreground font-medium w-8",children:"순위"}),_.jsx("th",{className:"py-2 px-3 text-left text-[11px] text-muted-foreground font-medium",children:"상품명"}),_.jsx("th",{className:"py-2 px-3 text-left text-[11px] text-muted-foreground font-medium",children:"브랜드"}),_.jsx("th",{className:"py-2 px-3 text-right text-[11px] text-muted-foreground font-medium",children:"가격"}),_.jsx("th",{className:"py-2 px-3 text-right text-[11px] text-muted-foreground font-medium",children:"리뷰"}),_.jsx("th",{className:"py-2 px-3 text-center text-[11px] text-muted-foreground font-medium w-8",children:"링크"})]})}),_.jsx("tbody",{children:r.items.map(e=>_.jsxs("tr",{className:"border-b border-border/50 hover:bg-muted/30 transition-colors text-[12px]",children:[_.jsx("td",{className:"py-2 px-3 text-muted-foreground tabular-nums text-center",children:e.rank}),_.jsx("td",{className:"py-2 px-3 font-medium max-w-[220px] truncate",children:e.name||"-"}),_.jsx("td",{className:"py-2 px-3 text-muted-foreground",children:e.brand||"-"}),_.jsx("td",{className:"py-2 px-3 text-right tabular-nums",children:e.price?_.jsxs("span",{children:[e.price.toLocaleString(),e.discountRate?_.jsxs("span",{className:"ml-1 text-[10px] text-red-500",children:["-",e.discountRate,"%"]}):null]}):"-"}),_.jsx("td",{className:"py-2 px-3 text-right tabular-nums text-muted-foreground",children:e.reviewCount?e.reviewCount.toLocaleString():"-"}),_.jsx("td",{className:"py-2 px-3 text-center",children:e.url?_.jsx("a",{href:e.url,target:"_blank",rel:"noopener noreferrer",className:"inline-flex text-muted-foreground hover:text-foreground transition-colors",children:_.jsx(kg,{size:12})}):"-"})]},e.rank))})]})})]}):null}function b2e({onSelectKeyword:r,onSelectPlatform:e}){const{data:t,isLoading:n}=sZ(),[a,i]=q.useState(!0);return n||!t||t.length===0?null:_.jsxs("section",{className:"mt-8",children:[_.jsxs("button",{type:"button",onClick:()=>i(o=>!o),className:"flex items-center gap-2 mb-3 text-[13px] font-semibold text-muted-foreground hover:text-foreground transition-colors",children:[_.jsx(KZ,{size:13}),"CLI 기록",_.jsxs("span",{className:"text-[11px] font-normal opacity-60",children:["(",t.length,"건)"]}),_.jsx("span",{className:"ml-auto text-[11px]",children:a?"▲":"▼"})]}),a&&_.jsx("div",{className:"border border-border rounded-lg overflow-hidden divide-y divide-border",children:t.map(o=>_.jsx(_2e,{entry:o,onSelectKeyword:r,onSelectPlatform:e},o.id))})]})}function _2e({entry:r,onSelectKeyword:e,onSelectPlatform:t}){var n;if(r.type==="keyword"){const a=(n=r.volume)==null?void 0:n.results[0],i=typeof(a==null?void 0:a.monthlyPcQcCnt)=="number"?a.monthlyPcQcCnt:0,o=typeof(a==null?void 0:a.monthlyMobileQcCnt)=="number"?a.monthlyMobileQcCnt:0,s=i+o;return _.jsxs("button",{type:"button",onClick:()=>e(r),className:"w-full flex items-center gap-3 px-4 py-2.5 hover:bg-muted/40 transition-colors text-left",children:[_.jsx(Fp,{size:11,className:"text-muted-foreground shrink-0"}),_.jsx("span",{className:"text-[13px] font-medium flex-1",children:r.keyword}),s>0&&_.jsxs("span",{className:"text-[11px] tabular-nums text-muted-foreground",children:[s.toLocaleString(),"회"]}),(a==null?void 0:a.compIdx)&&_.jsx("span",{className:Ae("text-[11px]",LL(a.compIdx)),children:a.compIdx}),_.jsx("span",{className:"text-[11px] text-muted-foreground/60",children:ET(r.timestamp)})]})}return r.type==="compare"?_.jsxs("button",{type:"button",onClick:()=>e(r),className:"w-full flex items-center gap-3 px-4 py-2.5 hover:bg-muted/40 transition-colors text-left",children:[_.jsx(Hp,{size:11,className:"text-muted-foreground shrink-0"}),_.jsx("span",{className:"text-[13px] font-medium flex-1",children:r.keywords.join(" vs ")}),_.jsx("span",{className:"text-[11px] text-muted-foreground/60",children:ET(r.timestamp)})]}):_.jsxs("button",{type:"button",onClick:()=>t(r),className:"w-full flex items-center gap-3 px-4 py-2.5 hover:bg-muted/40 transition-colors text-left",children:[_.jsx(ll,{size:11,className:"text-muted-foreground shrink-0"}),_.jsxs("span",{className:"text-[13px] font-medium flex-1",children:[r.platformLabel," 랭킹"]}),_.jsxs("span",{className:"text-[11px] tabular-nums text-muted-foreground",children:[r.ranking.items.length,"위"]}),_.jsx("span",{className:"text-[11px] text-muted-foreground/60",children:ET(r.timestamp)})]})}function S2e(){var I,B,P,H,V,j;const{data:r}=aZ(),[e,t]=q.useState(""),[n,a]=q.useState(null),[i,o]=q.useState(!1),[s,l]=q.useState(null),[u,c]=q.useState(null),[f,d]=q.useState(null),[v,g]=q.useState(!1),[y,x]=q.useState(null),b=q.useRef(new Map);async function w(){const U=e.trim();if(U){o(!0),l(null),a(null);try{const F=await iZ(U);F.error==="not_configured"?l(F.message??"채널이 설정되지 않았습니다"):F.error?l(F.message??F.error):a(F)}catch(F){l(F instanceof Error?F.message:String(F))}finally{o(!1)}}}async function T(U,F=!1){if(c(U),x(null),!F&&b.current.has(U)){d(b.current.get(U));return}g(!0),d(null);try{const X=await oZ(U,20);X.error==="not_configured"?x(X.message??"Apify가 설정되지 않았습니다"):X.error?x(X.message??X.error):(b.current.set(U,X),d(X))}catch(X){x(X instanceof Error?X.message:String(X))}finally{g(!1)}}function C(U){if(u===U&&f){c(null),d(null);return}T(U)}function D(){u&&T(u,!0)}function M(U){if(U.type==="keyword")t(U.keyword),a({keyword:U.keyword,volume:U.volume,trend:U.trend}),l(null),c(null),d(null);else{const F=U.keywords.join(", ");t(F),a({keyword:F,trend:U.trend}),l(null),c(null),d(null)}}function N(U){const F={ranking:U.ranking};b.current.set(U.platform,F),c(U.platform),d(F),x(null),a(null),l(null)}const R=((P=(B=(I=n==null?void 0:n.trend)==null?void 0:I.results)==null?void 0:B[0])==null?void 0:P.data)??[],E=((H=n==null?void 0:n.volume)==null?void 0:H.results)??[],k=E[0]??null;return _.jsxs("div",{children:[_.jsxs("div",{className:"flex items-center justify-between mb-6",children:[_.jsx("h2",{className:"text-xl font-medium",children:"트렌드"}),r&&_.jsxs("div",{className:"flex items-center gap-2 text-[11px] text-muted-foreground",children:[_.jsx("span",{className:Ae("w-1.5 h-1.5 rounded-full",r.searchad?"bg-green-500":"bg-muted-foreground/30")}),"검색광고",_.jsx("span",{className:Ae("w-1.5 h-1.5 rounded-full",r.datalab?"bg-green-500":"bg-muted-foreground/30")}),"데이터랩",_.jsx("span",{className:Ae("w-1.5 h-1.5 rounded-full",r.apify?"bg-green-500":"bg-muted-foreground/30")}),"Apify"]})]}),_.jsxs("section",{className:"mb-8",children:[_.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[_.jsx(Fp,{size:13,className:"text-muted-foreground"}),_.jsx("span",{className:"text-[13px] font-semibold text-muted-foreground",children:"키워드 검색량"})]}),_.jsxs("div",{className:"flex gap-2 mb-4",children:[_.jsx("input",{type:"text",value:e,onChange:U=>t(U.target.value),onKeyDown:U=>U.key==="Enter"&&!i&&w(),placeholder:"키워드 입력 (예: 여름 원피스)",className:"flex-1 h-9 px-3 text-[13px] border border-border rounded-md bg-background focus:outline-none focus:ring-1 focus:ring-ring"}),_.jsx("button",{type:"button",onClick:w,disabled:i||!e.trim(),className:"h-9 px-4 text-[13px] font-medium bg-primary text-primary-foreground rounded-md hover:bg-primary/90 transition-colors disabled:opacity-50 disabled:cursor-not-allowed flex items-center gap-1.5",children:i?_.jsxs(_.Fragment,{children:[_.jsx(F0,{size:12,className:"animate-spin"}),"조회 중"]}):_.jsxs(_.Fragment,{children:[_.jsx(Fp,{size:12}),"검색"]})})]}),s&&_.jsx("div",{className:"flex items-center gap-2 text-[12px] text-red-600 bg-red-50 dark:bg-red-950/20 border border-red-200 dark:border-red-900/50 rounded-lg px-4 py-3 mb-4",children:s}),n&&!s&&_.jsxs("div",{className:"border border-border rounded-lg overflow-hidden",children:[k&&_.jsx("div",{className:"px-5 py-4 border-b border-border bg-muted/30",children:_.jsxs("div",{className:"flex items-center gap-6",children:[_.jsxs("div",{children:[_.jsx("div",{className:"text-[11px] text-muted-foreground mb-0.5",children:"키워드"}),_.jsx("div",{className:"text-[14px] font-semibold",children:k.relKeyword})]}),_.jsxs("div",{children:[_.jsx("div",{className:"text-[11px] text-muted-foreground mb-0.5",children:"PC 검색량"}),_.jsx("div",{className:"text-[14px] font-semibold tabular-nums",children:zp(k.monthlyPcQcCnt)})]}),_.jsxs("div",{children:[_.jsx("div",{className:"text-[11px] text-muted-foreground mb-0.5",children:"모바일 검색량"}),_.jsx("div",{className:"text-[14px] font-semibold tabular-nums",children:zp(k.monthlyMobileQcCnt)})]}),_.jsxs("div",{children:[_.jsx("div",{className:"text-[11px] text-muted-foreground mb-0.5",children:"합계"}),_.jsx("div",{className:"text-[14px] font-semibold tabular-nums",children:(()=>{const U=typeof k.monthlyPcQcCnt=="number"?k.monthlyPcQcCnt:0,F=typeof k.monthlyMobileQcCnt=="number"?k.monthlyMobileQcCnt:0;return(U+F).toLocaleString()})()})]}),_.jsxs("div",{children:[_.jsx("div",{className:"text-[11px] text-muted-foreground mb-0.5",children:"경쟁강도"}),_.jsx("div",{className:Ae("text-[14px] font-semibold",LL(k.compIdx)),children:k.compIdx})]})]})}),R.length>0&&_.jsxs("div",{className:"px-5 py-4 border-b border-border",children:[_.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[_.jsx(ll,{size:12,className:"text-muted-foreground"}),_.jsx("span",{className:"text-[11px] text-muted-foreground font-medium",children:"최근 3개월 트렌드 (월별 상대지수)"})]}),_.jsx(m2e,{data:R}),_.jsxs("div",{className:"flex justify-between text-[10px] text-muted-foreground mt-1",children:[_.jsx("span",{children:(V=R[0])==null?void 0:V.period}),_.jsx("span",{children:(j=R[R.length-1])==null?void 0:j.period})]})]}),E.length>1&&_.jsx("div",{className:"overflow-x-auto",children:_.jsxs("table",{className:"w-full",children:[_.jsx("thead",{children:_.jsxs("tr",{className:"border-b border-border bg-muted/30",children:[_.jsx("th",{className:"py-2 px-3 text-left text-[11px] text-muted-foreground font-medium",children:"연관 키워드"}),_.jsx("th",{className:"py-2 px-3 text-right text-[11px] text-muted-foreground font-medium",children:"PC"}),_.jsx("th",{className:"py-2 px-3 text-right text-[11px] text-muted-foreground font-medium",children:"모바일"}),_.jsx("th",{className:"py-2 px-3 text-right text-[11px] text-muted-foreground font-medium",children:"합계"}),_.jsx("th",{className:"py-2 px-3 text-center text-[11px] text-muted-foreground font-medium",children:"경쟁강도"})]})}),_.jsx("tbody",{children:E.map((U,F)=>_.jsx(y2e,{kw:U,highlight:F%2===1},U.relKeyword))})]})})]}),!n&&!i&&!s&&_.jsxs("div",{className:"border border-dashed border-border rounded-lg p-8 text-center text-muted-foreground text-sm",children:[_.jsx(Hp,{size:24,className:"mx-auto mb-3 opacity-30"}),_.jsx("p",{className:"text-[13px]",children:"키워드를 입력하면 검색량과 트렌드를 조회합니다"})]})]}),_.jsxs("section",{children:[_.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[_.jsx(ll,{size:13,className:"text-muted-foreground"}),_.jsx("span",{className:"text-[13px] font-semibold text-muted-foreground",children:"전문몰 랭킹"}),r&&!r.apify&&_.jsx("span",{className:"text-[11px] text-muted-foreground",children:"· Apify 미설정"})]}),_.jsxs("div",{className:"flex flex-wrap gap-1.5 mb-4",children:[g2e.map(U=>_.jsx("button",{type:"button",onClick:()=>C(U.id),className:Ae("px-3 py-1.5 text-[12px] rounded-md border transition-colors",u===U.id?"border-foreground/50 bg-muted text-foreground font-medium":"border-border text-muted-foreground hover:border-foreground/30 hover:text-foreground"),children:U.label},U.id)),f&&u&&!v&&_.jsxs("button",{type:"button",onClick:D,className:"ml-auto flex items-center gap-1 px-2.5 py-1.5 text-[11px] border border-border rounded-md text-muted-foreground hover:border-foreground/30 hover:text-foreground transition-colors",title:"Apify 재조회 (비용 발생)",children:[_.jsx(F0,{size:11}),"새로고침"]})]}),v&&_.jsxs("div",{className:"flex items-center gap-2 py-8 justify-center text-[12px] text-muted-foreground",children:[_.jsx(F0,{size:13,className:"animate-spin"}),"랭킹 수집 중... (최대 2분 소요)"]}),y&&!v&&_.jsx("div",{className:"flex items-center gap-2 text-[12px] text-red-600 bg-red-50 dark:bg-red-950/20 border border-red-200 dark:border-red-900/50 rounded-lg px-4 py-3",children:y}),(f==null?void 0:f.ranking)&&!v&&_.jsx(x2e,{ranking:f.ranking}),!u&&!v&&_.jsxs("div",{className:"border border-dashed border-border rounded-lg p-8 text-center text-muted-foreground text-sm",children:[_.jsx(ll,{size:24,className:"mx-auto mb-3 opacity-30"}),_.jsx("p",{className:"text-[13px]",children:"플랫폼을 선택하면 실시간 랭킹을 수집합니다"}),_.jsx("p",{className:"text-[11px] mt-1 opacity-70",children:"Apify 기반 · 수집에 1-2분 소요"})]})]}),_.jsx(b2e,{onSelectKeyword:M,onSelectPlatform:N})]})}const w2e=["overview","session","config","orders","products","channels","sourcing","trend","settlement"];function dV(){const r=window.location.hash.slice(1).split("?")[0];return w2e.includes(r)?r:"overview"}function vV(){const r=window.location.hash.slice(1),e=r.indexOf("?");return e===-1?new URLSearchParams:new URLSearchParams(r.slice(e+1))}const T2e=[{type:"item",id:"overview",label:"Overview",icon:QZ},{type:"item",id:"session",label:"Session",icon:ZZ},{type:"item",id:"config",label:"Settings",icon:n$},{type:"section",label:"상품전략"},{type:"item",id:"trend",label:"트렌드",icon:ll},{type:"item",id:"sourcing",label:"소싱",icon:Fp},{type:"item",id:"products",label:"상품",icon:px},{type:"section",label:"판매채널"},{type:"item",id:"channels",label:"채널",icon:e$},{type:"item",id:"orders",label:"주문",icon:nG},{type:"item",id:"settlement",label:"정산",icon:r$}];function C2e(){const[r,e]=q.useState(dV),[t,n]=q.useState(vV);q.useEffect(()=>{const i=()=>{e(dV()),n(vV())};return window.addEventListener("hashchange",i),()=>window.removeEventListener("hashchange",i)},[]);const a=i=>{window.location.hash=i};return _.jsxs(WG,{delayDuration:200,children:[_.jsxs("div",{className:"flex min-h-screen",children:[_.jsxs("nav",{className:"w-[220px] border-r border-border flex flex-col shrink-0 sticky top-0 h-screen overflow-y-auto",children:[_.jsx("div",{className:"px-4 py-4 border-b border-border",children:_.jsxs("h1",{className:"text-[15px] font-semibold flex items-center gap-2",children:[_.jsxs("svg",{width:"17",height:"17",viewBox:"0 0 24 24",fill:"none",stroke:"hsl(var(--primary))",strokeWidth:"2","aria-hidden":"true",children:[_.jsx("path",{d:"M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z"}),_.jsx("polyline",{points:"3.27 6.96 12 12.01 20.73 6.96"}),_.jsx("line",{x1:"12",y1:"22.08",x2:"12",y2:"12"})]}),"shopport",_.jsx("span",{className:"text-[11px] text-muted-foreground font-normal",children:"v0.1.0"})]})}),_.jsx("div",{className:"flex-1 py-2",children:T2e.map(i=>i.type==="section"?_.jsx("div",{className:"px-4 pt-4 pb-1 text-[11px] font-medium text-muted-foreground/60 uppercase tracking-wider",children:i.label},i.label):_.jsxs("button",{type:"button",onClick:()=>a(i.id),className:Ae("flex items-center gap-2.5 w-full px-4 py-2 text-[13px] text-muted-foreground hover:bg-muted hover:text-foreground transition-colors",r===i.id&&"bg-muted text-foreground font-medium"),children:[_.jsx(i.icon,{size:14}),i.label]},i.id))})]}),_.jsx("main",{className:"flex-1 overflow-y-auto",children:_.jsxs("div",{className:"max-w-[1280px] mx-auto p-7",children:[r==="overview"&&_.jsx(Dwe,{}),r==="session"&&_.jsx(Owe,{}),r==="config"&&_.jsx(WQ,{initMode:t.get("mode")==="init"}),r==="orders"&&_.jsx(rte,{}),r==="products"&&_.jsx(Nwe,{}),r==="channels"&&_.jsx(GQ,{}),r==="sourcing"&&_.jsx(p2e,{}),r==="trend"&&_.jsx(S2e,{}),r==="settlement"&&_.jsx(a2e,{})]})})]}),_.jsx(l$,{})]})}const A2e=new Mq({defaultOptions:{queries:{refetchOnWindowFocus:!1,retry:1,staleTime:1e4}}}),OY=document.getElementById("root");if(!OY)throw new Error("Root element not found");Wq.createRoot(OY).render(_.jsx(q.StrictMode,{children:_.jsx(Nq,{client:A2e,children:_.jsx(C2e,{})})}));