import{i as O,r as Wr,m as H,a as E,c as V,e as S,b as _e,d as Ye,f as Z,g as B,h as ue,j as Jn,k as pu,l as R,n as W,o as ln,p as at,P as We,q as na,s as G,t as gu,Z as un,u as mu,v as yu,w as _u,x as Su,y as qo,z as ei,T as wu,A as Tu,B as ar,C as pe,D as Pt,E as xu,F as Ci,G as jo,S as fn,R as Qo,H as Jo,I as cn,J as Ue,L as yr,K as es,M as Di,N as pt,O as Ee,Q as Cu,U as Du,V as bu,W as Mu,X as or,Y as $r,_ as ne,$ as _r,a0 as he,a1 as z,a2 as gt,a3 as me,a4 as Au,a5 as we,a6 as Te,a7 as ze,a8 as Y,a9 as ti,aa as Iu,ab as it,ac as Pu,ad as Lu,ae as Ru,af as ts,ag as Eu,ah as hn,ai as ia,aj as xn,ak as ku,al as Ou,am as aa,an as Cn,ao as Nu,ap as Bu,aq as Vu,ar as sr,as as rs,at as Fu,au as zu,av as Hu,aw as Uu,ax as Gu,ay as oa,az as Yu,aA as Wu}from"./zrender.6f9469d4.js";import{_ as fe}from"./tslib.891692d0.js";var sa=1e-4,ns=20;function $u(t){return t.replace(/^\s+|\s+$/g,"")}function Xu(t,e,r,n){var i=e[0],a=e[1],o=r[0],s=r[1],l=a-i,f=s-o;if(l===0)return f===0?o:(o+s)/2;if(n)if(l>0){if(t<=i)return o;if(t>=a)return s}else{if(t>=i)return o;if(t<=a)return s}else{if(t===i)return o;if(t===a)return s}return(t-i)/l*f+o}function te(t,e){switch(t){case"center":case"middle":t="50%";break;case"left":case"top":t="0%";break;case"right":case"bottom":t="100%";break}return O(t)?$u(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):t==null?NaN:+t}function Ku(t,e,r){return e==null&&(e=10),e=Math.min(Math.max(0,e),ns),t=(+t).toFixed(e),r?t:+t}function la(t){if(t=+t,isNaN(t))return 0;if(t>1e-14){for(var e=1,r=0;r<15;r++,e*=10)if(Math.round(t*e)/e===t)return r}return Zu(t)}function Zu(t){var e=t.toString().toLowerCase(),r=e.indexOf("e"),n=r>0?+e.slice(r+1):0,i=r>0?r:e.length,a=e.indexOf("."),o=a<0?0:i-1-a;return Math.max(0,o-n)}function qu(t,e){var r=Wr(t,function(h,d){return h+(isNaN(d)?0:d)},0);if(r===0)return[];for(var n=Math.pow(10,e),i=H(t,function(h){return(isNaN(h)?0:h)/r*n*100}),a=n*100,o=H(i,function(h){return Math.floor(h)}),s=Wr(o,function(h,d){return h+d},0),l=H(i,function(h,d){return h-o[d]});sf&&(f=l[u],c=u);++o[c],l[c]=0,++s}return H(o,function(h){return h/n})}function ju(t,e){var r=Math.max(la(t),la(e)),n=t+e;return r>ns?n:Ku(n,r)}function is(t){var e=Math.PI*2;return(t%e+e)%e}function Xr(t){return t>-sa&&t=0||a&&_e(a,l)<0)){var f=n.getShallow(l,e);f!=null&&(o[t[s][0]]=f)}}return o}}var xf=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],Cf=ur(xf),Df=function(){function t(){}return t.prototype.getAreaStyle=function(e,r){return Cf(this,e,r)},t}(),Q=re(),bf=function(t,e,r,n){if(n){var i=Q(n);i.dataIndex=r,i.dataType=e,i.seriesIndex=t,i.ssrType="chart",n.type==="group"&&n.traverse(function(a){var o=Q(a);o.seriesIndex=t,o.dataIndex=r,o.dataType=e,o.ssrType="chart"})}},ca=1,ha={},vs=re(),Pi=re(),ds=0,Li=1,Ri=2,ke=["emphasis","blur","select"],Zr=["normal","emphasis","blur","select"],Mf=10,Af=9,vt="highlight",Br="downplay",Jt="select",Vr="unselect",er="toggleSelect";function Tt(t){return t!=null&&t!=="none"}function pn(t,e,r){t.onHoverStateChange&&(t.hoverState||0)!==r&&t.onHoverStateChange(e),t.hoverState=r}function ps(t){pn(t,"emphasis",Ri)}function gs(t){t.hoverState===Ri&&pn(t,"normal",ds)}function Ei(t){pn(t,"blur",Li)}function ms(t){t.hoverState===Li&&pn(t,"normal",ds)}function If(t){t.selected=!0}function Pf(t){t.selected=!1}function va(t,e,r){e(t,r)}function $e(t,e,r){va(t,e,r),t.isGroup&&t.traverse(function(n){va(n,e,r)})}function Lf(t,e,r,n){for(var i=t.style,a={},o=0;o=0,a=!1;if(t instanceof We){var o=vs(t),s=i&&o.selectFill||o.normalFill,l=i&&o.selectStroke||o.normalStroke;if(Tt(s)||Tt(l)){n=n||{};var f=n.style||{};f.fill==="inherit"?(a=!0,n=R({},n),f=R({},f),f.fill=s):!Tt(f.fill)&&Tt(s)?(a=!0,n=R({},n),f=R({},f),f.fill=na(s)):!Tt(f.stroke)&&Tt(l)&&(a||(n=R({},n),f=R({},f)),f.stroke=na(l)),n.style=f}}if(n&&n.z2==null){a||(n=R({},n));var c=t.z2EmphasisLift;n.z2=t.z2+(c!=null?c:Mf)}return n}function Ef(t,e,r){if(r&&r.z2==null){r=R({},r);var n=t.z2SelectLift;r.z2=t.z2+(n!=null?n:Af)}return r}function kf(t,e,r){var n=_e(t.currentStates,e)>=0,i=t.style.opacity,a=n?null:Lf(t,["opacity"],e,{opacity:1});r=r||{};var o=r.style||{};return o.opacity==null&&(r=R({},r),o=R({opacity:n?i:a.opacity*.1},o),r.style=o),r}function bn(t,e){var r=this.states[t];if(this.style){if(t==="emphasis")return Rf(this,t,e,r);if(t==="blur")return kf(this,t,r);if(t==="select")return Ef(this,t,r)}return r}function Of(t){t.stateProxy=bn;var e=t.getTextContent(),r=t.getTextGuideLine();e&&(e.stateProxy=bn),r&&(r.stateProxy=bn)}function da(t,e){!ws(t,e)&&!t.__highByOuter&&$e(t,ps)}function pa(t,e){!ws(t,e)&&!t.__highByOuter&&$e(t,gs)}function ni(t,e){t.__highByOuter|=1<<(e||0),$e(t,ps)}function ii(t,e){!(t.__highByOuter&=~(1<<(e||0)))&&$e(t,gs)}function Nf(t){$e(t,Ei)}function ys(t){$e(t,ms)}function _s(t){$e(t,If)}function Ss(t){$e(t,Pf)}function ws(t,e){return t.__highDownSilentOnTouch&&e.zrByTouch}function Ts(t){var e=t.getModel(),r=[],n=[];e.eachComponent(function(i,a){var o=Pi(a),s=i==="series",l=s?t.getViewOfSeriesModel(a):t.getViewOfComponentModel(a);!s&&n.push(l),o.isBlured&&(l.group.traverse(function(f){ms(f)}),s&&r.push(a)),o.isBlured=!1}),S(n,function(i){i&&i.toggleBlurSeries&&i.toggleBlurSeries(r,!1,e)})}function ai(t,e,r,n){var i=n.getModel();r=r||"coordinateSystem";function a(f,c){for(var u=0;u0){var s={dataIndex:o,seriesIndex:r.seriesIndex};a!=null&&(s.dataType=a),e.push(s)}})}),e}function Uf(t,e,r){xs(t,!0),$e(t,Of),Wf(t,e,r)}function Gf(t){xs(t,!1)}function Yf(t,e,r,n){n?Gf(t):Uf(t,e,r)}function Wf(t,e,r){var n=Q(t);e!=null?(n.focus=e,n.blurScope=r):n.focus&&(n.focus=null)}var ma=["emphasis","blur","select"],$f={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function Xf(t,e,r,n){r=r||"itemStyle";for(var i=0;i0){var u=c.duration,v=c.delay,h=c.easing,d={duration:u,delay:v||0,easing:h,done:a,force:!!a||!!o,setToFinal:!f,scope:t,during:o};s?e.animateFrom(r,d):e.animateTo(r,d)}else e.stopAnimation(),!s&&e.attr(r),o&&o(1),a&&a()}function fr(t,e,r,n,i,a){Oi("update",t,e,r,n,i,a)}function Fr(t,e,r,n,i,a){Oi("enter",t,e,r,n,i,a)}function tr(t){if(!t.__zr)return!0;for(var e=0;eMath.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function Sa(t){return!t.isGroup}function lc(t){return t.shape!=null}function uc(t,e,r){if(!t||!e)return;function n(o){var s={};return o.traverse(function(l){Sa(l)&&l.anid&&(s[l.anid]=l)}),s}function i(o){var s={x:o.x,y:o.y,rotation:o.rotation};return lc(o)&&(s.shape=R({},o.shape)),s}var a=n(t);e.traverse(function(o){if(Sa(o)&&o.anid){var s=a[o.anid];if(s){var l=i(o);o.attr(i(s)),fr(o,l,r,Q(o).dataIndex)}}})}function fc(t,e){return H(t,function(r){var n=r[0];n=qr(n,e.x),n=jr(n,e.x+e.width);var i=r[1];return i=qr(i,e.y),i=jr(i,e.y+e.height),[n,i]})}function cc(t,e){var r=qr(t.x,e.x),n=jr(t.x+t.width,e.x+e.width),i=qr(t.y,e.y),a=jr(t.y+t.height,e.y+e.height);if(n>=r&&a>=i)return{x:r,y:i,width:n-r,height:a-i}}function Is(t,e,r){var n=R({rectHover:!0},e),i=n.style={strokeNoScale:!0};if(r=r||{x:-1,y:-1,width:2,height:2},t)return t.indexOf("image://")===0?(i.image=t.slice(8),pe(i,r),new un(n)):Ni(t.replace("path://",""),n,r,"center")}function hc(t,e,r,n,i){for(var a=0,o=i[i.length-1];a1)return!1;var g=Mn(h,d,c,u)/v;return!(g<0||g>1)}function Mn(t,e,r,n){return t*n-r*e}function vc(t){return t<=1e-6&&t>=-1e-6}function Fi(t){var e=t.itemTooltipOption,r=t.componentModel,n=t.itemName,i=O(e)?{formatter:e}:e,a=r.mainType,o=r.componentIndex,s={componentType:a,name:n,$vars:["name"]};s[a+"Index"]=o;var l=t.formatterParamsExtra;l&&S(at(l),function(c){Pt(s,c)||(s[c]=l[c],s.$vars.push(c))});var f=Q(t.el);f.componentMainType=a,f.componentIndex=o,f.tooltipConfig={name:n,option:pe({content:n,encodeHTMLContent:!0,formatterParams:s},i)}}function wa(t,e){var r;t.isGroup&&(r=e(t)),r||t.traverse(e)}function Ls(t,e){if(t)if(E(t))for(var r=0;r=0&&s.push(l)}),s}}var Rc={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}},Ec={time:{month:["\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00\u6708","\u5341\u4E8C\u6708"],monthAbbr:["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],dayOfWeek:["\u661F\u671F\u65E5","\u661F\u671F\u4E00","\u661F\u671F\u4E8C","\u661F\u671F\u4E09","\u661F\u671F\u56DB","\u661F\u671F\u4E94","\u661F\u671F\u516D"],dayOfWeekAbbr:["\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D"]},legend:{selector:{all:"\u5168\u9009",inverse:"\u53CD\u9009"}},toolbox:{brush:{title:{rect:"\u77E9\u5F62\u9009\u62E9",polygon:"\u5708\u9009",lineX:"\u6A2A\u5411\u9009\u62E9",lineY:"\u7EB5\u5411\u9009\u62E9",keep:"\u4FDD\u6301\u9009\u62E9",clear:"\u6E05\u9664\u9009\u62E9"}},dataView:{title:"\u6570\u636E\u89C6\u56FE",lang:["\u6570\u636E\u89C6\u56FE","\u5173\u95ED","\u5237\u65B0"]},dataZoom:{title:{zoom:"\u533A\u57DF\u7F29\u653E",back:"\u533A\u57DF\u7F29\u653E\u8FD8\u539F"}},magicType:{title:{line:"\u5207\u6362\u4E3A\u6298\u7EBF\u56FE",bar:"\u5207\u6362\u4E3A\u67F1\u72B6\u56FE",stack:"\u5207\u6362\u4E3A\u5806\u53E0",tiled:"\u5207\u6362\u4E3A\u5E73\u94FA"}},restore:{title:"\u8FD8\u539F"},saveAsImage:{title:"\u4FDD\u5B58\u4E3A\u56FE\u7247",lang:["\u53F3\u952E\u53E6\u5B58\u4E3A\u56FE\u7247"]}},series:{typeNames:{pie:"\u997C\u56FE",bar:"\u67F1\u72B6\u56FE",line:"\u6298\u7EBF\u56FE",scatter:"\u6563\u70B9\u56FE",effectScatter:"\u6D9F\u6F2A\u6563\u70B9\u56FE",radar:"\u96F7\u8FBE\u56FE",tree:"\u6811\u56FE",treemap:"\u77E9\u5F62\u6811\u56FE",boxplot:"\u7BB1\u578B\u56FE",candlestick:"K\u7EBF\u56FE",k:"K\u7EBF\u56FE",heatmap:"\u70ED\u529B\u56FE",map:"\u5730\u56FE",parallel:"\u5E73\u884C\u5750\u6807\u56FE",lines:"\u7EBF\u56FE",graph:"\u5173\u7CFB\u56FE",sankey:"\u6851\u57FA\u56FE",funnel:"\u6F0F\u6597\u56FE",gauge:"\u4EEA\u8868\u76D8\u56FE",pictorialBar:"\u8C61\u5F62\u67F1\u56FE",themeRiver:"\u4E3B\u9898\u6CB3\u6D41\u56FE",sunburst:"\u65ED\u65E5\u56FE",custom:"\u81EA\u5B9A\u4E49\u56FE\u8868",chart:"\u56FE\u8868"}},aria:{general:{withTitle:"\u8FD9\u662F\u4E00\u4E2A\u5173\u4E8E\u201C{title}\u201D\u7684\u56FE\u8868\u3002",withoutTitle:"\u8FD9\u662F\u4E00\u4E2A\u56FE\u8868\uFF0C"},series:{single:{prefix:"",withName:"\u56FE\u8868\u7C7B\u578B\u662F{seriesType}\uFF0C\u8868\u793A{seriesName}\u3002",withoutName:"\u56FE\u8868\u7C7B\u578B\u662F{seriesType}\u3002"},multiple:{prefix:"\u5B83\u7531{seriesCount}\u4E2A\u56FE\u8868\u7CFB\u5217\u7EC4\u6210\u3002",withName:"\u7B2C{seriesId}\u4E2A\u7CFB\u5217\u662F\u4E00\u4E2A\u8868\u793A{seriesName}\u7684{seriesType}\uFF0C",withoutName:"\u7B2C{seriesId}\u4E2A\u7CFB\u5217\u662F\u4E00\u4E2A{seriesType}\uFF0C",separator:{middle:"\uFF1B",end:"\u3002"}}},data:{allData:"\u5176\u6570\u636E\u662F\u2014\u2014",partialData:"\u5176\u4E2D\uFF0C\u524D{displayCnt}\u9879\u662F\u2014\u2014",withName:"{name}\u7684\u6570\u636E\u662F{value}",withoutName:"{value}",separator:{middle:"\uFF0C",end:""}}}},Qr="ZH",zi="EN",At=zi,zr={},Hi={},ks=Z.domSupported?function(){var t=(document.documentElement.lang||navigator.language||navigator.browserLanguage||At).toUpperCase();return t.indexOf(Qr)>-1?Qr:At}():At;function Os(t,e){t=t.toUpperCase(),Hi[t]=new ve(e),zr[t]=e}function kc(t){if(O(t)){var e=zr[t.toUpperCase()]||{};return t===Qr||t===zi?z(e):he(z(e),z(zr[At]),!1)}else return he(z(t),z(zr[At]),!1)}function Oc(t){return Hi[t]}function Nc(){return Hi[At]}Os(zi,Rc);Os(Qr,Ec);function Ze(t,e){return t+="","0000".substr(0,e-t.length)+t}function Ns(t,e,r,n){var i=vn(t),a=i[Bc(r)](),o=i[Vc(r)]()+1,s=Math.floor((o-1)/3)+1,l=i[Fc(r)](),f=i["get"+(r?"UTC":"")+"Day"](),c=i[zc(r)](),u=(c-1)%12+1,v=i[Hc(r)](),h=i[Uc(r)](),d=i[Gc(r)](),p=c>=12?"pm":"am",g=p.toUpperCase(),m=n instanceof ve?n:Oc(n||ks)||Nc(),y=m.getModel("time"),_=y.get("month"),w=y.get("monthAbbr"),x=y.get("dayOfWeek"),T=y.get("dayOfWeekAbbr");return(e||"").replace(/{a}/g,p+"").replace(/{A}/g,g+"").replace(/{yyyy}/g,a+"").replace(/{yy}/g,Ze(a%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,_[o-1]).replace(/{MMM}/g,w[o-1]).replace(/{MM}/g,Ze(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,Ze(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,x[f]).replace(/{ee}/g,T[f]).replace(/{e}/g,f+"").replace(/{HH}/g,Ze(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,Ze(u+"",2)).replace(/{h}/g,u+"").replace(/{mm}/g,Ze(v,2)).replace(/{m}/g,v+"").replace(/{ss}/g,Ze(h,2)).replace(/{s}/g,h+"").replace(/{SSS}/g,Ze(d,3)).replace(/{S}/g,d+"")}function Bc(t){return t?"getUTCFullYear":"getFullYear"}function Vc(t){return t?"getUTCMonth":"getMonth"}function Fc(t){return t?"getUTCDate":"getDate"}function zc(t){return t?"getUTCHours":"getHours"}function Hc(t){return t?"getUTCMinutes":"getMinutes"}function Uc(t){return t?"getUTCSeconds":"getSeconds"}function Gc(t){return t?"getUTCMilliseconds":"getMilliseconds"}function Yc(t){if(!Ju(t))return O(t)?t:"-";var e=(t+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function Bs(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,function(r,n){return n.toUpperCase()}),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}var Ui=Au;function fi(t,e,r){var n="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function i(c){return c&&_r(c)?c:"-"}function a(c){return!!(c!=null&&!isNaN(c)&&isFinite(c))}var o=e==="time",s=t instanceof Date;if(o||s){var l=o?vn(t):t;if(isNaN(+l)){if(s)return"-"}else return Ns(l,n,r)}if(e==="ordinal")return Jn(t)?i(t):ue(t)&&a(t)?t+"":"-";var f=Kr(t);return a(f)?Yc(f):Jn(t)?i(t):typeof t=="boolean"?t+"":"-"}var Aa=["a","b","c","d","e","f","g"],Pn=function(t,e){return"{"+t+(e==null?"":e)+"}"};function Vs(t,e,r){E(e)||(e=[e]);var n=e.length;if(!n)return"";for(var i=e[0].$vars||[],a=0;a':'';var o=r.markerId||"markerX";return{renderMode:a,content:"{"+o+"|} ",style:i==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:n}:{width:10,height:10,borderRadius:5,backgroundColor:n}}}function hr(t,e){return e=e||"transparent",O(t)?t:B(t)&&t.colorStops&&(t.colorStops[0]||{}).color||e}var Hr=S,$c=["left","right","top","bottom","width","height"],br=[["width","left","right"],["height","top","bottom"]];function Fs(t,e,r,n,i){var a=0,o=0;n==null&&(n=1/0),i==null&&(i=1/0);var s=0;e.eachChild(function(l,f){var c=l.getBoundingRect(),u=e.childAt(f+1),v=u&&u.getBoundingRect(),h,d;if(t==="horizontal"){var p=c.width+(v?-v.x+c.x:0);h=a+p,h>n||l.newline?(a=0,h=p,o+=s+r,s=c.height):s=Math.max(s,c.height)}else{var g=c.height+(v?-v.y+c.y:0);d=o+g,d>i||l.newline?(a+=s+r,o=0,d=g,s=c.width):s=Math.max(s,c.width)}l.newline||(l.x=a,l.y=o,l.markRedraw(),t==="horizontal"?a=h+r:o=d+r)})}we(Fs,"vertical");we(Fs,"horizontal");function zs(t,e,r){r=Ui(r||0);var n=e.width,i=e.height,a=te(t.left,n),o=te(t.top,i),s=te(t.right,n),l=te(t.bottom,i),f=te(t.width,n),c=te(t.height,i),u=r[2]+r[0],v=r[1]+r[3],h=t.aspect;switch(isNaN(f)&&(f=n-s-v-a),isNaN(c)&&(c=i-l-u-o),h!=null&&(isNaN(f)&&isNaN(c)&&(h>n/i?f=n*.8:c=i*.8),isNaN(f)&&(f=h*c),isNaN(c)&&(c=f/h)),isNaN(a)&&(a=n-s-f-v),isNaN(o)&&(o=i-l-c-u),t.left||t.right){case"center":a=n/2-f/2-r[3];break;case"right":a=n-f-v;break}switch(t.top||t.bottom){case"middle":case"center":o=i/2-c/2-r[0];break;case"bottom":o=i-c-u;break}a=a||0,o=o||0,isNaN(f)&&(f=n-v-a-(s||0)),isNaN(c)&&(c=i-u-o-(l||0));var d=new or(a+r[3],o+r[0],f,c);return d.margin=r,d}function Jr(t){var e=t.layoutMode||t.constructor.layoutMode;return B(e)?e:e?{type:e}:null}function en(t,e,r){var n=r&&r.ignoreSize;!E(n)&&(n=[n,n]);var i=o(br[0],0),a=o(br[1],1);f(br[0],t,i),f(br[1],t,a);function o(c,u){var v={},h=0,d={},p=0,g=2;if(Hr(c,function(_){d[_]=t[_]}),Hr(c,function(_){s(e,_)&&(v[_]=d[_]=e[_]),l(v,_)&&h++,l(d,_)&&p++}),n[u])return l(e,c[1])?d[c[2]]=null:l(e,c[2])&&(d[c[1]]=null),d;if(p===g||!h)return d;if(h>=g)return v;for(var m=0;m=0;l--)s=he(s,i[l],!0);n.defaultOption=s}return n.defaultOption},e.prototype.getReferringComponents=function(r,n){var i=r+"Index",a=r+"Id";return wr(this.ecModel,r,{index:this.get(i,!0),id:this.get(a,!0)},n)},e.prototype.getBoxLayoutParams=function(){var r=this;return{left:r.get("left"),top:r.get("top"),right:r.get("right"),bottom:r.get("bottom"),width:r.get("width"),height:r.get("height")}},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(r){this.option.zlevel=r},e.protoInitialize=function(){var r=e.prototype;r.type="component",r.id="",r.name="",r.mainType="",r.subType="",r.componentIndex=0}(),e}(ve);hs(Rt,ve);Ii(Rt);Pc(Rt);Lc(Rt,Zc);function Zc(t){var e=[];return S(Rt.getClassesByMainType(t),function(r){e=e.concat(r.dependencies||r.prototype.dependencies||[])}),e=H(e,function(r){return Le(r).main}),t!=="dataset"&&_e(e,"dataset")<=0&&e.unshift("dataset"),e}var ee=Rt,Us="";typeof navigator!="undefined"&&(Us=navigator.platform||"");var xt="rgba(0, 0, 0, 0.2)",qc={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:xt,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:xt,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:xt,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:xt,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:xt,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:xt,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Us.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},Gs=V(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),Oe="original",Se="arrayRows",Ie="objectRows",Ne="keyedColumns",nt="typedArray",Ys="unknown",Ge="column",Et="row",ie={Must:1,Might:2,Not:3},jc=re();function Qc(t){jc(t).datasetMap=V()}function Jc(t,e,r){var n={},i=Ws(t);if(!i)return n;var a=e.sourceFormat,o=e.dimensionsDefine,s;(a===Ie||a===Ne)&&S(o,function(c,u){(B(c)?c.name:c)==="name"&&(s=u)});var l=function(){for(var c={},u={},v=[],h=0,d=Math.min(5,r);he)return t[n];return t[r-1]}function ih(t,e,r,n,i,a,o){a=a||t;var s=e(a),l=s.paletteIdx||0,f=s.paletteNameMap=s.paletteNameMap||{};if(f.hasOwnProperty(i))return f[i];var c=o==null||!n?r:nh(n,o);if(c=c||r,!(!c||!c.length)){var u=c[l];return i&&(f[i]=u),s.paletteIdx=(l+1)%c.length,u}}function ah(t,e){e(t).paletteIdx=0,e(t).paletteNameMap={}}var Mr,Ft,Pa,La="\0_ec_inner",oh=1,Ks=function(t){fe(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.init=function(r,n,i,a,o,s){a=a||{},this.option=null,this._theme=new ve(a),this._locale=new ve(o),this._optionManager=s},e.prototype.setOption=function(r,n,i){var a=ka(n);this._optionManager.setOption(r,i,a),this._resetOption(null,a)},e.prototype.resetOption=function(r,n){return this._resetOption(r,ka(n))},e.prototype._resetOption=function(r,n){var i=!1,a=this._optionManager;if(!r||r==="recreate"){var o=a.mountOption(r==="recreate");!this.option||r==="recreate"?Pa(this,o):(this.restoreData(),this._mergeOption(o,n)),i=!0}if((r==="timeline"||r==="media")&&this.restoreData(),!r||r==="recreate"||r==="timeline"){var s=a.getTimelineOption(this);s&&(i=!0,this._mergeOption(s,n))}if(!r||r==="recreate"||r==="media"){var l=a.getMediaOption(this);l.length&&S(l,function(f){i=!0,this._mergeOption(f,n)},this)}return i},e.prototype.mergeOption=function(r){this._mergeOption(r,null)},e.prototype._mergeOption=function(r,n){var i=this.option,a=this._componentsMap,o=this._componentsCount,s=[],l=V(),f=n&&n.replaceMergeMainTypeMap;Qc(this),S(r,function(u,v){u!=null&&(ee.hasClass(v)?v&&(s.push(v),l.set(v,!0)):i[v]=i[v]==null?z(u):he(i[v],u,!0))}),f&&f.each(function(u,v){ee.hasClass(v)&&!l.get(v)&&(s.push(v),l.set(v,!0))}),ee.topologicalTravel(s,ee.getAllClassMainTypes(),c,this);function c(u){var v=rh(this,u,de(r[u])),h=a.get(u),d=h?f&&f.get(u)?"replaceMerge":"normalMerge":"replaceAll",p=rf(h,v,d);ff(p,u,ee),i[u]=null,a.set(u,null),o.set(u,0);var g=[],m=[],y=0,_;S(p,function(w,x){var T=w.existing,b=w.newOption;if(!b)T&&(T.mergeOption({},this),T.optionUpdated({},!1));else{var D=u==="series",C=ee.getClass(u,w.keyInfo.subType,!D);if(!C)return;if(u==="tooltip"){if(_)return;_=!0}if(T&&T.constructor===C)T.name=w.keyInfo.name,T.mergeOption(b,this),T.optionUpdated(b,!1);else{var A=R({componentIndex:x},w.keyInfo);T=new C(b,this,this,A),R(T,A),w.brandNew&&(T.__requireNewView=!0),T.init(b,this,this),T.optionUpdated(null,!0)}}T?(g.push(T.option),m.push(T),y++):(g.push(void 0),m.push(void 0))},this),i[u]=g,a.set(u,m),o.set(u,y),u==="series"&&Mr(this)}this._seriesIndices||Mr(this)},e.prototype.getOption=function(){var r=z(this.option);return S(r,function(n,i){if(ee.hasClass(i)){for(var a=de(n),o=a.length,s=!1,l=o-1;l>=0;l--)a[l]&&!lr(a[l])?s=!0:(a[l]=null,!s&&o--);a.length=o,r[i]=a}}),delete r[La],r},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(r){this._payload=r},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(r,n){var i=this._componentsMap.get(r);if(i){var a=i[n||0];if(a)return a;if(n==null){for(var o=0;o=e:r==="max"?t<=e:t===e}function mh(t,e){return t.join(",")===e.join(",")}var yh=vh,be=S,vr=B,Oa=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Rn(t){var e=t&&t.itemStyle;if(!!e)for(var r=0,n=Oa.length;r=0;g--){var m=t[g];if(s||(d=m.data.rawIndexOf(m.stackedByDimension,h)),d>=0){var y=m.data.getByRawIndex(m.stackResultDimension,d);if(l==="all"||l==="positive"&&y>0||l==="negative"&&y<0||l==="samesign"&&v>=0&&y>0||l==="samesign"&&v<=0&&y<0){v=ju(v,y),p=y;break}}}return n[0]=v,n[1]=p,n})})}var yn=function(){function t(e){this.data=e.data||(e.sourceFormat===Ne?{}:[]),this.sourceFormat=e.sourceFormat||Ys,this.seriesLayoutBy=e.seriesLayoutBy||Ge,this.startIndex=e.startIndex||0,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var r=this.dimensionsDefine=e.dimensionsDefine;if(r)for(var n=0;np&&(p=_)}h[0]=d,h[1]=p}},i=function(){return this._data?this._data.length/this._dimSize:0};Ua=(e={},e[Se+"_"+Ge]={pure:!0,appendData:a},e[Se+"_"+Et]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[Ie]={pure:!0,appendData:a},e[Ne]={pure:!0,appendData:function(o){var s=this._data;S(o,function(l,f){for(var c=s[f]||(s[f]=[]),u=0;u<(l||[]).length;u++)c.push(l[u])})}},e[Oe]={appendData:a},e[nt]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},e);function a(o){for(var s=0;s=0&&(p=o.interpolatedValue[g])}return p!=null?p+"":""})}},t.prototype.getRawValue=function(e,r){return tn(this.getData(r),e)},t.prototype.formatTooltip=function(e,r,n){},t}();function $a(t){var e,r;return B(t)?t.type&&(r=t):e=t,{text:e,frag:r}}function rr(t){return new Nh(t)}var Nh=function(){function t(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return t.prototype.perform=function(e){var r=this._upstream,n=e&&e.skip;if(this._dirty&&r){var i=this.context;i.data=i.outputData=r.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var a;this._plan&&!n&&(a=this._plan(this.context));var o=c(this._modBy),s=this._modDataCount||0,l=c(e&&e.modBy),f=e&&e.modDataCount||0;(o!==l||s!==f)&&(a="reset");function c(y){return!(y>=1)&&(y=1),y}var u;(this._dirty||a==="reset")&&(this._dirty=!1,u=this._doReset(n)),this._modBy=l,this._modDataCount=f;var v=e&&e.step;if(r?this._dueEnd=r._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var h=this._dueIndex,d=Math.min(v!=null?this._dueIndex+v:1/0,this._dueEnd);if(!n&&(u||h1&&n>0?s:o}};return a;function o(){return e=t?null:li?-this._resultLT:0},t}(),Vh=function(){function t(){}return t.prototype.getRawData=function(){throw new Error("not supported")},t.prototype.getRawDataItem=function(e){throw new Error("not supported")},t.prototype.cloneRawData=function(){},t.prototype.getDimensionInfo=function(e){},t.prototype.cloneAllDimensionInfo=function(){},t.prototype.count=function(){},t.prototype.retrieveValue=function(e,r){},t.prototype.retrieveValueFromItem=function(e,r){},t.prototype.convertValue=function(e,r){return Ur(e,r)},t}();function Fh(t,e){var r=new Vh,n=t.data,i=r.sourceFormat=t.sourceFormat,a=t.startIndex,o="";t.seriesLayoutBy!==Ge&&ye(o);var s=[],l={},f=t.dimensionsDefine;if(f)S(f,function(p,g){var m=p.name,y={index:g,name:m,displayName:p.displayName};if(s.push(y),m!=null){var _="";Pt(l,m)&&ye(_),l[m]=y}});else for(var c=0;c65535?Xh:Kh}function Dt(){return[1/0,-1/0]}function Zh(t){var e=t.constructor;return e===Array?t.slice():new e(t)}function Za(t,e,r,n,i){var a=ul[r||"float"];if(i){var o=t[e],s=o&&o.length;if(s!==n){for(var l=new a(n),f=0;fg[1]&&(g[1]=p)}return this._rawCount=this._count=l,{start:s,end:l}},t.prototype._initDataFromProvider=function(e,r,n){for(var i=this._provider,a=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,f=H(o,function(y){return y.property}),c=0;cm[1]&&(m[1]=g)}}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=r,this._extent=[]},t.prototype.count=function(){return this._count},t.prototype.get=function(e,r){if(!(r>=0&&r=0&&r=this._rawCount||e<0)return-1;if(!this._indices)return e;var r=this._indices,n=r[e];if(n!=null&&ne)a=o-1;else return o}return-1},t.prototype.indicesOfNearest=function(e,r,n){var i=this._chunks,a=i[e],o=[];if(!a)return o;n==null&&(n=1/0);for(var s=1/0,l=-1,f=0,c=0,u=this.count();c=0&&l<0)&&(s=d,l=h,f=0),h===l&&(o[f++]=c))}return o.length=f,o},t.prototype.getIndices=function(){var e,r=this._indices;if(r){var n=r.constructor,i=this._count;if(n===Array){e=new n(i);for(var a=0;a=u&&y<=v||isNaN(y))&&(l[f++]=p),p++}d=!0}else if(a===2){for(var g=h[i[0]],_=h[i[1]],w=e[i[1]][0],x=e[i[1]][1],m=0;m=u&&y<=v||isNaN(y))&&(T>=w&&T<=x||isNaN(T))&&(l[f++]=p),p++}d=!0}}if(!d)if(a===1)for(var m=0;m=u&&y<=v||isNaN(y))&&(l[f++]=b)}else for(var m=0;me[A][1])&&(D=!1)}D&&(l[f++]=r.getRawIndex(m))}return fm[1]&&(m[1]=g)}}}},t.prototype.lttbDownSample=function(e,r){var n=this.clone([e],!0),i=n._chunks,a=i[e],o=this.count(),s=0,l=Math.floor(1/r),f=this.getRawIndex(0),c,u,v,h=new(Ct(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));h[s++]=f;for(var d=1;dc&&(c=u,v=w)}M>0&&Ms&&(p=s-c);for(var g=0;gd&&(d=y,h=c+g)}var _=this.getRawIndex(u),w=this.getRawIndex(h);uc-d&&(l=c-d,s.length=l);for(var p=0;pu[1]&&(u[1]=m),v[h++]=y}return a._count=h,a._indices=v,a._updateGetRawIdx(),a},t.prototype.each=function(e,r){if(!!this._count)for(var n=e.length,i=this._chunks,a=0,o=this.count();al&&(l=u)}return o=[s,l],this._extent[e]=o,o},t.prototype.getRawDataItem=function(e){var r=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(r);for(var n=[],i=this._chunks,a=0;a=0?this._indices[e]:-1},t.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},t.internalField=function(){function e(r,n,i,a){return Ur(r[a],this._dimensions[a])}On={arrayRows:e,objectRows:function(r,n,i,a){return Ur(r[n],this._dimensions[a])},keyedColumns:e,original:function(r,n,i,a){var o=r&&(r.value==null?r:r.value);return Ur(o instanceof Array?o[a]:o,this._dimensions[a])},typedArray:function(r,n,i,a){return r[a]}}}(),t}(),qh=function(){function t(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return t.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},t.prototype._setLocalSource=function(e,r){this._sourceList=e,this._upstreamSignList=r,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},t.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},t.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},t.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,r=this._getUpstreamSourceManagers(),n=!!r.length,i,a;if(Ar(e)){var o=e,s=void 0,l=void 0,f=void 0;if(n){var c=r[0];c.prepareSource(),f=c.getSource(),s=f.data,l=f.sourceFormat,a=[c._getVersionSign()]}else s=o.get("data",!0),l=Te(s)?nt:Oe,a=[];var u=this._getSourceMetaRawOption()||{},v=f&&f.metaRawOption||{},h=G(u.seriesLayoutBy,v.seriesLayoutBy)||null,d=G(u.sourceHeader,v.sourceHeader),p=G(u.dimensions,v.dimensions),g=h!==v.seriesLayoutBy||!!d!=!!v.sourceHeader||p;i=g?[ci(s,{seriesLayoutBy:h,sourceHeader:d,dimensions:p},l)]:[]}else{var m=e;if(n){var y=this._applyTransform(r);i=y.sourceList,a=y.upstreamSignList}else{var _=m.get("source",!0);i=[ci(_,this._getSourceMetaRawOption(),null)],a=[]}}this._setLocalSource(i,a)},t.prototype._applyTransform=function(e){var r=this._sourceHost,n=r.get("transform",!0),i=r.get("fromTransformResult",!0);if(i!=null){var a="";e.length!==1&&qa(a)}var o,s=[],l=[];return S(e,function(f){f.prepareSource();var c=f.getSource(i||0),u="";i!=null&&!c&&qa(u),s.push(c),l.push(f._getVersionSign())}),n?o=Wh(n,s,{datasetIndex:r.componentIndex}):i!=null&&(o=[Ah(s[0])]),{sourceList:o,upstreamSignList:l}},t.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),r=0;r1||r>0&&!t.noHeader;return S(t.blocks,function(i){var a=vl(i);a>=e&&(e=a+ +(n&&(!a||vi(i)&&!i.noHeader)))}),e}return 0}function ev(t,e,r,n){var i=e.noHeader,a=rv(vl(e)),o=[],s=e.blocks||[];Ye(!s||E(s)),s=s||[];var l=t.orderMode;if(e.sortBlocks&&l){s=s.slice();var f={valueAsc:"asc",valueDesc:"desc"};if(Pt(f,l)){var c=new Bh(f[l],null);s.sort(function(p,g){return c.evaluate(p.sortParam,g.sortParam)})}else l==="seriesDesc"&&s.reverse()}S(s,function(p,g){var m=e.valueFormatter,y=hl(p)(m?R(R({},t),{valueFormatter:m}):t,p,g>0?a.html:0,n);y!=null&&o.push(y)});var u=t.renderMode==="richText"?o.join(a.richText):di(n,o.join(""),i?r:a.html);if(i)return u;var v=fi(e.header,"ordinal",t.useUTC),h=cl(n,t.renderMode).nameStyle,d=fl(n);return t.renderMode==="richText"?dl(t,v,h)+a.richText+u:di(n,'
'+me(v)+"
"+u,r)}function tv(t,e,r,n){var i=t.renderMode,a=e.noName,o=e.noValue,s=!e.markerType,l=e.name,f=t.useUTC,c=e.valueFormatter||t.valueFormatter||function(w){return w=E(w)?w:[w],H(w,function(x,T){return fi(x,E(h)?h[T]:h,f)})};if(!(a&&o)){var u=s?"":t.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",i),v=a?"":fi(l,"ordinal",f),h=e.valueType,d=o?[]:c(e.value,e.dataIndex),p=!s||!a,g=!s&&a,m=cl(n,i),y=m.nameStyle,_=m.valueStyle;return i==="richText"?(s?"":u)+(a?"":dl(t,v,y))+(o?"":av(t,d,p,g,_)):di(n,(s?"":u)+(a?"":nv(v,!s,y))+(o?"":iv(d,p,g,_)),r)}}function ja(t,e,r,n,i,a){if(!!t){var o=hl(t),s={useUTC:i,renderMode:r,orderMode:n,markupStyleCreator:e,valueFormatter:t.valueFormatter};return o(s,t,0,a)}}function rv(t){return{html:Qh[t],richText:Jh[t]}}function di(t,e,r){var n='
',i="margin: "+r+"px 0 0",a=fl(t);return'
'+e+n+"
"}function nv(t,e,r){var n=e?"margin-left:2px":"";return''+me(t)+""}function iv(t,e,r,n){var i=r?"10px":"20px",a=e?"float:right;margin-left:"+i:"";return t=E(t)?t:[t],''+H(t,function(o){return me(o)}).join("  ")+""}function dl(t,e,r){return t.markupStyleCreator.wrapRichTextStyle(e,r)}function av(t,e,r,n,i){var a=[i],o=n?10:20;return r&&a.push({padding:[0,0,0,o],align:"right"}),t.markupStyleCreator.wrapRichTextStyle(E(e)?e.join(" "):e,a)}function ov(t,e){var r=t.getData().getItemVisual(e,"style"),n=r[t.visualDrawType];return hr(n)}function pl(t,e){var r=t.get("padding");return r!=null?r:e==="richText"?[8,10]:10}var Nn=function(){function t(){this.richTextStyles={},this._nextStyleNameId=as()}return t.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},t.prototype.makeTooltipMarker=function(e,r,n){var i=n==="richText"?this._generateStyleName():null,a=Wc({color:r,type:e,renderMode:n,markerId:i});return O(a)?a:(this.richTextStyles[i]=a.style,a.content)},t.prototype.wrapRichTextStyle=function(e,r){var n={};E(r)?S(r,function(a){return R(n,a)}):R(n,r);var i=this._generateStyleName();return this.richTextStyles[i]=n,"{"+i+"|"+e+"}"},t}();function sv(t){var e=t.series,r=t.dataIndex,n=t.multipleSeries,i=e.getData(),a=i.mapDimensionsAll("defaultedTooltip"),o=a.length,s=e.getRawValue(r),l=E(s),f=ov(e,r),c,u,v,h;if(o>1||l&&!o){var d=lv(s,e,r,a,f);c=d.inlineValues,u=d.inlineValueTypes,v=d.blocks,h=d.inlineValues[0]}else if(o){var p=i.getDimensionInfo(a[0]);h=c=tn(i,r,a[0]),u=p.type}else h=c=l?s[0]:s;var g=us(e),m=g&&e.name||"",y=i.getName(r),_=n?m:y;return dr("section",{header:m,noHeader:n||!g,sortParam:h,blocks:[dr("nameValue",{markerType:"item",markerColor:f,name:_,noName:!_r(_),value:c,valueType:u,dataIndex:r})].concat(v||[])})}function lv(t,e,r,n,i){var a=e.getData(),o=Wr(t,function(u,v,h){var d=a.getDimensionInfo(h);return u=u||d&&d.tooltip!==!1&&d.displayName!=null},!1),s=[],l=[],f=[];n.length?S(n,function(u){c(tn(a,r,u),u)}):S(t,c);function c(u,v){var h=a.getDimensionInfo(v);!h||h.otherDims.tooltip===!1||(o?f.push(dr("nameValue",{markerType:"subItem",markerColor:i,name:h.displayName,value:u,valueType:h.type})):(s.push(u),l.push(h.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:f}}var qe=re();function Ir(t,e){return t.getName(e)||t.getId(e)}var uv="__universalTransitionEnabled",Sn=function(t){fe(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r._selectedDataIndicesMap={},r}return e.prototype.init=function(r,n,i){this.seriesIndex=this.componentIndex,this.dataTask=rr({count:cv,reset:hv}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(r,i);var a=qe(this).sourceManager=new qh(this);a.prepareSource();var o=this.getInitialData(r,i);Ja(o,this),this.dataTask.context.data=o,qe(this).dataBeforeProcessed=o,Qa(this),this._initSelectedMapFromData(o)},e.prototype.mergeDefaultAndTheme=function(r,n){var i=Jr(this),a=i?Hs(r):{},o=this.subType;ee.hasClass(o)&&(o+="Series"),he(r,n.getTheme().get(this.subType)),he(r,this.getDefaultOption()),ri(r,"label",["show"]),this.fillDataTextStyle(r.data),i&&en(r,a,i)},e.prototype.mergeOption=function(r,n){r=he(this.option,r,!0),this.fillDataTextStyle(r.data);var i=Jr(this);i&&en(this.option,r,i);var a=qe(this).sourceManager;a.dirty(),a.prepareSource();var o=this.getInitialData(r,n);Ja(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,qe(this).dataBeforeProcessed=o,Qa(this),this._initSelectedMapFromData(o)},e.prototype.fillDataTextStyle=function(r){if(r&&!Te(r))for(var n=["show"],i=0;ithis.getShallow("animationThreshold")&&(n=!1),!!n},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(r,n,i){var a=this.ecModel,o=Gi.prototype.getColorFromPalette.call(this,r,n,i);return o||(o=a.getColorFromPalette(r,n,i)),o},e.prototype.coordDimToDataDim=function(r){return this.getRawData().mapDimensionsAll(r)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(r,n){this._innerSelect(this.getData(n),r)},e.prototype.unselect=function(r,n){var i=this.option.selectedMap;if(!!i){var a=this.option.selectedMode,o=this.getData(n);if(a==="series"||i==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s=0&&i.push(o)}return i},e.prototype.isSelected=function(r,n){var i=this.option.selectedMap;if(!i)return!1;var a=this.getData(n);return(i==="all"||i[Ir(a,r)])&&!a.getItemModel(r).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[uv])return!0;var r=this.option.universalTransition;return r?r===!0?!0:r&&r.enabled:!1},e.prototype._innerSelect=function(r,n){var i,a,o=this.option,s=o.selectedMode,l=n.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){B(o.selectedMap)||(o.selectedMap={});for(var f=o.selectedMap,c=0;c0&&this._innerSelect(r,n)}},e.registerClass=function(r){return ee.registerClass(r)},e.protoInitialize=function(){var r=e.prototype;r.type="series.__base__",r.seriesIndex=0,r.ignoreStyleOnData=!1,r.hasSymbolVisual=!1,r.defaultSymbol="circle",r.visualStyleAccessPath="itemStyle",r.visualDrawType="fill"}(),e}(ee);gt(Sn,Oh);gt(Sn,Gi);hs(Sn,ee);function Qa(t){var e=t.name;us(t)||(t.name=fv(t)||e)}function fv(t){var e=t.getRawData(),r=e.mapDimensionsAll("seriesName"),n=[];return S(r,function(i){var a=e.getDimensionInfo(i);a.displayName&&n.push(a.displayName)}),n.join(" ")}function cv(t){return t.model.getRawData().count()}function hv(t){var e=t.model;return e.setData(e.getRawData().cloneShallow()),vv}function vv(t,e){e.outputData&&t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function Ja(t,e){S(Iu(t.CHANGABLE_METHODS,t.DOWNSAMPLE_METHODS),function(r){t.wrapMethod(r,we(dv,e))})}function dv(t,e){var r=pi(t);return r&&r.setOutputEnd((e||this).count()),e}function pi(t){var e=(t.ecModel||{}).scheduler,r=e&&e.getPipeline(t.uid);if(r){var n=r.currentTask;if(n){var i=n.agentStubMap;i&&(n=i.get(t.uid))}return n}}var pr=Sn,Xi=function(){function t(){this.group=new pt,this.uid=mn("viewComponent")}return t.prototype.init=function(e,r){},t.prototype.render=function(e,r,n,i){},t.prototype.dispose=function(e,r){},t.prototype.updateView=function(e,r,n,i){},t.prototype.updateLayout=function(e,r,n,i){},t.prototype.updateVisual=function(e,r,n,i){},t.prototype.toggleBlurSeries=function(e,r,n){},t.prototype.eachRendered=function(e){var r=this.group;r&&r.traverse(e)},t}();Ai(Xi);Ii(Xi);var Lt=Xi;function pv(){var t=re();return function(e){var r=t(e),n=e.pipelineContext,i=!!r.large,a=!!r.progressiveRender,o=r.large=!!(n&&n.large),s=r.progressiveRender=!!(n&&n.progressiveRender);return(i!==o||a!==s)&&"reset"}}var gl=re(),gv=pv(),Ki=function(){function t(){this.group=new pt,this.uid=mn("viewChart"),this.renderTask=rr({plan:mv,reset:yv}),this.renderTask.context={view:this}}return t.prototype.init=function(e,r){},t.prototype.render=function(e,r,n,i){},t.prototype.highlight=function(e,r,n,i){var a=e.getData(i&&i.dataType);!a||to(a,i,"emphasis")},t.prototype.downplay=function(e,r,n,i){var a=e.getData(i&&i.dataType);!a||to(a,i,"normal")},t.prototype.remove=function(e,r){this.group.removeAll()},t.prototype.dispose=function(e,r){},t.prototype.updateView=function(e,r,n,i){this.render(e,r,n,i)},t.prototype.updateLayout=function(e,r,n,i){this.render(e,r,n,i)},t.prototype.updateVisual=function(e,r,n,i){this.render(e,r,n,i)},t.prototype.eachRendered=function(e){Ls(this.group,e)},t.markUpdateMethod=function(e,r){gl(e).updateMethod=r},t.protoInitialize=function(){var e=t.prototype;e.type="chart"}(),t}();function eo(t,e,r){t&&si(t)&&(e==="emphasis"?ni:ii)(t,r)}function to(t,e,r){var n=Sr(t,e),i=e&&e.highlightKey!=null?Kf(e.highlightKey):null;n!=null?S(de(n),function(a){eo(t.getItemGraphicEl(a),r,i)}):t.eachItemGraphicEl(function(a){eo(a,r,i)})}Ai(Ki);Ii(Ki);function mv(t){return gv(t.model)}function yv(t){var e=t.model,r=t.ecModel,n=t.api,i=t.payload,a=e.pipelineContext.progressiveRender,o=t.view,s=i&&gl(i).updateMethod,l=a?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](e,r,n,i),_v[l]}var _v={incrementalPrepareRender:{progress:function(t,e){e.view.incrementalRender(t,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(t,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},It=Ki,rn="\0__throttleOriginMethod",ro="\0__throttleRate",no="\0__throttleType";function ml(t,e,r){var n,i=0,a=0,o=null,s,l,f,c;e=e||0;function u(){a=new Date().getTime(),o=null,t.apply(l,f||[])}var v=function(){for(var h=[],d=0;d=0?u():o=setTimeout(u,-s),i=n};return v.clear=function(){o&&(clearTimeout(o),o=null)},v.debounceNextCall=function(h){c=h},v}function yl(t,e,r,n){var i=t[e];if(!!i){var a=i[rn]||i,o=i[no],s=i[ro];if(s!==r||o!==n){if(r==null||!n)return t[e]=a;i=t[e]=ml(a,r,n==="debounce"),i[rn]=a,i[no]=n,i[ro]=r}return i}}function gi(t,e){var r=t[e];r&&r[rn]&&(r.clear&&r.clear(),t[e]=r[rn])}var io=re(),ao={itemStyle:ur(Es,!0),lineStyle:ur(Rs,!0)},Sv={lineStyle:"stroke",itemStyle:"fill"};function _l(t,e){var r=t.visualStyleMapper||ao[e];return r||(console.warn("Unknown style type '"+e+"'."),ao.itemStyle)}function Sl(t,e){var r=t.visualDrawType||Sv[e];return r||(console.warn("Unknown style type '"+e+"'."),"fill")}var wv={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var r=t.getData(),n=t.visualStyleAccessPath||"itemStyle",i=t.getModel(n),a=_l(t,n),o=a(i),s=i.getShallow("decal");s&&(r.setVisual("decal",s),s.dirty=!0);var l=Sl(t,n),f=o[l],c=W(f)?f:null,u=o.fill==="auto"||o.stroke==="auto";if(!o[l]||c||u){var v=t.getColorFromPalette(t.name,null,e.getSeriesCount());o[l]||(o[l]=v,r.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||W(o.fill)?v:o.fill,o.stroke=o.stroke==="auto"||W(o.stroke)?v:o.stroke}if(r.setVisual("style",o),r.setVisual("drawType",l),!e.isSeriesFiltered(t)&&c)return r.setVisual("colorFromPalette",!1),{dataEach:function(h,d){var p=t.getDataParams(d),g=R({},o);g[l]=c(p),h.setItemVisual(d,"style",g)}}}},Ht=new ve,Tv={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){if(!(t.ignoreStyleOnData||e.isSeriesFiltered(t))){var r=t.getData(),n=t.visualStyleAccessPath||"itemStyle",i=_l(t,n),a=r.getVisual("drawType");return{dataEach:r.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[n]){Ht.option=l[n];var f=i(Ht),c=o.ensureUniqueItemVisual(s,"style");R(c,f),Ht.option.decal&&(o.setItemVisual(s,"decal",Ht.option.decal),Ht.option.decal.dirty=!0),a in f&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},xv={performRawSeries:!0,overallReset:function(t){var e=V();t.eachSeries(function(r){var n=r.getColorBy();if(!r.isColorBySeries()){var i=r.type+"-"+n,a=e.get(i);a||(a={},e.set(i,a)),io(r).scope=a}}),t.eachSeries(function(r){if(!(r.isColorBySeries()||t.isSeriesFiltered(r))){var n=r.getRawData(),i={},a=r.getData(),o=io(r).scope,s=r.visualStyleAccessPath||"itemStyle",l=Sl(r,s);a.each(function(f){var c=a.getRawIndex(f);i[c]=f}),n.each(function(f){var c=i[f],u=a.getItemVisual(c,"colorFromPalette");if(u){var v=a.ensureUniqueItemVisual(c,"style"),h=n.getName(f)||f+"",d=n.count();v[l]=r.getColorFromPalette(h,o,d)}})}})}},Pr=Math.PI;function Cv(t,e){e=e||{},pe(e,{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var r=new pt,n=new Ue({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});r.add(n);var i=new Ee({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),a=new Ue({style:{fill:"none"},textContent:i,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});r.add(a);var o;return e.showSpinner&&(o=new Di({shape:{startAngle:-Pr/2,endAngle:-Pr/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:Pr*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:Pr*3/2}).delay(300).start("circularInOut"),r.add(o)),r.resize=function(){var s=i.getBoundingRect().width,l=e.showSpinner?e.spinnerRadius:0,f=(t.getWidth()-l*2-(e.showSpinner&&s?10:0)-s)/2-(e.showSpinner&&s?0:5+s/2)+(e.showSpinner?0:s/2)+(s?0:l),c=t.getHeight()/2;e.showSpinner&&o.setShape({cx:f,cy:c}),a.setShape({x:f-l,y:c-l,width:l*2,height:l*2}),n.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},r.resize(),r}var Dv=function(){function t(e,r,n,i){this._stageTaskMap=V(),this.ecInstance=e,this.api=r,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}return t.prototype.restoreData=function(e,r){e.restoreData(r),this._stageTaskMap.each(function(n){var i=n.overallTask;i&&i.dirty()})},t.prototype.getPerformArgs=function(e,r){if(!!e.__pipeline){var n=this._pipelineMap.get(e.__pipeline.id),i=n.context,a=!r&&n.progressiveEnabled&&(!i||i.progressiveRender)&&e.__idxInPipeline>n.blockIndex,o=a?n.step:null,s=i&&i.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},t.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},t.prototype.updateStreamModes=function(e,r){var n=this._pipelineMap.get(e.uid),i=e.getData(),a=i.count(),o=n.progressiveEnabled&&r.incrementalPrepareRender&&a>=n.threshold,s=e.get("large")&&a>=e.get("largeThreshold"),l=e.get("progressiveChunkMode")==="mod"?a:null;e.pipelineContext=n.context={progressiveRender:o,modDataCount:l,large:s}},t.prototype.restorePipelines=function(e){var r=this,n=r._pipelineMap=V();e.eachSeries(function(i){var a=i.getProgressive(),o=i.uid;n.set(o,{id:o,head:null,tail:null,threshold:i.getProgressiveThreshold(),progressiveEnabled:a&&!(i.preventIncremental&&i.preventIncremental()),blockIndex:-1,step:Math.round(a||700),count:0}),r._pipe(i,i.dataTask)})},t.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,r=this.api.getModel(),n=this.api;S(this._allHandlers,function(i){var a=e.get(i.uid)||e.set(i.uid,{}),o="";Ye(!(i.reset&&i.overallReset),o),i.reset&&this._createSeriesStageTask(i,a,r,n),i.overallReset&&this._createOverallStageTask(i,a,r,n)},this)},t.prototype.prepareView=function(e,r,n,i){var a=e.renderTask,o=a.context;o.model=r,o.ecModel=n,o.api=i,a.__block=!e.incrementalPrepareRender,this._pipe(r,a)},t.prototype.performDataProcessorTasks=function(e,r){this._performStageTasks(this._dataProcessorHandlers,e,r,{block:!0})},t.prototype.performVisualTasks=function(e,r,n){this._performStageTasks(this._visualHandlers,e,r,n)},t.prototype._performStageTasks=function(e,r,n,i){i=i||{};var a=!1,o=this;S(e,function(l,f){if(!(i.visualType&&i.visualType!==l.visualType)){var c=o._stageTaskMap.get(l.uid),u=c.seriesTaskMap,v=c.overallTask;if(v){var h,d=v.agentStubMap;d.each(function(g){s(i,g)&&(g.dirty(),h=!0)}),h&&v.dirty(),o.updatePayload(v,n);var p=o.getPerformArgs(v,i.block);d.each(function(g){g.perform(p)}),v.perform(p)&&(a=!0)}else u&&u.each(function(g,m){s(i,g)&&g.dirty();var y=o.getPerformArgs(g,i.block);y.skip=!l.performRawSeries&&r.isSeriesFiltered(g.context.model),o.updatePayload(g,n),g.perform(y)&&(a=!0)})}});function s(l,f){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(f.__pipeline.id))}this.unfinished=a||this.unfinished},t.prototype.performSeriesTasks=function(e){var r;e.eachSeries(function(n){r=n.dataTask.perform()||r}),this.unfinished=r||this.unfinished},t.prototype.plan=function(){this._pipelineMap.each(function(e){var r=e.tail;do{if(r.__block){e.blockIndex=r.__idxInPipeline;break}r=r.getUpstream()}while(r)})},t.prototype.updatePayload=function(e,r){r!=="remain"&&(e.context.payload=r)},t.prototype._createSeriesStageTask=function(e,r,n,i){var a=this,o=r.seriesTaskMap,s=r.seriesTaskMap=V(),l=e.seriesType,f=e.getTargetSeries;e.createOnAllSeries?n.eachRawSeries(c):l?n.eachRawSeriesByType(l,c):f&&f(n,i).each(c);function c(u){var v=u.uid,h=s.set(v,o&&o.get(v)||rr({plan:Pv,reset:Lv,count:Ev}));h.context={model:u,ecModel:n,api:i,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:a},a._pipe(u,h)}},t.prototype._createOverallStageTask=function(e,r,n,i){var a=this,o=r.overallTask=r.overallTask||rr({reset:bv});o.context={ecModel:n,api:i,overallReset:e.overallReset,scheduler:a};var s=o.agentStubMap,l=o.agentStubMap=V(),f=e.seriesType,c=e.getTargetSeries,u=!0,v=!1,h="";Ye(!e.createOnAllSeries,h),f?n.eachRawSeriesByType(f,d):c?c(n,i).each(d):(u=!1,S(n.getSeries(),d));function d(p){var g=p.uid,m=l.set(g,s&&s.get(g)||(v=!0,rr({reset:Mv,onDirty:Iv})));m.context={model:p,overallProgress:u},m.agent=o,m.__block=u,a._pipe(p,m)}v&&o.dirty()},t.prototype._pipe=function(e,r){var n=e.uid,i=this._pipelineMap.get(n);!i.head&&(i.head=r),i.tail&&i.tail.pipe(r),i.tail=r,r.__idxInPipeline=i.count++,r.__pipeline=i},t.wrapStageHandler=function(e,r){return W(e)&&(e={overallReset:e,seriesType:kv(e)}),e.uid=mn("stageHandler"),r&&(e.visualType=r),e},t}();function bv(t){t.overallReset(t.ecModel,t.api,t.payload)}function Mv(t){return t.overallProgress&&Av}function Av(){this.agent.dirty(),this.getDownstream().dirty()}function Iv(){this.agent&&this.agent.dirty()}function Pv(t){return t.plan?t.plan(t.model,t.ecModel,t.api,t.payload):null}function Lv(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=de(t.reset(t.model,t.ecModel,t.api,t.payload));return e.length>1?H(e,function(r,n){return wl(n)}):Rv}var Rv=wl(0);function wl(t){return function(e,r){var n=r.data,i=r.resetDefines[t];if(i&&i.dataEach)for(var a=e.start;a0&&h===f.length-v.length){var d=f.slice(0,h);d!=="data"&&(r.mainType=d,r[v.toLowerCase()]=l,c=!0)}}s.hasOwnProperty(f)&&(n[f]=l,c=!0),c||(i[f]=l)})}return{cptQuery:r,dataQuery:n,otherQuery:i}},t.prototype.filter=function(e,r){var n=this.eventInfo;if(!n)return!0;var i=n.targetEl,a=n.packedEvent,o=n.model,s=n.view;if(!o||!s)return!0;var l=r.cptQuery,f=r.dataQuery;return c(l,o,"mainType")&&c(l,o,"subType")&&c(l,o,"index","componentIndex")&&c(l,o,"name")&&c(l,o,"id")&&c(f,a,"name")&&c(f,a,"dataIndex")&&c(f,a,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(e,r.otherQuery,i,a));function c(u,v,h,d){return u[h]==null||v[d||h]===u[h]}},t.prototype.afterTrigger=function(){this.eventInfo=null},t}(),mi=["symbol","symbolSize","symbolRotate","symbolOffset"],uo=mi.concat(["symbolKeepAspect"]),Vv={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var r=t.getData();if(t.legendIcon&&r.setVisual("legendIcon",t.legendIcon),!t.hasSymbolVisual)return;for(var n={},i={},a=!1,o=0;o0&&r.unfinished);r.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(r,n,i){if(!this[oe]){if(this._disposed){this.id;return}var a,o,s;if(B(n)&&(i=n.lazyUpdate,a=n.silent,o=n.replaceMerge,s=n.transition,n=n.notMerge),this[oe]=!0,!this._model||n){var l=new yh(this._api),f=this._theme,c=this._model=new Zs;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,f,this._locale,l)}this._model.setOption(r,{replaceMerge:o},Si);var u={seriesTransition:s,optionChanged:!0};if(i)this[ge]={silent:a,updateParams:u},this[oe]=!1,this.getZr().wakeUp();else{try{Mt(this),je.update.call(this,null,u)}catch(v){throw this[ge]=null,this[oe]=!1,v}this._ssr||this._zr.flush(),this[ge]=null,this[oe]=!1,Ut.call(this,a),Gt.call(this,a)}}},e.prototype.setTheme=function(){},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||Z.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(r){return this.renderToCanvas(r)},e.prototype.renderToCanvas=function(r){r=r||{};var n=this._zr.painter;return n.getRenderedCanvas({backgroundColor:r.backgroundColor||this._model.get("backgroundColor"),pixelRatio:r.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(r){r=r||{};var n=this._zr.painter;return n.renderToString({useViewBox:r.useViewBox})},e.prototype.getSvgDataURL=function(){if(!!Z.svgSupported){var r=this._zr,n=r.storage.getDisplayList();return S(n,function(i){i.stopAnimation(null,!0)}),r.painter.toDataURL()}},e.prototype.getDataURL=function(r){if(this._disposed){this.id;return}r=r||{};var n=r.excludeComponents,i=this._model,a=[],o=this;S(n,function(l){i.eachComponent({mainType:l},function(f){var c=o._componentsMap[f.__viewId];c.group.ignore||(a.push(c),c.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(r).toDataURL("image/"+(r&&r.type||"png"));return S(a,function(l){l.group.ignore=!1}),s},e.prototype.getConnectedDataURL=function(r){if(this._disposed){this.id;return}var n=r.type==="svg",i=this.group,a=Math.min,o=Math.max,s=1/0;if(wo[i]){var l=s,f=s,c=-s,u=-s,v=[],h=r&&r.pixelRatio||this.getDevicePixelRatio();S(ir,function(_,w){if(_.group===i){var x=n?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(z(r)),T=_.getDom().getBoundingClientRect();l=a(T.left,l),f=a(T.top,f),c=o(T.right,c),u=o(T.bottom,u),v.push({dom:x,left:T.left,top:T.top})}}),l*=h,f*=h,c*=h,u*=h;var d=c-l,p=u-f,g=ts.createCanvas(),m=ia(g,{renderer:n?"svg":"canvas"});if(m.resize({width:d,height:p}),n){var y="";return S(v,function(_){var w=_.left-l,x=_.top-f;y+=''+_.dom+""}),m.painter.getSvgRoot().innerHTML=y,r.connectedBackgroundColor&&m.painter.setBackgroundColor(r.connectedBackgroundColor),m.refreshImmediately(),m.painter.toDataURL()}else return r.connectedBackgroundColor&&m.add(new Ue({shape:{x:0,y:0,width:d,height:p},style:{fill:r.connectedBackgroundColor}})),S(v,function(_){var w=new un({style:{x:_.left*h-l,y:_.top*h-f,image:_.dom}});m.add(w)}),m.refreshImmediately(),g.toDataURL("image/"+(r&&r.type||"png"))}else return this.getDataURL(r)},e.prototype.convertToPixel=function(r,n){return Hn(this,"convertToPixel",r,n)},e.prototype.convertFromPixel=function(r,n){return Hn(this,"convertFromPixel",r,n)},e.prototype.containPixel=function(r,n){if(this._disposed){this.id;return}var i=this._model,a,o=Dn(i,r);return S(o,function(s,l){l.indexOf("Models")>=0&&S(s,function(f){var c=f.coordinateSystem;if(c&&c.containPoint)a=a||!!c.containPoint(n);else if(l==="seriesModels"){var u=this._chartsMap[f.__viewId];u&&u.containPoint&&(a=a||u.containPoint(n,f))}},this)},this),!!a},e.prototype.getVisual=function(r,n){var i=this._model,a=Dn(i,r,{defaultMainType:"series"}),o=a.seriesModel,s=o.getData(),l=a.hasOwnProperty("dataIndexInside")?a.dataIndexInside:a.hasOwnProperty("dataIndex")?s.indexOfRawIndex(a.dataIndex):null;return l!=null?zv(s,l,n):Hv(s,n)},e.prototype.getViewOfComponentModel=function(r){return this._componentsMap[r.__viewId]},e.prototype.getViewOfSeriesModel=function(r){return this._chartsMap[r.__viewId]},e.prototype._initEvents=function(){var r=this;S(_d,function(n){var i=function(a){var o=r.getModel(),s=a.target,l,f=n==="globalout";if(f?l={}:s&&jt(s,function(d){var p=Q(d);if(p&&p.dataIndex!=null){var g=p.dataModel||o.getSeriesByIndex(p.seriesIndex);return l=g&&g.getDataParams(p.dataIndex,p.dataType,s)||{},!0}else if(p.eventData)return l=R({},p.eventData),!0},!0),l){var c=l.componentType,u=l.componentIndex;(c==="markLine"||c==="markPoint"||c==="markArea")&&(c="series",u=l.seriesIndex);var v=c&&u!=null&&o.getComponent(c,u),h=v&&r[v.mainType==="series"?"_chartsMap":"_componentsMap"][v.__viewId];l.event=a,l.type=n,r._$eventProcessor.eventInfo={targetEl:s,packedEvent:l,model:v,view:h},r.trigger(n,l)}};i.zrEventfulCallAtLast=!0,r._zr.on(n,i,r)}),S(nr,function(n,i){r._messageCenter.on(i,function(a){this.trigger(i,a)},r)}),S(["selectchanged"],function(n){r._messageCenter.on(n,function(i){this.trigger(n,i)},r)}),Gv(this._messageCenter,this,this._api)},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var r=this.getDom();r&&fs(this.getDom(),ji,"");var n=this,i=n._api,a=n._model;S(n._componentsViews,function(o){o.dispose(a,i)}),S(n._chartsViews,function(o){o.dispose(a,i)}),n._zr.dispose(),n._dom=n._model=n._chartsMap=n._componentsMap=n._chartsViews=n._componentsViews=n._scheduler=n._api=n._zr=n._throttledZrFlush=n._theme=n._coordSysMgr=n._messageCenter=null,delete ir[n.id]},e.prototype.resize=function(r){if(!this[oe]){if(this._disposed){this.id;return}this._zr.resize(r);var n=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!n){var i=n.resetOption("media"),a=r&&r.silent;this[ge]&&(a==null&&(a=this[ge].silent),i=!0,this[ge]=null),this[oe]=!0;try{i&&Mt(this),je.update.call(this,{type:"resize",animation:R({duration:0},r&&r.animation)})}catch(o){throw this[oe]=!1,o}this[oe]=!1,Ut.call(this,a),Gt.call(this,a)}}},e.prototype.showLoading=function(r,n){if(this._disposed){this.id;return}if(B(r)&&(n=r,r=""),r=r||"default",this.hideLoading(),!!wi[r]){var i=wi[r](this._api,n),a=this._zr;this._loadingFX=i,a.add(i)}},e.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},e.prototype.makeActionFromEvent=function(r){var n=R({},r);return n.type=nr[r.type],n},e.prototype.dispatchAction=function(r,n){if(this._disposed){this.id;return}if(B(n)||(n={silent:!!n}),!!an[r.type]&&!!this._model){if(this[oe]){this._pendingActions.push(r);return}var i=n.silent;Gn.call(this,r,i);var a=n.flush;a?this._zr.flush():a!==!1&&Z.browser.weChat&&this._throttledZrFlush(),Ut.call(this,i),Gt.call(this,i)}},e.prototype.updateLabelLayout=function(){Me.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(r){if(this._disposed){this.id;return}var n=r.seriesIndex,i=this.getModel(),a=i.getSeriesByIndex(n);a.appendData(r),this._scheduler.unfinished=!0,this.getZr().wakeUp()},e.internalField=function(){Mt=function(u){var v=u._scheduler;v.restorePipelines(u._model),v.prepareStageTasks(),zn(u,!0),zn(u,!1),v.plan()},zn=function(u,v){for(var h=u._model,d=u._scheduler,p=v?u._componentsViews:u._chartsViews,g=v?u._componentsMap:u._chartsMap,m=u._zr,y=u._api,_=0;_v.get("hoverLayerThreshold")&&!Z.node&&!Z.worker&&v.eachSeries(function(g){if(!g.preventUsingHoverLayer){var m=u._chartsMap[g.__viewId];m.__alive&&m.eachRendered(function(y){y.states.emphasis&&(y.states.emphasis.hoverLayer=!0)})}})}function o(u,v){var h=u.get("blendMode")||null;v.eachRendered(function(d){d.isGroup||(d.style.blend=h)})}function s(u,v){if(!u.preventAutoZ){var h=u.get("z")||0,d=u.get("zlevel")||0;v.eachRendered(function(p){return l(p,h,d,-1/0),!0})}}function l(u,v,h,d){var p=u.getTextContent(),g=u.getTextGuideLine(),m=u.isGroup;if(m)for(var y=u.childrenRef(),_=0;_0?{duration:p,delay:h.get("delay"),easing:h.get("easing")}:null;v.eachRendered(function(m){if(m.states&&m.states.emphasis){if(tr(m))return;if(m instanceof We&&Zf(m),m.__dirty){var y=m.prevStates;y&&m.useStates(y)}if(d){m.stateTransition=g;var _=m.getTextContent(),w=m.getTextGuideLine();_&&(_.stateTransition=g),w&&(w.stateTransition=g)}m.__dirty&&i(m)}})}_o=function(u){return new(function(v){fe(h,v);function h(){return v!==null&&v.apply(this,arguments)||this}return h.prototype.getCoordinateSystems=function(){return u._coordSysMgr.getCoordinateSystems()},h.prototype.getComponentByElement=function(d){for(;d;){var p=d.__ecComponentInfo;if(p!=null)return u._model.getComponent(p.mainType,p.index);d=d.parent}},h.prototype.enterEmphasis=function(d,p){ni(d,p),xe(u)},h.prototype.leaveEmphasis=function(d,p){ii(d,p),xe(u)},h.prototype.enterBlur=function(d){Nf(d),xe(u)},h.prototype.leaveBlur=function(d){ys(d),xe(u)},h.prototype.enterSelect=function(d){_s(d),xe(u)},h.prototype.leaveSelect=function(d){Ss(d),xe(u)},h.prototype.getModel=function(){return u.getModel()},h.prototype.getViewOfComponentModel=function(d){return u.getViewOfComponentModel(d)},h.prototype.getViewOfSeriesModel=function(d){return u.getViewOfSeriesModel(d)},h}(qs))(u)},Fl=function(u){function v(h,d){for(var p=0;p=0)){To.push(r);var a=Cl.wrapStageHandler(r,i);a.__prio=e,a.__raw=r,t.push(a)}}function Wl(t,e){wi[t]=e}function bd(t,e,r){var n=id("registerMap");n&&n(t,e,r)}var Md=Yh;yt(Zi,wv);yt(wn,Tv);yt(wn,xv);yt(Zi,Vv);yt(wn,Fv);yt(El,td);Gl(Js);Yl(sd,bh);Wl("default",Cv);kt({type:vt,event:vt,update:vt},it);kt({type:Br,event:Br,update:Br},it);kt({type:Jt,event:Jt,update:Jt},it);kt({type:Vr,event:Vr,update:Vr},it);kt({type:er,event:er,update:er},it);Ul("light",Ov);Ul("dark",Nv);function Yt(t){return t==null?0:t.length||1}function xo(t){return t}var Ad=function(){function t(e,r,n,i,a,o){this._old=e,this._new=r,this._oldKeyGetter=n||xo,this._newKeyGetter=i||xo,this.context=a,this._diffModeMultiple=o==="multiple"}return t.prototype.add=function(e){return this._add=e,this},t.prototype.update=function(e){return this._update=e,this},t.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},t.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},t.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},t.prototype.remove=function(e){return this._remove=e,this},t.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},t.prototype._executeOneToOne=function(){var e=this._old,r=this._new,n={},i=new Array(e.length),a=new Array(r.length);this._initIndexMap(e,null,i,"_oldKeyGetter"),this._initIndexMap(r,n,a,"_newKeyGetter");for(var o=0;o1){var c=l.shift();l.length===1&&(n[s]=l[0]),this._update&&this._update(c,o)}else f===1?(n[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(a,n)},t.prototype._executeMultiple=function(){var e=this._old,r=this._new,n={},i={},a=[],o=[];this._initIndexMap(e,n,a,"_oldKeyGetter"),this._initIndexMap(r,i,o,"_newKeyGetter");for(var s=0;s1&&v===1)this._updateManyToOne&&this._updateManyToOne(c,f),i[l]=null;else if(u===1&&v>1)this._updateOneToMany&&this._updateOneToMany(c,f),i[l]=null;else if(u===1&&v===1)this._update&&this._update(c,f),i[l]=null;else if(u>1&&v>1)this._updateManyToMany&&this._updateManyToMany(c,f),i[l]=null;else if(u>1)for(var h=0;h1)for(var s=0;s30}var Wt=B,Qe=H,Bd=typeof Int32Array=="undefined"?Array:Int32Array,Vd="e\0\0",Co=-1,Fd=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],zd=["_approximateExtent"],Do,kr,$t,Xt,$n,Kt,Xn,Hd=function(){function t(e,r){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var n,i=!1;Nd(e)?(n=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(i=!0,n=e),n=n||["x","y"];for(var a={},o=[],s={},l=!1,f={},c=0;c=r)){var n=this._store,i=n.getProvider();this._updateOrdinalMeta();var a=this._nameList,o=this._idList,s=i.getSource().sourceFormat,l=s===Oe;if(l&&!i.pure)for(var f=[],c=e;c0},t.prototype.ensureUniqueItemVisual=function(e,r){var n=this._itemVisuals,i=n[e];i||(i=n[e]={});var a=i[r];return a==null&&(a=this.getVisual(r),E(a)?a=a.slice():Wt(a)&&(a=R({},a)),i[r]=a),a},t.prototype.setItemVisual=function(e,r,n){var i=this._itemVisuals[e]||{};this._itemVisuals[e]=i,Wt(r)?R(i,r):i[r]=n},t.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},t.prototype.setLayout=function(e,r){Wt(e)?R(this._layout,e):this._layout[e]=r},t.prototype.getLayout=function(e){return this._layout[e]},t.prototype.getItemLayout=function(e){return this._itemLayouts[e]},t.prototype.setItemLayout=function(e,r,n){this._itemLayouts[e]=n?R(this._itemLayouts[e]||{},r):r},t.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},t.prototype.setItemGraphicEl=function(e,r){var n=this.hostModel&&this.hostModel.seriesIndex;bf(n,this.dataType,e,r),this._graphicEls[e]=r},t.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},t.prototype.eachItemGraphicEl=function(e,r){S(this._graphicEls,function(n,i){n&&e&&e.call(r,n,i)})},t.prototype.cloneShallow=function(e){return e||(e=new t(this._schema?this._schema:Qe(this.dimensions,this._getDimInfo,this),this.hostModel)),$n(e,this),e._store=this._store,e},t.prototype.wrapMethod=function(e,r){var n=this[e];!W(n)||(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var i=n.apply(this,arguments);return r.apply(this,[i].concat(ku(arguments)))})},t.internalField=function(){Do=function(e){var r=e._invertedIndicesMap;S(r,function(n,i){var a=e._dimInfos[i],o=a.ordinalMeta,s=e._store;if(o){n=r[i]=new Bd(o.categories.length);for(var l=0;l1&&(l+="__ec__"+c),i[r]=l}}}(),t}(),Ud=Hd;function Gd(t,e){Yi(t)||(t=el(t)),e=e||{};var r=e.coordDimensions||[],n=e.dimensionsDefine||t.dimensionsDefine||[],i=V(),a=[],o=Wd(t,r,n,e.dimensionsCount),s=e.canOmitUnusedDimensions&&Zl(o),l=n===t.dimensionsDefine,f=l?Kl(t):Xl(n),c=e.encodeDefine;!c&&e.encodeDefaulter&&(c=e.encodeDefaulter(t,o));for(var u=V(c),v=new ll(o),h=0;h0&&(n.name=i+(a-1)),a++,e.set(i,a)}}function Wd(t,e,r,n){var i=Math.max(t.dimensionsDetectedCount||1,e.length,r.length,n||0);return S(e,function(a){var o;B(a)&&(o=a.dimsDef)&&(i=Math.max(i,o.length))}),i}function $d(t,e,r){if(r||e.hasKey(t)){for(var n=0;e.hasKey(t+n);)n++;t+=n}return e.set(t,!0),t}function ql(t,e){return t.type==="category"?t.scale.getLabel(e):e.value}function Xd(t){var e=t.get("interval");return e==null?"auto":e}function Kd(t){return t.type==="category"&&Xd(t.getLabelModel())===0}var bo=[],Zd={registerPreprocessor:Gl,registerProcessor:Yl,registerPostInit:Td,registerPostUpdate:xd,registerUpdateLifecycle:Qi,registerAction:kt,registerCoordinateSystem:Cd,registerLayout:Dd,registerVisual:yt,registerTransform:Md,registerLoading:Wl,registerMap:bd,registerImpl:nd,PRIORITY:gd,ComponentModel:ee,ComponentView:Lt,SeriesModel:pr,ChartView:It,registerComponentModel:function(t){ee.registerClass(t)},registerComponentView:function(t){Lt.registerClass(t)},registerSeriesModel:function(t){pr.registerClass(t)},registerChartView:function(t){It.registerClass(t)},registerSubTypeDefaulter:function(t,e){ee.registerSubTypeDefaulter(t,e)},registerPainter:function(t,e){Ou(t,e)}};function jl(t){if(E(t)){S(t,function(e){jl(e)});return}_e(bo,t)>=0||(bo.push(t),W(t)&&(t={install:t}),t.install(Zd))}function Ql(t,e,r,n,i,a,o,s){var l=i-t,f=a-e,c=r-t,u=n-e,v=Math.sqrt(c*c+u*u);c/=v,u/=v;var h=l*c+f*u,d=h/v;s&&(d=Math.min(Math.max(d,0),1)),d*=v;var p=o[0]=t+d*c,g=o[1]=e+d*u;return Math.sqrt((p-i)*(p-i)+(g-a)*(g-a))}var et=new ne,K=new ne,ae=new ne,tt=new ne,Pe=new ne,sn=[],ce=new ne;function qd(t,e){if(e<=180&&e>0){e=e/180*Math.PI,et.fromArray(t[0]),K.fromArray(t[1]),ae.fromArray(t[2]),ne.sub(tt,et,K),ne.sub(Pe,ae,K);var r=tt.len(),n=Pe.len();if(!(r<.001||n<.001)){tt.scale(1/r),Pe.scale(1/n);var i=tt.dot(Pe),a=Math.cos(e);if(a1&&ne.copy(ce,ae),ce.toArray(t[1])}}}}function jd(t,e,r){if(r<=180&&r>0){r=r/180*Math.PI,et.fromArray(t[0]),K.fromArray(t[1]),ae.fromArray(t[2]),ne.sub(tt,K,et),ne.sub(Pe,ae,K);var n=tt.len(),i=Pe.len();if(!(n<.001||i<.001)){tt.scale(1/n),Pe.scale(1/i);var a=tt.dot(e),o=Math.cos(r);if(a=l)ne.copy(ce,ae);else{ce.scaleAndAdd(Pe,s/Math.tan(Math.PI/2-c));var u=ae.x!==K.x?(ce.x-K.x)/(ae.x-K.x):(ce.y-K.y)/(ae.y-K.y);if(isNaN(u))return;u<0?ne.copy(ce,K):u>1&&ne.copy(ce,ae)}ce.toArray(t[1])}}}}function Kn(t,e,r,n){var i=r==="normal",a=i?t:t.ensureState(r);a.ignore=e;var o=n.get("smooth");o&&o===!0&&(o=.3),a.shape=a.shape||{},o>0&&(a.shape.smooth=o);var s=n.getModel("lineStyle").getLineStyle();i?t.useStyle(s):a.style=s}function Qd(t,e){var r=e.smooth,n=e.points;if(!!n)if(t.moveTo(n[0][0],n[0][1]),r>0&&n.length>=3){var i=aa(n[0],n[1]),a=aa(n[1],n[2]);if(!i||!a){t.lineTo(n[1][0],n[1][1]),t.lineTo(n[2][0],n[2][1]);return}var o=Math.min(i,a)*r,s=Cn([],n[1],n[0],o/i),l=Cn([],n[1],n[2],o/a),f=Cn([],s,l,.5);t.bezierCurveTo(s[0],s[1],s[0],s[1],f[0],f[1]),t.bezierCurveTo(l[0],l[1],l[0],l[1],n[2][0],n[2][1])}else for(var c=1;c0&&a&&x(-c/o,0,o);var p=t[0],g=t[o-1],m,y;_(),m<0&&T(-m,.8),y<0&&T(y,.8),_(),w(m,y,1),w(y,m,-1),_(),m<0&&b(-m),y<0&&b(y);function _(){m=p.rect[e]-n,y=i-g.rect[e]-g.rect[r]}function w(D,C,A){if(D<0){var M=Math.min(C,-D);if(M>0){x(M*A,0,o);var I=M+D;I<0&&T(-I*A,1)}else T(-D*A,1)}}function x(D,C,A){D!==0&&(f=!0);for(var M=C;M0)for(var I=0;I0;I--){var F=A[I-1]*k;x(-F,I,o)}}}function b(D){var C=D<0?-1:1;D=Math.abs(D);for(var A=Math.ceil(D/(o-1)),M=0;M0?x(A,0,M+1):x(-A,o-M-1,o),D-=A,D<=0)return}return f}function np(t,e,r,n){return rp(t,"y","height",e,r,n)}function ip(t){var e=[];t.sort(function(p,g){return g.priority-p.priority});var r=new or(0,0,0,0);function n(p){if(!p.ignore){var g=p.ensureState("emphasis");g.ignore==null&&(g.ignore=!1)}p.ignore=!0}for(var i=0;iN?(q=k+D*N/2,X=q):(q=k+A,X=U-A),i.setItemLayout($,{angle:N,startAngle:q,endAngle:X,clockwise:w,cx:l,cy:f,r0:u,r:x?Xu(J,b,[u,c]):c}),k=U}),Pr?m:g,x=Math.abs(_.label.y-r);if(x>=w.maxY){var T=_.label.x-e-_.len2*i,b=n+_.len,D=Math.abs(T)t.unconstrainedWidth?null:h:null;n.setStyle("width",d)}var p=n.getBoundingRect();a.width=p.width;var g=(n.style.margin||0)+2.1;a.height=p.height+g,a.y-=(a.height-u)/2}}}function Zn(t){return t.position==="center"}function up(t){var e=t.getData(),r=[],n,i,a=!1,o=(t.get("minShowLabelAngle")||0)*sp,s=e.getLayout("viewRect"),l=e.getLayout("r"),f=s.width,c=s.x,u=s.y,v=s.height;function h(T){T.ignore=!0}function d(T){if(!T.ignore)return!0;for(var b in T.states)if(T.states[b].ignore===!1)return!0;return!1}e.each(function(T){var b=e.getItemGraphicEl(T),D=b.shape,C=b.getTextContent(),A=b.getTextGuideLine(),M=e.getItemModel(T),I=M.getModel("label"),P=I.get("position")||M.get(["emphasis","label","position"]),L=I.get("distanceToLabelLine"),k=I.get("alignTo"),F=te(I.get("edgeDistance"),f),J=I.get("bleedMargin"),$=M.getModel("labelLine"),N=$.get("length");N=te(N,f);var U=$.get("length2");if(U=te(U,f),Math.abs(D.endAngle-D.startAngle)0?"right":"left":X>0?"left":"right"}var Ke=Math.PI,Ve=0,Bt=I.get("rotate");if(ue(Bt))Ve=Bt*(Ke/180);else if(P==="center")Ve=0;else if(Bt==="radial"||Bt===!0){var vu=X<0?-q+Ke:-q;Ve=vu}else if(Bt==="tangential"&&P!=="outside"&&P!=="outer"){var wt=Math.atan2(X,Be);wt<0&&(wt=Ke*2+wt);var du=Be>0;du&&(wt=Ke+wt),Ve=wt-Ke}if(a=!!Ve,C.x=ot,C.y=_t,C.rotation=Ve,C.setStyle({verticalAlign:"middle"}),Xe){C.setStyle({align:St});var Tn=C.states.select;Tn&&(Tn.x+=C.x,Tn.y+=C.y)}else{var Vt=C.getBoundingRect().clone();Vt.applyTransform(C.getComputedTransform());var ra=(C.style.margin||0)+2.1;Vt.y-=ra/2,Vt.height+=ra,r.push({label:C,labelLine:A,position:P,len:N,len2:U,minTurnAngle:$.get("minTurnAngle"),maxSurfaceAngle:$.get("maxSurfaceAngle"),surfaceNormal:new ne(X,Be),linePoints:Tr,textAlign:St,labelDistance:L,labelAlignTo:k,edgeDistance:F,bleedMargin:J,rect:Vt,unconstrainedWidth:Vt.width,labelStyleWidth:C.style.width})}b.setTextConfig({inside:Xe})}}),!a&&t.get("avoidLabelOverlap")&&lp(r,n,i,l,f,v,c,u);for(var p=0;p0){for(var c=o.getItemLayout(0),u=1;isNaN(c&&c.startAngle)&&u=a.r0}},e.type="pie",e}(It),hp=cp;function vp(t,e,r){e=E(e)&&{coordDimensions:e}||R({encodeDefine:t.getEncode()},e);var n=t.getSource(),i=Gd(n,e).dimensions,a=new Ud(i,t);return a.initData(n,r),a}var dp=function(){function t(e,r){this._getDataWithEncodedVisual=e,this._getRawData=r}return t.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},t.prototype.containName=function(e){var r=this._getRawData();return r.indexOfName(e)>=0},t.prototype.indexOfName=function(e){var r=this._getDataWithEncodedVisual();return r.indexOfName(e)},t.prototype.getItemVisual=function(e,r){var n=this._getDataWithEncodedVisual();return n.getItemVisual(e,r)},t}(),pp=dp,gp=re(),mp=function(t){fe(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.init=function(r){t.prototype.init.apply(this,arguments),this.legendVisualProvider=new pp(Y(this.getData,this),Y(this.getRawData,this)),this._defaultLabelLine(r)},e.prototype.mergeOption=function(){t.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return vp(this,{coordDimensions:["value"],encodeDefaulter:we(Jc,this)})},e.prototype.getDataParams=function(r){var n=this.getData(),i=gp(n),a=i.seats;if(!a){var o=[];n.each(n.mapDimension("value"),function(l){o.push(l)}),a=i.seats=qu(o,n.hostModel.get("percentPrecision"))}var s=t.prototype.getDataParams.call(this,r);return s.percent=a[r]||0,s.$vars.push("percent"),s},e.prototype._defaultLabelLine=function(r){ri(r,"labelLine",["show"]);var n=r.labelLine,i=r.emphasis.labelLine;n.show=n.show&&r.label.show,i.show=i.show&&r.emphasis.label.show},e.type="series.pie",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e}(pr),yp=mp;function _p(t){return{seriesType:t,reset:function(e,r){var n=e.getData();n.filterSelf(function(i){var a=n.mapDimension("value"),o=n.get(a,i);return!(ue(o)&&!isNaN(o)&&o<0)})}}}function Og(t){t.registerChartView(hp),t.registerSeriesModel(yp),Uv("pie",t.registerAction),t.registerLayout(we(ap,"pie")),t.registerProcessor(op("pie")),t.registerProcessor(_p("pie"))}function Io(t,e,r){r=r||{};var n=t.coordinateSystem,i=e.axis,a={},o=i.getAxesOnZeroOf()[0],s=i.position,l=o?"onZero":s,f=i.dim,c=n.getRect(),u=[c.x,c.x+c.width,c.y,c.y+c.height],v={left:0,right:1,top:0,bottom:1,onZero:2},h=e.get("offset")||0,d=f==="x"?[u[2]-h,u[3]+h]:[u[0]-h,u[1]+h];if(o){var p=o.toGlobalCoord(o.dataToCoord(0));d[v.onZero]=Math.max(Math.min(p,d[1]),d[0])}a.position=[f==="y"?d[v[l]]:u[0],f==="x"?d[v[l]]:u[3]],a.rotation=Math.PI/2*(f==="x"?0:1);var g={top:-1,bottom:1,left:-1,right:1};a.labelDirection=a.tickDirection=a.nameDirection=g[s],a.labelOffset=o?d[v[s]]-d[v.onZero]:0,e.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),sr(r.labelInside,e.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var m=e.get(["axisLabel","rotate"]);return a.labelRotate=l==="top"?-m:m,a.z2=1,a}var rt=Math.PI,dt=function(){function t(e,r){this.group=new pt,this.opt=r,this.axisModel=e,pe(r,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var n=new pt({x:r.position[0],y:r.position[1],rotation:r.rotation});n.updateTransform(),this._transformGroup=n}return t.prototype.hasBuilder=function(e){return!!Po[e]},t.prototype.add=function(e){Po[e](this.opt,this.axisModel,this.group,this._transformGroup)},t.prototype.getGroup=function(){return this.group},t.innerTextLayout=function(e,r,n){var i=is(r-e),a,o;return Xr(i)?(o=n>0?"top":"bottom",a="center"):Xr(i-rt)?(o=n>0?"bottom":"top",a="center"):(o="middle",i>0&&i0?"right":"left":a=n>0?"left":"right"),{rotation:i,textAlign:a,textVerticalAlign:o}},t.makeAxisEventDataBase=function(e){var r={componentType:e.mainType,componentIndex:e.componentIndex};return r[e.mainType+"Index"]=e.componentIndex,r},t.isLabelSilent=function(e){var r=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||r&&r.show)},t}(),Po={axisLine:function(t,e,r,n){var i=e.get(["axisLine","show"]);if(i==="auto"&&t.handleAutoShown&&(i=t.handleAutoShown("axisLine")),!!i){var a=e.axis.getExtent(),o=n.transform,s=[a[0],0],l=[a[1],0],f=s[0]>l[0];o&&(ar(s,s,o),ar(l,l,o));var c=R({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),u=new yr({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:c,strokeContainThreshold:t.strokeContainThreshold||5,silent:!0,z2:1});Bi(u.shape,u.style.lineWidth),u.anid="line",r.add(u);var v=e.get(["axisLine","symbol"]);if(v!=null){var h=e.get(["axisLine","symbolSize"]);O(v)&&(v=[v,v]),(O(h)||ue(h))&&(h=[h,h]);var d=Qv(e.get(["axisLine","symbolOffset"])||0,h),p=h[0],g=h[1];S([{rotate:t.rotation+Math.PI/2,offset:d[0],r:0},{rotate:t.rotation-Math.PI/2,offset:d[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],function(m,y){if(v[y]!=="none"&&v[y]!=null){var _=bl(v[y],-p/2,-g/2,p,g,c.stroke,!0),w=m.r+m.offset,x=f?l:s;_.attr({rotation:m.rotate,x:x[0]+w*Math.cos(t.rotation),y:x[1]-w*Math.sin(t.rotation),silent:!0,z2:11}),r.add(_)}})}}},axisTickLabel:function(t,e,r,n){var i=Tp(r,n,e,t),a=Cp(r,n,e,t);if(wp(e,a,i),xp(r,n,e,t.tickDirection),e.get(["axisLabel","hideOverlap"])){var o=tp(H(a,function(s){return{label:s,priority:s.z2,defaultAttr:{ignore:s.ignore}}}));ip(o)}},axisName:function(t,e,r,n){var i=sr(t.axisName,e.get("name"));if(!!i){var a=e.get("nameLocation"),o=t.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,f=e.axis.getExtent(),c=f[0]>f[1]?-1:1,u=[a==="start"?f[0]-c*l:a==="end"?f[1]+c*l:(f[0]+f[1])/2,Ro(a)?t.labelOffset+o*l:0],v,h=e.get("nameRotate");h!=null&&(h=h*rt/180);var d;Ro(a)?v=dt.innerTextLayout(t.rotation,h!=null?h:t.rotation,o):(v=Sp(t.rotation,a,h||0,f),d=t.axisNameAvailableWidth,d!=null&&(d=Math.abs(d/Math.sin(v.rotation)),!isFinite(d)&&(d=null)));var p=s.getFont(),g=e.get("nameTruncate",!0)||{},m=g.ellipsis,y=sr(t.nameTruncateMaxWidth,g.maxWidth,d),_=new Ee({x:u[0],y:u[1],rotation:v.rotation,silent:dt.isLabelSilent(e),style:cr(s,{text:i,font:p,overflow:"truncate",width:y,ellipsis:m,fill:s.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:s.get("align")||v.textAlign,verticalAlign:s.get("verticalAlign")||v.textVerticalAlign}),z2:1});if(Fi({el:_,componentModel:e,itemName:i}),_.__fullText=i,_.anid="name",e.get("triggerEvent")){var w=dt.makeAxisEventDataBase(e);w.targetType="axisName",w.name=i,Q(_).eventData=w}n.add(_),_.updateTransform(),r.add(_),_.decomposeTransform()}}};function Sp(t,e,r,n){var i=is(r-t),a,o,s=n[0]>n[1],l=e==="start"&&!s||e!=="start"&&s;return Xr(i-rt/2)?(o=l?"bottom":"top",a="center"):Xr(i-rt*1.5)?(o=l?"top":"bottom",a="center"):(o="middle",irt/2?a=l?"left":"right":a=l?"right":"left"),{rotation:i,textAlign:a,textVerticalAlign:o}}function wp(t,e,r){if(!Kd(t.axis)){var n=t.get(["axisLabel","showMinLabel"]),i=t.get(["axisLabel","showMaxLabel"]);e=e||[],r=r||[];var a=e[0],o=e[1],s=e[e.length-1],l=e[e.length-2],f=r[0],c=r[1],u=r[r.length-1],v=r[r.length-2];n===!1?(Ce(a),Ce(f)):Lo(a,o)&&(n?(Ce(o),Ce(c)):(Ce(a),Ce(f))),i===!1?(Ce(s),Ce(u)):Lo(l,s)&&(i?(Ce(l),Ce(v)):(Ce(s),Ce(u)))}}function Ce(t){t&&(t.ignore=!0)}function Lo(t,e){var r=t&&t.getBoundingRect().clone(),n=e&&e.getBoundingRect().clone();if(!(!r||!n)){var i=qo([]);return rs(i,i,-t.rotation),r.applyTransform(ei([],i,t.getLocalTransform())),n.applyTransform(ei([],i,e.getLocalTransform())),r.intersect(n)}}function Ro(t){return t==="middle"||t==="center"}function nu(t,e,r,n,i){for(var a=[],o=[],s=[],l=0;l=0||t===e}function Lp(t){var e=ea(t);if(!!e){var r=e.axisPointerModel,n=e.axis.scale,i=r.option,a=r.get("status"),o=r.get("value");o!=null&&(o=n.parse(o));var s=Ti(r);a==null&&(i.status=s?"show":"hide");var l=n.getExtent().slice();l[0]>l[1]&&l.reverse(),(o==null||o>l[1])&&(o=l[1]),os)return!0;if(o){var l=ea(e).seriesDataCount,f=i.getExtent();return Math.abs(f[0]-f[1])/l>s}return!1}return n===!0},t.prototype.makeElOption=function(e,r,n,i,a){},t.prototype.createPointerEl=function(e,r,n,i){var a=r.pointer;if(a){var o=ht(e).pointerEl=new dc[a.type](ko(r.pointer));e.add(o)}},t.prototype.createLabelEl=function(e,r,n,i){if(r.label){var a=ht(e).labelEl=new Ee(ko(r.label));e.add(a),No(a,i)}},t.prototype.updatePointerEl=function(e,r,n){var i=ht(e).pointerEl;i&&r.pointer&&(i.setStyle(r.pointer.style),n(i,{shape:r.pointer.shape}))},t.prototype.updateLabelEl=function(e,r,n,i){var a=ht(e).labelEl;a&&(a.setStyle(r.label.style),n(a,{x:r.label.x,y:r.label.y}),No(a,i))},t.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var r=this._axisPointerModel,n=this._api.getZr(),i=this._handle,a=r.getModel("handle"),o=r.get("status");if(!a.get("show")||!o||o==="hide"){i&&n.remove(i),this._handle=null;return}var s;this._handle||(s=!0,i=this._handle=Is(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(f){zu(f.event)},onmousedown:jn(this._onHandleDragMove,this,0,0),drift:jn(this._onHandleDragMove,this),ondragend:jn(this._onHandleDragEnd,this)}),n.add(i)),Bo(i,r,!1),i.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=a.get("size");E(l)||(l=[l,l]),i.scaleX=l[0]/2,i.scaleY=l[1]/2,yl(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},t.prototype._moveHandleToValue=function(e,r){Oo(this._axisPointerModel,!r&&this._moveAnimation,this._handle,Qn(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},t.prototype._onHandleDragMove=function(e,r){var n=this._handle;if(!!n){this._dragging=!0;var i=this.updateHandleTransform(Qn(n),[e,r],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(Qn(i)),ht(n).lastProp=null,this._doDispatchAxisPointer()}},t.prototype._doDispatchAxisPointer=function(){var e=this._handle;if(!!e){var r=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:r.cursorPoint[0],y:r.cursorPoint[1],tooltipOption:r.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},t.prototype._onHandleDragEnd=function(){this._dragging=!1;var e=this._handle;if(!!e){var r=this._axisPointerModel.get("value");this._moveHandleToValue(r),this._api.dispatchAction({type:"hideTip"})}},t.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var r=e.getZr(),n=this._group,i=this._handle;r&&n&&(this._lastGraphicKey=null,n&&r.remove(n),i&&r.remove(i),this._group=null,this._handle=null,this._payloadInfo=null),gi(this,"_doDispatchAxisPointer")},t.prototype.doClear=function(){},t.prototype.buildLabel=function(e,r,n){return n=n||0,{x:e[n],y:e[1-n],width:r[n],height:r[1-n]}},t}();function Oo(t,e,r,n){iu(ht(r).lastProp,n)||(ht(r).lastProp=n,e?fr(r,n,t):(r.stopAnimation(),r.attr(n)))}function iu(t,e){if(B(t)&&B(e)){var r=!0;return S(e,function(n,i){r=r&&iu(t[i],n)}),!!r}else return t===e}function No(t,e){t[e.get(["label","show"])?"show":"hide"]()}function Qn(t){return{x:t.x||0,y:t.y||0,rotation:t.rotation||0}}function Bo(t,e,r){var n=e.get("z"),i=e.get("zlevel");t&&t.traverse(function(a){a.type!=="group"&&(n!=null&&(a.z=n),i!=null&&(a.zlevel=i),a.silent=r)})}var Np=Op;function Bp(t){var e=t.get("type"),r=t.getModel(e+"Style"),n;return e==="line"?(n=r.getLineStyle(),n.fill=null):e==="shadow"&&(n=r.getAreaStyle(),n.stroke=null),n}function Vp(t,e,r,n,i){var a=r.get("value"),o=au(a,e.axis,e.ecModel,r.get("seriesDataIndices"),{precision:r.get(["label","precision"]),formatter:r.get(["label","formatter"])}),s=r.getModel("label"),l=Ui(s.get("padding")||0),f=s.getFont(),c=Uu(o,f),u=i.position,v=c.width+l[1]+l[3],h=c.height+l[0]+l[2],d=i.align;d==="right"&&(u[0]-=v),d==="center"&&(u[0]-=v/2);var p=i.verticalAlign;p==="bottom"&&(u[1]-=h),p==="middle"&&(u[1]-=h/2),Fp(u,v,h,n);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=e.get(["axisLine","lineStyle","color"])),t.label={x:u[0],y:u[1],style:cr(s,{text:o,font:f,fill:s.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function Fp(t,e,r,n){var i=n.getWidth(),a=n.getHeight();t[0]=Math.min(t[0]+e,i)-e,t[1]=Math.min(t[1]+r,a)-r,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}function au(t,e,r,n,i){t=e.scale.parse(t);var a=e.scale.getLabel({value:t},{precision:i.precision}),o=i.formatter;if(o){var s={value:ql(e,{value:t}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};S(n,function(l){var f=r.getSeriesByIndex(l.seriesIndex),c=l.dataIndexInside,u=f&&f.getDataParams(c);u&&s.seriesData.push(u)}),O(o)?a=o.replace("{value}",a):W(o)&&(a=o(s))}return a}function ou(t,e,r){var n=Gu();return rs(n,n,r.rotation),Hu(n,n,r.position),Vi([t.dataToCoord(e),(r.labelOffset||0)+(r.labelDirection||1)*(r.labelMargin||0)],n)}function zp(t,e,r,n,i,a){var o=Dp.innerTextLayout(r.rotation,0,r.labelDirection);r.labelMargin=i.get(["label","margin"]),Vp(e,n,i,a,{position:ou(n.axis,t,r),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function Hp(t,e,r){return r=r||0,{x1:t[r],y1:t[1-r],x2:e[r],y2:e[1-r]}}function Up(t,e,r){return r=r||0,{x:t[r],y:t[1-r],width:e[r],height:e[1-r]}}var Gp=function(t){fe(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.makeElOption=function(r,n,i,a,o){var s=i.axis,l=s.grid,f=a.get("type"),c=Vo(l,s).getOtherAxis(s).getGlobalExtent(),u=s.toGlobalCoord(s.dataToCoord(n,!0));if(f&&f!=="none"){var v=Bp(a),h=Yp[f](s,u,c);h.style=v,r.graphicKey=h.type,r.pointer=h}var d=Io(l.model,i);zp(n,r,d,i,a,o)},e.prototype.getHandleTransform=function(r,n,i){var a=Io(n.axis.grid.model,n,{labelInside:!1});a.labelMargin=i.get(["handle","margin"]);var o=ou(n.axis,r,a);return{x:o[0],y:o[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(r,n,i,a){var o=i.axis,s=o.grid,l=o.getGlobalExtent(!0),f=Vo(s,o).getOtherAxis(o).getGlobalExtent(),c=o.dim==="x"?0:1,u=[r.x,r.y];u[c]+=n[c],u[c]=Math.min(l[1],u[c]),u[c]=Math.max(l[0],u[c]);var v=(f[1]+f[0])/2,h=[v,v];h[c]=u[c];var d=[{verticalAlign:"middle"},{align:"center"}];return{x:u[0],y:u[1],rotation:r.rotation,cursorPoint:h,tooltipOption:d[c]}},e}(Np);function Vo(t,e){var r={};return r[e.dim+"AxisIndex"]=e.index,t.getCartesian(r)}var Yp={line:function(t,e,r){var n=Hp([e,r[0]],[e,r[1]],Fo(t));return{type:"Line",subPixelOptimize:!0,shape:n}},shadow:function(t,e,r){var n=Math.max(1,t.getBandWidth()),i=r[1]-r[0];return{type:"Rect",shape:Up([e-n/2,r[0]],[n,i],Fo(t))}}};function Fo(t){return t.dim==="x"?0:1}var Wp=Gp,$p=function(t){fe(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.type=e.type,r}return e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},e}(ee),Xp=$p,He=re(),Kp=S;function su(t,e,r){if(!Z.node){var n=e.getZr();He(n).records||(He(n).records={}),Zp(n,e);var i=He(n).records[t]||(He(n).records[t]={});i.handler=r}}function Zp(t,e){if(He(t).initialized)return;He(t).initialized=!0,r("click",we(zo,"click")),r("mousemove",we(zo,"mousemove")),r("globalout",jp);function r(n,i){t.on(n,function(a){var o=Qp(e);Kp(He(t).records,function(s){s&&i(s,a,o.dispatchAction)}),qp(o.pendings,e)})}}function qp(t,e){var r=t.showTip.length,n=t.hideTip.length,i;r?i=t.showTip[r-1]:n&&(i=t.hideTip[n-1]),i&&(i.dispatchAction=null,e.dispatchAction(i))}function jp(t,e,r){t.handler("leave",null,r)}function zo(t,e,r,n){e.handler(t,r,n)}function Qp(t){var e={showTip:[],hideTip:[]},r=function(n){var i=e[n.type];i?i.push(n):(n.dispatchAction=r,t.dispatchAction(n))};return{dispatchAction:r,pendings:e}}function xi(t,e){if(!Z.node){var r=e.getZr(),n=(He(r).records||{})[t];n&&(He(r).records[t]=null)}}var Jp=function(t){fe(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.type=e.type,r}return e.prototype.render=function(r,n,i){var a=n.getComponent("tooltip"),o=r.get("triggerOn")||a&&a.get("triggerOn")||"mousemove|click";su("axisPointer",i,function(s,l,f){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&f({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(r,n){xi("axisPointer",n)},e.prototype.dispose=function(r,n){xi("axisPointer",n)},e.type="axisPointer",e}(Lt),eg=Jp;function lu(t,e){var r=[],n=t.seriesIndex,i;if(n==null||!(i=e.getSeriesByIndex(n)))return{point:[]};var a=i.getData(),o=Sr(a,t);if(o==null||o<0||E(o))return{point:[]};var s=a.getItemGraphicEl(o),l=i.coordinateSystem;if(i.getTooltipPosition)r=i.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(t.isStacked){var f=l.getBaseAxis(),c=l.getOtherAxis(f),u=c.dim,v=f.dim,h=u==="x"||u==="radius"?1:0,d=a.mapDimension(v),p=[];p[h]=a.get(d,o),p[1-h]=a.get(a.getCalculationInfo("stackResultDimension"),o),r=l.dataToPoint(p)||[]}else r=l.dataToPoint(a.getValues(H(l.dimensions,function(m){return a.mapDimension(m)}),o))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),r=[g.x+g.width/2,g.y+g.height/2]}return{point:r,el:s}}var Ho=re();function tg(t,e,r){var n=t.currTrigger,i=[t.x,t.y],a=t,o=t.dispatchAction||Y(r.dispatchAction,r),s=e.getComponent("axisPointer").coordSysAxesInfo;if(!!s){Yr(i)&&(i=lu({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},e).point);var l=Yr(i),f=a.axesInfo,c=s.axesInfo,u=n==="leave"||Yr(i),v={},h={},d={list:[],map:{}},p={showPointer:we(ng,h),showTooltip:we(ig,d)};S(s.coordSysMap,function(m,y){var _=l||m.containPoint(i);S(s.coordSysAxesInfo[y],function(w,x){var T=w.axis,b=lg(f,w);if(!u&&_&&(!f||b)){var D=b&&b.value;D==null&&!l&&(D=T.pointToData(i)),D!=null&&Uo(w,D,p,!1,v)}})});var g={};return S(c,function(m,y){var _=m.linkGroup;_&&!h[y]&&S(_.axesInfo,function(w,x){var T=h[x];if(w!==m&&T){var b=T.value;_.mapper&&(b=m.axis.scale.parse(_.mapper(b,Go(w),Go(m)))),g[m.key]=b}})}),S(g,function(m,y){Uo(c[y],m,p,!0,v)}),ag(h,c,v),og(d,i,t,o),sg(c,o,r),v}}function Uo(t,e,r,n,i){var a=t.axis;if(!(a.scale.isBlank()||!a.containData(e))){if(!t.involveSeries){r.showPointer(t,e);return}var o=rg(e,t),s=o.payloadBatch,l=o.snapToValue;s[0]&&i.seriesIndex==null&&R(i,s[0]),!n&&t.snap&&a.containData(l)&&l!=null&&(e=l),r.showPointer(t,e,s),r.showTooltip(t,o,l)}}function rg(t,e){var r=e.axis,n=r.dim,i=t,a=[],o=Number.MAX_VALUE,s=-1;return S(e.seriesModels,function(l,f){var c=l.getData().mapDimensionsAll(n),u,v;if(l.getAxisTooltipData){var h=l.getAxisTooltipData(c,t,r);v=h.dataIndices,u=h.nestestValue}else{if(v=l.getData().indicesOfNearest(c[0],t,r.type==="category"?.5:null),!v.length)return;u=l.getData().get(c[0],v[0])}if(!(u==null||!isFinite(u))){var d=t-u,p=Math.abs(d);p<=o&&((p=0&&s<0)&&(o=p,s=d,i=u,a.length=0),S(v,function(g){a.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:a,snapToValue:i}}function ng(t,e,r,n){t[e.key]={value:r,payloadBatch:n}}function ig(t,e,r,n){var i=r.payloadBatch,a=e.axis,o=a.model,s=e.axisPointerModel;if(!(!e.triggerTooltip||!i.length)){var l=e.coordSys.model,f=mr(l),c=t.map[f];c||(c=t.map[f]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},t.list.push(c)),c.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:n,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:i.slice()})}}function ag(t,e,r){var n=r.axesInfo=[];S(e,function(i,a){var o=i.axisPointerModel.option,s=t[a];s?(!i.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!i.useHandle&&(o.status="hide"),o.status==="show"&&n.push({axisDim:i.axis.dim,axisIndex:i.axis.model.componentIndex,value:o.value})})}function og(t,e,r,n){if(Yr(e)||!t.list.length){n({type:"hideTip"});return}var i=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};n({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:r.tooltipOption,position:r.position,dataIndexInside:i.dataIndexInside,dataIndex:i.dataIndex,seriesIndex:i.seriesIndex,dataByCoordSys:t.list})}function sg(t,e,r){var n=r.getZr(),i="axisPointerLastHighlights",a=Ho(n)[i]||{},o=Ho(n)[i]={};S(t,function(f,c){var u=f.axisPointerModel.option;u.status==="show"&&f.triggerEmphasis&&S(u.seriesDataIndices,function(v){var h=v.seriesIndex+" | "+v.dataIndex;o[h]=v})});var s=[],l=[];S(a,function(f,c){!o[c]&&l.push(f)}),S(o,function(f,c){!a[c]&&s.push(f)}),l.length&&r.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&r.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function lg(t,e){for(var r=0;r<(t||[]).length;r++){var n=t[r];if(e.axis.dim===n.axisDim&&e.axis.model.componentIndex===n.axisIndex)return n}}function Go(t){var e=t.axis.model,r={},n=r.axisDim=t.axis.dim;return r.axisIndex=r[n+"AxisIndex"]=e.componentIndex,r.axisName=r[n+"AxisName"]=e.name,r.axisId=r[n+"AxisId"]=e.id,r}function Yr(t){return!t||t[0]==null||isNaN(t[0])||t[1]==null||isNaN(t[1])}function ug(t){kp.registerAxisPointerClass("CartesianAxisPointer",Wp),t.registerComponentModel(Xp),t.registerComponentView(eg),t.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var r=e.axisPointer.link;r&&!E(r)&&(e.axisPointer.link=[r])}}),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,function(e,r){e.getComponent("axisPointer").coordSysAxesInfo=bp(e,r)}),t.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},tg)}var fg=function(t){fe(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.type=e.type,r}return e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},e}(ee),cg=fg;function uu(t){var e=t.get("confine");return e!=null?!!e:t.get("renderMode")==="richText"}function fu(t){if(!!Z.domSupported){for(var e=document.documentElement.style,r=0,n=t.length;r-1?(s+="top:50%",l+="translateY(-50%) rotate("+(f=a==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(f=a==="top"?225:45)+"deg)");var c=f*Math.PI/180,u=o+i,v=u*Math.abs(Math.cos(c))+u*Math.abs(Math.sin(c)),h=Math.round(((v-Math.SQRT2*i)/2+Math.SQRT2*i-(v-u)/2)*100)/100;s+=";"+a+":-"+h+"px";var d=e+" solid "+i+"px;",p=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+d,"border-right:"+d,"background-color:"+n+";"];return'
'}function yg(t,e){var r="cubic-bezier(0.23,1,0.32,1)",n=" "+t/2+"s "+r,i="opacity"+n+",visibility"+n;return e||(n=" "+t+"s "+r,i+=Z.transformSupported?","+ta+n:",left"+n+",top"+n),dg+":"+i}function Yo(t,e,r){var n=t.toFixed(0)+"px",i=e.toFixed(0)+"px";if(!Z.transformSupported)return r?"top:"+i+";left:"+n+";":[["top",i],["left",n]];var a=Z.transform3dSupported,o="translate"+(a?"3d":"")+"("+n+","+i+(a?",0":"")+")";return r?"top:0;left:0;"+ta+":"+o+";":[["top",0],["left",0],[cu,o]]}function _g(t){var e=[],r=t.get("fontSize"),n=t.getTextColor();n&&e.push("color:"+n),e.push("font:"+t.getFont());var i=G(t.get("lineHeight"),Math.round(r*3/2));r&&e.push("line-height:"+i+"px");var a=t.get("textShadowColor"),o=t.get("textShadowBlur")||0,s=t.get("textShadowOffsetX")||0,l=t.get("textShadowOffsetY")||0;return a&&o&&e.push("text-shadow:"+s+"px "+l+"px "+o+"px "+a),S(["decoration","align"],function(f){var c=t.get(f);c&&e.push("text-"+f+":"+c)}),e.join(";")}function Sg(t,e,r){var n=[],i=t.get("transitionDuration"),a=t.get("backgroundColor"),o=t.get("shadowBlur"),s=t.get("shadowColor"),l=t.get("shadowOffsetX"),f=t.get("shadowOffsetY"),c=t.getModel("textStyle"),u=pl(t,"html"),v=l+"px "+f+"px "+o+"px "+s;return n.push("box-shadow:"+v),e&&i&&n.push(yg(i,r)),a&&n.push("background-color:"+a),S(["width","color","radius"],function(h){var d="border-"+h,p=Bs(d),g=t.get(p);g!=null&&n.push(d+":"+g+(h==="color"?"":"px"))}),n.push(_g(c)),u!=null&&n.push("padding:"+Ui(u).join("px ")+"px"),n.join(";")+";"}function Wo(t,e,r,n,i){var a=e&&e.painter;if(r){var o=a&&a.getViewportRoot();o&&Wu(t,o,r,n,i)}else{t[0]=n,t[1]=i;var s=a&&a.getViewportRootOffset();s&&(t[0]+=s.offsetLeft,t[1]+=s.offsetTop)}t[2]=t[0]/e.getWidth(),t[3]=t[1]/e.getHeight()}var wg=function(){function t(e,r){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,Z.wxa)return null;var n=document.createElement("div");n.domBelongToZr=!0,this.el=n;var i=this._zr=e.getZr(),a=r.appendTo,o=a&&(O(a)?document.querySelector(a):oa(a)?a:W(a)&&a(e.getDom()));Wo(this._styleCoord,i,o,e.getWidth()/2,e.getHeight()/2),(o||e.getDom()).appendChild(n),this._api=e,this._container=o;var s=this;n.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},n.onmousemove=function(l){if(l=l||window.event,!s._enterable){var f=i.handler,c=i.painter.getViewportRoot();Yu(c,l,!0),f.dispatch("mousemove",l)}},n.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return t.prototype.update=function(e){if(!this._container){var r=this._api.getDom(),n=vg(r,"position"),i=r.style;i.position!=="absolute"&&n!=="absolute"&&(i.position="relative")}var a=e.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this.el.className=e.get("className")||""},t.prototype.show=function(e,r){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,i=n.style,a=this._styleCoord;n.innerHTML?i.cssText=pg+Sg(e,!this._firstShow,this._longHide)+Yo(a[0],a[1],!0)+("border-color:"+hr(r)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):i.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},t.prototype.setContent=function(e,r,n,i,a){var o=this.el;if(e==null){o.innerHTML="";return}var s="";if(O(a)&&n.get("trigger")==="item"&&!uu(n)&&(s=mg(n,i,a)),O(e))o.innerHTML=e+s;else if(e){o.innerHTML="",E(e)||(e=[e]);for(var l=0;l=0?this._tryShow(a,o):i==="leave"&&this._hide(o))},this))},e.prototype._keepShow=function(){var r=this._tooltipModel,n=this._ecModel,i=this._api,a=r.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&a!=="none"&&a!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!i.isDisposed()&&o.manuallyShowTip(r,n,i,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(r,n,i,a){if(!(a.from===this.uid||Z.node||!i.getDom())){var o=Ko(a,i);this._ticket="";var s=a.dataByCoordSys,l=Pg(a,n,i);if(l){var f=l.el.getBoundingRect().clone();f.applyTransform(l.el.transform),this._tryShow({offsetX:f.x+f.width/2,offsetY:f.y+f.height/2,target:l.el,position:a.position,positionDefault:"bottom"},o)}else if(a.tooltip&&a.x!=null&&a.y!=null){var c=Dg;c.x=a.x,c.y=a.y,c.update(),Q(c).tooltipConfig={name:null,option:a.tooltip},this._tryShow({offsetX:a.x,offsetY:a.y,target:c},o)}else if(s)this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,dataByCoordSys:s,tooltipOption:a.tooltipOption},o);else if(a.seriesIndex!=null){if(this._manuallyAxisShowTip(r,n,i,a))return;var u=lu(a,n),v=u.point[0],h=u.point[1];v!=null&&h!=null&&this._tryShow({offsetX:v,offsetY:h,target:u.el,position:a.position,positionDefault:"bottom"},o)}else a.x!=null&&a.y!=null&&(i.dispatchAction({type:"updateAxisPointer",x:a.x,y:a.y}),this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,target:i.getZr().findHover(a.x,a.y).target},o))}},e.prototype.manuallyHideTip=function(r,n,i,a){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,a.from!==this.uid&&this._hide(Ko(a,i))},e.prototype._manuallyAxisShowTip=function(r,n,i,a){var o=a.seriesIndex,s=a.dataIndex,l=n.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var f=n.getSeriesByIndex(o);if(!!f){var c=f.getData(),u=Zt([c.getItemModel(s),f,(f.coordinateSystem||{}).model],this._tooltipModel);if(u.get("trigger")==="axis")return i.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:a.position}),!0}}},e.prototype._tryShow=function(r,n){var i=r.target,a=this._tooltipModel;if(!!a){this._lastX=r.offsetX,this._lastY=r.offsetY;var o=r.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,r);else if(i){var s=Q(i);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null;var l,f;jt(i,function(c){if(Q(c).dataIndex!=null)return l=c,!0;if(Q(c).tooltipConfig!=null)return f=c,!0},!0),l?this._showSeriesItemTooltip(r,l,n):f?this._showComponentItemTooltip(r,f,n):this._hide(n)}else this._lastDataByCoordSys=null,this._hide(n)}},e.prototype._showOrMove=function(r,n){var i=r.get("showDelay");n=Y(n,this),clearTimeout(this._showTimout),i>0?this._showTimout=setTimeout(n,i):n()},e.prototype._showAxisTooltip=function(r,n){var i=this._ecModel,a=this._tooltipModel,o=[n.offsetX,n.offsetY],s=Zt([n.tooltipOption],a),l=this._renderMode,f=[],c=dr("section",{blocks:[],noHeader:!0}),u=[],v=new Nn;S(r,function(y){S(y.dataByAxis,function(_){var w=i.getComponent(_.axisDim+"Axis",_.axisIndex),x=_.value;if(!(!w||x==null)){var T=au(x,w.axis,i,_.seriesDataIndices,_.valueLabelOpt),b=dr("section",{header:T,noHeader:!_r(T),sortBlocks:!0,blocks:[]});c.blocks.push(b),S(_.seriesDataIndices,function(D){var C=i.getSeriesByIndex(D.seriesIndex),A=D.dataIndexInside,M=C.getDataParams(A);if(!(M.dataIndex<0)){M.axisDim=_.axisDim,M.axisIndex=_.axisIndex,M.axisType=_.axisType,M.axisId=_.axisId,M.axisValue=ql(w.axis,{value:x}),M.axisValueLabel=T,M.marker=v.makeTooltipMarker("item",hr(M.color),l);var I=$a(C.formatTooltip(A,!0,null)),P=I.frag;if(P){var L=Zt([C],a).get("valueFormatter");b.blocks.push(L?R({valueFormatter:L},P):P)}I.text&&u.push(I.text),f.push(M)}})}})}),c.blocks.reverse(),u.reverse();var h=n.position,d=s.get("order"),p=ja(c,v,l,d,i.get("useUTC"),s.get("textStyle"));p&&u.unshift(p);var g=l==="richText"?` `:"
",m=u.join(g);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(r,f)?this._updatePosition(s,h,o[0],o[1],this._tooltipContent,f):this._showTooltipContent(s,m,f,Math.random()+"",o[0],o[1],h,null,v)})},e.prototype._showSeriesItemTooltip=function(r,n,i){var a=this._ecModel,o=Q(n),s=o.seriesIndex,l=a.getSeriesByIndex(s),f=o.dataModel||l,c=o.dataIndex,u=o.dataType,v=f.getData(u),h=this._renderMode,d=r.positionDefault,p=Zt([v.getItemModel(c),f,l&&(l.coordinateSystem||{}).model],this._tooltipModel,d?{position:d}:null),g=p.get("trigger");if(!(g!=null&&g!=="item")){var m=f.getDataParams(c,u),y=new Nn;m.marker=y.makeTooltipMarker("item",hr(m.color),h);var _=$a(f.formatTooltip(c,!1,u)),w=p.get("order"),x=p.get("valueFormatter"),T=_.frag,b=T?ja(x?R({valueFormatter:x},T):T,y,h,w,a.get("useUTC"),p.get("textStyle")):_.text,D="item_"+f.name+"_"+c;this._showOrMove(p,function(){this._showTooltipContent(p,b,m,D,r.offsetX,r.offsetY,r.position,r.target,y)}),i({type:"showTip",dataIndexInside:c,dataIndex:v.getRawIndex(c),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(r,n,i){var a=this._renderMode==="html",o=Q(n),s=o.tooltipConfig,l=s.option||{},f=l.encodeHTMLContent;if(O(l)){var c=l;l={content:c,formatter:c},f=!0}f&&a&&l.content&&(l=z(l),l.content=me(l.content));var u=[l],v=this._ecModel.getComponent(o.componentMainType,o.componentIndex);v&&u.push(v),u.push({formatter:l.content});var h=r.positionDefault,d=Zt(u,this._tooltipModel,h?{position:h}:null),p=d.get("content"),g=Math.random()+"",m=new Nn;this._showOrMove(d,function(){var y=z(d.get("formatterParams")||{});this._showTooltipContent(d,p,y,g,r.offsetX,r.offsetY,r.position,n,m)}),i({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(r,n,i,a,o,s,l,f,c){if(this._ticket="",!(!r.get("showContent")||!r.get("show"))){var u=this._tooltipContent;u.setEnterable(r.get("enterable"));var v=r.get("formatter");l=l||r.get("position");var h=n,d=this._getNearestPoint([o,s],i,r.get("trigger"),r.get("borderColor")),p=d.color;if(v)if(O(v)){var g=r.ecModel.get("useUTC"),m=E(i)?i[0]:i,y=m&&m.axisType&&m.axisType.indexOf("time")>=0;h=v,y&&(h=Ns(m.axisValue,h,g)),h=Vs(h,i,!0)}else if(W(v)){var _=Y(function(w,x){w===this._ticket&&(u.setContent(x,c,r,p,l),this._updatePosition(r,l,o,s,u,i,f))},this);this._ticket=a,h=v(i,a,_)}else h=v;u.setContent(h,c,r,p,l),u.show(r,p),this._updatePosition(r,l,o,s,u,i,f)}},e.prototype._getNearestPoint=function(r,n,i,a){if(i==="axis"||E(n))return{color:a||(this._renderMode==="html"?"#fff":"none")};if(!E(n))return{color:a||n.color||n.borderColor}},e.prototype._updatePosition=function(r,n,i,a,o,s,l){var f=this._api.getWidth(),c=this._api.getHeight();n=n||r.get("position");var u=o.getSize(),v=r.get("align"),h=r.get("verticalAlign"),d=l&&l.getBoundingRect().clone();if(l&&d.applyTransform(l.transform),W(n)&&(n=n([i,a],s,o.el,d,{viewSize:[f,c],contentSize:u.slice()})),E(n))i=te(n[0],f),a=te(n[1],c);else if(B(n)){var p=n;p.width=u[0],p.height=u[1];var g=zs(p,{width:f,height:c});i=g.x,a=g.y,v=null,h=null}else if(O(n)&&l){var m=Ig(n,d,u,r.get("borderWidth"));i=m[0],a=m[1]}else{var m=Mg(i,a,o,f,c,v?null:20,h?null:20);i=m[0],a=m[1]}if(v&&(i-=Zo(v)?u[0]/2:v==="right"?u[0]:0),h&&(a-=Zo(h)?u[1]/2:h==="bottom"?u[1]:0),uu(r)){var m=Ag(i,a,o,f,c);i=m[0],a=m[1]}o.moveTo(i,a)},e.prototype._updateContentNotChangedOnAxis=function(r,n){var i=this._lastDataByCoordSys,a=this._cbParamsList,o=!!i&&i.length===r.length;return o&&S(i,function(s,l){var f=s.dataByAxis||[],c=r[l]||{},u=c.dataByAxis||[];o=o&&f.length===u.length,o&&S(f,function(v,h){var d=u[h]||{},p=v.seriesDataIndices||[],g=d.seriesDataIndices||[];o=o&&v.value===d.value&&v.axisType===d.axisType&&v.axisId===d.axisId&&p.length===g.length,o&&S(p,function(m,y){var _=g[y];o=o&&m.seriesIndex===_.seriesIndex&&m.dataIndex===_.dataIndex}),a&&S(v.seriesDataIndices,function(m){var y=m.seriesIndex,_=n[y],w=a[y];_&&w&&w.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=r,this._cbParamsList=n,!!o},e.prototype._hide=function(r){this._lastDataByCoordSys=null,r({type:"hideTip",from:this.uid})},e.prototype.dispose=function(r,n){Z.node||!n.getDom()||(gi(this,"_updatePosition"),this._tooltipContent.dispose(),xi("itemTooltip",n))},e.type="tooltip",e}(Lt);function Zt(t,e,r){var n=e.ecModel,i;r?(i=new ve(r,n,n),i=new ve(e.option,i,n)):i=e;for(var a=t.length-1;a>=0;a--){var o=t[a];o&&(o instanceof ve&&(o=o.get("tooltip",!0)),O(o)&&(o={formatter:o}),o&&(i=new ve(o,i,n)))}return i}function Ko(t,e){return t.dispatchAction||Y(e.dispatchAction,e)}function Mg(t,e,r,n,i,a,o){var s=r.getSize(),l=s[0],f=s[1];return a!=null&&(t+l+a+2>n?t-=l+a:t+=a),o!=null&&(e+f+o>i?e-=f+o:e+=o),[t,e]}function Ag(t,e,r,n,i){var a=r.getSize(),o=a[0],s=a[1];return t=Math.min(t+o,n)-o,e=Math.min(e+s,i)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}function Ig(t,e,r,n){var i=r[0],a=r[1],o=Math.ceil(Math.SQRT2*n)+8,s=0,l=0,f=e.width,c=e.height;switch(t){case"inside":s=e.x+f/2-i/2,l=e.y+c/2-a/2;break;case"top":s=e.x+f/2-i/2,l=e.y-a-o;break;case"bottom":s=e.x+f/2-i/2,l=e.y+c+o;break;case"left":s=e.x-i-o,l=e.y+c/2-a/2;break;case"right":s=e.x+f+o,l=e.y+c/2-a/2}return[s,l]}function Zo(t){return t==="center"||t==="middle"}function Pg(t,e,r){var n=bi(t).queryOptionMap,i=n.keys()[0];if(!(!i||i==="series")){var a=wr(e,i,n.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}),o=a.models[0];if(!!o){var s=r.getViewOfComponentModel(o),l;if(s.group.traverse(function(f){var c=Q(f).tooltipConfig;if(c&&c.name===t.name)return l=f,!0}),l)return{componentMainType:i,componentIndex:o.componentIndex,el:l}}}}var Lg=bg;function Bg(t){jl(ug),t.registerComponentModel(cg),t.registerComponentView(Lg),t.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},it),t.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},it)}export{Ng as a,Bg as b,kg as c,Og as i,jl as u};