Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
 
 
 

100 řádky
981 KiB

  1. (self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[3679],{64183:function(ge,Xt,N){"use strict";var et=N(67294),ot=N(10572),Dt=N(29640),It=N(79360),mt=N(24770),yt=N(27681),ut=function(it,Ut){var Ft={};for(var ft in it)Object.prototype.hasOwnProperty.call(it,ft)&&Ut.indexOf(ft)<0&&(Ft[ft]=it[ft]);if(it!=null&&typeof Object.getOwnPropertySymbols=="function")for(var q=0,ft=Object.getOwnPropertySymbols(it);q<ft.length;q++)Ut.indexOf(ft[q])<0&&Object.prototype.propertyIsEnumerable.call(it,ft[q])&&(Ft[ft[q]]=it[ft[q]]);return Ft},xt=(0,et.forwardRef)(function(it,Ut){var Ft=it.chartRef,ft=it.style,q=ft===void 0?{height:"inherit"}:ft,p=it.className,f=it.loading,J=it.loadingTemplate,K=it.errorTemplate,ht=ut(it,["chartRef","style","className","loading","loadingTemplate","errorTemplate"]),Mt=(0,Dt.Z)(ot.uN,ht),X=Mt.chart,st=Mt.container;return(0,et.useEffect)(function(){(0,It.J)(Ft,X.current)},[X.current]),(0,et.useImperativeHandle)(Ut,function(){return{getChart:function(){return X.current}}}),et.createElement(mt.Z,{errorTemplate:K},f&&et.createElement(yt.Z,{loadingTemplate:J,theme:it.theme}),et.createElement("div",{className:p,style:q,ref:st}))});Xt.Z=xt},78677:function(ge,Xt,N){"use strict";var et=N(67294),ot=N(10572),Dt=N(29640),It=N(79360),mt=N(24770),yt=N(27681),ut=function(it,Ut){var Ft={};for(var ft in it)Object.prototype.hasOwnProperty.call(it,ft)&&Ut.indexOf(ft)<0&&(Ft[ft]=it[ft]);if(it!=null&&typeof Object.getOwnPropertySymbols=="function")for(var q=0,ft=Object.getOwnPropertySymbols(it);q<ft.length;q++)Ut.indexOf(ft[q])<0&&Object.prototype.propertyIsEnumerable.call(it,ft[q])&&(Ft[ft[q]]=it[ft[q]]);return Ft},xt=(0,et.forwardRef)(function(it,Ut){var Ft=it.chartRef,ft=it.style,q=ft===void 0?{height:"inherit"}:ft,p=it.className,f=it.loading,J=it.loadingTemplate,K=it.errorTemplate,ht=ut(it,["chartRef","style","className","loading","loadingTemplate","errorTemplate"]),Mt=(0,Dt.Z)(ot.sg,ht),X=Mt.chart,st=Mt.container;return(0,et.useEffect)(function(){(0,It.J)(Ft,X.current)},[X.current]),(0,et.useImperativeHandle)(Ut,function(){return{getChart:function(){return X.current}}}),et.createElement(mt.Z,{errorTemplate:K},f&&et.createElement(yt.Z,{loadingTemplate:J,theme:it.theme}),et.createElement("div",{className:p,style:q,ref:st}))});Xt.Z=xt},80652:function(ge,Xt,N){"use strict";var et=N(67294),ot=N(10572),Dt=N(29640),It=N(79360),mt=N(24770),yt=N(27681),ut=function(it,Ut){var Ft={};for(var ft in it)Object.prototype.hasOwnProperty.call(it,ft)&&Ut.indexOf(ft)<0&&(Ft[ft]=it[ft]);if(it!=null&&typeof Object.getOwnPropertySymbols=="function")for(var q=0,ft=Object.getOwnPropertySymbols(it);q<ft.length;q++)Ut.indexOf(ft[q])<0&&Object.prototype.propertyIsEnumerable.call(it,ft[q])&&(Ft[ft[q]]=it[ft[q]]);return Ft},xt=(0,et.forwardRef)(function(it,Ut){var Ft=it.chartRef,ft=it.style,q=ft===void 0?{height:"inherit"}:ft,p=it.className,f=it.loading,J=it.loadingTemplate,K=it.errorTemplate,ht=ut(it,["chartRef","style","className","loading","loadingTemplate","errorTemplate"]),Mt=(0,Dt.Z)(ot.x1,ht),X=Mt.chart,st=Mt.container;return(0,et.useEffect)(function(){(0,It.J)(Ft,X.current)},[X.current]),(0,et.useImperativeHandle)(Ut,function(){return{getChart:function(){return X.current}}}),et.createElement(mt.Z,{errorTemplate:K},f&&et.createElement(yt.Z,{loadingTemplate:J,theme:it.theme}),et.createElement("div",{className:p,style:q,ref:st}))});Xt.Z=xt},63430:function(ge,Xt,N){"use strict";var et=N(67294),ot=N(10572),Dt=N(29640),It=N(79360),mt=N(24770),yt=N(27681),ut=function(it,Ut){var Ft={};for(var ft in it)Object.prototype.hasOwnProperty.call(it,ft)&&Ut.indexOf(ft)<0&&(Ft[ft]=it[ft]);if(it!=null&&typeof Object.getOwnPropertySymbols=="function")for(var q=0,ft=Object.getOwnPropertySymbols(it);q<ft.length;q++)Ut.indexOf(ft[q])<0&&Object.prototype.propertyIsEnumerable.call(it,ft[q])&&(Ft[ft[q]]=it[ft[q]]);return Ft},xt=(0,et.forwardRef)(function(it,Ut){var Ft=it.chartRef,ft=it.style,q=ft===void 0?{height:"inherit"}:ft,p=it.className,f=it.loading,J=it.loadingTemplate,K=it.errorTemplate,ht=ut(it,["chartRef","style","className","loading","loadingTemplate","errorTemplate"]),Mt=(0,Dt.Z)(ot.by,ht),X=Mt.chart,st=Mt.container;return(0,et.useEffect)(function(){(0,It.J)(Ft,X.current)},[X.current]),(0,et.useImperativeHandle)(Ut,function(){return{getChart:function(){return X.current}}}),et.createElement(mt.Z,{errorTemplate:K},f&&et.createElement(yt.Z,{loadingTemplate:J,theme:it.theme}),et.createElement("div",{className:p,style:q,ref:st}))});Xt.Z=xt},24770:function(ge,Xt,N){"use strict";var et=N(67294),ot=function(){var It=function(mt,yt){return It=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ut,xt){ut.__proto__=xt}||function(ut,xt){for(var it in xt)Object.prototype.hasOwnProperty.call(xt,it)&&(ut[it]=xt[it])},It(mt,yt)};return function(mt,yt){if(typeof yt!="function"&&yt!==null)throw new TypeError("Class extends value "+String(yt)+" is not a constructor or null");It(mt,yt);function ut(){this.constructor=mt}mt.prototype=yt===null?Object.create(yt):(ut.prototype=yt.prototype,new ut)}}(),Dt=function(It){ot(mt,It);function mt(){var yt=It!==null&&It.apply(this,arguments)||this;return yt.state={hasError:!1},yt.renderError=function(ut){var xt=yt.props.errorTemplate;switch(ut){default:return typeof xt=="function"?xt(ut):xt||et.createElement("h5",null,"\u7EC4\u4EF6\u51FA\u9519\u4E86\uFF0C\u8BF7\u6838\u67E5\u540E\u91CD\u8BD5\uFF1A ",ut.message)}},yt}return mt.getDerivedStateFromError=function(yt){return{hasError:!0,error:yt}},mt.getDerivedStateFromProps=function(yt,ut){return ut.children!==yt.children?{children:yt.children,hasError:!1,error:void 0}:null},mt.prototype.render=function(){return this.state.hasError?this.renderError(this.state.error):et.createElement(et.Fragment,null,this.props.children)},mt}(et.Component);Xt.Z=Dt},29640:function(ge,Xt,N){"use strict";N.d(Xt,{Z:function(){return Y}});var et=N(67294),ot=N(41694),Dt=N(73935),It=N.t(Dt,2),mt=function(){return mt=Object.assign||function(V){for(var G,A=1,I=arguments.length;A<I;A++){G=arguments[A];for(var D in G)Object.prototype.hasOwnProperty.call(G,D)&&(V[D]=G[D])}return V},mt.apply(this,arguments)},yt=function(V,G,A,I){function D(E){return E instanceof A?E:new A(function(Q){Q(E)})}return new(A||(A=Promise))(function(E,Q){function lt(C){try{F(I.next(C))}catch(_){Q(_)}}function P(C){try{F(I.throw(C))}catch(_){Q(_)}}function F(C){C.done?E(C.value):D(C.value).then(lt,P)}F((I=I.apply(V,G||[])).next())})},ut=function(V,G){var A={label:0,sent:function(){if(E[0]&1)throw E[1];return E[1]},trys:[],ops:[]},I,D,E,Q;return Q={next:lt(0),throw:lt(1),return:lt(2)},typeof Symbol=="function"&&(Q[Symbol.iterator]=function(){return this}),Q;function lt(F){return function(C){return P([F,C])}}function P(F){if(I)throw new TypeError("Generator is already executing.");for(;Q&&(Q=0,F[0]&&(A=0)),A;)try{if(I=1,D&&(E=F[0]&2?D.return:F[0]?D.throw||((E=D.return)&&E.call(D),0):D.next)&&!(E=E.call(D,F[1])).done)return E;switch(D=0,E&&(F=[F[0]&2,E.value]),F[0]){case 0:case 1:E=F;break;case 4:return A.label++,{value:F[1],done:!1};case 5:A.label++,D=F[1],F=[0];continue;case 7:F=A.ops.pop(),A.trys.pop();continue;default:if(E=A.trys,!(E=E.length>0&&E[E.length-1])&&(F[0]===6||F[0]===2)){A=0;continue}if(F[0]===3&&(!E||F[1]>E[0]&&F[1]<E[3])){A.label=F[1];break}if(F[0]===6&&A.label<E[1]){A.label=E[1],E=F;break}if(E&&A.label<E[2]){A.label=E[2],A.ops.push(F);break}E[2]&&A.ops.pop(),A.trys.pop();continue}F=G.call(V,A)}catch(C){F=[6,C],D=0}finally{I=E=0}if(F[0]&5)throw F[1];return{value:F[0]?F[1]:void 0,done:!0}}},xt=mt({},It),it=xt.version,Ut=xt.render,Ft=xt.unmountComponentAtNode,ft;try{var q=Number((it||"").split(".")[0]);q>=18&&(ft=xt.createRoot)}catch(V){}function p(V){var G=xt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;G&&typeof G=="object"&&(G.usingClientEntryPoint=V)}var f="__rc_react_root__";function J(V,G){p(!0);var A=G[f]||ft(G);p(!1),A.render(V),G[f]=A}function K(V,G){Ut(V,G)}function ht(V,G){}function Mt(V,G){if(ft){J(V,G);return}K(V,G)}function X(V){return yt(this,void 0,void 0,function(){return ut(this,function(G){return[2,Promise.resolve().then(function(){var A;(A=V[f])===null||A===void 0||A.unmount(),delete V[f]})]})})}function st(V){Ft(V)}function Et(V){}function zt(V){return yt(this,void 0,void 0,function(){return ut(this,function(G){return ft!==void 0?[2,X(V)]:(st(V),[2])})})}var jt=new Map,ee=function(V,G,A){var I=document.createElement("div");return G==="tooltip"&&(I.setAttribute("data-uuid",A),jt.has(A)?I=jt.get(A):jt.set(A,I),I.className="g2-tooltip"),Mt(V,I),I},ye=ee,pt=function(V,G){var A={}.toString;return A.call(V)==="[object ".concat(G,"]")},Pt=function(V){if(!V)return V;var G={};for(var A in V)G[A]=V[A];return G},Rt=function(V){return Object.prototype.toString.call(V).slice(8,-1)},Bt=function(V){if(!V||typeof V!="object")return V;var G;return Array.isArray(V)?G=V.map(function(A){return Bt(A)}):(G={},Object.keys(V).forEach(function(A){return G[A]=Bt(V[A])})),G},Ct=function(V,G){for(var A=V,I=0;I<G.length;I+=1)if(A==null?void 0:A[G[I]])A=A[G[I]];else{A=void 0;break}return A},wt=function(V,G,A){if(!V)return V;var I=V;return G.forEach(function(D,E){E<G.length-1?I=I[D]:I[D]=A}),V},T=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(V){var G=Math.random()*16|0,A=V=="x"?G:G&3|8;return A.toString(16)})},z=function(){return z=Object.assign||function(V){for(var G,A=1,I=arguments.length;A<I;A++){G=arguments[A];for(var D in G)Object.prototype.hasOwnProperty.call(G,D)&&(V[D]=G[D])}return V},z.apply(this,arguments)},bt=function(V,G){var A={};for(var I in V)Object.prototype.hasOwnProperty.call(V,I)&&G.indexOf(I)<0&&(A[I]=V[I]);if(V!=null&&typeof Object.getOwnPropertySymbols=="function")for(var D=0,I=Object.getOwnPropertySymbols(V);D<I.length;D++)G.indexOf(I[D])<0&&Object.prototype.propertyIsEnumerable.call(V,I[D])&&(A[I[D]]=V[I[D]]);return A};function Y(V,G){var A=(0,et.useRef)(),I=(0,et.useRef)(),D=(0,et.useRef)(null),E=G.onReady,Q=G.onEvent,lt=function(_,L){var U;return _===void 0&&(_="image/png"),(U=A.current)===null||U===void 0?void 0:U.chart.canvas.cfg.el.toDataURL(_,L)},P=function(_,L,U){var B;_===void 0&&(_="download"),L===void 0&&(L="image/png");var j=_;_.indexOf(".")===-1&&(j="".concat(_,".").concat(L.split("/")[1]));var nt=(B=A.current)===null||B===void 0?void 0:B.chart.canvas.cfg.el.toDataURL(L,U),Tt=document.createElement("a");return Tt.href=nt,Tt.download=j,document.body.appendChild(Tt),Tt.click(),document.body.removeChild(Tt),Tt=null,j},F=function(_,L,U,B){var j=Ct(_,L);wt(_,L,function(){for(var nt=[],Tt=0;Tt<arguments.length;Tt++)nt[Tt]=arguments[Tt];var Jt=pt(j,"Function")?j.apply(void 0,nt):j;return pt(Jt,"String")||pt(Jt,"Number")||pt(Jt,"HTMLDivElement")?Jt:ye(Jt,U,B)})},C=function(){var _=T();Ct(G,["statistic","content","customHtml"])&&F(G,["statistic","content","customHtml"]),Ct(G,["statistic","title","customHtml"])&&F(G,["statistic","title","customHtml"]),typeof G.tooltip=="object"&&(Ct(G,["tooltip","container"])&&F(G,["tooltip","container"],"tooltip",_),Ct(G,["tooltip","customContent"])&&F(G,["tooltip","customContent"],"tooltip",_))};return(0,et.useEffect)(function(){if(A.current&&!(0,ot.Xy)(I.current,G)){var _=!1;if(I.current){var L=I.current,U=L.data,B=L.value,j=L.percent,nt=bt(L,["data","value","percent"]),Tt=G.data,Jt=G.value,$t=G.percent,ne=bt(G,["data","value","percent"]);_=(0,ot.Xy)(nt,ne)}if(I.current=Bt(G),_&&(0,ot.U2)(G,"chartType")!=="Mix"){var qt="data",Yt=["percent"],fe=Object.keys(G);Yt.forEach(function(Pe){fe.includes(Pe)&&(qt=Pe)}),A.current.changeData((G==null?void 0:G[qt])||[]),A.current.render()}else C(),A.current.update(G)}},[G]),(0,et.useEffect)(function(){if(!D.current)return function(){return null};I.current||(I.current=Bt(G)),C();var _=new V(D.current,z({},G));_.toDataURL=function(U,B){return lt(U,B)},_.downloadImage=function(U,B,j){return P(U,B,j)},_.render(),A.current=Pt(_),E&&E(_);var L=function(U){Q&&Q(_,U)};return _.on("*",L),function(){A.current&&(A.current.destroy(),A.current.off("*",L),A.current=void 0)}},[]),{chart:A,container:D}}},27681:function(ge,Xt,N){"use strict";N.d(Xt,{Z:function(){return p}});var et=N(67294);/*! *****************************************************************************
  2. Copyright (c) Microsoft Corporation. All rights reserved.
  3. Licensed under the Apache License, Version 2.0 (the "License"); you may not use
  4. this file except in compliance with the License. You may obtain a copy of the
  5. License at http://www.apache.org/licenses/LICENSE-2.0
  6. THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  7. KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
  8. WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
  9. MERCHANTABLITY OR NON-INFRINGEMENT.
  10. See the Apache Version 2.0 License for specific language governing permissions
  11. and limitations under the License.
  12. ***************************************************************************** */var ot=function(){return ot=Object.assign||function(J){for(var K,ht=1,Mt=arguments.length;ht<Mt;ht++){K=arguments[ht];for(var X in K)Object.prototype.hasOwnProperty.call(K,X)&&(J[X]=K[X])}return J},ot.apply(this,arguments)};function Dt(f,J){var K={};for(var ht in f)Object.prototype.hasOwnProperty.call(f,ht)&&J.indexOf(ht)<0&&(K[ht]=f[ht]);if(f!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Mt=0,ht=Object.getOwnPropertySymbols(f);Mt<ht.length;Mt++)J.indexOf(ht[Mt])<0&&Object.prototype.propertyIsEnumerable.call(f,ht[Mt])&&(K[ht[Mt]]=f[ht[Mt]]);return K}var It=function(){return Math.random().toString(36).substring(6)},mt=function(f){var J=f.animate,K=f.backgroundColor,ht=f.backgroundOpacity,Mt=f.baseUrl,X=f.children,st=f.foregroundColor,Et=f.foregroundOpacity,zt=f.gradientRatio,jt=f.uniqueKey,ee=f.interval,ye=f.rtl,pt=f.speed,Pt=f.style,Rt=f.title,Bt=Dt(f,["animate","backgroundColor","backgroundOpacity","baseUrl","children","foregroundColor","foregroundOpacity","gradientRatio","uniqueKey","interval","rtl","speed","style","title"]),Ct=jt||It(),wt=Ct+"-diff",T=Ct+"-animated-diff",z=Ct+"-aria",bt=ye?{transform:"scaleX(-1)"}:null,Y="0; "+ee+"; 1",V=pt+"s";return(0,et.createElement)("svg",ot({"aria-labelledby":z,role:"img",style:ot(ot({},Pt),bt)},Bt),Rt?(0,et.createElement)("title",{id:z},Rt):null,(0,et.createElement)("rect",{role:"presentation",x:"0",y:"0",width:"100%",height:"100%",clipPath:"url("+Mt+"#"+wt+")",style:{fill:"url("+Mt+"#"+T+")"}}),(0,et.createElement)("defs",{role:"presentation"},(0,et.createElement)("clipPath",{id:wt},X),(0,et.createElement)("linearGradient",{id:T},(0,et.createElement)("stop",{offset:"0%",stopColor:K,stopOpacity:ht},J&&(0,et.createElement)("animate",{attributeName:"offset",values:-zt+"; "+-zt+"; 1",keyTimes:Y,dur:V,repeatCount:"indefinite"})),(0,et.createElement)("stop",{offset:"50%",stopColor:st,stopOpacity:Et},J&&(0,et.createElement)("animate",{attributeName:"offset",values:-zt/2+"; "+-zt/2+"; "+(1+zt/2),keyTimes:Y,dur:V,repeatCount:"indefinite"})),(0,et.createElement)("stop",{offset:"100%",stopColor:K,stopOpacity:ht},J&&(0,et.createElement)("animate",{attributeName:"offset",values:"0; 0; "+(1+zt),keyTimes:Y,dur:V,repeatCount:"indefinite"})))))};mt.defaultProps={animate:!0,backgroundColor:"#f5f6f7",backgroundOpacity:1,baseUrl:"",foregroundColor:"#eee",foregroundOpacity:1,gradientRatio:2,id:null,interval:.25,rtl:!1,speed:1.2,style:{},title:"Loading..."};var yt=function(f){return f.children?(0,et.createElement)(mt,ot({},f)):(0,et.createElement)(ut,ot({},f))},ut=function(f){return(0,et.createElement)(yt,ot({viewBox:"0 0 476 124"},f),(0,et.createElement)("rect",{x:"48",y:"8",width:"88",height:"6",rx:"3"}),(0,et.createElement)("rect",{x:"48",y:"26",width:"52",height:"6",rx:"3"}),(0,et.createElement)("rect",{x:"0",y:"56",width:"410",height:"6",rx:"3"}),(0,et.createElement)("rect",{x:"0",y:"72",width:"380",height:"6",rx:"3"}),(0,et.createElement)("rect",{x:"0",y:"88",width:"178",height:"6",rx:"3"}),(0,et.createElement)("circle",{cx:"20",cy:"20",r:"20"}))},xt=function(f){return createElement(yt,ot({viewBox:"0 0 400 460"},f),createElement("circle",{cx:"31",cy:"31",r:"15"}),createElement("rect",{x:"58",y:"18",rx:"2",ry:"2",width:"140",height:"10"}),createElement("rect",{x:"58",y:"34",rx:"2",ry:"2",width:"140",height:"10"}),createElement("rect",{x:"0",y:"60",rx:"2",ry:"2",width:"400",height:"400"}))},it=function(f){return createElement(yt,ot({viewBox:"0 0 340 84"},f),createElement("rect",{x:"0",y:"0",width:"67",height:"11",rx:"3"}),createElement("rect",{x:"76",y:"0",width:"140",height:"11",rx:"3"}),createElement("rect",{x:"127",y:"48",width:"53",height:"11",rx:"3"}),createElement("rect",{x:"187",y:"48",width:"72",height:"11",rx:"3"}),createElement("rect",{x:"18",y:"48",width:"100",height:"11",rx:"3"}),createElement("rect",{x:"0",y:"71",width:"37",height:"11",rx:"3"}),createElement("rect",{x:"18",y:"23",width:"140",height:"11",rx:"3"}),createElement("rect",{x:"166",y:"23",width:"173",height:"11",rx:"3"}))},Ut=function(f){return createElement(yt,ot({viewBox:"0 0 400 110"},f),createElement("rect",{x:"0",y:"0",rx:"3",ry:"3",width:"250",height:"10"}),createElement("rect",{x:"20",y:"20",rx:"3",ry:"3",width:"220",height:"10"}),createElement("rect",{x:"20",y:"40",rx:"3",ry:"3",width:"170",height:"10"}),createElement("rect",{x:"0",y:"60",rx:"3",ry:"3",width:"250",height:"10"}),createElement("rect",{x:"20",y:"80",rx:"3",ry:"3",width:"200",height:"10"}),createElement("rect",{x:"20",y:"100",rx:"3",ry:"3",width:"80",height:"10"}))},Ft=function(f){return createElement(yt,ot({viewBox:"0 0 245 125"},f),createElement("circle",{cx:"10",cy:"20",r:"8"}),createElement("rect",{x:"25",y:"15",rx:"5",ry:"5",width:"220",height:"10"}),createElement("circle",{cx:"10",cy:"50",r:"8"}),createElement("rect",{x:"25",y:"45",rx:"5",ry:"5",width:"220",height:"10"}),createElement("circle",{cx:"10",cy:"80",r:"8"}),createElement("rect",{x:"25",y:"75",rx:"5",ry:"5",width:"220",height:"10"}),createElement("circle",{cx:"10",cy:"110",r:"8"}),createElement("rect",{x:"25",y:"105",rx:"5",ry:"5",width:"220",height:"10"}))},ft=yt,q=function(f){var J=f.loadingTemplate,K=f.theme,ht=K===void 0?"light":K,Mt=function(){return J||et.createElement(ft,{viewBox:"0 0 400 180",width:200,height:90,speed:1,backgroundColor:ht==="dark"?"#262626":"#D9D9D9"},et.createElement("rect",{x:"20",y:"5",rx:"0",ry:"0",width:"1",height:"170"}),et.createElement("rect",{x:"20",y:"175",rx:"0",ry:"0",width:"360",height:"1"}),et.createElement("rect",{x:"40",y:"75",rx:"0",ry:"0",width:"35",height:"100"}),et.createElement("rect",{x:"80",y:"125",rx:"0",ry:"0",width:"35",height:"50"}),et.createElement("rect",{x:"120",y:"105",rx:"0",ry:"0",width:"35",height:"70"}),et.createElement("rect",{x:"160",y:"35",rx:"0",ry:"0",width:"35",height:"140"}),et.createElement("rect",{x:"200",y:"55",rx:"0",ry:"0",width:"35",height:"120"}),et.createElement("rect",{x:"240",y:"15",rx:"0",ry:"0",width:"35",height:"160"}),et.createElement("rect",{x:"280",y:"135",rx:"0",ry:"0",width:"35",height:"40"}),et.createElement("rect",{x:"320",y:"85",rx:"0",ry:"0",width:"35",height:"90"}))};return et.createElement("div",{className:"charts-loading-container",style:{position:"absolute",width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center",left:0,top:0,zIndex:99,backgroundColor:ht==="dark"?"rgb(20, 20, 20)":"rgb(255, 255, 255)"}},Mt())},p=q},79360:function(ge,Xt,N){"use strict";N.d(Xt,{J:function(){return ot}});var et=N(41694),ot=function(Dt,It){!Dt||((0,et.mf)(Dt)?Dt(It):Dt.current=It)}},90494:function(ge,Xt){"use strict";var N="*",et=function(){function ot(){this._events={}}return ot.prototype.on=function(Dt,It,mt){return this._events[Dt]||(this._events[Dt]=[]),this._events[Dt].push({callback:It,once:!!mt}),this},ot.prototype.once=function(Dt,It){return this.on(Dt,It,!0)},ot.prototype.emit=function(Dt){for(var It=this,mt=[],yt=1;yt<arguments.length;yt++)mt[yt-1]=arguments[yt];var ut=this._events[Dt]||[],xt=this._events[N]||[],it=function(Ut){for(var Ft=Ut.length,ft=0;ft<Ft;ft++)if(!!Ut[ft]){var q=Ut[ft],p=q.callback,f=q.once;f&&(Ut.splice(ft,1),Ut.length===0&&delete It._events[Dt],Ft--,ft--),p.apply(It,mt)}};it(ut),it(xt)},ot.prototype.off=function(Dt,It){if(!Dt)this._events={};else if(!It)delete this._events[Dt];else{for(var mt=this._events[Dt]||[],yt=mt.length,ut=0;ut<yt;ut++)mt[ut].callback===It&&(mt.splice(ut,1),yt--,ut--);mt.length===0&&delete this._events[Dt]}return this},ot.prototype.getEvents=function(){return this._events},ot}();Xt.Z=et},2667:function(ge,Xt,N){"use strict";var et=N(65353),ot=N(90494),Dt=N(77341),It=function(mt){(0,et.ZT)(yt,mt);function yt(ut){var xt=mt.call(this)||this;xt.destroyed=!1;var it=xt.getDefaultCfg();return xt.cfg=(0,Dt.CD)(it,ut),xt}return yt.prototype.getDefaultCfg=function(){return{}},yt.prototype.get=function(ut){return this.cfg[ut]},yt.prototype.set=function(ut,xt){this.cfg[ut]=xt},yt.prototype.destroy=function(){this.cfg={destroyed:!0},this.off(),this.destroyed=!0},yt}(ot.Z);Xt.Z=It},96298:function(ge,Xt,N){"use strict";N.d(Xt,{Z:function(){return nn}});var et=N(65353),ot=N(43631),Dt=N(37153),It=N(77341),mt=N(41694),yt=0,ut=0,xt=0,it=1e3,Ut,Ft,ft=0,q=0,p=0,f=typeof performance=="object"&&performance.now?performance:Date,J=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(W){setTimeout(W,17)};function K(){return q||(J(ht),q=f.now()+p)}function ht(){q=0}function Mt(){this._call=this._time=this._next=null}Mt.prototype=X.prototype={constructor:Mt,restart:function(W,R,$){if(typeof W!="function")throw new TypeError("callback is not a function");$=($==null?K():+$)+(R==null?0:+R),!this._next&&Ft!==this&&(Ft?Ft._next=this:Ut=this,Ft=this),this._call=W,this._time=$,ee()},stop:function(){this._call&&(this._call=null,this._time=Infinity,ee())}};function X(W,R,$){var dt=new Mt;return dt.restart(W,R,$),dt}function st(){K(),++yt;for(var W=Ut,R;W;)(R=q-W._time)>=0&&W._call.call(null,R),W=W._next;--yt}function Et(){q=(ft=f.now())+p,yt=ut=0;try{st()}finally{yt=0,jt(),q=0}}function zt(){var W=f.now(),R=W-ft;R>it&&(p-=R,ft=W)}function jt(){for(var W,R=Ut,$,dt=Infinity;R;)R._call?(dt>R._time&&(dt=R._time),W=R,R=R._next):($=R._next,R._next=null,R=W?W._next=$:Ut=$);Ft=W,ee(dt)}function ee(W){if(!yt){ut&&(ut=clearTimeout(ut));var R=W-q;R>24?(W<Infinity&&(ut=setTimeout(Et,W-f.now()-p)),xt&&(xt=clearInterval(xt))):(xt||(ft=f.now(),xt=setInterval(zt,it)),yt=1,J(Et))}}function ye(W,R,$){W.prototype=R.prototype=$,$.constructor=W}function pt(W,R){var $=Object.create(W.prototype);for(var dt in R)$[dt]=R[dt];return $}function Pt(){}var Rt=.7,Bt=1/Rt,Ct="\\s*([+-]?\\d+)\\s*",wt="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",T="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",z=/^#([0-9a-f]{3,8})$/,bt=new RegExp("^rgb\\("+[Ct,Ct,Ct]+"\\)$"),Y=new RegExp("^rgb\\("+[T,T,T]+"\\)$"),V=new RegExp("^rgba\\("+[Ct,Ct,Ct,wt]+"\\)$"),G=new RegExp("^rgba\\("+[T,T,T,wt]+"\\)$"),A=new RegExp("^hsl\\("+[wt,T,T]+"\\)$"),I=new RegExp("^hsla\\("+[wt,T,T,wt]+"\\)$"),D={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};ye(Pt,P,{copy:function(W){return Object.assign(new this.constructor,this,W)},displayable:function(){return this.rgb().displayable()},hex:E,formatHex:E,formatHsl:Q,formatRgb:lt,toString:lt});function E(){return this.rgb().formatHex()}function Q(){return Jt(this).formatHsl()}function lt(){return this.rgb().formatRgb()}function P(W){var R,$;return W=(W+"").trim().toLowerCase(),(R=z.exec(W))?($=R[1].length,R=parseInt(R[1],16),$===6?F(R):$===3?new U(R>>8&15|R>>4&240,R>>4&15|R&240,(R&15)<<4|R&15,1):$===8?C(R>>24&255,R>>16&255,R>>8&255,(R&255)/255):$===4?C(R>>12&15|R>>8&240,R>>8&15|R>>4&240,R>>4&15|R&240,((R&15)<<4|R&15)/255):null):(R=bt.exec(W))?new U(R[1],R[2],R[3],1):(R=Y.exec(W))?new U(R[1]*255/100,R[2]*255/100,R[3]*255/100,1):(R=V.exec(W))?C(R[1],R[2],R[3],R[4]):(R=G.exec(W))?C(R[1]*255/100,R[2]*255/100,R[3]*255/100,R[4]):(R=A.exec(W))?Tt(R[1],R[2]/100,R[3]/100,1):(R=I.exec(W))?Tt(R[1],R[2]/100,R[3]/100,R[4]):D.hasOwnProperty(W)?F(D[W]):W==="transparent"?new U(NaN,NaN,NaN,0):null}function F(W){return new U(W>>16&255,W>>8&255,W&255,1)}function C(W,R,$,dt){return dt<=0&&(W=R=$=NaN),new U(W,R,$,dt)}function _(W){return W instanceof Pt||(W=P(W)),W?(W=W.rgb(),new U(W.r,W.g,W.b,W.opacity)):new U}function L(W,R,$,dt){return arguments.length===1?_(W):new U(W,R,$,dt==null?1:dt)}function U(W,R,$,dt){this.r=+W,this.g=+R,this.b=+$,this.opacity=+dt}ye(U,L,pt(Pt,{brighter:function(W){return W=W==null?Bt:Math.pow(Bt,W),new U(this.r*W,this.g*W,this.b*W,this.opacity)},darker:function(W){return W=W==null?Rt:Math.pow(Rt,W),new U(this.r*W,this.g*W,this.b*W,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:B,formatHex:B,formatRgb:j,toString:j}));function B(){return"#"+nt(this.r)+nt(this.g)+nt(this.b)}function j(){var W=this.opacity;return W=isNaN(W)?1:Math.max(0,Math.min(1,W)),(W===1?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(W===1?")":", "+W+")")}function nt(W){return W=Math.max(0,Math.min(255,Math.round(W)||0)),(W<16?"0":"")+W.toString(16)}function Tt(W,R,$,dt){return dt<=0?W=R=$=NaN:$<=0||$>=1?W=R=NaN:R<=0&&(W=NaN),new ne(W,R,$,dt)}function Jt(W){if(W instanceof ne)return new ne(W.h,W.s,W.l,W.opacity);if(W instanceof Pt||(W=P(W)),!W)return new ne;if(W instanceof ne)return W;W=W.rgb();var R=W.r/255,$=W.g/255,dt=W.b/255,Vt=Math.min(R,$,dt),oe=Math.max(R,$,dt),he=NaN,le=oe-Vt,ke=(oe+Vt)/2;return le?(R===oe?he=($-dt)/le+($<dt)*6:$===oe?he=(dt-R)/le+2:he=(R-$)/le+4,le/=ke<.5?oe+Vt:2-oe-Vt,he*=60):le=ke>0&&ke<1?0:he,new ne(he,le,ke,W.opacity)}function $t(W,R,$,dt){return arguments.length===1?Jt(W):new ne(W,R,$,dt==null?1:dt)}function ne(W,R,$,dt){this.h=+W,this.s=+R,this.l=+$,this.opacity=+dt}ye(ne,$t,pt(Pt,{brighter:function(W){return W=W==null?Bt:Math.pow(Bt,W),new ne(this.h,this.s,this.l*W,this.opacity)},darker:function(W){return W=W==null?Rt:Math.pow(Rt,W),new ne(this.h,this.s,this.l*W,this.opacity)},rgb:function(){var W=this.h%360+(this.h<0)*360,R=isNaN(W)||isNaN(this.s)?0:this.s,$=this.l,dt=$+($<.5?$:1-$)*R,Vt=2*$-dt;return new U(qt(W>=240?W-240:W+120,Vt,dt),qt(W,Vt,dt),qt(W<120?W+240:W-120,Vt,dt),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var W=this.opacity;return W=isNaN(W)?1:Math.max(0,Math.min(1,W)),(W===1?"hsl(":"hsla(")+(this.h||0)+", "+(this.s||0)*100+"%, "+(this.l||0)*100+"%"+(W===1?")":", "+W+")")}}));function qt(W,R,$){return(W<60?R+($-R)*W/60:W<180?$:W<240?R+($-R)*(240-W)/60:R)*255}function Yt(W,R,$,dt,Vt){var oe=W*W,he=oe*W;return((1-3*W+3*oe-he)*R+(4-6*oe+3*he)*$+(1+3*W+3*oe-3*he)*dt+he*Vt)/6}function fe(W){var R=W.length-1;return function($){var dt=$<=0?$=0:$>=1?($=1,R-1):Math.floor($*R),Vt=W[dt],oe=W[dt+1],he=dt>0?W[dt-1]:2*Vt-oe,le=dt<R-1?W[dt+2]:2*oe-Vt;return Yt(($-dt/R)*R,he,Vt,oe,le)}}function Pe(W){var R=W.length;return function($){var dt=Math.floor((($%=1)<0?++$:$)*R),Vt=W[(dt+R-1)%R],oe=W[dt%R],he=W[(dt+1)%R],le=W[(dt+2)%R];return Yt(($-dt/R)*R,Vt,oe,he,le)}}var Oe=function(W){return function(){return W}};function Be(W,R){return function($){return W+$*R}}function cr(W,R,$){return W=Math.pow(W,$),R=Math.pow(R,$)-W,$=1/$,function(dt){return Math.pow(W+dt*R,$)}}function Er(W,R){var $=R-W;return $?Be(W,$>180||$<-180?$-360*Math.round($/360):$):constant(isNaN(W)?R:W)}function _r(W){return(W=+W)==1?tt:function(R,$){return $-R?cr(R,$,W):Oe(isNaN(R)?$:R)}}function tt(W,R){var $=R-W;return $?Be(W,$):Oe(isNaN(W)?R:W)}var Z=function W(R){var $=_r(R);function dt(Vt,oe){var he=$((Vt=L(Vt)).r,(oe=L(oe)).r),le=$(Vt.g,oe.g),ke=$(Vt.b,oe.b),ir=tt(Vt.opacity,oe.opacity);return function(gr){return Vt.r=he(gr),Vt.g=le(gr),Vt.b=ke(gr),Vt.opacity=ir(gr),Vt+""}}return dt.gamma=W,dt}(1);function vt(W){return function(R){var $=R.length,dt=new Array($),Vt=new Array($),oe=new Array($),he,le;for(he=0;he<$;++he)le=L(R[he]),dt[he]=le.r||0,Vt[he]=le.g||0,oe[he]=le.b||0;return dt=W(dt),Vt=W(Vt),oe=W(oe),le.opacity=1,function(ke){return le.r=dt(ke),le.g=Vt(ke),le.b=oe(ke),le+""}}}var St=vt(fe),Ot=vt(Pe);function Wt(W,R){R||(R=[]);var $=W?Math.min(R.length,W.length):0,dt=R.slice(),Vt;return function(oe){for(Vt=0;Vt<$;++Vt)dt[Vt]=W[Vt]*(1-oe)+R[Vt]*oe;return dt}}function Ht(W){return ArrayBuffer.isView(W)&&!(W instanceof DataView)}function Kt(W,R){return(Ht(R)?Wt:Lt)(W,R)}function Lt(W,R){var $=R?R.length:0,dt=W?Math.min($,W.length):0,Vt=new Array(dt),oe=new Array($),he;for(he=0;he<dt;++he)Vt[he]=ae(W[he],R[he]);for(;he<$;++he)oe[he]=R[he];return function(le){for(he=0;he<dt;++he)oe[he]=Vt[he](le);return oe}}function re(W,R){var $=new Date;return W=+W,R=+R,function(dt){return $.setTime(W*(1-dt)+R*dt),$}}function Zt(W,R){return W=+W,R=+R,function($){return W*(1-$)+R*$}}function me(W,R){var $={},dt={},Vt;(W===null||typeof W!="object")&&(W={}),(R===null||typeof R!="object")&&(R={});for(Vt in R)Vt in W?$[Vt]=ae(W[Vt],R[Vt]):dt[Vt]=R[Vt];return function(oe){for(Vt in $)dt[Vt]=$[Vt](oe);return dt}}var Se=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,se=new RegExp(Se.source,"g");function we(W){return function(){return W}}function Ae(W){return function(R){return W(R)+""}}function Ce(W,R){var $=Se.lastIndex=se.lastIndex=0,dt,Vt,oe,he=-1,le=[],ke=[];for(W=W+"",R=R+"";(dt=Se.exec(W))&&(Vt=se.exec(R));)(oe=Vt.index)>$&&(oe=R.slice($,oe),le[he]?le[he]+=oe:le[++he]=oe),(dt=dt[0])===(Vt=Vt[0])?le[he]?le[he]+=Vt:le[++he]=Vt:(le[++he]=null,ke.push({i:he,x:Zt(dt,Vt)})),$=se.lastIndex;return $<R.length&&(oe=R.slice($),le[he]?le[he]+=oe:le[++he]=oe),le.length<2?ke[0]?Ae(ke[0].x):we(R):(R=ke.length,function(ir){for(var gr=0,Dr;gr<R;++gr)le[(Dr=ke[gr]).i]=Dr.x(ir);return le.join("")})}function ae(W,R){var $=typeof R,dt;return R==null||$==="boolean"?Oe(R):($==="number"?Zt:$==="string"?(dt=P(R))?(R=dt,Z):Ce:R instanceof P?Z:R instanceof Date?re:Ht(R)?Wt:Array.isArray(R)?Lt:typeof R.valueOf!="function"&&typeof R.toString!="function"||isNaN(R)?me:Zt)(W,R)}var Ie=N(97492),Le=N(47575),He=function(W){return["fill","stroke","fillStyle","strokeStyle"].includes(W)},ze=function(W){return/^[r,R,L,l]{1}[\s]*\(/.test(W)},$e=[1,0,0,0,1,0,0,0,1];function je(W,R,$){var dt={},Vt=R.fromAttrs,oe=R.toAttrs;if(!W.destroyed){var he;for(var le in oe)if(!(0,mt.Xy)(Vt[le],oe[le]))if(le==="path"){var ke=oe[le],ir=Vt[le];ke.length>ir.length?(ke=Le.parsePathString(oe[le]),ir=Le.parsePathString(Vt[le]),ir=Le.fillPathByDiff(ir,ke),ir=Le.formatPath(ir,ke),R.fromAttrs.path=ir,R.toAttrs.path=ke):R.pathFormatted||(ke=Le.parsePathString(oe[le]),ir=Le.parsePathString(Vt[le]),ir=Le.formatPath(ir,ke),R.fromAttrs.path=ir,R.toAttrs.path=ke,R.pathFormatted=!0),dt[le]=[];for(var gr=0;gr<ke.length;gr++){for(var Dr=ke[gr],mr=ir[gr],On=[],Xr=0;Xr<Dr.length;Xr++)(0,mt.hj)(Dr[Xr])&&mr&&(0,mt.hj)(mr[Xr])?(he=ae(mr[Xr],Dr[Xr]),On.push(he($))):On.push(Dr[Xr]);dt[le].push(On)}}else if(le==="matrix"){var Ia=Kt(Vt[le]||$e,oe[le]||$e),yi=Ia($);dt[le]=yi}else He(le)&&ze(oe[le])?dt[le]=oe[le]:(0,mt.mf)(oe[le])||(he=ae(Vt[le],oe[le]),dt[le]=he($));W.attr(dt)}}function yr(W,R,$){var dt=R.startTime,Vt=R.delay;if($<dt+Vt||R._paused)return!1;var oe,he=R.duration,le=R.easing,ke=(0,Ie._)(le);if($=$-dt-R.delay,R.repeat)oe=$%he/he,oe=ke(oe);else if(oe=$/he,oe<1)oe=ke(oe);else return R.onFrame?W.attr(R.onFrame(1)):W.attr(R.toAttrs),!0;if(R.onFrame){var ir=R.onFrame(oe);W.attr(ir)}else je(W,R,oe);return!1}var wr=function(){function W(R){this.animators=[],this.current=0,this.timer=null,this.canvas=R}return W.prototype.initTimer=function(){var R=this,$=!1,dt,Vt,oe;this.timer=X(function(he){if(R.current=he,R.animators.length>0){for(var le=R.animators.length-1;le>=0;le--){if(dt=R.animators[le],dt.destroyed){R.removeAnimator(le);continue}if(!dt.isAnimatePaused()){Vt=dt.get("animations");for(var ke=Vt.length-1;ke>=0;ke--)oe=Vt[ke],$=yr(dt,oe,he),$&&(Vt.splice(ke,1),$=!1,oe.callback&&oe.callback())}Vt.length===0&&R.removeAnimator(le)}var ir=R.canvas.get("autoDraw");ir||R.canvas.draw()}})},W.prototype.addAnimator=function(R){this.animators.push(R)},W.prototype.removeAnimator=function(R){this.animators.splice(R,1)},W.prototype.isAnimating=function(){return!!this.animators.length},W.prototype.stop=function(){this.timer&&this.timer.stop()},W.prototype.stopAllAnimations=function(R){R===void 0&&(R=!0),this.animators.forEach(function($){$.stopAnimate(R)}),this.animators=[],this.canvas.draw()},W.prototype.getTime=function(){return this.current},W}(),Sr=wr,cn=N(89473),yn=40,mn=0,qn=":",tn=["mousedown","mouseup","dblclick","mouseout","mouseover","mousemove","mouseleave","mouseenter","touchstart","touchmove","touchend","dragenter","dragover","dragleave","drop","contextmenu","mousewheel"];function Yr(W,R){for(var $ in W)if(W.hasOwnProperty($)&&$.indexOf(qn+R)>=0)return!0;return!1}function en(W,R,$){$.name=R,$.target=W,$.currentTarget=W,$.delegateTarget=W,W.emit(R,$)}function rn(W,R,$){if($.bubbles){var dt=void 0,Vt=!1;if(R==="mouseenter"?(dt=$.fromShape,Vt=!0):R==="mouseleave"&&(Vt=!0,dt=$.toShape),W.isCanvas()&&Vt)return;if(dt&&(0,It.UY)(W,dt)){$.bubbles=!1;return}$.name=R,$.currentTarget=W,$.delegateTarget=W,W.emit(R,$)}}var fn=function(){function W(R){var $=this;this.draggingShape=null,this.dragging=!1,this.currentShape=null,this.mousedownShape=null,this.mousedownPoint=null,this._eventCallback=function(dt){var Vt=dt.type;$._triggerEvent(Vt,dt)},this._onDocumentMove=function(dt){var Vt=$.canvas,oe=Vt.get("el");if(oe!==dt.target&&($.dragging||$.currentShape)){var he=$._getPointInfo(dt);$.dragging&&$._emitEvent("drag",dt,he,$.draggingShape)}},this._onDocumentMouseUp=function(dt){var Vt=$.canvas,oe=Vt.get("el");if(oe!==dt.target&&$.dragging){var he=$._getPointInfo(dt);$.draggingShape&&$._emitEvent("drop",dt,he,null),$._emitEvent("dragend",dt,he,$.draggingShape),$._afterDrag($.draggingShape,he,dt)}},this.canvas=R.canvas}return W.prototype.init=function(){this._bindEvents()},W.prototype._bindEvents=function(){var R=this,$=this.canvas.get("el");(0,It.S6)(tn,function(dt){$.addEventListener(dt,R._eventCallback)}),document&&(document.addEventListener("mousemove",this._onDocumentMove),document.addEventListener("mouseup",this._onDocumentMouseUp))},W.prototype._clearEvents=function(){var R=this,$=this.canvas.get("el");(0,It.S6)(tn,function(dt){$.removeEventListener(dt,R._eventCallback)}),document&&(document.removeEventListener("mousemove",this._onDocumentMove),document.removeEventListener("mouseup",this._onDocumentMouseUp))},W.prototype._getEventObj=function(R,$,dt,Vt,oe,he){var le=new cn.Z(R,$);return le.fromShape=oe,le.toShape=he,le.x=dt.x,le.y=dt.y,le.clientX=dt.clientX,le.clientY=dt.clientY,le.propagationPath.push(Vt),le},W.prototype._getShape=function(R,$){return this.canvas.getShape(R.x,R.y,$)},W.prototype._getPointInfo=function(R){var $=this.canvas,dt=$.getClientByEvent(R),Vt=$.getPointByEvent(R);return{x:Vt.x,y:Vt.y,clientX:dt.x,clientY:dt.y}},W.prototype._triggerEvent=function(R,$){var dt=this._getPointInfo($),Vt=this._getShape(dt,$),oe=this["_on"+R],he=!1;if(oe)oe.call(this,dt,Vt,$);else{var le=this.currentShape;R==="mouseenter"||R==="dragenter"||R==="mouseover"?(this._emitEvent(R,$,dt,null,null,Vt),Vt&&this._emitEvent(R,$,dt,Vt,null,Vt),R==="mouseenter"&&this.draggingShape&&this._emitEvent("dragenter",$,dt,null)):R==="mouseleave"||R==="dragleave"||R==="mouseout"?(he=!0,le&&this._emitEvent(R,$,dt,le,le,null),this._emitEvent(R,$,dt,null,le,null),R==="mouseleave"&&this.draggingShape&&this._emitEvent("dragleave",$,dt,null)):this._emitEvent(R,$,dt,Vt,null,null)}if(he||(this.currentShape=Vt),Vt&&!Vt.get("destroyed")){var ke=this.canvas,ir=ke.get("el");ir.style.cursor=Vt.attr("cursor")||ke.get("cursor")}},W.prototype._onmousedown=function(R,$,dt){dt.button===mn&&(this.mousedownShape=$,this.mousedownPoint=R,this.mousedownTimeStamp=dt.timeStamp),this._emitEvent("mousedown",dt,R,$,null,null)},W.prototype._emitMouseoverEvents=function(R,$,dt,Vt){var oe=this.canvas.get("el");dt!==Vt&&(dt&&(this._emitEvent("mouseout",R,$,dt,dt,Vt),this._emitEvent("mouseleave",R,$,dt,dt,Vt),(!Vt||Vt.get("destroyed"))&&(oe.style.cursor=this.canvas.get("cursor"))),Vt&&(this._emitEvent("mouseover",R,$,Vt,dt,Vt),this._emitEvent("mouseenter",R,$,Vt,dt,Vt)))},W.prototype._emitDragoverEvents=function(R,$,dt,Vt,oe){Vt?(Vt!==dt&&(dt&&this._emitEvent("dragleave",R,$,dt,dt,Vt),this._emitEvent("dragenter",R,$,Vt,dt,Vt)),oe||this._emitEvent("dragover",R,$,Vt)):dt&&this._emitEvent("dragleave",R,$,dt,dt,Vt),oe&&this._emitEvent("dragover",R,$,Vt)},W.prototype._afterDrag=function(R,$,dt){R&&(R.set("capture",!0),this.draggingShape=null),this.dragging=!1;var Vt=this._getShape($,dt);Vt!==R&&this._emitMouseoverEvents(dt,$,R,Vt),this.currentShape=Vt},W.prototype._onmouseup=function(R,$,dt){if(dt.button===mn){var Vt=this.draggingShape;this.dragging?(Vt&&this._emitEvent("drop",dt,R,$),this._emitEvent("dragend",dt,R,Vt),this._afterDrag(Vt,R,dt)):(this._emitEvent("mouseup",dt,R,$),$===this.mousedownShape&&this._emitEvent("click",dt,R,$),this.mousedownShape=null,this.mousedownPoint=null)}},W.prototype._ondragover=function(R,$,dt){dt.preventDefault();var Vt=this.currentShape;this._emitDragoverEvents(dt,R,Vt,$,!0)},W.prototype._onmousemove=function(R,$,dt){var Vt=this.canvas,oe=this.currentShape,he=this.draggingShape;if(this.dragging)he&&this._emitDragoverEvents(dt,R,oe,$,!1),this._emitEvent("drag",dt,R,he);else{var le=this.mousedownPoint;if(le){var ke=this.mousedownShape,ir=dt.timeStamp,gr=ir-this.mousedownTimeStamp,Dr=le.clientX-R.clientX,mr=le.clientY-R.clientY,On=Dr*Dr+mr*mr;gr>120||On>yn?ke&&ke.get("draggable")?(he=this.mousedownShape,he.set("capture",!1),this.draggingShape=he,this.dragging=!0,this._emitEvent("dragstart",dt,R,he),this.mousedownShape=null,this.mousedownPoint=null):!ke&&Vt.get("draggable")?(this.dragging=!0,this._emitEvent("dragstart",dt,R,null),this.mousedownShape=null,this.mousedownPoint=null):(this._emitMouseoverEvents(dt,R,oe,$),this._emitEvent("mousemove",dt,R,$)):(this._emitMouseoverEvents(dt,R,oe,$),this._emitEvent("mousemove",dt,R,$))}else this._emitMouseoverEvents(dt,R,oe,$),this._emitEvent("mousemove",dt,R,$)}},W.prototype._emitEvent=function(R,$,dt,Vt,oe,he){var le=this._getEventObj(R,$,dt,Vt,oe,he);if(Vt){le.shape=Vt,en(Vt,R,le);for(var ke=Vt.getParent();ke;)ke.emitDelegation(R,le),le.propagationStopped||rn(ke,R,le),le.propagationPath.push(ke),ke=ke.getParent()}else{var ir=this.canvas;en(ir,R,le)}},W.prototype.destroy=function(){this._clearEvents(),this.canvas=null,this.currentShape=null,this.draggingShape=null,this.mousedownPoint=null,this.mousedownShape=null,this.mousedownTimeStamp=null},W}(),Kn=fn,xn="px",jn=(0,ot.qY)(),_a=jn&&jn.name==="firefox",Fa=function(W){(0,et.ZT)(R,W);function R($){var dt=W.call(this,$)||this;return dt.initContainer(),dt.initDom(),dt.initEvents(),dt.initTimeline(),dt}return R.prototype.getDefaultCfg=function(){var $=W.prototype.getDefaultCfg.call(this);return $.cursor="default",$.supportCSSTransform=!1,$},R.prototype.initContainer=function(){var $=this.get("container");(0,It.HD)($)&&($=document.getElementById($),this.set("container",$))},R.prototype.initDom=function(){var $=this.createDom();this.set("el",$);var dt=this.get("container");dt.appendChild($),this.setDOMSize(this.get("width"),this.get("height"))},R.prototype.initEvents=function(){var $=new Kn({canvas:this});$.init(),this.set("eventController",$)},R.prototype.initTimeline=function(){var $=new Sr(this);this.set("timeline",$)},R.prototype.setDOMSize=function($,dt){var Vt=this.get("el");It.jU&&(Vt.style.width=$+xn,Vt.style.height=dt+xn)},R.prototype.changeSize=function($,dt){this.setDOMSize($,dt),this.set("width",$),this.set("height",dt),this.onCanvasChange("changeSize")},R.prototype.getRenderer=function(){return this.get("renderer")},R.prototype.getCursor=function(){return this.get("cursor")},R.prototype.setCursor=function($){this.set("cursor",$);var dt=this.get("el");It.jU&&dt&&(dt.style.cursor=$)},R.prototype.getPointByEvent=function($){var dt=this.get("supportCSSTransform");if(dt){if(_a&&!(0,It.kK)($.layerX)&&$.layerX!==$.offsetX)return{x:$.layerX,y:$.layerY};if(!(0,It.kK)($.offsetX))return{x:$.offsetX,y:$.offsetY}}var Vt=this.getClientByEvent($),oe=Vt.x,he=Vt.y;return this.getPointByClient(oe,he)},R.prototype.getClientByEvent=function($){var dt=$;return $.touches&&($.type==="touchend"?dt=$.changedTouches[0]:dt=$.touches[0]),{x:dt.clientX,y:dt.clientY}},R.prototype.getPointByClient=function($,dt){var Vt=this.get("el"),oe=Vt.getBoundingClientRect();return{x:$-oe.left,y:dt-oe.top}},R.prototype.getClientByPoint=function($,dt){var Vt=this.get("el"),oe=Vt.getBoundingClientRect();return{x:$+oe.left,y:dt+oe.top}},R.prototype.draw=function(){},R.prototype.removeDom=function(){var $=this.get("el");$.parentNode.removeChild($)},R.prototype.clearEvents=function(){var $=this.get("eventController");$.destroy()},R.prototype.isCanvas=function(){return!0},R.prototype.getParent=function(){return null},R.prototype.destroy=function(){var $=this.get("timeline");this.get("destroyed")||(this.clear(),$&&$.stop(),this.clearEvents(),this.removeDom(),W.prototype.destroy.call(this))},R}(Dt.Z),nn=Fa},37153:function(ge,Xt,N){"use strict";var et=N(65353),ot=N(29881),Dt=N(77341),It={},mt="_INDEX";function yt(ft,q){if(ft.set("canvas",q),ft.isGroup()){var p=ft.get("children");p.length&&p.forEach(function(f){yt(f,q)})}}function ut(ft,q){if(ft.set("timeline",q),ft.isGroup()){var p=ft.get("children");p.length&&p.forEach(function(f){ut(f,q)})}}function xt(ft,q){var p=ft.getChildren();return p.indexOf(q)>=0}function it(ft,q,p){p===void 0&&(p=!0),p?q.destroy():(q.set("parent",null),q.set("canvas",null)),(0,Dt.As)(ft.getChildren(),q)}function Ut(ft){return function(q,p){var f=ft(q,p);return f===0?q[mt]-p[mt]:f}}var Ft=function(ft){(0,et.ZT)(q,ft);function q(){return ft!==null&&ft.apply(this,arguments)||this}return q.prototype.isCanvas=function(){return!1},q.prototype.getBBox=function(){var p=Infinity,f=-Infinity,J=Infinity,K=-Infinity,ht=this.getChildren().filter(function(X){return X.get("visible")&&(!X.isGroup()||X.isGroup()&&X.getChildren().length>0)});ht.length>0?(0,Dt.S6)(ht,function(X){var st=X.getBBox(),Et=st.minX,zt=st.maxX,jt=st.minY,ee=st.maxY;Et<p&&(p=Et),zt>f&&(f=zt),jt<J&&(J=jt),ee>K&&(K=ee)}):(p=0,f=0,J=0,K=0);var Mt={x:p,y:J,minX:p,minY:J,maxX:f,maxY:K,width:f-p,height:K-J};return Mt},q.prototype.getCanvasBBox=function(){var p=Infinity,f=-Infinity,J=Infinity,K=-Infinity,ht=this.getChildren().filter(function(X){return X.get("visible")&&(!X.isGroup()||X.isGroup()&&X.getChildren().length>0)});ht.length>0?(0,Dt.S6)(ht,function(X){var st=X.getCanvasBBox(),Et=st.minX,zt=st.maxX,jt=st.minY,ee=st.maxY;Et<p&&(p=Et),zt>f&&(f=zt),jt<J&&(J=jt),ee>K&&(K=ee)}):(p=0,f=0,J=0,K=0);var Mt={x:p,y:J,minX:p,minY:J,maxX:f,maxY:K,width:f-p,height:K-J};return Mt},q.prototype.getDefaultCfg=function(){var p=ft.prototype.getDefaultCfg.call(this);return p.children=[],p},q.prototype.onAttrChange=function(p,f,J){if(ft.prototype.onAttrChange.call(this,p,f,J),p==="matrix"){var K=this.getTotalMatrix();this._applyChildrenMarix(K)}},q.prototype.applyMatrix=function(p){var f=this.getTotalMatrix();ft.prototype.applyMatrix.call(this,p);var J=this.getTotalMatrix();J!==f&&this._applyChildrenMarix(J)},q.prototype._applyChildrenMarix=function(p){var f=this.getChildren();(0,Dt.S6)(f,function(J){J.applyMatrix(p)})},q.prototype.addShape=function(){for(var p=[],f=0;f<arguments.length;f++)p[f]=arguments[f];var J=p[0],K=p[1];(0,Dt.Kn)(J)?K=J:K.type=J;var ht=It[K.type];ht||(ht=(0,Dt.jC)(K.type),It[K.type]=ht);var Mt=this.getShapeBase(),X=new Mt[ht](K);return this.add(X),X},q.prototype.addGroup=function(){for(var p=[],f=0;f<arguments.length;f++)p[f]=arguments[f];var J=p[0],K=p[1],ht;if((0,Dt.mf)(J))K?ht=new J(K):ht=new J({parent:this});else{var Mt=J||{},X=this.getGroupBase();ht=new X(Mt)}return this.add(ht),ht},q.prototype.getCanvas=function(){var p;return this.isCanvas()?p=this:p=this.get("canvas"),p},q.prototype.getShape=function(p,f,J){if(!(0,Dt.pP)(this))return null;var K=this.getChildren(),ht;if(this.isCanvas())ht=this._findShape(K,p,f,J);else{var Mt=[p,f,1];Mt=this.invertFromMatrix(Mt),this.isClipped(Mt[0],Mt[1])||(ht=this._findShape(K,Mt[0],Mt[1],J))}return ht},q.prototype._findShape=function(p,f,J,K){for(var ht=null,Mt=p.length-1;Mt>=0;Mt--){var X=p[Mt];if((0,Dt.pP)(X)&&(X.isGroup()?ht=X.getShape(f,J,K):X.isHit(f,J)&&(ht=X)),ht)break}return ht},q.prototype.add=function(p){var f=this.getCanvas(),J=this.getChildren(),K=this.get("timeline"),ht=p.getParent();ht&&it(ht,p,!1),p.set("parent",this),f&&yt(p,f),K&&ut(p,K),J.push(p),p.onCanvasChange("add"),this._applyElementMatrix(p)},q.prototype._applyElementMatrix=function(p){var f=this.getTotalMatrix();f&&p.applyMatrix(f)},q.prototype.getChildren=function(){return this.get("children")||[]},q.prototype.sort=function(){var p=this.getChildren();(0,Dt.S6)(p,function(f,J){return f[mt]=J,f}),p.sort(Ut(function(f,J){return f.get("zIndex")-J.get("zIndex")})),this.onCanvasChange("sort")},q.prototype.clear=function(){if(this.set("clearing",!0),!this.destroyed){for(var p=this.getChildren(),f=p.length-1;f>=0;f--)p[f].destroy();this.set("children",[]),this.onCanvasChange("clear"),this.set("clearing",!1)}},q.prototype.destroy=function(){this.get("destroyed")||(this.clear(),ft.prototype.destroy.call(this))},q.prototype.getFirst=function(){return this.getChildByIndex(0)},q.prototype.getLast=function(){var p=this.getChildren();return this.getChildByIndex(p.length-1)},q.prototype.getChildByIndex=function(p){var f=this.getChildren();return f[p]},q.prototype.getCount=function(){var p=this.getChildren();return p.length},q.prototype.contain=function(p){var f=this.getChildren();return f.indexOf(p)>-1},q.prototype.removeChild=function(p,f){f===void 0&&(f=!0),this.contain(p)&&p.remove(f)},q.prototype.findAll=function(p){var f=[],J=this.getChildren();return(0,Dt.S6)(J,function(K){p(K)&&f.push(K),K.isGroup()&&(f=f.concat(K.findAll(p)))}),f},q.prototype.find=function(p){var f=null,J=this.getChildren();return(0,Dt.S6)(J,function(K){if(p(K)?f=K:K.isGroup()&&(f=K.find(p)),f)return!1}),f},q.prototype.findById=function(p){return this.find(function(f){return f.get("id")===p})},q.prototype.findByClassName=function(p){return this.find(function(f){return f.get("className")===p})},q.prototype.findAllByName=function(p){return this.findAll(function(f){return f.get("name")===p})},q}(ot.Z);Xt.Z=Ft},29881:function(ge,Xt,N){"use strict";var et=N(65353),ot=N(41694),Dt=N(31506),It=N(77341),mt=N(41482),yt=N(2667),ut=Dt.vs,xt="matrix",it=["zIndex","capture","visible","type"],Ut=["repeat"],Ft=":",ft="*";function q(ht){for(var Mt=[],X=0;X<ht.length;X++)(0,ot.kJ)(ht[X])?Mt.push([].concat(ht[X])):Mt.push(ht[X]);return Mt}function p(ht,Mt){var X={},st=Mt.attrs;for(var Et in ht)X[Et]=st[Et];return X}function f(ht,Mt){var X={},st=Mt.attr();return(0,ot.S6)(ht,function(Et,zt){Ut.indexOf(zt)===-1&&!(0,ot.Xy)(st[zt],Et)&&(X[zt]=Et)}),X}function J(ht,Mt){if(Mt.onFrame)return ht;var X=Mt.startTime,st=Mt.delay,Et=Mt.duration,zt=Object.prototype.hasOwnProperty;return(0,ot.S6)(ht,function(jt){X+st<jt.startTime+jt.delay+jt.duration&&Et>jt.delay&&(0,ot.S6)(Mt.toAttrs,function(ee,ye){zt.call(jt.toAttrs,ye)&&(delete jt.toAttrs[ye],delete jt.fromAttrs[ye])})}),ht}var K=function(ht){(0,et.ZT)(Mt,ht);function Mt(X){var st=ht.call(this,X)||this;st.attrs={};var Et=st.getDefaultAttrs();return(0,ot.CD)(Et,X.attrs),st.attrs=Et,st.initAttrs(Et),st.initAnimate(),st}return Mt.prototype.getDefaultCfg=function(){return{visible:!0,capture:!0,zIndex:0}},Mt.prototype.getDefaultAttrs=function(){return{matrix:this.getDefaultMatrix(),opacity:1}},Mt.prototype.onCanvasChange=function(X){},Mt.prototype.initAttrs=function(X){},Mt.prototype.initAnimate=function(){this.set("animable",!0),this.set("animating",!1)},Mt.prototype.isGroup=function(){return!1},Mt.prototype.getParent=function(){return this.get("parent")},Mt.prototype.getCanvas=function(){return this.get("canvas")},Mt.prototype.attr=function(){for(var X,st=[],Et=0;Et<arguments.length;Et++)st[Et]=arguments[Et];var zt=st[0],jt=st[1];if(!zt)return this.attrs;if((0,ot.Kn)(zt)){for(var ee in zt)this.setAttr(ee,zt[ee]);return this.afterAttrsChange(zt),this}return st.length===2?(this.setAttr(zt,jt),this.afterAttrsChange((X={},X[zt]=jt,X)),this):this.attrs[zt]},Mt.prototype.isClipped=function(X,st){var Et=this.getClip();return Et&&!Et.isHit(X,st)},Mt.prototype.setAttr=function(X,st){var Et=this.attrs[X];Et!==st&&(this.attrs[X]=st,this.onAttrChange(X,st,Et))},Mt.prototype.onAttrChange=function(X,st,Et){X==="matrix"&&this.set("totalMatrix",null)},Mt.prototype.afterAttrsChange=function(X){if(this.cfg.isClipShape){var st=this.cfg.applyTo;st&&st.onCanvasChange("clip")}else this.onCanvasChange("attr")},Mt.prototype.show=function(){return this.set("visible",!0),this.onCanvasChange("show"),this},Mt.prototype.hide=function(){return this.set("visible",!1),this.onCanvasChange("hide"),this},Mt.prototype.setZIndex=function(X){this.set("zIndex",X);var st=this.getParent();return st&&st.sort(),this},Mt.prototype.toFront=function(){var X=this.getParent();if(!!X){var st=X.getChildren(),Et=this.get("el"),zt=st.indexOf(this);st.splice(zt,1),st.push(this),this.onCanvasChange("zIndex")}},Mt.prototype.toBack=function(){var X=this.getParent();if(!!X){var st=X.getChildren(),Et=this.get("el"),zt=st.indexOf(this);st.splice(zt,1),st.unshift(this),this.onCanvasChange("zIndex")}},Mt.prototype.remove=function(X){X===void 0&&(X=!0);var st=this.getParent();st?((0,It.As)(st.getChildren(),this),st.get("clearing")||this.onCanvasChange("remove")):this.onCanvasChange("remove"),X&&this.destroy()},Mt.prototype.resetMatrix=function(){this.attr(xt,this.getDefaultMatrix()),this.onCanvasChange("matrix")},Mt.prototype.getMatrix=function(){return this.attr(xt)},Mt.prototype.setMatrix=function(X){this.attr(xt,X),this.onCanvasChange("matrix")},Mt.prototype.getTotalMatrix=function(){var X=this.cfg.totalMatrix;if(!X){var st=this.attr("matrix"),Et=this.cfg.parentMatrix;Et&&st?X=(0,mt.xq)(Et,st):X=st||Et,this.set("totalMatrix",X)}return X},Mt.prototype.applyMatrix=function(X){var st=this.attr("matrix"),Et=null;X&&st?Et=(0,mt.xq)(X,st):Et=st||X,this.set("totalMatrix",Et),this.set("parentMatrix",X)},Mt.prototype.getDefaultMatrix=function(){return null},Mt.prototype.applyToMatrix=function(X){var st=this.attr("matrix");return st?(0,mt.rG)(st,X):X},Mt.prototype.invertFromMatrix=function(X){var st=this.attr("matrix");if(st){var Et=(0,mt.U_)(st);if(Et)return(0,mt.rG)(Et,X)}return X},Mt.prototype.setClip=function(X){var st=this.getCanvas(),Et=null;if(X){var zt=this.getShapeBase(),jt=(0,ot.jC)(X.type),ee=zt[jt];ee&&(Et=new ee({type:X.type,isClipShape:!0,applyTo:this,attrs:X.attrs,canvas:st}))}return this.set("clipShape",Et),this.onCanvasChange("clip"),Et},Mt.prototype.getClip=function(){var X=this.cfg.clipShape;return X||null},Mt.prototype.clone=function(){var X=this,st=this.attrs,Et={};(0,ot.S6)(st,function(ee,ye){(0,ot.kJ)(st[ye])?Et[ye]=q(st[ye]):Et[ye]=st[ye]});var zt=this.constructor,jt=new zt({attrs:Et});return(0,ot.S6)(it,function(ee){jt.set(ee,X.get(ee))}),jt},Mt.prototype.destroy=function(){var X=this.destroyed;X||(this.attrs={},ht.prototype.destroy.call(this))},Mt.prototype.isAnimatePaused=function(){return this.get("_pause").isPaused},Mt.prototype.animate=function(){for(var X=[],st=0;st<arguments.length;st++)X[st]=arguments[st];if(!(!this.get("timeline")&&!this.get("canvas"))){this.set("animating",!0);var Et=this.get("timeline");Et||(Et=this.get("canvas").get("timeline"),this.set("timeline",Et));var zt=this.get("animations")||[];Et.timer||Et.initTimer();var jt=X[0],ee=X[1],ye=X[2],pt=ye===void 0?"easeLinear":ye,Pt=X[3],Rt=Pt===void 0?ot.ZT:Pt,Bt=X[4],Ct=Bt===void 0?0:Bt,wt,T,z,bt,Y;(0,ot.mf)(jt)?(wt=jt,jt={}):(0,ot.Kn)(jt)&&jt.onFrame&&(wt=jt.onFrame,T=jt.repeat),(0,ot.Kn)(ee)?(Y=ee,ee=Y.duration,pt=Y.easing||"easeLinear",Ct=Y.delay||0,T=Y.repeat||T||!1,Rt=Y.callback||ot.ZT,z=Y.pauseCallback||ot.ZT,bt=Y.resumeCallback||ot.ZT):((0,ot.hj)(Rt)&&(Ct=Rt,Rt=null),(0,ot.mf)(pt)?(Rt=pt,pt="easeLinear"):pt=pt||"easeLinear");var V=f(jt,this),G={fromAttrs:p(V,this),toAttrs:V,duration:ee,easing:pt,repeat:T,callback:Rt,pauseCallback:z,resumeCallback:bt,delay:Ct,startTime:Et.getTime(),id:(0,ot.EL)(),onFrame:wt,pathFormatted:!1};zt.length>0?zt=J(zt,G):Et.addAnimator(this),zt.push(G),this.set("animations",zt),this.set("_pause",{isPaused:!1})}},Mt.prototype.stopAnimate=function(X){var st=this;X===void 0&&(X=!0);var Et=this.get("animations");(0,ot.S6)(Et,function(zt){X&&(zt.onFrame?st.attr(zt.onFrame(1)):st.attr(zt.toAttrs)),zt.callback&&zt.callback()}),this.set("animating",!1),this.set("animations",[])},Mt.prototype.pauseAnimate=function(){var X=this.get("timeline"),st=this.get("animations"),Et=X.getTime();return(0,ot.S6)(st,function(zt){zt._paused=!0,zt._pauseTime=Et,zt.pauseCallback&&zt.pauseCallback()}),this.set("_pause",{isPaused:!0,pauseTime:Et}),this},Mt.prototype.resumeAnimate=function(){var X=this.get("timeline"),st=X.getTime(),Et=this.get("animations"),zt=this.get("_pause").pauseTime;return(0,ot.S6)(Et,function(jt){jt.startTime=jt.startTime+(st-zt),jt._paused=!1,jt._pauseTime=null,jt.resumeCallback&&jt.resumeCallback()}),this.set("_pause",{isPaused:!1}),this.set("animations",Et),this},Mt.prototype.emitDelegation=function(X,st){var Et=this,zt=st.propagationPath,jt=this.getEvents(),ee;X==="mouseenter"?ee=st.fromShape:X==="mouseleave"&&(ee=st.toShape);for(var ye=function(Bt){var Ct=zt[Bt],wt=Ct.get("name");if(wt){if((Ct.isGroup()||Ct.isCanvas&&Ct.isCanvas())&&ee&&(0,It.UY)(Ct,ee))return"break";(0,ot.kJ)(wt)?(0,ot.S6)(wt,function(T){Et.emitDelegateEvent(Ct,T,st)}):pt.emitDelegateEvent(Ct,wt,st)}},pt=this,Pt=0;Pt<zt.length;Pt++){var Rt=ye(Pt);if(Rt==="break")break}},Mt.prototype.emitDelegateEvent=function(X,st,Et){var zt=this.getEvents(),jt=st+Ft+Et.type;(zt[jt]||zt[ft])&&(Et.name=jt,Et.currentTarget=X,Et.delegateTarget=this,Et.delegateObject=X.get("delegateObject"),this.emit(jt,Et))},Mt.prototype.translate=function(X,st){X===void 0&&(X=0),st===void 0&&(st=0);var Et=this.getMatrix(),zt=ut(Et,[["t",X,st]]);return this.setMatrix(zt),this},Mt.prototype.move=function(X,st){var Et=this.attr("x")||0,zt=this.attr("y")||0;return this.translate(X-Et,st-zt),this},Mt.prototype.moveTo=function(X,st){return this.move(X,st)},Mt.prototype.scale=function(X,st){var Et=this.getMatrix(),zt=ut(Et,[["s",X,st||X]]);return this.setMatrix(zt),this},Mt.prototype.rotate=function(X){var st=this.getMatrix(),Et=ut(st,[["r",X]]);return this.setMatrix(Et),this},Mt.prototype.rotateAtStart=function(X){var st=this.attr(),Et=st.x,zt=st.y,jt=this.getMatrix(),ee=ut(jt,[["t",-Et,-zt],["r",X],["t",Et,zt]]);return this.setMatrix(ee),this},Mt.prototype.rotateAtPoint=function(X,st,Et){var zt=this.getMatrix(),jt=ut(zt,[["t",-X,-st],["r",Et],["t",X,st]]);return this.setMatrix(jt),this},Mt}(yt.Z);Xt.Z=K},31841:function(ge,Xt,N){"use strict";var et=N(65353),ot=N(37153),Dt=function(It){(0,et.ZT)(mt,It);function mt(){return It!==null&&It.apply(this,arguments)||this}return mt.prototype.isGroup=function(){return!0},mt.prototype.isEntityGroup=function(){return!1},mt.prototype.clone=function(){for(var yt=It.prototype.clone.call(this),ut=this.getChildren(),xt=0;xt<ut.length;xt++){var it=ut[xt];yt.add(it.clone())}return yt},mt}(ot.Z);Xt.Z=Dt},15032:function(ge,Xt,N){"use strict";var et=N(65353),ot=N(29881),Dt=N(41482),It=function(mt){(0,et.ZT)(yt,mt);function yt(ut){return mt.call(this,ut)||this}return yt.prototype._isInBBox=function(ut,xt){var it=this.getBBox();return it.minX<=ut&&it.maxX>=ut&&it.minY<=xt&&it.maxY>=xt},yt.prototype.afterAttrsChange=function(ut){mt.prototype.afterAttrsChange.call(this,ut),this.clearCacheBBox()},yt.prototype.getBBox=function(){var ut=this.cfg.bbox;return ut||(ut=this.calculateBBox(),this.set("bbox",ut)),ut},yt.prototype.getCanvasBBox=function(){var ut=this.cfg.canvasBBox;return ut||(ut=this.calculateCanvasBBox(),this.set("canvasBBox",ut)),ut},yt.prototype.applyMatrix=function(ut){mt.prototype.applyMatrix.call(this,ut),this.set("canvasBBox",null)},yt.prototype.calculateCanvasBBox=function(){var ut=this.getBBox(),xt=this.getTotalMatrix(),it=ut.minX,Ut=ut.minY,Ft=ut.maxX,ft=ut.maxY;if(xt){var q=(0,Dt.rG)(xt,[ut.minX,ut.minY]),p=(0,Dt.rG)(xt,[ut.maxX,ut.minY]),f=(0,Dt.rG)(xt,[ut.minX,ut.maxY]),J=(0,Dt.rG)(xt,[ut.maxX,ut.maxY]);it=Math.min(q[0],p[0],f[0],J[0]),Ft=Math.max(q[0],p[0],f[0],J[0]),Ut=Math.min(q[1],p[1],f[1],J[1]),ft=Math.max(q[1],p[1],f[1],J[1])}var K=this.attrs;if(K.shadowColor){var ht=K.shadowBlur,Mt=ht===void 0?0:ht,X=K.shadowOffsetX,st=X===void 0?0:X,Et=K.shadowOffsetY,zt=Et===void 0?0:Et,jt=it-Mt+st,ee=Ft+Mt+st,ye=Ut-Mt+zt,pt=ft+Mt+zt;it=Math.min(it,jt),Ft=Math.max(Ft,ee),Ut=Math.min(Ut,ye),ft=Math.max(ft,pt)}return{x:it,y:Ut,minX:it,minY:Ut,maxX:Ft,maxY:ft,width:Ft-it,height:ft-Ut}},yt.prototype.clearCacheBBox=function(){this.set("bbox",null),this.set("canvasBBox",null)},yt.prototype.isClipShape=function(){return this.get("isClipShape")},yt.prototype.isInShape=function(ut,xt){return!1},yt.prototype.isOnlyHitBox=function(){return!1},yt.prototype.isHit=function(ut,xt){var it=this.get("startArrowShape"),Ut=this.get("endArrowShape"),Ft=[ut,xt,1];Ft=this.invertFromMatrix(Ft);var ft=Ft[0],q=Ft[1],p=this._isInBBox(ft,q);return this.isOnlyHitBox()?p:!!(p&&!this.isClipped(ft,q)&&(this.isInShape(ft,q)||it&&it.isHit(ft,q)||Ut&&Ut.isHit(ft,q)))},yt}(ot.Z);Xt.Z=It},97492:function(ge,Xt,N){"use strict";N.d(Xt,{_:function(){return L},C:function(){return U}});var et={};N.r(et),N.d(et,{easeBack:function(){return D},easeBackIn:function(){return A},easeBackInOut:function(){return D},easeBackOut:function(){return I},easeBounce:function(){return Y},easeBounceIn:function(){return bt},easeBounceInOut:function(){return V},easeBounceOut:function(){return Y},easeCircle:function(){return jt},easeCircleIn:function(){return Et},easeCircleInOut:function(){return jt},easeCircleOut:function(){return zt},easeCubic:function(){return xt},easeCubicIn:function(){return yt},easeCubicInOut:function(){return xt},easeCubicOut:function(){return ut},easeElastic:function(){return F},easeElasticIn:function(){return P},easeElasticInOut:function(){return C},easeElasticOut:function(){return F},easeExp:function(){return st},easeExpIn:function(){return Mt},easeExpInOut:function(){return st},easeExpOut:function(){return X},easeLinear:function(){return ot},easePoly:function(){return ft},easePolyIn:function(){return Ut},easePolyInOut:function(){return ft},easePolyOut:function(){return Ft},easeQuad:function(){return mt},easeQuadIn:function(){return Dt},easeQuadInOut:function(){return mt},easeQuadOut:function(){return It},easeSin:function(){return K},easeSinIn:function(){return f},easeSinInOut:function(){return K},easeSinOut:function(){return J}});function ot(B){return+B}function Dt(B){return B*B}function It(B){return B*(2-B)}function mt(B){return((B*=2)<=1?B*B:--B*(2-B)+1)/2}function yt(B){return B*B*B}function ut(B){return--B*B*B+1}function xt(B){return((B*=2)<=1?B*B*B:(B-=2)*B*B+2)/2}var it=3,Ut=function B(j){j=+j;function nt(Tt){return Math.pow(Tt,j)}return nt.exponent=B,nt}(it),Ft=function B(j){j=+j;function nt(Tt){return 1-Math.pow(1-Tt,j)}return nt.exponent=B,nt}(it),ft=function B(j){j=+j;function nt(Tt){return((Tt*=2)<=1?Math.pow(Tt,j):2-Math.pow(2-Tt,j))/2}return nt.exponent=B,nt}(it),q=Math.PI,p=q/2;function f(B){return+B==1?1:1-Math.cos(B*p)}function J(B){return Math.sin(B*p)}function K(B){return(1-Math.cos(q*B))/2}function ht(B){return(Math.pow(2,-10*B)-.0009765625)*1.0009775171065494}function Mt(B){return ht(1-+B)}function X(B){return 1-ht(B)}function st(B){return((B*=2)<=1?ht(1-B):2-ht(B-1))/2}function Et(B){return 1-Math.sqrt(1-B*B)}function zt(B){return Math.sqrt(1- --B*B)}function jt(B){return((B*=2)<=1?1-Math.sqrt(1-B*B):Math.sqrt(1-(B-=2)*B)+1)/2}var ee=4/11,ye=6/11,pt=8/11,Pt=3/4,Rt=9/11,Bt=10/11,Ct=15/16,wt=21/22,T=63/64,z=1/ee/ee;function bt(B){return 1-Y(1-B)}function Y(B){return(B=+B)<ee?z*B*B:B<pt?z*(B-=ye)*B+Pt:B<Bt?z*(B-=Rt)*B+Ct:z*(B-=wt)*B+T}function V(B){return((B*=2)<=1?1-Y(1-B):Y(B-1)+1)/2}var G=1.70158,A=function B(j){j=+j;function nt(Tt){return(Tt=+Tt)*Tt*(j*(Tt-1)+Tt)}return nt.overshoot=B,nt}(G),I=function B(j){j=+j;function nt(Tt){return--Tt*Tt*((Tt+1)*j+Tt)+1}return nt.overshoot=B,nt}(G),D=function B(j){j=+j;function nt(Tt){return((Tt*=2)<1?Tt*Tt*((j+1)*Tt-j):(Tt-=2)*Tt*((j+1)*Tt+j)+2)/2}return nt.overshoot=B,nt}(G),E=2*Math.PI,Q=1,lt=.3,P=function B(j,nt){var Tt=Math.asin(1/(j=Math.max(1,j)))*(nt/=E);function Jt($t){return j*ht(- --$t)*Math.sin((Tt-$t)/nt)}return Jt.amplitude=function($t){return B($t,nt*E)},Jt.period=function($t){return B(j,$t)},Jt}(Q,lt),F=function B(j,nt){var Tt=Math.asin(1/(j=Math.max(1,j)))*(nt/=E);function Jt($t){return 1-j*ht($t=+$t)*Math.sin(($t+Tt)/nt)}return Jt.amplitude=function($t){return B($t,nt*E)},Jt.period=function($t){return B(j,$t)},Jt}(Q,lt),C=function B(j,nt){var Tt=Math.asin(1/(j=Math.max(1,j)))*(nt/=E);function Jt($t){return(($t=$t*2-1)<0?j*ht(-$t)*Math.sin((Tt-$t)/nt):2-j*ht($t)*Math.sin((Tt+$t)/nt))/2}return Jt.amplitude=function($t){return B($t,nt*E)},Jt.period=function($t){return B(j,$t)},Jt}(Q,lt),_={};function L(B){return _[B.toLowerCase()]||et[B]}function U(B,j){_[B.toLowerCase()]=j}},63427:function(ge,Xt,N){"use strict";N.d(Xt,{b:function(){return Dt},W:function(){return ot}});var et=new Map;function ot(tt,Z){et.set(tt,Z)}function Dt(tt){return et.get(tt)}function It(tt){var Z=tt.attr(),vt=Z.x,St=Z.y,Ot=Z.width,Wt=Z.height;return{x:vt,y:St,width:Ot,height:Wt}}function mt(tt){var Z=tt.attr(),vt=Z.x,St=Z.y,Ot=Z.r;return{x:vt-Ot,y:St-Ot,width:Ot*2,height:Ot*2}}var yt=N(89838);function ut(tt,Z){return!tt||!Z?tt||Z:{minX:Math.min(tt.minX,Z.minX),minY:Math.min(tt.minY,Z.minY),maxX:Math.max(tt.maxX,Z.maxX),maxY:Math.max(tt.maxY,Z.maxY)}}function xt(tt,Z){var vt=tt.get("startArrowShape"),St=tt.get("endArrowShape"),Ot=null,Wt=null;return vt&&(Ot=vt.getCanvasBBox(),Z=ut(Z,Ot)),St&&(Wt=St.getCanvasBBox(),Z=ut(Z,Wt)),Z}function it(tt){for(var Z=tt.attr(),vt=Z.points,St=[],Ot=[],Wt=0;Wt<vt.length;Wt++){var Ht=vt[Wt];St.push(Ht[0]),Ot.push(Ht[1])}var Kt=yt.Zr.getBBoxByArray(St,Ot),Lt=Kt.x,re=Kt.y,Zt=Kt.width,me=Kt.height,Se={minX:Lt,minY:re,maxX:Lt+Zt,maxY:re+me};return Se=xt(tt,Se),{x:Se.minX,y:Se.minY,width:Se.maxX-Se.minX,height:Se.maxY-Se.minY}}function Ut(tt){for(var Z=tt.attr(),vt=Z.points,St=[],Ot=[],Wt=0;Wt<vt.length;Wt++){var Ht=vt[Wt];St.push(Ht[0]),Ot.push(Ht[1])}return yt.Zr.getBBoxByArray(St,Ot)}var Ft=N(8723);function ft(tt){var Z=tt.attr(),vt=Z.x,St=Z.y,Ot=Z.text,Wt=Z.fontSize,Ht=Z.lineHeight,Kt=Z.font;Kt||(Kt=(0,Ft.$O)(Z));var Lt=(0,Ft.mY)(Ot,Kt),re;if(!Lt)re={x:vt,y:St,width:0,height:0};else{var Zt=Z.textAlign,me=Z.textBaseline,Se=(0,Ft.FE)(Ot,Wt,Ht),se={x:vt,y:St-Se};Zt&&(Zt==="end"||Zt==="right"?se.x-=Lt:Zt==="center"&&(se.x-=Lt/2)),me&&(me==="top"?se.y+=Se:me==="middle"&&(se.y+=Se/2)),re={x:se.x,y:se.y,width:Lt,height:Se}}return re}var q=N(41694),p=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/ig,f=/[^\s\,]+/ig;function J(tt){var Z=tt||[];if((0,q.kJ)(Z))return Z;if((0,q.HD)(Z))return Z=Z.match(p),(0,q.S6)(Z,function(vt,St){if(vt=vt.match(f),vt[0].length>1){var Ot=vt[0].charAt(0);vt.splice(1,0,vt[0].substr(1)),vt[0]=Ot}(0,q.S6)(vt,function(Wt,Ht){isNaN(Wt)||(vt[Ht]=+Wt)}),Z[St]=vt}),Z}var K=J;function ht(tt,Z,vt){var St=null,Ot=vt;return Z<Ot&&(Ot=Z,St="add"),tt<Ot&&(Ot=tt,St="del"),{type:St,min:Ot}}var Mt=function(tt,Z){var vt=tt.length,St=Z.length,Ot,Wt,Ht=0;if(vt===0||St===0)return null;for(var Kt=[],Lt=0;Lt<=vt;Lt++)Kt[Lt]=[],Kt[Lt][0]={min:Lt};for(var re=0;re<=St;re++)Kt[0][re]={min:re};for(var Lt=1;Lt<=vt;Lt++){Ot=tt[Lt-1];for(var re=1;re<=St;re++){Wt=Z[re-1],isEqual(Ot,Wt)?Ht=0:Ht=1;var Zt=Kt[Lt-1][re].min+1,me=Kt[Lt][re-1].min+1,Se=Kt[Lt-1][re-1].min+Ht;Kt[Lt][re]=ht(Zt,me,Se)}}return Kt};function X(tt,Z){var vt=Mt(tt,Z),St=tt.length,Ot=Z.length,Wt=[],Ht=1,Kt=1;if(vt[St][Ot]!==St){for(var Lt=1;Lt<=St;Lt++){var re=vt[Lt][Lt].min;Kt=Lt;for(var Zt=Ht;Zt<=Ot;Zt++)vt[Lt][Zt].min<re&&(re=vt[Lt][Zt].min,Kt=Zt);Ht=Kt,vt[Lt][Ht].type&&Wt.push({index:Lt-1,type:vt[Lt][Ht].type})}for(var Lt=Wt.length-1;Lt>=0;Lt--)Ht=Wt[Lt].index,Wt[Lt].type==="add"?tt.splice(Ht,0,[].concat(tt[Ht])):tt.splice(Ht,1)}if(St=tt.length,St<Ot)for(var Lt=0;Lt<Ot-St;Lt++)tt[St-1][0]==="z"||tt[St-1][0]==="Z"?tt.splice(St-2,0,tt[St-2]):tt.push(tt[St-1]);return tt}var st=`
  13. \v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,Et=new RegExp("([a-z])["+st+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+st+"]*,?["+st+"]*)+)","ig"),zt=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+st+"]*,?["+st+"]*","ig");function jt(tt){if(!tt)return null;if(isArray(tt))return tt;var Z={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},vt=[];return String(tt).replace(Et,function(St,Ot,Wt){var Ht=[],Kt=Ot.toLowerCase();if(Wt.replace(zt,function(Lt,re){re&&Ht.push(+re)}),Kt==="m"&&Ht.length>2&&(vt.push([Ot].concat(Ht.splice(0,2))),Kt="l",Ot=Ot==="m"?"l":"L"),Kt==="o"&&Ht.length===1&&vt.push([Ot,Ht[0]]),Kt==="r")vt.push([Ot].concat(Ht));else for(;Ht.length>=Z[Kt]&&(vt.push([Ot].concat(Ht.splice(0,Z[Kt]))),!!Z[Kt]););return""}),vt}var ee=/[a-z]/;function ye(tt,Z){return[Z[0]+(Z[0]-tt[0]),Z[1]+(Z[1]-tt[1])]}function pt(tt){var Z=parsePathString(tt);if(!Z||!Z.length)return[["M",0,0]];for(var vt=!1,St=0;St<Z.length;St++){var Ot=Z[St][0];if(ee.test(Ot)||["V","H","T","S"].indexOf(Ot)>=0){vt=!0;break}}if(!vt)return Z;var Wt=[],Ht=0,Kt=0,Lt=0,re=0,Zt=0,me,Se,se=Z[0];(se[0]==="M"||se[0]==="m")&&(Ht=+se[1],Kt=+se[2],Lt=Ht,re=Kt,Zt++,Wt[0]=["M",Ht,Kt]);for(var St=Zt,we=Z.length;St<we;St++){var Ae=Z[St],Ce=Wt[St-1],ae=[],Ot=Ae[0],Ie=Ot.toUpperCase();if(Ot!==Ie)switch(ae[0]=Ie,Ie){case"A":ae[1]=Ae[1],ae[2]=Ae[2],ae[3]=Ae[3],ae[4]=Ae[4],ae[5]=Ae[5],ae[6]=+Ae[6]+Ht,ae[7]=+Ae[7]+Kt;break;case"V":ae[1]=+Ae[1]+Kt;break;case"H":ae[1]=+Ae[1]+Ht;break;case"M":Lt=+Ae[1]+Ht,re=+Ae[2]+Kt,ae[1]=Lt,ae[2]=re;break;default:for(var Le=1,He=Ae.length;Le<He;Le++)ae[Le]=+Ae[Le]+(Le%2?Ht:Kt)}else ae=Z[St];switch(Ie){case"Z":Ht=+Lt,Kt=+re;break;case"H":Ht=ae[1],ae=["L",Ht,Kt];break;case"V":Kt=ae[1],ae=["L",Ht,Kt];break;case"T":Ht=ae[1],Kt=ae[2];var ze=ye([Ce[1],Ce[2]],[Ce[3],Ce[4]]);ae=["Q",ze[0],ze[1],Ht,Kt];break;case"S":Ht=ae[ae.length-2],Kt=ae[ae.length-1];var $e=Ce.length,je=ye([Ce[$e-4],Ce[$e-3]],[Ce[$e-2],Ce[$e-1]]);ae=["C",je[0],je[1],ae[1],ae[2],Ht,Kt];break;case"M":Lt=ae[ae.length-2],re=ae[ae.length-1];break;default:Ht=ae[ae.length-2],Kt=ae[ae.length-1]}Wt.push(ae)}return Wt}var Pt=Math.PI*2,Rt=function(tt,Z,vt,St,Ot,Wt,Ht){var Kt=tt.x,Lt=tt.y;Kt*=Z,Lt*=vt;var re=St*Kt-Ot*Lt,Zt=Ot*Kt+St*Lt;return{x:re+Wt,y:Zt+Ht}},Bt=function(tt,Z){var vt=Z===1.5707963267948966?.551915024494:Z===-1.5707963267948966?-.551915024494:4/3*Math.tan(Z/4),St=Math.cos(tt),Ot=Math.sin(tt),Wt=Math.cos(tt+Z),Ht=Math.sin(tt+Z);return[{x:St-Ot*vt,y:Ot+St*vt},{x:Wt+Ht*vt,y:Ht-Wt*vt},{x:Wt,y:Ht}]},Ct=function(tt,Z,vt,St){var Ot=tt*St-Z*vt<0?-1:1,Wt=tt*vt+Z*St;return Wt>1&&(Wt=1),Wt<-1&&(Wt=-1),Ot*Math.acos(Wt)},wt=function(tt,Z,vt,St,Ot,Wt,Ht,Kt,Lt,re,Zt,me){var Se=Math.pow(Ot,2),se=Math.pow(Wt,2),we=Math.pow(Zt,2),Ae=Math.pow(me,2),Ce=Se*se-Se*Ae-se*we;Ce<0&&(Ce=0),Ce/=Se*Ae+se*we,Ce=Math.sqrt(Ce)*(Ht===Kt?-1:1);var ae=Ce*Ot/Wt*me,Ie=Ce*-Wt/Ot*Zt,Le=re*ae-Lt*Ie+(tt+vt)/2,He=Lt*ae+re*Ie+(Z+St)/2,ze=(Zt-ae)/Ot,$e=(me-Ie)/Wt,je=(-Zt-ae)/Ot,yr=(-me-Ie)/Wt,wr=Ct(1,0,ze,$e),Sr=Ct(ze,$e,je,yr);return Kt===0&&Sr>0&&(Sr-=Pt),Kt===1&&Sr<0&&(Sr+=Pt),[Le,He,wr,Sr]},T=function(tt){var Z=tt.px,vt=tt.py,St=tt.cx,Ot=tt.cy,Wt=tt.rx,Ht=tt.ry,Kt=tt.xAxisRotation,Lt=Kt===void 0?0:Kt,re=tt.largeArcFlag,Zt=re===void 0?0:re,me=tt.sweepFlag,Se=me===void 0?0:me,se=[];if(Wt===0||Ht===0)return[{x1:0,y1:0,x2:0,y2:0,x:St,y:Ot}];var we=Math.sin(Lt*Pt/360),Ae=Math.cos(Lt*Pt/360),Ce=Ae*(Z-St)/2+we*(vt-Ot)/2,ae=-we*(Z-St)/2+Ae*(vt-Ot)/2;if(Ce===0&&ae===0)return[{x1:0,y1:0,x2:0,y2:0,x:St,y:Ot}];Wt=Math.abs(Wt),Ht=Math.abs(Ht);var Ie=Math.pow(Ce,2)/Math.pow(Wt,2)+Math.pow(ae,2)/Math.pow(Ht,2);Ie>1&&(Wt*=Math.sqrt(Ie),Ht*=Math.sqrt(Ie));var Le=wt(Z,vt,St,Ot,Wt,Ht,Zt,Se,we,Ae,Ce,ae),He=Le[0],ze=Le[1],$e=Le[2],je=Le[3],yr=Math.abs(je)/(Pt/4);Math.abs(1-yr)<1e-7&&(yr=1);var wr=Math.max(Math.ceil(yr),1);je/=wr;for(var Sr=0;Sr<wr;Sr++)se.push(Bt($e,je)),$e+=je;return se.map(function(cn){var yn=Rt(cn[0],Wt,Ht,Ae,we,He,ze),mn=yn.x,qn=yn.y,tn=Rt(cn[1],Wt,Ht,Ae,we,He,ze),Yr=tn.x,en=tn.y,rn=Rt(cn[2],Wt,Ht,Ae,we,He,ze),fn=rn.x,Kn=rn.y;return{x1:mn,y1:qn,x2:Yr,y2:en,x:fn,y:Kn}})};function z(tt,Z,vt,St,Ot,Wt,Ht,Kt,Lt){var re=T({px:tt,py:Z,cx:Kt,cy:Lt,rx:vt,ry:St,xAxisRotation:Ot,largeArcFlag:Wt,sweepFlag:Ht});return re.reduce(function(Zt,me){var Se=me.x1,se=me.y1,we=me.x2,Ae=me.y2,Ce=me.x,ae=me.y;return Zt.push(Se,se,we,Ae,Ce,ae),Zt},[])}function bt(tt,Z){"TQ".indexOf(tt[0])<0&&(Z.qx=null,Z.qy=null);var vt=tt.slice(1),St=vt[0],Ot=vt[1];switch(tt[0]){case"M":return Z.x=St,Z.y=Ot,tt;case"A":return["C"].concat(arcToCubic.apply(0,[Z.x1,Z.y1].concat(tt.slice(1))));case"Q":return Z.qx=St,Z.qy=Ot,["C"].concat(quadToCubic.apply(0,[Z.x1,Z.y1].concat(tt.slice(1))));case"L":return["C"].concat(lineToCubic(Z.x1,Z.y1,tt[1],tt[2]));case"H":return["C"].concat(lineToCubic(Z.x1,Z.y1,tt[1],Z.y1));case"V":return["C"].concat(lineToCubic(Z.x1,Z.y1,Z.x1,tt[1]));case"Z":return["C"].concat(lineToCubic(Z.x1,Z.y1,Z.x,Z.y));default:}return tt}function Y(tt,Z){Z===void 0&&(Z=!1);for(var vt=path2Absolute(tt),St={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null},Ot=[],Wt="",Ht=vt.length,Kt,Lt,re=[],Zt=0;Zt<Ht;Zt+=1)vt[Zt]&&(Wt=vt[Zt][0]),Ot[Zt]=Wt,vt[Zt]=segmentToCubic(vt[Zt],St),V(vt,Ot,Zt),Ht=vt.length,Wt==="Z"&&re.push(Zt),Kt=vt[Zt],Lt=Kt.length,St.x1=+Kt[Lt-2],St.y1=+Kt[Lt-1],St.x2=+Kt[Lt-4]||St.x1,St.y2=+Kt[Lt-3]||St.y1;return Z?[vt,re]:vt}function V(tt,Z,vt){if(tt[vt].length>7){tt[vt].shift();for(var St=tt[vt],Ot=vt;St.length;)Z[vt]="A",tt.splice(Ot+=1,0,["C"].concat(St.splice(0,6)));tt.splice(vt,1)}}var G=function(tt,Z,vt,St,Ot){var Wt=-3*Z+9*vt-9*St+3*Ot,Ht=tt*Wt+6*Z-12*vt+6*St;return tt*Ht-3*Z+3*vt},A=function(tt,Z,vt,St,Ot,Wt,Ht,Kt,Lt){Lt===null&&(Lt=1),Lt=Lt>1?1:Lt<0?0:Lt;for(var re=Lt/2,Zt=12,me=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],Se=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],se=0,we=0;we<Zt;we++){var Ae=re*me[we]+re,Ce=G(Ae,tt,vt,Ot,Ht),ae=G(Ae,Z,St,Wt,Kt),Ie=Ce*Ce+ae*ae;se+=Se[we]*Math.sqrt(Ie)}return re*se},I=function(tt,Z,vt,St,Ot,Wt,Ht,Kt){for(var Lt=[],re=[[],[]],Zt,me,Se,se,we=0;we<2;++we){if(we===0?(me=6*tt-12*vt+6*Ot,Zt=-3*tt+9*vt-9*Ot+3*Ht,Se=3*vt-3*tt):(me=6*Z-12*St+6*Wt,Zt=-3*Z+9*St-9*Wt+3*Kt,Se=3*St-3*Z),Math.abs(Zt)<1e-12){if(Math.abs(me)<1e-12)continue;se=-Se/me,se>0&&se<1&&Lt.push(se);continue}var Ae=me*me-4*Se*Zt,Ce=Math.sqrt(Ae);if(!(Ae<0)){var ae=(-me+Ce)/(2*Zt);ae>0&&ae<1&&Lt.push(ae);var Ie=(-me-Ce)/(2*Zt);Ie>0&&Ie<1&&Lt.push(Ie)}}for(var Le=Lt.length,He=Le,ze;Le--;)se=Lt[Le],ze=1-se,re[0][Le]=ze*ze*ze*tt+3*ze*ze*se*vt+3*ze*se*se*Ot+se*se*se*Ht,re[1][Le]=ze*ze*ze*Z+3*ze*ze*se*St+3*ze*se*se*Wt+se*se*se*Kt;return re[0][He]=tt,re[1][He]=Z,re[0][He+1]=Ht,re[1][He+1]=Kt,re[0].length=re[1].length=He+2,{min:{x:Math.min.apply(0,re[0]),y:Math.min.apply(0,re[1])},max:{x:Math.max.apply(0,re[0]),y:Math.max.apply(0,re[1])}}},D=function(tt,Z,vt,St,Ot,Wt,Ht,Kt){if(!(Math.max(tt,vt)<Math.min(Ot,Ht)||Math.min(tt,vt)>Math.max(Ot,Ht)||Math.max(Z,St)<Math.min(Wt,Kt)||Math.min(Z,St)>Math.max(Wt,Kt))){var Lt=(tt*St-Z*vt)*(Ot-Ht)-(tt-vt)*(Ot*Kt-Wt*Ht),re=(tt*St-Z*vt)*(Wt-Kt)-(Z-St)*(Ot*Kt-Wt*Ht),Zt=(tt-vt)*(Wt-Kt)-(Z-St)*(Ot-Ht);if(!!Zt){var me=Lt/Zt,Se=re/Zt,se=+me.toFixed(2),we=+Se.toFixed(2);if(!(se<+Math.min(tt,vt).toFixed(2)||se>+Math.max(tt,vt).toFixed(2)||se<+Math.min(Ot,Ht).toFixed(2)||se>+Math.max(Ot,Ht).toFixed(2)||we<+Math.min(Z,St).toFixed(2)||we>+Math.max(Z,St).toFixed(2)||we<+Math.min(Wt,Kt).toFixed(2)||we>+Math.max(Wt,Kt).toFixed(2)))return{x:me,y:Se}}}},E=function(tt,Z,vt){return Z>=tt.x&&Z<=tt.x+tt.width&&vt>=tt.y&&vt<=tt.y+tt.height},Q=function(tt,Z,vt,St){return tt===null&&(tt=Z=vt=St=0),Z===null&&(Z=tt.y,vt=tt.width,St=tt.height,tt=tt.x),{x:tt,y:Z,width:vt,w:vt,height:St,h:St,x2:tt+vt,y2:Z+St,cx:tt+vt/2,cy:Z+St/2,r1:Math.min(vt,St)/2,r2:Math.max(vt,St)/2,r0:Math.sqrt(vt*vt+St*St)/2,path:rectPath(tt,Z,vt,St),vb:[tt,Z,vt,St].join(" ")}},lt=function(tt,Z){return tt=Q(tt),Z=Q(Z),E(Z,tt.x,tt.y)||E(Z,tt.x2,tt.y)||E(Z,tt.x,tt.y2)||E(Z,tt.x2,tt.y2)||E(tt,Z.x,Z.y)||E(tt,Z.x2,Z.y)||E(tt,Z.x,Z.y2)||E(tt,Z.x2,Z.y2)||(tt.x<Z.x2&&tt.x>Z.x||Z.x<tt.x2&&Z.x>tt.x)&&(tt.y<Z.y2&&tt.y>Z.y||Z.y<tt.y2&&Z.y>tt.y)},P=function(tt,Z,vt,St,Ot,Wt,Ht,Kt){isArray(tt)||(tt=[tt,Z,vt,St,Ot,Wt,Ht,Kt]);var Lt=I.apply(null,tt);return Q(Lt.min.x,Lt.min.y,Lt.max.x-Lt.min.x,Lt.max.y-Lt.min.y)},F=function(tt,Z,vt,St,Ot,Wt,Ht,Kt,Lt){var re=1-Lt,Zt=Math.pow(re,3),me=Math.pow(re,2),Se=Lt*Lt,se=Se*Lt,we=Zt*tt+me*3*Lt*vt+re*3*Lt*Lt*Ot+se*Ht,Ae=Zt*Z+me*3*Lt*St+re*3*Lt*Lt*Wt+se*Kt,Ce=tt+2*Lt*(vt-tt)+Se*(Ot-2*vt+tt),ae=Z+2*Lt*(St-Z)+Se*(Wt-2*St+Z),Ie=vt+2*Lt*(Ot-vt)+Se*(Ht-2*Ot+vt),Le=St+2*Lt*(Wt-St)+Se*(Kt-2*Wt+St),He=re*tt+Lt*vt,ze=re*Z+Lt*St,$e=re*Ot+Lt*Ht,je=re*Wt+Lt*Kt,yr=90-Math.atan2(Ce-Ie,ae-Le)*180/Math.PI;return{x:we,y:Ae,m:{x:Ce,y:ae},n:{x:Ie,y:Le},start:{x:He,y:ze},end:{x:$e,y:je},alpha:yr}},C=function(tt,Z,vt){var St=P(tt),Ot=P(Z);if(!lt(St,Ot))return vt?0:[];for(var Wt=A.apply(0,tt),Ht=A.apply(0,Z),Kt=~~(Wt/8),Lt=~~(Ht/8),re=[],Zt=[],me={},Se=vt?0:[],se=0;se<Kt+1;se++){var we=F.apply(0,tt.concat(se/Kt));re.push({x:we.x,y:we.y,t:se/Kt})}for(var se=0;se<Lt+1;se++){var we=F.apply(0,Z.concat(se/Lt));Zt.push({x:we.x,y:we.y,t:se/Lt})}for(var se=0;se<Kt;se++)for(var Ae=0;Ae<Lt;Ae++){var Ce=re[se],ae=re[se+1],Ie=Zt[Ae],Le=Zt[Ae+1],He=Math.abs(ae.x-Ce.x)<.001?"y":"x",ze=Math.abs(Le.x-Ie.x)<.001?"y":"x",$e=D(Ce.x,Ce.y,ae.x,ae.y,Ie.x,Ie.y,Le.x,Le.y);if($e){if(me[$e.x.toFixed(4)]===$e.y.toFixed(4))continue;me[$e.x.toFixed(4)]=$e.y.toFixed(4);var je=Ce.t+Math.abs(($e[He]-Ce[He])/(ae[He]-Ce[He]))*(ae.t-Ce.t),yr=Ie.t+Math.abs(($e[ze]-Ie[ze])/(Le[ze]-Ie[ze]))*(Le.t-Ie.t);je>=0&&je<=1&&yr>=0&&yr<=1&&(vt?Se++:Se.push({x:$e.x,y:$e.y,t1:je,t2:yr}))}}return Se},_=function(tt,Z,vt){tt=path2Curve(tt),Z=path2Curve(Z);for(var St,Ot,Wt,Ht,Kt,Lt,re,Zt,me,Se,se=vt?0:[],we=0,Ae=tt.length;we<Ae;we++){var Ce=tt[we];if(Ce[0]==="M")St=Kt=Ce[1],Ot=Lt=Ce[2];else{Ce[0]==="C"?(me=[St,Ot].concat(Ce.slice(1)),St=me[6],Ot=me[7]):(me=[St,Ot,St,Ot,Kt,Lt,Kt,Lt],St=Kt,Ot=Lt);for(var ae=0,Ie=Z.length;ae<Ie;ae++){var Le=Z[ae];if(Le[0]==="M")Wt=re=Le[1],Ht=Zt=Le[2];else{Le[0]==="C"?(Se=[Wt,Ht].concat(Le.slice(1)),Wt=Se[6],Ht=Se[7]):(Se=[Wt,Ht,Wt,Ht,re,Zt,re,Zt],Wt=re,Ht=Zt);var He=C(me,Se,vt);if(vt)se+=He;else{for(var ze=0,$e=He.length;ze<$e;ze++)He[ze].segment1=we,He[ze].segment2=ae,He[ze].bez1=me,He[ze].bez2=Se;se=se.concat(He)}}}}}return se};function L(tt,Z){return _(tt,Z)}function U(tt){return Math.sqrt(tt[0]*tt[0]+tt[1]*tt[1])}function B(tt,Z){return U(tt)*U(Z)?(tt[0]*Z[0]+tt[1]*Z[1])/(U(tt)*U(Z)):1}function j(tt,Z){return(tt[0]*Z[1]<tt[1]*Z[0]?-1:1)*Math.acos(B(tt,Z))}function nt(tt,Z){return tt[0]===Z[0]&&tt[1]===Z[1]}function Tt(tt,Z){var vt=Z[1],St=Z[2],Ot=(0,q.wQ)((0,q.c$)(Z[3]),Math.PI*2),Wt=Z[4],Ht=Z[5],Kt=tt[0],Lt=tt[1],re=Z[6],Zt=Z[7],me=Math.cos(Ot)*(Kt-re)/2+Math.sin(Ot)*(Lt-Zt)/2,Se=-1*Math.sin(Ot)*(Kt-re)/2+Math.cos(Ot)*(Lt-Zt)/2,se=me*me/(vt*vt)+Se*Se/(St*St);se>1&&(vt*=Math.sqrt(se),St*=Math.sqrt(se));var we=vt*vt*(Se*Se)+St*St*(me*me),Ae=we?Math.sqrt((vt*vt*(St*St)-we)/we):1;Wt===Ht&&(Ae*=-1),isNaN(Ae)&&(Ae=0);var Ce=St?Ae*vt*Se/St:0,ae=vt?Ae*-St*me/vt:0,Ie=(Kt+re)/2+Math.cos(Ot)*Ce-Math.sin(Ot)*ae,Le=(Lt+Zt)/2+Math.sin(Ot)*Ce+Math.cos(Ot)*ae,He=[(me-Ce)/vt,(Se-ae)/St],ze=[(-1*me-Ce)/vt,(-1*Se-ae)/St],$e=j([1,0],He),je=j(He,ze);return B(He,ze)<=-1&&(je=Math.PI),B(He,ze)>=1&&(je=0),Ht===0&&je>0&&(je=je-2*Math.PI),Ht===1&&je<0&&(je=je+2*Math.PI),{cx:Ie,cy:Le,rx:nt(tt,[re,Zt])?0:vt,ry:nt(tt,[re,Zt])?0:St,startAngle:$e,endAngle:$e+je,xRotation:Ot,arcFlag:Wt,sweepFlag:Ht}}function Jt(tt,Z){return[Z[0]+(Z[0]-tt[0]),Z[1]+(Z[1]-tt[1])]}function $t(tt){tt=K(tt);for(var Z=[],vt=null,St=null,Ot=null,Wt=0,Ht=tt.length,Kt=0;Kt<Ht;Kt++){var Lt=tt[Kt];St=tt[Kt+1];var re=Lt[0],Zt={command:re,prePoint:vt,params:Lt,startTangent:null,endTangent:null};switch(re){case"M":Ot=[Lt[1],Lt[2]],Wt=Kt;break;case"A":var me=Tt(vt,Lt);Zt.arcParams=me;break;default:break}if(re==="Z")vt=Ot,St=tt[Wt+1];else{var Se=Lt.length;vt=[Lt[Se-2],Lt[Se-1]]}St&&St[0]==="Z"&&(St=tt[Wt],Z[Wt]&&(Z[Wt].prePoint=vt)),Zt.currentPoint=vt,Z[Wt]&&nt(vt,Z[Wt].currentPoint)&&(Z[Wt].prePoint=Zt.prePoint);var se=St?[St[St.length-2],St[St.length-1]]:null;Zt.nextPoint=se;var we=Zt.prePoint;if(["L","H","V"].includes(re))Zt.startTangent=[we[0]-vt[0],we[1]-vt[1]],Zt.endTangent=[vt[0]-we[0],vt[1]-we[1]];else if(re==="Q"){var Ae=[Lt[1],Lt[2]];Zt.startTangent=[we[0]-Ae[0],we[1]-Ae[1]],Zt.endTangent=[vt[0]-Ae[0],vt[1]-Ae[1]]}else if(re==="T"){var Ce=Z[Kt-1],Ae=Jt(Ce.currentPoint,we);Ce.command==="Q"?(Zt.command="Q",Zt.startTangent=[we[0]-Ae[0],we[1]-Ae[1]],Zt.endTangent=[vt[0]-Ae[0],vt[1]-Ae[1]]):(Zt.command="TL",Zt.startTangent=[we[0]-vt[0],we[1]-vt[1]],Zt.endTangent=[vt[0]-we[0],vt[1]-we[1]])}else if(re==="C"){var ae=[Lt[1],Lt[2]],Ie=[Lt[3],Lt[4]];Zt.startTangent=[we[0]-ae[0],we[1]-ae[1]],Zt.endTangent=[vt[0]-Ie[0],vt[1]-Ie[1]],Zt.startTangent[0]===0&&Zt.startTangent[1]===0&&(Zt.startTangent=[ae[0]-Ie[0],ae[1]-Ie[1]]),Zt.endTangent[0]===0&&Zt.endTangent[1]===0&&(Zt.endTangent=[Ie[0]-ae[0],Ie[1]-ae[1]])}else if(re==="S"){var Ce=Z[Kt-1],ae=Jt(Ce.currentPoint,we),Ie=[Lt[1],Lt[2]];Ce.command==="C"?(Zt.command="C",Zt.startTangent=[we[0]-ae[0],we[1]-ae[1]],Zt.endTangent=[vt[0]-Ie[0],vt[1]-Ie[1]]):(Zt.command="SQ",Zt.startTangent=[we[0]-Ie[0],we[1]-Ie[1]],Zt.endTangent=[vt[0]-Ie[0],vt[1]-Ie[1]])}else if(re==="A"){var Le=.001,He=Zt.arcParams||{},ze=He.cx,$e=ze===void 0?0:ze,je=He.cy,yr=je===void 0?0:je,wr=He.rx,Sr=wr===void 0?0:wr,cn=He.ry,yn=cn===void 0?0:cn,mn=He.sweepFlag,qn=mn===void 0?0:mn,tn=He.startAngle,Yr=tn===void 0?0:tn,en=He.endAngle,rn=en===void 0?0:en;qn===0&&(Le*=-1);var fn=Sr*Math.cos(Yr-Le)+$e,Kn=yn*Math.sin(Yr-Le)+yr;Zt.startTangent=[fn-Ot[0],Kn-Ot[1]];var xn=Sr*Math.cos(Yr+rn+Le)+$e,jn=yn*Math.sin(Yr+rn-Le)+yr;Zt.endTangent=[we[0]-xn,we[1]-jn]}Z.push(Zt)}return Z}function ne(tt){for(var Z=[],vt=tt.length,St=0;St<vt-1;St++){var Ot=tt[St],Wt=tt[St+1];Z.push({from:{x:Ot[0],y:Ot[1]},to:{x:Wt[0],y:Wt[1]}})}if(Z.length>1){var Ht=tt[0],Kt=tt[vt-1];Z.push({from:{x:Kt[0],y:Kt[1]},to:{x:Ht[0],y:Ht[1]}})}return Z}function qt(tt,Z){var vt=!1;return each(tt,function(St){if(getLineIntersect(St.from,St.to,Z.from,Z.to))return vt=!0,!1}),vt}function Yt(tt){var Z=tt.map(function(St){return St[0]}),vt=tt.map(function(St){return St[1]});return{minX:Math.min.apply(null,Z),maxX:Math.max.apply(null,Z),minY:Math.min.apply(null,vt),maxY:Math.max.apply(null,vt)}}function fe(tt,Z){return!(Z.minX>tt.maxX||Z.maxX<tt.minX||Z.minY>tt.maxY||Z.maxY<tt.minY)}function Pe(tt,Z){if(tt.length<2||Z.length<2)return!1;var vt=Yt(tt),St=Yt(Z);if(!fe(vt,St))return!1;var Ot=!1;if(each(Z,function(Lt){if(isPointInPolygon(tt,Lt[0],Lt[1]))return Ot=!0,!1}),Ot||(each(tt,function(Lt){if(isPointInPolygon(Z,Lt[0],Lt[1]))return Ot=!0,!1}),Ot))return!0;var Wt=ne(tt),Ht=ne(Z),Kt=!1;return each(Ht,function(Lt){if(qt(Wt,Lt))return Kt=!0,!1}),Kt}function Oe(tt,Z){for(var vt=[],St=[],Ot=[],Wt=0;Wt<tt.length;Wt++){var Ht=tt[Wt],Kt=Ht.currentPoint,Lt=Ht.params,re=Ht.prePoint,Zt=void 0;switch(Ht.command){case"Q":Zt=yt.lD.box(re[0],re[1],Lt[1],Lt[2],Lt[3],Lt[4]);break;case"C":Zt=yt.Ll.box(re[0],re[1],Lt[1],Lt[2],Lt[3],Lt[4],Lt[5],Lt[6]);break;case"A":var me=Ht.arcParams;Zt=yt.wN.box(me.cx,me.cy,me.rx,me.ry,me.xRotation,me.startAngle,me.endAngle);break;default:vt.push(Kt[0]),St.push(Kt[1]);break}Zt&&(Ht.box=Zt,vt.push(Zt.x,Zt.x+Zt.width),St.push(Zt.y,Zt.y+Zt.height)),Z&&(Ht.command==="L"||Ht.command==="M")&&Ht.prePoint&&Ht.nextPoint&&Ot.push(Ht)}vt=vt.filter(function(ae){return!Number.isNaN(ae)&&ae!==Infinity&&ae!==-Infinity}),St=St.filter(function(ae){return!Number.isNaN(ae)&&ae!==Infinity&&ae!==-Infinity});var Se=(0,q.VV)(vt),se=(0,q.VV)(St),we=(0,q.Fp)(vt),Ae=(0,q.Fp)(St);if(Ot.length===0)return{x:Se,y:se,width:we-Se,height:Ae-se};for(var Wt=0;Wt<Ot.length;Wt++){var Ht=Ot[Wt],Kt=Ht.currentPoint,Ce=void 0;Kt[0]===Se?(Ce=Be(Ht,Z),Se=Se-Ce.xExtra):Kt[0]===we&&(Ce=Be(Ht,Z),we=we+Ce.xExtra),Kt[1]===se?(Ce=Be(Ht,Z),se=se-Ce.yExtra):Kt[1]===Ae&&(Ce=Be(Ht,Z),Ae=Ae+Ce.yExtra)}return{x:Se,y:se,width:we-Se,height:Ae-se}}function Be(tt,Z){var vt=tt.prePoint,St=tt.currentPoint,Ot=tt.nextPoint,Wt=Math.pow(St[0]-vt[0],2)+Math.pow(St[1]-vt[1],2),Ht=Math.pow(St[0]-Ot[0],2)+Math.pow(St[1]-Ot[1],2),Kt=Math.pow(vt[0]-Ot[0],2)+Math.pow(vt[1]-Ot[1],2),Lt=Math.acos((Wt+Ht-Kt)/(2*Math.sqrt(Wt)*Math.sqrt(Ht)));if(!Lt||Math.sin(Lt)===0||(0,q.vQ)(Lt,0))return{xExtra:0,yExtra:0};var re=Math.abs(Math.atan2(Ot[1]-St[1],Ot[0]-St[0])),Zt=Math.abs(Math.atan2(Ot[0]-St[0],Ot[1]-St[1]));re=re>Math.PI/2?Math.PI-re:re,Zt=Zt>Math.PI/2?Math.PI-Zt:Zt;var me={xExtra:Math.cos(Lt/2-re)*(Z/2*(1/Math.sin(Lt/2)))-Z/2||0,yExtra:Math.cos(Zt-Lt/2)*(Z/2*(1/Math.sin(Lt/2)))-Z/2||0};return me}function cr(tt){var Z=tt.attr(),vt=Z.path,St=Z.stroke,Ot=St?Z.lineWidth:0,Wt=tt.get("segments")||$t(vt),Ht=Oe(Wt,Ot),Kt=Ht.x,Lt=Ht.y,re=Ht.width,Zt=Ht.height,me={minX:Kt,minY:Lt,maxX:Kt+re,maxY:Lt+Zt};return me=xt(tt,me),{x:me.minX,y:me.minY,width:me.maxX-me.minX,height:me.maxY-me.minY}}function Er(tt){var Z=tt.attr(),vt=Z.x1,St=Z.y1,Ot=Z.x2,Wt=Z.y2,Ht=Math.min(vt,Ot),Kt=Math.max(vt,Ot),Lt=Math.min(St,Wt),re=Math.max(St,Wt),Zt={minX:Ht,maxX:Kt,minY:Lt,maxY:re};return Zt=xt(tt,Zt),{x:Zt.minX,y:Zt.minY,width:Zt.maxX-Zt.minX,height:Zt.maxY-Zt.minY}}function _r(tt){var Z=tt.attr(),vt=Z.x,St=Z.y,Ot=Z.rx,Wt=Z.ry;return{x:vt-Ot,y:St-Wt,width:Ot*2,height:Wt*2}}ot("rect",It),ot("image",It),ot("circle",mt),ot("marker",mt),ot("polyline",it),ot("polygon",Ut),ot("text",ft),ot("path",cr),ot("line",Er),ot("ellipse",_r)},89473:function(ge,Xt){"use strict";var N=function(){function et(ot,Dt){this.bubbles=!0,this.target=null,this.currentTarget=null,this.delegateTarget=null,this.delegateObject=null,this.defaultPrevented=!1,this.propagationStopped=!1,this.shape=null,this.fromShape=null,this.toShape=null,this.propagationPath=[],this.type=ot,this.name=ot,this.originalEvent=Dt,this.timeStamp=Dt.timeStamp}return et.prototype.preventDefault=function(){this.defaultPrevented=!0,this.originalEvent.preventDefault&&this.originalEvent.preventDefault()},et.prototype.stopPropagation=function(){this.propagationStopped=!0},et.prototype.toString=function(){var ot=this.type;return"[Event (type="+ot+")]"},et.prototype.save=function(){},et.prototype.restore=function(){},et}();Xt.Z=N},98190:function(ge,Xt,N){"use strict";N.r(Xt),N.d(Xt,{Event:function(){return xt.Z},Base:function(){return it.Z},AbstractCanvas:function(){return Ut.Z},AbstractGroup:function(){return Ft.Z},AbstractShape:function(){return ft.Z},PathUtil:function(){return et},getBBoxMethod:function(){return q.b},registerBBox:function(){return q.W},getTextHeight:function(){return p.FE},assembleFont:function(){return p.$O},isAllowCapture:function(){return f.pP},multiplyVec2:function(){return J.rG},invert:function(){return J.U_},getOffScreenContext:function(){return K.L},registerEasing:function(){return ht.C},version:function(){return Mt}});var et=N(47575),ot=N(52),Dt=N.n(ot),It={};for(var mt in ot)["default","Event","Base","AbstractCanvas","AbstractGroup","AbstractShape","PathUtil","getBBoxMethod","registerBBox","getTextHeight","assembleFont","isAllowCapture","multiplyVec2","invert","getOffScreenContext","registerEasing","version"].indexOf(mt)<0&&(It[mt]=function(X){return ot[X]}.bind(0,mt));N.d(Xt,It);var yt=N(15294),ut=N.n(yt),It={};for(var mt in yt)["default","Event","Base","AbstractCanvas","AbstractGroup","AbstractShape","PathUtil","getBBoxMethod","registerBBox","getTextHeight","assembleFont","isAllowCapture","multiplyVec2","invert","getOffScreenContext","registerEasing","version"].indexOf(mt)<0&&(It[mt]=function(st){return yt[st]}.bind(0,mt));N.d(Xt,It);var xt=N(89473),it=N(2667),Ut=N(96298),Ft=N(31841),ft=N(15032),q=N(63427),p=N(8723),f=N(77341),J=N(41482),K=N(67052),ht=N(97492),Mt="0.5.11"},15294:function(){},52:function(){},41482:function(ge,Xt,N){"use strict";N.d(Xt,{xq:function(){return et},rG:function(){return ot},U_:function(){return Dt}});function et(It,mt){var yt=[],ut=It[0],xt=It[1],it=It[2],Ut=It[3],Ft=It[4],ft=It[5],q=It[6],p=It[7],f=It[8],J=mt[0],K=mt[1],ht=mt[2],Mt=mt[3],X=mt[4],st=mt[5],Et=mt[6],zt=mt[7],jt=mt[8];return yt[0]=J*ut+K*Ut+ht*q,yt[1]=J*xt+K*Ft+ht*p,yt[2]=J*it+K*ft+ht*f,yt[3]=Mt*ut+X*Ut+st*q,yt[4]=Mt*xt+X*Ft+st*p,yt[5]=Mt*it+X*ft+st*f,yt[6]=Et*ut+zt*Ut+jt*q,yt[7]=Et*xt+zt*Ft+jt*p,yt[8]=Et*it+zt*ft+jt*f,yt}function ot(It,mt){var yt=[],ut=mt[0],xt=mt[1];return yt[0]=It[0]*ut+It[3]*xt+It[6],yt[1]=It[1]*ut+It[4]*xt+It[7],yt}function Dt(It){var mt=[],yt=It[0],ut=It[1],xt=It[2],it=It[3],Ut=It[4],Ft=It[5],ft=It[6],q=It[7],p=It[8],f=p*Ut-Ft*q,J=-p*it+Ft*ft,K=q*it-Ut*ft,ht=yt*f+ut*J+xt*K;return ht?(ht=1/ht,mt[0]=f*ht,mt[1]=(-p*ut+xt*q)*ht,mt[2]=(Ft*ut-xt*Ut)*ht,mt[3]=J*ht,mt[4]=(p*yt-xt*ft)*ht,mt[5]=(-Ft*yt+xt*it)*ht,mt[6]=K*ht,mt[7]=(-q*yt+ut*ft)*ht,mt[8]=(Ut*yt-ut*it)*ht,mt):null}},67052:function(ge,Xt,N){"use strict";N.d(Xt,{L:function(){return ot}});var et=null;function ot(){if(!et){var Dt=document.createElement("canvas");Dt.width=1,Dt.height=1,et=Dt.getContext("2d")}return et}},47575:function(ge,Xt,N){"use strict";N.r(Xt),N.d(Xt,{catmullRomToBezier:function(){return yt},fillPath:function(){return Ct},fillPathByDiff:function(){return bt},formatPath:function(){return G},intersection:function(){return pt},parsePathArray:function(){return p},parsePathString:function(){return mt},pathToAbsolute:function(){return xt},pathToCurve:function(){return ft},rectPath:function(){return X}});var et=N(41694),ot=`
  14. \v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,Dt=new RegExp("([a-z])["+ot+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+ot+"]*,?["+ot+"]*)+)","ig"),It=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+ot+"]*,?["+ot+"]*","ig"),mt=function(A){if(!A)return null;if((0,et.kJ)(A))return A;var I={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},D=[];return String(A).replace(Dt,function(E,Q,lt){var P=[],F=Q.toLowerCase();if(lt.replace(It,function(C,_){_&&P.push(+_)}),F==="m"&&P.length>2&&(D.push([Q].concat(P.splice(0,2))),F="l",Q=Q==="m"?"l":"L"),F==="o"&&P.length===1&&D.push([Q,P[0]]),F==="r")D.push([Q].concat(P));else for(;P.length>=I[F]&&(D.push([Q].concat(P.splice(0,I[F]))),!!I[F]););return A}),D},yt=function(A,I){for(var D=[],E=0,Q=A.length;Q-2*!I>E;E+=2){var lt=[{x:+A[E-2],y:+A[E-1]},{x:+A[E],y:+A[E+1]},{x:+A[E+2],y:+A[E+3]},{x:+A[E+4],y:+A[E+5]}];I?E?Q-4===E?lt[3]={x:+A[0],y:+A[1]}:Q-2===E&&(lt[2]={x:+A[0],y:+A[1]},lt[3]={x:+A[2],y:+A[3]}):lt[0]={x:+A[Q-2],y:+A[Q-1]}:Q-4===E?lt[3]=lt[2]:E||(lt[0]={x:+A[E],y:+A[E+1]}),D.push(["C",(-lt[0].x+6*lt[1].x+lt[2].x)/6,(-lt[0].y+6*lt[1].y+lt[2].y)/6,(lt[1].x+6*lt[2].x-lt[3].x)/6,(lt[1].y+6*lt[2].y-lt[3].y)/6,lt[2].x,lt[2].y])}return D},ut=function(A,I,D,E,Q){var lt=[];if(Q===null&&E===null&&(E=D),A=+A,I=+I,D=+D,E=+E,Q!==null){var P=Math.PI/180,F=A+D*Math.cos(-E*P),C=A+D*Math.cos(-Q*P),_=I+D*Math.sin(-E*P),L=I+D*Math.sin(-Q*P);lt=[["M",F,_],["A",D,D,0,+(Q-E>180),0,C,L]]}else lt=[["M",A,I],["m",0,-E],["a",D,E,0,1,1,0,2*E],["a",D,E,0,1,1,0,-2*E],["z"]];return lt},xt=function(A){if(A=mt(A),!A||!A.length)return[["M",0,0]];var I=[],D=0,E=0,Q=0,lt=0,P=0,F,C;A[0][0]==="M"&&(D=+A[0][1],E=+A[0][2],Q=D,lt=E,P++,I[0]=["M",D,E]);for(var _=A.length===3&&A[0][0]==="M"&&A[1][0].toUpperCase()==="R"&&A[2][0].toUpperCase()==="Z",L=void 0,U=void 0,B=P,j=A.length;B<j;B++){if(I.push(L=[]),U=A[B],F=U[0],F!==F.toUpperCase())switch(L[0]=F.toUpperCase(),L[0]){case"A":L[1]=U[1],L[2]=U[2],L[3]=U[3],L[4]=U[4],L[5]=U[5],L[6]=+U[6]+D,L[7]=+U[7]+E;break;case"V":L[1]=+U[1]+E;break;case"H":L[1]=+U[1]+D;break;case"R":C=[D,E].concat(U.slice(1));for(var nt=2,Tt=C.length;nt<Tt;nt++)C[nt]=+C[nt]+D,C[++nt]=+C[nt]+E;I.pop(),I=I.concat(yt(C,_));break;case"O":I.pop(),C=ut(D,E,U[1],U[2]),C.push(C[0]),I=I.concat(C);break;case"U":I.pop(),I=I.concat(ut(D,E,U[1],U[2],U[3])),L=["U"].concat(I[I.length-1].slice(-2));break;case"M":Q=+U[1]+D,lt=+U[2]+E;break;default:for(var nt=1,Tt=U.length;nt<Tt;nt++)L[nt]=+U[nt]+(nt%2?D:E)}else if(F==="R")C=[D,E].concat(U.slice(1)),I.pop(),I=I.concat(yt(C,_)),L=["R"].concat(U.slice(-2));else if(F==="O")I.pop(),C=ut(D,E,U[1],U[2]),C.push(C[0]),I=I.concat(C);else if(F==="U")I.pop(),I=I.concat(ut(D,E,U[1],U[2],U[3])),L=["U"].concat(I[I.length-1].slice(-2));else for(var Jt=0,$t=U.length;Jt<$t;Jt++)L[Jt]=U[Jt];if(F=F.toUpperCase(),F!=="O")switch(L[0]){case"Z":D=+Q,E=+lt;break;case"H":D=L[1];break;case"V":E=L[1];break;case"M":Q=L[L.length-2],lt=L[L.length-1];break;default:D=L[L.length-2],E=L[L.length-1]}}return I},it=function(A,I,D,E){return[A,I,D,E,D,E]},Ut=function(A,I,D,E,Q,lt){var P=1/3,F=2/3;return[P*A+F*D,P*I+F*E,P*Q+F*D,P*lt+F*E,Q,lt]},Ft=function(A,I,D,E,Q,lt,P,F,C,_){D===E&&(D+=1);var L=Math.PI*120/180,U=Math.PI/180*(+Q||0),B=[],j,nt,Tt,Jt,$t,ne=function(Ae,Ce,ae){var Ie=Ae*Math.cos(ae)-Ce*Math.sin(ae),Le=Ae*Math.sin(ae)+Ce*Math.cos(ae);return{x:Ie,y:Le}};if(_)nt=_[0],Tt=_[1],Jt=_[2],$t=_[3];else{j=ne(A,I,-U),A=j.x,I=j.y,j=ne(F,C,-U),F=j.x,C=j.y,A===F&&I===C&&(F+=1,C+=1);var qt=(A-F)/2,Yt=(I-C)/2,fe=qt*qt/(D*D)+Yt*Yt/(E*E);fe>1&&(fe=Math.sqrt(fe),D=fe*D,E=fe*E);var Pe=D*D,Oe=E*E,Be=(lt===P?-1:1)*Math.sqrt(Math.abs((Pe*Oe-Pe*Yt*Yt-Oe*qt*qt)/(Pe*Yt*Yt+Oe*qt*qt)));Jt=Be*D*Yt/E+(A+F)/2,$t=Be*-E*qt/D+(I+C)/2,nt=Math.asin(((I-$t)/E).toFixed(9)),Tt=Math.asin(((C-$t)/E).toFixed(9)),nt=A<Jt?Math.PI-nt:nt,Tt=F<Jt?Math.PI-Tt:Tt,nt<0&&(nt=Math.PI*2+nt),Tt<0&&(Tt=Math.PI*2+Tt),P&&nt>Tt&&(nt=nt-Math.PI*2),!P&&Tt>nt&&(Tt=Tt-Math.PI*2)}var cr=Tt-nt;if(Math.abs(cr)>L){var Er=Tt,_r=F,tt=C;Tt=nt+L*(P&&Tt>nt?1:-1),F=Jt+D*Math.cos(Tt),C=$t+E*Math.sin(Tt),B=Ft(F,C,D,E,Q,0,P,_r,tt,[Tt,Er,Jt,$t])}cr=Tt-nt;var Z=Math.cos(nt),vt=Math.sin(nt),St=Math.cos(Tt),Ot=Math.sin(Tt),Wt=Math.tan(cr/4),Ht=4/3*D*Wt,Kt=4/3*E*Wt,Lt=[A,I],re=[A+Ht*vt,I-Kt*Z],Zt=[F+Ht*Ot,C-Kt*St],me=[F,C];if(re[0]=2*Lt[0]-re[0],re[1]=2*Lt[1]-re[1],_)return[re,Zt,me].concat(B);B=[re,Zt,me].concat(B).join().split(",");for(var Se=[],se=0,we=B.length;se<we;se++)Se[se]=se%2?ne(B[se-1],B[se],U).y:ne(B[se],B[se+1],U).x;return Se},ft=function(A,I){var D=xt(A),E=I&&xt(I),Q={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},lt={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},P=[],F=[],C="",_="",L,U=function(qt,Yt,fe){var Pe,Oe;if(!qt)return["C",Yt.x,Yt.y,Yt.x,Yt.y,Yt.x,Yt.y];switch(!(qt[0]in{T:1,Q:1})&&(Yt.qx=Yt.qy=null),qt[0]){case"M":Yt.X=qt[1],Yt.Y=qt[2];break;case"A":qt=["C"].concat(Ft.apply(0,[Yt.x,Yt.y].concat(qt.slice(1))));break;case"S":fe==="C"||fe==="S"?(Pe=Yt.x*2-Yt.bx,Oe=Yt.y*2-Yt.by):(Pe=Yt.x,Oe=Yt.y),qt=["C",Pe,Oe].concat(qt.slice(1));break;case"T":fe==="Q"||fe==="T"?(Yt.qx=Yt.x*2-Yt.qx,Yt.qy=Yt.y*2-Yt.qy):(Yt.qx=Yt.x,Yt.qy=Yt.y),qt=["C"].concat(Ut(Yt.x,Yt.y,Yt.qx,Yt.qy,qt[1],qt[2]));break;case"Q":Yt.qx=qt[1],Yt.qy=qt[2],qt=["C"].concat(Ut(Yt.x,Yt.y,qt[1],qt[2],qt[3],qt[4]));break;case"L":qt=["C"].concat(it(Yt.x,Yt.y,qt[1],qt[2]));break;case"H":qt=["C"].concat(it(Yt.x,Yt.y,qt[1],Yt.y));break;case"V":qt=["C"].concat(it(Yt.x,Yt.y,Yt.x,qt[1]));break;case"Z":qt=["C"].concat(it(Yt.x,Yt.y,Yt.X,Yt.Y));break;default:break}return qt},B=function(qt,Yt){if(qt[Yt].length>7){qt[Yt].shift();for(var fe=qt[Yt];fe.length;)P[Yt]="A",E&&(F[Yt]="A"),qt.splice(Yt++,0,["C"].concat(fe.splice(0,6)));qt.splice(Yt,1),L=Math.max(D.length,E&&E.length||0)}},j=function(qt,Yt,fe,Pe,Oe){qt&&Yt&&qt[Oe][0]==="M"&&Yt[Oe][0]!=="M"&&(Yt.splice(Oe,0,["M",Pe.x,Pe.y]),fe.bx=0,fe.by=0,fe.x=qt[Oe][1],fe.y=qt[Oe][2],L=Math.max(D.length,E&&E.length||0))};L=Math.max(D.length,E&&E.length||0);for(var nt=0;nt<L;nt++){D[nt]&&(C=D[nt][0]),C!=="C"&&(P[nt]=C,nt&&(_=P[nt-1])),D[nt]=U(D[nt],Q,_),P[nt]!=="A"&&C==="C"&&(P[nt]="C"),B(D,nt),E&&(E[nt]&&(C=E[nt][0]),C!=="C"&&(F[nt]=C,nt&&(_=F[nt-1])),E[nt]=U(E[nt],lt,_),F[nt]!=="A"&&C==="C"&&(F[nt]="C"),B(E,nt)),j(D,E,Q,lt,nt),j(E,D,lt,Q,nt);var Tt=D[nt],Jt=E&&E[nt],$t=Tt.length,ne=E&&Jt.length;Q.x=Tt[$t-2],Q.y=Tt[$t-1],Q.bx=parseFloat(Tt[$t-4])||Q.x,Q.by=parseFloat(Tt[$t-3])||Q.y,lt.bx=E&&(parseFloat(Jt[ne-4])||lt.x),lt.by=E&&(parseFloat(Jt[ne-3])||lt.y),lt.x=E&&Jt[ne-2],lt.y=E&&Jt[ne-1]}return E?[D,E]:D},q=/,?([a-z]),?/gi,p=function(A){return A.join(",").replace(q,"$1")},f=function(A,I,D,E,Q){var lt=-3*I+9*D-9*E+3*Q,P=A*lt+6*I-12*D+6*E;return A*P-3*I+3*D},J=function(A,I,D,E,Q,lt,P,F,C){C===null&&(C=1),C=C>1?1:C<0?0:C;for(var _=C/2,L=12,U=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],B=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],j=0,nt=0;nt<L;nt++){var Tt=_*U[nt]+_,Jt=f(Tt,A,D,Q,P),$t=f(Tt,I,E,lt,F),ne=Jt*Jt+$t*$t;j+=B[nt]*Math.sqrt(ne)}return _*j},K=function(A,I,D,E,Q,lt,P,F){for(var C=[],_=[[],[]],L,U,B,j,nt=0;nt<2;++nt){if(nt===0?(U=6*A-12*D+6*Q,L=-3*A+9*D-9*Q+3*P,B=3*D-3*A):(U=6*I-12*E+6*lt,L=-3*I+9*E-9*lt+3*F,B=3*E-3*I),Math.abs(L)<1e-12){if(Math.abs(U)<1e-12)continue;j=-B/U,j>0&&j<1&&C.push(j);continue}var Tt=U*U-4*B*L,Jt=Math.sqrt(Tt);if(!(Tt<0)){var $t=(-U+Jt)/(2*L);$t>0&&$t<1&&C.push($t);var ne=(-U-Jt)/(2*L);ne>0&&ne<1&&C.push(ne)}}for(var qt=C.length,Yt=qt,fe;qt--;)j=C[qt],fe=1-j,_[0][qt]=fe*fe*fe*A+3*fe*fe*j*D+3*fe*j*j*Q+j*j*j*P,_[1][qt]=fe*fe*fe*I+3*fe*fe*j*E+3*fe*j*j*lt+j*j*j*F;return _[0][Yt]=A,_[1][Yt]=I,_[0][Yt+1]=P,_[1][Yt+1]=F,_[0].length=_[1].length=Yt+2,{min:{x:Math.min.apply(0,_[0]),y:Math.min.apply(0,_[1])},max:{x:Math.max.apply(0,_[0]),y:Math.max.apply(0,_[1])}}},ht=function(A,I,D,E,Q,lt,P,F){if(!(Math.max(A,D)<Math.min(Q,P)||Math.min(A,D)>Math.max(Q,P)||Math.max(I,E)<Math.min(lt,F)||Math.min(I,E)>Math.max(lt,F))){var C=(A*E-I*D)*(Q-P)-(A-D)*(Q*F-lt*P),_=(A*E-I*D)*(lt-F)-(I-E)*(Q*F-lt*P),L=(A-D)*(lt-F)-(I-E)*(Q-P);if(!!L){var U=C/L,B=_/L,j=+U.toFixed(2),nt=+B.toFixed(2);if(!(j<+Math.min(A,D).toFixed(2)||j>+Math.max(A,D).toFixed(2)||j<+Math.min(Q,P).toFixed(2)||j>+Math.max(Q,P).toFixed(2)||nt<+Math.min(I,E).toFixed(2)||nt>+Math.max(I,E).toFixed(2)||nt<+Math.min(lt,F).toFixed(2)||nt>+Math.max(lt,F).toFixed(2)))return{x:U,y:B}}}},Mt=function(A,I,D){return I>=A.x&&I<=A.x+A.width&&D>=A.y&&D<=A.y+A.height},X=function(A,I,D,E,Q){if(Q)return[["M",+A+ +Q,I],["l",D-Q*2,0],["a",Q,Q,0,0,1,Q,Q],["l",0,E-Q*2],["a",Q,Q,0,0,1,-Q,Q],["l",Q*2-D,0],["a",Q,Q,0,0,1,-Q,-Q],["l",0,Q*2-E],["a",Q,Q,0,0,1,Q,-Q],["z"]];var lt=[["M",A,I],["l",D,0],["l",0,E],["l",-D,0],["z"]];return lt.parsePathArray=p,lt},st=function(A,I,D,E){return A===null&&(A=I=D=E=0),I===null&&(I=A.y,D=A.width,E=A.height,A=A.x),{x:A,y:I,width:D,w:D,height:E,h:E,x2:A+D,y2:I+E,cx:A+D/2,cy:I+E/2,r1:Math.min(D,E)/2,r2:Math.max(D,E)/2,r0:Math.sqrt(D*D+E*E)/2,path:X(A,I,D,E),vb:[A,I,D,E].join(" ")}},Et=function(A,I){return A=st(A),I=st(I),Mt(I,A.x,A.y)||Mt(I,A.x2,A.y)||Mt(I,A.x,A.y2)||Mt(I,A.x2,A.y2)||Mt(A,I.x,I.y)||Mt(A,I.x2,I.y)||Mt(A,I.x,I.y2)||Mt(A,I.x2,I.y2)||(A.x<I.x2&&A.x>I.x||I.x<A.x2&&I.x>A.x)&&(A.y<I.y2&&A.y>I.y||I.y<A.y2&&I.y>A.y)},zt=function(A,I,D,E,Q,lt,P,F){(0,et.kJ)(A)||(A=[A,I,D,E,Q,lt,P,F]);var C=K.apply(null,A);return st(C.min.x,C.min.y,C.max.x-C.min.x,C.max.y-C.min.y)},jt=function(A,I,D,E,Q,lt,P,F,C){var _=1-C,L=Math.pow(_,3),U=Math.pow(_,2),B=C*C,j=B*C,nt=L*A+U*3*C*D+_*3*C*C*Q+j*P,Tt=L*I+U*3*C*E+_*3*C*C*lt+j*F,Jt=A+2*C*(D-A)+B*(Q-2*D+A),$t=I+2*C*(E-I)+B*(lt-2*E+I),ne=D+2*C*(Q-D)+B*(P-2*Q+D),qt=E+2*C*(lt-E)+B*(F-2*lt+E),Yt=_*A+C*D,fe=_*I+C*E,Pe=_*Q+C*P,Oe=_*lt+C*F,Be=90-Math.atan2(Jt-ne,$t-qt)*180/Math.PI;return{x:nt,y:Tt,m:{x:Jt,y:$t},n:{x:ne,y:qt},start:{x:Yt,y:fe},end:{x:Pe,y:Oe},alpha:Be}},ee=function(A,I,D){var E=zt(A),Q=zt(I);if(!Et(E,Q))return D?0:[];for(var lt=J.apply(0,A),P=J.apply(0,I),F=~~(lt/8),C=~~(P/8),_=[],L=[],U={},B=D?0:[],j=0;j<F+1;j++){var nt=jt.apply(0,A.concat(j/F));_.push({x:nt.x,y:nt.y,t:j/F})}for(var j=0;j<C+1;j++){var nt=jt.apply(0,I.concat(j/C));L.push({x:nt.x,y:nt.y,t:j/C})}for(var j=0;j<F;j++)for(var Tt=0;Tt<C;Tt++){var Jt=_[j],$t=_[j+1],ne=L[Tt],qt=L[Tt+1],Yt=Math.abs($t.x-Jt.x)<.001?"y":"x",fe=Math.abs(qt.x-ne.x)<.001?"y":"x",Pe=ht(Jt.x,Jt.y,$t.x,$t.y,ne.x,ne.y,qt.x,qt.y);if(Pe){if(U[Pe.x.toFixed(4)]===Pe.y.toFixed(4))continue;U[Pe.x.toFixed(4)]=Pe.y.toFixed(4);var Oe=Jt.t+Math.abs((Pe[Yt]-Jt[Yt])/($t[Yt]-Jt[Yt]))*($t.t-Jt.t),Be=ne.t+Math.abs((Pe[fe]-ne[fe])/(qt[fe]-ne[fe]))*(qt.t-ne.t);Oe>=0&&Oe<=1&&Be>=0&&Be<=1&&(D?B+=1:B.push({x:Pe.x,y:Pe.y,t1:Oe,t2:Be}))}}return B},ye=function(A,I,D){A=ft(A),I=ft(I);for(var E,Q,lt,P,F,C,_,L,U,B,j=D?0:[],nt=0,Tt=A.length;nt<Tt;nt++){var Jt=A[nt];if(Jt[0]==="M")E=F=Jt[1],Q=C=Jt[2];else{Jt[0]==="C"?(U=[E,Q].concat(Jt.slice(1)),E=U[6],Q=U[7]):(U=[E,Q,E,Q,F,C,F,C],E=F,Q=C);for(var $t=0,ne=I.length;$t<ne;$t++){var qt=I[$t];if(qt[0]==="M")lt=_=qt[1],P=L=qt[2];else{qt[0]==="C"?(B=[lt,P].concat(qt.slice(1)),lt=B[6],P=B[7]):(B=[lt,P,lt,P,_,L,_,L],lt=_,P=L);var Yt=ee(U,B,D);if(D)j+=Yt;else{for(var fe=0,Pe=Yt.length;fe<Pe;fe++)Yt[fe].segment1=nt,Yt[fe].segment2=$t,Yt[fe].bez1=U,Yt[fe].bez2=B;j=j.concat(Yt)}}}}}return j},pt=function(A,I){return ye(A,I)};function Pt(A,I){var D=[],E=[];function Q(lt,P){if(lt.length===1)D.push(lt[0]),E.push(lt[0]);else{for(var F=[],C=0;C<lt.length-1;C++)C===0&&D.push(lt[0]),C===lt.length-2&&E.push(lt[C+1]),F[C]=[(1-P)*lt[C][0]+P*lt[C+1][0],(1-P)*lt[C][1]+P*lt[C+1][1]];Q(F,P)}}return A.length&&Q(A,I),{left:D,right:E.reverse()}}function Rt(A,I,D){var E=[[A[1],A[2]]];D=D||2;var Q=[];I[0]==="A"?(E.push(I[6]),E.push(I[7])):I[0]==="C"?(E.push([I[1],I[2]]),E.push([I[3],I[4]]),E.push([I[5],I[6]])):I[0]==="S"||I[0]==="Q"?(E.push([I[1],I[2]]),E.push([I[3],I[4]])):E.push([I[1],I[2]]);for(var lt=E,P=1/D,F=0;F<D-1;F++){var C=P/(1-P*F),_=Pt(lt,C);Q.push(_.left),lt=_.right}Q.push(lt);var L=Q.map(function(U){var B=[];return U.length===4&&(B.push("C"),B=B.concat(U[2])),U.length>=3&&(U.length===3&&B.push("Q"),B=B.concat(U[1])),U.length===2&&B.push("L"),B=B.concat(U[U.length-1]),B});return L}var Bt=function(A,I,D){if(D===1)return[[].concat(A)];var E=[];if(I[0]==="L"||I[0]==="C"||I[0]==="Q")E=E.concat(Rt(A,I,D));else{var Q=[].concat(A);Q[0]==="M"&&(Q[0]="L");for(var lt=0;lt<=D-1;lt++)E.push(Q)}return E},Ct=function(A,I){if(A.length===1)return A;var D=A.length-1,E=I.length-1,Q=D/E,lt=[];if(A.length===1&&A[0][0]==="M"){for(var P=0;P<E-D;P++)A.push(A[0]);return A}for(var P=0;P<E;P++){var F=Math.floor(Q*P);lt[F]=(lt[F]||0)+1}var C=lt.reduce(function(_,L,U){return U===D?_.concat(A[D]):_.concat(Bt(A[U],A[U+1],L))},[]);return C.unshift(A[0]),(I[E]==="Z"||I[E]==="z")&&C.push("Z"),C},wt=function(A,I){if(A.length!==I.length)return!1;var D=!0;return(0,et.S6)(A,function(E,Q){if(E!==I[Q])return D=!1,!1}),D};function T(A,I,D){var E=null,Q=D;return I<Q&&(Q=I,E="add"),A<Q&&(Q=A,E="del"),{type:E,min:Q}}var z=function(A,I){var D=A.length,E=I.length,Q,lt,P=0;if(D===0||E===0)return null;for(var F=[],C=0;C<=D;C++)F[C]=[],F[C][0]={min:C};for(var _=0;_<=E;_++)F[0][_]={min:_};for(var C=1;C<=D;C++){Q=A[C-1];for(var _=1;_<=E;_++){lt=I[_-1],wt(Q,lt)?P=0:P=1;var L=F[C-1][_].min+1,U=F[C][_-1].min+1,B=F[C-1][_-1].min+P;F[C][_]=T(L,U,B)}}return F},bt=function(A,I){var D=z(A,I),E=A.length,Q=I.length,lt=[],P=1,F=1;if(D[E][Q].min!==E){for(var C=1;C<=E;C++){var _=D[C][C].min;F=C;for(var L=P;L<=Q;L++)D[C][L].min<_&&(_=D[C][L].min,F=L);P=F,D[C][P].type&&lt.push({index:C-1,type:D[C][P].type})}for(var C=lt.length-1;C>=0;C--)P=lt[C].index,lt[C].type==="add"?A.splice(P,0,[].concat(A[P])):A.splice(P,1)}E=A.length;var U=Q-E;if(E<Q)for(var C=0;C<U;C++)A[E-1][0]==="z"||A[E-1][0]==="Z"?A.splice(E-2,0,A[E-2]):A.push(A[E-1]),E+=1;return A};function Y(A,I,D){for(var E=[].concat(A),Q,lt=1/(D+1),P=V(I)[0],F=1;F<=D;F++)lt*=F,Q=Math.floor(A.length*lt),Q===0?E.unshift([P[0]*lt+A[Q][0]*(1-lt),P[1]*lt+A[Q][1]*(1-lt)]):E.splice(Q,0,[P[0]*lt+A[Q][0]*(1-lt),P[1]*lt+A[Q][1]*(1-lt)]);return E}function V(A){var I=[];switch(A[0]){case"M":I.push([A[1],A[2]]);break;case"L":I.push([A[1],A[2]]);break;case"A":I.push([A[6],A[7]]);break;case"Q":I.push([A[3],A[4]]),I.push([A[1],A[2]]);break;case"T":I.push([A[1],A[2]]);break;case"C":I.push([A[5],A[6]]),I.push([A[1],A[2]]),I.push([A[3],A[4]]);break;case"S":I.push([A[3],A[4]]),I.push([A[1],A[2]]);break;case"H":I.push([A[1],A[1]]);break;case"V":I.push([A[1],A[1]]);break;default:}return I}var G=function(A,I){if(A.length<=1)return A;for(var D,E=0;E<I.length;E++)if(A[E][0]!==I[E][0])switch(D=V(A[E]),I[E][0]){case"M":A[E]=["M"].concat(D[0]);break;case"L":A[E]=["L"].concat(D[0]);break;case"A":A[E]=[].concat(I[E]),A[E][6]=D[0][0],A[E][7]=D[0][1];break;case"Q":if(D.length<2)if(E>0)D=Y(D,A[E-1],1);else{A[E]=I[E];break}A[E]=["Q"].concat(D.reduce(function(Q,lt){return Q.concat(lt)},[]));break;case"T":A[E]=["T"].concat(D[0]);break;case"C":if(D.length<3)if(E>0)D=Y(D,A[E-1],2);else{A[E]=I[E];break}A[E]=["C"].concat(D.reduce(function(Q,lt){return Q.concat(lt)},[]));break;case"S":if(D.length<2)if(E>0)D=Y(D,A[E-1],1);else{A[E]=I[E];break}A[E]=["S"].concat(D.reduce(function(Q,lt){return Q.concat(lt)},[]));break;default:A[E]=I[E]}return A}},8723:function(ge,Xt,N){"use strict";N.d(Xt,{FE:function(){return Dt},mY:function(){return mt},$O:function(){return yt}});var et=N(77341),ot=N(67052);function Dt(ut,xt,it){var Ut=1;if((0,et.HD)(ut)&&(Ut=ut.split(`
  15. `).length),Ut>1){var Ft=It(xt,it);return xt*Ut+Ft*(Ut-1)}return xt}function It(ut,xt){return xt?xt-ut:ut*.14}function mt(ut,xt){var it=(0,ot.L)(),Ut=0;if((0,et.kK)(ut)||ut==="")return Ut;if(it.save(),it.font=xt,(0,et.HD)(ut)&&ut.includes(`
  16. `)){var Ft=ut.split(`
  17. `);(0,et.S6)(Ft,function(ft){var q=it.measureText(ft).width;Ut<q&&(Ut=q)})}else Ut=it.measureText(ut).width;return it.restore(),Ut}function yt(ut){var xt=ut.fontSize,it=ut.fontFamily,Ut=ut.fontWeight,Ft=ut.fontStyle,ft=ut.fontVariant;return[Ft,ft,Ut,xt+"px",it].join(" ").trim()}},77341:function(ge,Xt,N){"use strict";N.d(Xt,{As:function(){return ot},jU:function(){return Dt},kK:function(){return et.UM},mf:function(){return et.mf},HD:function(){return et.HD},Kn:function(){return et.Kn},CD:function(){return et.CD},S6:function(){return et.S6},jC:function(){return et.jC},UY:function(){return It},pP:function(){return mt}});var et=N(41694);function ot(yt,ut){var xt=yt.indexOf(ut);xt!==-1&&yt.splice(xt,1)}var Dt=typeof window!="undefined"&&typeof window.document!="undefined";function It(yt,ut){if(yt.isCanvas())return!0;for(var xt=ut.getParent(),it=!1;xt;){if(xt===yt){it=!0;break}xt=xt.getParent()}return it}function mt(yt){return yt.cfg.visible&&yt.cfg.capture}},89838:function(ge,Xt,N){"use strict";N.d(Xt,{wN:function(){return Y},Ll:function(){return jt},x1:function(){return it},aH:function(){return E},lD:function(){return ht},Zr:function(){return et}});var et={};N.r(et),N.d(et,{distance:function(){return Dt},getBBoxByArray:function(){return mt},getBBoxRange:function(){return yt},isNumberEqual:function(){return It},piMod:function(){return ut}});var ot=N(41694);function Dt(P,F,C,_){var L=P-C,U=F-_;return Math.sqrt(L*L+U*U)}function It(P,F){return Math.abs(P-F)<.001}function mt(P,F){var C=(0,ot.VV)(P),_=(0,ot.VV)(F),L=(0,ot.Fp)(P),U=(0,ot.Fp)(F);return{x:C,y:_,width:L-C,height:U-_}}function yt(P,F,C,_){return{minX:(0,ot.VV)([P,C]),maxX:(0,ot.Fp)([P,C]),minY:(0,ot.VV)([F,_]),maxY:(0,ot.Fp)([F,_])}}function ut(P){return(P+Math.PI*2)%(Math.PI*2)}var xt=N(31437),it={box:function(P,F,C,_){return mt([P,C],[F,_])},length:function(P,F,C,_){return Dt(P,F,C,_)},pointAt:function(P,F,C,_,L){return{x:(1-L)*P+L*C,y:(1-L)*F+L*_}},pointDistance:function(P,F,C,_,L,U){var B=(C-P)*(L-P)+(_-F)*(U-F);if(B<0)return Dt(P,F,L,U);var j=(C-P)*(C-P)+(_-F)*(_-F);return B>j?Dt(C,_,L,U):this.pointToLine(P,F,C,_,L,U)},pointToLine:function(P,F,C,_,L,U){var B=[C-P,_-F];if(xt.I6(B,[0,0]))return Math.sqrt((L-P)*(L-P)+(U-F)*(U-F));var j=[-B[1],B[0]];xt.Fv(j,j);var nt=[L-P,U-F];return Math.abs(xt.AK(nt,j))},tangentAngle:function(P,F,C,_){return Math.atan2(_-F,C-P)}},Ut=1e-4;function Ft(P,F,C,_,L,U){var B,j=Infinity,nt=[C,_],Tt=20;U&&U>200&&(Tt=U/10);for(var Jt=1/Tt,$t=Jt/10,ne=0;ne<=Tt;ne++){var qt=ne*Jt,Yt=[L.apply(null,P.concat([qt])),L.apply(null,F.concat([qt]))],fe=Dt(nt[0],nt[1],Yt[0],Yt[1]);fe<j&&(B=qt,j=fe)}if(B===0)return{x:P[0],y:F[0]};if(B===1){var Pe=P.length;return{x:P[Pe-1],y:F[Pe-1]}}j=Infinity;for(var ne=0;ne<32&&!($t<Ut);ne++){var Oe=B-$t,Be=B+$t,Yt=[L.apply(null,P.concat([Oe])),L.apply(null,F.concat([Oe]))],fe=Dt(nt[0],nt[1],Yt[0],Yt[1]);if(Oe>=0&&fe<j)B=Oe,j=fe;else{var cr=[L.apply(null,P.concat([Be])),L.apply(null,F.concat([Be]))],Er=Dt(nt[0],nt[1],cr[0],cr[1]);Be<=1&&Er<j?(B=Be,j=Er):$t*=.5}}return{x:L.apply(null,P.concat([B])),y:L.apply(null,F.concat([B]))}}function ft(P,F){for(var C=0,_=P.length,L=0;L<_;L++){var U=P[L],B=F[L],j=P[(L+1)%_],nt=F[(L+1)%_];C+=Dt(U,B,j,nt)}return C/2}function q(P,F,C,_){var L=1-_;return L*L*P+2*_*L*F+_*_*C}function p(P,F,C){var _=P+C-2*F;if(It(_,0))return[.5];var L=(P-F)/_;return L<=1&&L>=0?[L]:[]}function f(P,F,C,_){return 2*(1-_)*(F-P)+2*_*(C-F)}function J(P,F,C,_,L,U,B){var j=q(P,C,L,B),nt=q(F,_,U,B),Tt=it.pointAt(P,F,C,_,B),Jt=it.pointAt(C,_,L,U,B);return[[P,F,Tt.x,Tt.y,j,nt],[j,nt,Jt.x,Jt.y,L,U]]}function K(P,F,C,_,L,U,B){if(B===0)return(Dt(P,F,C,_)+Dt(C,_,L,U)+Dt(P,F,L,U))/2;var j=J(P,F,C,_,L,U,.5),nt=j[0],Tt=j[1];return nt.push(B-1),Tt.push(B-1),K.apply(null,nt)+K.apply(null,Tt)}var ht={box:function(P,F,C,_,L,U){var B=p(P,C,L)[0],j=p(F,_,U)[0],nt=[P,L],Tt=[F,U];return B!==void 0&&nt.push(q(P,C,L,B)),j!==void 0&&Tt.push(q(F,_,U,j)),mt(nt,Tt)},length:function(P,F,C,_,L,U){return K(P,F,C,_,L,U,3)},nearestPoint:function(P,F,C,_,L,U,B,j){return Ft([P,C,L],[F,_,U],B,j,q)},pointDistance:function(P,F,C,_,L,U,B,j){var nt=this.nearestPoint(P,F,C,_,L,U,B,j);return Dt(nt.x,nt.y,B,j)},interpolationAt:q,pointAt:function(P,F,C,_,L,U,B){return{x:q(P,C,L,B),y:q(F,_,U,B)}},divide:function(P,F,C,_,L,U,B){return J(P,F,C,_,L,U,B)},tangentAngle:function(P,F,C,_,L,U,B){var j=f(P,C,L,B),nt=f(F,_,U,B),Tt=Math.atan2(nt,j);return ut(Tt)}};function Mt(P,F,C,_,L){var U=1-L;return U*U*U*P+3*F*L*U*U+3*C*L*L*U+_*L*L*L}function X(P,F,C,_,L){var U=1-L;return 3*(U*U*(F-P)+2*U*L*(C-F)+L*L*(_-C))}function st(P,F,C,_){var L=-3*P+9*F-9*C+3*_,U=6*P-12*F+6*C,B=3*F-3*P,j=[],nt,Tt,Jt;if(It(L,0))It(U,0)||(nt=-B/U,nt>=0&&nt<=1&&j.push(nt));else{var $t=U*U-4*L*B;It($t,0)?j.push(-U/(2*L)):$t>0&&(Jt=Math.sqrt($t),nt=(-U+Jt)/(2*L),Tt=(-U-Jt)/(2*L),nt>=0&&nt<=1&&j.push(nt),Tt>=0&&Tt<=1&&j.push(Tt))}return j}function Et(P,F,C,_,L,U,B,j,nt){var Tt=Mt(P,C,L,B,nt),Jt=Mt(F,_,U,j,nt),$t=it.pointAt(P,F,C,_,nt),ne=it.pointAt(C,_,L,U,nt),qt=it.pointAt(L,U,B,j,nt),Yt=it.pointAt($t.x,$t.y,ne.x,ne.y,nt),fe=it.pointAt(ne.x,ne.y,qt.x,qt.y,nt);return[[P,F,$t.x,$t.y,Yt.x,Yt.y,Tt,Jt],[Tt,Jt,fe.x,fe.y,qt.x,qt.y,B,j]]}function zt(P,F,C,_,L,U,B,j,nt){if(nt===0)return ft([P,C,L,B],[F,_,U,j]);var Tt=Et(P,F,C,_,L,U,B,j,.5),Jt=Tt[0],$t=Tt[1];return Jt.push(nt-1),$t.push(nt-1),zt.apply(null,Jt)+zt.apply(null,$t)}var jt={extrema:st,box:function(P,F,C,_,L,U,B,j){for(var nt=[P,B],Tt=[F,j],Jt=st(P,C,L,B),$t=st(F,_,U,j),ne=0;ne<Jt.length;ne++)nt.push(Mt(P,C,L,B,Jt[ne]));for(var ne=0;ne<$t.length;ne++)Tt.push(Mt(F,_,U,j,$t[ne]));return mt(nt,Tt)},length:function(P,F,C,_,L,U,B,j){return zt(P,F,C,_,L,U,B,j,3)},nearestPoint:function(P,F,C,_,L,U,B,j,nt,Tt,Jt){return Ft([P,C,L,B],[F,_,U,j],nt,Tt,Mt,Jt)},pointDistance:function(P,F,C,_,L,U,B,j,nt,Tt,Jt){var $t=this.nearestPoint(P,F,C,_,L,U,B,j,nt,Tt,Jt);return Dt($t.x,$t.y,nt,Tt)},interpolationAt:Mt,pointAt:function(P,F,C,_,L,U,B,j,nt){return{x:Mt(P,C,L,B,nt),y:Mt(F,_,U,j,nt)}},divide:function(P,F,C,_,L,U,B,j,nt){return Et(P,F,C,_,L,U,B,j,nt)},tangentAngle:function(P,F,C,_,L,U,B,j,nt){var Tt=X(P,C,L,B,nt),Jt=X(F,_,U,j,nt);return ut(Math.atan2(Jt,Tt))}};function ee(P,F){var C=Math.abs(P);return F>0?C:C*-1}var ye={box:function(P,F,C,_){return{x:P-C,y:F-_,width:C*2,height:_*2}},length:function(P,F,C,_){return Math.PI*(3*(C+_)-Math.sqrt((3*C+_)*(C+3*_)))},nearestPoint:function(P,F,C,_,L,U){var B=C,j=_;if(B===0||j===0)return{x:P,y:F};for(var nt=L-P,Tt=U-F,Jt=Math.abs(nt),$t=Math.abs(Tt),ne=B*B,qt=j*j,Yt=Math.PI/4,fe,Pe,Oe=0;Oe<4;Oe++){fe=B*Math.cos(Yt),Pe=j*Math.sin(Yt);var Be=(ne-qt)*Math.pow(Math.cos(Yt),3)/B,cr=(qt-ne)*Math.pow(Math.sin(Yt),3)/j,Er=fe-Be,_r=Pe-cr,tt=Jt-Be,Z=$t-cr,vt=Math.hypot(_r,Er),St=Math.hypot(Z,tt),Ot=vt*Math.asin((Er*Z-_r*tt)/(vt*St)),Wt=Ot/Math.sqrt(ne+qt-fe*fe-Pe*Pe);Yt+=Wt,Yt=Math.min(Math.PI/2,Math.max(0,Yt))}return{x:P+ee(fe,nt),y:F+ee(Pe,Tt)}},pointDistance:function(P,F,C,_,L,U){var B=this.nearestPoint(P,F,C,_,L,U);return Dt(B.x,B.y,L,U)},pointAt:function(P,F,C,_,L){var U=2*Math.PI*L;return{x:P+C*Math.cos(U),y:F+_*Math.sin(U)}},tangentAngle:function(P,F,C,_,L){var U=2*Math.PI*L,B=Math.atan2(_*Math.cos(U),-C*Math.sin(U));return ut(B)}};function pt(P,F,C,_,L,U,B,j){return-1*C*Math.cos(L)*Math.sin(j)-_*Math.sin(L)*Math.cos(j)}function Pt(P,F,C,_,L,U,B,j){return-1*C*Math.sin(L)*Math.sin(j)+_*Math.cos(L)*Math.cos(j)}function Rt(P,F,C){return Math.atan(-F/P*Math.tan(C))}function Bt(P,F,C){return Math.atan(F/(P*Math.tan(C)))}function Ct(P,F,C,_,L,U){return C*Math.cos(L)*Math.cos(U)-_*Math.sin(L)*Math.sin(U)+P}function wt(P,F,C,_,L,U){return C*Math.sin(L)*Math.cos(U)+_*Math.cos(L)*Math.sin(U)+F}function T(P,F,C,_){var L=Math.atan2(_*P,C*F);return(L+Math.PI*2)%(Math.PI*2)}function z(P,F,C){return{x:P*Math.cos(C),y:F*Math.sin(C)}}function bt(P,F,C){var _=Math.cos(C),L=Math.sin(C);return[P*_-F*L,P*L+F*_]}var Y={box:function(P,F,C,_,L,U,B){for(var j=Rt(C,_,L),nt=Infinity,Tt=-Infinity,Jt=[U,B],$t=-Math.PI*2;$t<=Math.PI*2;$t+=Math.PI){var ne=j+$t;U<B?U<ne&&ne<B&&Jt.push(ne):B<ne&&ne<U&&Jt.push(ne)}for(var $t=0;$t<Jt.length;$t++){var qt=Ct(P,F,C,_,L,Jt[$t]);qt<nt&&(nt=qt),qt>Tt&&(Tt=qt)}for(var Yt=Bt(C,_,L),fe=Infinity,Pe=-Infinity,Oe=[U,B],$t=-Math.PI*2;$t<=Math.PI*2;$t+=Math.PI){var Be=Yt+$t;U<B?U<Be&&Be<B&&Oe.push(Be):B<Be&&Be<U&&Oe.push(Be)}for(var $t=0;$t<Oe.length;$t++){var cr=wt(P,F,C,_,L,Oe[$t]);cr<fe&&(fe=cr),cr>Pe&&(Pe=cr)}return{x:nt,y:fe,width:Tt-nt,height:Pe-fe}},length:function(P,F,C,_,L,U,B){},nearestPoint:function(P,F,C,_,L,U,B,j,nt){var Tt=bt(j-P,nt-F,-L),Jt=Tt[0],$t=Tt[1],ne=ye.nearestPoint(0,0,C,_,Jt,$t),qt=T(C,_,ne.x,ne.y);qt<U?ne=z(C,_,U):qt>B&&(ne=z(C,_,B));var Yt=bt(ne.x,ne.y,L);return{x:Yt[0]+P,y:Yt[1]+F}},pointDistance:function(P,F,C,_,L,U,B,j,nt){var Tt=this.nearestPoint(P,F,C,_,j,nt);return Dt(Tt.x,Tt.y,j,nt)},pointAt:function(P,F,C,_,L,U,B,j){var nt=(B-U)*j+U;return{x:Ct(P,F,C,_,L,nt),y:wt(P,F,C,_,L,nt)}},tangentAngle:function(P,F,C,_,L,U,B,j){var nt=(B-U)*j+U,Tt=pt(P,F,C,_,L,U,B,nt),Jt=Pt(P,F,C,_,L,U,B,nt);return ut(Math.atan2(Jt,Tt))}};function V(P){for(var F=0,C=[],_=0;_<P.length-1;_++){var L=P[_],U=P[_+1],B=Dt(L[0],L[1],U[0],U[1]),j={from:L,to:U,length:B};C.push(j),F+=B}return{segments:C,totalLength:F}}function G(P){if(P.length<2)return 0;for(var F=0,C=0;C<P.length-1;C++){var _=P[C],L=P[C+1];F+=Dt(_[0],_[1],L[0],L[1])}return F}function A(P,F){if(F>1||F<0||P.length<2)return null;var C=V(P),_=C.segments,L=C.totalLength;if(L===0)return{x:P[0][0],y:P[0][1]};for(var U=0,B=null,j=0;j<_.length;j++){var nt=_[j],Tt=nt.from,Jt=nt.to,$t=nt.length/L;if(F>=U&&F<=U+$t){var ne=(F-U)/$t;B=it.pointAt(Tt[0],Tt[1],Jt[0],Jt[1],ne);break}U+=$t}return B}function I(P,F){if(F>1||F<0||P.length<2)return 0;for(var C=V(P),_=C.segments,L=C.totalLength,U=0,B=0,j=0;j<_.length;j++){var nt=_[j],Tt=nt.from,Jt=nt.to,$t=nt.length/L;if(F>=U&&F<=U+$t){B=Math.atan2(Jt[1]-Tt[1],Jt[0]-Tt[0]);break}U+=$t}return B}function D(P,F,C){for(var _=Infinity,L=0;L<P.length-1;L++){var U=P[L],B=P[L+1],j=it.pointDistance(U[0],U[1],B[0],B[1],F,C);j<_&&(_=j)}return _}var E={box:function(P){for(var F=[],C=[],_=0;_<P.length;_++){var L=P[_];F.push(L[0]),C.push(L[1])}return mt(F,C)},length:function(P){return G(P)},pointAt:function(P,F){return A(P,F)},pointDistance:function(P,F,C){return D(P,F,C)},tangentAngle:function(P,F){return I(P,F)}};function Q(P){var F=P.slice(0);return P.length&&F.push(P[0]),F}var lt={box:function(P){return E.box(P)},length:function(P){return G(Q(P))},pointAt:function(P,F){return A(Q(P),F)},pointDistance:function(P,F,C){return D(Q(P),F,C)},tangentAngle:function(P,F){return I(Q(P),F)}}},10572:function(ge,Xt,N){"use strict";N.d(Xt,{uN:function(){return ug},sg:function(){return dg},x1:function(){return Lg},by:function(){return Ng}});var et={};N.r(et),N.d(et,{assign:function(){return Sn},default:function(){return Xo},defaultI18n:function(){return Uo},format:function(){return Yo},parse:function(){return La},setGlobalDateI18n:function(){return zo},setGlobalDateMasks:function(){return Pa}});var ot={};N.r(ot),N.d(ot,{Arc:function(){return Km},DataMarker:function(){return rx},DataRegion:function(){return ix},Html:function(){return px},Image:function(){return tx},Line:function(){return Wm},Region:function(){return Jm},RegionFilter:function(){return ox},Shape:function(){return lx},Text:function(){return $m}});var Dt={};N.r(Dt),N.d(Dt,{ellipsisHead:function(){return mx},ellipsisMiddle:function(){return xx},ellipsisTail:function(){return Jf},getDefault:function(){return yx}});var It={};N.r(It),N.d(It,{equidistance:function(){return eh},equidistanceWithReverseBoth:function(){return bx},getDefault:function(){return wx},reserveBoth:function(){return Ax},reserveFirst:function(){return Sx},reserveLast:function(){return Cx}});var mt={};N.r(mt),N.d(mt,{fixedAngle:function(){return nh},getDefault:function(){return Ex},unfixedAngle:function(){return _x}});var yt={};N.r(yt),N.d(yt,{autoEllipsis:function(){return Dt},autoHide:function(){return It},autoRotate:function(){return mt}});var ut={};N.r(ut),N.d(ut,{Base:function(){return su},Circle:function(){return Bx},Html:function(){return Ux},Line:function(){return ih}});var xt={};N.r(xt),N.d(xt,{CONTAINER_CLASS:function(){return Rn},CROSSHAIR_X:function(){return vu},CROSSHAIR_Y:function(){return du},LIST_CLASS:function(){return Ya},LIST_ITEM_CLASS:function(){return is},MARKER_CLASS:function(){return as},NAME_CLASS:function(){return uh},TITLE_CLASS:function(){return Nn},VALUE_CLASS:function(){return os}});var it={};N.r(it),N.d(it,{Base:function(){return dn},Circle:function(){return T2},Ellipse:function(){return _2},Image:function(){return I2},Line:function(){return L2},Marker:function(){return iS},Path:function(){return tc},Polygon:function(){return vS},Polyline:function(){return pS},Rect:function(){return xS},Text:function(){return wS}});var Ut={};N.r(Ut),N.d(Ut,{Canvas:function(){return AS},Group:function(){return $u},Shape:function(){return it},getArcParams:function(){return Es},version:function(){return bS}});var Ft={};N.r(Ft),N.d(Ft,{Base:function(){return on},Circle:function(){return PS},Dom:function(){return DS},Ellipse:function(){return kS},Image:function(){return RS},Line:function(){return US},Marker:function(){return VS},Path:function(){return GS},Polygon:function(){return XS},Polyline:function(){return ZS},Rect:function(){return JS},Text:function(){return iC}});var ft={};N.r(ft),N.d(ft,{Canvas:function(){return bC},Group:function(){return rc},Shape:function(){return Ft},version:function(){return TC}});var q={};N.r(q),N.d(q,{cluster:function(){return xO},hierarchy:function(){return Ca},pack:function(){return M0},packEnclose:function(){return v0},packSiblings:function(){return UP},partition:function(){return ey},stratify:function(){return CO},tree:function(){return FO},treemap:function(){return oy},treemapBinary:function(){return IO},treemapDice:function(){return Fo},treemapResquarify:function(){return LO},treemapSlice:function(){return ml},treemapSliceDice:function(){return PO},treemapSquarify:function(){return ay}});var p=N(65353),f=N(41694),J;(function(r){r.FORE="fore",r.MID="mid",r.BG="bg"})(J||(J={}));var K;(function(r){r.TOP="top",r.TOP_LEFT="top-left",r.TOP_RIGHT="top-right",r.RIGHT="right",r.RIGHT_TOP="right-top",r.RIGHT_BOTTOM="right-bottom",r.LEFT="left",r.LEFT_TOP="left-top",r.LEFT_BOTTOM="left-bottom",r.BOTTOM="bottom",r.BOTTOM_LEFT="bottom-left",r.BOTTOM_RIGHT="bottom-right",r.RADIUS="radius",r.CIRCLE="circle",r.NONE="none"})(K||(K={}));var ht;(function(r){r.AXIS="axis",r.GRID="grid",r.LEGEND="legend",r.TOOLTIP="tooltip",r.ANNOTATION="annotation",r.SLIDER="slider",r.SCROLLBAR="scrollbar",r.OTHER="other"})(ht||(ht={}));var Mt={FORE:3,MID:2,BG:1},X;(function(r){r.BEFORE_RENDER="beforerender",r.AFTER_RENDER="afterrender",r.BEFORE_PAINT="beforepaint",r.AFTER_PAINT="afterpaint",r.BEFORE_CHANGE_DATA="beforechangedata",r.AFTER_CHANGE_DATA="afterchangedata",r.BEFORE_CLEAR="beforeclear",r.AFTER_CLEAR="afterclear",r.BEFORE_DESTROY="beforedestroy",r.BEFORE_CHANGE_SIZE="beforechangesize",r.AFTER_CHANGE_SIZE="afterchangesize"})(X||(X={}));var st;(function(r){r.BEFORE_DRAW_ANIMATE="beforeanimate",r.AFTER_DRAW_ANIMATE="afteranimate",r.BEFORE_RENDER_LABEL="beforerenderlabel",r.AFTER_RENDER_LABEL="afterrenderlabel"})(st||(st={}));var Et;(function(r){r.MOUSE_ENTER="plot:mouseenter",r.MOUSE_DOWN="plot:mousedown",r.MOUSE_MOVE="plot:mousemove",r.MOUSE_UP="plot:mouseup",r.MOUSE_LEAVE="plot:mouseleave",r.TOUCH_START="plot:touchstart",r.TOUCH_MOVE="plot:touchmove",r.TOUCH_END="plot:touchend",r.TOUCH_CANCEL="plot:touchcancel",r.CLICK="plot:click",r.DBLCLICK="plot:dblclick",r.CONTEXTMENU="plot:contextmenu",r.LEAVE="plot:leave",r.ENTER="plot:enter"})(Et||(Et={}));var zt;(function(r){r.ACTIVE="active",r.INACTIVE="inactive",r.SELECTED="selected",r.DEFAULT="default"})(zt||(zt={}));var jt=["color","shape","size"],ee="_origin",ye=1,pt=1,Pt=.25,Rt={};function Bt(r){var e=Rt[r];if(!e)throw new Error("G engine '".concat(r,"' is not exist, please register it at first."));return e}function Ct(r,e){Rt[r]=e}var wt,T,z,bt;function Y(){wt=document.createElement("table"),T=document.createElement("tr"),z=/^\s*<(\w+|!)[^>]*>/,bt={tr:document.createElement("tbody"),tbody:wt,thead:wt,tfoot:wt,td:T,th:T,"*":document.createElement("div")}}function V(r){wt||Y();var e=z.test(r)&&RegExp.$1;(!e||!(e in bt))&&(e="*");var t=bt[e];r=typeof r=="string"?r.replace(/(^\s*)|(\s*$)/g,""):r,t.innerHTML=""+r;var n=t.childNodes[0];return n&&t.contains(n)&&t.removeChild(n),n}function G(r,e){if(r)for(var t in e)e.hasOwnProperty(t)&&(r.style[t]=e[t]);return r}function A(r){var e=getComputedStyle(r);return{width:(r.clientWidth||parseInt(e.width,10))-parseInt(e.paddingLeft,10)-parseInt(e.paddingRight,10),height:(r.clientHeight||parseInt(e.height,10))-parseInt(e.paddingTop,10)-parseInt(e.paddingBottom,10)}}function I(r){return typeof r=="number"&&!isNaN(r)}function D(r,e,t,n){var i=t,a=n;if(e){var o=A(r);i=o.width?o.width:i,a=o.height?o.height:a}return{width:Math.max(I(i)?i:ye,ye),height:Math.max(I(a)?a:pt,pt)}}function E(r){var e=r.parentNode;e&&e.removeChild(r)}var Q=N(90494),lt=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this)||this;n.destroyed=!1;var i=t.visible,a=i===void 0?!0:i;return n.visible=a,n}return e.prototype.show=function(){var t=this.visible;t||this.changeVisible(!0)},e.prototype.hide=function(){var t=this.visible;t&&this.changeVisible(!1)},e.prototype.destroy=function(){this.off(),this.destroyed=!0},e.prototype.changeVisible=function(t){this.visible!==t&&(this.visible=t)},e}(Q.Z),P=lt,F=N(98190),C=0,_=1/2,L=1/2,U=.05,B=function(){function r(e){var t=e.xField,n=e.yField,i=e.adjustNames,a=i===void 0?["x","y"]:i,o=e.dimValuesMap;this.adjustNames=a,this.xField=t,this.yField=n,this.dimValuesMap=o}return r.prototype.isAdjust=function(e){return this.adjustNames.indexOf(e)>=0},r.prototype.getAdjustRange=function(e,t,n){var i=this.yField,a=n.indexOf(t),o=n.length,s,l;return!i&&this.isAdjust("y")?(s=0,l=1):o>1?(s=n[a===0?0:a-1],l=n[a===o-1?o-1:a+1],a!==0?s+=(t-s)/2:s-=(l-t)/2,a!==o-1?l-=(l-t)/2:l+=(t-n[o-2])/2):(s=t===0?0:t-.5,l=t===0?1:t+.5),{pre:s,next:l}},r.prototype.adjustData=function(e,t){var n=this,i=this.getDimValues(t);f.S6(e,function(a,o){f.S6(i,function(s,l){n.adjustDim(l,s,a,o)})})},r.prototype.groupData=function(e,t){return f.S6(e,function(n){n[t]===void 0&&(n[t]=C)}),f.vM(e,t)},r.prototype.adjustDim=function(e,t,n,i){},r.prototype.getDimValues=function(e){var t=this,n=t.xField,i=t.yField,a=f.f0({},this.dimValuesMap),o=[];if(n&&this.isAdjust("x")&&o.push(n),i&&this.isAdjust("y")&&o.push(i),o.forEach(function(l){a&&a[l]||(a[l]=f.I(e,l).sort(function(u,c){return u-c}))}),!i&&this.isAdjust("y")){var s="y";a[s]=[C,1]}return a},r}(),j=B,nt={},Tt=function(r){return nt[r.toLowerCase()]},Jt=function(r,e){if(Tt(r))throw new Error("Adjust type '"+r+"' existed.");nt[r.toLowerCase()]=e};/*! *****************************************************************************
  18. Copyright (c) Microsoft Corporation.
  19. Permission to use, copy, modify, and/or distribute this software for any
  20. purpose with or without fee is hereby granted.
  21. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
  22. REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
  23. AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
  24. INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
  25. LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
  26. OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  27. PERFORMANCE OF THIS SOFTWARE.
  28. ***************************************************************************** */var $t=function(e,t){return $t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},$t(e,t)};function ne(r,e){$t(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var qt=function(){return qt=Object.assign||function(t){for(var n,i=1,a=arguments.length;i<a;i++){n=arguments[i];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},qt.apply(this,arguments)};function Yt(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 i=0,n=Object.getOwnPropertySymbols(r);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(r,n[i])&&(t[n[i]]=r[n[i]]);return t}function fe(r,e,t,n){var i=arguments.length,a=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,t):n,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")a=Reflect.decorate(r,e,t,n);else for(var s=r.length-1;s>=0;s--)(o=r[s])&&(a=(i<3?o(a):i>3?o(e,t,a):o(e,t))||a);return i>3&&a&&Object.defineProperty(e,t,a),a}function Pe(r,e){return function(t,n){e(t,n,r)}}function Oe(r,e){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(r,e)}function Be(r,e,t,n){function i(a){return a instanceof t?a:new t(function(o){o(a)})}return new(t||(t=Promise))(function(a,o){function s(c){try{u(n.next(c))}catch(h){o(h)}}function l(c){try{u(n.throw(c))}catch(h){o(h)}}function u(c){c.done?a(c.value):i(c.value).then(s,l)}u((n=n.apply(r,e||[])).next())})}function cr(r,e){var t={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,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,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return t.label++,{value:u[1],done:!1};case 5:t.label++,i=u[1],u=[0];continue;case 7:u=t.ops.pop(),t.trys.pop();continue;default:if(a=t.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){t=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){t.label=u[1];break}if(u[0]===6&&t.label<a[1]){t.label=a[1],a=u;break}if(a&&t.label<a[2]){t.label=a[2],t.ops.push(u);break}a[2]&&t.ops.pop(),t.trys.pop();continue}u=e.call(r,t)}catch(c){u=[6,c],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}function Er(r,e,t,n){n===void 0&&(n=t),r[n]=e[t]}function _r(r,e){for(var t in r)t!=="default"&&!e.hasOwnProperty(t)&&(e[t]=r[t])}function tt(r){var e=typeof Symbol=="function"&&Symbol.iterator,t=e&&r[e],n=0;if(t)return t.call(r);if(r&&typeof r.length=="number")return{next:function(){return r&&n>=r.length&&(r=void 0),{value:r&&r[n++],done:!r}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function Z(r,e){var t=typeof Symbol=="function"&&r[Symbol.iterator];if(!t)return r;var n=t.call(r),i,a=[],o;try{for(;(e===void 0||e-- >0)&&!(i=n.next()).done;)a.push(i.value)}catch(s){o={error:s}}finally{try{i&&!i.done&&(t=n.return)&&t.call(n)}finally{if(o)throw o.error}}return a}function vt(){for(var r=[],e=0;e<arguments.length;e++)r=r.concat(Z(arguments[e]));return r}function St(){for(var r=0,e=0,t=arguments.length;e<t;e++)r+=arguments[e].length;for(var n=Array(r),i=0,e=0;e<t;e++)for(var a=arguments[e],o=0,s=a.length;o<s;o++,i++)n[i]=a[o];return n}function Ot(r){return this instanceof Ot?(this.v=r,this):new Ot(r)}function Wt(r,e,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=t.apply(r,e||[]),i,a=[];return i={},o("next"),o("throw"),o("return"),i[Symbol.asyncIterator]=function(){return this},i;function o(v){n[v]&&(i[v]=function(d){return new Promise(function(g,y){a.push([v,d,g,y])>1||s(v,d)})})}function s(v,d){try{l(n[v](d))}catch(g){h(a[0][3],g)}}function l(v){v.value instanceof Ot?Promise.resolve(v.value.v).then(u,c):h(a[0][2],v)}function u(v){s("next",v)}function c(v){s("throw",v)}function h(v,d){v(d),a.shift(),a.length&&s(a[0][0],a[0][1])}}function Ht(r){var e,t;return e={},n("next"),n("throw",function(i){throw i}),n("return"),e[Symbol.iterator]=function(){return this},e;function n(i,a){e[i]=r[i]?function(o){return(t=!t)?{value:Ot(r[i](o)),done:i==="return"}:a?a(o):o}:a}}function Kt(r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=r[Symbol.asyncIterator],t;return e?e.call(r):(r=typeof tt=="function"?tt(r):r[Symbol.iterator](),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(a){t[a]=r[a]&&function(o){return new Promise(function(s,l){o=r[a](o),i(s,l,o.done,o.value)})}}function i(a,o,s,l){Promise.resolve(l).then(function(u){a({value:u,done:s})},o)}}function Lt(r,e){return Object.defineProperty?Object.defineProperty(r,"raw",{value:e}):r.raw=e,r}function re(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var t in r)Object.hasOwnProperty.call(r,t)&&(e[t]=r[t]);return e.default=r,e}function Zt(r){return r&&r.__esModule?r:{default:r}}function me(r,e){if(!e.has(r))throw new TypeError("attempted to get private field on non-instance");return e.get(r)}function Se(r,e,t){if(!e.has(r))throw new TypeError("attempted to set private field on non-instance");return e.set(r,t),t}var se=function(r){ne(e,r);function e(t){var n=r.call(this,t)||this;n.cacheMap={},n.adjustDataArray=[],n.mergeData=[];var i=t.marginRatio,a=i===void 0?_:i,o=t.dodgeRatio,s=o===void 0?L:o,l=t.dodgeBy,u=t.intervalPadding,c=t.dodgePadding,h=t.xDimensionLength,v=t.groupNum,d=t.defaultSize,g=t.maxColumnWidth,y=t.minColumnWidth,x=t.columnWidthRatio,m=t.customOffset;return n.marginRatio=a,n.dodgeRatio=s,n.dodgeBy=l,n.intervalPadding=u,n.dodgePadding=c,n.xDimensionLegenth=h,n.groupNum=v,n.defaultSize=d,n.maxColumnWidth=g,n.minColumnWidth=y,n.columnWidthRatio=x,n.customOffset=m,n}return e.prototype.process=function(t){var n=f.d9(t),i=f.xH(n),a=this.dodgeBy,o=a?f.ru(i,a):n;return this.cacheMap={},this.adjustDataArray=o,this.mergeData=i,this.adjustData(o,i),this.adjustDataArray=[],this.mergeData=[],n},e.prototype.adjustDim=function(t,n,i,a){var o=this,s=this.customOffset,l=this.getDistribution(t),u=this.groupData(i,t);return f.S6(u,function(c,h){var v;n.length===1?v={pre:n[0]-1,next:n[0]+1}:v=o.getAdjustRange(t,parseFloat(h),n),f.S6(c,function(d){var g=d[t],y=l[g],x=y.indexOf(a);if(f.UM(s))d[t]=o.getDodgeOffset(v,x,y.length);else{var m=v.pre,M=v.next;d[t]=f.mf(s)?s(d,v):(m+M)/2+s}})}),[]},e.prototype.getDodgeOffset=function(t,n,i){var a=this,o=a.dodgeRatio,s=a.marginRatio,l=a.intervalPadding,u=a.dodgePadding,c=t.pre,h=t.next,v=h-c,d;if(!f.UM(l)&&f.UM(u)&&l>=0){var g=this.getIntervalOnlyOffset(i,n);d=c+g}else if(!f.UM(u)&&f.UM(l)&&u>=0){var g=this.getDodgeOnlyOffset(i,n);d=c+g}else if(!f.UM(l)&&!f.UM(u)&&l>=0&&u>=0){var g=this.getIntervalAndDodgeOffset(i,n);d=c+g}else{var y=v*o/i,x=s*y,g=1/2*(v-i*y-(i-1)*x)+((n+1)*y+n*x)-1/2*y-1/2*v;d=(c+h)/2+g}return d},e.prototype.getIntervalOnlyOffset=function(t,n){var i=this,a=i.defaultSize,o=i.intervalPadding,s=i.xDimensionLegenth,l=i.groupNum,u=i.dodgeRatio,c=i.maxColumnWidth,h=i.minColumnWidth,v=i.columnWidthRatio,d=o/s,g=(1-(l-1)*d)/l*u/(t-1),y=((1-d*(l-1))/l-g*(t-1))/t;if(y=f.UM(v)?y:1/l/t*v,!f.UM(c)){var x=c/s;y=Math.min(y,x)}if(!f.UM(h)){var m=h/s;y=Math.max(y,m)}y=a?a/s:y,g=((1-(l-1)*d)/l-t*y)/(t-1);var M=((1/2+n)*y+n*g+1/2*d)*l-d/2;return M},e.prototype.getDodgeOnlyOffset=function(t,n){var i=this,a=i.defaultSize,o=i.dodgePadding,s=i.xDimensionLegenth,l=i.groupNum,u=i.marginRatio,c=i.maxColumnWidth,h=i.minColumnWidth,v=i.columnWidthRatio,d=o/s,g=1*u/(l-1),y=((1-g*(l-1))/l-d*(t-1))/t;if(y=v?1/l/t*v:y,!f.UM(c)){var x=c/s;y=Math.min(y,x)}if(!f.UM(h)){var m=h/s;y=Math.max(y,m)}y=a?a/s:y,g=(1-(y*t+d*(t-1))*l)/(l-1);var M=((1/2+n)*y+n*d+1/2*g)*l-g/2;return M},e.prototype.getIntervalAndDodgeOffset=function(t,n){var i=this,a=i.intervalPadding,o=i.dodgePadding,s=i.xDimensionLegenth,l=i.groupNum,u=a/s,c=o/s,h=((1-u*(l-1))/l-c*(t-1))/t,v=((1/2+n)*h+n*c+1/2*u)*l-u/2;return v},e.prototype.getDistribution=function(t){var n=this.adjustDataArray,i=this.cacheMap,a=i[t];return a||(a={},f.S6(n,function(o,s){var l=f.I(o,t);l.length||l.push(0),f.S6(l,function(u){a[u]||(a[u]=[]),a[u].push(s)})}),i[t]=a),a},e}(j),we=se;function Ae(r,e){return(e-r)*Math.random()+r}var Ce=function(r){ne(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.process=function(t){var n=f.d9(t),i=f.xH(n);return this.adjustData(n,i),n},e.prototype.adjustDim=function(t,n,i){var a=this,o=this.groupData(i,t);return f.S6(o,function(s,l){return a.adjustGroup(s,t,parseFloat(l),n)})},e.prototype.getAdjustOffset=function(t){var n=t.pre,i=t.next,a=(i-n)*U;return Ae(n+a,i-a)},e.prototype.adjustGroup=function(t,n,i,a){var o=this,s=this.getAdjustRange(n,i,a);return f.S6(t,function(l){l[n]=o.getAdjustOffset(s)}),t},e}(j),ae=Ce,Ie=f.Ct,Le=function(r){ne(e,r);function e(t){var n=r.call(this,t)||this,i=t.adjustNames,a=i===void 0?["y"]:i,o=t.height,s=o===void 0?NaN:o,l=t.size,u=l===void 0?10:l,c=t.reverseOrder,h=c===void 0?!1:c;return n.adjustNames=a,n.height=s,n.size=u,n.reverseOrder=h,n}return e.prototype.process=function(t){var n=this,i=n.yField,a=n.reverseOrder,o=i?this.processStack(t):this.processOneDimStack(t);return a?this.reverse(o):o},e.prototype.reverse=function(t){return t.slice(0).reverse()},e.prototype.processStack=function(t){var n=this,i=n.xField,a=n.yField,o=n.reverseOrder,s=o?this.reverse(t):t,l=new Ie,u=new Ie;return s.map(function(c){return c.map(function(h){var v,d=f.U2(h,i,0),g=f.U2(h,[a]),y=d.toString();if(g=f.kJ(g)?g[1]:g,!f.UM(g)){var x=g>=0?l:u;x.has(y)||x.set(y,0);var m=x.get(y),M=g+m;return x.set(y,M),qt(qt({},h),(v={},v[a]=[m,M],v))}return h})})},e.prototype.processOneDimStack=function(t){var n=this,i=this,a=i.xField,o=i.height,s=i.reverseOrder,l="y",u=s?this.reverse(t):t,c=new Ie;return u.map(function(h){return h.map(function(v){var d,g=n.size,y=v[a],x=g*2/o;c.has(y)||c.set(y,x/2);var m=c.get(y);return c.set(y,m+x),qt(qt({},v),(d={},d[l]=m,d))})})},e}(j),He=Le,ze=function(r){ne(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.process=function(t){var n=f.xH(t),i=this,a=i.xField,o=i.yField,s=this.getXValuesMaxMap(n),l=Math.max.apply(Math,Object.keys(s).map(function(u){return s[u]}));return f.UI(t,function(u){return f.UI(u,function(c){var h,v,d=c[o],g=c[a];if(f.kJ(d)){var y=(l-s[g])/2;return qt(qt({},c),(h={},h[o]=f.UI(d,function(m){return y+m}),h))}var x=(l-d)/2;return qt(qt({},c),(v={},v[o]=[x,d+x],v))})})},e.prototype.getXValuesMaxMap=function(t){var n=this,i=this,a=i.xField,o=i.yField,s=f.vM(t,function(l){return l[a]});return f.Q8(s,function(l){return n.getDimMaxValue(l,o)})},e.prototype.getDimMaxValue=function(t,n){var i=f.UI(t,function(o){return f.U2(o,n,[])}),a=f.xH(i);return Math.max.apply(Math,a)},e}(j),$e=ze;Jt("Dodge",we),Jt("Jitter",ae),Jt("Stack",He),Jt("Symmetric",$e);var je=function(r,e){return(0,f.HD)(e)?e:r.invert(r.scale(e))},yr=function(){function r(e){this.names=[],this.scales=[],this.linear=!1,this.values=[],this.callback=function(){return[]},this._parseCfg(e)}return r.prototype.mapping=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var i=t.map(function(a,o){return e._toOriginParam(a,e.scales[o])});return this.callback.apply(this,i)},r.prototype.getLinearValue=function(e){var t=this.values.length-1,n=Math.floor(t*e),i=t*e-n,a=this.values[n],o=n===t?a:this.values[n+1];return a+(o-a)*i},r.prototype.getNames=function(){for(var e=this.scales,t=this.names,n=Math.min(e.length,t.length),i=[],a=0;a<n;a+=1)i.push(t[a]);return i},r.prototype.getFields=function(){return this.scales.map(function(e){return e.field})},r.prototype.getScale=function(e){return this.scales[this.names.indexOf(e)]},r.prototype.defaultCallback=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return t.length===0?this.values:t.map(function(i,a){var o=e.scales[a];return o.type==="identity"?o.values[0]:e._getAttributeValue(o,i)})},r.prototype._parseCfg=function(e){var t=this,n=e.type,i=n===void 0?"base":n,a=e.names,o=a===void 0?[]:a,s=e.scales,l=s===void 0?[]:s,u=e.values,c=u===void 0?[]:u,h=e.callback;this.type=i,this.scales=l,this.values=c,this.names=o,this.callback=function(){for(var v=[],d=0;d<arguments.length;d++)v[d]=arguments[d];if(h){var g=h.apply(void 0,v);if(!(0,f.UM)(g))return[g]}return t.defaultCallback.apply(t,v)}},r.prototype._getAttributeValue=function(e,t){if(e.isCategory&&!this.linear){var n=e.translate(t);return this.values[n%this.values.length]}var i=e.scale(t);return this.getLinearValue(i)},r.prototype._toOriginParam=function(e,t){return t.isLinear?e:(0,f.kJ)(e)?e.map(function(n){return je(t,n)}):je(t,e)},r}(),wr=yr,Sr=/rgba?\(([\s.,0-9]+)\)/,cn=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,yn=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,mn=/[\d.]+:(#[^\s]+|[^\)]+\))/gi,qn=function(r){return/^[r,R,L,l]{1}[\s]*\(/.test(r)},tn=function(){var r=document.createElement("i");return r.title="Web Colour Picker",r.style.display="none",document.body.appendChild(r),r},Yr=function(r,e,t,n){return r[n]+(e[n]-r[n])*t};function en(r){return"#"+fn(r[0])+fn(r[1])+fn(r[2])}var rn=function(r){return[parseInt(r.substr(1,2),16),parseInt(r.substr(3,2),16),parseInt(r.substr(5,2),16)]},fn=function(r){var e=Math.round(r).toString(16);return e.length===1?"0"+e:e},Kn=function(r,e){var t=isNaN(Number(e))||e<0?0:e>1?1:Number(e),n=r.length-1,i=Math.floor(n*t),a=n*t-i,o=r[i],s=i===n?o:r[i+1];return en([Yr(o,s,a,0),Yr(o,s,a,1),Yr(o,s,a,2)])},xn,jn=function(r){if(r[0]==="#"&&r.length===7)return r;xn||(xn=tn()),xn.style.color=r;var e=document.defaultView.getComputedStyle(xn,"").getPropertyValue("color"),t=Sr.exec(e),n=t[1].split(/\s*,\s*/).map(function(i){return Number(i)});return e=en(n),e},_a=function(r){var e=(0,f.HD)(r)?r.split("-"):r,t=(0,f.UI)(e,function(n){return rn(n.indexOf("#")===-1?jn(n):n)});return function(n){return Kn(t,n)}},Fa=function(r){if(qn(r)){var e,t=void 0;if(r[0]==="l"){var n=cn.exec(r),i=+n[1]+90;t=n[2],e="linear-gradient("+i+"deg, "}else if(r[0]==="r"){e="radial-gradient(";var n=yn.exec(r);t=n[4]}var a=t.match(mn);return(0,f.S6)(a,function(o,s){var l=o.split(":");e+=l[1]+" "+l[0]*100+"%",s!==a.length-1&&(e+=", ")}),e+=")",e}return r},nn={rgb2arr:rn,gradient:_a,toRGB:(0,f.HP)(jn),toCSSGradient:Fa},W=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.type="color",n.names=["color"],(0,f.HD)(n.values)&&(n.linear=!0),n.gradient=nn.gradient(n.values),n}return e.prototype.getLinearValue=function(t){return this.gradient(t)},e}(wr),R=W,$=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.type="opacity",n.names=["opacity"],n}return e}(wr),dt=$,Vt=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.names=["x","y"],n.type="position",n}return e.prototype.mapping=function(t,n){var i=this.scales,a=i[0],o=i[1];return(0,f.UM)(t)||(0,f.UM)(n)?[]:[(0,f.kJ)(t)?t.map(function(s){return a.scale(s)}):a.scale(t),(0,f.kJ)(n)?n.map(function(s){return o.scale(s)}):o.scale(n)]},e}(wr),oe=Vt,he=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.type="shape",n.names=["shape"],n}return e.prototype.getLinearValue=function(t){var n=Math.round((this.values.length-1)*t);return this.values[n]},e}(wr),le=he,ke=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.type="size",n.names=["size"],n}return e}(wr),ir=ke,gr={};function Dr(r){return gr[r]}function mr(r,e){gr[r]=e}var On=function(){function r(e){this.type="base",this.isCategory=!1,this.isLinear=!1,this.isContinuous=!1,this.isIdentity=!1,this.values=[],this.range=[0,1],this.ticks=[],this.__cfg__=e,this.initCfg(),this.init()}return r.prototype.translate=function(e){return e},r.prototype.change=function(e){(0,f.f0)(this.__cfg__,e),this.init()},r.prototype.clone=function(){return this.constructor(this.__cfg__)},r.prototype.getTicks=function(){var e=this;return(0,f.UI)(this.ticks,function(t,n){return(0,f.Kn)(t)?t:{text:e.getText(t,n),tickValue:t,value:e.scale(t)}})},r.prototype.getText=function(e,t){var n=this.formatter,i=n?n(e,t):e;return(0,f.UM)(i)||!(0,f.mf)(i.toString)?"":i.toString()},r.prototype.getConfig=function(e){return this.__cfg__[e]},r.prototype.init=function(){(0,f.f0)(this,this.__cfg__),this.setDomain(),(0,f.xb)(this.getConfig("ticks"))&&(this.ticks=this.calculateTicks())},r.prototype.initCfg=function(){},r.prototype.setDomain=function(){},r.prototype.calculateTicks=function(){var e=this.tickMethod,t=[];if((0,f.HD)(e)){var n=Dr(e);if(!n)throw new Error("There is no method to to calculate ticks!");t=n(this)}else(0,f.mf)(e)&&(t=e(this));return t},r.prototype.rangeMin=function(){return this.range[0]},r.prototype.rangeMax=function(){return this.range[1]},r.prototype.calcPercent=function(e,t,n){return(0,f.hj)(e)?(e-t)/(n-t):NaN},r.prototype.calcValue=function(e,t,n){return t+e*(n-t)},r}(),Xr=On,Ia=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="cat",t.isCategory=!0,t}return e.prototype.buildIndexMap=function(){if(!this.translateIndexMap){this.translateIndexMap=new Map;for(var t=0;t<this.values.length;t++)this.translateIndexMap.set(this.values[t],t)}},e.prototype.translate=function(t){this.buildIndexMap();var n=this.translateIndexMap.get(t);return n===void 0&&(n=(0,f.hj)(t)?t:NaN),n},e.prototype.scale=function(t){var n=this.translate(t),i=this.calcPercent(n,this.min,this.max);return this.calcValue(i,this.rangeMin(),this.rangeMax())},e.prototype.invert=function(t){var n=this.max-this.min,i=this.calcPercent(t,this.rangeMin(),this.rangeMax()),a=Math.round(n*i)+this.min;return a<this.min||a>this.max?NaN:this.values[a]},e.prototype.getText=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];var a=t;return(0,f.hj)(t)&&!this.values.includes(t)&&(a=this.values[a]),r.prototype.getText.apply(this,(0,p.pr)([a],n))},e.prototype.initCfg=function(){this.tickMethod="cat"},e.prototype.setDomain=function(){if((0,f.UM)(this.getConfig("min"))&&(this.min=0),(0,f.UM)(this.getConfig("max"))){var t=this.values.length;this.max=t>1?t-1:t}this.translateIndexMap&&(this.translateIndexMap=void 0)},e}(Xr),yi=Ia,Tl=/d{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|ZZ|Z|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,Mn="\\d\\d?",wn="\\d\\d",El="\\d{3}",_l="\\d{4}",Wi="[^\\s]+",Fl=/\[([^]*?)\]/gm;function Il(r,e){for(var t=[],n=0,i=r.length;n<i;n++)t.push(r[n].substr(0,e));return t}var Bo=function(r){return function(e,t){var n=t[r].map(function(a){return a.toLowerCase()}),i=n.indexOf(e.toLowerCase());return i>-1?i:null}};function Sn(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];for(var n=0,i=e;n<i.length;n++){var a=i[n];for(var o in a)r[o]=a[o]}return r}var Ro=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],No=["January","February","March","April","May","June","July","August","September","October","November","December"],Pl=Il(No,3),Of=Il(Ro,3),Uo={dayNamesShort:Of,dayNames:Ro,monthNamesShort:Pl,monthNames:No,amPm:["am","pm"],DoFn:function(r){return r+["th","st","nd","rd"][r%10>3?0:(r-r%10!=10?1:0)*r%10]}},Zi=Sn({},Uo),zo=function(r){return Zi=Sn(Zi,r)},Vo=function(r){return r.replace(/[|\\{()[^$+*?.-]/g,"\\$&")},Fr=function(r,e){for(e===void 0&&(e=2),r=String(r);r.length<e;)r="0"+r;return r},Ll={D:function(r){return String(r.getDate())},DD:function(r){return Fr(r.getDate())},Do:function(r,e){return e.DoFn(r.getDate())},d:function(r){return String(r.getDay())},dd:function(r){return Fr(r.getDay())},ddd:function(r,e){return e.dayNamesShort[r.getDay()]},dddd:function(r,e){return e.dayNames[r.getDay()]},M:function(r){return String(r.getMonth()+1)},MM:function(r){return Fr(r.getMonth()+1)},MMM:function(r,e){return e.monthNamesShort[r.getMonth()]},MMMM:function(r,e){return e.monthNames[r.getMonth()]},YY:function(r){return Fr(String(r.getFullYear()),4).substr(2)},YYYY:function(r){return Fr(r.getFullYear(),4)},h:function(r){return String(r.getHours()%12||12)},hh:function(r){return Fr(r.getHours()%12||12)},H:function(r){return String(r.getHours())},HH:function(r){return Fr(r.getHours())},m:function(r){return String(r.getMinutes())},mm:function(r){return Fr(r.getMinutes())},s:function(r){return String(r.getSeconds())},ss:function(r){return Fr(r.getSeconds())},S:function(r){return String(Math.round(r.getMilliseconds()/100))},SS:function(r){return Fr(Math.round(r.getMilliseconds()/10),2)},SSS:function(r){return Fr(r.getMilliseconds(),3)},a:function(r,e){return r.getHours()<12?e.amPm[0]:e.amPm[1]},A:function(r,e){return r.getHours()<12?e.amPm[0].toUpperCase():e.amPm[1].toUpperCase()},ZZ:function(r){var e=r.getTimezoneOffset();return(e>0?"-":"+")+Fr(Math.floor(Math.abs(e)/60)*100+Math.abs(e)%60,4)},Z:function(r){var e=r.getTimezoneOffset();return(e>0?"-":"+")+Fr(Math.floor(Math.abs(e)/60),2)+":"+Fr(Math.abs(e)%60,2)}},Ho=function(r){return+r-1},Dl=[null,Mn],Ol=[null,Wi],$i=["isPm",Wi,function(r,e){var t=r.toLowerCase();return t===e.amPm[0]?0:t===e.amPm[1]?1:null}],Go=["timezoneOffset","[^\\s]*?[\\+\\-]\\d\\d:?\\d\\d|[^\\s]*?Z?",function(r){var e=(r+"").match(/([+-]|\d\d)/gi);if(e){var t=+e[1]*60+parseInt(e[2],10);return e[0]==="+"?t:-t}return 0}],kl={D:["day",Mn],DD:["day",wn],Do:["day",Mn+Wi,function(r){return parseInt(r,10)}],M:["month",Mn,Ho],MM:["month",wn,Ho],YY:["year",wn,function(r){var e=new Date,t=+(""+e.getFullYear()).substr(0,2);return+(""+(+r>68?t-1:t)+r)}],h:["hour",Mn,void 0,"isPm"],hh:["hour",wn,void 0,"isPm"],H:["hour",Mn],HH:["hour",wn],m:["minute",Mn],mm:["minute",wn],s:["second",Mn],ss:["second",wn],YYYY:["year",_l],S:["millisecond","\\d",function(r){return+r*100}],SS:["millisecond",wn,function(r){return+r*10}],SSS:["millisecond",El],d:Dl,dd:Dl,ddd:Ol,dddd:Ol,MMM:["month",Wi,Bo("monthNamesShort")],MMMM:["month",Wi,Bo("monthNames")],a:$i,A:$i,ZZ:Go,Z:Go},qi={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",isoDate:"YYYY-MM-DD",isoDateTime:"YYYY-MM-DDTHH:mm:ssZ",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},Pa=function(r){return Sn(qi,r)},Yo=function(r,e,t){if(e===void 0&&(e=qi.default),t===void 0&&(t={}),typeof r=="number"&&(r=new Date(r)),Object.prototype.toString.call(r)!=="[object Date]"||isNaN(r.getTime()))throw new Error("Invalid Date pass to format");e=qi[e]||e;var n=[];e=e.replace(Fl,function(a,o){return n.push(o),"@@@"});var i=Sn(Sn({},Zi),t);return e=e.replace(Tl,function(a){return Ll[a](r,i)}),e.replace(/@@@/g,function(){return n.shift()})};function La(r,e,t){if(t===void 0&&(t={}),typeof e!="string")throw new Error("Invalid format in fecha parse");if(e=qi[e]||e,r.length>1e3)return null;var n=new Date,i={year:n.getFullYear(),month:0,day:1,hour:0,minute:0,second:0,millisecond:0,isPm:null,timezoneOffset:null},a=[],o=[],s=e.replace(Fl,function(S,b){return o.push(Vo(b)),"@@@"}),l={},u={};s=Vo(s).replace(Tl,function(S){var b=kl[S],k=b[0],H=b[1],at=b[3];if(l[k])throw new Error("Invalid format. "+k+" specified twice in format");return l[k]=!0,at&&(u[at]=!0),a.push(b),"("+H+")"}),Object.keys(u).forEach(function(S){if(!l[S])throw new Error("Invalid format. "+S+" is required in specified format")}),s=s.replace(/@@@/g,function(){return o.shift()});var c=r.match(new RegExp(s,"i"));if(!c)return null;for(var h=Sn(Sn({},Zi),t),v=1;v<c.length;v++){var d=a[v-1],g=d[0],y=d[2],x=y?y(c[v],h):+c[v];if(x==null)return null;i[g]=x}i.isPm===1&&i.hour!=null&&+i.hour!=12?i.hour=+i.hour+12:i.isPm===0&&+i.hour==12&&(i.hour=0);var m;if(i.timezoneOffset==null){m=new Date(i.year,i.month,i.day,i.hour,i.minute,i.second,i.millisecond);for(var M=[["month","getMonth"],["day","getDate"],["hour","getHours"],["minute","getMinutes"],["second","getSeconds"]],v=0,w=M.length;v<w;v++)if(l[M[v][0]]&&i[M[v][0]]!==m[M[v][1]]())return null}else if(m=new Date(Date.UTC(i.year,i.month,i.day,i.hour,i.minute-i.timezoneOffset,i.second,i.millisecond)),i.month>11||i.month<0||i.day>31||i.day<1||i.hour>23||i.hour<0||i.minute>59||i.minute<0||i.second>59||i.second<0)return null;return m}var Bl={format:Yo,parse:La,defaultI18n:Uo,setGlobalDateI18n:zo,setGlobalDateMasks:Pa},Xo=Bl;function kf(r){return function(e,t,n,i){for(var a=(0,f.UM)(n)?0:n,o=(0,f.UM)(i)?e.length:i;a<o;){var s=a+o>>>1;r(e[s])>t?o=s:a=s+1}return a}}var Rl="format";function Wo(r,e){var t=et[Rl]||Xo[Rl];return t(r,e)}function Ki(r){return(0,f.HD)(r)&&(r.indexOf("T")>0?r=new Date(r).getTime():r=new Date(r.replace(/-/gi,"/")).getTime()),(0,f.J_)(r)&&(r=r.getTime()),r}var Wr=1e3,kn=60*Wr,Bn=60*kn,Zr=24*Bn,mi=Zr*31,Nl=Zr*365,xi=[["HH:mm:ss",Wr],["HH:mm:ss",Wr*10],["HH:mm:ss",Wr*30],["HH:mm",kn],["HH:mm",kn*10],["HH:mm",kn*30],["HH",Bn],["HH",Bn*6],["HH",Bn*12],["YYYY-MM-DD",Zr],["YYYY-MM-DD",Zr*4],["YYYY-WW",Zr*7],["YYYY-MM",mi],["YYYY-MM",mi*4],["YYYY-MM",mi*6],["YYYY",Zr*380]];function Ul(r,e,t){var n=(e-r)/t,i=kf(function(o){return o[1]})(xi,n)-1,a=xi[i];return i<0?a=xi[0]:i>=xi.length&&(a=(0,f.Z$)(xi)),a}var zl=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="timeCat",t}return e.prototype.translate=function(t){t=Ki(t);var n=this.values.indexOf(t);return n===-1&&((0,f.hj)(t)&&t<this.values.length?n=t:n=NaN),n},e.prototype.getText=function(t,n){var i=this.translate(t);if(i>-1){var a=this.values[i],o=this.formatter;return a=o?o(a,n):Wo(a,this.mask),a}return t},e.prototype.initCfg=function(){this.tickMethod="time-cat",this.mask="YYYY-MM-DD",this.tickCount=7},e.prototype.setDomain=function(){var t=this.values;(0,f.S6)(t,function(n,i){t[i]=Ki(n)}),t.sort(function(n,i){return n-i}),r.prototype.setDomain.call(this)},e}(yi),Vl=zl,Da=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.isContinuous=!0,t}return e.prototype.scale=function(t){if((0,f.UM)(t))return NaN;var n=this.rangeMin(),i=this.rangeMax(),a=this.max,o=this.min;if(a===o)return n;var s=this.getScalePercent(t);return n+s*(i-n)},e.prototype.init=function(){r.prototype.init.call(this);var t=this.ticks,n=(0,f.YM)(t),i=(0,f.Z$)(t);n<this.min&&(this.min=n),i>this.max&&(this.max=i),(0,f.UM)(this.minLimit)||(this.min=n),(0,f.UM)(this.maxLimit)||(this.max=i)},e.prototype.setDomain=function(){var t=(0,f.rx)(this.values),n=t.min,i=t.max;(0,f.UM)(this.min)&&(this.min=n),(0,f.UM)(this.max)&&(this.max=i),this.min>this.max&&(this.min=n,this.max=i)},e.prototype.calculateTicks=function(){var t=this,n=r.prototype.calculateTicks.call(this);return this.nice||(n=(0,f.hX)(n,function(i){return i>=t.min&&i<=t.max})),n},e.prototype.getScalePercent=function(t){var n=this.max,i=this.min;return(t-i)/(n-i)},e.prototype.getInvertPercent=function(t){return(t-this.rangeMin())/(this.rangeMax()-this.rangeMin())},e}(Xr),Mi=Da,Hl=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="linear",t.isLinear=!0,t}return e.prototype.invert=function(t){var n=this.getInvertPercent(t);return this.min+n*(this.max-this.min)},e.prototype.initCfg=function(){this.tickMethod="wilkinson-extended",this.nice=!1},e}(Mi),ji=Hl;function Cn(r,e){var t=Math.E,n;return e>=0?n=Math.pow(t,Math.log(e)/r):n=Math.pow(t,Math.log(-e)/r)*-1,n}function Or(r,e){return r===1?1:Math.log(e)/Math.log(r)}function Zo(r,e,t){(0,f.UM)(t)&&(t=Math.max.apply(null,r));var n=t;return(0,f.S6)(r,function(i){i>0&&i<n&&(n=i)}),n===t&&(n=t/e),n>1&&(n=1),n}function $o(r){var e=r.toString().split(/[eE]/),t=(e[0].split(".")[1]||"").length-+(e[1]||0);return t>0?t:0}function Bf(r,e){var t=$o(r),n=$o(e),i=Math.pow(10,Math.max(t,n));return(r*i+e*i)/i}var Ji=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="log",t}return e.prototype.invert=function(t){var n=this.base,i=Or(n,this.max),a=this.rangeMin(),o=this.rangeMax()-a,s,l=this.positiveMin;if(l){if(t===0)return 0;s=Or(n,l/n);var u=1/(i-s)*o;if(t<u)return t/u*l}else s=Or(n,this.min);var c=(t-a)/o,h=c*(i-s)+s;return Math.pow(n,h)},e.prototype.initCfg=function(){this.tickMethod="log",this.base=10,this.tickCount=6,this.nice=!0},e.prototype.setDomain=function(){r.prototype.setDomain.call(this);var t=this.min;if(t<0)throw new Error("When you use log scale, the minimum value must be greater than zero!");t===0&&(this.positiveMin=Zo(this.values,this.base,this.max))},e.prototype.getScalePercent=function(t){var n=this.max,i=this.min;if(n===i||t<=0)return 0;var a=this.base,o=this.positiveMin;o&&(i=o*1/a);var s;return t<o?s=t/o/(Or(a,n)-Or(a,i)):s=(Or(a,t)-Or(a,i))/(Or(a,n)-Or(a,i)),s},e}(Mi),Gl=Ji,Yl=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="pow",t}return e.prototype.invert=function(t){var n=this.getInvertPercent(t),i=this.exponent,a=Cn(i,this.max),o=Cn(i,this.min),s=n*(a-o)+o,l=s>=0?1:-1;return Math.pow(s,i)*l},e.prototype.initCfg=function(){this.tickMethod="pow",this.exponent=2,this.tickCount=5,this.nice=!0},e.prototype.getScalePercent=function(t){var n=this.max,i=this.min;if(n===i)return 0;var a=this.exponent,o=(Cn(a,t)-Cn(a,i))/(Cn(a,n)-Cn(a,i));return o},e}(Mi),Xl=Yl,Wl=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="time",t}return e.prototype.getText=function(t,n){var i=this.translate(t),a=this.formatter;return a?a(i,n):Wo(i,this.mask)},e.prototype.scale=function(t){var n=t;return((0,f.HD)(n)||(0,f.J_)(n))&&(n=this.translate(n)),r.prototype.scale.call(this,n)},e.prototype.translate=function(t){return Ki(t)},e.prototype.initCfg=function(){this.tickMethod="time-pretty",this.mask="YYYY-MM-DD",this.tickCount=7,this.nice=!1},e.prototype.setDomain=function(){var t=this.values,n=this.getConfig("min"),i=this.getConfig("max");if((!(0,f.UM)(n)||!(0,f.hj)(n))&&(this.min=this.translate(this.min)),(!(0,f.UM)(i)||!(0,f.hj)(i))&&(this.max=this.translate(this.max)),t&&t.length){var a=[],o=Infinity,s=o,l=0;(0,f.S6)(t,function(u){var c=Ki(u);if(isNaN(c))throw new TypeError("Invalid Time: "+u+" in time scale!");o>c?(s=o,o=c):s>c&&(s=c),l<c&&(l=c),a.push(c)}),t.length>1&&(this.minTickInterval=s-o),(0,f.UM)(n)&&(this.min=o),(0,f.UM)(i)&&(this.max=l)}},e}(ji),Qi=Wl,ta=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="quantize",t}return e.prototype.invert=function(t){var n=this.ticks,i=n.length,a=this.getInvertPercent(t),o=Math.floor(a*(i-1));if(o>=i-1)return(0,f.Z$)(n);if(o<0)return(0,f.YM)(n);var s=n[o],l=n[o+1],u=o/(i-1),c=(o+1)/(i-1);return s+(a-u)/(c-u)*(l-s)},e.prototype.initCfg=function(){this.tickMethod="r-pretty",this.tickCount=5,this.nice=!0},e.prototype.calculateTicks=function(){var t=r.prototype.calculateTicks.call(this);return this.nice||((0,f.Z$)(t)!==this.max&&t.push(this.max),(0,f.YM)(t)!==this.min&&t.unshift(this.min)),t},e.prototype.getScalePercent=function(t){var n=this.ticks;if(t<(0,f.YM)(n))return 0;if(t>(0,f.Z$)(n))return 1;var i=0;return(0,f.S6)(n,function(a,o){if(t>=a)i=o;else return!1}),i/(n.length-1)},e}(Mi),qo=ta,Zl=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="quantile",t}return e.prototype.initCfg=function(){this.tickMethod="quantile",this.tickCount=5,this.nice=!0},e}(qo),$l=Zl,O={};function rt(r){return O[r]}function ct(r,e){if(rt(r))throw new Error("type '"+r+"' existed.");O[r]=e}var _t=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="identity",t.isIdentity=!0,t}return e.prototype.calculateTicks=function(){return this.values},e.prototype.scale=function(t){return this.values[0]!==t&&(0,f.hj)(t)?t:this.range[0]},e.prototype.invert=function(t){var n=this.range;return t<n[0]||t>n[1]?NaN:this.values[0]},e}(Xr),Qt=_t;function ve(r){var e=r.values,t=r.tickInterval,n=r.tickCount,i=r.showLast;if((0,f.hj)(t)){var a=(0,f.hX)(e,function(g,y){return y%t==0}),o=(0,f.Z$)(e);return i&&(0,f.Z$)(a)!==o&&a.push(o),a}var s=e.length,l=r.min,u=r.max;if((0,f.UM)(l)&&(l=0),(0,f.UM)(u)&&(u=e.length-1),!(0,f.hj)(n)||n>=s)return e.slice(l,u+1);if(n<=0||u<=0)return[];for(var c=n===1?s:Math.floor(s/(n-1)),h=[],v=l,d=0;d<n&&!(v>=u);d++)v=Math.min(l+d*c,u),d===n-1&&i?h.push(e[u]):h.push(e[v]);return h}function _e(r){var e=r.min,t=r.max,n=r.nice,i=r.tickCount,a=new Oa;return a.domain([e,t]),n&&a.nice(i),a.ticks(i)}var qe=5,Cr=Math.sqrt(50),Lr=Math.sqrt(10),kr=Math.sqrt(2),Oa=function(){function r(){this._domain=[0,1]}return r.prototype.domain=function(e){return e?(this._domain=Array.from(e,Number),this):this._domain.slice()},r.prototype.nice=function(e){var t,n;e===void 0&&(e=qe);var i=this._domain.slice(),a=0,o=this._domain.length-1,s=this._domain[a],l=this._domain[o],u;return l<s&&(t=[l,s],s=t[0],l=t[1],n=[o,a],a=n[0],o=n[1]),u=Ko(s,l,e),u>0?(s=Math.floor(s/u)*u,l=Math.ceil(l/u)*u,u=Ko(s,l,e)):u<0&&(s=Math.ceil(s*u)/u,l=Math.floor(l*u)/u,u=Ko(s,l,e)),u>0?(i[a]=Math.floor(s/u)*u,i[o]=Math.ceil(l/u)*u,this.domain(i)):u<0&&(i[a]=Math.ceil(s*u)/u,i[o]=Math.floor(l*u)/u,this.domain(i)),this},r.prototype.ticks=function(e){return e===void 0&&(e=qe),Hy(this._domain[0],this._domain[this._domain.length-1],e||qe)},r}();function Hy(r,e,t){var n,i=-1,a,o,s;if(e=+e,r=+r,t=+t,r===e&&t>0)return[r];if((n=e<r)&&(a=r,r=e,e=a),(s=Ko(r,e,t))===0||!isFinite(s))return[];if(s>0)for(r=Math.ceil(r/s),e=Math.floor(e/s),o=new Array(a=Math.ceil(e-r+1));++i<a;)o[i]=(r+i)*s;else for(r=Math.floor(r*s),e=Math.ceil(e*s),o=new Array(a=Math.ceil(r-e+1));++i<a;)o[i]=(r-i)/s;return n&&o.reverse(),o}function Ko(r,e,t){var n=(e-r)/Math.max(0,t),i=Math.floor(Math.log(n)/Math.LN10),a=n/Math.pow(10,i);return i>=0?(a>=Cr?10:a>=Lr?5:a>=kr?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(a>=Cr?10:a>=Lr?5:a>=kr?2:1)}function Rf(r,e,t){var n;return t==="ceil"?n=Math.ceil(r/e):t==="floor"?n=Math.floor(r/e):n=Math.round(r/e),n*e}function ql(r,e,t){var n=Rf(r,t,"floor"),i=Rf(e,t,"ceil");n=(0,f.ri)(n,t),i=(0,f.ri)(i,t);for(var a=[],o=Math.max((i-n)/(Math.pow(2,12)-1),t),s=n;s<=i;s=s+o){var l=(0,f.ri)(s,o);a.push(l)}return{min:n,max:i,ticks:a}}function Kl(r,e,t){var n,i=r.minLimit,a=r.maxLimit,o=r.min,s=r.max,l=r.tickCount,u=l===void 0?5:l,c=(0,f.UM)(i)?(0,f.UM)(e)?o:e:i,h=(0,f.UM)(a)?(0,f.UM)(t)?s:t:a;if(c>h&&(n=[c,h],h=n[0],c=n[1]),u<=2)return[c,h];for(var v=(h-c)/(u-1),d=[],g=0;g<u;g++)d.push(c+v*g);return d}function Gy(r){var e=r.min,t=r.max,n=r.tickInterval,i=r.minLimit,a=r.maxLimit,o=_e(r);return!(0,f.UM)(i)||!(0,f.UM)(a)?Kl(r,(0,f.YM)(o),(0,f.Z$)(o)):n?ql(e,t,n).ticks:o}function wi(r){return Math.abs(r)<1e-15?r:parseFloat(r.toFixed(15))}var Yy=[1,5,2,2.5,4,3],pR=null,Nf=Number.EPSILON*100;function Xy(r,e){return(r%e+e)%e}function Wy(r){return Math.round(r*1e12)/1e12}function Zy(r,e,t,n,i,a){var o=(0,f.dp)(e),s=(0,f.cq)(e,r),l=0,u=Xy(n,a);return(u<Nf||a-u<Nf)&&n<=0&&i>=0&&(l=1),1-s/(o-1)-t+l}function $y(r,e,t){var n=(0,f.dp)(e),i=(0,f.cq)(e,r),a=1;return 1-i/(n-1)-t+a}function qy(r,e,t,n,i,a){var o=(r-1)/(a-i),s=(e-1)/(Math.max(a,n)-Math.min(t,i));return 2-Math.max(o/s,s/o)}function Ky(r,e){return r>=e?2-(r-1)/(e-1):1}function jy(r,e,t,n){var i=e-r;return 1-.5*(Math.pow(e-n,2)+Math.pow(r-t,2))/Math.pow(.1*i,2)}function Jy(r,e,t){var n=e-r;if(t>n){var i=(t-n)/2;return 1-Math.pow(i,2)/Math.pow(.1*n,2)}return 1}function Qy(){return 1}function tm(r,e,t,n,i,a){t===void 0&&(t=5),n===void 0&&(n=!0),i===void 0&&(i=Yy),a===void 0&&(a=[.25,.2,.5,.05]);var o=t<0?0:Math.round(t);if(Number.isNaN(r)||Number.isNaN(e)||typeof r!="number"||typeof e!="number"||!o)return{min:0,max:0,ticks:[]};if(e-r<1e-15||o===1)return{min:r,max:e,ticks:[r]};if(e-r>1e148){var s=t||5,l=(e-r)/s;return{min:r,max:e,ticks:Array(s).fill(null).map(function(Ee,Ne){return wi(r+l*Ne)})}}for(var u={score:-2,lmin:0,lmax:0,lstep:0},c=1;c<Infinity;){for(var h=0;h<i.length;h+=1){var v=i[h],d=$y(v,i,c);if(a[0]*d+a[1]+a[2]+a[3]<u.score){c=Infinity;break}for(var g=2;g<Infinity;){var y=Ky(g,o);if(a[0]*d+a[1]+a[2]*y+a[3]<u.score)break;for(var x=(e-r)/(g+1)/c/v,m=Math.ceil(Math.log10(x));m<Infinity;){var M=c*v*Math.pow(10,m),w=Jy(r,e,M*(g-1));if(a[0]*d+a[1]*w+a[2]*y+a[3]<u.score)break;var S=Math.floor(e/M)*c-(g-1)*c,b=Math.ceil(r/M)*c;if(S<=b)for(var s=b-S,k=0;k<=s;k+=1){var H=S+k,at=H*(M/c),At=at+M*(g-1),gt=M,Nt=Zy(v,i,c,at,At,gt),te=jy(r,e,at,At),ce=qy(g,o,r,e,at,At),Me=Qy(),be=a[0]*Nt+a[1]*te+a[2]*ce+a[3]*Me;be>u.score&&(!n||at<=r&&At>=e)&&(u.lmin=at,u.lmax=At,u.lstep=gt,u.score=be)}m+=1}g+=1}}c+=1}var Gt=wi(u.lmax),ie=wi(u.lmin),de=wi(u.lstep),ue=Math.floor(Wy((Gt-ie)/de))+1,pe=new Array(ue);pe[0]=wi(ie);for(var h=1;h<ue;h++)pe[h]=wi(pe[h-1]+de);return{min:Math.min(r,(0,f.YM)(pe)),max:Math.max(e,(0,f.Z$)(pe)),ticks:pe}}function em(r){var e=r.min,t=r.max,n=r.tickCount,i=r.nice,a=r.tickInterval,o=r.minLimit,s=r.maxLimit,l=tm(e,t,n,i).ticks;return!(0,f.UM)(o)||!(0,f.UM)(s)?Kl(r,(0,f.YM)(l),(0,f.Z$)(l)):a?ql(e,t,a).ticks:l}function rm(r){var e=r.base,t=r.tickCount,n=r.min,i=r.max,a=r.values,o,s=Or(e,i);if(n>0)o=Math.floor(Or(e,n));else{var l=Zo(a,e,i);o=Math.floor(Or(e,l))}for(var u=s-o,c=Math.ceil(u/t),h=[],v=o;v<s+c;v=v+c)h.push(Math.pow(e,v));return n<=0&&h.unshift(0),h}function Uf(r,e,t){if(t===void 0&&(t=5),r===e)return{max:e,min:r,ticks:[r]};var n=t<0?0:Math.round(t);if(n===0)return{max:e,min:r,ticks:[]};var i=1.5,a=.5+1.5*i,o=e-r,s=o/n,l=Math.pow(10,Math.floor(Math.log10(s))),u=l;2*l-s<i*(s-u)&&(u=2*l,5*l-s<a*(s-u)&&(u=5*l,10*l-s<i*(s-u)&&(u=10*l)));for(var c=Math.ceil(e/u),h=Math.floor(r/u),v=Math.max(c*u,e),d=Math.min(h*u,r),g=Math.floor((v-d)/u)+1,y=new Array(g),x=0;x<g;x++)y[x]=wi(d+x*u);return{min:d,max:v,ticks:y}}function nm(r){var e=r.exponent,t=r.tickCount,n=Math.ceil(Cn(e,r.max)),i=Math.floor(Cn(e,r.min)),a=Uf(i,n,t).ticks;return a.map(function(o){var s=o>=0?1:-1;return Math.pow(o,e)*s})}function im(r,e){var t=r.length*e;return e===1?r[r.length-1]:e===0?r[0]:t%1!=0?r[Math.ceil(t)-1]:r.length%2==0?(r[t-1]+r[t])/2:r[t]}function am(r){var e=r.tickCount,t=r.values;if(!t||!t.length)return[];for(var n=t.slice().sort(function(s,l){return s-l}),i=[],a=0;a<e;a++){var o=a/(e-1);i.push(im(n,o))}return i}function om(r){var e=r.min,t=r.max,n=r.tickCount,i=r.tickInterval,a=r.minLimit,o=r.maxLimit,s=Uf(e,t,n).ticks;return!(0,f.UM)(a)||!(0,f.UM)(o)?Kl(r,(0,f.YM)(s),(0,f.Z$)(s)):i?ql(e,t,i).ticks:s}function sm(r){var e=r.min,t=r.max,n=r.minTickInterval,i=r.tickInterval,a=r.tickCount;if(i)a=Math.ceil((t-e)/i);else{i=Ul(e,t,a)[1];var o=(t-e)/i,s=o/a;s>1&&(i=i*Math.ceil(s)),n&&i<n&&(i=n)}i=Math.max(Math.floor((t-e)/(Math.pow(2,12)-1)),i);for(var l=[],u=e;u<t+i;u+=i)l.push(u);return l}function lm(r){var e=ve((0,p.pi)({showLast:!0},r));return e}function jo(r){return new Date(r).getFullYear()}function um(r){return new Date(r,0,1).getTime()}function jl(r){return new Date(r).getMonth()}function cm(r,e){var t=jo(r),n=jo(e),i=jl(r),a=jl(e);return(n-t)*12+(a-i)%12}function fm(r,e){return new Date(r,e,1).getTime()}function hm(r,e){return Math.ceil((e-r)/Zr)}function vm(r,e){return Math.ceil((e-r)/Bn)}function dm(r,e){return Math.ceil((e-r)/(60*1e3))}function pm(r){var e=r.min,t=r.max,n=r.minTickInterval,i=r.tickCount,a=r.tickInterval,o=[];a||(a=(t-e)/i,n&&a<n&&(a=n)),a=Math.max(Math.floor((t-e)/(Math.pow(2,12)-1)),a);var s=jo(e);if(a>Nl)for(var l=jo(t),u=Math.ceil(a/Nl),c=s;c<=l+u;c=c+u)o.push(um(c));else if(a>mi)for(var h=Math.ceil(a/mi),v=jl(e),d=cm(e,t),c=0;c<=d+h;c=c+h)o.push(fm(s,c+v));else if(a>Zr)for(var g=new Date(e),y=g.getFullYear(),x=g.getMonth(),m=g.getDate(),M=Math.ceil(a/Zr),w=hm(e,t),c=0;c<w+M;c=c+M)o.push(new Date(y,x,m+c).getTime());else if(a>Bn)for(var g=new Date(e),y=g.getFullYear(),x=g.getMonth(),M=g.getDate(),S=g.getHours(),b=Math.ceil(a/Bn),k=vm(e,t),c=0;c<=k+b;c=c+b)o.push(new Date(y,x,M,S+c).getTime());else if(a>kn)for(var H=dm(e,t),at=Math.ceil(a/kn),c=0;c<=H+at;c=c+at)o.push(e+c*kn);else{var At=a;At<Wr&&(At=Wr);for(var gt=Math.floor(e/Wr)*Wr,Nt=Math.ceil((t-e)/Wr),te=Math.ceil(At/Wr),c=0;c<Nt+te;c=c+te)o.push(gt+c*Wr)}return o.length>=512&&console.warn("Notice: current ticks length("+o.length+') >= 512, may cause performance issues, even out of memory. Because of the configure "tickInterval"(in milliseconds, current is '+a+") is too small, increase the value to solve the problem!"),o}mr("cat",ve),mr("time-cat",lm),mr("wilkinson-extended",em),mr("r-pretty",om),mr("time",sm),mr("time-pretty",pm),mr("log",rm),mr("pow",nm),mr("quantile",am),mr("d3-linear",Gy),ct("cat",yi),ct("category",yi),ct("identity",Qt),ct("linear",ji),ct("log",Gl),ct("pow",Xl),ct("time",Qi),ct("timeCat",Vl),ct("quantize",qo),ct("quantile",$l);var zf={},Vf=function(r){return zf[r.toLowerCase()]},ka=function(r,e){if(Vf(r))throw new Error("Attribute type '".concat(r,"' existed."));zf[r.toLowerCase()]=e};ka("Color",R),ka("Opacity",dt),ka("Position",oe),ka("Shape",le),ka("Size",ir);var Hf=N(49685);function gm(){var r=new Hf.WT(3);return Hf.WT!=Float32Array&&(r[0]=0,r[1]=0,r[2]=0),r}function gR(r){var e=new glMatrix.ARRAY_TYPE(3);return e[0]=r[0],e[1]=r[1],e[2]=r[2],e}function yR(r){var e=r[0],t=r[1],n=r[2];return Math.hypot(e,t,n)}function mR(r,e,t){var n=new glMatrix.ARRAY_TYPE(3);return n[0]=r,n[1]=e,n[2]=t,n}function xR(r,e){return r[0]=e[0],r[1]=e[1],r[2]=e[2],r}function MR(r,e,t,n){return r[0]=e,r[1]=t,r[2]=n,r}function wR(r,e,t){return r[0]=e[0]+t[0],r[1]=e[1]+t[1],r[2]=e[2]+t[2],r}function SR(r,e,t){return r[0]=e[0]-t[0],r[1]=e[1]-t[1],r[2]=e[2]-t[2],r}function CR(r,e,t){return r[0]=e[0]*t[0],r[1]=e[1]*t[1],r[2]=e[2]*t[2],r}function AR(r,e,t){return r[0]=e[0]/t[0],r[1]=e[1]/t[1],r[2]=e[2]/t[2],r}function bR(r,e){return r[0]=Math.ceil(e[0]),r[1]=Math.ceil(e[1]),r[2]=Math.ceil(e[2]),r}function TR(r,e){return r[0]=Math.floor(e[0]),r[1]=Math.floor(e[1]),r[2]=Math.floor(e[2]),r}function ER(r,e,t){return r[0]=Math.min(e[0],t[0]),r[1]=Math.min(e[1],t[1]),r[2]=Math.min(e[2],t[2]),r}function _R(r,e,t){return r[0]=Math.max(e[0],t[0]),r[1]=Math.max(e[1],t[1]),r[2]=Math.max(e[2],t[2]),r}function FR(r,e){return r[0]=Math.round(e[0]),r[1]=Math.round(e[1]),r[2]=Math.round(e[2]),r}function IR(r,e,t){return r[0]=e[0]*t,r[1]=e[1]*t,r[2]=e[2]*t,r}function PR(r,e,t,n){return r[0]=e[0]+t[0]*n,r[1]=e[1]+t[1]*n,r[2]=e[2]+t[2]*n,r}function LR(r,e){var t=e[0]-r[0],n=e[1]-r[1],i=e[2]-r[2];return Math.hypot(t,n,i)}function DR(r,e){var t=e[0]-r[0],n=e[1]-r[1],i=e[2]-r[2];return t*t+n*n+i*i}function OR(r){var e=r[0],t=r[1],n=r[2];return e*e+t*t+n*n}function kR(r,e){return r[0]=-e[0],r[1]=-e[1],r[2]=-e[2],r}function BR(r,e){return r[0]=1/e[0],r[1]=1/e[1],r[2]=1/e[2],r}function RR(r,e){var t=e[0],n=e[1],i=e[2],a=t*t+n*n+i*i;return a>0&&(a=1/Math.sqrt(a)),r[0]=e[0]*a,r[1]=e[1]*a,r[2]=e[2]*a,r}function ym(r,e){return r[0]*e[0]+r[1]*e[1]+r[2]*e[2]}function NR(r,e,t){var n=e[0],i=e[1],a=e[2],o=t[0],s=t[1],l=t[2];return r[0]=i*l-a*s,r[1]=a*o-n*l,r[2]=n*s-i*o,r}function UR(r,e,t,n){var i=e[0],a=e[1],o=e[2];return r[0]=i+n*(t[0]-i),r[1]=a+n*(t[1]-a),r[2]=o+n*(t[2]-o),r}function zR(r,e,t,n,i,a){var o=a*a,s=o*(2*a-3)+1,l=o*(a-2)+a,u=o*(a-1),c=o*(3-2*a);return r[0]=e[0]*s+t[0]*l+n[0]*u+i[0]*c,r[1]=e[1]*s+t[1]*l+n[1]*u+i[1]*c,r[2]=e[2]*s+t[2]*l+n[2]*u+i[2]*c,r}function VR(r,e,t,n,i,a){var o=1-a,s=o*o,l=a*a,u=s*o,c=3*a*s,h=3*l*o,v=l*a;return r[0]=e[0]*u+t[0]*c+n[0]*h+i[0]*v,r[1]=e[1]*u+t[1]*c+n[1]*h+i[1]*v,r[2]=e[2]*u+t[2]*c+n[2]*h+i[2]*v,r}function HR(r,e){e=e||1;var t=glMatrix.RANDOM()*2*Math.PI,n=glMatrix.RANDOM()*2-1,i=Math.sqrt(1-n*n)*e;return r[0]=Math.cos(t)*i,r[1]=Math.sin(t)*i,r[2]=n*e,r}function GR(r,e,t){var n=e[0],i=e[1],a=e[2],o=t[3]*n+t[7]*i+t[11]*a+t[15];return o=o||1,r[0]=(t[0]*n+t[4]*i+t[8]*a+t[12])/o,r[1]=(t[1]*n+t[5]*i+t[9]*a+t[13])/o,r[2]=(t[2]*n+t[6]*i+t[10]*a+t[14])/o,r}function Ba(r,e,t){var n=e[0],i=e[1],a=e[2];return r[0]=n*t[0]+i*t[3]+a*t[6],r[1]=n*t[1]+i*t[4]+a*t[7],r[2]=n*t[2]+i*t[5]+a*t[8],r}function YR(r,e,t){var n=t[0],i=t[1],a=t[2],o=t[3],s=e[0],l=e[1],u=e[2],c=i*u-a*l,h=a*s-n*u,v=n*l-i*s,d=i*v-a*h,g=a*c-n*v,y=n*h-i*c,x=o*2;return c*=x,h*=x,v*=x,d*=2,g*=2,y*=2,r[0]=s+c+d,r[1]=l+h+g,r[2]=u+v+y,r}function XR(r,e,t,n){var i=[],a=[];return i[0]=e[0]-t[0],i[1]=e[1]-t[1],i[2]=e[2]-t[2],a[0]=i[0],a[1]=i[1]*Math.cos(n)-i[2]*Math.sin(n),a[2]=i[1]*Math.sin(n)+i[2]*Math.cos(n),r[0]=a[0]+t[0],r[1]=a[1]+t[1],r[2]=a[2]+t[2],r}function WR(r,e,t,n){var i=[],a=[];return i[0]=e[0]-t[0],i[1]=e[1]-t[1],i[2]=e[2]-t[2],a[0]=i[2]*Math.sin(n)+i[0]*Math.cos(n),a[1]=i[1],a[2]=i[2]*Math.cos(n)-i[0]*Math.sin(n),r[0]=a[0]+t[0],r[1]=a[1]+t[1],r[2]=a[2]+t[2],r}function ZR(r,e,t,n){var i=[],a=[];return i[0]=e[0]-t[0],i[1]=e[1]-t[1],i[2]=e[2]-t[2],a[0]=i[0]*Math.cos(n)-i[1]*Math.sin(n),a[1]=i[0]*Math.sin(n)+i[1]*Math.cos(n),a[2]=i[2],r[0]=a[0]+t[0],r[1]=a[1]+t[1],r[2]=a[2]+t[2],r}function $R(r,e){var t=r[0],n=r[1],i=r[2],a=e[0],o=e[1],s=e[2],l=Math.sqrt(t*t+n*n+i*i),u=Math.sqrt(a*a+o*o+s*s),c=l*u,h=c&&ym(r,e)/c;return Math.acos(Math.min(Math.max(h,-1),1))}function qR(r){return r[0]=0,r[1]=0,r[2]=0,r}function KR(r){return"vec3("+r[0]+", "+r[1]+", "+r[2]+")"}function jR(r,e){return r[0]===e[0]&&r[1]===e[1]&&r[2]===e[2]}function JR(r,e){var t=r[0],n=r[1],i=r[2],a=e[0],o=e[1],s=e[2];return Math.abs(t-a)<=glMatrix.EPSILON*Math.max(1,Math.abs(t),Math.abs(a))&&Math.abs(n-o)<=glMatrix.EPSILON*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(i-s)<=glMatrix.EPSILON*Math.max(1,Math.abs(i),Math.abs(s))}var QR=null,t6=null,e6=null,r6=null,n6=null,i6=null,a6=null,o6=function(){var r=gm();return function(e,t,n,i,a,o){var s,l;for(t||(t=3),n||(n=0),i?l=Math.min(i*t+n,e.length):l=e.length,s=n;s<l;s+=t)r[0]=e[s],r[1]=e[s+1],r[2]=e[s+2],a(r,r,o),e[s]=r[0],e[s+1]=r[1],e[s+2]=r[2];return e}}(),mm=N(35600),nr=N(31506),xm=function(){function r(e){this.type="coordinate",this.isRect=!1,this.isHelix=!1,this.isPolar=!1,this.isReflectX=!1,this.isReflectY=!1;var t=e.start,n=e.end,i=e.matrix,a=i===void 0?[1,0,0,0,1,0,0,0,1]:i,o=e.isTransposed,s=o===void 0?!1:o;this.start=t,this.end=n,this.matrix=a,this.originalMatrix=(0,p.ev)([],a),this.isTransposed=s}return r.prototype.initial=function(){this.center={x:(this.start.x+this.end.x)/2,y:(this.start.y+this.end.y)/2},this.width=Math.abs(this.end.x-this.start.x),this.height=Math.abs(this.end.y-this.start.y)},r.prototype.update=function(e){(0,f.f0)(this,e),this.initial()},r.prototype.convertDim=function(e,t){var n,i=this[t],a=i.start,o=i.end;return this.isReflect(t)&&(n=[o,a],a=n[0],o=n[1]),a+e*(o-a)},r.prototype.invertDim=function(e,t){var n,i=this[t],a=i.start,o=i.end;return this.isReflect(t)&&(n=[o,a],a=n[0],o=n[1]),(e-a)/(o-a)},r.prototype.applyMatrix=function(e,t,n){n===void 0&&(n=0);var i=this.matrix,a=[e,t,n];return Ba(a,a,i),a},r.prototype.invertMatrix=function(e,t,n){n===void 0&&(n=0);var i=this.matrix,a=mm.U_([0,0,0,0,0,0,0,0,0],i),o=[e,t,n];return a&&Ba(o,o,a),o},r.prototype.convert=function(e){var t=this.convertPoint(e),n=t.x,i=t.y,a=this.applyMatrix(n,i,1);return{x:a[0],y:a[1]}},r.prototype.invert=function(e){var t=this.invertMatrix(e.x,e.y,1);return this.invertPoint({x:t[0],y:t[1]})},r.prototype.rotate=function(e){var t=this.matrix,n=this.center;return nr.m$(t,t,[-n.x,-n.y]),nr.zu(t,t,e),nr.m$(t,t,[n.x,n.y]),this},r.prototype.reflect=function(e){return e==="x"?this.isReflectX=!this.isReflectX:this.isReflectY=!this.isReflectY,this},r.prototype.scale=function(e,t){var n=this.matrix,i=this.center;return nr.m$(n,n,[-i.x,-i.y]),nr.lh(n,n,[e,t]),nr.m$(n,n,[i.x,i.y]),this},r.prototype.translate=function(e,t){var n=this.matrix;return nr.m$(n,n,[e,t]),this},r.prototype.transpose=function(){return this.isTransposed=!this.isTransposed,this},r.prototype.getCenter=function(){return this.center},r.prototype.getWidth=function(){return this.width},r.prototype.getHeight=function(){return this.height},r.prototype.getRadius=function(){return this.radius},r.prototype.isReflect=function(e){return e==="x"?this.isReflectX:this.isReflectY},r.prototype.resetMatrix=function(e){this.matrix=e||(0,p.ev)([],this.originalMatrix)},r}(),Jl=xm,Mm=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.isRect=!0,n.type="cartesian",n.initial(),n}return e.prototype.initial=function(){r.prototype.initial.call(this);var t=this.start,n=this.end;this.x={start:t.x,end:n.x},this.y={start:t.y,end:n.y}},e.prototype.convertPoint=function(t){var n,i=t.x,a=t.y;return this.isTransposed&&(n=[a,i],i=n[0],a=n[1]),{x:this.convertDim(i,"x"),y:this.convertDim(a,"y")}},e.prototype.invertPoint=function(t){var n,i=this.invertDim(t.x,"x"),a=this.invertDim(t.y,"y");return this.isTransposed&&(n=[a,i],i=n[0],a=n[1]),{x:i,y:a}},e}(Jl),Gf=Mm,xe=N(31437),wm=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.isHelix=!0,n.type="helix";var i=t.startAngle,a=i===void 0?1.25*Math.PI:i,o=t.endAngle,s=o===void 0?7.25*Math.PI:o,l=t.innerRadius,u=l===void 0?0:l,c=t.radius;return n.startAngle=a,n.endAngle=s,n.innerRadius=u,n.radius=c,n.initial(),n}return e.prototype.initial=function(){r.prototype.initial.call(this);var t=(this.endAngle-this.startAngle)/(2*Math.PI)+1,n=Math.min(this.width,this.height)/2;this.radius&&this.radius>=0&&this.radius<=1&&(n=n*this.radius),this.d=Math.floor(n*(1-this.innerRadius)/t),this.a=this.d/(Math.PI*2),this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*n,end:this.innerRadius*n+this.d*.99}},e.prototype.convertPoint=function(t){var n,i=t.x,a=t.y;this.isTransposed&&(n=[a,i],i=n[0],a=n[1]);var o=this.convertDim(i,"x"),s=this.a*o,l=this.convertDim(a,"y");return{x:this.center.x+Math.cos(o)*(s+l),y:this.center.y+Math.sin(o)*(s+l)}},e.prototype.invertPoint=function(t){var n,i=this.d+this.y.start,a=xe.$X([0,0],[t.x,t.y],[this.center.x,this.center.y]),o=nr.Dg(a,[1,0],!0),s=o*this.a;xe.kE(a)<s&&(s=xe.kE(a));var l=Math.floor((xe.kE(a)-s)/i);o=2*l*Math.PI+o;var u=this.a*o,c=xe.kE(a)-u;c=(0,f.vQ)(c,0)?0:c;var h=this.invertDim(o,"x"),v=this.invertDim(c,"y");return h=(0,f.vQ)(h,0)?0:h,v=(0,f.vQ)(v,0)?0:v,this.isTransposed&&(n=[v,h],h=n[0],v=n[1]),{x:h,y:v}},e}(Jl),Sm=wm,Cm=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.isPolar=!0,n.type="polar";var i=t.startAngle,a=i===void 0?-Math.PI/2:i,o=t.endAngle,s=o===void 0?Math.PI*3/2:o,l=t.innerRadius,u=l===void 0?0:l,c=t.radius;return n.startAngle=a,n.endAngle=s,n.innerRadius=u,n.radius=c,n.initial(),n}return e.prototype.initial=function(){for(r.prototype.initial.call(this);this.endAngle<this.startAngle;)this.endAngle+=Math.PI*2;var t=this.getOneBox(),n=t.maxX-t.minX,i=t.maxY-t.minY,a=Math.abs(t.minX)/n,o=Math.abs(t.minY)/i,s;this.height/i>this.width/n?(s=this.width/n,this.circleCenter={x:this.center.x-(.5-a)*this.width,y:this.center.y-(.5-o)*s*i}):(s=this.height/i,this.circleCenter={x:this.center.x-(.5-a)*s*n,y:this.center.y-(.5-o)*this.height}),this.polarRadius=this.radius,this.radius?this.radius>0&&this.radius<=1?this.polarRadius=s*this.radius:(this.radius<=0||this.radius>s)&&(this.polarRadius=s):this.polarRadius=s,this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*this.polarRadius,end:this.polarRadius}},e.prototype.getRadius=function(){return this.polarRadius},e.prototype.convertPoint=function(t){var n,i=this.getCenter(),a=t.x,o=t.y;return this.isTransposed&&(n=[o,a],a=n[0],o=n[1]),a=this.convertDim(a,"x"),o=this.convertDim(o,"y"),{x:i.x+Math.cos(a)*o,y:i.y+Math.sin(a)*o}},e.prototype.invertPoint=function(t){var n,i=this.getCenter(),a=[t.x-i.x,t.y-i.y],o=this,s=o.startAngle,l=o.endAngle;this.isReflect("x")&&(n=[l,s],s=n[0],l=n[1]);var u=[1,0,0,0,1,0,0,0,1];nr.zu(u,u,s);var c=[1,0,0];Ba(c,c,u);var h=[c[0],c[1]],v=nr.Dg(h,a,l<s);(0,f.vQ)(v,Math.PI*2)&&(v=0);var d=xe.kE(a),g=v/(l-s);g=l-s>0?g:-g;var y=this.invertDim(d,"y"),x={x:0,y:0};return x.x=this.isTransposed?y:g,x.y=this.isTransposed?g:y,x},e.prototype.getCenter=function(){return this.circleCenter},e.prototype.getOneBox=function(){var t=this.startAngle,n=this.endAngle;if(Math.abs(n-t)>=Math.PI*2)return{minX:-1,maxX:1,minY:-1,maxY:1};for(var i=[0,Math.cos(t),Math.cos(n)],a=[0,Math.sin(t),Math.sin(n)],o=Math.min(t,n);o<Math.max(t,n);o+=Math.PI/18)i.push(Math.cos(o)),a.push(Math.sin(o));return{minX:Math.min.apply(Math,i),maxX:Math.max.apply(Math,i),minY:Math.min.apply(Math,a),maxY:Math.max.apply(Math,a)}},e}(Jl),Am=Cm,Yf={},bm=function(r){return Yf[r.toLowerCase()]},Jo=function(r,e){Yf[r.toLowerCase()]=e};Jo("rect",Gf),Jo("cartesian",Gf),Jo("polar",Am),Jo("helix",Sm);function Xf(r,e,t){var n=new F.Event(e,t);n.target=r,n.propagationPath.push(r),r.emitDelegation(e,n);for(var i=r.getParent();i;)i.emitDelegation(e,n),n.propagationPath.push(i),i=i.getParent()}var Wf=[1,0,0,0,1,0,0,0,1];function Si(r,e,t){if(t===void 0&&(t=Wf),!e)return null;var n=nr.vs(t,[["t",-r.x,-r.y],["r",e],["t",r.x,r.y]]);return n}function Ql(r,e){return!r.x&&!r.y?null:nr.vs(e||Wf,[["t",r.x,r.y]])}function Tm(r){var e=[1,0,0],t=[0,0,0];return Ba(t,e,r),Math.atan2(t[1],t[0])}function Qo(r,e){var t=[0,0];return xe.kK(t,e,r),t}function Em(r,e){var t=Qo(r,[e.minX,e.minY]),n=Qo(r,[e.maxX,e.minY]),i=Qo(r,[e.minX,e.maxY]),a=Qo(r,[e.maxX,e.maxY]),o=Math.min(t[0],n[0],i[0],a[0]),s=Math.max(t[0],n[0],i[0],a[0]),l=Math.min(t[1],n[1],i[1],a[1]),u=Math.max(t[1],n[1],i[1],a[1]);return{x:o,y:l,minX:o,minY:l,maxX:s,maxY:u,width:s-o,height:u-l}}function Zf(r,e,t,n){if(e){var i=Si({x:t,y:n},e,r.getMatrix());r.setMatrix(i)}}function tu(r,e,t){var n=Ql({x:e,y:t});r.attr("matrix",n)}function ts(r){var e=0,t=0,n=0,i=0;return(0,f.hj)(r)?e=t=n=i=r:(0,f.kJ)(r)&&(e=r[0],n=(0,f.UM)(r[1])?r[0]:r[1],i=(0,f.UM)(r[2])?r[0]:r[2],t=(0,f.UM)(r[3])?n:r[3]),[e,n,i,t]}function eu(r){for(var e=r.childNodes,t=e.length,n=t-1;n>=0;n--)r.removeChild(e[n])}function _m(r,e){return!!r.className.match(new RegExp("(\\s|^)"+e+"(\\s|$)"))}function Ra(r){var e=r.start,t=r.end,n=Math.min(e.x,t.x),i=Math.min(e.y,t.y),a=Math.max(e.x,t.x),o=Math.max(e.y,t.y);return{x:n,y:i,minX:n,minY:i,maxX:a,maxY:o,width:a-n,height:o-i}}function Fm(r){var e=r.map(function(s){return s.x}),t=r.map(function(s){return s.y}),n=Math.min.apply(Math,e),i=Math.min.apply(Math,t),a=Math.max.apply(Math,e),o=Math.max.apply(Math,t);return{x:n,y:i,minX:n,minY:i,maxX:a,maxY:o,width:a-n,height:o-i}}function Na(r,e,t,n){var i=r+t,a=e+n;return{x:r,y:e,width:t,height:n,minX:r,minY:e,maxX:isNaN(i)?0:i,maxY:isNaN(a)?0:a}}function Ci(r,e,t){return(1-t)*r+e*t}function ea(r,e,t){return{x:r.x+Math.cos(t)*e,y:r.y+Math.sin(t)*e}}function Im(r,e){var t=e.x-r.x,n=e.y-r.y;return Math.sqrt(t*t+n*n)}var s6=function(r){return new Promise(function(e){setTimeout(e,r)})},es=function(r,e,t){return t===void 0&&(t=Math.pow(Number.EPSILON,.5)),[r,e].includes(Infinity)?Math.abs(r)===Math.abs(e):Math.abs(r-e)<t};function Pm(r,e){var t=Math.max(r.minX,e.minX),n=Math.max(r.minY,e.minY),i=Math.min(r.maxX,e.maxX),a=Math.min(r.maxY,e.maxY);return Na(t,n,i-t,a-n)}function l6(r,e){var t=Math.min(r.minX,e.minX),n=Math.min(r.minY,e.minY),i=Math.max(r.maxX,e.maxX),a=Math.max(r.maxY,e.maxY);return Na(t,n,i-t,a-n)}function $f(r){var e=r.getClip(),t=e&&e.getBBox(),n;if(!r.isGroup())n=r.getBBox();else{var i=Infinity,a=-Infinity,o=Infinity,s=-Infinity,l=r.getChildren();l.length>0?(0,f.S6)(l,function(u){if(u.get("visible")){if(u.isGroup()&&u.get("children").length===0)return!0;var c=$f(u),h=u.applyToMatrix([c.minX,c.minY,1]),v=u.applyToMatrix([c.minX,c.maxY,1]),d=u.applyToMatrix([c.maxX,c.minY,1]),g=u.applyToMatrix([c.maxX,c.maxY,1]),y=Math.min(h[0],v[0],d[0],g[0]),x=Math.max(h[0],v[0],d[0],g[0]),m=Math.min(h[1],v[1],d[1],g[1]),M=Math.max(h[1],v[1],d[1],g[1]);y<i&&(i=y),x>a&&(a=x),m<o&&(o=m),M>s&&(s=M)}}):(i=0,a=0,o=0,s=0),n=Na(i,o,a-i,s-o)}return t?Pm(n,t):n}function Lm(r,e){if(!(!r.getClip()&&!e.getClip())){var t=e.getClip();if(!t){r.setClip(null);return}var n={type:t.get("type"),attrs:t.attr()};r.setClip(n)}}function Br(r){return r+"px"}function qf(r,e,t,n){var i=Im(r,e),a=n/i,o=0;return t==="start"?o=0-a:t==="end"&&(o=1+a),{x:Ci(r.x,e.x,o),y:Ci(r.y,e.y,o)}}var Dm={none:[],point:["x","y"],region:["start","end"],points:["points"],circle:["center","radius","startAngle","endAngle"]},Om=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.initCfg(),n}return e.prototype.getDefaultCfg=function(){return{id:"",name:"",type:"",locationType:"none",offsetX:0,offsetY:0,animate:!1,capture:!0,updateAutoRender:!1,animateOption:{appear:null,update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}},events:null,defaultCfg:{},visible:!0}},e.prototype.clear=function(){},e.prototype.update=function(t){var n=this,i=this.get("defaultCfg")||{};(0,f.S6)(t,function(a,o){var s=n.get(o),l=a;s!==a&&((0,f.Kn)(a)&&i[o]&&(l=(0,f.b$)({},i[o],a)),n.set(o,l))}),this.updateInner(t),this.afterUpdate(t)},e.prototype.updateInner=function(t){},e.prototype.afterUpdate=function(t){(0,f.wH)(t,"visible")&&(t.visible?this.show():this.hide()),(0,f.wH)(t,"capture")&&this.setCapture(t.capture)},e.prototype.getLayoutBBox=function(){return this.getBBox()},e.prototype.getLocationType=function(){return this.get("locationType")},e.prototype.getOffset=function(){return{offsetX:this.get("offsetX"),offsetY:this.get("offsetY")}},e.prototype.setOffset=function(t,n){this.update({offsetX:t,offsetY:n})},e.prototype.setLocation=function(t){var n=(0,p.pi)({},t);this.update(n)},e.prototype.getLocation=function(){var t=this,n={},i=this.get("locationType"),a=Dm[i];return(0,f.S6)(a,function(o){n[o]=t.get(o)}),n},e.prototype.isList=function(){return!1},e.prototype.isSlider=function(){return!1},e.prototype.init=function(){},e.prototype.initCfg=function(){var t=this,n=this.get("defaultCfg");(0,f.S6)(n,function(i,a){var o=t.get(a);if((0,f.Kn)(o)){var s=(0,f.b$)({},i,o);t.set(a,s)}})},e}(F.Base),Kf=Om,Ai="update_status",km=["visible","tip","delegateObject"],Bm=["container","group","shapesMap","isRegister","isUpdating","destroyed"],Rm=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{container:null,shapesMap:{},group:null,capture:!0,isRegister:!1,isUpdating:!1,isInit:!0})},e.prototype.remove=function(){this.clear();var t=this.get("group");t.remove()},e.prototype.clear=function(){var t=this.get("group");t.clear(),this.set("shapesMap",{}),this.clearOffScreenCache(),this.set("isInit",!0)},e.prototype.getChildComponentById=function(t){var n=this.getElementById(t),i=n&&n.get("component");return i},e.prototype.getElementById=function(t){return this.get("shapesMap")[t]},e.prototype.getElementByLocalId=function(t){var n=this.getElementId(t);return this.getElementById(n)},e.prototype.getElementsByName=function(t){var n=[];return(0,f.S6)(this.get("shapesMap"),function(i){i.get("name")===t&&n.push(i)}),n},e.prototype.getContainer=function(){return this.get("container")},e.prototype.updateInner=function(t){this.offScreenRender(),this.get("updateAutoRender")&&this.render()},e.prototype.render=function(){var t=this.get("offScreenGroup");t||(t=this.offScreenRender());var n=this.get("group");this.updateElements(t,n),this.deleteElements(),this.applyOffset(),this.get("eventInitted")||(this.initEvent(),this.set("eventInitted",!0)),this.set("isInit",!1)},e.prototype.show=function(){var t=this.get("group");t.show(),this.set("visible",!0)},e.prototype.hide=function(){var t=this.get("group");t.hide(),this.set("visible",!1)},e.prototype.setCapture=function(t){var n=this.get("group");n.set("capture",t),this.set("capture",t)},e.prototype.destroy=function(){this.removeEvent(),this.remove(),r.prototype.destroy.call(this)},e.prototype.getBBox=function(){return this.get("group").getCanvasBBox()},e.prototype.getLayoutBBox=function(){var t=this.get("group"),n=this.getInnerLayoutBBox(),i=t.getTotalMatrix();return i&&(n=Em(i,n)),n},e.prototype.on=function(t,n,i){var a=this.get("group");return a.on(t,n,i),this},e.prototype.off=function(t,n){var i=this.get("group");return i&&i.off(t,n),this},e.prototype.emit=function(t,n){var i=this.get("group");i.emit(t,n)},e.prototype.init=function(){r.prototype.init.call(this),this.get("group")||this.initGroup(),this.offScreenRender()},e.prototype.getInnerLayoutBBox=function(){return this.get("offScreenBBox")||this.get("group").getBBox()},e.prototype.delegateEmit=function(t,n){var i=this.get("group");n.target=i,i.emit(t,n),Xf(i,t,n)},e.prototype.createOffScreenGroup=function(){var t=this.get("group"),n=t.getGroupBase(),i=new n({delegateObject:this.getDelegateObject()});return i},e.prototype.applyOffset=function(){var t=this.get("offsetX"),n=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t,y:n})},e.prototype.initGroup=function(){var t=this.get("container");this.set("group",t.addGroup({id:this.get("id"),name:this.get("name"),capture:this.get("capture"),visible:this.get("visible"),isComponent:!0,component:this,delegateObject:this.getDelegateObject()}))},e.prototype.offScreenRender=function(){this.clearOffScreenCache();var t=this.createOffScreenGroup();return this.renderInner(t),this.set("offScreenGroup",t),this.set("offScreenBBox",$f(t)),t},e.prototype.addGroup=function(t,n){this.appendDelegateObject(t,n);var i=t.addGroup(n);return this.get("isRegister")&&this.registerElement(i),i},e.prototype.addShape=function(t,n){this.appendDelegateObject(t,n);var i=t.addShape(n);return this.get("isRegister")&&this.registerElement(i),i},e.prototype.addComponent=function(t,n){var i=n.id,a=n.component,o=(0,p._T)(n,["id","component"]),s=new a((0,p.pi)((0,p.pi)({},o),{id:i,container:t,updateAutoRender:this.get("updateAutoRender")}));return s.init(),s.render(),this.get("isRegister")&&this.registerElement(s.get("group")),s},e.prototype.initEvent=function(){},e.prototype.removeEvent=function(){var t=this.get("group");t.off()},e.prototype.getElementId=function(t){var n=this.get("id"),i=this.get("name");return n+"-"+i+"-"+t},e.prototype.registerElement=function(t){var n=t.get("id");this.get("shapesMap")[n]=t},e.prototype.unregisterElement=function(t){var n=t.get("id");delete this.get("shapesMap")[n]},e.prototype.moveElementTo=function(t,n){var i=Ql(n);t.attr("matrix",i)},e.prototype.addAnimation=function(t,n,i){var a=n.attr("opacity");(0,f.UM)(a)&&(a=1),n.attr("opacity",0),n.animate({opacity:a},i)},e.prototype.removeAnimation=function(t,n,i){n.animate({opacity:0},i)},e.prototype.updateAnimation=function(t,n,i,a){n.animate(i,a)},e.prototype.updateElements=function(t,n){var i=this,a=this.get("animate"),o=this.get("animateOption"),s=t.getChildren().slice(0),l;(0,f.S6)(s,function(u){var c=u.get("id"),h=i.getElementById(c),v=u.get("name");if(h)if(u.get("isComponent")){var d=u.get("component"),g=h.get("component"),y=(0,f.ei)(d.cfg,(0,f.e5)((0,f.XP)(d.cfg),Bm));g.update(y),h.set(Ai,"update")}else{var x=i.getReplaceAttrs(h,u);a&&o.update?i.updateAnimation(v,h,x,o.update):h.attr(x),u.isGroup()&&i.updateElements(u,h),(0,f.S6)(km,function(S){h.set(S,u.get(S))}),Lm(h,u),l=h,h.set(Ai,"update")}else{n.add(u);var m=n.getChildren();if(m.splice(m.length-1,1),l){var M=m.indexOf(l);m.splice(M+1,0,u)}else m.unshift(u);if(i.registerElement(u),u.set(Ai,"add"),u.get("isComponent")){var d=u.get("component");d.set("container",n)}else u.isGroup()&&i.registerNewGroup(u);if(l=u,a){var w=i.get("isInit")?o.appear:o.enter;w&&i.addAnimation(v,u,w)}}})},e.prototype.clearUpdateStatus=function(t){var n=t.getChildren();(0,f.S6)(n,function(i){i.set(Ai,null)})},e.prototype.clearOffScreenCache=function(){var t=this.get("offScreenGroup");t&&t.destroy(),this.set("offScreenGroup",null),this.set("offScreenBBox",null)},e.prototype.getDelegateObject=function(){var t,n=this.get("name"),i=(t={},t[n]=this,t.component=this,t);return i},e.prototype.appendDelegateObject=function(t,n){var i=t.get("delegateObject");n.delegateObject||(n.delegateObject={}),(0,f.CD)(n.delegateObject,i)},e.prototype.getReplaceAttrs=function(t,n){var i=t.attr(),a=n.attr();return(0,f.S6)(i,function(o,s){a[s]===void 0&&(a[s]=void 0)}),a},e.prototype.registerNewGroup=function(t){var n=this,i=t.getChildren();(0,f.S6)(i,function(a){n.registerElement(a),a.set(Ai,"add"),a.isGroup()&&n.registerNewGroup(a)})},e.prototype.deleteElements=function(){var t=this,n=this.get("shapesMap"),i=[];(0,f.S6)(n,function(s,l){!s.get(Ai)||s.destroyed?i.push([l,s]):s.set(Ai,null)});var a=this.get("animate"),o=this.get("animateOption");(0,f.S6)(i,function(s){var l=s[0],u=s[1];if(!u.destroyed){var c=u.get("name");if(a&&o.leave){var h=(0,f.CD)({callback:function(){t.removeElement(u)}},o.leave);t.removeAnimation(c,u,h)}else t.removeElement(u)}delete n[l]})},e.prototype.removeElement=function(t){if(t.get("isGroup")){var n=t.get("component");n&&n.destroy()}t.remove()},e}(Kf),Ar=Rm,ru="\u2026";function Nm(r){for(var e=0,t=0;t<r.length;t++)e+=bi(r,t);return e}function bi(r,e){return r.charCodeAt(e)>0&&r.charCodeAt(e)<128?1:2}function Um(r,e,t){t===void 0&&(t="tail");var n=r.length,i="";if(t==="tail"){for(var a=0,o=0;a<e;){var s=bi(r,o);if(a+s<=e)i+=r[o],a+=bi(r,o),o++;else break}i+=ru}else if(t==="head"){for(var a=0,o=n-1;a<e;){var s=bi(r,o);if(a+s<=e)i+=r[o],a+=bi(r,o),o--;else break}i=ru+i}else{for(var l="",u="",a=0,c=0,h=n-1;a<e;){var v=bi(r,c),d=!1;v+a<=e&&(l+=r[c],c++,a+=v,d=!0);var g=bi(r,h);if(g+a<=e&&(u=r[h]+u,a+=g,h--,d=!0),!d)break}i=l+ru+u}return i}var zm="\u2026",Vm=2,Hm=400;function Gm(r){for(var e=r.map(function(l){var u=l.attr("text");return(0,f.UM)(u)?"":""+u}),t=0,n=0,i=0;i<e.length;i+=1){for(var a=0,o=0;o<=e[i].length;o+=1){var s=e[i].charCodeAt(o);s>=19968&&s<=40869?a+=2:a+=1}a>t&&(t=a,n=i)}return r[n].getBBox().width}function nu(r){if(r.length>Hm)return Gm(r);var e=0;return(0,f.S6)(r,function(t){var n=t.getBBox(),i=n.width;e<i&&(e=i)}),e}function Ym(r,e){var t=e.getCanvasBBox();return r?t.width:t.height}function u6(r,e){return r.getBBox().width<e}function Ua(r,e,t,n){var i;n===void 0&&(n="tail");var a=(i=e.attr("text"))!==null&&i!==void 0?i:"";if(n==="tail"){var o=(0,f.ei)(e.attr(),["fontSize","fontFamily","fontWeight","fontStyle","fontVariant"]),s=(0,f.Lo)(a,t,o,"\u2026");return a!==s?(e.attr("text",s),e.set("tip",a),!0):(e.set("tip",null),!1)}var l=Ym(r,e),u=Nm(a),c=!1;if(t<l){var h=Math.floor(t/l*u)-Vm,v=void 0;h>=0?v=Um(a,h,n):v=zm,v&&(e.attr("text",v),c=!0)}return c?e.set("tip",a):e.set("tip",null),c}function rs(r,e){var t=e.x,n=e.y,i=e.content,a=e.style,o=e.id,s=e.name,l=e.rotate,u=e.maxLength,c=e.autoEllipsis,h=e.isVertical,v=e.ellipsisPosition,d=e.background,g=r.addGroup({id:o+"-group",name:s+"-group",attrs:{x:t,y:n}}),y=g.addShape({type:"text",id:o,name:s,attrs:(0,p.pi)({x:0,y:0,text:i},a)}),x=ts((0,f.U2)(d,"padding",0));if(u&&c){var m=u-(x[1]+x[3]);Ua(!h,y,m,v)}if(d){var M=(0,f.U2)(d,"style",{}),w=y.getCanvasBBox(),S=w.minX,b=w.minY,k=w.width,H=w.height,at=g.addShape("rect",{id:o+"-bg",name:o+"-bg",attrs:(0,p.pi)({x:S-x[3],y:b-x[0],width:k+x[1]+x[3],height:H+x[0]+x[2]},M)});at.toBack()}tu(g,t,n),Zf(g,l,t,n)}var Ge={fontFamily:`
  29. BlinkMacSystemFont, "Segoe UI", Roboto,"Helvetica Neue",
  30. Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
  31. SimSun, "sans-serif"`,textColor:"#2C3542",activeTextColor:"#333333",uncheckedColor:"#D8D8D8",lineColor:"#416180",regionColor:"#CCD7EB",verticalAxisRotate:-Math.PI/4,horizontalAxisRotate:Math.PI/4,descriptionIconStroke:"#fff",descriptionIconFill:"rgba(58, 73, 101, .25)"},Xm=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"line",locationType:"region",start:null,end:null,style:{},text:null,defaultCfg:{style:{fill:Ge.textColor,fontSize:12,textAlign:"center",textBaseline:"bottom",fontFamily:Ge.fontFamily},text:{position:"center",autoRotate:!0,content:null,offsetX:0,offsetY:0,style:{stroke:Ge.lineColor,lineWidth:1}}}})},e.prototype.renderInner=function(t){this.renderLine(t),this.get("text")&&this.renderLabel(t)},e.prototype.renderLine=function(t){var n=this.get("start"),i=this.get("end"),a=this.get("style");this.addShape(t,{type:"line",id:this.getElementId("line"),name:"annotation-line",attrs:(0,p.pi)({x1:n.x,y1:n.y,x2:i.x,y2:i.y},a)})},e.prototype.getLabelPoint=function(t,n,i){var a;return i==="start"?a=0:i==="center"?a=.5:(0,f.HD)(i)&&i.indexOf("%")!==-1?a=parseInt(i,10)/100:(0,f.hj)(i)?a=i:a=1,(a>1||a<0)&&(a=1),{x:Ci(t.x,n.x,a),y:Ci(t.y,n.y,a)}},e.prototype.renderLabel=function(t){var n=this.get("text"),i=this.get("start"),a=this.get("end"),o=n.position,s=n.content,l=n.style,u=n.offsetX,c=n.offsetY,h=n.autoRotate,v=n.maxLength,d=n.autoEllipsis,g=n.ellipsisPosition,y=n.background,x=n.isVertical,m=x===void 0?!1:x,M=this.getLabelPoint(i,a,o),w=M.x+u,S=M.y+c,b={id:this.getElementId("line-text"),name:"annotation-line-text",x:w,y:S,content:s,style:l,maxLength:v,autoEllipsis:d,ellipsisPosition:g,background:y,isVertical:m};if(h){var k=[a.x-i.x,a.y-i.y];b.rotate=Math.atan2(k[1],k[0])}rs(t,b)},e}(Ar),Wm=Xm,Zm=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"text",locationType:"point",x:0,y:0,content:"",rotate:null,style:{},background:null,maxLength:null,autoEllipsis:!0,isVertical:!1,ellipsisPosition:"tail",defaultCfg:{style:{fill:Ge.textColor,fontSize:12,textAlign:"center",textBaseline:"middle",fontFamily:Ge.fontFamily}}})},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},e.prototype.renderInner=function(t){var n=this.getLocation(),i=n.x,a=n.y,o=this.get("content"),s=this.get("style"),l=this.getElementId("text"),u=this.get("name")+"-text",c=this.get("maxLength"),h=this.get("autoEllipsis"),v=this.get("isVertical"),d=this.get("ellipsisPosition"),g=this.get("background"),y=this.get("rotate"),x={id:l,name:u,x:i,y:a,content:o,style:s,maxLength:c,autoEllipsis:h,isVertical:v,ellipsisPosition:d,background:g,rotate:y};rs(t,x)},e.prototype.resetLocation=function(){var t=this.getElementByLocalId("text-group");if(t){var n=this.getLocation(),i=n.x,a=n.y,o=this.get("rotate");tu(t,i,a),Zf(t,o,i,a)}},e}(Ar),$m=Zm,qm=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"arc",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:Math.PI*3/2,style:{stroke:"#999",lineWidth:1}})},e.prototype.renderInner=function(t){this.renderArc(t)},e.prototype.getArcPath=function(){var t=this.getLocation(),n=t.center,i=t.radius,a=t.startAngle,o=t.endAngle,s=ea(n,i,a),l=ea(n,i,o),u=o-a>Math.PI?1:0,c=[["M",s.x,s.y]];if(o-a==Math.PI*2){var h=ea(n,i,a+Math.PI);c.push(["A",i,i,0,u,1,h.x,h.y]),c.push(["A",i,i,0,u,1,l.x,l.y])}else c.push(["A",i,i,0,u,1,l.x,l.y]);return c},e.prototype.renderArc=function(t){var n=this.getArcPath(),i=this.get("style");this.addShape(t,{type:"path",id:this.getElementId("arc"),name:"annotation-arc",attrs:(0,p.pi)({path:n},i)})},e}(Ar),Km=qm,jm=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"region",locationType:"region",start:null,end:null,style:{},defaultCfg:{style:{lineWidth:0,fill:Ge.regionColor,opacity:.4}}})},e.prototype.renderInner=function(t){this.renderRegion(t)},e.prototype.renderRegion=function(t){var n=this.get("start"),i=this.get("end"),a=this.get("style"),o=Ra({start:n,end:i});this.addShape(t,{type:"rect",id:this.getElementId("region"),name:"annotation-region",attrs:(0,p.pi)({x:o.x,y:o.y,width:o.width,height:o.height},a)})},e}(Ar),Jm=jm,Qm=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"image",locationType:"region",start:null,end:null,src:null,style:{}})},e.prototype.renderInner=function(t){this.renderImage(t)},e.prototype.getImageAttrs=function(){var t=this.get("start"),n=this.get("end"),i=this.get("style"),a=Ra({start:t,end:n}),o=this.get("src");return(0,p.pi)({x:a.x,y:a.y,img:o,width:a.width,height:a.height},i)},e.prototype.renderImage=function(t){this.addShape(t,{type:"image",id:this.getElementId("image"),name:"annotation-image",attrs:this.getImageAttrs()})},e}(Ar),tx=Qm,ex=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"dataMarker",locationType:"point",x:0,y:0,point:{},line:{},text:{},direction:"upward",autoAdjust:!0,coordinateBBox:null,defaultCfg:{point:{display:!0,style:{r:3,fill:"#FFFFFF",stroke:"#1890FF",lineWidth:2}},line:{display:!0,length:20,style:{stroke:Ge.lineColor,lineWidth:1}},text:{content:"",display:!0,style:{fill:Ge.textColor,opacity:.65,fontSize:12,textAlign:"start",fontFamily:Ge.fontFamily}}}})},e.prototype.renderInner=function(t){(0,f.U2)(this.get("line"),"display")&&this.renderLine(t),(0,f.U2)(this.get("text"),"display")&&this.renderText(t),(0,f.U2)(this.get("point"),"display")&&this.renderPoint(t),this.get("autoAdjust")&&this.autoAdjust(t)},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x")+this.get("offsetX"),y:this.get("y")+this.get("offsetY")})},e.prototype.renderPoint=function(t){var n=this.getShapeAttrs().point;this.addShape(t,{type:"circle",id:this.getElementId("point"),name:"annotation-point",attrs:n})},e.prototype.renderLine=function(t){var n=this.getShapeAttrs().line;this.addShape(t,{type:"path",id:this.getElementId("line"),name:"annotation-line",attrs:n})},e.prototype.renderText=function(t){var n=this.getShapeAttrs().text,i=n.x,a=n.y,o=n.text,s=(0,p._T)(n,["x","y","text"]),l=this.get("text"),u=l.background,c=l.maxLength,h=l.autoEllipsis,v=l.isVertival,d=l.ellipsisPosition,g={x:i,y:a,id:this.getElementId("text"),name:"annotation-text",content:o,style:s,background:u,maxLength:c,autoEllipsis:h,isVertival:v,ellipsisPosition:d};rs(t,g)},e.prototype.autoAdjust=function(t){var n=this.get("direction"),i=this.get("x"),a=this.get("y"),o=(0,f.U2)(this.get("line"),"length",0),s=this.get("coordinateBBox"),l=t.getBBox(),u=l.minX,c=l.maxX,h=l.minY,v=l.maxY,d=t.findById(this.getElementId("text-group")),g=t.findById(this.getElementId("text")),y=t.findById(this.getElementId("line"));if(!!s&&d){var x=d.attr("x"),m=d.attr("y"),M=g.getCanvasBBox(),w=M.width,S=M.height,b=0,k=0;if(i+u<=s.minX)if(n==="leftward")b=1;else{var H=s.minX-(i+u);x=d.attr("x")+H}else if(i+c>=s.maxX)if(n==="rightward")b=-1;else{var H=i+c-s.maxX;x=d.attr("x")-H}if(b&&(y&&y.attr("path",[["M",0,0],["L",o*b,0]]),x=(o+2+w)*b),a+h<=s.minY)if(n==="upward")k=1;else{var H=s.minY-(a+h);m=d.attr("y")+H}else if(a+v>=s.maxY)if(n==="downward")k=-1;else{var H=a+v-s.maxY;m=d.attr("y")-H}k&&(y&&y.attr("path",[["M",0,0],["L",0,o*k]]),m=(o+2+S)*k),(x!==d.attr("x")||m!==d.attr("y"))&&tu(d,x,m)}},e.prototype.getShapeAttrs=function(){var t=(0,f.U2)(this.get("line"),"display"),n=(0,f.U2)(this.get("point"),"style",{}),i=(0,f.U2)(this.get("line"),"style",{}),a=(0,f.U2)(this.get("text"),"style",{}),o=this.get("direction"),s=t?(0,f.U2)(this.get("line"),"length",0):0,l=0,u=0,c="top",h="start";switch(o){case"upward":u=-1,c="bottom";break;case"downward":u=1,c="top";break;case"leftward":l=-1,h="end";break;case"rightward":l=1,h="start";break}return{point:(0,p.pi)({x:0,y:0},n),line:(0,p.pi)({path:[["M",0,0],["L",s*l,s*u]]},i),text:(0,p.pi)({x:(s+2)*l,y:(s+2)*u,text:(0,f.U2)(this.get("text"),"content",""),textBaseline:c,textAlign:h},a)}},e}(Ar),rx=ex,nx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"dataRegion",locationType:"points",points:[],lineLength:0,region:{},text:{},defaultCfg:{region:{style:{lineWidth:0,fill:Ge.regionColor,opacity:.4}},text:{content:"",style:{textAlign:"center",textBaseline:"bottom",fontSize:12,fill:Ge.textColor,fontFamily:Ge.fontFamily}}}})},e.prototype.renderInner=function(t){var n=(0,f.U2)(this.get("region"),"style",{}),i=(0,f.U2)(this.get("text"),"style",{}),a=this.get("lineLength")||0,o=this.get("points");if(!!o.length){var s=Fm(o),l=[];l.push(["M",o[0].x,s.minY-a]),o.forEach(function(c){l.push(["L",c.x,c.y])}),l.push(["L",o[o.length-1].x,o[o.length-1].y-a]),this.addShape(t,{type:"path",id:this.getElementId("region"),name:"annotation-region",attrs:(0,p.pi)({path:l},n)});var u=(0,p.pi)({id:this.getElementId("text"),name:"annotation-text",x:(s.minX+s.maxX)/2,y:s.minY-a},this.get("text"));rs(t,u)}},e}(Ar),ix=nx,ax=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"regionFilter",locationType:"region",start:null,end:null,color:null,shape:[]})},e.prototype.renderInner=function(t){var n=this,i=this.get("start"),a=this.get("end"),o=this.addGroup(t,{id:this.getElementId("region-filter"),capture:!1});(0,f.S6)(this.get("shapes"),function(l,u){var c=l.get("type"),h=(0,f.d9)(l.attr());n.adjustShapeAttrs(h),n.addShape(o,{id:n.getElementId("shape-"+c+"-"+u),capture:!1,type:c,attrs:h})});var s=Ra({start:i,end:a});o.setClip({type:"rect",attrs:{x:s.minX,y:s.minY,width:s.width,height:s.height}})},e.prototype.adjustShapeAttrs=function(t){var n=this.get("color");t.fill&&(t.fill=t.fillStyle=n),t.stroke=t.strokeStyle=n},e}(Ar),ox=ax,sx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"shape",draw:f.ZT})},e.prototype.renderInner=function(t){var n=this.get("render");(0,f.mf)(n)&&n(t)},e}(Ar),lx=sx;function Rr(r,e,t){var n;try{n=window.getComputedStyle?window.getComputedStyle(r,null)[e]:r.style[e]}catch(i){}finally{n=n===void 0?t:n}return n}function ux(r,e){var t=Rr(r,"width",e);return t==="auto"&&(t=r.offsetWidth),parseFloat(t)}function cx(r,e){var t=ux(r,e),n=parseFloat(Rr(r,"borderLeftWidth"))||0,i=parseFloat(Rr(r,"paddingLeft"))||0,a=parseFloat(Rr(r,"paddingRight"))||0,o=parseFloat(Rr(r,"borderRightWidth"))||0,s=parseFloat(Rr(r,"marginRight"))||0,l=parseFloat(Rr(r,"marginLeft"))||0;return t+n+o+i+a+l+s}function fx(r,e){var t=Rr(r,"height",e);return t==="auto"&&(t=r.offsetHeight),parseFloat(t)}function hx(r,e){var t=fx(r,e),n=parseFloat(Rr(r,"borderTopWidth"))||0,i=parseFloat(Rr(r,"paddingTop"))||0,a=parseFloat(Rr(r,"paddingBottom"))||0,o=parseFloat(Rr(r,"borderBottomWidth"))||0,s=parseFloat(Rr(r,"marginTop"))||0,l=parseFloat(Rr(r,"marginBottom"))||0;return t+n+o+i+a+s+l}var vx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{container:null,containerTpl:"<div></div>",updateAutoRender:!0,containerClassName:"",parent:null})},e.prototype.getContainer=function(){return this.get("container")},e.prototype.show=function(){var t=this.get("container");t.style.display="",this.set("visible",!0)},e.prototype.hide=function(){var t=this.get("container");t.style.display="none",this.set("visible",!1)},e.prototype.setCapture=function(t){var n=this.getContainer(),i=t?"auto":"none";n.style.pointerEvents=i,this.set("capture",t)},e.prototype.getBBox=function(){var t=this.getContainer(),n=parseFloat(t.style.left)||0,i=parseFloat(t.style.top)||0;return Na(n,i,t.clientWidth,t.clientHeight)},e.prototype.clear=function(){var t=this.get("container");eu(t)},e.prototype.destroy=function(){this.removeEvent(),this.removeDom(),r.prototype.destroy.call(this)},e.prototype.init=function(){r.prototype.init.call(this),this.initContainer(),this.initDom(),this.resetStyles(),this.applyStyles(),this.initEvent(),this.initCapture(),this.initVisible()},e.prototype.initCapture=function(){this.setCapture(this.get("capture"))},e.prototype.initVisible=function(){this.get("visible")?this.show():this.hide()},e.prototype.initDom=function(){},e.prototype.initContainer=function(){var t=this.get("container");if((0,f.UM)(t)){t=this.createDom();var n=this.get("parent");(0,f.HD)(n)&&(n=document.getElementById(n),this.set("parent",n)),n.appendChild(t),this.get("containerId")&&t.setAttribute("id",this.get("containerId")),this.set("container",t)}else(0,f.HD)(t)&&(t=document.getElementById(t),this.set("container",t));this.get("parent")||this.set("parent",t.parentNode)},e.prototype.resetStyles=function(){var t=this.get("domStyles"),n=this.get("defaultStyles");t?t=(0,f.b$)({},n,t):t=n,this.set("domStyles",t)},e.prototype.applyStyles=function(){var t=this.get("domStyles");if(!!t){var n=this.getContainer();this.applyChildrenStyles(n,t);var i=this.get("containerClassName");if(i&&_m(n,i)){var a=t[i];G(n,a)}}},e.prototype.applyChildrenStyles=function(t,n){(0,f.S6)(n,function(i,a){var o=t.getElementsByClassName(a);(0,f.S6)(o,function(s){G(s,i)})})},e.prototype.applyStyle=function(t,n){var i=this.get("domStyles");G(n,i[t])},e.prototype.createDom=function(){var t=this.get("containerTpl");return V(t)},e.prototype.initEvent=function(){},e.prototype.removeDom=function(){var t=this.get("container");t&&t.parentNode&&t.parentNode.removeChild(t)},e.prototype.removeEvent=function(){},e.prototype.updateInner=function(t){(0,f.wH)(t,"domStyles")&&(this.resetStyles(),this.applyStyles()),this.resetPosition()},e.prototype.resetPosition=function(){},e}(Kf),iu=vx,dx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"annotation",type:"html",locationType:"point",x:0,y:0,containerTpl:'<div class="g2-html-annotation" style="position:absolute"></div>',alignX:"left",alignY:"top",html:"",zIndex:7})},e.prototype.render=function(){var t=this.getContainer(),n=this.get("html");eu(t);var i=(0,f.mf)(n)?n(t):n;if((0,f.kK)(i))t.appendChild(i);else if((0,f.HD)(i)||(0,f.hj)(i)){var a=V(""+i);a&&t.appendChild(a)}this.resetPosition()},e.prototype.resetPosition=function(){var t=this.getContainer(),n=this.getLocation(),i=n.x,a=n.y,o=this.get("alignX"),s=this.get("alignY"),l=this.get("offsetX"),u=this.get("offsetY"),c=cx(t),h=hx(t),v={x:i,y:a};o==="middle"?v.x-=Math.round(c/2):o==="right"&&(v.x-=Math.round(c)),s==="middle"?v.y-=Math.round(h/2):s==="bottom"&&(v.y-=Math.round(h)),l&&(v.x+=l),u&&(v.y+=u),G(t,{position:"absolute",left:v.x+"px",top:v.y+"px",zIndex:this.get("zIndex")})},e}(iu),px=dx;function za(r,e,t){var n=e+"Style",i=null;return(0,f.S6)(t,function(a,o){r[o]&&a[n]&&(i||(i={}),(0,f.CD)(i,a[n]))}),i}var gx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"axis",ticks:[],line:{},tickLine:{},subTickLine:null,title:null,label:{},verticalFactor:1,verticalLimitLength:null,overlapOrder:["autoRotate","autoEllipsis","autoHide"],tickStates:{},optimize:{},defaultCfg:{line:{style:{lineWidth:1,stroke:Ge.lineColor}},tickLine:{style:{lineWidth:1,stroke:Ge.lineColor},alignTick:!0,length:5,displayWithLabel:!0},subTickLine:{style:{lineWidth:1,stroke:Ge.lineColor},count:4,length:2},label:{autoRotate:!0,autoHide:!1,autoEllipsis:!1,style:{fontSize:12,fill:Ge.textColor,fontFamily:Ge.fontFamily,fontWeight:"normal"},offset:10,offsetX:0,offsetY:0},title:{autoRotate:!0,spacing:5,position:"center",style:{fontSize:12,fill:Ge.textColor,textBaseline:"middle",fontFamily:Ge.fontFamily,textAlign:"center"},iconStyle:{fill:Ge.descriptionIconFill,stroke:Ge.descriptionIconStroke},description:""},tickStates:{active:{labelStyle:{fontWeight:500},tickLineStyle:{lineWidth:2}},inactive:{labelStyle:{fill:Ge.uncheckedColor}}},optimize:{enable:!0,threshold:400}},theme:{}})},e.prototype.renderInner=function(t){this.get("line")&&this.drawLine(t),this.drawTicks(t),this.get("title")&&this.drawTitle(t)},e.prototype.isList=function(){return!0},e.prototype.getItems=function(){return this.get("ticks")},e.prototype.setItems=function(t){this.update({ticks:t})},e.prototype.updateItem=function(t,n){(0,f.CD)(t,n),this.clear(),this.render()},e.prototype.clearItems=function(){var t=this.getElementByLocalId("label-group");t&&t.clear()},e.prototype.setItemState=function(t,n,i){t[n]=i,this.updateTickStates(t)},e.prototype.hasState=function(t,n){return!!t[n]},e.prototype.getItemStates=function(t){var n=this.get("tickStates"),i=[];return(0,f.S6)(n,function(a,o){t[o]&&i.push(o)}),i},e.prototype.clearItemsState=function(t){var n=this,i=this.getItemsByState(t);(0,f.S6)(i,function(a){n.setItemState(a,t,!1)})},e.prototype.getItemsByState=function(t){var n=this,i=this.getItems();return(0,f.hX)(i,function(a){return n.hasState(a,t)})},e.prototype.getSidePoint=function(t,n){var i=this,a=i.getSideVector(n,t);return{x:t.x+a[0],y:t.y+a[1]}},e.prototype.getTextAnchor=function(t){var n;return(0,f.vQ)(t[0],0)?n="center":t[0]>0?n="start":t[0]<0&&(n="end"),n},e.prototype.getTextBaseline=function(t){var n;return(0,f.vQ)(t[1],0)?n="middle":t[1]>0?n="top":t[1]<0&&(n="bottom"),n},e.prototype.processOverlap=function(t){},e.prototype.drawLine=function(t){var n=this.getLinePath(),i=this.get("line");this.addShape(t,{type:"path",id:this.getElementId("line"),name:"axis-line",attrs:(0,f.CD)({path:n},i.style)})},e.prototype.getTickLineItems=function(t){var n=this,i=[],a=this.get("tickLine"),o=a.alignTick,s=a.length,l=1,u=t.length;return u>=2&&(l=t[1].value-t[0].value),(0,f.S6)(t,function(c){var h=c.point;o||(h=n.getTickPoint(c.value-l/2));var v=n.getSidePoint(h,s);i.push({startPoint:h,tickValue:c.value,endPoint:v,tickId:c.id,id:"tickline-"+c.id})}),i},e.prototype.getSubTickLineItems=function(t){var n=[],i=this.get("subTickLine"),a=i.count,o=t.length;if(o>=2)for(var s=0;s<o-1;s++)for(var l=t[s],u=t[s+1],c=0;c<a;c++){var h=(c+1)/(a+1),v=(1-h)*l.tickValue+h*u.tickValue,d=this.getTickPoint(v),g=this.getSidePoint(d,i.length);n.push({startPoint:d,endPoint:g,tickValue:v,id:"sub-"+l.id+"-"+c})}return n},e.prototype.getTickLineAttrs=function(t,n,i,a){var o=this.get(n).style,s={points:[t.startPoint,t.endPoint]},l=(0,f.U2)(this.get("theme"),["tickLine","style"],{});o=(0,f.mf)(o)?(0,f.CD)({},l,o(s,i,a)):o;var u=t.startPoint,c=t.endPoint;return(0,p.pi)({x1:u.x,y1:u.y,x2:c.x,y2:c.y},o)},e.prototype.drawTick=function(t,n,i,a,o){this.addShape(n,{type:"line",id:this.getElementId(t.id),name:"axis-"+i,attrs:this.getTickLineAttrs(t,i,a,o)})},e.prototype.drawTickLines=function(t){var n=this,i=this.get("ticks"),a=this.get("subTickLine"),o=this.getTickLineItems(i),s=this.addGroup(t,{name:"axis-tickline-group",id:this.getElementId("tickline-group")}),l=this.get("tickLine");if((0,f.S6)(o,function(c,h){if(l.displayWithLabel){var v=n.getElementId("label-"+c.tickId);t.findById(v)&&n.drawTick(c,s,"tickLine",h,o)}else n.drawTick(c,s,"tickLine",h,o)}),a){var u=this.getSubTickLineItems(o);(0,f.S6)(u,function(c,h){n.drawTick(c,s,"subTickLine",h,u)})}},e.prototype.processTicks=function(){var t=this,n=this.get("ticks");(0,f.S6)(n,function(i){i.point=t.getTickPoint(i.value),(0,f.UM)(i.id)&&(i.id=i.name)})},e.prototype.drawTicks=function(t){var n=this;this.optimizeTicks(),this.processTicks(),this.get("label")&&this.drawLabels(t),this.get("tickLine")&&this.drawTickLines(t);var i=this.get("ticks");(0,f.S6)(i,function(a){n.applyTickStates(a,t)})},e.prototype.optimizeTicks=function(){var t=this.get("optimize"),n=this.get("ticks");if(t&&t.enable&&t.threshold>0){var i=(0,f.dp)(n);if(i>t.threshold){var a=Math.ceil(i/t.threshold),o=n.filter(function(s,l){return l%a==0});this.set("ticks",o),this.set("originalTicks",n)}}},e.prototype.getLabelAttrs=function(t,n,i){var a=this.get("label"),o=a.offset,s=a.offsetX,l=a.offsetY,u=a.rotate,c=a.formatter,h=this.getSidePoint(t.point,o),v=this.getSideVector(o,h),d=c?c(t.name,t,n):t.name,g=a.style;g=(0,f.mf)(g)?(0,f.U2)(this.get("theme"),["label","style"],{}):g;var y=(0,f.CD)({x:h.x+s,y:h.y+l,text:d,textAlign:this.getTextAnchor(v),textBaseline:this.getTextBaseline(v)},g);return u&&(y.matrix=Si(h,u)),y},e.prototype.drawLabels=function(t){var n=this,i=this.get("ticks"),a=this.addGroup(t,{name:"axis-label-group",id:this.getElementId("label-group")});(0,f.S6)(i,function(v,d){n.addShape(a,{type:"text",name:"axis-label",id:n.getElementId("label-"+v.id),attrs:n.getLabelAttrs(v,d,i),delegateObject:{tick:v,item:v,index:d}})}),this.processOverlap(a);var o=a.getChildren(),s=(0,f.U2)(this.get("theme"),["label","style"],{}),l=this.get("label"),u=l.style,c=l.formatter;if((0,f.mf)(u)){var h=o.map(function(v){return(0,f.U2)(v.get("delegateObject"),"tick")});(0,f.S6)(o,function(v,d){var g=v.get("delegateObject").tick,y=c?c(g.name,g,d):g.name,x=(0,f.CD)({},s,u(y,d,h));v.attr(x)})}},e.prototype.getTitleAttrs=function(){var t=this.get("title"),n=t.style,i=t.position,a=t.offset,o=t.spacing,s=o===void 0?0:o,l=t.autoRotate,u=n.fontSize,c=.5;i==="start"?c=0:i==="end"&&(c=1);var h=this.getTickPoint(c),v=this.getSidePoint(h,a||s+u/2),d=(0,f.CD)({x:v.x,y:v.y,text:t.text},n),g=t.rotate,y=g;if((0,f.UM)(g)&&l){var x=this.getAxisVector(h),m=[1,0];y=nr.Dg(x,m,!0)}if(y){var M=Si(v,y);d.matrix=M}return d},e.prototype.drawTitle=function(t){var n,i=this.getTitleAttrs(),a=this.addShape(t,{type:"text",id:this.getElementId("title"),name:"axis-title",attrs:i});((n=this.get("title"))===null||n===void 0?void 0:n.description)&&this.drawDescriptionIcon(t,a,i.matrix)},e.prototype.drawDescriptionIcon=function(t,n,i){var a=this.addGroup(t,{name:"axis-description",id:this.getElementById("description")}),o=n.getBBox(),s=o.maxX,l=o.maxY,u=o.height,c=this.get("title").iconStyle,h=4,v=u/2,d=v/6,g=s+h,y=l-u/2,x=[g+v,y-v],m=x[0],M=x[1],w=[m+v,M+v],S=w[0],b=w[1],k=[m,b+v],H=k[0],at=k[1],At=[g,M+v],gt=At[0],Nt=At[1],te=[g+v,y-u/4],ce=te[0],Me=te[1],be=[ce,Me+d],Gt=be[0],ie=be[1],de=[Gt,ie+d],ue=de[0],pe=de[1],Ee=[ue,pe+v*3/4],Ne=Ee[0],Ye=Ee[1];this.addShape(a,{type:"path",id:this.getElementId("title-description-icon"),name:"axis-title-description-icon",attrs:(0,p.pi)({path:[["M",m,M],["A",v,v,0,0,1,S,b],["A",v,v,0,0,1,H,at],["A",v,v,0,0,1,gt,Nt],["A",v,v,0,0,1,m,M],["M",ce,Me],["L",Gt,ie],["M",ue,pe],["L",Ne,Ye]],lineWidth:d,matrix:i},c)}),this.addShape(a,{type:"rect",id:this.getElementId("title-description-rect"),name:"axis-title-description-rect",attrs:{x:g,y:y-u/2,width:u,height:u,stroke:"#000",fill:"#000",opacity:0,matrix:i,cursor:"pointer"}})},e.prototype.applyTickStates=function(t,n){var i=this.getItemStates(t);if(i.length){var a=this.get("tickStates"),o=this.getElementId("label-"+t.id),s=n.findById(o);if(s){var l=za(t,"label",a);l&&s.attr(l)}var u=this.getElementId("tickline-"+t.id),c=n.findById(u);if(c){var h=za(t,"tickLine",a);h&&c.attr(h)}}},e.prototype.updateTickStates=function(t){var n=this.getItemStates(t),i=this.get("tickStates"),a=this.get("label"),o=this.getElementByLocalId("label-"+t.id),s=this.get("tickLine"),l=this.getElementByLocalId("tickline-"+t.id);if(n.length){if(o){var u=za(t,"label",i);u&&o.attr(u)}if(l){var c=za(t,"tickLine",i);c&&l.attr(c)}}else o&&o.attr(a.style),l&&l.attr(s.style)},e}(Ar),jf=gx;function au(r,e,t,n){var i=e.getChildren(),a=!1;return(0,f.S6)(i,function(o){var s=Ua(r,o,t,n);a=a||s}),a}function yx(){return Jf}function mx(r,e,t){return au(r,e,t,"head")}function Jf(r,e,t){return au(r,e,t,"tail")}function xx(r,e,t){return au(r,e,t,"middle")}function Mx(r){var e=r.attr("matrix");return e&&e[0]!==1}function Qf(r){var e=Mx(r)?Tm(r.attr("matrix")):0;return e%360}function ou(r,e,t,n){var i=!1,a=Qf(e),o=Math.abs(r?t.attr("y")-e.attr("y"):t.attr("x")-e.attr("x")),s=(r?t.attr("y")>e.attr("y"):t.attr("x")>e.attr("x"))?e.getBBox():t.getBBox();if(r){var l=Math.abs(Math.cos(a));es(l,0,Math.PI/180)?i=s.width+n>o:i=s.height/l+n>o}else{var l=Math.abs(Math.sin(a));es(l,0,Math.PI/180)?i=s.width+n>o:i=s.height/l+n>o}return i}function Va(r,e,t,n){var i=(n==null?void 0:n.minGap)||0,a=e.getChildren().slice().filter(function(g){return g.get("visible")});if(!a.length)return!1;var o=!1;t&&a.reverse();for(var s=a.length,l=a[0],u=l,c=1;c<s;c++){var h=a[c],v=h.getBBox(),d=ou(r,u,h,i);d?(h.hide(),o=!0):u=h}return o}function th(r,e,t){var n=(t==null?void 0:t.minGap)||0,i=e.getChildren().slice();if(i.length<2)return!1;var a=!1,o=i[0],s=o.getBBox(),l=i[1],u=i.length,c=Qf(o),h=Math.abs(r?l.attr("y")-o.attr("y"):l.attr("x")-o.attr("x")),v=0;if(r){var d=Math.abs(Math.cos(c));if(es(d,0,Math.PI/180)){var g=nu(i);v=(g+n)/h}else v=(s.height/d+n)/h}else{var d=Math.abs(Math.sin(c));if(es(d,0,Math.PI/180)){var g=nu(i);v=(g+n)/h}else v=(s.height/d+n)/h}if(v>1){v=Math.ceil(v);for(var y=0;y<u;y++)y%v!=0&&(i[y].hide(),a=!0)}return a}function wx(){return eh}function Sx(r,e,t,n){return Va(r,e,!1,n)}function Cx(r,e,t,n){return Va(r,e,!0,n)}function Ax(r,e,t,n){var i=(n==null?void 0:n.minGap)||0,a=e.getChildren().slice();if(a.length<=2)return!1;for(var o=!1,s=a.length,l=a[0],u=a[s-1],c=l,h=1;h<s-1;h++){var v=a[h],d=v.getBBox(),g=ou(r,c,v,i);g?(v.hide(),o=!0):c=v}var y=ou(r,c,u,i);return y&&(c.hide(),o=!0),o}function eh(r,e,t,n){var i=th(r,e,n);return Va(r,e,!1)&&(i=!0),i}function bx(r,e,t,n){var i=e.getChildren().slice(),a=th(r,e,n);if(i.length>2){var o=i[0],s=i[i.length-1];o.get("visible")||(o.show(),Va(r,e,!1,n)&&(a=!0)),s.get("visible")||(s.show(),Va(r,e,!0,n)&&(a=!0))}return a}function Tx(r,e){(0,f.S6)(r,function(t){var n=t.attr("x"),i=t.attr("y"),a=Si({x:n,y:i},e);t.attr("matrix",a)})}function rh(r,e,t,n){var i=e.getChildren();if(!i.length||!r&&i.length<2)return!1;var a=nu(i),o=!1;if(r)o=!!t&&a>t;else{var s=Math.abs(i[1].attr("x")-i[0].attr("x"));o=a>s}if(o){var l=n(t,a);Tx(i,l)}return o}function Ex(){return nh}function nh(r,e,t,n){return rh(r,e,t,function(){return(0,f.hj)(n)?n:r?Ge.verticalAxisRotate:Ge.horizontalAxisRotate})}function _x(r,e,t){return rh(r,e,t,function(n,i){if(!n)return r?Ge.verticalAxisRotate:Ge.horizontalAxisRotate;if(r)return-Math.acos(n/i);var a=0;return n>i?a=Math.PI/4:(a=Math.asin(n/i),a>Math.PI/4&&(a=Math.PI/4)),a})}var Fx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{type:"line",locationType:"region",start:null,end:null})},e.prototype.getLinePath=function(){var t=this.get("start"),n=this.get("end"),i=[];return i.push(["M",t.x,t.y]),i.push(["L",n.x,n.y]),i},e.prototype.getInnerLayoutBBox=function(){var t=this.get("start"),n=this.get("end"),i=r.prototype.getInnerLayoutBBox.call(this),a=Math.min(t.x,n.x,i.x),o=Math.min(t.y,n.y,i.y),s=Math.max(t.x,n.x,i.maxX),l=Math.max(t.y,n.y,i.maxY);return{x:a,y:o,minX:a,minY:o,maxX:s,maxY:l,width:s-a,height:l-o}},e.prototype.isVertical=function(){var t=this.get("start"),n=this.get("end");return(0,f.vQ)(t.x,n.x)},e.prototype.isHorizontal=function(){var t=this.get("start"),n=this.get("end");return(0,f.vQ)(t.y,n.y)},e.prototype.getTickPoint=function(t){var n=this,i=n.get("start"),a=n.get("end"),o=a.x-i.x,s=a.y-i.y;return{x:i.x+o*t,y:i.y+s*t}},e.prototype.getSideVector=function(t){var n=this.getAxisVector(),i=xe.Fv([0,0],n),a=this.get("verticalFactor"),o=[i[1],i[0]*-1];return xe.bA([0,0],o,t*a)},e.prototype.getAxisVector=function(){var t=this.get("start"),n=this.get("end");return[n.x-t.x,n.y-t.y]},e.prototype.processOverlap=function(t){var n=this,i=this.isVertical(),a=this.isHorizontal();if(!(!i&&!a)){var o=this.get("label"),s=this.get("title"),l=this.get("verticalLimitLength"),u=o.offset,c=l,h=0,v=0;s&&(h=s.style.fontSize,v=s.spacing),c&&(c=c-u-v-h);var d=this.get("overlapOrder");if((0,f.S6)(d,function(x){o[x]&&n.canProcessOverlap(x)&&n.autoProcessOverlap(x,o[x],t,c)}),s&&(0,f.UM)(s.offset)){var g=t.getCanvasBBox(),y=i?g.width:g.height;s.offset=u+y+v+h/2}}},e.prototype.canProcessOverlap=function(t){var n=this.get("label");return t==="autoRotate"?(0,f.UM)(n.rotate):!0},e.prototype.autoProcessOverlap=function(t,n,i,a){var o=this,s=this.isVertical(),l=!1,u=yt[t];if(n===!0){var c=this.get("label");l=u.getDefault()(s,i,a)}else if((0,f.mf)(n))l=n(s,i,a);else if((0,f.Kn)(n)){var h=n;u[h.type]&&(l=u[h.type](s,i,a,h.cfg))}else u[n]&&(l=u[n](s,i,a));if(t==="autoRotate"){if(l){var v=i.getChildren(),d=this.get("verticalFactor");(0,f.S6)(v,function(y){var x=y.attr("textAlign");if(x==="center"){var m=d>0?"end":"start";y.attr("textAlign",m)}})}}else if(t==="autoHide"){var g=i.getChildren().slice(0);(0,f.S6)(g,function(y){y.get("visible")||(o.get("isRegister")&&o.unregisterElement(y),y.remove())})}},e}(jf),Ix=Fx,Px=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{type:"circle",locationType:"circle",center:null,radius:null,startAngle:-Math.PI/2,endAngle:Math.PI*3/2})},e.prototype.getLinePath=function(){var t=this.get("center"),n=t.x,i=t.y,a=this.get("radius"),o=a,s=this.get("startAngle"),l=this.get("endAngle"),u=[];if(Math.abs(l-s)===Math.PI*2)u=[["M",n,i-o],["A",a,o,0,1,1,n,i+o],["A",a,o,0,1,1,n,i-o],["Z"]];else{var c=this.getCirclePoint(s),h=this.getCirclePoint(l),v=Math.abs(l-s)>Math.PI?1:0,d=s>l?0:1;u=[["M",n,i],["L",c.x,c.y],["A",a,o,0,v,d,h.x,h.y],["L",n,i]]}return u},e.prototype.getTickPoint=function(t){var n=this.get("startAngle"),i=this.get("endAngle"),a=n+(i-n)*t;return this.getCirclePoint(a)},e.prototype.getSideVector=function(t,n){var i=this.get("center"),a=[n.x-i.x,n.y-i.y],o=this.get("verticalFactor"),s=xe.kE(a);return xe.bA(a,a,o*t/s),a},e.prototype.getAxisVector=function(t){var n=this.get("center"),i=[t.x-n.x,t.y-n.y];return[i[1],-1*i[0]]},e.prototype.getCirclePoint=function(t,n){var i=this.get("center");return n=n||this.get("radius"),{x:i.x+Math.cos(t)*n,y:i.y+Math.sin(t)*n}},e.prototype.canProcessOverlap=function(t){var n=this.get("label");return t==="autoRotate"?(0,f.UM)(n.rotate):!0},e.prototype.processOverlap=function(t){var n=this,i=this.get("label"),a=this.get("title"),o=this.get("verticalLimitLength"),s=i.offset,l=o,u=0,c=0;a&&(u=a.style.fontSize,c=a.spacing),l&&(l=l-s-c-u);var h=this.get("overlapOrder");if((0,f.S6)(h,function(d){i[d]&&n.canProcessOverlap(d)&&n.autoProcessOverlap(d,i[d],t,l)}),a&&(0,f.UM)(a.offset)){var v=t.getCanvasBBox().height;a.offset=s+v+c+u/2}},e.prototype.autoProcessOverlap=function(t,n,i,a){var o=this,s=!1,l=yt[t];if(a>0)if(n===!0)s=l.getDefault()(!1,i,a);else if((0,f.mf)(n))s=n(!1,i,a);else if((0,f.Kn)(n)){var u=n;l[u.type]&&(s=l[u.type](!1,i,a,u.cfg))}else l[n]&&(s=l[n](!1,i,a));if(t==="autoRotate"){if(s){var c=i.getChildren(),h=this.get("verticalFactor");(0,f.S6)(c,function(d){var g=d.attr("textAlign");if(g==="center"){var y=h>0?"end":"start";d.attr("textAlign",y)}})}}else if(t==="autoHide"){var v=i.getChildren().slice(0);(0,f.S6)(v,function(d){d.get("visible")||(o.get("isRegister")&&o.unregisterElement(d),d.remove())})}},e}(jf),Lx=Px,Dx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"crosshair",type:"base",line:{},text:null,textBackground:{},capture:!1,defaultCfg:{line:{style:{lineWidth:1,stroke:Ge.lineColor}},text:{position:"start",offset:10,autoRotate:!1,content:null,style:{fill:Ge.textColor,textAlign:"center",textBaseline:"middle",fontFamily:Ge.fontFamily}},textBackground:{padding:5,style:{stroke:Ge.lineColor}}}})},e.prototype.renderInner=function(t){this.get("line")&&this.renderLine(t),this.get("text")&&(this.renderText(t),this.renderBackground(t))},e.prototype.renderText=function(t){var n=this.get("text"),i=n.style,a=n.autoRotate,o=n.content;if(!(0,f.UM)(o)){var s=this.getTextPoint(),l=null;if(a){var u=this.getRotateAngle();l=Si(s,u)}this.addShape(t,{type:"text",name:"crosshair-text",id:this.getElementId("text"),attrs:(0,p.pi)((0,p.pi)((0,p.pi)({},s),{text:o,matrix:l}),i)})}},e.prototype.renderLine=function(t){var n=this.getLinePath(),i=this.get("line"),a=i.style;this.addShape(t,{type:"path",name:"crosshair-line",id:this.getElementId("line"),attrs:(0,p.pi)({path:n},a)})},e.prototype.renderBackground=function(t){var n=this.getElementId("text"),i=t.findById(n),a=this.get("textBackground");if(a&&i){var o=i.getBBox(),s=ts(a.padding),l=a.style,u=this.addShape(t,{type:"rect",name:"crosshair-text-background",id:this.getElementId("text-background"),attrs:(0,p.pi)({x:o.x-s[3],y:o.y-s[0],width:o.width+s[1]+s[3],height:o.height+s[0]+s[2],matrix:i.attr("matrix")},l)});u.toBack()}},e}(Ar),su=Dx,Ox=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{type:"line",locationType:"region",start:null,end:null})},e.prototype.getRotateAngle=function(){var t=this.getLocation(),n=t.start,i=t.end,a=this.get("text").position,o=Math.atan2(i.y-n.y,i.x-n.x),s=a==="start"?o-Math.PI/2:o+Math.PI/2;return s},e.prototype.getTextPoint=function(){var t=this.getLocation(),n=t.start,i=t.end,a=this.get("text"),o=a.position,s=a.offset;return qf(n,i,o,s)},e.prototype.getLinePath=function(){var t=this.getLocation(),n=t.start,i=t.end;return[["M",n.x,n.y],["L",i.x,i.y]]},e}(su),ih=Ox,kx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{type:"circle",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:Math.PI*3/2})},e.prototype.getRotateAngle=function(){var t=this.getLocation(),n=t.startAngle,i=t.endAngle,a=this.get("text").position,o=a==="start"?n+Math.PI/2:i-Math.PI/2;return o},e.prototype.getTextPoint=function(){var t=this.get("text"),n=t.position,i=t.offset,a=this.getLocation(),o=a.center,s=a.radius,l=a.startAngle,u=a.endAngle,c=n==="start"?l:u,h=this.getRotateAngle()-Math.PI,v=ea(o,s,c),d=Math.cos(h)*i,g=Math.sin(h)*i;return{x:v.x+d,y:v.y+g}},e.prototype.getLinePath=function(){var t=this.getLocation(),n=t.center,i=t.radius,a=t.startAngle,o=t.endAngle,s=null;if(o-a==Math.PI*2){var l=n.x,u=n.y;s=[["M",l,u-i],["A",i,i,0,1,1,l,u+i],["A",i,i,0,1,1,l,u-i],["Z"]]}else{var c=ea(n,i,a),h=ea(n,i,o),v=Math.abs(o-a)>Math.PI?1:0,d=a>o?0:1;s=[["M",c.x,c.y],["A",i,i,0,v,d,h.x,h.y]]}return s},e}(su),Bx=kx,Ha="g2-crosshair",lu=Ha+"-line",uu=Ha+"-text",Ga,Rx=(Ga={},Ga[""+Ha]={position:"relative"},Ga[""+lu]={position:"absolute",backgroundColor:"rgba(0, 0, 0, 0.25)"},Ga[""+uu]={position:"absolute",color:Ge.textColor,fontFamily:Ge.fontFamily},Ga),Nx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"crosshair",type:"html",locationType:"region",start:{x:0,y:0},end:{x:0,y:0},capture:!1,text:null,containerTpl:'<div class="'+Ha+'"></div>',crosshairTpl:'<div class="'+lu+'"></div>',textTpl:'<span class="'+uu+'">{content}</span>',domStyles:null,containerClassName:Ha,defaultStyles:Rx,defaultCfg:{text:{position:"start",content:null,align:"center",offset:10}}})},e.prototype.render=function(){this.resetText(),this.resetPosition()},e.prototype.initCrossHair=function(){var t=this.getContainer(),n=this.get("crosshairTpl"),i=V(n);t.appendChild(i),this.applyStyle(lu,i),this.set("crosshairEl",i)},e.prototype.getTextPoint=function(){var t=this.getLocation(),n=t.start,i=t.end,a=this.get("text"),o=a.position,s=a.offset;return qf(n,i,o,s)},e.prototype.resetText=function(){var t=this.get("text"),n=this.get("textEl");if(t){var i=t.content;if(!n){var a=this.getContainer(),o=(0,f.ng)(this.get("textTpl"),t);n=V(o),a.appendChild(n),this.applyStyle(uu,n),this.set("textEl",n)}n.innerHTML=i}else n&&n.remove()},e.prototype.isVertical=function(t,n){return t.x===n.x},e.prototype.resetPosition=function(){var t=this.get("crosshairEl");t||(this.initCrossHair(),t=this.get("crosshairEl"));var n=this.get("start"),i=this.get("end"),a=Math.min(n.x,i.x),o=Math.min(n.y,i.y);this.isVertical(n,i)?G(t,{width:"1px",height:Br(Math.abs(i.y-n.y))}):G(t,{height:"1px",width:Br(Math.abs(i.x-n.x))}),G(t,{top:Br(o),left:Br(a)}),this.alignText()},e.prototype.alignText=function(){var t=this.get("textEl");if(t){var n=this.get("text").align,i=t.clientWidth,a=this.getTextPoint();switch(n){case"center":a.x=a.x-i/2;break;case"right":a.x=a.x-i;case"left":break}G(t,{top:Br(a.y),left:Br(a.x)})}},e.prototype.updateInner=function(t){(0,f.wH)(t,"text")&&this.resetText(),r.prototype.updateInner.call(this,t)},e}(iu),Ux=Nx,zx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"grid",line:{},alternateColor:null,capture:!1,items:[],closed:!1,defaultCfg:{line:{type:"line",style:{lineWidth:1,stroke:Ge.lineColor}}}})},e.prototype.getLineType=function(){var t=this.get("line")||this.get("defaultCfg").line;return t.type},e.prototype.renderInner=function(t){this.drawGrid(t)},e.prototype.getAlternatePath=function(t,n){var i=this.getGridPath(t),a=n.slice(0).reverse(),o=this.getGridPath(a,!0),s=this.get("closed");return s?i=i.concat(o):(o[0][0]="L",i=i.concat(o),i.push(["Z"])),i},e.prototype.getPathStyle=function(){return this.get("line").style},e.prototype.drawGrid=function(t){var n=this,i=this.get("line"),a=this.get("items"),o=this.get("alternateColor"),s=null;(0,f.S6)(a,function(l,u){var c=l.id||u;if(i){var h=n.getPathStyle();h=(0,f.mf)(h)?h(l,u,a):h;var v=n.getElementId("line-"+c),d=n.getGridPath(l.points);n.addShape(t,{type:"path",name:"grid-line",id:v,attrs:(0,f.CD)({path:d},h)})}if(o&&u>0){var g=n.getElementId("region-"+c),y=u%2==0;if((0,f.HD)(o))y&&n.drawAlternateRegion(g,t,s.points,l.points,o);else{var x=y?o[1]:o[0];n.drawAlternateRegion(g,t,s.points,l.points,x)}}s=l})},e.prototype.drawAlternateRegion=function(t,n,i,a,o){var s=this.getAlternatePath(i,a);this.addShape(n,{type:"path",id:t,name:"grid-region",attrs:{path:s,fill:o}})},e}(Ar),ah=zx;function Vx(r,e,t,n){var i=t-r,a=n-e;return Math.sqrt(i*i+a*a)}var Hx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{type:"circle",center:null,closed:!0})},e.prototype.getGridPath=function(t,n){var i=this.getLineType(),a=this.get("closed"),o=[];if(t.length)if(i==="circle"){var s=this.get("center"),l=t[0],u=Vx(s.x,s.y,l.x,l.y),c=n?0:1;a?(o.push(["M",s.x,s.y-u]),o.push(["A",u,u,0,0,c,s.x,s.y+u]),o.push(["A",u,u,0,0,c,s.x,s.y-u]),o.push(["Z"])):(0,f.S6)(t,function(h,v){v===0?o.push(["M",h.x,h.y]):o.push(["A",u,u,0,0,c,h.x,h.y])})}else(0,f.S6)(t,function(h,v){v===0?o.push(["M",h.x,h.y]):o.push(["L",h.x,h.y])}),a&&o.push(["Z"]);return o},e}(ah),Gx=Hx,Yx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{type:"line"})},e.prototype.getGridPath=function(t){var n=[];return(0,f.S6)(t,function(i,a){a===0?n.push(["M",i.x,i.y]):n.push(["L",i.x,i.y])}),n},e}(ah),Xx=Yx,Wx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"legend",layout:"horizontal",locationType:"point",x:0,y:0,offsetX:0,offsetY:0,title:null,background:null})},e.prototype.getLayoutBBox=function(){var t=r.prototype.getLayoutBBox.call(this),n=this.get("maxWidth"),i=this.get("maxHeight"),a=t.width,o=t.height;return n&&(a=Math.min(a,n)),i&&(o=Math.min(o,i)),Na(t.minX,t.minY,a,o)},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},e.prototype.resetLocation=function(){var t=this.get("x"),n=this.get("y"),i=this.get("offsetX"),a=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t+i,y:n+a})},e.prototype.applyOffset=function(){this.resetLocation()},e.prototype.getDrawPoint=function(){return this.get("currentPoint")},e.prototype.setDrawPoint=function(t){return this.set("currentPoint",t)},e.prototype.renderInner=function(t){this.resetDraw(),this.get("title")&&this.drawTitle(t),this.drawLegendContent(t),this.get("background")&&this.drawBackground(t)},e.prototype.drawBackground=function(t){var n=this.get("background"),i=t.getBBox(),a=ts(n.padding),o=(0,p.pi)({x:0,y:0,width:i.width+a[1]+a[3],height:i.height+a[0]+a[2]},n.style),s=this.addShape(t,{type:"rect",id:this.getElementId("background"),name:"legend-background",attrs:o});s.toBack()},e.prototype.drawTitle=function(t){var n=this.get("currentPoint"),i=this.get("title"),a=i.spacing,o=i.style,s=i.text,l=this.addShape(t,{type:"text",id:this.getElementId("title"),name:"legend-title",attrs:(0,p.pi)({text:s,x:n.x,y:n.y},o)}),u=l.getBBox();this.set("currentPoint",{x:n.x,y:u.maxY+a})},e.prototype.resetDraw=function(){var t=this.get("background"),n={x:0,y:0};if(t){var i=ts(t.padding);n.x=i[3],n.y=i[0]}this.set("currentPoint",n)},e}(Ar),oh=Wx,cu={marker:{style:{inactiveFill:"#000",inactiveOpacity:.45,fill:"#000",opacity:1,size:12}},text:{style:{fill:"#ccc",fontSize:12}}},ns={fill:Ge.textColor,fontSize:12,textAlign:"start",textBaseline:"middle",fontFamily:Ge.fontFamily,fontWeight:"normal",lineHeight:12},fu="navigation-arrow-right",hu="navigation-arrow-left",sh={right:90*Math.PI/180,left:(360-90)*Math.PI/180,up:0,down:180*Math.PI/180},Zx=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.currentPageIndex=1,t.totalPagesCnt=1,t.pageWidth=0,t.pageHeight=0,t.startX=0,t.startY=0,t.onNavigationBack=function(){var n=t.getElementByLocalId("item-group");if(t.currentPageIndex>1){t.currentPageIndex-=1,t.updateNavigation();var i=t.getCurrentNavigationMatrix();t.get("animate")?n.animate({matrix:i},100):n.attr({matrix:i})}},t.onNavigationAfter=function(){var n=t.getElementByLocalId("item-group");if(t.currentPageIndex<t.totalPagesCnt){t.currentPageIndex+=1,t.updateNavigation();var i=t.getCurrentNavigationMatrix();t.get("animate")?n.animate({matrix:i},100):n.attr({matrix:i})}},t}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"legend",type:"category",itemSpacing:24,itemMarginBottom:8,maxItemWidth:null,itemWidth:null,itemHeight:null,itemName:{},itemValue:null,maxWidth:null,maxHeight:null,marker:{},radio:null,items:[],itemStates:{},itemBackground:{},pageNavigator:{},defaultCfg:{title:{spacing:5,style:{fill:Ge.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}},background:{padding:5,style:{stroke:Ge.lineColor}},itemBackground:{style:{opacity:0,fill:"#fff"}},pageNavigator:cu,itemName:{spacing:16,style:ns},marker:{spacing:8,style:{r:6,symbol:"circle"}},itemValue:{alignRight:!1,formatter:null,style:ns,spacing:6},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:Ge.uncheckedColor},markerStyle:{fill:Ge.uncheckedColor,stroke:Ge.uncheckedColor}},inactive:{nameStyle:{fill:Ge.uncheckedColor},markerStyle:{opacity:.2}}}}})},e.prototype.isList=function(){return!0},e.prototype.getItems=function(){return this.get("items")},e.prototype.setItems=function(t){this.update({items:t})},e.prototype.updateItem=function(t,n){(0,f.CD)(t,n),this.clear(),this.render()},e.prototype.clearItems=function(){var t=this.getElementByLocalId("item-group");t&&t.clear()},e.prototype.setItemState=function(t,n,i){t[n]=i;var a=this.getElementByLocalId("item-"+t.id);if(a){var o=this.getItems(),s=o.indexOf(t),l=this.createOffScreenGroup(),u=this.drawItem(t,s,this.getItemHeight(),l);this.updateElements(u,a),this.clearUpdateStatus(a)}},e.prototype.hasState=function(t,n){return!!t[n]},e.prototype.getItemStates=function(t){var n=this.get("itemStates"),i=[];return(0,f.S6)(n,function(a,o){t[o]&&i.push(o)}),i},e.prototype.clearItemsState=function(t){var n=this,i=this.getItemsByState(t);(0,f.S6)(i,function(a){n.setItemState(a,t,!1)})},e.prototype.getItemsByState=function(t){var n=this,i=this.getItems();return(0,f.hX)(i,function(a){return n.hasState(a,t)})},e.prototype.drawLegendContent=function(t){this.processItems(),this.drawItems(t)},e.prototype.processItems=function(){var t=this.get("items");(0,f.S6)(t,function(n){n.id||(n.id=n.name)})},e.prototype.drawItems=function(t){var n=this,i=this.addGroup(t,{id:this.getElementId("item-container-group"),name:"legend-item-container-group"}),a=this.addGroup(i,{id:this.getElementId("item-group"),name:"legend-item-group"}),o=this.getItemHeight(),s=this.get("itemWidth"),l=this.get("itemSpacing"),u=this.get("itemMarginBottom"),c=this.get("currentPoint"),h=c.x,v=c.y,d=this.get("layout"),g=this.get("items"),y=!1,x=0,m=this.get("maxWidth"),M=this.get("maxHeight");(0,f.S6)(g,function(w,S){var b=n.drawItem(w,S,o,a),k=b.getBBox(),H=s||k.width;H>x&&(x=H),d==="horizontal"?(m&&m<c.x+H-h&&(y=!0,c.x=h,c.y+=o+u),n.moveElementTo(b,c),c.x+=H+l):(M&&M<c.y+o+u-v&&(y=!0,c.x+=x+l,c.y=v,x=0),n.moveElementTo(b,c),c.y+=o+u)}),y&&this.get("flipPage")&&(this.pageHeight=0,this.pageWidth=0,this.totalPagesCnt=1,this.startX=h,this.startY=v,this.adjustNavigation(t,a))},e.prototype.getItemHeight=function(){var t=this.get("itemHeight");if(!t){var n=(this.get("itemName")||{}).style;if((0,f.mf)(n)){var i=this.getItems();i.forEach(function(a,o){var s=(0,p.pi)((0,p.pi)({},ns),n(a,o,i)).fontSize;t<s&&(t=s)})}else n&&(t=n.fontSize)}return t},e.prototype.drawMarker=function(t,n,i,a){var o=(0,p.pi)((0,p.pi)((0,p.pi)({x:0,y:a/2},n.style),{symbol:(0,f.U2)(i.marker,"symbol","circle")}),(0,f.U2)(i.marker,"style",{})),s=this.addShape(t,{type:"marker",id:this.getElementId("item-"+i.id+"-marker"),name:"legend-item-marker",attrs:o}),l=s.getBBox();s.attr("x",l.width/2);var u=s.attr(),c=u.stroke,h=u.fill;return c&&s.set("isStroke",!0),h&&s.set("isFill",!0),s},e.prototype.drawItemText=function(t,n,i,a,o,s,l){var u=i.formatter,c=i.style,h=(0,p.pi)((0,p.pi)({x:s,y:o/2,text:u?u(a[n],a,l):a[n]},ns),(0,f.mf)(c)?c(a,l,this.getItems()):c);return this.addShape(t,{type:"text",id:this.getElementId("item-"+a.id+"-"+n),name:"legend-item-"+n,attrs:h})},e.prototype.drawRadio=function(t,n,i,a,o){var s,l,u=n.style||{},c=(s=u.r)!==null&&s!==void 0?s:a/2,h=c*3.6/8,v=[o+c,a/2-c],d=v[0],g=v[1],y=[d+c,g+c],x=y[0],m=y[1],M=[d,m+c],w=M[0],S=M[1],b=[o,g+c],k=b[0],H=b[1],at=i.showRadio,At=(0,p.pi)((0,p.pi)({path:[["M",d,g],["A",c,c,0,0,1,x,m],["L",x-h,m],["L",x,m],["A",c,c,0,0,1,w,S],["L",w,S-h],["L",w,S],["A",c,c,0,0,1,k,H],["L",k+h,H],["L",k,H],["A",c,c,0,0,1,d,g],["L",d,g+h]],stroke:"#000000",fill:"#ffffff"},u),{opacity:at?(l=u==null?void 0:u.opacity)!==null&&l!==void 0?l:.45:0}),gt=this.addShape(t,{type:"path",id:this.getElementId("item-"+i.id+"-radio"),name:"legend-item-radio",attrs:At});return gt.set("tip",n.tip),gt},e.prototype.drawItem=function(t,n,i,a){var o="item-"+t.id,s=this.addGroup(a,{name:"legend-item-container",id:this.getElementId("item-container-"+o),delegateObject:{item:t,index:n}}),l=this.addGroup(s,{name:"legend-item",id:this.getElementId(o),delegateObject:{item:t,index:n}}),u=this.get("marker"),c=this.get("itemName"),h=this.get("itemValue"),v=this.get("itemBackground"),d=this.get("radio"),g=this.getLimitItemWidth(),y=0;if(u){var x=this.drawMarker(l,u,t,i),m=u.spacing,M=(0,f.U2)(t,["marker","spacing"]);(0,f.hj)(M)&&(m=M),y=x.getBBox().maxX+m}if(c){var w=this.drawItemText(l,"name",c,t,i,y,n);g&&Ua(!0,w,(0,f.uZ)(g-y,0,g)),y=w.getBBox().maxX+c.spacing}if(h){var S=this.drawItemText(l,"value",h,t,i,y,n);g&&(h.alignRight?(S.attr({textAlign:"right",x:g}),Ua(!0,S,(0,f.uZ)(g-y,0,g),"head")):Ua(!0,S,(0,f.uZ)(g-y,0,g))),y=S.getBBox().maxX+h.spacing}if(d&&this.drawRadio(l,d,t,i,y),v){var b=l.getBBox(),k=this.addShape(l,{type:"rect",name:"legend-item-background",id:this.getElementId(o+"-background"),attrs:(0,p.pi)({x:0,y:0,width:b.width,height:i},v.style)});k.toBack()}return this.applyItemStates(t,l),l},e.prototype.adjustNavigation=function(t,n){var i=this,a=this.startX,o=this.startY,s=this.get("layout"),l=n.findAll(function(te){return te.get("name")==="legend-item"}),u=this.get("maxWidth"),c=this.get("maxHeight"),h=this.get("itemWidth"),v=this.get("itemSpacing"),d=this.getItemHeight(),g=(0,f.b$)({},cu,this.get("pageNavigator")),y=this.drawNavigation(t,s,"00/00",g),x=y.getBBox(),m={x:a,y:o},M=1,w=0,S=0,b=0,k=this.get("itemMarginBottom");function H(te,ce){var Me=te.getBBox(),be=h||Me.width,Gt=ce.x+be+v+x.width;return Gt>u}if(s==="horizontal"){var at=this.get("maxRow")||1,At=d+(at===1?0:k),gt=u-v-x.width-x.minX;this.pageHeight=At*at,this.pageWidth=gt,(0,f.S6)(l,function(te){var ce=te.getBBox(),Me=h||ce.width;(w&&w<m.x+Me+v||H(te,m))&&(M===1&&(w=m.x+v,i.moveElementTo(y,{x:gt,y:m.y+d/2-x.height/2-x.minY})),M+=1,m.x=a,m.y+=At),i.moveElementTo(te,m),te.getParent().setClip({type:"rect",attrs:{x:m.x,y:m.y,width:Me+v,height:d}}),m.x+=Me+v})}else{(0,f.S6)(l,function(te){var ce=te.getBBox();ce.width>S&&(S=ce.width)}),b=S,S+=v,u&&(S=Math.min(u,S),b=Math.min(u,b)),this.pageWidth=S,this.pageHeight=c-Math.max(x.height,d+k);var Nt=Math.floor(this.pageHeight/(d+k));(0,f.S6)(l,function(te,ce){ce!==0&&ce%Nt==0&&(M+=1,m.x+=S,m.y=o),i.moveElementTo(te,m),te.getParent().setClip({type:"rect",attrs:{x:m.x,y:m.y,width:S,height:d}}),m.y+=d+k}),this.totalPagesCnt=M,this.moveElementTo(y,{x:a+b/2-x.width/2-x.minX,y:c-x.height-x.minY})}this.pageHeight&&this.pageWidth&&n.getParent().setClip({type:"rect",attrs:{x:this.startX,y:this.startY,width:this.pageWidth,height:this.pageHeight}}),s==="horizontal"&&this.get("maxRow")?this.totalPagesCnt=Math.ceil(M/this.get("maxRow")):this.totalPagesCnt=M,this.currentPageIndex>this.totalPagesCnt&&(this.currentPageIndex=1),this.updateNavigation(y),n.attr("matrix",this.getCurrentNavigationMatrix())},e.prototype.drawNavigation=function(t,n,i,a){var o={x:0,y:0},s=this.addGroup(t,{id:this.getElementId("navigation-group"),name:"legend-navigation"}),l=(0,f.U2)(a.marker,"style",{}),u=l.size,c=u===void 0?12:u,h=(0,p._T)(l,["size"]),v=this.drawArrow(s,o,hu,n==="horizontal"?"up":"left",c,h);v.on("click",this.onNavigationBack);var d=v.getBBox();o.x+=d.width+2;var g=this.addShape(s,{type:"text",id:this.getElementId("navigation-text"),name:"navigation-text",attrs:(0,p.pi)({x:o.x,y:o.y+c/2,text:i,textBaseline:"middle"},(0,f.U2)(a.text,"style"))}),y=g.getBBox();o.x+=y.width+2;var x=this.drawArrow(s,o,fu,n==="horizontal"?"down":"right",c,h);return x.on("click",this.onNavigationAfter),s},e.prototype.updateNavigation=function(t){var n=(0,f.b$)({},cu,this.get("pageNavigator")),i=n.marker.style,a=i.fill,o=i.opacity,s=i.inactiveFill,l=i.inactiveOpacity,u=this.currentPageIndex+"/"+this.totalPagesCnt,c=t?t.getChildren()[1]:this.getElementByLocalId("navigation-text"),h=t?t.findById(this.getElementId(hu)):this.getElementByLocalId(hu),v=t?t.findById(this.getElementId(fu)):this.getElementByLocalId(fu);c.attr("text",u),h.attr("opacity",this.currentPageIndex===1?l:o),h.attr("fill",this.currentPageIndex===1?s:a),h.attr("cursor",this.currentPageIndex===1?"not-allowed":"pointer"),v.attr("opacity",this.currentPageIndex===this.totalPagesCnt?l:o),v.attr("fill",this.currentPageIndex===this.totalPagesCnt?s:a),v.attr("cursor",this.currentPageIndex===this.totalPagesCnt?"not-allowed":"pointer");var d=h.getBBox().maxX+2;c.attr("x",d),d+=c.getBBox().width+2,this.updateArrowPath(v,{x:d,y:0})},e.prototype.drawArrow=function(t,n,i,a,o,s){var l=n.x,u=n.y,c=this.addShape(t,{type:"path",id:this.getElementId(i),name:i,attrs:(0,p.pi)({size:o,direction:a,path:[["M",l+o/2,u],["L",l,u+o],["L",l+o,u+o],["Z"]],cursor:"pointer"},s)});return c.attr("matrix",Si({x:l+o/2,y:u+o/2},sh[a])),c},e.prototype.updateArrowPath=function(t,n){var i=n.x,a=n.y,o=t.attr(),s=o.size,l=o.direction,u=Si({x:i+s/2,y:a+s/2},sh[l]);t.attr("path",[["M",i+s/2,a],["L",i,a+s],["L",i+s,a+s],["Z"]]),t.attr("matrix",u)},e.prototype.getCurrentNavigationMatrix=function(){var t=this,n=t.currentPageIndex,i=t.pageWidth,a=t.pageHeight,o=this.get("layout"),s=o==="horizontal"?{x:0,y:a*(1-n)}:{x:i*(1-n),y:0};return Ql(s)},e.prototype.applyItemStates=function(t,n){var i=this.getItemStates(t),a=i.length>0;if(a){var o=n.getChildren(),s=this.get("itemStates");(0,f.S6)(o,function(l){var u=l.get("name"),c=u.split("-")[2],h=za(t,c,s);h&&(l.attr(h),c==="marker"&&!(l.get("isStroke")&&l.get("isFill"))&&(l.get("isStroke")&&l.attr("fill",null),l.get("isFill")&&l.attr("stroke",null)))})}},e.prototype.getLimitItemWidth=function(){var t=this.get("itemWidth"),n=this.get("maxItemWidth");return n?t&&(n=t<=n?t:n):t&&(n=t),n},e}(oh),$x=Zx,qx=1.4,lh=.4,Kx=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{type:"continue",min:0,max:100,value:null,colors:[],track:{},rail:{},label:{},handler:{},slidable:!0,tip:null,step:null,maxWidth:null,maxHeight:null,defaultCfg:{label:{align:"rail",spacing:5,formatter:null,style:{fontSize:12,fill:Ge.textColor,textBaseline:"middle",fontFamily:Ge.fontFamily}},handler:{size:10,style:{fill:"#fff",stroke:"#333"}},track:{},rail:{type:"color",size:20,defaultLength:100,style:{fill:"#DCDEE2"}},title:{spacing:5,style:{fill:Ge.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}}}})},e.prototype.isSlider=function(){return!0},e.prototype.getValue=function(){return this.getCurrentValue()},e.prototype.getRange=function(){return{min:this.get("min"),max:this.get("max")}},e.prototype.setRange=function(t,n){this.update({min:t,max:n})},e.prototype.setValue=function(t){var n=this.getValue();this.set("value",t);var i=this.get("group");this.resetTrackClip(),this.get("slidable")&&this.resetHandlers(i),this.delegateEmit("valuechanged",{originValue:n,value:t})},e.prototype.initEvent=function(){var t=this.get("group");this.bindSliderEvent(t),this.bindRailEvent(t),this.bindTrackEvent(t)},e.prototype.drawLegendContent=function(t){this.drawRail(t),this.drawLabels(t),this.fixedElements(t),this.resetTrack(t),this.resetTrackClip(t),this.get("slidable")&&this.resetHandlers(t)},e.prototype.bindSliderEvent=function(t){this.bindHandlersEvent(t)},e.prototype.bindHandlersEvent=function(t){var n=this;t.on("legend-handler-min:drag",function(i){var a=n.getValueByCanvasPoint(i.x,i.y),o=n.getCurrentValue(),s=o[1];s<a&&(s=a),n.setValue([a,s])}),t.on("legend-handler-max:drag",function(i){var a=n.getValueByCanvasPoint(i.x,i.y),o=n.getCurrentValue(),s=o[0];s>a&&(s=a),n.setValue([s,a])})},e.prototype.bindRailEvent=function(t){},e.prototype.bindTrackEvent=function(t){var n=this,i=null;t.on("legend-track:dragstart",function(a){i={x:a.x,y:a.y}}),t.on("legend-track:drag",function(a){if(!!i){var o=n.getValueByCanvasPoint(i.x,i.y),s=n.getValueByCanvasPoint(a.x,a.y),l=n.getCurrentValue(),u=l[1]-l[0],c=n.getRange(),h=s-o;h<0?l[0]+h>c.min?n.setValue([l[0]+h,l[1]+h]):n.setValue([c.min,c.min+u]):h>0&&(h>0&&l[1]+h<c.max?n.setValue([l[0]+h,l[1]+h]):n.setValue([c.max-u,c.max])),i={x:a.x,y:a.y}}}),t.on("legend-track:dragend",function(a){i=null})},e.prototype.drawLabels=function(t){this.drawLabel("min",t),this.drawLabel("max",t)},e.prototype.drawLabel=function(t,n){var i=this.get("label"),a=i.style,o=i.align,s=i.formatter,l=this.get(t),u=this.getLabelAlignAttrs(t,o),c="label-"+t;this.addShape(n,{type:"text",id:this.getElementId(c),name:"legend-label-"+t,attrs:(0,p.pi)((0,p.pi)({x:0,y:0,text:(0,f.mf)(s)?s(l):l},a),u)})},e.prototype.getLabelAlignAttrs=function(t,n){var i=this.isVertical(),a="center",o="middle";return i?(a="start",n!=="rail"?t==="min"?o="top":o="bottom":o="top"):n!=="rail"?(o="top",t==="min"?a="start":a="end"):(a="start",o="middle"),{textAlign:a,textBaseline:o}},e.prototype.getRailPath=function(t,n,i,a){var o=this.get("rail"),s=o.size,l=o.defaultLength,u=o.type,c=this.isVertical(),h=l,v=i,d=a;v||(v=c?s:h),d||(d=c?h:s);var g=[];return u==="color"?(g.push(["M",t,n]),g.push(["L",t+v,n]),g.push(["L",t+v,n+d]),g.push(["L",t,n+d]),g.push(["Z"])):(g.push(["M",t+v,n]),g.push(["L",t+v,n+d]),g.push(["L",t,n+d]),g.push(["Z"])),g},e.prototype.drawRail=function(t){var n=this.get("rail"),i=n.style;this.addShape(t,{type:"path",id:this.getElementId("rail"),name:"legend-rail",attrs:(0,p.pi)({path:this.getRailPath(0,0)},i)})},e.prototype.getTrackColor=function(t){var n=t.length;if(!n)return null;if(n===1)return t[0];var i;this.isVertical()?i="l(90)":i="l(0)";for(var a=0;a<n;a++){var o=a/(n-1);i+=" "+o+":"+t[a]}return i},e.prototype.getTrackPath=function(t){var n=this.getRailShape(t),i=n.attr("path");return(0,f.d9)(i)},e.prototype.getClipTrackAttrs=function(t){var n=this.getCurrentValue(),i=n[0],a=n[1],o=this.getRailBBox(t),s=this.getPointByValue(i,t),l=this.getPointByValue(a,t),u=this.isVertical(),c,h,v,d;return u?(c=o.minX,h=s.y,v=o.width,d=l.y-s.y):(c=s.x,h=o.minY,v=l.x-s.x,d=o.height),{x:c,y:h,width:v,height:d}},e.prototype.getTrackAttrs=function(t){var n=this.get("track"),i=this.get("colors"),a=this.getTrackPath(t);return(0,f.CD)({path:a,fill:this.getTrackColor(i)},n.style)},e.prototype.resetTrackClip=function(t){var n=t||this.get("group"),i=this.getElementId("track"),a=n.findById(i),o=a.getClip(),s=this.getClipTrackAttrs(t);o?o.attr(s):a.setClip({type:"rect",attrs:s})},e.prototype.resetTrack=function(t){var n=this.getElementId("track"),i=t.findById(n),a=this.getTrackAttrs(t);i?i.attr(a):this.addShape(t,{type:"path",id:n,draggable:this.get("slidable"),name:"legend-track",attrs:a})},e.prototype.getPointByValue=function(t,n){var i=this.getRange(),a=i.min,o=i.max,s=(t-a)/(o-a),l=this.getRailBBox(n),u=this.isVertical(),c={x:0,y:0};return u?(c.x=l.minX+l.width/2,c.y=Ci(l.minY,l.maxY,s)):(c.x=Ci(l.minX,l.maxX,s),c.y=l.minY+l.height/2),c},e.prototype.getRailShape=function(t){var n=t||this.get("group");return n.findById(this.getElementId("rail"))},e.prototype.getRailBBox=function(t){var n=this.getRailShape(t),i=n.getBBox();return i},e.prototype.getRailCanvasBBox=function(){var t=this.get("group"),n=t.findById(this.getElementId("rail")),i=n.getCanvasBBox();return i},e.prototype.isVertical=function(){return this.get("layout")==="vertical"},e.prototype.getValueByCanvasPoint=function(t,n){var i=this.getRange(),a=i.min,o=i.max,s=this.getRailCanvasBBox(),l=this.isVertical(),u=this.get("step"),c;l?c=(n-s.minY)/s.height:c=(t-s.minX)/s.width;var h=Ci(a,o,c);if(u){var v=Math.round((h-a)/u);h=a+v*u}return h>o&&(h=o),h<a&&(h=a),h},e.prototype.getCurrentValue=function(){var t=this.get("value");if(!t){var n=this.get("values");return n?[Math.max(Math.min.apply(Math,(0,p.pr)(n,[this.get("max")])),this.get("min")),Math.min(Math.max.apply(Math,(0,p.pr)(n,[this.get("min")])),this.get("max"))]:[this.get("min"),this.get("max")]}return t},e.prototype.resetHandlers=function(t){var n=this.getCurrentValue(),i=n[0],a=n[1];this.resetHandler(t,"min",i),this.resetHandler(t,"max",a)},e.prototype.getHandlerPath=function(t,n){var i=this.isVertical(),a=[],o=t.size,s=n.x,l=n.y,u=o*qx,c=o/2,h=o/6;if(i){var v=s+u*lh;a.push(["M",s,l]),a.push(["L",v,l+c]),a.push(["L",s+u,l+c]),a.push(["L",s+u,l-c]),a.push(["L",v,l-c]),a.push(["Z"]),a.push(["M",v,l+h]),a.push(["L",s+u-2,l+h]),a.push(["M",v,l-h]),a.push(["L",s+u-2,l-h])}else{var d=l+u*lh;a.push(["M",s,l]),a.push(["L",s-c,d]),a.push(["L",s-c,l+u]),a.push(["L",s+c,l+u]),a.push(["L",s+c,d]),a.push(["Z"]),a.push(["M",s-h,d]),a.push(["L",s-h,l+u-2]),a.push(["M",s+h,d]),a.push(["L",s+h,l+u-2])}return a},e.prototype.resetHandler=function(t,n,i){var a=this.getPointByValue(i,t),o=this.get("handler"),s=this.getHandlerPath(o,a),l=this.getElementId("handler-"+n),u=t.findById(l),c=this.isVertical();u?u.attr("path",s):this.addShape(t,{type:"path",name:"legend-handler-"+n,draggable:!0,id:l,attrs:(0,p.pi)((0,p.pi)({path:s},o.style),{cursor:c?"ns-resize":"ew-resize"})})},e.prototype.fixedElements=function(t){var n=t.findById(this.getElementId("rail")),i=t.findById(this.getElementId("label-min")),a=t.findById(this.getElementId("label-max")),o=this.getDrawPoint();this.isVertical()?this.fixedVertail(i,a,n,o):this.fixedHorizontal(i,a,n,o)},e.prototype.fitRailLength=function(t,n,i,a){var o=this.isVertical(),s=o?"height":"width",l=this.get("label"),u=l.align,c=l.spacing,h=this.get("max"+(0,f.jC)(s));if(h){var v=u==="rail"?i[s]+t[s]+n[s]+c*2:i[s],d=v-h;d>0&&this.changeRailLength(a,s,i[s]-d)}},e.prototype.changeRailLength=function(t,n,i){var a=t.getBBox(),o;n==="height"?o=this.getRailPath(a.x,a.y,a.width,i):o=this.getRailPath(a.x,a.y,i,a.height),t.attr("path",o)},e.prototype.changeRailPosition=function(t,n,i){var a=t.getBBox(),o=this.getRailPath(n,i,a.width,a.height);t.attr("path",o)},e.prototype.fixedHorizontal=function(t,n,i,a){var o=this.get("label"),s=o.align,l=o.spacing,u=i.getBBox(),c=t.getBBox(),h=n.getBBox(),v=u.height;this.fitRailLength(c,h,u,i),u=i.getBBox(),s==="rail"?(t.attr({x:a.x,y:a.y+v/2}),this.changeRailPosition(i,a.x+c.width+l,a.y),n.attr({x:a.x+c.width+u.width+l*2,y:a.y+v/2})):s==="top"?(t.attr({x:a.x,y:a.y}),n.attr({x:a.x+u.width,y:a.y}),this.changeRailPosition(i,a.x,a.y+c.height+l)):(this.changeRailPosition(i,a.x,a.y),t.attr({x:a.x,y:a.y+u.height+l}),n.attr({x:a.x+u.width,y:a.y+u.height+l}))},e.prototype.fixedVertail=function(t,n,i,a){var o=this.get("label"),s=o.align,l=o.spacing,u=i.getBBox(),c=t.getBBox(),h=n.getBBox();if(this.fitRailLength(c,h,u,i),u=i.getBBox(),s==="rail")t.attr({x:a.x,y:a.y}),this.changeRailPosition(i,a.x,a.y+c.height+l),n.attr({x:a.x,y:a.y+c.height+u.height+l*2});else if(s==="right")t.attr({x:a.x+u.width+l,y:a.y}),this.changeRailPosition(i,a.x,a.y),n.attr({x:a.x+u.width+l,y:a.y+u.height});else{var v=Math.max(c.width,h.width);t.attr({x:a.x,y:a.y}),this.changeRailPosition(i,a.x+v+l,a.y),n.attr({x:a.x,y:a.y+u.height})}},e}(oh),jx=Kx,Rn="g2-tooltip",Nn="g2-tooltip-title",Ya="g2-tooltip-list",is="g2-tooltip-list-item",as="g2-tooltip-marker",os="g2-tooltip-value",uh="g2-tooltip-name",vu="g2-tooltip-crosshair-x",du="g2-tooltip-crosshair-y",An,Jx=(An={},An[""+Rn]={position:"absolute",visibility:"visible",zIndex:8,transition:"visibility 0.2s cubic-bezier(0.23, 1, 0.32, 1), left 0.4s cubic-bezier(0.23, 1, 0.32, 1), top 0.4s cubic-bezier(0.23, 1, 0.32, 1)",backgroundColor:"rgba(255, 255, 255, 0.9)",boxShadow:"0px 0px 10px #aeaeae",borderRadius:"3px",color:"rgb(87, 87, 87)",fontSize:"12px",fontFamily:Ge.fontFamily,lineHeight:"20px",padding:"10px 10px 6px 10px"},An[""+Nn]={marginBottom:"4px"},An[""+Ya]={margin:"0px",listStyleType:"none",padding:"0px"},An[""+is]={listStyleType:"none",marginBottom:"4px"},An[""+as]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},An[""+os]={display:"inline-block",float:"right",marginLeft:"30px"},An[""+vu]={position:"absolute",width:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},An[""+du]={position:"absolute",height:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},An);function Qx(r,e,t,n,i){var a={left:r<i.x,right:r+t>i.x+i.width,top:e<i.y,bottom:e+n>i.y+i.height};return a}function t1(r,e,t,n,i,a){var o=r,s=e;switch(a){case"left":o=r-n-t,s=e-i/2;break;case"right":o=r+t,s=e-i/2;break;case"top":o=r-n/2,s=e-i-t;break;case"bottom":o=r-n/2,s=e+t;break;default:o=r+t,s=e-i-t;break}return{x:o,y:s}}function e1(r,e,t,n,i,a,o){var s=t1(r,e,t,n,i,a);if(o){var l=Qx(s.x,s.y,n,i,o);a==="auto"?(l.right&&(s.x=Math.max(0,r-n-t)),l.top&&(s.y=Math.max(0,e-i-t))):a==="top"||a==="bottom"?(l.left&&(s.x=o.x),l.right&&(s.x=o.x+o.width-n),a==="top"&&l.top&&(s.y=e+t),a==="bottom"&&l.bottom&&(s.y=e-i-t)):(l.top&&(s.y=o.y),l.bottom&&(s.y=o.y+o.height-i),a==="left"&&l.left&&(s.x=r+t),a==="right"&&l.right&&(s.x=r-n-t))}return s}function r1(r,e){var t=!1;return(0,f.S6)(e,function(n){if((0,f.wH)(r,n))return t=!0,!1}),t}var n1=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"tooltip",type:"html",x:0,y:0,items:[],customContent:null,containerTpl:'<div class="'+Rn+'"><div class="'+Nn+'"></div><ul class="'+Ya+'"></ul></div>',itemTpl:'<li class="'+is+`" data-index={index}>
  32. <span class="`+as+`" style="background:{color}"></span>
  33. <span class="`+uh+`">{name}</span>:
  34. <span class="`+os+`">{value}</span>
  35. </li>`,xCrosshairTpl:'<div class="'+vu+'"></div>',yCrosshairTpl:'<div class="'+du+'"></div>',title:null,showTitle:!0,region:null,crosshairsRegion:null,containerClassName:Rn,crosshairs:null,offset:10,position:"right",domStyles:null,defaultStyles:Jx})},e.prototype.render=function(){this.get("customContent")?this.renderCustomContent():(this.resetTitle(),this.renderItems()),this.resetPosition()},e.prototype.clear=function(){this.clearCrosshairs(),this.setTitle(""),this.clearItemDoms()},e.prototype.show=function(){var t=this.getContainer();!t||this.destroyed||(this.set("visible",!0),G(t,{visibility:"visible"}),this.setCrossHairsVisible(!0))},e.prototype.hide=function(){var t=this.getContainer();!t||this.destroyed||(this.set("visible",!1),G(t,{visibility:"hidden"}),this.setCrossHairsVisible(!1))},e.prototype.getLocation=function(){return{x:this.get("x"),y:this.get("y")}},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetPosition()},e.prototype.setCrossHairsVisible=function(t){var n=t?"":"none",i=this.get("xCrosshairDom"),a=this.get("yCrosshairDom");i&&G(i,{display:n}),a&&G(a,{display:n})},e.prototype.initContainer=function(){if(r.prototype.initContainer.call(this),this.get("customContent")){this.get("container")&&this.get("container").remove();var t=this.getHtmlContentNode();this.get("parent").appendChild(t),this.set("container",t),this.resetStyles(),this.applyStyles()}},e.prototype.updateInner=function(t){this.get("customContent")?this.renderCustomContent():(r1(t,["title","showTitle"])&&this.resetTitle(),(0,f.wH)(t,"items")&&this.renderItems()),r.prototype.updateInner.call(this,t)},e.prototype.initDom=function(){this.cacheDoms()},e.prototype.removeDom=function(){r.prototype.removeDom.call(this),this.clearCrosshairs()},e.prototype.resetPosition=function(){var t=this.get("x"),n=this.get("y"),i=this.get("offset"),a=this.getOffset(),o=a.offsetX,s=a.offsetY,l=this.get("position"),u=this.get("region"),c=this.getContainer(),h=this.getBBox(),v=h.width,d=h.height,g;u&&(g=Ra(u));var y=e1(t,n,i,v,d,l,g);G(c,{left:Br(y.x+o),top:Br(y.y+s)}),this.resetCrosshairs()},e.prototype.renderCustomContent=function(){var t=this.getHtmlContentNode(),n=this.get("parent"),i=this.get("container");i&&i.parentNode===n?n.replaceChild(t,i):n.appendChild(t),this.set("container",t),this.resetStyles(),this.applyStyles()},e.prototype.getHtmlContentNode=function(){var t,n=this.get("customContent");if(n){var i=n(this.get("title"),this.get("items"));(0,f.kK)(i)?t=i:t=V(i)}return t},e.prototype.cacheDoms=function(){var t=this.getContainer(),n=t.getElementsByClassName(Nn)[0],i=t.getElementsByClassName(Ya)[0];this.set("titleDom",n),this.set("listDom",i)},e.prototype.resetTitle=function(){var t=this.get("title"),n=this.get("showTitle");n&&t?this.setTitle(t):this.setTitle("")},e.prototype.setTitle=function(t){var n=this.get("titleDom");n&&(n.innerText=t)},e.prototype.resetCrosshairs=function(){var t=this.get("crosshairsRegion"),n=this.get("crosshairs");if(!t||!n)this.clearCrosshairs();else{var i=Ra(t),a=this.get("xCrosshairDom"),o=this.get("yCrosshairDom");n==="x"?(this.resetCrosshair("x",i),o&&(o.remove(),this.set("yCrosshairDom",null))):n==="y"?(this.resetCrosshair("y",i),a&&(a.remove(),this.set("xCrosshairDom",null))):(this.resetCrosshair("x",i),this.resetCrosshair("y",i)),this.setCrossHairsVisible(this.get("visible"))}},e.prototype.resetCrosshair=function(t,n){var i=this.checkCrosshair(t),a=this.get(t);t==="x"?G(i,{left:Br(a),top:Br(n.y),height:Br(n.height)}):G(i,{top:Br(a),left:Br(n.x),width:Br(n.width)})},e.prototype.checkCrosshair=function(t){var n=t+"CrosshairDom",i=t+"CrosshairTpl",a="CROSSHAIR_"+t.toUpperCase(),o=xt[a],s=this.get(n),l=this.get("parent");return s||(s=V(this.get(i)),this.applyStyle(o,s),l.appendChild(s),this.set(n,s)),s},e.prototype.renderItems=function(){this.clearItemDoms();var t=this.get("items"),n=this.get("itemTpl"),i=this.get("listDom");i&&((0,f.S6)(t,function(a){var o=nn.toCSSGradient(a.color),s=(0,p.pi)((0,p.pi)({},a),{color:o}),l=(0,f.ng)(n,s),u=V(l);i.appendChild(u)}),this.applyChildrenStyles(i,this.get("domStyles")))},e.prototype.clearItemDoms=function(){this.get("listDom")&&eu(this.get("listDom"))},e.prototype.clearCrosshairs=function(){var t=this.get("xCrosshairDom"),n=this.get("yCrosshairDom");t&&t.remove(),n&&n.remove(),this.set("xCrosshairDom",null),this.set("yCrosshairDom",null)},e}(iu),i1=n1,a1={opacity:0},o1={stroke:"#C5C5C5",strokeOpacity:.85},s1={fill:"#CACED4",opacity:.85},l1=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/ig,u1=/[^\s\,]+/ig;function c6(r){var e=r||[];if(isArray(e))return e;if(isString(e))return e=e.match(l1),each(e,function(t,n){if(t=t.match(u1),t[0].length>1){var i=t[0].charAt(0);t.splice(1,0,t[0].substr(1)),t[0]=i}each(t,function(a,o){isNaN(a)||(t[o]=+a)}),e[n]=t}),e}var f6=null;function c1(r,e,t,n){var i=[],a=!!n,o,s,l,u,c,h,v;if(a){l=n[0],u=n[1];for(var d=0,g=r.length;d<g;d+=1){var y=r[d];l=xe.VV([0,0],l,y),u=xe.Fp([0,0],u,y)}}for(var d=0,x=r.length;d<x;d+=1){var y=r[d];if(d===0&&!t)v=y;else if(d===x-1&&!t)h=y,i.push(v),i.push(h);else{var m=[d?d-1:x-1,d-1][t?0:1];o=r[m],s=r[t?(d+1)%x:d+1];var M=[0,0];M=xe.lu(M,s,o),M=xe.bA(M,M,e);var w=xe.TE(y,o),S=xe.TE(y,s),b=w+S;b!==0&&(w/=b,S/=b);var k=xe.bA([0,0],M,-w),H=xe.bA([0,0],M,S);h=xe.IH([0,0],y,k),c=xe.IH([0,0],y,H),c=xe.VV([0,0],c,xe.Fp([0,0],s,y)),c=xe.Fp([0,0],c,xe.VV([0,0],s,y)),k=xe.lu([0,0],c,y),k=xe.bA([0,0],k,-w/S),h=xe.IH([0,0],y,k),h=xe.VV([0,0],h,xe.Fp([0,0],o,y)),h=xe.Fp([0,0],h,xe.VV([0,0],o,y)),H=xe.lu([0,0],y,h),H=xe.bA([0,0],H,S/w),c=xe.IH([0,0],y,H),a&&(h=xe.Fp([0,0],h,l),h=xe.VV([0,0],h,u),c=xe.Fp([0,0],c,l),c=xe.VV([0,0],c,u)),i.push(v),i.push(h),v=c}}return t&&i.push(i.shift()),i}function f1(r,e,t){e===void 0&&(e=!1),t===void 0&&(t=[[0,0],[1,1]]);for(var n=!!e,i=[],a=0,o=r.length;a<o;a+=2)i.push([r[a],r[a+1]]);for(var s=c1(i,.4,n,t),l=i.length,u=[],c,h,v,a=0;a<l-1;a+=1)c=s[a*2],h=s[a*2+1],v=i[a+1],u.push(["C",c[0],c[1],h[0],h[1],v[0],v[1]]);return n&&(c=s[l],h=s[l+1],v=i[0],u.push(["C",c[0],c[1],h[0],h[1],v[0],v[1]])),u}var h1=f1;function v1(r,e,t){var n=null,i=t;return e<i&&(i=e,n="add"),r<i&&(i=r,n="del"),{type:n,min:i}}var d1=function(r,e){var t=r.length,n=e.length,i,a,o=0;if(t===0||n===0)return null;for(var s=[],l=0;l<=t;l++)s[l]=[],s[l][0]={min:l};for(var u=0;u<=n;u++)s[0][u]={min:u};for(var l=1;l<=t;l++){i=r[l-1];for(var u=1;u<=n;u++){a=e[u-1],isEqual(i,a)?o=0:o=1;var c=s[l-1][u].min+1,h=s[l][u-1].min+1,v=s[l-1][u-1].min+o;s[l][u]=v1(c,h,v)}}return s};function h6(r,e){var t=d1(r,e),n=r.length,i=e.length,a=[],o=1,s=1;if(t[n][i]!==n){for(var l=1;l<=n;l++){var u=t[l][l].min;s=l;for(var c=o;c<=i;c++)t[l][c].min<u&&(u=t[l][c].min,s=c);o=s,t[l][o].type&&a.push({index:l-1,type:t[l][o].type})}for(var l=a.length-1;l>=0;l--)o=a[l].index,a[l].type==="add"?r.splice(o,0,[].concat(r[o])):r.splice(o,1)}if(n=r.length,n<i)for(var l=0;l<i-n;l++)r[n-1][0]==="z"||r[n-1][0]==="Z"?r.splice(n-2,0,r[n-2]):r.push(r[n-1]);return r}var Xa=`
  36. \v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,p1=new RegExp("([a-z])["+Xa+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+Xa+"]*,?["+Xa+"]*)+)","ig"),g1=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+Xa+"]*,?["+Xa+"]*","ig");function v6(r){if(!r)return null;if(isArray(r))return r;var e={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},t=[];return String(r).replace(p1,function(n,i,a){var o=[],s=i.toLowerCase();if(a.replace(g1,function(l,u){u&&o.push(+u)}),s==="m"&&o.length>2&&(t.push([i].concat(o.splice(0,2))),s="l",i=i==="m"?"l":"L"),s==="o"&&o.length===1&&t.push([i,o[0]]),s==="r")t.push([i].concat(o));else for(;o.length>=e[s]&&(t.push([i].concat(o.splice(0,e[s]))),!!e[s]););return""}),t}var y1=/[a-z]/;function ch(r,e){return[e[0]+(e[0]-r[0]),e[1]+(e[1]-r[1])]}function d6(r){var e=parsePathString(r);if(!e||!e.length)return[["M",0,0]];for(var t=!1,n=0;n<e.length;n++){var i=e[n][0];if(y1.test(i)||["V","H","T","S"].indexOf(i)>=0){t=!0;break}}if(!t)return e;var a=[],o=0,s=0,l=0,u=0,c=0,h,v,d=e[0];(d[0]==="M"||d[0]==="m")&&(o=+d[1],s=+d[2],l=o,u=s,c++,a[0]=["M",o,s]);for(var n=c,g=e.length;n<g;n++){var y=e[n],x=a[n-1],m=[],i=y[0],M=i.toUpperCase();if(i!==M)switch(m[0]=M,M){case"A":m[1]=y[1],m[2]=y[2],m[3]=y[3],m[4]=y[4],m[5]=y[5],m[6]=+y[6]+o,m[7]=+y[7]+s;break;case"V":m[1]=+y[1]+s;break;case"H":m[1]=+y[1]+o;break;case"M":l=+y[1]+o,u=+y[2]+s,m[1]=l,m[2]=u;break;default:for(var w=1,S=y.length;w<S;w++)m[w]=+y[w]+(w%2?o:s)}else m=e[n];switch(M){case"Z":o=+l,s=+u;break;case"H":o=m[1],m=["L",o,s];break;case"V":s=m[1],m=["L",o,s];break;case"T":o=m[1],s=m[2];var b=ch([x[1],x[2]],[x[3],x[4]]);m=["Q",b[0],b[1],o,s];break;case"S":o=m[m.length-2],s=m[m.length-1];var k=x.length,H=ch([x[k-4],x[k-3]],[x[k-2],x[k-1]]);m=["C",H[0],H[1],m[1],m[2],o,s];break;case"M":l=m[m.length-2],u=m[m.length-1];break;default:o=m[m.length-2],s=m[m.length-1]}a.push(m)}return a}var Wa=Math.PI*2,pu=function(r,e,t,n,i,a,o){var s=r.x,l=r.y;s*=e,l*=t;var u=n*s-i*l,c=i*s+n*l;return{x:u+a,y:c+o}},m1=function(r,e){var t=e===1.5707963267948966?.551915024494:e===-1.5707963267948966?-.551915024494:4/3*Math.tan(e/4),n=Math.cos(r),i=Math.sin(r),a=Math.cos(r+e),o=Math.sin(r+e);return[{x:n-i*t,y:i+n*t},{x:a+o*t,y:o-a*t},{x:a,y:o}]},fh=function(r,e,t,n){var i=r*n-e*t<0?-1:1,a=r*t+e*n;return a>1&&(a=1),a<-1&&(a=-1),i*Math.acos(a)},x1=function(r,e,t,n,i,a,o,s,l,u,c,h){var v=Math.pow(i,2),d=Math.pow(a,2),g=Math.pow(c,2),y=Math.pow(h,2),x=v*d-v*y-d*g;x<0&&(x=0),x/=v*y+d*g,x=Math.sqrt(x)*(o===s?-1:1);var m=x*i/a*h,M=x*-a/i*c,w=u*m-l*M+(r+t)/2,S=l*m+u*M+(e+n)/2,b=(c-m)/i,k=(h-M)/a,H=(-c-m)/i,at=(-h-M)/a,At=fh(1,0,b,k),gt=fh(b,k,H,at);return s===0&&gt>0&&(gt-=Wa),s===1&&gt<0&&(gt+=Wa),[w,S,At,gt]},M1=function(r){var e=r.px,t=r.py,n=r.cx,i=r.cy,a=r.rx,o=r.ry,s=r.xAxisRotation,l=s===void 0?0:s,u=r.largeArcFlag,c=u===void 0?0:u,h=r.sweepFlag,v=h===void 0?0:h,d=[];if(a===0||o===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];var g=Math.sin(l*Wa/360),y=Math.cos(l*Wa/360),x=y*(e-n)/2+g*(t-i)/2,m=-g*(e-n)/2+y*(t-i)/2;if(x===0&&m===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];a=Math.abs(a),o=Math.abs(o);var M=Math.pow(x,2)/Math.pow(a,2)+Math.pow(m,2)/Math.pow(o,2);M>1&&(a*=Math.sqrt(M),o*=Math.sqrt(M));var w=x1(e,t,n,i,a,o,c,v,g,y,x,m),S=w[0],b=w[1],k=w[2],H=w[3],at=Math.abs(H)/(Wa/4);Math.abs(1-at)<1e-7&&(at=1);var At=Math.max(Math.ceil(at),1);H/=At;for(var gt=0;gt<At;gt++)d.push(m1(k,H)),k+=H;return d.map(function(Nt){var te=pu(Nt[0],a,o,y,g,S,b),ce=te.x,Me=te.y,be=pu(Nt[1],a,o,y,g,S,b),Gt=be.x,ie=be.y,de=pu(Nt[2],a,o,y,g,S,b),ue=de.x,pe=de.y;return{x1:ce,y1:Me,x2:Gt,y2:ie,x:ue,y:pe}})};function p6(r,e,t,n,i,a,o,s,l){var u=M1({px:r,py:e,cx:s,cy:l,rx:t,ry:n,xAxisRotation:i,largeArcFlag:a,sweepFlag:o});return u.reduce(function(c,h){var v=h.x1,d=h.y1,g=h.x2,y=h.y2,x=h.x,m=h.y;return c.push(v,d,g,y,x,m),c},[])}function g6(r,e){"TQ".indexOf(r[0])<0&&(e.qx=null,e.qy=null);var t=r.slice(1),n=t[0],i=t[1];switch(r[0]){case"M":return e.x=n,e.y=i,r;case"A":return["C"].concat(arcToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"Q":return e.qx=n,e.qy=i,["C"].concat(quadToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"L":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],r[2]));case"H":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],e.y1));case"V":return["C"].concat(lineToCubic(e.x1,e.y1,e.x1,r[1]));case"Z":return["C"].concat(lineToCubic(e.x1,e.y1,e.x,e.y));default:}return r}function y6(r,e){e===void 0&&(e=!1);for(var t=path2Absolute(r),n={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null},i=[],a="",o=t.length,s,l,u=[],c=0;c<o;c+=1)t[c]&&(a=t[c][0]),i[c]=a,t[c]=segmentToCubic(t[c],n),w1(t,i,c),o=t.length,a==="Z"&&u.push(c),s=t[c],l=s.length,n.x1=+s[l-2],n.y1=+s[l-1],n.x2=+s[l-4]||n.x1,n.y2=+s[l-3]||n.y1;return e?[t,u]:t}function w1(r,e,t){if(r[t].length>7){r[t].shift();for(var n=r[t],i=t;n.length;)e[t]="A",r.splice(i+=1,0,["C"].concat(n.splice(0,6)));r.splice(t,1)}}var hh=function(r,e,t,n,i){var a=-3*e+9*t-9*n+3*i,o=r*a+6*e-12*t+6*n;return r*o-3*e+3*t},vh=function(r,e,t,n,i,a,o,s,l){l===null&&(l=1),l=l>1?1:l<0?0:l;for(var u=l/2,c=12,h=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],v=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],d=0,g=0;g<c;g++){var y=u*h[g]+u,x=hh(y,r,t,i,o),m=hh(y,e,n,a,s),M=x*x+m*m;d+=v[g]*Math.sqrt(M)}return u*d},S1=function(r,e,t,n,i,a,o,s){for(var l=[],u=[[],[]],c,h,v,d,g=0;g<2;++g){if(g===0?(h=6*r-12*t+6*i,c=-3*r+9*t-9*i+3*o,v=3*t-3*r):(h=6*e-12*n+6*a,c=-3*e+9*n-9*a+3*s,v=3*n-3*e),Math.abs(c)<1e-12){if(Math.abs(h)<1e-12)continue;d=-v/h,d>0&&d<1&&l.push(d);continue}var y=h*h-4*v*c,x=Math.sqrt(y);if(!(y<0)){var m=(-h+x)/(2*c);m>0&&m<1&&l.push(m);var M=(-h-x)/(2*c);M>0&&M<1&&l.push(M)}}for(var w=l.length,S=w,b;w--;)d=l[w],b=1-d,u[0][w]=b*b*b*r+3*b*b*d*t+3*b*d*d*i+d*d*d*o,u[1][w]=b*b*b*e+3*b*b*d*n+3*b*d*d*a+d*d*d*s;return u[0][S]=r,u[1][S]=e,u[0][S+1]=o,u[1][S+1]=s,u[0].length=u[1].length=S+2,{min:{x:Math.min.apply(0,u[0]),y:Math.min.apply(0,u[1])},max:{x:Math.max.apply(0,u[0]),y:Math.max.apply(0,u[1])}}},C1=function(r,e,t,n,i,a,o,s){if(!(Math.max(r,t)<Math.min(i,o)||Math.min(r,t)>Math.max(i,o)||Math.max(e,n)<Math.min(a,s)||Math.min(e,n)>Math.max(a,s))){var l=(r*n-e*t)*(i-o)-(r-t)*(i*s-a*o),u=(r*n-e*t)*(a-s)-(e-n)*(i*s-a*o),c=(r-t)*(a-s)-(e-n)*(i-o);if(!!c){var h=l/c,v=u/c,d=+h.toFixed(2),g=+v.toFixed(2);if(!(d<+Math.min(r,t).toFixed(2)||d>+Math.max(r,t).toFixed(2)||d<+Math.min(i,o).toFixed(2)||d>+Math.max(i,o).toFixed(2)||g<+Math.min(e,n).toFixed(2)||g>+Math.max(e,n).toFixed(2)||g<+Math.min(a,s).toFixed(2)||g>+Math.max(a,s).toFixed(2)))return{x:h,y:v}}}},Jn=function(r,e,t){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height},gu=function(r,e,t,n){return r===null&&(r=e=t=n=0),e===null&&(e=r.y,t=r.width,n=r.height,r=r.x),{x:r,y:e,width:t,w:t,height:n,h:n,x2:r+t,y2:e+n,cx:r+t/2,cy:e+n/2,r1:Math.min(t,n)/2,r2:Math.max(t,n)/2,r0:Math.sqrt(t*t+n*n)/2,path:rectPath(r,e,t,n),vb:[r,e,t,n].join(" ")}},A1=function(r,e){return r=gu(r),e=gu(e),Jn(e,r.x,r.y)||Jn(e,r.x2,r.y)||Jn(e,r.x,r.y2)||Jn(e,r.x2,r.y2)||Jn(r,e.x,e.y)||Jn(r,e.x2,e.y)||Jn(r,e.x,e.y2)||Jn(r,e.x2,e.y2)||(r.x<e.x2&&r.x>e.x||e.x<r.x2&&e.x>r.x)&&(r.y<e.y2&&r.y>e.y||e.y<r.y2&&e.y>r.y)},dh=function(r,e,t,n,i,a,o,s){isArray(r)||(r=[r,e,t,n,i,a,o,s]);var l=S1.apply(null,r);return gu(l.min.x,l.min.y,l.max.x-l.min.x,l.max.y-l.min.y)},ph=function(r,e,t,n,i,a,o,s,l){var u=1-l,c=Math.pow(u,3),h=Math.pow(u,2),v=l*l,d=v*l,g=c*r+h*3*l*t+u*3*l*l*i+d*o,y=c*e+h*3*l*n+u*3*l*l*a+d*s,x=r+2*l*(t-r)+v*(i-2*t+r),m=e+2*l*(n-e)+v*(a-2*n+e),M=t+2*l*(i-t)+v*(o-2*i+t),w=n+2*l*(a-n)+v*(s-2*a+n),S=u*r+l*t,b=u*e+l*n,k=u*i+l*o,H=u*a+l*s,at=90-Math.atan2(x-M,m-w)*180/Math.PI;return{x:g,y,m:{x,y:m},n:{x:M,y:w},start:{x:S,y:b},end:{x:k,y:H},alpha:at}},b1=function(r,e,t){var n=dh(r),i=dh(e);if(!A1(n,i))return t?0:[];for(var a=vh.apply(0,r),o=vh.apply(0,e),s=~~(a/8),l=~~(o/8),u=[],c=[],h={},v=t?0:[],d=0;d<s+1;d++){var g=ph.apply(0,r.concat(d/s));u.push({x:g.x,y:g.y,t:d/s})}for(var d=0;d<l+1;d++){var g=ph.apply(0,e.concat(d/l));c.push({x:g.x,y:g.y,t:d/l})}for(var d=0;d<s;d++)for(var y=0;y<l;y++){var x=u[d],m=u[d+1],M=c[y],w=c[y+1],S=Math.abs(m.x-x.x)<.001?"y":"x",b=Math.abs(w.x-M.x)<.001?"y":"x",k=C1(x.x,x.y,m.x,m.y,M.x,M.y,w.x,w.y);if(k){if(h[k.x.toFixed(4)]===k.y.toFixed(4))continue;h[k.x.toFixed(4)]=k.y.toFixed(4);var H=x.t+Math.abs((k[S]-x[S])/(m[S]-x[S]))*(m.t-x.t),at=M.t+Math.abs((k[b]-M[b])/(w[b]-M[b]))*(w.t-M.t);H>=0&&H<=1&&at>=0&&at<=1&&(t?v++:v.push({x:k.x,y:k.y,t1:H,t2:at}))}}return v},T1=function(r,e,t){r=path2Curve(r),e=path2Curve(e);for(var n,i,a,o,s,l,u,c,h,v,d=t?0:[],g=0,y=r.length;g<y;g++){var x=r[g];if(x[0]==="M")n=s=x[1],i=l=x[2];else{x[0]==="C"?(h=[n,i].concat(x.slice(1)),n=h[6],i=h[7]):(h=[n,i,n,i,s,l,s,l],n=s,i=l);for(var m=0,M=e.length;m<M;m++){var w=e[m];if(w[0]==="M")a=u=w[1],o=c=w[2];else{w[0]==="C"?(v=[a,o].concat(w.slice(1)),a=v[6],o=v[7]):(v=[a,o,a,o,u,c,u,c],a=u,o=c);var S=b1(h,v,t);if(t)d+=S;else{for(var b=0,k=S.length;b<k;b++)S[b].segment1=g,S[b].segment2=m,S[b].bez1=h,S[b].bez2=v;d=d.concat(S)}}}}}return d};function m6(r,e){return T1(r,e)}function ss(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function yu(r,e){return ss(r)*ss(e)?(r[0]*e[0]+r[1]*e[1])/(ss(r)*ss(e)):1}function gh(r,e){return(r[0]*e[1]<r[1]*e[0]?-1:1)*Math.acos(yu(r,e))}function yh(r,e){return r[0]===e[0]&&r[1]===e[1]}function x6(r,e){var t=e[1],n=e[2],i=mod(toRadian(e[3]),Math.PI*2),a=e[4],o=e[5],s=r[0],l=r[1],u=e[6],c=e[7],h=Math.cos(i)*(s-u)/2+Math.sin(i)*(l-c)/2,v=-1*Math.sin(i)*(s-u)/2+Math.cos(i)*(l-c)/2,d=h*h/(t*t)+v*v/(n*n);d>1&&(t*=Math.sqrt(d),n*=Math.sqrt(d));var g=t*t*(v*v)+n*n*(h*h),y=g?Math.sqrt((t*t*(n*n)-g)/g):1;a===o&&(y*=-1),isNaN(y)&&(y=0);var x=n?y*t*v/n:0,m=t?y*-n*h/t:0,M=(s+u)/2+Math.cos(i)*x-Math.sin(i)*m,w=(l+c)/2+Math.sin(i)*x+Math.cos(i)*m,S=[(h-x)/t,(v-m)/n],b=[(-1*h-x)/t,(-1*v-m)/n],k=gh([1,0],S),H=gh(S,b);return yu(S,b)<=-1&&(H=Math.PI),yu(S,b)>=1&&(H=0),o===0&&H>0&&(H=H-2*Math.PI),o===1&&H<0&&(H=H+2*Math.PI),{cx:M,cy:w,rx:yh(r,[u,c])?0:t,ry:yh(r,[u,c])?0:n,startAngle:k,endAngle:k+H,xRotation:i,arcFlag:a,sweepFlag:o}}function mh(r,e){return[e[0]+(e[0]-r[0]),e[1]+(e[1]-r[1])]}function M6(r){r=parsePath(r);for(var e=[],t=null,n=null,i=null,a=0,o=r.length,s=0;s<o;s++){var l=r[s];n=r[s+1];var u=l[0],c={command:u,prePoint:t,params:l,startTangent:null,endTangent:null};switch(u){case"M":i=[l[1],l[2]],a=s;break;case"A":var h=getArcParams(t,l);c.arcParams=h;break;default:break}if(u==="Z")t=i,n=r[a+1];else{var v=l.length;t=[l[v-2],l[v-1]]}n&&n[0]==="Z"&&(n=r[a],e[a]&&(e[a].prePoint=t)),c.currentPoint=t,e[a]&&isSamePoint(t,e[a].currentPoint)&&(e[a].prePoint=c.prePoint);var d=n?[n[n.length-2],n[n.length-1]]:null;c.nextPoint=d;var g=c.prePoint;if(["L","H","V"].includes(u))c.startTangent=[g[0]-t[0],g[1]-t[1]],c.endTangent=[t[0]-g[0],t[1]-g[1]];else if(u==="Q"){var y=[l[1],l[2]];c.startTangent=[g[0]-y[0],g[1]-y[1]],c.endTangent=[t[0]-y[0],t[1]-y[1]]}else if(u==="T"){var x=e[s-1],y=mh(x.currentPoint,g);x.command==="Q"?(c.command="Q",c.startTangent=[g[0]-y[0],g[1]-y[1]],c.endTangent=[t[0]-y[0],t[1]-y[1]]):(c.command="TL",c.startTangent=[g[0]-t[0],g[1]-t[1]],c.endTangent=[t[0]-g[0],t[1]-g[1]])}else if(u==="C"){var m=[l[1],l[2]],M=[l[3],l[4]];c.startTangent=[g[0]-m[0],g[1]-m[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]],c.startTangent[0]===0&&c.startTangent[1]===0&&(c.startTangent=[m[0]-M[0],m[1]-M[1]]),c.endTangent[0]===0&&c.endTangent[1]===0&&(c.endTangent=[M[0]-m[0],M[1]-m[1]])}else if(u==="S"){var x=e[s-1],m=mh(x.currentPoint,g),M=[l[1],l[2]];x.command==="C"?(c.command="C",c.startTangent=[g[0]-m[0],g[1]-m[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]]):(c.command="SQ",c.startTangent=[g[0]-M[0],g[1]-M[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]])}else if(u==="A"){var w=.001,S=c.arcParams||{},b=S.cx,k=b===void 0?0:b,H=S.cy,at=H===void 0?0:H,At=S.rx,gt=At===void 0?0:At,Nt=S.ry,te=Nt===void 0?0:Nt,ce=S.sweepFlag,Me=ce===void 0?0:ce,be=S.startAngle,Gt=be===void 0?0:be,ie=S.endAngle,de=ie===void 0?0:ie;Me===0&&(w*=-1);var ue=gt*Math.cos(Gt-w)+k,pe=te*Math.sin(Gt-w)+at;c.startTangent=[ue-i[0],pe-i[1]];var Ee=gt*Math.cos(Gt+de+w)+k,Ne=te*Math.sin(Gt+de-w)+at;c.endTangent=[g[0]-Ee,g[1]-Ne]}e.push(c)}return e}function xh(r){for(var e=[],t=r.length,n=0;n<t-1;n++){var i=r[n],a=r[n+1];e.push({from:{x:i[0],y:i[1]},to:{x:a[0],y:a[1]}})}if(e.length>1){var o=r[0],s=r[t-1];e.push({from:{x:s[0],y:s[1]},to:{x:o[0],y:o[1]}})}return e}function E1(r,e){var t=!1;return each(r,function(n){if(getLineIntersect(n.from,n.to,e.from,e.to))return t=!0,!1}),t}function Mh(r){var e=r.map(function(n){return n[0]}),t=r.map(function(n){return n[1]});return{minX:Math.min.apply(null,e),maxX:Math.max.apply(null,e),minY:Math.min.apply(null,t),maxY:Math.max.apply(null,t)}}function _1(r,e){return!(e.minX>r.maxX||e.maxX<r.minX||e.minY>r.maxY||e.maxY<r.minY)}function w6(r,e){if(r.length<2||e.length<2)return!1;var t=Mh(r),n=Mh(e);if(!_1(t,n))return!1;var i=!1;if(each(e,function(l){if(isPointInPolygon(r,l[0],l[1]))return i=!0,!1}),i||(each(r,function(l){if(isPointInPolygon(e,l[0],l[1]))return i=!0,!1}),i))return!0;var a=xh(r),o=xh(e),s=!1;return each(o,function(l){if(E1(a,l))return s=!0,!1}),s}function F1(r){return(0,f.UI)(r,function(e,t){var n=t===0?"M":"L",i=e[0],a=e[1];return[n,i,a]})}function wh(r){return F1(r)}function I1(r){if(r.length<=2)return wh(r);var e=[];(0,f.S6)(r,function(o){(0,f.Xy)(o,e.slice(e.length-2))||e.push(o[0],o[1])});var t=h1(e,!1),n=(0,f.YM)(r),i=n[0],a=n[1];return t.unshift(["M",i,a]),t}function P1(r,e,t,n){n===void 0&&(n=!0);var i=new ji({values:r}),a=new yi({values:(0,f.UI)(r,function(s,l){return l})}),o=(0,f.UI)(r,function(s,l){return[a.scale(l)*e,t-i.scale(s)*t]});return n?I1(o):wh(o)}function L1(r,e){var t=new ji({values:r}),n=t.max<0?t.max:Math.max(0,t.min);return e-t.scale(n)*e}function D1(r,e,t,n){var i=(0,p.pr)(r),a=L1(n,t);return i.push(["L",e,a]),i.push(["L",0,a]),i.push(["Z"]),i}var O1=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"trend",x:0,y:0,width:200,height:16,smooth:!0,isArea:!1,data:[],backgroundStyle:a1,lineStyle:o1,areaStyle:s1})},e.prototype.renderInner=function(t){var n=this.cfg,i=n.width,a=n.height,o=n.data,s=n.smooth,l=n.isArea,u=n.backgroundStyle,c=n.lineStyle,h=n.areaStyle;this.addShape(t,{id:this.getElementId("background"),type:"rect",attrs:(0,p.pi)({x:0,y:0,width:i,height:a},u)});var v=P1(o,i,a,s);if(this.addShape(t,{id:this.getElementId("line"),type:"path",attrs:(0,p.pi)({path:v},c)}),l){var d=D1(v,i,a,o);this.addShape(t,{id:this.getElementId("area"),type:"path",attrs:(0,p.pi)({path:d},h)})}},e.prototype.applyOffset=function(){var t=this.cfg,n=t.x,i=t.y;this.moveElementTo(this.get("group"),{x:n,y:i})},e}(Ar),S6=null,Sh={fill:"#F7F7F7",stroke:"#BFBFBF",radius:2,opacity:1,cursor:"ew-resize",highLightFill:"#FFF"},Ch=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"handler",x:0,y:0,width:10,height:24,style:Sh})},e.prototype.renderInner=function(t){var n=this.cfg,i=n.width,a=n.height,o=n.style,s=o.fill,l=o.stroke,u=o.radius,c=o.opacity,h=o.cursor;this.addShape(t,{type:"rect",id:this.getElementId("background"),attrs:{x:0,y:0,width:i,height:a,fill:s,stroke:l,radius:u,opacity:c,cursor:h}});var v=1/3*i,d=2/3*i,g=1/4*a,y=3/4*a;this.addShape(t,{id:this.getElementId("line-left"),type:"line",attrs:{x1:v,y1:g,x2:v,y2:y,stroke:l,cursor:h}}),this.addShape(t,{id:this.getElementId("line-right"),type:"line",attrs:{x1:d,y1:g,x2:d,y2:y,stroke:l,cursor:h}})},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.bindEvents=function(){var t=this;this.get("group").on("mouseenter",function(){var n=t.get("style").highLightFill;t.getElementByLocalId("background").attr("fill",n),t.draw()}),this.get("group").on("mouseleave",function(){var n=t.get("style").fill;t.getElementByLocalId("background").attr("fill",n),t.draw()})},e.prototype.draw=function(){var t=this.get("container").get("canvas");t&&t.draw()},e}(Ar),C6=null,k1={fill:"#416180",opacity:.05},B1={fill:"#5B8FF9",opacity:.15,cursor:"move"},ls=10,R1={width:ls,height:24},N1={textBaseline:"middle",fill:"#000",opacity:.45},U1="sliderchange",z1=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.onMouseDown=function(n){return function(i){t.currentTarget=n;var a=i.originalEvent;a.stopPropagation(),a.preventDefault(),t.prevX=(0,f.U2)(a,"touches.0.pageX",a.pageX),t.prevY=(0,f.U2)(a,"touches.0.pageY",a.pageY);var o=t.getContainerDOM();o.addEventListener("mousemove",t.onMouseMove),o.addEventListener("mouseup",t.onMouseUp),o.addEventListener("mouseleave",t.onMouseUp),o.addEventListener("touchmove",t.onMouseMove),o.addEventListener("touchend",t.onMouseUp),o.addEventListener("touchcancel",t.onMouseUp)}},t.onMouseMove=function(n){var i=t.cfg.width,a=[t.get("start"),t.get("end")];n.stopPropagation(),n.preventDefault();var o=(0,f.U2)(n,"touches.0.pageX",n.pageX),s=(0,f.U2)(n,"touches.0.pageY",n.pageY),l=o-t.prevX,u=t.adjustOffsetRange(l/i);t.updateStartEnd(u),t.updateUI(t.getElementByLocalId("foreground"),t.getElementByLocalId("minText"),t.getElementByLocalId("maxText")),t.prevX=o,t.prevY=s,t.draw(),t.emit(U1,[t.get("start"),t.get("end")].sort()),t.delegateEmit("valuechanged",{originValue:a,value:[t.get("start"),t.get("end")]})},t.onMouseUp=function(){t.currentTarget&&(t.currentTarget=void 0);var n=t.getContainerDOM();n&&(n.removeEventListener("mousemove",t.onMouseMove),n.removeEventListener("mouseup",t.onMouseUp),n.removeEventListener("mouseleave",t.onMouseUp),n.removeEventListener("touchmove",t.onMouseMove),n.removeEventListener("touchend",t.onMouseUp),n.removeEventListener("touchcancel",t.onMouseUp))},t}return e.prototype.setRange=function(t,n){this.set("minLimit",t),this.set("maxLimit",n);var i=this.get("start"),a=this.get("end"),o=(0,f.uZ)(i,t,n),s=(0,f.uZ)(a,t,n);!this.get("isInit")&&(i!==o||a!==s)&&this.setValue([o,s])},e.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},e.prototype.setValue=function(t){var n=this.getRange();if((0,f.kJ)(t)&&t.length===2){var i=[this.get("start"),this.get("end")];this.update({start:(0,f.uZ)(t[0],n.min,n.max),end:(0,f.uZ)(t[1],n.min,n.max)}),this.get("updateAutoRender")||this.render(),this.delegateEmit("valuechanged",{originValue:i,value:t})}},e.prototype.getValue=function(){return[this.get("start"),this.get("end")]},e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"slider",x:0,y:0,width:100,height:16,backgroundStyle:{},foregroundStyle:{},handlerStyle:{},textStyle:{},defaultCfg:{backgroundStyle:k1,foregroundStyle:B1,handlerStyle:R1,textStyle:N1}})},e.prototype.update=function(t){var n=t.start,i=t.end,a=(0,p.pi)({},t);(0,f.UM)(n)||(a.start=(0,f.uZ)(n,0,1)),(0,f.UM)(i)||(a.end=(0,f.uZ)(i,0,1)),r.prototype.update.call(this,a),this.minHandler=this.getChildComponentById(this.getElementId("minHandler")),this.maxHandler=this.getChildComponentById(this.getElementId("maxHandler")),this.trend=this.getChildComponentById(this.getElementId("trend"))},e.prototype.init=function(){this.set("start",(0,f.uZ)(this.get("start"),0,1)),this.set("end",(0,f.uZ)(this.get("end"),0,1)),r.prototype.init.call(this)},e.prototype.render=function(){r.prototype.render.call(this),this.updateUI(this.getElementByLocalId("foreground"),this.getElementByLocalId("minText"),this.getElementByLocalId("maxText"))},e.prototype.renderInner=function(t){var n=this.cfg,i=n.start,a=n.end,o=n.width,s=n.height,l=n.trendCfg,u=l===void 0?{}:l,c=n.minText,h=n.maxText,v=n.backgroundStyle,d=v===void 0?{}:v,g=n.foregroundStyle,y=g===void 0?{}:g,x=n.textStyle,m=x===void 0?{}:x,M=(0,f.b$)({},Sh,this.cfg.handlerStyle),w=i*o,S=a*o;(0,f.dp)((0,f.U2)(u,"data"))&&(this.trend=this.addComponent(t,(0,p.pi)({component:O1,id:this.getElementId("trend"),x:0,y:0,width:o,height:s},u))),this.addShape(t,{id:this.getElementId("background"),type:"rect",attrs:(0,p.pi)({x:0,y:0,width:o,height:s},d)});var b=this.addShape(t,{id:this.getElementId("minText"),type:"text",attrs:(0,p.pi)({y:s/2,textAlign:"right",text:c,silent:!1},m)}),k=this.addShape(t,{id:this.getElementId("maxText"),type:"text",attrs:(0,p.pi)({y:s/2,textAlign:"left",text:h,silent:!1},m)}),H=this.addShape(t,{id:this.getElementId("foreground"),name:"foreground",type:"rect",attrs:(0,p.pi)({y:0,height:s},y)}),at=(0,f.U2)(M,"width",ls),At=(0,f.U2)(M,"height",24);this.minHandler=this.addComponent(t,{component:Ch,id:this.getElementId("minHandler"),name:"handler-min",x:0,y:(s-At)/2,width:at,height:At,cursor:"ew-resize",style:M}),this.maxHandler=this.addComponent(t,{component:Ch,id:this.getElementId("maxHandler"),name:"handler-max",x:0,y:(s-At)/2,width:at,height:At,cursor:"ew-resize",style:M})},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.updateUI=function(t,n,i){var a=this.cfg,o=a.start,s=a.end,l=a.width,u=a.minText,c=a.maxText,h=a.handlerStyle,v=a.height,d=o*l,g=s*l;this.trend&&(this.trend.update({width:l,height:v}),this.get("updateAutoRender")||this.trend.render()),t.attr("x",d),t.attr("width",g-d);var y=(0,f.U2)(h,"width",ls);n.attr("text",u),i.attr("text",c);var x=this._dodgeText([d,g],n,i),m=x[0],M=x[1];this.minHandler&&(this.minHandler.update({x:d-y/2}),this.get("updateAutoRender")||this.minHandler.render()),(0,f.S6)(m,function(w,S){return n.attr(S,w)}),this.maxHandler&&(this.maxHandler.update({x:g-y/2}),this.get("updateAutoRender")||this.maxHandler.render()),(0,f.S6)(M,function(w,S){return i.attr(S,w)})},e.prototype.bindEvents=function(){var t=this.get("group");t.on("handler-min:mousedown",this.onMouseDown("minHandler")),t.on("handler-min:touchstart",this.onMouseDown("minHandler")),t.on("handler-max:mousedown",this.onMouseDown("maxHandler")),t.on("handler-max:touchstart",this.onMouseDown("maxHandler"));var n=t.findById(this.getElementId("foreground"));n.on("mousedown",this.onMouseDown("foreground")),n.on("touchstart",this.onMouseDown("foreground"))},e.prototype.adjustOffsetRange=function(t){var n=this.cfg,i=n.start,a=n.end;switch(this.currentTarget){case"minHandler":{var o=0-i,s=1-i;return Math.min(s,Math.max(o,t))}case"maxHandler":{var o=0-a,s=1-a;return Math.min(s,Math.max(o,t))}case"foreground":{var o=0-i,s=1-a;return Math.min(s,Math.max(o,t))}}},e.prototype.updateStartEnd=function(t){var n=this.cfg,i=n.start,a=n.end;switch(this.currentTarget){case"minHandler":i+=t;break;case"maxHandler":a+=t;break;case"foreground":i+=t,a+=t;break}this.set("start",i),this.set("end",a)},e.prototype._dodgeText=function(t,n,i){var a,o,s=this.cfg,l=s.handlerStyle,u=s.width,c=2,h=(0,f.U2)(l,"width",ls),v=t[0],d=t[1],g=!1;v>d&&(a=[d,v],v=a[0],d=a[1],o=[i,n],n=o[0],i=o[1],g=!0);var y=n.getBBox(),x=i.getBBox(),m=y.width>v-c?{x:v+h/2+c,textAlign:"left"}:{x:v-h/2-c,textAlign:"right"},M=x.width>u-d-c?{x:d-h/2-c,textAlign:"right"}:{x:d+h/2+c,textAlign:"left"};return g?[M,m]:[m,M]},e.prototype.draw=function(){var t=this.get("container"),n=t&&t.get("canvas");n&&n.draw()},e.prototype.getContainerDOM=function(){var t=this.get("container"),n=t&&t.get("canvas");return n&&n.get("container")},e}(Ar),A6=null;function ra(r,e,t){if(r){if(typeof r.addEventListener=="function")return r.addEventListener(e,t,!1),{remove:function(){r.removeEventListener(e,t,!1)}};if(typeof r.attachEvent=="function")return r.attachEvent("on"+e,t),{remove:function(){r.detachEvent("on"+e,t)}}}}var V1={trackColor:"rgba(0,0,0,0)",thumbColor:"rgba(0,0,0,0.15)",size:8,lineCap:"round"},mu={default:V1,hover:{thumbColor:"rgba(0,0,0,0.2)"}},H1=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.clearEvents=f.ZT,t.onStartEvent=function(n){return function(i){t.isMobile=n,i.originalEvent.preventDefault();var a=n?(0,f.U2)(i.originalEvent,"touches.0.clientX"):i.clientX,o=n?(0,f.U2)(i.originalEvent,"touches.0.clientY"):i.clientY;t.startPos=t.cfg.isHorizontal?a:o,t.bindLaterEvent()}},t.bindLaterEvent=function(){var n=t.getContainerDOM(),i=[];t.isMobile?i=[ra(n,"touchmove",t.onMouseMove),ra(n,"touchend",t.onMouseUp),ra(n,"touchcancel",t.onMouseUp)]:i=[ra(n,"mousemove",t.onMouseMove),ra(n,"mouseup",t.onMouseUp),ra(n,"mouseleave",t.onMouseUp)],t.clearEvents=function(){i.forEach(function(a){a.remove()})}},t.onMouseMove=function(n){var i=t.cfg,a=i.isHorizontal,o=i.thumbOffset;n.preventDefault();var s=t.isMobile?(0,f.U2)(n,"touches.0.clientX"):n.clientX,l=t.isMobile?(0,f.U2)(n,"touches.0.clientY"):n.clientY,u=a?s:l,c=u-t.startPos;t.startPos=u,t.updateThumbOffset(o+c)},t.onMouseUp=function(n){n.preventDefault(),t.clearEvents()},t.onTrackClick=function(n){var i=t.cfg,a=i.isHorizontal,o=i.x,s=i.y,l=i.thumbLen,u=t.getContainerDOM(),c=u.getBoundingClientRect(),h=n.clientX,v=n.clientY,d=a?h-c.left-o-l/2:v-c.top-s-l/2,g=t.validateRange(d);t.updateThumbOffset(g)},t.onThumbMouseOver=function(){var n=t.cfg.theme.hover.thumbColor;t.getElementByLocalId("thumb").attr("stroke",n),t.draw()},t.onThumbMouseOut=function(){var n=t.cfg.theme.default.thumbColor;t.getElementByLocalId("thumb").attr("stroke",n),t.draw()},t}return e.prototype.setRange=function(t,n){this.set("minLimit",t),this.set("maxLimit",n);var i=this.getValue(),a=(0,f.uZ)(i,t,n);i!==a&&!this.get("isInit")&&this.setValue(a)},e.prototype.getRange=function(){var t=this.get("minLimit")||0,n=this.get("maxLimit")||1;return{min:t,max:n}},e.prototype.setValue=function(t){var n=this.getRange(),i=this.getValue();this.update({thumbOffset:(this.get("trackLen")-this.get("thumbLen"))*(0,f.uZ)(t,n.min,n.max)}),this.delegateEmit("valuechange",{originalValue:i,value:this.getValue()})},e.prototype.getValue=function(){return(0,f.uZ)(this.get("thumbOffset")/(this.get("trackLen")-this.get("thumbLen")),0,1)},e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return(0,p.pi)((0,p.pi)({},t),{name:"scrollbar",isHorizontal:!0,minThumbLen:20,thumbOffset:0,theme:mu})},e.prototype.renderInner=function(t){this.renderTrackShape(t),this.renderThumbShape(t)},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.renderTrackShape=function(t){var n=this.cfg,i=n.trackLen,a=n.theme,o=a===void 0?{default:{}}:a,s=(0,f.b$)({},mu,o).default,l=s.lineCap,u=s.trackColor,c=s.size,h=(0,f.U2)(this.cfg,"size",c),v=this.get("isHorizontal")?{x1:0+h/2,y1:h/2,x2:i-h/2,y2:h/2,lineWidth:h,stroke:u,lineCap:l}:{x1:h/2,y1:0+h/2,x2:h/2,y2:i-h/2,lineWidth:h,stroke:u,lineCap:l};return this.addShape(t,{id:this.getElementId("track"),name:"track",type:"line",attrs:v})},e.prototype.renderThumbShape=function(t){var n=this.cfg,i=n.thumbOffset,a=n.thumbLen,o=n.theme,s=(0,f.b$)({},mu,o).default,l=s.size,u=s.lineCap,c=s.thumbColor,h=(0,f.U2)(this.cfg,"size",l),v=this.get("isHorizontal")?{x1:i+h/2,y1:h/2,x2:i+a-h/2,y2:h/2,lineWidth:h,stroke:c,lineCap:u,cursor:"default"}:{x1:h/2,y1:i+h/2,x2:h/2,y2:i+a-h/2,lineWidth:h,stroke:c,lineCap:u,cursor:"default"};return this.addShape(t,{id:this.getElementId("thumb"),name:"thumb",type:"line",attrs:v})},e.prototype.bindEvents=function(){var t=this.get("group");t.on("mousedown",this.onStartEvent(!1)),t.on("mouseup",this.onMouseUp),t.on("touchstart",this.onStartEvent(!0)),t.on("touchend",this.onMouseUp);var n=t.findById(this.getElementId("track"));n.on("click",this.onTrackClick);var i=t.findById(this.getElementId("thumb"));i.on("mouseover",this.onThumbMouseOver),i.on("mouseout",this.onThumbMouseOut)},e.prototype.getContainerDOM=function(){var t=this.get("container"),n=t&&t.get("canvas");return n&&n.get("container")},e.prototype.validateRange=function(t){var n=this.cfg,i=n.thumbLen,a=n.trackLen,o=t;return t+i>a?o=a-i:t+i<i&&(o=0),o},e.prototype.draw=function(){var t=this.get("container"),n=t&&t.get("canvas");n&&n.draw()},e.prototype.updateThumbOffset=function(t){var n=this.cfg,i=n.thumbOffset,a=n.isHorizontal,o=n.thumbLen,s=n.size,l=this.validateRange(t);if(l!==i){var u=this.getElementByLocalId("thumb");a?u.attr({x1:l+s/2,x2:l+o-s/2}):u.attr({y1:l+s/2,y2:l+o-s/2}),this.emitOffsetChange(l)}},e.prototype.emitOffsetChange=function(t){var n=this.cfg,i=n.thumbOffset,a=n.trackLen,o=n.thumbLen;this.cfg.thumbOffset=t,this.emit("scrollchange",{thumbOffset:t,ratio:(0,f.uZ)(t/(a-o),0,1)}),this.delegateEmit("valuechange",{originalValue:i,value:t})},e}(Ar),G1=Ix,Y1=Lx,X1=Xx,W1=Gx,Ah=$x,Z1=jx,us=i1;function $1(r){if((0,f.xb)(r))return null;var e=r[0].x,t=r[0].x,n=r[0].y,i=r[0].y;return(0,f.S6)(r,function(a){e=e>a.x?a.x:e,t=t<a.x?a.x:t,n=n>a.y?a.y:n,i=i<a.y?a.y:i}),{minX:e,maxX:t,minY:n,maxY:i,centerX:(e+t)/2,centerY:(n+i)/2}}function bh(r){return Array.from(new Set(r)).length===1}function Th(r){return((0,f.VV)(r)+(0,f.Fp)(r))/2}function hr(r,e,t,n){return{x:r+t*Math.cos(n),y:e+t*Math.sin(n)}}function Qn(r,e,t,n,i,a){a===void 0&&(a=0);var o=hr(r,e,t,n),s=hr(r,e,t,i),l=hr(r,e,a,n),u=hr(r,e,a,i);if(i-n==Math.PI*2){var c=hr(r,e,t,n+Math.PI),h=hr(r,e,a,n+Math.PI),v=[["M",o.x,o.y],["A",t,t,0,1,1,c.x,c.y],["A",t,t,0,1,1,s.x,s.y],["M",l.x,l.y]];return a&&(v.push(["A",a,a,0,1,0,h.x,h.y]),v.push(["A",a,a,0,1,0,u.x,u.y])),v.push(["M",o.x,o.y]),v.push(["Z"]),v}var d=i-n<=Math.PI?0:1,g=[["M",o.x,o.y],["A",t,t,0,d,1,s.x,s.y],["L",u.x,u.y]];return a&&g.push(["A",a,a,0,d,0,l.x,l.y]),g.push(["L",o.x,o.y]),g.push(["Z"]),g}function Eh(r,e,t,n,i){var a=hr(r,e,t,n),o=hr(r,e,t,i);if((0,f.vQ)(i-n,Math.PI*2)){var s=hr(r,e,t,n+Math.PI);return[["M",a.x,a.y],["A",t,t,0,1,1,s.x,s.y],["A",t,t,0,1,1,a.x,a.y],["A",t,t,0,1,0,s.x,s.y],["A",t,t,0,1,0,a.x,a.y],["Z"]]}var l=i-n<=Math.PI?0:1;return[["M",a.x,a.y],["A",t,t,0,l,1,o.x,o.y]]}function Za(r,e){var t=r.points,n=$1(t),i,a,o=e.startAngle,s=e.endAngle,l=s-o;return e.isTransposed?(i=n.maxY*l,a=n.minY*l):(i=n.maxX*l,a=n.minX*l),i+=o,a+=o,{startAngle:a,endAngle:i}}function q1(r,e){if((0,f.hj)(r)&&(0,f.hj)(e))return[r,e];if(r=r,e=e,bh(r)||bh(e))return[Th(r),Th(e)];for(var t=-1,n=0,i=0,a,o=r.length-1,s,l=0;++t<r.length;)a=o,o=t,l+=s=r[a]*e[o]-r[o]*e[a],n+=(r[a]+r[o])*s,i+=(e[a]+e[o])*s;return l*=3,[n/l,i/l]}function _h(r,e){var t=r.attr(),n=e.attr();return(0,f.S6)(t,function(i,a){n[a]===void 0&&(n[a]=void 0)}),n}function na(r,e,t){var n=Math.min(e,t),i=Math.max(e,t);return r>=n&&r<=i}function K1(r,e,t){if((0,f.HD)(r))return r.padEnd(e,t);if((0,f.kJ)(r)){var n=r.length;if(n<e)for(var i=e-n,a=0;a<i;a++)r.push(t)}return r}function Nr(r,e){return typeof r=="object"&&e.forEach(function(t){delete r[t]}),r}function ti(r,e,t){var n,i;e===void 0&&(e=[]),t===void 0&&(t=new Map);try{for(var a=(0,p.XA)(r),o=a.next();!o.done;o=a.next()){var s=o.value;t.has(s)||(e.push(s),t.set(s,!0))}}catch(l){n={error:l}}finally{try{o&&!o.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}return e}var Ir=function(){function r(e,t,n,i){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0),i===void 0&&(i=0),this.x=e,this.y=t,this.height=i,this.width=n}return r.fromRange=function(e,t,n,i){return new r(e,t,n-e,i-t)},r.fromObject=function(e){return new r(e.minX,e.minY,e.width,e.height)},Object.defineProperty(r.prototype,"minX",{get:function(){return this.x},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"maxX",{get:function(){return this.x+this.width},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"minY",{get:function(){return this.y},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"maxY",{get:function(){return this.y+this.height},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"tl",{get:function(){return{x:this.x,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"tr",{get:function(){return{x:this.maxX,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"bl",{get:function(){return{x:this.x,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"br",{get:function(){return{x:this.maxX,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"top",{get:function(){return{x:this.x+this.width/2,y:this.minY}},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"right",{get:function(){return{x:this.maxX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"bottom",{get:function(){return{x:this.x+this.width/2,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"left",{get:function(){return{x:this.minX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),r.prototype.isEqual=function(e){return this.x===e.x&&this.y===e.y&&this.width===e.width&&this.height===e.height},r.prototype.contains=function(e){return e.minX>=this.minX&&e.maxX<=this.maxX&&e.minY>=this.minY&&e.maxY<=this.maxY},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.add=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=this.clone();return(0,f.S6)(e,function(i){n.x=Math.min(i.x,n.x),n.y=Math.min(i.y,n.y),n.width=Math.max(i.maxX,n.maxX)-n.x,n.height=Math.max(i.maxY,n.maxY)-n.y}),n},r.prototype.merge=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=this.clone();return(0,f.S6)(e,function(i){n.x=Math.max(i.x,n.x),n.y=Math.max(i.y,n.y),n.width=Math.min(i.maxX,n.maxX)-n.x,n.height=Math.min(i.maxY,n.maxY)-n.y}),n},r.prototype.cut=function(e,t){var n=e.width,i=e.height;switch(t){case K.TOP:case K.TOP_LEFT:case K.TOP_RIGHT:return r.fromRange(this.minX,this.minY+i,this.maxX,this.maxY);case K.RIGHT:case K.RIGHT_TOP:case K.RIGHT_BOTTOM:return r.fromRange(this.minX,this.minY,this.maxX-n,this.maxY);case K.BOTTOM:case K.BOTTOM_LEFT:case K.BOTTOM_RIGHT:return r.fromRange(this.minX,this.minY,this.maxX,this.maxY-i);case K.LEFT:case K.LEFT_TOP:case K.LEFT_BOTTOM:return r.fromRange(this.minX+n,this.minY,this.maxX,this.maxY);default:return this}},r.prototype.shrink=function(e){var t=(0,p.CR)(e,4),n=t[0],i=t[1],a=t[2],o=t[3];return new r(this.x+o,this.y+n,this.width-o-i,this.height-n-a)},r.prototype.expand=function(e){var t=(0,p.CR)(e,4),n=t[0],i=t[1],a=t[2],o=t[3];return new r(this.x-o,this.y-n,this.width+o+i,this.height+n+a)},r.prototype.exceed=function(e){return[Math.max(-this.minY+e.minY,0),Math.max(this.maxX-e.maxX,0),Math.max(this.maxY-e.maxY,0),Math.max(-this.minX+e.minX,0)]},r.prototype.collide=function(e){return this.minX<e.maxX&&this.maxX>e.minX&&this.minY<e.maxY&&this.maxY>e.minY},r.prototype.size=function(){return this.width*this.height},r.prototype.isPointIn=function(e){return e.x>=this.minX&&e.x<=this.maxX&&e.y>=this.minY&&e.y<=this.maxY},r}(),b6=function(r,e){var t=e.start,n=e.end;return new Ir(r.x+r.width*t.x,r.y+r.height*t.y,r.width*Math.abs(n.x-t.x),r.height*Math.abs(n.y-t.y))};function j1(r){return[[r.minX,r.minY],[r.maxX,r.minY],[r.maxX,r.maxY],[r.minX,r.maxY]]}function $a(r){if(r.isPolar&&!r.isTransposed)return(r.endAngle-r.startAngle)*r.getRadius();var e=r.convert({x:0,y:0}),t=r.convert({x:1,y:0});return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}function J1(r){if(r.isPolar){var e=r.startAngle,t=r.endAngle;return t-e==Math.PI*2}return!1}function cs(r,e){var t=r.getCenter();return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function Q1(r,e){var t=!1;if(r)if(r.type==="theta"){var n=r.start,i=r.end;t=na(e.x,n.x,i.x)&&na(e.y,n.y,i.y)}else{var a=r.invert(e);t=na(a.x,0,1)&&na(a.y,0,1)}return t}function ia(r,e){var t=r.getCenter();return Math.atan2(e.y-t.y,e.x-t.x)}function xu(r,e){e===void 0&&(e=0);var t=r.start,n=r.end,i=r.getWidth(),a=r.getHeight();if(r.isPolar){var o=r.startAngle,s=r.endAngle,l=r.getCenter(),u=r.getRadius();return{type:"path",startState:{path:Qn(l.x,l.y,u+e,o,o)},endState:function(h){var v=(s-o)*h+o,d=Qn(l.x,l.y,u+e,o,v);return{path:d}},attrs:{path:Qn(l.x,l.y,u+e,o,s)}}}var c;return r.isTransposed?c={height:a+e*2}:c={width:i+e*2},{type:"rect",startState:{x:t.x-e,y:n.y-e,width:r.isTransposed?i+e*2:0,height:r.isTransposed?0:a+e*2},endState:c,attrs:{x:t.x-e,y:n.y-e,width:i+e*2,height:a+e*2}}}function tM(r,e){e===void 0&&(e=0);var t=r.start,n=r.end,i=r.getWidth(),a=r.getHeight(),o=Math.min(t.x,n.x),s=Math.min(t.y,n.y);return Ir.fromRange(o-e,s-e,o+i+e,s+a+e)}var eM=/^(?:(?!0000)[0-9]{4}([-/.]+)(?:(?:0?[1-9]|1[0-2])\1(?:0?[1-9]|1[0-9]|2[0-8])|(?:0?[13-9]|1[0-2])\1(?:29|30)|(?:0?[13578]|1[02])\1(?:31))|(?:[0-9]{2}(?:0[48]|[2468][048]|[13579][26])|(?:0[48]|[2468][048]|[13579][26])00)([-/.]+)0?2\2(?:29))(\s+([01]|([01][0-9]|2[0-3])):([0-9]|[0-5][0-9]):([0-9]|[0-5][0-9]))?$/;function rM(r){var e="linear";return eM.test(r)?e="timeCat":(0,f.HD)(r)&&(e="cat"),e}function Fh(r,e,t,n){return e===void 0&&(e={}),e.type?e.type:r.type!=="identity"&&jt.includes(t)&&["interval"].includes(n)||r.isCategory?"cat":r.type}function nM(r,e,t){var n=e||[];if((0,f.hj)(r)||(0,f.UM)((0,f.Wx)(n,r))&&(0,f.xb)(t)){var i=rt("identity");return new i({field:r.toString(),values:[r]})}var a=(0,f.I)(n,r),o=(0,f.U2)(t,"type",rM(a[0])),s=rt(o);return new s((0,p.pi)({field:r,values:a},t))}function iM(r,e){if(r.type!=="identity"&&e.type!=="identity"){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);r.change(t)}}function qa(r){return r.alias||r.field}function Ih(r,e,t){var n=r.values,i=n.length,a;if(i===1)a=[.5,1];else{var o=1,s=0;J1(e)?e.isTransposed?(o=(0,f.U2)(t,"widthRatio.multiplePie",1/1.3),s=1/i*o,a=[s/2,1-s/2]):a=[0,1-1/i]:(s=1/i/2,a=[s,1-s])}return a}function aM(r){var e=r.values.filter(function(t){return!(0,f.UM)(t)&&!isNaN(t)});return Math.max.apply(Math,(0,p.ev)((0,p.ev)([],(0,p.CR)(e),!1),[(0,f.UM)(r.max)?-Infinity:r.max],!1))}function oM(r){var e,t;switch(r){case K.TOP:e={x:0,y:1},t={x:1,y:1};break;case K.RIGHT:e={x:1,y:0},t={x:1,y:1};break;case K.BOTTOM:e={x:0,y:0},t={x:1,y:0};break;case K.LEFT:e={x:0,y:0},t={x:0,y:1};break;default:e=t={x:0,y:0}}return{start:e,end:t}}function sM(r){var e,t;return r.isTransposed?(e={x:0,y:0},t={x:1,y:0}):(e={x:0,y:0},t={x:0,y:1}),{start:e,end:t}}function fs(r,e){var t={start:{x:0,y:0},end:{x:0,y:0}};r.isRect?t=oM(e):r.isPolar&&(t=sM(r));var n=t.start,i=t.end;return{start:r.convert(n),end:r.convert(i)}}function T6(r,e){if(r.isRect)return r.isTransposed?[DIRECTION.RIGHT,DIRECTION.BOTTOM].includes(e)?1:-1:[DIRECTION.BOTTOM,DIRECTION.RIGHT].includes(e)?-1:1;if(r.isPolar){var t=r.x.start;return t<0?-1:1}return 1}function Ph(r){var e=r.start,t=r.end;return e.x===t.x}function Lh(r,e){var t=r.start,n=r.end,i=Ph(r);return i?(t.y-n.y)*(e.x-t.x)>0?1:-1:(n.x-t.x)*(t.y-e.y)>0?-1:1}function hs(r,e){var t=(0,f.U2)(r,["components","axis"],{});return(0,f.b$)({},(0,f.U2)(t,["common"],{}),(0,f.b$)({},(0,f.U2)(t,[e],{})))}function Dh(r,e,t){var n=(0,f.U2)(r,["components","axis"],{});return(0,f.b$)({},(0,f.U2)(n,["common","title"],{}),(0,f.b$)({},(0,f.U2)(n,[e,"title"],{})),t)}function Mu(r){var e=r.x,t=r.y,n=r.circleCenter,i=t.start>t.end,a=r.isTransposed?r.convert({x:i?0:1,y:0}):r.convert({x:0,y:i?0:1}),o=[a.x-n.x,a.y-n.y],s=[1,0],l=a.y>n.y?xe.EU(o,s):xe.EU(o,s)*-1,u=l+(e.end-e.start),c=Math.sqrt(Math.pow(a.x-n.x,2)+Math.pow(a.y-n.y,2));return{center:n,radius:c,startAngle:l,endAngle:u}}function vs(r,e){return(0,f.jn)(r)?r===!1?!1:{}:(0,f.U2)(r,[e])}function Oh(r,e){return(0,f.U2)(r,"position",e)}function kh(r,e){return(0,f.U2)(e,["title","text"],qa(r))}var aa=function(){function r(e,t){this.destroyed=!1,this.facets=[],this.view=e,this.cfg=(0,f.b$)({},this.getDefaultCfg(),t)}return r.prototype.init=function(){this.container||(this.container=this.createContainer());var e=this.view.getData();this.facets=this.generateFacets(e)},r.prototype.render=function(){this.renderViews()},r.prototype.update=function(){},r.prototype.clear=function(){this.clearFacetViews()},r.prototype.destroy=function(){this.clear(),this.container&&(this.container.remove(!0),this.container=void 0),this.destroyed=!0,this.view=void 0,this.facets=[]},r.prototype.facetToView=function(e){var t=e.region,n=e.data,i=e.padding,a=i===void 0?this.cfg.padding:i,o=this.view.createView({region:t,padding:a});o.data(n||[]),e.view=o,this.beforeEachView(o,e);var s=this.cfg.eachView;return s&&s(o,e),this.afterEachView(o,e),o},r.prototype.createContainer=function(){var e=this.view.getLayer(J.FORE);return e.addGroup()},r.prototype.renderViews=function(){this.createFacetViews()},r.prototype.createFacetViews=function(){var e=this;return this.facets.map(function(t){return e.facetToView(t)})},r.prototype.clearFacetViews=function(){var e=this;(0,f.S6)(this.facets,function(t){t.view&&(e.view.removeView(t.view),t.view=void 0)})},r.prototype.parseSpacing=function(){var e=this.view.viewBBox,t=e.width,n=e.height,i=this.cfg.spacing;return i.map(function(a,o){return(0,f.hj)(a)?a/(o===0?t:n):parseFloat(a)/100})},r.prototype.getFieldValues=function(e,t){var n=[],i={};return(0,f.S6)(e,function(a){var o=a[t];!(0,f.UM)(o)&&!i[o]&&(n.push(o),i[o]=!0)}),n},r.prototype.getRegion=function(e,t,n,i){var a=(0,p.CR)(this.parseSpacing(),2),o=a[0],s=a[1],l=(1+o)/(t===0?1:t)-o,u=(1+s)/(e===0?1:e)-s,c={x:(l+o)*n,y:(u+s)*i},h={x:c.x+l,y:c.y+u};return{start:c,end:h}},r.prototype.getDefaultCfg=function(){return{eachView:void 0,showTitle:!0,spacing:[0,0],padding:10,fields:[]}},r.prototype.getDefaultTitleCfg=function(){var e=this.view.getTheme().fontFamily;return{style:{fontSize:14,fill:"#666",fontFamily:e}}},r.prototype.processAxis=function(e,t){var n=e.getOptions(),i=n.coordinate,a=e.geometries,o=(0,f.U2)(i,"type","rect");if(o==="rect"&&a.length){(0,f.UM)(n.axes)&&(n.axes={});var s=n.axes,l=(0,p.CR)(a[0].getXYFields(),2),u=l[0],c=l[1],h=vs(s,u),v=vs(s,c);h!==!1&&(n.axes[u]=this.getXAxisOption(u,s,h,t)),v!==!1&&(n.axes[c]=this.getYAxisOption(c,s,v,t))}},r.prototype.getFacetDataFilter=function(e){return function(t){return(0,f.yW)(e,function(n){var i=n.field,a=n.value;return!(0,f.UM)(a)&&i?t[i]===a:!0})}},r}(),Bh={},lM=function(r){return Bh[(0,f.vl)(r)]},oa=function(r,e){Bh[(0,f.vl)(r)]=e},uM=function(){function r(e,t){this.context=e,this.cfg=t,e.addAction(this)}return r.prototype.applyCfg=function(e){(0,f.f0)(this,e)},r.prototype.init=function(){this.applyCfg(this.cfg)},r.prototype.destroy=function(){this.context.removeAction(this),this.context=null},r}(),ar=uM,cM=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.execute=function(){this.callback&&this.callback(this.context)},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.callback=null},e}(ar),fM=cM,ds={};function hM(r,e){var t=ds[r],n=null;if(t){var i=t.ActionClass,a=t.cfg;n=new i(e,a),n.name=r,n.init()}return n}function ps(r){var e=ds[r];return(0,f.U2)(e,"ActionClass")}function Te(r,e,t){ds[r]={ActionClass:e,cfg:t}}function E6(r){delete ds[r]}function vM(r,e){var t=new fM(e);return t.callback=r,t.name="callback",t}function dM(r,e){var t=[];if(r.length){t.push(["M",r[0].x,r[0].y]);for(var n=1,i=r.length;n<i;n+=1){var a=r[n];t.push(["L",a.x,a.y])}e&&t.push(["Z"])}return t}function wu(r,e){for(var t=[r[0]],n=1,i=r.length;n<i;n=n+2){var a=e.convert({x:r[n],y:r[n+1]});t.push(a.x,a.y)}return t}function Rh(r,e){var t=e.isTransposed,n=r[1],i=r[6],a=r[7],o=e.convert({x:i,y:a}),s=t?0:1;return["A",n,n,0,0,s,o.x,o.y]}function pM(r,e,t){var n=t.isTransposed,i=t.startAngle,a=t.endAngle,o=r[0].toLowerCase()==="a"?{x:r[6],y:r[7]}:{x:r[1],y:r[2]},s={x:e[1],y:e[2]},l=[],u=n?"y":"x",c=Math.abs(s[u]-o[u])*(a-i),h=s[u]>=o[u]?1:0,v=c>Math.PI?1:0,d=t.convert(s),g=cs(t,d);if(g>=.5)if(c===Math.PI*2){var y={x:(s.x+o.x)/2,y:(s.y+o.y)/2},x=t.convert(y);l.push(["A",g,g,0,v,h,x.x,x.y]),l.push(["A",g,g,0,v,h,d.x,d.y])}else l.push(["A",g,g,0,v,h,d.x,d.y]);return l}function gM(r){(0,f.S6)(r,function(e,t){var n=e;if(n[0].toLowerCase()==="a"){var i=r[t-1],a=r[t+1];a&&a[0].toLowerCase()==="a"?i&&i[0].toLowerCase()==="l"&&(i[0]="M"):i&&i[0].toLowerCase()==="a"&&a&&a[0].toLowerCase()==="l"&&(a[0]="M")}})}var yM=function(r,e,t,n){var i,a=[],o=!!n,s,l,u,c,h,v,d;if(o){i=(0,p.CR)(n,2),u=i[0],c=i[1];for(var g=0,y=r.length;g<y;g++){var x=r[g];u=xe.VV([0,0],u,x),c=xe.Fp([0,0],c,x)}}for(var g=0,m=r.length;g<m;g++){var x=r[g];if(g===0&&!t)d=x;else if(g===m-1&&!t)v=x,a.push(d),a.push(v);else{s=r[t?g?g-1:m-1:g-1],l=r[t?(g+1)%m:g+1];var M=[0,0];M=xe.lu(M,l,s),M=xe.bA(M,M,e);var w=xe.TE(x,s),S=xe.TE(x,l),b=w+S;b!==0&&(w/=b,S/=b);var k=xe.bA([0,0],M,-w),H=xe.bA([0,0],M,S);v=xe.IH([0,0],x,k),h=xe.IH([0,0],x,H),h=xe.VV([0,0],h,xe.Fp([0,0],l,x)),h=xe.Fp([0,0],h,xe.VV([0,0],l,x)),k=xe.lu([0,0],h,x),k=xe.bA([0,0],k,-w/S),v=xe.IH([0,0],x,k),v=xe.VV([0,0],v,xe.Fp([0,0],s,x)),v=xe.Fp([0,0],v,xe.VV([0,0],s,x)),H=xe.lu([0,0],x,v),H=xe.bA([0,0],H,S/w),h=xe.IH([0,0],x,H),o&&(v=xe.Fp([0,0],v,u),v=xe.VV([0,0],v,c),h=xe.Fp([0,0],h,u),h=xe.VV([0,0],h,c)),a.push(d),a.push(v),d=h}}return t&&a.push(a.shift()),a};function Nh(r,e,t){for(var n=!!e,i=[],a=0,o=r.length;a<o;a+=2)i.push([r[a],r[a+1]]);for(var s=yM(i,.4,n,t),l=i.length,u=[],c,h,v,a=0;a<l-1;a++)c=s[a*2],h=s[a*2+1],v=i[a+1],u.push(["C",c[0],c[1],h[0],h[1],v[0],v[1]]);return n&&(c=s[l],h=s[l+1],v=i[0],u.push(["C",c[0],c[1],h[0],h[1],v[0],v[1]])),u}function Ka(r,e){return dM(r,e)}function gs(r,e,t){var n=[],i=r[0],a=null;if(r.length<=2)return Ka(r,e);for(var o=0,s=r.length;o<s;o++){var l=r[o];(!a||!(a.x===l.x&&a.y===l.y))&&(n.push(l.x),n.push(l.y),a=l)}var u=t||[[0,0],[1,1]],c=Nh(n,e,u);return c.unshift(["M",i.x,i.y]),c}function mM(r,e){var t=[];return(0,f.S6)(e,function(n){var i=n[0];switch(i.toLowerCase()){case"m":case"l":case"c":t.push(wu(n,r));break;case"a":t.push(Rh(n,r));break;case"z":default:t.push(n);break}}),t}function xM(r,e){var t=[],n,i,a,o;return(0,f.S6)(e,function(s,l){var u=s[0];switch(u.toLowerCase()){case"m":case"c":case"q":t.push(wu(s,r));break;case"l":n=e[l-1],i=s,a=r.isTransposed,o=a?n[n.length-2]===i[1]:n[n.length-1]===i[2],o?t=t.concat(pM(n,i,r)):t.push(wu(s,r));break;case"a":t.push(Rh(s,r));break;case"z":default:t.push(s);break}}),gM(t),t}var MM=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/ig,wM=/[^\s\,]+/ig;function _6(r){var e=r||[];if(isArray(e))return e;if(isString(e))return e=e.match(MM),each(e,function(t,n){if(t=t.match(wM),t[0].length>1){var i=t[0].charAt(0);t.splice(1,0,t[0].substr(1)),t[0]=i}each(t,function(a,o){isNaN(a)||(t[o]=+a)}),e[n]=t}),e}var F6=null;function SM(r,e,t){var n=null,i=t;return e<i&&(i=e,n="add"),r<i&&(i=r,n="del"),{type:n,min:i}}var CM=function(r,e){var t=r.length,n=e.length,i,a,o=0;if(t===0||n===0)return null;for(var s=[],l=0;l<=t;l++)s[l]=[],s[l][0]={min:l};for(var u=0;u<=n;u++)s[0][u]={min:u};for(var l=1;l<=t;l++){i=r[l-1];for(var u=1;u<=n;u++){a=e[u-1],isEqual(i,a)?o=0:o=1;var c=s[l-1][u].min+1,h=s[l][u-1].min+1,v=s[l-1][u-1].min+o;s[l][u]=SM(c,h,v)}}return s};function I6(r,e){var t=CM(r,e),n=r.length,i=e.length,a=[],o=1,s=1;if(t[n][i]!==n){for(var l=1;l<=n;l++){var u=t[l][l].min;s=l;for(var c=o;c<=i;c++)t[l][c].min<u&&(u=t[l][c].min,s=c);o=s,t[l][o].type&&a.push({index:l-1,type:t[l][o].type})}for(var l=a.length-1;l>=0;l--)o=a[l].index,a[l].type==="add"?r.splice(o,0,[].concat(r[o])):r.splice(o,1)}if(n=r.length,n<i)for(var l=0;l<i-n;l++)r[n-1][0]==="z"||r[n-1][0]==="Z"?r.splice(n-2,0,r[n-2]):r.push(r[n-1]);return r}var ja=`
  37. \v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,AM=new RegExp("([a-z])["+ja+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+ja+"]*,?["+ja+"]*)+)","ig"),bM=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+ja+"]*,?["+ja+"]*","ig");function TM(r){if(!r)return null;if((0,f.kJ)(r))return r;var e={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},t=[];return String(r).replace(AM,function(n,i,a){var o=[],s=i.toLowerCase();if(a.replace(bM,function(l,u){u&&o.push(+u)}),s==="m"&&o.length>2&&(t.push([i].concat(o.splice(0,2))),s="l",i=i==="m"?"l":"L"),s==="o"&&o.length===1&&t.push([i,o[0]]),s==="r")t.push([i].concat(o));else for(;o.length>=e[s]&&(t.push([i].concat(o.splice(0,e[s]))),!!e[s]););return""}),t}var EM=/[a-z]/;function Uh(r,e){return[e[0]+(e[0]-r[0]),e[1]+(e[1]-r[1])]}function P6(r){var e=parsePathString(r);if(!e||!e.length)return[["M",0,0]];for(var t=!1,n=0;n<e.length;n++){var i=e[n][0];if(EM.test(i)||["V","H","T","S"].indexOf(i)>=0){t=!0;break}}if(!t)return e;var a=[],o=0,s=0,l=0,u=0,c=0,h,v,d=e[0];(d[0]==="M"||d[0]==="m")&&(o=+d[1],s=+d[2],l=o,u=s,c++,a[0]=["M",o,s]);for(var n=c,g=e.length;n<g;n++){var y=e[n],x=a[n-1],m=[],i=y[0],M=i.toUpperCase();if(i!==M)switch(m[0]=M,M){case"A":m[1]=y[1],m[2]=y[2],m[3]=y[3],m[4]=y[4],m[5]=y[5],m[6]=+y[6]+o,m[7]=+y[7]+s;break;case"V":m[1]=+y[1]+s;break;case"H":m[1]=+y[1]+o;break;case"M":l=+y[1]+o,u=+y[2]+s,m[1]=l,m[2]=u;break;default:for(var w=1,S=y.length;w<S;w++)m[w]=+y[w]+(w%2?o:s)}else m=e[n];switch(M){case"Z":o=+l,s=+u;break;case"H":o=m[1],m=["L",o,s];break;case"V":s=m[1],m=["L",o,s];break;case"T":o=m[1],s=m[2];var b=Uh([x[1],x[2]],[x[3],x[4]]);m=["Q",b[0],b[1],o,s];break;case"S":o=m[m.length-2],s=m[m.length-1];var k=x.length,H=Uh([x[k-4],x[k-3]],[x[k-2],x[k-1]]);m=["C",H[0],H[1],m[1],m[2],o,s];break;case"M":l=m[m.length-2],u=m[m.length-1];break;default:o=m[m.length-2],s=m[m.length-1]}a.push(m)}return a}var Ja=Math.PI*2,Su=function(r,e,t,n,i,a,o){var s=r.x,l=r.y;s*=e,l*=t;var u=n*s-i*l,c=i*s+n*l;return{x:u+a,y:c+o}},_M=function(r,e){var t=e===1.5707963267948966?.551915024494:e===-1.5707963267948966?-.551915024494:4/3*Math.tan(e/4),n=Math.cos(r),i=Math.sin(r),a=Math.cos(r+e),o=Math.sin(r+e);return[{x:n-i*t,y:i+n*t},{x:a+o*t,y:o-a*t},{x:a,y:o}]},zh=function(r,e,t,n){var i=r*n-e*t<0?-1:1,a=r*t+e*n;return a>1&&(a=1),a<-1&&(a=-1),i*Math.acos(a)},FM=function(r,e,t,n,i,a,o,s,l,u,c,h){var v=Math.pow(i,2),d=Math.pow(a,2),g=Math.pow(c,2),y=Math.pow(h,2),x=v*d-v*y-d*g;x<0&&(x=0),x/=v*y+d*g,x=Math.sqrt(x)*(o===s?-1:1);var m=x*i/a*h,M=x*-a/i*c,w=u*m-l*M+(r+t)/2,S=l*m+u*M+(e+n)/2,b=(c-m)/i,k=(h-M)/a,H=(-c-m)/i,at=(-h-M)/a,At=zh(1,0,b,k),gt=zh(b,k,H,at);return s===0&&gt>0&&(gt-=Ja),s===1&&gt<0&&(gt+=Ja),[w,S,At,gt]},IM=function(r){var e=r.px,t=r.py,n=r.cx,i=r.cy,a=r.rx,o=r.ry,s=r.xAxisRotation,l=s===void 0?0:s,u=r.largeArcFlag,c=u===void 0?0:u,h=r.sweepFlag,v=h===void 0?0:h,d=[];if(a===0||o===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];var g=Math.sin(l*Ja/360),y=Math.cos(l*Ja/360),x=y*(e-n)/2+g*(t-i)/2,m=-g*(e-n)/2+y*(t-i)/2;if(x===0&&m===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];a=Math.abs(a),o=Math.abs(o);var M=Math.pow(x,2)/Math.pow(a,2)+Math.pow(m,2)/Math.pow(o,2);M>1&&(a*=Math.sqrt(M),o*=Math.sqrt(M));var w=FM(e,t,n,i,a,o,c,v,g,y,x,m),S=w[0],b=w[1],k=w[2],H=w[3],at=Math.abs(H)/(Ja/4);Math.abs(1-at)<1e-7&&(at=1);var At=Math.max(Math.ceil(at),1);H/=At;for(var gt=0;gt<At;gt++)d.push(_M(k,H)),k+=H;return d.map(function(Nt){var te=Su(Nt[0],a,o,y,g,S,b),ce=te.x,Me=te.y,be=Su(Nt[1],a,o,y,g,S,b),Gt=be.x,ie=be.y,de=Su(Nt[2],a,o,y,g,S,b),ue=de.x,pe=de.y;return{x1:ce,y1:Me,x2:Gt,y2:ie,x:ue,y:pe}})};function L6(r,e,t,n,i,a,o,s,l){var u=IM({px:r,py:e,cx:s,cy:l,rx:t,ry:n,xAxisRotation:i,largeArcFlag:a,sweepFlag:o});return u.reduce(function(c,h){var v=h.x1,d=h.y1,g=h.x2,y=h.y2,x=h.x,m=h.y;return c.push(v,d,g,y,x,m),c},[])}function D6(r,e){"TQ".indexOf(r[0])<0&&(e.qx=null,e.qy=null);var t=r.slice(1),n=t[0],i=t[1];switch(r[0]){case"M":return e.x=n,e.y=i,r;case"A":return["C"].concat(arcToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"Q":return e.qx=n,e.qy=i,["C"].concat(quadToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"L":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],r[2]));case"H":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],e.y1));case"V":return["C"].concat(lineToCubic(e.x1,e.y1,e.x1,r[1]));case"Z":return["C"].concat(lineToCubic(e.x1,e.y1,e.x,e.y));default:}return r}function O6(r,e){e===void 0&&(e=!1);for(var t=path2Absolute(r),n={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null},i=[],a="",o=t.length,s,l,u=[],c=0;c<o;c+=1)t[c]&&(a=t[c][0]),i[c]=a,t[c]=segmentToCubic(t[c],n),PM(t,i,c),o=t.length,a==="Z"&&u.push(c),s=t[c],l=s.length,n.x1=+s[l-2],n.y1=+s[l-1],n.x2=+s[l-4]||n.x1,n.y2=+s[l-3]||n.y1;return e?[t,u]:t}function PM(r,e,t){if(r[t].length>7){r[t].shift();for(var n=r[t],i=t;n.length;)e[t]="A",r.splice(i+=1,0,["C"].concat(n.splice(0,6)));r.splice(t,1)}}var Vh=function(r,e,t,n,i){var a=-3*e+9*t-9*n+3*i,o=r*a+6*e-12*t+6*n;return r*o-3*e+3*t},Hh=function(r,e,t,n,i,a,o,s,l){l===null&&(l=1),l=l>1?1:l<0?0:l;for(var u=l/2,c=12,h=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],v=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],d=0,g=0;g<c;g++){var y=u*h[g]+u,x=Vh(y,r,t,i,o),m=Vh(y,e,n,a,s),M=x*x+m*m;d+=v[g]*Math.sqrt(M)}return u*d},LM=function(r,e,t,n,i,a,o,s){for(var l=[],u=[[],[]],c,h,v,d,g=0;g<2;++g){if(g===0?(h=6*r-12*t+6*i,c=-3*r+9*t-9*i+3*o,v=3*t-3*r):(h=6*e-12*n+6*a,c=-3*e+9*n-9*a+3*s,v=3*n-3*e),Math.abs(c)<1e-12){if(Math.abs(h)<1e-12)continue;d=-v/h,d>0&&d<1&&l.push(d);continue}var y=h*h-4*v*c,x=Math.sqrt(y);if(!(y<0)){var m=(-h+x)/(2*c);m>0&&m<1&&l.push(m);var M=(-h-x)/(2*c);M>0&&M<1&&l.push(M)}}for(var w=l.length,S=w,b;w--;)d=l[w],b=1-d,u[0][w]=b*b*b*r+3*b*b*d*t+3*b*d*d*i+d*d*d*o,u[1][w]=b*b*b*e+3*b*b*d*n+3*b*d*d*a+d*d*d*s;return u[0][S]=r,u[1][S]=e,u[0][S+1]=o,u[1][S+1]=s,u[0].length=u[1].length=S+2,{min:{x:Math.min.apply(0,u[0]),y:Math.min.apply(0,u[1])},max:{x:Math.max.apply(0,u[0]),y:Math.max.apply(0,u[1])}}},DM=function(r,e,t,n,i,a,o,s){if(!(Math.max(r,t)<Math.min(i,o)||Math.min(r,t)>Math.max(i,o)||Math.max(e,n)<Math.min(a,s)||Math.min(e,n)>Math.max(a,s))){var l=(r*n-e*t)*(i-o)-(r-t)*(i*s-a*o),u=(r*n-e*t)*(a-s)-(e-n)*(i*s-a*o),c=(r-t)*(a-s)-(e-n)*(i-o);if(!!c){var h=l/c,v=u/c,d=+h.toFixed(2),g=+v.toFixed(2);if(!(d<+Math.min(r,t).toFixed(2)||d>+Math.max(r,t).toFixed(2)||d<+Math.min(i,o).toFixed(2)||d>+Math.max(i,o).toFixed(2)||g<+Math.min(e,n).toFixed(2)||g>+Math.max(e,n).toFixed(2)||g<+Math.min(a,s).toFixed(2)||g>+Math.max(a,s).toFixed(2)))return{x:h,y:v}}}},ei=function(r,e,t){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height},Cu=function(r,e,t,n){return r===null&&(r=e=t=n=0),e===null&&(e=r.y,t=r.width,n=r.height,r=r.x),{x:r,y:e,width:t,w:t,height:n,h:n,x2:r+t,y2:e+n,cx:r+t/2,cy:e+n/2,r1:Math.min(t,n)/2,r2:Math.max(t,n)/2,r0:Math.sqrt(t*t+n*n)/2,path:rectPath(r,e,t,n),vb:[r,e,t,n].join(" ")}},OM=function(r,e){return r=Cu(r),e=Cu(e),ei(e,r.x,r.y)||ei(e,r.x2,r.y)||ei(e,r.x,r.y2)||ei(e,r.x2,r.y2)||ei(r,e.x,e.y)||ei(r,e.x2,e.y)||ei(r,e.x,e.y2)||ei(r,e.x2,e.y2)||(r.x<e.x2&&r.x>e.x||e.x<r.x2&&e.x>r.x)&&(r.y<e.y2&&r.y>e.y||e.y<r.y2&&e.y>r.y)},Gh=function(r,e,t,n,i,a,o,s){isArray(r)||(r=[r,e,t,n,i,a,o,s]);var l=LM.apply(null,r);return Cu(l.min.x,l.min.y,l.max.x-l.min.x,l.max.y-l.min.y)},Yh=function(r,e,t,n,i,a,o,s,l){var u=1-l,c=Math.pow(u,3),h=Math.pow(u,2),v=l*l,d=v*l,g=c*r+h*3*l*t+u*3*l*l*i+d*o,y=c*e+h*3*l*n+u*3*l*l*a+d*s,x=r+2*l*(t-r)+v*(i-2*t+r),m=e+2*l*(n-e)+v*(a-2*n+e),M=t+2*l*(i-t)+v*(o-2*i+t),w=n+2*l*(a-n)+v*(s-2*a+n),S=u*r+l*t,b=u*e+l*n,k=u*i+l*o,H=u*a+l*s,at=90-Math.atan2(x-M,m-w)*180/Math.PI;return{x:g,y,m:{x,y:m},n:{x:M,y:w},start:{x:S,y:b},end:{x:k,y:H},alpha:at}},kM=function(r,e,t){var n=Gh(r),i=Gh(e);if(!OM(n,i))return t?0:[];for(var a=Hh.apply(0,r),o=Hh.apply(0,e),s=~~(a/8),l=~~(o/8),u=[],c=[],h={},v=t?0:[],d=0;d<s+1;d++){var g=Yh.apply(0,r.concat(d/s));u.push({x:g.x,y:g.y,t:d/s})}for(var d=0;d<l+1;d++){var g=Yh.apply(0,e.concat(d/l));c.push({x:g.x,y:g.y,t:d/l})}for(var d=0;d<s;d++)for(var y=0;y<l;y++){var x=u[d],m=u[d+1],M=c[y],w=c[y+1],S=Math.abs(m.x-x.x)<.001?"y":"x",b=Math.abs(w.x-M.x)<.001?"y":"x",k=DM(x.x,x.y,m.x,m.y,M.x,M.y,w.x,w.y);if(k){if(h[k.x.toFixed(4)]===k.y.toFixed(4))continue;h[k.x.toFixed(4)]=k.y.toFixed(4);var H=x.t+Math.abs((k[S]-x[S])/(m[S]-x[S]))*(m.t-x.t),at=M.t+Math.abs((k[b]-M[b])/(w[b]-M[b]))*(w.t-M.t);H>=0&&H<=1&&at>=0&&at<=1&&(t?v++:v.push({x:k.x,y:k.y,t1:H,t2:at}))}}return v},BM=function(r,e,t){r=path2Curve(r),e=path2Curve(e);for(var n,i,a,o,s,l,u,c,h,v,d=t?0:[],g=0,y=r.length;g<y;g++){var x=r[g];if(x[0]==="M")n=s=x[1],i=l=x[2];else{x[0]==="C"?(h=[n,i].concat(x.slice(1)),n=h[6],i=h[7]):(h=[n,i,n,i,s,l,s,l],n=s,i=l);for(var m=0,M=e.length;m<M;m++){var w=e[m];if(w[0]==="M")a=u=w[1],o=c=w[2];else{w[0]==="C"?(v=[a,o].concat(w.slice(1)),a=v[6],o=v[7]):(v=[a,o,a,o,u,c,u,c],a=u,o=c);var S=kM(h,v,t);if(t)d+=S;else{for(var b=0,k=S.length;b<k;b++)S[b].segment1=g,S[b].segment2=m,S[b].bez1=h,S[b].bez2=v;d=d.concat(S)}}}}}return d};function k6(r,e){return BM(r,e)}function ys(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function Au(r,e){return ys(r)*ys(e)?(r[0]*e[0]+r[1]*e[1])/(ys(r)*ys(e)):1}function Xh(r,e){return(r[0]*e[1]<r[1]*e[0]?-1:1)*Math.acos(Au(r,e))}function Wh(r,e){return r[0]===e[0]&&r[1]===e[1]}function B6(r,e){var t=e[1],n=e[2],i=mod(toRadian(e[3]),Math.PI*2),a=e[4],o=e[5],s=r[0],l=r[1],u=e[6],c=e[7],h=Math.cos(i)*(s-u)/2+Math.sin(i)*(l-c)/2,v=-1*Math.sin(i)*(s-u)/2+Math.cos(i)*(l-c)/2,d=h*h/(t*t)+v*v/(n*n);d>1&&(t*=Math.sqrt(d),n*=Math.sqrt(d));var g=t*t*(v*v)+n*n*(h*h),y=g?Math.sqrt((t*t*(n*n)-g)/g):1;a===o&&(y*=-1),isNaN(y)&&(y=0);var x=n?y*t*v/n:0,m=t?y*-n*h/t:0,M=(s+u)/2+Math.cos(i)*x-Math.sin(i)*m,w=(l+c)/2+Math.sin(i)*x+Math.cos(i)*m,S=[(h-x)/t,(v-m)/n],b=[(-1*h-x)/t,(-1*v-m)/n],k=Xh([1,0],S),H=Xh(S,b);return Au(S,b)<=-1&&(H=Math.PI),Au(S,b)>=1&&(H=0),o===0&&H>0&&(H=H-2*Math.PI),o===1&&H<0&&(H=H+2*Math.PI),{cx:M,cy:w,rx:Wh(r,[u,c])?0:t,ry:Wh(r,[u,c])?0:n,startAngle:k,endAngle:k+H,xRotation:i,arcFlag:a,sweepFlag:o}}function Zh(r,e){return[e[0]+(e[0]-r[0]),e[1]+(e[1]-r[1])]}function R6(r){r=parsePath(r);for(var e=[],t=null,n=null,i=null,a=0,o=r.length,s=0;s<o;s++){var l=r[s];n=r[s+1];var u=l[0],c={command:u,prePoint:t,params:l,startTangent:null,endTangent:null};switch(u){case"M":i=[l[1],l[2]],a=s;break;case"A":var h=getArcParams(t,l);c.arcParams=h;break;default:break}if(u==="Z")t=i,n=r[a+1];else{var v=l.length;t=[l[v-2],l[v-1]]}n&&n[0]==="Z"&&(n=r[a],e[a]&&(e[a].prePoint=t)),c.currentPoint=t,e[a]&&isSamePoint(t,e[a].currentPoint)&&(e[a].prePoint=c.prePoint);var d=n?[n[n.length-2],n[n.length-1]]:null;c.nextPoint=d;var g=c.prePoint;if(["L","H","V"].includes(u))c.startTangent=[g[0]-t[0],g[1]-t[1]],c.endTangent=[t[0]-g[0],t[1]-g[1]];else if(u==="Q"){var y=[l[1],l[2]];c.startTangent=[g[0]-y[0],g[1]-y[1]],c.endTangent=[t[0]-y[0],t[1]-y[1]]}else if(u==="T"){var x=e[s-1],y=Zh(x.currentPoint,g);x.command==="Q"?(c.command="Q",c.startTangent=[g[0]-y[0],g[1]-y[1]],c.endTangent=[t[0]-y[0],t[1]-y[1]]):(c.command="TL",c.startTangent=[g[0]-t[0],g[1]-t[1]],c.endTangent=[t[0]-g[0],t[1]-g[1]])}else if(u==="C"){var m=[l[1],l[2]],M=[l[3],l[4]];c.startTangent=[g[0]-m[0],g[1]-m[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]],c.startTangent[0]===0&&c.startTangent[1]===0&&(c.startTangent=[m[0]-M[0],m[1]-M[1]]),c.endTangent[0]===0&&c.endTangent[1]===0&&(c.endTangent=[M[0]-m[0],M[1]-m[1]])}else if(u==="S"){var x=e[s-1],m=Zh(x.currentPoint,g),M=[l[1],l[2]];x.command==="C"?(c.command="C",c.startTangent=[g[0]-m[0],g[1]-m[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]]):(c.command="SQ",c.startTangent=[g[0]-M[0],g[1]-M[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]])}else if(u==="A"){var w=.001,S=c.arcParams||{},b=S.cx,k=b===void 0?0:b,H=S.cy,at=H===void 0?0:H,At=S.rx,gt=At===void 0?0:At,Nt=S.ry,te=Nt===void 0?0:Nt,ce=S.sweepFlag,Me=ce===void 0?0:ce,be=S.startAngle,Gt=be===void 0?0:be,ie=S.endAngle,de=ie===void 0?0:ie;Me===0&&(w*=-1);var ue=gt*Math.cos(Gt-w)+k,pe=te*Math.sin(Gt-w)+at;c.startTangent=[ue-i[0],pe-i[1]];var Ee=gt*Math.cos(Gt+de+w)+k,Ne=te*Math.sin(Gt+de-w)+at;c.endTangent=[g[0]-Ee,g[1]-Ne]}e.push(c)}return e}var RM=1e-6;function bu(r){return Math.abs(r)<RM?0:r<0?-1:1}function NM(r,e,t){return(t[0]-r[0])*(e[1]-r[1])==(e[0]-r[0])*(t[1]-r[1])&&Math.min(r[0],e[0])<=t[0]&&t[0]<=Math.max(r[0],e[0])&&Math.min(r[1],e[1])<=t[1]&&t[1]<=Math.max(r[1],e[1])}function $h(r,e,t){var n=!1,i=r.length;if(i<=2)return!1;for(var a=0;a<i;a++){var o=r[a],s=r[(a+1)%i];if(NM(o,s,[e,t]))return!0;bu(o[1]-t)>0!=bu(s[1]-t)>0&&bu(e-(t-o[1])*(o[0]-s[0])/(o[1]-s[1])-o[0])<0&&(n=!n)}return n}var qh=function(r,e,t){return r>=e&&r<=t};function UM(r,e,t,n){var i=.001,a={x:t.x-r.x,y:t.y-r.y},o={x:e.x-r.x,y:e.y-r.y},s={x:n.x-t.x,y:n.y-t.y},l=o.x*s.y-o.y*s.x,u=l*l,c=o.x*o.x+o.y*o.y,h=s.x*s.x+s.y*s.y,v=null;if(u>i*c*h){var d=(a.x*s.y-a.y*s.x)/l,g=(a.x*o.y-a.y*o.x)/l;qh(d,0,1)&&qh(g,0,1)&&(v={x:r.x+d*o.x,y:r.y+d*o.y})}return v}function Kh(r){for(var e=[],t=r.length,n=0;n<t-1;n++){var i=r[n],a=r[n+1];e.push({from:{x:i[0],y:i[1]},to:{x:a[0],y:a[1]}})}if(e.length>1){var o=r[0],s=r[t-1];e.push({from:{x:s[0],y:s[1]},to:{x:o[0],y:o[1]}})}return e}function zM(r,e){var t=!1;return(0,f.S6)(r,function(n){if(UM(n.from,n.to,e.from,e.to))return t=!0,!1}),t}function jh(r){var e=r.map(function(n){return n[0]}),t=r.map(function(n){return n[1]});return{minX:Math.min.apply(null,e),maxX:Math.max.apply(null,e),minY:Math.min.apply(null,t),maxY:Math.max.apply(null,t)}}function VM(r,e){return!(e.minX>r.maxX||e.maxX<r.minX||e.minY>r.maxY||e.maxY<r.minY)}function HM(r,e){if(r.length<2||e.length<2)return!1;var t=jh(r),n=jh(e);if(!VM(t,n))return!1;var i=!1;if((0,f.S6)(e,function(l){if($h(r,l[0],l[1]))return i=!0,!1}),i||((0,f.S6)(r,function(l){if($h(e,l[0],l[1]))return i=!0,!1}),i))return!0;var a=Kh(r),o=Kh(e),s=!1;return(0,f.S6)(o,function(l){if(zM(a,l))return s=!0,!1}),s}function Jh(r,e){var t=r.event,n=t.target;return tv(n,e)}function Qh(r,e){var t=r.getCanvasBBox(),n=t.width,i=t.height;return n>0&&i>0&&(n>=e||i>=e)}function tv(r,e){var t=r.getCanvasBBox();return Qh(r,e)?t:null}function ev(r,e){var t=r.event.maskShapes;return t.map(function(n){return tv(n,e)}).filter(function(n){return!!n})}function GM(r,e){var t=r.event,n=t.target;return rv(n,e)}function rv(r,e){return Qh(r,e)?r.attr("path"):null}function YM(r,e){var t=r.event.maskShapes;return t.map(function(n){return rv(n,e)})}function ri(r){var e=r.event,t,n=e.target;return n&&(t=n.get("element")),t}function Ti(r){var e=r.event,t=e.target,n;return t&&(n=t.get("delegateObject")),n}function nv(r){var e=r.event.gEvent;return!(e&&e.fromShape&&e.toShape&&e.fromShape.get("element")===e.toShape.get("element"))}function Qa(r){return r&&r.component&&r.component.isList()}function iv(r){return r&&r.component&&r.component.isSlider()}function to(r){var e=r.event,t=e.target;return t&&(t==null?void 0:t.get("name"))==="mask"||ms(r)}function ms(r){var e;return((e=r.event.target)===null||e===void 0?void 0:e.get("name"))==="multi-mask"}function Tu(r,e){var t=r.event.target;if(ms(r))return XM(r,e);if(t.get("type")==="path"){var n=GM(r,e);return n?uv(r.view,n):void 0}var i=Jh(r,e);return i?xs(r.view,i):null}function XM(r,e){var t=r.event.target;if(t.get("type")==="path"){var n=YM(r,e);return n.length>0?n.flatMap(function(a){return uv(r.view,a)}):null}var i=ev(r,e);return i.length>0?i.flatMap(function(a){return xs(r.view,a)}):null}function av(r,e,t){if(ms(r))return WM(r,e,t);var n=Jh(r,t);return n?ov(n,r,e):null}function ov(r,e,t){var n=e.view,i=_u(n,t,{x:r.x,y:r.y}),a=_u(n,t,{x:r.maxX,y:r.maxY}),o={minX:i.x,minY:i.y,maxX:a.x,maxY:a.y};return xs(t,o)}function WM(r,e,t){var n=ev(r,t);return n.length>0?n.flatMap(function(i){return ov(i,r,e)}):null}function Mr(r){var e=r.geometries,t=[];return(0,f.S6)(e,function(n){var i=n.elements;t=t.concat(i)}),r.views&&r.views.length&&(0,f.S6)(r.views,function(n){t=t.concat(Mr(n))}),t}function ZM(r,e,t){var n=Mr(r);return n.filter(function(i){return hn(i,e)===t})}function sv(r,e){var t=r.geometries,n=[];return(0,f.S6)(t,function(i){var a=i.getElementsBy(function(o){return o.hasState(e)});n=n.concat(a)}),n}function hn(r,e){var t=r.getModel(),n=t.data,i;return(0,f.kJ)(n)?i=n[0][e]:i=n[e],i}function $M(r,e){return!(e.minX>r.maxX||e.maxX<r.minX||e.minY>r.maxY||e.maxY<r.minY)}function xs(r,e){var t=Mr(r),n=[];return(0,f.S6)(t,function(i){var a=i.shape,o=a.getCanvasBBox();$M(e,o)&&n.push(i)}),n}function lv(r){var e=[];return(0,f.S6)(r,function(t){var n=t[0];if(n!=="A")for(var i=1;i<t.length;i=i+2)e.push([t[i],t[i+1]]);else{var a=t.length;e.push([t[a-2],t[a-1]])}}),e}function uv(r,e){var t=Mr(r),n=lv(e),i=t.filter(function(a){var o=a.shape,s;if(o.get("type")==="path")s=lv(o.attr("path"));else{var l=o.getCanvasBBox();s=j1(l)}return HM(n,s)});return i}function cv(r){return r.getComponents().map(function(e){return e.component})}function Eu(r,e){var t=e.x-r.x,n=e.y-r.y;return Math.sqrt(t*t+n*n)}function qM(r,e){if(r.length<=2)return Ka(r,!1);var t=r[0],n=[];(0,f.S6)(r,function(a){n.push(a.x),n.push(a.y)});var i=Nh(n,e,null);return i.unshift(["M",t.x,t.y]),i}function fv(r,e){return r.x<=e.x&&r.maxX>=e.x&&r.y<=e.y&&r.maxY>e.y}function bn(r){var e=r.parent,t=null;return e&&(t=e.views.filter(function(n){return n!==r})),t}function KM(r,e){var t=r.getCoordinate();return t.invert(e)}function _u(r,e,t){var n=KM(r,t);return e.getCoordinate().convert(n)}function hv(r,e,t,n){var i=!1;return(0,f.S6)(r,function(a){if(a[t]===e[t]&&a[n]===e[n])return i=!0,!1}),i}function sa(r,e){var t=r.getScaleByField(e);return!t&&r.views&&(0,f.S6)(r.views,function(n){if(t=sa(n,e),t)return!1}),t}var jM=function(){function r(e){this.actions=[],this.event=null,this.cacheMap={},this.view=e}return r.prototype.cache=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(e.length===1)return this.cacheMap[e[0]];e.length===2&&(this.cacheMap[e[0]]=e[1])},r.prototype.getAction=function(e){return this.actions.find(function(t){return t.name===e})},r.prototype.addAction=function(e){this.actions.push(e)},r.prototype.removeAction=function(e){var t=this.actions,n=this.actions.indexOf(e);n>=0&&t.splice(n,1)},r.prototype.getCurrentPoint=function(){var e=this.event;if(e)if(e.target instanceof HTMLElement){var t=this.view.getCanvas(),n=t.getPointByClient(e.clientX,e.clientY);return n}else return{x:e.x,y:e.y};return null},r.prototype.getCurrentShape=function(){return(0,f.U2)(this.event,["gEvent","shape"])},r.prototype.isInPlot=function(){var e=this.getCurrentPoint();return e?this.view.isPointInPlot(e):!1},r.prototype.isInShape=function(e){var t=this.getCurrentShape();return t?t.get("name")===e:!1},r.prototype.isInComponent=function(e){var t=cv(this.view),n=this.getCurrentPoint();return n?!!t.find(function(i){var a=i.getBBox();return e?i.get("name")===e&&fv(a,n):fv(a,n)}):!1},r.prototype.destroy=function(){(0,f.S6)(this.actions.slice(),function(e){e.destroy()}),this.view=null,this.event=null,this.actions=null,this.cacheMap=null},r}(),JM=jM,QM=function(){function r(e,t){this.view=e,this.cfg=t}return r.prototype.init=function(){this.initEvents()},r.prototype.initEvents=function(){},r.prototype.clearEvents=function(){},r.prototype.destroy=function(){this.clearEvents()},r}(),tw=QM;function vv(r,e,t){var n=r.split(":"),i=n[0],a=e.getAction(i)||hM(i,e);if(!a)throw new Error("There is no action named ".concat(i));var o=n[1];return{action:a,methodName:o,arg:t}}function dv(r){var e=r.action,t=r.methodName,n=r.arg;if(e[t])e[t](n);else throw new Error("Action(".concat(e.name,") doesn't have a method called ").concat(t))}var $r={START:"start",SHOW_ENABLE:"showEnable",END:"end",ROLLBACK:"rollback",PROCESSING:"processing"},ew=function(r){(0,p.ZT)(e,r);function e(t,n){var i=r.call(this,t,n)||this;return i.callbackCaches={},i.emitCaches={},i.steps=n,i}return e.prototype.init=function(){this.initContext(),r.prototype.init.call(this)},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.steps=null,this.context&&(this.context.destroy(),this.context=null),this.callbackCaches=null,this.view=null},e.prototype.initEvents=function(){var t=this;(0,f.S6)(this.steps,function(n,i){(0,f.S6)(n,function(a){var o=t.getActionCallback(i,a);o&&t.bindEvent(a.trigger,o)})})},e.prototype.clearEvents=function(){var t=this;(0,f.S6)(this.steps,function(n,i){(0,f.S6)(n,function(a){var o=t.getActionCallback(i,a);o&&t.offEvent(a.trigger,o)})})},e.prototype.initContext=function(){var t=this.view,n=new JM(t);this.context=n;var i=this.steps;(0,f.S6)(i,function(a){(0,f.S6)(a,function(o){if((0,f.mf)(o.action))o.actionObject={action:vM(o.action,n),methodName:"execute"};else if((0,f.HD)(o.action))o.actionObject=vv(o.action,n,o.arg);else if((0,f.kJ)(o.action)){var s=o.action,l=(0,f.kJ)(o.arg)?o.arg:[o.arg];o.actionObject=[],(0,f.S6)(s,function(u,c){o.actionObject.push(vv(u,n,l[c]))})}})})},e.prototype.isAllowStep=function(t){var n=this.currentStepName,i=this.steps;if(n===t||t===$r.SHOW_ENABLE)return!0;if(t===$r.PROCESSING)return n===$r.START;if(t===$r.START)return n!==$r.PROCESSING;if(t===$r.END)return n===$r.PROCESSING||n===$r.START;if(t===$r.ROLLBACK){if(i[$r.END])return n===$r.END;if(n===$r.START)return!0}return!1},e.prototype.isAllowExecute=function(t,n){if(this.isAllowStep(t)){var i=this.getKey(t,n);return n.once&&this.emitCaches[i]?!1:n.isEnable?n.isEnable(this.context):!0}return!1},e.prototype.enterStep=function(t){this.currentStepName=t,this.emitCaches={}},e.prototype.afterExecute=function(t,n){t!==$r.SHOW_ENABLE&&this.currentStepName!==t&&this.enterStep(t);var i=this.getKey(t,n);this.emitCaches[i]=!0},e.prototype.getKey=function(t,n){return t+n.trigger+n.action},e.prototype.getActionCallback=function(t,n){var i=this,a=this.context,o=this.callbackCaches,s=n.actionObject;if(n.action&&s){var l=this.getKey(t,n);if(!o[l]){var u=function(c){a.event=c,i.isAllowExecute(t,n)?((0,f.kJ)(s)?(0,f.S6)(s,function(h){a.event=c,dv(h)}):(a.event=c,dv(s)),i.afterExecute(t,n),n.callback&&(a.event=c,n.callback(a))):a.event=null};n.debounce?o[l]=(0,f.Ds)(u,n.debounce.wait,n.debounce.immediate):n.throttle?o[l]=(0,f.P2)(u,n.throttle.wait,{leading:n.throttle.leading,trailing:n.throttle.trailing}):o[l]=u}return o[l]}return null},e.prototype.bindEvent=function(t,n){var i=t.split(":");i[0]==="window"?window.addEventListener(i[1],n):i[0]==="document"?document.addEventListener(i[1],n):this.view.on(t,n)},e.prototype.offEvent=function(t,n){var i=t.split(":");i[0]==="window"?window.removeEventListener(i[1],n):i[0]==="document"?document.removeEventListener(i[1],n):this.view.off(t,n)},e}(tw),rw=ew,pv={};function nw(r){return pv[(0,f.vl)(r)]}function De(r,e){pv[(0,f.vl)(r)]=e}function iw(r,e,t){var n=nw(r);if(!n)return null;if((0,f.PO)(n)){var i=(0,f.CD)((0,f.d9)(n),t);return new rw(e,i)}else{var a=n;return new a(e,t)}}function aw(r){return{title:{autoRotate:!0,position:"center",spacing:r.axisTitleSpacing,style:{fill:r.axisTitleTextFillColor,fontSize:r.axisTitleTextFontSize,lineHeight:r.axisTitleTextLineHeight,textBaseline:"middle",fontFamily:r.fontFamily},iconStyle:{fill:r.axisDescriptionIconFillColor}},label:{autoRotate:!1,autoEllipsis:!1,autoHide:{type:"equidistance",cfg:{minGap:6}},offset:r.axisLabelOffset,style:{fill:r.axisLabelFillColor,fontSize:r.axisLabelFontSize,lineHeight:r.axisLabelLineHeight,fontFamily:r.fontFamily}},line:{style:{lineWidth:r.axisLineBorder,stroke:r.axisLineBorderColor}},grid:{line:{type:"line",style:{stroke:r.axisGridBorderColor,lineWidth:r.axisGridBorder,lineDash:r.axisGridLineDash}},alignTick:!0,animate:!0},tickLine:{style:{lineWidth:r.axisTickLineBorder,stroke:r.axisTickLineBorderColor},alignTick:!0,length:r.axisTickLineLength},subTickLine:null,animate:!0}}function ow(r){return{title:null,marker:{symbol:"circle",spacing:r.legendMarkerSpacing,style:{r:r.legendCircleMarkerSize,fill:r.legendMarkerColor}},itemName:{spacing:5,style:{fill:r.legendItemNameFillColor,fontFamily:r.fontFamily,fontSize:r.legendItemNameFontSize,lineHeight:r.legendItemNameLineHeight,fontWeight:r.legendItemNameFontWeight,textAlign:"start",textBaseline:"middle"}},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:"#D8D8D8"},markerStyle:{fill:"#D8D8D8",stroke:"#D8D8D8"}},inactive:{nameStyle:{fill:"#D8D8D8"},markerStyle:{opacity:.2}}},flipPage:!0,pageNavigator:{marker:{style:{size:r.legendPageNavigatorMarkerSize,inactiveFill:r.legendPageNavigatorMarkerInactiveFillColor,inactiveOpacity:r.legendPageNavigatorMarkerInactiveFillOpacity,fill:r.legendPageNavigatorMarkerFillColor,opacity:r.legendPageNavigatorMarkerFillOpacity}},text:{style:{fill:r.legendPageNavigatorTextFillColor,fontSize:r.legendPageNavigatorTextFontSize}}},animate:!1,maxItemWidth:200,itemSpacing:r.legendItemSpacing,itemMarginBottom:r.legendItemMarginBottom,padding:r.legendPadding}}function gv(r){var e,t={point:{default:{fill:r.pointFillColor,r:r.pointSize,stroke:r.pointBorderColor,lineWidth:r.pointBorder,fillOpacity:r.pointFillOpacity},active:{stroke:r.pointActiveBorderColor,lineWidth:r.pointActiveBorder},selected:{stroke:r.pointSelectedBorderColor,lineWidth:r.pointSelectedBorder},inactive:{fillOpacity:r.pointInactiveFillOpacity,strokeOpacity:r.pointInactiveBorderOpacity}},hollowPoint:{default:{fill:r.hollowPointFillColor,lineWidth:r.hollowPointBorder,stroke:r.hollowPointBorderColor,strokeOpacity:r.hollowPointBorderOpacity,r:r.hollowPointSize},active:{stroke:r.hollowPointActiveBorderColor,strokeOpacity:r.hollowPointActiveBorderOpacity},selected:{lineWidth:r.hollowPointSelectedBorder,stroke:r.hollowPointSelectedBorderColor,strokeOpacity:r.hollowPointSelectedBorderOpacity},inactive:{strokeOpacity:r.hollowPointInactiveBorderOpacity}},area:{default:{fill:r.areaFillColor,fillOpacity:r.areaFillOpacity,stroke:null},active:{fillOpacity:r.areaActiveFillOpacity},selected:{fillOpacity:r.areaSelectedFillOpacity},inactive:{fillOpacity:r.areaInactiveFillOpacity}},hollowArea:{default:{fill:null,stroke:r.hollowAreaBorderColor,lineWidth:r.hollowAreaBorder,strokeOpacity:r.hollowAreaBorderOpacity},active:{fill:null,lineWidth:r.hollowAreaActiveBorder},selected:{fill:null,lineWidth:r.hollowAreaSelectedBorder},inactive:{strokeOpacity:r.hollowAreaInactiveBorderOpacity}},interval:{default:{fill:r.intervalFillColor,fillOpacity:r.intervalFillOpacity},active:{stroke:r.intervalActiveBorderColor,lineWidth:r.intervalActiveBorder},selected:{stroke:r.intervalSelectedBorderColor,lineWidth:r.intervalSelectedBorder},inactive:{fillOpacity:r.intervalInactiveFillOpacity,strokeOpacity:r.intervalInactiveBorderOpacity}},hollowInterval:{default:{fill:r.hollowIntervalFillColor,stroke:r.hollowIntervalBorderColor,lineWidth:r.hollowIntervalBorder,strokeOpacity:r.hollowIntervalBorderOpacity},active:{stroke:r.hollowIntervalActiveBorderColor,lineWidth:r.hollowIntervalActiveBorder,strokeOpacity:r.hollowIntervalActiveBorderOpacity},selected:{stroke:r.hollowIntervalSelectedBorderColor,lineWidth:r.hollowIntervalSelectedBorder,strokeOpacity:r.hollowIntervalSelectedBorderOpacity},inactive:{stroke:r.hollowIntervalInactiveBorderColor,lineWidth:r.hollowIntervalInactiveBorder,strokeOpacity:r.hollowIntervalInactiveBorderOpacity}},line:{default:{stroke:r.lineBorderColor,lineWidth:r.lineBorder,strokeOpacity:r.lineBorderOpacity,fill:null,lineAppendWidth:10,lineCap:"round",lineJoin:"round"},active:{lineWidth:r.lineActiveBorder},selected:{lineWidth:r.lineSelectedBorder},inactive:{strokeOpacity:r.lineInactiveBorderOpacity}}},n=aw(r),i=ow(r);return{background:r.backgroundColor,defaultColor:r.brandColor,subColor:r.subColor,semanticRed:r.paletteSemanticRed,semanticGreen:r.paletteSemanticGreen,padding:"auto",fontFamily:r.fontFamily,columnWidthRatio:1/2,maxColumnWidth:null,minColumnWidth:null,roseWidthRatio:.9999999,multiplePieWidthRatio:1/1.3,colors10:r.paletteQualitative10,colors20:r.paletteQualitative20,sequenceColors:r.paletteSequence,shapes:{point:["hollow-circle","hollow-square","hollow-bowtie","hollow-diamond","hollow-hexagon","hollow-triangle","hollow-triangle-down","circle","square","bowtie","diamond","hexagon","triangle","triangle-down","cross","tick","plus","hyphen","line"],line:["line","dash","dot","smooth"],area:["area","smooth","line","smooth-line"],interval:["rect","hollow-rect","line","tick"]},sizes:[1,10],geometries:{interval:{rect:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:function(a){var o=a.geometry.coordinate;if(o.isPolar&&o.isTransposed){var s=Za(a.getModel(),o),l=s.startAngle,u=s.endAngle,c=(l+u)/2,h=7.5,v=h*Math.cos(c),d=h*Math.sin(c);return{matrix:nr.vs(null,[["t",v,d]])}}return t.interval.selected}}},"hollow-rect":{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},line:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},tick:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},funnel:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}},pyramid:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}}},line:{line:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},dot:{default:{style:(0,p.pi)((0,p.pi)({},t.line.default),{lineCap:null,lineDash:[1,1]})},active:{style:(0,p.pi)((0,p.pi)({},t.line.active),{lineCap:null,lineDash:[1,1]})},inactive:{style:(0,p.pi)((0,p.pi)({},t.line.inactive),{lineCap:null,lineDash:[1,1]})},selected:{style:(0,p.pi)((0,p.pi)({},t.line.selected),{lineCap:null,lineDash:[1,1]})}},dash:{default:{style:(0,p.pi)((0,p.pi)({},t.line.default),{lineCap:null,lineDash:[5.5,1]})},active:{style:(0,p.pi)((0,p.pi)({},t.line.active),{lineCap:null,lineDash:[5.5,1]})},inactive:{style:(0,p.pi)((0,p.pi)({},t.line.inactive),{lineCap:null,lineDash:[5.5,1]})},selected:{style:(0,p.pi)((0,p.pi)({},t.line.selected),{lineCap:null,lineDash:[5.5,1]})}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vh:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hvh:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vhv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}}},polygon:{polygon:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}}},point:{circle:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},square:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},bowtie:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},diamond:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},hexagon:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},triangle:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},"triangle-down":{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},"hollow-circle":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-square":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-bowtie":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-diamond":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-hexagon":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-triangle":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-triangle-down":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},cross:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},tick:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},plus:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},hyphen:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},line:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}}},area:{area:{default:{style:t.area.default},active:{style:t.area.active},inactive:{style:t.area.inactive},selected:{style:t.area.selected}},smooth:{default:{style:t.area.default},active:{style:t.area.active},inactive:{style:t.area.inactive},selected:{style:t.area.selected}},line:{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}},"smooth-line":{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}}},schema:{candle:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},box:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}}},edge:{line:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vhv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},arc:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}}},violin:{violin:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hollow:{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}},"hollow-smooth":{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}}}},components:{axis:{common:n,top:{position:"top",grid:null,title:null,verticalLimitLength:1/2},bottom:{position:"bottom",grid:null,title:null,verticalLimitLength:1/2},left:{position:"left",title:null,line:null,tickLine:null,verticalLimitLength:1/3},right:{position:"right",title:null,line:null,tickLine:null,verticalLimitLength:1/3},circle:{title:null,grid:(0,f.b$)({},n.grid,{line:{type:"line"}})},radius:{title:null,grid:(0,f.b$)({},n.grid,{line:{type:"circle"}})}},legend:{common:i,right:{layout:"vertical",padding:r.legendVerticalPadding},left:{layout:"vertical",padding:r.legendVerticalPadding},top:{layout:"horizontal",padding:r.legendHorizontalPadding},bottom:{layout:"horizontal",padding:r.legendHorizontalPadding},continuous:{title:null,background:null,track:{},rail:{type:"color",size:r.sliderRailHeight,defaultLength:r.sliderRailWidth,style:{fill:r.sliderRailFillColor,stroke:r.sliderRailBorderColor,lineWidth:r.sliderRailBorder}},label:{align:"rail",spacing:4,formatter:null,style:{fill:r.sliderLabelTextFillColor,fontSize:r.sliderLabelTextFontSize,lineHeight:r.sliderLabelTextLineHeight,textBaseline:"middle",fontFamily:r.fontFamily}},handler:{size:r.sliderHandlerWidth,style:{fill:r.sliderHandlerFillColor,stroke:r.sliderHandlerBorderColor}},slidable:!0,padding:i.padding}},tooltip:{showContent:!0,follow:!0,showCrosshairs:!1,showMarkers:!0,shared:!1,enterable:!1,position:"auto",marker:{symbol:"circle",stroke:"#fff",shadowBlur:10,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0,0,0,0.09)",lineWidth:2,r:4},crosshairs:{line:{style:{stroke:r.tooltipCrosshairsBorderColor,lineWidth:r.tooltipCrosshairsBorder}},text:null,textBackground:{padding:2,style:{fill:"rgba(0, 0, 0, 0.25)",lineWidth:0,stroke:null}},follow:!1},domStyles:(e={},e["".concat(Rn)]={position:"absolute",visibility:"hidden",zIndex:8,transition:"left 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s, top 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s",backgroundColor:r.tooltipContainerFillColor,opacity:r.tooltipContainerFillOpacity,boxShadow:r.tooltipContainerShadow,borderRadius:"".concat(r.tooltipContainerBorderRadius,"px"),color:r.tooltipTextFillColor,fontSize:"".concat(r.tooltipTextFontSize,"px"),fontFamily:r.fontFamily,lineHeight:"".concat(r.tooltipTextLineHeight,"px"),padding:"0 12px 0 12px"},e["".concat(Nn)]={marginBottom:"12px",marginTop:"12px"},e["".concat(Ya)]={margin:0,listStyleType:"none",padding:0},e["".concat(is)]={listStyleType:"none",padding:0,marginBottom:"12px",marginTop:"12px",marginLeft:0,marginRight:0},e["".concat(as)]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},e["".concat(os)]={display:"inline-block",float:"right",marginLeft:"30px"},e)},annotation:{arc:{style:{stroke:r.annotationArcBorderColor,lineWidth:r.annotationArcBorder},animate:!0},line:{style:{stroke:r.annotationLineBorderColor,lineDash:r.annotationLineDash,lineWidth:r.annotationLineBorder},text:{position:"start",autoRotate:!0,style:{fill:r.annotationTextFillColor,stroke:r.annotationTextBorderColor,lineWidth:r.annotationTextBorder,fontSize:r.annotationTextFontSize,textAlign:"start",fontFamily:r.fontFamily,textBaseline:"bottom"}},animate:!0},text:{style:{fill:r.annotationTextFillColor,stroke:r.annotationTextBorderColor,lineWidth:r.annotationTextBorder,fontSize:r.annotationTextFontSize,textBaseline:"middle",textAlign:"start",fontFamily:r.fontFamily},animate:!0},region:{top:!1,style:{lineWidth:r.annotationRegionBorder,stroke:r.annotationRegionBorderColor,fill:r.annotationRegionFillColor,fillOpacity:r.annotationRegionFillOpacity},animate:!0},image:{top:!1,animate:!0},dataMarker:{top:!0,point:{style:{r:3,stroke:r.brandColor,lineWidth:2}},line:{style:{stroke:r.annotationLineBorderColor,lineWidth:r.annotationLineBorder},length:r.annotationDataMarkerLineLength},text:{style:{textAlign:"start",fill:r.annotationTextFillColor,stroke:r.annotationTextBorderColor,lineWidth:r.annotationTextBorder,fontSize:r.annotationTextFontSize,fontFamily:r.fontFamily}},direction:"upward",autoAdjust:!0,animate:!0},dataRegion:{style:{region:{fill:r.annotationRegionFillColor,fillOpacity:r.annotationRegionFillOpacity},text:{textAlign:"center",textBaseline:"bottom",fill:r.annotationTextFillColor,stroke:r.annotationTextBorderColor,lineWidth:r.annotationTextBorder,fontSize:r.annotationTextFontSize,fontFamily:r.fontFamily}},animate:!0}},slider:{common:{padding:[8,8,8,8],backgroundStyle:{fill:r.cSliderBackgroundFillColor,opacity:r.cSliderBackgroundFillOpacity},foregroundStyle:{fill:r.cSliderForegroundFillColor,opacity:r.cSliderForegroundFillOpacity},handlerStyle:{width:r.cSliderHandlerWidth,height:r.cSliderHandlerHeight,fill:r.cSliderHandlerFillColor,opacity:r.cSliderHandlerFillOpacity,stroke:r.cSliderHandlerBorderColor,lineWidth:r.cSliderHandlerBorder,radius:r.cSliderHandlerBorderRadius,highLightFill:r.cSliderHandlerHighlightFillColor},textStyle:{fill:r.cSliderTextFillColor,opacity:r.cSliderTextFillOpacity,fontSize:r.cSliderTextFontSize,lineHeight:r.cSliderTextLineHeight,fontWeight:r.cSliderTextFontWeight,stroke:r.cSliderTextBorderColor,lineWidth:r.cSliderTextBorder}}},scrollbar:{common:{padding:[8,8,8,8]},default:{style:{trackColor:r.scrollbarTrackFillColor,thumbColor:r.scrollbarThumbFillColor}},hover:{style:{thumbColor:r.scrollbarThumbHighlightFillColor}}}},labels:{offset:12,style:{fill:r.labelFillColor,fontSize:r.labelFontSize,fontFamily:r.fontFamily,stroke:r.labelBorderColor,lineWidth:r.labelBorder},fillColorDark:r.labelFillColorDark,fillColorLight:r.labelFillColorLight,autoRotate:!0},innerLabels:{style:{fill:r.innerLabelFillColor,fontSize:r.innerLabelFontSize,fontFamily:r.fontFamily,stroke:r.innerLabelBorderColor,lineWidth:r.innerLabelBorder},autoRotate:!0},overflowLabels:{style:{fill:r.overflowLabelFillColor,fontSize:r.overflowLabelFontSize,fontFamily:r.fontFamily,stroke:r.overflowLabelBorderColor,lineWidth:r.overflowLabelBorder}},pieLabels:{labelHeight:14,offset:10,labelLine:{style:{lineWidth:r.labelLineBorder}},autoRotate:!0}}}var Je={100:"#000",95:"#0D0D0D",85:"#262626",65:"#595959",45:"#8C8C8C",25:"#BFBFBF",15:"#D9D9D9",6:"#F0F0F0"},la={100:"#FFFFFF",95:"#F2F2F2",85:"#D9D9D9",65:"#A6A6A6",45:"#737373",25:"#404040",15:"#262626",6:"#0F0F0F"},sw=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#6F5EF9","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],lw=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#6F5EF9","#D3CEFD","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],uw=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],yv=function(r){r===void 0&&(r={});var e=r.paletteQualitative10,t=e===void 0?sw:e,n=r.paletteQualitative20,i=n===void 0?lw:n,a=r.brandColor,o=a===void 0?t[0]:a,s={backgroundColor:"transparent",brandColor:o,subColor:"rgba(0,0,0,0.05)",paletteQualitative10:t,paletteQualitative20:i,paletteSemanticRed:"#F4664A",paletteSemanticGreen:"#30BF78",paletteSemanticYellow:"#FAAD14",paletteSequence:uw,fontFamily:`"Segoe UI", Roboto, "Helvetica Neue", Arial,
  38. "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",
  39. "Noto Color Emoji"`,axisLineBorderColor:Je[25],axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:Je[65],axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisDescriptionIconFillColor:la[85],axisTickLineBorderColor:Je[25],axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:Je[15],axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:Je[45],axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:Je[15],axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:Je[45],legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:o,legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:Je[65],legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:Je[100],legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:Je[100],legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:Je[45],legendPageNavigatorTextFontSize:12,sliderRailFillColor:Je[15],sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:Je[45],sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:Je[6],sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:Je[25],annotationArcBorderColor:Je[15],annotationArcBorder:1,annotationLineBorderColor:Je[25],annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:Je[65],annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:Je[100],annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:Je[25],tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"rgb(255, 255, 255)",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 0px 10px #aeaeae",tooltipContainerBorderRadius:3,tooltipTextFillColor:Je[65],tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:Je[65],labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:la[100],innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:Je[65],overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:la[100],overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:Je[25],cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#000",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(0,0,0,0)",scrollbarThumbFillColor:"rgba(0,0,0,0.15)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.2)",pointFillColor:o,pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:la[100],pointBorderOpacity:1,pointActiveBorderColor:Je[100],pointSelectedBorder:2,pointSelectedBorderColor:Je[100],pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:o,hollowPointBorderOpacity:.95,hollowPointFillColor:la[100],hollowPointActiveBorder:1,hollowPointActiveBorderColor:Je[100],hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:Je[100],hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:o,lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:o,areaFillOpacity:.25,areaActiveFillColor:o,areaActiveFillOpacity:.5,areaSelectedFillColor:o,areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:o,hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:Je[100],hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:Je[100],hollowAreaInactiveBorderOpacity:.3,intervalFillColor:o,intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:Je[100],intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:Je[100],intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:o,hollowIntervalBorderOpacity:1,hollowIntervalFillColor:la[100],hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:Je[100],hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:Je[100],hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3};return(0,p.pi)((0,p.pi)({},s),r)},N6=yv();function Ms(r){var e=r.styleSheet,t=e===void 0?{}:e,n=(0,p._T)(r,["styleSheet"]),i=yv(t);return(0,f.b$)({},gv(i),n)}var cw=Ms({}),Fu={default:cw};function eo(r){return(0,f.U2)(Fu,(0,f.vl)(r),Fu.default)}function fw(r,e){Fu[(0,f.vl)(r)]=Ms(e)}function mv(r,e,t){var n=t.translate(r),i=t.translate(e);return(0,f.vQ)(n,i)}function hw(r,e){var t=e.coordinate,n=e.getXScale(),i=n.range,a=i[i.length-1],o=i[0],s=t.invert(r),l=s.x;return t.isPolar&&l>(1+a)/2&&(l=o),n.translate(n.invert(l))}function xv(r,e,t){var n=t.coordinate,i=t.getYScale(),a=i.field,o=n.invert(e),s=i.invert(o.y),l=(0,f.sE)(r,function(u){var c=u[ee];return c[a][0]<=s&&c[a][1]>=s});return l||r[r.length-1]}var vw=(0,f.HP)(function(r){if(r.isCategory)return 1;for(var e=r.values,t=e.length,n=r.translate(e[0]),i=n,a=0;a<t;a++){var o=e[a],s=r.translate(o);s<n&&(n=s),s>i&&(i=s)}return(i-n)/(t-1)});function dw(r,e,t){var n=e.getAttribute("position"),i=n.getFields(),a=e.scales,o=(0,f.mf)(t)||!t?i[0]:t,s=a[o],l=s?s.getText(r[o]):r[o]||o;return(0,f.mf)(t)?t(l,r):l}function pw(r){var e=(0,f.VO)(r.attributes);return(0,f.hX)(e,function(t){return(0,f.FX)(jt,t.type)})}function Mv(r){var e,t,n=pw(r),i;try{for(var a=(0,p.XA)(n),o=a.next();!o.done;o=a.next()){var s=o.value,l=s.getScale(s.type);if(l&&l.isLinear){var u=(0,f.U2)(r.scaleDefs,l.field),c=Fh(l,u,s.type,r.type);if(c!=="cat"){i=l;break}}}}catch(d){e={error:d}}finally{try{o&&!o.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}var h=r.getXScale(),v=r.getYScale();return i||v||h}function gw(r,e){var t=e.field,n=r[t];if((0,f.kJ)(n)){var i=n.map(function(a){return e.getText(a)});return i.join("-")}return e.getText(n)}function yw(r,e){var t,n=e.getGroupScales();if(n.length&&(t=n[0]),t){var i=t.field;return t.getText(r[i])}var a=Mv(e);return qa(a)}function wv(r,e,t){if(e.length===0)return null;var n=t.type,i=t.getXScale(),a=t.getYScale(),o=i.field,s=a.field,l=null;if(n==="heatmap"||n==="point"){for(var u=t.coordinate,c=u.invert(r),h=i.invert(c.x),v=a.invert(c.y),d=Infinity,g=0;g<e.length;g++){var y=e[g],x=y[ee],m=Math.pow(x[o]-h,2)+Math.pow(x[s]-v,2);m<d&&(d=m,l=y)}return l}var M=e[0],w=e[e.length-1],S=hw(r,t),b=M[ee][o],k=M[ee][s],H=w[ee][o],at=a.isLinear&&(0,f.kJ)(k);if((0,f.kJ)(b)){for(var g=0;g<e.length;g++){var At=e[g],x=At[ee];if(i.translate(x[o][0])<=S&&i.translate(x[o][1])>=S)if(at)(0,f.kJ)(l)||(l=[]),l.push(At);else{l=At;break}}(0,f.kJ)(l)&&(l=xv(l,r,t))}else{var gt=void 0;if(!i.isLinear&&i.type!=="timeCat"){for(var g=0;g<e.length;g++){var At=e[g],x=At[ee];if(mv(x[o],S,i))if(at)(0,f.kJ)(l)||(l=[]),l.push(At);else{l=At;break}else i.translate(x[o])<=S&&(w=At,gt=e[g+1])}(0,f.kJ)(l)&&(l=xv(l,r,t))}else{if((S>i.translate(H)||S<i.translate(b))&&(S>i.max||S<i.min))return null;for(var Nt=0,te=e.length-1,ce=void 0;Nt<=te;){ce=Math.floor((Nt+te)/2);var Me=e[ce][ee][o];if(mv(Me,S,i))return e[ce];i.translate(Me)<=i.translate(S)?(Nt=ce+1,w=e[ce],gt=e[ce+1]):(te===0&&(w=e[0]),te=ce-1)}}w&&gt&&Math.abs(i.translate(w[ee][o])-S)>Math.abs(i.translate(gt[ee][o])-S)&&(w=gt)}var be=vw(t.getXScale());return!l&&Math.abs(i.translate(w[ee][o])-S)<=be/2&&(l=w),l}function Iu(r,e,t,n){var i,a;t===void 0&&(t=""),n===void 0&&(n=!1);var o=r[ee],s=dw(o,e,t),l=e.tooltipOption,u=e.theme.defaultColor,c=[],h,v;function d(At,gt){if(n||!(0,f.UM)(gt)&&gt!==""){var Nt={title:s,data:o,mappingData:r,name:At,value:gt,color:r.color||u,marker:!0};c.push(Nt)}}if((0,f.Kn)(l)){var g=l.fields,y=l.callback;if(y){var x=g.map(function(At){return r[ee][At]}),m=y.apply(void 0,(0,p.ev)([],(0,p.CR)(x),!1)),M=(0,p.pi)({data:r[ee],mappingData:r,title:s,color:r.color||u,marker:!0},m);c.push(M)}else{var w=e.scales;try{for(var S=(0,p.XA)(g),b=S.next();!b.done;b=S.next()){var k=b.value;if(!(0,f.UM)(o[k])){var H=w[k];h=qa(H),v=H.getText(o[k]),d(h,v)}}}catch(At){i={error:At}}finally{try{b&&!b.done&&(a=S.return)&&a.call(S)}finally{if(i)throw i.error}}}}else{var at=Mv(e);v=gw(o,at),h=yw(o,e),d(h,v)}return c}function Sv(r,e,t,n){var i,a,o=n.showNil,s=[],l=r.dataArray;if(!(0,f.xb)(l)){r.sort(l);try{for(var u=(0,p.XA)(l),c=u.next();!c.done;c=u.next()){var h=c.value,v=wv(e,h,r);if(v){var d=r.getElementId(v),g=r.elementsMap[d];if(r.type==="heatmap"||g.visible){var y=Iu(v,r,t,o);y.length&&s.push(y)}}}}catch(x){i={error:x}}finally{try{c&&!c.done&&(a=u.return)&&a.call(u)}finally{if(i)throw i.error}}}return s}function Cv(r,e,t,n){var i=n.showNil,a=[],o=r.container,s=o.getShape(e.x,e.y);if(s&&s.get("visible")&&s.get("origin")){var l=s.get("origin").mappingData,u=Iu(l,r,t,i);u.length&&a.push(u)}return a}function Pu(r,e,t){var n,i,a=[],o=r.geometries,s=t.shared,l=t.title,u=t.reversed;try{for(var c=(0,p.XA)(o),h=c.next();!h.done;h=c.next()){var v=h.value;if(v.visible&&v.tooltipOption!==!1){var d=v.type,g=void 0;["point","edge","polygon"].includes(d)?g=Cv(v,e,l,t):["area","line","path","heatmap"].includes(d)||s!==!1?g=Sv(v,e,l,t):g=Cv(v,e,l,t),g.length&&(u&&g.reverse(),a.push(g))}}}catch(y){n={error:y}}finally{try{h&&!h.done&&(i=c.return)&&i.call(c)}finally{if(n)throw n.error}}return a}function mw(r,e,t){var n,i,a=Pu(r,e,t);try{for(var o=(0,p.XA)(r.views),s=o.next();!s.done;s=o.next()){var l=s.value;a=a.concat(Pu(l,e,t))}}catch(u){n={error:u}}finally{try{s&&!s.done&&(i=o.return)&&i.call(o)}finally{if(n)throw n.error}}return a}function xw(r){return!(0,f.hj)(r)&&!(0,f.kJ)(r)}function Lu(r){r===void 0&&(r=0);var e=(0,f.kJ)(r)?r:[r];switch(e.length){case 0:e=[0,0,0,0];break;case 1:e=new Array(4).fill(e[0]);break;case 2:e=(0,p.ev)((0,p.ev)([],(0,p.CR)(e),!1),(0,p.CR)(e),!1);break;case 3:e=(0,p.ev)((0,p.ev)([],(0,p.CR)(e),!1),[e[1]],!1);break;default:e=e.slice(0,4);break}return e}var ws={};function Ei(r,e){ws[r]=e}function U6(r){delete ws[r]}function Mw(){return Object.keys(ws)}function ww(r){return ws[r]}var Sw=function(){function r(e){this.option=this.wrapperOption(e)}return r.prototype.update=function(e){return this.option=this.wrapperOption(e),this},r.prototype.hasAction=function(e){var t=this.option.actions;return(0,f.G)(t,function(n){return n[0]===e})},r.prototype.create=function(e,t){var n=this.option,i=n.type,a=n.cfg,o=i==="theta",s=(0,p.pi)({start:e,end:t},a),l=bm(o?"polar":i);return this.coordinate=new l(s),this.coordinate.type=i,o&&(this.hasAction("transpose")||this.transpose()),this.execActions(),this.coordinate},r.prototype.adjust=function(e,t){return this.coordinate.update({start:e,end:t}),this.coordinate.resetMatrix(),this.execActions(["scale","rotate","translate"]),this.coordinate},r.prototype.rotate=function(e){return this.option.actions.push(["rotate",e]),this},r.prototype.reflect=function(e){return this.option.actions.push(["reflect",e]),this},r.prototype.scale=function(e,t){return this.option.actions.push(["scale",e,t]),this},r.prototype.transpose=function(){return this.option.actions.push(["transpose"]),this},r.prototype.getOption=function(){return this.option},r.prototype.getCoordinate=function(){return this.coordinate},r.prototype.wrapperOption=function(e){return(0,p.pi)({type:"rect",actions:[],cfg:{}},e)},r.prototype.execActions=function(e){var t=this,n=this.option.actions;(0,f.S6)(n,function(i){var a,o=(0,p.CR)(i),s=o[0],l=o.slice(1),u=(0,f.UM)(e)?!0:e.includes(s);u&&(a=t.coordinate)[s].apply(a,(0,p.ev)([],(0,p.CR)(l),!1))})},r}(),Cw=Sw,Aw=function(){function r(e,t,n){this.view=e,this.gEvent=t,this.data=n,this.type=t.type}return r.fromData=function(e,t,n){return new r(e,new F.Event(t,{}),n)},Object.defineProperty(r.prototype,"target",{get:function(){return this.gEvent.target},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"event",{get:function(){return this.gEvent.originalEvent},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"x",{get:function(){return this.gEvent.x},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"y",{get:function(){return this.gEvent.y},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"clientX",{get:function(){return this.gEvent.clientX},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"clientY",{get:function(){return this.gEvent.clientY},enumerable:!1,configurable:!0}),r.prototype.toString=function(){return"[Event (type=".concat(this.type,")]")},r.prototype.clone=function(){return new r(this.view,this.gEvent,this.data)},r}(),lr=Aw;function bw(r){var e=r.getController("axis"),t=r.getController("legend"),n=r.getController("annotation"),i=r.getController("slider"),a=r.getController("scrollbar");[e,i,a,t,n].forEach(function(o){o&&o.layout()})}var Tw=function(){function r(){this.scales=new Map,this.syncScales=new Map}return r.prototype.createScale=function(e,t,n,i){var a=n,o=this.getScaleMeta(i);if(t.length===0&&o){var s=o.scale,l={type:s.type};s.isCategory&&(l.values=s.values),a=(0,f.b$)(l,o.scaleDef,n)}var u=nM(e,t,a);return this.cacheScale(u,n,i),u},r.prototype.sync=function(e,t){var n=this;this.syncScales.forEach(function(i,a){var o=Number.MAX_SAFE_INTEGER,s=Number.MIN_SAFE_INTEGER,l=[];(0,f.S6)(i,function(u){var c=n.getScale(u);s=(0,f.hj)(c.max)?Math.max(s,c.max):s,o=(0,f.hj)(c.min)?Math.min(o,c.min):o,(0,f.S6)(c.values,function(h){l.includes(h)||l.push(h)})}),(0,f.S6)(i,function(u){var c=n.getScale(u);if(c.isContinuous)c.change({min:o,max:s,values:l});else if(c.isCategory){var h=c.range,v=n.getScaleMeta(u);l&&!(0,f.U2)(v,["scaleDef","range"])&&(h=Ih((0,f.b$)({},c,{values:l}),e,t)),c.change({values:l,range:h})}})})},r.prototype.cacheScale=function(e,t,n){var i=this.getScaleMeta(n);i&&i.scale.type===e.type?(iM(i.scale,e),i.scaleDef=t):(i={key:n,scale:e,scaleDef:t},this.scales.set(n,i));var a=this.getSyncKey(i);if(i.syncKey=a,this.removeFromSyncScales(n),a){var o=this.syncScales.get(a);o||(o=[],this.syncScales.set(a,o)),o.push(n)}},r.prototype.getScale=function(e){var t=this.getScaleMeta(e);if(!t){var n=(0,f.Z$)(e.split("-")),i=this.syncScales.get(n);i&&i.length&&(t=this.getScaleMeta(i[0]))}return t&&t.scale},r.prototype.deleteScale=function(e){var t=this.getScaleMeta(e);if(t){var n=t.syncKey,i=this.syncScales.get(n);if(i&&i.length){var a=i.indexOf(e);a!==-1&&i.splice(a,1)}}this.scales.delete(e)},r.prototype.clear=function(){this.scales.clear(),this.syncScales.clear()},r.prototype.removeFromSyncScales=function(e){var t=this;this.syncScales.forEach(function(n,i){var a=n.indexOf(e);if(a!==-1)return n.splice(a,1),n.length===0&&t.syncScales.delete(i),!1})},r.prototype.getSyncKey=function(e){var t=e.scale,n=e.scaleDef,i=t.field,a=(0,f.U2)(n,["sync"]);return a===!0?i:a===!1?void 0:a},r.prototype.getScaleMeta=function(e){return this.scales.get(e)},r}(),Ss=function(){function r(e,t,n,i){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0),i===void 0&&(i=0),this.top=e,this.right=t,this.bottom=n,this.left=i}return r.instance=function(e,t,n,i){return e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0),i===void 0&&(i=0),new r(e,t,n,i)},r.prototype.max=function(e){var t=(0,p.CR)(e,4),n=t[0],i=t[1],a=t[2],o=t[3];return this.top=Math.max(this.top,n),this.right=Math.max(this.right,i),this.bottom=Math.max(this.bottom,a),this.left=Math.max(this.left,o),this},r.prototype.shrink=function(e){var t=(0,p.CR)(e,4),n=t[0],i=t[1],a=t[2],o=t[3];return this.top+=n,this.right+=i,this.bottom+=a,this.left+=o,this},r.prototype.inc=function(e,t){var n=e.width,i=e.height;switch(t){case K.TOP:case K.TOP_LEFT:case K.TOP_RIGHT:this.top+=i;break;case K.RIGHT:case K.RIGHT_TOP:case K.RIGHT_BOTTOM:this.right+=n;break;case K.BOTTOM:case K.BOTTOM_LEFT:case K.BOTTOM_RIGHT:this.bottom+=i;break;case K.LEFT:case K.LEFT_TOP:case K.LEFT_BOTTOM:this.left+=n;break;default:break}return this},r.prototype.getPadding=function(){return[this.top,this.right,this.bottom,this.left]},r.prototype.clone=function(){return new(r.bind.apply(r,(0,p.ev)([void 0],(0,p.CR)(this.getPadding()),!1)))},r}();function Ew(r){var e=r.padding;if(!xw(e))return new(Ss.bind.apply(Ss,(0,p.ev)([void 0],(0,p.CR)(Lu(e)),!1)));var t=r.viewBBox,n=new Ss,i=[],a=[],o=[];return(0,f.S6)(r.getComponents(),function(s){var l=s.type;l===ht.AXIS?i.push(s):[ht.LEGEND,ht.SLIDER,ht.SCROLLBAR].includes(l)?a.push(s):l!==ht.GRID&&l!==ht.TOOLTIP&&o.push(s)}),(0,f.S6)(i,function(s){var l=s.component,u=l.getLayoutBBox(),c=new Ir(u.x,u.y,u.width,u.height),h=c.exceed(t);n.max(h)}),(0,f.S6)(a,function(s){var l=s.component,u=s.direction,c=l.getLayoutBBox(),h=l.get("padding"),v=new Ir(c.x,c.y,c.width,c.height).expand(h);n.inc(v,u)}),(0,f.S6)(o,function(s){var l=s.component,u=s.direction,c=l.getLayoutBBox(),h=new Ir(c.x,c.y,c.width,c.height);n.inc(h,u)}),n}function _w(r,e,t){var n=t.instance();e.forEach(function(i){i.autoPadding=n.max(i.autoPadding.getPadding())})}var Av=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,{visible:t.visible})||this;n.views=[],n.geometries=[],n.controllers=[],n.interactions={},n.limitInPlot=!1,n.options={data:[],animate:!0},n.usedControllers=Mw(),n.scalePool=new Tw,n.layoutFunc=bw,n.isPreMouseInPlot=!1,n.isDataChanged=!1,n.isCoordinateChanged=!1,n.createdScaleKeys=new Map,n.onCanvasEvent=function(w){var S=w.name;if(!S.includes(":")){var b=n.createViewEvent(w);n.doPlotEvent(b),n.emit(S,b)}},n.onDelegateEvents=function(w){var S=w.name;if(!!S.includes(":")){var b=n.createViewEvent(w);n.emit(S,b)}};var i=t.id,a=i===void 0?(0,f.EL)("view"):i,o=t.parent,s=t.canvas,l=t.backgroundGroup,u=t.middleGroup,c=t.foregroundGroup,h=t.region,v=h===void 0?{start:{x:0,y:0},end:{x:1,y:1}}:h,d=t.padding,g=t.appendPadding,y=t.theme,x=t.options,m=t.limitInPlot,M=t.syncViewPadding;return n.parent=o,n.canvas=s,n.backgroundGroup=l,n.middleGroup=u,n.foregroundGroup=c,n.region=v,n.padding=d,n.appendPadding=g,n.options=(0,p.pi)((0,p.pi)({},n.options),x),n.limitInPlot=m,n.id=a,n.syncViewPadding=M,n.themeObject=(0,f.Kn)(y)?(0,f.b$)({},eo("default"),Ms(y)):eo(y),n.init(),n}return e.prototype.setLayout=function(t){this.layoutFunc=t},e.prototype.init=function(){this.calculateViewBBox(),this.initEvents(),this.initComponentController(),this.initOptions()},e.prototype.render=function(t,n){t===void 0&&(t=!1),this.emit(X.BEFORE_RENDER,lr.fromData(this,X.BEFORE_RENDER,n)),this.paint(t),this.emit(X.AFTER_RENDER,lr.fromData(this,X.AFTER_RENDER,n)),this.visible===!1&&this.changeVisible(!1)},e.prototype.clear=function(){var t=this;this.emit(X.BEFORE_CLEAR),this.filteredData=[],this.coordinateInstance=void 0,this.isDataChanged=!1,this.isCoordinateChanged=!1;for(var n=this.geometries,i=0;i<n.length;i++)n[i].clear(),n[i].container.remove(!0),n[i].labelsContainer.remove(!0);this.geometries=[];for(var a=this.controllers,i=0;i<a.length;i++)a[i].name==="annotation"?a[i].clear(!0):a[i].clear();this.createdScaleKeys.forEach(function(s,l){t.getRootView().scalePool.deleteScale(l)}),this.createdScaleKeys.clear();for(var o=this.views,i=0;i<o.length;i++)o[i].clear();this.emit(X.AFTER_CLEAR)},e.prototype.destroy=function(){this.emit(X.BEFORE_DESTROY);var t=this.interactions;(0,f.S6)(t,function(s){s&&s.destroy()}),this.clear();for(var n=this.controllers,i=0,a=n.length;i<a;i++){var o=n[i];o.destroy()}this.backgroundGroup.remove(!0),this.middleGroup.remove(!0),this.foregroundGroup.remove(!0),r.prototype.destroy.call(this)},e.prototype.changeVisible=function(t){r.prototype.changeVisible.call(this,t);for(var n=this.geometries,i=0,a=n.length;i<a;i++){var o=n[i];o.changeVisible(t)}for(var s=this.controllers,i=0,a=s.length;i<a;i++){var l=s[i];l.changeVisible(t)}return this.foregroundGroup.set("visible",t),this.middleGroup.set("visible",t),this.backgroundGroup.set("visible",t),this.getCanvas().draw(),this},e.prototype.data=function(t){return(0,f.t8)(this.options,"data",t),this.isDataChanged=!0,this},e.prototype.source=function(t){return console.warn("This method will be removed at G2 V4.1. Please use chart.data() instead."),this.data(t)},e.prototype.filter=function(t,n){return(0,f.mf)(n)?((0,f.t8)(this.options,["filters",t],n),this):(!n&&(0,f.U2)(this.options,["filters",t])&&delete this.options.filters[t],this)},e.prototype.axis=function(t,n){return(0,f.jn)(t)?(0,f.t8)(this.options,["axes"],t):(0,f.t8)(this.options,["axes",t],n),this},e.prototype.legend=function(t,n){return(0,f.jn)(t)?(0,f.t8)(this.options,["legends"],t):(0,f.HD)(t)?((0,f.t8)(this.options,["legends",t],n),(0,f.PO)(n)&&(n==null?void 0:n.selected)&&(0,f.t8)(this.options,["filters",t],function(i){var a;return(a=n==null?void 0:n.selected[i])!==null&&a!==void 0?a:!0})):(0,f.t8)(this.options,["legends"],t),this},e.prototype.scale=function(t,n){var i=this;return(0,f.HD)(t)?(0,f.t8)(this.options,["scales",t],n):(0,f.Kn)(t)&&(0,f.S6)(t,function(a,o){(0,f.t8)(i.options,["scales",o],a)}),this},e.prototype.tooltip=function(t){return(0,f.t8)(this.options,"tooltip",t),this},e.prototype.annotation=function(){return this.getController("annotation")},e.prototype.guide=function(){return console.warn("This method will be removed at G2 V4.1. Please use chart.annotation() instead."),this.annotation()},e.prototype.coordinate=function(t,n){return(0,f.HD)(t)?(0,f.t8)(this.options,"coordinate",{type:t,cfg:n}):(0,f.t8)(this.options,"coordinate",t),this.coordinateController.update(this.options.coordinate),this.coordinateController},e.prototype.coord=function(t,n){return console.warn("This method will be removed at G2 V4.1. Please use chart.coordinate() instead."),this.coordinate(t,n)},e.prototype.facet=function(t,n){this.facetInstance&&this.facetInstance.destroy();var i=lM(t);if(!i)throw new Error("facet '".concat(t,"' is not exist!"));return this.facetInstance=new i(this,(0,p.pi)((0,p.pi)({},n),{type:t})),this},e.prototype.animate=function(t){return(0,f.t8)(this.options,"animate",t),this},e.prototype.updateOptions=function(t){return this.clear(),(0,f.CD)(this.options,t),this.views.forEach(function(n){return n.destroy()}),this.views=[],this.initOptions(),this.coordinateBBox=this.viewBBox,this},e.prototype.option=function(t,n){if(e.prototype[t])throw new Error(`Can't use built in variable name "`.concat(t,'", please change another one.'));return(0,f.t8)(this.options,t,n),this},e.prototype.theme=function(t){return this.themeObject=(0,f.Kn)(t)?(0,f.b$)({},this.themeObject,Ms(t)):eo(t),this},e.prototype.interaction=function(t,n){var i=this.interactions[t];i&&i.destroy();var a=iw(t,this,n);return a&&(a.init(),this.interactions[t]=a),this},e.prototype.removeInteraction=function(t){var n=this.interactions[t];n&&(n.destroy(),this.interactions[t]=void 0)},e.prototype.changeData=function(t){this.isDataChanged=!0,this.emit(X.BEFORE_CHANGE_DATA,lr.fromData(this,X.BEFORE_CHANGE_DATA,null)),this.data(t),this.paint(!0);for(var n=this.views,i=0,a=n.length;i<a;i++){var o=n[i];o.changeData(t)}this.emit(X.AFTER_CHANGE_DATA,lr.fromData(this,X.AFTER_CHANGE_DATA,null))},e.prototype.createView=function(t){this.parent&&this.parent.parent&&console.warn("The view nesting recursive feature will be removed at G2 V4.1. Please avoid to use it.");var n={data:this.options.data,scales:(0,f.d9)(this.options.scales),axes:(0,f.d9)(this.options.axes),coordinate:(0,f.d9)(this.coordinateController.getOption()),tooltip:(0,f.d9)(this.options.tooltip),legends:(0,f.d9)(this.options.legends),animate:this.options.animate,visible:this.visible},i=new e((0,p.pi)((0,p.pi)({parent:this,canvas:this.canvas,backgroundGroup:this.backgroundGroup.addGroup({zIndex:Mt.BG}),middleGroup:this.middleGroup.addGroup({zIndex:Mt.MID}),foregroundGroup:this.foregroundGroup.addGroup({zIndex:Mt.FORE}),theme:this.themeObject,padding:this.padding},t),{options:(0,p.pi)((0,p.pi)({},n),(0,f.U2)(t,"options",{}))}));return this.views.push(i),i},e.prototype.view=function(t){return console.warn("This method will be removed at G2 V4.1. Please use chart.createView() instead."),this.createView(t)},e.prototype.removeView=function(t){var n=(0,f.Od)(this.views,function(i){return i===t})[0];return n&&n.destroy(),n},e.prototype.getCoordinate=function(){return this.coordinateInstance},e.prototype.getTheme=function(){return this.themeObject},e.prototype.getXScale=function(){var t=this.geometries[0];return t?t.getXScale():null},e.prototype.getYScales=function(){var t={},n=[];return this.geometries.forEach(function(i){var a=i.getYScale(),o=a.field;t[o]||(t[o]=!0,n.push(a))}),n},e.prototype.getScalesByDim=function(t){for(var n=this.geometries,i={},a=0,o=n.length;a<o;a++){var s=n[a],l=t==="x"?s.getXScale():s.getYScale();l&&!i[l.field]&&(i[l.field]=l)}return i},e.prototype.getScale=function(t,n){var i=n||this.getScaleKey(t);return this.getRootView().scalePool.getScale(i)},e.prototype.getScaleByField=function(t,n){return this.getScale(t,n)},e.prototype.getOptions=function(){return this.options},e.prototype.getData=function(){return this.filteredData},e.prototype.getOriginalData=function(){return this.options.data},e.prototype.getPadding=function(){return this.autoPadding.getPadding()},e.prototype.getGeometries=function(){return this.geometries},e.prototype.getElements=function(){return(0,f.u4)(this.geometries,function(t,n){return t.concat(n.getElements())},[])},e.prototype.getElementsBy=function(t){return this.getElements().filter(function(n){return t(n)})},e.prototype.getLayer=function(t){return t===J.BG?this.backgroundGroup:t===J.MID?this.middleGroup:t===J.FORE?this.foregroundGroup:this.foregroundGroup},e.prototype.isPointInPlot=function(t){return Q1(this.getCoordinate(),t)},e.prototype.getLegendAttributes=function(){return(0,f.xH)(this.geometries.map(function(t){return t.getGroupAttributes()}))},e.prototype.getGroupScales=function(){var t=this.geometries.map(function(n){return n.getGroupScales()});return ti((0,f.xH)(t))},e.prototype.getCanvas=function(){return this.getRootView().canvas},e.prototype.getRootView=function(){for(var t=this;;){if(t.parent){t=t.parent;continue}break}return t},e.prototype.getXY=function(t){var n=this.getCoordinate(),i=this.getScalesByDim("x"),a=this.getScalesByDim("y"),o,s;if((0,f.S6)(t,function(l,u){i[u]&&(o=i[u].scale(l)),a[u]&&(s=a[u].scale(l))}),!(0,f.UM)(o)&&!(0,f.UM)(s))return n.convert({x:o,y:s})},e.prototype.getController=function(t){return(0,f.sE)(this.controllers,function(n){return n.name===t})},e.prototype.showTooltip=function(t){var n=this.getController("tooltip");return n&&n.showTooltip(t),this},e.prototype.hideTooltip=function(){var t=this.getController("tooltip");return t&&t.hideTooltip(),this},e.prototype.lockTooltip=function(){var t=this.getController("tooltip");return t&&t.lockTooltip(),this},e.prototype.unlockTooltip=function(){var t=this.getController("tooltip");return t&&t.unlockTooltip(),this},e.prototype.isTooltipLocked=function(){var t=this.getController("tooltip");return t&&t.isTooltipLocked()},e.prototype.getTooltipItems=function(t){var n=this.getController("tooltip");return n?n.getTooltipItems(t):[]},e.prototype.getSnapRecords=function(t){for(var n=this.geometries,i=[],a=0,o=n.length;a<o;a++){var s=n[a],l=s.dataArray;s.sort(l);for(var u=void 0,c=0,h=l.length;c<h;c++){var v=l[c];u=wv(t,v,s),u&&i.push(u)}}for(var d=this.views,a=0,o=d.length;a<o;a++){var g=d[a],y=g.getSnapRecords(t);i=i.concat(y)}return i},e.prototype.getComponents=function(){for(var t=[],n=this.controllers,i=0,a=n.length;i<a;i++){var o=n[i];t=t.concat(o.getComponents())}return t},e.prototype.filterData=function(t){var n=this.options.filters;return(0,f.dp)(n)===0?t:(0,f.hX)(t,function(i,a){var o=Object.keys(n);return o.every(function(s){var l=n[s];return l(i[s],i,a)})})},e.prototype.filterFieldData=function(t,n){var i=this.options.filters,a=(0,f.U2)(i,t);return(0,f.o8)(a)?n:n.filter(function(o,s){return a(o[t],o,s)})},e.prototype.adjustCoordinate=function(){var t=this.getCoordinate(),n=t.start,i=t.end,a=this.coordinateBBox.bl,o=this.coordinateBBox.tr;if((0,f.Xy)(n,a)&&(0,f.Xy)(i,o)){this.isCoordinateChanged=!1;return}this.isCoordinateChanged=!0,this.coordinateInstance=this.coordinateController.adjust(a,o)},e.prototype.paint=function(t){this.renderDataRecursive(t),this.syncScale(),this.emit(X.BEFORE_PAINT),this.renderPaddingRecursive(t),this.renderLayoutRecursive(t),this.renderBackgroundStyleShape(),this.renderPaintRecursive(t),this.emit(X.AFTER_PAINT),this.isDataChanged=!1},e.prototype.renderBackgroundStyleShape=function(){if(!this.parent){var t=(0,f.U2)(this.themeObject,"background");if(t){this.backgroundStyleRectShape||(this.backgroundStyleRectShape=this.backgroundGroup.addShape("rect",{attrs:{},zIndex:-1,capture:!1}),this.backgroundStyleRectShape.toBack());var n=this.viewBBox,i=n.x,a=n.y,o=n.width,s=n.height;this.backgroundStyleRectShape.attr({fill:t,x:i,y:a,width:o,height:s})}else this.backgroundStyleRectShape&&(this.backgroundStyleRectShape.remove(!0),this.backgroundStyleRectShape=void 0)}},e.prototype.renderPaddingRecursive=function(t){this.calculateViewBBox(),this.adjustCoordinate(),this.initComponents(t),this.autoPadding=Ew(this).shrink(Lu(this.appendPadding)),this.coordinateBBox=this.viewBBox.shrink(this.autoPadding.getPadding()),this.adjustCoordinate();var n=this.controllers.find(function(l){return l.name==="tooltip"});n.update();for(var i=this.views,a=0,o=i.length;a<o;a++){var s=i[a];s.renderPaddingRecursive(t)}},e.prototype.renderLayoutRecursive=function(t){var n=this.syncViewPadding===!0?_w:(0,f.mf)(this.syncViewPadding)?this.syncViewPadding:void 0;n&&(n(this,this.views,Ss),this.views.forEach(function(l){l.coordinateBBox=l.viewBBox.shrink(l.autoPadding.getPadding()),l.adjustCoordinate()})),this.doLayout();for(var i=this.views,a=0,o=i.length;a<o;a++){var s=i[a];s.renderLayoutRecursive(t)}},e.prototype.renderPaintRecursive=function(t){var n=this.middleGroup;if(this.limitInPlot){var i=xu(this.coordinateInstance),a=i.type,o=i.attrs;n.setClip({type:a,attrs:o})}else n.setClip(void 0);this.paintGeometries(t),this.renderComponents(t);for(var s=this.views,l=0,u=s.length;l<u;l++){var c=s[l];c.renderPaintRecursive(t)}},e.prototype.createScale=function(t,n,i,a){var o=(0,f.U2)(this.options.scales,[t]),s=(0,p.pi)((0,p.pi)({},o),i);return this.parent?this.parent.createScale(t,n,s,a):this.scalePool.createScale(t,n,s,a)},e.prototype.renderDataRecursive=function(t){this.doFilterData(),this.createCoordinate(),this.initGeometries(t),this.renderFacet(t);for(var n=this.views,i=0,a=n.length;i<a;i++){var o=n[i];o.renderDataRecursive(t)}},e.prototype.calculateViewBBox=function(){var t,n,i,a;if(this.parent){var o=this.parent.coordinateBBox;t=o.x,n=o.y,i=o.width,a=o.height}else t=0,n=0,i=this.canvas.get("width"),a=this.canvas.get("height");var s=this.region,l=s.start,u=s.end,c=new Ir(t+i*l.x,n+a*l.y,i*(u.x-l.x),a*(u.y-l.y));(!this.viewBBox||!this.viewBBox.isEqual(c))&&(this.viewBBox=new Ir(t+i*l.x,n+a*l.y,i*(u.x-l.x),a*(u.y-l.y))),this.coordinateBBox=this.viewBBox},e.prototype.initEvents=function(){this.foregroundGroup.on("*",this.onDelegateEvents),this.middleGroup.on("*",this.onDelegateEvents),this.backgroundGroup.on("*",this.onDelegateEvents),this.canvas.on("*",this.onCanvasEvent)},e.prototype.initComponentController=function(){for(var t=this.usedControllers,n=0,i=t.length;n<i;n++){var a=t[n],o=ww(a);o&&this.controllers.push(new o(this))}},e.prototype.createViewEvent=function(t){var n=t.shape,i=t.name,a=n?n.get("origin"):null,o=new lr(this,t,a);return o.type=i,o},e.prototype.doPlotEvent=function(t){var n=t.type,i=t.x,a=t.y,o={x:i,y:a},s=["mousedown","mouseup","mousemove","mouseleave","mousewheel","touchstart","touchmove","touchend","touchcancel","click","dblclick","contextmenu"];if(s.includes(n)){var l=this.isPointInPlot(o),u=t.clone();if(l){var c="plot:".concat(n);u.type=c,this.emit(c,u),(n==="mouseleave"||n==="touchend")&&(this.isPreMouseInPlot=!1)}n==="mousemove"||n==="touchmove"?(this.isPreMouseInPlot&&!l?(n==="mousemove"&&(u.type=Et.MOUSE_LEAVE,this.emit(Et.MOUSE_LEAVE,u)),u.type=Et.LEAVE,this.emit(Et.LEAVE,u)):!this.isPreMouseInPlot&&l&&(n==="mousemove"&&(u.type=Et.MOUSE_ENTER,this.emit(Et.MOUSE_ENTER,u)),u.type=Et.ENTER,this.emit(Et.ENTER,u)),this.isPreMouseInPlot=l):(n==="mouseleave"||n==="touchend")&&this.isPreMouseInPlot&&(n==="mouseleave"&&(u.type=Et.MOUSE_LEAVE,this.emit(Et.MOUSE_LEAVE,u)),u.type=Et.LEAVE,this.emit(Et.LEAVE,u),this.isPreMouseInPlot=!1)}},e.prototype.doFilterData=function(){var t=this.options.data;this.filteredData=this.filterData(t)},e.prototype.initGeometries=function(t){this.createOrUpdateScales();for(var n=this.getCoordinate(),i=(0,f.U2)(this.options,"scales",{}),a=this.geometries,o=0,s=a.length;o<s;o++){var l=a[o];l.scales=this.getGeometryScales();var u={coordinate:n,scaleDefs:i,data:this.filteredData,theme:this.themeObject,isDataChanged:this.isDataChanged,isCoordinateChanged:this.isCoordinateChanged};t?l.update(u):l.init(u)}this.adjustScales()},e.prototype.createOrUpdateScales=function(){for(var t=this.getScaleFields(),n=this.getGroupedFields(),i=this.getOptions(),a=i.data,o=i.scales,s=o===void 0?{}:o,l=this.filteredData,u=0,c=t.length;u<c;u++){var h=t[u],v=s[h],d=this.getScaleKey(h);this.createScale(h,n.includes(h)?a:l,v,d),this.createdScaleKeys.set(d,!0)}},e.prototype.syncScale=function(){this.getRootView().scalePool.sync(this.getCoordinate(),this.theme)},e.prototype.getGeometryScales=function(){for(var t=this.getScaleFields(),n={},i=0;i<t.length;i++){var a=t[i];n[a]=this.getScaleByField(a)}return n},e.prototype.getScaleFields=function(){for(var t=[],n=new Map,i=this.geometries,a=0;a<i.length;a++){var o=i[a],s=o.getScaleFields();ti(s,t,n)}return t},e.prototype.getGroupedFields=function(){for(var t=[],n=new Map,i=this.geometries,a=0;a<i.length;a++){var o=i[a],s=o.getGroupFields();ti(s,t,n)}return t},e.prototype.adjustScales=function(){this.adjustCategoryScaleRange()},e.prototype.adjustCategoryScaleRange=function(){var t=this,n=(0,p.ev)([this.getXScale()],(0,p.CR)(this.getYScales()),!1).filter(function(o){return!!o}),i=this.getCoordinate(),a=this.options.scales;(0,f.S6)(n,function(o){var s=o.field,l=o.values,u=o.isCategory,c=o.isIdentity;(u||c)&&l&&!(0,f.U2)(a,[s,"range"])&&(o.range=Ih(o,i,t.theme))})},e.prototype.initComponents=function(t){for(var n=this.controllers,i=0;i<n.length;i++){var a=n[i];t?a.update():(a.clear(),a.render())}},e.prototype.doLayout=function(){this.layoutFunc(this)},e.prototype.createCoordinate=function(){var t=this.coordinateBBox.bl,n=this.coordinateBBox.tr;this.coordinateInstance=this.coordinateController.create(t,n)},e.prototype.paintGeometries=function(t){for(var n=this.options.animate,i=this.getCoordinate(),a={x:this.viewBBox.x,y:this.viewBBox.y,minX:this.viewBBox.minX,minY:this.viewBBox.minY,maxX:this.viewBBox.maxX,maxY:this.viewBBox.maxY,width:this.viewBBox.width,height:this.viewBBox.height},o=this.geometries,s=0;s<o.length;s++){var l=o[s];l.coordinate=i,l.canvasRegion=a,n||l.animate(!1),l.paint(t)}},e.prototype.renderComponents=function(t){for(var n=this.getComponents(),i=0;i<n.length;i++){var a=n[i];a.component.render()}},e.prototype.renderFacet=function(t){this.facetInstance&&(t?this.facetInstance.update():(this.facetInstance.clear(),this.facetInstance.init(),this.facetInstance.render()))},e.prototype.initOptions=function(){var t=this,n=this.options,i=n.geometries,a=i===void 0?[]:i,o=n.interactions,s=o===void 0?[]:o,l=n.views,u=l===void 0?[]:l,c=n.annotations,h=c===void 0?[]:c,v=n.coordinate,d=n.events,g=n.facets;this.coordinateController?v&&this.coordinateController.update(v):this.coordinateController=new Cw(v);for(var y=0;y<a.length;y++){var x=a[y];this.createGeometry(x)}for(var m=0;m<s.length;m++){var M=s[m],w=M.type,S=M.cfg;this.interaction(w,S)}for(var b=0;b<u.length;b++){var k=u[b];this.createView(k)}for(var H=this.getController("annotation"),at=0;at<h.length;at++){var At=h[at];H.annotation(At)}d&&(0,f.S6)(d,function(gt,Nt){t.on(Nt,gt)}),g&&(0,f.S6)(g,function(gt){var Nt=gt.type,te=(0,p._T)(gt,["type"]);t.facet(Nt,te)})},e.prototype.createGeometry=function(t){var n=t.type,i=t.cfg,a=i===void 0?{}:i;if(this[n]){var o=this[n](a);(0,f.S6)(t,function(s,l){(0,f.mf)(o[l])&&o[l](s)})}},e.prototype.getScaleKey=function(t){return"".concat(this.id,"-").concat(t)},e}(P);function Tn(r,e){Av.prototype[r.toLowerCase()]=function(t){t===void 0&&(t={});var n=(0,p.pi)({container:this.middleGroup.addGroup(),labelsContainer:this.foregroundGroup.addGroup()},t),i=new e(n);return this.geometries.push(i),i}}var Fw=Av,Iw=function(r){(0,p.ZT)(e,r);function e(t){var n=this,i=t.container,a=t.width,o=t.height,s=t.autoFit,l=s===void 0?!1:s,u=t.padding,c=t.appendPadding,h=t.renderer,v=h===void 0?"canvas":h,d=t.pixelRatio,g=t.localRefresh,y=g===void 0?!0:g,x=t.visible,m=x===void 0?!0:x,M=t.supportCSSTransform,w=M===void 0?!1:M,S=t.defaultInteractions,b=S===void 0?["tooltip","legend-filter","legend-active","continuous-filter","ellipsis-text","axis-description"]:S,k=t.options,H=t.limitInPlot,at=t.theme,At=t.syncViewPadding,gt=(0,f.HD)(i)?document.getElementById(i):i,Nt=V('<div style="position:relative;"></div>');gt.appendChild(Nt);var te=D(gt,l,a,o),ce=Bt(v),Me=new ce.Canvas((0,p.pi)({container:Nt,pixelRatio:d,localRefresh:y,supportCSSTransform:w},te));return n=r.call(this,{parent:null,canvas:Me,backgroundGroup:Me.addGroup({zIndex:Mt.BG}),middleGroup:Me.addGroup({zIndex:Mt.MID}),foregroundGroup:Me.addGroup({zIndex:Mt.FORE}),padding:u,appendPadding:c,visible:m,options:k,limitInPlot:H,theme:at,syncViewPadding:At})||this,n.onResize=(0,f.Ds)(function(){n.forceFit()},300),n.ele=gt,n.canvas=Me,n.width=te.width,n.height=te.height,n.autoFit=l,n.localRefresh=y,n.renderer=v,n.wrapperElement=Nt,n.updateCanvasStyle(),n.bindAutoFit(),n.initDefaultInteractions(b),n}return e.prototype.initDefaultInteractions=function(t){var n=this;(0,f.S6)(t,function(i){n.interaction(i)})},e.prototype.aria=function(t){var n="aria-label";t===!1?this.ele.removeAttribute(n):this.ele.setAttribute(n,t.label)},e.prototype.changeSize=function(t,n){return this.width===t&&this.height===n?this:(this.emit(X.BEFORE_CHANGE_SIZE),this.width=t,this.height=n,this.canvas.changeSize(t,n),this.render(!0),this.emit(X.AFTER_CHANGE_SIZE),this)},e.prototype.clear=function(){r.prototype.clear.call(this),this.aria(!1)},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.unbindAutoFit(),this.canvas.destroy(),E(this.wrapperElement),this.wrapperElement=null},e.prototype.changeVisible=function(t){return r.prototype.changeVisible.call(this,t),this.wrapperElement.style.display=t?"":"none",this},e.prototype.forceFit=function(){if(!this.destroyed){var t=D(this.ele,!0,this.width,this.height),n=t.width,i=t.height;this.changeSize(n,i)}},e.prototype.updateCanvasStyle=function(){G(this.canvas.get("el"),{display:"inline-block",verticalAlign:"middle"})},e.prototype.bindAutoFit=function(){this.autoFit&&window.addEventListener("resize",this.onResize)},e.prototype.unbindAutoFit=function(){this.autoFit&&window.removeEventListener("resize",this.onResize)},e}(Fw),Pw=Iw,ua=function(){function r(e){this.visible=!0,this.components=[],this.view=e}return r.prototype.clear=function(e){(0,f.S6)(this.components,function(t){t.component.destroy()}),this.components=[]},r.prototype.destroy=function(){this.clear()},r.prototype.getComponents=function(){return this.components},r.prototype.changeVisible=function(e){this.visible!==e&&(this.components.forEach(function(t){e?t.component.show():t.component.hide()}),this.visible=e)},r}();function Lw(r){for(var e=[],t=function(i){var a=r[i],o=(0,f.sE)(e,function(s){return s.color===a.color&&s.name===a.name&&s.value===a.value&&s.title===a.title});o||e.push(a)},n=0;n<r.length;n++)t(n);return e}var Dw=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.isLocked=!1,t}return Object.defineProperty(e.prototype,"name",{get:function(){return"tooltip"},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.isVisible=function(){var t=this.view.getOptions().tooltip;return t!==!1},e.prototype.render=function(){},e.prototype.showTooltip=function(t){if(this.point=t,!!this.isVisible()){var n=this.view,i=this.getTooltipItems(t);if(!i.length){this.hideTooltip();return}var a=this.getTitle(i),o={x:i[0].x,y:i[0].y};n.emit("tooltip:show",lr.fromData(n,"tooltip:show",(0,p.pi)({items:i,title:a},t)));var s=this.getTooltipCfg(),l=s.follow,u=s.showMarkers,c=s.showCrosshairs,h=s.showContent,v=s.marker,d=this.items,g=this.title;if(!(0,f.Xy)(g,a)||!(0,f.Xy)(d,i)?(n.emit("tooltip:change",lr.fromData(n,"tooltip:change",(0,p.pi)({items:i,title:a},t))),((0,f.mf)(h)?h(i):h)&&(this.tooltip||this.renderTooltip(),this.tooltip.update((0,f.CD)({},s,{items:this.getItemsAfterProcess(i),title:a},l?t:{})),this.tooltip.show()),u&&this.renderTooltipMarkers(i,v)):(this.tooltip&&l&&(this.tooltip.update(t),this.tooltip.show()),this.tooltipMarkersGroup&&this.tooltipMarkersGroup.show()),this.items=i,this.title=a,c){var y=(0,f.U2)(s,["crosshairs","follow"],!1);this.renderCrosshairs(y?t:o,s)}}},e.prototype.hideTooltip=function(){var t=this.getTooltipCfg().follow;if(!t){this.point=null;return}var n=this.tooltipMarkersGroup;n&&n.hide();var i=this.xCrosshair,a=this.yCrosshair;i&&i.hide(),a&&a.hide();var o=this.tooltip;o&&o.hide(),this.view.emit("tooltip:hide",lr.fromData(this.view,"tooltip:hide",{})),this.point=null},e.prototype.lockTooltip=function(){this.isLocked=!0,this.tooltip&&this.tooltip.setCapture(!0)},e.prototype.unlockTooltip=function(){this.isLocked=!1;var t=this.getTooltipCfg();this.tooltip&&this.tooltip.setCapture(t.capture)},e.prototype.isTooltipLocked=function(){return this.isLocked},e.prototype.clear=function(){var t=this,n=t.tooltip,i=t.xCrosshair,a=t.yCrosshair,o=t.tooltipMarkersGroup;n&&(n.hide(),n.clear()),i&&i.clear(),a&&a.clear(),o&&o.clear(),(n==null?void 0:n.get("customContent"))&&(this.tooltip.destroy(),this.tooltip=null),this.title=null,this.items=null},e.prototype.destroy=function(){this.tooltip&&this.tooltip.destroy(),this.xCrosshair&&this.xCrosshair.destroy(),this.yCrosshair&&this.yCrosshair.destroy(),this.guideGroup&&this.guideGroup.remove(!0),this.reset()},e.prototype.reset=function(){this.items=null,this.title=null,this.tooltipMarkersGroup=null,this.tooltipCrosshairsGroup=null,this.xCrosshair=null,this.yCrosshair=null,this.tooltip=null,this.guideGroup=null,this.isLocked=!1,this.point=null},e.prototype.changeVisible=function(t){if(this.visible!==t){var n=this,i=n.tooltip,a=n.tooltipMarkersGroup,o=n.xCrosshair,s=n.yCrosshair;t?(i&&i.show(),a&&a.show(),o&&o.show(),s&&s.show()):(i&&i.hide(),a&&a.hide(),o&&o.hide(),s&&s.hide()),this.visible=t}},e.prototype.getTooltipItems=function(t){var n,i,a,o,s,l,u=this.findItemsFromView(this.view,t);if(u.length){u=(0,f.xH)(u);try{for(var c=(0,p.XA)(u),h=c.next();!h.done;h=c.next()){var v=h.value;try{for(var d=(a=void 0,(0,p.XA)(v)),g=d.next();!g.done;g=d.next()){var y=g.value,x=y.mappingData,m=x.x,M=x.y;y.x=(0,f.kJ)(m)?m[m.length-1]:m,y.y=(0,f.kJ)(M)?M[M.length-1]:M}}catch(gt){a={error:gt}}finally{try{g&&!g.done&&(o=d.return)&&o.call(d)}finally{if(a)throw a.error}}}}catch(gt){n={error:gt}}finally{try{h&&!h.done&&(i=c.return)&&i.call(c)}finally{if(n)throw n.error}}var w=this.getTooltipCfg().shared;if(w===!1&&u.length>1){var S=u[0],b=Math.abs(t.y-S[0].y);try{for(var k=(0,p.XA)(u),H=k.next();!H.done;H=k.next()){var at=H.value,At=Math.abs(t.y-at[0].y);At<=b&&(S=at,b=At)}}catch(gt){s={error:gt}}finally{try{H&&!H.done&&(l=k.return)&&l.call(k)}finally{if(s)throw s.error}}u=[S]}return Lw((0,f.xH)(u))}return[]},e.prototype.layout=function(){},e.prototype.update=function(){if(this.point&&this.showTooltip(this.point),this.tooltip){var t=this.view.getCanvas();this.tooltip.set("region",{start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}})}},e.prototype.isCursorEntered=function(t){if(this.tooltip){var n=this.tooltip.getContainer(),i=this.tooltip.get("capture");if(n&&i){var a=n.getBoundingClientRect(),o=a.x,s=a.y,l=a.width,u=a.height;return new Ir(o,s,l,u).isPointIn(t)}}return!1},e.prototype.getTooltipCfg=function(){var t=this.view,n=t.getOptions().tooltip,i=this.processCustomContent(n),a=t.getTheme(),o=(0,f.U2)(a,["components","tooltip"],{}),s=(0,f.U2)(i,"enterable",o.enterable);return(0,f.b$)({},o,i,{capture:!!(s||this.isLocked)})},e.prototype.processCustomContent=function(t){if((0,f.jn)(t)||!(0,f.U2)(t,"customContent"))return t;var n=t.customContent,i=function(a,o){var s=n(a,o)||"";return(0,f.HD)(s)?'<div class="g2-tooltip">'+s+"</div>":s};return(0,p.pi)((0,p.pi)({},t),{customContent:i})},e.prototype.getTitle=function(t){var n=t[0].title||t[0].name;return this.title=n,n},e.prototype.renderTooltip=function(){var t=this.view.getCanvas(),n={start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}},i=this.getTooltipCfg(),a=new us((0,p.pi)((0,p.pi)({parent:t.get("el").parentNode,region:n},i),{visible:!1,crosshairs:null}));a.init(),this.tooltip=a},e.prototype.renderTooltipMarkers=function(t,n){var i,a,o=this.getTooltipMarkersGroup(),s=this.view.getRootView(),l=s.limitInPlot;try{for(var u=(0,p.XA)(t),c=u.next();!c.done;c=u.next()){var h=c.value,v=h.x,d=h.y;if(l||(o==null?void 0:o.getClip())){var g=xu(s.getCoordinate()),y=g.type,x=g.attrs;o==null||o.setClip({type:y,attrs:x})}else o==null||o.setClip(void 0);var m=this.view.getTheme(),M=(0,f.U2)(m,["components","tooltip","marker"],{}),w=(0,p.pi)((0,p.pi)({fill:h.color,symbol:"circle",shadowColor:h.color},(0,f.mf)(n)?(0,p.pi)((0,p.pi)({},M),n(h)):n),{x:v,y:d});o.addShape("marker",{attrs:w})}}catch(S){i={error:S}}finally{try{c&&!c.done&&(a=u.return)&&a.call(u)}finally{if(i)throw i.error}}},e.prototype.renderCrosshairs=function(t,n){var i=(0,f.U2)(n,["crosshairs","type"],"x");i==="x"?(this.yCrosshair&&this.yCrosshair.hide(),this.renderXCrosshairs(t,n)):i==="y"?(this.xCrosshair&&this.xCrosshair.hide(),this.renderYCrosshairs(t,n)):i==="xy"&&(this.renderXCrosshairs(t,n),this.renderYCrosshairs(t,n))},e.prototype.renderXCrosshairs=function(t,n){var i=this.getViewWithGeometry(this.view).getCoordinate(),a,o;if(i.isRect)i.isTransposed?(a={x:i.start.x,y:t.y},o={x:i.end.x,y:t.y}):(a={x:t.x,y:i.end.y},o={x:t.x,y:i.start.y});else{var s=ia(i,t),l=i.getCenter(),u=i.getRadius();o=hr(l.x,l.y,u,s),a=l}var c=(0,f.b$)({start:a,end:o,container:this.getTooltipCrosshairsGroup()},(0,f.U2)(n,"crosshairs",{}),this.getCrosshairsText("x",t,n));delete c.type;var h=this.xCrosshair;h?h.update(c):(h=new ih(c),h.init()),h.render(),h.show(),this.xCrosshair=h},e.prototype.renderYCrosshairs=function(t,n){var i=this.getViewWithGeometry(this.view).getCoordinate(),a,o;if(i.isRect){var s=void 0,l=void 0;i.isTransposed?(s={x:t.x,y:i.end.y},l={x:t.x,y:i.start.y}):(s={x:i.start.x,y:t.y},l={x:i.end.x,y:t.y}),a={start:s,end:l},o="Line"}else a={center:i.getCenter(),radius:cs(i,t),startAngle:i.startAngle,endAngle:i.endAngle},o="Circle";a=(0,f.b$)({container:this.getTooltipCrosshairsGroup()},a,(0,f.U2)(n,"crosshairs",{}),this.getCrosshairsText("y",t,n)),delete a.type;var u=this.yCrosshair;u?i.isRect&&u.get("type")==="circle"||!i.isRect&&u.get("type")==="line"?(u=new ut[o](a),u.init()):u.update(a):(u=new ut[o](a),u.init()),u.render(),u.show(),this.yCrosshair=u},e.prototype.getCrosshairsText=function(t,n,i){var a=(0,f.U2)(i,["crosshairs","text"]),o=(0,f.U2)(i,["crosshairs","follow"]),s=this.items;if(a){var l=this.getViewWithGeometry(this.view),u=s[0],c=l.getXScale(),h=l.getYScales()[0],v=void 0,d=void 0;if(o){var g=this.view.getCoordinate().invert(n);v=c.invert(g.x),d=h.invert(g.y)}else v=u.data[c.field],d=u.data[h.field];var y=t==="x"?v:d;return(0,f.mf)(a)?a=a(t,y,s,n):a.content=y,{text:a}}},e.prototype.getGuideGroup=function(){if(!this.guideGroup){var t=this.view.foregroundGroup;this.guideGroup=t.addGroup({name:"tooltipGuide",capture:!1})}return this.guideGroup},e.prototype.getTooltipMarkersGroup=function(){var t=this.tooltipMarkersGroup;return t&&!t.destroyed?(t.clear(),t.show()):(t=this.getGuideGroup().addGroup({name:"tooltipMarkersGroup"}),t.toFront(),this.tooltipMarkersGroup=t),t},e.prototype.getTooltipCrosshairsGroup=function(){var t=this.tooltipCrosshairsGroup;return t||(t=this.getGuideGroup().addGroup({name:"tooltipCrosshairsGroup",capture:!1}),t.toBack(),this.tooltipCrosshairsGroup=t),t},e.prototype.findItemsFromView=function(t,n){var i,a;if(t.getOptions().tooltip===!1)return[];var o=this.getTooltipCfg(),s=Pu(t,n,o);try{for(var l=(0,p.XA)(t.views),u=l.next();!u.done;u=l.next()){var c=u.value;s=s.concat(this.findItemsFromView(c,n))}}catch(h){i={error:h}}finally{try{u&&!u.done&&(a=l.return)&&a.call(l)}finally{if(i)throw i.error}}return s},e.prototype.getViewWithGeometry=function(t){var n=this;return t.geometries.length?t:(0,f.sE)(t.views,function(i){return n.getViewWithGeometry(i)})},e.prototype.getItemsAfterProcess=function(t){var n=this.getTooltipCfg().customItems,i=n||function(a){return a};return i(t)},e}(ua),bv=Dw,Tv={};function Ev(r){return Tv[r.toLowerCase()]}function qr(r,e){Tv[r.toLowerCase()]=e}var ca={appear:{duration:450,easing:"easeQuadOut"},update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}},Ow={interval:function(r){return{enter:{animation:r.isRect?r.isTransposed?"scale-in-x":"scale-in-y":"fade-in"},update:{animation:r.isPolar&&r.isTransposed?"sector-path-update":null},leave:{animation:"fade-out"}}},line:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},path:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},point:{appear:{animation:"zoom-in"},enter:{animation:"zoom-in"},leave:{animation:"zoom-out"}},area:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},polygon:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},schema:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},edge:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},label:{appear:{animation:"fade-in",delay:450},enter:{animation:"fade-in"},update:{animation:"position-update"},leave:{animation:"fade-out"}}},_v={line:function(){return{animation:"wave-in"}},area:function(){return{animation:"wave-in"}},path:function(){return{animation:"fade-in"}},interval:function(r){var e;return r.isRect?e=r.isTransposed?"grow-in-x":"grow-in-y":(e="grow-in-xy",r.isPolar&&r.isTransposed&&(e="wave-in")),{animation:e}},schema:function(r){var e;return r.isRect?e=r.isTransposed?"grow-in-x":"grow-in-y":e="grow-in-xy",{animation:e}},polygon:function(){return{animation:"fade-in",duration:500}},edge:function(){return{animation:"fade-in"}}};function kw(r,e){return{delay:(0,f.mf)(r.delay)?r.delay(e):r.delay,easing:(0,f.mf)(r.easing)?r.easing(e):r.easing,duration:(0,f.mf)(r.duration)?r.duration(e):r.duration,callback:r.callback,repeat:r.repeat}}function Fv(r,e,t){var n=Ow[r];return n&&((0,f.mf)(n)&&(n=n(e)),n=(0,f.b$)({},ca,n),t)?n[t]:n}function fa(r,e,t){var n=(0,f.U2)(r.get("origin"),"data",ee),i=e.animation,a=kw(e,n);if(i){var o=Ev(i);o&&o(r,a,t)}else r.animate(t.toAttrs,a)}function Bw(r,e,t,n,i){if(_v[t]){var a=_v[t](n),o=Ev((0,f.U2)(a,"animation",""));if(o){var s=(0,p.pi)((0,p.pi)((0,p.pi)({},ca.appear),a),e);r.stopAnimate(),o(r,s,{coordinate:n,minYPoint:i,toAttrs:null})}}}var Du="element-background",Rw=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.labelShape=[],n.states=[];var i=t.shapeFactory,a=t.container,o=t.offscreenGroup,s=t.elementIndex,l=t.visible,u=l===void 0?!0:l;return n.shapeFactory=i,n.container=a,n.offscreenGroup=o,n.visible=u,n.elementIndex=s,n}return e.prototype.draw=function(t,n){n===void 0&&(n=!1),this.model=t,this.data=t.data,this.shapeType=this.getShapeType(t),this.drawShape(t,n),this.visible===!1&&this.changeVisible(!1)},e.prototype.update=function(t){var n=this,i=n.shapeFactory,a=n.shape;if(!!a){this.model=t,this.data=t.data,this.shapeType=this.getShapeType(t),this.setShapeInfo(a,t);var o=this.getOffscreenGroup(),s=i.drawShape(this.shapeType,t,o);s.cfg.data=this.data,s.cfg.origin=t,s.cfg.element=this,this.syncShapeStyle(a,s,this.getStates(),this.getAnimateCfg("update"))}},e.prototype.destroy=function(){var t=this,n=t.shapeFactory,i=t.shape;if(i){var a=this.getAnimateCfg("leave");a?fa(i,a,{coordinate:n.coordinate,toAttrs:(0,p.pi)({},i.attr())}):i.remove(!0)}this.states=[],this.shapeFactory=void 0,this.container=void 0,this.shape=void 0,this.animate=void 0,this.geometry=void 0,this.labelShape=[],this.model=void 0,this.data=void 0,this.offscreenGroup=void 0,this.statesStyle=void 0,r.prototype.destroy.call(this)},e.prototype.changeVisible=function(t){r.prototype.changeVisible.call(this,t),t?(this.shape&&this.shape.show(),this.labelShape&&this.labelShape.forEach(function(n){n.show()})):(this.shape&&this.shape.hide(),this.labelShape&&this.labelShape.forEach(function(n){n.hide()}))},e.prototype.setState=function(t,n){var i=this,a=i.states,o=i.shapeFactory,s=i.model,l=i.shape,u=i.shapeType,c=a.indexOf(t);if(n){if(c>-1)return;a.push(t),(t==="active"||t==="selected")&&(l==null||l.toFront())}else{if(c===-1)return;if(a.splice(c,1),t==="active"||t==="selected"){var h=this.geometry,v=h.sortZIndex,d=h.zIndexReversed,g=d?this.geometry.elements.length-this.elementIndex:this.elementIndex;v?l.setZIndex(g):l.set("zIndex",g)}}var y=o.drawShape(u,s,this.getOffscreenGroup());a.length?this.syncShapeStyle(l,y,a,null):this.syncShapeStyle(l,y,["reset"],null),y.remove(!0);var x={state:t,stateStatus:n,element:this,target:this.container};this.container.emit("statechange",x),Xf(this.shape,"statechange",x)},e.prototype.clearStates=function(){var t=this,n=this.states;(0,f.S6)(n,function(i){t.setState(i,!1)}),this.states=[]},e.prototype.hasState=function(t){return this.states.includes(t)},e.prototype.getStates=function(){return this.states},e.prototype.getData=function(){return this.data},e.prototype.getModel=function(){return this.model},e.prototype.getBBox=function(){var t=this,n=t.shape,i=t.labelShape,a={x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0};return n&&(a=n.getCanvasBBox()),i&&i.forEach(function(o){var s=o.getCanvasBBox();a.x=Math.min(s.x,a.x),a.y=Math.min(s.y,a.y),a.minX=Math.min(s.minX,a.minX),a.minY=Math.min(s.minY,a.minY),a.maxX=Math.max(s.maxX,a.maxX),a.maxY=Math.max(s.maxY,a.maxY)}),a.width=a.maxX-a.minX,a.height=a.maxY-a.minY,a},e.prototype.getStatesStyle=function(){if(!this.statesStyle){var t=this,n=t.shapeType,i=t.geometry,a=t.shapeFactory,o=i.stateOption,s=a.defaultShapeType,l=a.theme[n]||a.theme[s];this.statesStyle=(0,f.b$)({},l,o)}return this.statesStyle},e.prototype.getStateStyle=function(t,n){var i=this.getStatesStyle(),a=(0,f.U2)(i,[t,"style"],{}),o=a[n]||a;return(0,f.mf)(o)?o(this):o},e.prototype.getAnimateCfg=function(t){var n=this,i=this.animate;if(i){var a=i[t];return a&&(0,p.pi)((0,p.pi)({},a),{callback:function(){var o;(0,f.mf)(a.callback)&&a.callback(),(o=n.geometry)===null||o===void 0||o.emit(st.AFTER_DRAW_ANIMATE)}})}return null},e.prototype.drawShape=function(t,n){var i;n===void 0&&(n=!1);var a=this,o=a.shapeFactory,s=a.container,l=a.shapeType;if(this.shape=o.drawShape(l,t,s),this.shape){this.setShapeInfo(this.shape,t);var u=this.shape.cfg.name;u?(0,f.HD)(u)&&(this.shape.cfg.name=["element",u]):this.shape.cfg.name=["element",this.shapeFactory.geometryType];var c=n?"enter":"appear",h=this.getAnimateCfg(c);h&&((i=this.geometry)===null||i===void 0||i.emit(st.BEFORE_DRAW_ANIMATE),fa(this.shape,h,{coordinate:o.coordinate,toAttrs:(0,p.pi)({},this.shape.attr())}))}},e.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var t=this.container.getGroupBase();this.offscreenGroup=new t({})}return this.offscreenGroup},e.prototype.setShapeInfo=function(t,n){var i=this;if(t.cfg.origin=n,t.cfg.element=this,t.isGroup()){var a=t.get("children");a.forEach(function(o){i.setShapeInfo(o,n)})}},e.prototype.syncShapeStyle=function(t,n,i,a,o){var s=this,l;if(i===void 0&&(i=[]),o===void 0&&(o=0),!(!t||!n)){var u=t.get("clipShape"),c=n.get("clipShape");if(this.syncShapeStyle(u,c,i,a),t.isGroup())for(var h=t.get("children"),v=n.get("children"),d=0;d<h.length;d++)this.syncShapeStyle(h[d],v[d],i,a,o+d);else{if(!(0,f.xb)(i)&&!(0,f.Xy)(i,["reset"])){var g=t.get("name");(0,f.kJ)(g)&&(g=g[1]),(0,f.S6)(i,function(x){if(n.get("name")!==Du){var m=s.getStateStyle(x,g||o);n.attr(m)}})}var y=_h(t,n);this.animate?a?((l=this.geometry)===null||l===void 0||l.emit(st.BEFORE_DRAW_ANIMATE),fa(t,a,{coordinate:this.shapeFactory.coordinate,toAttrs:y,shapeModel:this.model})):(0,f.xb)(i)?t.attr(y):(t.stopAnimate(),t.animate(y,{duration:300})):t.attr(y)}}},e.prototype.getShapeType=function(t){var n=(0,f.U2)(t,"shape");return(0,f.kJ)(n)?n[0]:n},e}(P),Iv=Rw,Pv={},Lv={};function Nw(r){return Pv[r.toLowerCase()]}function ro(r,e){Pv[r.toLowerCase()]=e}function Uw(r){return Lv[r.toLowerCase()]}function Ur(r,e){Lv[r.toLowerCase()]=e}var zw={coordinate:null,defaultShapeType:null,theme:null,getShapePoints:function(r,e){var t=this.getShape(r);return t.getPoints?t.getPoints(e):this.getDefaultPoints(e)},getShape:function(r){var e=this[r]||this[this.defaultShapeType];return e.coordinate=this.coordinate,e},getDefaultPoints:function(){return[]},getDefaultStyle:function(r){return(0,f.U2)(r,[this.defaultShapeType,"default","style"],{})},getMarker:function(r,e){var t=this.getShape(r);if(!t.getMarker){var n=this.defaultShapeType;t=this.getShape(n)}var i=this.theme,a=(0,f.U2)(i,[r,"default"],{}),o=t.getMarker(e);return(0,f.b$)({},a,o)},drawShape:function(r,e,t){var n=this.getShape(r);return n.draw(e,t)}},Vw={coordinate:null,parsePath:function(r){var e=this.coordinate,t=TM(r);return e.isPolar?t=xM(e,t):t=mM(e,t),t},parsePoint:function(r){var e=this.coordinate;return e.convert(r)},parsePoints:function(r){var e=this.coordinate;return r.map(function(t){return e.convert(t)})},draw:function(r,e){}},Ou={};function ni(r,e){var t=(0,f.jC)(r),n=(0,p.pi)((0,p.pi)((0,p.pi)({},zw),e),{geometryType:r});return Ou[t]=n,n}function Ke(r,e,t){var n=(0,f.jC)(r),i=Ou[n],a=(0,p.pi)((0,p.pi)({},Vw),t);return i[e]=a,a}function Dv(r){var e=(0,f.jC)(r);return Ou[e]}function Hw(r,e,t){var n,i;if(t===void 0&&(t={}),!e)return[r];var a=(0,f.Ms)(r,e),o=[];if(e.length===1&&t[e[0]]){var s=t[e[0]];try{for(var l=(0,p.XA)(s),u=l.next();!u.done;u=l.next()){var c=u.value,h=a["_".concat(c)];h&&o.push(h)}}catch(g){n={error:g}}finally{try{u&&!u.done&&(i=l.return)&&i.call(l)}finally{if(n)throw n.error}}}else for(var v in a)if(a.hasOwnProperty(v)){var d=a[v];o.push(d)}return o}function Ov(r,e){return(0,f.G)(["color","shape","size","x","y","isInCircle","data","style","defaultStyle","points","mappingData"],function(t){return!(0,f.Xy)(r[t],e[t])})}function no(r){return(0,f.kJ)(r)?r:r.split("*")}function kv(r,e){for(var t=[],n=[],i=[],a=new Map,o=0;o<e.length;o++){var s=e[o];r[s]?n.push(s):t.push(s),a.set(s,!0)}return Object.keys(r).forEach(function(l){a.has(l)||i.push(l)}),{added:t,updated:n,removed:i}}var Gw=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.type="base",n.attributes={},n.elements=[],n.elementsMap={},n.animateOption=!0,n.attributeOption={},n.lastElementsMap={},n.generatePoints=!1,n.beforeMappingData=null,n.adjusts={},n.idFields=[],n.hasSorted=!1,n.isCoordinateChanged=!1;var i=t.container,a=t.labelsContainer,o=t.coordinate,s=t.data,l=t.sortable,u=l===void 0?!1:l,c=t.visible,h=c===void 0?!0:c,v=t.theme,d=t.scales,g=d===void 0?{}:d,y=t.scaleDefs,x=y===void 0?{}:y,m=t.intervalPadding,M=t.dodgePadding,w=t.maxColumnWidth,S=t.minColumnWidth,b=t.columnWidthRatio,k=t.roseWidthRatio,H=t.multiplePieWidthRatio,at=t.zIndexReversed,At=t.sortZIndex,gt=t.useDeferredLabel;return n.container=i,n.labelsContainer=a,n.coordinate=o,n.data=s,n.sortable=u,n.visible=h,n.userTheme=v,n.scales=g,n.scaleDefs=x,n.intervalPadding=m,n.dodgePadding=M,n.maxColumnWidth=w,n.minColumnWidth=S,n.columnWidthRatio=b,n.roseWidthRatio=k,n.multiplePieWidthRatio=H,n.zIndexReversed=at,n.sortZIndex=At,n.useDeferredLabel=gt?typeof gt=="number"?gt:Infinity:null,n}return e.prototype.position=function(t){var n=t;(0,f.PO)(t)||(n={fields:no(t)});var i=(0,f.U2)(n,"fields");return i.length===1&&(i.unshift("1"),(0,f.t8)(n,"fields",i)),(0,f.t8)(this.attributeOption,"position",n),this},e.prototype.color=function(t,n){return this.createAttrOption("color",t,n),this},e.prototype.shape=function(t,n){return this.createAttrOption("shape",t,n),this},e.prototype.size=function(t,n){return this.createAttrOption("size",t,n),this},e.prototype.adjust=function(t){var n=t;return((0,f.HD)(t)||(0,f.PO)(t))&&(n=[t]),(0,f.S6)(n,function(i,a){(0,f.Kn)(i)||(n[a]={type:i})}),this.adjustOption=n,this},e.prototype.style=function(t,n){if((0,f.HD)(t)){var i=no(t);this.styleOption={fields:i,callback:n}}else{var a=t,i=a.fields,o=a.callback,s=a.cfg;i||o||s?this.styleOption=t:this.styleOption={cfg:t}}return this},e.prototype.tooltip=function(t,n){if((0,f.HD)(t)){var i=no(t);this.tooltipOption={fields:i,callback:n}}else this.tooltipOption=t;return this},e.prototype.animate=function(t){return this.animateOption=t,this},e.prototype.label=function(t,n,i){if((0,f.HD)(t)){var a={},o=no(t);a.fields=o,(0,f.mf)(n)?a.callback=n:(0,f.PO)(n)&&(a.cfg=n),i&&(a.cfg=i),this.labelOption=a}else this.labelOption=t;return this},e.prototype.state=function(t){return this.stateOption=t,this},e.prototype.customInfo=function(t){return this.customOption=t,this},e.prototype.init=function(t){t===void 0&&(t={}),this.setCfg(t),this.initAttributes(),this.processData(this.data),this.adjustScale()},e.prototype.update=function(t){t===void 0&&(t={});var n=t.data,i=t.isDataChanged,a=t.isCoordinateChanged,o=this,s=o.attributeOption,l=o.lastAttributeOption;(0,f.Xy)(s,l)?n&&(i||!(0,f.Xy)(n,this.data))?(this.setCfg(t),this.initAttributes(),this.processData(n)):this.setCfg(t):this.init(t),this.adjustScale(),this.isCoordinateChanged=a},e.prototype.paint=function(t){var n=this;t===void 0&&(t=!1),this.animateOption&&(this.animateOption=(0,f.b$)({},Fv(this.type,this.coordinate),this.animateOption)),this.defaultSize=void 0,this.elementsMap={},this.elements=[];var i=this.getOffscreenGroup();i.clear();var a=this.beforeMappingData,o=this.beforeMapping(a);this.dataArray=new Array(o.length);for(var s=0;s<o.length;s++){var l=o[s];this.dataArray[s]=this.mapping(l)}if(this.updateElements(this.dataArray,t),this.lastElementsMap=this.elementsMap,this.canDoGroupAnimation(t)){var u=this.container,c=this.type,h=this.coordinate,v=(0,f.U2)(this.animateOption,"appear"),d=this.getYScale(),g=h.convert({x:0,y:d.scale(this.getYMinValue())});Bw(u,v,c,h,g)}if(this.labelOption){var y=this.useDeferredLabel,x=function(){return n.renderLabels((0,f.xH)(n.dataArray),t)}.bind(this);if(typeof y=="number"){var m=typeof y=="number"&&y!==Infinity?y:0;if(!window.requestIdleCallback)setTimeout(x,m);else{var M=m&&m!==Infinity?{timeout:m}:void 0;window.requestIdleCallback(x,M)}}else x()}this.lastAttributeOption=(0,p.pi)({},this.attributeOption),this.visible===!1&&this.changeVisible(!1)},e.prototype.clear=function(){var t=this,n=t.container,i=t.geometryLabel,a=t.offscreenGroup;n&&n.clear(),i&&i.clear(),a&&a.clear(),this.scaleDefs=void 0,this.attributes={},this.scales={},this.elementsMap={},this.lastElementsMap={},this.elements=[],this.adjusts={},this.dataArray=null,this.beforeMappingData=null,this.lastAttributeOption=void 0,this.defaultSize=void 0,this.idFields=[],this.groupScales=void 0,this.hasSorted=!1,this.isCoordinateChanged=!1},e.prototype.destroy=function(){this.clear();var t=this.container;t.remove(!0),this.offscreenGroup&&(this.offscreenGroup.remove(!0),this.offscreenGroup=null),this.geometryLabel&&(this.geometryLabel.destroy(),this.geometryLabel=null),this.theme=void 0,this.shapeFactory=void 0,r.prototype.destroy.call(this)},e.prototype.getGroupScales=function(){return this.groupScales},e.prototype.getAttribute=function(t){return this.attributes[t]},e.prototype.getXScale=function(){return this.getAttribute("position").scales[0]},e.prototype.getYScale=function(){return this.getAttribute("position").scales[1]},e.prototype.getGroupAttributes=function(){var t=[];return(0,f.S6)(this.attributes,function(n){jt.includes(n.type)&&t.push(n)}),t},e.prototype.getDefaultValue=function(t){var n,i=this.getAttribute(t);return i&&(0,f.xb)(i.scales)&&(n=i.values[0]),n},e.prototype.getAttributeValues=function(t,n){for(var i=[],a=t.scales,o=0,s=a.length;o<s;o++){var l=a[o],u=l.field;l.isIdentity?i.push(l.values):i.push(n[u])}return t.mapping.apply(t,(0,p.ev)([],(0,p.CR)(i),!1))},e.prototype.getAdjust=function(t){return this.adjusts[t]},e.prototype.getCoordinate=function(){return this.coordinate},e.prototype.getData=function(){return this.data},e.prototype.getShapeMarker=function(t,n){var i=this.getShapeFactory();return i.getMarker(t,n)},e.prototype.getElementsBy=function(t){return this.elements.filter(function(n){return t(n)})},e.prototype.getElements=function(){return this.elements},e.prototype.getElementId=function(t){t=(0,f.kJ)(t)?t[0]:t;var n=t[ee];if(this.idFields.length){for(var i=n[this.idFields[0]],a=1;a<this.idFields.length;a++)i+="-"+n[this.idFields[a]];return i}var o=this.type,s=this.getXScale(),l=this.getYScale(),u=s.field||"x",c=l.field||"y",h=n[c],v;s.type==="identity"?v=s.values[0]:v=n[u];var d;o==="interval"||o==="schema"?d="".concat(v):o==="line"||o==="area"||o==="path"?d=o:d="".concat(v,"-").concat(h);for(var g=this.groupScales,a=0,y=g.length;a<y;a++){var x=g[a],m=x.field;d="".concat(d,"-").concat(n[m])}var M=this.getAdjust("dodge");if(M){var w=M.dodgeBy;w&&(d="".concat(d,"-").concat(n[w]))}return this.getAdjust("jitter")&&(d="".concat(d,"-").concat(t.x,"-").concat(t.y)),d},e.prototype.getScaleFields=function(){var t=[],n=new Map,i=this,a=i.attributeOption,o=i.labelOption,s=i.tooltipOption;for(var l in a)if(a.hasOwnProperty(l)){var u=a[l];u.fields?ti(u.fields,t,n):u.values&&ti(u.values,t,n)}return o&&o.fields&&ti(o.fields,t,n),(0,f.Kn)(s)&&s.fields&&ti(s.fields,t,n),t},e.prototype.changeVisible=function(t){r.prototype.changeVisible.call(this,t);for(var n=this.elements,i=0,a=n.length;i<a;i++){var o=n[i];o.changeVisible(t)}t?(this.container&&this.container.show(),this.labelsContainer&&this.labelsContainer.show()):(this.container&&this.container.hide(),this.labelsContainer&&this.labelsContainer.hide())},e.prototype.getFields=function(){var t=new Map,n=[];return Object.values(this.attributeOption).forEach(function(i){var a=(i==null?void 0:i.fields)||[];a.forEach(function(o){t.has(o)||n.push(o),t.set(o,!0)})},[]),n},e.prototype.getGroupFields=function(){for(var t=[],n=new Map,i=0,a=jt.length;i<a;i++){var o=jt[i],s=this.attributeOption[o];s&&s.fields&&ti(s.fields,t,n)}return t},e.prototype.getXYFields=function(){var t=(0,p.CR)(this.attributeOption.position.fields,2),n=t[0],i=t[1];return[n,i]},e.prototype.getXField=function(){return(0,f.U2)(this.getXYFields(),[0])},e.prototype.getYField=function(){return(0,f.U2)(this.getXYFields(),[1])},e.prototype.getShapes=function(){return this.elements.map(function(t){return t.shape})},e.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var t=this.container.getGroupBase();this.offscreenGroup=new t({})}return this.offscreenGroup},e.prototype.sort=function(t){if(!this.hasSorted)for(var n=this.getXScale(),i=n.field,a=0;a<t.length;a++){var o=t[a];o.sort(function(s,l){return n.translate(s[ee][i])-n.translate(l[ee][i])})}this.hasSorted=!0},e.prototype.adjustScale=function(){var t=this.getYScale();t&&this.getAdjust("stack")&&this.updateStackRange(t,this.beforeMappingData)},e.prototype.getShapeFactory=function(){var t=this.shapeType;if(!!Dv(t))return this.shapeFactory||(this.shapeFactory=(0,f.d9)(Dv(t))),this.shapeFactory.coordinate=this.coordinate,this.shapeFactory.theme=this.theme.geometries[t]||{},this.shapeFactory},e.prototype.createShapePointsCfg=function(t){var n=this.getXScale(),i=this.getYScale(),a=this.normalizeValues(t[n.field],n),o;return i?o=this.normalizeValues(t[i.field],i):o=t.y?t.y:.1,{x:a,y:o,y0:i?i.scale(this.getYMinValue()):void 0}},e.prototype.createElement=function(t,n,i){i===void 0&&(i=!1);var a=this.container,o=this.getDrawCfg(t),s=this.getShapeFactory(),l=new Iv({shapeFactory:s,container:a,offscreenGroup:this.getOffscreenGroup(),elementIndex:n});return l.animate=this.animateOption,l.geometry=this,l.draw(o,i),l},e.prototype.getDrawCfg=function(t){var n=t[ee],i={mappingData:t,data:n,x:t.x,y:t.y,color:t.color,size:t.size,isInCircle:this.coordinate.isPolar,customInfo:this.customOption},a=t.shape;!a&&this.getShapeFactory()&&(a=this.getShapeFactory().defaultShapeType),i.shape=a;var o=this.theme.geometries[this.shapeType];i.defaultStyle=(0,f.U2)(o,[a,"default"],{}).style,!i.defaultStyle&&this.getShapeFactory()&&(i.defaultStyle=this.getShapeFactory().getDefaultStyle(o));var s=this.styleOption;return s&&(i.style=this.getStyleCfg(s,n)),this.generatePoints&&(i.points=t.points,i.nextPoints=t.nextPoints),i},e.prototype.updateElements=function(t,n){var i,a,o,s,l,u;n===void 0&&(n=!1);for(var c=new Map,h=[],v=new Map,d=0,g=0;g<t.length;g++)for(var y=t[g],x=0;x<y.length;x++){var m=y[x],M=this.getElementId(m),w=c.has(M)?"".concat(M,"-").concat(g,"-").concat(x):M;h.push(w),c.set(w,m),v.set(w,d),d++}this.elements=new Array(d);var S=kv(this.lastElementsMap,h),b=S.added,k=S.updated,H=S.removed;try{for(var at=(0,p.XA)(b),At=at.next();!At.done;At=at.next()){var M=At.value,m=c.get(M),g=v.get(M),gt=this.createElement(m,g,n);this.elements[g]=gt,this.elementsMap[M]=gt,gt.shape&&gt.shape.set("zIndex",this.zIndexReversed?this.elements.length-g:g)}}catch(ie){i={error:ie}}finally{try{At&&!At.done&&(a=at.return)&&a.call(at)}finally{if(i)throw i.error}}try{for(var Nt=(0,p.XA)(k),te=Nt.next();!te.done;te=Nt.next()){var M=te.value,gt=this.lastElementsMap[M],m=c.get(M),ce=this.getDrawCfg(m),Me=gt.getModel(),g=v.get(M);(this.isCoordinateChanged||Ov(ce,Me))&&(gt.animate=this.animateOption,gt.update(ce)),this.elements[g]=gt,this.elementsMap[M]=gt,gt.shape&&gt.shape.set("zIndex",this.zIndexReversed?this.elements.length-g:g)}}catch(ie){o={error:ie}}finally{try{te&&!te.done&&(s=Nt.return)&&s.call(Nt)}finally{if(o)throw o.error}}this.container&&this.container.sort();try{for(var be=(0,p.XA)(H),Gt=be.next();!Gt.done;Gt=be.next()){var M=Gt.value,gt=this.lastElementsMap[M];gt.animate=this.animateOption,gt.destroy()}}catch(ie){l={error:ie}}finally{try{Gt&&!Gt.done&&(u=be.return)&&u.call(be)}finally{if(l)throw l.error}}},e.prototype.getLabelType=function(){var t=this,n=t.labelOption,i=t.coordinate,a=t.type,o=i.type,s=i.isTransposed,l=(0,f.U2)(n,["cfg","type"]);return l||(o==="polar"?l=s?"pie":"polar":o==="theta"?l="pie":a==="interval"||a==="polygon"?l="interval":l="base"),l},e.prototype.getYMinValue=function(){var t=this.getYScale(),n=t.min,i=t.max,a;return n>=0?a=n:i<=0?a=i:a=0,a},e.prototype.createAttrOption=function(t,n,i){if((0,f.UM)(n)||(0,f.Kn)(n))(0,f.Kn)(n)&&(0,f.Xy)(Object.keys(n),["values"])?(0,f.t8)(this.attributeOption,t,{fields:n.values}):(0,f.t8)(this.attributeOption,t,n);else{var a={};(0,f.hj)(n)?a.values=[n]:a.fields=no(n),i&&((0,f.mf)(i)?a.callback=i:a.values=i),(0,f.t8)(this.attributeOption,t,a)}},e.prototype.initAttributes=function(){var t=this,n=this,i=n.attributes,a=n.attributeOption,o=n.theme,s=n.shapeType;this.groupScales=[];var l={},u=function(v){if(a.hasOwnProperty(v)){var d=a[v];if(!d)return{value:void 0};var g=(0,p.pi)({},d),y=g.callback,x=g.values,m=g.fields,M=m===void 0?[]:m,w=M.map(function(b){var k=t.scales[b];if(!l[b]&&jt.includes(v)){var H=Fh(k,(0,f.U2)(t.scaleDefs,b),v,t.type);H==="cat"&&(t.groupScales.push(k),l[b]=!0)}return k});g.scales=w,v!=="position"&&w.length===1&&w[0].type==="identity"?g.values=w[0].values:!y&&!x&&(v==="size"?g.values=o.sizes:v==="shape"?g.values=o.shapes[s]||[]:v==="color"&&(w.length?g.values=w[0].values.length<=10?o.colors10:o.colors20:g.values=o.colors10));var S=Vf(v);i[v]=new S(g)}};for(var c in a){var h=u(c);if(typeof h=="object")return h.value}},e.prototype.processData=function(t){var n,i;this.hasSorted=!1;for(var a=this.getAttribute("position").scales,o=a.filter(function(H){return H.isCategory}),s=this.groupData(t),l=[],u=0,c=s.length;u<c;u++){for(var h=s[u],v=[],d=0,g=h.length;d<g;d++){var y=h[d],x={};for(var m in y)x[m]=y[m];x[ee]=y;try{for(var M=(n=void 0,(0,p.XA)(o)),w=M.next();!w.done;w=M.next()){var S=w.value,b=S.field;x[b]=S.translate(x[b])}}catch(H){n={error:H}}finally{try{w&&!w.done&&(i=M.return)&&i.call(M)}finally{if(n)throw n.error}}v.push(x)}l.push(v)}var k=this.adjustData(l);return this.beforeMappingData=k,k},e.prototype.adjustData=function(t){var n=this.adjustOption,i=this,a=i.intervalPadding,o=i.dodgePadding,s=i.theme,l=this.maxColumnWidth||s.maxColumnWidth,u=this.minColumnWidth||s.minColumnWidth,c=this.columnWidthRatio||s.columnWidthRatio,h=t;if(n){var v=this.getXScale(),d=this.getYScale(),g=v.field,y=d?d.field:null,x=$a(this.coordinate),m=v.values.length,M=this.getAttribute("size"),w=void 0;M&&(w=M.values[0]);for(var S=0,b=n.length;S<b;S++){var k=n[S],H=(0,p.pi)({xField:g,yField:y,intervalPadding:a,dodgePadding:o,xDimensionLength:x,groupNum:m,defaultSize:w,maxColumnWidth:l,minColumnWidth:u,columnWidthRatio:c},k),at=k.type;if(at==="dodge"){var At=[];if(v.isCategory||v.type==="identity")At.push("x");else if(!d)At.push("y");else throw new Error("dodge is not support linear attribute, please use category attribute!");H.adjustNames=At,H.dodgeRatio=c}else if(at==="stack"){var gt=this.coordinate;if(!d){H.height=gt.getHeight();var Nt=this.getDefaultValue("size")||3;H.size=Nt}!gt.isTransposed&&(0,f.UM)(H.reverseOrder)&&(H.reverseOrder=!0)}var te=Tt(at);H.dimValuesMap={},v&&v.values&&(H.dimValuesMap[v.field]=v.values.map(function(Me){return v.translate(Me)}));var ce=new te(H);h=ce.process(h),this.adjusts[at]=ce}}return h},e.prototype.groupData=function(t){for(var n=this.getGroupScales(),i=this.scaleDefs,a={},o=[],s=0;s<n.length;s++){var l=n[s],u=l.field;o.push(u),(0,f.U2)(i,[u,"values"])&&(a[u]=i[u].values)}return Hw(t,o,a)},e.prototype.updateStackRange=function(t,n){for(var i=(0,f.xH)(n),a=t.field,o=t.min,s=t.max,l=0;l<i.length;l++){var u=i[l],c=Math.min.apply(null,u[a]),h=Math.max.apply(null,u[a]);c<o&&(o=c),h>s&&(s=h)}var v=this.scaleDefs,d={};o<t.min&&!(0,f.U2)(v,[a,"min"])&&(d.min=o),s>t.max&&!(0,f.U2)(v,[a,"max"])&&(d.max=s),t.change(d)},e.prototype.beforeMapping=function(t){var n=t;if(this.sortable&&this.sort(n),this.generatePoints)for(var i=0,a=n.length;i<a;i++){var o=n[i];this.generateShapePoints(o);var s=n[i+1];s&&(this.generateShapePoints(s),o[0].nextPoints=s[0].points)}return n},e.prototype.generateShapePoints=function(t){for(var n=this.getShapeFactory(),i=this.getAttribute("shape"),a=0;a<t.length;a++){var o=t[a],s=this.createShapePointsCfg(o),l=i?this.getAttributeValues(i,o):null,u=n.getShapePoints(l,s);o.points=u}},e.prototype.normalizeValues=function(t,n){var i=[];if((0,f.kJ)(t))for(var a=0;a<t.length;a++){var o=t[a];i.push(n.scale(o))}else i=n.scale(t);return i},e.prototype.mapping=function(t){for(var n=this.attributes,i=[],a=0;a<t.length;a++){var o=t[a],s={_origin:o[ee],points:o.points,nextPoints:o.nextPoints};for(var l in n)if(n.hasOwnProperty(l)){var u=n[l],c=u.names,h=this.getAttributeValues(u,o);if(c.length>1)for(var v=0;v<h.length;v+=1){var d=h[v],g=c[v];s[g]=(0,f.kJ)(d)&&d.length===1?d[0]:d}else s[c[0]]=h.length===1?h[0]:h}this.convertPoint(s),i.push(s)}return i},e.prototype.convertPoint=function(t){var n=t.x,i=t.y,a,o,s,l=this.coordinate;if((0,f.kJ)(n)&&(0,f.kJ)(i)){a=[],o=[];for(var u=0,c=0,h=n.length,v=i.length;u<h&&c<v;u+=1,c+=1)s=l.convert({x:n[u],y:i[c]}),a.push(s.x),o.push(s.y)}else if((0,f.kJ)(i)){o=[];for(var d=0;d<i.length;d++){var g=i[d];s=l.convert({x:n,y:g}),a&&a!==s.x?((0,f.kJ)(a)||(a=[a]),a.push(s.x)):a=s.x,o.push(s.y)}}else if((0,f.kJ)(n)){a=[];for(var d=0;d<n.length;d++){var y=n[d];s=l.convert({x:y,y:i}),o&&o!==s.y?((0,f.kJ)(o)||(o=[o]),o.push(s.y)):o=s.y,a.push(s.x)}}else{var x=l.convert({x:n,y:i});a=x.x,o=x.y}t.x=a,t.y=o},e.prototype.getStyleCfg=function(t,n){var i=t.fields,a=i===void 0?[]:i,o=t.callback,s=t.cfg;if(s)return s;var l=a.map(function(u){return n[u]});return o.apply(void 0,(0,p.ev)([],(0,p.CR)(l),!1))},e.prototype.setCfg=function(t){var n=this,i=t.coordinate,a=t.data,o=t.theme,s=t.scaleDefs;i&&(this.coordinate=i),a&&(this.data=a),s&&(this.scaleDefs=s,this.idFields=[],(0,f.S6)(s,function(l,u){l&&l.key&&n.idFields.push(u)})),o&&(this.theme=this.userTheme?(0,f.b$)({},o,this.userTheme):o)},e.prototype.renderLabels=function(t,n){return n===void 0&&(n=!1),(0,p.mG)(this,void 0,void 0,function(){var i,a,o,s,l,u,c,h,v,d,g,y,x=this;return(0,p.Jh)(this,function(m){switch(m.label){case 0:return i=this.geometryLabel,this.emit(st.BEFORE_RENDER_LABEL),i||(a=this.getLabelType(),o=Nw(a),i=new o(this),this.geometryLabel=i),[4,i.render(t,n)];case 1:m.sent(),s=i.labelsRenderer.shapesMap,l=new Map,(0,f.S6)(s,function(M,w){for(var S=M.getChildren()||[],b=0;b<S.length;b++){var k=S[b],H=x.elementsMap[k.get("elementId")||w.split(" ")[0]];if(H){k.cfg.name=["element","label"],k.cfg.element=H;var at=l.get(H)||new Set;at.add(M),l.set(H,at)}}});try{for(u=(0,p.XA)(l.entries()),c=u.next();!c.done;c=u.next())h=(0,p.CR)(c.value,2),v=h[0],d=h[1],v.labelShape=(0,p.ev)([],(0,p.CR)(d),!1)}catch(M){g={error:M}}finally{try{c&&!c.done&&(y=u.return)&&y.call(u)}finally{if(g)throw g.error}}return this.emit(st.AFTER_RENDER_LABEL),[2]}})})},e.prototype.canDoGroupAnimation=function(t){return!t&&this.animateOption&&((0,f.U2)(this.animateOption,"appear")===void 0||(0,f.U2)(this.animateOption,"appear")&&(0,f.U2)(this.animateOption,["appear","animation"])===void 0)},e}(P),ii=Gw,Cs=nr.vs;function io(r,e,t){var n=Cs(r.getMatrix(),[["t",e,t]]);r.setMatrix(n)}function Yw(r,e){var t=r.attr(),n=t.x,i=t.y,a=Cs(r.getMatrix(),[["t",-n,-i],["r",e],["t",n,i]]);return a}function ku(r,e){var t=Yw(r,e);r.setMatrix(t)}function z6(){return[1,0,0,0,1,0,0,0,1]}function Xw(r,e){var t=r.getBBox(),n=(t.minX+t.maxX)/2,i=(t.minY+t.maxY)/2;r.applyToMatrix([n,i,1]);var a=Cs(r.getMatrix(),[["t",-n,-i],["s",e,e],["t",n,i]]);r.setMatrix(a)}function ai(r){return r.find(function(e){return e.get("type")==="text"})}function Bv(r,e,t){t===void 0&&(t=[0,0,0,0]);var n=r&&r.getChildren()[0];if(n){var i=n.clone();(e==null?void 0:e.rotate)&&ku(i,-e.rotate);var a=i.getCanvasBBox(),o=a.x,s=a.y,l=a.width,u=a.height;i.destroy();var c=t;return(0,f.UM)(c)?c=[2,2,2,2]:(0,f.hj)(c)&&(c=new Array(4).fill(c)),{x:o-c[3],y:s-c[0],width:l+c[1]+c[3],height:u+c[0]+c[2],rotation:(e==null?void 0:e.rotate)||0}}return{x:0,y:0,width:0,height:0,rotation:0}}function Ww(r,e,t){t===void 0&&(t=0);var n=Math.max(0,Math.min(r.x+r.width+t,e.x+e.width+t)-Math.max(r.x-t,e.x-t)),i=Math.max(0,Math.min(r.y+r.height+t,e.y+e.height+t)-Math.max(r.y-t,e.y-t));return n*i}function Zw(r,e){var t=r.getBBox();return(0,f.G)(e,function(n){var i=n.getBBox();return Ww(t,i,2)>0})}function Rv(r,e,t){var n=t.data,i=t.origin,a=t.animateCfg,o=t.coordinate,s=(0,f.U2)(a,"update");r.set("data",n),r.set("origin",i),r.set("animateCfg",a),r.set("coordinate",o),r.set("visible",e.get("visible")),(r.getChildren()||[]).forEach(function(l,u){var c=e.getChildByIndex(u);if(!c)r.removeChild(l),l.remove(!0);else{l.set("data",n),l.set("origin",i),l.set("animateCfg",a),l.set("coordinate",o);var h=_h(l,c);s?fa(l,s,{toAttrs:h,coordinate:o}):l.attr(h),c.isGroup()&&Rv(l,c,t)}}),(0,f.S6)(e.getChildren(),function(l,u){(0,f.kJ)(r.getChildren())&&u>=r.getCount()&&(l.destroyed||r.add(l))})}var $w=function(){function r(e){this.shapesMap={};var t=e.layout,n=e.container;this.layout=t,this.container=n}return r.prototype.render=function(e,t,n){return n===void 0&&(n=!1),(0,p.mG)(this,void 0,void 0,function(){var i,a,o,s,l,u,c,h,v=this;return(0,p.Jh)(this,function(d){switch(d.label){case 0:if(i={},a=this.createOffscreenGroup(),!e.length)return[3,2];try{for(o=(0,p.XA)(e),s=o.next();!s.done;s=o.next())l=s.value,l&&(i[l.id]=this.renderLabel(l,a))}catch(g){c={error:g}}finally{try{s&&!s.done&&(h=o.return)&&h.call(o)}finally{if(c)throw c.error}}return[4,this.doLayout(e,t,i)];case 1:d.sent(),this.renderLabelLine(e,i),this.renderLabelBackground(e,i),this.adjustLabel(e,i),d.label=2;case 2:return u=this.shapesMap,(0,f.S6)(i,function(g,y){if(g.destroyed)delete i[y];else{if(u[y]){var x=g.get("data"),m=g.get("origin"),M=g.get("coordinate"),w=g.get("animateCfg"),S=u[y];Rv(S,i[y],{data:x,origin:m,animateCfg:w,coordinate:M}),i[y]=S}else{if(v.container.destroyed)return;v.container.add(g);var b=(0,f.U2)(g.get("animateCfg"),n?"enter":"appear");b&&fa(g,b,{toAttrs:(0,p.pi)({},g.attr()),coordinate:g.get("coordinate")})}delete u[y]}}),(0,f.S6)(u,function(g){var y=(0,f.U2)(g.get("animateCfg"),"leave");y?fa(g,y,{toAttrs:null,coordinate:g.get("coordinate")}):g.remove(!0)}),this.shapesMap=i,a.destroy(),[2]}})})},r.prototype.clear=function(){this.container.clear(),this.shapesMap={}},r.prototype.destroy=function(){this.container.destroy(),this.shapesMap=null},r.prototype.renderLabel=function(e,t){var n=e.id,i=e.elementId,a=e.data,o=e.mappingData,s=e.coordinate,l=e.animate,u=e.content,c=e.capture,h={id:n,elementId:i,capture:c,data:a,origin:(0,p.pi)((0,p.pi)({},o),{data:o[ee]}),coordinate:s},v=t.addGroup((0,p.pi)({name:"label",animateCfg:this.animate===!1||l===null||l===!1?!1:(0,f.b$)({},this.animate,l)},h)),d;if(u.isGroup&&u.isGroup()||u.isShape&&u.isShape()){var g=u.getCanvasBBox(),y=g.width,x=g.height,m=(0,f.U2)(e,"textAlign","left"),M=e.x,w=e.y-x/2;m==="center"?M=M-y/2:(m==="right"||m==="end")&&(M=M-y),io(u,M,w),d=u,v.add(u)}else{var S=(0,f.U2)(e,["style","fill"]);d=v.addShape("text",(0,p.pi)({attrs:(0,p.pi)((0,p.pi)({x:e.x,y:e.y,textAlign:e.textAlign,textBaseline:(0,f.U2)(e,"textBaseline","middle"),text:e.content},e.style),{fill:(0,f.Ft)(S)?e.color:S})},h))}return e.rotate&&ku(d,e.rotate),v},r.prototype.doLayout=function(e,t,n){return(0,p.mG)(this,void 0,void 0,function(){var i,a=this;return(0,p.Jh)(this,function(o){switch(o.label){case 0:return this.layout?(i=(0,f.kJ)(this.layout)?this.layout:[this.layout],[4,Promise.all(i.map(function(s){var l=Uw((0,f.U2)(s,"type",""));if(!!l){var u=[],c=[];return(0,f.S6)(n,function(h,v){u.push(h),c.push(t[h.get("elementId")])}),l(e,u,c,a.region,s.cfg)}}))]):[3,2];case 1:o.sent(),o.label=2;case 2:return[2]}})})},r.prototype.renderLabelLine=function(e,t){(0,f.S6)(e,function(n){var i=(0,f.U2)(n,"coordinate");if(!(!n||!i)){var a=i.getCenter(),o=i.getRadius();if(!!n.labelLine){var s=(0,f.U2)(n,"labelLine",{}),l=n.id,u=s.path;if(!u){var c=hr(a.x,a.y,o,n.angle);u=[["M",c.x,c.y],["L",n.x,n.y]]}var h=t[l];h.destroyed||h.addShape("path",{capture:!1,attrs:(0,p.pi)({path:u,stroke:n.color?n.color:(0,f.U2)(n,["style","fill"],"#000"),fill:null},s.style),id:l,origin:n.mappingData,data:n.data,coordinate:n.coordinate})}}})},r.prototype.renderLabelBackground=function(e,t){(0,f.S6)(e,function(n){var i=(0,f.U2)(n,"coordinate"),a=(0,f.U2)(n,"background");if(!(!a||!i)){var o=n.id,s=t[o];if(!s.destroyed){var l=s.getChildren()[0];if(l){var u=Bv(s,n,a.padding),c=u.rotation,h=(0,p._T)(u,["rotation"]),v=s.addShape("rect",{attrs:(0,p.pi)((0,p.pi)({},h),a.style||{}),id:o,origin:n.mappingData,data:n.data,coordinate:n.coordinate});if(v.setZIndex(-1),c){var d=l.getMatrix();v.setMatrix(d)}}}}})},r.prototype.createOffscreenGroup=function(){var e=this.container,t=e.getGroupBase(),n=new t({});return n},r.prototype.adjustLabel=function(e,t){(0,f.S6)(e,function(n){if(n){var i=n.id,a=t[i];if(!a.destroyed){var o=a.findAll(function(s){return s.get("type")!=="path"});(0,f.S6)(o,function(s){s&&(n.offsetX&&s.attr("x",s.attr("x")+n.offsetX),n.offsetY&&s.attr("y",s.attr("y")+n.offsetY))})}}})},r}(),qw=$w;function Nv(r){var e=0;return(0,f.S6)(r,function(t){e+=t}),e/r.length}var Kw=function(){function r(e){this.geometry=e}return r.prototype.getLabelItems=function(e){var t=this,n=[],i=this.getLabelCfgs(e);return(0,f.S6)(e,function(a,o){var s=i[o];if(!s||(0,f.UM)(a.x)||(0,f.UM)(a.y)){n.push(null);return}var l=(0,f.kJ)(s.content)?s.content:[s.content];s.content=l;var u=l.length;(0,f.S6)(l,function(c,h){if((0,f.UM)(c)||c===""){n.push(null);return}var v=(0,p.pi)((0,p.pi)({},s),t.getLabelPoint(s,a,h));v.textAlign||(v.textAlign=t.getLabelAlign(v,h,u)),v.offset<=0&&(v.labelLine=null),n.push(v)})}),n},r.prototype.render=function(e,t){return t===void 0&&(t=!1),(0,p.mG)(this,void 0,void 0,function(){var n,i,a;return(0,p.Jh)(this,function(o){switch(o.label){case 0:return n=this.getLabelItems(e),i=this.getLabelsRenderer(),a=this.getGeometryShapes(),[4,i.render(n,a,t)];case 1:return o.sent(),[2]}})})},r.prototype.clear=function(){var e=this.labelsRenderer;e&&e.clear()},r.prototype.destroy=function(){var e=this.labelsRenderer;e&&e.destroy(),this.labelsRenderer=null},r.prototype.getCoordinate=function(){return this.geometry.coordinate},r.prototype.getDefaultLabelCfg=function(e,t){var n=this.geometry,i=n.type,a=n.theme;return i==="polygon"||i==="interval"&&t==="middle"||e<0&&!["line","point","path"].includes(i)?(0,f.U2)(a,"innerLabels",{}):(0,f.U2)(a,"labels",{})},r.prototype.getThemedLabelCfg=function(e){var t=this.geometry,n=this.getDefaultLabelCfg(),i=t.type,a=t.theme,o;return i==="polygon"||e.offset<0&&!["line","point","path"].includes(i)?o=(0,f.b$)({},n,a.innerLabels,e):o=(0,f.b$)({},n,a.labels,e),o},r.prototype.setLabelPosition=function(e,t,n,i){},r.prototype.getLabelOffset=function(e){var t=this.getCoordinate(),n=this.getOffsetVector(e);return t.isTransposed?n[0]:n[1]},r.prototype.getLabelOffsetPoint=function(e,t,n){var i=e.offset,a=this.getCoordinate(),o=a.isTransposed,s=o?"x":"y",l=o?1:-1,u={x:0,y:0};return t>0||n===1?u[s]=i*l:u[s]=i*l*-1,u},r.prototype.getLabelPoint=function(e,t,n){var i=this.getCoordinate(),a=e.content.length;function o(x,m,M){M===void 0&&(M=!1);var w=x;return(0,f.kJ)(w)&&(e.content.length===1?M?w=Nv(w):w.length<=2?w=w[x.length-1]:w=Nv(w):w=w[m]),w}var s={content:e.content[n],x:0,y:0,start:{x:0,y:0},color:"#fff"},l=(0,f.kJ)(t.shape)?t.shape[0]:t.shape,u=l==="funnel"||l==="pyramid";if(this.geometry.type==="polygon"){var c=q1(t.x,t.y);s.x=c[0],s.y=c[1]}else this.geometry.type==="interval"&&!u?(s.x=o(t.x,n,!0),s.y=o(t.y,n)):(s.x=o(t.x,n),s.y=o(t.y,n));if(u){var h=(0,f.U2)(t,"nextPoints"),v=(0,f.U2)(t,"points");if(h){var d=i.convert(v[1]),g=i.convert(h[1]);s.x=(d.x+g.x)/2,s.y=(d.y+g.y)/2}else if(l==="pyramid"){var d=i.convert(v[1]),g=i.convert(v[2]);s.x=(d.x+g.x)/2,s.y=(d.y+g.y)/2}}e.position&&this.setLabelPosition(s,t,n,e.position);var y=this.getLabelOffsetPoint(e,n,a);return s.start={x:s.x,y:s.y},s.x+=y.x,s.y+=y.y,s.color=t.color,s},r.prototype.getLabelAlign=function(e,t,n){var i="center",a=this.getCoordinate();if(a.isTransposed){var o=e.offset;o<0?i="right":o===0?i="center":i="left",n>1&&t===0&&(i==="right"?i="left":i==="left"&&(i="right"))}return i},r.prototype.getLabelId=function(e){var t=this.geometry,n=t.type,i=t.getXScale(),a=t.getYScale(),o=e[ee],s=t.getElementId(e);return n==="line"||n==="area"?s+=" ".concat(o[i.field]):n==="path"&&(s+=" ".concat(o[i.field],"-").concat(o[a.field])),s},r.prototype.getLabelsRenderer=function(){var e=this.geometry,t=e.labelsContainer,n=e.labelOption,i=e.canvasRegion,a=e.animateOption,o=this.geometry.coordinate,s=this.labelsRenderer;return s||(s=new qw({container:t,layout:(0,f.U2)(n,["cfg","layout"],{type:this.defaultLayout})}),this.labelsRenderer=s),s.region=i,s.animate=a?Fv("label",o):!1,s},r.prototype.getLabelCfgs=function(e){var t=this,n=this.geometry,i=n.labelOption,a=n.scales,o=n.coordinate,s=i,l=s.fields,u=s.callback,c=s.cfg,h=l.map(function(d){return a[d]}),v=[];return(0,f.S6)(e,function(d,g){var y=d[ee],x=t.getLabelText(y,h),m;if(u){var M=l.map(function(H){return y[H]});if(m=u.apply(void 0,(0,p.ev)([],(0,p.CR)(M),!1)),(0,f.UM)(m)){v.push(null);return}}var w=(0,p.pi)((0,p.pi)({id:t.getLabelId(d),elementId:t.geometry.getElementId(d),data:y,mappingData:d,coordinate:o},c),m);(0,f.mf)(w.position)&&(w.position=w.position(y,d,g));var S=t.getLabelOffset(w.offset||0),b=t.getDefaultLabelCfg(S,w.position);w=(0,f.b$)({},b,w),w.offset=t.getLabelOffset(w.offset||0);var k=w.content;(0,f.mf)(k)?w.content=k(y,d,g):(0,f.o8)(k)&&(w.content=x[0]),v.push(w)}),v},r.prototype.getLabelText=function(e,t){var n=[];return(0,f.S6)(t,function(i){var a=e[i.field];(0,f.kJ)(a)?a=a.map(function(o){return i.getText(o)}):a=i.getText(a),(0,f.UM)(a)||a===""?n.push(null):n.push(a)}),n},r.prototype.getOffsetVector=function(e){e===void 0&&(e=0);var t=this.getCoordinate(),n=0;return(0,f.hj)(e)&&(n=e),t.isTransposed?t.applyMatrix(n,0):t.applyMatrix(0,n)},r.prototype.getGeometryShapes=function(){var e=this.geometry,t={};return(0,f.S6)(e.elementsMap,function(n,i){t[i]=n.shape}),(0,f.S6)(e.getOffscreenGroup().getChildren(),function(n){var i=e.getElementId(n.get("origin").mappingData);t[i]=n}),t},r}(),As=Kw;function Bu(r,e,t){if(!r)return t;var n;if(r.callback&&r.callback.length>1){var i=Array(r.callback.length-1).fill("");n=r.mapping.apply(r,(0,p.ev)([e],(0,p.CR)(i),!1)).join("")}else n=r.mapping(e).join("");return n||t}var _i={hexagon:function(r,e,t){var n=t/2*Math.sqrt(3);return[["M",r,e-t],["L",r+n,e-t/2],["L",r+n,e+t/2],["L",r,e+t],["L",r-n,e+t/2],["L",r-n,e-t/2],["Z"]]},bowtie:function(r,e,t){var n=t-1.5;return[["M",r-t,e-n],["L",r+t,e+n],["L",r+t,e-n],["L",r-t,e+n],["Z"]]},cross:function(r,e,t){return[["M",r-t,e-t],["L",r+t,e+t],["M",r+t,e-t],["L",r-t,e+t]]},tick:function(r,e,t){return[["M",r-t/2,e-t],["L",r+t/2,e-t],["M",r,e-t],["L",r,e+t],["M",r-t/2,e+t],["L",r+t/2,e+t]]},plus:function(r,e,t){return[["M",r-t,e],["L",r+t,e],["M",r,e-t],["L",r,e+t]]},hyphen:function(r,e,t){return[["M",r-t,e],["L",r+t,e]]},line:function(r,e,t){return[["M",r,e-t],["L",r,e+t]]}},jw=["line","cross","tick","plus","hyphen"];function Jw(r,e){return(0,f.mf)(e)?e(r):(0,f.b$)({},r,e)}function Qw(r,e){var t=r.symbol;if((0,f.HD)(t)&&jw.indexOf(t)!==-1){var n=(0,f.U2)(r,"style",{}),i=(0,f.U2)(n,"lineWidth",1),a=n.stroke||n.fill||e;r.style=(0,f.b$)({},r.style,{lineWidth:i,stroke:a,fill:null})}}function Uv(r){var e=r.symbol;(0,f.HD)(e)&&_i[e]&&(r.symbol=_i[e])}function Ru(r){return r.startsWith(K.LEFT)||r.startsWith(K.RIGHT)?"vertical":"horizontal"}function zv(r,e,t,n,i){var a=t.getScale(t.type);if(a.isCategory){var o=a.field,s=e.getAttribute("color"),l=e.getAttribute("shape"),u=r.getTheme().defaultColor,c=e.coordinate.isPolar;return a.getTicks().map(function(h,v){var d,g=h.text,y=h.value,x=g,m=a.invert(y),M=r.filterFieldData(o,[(d={},d[o]=m,d)]).length===0;(0,f.S6)(r.views,function(H){var at;H.filterFieldData(o,[(at={},at[o]=m,at)]).length||(M=!0)});var w=Bu(s,m,u),S=Bu(l,m,"point"),b=e.getShapeMarker(S,{color:w,isInPolar:c}),k=i;return(0,f.mf)(k)&&(k=k(x,v,(0,p.pi)({name:x,value:m},(0,f.b$)({},n,b)))),b=(0,f.b$)({},n,b,Nr((0,p.pi)({},k),["style"])),Qw(b,w),k&&k.style&&(b.style=Jw(b.style,k.style)),Uv(b),{id:m,name:x,value:m,marker:b,unchecked:M}})}return[]}function t2(r,e,t){return t.map(function(n,i){var a=e;(0,f.mf)(a)&&(a=a(n.name,i,(0,f.b$)({},r,n)));var o=(0,f.mf)(n.marker)?n.marker(n.name,i,(0,f.b$)({},r,n)):n.marker,s=(0,f.b$)({},r,a,o);return Uv(s),n.marker=s,n})}function Vv(r,e){var t=(0,f.U2)(r,["components","legend"],{});return(0,f.b$)({},(0,f.U2)(t,["common"],{}),(0,f.b$)({},(0,f.U2)(t,[e],{})))}function Nu(r){return r?!1:r==null||isNaN(r)}function Hv(r){if((0,f.kJ)(r))return Nu(r[1].y);var e=r.y;return(0,f.kJ)(e)?Nu(e[0]):Nu(e)}function bs(r,e,t){if(e===void 0&&(e=!1),t===void 0&&(t=!0),!r.length||r.length===1&&!t)return[];if(e){for(var n=[],i=0,a=r.length;i<a;i++){var o=r[i];Hv(o)||n.push(o)}return[n]}for(var s=[],l=[],i=0,a=r.length;i<a;i++){var o=r[i];Hv(o)?l.length&&(l.length===1&&!t||s.push(l),l=[]):l.push(o)}return l.length&&s.push(l),s}function Gv(r){for(var e=[],t=0;t<r.length;t++){var n=r[t];if(n){var i=t===0?"M":"L";e.push([i,n.x,n.y])}}var a=r[0];return a&&(e.push(["L",a.x,a.y]),e.push(["z"])),e}function Yv(r){for(var e=r.length/2,t=[],n=[],i=0;i<r.length;i++)i<e?t.push(r[i]):n.push(r[i]);var a=gs(t,!1),o=gs(n,!1);n.length&&a.push(["L",n[0].x,n[0].y]),o.shift();var s=a.concat(o);return t.length&&s.push(["L",t[0].x,t[0].y]),s.push(["z"]),s}function fr(r,e,t,n){n===void 0&&(n="");var i=r.style,a=i===void 0?{}:i,o=r.defaultStyle,s=r.color,l=r.size,u=(0,p.pi)((0,p.pi)({},o),a);return s&&(e&&(a.stroke||(u.stroke=s)),t&&(a.fill||(u.fill=s))),n&&(0,f.UM)(a[n])&&!(0,f.UM)(l)&&(u[n]=l),u}function Xv(r){return(0,f.b$)({},{fill:"#CCD6EC",fillOpacity:.3},(0,f.U2)(r,["background","style"]))}function Uu(r){var e=r.x,t=(0,f.kJ)(r.y)?r.y:[r.y];return t.map(function(n,i){return{x:(0,f.kJ)(e)?e[i]:e,y:n}})}var e2={line:function(r,e,t){return[["M",r-t,e],["L",r+t,e]]},dot:function(r,e,t){return[["M",r-t,e],["L",r+t,e]]},dash:function(r,e,t){return[["M",r-t,e],["L",r+t,e]]},smooth:function(r,e,t){return[["M",r-t,e],["A",t/2,t/2,0,1,1,r,e],["A",t/2,t/2,0,1,0,r+t,e]]},hv:function(r,e,t){return[["M",r-t-1,e-2.5],["L",r,e-2.5],["L",r,e+2.5],["L",r+t+1,e+2.5]]},vh:function(r,e,t){return[["M",r-t-1,e+2.5],["L",r,e+2.5],["L",r,e-2.5],["L",r+t+1,e-2.5]]},hvh:function(r,e,t){return[["M",r-(t+1),e+2.5],["L",r-t/2,e+2.5],["L",r-t/2,e-2.5],["L",r+t/2,e-2.5],["L",r+t/2,e+2.5],["L",r+t+1,e+2.5]]},vhv:function(r,e){return[["M",r-5,e+2.5],["L",r-5,e],["L",r,e],["L",r,e-3],["L",r,e+3],["L",r+6.5,e+3]]}};function Wv(r,e){var t=r.color;return{symbol:e2[e],style:{lineWidth:2,r:6,stroke:t}}}function r2(r,e,t){for(var n=r.isStack,i=r.connectNulls,a=r.isInCircle,o=r.showSinglePoint,s=fr(r,!0,!1,"lineWidth"),l=bs(r.points,i,o),u=[],c=0,h=l.length;c<h;c++){var v=l[c];u=u.concat(Zv(v,a,n,e,t,s))}return s.path=u,s}function zu(r,e,t,n,i){if(r.length===1)return[["M",r[0].x,r[0].y-i.lineWidth/2],["L",r[0].x,r[0].y],["L",r[0].x,r[0].y+i.lineWidth/2]];var a;return t?(e&&r.length&&r.push({x:r[0].x,y:r[0].y}),a=gs(r,!1,n)):(a=Ka(r,!1),e&&a.push(["Z"])),a}function n2(r,e,t,n,i,a){var o=[],s=[];(0,f.S6)(r,function(c){var h=Uu(c);o.push(h[1]),s.push(h[0])});var l=zu(o,e,n,i,a),u=zu(s,e,n,i,a);return t?l:l.concat(u)}function Zv(r,e,t,n,i,a){if(r.length){var o=r[0];return(0,f.kJ)(o.y)?n2(r,e,t,n,i,a):zu(r,e,n,i,a)}return[]}var V6=ni("line",{defaultShapeType:"line"});(0,f.S6)(["line","dot","dash","smooth"],function(r){Ke("line",r,{draw:function(e,t){var n=r==="smooth",i;if(n){var a=this.coordinate,o=a.start,s=a.end;i=[[o.x,s.y],[s.x,o.y]]}var l=r2(e,n,i),u=t.addShape({type:"path",attrs:l,name:"line",capture:!n});return u},getMarker:function(e){return Wv(e,r)}})});var H6=null,G6="4.2.11",zr={getLegendItems:zv,translate:io,rotate:ku,zoom:Xw,transform:Cs,getAngle:Za,getSectorPath:Qn,polarToCartesian:hr,getDelegationObject:Ti,getTooltipItems:Iu,getMappingValue:Bu,getPath:Zv,getPathPoints:bs},oi={100:"#000",95:"#0D0D0D",85:"#262626",65:"#595959",45:"#8C8C8C",25:"#BFBFBF",15:"#D9D9D9",6:"#F0F0F0"},rr={100:"#FFFFFF",95:"#F2F2F2",85:"#D9D9D9",65:"#A6A6A6",45:"#737373",25:"#404040",15:"#262626",6:"#0F0F0F"},vn=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#E86452","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],i2=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#E86452","#F8D0CB","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],a2=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],o2=function(r){r===void 0&&(r={});var e=r.paletteQualitative10,t=e===void 0?vn:e,n=r.paletteQualitative20,i=n===void 0?i2:n,a=r.brandColor,o=a===void 0?t[0]:a,s={backgroundColor:"#141414",brandColor:o,subColor:"rgba(255,255,255,0.05)",paletteQualitative10:t,paletteQualitative20:i,paletteSemanticRed:"#F4664A",paletteSemanticGreen:"#30BF78",paletteSemanticYellow:"#FAAD14",paletteSequence:a2,fontFamily:`"Segoe UI", Roboto, "Helvetica Neue", Arial,
  40. "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",
  41. "Noto Color Emoji"`,axisLineBorderColor:rr[25],axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:rr[65],axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisDescriptionIconFillColor:oi[85],axisTickLineBorderColor:rr[25],axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:rr[15],axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:rr[45],axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:rr[15],axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:rr[45],legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:vn[0],legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:rr[65],legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendSpacing:16,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:rr[45],legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:rr[45],legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:rr[65],legendPageNavigatorTextFontSize:12,sliderRailFillColor:rr[15],sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:rr[45],sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:oi[6],sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:oi[25],annotationArcBorderColor:rr[15],annotationArcBorder:1,annotationLineBorderColor:rr[25],annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:rr[65],annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:rr[100],annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:rr[25],tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"#1f1f1f",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 2px 4px rgba(0,0,0,.5)",tooltipContainerBorderRadius:3,tooltipTextFillColor:rr[65],tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:rr[65],labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:oi[100],innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:rr[65],overflowLabelFillColorDark:"#2c3542",overflowLabelFillColorLight:"#ffffff",overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:oi[100],overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:rr[25],cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#fff",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(255,255,255,0.65)",scrollbarThumbFillColor:"rgba(0,0,0,0.35)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.45)",pointFillColor:vn[0],pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:oi[100],pointBorderOpacity:1,pointActiveBorderColor:rr[100],pointSelectedBorder:2,pointSelectedBorderColor:rr[100],pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:vn[0],hollowPointBorderOpacity:.95,hollowPointFillColor:oi[100],hollowPointActiveBorder:1,hollowPointActiveBorderColor:rr[100],hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:rr[100],hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:vn[0],lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:vn[0],areaFillOpacity:.25,areaActiveFillColor:vn[0],areaActiveFillOpacity:.5,areaSelectedFillColor:vn[0],areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:vn[0],hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:rr[100],hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:rr[100],hollowAreaInactiveBorderOpacity:.3,intervalFillColor:vn[0],intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:rr[100],intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:rr[100],intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:vn[0],hollowIntervalBorderOpacity:1,hollowIntervalFillColor:oi[100],hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:rr[100],hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:rr[100],hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3};return(0,p.pi)((0,p.pi)({},s),r)},s2=o2();function l2(){return window?window.devicePixelRatio:1}function $v(r,e,t,n){var i=r-t,a=e-n;return Math.sqrt(i*i+a*a)}function Fi(r,e,t,n,i,a){return i>=r&&i<=r+t&&a>=e&&a<=e+n}function ao(r,e){return!(e.minX>r.maxX||e.maxX<r.minX||e.minY>r.maxY||e.maxY<r.minY)}function u2(r,e){return!r||!e?r||e:{minX:Math.min(r.minX,e.minX),minY:Math.min(r.minY,e.minY),maxX:Math.max(r.maxX,e.maxX),maxY:Math.max(r.maxY,e.maxY)}}function qv(r,e){return r[0]===e[0]&&r[1]===e[1]}var c2=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,f2=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,h2=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,Kv=/[\d.]+:(#[^\s]+|[^\)]+\))/gi;function jv(r,e){var t=r.match(Kv);(0,f.S6)(t,function(n){var i=n.split(":");e.addColorStop(i[0],i[1])})}function v2(r,e,t){var n=c2.exec(t),i=parseFloat(n[1])%360*(Math.PI/180),a=n[2],o=e.getBBox(),s,l;i>=0&&i<1/2*Math.PI?(s={x:o.minX,y:o.minY},l={x:o.maxX,y:o.maxY}):1/2*Math.PI<=i&&i<Math.PI?(s={x:o.maxX,y:o.minY},l={x:o.minX,y:o.maxY}):Math.PI<=i&&i<3/2*Math.PI?(s={x:o.maxX,y:o.maxY},l={x:o.minX,y:o.minY}):(s={x:o.minX,y:o.maxY},l={x:o.maxX,y:o.minY});var u=Math.tan(i),c=u*u,h=(l.x-s.x+u*(l.y-s.y))/(c+1)+s.x,v=u*(l.x-s.x+u*(l.y-s.y))/(c+1)+s.y,d=r.createLinearGradient(s.x,s.y,h,v);return jv(a,d),d}function d2(r,e,t){var n=f2.exec(t),i=parseFloat(n[1]),a=parseFloat(n[2]),o=parseFloat(n[3]),s=n[4];if(o===0){var l=s.match(Kv);return l[l.length-1].split(":")[1]}var u=e.getBBox(),c=u.maxX-u.minX,h=u.maxY-u.minY,v=Math.sqrt(c*c+h*h)/2,d=r.createRadialGradient(u.minX+c*i,u.minY+h*a,0,u.minX+c/2,u.minY+h/2,o*v);return jv(s,d),d}function p2(r,e,t){if(e.get("patternSource")&&e.get("patternSource")===t)return e.get("pattern");var n,i,a=h2.exec(t),o=a[1],s=a[2];function l(){n=r.createPattern(i,o),e.set("pattern",n),e.set("patternSource",t)}switch(o){case"a":o="repeat";break;case"x":o="repeat-x";break;case"y":o="repeat-y";break;case"n":o="no-repeat";break;default:o="no-repeat"}return i=new Image,s.match(/^data:/i)||(i.crossOrigin="Anonymous"),i.src=s,i.complete?l():(i.onload=l,i.src=i.src),n}function g2(r,e,t){var n=e.getBBox();if(isNaN(n.x)||isNaN(n.y)||isNaN(n.width)||isNaN(n.height))return t;if((0,f.HD)(t)){if(t[1]==="("||t[2]==="("){if(t[0]==="l")return v2(r,e,t);if(t[0]==="r")return d2(r,e,t);if(t[0]==="p")return p2(r,e,t)}return t}if(t instanceof CanvasPattern)return t}function y2(r){var e=0,t=0,n=0,i=0;return(0,f.kJ)(r)?r.length===1?e=t=n=i=r[0]:r.length===2?(e=n=r[0],t=i=r[1]):r.length===3?(e=r[0],t=i=r[1],n=r[2]):(e=r[0],t=r[1],n=r[2],i=r[3]):e=t=n=i=r,[e,t,n,i]}function Ts(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function Vu(r,e){return Ts(r)*Ts(e)?(r[0]*e[0]+r[1]*e[1])/(Ts(r)*Ts(e)):1}function Jv(r,e){return(r[0]*e[1]<r[1]*e[0]?-1:1)*Math.acos(Vu(r,e))}function Es(r,e){var t=e[1],n=e[2],i=(0,f.wQ)((0,f.c$)(e[3]),Math.PI*2),a=e[4],o=e[5],s=r[0],l=r[1],u=e[6],c=e[7],h=Math.cos(i)*(s-u)/2+Math.sin(i)*(l-c)/2,v=-1*Math.sin(i)*(s-u)/2+Math.cos(i)*(l-c)/2,d=h*h/(t*t)+v*v/(n*n);d>1&&(t*=Math.sqrt(d),n*=Math.sqrt(d));var g=t*t*(v*v)+n*n*(h*h),y=g?Math.sqrt((t*t*(n*n)-g)/g):1;a===o&&(y*=-1),isNaN(y)&&(y=0);var x=n?y*t*v/n:0,m=t?y*-n*h/t:0,M=(s+u)/2+Math.cos(i)*x-Math.sin(i)*m,w=(l+c)/2+Math.sin(i)*x+Math.cos(i)*m,S=[(h-x)/t,(v-m)/n],b=[(-1*h-x)/t,(-1*v-m)/n],k=Jv([1,0],S),H=Jv(S,b);return Vu(S,b)<=-1&&(H=Math.PI),Vu(S,b)>=1&&(H=0),o===0&&H>0&&(H=H-2*Math.PI),o===1&&H<0&&(H=H+2*Math.PI),{cx:M,cy:w,rx:qv(r,[u,c])?0:t,ry:qv(r,[u,c])?0:n,startAngle:k,endAngle:k+H,xRotation:i,arcFlag:a,sweepFlag:o}}var _s=Math.sin,Fs=Math.cos,Hu=Math.atan2,Is=Math.PI;function Qv(r,e,t,n,i,a,o){var s=e.stroke,l=e.lineWidth,u=t-i,c=n-a,h=Hu(c,u),v=new tc({type:"path",canvas:r.get("canvas"),isArrowShape:!0,attrs:{path:"M"+10*Fs(Is/6)+","+10*_s(Is/6)+" L0,0 L"+10*Fs(Is/6)+",-"+10*_s(Is/6),stroke:s,lineWidth:l}});v.translate(i,a),v.rotateAtPoint(i,a,h),r.set(o?"startArrowShape":"endArrowShape",v)}function td(r,e,t,n,i,a,o){var s=e.startArrow,l=e.endArrow,u=e.stroke,c=e.lineWidth,h=o?s:l,v=h.d,d=h.fill,g=h.stroke,y=h.lineWidth,x=(0,p._T)(h,["d","fill","stroke","lineWidth"]),m=t-i,M=n-a,w=Hu(M,m);v&&(i=i-Fs(w)*v,a=a-_s(w)*v);var S=new tc({type:"path",canvas:r.get("canvas"),isArrowShape:!0,attrs:(0,p.pi)((0,p.pi)({},x),{stroke:g||u,lineWidth:y||c,fill:d})});S.translate(i,a),S.rotateAtPoint(i,a,w),r.set(o?"startArrowShape":"endArrowShape",S)}function Ii(r,e,t,n,i){var a=Hu(n-e,t-r);return{dx:Fs(a)*i,dy:_s(a)*i}}function Gu(r,e,t,n,i,a){typeof e.startArrow=="object"?td(r,e,t,n,i,a,!0):e.startArrow?Qv(r,e,t,n,i,a,!0):r.set("startArrowShape",null)}function Yu(r,e,t,n,i,a){typeof e.endArrow=="object"?td(r,e,t,n,i,a,!1):e.endArrow?Qv(r,e,t,n,i,a,!1):r.set("startArrowShape",null)}var ed={fill:"fillStyle",stroke:"strokeStyle",opacity:"globalAlpha"};function ha(r,e){var t=e.attr();for(var n in t){var i=t[n],a=ed[n]?ed[n]:n;a==="matrix"&&i?r.transform(i[0],i[1],i[3],i[4],i[6],i[7]):a==="lineDash"&&r.setLineDash?(0,f.kJ)(i)&&r.setLineDash(i):(a==="strokeStyle"||a==="fillStyle"?i=g2(r,e,i):a==="globalAlpha"&&(i=i*r.globalAlpha),r[a]=i)}}function Xu(r,e,t){for(var n=0;n<e.length;n++){var i=e[n];i.cfg.visible?i.draw(r,t):i.skipDraw()}}function m2(r,e,t){var n=r.get("refreshElements");(0,f.S6)(n,function(i){if(i!==r)for(var a=i.cfg.parent;a&&a!==r&&!a.cfg.refresh;)a.cfg.refresh=!0,a=a.cfg.parent}),n[0]===r?Zu(e,t):Wu(e,t)}function Wu(r,e){for(var t=0;t<r.length;t++){var n=r[t];if(n.cfg.visible)if(n.cfg.hasChanged)n.cfg.refresh=!0,n.isGroup()&&Zu(n.cfg.children,e);else if(n.cfg.refresh)n.isGroup()&&Wu(n.cfg.children,e);else{var i=x2(n,e);n.cfg.refresh=i,i&&n.isGroup()&&Wu(n.cfg.children,e)}}}function rd(r){for(var e=0;e<r.length;e++){var t=r[e];t.cfg.hasChanged=!1,t.isGroup()&&!t.destroyed&&rd(t.cfg.children)}}function Zu(r,e){for(var t=0;t<r.length;t++){var n=r[t];!n.cfg.visible||(n.cfg.refresh=!0,n.isGroup()&&Zu(n.get("children"),e))}}function x2(r,e){var t=r.cfg.cacheCanvasBBox,n=r.cfg.isInView&&t&&ao(t,e);return n}function nd(r,e,t,n){var i=t.path,a=t.startArrow,o=t.endArrow;if(!!i){var s=[0,0],l=[0,0],u={dx:0,dy:0};e.beginPath();for(var c=0;c<i.length;c++){var h=i[c],v=h[0];if(c===0&&a&&a.d){var d=r.getStartTangent();u=Ii(d[0][0],d[0][1],d[1][0],d[1][1],a.d)}else if(c===i.length-2&&i[c+1][0]==="Z"&&o&&o.d){var g=i[c+1];if(g[0]==="Z"){var d=r.getEndTangent();u=Ii(d[0][0],d[0][1],d[1][0],d[1][1],o.d)}}else if(c===i.length-1&&o&&o.d&&i[0]!=="Z"){var d=r.getEndTangent();u=Ii(d[0][0],d[0][1],d[1][0],d[1][1],o.d)}var y=u.dx,x=u.dy;switch(v){case"M":e.moveTo(h[1]-y,h[2]-x),l=[h[1],h[2]];break;case"L":e.lineTo(h[1]-y,h[2]-x);break;case"Q":e.quadraticCurveTo(h[1],h[2],h[3]-y,h[4]-x);break;case"C":e.bezierCurveTo(h[1],h[2],h[3],h[4],h[5]-y,h[6]-x);break;case"A":{var m=void 0;n?(m=n[c],m||(m=Es(s,h),n[c]=m)):m=Es(s,h);var M=m.cx,w=m.cy,S=m.rx,b=m.ry,k=m.startAngle,H=m.endAngle,at=m.xRotation,At=m.sweepFlag;if(e.ellipse)e.ellipse(M,w,S,b,at,k,H,1-At);else{var gt=S>b?S:b,Nt=S>b?1:S/b,te=S>b?b/S:1;e.translate(M,w),e.rotate(at),e.scale(Nt,te),e.arc(0,0,gt,k,H,1-At),e.scale(1/Nt,1/te),e.rotate(-at),e.translate(-M,-w)}break}case"Z":e.closePath();break;default:break}if(v==="Z")s=l;else{var ce=h.length;s=[h[ce-2],h[ce-1]]}}}}function id(r,e){var t=r.get("canvas");t&&(e==="remove"&&(r._cacheCanvasBBox=r.get("cacheCanvasBBox")),r.get("hasChanged")||(r.set("hasChanged",!0),r.cfg.parent&&r.cfg.parent.get("hasChanged")||(t.refreshElement(r,e,t),t.get("autoDraw")&&t.draw())))}function M2(r){var e;if(r.destroyed)e=r._cacheCanvasBBox;else{var t=r.get("cacheCanvasBBox"),n=t&&!!(t.width&&t.height),i=r.getCanvasBBox(),a=i&&!!(i.width&&i.height);n&&a?e=u2(t,i):n?e=t:a&&(e=i)}return e}function w2(r){if(!r.length)return null;var e=[],t=[],n=[],i=[];return(0,f.S6)(r,function(a){var o=M2(a);o&&(e.push(o.minX),t.push(o.minY),n.push(o.maxX),i.push(o.maxY))}),{minX:(0,f.VV)(e),minY:(0,f.VV)(t),maxX:(0,f.Fp)(n),maxY:(0,f.Fp)(i)}}function S2(r,e){return!r||!e||!ao(r,e)?null:{minX:Math.max(r.minX,e.minX),minY:Math.max(r.minY,e.minY),maxX:Math.min(r.maxX,e.maxX),maxY:Math.min(r.maxY,e.maxY)}}var C2=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onCanvasChange=function(t){id(this,t)},e.prototype.getShapeBase=function(){return it},e.prototype.getGroupBase=function(){return e},e.prototype._applyClip=function(t,n){n&&(t.save(),ha(t,n),n.createPath(t),t.restore(),t.clip(),n._afterDraw())},e.prototype.cacheCanvasBBox=function(){var t=this.cfg.children,n=[],i=[];(0,f.S6)(t,function(v){var d=v.cfg.cacheCanvasBBox;d&&v.cfg.isInView&&(n.push(d.minX,d.maxX),i.push(d.minY,d.maxY))});var a=null;if(n.length){var o=(0,f.VV)(n),s=(0,f.Fp)(n),l=(0,f.VV)(i),u=(0,f.Fp)(i);a={minX:o,minY:l,x:o,y:l,maxX:s,maxY:u,width:s-o,height:u-l};var c=this.cfg.canvas;if(c){var h=c.getViewRange();this.set("isInView",ao(a,h))}}else this.set("isInView",!1);this.set("cacheCanvasBBox",a)},e.prototype.draw=function(t,n){var i=this.cfg.children,a=n?this.cfg.refresh:!0;i.length&&a&&(t.save(),ha(t,this),this._applyClip(t,this.getClip()),Xu(t,i,n),t.restore(),this.cacheCanvasBBox()),this.cfg.refresh=null,this.set("hasChanged",!1)},e.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("hasChanged",!1)},e}(F.AbstractGroup),$u=C2,A2=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},e.prototype.getShapeBase=function(){return it},e.prototype.getGroupBase=function(){return $u},e.prototype.onCanvasChange=function(t){id(this,t)},e.prototype.calculateBBox=function(){var t=this.get("type"),n=this.getHitLineWidth(),i=(0,F.getBBoxMethod)(t),a=i(this),o=n/2,s=a.x-o,l=a.y-o,u=a.x+a.width+o,c=a.y+a.height+o;return{x:s,minX:s,y:l,minY:l,width:a.width+n,height:a.height+n,maxX:u,maxY:c}},e.prototype.isFill=function(){return!!this.attrs.fill||this.isClipShape()},e.prototype.isStroke=function(){return!!this.attrs.stroke},e.prototype._applyClip=function(t,n){n&&(t.save(),ha(t,n),n.createPath(t),t.restore(),t.clip(),n._afterDraw())},e.prototype.draw=function(t,n){var i=this.cfg.clipShape;if(n){if(this.cfg.refresh===!1){this.set("hasChanged",!1);return}var a=this.getCanvasBBox();if(!ao(n,a)){this.set("hasChanged",!1),this.cfg.isInView&&this._afterDraw();return}}t.save(),ha(t,this),this._applyClip(t,i),this.drawPath(t),t.restore(),this._afterDraw()},e.prototype.getCanvasViewBox=function(){var t=this.cfg.canvas;return t?t.getViewRange():null},e.prototype.cacheCanvasBBox=function(){var t=this.getCanvasViewBox();if(t){var n=this.getCanvasBBox(),i=ao(n,t);this.set("isInView",i),i?this.set("cacheCanvasBBox",n):this.set("cacheCanvasBBox",null)}},e.prototype._afterDraw=function(){this.cacheCanvasBBox(),this.set("hasChanged",!1),this.set("refresh",null)},e.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("isInView",null),this.set("hasChanged",!1)},e.prototype.drawPath=function(t){this.createPath(t),this.strokeAndFill(t),this.afterDrawPath(t)},e.prototype.fill=function(t){t.fill()},e.prototype.stroke=function(t){t.stroke()},e.prototype.strokeAndFill=function(t){var n=this.attrs,i=n.lineWidth,a=n.opacity,o=n.strokeOpacity,s=n.fillOpacity;this.isFill()&&(!(0,f.UM)(s)&&s!==1?(t.globalAlpha=s,this.fill(t),t.globalAlpha=a):this.fill(t)),this.isStroke()&&i>0&&(!(0,f.UM)(o)&&o!==1&&(t.globalAlpha=o),this.stroke(t)),this.afterDrawPath(t)},e.prototype.createPath=function(t){},e.prototype.afterDrawPath=function(t){},e.prototype.isInShape=function(t,n){var i=this.isStroke(),a=this.isFill(),o=this.getHitLineWidth();return this.isInStrokeOrPath(t,n,i,a,o)},e.prototype.isInStrokeOrPath=function(t,n,i,a,o){return!1},e.prototype.getHitLineWidth=function(){if(!this.isStroke())return 0;var t=this.attrs;return t.lineWidth+t.lineAppendWidth},e}(F.AbstractShape),dn=A2,b2=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,r:0})},e.prototype.isInStrokeOrPath=function(t,n,i,a,o){var s=this.attr(),l=s.x,u=s.y,c=s.r,h=o/2,v=$v(l,u,t,n);return a&&i?v<=c+h:a?v<=c:i?v>=c-h&&v<=c+h:!1},e.prototype.createPath=function(t){var n=this.attr(),i=n.x,a=n.y,o=n.r;t.beginPath(),t.arc(i,a,o,0,Math.PI*2,!1),t.closePath()},e}(dn),T2=b2;function Ps(r,e,t,n){return r/(t*t)+e/(n*n)}var E2=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,rx:0,ry:0})},e.prototype.isInStrokeOrPath=function(t,n,i,a,o){var s=this.attr(),l=o/2,u=s.x,c=s.y,h=s.rx,v=s.ry,d=(t-u)*(t-u),g=(n-c)*(n-c);return a&&i?Ps(d,g,h+l,v+l)<=1:a?Ps(d,g,h,v)<=1:i?Ps(d,g,h-l,v-l)>=1&&Ps(d,g,h+l,v+l)<=1:!1},e.prototype.createPath=function(t){var n=this.attr(),i=n.x,a=n.y,o=n.rx,s=n.ry;if(t.beginPath(),t.ellipse)t.ellipse(i,a,o,s,0,0,Math.PI*2,!1);else{var l=o>s?o:s,u=o>s?1:o/s,c=o>s?s/o:1;t.save(),t.translate(i,a),t.scale(u,c),t.arc(0,0,l,0,Math.PI*2),t.restore(),t.closePath()}},e}(dn),_2=E2;function ad(r){return r instanceof HTMLElement&&(0,f.HD)(r.nodeName)&&r.nodeName.toUpperCase()==="CANVAS"}var F2=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,width:0,height:0})},e.prototype.initAttrs=function(t){this._setImage(t.img)},e.prototype.isStroke=function(){return!1},e.prototype.isOnlyHitBox=function(){return!0},e.prototype._afterLoading=function(){if(this.get("toDraw")===!0){var t=this.get("canvas");t?t.draw():this.createPath(this.get("context"))}},e.prototype._setImage=function(t){var n=this,i=this.attrs;if((0,f.HD)(t)){var a=new Image;a.onload=function(){if(n.destroyed)return!1;n.attr("img",a),n.set("loading",!1),n._afterLoading();var o=n.get("callback");o&&o.call(n)},a.crossOrigin="Anonymous",a.src=t,this.set("loading",!0)}else t instanceof Image?(i.width||(i.width=t.width),i.height||(i.height=t.height)):ad(t)&&(i.width||(i.width=Number(t.getAttribute("width"))),i.height||(i.height,Number(t.getAttribute("height"))))},e.prototype.onAttrChange=function(t,n,i){r.prototype.onAttrChange.call(this,t,n,i),t==="img"&&this._setImage(n)},e.prototype.createPath=function(t){if(this.get("loading")){this.set("toDraw",!0),this.set("context",t);return}var n=this.attr(),i=n.x,a=n.y,o=n.width,s=n.height,l=n.sx,u=n.sy,c=n.swidth,h=n.sheight,v=n.img;(v instanceof Image||ad(v))&&(!(0,f.UM)(l)&&!(0,f.UM)(u)&&!(0,f.UM)(c)&&!(0,f.UM)(h)?t.drawImage(v,l,u,c,h,i,a,o,s):t.drawImage(v,i,a,o,s))},e}(dn),I2=F2,Pr=N(89838);function si(r,e,t,n,i,a,o){var s=Math.min(r,t),l=Math.max(r,t),u=Math.min(e,n),c=Math.max(e,n),h=i/2;return a>=s-h&&a<=l+h&&o>=u-h&&o<=c+h?Pr.x1.pointToLine(r,e,t,n,a,o)<=i/2:!1}var P2=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},e.prototype.initAttrs=function(t){this.setArrow()},e.prototype.onAttrChange=function(t,n,i){r.prototype.onAttrChange.call(this,t,n,i),this.setArrow()},e.prototype.setArrow=function(){var t=this.attr(),n=t.x1,i=t.y1,a=t.x2,o=t.y2,s=t.startArrow,l=t.endArrow;s&&Gu(this,t,a,o,n,i),l&&Yu(this,t,n,i,a,o)},e.prototype.isInStrokeOrPath=function(t,n,i,a,o){if(!i||!o)return!1;var s=this.attr(),l=s.x1,u=s.y1,c=s.x2,h=s.y2;return si(l,u,c,h,o,t,n)},e.prototype.createPath=function(t){var n=this.attr(),i=n.x1,a=n.y1,o=n.x2,s=n.y2,l=n.startArrow,u=n.endArrow,c={dx:0,dy:0},h={dx:0,dy:0};l&&l.d&&(c=Ii(i,a,o,s,n.startArrow.d)),u&&u.d&&(h=Ii(i,a,o,s,n.endArrow.d)),t.beginPath(),t.moveTo(i+c.dx,a+c.dy),t.lineTo(o-h.dx,s-h.dy)},e.prototype.afterDrawPath=function(t){var n=this.get("startArrowShape"),i=this.get("endArrowShape");n&&n.draw(t),i&&i.draw(t)},e.prototype.getTotalLength=function(){var t=this.attr(),n=t.x1,i=t.y1,a=t.x2,o=t.y2;return Pr.x1.length(n,i,a,o)},e.prototype.getPoint=function(t){var n=this.attr(),i=n.x1,a=n.y1,o=n.x2,s=n.y2;return Pr.x1.pointAt(i,a,o,s,t)},e}(dn),L2=P2,D2=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/ig,O2=/[^\s\,]+/ig;function k2(r){var e=r||[];if((0,f.kJ)(e))return e;if((0,f.HD)(e))return e=e.match(D2),(0,f.S6)(e,function(t,n){if(t=t.match(O2),t[0].length>1){var i=t[0].charAt(0);t.splice(1,0,t[0].substr(1)),t[0]=i}(0,f.S6)(t,function(a,o){isNaN(a)||(t[o]=+a)}),e[n]=t}),e}var B2=k2;function R2(r,e,t){var n=null,i=t;return e<i&&(i=e,n="add"),r<i&&(i=r,n="del"),{type:n,min:i}}var N2=function(r,e){var t=r.length,n=e.length,i,a,o=0;if(t===0||n===0)return null;for(var s=[],l=0;l<=t;l++)s[l]=[],s[l][0]={min:l};for(var u=0;u<=n;u++)s[0][u]={min:u};for(var l=1;l<=t;l++){i=r[l-1];for(var u=1;u<=n;u++){a=e[u-1],isEqual(i,a)?o=0:o=1;var c=s[l-1][u].min+1,h=s[l][u-1].min+1,v=s[l-1][u-1].min+o;s[l][u]=R2(c,h,v)}}return s};function Y6(r,e){var t=N2(r,e),n=r.length,i=e.length,a=[],o=1,s=1;if(t[n][i]!==n){for(var l=1;l<=n;l++){var u=t[l][l].min;s=l;for(var c=o;c<=i;c++)t[l][c].min<u&&(u=t[l][c].min,s=c);o=s,t[l][o].type&&a.push({index:l-1,type:t[l][o].type})}for(var l=a.length-1;l>=0;l--)o=a[l].index,a[l].type==="add"?r.splice(o,0,[].concat(r[o])):r.splice(o,1)}if(n=r.length,n<i)for(var l=0;l<i-n;l++)r[n-1][0]==="z"||r[n-1][0]==="Z"?r.splice(n-2,0,r[n-2]):r.push(r[n-1]);return r}var oo=`
  42. \v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,U2=new RegExp("([a-z])["+oo+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+oo+"]*,?["+oo+"]*)+)","ig"),z2=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+oo+"]*,?["+oo+"]*","ig");function V2(r){if(!r)return null;if((0,f.kJ)(r))return r;var e={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},t=[];return String(r).replace(U2,function(n,i,a){var o=[],s=i.toLowerCase();if(a.replace(z2,function(l,u){u&&o.push(+u)}),s==="m"&&o.length>2&&(t.push([i].concat(o.splice(0,2))),s="l",i=i==="m"?"l":"L"),s==="o"&&o.length===1&&t.push([i,o[0]]),s==="r")t.push([i].concat(o));else for(;o.length>=e[s]&&(t.push([i].concat(o.splice(0,e[s]))),!!e[s]););return""}),t}var H2=/[a-z]/;function od(r,e){return[e[0]+(e[0]-r[0]),e[1]+(e[1]-r[1])]}function sd(r){var e=V2(r);if(!e||!e.length)return[["M",0,0]];for(var t=!1,n=0;n<e.length;n++){var i=e[n][0];if(H2.test(i)||["V","H","T","S"].indexOf(i)>=0){t=!0;break}}if(!t)return e;var a=[],o=0,s=0,l=0,u=0,c=0,h,v,d=e[0];(d[0]==="M"||d[0]==="m")&&(o=+d[1],s=+d[2],l=o,u=s,c++,a[0]=["M",o,s]);for(var n=c,g=e.length;n<g;n++){var y=e[n],x=a[n-1],m=[],i=y[0],M=i.toUpperCase();if(i!==M)switch(m[0]=M,M){case"A":m[1]=y[1],m[2]=y[2],m[3]=y[3],m[4]=y[4],m[5]=y[5],m[6]=+y[6]+o,m[7]=+y[7]+s;break;case"V":m[1]=+y[1]+s;break;case"H":m[1]=+y[1]+o;break;case"M":l=+y[1]+o,u=+y[2]+s,m[1]=l,m[2]=u;break;default:for(var w=1,S=y.length;w<S;w++)m[w]=+y[w]+(w%2?o:s)}else m=e[n];switch(M){case"Z":o=+l,s=+u;break;case"H":o=m[1],m=["L",o,s];break;case"V":s=m[1],m=["L",o,s];break;case"T":o=m[1],s=m[2];var b=od([x[1],x[2]],[x[3],x[4]]);m=["Q",b[0],b[1],o,s];break;case"S":o=m[m.length-2],s=m[m.length-1];var k=x.length,H=od([x[k-4],x[k-3]],[x[k-2],x[k-1]]);m=["C",H[0],H[1],m[1],m[2],o,s];break;case"M":l=m[m.length-2],u=m[m.length-1];break;default:o=m[m.length-2],s=m[m.length-1]}a.push(m)}return a}var so=Math.PI*2,qu=function(r,e,t,n,i,a,o){var s=r.x,l=r.y;s*=e,l*=t;var u=n*s-i*l,c=i*s+n*l;return{x:u+a,y:c+o}},G2=function(r,e){var t=e===1.5707963267948966?.551915024494:e===-1.5707963267948966?-.551915024494:4/3*Math.tan(e/4),n=Math.cos(r),i=Math.sin(r),a=Math.cos(r+e),o=Math.sin(r+e);return[{x:n-i*t,y:i+n*t},{x:a+o*t,y:o-a*t},{x:a,y:o}]},ld=function(r,e,t,n){var i=r*n-e*t<0?-1:1,a=r*t+e*n;return a>1&&(a=1),a<-1&&(a=-1),i*Math.acos(a)},Y2=function(r,e,t,n,i,a,o,s,l,u,c,h){var v=Math.pow(i,2),d=Math.pow(a,2),g=Math.pow(c,2),y=Math.pow(h,2),x=v*d-v*y-d*g;x<0&&(x=0),x/=v*y+d*g,x=Math.sqrt(x)*(o===s?-1:1);var m=x*i/a*h,M=x*-a/i*c,w=u*m-l*M+(r+t)/2,S=l*m+u*M+(e+n)/2,b=(c-m)/i,k=(h-M)/a,H=(-c-m)/i,at=(-h-M)/a,At=ld(1,0,b,k),gt=ld(b,k,H,at);return s===0&&gt>0&&(gt-=so),s===1&&gt<0&&(gt+=so),[w,S,At,gt]},X2=function(r){var e=r.px,t=r.py,n=r.cx,i=r.cy,a=r.rx,o=r.ry,s=r.xAxisRotation,l=s===void 0?0:s,u=r.largeArcFlag,c=u===void 0?0:u,h=r.sweepFlag,v=h===void 0?0:h,d=[];if(a===0||o===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];var g=Math.sin(l*so/360),y=Math.cos(l*so/360),x=y*(e-n)/2+g*(t-i)/2,m=-g*(e-n)/2+y*(t-i)/2;if(x===0&&m===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];a=Math.abs(a),o=Math.abs(o);var M=Math.pow(x,2)/Math.pow(a,2)+Math.pow(m,2)/Math.pow(o,2);M>1&&(a*=Math.sqrt(M),o*=Math.sqrt(M));var w=Y2(e,t,n,i,a,o,c,v,g,y,x,m),S=w[0],b=w[1],k=w[2],H=w[3],at=Math.abs(H)/(so/4);Math.abs(1-at)<1e-7&&(at=1);var At=Math.max(Math.ceil(at),1);H/=At;for(var gt=0;gt<At;gt++)d.push(G2(k,H)),k+=H;return d.map(function(Nt){var te=qu(Nt[0],a,o,y,g,S,b),ce=te.x,Me=te.y,be=qu(Nt[1],a,o,y,g,S,b),Gt=be.x,ie=be.y,de=qu(Nt[2],a,o,y,g,S,b),ue=de.x,pe=de.y;return{x1:ce,y1:Me,x2:Gt,y2:ie,x:ue,y:pe}})};function X6(r,e,t,n,i,a,o,s,l){var u=X2({px:r,py:e,cx:s,cy:l,rx:t,ry:n,xAxisRotation:i,largeArcFlag:a,sweepFlag:o});return u.reduce(function(c,h){var v=h.x1,d=h.y1,g=h.x2,y=h.y2,x=h.x,m=h.y;return c.push(v,d,g,y,x,m),c},[])}function W6(r,e){"TQ".indexOf(r[0])<0&&(e.qx=null,e.qy=null);var t=r.slice(1),n=t[0],i=t[1];switch(r[0]){case"M":return e.x=n,e.y=i,r;case"A":return["C"].concat(arcToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"Q":return e.qx=n,e.qy=i,["C"].concat(quadToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"L":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],r[2]));case"H":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],e.y1));case"V":return["C"].concat(lineToCubic(e.x1,e.y1,e.x1,r[1]));case"Z":return["C"].concat(lineToCubic(e.x1,e.y1,e.x,e.y));default:}return r}function Z6(r,e){e===void 0&&(e=!1);for(var t=path2Absolute(r),n={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null},i=[],a="",o=t.length,s,l,u=[],c=0;c<o;c+=1)t[c]&&(a=t[c][0]),i[c]=a,t[c]=segmentToCubic(t[c],n),W2(t,i,c),o=t.length,a==="Z"&&u.push(c),s=t[c],l=s.length,n.x1=+s[l-2],n.y1=+s[l-1],n.x2=+s[l-4]||n.x1,n.y2=+s[l-3]||n.y1;return e?[t,u]:t}function W2(r,e,t){if(r[t].length>7){r[t].shift();for(var n=r[t],i=t;n.length;)e[t]="A",r.splice(i+=1,0,["C"].concat(n.splice(0,6)));r.splice(t,1)}}var ud=function(r,e,t,n,i){var a=-3*e+9*t-9*n+3*i,o=r*a+6*e-12*t+6*n;return r*o-3*e+3*t},cd=function(r,e,t,n,i,a,o,s,l){l===null&&(l=1),l=l>1?1:l<0?0:l;for(var u=l/2,c=12,h=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],v=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],d=0,g=0;g<c;g++){var y=u*h[g]+u,x=ud(y,r,t,i,o),m=ud(y,e,n,a,s),M=x*x+m*m;d+=v[g]*Math.sqrt(M)}return u*d},Z2=function(r,e,t,n,i,a,o,s){for(var l=[],u=[[],[]],c,h,v,d,g=0;g<2;++g){if(g===0?(h=6*r-12*t+6*i,c=-3*r+9*t-9*i+3*o,v=3*t-3*r):(h=6*e-12*n+6*a,c=-3*e+9*n-9*a+3*s,v=3*n-3*e),Math.abs(c)<1e-12){if(Math.abs(h)<1e-12)continue;d=-v/h,d>0&&d<1&&l.push(d);continue}var y=h*h-4*v*c,x=Math.sqrt(y);if(!(y<0)){var m=(-h+x)/(2*c);m>0&&m<1&&l.push(m);var M=(-h-x)/(2*c);M>0&&M<1&&l.push(M)}}for(var w=l.length,S=w,b;w--;)d=l[w],b=1-d,u[0][w]=b*b*b*r+3*b*b*d*t+3*b*d*d*i+d*d*d*o,u[1][w]=b*b*b*e+3*b*b*d*n+3*b*d*d*a+d*d*d*s;return u[0][S]=r,u[1][S]=e,u[0][S+1]=o,u[1][S+1]=s,u[0].length=u[1].length=S+2,{min:{x:Math.min.apply(0,u[0]),y:Math.min.apply(0,u[1])},max:{x:Math.max.apply(0,u[0]),y:Math.max.apply(0,u[1])}}},$2=function(r,e,t,n,i,a,o,s){if(!(Math.max(r,t)<Math.min(i,o)||Math.min(r,t)>Math.max(i,o)||Math.max(e,n)<Math.min(a,s)||Math.min(e,n)>Math.max(a,s))){var l=(r*n-e*t)*(i-o)-(r-t)*(i*s-a*o),u=(r*n-e*t)*(a-s)-(e-n)*(i*s-a*o),c=(r-t)*(a-s)-(e-n)*(i-o);if(!!c){var h=l/c,v=u/c,d=+h.toFixed(2),g=+v.toFixed(2);if(!(d<+Math.min(r,t).toFixed(2)||d>+Math.max(r,t).toFixed(2)||d<+Math.min(i,o).toFixed(2)||d>+Math.max(i,o).toFixed(2)||g<+Math.min(e,n).toFixed(2)||g>+Math.max(e,n).toFixed(2)||g<+Math.min(a,s).toFixed(2)||g>+Math.max(a,s).toFixed(2)))return{x:h,y:v}}}},li=function(r,e,t){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height},Ku=function(r,e,t,n){return r===null&&(r=e=t=n=0),e===null&&(e=r.y,t=r.width,n=r.height,r=r.x),{x:r,y:e,width:t,w:t,height:n,h:n,x2:r+t,y2:e+n,cx:r+t/2,cy:e+n/2,r1:Math.min(t,n)/2,r2:Math.max(t,n)/2,r0:Math.sqrt(t*t+n*n)/2,path:rectPath(r,e,t,n),vb:[r,e,t,n].join(" ")}},q2=function(r,e){return r=Ku(r),e=Ku(e),li(e,r.x,r.y)||li(e,r.x2,r.y)||li(e,r.x,r.y2)||li(e,r.x2,r.y2)||li(r,e.x,e.y)||li(r,e.x2,e.y)||li(r,e.x,e.y2)||li(r,e.x2,e.y2)||(r.x<e.x2&&r.x>e.x||e.x<r.x2&&e.x>r.x)&&(r.y<e.y2&&r.y>e.y||e.y<r.y2&&e.y>r.y)},fd=function(r,e,t,n,i,a,o,s){isArray(r)||(r=[r,e,t,n,i,a,o,s]);var l=Z2.apply(null,r);return Ku(l.min.x,l.min.y,l.max.x-l.min.x,l.max.y-l.min.y)},hd=function(r,e,t,n,i,a,o,s,l){var u=1-l,c=Math.pow(u,3),h=Math.pow(u,2),v=l*l,d=v*l,g=c*r+h*3*l*t+u*3*l*l*i+d*o,y=c*e+h*3*l*n+u*3*l*l*a+d*s,x=r+2*l*(t-r)+v*(i-2*t+r),m=e+2*l*(n-e)+v*(a-2*n+e),M=t+2*l*(i-t)+v*(o-2*i+t),w=n+2*l*(a-n)+v*(s-2*a+n),S=u*r+l*t,b=u*e+l*n,k=u*i+l*o,H=u*a+l*s,at=90-Math.atan2(x-M,m-w)*180/Math.PI;return{x:g,y,m:{x,y:m},n:{x:M,y:w},start:{x:S,y:b},end:{x:k,y:H},alpha:at}},K2=function(r,e,t){var n=fd(r),i=fd(e);if(!q2(n,i))return t?0:[];for(var a=cd.apply(0,r),o=cd.apply(0,e),s=~~(a/8),l=~~(o/8),u=[],c=[],h={},v=t?0:[],d=0;d<s+1;d++){var g=hd.apply(0,r.concat(d/s));u.push({x:g.x,y:g.y,t:d/s})}for(var d=0;d<l+1;d++){var g=hd.apply(0,e.concat(d/l));c.push({x:g.x,y:g.y,t:d/l})}for(var d=0;d<s;d++)for(var y=0;y<l;y++){var x=u[d],m=u[d+1],M=c[y],w=c[y+1],S=Math.abs(m.x-x.x)<.001?"y":"x",b=Math.abs(w.x-M.x)<.001?"y":"x",k=$2(x.x,x.y,m.x,m.y,M.x,M.y,w.x,w.y);if(k){if(h[k.x.toFixed(4)]===k.y.toFixed(4))continue;h[k.x.toFixed(4)]=k.y.toFixed(4);var H=x.t+Math.abs((k[S]-x[S])/(m[S]-x[S]))*(m.t-x.t),at=M.t+Math.abs((k[b]-M[b])/(w[b]-M[b]))*(w.t-M.t);H>=0&&H<=1&&at>=0&&at<=1&&(t?v++:v.push({x:k.x,y:k.y,t1:H,t2:at}))}}return v},j2=function(r,e,t){r=path2Curve(r),e=path2Curve(e);for(var n,i,a,o,s,l,u,c,h,v,d=t?0:[],g=0,y=r.length;g<y;g++){var x=r[g];if(x[0]==="M")n=s=x[1],i=l=x[2];else{x[0]==="C"?(h=[n,i].concat(x.slice(1)),n=h[6],i=h[7]):(h=[n,i,n,i,s,l,s,l],n=s,i=l);for(var m=0,M=e.length;m<M;m++){var w=e[m];if(w[0]==="M")a=u=w[1],o=c=w[2];else{w[0]==="C"?(v=[a,o].concat(w.slice(1)),a=v[6],o=v[7]):(v=[a,o,a,o,u,c,u,c],a=u,o=c);var S=K2(h,v,t);if(t)d+=S;else{for(var b=0,k=S.length;b<k;b++)S[b].segment1=g,S[b].segment2=m,S[b].bez1=h,S[b].bez2=v;d=d.concat(S)}}}}}return d};function $6(r,e){return j2(r,e)}function Ls(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function ju(r,e){return Ls(r)*Ls(e)?(r[0]*e[0]+r[1]*e[1])/(Ls(r)*Ls(e)):1}function vd(r,e){return(r[0]*e[1]<r[1]*e[0]?-1:1)*Math.acos(ju(r,e))}function Ju(r,e){return r[0]===e[0]&&r[1]===e[1]}function J2(r,e){var t=e[1],n=e[2],i=(0,f.wQ)((0,f.c$)(e[3]),Math.PI*2),a=e[4],o=e[5],s=r[0],l=r[1],u=e[6],c=e[7],h=Math.cos(i)*(s-u)/2+Math.sin(i)*(l-c)/2,v=-1*Math.sin(i)*(s-u)/2+Math.cos(i)*(l-c)/2,d=h*h/(t*t)+v*v/(n*n);d>1&&(t*=Math.sqrt(d),n*=Math.sqrt(d));var g=t*t*(v*v)+n*n*(h*h),y=g?Math.sqrt((t*t*(n*n)-g)/g):1;a===o&&(y*=-1),isNaN(y)&&(y=0);var x=n?y*t*v/n:0,m=t?y*-n*h/t:0,M=(s+u)/2+Math.cos(i)*x-Math.sin(i)*m,w=(l+c)/2+Math.sin(i)*x+Math.cos(i)*m,S=[(h-x)/t,(v-m)/n],b=[(-1*h-x)/t,(-1*v-m)/n],k=vd([1,0],S),H=vd(S,b);return ju(S,b)<=-1&&(H=Math.PI),ju(S,b)>=1&&(H=0),o===0&&H>0&&(H=H-2*Math.PI),o===1&&H<0&&(H=H+2*Math.PI),{cx:M,cy:w,rx:Ju(r,[u,c])?0:t,ry:Ju(r,[u,c])?0:n,startAngle:k,endAngle:k+H,xRotation:i,arcFlag:a,sweepFlag:o}}function dd(r,e){return[e[0]+(e[0]-r[0]),e[1]+(e[1]-r[1])]}function Q2(r){r=B2(r);for(var e=[],t=null,n=null,i=null,a=0,o=r.length,s=0;s<o;s++){var l=r[s];n=r[s+1];var u=l[0],c={command:u,prePoint:t,params:l,startTangent:null,endTangent:null};switch(u){case"M":i=[l[1],l[2]],a=s;break;case"A":var h=J2(t,l);c.arcParams=h;break;default:break}if(u==="Z")t=i,n=r[a+1];else{var v=l.length;t=[l[v-2],l[v-1]]}n&&n[0]==="Z"&&(n=r[a],e[a]&&(e[a].prePoint=t)),c.currentPoint=t,e[a]&&Ju(t,e[a].currentPoint)&&(e[a].prePoint=c.prePoint);var d=n?[n[n.length-2],n[n.length-1]]:null;c.nextPoint=d;var g=c.prePoint;if(["L","H","V"].includes(u))c.startTangent=[g[0]-t[0],g[1]-t[1]],c.endTangent=[t[0]-g[0],t[1]-g[1]];else if(u==="Q"){var y=[l[1],l[2]];c.startTangent=[g[0]-y[0],g[1]-y[1]],c.endTangent=[t[0]-y[0],t[1]-y[1]]}else if(u==="T"){var x=e[s-1],y=dd(x.currentPoint,g);x.command==="Q"?(c.command="Q",c.startTangent=[g[0]-y[0],g[1]-y[1]],c.endTangent=[t[0]-y[0],t[1]-y[1]]):(c.command="TL",c.startTangent=[g[0]-t[0],g[1]-t[1]],c.endTangent=[t[0]-g[0],t[1]-g[1]])}else if(u==="C"){var m=[l[1],l[2]],M=[l[3],l[4]];c.startTangent=[g[0]-m[0],g[1]-m[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]],c.startTangent[0]===0&&c.startTangent[1]===0&&(c.startTangent=[m[0]-M[0],m[1]-M[1]]),c.endTangent[0]===0&&c.endTangent[1]===0&&(c.endTangent=[M[0]-m[0],M[1]-m[1]])}else if(u==="S"){var x=e[s-1],m=dd(x.currentPoint,g),M=[l[1],l[2]];x.command==="C"?(c.command="C",c.startTangent=[g[0]-m[0],g[1]-m[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]]):(c.command="SQ",c.startTangent=[g[0]-M[0],g[1]-M[1]],c.endTangent=[t[0]-M[0],t[1]-M[1]])}else if(u==="A"){var w=.001,S=c.arcParams||{},b=S.cx,k=b===void 0?0:b,H=S.cy,at=H===void 0?0:H,At=S.rx,gt=At===void 0?0:At,Nt=S.ry,te=Nt===void 0?0:Nt,ce=S.sweepFlag,Me=ce===void 0?0:ce,be=S.startAngle,Gt=be===void 0?0:be,ie=S.endAngle,de=ie===void 0?0:ie;Me===0&&(w*=-1);var ue=gt*Math.cos(Gt-w)+k,pe=te*Math.sin(Gt-w)+at;c.startTangent=[ue-i[0],pe-i[1]];var Ee=gt*Math.cos(Gt+de+w)+k,Ne=te*Math.sin(Gt+de-w)+at;c.endTangent=[g[0]-Ee,g[1]-Ne]}e.push(c)}return e}function pd(r){for(var e=[],t=r.length,n=0;n<t-1;n++){var i=r[n],a=r[n+1];e.push({from:{x:i[0],y:i[1]},to:{x:a[0],y:a[1]}})}if(e.length>1){var o=r[0],s=r[t-1];e.push({from:{x:s[0],y:s[1]},to:{x:o[0],y:o[1]}})}return e}function tS(r,e){var t=!1;return each(r,function(n){if(getLineIntersect(n.from,n.to,e.from,e.to))return t=!0,!1}),t}function gd(r){var e=r.map(function(n){return n[0]}),t=r.map(function(n){return n[1]});return{minX:Math.min.apply(null,e),maxX:Math.max.apply(null,e),minY:Math.min.apply(null,t),maxY:Math.max.apply(null,t)}}function eS(r,e){return!(e.minX>r.maxX||e.maxX<r.minX||e.minY>r.maxY||e.maxY<r.minY)}function q6(r,e){if(r.length<2||e.length<2)return!1;var t=gd(r),n=gd(e);if(!eS(t,n))return!1;var i=!1;if(each(e,function(l){if(isPointInPolygon(r,l[0],l[1]))return i=!0,!1}),i||(each(r,function(l){if(isPointInPolygon(e,l[0],l[1]))return i=!0,!1}),i))return!0;var a=pd(r),o=pd(e),s=!1;return each(o,function(l){if(tS(a,l))return s=!0,!1}),s}var rS={circle:function(r,e,t){return[["M",r-t,e],["A",t,t,0,1,0,r+t,e],["A",t,t,0,1,0,r-t,e]]},square:function(r,e,t){return[["M",r-t,e-t],["L",r+t,e-t],["L",r+t,e+t],["L",r-t,e+t],["Z"]]},diamond:function(r,e,t){return[["M",r-t,e],["L",r,e-t],["L",r+t,e],["L",r,e+t],["Z"]]},triangle:function(r,e,t){var n=t*Math.sin(1/3*Math.PI);return[["M",r-t,e+n],["L",r,e-n],["L",r+t,e+n],["Z"]]},"triangle-down":function(r,e,t){var n=t*Math.sin(1/3*Math.PI);return[["M",r-t,e-n],["L",r+t,e-n],["L",r,e+n],["Z"]]}},nS=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.initAttrs=function(t){this._resetParamsCache()},e.prototype._resetParamsCache=function(){this.set("paramsCache",{})},e.prototype.onAttrChange=function(t,n,i){r.prototype.onAttrChange.call(this,t,n,i),["symbol","x","y","r","radius"].indexOf(t)!==-1&&this._resetParamsCache()},e.prototype.isOnlyHitBox=function(){return!0},e.prototype._getR=function(t){return(0,f.UM)(t.r)?t.radius:t.r},e.prototype._getPath=function(){var t=this.attr(),n=t.x,i=t.y,a=t.symbol||"circle",o=this._getR(t),s,l;if((0,f.mf)(a))s=a,l=s(n,i,o),l=sd(l);else{if(s=e.Symbols[a],!s)return console.warn(a+" marker is not supported."),null;l=s(n,i,o)}return l},e.prototype.createPath=function(t){var n=this._getPath(),i=this.get("paramsCache");nd(this,t,{path:n},i)},e.Symbols=rS,e}(dn),iS=nS;function yd(r,e,t){var n=(0,F.getOffScreenContext)();return r.createPath(n),n.isPointInPath(e,t)}var aS=1e-6;function Qu(r){return Math.abs(r)<aS?0:r<0?-1:1}function oS(r,e,t){return(t[0]-r[0])*(e[1]-r[1])==(e[0]-r[0])*(t[1]-r[1])&&Math.min(r[0],e[0])<=t[0]&&t[0]<=Math.max(r[0],e[0])&&Math.min(r[1],e[1])<=t[1]&&t[1]<=Math.max(r[1],e[1])}function md(r,e,t){var n=!1,i=r.length;if(i<=2)return!1;for(var a=0;a<i;a++){var o=r[a],s=r[(a+1)%i];if(oS(o,s,[e,t]))return!0;Qu(o[1]-t)>0!=Qu(s[1]-t)>0&&Qu(e-(t-o[1])*(o[0]-s[0])/(o[1]-s[1])-o[0])<0&&(n=!n)}return n}function lo(r,e,t,n,i,a,o,s){var l=(Math.atan2(s-e,o-r)+Math.PI*2)%(Math.PI*2);if(l<n||l>i)return!1;var u={x:r+t*Math.cos(l),y:e+t*Math.sin(l)};return $v(u.x,u.y,o,s)<=a/2}var sS=nr.vs;function lS(r){for(var e=!1,t=r.length,n=0;n<t;n++){var i=r[n],a=i[0];if(a==="C"||a==="A"||a==="Q"){e=!0;break}}return e}function uS(r,e,t,n,i){for(var a=!1,o=e/2,s=0;s<r.length;s++){var l=r[s],u=l.currentPoint,c=l.params,h=l.prePoint,v=l.box;if(!(v&&!Fi(v.x-o,v.y-o,v.width+e,v.height+e,t,n))){switch(l.command){case"L":case"Z":a=si(h[0],h[1],u[0],u[1],e,t,n);break;case"Q":var d=Pr.lD.pointDistance(h[0],h[1],c[1],c[2],c[3],c[4],t,n);a=d<=e/2;break;case"C":var g=Pr.Ll.pointDistance(h[0],h[1],c[1],c[2],c[3],c[4],c[5],c[6],t,n,i);a=g<=e/2;break;case"A":var y=l.arcParams,x=y.cx,m=y.cy,M=y.rx,w=y.ry,S=y.startAngle,b=y.endAngle,k=y.xRotation,H=[t,n,1],at=M>w?M:w,At=M>w?1:M/w,gt=M>w?w/M:1,Nt=sS(null,[["t",-x,-m],["r",-k],["s",1/At,1/gt]]);Ba(H,H,Nt),a=lo(0,0,at,S,b,e,H[0],H[1]);break;default:break}if(a)break}}return a}function cS(r){for(var e=r.length,t=[],n=[],i=[],a=0;a<e;a++){var o=r[a],s=o[0];s==="M"?(i.length&&(n.push(i),i=[]),i.push([o[1],o[2]])):s==="Z"?i.length&&(t.push(i),i=[]):i.push([o[1],o[2]])}return i.length>0&&n.push(i),{polygons:t,polylines:n}}var Ds=(0,p.pi)({hasArc:lS,extractPolygons:cS,isPointInStroke:uS},F.PathUtil);function xd(r,e,t){for(var n=!1,i=0;i<r.length;i++){var a=r[i];if(n=md(a,e,t),n)break}return n}var fS=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{startArrow:!1,endArrow:!1})},e.prototype.initAttrs=function(t){this._setPathArr(t.path),this.setArrow()},e.prototype.onAttrChange=function(t,n,i){r.prototype.onAttrChange.call(this,t,n,i),t==="path"&&this._setPathArr(n),this.setArrow()},e.prototype._setPathArr=function(t){this.attrs.path=sd(t);var n=Ds.hasArc(t);this.set("hasArc",n),this.set("paramsCache",{}),this.set("segments",null),this.set("curve",null),this.set("tCache",null),this.set("totalLength",null)},e.prototype.getSegments=function(){var t=this.get("segements");return t||(t=Q2(this.attr("path")),this.set("segments",t)),t},e.prototype.setArrow=function(){var t=this.attr(),n=t.startArrow,i=t.endArrow;if(n){var a=this.getStartTangent();Gu(this,t,a[0][0],a[0][1],a[1][0],a[1][1])}if(i){var a=this.getEndTangent();Yu(this,t,a[0][0],a[0][1],a[1][0],a[1][1])}},e.prototype.isInStrokeOrPath=function(t,n,i,a,o){var s=this.getSegments(),l=this.get("hasArc"),u=!1;if(i){var c=this.getTotalLength();u=Ds.isPointInStroke(s,o,t,n,c)}if(!u&&a)if(l)u=yd(this,t,n);else{var h=this.attr("path"),v=Ds.extractPolygons(h);u=xd(v.polygons,t,n)||xd(v.polylines,t,n)}return u},e.prototype.createPath=function(t){var n=this.attr(),i=this.get("paramsCache");nd(this,t,n,i)},e.prototype.afterDrawPath=function(t){var n=this.get("startArrowShape"),i=this.get("endArrowShape");n&&n.draw(t),i&&i.draw(t)},e.prototype.getTotalLength=function(){var t=this.get("totalLength");return(0,f.UM)(t)?(this._calculateCurve(),this._setTcache(),this.get("totalLength")):t},e.prototype.getPoint=function(t){var n=this.get("tCache");n||(this._calculateCurve(),this._setTcache(),n=this.get("tCache"));var i,a,o=this.get("curve");if(!n||n.length===0)return o?{x:o[0][1],y:o[0][2]}:null;(0,f.S6)(n,function(c,h){t>=c[0]&&t<=c[1]&&(i=(t-c[0])/(c[1]-c[0]),a=h)});var s=o[a];if((0,f.UM)(s)||(0,f.UM)(a))return null;var l=s.length,u=o[a+1];return Pr.Ll.pointAt(s[l-2],s[l-1],u[1],u[2],u[3],u[4],u[5],u[6],i)},e.prototype._calculateCurve=function(){var t=this.attr().path;this.set("curve",Ds.pathToCurve(t))},e.prototype._setTcache=function(){var t=0,n=0,i=[],a,o,s,l,u=this.get("curve");if(!!u){if((0,f.S6)(u,function(c,h){s=u[h+1],l=c.length,s&&(t+=Pr.Ll.length(c[l-2],c[l-1],s[1],s[2],s[3],s[4],s[5],s[6])||0)}),this.set("totalLength",t),t===0){this.set("tCache",[]);return}(0,f.S6)(u,function(c,h){s=u[h+1],l=c.length,s&&(a=[],a[0]=n/t,o=Pr.Ll.length(c[l-2],c[l-1],s[1],s[2],s[3],s[4],s[5],s[6]),n+=o||0,a[1]=n/t,i.push(a))}),this.set("tCache",i)}},e.prototype.getStartTangent=function(){var t=this.getSegments(),n;if(t.length>1){var i=t[0].currentPoint,a=t[1].currentPoint,o=t[1].startTangent;n=[],o?(n.push([i[0]-o[0],i[1]-o[1]]),n.push([i[0],i[1]])):(n.push([a[0],a[1]]),n.push([i[0],i[1]]))}return n},e.prototype.getEndTangent=function(){var t=this.getSegments(),n=t.length,i;if(n>1){var a=t[n-2].currentPoint,o=t[n-1].currentPoint,s=t[n-1].endTangent;i=[],s?(i.push([o[0]-s[0],o[1]-s[1]]),i.push([o[0],o[1]])):(i.push([a[0],a[1]]),i.push([o[0],o[1]]))}return i},e}(dn),tc=fS;function Md(r,e,t,n,i){var a=r.length;if(a<2)return!1;for(var o=0;o<a-1;o++){var s=r[o][0],l=r[o][1],u=r[o+1][0],c=r[o+1][1];if(si(s,l,u,c,e,t,n))return!0}if(i){var h=r[0],v=r[a-1];if(si(h[0],h[1],v[0],v[1],e,t,n))return!0}return!1}var hS=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.isInStrokeOrPath=function(t,n,i,a,o){var s=this.attr().points,l=!1;return i&&(l=Md(s,o,t,n,!0)),!l&&a&&(l=md(s,t,n)),l},e.prototype.createPath=function(t){var n=this.attr(),i=n.points;if(!(i.length<2)){t.beginPath();for(var a=0;a<i.length;a++){var o=i[a];a===0?t.moveTo(o[0],o[1]):t.lineTo(o[0],o[1])}t.closePath()}},e}(dn),vS=hS,dS=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{startArrow:!1,endArrow:!1})},e.prototype.initAttrs=function(t){this.setArrow()},e.prototype.onAttrChange=function(t,n,i){r.prototype.onAttrChange.call(this,t,n,i),this.setArrow(),["points"].indexOf(t)!==-1&&this._resetCache()},e.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},e.prototype.setArrow=function(){var t=this.attr(),n=this.attrs,i=n.points,a=n.startArrow,o=n.endArrow,s=i.length,l=i[0][0],u=i[0][1],c=i[s-1][0],h=i[s-1][1];a&&Gu(this,t,i[1][0],i[1][1],l,u),o&&Yu(this,t,i[s-2][0],i[s-2][1],c,h)},e.prototype.isFill=function(){return!1},e.prototype.isInStrokeOrPath=function(t,n,i,a,o){if(!i||!o)return!1;var s=this.attr().points;return Md(s,o,t,n,!1)},e.prototype.isStroke=function(){return!0},e.prototype.createPath=function(t){var n=this.attr(),i=n.points,a=n.startArrow,o=n.endArrow,s=i.length;if(!(i.length<2)){var l=i[0][0],u=i[0][1],c=i[s-1][0],h=i[s-1][1];if(a&&a.d){var v=Ii(l,u,i[1][0],i[1][1],a.d);l+=v.dx,u+=v.dy}if(o&&o.d){var v=Ii(i[s-2][0],i[s-2][1],c,h,o.d);c-=v.dx,h-=v.dy}t.beginPath(),t.moveTo(l,u);for(var d=0;d<s-1;d++){var g=i[d];t.lineTo(g[0],g[1])}t.lineTo(c,h)}},e.prototype.afterDrawPath=function(t){var n=this.get("startArrowShape"),i=this.get("endArrowShape");n&&n.draw(t),i&&i.draw(t)},e.prototype.getTotalLength=function(){var t=this.attr().points,n=this.get("totalLength");return(0,f.UM)(n)?(this.set("totalLength",Pr.aH.length(t)),this.get("totalLength")):n},e.prototype.getPoint=function(t){var n=this.attr().points,i=this.get("tCache");i||(this._setTcache(),i=this.get("tCache"));var a,o;return(0,f.S6)(i,function(s,l){t>=s[0]&&t<=s[1]&&(a=(t-s[0])/(s[1]-s[0]),o=l)}),Pr.x1.pointAt(n[o][0],n[o][1],n[o+1][0],n[o+1][1],a)},e.prototype._setTcache=function(){var t=this.attr().points;if(!(!t||t.length===0)){var n=this.getTotalLength();if(!(n<=0)){var i=0,a=[],o,s;(0,f.S6)(t,function(l,u){t[u+1]&&(o=[],o[0]=i/n,s=Pr.x1.length(l[0],l[1],t[u+1][0],t[u+1][1]),i+=s,o[1]=i/n,a.push(o))}),this.set("tCache",a)}}},e.prototype.getStartTangent=function(){var t=this.attr().points,n=[];return n.push([t[1][0],t[1][1]]),n.push([t[0][0],t[0][1]]),n},e.prototype.getEndTangent=function(){var t=this.attr().points,n=t.length-1,i=[];return i.push([t[n-1][0],t[n-1][1]]),i.push([t[n][0],t[n][1]]),i},e}(dn),pS=dS;function gS(r,e,t,n,i,a,o){var s=i/2;return Fi(r-s,e-s,t,i,a,o)||Fi(r+t-s,e-s,i,n,a,o)||Fi(r+s,e+n-s,t,i,a,o)||Fi(r-s,e+s,i,n,a,o)}function yS(r,e,t,n,i,a,o,s){var l=a/2;return si(r+i,e,r+t-i,e,a,o,s)||si(r+t,e+i,r+t,e+n-i,a,o,s)||si(r+t-i,e+n,r+i,e+n,a,o,s)||si(r,e+n-i,r,e+i,a,o,s)||lo(r+t-i,e+i,i,1.5*Math.PI,2*Math.PI,a,o,s)||lo(r+t-i,e+n-i,i,0,.5*Math.PI,a,o,s)||lo(r+i,e+n-i,i,.5*Math.PI,Math.PI,a,o,s)||lo(r+i,e+i,i,Math.PI,1.5*Math.PI,a,o,s)}var mS=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,width:0,height:0,radius:0})},e.prototype.isInStrokeOrPath=function(t,n,i,a,o){var s=this.attr(),l=s.x,u=s.y,c=s.width,h=s.height,v=s.radius;if(v){var g=!1;return i&&(g=yS(l,u,c,h,v,o,t,n)),!g&&a&&(g=yd(this,t,n)),g}else{var d=o/2;if(a&&i)return Fi(l-d,u-d,c+d,h+d,t,n);if(a)return Fi(l,u,c,h,t,n);if(i)return gS(l,u,c,h,o,t,n)}},e.prototype.createPath=function(t){var n=this.attr(),i=n.x,a=n.y,o=n.width,s=n.height,l=n.radius;if(t.beginPath(),l===0)t.rect(i,a,o,s);else{var u=y2(l),c=u[0],h=u[1],v=u[2],d=u[3];t.moveTo(i+c,a),t.lineTo(i+o-h,a),h!==0&&t.arc(i+o-h,a+h,h,-Math.PI/2,0),t.lineTo(i+o,a+s-v),v!==0&&t.arc(i+o-v,a+s-v,v,0,Math.PI/2),t.lineTo(i+d,a+s),d!==0&&t.arc(i+d,a+s-d,d,Math.PI/2,Math.PI),t.lineTo(i,a+c),c!==0&&t.arc(i+c,a+c,c,Math.PI,Math.PI*1.5),t.closePath()}},e}(dn),xS=mS,MS=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},e.prototype.isOnlyHitBox=function(){return!0},e.prototype.initAttrs=function(t){this._assembleFont(),t.text&&this._setText(t.text)},e.prototype._assembleFont=function(){var t=this.attrs;t.font=(0,F.assembleFont)(t)},e.prototype._setText=function(t){var n=null;(0,f.HD)(t)&&t.indexOf(`
  43. `)!==-1&&(n=t.split(`
  44. `)),this.set("textArr",n)},e.prototype.onAttrChange=function(t,n,i){r.prototype.onAttrChange.call(this,t,n,i),t.startsWith("font")&&this._assembleFont(),t==="text"&&this._setText(n)},e.prototype._getSpaceingY=function(){var t=this.attrs,n=t.lineHeight,i=t.fontSize*1;return n?n-i:i*.14},e.prototype._drawTextArr=function(t,n,i){var a=this.attrs,o=a.textBaseline,s=a.x,l=a.y,u=a.fontSize*1,c=this._getSpaceingY(),h=(0,F.getTextHeight)(a.text,a.fontSize,a.lineHeight),v;(0,f.S6)(n,function(d,g){v=l+g*(c+u)-h+u,o==="middle"&&(v+=h-u-(h-u)/2),o==="top"&&(v+=h-u),(0,f.UM)(d)||(i?t.fillText(d,s,v):t.strokeText(d,s,v))})},e.prototype._drawText=function(t,n){var i=this.attr(),a=i.x,o=i.y,s=this.get("textArr");if(s)this._drawTextArr(t,s,n);else{var l=i.text;(0,f.UM)(l)||(n?t.fillText(l,a,o):t.strokeText(l,a,o))}},e.prototype.strokeAndFill=function(t){var n=this.attrs,i=n.lineWidth,a=n.opacity,o=n.strokeOpacity,s=n.fillOpacity;this.isStroke()&&i>0&&(!(0,f.UM)(o)&&o!==1&&(t.globalAlpha=a),this.stroke(t)),this.isFill()&&(!(0,f.UM)(s)&&s!==1?(t.globalAlpha=s,this.fill(t),t.globalAlpha=a):this.fill(t)),this.afterDrawPath(t)},e.prototype.fill=function(t){this._drawText(t,!0)},e.prototype.stroke=function(t){this._drawText(t,!1)},e}(dn),wS=MS;function SS(r,e){if(e){var t=(0,F.invert)(e);return(0,F.multiplyVec2)(t,r)}return r}function wd(r,e,t){var n=r.getTotalMatrix();if(n){var i=SS([e,t,1],n),a=i[0],o=i[1];return[a,o]}return[e,t]}function Sd(r,e,t){if(r.isCanvas&&r.isCanvas())return!0;if(!(0,F.isAllowCapture)(r)||r.cfg.isInView===!1)return!1;if(r.cfg.clipShape){var n=wd(r,e,t),i=n[0],a=n[1];if(r.isClipped(i,a))return!1}var o=r.cfg.cacheCanvasBBox||r.getCanvasBBox();return e>=o.minX&&e<=o.maxX&&t>=o.minY&&t<=o.maxY}function Cd(r,e,t){if(!Sd(r,e,t))return null;for(var n=null,i=r.getChildren(),a=i.length,o=a-1;o>=0;o--){var s=i[o];if(s.isGroup())n=Cd(s,e,t);else if(Sd(s,e,t)){var l=s,u=wd(s,e,t),c=u[0],h=u[1];l.isInShape(c,h)&&(n=s)}if(n)break}return n}var CS=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){var t=r.prototype.getDefaultCfg.call(this);return t.renderer="canvas",t.autoDraw=!0,t.localRefresh=!0,t.refreshElements=[],t.clipView=!0,t.quickHit=!1,t},e.prototype.onCanvasChange=function(t){(t==="attr"||t==="sort"||t==="changeSize")&&(this.set("refreshElements",[this]),this.draw())},e.prototype.getShapeBase=function(){return it},e.prototype.getGroupBase=function(){return $u},e.prototype.getPixelRatio=function(){var t=this.get("pixelRatio")||l2();return t>=1?Math.ceil(t):1},e.prototype.getViewRange=function(){return{minX:0,minY:0,maxX:this.cfg.width,maxY:this.cfg.height}},e.prototype.createDom=function(){var t=document.createElement("canvas"),n=t.getContext("2d");return this.set("context",n),t},e.prototype.setDOMSize=function(t,n){r.prototype.setDOMSize.call(this,t,n);var i=this.get("context"),a=this.get("el"),o=this.getPixelRatio();a.width=o*t,a.height=o*n,o>1&&i.scale(o,o)},e.prototype.clear=function(){r.prototype.clear.call(this),this._clearFrame();var t=this.get("context"),n=this.get("el");t.clearRect(0,0,n.width,n.height)},e.prototype.getShape=function(t,n){var i;return this.get("quickHit")?i=Cd(this,t,n):i=r.prototype.getShape.call(this,t,n,null),i},e.prototype._getRefreshRegion=function(){var t=this.get("refreshElements"),n=this.getViewRange(),i;if(t.length&&t[0]===this)i=n;else if(i=w2(t),i){i.minX=Math.floor(i.minX),i.minY=Math.floor(i.minY),i.maxX=Math.ceil(i.maxX),i.maxY=Math.ceil(i.maxY),i.maxY+=1;var a=this.get("clipView");a&&(i=S2(i,n))}return i},e.prototype.refreshElement=function(t){var n=this.get("refreshElements");n.push(t)},e.prototype._clearFrame=function(){var t=this.get("drawFrame");t&&((0,f.VS)(t),this.set("drawFrame",null),this.set("refreshElements",[]))},e.prototype.draw=function(){var t=this.get("drawFrame");this.get("autoDraw")&&t||this._startDraw()},e.prototype._drawAll=function(){var t=this.get("context"),n=this.get("el"),i=this.getChildren();t.clearRect(0,0,n.width,n.height),ha(t,this),Xu(t,i),this.set("refreshElements",[])},e.prototype._drawRegion=function(){var t=this.get("context"),n=this.get("refreshElements"),i=this.getChildren(),a=this._getRefreshRegion();a?(t.clearRect(a.minX,a.minY,a.maxX-a.minX,a.maxY-a.minY),t.save(),t.beginPath(),t.rect(a.minX,a.minY,a.maxX-a.minX,a.maxY-a.minY),t.clip(),ha(t,this),m2(this,i,a),Xu(t,i,a),t.restore()):n.length&&rd(n),(0,f.S6)(n,function(o){o.get("hasChanged")&&o.set("hasChanged",!1)}),this.set("refreshElements",[])},e.prototype._startDraw=function(){var t=this,n=this.get("drawFrame"),i=this.get("drawFrameCallback");n||(n=(0,f.U7)(function(){t.get("localRefresh")?t._drawRegion():t._drawAll(),t.set("drawFrame",null),i&&i()}),this.set("drawFrame",n))},e.prototype.skipDraw=function(){},e.prototype.removeDom=function(){var t=this.get("el");t.width=0,t.height=0,t.parentNode.removeChild(t)},e}(F.AbstractCanvas),AS=CS,bS="0.5.12",ec={rect:"path",circle:"circle",line:"line",path:"path",marker:"path",text:"text",polyline:"polyline",polygon:"polygon",image:"image",ellipse:"ellipse",dom:"foreignObject"},Ze={opacity:"opacity",fillStyle:"fill",fill:"fill",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",x:"x",y:"y",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",x1:"x1",x2:"x2",y1:"y1",y2:"y2",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",startArrow:"marker-start",endArrow:"marker-end",path:"d",class:"class",id:"id",style:"style",preserveAspectRatio:"preserveAspectRatio"},K6=null;function an(r){return document.createElementNS("http://www.w3.org/2000/svg",r)}function Ad(r){var e=ec[r.type],t=r.getParent();if(!e)throw new Error("the type "+r.type+" is not supported by svg");var n=an(e);if(r.get("id")&&(n.id=r.get("id")),r.set("el",n),r.set("attrs",{}),t){var i=t.get("el");i||(i=t.createDom(),t.set("el",i)),i.appendChild(n)}return n}function bd(r,e){var t=r.get("el"),n=(0,f.qo)(t.children).sort(e),i=document.createDocumentFragment();n.forEach(function(a){i.appendChild(a)}),t.appendChild(i)}function TS(r,e){var t=r.parentNode,n=Array.from(t.childNodes).filter(function(s){return s.nodeType===1&&s.nodeName.toLowerCase()!=="defs"}),i=n[e],a=n.indexOf(r);if(i){if(a>e)t.insertBefore(r,i);else if(a<e){var o=n[e+1];o?t.insertBefore(r,o):t.appendChild(r)}}else t.appendChild(r)}function ES(r,e){var t=r.cfg.el,n=r.attr(),i={dx:n.shadowOffsetX,dy:n.shadowOffsetY,blur:n.shadowBlur,color:n.shadowColor};if(!i.dx&&!i.dy&&!i.blur&&!i.color)t.removeAttribute("filter");else{var a=e.find("filter",i);a||(a=e.addShadow(i)),t.setAttribute("filter","url(#"+a+")")}}function uo(r){var e=r.attr().matrix;if(e){for(var t=r.cfg.el,n=[],i=0;i<9;i+=3)n.push(e[i]+","+e[i+1]);n=n.join(","),n.indexOf("NaN")===-1?t.setAttribute("transform","matrix("+n+")"):console.warn("invalid matrix:",e)}}function co(r,e){var t=r.getClip(),n=r.get("el");if(!t)n.removeAttribute("clip-path");else if(t&&!n.hasAttribute("clip-path")){Ad(t),t.createPath(e);var i=e.addClip(t);n.setAttribute("clip-path","url(#"+i+")")}}function Td(r,e){e.forEach(function(t){t.draw(r)})}function Ed(r,e){var t=r.get("canvas");if(t&&t.get("autoDraw")){var n=t.get("context"),i=r.getParent(),a=i?i.getChildren():[t],o=r.get("el");if(e==="remove"){var s=r.get("isClipShape");if(s){var l=o&&o.parentNode,u=l&&l.parentNode;l&&u&&u.removeChild(l)}else o&&o.parentNode&&o.parentNode.removeChild(o)}else if(e==="show")o.setAttribute("visibility","visible");else if(e==="hide")o.setAttribute("visibility","hidden");else if(e==="zIndex")TS(o,a.indexOf(r));else if(e==="sort"){var c=r.get("children");c&&c.length&&bd(r,function(h,v){return c.indexOf(h)-c.indexOf(v)?1:0})}else e==="clear"?o&&(o.innerHTML=""):e==="matrix"?uo(r):e==="clip"?co(r,n):e==="attr"||e==="add"&&r.draw(n)}}var _S=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.isEntityGroup=function(){return!0},e.prototype.createDom=function(){var t=an("g");this.set("el",t);var n=this.getParent();if(n){var i=n.get("el");i||(i=n.createDom(),n.set("el",i)),i.appendChild(t)}return t},e.prototype.afterAttrsChange=function(t){r.prototype.afterAttrsChange.call(this,t);var n=this.get("canvas");if(n&&n.get("autoDraw")){var i=n.get("context");this.createPath(i,t)}},e.prototype.onCanvasChange=function(t){Ed(this,t)},e.prototype.getShapeBase=function(){return Ft},e.prototype.getGroupBase=function(){return e},e.prototype.draw=function(t){var n=this.getChildren(),i=this.get("el");this.get("destroyed")?i&&i.parentNode.removeChild(i):(i||this.createDom(),co(this,t),this.createPath(t),n.length&&Td(t,n))},e.prototype.createPath=function(t,n){var i=this.attr(),a=this.get("el");(0,f.S6)(n||i,function(o,s){Ze[s]&&a.setAttribute(Ze[s],o)}),uo(this)},e}(F.AbstractGroup),rc=_S,FS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="svg",t.canFill=!1,t.canStroke=!1,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},e.prototype.afterAttrsChange=function(t){r.prototype.afterAttrsChange.call(this,t);var n=this.get("canvas");if(n&&n.get("autoDraw")){var i=n.get("context");this.draw(i,t)}},e.prototype.getShapeBase=function(){return Ft},e.prototype.getGroupBase=function(){return rc},e.prototype.onCanvasChange=function(t){Ed(this,t)},e.prototype.calculateBBox=function(){var t=this.get("el"),n=null;if(t)n=t.getBBox();else{var i=(0,F.getBBoxMethod)(this.get("type"));i&&(n=i(this))}if(n){var a=n.x,o=n.y,s=n.width,l=n.height,u=this.getHitLineWidth(),c=u/2,h=a-c,v=o-c,d=a+s+c,g=o+l+c;return{x:h,y:v,minX:h,minY:v,maxX:d,maxY:g,width:s+u,height:l+u}}return{x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0}},e.prototype.isFill=function(){var t=this.attr(),n=t.fill,i=t.fillStyle;return(n||i||this.isClipShape())&&this.canFill},e.prototype.isStroke=function(){var t=this.attr(),n=t.stroke,i=t.strokeStyle;return(n||i)&&this.canStroke},e.prototype.draw=function(t,n){var i=this.get("el");this.get("destroyed")?i&&i.parentNode.removeChild(i):(i||Ad(this),co(this,t),this.createPath(t,n),this.shadow(t,n),this.strokeAndFill(t,n),this.transform(n))},e.prototype.createPath=function(t,n){},e.prototype.strokeAndFill=function(t,n){var i=n||this.attr(),a=i.fill,o=i.fillStyle,s=i.stroke,l=i.strokeStyle,u=i.fillOpacity,c=i.strokeOpacity,h=i.lineWidth,v=this.get("el");this.canFill&&(n?"fill"in i?this._setColor(t,"fill",a):"fillStyle"in i&&this._setColor(t,"fill",o):this._setColor(t,"fill",a||o),u&&v.setAttribute(Ze.fillOpacity,u)),this.canStroke&&h>0&&(n?"stroke"in i?this._setColor(t,"stroke",s):"strokeStyle"in i&&this._setColor(t,"stroke",l):this._setColor(t,"stroke",s||l),c&&v.setAttribute(Ze.strokeOpacity,c),h&&v.setAttribute(Ze.lineWidth,h))},e.prototype._setColor=function(t,n,i){var a=this.get("el");if(!i){a.setAttribute(Ze[n],"none");return}if(i=i.trim(),/^[r,R,L,l]{1}[\s]*\(/.test(i)){var o=t.find("gradient",i);o||(o=t.addGradient(i)),a.setAttribute(Ze[n],"url(#"+o+")")}else if(/^[p,P]{1}[\s]*\(/.test(i)){var o=t.find("pattern",i);o||(o=t.addPattern(i)),a.setAttribute(Ze[n],"url(#"+o+")")}else a.setAttribute(Ze[n],i)},e.prototype.shadow=function(t,n){var i=this.attr(),a=n||i,o=a.shadowOffsetX,s=a.shadowOffsetY,l=a.shadowBlur,u=a.shadowColor;(o||s||l||u)&&ES(this,t)},e.prototype.transform=function(t){var n=this.attr(),i=(t||n).matrix;i&&uo(this)},e.prototype.isInShape=function(t,n){return this.isPointInPath(t,n)},e.prototype.isPointInPath=function(t,n){var i=this.get("el"),a=this.get("canvas"),o=a.get("el").getBoundingClientRect(),s=t+o.left,l=n+o.top,u=document.elementFromPoint(s,l);return!!(u&&u.isEqualNode(i))},e.prototype.getHitLineWidth=function(){var t=this.attrs,n=t.lineWidth,i=t.lineAppendWidth;return this.isStroke()?n+i:0},e}(F.AbstractShape),on=FS,IS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="circle",t.canFill=!0,t.canStroke=!0,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,r:0})},e.prototype.createPath=function(t,n){var i=this.attr(),a=this.get("el");(0,f.S6)(n||i,function(o,s){s==="x"||s==="y"?a.setAttribute("c"+s,o):Ze[s]&&a.setAttribute(Ze[s],o)})},e}(on),PS=IS,LS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dom",t.canFill=!1,t.canStroke=!1,t}return e.prototype.createPath=function(t,n){var i=this.attr(),a=this.get("el");if((0,f.S6)(n||i,function(u,c){Ze[c]&&a.setAttribute(Ze[c],u)}),typeof i.html=="function"){var o=i.html.call(this,i);if(o instanceof Element||o instanceof HTMLDocument){for(var s=a.childNodes,l=s.length-1;l>=0;l--)a.removeChild(s[l]);a.appendChild(o)}else a.innerHTML=o}else a.innerHTML=i.html},e}(on),DS=LS,OS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="ellipse",t.canFill=!0,t.canStroke=!0,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,rx:0,ry:0})},e.prototype.createPath=function(t,n){var i=this.attr(),a=this.get("el");(0,f.S6)(n||i,function(o,s){s==="x"||s==="y"?a.setAttribute("c"+s,o):Ze[s]&&a.setAttribute(Ze[s],o)})},e}(on),kS=OS,BS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="image",t.canFill=!1,t.canStroke=!1,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,width:0,height:0})},e.prototype.createPath=function(t,n){var i=this,a=this.attr(),o=this.get("el");(0,f.S6)(n||a,function(s,l){l==="img"?i._setImage(a.img):Ze[l]&&o.setAttribute(Ze[l],s)})},e.prototype.setAttr=function(t,n){this.attrs[t]=n,t==="img"&&this._setImage(n)},e.prototype._setImage=function(t){var n=this.attr(),i=this.get("el");if((0,f.HD)(t))i.setAttribute("href",t);else if(t instanceof window.Image)n.width||(i.setAttribute("width",t.width),this.attr("width",t.width)),n.height||(i.setAttribute("height",t.height),this.attr("height",t.height)),i.setAttribute("href",t.src);else if(t instanceof HTMLElement&&(0,f.HD)(t.nodeName)&&t.nodeName.toUpperCase()==="CANVAS")i.setAttribute("href",t.toDataURL());else if(t instanceof ImageData){var a=document.createElement("canvas");a.setAttribute("width",""+t.width),a.setAttribute("height",""+t.height),a.getContext("2d").putImageData(t,0,0),n.width||(i.setAttribute("width",""+t.width),this.attr("width",t.width)),n.height||(i.setAttribute("height",""+t.height),this.attr("height",t.height)),i.setAttribute("href",a.toDataURL())}},e}(on),RS=BS,NS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="line",t.canFill=!1,t.canStroke=!0,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},e.prototype.createPath=function(t,n){var i=this.attr(),a=this.get("el");(0,f.S6)(n||i,function(o,s){if(s==="startArrow"||s==="endArrow")if(o){var l=(0,f.Kn)(o)?t.addArrow(i,Ze[s]):t.getDefaultArrow(i,Ze[s]);a.setAttribute(Ze[s],"url(#"+l+")")}else a.removeAttribute(Ze[s]);else Ze[s]&&a.setAttribute(Ze[s],o)})},e.prototype.getTotalLength=function(){var t=this.attr(),n=t.x1,i=t.y1,a=t.x2,o=t.y2;return Pr.x1.length(n,i,a,o)},e.prototype.getPoint=function(t){var n=this.attr(),i=n.x1,a=n.y1,o=n.x2,s=n.y2;return Pr.x1.pointAt(i,a,o,s,t)},e}(on),US=NS,Os={circle:function(r,e,t){return[["M",r,e],["m",-t,0],["a",t,t,0,1,0,t*2,0],["a",t,t,0,1,0,-t*2,0]]},square:function(r,e,t){return[["M",r-t,e-t],["L",r+t,e-t],["L",r+t,e+t],["L",r-t,e+t],["Z"]]},diamond:function(r,e,t){return[["M",r-t,e],["L",r,e-t],["L",r+t,e],["L",r,e+t],["Z"]]},triangle:function(r,e,t){var n=t*Math.sin(1/3*Math.PI);return[["M",r-t,e+n],["L",r,e-n],["L",r+t,e+n],["z"]]},triangleDown:function(r,e,t){var n=t*Math.sin(1/3*Math.PI);return[["M",r-t,e-n],["L",r+t,e-n],["L",r,e+n],["Z"]]}},_d={get:function(r){return Os[r]},register:function(r,e){Os[r]=e},remove:function(r){delete Os[r]},getAll:function(){return Os}},zS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="marker",t.canFill=!0,t.canStroke=!0,t}return e.prototype.createPath=function(t){var n=this.get("el");n.setAttribute("d",this._assembleMarker())},e.prototype._assembleMarker=function(){var t=this._getPath();return(0,f.kJ)(t)?t.map(function(n){return n.join(" ")}).join(""):t},e.prototype._getPath=function(){var t=this.attr(),n=t.x,i=t.y,a=t.r||t.radius,o=t.symbol||"circle",s;return(0,f.mf)(o)?s=o:s=_d.get(o),s?s(n,i,a):(console.warn(s+" symbol is not exist."),null)},e.symbolsFactory=_d,e}(on),VS=zS,HS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="path",t.canFill=!0,t.canStroke=!0,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{startArrow:!1,endArrow:!1})},e.prototype.createPath=function(t,n){var i=this,a=this.attr(),o=this.get("el");(0,f.S6)(n||a,function(s,l){if(l==="path"&&(0,f.kJ)(s))o.setAttribute("d",i._formatPath(s));else if(l==="startArrow"||l==="endArrow")if(s){var u=(0,f.Kn)(s)?t.addArrow(a,Ze[l]):t.getDefaultArrow(a,Ze[l]);o.setAttribute(Ze[l],"url(#"+u+")")}else o.removeAttribute(Ze[l]);else Ze[l]&&o.setAttribute(Ze[l],s)})},e.prototype._formatPath=function(t){var n=t.map(function(i){return i.join(" ")}).join("");return~n.indexOf("NaN")?"":n},e.prototype.getTotalLength=function(){var t=this.get("el");return t?t.getTotalLength():null},e.prototype.getPoint=function(t){var n=this.get("el"),i=this.getTotalLength();if(i===0)return null;var a=n?n.getPointAtLength(t*i):null;return a?{x:a.x,y:a.y}:null},e}(on),GS=HS,YS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="polygon",t.canFill=!0,t.canStroke=!0,t}return e.prototype.createPath=function(t,n){var i=this.attr(),a=this.get("el");(0,f.S6)(n||i,function(o,s){s==="points"&&(0,f.kJ)(o)&&o.length>=2?a.setAttribute("points",o.map(function(l){return l[0]+","+l[1]}).join(" ")):Ze[s]&&a.setAttribute(Ze[s],o)})},e}(on),XS=YS,WS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="polyline",t.canFill=!0,t.canStroke=!0,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{startArrow:!1,endArrow:!1})},e.prototype.onAttrChange=function(t,n,i){r.prototype.onAttrChange.call(this,t,n,i),["points"].indexOf(t)!==-1&&this._resetCache()},e.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},e.prototype.createPath=function(t,n){var i=this.attr(),a=this.get("el");(0,f.S6)(n||i,function(o,s){s==="points"&&(0,f.kJ)(o)&&o.length>=2?a.setAttribute("points",o.map(function(l){return l[0]+","+l[1]}).join(" ")):Ze[s]&&a.setAttribute(Ze[s],o)})},e.prototype.getTotalLength=function(){var t=this.attr().points,n=this.get("totalLength");return(0,f.UM)(n)?(this.set("totalLength",Pr.aH.length(t)),this.get("totalLength")):n},e.prototype.getPoint=function(t){var n=this.attr().points,i=this.get("tCache");i||(this._setTcache(),i=this.get("tCache"));var a,o;return(0,f.S6)(i,function(s,l){t>=s[0]&&t<=s[1]&&(a=(t-s[0])/(s[1]-s[0]),o=l)}),Pr.x1.pointAt(n[o][0],n[o][1],n[o+1][0],n[o+1][1],a)},e.prototype._setTcache=function(){var t=this.attr().points;if(!(!t||t.length===0)){var n=this.getTotalLength();if(!(n<=0)){var i=0,a=[],o,s;(0,f.S6)(t,function(l,u){t[u+1]&&(o=[],o[0]=i/n,s=Pr.x1.length(l[0],l[1],t[u+1][0],t[u+1][1]),i+=s,o[1]=i/n,a.push(o))}),this.set("tCache",a)}}},e.prototype.getStartTangent=function(){var t=this.attr().points,n=[];return n.push([t[1][0],t[1][1]]),n.push([t[0][0],t[0][1]]),n},e.prototype.getEndTangent=function(){var t=this.attr().points,n=t.length-1,i=[];return i.push([t[n-1][0],t[n-1][1]]),i.push([t[n][0],t[n][1]]),i},e}(on),ZS=WS,$S=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/gi,qS=/[^\s,]+/gi;function KS(r){var e=0,t=0,n=0,i=0;return(0,f.kJ)(r)?r.length===1?e=t=n=i=r[0]:r.length===2?(e=n=r[0],t=i=r[1]):r.length===3?(e=r[0],t=i=r[1],n=r[2]):(e=r[0],t=r[1],n=r[2],i=r[3]):e=t=n=i=r,{r1:e,r2:t,r3:n,r4:i}}function j6(r){if(r=r||[],isArray(r))return r;if(isString(r))return r=r.match($S),each(r,function(e,t){if(e=e.match(qS),e[0].length>1){var n=e[0].charAt(0);e.splice(1,0,e[0].substr(1)),e[0]=n}each(e,function(i,a){isNaN(i)||(e[a]=+i)}),r[t]=e}),r}var jS=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="rect",t.canFill=!0,t.canStroke=!0,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,width:0,height:0,radius:0})},e.prototype.createPath=function(t,n){var i=this,a=this.attr(),o=this.get("el"),s=!1,l=["x","y","width","height","radius"];(0,f.S6)(n||a,function(u,c){l.indexOf(c)!==-1&&!s?(o.setAttribute("d",i._assembleRect(a)),s=!0):l.indexOf(c)===-1&&Ze[c]&&o.setAttribute(Ze[c],u)})},e.prototype._assembleRect=function(t){var n=t.x,i=t.y,a=t.width,o=t.height,s=t.radius;if(!s)return"M "+n+","+i+" l "+a+",0 l 0,"+o+" l"+-a+" 0 z";var l=KS(s);(0,f.kJ)(s)?s.length===1?l.r1=l.r2=l.r3=l.r4=s[0]:s.length===2?(l.r1=l.r3=s[0],l.r2=l.r4=s[1]):s.length===3?(l.r1=s[0],l.r2=l.r4=s[1],l.r3=s[2]):(l.r1=s[0],l.r2=s[1],l.r3=s[2],l.r4=s[3]):l.r1=l.r2=l.r3=l.r4=s;var u=[["M "+(n+l.r1)+","+i],["l "+(a-l.r1-l.r2)+",0"],["a "+l.r2+","+l.r2+",0,0,1,"+l.r2+","+l.r2],["l 0,"+(o-l.r2-l.r3)],["a "+l.r3+","+l.r3+",0,0,1,"+-l.r3+","+l.r3],["l "+(l.r3+l.r4-a)+",0"],["a "+l.r4+","+l.r4+",0,0,1,"+-l.r4+","+-l.r4],["l 0,"+(l.r4+l.r1-o)],["a "+l.r1+","+l.r1+",0,0,1,"+l.r1+","+-l.r1],["z"]];return u.join(" ")},e}(on),JS=jS,QS=N(43631),Fd=.3,tC={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"baseline",hanging:"hanging"},eC={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",hanging:"hanging"},rC={left:"left",start:"left",center:"middle",right:"end",end:"end"},nC=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="text",t.canFill=!0,t.canStroke=!0,t}return e.prototype.getDefaultAttrs=function(){var t=r.prototype.getDefaultAttrs.call(this);return(0,p.pi)((0,p.pi)({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},e.prototype.createPath=function(t,n){var i=this,a=this.attr(),o=this.get("el");this._setFont(),(0,f.S6)(n||a,function(s,l){l==="text"?i._setText(""+s):l==="matrix"&&s?uo(i):Ze[l]&&o.setAttribute(Ze[l],s)}),o.setAttribute("paint-order","stroke"),o.setAttribute("style","stroke-linecap:butt; stroke-linejoin:miter;")},e.prototype._setFont=function(){var t=this.get("el"),n=this.attr(),i=n.textBaseline,a=n.textAlign,o=(0,QS.qY)();o&&o.name==="firefox"?t.setAttribute("dominant-baseline",eC[i]||"alphabetic"):t.setAttribute("alignment-baseline",tC[i]||"baseline"),t.setAttribute("text-anchor",rC[a]||"left")},e.prototype._setText=function(t){var n=this.get("el"),i=this.attr(),a=i.x,o=i.textBaseline,s=o===void 0?"bottom":o;if(!t)n.innerHTML="";else if(~t.indexOf(`
  45. `)){var l=t.split(`
  46. `),u=l.length-1,c="";(0,f.S6)(l,function(h,v){v===0?s==="alphabetic"?c+='<tspan x="'+a+'" dy="'+-u+'em">'+h+"</tspan>":s==="top"?c+='<tspan x="'+a+'" dy="0.9em">'+h+"</tspan>":s==="middle"?c+='<tspan x="'+a+'" dy="'+-(u-1)/2+'em">'+h+"</tspan>":s==="bottom"?c+='<tspan x="'+a+'" dy="-'+(u+Fd)+'em">'+h+"</tspan>":s==="hanging"&&(c+='<tspan x="'+a+'" dy="'+(-(u-1)-Fd)+'em">'+h+"</tspan>"):c+='<tspan x="'+a+'" dy="1em">'+h+"</tspan>"}),n.innerHTML=c}else n.innerHTML=t},e}(on),iC=nC,aC=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,oC=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,sC=/[\d.]+:(#[^\s]+|[^)]+\))/gi;function Id(r){var e=r.match(sC);if(!e)return"";var t="";return e.sort(function(n,i){return n=n.split(":"),i=i.split(":"),Number(n[0])-Number(i[0])}),(0,f.S6)(e,function(n){n=n.split(":"),t+='<stop offset="'+n[0]+'" stop-color="'+n[1]+'"></stop>'}),t}function lC(r,e){var t=aC.exec(r),n=(0,f.wQ)((0,f.c$)(parseFloat(t[1])),Math.PI*2),i=t[2],a,o;n>=0&&n<.5*Math.PI?(a={x:0,y:0},o={x:1,y:1}):.5*Math.PI<=n&&n<Math.PI?(a={x:1,y:0},o={x:0,y:1}):Math.PI<=n&&n<1.5*Math.PI?(a={x:1,y:1},o={x:0,y:0}):(a={x:0,y:1},o={x:1,y:0});var s=Math.tan(n),l=s*s,u=(o.x-a.x+s*(o.y-a.y))/(l+1)+a.x,c=s*(o.x-a.x+s*(o.y-a.y))/(l+1)+a.y;e.setAttribute("x1",a.x),e.setAttribute("y1",a.y),e.setAttribute("x2",u),e.setAttribute("y2",c),e.innerHTML=Id(i)}function uC(r,e){var t=oC.exec(r),n=parseFloat(t[1]),i=parseFloat(t[2]),a=parseFloat(t[3]),o=t[4];e.setAttribute("cx",n),e.setAttribute("cy",i),e.setAttribute("r",a),e.innerHTML=Id(o)}var cC=function(){function r(e){this.cfg={};var t=null,n=(0,f.EL)("gradient_");return e.toLowerCase()[0]==="l"?(t=an("linearGradient"),lC(e,t)):(t=an("radialGradient"),uC(e,t)),t.setAttribute("id",n),this.el=t,this.id=n,this.cfg=e,this}return r.prototype.match=function(e,t){return this.cfg===t},r}(),fC=cC,hC={shadowColor:"color",shadowOpacity:"opacity",shadowBlur:"blur",shadowOffsetX:"dx",shadowOffsetY:"dy"},vC={x:"-40%",y:"-40%",width:"200%",height:"200%"},dC=function(){function r(e){this.type="filter",this.cfg={},this.type="filter";var t=an("filter");return(0,f.S6)(vC,function(n,i){t.setAttribute(i,n)}),this.el=t,this.id=(0,f.EL)("filter_"),this.el.id=this.id,this.cfg=e,this._parseShadow(e,t),this}return r.prototype.match=function(e,t){if(this.type!==e)return!1;var n=!0,i=this.cfg;return(0,f.S6)(Object.keys(i),function(a){if(i[a]!==t[a])return n=!1,!1}),n},r.prototype.update=function(e,t){var n=this.cfg;return n[hC[e]]=t,this._parseShadow(n,this.el),this},r.prototype._parseShadow=function(e,t){var n=`<feDropShadow
  47. dx="`+(e.dx||0)+`"
  48. dy="`+(e.dy||0)+`"
  49. stdDeviation="`+(e.blur?e.blur/10:0)+`"
  50. flood-color="`+(e.color?e.color:"#000")+`"
  51. flood-opacity="`+(e.opacity?e.opacity:1)+`"
  52. />`;t.innerHTML=n},r}(),pC=dC,gC=function(){function r(e,t){this.cfg={};var n=an("marker"),i=(0,f.EL)("marker_");n.setAttribute("id",i);var a=an("path");a.setAttribute("stroke",e.stroke||"none"),a.setAttribute("fill",e.fill||"none"),n.appendChild(a),n.setAttribute("overflow","visible"),n.setAttribute("orient","auto-start-reverse"),this.el=n,this.child=a,this.id=i;var o=e[t==="marker-start"?"startArrow":"endArrow"];return this.stroke=e.stroke||"#000",o===!0?this._setDefaultPath(t,a):(this.cfg=o,this._setMarker(e.lineWidth,a)),this}return r.prototype.match=function(){return!1},r.prototype._setDefaultPath=function(e,t){var n=this.el;t.setAttribute("d","M0,0 L"+10*Math.cos(Math.PI/6)+",5 L0,10"),n.setAttribute("refX",""+10*Math.cos(Math.PI/6)),n.setAttribute("refY",""+5)},r.prototype._setMarker=function(e,t){var n=this.el,i=this.cfg.path,a=this.cfg.d;(0,f.kJ)(i)&&(i=i.map(function(o){return o.join(" ")}).join("")),t.setAttribute("d",i),n.appendChild(t),a&&n.setAttribute("refX",""+a/e)},r.prototype.update=function(e){var t=this.child;t.attr?t.attr("fill",e):t.setAttribute("fill",e)},r}(),Pd=gC,yC=function(){function r(e){this.type="clip",this.cfg={};var t=an("clipPath");this.el=t,this.id=(0,f.EL)("clip_"),t.id=this.id;var n=e.cfg.el;return t.appendChild(n),this.cfg=e,this}return r.prototype.match=function(){return!1},r.prototype.remove=function(){var e=this.el;e.parentNode.removeChild(e)},r}(),mC=yC,xC=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,MC=function(){function r(e){this.cfg={};var t=an("pattern");t.setAttribute("patternUnits","userSpaceOnUse");var n=an("image");t.appendChild(n);var i=(0,f.EL)("pattern_");t.id=i,this.el=t,this.id=i,this.cfg=e;var a=xC.exec(e),o=a[2];n.setAttribute("href",o);var s=new Image;o.match(/^data:/i)||(s.crossOrigin="Anonymous"),s.src=o;function l(){t.setAttribute("width",""+s.width),t.setAttribute("height",""+s.height)}return s.complete?l():(s.onload=l,s.src=s.src),this}return r.prototype.match=function(e,t){return this.cfg===t},r}(),wC=MC,SC=function(){function r(e){var t=an("defs"),n=(0,f.EL)("defs_");t.id=n,e.appendChild(t),this.children=[],this.defaultArrow={},this.el=t,this.canvas=e}return r.prototype.find=function(e,t){for(var n=this.children,i=null,a=0;a<n.length;a++)if(n[a].match(e,t)){i=n[a].id;break}return i},r.prototype.findById=function(e){for(var t=this.children,n=null,i=0;i<t.length;i++)if(t[i].id===e){n=t[i];break}return n},r.prototype.add=function(e){this.children.push(e),e.canvas=this.canvas,e.parent=this},r.prototype.getDefaultArrow=function(e,t){var n=e.stroke||e.strokeStyle;if(this.defaultArrow[n])return this.defaultArrow[n].id;var i=new Pd(e,t);return this.defaultArrow[n]=i,this.el.appendChild(i.el),this.add(i),i.id},r.prototype.addGradient=function(e){var t=new fC(e);return this.el.appendChild(t.el),this.add(t),t.id},r.prototype.addArrow=function(e,t){var n=new Pd(e,t);return this.el.appendChild(n.el),this.add(n),n.id},r.prototype.addShadow=function(e){var t=new pC(e);return this.el.appendChild(t.el),this.add(t),t.id},r.prototype.addPattern=function(e){var t=new wC(e);return this.el.appendChild(t.el),this.add(t),t.id},r.prototype.addClip=function(e){var t=new mC(e);return this.el.appendChild(t.el),this.add(t),t.id},r}(),CC=SC,AC=function(r){(0,p.ZT)(e,r);function e(t){return r.call(this,(0,p.pi)((0,p.pi)({},t),{autoDraw:!0,renderer:"svg"}))||this}return e.prototype.getShapeBase=function(){return Ft},e.prototype.getGroupBase=function(){return rc},e.prototype.getShape=function(t,n,i){var a=i.target||i.srcElement;if(!ec[a.tagName]){for(var o=a.parentNode;o&&!ec[o.tagName];)o=o.parentNode;a=o}return this.find(function(s){return s.get("el")===a})},e.prototype.createDom=function(){var t=an("svg"),n=new CC(t);return t.setAttribute("width",""+this.get("width")),t.setAttribute("height",""+this.get("height")),this.set("context",n),t},e.prototype.onCanvasChange=function(t){var n=this.get("context"),i=this.get("el");if(t==="sort"){var a=this.get("children");a&&a.length&&bd(this,function(s,l){return a.indexOf(s)-a.indexOf(l)?1:0})}else if(t==="clear"){if(i){i.innerHTML="";var o=n.el;o.innerHTML="",i.appendChild(o)}}else t==="matrix"?uo(this):t==="clip"?co(this,n):t==="changeSize"&&(i.setAttribute("width",""+this.get("width")),i.setAttribute("height",""+this.get("height")))},e.prototype.draw=function(){var t=this.get("context"),n=this.getChildren();co(this,t),n.length&&Td(t,n)},e}(F.AbstractCanvas),bC=AC,TC="0.5.6",EC=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.type="path",n.shapeType="line";var i=t.connectNulls,a=i===void 0?!1:i,o=t.showSinglePoint,s=o===void 0?!0:o;return n.connectNulls=a,n.showSinglePoint=s,n}return e.prototype.updateElements=function(t,n){var i,a,o,s,l,u;n===void 0&&(n=!1);for(var c=new Map,h=new Map,v=[],d=0,g=0;g<t.length;g++){var y=t[g],x=this.getElementId(y);v.push(x),c.set(x,y),h.set(x,d),d++}this.elements=new Array(d);var m=kv(this.lastElementsMap,v),M=m.added,w=m.updated,S=m.removed;try{for(var b=(0,p.XA)(M),k=b.next();!k.done;k=b.next()){var x=k.value,y=c.get(x),H=this.getShapeFactory(),at=this.getShapeInfo(y),g=h.get(x),At=new Iv({shapeFactory:H,container:this.container,offscreenGroup:this.getOffscreenGroup(),elementIndex:g});At.geometry=this,At.animate=this.animateOption,At.draw(at,n),this.elementsMap[x]=At,this.elements[g]=At}}catch(be){i={error:be}}finally{try{k&&!k.done&&(a=b.return)&&a.call(b)}finally{if(i)throw i.error}}try{for(var gt=(0,p.XA)(w),Nt=gt.next();!Nt.done;Nt=gt.next()){var x=Nt.value,y=c.get(x),At=this.lastElementsMap[x],g=h.get(x),at=this.getShapeInfo(y),te=At.getModel();(this.isCoordinateChanged||Ov(te,at))&&(At.animate=this.animateOption,At.update(at)),this.elementsMap[x]=At,this.elements[g]=At}}catch(be){o={error:be}}finally{try{Nt&&!Nt.done&&(s=gt.return)&&s.call(gt)}finally{if(o)throw o.error}}try{for(var ce=(0,p.XA)(S),Me=ce.next();!Me.done;Me=ce.next()){var x=Me.value,At=this.lastElementsMap[x];At.animate=this.animateOption,At.destroy()}}catch(be){l={error:be}}finally{try{Me&&!Me.done&&(u=ce.return)&&u.call(ce)}finally{if(l)throw l.error}}},e.prototype.getPointsAndData=function(t){for(var n=[],i=[],a=0,o=t.length;a<o;a++){var s=t[a];n.push({x:s.x,y:s.y}),i.push(s[ee])}return{points:n,data:i}},e.prototype.getShapeInfo=function(t){var n=this.getDrawCfg(t[0]),i=this.getPointsAndData(t),a=i.points,o=i.data;return n.mappingData=t,n.data=o,n.isStack=!!this.getAdjust("stack"),n.points=a,n.connectNulls=this.connectNulls,n.showSinglePoint=this.showSinglePoint,n},e}(ii),nc=EC;function _C(r,e,t,n,i){var a=[];if(r.length){for(var o=[],s=[],l=0,u=r.length;l<u;l++){var c=r[l];o.push(c[1]),s.push(c[0])}s=s.reverse(),(0,f.S6)([o,s],function(h,v){var d=[],g=n.parsePoints(h),y=g[0];o.length===1&&s.length===1?d=v===0?[["M",y.x-.5,y.y],["L",y.x+.5,y.y]]:[["L",y.x+.5,y.y],["L",y.x-.5,y.y]]:(e&&g.push({x:y.x,y:y.y}),t?d=gs(g,!1,i):d=Ka(g,!1),v>0&&(d[0][0]="L")),a=a.concat(d)}),a.push(["Z"])}return a}function ks(r,e,t,n,i){for(var a=fr(r,e,!e,"lineWidth"),o=r.connectNulls,s=r.isInCircle,l=r.points,u=r.showSinglePoint,c=bs(l,o,u),h=[],v=0,d=c.length;v<d;v++){var g=c[v];h=h.concat(_C(g,s,t,n,i))}return a.path=h,a}function Ld(r){var e=r.start,t=r.end;return[[e.x,t.y],[t.x,e.y]]}var J6=ni("area",{defaultShapeType:"area",getDefaultPoints:function(r){var e=r.x,t=r.y0,n=(0,f.kJ)(r.y)?r.y:[t,r.y];return n.map(function(i){return{x:e,y:i}})}});Ke("area","area",{draw:function(r,e){var t=ks(r,!1,!1,this),n=e.addShape({type:"path",attrs:t,name:"area"});return n},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){return i===void 0&&(i=5.5),[["M",t-i,n-4],["L",t+i,n-4],["L",t+i,n+4],["L",t-i,n+4],["Z"]]},style:{r:5,fill:e,fillOpacity:1}}}});var Q6=null,FC=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.type="area",n.shapeType="area",n.generatePoints=!0,n.startOnZero=!0;var i=t.startOnZero,a=i===void 0?!0:i,o=t.sortable,s=o===void 0?!1:o,l=t.showSinglePoint,u=l===void 0?!1:l;return n.startOnZero=a,n.sortable=s,n.showSinglePoint=u,n}return e.prototype.getPointsAndData=function(t){for(var n=[],i=[],a=0,o=t.length;a<o;a++){var s=t[a];n.push(s.points),i.push(s[ee])}return{points:n,data:i}},e.prototype.getYMinValue=function(){if(this.startOnZero)return r.prototype.getYMinValue.call(this);var t=this.getYScale();return t.min},e}(nc),IC=FC,t5=ni("edge",{defaultShapeType:"line",getDefaultPoints:function(r){return Uu(r)}});Ke("edge","line",{draw:function(r,e){var t=fr(r,!0,!1,"lineWidth"),n=Ka(this.parsePoints(r.points),this.coordinate.isPolar);return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n})})},getMarker:function(r){return{symbol:"circle",style:{r:4.5,fill:r.color}}}});var e5=null,PC=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="edge",t.shapeType="edge",t.generatePoints=!0,t}return e}(ii),LC=PC,DC=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="heatmap",t.paletteCache={},t}return e.prototype.updateElements=function(t,n){n===void 0&&(n=!1);for(var i=0;i<t.length;i++){var a=t[i],o=this.prepareRange(a),s=this.prepareSize(),l=(0,f.U2)(this.styleOption,["cfg","shadowBlur"]);(0,f.hj)(l)||(l=s/2),this.prepareGreyScaleBlurredCircle(s,l),this.drawWithRange(a,o,s,l)}},e.prototype.color=function(t,n){return this.createAttrOption("color",t,typeof n!="function"?n:""),this},e.prototype.clear=function(){r.prototype.clear.call(this),this.clearShadowCanvasCtx(),this.paletteCache={}},e.prototype.prepareRange=function(t){var n=this.getAttribute("color"),i=n.getFields()[0],a=Infinity,o=-Infinity;return t.forEach(function(s){var l=s[ee][i];l>o&&(o=l),l<a&&(a=l)}),a===o&&(a=o-1),[a,o]},e.prototype.prepareSize=function(){var t=this.getDefaultValue("size");return(0,f.hj)(t)||(t=this.getDefaultSize()),t},e.prototype.prepareGreyScaleBlurredCircle=function(t,n){var i=this.getGrayScaleBlurredCanvas(),a=t+n,o=i.getContext("2d");i.width=i.height=a*2,o.clearRect(0,0,i.width,i.height),o.shadowOffsetX=o.shadowOffsetY=a*2,o.shadowBlur=n,o.shadowColor="black",o.beginPath(),o.arc(-a,-a,t,0,Math.PI*2,!0),o.closePath(),o.fill()},e.prototype.drawWithRange=function(t,n,i,a){var o,s,l=this.coordinate,u=l.start,c=l.end,h=this.coordinate.getWidth(),v=this.coordinate.getHeight(),d=this.getAttribute("color"),g=d.getFields()[0];this.clearShadowCanvasCtx();var y=this.getShadowCanvasCtx();n&&(t=t.filter(function(gt){return gt[ee][g]<=n[1]&&gt[ee][g]>=n[0]}));var x=this.scales[g];try{for(var m=(0,p.XA)(t),M=m.next();!M.done;M=m.next()){var w=M.value,S=this.getDrawCfg(w),b=S.x,k=S.y,H=x.scale(w[ee][g]);this.drawGrayScaleBlurredCircle(b-u.x,k-c.y,i+a,H,y)}}catch(gt){o={error:gt}}finally{try{M&&!M.done&&(s=m.return)&&s.call(m)}finally{if(o)throw o.error}}var at=y.getImageData(0,0,h,v);this.clearShadowCanvasCtx(),this.colorize(at),y.putImageData(at,0,0);var At=this.getImageShape();At.attr("x",u.x),At.attr("y",c.y),At.attr("width",h),At.attr("height",v),At.attr("img",y.canvas),At.set("origin",this.getShapeInfo(t))},e.prototype.getDefaultSize=function(){var t=this.getAttribute("position"),n=this.coordinate;return Math.min(n.getWidth()/(t.scales[0].ticks.length*4),n.getHeight()/(t.scales[1].ticks.length*4))},e.prototype.clearShadowCanvasCtx=function(){var t=this.getShadowCanvasCtx();t.clearRect(0,0,t.canvas.width,t.canvas.height)},e.prototype.getShadowCanvasCtx=function(){var t=this.shadowCanvas;return t||(t=document.createElement("canvas"),this.shadowCanvas=t),t.width=this.coordinate.getWidth(),t.height=this.coordinate.getHeight(),t.getContext("2d")},e.prototype.getGrayScaleBlurredCanvas=function(){return this.grayScaleBlurredCanvas||(this.grayScaleBlurredCanvas=document.createElement("canvas")),this.grayScaleBlurredCanvas},e.prototype.drawGrayScaleBlurredCircle=function(t,n,i,a,o){var s=this.getGrayScaleBlurredCanvas();o.globalAlpha=a,o.drawImage(s,t-i,n-i)},e.prototype.colorize=function(t){for(var n=this.getAttribute("color"),i=t.data,a=this.paletteCache,o=3;o<i.length;o+=4){var s=i[o];if((0,f.hj)(s)){var l=a[s]?a[s]:nn.rgb2arr(n.gradient(s/256));i[o-3]=l[0],i[o-2]=l[1],i[o-1]=l[2],i[o]=s}}},e.prototype.getImageShape=function(){var t=this.imageShape;if(t)return t;var n=this.container;return t=n.addShape({type:"image",attrs:{}}),this.imageShape=t,t},e.prototype.getShapeInfo=function(t){var n=this.getDrawCfg(t[0]),i=t.map(function(a){return a[ee]});return(0,p.pi)((0,p.pi)({},n),{mappingData:t,data:i})},e}(ii),OC=DC;function ic(r){var e,t,n=r.x,i=r.y,a=r.y0,o=r.size,s,l;(0,f.kJ)(i)?(e=(0,p.CR)(i,2),s=e[0],l=e[1]):(s=a,l=i);var u,c;(0,f.kJ)(n)?(t=(0,p.CR)(n,2),u=t[0],c=t[1]):(u=n-o/2,c=n+o/2);var h=[{x:u,y:s},{x:u,y:l}];return h.push({x:c,y:l},{x:c,y:s}),h}function ac(r,e){e===void 0&&(e=!0);var t=[],n=r[0];t.push(["M",n.x,n.y]);for(var i=1,a=r.length;i<a;i++)t.push(["L",r[i].x,r[i].y]);return e&&(t.push(["L",n.x,n.y]),t.push(["z"])),t}function Dd(r,e){var t=0,n=0,i=0,a=0;return(0,f.kJ)(r)?r.length===1?t=n=i=a=r[0]:r.length===2?(t=i=r[0],n=a=r[1]):r.length===3?(t=r[0],n=a=r[1],i=r[2]):(t=r[0],n=r[1],i=r[2],a=r[3]):t=n=i=a=r,t+n>e&&(t=t?e/(1+n/t):0,n=e-t),i+a>e&&(i=i?e/(1+a/i):0,a=e-i),[t||0,n||0,i||0,a||0]}function Od(r,e,t){var n=[];if(t.isRect){var i=t.isTransposed?{x:t.start.x,y:e[0].y}:{x:e[0].x,y:t.start.y},a=t.isTransposed?{x:t.end.x,y:e[2].y}:{x:e[3].x,y:t.end.y},o=(0,f.U2)(r,["background","style","radius"]);if(o){var s=t.isTransposed?Math.abs(e[0].y-e[2].y):e[2].x-e[1].x,l=t.isTransposed?t.getWidth():t.getHeight(),u=(0,p.CR)(Dd(o,Math.min(s,l)),4),c=u[0],h=u[1],v=u[2],d=u[3],g=t.isTransposed&&t.isReflect("y"),y=g?0:1,x=function(k){return g?-k:k};n.push(["M",i.x,a.y+x(c)]),c!==0&&n.push(["A",c,c,0,0,y,i.x+c,a.y]),n.push(["L",a.x-h,a.y]),h!==0&&n.push(["A",h,h,0,0,y,a.x,a.y+x(h)]),n.push(["L",a.x,i.y-x(v)]),v!==0&&n.push(["A",v,v,0,0,y,a.x-v,i.y]),n.push(["L",i.x+d,i.y]),d!==0&&n.push(["A",d,d,0,0,y,i.x,i.y-x(d)])}else n.push(["M",i.x,i.y]),n.push(["L",a.x,i.y]),n.push(["L",a.x,a.y]),n.push(["L",i.x,a.y]),n.push(["L",i.x,i.y]);n.push(["z"])}if(t.isPolar){var m=t.getCenter(),M=Za(r,t),w=M.startAngle,S=M.endAngle;if(t.type!=="theta"&&!t.isTransposed)n=Qn(m.x,m.y,t.getRadius(),w,S);else{var b=function(at){return Math.pow(at,2)},c=Math.sqrt(b(m.x-e[0].x)+b(m.y-e[0].y)),h=Math.sqrt(b(m.x-e[2].x)+b(m.y-e[2].y));n=Qn(m.x,m.y,c,t.startAngle,t.endAngle,h)}}return n}function kC(r,e,t){var n=t.getWidth(),i=t.getHeight(),a=t.type==="rect",o=[],s=(r[2].x-r[1].x)/2,l=t.isTransposed?s*i/n:s*n/i;return e==="round"?(a?(o.push(["M",r[0].x,r[0].y+l]),o.push(["L",r[1].x,r[1].y-l]),o.push(["A",s,s,0,0,1,r[2].x,r[2].y-l]),o.push(["L",r[3].x,r[3].y+l]),o.push(["A",s,s,0,0,1,r[0].x,r[0].y+l])):(o.push(["M",r[0].x,r[0].y]),o.push(["L",r[1].x,r[1].y]),o.push(["A",s,s,0,0,1,r[2].x,r[2].y]),o.push(["L",r[3].x,r[3].y]),o.push(["A",s,s,0,0,1,r[0].x,r[0].y])),o.push(["z"])):o=ac(r),o}function kd(r,e,t){var n=[];return(0,f.UM)(e)?t?n.push(["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],["L",(r[2].x+r[3].x)/2,(r[2].y+r[3].y)/2],["Z"]):n.push(["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],["L",r[2].x,r[2].y],["L",r[3].x,r[3].y],["Z"]):n.push(["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],["L",e[1].x,e[1].y],["L",e[0].x,e[0].y],["Z"]),n}function fo(r,e){return[e,r]}function BC(r,e,t){var n,i,a,o,s,l,u,c=(0,p.CR)((0,p.ev)([],(0,p.CR)(r),!1),4),h=c[0],v=c[1],d=c[2],g=c[3],y=(0,p.CR)(typeof t=="number"?Array(4).fill(t):t,4),x=y[0],m=y[1],M=y[2],w=y[3];e.isTransposed&&(n=(0,p.CR)(fo(v,g),2),v=n[0],g=n[1]),e.isReflect("y")&&(i=(0,p.CR)(fo(h,v),2),h=i[0],v=i[1],a=(0,p.CR)(fo(d,g),2),d=a[0],g=a[1]),e.isReflect("x")&&(o=(0,p.CR)(fo(h,g),2),h=o[0],g=o[1],s=(0,p.CR)(fo(v,d),2),v=s[0],d=s[1]);var S=[],b=function(k){return Math.abs(k)};return l=(0,p.CR)(Dd([x,m,M,w],Math.min(b(g.x-h.x),b(v.y-h.y))).map(function(k){return b(k)}),4),x=l[0],m=l[1],M=l[2],w=l[3],e.isTransposed&&(u=(0,p.CR)([w,x,m,M],4),x=u[0],m=u[1],M=u[2],w=u[3]),h.y<v.y?(S.push(["M",g.x,g.y+M]),M!==0&&S.push(["A",M,M,0,0,0,g.x-M,g.y]),S.push(["L",h.x+w,h.y]),w!==0&&S.push(["A",w,w,0,0,0,h.x,h.y+w]),S.push(["L",v.x,v.y-x]),x!==0&&S.push(["A",x,x,0,0,0,v.x+x,v.y]),S.push(["L",d.x-m,d.y]),m!==0&&S.push(["A",m,m,0,0,0,d.x,d.y-m]),S.push(["L",g.x,g.y+M]),S.push(["z"])):g.x<h.x?(S.push(["M",d.x+m,d.y]),m!==0&&S.push(["A",m,m,0,0,0,d.x,d.y+m]),S.push(["L",g.x,g.y-M]),M!==0&&S.push(["A",M,M,0,0,0,g.x+M,g.y]),S.push(["L",h.x-w,h.y]),w!==0&&S.push(["A",w,w,0,0,0,h.x,h.y-w]),S.push(["L",v.x,v.y+x]),x!==0&&S.push(["A",x,x,0,0,0,v.x-x,v.y]),S.push(["L",d.x+m,d.y]),S.push(["z"])):(S.push(["M",v.x,v.y+x]),x!==0&&S.push(["A",x,x,0,0,1,v.x+x,v.y]),S.push(["L",d.x-m,d.y]),m!==0&&S.push(["A",m,m,0,0,1,d.x,d.y+m]),S.push(["L",g.x,g.y-M]),M!==0&&S.push(["A",M,M,0,0,1,g.x-M,g.y]),S.push(["L",h.x+w,h.y]),w!==0&&S.push(["A",w,w,0,0,1,h.x,h.y-w]),S.push(["L",v.x,v.y+x]),S.push(["z"])),S}var r5=ni("interval",{defaultShapeType:"rect",getDefaultPoints:function(r){return ic(r)}});Ke("interval","rect",{draw:function(r,e){var t=fr(r,!1,!0),n=e,i=r==null?void 0:r.background;if(i){n=e.addGroup({name:"interval-group"});var a=Xv(r),o=Od(r,this.parsePoints(r.points),this.coordinate);n.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},a),{path:o}),capture:!1,zIndex:-1,name:Du})}var s;t.radius&&this.coordinate.isRect?s=BC(this.parsePoints(r.points),this.coordinate,t.radius):s=this.parsePath(kC(r.points,t.lineCap,this.coordinate));var l=n.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:s}),name:"interval"});return i?n:l},getMarker:function(r){var e=r.color,t=r.isInPolar;return t?{symbol:"circle",style:{r:4.5,fill:e}}:{symbol:"square",style:{r:4,fill:e}}}});var n5=null;function RC(r,e){var t=r.length,n=r;(0,f.HD)(n[0])&&(n=r.map(function(s){return e.translate(s)}));for(var i=n[1]-n[0],a=2;a<t;a++){var o=n[a]-n[a-1];i>o&&(i=o)}return i}function NC(r,e){if(e){var t=(0,f.xH)(r),n=(0,f.I)(t,e);return n.length}return r.length}function oc(r){var e=r.theme,t=r.coordinate,n=r.getXScale(),i=n.values,a=r.beforeMappingData,o=i.length,s=$a(r.coordinate),l=r.intervalPadding,u=r.dodgePadding,c=r.maxColumnWidth||e.maxColumnWidth,h=r.minColumnWidth||e.minColumnWidth,v=r.columnWidthRatio||e.columnWidthRatio,d=r.multiplePieWidthRatio||e.multiplePieWidthRatio,g=r.roseWidthRatio||e.roseWidthRatio;if(n.isLinear&&i.length>1){i.sort();var y=RC(i,n);o=(n.max-n.min)/y,i.length>o&&(o=i.length)}var x=n.range,m=1/o,M=1;if(t.isPolar?t.isTransposed&&o>1?M=d:M=g:(n.isLinear&&(m*=x[1]-x[0]),M=v),!(0,f.UM)(l)&&l>=0){var w=l/s;m=(1-(o-1)*w)/o}else m*=M;if(r.getAdjust("dodge")){var S=r.getAdjust("dodge"),b=S.dodgeBy,k=NC(a,b);if(!(0,f.UM)(u)&&u>=0){var H=u/s;m=(m-H*(k-1))/k}else!(0,f.UM)(l)&&l>=0&&(m*=M),m=m/k;m=m>=0?m:0}if(!(0,f.UM)(c)&&c>=0){var at=c/s;m>at&&(m=at)}if(!(0,f.UM)(h)&&h>=0){var At=h/s;m<At&&(m=At)}return m}var UC=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.type="interval",n.shapeType="interval",n.generatePoints=!0;var i=t.background;return n.background=i,n}return e.prototype.createShapePointsCfg=function(t){var n=r.prototype.createShapePointsCfg.call(this,t),i,a=this.getAttribute("size");if(a){i=this.getAttributeValues(a,t)[0];var o=this.coordinate,s=$a(o);i=i/s}else this.defaultSize||(this.defaultSize=oc(this)),i=this.defaultSize;return n.size=i,n},e.prototype.adjustScale=function(){r.prototype.adjustScale.call(this);var t=this.getYScale();if(this.coordinate.type==="theta")t.change({nice:!1,min:0,max:aM(t)});else{var n=this.scaleDefs,i=t.field,a=t.min,o=t.max,s=t.type;s!=="time"&&(a>0&&!(0,f.U2)(n,[i,"min"])&&t.change({min:0}),o<=0&&!(0,f.U2)(n,[i,"max"])&&t.change({max:0}))}},e.prototype.getDrawCfg=function(t){var n=r.prototype.getDrawCfg.call(this,t);return n.background=this.background,n},e}(ii),zC=UC,VC=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;n.type="line";var i=t.sortable,a=i===void 0?!1:i;return n.sortable=a,n}return e}(nc),HC=VC,Bd=["circle","square","bowtie","diamond","hexagon","triangle","triangle-down"],GC=["cross","tick","plus","hyphen","line"];function sc(r,e,t,n,i){var a,o,s=fr(e,i,!i,"r"),l=r.parsePoints(e.points),u=l[0];if(e.isStack)u=l[1];else if(l.length>1){var c=t.addGroup();try{for(var h=(0,p.XA)(l),v=h.next();!v.done;v=h.next()){var d=v.value;c.addShape({type:"marker",attrs:(0,p.pi)((0,p.pi)((0,p.pi)({},s),{symbol:_i[n]||n}),d)})}}catch(g){a={error:g}}finally{try{v&&!v.done&&(o=h.return)&&o.call(h)}finally{if(a)throw a.error}}return c}return t.addShape({type:"marker",attrs:(0,p.pi)((0,p.pi)((0,p.pi)({},s),{symbol:_i[n]||n}),u)})}var i5=ni("point",{defaultShapeType:"hollow-circle",getDefaultPoints:function(r){return Uu(r)}});(0,f.S6)(Bd,function(r){Ke("point","hollow-".concat(r),{draw:function(e,t){return sc(this,e,t,r,!0)},getMarker:function(e){var t=e.color;return{symbol:_i[r]||r,style:{r:4.5,stroke:t,fill:null}}}})});var a5=null,YC=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="point",t.shapeType="point",t.generatePoints=!0,t}return e.prototype.getDrawCfg=function(t){var n=r.prototype.getDrawCfg.call(this,t);return(0,p.pi)((0,p.pi)({},n),{isStack:!!this.getAdjust("stack")})},e}(ii),XC=YC;function WC(r){for(var e=r[0],t=1,n=[["M",e.x,e.y]];t<r.length;){var i=r[t];(i.x!==r[t-1].x||i.y!==r[t-1].y)&&(n.push(["L",i.x,i.y]),i.x===e.x&&i.y===e.y&&t<r.length-1&&(e=r[t+1],n.push(["Z"]),n.push(["M",e.x,e.y]),t++)),t++}return(0,f.Xy)((0,f.Z$)(n),e)||n.push(["L",e.x,e.y]),n.push(["Z"]),n}var o5=ni("polygon",{defaultShapeType:"polygon",getDefaultPoints:function(r){var e=[];return(0,f.S6)(r.x,function(t,n){var i=r.y[n];e.push({x:t,y:i})}),e}});Ke("polygon","polygon",{draw:function(r,e){if(!(0,f.xb)(r.points)){var t=fr(r,!0,!0),n=this.parsePath(WC(r.points));return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n}),name:"polygon"})}},getMarker:function(r){var e=r.color;return{symbol:"square",style:{r:4,fill:e}}}});var s5=null,ZC=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="polygon",t.shapeType="polygon",t.generatePoints=!0,t}return e.prototype.createShapePointsCfg=function(t){var n=r.prototype.createShapePointsCfg.call(this,t),i=n.x,a=n.y,o;if(!((0,f.kJ)(i)&&(0,f.kJ)(a))){var s=this.getXScale(),l=this.getYScale(),u=s.values.length,c=l.values.length,h=.5*1/u,v=.5*1/c;s.isCategory&&l.isCategory?(i=[i-h,i-h,i+h,i+h],a=[a-v,a+v,a+v,a-v]):(0,f.kJ)(i)?(o=i,i=[o[0],o[0],o[1],o[1]],a=[a-v/2,a+v/2,a+v/2,a-v/2]):(0,f.kJ)(a)&&(o=a,a=[o[0],o[1],o[1],o[0]],i=[i-h/2,i-h/2,i+h/2,i+h/2]),n.x=i,n.y=a}return n},e}(ii),$C=ZC,l5=ni("schema",{defaultShapeType:""}),u5=null,qC=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="schema",t.shapeType="schema",t.generatePoints=!0,t}return e.prototype.createShapePointsCfg=function(t){var n=r.prototype.createShapePointsCfg.call(this,t),i,a=this.getAttribute("size");if(a){i=this.getAttributeValues(a,t)[0];var o=this.coordinate,s=$a(o);i=i/s}else this.defaultSize||(this.defaultSize=oc(this)),i=this.defaultSize;return n.size=i,n},e}(ii),KC=qC;function jC(r){if(!(0,f.kJ)(r))return[];var e=(0,f.Fp)(r);return(0,f.UI)(r,function(t){return t/e})}var c5=ni("violin",{defaultShapeType:"violin",getDefaultPoints:function(r){var e=r.size/2,t=[],n=jC(r._size);return(0,f.S6)(r.y,function(i,a){var o=n[a]*e,s=a===0,l=a===r.y.length-1;t.push({isMin:s,isMax:l,x:r.x-o,y:i}),t.unshift({isMin:s,isMax:l,x:r.x+o,y:i})}),t}});Ke("violin","violin",{draw:function(r,e){var t=fr(r,!0,!0),n=this.parsePath(Gv(r.points));return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n}),name:"violin"})},getMarker:function(r){var e=r.color;return{symbol:"circle",style:{r:4,fill:e}}}});var f5=null,JC=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="violin",t.shapeType="violin",t.generatePoints=!0,t}return e.prototype.createShapePointsCfg=function(t){var n=r.prototype.createShapePointsCfg.call(this,t),i,a=this.getAttribute("size");if(a){i=this.getAttributeValues(a,t)[0];var o=this.coordinate,s=$a(o);i=i/s}else this.defaultSize||(this.defaultSize=oc(this)),i=this.defaultSize;return n.size=i,n._size=(0,f.U2)(t[ee],[this._sizeField]),n},e.prototype.initAttributes=function(){var t=this.attributeOption,n=t.size?t.size.fields[0]:this._sizeField?this._sizeField:"size";this._sizeField=n,delete t.size,r.prototype.initAttributes.call(this)},e}(ii),QC=JC;Ke("area","line",{draw:function(r,e){var t=ks(r,!0,!1,this),n=e.addShape({type:"path",attrs:t,name:"area"});return n},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){return i===void 0&&(i=5.5),[["M",t-i,n-4],["L",t+i,n-4],["L",t+i,n+4],["L",t-i,n+4],["Z"]]},style:{r:5,stroke:e,fill:null}}}}),Ke("area","smooth",{draw:function(r,e){var t=this.coordinate,n=ks(r,!1,!0,this,Ld(t)),i=e.addShape({type:"path",attrs:n,name:"area"});return i},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){return i===void 0&&(i=5.5),[["M",t-i,n-4],["L",t+i,n-4],["L",t+i,n+4],["L",t-i,n+4],["Z"]]},style:{r:5,fill:e,fillOpacity:1}}}}),Ke("area","smooth-line",{draw:function(r,e){var t=this.coordinate,n=ks(r,!0,!0,this,Ld(t)),i=e.addShape({type:"path",attrs:n,name:"area"});return i},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){return i===void 0&&(i=5.5),[["M",t-i,n-4],["L",t+i,n-4],["L",t+i,n+4],["L",t-i,n+4],["Z"]]},style:{r:5,stroke:e,fill:null}}}});function lc(r,e){return["C",r.x*1/2+e.x*1/2,r.y,r.x*1/2+e.x*1/2,e.y,e.x,e.y]}function uc(r,e){var t=[];t.push({x:e.x,y:e.y}),t.push(r);var n=["Q"];return(0,f.S6)(t,function(i){n.push(i.x,i.y)}),n}function tA(r,e,t){var n=uc(e,t),i=[["M",r.x,r.y]];return i.push(n),i}function eA(r,e){var t=uc(r[1],e),n=uc(r[3],e),i=[["M",r[0].x,r[0].y]];return i.push(n),i.push(["L",r[3].x,r[3].y]),i.push(["L",r[2].x,r[2].y]),i.push(t),i.push(["L",r[1].x,r[1].y]),i.push(["L",r[0].x,r[0].y]),i.push(["Z"]),i}Ke("edge","arc",{draw:function(r,e){var t=fr(r,!0,!1,"lineWidth"),n=r.points,i=n.length>2?"weight":"normal",a;if(r.isInCircle){var o={x:0,y:1};return i==="normal"?a=tA(n[0],n[1],o):(t.fill=t.stroke,a=eA(n,o)),a=this.parsePath(a),e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:a})})}else{if(i==="normal")return n=this.parsePoints(n),a=Eh((n[1].x+n[0].x)/2,n[0].y,Math.abs(n[1].x-n[0].x)/2,Math.PI,Math.PI*2),e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:a})});var s=lc(n[1],n[3]),l=lc(n[2],n[0]);return a=[["M",n[0].x,n[0].y],["L",n[1].x,n[1].y],s,["L",n[3].x,n[3].y],["L",n[2].x,n[2].y],l,["Z"]],a=this.parsePath(a),t.fill=t.stroke,e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:a})})}},getMarker:function(r){return{symbol:"circle",style:{r:4.5,fill:r.color}}}});function rA(r,e){var t=lc(r,e),n=[["M",r.x,r.y]];return n.push(t),n}Ke("edge","smooth",{draw:function(r,e){var t=fr(r,!0,!1,"lineWidth"),n=r.points,i=this.parsePath(rA(n[0],n[1]));return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:i})})},getMarker:function(r){return{symbol:"circle",style:{r:4.5,fill:r.color}}}});var Bs=1/3;function nA(r,e){var t=[];t.push({x:r.x,y:r.y*(1-Bs)+e.y*Bs}),t.push({x:e.x,y:r.y*(1-Bs)+e.y*Bs}),t.push(e);var n=[["M",r.x,r.y]];return(0,f.S6)(t,function(i){n.push(["L",i.x,i.y])}),n}Ke("edge","vhv",{draw:function(r,e){var t=fr(r,!0,!1,"lineWidth"),n=r.points,i=this.parsePath(nA(n[0],n[1]));return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:i})})},getMarker:function(r){return{symbol:"circle",style:{r:4.5,fill:r.color}}}}),Ke("interval","funnel",{getPoints:function(r){return r.size=r.size*2,ic(r)},draw:function(r,e){var t=fr(r,!1,!0),n=this.parsePath(kd(r.points,r.nextPoints,!1)),i=e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n}),name:"interval"});return i},getMarker:function(r){var e=r.color;return{symbol:"square",style:{r:4,fill:e}}}}),Ke("interval","hollow-rect",{draw:function(r,e){var t=fr(r,!0,!1),n=e,i=r==null?void 0:r.background;if(i){n=e.addGroup();var a=Xv(r),o=Od(r,this.parsePoints(r.points),this.coordinate);n.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},a),{path:o}),capture:!1,zIndex:-1,name:Du})}var s=this.parsePath(ac(r.points)),l=n.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:s}),name:"interval"});return i?n:l},getMarker:function(r){var e=r.color,t=r.isInPolar;return t?{symbol:"circle",style:{r:4.5,stroke:e,fill:null}}:{symbol:"square",style:{r:4,stroke:e,fill:null}}}});function iA(r){var e=r.x,t=r.y,n=r.y0;return(0,f.kJ)(t)?t.map(function(i,a){return{x:(0,f.kJ)(e)?e[a]:e,y:i}}):[{x:e,y:n},{x:e,y:t}]}Ke("interval","line",{getPoints:function(r){return iA(r)},draw:function(r,e){var t=fr(r,!0,!1,"lineWidth"),n=Nr((0,p.pi)({},t),["fill"]),i=this.parsePath(ac(r.points,!1)),a=e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},n),{path:i}),name:"interval"});return a},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){return[["M",t,n-i],["L",t,n+i]]},style:{r:5,stroke:e}}}}),Ke("interval","pyramid",{getPoints:function(r){return r.size=r.size*2,ic(r)},draw:function(r,e){var t=fr(r,!1,!0),n=this.parsePath(kd(r.points,r.nextPoints,!0)),i=e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n}),name:"interval"});return i},getMarker:function(r){var e=r.color;return{symbol:"square",style:{r:4,fill:e}}}});function aA(r){var e,t=r.x,n=r.y,i=r.y0,a=r.size,o,s;(0,f.kJ)(n)?(e=(0,p.CR)(n,2),o=e[0],s=e[1]):(o=i,s=n);var l=t+a/2,u=t-a/2;return[{x:t,y:o},{x:t,y:s},{x:u,y:o},{x:l,y:o},{x:u,y:s},{x:l,y:s}]}function oA(r){return[["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],["M",r[2].x,r[2].y],["L",r[3].x,r[3].y],["M",r[4].x,r[4].y],["L",r[5].x,r[5].y]]}Ke("interval","tick",{getPoints:function(r){return aA(r)},draw:function(r,e){var t=fr(r,!0,!1),n=this.parsePath(oA(r.points)),i=e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n}),name:"interval"});return i},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){return[["M",t-i/2,n-i],["L",t+i/2,n-i],["M",t,n-i],["L",t,n+i],["M",t-i/2,n+i],["L",t+i/2,n+i]]},style:{r:5,stroke:e}}}});var sA=function(r,e,t){var n=r.x,i=r.y,a=e.x,o=e.y,s;switch(t){case"hv":s=[{x:a,y:i}];break;case"vh":s=[{x:n,y:o}];break;case"hvh":var l=(a+n)/2;s=[{x:l,y:i},{x:l,y:o}];break;case"vhv":var u=(i+o)/2;s=[{x:n,y:u},{x:a,y:u}];break;default:break}return s};function lA(r,e){var t=[];return(0,f.S6)(r,function(n,i){var a=r[i+1];if(t.push(n),a){var o=sA(n,a,e);t=t.concat(o)}}),t}function uA(r){return r.map(function(e,t){return t===0?["M",e.x,e.y]:["L",e.x,e.y]})}function cA(r,e){var t=bs(r.points,r.connectNulls,r.showSinglePoint),n=[];return(0,f.S6)(t,function(i){var a=lA(i,e);n=n.concat(uA(a))}),(0,p.pi)((0,p.pi)({},fr(r,!0,!1,"lineWidth")),{path:n})}(0,f.S6)(["hv","vh","hvh","vhv"],function(r){Ke("line",r,{draw:function(e,t){var n=cA(e,r),i=t.addShape({type:"path",attrs:n,name:"line"});return i},getMarker:function(e){return Wv(e,r)}})}),(0,f.S6)(GC,function(r){Ke("point",r,{draw:function(e,t){return sc(this,e,t,r,!0)},getMarker:function(e){var t=e.color;return{symbol:_i[r],style:{r:4.5,stroke:t,fill:null}}}})}),Ke("point","image",{draw:function(r,e){var t,n,i=fr(r,!1,!1,"r").r,a=this.parsePoints(r.points),o=a[0];if(r.isStack)o=a[1];else if(a.length>1){var s=e.addGroup();try{for(var l=(0,p.XA)(a),u=l.next();!u.done;u=l.next()){var c=u.value;s.addShape("image",{attrs:{x:c.x-i/2,y:c.y-i,width:i,height:i,img:r.shape[1]}})}}catch(h){t={error:h}}finally{try{u&&!u.done&&(n=l.return)&&n.call(l)}finally{if(t)throw t.error}}return s}return e.addShape("image",{attrs:{x:o.x-i/2,y:o.y-i,width:i,height:i,img:r.shape[1]}})},getMarker:function(r){var e=r.color;return{symbol:"circle",style:{r:4.5,fill:e}}}}),(0,f.S6)(Bd,function(r){Ke("point",r,{draw:function(e,t){return sc(this,e,t,r,!1)},getMarker:function(e){var t=e.color;return{symbol:_i[r]||r,style:{r:4.5,fill:t}}}})});function Rd(r){var e=(0,f.kJ)(r)?r:[r],t=e[0],n=e[e.length-1],i=e.length>1?e[1]:t,a=e.length>3?e[3]:n,o=e.length>2?e[2]:i;return{min:t,max:n,min1:i,max1:a,median:o}}function Nd(r,e,t){var n=t/2,i;if((0,f.kJ)(e)){var a=Rd(e),o=a.min,s=a.max,l=a.median,u=a.min1,c=a.max1,h=r-n,v=r+n;i=[[h,s],[v,s],[r,s],[r,c],[h,u],[h,c],[v,c],[v,u],[r,u],[r,o],[h,o],[v,o],[h,l],[v,l]]}else{e=(0,f.UM)(e)?.5:e;var d=Rd(r),o=d.min,s=d.max,l=d.median,u=d.min1,c=d.max1,g=e-n,y=e+n;i=[[o,g],[o,y],[o,e],[u,e],[u,g],[u,y],[c,y],[c,g],[c,e],[s,e],[s,g],[s,y],[l,g],[l,y]]}return i.map(function(x){return{x:x[0],y:x[1]}})}function fA(r){return[["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],["M",r[2].x,r[2].y],["L",r[3].x,r[3].y],["M",r[4].x,r[4].y],["L",r[5].x,r[5].y],["L",r[6].x,r[6].y],["L",r[7].x,r[7].y],["L",r[4].x,r[4].y],["Z"],["M",r[8].x,r[8].y],["L",r[9].x,r[9].y],["M",r[10].x,r[10].y],["L",r[11].x,r[11].y],["M",r[12].x,r[12].y],["L",r[13].x,r[13].y]]}Ke("schema","box",{getPoints:function(r){var e=r.x,t=r.y,n=r.size;return Nd(e,t,n)},draw:function(r,e){var t=fr(r,!0,!1),n=this.parsePath(fA(r.points)),i=e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n,name:"schema"})});return i},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){var a=[n-6,n-3,n,n+3,n+6],o=Nd(t,a,i);return[["M",o[0].x+1,o[0].y],["L",o[1].x-1,o[1].y],["M",o[2].x,o[2].y],["L",o[3].x,o[3].y],["M",o[4].x,o[4].y],["L",o[5].x,o[5].y],["L",o[6].x,o[6].y],["L",o[7].x,o[7].y],["L",o[4].x,o[4].y],["Z"],["M",o[8].x,o[8].y],["L",o[9].x,o[9].y],["M",o[10].x+1,o[10].y],["L",o[11].x-1,o[11].y],["M",o[12].x,o[12].y],["L",o[13].x,o[13].y]]},style:{r:6,lineWidth:1,stroke:e}}}});function hA(r){var e=(0,f.kJ)(r)?r:[r],t=e.sort(function(n,i){return i-n});return K1(t,4,t[t.length-1])}function Ud(r,e,t){var n=hA(e);return[{x:r,y:n[0]},{x:r,y:n[1]},{x:r-t/2,y:n[2]},{x:r-t/2,y:n[1]},{x:r+t/2,y:n[1]},{x:r+t/2,y:n[2]},{x:r,y:n[2]},{x:r,y:n[3]}]}function vA(r){return[["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],["M",r[2].x,r[2].y],["L",r[3].x,r[3].y],["L",r[4].x,r[4].y],["L",r[5].x,r[5].y],["Z"],["M",r[6].x,r[6].y],["L",r[7].x,r[7].y]]}Ke("schema","candle",{getPoints:function(r){var e=r.x,t=r.y,n=r.size;return Ud(e,t,n)},draw:function(r,e){var t=fr(r,!0,!0),n=this.parsePath(vA(r.points)),i=e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n,name:"schema"})});return i},getMarker:function(r){var e=r.color;return{symbol:function(t,n,i){var a=[n+7.5,n+3,n-3,n-7.5],o=Ud(t,a,i);return[["M",o[0].x,o[0].y],["L",o[1].x,o[1].y],["M",o[2].x,o[2].y],["L",o[3].x,o[3].y],["L",o[4].x,o[4].y],["L",o[5].x,o[5].y],["Z"],["M",o[6].x,o[6].y],["L",o[7].x,o[7].y]]},style:{lineWidth:1,stroke:e,fill:e,r:6}}}});function dA(r,e){var t=Math.abs(r[0].x-r[2].x),n=Math.abs(r[0].y-r[2].y),i=Math.min(t,n);e&&(i=(0,f.uZ)(e,0,Math.min(t,n))),i=i/2;var a=(r[0].x+r[2].x)/2,o=(r[0].y+r[2].y)/2;return{x:a-i,y:o-i,width:i*2,height:i*2}}Ke("polygon","square",{draw:function(r,e){if(!(0,f.xb)(r.points)){var t=fr(r,!0,!0),n=this.parsePoints(r.points);return e.addShape("rect",{attrs:(0,p.pi)((0,p.pi)({},t),dA(n,r.size)),name:"polygon"})}},getMarker:function(r){var e=r.color;return{symbol:"square",style:{r:4,fill:e}}}}),Ke("violin","smooth",{draw:function(r,e){var t=fr(r,!0,!0),n=this.parsePath(Yv(r.points));return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n})})},getMarker:function(r){var e=r.color;return{symbol:"circle",style:{stroke:null,r:4,fill:e}}}}),Ke("violin","hollow",{draw:function(r,e){var t=fr(r,!0,!1),n=this.parsePath(Gv(r.points));return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n})})},getMarker:function(r){var e=r.color;return{symbol:"circle",style:{r:4,fill:null,stroke:e}}}}),Ke("violin","hollow-smooth",{draw:function(r,e){var t=fr(r,!0,!1),n=this.parsePath(Yv(r.points));return e.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},t),{path:n})})},getMarker:function(r){var e=r.color;return{symbol:"circle",style:{r:4,fill:null,stroke:e}}}});var pA=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getLabelValueDir=function(t){var n="y",i=t.points;return i[0][n]<=i[2][n]?1:-1},e.prototype.getLabelOffsetPoint=function(t,n,i,a){var o,s=r.prototype.getLabelOffsetPoint.call(this,t,n,i),l=this.getCoordinate(),u=l.isTransposed,c=u?"x":"y",h=this.getLabelValueDir(t.mappingData);return s=(0,p.pi)((0,p.pi)({},s),(o={},o[c]=s[c]*h,o)),l.isReflect("x")&&(s=(0,p.pi)((0,p.pi)({},s),{x:s.x*-1})),l.isReflect("y")&&(s=(0,p.pi)((0,p.pi)({},s),{y:s.y*-1})),s},e.prototype.getThemedLabelCfg=function(t){var n=this.geometry,i=this.getDefaultLabelCfg(),a=n.theme;return(0,f.b$)({},i,a.labels,t.position==="middle"?{offset:0}:{},t)},e.prototype.setLabelPosition=function(t,n,i,a){var o=this.getCoordinate(),s=o.isTransposed,l=n.points,u=o.convert(l[0]),c=o.convert(l[2]),h=this.getLabelValueDir(n),v,d,g,y,x=(0,f.kJ)(n.shape)?n.shape[0]:n.shape;if(x==="funnel"||x==="pyramid"){var m=(0,f.U2)(n,"nextPoints"),M=(0,f.U2)(n,"points");if(m){var w=o.convert(M[0]),S=o.convert(M[1]),b=o.convert(m[0]),k=o.convert(m[1]);s?(v=Math.min(b.y,w.y),g=Math.max(b.y,w.y),d=(S.x+k.x)/2,y=(w.x+b.x)/2):(v=Math.min((S.y+k.y)/2,(w.y+b.y)/2),g=Math.max((S.y+k.y)/2,(w.y+b.y)/2),d=k.x,y=w.x)}else v=Math.min(c.y,u.y),g=Math.max(c.y,u.y),d=c.x,y=u.x}else v=Math.min(c.y,u.y),g=Math.max(c.y,u.y),d=c.x,y=u.x;switch(a){case"right":t.x=d,t.y=(v+g)/2,t.textAlign=(0,f.U2)(t,"textAlign",h>0?"left":"right");break;case"left":t.x=y,t.y=(v+g)/2,t.textAlign=(0,f.U2)(t,"textAlign",h>0?"left":"right");break;case"bottom":s&&(t.x=(d+y)/2),t.y=g,t.textAlign=(0,f.U2)(t,"textAlign","center"),t.textBaseline=(0,f.U2)(t,"textBaseline",h>0?"bottom":"top");break;case"middle":s&&(t.x=(d+y)/2),t.y=(v+g)/2,t.textAlign=(0,f.U2)(t,"textAlign","center"),t.textBaseline=(0,f.U2)(t,"textBaseline","middle");break;case"top":s&&(t.x=(d+y)/2),t.y=v,t.textAlign=(0,f.U2)(t,"textAlign","center"),t.textBaseline=(0,f.U2)(t,"textBaseline",h>0?"bottom":"top");break;default:break}},e}(As),gA=pA,Rs=Math.PI/2,yA=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getLabelOffset=function(t){var n=this.getCoordinate(),i=0;if((0,f.hj)(t))i=t;else if((0,f.HD)(t)&&t.indexOf("%")!==-1){var a=n.getRadius();n.innerRadius>0&&(a=a*(1-n.innerRadius)),i=parseFloat(t)*.01*a}return i},e.prototype.getLabelItems=function(t){var n=r.prototype.getLabelItems.call(this,t),i=this.geometry.getYScale();return(0,f.UI)(n,function(a){if(a&&i){var o=i.scale((0,f.U2)(a.data,i.field));return(0,p.pi)((0,p.pi)({},a),{percent:o})}return a})},e.prototype.getLabelAlign=function(t){var n=this.getCoordinate(),i;if(t.labelEmit)i=t.angle<=Math.PI/2&&t.angle>=-Math.PI/2?"left":"right";else if(!n.isTransposed)i="center";else{var a=n.getCenter(),o=t.offset;Math.abs(t.x-a.x)<1?i="center":t.angle>Math.PI||t.angle<=0?i=o>0?"left":"right":i=o>0?"right":"left"}return i},e.prototype.getLabelPoint=function(t,n,i){var a=1,o,s=t.content[i];this.isToMiddle(n)?o=this.getMiddlePoint(n.points):(t.content.length===1&&i===0?i=1:i===0&&(a=-1),o=this.getArcPoint(n,i));var l=t.offset*a,u=this.getPointAngle(o),c=t.labelEmit,h=this.getCirclePoint(u,l,o,c);return h.r===0?h.content="":(h.content=s,h.angle=u,h.color=n.color),h.rotate=t.autoRotate?this.getLabelRotate(u,l,c):t.rotate,h.start={x:o.x,y:o.y},h},e.prototype.getArcPoint=function(t,n){return n===void 0&&(n=0),!(0,f.kJ)(t.x)&&!(0,f.kJ)(t.y)?{x:t.x,y:t.y}:{x:(0,f.kJ)(t.x)?t.x[n]:t.x,y:(0,f.kJ)(t.y)?t.y[n]:t.y}},e.prototype.getPointAngle=function(t){return ia(this.getCoordinate(),t)},e.prototype.getCirclePoint=function(t,n,i,a){var o=this.getCoordinate(),s=o.getCenter(),l=cs(o,i);if(l===0)return(0,p.pi)((0,p.pi)({},s),{r:l});var u=t;if(o.isTransposed&&l>n&&!a){var c=Math.asin(n/(2*l));u=t+c*2}else l=l+n;return{x:s.x+l*Math.cos(u),y:s.y+l*Math.sin(u),r:l}},e.prototype.getLabelRotate=function(t,n,i){var a=t+Rs;return i&&(a-=Rs),a&&(a>Rs?a=a-Math.PI:a<-Rs&&(a=a+Math.PI)),a},e.prototype.getMiddlePoint=function(t){var n=this.getCoordinate(),i=t.length,a={x:0,y:0};return(0,f.S6)(t,function(o){a.x+=o.x,a.y+=o.y}),a.x/=i,a.y/=i,a=n.convert(a),a},e.prototype.isToMiddle=function(t){return t.x.length>2},e}(As),zd=yA,mA=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.defaultLayout="distribute",t}return e.prototype.getDefaultLabelCfg=function(t,n){var i=r.prototype.getDefaultLabelCfg.call(this,t,n);return(0,f.b$)({},i,(0,f.U2)(this.geometry.theme,"pieLabels",{}))},e.prototype.getLabelOffset=function(t){return r.prototype.getLabelOffset.call(this,t)||0},e.prototype.getLabelRotate=function(t,n,i){var a;return n<0&&(a=t,a>Math.PI/2&&(a=a-Math.PI),a<-Math.PI/2&&(a=a+Math.PI)),a},e.prototype.getLabelAlign=function(t){var n=this.getCoordinate(),i=n.getCenter(),a;return t.angle<=Math.PI/2&&t.x>=i.x?a="left":a="right",t.offset<=0&&(a==="right"?a="left":a="right"),a},e.prototype.getArcPoint=function(t){return t},e.prototype.getPointAngle=function(t){var n=this.getCoordinate(),i={x:(0,f.kJ)(t.x)?t.x[0]:t.x,y:t.y[0]},a={x:(0,f.kJ)(t.x)?t.x[1]:t.x,y:t.y[1]},o,s=ia(n,i);if(t.points&&t.points[0].y===t.points[1].y)o=s;else{var l=ia(n,a);s>=l&&(l=l+Math.PI*2),o=s+(l-s)/2}return o},e.prototype.getCirclePoint=function(t,n){var i=this.getCoordinate(),a=i.getCenter(),o=i.getRadius()+n;return(0,p.pi)((0,p.pi)({},hr(a.x,a.y,o,t)),{angle:t,r:o})},e}(zd),xA=mA,Vd=4;function MA(r,e,t,n,i,a){var o,s,l=!0,u=n.start,c=n.end,h=Math.min(u.y,c.y),v=Math.abs(u.y-c.y),d,g=0,y=Number.MIN_VALUE,x=e.map(function(H){return H.y>g&&(g=H.y),H.y<y&&(y=H.y),{size:t,targets:[H.y-h]}});for(y-=h,g-h>v&&(v=g-h);l;)for(x.forEach(function(H){var at=(Math.min.apply(y,H.targets)+Math.max.apply(y,H.targets))/2;H.pos=Math.min(Math.max(y,at-H.size/2),v-H.size)}),l=!1,d=x.length;d--;)if(d>0){var m=x[d-1],M=x[d];m.pos+m.size>M.pos&&(m.size+=M.size,m.targets=m.targets.concat(M.targets),m.pos+m.size>v&&(m.pos=v-m.size),x.splice(d,1),l=!0)}d=0,x.forEach(function(H){var at=h+t/2;H.targets.forEach(function(){e[d].y=H.pos+at,at+=t,d++})});var w={};try{for(var S=(0,p.XA)(r),b=S.next();!b.done;b=S.next()){var k=b.value;w[k.get("id")]=k}}catch(H){o={error:H}}finally{try{b&&!b.done&&(s=S.return)&&s.call(S)}finally{if(o)throw o.error}}e.forEach(function(H){var at=H.r*H.r,At=Math.pow(Math.abs(H.y-i.y),2);if(at<At)H.x=i.x;else{var gt=Math.sqrt(at-At);a?H.x=i.x+gt:H.x=i.x-gt}var Nt=w[H.id];Nt.attr("x",H.x),Nt.attr("y",H.y);var te=(0,f.sE)(Nt.getChildren(),function(ce){return ce.get("type")==="text"});te&&(te.attr("y",H.y),te.attr("x",H.x))})}function wA(r,e,t,n){if(!(!r.length||!e.length)){var i=r[0]?r[0].offset:0,a=e[0].get("coordinate"),o=a.getRadius(),s=a.getCenter();if(i>0){var l=14,u=o+i,c=u*2+l*2,h={start:a.start,end:a.end},v=[[],[]];r.forEach(function(d){!d||(d.textAlign==="right"?v[0].push(d):v[1].push(d))}),v.forEach(function(d,g){var y=c/l;d.length>y&&(d.sort(function(x,m){return m["..percent"]-x["..percent"]}),d.splice(y,d.length-y)),d.sort(function(x,m){return x.y-m.y}),MA(e,d,l,h,s,g)})}(0,f.S6)(r,function(d){if(d&&d.labelLine){var g=d.offset,y=d.angle,x=hr(s.x,s.y,o,y),m=hr(s.x,s.y,o+g/2,y),M=d.x+(0,f.U2)(d,"offsetX",0),w=d.y+(0,f.U2)(d,"offsetY",0),S={x:M-Math.cos(y)*Vd,y:w-Math.sin(y)*Vd};(0,f.Kn)(d.labelLine)||(d.labelLine={}),d.labelLine.path=["M ".concat(x.x),"".concat(x.y," Q").concat(m.x),"".concat(m.y," ").concat(S.x),S.y].join(",")}})}}function Hd(r,e,t){var n=r.filter(function(g){return!g.invisible});n.sort(function(g,y){return g.y-y.y});var i=!0,a=t.minY,o=t.maxY,s=Math.abs(a-o),l,u=0,c=Number.MIN_VALUE,h=n.map(function(g){return g.y>u&&(u=g.y),g.y<c&&(c=g.y),{content:g.content,size:e,targets:[g.y-a],pos:null}});for(c-=a,u-a>s&&(s=u-a);i;)for(h.forEach(function(g){var y=(Math.min.apply(c,g.targets)+Math.max.apply(c,g.targets))/2;g.pos=Math.min(Math.max(c,y-g.size/2),s-g.size),g.pos=Math.max(0,g.pos)}),i=!1,l=h.length;l--;)if(l>0){var v=h[l-1],d=h[l];v.pos+v.size>d.pos&&(v.size+=d.size,v.targets=v.targets.concat(d.targets),v.pos+v.size>s&&(v.pos=s-v.size),h.splice(l,1),i=!0)}l=0,h.forEach(function(g){var y=a+e/2;g.targets.forEach(function(){n[l].y=g.pos+y,y+=e,l++})})}var Gd=4;function SA(r,e){var t=e.getCenter(),n=e.getRadius();if(r&&r.labelLine){var i=r.angle,a=r.offset,o=hr(t.x,t.y,n,i),s=r.x+(0,f.U2)(r,"offsetX",0)*(Math.cos(i)>0?1:-1),l=r.y+(0,f.U2)(r,"offsetY",0)*(Math.sin(i)>0?1:-1),u={x:s-Math.cos(i)*Gd,y:l-Math.sin(i)*Gd},c=r.labelLine.smooth,h=[],v=u.x-t.x,d=u.y-t.y,g=Math.atan(d/v);if(v<0&&(g+=Math.PI),c===!1){(0,f.Kn)(r.labelLine)||(r.labelLine={});var y=0;(i<0&&i>-Math.PI/2||i>Math.PI*1.5)&&u.y>o.y&&(y=1),i>=0&&i<Math.PI/2&&u.y>o.y&&(y=1),i>=Math.PI/2&&i<Math.PI&&o.y>u.y&&(y=1),(i<-Math.PI/2||i>=Math.PI&&i<Math.PI*1.5)&&o.y>u.y&&(y=1);var x=a/2>4?4:Math.max(a/2-1,0),m=hr(t.x,t.y,n+x,i),M=hr(t.x,t.y,n+a/2,g),w=0;h.push("M ".concat(o.x," ").concat(o.y)),h.push("L ".concat(m.x," ").concat(m.y)),h.push("A ".concat(t.x," ").concat(t.y," 0 ").concat(w," ").concat(y," ").concat(M.x," ").concat(M.y)),h.push("L ".concat(u.x," ").concat(u.y))}else{var m=hr(t.x,t.y,n+(a/2>4?4:Math.max(a/2-1,0)),i),S=o.x<t.x?1:-1;h.push("M ".concat(u.x," ").concat(u.y));var b=(o.y-t.y)/(o.x-t.x),k=(u.y-t.y)/(u.x-t.x);Math.abs(b-k)>Math.pow(Math.E,-16)&&h.push.apply(h,["C",u.x+S*4,u.y,2*m.x-o.x,2*m.y-o.y,o.x,o.y]),h.push("L ".concat(o.x," ").concat(o.y))}r.labelLine.path=h.join(" ")}}function CA(r,e,t,n){var i,a,o=(0,f.hX)(r,function(at){return!(0,f.UM)(at)}),s=e[0]&&e[0].get("coordinate");if(!!s){var l=s.getCenter(),u=s.getRadius(),c={};try{for(var h=(0,p.XA)(e),v=h.next();!v.done;v=h.next()){var d=v.value;c[d.get("id")]=d}}catch(at){i={error:at}}finally{try{v&&!v.done&&(a=h.return)&&a.call(h)}finally{if(i)throw i.error}}var g=(0,f.U2)(o[0],"labelHeight",14),y=(0,f.U2)(o[0],"offset",0);if(!(y<=0)){var x="left",m="right",M=(0,f.vM)(o,function(at){return at.x<l.x?x:m}),w=s.start,S=s.end,b=Math.min((u+y+g)*2,s.getHeight()),k=b/2,H={minX:w.x,maxX:S.x,minY:l.y-k,maxY:l.y+k};(0,f.S6)(M,function(at,At){var gt=Math.floor(b/g);at.length>gt&&(at.sort(function(Nt,te){return te.percent-Nt.percent}),(0,f.S6)(at,function(Nt,te){te+1>gt&&(c[Nt.id].set("visible",!1),Nt.invisible=!0)})),Hd(at,g,H)}),(0,f.S6)(M,function(at,At){(0,f.S6)(at,function(gt){var Nt=At===m,te=c[gt.id],ce=te.getChildByIndex(0);if(ce){var Me=u+y,be=gt.y-l.y,Gt=Math.pow(Me,2),ie=Math.pow(be,2),de=Gt-ie>0?Gt-ie:0,ue=Math.sqrt(de),pe=Math.abs(Math.cos(gt.angle)*Me);Nt?gt.x=l.x+Math.max(ue,pe):gt.x=l.x-Math.max(ue,pe)}ce&&(ce.attr("y",gt.y),ce.attr("x",gt.x)),SA(gt,s)})})}}}var cc=4,AA=4,Yd=4;function bA(r,e,t){var n=e.getCenter(),i=e.getRadius(),a={x:r.x-(t?Yd:-Yd),y:r.y},o=hr(n.x,n.y,i+cc,r.angle),s={x:a.x,y:a.y},l={x:o.x,y:o.y},u=hr(n.x,n.y,i,r.angle),c="";if(a.y!==o.y){var h=t?4:-4;s.y=a.y,r.angle<0&&r.angle>=-Math.PI/2&&(s.x=Math.max(o.x,a.x-h),a.y<o.y?l.y=s.y:(l.y=o.y,l.x=Math.max(l.x,s.x-h))),r.angle>0&&r.angle<Math.PI/2&&(s.x=Math.max(o.x,a.x-h),a.y>o.y?l.y=s.y:(l.y=o.y,l.x=Math.max(l.x,s.x-h))),r.angle>Math.PI/2&&(s.x=Math.min(o.x,a.x-h),a.y>o.y?l.y=s.y:(l.y=o.y,l.x=Math.min(l.x,s.x-h))),r.angle<-Math.PI/2&&(s.x=Math.min(o.x,a.x-h),a.y<o.y?l.y=s.y:(l.y=o.y,l.x=Math.min(l.x,s.x-h)))}c=["M ".concat(a.x,",").concat(a.y),"L ".concat(s.x,",").concat(s.y),"L ".concat(l.x,",").concat(l.y),"L ".concat(o.x,",").concat(o.y),"L ".concat(u.x,",").concat(u.y)].join(" "),r.labelLine=(0,f.b$)({},r.labelLine,{path:c})}function TA(r,e,t,n){var i,a,o=e[0]&&e[0].get("coordinate");if(!!o){var s=o.getCenter(),l=o.getRadius(),u={};try{for(var c=(0,p.XA)(e),h=c.next();!h.done;h=c.next()){var v=h.value;u[v.get("id")]=v}}catch(at){i={error:at}}finally{try{h&&!h.done&&(a=c.return)&&a.call(c)}finally{if(i)throw i.error}}var d=(0,f.U2)(r[0],"labelHeight",14),g=Math.max((0,f.U2)(r[0],"offset",0),cc);(0,f.S6)(r,function(at){if(!!at){var At=(0,f.U2)(u,[at.id]);if(!!At){var gt=at.x>s.x||at.x===s.x&&at.y>s.y,Nt=(0,f.UM)(at.offsetX)?AA:at.offsetX,te=hr(s.x,s.y,l+cc,at.angle),ce=g+Nt;at.x=s.x+(gt?1:-1)*(l+ce),at.y=te.y}}});var y=o.start,x=o.end,m="left",M="right",w=(0,f.vM)(r,function(at){return at.x<s.x?m:M}),S=(l+g)*2+d;(0,f.S6)(w,function(at){var At=at.length*d;At>S&&(S=Math.min(At,Math.abs(y.y-x.y)))});var b={minX:y.x,maxX:x.x,minY:s.y-S/2,maxY:s.y+S/2};(0,f.S6)(w,function(at,At){var gt=S/d;at.length>gt&&(at.sort(function(Nt,te){return te.percent-Nt.percent}),(0,f.S6)(at,function(Nt,te){te>gt&&(u[Nt.id].set("visible",!1),Nt.invisible=!0)})),Hd(at,d,b)});var k=b.minY,H=b.maxY;(0,f.S6)(w,function(at,At){var gt=At===M;(0,f.S6)(at,function(Nt){var te=(0,f.U2)(u,Nt&&[Nt.id]);if(!!te){if(Nt.y<k||Nt.y>H){te.set("visible",!1);return}var ce=te.getChildByIndex(0),Me=ce.getCanvasBBox(),be={x:gt?Me.x:Me.maxX,y:Me.y+Me.height/2};io(ce,Nt.x-be.x,Nt.y-be.y),Nt.labelLine&&bA(Nt,o,gt)}})})}}function EA(r,e,t,n){(0,f.S6)(e,function(i){var a=n.minX,o=n.minY,s=n.maxX,l=n.maxY,u=i.getCanvasBBox(),c=u.minX,h=u.minY,v=u.maxX,d=u.maxY,g=u.x,y=u.y,x=u.width,m=u.height,M=g,w=y;(c<a||v<a)&&(M=a),(h<o||d<o)&&(w=o),c>s?M=s-x:v>s&&(M=M-(v-s)),h>l?w=l-m:d>l&&(w=w-(d-l)),(M!==g||w!==y)&&io(i,M-g,w-y)})}function _A(r,e,t,n){(0,f.S6)(e,function(i,a){var o=i.getCanvasBBox(),s=t[a].getBBox();(o.minX<s.minX||o.minY<s.minY||o.maxX>s.maxX||o.maxY>s.maxY)&&i.remove(!0)})}var FA=100,Xd=function(){function r(e){e===void 0&&(e={}),this.bitmap={};var t=e.xGap,n=t===void 0?1:t,i=e.yGap,a=i===void 0?8:i;this.xGap=n,this.yGap=a}return r.prototype.hasGap=function(e){for(var t=!0,n=this.bitmap,i=Math.round(e.minX),a=Math.round(e.maxX),o=Math.round(e.minY),s=Math.round(e.maxY),l=i;l<=a;l+=1){if(!n[l]){n[l]={};continue}if(l===i||l===a){for(var u=o;u<=s;u++)if(n[l][u]){t=!1;break}}else if(n[l][o]||n[l][s]){t=!1;break}}return t},r.prototype.fillGap=function(e){for(var t=this.bitmap,n=Math.round(e.minX),i=Math.round(e.maxX),a=Math.round(e.minY),o=Math.round(e.maxY),s=n;s<=i;s+=1)t[s]||(t[s]={});for(var s=n;s<=i;s+=this.xGap){for(var l=a;l<=o;l+=this.yGap)t[s][l]=!0;t[s][o]=!0}if(this.yGap!==1)for(var s=a;s<=o;s+=1)t[n][s]=!0,t[i][s]=!0;if(this.xGap!==1)for(var s=n;s<=i;s+=1)t[s][a]=!0,t[s][o]=!0},r.prototype.destroy=function(){this.bitmap={}},r}();function IA(r,e,t){t===void 0&&(t=FA);var n=-1,i=r.attr(),a=i.x,o=i.y,s=r.getCanvasBBox(),l=Math.sqrt(s.width*s.width+s.height*s.height),u,c=-n,h=0,v=0,d=function(m){var M=m*.1;return[M*Math.cos(M),M*Math.sin(M)]};if(e.hasGap(s))return e.fillGap(s),!0;for(var g=!1,y=0,x={};Math.min(Math.abs(h),Math.abs(v))<l&&y<t;)if(u=d(c+=n),h=~~u[0],v=~~u[1],!(!h&&!v||x["".concat(h,"-").concat(v)])&&(r.attr({x:a+h,y:o+v}),h+v<0&&r.attr("textAlign","right"),y++,e.hasGap(r.getCanvasBBox()))){e.fillGap(r.getCanvasBBox()),g=!0,x["".concat(h,"-").concat(v)]=!0;break}return g}function PA(r,e,t,n){var i=r.getCanvasBBox(),a=i.width,o=i.height,s={x:e,y:t,textAlign:"center"};switch(n){case 0:s.y-=o+1,s.x+=1,s.textAlign="left";break;case 1:s.y-=o+1,s.x-=1,s.textAlign="right";break;case 2:s.y+=o+1,s.x-=1,s.textAlign="right";break;case 3:s.y+=o+1,s.x+=1,s.textAlign="left";break;case 5:s.y-=o*2+2;break;case 6:s.y+=o*2+2;break;case 7:s.x+=a+1,s.textAlign="left";break;case 8:s.x-=a+1,s.textAlign="right";break;default:break}return r.attr(s),r.getCanvasBBox()}function LA(r,e,t,n){var i=new Xd;(0,f.S6)(e,function(a){var o=a.find(function(s){return s.get("type")==="text"});IA(o,i)||a.remove(!0)}),i.destroy()}function DA(r,e,t,n){var i=new Xd;(0,f.S6)(e,function(a){for(var o=a.find(function(d){return d.get("type")==="text"}),s=o.attr(),l=s.x,u=s.y,c=!1,h=0;h<=8;h++){var v=PA(o,l,u,h);if(i.hasGap(v)){i.fillGap(v),c=!0;break}}c||a.remove(!0)}),i.destroy()}function OA(r,e){return(r[0]||0)*(e[0]||0)+(r[1]||0)*(e[1]||0)+(r[2]||0)*(e[2]||0)}function Wd(r){if(r.length>4)return[];var e=function(i,a){return[a.x-i.x,a.y-i.y]},t=e(r[0],r[1]),n=e(r[1],r[2]);return[t,n]}function Ns(r,e,t){e===void 0&&(e=0),t===void 0&&(t={x:0,y:0});var n=r.x,i=r.y;return{x:(n-t.x)*Math.cos(-e)+(i-t.y)*Math.sin(-e)+t.x,y:(t.x-n)*Math.sin(-e)+(i-t.y)*Math.cos(-e)+t.y}}function Zd(r){var e=[{x:r.x,y:r.y},{x:r.x+r.width,y:r.y},{x:r.x+r.width,y:r.y+r.height},{x:r.x,y:r.y+r.height}],t=r.rotation;return t?[Ns(e[0],t,e[0]),Ns(e[1],t,e[0]),Ns(e[2],t,e[0]),Ns(e[3],t,e[0])]:e}function $d(r,e){if(r.length>4)return{min:0,max:0};var t=[];return r.forEach(function(n){t.push(OA([n.x,n.y],e))}),{min:Math.min.apply(Math,(0,p.ev)([],(0,p.CR)(t),!1)),max:Math.max.apply(Math,(0,p.ev)([],(0,p.CR)(t),!1))}}function kA(r,e){return r.max>e.min&&r.min<e.max}function BA(r){return typeof r=="number"&&!Number.isNaN(r)&&r!==Infinity&&r!==-Infinity}function qd(r){return["x","y","width","height"].every(function(e){return BA(r[e])})}function RA(r,e,t){return t===void 0&&(t=0),!(e.x>r.x+r.width+t||e.x+e.width<r.x-t||e.y>r.y+r.height+t||e.y+e.height<r.y-t)}function NA(r,e,t){if(t===void 0&&(t=0),!qd(r)||!qd(e))return!1;if(!r.rotation&&!e.rotation)return RA(r,e,t);for(var n=Zd(r),i=Zd(e),a=Wd(n).concat(Wd(i)),o=0;o<a.length;o++){var s=a[o],l=$d(n,s),u=$d(i,s);if(!kA(l,u))return!1}return!0}var UA=function(){function r(e){var t=this;this.queue=[],this.worker=new Worker(e),this.worker.onmessage=function(n){var i;(i=t.queue.shift())===null||i===void 0||i.resolve(n)},this.worker.onmessageerror=function(n){var i;console.warn("[AntV G2] Web worker is not available"),(i=t.queue.shift())===null||i===void 0||i.reject(n)}}return r.prototype.post=function(e,t){var n=this;return new Promise(function(i,a){n.queue.push({resolve:i,reject:a});try{n.worker.postMessage(e)}catch(o){console.warn("[AntV G2] Web worker is not available"),(0,f.mf)(t)&&t()}})},r.prototype.destroy=function(){this.worker.terminate()},r}();function zA(r){if(typeof window!="undefined"){var e;try{e=new Blob([r.toString()],{type:"application/javascript"})}catch(t){e=new window.BlobBuilder,e.append(r.toString()),e=e.getBlob()}return new UA(URL.createObjectURL(e))}}var VA=function(r){function e(){function u(w,S){return(w[0]||0)*(S[0]||0)+(w[1]||0)*(S[1]||0)+(w[2]||0)*(S[2]||0)}function c(w){if(w.length>4)return[];var S=function(H,at){return[at.x-H.x,at.y-H.y]},b=S(w[0],w[1]),k=S(w[1],w[2]);return[b,k]}function h(w,S,b){S===void 0&&(S=0),b===void 0&&(b={x:0,y:0});var k=w.x,H=w.y;return{x:(k-b.x)*Math.cos(-S)+(H-b.y)*Math.sin(-S)+b.x,y:(b.x-k)*Math.sin(-S)+(H-b.y)*Math.cos(-S)+b.y}}function v(w){var S=[{x:w.x,y:w.y},{x:w.x+w.width,y:w.y},{x:w.x+w.width,y:w.y+w.height},{x:w.x,y:w.y+w.height}],b=w.rotation;return b?[h(S[0],b,S[0]),h(S[1],b,S[0]),h(S[2],b,S[0]),h(S[3],b,S[0])]:S}function d(w,S){if(w.length>4)return{min:0,max:0};var b=[];return w.forEach(function(k){b.push(u([k.x,k.y],S))}),{min:Math.min.apply(null,b),max:Math.max.apply(null,b)}}function g(w,S){return w.max>S.min&&w.min<S.max}function y(w){return typeof w=="number"&&!Number.isNaN(w)&&w!==Infinity&&w!==-Infinity}function x(w){return["x","y","width","height"].every(function(S){return y(w[S])})}function m(w,S,b){return b===void 0&&(b=0),!(S.x>w.x+w.width+b||S.x+S.width<w.x-b||S.y>w.y+w.height+b||S.y+S.height<w.y-b)}function M(w,S,b){if(b===void 0&&(b=0),!x(w)||!x(S))return!1;if(!w.rotation&&!S.rotation)return m(w,S,b);for(var k=v(w),H=v(S),at=c(k).concat(c(H)),At=0;At<at.length;At++){var gt=at[At],Nt=d(k,gt),te=d(H,gt);if(!g(Nt,te))return!1}return!0}return{intersect:M}}var t=e().intersect;function n(u){for(var c=u.slice(),h=0;h<c.length;h++){var v=c[h];if(v.visible)for(var d=h+1;d<c.length;d++){var g=c[d];v!==g&&g.visible&&t(v,g)&&(g.visible=!1)}}return c}var i={"hide-overlap":n};try{var a=JSON.parse(r.data);if(!a||!a.type||!i[a.type])return;var o=a.type,s=a.items,l=i[o](s);self.postMessage(l)}catch(u){throw u}},HA=`
  53. self.onmessage = `.concat(VA.toString(),`
  54. `),fc=function(r){for(var e=r.slice(),t=0;t<e.length;t++){var n=e[t];if(n.visible)for(var i=t+1;i<e.length;i++){var a=e[i];n!==a&&a.visible&&NA(n,a)&&(a.visible=!1)}}return e},hc=new Map,Kd=zA(HA);function GA(r,e,t,n){return(0,p.mG)(this,void 0,void 0,function(){var i,a,o,s,l,u;return(0,p.Jh)(this,function(c){switch(c.label){case 0:return i=e.map(function(h,v){return(0,p.pi)((0,p.pi)({},Bv(h,r[v],(0,f.U2)(r[v],"background.padding"))),{visible:!0})}),a=JSON.stringify(i),o=function(h){return hc.set(a,h),(0,f.S6)(h,function(v,d){var g=v.visible,y=e[d];g?y==null||y.show():y==null||y.hide()}),h},hc.get(a)?(o(hc.get(a)),[3,7]):[3,1];case 1:if(!Kd)return[3,6];c.label=2;case 2:return c.trys.push([2,4,,5]),s=JSON.stringify({type:"hide-overlap",items:i}),[4,Kd.post(s,function(){return o(fc(i))})];case 3:return l=c.sent(),o(Array.isArray(l.data)?l.data:[]),[3,5];case 4:return u=c.sent(),console.error(u),o(fc(i)),[3,5];case 5:return[3,7];case 6:o(fc(i)),c.label=7;case 7:return[2]}})})}var jd={"#5B8FF9":!0},YA=function(r){var e=nn.toRGB(r).toUpperCase();if(jd[e])return jd[e];var t=(0,p.CR)(nn.rgb2arr(e),3),n=t[0],i=t[1],a=t[2],o=(n*299+i*587+a*114)/1e3<128;return o};function XA(r,e,t){if(t.length!==0){var n=t[0].get("element"),i=n.geometry.theme,a=i.labels||{},o=a.fillColorLight,s=a.fillColorDark;t.forEach(function(l,u){var c=e[u],h=c.find(function(m){return m.get("type")==="text"}),v=Ir.fromObject(l.getBBox()),d=Ir.fromObject(h.getCanvasBBox()),g=!v.contains(d),y=l.attr("fill"),x=YA(y);g?h.attr(i.overflowLabels.style):x?o&&h.attr("fill",o):s&&h.attr("fill",s)})}}function WA(r,e,t){var n=r.coordinate,i=ai(e),a=Ir.fromObject(i.getCanvasBBox()),o=Ir.fromObject(t.getBBox());return n.isTransposed?o.height>=a.height:o.width>=a.width}function ZA(r,e,t){var n=!!r.getAdjust("stack");return n||e.every(function(i,a){var o=t[a];return WA(r,i,o)})}function $A(r,e,t){var n=r.coordinate,i=Ir.fromObject(t.getBBox()),a=ai(e);n.isTransposed?a.attr({x:i.minX+i.width/2,textAlign:"center"}):a.attr({y:i.minY+i.height/2,textBaseline:"middle"})}function qA(r,e,t){var n;if(t.length!==0){var i=(n=t[0])===null||n===void 0?void 0:n.get("element"),a=i==null?void 0:i.geometry;if(!(!a||a.type!=="interval")){var o=ZA(a,e,t);o&&t.forEach(function(s,l){var u=e[l];$A(a,u,s)})}}}function KA(r){var e=500,t=[],n=Math.max(Math.floor(r.length/e),1);return(0,f.S6)(r,function(i,a){a%n==0?t.push(i):i.set("visible",!1)}),t}function jA(r,e,t){var n;if(t.length!==0){var i=(n=t[0])===null||n===void 0?void 0:n.get("element"),a=i==null?void 0:i.geometry;if(!(!a||a.type!=="interval")){var o=KA(e),s=(0,p.CR)(a.getXYFields(),1),l=s[0],u=[],c=[],h=(0,f.vM)(o,function(x){return x.get("data")[l]}),v=(0,f.jj)((0,f.UI)(o,function(x){return x.get("data")[l]})),d;o.forEach(function(x){x.set("visible",!0)});var g=function(x){x&&(x.length&&c.push(x.pop()),c.push.apply(c,(0,p.ev)([],(0,p.CR)(x),!1)))};for((0,f.dp)(v)>0&&(d=v.shift(),g(h[d])),(0,f.dp)(v)>0&&(d=v.pop(),g(h[d])),(0,f.S6)(v.reverse(),function(x){g(h[x])});c.length>0;){var y=c.shift();y.get("visible")&&(Zw(y,u)?y.set("visible",!1):u.push(y))}}}}function JA(r,e){var t=r.getXYFields()[1],n=[],i=e.sort(function(a,o){return a.get("data")[t]-a.get("data")[t]});return i.length>0&&n.push(i.shift()),i.length>0&&n.push(i.pop()),n.push.apply(n,(0,p.ev)([],(0,p.CR)(i),!1)),n}function Jd(r,e,t){return r.some(function(n){return t(n,e)})}function QA(r,e,t){t===void 0&&(t=0);var n=Math.max(0,Math.min(r.x+r.width+t,e.x+e.width+t)-Math.max(r.x-t,e.x-t)),i=Math.max(0,Math.min(r.y+r.height+t,e.y+e.height+t)-Math.max(r.y-t,e.y-t));return n*i}function Qd(r,e){return Jd(r,e,function(t,n){var i=ai(t),a=ai(n);return QA(i.getCanvasBBox(),a.getCanvasBBox(),2)>0})}function tb(r,e,t,n,i){var a,o;if(t.length!==0){var s=(a=t[0])===null||a===void 0?void 0:a.get("element"),l=s==null?void 0:s.geometry;if(!(!l||l.type!=="point")){var u=(0,p.CR)(l.getXYFields(),2),c=u[0],h=u[1],v=(0,f.vM)(e,function(y){return y.get("data")[c]}),d=[],g=i&&i.offset||((o=r[0])===null||o===void 0?void 0:o.offset)||12;(0,f.UI)((0,f.XP)(v).reverse(),function(y){for(var x=JA(l,v[y]);x.length;){var m=x.shift(),M=ai(m);if(Jd(d,m,function(b,k){return b.get("data")[c]===k.get("data")[c]&&b.get("data")[h]===k.get("data")[h]})){M.set("visible",!1);continue}var w=Qd(d,m),S=!1;if(w&&(M.attr("y",M.attr("y")+2*g),S=Qd(d,m)),S){M.set("visible",!1);continue}d.push(m)}})}}}function eb(r,e){var t=r.getXYFields()[1],n=[],i=e.sort(function(a,o){return a.get("data")[t]-a.get("data")[t]});return i.length>0&&n.push(i.shift()),i.length>0&&n.push(i.pop()),n.push.apply(n,(0,p.ev)([],(0,p.CR)(i),!1)),n}function tp(r,e,t){return r.some(function(n){return t(n,e)})}function rb(r,e,t){t===void 0&&(t=0);var n=Math.max(0,Math.min(r.x+r.width+t,e.x+e.width+t)-Math.max(r.x-t,e.x-t)),i=Math.max(0,Math.min(r.y+r.height+t,e.y+e.height+t)-Math.max(r.y-t,e.y-t));return n*i}function ep(r,e){return tp(r,e,function(t,n){var i=ai(t),a=ai(n);return rb(i.getCanvasBBox(),a.getCanvasBBox(),2)>0})}function nb(r,e,t,n,i){var a,o;if(t.length!==0){var s=(a=t[0])===null||a===void 0?void 0:a.get("element"),l=s==null?void 0:s.geometry;if(!(!l||["path","line","area"].indexOf(l.type)<0)){var u=(0,p.CR)(l.getXYFields(),2),c=u[0],h=u[1],v=(0,f.vM)(e,function(y){return y.get("data")[c]}),d=[],g=i&&i.offset||((o=r[0])===null||o===void 0?void 0:o.offset)||12;(0,f.UI)((0,f.XP)(v).reverse(),function(y){for(var x=eb(l,v[y]);x.length;){var m=x.shift(),M=ai(m);if(tp(d,m,function(b,k){return b.get("data")[c]===k.get("data")[c]&&b.get("data")[h]===k.get("data")[h]})){M.set("visible",!1);continue}var w=ep(d,m),S=!1;if(w&&(M.attr("y",M.attr("y")+2*g),S=ep(d,m)),S){M.set("visible",!1);continue}d.push(m)}})}}}var vc;function ib(){return vc||(vc=document.createElement("canvas").getContext("2d")),vc}var Us=(0,f.HP)(function(r,e){e===void 0&&(e={});var t=e.fontSize,n=e.fontFamily,i=e.fontWeight,a=e.fontStyle,o=e.fontVariant,s=ib();return s.font=[a,o,i,"".concat(t,"px"),n].join(" "),s.measureText((0,f.HD)(r)?r:"").width},function(r,e){return e===void 0&&(e={}),(0,p.ev)([r],(0,p.CR)((0,f.VO)(e)),!1).join("")}),ab=function(r,e,t){var n=16,i=Us("...",t),a;(0,f.HD)(r)?a=r:a=(0,f.BB)(r);var o=e,s=[],l,u;if(Us(r,t)<=e)return r;for(;l=a.substr(0,n),u=Us(l,t),!(u+i>o&&u>o);)if(s.push(l),o-=u,a=a.substr(n),!a)return s.join("");for(;l=a.substr(0,1),u=Us(l,t),!(u+i>o);)if(s.push(l),o-=u,a=a.substr(1),!a)return s.join("");return"".concat(s.join(""),"...")};function ob(r,e,t,n,i){if(!(e.length<=0)){var a=(i==null?void 0:i.direction)||["top","right","bottom","left"],o=(i==null?void 0:i.action)||"translate",s=(i==null?void 0:i.margin)||0,l=e[0].get("coordinate");if(!!l){var u=tM(l,s),c=u.minX,h=u.minY,v=u.maxX,d=u.maxY;(0,f.S6)(e,function(g){var y=g.getCanvasBBox(),x=y.minX,m=y.minY,M=y.maxX,w=y.maxY,S=y.x,b=y.y,k=y.width,H=y.height,at=S,At=b;if(a.indexOf("left")>=0&&(x<c||M<c)&&(at=c),a.indexOf("top")>=0&&(m<h||w<h)&&(At=h),a.indexOf("right")>=0&&(x>v?at=v-k:M>v&&(at=at-(M-v))),a.indexOf("bottom")>=0&&(m>d?At=d-H:w>d&&(At=At-(w-d))),at!==S||At!==b){var gt=at-S;if(o==="translate")io(g,gt,At-b);else if(o==="ellipsis"){var Nt=g.findAll(function(te){return te.get("type")==="text"});Nt.forEach(function(te){var ce=(0,f.ei)(te.attr(),["fontSize","fontFamily","fontWeight","fontStyle","fontVariant"]),Me=te.getCanvasBBox(),be=ab(te.attr("text"),Me.width-Math.abs(gt),ce);te.attr("text",be)})}else g.hide()}})}}}function sb(r,e,t){var n={fillOpacity:(0,f.UM)(r.attr("fillOpacity"))?1:r.attr("fillOpacity"),strokeOpacity:(0,f.UM)(r.attr("strokeOpacity"))?1:r.attr("strokeOpacity"),opacity:(0,f.UM)(r.attr("opacity"))?1:r.attr("opacity")};r.attr({fillOpacity:0,strokeOpacity:0,opacity:0}),r.animate(n,e)}function lb(r,e,t){var n={fillOpacity:0,strokeOpacity:0,opacity:0},i=e.easing,a=e.duration,o=e.delay;r.animate(n,a,i,function(){r.remove(!0)},o)}function ub(r,e,t){var n,i=(0,p.CR)(e,2),a=i[0],o=i[1];return r.applyToMatrix([a,o,1]),t==="x"?(r.setMatrix(nr.vs(r.getMatrix(),[["t",-a,-o],["s",.01,1],["t",a,o]])),n=nr.vs(r.getMatrix(),[["t",-a,-o],["s",100,1],["t",a,o]])):t==="y"?(r.setMatrix(nr.vs(r.getMatrix(),[["t",-a,-o],["s",1,.01],["t",a,o]])),n=nr.vs(r.getMatrix(),[["t",-a,-o],["s",1,100],["t",a,o]])):t==="xy"&&(r.setMatrix(nr.vs(r.getMatrix(),[["t",-a,-o],["s",.01,.01],["t",a,o]])),n=nr.vs(r.getMatrix(),[["t",-a,-o],["s",100,100],["t",a,o]])),n}function dc(r,e,t,n,i){var a=t.start,o=t.end,s=t.getWidth(),l=t.getHeight(),u,c;i==="y"?(u=a.x+s/2,c=n.y<a.y?n.y:a.y):i==="x"?(u=n.x>a.x?n.x:a.x,c=a.y+l/2):i==="xy"&&(t.isPolar?(u=t.getCenter().x,c=t.getCenter().y):(u=(a.x+o.x)/2,c=(a.y+o.y)/2));var h=ub(r,[u,c],i);r.animate({matrix:h},e)}function cb(r,e,t){var n=t.coordinate,i=t.minYPoint;dc(r,e,n,i,"x")}function fb(r,e,t){var n=t.coordinate,i=t.minYPoint;dc(r,e,n,i,"y")}function hb(r,e,t){var n=t.coordinate,i=t.minYPoint;dc(r,e,n,i,"xy")}function vb(r,e,t){var n=r.getTotalLength();r.attr("lineDash",[n]),r.animate(function(i){return{lineDashOffset:(1-i)*n}},e)}function db(r,e,t){var n=t.toAttrs,i=n.x,a=n.y;delete n.x,delete n.y,r.attr(n),r.animate({x:i,y:a},e)}function pb(r,e,t){var n=r.getBBox(),i=r.get("origin").mappingData,a=i.points,o=a[0].y-a[1].y>0?n.maxX:n.minX,s=(n.minY+n.maxY)/2;r.applyToMatrix([o,s,1]);var l=nr.vs(r.getMatrix(),[["t",-o,-s],["s",.01,1],["t",o,s]]);r.setMatrix(l),r.animate({matrix:nr.vs(r.getMatrix(),[["t",-o,-s],["s",100,1],["t",o,s]])},e)}function gb(r,e,t){var n=r.getBBox(),i=r.get("origin").mappingData,a=(n.minX+n.maxX)/2,o=i.points,s=o[0].y-o[1].y<=0?n.maxY:n.minY;r.applyToMatrix([a,s,1]);var l=nr.vs(r.getMatrix(),[["t",-a,-s],["s",1,.01],["t",a,s]]);r.setMatrix(l),r.animate({matrix:nr.vs(r.getMatrix(),[["t",-a,-s],["s",1,100],["t",a,s]])},e)}function rp(r,e){var t,n=Es(r,e),i=n.startAngle,a=n.endAngle;return!(0,f.vQ)(i,-Math.PI*.5)&&i<-Math.PI*.5&&(i+=Math.PI*2),!(0,f.vQ)(a,-Math.PI*.5)&&a<-Math.PI*.5&&(a+=Math.PI*2),e[5]===0&&(t=(0,p.CR)([a,i],2),i=t[0],a=t[1]),(0,f.vQ)(i,Math.PI*1.5)&&(i=Math.PI*-.5),(0,f.vQ)(a,Math.PI*-.5)&&!(0,f.vQ)(i,a)&&(a=Math.PI*1.5),{startAngle:i,endAngle:a}}function np(r){var e;return r[0]==="M"||r[0]==="L"?e=[r[1],r[2]]:(r[0]==="a"||r[0]==="A"||r[0]==="C")&&(e=[r[r.length-2],r[r.length-1]]),e}function ip(r){var e,t,n,i=r.filter(function(w){return w[0]==="A"||w[0]==="a"});if(i.length===0)return{startAngle:0,endAngle:0,radius:0,innerRadius:0};var a=i[0],o=i.length>1?i[1]:i[0],s=r.indexOf(a),l=r.indexOf(o),u=np(r[s-1]),c=np(r[l-1]),h=rp(u,a),v=h.startAngle,d=h.endAngle,g=rp(c,o),y=g.startAngle,x=g.endAngle;(0,f.vQ)(v,y)&&(0,f.vQ)(d,x)?(t=v,n=d):(t=Math.min(v,y),n=Math.max(d,x));var m=a[1],M=i[i.length-1][1];return m<M?(e=(0,p.CR)([M,m],2),m=e[0],M=e[1]):m===M&&(M=0),{startAngle:t,endAngle:n,radius:m,innerRadius:M}}function yb(r,e,t){var n=t.toAttrs,i=t.coordinate,a=n.path||[],o=a.map(function(M){return M[0]});if(!(a.length<1)){var s=ip(a),l=s.startAngle,u=s.endAngle,c=s.radius,h=s.innerRadius,v=ip(r.attr("path")),d=v.startAngle,g=v.endAngle,y=i.getCenter(),x=l-d,m=u-g;if(x===0&&m===0){r.attr(n);return}r.animate(function(M){var w=d+M*x,S=g+M*m;return(0,p.pi)((0,p.pi)({},n),{path:(0,f.Xy)(o,["M","A","A","Z"])?Eh(y.x,y.y,c,w,S):Qn(y.x,y.y,c,w,S,h)})},(0,p.pi)((0,p.pi)({},e),{callback:function(){r.attr("path",a),(0,f.mf)(e.callback)&&e.callback()}}))}}function mb(r,e,t){var n=xu(t.coordinate,20),i=n.type,a=n.startState,o=n.endState,s=r.setClip({type:i,attrs:a});t.toAttrs&&r.attr(t.toAttrs),s.animate(o,(0,p.pi)((0,p.pi)({},e),{callback:function(){r&&!r.get("destroyed")&&r.set("clipShape",null),s.remove(!0),(0,f.mf)(e.callback)&&e.callback()}}))}function pc(r,e,t){if(r.isGroup())(0,f.S6)(r.getChildren(),function(s){pc(s,e,t)});else{var n=r.getBBox(),i=(n.minX+n.maxX)/2,a=(n.minY+n.maxY)/2;if(r.applyToMatrix([i,a,1]),t==="zoomIn"){var o=nr.vs(r.getMatrix(),[["t",-i,-a],["s",.01,.01],["t",i,a]]);r.setMatrix(o),r.animate({matrix:nr.vs(r.getMatrix(),[["t",-i,-a],["s",100,100],["t",i,a]])},e)}else r.animate({matrix:nr.vs(r.getMatrix(),[["t",-i,-a],["s",.01,.01],["t",i,a]])},(0,p.pi)((0,p.pi)({},e),{callback:function(){r.remove(!0),(0,f.mf)(e.callback)&&e.callback()}}))}}function xb(r,e,t){pc(r,e,"zoomIn")}function Mb(r,e,t){pc(r,e,"zoomOut")}function Un(r){return[K.TOP,K.BOTTOM].includes(r)?{offsetX:0,offsetY:r===K.TOP?-8:8,style:{textAlign:"center",textBaseline:r===K.TOP?"bottom":"top"}}:[K.LEFT,K.RIGHT].includes(r)?{offsetX:r===K.LEFT?-8:8,offsetY:0,style:{textAlign:r===K.LEFT?"right":"left",textBaseline:"middle",rotate:Math.PI/2}}:{}}function gc(r,e,t){return{x:r.x+e*Math.cos(t),y:r.y+e*Math.sin(t)}}var wb=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){return(0,f.b$)({},r.prototype.getDefaultCfg.call(this),{type:"circle",showTitle:!0,title:r.prototype.getDefaultTitleCfg.call(this)})},e.prototype.render=function(){r.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},e.prototype.getRegion=function(t,n){var i=1/2,a={x:.5,y:.5},o=Math.PI*2/t,s=-1*Math.PI/2+o*n,l=i/(1+1/Math.sin(o/2)),u=gc(a,i-l,s),c=Math.PI*5/4,h=Math.PI*1/4;return{start:gc(u,l,c),end:gc(u,l,h)}},e.prototype.afterEachView=function(t,n){this.processAxis(t,n)},e.prototype.beforeEachView=function(t,n){},e.prototype.generateFacets=function(t){var n=this,i=this.cfg,a=i.fields,o=i.type,s=(0,p.CR)(a,1),l=s[0];if(!l)throw new Error("No `fields` specified!");var u=this.getFieldValues(t,l),c=u.length,h=[];return u.forEach(function(v,d){var g=[{field:l,value:v,values:u}],y=(0,f.hX)(t,n.getFacetDataFilter(g)),x={type:o,data:y,region:n.getRegion(c,d),columnValue:v,columnField:l,columnIndex:d,columnValuesLength:c,rowValue:null,rowField:null,rowIndex:0,rowValuesLength:1};h.push(x)}),h},e.prototype.getXAxisOption=function(t,n,i,a){return i},e.prototype.getYAxisOption=function(t,n,i,a){return i},e.prototype.renderTitle=function(){var t=this;(0,f.S6)(this.facets,function(n){var i=n.columnValue,a=n.view,o=(0,f.U2)(t.cfg.title,"formatter"),s=(0,f.b$)({position:["50%","0%"],content:o?o(i):i},Un(K.TOP),t.cfg.title);a.annotation().text(s)})},e}(aa),Sb=wb,Cb=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){return(0,f.b$)({},r.prototype.getDefaultCfg.call(this),{type:"list",cols:null,showTitle:!0,title:r.prototype.getDefaultTitleCfg.call(this)})},e.prototype.render=function(){r.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},e.prototype.afterEachView=function(t,n){this.processAxis(t,n)},e.prototype.beforeEachView=function(t,n){},e.prototype.generateFacets=function(t){var n=this,i=this.cfg.fields,a=this.cfg.cols,o=(0,p.CR)(i,1),s=o[0];if(!s)throw new Error("No `fields` specified!");var l=this.getFieldValues(t,s),u=l.length;a=a||u;var c=this.getPageCount(u,a),h=[];return l.forEach(function(v,d){var g=n.getRowCol(d,a),y=g.row,x=g.col,m=[{field:s,value:v,values:l}],M=(0,f.hX)(t,n.getFacetDataFilter(m)),w={type:n.cfg.type,data:M,region:n.getRegion(c,a,x,y),columnValue:v,rowValue:v,columnField:s,rowField:null,columnIndex:x,rowIndex:y,columnValuesLength:a,rowValuesLength:c,total:u};h.push(w)}),h},e.prototype.getXAxisOption=function(t,n,i,a){return a.rowIndex!==a.rowValuesLength-1&&a.columnValuesLength*a.rowIndex+a.columnIndex+1+a.columnValuesLength<=a.total?(0,p.pi)((0,p.pi)({},i),{label:null,title:null}):i},e.prototype.getYAxisOption=function(t,n,i,a){return a.columnIndex!==0?(0,p.pi)((0,p.pi)({},i),{title:null,label:null}):i},e.prototype.renderTitle=function(){var t=this;(0,f.S6)(this.facets,function(n){var i=n.columnValue,a=n.view,o=(0,f.U2)(t.cfg.title,"formatter"),s=(0,f.b$)({position:["50%","0%"],content:o?o(i):i},Un(K.TOP),t.cfg.title);a.annotation().text(s)})},e.prototype.getPageCount=function(t,n){return Math.floor((t+n-1)/n)},e.prototype.getRowCol=function(t,n){var i=Math.floor(t/n),a=t%n;return{row:i,col:a}},e}(aa),Ab=Cb,bb=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){return(0,f.b$)({},r.prototype.getDefaultCfg.call(this),{type:"matrix",showTitle:!1,columnTitle:(0,p.pi)({},r.prototype.getDefaultTitleCfg.call(this)),rowTitle:(0,p.pi)({},r.prototype.getDefaultTitleCfg.call(this))})},e.prototype.render=function(){r.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},e.prototype.afterEachView=function(t,n){this.processAxis(t,n)},e.prototype.beforeEachView=function(t,n){},e.prototype.generateFacets=function(t){for(var n=this.cfg,i=n.fields,a=n.type,o=i.length,s=o,l=[],u=0;u<s;u++)for(var c=i[u],h=0;h<o;h++){var v=i[h],d={type:a,data:t,region:this.getRegion(o,s,u,h),columnValue:c,rowValue:v,columnField:c,rowField:v,columnIndex:u,rowIndex:h,columnValuesLength:s,rowValuesLength:o};l.push(d)}return l},e.prototype.getXAxisOption=function(t,n,i,a){return a.rowIndex!==a.rowValuesLength-1?(0,p.pi)((0,p.pi)({},i),{label:null,title:null}):i},e.prototype.getYAxisOption=function(t,n,i,a){return a.columnIndex!==0?(0,p.pi)((0,p.pi)({},i),{title:null,label:null}):i},e.prototype.renderTitle=function(){var t=this;(0,f.S6)(this.facets,function(n,i){var a=n.columnIndex,o=n.rowIndex,s=n.columnValuesLength,l=n.rowValuesLength,u=n.columnValue,c=n.rowValue,h=n.view;if(o===0){var v=(0,f.U2)(t.cfg.columnTitle,"formatter"),d=(0,f.b$)({position:["50%","0%"],content:v?v(u):u},Un(K.TOP),t.cfg.columnTitle);h.annotation().text(d)}if(a===s-1){var v=(0,f.U2)(t.cfg.rowTitle,"formatter"),d=(0,f.b$)({position:["100%","50%"],content:v?v(c):c},Un(K.RIGHT),t.cfg.rowTitle);h.annotation().text(d)}})},e}(aa),Tb=bb,Eb=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getDefaultCfg=function(){return(0,f.b$)({},r.prototype.getDefaultCfg.call(this),{type:"mirror",showTitle:!0,title:r.prototype.getDefaultTitleCfg.call(this),transpose:!1})},e.prototype.render=function(){r.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},e.prototype.beforeEachView=function(t,n){this.cfg.transpose?n.columnIndex%2==0?t.coordinate().transpose().reflect("x"):t.coordinate().transpose():n.rowIndex%2!=0&&t.coordinate().reflect("y")},e.prototype.afterEachView=function(t,n){this.processAxis(t,n)},e.prototype.generateFacets=function(t){var n=this,i=(0,p.CR)(this.cfg.fields,1),a=i[0],o=[],s=1,l=1,u=[""],c=[""],h,v;return this.cfg.transpose?(h=a,u=this.getFieldValues(t,h).slice(0,2),s=u.length):(v=a,c=this.getFieldValues(t,v).slice(0,2),l=c.length),u.forEach(function(d,g){c.forEach(function(y,x){var m=[{field:h,value:d,values:u},{field:v,value:y,values:c}],M=(0,f.hX)(t,n.getFacetDataFilter(m)),w={type:n.cfg.type,data:M,region:n.getRegion(l,s,g,x),columnValue:d,rowValue:y,columnField:h,rowField:v,columnIndex:g,rowIndex:x,columnValuesLength:s,rowValuesLength:l};o.push(w)})}),o},e.prototype.getXAxisOption=function(t,n,i,a){return a.columnIndex===1||a.rowIndex===1?(0,p.pi)((0,p.pi)({},i),{label:null,title:null}):i},e.prototype.getYAxisOption=function(t,n,i,a){return i},e.prototype.renderTitle=function(){var t=this;(0,f.S6)(this.facets,function(n,i){var a=n.columnValue,o=n.rowValue,s=n.view,l=(0,f.U2)(t.cfg.title,"formatter");if(t.cfg.transpose){var u=(0,f.b$)({position:["50%","0%"],content:l?l(a):a},Un(K.TOP),t.cfg.title);s.annotation().text(u)}else{var u=(0,f.b$)({position:["100%","50%"],content:l?l(o):o},Un(K.RIGHT),t.cfg.title);s.annotation().text(u)}})},e}(aa),_b=Eb,Fb=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.afterEachView=function(t,n){this.processAxis(t,n)},e.prototype.beforeEachView=function(t,n){},e.prototype.getDefaultCfg=function(){return(0,f.b$)({},r.prototype.getDefaultCfg.call(this),{type:"rect",columnTitle:(0,p.pi)({},r.prototype.getDefaultTitleCfg.call(this)),rowTitle:(0,p.pi)({},r.prototype.getDefaultTitleCfg.call(this))})},e.prototype.render=function(){r.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},e.prototype.generateFacets=function(t){var n=this,i=(0,p.CR)(this.cfg.fields,2),a=i[0],o=i[1],s=[],l=1,u=1,c=[""],h=[""];return a&&(c=this.getFieldValues(t,a),l=c.length),o&&(h=this.getFieldValues(t,o),u=h.length),c.forEach(function(v,d){h.forEach(function(g,y){var x=[{field:a,value:v,values:c},{field:o,value:g,values:h}],m=(0,f.hX)(t,n.getFacetDataFilter(x)),M={type:n.cfg.type,data:m,region:n.getRegion(u,l,d,y),columnValue:v,rowValue:g,columnField:a,rowField:o,columnIndex:d,rowIndex:y,columnValuesLength:l,rowValuesLength:u};s.push(M)})}),s},e.prototype.renderTitle=function(){var t=this;(0,f.S6)(this.facets,function(n,i){var a=n.columnIndex,o=n.rowIndex,s=n.columnValuesLength,l=n.columnValue,u=n.rowValue,c=n.view;if(o===0){var h=(0,f.U2)(t.cfg.columnTitle,"formatter"),v=(0,f.b$)({position:["50%","0%"],content:h?h(l):l},Un(K.TOP),t.cfg.columnTitle);c.annotation().text(v)}if(a===s-1){var h=(0,f.U2)(t.cfg.rowTitle,"formatter"),v=(0,f.b$)({position:["100%","50%"],content:h?h(u):u},Un(K.RIGHT),t.cfg.rowTitle);c.annotation().text(v)}})},e.prototype.getXAxisOption=function(t,n,i,a){return a.rowIndex!==a.rowValuesLength-1?(0,p.pi)((0,p.pi)({},i),{title:null,label:null}):a.columnIndex!==Math.floor((a.columnValuesLength-1)/2)?(0,p.pi)((0,p.pi)({},i),{title:null}):i},e.prototype.getYAxisOption=function(t,n,i,a){return a.columnIndex!==0?(0,p.pi)((0,p.pi)({},i),{title:null,label:null}):a.rowIndex!==Math.floor((a.rowValuesLength-1)/2)?(0,p.pi)((0,p.pi)({},i),{title:null}):i},e}(aa),Ib=Fb,Pb=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.afterChartRender=function(){t.facets&&t.cfg.line&&(t.container.clear(),t.drawLines(t.facets))},t}return e.prototype.afterEachView=function(t,n){this.processAxis(t,n)},e.prototype.beforeEachView=function(t,n){},e.prototype.init=function(){r.prototype.init.call(this),this.view.on(X.AFTER_RENDER,this.afterChartRender)},e.prototype.getDefaultCfg=function(){return(0,f.b$)({},r.prototype.getDefaultCfg.call(this),{type:"tree",line:{style:{lineWidth:1,stroke:"#ddd"},smooth:!1},showTitle:!0,title:r.prototype.getDefaultTitleCfg.call(this)})},e.prototype.generateFacets=function(t){var n=this.cfg.fields;if(!n.length)throw new Error("Please specify for the fields for rootFacet!");var i=[],a={type:this.cfg.type,data:t,region:null,rowValuesLength:this.getRows(),columnValuesLength:1,rowIndex:0,columnIndex:0,rowField:"",columnField:"",rowValue:"",columnValue:""};return i.push(a),a.children=this.getChildFacets(t,1,i),this.setRegion(i),i},e.prototype.setRegion=function(t){var n=this;this.forceColIndex(t),t.forEach(function(i){i.region=n.getRegion(i.rowValuesLength,i.columnValuesLength,i.columnIndex,i.rowIndex)})},e.prototype.getRegion=function(t,n,i,a){var o=1/n,s=1/t,l={x:o*i,y:s*a},u={x:l.x+o,y:l.y+s*2/3};return{start:l,end:u}},e.prototype.forceColIndex=function(t){var n,i,a=this,o=[],s=0;t.forEach(function(g){a.isLeaf(g)&&(o.push(g),g.columnIndex=s,s++)}),o.forEach(function(g){g.columnValuesLength=o.length});for(var l=this.cfg.fields.length,u=l-1;u>=0;u--){var c=this.getFacetsByLevel(t,u);try{for(var h=(n=void 0,(0,p.XA)(c)),v=h.next();!v.done;v=h.next()){var d=v.value;this.isLeaf(d)||(d.originColIndex=d.columnIndex,d.columnIndex=this.getRegionIndex(d.children),d.columnValuesLength=o.length)}}catch(g){n={error:g}}finally{try{v&&!v.done&&(i=h.return)&&i.call(h)}finally{if(n)throw n.error}}}},e.prototype.getFacetsByLevel=function(t,n){var i=[];return t.forEach(function(a){a.rowIndex===n&&i.push(a)}),i},e.prototype.getRegionIndex=function(t){var n=t[0],i=t[t.length-1];return(i.columnIndex-n.columnIndex)/2+n.columnIndex},e.prototype.isLeaf=function(t){return!t.children||!t.children.length},e.prototype.getRows=function(){return this.cfg.fields.length+1},e.prototype.getChildFacets=function(t,n,i){var a=this,o=this.cfg.fields,s=o.length;if(!(s<n)){var l=[],u=o[n-1],c=this.getFieldValues(t,u);return c.forEach(function(h,v){var d=[{field:u,value:h,values:c}],g=t.filter(a.getFacetDataFilter(d));if(g.length){var y={type:a.cfg.type,data:g,region:null,columnValue:h,rowValue:"",columnField:u,rowField:"",columnIndex:v,rowValuesLength:a.getRows(),columnValuesLength:1,rowIndex:n,children:a.getChildFacets(g,n+1,i)};l.push(y),i.push(y)}}),l}},e.prototype.render=function(){r.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},e.prototype.renderTitle=function(){var t=this;(0,f.S6)(this.facets,function(n){var i=n.columnValue,a=n.view,o=(0,f.U2)(t.cfg.title,"formatter"),s=(0,f.b$)({position:["50%","0%"],content:o?o(i):i},Un(K.TOP),t.cfg.title);a.annotation().text(s)})},e.prototype.drawLines=function(t){var n=this;t.forEach(function(i){if(!n.isLeaf(i)){var a=i.children;n.addFacetLines(i,a)}})},e.prototype.addFacetLines=function(t,n){var i=this,a=t.view,o=a.coordinateBBox,s={x:o.x+o.width/2,y:o.y+o.height};n.forEach(function(l){var u=l.view.coordinateBBox,c={x:u.bl.x+(u.tr.x-u.bl.x)/2,y:u.tr.y},h={x:s.x,y:s.y+(c.y-s.y)/2},v={x:c.x,y:h.y};i.drawLine([s,h,v,c])})},e.prototype.getPath=function(t){var n=[],i=this.cfg.line.smooth;return i?(n.push(["M",t[0].x,t[0].y]),n.push(["C",t[1].x,t[1].y,t[2].x,t[2].y,t[3].x,t[3].y])):t.forEach(function(a,o){o===0?n.push(["M",a.x,a.y]):n.push(["L",a.x,a.y])}),n},e.prototype.drawLine=function(t){var n=this.getPath(t),i=this.cfg.line.style;this.container.addShape("path",{attrs:(0,f.f0)({path:n},i)})},e.prototype.getXAxisOption=function(t,n,i,a){return a.rowIndex!==a.rowValuesLength-1?(0,p.pi)((0,p.pi)({},i),{title:null,label:null}):i},e.prototype.getYAxisOption=function(t,n,i,a){return a.originColIndex!==0&&a.columnIndex!==0?(0,p.pi)((0,p.pi)({},i),{title:null,label:null}):i},e}(aa),Lb=Pb;function ap(r){var e=(0,p.ev)([],(0,p.CR)(r),!1);e.sort(function(n,i){return n-i});var t=e.length;return t===0?0:t%2==1?e[(t-1)/2]:(e[t/2]+e[t/2-1])/2}function Db(r){var e=(0,f.u4)(r,function(t,n){return t+=isNaN(n)||!(0,f.hj)(n)?0:n},0);return r.length===0?0:e/r.length}function zs(r,e){if(!e)return null;var t;switch(r){case"start":return 0;case"center":return .5;case"end":return 1;case"median":{t=e.isCategory?ap(e.values.map(function(n,i){return i})):ap(e.values);break}case"mean":{t=e.isCategory?(e.values.length-1)/2:Db(e.values);break}case"min":t=e.isCategory?0:e[r];break;case"max":t=e.isCategory?e.values.length-1:e[r];break;default:t=r;break}return e.scale(t)}var Vs=["regionFilter","shape"],Ob=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.cache=new Map,n.foregroundContainer=n.view.getLayer(J.FORE).addGroup(),n.backgroundContainer=n.view.getLayer(J.BG).addGroup(),n.option=[],n}return Object.defineProperty(e.prototype,"name",{get:function(){return"annotation"},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.layout=function(){this.update()},e.prototype.render=function(){},e.prototype.update=function(){var t=this;this.onAfterRender(function(){var i=new Map;(0,f.S6)(t.option,function(a){if((0,f.q9)(Vs,a.type)){var o=t.updateOrCreate(a);o&&i.set(t.getCacheKey(a),o)}}),t.cache=t.syncCache(i)});var n=new Map;(0,f.S6)(this.option,function(i){if(!(0,f.q9)(Vs,i.type)){var a=t.updateOrCreate(i);a&&n.set(t.getCacheKey(i),a)}}),this.cache=this.syncCache(n)},e.prototype.clear=function(t){t===void 0&&(t=!1),r.prototype.clear.call(this),this.clearComponents(),this.foregroundContainer.clear(),this.backgroundContainer.clear(),t&&(this.option=[])},e.prototype.destroy=function(){this.clear(!0),this.foregroundContainer.remove(!0),this.backgroundContainer.remove(!0)},e.prototype.getComponents=function(){var t=[];return this.cache.forEach(function(n){t.push(n)}),t},e.prototype.clearComponents=function(){this.getComponents().forEach(function(t){t.component.destroy()}),this.cache.clear()},e.prototype.onAfterRender=function(t){var n=!1;this.view.getOptions().animate&&this.view.geometries.forEach(function(i){i.animateOption&&(i.once(st.AFTER_DRAW_ANIMATE,function(){t()}),n=!0)}),n||this.view.getRootView().once(X.AFTER_RENDER,function(){t()})},e.prototype.createAnnotation=function(t){var n=t.type,i=ot[(0,f.jC)(n)];if(i){var a=this.getAnnotationTheme(n),o=this.getAnnotationCfg(n,t,a);if(!o)return null;var s=new i(o);return{component:s,layer:this.isTop(o)?J.FORE:J.BG,direction:K.NONE,type:ht.ANNOTATION,extra:t}}},e.prototype.annotation=function(t){this.option.push(t)},e.prototype.arc=function(t){return this.annotation((0,p.pi)({type:"arc"},t)),this},e.prototype.image=function(t){return this.annotation((0,p.pi)({type:"image"},t)),this},e.prototype.line=function(t){return this.annotation((0,p.pi)({type:"line"},t)),this},e.prototype.region=function(t){return this.annotation((0,p.pi)({type:"region"},t)),this},e.prototype.text=function(t){return this.annotation((0,p.pi)({type:"text"},t)),this},e.prototype.dataMarker=function(t){return this.annotation((0,p.pi)({type:"dataMarker"},t)),this},e.prototype.dataRegion=function(t){this.annotation((0,p.pi)({type:"dataRegion"},t))},e.prototype.regionFilter=function(t){this.annotation((0,p.pi)({type:"regionFilter"},t))},e.prototype.shape=function(t){this.annotation((0,p.pi)({type:"shape"},t))},e.prototype.html=function(t){this.annotation((0,p.pi)({type:"html"},t))},e.prototype.parsePosition=function(t){var n,i,a=this.view.getXScale(),o=this.view.getScalesByDim("y"),s=(0,f.mf)(t)?t.call(null,a,o):t,l=0,u=0;if((0,f.kJ)(s)){var c=(0,p.CR)(s,2),h=c[0],v=c[1];if((0,f.HD)(h)&&h.indexOf("%")!==-1&&!isNaN(h.slice(0,-1)))return this.parsePercentPosition(s);l=zs(h,a),u=zs(v,Object.values(o)[0])}else if(!(0,f.UM)(s))try{for(var d=(0,p.XA)((0,f.XP)(s)),g=d.next();!g.done;g=d.next()){var y=g.value,x=s[y];y===a.field&&(l=zs(x,a)),o[y]&&(u=zs(x,o[y]))}}catch(m){n={error:m}}finally{try{g&&!g.done&&(i=d.return)&&i.call(d)}finally{if(n)throw n.error}}return isNaN(l)||isNaN(u)?null:this.view.getCoordinate().convert({x:l,y:u})},e.prototype.getRegionPoints=function(t,n){var i=this,a=this.view.getXScale(),o=this.view.getScalesByDim("y"),s=Object.values(o)[0],l=a.field,u=this.view.getData(),c=(0,f.kJ)(t)?t[0]:t[l],h=(0,f.kJ)(n)?n[0]:n[l],v=[],d;return(0,f.S6)(u,function(g,y){if(g[l]===c&&(d=y),y>=d){var x=i.parsePosition([g[l],g[s.field]]);x&&v.push(x)}if(g[l]===h)return!1}),v},e.prototype.parsePercentPosition=function(t){var n=parseFloat(t[0])/100,i=parseFloat(t[1])/100,a=this.view.getCoordinate(),o=a.start,s=a.end,l={x:Math.min(o.x,s.x),y:Math.min(o.y,s.y)},u=a.getWidth()*n+l.x,c=a.getHeight()*i+l.y;return{x:u,y:c}},e.prototype.getCoordinateBBox=function(){var t=this.view.getCoordinate(),n=t.start,i=t.end,a=t.getWidth(),o=t.getHeight(),s={x:Math.min(n.x,i.x),y:Math.min(n.y,i.y)};return{x:s.x,y:s.y,minX:s.x,minY:s.y,maxX:s.x+a,maxY:s.y+o,width:a,height:o}},e.prototype.getAnnotationCfg=function(t,n,i){var a=this,o=this.view.getCoordinate(),s=this.view.getCanvas(),l={};if((0,f.UM)(n))return null;var u=n.start,c=n.end,h=n.position,v=this.parsePosition(u),d=this.parsePosition(c),g=this.parsePosition(h);if(["arc","image","line","region","regionFilter"].includes(t)&&(!v||!d))return null;if(["text","dataMarker","html"].includes(t)&&!g)return null;if(t==="arc"){var y=n,x=y.start,m=y.end,M=(0,p._T)(y,["start","end"]),w=ia(o,v),S=ia(o,d);w>S&&(S=Math.PI*2+S),l=(0,p.pi)((0,p.pi)({},M),{center:o.getCenter(),radius:cs(o,v),startAngle:w,endAngle:S})}else if(t==="image"){var b=n,k=b.start,H=b.end,M=(0,p._T)(b,["start","end"]);l=(0,p.pi)((0,p.pi)({},M),{start:v,end:d,src:n.src})}else if(t==="line"){var at=n,At=at.start,gt=at.end,M=(0,p._T)(at,["start","end"]);l=(0,p.pi)((0,p.pi)({},M),{start:v,end:d,text:(0,f.U2)(n,"text",null)})}else if(t==="region"){var Nt=n,te=Nt.start,ce=Nt.end,M=(0,p._T)(Nt,["start","end"]);l=(0,p.pi)((0,p.pi)({},M),{start:v,end:d})}else if(t==="text"){var Me=this.view.getData(),be=n,Gt=be.position,ie=be.content,M=(0,p._T)(be,["position","content"]),de=ie;(0,f.mf)(ie)&&(de=ie(Me)),l=(0,p.pi)((0,p.pi)((0,p.pi)({},g),M),{content:de})}else if(t==="dataMarker"){var ue=n,pe=ue.position,Ee=ue.point,Ne=ue.line,Ye=ue.text,Ue=ue.autoAdjust,Xe=ue.direction,M=(0,p._T)(ue,["position","point","line","text","autoAdjust","direction"]);l=(0,p.pi)((0,p.pi)((0,p.pi)({},M),g),{coordinateBBox:this.getCoordinateBBox(),point:Ee,line:Ne,text:Ye,autoAdjust:Ue,direction:Xe})}else if(t==="dataRegion"){var er=n,vr=er.start,dr=er.end,Ln=er.region,Ye=er.text,Xi=er.lineLength,M=(0,p._T)(er,["start","end","region","text","lineLength"]);l=(0,p.pi)((0,p.pi)({},M),{points:this.getRegionPoints(vr,dr),region:Ln,text:Ye,lineLength:Xi})}else if(t==="regionFilter"){var $n=n,Ta=$n.start,Ea=$n.end,Uy=$n.apply,uR=$n.color,M=(0,p._T)($n,["start","end","apply","color"]),cR=this.view.geometries,zy=[],If=function(Dn){!Dn||(Dn.isGroup()?Dn.getChildren().forEach(function(ko){return If(ko)}):zy.push(Dn))};(0,f.S6)(cR,function(Dn){Uy?(0,f.FX)(Uy,Dn.type)&&(0,f.S6)(Dn.elements,function(ko){If(ko.shape)}):(0,f.S6)(Dn.elements,function(ko){If(ko.shape)})}),l=(0,p.pi)((0,p.pi)({},M),{color:uR,shapes:zy,start:v,end:d})}else if(t==="shape"){var Vy=n,fR=Vy.render,Pf=(0,p._T)(Vy,["render"]),hR=function(dR){if((0,f.mf)(n.render))return fR(dR,a.view,{parsePosition:a.parsePosition.bind(a)})};l=(0,p.pi)((0,p.pi)({},Pf),{render:hR})}else if(t==="html"){var Lf=n,Df=Lf.html,W5=Lf.position,Pf=(0,p._T)(Lf,["html","position"]),vR=function(Dn){return(0,f.mf)(Df)?Df(Dn,a.view):Df};l=(0,p.pi)((0,p.pi)((0,p.pi)({},Pf),g),{parent:s.get("el").parentNode,html:vR})}var gi=(0,f.b$)({},i,(0,p.pi)((0,p.pi)({},l),{top:n.top,style:n.style,offsetX:n.offsetX,offsetY:n.offsetY}));return t!=="html"&&(gi.container=this.getComponentContainer(gi)),gi.animate=this.view.getOptions().animate&&gi.animate&&(0,f.U2)(n,"animate",gi.animate),gi.animateOption=(0,f.b$)({},ca,gi.animateOption,n.animateOption),gi},e.prototype.isTop=function(t){return(0,f.U2)(t,"top",!0)},e.prototype.getComponentContainer=function(t){return this.isTop(t)?this.foregroundContainer:this.backgroundContainer},e.prototype.getAnnotationTheme=function(t){return(0,f.U2)(this.view.getTheme(),["components","annotation",t],{})},e.prototype.updateOrCreate=function(t){var n=this.cache.get(this.getCacheKey(t));if(n){var i=t.type,a=this.getAnnotationTheme(i),o=this.getAnnotationCfg(i,t,a);o&&Nr(o,["container"]),n.component.update((0,p.pi)((0,p.pi)({},o||{}),{visible:!!o})),(0,f.q9)(Vs,t.type)&&n.component.render()}else n=this.createAnnotation(t),n&&(n.component.init(),(0,f.q9)(Vs,t.type)&&n.component.render());return n},e.prototype.syncCache=function(t){var n=this,i=new Map(this.cache);return t.forEach(function(a,o){i.set(o,a)}),i.forEach(function(a,o){(0,f.sE)(n.option,function(s){return o===n.getCacheKey(s)})||(a.component.destroy(),i.delete(o))}),i},e.prototype.getCacheKey=function(t){return t},e}(ua),kb=Ob;function op(r,e){var t=(0,f.b$)({},(0,f.U2)(r,["components","axis","common"]),(0,f.U2)(r,["components","axis",e]));return(0,f.U2)(t,["grid"],{})}function Hs(r,e,t,n){var i=[],a=e.getTicks();return r.isPolar&&a.push({value:1,text:"",tickValue:""}),a.reduce(function(o,s,l){var u=s.value;if(n)i.push({points:[r.convert(t==="y"?{x:0,y:u}:{x:u,y:0}),r.convert(t==="y"?{x:1,y:u}:{x:u,y:1})]});else if(l){var c=o.value,h=(c+u)/2;i.push({points:[r.convert(t==="y"?{x:0,y:h}:{x:h,y:0}),r.convert(t==="y"?{x:1,y:h}:{x:h,y:1})]})}return s},a[0]),i}function yc(r,e,t,n,i){var a=e.values.length,o=[],s=t.getTicks();return s.reduce(function(l,u){var c=l?l.value:u.value,h=u.value,v=(c+h)/2;return i==="x"?o.push({points:[r.convert({x:n?h:v,y:0}),r.convert({x:n?h:v,y:1})]}):o.push({points:(0,f.UI)(Array(a+1),function(d,g){return r.convert({x:g/a,y:n?h:v})})}),u},s[0]),o}function sp(r,e){var t=(0,f.U2)(e,"grid");if(t===null)return!1;var n=(0,f.U2)(r,"grid");return!(t===void 0&&n===null)}var ui=["container"],lp=(0,p.pi)((0,p.pi)({},ca),{appear:null}),Bb=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.cache=new Map,n.gridContainer=n.view.getLayer(J.BG).addGroup(),n.gridForeContainer=n.view.getLayer(J.FORE).addGroup(),n.axisContainer=n.view.getLayer(J.BG).addGroup(),n.axisForeContainer=n.view.getLayer(J.FORE).addGroup(),n}return Object.defineProperty(e.prototype,"name",{get:function(){return"axis"},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.render=function(){this.update()},e.prototype.layout=function(){var t=this,n=this.view.getCoordinate();(0,f.S6)(this.getComponents(),function(i){var a=i.component,o=i.direction,s=i.type,l=i.extra,u=l.dim,c=l.scale,h=l.alignTick,v;if(s===ht.AXIS)n.isPolar?u==="x"?v=n.isTransposed?fs(n,o):Mu(n):u==="y"&&(v=n.isTransposed?Mu(n):fs(n,o)):v=fs(n,o);else if(s===ht.GRID)if(n.isPolar){var d=void 0;n.isTransposed?d=u==="x"?yc(n,t.view.getYScales()[0],c,h,u):Hs(n,c,u,h):d=u==="x"?Hs(n,c,u,h):yc(n,t.view.getXScale(),c,h,u),v={items:d,center:t.view.getCoordinate().getCenter()}}else v={items:Hs(n,c,u,h)};a.update(v)})},e.prototype.update=function(){this.option=this.view.getOptions().axes;var t=new Map;this.updateXAxes(t),this.updateYAxes(t);var n=new Map;this.cache.forEach(function(i,a){t.has(a)?n.set(a,i):i.component.destroy()}),this.cache=n},e.prototype.clear=function(){r.prototype.clear.call(this),this.cache.clear(),this.gridContainer.clear(),this.gridForeContainer.clear(),this.axisContainer.clear(),this.axisForeContainer.clear()},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.gridContainer.remove(!0),this.gridForeContainer.remove(!0),this.axisContainer.remove(!0),this.axisForeContainer.remove(!0)},e.prototype.getComponents=function(){var t=[];return this.cache.forEach(function(n){t.push(n)}),t},e.prototype.updateXAxes=function(t){var n=this.view.getXScale();if(!(!n||n.isIdentity)){var i=vs(this.option,n.field);if(i!==!1){var a=Oh(i,K.BOTTOM),o=J.BG,s="x",l=this.view.getCoordinate(),u=this.getId("axis",n.field),c=this.getId("grid",n.field);if(l.isRect){var h=this.cache.get(u);if(h){var v=this.getLineAxisCfg(n,i,a);Nr(v,ui),h.component.update(v),t.set(u,h)}else h=this.createLineAxis(n,i,o,a,s),this.cache.set(u,h),t.set(u,h);var d=this.cache.get(c);if(d){var v=this.getLineGridCfg(n,i,a,s);Nr(v,ui),d.component.update(v),t.set(c,d)}else d=this.createLineGrid(n,i,o,a,s),d&&(this.cache.set(c,d),t.set(c,d))}else if(l.isPolar){var h=this.cache.get(u);if(h){var v=l.isTransposed?this.getLineAxisCfg(n,i,K.RADIUS):this.getCircleAxisCfg(n,i,a);Nr(v,ui),h.component.update(v),t.set(u,h)}else{if(l.isTransposed){if((0,f.o8)(i))return;h=this.createLineAxis(n,i,o,K.RADIUS,s)}else h=this.createCircleAxis(n,i,o,a,s);this.cache.set(u,h),t.set(u,h)}var d=this.cache.get(c);if(d){var v=l.isTransposed?this.getCircleGridCfg(n,i,K.RADIUS,s):this.getLineGridCfg(n,i,K.CIRCLE,s);Nr(v,ui),d.component.update(v),t.set(c,d)}else{if(l.isTransposed){if((0,f.o8)(i))return;d=this.createCircleGrid(n,i,o,K.RADIUS,s)}else d=this.createLineGrid(n,i,o,K.CIRCLE,s);d&&(this.cache.set(c,d),t.set(c,d))}}}}},e.prototype.updateYAxes=function(t){var n=this,i=this.view.getYScales();(0,f.S6)(i,function(a,o){if(!(!a||a.isIdentity)){var s=a.field,l=vs(n.option,s);if(l!==!1){var u=J.BG,c="y",h=n.getId("axis",s),v=n.getId("grid",s),d=n.view.getCoordinate();if(d.isRect){var g=Oh(l,o===0?K.LEFT:K.RIGHT),y=n.cache.get(h);if(y){var x=n.getLineAxisCfg(a,l,g);Nr(x,ui),y.component.update(x),t.set(h,y)}else y=n.createLineAxis(a,l,u,g,c),n.cache.set(h,y),t.set(h,y);var m=n.cache.get(v);if(m){var x=n.getLineGridCfg(a,l,g,c);Nr(x,ui),m.component.update(x),t.set(v,m)}else m=n.createLineGrid(a,l,u,g,c),m&&(n.cache.set(v,m),t.set(v,m))}else if(d.isPolar){var y=n.cache.get(h);if(y){var x=d.isTransposed?n.getCircleAxisCfg(a,l,K.CIRCLE):n.getLineAxisCfg(a,l,K.RADIUS);Nr(x,ui),y.component.update(x),t.set(h,y)}else{if(d.isTransposed){if((0,f.o8)(l))return;y=n.createCircleAxis(a,l,u,K.CIRCLE,c)}else y=n.createLineAxis(a,l,u,K.RADIUS,c);n.cache.set(h,y),t.set(h,y)}var m=n.cache.get(v);if(m){var x=d.isTransposed?n.getLineGridCfg(a,l,K.CIRCLE,c):n.getCircleGridCfg(a,l,K.RADIUS,c);Nr(x,ui),m.component.update(x),t.set(v,m)}else{if(d.isTransposed){if((0,f.o8)(l))return;m=n.createLineGrid(a,l,u,K.CIRCLE,c)}else m=n.createCircleGrid(a,l,u,K.RADIUS,c);m&&(n.cache.set(v,m),t.set(v,m))}}}}})},e.prototype.createLineAxis=function(t,n,i,a,o){var s={component:new G1(this.getLineAxisCfg(t,n,a)),layer:i,direction:a===K.RADIUS?K.NONE:a,type:ht.AXIS,extra:{dim:o,scale:t}};return s.component.set("field",t.field),s.component.init(),s},e.prototype.createLineGrid=function(t,n,i,a,o){var s=this.getLineGridCfg(t,n,a,o);if(s){var l={component:new X1(s),layer:i,direction:K.NONE,type:ht.GRID,extra:{dim:o,scale:t,alignTick:(0,f.U2)(s,"alignTick",!0)}};return l.component.init(),l}},e.prototype.createCircleAxis=function(t,n,i,a,o){var s={component:new Y1(this.getCircleAxisCfg(t,n,a)),layer:i,direction:a,type:ht.AXIS,extra:{dim:o,scale:t}};return s.component.set("field",t.field),s.component.init(),s},e.prototype.createCircleGrid=function(t,n,i,a,o){var s=this.getCircleGridCfg(t,n,a,o);if(s){var l={component:new W1(s),layer:i,direction:K.NONE,type:ht.GRID,extra:{dim:o,scale:t,alignTick:(0,f.U2)(s,"alignTick",!0)}};return l.component.init(),l}},e.prototype.getLineAxisCfg=function(t,n,i){var a=(0,f.U2)(n,["top"])?this.axisForeContainer:this.axisContainer,o=this.view.getCoordinate(),s=fs(o,i),l=kh(t,n),u=hs(this.view.getTheme(),i),c=(0,f.U2)(n,["title"])?(0,f.b$)({title:{style:{text:l}}},{title:Dh(this.view.getTheme(),i,n.title)},n):n,h=(0,f.b$)((0,p.pi)((0,p.pi)({container:a},s),{ticks:t.getTicks().map(function(w){return{id:"".concat(w.tickValue),name:w.text,value:w.value}}),verticalFactor:o.isPolar?Lh(s,o.getCenter())*-1:Lh(s,o.getCenter()),theme:u}),u,c),v=this.getAnimateCfg(h),d=v.animate,g=v.animateOption;h.animateOption=g,h.animate=d;var y=Ph(s),x=(0,f.U2)(h,"verticalLimitLength",y?1/3:1/2);if(x<=1){var m=this.view.getCanvas().get("width"),M=this.view.getCanvas().get("height");h.verticalLimitLength=x*(y?m:M)}return h},e.prototype.getLineGridCfg=function(t,n,i,a){if(!!sp(hs(this.view.getTheme(),i),n)){var o=op(this.view.getTheme(),i),s=(0,f.b$)({container:(0,f.U2)(n,["top"])?this.gridForeContainer:this.gridContainer},o,(0,f.U2)(n,"grid"),this.getAnimateCfg(n));return s.items=Hs(this.view.getCoordinate(),t,a,(0,f.U2)(s,"alignTick",!0)),s}},e.prototype.getCircleAxisCfg=function(t,n,i){var a=(0,f.U2)(n,["top"])?this.axisForeContainer:this.axisContainer,o=this.view.getCoordinate(),s=t.getTicks().map(function(y){return{id:"".concat(y.tickValue),name:y.text,value:y.value}});!t.isCategory&&Math.abs(o.endAngle-o.startAngle)===Math.PI*2&&s.length&&(s[s.length-1].name="");var l=kh(t,n),u=hs(this.view.getTheme(),K.CIRCLE),c=(0,f.U2)(n,["title"])?(0,f.b$)({title:{style:{text:l}}},{title:Dh(this.view.getTheme(),i,n.title)},n):n,h=(0,f.b$)((0,p.pi)((0,p.pi)({container:a},Mu(this.view.getCoordinate())),{ticks:s,verticalFactor:1,theme:u}),u,c),v=this.getAnimateCfg(h),d=v.animate,g=v.animateOption;return h.animate=d,h.animateOption=g,h},e.prototype.getCircleGridCfg=function(t,n,i,a){if(!!sp(hs(this.view.getTheme(),i),n)){var o=op(this.view.getTheme(),K.RADIUS),s=(0,f.b$)({container:(0,f.U2)(n,["top"])?this.gridForeContainer:this.gridContainer,center:this.view.getCoordinate().getCenter()},o,(0,f.U2)(n,"grid"),this.getAnimateCfg(n)),l=(0,f.U2)(s,"alignTick",!0),u=a==="x"?this.view.getYScales()[0]:this.view.getXScale();return s.items=yc(this.view.getCoordinate(),u,t,l,a),s}},e.prototype.getId=function(t,n){var i=this.view.getCoordinate();return"".concat(t,"-").concat(n,"-").concat(i.type)},e.prototype.getAnimateCfg=function(t){return{animate:this.view.getOptions().animate&&(0,f.U2)(t,"animate"),animateOption:t&&t.animateOption?(0,f.b$)({},lp,t.animateOption):lp}},e}(ua),Rb=Bb;function ci(r,e,t){return t===K.TOP?[r.minX+r.width/2-e.width/2,r.minY]:t===K.BOTTOM?[r.minX+r.width/2-e.width/2,r.maxY-e.height]:t===K.LEFT?[r.minX,r.minY+r.height/2-e.height/2]:t===K.RIGHT?[r.maxX-e.width,r.minY+r.height/2-e.height/2]:t===K.TOP_LEFT||t===K.LEFT_TOP?[r.tl.x,r.tl.y]:t===K.TOP_RIGHT||t===K.RIGHT_TOP?[r.tr.x-e.width,r.tr.y]:t===K.BOTTOM_LEFT||t===K.LEFT_BOTTOM?[r.bl.x,r.bl.y-e.height]:t===K.BOTTOM_RIGHT||t===K.RIGHT_BOTTOM?[r.br.x-e.width,r.br.y-e.height]:[0,0]}function Nb(r,e){if(e.isTransposed)switch(r){case DIRECTION.BOTTOM:return DIRECTION.LEFT;case DIRECTION.LEFT:return DIRECTION.BOTTOM;case DIRECTION.RIGHT:return DIRECTION.TOP;case DIRECTION.TOP:return DIRECTION.RIGHT}return r}function up(r){return r===DIRECTION.LEFT?DIRECTION.RIGHT:r===DIRECTION.RIGHT?DIRECTION.LEFT:r}function cp(r){return r===DIRECTION.TOP?DIRECTION.BOTTOM:r===DIRECTION.BOTTOM?DIRECTION.TOP:r}function Ub(r,e){var t=e.matrix[0],n=e.matrix[4],i=r;return t<0&&(i=up(i)),n<0&&(i=cp(i)),i}function zb(r,e){var t=r;return e.isReflect("x")&&(t=up(t)),e.isReflect("y")&&(t=cp(t)),t}function h5(r,e){var t=r;return t=Nb(t,e),t=Ub(t,e),t=zb(t,e),t}function fp(r,e){return(0,f.jn)(r)?r===!1?!1:{}:(0,f.U2)(r,[e],r)}function Gs(r){return(0,f.U2)(r,"position",K.BOTTOM)}var Vb=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.container=n.view.getLayer(J.FORE).addGroup(),n}return Object.defineProperty(e.prototype,"name",{get:function(){return"legend"},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.render=function(){this.update()},e.prototype.layout=function(){var t=this;this.layoutBBox=this.view.viewBBox,(0,f.S6)(this.components,function(n){var i=n.component,a=n.direction,o=Ru(a),s=i.get("maxWidthRatio"),l=i.get("maxHeightRatio"),u=t.getCategoryLegendSizeCfg(o,s,l),c=i.get("maxWidth"),h=i.get("maxHeight");i.update({maxWidth:Math.min(u.maxWidth,c||0),maxHeight:Math.min(u.maxHeight,h||0)});var v=i.get("padding"),d=i.getLayoutBBox(),g=new Ir(d.x,d.y,d.width,d.height).expand(v),y=(0,p.CR)(ci(t.view.viewBBox,g,a),2),x=y[0],m=y[1],M=(0,p.CR)(ci(t.layoutBBox,g,a),2),w=M[0],S=M[1],b=0,k=0;a.startsWith("top")||a.startsWith("bottom")?(b=x,k=S):(b=w,k=m),i.setLocation({x:b+v[3],y:k+v[0]}),t.layoutBBox=t.layoutBBox.cut(g,a)})},e.prototype.update=function(){var t=this;this.option=this.view.getOptions().legends;var n={},i=function(v,d,g){var y=t.getId(g.field),x=t.getComponentById(y);if(x){var m=void 0,M=fp(t.option,g.field);M!==!1&&((0,f.U2)(M,"custom")?m=t.getCategoryCfg(v,d,g,M,!0):g.isLinear?m=t.getContinuousCfg(v,d,g,M):g.isCategory&&(m=t.getCategoryCfg(v,d,g,M))),m&&(Nr(m,["container"]),x.direction=Gs(M),x.component.update(m),n[y]=!0)}else{var w=t.createFieldLegend(v,d,g);w&&(w.component.init(),t.components.push(w),n[y]=!0)}};if((0,f.U2)(this.option,"custom")){var a="global-custom",o=this.getComponentById(a);if(o){var s=this.getCategoryCfg(void 0,void 0,void 0,this.option,!0);Nr(s,["container"]),o.component.update(s),n[a]=!0}else{var l=this.createCustomLegend(void 0,void 0,void 0,this.option);if(l){l.init();var u=J.FORE,c=Gs(this.option);this.components.push({id:a,component:l,layer:u,direction:c,type:ht.LEGEND,extra:void 0}),n[a]=!0}}}else this.loopLegends(i);var h=[];(0,f.S6)(this.getComponents(),function(v){n[v.id]?h.push(v):v.component.destroy()}),this.components=h},e.prototype.clear=function(){r.prototype.clear.call(this),this.container.clear()},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.container.remove(!0)},e.prototype.getGeometries=function(t){var n=this,i=t.geometries;return(0,f.S6)(t.views,function(a){i=i.concat(n.getGeometries(a))}),i},e.prototype.loopLegends=function(t){var n=this.view.getRootView()===this.view;if(!!n){var i=this.getGeometries(this.view),a={};(0,f.S6)(i,function(o){var s=o.getGroupAttributes();(0,f.S6)(s,function(l){var u=l.getScale(l.type);!u||u.type==="identity"||a[u.field]||(t(o,l,u),a[u.field]=!0)})})}},e.prototype.createFieldLegend=function(t,n,i){var a,o=fp(this.option,i.field),s=J.FORE,l=Gs(o);if(o!==!1&&((0,f.U2)(o,"custom")?a=this.createCustomLegend(t,n,i,o):i.isLinear?a=this.createContinuousLegend(t,n,i,o):i.isCategory&&(a=this.createCategoryLegend(t,n,i,o))),a)return a.set("field",i.field),{id:this.getId(i.field),component:a,layer:s,direction:l,type:ht.LEGEND,extra:{scale:i}}},e.prototype.createCustomLegend=function(t,n,i,a){var o=this.getCategoryCfg(t,n,i,a,!0);return new Ah(o)},e.prototype.createContinuousLegend=function(t,n,i,a){var o=this.getContinuousCfg(t,n,i,Nr(a,["value"]));return new Z1(o)},e.prototype.createCategoryLegend=function(t,n,i,a){var o=this.getCategoryCfg(t,n,i,a);return new Ah(o)},e.prototype.getContinuousCfg=function(t,n,i,a){var o=i.getTicks(),s=(0,f.sE)(o,function(y){return y.value===0}),l=(0,f.sE)(o,function(y){return y.value===1}),u=o.map(function(y){var x=y.value,m=y.tickValue,M=n.mapping(i.invert(x)).join("");return{value:m,attrValue:M,color:M,scaleValue:x}});s||u.push({value:i.min,attrValue:n.mapping(i.invert(0)).join(""),color:n.mapping(i.invert(0)).join(""),scaleValue:0}),l||u.push({value:i.max,attrValue:n.mapping(i.invert(1)).join(""),color:n.mapping(i.invert(1)).join(""),scaleValue:1}),u.sort(function(y,x){return y.value-x.value});var c={min:(0,f.YM)(u).value,max:(0,f.Z$)(u).value,colors:[],rail:{type:n.type},track:{}};n.type==="size"&&(c.track={style:{fill:n.type==="size"?this.view.getTheme().defaultColor:void 0}}),n.type==="color"&&(c.colors=u.map(function(y){return y.attrValue}));var h=this.container,v=Gs(a),d=Ru(v),g=(0,f.U2)(a,"title");return g&&(g=(0,f.b$)({text:qa(i)},g)),c.container=h,c.layout=d,c.title=g,c.animateOption=ca,this.mergeLegendCfg(c,a,"continuous")},e.prototype.getCategoryCfg=function(t,n,i,a,o){var s=this.container,l=(0,f.U2)(a,"position",K.BOTTOM),u=Vv(this.view.getTheme(),l),c=(0,f.U2)(u,["marker"]),h=(0,f.U2)(a,"marker"),v=Ru(l),d=(0,f.U2)(u,["pageNavigator"]),g=(0,f.U2)(a,"pageNavigator"),y=o?t2(c,h,a.items):zv(this.view,t,n,c,h),x=(0,f.U2)(a,"title");x&&(x=(0,f.b$)({text:i?qa(i):""},x));var m=(0,f.U2)(a,"maxWidthRatio"),M=(0,f.U2)(a,"maxHeightRatio"),w=this.getCategoryLegendSizeCfg(v,m,M);w.container=s,w.layout=v,w.items=y,w.title=x,w.animateOption=ca,w.pageNavigator=(0,f.b$)({},d,g);var S=this.mergeLegendCfg(w,a,l);S.reversed&&S.items.reverse();var b=(0,f.U2)(S,"maxItemWidth");return b&&b<=1&&(S.maxItemWidth=this.view.viewBBox.width*b),S},e.prototype.mergeLegendCfg=function(t,n,i){var a=i.split("-")[0],o=Vv(this.view.getTheme(),a);return(0,f.b$)({},o,t,n)},e.prototype.getId=function(t){return"".concat(this.name,"-").concat(t)},e.prototype.getComponentById=function(t){return(0,f.sE)(this.components,function(n){return n.id===t})},e.prototype.getCategoryLegendSizeCfg=function(t,n,i){n===void 0&&(n=Pt),i===void 0&&(i=Pt);var a=this.view.viewBBox,o=a.width,s=a.height;return t==="vertical"?{maxWidth:o*n,maxHeight:s}:{maxWidth:o,maxHeight:s*i}},e}(ua),Hb=Vb,Gb=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.onChangeFn=f.ZT,n.resetMeasure=function(){n.clear()},n.onValueChange=function(i){var a=(0,p.CR)(i,2),o=a[0],s=a[1];n.start=o,n.end=s,n.changeViewData(o,s)},n.container=n.view.getLayer(J.FORE).addGroup(),n.onChangeFn=(0,f.P2)(n.onValueChange,20,{leading:!0}),n.width=0,n.view.on(X.BEFORE_CHANGE_DATA,n.resetMeasure),n.view.on(X.BEFORE_CHANGE_SIZE,n.resetMeasure),n}return Object.defineProperty(e.prototype,"name",{get:function(){return"slider"},enumerable:!1,configurable:!0}),e.prototype.destroy=function(){r.prototype.destroy.call(this),this.view.off(X.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(X.BEFORE_CHANGE_SIZE,this.resetMeasure)},e.prototype.init=function(){},e.prototype.render=function(){this.option=this.view.getOptions().slider;var t=this.getSliderCfg(),n=t.start,i=t.end;(0,f.UM)(this.start)&&(this.start=n,this.end=i);var a=this.view.getOptions().data;this.option&&!(0,f.xb)(a)?this.slider?this.slider=this.updateSlider():(this.slider=this.createSlider(),this.slider.component.on("sliderchange",this.onChangeFn)):this.slider&&(this.slider.component.destroy(),this.slider=void 0)},e.prototype.layout=function(){var t=this;if(this.option&&!this.width&&(this.measureSlider(),setTimeout(function(){t.view.destroyed||t.changeViewData(t.start,t.end)},0)),this.slider){var n=this.view.coordinateBBox.width,i=this.slider.component.get("padding"),a=(0,p.CR)(i,4),o=a[0],s=a[1],l=a[2],u=a[3],c=this.slider.component.getLayoutBBox(),h=new Ir(c.x,c.y,Math.min(c.width,n),c.height).expand(i),v=this.getMinMaxText(this.start,this.end),d=v.minText,g=v.maxText,y=(0,p.CR)(ci(this.view.viewBBox,h,K.BOTTOM),2),x=y[0],m=y[1],M=(0,p.CR)(ci(this.view.coordinateBBox,h,K.BOTTOM),2),w=M[0],S=M[1];this.slider.component.update((0,p.pi)((0,p.pi)({},this.getSliderCfg()),{x:w+u,y:m+o,width:this.width,start:this.start,end:this.end,minText:d,maxText:g})),this.view.viewBBox=this.view.viewBBox.cut(h,K.BOTTOM)}},e.prototype.update=function(){this.render()},e.prototype.createSlider=function(){var t=this.getSliderCfg(),n=new z1((0,p.pi)({container:this.container},t));return n.init(),{component:n,layer:J.FORE,direction:K.BOTTOM,type:ht.SLIDER}},e.prototype.updateSlider=function(){var t=this.getSliderCfg();if(this.width){var n=this.getMinMaxText(this.start,this.end),i=n.minText,a=n.maxText;t=(0,p.pi)((0,p.pi)({},t),{width:this.width,start:this.start,end:this.end,minText:i,maxText:a})}return this.slider.component.update(t),this.slider},e.prototype.measureSlider=function(){var t=this.getSliderCfg().width;this.width=t},e.prototype.getSliderCfg=function(){var t={height:16,start:0,end:1,minText:"",maxText:"",x:0,y:0,width:this.view.coordinateBBox.width};if((0,f.Kn)(this.option)){var n=(0,p.pi)({data:this.getData()},(0,f.U2)(this.option,"trendCfg",{}));t=(0,f.b$)({},t,this.getThemeOptions(),this.option),t=(0,p.pi)((0,p.pi)({},t),{trendCfg:n})}return t.start=(0,f.uZ)(Math.min((0,f.UM)(t.start)?0:t.start,(0,f.UM)(t.end)?1:t.end),0,1),t.end=(0,f.uZ)(Math.max((0,f.UM)(t.start)?0:t.start,(0,f.UM)(t.end)?1:t.end),0,1),t},e.prototype.getData=function(){var t=this.view.getOptions().data,n=(0,p.CR)(this.view.getYScales(),1),i=n[0],a=this.view.getGroupScales();if(a.length){var o=a[0],s=o.field,l=o.ticks;return t.reduce(function(u,c){return c[s]===l[0]&&u.push(c[i.field]),u},[])}return t.map(function(u){return u[i.field]||0})},e.prototype.getThemeOptions=function(){var t=this.view.getTheme();return(0,f.U2)(t,["components","slider","common"],{})},e.prototype.getMinMaxText=function(t,n){var i=this.view.getOptions().data,a=this.view.getXScale(),o=!0,s=(0,f.I)(i,a.field);a.isLinear&&(s=s.sort());var l=o?s:s.reverse(),u=(0,f.dp)(i);if(!a||!u)return{};var c=(0,f.dp)(l),h=Math.round(t*(c-1)),v=Math.round(n*(c-1)),d=(0,f.U2)(l,[h]),g=(0,f.U2)(l,[v]),y=this.getSliderCfg().formatter;return y&&(d=y(d,i[h],h),g=y(g,i[v],v)),{minText:d,maxText:g}},e.prototype.changeViewData=function(t,n){var i=this.view.getOptions().data,a=this.view.getXScale(),o=(0,f.dp)(i);if(!(!a||!o)){var s=!0,l=(0,f.I)(i,a.field),u=this.view.getXScale().isLinear?l.sort(function(g,y){return Number(g)-Number(y)}):l,c=s?u:u.reverse(),h=(0,f.dp)(c),v=Math.round(t*(h-1)),d=Math.round(n*(h-1));this.view.filter(a.field,function(g,y){var x=c.indexOf(g);return x>-1?na(x,v,d):!0}),this.view.render(!0)}},e.prototype.getComponents=function(){return this.slider?[this.slider]:[]},e.prototype.clear=function(){this.slider&&(this.slider.component.destroy(),this.slider=void 0),this.width=0,this.start=void 0,this.end=void 0},e}(ua),Yb=Gb,Ys=0,hp=8,Xb=32,Wb=20,Zb=function(r){(0,p.ZT)(e,r);function e(t){var n=r.call(this,t)||this;return n.onChangeFn=f.ZT,n.resetMeasure=function(){n.clear()},n.onValueChange=function(i){var a=i.ratio,o=n.getValidScrollbarCfg().animate;n.ratio=(0,f.uZ)(a,0,1);var s=n.view.getOptions().animate;o||n.view.animate(!1),n.changeViewData(n.getScrollRange(),!0),n.view.animate(s)},n.container=n.view.getLayer(J.FORE).addGroup(),n.onChangeFn=(0,f.P2)(n.onValueChange,20,{leading:!0}),n.trackLen=0,n.thumbLen=0,n.ratio=0,n.view.on(X.BEFORE_CHANGE_DATA,n.resetMeasure),n.view.on(X.BEFORE_CHANGE_SIZE,n.resetMeasure),n}return Object.defineProperty(e.prototype,"name",{get:function(){return"scrollbar"},enumerable:!1,configurable:!0}),e.prototype.destroy=function(){r.prototype.destroy.call(this),this.view.off(X.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(X.BEFORE_CHANGE_SIZE,this.resetMeasure)},e.prototype.init=function(){},e.prototype.render=function(){this.option=this.view.getOptions().scrollbar,this.option?this.scrollbar?this.scrollbar=this.updateScrollbar():(this.scrollbar=this.createScrollbar(),this.scrollbar.component.on("scrollchange",this.onChangeFn)):this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0)},e.prototype.layout=function(){var t=this;if(this.option&&!this.trackLen&&(this.measureScrollbar(),setTimeout(function(){t.view.destroyed||t.changeViewData(t.getScrollRange(),!0)})),this.scrollbar){var n=this.view.coordinateBBox.width,i=this.scrollbar.component.get("padding"),a=this.scrollbar.component.getLayoutBBox(),o=new Ir(a.x,a.y,Math.min(a.width,n),a.height).expand(i),s=this.getScrollbarComponentCfg(),l=void 0,u=void 0;if(s.isHorizontal){var c=(0,p.CR)(ci(this.view.viewBBox,o,K.BOTTOM),2),h=c[0],v=c[1],d=(0,p.CR)(ci(this.view.coordinateBBox,o,K.BOTTOM),2),g=d[0],y=d[1];l=g,u=v}else{var x=(0,p.CR)(ci(this.view.viewBBox,o,K.RIGHT),2),h=x[0],v=x[1],m=(0,p.CR)(ci(this.view.viewBBox,o,K.RIGHT),2),g=m[0],y=m[1];l=g,u=v}l+=i[3],u+=i[0],this.trackLen?this.scrollbar.component.update((0,p.pi)((0,p.pi)({},s),{x:l,y:u,trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio})):this.scrollbar.component.update((0,p.pi)((0,p.pi)({},s),{x:l,y:u})),this.view.viewBBox=this.view.viewBBox.cut(o,s.isHorizontal?K.BOTTOM:K.RIGHT)}},e.prototype.update=function(){this.render()},e.prototype.getComponents=function(){return this.scrollbar?[this.scrollbar]:[]},e.prototype.clear=function(){this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0),this.trackLen=0,this.thumbLen=0,this.ratio=0,this.cnt=0,this.step=0,this.data=void 0,this.xScaleCfg=void 0,this.yScalesCfg=[]},e.prototype.setValue=function(t){this.onValueChange({ratio:t})},e.prototype.getValue=function(){return this.ratio},e.prototype.getThemeOptions=function(){var t=this.view.getTheme();return(0,f.U2)(t,["components","scrollbar","common"],{})},e.prototype.getScrollbarTheme=function(t){var n=(0,f.U2)(this.view.getTheme(),["components","scrollbar"]),i=t||{},a=i.thumbHighlightColor,o=(0,p._T)(i,["thumbHighlightColor"]);return{default:(0,f.b$)({},(0,f.U2)(n,["default","style"],{}),o),hover:(0,f.b$)({},(0,f.U2)(n,["hover","style"],{}),{thumbColor:a})}},e.prototype.measureScrollbar=function(){var t=this.view.getXScale(),n=this.view.getYScales().slice();this.data=this.getScrollbarData(),this.step=this.getStep(),this.cnt=this.getCnt();var i=this.getScrollbarComponentCfg(),a=i.trackLen,o=i.thumbLen;this.trackLen=a,this.thumbLen=o,this.xScaleCfg={field:t.field,values:t.values||[]},this.yScalesCfg=n},e.prototype.getScrollRange=function(){var t=Math.floor((this.cnt-this.step)*(0,f.uZ)(this.ratio,0,1)),n=Math.min(t+this.step-1,this.cnt-1);return[t,n]},e.prototype.changeViewData=function(t,n){var i=this,a=(0,p.CR)(t,2),o=a[0],s=a[1],l=this.getValidScrollbarCfg().type,u=l!=="vertical",c=(0,f.I)(this.data,this.xScaleCfg.field),h=this.view.getXScale().isLinear?c.sort(function(d,g){return Number(d)-Number(g)}):c,v=u?h:h.reverse();this.yScalesCfg.forEach(function(d){i.view.scale(d.field,{formatter:d.formatter,type:d.type,min:d.min,max:d.max,tickMethod:d.tickMethod})}),this.view.filter(this.xScaleCfg.field,function(d){var g=v.indexOf(d);return g>-1?na(g,o,s):!0}),this.view.render(!0)},e.prototype.createScrollbar=function(){var t=this.getValidScrollbarCfg().type,n=t!=="vertical",i=new H1((0,p.pi)((0,p.pi)({container:this.container},this.getScrollbarComponentCfg()),{x:0,y:0}));return i.init(),{component:i,layer:J.FORE,direction:n?K.BOTTOM:K.RIGHT,type:ht.SCROLLBAR}},e.prototype.updateScrollbar=function(){var t=this.getScrollbarComponentCfg(),n=this.trackLen?(0,p.pi)((0,p.pi)({},t),{trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio}):(0,p.pi)({},t);return this.scrollbar.component.update(n),this.scrollbar},e.prototype.getStep=function(){if(this.step)return this.step;var t=this.view.coordinateBBox,n=this.getValidScrollbarCfg(),i=n.type,a=n.categorySize,o=i!=="vertical";return Math.floor((o?t.width:t.height)/a)},e.prototype.getCnt=function(){if(this.cnt)return this.cnt;var t=this.view.getXScale(),n=this.getScrollbarData(),i=(0,f.I)(n,t.field);return(0,f.dp)(i)},e.prototype.getScrollbarComponentCfg=function(){var t=this.view,n=t.coordinateBBox,i=t.viewBBox,a=this.getValidScrollbarCfg(),o=a.type,s=a.padding,l=a.width,u=a.height,c=a.style,h=o!=="vertical",v=(0,p.CR)(s,4),d=v[0],g=v[1],y=v[2],x=v[3],m=h?{x:n.minX+x,y:i.maxY-u-y}:{x:i.maxX-l-g,y:n.minY+d},M=this.getStep(),w=this.getCnt(),S=h?n.width-x-g:n.height-d-y,b=Math.max(S*(0,f.uZ)(M/w,0,1),Wb);return(0,p.pi)((0,p.pi)({},this.getThemeOptions()),{x:m.x,y:m.y,size:h?u:l,isHorizontal:h,trackLen:S,thumbLen:b,thumbOffset:0,theme:this.getScrollbarTheme(c)})},e.prototype.getValidScrollbarCfg=function(){var t={type:"horizontal",categorySize:Xb,width:hp,height:hp,padding:[0,0,0,0],animate:!0,style:{}};return(0,f.Kn)(this.option)&&(t=(0,p.pi)((0,p.pi)({},t),this.option)),(!(0,f.Kn)(this.option)||!this.option.padding)&&(t.padding=t.type==="horizontal"?[Ys,0,Ys,0]:[0,Ys,0,Ys]),t},e.prototype.getScrollbarData=function(){var t=this.view.getCoordinate(),n=this.getValidScrollbarCfg(),i=this.view.getOptions().data||[];return t.isReflect("y")&&n.type==="vertical"&&(i=(0,p.ev)([],(0,p.CR)(i),!1).reverse()),i},e}(ua),$b=Zb,qb={fill:"#CCD6EC",opacity:.3};function Kb(r,e,t){var n,i,a,o,s,l,u=mw(r,e,t);if(u.length){u=(0,f.xH)(u);try{for(var c=(0,p.XA)(u),h=c.next();!h.done;h=c.next()){var v=h.value;try{for(var d=(a=void 0,(0,p.XA)(v)),g=d.next();!g.done;g=d.next()){var y=g.value,x=y.mappingData,m=x.x,M=x.y;y.x=(0,f.kJ)(m)?m[m.length-1]:m,y.y=(0,f.kJ)(M)?M[M.length-1]:M}}catch(gt){a={error:gt}}finally{try{g&&!g.done&&(o=d.return)&&o.call(d)}finally{if(a)throw a.error}}}}catch(gt){n={error:gt}}finally{try{h&&!h.done&&(i=c.return)&&i.call(c)}finally{if(n)throw n.error}}var w=t.shared;if(w===!1&&u.length>1){var S=u[0],b=Math.abs(e.y-S[0].y);try{for(var k=(0,p.XA)(u),H=k.next();!H.done;H=k.next()){var at=H.value,At=Math.abs(e.y-at[0].y);At<=b&&(S=at,b=At)}}catch(gt){s={error:gt}}finally{try{H&&!H.done&&(l=k.return)&&l.call(k)}finally{if(s)throw s.error}}u=[S]}return(0,f.jj)((0,f.xH)(u))}return[]}var jb=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.show=function(t){var n=this.context.view,i=this.context.event,a=n.getController("tooltip").getTooltipCfg(),o=Kb(n,{x:i.x,y:i.y},a);if(!(0,f.Xy)(o,this.items)&&(this.items=o,o.length)){var s=n.getXScale().field,l=o[0].data[s],u=[],c=n.geometries;if((0,f.S6)(c,function(de){if(de.type==="interval"||de.type==="schema"){var ue=de.getElementsBy(function(pe){var Ee=pe.getData();return Ee[s]===l});u=u.concat(ue)}}),u.length){var h=n.getCoordinate(),v=u[0].shape.getCanvasBBox(),d=u[0].shape.getCanvasBBox(),g=v;(0,f.S6)(u,function(de){var ue=de.shape.getCanvasBBox();h.isTransposed?(ue.minY<v.minY&&(v=ue),ue.maxY>d.maxY&&(d=ue)):(ue.minX<v.minX&&(v=ue),ue.maxX>d.maxX&&(d=ue)),g.x=Math.min(ue.minX,g.minX),g.y=Math.min(ue.minY,g.minY),g.width=Math.max(ue.maxX,g.maxX)-g.x,g.height=Math.max(ue.maxY,g.maxY)-g.y});var y=n.backgroundGroup,x=n.coordinateBBox,m=void 0;if(h.isRect){var M=n.getXScale(),w=t||{},S=w.appendRatio,b=w.appendWidth;(0,f.UM)(b)&&(S=(0,f.UM)(S)?M.isLinear?0:.25:S,b=h.isTransposed?S*d.height:S*v.width);var k=void 0,H=void 0,at=void 0,At=void 0;h.isTransposed?(k=x.minX,H=Math.min(d.minY,v.minY)-b,at=x.width,At=g.height+b*2):(k=Math.min(v.minX,d.minX)-b,H=x.minY,at=g.width+b*2,At=x.height),m=[["M",k,H],["L",k+at,H],["L",k+at,H+At],["L",k,H+At],["Z"]]}else{var gt=(0,f.YM)(u),Nt=(0,f.Z$)(u),te=Za(gt.getModel(),h).startAngle,ce=Za(Nt.getModel(),h).endAngle,Me=h.getCenter(),be=h.getRadius(),Gt=h.innerRadius*be;m=Qn(Me.x,Me.y,be,te,ce,Gt)}if(this.regionPath)this.regionPath.attr("path",m),this.regionPath.show();else{var ie=(0,f.U2)(t,"style",qb);this.regionPath=y.addShape({type:"path",name:"active-region",capture:!1,attrs:(0,p.pi)((0,p.pi)({},ie),{path:m})})}}}},e.prototype.hide=function(){this.regionPath&&this.regionPath.hide(),this.items=null},e.prototype.destroy=function(){this.hide(),this.regionPath&&this.regionPath.remove(!0),r.prototype.destroy.call(this)},e}(ar),Jb=jb,Qb=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.timeStamp=0,t}return e.prototype.show=function(){var t=this.context,n=t.event,i=t.view,a=i.isTooltipLocked();if(!a){var o=this.timeStamp,s=+new Date,l=(0,f.U2)(t.view.getOptions(),"tooltip.showDelay",16);if(s-o>l){var u=this.location,c={x:n.x,y:n.y};(!u||!(0,f.Xy)(u,c))&&this.showTooltip(i,c),this.timeStamp=s,this.location=c}}},e.prototype.hide=function(){var t=this.context.view,n=t.getController("tooltip"),i=this.context.event,a=i.clientX,o=i.clientY;n.isCursorEntered({x:a,y:o})||t.isTooltipLocked()||(this.hideTooltip(t),this.location=null)},e.prototype.showTooltip=function(t,n){t.showTooltip(n)},e.prototype.hideTooltip=function(t){t.hideTooltip()},e}(ar),vp=Qb,tT=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.showTooltip=function(t,n){var i=bn(t);(0,f.S6)(i,function(a){var o=_u(t,a,n);a.showTooltip(o)})},e.prototype.hideTooltip=function(t){var n=bn(t);(0,f.S6)(n,function(i){i.hideTooltip()})},e}(vp),eT=tT,rT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.timeStamp=0,t}return e.prototype.destroy=function(){r.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},e.prototype.show=function(){var t=this.context,n=t.event,i=this.timeStamp,a=+new Date;if(a-i>16){var o=this.location,s={x:n.x,y:n.y};(!o||!(0,f.Xy)(o,s))&&this.showTooltip(s),this.timeStamp=a,this.location=s}},e.prototype.hide=function(){this.hideTooltip(),this.location=null},e.prototype.showTooltip=function(t){var n=this.context,i=n.event,a=i.target;if(a&&a.get("tip")){if(!this.tooltip)this.renderTooltip();else{var o=n.view,s=o.canvas,l={start:{x:0,y:0},end:{x:s.get("width"),y:s.get("height")}};this.tooltip.set("region",l)}var u=a.get("tip");this.tooltip.update((0,p.pi)({title:u},t)),this.tooltip.show()}},e.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},e.prototype.renderTooltip=function(){var t,n=this.context.view,i=n.canvas,a={start:{x:0,y:0},end:{x:i.get("width"),y:i.get("height")}},o=n.getTheme(),s=(0,f.U2)(o,["components","tooltip","domStyles"],{}),l=new us({parent:i.get("el").parentNode,region:a,visible:!1,crosshairs:null,domStyles:(0,p.pi)({},(0,f.b$)({},s,(t={},t[Rn]={"max-width":"50%"},t[Nn]={"word-break":"break-all"},t)))});l.init(),l.setCapture(!1),this.tooltip=l},e}(ar),nT=rT,iT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="",t}return e.prototype.hasState=function(t){return t.hasState(this.stateName)},e.prototype.setElementState=function(t,n){t.setState(this.stateName,n)},e.prototype.setState=function(){this.setStateEnable(!0)},e.prototype.clear=function(){var t=this.context.view;this.clearViewState(t)},e.prototype.clearViewState=function(t){var n=this,i=sv(t,this.stateName);(0,f.S6)(i,function(a){n.setElementState(a,!1)})},e}(ar),mc=iT;function dp(r){return(0,f.U2)(r.get("delegateObject"),"item")}var aT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.ignoreListItemStates=["unchecked"],t}return e.prototype.isItemIgnore=function(t,n){var i=this.ignoreListItemStates,a=i.filter(function(o){return n.hasState(t,o)});return!!a.length},e.prototype.setStateByComponent=function(t,n,i){var a=this.context.view,o=t.get("field"),s=Mr(a);this.setElementsStateByItem(s,o,n,i)},e.prototype.setStateByElement=function(t,n){this.setElementState(t,n)},e.prototype.isMathItem=function(t,n,i){var a=this.context.view,o=sa(a,n),s=hn(t,n);return!(0,f.UM)(s)&&i.name===o.getText(s)},e.prototype.setElementsStateByItem=function(t,n,i,a){var o=this;(0,f.S6)(t,function(s){o.isMathItem(s,n,i)&&s.setState(o.stateName,a)})},e.prototype.setStateEnable=function(t){var n=ri(this.context);if(n)nv(this.context)&&this.setStateByElement(n,t);else{var i=Ti(this.context);if(Qa(i)){var a=i.item,o=i.component;if(a&&o&&!this.isItemIgnore(a,o)){var s=this.context.event.gEvent;if(s&&s.fromShape&&s.toShape&&dp(s.fromShape)===dp(s.toShape))return;this.setStateByComponent(o,a,t)}}}},e.prototype.toggle=function(){var t=ri(this.context);if(t){var n=t.hasState(this.stateName);this.setElementState(t,!n)}},e.prototype.reset=function(){this.setStateEnable(!1)},e}(mc),xc=aT,oT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="active",t}return e.prototype.active=function(){this.setState()},e}(xc),sT=oT,lT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.cache={},t}return e.prototype.getColorScale=function(t,n){var i=n.geometry.getAttribute("color");if(!i)return null;var a=t.getScaleByField(i.getFields()[0]);return a},e.prototype.getLinkPath=function(t,n){var i=this.context.view,a=i.getCoordinate().isTransposed,o=t.shape.getCanvasBBox(),s=n.shape.getCanvasBBox(),l=a?[["M",o.minX,o.minY],["L",s.minX,s.maxY],["L",s.maxX,s.maxY],["L",o.maxX,o.minY],["Z"]]:[["M",o.maxX,o.minY],["L",s.minX,s.minY],["L",s.minX,s.maxY],["L",o.maxX,o.maxY],["Z"]];return l},e.prototype.addLinkShape=function(t,n,i,a){var o={opacity:.4,fill:n.shape.attr("fill")};t.addShape({type:"path",attrs:(0,p.pi)((0,p.pi)({},(0,f.b$)({},o,(0,f.mf)(a)?a(o,n):a)),{path:this.getLinkPath(n,i)})})},e.prototype.linkByElement=function(t,n){var i=this,a=this.context.view,o=this.getColorScale(a,t);if(!!o){var s=hn(t,o.field);if(!this.cache[s]){var l=ZM(a,o.field,s),u=this.linkGroup,c=u.addGroup();this.cache[s]=c;var h=l.length;(0,f.S6)(l,function(v,d){if(d<h-1){var g=l[d+1];i.addLinkShape(c,v,g,n)}})}}},e.prototype.removeLink=function(t){var n=this.getColorScale(this.context.view,t);if(!!n){var i=hn(t,n.field);this.cache[i]&&(this.cache[i].remove(),this.cache[i]=null)}},e.prototype.link=function(t){var n=this.context;this.linkGroup||(this.linkGroup=n.view.foregroundGroup.addGroup({id:"link-by-color-group",capture:!1}));var i=ri(n);i&&this.linkByElement(i,t==null?void 0:t.style)},e.prototype.unlink=function(){var t=ri(this.context);t&&this.removeLink(t)},e.prototype.clear=function(){this.linkGroup&&this.linkGroup.clear(),this.cache={}},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.linkGroup&&this.linkGroup.remove()},e}(ar),uT=lT,cT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.startPoint=null,t.endPoint=null,t.isStarted=!1,t.effectSiblings=!1,t.effectByRecord=!1,t}return e.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},e.prototype.start=function(){this.clear(),this.startPoint=this.getCurrentPoint(),this.isStarted=!0},e.prototype.getIntersectElements=function(){var t=null;if(to(this.context))t=Tu(this.context,10);else{var n=this.startPoint,i=this.isStarted?this.getCurrentPoint():this.endPoint;if(!n||!i)return;var a={minX:Math.min(n.x,i.x),minY:Math.min(n.y,i.y),maxX:Math.max(n.x,i.x),maxY:Math.max(n.y,i.y)},o=this.context.view;t=xs(o,a)}return t},e.prototype.setStateEnable=function(t){if(this.effectSiblings&&!this.effectByRecord)this.setSiblingsState(t);else{var n=Mr(this.context.view),i=this.getIntersectElements();i&&i.length?this.effectByRecord?this.setSiblingsStateByRecord(i,t):this.setElementsState(i,t,n):this.clear()}},e.prototype.setSiblingsStateByRecord=function(t,n){var i=this,a=this.context.view,o=bn(a),s=t.map(function(c){return c.getModel().data}),l=a.getXScale().field,u=a.getYScales()[0].field;(0,f.S6)(o,function(c){var h=Mr(c),v=h.filter(function(d){var g=d.getModel().data;return hv(s,g,l,u)});i.setElementsState(v,n,h)})},e.prototype.setSiblingsState=function(t){var n=this,i=this.context.view,a=bn(i);to(this.context)&&(0,f.S6)(a,function(o){var s=Mr(o),l=av(n.context,o,10);l&&l.length?n.setElementsState(l,t,s):n.clearViewState(o)})},e.prototype.setElementsState=function(t,n,i){var a=this;(0,f.S6)(i,function(o){t.includes(o)?a.setElementState(o,n):a.setElementState(o,!1)})},e.prototype.end=function(){this.isStarted=!1,this.endPoint=this.getCurrentPoint()},e.prototype.clear=function(){var t=this,n=this.context.view;if(this.effectSiblings){var i=bn(n);(0,f.S6)(i,function(a){t.clearViewState(a)})}else this.clearViewState(n)},e}(mc),Mc=cT,fT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="active",t}return e.prototype.active=function(){this.setState()},e}(Mc),hT=fT,vT=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.setStateEnable=function(t){var n=ri(this.context);if(n){if(!nv(this.context))return;t?(this.clear(),this.setElementState(n,!0)):this.hasState(n)&&this.setElementState(n,!1)}},e.prototype.toggle=function(){var t=ri(this.context);if(t){var n=this.hasState(t);n||this.clear(),this.setElementState(t,!n)}},e.prototype.reset=function(){this.setStateEnable(!1)},e}(mc),wc=vT,dT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="active",t}return e.prototype.active=function(){this.setState()},e}(wc),pT=dT,ho="inactive",vo="active";function Sc(r){var e=Mr(r);(0,f.S6)(e,function(t){t.hasState(vo)&&t.setState(vo,!1),t.hasState(ho)&&t.setState(ho,!1)})}function pp(r,e,t){(0,f.S6)(r,function(n){e(n)?(n.hasState(ho)&&n.setState(ho,!1),n.setState(vo,t)):(n.hasState(vo)&&n.setState(vo,!1),n.setState(ho,t))})}var Pi=zt.INACTIVE,zn=zt.ACTIVE,gT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName=zn,t}return e.prototype.setElementsStateByItem=function(t,n,i,a){var o=this,s=function(l){return o.isMathItem(l,n,i)};this.setHighlightBy(t,s,a)},e.prototype.setElementHighlight=function(t,n){n(t)?(t.hasState(Pi)&&t.setState(Pi,!1),t.setState(zn,!0)):t.hasState(zn)||t.setState(Pi,!0)},e.prototype.setHighlightBy=function(t,n,i){var a=this;if(i)(0,f.S6)(t,function(l){a.setElementHighlight(l,n)});else{var o=sv(this.context.view,zn),s=!0;(0,f.S6)(o,function(l){if(!n(l))return s=!1,!1}),s?this.clear():(0,f.S6)(t,function(l){n(l)&&(l.hasState(zn)&&l.setState(zn,!1),l.setState(Pi,!0))})}},e.prototype.setElementState=function(t,n){var i=this.context.view,a=Mr(i);this.setHighlightBy(a,function(o){return t===o},n)},e.prototype.highlight=function(){this.setState()},e.prototype.clear=function(){var t=this.context.view;Sc(t)},e}(xc),Cc=gT,yT=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.setStateByElement=function(t,n){var i=this.context.view,a=t.geometry.getAttribute("color");if(!!a){var o=i.getScaleByField(a.getFields()[0]),s=hn(t,o.field),l=Mr(i),u=l.filter(function(c){return hn(c,o.field)===s});this.setHighlightBy(l,function(c){return u.includes(c)},n)}},e}(Cc),mT=yT,xT=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.setElementHighlight=function(t,n){n(t)?(t.hasState(Pi)&&t.setState(Pi,!1),t.setState(zn,!0)):(t.setState(Pi,!0),t.hasState(zn)&&t.setState(zn,!1))},e.prototype.setStateByElement=function(t,n){var i=this.context.view,a=i.getXScale(),o=hn(t,a.field),s=Mr(i),l=s.filter(function(u){return hn(u,a.field)===o});this.setHighlightBy(s,function(u){return l.includes(u)},n)},e.prototype.toggle=function(){var t=ri(this.context);if(t){var n=t.hasState(this.stateName);this.setStateByElement(t,!n)}},e}(Cc),MT=xT,En;(function(r){r.BEFORE_HIGHLIGHT="element-range-highlight:beforehighlight",r.AFTER_HIGHLIGHT="element-range-highlight:afterhighlight",r.BEFORE_CLEAR="element-range-highlight:beforeclear",r.AFTER_CLEAR="element-range-highlight:afterclear"})(En||(En={}));var wT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="active",t}return e.prototype.clearViewState=function(t){Sc(t)},e.prototype.highlight=function(){var t=this.context,n=t.view,i=t.event,a=this.getIntersectElements(),o={view:n,event:i,highlightElements:a};n.emit(En.BEFORE_HIGHLIGHT,lr.fromData(n,En.BEFORE_HIGHLIGHT,o)),this.setState(),n.emit(En.AFTER_HIGHLIGHT,lr.fromData(n,En.AFTER_HIGHLIGHT,o))},e.prototype.clear=function(){var t=this.context.view;t.emit(En.BEFORE_CLEAR,lr.fromData(t,En.BEFORE_CLEAR,{})),r.prototype.clear.call(this),t.emit(En.AFTER_CLEAR,lr.fromData(t,En.AFTER_CLEAR,{}))},e.prototype.setElementsState=function(t,n,i){pp(i,function(a){return t.indexOf(a)>=0},n)},e}(Mc),gp=wT,ST=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="active",t}return e.prototype.highlight=function(){this.setState()},e.prototype.setElementState=function(t,n){var i=this.context.view,a=Mr(i);pp(a,function(o){return t===o},n)},e.prototype.clear=function(){var t=this.context.view;Sc(t)},e}(wc),CT=ST,AT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="selected",t}return e.prototype.selected=function(){this.setState()},e}(Mc),bT=AT,TT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="selected",t}return e.prototype.selected=function(){this.setState()},e}(xc),ET=TT,_T=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="selected",t}return e.prototype.selected=function(){this.setState()},e}(wc),FT=_T,IT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="",t.ignoreItemStates=[],t}return e.prototype.getTriggerListInfo=function(){var t=Ti(this.context),n=null;return Qa(t)&&(n={item:t.item,list:t.component}),n},e.prototype.getAllowComponents=function(){var t=this,n=this.context.view,i=cv(n),a=[];return(0,f.S6)(i,function(o){o.isList()&&t.allowSetStateByElement(o)&&a.push(o)}),a},e.prototype.hasState=function(t,n){return t.hasState(n,this.stateName)},e.prototype.clearAllComponentsState=function(){var t=this,n=this.getAllowComponents();(0,f.S6)(n,function(i){i.clearItemsState(t.stateName)})},e.prototype.allowSetStateByElement=function(t){var n=t.get("field");if(!n)return!1;if(this.cfg&&this.cfg.componentNames){var i=t.get("name");if(this.cfg.componentNames.indexOf(i)===-1)return!1}var a=this.context.view,o=sa(a,n);return o&&o.isCategory},e.prototype.allowSetStateByItem=function(t,n){var i=this.ignoreItemStates;if(i.length){var a=i.filter(function(o){return n.hasState(t,o)});return a.length===0}return!0},e.prototype.setStateByElement=function(t,n,i){var a=t.get("field"),o=this.context.view,s=sa(o,a),l=hn(n,a),u=s.getText(l);this.setItemsState(t,u,i)},e.prototype.setStateEnable=function(t){var n=this,i=ri(this.context);if(i){var a=this.getAllowComponents();(0,f.S6)(a,function(u){n.setStateByElement(u,i,t)})}else{var o=Ti(this.context);if(Qa(o)){var s=o.item,l=o.component;this.allowSetStateByElement(l)&&this.allowSetStateByItem(s,l)&&this.setItemState(l,s,t)}}},e.prototype.setItemsState=function(t,n,i){var a=this,o=t.getItems();(0,f.S6)(o,function(s){s.name===n&&a.setItemState(t,s,i)})},e.prototype.setItemState=function(t,n,i){t.setItemState(n,this.stateName,i)},e.prototype.setState=function(){this.setStateEnable(!0)},e.prototype.reset=function(){this.setStateEnable(!1)},e.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var n=t.list,i=t.item,a=this.hasState(n,i);this.setItemState(n,i,!a)}},e.prototype.clear=function(){var t=this.getTriggerListInfo();t?t.list.clearItemsState(this.stateName):this.clearAllComponentsState()},e}(ar),Li=IT,PT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="active",t}return e.prototype.active=function(){this.setState()},e}(Li),LT=PT,yp="inactive",mp="active";function DT(r){var e=r.getItems();(0,f.S6)(e,function(t){r.hasState(t,mp)&&r.setItemState(t,mp,!1),r.hasState(t,yp)&&r.setItemState(t,yp,!1)})}var po="inactive",Di="active",OT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName=Di,t.ignoreItemStates=["unchecked"],t}return e.prototype.setItemsState=function(t,n,i){this.setHighlightBy(t,function(a){return a.name===n},i)},e.prototype.setItemState=function(t,n,i){var a=t.getItems();this.setHighlightBy(t,function(o){return o===n},i)},e.prototype.setHighlightBy=function(t,n,i){var a=t.getItems();if(i)(0,f.S6)(a,function(l){n(l)?(t.hasState(l,po)&&t.setItemState(l,po,!1),t.setItemState(l,Di,!0)):t.hasState(l,Di)||t.setItemState(l,po,!0)});else{var o=t.getItemsByState(Di),s=!0;(0,f.S6)(o,function(l){if(!n(l))return s=!1,!1}),s?this.clear():(0,f.S6)(a,function(l){n(l)&&(t.hasState(l,Di)&&t.setItemState(l,Di,!1),t.setItemState(l,po,!0))})}},e.prototype.highlight=function(){this.setState()},e.prototype.clear=function(){var t=this.getTriggerListInfo();if(t)DT(t.list);else{var n=this.getAllowComponents();(0,f.S6)(n,function(i){i.clearItemsState(Di),i.clearItemsState(po)})}},e}(Li),Ac=OT,kT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="selected",t}return e.prototype.selected=function(){this.setState()},e}(Li),BT=kT,RT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName="unchecked",t}return e.prototype.unchecked=function(){this.setState()},e}(Li),NT=RT,va="unchecked",Xs="checked",UT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.stateName=Xs,t}return e.prototype.setItemState=function(t,n,i){this.setCheckedBy(t,function(a){return a===n},i)},e.prototype.setCheckedBy=function(t,n,i){var a=t.getItems();i&&(0,f.S6)(a,function(o){n(o)?(t.hasState(o,va)&&t.setItemState(o,va,!1),t.setItemState(o,Xs,!0)):t.hasState(o,Xs)||t.setItemState(o,va,!0)})},e.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var n=t.list,i=t.item,a=!(0,f.G)(n.getItems(),function(o){return n.hasState(o,va)});a||n.hasState(i,va)?this.setItemState(n,i,!0):this.reset()}},e.prototype.checked=function(){this.setState()},e.prototype.reset=function(){var t=this.getAllowComponents();(0,f.S6)(t,function(n){n.clearItemsState(Xs),n.clearItemsState(va)})},e}(Li),zT=UT,da="unchecked",VT=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.toggle=function(){var t,n,i,a,o,s,l,u,c=this.getTriggerListInfo();if(c==null?void 0:c.item){var h=c.list,v=c.item,d=h.getItems(),g=d.filter(function(gt){return!h.hasState(gt,da)}),y=d.filter(function(gt){return h.hasState(gt,da)}),x=g[0];if(d.length===g.length)try{for(var m=(0,p.XA)(d),M=m.next();!M.done;M=m.next()){var w=M.value;h.setItemState(w,da,w.id!==v.id)}}catch(gt){t={error:gt}}finally{try{M&&!M.done&&(n=m.return)&&n.call(m)}finally{if(t)throw t.error}}else if(d.length-y.length==1)if(x.id===v.id)try{for(var S=(0,p.XA)(d),b=S.next();!b.done;b=S.next()){var w=b.value;h.setItemState(w,da,!1)}}catch(gt){i={error:gt}}finally{try{b&&!b.done&&(a=S.return)&&a.call(S)}finally{if(i)throw i.error}}else try{for(var k=(0,p.XA)(d),H=k.next();!H.done;H=k.next()){var w=H.value;h.setItemState(w,da,w.id!==v.id)}}catch(gt){o={error:gt}}finally{try{H&&!H.done&&(s=k.return)&&s.call(k)}finally{if(o)throw o.error}}else try{for(var at=(0,p.XA)(d),At=at.next();!At.done;At=at.next()){var w=At.value;h.setItemState(w,da,w.id!==v.id)}}catch(gt){l={error:gt}}finally{try{At&&!At.done&&(u=at.return)&&u.call(at)}finally{if(l)throw l.error}}}},e}(Li),HT=VT,xp="showRadio",bc="legend-radio-tip",GT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.timeStamp=0,t}return e.prototype.show=function(){var t=this.getTriggerListInfo();if(t==null?void 0:t.item){var n=t.list,i=t.item;n.setItemState(i,xp,!0)}},e.prototype.hide=function(){var t=this.getTriggerListInfo();if(t==null?void 0:t.item){var n=t.list,i=t.item;n.setItemState(i,xp,!1)}},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},e.prototype.showTip=function(){var t=this.context,n=t.event,i=this.timeStamp,a=+new Date,o=this.context.event.target;if(a-i>16&&o.get("name")==="legend-item-radio"){var s=this.location,l={x:n.x,y:n.y};this.timeStamp=a,this.location=l,(!s||!(0,f.Xy)(s,l))&&this.showTooltip(l)}},e.prototype.hideTip=function(){this.hideTooltip(),this.location=null},e.prototype.showTooltip=function(t){var n=this.context,i=n.event,a=i.target;if(a&&a.get("tip")){this.tooltip||this.renderTooltip();var o=n.view.getCanvas().get("el").getBoundingClientRect(),s=o.x,l=o.y;this.tooltip.update((0,p.pi)((0,p.pi)({title:a.get("tip")},t),{x:t.x+s,y:t.y+l})),this.tooltip.show()}},e.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},e.prototype.renderTooltip=function(){var t,n=(t={},t[Rn]={padding:"6px 8px",transform:"translate(-50%, -80%)",background:"rgba(0,0,0,0.75)",color:"#fff","border-radius":"2px","z-index":100},t[Nn]={"font-size":"12px","line-height":"14px","margin-bottom":0,"word-break":"break-all"},t);document.getElementById(bc)&&document.body.removeChild(document.getElementById(bc));var i=new us({parent:document.body,region:null,visible:!1,crosshairs:null,domStyles:n,containerId:bc});i.init(),i.setCapture(!1),this.tooltip=i},e}(Li),YT=GT,XT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.maskShape=null,t.points=[],t.starting=!1,t.moving=!1,t.preMovePoint=null,t.shapeType="path",t}return e.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},e.prototype.emitEvent=function(t){var n="mask:".concat(t),i=this.context.view,a=this.context.event;i.emit(n,{target:this.maskShape,shape:this.maskShape,points:this.points,x:a.x,y:a.y})},e.prototype.createMask=function(){var t=this.context.view,n=this.getMaskAttrs(),i=t.foregroundGroup.addShape({type:this.shapeType,name:"mask",draggable:!0,attrs:(0,p.pi)({fill:"#C5D4EB",opacity:.3},n)});return i},e.prototype.getMaskPath=function(){return[]},e.prototype.show=function(){this.maskShape&&(this.maskShape.show(),this.emitEvent("show"))},e.prototype.start=function(t){this.starting=!0,this.moving=!1,this.points=[this.getCurrentPoint()],this.maskShape||(this.maskShape=this.createMask(),this.maskShape.set("capture",!1)),this.updateMask(t==null?void 0:t.maskStyle),this.emitEvent("start")},e.prototype.moveStart=function(){this.moving=!0,this.preMovePoint=this.getCurrentPoint()},e.prototype.move=function(){if(!(!this.moving||!this.maskShape)){var t=this.getCurrentPoint(),n=this.preMovePoint,i=t.x-n.x,a=t.y-n.y,o=this.points;(0,f.S6)(o,function(s){s.x+=i,s.y+=a}),this.updateMask(),this.emitEvent("change"),this.preMovePoint=t}},e.prototype.updateMask=function(t){var n=(0,f.b$)({},this.getMaskAttrs(),t);this.maskShape.attr(n)},e.prototype.moveEnd=function(){this.moving=!1,this.preMovePoint=null},e.prototype.end=function(){this.starting=!1,this.emitEvent("end"),this.maskShape&&this.maskShape.set("capture",!0)},e.prototype.hide=function(){this.maskShape&&(this.maskShape.hide(),this.emitEvent("hide"))},e.prototype.resize=function(){this.starting&&this.maskShape&&(this.points.push(this.getCurrentPoint()),this.updateMask(),this.emitEvent("change"))},e.prototype.destroy=function(){this.points=[],this.maskShape&&this.maskShape.remove(),this.maskShape=null,this.preMovePoint=null,r.prototype.destroy.call(this)},e}(ar),Tc=XT;function Mp(r){var e=(0,f.Z$)(r),t=0,n=0,i=0;if(r.length){var a=r[0];t=Eu(a,e)/2,n=(e.x+a.x)/2,i=(e.y+a.y)/2}return{x:n,y:i,r:t}}var WT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.shapeType="circle",t}return e.prototype.getMaskAttrs=function(){return Mp(this.points)},e}(Tc),ZT=WT;function wp(r){return{start:(0,f.YM)(r),end:(0,f.Z$)(r)}}function Sp(r,e){var t=Math.min(r.x,e.x),n=Math.min(r.y,e.y),i=Math.abs(e.x-r.x),a=Math.abs(e.y-r.y);return{x:t,y:n,width:i,height:a}}var $T=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.shapeType="rect",t}return e.prototype.getRegion=function(){return wp(this.points)},e.prototype.getMaskAttrs=function(){var t=this.getRegion(),n=t.start,i=t.end;return Sp(n,i)},e}(Tc),Cp=$T;function Ap(r){r.x=(0,f.uZ)(r.x,0,1),r.y=(0,f.uZ)(r.y,0,1)}function bp(r,e,t,n){var i=null,a=null,o=n.invert((0,f.YM)(r)),s=n.invert((0,f.Z$)(r));return t&&(Ap(o),Ap(s)),e==="x"?(i=n.convert({x:o.x,y:0}),a=n.convert({x:s.x,y:1})):(i=n.convert({x:0,y:o.y}),a=n.convert({x:1,y:s.y})),{start:i,end:a}}var qT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.dim="x",t.inPlot=!0,t}return e.prototype.getRegion=function(){var t=this.context.view.getCoordinate();return bp(this.points,this.dim,this.inPlot,t)},e}(Cp),Tp=qT;function Ec(r){var e=[];return r.length&&((0,f.S6)(r,function(t,n){n===0?e.push(["M",t.x,t.y]):e.push(["L",t.x,t.y])}),e.push(["L",r[0].x,r[0].y])),e}function Ep(r){return{path:Ec(r)}}var KT=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getMaskPath=function(){return Ec(this.points)},e.prototype.getMaskAttrs=function(){return Ep(this.points)},e.prototype.addPoint=function(){this.resize()},e}(Tc),_p=KT;function _c(r){return qM(r,!0)}function Fp(r){return{path:_c(r)}}var jT=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getMaskPath=function(){return _c(this.points)},e.prototype.getMaskAttrs=function(){return Fp(this.points)},e}(_p),JT=jT,QT=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.maskShapes=[],t.starting=!1,t.moving=!1,t.recordPoints=null,t.preMovePoint=null,t.shapeType="path",t.maskType="multi-mask",t}return e.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},e.prototype.emitEvent=function(t){var n="".concat(this.maskType,":").concat(t),i=this.context.view,a=this.context.event,o={type:this.shapeType,name:this.maskType,get:function(s){return o.hasOwnProperty(s)?o[s]:void 0}};i.emit(n,{target:o,maskShapes:this.maskShapes,multiPoints:this.recordPoints,x:a.x,y:a.y})},e.prototype.createMask=function(t){var n=this.context.view,i=this.recordPoints[t],a=this.getMaskAttrs(i),o=n.foregroundGroup.addShape({type:this.shapeType,name:"mask",draggable:!0,attrs:(0,p.pi)({fill:"#C5D4EB",opacity:.3},a)});this.maskShapes.push(o)},e.prototype.getMaskPath=function(t){return[]},e.prototype.show=function(){this.maskShapes.length>0&&(this.maskShapes.forEach(function(t){return t.show()}),this.emitEvent("show"))},e.prototype.start=function(t){this.recordPointStart(),this.starting=!0,this.moving=!1;var n=this.recordPoints.length-1;this.createMask(n),this.updateShapesCapture(!1),this.updateMask(t==null?void 0:t.maskStyle),this.emitEvent("start")},e.prototype.moveStart=function(){this.moving=!0,this.preMovePoint=this.getCurrentPoint(),this.updateShapesCapture(!1)},e.prototype.move=function(){if(!(!this.moving||this.maskShapes.length===0)){var t=this.getCurrentPoint(),n=this.preMovePoint,i=t.x-n.x,a=t.y-n.y,o=this.getCurMaskShapeIndex();o>-1&&(this.recordPoints[o].forEach(function(s){s.x+=i,s.y+=a}),this.updateMask(),this.emitEvent("change"),this.preMovePoint=t)}},e.prototype.updateMask=function(t){var n=this;this.recordPoints.forEach(function(i,a){var o=(0,f.b$)({},n.getMaskAttrs(i),t);n.maskShapes[a].attr(o)})},e.prototype.resize=function(){this.starting&&this.maskShapes.length>0&&(this.recordPointContinue(),this.updateMask(),this.emitEvent("change"))},e.prototype.moveEnd=function(){this.moving=!1,this.preMovePoint=null,this.updateShapesCapture(!0)},e.prototype.end=function(){this.starting=!1,this.emitEvent("end"),this.updateShapesCapture(!0)},e.prototype.hide=function(){this.maskShapes.length>0&&(this.maskShapes.forEach(function(t){return t.hide()}),this.emitEvent("hide"))},e.prototype.remove=function(){var t=this.getCurMaskShapeIndex();t>-1&&(this.recordPoints.splice(t,1),this.maskShapes[t].remove(),this.maskShapes.splice(t,1),this.preMovePoint=null,this.updateShapesCapture(!0),this.emitEvent("change"))},e.prototype.clearAll=function(){this.recordPointClear(),this.maskShapes.forEach(function(t){return t.remove()}),this.maskShapes=[],this.preMovePoint=null},e.prototype.clear=function(){var t=this.getCurMaskShapeIndex();t===-1?(this.recordPointClear(),this.maskShapes.forEach(function(n){return n.remove()}),this.maskShapes=[],this.emitEvent("clearAll")):(this.recordPoints.splice(t,1),this.maskShapes[t].remove(),this.maskShapes.splice(t,1),this.preMovePoint=null,this.emitEvent("clearSingle")),this.preMovePoint=null},e.prototype.destroy=function(){this.clear(),r.prototype.destroy.call(this)},e.prototype.getRecordPoints=function(){var t;return(0,p.ev)([],(0,p.CR)((t=this.recordPoints)!==null&&t!==void 0?t:[]),!1)},e.prototype.recordPointStart=function(){var t=this.getRecordPoints(),n=this.getCurrentPoint();this.recordPoints=(0,p.ev)((0,p.ev)([],(0,p.CR)(t),!1),[[n]],!1)},e.prototype.recordPointContinue=function(){var t=this.getRecordPoints(),n=this.getCurrentPoint(),i=t.splice(-1,1)[0]||[];i.push(n),this.recordPoints=(0,p.ev)((0,p.ev)([],(0,p.CR)(t),!1),[i],!1)},e.prototype.recordPointClear=function(){this.recordPoints=[]},e.prototype.updateShapesCapture=function(t){this.maskShapes.forEach(function(n){return n.set("capture",t)})},e.prototype.getCurMaskShapeIndex=function(){var t=this.getCurrentPoint();return this.maskShapes.findIndex(function(n){var i=n.attrs,a=i.width,o=i.height,s=i.r,l=a===0||o===0||s===0;return!l&&n.isHit(t.x,t.y)})},e}(ar),Fc=QT,tE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.shapeType="rect",t}return e.prototype.getRegion=function(t){return wp(t)},e.prototype.getMaskAttrs=function(t){var n=this.getRegion(t),i=n.start,a=n.end;return Sp(i,a)},e}(Fc),Ip=tE,eE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.dim="x",t.inPlot=!0,t}return e.prototype.getRegion=function(t){var n=this.context.view.getCoordinate();return bp(t,this.dim,this.inPlot,n)},e}(Ip),Pp=eE,rE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.shapeType="circle",t.getMaskAttrs=Mp,t}return e}(Fc),nE=rE,iE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.getMaskPath=Ec,t.getMaskAttrs=Ep,t}return e.prototype.addPoint=function(){this.resize()},e}(Fc),Lp=iE,aE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.getMaskPath=_c,t.getMaskAttrs=Fp,t}return e}(Lp),oE=aE,sE=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.setCursor=function(t){var n=this.context.view;n.getCanvas().setCursor(t)},e.prototype.default=function(){this.setCursor("default")},e.prototype.pointer=function(){this.setCursor("pointer")},e.prototype.move=function(){this.setCursor("move")},e.prototype.crosshair=function(){this.setCursor("crosshair")},e.prototype.wait=function(){this.setCursor("wait")},e.prototype.help=function(){this.setCursor("help")},e.prototype.text=function(){this.setCursor("text")},e.prototype.eResize=function(){this.setCursor("e-resize")},e.prototype.wResize=function(){this.setCursor("w-resize")},e.prototype.nResize=function(){this.setCursor("n-resize")},e.prototype.sResize=function(){this.setCursor("s-resize")},e.prototype.neResize=function(){this.setCursor("ne-resize")},e.prototype.nwResize=function(){this.setCursor("nw-resize")},e.prototype.seResize=function(){this.setCursor("se-resize")},e.prototype.swResize=function(){this.setCursor("sw-resize")},e.prototype.nsResize=function(){this.setCursor("ns-resize")},e.prototype.ewResize=function(){this.setCursor("ew-resize")},e.prototype.zoomIn=function(){this.setCursor("zoom-in")},e.prototype.zoomOut=function(){this.setCursor("zoom-out")},e}(ar),lE=sE,uE=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.filterView=function(t,n,i){var a=this;t.getScaleByField(n)&&t.filter(n,i),t.views&&t.views.length&&(0,f.S6)(t.views,function(o){a.filterView(o,n,i)})},e.prototype.filter=function(){var t=Ti(this.context);if(t){var n=this.context.view,i=t.component,a=i.get("field");if(Qa(t)){if(a){var o=i.getItemsByState("unchecked"),s=sa(n,a),l=o.map(function(d){return d.name});l.length?this.filterView(n,a,function(d){var g=s.getText(d);return!l.includes(g)}):this.filterView(n,a,null),n.render(!0)}}else if(iv(t)){var u=i.getValue(),c=(0,p.CR)(u,2),h=c[0],v=c[1];this.filterView(n,a,function(d){return d>=h&&d<=v}),n.render(!0)}}},e}(ar),cE=uE;function Dp(r,e,t,n){var i=Math.min(t[e],n[e]),a=Math.max(t[e],n[e]),o=(0,p.CR)(r.range,2),s=o[0],l=o[1];if(i<s&&(i=s),a>l&&(a=l),i===l&&a===l)return null;var u=r.invert(i),c=r.invert(a);if(r.isCategory){var h=r.values.indexOf(u),v=r.values.indexOf(c),d=r.values.slice(h,v+1);return function(g){return d.includes(g)}}else return function(g){return g>=u&&g<=c}}var Vr;(function(r){r.FILTER="brush-filter-processing",r.RESET="brush-filter-reset",r.BEFORE_FILTER="brush-filter:beforefilter",r.AFTER_FILTER="brush-filter:afterfilter",r.BEFORE_RESET="brush-filter:beforereset",r.AFTER_RESET="brush-filter:afterreset"})(Vr||(Vr={}));var fE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.dims=["x","y"],t.startPoint=null,t.isStarted=!1,t}return e.prototype.hasDim=function(t){return this.dims.includes(t)},e.prototype.start=function(){var t=this.context;this.isStarted=!0,this.startPoint=t.getCurrentPoint()},e.prototype.filter=function(){var t,n;if(to(this.context)){var i=this.context.event.target,a=i.getCanvasBBox();t={x:a.x,y:a.y},n={x:a.maxX,y:a.maxY}}else{if(!this.isStarted)return;t=this.startPoint,n=this.context.getCurrentPoint()}if(!(Math.abs(t.x-n.x)<5||Math.abs(t.x-n.y)<5)){var o=this.context,s=o.view,l=o.event,u={view:s,event:l,dims:this.dims};s.emit(Vr.BEFORE_FILTER,lr.fromData(s,Vr.BEFORE_FILTER,u));var c=s.getCoordinate(),h=c.invert(n),v=c.invert(t);if(this.hasDim("x")){var d=s.getXScale(),g=Dp(d,"x",h,v);this.filterView(s,d.field,g)}if(this.hasDim("y")){var y=s.getYScales()[0],g=Dp(y,"y",h,v);this.filterView(s,y.field,g)}this.reRender(s,{source:Vr.FILTER}),s.emit(Vr.AFTER_FILTER,lr.fromData(s,Vr.AFTER_FILTER,u))}},e.prototype.end=function(){this.isStarted=!1},e.prototype.reset=function(){var t=this.context.view;if(t.emit(Vr.BEFORE_RESET,lr.fromData(t,Vr.BEFORE_RESET,{})),this.isStarted=!1,this.hasDim("x")){var n=t.getXScale();this.filterView(t,n.field,null)}if(this.hasDim("y")){var i=t.getYScales()[0];this.filterView(t,i.field,null)}this.reRender(t,{source:Vr.RESET}),t.emit(Vr.AFTER_RESET,lr.fromData(t,Vr.AFTER_RESET,{}))},e.prototype.filterView=function(t,n,i){t.filter(n,i)},e.prototype.reRender=function(t,n){t.render(!0,n)},e}(ar),Ws=fE,hE=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.filterView=function(t,n,i){var a=bn(t);(0,f.S6)(a,function(o){o.filter(n,i)})},e.prototype.reRender=function(t){var n=bn(t);(0,f.S6)(n,function(i){i.render(!0)})},e}(Ws),Ic=hE,vE=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.filter=function(){var t=Ti(this.context),n=this.context.view,i=Mr(n);if(to(this.context)){var a=Tu(this.context,10);a&&(0,f.S6)(i,function(y){a.includes(y)?y.show():y.hide()})}else if(t){var o=t.component,s=o.get("field");if(Qa(t)){if(s){var l=o.getItemsByState("unchecked"),u=sa(n,s),c=l.map(function(y){return y.name});(0,f.S6)(i,function(y){var x=hn(y,s),m=u.getText(x);c.indexOf(m)>=0?y.hide():y.show()})}}else if(iv(t)){var h=o.getValue(),v=(0,p.CR)(h,2),d=v[0],g=v[1];(0,f.S6)(i,function(y){var x=hn(y,s);x>=d&&x<=g?y.show():y.hide()})}}},e.prototype.clear=function(){var t=Mr(this.context.view);(0,f.S6)(t,function(n){n.show()})},e.prototype.reset=function(){this.clear()},e}(ar),dE=vE,pE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.byRecord=!1,t}return e.prototype.filter=function(){to(this.context)&&(this.byRecord?this.filterByRecord():this.filterByBBox())},e.prototype.filterByRecord=function(){var t=this.context.view,n=Tu(this.context,10);if(!!n){var i=t.getXScale().field,a=t.getYScales()[0].field,o=n.map(function(l){return l.getModel().data}),s=bn(t);(0,f.S6)(s,function(l){var u=Mr(l);(0,f.S6)(u,function(c){var h=c.getModel().data;hv(o,h,i,a)?c.show():c.hide()})})}},e.prototype.filterByBBox=function(){var t=this,n=this.context.view,i=bn(n);(0,f.S6)(i,function(a){var o=av(t.context,a,10),s=Mr(a);o&&(0,f.S6)(s,function(l){o.includes(l)?l.show():l.hide()})})},e.prototype.reset=function(){var t=bn(this.context.view);(0,f.S6)(t,function(n){var i=Mr(n);(0,f.S6)(i,function(a){a.show()})})},e}(ar),Op=pE,gE=10,yE=5,mE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.buttonGroup=null,t.buttonCfg={name:"button",text:"button",textStyle:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"},padding:[8,10],style:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},activeStyle:{fill:"#e6e6e6"}},t}return e.prototype.getButtonCfg=function(){return(0,f.b$)(this.buttonCfg,this.cfg)},e.prototype.drawButton=function(){var t=this.getButtonCfg(),n=this.context.view.foregroundGroup.addGroup({name:t.name}),i=n.addShape({type:"text",name:"button-text",attrs:(0,p.pi)({text:t.text},t.textStyle)}),a=i.getBBox(),o=Lu(t.padding),s=n.addShape({type:"rect",name:"button-rect",attrs:(0,p.pi)({x:a.x-o[3],y:a.y-o[0],width:a.width+o[1]+o[3],height:a.height+o[0]+o[2]},t.style)});s.toBack(),n.on("mouseenter",function(){s.attr(t.activeStyle)}),n.on("mouseleave",function(){s.attr(t.style)}),this.buttonGroup=n},e.prototype.resetPosition=function(){var t=this.context.view,n=t.getCoordinate(),i=n.convert({x:1,y:1}),a=this.buttonGroup,o=a.getBBox(),s=nr.vs(null,[["t",i.x-o.width-gE,i.y+o.height+yE]]);a.setMatrix(s)},e.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},e.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},e.prototype.destroy=function(){var t=this.buttonGroup;t&&t.remove(),r.prototype.destroy.call(this)},e}(ar),xE=mE,ME=4,wE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.starting=!1,t.dragStart=!1,t}return e.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint()},e.prototype.drag=function(){if(!!this.startPoint){var t=this.context.getCurrentPoint(),n=this.context.view,i=this.context.event;this.dragStart?n.emit("drag",{target:i.target,x:i.x,y:i.y}):Eu(t,this.startPoint)>ME&&(n.emit("dragstart",{target:i.target,x:i.x,y:i.y}),this.dragStart=!0)}},e.prototype.end=function(){if(this.dragStart){var t=this.context.view,n=this.context.event;t.emit("dragend",{target:n.target,x:n.x,y:n.y})}this.starting=!1,this.dragStart=!1},e}(ar),SE=wE,CE=5,AE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.starting=!1,t.isMoving=!1,t.startPoint=null,t.startMatrix=null,t}return e.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint(),this.startMatrix=this.context.view.middleGroup.getMatrix()},e.prototype.move=function(){if(!!this.starting){var t=this.startPoint,n=this.context.getCurrentPoint(),i=Eu(t,n);if(i>CE&&!this.isMoving&&(this.isMoving=!0),this.isMoving){var a=this.context.view,o=nr.vs(this.startMatrix,[["t",n.x-t.x,n.y-t.y]]);a.backgroundGroup.setMatrix(o),a.foregroundGroup.setMatrix(o),a.middleGroup.setMatrix(o)}}},e.prototype.end=function(){this.isMoving&&(this.isMoving=!1),this.startMatrix=null,this.starting=!1,this.startPoint=null},e.prototype.reset=function(){this.starting=!1,this.startPoint=null,this.isMoving=!1;var t=this.context.view;t.backgroundGroup.resetMatrix(),t.foregroundGroup.resetMatrix(),t.middleGroup.resetMatrix(),this.isMoving=!1},e}(ar),bE=AE,kp="x",Bp="y",TE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.dims=[kp,Bp],t.cfgFields=["dims"],t.cacheScaleDefs={},t}return e.prototype.hasDim=function(t){return this.dims.includes(t)},e.prototype.getScale=function(t){var n=this.context.view;return t==="x"?n.getXScale():n.getYScales()[0]},e.prototype.resetDim=function(t){var n=this.context.view;if(this.hasDim(t)&&this.cacheScaleDefs[t]){var i=this.getScale(t);n.scale(i.field,this.cacheScaleDefs[t]),this.cacheScaleDefs[t]=null}},e.prototype.reset=function(){this.resetDim(kp),this.resetDim(Bp);var t=this.context.view;t.render(!0)},e}(ar),Rp=TE,EE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.startPoint=null,t.starting=!1,t.startCache={},t}return e.prototype.start=function(){var t=this;this.startPoint=this.context.getCurrentPoint(),this.starting=!0;var n=this.dims;(0,f.S6)(n,function(i){var a=t.getScale(i),o=a.min,s=a.max,l=a.values;t.startCache[i]={min:o,max:s,values:l}})},e.prototype.end=function(){this.startPoint=null,this.starting=!1,this.startCache={}},e.prototype.translate=function(){var t=this;if(!!this.starting){var n=this.startPoint,i=this.context.view.getCoordinate(),a=this.context.getCurrentPoint(),o=i.invert(n),s=i.invert(a),l=s.x-o.x,u=s.y-o.y,c=this.context.view,h=this.dims;(0,f.S6)(h,function(v){t.translateDim(v,{x:l*-1,y:u*-1})}),c.render(!0)}},e.prototype.translateDim=function(t,n){if(this.hasDim(t)){var i=this.getScale(t);i.isLinear&&this.translateLinear(t,i,n)}},e.prototype.translateLinear=function(t,n,i){var a=this.context.view,o=this.startCache[t],s=o.min,l=o.max,u=l-s,c=i[t]*u;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:n.nice,min:s,max:l}),a.scale(n.field,{nice:!1,min:s+c,max:l+c})},e.prototype.reset=function(){r.prototype.reset.call(this),this.startPoint=null,this.starting=!1},e}(Rp),_E=EE,FE=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.zoomRatio=.05,t}return e.prototype.zoomIn=function(){this.zoom(this.zoomRatio)},e.prototype.zoom=function(t){var n=this,i=this.dims;(0,f.S6)(i,function(a){n.zoomDim(a,t)}),this.context.view.render(!0)},e.prototype.zoomOut=function(){this.zoom(-1*this.zoomRatio)},e.prototype.zoomDim=function(t,n){if(this.hasDim(t)){var i=this.getScale(t);i.isLinear&&this.zoomLinear(t,i,n)}},e.prototype.zoomLinear=function(t,n,i){var a=this.context.view;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:n.nice,min:n.min,max:n.max});var o=this.cacheScaleDefs[t],s=o.max-o.min,l=n.min,u=n.max,c=i*s,h=l-c,v=u+c,d=v-h,g=d/s;v>h&&g<100&&g>.01&&a.scale(n.field,{nice:!1,min:l-c,max:u+c})},e}(Rp),IE=FE;function PE(r){var e=r.gEvent.originalEvent;return e.deltaY>0}var LE=1,DE=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.scroll=function(t){var n=this.context,i=n.view,a=n.event;if(!!i.getOptions().scrollbar){var o=(t==null?void 0:t.wheelDelta)||LE,s=i.getController("scrollbar"),l=i.getXScale(),u=i.getOptions().data,c=(0,f.dp)((0,f.I)(u,l.field)),h=(0,f.dp)(l.values),v=s.getValue(),d=Math.floor((c-h)*v),g=d+(PE(a)?o:-o),y=o/(c-h)/1e4,x=(0,f.uZ)(g/(c-h)+y,0,1);s.setValue(x)}},e}(ar),OE=DE,kE="aixs-description-tooltip",BE=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.show=function(){var t=this.context,n=Ti(t).axis,i=n.cfg.title,a=i.description,o=i.text,s=i.descriptionTooltipStyle,l=t.event,u=l.x,c=l.y;this.tooltip||this.renderTooltip(),this.tooltip.update({title:o||"",customContent:function(){return`
  55. <div class="`.concat(Rn,'" style={').concat(s,`}>
  56. <div class="`).concat(Nn,`">
  57. \u5B57\u6BB5\u8BF4\u660E\uFF1A`).concat(a,`
  58. </div>
  59. </div>
  60. `)},x:u,y:c}),this.tooltip.show()},e.prototype.destroy=function(){r.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},e.prototype.hide=function(){this.tooltip&&this.tooltip.hide()},e.prototype.renderTooltip=function(){var t,n=this.context.view,i=n.canvas,a={start:{x:0,y:0},end:{x:i.get("width"),y:i.get("height")}},o=new us({parent:i.get("el").parentNode,region:a,visible:!1,containerId:kE,domStyles:(0,p.pi)({},(0,f.b$)({},(t={},t[Rn]={"max-width":"50%",padding:"10px","line-height":"15px","font-size":"12px",color:"rgba(0, 0, 0, .65)"},t[Nn]={"word-break":"break-all","margin-bottom":"3px"},t)))});o.init(),o.setCapture(!1),this.tooltip=o},e}(ar),RE=BE;fw("dark",gv(s2)),Ct("canvas",Ut),Ct("svg",ft),Tn("Polygon",$C),Tn("Interval",zC),Tn("Schema",KC),Tn("Path",nc),Tn("Point",XC),Tn("Line",HC),Tn("Area",IC),Tn("Edge",LC),Tn("Heatmap",OC),Tn("Violin",QC),ro("base",As),ro("interval",gA),ro("pie",xA),ro("polar",zd),Ur("overlap",DA),Ur("distribute",wA),Ur("fixed-overlap",LA),Ur("hide-overlap",GA),Ur("limit-in-shape",_A),Ur("limit-in-canvas",EA),Ur("limit-in-plot",ob),Ur("pie-outer",CA),Ur("adjust-color",XA),Ur("interval-adjust-position",qA),Ur("interval-hide-overlap",jA),Ur("point-adjust-position",tb),Ur("pie-spider",TA),Ur("path-adjust-position",nb),qr("fade-in",sb),qr("fade-out",lb),qr("grow-in-x",cb),qr("grow-in-xy",hb),qr("grow-in-y",fb),qr("scale-in-x",pb),qr("scale-in-y",gb),qr("wave-in",mb),qr("zoom-in",xb),qr("zoom-out",Mb),qr("position-update",db),qr("sector-path-update",yb),qr("path-in",vb),oa("rect",Ib),oa("mirror",_b),oa("list",Ab),oa("matrix",Tb),oa("circle",Sb),oa("tree",Lb),Ei("axis",Rb),Ei("legend",Hb),Ei("tooltip",bv),Ei("annotation",kb),Ei("slider",Yb),Ei("scrollbar",$b),Te("tooltip",vp),Te("sibling-tooltip",eT),Te("ellipsis-text",nT),Te("element-active",sT),Te("element-single-active",pT),Te("element-range-active",hT),Te("element-highlight",Cc),Te("element-highlight-by-x",MT),Te("element-highlight-by-color",mT),Te("element-single-highlight",CT),Te("element-range-highlight",gp),Te("element-sibling-highlight",gp,{effectSiblings:!0,effectByRecord:!0}),Te("element-selected",ET),Te("element-single-selected",FT),Te("element-range-selected",bT),Te("element-link-by-color",uT),Te("active-region",Jb),Te("list-active",LT),Te("list-selected",BT),Te("list-highlight",Ac),Te("list-unchecked",NT),Te("list-checked",zT),Te("list-focus",HT),Te("list-radio",YT),Te("legend-item-highlight",Ac,{componentNames:["legend"]}),Te("axis-label-highlight",Ac,{componentNames:["axis"]}),Te("axis-description",RE),Te("rect-mask",Cp),Te("x-rect-mask",Tp,{dim:"x"}),Te("y-rect-mask",Tp,{dim:"y"}),Te("circle-mask",ZT),Te("path-mask",_p),Te("smooth-path-mask",JT),Te("rect-multi-mask",Ip),Te("x-rect-multi-mask",Pp,{dim:"x"}),Te("y-rect-multi-mask",Pp,{dim:"y"}),Te("circle-multi-mask",nE),Te("path-multi-mask",Lp),Te("smooth-path-multi-mask",oE),Te("cursor",lE),Te("data-filter",cE),Te("brush",Ws),Te("brush-x",Ws,{dims:["x"]}),Te("brush-y",Ws,{dims:["y"]}),Te("sibling-filter",Ic),Te("sibling-x-filter",Ic,{dims:"x"}),Te("sibling-y-filter",Ic,{dims:"y"}),Te("element-filter",dE),Te("element-sibling-filter",Op),Te("element-sibling-filter-record",Op,{byRecord:!0}),Te("view-drag",SE),Te("view-move",bE),Te("scale-translate",_E),Te("scale-zoom",IE),Te("reset-button",xE,{name:"reset-button",text:"reset"}),Te("mousewheel-scroll",OE);function Vn(r){return r.isInPlot()}De("tooltip",{start:[{trigger:"plot:mousemove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:touchmove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseleave",action:"tooltip:hide"},{trigger:"plot:leave",action:"tooltip:hide"},{trigger:"plot:touchend",action:"tooltip:hide"}]}),De("ellipsis-text",{start:[{trigger:"legend-item-name:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"legend-item-name:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"legend-item-name:mouseleave",action:"ellipsis-text:hide"},{trigger:"legend-item-name:touchend",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseleave",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseout",action:"ellipsis-text:hide"},{trigger:"axis-label:touchend",action:"ellipsis-text:hide"}]}),De("element-active",{start:[{trigger:"element:mouseenter",action:"element-active:active"}],end:[{trigger:"element:mouseleave",action:"element-active:reset"}]}),De("element-selected",{start:[{trigger:"element:click",action:"element-selected:toggle"}]}),De("element-highlight",{start:[{trigger:"element:mouseenter",action:"element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight:reset"}]}),De("element-highlight-by-x",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-x:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-x:reset"}]}),De("element-highlight-by-color",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-color:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-color:reset"}]}),De("legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","element-active:reset"]}]}),De("legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","element-highlight:reset"]}]}),De("axis-label-highlight",{start:[{trigger:"axis-label:mouseenter",action:["axis-label-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"axis-label:mouseleave",action:["axis-label-highlight:reset","element-highlight:reset"]}]}),De("element-list-highlight",{start:[{trigger:"element:mouseenter",action:["list-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"element:mouseleave",action:["list-highlight:reset","element-highlight:reset"]}]}),De("element-range-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(r){return!r.isInShape("mask")},action:["rect-mask:start","rect-mask:show"]},{trigger:"mask:dragstart",action:["rect-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:drag",action:["rect-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end"]},{trigger:"mask:dragend",action:["rect-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(r){return!r.isInPlot()},action:["element-range-highlight:clear","rect-mask:end","rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","rect-mask:hide"]}]}),De("brush",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Vn,action:["brush:start","rect-mask:start","rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:Vn,action:["rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:Vn,action:["brush:filter","brush:end","rect-mask:end","rect-mask:hide","reset-button:show"]}],rollback:[{trigger:"reset-button:click",action:["brush:reset","reset-button:hide","cursor:crosshair"]}]}),De("brush-visible",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"plot:mousedown",action:["rect-mask:start","rect-mask:show"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end","rect-mask:hide","element-filter:filter","element-range-highlight:clear"]}],rollback:[{trigger:"dblclick",action:["element-filter:clear"]}]}),De("brush-x",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Vn,action:["brush-x:start","x-rect-mask:start","x-rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:Vn,action:["x-rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:Vn,action:["brush-x:filter","brush-x:end","x-rect-mask:end","x-rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]}),De("element-path-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Vn,action:"path-mask:start"},{trigger:"mousedown",isEnable:Vn,action:"path-mask:show"}],processing:[{trigger:"mousemove",action:"path-mask:addPoint"}],end:[{trigger:"mouseup",action:"path-mask:end"}],rollback:[{trigger:"dblclick",action:"path-mask:hide"}]}),De("brush-x-multi",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"mousedown",isEnable:Vn,action:["x-rect-multi-mask:start","x-rect-multi-mask:show"]},{trigger:"mask:dragstart",action:["x-rect-multi-mask:moveStart"]}],processing:[{trigger:"mousemove",isEnable:function(r){return!ms(r)},action:["x-rect-multi-mask:resize"]},{trigger:"multi-mask:change",action:"element-range-highlight:highlight"},{trigger:"mask:drag",action:["x-rect-multi-mask:move"]}],end:[{trigger:"mouseup",action:["x-rect-multi-mask:end"]},{trigger:"mask:dragend",action:["x-rect-multi-mask:moveEnd"]}],rollback:[{trigger:"dblclick",action:["x-rect-multi-mask:clear","cursor:crosshair"]},{trigger:"multi-mask:clearAll",action:["element-range-highlight:clear"]},{trigger:"multi-mask:clearSingle",action:["element-range-highlight:highlight"]}]}),De("element-single-selected",{start:[{trigger:"element:click",action:"element-single-selected:toggle"}]}),De("legend-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:["cursor:pointer","list-radio:show"]},{trigger:"legend-item:mouseleave",action:["cursor:default","list-radio:hide"]}],start:[{trigger:"legend-item:click",isEnable:function(r){return!r.isInShape("legend-item-radio")},action:["legend-item-highlight:reset","element-highlight:reset","list-unchecked:toggle","data-filter:filter","list-radio:show"]},{trigger:"legend-item-radio:mouseenter",action:["list-radio:showTip"]},{trigger:"legend-item-radio:mouseleave",action:["list-radio:hideTip"]},{trigger:"legend-item-radio:click",action:["list-focus:toggle","data-filter:filter","list-radio:show"]}]}),De("continuous-filter",{start:[{trigger:"legend:valuechanged",action:"data-filter:filter"}]}),De("continuous-visible-filter",{start:[{trigger:"legend:valuechanged",action:"element-filter:filter"}]}),De("legend-visible-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:["legend-item-highlight:reset","element-highlight:reset","list-unchecked:toggle","element-filter:filter"]}]}),De("active-region",{start:[{trigger:"plot:mousemove",action:"active-region:show"}],end:[{trigger:"plot:mouseleave",action:"active-region:hide"}]}),De("axis-description",{start:[{trigger:"axis-description:mousemove",action:"axis-description:show"}],end:[{trigger:"axis-description:mouseleave",action:"axis-description:hide"}]});function Np(r){return r.gEvent.preventDefault(),r.gEvent.originalEvent.deltaY>0}De("view-zoom",{start:[{trigger:"plot:mousewheel",isEnable:function(r){return Np(r.event)},action:"scale-zoom:zoomOut",throttle:{wait:100,leading:!0,trailing:!1}},{trigger:"plot:mousewheel",isEnable:function(r){return!Np(r.event)},action:"scale-zoom:zoomIn",throttle:{wait:100,leading:!0,trailing:!1}}]}),De("sibling-tooltip",{start:[{trigger:"plot:mousemove",action:"sibling-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"sibling-tooltip:hide"}]}),De("plot-mousewheel-scroll",{start:[{trigger:"plot:mousewheel",action:"mousewheel-scroll:scroll"}]});var Hr=["type","alias","tickCount","tickInterval","min","max","nice","minLimit","maxLimit","range","tickMethod","base","exponent","mask","sync"],pn;(function(r){r.ERROR="error",r.WARN="warn",r.INFO="log"})(pn||(pn={}));var Up="AntV/G2Plot";function zp(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];var n=0;return"".concat(Up,": ").concat(r.replace(/%s/g,function(){return"".concat(e[n++])}))}function v5(r,e){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];if(!r){var i=new Error(zp.apply(void 0,__spreadArray([e],t,!1)));throw i.name=Up,i}}function Hn(r,e,t){for(var n=[],i=3;i<arguments.length;i++)n[i-3]=arguments[i];e||console[r](zp.apply(void 0,(0,p.ev)([t],n,!1)))}function Qe(r,e){var t={};return r!==null&&typeof r=="object"&&e.forEach(function(n){var i=r[n];i!==void 0&&(t[n]=i)}),t}function Pc(r,e){if(!r)return{};var t=r.filter(function(a){var o=(0,f.U2)(a,[e]);return(0,f.hj)(o)&&!isNaN(o)}),n=t.every(function(a){return(0,f.U2)(a,[e])>=0}),i=t.every(function(a){return(0,f.U2)(a,[e])<=0});return n?{min:0}:i?{max:0}:{}}function Vp(r,e,t,n,i){if(i===void 0&&(i=[]),!Array.isArray(r))return{nodes:[],links:[]};var a=[],o={},s=-1;return r.forEach(function(l){var u=l[e],c=l[t],h=l[n],v=Qe(l,i);o[u]||(o[u]=(0,p.pi)({id:++s,name:u},v)),o[c]||(o[c]=(0,p.pi)({id:++s,name:c},v)),a.push((0,p.pi)({source:o[u].id,target:o[c].id,value:h},v))}),{nodes:Object.values(o).sort(function(l,u){return l.id-u.id}),links:a}}function pa(r,e){var t=(0,f.hX)(r,function(n){var i=n[e];return i===null||typeof i=="number"&&!isNaN(i)});return Hn(pn.WARN,t.length===r.length,"illegal data existed in chart data."),t}var NE=5,UE={}.toString,Hp=function(r,e){return UE.call(r)==="[object "+e+"]"},zE=function(r){return Hp(r,"Array")},VE=function(r){return typeof r=="object"&&r!==null},Gp=function(r){if(!VE(r)||!Hp(r,"Object"))return!1;for(var e=r;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(r)===e},Yp=function(r,e,t,n){t=t||0,n=n||NE;for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var a=e[i];a?Gp(a)?(Gp(r[i])||(r[i]={}),t<n?Yp(r[i],a,t+1,n):r[i]=e[i]):zE(a)?(r[i]=[],r[i]=r[i].concat(a)):r[i]=a:r[i]=a}},kt=function(r){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];for(var n=0;n<e.length;n+=1)Yp(r,e[n]);return r};function Lc(r){if(!r)return{width:0,height:0};var e=getComputedStyle(r);return{width:(r.clientWidth||parseInt(e.width,10))-parseInt(e.paddingLeft,10)-parseInt(e.paddingRight,10),height:(r.clientHeight||parseInt(e.height,10))-parseInt(e.paddingTop,10)-parseInt(e.paddingBottom,10)}}function Fe(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return function(t){return r.reduce(function(n,i){return i(n)},t)}}function br(r,e){return r.geometries.find(function(t){return t.type===e})}function Zs(r){return(0,f.u4)(r.geometries,function(e,t){return e.concat(t.elements)},[])}function go(r){return(0,f.U2)(r,["views","length"],0)<=0?Zs(r):(0,f.u4)(r.views,function(e,t){return e.concat(go(t))},Zs(r))}function HE(r){return(0,f.U2)(r,["views","length"],0)<=0?r.geometries:(0,f.u4)(r.views,function(e,t){return e.concat(t.geometries)},r.geometries)}function xr(r){if(!(0,f.P9)(r,"Object"))return r;var e=(0,p.pi)({},r);return e.formatter&&!e.content&&(e.content=e.formatter),e}var Dc;function GE(){return Dc||(Dc=document.createElement("canvas").getContext("2d")),Dc}var d5=(0,f.HP)(function(r,e){e===void 0&&(e={});var t=e.fontSize,n=e.fontFamily,i=n===void 0?"sans-serif":n,a=e.fontWeight,o=e.fontStyle,s=e.fontVariant,l=GE();l.font=[o,a,s,"".concat(t,"px"),i].join(" ");var u=l.measureText((0,f.HD)(r)?r:"");return u.width},function(r,e){return e===void 0&&(e={}),(0,p.ev)([r],(0,f.VO)(e),!0).join("")});function Oi(r){return typeof r=="number"&&!isNaN(r)}function YE(r,e,t){var n=Math.min(e,t),i=Math.max(e,t);return r>=n&&r<=i}function fi(r){if((0,f.hj)(r))return[r,r,r,r];if((0,f.kJ)(r)){var e=r.length;if(e===1)return[r[0],r[0],r[0],r[0]];if(e===2)return[r[0],r[1],r[0],r[1]];if(e===3)return[r[0],r[1],r[2],r[1]];if(e===4)return r}return[0,0,0,0]}function $s(r,e,t){e===void 0&&(e="bottom"),t===void 0&&(t=25);var n=fi(r),i=[e.startsWith("top")?t:0,e.startsWith("right")?t:0,e.startsWith("bottom")?t:0,e.startsWith("left")?t:0];return[n[0]+i[0],n[1]+i[1],n[2]+i[2],n[3]+i[3]]}function Oc(r){var e=r.map(function(n){return fi(n)}),t=[0,0,0,0];return e.length>0&&(t=t.map(function(n,i){return e.forEach(function(a,o){n+=e[o][i]}),n})),t}function XE(r,e){var t=[];if(r.length){t.push(["M",r[0].x,r[0].y]);for(var n=1,i=r.length;n<i;n+=1){var a=r[n];t.push(["L",a.x,a.y])}e&&t.push(["Z"])}return t}var WE=function(r,e,t,n){var i=[],a,o,s=!!n,l,u;if(s){l=[Infinity,Infinity],u=[-Infinity,-Infinity];for(var c=0,h=r.length;c<h;c++){var v=r[c];l=xe.VV([0,0],l,v),u=xe.Fp([0,0],u,v)}l=xe.VV([0,0],l,n[0]),u=xe.Fp([0,0],u,n[1])}for(var c=0,d=r.length;c<d;c++){var v=r[c];if(t)a=r[c?c-1:d-1],o=r[(c+1)%d];else if(c===0||c===d-1){i.push(v);continue}else a=r[c-1],o=r[c+1];var g=[0,0];g=xe.lu(g,o,a),g=xe.bA(g,g,e);var y=xe.TE(v,a),x=xe.TE(v,o),m=y+x;m!==0&&(y/=m,x/=m);var M=xe.bA([0,0],g,-y),w=xe.bA([0,0],g,x),S=xe.IH([0,0],v,M),b=xe.IH([0,0],v,w);s&&(S=xe.Fp([0,0],S,l),S=xe.VV([0,0],S,u),b=xe.Fp([0,0],b,l),b=xe.VV([0,0],b,u)),i.push(S),i.push(b)}return t&&i.push(i.shift()),i};function ZE(r,e,t){for(var n=!!e,i=[],a=0,o=r.length;a<o;a+=2)i.push([r[a],r[a+1]]);for(var s=WE(i,.4,n,t),l=i.length,u=[],c,h,v,a=0;a<l-1;a++)c=s[a*2],h=s[a*2+1],v=i[a+1],u.push(["C",c[0],c[1],h[0],h[1],v[0],v[1]]);return n&&(c=s[l],h=s[l+1],v=i[0],u.push(["C",c[0],c[1],h[0],h[1],v[0],v[1]])),u}function $E(r,e,t){var n=[],i=r[0],a=null;if(r.length<=2)return XE(r,e);for(var o=0,s=r.length;o<s;o++){var l=r[o];(!a||!(a.x===l.x&&a.y===l.y))&&(n.push(l.x),n.push(l.y),a=l)}var u=t||[[0,0],[1,1]],c=ZE(n,e,u);return c.unshift(["M",i.x,i.y]),c}function Xp(r){if(!r)return r;var e=r.match(/(([A-Z]{0,1}[a-z]*[^A-Z])|([A-Z]{1}))/g);return e.map(function(t){return t.toLowerCase()}).join("-")}function Wp(r){var e={overflow:"hidden","white-space":"nowrap","text-overflow":"ellipsis",display:"flex",justifyContent:"center",alignItems:"center"},t=["stroke","lineWidth","shadowColor","strokeOpacity","shadowBlur","shadowOffsetX","shadowOffsetY","fill"];(0,f.U2)(r,"fill")&&(e.color=r.fill);var n=Qe(r,t),i=n.shadowColor,a=n.shadowBlur,o=a===void 0?0:a,s=n.shadowOffsetX,l=s===void 0?0:s,u=n.shadowOffsetY,c=u===void 0?0:u;e["text-shadow"]="".concat([i,"".concat(l,"px"),"".concat(c,"px"),"".concat(o,"px")].join(" "));var h=Qe(r,t),v=h.stroke,d=h.lineWidth,g=d===void 0?0:d;return e["-webkit-text-stroke"]="".concat(["".concat(g,"px"),v].join(" ")),(0,f.S6)(r,function(y,x){["fontSize"].includes(x)&&(0,f.hj)(y)?e[Xp(x)]="".concat(y,"px"):x&&!t.includes(x)&&(e[Xp(x)]="".concat(y))}),e}function Zp(r,e){r.style["pointer-events"]="none",(0,f.S6)(e,function(t,n){n&&t&&(r.style[n]=t)})}var qs=function(r,e,t){var n=e.statistic,i=e.plotType,a=n.title,o=n.content;[a,o].forEach(function(s,l){if(!!s){var u="";l===0?u=o?"translate(-50%, -100%)":"translate(-50%, -50%)":u=a?"translate(-50%, 0)":"translate(-50%, -50%)";var c=(0,f.mf)(s.style)?s.style(t):s.style;r.annotation().html((0,p.pi)({position:["50%","50%"],html:function(h,v){var d=v.getCoordinate(),g=0;if(i==="pie"||i==="ring-progress")g=d.getRadius()*d.innerRadius*2;else if(i==="liquid"){var y=(0,f.U2)(v.geometries,[0,"elements",0,"shape"]);if(y){var x=y.find(function(S){return S.get("name")==="wrap"}),m=x.getCanvasBBox().width;g=m}}else g||(g=d.getWidth());Zp(h,(0,p.pi)({width:"".concat(g,"px"),transform:u},Wp(c)));var M=v.getData();if(s.customHtml)return s.customHtml(h,v,t,M);var w=s.content;return s.formatter&&(w=s.formatter(t,M)),w?(0,f.HD)(w)?w:"".concat(w):"<div></div>"},key:"".concat(l===0?"top":"bottom","-statistic")},Qe(s,["offsetX","offsetY","rotate","style","formatter"])))}})},qE=function(r,e,t){var n=e.statistic,i=n.title,a=n.content;[i,a].forEach(function(o){if(!!o){var s=(0,f.mf)(o.style)?o.style(t):o.style;r.annotation().html((0,p.pi)({position:["50%","100%"],html:function(l,u){var c=u.getCoordinate(),h=u.views[0].getCoordinate(),v=h.getCenter(),d=h.getRadius(),g=Math.max(Math.sin(h.startAngle),Math.sin(h.endAngle))*d,y=v.y+g-c.y.start-parseFloat((0,f.U2)(s,"fontSize",0)),x=c.getRadius()*c.innerRadius*2;Zp(l,(0,p.pi)({width:"".concat(x,"px"),transform:"translate(-50%, ".concat(y,"px)")},Wp(s)));var m=u.getData();if(o.customHtml)return o.customHtml(l,u,t,m);var M=o.content;return o.formatter&&(M=o.formatter(t,m)),M?(0,f.HD)(M)?M:"".concat(M):"<div></div>"}},Qe(o,["offsetX","offsetY","rotate","style","formatter"])))}})};function $p(r,e){return e?(0,f.u4)(e,function(t,n,i){return t.replace(new RegExp("{\\s*".concat(i,"\\s*}"),"g"),n)},r):r}function Ve(r,e){return r.views.find(function(t){return t.id===e})}function yo(r){var e=r.parent;return e?e.views:[]}function qp(r){return yo(r).filter(function(e){return e!==r})}function mo(r,e,t){t===void 0&&(t=r.geometries),typeof e=="boolean"?r.animate(e):r.animate(!0),(0,f.S6)(t,function(n){var i;(0,f.mf)(e)?i=e(n.type||n.shapeType,n)||!0:i=e,n.animate(i)})}function Ks(){return typeof window=="object"?window==null?void 0:window.devicePixelRatio:2}function kc(r,e){e===void 0&&(e=r);var t=document.createElement("canvas"),n=Ks();t.width=r*n,t.height=e*n,t.style.width="".concat(r,"px"),t.style.height="".concat(e,"px");var i=t.getContext("2d");return i.scale(n,n),t}function Bc(r,e,t,n){n===void 0&&(n=t);var i=e.backgroundColor,a=e.opacity;r.globalAlpha=a,r.fillStyle=i,r.beginPath(),r.fillRect(0,0,t,n),r.closePath()}function Kp(r,e,t){var n=r+e;return t?n*2:n}function jp(r,e){var t=e?[[r*(1/4),r*(1/4)],[r*(3/4),r*(3/4)]]:[[r*(1/2),r*(1/2)]];return t}function Rc(r,e){var t=e*Math.PI/180,n={a:Math.cos(t)*(1/r),b:Math.sin(t)*(1/r),c:-Math.sin(t)*(1/r),d:Math.cos(t)*(1/r),e:0,f:0};return n}var KE={size:6,padding:2,backgroundColor:"transparent",opacity:1,rotation:0,fill:"#fff",fillOpacity:.5,stroke:"transparent",lineWidth:0,isStagger:!0};function jE(r,e,t,n){var i=e.size,a=e.fill,o=e.lineWidth,s=e.stroke,l=e.fillOpacity;r.beginPath(),r.globalAlpha=l,r.fillStyle=a,r.strokeStyle=s,r.lineWidth=o,r.arc(t,n,i/2,0,2*Math.PI,!1),r.fill(),o&&r.stroke(),r.closePath()}function JE(r){var e=kt({},KE,r),t=e.size,n=e.padding,i=e.isStagger,a=e.rotation,o=Kp(t,n,i),s=jp(o,i),l=kc(o,o),u=l.getContext("2d");Bc(u,e,o);for(var c=0,h=s;c<h.length;c++){var v=h[c],d=v[0],g=v[1];jE(u,e,d,g)}var y=u.createPattern(l,"repeat");if(y){var x=Ks(),m=Rc(x,a);y.setTransform(m)}return y}var QE={rotation:45,spacing:5,opacity:1,backgroundColor:"transparent",strokeOpacity:.5,stroke:"#fff",lineWidth:2};function t_(r,e,t){var n=e.stroke,i=e.lineWidth,a=e.strokeOpacity,o=new Path2D(t);r.globalAlpha=a,r.lineCap="square",r.strokeStyle=i?n:"transparent",r.lineWidth=i,r.stroke(o)}function e_(r){var e=kt({},QE,r),t=e.spacing,n=e.rotation,i=e.lineWidth,a=t+i||1,o=t+i||1,s=`
  61. M 0 0 L `.concat(a,` 0
  62. M 0 `).concat(o," L ").concat(a," ").concat(o,`
  63. `),l=kc(a,o),u=l.getContext("2d");Bc(u,e,a,o),t_(u,e,s);var c=u.createPattern(l,"repeat");if(c){var h=Ks(),v=Rc(h,n);c.setTransform(v)}return c}var r_={size:6,padding:1,isStagger:!0,backgroundColor:"transparent",opacity:1,rotation:0,fill:"#fff",fillOpacity:.5,stroke:"transparent",lineWidth:0};function n_(r,e,t,n){var i=e.stroke,a=e.size,o=e.fill,s=e.lineWidth,l=e.fillOpacity;r.globalAlpha=l,r.strokeStyle=i,r.lineWidth=s,r.fillStyle=o,r.strokeRect(t-a/2,n-a/2,a,a),r.fillRect(t-a/2,n-a/2,a,a)}function i_(r){var e=kt({},r_,r),t=e.size,n=e.padding,i=e.isStagger,a=e.rotation,o=Kp(t,n,i),s=jp(o,i),l=kc(o,o),u=l.getContext("2d");Bc(u,e,o);for(var c=0,h=s;c<h.length;c++){var v=h[c],d=v[0],g=v[1];n_(u,e,d,g)}var y=u.createPattern(l,"repeat");if(y){var x=Ks(),m=Rc(x,a);y.setTransform(m)}return y}function a_(r){var e=r.type,t=r.cfg,n;switch(e){case"dot":n=JE(t);break;case"line":n=e_(t);break;case"square":n=i_(t);break;default:break}return n}function Kr(r){var e=this;return function(t){var n,i=t.options,a=t.chart,o=i.pattern;if(!o)return t;var s=function(l){for(var u,c,h,v=[],d=1;d<arguments.length;d++)v[d-1]=arguments[d];var g=a.getTheme().defaultColor,y=g,x=(c=(u=a.geometries)===null||u===void 0?void 0:u[0])===null||c===void 0?void 0:c.getAttribute("color");if(x){var m=x.getFields()[0],M=(0,f.U2)(l,m);y=zr.getMappingValue(x,M,((h=x.values)===null||h===void 0?void 0:h[0])||g)}var w=o;typeof o=="function"&&(w=o.call(e,l,y)),w instanceof CanvasPattern||(w=a_(kt({},{cfg:{backgroundColor:y}},w)));var S=i[r];return(0,p.pi)((0,p.pi)({},typeof S=="function"?S.call.apply(S,(0,p.ev)([e,l],v,!1)):S||{}),{fill:w||y})};return kt({},t,{options:(n={},n[r]=s,n)})}}function ki(r){var e=r.chart,t=r.options,n=t.legend,i=t.colorField,a=t.seriesField;return n===!1?e.legend(!1):(i||a)&&e.legend(i||a,n),r}function pr(r){var e=r.chart,t=r.options,n=t.tooltip;return n!==void 0&&e.tooltip(n),r}function or(r){var e=r.chart,t=r.options,n=t.interactions;return(0,f.S6)(n,function(i){i.enable===!1?e.removeInteraction(i.type):e.interaction(i.type,i.cfg||{})}),r}function tr(r){var e=r.chart,t=r.options,n=t.animation;return mo(e,n),r}function We(r){var e=r.chart,t=r.options,n=t.theme;return n&&e.theme(n),r}function hi(r){var e=r.chart,t=r.options,n=t.state;return n&&(0,f.S6)(e.geometries,function(i){i.state(n)}),r}function xo(r){var e=r.chart,t=r.options,n=t.slider;return e.option("slider",n),r}function Nc(r){var e=r.chart,t=r.options,n=t.scrollbar;return e.option("scrollbar",n),r}function ur(r,e){return function(t){var n=t.chart,i=t.options,a={};return(0,f.S6)(r,function(o,s){a[s]=Qe(o,Hr)}),a=kt({},e,i.meta,a),n.scale(a),t}}function sr(r){return function(e){var t=e.chart,n=e.options,i=t.getController("annotation");return(0,f.S6)((0,p.ev)((0,p.ev)([],n.annotations||[],!0),r||[],!0),function(a){i.annotation(a)}),e}}function Bi(r){var e=r.chart,t=r.options,n=t.yAxis,i=t.limitInPlot,a=i;return(0,f.Kn)(n)&&(0,f.UM)(i)&&(Object.values(Qe(n,["min","max","minLimit","maxLimit"])).some(function(o){return!(0,f.UM)(o)})?a=!0:a=!1),e.limitInPlot=a,r}function Jp(r){return r===void 0&&(r="rect"),function(e){var t=e.chart,n=e.options,i=n.coordinate,a=Array.from(i||[]).map(function(o){return o.type==="reflectX"?["reflect","x"]:o.type==="reflectY"?["reflect","y"]:o.type==="transpose"?["transpose"]:null}).filter(function(o){return!!o});return a.length!==0&&t.coordinate({type:r,actions:a}),e}}var Qp={locale:"en-US"};function p5(r){each(r,function(e,t){return Qp[t]=e})}var js={};function tg(r,e){js[r]=e}function Js(r){return{get:function(e,t){return $p((0,f.U2)(js[r],e)||(0,f.U2)(js[Qp.locale],e)||(0,f.U2)(js["en-US"],e)||e,t)}}}var o_={locale:"en-US",general:{increase:"Increase",decrease:"Decrease",root:"Root"},statistic:{total:"Total"},conversionTag:{label:"Rate"},legend:{},tooltip:{},slider:{},scrollbar:{},waterfall:{total:"Total"}},s_={locale:"zh-CN",general:{increase:"\u589E\u52A0",decrease:"\u51CF\u5C11",root:"\u521D\u59CB"},statistic:{total:"\u603B\u8BA1"},conversionTag:{label:"\u8F6C\u5316\u7387"},legend:{},tooltip:{},slider:{},scrollbar:{},waterfall:{total:"\u603B\u8BA1"}};function sn(r,e){if(r===!1)return{fields:!1};var t=(0,f.U2)(r,"fields"),n=(0,f.U2)(r,"formatter");return n&&!t&&(t=e),{fields:t,formatter:n}}function Qs(r,e){var t=r.type,n=r.xField,i=r.yField,a=r.colorField,o=r.shapeField,s=r.sizeField,l=r.styleField,u=r.rawFields,c=[];if(u=((0,f.mf)(u)?u(t,e):u)||[],e==="color")c=(0,p.ev)([a||n],u,!0);else if(e==="shape")c=(0,p.ev)([o||n],u,!0);else if(e==="size")c=(0,p.ev)([s||n],u,!0);else{c=(0,p.ev)([n,i,a,o,s,l],u,!0);var h=["x","y","color","shape","size","style"].indexOf(e),v=c[h];c.splice(h,1),c.unshift(v)}var d=(0,f.jj)(c.filter(function(y){return!!y})),g=t==="line"&&[n,i].includes(d.join("*"))?"":d.join("*");return{mappingFields:d,tileMappingField:g}}function ga(r,e){if(!!e)return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var i={};return r.forEach(function(a,o){i[a]=t[o]}),delete i.undefined,e(i)}}function Gr(r){var e=r.chart,t=r.options,n=t.type,i=t.args,a=t.mapping,o=t.xField,s=t.yField,l=t.colorField,u=t.shapeField,c=t.sizeField,h=t.tooltipFields,v=t.label,d=t.state,g=t.customInfo;if(!a)return r;var y=a.color,x=a.shape,m=a.size,M=a.style,w=a.tooltip,S=e[n](i).position("".concat(o,"*").concat(s));if((0,f.HD)(y))l?S.color(l,y):S.color(y);else if((0,f.mf)(y)){var b=Qs(t,"color"),k=b.mappingFields,H=b.tileMappingField;S.color(H,ga(k,y))}else l&&S.color(l,y);if((0,f.HD)(x))u?S.shape(u,[x]):S.shape(x);else if((0,f.mf)(x)){var at=Qs(t,"shape"),k=at.mappingFields,H=at.tileMappingField;S.shape(H,ga(k,x))}else u&&S.shape(u,x);if((0,f.hj)(m))c?S.size(c,m):S.size(m);else if((0,f.mf)(m)){var At=Qs(t,"size"),k=At.mappingFields,H=At.tileMappingField;S.size(H,ga(k,m))}else c&&S.size(c,m);if((0,f.mf)(M)){var gt=Qs(t,"style"),k=gt.mappingFields,H=gt.tileMappingField;S.style(H,ga(k,M))}else(0,f.Kn)(M)&&S.style(M);if(h===!1?S.tooltip(!1):(0,f.xb)(h)||S.tooltip(h.join("*"),ga(h,w)),v===!1)S.label(!1);else if(v){var Nt=v.callback,te=v.fields,ce=(0,p._T)(v,["callback","fields"]);S.label({fields:te||[s],callback:Nt,cfg:xr(ce)})}return d&&S.state(d),g&&S.customInfo(g),[o,s].filter(function(Me){return Me!==l}).forEach(function(Me){e.legend(Me,!1)}),(0,p.pi)((0,p.pi)({},r),{ext:{geometry:S}})}function tl(r){var e=r.options,t=e.area,n=e.xField,i=e.yField,a=e.seriesField,o=e.smooth,s=e.tooltip,l=e.useDeferredLabel,u=sn(s,[n,i,a]),c=u.fields,h=u.formatter;return t?Gr(kt({},r,{options:{type:"area",colorField:a,tooltipFields:c,mapping:(0,f.b$)({shape:o?"smooth":"area",tooltip:h},t),args:{useDeferredLabel:l}}})):r}function eg(r){var e=r.options,t=e.edge,n=e.xField,i=e.yField,a=e.seriesField,o=e.tooltip,s=e.useDeferredLabel,l=sn(o,[n,i,a]),u=l.fields,c=l.formatter;return t?Gr(kt({},r,{options:{type:"edge",colorField:a,tooltipFields:u,mapping:(0,p.pi)({tooltip:c},t),args:{useDeferredLabel:s}}})):r}function l_(r){var e=r.chart,t=r.options,n=r.ext,i=t.seriesField,a=t.isGroup,o=t.isStack,s=t.marginRatio,l=t.widthRatio,u=t.groupField,c=t.theme,h=[];if(i&&(a&&h.push({type:"dodge",dodgeBy:u||i,marginRatio:s}),o&&h.push({type:"stack",marginRatio:s})),h.length&&(n==null?void 0:n.geometry)){var v=n==null?void 0:n.geometry;v.adjust(h)}return(0,f.UM)(l)||e.theme(kt({},(0,f.Kn)(c)?c:eo(c),{columnWidthRatio:l})),r}function Tr(r){var e=r.options,t=e.xField,n=e.yField,i=e.interval,a=e.seriesField,o=e.tooltip,s=e.minColumnWidth,l=e.maxColumnWidth,u=e.columnBackground,c=e.dodgePadding,h=e.intervalPadding,v=e.useDeferredLabel,d=sn(o,[t,n,a]),g=d.fields,y=d.formatter,x=(i?Gr(kt({},r,{options:{type:"interval",colorField:a,tooltipFields:g,mapping:(0,p.pi)({tooltip:y},i),args:{dodgePadding:c,intervalPadding:h,minColumnWidth:s,maxColumnWidth:l,background:u,useDeferredLabel:v}}})):r).ext;return l_((0,p.pi)((0,p.pi)({},r),{ext:x}))}function ya(r){var e=r.options,t=e.line,n=e.stepType,i=e.xField,a=e.yField,o=e.seriesField,s=e.smooth,l=e.connectNulls,u=e.tooltip,c=e.useDeferredLabel,h=sn(u,[i,a,o]),v=h.fields,d=h.formatter;return t?Gr(kt({},r,{options:{type:"line",colorField:o,tooltipFields:v,mapping:(0,f.b$)({shape:n||(s?"smooth":"line"),tooltip:d},t),args:{connectNulls:l,useDeferredLabel:c}}})):r}function jr(r){var e=r.options,t=e.point,n=e.xField,i=e.yField,a=e.seriesField,o=e.sizeField,s=e.shapeField,l=e.tooltip,u=e.useDeferredLabel,c=sn(l,[n,i,a,o,s]),h=c.fields,v=c.formatter;return t?Gr(kt({},r,{options:{type:"point",colorField:a,shapeField:s,tooltipFields:h,mapping:(0,p.pi)({tooltip:v},t),args:{useDeferredLabel:u}}})):r}function el(r){var e=r.options,t=e.polygon,n=e.xField,i=e.yField,a=e.seriesField,o=e.tooltip,s=e.useDeferredLabel,l=sn(o,[n,i,a]),u=l.fields,c=l.formatter;return t?Gr(kt({},r,{options:{type:"polygon",colorField:a,tooltipFields:u,mapping:(0,p.pi)({tooltip:c},t),args:{useDeferredLabel:s}}})):r}function Uc(r){var e=r.options,t=e.schema,n=e.xField,i=e.yField,a=e.seriesField,o=e.tooltip,s=e.useDeferredLabel,l=sn(o,[n,i,a]),u=l.fields,c=l.formatter;return t?Gr(kt({},r,{options:{type:"schema",colorField:a,tooltipFields:u,mapping:(0,p.pi)({tooltip:c},t),args:{useDeferredLabel:s}}})):r}function u_(r){var e=r.options,t=e.violin,n=e.xField,i=e.yField,a=e.seriesField,o=e.sizeField,s=e.tooltip,l=sn(s,[n,i,a,o]),u=l.fields,c=l.formatter;return t?Gr(kt({},r,{options:{type:"violin",colorField:a,tooltipFields:u,mapping:(0,p.pi)({tooltip:c},t)}})):r}var c_=N(18587),rg="data-chart-source-type",ng=["padding","appendPadding","renderer","pixelRatio","syncViewPadding","supportCSSTransform","limitInPlot"],Re=function(r){(0,p.ZT)(e,r);function e(t,n){var i=r.call(this)||this;return i.container=typeof t=="string"?document.getElementById(t):t,i.options=kt({},i.getDefaultOptions(),n),i.createG2(),i.bindEvents(),i}return e.getDefaultOptions=function(){return{renderer:"canvas",xAxis:{nice:!0,label:{autoRotate:!1,autoHide:{type:"equidistance",cfg:{minGap:6}}}},yAxis:{nice:!0,label:{autoHide:!0,autoRotate:!1}},animation:!0}},e.prototype.createG2=function(){var t=this.options,n=t.width,i=t.height,a=t.defaultInteractions;this.chart=new Pw((0,p.pi)((0,p.pi)((0,p.pi)((0,p.pi)({container:this.container,autoFit:!1},this.getChartSize(n,i)),{localRefresh:!1}),Qe(this.options,ng)),{defaultInteractions:a})),this.container.setAttribute(rg,"G2Plot")},e.prototype.getChartSize=function(t,n){var i=Lc(this.container);return{width:t||i.width||400,height:n||i.height||400}},e.prototype.bindEvents=function(){var t=this;this.chart&&this.chart.on("*",function(n){(n==null?void 0:n.type)&&t.emit(n.type,n)})},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.render=function(){this.chart.clear(),this.chart.options={data:[],animate:!0},this.chart.views=[],this.execAdaptor(),this.chart.render(),this.bindSizeSensor()},e.prototype.update=function(t){this.updateOption(t),this.render()},e.prototype.updateOption=function(t){this.options=kt({},this.options,t)},e.prototype.setState=function(t,n,i){i===void 0&&(i=!0);var a=go(this.chart);(0,f.S6)(a,function(o){n(o.getData())&&o.setState(t,i)})},e.prototype.getStates=function(){var t=go(this.chart),n=[];return(0,f.S6)(t,function(i){var a=i.getData(),o=i.getStates();(0,f.S6)(o,function(s){n.push({data:a,state:s,geometry:i.geometry,element:i})})}),n},e.prototype.changeData=function(t){this.update({data:t})},e.prototype.changeSize=function(t,n){this.chart.changeSize(t,n)},e.prototype.addAnnotations=function(t,n){n=n||this.chart;var i=(0,p.ev)([],t,!0),a=n.getController("annotation"),o=a.getComponents().map(function(u){return u.extra});a.clear(!0);for(var s=function(u){var c=o[u],h=i.findIndex(function(v){return v.id&&v.id===c.id});h!==-1&&(c=kt({},c,i[h]),i.splice(h,1)),a.annotation(c)},l=0;l<o.length;l++)s(l);i.forEach(function(u){return a.annotation(u)}),n.render(!0)},e.prototype.removeAnnotations=function(t){var n=this.chart.getController("annotation"),i=n.getComponents().map(function(s){return s.extra});n.clear(!0);for(var a=function(s){var l=i[s];t.find(function(u){return u.id&&u.id===l.id})||n.annotation(l)},o=0;o<i.length;o++)a(o);this.chart.render(!0)},e.prototype.destroy=function(){this.unbindSizeSensor(),this.chart.destroy(),this.off(),this.container.removeAttribute(rg)},e.prototype.execAdaptor=function(){var t=this.getSchemaAdaptor(),n=this.options,i=n.padding,a=n.appendPadding;this.chart.padding=i,this.chart.appendPadding=a,t({chart:this.chart,options:this.options})},e.prototype.triggerResize=function(){this.chart.forceFit()},e.prototype.bindSizeSensor=function(){var t=this;if(!this.unbind){var n=this.options.autoFit,i=n===void 0?!0:n;i&&(this.unbind=(0,c_.ak)(this.container,function(){var a=Lc(t.container),o=a.width,s=a.height;(o!==t.chart.width||s!==t.chart.height)&&t.triggerResize()}))}},e.prototype.unbindSizeSensor=function(){this.unbind&&(this.unbind(),this.unbind=void 0)},e}(Q.Z);function ig(r,e,t,n){var i=(0,f.u4)(r,function(a,o){var s=o[t],l=a.has(s)?a.get(s):0,u=o[e];return l=Oi(u)?l+u:l,a.set(s,l),a},new Map);return(0,f.UI)(r,function(a){var o,s=a[e],l=a[t],u=Oi(s)&&i.get(l)!==0?s/i.get(l):0;return(0,p.pi)((0,p.pi)({},a),(o={},o[n]=u,o))})}function f_(r,e,t,n){var i=(0,f.u4)(r,function(a,o){var s=(0,f.u4)(t,function(c,h){return"".concat(c).concat(o[h])},""),l=a.has(s)?a.get(s):0,u=o[e];return l=Oi(u)?l+u:l,a.set(s,l),a},new Map);return(0,f.UI)(r,function(a){var o,s=a[e],l=(0,f.u4)(t,function(c,h){return"".concat(c).concat(a[h])},""),u=Oi(s)&&i.get(l)!==0?s/i.get(l):0;return(0,p.pi)((0,p.pi)({},a),(o={},o[n]=u,o))})}function Mo(r,e,t,n,i){return i?ig(r,e,t,n):r}function h_(r){var e=r.chart,t=r.options,n=t.data,i=t.color,a=t.lineStyle,o=t.lineShape,s=t.point,l=t.area,u=t.seriesField,c=s==null?void 0:s.state,h=l==null?void 0:l.state;e.data(n);var v=kt({},r,{options:{shapeField:u,line:{color:i,style:a,shape:o},point:s&&(0,p.pi)({color:i,shape:"circle"},s),area:l&&(0,p.pi)({color:i},l),label:void 0}}),d=kt({},v,{options:{tooltip:!1,state:c}}),g=kt({},v,{options:{tooltip:!1,state:h}});return ya(v),jr(d),tl(g),r}function rl(r){var e,t,n=r.options,i=n.xAxis,a=n.yAxis,o=n.xField,s=n.yField,l=n.data;return Fe(ur((e={},e[o]=i,e[s]=a,e),(t={},t[o]={type:"cat"},t[s]=Pc(l,s),t)))(r)}function v_(r){var e=r.chart,t=r.options,n=t.reflect;if(n){var i=n;(0,f.kJ)(i)||(i=[i]);var a=i.map(function(o){return["reflect",o]});e.coordinate({type:"rect",actions:a})}return r}function ag(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return n===!1?e.axis(a,!1):e.axis(a,n),i===!1?e.axis(o,!1):e.axis(o,i),r}function og(r){var e=r.chart,t=r.options,n=t.legend,i=t.seriesField;return n&&i?e.legend(i,n):n===!1&&e.legend(!1),r}function d_(r){var e=r.chart,t=r.options,n=t.label,i=t.yField,a=br(e,"line");if(!n)a.label(!1);else{var o=n.callback,s=(0,p._T)(n,["callback"]);a.label({fields:[i],callback:o,cfg:(0,p.pi)({layout:[{type:"limit-in-plot"},{type:"path-adjust-position"},{type:"point-adjust-position"},{type:"limit-in-plot",cfg:{action:"hide"}}]},xr(s))})}return r}function p_(r){var e=r.chart,t=r.options,n=t.isStack;return n&&(0,f.S6)(e.geometries,function(i){i.adjust("stack")}),r}function sg(r){return Fe(h_,rl,p_,We,v_,ag,og,pr,d_,xo,Nc,or,tr,sr(),Bi)(r)}function g_(r){var e=r.chart,t=r.options,n=t.data,i=t.areaStyle,a=t.areaShape,o=t.color,s=t.point,l=t.line,u=t.isPercent,c=t.xField,h=t.yField,v=t.tooltip,d=t.seriesField,g=t.startOnZero,y=s==null?void 0:s.state,x=Mo(n,h,c,h,u);e.data(x);var m=u?(0,p.pi)({formatter:function(b){return{name:b[d]||b[c],value:(Number(b[h])*100).toFixed(2)+"%"}}},v):v,M=kt({},r,{options:{area:{color:o,style:i,shape:a},point:s&&(0,p.pi)({color:o},s),tooltip:m,label:void 0,args:{startOnZero:g}}}),w={chart:e,options:kt({line:{size:2}},(0,f.CE)(t,["state"]),{line:l&&(0,p.pi)({color:o},l),sizeField:d,state:l==null?void 0:l.state,tooltip:!1,label:void 0,args:{startOnZero:g}})},S=kt({},M,{options:{tooltip:!1,state:y}});return tl(M),ya(w),jr(S),r}function y_(r){var e=r.chart,t=r.options,n=t.label,i=t.yField,a=br(e,"area");if(!n)a.label(!1);else{var o=n.callback,s=(0,p._T)(n,["callback"]);a.label({fields:[i],callback:o,cfg:(0,p.pi)({layout:[{type:"limit-in-plot"},{type:"path-adjust-position"},{type:"point-adjust-position"},{type:"limit-in-plot",cfg:{action:"hide"}}]},xr(s))})}return r}function m_(r){var e=r.chart,t=r.options,n=t.isStack,i=t.isPercent,a=t.seriesField;return(i||n)&&a&&(0,f.S6)(e.geometries,function(o){o.adjust("stack")}),r}function lg(r){return Fe(We,Kr("areaStyle"),Jp("rect"),g_,rl,m_,ag,og,pr,y_,xo,sr(),or,tr,Bi)(r)}var x_=kt({},Re.getDefaultOptions(),{tooltip:{shared:!0,showMarkers:!0,showCrosshairs:!0,crosshairs:{type:"x"}},isStack:!0,line:{},legend:{position:"top-left",radio:{}}}),ug=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="area",t}return e.getDefaultOptions=function(){return x_},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this.options,i=n.isPercent,a=n.xField,o=n.yField,s=this,l=s.chart,u=s.options;rl({chart:l,options:u}),this.chart.changeData(Mo(t,o,a,o,i))},e.prototype.getSchemaAdaptor=function(){return lg},e}(Re),M_=10,w_=5,S_={padding:[8,10],text:"reset",textStyle:{default:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"}},buttonStyle:{default:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},active:{fill:"#e6e6e6"}}},C_=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.buttonGroup=null,t.buttonCfg=(0,p.pi)({name:"button"},S_),t}return e.prototype.getButtonCfg=function(){var t=this.context.view,n=(0,f.U2)(t,["interactions","filter-action","cfg","buttonConfig"]);return kt(this.buttonCfg,n,this.cfg)},e.prototype.drawButton=function(){var t=this.getButtonCfg(),n=this.context.view.foregroundGroup.addGroup({name:t.name}),i=this.drawText(n);this.drawBackground(n,i.getBBox()),this.buttonGroup=n},e.prototype.drawText=function(t){var n,i=this.getButtonCfg();return t.addShape({type:"text",name:"button-text",attrs:(0,p.pi)({text:i.text},(n=i.textStyle)===null||n===void 0?void 0:n.default)})},e.prototype.drawBackground=function(t,n){var i,a=this.getButtonCfg(),o=fi(a.padding),s=t.addShape({type:"rect",name:"button-rect",attrs:(0,p.pi)({x:n.x-o[3],y:n.y-o[0],width:n.width+o[1]+o[3],height:n.height+o[0]+o[2]},(i=a.buttonStyle)===null||i===void 0?void 0:i.default)});return s.toBack(),t.on("mouseenter",function(){var l;s.attr((l=a.buttonStyle)===null||l===void 0?void 0:l.active)}),t.on("mouseleave",function(){var l;s.attr((l=a.buttonStyle)===null||l===void 0?void 0:l.default)}),s},e.prototype.resetPosition=function(){var t=this.context.view,n=t.getCoordinate(),i=n.convert({x:1,y:1}),a=this.buttonGroup,o=a.getBBox(),s=zr.transform(null,[["t",i.x-o.width-M_,i.y+o.height+w_]]);a.setMatrix(s)},e.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},e.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},e.prototype.destroy=function(){var t=this.buttonGroup;t&&t.remove(),r.prototype.destroy.call(this)},e}(ar);Te("brush-reset-button",C_,{name:"brush-reset-button"}),De("filter-action",{});function Gn(r){return r.isInPlot()}function Ri(r,e,t){var n=t||{},i=n.mask,a=n.isStartEnable,o=e||"rect";switch(r){case"brush":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair",isEnable:a||function(){return!0}},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:a||Gn,action:["brush:start","".concat(o,"-mask:start"),"".concat(o,"-mask:show")],arg:[null,{maskStyle:i==null?void 0:i.style}]}],processing:[{trigger:"mousemove",isEnable:Gn,action:["".concat(o,"-mask:resize")]}],end:[{trigger:"mouseup",isEnable:Gn,action:["brush:filter","brush:end","".concat(o,"-mask:end"),"".concat(o,"-mask:hide"),"brush-reset-button:show"]}],rollback:[{trigger:"brush-reset-button:click",action:["brush:reset","brush-reset-button:hide","cursor:crosshair"]}]};case"brush-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair",isEnable:a||function(){return!0}},{trigger:"plot:mousemove",action:"cursor:crosshair",isEnable:a||function(){return!0}},{trigger:"plot:mousemove",action:"cursor:default",isEnable:function(s){return a?!a(s):!1}},{trigger:"mask:mouseenter",action:"cursor:move",isEnable:a||function(){return!0}},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:a||function(s){return!s.isInShape("mask")},action:["".concat(o,"-mask:start"),"".concat(o,"-mask:show")],arg:[{maskStyle:i==null?void 0:i.style}]},{trigger:"mask:dragstart",action:["".concat(o,"-mask:moveStart")]}],processing:[{trigger:"plot:mousemove",action:["".concat(o,"-mask:resize")]},{trigger:"mask:drag",action:["".concat(o,"-mask:move")]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["".concat(o,"-mask:end")]},{trigger:"mask:dragend",action:["".concat(o,"-mask:moveEnd")]},{trigger:"document:mouseup",isEnable:function(s){return!s.isInPlot()},action:["element-range-highlight:clear","".concat(o,"-mask:end"),"".concat(o,"-mask:hide")]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","".concat(o,"-mask:hide")]}]};case"brush-x":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair",isEnable:a||function(){return!0}},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:a||Gn,action:["brush-x:start","".concat(o,"-mask:start"),"".concat(o,"-mask:show")],arg:[null,{maskStyle:i==null?void 0:i.style}]}],processing:[{trigger:"mousemove",isEnable:Gn,action:["".concat(o,"-mask:resize")]}],end:[{trigger:"mouseup",isEnable:Gn,action:["brush-x:filter","brush-x:end","".concat(o,"-mask:end"),"".concat(o,"-mask:hide")]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]};case"brush-x-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair",isEnable:a||function(){return!0}},{trigger:"mask:mouseenter",action:"cursor:move",isEnable:a||function(){return!0}},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:a||function(s){return!s.isInShape("mask")},action:["".concat(o,"-mask:start"),"".concat(o,"-mask:show")],arg:[{maskStyle:i==null?void 0:i.style}]},{trigger:"mask:dragstart",action:["".concat(o,"-mask:moveStart")]}],processing:[{trigger:"plot:mousemove",action:["".concat(o,"-mask:resize")]},{trigger:"mask:drag",action:["".concat(o,"-mask:move")]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["".concat(o,"-mask:end")]},{trigger:"mask:dragend",action:["".concat(o,"-mask:moveEnd")]},{trigger:"document:mouseup",isEnable:function(s){return!s.isInPlot()},action:["element-range-highlight:clear","".concat(o,"-mask:end"),"".concat(o,"-mask:hide")]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","".concat(o,"-mask:hide")]}]};case"brush-y":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair",isEnable:a||function(){return!0}},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:a||Gn,action:["brush-y:start","".concat(o,"-mask:start"),"".concat(o,"-mask:show")],arg:[null,{maskStyle:i==null?void 0:i.style}]}],processing:[{trigger:"mousemove",isEnable:Gn,action:["".concat(o,"-mask:resize")]}],end:[{trigger:"mouseup",isEnable:Gn,action:["brush-y:filter","brush-y:end","".concat(o,"-mask:end"),"".concat(o,"-mask:hide")]}],rollback:[{trigger:"dblclick",action:["brush-y:reset"]}]};case"brush-y-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair",isEnable:a||function(){return!0}},{trigger:"mask:mouseenter",action:"cursor:move",isEnable:a||function(){return!0}},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:a||function(s){return!s.isInShape("mask")},action:["".concat(o,"-mask:start"),"".concat(o,"-mask:show")],arg:[{maskStyle:i==null?void 0:i.style}]},{trigger:"mask:dragstart",action:["".concat(o,"-mask:moveStart")]}],processing:[{trigger:"plot:mousemove",action:["".concat(o,"-mask:resize")]},{trigger:"mask:drag",action:["".concat(o,"-mask:move")]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["".concat(o,"-mask:end")]},{trigger:"mask:dragend",action:["".concat(o,"-mask:moveEnd")]},{trigger:"document:mouseup",isEnable:function(s){return!s.isInPlot()},action:["element-range-highlight:clear","".concat(o,"-mask:end"),"".concat(o,"-mask:hide")]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","".concat(o,"-mask:hide")]}]};default:return{}}}De("brush",Ri("brush")),De("brush-highlight",Ri("brush-highlight")),De("brush-x",Ri("brush-x","x-rect")),De("brush-y",Ri("brush-y","y-rect")),De("brush-x-highlight",Ri("brush-x-highlight","x-rect")),De("brush-y-highlight",Ri("brush-y-highlight","y-rect"));var cg=["brush","brush-x","brush-y","brush-highlight","brush-x-highlight","brush-y-highlight"];function fg(r){var e=r.options,t=e.brush,n=(0,f.hX)(e.interactions||[],function(i){return cg.indexOf(i.type)===-1});return(t==null?void 0:t.enabled)&&(cg.forEach(function(i){var a=!1;switch(t.type){case"x-rect":a=i===(t.action==="highlight"?"brush-x-highlight":"brush-x");break;case"y-rect":a=i===(t.action==="highlight"?"brush-y-highlight":"brush-y");break;default:a=i===(t.action==="highlight"?"brush-highlight":"brush");break}var o={type:i,enable:a};t&&(o.cfg=Ri(i,t.type,t)),n.push(o)}),(t==null?void 0:t.action)!=="highlight"&&n.push({type:"filter-action",cfg:{buttonConfig:t.button}})),kt({},r,{options:{interactions:n}})}var Ni={hover:"__interval-connected-area-hover__",click:"__interval-connected-area-click__"},zc=function(r,e){return r==="hover"?[{trigger:"interval:mouseenter",action:["element-highlight-by-color:highlight","element-link-by-color:link"],arg:[null,{style:e}]}]:[{trigger:"interval:click",action:["element-highlight-by-color:clear","element-highlight-by-color:highlight","element-link-by-color:clear","element-link-by-color:unlink","element-link-by-color:link"],arg:[null,null,null,null,{style:e}]}]};De(Ni.hover,{start:zc(Ni.hover),end:[{trigger:"interval:mouseleave",action:["element-highlight-by-color:reset","element-link-by-color:unlink"]}]}),De(Ni.click,{start:zc(Ni.click),end:[{trigger:"document:mousedown",action:["element-highlight-by-color:clear","element-link-by-color:clear"]}]});function A_(r){return r===void 0&&(r=!1),function(e){var t=e.chart,n=e.options,i=n.connectedArea,a=function(){t.removeInteraction(Ni.hover),t.removeInteraction(Ni.click)};if(!r&&i){var o=i.trigger||"hover";a(),t.interaction(Ni[o],{start:zc(o,i.style)})}else a();return e}}function hg(r,e){return!(0,f.hj)(r)||!(0,f.hj)(e)||r===0&&e===0?"-":r===e?"100%":r===0?"\u221E":"".concat((100*e/r).toFixed(2),"%")}function b_(r,e){return kt({size:e?32:80,spacing:e?8:12,offset:e?32:0,arrow:r.arrow!==!1&&{headSize:12,style:{fill:"rgba(0, 0, 0, 0.05)"}},text:r.text!==!1&&{style:{fontSize:12,fill:"rgba(0, 0, 0, 0.85)",textAlign:"center",textBaseline:"middle"},formatter:hg}},r)}function nl(r,e){return(0,f.UI)(e.getModel().points,function(t){return r.convertPoint(t)})}function T_(r,e,t){var n=r.view,i=r.geometry,a=r.group,o=r.options,s=r.horizontal,l=o.offset,u=o.size,c=o.arrow,h=n.getCoordinate(),v=nl(h,e)[3],d=nl(h,t)[0],g=d.y-v.y,y=d.x-v.x;if(typeof c!="boolean"){var x=c.headSize,m=o.spacing,M;s?(y-x)/2<m?(m=Math.max(1,(y-x)/2),M=[[v.x+m,v.y-l],[v.x+m,v.y-l-u],[d.x-m,d.y-l-u/2]]):M=[[v.x+m,v.y-l],[v.x+m,v.y-l-u],[d.x-m-x,d.y-l-u],[d.x-m,d.y-l-u/2],[d.x-m-x,d.y-l]]:(g-x)/2<m?(m=Math.max(1,(g-x)/2),M=[[v.x+l,v.y+m],[v.x+l+u,v.y+m],[d.x+l+u/2,d.y-m]]):M=[[v.x+l,v.y+m],[v.x+l+u,v.y+m],[d.x+l+u,d.y-m-x],[d.x+l+u/2,d.y-m],[d.x+l,d.y-m-x]],a.addShape("polygon",{id:"".concat(n.id,"-conversion-tag-arrow-").concat(i.getElementId(e.getModel().mappingData)),name:"conversion-tag-arrow",origin:{element:e,nextElement:t},attrs:(0,p.pi)((0,p.pi)({},c.style||{}),{points:M})})}}function E_(r,e,t){var n,i,a,o=r.view,s=r.geometry,l=r.group,u=r.options,c=r.field,h=r.horizontal,v=u.offset,d=u.size;if(typeof u.text!="boolean"){var g=o.getCoordinate(),y=((n=u.text)===null||n===void 0?void 0:n.formatter)&&((i=u.text)===null||i===void 0?void 0:i.formatter(e.getData()[c],t.getData()[c])),x=nl(g,e)[h?3:0],m=nl(g,t)[h?0:3],M=l.addShape("text",{id:"".concat(o.id,"-conversion-tag-text-").concat(s.getElementId(e.getModel().mappingData)),name:"conversion-tag-text",origin:{element:e,nextElement:t},attrs:(0,p.pi)((0,p.pi)({},((a=u.text)===null||a===void 0?void 0:a.style)||{}),{text:y,x:h?(x.x+m.x)/2:x.x+v+d/2,y:h?x.y-v-d/2:(x.y+m.y)/2})});if(h){var w=m.x-x.x,S=M.getBBox().width;if(S>w){var b=S/y.length,k=Math.max(1,Math.ceil(w/b)-1),H="".concat(y.slice(0,k),"...");M.attr("text",H)}}}}function __(r,e,t){T_(r,e,t),E_(r,e,t)}function F_(r,e,t){return e===void 0&&(e=!0),t===void 0&&(t=!1),function(n){var i=n.options,a=n.chart,o=i.conversionTag,s=i.theme;return o&&!t&&(a.theme(kt({},(0,f.Kn)(s)?s:eo(s),{columnWidthRatio:1/3})),a.annotation().shape({render:function(l,u){var c=l.addGroup({id:"".concat(a.id,"-conversion-tag-group"),name:"conversion-tag-group"}),h=(0,f.sE)(a.geometries,function(g){return g.type==="interval"}),v={view:u,geometry:h,group:c,field:r,horizontal:e,options:b_(o,e)},d=h.elements;(0,f.S6)(d,function(g,y){y>0&&__(v,d[y-1],g)})}})),n}}function I_(r){var e=r.options,t=e.legend,n=e.seriesField,i=e.isStack;return n?t!==!1&&(t=(0,p.pi)({position:i?"right-top":"top-left"},t)):t=!1,r.options.legend=t,r}function P_(r){var e=r.chart,t=r.options,n=t.data,i=t.columnStyle,a=t.color,o=t.columnWidthRatio,s=t.isPercent,l=t.isGroup,u=t.isStack,c=t.xField,h=t.yField,v=t.seriesField,d=t.groupField,g=t.tooltip,y=t.shape,x=s&&l&&u?f_(n,h,[c,d],h):Mo(n,h,c,h,s),m=[];u&&v&&!l?x.forEach(function(S){var b=m.find(function(k){return k[c]===S[c]&&k[v]===S[v]});b?b[h]+=S[h]||0:m.push((0,p.pi)({},S))}):m=x,e.data(m);var M=s?(0,p.pi)({formatter:function(S){var b;return{name:l&&u?"".concat(S[v]," - ").concat(S[d]):(b=S[v])!==null&&b!==void 0?b:S[c],value:(Number(S[h])*100).toFixed(2)+"%"}}},g):g,w=kt({},r,{options:{data:m,widthRatio:o,tooltip:M,interval:{shape:y,style:i,color:a}}});return Tr(w),w}function Vc(r){var e,t,n=r.options,i=n.xAxis,a=n.yAxis,o=n.xField,s=n.yField,l=n.data,u=n.isPercent,c=u?{max:1,min:0,minLimit:0,maxLimit:1}:{};return Fe(ur((e={},e[o]=i,e[s]=a,e),(t={},t[o]={type:"cat"},t[s]=(0,p.pi)((0,p.pi)({},Pc(l,s)),c),t)))(r)}function L_(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return n===!1?e.axis(a,!1):e.axis(a,n),i===!1?e.axis(o,!1):e.axis(o,i),r}function D_(r){var e=r.chart,t=r.options,n=t.legend,i=t.seriesField;return n&&i?e.legend(i,n):n===!1&&e.legend(!1),r}function O_(r){var e=r.chart,t=r.options,n=t.label,i=t.yField,a=t.isRange,o=br(e,"interval");if(!n)o.label(!1);else{var s=n.callback,l=(0,p._T)(n,["callback"]);o.label({fields:[i],callback:s,cfg:(0,p.pi)({layout:(l==null?void 0:l.position)?void 0:[{type:"interval-adjust-position"},{type:"interval-hide-overlap"},{type:"adjust-color"},{type:"limit-in-plot",cfg:{action:"hide"}}]},xr(a?(0,p.pi)({content:function(u){var c;return(c=u[i])===null||c===void 0?void 0:c.join("-")}},l):l))})}return r}function k_(r){var e=r.chart,t=r.options,n=t.tooltip,i=t.isGroup,a=t.isStack,o=t.groupField,s=t.data,l=t.xField,u=t.yField,c=t.seriesField;if(n===!1)e.tooltip(!1);else{var h=n;if(i&&a){var v=h.customItems,d=(h==null?void 0:h.formatter)||function(g){return{name:"".concat(g[c]," - ").concat(g[o]),value:g[u]}};h=(0,p.pi)((0,p.pi)({},h),{customItems:function(g){var y=[];return(0,f.S6)(g,function(x){var m=(0,f.hX)(s,function(M){return(0,f.BD)(M,Qe(x.data,[l,c]))});m.forEach(function(M){y.push((0,p.pi)((0,p.pi)((0,p.pi)({},x),{value:M[u],data:M,mappingData:{_origin:M}}),d(M)))})}),v?v(y):y}})}e.tooltip(h)}return r}function il(r,e){e===void 0&&(e=!1);var t=r.options,n=t.seriesField;return Fe(I_,We,Kr("columnStyle"),hi,Jp("rect"),P_,Vc,L_,D_,k_,xo,Nc,O_,fg,or,tr,sr(),F_(t.yField,!e,!!n),A_(!t.isStack),Bi)(r)}function B_(r){var e=r.options,t=e.xField,n=e.yField,i=e.xAxis,a=e.yAxis,o={left:"bottom",right:"top",top:"left",bottom:"right"},s=a!==!1?(0,p.pi)({position:o[(a==null?void 0:a.position)||"left"]},a):!1,l=i!==!1?(0,p.pi)({position:o[(i==null?void 0:i.position)||"bottom"]},i):!1;return(0,p.pi)((0,p.pi)({},r),{options:(0,p.pi)((0,p.pi)({},e),{xField:n,yField:t,xAxis:s,yAxis:l})})}function R_(r){var e=r.options,t=e.label;return t&&!t.position&&(t.position="left",t.layout||(t.layout=[{type:"interval-adjust-position"},{type:"interval-hide-overlap"},{type:"adjust-color"},{type:"limit-in-plot",cfg:{action:"hide"}}])),kt({},r,{options:{label:t}})}function N_(r){var e=r.options,t=e.seriesField,n=e.isStack,i=e.legend;return t?i!==!1&&(i=(0,p.pi)({position:n?"top-left":"right-top"},i||{})):i=!1,kt({},r,{options:{legend:i}})}function U_(r){var e=r.options,t=[{type:"transpose"},{type:"reflectY"}].concat(e.coordinate||[]);return kt({},r,{options:{coordinate:t}})}function z_(r){var e=r.chart,t=r.options,n=t.barStyle,i=t.barWidthRatio,a=t.minBarWidth,o=t.maxBarWidth,s=t.barBackground;return il({chart:e,options:(0,p.pi)((0,p.pi)({},t),{columnStyle:n,columnWidthRatio:i,minColumnWidth:a,maxColumnWidth:o,columnBackground:s})},!0)}function vg(r){return Fe(B_,R_,N_,pr,U_,z_)(r)}var V_=kt({},Re.getDefaultOptions(),{barWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},legend:{radio:{}},interactions:[{type:"active-region"}]}),H_=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="bar",t}return e.getDefaultOptions=function(){return V_},e.prototype.changeData=function(t){var n,i;this.updateOption({data:t});var a=this,o=a.chart,s=a.options,l=s.isPercent,u=s.xField,c=s.yField,h=s.xAxis,v=s.yAxis;n=[c,u],u=n[0],c=n[1],i=[v,h],h=i[0],v=i[1];var d=(0,p.pi)((0,p.pi)({},s),{xField:u,yField:c,yAxis:v,xAxis:h});Vc({chart:o,options:d}),o.changeData(Mo(t,u,c,u,l))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return vg},e}(Re),G_=kt({},Re.getDefaultOptions(),{columnWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},legend:{radio:{}},interactions:[{type:"active-region"}]}),dg=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="column",t}return e.getDefaultOptions=function(){return G_},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this.options,i=n.yField,a=n.xField,o=n.isPercent,s=this,l=s.chart,u=s.options;Vc({chart:l,options:u}),this.chart.changeData(Mo(t,i,a,i,o))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return il},e}(Re),Hc,vi="$$percentage$$",di="$$mappingValue$$",Yn="$$conversion$$",Gc="$$totalPercentage$$",wo="$$x$$",So="$$y$$",Y_={appendPadding:[0,80],minSize:0,maxSize:1,meta:(Hc={},Hc[di]={min:0,max:1,nice:!1},Hc),label:{style:{fill:"#fff",fontSize:12}},tooltip:{showTitle:!1,showMarkers:!1,shared:!1},conversionTag:{offsetX:10,offsetY:0,style:{fontSize:12,fill:"rgba(0,0,0,0.45)"}}},pg="CONVERSION_TAG_NAME";function Yc(r,e,t){var n=[],i=t.yField,a=t.maxSize,o=t.minSize,s=(0,f.U2)((0,f.UT)(e,i),[i]),l=(0,f.hj)(a)?a:1,u=(0,f.hj)(o)?o:0;return n=(0,f.UI)(r,function(c,h){var v=(c[i]||0)/s;return c[vi]=v,c[di]=(l-u)*v+u,c[Yn]=[(0,f.U2)(r,[h-1,i]),c[i]],c}),n}function Xc(r){return function(e){var t=e.chart,n=e.options,i=n.conversionTag,a=n.filteredData,o=a||t.getOptions().data;if(i){var s=i.formatter;o.forEach(function(l,u){if(!(u<=0||Number.isNaN(l[di]))){var c=r(l,u,o,{top:!0,name:pg,text:{content:(0,f.mf)(s)?s(l,o):s,offsetX:i.offsetX,offsetY:i.offsetY,position:"end",autoRotate:!1,style:(0,p.pi)({textAlign:"start",textBaseline:"middle"},i.style)}});t.annotation().line(c)}})}return e}}function X_(r){var e=r.chart,t=r.options,n=t.data,i=n===void 0?[]:n,a=t.yField,o=t.maxSize,s=t.minSize,l=Yc(i,i,{yField:a,maxSize:o,minSize:s});return e.data(l),r}function W_(r){var e=r.chart,t=r.options,n=t.xField,i=t.yField,a=t.color,o=t.tooltip,s=t.label,l=t.shape,u=l===void 0?"funnel":l,c=t.funnelStyle,h=t.state,v=sn(o,[n,i]),d=v.fields,g=v.formatter;Gr({chart:e,options:{type:"interval",xField:n,yField:di,colorField:n,tooltipFields:(0,f.kJ)(d)&&d.concat([vi,Yn]),mapping:{shape:u,tooltip:g,color:a,style:c},label:s,state:h}});var y=br(r.chart,"interval");return y.adjust("symmetric"),r}function Z_(r){var e=r.chart,t=r.options,n=t.isTransposed;return e.coordinate({type:"rect",actions:n?[]:[["transpose"],["scale",1,-1]]}),r}function gg(r){var e=r.options,t=r.chart,n=e.maxSize,i=(0,f.U2)(t,["geometries","0","dataArray"],[]),a=(0,f.U2)(t,["options","data","length"]),o=(0,f.UI)(i,function(l){return(0,f.U2)(l,["0","nextPoints","0","x"])*a-.5}),s=function(l,u,c,h){var v=n-(n-l[di])/2;return(0,p.pi)((0,p.pi)({},h),{start:[o[u-1]||u-.5,v],end:[o[u-1]||u-.5,v+.05]})};return Xc(s)(r),r}function yg(r){return Fe(X_,W_,Z_,gg)(r)}function $_(r){var e,t=r.chart,n=r.options,i=n.data,a=i===void 0?[]:i,o=n.yField;return t.data(a),t.scale((e={},e[o]={sync:!0},e)),r}function q_(r){var e=r.chart,t=r.options,n=t.data,i=t.xField,a=t.yField,o=t.color,s=t.compareField,l=t.isTransposed,u=t.tooltip,c=t.maxSize,h=t.minSize,v=t.label,d=t.funnelStyle,g=t.state,y=t.showFacetTitle;return e.facet("mirror",{fields:[s],transpose:!l,padding:l?0:[32,0,0,0],showTitle:y,eachView:function(x,m){var M=l?m.rowIndex:m.columnIndex;l||x.coordinate({type:"rect",actions:[["transpose"],["scale",M===0?-1:1,-1]]});var w=Yc(m.data,n,{yField:a,maxSize:c,minSize:h});x.data(w);var S=sn(u,[i,a,s]),b=S.fields,k=S.formatter,H=l?{offset:M===0?10:-23,position:M===0?"bottom":"top"}:{offset:10,position:"left",style:{textAlign:M===0?"end":"start"}};Gr({chart:x,options:{type:"interval",xField:i,yField:di,colorField:i,tooltipFields:(0,f.kJ)(b)&&b.concat([vi,Yn]),mapping:{shape:"funnel",tooltip:k,color:o,style:d},label:v===!1?!1:kt({},H,v),state:g}})}}),r}function mg(r){var e=r.chart,t=r.index,n=r.options,i=n.conversionTag,a=n.isTransposed;((0,f.hj)(t)?[e]:e.views).forEach(function(o,s){var l=(0,f.U2)(o,["geometries","0","dataArray"],[]),u=(0,f.U2)(o,["options","data","length"]),c=(0,f.UI)(l,function(v){return(0,f.U2)(v,["0","nextPoints","0","x"])*u-.5}),h=function(v,d,g,y){var x=(t||s)===0?-1:1;return kt({},y,{start:[c[d-1]||d-.5,v[di]],end:[c[d-1]||d-.5,v[di]+.05],text:a?{style:{textAlign:"start"}}:{offsetX:i!==!1?x*i.offsetX:0,style:{textAlign:(t||s)===0?"end":"start"}}})};Xc(h)(kt({},{chart:o,options:n}))})}function K_(r){var e=r.chart;return e.once("beforepaint",function(){return mg(r)}),r}function j_(r){return Fe($_,q_,K_)(r)}function J_(r){var e=r.chart,t=r.options,n=t.data,i=n===void 0?[]:n,a=t.yField,o=(0,f.u4)(i,function(u,c){return u+(c[a]||0)},0),s=(0,f.UT)(i,a)[a],l=(0,f.UI)(i,function(u,c){var h=[],v=[];if(u[Gc]=(u[a]||0)/o,c){var d=i[c-1][wo],g=i[c-1][So];h[0]=d[3],v[0]=g[3],h[1]=d[2],v[1]=g[2]}else h[0]=-.5,v[0]=1,h[1]=.5,v[1]=1;return v[2]=v[1]-u[Gc],h[2]=(v[2]+1)/4,v[3]=v[2],h[3]=-h[2],u[wo]=h,u[So]=v,u[vi]=(u[a]||0)/s,u[Yn]=[(0,f.U2)(i,[c-1,a]),u[a]],u});return e.data(l),r}function Q_(r){var e=r.chart,t=r.options,n=t.xField,i=t.yField,a=t.color,o=t.tooltip,s=t.label,l=t.funnelStyle,u=t.state,c=sn(o,[n,i]),h=c.fields,v=c.formatter;return Gr({chart:e,options:{type:"polygon",xField:wo,yField:So,colorField:n,tooltipFields:(0,f.kJ)(h)&&h.concat([vi,Yn]),label:s,state:u,mapping:{tooltip:v,color:a,style:l}}}),r}function tF(r){var e=r.chart,t=r.options,n=t.isTransposed;return e.coordinate({type:"rect",actions:n?[["transpose"],["reflect","x"]]:[]}),r}function eF(r){var e=function(t,n,i,a){return(0,p.pi)((0,p.pi)({},a),{start:[t[wo][1],t[So][1]],end:[t[wo][1]+.05,t[So][1]]})};return Xc(e)(r),r}function rF(r){return Fe(J_,Q_,tF,eF)(r)}function nF(r){var e,t=r.chart,n=r.options,i=n.data,a=i===void 0?[]:i,o=n.yField;return t.data(a),t.scale((e={},e[o]={sync:!0},e)),r}function iF(r){var e=r.chart,t=r.options,n=t.seriesField,i=t.isTransposed,a=t.showFacetTitle;return e.facet("rect",{fields:[n],padding:[i?0:32,10,0,10],showTitle:a,eachView:function(o,s){yg(kt({},r,{chart:o,options:{data:s.data}}))}}),r}function aF(r){return Fe(nF,iF)(r)}var oF=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.rendering=!1,t}return e.prototype.change=function(t){var n=this;if(!this.rendering){var i=t.seriesField,a=t.compareField,o=a?mg:gg,s=this.context.view,l=i||a?s.views:[s];(0,f.UI)(l,function(u,c){var h=u.getController("annotation"),v=(0,f.hX)((0,f.U2)(h,["option"],[]),function(g){var y=g.name;return y!==pg});h.clear(!0),(0,f.S6)(v,function(g){typeof g=="object"&&u.annotation()[g.type](g)});var d=(0,f.U2)(u,["filteredData"],u.getOptions().data);o({chart:u,index:c,options:(0,p.pi)((0,p.pi)({},t),{filteredData:Yc(d,d,t)})}),u.filterData(d),n.rendering=!0,u.render(!0)})}this.rendering=!1},e}(ar),xg="funnel-conversion-tag",Wc="funnel-afterrender",Mg={trigger:"afterrender",action:"".concat(xg,":change")};Te(xg,oF),De(Wc,{start:[Mg]});function sF(r){var e=r.options,t=e.compareField,n=e.xField,i=e.yField,a=e.locale,o=e.funnelStyle,s=e.data,l=Js(a),u={label:t?{fields:[n,i,t,vi,Yn],formatter:function(h){return"".concat(h[i])}}:{fields:[n,i,vi,Yn],offset:0,position:"middle",formatter:function(h){return"".concat(h[n]," ").concat(h[i])}},tooltip:{title:n,formatter:function(h){return{name:h[n],value:h[i]}}},conversionTag:{formatter:function(h){return"".concat(l.get(["conversionTag","label"]),": ").concat(hg.apply(void 0,h[Yn]))}}},c;return(t||o)&&(c=function(h){return kt({},t&&{lineWidth:1,stroke:"#fff"},(0,f.mf)(o)?o(h):o)}),kt({options:u},r,{options:{funnelStyle:c,data:(0,f.d9)(s)}})}function lF(r){var e=r.options,t=e.compareField,n=e.dynamicHeight,i=e.seriesField;return i?aF(r):t?j_(r):n?rF(r):yg(r)}function uF(r){var e,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return Fe(ur((e={},e[a]=n,e[o]=i,e)))(r)}function cF(r){var e=r.chart;return e.axis(!1),r}function fF(r){var e=r.chart,t=r.options,n=t.legend;return n===!1?e.legend(!1):e.legend(n),r}function hF(r){var e=r.chart,t=r.options,n=t.interactions,i=t.dynamicHeight;return(0,f.S6)(n,function(a){a.enable===!1?e.removeInteraction(a.type):e.interaction(a.type,a.cfg||{})}),i?e.removeInteraction(Wc):e.interaction(Wc,{start:[(0,p.pi)((0,p.pi)({},Mg),{arg:t})]}),r}function wg(r){return Fe(sF,lF,uF,cF,pr,hF,fF,tr,We,sr())(r)}var vF=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="funnel",t}return e.getDefaultOptions=function(){return Y_},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return wg},e.prototype.setState=function(t,n,i){i===void 0&&(i=!0);var a=go(this.chart);(0,f.S6)(a,function(o){n(o.getData())&&o.setState(t,i)})},e.prototype.getStates=function(){var t=go(this.chart),n=[];return(0,f.S6)(t,function(i){var a=i.getData(),o=i.getStates();(0,f.S6)(o,function(s){n.push({data:a,state:s,geometry:i.geometry,element:i})})}),n},e.CONVERSATION_FIELD=Yn,e.PERCENT_FIELD=vi,e.TOTAL_PERCENT_FIELD=Gc,e}(Re),al,Zc="range",Sg="type",Xn="percent",dF="#f0f0f0",Cg="indicator-view",Ag="range-view",pF={percent:0,range:{ticks:[]},innerRadius:.9,radius:.95,startAngle:-7/6*Math.PI,endAngle:1/6*Math.PI,syncViewPadding:!0,axis:{line:null,label:{offset:-24,style:{textAlign:"center",textBaseline:"middle"}},subTickLine:{length:-8},tickLine:{length:-12},grid:null},indicator:{pointer:{style:{lineWidth:5,lineCap:"round"}},pin:{style:{r:9.75,lineWidth:4.5,fill:"#fff"}}},statistic:{title:!1},meta:(al={},al[Zc]={sync:"v"},al[Xn]={sync:"v",tickCount:5,tickInterval:.2},al),animation:!1};function gF(r,e){return r.map(function(t,n){var i;return i={},i[Zc]=t-(r[n-1]||0),i[Sg]="".concat(n),i[Xn]=e,i})}function bg(r){var e;return[(e={},e[Xn]=(0,f.uZ)(r,0,1),e)]}function Tg(r,e){var t=(0,f.U2)(e,["ticks"],[]),n=(0,f.dp)(t)?(0,f.jj)(t):[0,(0,f.uZ)(r,0,1),1];return n[0]||n.shift(),gF(n,r)}function yF(r){var e=r.chart,t=r.options,n=t.percent,i=t.range,a=t.radius,o=t.innerRadius,s=t.startAngle,l=t.endAngle,u=t.axis,c=t.indicator,h=t.gaugeStyle,v=t.type,d=t.meter,g=i.color,y=i.width;if(c){var x=bg(n),m=e.createView({id:Cg});m.data(x),m.point().position("".concat(Xn,"*1")).shape(c.shape||"gauge-indicator").customInfo({defaultColor:e.getTheme().defaultColor,indicator:c}),m.coordinate("polar",{startAngle:s,endAngle:l,radius:o*a}),m.axis(Xn,u),m.scale(Xn,Qe(u,Hr))}var M=Tg(n,t.range),w=e.createView({id:Ag});w.data(M);var S=(0,f.HD)(g)?[g,dF]:g,b=Tr({chart:w,options:{xField:"1",yField:Zc,seriesField:Sg,rawFields:[Xn],isStack:!0,interval:{color:S,style:h,shape:v==="meter"?"meter-gauge":null},args:{zIndexReversed:!0,sortZIndex:!0},minColumnWidth:y,maxColumnWidth:y}}).ext,k=b.geometry;return k.customInfo({meter:d}),w.coordinate("polar",{innerRadius:o,radius:a,startAngle:s,endAngle:l}).transpose(),r}function mF(r){var e;return Fe(ur((e={range:{min:0,max:1,maxLimit:1,minLimit:0}},e[Xn]={},e)))(r)}function Eg(r,e){var t=r.chart,n=r.options,i=n.statistic,a=n.percent;if(t.getController("annotation").clear(!0),i){var o=i.content,s=void 0;o&&(s=kt({},{content:"".concat((a*100).toFixed(2),"%"),style:{opacity:.75,fontSize:"30px",lineHeight:1,textAlign:"center",color:"rgba(44,53,66,0.85)"}},o)),qE(t,{statistic:(0,p.pi)((0,p.pi)({},i),{content:s})},{percent:a})}return e&&t.render(!0),r}function xF(r){var e=r.chart,t=r.options,n=t.tooltip;return n?e.tooltip(kt({showTitle:!1,showMarkers:!1,containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',domStyles:{"g2-tooltip":{padding:"4px 8px",fontSize:"10px"}},customContent:function(i,a){var o=(0,f.U2)(a,[0,"data",Xn],0);return"".concat((o*100).toFixed(2),"%")}},n)):e.tooltip(!1),r}function MF(r){var e=r.chart;return e.legend(!1),r}function _g(r){return Fe(We,tr,yF,mF,xF,Eg,or,sr(),MF)(r)}Ke("point","gauge-indicator",{draw:function(r,e){var t=r.customInfo,n=t.indicator,i=t.defaultColor,a=n,o=a.pointer,s=a.pin,l=e.addGroup(),u=this.parsePoint({x:0,y:0});return o&&l.addShape("line",{name:"pointer",attrs:(0,p.pi)({x1:u.x,y1:u.y,x2:r.x,y2:r.y,stroke:i},o.style)}),s&&l.addShape("circle",{name:"pin",attrs:(0,p.pi)({x:u.x,y:u.y,stroke:i},s.style)}),l}}),Ke("interval","meter-gauge",{draw:function(r,e){var t=r.customInfo.meter,n=t===void 0?{}:t,i=n.steps,a=i===void 0?50:i,o=n.stepRatio,s=o===void 0?.5:o;a=a<1?1:a,s=(0,f.uZ)(s,0,1);var l=this.coordinate,u=l.startAngle,c=l.endAngle,h=0;if(s>0&&s<1){var v=c-u;h=v/a/(s/(1-s)+1-1/a)}for(var d=h/(1-s)*s,g=e.addGroup(),y=this.coordinate.getCenter(),x=this.coordinate.getRadius(),m=zr.getAngle(r,this.coordinate),M=m.startAngle,w=m.endAngle,S=M;S<w;){var b=void 0,k=(S-u)%(d+h);k<d?b=S+(d-k):(S+=d+h-k,b=S+d);var H=zr.getSectorPath(y.x,y.y,x,S,Math.min(b,w),x*this.coordinate.innerRadius);g.addShape("path",{name:"meter-gauge",attrs:{path:H,fill:r.color,stroke:r.color,lineWidth:.5}}),S=b+h}return g}});var wF=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="gauge",t}return e.getDefaultOptions=function(){return pF},e.prototype.changeData=function(t){this.chart.emit(X.BEFORE_CHANGE_DATA,lr.fromData(this.chart,X.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t});var n=this.chart.views.find(function(a){return a.id===Cg});n&&n.data(bg(t));var i=this.chart.views.find(function(a){return a.id===Ag});i&&i.data(Tg(t,this.options.range)),Eg({chart:this.chart,options:this.options},!0),this.chart.emit(X.AFTER_CHANGE_DATA,lr.fromData(this.chart,X.AFTER_CHANGE_DATA,null))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return _g},e}(Re);function Fg(r,e,t){if(t===1)return[0,e];var n=Math.floor(r/e);return[e*n,e*(n+1)]}function SF(r){return Math.ceil(Math.log(r.length)/Math.LN2)+1}function Ig(r,e,t,n,i){var a=(0,f.d9)(r);(0,f.MR)(a,e);var o=(0,f.I)(a,e),s=(0,f.rx)(o),l=s.max-s.min,u=t;if(!t&&n&&(u=n>1?l/(n-1):s.max),!t&&!n){var c=SF(o);u=l/c}var h={},v=(0,f.vM)(a,i);(0,f.xb)(v)?(0,f.S6)(a,function(g){var y=g[e],x=Fg(y,u,n),m="".concat(x[0],"-").concat(x[1]);(0,f.wH)(h,m)||(h[m]={range:x,count:0}),h[m].count+=1}):Object.keys(v).forEach(function(g){(0,f.S6)(v[g],function(y){var x=y[e],m=Fg(x,u,n),M="".concat(m[0],"-").concat(m[1]),w="".concat(M,"-").concat(g);(0,f.wH)(h,w)||(h[w]={range:m,count:0},h[w][i]=g),h[w].count+=1})});var d=[];return(0,f.S6)(h,function(g){d.push(g)}),d}var ol="range",Co="count",CF=kt({},Re.getDefaultOptions(),{columnStyle:{stroke:"#FFFFFF"},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]});function AF(r){var e=r.chart,t=r.options,n=t.data,i=t.binField,a=t.binNumber,o=t.binWidth,s=t.color,l=t.stackField,u=t.legend,c=t.columnStyle,h=Ig(n,i,o,a,l);e.data(h);var v=kt({},r,{options:{xField:ol,yField:Co,seriesField:l,isStack:!0,interval:{color:s,style:c}}});return Tr(v),u&&l?e.legend(l,u):e.legend(!1),r}function bF(r){var e,t=r.options,n=t.xAxis,i=t.yAxis;return Fe(ur((e={},e[ol]=n,e[Co]=i,e)))(r)}function TF(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis;return n===!1?e.axis(ol,!1):e.axis(ol,n),i===!1?e.axis(Co,!1):e.axis(Co,i),r}function EF(r){var e=r.chart,t=r.options,n=t.label,i=br(e,"interval");if(!n)i.label(!1);else{var a=n.callback,o=(0,p._T)(n,["callback"]);i.label({fields:[Co],callback:a,cfg:xr(o)})}return r}function Pg(r){return Fe(We,Kr("columnStyle"),AF,bF,TF,hi,EF,pr,or,tr)(r)}var _F=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="histogram",t}return e.getDefaultOptions=function(){return CF},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this.options,i=n.binField,a=n.binNumber,o=n.binWidth,s=n.stackField;this.chart.changeData(Ig(t,i,o,a,s))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return Pg},e}(Re),FF=kt({},Re.getDefaultOptions(),{tooltip:{shared:!0,showMarkers:!0,showCrosshairs:!0,crosshairs:{type:"x"}},legend:{position:"top-left",radio:{}},isStack:!1}),IF=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.active=function(){var t=this.getView(),n=this.context.event;if(n.data){var i=n.data.items,a=t.geometries.filter(function(o){return o.type==="point"});(0,f.S6)(a,function(o){(0,f.S6)(o.elements,function(s){var l=(0,f.cx)(i,function(u){return u.data===s.data})!==-1;s.setState("active",l)})})}},e.prototype.reset=function(){var t=this.getView(),n=t.geometries.filter(function(i){return i.type==="point"});(0,f.S6)(n,function(i){(0,f.S6)(i.elements,function(a){a.setState("active",!1)})})},e.prototype.getView=function(){return this.context.view},e}(ar);Te("marker-active",IF),De("marker-active",{start:[{trigger:"tooltip:show",action:"marker-active:active"}],end:[{trigger:"tooltip:hide",action:"marker-active:reset"}]});var Lg=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="line",t}return e.getDefaultOptions=function(){return FF},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this,i=n.chart,a=n.options;rl({chart:i,options:a}),this.chart.changeData(t)},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return sg},e}(Re),Dg=kt({},Re.getDefaultOptions(),{legend:{position:"right",radio:{}},tooltip:{shared:!1,showTitle:!1,showMarkers:!1},label:{layout:{type:"limit-in-plot",cfg:{action:"ellipsis"}}},pieStyle:{stroke:"white",lineWidth:1},statistic:{title:{style:{fontWeight:300,color:"#4B535E",textAlign:"center",fontSize:"20px",lineHeight:1}},content:{style:{fontWeight:"bold",color:"rgba(44,53,66,0.85)",textAlign:"center",fontSize:"32px",lineHeight:1}}},theme:{components:{annotation:{text:{animate:!1}}}}}),PF=[1,0,0,0,1,0,0,0,1];function $c(r,e){var t=e?(0,p.ev)([],e,!0):(0,p.ev)([],PF,!0);return zr.transform(t,r)}var LF=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getActiveElements=function(){var t=zr.getDelegationObject(this.context);if(t){var n=this.context.view,i=t.component,a=t.item,o=i.get("field");if(o){var s=n.geometries[0].elements;return s.filter(function(l){return l.getModel().data[o]===a.value})}}return[]},e.prototype.getActiveElementLabels=function(){var t=this.context.view,n=this.getActiveElements(),i=t.geometries[0].labelsContainer.getChildren();return i.filter(function(a){return n.find(function(o){return(0,f.Xy)(o.getData(),a.get("data"))})})},e.prototype.transfrom=function(t){t===void 0&&(t=7.5);var n=this.getActiveElements(),i=this.getActiveElementLabels();n.forEach(function(a,o){var s=i[o],l=a.geometry.coordinate;if(l.isPolar&&l.isTransposed){var u=zr.getAngle(a.getModel(),l),c=u.startAngle,h=u.endAngle,v=(c+h)/2,d=t,g=d*Math.cos(v),y=d*Math.sin(v);a.shape.setMatrix($c([["t",g,y]])),s.setMatrix($c([["t",g,y]]))}})},e.prototype.active=function(){this.transfrom()},e.prototype.reset=function(){this.transfrom(0)},e}(ar);function DF(r){var e=r.event,t,n=e.target;return n&&(t=n.get("element")),t}var OF=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getAnnotations=function(t){var n=t||this.context.view;return n.getController("annotation").option},e.prototype.getInitialAnnotation=function(){return this.initialAnnotation},e.prototype.init=function(){var t=this,n=this.context.view;n.removeInteraction("tooltip"),n.on("afterchangesize",function(){var i=t.getAnnotations(n);t.initialAnnotation=i})},e.prototype.change=function(t){var n=this.context,i=n.view,a=n.event;this.initialAnnotation||(this.initialAnnotation=this.getAnnotations());var o=(0,f.U2)(a,["data","data"]);if(a.type.match("legend-item")){var s=zr.getDelegationObject(this.context),l=i.getGroupedFields()[0];if(s&&l){var u=s.item;o=i.getData().find(function(d){return d[l]===u.value})}}if(o){var c=(0,f.U2)(t,"annotations",[]),h=(0,f.U2)(t,"statistic",{});i.getController("annotation").clear(!0),(0,f.S6)(c,function(d){typeof d=="object"&&i.annotation()[d.type](d)}),qs(i,{statistic:h,plotType:"pie"},o),i.render(!0)}var v=DF(this.context);v&&v.shape.toFront()},e.prototype.reset=function(){var t=this.context.view,n=t.getController("annotation");n.clear(!0);var i=this.getInitialAnnotation();(0,f.S6)(i,function(a){t.annotation()[a.type](a)}),t.render(!0)},e}(ar),Og="pie-statistic";Te(Og,OF),De("pie-statistic-active",{start:[{trigger:"element:mouseenter",action:"pie-statistic:change"}],end:[{trigger:"element:mouseleave",action:"pie-statistic:reset"}]}),Te("pie-legend",LF),De("pie-legend-active",{start:[{trigger:"legend-item:mouseenter",action:"pie-legend:active"}],end:[{trigger:"legend-item:mouseleave",action:"pie-legend:reset"}]});function kF(r,e){var t=null;return(0,f.S6)(r,function(n){typeof n[e]=="number"&&(t+=n[e])}),t}function BF(r,e){var t;switch(r){case"inner":return t="-30%",(0,f.HD)(e)&&e.endsWith("%")?parseFloat(e)*.01>0?t:e:e<0?e:t;case"outer":return t=12,(0,f.HD)(e)&&e.endsWith("%")?parseFloat(e)*.01<0?t:e:e>0?e:t;default:return e}}function sl(r,e){return(0,f.yW)(pa(r,e),function(t){return t[e]===0})}function RF(r){var e=r.chart,t=r.options,n=t.data,i=t.angleField,a=t.colorField,o=t.color,s=t.pieStyle,l=t.shape,u=pa(n,i);if(sl(u,i)){var c="$$percentage$$";u=u.map(function(v){var d;return(0,p.pi)((0,p.pi)({},v),(d={},d[c]=1/u.length,d))}),e.data(u);var h=kt({},r,{options:{xField:"1",yField:c,seriesField:a,isStack:!0,interval:{color:o,shape:l,style:s},args:{zIndexReversed:!0,sortZIndex:!0}}});Tr(h)}else{e.data(u);var h=kt({},r,{options:{xField:"1",yField:i,seriesField:a,isStack:!0,interval:{color:o,shape:l,style:s},args:{zIndexReversed:!0,sortZIndex:!0}}});Tr(h)}return r}function NF(r){var e,t=r.chart,n=r.options,i=n.meta,a=n.colorField,o=kt({},i);return t.scale(o,(e={},e[a]={type:"cat"},e)),r}function UF(r){var e=r.chart,t=r.options,n=t.radius,i=t.innerRadius,a=t.startAngle,o=t.endAngle;return e.coordinate({type:"theta",cfg:{radius:n,innerRadius:i,startAngle:a,endAngle:o}}),r}function zF(r){var e=r.chart,t=r.options,n=t.label,i=t.colorField,a=t.angleField,o=e.geometries[0];if(!n)o.label(!1);else{var s=n.callback,l=(0,p._T)(n,["callback"]),u=xr(l);if(u.content){var c=u.content;u.content=function(g,y,x){var m=g[i],M=g[a],w=e.getScaleByField(a),S=w==null?void 0:w.scale(M);return(0,f.mf)(c)?c((0,p.pi)((0,p.pi)({},g),{percent:S}),y,x):(0,f.HD)(c)?$p(c,{value:M,name:m,percentage:(0,f.hj)(S)&&!(0,f.UM)(M)?"".concat((S*100).toFixed(2),"%"):null}):c}}var h={inner:"",outer:"pie-outer",spider:"pie-spider"},v=u.type?h[u.type]:"pie-outer",d=u.layout?(0,f.kJ)(u.layout)?u.layout:[u.layout]:[];u.layout=(v?[{type:v}]:[]).concat(d),o.label({fields:i?[a,i]:[a],callback:s,cfg:(0,p.pi)((0,p.pi)({},u),{offset:BF(u.type,u.offset),type:"pie"})})}return r}function kg(r){var e=r.innerRadius,t=r.statistic,n=r.angleField,i=r.colorField,a=r.meta,o=r.locale,s=Js(o);if(e&&t){var l=kt({},Dg.statistic,t),u=l.title,c=l.content;return u!==!1&&(u=kt({},{formatter:function(h){var v=h?h[i]:(0,f.UM)(u.content)?s.get(["statistic","total"]):u.content,d=(0,f.U2)(a,[i,"formatter"])||function(g){return g};return d(v)}},u)),c!==!1&&(c=kt({},{formatter:function(h,v){var d=h?h[n]:kF(v,n),g=(0,f.U2)(a,[n,"formatter"])||function(y){return y};return h||(0,f.UM)(c.content)?g(d):c.content}},c)),kt({},{statistic:{title:u,content:c}},r)}return r}function Bg(r){var e=r.chart,t=r.options,n=kg(t),i=n.innerRadius,a=n.statistic;return e.getController("annotation").clear(!0),Fe(sr())(r),i&&a&&qs(e,{statistic:a,plotType:"pie"}),r}function VF(r){var e=r.chart,t=r.options,n=t.tooltip,i=t.colorField,a=t.angleField,o=t.data;if(n===!1)e.tooltip(n);else if(e.tooltip(kt({},n,{shared:!1})),sl(o,a)){var s=(0,f.U2)(n,"fields"),l=(0,f.U2)(n,"formatter");(0,f.xb)((0,f.U2)(n,"fields"))&&(s=[i,a],l=l||function(u){return{name:u[i],value:(0,f.BB)(u[a])}}),e.geometries[0].tooltip(s.join("*"),ga(s,l))}return r}function HF(r){var e=r.chart,t=r.options,n=kg(t),i=n.interactions,a=n.statistic,o=n.annotations;return(0,f.S6)(i,function(s){var l,u;if(s.enable===!1)e.removeInteraction(s.type);else if(s.type==="pie-statistic-active"){var c=[];((l=s.cfg)===null||l===void 0?void 0:l.start)||(c=[{trigger:"element:mouseenter",action:"".concat(Og,":change"),arg:{statistic:a,annotations:o}}]),(0,f.S6)((u=s.cfg)===null||u===void 0?void 0:u.start,function(h){c.push((0,p.pi)((0,p.pi)({},h),{arg:{statistic:a,annotations:o}}))}),e.interaction(s.type,kt({},s.cfg,{start:c}))}else e.interaction(s.type,s.cfg||{})}),r}function Rg(r){return Fe(Kr("pieStyle"),RF,NF,We,UF,ki,VF,zF,hi,Bg,HF,tr)(r)}var Ng=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="pie",t}return e.getDefaultOptions=function(){return Dg},e.prototype.changeData=function(t){this.chart.emit(X.BEFORE_CHANGE_DATA,lr.fromData(this.chart,X.BEFORE_CHANGE_DATA,null));var n=this.options,i=this.options.angleField,a=pa(n.data,i),o=pa(t,i);sl(a,i)||sl(o,i)?this.update({data:t}):(this.updateOption({data:t}),this.chart.data(o),Bg({chart:this.chart,options:this.options}),this.chart.render(!0)),this.chart.emit(X.AFTER_CHANGE_DATA,lr.fromData(this.chart,X.AFTER_CHANGE_DATA,null))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return Rg},e}(Re),Ug=["#FAAD14","#E8EDF3"],GF={percent:.2,color:Ug,animation:{}};function qc(r){var e=(0,f.uZ)(Oi(r)?r:0,0,1);return[{current:"".concat(e),type:"current",percent:e},{current:"".concat(e),type:"target",percent:1}]}function zg(r){var e=r.chart,t=r.options,n=t.percent,i=t.progressStyle,a=t.color,o=t.barWidthRatio;e.data(qc(n));var s=kt({},r,{options:{xField:"current",yField:"percent",seriesField:"type",widthRatio:o,interval:{style:i,color:(0,f.HD)(a)?[a,Ug[1]]:a},args:{zIndexReversed:!0,sortZIndex:!0}}});return Tr(s),e.tooltip(!1),e.axis(!1),e.legend(!1),r}function YF(r){var e=r.chart;return e.coordinate("rect").transpose(),r}function Vg(r){return Fe(zg,ur({}),YF,tr,We,sr())(r)}var XF=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="process",t}return e.getDefaultOptions=function(){return GF},e.prototype.changeData=function(t){this.updateOption({percent:t}),this.chart.changeData(qc(t))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return Vg},e}(Re);function WF(r){var e=r.chart,t=r.options,n=t.innerRadius,i=t.radius;return e.coordinate("theta",{innerRadius:n,radius:i}),r}function Hg(r,e){var t=r.chart,n=r.options,i=n.innerRadius,a=n.statistic,o=n.percent,s=n.meta;if(t.getController("annotation").clear(!0),i&&a){var l=(0,f.U2)(s,["percent","formatter"])||function(c){return"".concat((c*100).toFixed(2),"%")},u=a.content;u&&(u=kt({},u,{content:(0,f.UM)(u.content)?l(o):u.content})),qs(t,{statistic:(0,p.pi)((0,p.pi)({},a),{content:u}),plotType:"ring-progress"},{percent:o})}return e&&t.render(!0),r}function Gg(r){return Fe(zg,ur({}),WF,Hg,tr,We,sr())(r)}var ZF={percent:.2,innerRadius:.8,radius:.98,color:["#FAAD14","#E8EDF3"],statistic:{title:!1,content:{style:{fontSize:"14px",fontWeight:300,fill:"#4D4D4D",textAlign:"center",textBaseline:"middle"}}},animation:{}},$F=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="ring-process",t}return e.getDefaultOptions=function(){return ZF},e.prototype.changeData=function(t){this.chart.emit(X.BEFORE_CHANGE_DATA,lr.fromData(this.chart,X.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(qc(t)),Hg({chart:this.chart,options:this.options},!0),this.chart.emit(X.AFTER_CHANGE_DATA,lr.fromData(this.chart,X.AFTER_CHANGE_DATA,null))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return Gg},e}(Re),Ui=N(56645),qF={exp:Ui.regressionExp,linear:Ui.regressionLinear,loess:Ui.regressionLoess,log:Ui.regressionLog,poly:Ui.regressionPoly,pow:Ui.regressionPow,quad:Ui.regressionQuad};function KF(r,e){var t=10,n={regionStyle:[{position:{start:[r,"max"],end:["max",e]},style:{fill:"#d8d0c0",opacity:.4}},{position:{start:["min","max"],end:[r,e]},style:{fill:"#a3dda1",opacity:.4}},{position:{start:["min",e],end:[r,"min"]},style:{fill:"#d8d0c0",opacity:.4}},{position:{start:[r,e],end:["max","min"]},style:{fill:"#a3dda1",opacity:.4}}],lineStyle:{stroke:"#9ba29a",lineWidth:1},labelStyle:[{position:["max",e],offsetX:-t,offsetY:-t,style:{textAlign:"right",textBaseline:"bottom",fontSize:14,fill:"#ccc"}},{position:["min",e],offsetX:t,offsetY:-t,style:{textAlign:"left",textBaseline:"bottom",fontSize:14,fill:"#ccc"}},{position:["min",e],offsetX:t,offsetY:t,style:{textAlign:"left",textBaseline:"top",fontSize:14,fill:"#ccc"}},{position:["max",e],offsetX:-t,offsetY:t,style:{textAlign:"right",textBaseline:"top",fontSize:14,fill:"#ccc"}}]};return n}var jF=function(r,e){var t=e.view,n=e.options,i=n.xField,a=n.yField,o=t.getScaleByField(i),s=t.getScaleByField(a),l=r.map(function(u){return t.getCoordinate().convert({x:o.scale(u[0]),y:s.scale(u[1])})});return $E(l,!1)},JF=function(r){var e=r.options,t=e.xField,n=e.yField,i=e.data,a=e.regressionLine,o=a.type,s=o===void 0?"linear":o,l=a.algorithm,u=a.equation,c,h=null;if(l)c=(0,f.kJ)(l)?l:l(i),h=u;else{var v=qF[s]().x(function(d){return d[t]}).y(function(d){return d[n]});c=v(i),h=tI(s,c)}return[jF(c,r),h]},QF=function(r){var e,t=r.meta,n=t===void 0?{}:t,i=r.xField,a=r.yField,o=r.data,s=o[0][i],l=o[0][a],u=s>0,c=l>0;function h(v,d){var g=(0,f.U2)(n,[v]);function y(m){return(0,f.U2)(g,m)}var x={};return d==="x"?((0,f.hj)(s)&&((0,f.hj)(y("min"))||(x.min=u?0:s*2),(0,f.hj)(y("max"))||(x.max=u?s*2:0)),x):((0,f.hj)(l)&&((0,f.hj)(y("min"))||(x.min=c?0:l*2),(0,f.hj)(y("max"))||(x.max=c?l*2:0)),x)}return(0,p.pi)((0,p.pi)({},n),(e={},e[i]=(0,p.pi)((0,p.pi)({},n[i]),h(i,"x")),e[a]=(0,p.pi)((0,p.pi)({},n[a]),h(a,"y")),e))};function tI(r,e){var t,n,i,a=function(u,c){return c===void 0&&(c=4),Math.round(u*Math.pow(10,c))/Math.pow(10,c)},o=function(u){return Number.isFinite(u)?a(u):"?"};switch(r){case"linear":return"y = ".concat(o(e.a),"x + ").concat(o(e.b),", R^2 = ").concat(o(e.rSquared));case"exp":return"y = ".concat(o(e.a),"e^(").concat(o(e.b),"x), R^2 = ").concat(o(e.rSquared));case"log":return"y = ".concat(o(e.a),"ln(x) + ").concat(o(e.b),", R^2 = ").concat(o(e.rSquared));case"quad":return"y = ".concat(o(e.a),"x^2 + ").concat(o(e.b),"x + ").concat(o(e.c),", R^2 = ").concat(o(e.rSquared));case"poly":for(var s="y = ".concat(o((t=e.coefficients)===null||t===void 0?void 0:t[0])," + ").concat(o((n=e.coefficients)===null||n===void 0?void 0:n[1]),"x + ").concat(o((i=e.coefficients)===null||i===void 0?void 0:i[2]),"x^2"),l=3;l<e.coefficients.length;++l)s+=" + ".concat(o(e.coefficients[l]),"x^").concat(l);return"".concat(s,", R^2 = ").concat(o(e.rSquared));case"pow":return"y = ".concat(o(e.a),"x^").concat(o(e.b),", R^2 = ").concat(o(e.rSquared))}return null}function Yg(r){var e=r.data,t=e===void 0?[]:e,n=r.xField,i=r.yField;if(t.length){for(var a=!0,o=!0,s=t[0],l=void 0,u=1;u<t.length&&(l=t[u],s[n]!==l[n]&&(a=!1),s[i]!==l[i]&&(o=!1),!(!a&&!o));u++)s=l;var c=[];a&&c.push(n),o&&c.push(i);var h=Qe(QF(r),c);return kt({},r,{meta:h})}return r}function eI(r){var e=r.chart,t=r.options,n=t.data,i=t.type,a=t.color,o=t.shape,s=t.pointStyle,l=t.shapeField,u=t.colorField,c=t.xField,h=t.yField,v=t.sizeField,d=t.size,g=t.tooltip;v&&(d||(d=[2,8]),(0,f.hj)(d)&&(d=[d,d])),g&&!g.fields&&(g=(0,p.pi)((0,p.pi)({},g),{fields:[c,h,u,v,l]})),e.data(n),jr(kt({},r,{options:{seriesField:u,point:{color:a,shape:o,size:d,style:s},tooltip:g}}));var y=br(e,"point");return i&&y.adjust(i),r}function ll(r){var e,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField,s=Yg(t);return Fe(ur((e={},e[a]=n,e[o]=i,e)))(kt({},r,{options:s}))}function rI(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return e.axis(a,n),e.axis(o,i),r}function nI(r){var e=r.chart,t=r.options,n=t.legend,i=t.colorField,a=t.shapeField,o=t.sizeField,s=t.shapeLegend,l=t.sizeLegend,u=n!==!1;return i&&e.legend(i,u?n:!1),a&&(s?e.legend(a,s):e.legend(a,s===!1?!1:n)),o&&e.legend(o,l||!1),!u&&!s&&!l&&e.legend(!1),r}function iI(r){var e=r.chart,t=r.options,n=t.label,i=t.yField,a=br(e,"point");if(!n)a.label(!1);else{var o=n.callback,s=(0,p._T)(n,["callback"]);a.label({fields:[i],callback:o,cfg:xr(s)})}return r}function aI(r){var e=r.options,t=e.quadrant,n=[];if(t){var i=t.xBaseline,a=i===void 0?0:i,o=t.yBaseline,s=o===void 0?0:o,l=t.labels,u=t.regionStyle,c=t.lineStyle,h=KF(a,s),v=new Array(4).join(",").split(",");v.forEach(function(d,g){n.push((0,p.pi)((0,p.pi)({type:"region",top:!1},h.regionStyle[g].position),{style:kt({},h.regionStyle[g].style,u==null?void 0:u[g])}),(0,p.pi)({type:"text",top:!0},kt({},h.labelStyle[g],l==null?void 0:l[g])))}),n.push({type:"line",top:!1,start:["min",s],end:["max",s],style:kt({},h.lineStyle,c)},{type:"line",top:!1,start:[a,"min"],end:[a,"max"],style:kt({},h.lineStyle,c)})}return Fe(sr(n))(r)}function oI(r){var e=r.options,t=r.chart,n=e.regressionLine;if(n){var i=n.style,a=n.equationStyle,o=a===void 0?{}:a,s=n.top,l=s===void 0?!1:s,u=n.showEquation,c=u===void 0?!1:u,h={stroke:"#9ba29a",lineWidth:2,opacity:.5},v={x:20,y:20,textAlign:"left",textBaseline:"middle",fontSize:14,fillOpacity:.5};t.annotation().shape({top:l,render:function(d,g){var y=d.addGroup({id:"".concat(t.id,"-regression-line"),name:"regression-line-group"}),x=JF({view:g,options:e}),m=x[0],M=x[1];y.addShape("path",{name:"regression-line",attrs:(0,p.pi)((0,p.pi)({path:m},h),i)}),c&&y.addShape("text",{name:"regression-equation",attrs:(0,p.pi)((0,p.pi)((0,p.pi)({},v),o),{text:M})})}})}return r}function sI(r){var e=r.chart,t=r.options,n=t.tooltip;return n?e.tooltip(n):n===!1&&e.tooltip(!1),r}function Xg(r){return Fe(eI,ll,rI,nI,sI,iI,fg,xo,Nc,or,aI,tr,We,oI)(r)}var lI=kt({},Re.getDefaultOptions(),{size:4,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!0,crosshairs:{type:"xy"}}});De("drag-move",{start:[{trigger:"plot:mousedown",action:"scale-translate:start"}],processing:[{trigger:"plot:mousemove",action:"scale-translate:translate",throttle:{wait:100,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseup",action:"scale-translate:end"}]});var uI=function(r){(0,p.ZT)(e,r);function e(t,n){var i=r.call(this,t,n)||this;return i.type="scatter",i.on(X.BEFORE_RENDER,function(a){var o,s,l=i,u=l.options,c=l.chart;if(((o=a.data)===null||o===void 0?void 0:o.source)===Vr.FILTER){var h=i.chart.filterData(i.chart.getData());ll({chart:c,options:(0,p.pi)((0,p.pi)({},u),{data:h})})}((s=a.data)===null||s===void 0?void 0:s.source)===Vr.RESET&&ll({chart:c,options:u})}),i}return e.getDefaultOptions=function(){return lI},e.prototype.changeData=function(t){this.updateOption(Yg(kt({},this.options,{data:t})));var n=this,i=n.options,a=n.chart;ll({chart:a,options:i}),this.chart.changeData(t)},e.prototype.getSchemaAdaptor=function(){return Xg},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(Re),Ao="$$stock-range$$",ul="trend",Wg="up",Zg="down",cI={showMarkers:!1,showCrosshairs:!0,shared:!0,crosshairs:{type:"xy",follow:!0,text:function(r,e,t){var n;if(r==="x"){var i=t[0];n=i?i.title:e}else n=e;return{position:r==="y"?"start":"end",content:n,style:{fill:"#dfdfdf"}}},textBackground:{padding:[2,4],style:{fill:"#666"}}}},fI=kt({},Re.getDefaultOptions(),{tooltip:cI,interactions:[{type:"tooltip"}],legend:{position:"top-left"},risingFill:"#ef5350",fallingFill:"#26a69a"});function $g(r,e){return(0,f.UI)(r,function(t){var n=t&&(0,p.pi)({},t);if((0,f.kJ)(e)&&n){var i=e[0],a=e[1],o=e[2],s=e[3];n[ul]=n[i]<=n[a]?Wg:Zg,n[Ao]=[n[i],n[a],n[o],n[s]]}return n})}function hI(r){var e=r.chart,t=r.options,n=t.yField,i=t.data,a=t.risingFill,o=t.fallingFill,s=t.tooltip,l=t.stockStyle;e.data($g(i,n));var u=s;return u!==!1&&(u=kt({},{fields:n},u)),Uc(kt({},r,{options:{schema:{shape:"candle",color:[a,o],style:l},yField:Ao,seriesField:ul,rawFields:n,tooltip:u}})),r}function vI(r){var e,t,n=r.chart,i=r.options,a=i.meta,o=i.xAxis,s=i.yAxis,l=i.xField,u=(e={},e[l]={type:"timeCat",tickCount:6},e[ul]={values:[Wg,Zg]},e),c=kt(u,a,(t={},t[l]=Qe(o,Hr),t[Ao]=Qe(s,Hr),t));return n.scale(c),r}function dI(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField;return n===!1?e.axis(a,!1):e.axis(a,n),i===!1?e.axis(Ao,!1):e.axis(Ao,i),r}function pI(r){var e=r.chart,t=r.options,n=t.tooltip;return n!==!1?e.tooltip(n):e.tooltip(!1),r}function gI(r){var e=r.chart,t=r.options,n=t.legend;return n?e.legend(ul,n):n===!1&&e.legend(!1),r}function qg(r){Fe(We,hI,vI,dI,pI,gI,or,tr,sr(),xo)(r)}var yI=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="stock",t}return e.getDefaultOptions=function(){return fI},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return qg},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this.options.yField;this.chart.changeData($g(t,n))},e}(Re);function zi(r){return(0,f.UI)(r||[],function(e,t){return{x:"".concat(t),y:e}})}var bo="x",ma="y",Kg={showTitle:!1,shared:!0,showMarkers:!1,customContent:function(r,e){return"".concat((0,f.U2)(e,[0,"data","y"],0))},containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',itemTpl:"<span>{value}</span>",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}},showCrosshairs:!0,crosshairs:{type:"x"}},mI={appendPadding:2,tooltip:(0,p.pi)({},Kg),animation:{}};function xI(r){var e=r.chart,t=r.options,n=t.data,i=t.color,a=t.areaStyle,o=t.point,s=t.line,l=o==null?void 0:o.state,u=zi(n);e.data(u);var c=kt({},r,{options:{xField:bo,yField:ma,area:{color:i,style:a},line:s,point:o}}),h=kt({},c,{options:{tooltip:!1}}),v=kt({},c,{options:{tooltip:!1,state:l}});return tl(c),ya(h),jr(v),e.axis(!1),e.legend(!1),r}function xa(r){var e,t,n=r.options,i=n.xAxis,a=n.yAxis,o=n.data,s=zi(o);return Fe(ur((e={},e[bo]=i,e[ma]=a,e),(t={},t[bo]={type:"cat"},t[ma]=Pc(s,ma),t)))(r)}function jg(r){return Fe(Kr("areaStyle"),xI,xa,pr,We,tr,sr())(r)}var MI={appendPadding:2,tooltip:(0,p.pi)({},Kg),color:"l(90) 0:#E5EDFE 1:#ffffff",areaStyle:{fillOpacity:.6},line:{size:1,color:"#5B8FF9"},animation:{}},wI=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="tiny-area",t}return e.getDefaultOptions=function(){return MI},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this,i=n.chart,a=n.options;xa({chart:i,options:a}),i.changeData(zi(t))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return jg},e}(Re);function SI(r){var e=r.chart,t=r.options,n=t.data,i=t.color,a=t.columnStyle,o=t.columnWidthRatio,s=zi(n);e.data(s);var l=kt({},r,{options:{xField:bo,yField:ma,widthRatio:o,interval:{style:a,color:i}}});return Tr(l),e.axis(!1),e.legend(!1),e.interaction("element-active"),r}function Jg(r){return Fe(We,Kr("columnStyle"),SI,xa,pr,tr,sr())(r)}var CI={showTitle:!1,shared:!0,showMarkers:!1,customContent:function(r,e){return"".concat((0,f.U2)(e,[0,"data","y"],0))},containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',itemTpl:"<span>{value}</span>",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}}},AI={appendPadding:2,tooltip:(0,p.pi)({},CI),animation:{}},bI=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="tiny-column",t}return e.getDefaultOptions=function(){return AI},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this,i=n.chart,a=n.options;xa({chart:i,options:a}),i.changeData(zi(t))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return Jg},e}(Re);function TI(r){var e=r.chart,t=r.options,n=t.data,i=t.color,a=t.lineStyle,o=t.point,s=o==null?void 0:o.state,l=zi(n);e.data(l);var u=kt({},r,{options:{xField:bo,yField:ma,line:{color:i,style:a},point:o}}),c=kt({},u,{options:{tooltip:!1,state:s}});return ya(u),jr(c),e.axis(!1),e.legend(!1),r}function Qg(r){return Fe(TI,xa,We,pr,tr,sr())(r)}var EI=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="tiny-line",t}return e.getDefaultOptions=function(){return mI},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this,i=n.chart,a=n.options;xa({chart:i,options:a}),i.changeData(zi(t))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return Qg},e}(Re),_I={line:sg,pie:Rg,column:il,bar:vg,area:lg,gauge:_g,"tiny-line":Qg,"tiny-column":Jg,"tiny-area":jg,"ring-progress":Gg,progress:Vg,scatter:Xg,histogram:Pg,funnel:wg,stock:qg},FI={line:Lg,pie:Ng,column:dg,bar:H_,area:ug,gauge:wF,"tiny-line":EI,"tiny-column":bI,"tiny-area":wI,"ring-progress":$F,progress:XF,scatter:uI,histogram:_F,funnel:vF,stock:yI},II={pie:{label:!1},column:{tooltip:{showMarkers:!1}},bar:{tooltip:{showMarkers:!1}}};function Kc(r,e,t){var n=FI[r];if(!n){console.error("could not find ".concat(r," plot"));return}var i=_I[r];i({chart:e,options:kt({},n.getDefaultOptions(),(0,f.U2)(II,r,{}),t)})}function PI(r){var e=r.chart,t=r.options,n=t.views,i=t.legend;return(0,f.S6)(n,function(a){var o=a.region,s=a.data,l=a.meta,u=a.axes,c=a.coordinate,h=a.interactions,v=a.annotations,d=a.tooltip,g=a.geometries,y=e.createView({region:o});y.data(s);var x={};u&&(0,f.S6)(u,function(m,M){x[M]=Qe(m,Hr)}),x=kt({},l,x),y.scale(x),u?(0,f.S6)(u,function(m,M){y.axis(M,m)}):y.axis(!1),y.coordinate(c),(0,f.S6)(g,function(m){var M=Gr({chart:y,options:m}).ext,w=m.adjust;w&&M.geometry.adjust(w)}),(0,f.S6)(h,function(m){m.enable===!1?y.removeInteraction(m.type):y.interaction(m.type,m.cfg)}),(0,f.S6)(v,function(m){y.annotation()[m.type]((0,p.pi)({},m))}),typeof a.animation=="boolean"?y.animate(!1):(y.animate(!0),(0,f.S6)(y.geometries,function(m){m.animate(a.animation)})),d&&(y.interaction("tooltip"),y.tooltip(d))}),i?(0,f.S6)(i,function(a,o){e.legend(o,a)}):e.legend(!1),e.tooltip(t.tooltip),r}function LI(r){var e=r.chart,t=r.options,n=t.plots,i=t.data,a=i===void 0?[]:i;return(0,f.S6)(n,function(o){var s=o.type,l=o.region,u=o.options,c=u===void 0?{}:u,h=o.top,v=c.tooltip;if(h){Kc(s,e,(0,p.pi)((0,p.pi)({},c),{data:a}));return}var d=e.createView((0,p.pi)({region:l},Qe(c,ng)));v&&d.interaction("tooltip"),Kc(s,d,(0,p.pi)({data:a},c))}),r}function DI(r){var e=r.chart,t=r.options;return e.option("slider",t.slider),r}function OI(r){return Fe(tr,PI,LI,or,tr,We,pr,DI,sr())(r)}function kI(r,e){var t=r.getModel(),n=t.data,i;return(0,f.kJ)(n)?i=n[0][e]:i=n[e],i}function BI(r){var e=Zs(r);(0,f.S6)(e,function(t){t.hasState("active")&&t.setState("active",!1),t.hasState("selected")&&t.setState("selected",!1),t.hasState("inactive")&&t.setState("inactive",!1)})}var RI=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getAssociationItems=function(t,n){var i,a=this.context.event,o=n||{},s=o.linkField,l=o.dim,u=[];if((i=a.data)===null||i===void 0?void 0:i.data){var c=a.data.data;(0,f.S6)(t,function(h){var v,d,g=s;if(l==="x"?g=h.getXScale().field:l==="y"?g=(v=h.getYScales().find(function(x){return x.field===g}))===null||v===void 0?void 0:v.field:g||(g=(d=h.getGroupScales()[0])===null||d===void 0?void 0:d.field),!!g){var y=(0,f.UI)(Zs(h),function(x){var m=!1,M=!1,w=(0,f.kJ)(c)?(0,f.U2)(c[0],g):(0,f.U2)(c,g);return kI(x,g)===w?m=!0:M=!0,{element:x,view:h,active:m,inactive:M}});u.push.apply(u,y)}})}return u},e.prototype.showTooltip=function(t){var n=qp(this.context.view),i=this.getAssociationItems(n,t);(0,f.S6)(i,function(a){if(a.active){var o=a.element.shape.getCanvasBBox();a.view.showTooltip({x:o.minX+o.width/2,y:o.minY+o.height/2})}})},e.prototype.hideTooltip=function(){var t=qp(this.context.view);(0,f.S6)(t,function(n){n.hideTooltip()})},e.prototype.active=function(t){var n=yo(this.context.view),i=this.getAssociationItems(n,t);(0,f.S6)(i,function(a){var o=a.active,s=a.element;o&&s.setState("active",!0)})},e.prototype.selected=function(t){var n=yo(this.context.view),i=this.getAssociationItems(n,t);(0,f.S6)(i,function(a){var o=a.active,s=a.element;o&&s.setState("selected",!0)})},e.prototype.highlight=function(t){var n=yo(this.context.view),i=this.getAssociationItems(n,t);(0,f.S6)(i,function(a){var o=a.inactive,s=a.element;o&&s.setState("inactive",!0)})},e.prototype.reset=function(){var t=yo(this.context.view);(0,f.S6)(t,function(n){BI(n)})},e}(ar);Te("association",RI),De("association-active",{start:[{trigger:"element:mouseenter",action:"association:active"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]}),De("association-selected",{start:[{trigger:"element:mouseenter",action:"association:selected"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]}),De("association-highlight",{start:[{trigger:"element:mouseenter",action:"association:highlight"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]}),De("association-tooltip",{start:[{trigger:"element:mousemove",action:"association:showTooltip"}],end:[{trigger:"element:mouseleave",action:"association:hideTooltip"}]});var NI=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="mix",t}return e.prototype.getSchemaAdaptor=function(){return OI},e}(Re),Ma;(function(r){r.DEV="DEV",r.BETA="BETA",r.STABLE="STABLE"})(Ma||(Ma={}));function UI(r,e){console.warn(r===Ma.DEV?"Plot '".concat(e,"' is in DEV stage, just give us issues."):r===Ma.BETA?"Plot '".concat(e,"' is in BETA stage, DO NOT use it in production env."):r===Ma.STABLE?"Plot '".concat(e,`' is in STABLE stage, import it by "import { `).concat(e,` } from '@antv/g2plot'".`):"invalid Stage type.")}var g5=function(){function r(){}return Object.defineProperty(r,"MultiView",{get:function(){return UI(Ma.STABLE,"MultiView"),NI},enumerable:!1,configurable:!0}),r}(),_n="first-axes-view",Fn="second-axes-view",Vi="series-field-key";function t0(r,e,t,n,i){var a=[];e.forEach(function(h){n.forEach(function(v){var d,g=(d={},d[r]=v[r],d[t]=h,d[h]=v[h],d);a.push(g)})});var o=Object.values((0,f.vM)(a,t)),s=o[0],l=s===void 0?[]:s,u=o[1],c=u===void 0?[]:u;return i?[l.reverse(),c.reverse()]:[l,c]}function Wn(r){return r!=="vertical"}function zI(r,e,t){var n=e[0],i=e[1],a=n.autoPadding,o=i.autoPadding,s=r.__axisPosition,l=s.layout,u=s.position;if(Wn(l)&&u==="top"&&(n.autoPadding=t.instance(a.top,0,a.bottom,a.left),i.autoPadding=t.instance(o.top,a.left,o.bottom,0)),Wn(l)&&u==="bottom"&&(n.autoPadding=t.instance(a.top,a.right/2+5,a.bottom,a.left),i.autoPadding=t.instance(o.top,o.right,o.bottom,a.right/2+5)),!Wn(l)&&u==="bottom"){var c=a.left>=o.left?a.left:o.left;n.autoPadding=t.instance(a.top,a.right,a.bottom/2+5,c),i.autoPadding=t.instance(a.bottom/2+5,o.right,o.bottom,c)}if(!Wn(l)&&u==="top"){var c=a.left>=o.left?a.left:o.left;n.autoPadding=t.instance(a.top,a.right,0,c),i.autoPadding=t.instance(0,o.right,a.top,c)}}function VI(r){var e=r.chart,t=r.options,n=t.data,i=t.xField,a=t.yField,o=t.color,s=t.barStyle,l=t.widthRatio,u=t.legend,c=t.layout,h=t0(i,a,Vi,n,Wn(c));u?e.legend(Vi,u):u===!1&&e.legend(!1);var v,d,g=h[0],y=h[1];Wn(c)?(v=e.createView({region:{start:{x:0,y:0},end:{x:.5,y:1}},id:_n}),v.coordinate().transpose().reflect("x"),d=e.createView({region:{start:{x:.5,y:0},end:{x:1,y:1}},id:Fn}),d.coordinate().transpose(),v.data(g),d.data(y)):(v=e.createView({region:{start:{x:0,y:0},end:{x:1,y:.5}},id:_n}),d=e.createView({region:{start:{x:0,y:.5},end:{x:1,y:1}},id:Fn}),d.coordinate().reflect("y"),v.data(g),d.data(y));var x=kt({},r,{chart:v,options:{widthRatio:l,xField:i,yField:a[0],seriesField:Vi,interval:{color:o,style:s}}});Tr(x);var m=kt({},r,{chart:d,options:{xField:i,yField:a[1],seriesField:Vi,widthRatio:l,interval:{color:o,style:s}}});return Tr(m),r}function HI(r){var e,t,n,i=r.options,a=r.chart,o=i.xAxis,s=i.yAxis,l=i.xField,u=i.yField,c=Ve(a,_n),h=Ve(a,Fn),v={};return(0,f.XP)((i==null?void 0:i.meta)||{}).map(function(d){(0,f.U2)(i==null?void 0:i.meta,[d,"alias"])&&(v[d]=i.meta[d].alias)}),a.scale((e={},e[Vi]={sync:!0,formatter:function(d){return(0,f.U2)(v,d,d)}},e)),ur((t={},t[l]=o,t[u[0]]=s[u[0]],t))(kt({},r,{chart:c})),ur((n={},n[l]=o,n[u[1]]=s[u[1]],n))(kt({},r,{chart:h})),r}function GI(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField,s=t.layout,l=Ve(e,_n),u=Ve(e,Fn);return(n==null?void 0:n.position)==="bottom"?u.axis(a,(0,p.pi)((0,p.pi)({},n),{label:{formatter:function(){return""}}})):u.axis(a,!1),n===!1?l.axis(a,!1):l.axis(a,(0,p.pi)({position:Wn(s)?"top":"bottom"},n)),i===!1?(l.axis(o[0],!1),u.axis(o[1],!1)):(l.axis(o[0],i[o[0]]),u.axis(o[1],i[o[1]])),e.__axisPosition={position:l.getOptions().axes[a].position,layout:s},r}function YI(r){var e=r.chart;return or(kt({},r,{chart:Ve(e,_n)})),or(kt({},r,{chart:Ve(e,Fn)})),r}function XI(r){var e=r.chart,t=r.options,n=t.yField,i=t.yAxis;return Bi(kt({},r,{chart:Ve(e,_n),options:{yAxis:i[n[0]]}})),Bi(kt({},r,{chart:Ve(e,Fn),options:{yAxis:i[n[1]]}})),r}function WI(r){var e=r.chart;return We(kt({},r,{chart:Ve(e,_n)})),We(kt({},r,{chart:Ve(e,Fn)})),We(r),r}function ZI(r){var e=r.chart;return tr(kt({},r,{chart:Ve(e,_n)})),tr(kt({},r,{chart:Ve(e,Fn)})),r}function $I(r){var e=this,t,n,i=r.chart,a=r.options,o=a.label,s=a.yField,l=a.layout,u=Ve(i,_n),c=Ve(i,Fn),h=br(u,"interval"),v=br(c,"interval");if(!o)h.label(!1),v.label(!1);else{var d=o.callback,g=(0,p._T)(o,["callback"]);g.position||(g.position="middle"),g.offset===void 0&&(g.offset=2);var y=(0,p.pi)({},g);if(Wn(l)){var x=((t=y.style)===null||t===void 0?void 0:t.textAlign)||(g.position==="middle"?"center":"left");g.style=kt({},g.style,{textAlign:x});var m={left:"right",right:"left",center:"center"};y.style=kt({},y.style,{textAlign:m[x]})}else{var M={top:"bottom",bottom:"top",middle:"middle"};typeof g.position=="string"?g.position=M[g.position]:typeof g.position=="function"&&(g.position=function(){for(var b=[],k=0;k<arguments.length;k++)b[k]=arguments[k];return M[g.position.apply(e,b)]});var w=((n=y.style)===null||n===void 0?void 0:n.textBaseline)||"bottom";y.style=kt({},y.style,{textBaseline:w});var S={top:"bottom",bottom:"top",middle:"middle"};g.style=kt({},g.style,{textBaseline:S[w]})}h.label({fields:[s[0]],callback:d,cfg:xr(y)}),v.label({fields:[s[1]],callback:d,cfg:xr(g)})}return r}function qI(r){return Fe(VI,HI,GI,XI,WI,$I,pr,YI,ZI)(r)}var y5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="bidirectional-bar",t}return e.getDefaultOptions=function(){return kt({},r.getDefaultOptions.call(this),{syncViewPadding:zI})},e.prototype.changeData=function(t){t===void 0&&(t=[]),this.chart.emit(X.BEFORE_CHANGE_DATA,lr.fromData(this.chart,X.BEFORE_CHANGE_DATA,null)),this.updateOption({data:t});var n=this.options,i=n.xField,a=n.yField,o=n.layout,s=t0(i,a,Vi,t,Wn(o)),l=s[0],u=s[1],c=Ve(this.chart,_n),h=Ve(this.chart,Fn);c.data(l),h.data(u),this.chart.render(!0),this.chart.emit(X.AFTER_CHANGE_DATA,lr.fromData(this.chart,X.AFTER_CHANGE_DATA,null))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return qI},e.SERIES_FIELD_KEY=Vi,e}(Re),jc,wa="$$range$$",KI="low-q1-median-q3-high",jI="$$y_outliers$$",e0="outliers_view",JI=kt({},Re.getDefaultOptions(),{meta:(jc={},jc[wa]={min:0,alias:KI},jc),interactions:[{type:"active-region"}],tooltip:{showMarkers:!1,shared:!0},boxStyle:{lineWidth:1}}),r0=function(r,e){var t=r;if(Array.isArray(e)){var n=e[0],i=e[1],a=e[2],o=e[3],s=e[4];t=(0,f.UI)(r,function(l){return l[wa]=[l[n],l[i],l[a],l[o],l[s]],l})}return t};function QI(r){var e=r.chart,t=r.options,n=t.xField,i=t.yField,a=t.groupField,o=t.color,s=t.tooltip,l=t.boxStyle;e.data(r0(t.data,i));var u=(0,f.kJ)(i)?wa:i,c=i?(0,f.kJ)(i)?i:[i]:[],h=s;h!==!1&&(h=kt({},{fields:(0,f.kJ)(i)?i:[]},h));var v=Uc(kt({},r,{options:{xField:n,yField:u,seriesField:a,tooltip:h,rawFields:c,label:!1,schema:{shape:"box",color:o,style:l}}})).ext;return a&&v.geometry.adjust("dodge"),r}function tP(r){var e=r.chart,t=r.options,n=t.xField,i=t.data,a=t.outliersField,o=t.outliersStyle,s=t.padding,l=t.label;if(!a)return r;var u=e.createView({padding:s,id:e0}),c=i.reduce(function(h,v){var d=v[a];return d.forEach(function(g){var y;return h.push((0,p.pi)((0,p.pi)({},v),(y={},y[a]=g,y)))}),h},[]);return u.data(c),jr({chart:u,options:{xField:n,yField:a,point:{shape:"circle",style:o},label:l}}),u.axis(!1),r}function eP(r){var e,t,n=r.chart,i=r.options,a=i.meta,o=i.xAxis,s=i.yAxis,l=i.xField,u=i.yField,c=i.outliersField,h=Array.isArray(u)?wa:u,v={};if(c){var d=jI;v=(e={},e[c]={sync:d,nice:!0},e[h]={sync:d,nice:!0},e)}var g=kt(v,a,(t={},t[l]=Qe(o,Hr),t[h]=Qe(s,Hr),t));return n.scale(g),r}function rP(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField,s=Array.isArray(o)?wa:o;return n===!1?e.axis(a,!1):e.axis(a,n),i===!1?e.axis(wa,!1):e.axis(s,i),r}function nP(r){var e=r.chart,t=r.options,n=t.legend,i=t.groupField;return i?n?e.legend(i,n):e.legend(i,{position:"bottom"}):e.legend(!1),r}function iP(r){return Fe(QI,tP,eP,rP,nP,pr,sr(),or,tr,We)(r)}var m5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="box",t}return e.getDefaultOptions=function(){return JI},e.prototype.changeData=function(t){this.updateOption({data:t});var n=this.options.yField,i=this.chart.views.find(function(a){return a.id===e0});i&&i.data(t),this.chart.changeData(r0(t,n))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return iP},e}(Re);function n0(r,e,t){return r.length>1?"".concat(e,"_").concat(t):"".concat(e)}function i0(r){var e=r.data,t=r.xField,n=r.measureField,i=r.rangeField,a=r.targetField,o=r.layout,s=[],l=[];e.forEach(function(h,v){var d=[h[i]].flat();d.sort(function(x,m){return x-m}),d.forEach(function(x,m){var M,w=m===0?x:d[m]-d[m-1];s.push((M={rKey:"".concat(i,"_").concat(m)},M[t]=t?h[t]:String(v),M[i]=w,M))});var g=[h[n]].flat();g.forEach(function(x,m){var M;s.push((M={mKey:n0(g,n,m)},M[t]=t?h[t]:String(v),M[n]=x,M))});var y=[h[a]].flat();y.forEach(function(x,m){var M;s.push((M={tKey:n0(y,a,m)},M[t]=t?h[t]:String(v),M[a]=x,M))}),l.push(h[i],h[n],h[a])});var u=Math.min.apply(Math,l.flat(Infinity)),c=Math.max.apply(Math,l.flat(Infinity));return u=u>0?0:u,o==="vertical"&&s.reverse(),{min:u,max:c,ds:s}}function aP(r){var e=r.chart,t=r.options,n=t.bulletStyle,i=t.targetField,a=t.rangeField,o=t.measureField,s=t.xField,l=t.color,u=t.layout,c=t.size,h=t.label,v=i0(t),d=v.min,g=v.max,y=v.ds;e.data(y);var x=kt({},r,{options:{xField:s,yField:a,seriesField:"rKey",isStack:!0,label:(0,f.U2)(h,"range"),interval:{color:(0,f.U2)(l,"range"),style:(0,f.U2)(n,"range"),size:(0,f.U2)(c,"range")}}});Tr(x),e.geometries[0].tooltip(!1);var m=kt({},r,{options:{xField:s,yField:o,seriesField:"mKey",isStack:!0,label:(0,f.U2)(h,"measure"),interval:{color:(0,f.U2)(l,"measure"),style:(0,f.U2)(n,"measure"),size:(0,f.U2)(c,"measure")}}});Tr(m);var M=kt({},r,{options:{xField:s,yField:i,seriesField:"tKey",label:(0,f.U2)(h,"target"),point:{color:(0,f.U2)(l,"target"),style:(0,f.U2)(n,"target"),size:(0,f.mf)((0,f.U2)(c,"target"))?function(w){return(0,f.U2)(c,"target")(w)/2}:(0,f.U2)(c,"target")/2,shape:u==="horizontal"?"line":"hyphen"}}});return jr(M),u==="horizontal"&&e.coordinate().transpose(),(0,p.pi)((0,p.pi)({},r),{ext:{data:{min:d,max:g}}})}function a0(r){var e,t,n=r.options,i=r.ext,a=n.xAxis,o=n.yAxis,s=n.targetField,l=n.rangeField,u=n.measureField,c=n.xField,h=i.data;return Fe(ur((e={},e[c]=a,e[u]=o,e),(t={},t[u]={min:h==null?void 0:h.min,max:h==null?void 0:h.max,sync:!0},t[s]={sync:"".concat(u)},t[l]={sync:"".concat(u)},t)))(r)}function oP(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.measureField,s=t.rangeField,l=t.targetField;return e.axis("".concat(s),!1),e.axis("".concat(l),!1),n===!1?e.axis("".concat(a),!1):e.axis("".concat(a),n),i===!1?e.axis("".concat(o),!1):e.axis("".concat(o),i),r}function sP(r){var e=r.chart,t=r.options,n=t.legend;return e.removeInteraction("legend-filter"),e.legend(n),e.legend("rKey",!1),e.legend("mKey",!1),e.legend("tKey",!1),r}function lP(r){var e=r.chart,t=r.options,n=t.label,i=t.measureField,a=t.targetField,o=t.rangeField,s=e.geometries,l=s[0],u=s[1],c=s[2];return(0,f.U2)(n,"range")?l.label("".concat(o),(0,p.pi)({layout:[{type:"limit-in-plot"}]},xr(n.range))):l.label(!1),(0,f.U2)(n,"measure")?u.label("".concat(i),(0,p.pi)({layout:[{type:"limit-in-plot"}]},xr(n.measure))):u.label(!1),(0,f.U2)(n,"target")?c.label("".concat(a),(0,p.pi)({layout:[{type:"limit-in-plot"}]},xr(n.target))):c.label(!1),r}function uP(r){Fe(aP,a0,oP,sP,We,lP,pr,or,tr)(r)}var cP=kt({},Re.getDefaultOptions(),{layout:"horizontal",size:{range:30,measure:20,target:20},xAxis:{tickLine:!1,line:null},bulletStyle:{range:{fillOpacity:.5}},label:{measure:{position:"right"}},tooltip:{showMarkers:!1}}),x5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="bullet",t}return e.getDefaultOptions=function(){return cP},e.prototype.changeData=function(t){this.updateOption({data:t});var n=i0(this.options),i=n.min,a=n.max,o=n.ds;a0({options:this.options,ext:{data:{min:i,max:a}},chart:this.chart}),this.chart.changeData(o)},e.prototype.getSchemaAdaptor=function(){return uP},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(Re),fP={y:0,nodeWidthRatio:.05,weight:!1,nodePaddingRatio:.1,id:function(r){return r.id},source:function(r){return r.source},target:function(r){return r.target},sourceWeight:function(r){return r.value||1},targetWeight:function(r){return r.value||1},sortBy:null};function hP(r,e,t){(0,f.U5)(r,function(n,i){n.inEdges=e.filter(function(a){return"".concat(t.target(a))==="".concat(i)}),n.outEdges=e.filter(function(a){return"".concat(t.source(a))==="".concat(i)}),n.edges=n.outEdges.concat(n.inEdges),n.frequency=n.edges.length,n.value=0,n.inEdges.forEach(function(a){n.value+=t.targetWeight(a)}),n.outEdges.forEach(function(a){n.value+=t.sourceWeight(a)})})}function vP(r,e){var t={weight:function(i,a){return a.value-i.value},frequency:function(i,a){return a.frequency-i.frequency},id:function(i,a){return"".concat(e.id(i)).localeCompare("".concat(e.id(a)))}},n=t[e.sortBy];!n&&(0,f.mf)(e.sortBy)&&(n=e.sortBy),n&&r.sort(n)}function dP(r,e){var t=r.length;if(!t)throw new TypeError("Invalid nodes: it's empty!");if(e.weight){var n=e.nodePaddingRatio;if(n<0||n>=1)throw new TypeError("Invalid nodePaddingRatio: it must be in range [0, 1)!");var i=n/(2*t),a=e.nodeWidthRatio;if(a<=0||a>=1)throw new TypeError("Invalid nodeWidthRatio: it must be in range (0, 1)!");var o=0;r.forEach(function(l){o+=l.value}),r.forEach(function(l){l.weight=l.value/o,l.width=l.weight*(1-n),l.height=a}),r.forEach(function(l,u){for(var c=0,h=u-1;h>=0;h--)c+=r[h].width+2*i;var v=l.minX=i+c,d=l.maxX=l.minX+l.width,g=l.minY=e.y-a/2,y=l.maxY=g+a;l.x=[v,d,d,v],l.y=[g,g,y,y]})}else{var s=1/t;r.forEach(function(l,u){l.x=(u+.5)*s,l.y=e.y})}return r}function pP(r,e,t){if(t.weight){var n={};(0,f.U5)(r,function(i,a){n[a]=i.value}),e.forEach(function(i){var a=t.source(i),o=t.target(i),s=r[a],l=r[o];if(s&&l){var u=n[a],c=t.sourceWeight(i),h=s.minX+(s.value-u)/s.value*s.width,v=h+c/s.value*s.width;n[a]-=c;var d=n[o],g=t.targetWeight(i),y=l.minX+(l.value-d)/l.value*l.width,x=y+g/l.value*l.width;n[o]-=g;var m=t.y;i.x=[h,v,y,x],i.y=[m,m,m,m],i.source=s,i.target=l}})}else e.forEach(function(i){var a=r[t.source(i)],o=r[t.target(i)];a&&o&&(i.x=[a.x,o.x],i.y=[a.y,o.y],i.source=a,i.target=o)});return e}function gP(r){return(0,f.f0)({},fP,r)}function yP(r,e){var t=gP(r),n={},i=e.nodes,a=e.links;i.forEach(function(l){var u=t.id(l);n[u]=l}),hP(n,a,t),vP(i,t);var o=dP(i,t),s=pP(n,a,t);return{nodes:o,links:s}}var o0="x",s0="y",l0="name",u0="source",mP={nodeStyle:{opacity:1,fillOpacity:1,lineWidth:1},edgeStyle:{opacity:.5,lineWidth:2},label:{fields:["x","name"],callback:function(r,e){var t=(r[0]+r[1])/2,n=t>.5?-4:4;return{offsetX:n,content:e}},labelEmit:!0,style:{fill:"#8c8c8c"}},tooltip:{showTitle:!1,showMarkers:!1,fields:["source","target","value","isNode"],showContent:function(r){return!(0,f.U2)(r,[0,"data","isNode"])},formatter:function(r){var e=r.source,t=r.target,n=r.value;return{name:"".concat(e," -> ").concat(t),value:n}}},interactions:[{type:"element-active"}],weight:!0,nodePaddingRatio:.1,nodeWidthRatio:.05};function xP(r){var e=r.options,t=e.data,n=e.sourceField,i=e.targetField,a=e.weightField,o=e.nodePaddingRatio,s=e.nodeWidthRatio,l=e.rawFields,u=l===void 0?[]:l,c=Vp(t,n,i,a),h=yP({weight:!0,nodePaddingRatio:o,nodeWidthRatio:s},c),v=h.nodes,d=h.links,g=v.map(function(x){return(0,p.pi)((0,p.pi)({},Qe(x,(0,p.ev)(["id","x","y","name"],u,!0))),{isNode:!0})}),y=d.map(function(x){return(0,p.pi)((0,p.pi)({source:x.source.name,target:x.target.name,name:x.source.name||x.target.name},Qe(x,(0,p.ev)(["x","y","value"],u,!0))),{isNode:!1})});return(0,p.pi)((0,p.pi)({},r),{ext:(0,p.pi)((0,p.pi)({},r.ext),{chordData:{nodesData:g,edgesData:y}})})}function MP(r){var e,t=r.chart;return t.scale((e={x:{sync:!0,nice:!0},y:{sync:!0,nice:!0,max:1}},e[l0]={sync:"color"},e[u0]={sync:"color"},e)),r}function wP(r){var e=r.chart;return e.axis(!1),r}function SP(r){var e=r.chart;return e.legend(!1),r}function CP(r){var e=r.chart,t=r.options,n=t.tooltip;return e.tooltip(n),r}function AP(r){var e=r.chart;return e.coordinate("polar").reflect("y"),r}function bP(r){var e=r.chart,t=r.options,n=r.ext.chordData.nodesData,i=t.nodeStyle,a=t.label,o=t.tooltip,s=e.createView();return s.data(n),el({chart:s,options:{xField:o0,yField:s0,seriesField:l0,polygon:{style:i},label:a,tooltip:o}}),r}function TP(r){var e=r.chart,t=r.options,n=r.ext.chordData.edgesData,i=t.edgeStyle,a=t.tooltip,o=e.createView();o.data(n);var s={xField:o0,yField:s0,seriesField:u0,edge:{style:i,shape:"arc"},tooltip:a};return eg({chart:o,options:s}),r}function EP(r){var e=r.chart,t=r.options,n=t.animation;return mo(e,n,HE(e)),r}function _P(r){return Fe(We,xP,AP,MP,wP,SP,CP,TP,bP,or,hi,EP)(r)}var M5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="chord",t}return e.getDefaultOptions=function(){return mP},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return _P},e}(Re),FP=["x","y","r","name","value","path","depth"],IP={colorField:"name",autoFit:!0,pointStyle:{lineWidth:0,stroke:"#fff"},legend:!1,hierarchyConfig:{size:[1,1],padding:0},label:{fields:["name"],layout:{type:"limit-in-shape"}},tooltip:{showMarkers:!1,showTitle:!1},drilldown:{enabled:!1}},c0=4,PP=0,f0=5,h0="drilldown-bread-crumb",LP={position:"top-left",dividerText:"/",textStyle:{fontSize:12,fill:"rgba(0, 0, 0, 0.65)",cursor:"pointer"},activeTextStyle:{fill:"#87B5FF"}},To="hierarchy-data-transform-params",DP=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.name="drill-down",t.historyCache=[],t.breadCrumbGroup=null,t.breadCrumbCfg=LP,t}return e.prototype.click=function(){var t=(0,f.U2)(this.context,["event","data","data"]);if(!t)return!1;this.drill(t),this.drawBreadCrumb()},e.prototype.resetPosition=function(){if(!!this.breadCrumbGroup){var t=this.context.view.getCoordinate(),n=this.breadCrumbGroup,i=n.getBBox(),a=this.getButtonCfg().position,o={x:t.start.x,y:t.end.y-(i.height+f0*2)};t.isPolar&&(o={x:0,y:0}),a==="bottom-left"&&(o={x:t.start.x,y:t.start.y});var s=zr.transform(null,[["t",o.x+PP,o.y+i.height+f0]]);n.setMatrix(s)}},e.prototype.back=function(){(0,f.dp)(this.historyCache)&&this.backTo(this.historyCache.slice(0,-1))},e.prototype.reset=function(){this.historyCache[0]&&this.backTo(this.historyCache.slice(0,1)),this.historyCache=[],this.hideCrumbGroup()},e.prototype.drill=function(t){var n=this.context.view,i=(0,f.U2)(n,["interactions","drill-down","cfg","transformData"],function(u){return u}),a=i((0,p.pi)({data:t.data},t[To]));n.changeData(a);for(var o=[],s=t;s;){var l=s.data;o.unshift({id:"".concat(l.name,"_").concat(s.height,"_").concat(s.depth),name:l.name,children:i((0,p.pi)({data:l},t[To]))}),s=s.parent}this.historyCache=(this.historyCache||[]).slice(0,-1).concat(o)},e.prototype.backTo=function(t){if(!(!t||t.length<=0)){var n=this.context.view,i=(0,f.Z$)(t).children;n.changeData(i),t.length>1?(this.historyCache=t,this.drawBreadCrumb()):(this.historyCache=[],this.hideCrumbGroup())}},e.prototype.getButtonCfg=function(){var t=this.context.view,n=(0,f.U2)(t,["interactions","drill-down","cfg","drillDownConfig"]);return kt(this.breadCrumbCfg,n==null?void 0:n.breadCrumb,this.cfg)},e.prototype.drawBreadCrumb=function(){this.drawBreadCrumbGroup(),this.resetPosition(),this.breadCrumbGroup.show()},e.prototype.drawBreadCrumbGroup=function(){var t=this,n=this.getButtonCfg(),i=this.historyCache;this.breadCrumbGroup?this.breadCrumbGroup.clear():this.breadCrumbGroup=this.context.view.foregroundGroup.addGroup({name:h0});var a=0;i.forEach(function(o,s){var l=t.breadCrumbGroup.addShape({type:"text",id:o.id,name:"".concat(h0,"_").concat(o.name,"_text"),attrs:(0,p.pi)((0,p.pi)({text:s===0&&!(0,f.UM)(n.rootText)?n.rootText:o.name},n.textStyle),{x:a,y:0})}),u=l.getBBox();if(a+=u.width+c0,l.on("click",function(v){var d,g=v.target.get("id");if(g!==((d=(0,f.Z$)(i))===null||d===void 0?void 0:d.id)){var y=i.slice(0,i.findIndex(function(x){return x.id===g})+1);t.backTo(y)}}),l.on("mouseenter",function(v){var d,g=v.target.get("id");g!==((d=(0,f.Z$)(i))===null||d===void 0?void 0:d.id)?l.attr(n.activeTextStyle):l.attr({cursor:"default"})}),l.on("mouseleave",function(){l.attr(n.textStyle)}),s<i.length-1){var c=t.breadCrumbGroup.addShape({type:"text",name:"".concat(n.name,"_").concat(o.name,"_divider"),attrs:(0,p.pi)((0,p.pi)({text:n.dividerText},n.textStyle),{x:a,y:0})}),h=c.getBBox();a+=h.width+c0}})},e.prototype.hideCrumbGroup=function(){this.breadCrumbGroup&&this.breadCrumbGroup.hide()},e.prototype.destroy=function(){this.breadCrumbGroup&&this.breadCrumbGroup.remove(),r.prototype.destroy.call(this)},e}(ar);function OP(r){return typeof r=="object"&&"length"in r?r:Array.from(r)}function kP(r){for(var e=r.length,t,n;e;)n=Math.random()*e--|0,t=r[e],r[e]=r[n],r[n]=t;return r}function v0(r){for(var e=0,t=(r=kP(Array.from(r))).length,n=[],i,a;e<t;)i=r[e],a&&d0(a,i)?++e:(a=RP(n=BP(n,i)),e=0);return a}function BP(r,e){var t,n;if(Jc(e,r))return[e];for(t=0;t<r.length;++t)if(cl(e,r[t])&&Jc(Eo(r[t],e),r))return[r[t],e];for(t=0;t<r.length-1;++t)for(n=t+1;n<r.length;++n)if(cl(Eo(r[t],r[n]),e)&&cl(Eo(r[t],e),r[n])&&cl(Eo(r[n],e),r[t])&&Jc(p0(r[t],r[n],e),r))return[r[t],r[n],e];throw new Error}function cl(r,e){var t=r.r-e.r,n=e.x-r.x,i=e.y-r.y;return t<0||t*t<n*n+i*i}function d0(r,e){var t=r.r-e.r+Math.max(r.r,e.r,1)*1e-9,n=e.x-r.x,i=e.y-r.y;return t>0&&t*t>n*n+i*i}function Jc(r,e){for(var t=0;t<e.length;++t)if(!d0(r,e[t]))return!1;return!0}function RP(r){switch(r.length){case 1:return NP(r[0]);case 2:return Eo(r[0],r[1]);case 3:return p0(r[0],r[1],r[2])}}function NP(r){return{x:r.x,y:r.y,r:r.r}}function Eo(r,e){var t=r.x,n=r.y,i=r.r,a=e.x,o=e.y,s=e.r,l=a-t,u=o-n,c=s-i,h=Math.sqrt(l*l+u*u);return{x:(t+a+l/h*c)/2,y:(n+o+u/h*c)/2,r:(h+i+s)/2}}function p0(r,e,t){var n=r.x,i=r.y,a=r.r,o=e.x,s=e.y,l=e.r,u=t.x,c=t.y,h=t.r,v=n-o,d=n-u,g=i-s,y=i-c,x=l-a,m=h-a,M=n*n+i*i-a*a,w=M-o*o-s*s+l*l,S=M-u*u-c*c+h*h,b=d*g-v*y,k=(g*S-y*w)/(b*2)-n,H=(y*x-g*m)/b,at=(d*w-v*S)/(b*2)-i,At=(v*m-d*x)/b,gt=H*H+At*At-1,Nt=2*(a+k*H+at*At),te=k*k+at*at-a*a,ce=-(gt?(Nt+Math.sqrt(Nt*Nt-4*gt*te))/(2*gt):te/Nt);return{x:n+k+H*ce,y:i+at+At*ce,r:ce}}function g0(r,e,t){var n=r.x-e.x,i,a,o=r.y-e.y,s,l,u=n*n+o*o;u?(a=e.r+t.r,a*=a,l=r.r+t.r,l*=l,a>l?(i=(u+l-a)/(2*u),s=Math.sqrt(Math.max(0,l/u-i*i)),t.x=r.x-i*n-s*o,t.y=r.y-i*o+s*n):(i=(u+a-l)/(2*u),s=Math.sqrt(Math.max(0,a/u-i*i)),t.x=e.x+i*n-s*o,t.y=e.y+i*o+s*n)):(t.x=e.x+t.r,t.y=e.y)}function y0(r,e){var t=r.r+e.r-1e-6,n=e.x-r.x,i=e.y-r.y;return t>0&&t*t>n*n+i*i}function m0(r){var e=r._,t=r.next._,n=e.r+t.r,i=(e.x*t.r+t.x*e.r)/n,a=(e.y*t.r+t.y*e.r)/n;return i*i+a*a}function fl(r){this._=r,this.next=null,this.previous=null}function x0(r){if(!(i=(r=OP(r)).length))return 0;var e,t,n,i,a,o,s,l,u,c,h;if(e=r[0],e.x=0,e.y=0,!(i>1))return e.r;if(t=r[1],e.x=-t.r,t.x=e.r,t.y=0,!(i>2))return e.r+t.r;g0(t,e,n=r[2]),e=new fl(e),t=new fl(t),n=new fl(n),e.next=n.previous=t,t.next=e.previous=n,n.next=t.previous=e;t:for(s=3;s<i;++s){g0(e._,t._,n=r[s]),n=new fl(n),l=t.next,u=e.previous,c=t._.r,h=e._.r;do if(c<=h){if(y0(l._,n._)){t=l,e.next=t,t.previous=e,--s;continue t}c+=l._.r,l=l.next}else{if(y0(u._,n._)){e=u,e.next=t,t.previous=e,--s;continue t}h+=u._.r,u=u.previous}while(l!==u.next);for(n.previous=e,n.next=t,e.next=t.previous=t=n,a=m0(e);(n=n.next)!==t;)(o=m0(n))<a&&(e=n,a=o);t=e.next}for(e=[t._],n=t;(n=n.next)!==t;)e.push(n._);for(n=v0(e),s=0;s<i;++s)e=r[s],e.x-=n.x,e.y-=n.y;return n.r}function UP(r){return x0(r),r}function zP(r){return r==null?null:hl(r)}function hl(r){if(typeof r!="function")throw new Error;return r}function Hi(){return 0}function Sa(r){return function(){return r}}function VP(r){return Math.sqrt(r.value)}function M0(){var r=null,e=1,t=1,n=Hi;function i(a){return a.x=e/2,a.y=t/2,r?a.eachBefore(w0(r)).eachAfter(Qc(n,.5)).eachBefore(S0(1)):a.eachBefore(w0(VP)).eachAfter(Qc(Hi,1)).eachAfter(Qc(n,a.r/Math.min(e,t))).eachBefore(S0(Math.min(e,t)/(2*a.r))),a}return i.radius=function(a){return arguments.length?(r=zP(a),i):r},i.size=function(a){return arguments.length?(e=+a[0],t=+a[1],i):[e,t]},i.padding=function(a){return arguments.length?(n=typeof a=="function"?a:Sa(+a),i):n},i}function w0(r){return function(e){e.children||(e.r=Math.max(0,+r(e)||0))}}function Qc(r,e){return function(t){if(n=t.children){var n,i,a=n.length,o=r(t)*e||0,s;if(o)for(i=0;i<a;++i)n[i].r+=o;if(s=x0(n),o)for(i=0;i<a;++i)n[i].r-=o;t.r=s+o}}}function S0(r){return function(e){var t=e.parent;e.r*=r,t&&(e.x=t.x+r*e.x,e.y=t.y+r*e.y)}}var HP=N(32059);function GP(r){var e=0,t=r.children,n=t&&t.length;if(!n)e=1;else for(;--n>=0;)e+=t[n].value;r.value=e}function YP(){return this.eachAfter(GP)}var XP=N(64254);function C0(r,e){var t=typeof Symbol!="undefined"&&r[Symbol.iterator]||r["@@iterator"];if(!t){if(Array.isArray(r)||(t=(0,XP.Z)(r))||e&&r&&typeof r.length=="number"){t&&(r=t);var n=0,i=function(){};return{s:i,n:function(){return n>=r.length?{done:!0}:{done:!1,value:r[n++]}},e:function(u){throw u},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
  64. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){t=t.call(r)},n:function(){var u=t.next();return a=u.done,u},e:function(u){o=!0,s=u},f:function(){try{!a&&t.return!=null&&t.return()}finally{if(o)throw s}}}}function WP(r,e){var t=-1,n=C0(this),i;try{for(n.s();!(i=n.n()).done;){var a=i.value;r.call(e,a,++t,this)}}catch(o){n.e(o)}finally{n.f()}return this}function ZP(r,e){for(var t=this,n=[t],i,a,o=-1;t=n.pop();)if(r.call(e,t,++o,this),i=t.children)for(a=i.length-1;a>=0;--a)n.push(i[a]);return this}function $P(r,e){for(var t=this,n=[t],i=[],a,o,s,l=-1;t=n.pop();)if(i.push(t),a=t.children)for(o=0,s=a.length;o<s;++o)n.push(a[o]);for(;t=i.pop();)r.call(e,t,++l,this);return this}function qP(r,e){var t=-1,n=C0(this),i;try{for(n.s();!(i=n.n()).done;){var a=i.value;if(r.call(e,a,++t,this))return a}}catch(o){n.e(o)}finally{n.f()}}function KP(r){return this.eachAfter(function(e){for(var t=+r(e.data)||0,n=e.children,i=n&&n.length;--i>=0;)t+=n[i].value;e.value=t})}function jP(r){return this.eachBefore(function(e){e.children&&e.children.sort(r)})}function JP(r){for(var e=this,t=QP(e,r),n=[e];e!==t;)e=e.parent,n.push(e);for(var i=n.length;r!==t;)n.splice(i,0,r),r=r.parent;return n}function QP(r,e){if(r===e)return r;var t=r.ancestors(),n=e.ancestors(),i=null;for(r=t.pop(),e=n.pop();r===e;)i=r,r=t.pop(),e=n.pop();return i}function tL(){for(var r=this,e=[r];r=r.parent;)e.push(r);return e}function eL(){return Array.from(this)}function rL(){var r=[];return this.eachBefore(function(e){e.children||r.push(e)}),r}function nL(){var r=this,e=[];return r.each(function(t){t!==r&&e.push({source:t.parent,target:t})}),e}var A0=N(39428),iL=(0,A0.Z)().mark(b0);function b0(){var r,e,t,n,i,a;return(0,A0.Z)().wrap(function(s){for(;;)switch(s.prev=s.next){case 0:r=this,t=[r];case 1:e=t.reverse(),t=[];case 2:if(!(r=e.pop())){s.next=8;break}return s.next=5,r;case 5:if(n=r.children)for(i=0,a=n.length;i<a;++i)t.push(n[i]);s.next=2;break;case 8:if(t.length){s.next=1;break}case 9:case"end":return s.stop()}},iL,this)}function Ca(r,e){r instanceof Map?(r=[void 0,r],e===void 0&&(e=sL)):e===void 0&&(e=oL);for(var t=new Aa(r),n,i=[t],a,o,s,l;n=i.pop();)if((o=e(n.data))&&(l=(o=Array.from(o)).length))for(n.children=o,s=l-1;s>=0;--s)i.push(a=o[s]=new Aa(o[s])),a.parent=n,a.depth=n.depth+1;return t.eachBefore(T0)}function aL(){return Ca(this).eachBefore(lL)}function oL(r){return r.children}function sL(r){return Array.isArray(r)?r[1]:null}function lL(r){r.data.value!==void 0&&(r.value=r.data.value),r.data=r.data.data}function T0(r){var e=0;do r.height=e;while((r=r.parent)&&r.height<++e)}function Aa(r){this.data=r,this.depth=this.height=0,this.parent=null}Aa.prototype=Ca.prototype=(0,HP.Z)({constructor:Aa,count:YP,each:WP,eachAfter:$P,eachBefore:ZP,find:qP,sum:KP,sort:jP,path:JP,ancestors:tL,descendants:eL,leaves:rL,links:nL,copy:aL},Symbol.iterator,b0);var E0="nodeIndex",_0="childNodeCount",tf="nodeAncestor",ef="Invalid field: it must be a string!";function rf(r,e){var t=r.field,n=r.fields;if((0,f.HD)(t))return t;if((0,f.kJ)(t))return console.warn(ef),t[0];if(console.warn("".concat(ef," will try to get fields instead.")),(0,f.HD)(n))return n;if((0,f.kJ)(n)&&n.length)return n[0];if(e)return e;throw new TypeError(ef)}function nf(r){var e=[];if(r&&r.each){var t,n;r.each(function(i){var a,o;i.parent!==t?(t=i.parent,n=0):n+=1;var s=(0,f.hX)((((a=i.ancestors)===null||a===void 0?void 0:a.call(i))||[]).map(function(l){return e.find(function(u){return u.name===l.name})||l}),function(l){var u=l.depth;return u>0&&u<i.depth});i[tf]=s,i[_0]=((o=i.children)===null||o===void 0?void 0:o.length)||0,i[E0]=n,e.push(i)})}else r&&r.eachNode&&r.eachNode(function(i){e.push(i)});return e}var uL={field:"value",as:["x","y","r"],sort:function(r,e){return e.value-r.value}};function cL(r,e){e=(0,f.f0)({},uL,e);var t=e.as;if(!(0,f.kJ)(t)||t.length!==3)throw new TypeError('Invalid as: it must be an array with 3 strings (e.g. [ "x", "y", "r" ])!');var n;try{n=rf(e)}catch(u){console.warn(u)}var i=function(u){return M0().size(e.size).padding(e.padding)(Ca(u).sum(function(c){return c[n]}).sort(e.sort))},a=i(r),o=t[0],s=t[1],l=t[2];return a.each(function(u){u[o]=u.x,u[s]=u.y,u[l]=u.r}),nf(a)}function F0(r){var e=r.data,t=r.hierarchyConfig,n=r.rawFields,i=n===void 0?[]:n,a=r.enableDrillDown,o=cL(e,(0,p.pi)((0,p.pi)({},t),{field:"value",as:["x","y","r"]})),s=[];return o.forEach(function(l){for(var u,c=l.data.name,h=(0,p.pi)({},l);h.depth>1;)c="".concat((u=h.parent.data)===null||u===void 0?void 0:u.name," / ").concat(c),h=h.parent;if(a&&l.depth>2)return null;var v=kt({},l.data,(0,p.pi)((0,p.pi)((0,p.pi)({},Qe(l.data,i)),{path:c}),l));v.ext=t,v[To]={hierarchyConfig:t,rawFields:i,enableDrillDown:a},s.push(v)}),s}function I0(r,e,t){var n=Oc([r,e]),i=n[0],a=n[1],o=n[2],s=n[3],l=t.width,u=t.height,c=l-(s+a),h=u-(i+o),v=Math.min(c,h),d=(c-v)/2,g=(h-v)/2,y=i+g,x=a+d,m=o+g,M=s+d,w=[y,x,m,M],S=v<0?0:v;return{finalPadding:w,finalSize:S}}function fL(r){var e=r.chart,t=Math.min(e.viewBBox.width,e.viewBBox.height);return kt({options:{size:function(n){var i=n.r;return i*t}}},r)}function hL(r){var e=r.options,t=r.chart,n=t.viewBBox,i=e.padding,a=e.appendPadding,o=e.drilldown,s=a;if(o==null?void 0:o.enabled){var l=$s(t.appendPadding,(0,f.U2)(o,["breadCrumb","position"]));s=Oc([l,a])}var u=I0(i,s,n).finalPadding;return t.padding=u,t.appendPadding=0,r}function vL(r){var e=r.chart,t=r.options,n=e.padding,i=e.appendPadding,a=t.color,o=t.colorField,s=t.pointStyle,l=t.hierarchyConfig,u=t.sizeField,c=t.rawFields,h=c===void 0?[]:c,v=t.drilldown,d=F0({data:t.data,hierarchyConfig:l,enableDrillDown:v==null?void 0:v.enabled,rawFields:h});e.data(d);var g=e.viewBBox,y=I0(n,i,g).finalSize,x=function(m){var M=m.r;return M*y};return u&&(x=function(m){return m[u]*y}),jr(kt({},r,{options:{xField:"x",yField:"y",seriesField:o,sizeField:u,rawFields:(0,p.ev)((0,p.ev)([],FP,!0),h,!0),point:{color:a,style:s,shape:"circle",size:x}}})),r}function dL(r){return Fe(ur({},{x:{min:0,max:1,minLimit:0,maxLimit:1,nice:!0},y:{min:0,max:1,minLimit:0,maxLimit:1,nice:!0}}))(r)}function pL(r){var e=r.chart,t=r.options,n=t.tooltip;if(n===!1)e.tooltip(!1);else{var i=n;(0,f.U2)(n,"fields")||(i=kt({},{customItems:function(a){return a.map(function(o){var s=(0,f.U2)(e.getOptions(),"scales"),l=(0,f.U2)(s,["name","formatter"],function(c){return c}),u=(0,f.U2)(s,["value","formatter"],function(c){return c});return(0,p.pi)((0,p.pi)({},o),{name:l(o.data.name),value:u(o.data.value)})})}},i)),e.tooltip(i)}return r}function gL(r){var e=r.chart;return e.axis(!1),r}function yL(r){var e=r.drilldown,t=r.interactions,n=t===void 0?[]:t;return(e==null?void 0:e.enabled)?kt({},r,{interactions:(0,p.ev)((0,p.ev)([],n,!0),[{type:"drill-down",cfg:{drillDownConfig:e,transformData:F0,enableDrillDown:!0}}],!1)}):r}function mL(r){var e=r.chart,t=r.options;return or({chart:e,options:yL(t)}),r}function xL(r){return Fe(Kr("pointStyle"),fL,hL,We,dL,vL,gL,ki,pL,mL,tr,sr())(r)}function P0(r){var e=(0,f.U2)(r,["event","data","data"],{});return(0,f.kJ)(e.children)&&e.children.length>0}function L0(r){var e=r.view.getCoordinate(),t=e.innerRadius;if(t){var n=r.event,i=n.x,a=n.y,o=e.center,s=o.x,l=o.y,u=e.getRadius()*t,c=Math.sqrt(Math.pow(s-i,2)+Math.pow(l-a,2));return c<u}return!1}Te("drill-down-action",DP),De("drill-down",{showEnable:[{trigger:"element:mouseenter",action:"cursor:pointer",isEnable:P0},{trigger:"element:mouseleave",action:"cursor:default"},{trigger:"element:mouseleave",action:"cursor:pointer",isEnable:L0}],start:[{trigger:"element:click",isEnable:P0,action:["drill-down-action:click"]},{trigger:"afterchangesize",action:["drill-down-action:resetPosition"]},{trigger:"click",isEnable:L0,action:["drill-down-action:back"]}]});var w5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="circle-packing",t}return e.getDefaultOptions=function(){return IP},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return xL},e.prototype.triggerResize=function(){this.chart.destroyed||(this.chart.forceFit(),this.chart.clear(),this.execAdaptor(),this.chart.render(!0))},e}(Re),Jr="left-axes-view",Qr="right-axes-view",D0={nice:!0,label:{autoHide:!0,autoRotate:!1}},ML=(0,p.pi)((0,p.pi)({},D0),{position:"left"}),wL=(0,p.pi)((0,p.pi)({},D0),{position:"right",grid:null}),ba;(function(r){r.Left="Left",r.Right="Right"})(ba||(ba={}));var Gi;(function(r){r.Line="line",r.Column="column"})(Gi||(Gi={}));function af(r){return(0,f.U2)(r,"geometry")===Gi.Line}function of(r){return(0,f.U2)(r,"geometry")===Gi.Column}function O0(r,e,t){return of(t)?kt({},{geometry:Gi.Column,label:t.label&&t.isRange?{content:function(n){var i;return(i=n[e])===null||i===void 0?void 0:i.join("-")}}:void 0},t):(0,p.pi)({geometry:Gi.Line},t)}function k0(r,e){var t=r[0],n=r[1];if((0,f.kJ)(e)){var i=e[0],a=e[1];return[i,a]}var o=(0,f.U2)(e,t),s=(0,f.U2)(e,n);return[o,s]}function B0(r,e){return e===ba.Left?r===!1?!1:kt({},ML,r):e===ba.Right?r===!1?!1:kt({},wL,r):r}function SL(r){var e=r.options,t=r.chart,n=e.geometryOption,i=n.isStack,a=n.color,o=n.seriesField,s=n.groupField,l=n.isGroup,u=["xField","yField"];if(af(n)){ya(kt({},r,{options:(0,p.pi)((0,p.pi)((0,p.pi)({},Qe(e,u)),n),{line:{color:n.color,style:n.lineStyle}})})),jr(kt({},r,{options:(0,p.pi)((0,p.pi)((0,p.pi)({},Qe(e,u)),n),{point:n.point&&(0,p.pi)({color:a,shape:"circle"},n.point)})}));var c=[];l&&c.push({type:"dodge",dodgeBy:s||o,customOffset:0}),i&&c.push({type:"stack"}),c.length&&(0,f.S6)(t.geometries,function(h){h.adjust(c)})}return of(n)&&il(kt({},r,{options:(0,p.pi)((0,p.pi)((0,p.pi)({},Qe(e,u)),n),{widthRatio:n.columnWidthRatio,interval:(0,p.pi)((0,p.pi)({},Qe(n,["color"])),{style:n.columnStyle})})})),r}function R0(r){var e=r.view,t=r.geometryOption,n=r.yField,i=r.legend,a=(0,f.U2)(i,"marker"),o=br(e,af(t)?"line":"interval");if(!t.seriesField){var s=(0,f.U2)(e,"options.scales.".concat(n,".alias"))||n,l=o.getAttribute("color"),u=e.getTheme().defaultColor;l&&(u=zr.getMappingValue(l,s,(0,f.U2)(l,["values",0],u)));var c=((0,f.mf)(a)?a:!(0,f.xb)(a)&&kt({},{style:{stroke:u,fill:u}},a))||(af(t)?{symbol:function(v,d,g){return[["M",v-g,d],["L",v+g,d]]},style:{lineWidth:2,r:6,stroke:u}}:{symbol:"square",style:{fill:u}});return[{value:n,name:s,marker:c,isGeometry:!0,viewId:e.id}]}var h=o.getGroupAttributes();return(0,f.u4)(h,function(v,d){var g=zr.getLegendItems(e,o,d,e.getTheme(),a);return v.concat(g)},[])}var N0=function(r,e){var t=e[0],n=e[1],i=r.getOptions().data,a=r.getXScale(),o=(0,f.dp)(i);if(!(!a||!o)){var s=!0,l=(0,f.I)(i,a.field),u=s?l:l.reverse(),c=(0,f.dp)(u),h=Math.floor(t*(c-1)),v=Math.floor(n*(c-1));r.filter(a.field,function(d){var g=u.indexOf(d);return g>-1?YE(g,h,v):!0}),r.getRootView().render(!0)}};function CL(r){var e,t=r.options,n=t.geometryOptions,i=n===void 0?[]:n,a=t.xField,o=t.yField,s=(0,f.yW)(i,function(l){var u=l.geometry;return u===Gi.Line||u===void 0});return kt({},{options:{geometryOptions:[],meta:(e={},e[a]={type:"cat",sync:!0,range:s?[0,1]:void 0},e),tooltip:{showMarkers:s,showCrosshairs:s,shared:!0,crosshairs:{type:"x"}},interactions:s?[{type:"legend-visible-filter"}]:[{type:"legend-visible-filter"},{type:"active-region"}],legend:{position:"top-left"}}},r,{options:{yAxis:k0(o,t.yAxis),geometryOptions:[O0(a,o[0],i[0]),O0(a,o[1],i[1])],annotations:k0(o,t.annotations)}})}function AL(r){var e,t,n=r.chart,i=r.options,a=i.geometryOptions,o={line:0,column:1},s=[{type:(e=a[0])===null||e===void 0?void 0:e.geometry,id:Jr},{type:(t=a[1])===null||t===void 0?void 0:t.geometry,id:Qr}];return s.sort(function(l,u){return-o[l.type]+o[u.type]}).forEach(function(l){return n.createView({id:l.id})}),r}function bL(r){var e=r.chart,t=r.options,n=t.xField,i=t.yField,a=t.geometryOptions,o=t.data,s=t.tooltip,l=[(0,p.pi)((0,p.pi)({},a[0]),{id:Jr,data:o[0],yField:i[0]}),(0,p.pi)((0,p.pi)({},a[1]),{id:Qr,data:o[1],yField:i[1]})];return l.forEach(function(u){var c=u.id,h=u.data,v=u.yField,d=of(u)&&u.isPercent,g=d?ig(h,v,n,v):h,y=Ve(e,c).data(g),x=d?(0,p.pi)({formatter:function(m){return{name:m[u.seriesField]||v,value:(Number(m[v])*100).toFixed(2)+"%"}}},s):s;SL({chart:y,options:{xField:n,yField:v,tooltip:x,geometryOption:u}})}),r}function TL(r){var e,t=r.chart,n=r.options,i=n.geometryOptions,a=((e=t.getTheme())===null||e===void 0?void 0:e.colors10)||[],o=0;return t.once("beforepaint",function(){(0,f.S6)(i,function(s,l){var u=Ve(t,l===0?Jr:Qr);if(!s.color){var c=u.getGroupScales(),h=(0,f.U2)(c,[0,"values","length"],1),v=a.slice(o,o+h).concat(l===0?[]:a);u.geometries.forEach(function(d){s.seriesField?d.color(s.seriesField,v):d.color(v[0])}),o+=h}}),t.render(!0)}),r}function EL(r){var e,t,n=r.chart,i=r.options,a=i.xAxis,o=i.yAxis,s=i.xField,l=i.yField;return ur((e={},e[s]=a,e[l[0]]=o[0],e))(kt({},r,{chart:Ve(n,Jr)})),ur((t={},t[s]=a,t[l[1]]=o[1],t))(kt({},r,{chart:Ve(n,Qr)})),r}function _L(r){var e=r.chart,t=r.options,n=Ve(e,Jr),i=Ve(e,Qr),a=t.xField,o=t.yField,s=t.xAxis,l=t.yAxis;return e.axis(a,!1),e.axis(o[0],!1),e.axis(o[1],!1),n.axis(a,s),n.axis(o[0],B0(l[0],ba.Left)),i.axis(a,!1),i.axis(o[1],B0(l[1],ba.Right)),r}function FL(r){var e=r.chart,t=r.options,n=t.tooltip,i=Ve(e,Jr),a=Ve(e,Qr);return e.tooltip(n),i.tooltip({shared:!0}),a.tooltip({shared:!0}),r}function IL(r){var e=r.chart;return or(kt({},r,{chart:Ve(e,Jr)})),or(kt({},r,{chart:Ve(e,Qr)})),r}function PL(r){var e=r.chart,t=r.options,n=t.annotations,i=(0,f.U2)(n,[0]),a=(0,f.U2)(n,[1]);return sr(i)(kt({},r,{chart:Ve(e,Jr),options:{annotations:i}})),sr(a)(kt({},r,{chart:Ve(e,Qr),options:{annotations:a}})),r}function LL(r){var e=r.chart;return We(kt({},r,{chart:Ve(e,Jr)})),We(kt({},r,{chart:Ve(e,Qr)})),We(r),r}function DL(r){var e=r.chart;return tr(kt({},r,{chart:Ve(e,Jr)})),tr(kt({},r,{chart:Ve(e,Qr)})),r}function OL(r){var e=r.chart,t=r.options,n=t.yAxis;return Bi(kt({},r,{chart:Ve(e,Jr),options:{yAxis:n[0]}})),Bi(kt({},r,{chart:Ve(e,Qr),options:{yAxis:n[1]}})),r}function kL(r){var e=r.chart,t=r.options,n=t.legend,i=t.geometryOptions,a=t.yField,o=t.data,s=Ve(e,Jr),l=Ve(e,Qr);if(n===!1)e.legend(!1);else if((0,f.Kn)(n)&&n.custom===!0)e.legend(n);else{var u=(0,f.U2)(i,[0,"legend"],n),c=(0,f.U2)(i,[1,"legend"],n);e.once("beforepaint",function(){var h=o[0].length?R0({view:s,geometryOption:i[0],yField:a[0],legend:u}):[],v=o[1].length?R0({view:l,geometryOption:i[1],yField:a[1],legend:c}):[];e.legend(kt({},n,{custom:!0,items:h.concat(v)}))}),i[0].seriesField&&s.legend(i[0].seriesField,u),i[1].seriesField&&l.legend(i[1].seriesField,c),e.on("legend-item:click",function(h){var v=(0,f.U2)(h,"gEvent.delegateObject",{});if(v&&v.item){var d=v.item,g=d.value,y=d.isGeometry,x=d.viewId;if(y){var m=(0,f.cx)(a,function(S){return S===g});if(m>-1){var M=(0,f.U2)(Ve(e,x),"geometries");(0,f.S6)(M,function(S){S.changeVisible(!v.item.unchecked)})}}else{var w=(0,f.U2)(e.getController("legend"),"option.items",[]);(0,f.S6)(e.views,function(S){var b=S.getGroupScales();(0,f.S6)(b,function(k){k.values&&k.values.indexOf(g)>-1&&S.filter(k.field,function(H){var at=(0,f.sE)(w,function(At){return At.value===H});return!at.unchecked})}),e.render(!0)})}}})}return r}function BL(r){var e=r.chart,t=r.options,n=t.slider,i=Ve(e,Jr),a=Ve(e,Qr);return n&&(i.option("slider",n),i.on("slider:valuechanged",function(o){var s=o.event,l=s.value,u=s.originValue;(0,f.Xy)(l,u)||N0(a,l)}),e.once("afterpaint",function(){if(!(0,f.jn)(n)){var o=n.start,s=n.end;(o||s)&&N0(a,[o,s])}})),r}function RL(r){return Fe(CL,AL,LL,bL,EL,_L,OL,FL,IL,PL,DL,TL,kL,BL)(r)}var S5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dual-axes",t}return e.prototype.getDefaultOptions=function(){return kt({},r.prototype.getDefaultOptions.call(this),{yAxis:[],syncViewPadding:!0})},e.prototype.getSchemaAdaptor=function(){return RL},e}(Re);function NL(r,e){var t=e.data,n=e.coordinate,i=e.interactions,a=e.annotations,o=e.animation,s=e.tooltip,l=e.axes,u=e.meta,c=e.geometries;t&&r.data(t);var h={};l&&(0,f.S6)(l,function(v,d){h[d]=Qe(v,Hr)}),h=kt({},u,h),r.scale(h),n&&r.coordinate(n),l===!1?r.axis(!1):(0,f.S6)(l,function(v,d){r.axis(d,v)}),(0,f.S6)(c,function(v){var d=Gr({chart:r,options:v}).ext,g=v.adjust;g&&d.geometry.adjust(g)}),(0,f.S6)(i,function(v){v.enable===!1?r.removeInteraction(v.type):r.interaction(v.type,v.cfg)}),(0,f.S6)(a,function(v){r.annotation()[v.type]((0,p.pi)({},v))}),mo(r,o),s?(r.interaction("tooltip"),r.tooltip(s)):s===!1&&r.removeInteraction("tooltip")}function UL(r){var e=r.chart,t=r.options,n=t.type,i=t.data,a=t.fields,o=t.eachView,s=(0,f.CE)(t,["type","data","fields","eachView","axes","meta","tooltip","coordinate","theme","legend","interactions","annotations"]);return e.data(i),e.facet(n,(0,p.pi)((0,p.pi)({},s),{fields:a,eachView:function(l,u){var c=o(l,u);if(c.geometries)NL(l,c);else{var h=c,v=h.options;v.tooltip&&l.interaction("tooltip"),Kc(h.type,l,v)}}})),r}function zL(r){var e=r.chart,t=r.options,n=t.axes,i=t.meta,a=t.tooltip,o=t.coordinate,s=t.theme,l=t.legend,u=t.interactions,c=t.annotations,h={};return n&&(0,f.S6)(n,function(v,d){h[d]=Qe(v,Hr)}),h=kt({},i,h),e.scale(h),e.coordinate(o),n?(0,f.S6)(n,function(v,d){e.axis(d,v)}):e.axis(!1),a?(e.interaction("tooltip"),e.tooltip(a)):a===!1&&e.removeInteraction("tooltip"),e.legend(l),s&&e.theme(s),(0,f.S6)(u,function(v){v.enable===!1?e.removeInteraction(v.type):e.interaction(v.type,v.cfg)}),(0,f.S6)(c,function(v){e.annotation()[v.type]((0,p.pi)({},v))}),r}function VL(r){return Fe(We,UL,zL)(r)}var HL={title:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}},rowTitle:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}},columnTitle:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}}},C5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="area",t}return e.getDefaultOptions=function(){return HL},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return VL},e}(Re);function GL(r){var e=r.chart,t=r.options,n=t.data,i=t.type,a=t.xField,o=t.yField,s=t.colorField,l=t.sizeField,u=t.sizeRatio,c=t.shape,h=t.color,v=t.tooltip,d=t.heatmapStyle,g=t.meta;e.data(n);var y="polygon";i==="density"&&(y="heatmap");var x=sn(v,[a,o,s]),m=x.fields,M=x.formatter,w=1;return(u||u===0)&&(!c&&!l?console.warn("sizeRatio is not in effect: Must define shape or sizeField first"):u<0||u>1?console.warn("sizeRatio is not in effect: It must be a number in [0,1]"):w=u),Gr(kt({},r,{options:{type:y,colorField:s,tooltipFields:m,shapeField:l||"",label:void 0,mapping:{tooltip:M,shape:c&&(l?function(S){var b=n.map(function(At){return At[l]}),k=(g==null?void 0:g[l])||{},H=k.min,at=k.max;return H=(0,f.hj)(H)?H:Math.min.apply(Math,b),at=(0,f.hj)(at)?at:Math.max.apply(Math,b),[c,((0,f.U2)(S,l)-H)/(at-H),w]}:function(){return[c,1,w]}),color:h||s&&e.getTheme().sequenceColors.join("-"),style:d}}})),r}function YL(r){var e,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return Fe(ur((e={},e[a]=n,e[o]=i,e)))(r)}function XL(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return n===!1?e.axis(a,!1):e.axis(a,n),i===!1?e.axis(o,!1):e.axis(o,i),r}function WL(r){var e=r.chart,t=r.options,n=t.legend,i=t.colorField,a=t.sizeField,o=t.sizeLegend,s=n!==!1;return i&&e.legend(i,s?n:!1),a&&e.legend(a,o===void 0?n:o),!s&&!o&&e.legend(!1),r}function ZL(r){var e=r.chart,t=r.options,n=t.label,i=t.colorField,a=t.type,o=br(e,a==="density"?"heatmap":"polygon");if(!n)o.label(!1);else if(i){var s=n.callback,l=(0,p._T)(n,["callback"]);o.label({fields:[i],callback:s,cfg:xr(l)})}return r}function $L(r){var e,t,n=r.chart,i=r.options,a=i.coordinate,o=i.reflect,s=kt({actions:[]},a!=null?a:{type:"rect"});return o&&((t=(e=s.actions)===null||e===void 0?void 0:e.push)===null||t===void 0||t.call(e,["reflect",o])),n.coordinate(s),r}function qL(r){return Fe(We,Kr("heatmapStyle"),YL,$L,GL,XL,WL,pr,ZL,sr(),or,tr,hi)(r)}var KL=kt({},Re.getDefaultOptions(),{type:"polygon",legend:!1,coordinate:{type:"rect"},xAxis:{tickLine:null,line:null,grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}},yAxis:{grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}}});Ke("polygon","circle",{draw:function(r,e){var t,n,i=r.x,a=r.y,o=this.parsePoints(r.points),s=Math.abs(o[2].x-o[1].x),l=Math.abs(o[1].y-o[0].y),u=Math.min(s,l)/2,c=Number(r.shape[1]),h=Number(r.shape[2]),v=Math.sqrt(h),d=u*v*Math.sqrt(c),g=((t=r.style)===null||t===void 0?void 0:t.fill)||r.color||((n=r.defaultStyle)===null||n===void 0?void 0:n.fill),y=e.addShape("circle",{attrs:(0,p.pi)((0,p.pi)((0,p.pi)({x:i,y:a,r:d},r.defaultStyle),r.style),{fill:g})});return y}}),Ke("polygon","square",{draw:function(r,e){var t,n,i=r.x,a=r.y,o=this.parsePoints(r.points),s=Math.abs(o[2].x-o[1].x),l=Math.abs(o[1].y-o[0].y),u=Math.min(s,l),c=Number(r.shape[1]),h=Number(r.shape[2]),v=Math.sqrt(h),d=u*v*Math.sqrt(c),g=((t=r.style)===null||t===void 0?void 0:t.fill)||r.color||((n=r.defaultStyle)===null||n===void 0?void 0:n.fill),y=e.addShape("rect",{attrs:(0,p.pi)((0,p.pi)((0,p.pi)({x:i-d/2,y:a-d/2,width:d,height:d},r.defaultStyle),r.style),{fill:g})});return y}});var A5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="heatmap",t}return e.getDefaultOptions=function(){return KL},e.prototype.getSchemaAdaptor=function(){return qL},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(Re),jL="liquid";function U0(r){return[{percent:r,type:jL}]}function JL(r){var e=r.chart,t=r.options,n=t.percent,i=t.liquidStyle,a=t.radius,o=t.outline,s=t.wave,l=t.shape,u=t.shapeStyle,c=t.animation;e.scale({percent:{min:0,max:1}}),e.data(U0(n));var h=t.color||e.getTheme().defaultColor,v=kt({},r,{options:{xField:"type",yField:"percent",widthRatio:a,interval:{color:h,style:i,shape:"liquid-fill-gauge"}}}),d=Tr(v).ext,g=d.geometry,y=e.getTheme().background,x={percent:n,radius:a,outline:o,wave:s,shape:l,shapeStyle:u,background:y,animation:c};return g.customInfo(x),e.legend(!1),e.axis(!1),e.tooltip(!1),r}function z0(r,e){var t=r.chart,n=r.options,i=n.statistic,a=n.percent,o=n.meta;t.getController("annotation").clear(!0);var s=(0,f.U2)(o,["percent","formatter"])||function(u){return"".concat((u*100).toFixed(2),"%")},l=i.content;return l&&(l=kt({},l,{content:(0,f.UM)(l.content)?s(a):l.content})),qs(t,{statistic:(0,p.pi)((0,p.pi)({},i),{content:l}),plotType:"liquid"},{percent:a}),e&&t.render(!0),r}function QL(r){return Fe(We,Kr("liquidStyle"),JL,z0,ur({}),tr,or)(r)}var tD={radius:.9,statistic:{title:!1,content:{style:{opacity:.75,fontSize:"30px",lineHeight:"30px",textAlign:"center"}}},outline:{border:2,distance:0},wave:{count:3,length:192},shape:"circle"},V0=5e3;function H0(r,e,t){return r+(e-r)*t}function eD(r){var e=(0,p.pi)({opacity:1},r.style);return r.color&&!e.fill&&(e.fill=r.color),e}function rD(r){var e={fill:"#fff",fillOpacity:0,lineWidth:4},t=(0,f.CD)({},e,r.style);return r.color&&!t.stroke&&(t.stroke=r.color),(0,f.hj)(r.opacity)&&(t.opacity=t.strokeOpacity=r.opacity),t}function nD(r,e,t,n){return e===0?[[r+1/2*t/Math.PI/2,n/2],[r+1/2*t/Math.PI,n],[r+t/4,n]]:e===1?[[r+1/2*t/Math.PI/2*(Math.PI-2),n],[r+1/2*t/Math.PI/2*(Math.PI-1),n/2],[r+t/4,0]]:e===2?[[r+1/2*t/Math.PI/2,-n/2],[r+1/2*t/Math.PI,-n],[r+t/4,-n]]:[[r+1/2*t/Math.PI/2*(Math.PI-2),-n],[r+1/2*t/Math.PI/2*(Math.PI-1),-n/2],[r+t/4,0]]}function iD(r,e,t,n,i,a,o){for(var s=Math.ceil(2*r/t*4)*4,l=[],u=n;u<-Math.PI*2;)u+=Math.PI*2;for(;u>0;)u-=Math.PI*2;u=u/Math.PI/2*t;var c=a-r+u-r*2;l.push(["M",c,e]);for(var h=0,v=0;v<s;++v){var d=v%4,g=nD(v*t/4,d,t,i);l.push(["C",g[0][0]+c,-g[0][1]+e,g[1][0]+c,-g[1][1]+e,g[2][0]+c,-g[2][1]+e]),v===s-1&&(h=g[2][0])}return l.push(["L",h+c,o+r]),l.push(["L",c,o+r]),l.push(["Z"]),l}function aD(r,e,t,n,i,a,o,s,l,u){for(var c=i.fill,h=i.opacity,v=o.getBBox(),d=v.maxX-v.minX,g=v.maxY-v.minY,y=0;y<n;y++){var x=n<=1?1:y/(n-1),m=a.addShape("path",{name:"waterwave-path",attrs:{path:iD(s,v.minY+g*t,l,0,d/32,r,e),fill:c,opacity:H0(.2,.9,x)*h}});try{if(u===!1)return;var M=$c([["t",l,0]]);m.stopAnimate(),m.animate({matrix:M},{duration:H0(.5*V0,V0,x),repeat:!0})}catch(w){console.warn("off-screen group animate error!")}}}function oD(r,e,t,n){var i=t*2/3,a=Math.max(i,n),o=i/2,s=r,l=o+e-a/2,u=Math.asin(o/((a-o)*.85)),c=Math.sin(u)*o,h=Math.cos(u)*o,v=s-h,d=l+c,g=r,y=l+o/Math.sin(u);return`
  65. M `.concat(v," ").concat(d,`
  66. A `).concat(o," ").concat(o," 0 1 1 ").concat(v+h*2," ").concat(d,`
  67. Q `).concat(g," ").concat(y," ").concat(r," ").concat(e+a/2,`
  68. Q `).concat(g," ").concat(y," ").concat(v," ").concat(d,`
  69. Z
  70. `)}function sD(r,e,t,n){var i=t/2,a=n/2;return`
  71. M `.concat(r," ").concat(e-a,`
  72. a `).concat(i," ").concat(a," 0 1 0 0 ").concat(a*2,`
  73. a `).concat(i," ").concat(a," 0 1 0 0 ").concat(-a*2,`
  74. Z
  75. `)}function lD(r,e,t,n){var i=n/2,a=t/2;return`
  76. M `.concat(r," ").concat(e-i,`
  77. L `).concat(r+a," ").concat(e,`
  78. L `).concat(r," ").concat(e+i,`
  79. L `).concat(r-a," ").concat(e,`
  80. Z
  81. `)}function uD(r,e,t,n){var i=n/2,a=t/2;return`
  82. M `.concat(r," ").concat(e-i,`
  83. L `).concat(r+a," ").concat(e+i,`
  84. L `).concat(r-a," ").concat(e+i,`
  85. Z
  86. `)}function cD(r,e,t,n){var i=.618,a=n/2,o=t/2*i;return`
  87. M `.concat(r-o," ").concat(e-a,`
  88. L `).concat(r+o," ").concat(e-a,`
  89. L `).concat(r+o," ").concat(e+a,`
  90. L `).concat(r-o," ").concat(e+a,`
  91. Z
  92. `)}var G0={pin:oD,circle:sD,diamond:lD,triangle:uD,rect:cD};Ke("interval","liquid-fill-gauge",{draw:function(r,e){var t=.5,n=.5,i=r.customInfo,a=i,o=a.percent,s=a.radius,l=a.shape,u=a.shapeStyle,c=a.background,h=a.animation,v=i.outline,d=i.wave,g=v.border,y=v.distance,x=d.count,m=d.length,M=(0,f.u4)(r.points,function(Me,be){return Math.min(Me,be.x)},Infinity),w=this.parsePoint({x:t,y:n}),S=this.parsePoint({x:M,y:n}),b=w.x-S.x,k=Math.min(b,S.y*s),H=eD(r),at=rD((0,f.CD)({},r,v)),At=k-g/2,gt=typeof l=="function"?l:G0[l]||G0.circle,Nt=gt(w.x,w.y,At*2,At*2);if(u&&e.addShape("path",{name:"shape",attrs:(0,p.pi)({path:Nt},u)}),o>0){var te=e.addGroup({name:"waves"}),ce=te.setClip({type:"path",attrs:{path:Nt}});aD(w.x,w.y,1-r.points[1].y,x,H,te,ce,k*2,m,h)}return e.addShape("path",{name:"distance",attrs:{path:Nt,fill:"transparent",lineWidth:g+y*2,stroke:c==="transparent"?"#fff":c}}),e.addShape("path",{name:"wrap",attrs:(0,f.CD)(at,{path:Nt,fill:"transparent",lineWidth:g})}),e}});var b5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="liquid",t}return e.getDefaultOptions=function(){return tD},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.changeData=function(t){this.chart.emit(X.BEFORE_CHANGE_DATA,lr.fromData(this.chart,X.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(U0(t)),z0({chart:this.chart,options:this.options},!0),this.chart.emit(X.AFTER_CHANGE_DATA,lr.fromData(this.chart,X.AFTER_CHANGE_DATA,null))},e.prototype.getSchemaAdaptor=function(){return QL},e}(Re);function fD(r){var e=r.chart,t=r.options,n=t.data,i=t.lineStyle,a=t.color,o=t.point,s=t.area;e.data(n);var l=kt({},r,{options:{line:{style:i,color:a},point:o&&(0,p.pi)({color:a},o),area:s&&(0,p.pi)({color:a},s),label:void 0}}),u=kt({},l,{options:{tooltip:!1}}),c=(o==null?void 0:o.state)||t.state,h=kt({},l,{options:{tooltip:!1,state:c}});return ya(l),jr(h),tl(u),r}function hD(r){var e,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return Fe(ur((e={},e[a]=n,e[o]=i,e)))(r)}function vD(r){var e=r.chart,t=r.options,n=t.radius,i=t.startAngle,a=t.endAngle;return e.coordinate("polar",{radius:n,startAngle:i,endAngle:a}),r}function dD(r){var e=r.chart,t=r.options,n=t.xField,i=t.xAxis,a=t.yField,o=t.yAxis;return e.axis(n,i),e.axis(a,o),r}function pD(r){var e=r.chart,t=r.options,n=t.label,i=t.yField,a=br(e,"line");if(!n)a.label(!1);else{var o=n.callback,s=(0,p._T)(n,["callback"]);a.label({fields:[i],callback:o,cfg:xr(s)})}return r}function gD(r){return Fe(fD,hD,We,vD,dD,ki,pr,pD,or,tr,sr())(r)}var yD=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return Object.defineProperty(e.prototype,"name",{get:function(){return"radar-tooltip"},enumerable:!1,configurable:!0}),e.prototype.getTooltipItems=function(t){var n=this.getTooltipCfg(),i=n.shared,a=n.title,o=r.prototype.getTooltipItems.call(this,t);if(o.length>0){var s=this.view.geometries[0],l=s.dataArray,u=o[0].name,c=[];return l.forEach(function(h){h.forEach(function(v){var d=zr.getTooltipItems(v,s),g=d[0];if(!i&&g&&g.name===u){var y=(0,f.UM)(a)?u:a;c.push((0,p.pi)((0,p.pi)({},g),{name:g.title,title:y}))}else if(i&&g){var y=(0,f.UM)(a)?g.name||u:a;c.push((0,p.pi)((0,p.pi)({},g),{name:g.title,title:y}))}})}),c}return[]},e}(bv);Ei("radar-tooltip",yD);var mD=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(){var t=this.context.view;t.removeInteraction("tooltip")},e.prototype.show=function(){var t=this.context.event,n=this.getTooltipController();n.showTooltip({x:t.x,y:t.y})},e.prototype.hide=function(){var t=this.getTooltipController();t.hideTooltip()},e.prototype.getTooltipController=function(){var t=this.context.view;return t.getController("radar-tooltip")},e}(ar);Te("radar-tooltip",mD),De("radar-tooltip",{start:[{trigger:"plot:mousemove",action:"radar-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"radar-tooltip:hide"}]});var T5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="radar",t}return e.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},e.prototype.getDefaultOptions=function(){return kt({},r.prototype.getDefaultOptions.call(this),{xAxis:{label:{offset:15},grid:{line:{type:"line"}}},yAxis:{grid:{line:{type:"circle"}}},legend:{position:"top"},tooltip:{shared:!0,showCrosshairs:!0,showMarkers:!0,crosshairs:{type:"xy",line:{style:{stroke:"#565656",lineDash:[4]}},follow:!0}}})},e.prototype.getSchemaAdaptor=function(){return gD},e}(Re);function xD(r,e,t){var n=t.map(function(o){return o[e]}).filter(function(o){return o!==void 0}),i=n.length>0?Math.max.apply(Math,n):0,a=Math.abs(r)%360;return a?i*360/a:i}function MD(r,e,t){var n=[];return r.forEach(function(i){var a=n.find(function(o){return o[e]===i[e]});a?a[t]+=i[t]||null:n.push((0,p.pi)({},i))}),n}function wD(r){var e=r.chart,t=r.options,n=t.barStyle,i=t.color,a=t.tooltip,o=t.colorField,s=t.type,l=t.xField,u=t.yField,c=t.data,h=t.shape,v=pa(c,u);e.data(v);var d=kt({},r,{options:{tooltip:a,seriesField:o,interval:{style:n,color:i,shape:h||(s==="line"?"line":"intervel")},minColumnWidth:t.minBarWidth,maxColumnWidth:t.maxBarWidth,columnBackground:t.barBackground}});return Tr(d),s==="line"&&jr({chart:e,options:{xField:l,yField:u,seriesField:o,point:{shape:"circle",color:i}}}),r}function Y0(r){var e,t=r.options,n=t.yField,i=t.xField,a=t.data,o=t.isStack,s=t.isGroup,l=t.colorField,u=t.maxAngle,c=o&&!s&&l?MD(a,i,n):a,h=pa(c,n);return Fe(ur((e={},e[n]={min:0,max:xD(u,n,h)},e)))(r)}function SD(r){var e=r.chart,t=r.options,n=t.radius,i=t.innerRadius,a=t.startAngle,o=t.endAngle;return e.coordinate({type:"polar",cfg:{radius:n,innerRadius:i,startAngle:a,endAngle:o}}).transpose(),r}function CD(r){var e=r.chart,t=r.options,n=t.xField,i=t.xAxis;return e.axis(n,i),r}function AD(r){var e=r.chart,t=r.options,n=t.label,i=t.yField,a=br(e,"interval");if(!n)a.label(!1);else{var o=n.callback,s=(0,p._T)(n,["callback"]);a.label({fields:[i],callback:o,cfg:(0,p.pi)((0,p.pi)({},xr(s)),{type:"polar"})})}return r}function bD(r){return Fe(Kr("barStyle"),wD,Y0,CD,SD,or,tr,We,pr,ki,sr(),AD)(r)}var TD=kt({},Re.getDefaultOptions(),{interactions:[{type:"element-active"}],legend:!1,tooltip:{showMarkers:!1},xAxis:{grid:null,tickLine:null,line:null},maxAngle:240}),E5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="radial-bar",t}return e.getDefaultOptions=function(){return TD},e.prototype.changeData=function(t){this.updateOption({data:t}),Y0({chart:this.chart,options:this.options}),this.chart.changeData(t)},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return bD},e}(Re);function ED(r){var e=r.chart,t=r.options,n=t.data,i=t.sectorStyle,a=t.shape,o=t.color;return e.data(n),Fe(Tr)(kt({},r,{options:{marginRatio:1,interval:{style:i,color:o,shape:a}}})),r}function _D(r){var e=r.chart,t=r.options,n=t.label,i=t.xField,a=br(e,"interval");if(n===!1)a.label(!1);else if((0,f.Kn)(n)){var o=n.callback,s=n.fields,l=(0,p._T)(n,["callback","fields"]),u=l.offset,c=l.layout;(u===void 0||u>=0)&&(c=c?(0,f.kJ)(c)?c:[c]:[],l.layout=(0,f.hX)(c,function(h){return h.type!=="limit-in-shape"}),l.layout.length||delete l.layout),a.label({fields:s||[i],callback:o,cfg:xr(l)})}else Hn(pn.WARN,n===null,"the label option must be an Object."),a.label({fields:[i]});return r}function FD(r){var e=r.chart,t=r.options,n=t.legend,i=t.seriesField;return n===!1?e.legend(!1):i&&e.legend(i,n),r}function ID(r){var e=r.chart,t=r.options,n=t.radius,i=t.innerRadius,a=t.startAngle,o=t.endAngle;return e.coordinate({type:"polar",cfg:{radius:n,innerRadius:i,startAngle:a,endAngle:o}}),r}function PD(r){var e,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return Fe(ur((e={},e[a]=n,e[o]=i,e)))(r)}function LD(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return n?e.axis(a,n):e.axis(a,!1),i?e.axis(o,i):e.axis(o,!1),r}function DD(r){Fe(Kr("sectorStyle"),ED,PD,_D,ID,LD,FD,pr,or,tr,We,sr(),hi)(r)}var OD=kt({},Re.getDefaultOptions(),{xAxis:!1,yAxis:!1,legend:{position:"right",radio:{}},sectorStyle:{stroke:"#fff",lineWidth:1},label:{layout:{type:"limit-in-shape"}},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]}),_5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="rose",t}return e.getDefaultOptions=function(){return OD},e.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return DD},e}(Re),X0="x",W0="y",Z0="name",vl="nodes",dl="edges";function kD(r,e,t){var n=[];return r.forEach(function(i){var a=i[e],o=i[t];n.includes(a)||n.push(a),n.includes(o)||n.push(o)}),n}function BD(r,e,t,n){var i={};return e.forEach(function(a){i[a]={},e.forEach(function(o){i[a][o]=0})}),r.forEach(function(a){i[a[t]][a[n]]=1}),i}function RD(r,e,t){if(!(0,f.kJ)(r))return[];var n=[],i=kD(r,e,t),a=BD(r,i,e,t),o={};i.forEach(function(l){o[l]=0});function s(l){o[l]=1,i.forEach(function(u){if(a[l][u]!=0)if(o[u]==1)n.push("".concat(l,"_").concat(u));else{if(o[u]==-1)return;s(u)}}),o[l]=-1}return i.forEach(function(l){o[l]!=-1&&s(l)}),n.length!==0&&console.warn("sankey data contains circle, ".concat(n.length," records removed."),n),r.filter(function(l){return n.findIndex(function(u){return u==="".concat(l[e],"_").concat(l[t])})<0})}function ND(r){return r.target.depth}function UD(r){return r.depth}function zD(r,e){return e-1-r.height}function sf(r,e){return r.sourceLinks.length?r.depth:e-1}function VD(r){return r.targetLinks.length?r.depth:r.sourceLinks.length?(0,f.F)(r.sourceLinks,ND)-1:0}function pl(r){return function(){return r}}function lf(r,e){for(var t=0,n=0;n<r.length;n++)t+=e(r[n]);return t}function uf(r,e){for(var t=-Infinity,n=0;n<r.length;n++)t=Math.max(e(r[n]),t);return t}function HD(r,e){for(var t=Infinity,n=0;n<r.length;n++)t=Math.min(e(r[n]),t);return t}function $0(r,e){return gl(r.source,e.source)||r.index-e.index}function q0(r,e){return gl(r.target,e.target)||r.index-e.index}function gl(r,e){return r.y0-e.y0}function cf(r){return r.value}function GD(r){return r.index}function YD(r){return r.nodes}function XD(r){return r.links}function K0(r,e){var t=r.get(e);if(!t)throw new Error("missing: "+e);return t}function j0(r){for(var e=r.nodes,t=0,n=e;t<n.length;t++){for(var i=n[t],a=i.y0,o=a,s=0,l=i.sourceLinks;s<l.length;s++){var u=l[s];u.y0=a+u.width/2,a+=u.width}for(var c=0,h=i.targetLinks;c<h.length;c++){var u=h[c];u.y1=o+u.width/2,o+=u.width}}}function WD(){var r=0,e=0,t=1,n=1,i=24,a=8,o,s=GD,l=sf,u,c,h,v=YD,d=XD,g=6;function y(Gt){var ie={nodes:v(Gt),links:d(Gt)};return x(ie),m(ie),M(ie),w(ie),k(ie),j0(ie),ie}y.update=function(Gt){return j0(Gt),Gt},y.nodeId=function(Gt){return arguments.length?(s=typeof Gt=="function"?Gt:pl(Gt),y):s},y.nodeAlign=function(Gt){return arguments.length?(l=typeof Gt=="function"?Gt:pl(Gt),y):l},y.nodeDepth=function(Gt){return arguments.length?(u=(typeof Gt=="function",Gt),y):u},y.nodeSort=function(Gt){return arguments.length?(c=Gt,y):c},y.nodeWidth=function(Gt){return arguments.length?(i=+Gt,y):i},y.nodePadding=function(Gt){return arguments.length?(a=o=+Gt,y):a},y.nodes=function(Gt){return arguments.length?(v=typeof Gt=="function"?Gt:pl(Gt),y):v},y.links=function(Gt){return arguments.length?(d=typeof Gt=="function"?Gt:pl(Gt),y):d},y.linkSort=function(Gt){return arguments.length?(h=Gt,y):h},y.size=function(Gt){return arguments.length?(r=e=0,t=+Gt[0],n=+Gt[1],y):[t-r,n-e]},y.extent=function(Gt){return arguments.length?(r=+Gt[0][0],t=+Gt[1][0],e=+Gt[0][1],n=+Gt[1][1],y):[[r,e],[t,n]]},y.iterations=function(Gt){return arguments.length?(g=+Gt,y):g};function x(Gt){var ie=Gt.nodes,de=Gt.links;ie.forEach(function(Xe,er){Xe.index=er,Xe.sourceLinks=[],Xe.targetLinks=[]});var ue=new Map(ie.map(function(Xe){return[s(Xe),Xe]}));if(de.forEach(function(Xe,er){Xe.index=er;var vr=Xe.source,dr=Xe.target;typeof vr!="object"&&(vr=Xe.source=K0(ue,vr)),typeof dr!="object"&&(dr=Xe.target=K0(ue,dr)),vr.sourceLinks.push(Xe),dr.targetLinks.push(Xe)}),h!=null)for(var pe=0,Ee=ie;pe<Ee.length;pe++){var Ne=Ee[pe],Ye=Ne.sourceLinks,Ue=Ne.targetLinks;Ye.sort(h),Ue.sort(h)}}function m(Gt){for(var ie=Gt.nodes,de=0,ue=ie;de<ue.length;de++){var pe=ue[de];pe.value=pe.fixedValue===void 0?Math.max(lf(pe.sourceLinks,cf),lf(pe.targetLinks,cf)):pe.fixedValue}}function M(Gt){for(var ie=Gt.nodes,de=ie.length,ue=new Set(ie),pe=new Set,Ee=0;ue.size;){if(ue.forEach(function(Xe){Xe.depth=Ee;for(var er=0,vr=Xe.sourceLinks;er<vr.length;er++){var dr=vr[er].target;pe.add(dr)}}),++Ee>de)throw new Error("circular link");ue=pe,pe=new Set}if(u)for(var Ne=Math.max(uf(ie,function(Xe){return Xe.depth})+1,0),Ye=void 0,Ue=0;Ue<ie.length;Ue++)Ye=ie[Ue],Ye.depth=u.call(null,Ye,Ne)}function w(Gt){for(var ie=Gt.nodes,de=ie.length,ue=new Set(ie),pe=new Set,Ee=0;ue.size;){if(ue.forEach(function(Ne){Ne.height=Ee;for(var Ye=0,Ue=Ne.targetLinks;Ye<Ue.length;Ye++){var Xe=Ue[Ye].source;pe.add(Xe)}}),++Ee>de)throw new Error("circular link");ue=pe,pe=new Set}}function S(Gt){for(var ie=Gt.nodes,de=Math.max(uf(ie,function(dr){return dr.depth})+1,0),ue=(t-r-i)/(de-1),pe=new Array(de).fill(0).map(function(){return[]}),Ee=0,Ne=ie;Ee<Ne.length;Ee++){var Ye=Ne[Ee],Ue=Math.max(0,Math.min(de-1,Math.floor(l.call(null,Ye,de))));Ye.layer=Ue,Ye.x0=r+Ue*ue,Ye.x1=Ye.x0+i,pe[Ue]?pe[Ue].push(Ye):pe[Ue]=[Ye]}if(c)for(var Xe=0,er=pe;Xe<er.length;Xe++){var vr=er[Xe];vr.sort(c)}return pe}function b(Gt){for(var ie=HD(Gt,function(Ln){return(n-e-(Ln.length-1)*o)/lf(Ln,cf)}),de=0,ue=Gt;de<ue.length;de++){for(var pe=ue[de],Ee=e,Ne=0,Ye=pe;Ne<Ye.length;Ne++){var Ue=Ye[Ne];Ue.y0=Ee,Ue.y1=Ee+Ue.value*ie,Ee=Ue.y1+o;for(var Xe=0,er=Ue.sourceLinks;Xe<er.length;Xe++){var vr=er[Xe];vr.width=vr.value*ie}}Ee=(n-Ee+o)/(pe.length+1);for(var dr=0;dr<pe.length;++dr){var Ue=pe[dr];Ue.y0+=Ee*(dr+1),Ue.y1+=Ee*(dr+1)}ce(pe)}}function k(Gt){var ie=S(Gt);o=Math.min(a,(n-e)/(uf(ie,function(Ee){return Ee.length})-1)),b(ie);for(var de=0;de<g;++de){var ue=Math.pow(.99,de),pe=Math.max(1-ue,(de+1)/g);at(ie,ue,pe),H(ie,ue,pe)}}function H(Gt,ie,de){for(var ue=1,pe=Gt.length;ue<pe;++ue){for(var Ee=Gt[ue],Ne=0,Ye=Ee;Ne<Ye.length;Ne++){for(var Ue=Ye[Ne],Xe=0,er=0,vr=0,dr=Ue.targetLinks;vr<dr.length;vr++){var Ln=dr[vr],Xi=Ln.source,$n=Ln.value,Ta=$n*(Ue.layer-Xi.layer);Xe+=Me(Xi,Ue)*Ta,er+=Ta}if(er>0){var Ea=(Xe/er-Ue.y0)*ie;Ue.y0+=Ea,Ue.y1+=Ea,te(Ue)}}c===void 0&&Ee.sort(gl),Ee.length&&At(Ee,de)}}function at(Gt,ie,de){for(var ue=Gt.length,pe=ue-2;pe>=0;--pe){for(var Ee=Gt[pe],Ne=0,Ye=Ee;Ne<Ye.length;Ne++){for(var Ue=Ye[Ne],Xe=0,er=0,vr=0,dr=Ue.sourceLinks;vr<dr.length;vr++){var Ln=dr[vr],Xi=Ln.target,$n=Ln.value,Ta=$n*(Xi.layer-Ue.layer);Xe+=be(Ue,Xi)*Ta,er+=Ta}if(er>0){var Ea=(Xe/er-Ue.y0)*ie;Ue.y0+=Ea,Ue.y1+=Ea,te(Ue)}}c===void 0&&Ee.sort(gl),Ee.length&&At(Ee,de)}}function At(Gt,ie){var de=Gt.length>>1,ue=Gt[de];Nt(Gt,ue.y0-o,de-1,ie),gt(Gt,ue.y1+o,de+1,ie),Nt(Gt,n,Gt.length-1,ie),gt(Gt,e,0,ie)}function gt(Gt,ie,de,ue){for(;de<Gt.length;++de){var pe=Gt[de],Ee=(ie-pe.y0)*ue;Ee>1e-6&&(pe.y0+=Ee,pe.y1+=Ee),ie=pe.y1+o}}function Nt(Gt,ie,de,ue){for(;de>=0;--de){var pe=Gt[de],Ee=(pe.y1-ie)*ue;Ee>1e-6&&(pe.y0-=Ee,pe.y1-=Ee),ie=pe.y0-o}}function te(Gt){var ie=Gt.sourceLinks,de=Gt.targetLinks;if(h===void 0){for(var ue=0,pe=de;ue<pe.length;ue++){var Ee=pe[ue].source.sourceLinks;Ee.sort(q0)}for(var Ne=0,Ye=ie;Ne<Ye.length;Ne++){var Ue=Ye[Ne].target.targetLinks;Ue.sort($0)}}}function ce(Gt){if(h===void 0)for(var ie=0,de=Gt;ie<de.length;ie++){var ue=de[ie],pe=ue.sourceLinks,Ee=ue.targetLinks;pe.sort(q0),Ee.sort($0)}}function Me(Gt,ie){for(var de=Gt.y0-(Gt.sourceLinks.length-1)*o/2,ue=0,pe=Gt.sourceLinks;ue<pe.length;ue++){var Ee=pe[ue],Ne=Ee.target,Ye=Ee.width;if(Ne===ie)break;de+=Ye+o}for(var Ue=0,Xe=ie.targetLinks;Ue<Xe.length;Ue++){var er=Xe[Ue],Ne=er.source,Ye=er.width;if(Ne===Gt)break;de-=Ye}return de}function be(Gt,ie){for(var de=ie.y0-(ie.targetLinks.length-1)*o/2,ue=0,pe=ie.targetLinks;ue<pe.length;ue++){var Ee=pe[ue],Ne=Ee.source,Ye=Ee.width;if(Ne===Gt)break;de+=Ye+o}for(var Ue=0,Xe=Gt.sourceLinks;Ue<Xe.length;Ue++){var er=Xe[Ue],Ne=er.target,Ye=er.width;if(Ne===ie)break;de-=Ye}return de}return y}var ZD={left:UD,right:zD,center:VD,justify:sf},$D={nodeId:function(r){return r.index},nodeAlign:"justify",nodeWidth:.008,nodePadding:.03,nodeSort:void 0};function qD(r){var e=(0,f.HD)(r)?ZD[r]:(0,f.mf)(r)?r:null;return e||sf}function KD(r){return(0,f.f0)({},$D,r)}function jD(r,e){var t=KD(r),n=t.nodeId,i=t.nodeSort,a=t.nodeAlign,o=t.nodeWidth,s=t.nodePadding,l=t.nodeDepth,u=WD().nodeSort(i).nodeWidth(o).nodePadding(s).nodeDepth(l).nodeAlign(qD(a)).extent([[0,0],[1,1]]).nodeId(n),c=u(e),h=c.nodes.map(function(d){var g=d.x0,y=d.x1,x=d.y0,m=d.y1;return d.x=[g,y,y,g],d.y=[x,x,m,m],d}).filter(function(d){return d.name!==null}),v=c.links.map(function(d){var g=d.source,y=d.target,x=g.x1,m=y.x0;d.x=[x,x,m,m];var M=d.width/2;return d.y=[d.y0+M,d.y0-M,d.y1+M,d.y1-M],d}).filter(function(d){var g=d.source,y=d.target;return g.name!==null&&y.name!==null});return{nodes:h,links:v}}function JD(r){return r==="node-link"}function QD(r,e,t){return Oi(r)?r/t:e}function tO(r,e,t){return Oi(r)?r/t:e}function J0(r,e,t){var n=r.dataType,i=r.data,a=r.sourceField,o=r.targetField,s=r.weightField,l=r.nodeAlign,u=r.nodeSort,c=r.nodePadding,h=r.nodePaddingRatio,v=r.nodeWidth,d=r.nodeWidthRatio,g=r.nodeDepth,y=r.rawFields,x=y===void 0?[]:y,m;JD(n)?m=i:m=Vp(RD(i,a,o),a,o,s,x);var M=jD({nodeAlign:l,nodePadding:tO(c,h,t),nodeWidth:QD(v,d,e),nodeSort:u,nodeDepth:g},m),w=M.nodes,S=M.links;return{nodes:w.map(function(b){return(0,p.pi)((0,p.pi)({},Qe(b,(0,p.ev)(["x","y","name"],x,!0))),{isNode:!0})}),edges:S.map(function(b){return(0,p.pi)((0,p.pi)({source:b.source.name,target:b.target.name,name:b.source.name||b.target.name},Qe(b,(0,p.ev)(["x","y","value"],x,!0))),{isNode:!1})})}}function eO(r){var e=r.options,t=e.rawFields,n=t===void 0?[]:t;return kt({},{options:{tooltip:{fields:(0,f.jj)((0,p.ev)(["name","source","target","value","isNode"],n,!0))},label:{fields:(0,f.jj)((0,p.ev)(["x","name"],n,!0))}}},r)}function rO(r){var e=r.chart,t=r.options,n=t.color,i=t.nodeStyle,a=t.edgeStyle,o=t.label,s=t.tooltip,l=t.nodeState,u=t.edgeState,c=t.rawFields,h=c===void 0?[]:c;e.legend(!1),e.tooltip(s),e.axis(!1),e.coordinate().reflect("y");var v=J0(t,e.width,e.height),d=v.nodes,g=v.edges,y=e.createView({id:dl});y.data(g),eg({chart:y,options:{xField:X0,yField:W0,seriesField:Z0,rawFields:(0,p.ev)(["source","target"],h,!0),edge:{color:n,style:a,shape:"arc"},tooltip:s,state:u}});var x=e.createView({id:vl});return x.data(d),el({chart:x,options:{xField:X0,yField:W0,seriesField:Z0,polygon:{color:n,style:i},label:o,tooltip:s,state:l}}),e.interaction("element-active"),e.scale({x:{sync:!0,nice:!0,min:0,max:1,minLimit:0,maxLimit:1},y:{sync:!0,nice:!0,min:0,max:1,minLimit:0,maxLimit:1},name:{sync:"color",type:"cat"}}),r}function nO(r){var e=r.chart,t=r.options,n=t.animation,i=(0,p.ev)((0,p.ev)([],e.views[0].geometries,!0),e.views[1].geometries,!0);return mo(e,n,i),r}function iO(r){var e=r.chart,t=r.options,n=t.nodeDraggable,i="sankey-node-draggable";return n?e.interaction(i):e.removeInteraction(i),r}function aO(r){var e=r.chart,t=r.options,n=t.interactions,i=n===void 0?[]:n,a=[].concat(i,t.nodeInteractions||[]),o=[].concat(i,t.edgeInteractions||[]),s=Ve(e,vl),l=Ve(e,dl);return a.forEach(function(u){(u==null?void 0:u.enable)===!1?s.removeInteraction(u.type):s.interaction(u.type,u.cfg||{})}),o.forEach(function(u){(u==null?void 0:u.enable)===!1?l.removeInteraction(u.type):l.interaction(u.type,u.cfg||{})}),r}function oO(r){return Fe(eO,rO,aO,iO,nO,We)(r)}var sO=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.isDragging=!1,t}return e.prototype.isNodeElement=function(){var t=(0,f.U2)(this.context,"event.target");if(t){var n=t.get("element");return n&&n.getModel().data.isNode}return!1},e.prototype.getNodeView=function(){return Ve(this.context.view,vl)},e.prototype.getEdgeView=function(){return Ve(this.context.view,dl)},e.prototype.getCurrentDatumIdx=function(t){return this.getNodeView().geometries[0].elements.indexOf(t)},e.prototype.start=function(){if(this.isNodeElement()){this.prevPoint={x:(0,f.U2)(this.context,"event.x"),y:(0,f.U2)(this.context,"event.y")};var t=this.context.event.target.get("element"),n=this.getCurrentDatumIdx(t);if(n===-1)return;this.currentElementIdx=n,this.context.isDragging=!0,this.isDragging=!0,this.prevNodeAnimateCfg=this.getNodeView().getOptions().animate,this.prevEdgeAnimateCfg=this.getEdgeView().getOptions().animate,this.getNodeView().animate(!1),this.getEdgeView().animate(!1)}},e.prototype.translate=function(){if(this.isDragging){var t=this.context.view,n={x:(0,f.U2)(this.context,"event.x"),y:(0,f.U2)(this.context,"event.y")},i=n.x-this.prevPoint.x,a=n.y-this.prevPoint.y,o=this.getNodeView(),s=o.geometries[0].elements[this.currentElementIdx];if(s&&s.getModel()){var l=s.getModel().data,u=o.getOptions().data,c=o.getCoordinate(),h={x:i/c.getWidth(),y:a/c.getHeight()},v=(0,p.pi)((0,p.pi)({},l),{x:l.x.map(function(m){return m+=h.x}),y:l.y.map(function(m){return m+=h.y})}),d=(0,p.ev)([],u,!0);d[this.currentElementIdx]=v,o.data(d);var g=l.name,y=this.getEdgeView(),x=y.getOptions().data;x.forEach(function(m){m.source===g&&(m.x[0]+=h.x,m.x[1]+=h.x,m.y[0]+=h.y,m.y[1]+=h.y),m.target===g&&(m.x[2]+=h.x,m.x[3]+=h.x,m.y[2]+=h.y,m.y[3]+=h.y)}),y.data(x),this.prevPoint=n,t.render(!0)}}},e.prototype.end=function(){this.isDragging=!1,this.context.isDragging=!1,this.prevPoint=null,this.currentElementIdx=null,this.getNodeView().animate(this.prevNodeAnimateCfg),this.getEdgeView().animate(this.prevEdgeAnimateCfg)},e}(ar);Te("sankey-node-drag",sO),De("sankey-node-draggable",{showEnable:[{trigger:"polygon:mouseenter",action:"cursor:pointer"},{trigger:"polygon:mouseleave",action:"cursor:default"}],start:[{trigger:"polygon:mousedown",action:"sankey-node-drag:start"}],processing:[{trigger:"plot:mousemove",action:"sankey-node-drag:translate"},{isEnable:function(r){return r.isDragging},trigger:"plot:mousemove",action:"cursor:move"}],end:[{trigger:"plot:mouseup",action:"sankey-node-drag:end"}]});var F5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="sankey",t}return e.getDefaultOptions=function(){return{appendPadding:8,syncViewPadding:!0,nodeStyle:{opacity:1,fillOpacity:1,lineWidth:1},edgeStyle:{opacity:.3,lineWidth:0},edgeState:{active:{style:{opacity:.8,lineWidth:0}}},label:{formatter:function(t){var n=t.name;return n},callback:function(t){var n=t[1]===1;return{style:{fill:"#545454",textAlign:n?"end":"start"},offsetX:n?-8:8}},layout:[{type:"hide-overlap"}]},tooltip:{showTitle:!1,showMarkers:!1,shared:!1,showContent:function(t){return!(0,f.U2)(t,[0,"data","isNode"])},formatter:function(t){var n=t.source,i=t.target,a=t.value;return{name:n+" -> "+i,value:a}}},nodeWidthRatio:.008,nodePaddingRatio:.01,animation:{appear:{animation:"wave-in"},enter:{animation:"wave-in"}}}},e.prototype.changeData=function(t){this.updateOption({data:t});var n=J0(this.options,this.chart.width,this.chart.height),i=n.nodes,a=n.edges,o=Ve(this.chart,vl),s=Ve(this.chart,dl);o.changeData(i),s.changeData(a)},e.prototype.getSchemaAdaptor=function(){return oO},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(Re),ff="ancestor-node",Q0="value",_o="path",lO=[_o,E0,tf,_0,"name","depth","height"],uO=kt({},Re.getDefaultOptions(),{innerRadius:0,radius:.85,hierarchyConfig:{field:"value"},tooltip:{shared:!0,showMarkers:!1,offset:20,showTitle:!1},legend:!1,sunburstStyle:{lineWidth:.5,stroke:"#FFF"},drilldown:{enabled:!0}});function ty(r){r.x0=Math.round(r.x0),r.y0=Math.round(r.y0),r.x1=Math.round(r.x1),r.y1=Math.round(r.y1)}function Fo(r,e,t,n,i){for(var a=r.children,o,s=-1,l=a.length,u=r.value&&(n-e)/r.value;++s<l;)o=a[s],o.y0=t,o.y1=i,o.x0=e,o.x1=e+=o.value*u}function ey(){var r=1,e=1,t=0,n=!1;function i(o){var s=o.height+1;return o.x0=o.y0=t,o.x1=r,o.y1=e/s,o.eachBefore(a(e,s)),n&&o.eachBefore(ty),o}function a(o,s){return function(l){l.children&&Fo(l,l.x0,o*(l.depth+1)/s,l.x1,o*(l.depth+2)/s);var u=l.x0,c=l.y0,h=l.x1-t,v=l.y1-t;h<u&&(u=h=(u+h)/2),v<c&&(c=v=(c+v)/2),l.x0=u,l.y0=c,l.x1=h,l.y1=v}}return i.round=function(o){return arguments.length?(n=!!o,i):n},i.size=function(o){return arguments.length?(r=+o[0],e=+o[1],i):[r,e]},i.padding=function(o){return arguments.length?(t=+o,i):t},i}var cO={field:"value",size:[1,1],round:!1,padding:0,sort:function(r,e){return e.value-r.value},as:["x","y"],ignoreParentValue:!0};function fO(r,e){e=(0,f.f0)({},cO,e);var t=e.as;if(!(0,f.kJ)(t)||t.length!==2)throw new TypeError('Invalid as: it must be an array with 2 strings (e.g. [ "x", "y" ])!');var n;try{n=rf(e)}catch(l){console.warn(l)}var i=function(l){return ey().size(e.size).round(e.round).padding(e.padding)(Ca(l).sum(function(u){return(0,f.dp)(u.children)?e.ignoreParentValue?0:u[n]-(0,f.u4)(u.children,function(c,h){return c+h[n]},0):u[n]}).sort(e.sort))},a=i(r),o=t[0],s=t[1];return a.each(function(l){var u,c;l[o]=[l.x0,l.x1,l.x1,l.x0],l[s]=[l.y1,l.y1,l.y0,l.y0],l.name=l.name||((u=l.data)===null||u===void 0?void 0:u.name)||((c=l.data)===null||c===void 0?void 0:c.label),l.data.name=l.name,["x0","x1","y0","y1"].forEach(function(h){t.indexOf(h)===-1&&delete l[h]})}),nf(a)}function hO(r,e){return r.parent===e.parent?1:2}function vO(r){return r.reduce(dO,0)/r.length}function dO(r,e){return r+e.x}function pO(r){return 1+r.reduce(gO,0)}function gO(r,e){return Math.max(r,e.y)}function yO(r){for(var e;e=r.children;)r=e[0];return r}function mO(r){for(var e;e=r.children;)r=e[e.length-1];return r}function xO(){var r=hO,e=1,t=1,n=!1;function i(a){var o,s=0;a.eachAfter(function(v){var d=v.children;d?(v.x=vO(d),v.y=pO(d)):(v.x=o?s+=r(v,o):0,v.y=0,o=v)});var l=yO(a),u=mO(a),c=l.x-r(l,u)/2,h=u.x+r(u,l)/2;return a.eachAfter(n?function(v){v.x=(v.x-a.x)*e,v.y=(a.y-v.y)*t}:function(v){v.x=(v.x-c)/(h-c)*e,v.y=(1-(a.y?v.y/a.y:1))*t})}return i.separation=function(a){return arguments.length?(r=a,i):r},i.size=function(a){return arguments.length?(n=!1,e=+a[0],t=+a[1],i):n?null:[e,t]},i.nodeSize=function(a){return arguments.length?(n=!0,e=+a[0],t=+a[1],i):n?[e,t]:null},i}var MO={depth:-1},ry={};function wO(r){return r.id}function SO(r){return r.parentId}function CO(){var r=wO,e=SO;function t(n){var i=Array.from(n),a=i.length,o,s,l,u,c,h,v,d=new Map;for(s=0;s<a;++s)o=i[s],c=i[s]=new Aa(o),(h=r(o,s,n))!=null&&(h+="")&&(v=c.id=h,d.set(v,d.has(v)?ry:c)),(h=e(o,s,n))!=null&&(h+="")&&(c.parent=h);for(s=0;s<a;++s)if(c=i[s],h=c.parent){if(u=d.get(h),!u)throw new Error("missing: "+h);if(u===ry)throw new Error("ambiguous: "+h);u.children?u.children.push(c):u.children=[c],c.parent=u}else{if(l)throw new Error("multiple roots");l=c}if(!l)throw new Error("no root");if(l.parent=MO,l.eachBefore(function(g){g.depth=g.parent.depth+1,--a}).eachBefore(T0),l.parent=null,a>0)throw new Error("cycle");return l}return t.id=function(n){return arguments.length?(r=hl(n),t):r},t.parentId=function(n){return arguments.length?(e=hl(n),t):e},t}function AO(r,e){return r.parent===e.parent?1:2}function hf(r){var e=r.children;return e?e[0]:r.t}function vf(r){var e=r.children;return e?e[e.length-1]:r.t}function bO(r,e,t){var n=t/(e.i-r.i);e.c-=n,e.s+=t,r.c+=n,e.z+=t,e.m+=t}function TO(r){for(var e=0,t=0,n=r.children,i=n.length,a;--i>=0;)a=n[i],a.z+=e,a.m+=e,e+=a.s+(t+=a.c)}function EO(r,e,t){return r.a.parent===e.parent?r.a:t}function yl(r,e){this._=r,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}yl.prototype=Object.create(Aa.prototype);function _O(r){for(var e=new yl(r,0),t,n=[e],i,a,o,s;t=n.pop();)if(a=t._.children)for(t.children=new Array(s=a.length),o=s-1;o>=0;--o)n.push(i=t.children[o]=new yl(a[o],o)),i.parent=t;return(e.parent=new yl(null,0)).children=[e],e}function FO(){var r=AO,e=1,t=1,n=null;function i(u){var c=_O(u);if(c.eachAfter(a),c.parent.m=-c.z,c.eachBefore(o),n)u.eachBefore(l);else{var h=u,v=u,d=u;u.eachBefore(function(M){M.x<h.x&&(h=M),M.x>v.x&&(v=M),M.depth>d.depth&&(d=M)});var g=h===v?1:r(h,v)/2,y=g-h.x,x=e/(v.x+g+y),m=t/(d.depth||1);u.eachBefore(function(M){M.x=(M.x+y)*x,M.y=M.depth*m})}return u}function a(u){var c=u.children,h=u.parent.children,v=u.i?h[u.i-1]:null;if(c){TO(u);var d=(c[0].z+c[c.length-1].z)/2;v?(u.z=v.z+r(u._,v._),u.m=u.z-d):u.z=d}else v&&(u.z=v.z+r(u._,v._));u.parent.A=s(u,v,u.parent.A||h[0])}function o(u){u._.x=u.z+u.parent.m,u.m+=u.parent.m}function s(u,c,h){if(c){for(var v=u,d=u,g=c,y=v.parent.children[0],x=v.m,m=d.m,M=g.m,w=y.m,S;g=vf(g),v=hf(v),g&&v;)y=hf(y),d=vf(d),d.a=u,S=g.z+M-v.z-x+r(g._,v._),S>0&&(bO(EO(g,u,h),u,S),x+=S,m+=S),M+=g.m,x+=v.m,w+=y.m,m+=d.m;g&&!vf(d)&&(d.t=g,d.m+=M-m),v&&!hf(y)&&(y.t=v,y.m+=x-w,h=u)}return h}function l(u){u.x*=e,u.y=u.depth*t}return i.separation=function(u){return arguments.length?(r=u,i):r},i.size=function(u){return arguments.length?(n=!1,e=+u[0],t=+u[1],i):n?null:[e,t]},i.nodeSize=function(u){return arguments.length?(n=!0,e=+u[0],t=+u[1],i):n?[e,t]:null},i}function ml(r,e,t,n,i){for(var a=r.children,o,s=-1,l=a.length,u=r.value&&(i-t)/r.value;++s<l;)o=a[s],o.x0=e,o.x1=n,o.y0=t,o.y1=t+=o.value*u}var ny=(1+Math.sqrt(5))/2;function iy(r,e,t,n,i,a){for(var o=[],s=e.children,l,u,c=0,h=0,v=s.length,d,g,y=e.value,x,m,M,w,S,b,k;c<v;){d=i-t,g=a-n;do x=s[h++].value;while(!x&&h<v);for(m=M=x,b=Math.max(g/d,d/g)/(y*r),k=x*x*b,S=Math.max(M/k,k/m);h<v;++h){if(x+=u=s[h].value,u<m&&(m=u),u>M&&(M=u),k=x*x*b,w=Math.max(M/k,k/m),w>S){x-=u;break}S=w}o.push(l={value:x,dice:d<g,children:s.slice(c,h)}),l.dice?Fo(l,t,n,i,y?n+=g*x/y:a):ml(l,t,n,y?t+=d*x/y:i,a),y-=x,c=h}return o}var ay=function r(e){function t(n,i,a,o,s){iy(e,n,i,a,o,s)}return t.ratio=function(n){return r((n=+n)>1?n:1)},t}(ny);function oy(){var r=ay,e=!1,t=1,n=1,i=[0],a=Hi,o=Hi,s=Hi,l=Hi,u=Hi;function c(v){return v.x0=v.y0=0,v.x1=t,v.y1=n,v.eachBefore(h),i=[0],e&&v.eachBefore(ty),v}function h(v){var d=i[v.depth],g=v.x0+d,y=v.y0+d,x=v.x1-d,m=v.y1-d;x<g&&(g=x=(g+x)/2),m<y&&(y=m=(y+m)/2),v.x0=g,v.y0=y,v.x1=x,v.y1=m,v.children&&(d=i[v.depth+1]=a(v)/2,g+=u(v)-d,y+=o(v)-d,x-=s(v)-d,m-=l(v)-d,x<g&&(g=x=(g+x)/2),m<y&&(y=m=(y+m)/2),r(v,g,y,x,m))}return c.round=function(v){return arguments.length?(e=!!v,c):e},c.size=function(v){return arguments.length?(t=+v[0],n=+v[1],c):[t,n]},c.tile=function(v){return arguments.length?(r=hl(v),c):r},c.padding=function(v){return arguments.length?c.paddingInner(v).paddingOuter(v):c.paddingInner()},c.paddingInner=function(v){return arguments.length?(a=typeof v=="function"?v:Sa(+v),c):a},c.paddingOuter=function(v){return arguments.length?c.paddingTop(v).paddingRight(v).paddingBottom(v).paddingLeft(v):c.paddingTop()},c.paddingTop=function(v){return arguments.length?(o=typeof v=="function"?v:Sa(+v),c):o},c.paddingRight=function(v){return arguments.length?(s=typeof v=="function"?v:Sa(+v),c):s},c.paddingBottom=function(v){return arguments.length?(l=typeof v=="function"?v:Sa(+v),c):l},c.paddingLeft=function(v){return arguments.length?(u=typeof v=="function"?v:Sa(+v),c):u},c}function IO(r,e,t,n,i){var a=r.children,o,s=a.length,l,u=new Array(s+1);for(u[0]=l=o=0;o<s;++o)u[o+1]=l+=a[o].value;c(0,s,r.value,e,t,n,i);function c(h,v,d,g,y,x,m){if(h>=v-1){var M=a[h];M.x0=g,M.y0=y,M.x1=x,M.y1=m;return}for(var w=u[h],S=d/2+w,b=h+1,k=v-1;b<k;){var H=b+k>>>1;u[H]<S?b=H+1:k=H}S-u[b-1]<u[b]-S&&h+1<b&&--b;var at=u[b]-w,At=d-at;if(x-g>m-y){var gt=d?(g*At+x*at)/d:x;c(h,b,at,g,y,gt,m),c(b,v,At,gt,y,x,m)}else{var Nt=d?(y*At+m*at)/d:m;c(h,b,at,g,y,x,Nt),c(b,v,At,g,Nt,x,m)}}}function PO(r,e,t,n,i){(r.depth&1?ml:Fo)(r,e,t,n,i)}var LO=function r(e){function t(n,i,a,o,s){if((l=n._squarify)&&l.ratio===e)for(var l,u,c,h,v=-1,d,g=l.length,y=n.value;++v<g;){for(u=l[v],c=u.children,h=u.value=0,d=c.length;h<d;++h)u.value+=c[h].value;u.dice?Fo(u,i,a,o,y?a+=(s-a)*u.value/y:s):ml(u,i,a,y?i+=(o-i)*u.value/y:o,s),y-=u.value}else n._squarify=l=iy(e,n,i,a,o,s),l.ratio=e}return t.ratio=function(n){return r((n=+n)>1?n:1)},t}(ny),DO={field:"value",tile:"treemapSquarify",size:[1,1],round:!1,ignoreParentValue:!0,padding:0,paddingInner:0,paddingOuter:0,paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0,as:["x","y"],sort:function(r,e){return e.value-r.value},ratio:.5*(1+Math.sqrt(5))};function OO(r,e){return r==="treemapSquarify"?q[r].ratio(e):q[r]}function sy(r,e){e=(0,f.f0)({},DO,e);var t=e.as;if(!(0,f.kJ)(t)||t.length!==2)throw new TypeError('Invalid as: it must be an array with 2 strings (e.g. [ "x", "y" ])!');var n;try{n=rf(e)}catch(u){console.warn(u)}var i=OO(e.tile,e.ratio),a=function(u){return oy().tile(i).size(e.size).round(e.round).padding(e.padding).paddingInner(e.paddingInner).paddingOuter(e.paddingOuter).paddingTop(e.paddingTop).paddingRight(e.paddingRight).paddingBottom(e.paddingBottom).paddingLeft(e.paddingLeft)(Ca(u).sum(function(c){return e.ignoreParentValue&&c.children?0:c[n]}).sort(e.sort))},o=a(r),s=t[0],l=t[1];return o.each(function(u){u[s]=[u.x0,u.x1,u.x1,u.x0],u[l]=[u.y1,u.y1,u.y0,u.y0],["x0","x1","y0","y1"].forEach(function(c){t.indexOf(c)===-1&&delete u[c]})}),nf(o)}function ly(r){var e=r.data,t=r.colorField,n=r.rawFields,i=r.hierarchyConfig,a=i===void 0?{}:i,o=a.activeDepth,s={partition:fO,treemap:sy},l=r.seriesField,u=r.type||"partition",c=s[u](e,(0,p.pi)((0,p.pi)({field:l||"value"},(0,f.CE)(a,["activeDepth"])),{type:"hierarchy.".concat(u),as:["x","y"]})),h=[];return c.forEach(function(v){var d,g,y,x,m,M;if(v.depth===0||o>0&&v.depth>o)return null;for(var w=v.data.name,S=(0,p.pi)({},v);S.depth>1;)w="".concat((g=S.parent.data)===null||g===void 0?void 0:g.name," / ").concat(w),S=S.parent;var b=(0,p.pi)((0,p.pi)((0,p.pi)({},Qe(v.data,(0,p.ev)((0,p.ev)([],n||[],!0),[a.field],!1))),(d={},d[_o]=w,d[ff]=S.data.name,d)),v);l&&(b[l]=v.data[l]||((x=(y=v.parent)===null||y===void 0?void 0:y.data)===null||x===void 0?void 0:x[l])),t&&(b[t]=v.data[t]||((M=(m=v.parent)===null||m===void 0?void 0:m.data)===null||M===void 0?void 0:M[t])),b.ext=a,b[To]={hierarchyConfig:a,colorField:t,rawFields:n},h.push(b)}),h}function kO(r){var e=r.chart,t=r.options,n=t.color,i=t.colorField,a=i===void 0?ff:i,o=t.sunburstStyle,s=t.rawFields,l=s===void 0?[]:s,u=t.shape,c=ly(t);e.data(c);var h;return o&&(h=function(v){return kt({},{fillOpacity:Math.pow(.85,v.depth)},(0,f.mf)(o)?o(v):o)}),el(kt({},r,{options:{xField:"x",yField:"y",seriesField:a,rawFields:(0,f.jj)((0,p.ev)((0,p.ev)([],lO,!0),l,!0)),polygon:{color:n,style:h,shape:u}}})),r}function BO(r){var e=r.chart;return e.axis(!1),r}function RO(r){var e=r.chart,t=r.options,n=t.label,i=br(e,"polygon");if(!n)i.label(!1);else{var a=n.fields,o=a===void 0?["name"]:a,s=n.callback,l=(0,p._T)(n,["fields","callback"]);i.label({fields:o,callback:s,cfg:xr(l)})}return r}function NO(r){var e=r.chart,t=r.options,n=t.innerRadius,i=t.radius,a=t.reflect,o=e.coordinate({type:"polar",cfg:{innerRadius:n,radius:i}});return a&&o.reflect(a),r}function UO(r){var e,t=r.options,n=t.hierarchyConfig,i=t.meta;return Fe(ur({},(e={},e[Q0]=(0,f.U2)(i,(0,f.U2)(n,["field"],"value")),e)))(r)}function zO(r){var e=r.chart,t=r.options,n=t.tooltip;if(n===!1)e.tooltip(!1);else{var i=n;(0,f.U2)(n,"fields")||(i=kt({},{customItems:function(a){return a.map(function(o){var s=(0,f.U2)(e.getOptions(),"scales"),l=(0,f.U2)(s,[_o,"formatter"],function(c){return c}),u=(0,f.U2)(s,[Q0,"formatter"],function(c){return c});return(0,p.pi)((0,p.pi)({},o),{name:l(o.data[_o]),value:u(o.data.value)})})}},i)),e.tooltip(i)}return r}function VO(r){var e=r.drilldown,t=r.interactions,n=t===void 0?[]:t;return(e==null?void 0:e.enabled)?kt({},r,{interactions:(0,p.ev)((0,p.ev)([],n,!0),[{type:"drill-down",cfg:{drillDownConfig:e,transformData:ly}}],!1)}):r}function HO(r){var e=r.chart,t=r.options,n=t.drilldown;return or({chart:e,options:VO(t)}),(n==null?void 0:n.enabled)&&(e.appendPadding=$s(e.appendPadding,(0,f.U2)(n,["breadCrumb","position"]))),r}function GO(r){return Fe(We,Kr("sunburstStyle"),kO,BO,UO,ki,NO,zO,RO,HO,tr,sr())(r)}var I5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="sunburst",t}return e.getDefaultOptions=function(){return uO},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return GO},e.SUNBURST_ANCESTOR_FIELD=ff,e.SUNBURST_PATH_FIELD=_o,e.NODE_ANCESTORS_FIELD=tf,e}(Re);function uy(r,e){if(!!(0,f.kJ)(r))return r.find(function(t){return t.type===e})}function cy(r,e){var t=uy(r,e);return t&&t.enable!==!1}function df(r){var e=r.interactions,t=r.drilldown;return(0,f.U2)(t,"enabled")||cy(e,"treemap-drill-down")}function YO(r){var e=r.interactions["drill-down"];if(!!e){var t=e.context.actions.find(function(n){return n.name==="drill-down-action"});t.reset()}}function pf(r){var e=r.data,t=r.colorField,n=r.enableDrillDown,i=r.hierarchyConfig,a=sy(e,(0,p.pi)((0,p.pi)({},i),{type:"hierarchy.treemap",field:"value",as:["x","y"]})),o=[];return a.forEach(function(s){if(s.depth===0||n&&s.depth!==1||!n&&s.children)return null;var l=s.ancestors().map(function(v){return{data:v.data,height:v.height,value:v.value}}),u=n&&(0,f.kJ)(e.path)?l.concat(e.path.slice(1)):l,c=Object.assign({},s.data,(0,p.pi)({x:s.x,y:s.y,depth:s.depth,value:s.value,path:u},s));if(!s.data[t]&&s.parent){var h=s.ancestors().find(function(v){return v.data[t]});c[t]=h==null?void 0:h.data[t]}else c[t]=s.data[t];c[To]={hierarchyConfig:i,colorField:t,enableDrillDown:n},o.push(c)}),o}function XO(r){var e=r.options,t=e.colorField;return kt({options:{rawFields:["value"],tooltip:{fields:["name","value",t,"path"],formatter:function(n){return{name:n.name,value:n.value}}}}},r)}function WO(r){var e=r.chart,t=r.options,n=t.color,i=t.colorField,a=t.rectStyle,o=t.hierarchyConfig,s=t.rawFields,l=pf({data:t.data,colorField:t.colorField,enableDrillDown:df(t),hierarchyConfig:o});return e.data(l),el(kt({},r,{options:{xField:"x",yField:"y",seriesField:i,rawFields:s,polygon:{color:n,style:a}}})),e.coordinate().reflect("y"),r}function ZO(r){var e=r.chart;return e.axis(!1),r}function $O(r){var e=r.drilldown,t=r.interactions,n=t===void 0?[]:t,i=df(r);return i?kt({},r,{interactions:(0,p.ev)((0,p.ev)([],n,!0),[{type:"drill-down",cfg:{drillDownConfig:e,transformData:pf}}],!1)}):r}function qO(r){var e=r.chart,t=r.options,n=t.interactions,i=t.drilldown;or({chart:e,options:$O(t)});var a=uy(n,"view-zoom");a&&(a.enable!==!1?e.getCanvas().on("mousewheel",function(s){s.preventDefault()}):e.getCanvas().off("mousewheel"));var o=df(t);return o&&(e.appendPadding=$s(e.appendPadding,(0,f.U2)(i,["breadCrumb","position"]))),r}function KO(r){return Fe(XO,We,Kr("rectStyle"),WO,ZO,ki,pr,qO,tr,sr())(r)}var jO={colorField:"name",rectStyle:{lineWidth:1,stroke:"#fff"},hierarchyConfig:{tile:"treemapSquarify"},label:{fields:["name"],layout:{type:"limit-in-shape"}},tooltip:{showMarkers:!1,showTitle:!1},drilldown:{enabled:!1,breadCrumb:{position:"bottom-left",rootText:"\u521D\u59CB",dividerText:"/",textStyle:{fontSize:12,fill:"rgba(0, 0, 0, 0.65)",cursor:"pointer"},activeTextStyle:{fill:"#87B5FF"}}}},P5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="treemap",t}return e.getDefaultOptions=function(){return jO},e.prototype.changeData=function(t){var n=this.options,i=n.colorField,a=n.interactions,o=n.hierarchyConfig;this.updateOption({data:t});var s=pf({data:t,colorField:i,enableDrillDown:cy(a,"treemap-drill-down"),hierarchyConfig:o});this.chart.changeData(s),YO(this.chart)},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return KO},e}(Re),Zn="id",gf="path",JO={appendPadding:[10,0,20,0],blendMode:"multiply",tooltip:{showTitle:!1,showMarkers:!1,fields:["id","size"],formatter:function(r){return{name:r.id,value:r.size}}},legend:{position:"top-left"},label:{style:{textAlign:"center",fill:"#fff"}},interactions:[{type:"legend-filter",enable:!1}],state:{active:{style:{stroke:"#000"}},selected:{style:{stroke:"#000",lineWidth:2}},inactive:{style:{fillOpacity:.3,strokeOpacity:.3}}},defaultInteractions:["tooltip","venn-legend-active"]};function xl(r){if(!!r){var e=r.geometries[0].elements;e.forEach(function(t){t.shape.toFront()})}}var QO=ps("element-active"),tk=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.syncElementsPos=function(){xl(this.context.view)},e.prototype.active=function(){r.prototype.active.call(this),this.syncElementsPos()},e.prototype.toggle=function(){r.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.reset=function(){r.prototype.reset.call(this),this.syncElementsPos()},e}(QO),ek=ps("element-highlight"),rk=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.syncElementsPos=function(){xl(this.context.view)},e.prototype.highlight=function(){r.prototype.highlight.call(this),this.syncElementsPos()},e.prototype.toggle=function(){r.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.clear=function(){r.prototype.clear.call(this),this.syncElementsPos()},e.prototype.reset=function(){r.prototype.reset.call(this),this.syncElementsPos()},e}(ek),nk=ps("element-selected"),ik=ps("element-single-selected"),ak=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.syncElementsPos=function(){xl(this.context.view)},e.prototype.selected=function(){r.prototype.selected.call(this),this.syncElementsPos()},e.prototype.toggle=function(){r.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.reset=function(){r.prototype.reset.call(this),this.syncElementsPos()},e}(nk),ok=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.syncElementsPos=function(){xl(this.context.view)},e.prototype.selected=function(){r.prototype.selected.call(this),this.syncElementsPos()},e.prototype.toggle=function(){r.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.reset=function(){r.prototype.reset.call(this),this.syncElementsPos()},e}(ik);Te("venn-element-active",tk),Te("venn-element-highlight",rk),Te("venn-element-selected",ak),Te("venn-element-single-selected",ok),De("venn-element-active",{start:[{trigger:"element:mouseenter",action:"venn-element-active:active"}],end:[{trigger:"element:mouseleave",action:"venn-element-active:reset"}]}),De("venn-element-highlight",{start:[{trigger:"element:mouseenter",action:"venn-element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"venn-element-highlight:reset"}]}),De("venn-element-selected",{start:[{trigger:"element:click",action:"venn-element-selected:toggle"}],rollback:[{trigger:"dblclick",action:["venn-element-selected:reset"]}]}),De("venn-element-single-selected",{start:[{trigger:"element:click",action:"venn-element-single-selected:toggle"}],rollback:[{trigger:"dblclick",action:["venn-element-single-selected:reset"]}]}),De("venn-legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","venn-element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","venn-element-active:reset"]}]}),De("venn-legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","venn-element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","venn-element-highlight:reset"]}]});var sk=function(r){(0,p.ZT)(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getLabelPoint=function(t,n,i){var a=t.data,o=a.x,s=a.y,l=t.customLabelInfo,u=l.offsetX,c=l.offsetY;return{content:t.content[i],x:o+u,y:s+c}},e}(As);ro("venn",sk);var lk=Array.isArray,uk=lk,Io=`
  93. \v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,ck=new RegExp("([a-z])["+Io+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+Io+"]*,?["+Io+"]*)+)","ig"),fk=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+Io+"]*,?["+Io+"]*","ig");function hk(r){if(!r)return null;if(uk(r))return r;var e={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},t=[];return String(r).replace(ck,function(n,i,a){var o=[],s=i.toLowerCase();if(a.replace(fk,function(l,u){u&&o.push(+u)}),s==="m"&&o.length>2&&(t.push([i].concat(o.splice(0,2))),s="l",i=i==="m"?"l":"L"),s==="o"&&o.length===1&&t.push([i,o[0]]),s==="r")t.push([i].concat(o));else for(;o.length>=e[s]&&(t.push([i].concat(o.splice(0,e[s]))),!!e[s]););return""}),t}var vk=/[a-z]/;function fy(r,e){return[e[0]+(e[0]-r[0]),e[1]+(e[1]-r[1])]}function L5(r){var e=parsePathString(r);if(!e||!e.length)return[["M",0,0]];for(var t=!1,n=0;n<e.length;n++){var i=e[n][0];if(vk.test(i)||["V","H","T","S"].indexOf(i)>=0){t=!0;break}}if(!t)return e;var a=[],o=0,s=0,l=0,u=0,c=0,h,v,d=e[0];(d[0]==="M"||d[0]==="m")&&(o=+d[1],s=+d[2],l=o,u=s,c++,a[0]=["M",o,s]);for(var n=c,g=e.length;n<g;n++){var y=e[n],x=a[n-1],m=[],i=y[0],M=i.toUpperCase();if(i!==M)switch(m[0]=M,M){case"A":m[1]=y[1],m[2]=y[2],m[3]=y[3],m[4]=y[4],m[5]=y[5],m[6]=+y[6]+o,m[7]=+y[7]+s;break;case"V":m[1]=+y[1]+s;break;case"H":m[1]=+y[1]+o;break;case"M":l=+y[1]+o,u=+y[2]+s,m[1]=l,m[2]=u;break;default:for(var w=1,S=y.length;w<S;w++)m[w]=+y[w]+(w%2?o:s)}else m=e[n];switch(M){case"Z":o=+l,s=+u;break;case"H":o=m[1],m=["L",o,s];break;case"V":s=m[1],m=["L",o,s];break;case"T":o=m[1],s=m[2];var b=fy([x[1],x[2]],[x[3],x[4]]);m=["Q",b[0],b[1],o,s];break;case"S":o=m[m.length-2],s=m[m.length-1];var k=x.length,H=fy([x[k-4],x[k-3]],[x[k-2],x[k-1]]);m=["C",H[0],H[1],m[1],m[2],o,s];break;case"M":l=m[m.length-2],u=m[m.length-1];break;default:o=m[m.length-2],s=m[m.length-1]}a.push(m)}return a}var Po=Math.PI*2,yf=function(r,e,t,n,i,a,o){var s=r.x,l=r.y;s*=e,l*=t;var u=n*s-i*l,c=i*s+n*l;return{x:u+a,y:c+o}},dk=function(r,e){var t=e===1.5707963267948966?.551915024494:e===-1.5707963267948966?-.551915024494:4/3*Math.tan(e/4),n=Math.cos(r),i=Math.sin(r),a=Math.cos(r+e),o=Math.sin(r+e);return[{x:n-i*t,y:i+n*t},{x:a+o*t,y:o-a*t},{x:a,y:o}]},hy=function(r,e,t,n){var i=r*n-e*t<0?-1:1,a=r*t+e*n;return a>1&&(a=1),a<-1&&(a=-1),i*Math.acos(a)},pk=function(r,e,t,n,i,a,o,s,l,u,c,h){var v=Math.pow(i,2),d=Math.pow(a,2),g=Math.pow(c,2),y=Math.pow(h,2),x=v*d-v*y-d*g;x<0&&(x=0),x/=v*y+d*g,x=Math.sqrt(x)*(o===s?-1:1);var m=x*i/a*h,M=x*-a/i*c,w=u*m-l*M+(r+t)/2,S=l*m+u*M+(e+n)/2,b=(c-m)/i,k=(h-M)/a,H=(-c-m)/i,at=(-h-M)/a,At=hy(1,0,b,k),gt=hy(b,k,H,at);return s===0&&gt>0&&(gt-=Po),s===1&&gt<0&&(gt+=Po),[w,S,At,gt]},gk=function(r){var e=r.px,t=r.py,n=r.cx,i=r.cy,a=r.rx,o=r.ry,s=r.xAxisRotation,l=s===void 0?0:s,u=r.largeArcFlag,c=u===void 0?0:u,h=r.sweepFlag,v=h===void 0?0:h,d=[];if(a===0||o===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];var g=Math.sin(l*Po/360),y=Math.cos(l*Po/360),x=y*(e-n)/2+g*(t-i)/2,m=-g*(e-n)/2+y*(t-i)/2;if(x===0&&m===0)return[{x1:0,y1:0,x2:0,y2:0,x:n,y:i}];a=Math.abs(a),o=Math.abs(o);var M=Math.pow(x,2)/Math.pow(a,2)+Math.pow(m,2)/Math.pow(o,2);M>1&&(a*=Math.sqrt(M),o*=Math.sqrt(M));var w=pk(e,t,n,i,a,o,c,v,g,y,x,m),S=w[0],b=w[1],k=w[2],H=w[3],at=Math.abs(H)/(Po/4);Math.abs(1-at)<1e-7&&(at=1);var At=Math.max(Math.ceil(at),1);H/=At;for(var gt=0;gt<At;gt++)d.push(dk(k,H)),k+=H;return d.map(function(Nt){var te=yf(Nt[0],a,o,y,g,S,b),ce=te.x,Me=te.y,be=yf(Nt[1],a,o,y,g,S,b),Gt=be.x,ie=be.y,de=yf(Nt[2],a,o,y,g,S,b),ue=de.x,pe=de.y;return{x1:ce,y1:Me,x2:Gt,y2:ie,x:ue,y:pe}})};function D5(r,e,t,n,i,a,o,s,l){var u=gk({px:r,py:e,cx:s,cy:l,rx:t,ry:n,xAxisRotation:i,largeArcFlag:a,sweepFlag:o});return u.reduce(function(c,h){var v=h.x1,d=h.y1,g=h.x2,y=h.y2,x=h.x,m=h.y;return c.push(v,d,g,y,x,m),c},[])}function O5(r,e){"TQ".indexOf(r[0])<0&&(e.qx=null,e.qy=null);var t=r.slice(1),n=t[0],i=t[1];switch(r[0]){case"M":return e.x=n,e.y=i,r;case"A":return["C"].concat(arcToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"Q":return e.qx=n,e.qy=i,["C"].concat(quadToCubic.apply(0,[e.x1,e.y1].concat(r.slice(1))));case"L":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],r[2]));case"H":return["C"].concat(lineToCubic(e.x1,e.y1,r[1],e.y1));case"V":return["C"].concat(lineToCubic(e.x1,e.y1,e.x1,r[1]));case"Z":return["C"].concat(lineToCubic(e.x1,e.y1,e.x,e.y));default:}return r}function k5(r,e){e===void 0&&(e=!1);for(var t=path2Absolute(r),n={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null},i=[],a="",o=t.length,s,l,u=[],c=0;c<o;c+=1)t[c]&&(a=t[c][0]),i[c]=a,t[c]=segmentToCubic(t[c],n),yk(t,i,c),o=t.length,a==="Z"&&u.push(c),s=t[c],l=s.length,n.x1=+s[l-2],n.y1=+s[l-1],n.x2=+s[l-4]||n.x1,n.y2=+s[l-3]||n.y1;return e?[t,u]:t}function yk(r,e,t){if(r[t].length>7){r[t].shift();for(var n=r[t],i=t;n.length;)e[t]="A",r.splice(i+=1,0,["C"].concat(n.splice(0,6)));r.splice(t,1)}}var vy=function(r,e,t,n,i){var a=-3*e+9*t-9*n+3*i,o=r*a+6*e-12*t+6*n;return r*o-3*e+3*t},dy=function(r,e,t,n,i,a,o,s,l){l===null&&(l=1),l=l>1?1:l<0?0:l;for(var u=l/2,c=12,h=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],v=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],d=0,g=0;g<c;g++){var y=u*h[g]+u,x=vy(y,r,t,i,o),m=vy(y,e,n,a,s),M=x*x+m*m;d+=v[g]*Math.sqrt(M)}return u*d},mk=function(r,e,t,n,i,a,o,s){for(var l=[],u=[[],[]],c,h,v,d,g=0;g<2;++g){if(g===0?(h=6*r-12*t+6*i,c=-3*r+9*t-9*i+3*o,v=3*t-3*r):(h=6*e-12*n+6*a,c=-3*e+9*n-9*a+3*s,v=3*n-3*e),Math.abs(c)<1e-12){if(Math.abs(h)<1e-12)continue;d=-v/h,d>0&&d<1&&l.push(d);continue}var y=h*h-4*v*c,x=Math.sqrt(y);if(!(y<0)){var m=(-h+x)/(2*c);m>0&&m<1&&l.push(m);var M=(-h-x)/(2*c);M>0&&M<1&&l.push(M)}}for(var w=l.length,S=w,b;w--;)d=l[w],b=1-d,u[0][w]=b*b*b*r+3*b*b*d*t+3*b*d*d*i+d*d*d*o,u[1][w]=b*b*b*e+3*b*b*d*n+3*b*d*d*a+d*d*d*s;return u[0][S]=r,u[1][S]=e,u[0][S+1]=o,u[1][S+1]=s,u[0].length=u[1].length=S+2,{min:{x:Math.min.apply(0,u[0]),y:Math.min.apply(0,u[1])},max:{x:Math.max.apply(0,u[0]),y:Math.max.apply(0,u[1])}}},xk=function(r,e,t,n,i,a,o,s){if(!(Math.max(r,t)<Math.min(i,o)||Math.min(r,t)>Math.max(i,o)||Math.max(e,n)<Math.min(a,s)||Math.min(e,n)>Math.max(a,s))){var l=(r*n-e*t)*(i-o)-(r-t)*(i*s-a*o),u=(r*n-e*t)*(a-s)-(e-n)*(i*s-a*o),c=(r-t)*(a-s)-(e-n)*(i-o);if(!!c){var h=l/c,v=u/c,d=+h.toFixed(2),g=+v.toFixed(2);if(!(d<+Math.min(r,t).toFixed(2)||d>+Math.max(r,t).toFixed(2)||d<+Math.min(i,o).toFixed(2)||d>+Math.max(i,o).toFixed(2)||g<+Math.min(e,n).toFixed(2)||g>+Math.max(e,n).toFixed(2)||g<+Math.min(a,s).toFixed(2)||g>+Math.max(a,s).toFixed(2)))return{x:h,y:v}}}},pi=function(r,e,t){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height},mf=function(r,e,t,n){return r===null&&(r=e=t=n=0),e===null&&(e=r.y,t=r.width,n=r.height,r=r.x),{x:r,y:e,width:t,w:t,height:n,h:n,x2:r+t,y2:e+n,cx:r+t/2,cy:e+n/2,r1:Math.min(t,n)/2,r2:Math.max(t,n)/2,r0:Math.sqrt(t*t+n*n)/2,path:rectPath(r,e,t,n),vb:[r,e,t,n].join(" ")}},Mk=function(r,e){return r=mf(r),e=mf(e),pi(e,r.x,r.y)||pi(e,r.x2,r.y)||pi(e,r.x,r.y2)||pi(e,r.x2,r.y2)||pi(r,e.x,e.y)||pi(r,e.x2,e.y)||pi(r,e.x,e.y2)||pi(r,e.x2,e.y2)||(r.x<e.x2&&r.x>e.x||e.x<r.x2&&e.x>r.x)&&(r.y<e.y2&&r.y>e.y||e.y<r.y2&&e.y>r.y)},py=function(r,e,t,n,i,a,o,s){isArray(r)||(r=[r,e,t,n,i,a,o,s]);var l=mk.apply(null,r);return mf(l.min.x,l.min.y,l.max.x-l.min.x,l.max.y-l.min.y)},gy=function(r,e,t,n,i,a,o,s,l){var u=1-l,c=Math.pow(u,3),h=Math.pow(u,2),v=l*l,d=v*l,g=c*r+h*3*l*t+u*3*l*l*i+d*o,y=c*e+h*3*l*n+u*3*l*l*a+d*s,x=r+2*l*(t-r)+v*(i-2*t+r),m=e+2*l*(n-e)+v*(a-2*n+e),M=t+2*l*(i-t)+v*(o-2*i+t),w=n+2*l*(a-n)+v*(s-2*a+n),S=u*r+l*t,b=u*e+l*n,k=u*i+l*o,H=u*a+l*s,at=90-Math.atan2(x-M,m-w)*180/Math.PI;return{x:g,y,m:{x,y:m},n:{x:M,y:w},start:{x:S,y:b},end:{x:k,y:H},alpha:at}},wk=function(r,e,t){var n=py(r),i=py(e);if(!Mk(n,i))return t?0:[];for(var a=dy.apply(0,r),o=dy.apply(0,e),s=~~(a/8),l=~~(o/8),u=[],c=[],h={},v=t?0:[],d=0;d<s+1;d++){var g=gy.apply(0,r.concat(d/s));u.push({x:g.x,y:g.y,t:d/s})}for(var d=0;d<l+1;d++){var g=gy.apply(0,e.concat(d/l));c.push({x:g.x,y:g.y,t:d/l})}for(var d=0;d<s;d++)for(var y=0;y<l;y++){var x=u[d],m=u[d+1],M=c[y],w=c[y+1],S=Math.abs(m.x-x.x)<.001?"y":"x",b=Math.abs(w.x-M.x)<.001?"y":"x",k=xk(x.x,x.y,m.x,m.y,M.x,M.y,w.x,w.y);if(k){if(h[k.x.toFixed(4)]===k.y.toFixed(4))continue;h[k.x.toFixed(4)]=k.y.toFixed(4);var H=x.t+Math.abs((k[S]-x[S])/(m[S]-x[S]))*(m.t-x.t),at=M.t+Math.abs((k[b]-M[b])/(w[b]-M[b]))*(w.t-M.t);H>=0&&H<=1&&at>=0&&at<=1&&(t?v++:v.push({x:k.x,y:k.y,t1:H,t2:at}))}}return v},Sk=function(r,e,t){r=path2Curve(r),e=path2Curve(e);for(var n,i,a,o,s,l,u,c,h,v,d=t?0:[],g=0,y=r.length;g<y;g++){var x=r[g];if(x[0]==="M")n=s=x[1],i=l=x[2];else{x[0]==="C"?(h=[n,i].concat(x.slice(1)),n=h[6],i=h[7]):(h=[n,i,n,i,s,l,s,l],n=s,i=l);for(var m=0,M=e.length;m<M;m++){var w=e[m];if(w[0]==="M")a=u=w[1],o=c=w[2];else{w[0]==="C"?(v=[a,o].concat(w.slice(1)),a=v[6],o=v[7]):(v=[a,o,a,o,u,c,u,c],a=u,o=c);var S=wk(h,v,t);if(t)d+=S;else{for(var b=0,k=S.length;b<k;b++)S[b].segment1=g,S[b].segment2=m,S[b].bez1=h,S[b].bez2=v;d=d.concat(S)}}}}}return d};function B5(r,e){return Sk(r,e)}function Ck(r){return kt({},r.defaultStyle,{fill:r.color},r.style)}Ke("schema","venn",{draw:function(r,e){var t=r.data,n=hk(t[gf]),i=Ck(r),a=e.addGroup({name:"venn-shape"});a.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},i),{path:n}),name:"venn-path"});var o=r.customInfo,s=o.offsetX,l=o.offsetY,u=zr.transform(null,[["t",s,l]]);return a.setMatrix(u),a},getMarker:function(r){var e=r.color;return{symbol:"circle",style:{lineWidth:0,stroke:e,fill:e,r:4}}}});var Ak=function(r){return function(e,t){var n=[];return n[0]=r(e[0],t[0]),n[1]=r(e[1],t[1]),n[2]=r(e[2],t[2]),n}},yy={normal:function(r){return r},multiply:function(r,e){return r*e/255},screen:function(r,e){return 255*(1-(1-r/255)*(1-e/255))},overlay:function(r,e){return e<128?2*r*e/255:255*(1-2*(1-r/255)*(1-e/255))},darken:function(r,e){return r>e?e:r},lighten:function(r,e){return r>e?r:e},dodge:function(r,e){return r===255?255:(r=255*(e/255)/(1-r/255),r>255?255:r)},burn:function(r,e){return e===255?255:r===0?0:255*(1-Math.min(1,(1-e/255)/(r/255)))}},bk=function(r){if(!yy[r])throw new Error("unknown blend mode "+r);return yy[r]};function Tk(r,e,t){t===void 0&&(t="normal");var n=Ak(bk(t))(Ml(r),Ml(e)),i=Ml(r),a=i[0],o=i[1],s=i[2],l=i[3],u=Ml(e),c=u[0],h=u[1],v=u[2],d=u[3],g=Number((l+d*(1-l)).toFixed(2)),y=Math.round((l*(1-d)*(a/255)+l*d*(n[0]/255)+(1-l)*d*(c/255))/g*255),x=Math.round((l*(1-d)*(o/255)+l*d*(n[1]/255)+(1-l)*d*(h/255))/g*255),m=Math.round((l*(1-d)*(s/255)+l*d*(n[2]/255)+(1-l)*d*(v/255))/g*255);return"rgba(".concat(y,", ").concat(x,", ").concat(m,", ").concat(g,")")}function Ml(r){var e=r.replace("/s+/g",""),t;return typeof e=="string"&&!e.startsWith("rgba")&&!e.startsWith("#")?t=nn.rgb2arr(nn.toRGB(e)).concat([1]):(e.startsWith("rgba")&&(t=e.replace("rgba(","").replace(")","").split(",")),e.startsWith("#")&&(t=nn.rgb2arr(e).concat([1])),t.map(function(n,i){return i===3?Number(n):n|0}))}var In=N(87026),my=1e-10;function xf(r,e){var t=_k(r),n=t.filter(function(H){return Ek(H,r)}),i=0,a=0,o,s=[];if(n.length>1){var l=wy(n);for(o=0;o<n.length;++o){var u=n[o];u.angle=Math.atan2(u.x-l.x,u.y-l.y)}n.sort(function(H,at){return at.angle-H.angle});var c=n[n.length-1];for(o=0;o<n.length;++o){var h=n[o];a+=(c.x+h.x)*(h.y-c.y);for(var v={x:(h.x+c.x)/2,y:(h.y+c.y)/2},d=null,g=0;g<h.parentIndex.length;++g)if(c.parentIndex.indexOf(h.parentIndex[g])>-1){var y=r[h.parentIndex[g]],x=Math.atan2(h.x-y.x,h.y-y.y),m=Math.atan2(c.x-y.x,c.y-y.y),M=m-x;M<0&&(M+=2*Math.PI);var w=m-M/2,S=gn(v,{x:y.x+y.radius*Math.sin(w),y:y.y+y.radius*Math.cos(w)});S>y.radius*2&&(S=y.radius*2),(d===null||d.width>S)&&(d={circle:y,width:S,p1:h,p2:c})}d!==null&&(s.push(d),i+=Mf(d.circle.radius,d.width),c=h)}}else{var b=r[0];for(o=1;o<r.length;++o)r[o].radius<b.radius&&(b=r[o]);var k=!1;for(o=0;o<r.length;++o)if(gn(r[o],b)>Math.abs(b.radius-r[o].radius)){k=!0;break}k?i=a=0:(i=b.radius*b.radius*Math.PI,s.push({circle:b,p1:{x:b.x,y:b.y+b.radius},p2:{x:b.x-my,y:b.y+b.radius},width:b.radius*2}))}return a/=2,e&&(e.area=i+a,e.arcArea=i,e.polygonArea=a,e.arcs=s,e.innerPoints=n,e.intersectionPoints=t),i+a}function Ek(r,e){for(var t=0;t<e.length;++t)if(gn(r,e[t])>e[t].radius+my)return!1;return!0}function _k(r){for(var e=[],t=0;t<r.length;++t)for(var n=t+1;n<r.length;++n)for(var i=My(r[t],r[n]),a=0;a<i.length;++a){var o=i[a];o.parentIndex=[t,n],e.push(o)}return e}function Mf(r,e){return r*r*Math.acos(1-e/r)-(r-e)*Math.sqrt(e*(2*r-e))}function gn(r,e){return Math.sqrt((r.x-e.x)*(r.x-e.x)+(r.y-e.y)*(r.y-e.y))}function xy(r,e,t){if(t>=r+e)return 0;if(t<=Math.abs(r-e))return Math.PI*Math.min(r,e)*Math.min(r,e);var n=r-(t*t-e*e+r*r)/(2*t),i=e-(t*t-r*r+e*e)/(2*t);return Mf(r,n)+Mf(e,i)}function My(r,e){var t=gn(r,e),n=r.radius,i=e.radius;if(t>=n+i||t<=Math.abs(n-i))return[];var a=(n*n-i*i+t*t)/(2*t),o=Math.sqrt(n*n-a*a),s=r.x+a*(e.x-r.x)/t,l=r.y+a*(e.y-r.y)/t,u=-(e.y-r.y)*(o/t),c=-(e.x-r.x)*(o/t);return[{x:s+u,y:l-c},{x:s-u,y:l+c}]}function wy(r){for(var e={x:0,y:0},t=0;t<r.length;++t)e.x+=r[t].x,e.y+=r[t].y;return e.x/=r.length,e.y/=r.length,e}function wf(r,e,t){var n=e[0].radius-gn(e[0],r),i,a;for(i=1;i<e.length;++i)a=e[i].radius-gn(e[i],r),a<=n&&(n=a);for(i=0;i<t.length;++i)a=gn(t[i],r)-t[i].radius,a<=n&&(n=a);return n}function Sy(r,e){var t=[],n;for(n=0;n<r.length;++n){var i=r[n];t.push({x:i.x,y:i.y}),t.push({x:i.x+i.radius/2,y:i.y}),t.push({x:i.x-i.radius/2,y:i.y}),t.push({x:i.x,y:i.y+i.radius/2}),t.push({x:i.x,y:i.y-i.radius/2})}var a=t[0],o=wf(t[0],r,e);for(n=1;n<t.length;++n){var s=wf(t[n],r,e);s>=o&&(a=t[n],o=s)}var l=(0,In.nelderMead)(function(v){return-1*wf({x:v[0],y:v[1]},r,e)},[a.x,a.y],{maxIterations:500,minErrorDelta:1e-10}).x,u={x:l[0],y:l[1]},c=!0;for(n=0;n<r.length;++n)if(gn(u,r[n])>r[n].radius){c=!1;break}for(n=0;n<e.length;++n)if(gn(u,e[n])<e[n].radius){c=!1;break}if(!c)if(r.length==1)u={x:r[0].x,y:r[0].y};else{var h={};xf(r,h),h.arcs.length===0?u={x:0,y:-1e3,disjoint:!0}:h.arcs.length==1?u={x:h.arcs[0].circle.x,y:h.arcs[0].circle.y}:e.length?u=Sy(r,[]):u=wy(h.arcs.map(function(v){return v.p1}))}return u}function Fk(r){var e={},t=[];for(var n in r)t.push(n),e[n]=[];for(var i=0;i<t.length;i++)for(var a=r[t[i]],o=i+1;o<t.length;++o){var s=r[t[o]],l=gn(a,s);l+s.radius<=a.radius+1e-10?e[t[o]].push(t[i]):l+a.radius<=s.radius+1e-10&&e[t[i]].push(t[o])}return e}function Ik(r,e){for(var t={},n=Fk(r),i=0;i<e.length;++i){for(var a=e[i].sets,o={},s={},l=0;l<a.length;++l){o[a[l]]=!0;for(var u=n[a[l]],c=0;c<u.length;++c)s[u[c]]=!0}var h=[],v=[];for(var d in r)d in o?h.push(r[d]):d in s||v.push(r[d]);var g=Sy(h,v);t[a]=g,g.disjoint&&e[i].size>0&&console.log("WARNING: area "+a+" not represented on screen")}return t}function Pk(r,e,t){var n=[],i=r-t,a=e;return n.push("M",i,a),n.push("A",t,t,0,1,0,i+2*t,a),n.push("A",t,t,0,1,0,i,a),n.join(" ")}function R5(r){var e=r.split(" ");return{x:parseFloat(e[1]),y:parseFloat(e[2]),radius:-parseFloat(e[4])}}function Lk(r){var e={};xf(r,e);var t=e.arcs;if(t.length===0)return"M 0 0";if(t.length==1){var n=t[0].circle;return Pk(n.x,n.y,n.radius)}else{for(var i=[`
  94. M`,t[0].p2.x,t[0].p2.y],a=0;a<t.length;++a){var o=t[a],s=o.circle.radius,l=o.width>s;i.push(`
  95. A`,s,s,0,l?1:0,1,o.p1.x,o.p1.y)}return i.join(" ")}}function Dk(r,e){e=e||{},e.maxIterations=e.maxIterations||500;var t=e.initialLayout||Rk,n=e.lossFunction||Cf;r=Ok(r);var i=t(r,e),a=[],o=[],s;for(s in i)i.hasOwnProperty(s)&&(a.push(i[s].x),a.push(i[s].y),o.push(s));for(var l=(0,In.nelderMead)(function(h){for(var v={},d=0;d<o.length;++d){var g=o[d];v[g]={x:h[2*d],y:h[2*d+1],radius:i[g].radius}}return n(v,r)},a,e),u=l.x,c=0;c<o.length;++c)s=o[c],i[s].x=u[2*c],i[s].y=u[2*c+1];return i}var Cy=1e-10;function Sf(r,e,t){return Math.min(r,e)*Math.min(r,e)*Math.PI<=t+Cy?Math.abs(r-e):(0,In.bisect)(function(n){return xy(r,e,n)-t},0,r+e)}function Ok(r){r=r.slice();var e=[],t={},n,i,a,o;for(n=0;n<r.length;++n){var s=r[n];s.sets.length==1?e.push(s.sets[0]):s.sets.length==2&&(a=s.sets[0],o=s.sets[1],t[[a,o]]=!0,t[[o,a]]=!0)}for(e.sort(function(l,u){return l>u?1:-1}),n=0;n<e.length;++n)for(a=e[n],i=n+1;i<e.length;++i)o=e[i],[a,o]in t||r.push({sets:[a,o],size:0});return r}function kk(r,e,t){var n=(0,In.zerosM)(e.length,e.length),i=(0,In.zerosM)(e.length,e.length);return r.filter(function(a){return a.sets.length==2}).map(function(a){var o=t[a.sets[0]],s=t[a.sets[1]],l=Math.sqrt(e[o].size/Math.PI),u=Math.sqrt(e[s].size/Math.PI),c=Sf(l,u,a.size);n[o][s]=n[s][o]=c;var h=0;a.size+1e-10>=Math.min(e[o].size,e[s].size)?h=1:a.size<=1e-10&&(h=-1),i[o][s]=i[s][o]=h}),{distances:n,constraints:i}}function Bk(r,e,t,n){var i=0,a;for(a=0;a<e.length;++a)e[a]=0;for(a=0;a<t.length;++a)for(var o=r[2*a],s=r[2*a+1],l=a+1;l<t.length;++l){var u=r[2*l],c=r[2*l+1],h=t[a][l],v=n[a][l],d=(u-o)*(u-o)+(c-s)*(c-s),g=Math.sqrt(d),y=d-h*h;v>0&&g<=h||v<0&&g>=h||(i+=2*y*y,e[2*a]+=4*y*(o-u),e[2*a+1]+=4*y*(s-c),e[2*l]+=4*y*(u-o),e[2*l+1]+=4*y*(c-s))}return i}function Rk(r,e){var t=Uk(r,e),n=e.lossFunction||Cf;if(r.length>=8){var i=Nk(r,e),a=n(i,r),o=n(t,r);a+1e-8<o&&(t=i)}return t}function Nk(r,e){e=e||{};var t=e.restarts||10,n=[],i={},a;for(a=0;a<r.length;++a){var o=r[a];o.sets.length==1&&(i[o.sets[0]]=n.length,n.push(o))}var s=kk(r,n,i),l=s.distances,u=s.constraints,c=(0,In.norm2)(l.map(In.norm2))/l.length;l=l.map(function(M){return M.map(function(w){return w/c})});var h=function(M,w){return Bk(M,w,l,u)},v,d;for(a=0;a<t;++a){var g=(0,In.zeros)(l.length*2).map(Math.random);d=(0,In.conjugateGradient)(h,g,e),(!v||d.fx<v.fx)&&(v=d)}var y=v.x,x={};for(a=0;a<n.length;++a){var m=n[a];x[m.sets[0]]={x:y[2*a]*c,y:y[2*a+1]*c,radius:Math.sqrt(m.size/Math.PI)}}if(e.history)for(a=0;a<e.history.length;++a)(0,In.scale)(e.history[a].x,c);return x}function Uk(r,e){for(var t=e&&e.lossFunction?e.lossFunction:Cf,n={},i={},a,o=0;o<r.length;++o){var s=r[o];s.sets.length==1&&(a=s.sets[0],n[a]={x:1e10,y:1e10,rowid:Object.keys(n).length,size:s.size,radius:Math.sqrt(s.size/Math.PI)},i[a]=[])}r=r.filter(function(Gt){return Gt.sets.length==2});for(var o=0;o<r.length;++o){var l=r[o],u=l.hasOwnProperty("weight")?l.weight:1,c=l.sets[0],h=l.sets[1];l.size+Cy>=Math.min(n[c].size,n[h].size)&&(u=0),i[c].push({set:h,size:l.size,weight:u}),i[h].push({set:c,size:l.size,weight:u})}var v=[];for(a in i)if(i.hasOwnProperty(a)){for(var d=0,o=0;o<i[a].length;++o)d+=i[a][o].size*i[a][o].weight;v.push({set:a,size:d})}function g(Gt,ie){return ie.size-Gt.size}v.sort(g);var y={};function x(Gt){return Gt.set in y}function m(Gt,ie){n[ie].x=Gt.x,n[ie].y=Gt.y,y[ie]=!0}m({x:0,y:0},v[0].set);for(var o=1;o<v.length;++o){var M=v[o].set,w=i[M].filter(x);if(a=n[M],w.sort(g),w.length===0)throw"ERROR: missing pairwise overlap information";for(var S=[],b=0;b<w.length;++b){var k=n[w[b].set],H=Sf(a.radius,k.radius,w[b].size);S.push({x:k.x+H,y:k.y}),S.push({x:k.x-H,y:k.y}),S.push({y:k.y+H,x:k.x}),S.push({y:k.y-H,x:k.x});for(var at=b+1;at<w.length;++at)for(var At=n[w[at].set],gt=Sf(a.radius,At.radius,w[at].size),Nt=My({x:k.x,y:k.y,radius:H},{x:At.x,y:At.y,radius:gt}),te=0;te<Nt.length;++te)S.push(Nt[te])}for(var ce=1e50,Me=S[0],b=0;b<S.length;++b){n[M].x=S[b].x,n[M].y=S[b].y;var be=t(n,r);be<ce&&(ce=be,Me=S[b])}m(Me,M)}return n}function Cf(r,e){var t=0;function n(c){return c.map(function(h){return r[h]})}for(var i=0;i<e.length;++i){var a=e[i],o=void 0;if(a.sets.length!=1){if(a.sets.length==2){var s=r[a.sets[0]],l=r[a.sets[1]];o=xy(s.radius,l.radius,gn(s,l))}else o=xf(n(a.sets));var u=a.hasOwnProperty("weight")?a.weight:1;t+=u*(o-a.size)*(o-a.size)}}return t}function zk(r,e,t){t===null?r.sort(function(y,x){return x.radius-y.radius}):r.sort(t);var n;if(r.length>0){var i=r[0].x,a=r[0].y;for(n=0;n<r.length;++n)r[n].x-=i,r[n].y-=a}if(r.length==2){var o=distance(r[0],r[1]);o<Math.abs(r[1].radius-r[0].radius)&&(r[1].x=r[0].x+r[0].radius-r[1].radius-1e-10,r[1].y=r[0].y)}if(r.length>1){var s=Math.atan2(r[1].x,r[1].y)-e,l=void 0,u=void 0,c=Math.cos(s),h=Math.sin(s);for(n=0;n<r.length;++n)l=r[n].x,u=r[n].y,r[n].x=c*l-h*u,r[n].y=h*l+c*u}if(r.length>2){for(var v=Math.atan2(r[2].x,r[2].y)-e;v<0;)v+=2*Math.PI;for(;v>2*Math.PI;)v-=2*Math.PI;if(v>Math.PI){var d=r[1].y/(1e-10+r[1].x);for(n=0;n<r.length;++n){var g=(r[n].x+d*r[n].y)/(1+d*d);r[n].x=2*g-r[n].x,r[n].y=2*g*d-r[n].y}}}}function Vk(r){r.map(function(u){u.parent=u});function e(u){return u.parent!==u&&(u.parent=e(u.parent)),u.parent}function t(u,c){var h=e(u),v=e(c);h.parent=v}for(var n=0;n<r.length;++n)for(var i=n+1;i<r.length;++i){var a=r[n].radius+r[i].radius;distance(r[n],r[i])+1e-10<a&&t(r[i],r[n])}for(var o={},s,n=0;n<r.length;++n)s=e(r[n]).parent.setid,s in o||(o[s]=[]),o[s].push(r[n]);r.map(function(u){delete u.parent});var l=[];for(s in o)o.hasOwnProperty(s)&&l.push(o[s]);return l}function Af(r){var e=function(t){var n=Math.max.apply(null,r.map(function(a){return a[t]+a.radius})),i=Math.min.apply(null,r.map(function(a){return a[t]-a.radius}));return{max:n,min:i}};return{xRange:e("x"),yRange:e("y")}}function N5(r,e,t){e===null&&(e=Math.PI/2);var n=[],i,a;for(a in r)if(r.hasOwnProperty(a)){var o=r[a];n.push({x:o.x,y:o.y,radius:o.radius,setid:a})}var s=Vk(n);for(i=0;i<s.length;++i){zk(s[i],e,t);var l=Af(s[i]);s[i].size=(l.xRange.max-l.xRange.min)*(l.yRange.max-l.yRange.min),s[i].bounds=l}s.sort(function(g,y){return y.size-g.size}),n=s[0];var u=n.bounds,c=(u.xRange.max-u.xRange.min)/50;function h(g,y,x){if(!!g){var m=g.bounds,M,w,S;y?M=u.xRange.max-m.xRange.min+c:(M=u.xRange.max-m.xRange.max,S=(m.xRange.max-m.xRange.min)/2-(u.xRange.max-u.xRange.min)/2,S<0&&(M+=S)),x?w=u.yRange.max-m.yRange.min+c:(w=u.yRange.max-m.yRange.max,S=(m.yRange.max-m.yRange.min)/2-(u.yRange.max-u.yRange.min)/2,S<0&&(w+=S));for(var b=0;b<g.length;++b)g[b].x+=M,g[b].y+=w,n.push(g[b])}}for(var v=1;v<s.length;)h(s[v],!0,!1),h(s[v+1],!1,!0),h(s[v+2],!0,!0),v+=3,u=Af(n);var d={};for(i=0;i<n.length;++i)d[n[i].setid]=n[i];return d}function Hk(r,e,t,n){var i=[],a=[];for(var o in r)r.hasOwnProperty(o)&&(a.push(o),i.push(r[o]));e-=2*n,t-=2*n;var s=Af(i),l=s.xRange,u=s.yRange;if(l.max==l.min||u.max==u.min)return console.log("not scaling solution: zero size detected"),r;for(var c=e/(l.max-l.min),h=t/(u.max-u.min),v=Math.min(h,c),d=(e-(l.max-l.min)*v)/2,g=(t-(u.max-u.min)*v)/2,y={},x=0;x<i.length;++x){var m=i[x];y[a[x]]={radius:v*m.radius,x:n+d+(m.x-l.min)*v,y:n+g+(m.y-u.min)*v}}return y}var Gk=(0,f.HP)(function(r,e,t,n){var i=new Map,a=r.length;return e.forEach(function(o,s){if(o[n].length===1)i.set(o[Zn],r[(s+a)%a]);else{var l=o[n].map(function(u){return i.get(u)});i.set(o[Zn],l.slice(1).reduce(function(u,c){return Tk(u,c,t)},l[0]))}}),i},function(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return JSON.stringify(r)});function Yk(r,e,t,n){n===void 0&&(n=0);var i=r.data,a=r.setsField,o=r.sizeField;if(i.length===0)return Hn(pn.WARN,!1,"warn: %s","\u6570\u636E\u4E0D\u80FD\u4E3A\u7A7A"),[];var s=i.map(function(h){var v;return(0,p.pi)((0,p.pi)({},h),(v={sets:h[a]||[],size:h[o]},v[gf]="",v[Zn]="",v))});s.sort(function(h,v){return h.sets.length-v.sets.length});var l=Dk(s),u=Hk(l,e,t,n),c=Ik(u,s);return s.forEach(function(h){var v=h.sets,d=v.join(",");h[Zn]=d;var g=v.map(function(m){return u[m]}),y=Lk(g);/[zZ]$/.test(y)||(y+=" Z"),h[gf]=y;var x=c[d]||{x:0,y:0};(0,f.f0)(h,x)}),s}function Xk(r,e){for(var t=0;t<e.length;t++)if(!r.includes(e[t]))return!1;return!0}var Wk=40;function Ay(r,e,t){var n=r.chart,i=r.options,a=i.blendMode,o=i.setsField,s=n.getTheme(),l=s.colors10,u=s.colors20,c=t;(0,f.kJ)(c)||(c=e.filter(function(v){return v[o].length===1}).length<=10?l:u);var h=Gk(c,e,a,o);return function(v){return h.get(v)||c[0]}}function Zk(r,e){var t=r.options,n=t.color;if(typeof n!="function"){var i=typeof n=="string"?[n]:n,a=Ay(r,e,i);return function(o){return a(o[Zn])}}return n}function $k(r){var e=r.chart,t=r.options,n=t.legend,i=t.appendPadding,a=t.padding,o=fi(i);return n!==!1&&(o=$s(i,(0,f.U2)(n,"position"),Wk)),e.appendPadding=Oc([o,a]),r}function qk(r){var e=r.options,t=e.data;t||(Hn(pn.WARN,!1,"warn: %s","\u6570\u636E\u4E0D\u80FD\u4E3A\u7A7A"),t=[]);var n=t.filter(function(a){return a.sets.length===1}).map(function(a){return a.sets[0]}),i=t.filter(function(a){var o=a.sets;return Xk(n,o)});return(0,f.Xy)(i,t)||Hn(pn.WARN,!1,"warn: %s","\u4EA4\u96C6\u4E2D\u4E0D\u80FD\u51FA\u73B0\u4E0D\u5B58\u5728\u7684\u96C6\u5408, \u8BF7\u8F93\u5165\u5408\u6CD5\u6570\u636E"),(0,f.b$)({},r,{options:{data:i}})}function Kk(r){var e=r.chart,t=r.options,n=t.pointStyle,i=t.setsField,a=t.sizeField,o=fi(e.appendPadding),s=o[0],l=o[1],u=o[2],c=o[3],h={offsetX:c,offsetY:s},v=e.viewBBox,d=v.width,g=v.height,y=Yk(t,Math.max(d-(l+c),0),Math.max(g-(s+u),0),0);e.data(y);var x=Uc(kt({},r,{options:{xField:"x",yField:"y",sizeField:a,seriesField:Zn,rawFields:[i,a],schema:{shape:"venn",style:n}}})).ext,m=x.geometry;m.customInfo(h);var M=Zk(r,y);return typeof M=="function"&&m.color(Zn,function(w){var S=y.find(function(k){return k[Zn]===w}),b=Ay(r,y)(w);return M(S,b)}),r}function jk(r){var e=r.chart,t=r.options,n=t.label,i=fi(e.appendPadding),a=i[0],o=i[3],s={offsetX:o,offsetY:a},l=br(e,"schema");if(!n)l.label(!1);else{var u=n.callback,c=(0,p._T)(n,["callback"]);l.label({fields:["id"],callback:u,cfg:(0,f.b$)({},xr(c),{type:"venn",customLabelInfo:s})})}return r}function Jk(r){var e=r.chart,t=r.options,n=t.legend,i=t.sizeField;return e.legend(Zn,n),e.legend(i,!1),r}function Qk(r){var e=r.chart;return e.axis(!1),r}function tB(r){var e=r.options,t=r.chart,n=e.interactions;if(n){var i={"legend-active":"venn-legend-active","legend-highlight":"venn-legend-highlight"};or(kt({},r,{options:{interactions:n.map(function(a){return(0,p.pi)((0,p.pi)({},a),{type:i[a.type]||a.type})})}}))}return t.removeInteraction("legend-active"),t.removeInteraction("legend-highlight"),r}function eB(r){return Fe($k,We,qk,Kk,jk,ur({}),Jk,Qk,pr,tB,tr)(r)}var U5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="venn",t}return e.getDefaultOptions=function(){return JO},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return eB},e.prototype.triggerResize=function(){this.chart.destroyed||(this.chart.forceFit(),this.chart.clear(),this.execAdaptor(),this.chart.render(!0))},e}(Re),ln="x",Yi="violinY",rB="violinSize",by="minMax",Ty="quantile",Ey="median",bf="violin_view",nB="min_max_view",iB="quantile_view",aB="median_view",oB=kt({},Re.getDefaultOptions(),{syncViewPadding:!0,kde:{type:"triangular",sampleSize:32,width:3},violinStyle:{lineWidth:1,fillOpacity:.3,strokeOpacity:.75},xAxis:{grid:{line:null},tickLine:{alignTick:!1}},yAxis:{grid:{line:{style:{lineWidth:.5,lineDash:[4,4]}}}},legend:{position:"top-left"},tooltip:{showMarkers:!1}}),sB=N(53843),lB=N.n(sB);function _y(r,e){var t=r.length*e;if(r.length===0)throw new Error("quantile requires at least one data point.");if(e<0||e>1)throw new Error("quantiles must be between 0 and 1");return e===1?r[r.length-1]:e===0?r[0]:t%1!=0?r[Math.ceil(t)-1]:r.length%2==0?(r[t-1]+r[t])/2:r[t]}function Lo(r,e,t){var n=r[e];r[e]=r[t],r[t]=n}function wl(r,e,t,n){for(t=t||0,n=n||r.length-1;n>t;){if(n-t>600){var i=n-t+1,a=e-t+1,o=Math.log(i),s=.5*Math.exp(2*o/3),l=.5*Math.sqrt(o*s*(i-s)/i);a-i/2<0&&(l*=-1);var u=Math.max(t,Math.floor(e-a*s/i+l)),c=Math.min(n,Math.floor(e+(i-a)*s/i+l));wl(r,e,u,c)}var h=r[e],v=t,d=n;for(Lo(r,t,e),r[n]>h&&Lo(r,t,n);v<d;){for(Lo(r,v,d),v++,d--;r[v]<h;)v++;for(;r[d]>h;)d--}r[t]===h?Lo(r,t,d):(d++,Lo(r,d,n)),d<=e&&(t=d+1),e<=d&&(n=d-1)}}function Do(r,e){var t=r.slice();if(Array.isArray(e)){uB(t,e);for(var n=[],i=0;i<e.length;i++)n[i]=_y(t,e[i]);return n}else{var a=Iy(t.length,e);return Fy(t,a,0,t.length-1),_y(t,e)}}function Fy(r,e,t,n){e%1==0?wl(r,e,t,n):(e=Math.floor(e),wl(r,e,t,n),wl(r,e+1,e+1,n))}function uB(r,e){for(var t=[0],n=0;n<e.length;n++)t.push(Iy(r.length,e[n]));t.push(r.length-1),t.sort(cB);for(var i=[0,t.length-1];i.length;){var a=Math.ceil(i.pop()),o=Math.floor(i.pop());if(!(a-o<=1)){var s=Math.floor((o+a)/2);Fy(r,t[s],Math.floor(t[o]),Math.ceil(t[a])),i.push(o,s,s,a)}}}function cB(r,e){return r-e}function Iy(r,e){var t=r*e;return e===1?r-1:e===0?0:t%1!=0?Math.ceil(t)-1:r%2==0?t-.5:t}var Py=function(r){return{low:(0,f.VV)(r),high:(0,f.Fp)(r),q1:Do(r,.25),q3:Do(r,.75),median:Do(r,[.5]),minMax:[(0,f.VV)(r),(0,f.Fp)(r)],quantile:[Do(r,.25),Do(r,.75)]}},Ly=function(r,e){var t=lB().create(r,e);return{violinSize:t.map(function(n){return n.y}),violinY:t.map(function(n){return n.x})}},Dy=function(r){var e=r.xField,t=r.yField,n=r.seriesField,i=r.data,a=r.kde,o={min:a.min,max:a.max,size:a.sampleSize,width:a.width};if(!n){var s=(0,f.vM)(i,e);return Object.keys(s).map(function(c){var h=s[c],v=h.map(function(d){return d[t]});return(0,p.pi)((0,p.pi)({x:c},Ly(v,o)),Py(v))})}var l=[],u=(0,f.vM)(i,n);return Object.keys(u).forEach(function(c){var h=(0,f.vM)(u[c],e);return Object.keys(h).forEach(function(v){var d,g=h[v],y=g.map(function(x){return x[t]});l.push((0,p.pi)((0,p.pi)((d={x:v},d[n]=c,d),Ly(y,o)),Py(y)))})}),l},Sl=["low","high","q1","q3","median"],Cl=[{type:"dodge",marginRatio:1/32}];function fB(r){var e=r.chart,t=r.options;return e.data(Dy(t)),r}function hB(r){var e=r.chart,t=r.options,n=t.seriesField,i=t.color,a=t.shape,o=a===void 0?"violin":a,s=t.violinStyle,l=t.tooltip,u=t.state,c=e.createView({id:bf});return u_({chart:c,options:{xField:ln,yField:Yi,seriesField:n||ln,sizeField:rB,tooltip:(0,p.pi)({fields:Sl},l),violin:{style:s,color:i,shape:o},state:u}}),c.geometries[0].adjust(Cl),r}function vB(r){var e=r.chart,t=r.options,n=t.seriesField,i=t.color,a=t.tooltip,o=t.box;if(o===!1)return r;var s=e.createView({id:nB});Tr({chart:s,options:{xField:ln,yField:by,seriesField:n||ln,tooltip:(0,p.pi)({fields:Sl},a),state:typeof o=="object"?o.state:{},interval:{color:i,size:1,style:{lineWidth:0}}}}),s.geometries[0].adjust(Cl);var l=e.createView({id:iB});Tr({chart:l,options:{xField:ln,yField:Ty,seriesField:n||ln,tooltip:(0,p.pi)({fields:Sl},a),state:typeof o=="object"?o.state:{},interval:{color:i,size:8,style:{fillOpacity:1}}}}),l.geometries[0].adjust(Cl);var u=e.createView({id:aB});return jr({chart:u,options:{xField:ln,yField:Ey,seriesField:n||ln,tooltip:(0,p.pi)({fields:Sl},a),state:typeof o=="object"?o.state:{},point:{color:i,size:1,style:{fill:"white",lineWidth:0}}}}),u.geometries[0].adjust(Cl),l.axis(!1),s.axis(!1),u.axis(!1),u.legend(!1),s.legend(!1),l.legend(!1),r}function dB(r){var e,t=r.chart,n=r.options,i=n.meta,a=n.xAxis,o=n.yAxis,s={},l=kt(s,i,(e={},e[ln]=(0,p.pi)((0,p.pi)({sync:!0},Qe(a,Hr)),{type:"cat"}),e[Yi]=(0,p.pi)({sync:!0},Qe(o,Hr)),e[by]=(0,p.pi)({sync:Yi},Qe(o,Hr)),e[Ty]=(0,p.pi)({sync:Yi},Qe(o,Hr)),e[Ey]=(0,p.pi)({sync:Yi},Qe(o,Hr)),e));return t.scale(l),r}function pB(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=Ve(e,bf);return n===!1?a.axis(ln,!1):a.axis(ln,n),i===!1?a.axis(Yi,!1):a.axis(Yi,i),e.axis(!1),r}function gB(r){var e=r.chart,t=r.options,n=t.legend,i=t.seriesField,a=t.shape;if(n===!1)e.legend(!1);else{var o=i||ln,s=(0,f.CE)(n,["selected"]);(!a||!a.startsWith("hollow"))&&((0,f.U2)(s,["marker","style","lineWidth"])||(0,f.t8)(s,["marker","style","lineWidth"],0)),e.legend(o,s),(0,f.U2)(n,"selected")&&(0,f.S6)(e.views,function(l){return l.legend(o,n)})}return r}function yB(r){var e=r.chart,t=Ve(e,bf);return sr()((0,p.pi)((0,p.pi)({},r),{chart:t})),r}function mB(r){var e=r.chart,t=r.options,n=t.animation;return(0,f.S6)(e.views,function(i){mo(i,n)}),r}function xB(r){return Fe(We,fB,hB,vB,dB,pr,pB,gB,or,yB,mB)(r)}var z5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="violin",t}return e.getDefaultOptions=function(){return oB},e.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(Dy(this.options))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return xB},e}(Re),un="$$yField$$",Al="$$diffField$$",Tf="$$absoluteField$$",Ef="$$isTotal$$",MB={label:{},leaderLine:{style:{lineWidth:1,stroke:"#8c8c8c",lineDash:[4,2]}},total:{style:{fill:"rgba(0, 0, 0, 0.25)"}},interactions:[{type:"element-active"}],risingFill:"#f4664a",fallingFill:"#30bf78",waterfallStyle:{fill:"rgba(0, 0, 0, 0.25)"},yAxis:{grid:{line:{style:{lineDash:[4,2]}}}}};function wB(r){for(var e=[],t=0;t<r.length;t++){var n=r[t];if(n){var i=t===0?"M":"L";e.push([i,n.x,n.y])}}var a=r[0];return e.push(["L",a.x,a.y]),e.push(["z"]),e}function SB(r){return kt({},r.defaultStyle,r.style,{fill:r.color})}Ke("interval","waterfall",{draw:function(r,e){var t=r.customInfo,n=r.points,i=r.nextPoints,a=e.addGroup(),o=this.parsePath(wB(n)),s=SB(r);a.addShape("path",{attrs:(0,p.pi)((0,p.pi)({},s),{path:o})});var l=(0,f.U2)(t,"leaderLine");if(l&&i){var u=[["M",n[2].x,n[2].y],["L",i[0].x,i[0].y]];n[2].y===i[1].y&&(u[1]=["L",i[1].x,i[1].y]),u=this.parsePath(u),a.addShape("path",{attrs:(0,p.pi)({path:u},l.style||{})})}return a}});function CB(r,e,t,n,i){var a,o=[];if((0,f.u4)(r,function(l,u){var c;Hn(pn.WARN,(0,f.hj)(u[t]),"".concat(u[t]," is not a valid number"));var h=(0,f.o8)(u[t])?null:u[t];return o.push((0,p.pi)((0,p.pi)({},u),(c={},c[n]=[l,l+h],c))),l+h},0),o.length&&i){var s=(0,f.U2)(o,[[r.length-1],n,[1]]);o.push((a={},a[e]=i.label,a[t]=s,a[n]=[0,s],a))}return o}function Oy(r,e,t,n){var i=CB(r,e,t,un,n);return i.map(function(a,o){var s;return(0,f.Kn)(a)?(0,p.pi)((0,p.pi)({},a),(s={},s[Tf]=a[un][1],s[Al]=a[un][1]-a[un][0],s[Ef]=o===r.length,s)):a})}function AB(r){var e=r.options,t=e.locale,n=e.total,i=Js(t).get(["waterfall","total"]);return n&&typeof n.label!="string"&&i&&(r.options.total.label=i),r}function bB(r){var e=r.chart,t=r.options,n=t.data,i=t.xField,a=t.yField,o=t.total,s=t.leaderLine,l=t.columnWidthRatio,u=t.waterfallStyle,c=t.risingFill,h=t.fallingFill,v=t.color,d=t.shape,g=t.customInfo;e.data(Oy(n,i,a,o));var y=v||function(w){return(0,f.U2)(w,[Ef])?(0,f.U2)(o,["style","fill"],""):(0,f.U2)(w,[un,1])-(0,f.U2)(w,[un,0])>0?c:h},x=kt({},r,{options:{xField:i,yField:un,seriesField:i,rawFields:[a,Al,Ef,un],widthRatio:l,interval:{style:u,shape:d||"waterfall",color:y}}}),m=Tr(x).ext,M=m.geometry;return M.customInfo((0,p.pi)((0,p.pi)({},g),{leaderLine:s})),r}function TB(r){var e,t,n=r.options,i=n.xAxis,a=n.yAxis,o=n.xField,s=n.yField,l=n.meta,u=kt({},{alias:s},(0,f.U2)(l,s));return Fe(ur((e={},e[o]=i,e[s]=a,e[un]=a,e),kt({},l,(t={},t[un]=u,t[Al]=u,t[Tf]=u,t))))(r)}function EB(r){var e=r.chart,t=r.options,n=t.xAxis,i=t.yAxis,a=t.xField,o=t.yField;return n===!1?e.axis(a,!1):e.axis(a,n),i===!1?(e.axis(o,!1),e.axis(un,!1)):(e.axis(o,i),e.axis(un,i)),r}function _B(r){var e=r.chart,t=r.options,n=t.legend,i=t.total,a=t.risingFill,o=t.fallingFill,s=t.locale,l=Js(s);if(n===!1)e.legend(!1);else{var u=[{name:l.get(["general","increase"]),value:"increase",marker:{symbol:"square",style:{r:5,fill:a}}},{name:l.get(["general","decrease"]),value:"decrease",marker:{symbol:"square",style:{r:5,fill:o}}}];i&&u.push({name:i.label||"",value:"total",marker:{symbol:"square",style:kt({},{r:5},(0,f.U2)(i,"style"))}}),e.legend(kt({},{custom:!0,position:"top",items:u},n)),e.removeInteraction("legend-filter")}return r}function FB(r){var e=r.chart,t=r.options,n=t.label,i=t.labelMode,a=t.xField,o=br(e,"interval");if(!n)o.label(!1);else{var s=n.callback,l=(0,p._T)(n,["callback"]);o.label({fields:i==="absolute"?[Tf,a]:[Al,a],callback:s,cfg:xr(l)})}return r}function IB(r){var e=r.chart,t=r.options,n=t.tooltip,i=t.xField,a=t.yField;if(n!==!1){e.tooltip((0,p.pi)({showCrosshairs:!1,showMarkers:!1,shared:!0,fields:[a]},n));var o=e.geometries[0];(n==null?void 0:n.formatter)?o.tooltip("".concat(i,"*").concat(a),n.formatter):o.tooltip(a)}else e.tooltip(!1);return r}function PB(r){return Fe(AB,We,bB,TB,EB,_B,IB,FB,hi,or,tr,sr())(r)}var V5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="waterfall",t}return e.getDefaultOptions=function(){return MB},e.prototype.changeData=function(t){var n=this.options,i=n.xField,a=n.yField,o=n.total;this.updateOption({data:t}),this.chart.changeData(Oy(t,i,a,o))},e.prototype.getSchemaAdaptor=function(){return PB},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(Re),_f="color",LB=kt({},Re.getDefaultOptions(),{timeInterval:2e3,legend:!1,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!1,fields:["text","value",_f],formatter:function(r){return{name:r.text,value:r.value}}},wordStyle:{fontFamily:"Verdana",fontWeight:"normal",padding:1,fontSize:[12,60],rotation:[0,90],rotationSteps:2,rotateRatio:.5}}),DB={font:function(){return"serif"},padding:1,size:[500,500],spiral:"archimedean",timeInterval:3e3};function OB(r,e){return e=(0,f.f0)({},DB,e),kB(r,e)}function kB(r,e){var t=$B();["font","fontSize","fontWeight","padding","rotate","size","spiral","timeInterval","random"].forEach(function(l){(0,f.UM)(e[l])||t[l](e[l])}),t.words(r),e.imageMask&&t.createMask(e.imageMask);var n=t.start(),i=n._tags;i.forEach(function(l){l.x+=e.size[0]/2,l.y+=e.size[1]/2});var a=e.size,o=a[0],s=a[1];return i.push({text:"",value:0,x:0,y:0,opacity:0}),i.push({text:"",value:0,x:o,y:s,opacity:0}),i}var Ff=Math.PI/180,Oo=1<<11>>5,bl=1<<11;function BB(r){return r.text}function RB(){return"serif"}function ky(){return"normal"}function NB(r){return r.value}function UB(){return~~(Math.random()*2)*90}function zB(){return 1}function VB(r,e,t,n){if(!e.sprite){var i=r.context,a=r.ratio;i.clearRect(0,0,(Oo<<5)/a,bl/a);var o=0,s=0,l=0,u=t.length;for(--n;++n<u;){e=t[n],i.save(),i.font=e.style+" "+e.weight+" "+~~((e.size+1)/a)+"px "+e.font;var c=i.measureText(e.text+"m").width*a,h=e.size<<1;if(e.rotate){var v=Math.sin(e.rotate*Ff),d=Math.cos(e.rotate*Ff),g=c*d,y=c*v,x=h*d,m=h*v;c=Math.max(Math.abs(g+m),Math.abs(g-m))+31>>5<<5,h=~~Math.max(Math.abs(y+x),Math.abs(y-x))}else c=c+31>>5<<5;if(h>l&&(l=h),o+c>=Oo<<5&&(o=0,s+=l,l=0),s+h>=bl)break;i.translate((o+(c>>1))/a,(s+(h>>1))/a),e.rotate&&i.rotate(e.rotate*Ff),i.fillText(e.text,0,0),e.padding&&(i.lineWidth=2*e.padding,i.strokeText(e.text,0,0)),i.restore(),e.width=c,e.height=h,e.xoff=o,e.yoff=s,e.x1=c>>1,e.y1=h>>1,e.x0=-e.x1,e.y0=-e.y1,e.hasText=!0,o+=c}for(var M=i.getImageData(0,0,(Oo<<5)/a,bl/a).data,w=[];--n>=0;)if(e=t[n],!!e.hasText){for(var c=e.width,S=c>>5,h=e.y1-e.y0,b=0;b<h*S;b++)w[b]=0;if(o=e.xoff,o==null)return;s=e.yoff;for(var k=0,H=-1,at=0;at<h;at++){for(var b=0;b<c;b++){var At=S*at+(b>>5),gt=M[(s+at)*(Oo<<5)+(o+b)<<2]?1<<31-b%32:0;w[At]|=gt,k|=gt}k?H=at:(e.y0++,h--,at--,s++)}e.y1=e.y0+H,e.sprite=w.slice(0,(e.y1-e.y0)*S)}}}function HB(r,e,t){t>>=5;for(var n=r.sprite,i=r.width>>5,a=r.x-(i<<4),o=a&127,s=32-o,l=r.y1-r.y0,u=(r.y+r.y0)*t+(a>>5),c,h=0;h<l;h++){c=0;for(var v=0;v<=i;v++)if((c<<s|(v<i?(c=n[h*i+v])>>>o:0))&e[u+v])return!0;u+=t}return!1}function GB(r,e){var t=r[0],n=r[1];e.x+e.x0<t.x&&(t.x=e.x+e.x0),e.y+e.y0<t.y&&(t.y=e.y+e.y0),e.x+e.x1>n.x&&(n.x=e.x+e.x1),e.y+e.y1>n.y&&(n.y=e.y+e.y1)}function YB(r,e){return r.x+r.x1>e[0].x&&r.x+r.x0<e[1].x&&r.y+r.y1>e[0].y&&r.y+r.y0<e[1].y}function By(r){var e=r[0]/r[1];return function(t){return[e*(t*=.1)*Math.cos(t),t*Math.sin(t)]}}function XB(r){var e=4,t=e*r[0]/r[1],n=0,i=0;return function(a){var o=a<0?-1:1;switch(Math.sqrt(1+4*o*a)-o&3){case 0:n+=t;break;case 1:i+=e;break;case 2:n-=t;break;default:i-=e;break}return[n,i]}}function Ry(r){for(var e=[],t=-1;++t<r;)e[t]=0;return e}function WB(){return document.createElement("canvas")}function Pn(r){return(0,f.mf)(r)?r:function(){return r}}var ZB={archimedean:By,rectangular:XB};function $B(){var r=[256,256],e=RB,t=NB,n=ky,i=UB,a=zB,o=By,s=Math.random,l=[],u=Infinity,c=BB,h=ky,v=WB,d={};d.start=function(){var x=r[0],m=r[1],M=g(v()),w=d.board?d.board:Ry((r[0]>>5)*r[1]),S=l.length,b=[],k=l.map(function(gt,Nt,te){return gt.text=c.call(this,gt,Nt,te),gt.font=e.call(this,gt,Nt,te),gt.style=h.call(this,gt,Nt,te),gt.weight=n.call(this,gt,Nt,te),gt.rotate=i.call(this,gt,Nt,te),gt.size=~~t.call(this,gt,Nt,te),gt.padding=a.call(this,gt,Nt,te),gt}).sort(function(gt,Nt){return Nt.size-gt.size}),H=-1,at=d.board?[{x:0,y:0},{x,y:m}]:null;At();function At(){for(var gt=Date.now();Date.now()-gt<u&&++H<S;){var Nt=k[H];Nt.x=x*(s()+.5)>>1,Nt.y=m*(s()+.5)>>1,VB(M,Nt,k,H),Nt.hasText&&y(w,Nt,at)&&(b.push(Nt),at?d.hasImage||GB(at,Nt):at=[{x:Nt.x+Nt.x0,y:Nt.y+Nt.y0},{x:Nt.x+Nt.x1,y:Nt.y+Nt.y1}],Nt.x-=r[0]>>1,Nt.y-=r[1]>>1)}d._tags=b,d._bounds=at}return d};function g(x){x.width=x.height=1;var m=Math.sqrt(x.getContext("2d",{willReadFrequently:!0}).getImageData(0,0,1,1).data.length>>2);x.width=(Oo<<5)/m,x.height=bl/m;var M=x.getContext("2d",{willReadFrequently:!0});return M.fillStyle=M.strokeStyle="red",M.textAlign="center",{context:M,ratio:m}}function y(x,m,M){for(var w=m.x,S=m.y,b=Math.sqrt(r[0]*r[0]+r[1]*r[1]),k=o(r),H=s()<.5?1:-1,at,At=-H,gt,Nt;(at=k(At+=H))&&(gt=~~at[0],Nt=~~at[1],!(Math.min(Math.abs(gt),Math.abs(Nt))>=b));)if(m.x=w+gt,m.y=S+Nt,!(m.x+m.x0<0||m.y+m.y0<0||m.x+m.x1>r[0]||m.y+m.y1>r[1])&&(!M||!HB(m,x,r[0]))&&(!M||YB(m,M))){for(var te=m.sprite,ce=m.width>>5,Me=r[0]>>5,be=m.x-(ce<<4),Gt=be&127,ie=32-Gt,de=m.y1-m.y0,ue=void 0,pe=(m.y+m.y0)*Me+(be>>5),Ee=0;Ee<de;Ee++){ue=0;for(var Ne=0;Ne<=ce;Ne++)x[pe+Ne]|=ue<<ie|(Ne<ce?(ue=te[Ee*ce+Ne])>>>Gt:0);pe+=Me}return delete m.sprite,!0}return!1}return d.createMask=function(x){var m=document.createElement("canvas"),M=r[0],w=r[1];if(!(!M||!w)){var S=M>>5,b=Ry((M>>5)*w);m.width=M,m.height=w;var k=m.getContext("2d");k.drawImage(x,0,0,x.width,x.height,0,0,M,w);for(var H=k.getImageData(0,0,M,w).data,at=0;at<w;at++)for(var At=0;At<M;At++){var gt=S*at+(At>>5),Nt=at*M+At<<2,te=H[Nt]>=250&&H[Nt+1]>=250&&H[Nt+2]>=250,ce=te?1<<31-At%32:0;b[gt]|=ce}d.board=b,d.hasImage=!0}},d.timeInterval=function(x){u=x==null?Infinity:x},d.words=function(x){l=x},d.size=function(x){r=[+x[0],+x[1]]},d.font=function(x){e=Pn(x)},d.fontWeight=function(x){n=Pn(x)},d.rotate=function(x){i=Pn(x)},d.spiral=function(x){o=ZB[x]||x},d.fontSize=function(x){t=Pn(x)},d.padding=function(x){a=Pn(x)},d.random=function(x){s=Pn(x)},d}function Ny(r){var e=r.options,t=r.chart,n=t,i=n.width,a=n.height,o=n.padding,s=n.appendPadding,l=n.ele,u=e.data,c=e.imageMask,h=e.wordField,v=e.weightField,d=e.colorField,g=e.wordStyle,y=e.timeInterval,x=e.random,m=e.spiral,M=e.autoFit,w=M===void 0?!0:M,S=e.placementStrategy;if(!u||!u.length)return[];var b=g.fontFamily,k=g.fontWeight,H=g.padding,at=g.fontSize,At=QB(u,v),gt=[rR(At),nR(At)],Nt=u.map(function(Me){return{text:Me[h],value:Me[v],color:Me[d],datum:Me}}),te={imageMask:c,font:b,fontSize:JB(at,gt),fontWeight:k,size:qB({width:i,height:a,padding:o,appendPadding:s,autoFit:w,container:l}),padding:H,timeInterval:y,random:x,spiral:m,rotate:tR(e)};if((0,f.mf)(S)){var ce=Nt.map(function(Me,be,Gt){return(0,p.pi)((0,p.pi)((0,p.pi)({},Me),{hasText:!!Me.text,font:Pn(te.font)(Me,be,Gt),weight:Pn(te.fontWeight)(Me,be,Gt),rotate:Pn(te.rotate)(Me,be,Gt),size:Pn(te.fontSize)(Me,be,Gt),style:"normal"}),S.call(t,Me,be,Gt))});return ce.push({text:"",value:0,x:0,y:0,opacity:0}),ce.push({text:"",value:0,x:te.size[0],y:te.size[1],opacity:0}),ce}return OB(Nt,te)}function qB(r){var e=r.width,t=r.height,n=r.container,i=r.autoFit,a=r.padding,o=r.appendPadding;if(i){var s=Lc(n);e=s.width,t=s.height}e=e||400,t=t||400;var l=KB({padding:a,appendPadding:o}),u=l[0],c=l[1],h=l[2],v=l[3],d=[e-(v+c),t-(u+h)];return d}function KB(r){var e=fi(r.padding),t=fi(r.appendPadding),n=e[0]+t[0],i=e[1]+t[1],a=e[2]+t[2],o=e[3]+t[3];return[n,i,a,o]}function jB(r){return new Promise(function(e,t){if(r instanceof HTMLImageElement){e(r);return}if((0,f.HD)(r)){var n=new Image;n.crossOrigin="anonymous",n.src=r,n.onload=function(){e(n)},n.onerror=function(){Hn(pn.ERROR,!1,"image %s load failed !!!",r),t()};return}Hn(pn.WARN,r===void 0,"The type of imageMask option must be String or HTMLImageElement."),t()})}function JB(r,e){if((0,f.mf)(r))return r;if((0,f.kJ)(r)){var t=r[0],n=r[1];if(!e)return function(){return(n+t)/2};var i=e[0],a=e[1];return a===i?function(){return(n+t)/2}:function(s){var l=s.value;return(n-t)/(a-i)*(l-i)+t}}return function(){return r}}function QB(r,e){return r.map(function(t){return t[e]}).filter(function(t){return typeof t=="number"&&!isNaN(t)})}function tR(r){var e=eR(r),t=e.rotation,n=e.rotationSteps;if(!(0,f.kJ)(t))return t;var i=t[0],a=t[1],o=n===1?0:(a-i)/(n-1);return function(){return a===i?a:Math.floor(Math.random()*n)*o}}function eR(r){var e=r.wordStyle.rotationSteps;return e<1&&(Hn(pn.WARN,!1,"The rotationSteps option must be greater than or equal to 1."),e=1),{rotation:r.wordStyle.rotation,rotationSteps:e}}function rR(r){return Math.min.apply(Math,r)}function nR(r){return Math.max.apply(Math,r)}function iR(r){var e=r.chart,t=r.options,n=t.colorField,i=t.color,a=Ny(r);e.data(a);var o=kt({},r,{options:{xField:"x",yField:"y",seriesField:n&&_f,rawFields:(0,f.mf)(i)&&(0,p.ev)((0,p.ev)([],(0,f.U2)(t,"rawFields",[]),!0),["datum"],!1),point:{color:i,shape:"word-cloud"}}}),s=jr(o).ext;return s.geometry.label(!1),e.coordinate().reflect("y"),e.axis(!1),r}function aR(r){return Fe(ur({x:{nice:!1},y:{nice:!1}}))(r)}function oR(r){var e=r.chart,t=r.options,n=t.legend,i=t.colorField;return n===!1?e.legend(!1):i&&e.legend(_f,n),r}function sR(r){Fe(iR,aR,pr,oR,or,tr,We,hi)(r)}Ke("point","word-cloud",{draw:function(r,e){var t=r.x,n=r.y,i=e.addShape("text",{attrs:(0,p.pi)((0,p.pi)({},lR(r)),{x:t,y:n})}),a=r.data.rotate;return typeof a=="number"&&zr.rotate(i,a*Math.PI/180),i}});function lR(r){return{fontSize:r.data.size,text:r.data.text,textAlign:"center",fontFamily:r.data.font,fontWeight:r.data.weight,fill:r.color||r.defaultStyle.stroke,textBaseline:"alphabetic"}}var H5=function(r){(0,p.ZT)(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="word-cloud",t}return e.getDefaultOptions=function(){return LB},e.prototype.changeData=function(t){this.updateOption({data:t}),this.options.imageMask?this.render():this.chart.changeData(Ny({chart:this.chart,options:this.options}))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.render=function(){var t=this;return new Promise(function(n){var i=t.options.imageMask;if(!i){r.prototype.render.call(t),n();return}var a=function(o){t.options=(0,p.pi)((0,p.pi)({},t.options),{imageMask:o||null}),r.prototype.render.call(t),n()};jB(i).then(a).catch(a)})},e.prototype.getSchemaAdaptor=function(){return sR},e.prototype.triggerResize=function(){var t=this;this.chart.destroyed||(this.execAdaptor(),window.setTimeout(function(){r.prototype.triggerResize.call(t)}))},e}(Re),G5=function(r){(0,p.ZT)(e,r);function e(t,n,i,a){var o=r.call(this,t,kt({},a,n))||this;return o.type="g2-plot",o.defaultOptions=a,o.adaptor=i,o}return e.prototype.getDefaultOptions=function(){return this.defaultOptions},e.prototype.getSchemaAdaptor=function(){return this.adaptor},e}(Re),Y5="2.4.31";tg("en-US",o_),tg("zh-CN",s_);var X5={scale:ur,legend:ki,tooltip:pr,annotation:sr,interaction:or,theme:We,animation:tr}},31506:function(ge,Xt,N){"use strict";N.d(Xt,{m$:function(){return Dt},zu:function(){return It},lh:function(){return mt},vs:function(){return ut},Dg:function(){return it}});var et=N(35600),ot=N(31437);function Dt(Ft,ft,q){var p=[0,0,0,0,0,0,0,0,0];return et.vc(p,q),et.Jp(Ft,p,ft)}function It(Ft,ft,q){var p=[0,0,0,0,0,0,0,0,0];return et.Us(p,q),et.Jp(Ft,p,ft)}function mt(Ft,ft,q){var p=[0,0,0,0,0,0,0,0,0];return et.xJ(p,q),et.Jp(Ft,p,ft)}function yt(Ft,ft,q){return et.Jp(Ft,q,ft)}function ut(Ft,ft){for(var q=Ft?[].concat(Ft):[1,0,0,0,1,0,0,0,1],p=0,f=ft.length;p<f;p++){var J=ft[p];switch(J[0]){case"t":Dt(q,q,[J[1],J[2]]);break;case"s":mt(q,q,[J[1],J[2]]);break;case"r":It(q,q,J[1]);break;case"m":yt(q,q,J[1]);break;default:break}}return q}function xt(Ft,ft){return Ft[0]*ft[1]-ft[0]*Ft[1]}function it(Ft,ft,q){var p=ot.EU(Ft,ft),f=xt(Ft,ft)>=0;return q?f?Math.PI*2-p:p:f?p:Math.PI*2-p}function Ut(Ft,ft,q){return q?(Ft[0]=ft[1],Ft[1]=-1*ft[0]):(Ft[0]=-1*ft[1],Ft[1]=ft[0]),Ft}},41694:function(ge,Xt,N){"use strict";N.d(Xt,{Ct:function(){return $l},f0:function(){return Mi},uZ:function(){return Se},VS:function(){return Ho},d9:function(){return Go},FX:function(){return It},Ds:function(){return qi},b$:function(){return Xo},e5:function(){return xt},S6:function(){return ht},yW:function(){return Er},hX:function(){return yt},sE:function(){return Pt},cx:function(){return Bt},Wx:function(){return wt},ri:function(){return we},xH:function(){return z},U5:function(){return W},U2:function(){return Hl},Lo:function(){return qo},rx:function(){return I},ru:function(){return Wt},vM:function(){return St},Ms:function(){return Ot},wH:function(){return $},YM:function(){return qt},q9:function(){return It},cq:function(){return Ki},kJ:function(){return f},jn:function(){return wn},J_:function(){return _l},kK:function(){return Fr},xb:function(){return Bn},Xy:function(){return mi},mf:function(){return ft},BD:function(){return Et},UM:function(){return p},Ft:function(){return Sn},hj:function(){return Ce},vQ:function(){return Sr},Kn:function(){return J},PO:function(){return ye},HD:function(){return nt},P9:function(){return Ft},o8:function(){return zo},XP:function(){return X},Z$:function(){return Yt},vl:function(){return ke},UI:function(){return Ul},Q8:function(){return Vl},Fp:function(){return V},UT:function(){return tn},HP:function(){return Pa},VV:function(){return G},F:function(){return Yr},CD:function(){return Mi},wQ:function(){return rn},ZT:function(){return Yl},CE:function(){return Zo},ei:function(){return Or},u4:function(){return U},Od:function(){return j},U7:function(){return Ll},t8:function(){return ji},dp:function(){return Xl},G:function(){return tt},MR:function(){return Jt},ng:function(){return gr},P2:function(){return $o},qo:function(){return Bf},c$:function(){return nn},BB:function(){return he},jj:function(){return $t},EL:function(){return Gl},jC:function(){return mr},VO:function(){return Vt},I:function(){return ne}});var et=function(O){return O!==null&&typeof O!="function"&&isFinite(O.length)},ot=et,Dt=function(O,rt){return ot(O)?O.indexOf(rt)>-1:!1},It=Dt,mt=function(O,rt){if(!ot(O))return O;for(var ct=[],_t=0;_t<O.length;_t++){var Qt=O[_t];rt(Qt,_t)&&ct.push(Qt)}return ct},yt=mt,ut=function(O,rt){return rt===void 0&&(rt=[]),yt(O,function(ct){return!It(rt,ct)})},xt=ut,it={}.toString,Ut=function(O,rt){return it.call(O)==="[object "+rt+"]"},Ft=Ut,ft=function(O){return Ft(O,"Function")},q=function(O){return O==null},p=q,f=function(O){return Array.isArray?Array.isArray(O):Ft(O,"Array")},J=function(O){var rt=typeof O;return O!==null&&rt==="object"||rt==="function"};function K(O,rt){if(!!O){var ct;if(f(O))for(var _t=0,Qt=O.length;_t<Qt&&(ct=rt(O[_t],_t),ct!==!1);_t++);else if(J(O)){for(var ve in O)if(O.hasOwnProperty(ve)&&(ct=rt(O[ve],ve),ct===!1))break}}}var ht=K,Mt=Object.keys?function(O){return Object.keys(O)}:function(O){var rt=[];return ht(O,function(ct,_t){ft(O)&&_t==="prototype"||rt.push(_t)}),rt},X=Mt;function st(O,rt){var ct=X(rt),_t=ct.length;if(p(O))return!_t;for(var Qt=0;Qt<_t;Qt+=1){var ve=ct[Qt];if(rt[ve]!==O[ve]||!(ve in O))return!1}return!0}var Et=st,zt=function(O){return typeof O=="object"&&O!==null},jt=zt,ee=function(O){if(!jt(O)||!Ft(O,"Object"))return!1;if(Object.getPrototypeOf(O)===null)return!0;for(var rt=O;Object.getPrototypeOf(rt)!==null;)rt=Object.getPrototypeOf(rt);return Object.getPrototypeOf(O)===rt},ye=ee;function pt(O,rt){if(!f(O))return null;var ct;if(ft(rt)&&(ct=rt),ye(rt)&&(ct=function(Qt){return Et(Qt,rt)}),ct){for(var _t=0;_t<O.length;_t+=1)if(ct(O[_t]))return O[_t]}return null}var Pt=pt;function Rt(O,rt,ct){ct===void 0&&(ct=0);for(var _t=ct;_t<O.length;_t++)if(rt(O[_t],_t))return _t;return-1}var Bt=Rt,Ct=function(O,rt){for(var ct=null,_t=0;_t<O.length;_t++){var Qt=O[_t],ve=Qt[rt];if(!p(ve)){f(ve)?ct=ve[0]:ct=ve;break}}return ct},wt=Ct,T=function(O){if(!f(O))return[];for(var rt=[],ct=0;ct<O.length;ct++)rt=rt.concat(O[ct]);return rt},z=T,bt=function(O,rt){if(rt===void 0&&(rt=[]),!isArray(O))rt.push(O);else for(var ct=0;ct<O.length;ct+=1)bt(O[ct],rt);return rt},Y=null,V=function(O){if(!!f(O))return O.reduce(function(rt,ct){return Math.max(rt,ct)},O[0])},G=function(O){if(!!f(O))return O.reduce(function(rt,ct){return Math.min(rt,ct)},O[0])},A=function(O){var rt=O.filter(function(_e){return!isNaN(_e)});if(!rt.length)return{min:0,max:0};if(f(O[0])){for(var ct=[],_t=0;_t<O.length;_t++)ct=ct.concat(O[_t]);rt=ct}var Qt=V(rt),ve=G(rt);return{min:ve,max:Qt}},I=A,D=Array.prototype,E=D.splice,Q=D.indexOf,lt=function(O){for(var rt=[],ct=1;ct<arguments.length;ct++)rt[ct-1]=arguments[ct];for(var _t=0;_t<rt.length;_t++)for(var Qt=rt[_t],ve=-1;(ve=Q.call(O,Qt))>-1;)E.call(O,ve,1);return O},P=null,F=Array.prototype.splice,C=function(rt,ct){if(!ot(rt))return[];for(var _t=rt?ct.length:0,Qt=_t-1;_t--;){var ve=void 0,_e=ct[_t];(_t===Qt||_e!==ve)&&(ve=_e,F.call(rt,_e,1))}return rt},_=C,L=function(O,rt,ct){if(!f(O)&&!ye(O))return O;var _t=ct;return ht(O,function(Qt,ve){_t=rt(_t,Qt,ve)}),_t},U=L,B=function(O,rt){var ct=[];if(!ot(O))return ct;for(var _t=-1,Qt=[],ve=O.length;++_t<ve;){var _e=O[_t];rt(_e,_t,O)&&(ct.push(_e),Qt.push(_t))}return _(O,Qt),ct},j=B,nt=function(O){return Ft(O,"String")};function Tt(O,rt){var ct;if(ft(rt))ct=function(Qt,ve){return rt(Qt)-rt(ve)};else{var _t=[];nt(rt)?_t.push(rt):f(rt)&&(_t=rt),ct=function(Qt,ve){for(var _e=0;_e<_t.length;_e+=1){var qe=_t[_e];if(Qt[qe]>ve[qe])return 1;if(Qt[qe]<ve[qe])return-1}return 0}}return O.sort(ct),O}var Jt=Tt;function $t(O,rt){rt===void 0&&(rt=new Map);var ct=[];if(Array.isArray(O))for(var _t=0,Qt=O.length;_t<Qt;_t++){var ve=O[_t];rt.has(ve)||(ct.push(ve),rt.set(ve,!0))}return ct}var ne=function(O,rt){for(var ct=[],_t={},Qt=0;Qt<O.length;Qt++){var ve=O[Qt],_e=ve[rt];if(!p(_e)){f(_e)||(_e=[_e]);for(var qe=0;qe<_e.length;qe++){var Cr=_e[qe];_t[Cr]||(ct.push(Cr),_t[Cr]=!0)}}}return ct};function qt(O){if(ot(O))return O[0]}function Yt(O){if(ot(O)){var rt=O;return rt[rt.length-1]}}function fe(O,rt){return isArray(O)||isString(O)?O[0]===rt:!1}var Pe=null;function Oe(O,rt){return isArray(O)||isString(O)?O[O.length-1]===rt:!1}var Be=null,cr=function(O,rt){for(var ct=0;ct<O.length;ct++)if(!rt(O[ct],ct))return!1;return!0},Er=cr,_r=function(O,rt){for(var ct=0;ct<O.length;ct++)if(rt(O[ct],ct))return!0;return!1},tt=_r,Z=Object.prototype.hasOwnProperty;function vt(O,rt){if(!rt||!f(O))return{};for(var ct={},_t=ft(rt)?rt:function(qe){return qe[rt]},Qt,ve=0;ve<O.length;ve++){var _e=O[ve];Qt=_t(_e),Z.call(ct,Qt)?ct[Qt].push(_e):ct[Qt]=[_e]}return ct}var St=vt;function Ot(O,rt){if(!rt)return{0:O};if(!ft(rt)){var ct=f(rt)?rt:rt.replace(/\s+/g,"").split("*");rt=function(_t){for(var Qt="_",ve=0,_e=ct.length;ve<_e;ve++)Qt+=_t[ct[ve]]&&_t[ct[ve]].toString();return Qt}}return St(O,rt)}var Wt=function(O,rt){if(!rt)return[O];var ct=Ot(O,rt),_t=[];for(var Qt in ct)_t.push(ct[Qt]);return _t},Ht={};function Kt(O){var rt=Ht[O];if(!rt){for(var ct=O.toString(16),_t=ct.length;_t<6;_t++)ct="0"+ct;rt="#"+ct,Ht[O]=rt}return rt}var Lt=null;function re(O){var rt=0,ct=0,_t=0,Qt=0;return isArray(O)?O.length===1?rt=ct=_t=Qt=O[0]:O.length===2?(rt=_t=O[0],ct=Qt=O[1]):O.length===3?(rt=O[0],ct=Qt=O[1],_t=O[2]):(rt=O[0],ct=O[1],_t=O[2],Qt=O[3]):rt=ct=_t=Qt=O,{r1:rt,r2:ct,r3:_t,r4:Qt}}var Zt=null,me=function(O,rt,ct){return O<rt?rt:O>ct?ct:O},Se=me,se=function(O,rt){var ct=rt.toString(),_t=ct.indexOf(".");if(_t===-1)return Math.round(O);var Qt=ct.substr(_t+1).length;return Qt>20&&(Qt=20),parseFloat(O.toFixed(Qt))},we=se,Ae=function(O){return Ft(O,"Number")},Ce=Ae,ae=function(O){return isNumber(O)&&O%1!=0},Ie=null,Le=function(O){return isNumber(O)&&O%2==0},He=null,ze=Number.isInteger?Number.isInteger:function(O){return Ce(O)&&O%1==0},$e=null,je=function(O){return isNumber(O)&&O<0},yr=null,wr=1e-5;function Sr(O,rt,ct){return ct===void 0&&(ct=wr),Math.abs(O-rt)<ct}var cn=function(O){return isNumber(O)&&O%2!=0},yn=null,mn=function(O){return isNumber(O)&&O>0},qn=null,tn=function(O,rt){if(!!f(O)){for(var ct,_t=-Infinity,Qt=0;Qt<O.length;Qt++){var ve=O[Qt],_e=ft(rt)?rt(ve):ve[rt];_e>_t&&(ct=ve,_t=_e)}return ct}},Yr=function(O,rt){if(!!f(O)){for(var ct,_t=Infinity,Qt=0;Qt<O.length;Qt++){var ve=O[Qt],_e=ft(rt)?rt(ve):ve[rt];_e<_t&&(ct=ve,_t=_e)}return ct}},en=function(O,rt){return(O%rt+rt)%rt},rn=en,fn=180/Math.PI,Kn=function(O){return fn*O},xn=null,jn=parseInt,_a=Math.PI/180,Fa=function(O){return _a*O},nn=Fa,W=ht,R=function(O,rt){return O.hasOwnProperty(rt)},$=R,dt=Object.values?function(O){return Object.values(O)}:function(O){var rt=[];return ht(O,function(ct,_t){ft(O)&&_t==="prototype"||rt.push(ct)}),rt},Vt=dt,oe=function(O,rt){return contains(values(O),rt)},he=function(O){return p(O)?"":O.toString()},le=function(O){return he(O).toLowerCase()},ke=le;function ir(O,rt){return!O||!rt?O:O.replace(/\\?\{([^{}]+)\}/g,function(ct,_t){return ct.charAt(0)==="\\"?ct.slice(1):rt[_t]===void 0?"":rt[_t]})}var gr=ir,Dr=function(O){var rt=he(O);return rt.charAt(0).toUpperCase()+rt.substring(1)},mr=Dr,On={}.toString,Xr=function(O){return On.call(O).replace(/^\[object /,"").replace(/]$/,"")},Ia=Xr,yi=function(O){return isType(O,"Arguments")},Tl=null,Mn=function(O){return Ft(O,"Boolean")},wn=Mn,El=function(O){return Ft(O,"Date")},_l=El,Wi=function(O){return isType(O,"Error")},Fl=null;function Il(O){return isNumber(O)&&isFinite(O)}var Bo=function(O){return O===null},Sn=Bo,Ro=Object.prototype,No=function(O){var rt=O&&O.constructor,ct=typeof rt=="function"&&rt.prototype||Ro;return O===ct},Pl=No,Of=function(O){return isType(O,"RegExp")},Uo=null,Zi=function(O){return O===void 0},zo=Zi,Vo=function(O){return O instanceof Element||O instanceof HTMLDocument},Fr=Vo;function Ll(O){var rt=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||function(ct){return setTimeout(ct,16)};return rt(O)}function Ho(O){var rt=window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||window.msCancelAnimationFrame||clearTimeout;rt(O)}var Dl=function(){for(var O=[],rt=0;rt<arguments.length;rt++)O[rt]=arguments[rt];for(var ct=O[0],_t=1;_t<O.length;_t++){var Qt=O[_t];isFunction(Qt)&&(Qt=Qt.prototype),mix(ct.prototype,Qt)}},Ol=null,$i=function(O){if(typeof O!="object"||O===null)return O;var rt;if(f(O)){rt=[];for(var ct=0,_t=O.length;ct<_t;ct++)typeof O[ct]=="object"&&O[ct]!=null?rt[ct]=$i(O[ct]):rt[ct]=O[ct]}else{rt={};for(var Qt in O)typeof O[Qt]=="object"&&O[Qt]!=null?rt[Qt]=$i(O[Qt]):rt[Qt]=O[Qt]}return rt},Go=$i;function kl(O,rt,ct){var _t;return function(){var Qt=this,ve=arguments,_e=function(){_t=null,ct||O.apply(Qt,ve)},qe=ct&&!_t;clearTimeout(_t),_t=setTimeout(_e,rt),qe&&O.apply(Qt,ve)}}var qi=kl,Pa=function(O,rt){if(!ft(O))throw new TypeError("Expected a function");var ct=function(){for(var _t=[],Qt=0;Qt<arguments.length;Qt++)_t[Qt]=arguments[Qt];var ve=rt?rt.apply(this,_t):_t[0],_e=ct.cache;if(_e.has(ve))return _e.get(ve);var qe=O.apply(this,_t);return _e.set(ve,qe),qe};return ct.cache=new Map,ct},Yo=5;function La(O,rt,ct,_t){ct=ct||0,_t=_t||Yo;for(var Qt in rt)if(rt.hasOwnProperty(Qt)){var ve=rt[Qt];ve!==null&&ye(ve)?(ye(O[Qt])||(O[Qt]={}),ct<_t?La(O[Qt],ve,ct+1,_t):O[Qt]=rt[Qt]):f(ve)?(O[Qt]=[],O[Qt]=O[Qt].concat(ve)):ve!==void 0&&(O[Qt]=ve)}}var Bl=function(O){for(var rt=[],ct=1;ct<arguments.length;ct++)rt[ct-1]=arguments[ct];for(var _t=0;_t<rt.length;_t+=1)La(O,rt[_t]);return O},Xo=Bl,kf=function(O,rt,ct,_t){isFunction(rt)||(ct=rt,rt=O,O=function(){});var Qt=Object.create?function(_e,qe){return Object.create(_e,{constructor:{value:qe}})}:function(_e,qe){function Cr(){}Cr.prototype=_e;var Lr=new Cr;return Lr.constructor=qe,Lr},ve=Qt(rt.prototype,O);return O.prototype=mix(ve,O.prototype),O.superclass=Qt(rt.prototype,rt),mix(ve,ct),mix(O,_t),O},Rl=null,Wo=function(O,rt){if(!ot(O))return-1;var ct=Array.prototype.indexOf;if(ct)return ct.call(O,rt);for(var _t=-1,Qt=0;Qt<O.length;Qt++)if(O[Qt]===rt){_t=Qt;break}return _t},Ki=Wo,Wr=Object.prototype.hasOwnProperty;function kn(O){if(p(O))return!0;if(ot(O))return!O.length;var rt=Ia(O);if(rt==="Map"||rt==="Set")return!O.size;if(Pl(O))return!Object.keys(O).length;for(var ct in O)if(Wr.call(O,ct))return!1;return!0}var Bn=kn,Zr=function(O,rt){if(O===rt)return!0;if(!O||!rt||nt(O)||nt(rt))return!1;if(ot(O)||ot(rt)){if(O.length!==rt.length)return!1;for(var ct=!0,_t=0;_t<O.length&&(ct=Zr(O[_t],rt[_t]),!!ct);_t++);return ct}if(jt(O)||jt(rt)){var Qt=Object.keys(O),ve=Object.keys(rt);if(Qt.length!==ve.length)return!1;for(var ct=!0,_t=0;_t<Qt.length&&(ct=Zr(O[Qt[_t]],rt[Qt[_t]]),!!ct);_t++);return ct}return!1},mi=Zr,Nl=function(O,rt,ct){return isFunction(ct)?!!ct(O,rt):isEqual(O,rt)},xi=function(O,rt){if(!ot(O))return O;for(var ct=[],_t=0;_t<O.length;_t++){var Qt=O[_t];ct.push(rt(Qt,_t))}return ct},Ul=xi,zl=function(O){return O},Vl=function(O,rt){rt===void 0&&(rt=zl);var ct={};return J(O)&&!p(O)&&Object.keys(O).forEach(function(_t){ct[_t]=rt(O[_t],_t)}),ct};function Da(O,rt){for(var ct in rt)rt.hasOwnProperty(ct)&&ct!=="constructor"&&rt[ct]!==void 0&&(O[ct]=rt[ct])}function Mi(O,rt,ct,_t){return rt&&Da(O,rt),ct&&Da(O,ct),_t&&Da(O,_t),O}var Hl=function(O,rt,ct){for(var _t=0,Qt=nt(rt)?rt.split("."):rt;O&&_t<Qt.length;)O=O[Qt[_t++]];return O===void 0||_t<Qt.length?ct:O},ji=function(O,rt,ct){var _t=O,Qt=nt(rt)?rt.split("."):rt;return Qt.forEach(function(ve,_e){_e<Qt.length-1?(J(_t[ve])||(_t[ve]=Ce(Qt[_e+1])?[]:{}),_t=_t[ve]):_t[ve]=ct}),O},Cn=Object.prototype.hasOwnProperty,Or=function(O,rt){if(O===null||!ye(O))return{};var ct={};return ht(rt,function(_t){Cn.call(O,_t)&&(ct[_t]=O[_t])}),ct},Zo=function(O,rt){return U(O,function(ct,_t,Qt){return rt.includes(Qt)||(ct[Qt]=_t),ct},{})},$o=function(O,rt,ct){var _t,Qt,ve,_e,qe=0;ct||(ct={});var Cr=function(){qe=ct.leading===!1?0:Date.now(),_t=null,_e=O.apply(Qt,ve),_t||(Qt=ve=null)},Lr=function(){var kr=Date.now();!qe&&ct.leading===!1&&(qe=kr);var Oa=rt-(kr-qe);return Qt=this,ve=arguments,Oa<=0||Oa>rt?(_t&&(clearTimeout(_t),_t=null),qe=kr,_e=O.apply(Qt,ve),_t||(Qt=ve=null)):!_t&&ct.trailing!==!1&&(_t=setTimeout(Cr,Oa)),_e};return Lr.cancel=function(){clearTimeout(_t),qe=0,_t=Qt=ve=null},Lr},Bf=function(O){return ot(O)?Array.prototype.slice.call(O):[]},Ji={},Gl=function(O){return O=O||"g",Ji[O]?Ji[O]+=1:Ji[O]=1,O+Ji[O]},Yl=function(){};function Xl(O){return p(O)?0:ot(O)?O.length:Object.keys(O).length}var Wl=N(65353),Qi,ta=Pa(function(O,rt){rt===void 0&&(rt={});var ct=rt.fontSize,_t=rt.fontFamily,Qt=rt.fontWeight,ve=rt.fontStyle,_e=rt.fontVariant;return Qi||(Qi=document.createElement("canvas").getContext("2d")),Qi.font=[ve,_e,Qt,ct+"px",_t].join(" "),Qi.measureText(nt(O)?O:"").width},function(O,rt){return rt===void 0&&(rt={}),(0,Wl.pr)([O],Vt(rt)).join("")}),qo=function(O,rt,ct,_t){_t===void 0&&(_t="...");var Qt=16,ve=ta(_t,ct),_e=nt(O)?O:he(O),qe=rt,Cr=[],Lr,kr;if(ta(O,ct)<=rt)return O;for(;Lr=_e.substr(0,Qt),kr=ta(Lr,ct),!(kr+ve>qe&&kr>qe);)if(Cr.push(Lr),qe-=kr,_e=_e.substr(Qt),!_e)return Cr.join("");for(;Lr=_e.substr(0,1),kr=ta(Lr,ct),!(kr+ve>qe);)if(Cr.push(Lr),qe-=kr,_e=_e.substr(1),!_e)return Cr.join("");return""+Cr.join("")+_t},Zl=function(){function O(){this.map={}}return O.prototype.has=function(rt){return this.map[rt]!==void 0},O.prototype.get=function(rt,ct){var _t=this.map[rt];return _t===void 0?ct:_t},O.prototype.set=function(rt,ct){this.map[rt]=ct},O.prototype.clear=function(){this.map={}},O.prototype.delete=function(rt){delete this.map[rt]},O.prototype.size=function(){return Object.keys(this.map).length},O}(),$l=Zl},80638:function(){},81903:function(){},15746:function(ge,Xt,N){"use strict";var et=N(21584);Xt.Z=et.Z},89032:function(ge,Xt,N){"use strict";var et=N(38663),ot=N.n(et),Dt=N(6999)},99134:function(ge,Xt,N){"use strict";var et=N(67294),ot=(0,et.createContext)({});Xt.Z=ot},21584:function(ge,Xt,N){"use strict";var et=N(96156),ot=N(22122),Dt=N(90484),It=N(94184),mt=N.n(It),yt=N(67294),ut=N(53124),xt=N(99134),it=function(q,p){var f={};for(var J in q)Object.prototype.hasOwnProperty.call(q,J)&&p.indexOf(J)<0&&(f[J]=q[J]);if(q!=null&&typeof Object.getOwnPropertySymbols=="function")for(var K=0,J=Object.getOwnPropertySymbols(q);K<J.length;K++)p.indexOf(J[K])<0&&Object.prototype.propertyIsEnumerable.call(q,J[K])&&(f[J[K]]=q[J[K]]);return f};function Ut(q){return typeof q=="number"?"".concat(q," ").concat(q," auto"):/^\d+(\.\d+)?(px|em|rem|%)$/.test(q)?"0 0 ".concat(q):q}var Ft=["xs","sm","md","lg","xl","xxl"],ft=yt.forwardRef(function(q,p){var f=yt.useContext(ut.E_),J=f.getPrefixCls,K=f.direction,ht=yt.useContext(xt.Z),Mt=ht.gutter,X=ht.wrap,st=ht.supportFlexGap,Et=q.prefixCls,zt=q.span,jt=q.order,ee=q.offset,ye=q.push,pt=q.pull,Pt=q.className,Rt=q.children,Bt=q.flex,Ct=q.style,wt=it(q,["prefixCls","span","order","offset","push","pull","className","children","flex","style"]),T=J("col",Et),z={};Ft.forEach(function(A){var I={},D=q[A];typeof D=="number"?I.span=D:(0,Dt.Z)(D)==="object"&&(I=D||{}),delete wt[A],z=(0,ot.Z)((0,ot.Z)({},z),(0,et.Z)((0,et.Z)((0,et.Z)((0,et.Z)((0,et.Z)((0,et.Z)({},"".concat(T,"-").concat(A,"-").concat(I.span),I.span!==void 0),"".concat(T,"-").concat(A,"-order-").concat(I.order),I.order||I.order===0),"".concat(T,"-").concat(A,"-offset-").concat(I.offset),I.offset||I.offset===0),"".concat(T,"-").concat(A,"-push-").concat(I.push),I.push||I.push===0),"".concat(T,"-").concat(A,"-pull-").concat(I.pull),I.pull||I.pull===0),"".concat(T,"-rtl"),K==="rtl"))});var bt=mt()(T,(0,et.Z)((0,et.Z)((0,et.Z)((0,et.Z)((0,et.Z)({},"".concat(T,"-").concat(zt),zt!==void 0),"".concat(T,"-order-").concat(jt),jt),"".concat(T,"-offset-").concat(ee),ee),"".concat(T,"-push-").concat(ye),ye),"".concat(T,"-pull-").concat(pt),pt),Pt,z),Y={};if(Mt&&Mt[0]>0){var V=Mt[0]/2;Y.paddingLeft=V,Y.paddingRight=V}if(Mt&&Mt[1]>0&&!st){var G=Mt[1]/2;Y.paddingTop=G,Y.paddingBottom=G}return Bt&&(Y.flex=Ut(Bt),X===!1&&!Y.minWidth&&(Y.minWidth=0)),yt.createElement("div",(0,ot.Z)({},wt,{style:(0,ot.Z)((0,ot.Z)({},Y),Ct),className:bt,ref:p}),Rt)});Xt.Z=ft},92820:function(ge,Xt,N){"use strict";var et=N(22122),ot=N(96156),Dt=N(90484),It=N(28481),mt=N(94184),yt=N.n(mt),ut=N(67294),xt=N(53124),it=N(98082),Ut=N(24308),Ft=N(93355),ft=N(99134),q=function(ht,Mt){var X={};for(var st in ht)Object.prototype.hasOwnProperty.call(ht,st)&&Mt.indexOf(st)<0&&(X[st]=ht[st]);if(ht!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Et=0,st=Object.getOwnPropertySymbols(ht);Et<st.length;Et++)Mt.indexOf(st[Et])<0&&Object.prototype.propertyIsEnumerable.call(ht,st[Et])&&(X[st[Et]]=ht[st[Et]]);return X},p=(0,Ft.b)("top","middle","bottom","stretch"),f=(0,Ft.b)("start","end","center","space-around","space-between","space-evenly");function J(ht,Mt){var X=ut.useState(typeof ht=="string"?ht:""),st=(0,It.Z)(X,2),Et=st[0],zt=st[1],jt=function(){if(typeof ht=="string"&&zt(ht),(0,Dt.Z)(ht)==="object")for(var ye=0;ye<Ut.c4.length;ye++){var pt=Ut.c4[ye];if(!!Mt[pt]){var Pt=ht[pt];if(Pt!==void 0){zt(Pt);return}}}};return ut.useEffect(function(){jt()},[JSON.stringify(ht),Mt]),Et}var K=ut.forwardRef(function(ht,Mt){var X=ht.prefixCls,st=ht.justify,Et=ht.align,zt=ht.className,jt=ht.style,ee=ht.children,ye=ht.gutter,pt=ye===void 0?0:ye,Pt=ht.wrap,Rt=q(ht,["prefixCls","justify","align","className","style","children","gutter","wrap"]),Bt=ut.useContext(xt.E_),Ct=Bt.getPrefixCls,wt=Bt.direction,T=ut.useState({xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0}),z=(0,It.Z)(T,2),bt=z[0],Y=z[1],V=ut.useState({xs:!1,sm:!1,md:!1,lg:!1,xl:!1,xxl:!1}),G=(0,It.Z)(V,2),A=G[0],I=G[1],D=J(Et,A),E=J(st,A),Q=(0,it.Z)(),lt=ut.useRef(pt);ut.useEffect(function(){var ne=Ut.ZP.subscribe(function(qt){I(qt);var Yt=lt.current||0;(!Array.isArray(Yt)&&(0,Dt.Z)(Yt)==="object"||Array.isArray(Yt)&&((0,Dt.Z)(Yt[0])==="object"||(0,Dt.Z)(Yt[1])==="object"))&&Y(qt)});return function(){return Ut.ZP.unsubscribe(ne)}},[]);var P=function(){var qt=[void 0,void 0],Yt=Array.isArray(pt)?pt:[pt,void 0];return Yt.forEach(function(fe,Pe){if((0,Dt.Z)(fe)==="object")for(var Oe=0;Oe<Ut.c4.length;Oe++){var Be=Ut.c4[Oe];if(bt[Be]&&fe[Be]!==void 0){qt[Pe]=fe[Be];break}}else qt[Pe]=fe}),qt},F=Ct("row",X),C=P(),_=yt()(F,(0,ot.Z)((0,ot.Z)((0,ot.Z)((0,ot.Z)({},"".concat(F,"-no-wrap"),Pt===!1),"".concat(F,"-").concat(E),E),"".concat(F,"-").concat(D),D),"".concat(F,"-rtl"),wt==="rtl"),zt),L={},U=C[0]!=null&&C[0]>0?C[0]/-2:void 0,B=C[1]!=null&&C[1]>0?C[1]/-2:void 0;if(U&&(L.marginLeft=U,L.marginRight=U),Q){var j=(0,It.Z)(C,2);L.rowGap=j[1]}else B&&(L.marginTop=B,L.marginBottom=B);var nt=(0,It.Z)(C,2),Tt=nt[0],Jt=nt[1],$t=ut.useMemo(function(){return{gutter:[Tt,Jt],wrap:Pt,supportFlexGap:Q}},[Tt,Jt,Pt,Q]);return ut.createElement(ft.Z.Provider,{value:$t},ut.createElement("div",(0,et.Z)({},Rt,{className:_,style:(0,et.Z)((0,et.Z)({},L),jt),ref:Mt}),ee))});Xt.Z=K},6999:function(ge,Xt,N){"use strict";var et=N(38663),ot=N.n(et),Dt=N(80638),It=N.n(Dt)},71230:function(ge,Xt,N){"use strict";var et=N(92820);Xt.Z=et.Z},13062:function(ge,Xt,N){"use strict";var et=N(38663),ot=N.n(et),Dt=N(6999)},7277:function(ge,Xt,N){"use strict";N.d(Xt,{Z:function(){return pt}});var et=N(22122),ot=N(67294),Dt=N(57838),It=N(96159),mt=N(96156),yt=N(94184),ut=N.n(yt),xt=N(53124),it=N(19586),Ut=N(11726),Ft=N.n(Ut),ft=function(Rt){var Bt=Rt.value,Ct=Rt.formatter,wt=Rt.precision,T=Rt.decimalSeparator,z=Rt.groupSeparator,bt=z===void 0?"":z,Y=Rt.prefixCls,V;if(typeof Ct=="function")V=Ct(Bt);else{var G=String(Bt),A=G.match(/^(-?)(\d*)(\.(\d+))?$/);if(!A||G==="-")V=G;else{var I=A[1],D=A[2]||"0",E=A[4]||"";D=D.replace(/\B(?=(\d{3})+(?!\d))/g,bt),typeof wt=="number"&&(E=Ft()(E,wt,"0").slice(0,wt>0?wt:0)),E&&(E="".concat(T).concat(E)),V=[ot.createElement("span",{key:"int",className:"".concat(Y,"-content-value-int")},I,D),E&&ot.createElement("span",{key:"decimal",className:"".concat(Y,"-content-value-decimal")},E)]}}return ot.createElement("span",{className:"".concat(Y,"-content-value")},V)},q=ft,p=function(Rt){var Bt=Rt.prefixCls,Ct=Rt.className,wt=Rt.style,T=Rt.valueStyle,z=Rt.value,bt=z===void 0?0:z,Y=Rt.title,V=Rt.valueRender,G=Rt.prefix,A=Rt.suffix,I=Rt.loading,D=I===void 0?!1:I,E=Rt.direction,Q=Rt.onMouseEnter,lt=Rt.onMouseLeave,P=Rt.decimalSeparator,F=P===void 0?".":P,C=Rt.groupSeparator,_=C===void 0?",":C,L=ot.createElement(q,(0,et.Z)({decimalSeparator:F,groupSeparator:_},Rt,{value:bt})),U=ut()(Bt,(0,mt.Z)({},"".concat(Bt,"-rtl"),E==="rtl"),Ct);return ot.createElement("div",{className:U,style:wt,onMouseEnter:Q,onMouseLeave:lt},Y&&ot.createElement("div",{className:"".concat(Bt,"-title")},Y),ot.createElement(it.Z,{paragraph:!1,loading:D,className:"".concat(Bt,"-skeleton")},ot.createElement("div",{style:T,className:"".concat(Bt,"-content")},G&&ot.createElement("span",{className:"".concat(Bt,"-content-prefix")},G),V?V(L):L,A&&ot.createElement("span",{className:"".concat(Bt,"-content-suffix")},A))))},f=(0,xt.PG)({prefixCls:"statistic"})(p),J=f,K=N(28481),ht=N(32475),Mt=N.n(ht),X=[["Y",1e3*60*60*24*365],["M",1e3*60*60*24*30],["D",1e3*60*60*24],["H",1e3*60*60],["m",1e3*60],["s",1e3],["S",1]];function st(Pt,Rt){var Bt=Pt,Ct=/\[[^\]]*]/g,wt=(Rt.match(Ct)||[]).map(function(Y){return Y.slice(1,-1)}),T=Rt.replace(Ct,"[]"),z=X.reduce(function(Y,V){var G=(0,K.Z)(V,2),A=G[0],I=G[1];if(Y.includes(A)){var D=Math.floor(Bt/I);return Bt-=D*I,Y.replace(new RegExp("".concat(A,"+"),"g"),function(E){var Q=E.length;return Mt()(D.toString(),Q,"0")})}return Y},T),bt=0;return z.replace(Ct,function(){var Y=wt[bt];return bt+=1,Y})}function Et(Pt,Rt){var Bt=Rt.format,Ct=Bt===void 0?"":Bt,wt=new Date(Pt).getTime(),T=Date.now(),z=Math.max(wt-T,0);return st(z,Ct)}var zt=1e3/30;function jt(Pt){return new Date(Pt).getTime()}var ee=function(Rt){var Bt=Rt.value,Ct=Rt.format,wt=Ct===void 0?"HH:mm:ss":Ct,T=Rt.onChange,z=Rt.onFinish,bt=(0,Dt.Z)(),Y=ot.useRef(null),V=function(){z==null||z(),Y.current&&(clearInterval(Y.current),Y.current=null)},G=function(){var E=jt(Bt);E>=Date.now()&&(Y.current=setInterval(function(){bt(),T==null||T(E-Date.now()),E<Date.now()&&V()},zt))};ot.useEffect(function(){return G(),function(){Y.current&&(clearInterval(Y.current),Y.current=null)}},[Bt]);var A=function(E,Q){return Et(E,(0,et.Z)((0,et.Z)({},Q),{format:wt}))},I=function(E){return(0,It.Tm)(E,{title:void 0})};return ot.createElement(J,(0,et.Z)({},Rt,{valueRender:I,formatter:A}))},ye=ot.memo(ee);J.Countdown=ye;var pt=J},95300:function(ge,Xt,N){"use strict";var et=N(38663),ot=N.n(et),Dt=N(81903),It=N.n(Dt),mt=N(18446)},56645:function(ge,Xt){(function(N,et){et(Xt)})(this,function(N){"use strict";function et(pt,Pt){return ot(pt)||Dt(pt,Pt)||It()}function ot(pt){if(Array.isArray(pt))return pt}function Dt(pt,Pt){var Rt=[],Bt=!0,Ct=!1,wt=void 0;try{for(var T=pt[Symbol.iterator](),z;!(Bt=(z=T.next()).done)&&(Rt.push(z.value),!(Pt&&Rt.length===Pt));Bt=!0);}catch(bt){Ct=!0,wt=bt}finally{try{!Bt&&T.return!=null&&T.return()}finally{if(Ct)throw wt}}return Rt}function It(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}function mt(pt,Pt,Rt,Bt){pt=pt.filter(function(D,E){var Q=Pt(D,E),lt=Rt(D,E);return Q!=null&&isFinite(Q)&&lt!=null&&isFinite(lt)}),Bt&&pt.sort(function(D,E){return Pt(D)-Pt(E)});for(var Ct=pt.length,wt=new Float64Array(Ct),T=new Float64Array(Ct),z=0,bt=0,Y,V,G,A=0;A<Ct;)G=pt[A],wt[A]=Y=+Pt(G,A,pt),T[A]=V=+Rt(G,A,pt),++A,z+=(Y-z)/A,bt+=(V-bt)/A;for(var I=0;I<Ct;++I)wt[I]-=z,T[I]-=bt;return[wt,T,z,bt]}function yt(pt,Pt,Rt,Bt){for(var Ct=0,wt=0,T=pt.length;wt<T;wt++){var z=pt[wt],bt=+Pt(z,wt,pt),Y=+Rt(z,wt,pt);bt!=null&&isFinite(bt)&&Y!=null&&isFinite(Y)&&Bt(bt,Y,Ct++)}}function ut(pt,Pt,Rt,Bt,Ct){var wt=0,T=0;return yt(pt,Pt,Rt,function(z,bt){var Y=bt-Ct(z),V=bt-Bt;wt+=Y*Y,T+=V*V}),1-wt/T}function xt(pt){return Math.atan2(pt[1][1]-pt[0][1],pt[1][0]-pt[0][0])*180/Math.PI}function it(pt){return[(pt[0][0]+pt[1][0])/2,(pt[0][1]+pt[1][1])/2]}function Ut(pt,Pt,Rt){for(var Bt=Math.log(Pt-pt)*Math.LOG10E+1|0,Ct=1*Math.pow(10,-Bt/2-1),wt=1e4,T=[bt(pt),bt(Pt)],z=0;Y(T)&&z<wt;);return T;function bt(V){return[V,Rt(V)]}function Y(V){z++;for(var G=V.length,A=!1,I=0;I<G-1;I++){var D=V[I],E=V[I+1],Q=it([D,E]),lt=bt(Q[0]),P=xt([D,Q]),F=xt([D,lt]),C=Math.abs(P-F);C>Ct&&(V.splice(I+1,0,lt),A=!0)}return A}}function Ft(pt,Pt,Rt,Bt){var Ct=Bt-pt*pt,wt=Math.abs(Ct)<1e-24?0:(Rt-pt*Pt)/Ct,T=Pt-wt*pt;return[T,wt]}function ft(){var pt=function(wt){return wt[0]},Pt=function(wt){return wt[1]},Rt;function Bt(Ct){var wt=0,T=0,z=0,bt=0,Y=0,V=0,G=Rt?+Rt[0]:Infinity,A=Rt?+Rt[1]:-Infinity;yt(Ct,pt,Pt,function(F,C){var _=Math.log(C),L=F*C;++wt,T+=(C-T)/wt,bt+=(L-bt)/wt,V+=(F*L-V)/wt,z+=(C*_-z)/wt,Y+=(L*_-Y)/wt,Rt||(F<G&&(G=F),F>A&&(A=F))});var I=Ft(bt/T,z/T,Y/T,V/T),D=et(I,2),E=D[0],Q=D[1];E=Math.exp(E);var lt=function(C){return E*Math.exp(Q*C)},P=Ut(G,A,lt);return P.a=E,P.b=Q,P.predict=lt,P.rSquared=ut(Ct,pt,Pt,T,lt),P}return Bt.domain=function(Ct){return arguments.length?(Rt=Ct,Bt):Rt},Bt.x=function(Ct){return arguments.length?(pt=Ct,Bt):pt},Bt.y=function(Ct){return arguments.length?(Pt=Ct,Bt):Pt},Bt}function q(){var pt=function(wt){return wt[0]},Pt=function(wt){return wt[1]},Rt;function Bt(Ct){var wt=0,T=0,z=0,bt=0,Y=0,V=Rt?+Rt[0]:Infinity,G=Rt?+Rt[1]:-Infinity;yt(Ct,pt,Pt,function(P,F){++wt,T+=(P-T)/wt,z+=(F-z)/wt,bt+=(P*F-bt)/wt,Y+=(P*P-Y)/wt,Rt||(P<V&&(V=P),P>G&&(G=P))});var A=Ft(T,z,bt,Y),I=et(A,2),D=I[0],E=I[1],Q=function(F){return E*F+D},lt=[[V,Q(V)],[G,Q(G)]];return lt.a=E,lt.b=D,lt.predict=Q,lt.rSquared=ut(Ct,pt,Pt,z,Q),lt}return Bt.domain=function(Ct){return arguments.length?(Rt=Ct,Bt):Rt},Bt.x=function(Ct){return arguments.length?(pt=Ct,Bt):pt},Bt.y=function(Ct){return arguments.length?(Pt=Ct,Bt):Pt},Bt}function p(pt){pt.sort(function(Rt,Bt){return Rt-Bt});var Pt=pt.length/2;return Pt%1==0?(pt[Pt-1]+pt[Pt])/2:pt[Math.floor(Pt)]}var f=2,J=1e-12;function K(){var pt=function(wt){return wt[0]},Pt=function(wt){return wt[1]},Rt=.3;function Bt(Ct){for(var wt=mt(Ct,pt,Pt,!0),T=et(wt,4),z=T[0],bt=T[1],Y=T[2],V=T[3],G=z.length,A=Math.max(2,~~(Rt*G)),I=new Float64Array(G),D=new Float64Array(G),E=new Float64Array(G).fill(1),Q=-1;++Q<=f;){for(var lt=[0,A-1],P=0;P<G;++P){for(var F=z[P],C=lt[0],_=lt[1],L=F-z[C]>z[_]-F?C:_,U=0,B=0,j=0,nt=0,Tt=0,Jt=1/Math.abs(z[L]-F||1),$t=C;$t<=_;++$t){var ne=z[$t],qt=bt[$t],Yt=ht(Math.abs(F-ne)*Jt)*E[$t],fe=ne*Yt;U+=Yt,B+=fe,j+=qt*Yt,nt+=qt*fe,Tt+=ne*fe}var Pe=Ft(B/U,j/U,nt/U,Tt/U),Oe=et(Pe,2),Be=Oe[0],cr=Oe[1];I[P]=Be+cr*F,D[P]=Math.abs(bt[P]-I[P]),Mt(z,P+1,lt)}if(Q===f)break;var Er=p(D);if(Math.abs(Er)<J)break;for(var _r=0,tt,Z;_r<G;++_r)tt=D[_r]/(6*Er),E[_r]=tt>=1?J:(Z=1-tt*tt)*Z}return X(z,I,Y,V)}return Bt.bandwidth=function(Ct){return arguments.length?(Rt=Ct,Bt):Rt},Bt.x=function(Ct){return arguments.length?(pt=Ct,Bt):pt},Bt.y=function(Ct){return arguments.length?(Pt=Ct,Bt):Pt},Bt}function ht(pt){return(pt=1-pt*pt*pt)*pt*pt}function Mt(pt,Pt,Rt){var Bt=pt[Pt],Ct=Rt[0],wt=Rt[1]+1;if(!(wt>=pt.length))for(;Pt>Ct&&pt[wt]-Bt<=Bt-pt[Ct];)Rt[0]=++Ct,Rt[1]=wt,++wt}function X(pt,Pt,Rt,Bt){for(var Ct=pt.length,wt=[],T=0,z=0,bt=[],Y;T<Ct;++T)Y=pt[T]+Rt,bt[0]===Y?bt[1]+=(Pt[T]-bt[1])/++z:(z=0,bt[1]+=Bt,bt=[Y,Pt[T]],wt.push(bt));return bt[1]+=Bt,wt}function st(){var pt=function(T){return T[0]},Pt=function(T){return T[1]},Rt=Math.E,Bt;function Ct(wt){var T=0,z=0,bt=0,Y=0,V=0,G=Bt?+Bt[0]:Infinity,A=Bt?+Bt[1]:-Infinity,I=Math.log(Rt);yt(wt,pt,Pt,function(C,_){var L=Math.log(C)/I;++T,z+=(L-z)/T,bt+=(_-bt)/T,Y+=(L*_-Y)/T,V+=(L*L-V)/T,Bt||(C<G&&(G=C),C>A&&(A=C))});var D=Ft(z,bt,Y,V),E=et(D,2),Q=E[0],lt=E[1],P=function(_){return lt*Math.log(_)/I+Q},F=Ut(G,A,P);return F.a=lt,F.b=Q,F.predict=P,F.rSquared=ut(wt,pt,Pt,bt,P),F}return Ct.domain=function(wt){return arguments.length?(Bt=wt,Ct):Bt},Ct.x=function(wt){return arguments.length?(pt=wt,Ct):pt},Ct.y=function(wt){return arguments.length?(Pt=wt,Ct):Pt},Ct.base=function(wt){return arguments.length?(Rt=wt,Ct):Rt},Ct}function Et(){var pt=function(wt){return wt[0]},Pt=function(wt){return wt[1]},Rt;function Bt(Ct){var wt=mt(Ct,pt,Pt),T=et(wt,4),z=T[0],bt=T[1],Y=T[2],V=T[3],G=z.length,A=0,I=0,D=0,E=0,Q=0,lt,P,F,C;for(lt=0;lt<G;)P=z[lt],F=bt[lt++],C=P*P,A+=(C-A)/lt,I+=(C*P-I)/lt,D+=(C*C-D)/lt,E+=(P*F-E)/lt,Q+=(C*F-Q)/lt;var _=0,L=0,U=Rt?+Rt[0]:Infinity,B=Rt?+Rt[1]:-Infinity;yt(Ct,pt,Pt,function(Yt,fe){L++,_+=(fe-_)/L,Rt||(Yt<U&&(U=Yt),Yt>B&&(B=Yt))});var j=D-A*A,nt=A*j-I*I,Tt=(Q*A-E*I)/nt,Jt=(E*j-Q*I)/nt,$t=-Tt*A,ne=function(fe){return fe=fe-Y,Tt*fe*fe+Jt*fe+$t+V},qt=Ut(U,B,ne);return qt.a=Tt,qt.b=Jt-2*Tt*Y,qt.c=$t-Jt*Y+Tt*Y*Y+V,qt.predict=ne,qt.rSquared=ut(Ct,pt,Pt,_,ne),qt}return Bt.domain=function(Ct){return arguments.length?(Rt=Ct,Bt):Rt},Bt.x=function(Ct){return arguments.length?(pt=Ct,Bt):pt},Bt.y=function(Ct){return arguments.length?(Pt=Ct,Bt):Pt},Bt}function zt(){var pt=function(T){return T[0]},Pt=function(T){return T[1]},Rt=3,Bt;function Ct(wt){if(Rt===1){var T=q().x(pt).y(Pt).domain(Bt)(wt);return T.coefficients=[T.b,T.a],delete T.a,delete T.b,T}if(Rt===2){var z=Et().x(pt).y(Pt).domain(Bt)(wt);return z.coefficients=[z.c,z.b,z.a],delete z.a,delete z.b,delete z.c,z}var bt=mt(wt,pt,Pt),Y=et(bt,4),V=Y[0],G=Y[1],A=Y[2],I=Y[3],D=V.length,E=[],Q=[],lt=Rt+1,P=0,F=0,C=Bt?+Bt[0]:Infinity,_=Bt?+Bt[1]:-Infinity;yt(wt,pt,Pt,function(ne,qt){++F,P+=(qt-P)/F,Bt||(ne<C&&(C=ne),ne>_&&(_=ne))});var L,U,B,j,nt;for(L=0;L<lt;++L){for(B=0,j=0;B<D;++B)j+=Math.pow(V[B],L)*G[B];for(E.push(j),nt=new Float64Array(lt),U=0;U<lt;++U){for(B=0,j=0;B<D;++B)j+=Math.pow(V[B],L+U);nt[U]=j}Q.push(nt)}Q.push(E);var Tt=ee(Q),Jt=function(qt){qt-=A;var Yt=I+Tt[0]+Tt[1]*qt+Tt[2]*qt*qt;for(L=3;L<lt;++L)Yt+=Tt[L]*Math.pow(qt,L);return Yt},$t=Ut(C,_,Jt);return $t.coefficients=jt(lt,Tt,-A,I),$t.predict=Jt,$t.rSquared=ut(wt,pt,Pt,P,Jt),$t}return Ct.domain=function(wt){return arguments.length?(Bt=wt,Ct):Bt},Ct.x=function(wt){return arguments.length?(pt=wt,Ct):pt},Ct.y=function(wt){return arguments.length?(Pt=wt,Ct):Pt},Ct.order=function(wt){return arguments.length?(Rt=wt,Ct):Rt},Ct}function jt(pt,Pt,Rt,Bt){var Ct=Array(pt),wt,T,z,bt;for(wt=0;wt<pt;++wt)Ct[wt]=0;for(wt=pt-1;wt>=0;--wt)for(z=Pt[wt],bt=1,Ct[wt]+=z,T=1;T<=wt;++T)bt*=(wt+1-T)/T,Ct[wt-T]+=z*Math.pow(Rt,T)*bt;return Ct[0]+=Bt,Ct}function ee(pt){var Pt=pt.length-1,Rt=[],Bt,Ct,wt,T,z;for(Bt=0;Bt<Pt;++Bt){for(T=Bt,Ct=Bt+1;Ct<Pt;++Ct)Math.abs(pt[Bt][Ct])>Math.abs(pt[Bt][T])&&(T=Ct);for(wt=Bt;wt<Pt+1;++wt)z=pt[wt][Bt],pt[wt][Bt]=pt[wt][T],pt[wt][T]=z;for(Ct=Bt+1;Ct<Pt;++Ct)for(wt=Pt;wt>=Bt;wt--)pt[wt][Ct]-=pt[wt][Bt]*pt[Bt][Ct]/pt[Bt][Bt]}for(Ct=Pt-1;Ct>=0;--Ct){for(z=0,wt=Ct+1;wt<Pt;++wt)z+=pt[wt][Ct]*Rt[wt];Rt[Ct]=(pt[Pt][Ct]-z)/pt[Ct][Ct]}return Rt}function ye(){var pt=function(wt){return wt[0]},Pt=function(wt){return wt[1]},Rt;function Bt(Ct){var wt=0,T=0,z=0,bt=0,Y=0,V=0,G=Rt?+Rt[0]:Infinity,A=Rt?+Rt[1]:-Infinity;yt(Ct,pt,Pt,function(F,C){var _=Math.log(F),L=Math.log(C);++wt,T+=(_-T)/wt,z+=(L-z)/wt,bt+=(_*L-bt)/wt,Y+=(_*_-Y)/wt,V+=(C-V)/wt,Rt||(F<G&&(G=F),F>A&&(A=F))});var I=Ft(T,z,bt,Y),D=et(I,2),E=D[0],Q=D[1];E=Math.exp(E);var lt=function(C){return E*Math.pow(C,Q)},P=Ut(G,A,lt);return P.a=E,P.b=Q,P.predict=lt,P.rSquared=ut(Ct,pt,Pt,V,lt),P}return Bt.domain=function(Ct){return arguments.length?(Rt=Ct,Bt):Rt},Bt.x=function(Ct){return arguments.length?(pt=Ct,Bt):pt},Bt.y=function(Ct){return arguments.length?(Pt=Ct,Bt):Pt},Bt}N.regressionExp=ft,N.regressionLinear=q,N.regressionLoess=K,N.regressionLog=st,N.regressionPoly=zt,N.regressionPow=ye,N.regressionQuad=Et,Object.defineProperty(N,"__esModule",{value:!0})})},43631:function(ge,Xt,N){"use strict";N.d(Xt,{qY:function(){return q}});var et=N(34155),ot=function(X,st,Et){if(Et||arguments.length===2)for(var zt=0,jt=st.length,ee;zt<jt;zt++)(ee||!(zt in st))&&(ee||(ee=Array.prototype.slice.call(st,0,zt)),ee[zt]=st[zt]);return X.concat(ee||Array.prototype.slice.call(st))},Dt=function(){function X(st,Et,zt){this.name=st,this.version=Et,this.os=zt,this.type="browser"}return X}(),It=function(){function X(st){this.version=st,this.type="node",this.name="node",this.os=et.platform}return X}(),mt=function(){function X(st,Et,zt,jt){this.name=st,this.version=Et,this.os=zt,this.bot=jt,this.type="bot-device"}return X}(),yt=function(){function X(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null}return X}(),ut=function(){function X(){this.type="react-native",this.name="react-native",this.version=null,this.os=null}return X}(),xt=/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/,it=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,Ut=3,Ft=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["pie",/^Microsoft Pocket Internet Explorer\/(\d+\.\d+)$/],["pie",/^Mozilla\/\d\.\d+\s\(compatible;\s(?:MSP?IE|MSInternet Explorer) (\d+\.\d+);.*Windows CE.*\)$/],["netfront",/^Mozilla\/\d\.\d+.*NetFront\/(\d.\d)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",xt]],ft=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Windows CE",/Windows CE|WinCE|Microsoft Pocket Internet Explorer/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function q(X){return X?J(X):typeof document=="undefined"&&typeof navigator!="undefined"&&navigator.product==="ReactNative"?new ut:typeof navigator!="undefined"?J(navigator.userAgent):ht()}function p(X){return X!==""&&Ft.reduce(function(st,Et){var zt=Et[0],jt=Et[1];if(st)return st;var ee=jt.exec(X);return!!ee&&[zt,ee]},!1)}function f(X){var st=p(X);return st?st[0]:null}function J(X){var st=p(X);if(!st)return null;var Et=st[0],zt=st[1];if(Et==="searchbot")return new yt;var jt=zt[1]&&zt[1].split(".").join("_").split("_").slice(0,3);jt?jt.length<Ut&&(jt=ot(ot([],jt,!0),Mt(Ut-jt.length),!0)):jt=[];var ee=jt.join("."),ye=K(X),pt=it.exec(X);return pt&&pt[1]?new mt(Et,ee,ye,pt[1]):new Dt(Et,ee,ye)}function K(X){for(var st=0,Et=ft.length;st<Et;st++){var zt=ft[st],jt=zt[0],ee=zt[1],ye=ee.exec(X);if(ye)return jt}return null}function ht(){var X=typeof et!="undefined"&&et.version;return X?new It(et.version.slice(1)):null}function Mt(X){for(var st=[],Et=0;Et<X;Et++)st.push("0");return st}},87026:function(ge,Xt){(function(N,et){et(Xt)})(this,function(N){"use strict";function et(q,p,f,J){J=J||{};var K=J.maxIterations||100,ht=J.tolerance||1e-10,Mt=q(p),X=q(f),st=f-p;if(Mt*X>0)throw"Initial bisect points must have opposite signs";if(Mt===0)return p;if(X===0)return f;for(var Et=0;Et<K;++Et){st/=2;var zt=p+st,jt=q(zt);if(jt*Mt>=0&&(p=zt),Math.abs(st)<ht||jt===0)return zt}return p+st}function ot(q){for(var p=new Array(q),f=0;f<q;++f)p[f]=0;return p}function Dt(q,p){return ot(q).map(function(){return ot(p)})}function It(q,p){for(var f=0,J=0;J<q.length;++J)f+=q[J]*p[J];return f}function mt(q){return Math.sqrt(It(q,q))}function yt(q,p,f){for(var J=0;J<p.length;++J)q[J]=p[J]*f}function ut(q,p,f,J,K){for(var ht=0;ht<q.length;++ht)q[ht]=p*f[ht]+J*K[ht]}function xt(q,p,f){f=f||{};var J=f.maxIterations||p.length*200,K=f.nonZeroDelta||1.05,ht=f.zeroDelta||.001,Mt=f.minErrorDelta||1e-6,X=f.minErrorDelta||1e-5,st=f.rho!==void 0?f.rho:1,Et=f.chi!==void 0?f.chi:2,zt=f.psi!==void 0?f.psi:-.5,jt=f.sigma!==void 0?f.sigma:.5,ee,ye=p.length,pt=new Array(ye+1);pt[0]=p,pt[0].fx=q(p),pt[0].id=0;for(var Pt=0;Pt<ye;++Pt){var Rt=p.slice();Rt[Pt]=Rt[Pt]?Rt[Pt]*K:ht,pt[Pt+1]=Rt,pt[Pt+1].fx=q(Rt),pt[Pt+1].id=Pt+1}function Bt(D){for(var E=0;E<D.length;E++)pt[ye][E]=D[E];pt[ye].fx=D.fx}for(var Ct=function(D,E){return D.fx-E.fx},wt=p.slice(),T=p.slice(),z=p.slice(),bt=p.slice(),Y=0;Y<J;++Y){if(pt.sort(Ct),f.history){var V=pt.map(function(D){var E=D.slice();return E.fx=D.fx,E.id=D.id,E});V.sort(function(D,E){return D.id-E.id}),f.history.push({x:pt[0].slice(),fx:pt[0].fx,simplex:V})}for(ee=0,Pt=0;Pt<ye;++Pt)ee=Math.max(ee,Math.abs(pt[0][Pt]-pt[1][Pt]));if(Math.abs(pt[0].fx-pt[ye].fx)<Mt&&ee<X)break;for(Pt=0;Pt<ye;++Pt){wt[Pt]=0;for(var G=0;G<ye;++G)wt[Pt]+=pt[G][Pt];wt[Pt]/=ye}var A=pt[ye];if(ut(T,1+st,wt,-st,A),T.fx=q(T),T.fx<pt[0].fx)ut(bt,1+Et,wt,-Et,A),bt.fx=q(bt),bt.fx<T.fx?Bt(bt):Bt(T);else if(T.fx>=pt[ye-1].fx){var I=!1;if(T.fx>A.fx?(ut(z,1+zt,wt,-zt,A),z.fx=q(z),z.fx<A.fx?Bt(z):I=!0):(ut(z,1-zt*st,wt,zt*st,A),z.fx=q(z),z.fx<T.fx?Bt(z):I=!0),I){if(jt>=1)break;for(Pt=1;Pt<pt.length;++Pt)ut(pt[Pt],1-jt,pt[0],jt,pt[Pt]),pt[Pt].fx=q(pt[Pt])}}else Bt(T)}return pt.sort(Ct),{fx:pt[0].fx,x:pt[0]}}function it(q,p,f,J,K,ht,Mt){var X=f.fx,st=It(f.fxprime,p),Et=X,zt=X,jt=st,ee=0;K=K||1,ht=ht||1e-6,Mt=Mt||.1;function ye(Pt,Rt,Bt){for(var Ct=0;Ct<16;++Ct)if(K=(Pt+Rt)/2,ut(J.x,1,f.x,K,p),Et=J.fx=q(J.x,J.fxprime),jt=It(J.fxprime,p),Et>X+ht*K*st||Et>=Bt)Rt=K;else{if(Math.abs(jt)<=-Mt*st)return K;jt*(Rt-Pt)>=0&&(Rt=Pt),Pt=K,Bt=Et}return 0}for(var pt=0;pt<10;++pt){if(ut(J.x,1,f.x,K,p),Et=J.fx=q(J.x,J.fxprime),jt=It(J.fxprime,p),Et>X+ht*K*st||pt&&Et>=zt)return ye(ee,K,zt);if(Math.abs(jt)<=-Mt*st)return K;if(jt>=0)return ye(K,ee,Et);zt=Et,ee=K,K*=2}return K}function Ut(q,p,f){var J={x:p.slice(),fx:0,fxprime:p.slice()},K={x:p.slice(),fx:0,fxprime:p.slice()},ht=p.slice(),Mt,X,st=1,Et;f=f||{},Et=f.maxIterations||p.length*20,J.fx=q(J.x,J.fxprime),Mt=J.fxprime.slice(),yt(Mt,J.fxprime,-1);for(var zt=0;zt<Et;++zt){if(st=it(q,Mt,J,K,st),f.history&&f.history.push({x:J.x.slice(),fx:J.fx,fxprime:J.fxprime.slice(),alpha:st}),!st)yt(Mt,J.fxprime,-1);else{ut(ht,1,K.fxprime,-1,J.fxprime);var jt=It(J.fxprime,J.fxprime),ee=Math.max(0,It(ht,K.fxprime)/jt);ut(Mt,ee,Mt,-1,K.fxprime),X=J,J=K,K=X}if(mt(J.fxprime)<=1e-5)break}return f.history&&f.history.push({x:J.x.slice(),fx:J.fx,fxprime:J.fxprime.slice(),alpha:st}),J}function Ft(q,p,f){f=f||{};for(var J=f.maxIterations||p.length*100,K=f.learnRate||.001,ht={x:p.slice(),fx:0,fxprime:p.slice()},Mt=0;Mt<J&&(ht.fx=q(ht.x,ht.fxprime),f.history&&f.history.push({x:ht.x.slice(),fx:ht.fx,fxprime:ht.fxprime.slice()}),ut(ht.x,1,ht.x,-K,ht.fxprime),!(mt(ht.fxprime)<=1e-5));++Mt);return ht}function ft(q,p,f){f=f||{};var J={x:p.slice(),fx:0,fxprime:p.slice()},K={x:p.slice(),fx:0,fxprime:p.slice()},ht=f.maxIterations||p.length*100,Mt=f.learnRate||1,X=p.slice(),st=f.c1||.001,Et=f.c2||.1,zt,jt=[];if(f.history){var ee=q;q=function(pt,Pt){return jt.push(pt.slice()),ee(pt,Pt)}}J.fx=q(J.x,J.fxprime);for(var ye=0;ye<ht&&(yt(X,J.fxprime,-1),Mt=it(q,X,J,K,Mt,st,Et),f.history&&(f.history.push({x:J.x.slice(),fx:J.fx,fxprime:J.fxprime.slice(),functionCalls:jt,learnRate:Mt,alpha:Mt}),jt=[]),zt=J,J=K,K=zt,!(Mt===0||mt(J.fxprime)<1e-5));++ye);return J}N.bisect=et,N.nelderMead=xt,N.conjugateGradient=Ut,N.gradientDescent=Ft,N.gradientDescentLineSearch=ft,N.zeros=ot,N.zerosM=Dt,N.norm2=mt,N.weightedSum=ut,N.scale=yt})},49685:function(ge,Xt,N){"use strict";N.d(Xt,{WT:function(){return ot}});var et=1e-6,ot=typeof Float32Array!="undefined"?Float32Array:Array,Dt=Math.random;function It(xt){ot=xt}var mt=Math.PI/180;function yt(xt){return xt*mt}function ut(xt,it){return Math.abs(xt-it)<=et*Math.max(1,Math.abs(xt),Math.abs(it))}Math.hypot||(Math.hypot=function(){for(var xt=0,it=arguments.length;it--;)xt+=arguments[it]*arguments[it];return Math.sqrt(xt)})},35600:function(ge,Xt,N){"use strict";N.d(Xt,{U_:function(){return it},Jp:function(){return ft},vc:function(){return J},Us:function(){return K},xJ:function(){return ht}});function et(){var T=new glMatrix.ARRAY_TYPE(9);return glMatrix.ARRAY_TYPE!=Float32Array&&(T[1]=0,T[2]=0,T[3]=0,T[5]=0,T[6]=0,T[7]=0),T[0]=1,T[4]=1,T[8]=1,T}function ot(T,z){return T[0]=z[0],T[1]=z[1],T[2]=z[2],T[3]=z[4],T[4]=z[5],T[5]=z[6],T[6]=z[8],T[7]=z[9],T[8]=z[10],T}function Dt(T){var z=new glMatrix.ARRAY_TYPE(9);return z[0]=T[0],z[1]=T[1],z[2]=T[2],z[3]=T[3],z[4]=T[4],z[5]=T[5],z[6]=T[6],z[7]=T[7],z[8]=T[8],z}function It(T,z){return T[0]=z[0],T[1]=z[1],T[2]=z[2],T[3]=z[3],T[4]=z[4],T[5]=z[5],T[6]=z[6],T[7]=z[7],T[8]=z[8],T}function mt(T,z,bt,Y,V,G,A,I,D){var E=new glMatrix.ARRAY_TYPE(9);return E[0]=T,E[1]=z,E[2]=bt,E[3]=Y,E[4]=V,E[5]=G,E[6]=A,E[7]=I,E[8]=D,E}function yt(T,z,bt,Y,V,G,A,I,D,E){return T[0]=z,T[1]=bt,T[2]=Y,T[3]=V,T[4]=G,T[5]=A,T[6]=I,T[7]=D,T[8]=E,T}function ut(T){return T[0]=1,T[1]=0,T[2]=0,T[3]=0,T[4]=1,T[5]=0,T[6]=0,T[7]=0,T[8]=1,T}function xt(T,z){if(T===z){var bt=z[1],Y=z[2],V=z[5];T[1]=z[3],T[2]=z[6],T[3]=bt,T[5]=z[7],T[6]=Y,T[7]=V}else T[0]=z[0],T[1]=z[3],T[2]=z[6],T[3]=z[1],T[4]=z[4],T[5]=z[7],T[6]=z[2],T[7]=z[5],T[8]=z[8];return T}function it(T,z){var bt=z[0],Y=z[1],V=z[2],G=z[3],A=z[4],I=z[5],D=z[6],E=z[7],Q=z[8],lt=Q*A-I*E,P=-Q*G+I*D,F=E*G-A*D,C=bt*lt+Y*P+V*F;return C?(C=1/C,T[0]=lt*C,T[1]=(-Q*Y+V*E)*C,T[2]=(I*Y-V*A)*C,T[3]=P*C,T[4]=(Q*bt-V*D)*C,T[5]=(-I*bt+V*G)*C,T[6]=F*C,T[7]=(-E*bt+Y*D)*C,T[8]=(A*bt-Y*G)*C,T):null}function Ut(T,z){var bt=z[0],Y=z[1],V=z[2],G=z[3],A=z[4],I=z[5],D=z[6],E=z[7],Q=z[8];return T[0]=A*Q-I*E,T[1]=V*E-Y*Q,T[2]=Y*I-V*A,T[3]=I*D-G*Q,T[4]=bt*Q-V*D,T[5]=V*G-bt*I,T[6]=G*E-A*D,T[7]=Y*D-bt*E,T[8]=bt*A-Y*G,T}function Ft(T){var z=T[0],bt=T[1],Y=T[2],V=T[3],G=T[4],A=T[5],I=T[6],D=T[7],E=T[8];return z*(E*G-A*D)+bt*(-E*V+A*I)+Y*(D*V-G*I)}function ft(T,z,bt){var Y=z[0],V=z[1],G=z[2],A=z[3],I=z[4],D=z[5],E=z[6],Q=z[7],lt=z[8],P=bt[0],F=bt[1],C=bt[2],_=bt[3],L=bt[4],U=bt[5],B=bt[6],j=bt[7],nt=bt[8];return T[0]=P*Y+F*A+C*E,T[1]=P*V+F*I+C*Q,T[2]=P*G+F*D+C*lt,T[3]=_*Y+L*A+U*E,T[4]=_*V+L*I+U*Q,T[5]=_*G+L*D+U*lt,T[6]=B*Y+j*A+nt*E,T[7]=B*V+j*I+nt*Q,T[8]=B*G+j*D+nt*lt,T}function q(T,z,bt){var Y=z[0],V=z[1],G=z[2],A=z[3],I=z[4],D=z[5],E=z[6],Q=z[7],lt=z[8],P=bt[0],F=bt[1];return T[0]=Y,T[1]=V,T[2]=G,T[3]=A,T[4]=I,T[5]=D,T[6]=P*Y+F*A+E,T[7]=P*V+F*I+Q,T[8]=P*G+F*D+lt,T}function p(T,z,bt){var Y=z[0],V=z[1],G=z[2],A=z[3],I=z[4],D=z[5],E=z[6],Q=z[7],lt=z[8],P=Math.sin(bt),F=Math.cos(bt);return T[0]=F*Y+P*A,T[1]=F*V+P*I,T[2]=F*G+P*D,T[3]=F*A-P*Y,T[4]=F*I-P*V,T[5]=F*D-P*G,T[6]=E,T[7]=Q,T[8]=lt,T}function f(T,z,bt){var Y=bt[0],V=bt[1];return T[0]=Y*z[0],T[1]=Y*z[1],T[2]=Y*z[2],T[3]=V*z[3],T[4]=V*z[4],T[5]=V*z[5],T[6]=z[6],T[7]=z[7],T[8]=z[8],T}function J(T,z){return T[0]=1,T[1]=0,T[2]=0,T[3]=0,T[4]=1,T[5]=0,T[6]=z[0],T[7]=z[1],T[8]=1,T}function K(T,z){var bt=Math.sin(z),Y=Math.cos(z);return T[0]=Y,T[1]=bt,T[2]=0,T[3]=-bt,T[4]=Y,T[5]=0,T[6]=0,T[7]=0,T[8]=1,T}function ht(T,z){return T[0]=z[0],T[1]=0,T[2]=0,T[3]=0,T[4]=z[1],T[5]=0,T[6]=0,T[7]=0,T[8]=1,T}function Mt(T,z){return T[0]=z[0],T[1]=z[1],T[2]=0,T[3]=z[2],T[4]=z[3],T[5]=0,T[6]=z[4],T[7]=z[5],T[8]=1,T}function X(T,z){var bt=z[0],Y=z[1],V=z[2],G=z[3],A=bt+bt,I=Y+Y,D=V+V,E=bt*A,Q=Y*A,lt=Y*I,P=V*A,F=V*I,C=V*D,_=G*A,L=G*I,U=G*D;return T[0]=1-lt-C,T[3]=Q-U,T[6]=P+L,T[1]=Q+U,T[4]=1-E-C,T[7]=F-_,T[2]=P-L,T[5]=F+_,T[8]=1-E-lt,T}function st(T,z){var bt=z[0],Y=z[1],V=z[2],G=z[3],A=z[4],I=z[5],D=z[6],E=z[7],Q=z[8],lt=z[9],P=z[10],F=z[11],C=z[12],_=z[13],L=z[14],U=z[15],B=bt*I-Y*A,j=bt*D-V*A,nt=bt*E-G*A,Tt=Y*D-V*I,Jt=Y*E-G*I,$t=V*E-G*D,ne=Q*_-lt*C,qt=Q*L-P*C,Yt=Q*U-F*C,fe=lt*L-P*_,Pe=lt*U-F*_,Oe=P*U-F*L,Be=B*Oe-j*Pe+nt*fe+Tt*Yt-Jt*qt+$t*ne;return Be?(Be=1/Be,T[0]=(I*Oe-D*Pe+E*fe)*Be,T[1]=(D*Yt-A*Oe-E*qt)*Be,T[2]=(A*Pe-I*Yt+E*ne)*Be,T[3]=(V*Pe-Y*Oe-G*fe)*Be,T[4]=(bt*Oe-V*Yt+G*qt)*Be,T[5]=(Y*Yt-bt*Pe-G*ne)*Be,T[6]=(_*$t-L*Jt+U*Tt)*Be,T[7]=(L*nt-C*$t-U*j)*Be,T[8]=(C*Jt-_*nt+U*B)*Be,T):null}function Et(T,z,bt){return T[0]=2/z,T[1]=0,T[2]=0,T[3]=0,T[4]=-2/bt,T[5]=0,T[6]=-1,T[7]=1,T[8]=1,T}function zt(T){return"mat3("+T[0]+", "+T[1]+", "+T[2]+", "+T[3]+", "+T[4]+", "+T[5]+", "+T[6]+", "+T[7]+", "+T[8]+")"}function jt(T){return Math.hypot(T[0],T[1],T[2],T[3],T[4],T[5],T[6],T[7],T[8])}function ee(T,z,bt){return T[0]=z[0]+bt[0],T[1]=z[1]+bt[1],T[2]=z[2]+bt[2],T[3]=z[3]+bt[3],T[4]=z[4]+bt[4],T[5]=z[5]+bt[5],T[6]=z[6]+bt[6],T[7]=z[7]+bt[7],T[8]=z[8]+bt[8],T}function ye(T,z,bt){return T[0]=z[0]-bt[0],T[1]=z[1]-bt[1],T[2]=z[2]-bt[2],T[3]=z[3]-bt[3],T[4]=z[4]-bt[4],T[5]=z[5]-bt[5],T[6]=z[6]-bt[6],T[7]=z[7]-bt[7],T[8]=z[8]-bt[8],T}function pt(T,z,bt){return T[0]=z[0]*bt,T[1]=z[1]*bt,T[2]=z[2]*bt,T[3]=z[3]*bt,T[4]=z[4]*bt,T[5]=z[5]*bt,T[6]=z[6]*bt,T[7]=z[7]*bt,T[8]=z[8]*bt,T}function Pt(T,z,bt,Y){return T[0]=z[0]+bt[0]*Y,T[1]=z[1]+bt[1]*Y,T[2]=z[2]+bt[2]*Y,T[3]=z[3]+bt[3]*Y,T[4]=z[4]+bt[4]*Y,T[5]=z[5]+bt[5]*Y,T[6]=z[6]+bt[6]*Y,T[7]=z[7]+bt[7]*Y,T[8]=z[8]+bt[8]*Y,T}function Rt(T,z){return T[0]===z[0]&&T[1]===z[1]&&T[2]===z[2]&&T[3]===z[3]&&T[4]===z[4]&&T[5]===z[5]&&T[6]===z[6]&&T[7]===z[7]&&T[8]===z[8]}function Bt(T,z){var bt=T[0],Y=T[1],V=T[2],G=T[3],A=T[4],I=T[5],D=T[6],E=T[7],Q=T[8],lt=z[0],P=z[1],F=z[2],C=z[3],_=z[4],L=z[5],U=z[6],B=z[7],j=z[8];return Math.abs(bt-lt)<=glMatrix.EPSILON*Math.max(1,Math.abs(bt),Math.abs(lt))&&Math.abs(Y-P)<=glMatrix.EPSILON*Math.max(1,Math.abs(Y),Math.abs(P))&&Math.abs(V-F)<=glMatrix.EPSILON*Math.max(1,Math.abs(V),Math.abs(F))&&Math.abs(G-C)<=glMatrix.EPSILON*Math.max(1,Math.abs(G),Math.abs(C))&&Math.abs(A-_)<=glMatrix.EPSILON*Math.max(1,Math.abs(A),Math.abs(_))&&Math.abs(I-L)<=glMatrix.EPSILON*Math.max(1,Math.abs(I),Math.abs(L))&&Math.abs(D-U)<=glMatrix.EPSILON*Math.max(1,Math.abs(D),Math.abs(U))&&Math.abs(E-B)<=glMatrix.EPSILON*Math.max(1,Math.abs(E),Math.abs(B))&&Math.abs(Q-j)<=glMatrix.EPSILON*Math.max(1,Math.abs(Q),Math.abs(j))}var Ct=null,wt=null},31437:function(ge,Xt,N){"use strict";N.d(Xt,{IH:function(){return ut},$X:function(){return xt},VV:function(){return q},Fp:function(){return p},bA:function(){return J},TE:function(){return ht},kE:function(){return X},Fv:function(){return jt},AK:function(){return ee},kK:function(){return Ct},EU:function(){return z},I6:function(){return V},lu:function(){return I}});var et=N(49685);function ot(){var C=new et.WT(2);return et.WT!=Float32Array&&(C[0]=0,C[1]=0),C}function Dt(C){var _=new glMatrix.ARRAY_TYPE(2);return _[0]=C[0],_[1]=C[1],_}function It(C,_){var L=new glMatrix.ARRAY_TYPE(2);return L[0]=C,L[1]=_,L}function mt(C,_){return C[0]=_[0],C[1]=_[1],C}function yt(C,_,L){return C[0]=_,C[1]=L,C}function ut(C,_,L){return C[0]=_[0]+L[0],C[1]=_[1]+L[1],C}function xt(C,_,L){return C[0]=_[0]-L[0],C[1]=_[1]-L[1],C}function it(C,_,L){return C[0]=_[0]*L[0],C[1]=_[1]*L[1],C}function Ut(C,_,L){return C[0]=_[0]/L[0],C[1]=_[1]/L[1],C}function Ft(C,_){return C[0]=Math.ceil(_[0]),C[1]=Math.ceil(_[1]),C}function ft(C,_){return C[0]=Math.floor(_[0]),C[1]=Math.floor(_[1]),C}function q(C,_,L){return C[0]=Math.min(_[0],L[0]),C[1]=Math.min(_[1],L[1]),C}function p(C,_,L){return C[0]=Math.max(_[0],L[0]),C[1]=Math.max(_[1],L[1]),C}function f(C,_){return C[0]=Math.round(_[0]),C[1]=Math.round(_[1]),C}function J(C,_,L){return C[0]=_[0]*L,C[1]=_[1]*L,C}function K(C,_,L,U){return C[0]=_[0]+L[0]*U,C[1]=_[1]+L[1]*U,C}function ht(C,_){var L=_[0]-C[0],U=_[1]-C[1];return Math.hypot(L,U)}function Mt(C,_){var L=_[0]-C[0],U=_[1]-C[1];return L*L+U*U}function X(C){var _=C[0],L=C[1];return Math.hypot(_,L)}function st(C){var _=C[0],L=C[1];return _*_+L*L}function Et(C,_){return C[0]=-_[0],C[1]=-_[1],C}function zt(C,_){return C[0]=1/_[0],C[1]=1/_[1],C}function jt(C,_){var L=_[0],U=_[1],B=L*L+U*U;return B>0&&(B=1/Math.sqrt(B)),C[0]=_[0]*B,C[1]=_[1]*B,C}function ee(C,_){return C[0]*_[0]+C[1]*_[1]}function ye(C,_,L){var U=_[0]*L[1]-_[1]*L[0];return C[0]=C[1]=0,C[2]=U,C}function pt(C,_,L,U){var B=_[0],j=_[1];return C[0]=B+U*(L[0]-B),C[1]=j+U*(L[1]-j),C}function Pt(C,_){_=_||1;var L=glMatrix.RANDOM()*2*Math.PI;return C[0]=Math.cos(L)*_,C[1]=Math.sin(L)*_,C}function Rt(C,_,L){var U=_[0],B=_[1];return C[0]=L[0]*U+L[2]*B,C[1]=L[1]*U+L[3]*B,C}function Bt(C,_,L){var U=_[0],B=_[1];return C[0]=L[0]*U+L[2]*B+L[4],C[1]=L[1]*U+L[3]*B+L[5],C}function Ct(C,_,L){var U=_[0],B=_[1];return C[0]=L[0]*U+L[3]*B+L[6],C[1]=L[1]*U+L[4]*B+L[7],C}function wt(C,_,L){var U=_[0],B=_[1];return C[0]=L[0]*U+L[4]*B+L[12],C[1]=L[1]*U+L[5]*B+L[13],C}function T(C,_,L,U){var B=_[0]-L[0],j=_[1]-L[1],nt=Math.sin(U),Tt=Math.cos(U);return C[0]=B*Tt-j*nt+L[0],C[1]=B*nt+j*Tt+L[1],C}function z(C,_){var L=C[0],U=C[1],B=_[0],j=_[1],nt=Math.sqrt(L*L+U*U)*Math.sqrt(B*B+j*j),Tt=nt&&(L*B+U*j)/nt;return Math.acos(Math.min(Math.max(Tt,-1),1))}function bt(C){return C[0]=0,C[1]=0,C}function Y(C){return"vec2("+C[0]+", "+C[1]+")"}function V(C,_){return C[0]===_[0]&&C[1]===_[1]}function G(C,_){var L=C[0],U=C[1],B=_[0],j=_[1];return Math.abs(L-B)<=glMatrix.EPSILON*Math.max(1,Math.abs(L),Math.abs(B))&&Math.abs(U-j)<=glMatrix.EPSILON*Math.max(1,Math.abs(U),Math.abs(j))}var A=null,I=xt,D=null,E=null,Q=null,lt=null,P=null,F=function(){var C=ot();return function(_,L,U,B,j,nt){var Tt,Jt;for(L||(L=2),U||(U=0),B?Jt=Math.min(B*L+U,_.length):Jt=_.length,Tt=U;Tt<Jt;Tt+=L)C[0]=_[Tt],C[1]=_[Tt+1],j(C,C,nt),_[Tt]=C[0],_[Tt+1]=C[1];return _}}()},48983:function(ge,Xt,N){var et=N(40371),ot=et("length");ge.exports=ot},40371:function(ge){function Xt(N){return function(et){return et==null?void 0:et[N]}}ge.exports=Xt},18190:function(ge){var Xt=9007199254740991,N=Math.floor;function et(ot,Dt){var It="";if(!ot||Dt<1||Dt>Xt)return It;do Dt%2&&(It+=ot),Dt=N(Dt/2),Dt&&(ot+=ot);while(Dt);return It}ge.exports=et},78302:function(ge,Xt,N){var et=N(18190),ot=N(80531),Dt=N(40180),It=N(62689),mt=N(88016),yt=N(83140),ut=Math.ceil;function xt(it,Ut){Ut=Ut===void 0?" ":ot(Ut);var Ft=Ut.length;if(Ft<2)return Ft?et(Ut,it):Ut;var ft=et(Ut,ut(it/mt(Ut)));return It(Ut)?Dt(yt(ft),0,it).join(""):ft.slice(0,it)}ge.exports=xt},88016:function(ge,Xt,N){var et=N(48983),ot=N(62689),Dt=N(21903);function It(mt){return ot(mt)?Dt(mt):et(mt)}ge.exports=It},21903:function(ge){var Xt="\\ud800-\\udfff",N="\\u0300-\\u036f",et="\\ufe20-\\ufe2f",ot="\\u20d0-\\u20ff",Dt=N+et+ot,It="\\ufe0e\\ufe0f",mt="["+Xt+"]",yt="["+Dt+"]",ut="\\ud83c[\\udffb-\\udfff]",xt="(?:"+yt+"|"+ut+")",it="[^"+Xt+"]",Ut="(?:\\ud83c[\\udde6-\\uddff]){2}",Ft="[\\ud800-\\udbff][\\udc00-\\udfff]",ft="\\u200d",q=xt+"?",p="["+It+"]?",f="(?:"+ft+"(?:"+[it,Ut,Ft].join("|")+")"+p+q+")*",J=p+q+f,K="(?:"+[it+yt+"?",yt,Ut,Ft,mt].join("|")+")",ht=RegExp(ut+"(?="+ut+")|"+K+J,"g");function Mt(X){for(var st=ht.lastIndex=0;ht.test(X);)++st;return st}ge.exports=Mt},11726:function(ge,Xt,N){var et=N(78302),ot=N(88016),Dt=N(40554),It=N(79833);function mt(yt,ut,xt){yt=It(yt),ut=Dt(ut);var it=ut?ot(yt):0;return ut&&it<ut?yt+et(ut-it,xt):yt}ge.exports=mt},32475:function(ge,Xt,N){var et=N(78302),ot=N(88016),Dt=N(40554),It=N(79833);function mt(yt,ut,xt){yt=It(yt),ut=Dt(ut);var it=ut?ot(yt):0;return ut&&it<ut?et(ut-it,xt)+yt:yt}ge.exports=mt},18601:function(ge,Xt,N){var et=N(14841),ot=1/0,Dt=17976931348623157e292;function It(mt){if(!mt)return mt===0?mt:0;if(mt=et(mt),mt===ot||mt===-ot){var yt=mt<0?-1:1;return yt*Dt}return mt===mt?mt:0}ge.exports=It},40554:function(ge,Xt,N){var et=N(18601);function ot(Dt){var It=et(Dt),mt=It%1;return It===It?mt?It-mt:It:0}ge.exports=ot},73807:function(ge){"use strict";var Xt=ge.exports;ge.exports.isNumber=function(N){return typeof N=="number"},ge.exports.findMin=function(N){if(N.length===0)return Infinity;for(var et=N[0],ot=1;ot<N.length;ot++)et=Math.min(et,N[ot]);return et},ge.exports.findMax=function(N){if(N.length===0)return-Infinity;for(var et=N[0],ot=1;ot<N.length;ot++)et=Math.max(et,N[ot]);return et},ge.exports.findMinMulti=function(N){for(var et=Xt.findMin(N[0]),ot=1;ot<N.length;ot++)et=Math.min(et,Xt.findMin(N[ot]));return et},ge.exports.findMaxMulti=function(N){for(var et=Xt.findMax(N[0]),ot=1;ot<N.length;ot++)et=Math.max(et,Xt.findMax(N[ot]));return et},ge.exports.inside=function(N,et,ot){return N<=ot&&ot<=et}},53843:function(ge,Xt,N){"use strict";var et=50,ot=2,Dt=Math.log(2),It=ge.exports,mt=N(73807);function yt(xt){return 1-Math.abs(xt)}ge.exports.getUnifiedMinMax=function(xt,it){return It.getUnifiedMinMaxMulti([xt],it)},ge.exports.getUnifiedMinMaxMulti=function(xt,it){it=it||{};var Ut=!1,Ft=!1,ft=mt.isNumber(it.width)?it.width:ot,q=mt.isNumber(it.size)?it.size:et,p=mt.isNumber(it.min)?it.min:(Ut=!0,mt.findMinMulti(xt)),f=mt.isNumber(it.max)?it.max:(Ft=!0,mt.findMaxMulti(xt)),J=f-p,K=J/(q-1);return Ut&&(p=p-2*ft*K),Ft&&(f=f+2*ft*K),{min:p,max:f}},ge.exports.create=function(xt,it){if(it=it||{},!xt||xt.length===0)return[];var Ut=mt.isNumber(it.size)?it.size:et,Ft=mt.isNumber(it.width)?it.width:ot,ft=It.getUnifiedMinMax(xt,{size:Ut,width:Ft,min:it.min,max:it.max}),q=ft.min,p=ft.max,f=p-q,J=f/(Ut-1);if(f===0)return[{x:q,y:1}];for(var K=[],ht=0;ht<Ut;ht++)K.push({x:q+ht*J,y:0});var Mt=function(pt){return Math.floor((pt-q)/J)},X=ut(yt,Ft),st=X[Ft],Et=X[Ft-1]-X[Ft-2],zt=0;xt.forEach(function(pt){var Pt=Mt(pt);if(!(Pt+Ft<0||Pt-Ft>=K.length)){var Rt=Math.max(Pt-Ft,0),Bt=Pt,Ct=Math.min(Pt+Ft,K.length-1),wt=Rt-(Pt-Ft),T=Pt+Ft-Ct,z=X[-Ft-1+wt]||0,bt=X[-Ft-1+T]||0,Y=st/(st-z-bt);wt>0&&(zt+=Y*(wt-1)*Et);var V=Math.max(0,Pt-Ft+1);mt.inside(0,K.length-1,V)&&(K[V].y+=Y*1*Et),mt.inside(0,K.length-1,Bt+1)&&(K[Bt+1].y-=Y*2*Et),mt.inside(0,K.length-1,Ct+1)&&(K[Ct+1].y+=Y*1*Et)}});var jt=zt,ee=0,ye=0;return K.forEach(function(pt){ee+=pt.y,jt+=ee,pt.y=jt,ye+=jt}),ye>0&&K.forEach(function(pt){pt.y/=ye}),K};function ut(xt,it){for(var Ut={},Ft=0,ft=-it;ft<=it;ft++)Ft+=xt(ft/it),Ut[ft]=Ft;return Ut}ge.exports.getExpectedValueFromPdf=function(xt){if(!(!xt||xt.length===0)){var it=0;return xt.forEach(function(Ut){it+=Ut.x*Ut.y}),it}},ge.exports.getXWithLeftTailArea=function(xt,it){if(!(!xt||xt.length===0)){for(var Ut=0,Ft=0,ft=0;ft<xt.length&&(Ft=ft,Ut+=xt[ft].y,!(Ut>=it));ft++);return xt[Ft].x}},ge.exports.getPerplexity=function(xt){if(!(!xt||xt.length===0)){var it=0;return xt.forEach(function(Ut){var Ft=Math.log(Ut.y);isFinite(Ft)&&(it+=Ut.y*Ft)}),it=-it/Dt,Math.pow(2,it)}}},55168:function(ge,Xt){"use strict";Object.defineProperty(Xt,"__esModule",{value:!0}),Xt.SizeSensorId=Xt.SensorTabIndex=Xt.SensorClassName=void 0;var N="size-sensor-id";Xt.SizeSensorId=N;var et="size-sensor-object";Xt.SensorClassName=et;var ot="-1";Xt.SensorTabIndex=ot},12177:function(ge,Xt){"use strict";Object.defineProperty(Xt,"__esModule",{value:!0}),Xt.default=void 0;var N=function(ot){var Dt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:60,It=null;return function(){for(var mt=this,yt=arguments.length,ut=new Array(yt),xt=0;xt<yt;xt++)ut[xt]=arguments[xt];clearTimeout(It),It=setTimeout(function(){ot.apply(mt,ut)},Dt)}};Xt.default=N},15378:function(ge,Xt){"use strict";Object.defineProperty(Xt,"__esModule",{value:!0}),Xt.default=void 0;var N=1,et=function(){return"".concat(N++)};Xt.default=et},18587:function(ge,Xt,N){"use strict";var et;et={value:!0},et=et=Xt.ak=void 0;var ot=N(12955),Dt=function(ut,xt){var it=(0,ot.getSensor)(ut);return it.bind(xt),function(){it.unbind(xt)}};Xt.ak=Dt;var It=function(ut){var xt=(0,ot.getSensor)(ut);(0,ot.removeSensor)(xt)};et=It;var mt="1.0.2";et=mt},12955:function(ge,Xt,N){"use strict";Object.defineProperty(Xt,"__esModule",{value:!0}),Xt.removeSensor=Xt.getSensor=Xt.Sensors=void 0;var et=It(N(15378)),ot=N(82578),Dt=N(55168);function It(it){return it&&it.__esModule?it:{default:it}}var mt={};Xt.Sensors=mt;function yt(it){it&&mt[it]&&delete mt[it]}var ut=function(Ut){var Ft=Ut.getAttribute(Dt.SizeSensorId);if(Ft&&mt[Ft])return mt[Ft];var ft=(0,et.default)();Ut.setAttribute(Dt.SizeSensorId,ft);var q=(0,ot.createSensor)(Ut,function(){return yt(ft)});return mt[ft]=q,q};Xt.getSensor=ut;var xt=function(Ut){var Ft=Ut.element.getAttribute(Dt.SizeSensorId);Ut.destroy(),yt(Ft)};Xt.removeSensor=xt},82578:function(ge,Xt,N){"use strict";Object.defineProperty(Xt,"__esModule",{value:!0}),Xt.createSensor=void 0;var et=N(27643),ot=N(31743),Dt=typeof ResizeObserver!="undefined"?ot.createSensor:et.createSensor;Xt.createSensor=Dt},27643:function(ge,Xt,N){"use strict";Object.defineProperty(Xt,"__esModule",{value:!0}),Xt.createSensor=void 0;var et=Dt(N(12177)),ot=N(55168);function Dt(mt){return mt&&mt.__esModule?mt:{default:mt}}var It=function(yt,ut){var xt=void 0,it=[],Ut=function(){getComputedStyle(yt).position==="static"&&(yt.style.position="relative");var J=document.createElement("object");return J.onload=function(){J.contentDocument.defaultView.addEventListener("resize",Ft),Ft()},J.style.display="block",J.style.position="absolute",J.style.top="0",J.style.left="0",J.style.height="100%",J.style.width="100%",J.style.overflow="hidden",J.style.pointerEvents="none",J.style.zIndex="-1",J.style.opacity="0",J.setAttribute("class",ot.SensorClassName),J.setAttribute("tabindex",ot.SensorTabIndex),J.type="text/html",yt.appendChild(J),J.data="about:blank",J},Ft=(0,et.default)(function(){it.forEach(function(f){f(yt)})}),ft=function(J){xt||(xt=Ut()),it.indexOf(J)===-1&&it.push(J)},q=function(){xt&&xt.parentNode&&(xt.contentDocument&&xt.contentDocument.defaultView.removeEventListener("resize",Ft),xt.parentNode.removeChild(xt),yt.removeAttribute(ot.SizeSensorId),xt=void 0,it=[],ut&&ut())},p=function(J){var K=it.indexOf(J);K!==-1&&it.splice(K,1),it.length===0&&xt&&q()};return{element:yt,bind:ft,destroy:q,unbind:p}};Xt.createSensor=It},31743:function(ge,Xt,N){"use strict";Object.defineProperty(Xt,"__esModule",{value:!0}),Xt.createSensor=void 0;var et=N(55168),ot=Dt(N(12177));function Dt(mt){return mt&&mt.__esModule?mt:{default:mt}}var It=function(yt,ut){var xt=void 0,it=[],Ut=(0,ot.default)(function(){it.forEach(function(f){f(yt)})}),Ft=function(){var J=new ResizeObserver(Ut);return J.observe(yt),Ut(),J},ft=function(J){xt||(xt=Ft()),it.indexOf(J)===-1&&it.push(J)},q=function(){xt.disconnect(),it=[],xt=void 0,yt.removeAttribute(et.SizeSensorId),ut&&ut()},p=function(J){var K=it.indexOf(J);K!==-1&&it.splice(K,1),it.length===0&&xt&&q()};return{element:yt,bind:ft,destroy:q,unbind:p}};Xt.createSensor=It},65353:function(ge,Xt,N){"use strict";N.d(Xt,{ZT:function(){return ot},pi:function(){return Dt},_T:function(){return It},mG:function(){return ft},Jh:function(){return q},XA:function(){return J},CR:function(){return K},pr:function(){return Mt},ev:function(){return X}});var et=function(Y,V){return et=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,A){G.__proto__=A}||function(G,A){for(var I in A)Object.prototype.hasOwnProperty.call(A,I)&&(G[I]=A[I])},et(Y,V)};function ot(Y,V){if(typeof V!="function"&&V!==null)throw new TypeError("Class extends value "+String(V)+" is not a constructor or null");et(Y,V);function G(){this.constructor=Y}Y.prototype=V===null?Object.create(V):(G.prototype=V.prototype,new G)}var Dt=function(){return Dt=Object.assign||function(V){for(var G,A=1,I=arguments.length;A<I;A++){G=arguments[A];for(var D in G)Object.prototype.hasOwnProperty.call(G,D)&&(V[D]=G[D])}return V},Dt.apply(this,arguments)};function It(Y,V){var G={};for(var A in Y)Object.prototype.hasOwnProperty.call(Y,A)&&V.indexOf(A)<0&&(G[A]=Y[A]);if(Y!=null&&typeof Object.getOwnPropertySymbols=="function")for(var I=0,A=Object.getOwnPropertySymbols(Y);I<A.length;I++)V.indexOf(A[I])<0&&Object.prototype.propertyIsEnumerable.call(Y,A[I])&&(G[A[I]]=Y[A[I]]);return G}function mt(Y,V,G,A){var I=arguments.length,D=I<3?V:A===null?A=Object.getOwnPropertyDescriptor(V,G):A,E;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")D=Reflect.decorate(Y,V,G,A);else for(var Q=Y.length-1;Q>=0;Q--)(E=Y[Q])&&(D=(I<3?E(D):I>3?E(V,G,D):E(V,G))||D);return I>3&&D&&Object.defineProperty(V,G,D),D}function yt(Y,V){return function(G,A){V(G,A,Y)}}function ut(Y,V,G,A,I,D){function E(nt){if(nt!==void 0&&typeof nt!="function")throw new TypeError("Function expected");return nt}for(var Q=A.kind,lt=Q==="getter"?"get":Q==="setter"?"set":"value",P=!V&&Y?A.static?Y:Y.prototype:null,F=V||(P?Object.getOwnPropertyDescriptor(P,A.name):{}),C,_=!1,L=G.length-1;L>=0;L--){var U={};for(var B in A)U[B]=B==="access"?{}:A[B];for(var B in A.access)U.access[B]=A.access[B];U.addInitializer=function(nt){if(_)throw new TypeError("Cannot add initializers after decoration has completed");D.push(E(nt||null))};var j=(0,G[L])(Q==="accessor"?{get:F.get,set:F.set}:F[lt],U);if(Q==="accessor"){if(j===void 0)continue;if(j===null||typeof j!="object")throw new TypeError("Object expected");(C=E(j.get))&&(F.get=C),(C=E(j.set))&&(F.set=C),(C=E(j.init))&&I.unshift(C)}else(C=E(j))&&(Q==="field"?I.unshift(C):F[lt]=C)}P&&Object.defineProperty(P,A.name,F),_=!0}function xt(Y,V,G){for(var A=arguments.length>2,I=0;I<V.length;I++)G=A?V[I].call(Y,G):V[I].call(Y);return A?G:void 0}function it(Y){return typeof Y=="symbol"?Y:"".concat(Y)}function Ut(Y,V,G){return typeof V=="symbol"&&(V=V.description?"[".concat(V.description,"]"):""),Object.defineProperty(Y,"name",{configurable:!0,value:G?"".concat(G," ",V):V})}function Ft(Y,V){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(Y,V)}function ft(Y,V,G,A){function I(D){return D instanceof G?D:new G(function(E){E(D)})}return new(G||(G=Promise))(function(D,E){function Q(F){try{P(A.next(F))}catch(C){E(C)}}function lt(F){try{P(A.throw(F))}catch(C){E(C)}}function P(F){F.done?D(F.value):I(F.value).then(Q,lt)}P((A=A.apply(Y,V||[])).next())})}function q(Y,V){var G={label:0,sent:function(){if(D[0]&1)throw D[1];return D[1]},trys:[],ops:[]},A,I,D,E;return E={next:Q(0),throw:Q(1),return:Q(2)},typeof Symbol=="function"&&(E[Symbol.iterator]=function(){return this}),E;function Q(P){return function(F){return lt([P,F])}}function lt(P){if(A)throw new TypeError("Generator is already executing.");for(;E&&(E=0,P[0]&&(G=0)),G;)try{if(A=1,I&&(D=P[0]&2?I.return:P[0]?I.throw||((D=I.return)&&D.call(I),0):I.next)&&!(D=D.call(I,P[1])).done)return D;switch(I=0,D&&(P=[P[0]&2,D.value]),P[0]){case 0:case 1:D=P;break;case 4:return G.label++,{value:P[1],done:!1};case 5:G.label++,I=P[1],P=[0];continue;case 7:P=G.ops.pop(),G.trys.pop();continue;default:if(D=G.trys,!(D=D.length>0&&D[D.length-1])&&(P[0]===6||P[0]===2)){G=0;continue}if(P[0]===3&&(!D||P[1]>D[0]&&P[1]<D[3])){G.label=P[1];break}if(P[0]===6&&G.label<D[1]){G.label=D[1],D=P;break}if(D&&G.label<D[2]){G.label=D[2],G.ops.push(P);break}D[2]&&G.ops.pop(),G.trys.pop();continue}P=V.call(Y,G)}catch(F){P=[6,F],I=0}finally{A=D=0}if(P[0]&5)throw P[1];return{value:P[0]?P[1]:void 0,done:!0}}}var p=Object.create?function(Y,V,G,A){A===void 0&&(A=G);var I=Object.getOwnPropertyDescriptor(V,G);(!I||("get"in I?!V.__esModule:I.writable||I.configurable))&&(I={enumerable:!0,get:function(){return V[G]}}),Object.defineProperty(Y,A,I)}:function(Y,V,G,A){A===void 0&&(A=G),Y[A]=V[G]};function f(Y,V){for(var G in Y)G!=="default"&&!Object.prototype.hasOwnProperty.call(V,G)&&p(V,Y,G)}function J(Y){var V=typeof Symbol=="function"&&Symbol.iterator,G=V&&Y[V],A=0;if(G)return G.call(Y);if(Y&&typeof Y.length=="number")return{next:function(){return Y&&A>=Y.length&&(Y=void 0),{value:Y&&Y[A++],done:!Y}}};throw new TypeError(V?"Object is not iterable.":"Symbol.iterator is not defined.")}function K(Y,V){var G=typeof Symbol=="function"&&Y[Symbol.iterator];if(!G)return Y;var A=G.call(Y),I,D=[],E;try{for(;(V===void 0||V-- >0)&&!(I=A.next()).done;)D.push(I.value)}catch(Q){E={error:Q}}finally{try{I&&!I.done&&(G=A.return)&&G.call(A)}finally{if(E)throw E.error}}return D}function ht(){for(var Y=[],V=0;V<arguments.length;V++)Y=Y.concat(K(arguments[V]));return Y}function Mt(){for(var Y=0,V=0,G=arguments.length;V<G;V++)Y+=arguments[V].length;for(var A=Array(Y),I=0,V=0;V<G;V++)for(var D=arguments[V],E=0,Q=D.length;E<Q;E++,I++)A[I]=D[E];return A}function X(Y,V,G){if(G||arguments.length===2)for(var A=0,I=V.length,D;A<I;A++)(D||!(A in V))&&(D||(D=Array.prototype.slice.call(V,0,A)),D[A]=V[A]);return Y.concat(D||Array.prototype.slice.call(V))}function st(Y){return this instanceof st?(this.v=Y,this):new st(Y)}function Et(Y,V,G){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var A=G.apply(Y,V||[]),I,D=[];return I={},E("next"),E("throw"),E("return"),I[Symbol.asyncIterator]=function(){return this},I;function E(_){A[_]&&(I[_]=function(L){return new Promise(function(U,B){D.push([_,L,U,B])>1||Q(_,L)})})}function Q(_,L){try{lt(A[_](L))}catch(U){C(D[0][3],U)}}function lt(_){_.value instanceof st?Promise.resolve(_.value.v).then(P,F):C(D[0][2],_)}function P(_){Q("next",_)}function F(_){Q("throw",_)}function C(_,L){_(L),D.shift(),D.length&&Q(D[0][0],D[0][1])}}function zt(Y){var V,G;return V={},A("next"),A("throw",function(I){throw I}),A("return"),V[Symbol.iterator]=function(){return this},V;function A(I,D){V[I]=Y[I]?function(E){return(G=!G)?{value:st(Y[I](E)),done:!1}:D?D(E):E}:D}}function jt(Y){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var V=Y[Symbol.asyncIterator],G;return V?V.call(Y):(Y=typeof J=="function"?J(Y):Y[Symbol.iterator](),G={},A("next"),A("throw"),A("return"),G[Symbol.asyncIterator]=function(){return this},G);function A(D){G[D]=Y[D]&&function(E){return new Promise(function(Q,lt){E=Y[D](E),I(Q,lt,E.done,E.value)})}}function I(D,E,Q,lt){Promise.resolve(lt).then(function(P){D({value:P,done:Q})},E)}}function ee(Y,V){return Object.defineProperty?Object.defineProperty(Y,"raw",{value:V}):Y.raw=V,Y}var ye=Object.create?function(Y,V){Object.defineProperty(Y,"default",{enumerable:!0,value:V})}:function(Y,V){Y.default=V};function pt(Y){if(Y&&Y.__esModule)return Y;var V={};if(Y!=null)for(var G in Y)G!=="default"&&Object.prototype.hasOwnProperty.call(Y,G)&&p(V,Y,G);return ye(V,Y),V}function Pt(Y){return Y&&Y.__esModule?Y:{default:Y}}function Rt(Y,V,G,A){if(G==="a"&&!A)throw new TypeError("Private accessor was defined without a getter");if(typeof V=="function"?Y!==V||!A:!V.has(Y))throw new TypeError("Cannot read private member from an object whose class did not declare it");return G==="m"?A:G==="a"?A.call(Y):A?A.value:V.get(Y)}function Bt(Y,V,G,A,I){if(A==="m")throw new TypeError("Private method is not writable");if(A==="a"&&!I)throw new TypeError("Private accessor was defined without a setter");if(typeof V=="function"?Y!==V||!I:!V.has(Y))throw new TypeError("Cannot write private member to an object whose class did not declare it");return A==="a"?I.call(Y,G):I?I.value=G:V.set(Y,G),G}function Ct(Y,V){if(V===null||typeof V!="object"&&typeof V!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof Y=="function"?V===Y:Y.has(V)}function wt(Y,V,G){if(V!=null){if(typeof V!="object"&&typeof V!="function")throw new TypeError("Object expected.");var A;if(G){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");A=V[Symbol.asyncDispose]}if(A===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");A=V[Symbol.dispose]}if(typeof A!="function")throw new TypeError("Object not disposable.");Y.stack.push({value:V,dispose:A,async:G})}else G&&Y.stack.push({async:!0});return V}var T=typeof SuppressedError=="function"?SuppressedError:function(Y,V,G){var A=new Error(G);return A.name="SuppressedError",A.error=Y,A.suppressed=V,A};function z(Y){function V(A){Y.error=Y.hasError?new T(A,Y.error,"An error was suppressed during disposal."):A,Y.hasError=!0}function G(){for(;Y.stack.length;){var A=Y.stack.pop();try{var I=A.dispose&&A.dispose.call(A.value);if(A.async)return Promise.resolve(I).then(G,function(D){return V(D),G()})}catch(D){V(D)}}if(Y.hasError)throw Y.error}return G()}var bt={__extends:ot,__assign:Dt,__rest:It,__decorate:mt,__param:yt,__metadata:Ft,__awaiter:ft,__generator:q,__createBinding:p,__exportStar:f,__values:J,__read:K,__spread:ht,__spreadArrays:Mt,__spreadArray:X,__await:st,__asyncGenerator:Et,__asyncDelegator:zt,__asyncValues:jt,__makeTemplateObject:ee,__importStar:pt,__importDefault:Pt,__classPrivateFieldGet:Rt,__classPrivateFieldSet:Bt,__classPrivateFieldIn:Ct,__addDisposableResource:wt,__disposeResources:z}}}]);