(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-5072099c","chunk-df50fe74","chunk-09a68df5"],{"0007":function(t,e,n){"use strict";var i=n("7a23"),r=n("313e");const a=["id"];var o={__name:"moreLineEcharts",props:{echartsId:{type:String,default:"morelineId"},data:{type:Object,default:{color:[],list:[],xData:[],labelColor:"#000",rotate:0,interval:0,isVertical:!1}}},setup(t){const e=t;function n(t){let e=t.color,n=t.list,i=n.map((t,n)=>({type:"line",name:t.label,data:t.val,itemStyle:{normal:{color:e[n]}},smooth:!0,showSymbol:!1,areaStyle:{normal:{color:new r["a"].LinearGradient(0,0,0,1,[{offset:0,color:"rgba(199, 237, 250,0.5)"},{offset:1,color:"rgba(199, 237, 250,0.2)"}],!1)}}}));o(i)}function o(t){var n=r["b"](document.getElementById(e.echartsId)),i={grid:{top:"20%",right:"6%",left:"2%",bottom:"3%",containLabel:!0},legend:{data:e.data.list.map(t=>t.label),textStyle:{color:e.data.labelColor||"#fff"},icon:"diamond",itemWidth:16,itemHeight:8,itemGap:5},tooltip:{trigger:"axis",axisPointer:{lineStyle:{color:"#ddd"}},backgroundColor:"rgba(255,255,255,1)",padding:[5,10],textStyle:{color:"#7588E4"},extraCssText:"box-shadow: 0 0 5px rgba(0,0,0,0.3)"},xAxis:{type:"category",data:e.data.xData,axisTick:{show:!1},axisLine:{show:!1},axisLabel:{show:!0,color:e.data.labelColor||"#fff",interval:e.data.interval||0,rotate:e.data.rotate||0,formatter:function(t){return e.data.isVertical?t.split("").join("\n"):t}}},yAxis:{type:"value",splitLine:{show:!0,lineStyle:{type:"dashed",color:"rgba(14,95,255,0.5)"}},axisTick:{show:!1},axisLine:{show:!1},axisLabel:{color:e.data.labelColor||"#fff"}},series:t};i&&n.setOption(i),window.addEventListener("resize",(function(){n.resize()}))}return Object(i["watch"])(()=>e.data,t=>{Object(i["nextTick"])(()=>{n(t)})},{immediate:!0,deep:!0}),(e,n)=>(Object(i["openBlock"])(),Object(i["createElementBlock"])("div",{style:{height:"100%",width:"100%"},id:t.echartsId},null,8,a))}};const s=o;e["a"]=s},"04f6":function(t,e,n){"use strict";n.d(e,"a",(function(){return d}));var i=32,r=7;function a(t){var e=0;while(t>=i)e|=1&t,t>>=1;return t+e}function o(t,e,n,i){var r=e+1;if(r===n)return 1;if(i(t[r++],t[e])<0){while(r=0)r++;return r-e}function s(t,e,n){n--;while(e>>1,r(o,t[a])<0?l=a:s=a+1;var u=i-s;switch(u){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:while(u>0)t[s+u]=t[s+u-1],u--}t[s]=o}}function u(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])>0){s=i-r;while(l0)o=l,l=1+(l<<1),l<=0&&(l=s);l>s&&(l=s),o+=r,l+=r}else{s=r+1;while(ls&&(l=s);var u=o;o=r-l,l=r-u}o++;while(o>>1);a(t,e[n+c])>0?o=c+1:l=c}return l}function c(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])<0){s=r+1;while(ls&&(l=s);var u=o;o=r-l,l=r-u}else{s=i-r;while(l=0)o=l,l=1+(l<<1),l<=0&&(l=s);l>s&&(l=s),o+=r,l+=r}o++;while(o>>1);a(t,e[n+c])<0?l=c:o=c+1}return l}function h(t,e){var n,i,a=r,o=0,s=0;o=t.length;var l=[];function h(t,e){n[s]=t,i[s]=e,s+=1}function d(){while(s>1){var t=s-2;if(t>=1&&i[t-1]<=i[t]+i[t+1]||t>=2&&i[t-2]<=i[t]+i[t-1])i[t-1]i[t+1])break;p(t)}}function f(){while(s>1){var t=s-2;t>0&&i[t-1]=r||m>=r);if(v)break;y<0&&(y=0),y+=2}if(a=y,a<1&&(a=1),1===i){for(h=0;h=0;h--)t[m+h]=t[g+h];if(0===i){b=!0;break}}if(t[p--]=l[f--],1===--s){b=!0;break}if(_=s-u(t[d],l,0,s,s-1,e),0!==_){for(p-=_,f-=_,s-=_,m=p+1,g=f+1,h=0;h<_;h++)t[m+h]=l[g+h];if(s<=1){b=!0;break}}if(t[p--]=t[d--],0===--i){b=!0;break}v--}while(y>=r||_>=r);if(b)break;v<0&&(v=0),v+=2}if(a=v,a<1&&(a=1),1===s){for(p-=i,d-=i,m=p+1,g=d+1,h=i-1;h>=0;h--)t[m+h]=t[g+h];t[p]=l[f]}else{if(0===s)throw new Error;for(g=p-(s-1),h=0;h=0;h--)t[m+h]=t[g+h];t[p]=l[f]}else for(g=p-(s-1),h=0;hd&&(f=d),l(t,n,n+f,n+u,e),u=f}c.pushRun(n,u),c.mergeRuns(),s-=u,n+=u}while(0!==s);c.forceMergeRuns()}}},"04f7":function(t,e,n){"use strict";n.d(e,"b",(function(){return v})),n.d(e,"a",(function(){return y}));var i=n("07fd"),r=n("e0d3"),a=n("6d8b"),o=n("2b17"),s=n("b7d9"),l=n("edae"),u=n("ec6f"),c=function(){function t(){}return t.prototype.getRawData=function(){throw new Error("not supported")},t.prototype.getRawDataItem=function(t){throw new Error("not supported")},t.prototype.cloneRawData=function(){},t.prototype.getDimensionInfo=function(t){},t.prototype.cloneAllDimensionInfo=function(){},t.prototype.count=function(){},t.prototype.retrieveValue=function(t,e){},t.prototype.retrieveValueFromItem=function(t,e){},t.prototype.convertValue=function(t,e){return Object(s["d"])(t,e)},t}();function h(t,e){var n=new c,r=t.data,s=n.sourceFormat=t.sourceFormat,u=t.startIndex,h="";t.seriesLayoutBy!==i["a"]&&Object(l["c"])(h);var m=[],v={},y=t.dimensionsDefine;if(y)Object(a["k"])(y,(function(t,e){var n=t.name,i={index:e,name:n,displayName:t.displayName};if(m.push(i),null!=n){var r="";Object(a["q"])(v,n)&&Object(l["c"])(r),v[n]=i}}));else for(var _=0;_i?e:t,a=Math.min(n,i),o=r[a-1]||{color:[0,0,0,0],offset:0},s=a;so;if(s)i.length=o;else for(var l=a;l=1},t.prototype.getAdditiveTrack=function(){return this._additiveTrack},t.prototype.addKeyframe=function(t,e,n){this._needsSort=!0;var i=this.keyframes,s=i.length,l=!1,h=C,d=e;if(Object(a["u"])(e)){var f=x(e);h=f,(1===f&&!Object(a["z"])(e[0])||2===f&&!Object(a["z"])(e[0][0]))&&(l=!0)}else if(Object(a["z"])(e)&&!Object(a["l"])(e))h=w;else if(Object(a["C"])(e))if(isNaN(+e)){var p=u["parse"](e);p&&(d=p,h=T)}else h=w;else if(Object(a["x"])(e)){var g=Object(a["m"])({},d);g.colorStops=Object(a["H"])(e.colorStops,(function(t){return{offset:t.offset,color:u["parse"](t.color)}})),Object(c["m"])(e)?h=M:Object(c["o"])(e)&&(h=A),d=g}0===s?this.valType=h:h===this.valType&&h!==C||(l=!0),this.discrete=this.discrete||l;var m={time:t,value:d,rawValue:e,percent:0};return n&&(m.easing=n,m.easingFunc=Object(a["w"])(n)?n:r[n]||Object(o["a"])(n)),i.push(m),m},t.prototype.prepare=function(t,e){var n=this.keyframes;this._needsSort&&n.sort((function(t,e){return t.time-e.time}));for(var i=this.valType,r=n.length,a=n[r-1],o=this.discrete,s=D(i),l=I(i),u=0;u=0;n--)if(u[n].percent<=e)break;n=v(n,c-2)}else{for(n=m;ne)break;n=v(n-1,c-2)}r=u[n+1],i=u[n]}if(i&&r){this._lastFr=n,this._lastFrP=e;var _=r.percent-i.percent,x=0===_?1:v((e-i.percent)/_,1);r.easingFunc&&(x=r.easingFunc(x));var w=o?this._additiveValue:g?L:t[h];if(!D(l)&&!g||w||(w=this._additiveValue=[]),this.discrete)t[h]=x<1?i.rawValue:r.rawValue;else if(D(l))l===O?f(w,i[s],r[s],x):p(w,i[s],r[s],x);else if(I(l)){var S=i[s],A=r[s],C=l===M;t[h]={type:C?"linear":"radial",x:d(S.x,A.x,x),y:d(S.y,A.y,x),colorStops:Object(a["H"])(S.colorStops,(function(t,e){var n=A.colorStops[e];return{offset:d(t.offset,n.offset,x),color:b(f([],t.color,n.color,x))}})),global:A.global},C?(t[h].x2=d(S.x2,A.x2,x),t[h].y2=d(S.y2,A.y2,x)):t[h].r=d(S.r,A.r,x)}else if(g)f(w,i[s],r[s],x),o||(t[h]=b(w));else{var E=d(i[s],r[s],x);o?this._additiveValue=E:t[h]=E}o&&this._addToTarget(t)}}},t.prototype._addToTarget=function(t){var e=this.valType,n=this.propName,i=this._additiveValue;e===w?t[n]=t[n]+i:e===T?(u["parse"](t[n],L),g(L,L,i,1),t[n]=b(L)):e===O?g(t[n],t[n],i,1):e===S&&m(t[n],t[n],i,1)},t}(),j=function(){function t(t,e,n,i){this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=e,e&&i?Object(a["G"])("Can' use additive animation on looped animation."):(this._additiveAnimators=i,this._allowDiscrete=n)}return t.prototype.getMaxTime=function(){return this._maxTime},t.prototype.getDelay=function(){return this._delay},t.prototype.getLoop=function(){return this._loop},t.prototype.getTarget=function(){return this._target},t.prototype.changeTarget=function(t){this._target=t},t.prototype.when=function(t,e,n){return this.whenWithKeys(t,e,Object(a["F"])(e),n)},t.prototype.whenWithKeys=function(t,e,n,i){for(var r=this._tracks,a=0;a0&&s.addKeyframe(0,_(l),i),this._trackKeys.push(o)}s.addKeyframe(t,_(e[o]),i)}return this._maxTime=Math.max(this._maxTime,t),this},t.prototype.pause=function(){this._clip.pause(),this._paused=!0},t.prototype.resume=function(){this._clip.resume(),this._paused=!1},t.prototype.isPaused=function(){return!!this._paused},t.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},t.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var e=t.length,n=0;n0)){this._started=1;for(var e=this,n=[],i=this._maxTime||0,r=0;r1){var s=o.pop();r.addKeyframe(s.time,t[i]),r.prepare(this._maxTime,r.getAdditiveTrack())}}}},t}();e["b"]=j},"07fd":function(t,e,n){"use strict";n.d(e,"i",(function(){return r})),n.d(e,"f",(function(){return a})),n.d(e,"c",(function(){return o})),n.d(e,"e",(function(){return s})),n.d(e,"d",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"a",(function(){return h})),n.d(e,"b",(function(){return d}));var i=n("6d8b"),r=Object(i["f"])(["tooltip","label","itemName","itemId","itemGroupId","seriesName"]),a="original",o="arrayRows",s="objectRows",l="keyedColumns",u="typedArray",c="unknown",h="column",d="row"},"0924":function(t,e,n){"use strict";function i(t,e,n){switch(n){case"color":var i=t.getItemVisual(e,"style");return i[t.getVisual("drawType")];case"opacity":return t.getItemVisual(e,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return t.getItemVisual(e,n);default:0}}function r(t,e){switch(e){case"color":var n=t.getVisual("style");return n[t.getVisual("drawType")];case"opacity":return t.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return t.getVisual(e);default:0}}function a(t,e,n,i){switch(n){case"color":var r=t.ensureUniqueItemVisual(e,"style");r[t.getVisual("drawType")]=i,t.setItemVisual(e,"colorFromPalette",!1);break;case"opacity":t.ensureUniqueItemVisual(e,"style").opacity=i;break;case"symbol":case"symbolSize":case"liftZ":t.setItemVisual(e,n,i);break;default:0}}n.d(e,"a",(function(){return i})),n.d(e,"b",(function(){return r})),n.d(e,"c",(function(){return a}))},"0947":function(t,e,n){"use strict";n("60d9")},"0bb9":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABcAAAArCAYAAACTkhN2AAAMIklEQVRIiWVXCZAc5Xl9fc70TE/PPVrtvavVsSskoQNpV8rqQgJFkKRCHHMUp+0irgJTxEkVZZw4dlEuE2LKpmzHAkQiELikpDBWbB0IHchCkjkWSasLSas9Nfexc/RM3/2nuif4CF3Vd/fr7/++973/NQUA45NJZweGYVCv18AwBHv3/hKGZiyvN2pfO336o825bEHQNNUCCOXzCVRnV2dq48ZN77S3t+2lKDKzZcsWKKqGgD8Ay7ZcPBZfWAgoigbHcpRcq4cVVY1YlhkBIFAUZYEQihBCGYapKYoS0XRdCoh+UDQNEPInYH8CbtsEPp8fs7N5z+xs+ftvvfmLb8pyjXKucZwHLMeDEBuqauDK5avSubOj3+roaP36449/9VmlUX/F5xdtm9i/x2OczdN//4/uid/vA0WBefGH/7bjpz/Z8YTPJ1GRaAzUHwXgBEdsCh6PF5IURj6fEw4e2H83QIXXr99wSBTFZtQs2wT/xlNPuwA+vw+vv7H7mz968aVnQqEwRDEAyzSaOaQoGLoB0zBBcwzcFyjiPmMYBk6fOr2mta2t1je/78z4+ATK5XIzLSzDwOcTcOH86JLdr+9+whlQQAqCENJcKQqarsLj9cDrFVCv12GDdrBhmUAkEoUs17Fnz96vxhLx/RzPXXUCccGr1YpbyLNnP900dv1aTzgUhW1ZLntg27BsgkA4jL6BbgSDQYxdmkYuk2rWj6bcAJzrVy5fGpCrldV/fc89V/P5fBN8ZOQ8QqEQJsYnB3TNAMdx7gvOB52taWjo7ulHPB6GaZqItSRQKmTdNNmgQFO0O6pCvoxUOr0wlUohOZNsggf8Xs4ytdj0TGqA9/ggeD0wbYCiAY5nYDvjhw2e4WHrJoilgWFoEJYDTTOgaQoC4wPDsLh+7dpiuVbxh8JinXbAW1oiMU2trTw7MjIsSRI0w4BlmSA2gWlasC2C5HQGU+MpZDJFFAsFqIoGw7Tcujqj1VTVZdCZM2f+slQqDQ0sXtxkyy233PrA6IVLd/721Jlb57a3wiN4YVoW6o0qYrEIYi1zYFg6avUaVFWBDRvReAwelkOlWoFPFBEIShAEDyanJqnOzo58NBo+7IIHI4lvTU5OrZu5ORn0+Dhoah0wNbDE+UAFxVIOnXMTCHo8kDgeXpbB9bHPoCsy/LxTUBOK1oBpGygXZhGORSgL9iE355cvnO2t1+VO5+Hs9BT+5eF78eU7tiJZAcaSSYxOXEYoHMF9W/7CzfWeI7/Bst5eDMxfgKVdnYgwwK4Dh/D9N99yOgzl2UJnOpkMu+C2pTOWZTQ70CZYOq8b81YsRYIJYWTP29g8OIyBzi60x+IADdx7+524kZrGdF3GwLp1EJUqBq+P/b6LTUO3dFWxXfC/+dKXd+XzueUnjx97qFypIVuoAoTG/o/O4NfHjkCkTLz63efg5WlYxEQ8EsH3XvkZ0rUGON6Pr2xeg7riqCmHcDyEDRs27lm+YsUNly2xWOxHQ0NDD7+yY8dTffP7rWuTM0BAwuED+3H8vYNIZzOwDBNgKIAmsImFbKGE40eP4N13DwCBAK5MToAXBHnHyy/ff+e2bc/UarLmgjs0UpUGwtHoT24bXv9U3SHYzTQ237IMsTlxbFq7DiG/CFmRoek6RNaL29f8GSLxBFb1LwCqCkplBdvv3v7ztUODe2RZdpvPZct99z2AQCAA0e9HS0fnCNHIspjWWHTbwl4sXbQE24c3IhYIoNaogqZYCDSHee0tWDa/F3etWAYml8WFXCnXtnTZc9FIZLpRb0AKiE01vXD+ImzbhmGaCEbCOHX0xEOhqWtv/NUdG4BYHEpZQTo3C9W2QBwl9LLo6mgBeAYo13H00Ls4bdA/m7dq8MlyPo+Q6AXraLcD/uRTT4NmWfAeD2AR+CPS6IWZKb6azg/Pi/vBeVnINRnpTBKmXkVDa+DYh+cg1BUc+eBDTHiFf188OPiM6BWMOXPiSCWTSN680QT/9neeg9fnh0+UYJo22trbYUXDxV8cPNA/PTbRzVsEYdGP1piEzkQYM/kSvrvzDXySzOCGqh3efu+9z65ZsTznE3h0tLcim88hEQs2hcsyTXy+D4UklIqleYf++5ffO3v+wqJDM0n9Reodvj0RR8ecGBiaxlQ6h+lkCuO5grmof8GSMydO/EN/38JnLUJXG4oCXdfgD7Y2SZ/O1ZDKViGrBFMzOfGRRx5/m2cDJCQliIcXiGMHaEEgoBhCMQKJJDpIT08v6erqIgzjJX3zFxVPfPDJHcVyA+PTU3h7376u/e+NzHUjTyXHXdmsVv149dVdz7/++u57IpEYxKCABBdFICC4M1MqW0CtJiMaDiMSDaEh11AqVGCYVOTatbH7u7o7Dnt4Dz67dOnrvFeednkuV4sAMXD8yLsP7nz55SfCoQQkyQeOJVi6bAlWrVmD3v5+eLwCOI6HBYJsJodisQLWy0OpN/DZ5ctfqtarm+qKivePndwqClDZpp7QfC5bnPPOr/7nG426jNY2J7dAPN6CfKmKXHEWtVodclUGz3nBMl4ougWKZiEIAuplGXt27xIvjn60IxQK5i5euLhybuvRLWyzQ/V5Y2NjQ7/73cjqSDQOTSlDAwUmT0PXdWiGDlVVYZmkOQMRG4qqgKIIaGK59yRBgKjpC+hSYUFPawKq2oi64OcunFs/MT6xVqlrCIcTjkrCti1Uq46AUSDuXE/Q0xZHw2WViuGFqzGTyeP4p5+AohhwgoBZm0F66iYefPTBnwbD4WfdnM+Wyu2y3Jjr6Klh2LAtBoSw4Dg/vN4AWN4LURDxd3dvxYqBPoihKFiOg8/Do6e3b/rBhx/9Fevla++fOomZdBax2JwP7tq+veY20Q+ef366r2/+x5pmxpM3JxcQ2zCDwbCsGzpnmjrt8N/Ds1jU3Y4bqTzyNR0z2SIuXr+Cnr7eiW//8z89Fo1GJycmJ9YND68/tPn2TT/neb7masvJD04jk8li7MaUVC7nHmMZpjKweEl0587XvnP24xHJ0FUIfhGJRAtYjweapriGyDAaWLX6tmv33//A3X6/dH1ua4d08sQJo7NzjpLOlkE32WLDMExUK9Wq3+d/qX9g0S6vwFM+v1+KJBIQ/H6IARGcYzkMDQxlwbJV2CDI5XLS9etXWzPZlOMPqxRFKbOzVddOuwVlWAaSFEDL3ARWr1mF+X3z8OOXfrzg05GPwbFeSMEQeA8PQ9egKQ3XKumaYy0MBEOh3KL+gRuOO7MsC6Lox6fnRsF5fE1wx5nG4jGsHV7r+kDO48XSZbeeikQijxQLJZ7zBaE2TChK1QXw+UXQrAhDrcDv9WV6urtuZjMZlAppaJoGxjVLdBM8nU67J+l0xrVxjv1tSSQOts1tuVgq5leIwQAadQ3RWKjo8/mUmZlsm+DzU4ahI5PNtF69+lnb7Gw5yXE0CqUaGJoHS1NNcMfbNR2tjc9rMKelRY8lEqbjYC1DRbVcwPJlQ2cXLuq/9B+v7X5SAMfE4mFnOgvOzCTbZFlOOt7SJjwEn9f1mS54a1vbF35eQqFQOR6PVzxeLxxFdpoqKEn5zo7WUa/gsUUpwDh5ZhmG1hSFNTTN9ZPEcb0U4x674M7k/P8XXfCgPDtrqWoDFHwghIdPDFcDgUhO1wxSl+tuI3lYyluXa1KjoYDYFniBdsXMOW5G3vqHyJ30OBY6Go0gHotfz6Yz20wDsAmFeDw+3d7VMxkKSfLM9GTEYcuty5dq7d09aqVchmPnC0UVtZoOj4dv8tw5+Hx1Zu1sLod8oYjBocHDLXNbZyvVIniOGIODK492d3VfW71m5XvlShEsQ6G/v//Djes3vD88vB5Da4ex/a6t6O1pBUP/X1qUP0oLIV7kc1n4RRGFYnGhbdlhChRMy6Q0TTXfevM/bVVRXO/nWGZdN1qOHz8WtAipbNu2HbLmwbblB8HUjjYjpyjqDyuARCLRvW/fvjd++MILP0ilboLneVQqFfbSpcu3HDp4QBwdPb/SeU5R6jhy5L2hnTtfu6ip6qMUBcgKhSA7jt7AR1/8yQ1Fwti797/+9sUX/vUhp64URVUJIfTixYtTvfP6bt5x558rN2emf3vlypWuWl02a7LMppLJdikgPhaSgocnUlZqa28SbJzF/wKPOdM6g3/bDwAAAABJRU5ErkJggg=="},"0d20":function(t,e,n){},"0da8":function(t,e,n){"use strict";var i=n("21a10"),r=n("19eb"),a=n("9850"),o=n("6d8b"),s=Object(o["i"])({x:0,y:0},r["b"]),l={style:Object(o["i"])({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},r["a"].style)};function u(t){return!!(t&&"string"!==typeof t&&t.width&&t.height)}var c=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i["a"])(e,t),e.prototype.createStyle=function(t){return Object(o["g"])(s,t)},e.prototype._getSize=function(t){var e=this.style,n=e[t];if(null!=n)return n;var i=u(e.image)?e.image:this.__image;if(!i)return 0;var r="width"===t?"height":"width",a=e[r];return null==a?i[t]:i[t]/i[r]*a},e.prototype.getWidth=function(){return this._getSize("width")},e.prototype.getHeight=function(){return this._getSize("height")},e.prototype.getAnimationStyleProps=function(){return l},e.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new a["a"](t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},e}(r["c"]);c.prototype.type="image",e["a"]=c},"0f99":function(t,e,n){"use strict";n.d(e,"a",(function(){return o})),n.d(e,"g",(function(){return l})),n.d(e,"c",(function(){return u})),n.d(e,"d",(function(){return c})),n.d(e,"f",(function(){return h})),n.d(e,"e",(function(){return d})),n.d(e,"b",(function(){return f}));var i=n("e0d3"),r=n("6d8b"),a=n("07fd"),o={Must:1,Might:2,Not:3},s=Object(i["o"])();function l(t){s(t).datasetMap=Object(r["f"])()}function u(t,e,n){var i={},a=h(e);if(!a||!t)return i;var o,l,u=[],c=[],d=e.ecModel,f=s(d).datasetMap,p=a.uid+"_"+n.seriesLayoutBy;t=t.slice(),Object(r["k"])(t,(function(e,n){var a=Object(r["A"])(e)?e:t[n]={name:e};"ordinal"===a.type&&null==o&&(o=n,l=v(a)),i[a.name]=[]}));var g=f.get(p)||f.set(p,{categoryWayDim:l,valueWayDim:0});function m(t,e,n){for(var i=0;i=0&&t=0&&t=t},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.prototype.calcNiceTicks=function(){},e.prototype.calcNiceExtent=function(){},e.type="ordinal",e}(r["a"]);r["a"].registerClass(l),e["a"]=l},"19eb":function(t,e,n){"use strict";n.d(e,"b",(function(){return u})),n.d(e,"a",(function(){return c}));var i=n("21a10"),r=n("d5b7"),a=n("9850"),o=n("6d8b"),s=n("4bc4"),l="__zr_style_"+Math.round(10*Math.random()),u={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},c={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};u[l]=!0;var h=["z","z2","invisible"],d=["invisible"],f=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype._init=function(e){for(var n=Object(o["F"])(e),i=0;i=0;o--)i[o]&&!u["l"](i[o])?a=!0:(i[o]=null,!a&&r--);i.length=r,t[n]=i}})),delete t[w],t},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,e){var n=this._componentsMap.get(t);if(n){var i=n[e||0];if(i)return i;if(null==e)for(var r=0;r=e:"max"===n?t<=e:t===e}function V(t,e){return t.join(",")===e.join(",")}var F=R,G=a["k"],H=a["A"],U=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function W(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=U.length;n=0;g--){var m=t[g];if(s||(d=m.data.rawIndexOf(m.stackedByDimension,h)),d>=0){var v=m.data.getByRawIndex(m.stackResultDimension,d);if("all"===l||"positive"===l&&v>0||"negative"===l&&v<0||"samesign"===l&&f>=0&&v>0||"samesign"===l&&f<=0&&v<0){f=Object(dt["b"])(f,v),p=v;break}}}return i[0]=f,i[1]=p,i}))}))}var gt=n("4f85"),mt=n("b12f"),vt=n("e887"),yt=n("c7a2"),_t=n("0da8"),bt=n("deab"),xt=n("cbe5"),wt=n("861c"),Ot=n("7d6c"),St=n("88b3"),Tt=n("282b"),Mt=n("551f"),At=n("3901"),Ct=Object(u["o"])(),It={itemStyle:Object(Tt["a"])(Mt["a"],!0),lineStyle:Object(Tt["a"])(At["a"],!0)},Dt={lineStyle:"stroke",itemStyle:"fill"};function Lt(t,e){var n=t.visualStyleMapper||It[e];return n||(console.warn("Unkown style type '"+e+"'."),It.itemStyle)}function Et(t,e){var n=t.visualDrawType||Dt[e];return n||(console.warn("Unkown style type '"+e+"'."),"fill")}var jt={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var n=t.getData(),i=t.visualStyleAccessPath||"itemStyle",r=t.getModel(i),o=Lt(t,i),s=o(r),l=r.getShallow("decal");l&&(n.setVisual("decal",l),l.dirty=!0);var u=Et(t,i),c=s[u],h=Object(a["w"])(c)?c:null,d="auto"===s.fill||"auto"===s.stroke;if(!s[u]||h||d){var f=t.getColorFromPalette(t.name,null,e.getSeriesCount());s[u]||(s[u]=f,n.setVisual("colorFromPalette",!0)),s.fill="auto"===s.fill||Object(a["w"])(s.fill)?f:s.fill,s.stroke="auto"===s.stroke||Object(a["w"])(s.stroke)?f:s.stroke}if(n.setVisual("style",s),n.setVisual("drawType",u),!e.isSeriesFiltered(t)&&h)return n.setVisual("colorFromPalette",!1),{dataEach:function(e,n){var i=t.getDataParams(n),r=Object(a["m"])({},s);r[u]=h(i),e.setItemVisual(n,"style",r)}}}},Pt=new c["a"],Nt={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){if(!t.ignoreStyleOnData&&!e.isSeriesFiltered(t)){var n=t.getData(),i=t.visualStyleAccessPath||"itemStyle",r=Lt(t,i),o=n.getVisual("drawType");return{dataEach:n.hasItemOption?function(t,e){var n=t.getRawDataItem(e);if(n&&n[i]){Pt.option=n[i];var s=r(Pt),l=t.ensureUniqueItemVisual(e,"style");Object(a["m"])(l,s),Pt.option.decal&&(t.setItemVisual(e,"decal",Pt.option.decal),Pt.option.decal.dirty=!0),o in s&&t.setItemVisual(e,"colorFromPalette",!1)}}:null}}}},Rt={performRawSeries:!0,overallReset:function(t){var e=Object(a["f"])();t.eachSeries((function(t){var n=t.getColorBy();if(!t.isColorBySeries()){var i=t.type+"-"+n,r=e.get(i);r||(r={},e.set(i,r)),Ct(t).scope=r}})),t.eachSeries((function(e){if(!e.isColorBySeries()&&!t.isSeriesFiltered(e)){var n=e.getRawData(),i={},r=e.getData(),a=Ct(e).scope,o=e.visualStyleAccessPath||"itemStyle",s=Et(e,o);r.each((function(t){var e=r.getRawIndex(t);i[e]=t})),n.each((function(t){var o=i[t],l=r.getItemVisual(o,"colorFromPalette");if(l){var u=r.ensureUniqueItemVisual(o,"style"),c=n.getName(t)||t+"",h=n.count();u[s]=e.getColorFromPalette(c,a,h)}}))}}))}},kt=n("2dc5"),Bt=n("76a5"),zt=n("8d32"),Vt=Math.PI;function Ft(t,e){e=e||{},a["i"](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 n=new kt["a"],i=new yt["a"]({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});n.add(i);var r,o=new Bt["a"]({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),s=new yt["a"]({style:{fill:"none"},textContent:o,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});return n.add(s),e.showSpinner&&(r=new zt["a"]({shape:{startAngle:-Vt/2,endAngle:-Vt/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001}),r.animateShape(!0).when(1e3,{endAngle:3*Vt/2}).start("circularInOut"),r.animateShape(!0).when(1e3,{startAngle:3*Vt/2}).delay(300).start("circularInOut"),n.add(r)),n.resize=function(){var n=o.getBoundingRect().width,a=e.showSpinner?e.spinnerRadius:0,l=(t.getWidth()-2*a-(e.showSpinner&&n?10:0)-n)/2-(e.showSpinner&&n?0:5+n/2)+(e.showSpinner?0:n/2)+(n?0:a),u=t.getHeight()/2;e.showSpinner&&r.setShape({cx:l,cy:u}),s.setShape({x:l-a,y:u-a,width:2*a,height:2*a}),i.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},n.resize(),n}var Gt=n("9fbc"),Ht=n("8918"),Ut=function(){function t(t,e,n,i){this._stageTaskMap=Object(a["f"])(),this.ecInstance=t,this.api=e,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}return t.prototype.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each((function(t){var e=t.overallTask;e&&e.dirty()}))},t.prototype.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,r=!e&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex,a=r?n.step:null,o=i&&i.modDataCount,s=null!=o?Math.ceil(o/a):null;return{step:a,modBy:s,modDataCount:o}}},t.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},t.prototype.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData(),r=i.count(),a=n.progressiveEnabled&&e.incrementalPrepareRender&&r>=n.threshold,o=t.get("large")&&r>=t.get("largeThreshold"),s="mod"===t.get("progressiveChunkMode")?r:null;t.pipelineContext=n.context={progressiveRender:a,modDataCount:s,large:o}},t.prototype.restorePipelines=function(t){var e=this,n=e._pipelineMap=Object(a["f"])();t.eachSeries((function(t){var i=t.getProgressive(),r=t.uid;n.set(r,{id:r,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:i&&!(t.preventIncremental&&t.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),e._pipe(t,t.dataTask)}))},t.prototype.prepareStageTasks=function(){var t=this._stageTaskMap,e=this.api.getModel(),n=this.api;Object(a["k"])(this._allHandlers,(function(i){var r=t.get(i.uid)||t.set(i.uid,{}),o="";Object(a["b"])(!(i.reset&&i.overallReset),o),i.reset&&this._createSeriesStageTask(i,r,e,n),i.overallReset&&this._createOverallStageTask(i,r,e,n)}),this)},t.prototype.prepareView=function(t,e,n,i){var r=t.renderTask,a=r.context;a.model=e,a.ecModel=n,a.api=i,r.__block=!t.incrementalPrepareRender,this._pipe(e,r)},t.prototype.performDataProcessorTasks=function(t,e){this._performStageTasks(this._dataProcessorHandlers,t,e,{block:!0})},t.prototype.performVisualTasks=function(t,e,n){this._performStageTasks(this._visualHandlers,t,e,n)},t.prototype._performStageTasks=function(t,e,n,i){i=i||{};var r=!1,o=this;function s(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}Object(a["k"])(t,(function(t,a){if(!i.visualType||i.visualType===t.visualType){var l=o._stageTaskMap.get(t.uid),u=l.seriesTaskMap,c=l.overallTask;if(c){var h,d=c.agentStubMap;d.each((function(t){s(i,t)&&(t.dirty(),h=!0)})),h&&c.dirty(),o.updatePayload(c,n);var f=o.getPerformArgs(c,i.block);d.each((function(t){t.perform(f)})),c.perform(f)&&(r=!0)}else u&&u.each((function(a,l){s(i,a)&&a.dirty();var u=o.getPerformArgs(a,i.block);u.skip=!t.performRawSeries&&e.isSeriesFiltered(a.context.model),o.updatePayload(a,n),a.perform(u)&&(r=!0)}))}})),this.unfinished=r||this.unfinished},t.prototype.performSeriesTasks=function(t){var e;t.eachSeries((function(t){e=t.dataTask.perform()||e})),this.unfinished=e||this.unfinished},t.prototype.plan=function(){this._pipelineMap.each((function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)}))},t.prototype.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)},t.prototype._createSeriesStageTask=function(t,e,n,i){var r=this,o=e.seriesTaskMap,s=e.seriesTaskMap=Object(a["f"])(),l=t.seriesType,u=t.getTargetSeries;function c(e){var a=e.uid,l=s.set(a,o&&o.get(a)||Object(Gt["a"])({plan:Yt,reset:Kt,count:$t}));l.context={model:e,ecModel:n,api:i,useClearVisual:t.isVisual&&!t.isLayout,plan:t.plan,reset:t.reset,scheduler:r},r._pipe(e,l)}t.createOnAllSeries?n.eachRawSeries(c):l?n.eachRawSeriesByType(l,c):u&&u(n,i).each(c)},t.prototype._createOverallStageTask=function(t,e,n,i){var r=this,o=e.overallTask=e.overallTask||Object(Gt["a"])({reset:Wt});o.context={ecModel:n,api:i,overallReset:t.overallReset,scheduler:r};var s=o.agentStubMap,l=o.agentStubMap=Object(a["f"])(),u=t.seriesType,c=t.getTargetSeries,h=!0,d=!1,f="";function p(t){var e=t.uid,n=l.set(e,s&&s.get(e)||(d=!0,Object(Gt["a"])({reset:Xt,onDirty:qt})));n.context={model:t,overallProgress:h},n.agent=o,n.__block=h,r._pipe(t,n)}Object(a["b"])(!t.createOnAllSeries,f),u?n.eachRawSeriesByType(u,p):c?c(n,i).each(p):(h=!1,Object(a["k"])(n.getSeries(),p)),d&&o.dirty()},t.prototype._pipe=function(t,e){var n=t.uid,i=this._pipelineMap.get(n);!i.head&&(i.head=e),i.tail&&i.tail.pipe(e),i.tail=e,e.__idxInPipeline=i.count++,e.__pipeline=i},t.wrapStageHandler=function(t,e){return Object(a["w"])(t)&&(t={overallReset:t,seriesType:te(t)}),t.uid=Object(Ht["c"])("stageHandler"),e&&(t.visualType=e),t},t}();function Wt(t){t.overallReset(t.ecModel,t.api,t.payload)}function Xt(t){return t.overallProgress&&Zt}function Zt(){this.agent.dirty(),this.getDownstream().dirty()}function qt(){this.agent&&this.agent.dirty()}function Yt(t){return t.plan?t.plan(t.model,t.ecModel,t.api,t.payload):null}function Kt(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=Object(u["r"])(t.reset(t.model,t.ecModel,t.api,t.payload));return e.length>1?Object(a["H"])(e,(function(t,e){return Jt(e)})):Qt}var Qt=Jt(0);function Jt(t){return function(e,n){var i=n.data,r=n.resetDefines[t];if(r&&r.dataEach)for(var a=e.start;a0&&c===r.length-u.length){var h=r.slice(0,c);"data"!==h&&(e.mainType=h,e[u.toLowerCase()]=t,a=!0)}}s.hasOwnProperty(r)&&(n[r]=t,a=!0),a||(i[r]=t)}))}return{cptQuery:e,dataQuery:n,otherQuery:i}},t.prototype.filter=function(t,e){var n=this.eventInfo;if(!n)return!0;var i=n.targetEl,r=n.packedEvent,a=n.model,o=n.view;if(!a||!o)return!0;var s=e.cptQuery,l=e.dataQuery;return u(s,a,"mainType")&&u(s,a,"subType")&&u(s,a,"index","componentIndex")&&u(s,a,"name")&&u(s,a,"id")&&u(l,r,"name")&&u(l,r,"dataIndex")&&u(l,r,"dataType")&&(!o.filterForExposedEvent||o.filterForExposedEvent(t,e.otherQuery,i,r));function u(t,e,n,i){return null==t[n]||e[i||n]===t[n]}},t.prototype.afterTrigger=function(){this.eventInfo=null},t}(),me=["symbol","symbolSize","symbolRotate","symbolOffset"],ve=me.concat(["symbolKeepAspect"]),ye={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var n=t.getData();if(t.legendIcon&&n.setVisual("legendIcon",t.legendIcon),t.hasSymbolVisual){for(var i={},r={},o=!1,s=0;s0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,e,n){if(!this[Ye])if(this._disposed)Dn(this.id);else{var i,r,o;if(Object(a["A"])(e)&&(n=e.lazyUpdate,i=e.silent,r=e.replaceMerge,o=e.transition,e=e.notMerge),this[Ye]=!0,!this._model||e){var s=new F(this._api),l=this._theme,u=this._model=new D;u.scheduler=this._scheduler,u.ssr=this._ssr,u.init(null,null,null,l,this._locale,s)}this._model.setOption(t,{replaceMerge:r},Pn);var c={seriesTransition:o,optionChanged:!0};if(n)this[Ke]={silent:i,updateParams:c},this[Ye]=!1,this.getZr().wakeUp();else{try{sn(this),cn.update.call(this,null,c)}catch(h){throw this[Ke]=null,this[Ye]=!1,h}this._ssr||this._zr.flush(),this[Ke]=null,this[Ye]=!1,pn.call(this,i),gn.call(this,i)}}},e.prototype.setTheme=function(){Object(x["a"])("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},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||Le&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var e=this._zr.painter;return e.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var e=this._zr.painter;return e.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){if(o["a"].svgSupported){var t=this._zr,e=t.storage.getDisplayList();return Object(a["k"])(e,(function(t){t.stopAnimation(null,!0)})),t.painter.toDataURL()}},e.prototype.getDataURL=function(t){if(!this._disposed){t=t||{};var e=t.excludeComponents,n=this._model,i=[],r=this;Object(a["k"])(e,(function(t){n.eachComponent({mainType:t},(function(t){var e=r._componentsMap[t.__viewId];e.group.ignore||(i.push(e),e.group.ignore=!0)}))}));var o="svg"===this._zr.painter.getType()?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return Object(a["k"])(i,(function(t){t.group.ignore=!1})),o}Dn(this.id)},e.prototype.getConnectedDataURL=function(t){if(!this._disposed){var e="svg"===t.type,n=this.group,i=Math.min,o=Math.max,s=1/0;if(zn[n]){var l=s,u=s,c=-s,h=-s,d=[],f=t&&t.pixelRatio||this.getDevicePixelRatio();Object(a["k"])(Bn,(function(r,s){if(r.group===n){var f=e?r.getZr().painter.getSvgDom().innerHTML:r.renderToCanvas(Object(a["d"])(t)),p=r.getDom().getBoundingClientRect();l=i(p.left,l),u=i(p.top,u),c=o(p.right,c),h=o(p.bottom,h),d.push({dom:f,left:p.left,top:p.top})}})),l*=f,u*=f,c*=f,h*=f;var p=c-l,g=h-u,m=Ie["d"].createCanvas(),v=r["init"](m,{renderer:e?"svg":"canvas"});if(v.resize({width:p,height:g}),e){var y="";return Object(a["k"])(d,(function(t){var e=t.left-l,n=t.top-u;y+=''+t.dom+""})),v.painter.getSvgRoot().innerHTML=y,t.connectedBackgroundColor&&v.painter.setBackgroundColor(t.connectedBackgroundColor),v.refreshImmediately(),v.painter.toDataURL()}return t.connectedBackgroundColor&&v.add(new yt["a"]({shape:{x:0,y:0,width:p,height:g},style:{fill:t.connectedBackgroundColor}})),Object(a["k"])(d,(function(t){var e=new _t["a"]({style:{x:t.left*f-l,y:t.top*f-u,image:t.dom}});v.add(e)})),v.refreshImmediately(),m.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}Dn(this.id)},e.prototype.convertToPixel=function(t,e){return hn(this,"convertToPixel",t,e)},e.prototype.convertFromPixel=function(t,e){return hn(this,"convertFromPixel",t,e)},e.prototype.containPixel=function(t,e){if(!this._disposed){var n,i=this._model,r=u["s"](i,t);return Object(a["k"])(r,(function(t,i){i.indexOf("Models")>=0&&Object(a["k"])(t,(function(t){var r=t.coordinateSystem;if(r&&r.containPoint)n=n||!!r.containPoint(e);else if("seriesModels"===i){var a=this._chartsMap[t.__viewId];a&&a.containPoint&&(n=n||a.containPoint(e,t))}else 0}),this)}),this),!!n}Dn(this.id)},e.prototype.getVisual=function(t,e){var n=this._model,i=u["s"](n,t,{defaultMainType:"series"}),r=i.seriesModel;var a=r.getData(),o=i.hasOwnProperty("dataIndexInside")?i.dataIndexInside:i.hasOwnProperty("dataIndex")?a.indexOfRawIndex(i.dataIndex):null;return null!=o?Object(be["a"])(a,o,e):Object(be["b"])(a,e)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t=this;Object(a["k"])(In,(function(e){var n=function(n){var i,r=t.getModel(),o=n.target,s="globalout"===e;if(s?i={}:o&&Object(Se["a"])(o,(function(t){var e=Object(wt["a"])(t);if(e&&null!=e.dataIndex){var n=e.dataModel||r.getSeriesByIndex(e.seriesIndex);return i=n&&n.getDataParams(e.dataIndex,e.dataType)||{},!0}if(e.eventData)return i=Object(a["m"])({},e.eventData),!0}),!0),i){var l=i.componentType,u=i.componentIndex;"markLine"!==l&&"markPoint"!==l&&"markArea"!==l||(l="series",u=i.seriesIndex);var c=l&&null!=u&&r.getComponent(l,u),h=c&&t["series"===c.mainType?"_chartsMap":"_componentsMap"][c.__viewId];0,i.event=n,i.type=e,t._$eventProcessor.eventInfo={targetEl:o,packedEvent:i,model:c,view:h},t.trigger(e,i)}};n.zrEventfulCallAtLast=!0,t._zr.on(e,n,t)})),Object(a["k"])(En,(function(e,n){t._messageCenter.on(n,(function(t){this.trigger(n,t)}),t)})),Object(a["k"])(["selectchanged"],(function(e){t._messageCenter.on(e,(function(t){this.trigger(e,t)}),t)})),Object(xe["b"])(this._messageCenter,this,this._api)},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){this._disposed?Dn(this.id):this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed)Dn(this.id);else{this._disposed=!0;var t=this.getDom();t&&u["w"](this.getDom(),Fn,"");var e=this,n=e._api,i=e._model;Object(a["k"])(e._componentsViews,(function(t){t.dispose(i,n)})),Object(a["k"])(e._chartsViews,(function(t){t.dispose(i,n)})),e._zr.dispose(),e._dom=e._model=e._chartsMap=e._componentsMap=e._chartsViews=e._componentsViews=e._scheduler=e._api=e._zr=e._throttledZrFlush=e._theme=e._coordSysMgr=e._messageCenter=null,delete Bn[e.id]}},e.prototype.resize=function(t){if(!this[Ye])if(this._disposed)Dn(this.id);else{this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media"),i=t&&t.silent;this[Ke]&&(null==i&&(i=this[Ke].silent),n=!0,this[Ke]=null),this[Ye]=!0;try{n&&sn(this),cn.update.call(this,{type:"resize",animation:Object(a["m"])({duration:0},t&&t.animation)})}catch(r){throw this[Ye]=!1,r}this[Ye]=!1,pn.call(this,i),gn.call(this,i)}}},e.prototype.showLoading=function(t,e){if(this._disposed)Dn(this.id);else if(Object(a["A"])(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),kn[t]){var n=kn[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},e.prototype.hideLoading=function(){this._disposed?Dn(this.id):(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},e.prototype.makeActionFromEvent=function(t){var e=Object(a["m"])({},t);return e.type=En[t.type],e},e.prototype.dispatchAction=function(t,e){if(this._disposed)Dn(this.id);else if(Object(a["A"])(e)||(e={silent:!!e}),Ln[t.type]&&this._model)if(this[Ye])this._pendingActions.push(t);else{var n=e.silent;fn.call(this,t,n);var i=e.flush;i?this._zr.flush():!1!==i&&o["a"].browser.weChat&&this._throttledZrFlush(),pn.call(this,n),gn.call(this,n)}},e.prototype.updateLabelLayout=function(){Ce.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed)Dn(this.id);else{var e=t.seriesIndex,n=this.getModel(),i=n.getSeriesByIndex(e);0,i.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()}},e.internalField=function(){function t(t){t.clearColorPalette(),t.eachSeries((function(t){t.clearColorPalette()}))}function e(t){var e=[],n=[],i=!1;if(t.eachComponent((function(t,r){var a=r.get("zlevel")||0,o=r.get("z")||0,s=r.getZLevelKey();i=i||!!s,("series"===t?n:e).push({zlevel:a,z:o,idx:r.componentIndex,type:t,key:s})})),i){var r,o,l=e.concat(n);Object(s["a"])(l,(function(t,e){return t.zlevel===e.zlevel?t.z-e.z:t.zlevel-e.zlevel})),Object(a["k"])(l,(function(e){var n=t.getComponent(e.type,e.idx),i=e.zlevel,a=e.key;null!=r&&(i=Math.max(r,i)),a?(i===r&&a!==o&&i++,o=a):o&&(i===r&&i++,o=""),r=i,n.setZLevel(i)}))}}function n(t){for(var e=[],n=t.currentStates,i=0;ie.get("hoverLayerThreshold")&&!o["a"].node&&!o["a"].worker&&e.eachSeries((function(e){if(!e.preventUsingHoverLayer){var n=t._chartsMap[e.__viewId];n.__alive&&n.eachRendered((function(t){t.states.emphasis&&(t.states.emphasis.hoverLayer=!0)}))}}))}function l(t,e){var n=t.get("blendMode")||null;e.eachRendered((function(t){t.isGroup||(t.style.blend=n)}))}function c(t,e){if(!t.preventAutoZ){var n=t.get("z")||0,i=t.get("zlevel")||0;e.eachRendered((function(t){return h(t,n,i,-1/0),!0}))}}function h(t,e,n,i){var r=t.getTextContent(),a=t.getTextGuideLine(),o=t.isGroup;if(o)for(var s=t.childrenRef(),l=0;l0?{duration:a,delay:i.get("delay"),easing:i.get("easing")}:null;e.eachRendered((function(t){if(t.states&&t.states.emphasis){if(bt["d"](t))return;if(t instanceof xt["b"]&&Object(Ot["E"])(t),t.__dirty){var e=t.prevStates;e&&t.useStates(e)}if(r){t.stateTransition=o;var i=t.getTextContent(),a=t.getTextGuideLine();i&&(i.stateTransition=o),a&&(a.stateTransition=o)}t.__dirty&&n(t)}}))}sn=function(t){var e=t._scheduler;e.restorePipelines(t._model),e.prepareStageTasks(),ln(t,!0),ln(t,!1),e.plan()},ln=function(t,e){for(var n=t._model,i=t._scheduler,r=e?t._componentsViews:t._chartsViews,a=e?t._componentsMap:t._chartsMap,o=t._zr,s=t._api,l=0;l=0)){ei.push(n);var o=ae.wrapStageHandler(n,r);o.__prio=e,o.__raw=n,t.push(o)}}function ii(t,e){kn[t]=e}function ri(t,e,n){var i=Object(De["a"])("registerMap");i&&i(t,e,n)}function ai(t){var e=Object(De["a"])("getMap");return e&&e(t)}var oi=we["b"];ti(Ve,jt),ti(He,Nt),ti(He,Rt),ti(Ve,ye),ti(He,_e),ti(Ze,Me),Wn(ht),Xn(Pe,ft),ii("default",Ft),Kn({type:Ot["c"],event:Ot["c"],update:Ot["c"]},a["L"]),Kn({type:Ot["b"],event:Ot["b"],update:Ot["b"]},a["L"]),Kn({type:Ot["f"],event:Ot["f"],update:Ot["f"]},a["L"]),Kn({type:Ot["i"],event:Ot["i"],update:Ot["i"]},a["L"]),Kn({type:Ot["h"],event:Ot["h"],update:Ot["h"]},a["L"]),Un("light",se),Un("dark",fe)},"1f39":function(t,e,n){"use strict";var i=n("6d8b"),r={},a=function(){function t(){this._coordinateSystems=[]}return t.prototype.create=function(t,e){var n=[];i["k"](r,(function(i,r){var a=i.create(t,e);n=n.concat(a||[])})),this._coordinateSystems=n},t.prototype.update=function(t,e){i["k"](this._coordinateSystems,(function(n){n.update&&n.update(t,e)}))},t.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},t.register=function(t,e){r[t]=e},t.get=function(t){return r[t]},t}();e["a"]=a},2023:function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var i=function(){function t(){}return t.prototype.getNeedCrossZero=function(){var t=this.option;return!t.scale},t.prototype.getCoordSysModel=function(){},t}()},"20c8":function(t,e,n){"use strict";n.d(e,"b",(function(){return T}));var i=n("401b"),r=n("9850"),a=n("2cf4"),o=n("e263"),s=n("4a3f"),l={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},u=[],c=[],h=[],d=[],f=[],p=[],g=Math.min,m=Math.max,v=Math.cos,y=Math.sin,_=Math.abs,b=Math.PI,x=2*b,w="undefined"!==typeof Float32Array,O=[];function S(t){var e=Math.round(t/b*1e8)/1e8;return e%2*b}function T(t,e){var n=S(t[0]);n<0&&(n+=x);var i=n-t[0],r=t[1];r+=i,!e&&r-n>=x?r=n+x:e&&n-r>=x?r=n-x:!e&&n>r?r=n+(x-S(n-r)):e&&n0&&(this._ux=_(n/a["e"]/t)||0,this._uy=_(n/a["e"]/e)||0)},t.prototype.setDPR=function(t){this.dpr=t},t.prototype.setContext=function(t){this._ctx=t},t.prototype.getContext=function(){return this._ctx},t.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},t.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},t.prototype.moveTo=function(t,e){return this._drawPendingPt(),this.addData(l.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},t.prototype.lineTo=function(t,e){var n=_(t-this._xi),i=_(e-this._yi),r=n>this._ux||i>this._uy;if(this.addData(l.L,t,e),this._ctx&&r&&this._ctx.lineTo(t,e),r)this._xi=t,this._yi=e,this._pendingPtDist=0;else{var a=n*n+i*i;a>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=e,this._pendingPtDist=a)}return this},t.prototype.bezierCurveTo=function(t,e,n,i,r,a){return this._drawPendingPt(),this.addData(l.C,t,e,n,i,r,a),this._ctx&&this._ctx.bezierCurveTo(t,e,n,i,r,a),this._xi=r,this._yi=a,this},t.prototype.quadraticCurveTo=function(t,e,n,i){return this._drawPendingPt(),this.addData(l.Q,t,e,n,i),this._ctx&&this._ctx.quadraticCurveTo(t,e,n,i),this._xi=n,this._yi=i,this},t.prototype.arc=function(t,e,n,i,r,a){this._drawPendingPt(),O[0]=i,O[1]=r,T(O,a),i=O[0],r=O[1];var o=r-i;return this.addData(l.A,t,e,n,n,i,o,0,a?0:1),this._ctx&&this._ctx.arc(t,e,n,i,r,a),this._xi=v(r)*n+t,this._yi=y(r)*n+e,this},t.prototype.arcTo=function(t,e,n,i,r){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,e,n,i,r),this},t.prototype.rect=function(t,e,n,i){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,e,n,i),this.addData(l.R,t,e,n,i),this},t.prototype.closePath=function(){this._drawPendingPt(),this.addData(l.Z);var t=this._ctx,e=this._x0,n=this._y0;return t&&t.closePath(),this._xi=e,this._yi=n,this},t.prototype.fill=function(t){t&&t.fill(),this.toStatic()},t.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},t.prototype.len=function(){return this._len},t.prototype.setData=function(t){var e=t.length;this.data&&this.data.length===e||!w||(this.data=new Float32Array(e));for(var n=0;nu.length&&(this._expandData(),u=this.data);for(var c=0;c0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},t.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e11&&(this.data=new Float32Array(t)))}},t.prototype.getBoundingRect=function(){h[0]=h[1]=f[0]=f[1]=Number.MAX_VALUE,d[0]=d[1]=p[0]=p[1]=-Number.MAX_VALUE;var t,e=this.data,n=0,a=0,s=0,u=0;for(t=0;tn||_(M)>i||f===e-1)&&(w=Math.sqrt(T*T+M*M),r=O,a=S);break;case l.C:var A=t[f++],C=t[f++],I=(O=t[f++],S=t[f++],t[f++]),D=t[f++];w=Object(s["d"])(r,a,A,C,O,S,I,D,10),r=I,a=D;break;case l.Q:A=t[f++],C=t[f++],O=t[f++],S=t[f++];w=Object(s["k"])(r,a,A,C,O,S,10),r=O,a=S;break;case l.A:var L=t[f++],E=t[f++],j=t[f++],P=t[f++],N=t[f++],R=t[f++],k=R+N;f+=1;t[f++];b&&(o=v(N)*j+L,u=y(N)*P+E),w=m(j,P)*g(x,Math.abs(R)),r=v(k)*j+L,a=y(k)*P+E;break;case l.R:o=r=t[f++],u=a=t[f++];var B=t[f++],z=t[f++];w=2*B+2*z;break;case l.Z:T=o-r,M=u-a;w=Math.sqrt(T*T+M*M),r=o,a=u;break}w>=0&&(c[d++]=w,h+=w)}return this._pathLen=h,h},t.prototype.rebuildPath=function(t,e){var n,i,r,a,o,h,d,f,p,b,x,w=this.data,O=this._ux,S=this._uy,T=this._len,M=e<1,A=0,C=0,I=0;if(!M||(this._pathSegLen||this._calculateLength(),d=this._pathSegLen,f=this._pathLen,p=e*f,p))t:for(var D=0;D0&&(t.lineTo(b,x),I=0),L){case l.M:n=r=w[D++],i=a=w[D++],t.moveTo(r,a);break;case l.L:o=w[D++],h=w[D++];var j=_(o-r),P=_(h-a);if(j>O||P>S){if(M){var N=d[C++];if(A+N>p){var R=(p-A)/N;t.lineTo(r*(1-R)+o*R,a*(1-R)+h*R);break t}A+=N}t.lineTo(o,h),r=o,a=h,I=0}else{var k=j*j+P*P;k>I&&(b=o,x=h,I=k)}break;case l.C:var B=w[D++],z=w[D++],V=w[D++],F=w[D++],G=w[D++],H=w[D++];if(M){N=d[C++];if(A+N>p){R=(p-A)/N;Object(s["g"])(r,B,V,G,R,u),Object(s["g"])(a,z,F,H,R,c),t.bezierCurveTo(u[1],c[1],u[2],c[2],u[3],c[3]);break t}A+=N}t.bezierCurveTo(B,z,V,F,G,H),r=G,a=H;break;case l.Q:B=w[D++],z=w[D++],V=w[D++],F=w[D++];if(M){N=d[C++];if(A+N>p){R=(p-A)/N;Object(s["n"])(r,B,V,R,u),Object(s["n"])(a,z,F,R,c),t.quadraticCurveTo(u[1],c[1],u[2],c[2]);break t}A+=N}t.quadraticCurveTo(B,z,V,F),r=V,a=F;break;case l.A:var U=w[D++],W=w[D++],X=w[D++],Z=w[D++],q=w[D++],Y=w[D++],K=w[D++],Q=!w[D++],J=X>Z?X:Z,$=_(X-Z)>.001,tt=q+Y,et=!1;if(M){N=d[C++];A+N>p&&(tt=q+Y*(p-A)/N,et=!0),A+=N}if($&&t.ellipse?t.ellipse(U,W,X,Z,K,q,tt,Q):t.arc(U,W,J,q,tt,Q),et)break t;E&&(n=v(q)*X+U,i=y(q)*Z+W),r=v(tt)*X+U,a=y(tt)*Z+W;break;case l.R:n=r=w[D],i=a=w[D+1],o=w[D++],h=w[D++];var nt=w[D++],it=w[D++];if(M){N=d[C++];if(A+N>p){var rt=p-A;t.moveTo(o,h),t.lineTo(o+g(rt,nt),h),rt-=nt,rt>0&&t.lineTo(o+nt,h+g(rt,it)),rt-=it,rt>0&&t.lineTo(o+m(nt-rt,0),h+it),rt-=nt,rt>0&&t.lineTo(o,h+m(it-rt,0));break t}A+=N}t.rect(o,h,nt,it);break;case l.Z:if(M){N=d[C++];if(A+N>p){R=(p-A)/N;t.lineTo(r*(1-R)+n*R,a*(1-R)+i*R);break t}A+=N}t.closePath(),r=n,a=i}}},t.prototype.clone=function(){var e=new t,n=this.data;return e.data=n.slice?n.slice():Array.prototype.slice.call(n),e._len=this._len,e},t.CMD=l,t.initDefaultProps=function(){var e=t.prototype;e._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0}(),t}();e["a"]=M},"216a":function(t,e,n){"use strict";var i=n("7fae"),r=n("3842"),a=n("f876"),o=n("944e"),s=n("89e3"),l=n("e0d8"),u=n("6d8b"),c=function(t,e,n,i){while(n>>1;t[r][1]n&&(this._approxInterval=n);var a=d.length,o=Math.min(c(d,this._approxInterval,0,a),a-1);this._interval=d[o][1],this._minLevelUnit=d[Math.max(o-1,0)][0]},e.prototype.parse=function(t){return Object(u["z"])(t)?t:+r["o"](t)},e.prototype.contain=function(t){return o["a"](this.parse(t),this._extent)},e.prototype.normalize=function(t){return o["f"](this.parse(t),this._extent)},e.prototype.scale=function(t){return o["g"](t,this._extent)},e.type="time",e}(s["a"]),d=[["second",a["d"]],["minute",a["c"]],["hour",a["b"]],["quarter-day",6*a["b"]],["half-day",12*a["b"]],["day",1.2*a["a"]],["half-week",3.5*a["a"]],["week",7*a["a"]],["month",31*a["a"]],["quarter",95*a["a"]],["half-year",a["e"]/2],["year",a["e"]]];function f(t,e,n,i){var o=r["o"](e),s=r["o"](n),l=function(t){return Object(a["n"])(o,t,i)===Object(a["n"])(s,t,i)},u=function(){return l("year")},c=function(){return u()&&l("month")},h=function(){return c()&&l("day")},d=function(){return h()&&l("hour")},f=function(){return d()&&l("minute")},p=function(){return f()&&l("second")},g=function(){return p()&&l("millisecond")};switch(t){case"year":return u();case"month":return c();case"day":return h();case"hour":return d();case"minute":return f();case"second":return p();case"millisecond":return g()}}function p(t,e){return t/=a["a"],t>16?16:t>7.5?7:t>3.5?4:t>1.5?2:1}function g(t){var e=30*a["a"];return t/=e,t>6?6:t>3?3:t>2?2:1}function m(t){return t/=a["b"],t>12?12:t>6?6:t>3.5?4:t>2?2:1}function v(t,e){return t/=e?a["c"]:a["d"],t>30?30:t>20?20:t>15?15:t>10?10:t>5?5:t>2?2:1}function y(t){return r["m"](t,!0)}function _(t,e,n){var i=new Date(t);switch(Object(a["m"])(e)){case"year":case"month":i[Object(a["x"])(n)](0);case"day":i[Object(a["g"])(n)](1);case"hour":i[Object(a["p"])(n)](0);case"minute":i[Object(a["v"])(n)](0);case"second":i[Object(a["A"])(n)](0),i[Object(a["t"])(n)](0)}return i.getTime()}function b(t,e,n,i){var r=1e4,o=a["B"],s=0;function l(t,e,n,r,a,o,s){var l=new Date(e),u=e,c=l[r]();while(u1&&0===c&&o.unshift({value:o[0].value-b})}}for(c=0;c=i[0]&&A<=i[1]&&b++)}var C=(i[1]-i[0])/e;if(b>1.5*C&&x>C/1.5)break;if(h.push(T),b>C||t===o[w])break}d=[]}}}var I=Object(u["n"])(Object(u["H"])(h,(function(t){return Object(u["n"])(t,(function(t){return t.value>=i[0]&&t.value<=i[1]&&!t.notAdd}))})),(function(t){return t.length>0})),D=[],L=I.length-1;for(w=0;w1||n>0&&!t.noHeader;return Object(r["k"])(t.blocks,(function(t){var n=p(t);n>=e&&(e=n+ +(i&&(!n||d(t)&&!t.noHeader)))})),e}return 0}function g(t,e,n,o){var u=e.noHeader,c=y(p(e)),h=[],d=e.blocks||[];Object(r["b"])(!d||Object(r["t"])(d)),d=d||[];var g=t.orderMode;if(e.sortBlocks&&g){d=d.slice();var m={valueAsc:"asc",valueDesc:"desc"};if(Object(r["q"])(m,g)){var v=new a["a"](m[g],null);d.sort((function(t,e){return v.evaluate(t.sortParam,e.sortParam)}))}else"seriesDesc"===g&&d.reverse()}Object(r["k"])(d,(function(n,i){var a=e.valueFormatter,s=f(n)(a?Object(r["m"])(Object(r["m"])({},t),{valueFormatter:a}):t,n,i>0?c.html:0,o);null!=s&&h.push(s)}));var b="richText"===t.renderMode?h.join(c.richText):_(h.join(""),u?n:c.html);if(u)return b;var x=Object(i["i"])(e.header,"ordinal",t.useUTC),O=l(o,t.renderMode).nameStyle;return"richText"===t.renderMode?w(t,x,O)+c.richText+b:_('
'+Object(i["d"])(x)+"
"+b,n)}function m(t,e,n,a){var o=t.renderMode,s=e.noName,u=e.noValue,c=!e.markerType,h=e.name,d=t.useUTC,f=e.valueFormatter||t.valueFormatter||function(t){return t=Object(r["t"])(t)?t:[t],Object(r["H"])(t,(function(t,e){return Object(i["i"])(t,Object(r["t"])(m)?m[e]:m,d)}))};if(!s||!u){var p=c?"":t.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",o),g=s?"":Object(i["i"])(h,"ordinal",d),m=e.valueType,v=u?[]:f(e.value),y=!c||!s,S=!c&&s,T=l(a,o),M=T.nameStyle,A=T.valueStyle;return"richText"===o?(c?"":p)+(s?"":w(t,g,M))+(u?"":O(t,v,y,S,A)):_((c?"":p)+(s?"":b(g,!c,M))+(u?"":x(v,y,S,A)),n)}}function v(t,e,n,i,r,a){if(t){var o=f(t),s={useUTC:r,renderMode:n,orderMode:i,markupStyleCreator:e,valueFormatter:t.valueFormatter};return o(s,t,0,a)}}function y(t){return{html:u[t],richText:c[t]}}function _(t,e){var n='
',i="margin: "+e+"px 0 0";return'
'+t+n+"
"}function b(t,e,n){var r=e?"margin-left:2px":"";return''+Object(i["d"])(t)+""}function x(t,e,n,a){var o=n?"10px":"20px",s=e?"float:right;margin-left:"+o:"";return t=Object(r["t"])(t)?t:[t],''+Object(r["H"])(t,(function(t){return Object(i["d"])(t)})).join("  ")+""}function w(t,e,n){return t.markupStyleCreator.wrapRichTextStyle(e,n)}function O(t,e,n,i,a){var o=[a],s=i?10:20;return n&&o.push({padding:[0,0,0,s],align:"right"}),t.markupStyleCreator.wrapRichTextStyle(Object(r["t"])(e)?e.join(" "):e,o)}function S(t,e){var n=t.getData().getItemVisual(e,"style"),r=n[t.visualDrawType];return Object(i["c"])(r)}function T(t,e){var n=t.get("padding");return null!=n?n:"richText"===e?[8,10]:10}var M=function(){function t(){this.richTextStyles={},this._nextStyleNameId=Object(o["i"])()}return t.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},t.prototype.makeTooltipMarker=function(t,e,n){var a="richText"===n?this._generateStyleName():null,o=Object(i["h"])({color:e,type:t,renderMode:n,markerId:a});return Object(r["C"])(o)?o:(this.richTextStyles[a]=o.style,o.content)},t.prototype.wrapRichTextStyle=function(t,e){var n={};Object(r["t"])(e)?Object(r["k"])(e,(function(t){return Object(r["m"])(n,t)})):Object(r["m"])(n,e);var i=this._generateStyleName();return this.richTextStyles[i]=n,"{"+i+"|"+t+"}"},t}()},"21a10":function(t,e,n){"use strict";n.d(e,"a",(function(){return r})); /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */ var i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)};function r(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}Object.create;Object.create},"22b4":function(t,e,n){"use strict";n.d(e,"a",(function(){return f}));var i=n("1be7"),r=n("b12f"),a=n("e887"),o=n("6cb7"),s=n("4f85"),l=n("6d8b"),u=n("58c9"),c=n("697e7"),h=[],d={registerPreprocessor:i["l"],registerProcessor:i["m"],registerPostInit:i["j"],registerPostUpdate:i["k"],registerUpdateLifecycle:i["o"],registerAction:i["e"],registerCoordinateSystem:i["f"],registerLayout:i["g"],registerVisual:i["p"],registerTransform:i["n"],registerLoading:i["h"],registerMap:i["i"],registerImpl:u["b"],PRIORITY:i["a"],ComponentModel:o["a"],ComponentView:r["a"],SeriesModel:s["b"],ChartView:a["a"],registerComponentModel:function(t){o["a"].registerClass(t)},registerComponentView:function(t){r["a"].registerClass(t)},registerSeriesModel:function(t){s["b"].registerClass(t)},registerChartView:function(t){a["a"].registerClass(t)},registerSubTypeDefaulter:function(t,e){o["a"].registerSubTypeDefaulter(t,e)},registerPainter:function(t,e){Object(c["registerPainter"])(t,e)}};function f(t){Object(l["t"])(t)?Object(l["k"])(t,(function(t){f(t)})):Object(l["r"])(h,t)>=0||(h.push(t),Object(l["w"])(t)&&(t={install:t}),t.install(d))}},"22d1":function(t,e,n){"use strict";var i=function(){function t(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return t}(),r=function(){function t(){this.browser=new i,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow="undefined"!==typeof window}return t}(),a=new r;function o(t,e){var n=e.browser,i=t.match(/Firefox\/([\d.]+)/),r=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),a=t.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(t);i&&(n.firefox=!0,n.version=i[1]),r&&(n.ie=!0,n.version=r[1]),a&&(n.edge=!0,n.version=a[1],n.newEdge=+a[1].split(".")[0]>18),o&&(n.weChat=!0),e.svgSupported="undefined"!==typeof SVGRect,e.touchEventsSupported="ontouchstart"in window&&!n.ie&&!n.edge,e.pointerEventsSupported="onpointerdown"in window&&(n.edge||n.ie&&+n.version>=11),e.domSupported="undefined"!==typeof document;var s=document.documentElement.style;e.transform3dSupported=(n.ie&&"transition"in s||n.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),e.transformSupported=e.transform3dSupported||n.ie&&+n.version>=9}"object"===typeof wx&&"function"===typeof wx.getSystemInfoSync?(a.wxa=!0,a.touchEventsSupported=!0):"undefined"===typeof document&&"undefined"!==typeof self?a.worker=!0:"undefined"===typeof navigator?(a.node=!0,a.svgSupported=!0):o(navigator.userAgent,a),e["a"]=a},2306:function(t,e,n){"use strict";n.r(e),n.d(e,"extendShape",(function(){return N})),n.d(e,"extendPath",(function(){return k})),n.d(e,"registerShape",(function(){return B})),n.d(e,"getShapeClass",(function(){return z})),n.d(e,"makePath",(function(){return V})),n.d(e,"makeImage",(function(){return F})),n.d(e,"mergePath",(function(){return H})),n.d(e,"resizePath",(function(){return U})),n.d(e,"subPixelOptimizeLine",(function(){return W})),n.d(e,"subPixelOptimizeRect",(function(){return X})),n.d(e,"subPixelOptimize",(function(){return Z})),n.d(e,"getTransform",(function(){return q})),n.d(e,"applyTransform",(function(){return Y})),n.d(e,"transformDirection",(function(){return K})),n.d(e,"groupTransition",(function(){return $})),n.d(e,"clipPointsByRect",(function(){return tt})),n.d(e,"clipRectByRect",(function(){return et})),n.d(e,"createIcon",(function(){return nt})),n.d(e,"linePolygonIntersect",(function(){return it})),n.d(e,"lineLineIntersect",(function(){return rt})),n.d(e,"setTooltipConfig",(function(){return st})),n.d(e,"traverseElements",(function(){return ut}));var i=n("342d"),r=n("1687"),a=n("401b"),o=n("cbe5");n.d(e,"Path",(function(){return o["b"]}));var s=n("8582"),l=n("0da8");n.d(e,"Image",(function(){return l["a"]}));var u=n("2dc5");n.d(e,"Group",(function(){return u["a"]}));var c=n("76a5");n.d(e,"Text",(function(){return c["a"]}));var h=n("d9fc");n.d(e,"Circle",(function(){return h["a"]}));var d=n("ae69");n.d(e,"Ellipse",(function(){return d["a"]}));var f=n("4aa2");n.d(e,"Sector",(function(){return f["a"]}));var p=n("4573");n.d(e,"Ring",(function(){return p["a"]}));var g=n("87b1");n.d(e,"Polygon",(function(){return g["a"]}));var m=n("d498");n.d(e,"Polyline",(function(){return m["a"]}));var v=n("c7a2");n.d(e,"Rect",(function(){return v["a"]}));var y=n("cb11");n.d(e,"Line",(function(){return y["a"]}));var _=n("ac0f");n.d(e,"BezierCurve",(function(){return _["a"]}));var b=n("8d32");n.d(e,"Arc",(function(){return b["a"]}));var x=n("d4c6");n.d(e,"CompoundPath",(function(){return x["a"]}));var w=n("48a9");n.d(e,"LinearGradient",(function(){return w["a"]}));var O=n("dded");n.d(e,"RadialGradient",(function(){return O["a"]}));var S=n("9850");n.d(e,"BoundingRect",(function(){return S["a"]}));var T=n("ca80");n.d(e,"OrientedBoundingRect",(function(){return T["a"]}));var M=n("dce8");n.d(e,"Point",(function(){return M["a"]}));var A=n("392f");n.d(e,"IncrementalDisplayable",(function(){return A["a"]}));var C=n("9cf9"),I=n("6d8b"),D=n("861c"),L=n("deab");n.d(e,"updateProps",(function(){return L["h"]})),n.d(e,"initProps",(function(){return L["c"]})),n.d(e,"removeElement",(function(){return L["e"]})),n.d(e,"removeElementWithFadeOut",(function(){return L["f"]})),n.d(e,"isElementRemoved",(function(){return L["d"]}));var E=Math.max,j=Math.min,P={};function N(t){return o["b"].extend(t)}var R=i["c"];function k(t,e){return R(t,e)}function B(t,e){P[t]=e}function z(t){if(P.hasOwnProperty(t))return P[t]}function V(t,e,n,r){var a=i["b"](t,e);return n&&("center"===r&&(n=G(n,a.getBoundingRect())),U(a,n)),a}function F(t,e,n){var i=new l["a"]({style:{image:t,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(t){if("center"===n){var r={width:t.width,height:t.height};i.setStyle(G(e,r))}}});return i}function G(t,e){var n,i=e.width/e.height,r=t.height*i;r<=t.width?n=t.height:(r=t.width,n=r/i);var a=t.x+t.width/2,o=t.y+t.height/2;return{x:a-r/2,y:o-n/2,width:r,height:n}}var H=i["d"];function U(t,e){if(t.applyTransform){var n=t.getBoundingRect(),i=n.calculateTransform(e);t.applyTransform(i)}}function W(t){return C["b"](t.shape,t.shape,t.style),t}function X(t){return C["c"](t.shape,t.shape,t.style),t}var Z=C["a"];function q(t,e){var n=r["d"]([]);while(t&&t!==e)r["f"](n,t.getLocalTransform(),n),t=t.parent;return n}function Y(t,e,n){return e&&!Object(I["u"])(e)&&(e=s["c"].getLocalTransform(e)),n&&(e=r["e"]([],e)),a["b"]([],t,e)}function K(t,e,n){var i=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),r=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),a=["left"===t?-i:"right"===t?i:0,"top"===t?-r:"bottom"===t?r:0];return a=Y(a,e,n),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function Q(t){return!t.isGroup}function J(t){return null!=t.shape}function $(t,e,n){if(t&&e){var i=r(t);e.traverse((function(t){if(Q(t)&&t.anid){var e=i[t.anid];if(e){var r=a(t);t.attr(a(e)),Object(L["h"])(t,r,n,Object(D["a"])(t).dataIndex)}}}))}function r(t){var e={};return t.traverse((function(t){Q(t)&&t.anid&&(e[t.anid]=t)})),e}function a(t){var e={x:t.x,y:t.y,rotation:t.rotation};return J(t)&&(e.shape=Object(I["m"])({},t.shape)),e}}function tt(t,e){return Object(I["H"])(t,(function(t){var n=t[0];n=E(n,e.x),n=j(n,e.x+e.width);var i=t[1];return i=E(i,e.y),i=j(i,e.y+e.height),[n,i]}))}function et(t,e){var n=E(t.x,e.x),i=j(t.x+t.width,e.x+e.width),r=E(t.y,e.y),a=j(t.y+t.height,e.y+e.height);if(i>=n&&a>=r)return{x:n,y:r,width:i-n,height:a-r}}function nt(t,e,n){var i=Object(I["m"])({rectHover:!0},e),r=i.style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(r.image=t.slice(8),Object(I["i"])(r,n),new l["a"](i)):V(t.replace("path://",""),i,n,"center")}function it(t,e,n,i,r){for(var a=0,o=r[r.length-1];a1)return!1;var m=at(f,p,c,h)/d;return!(m<0||m>1)}function at(t,e,n,i){return t*i-n*e}function ot(t){return t<=1e-6&&t>=-1e-6}function st(t){var e=t.itemTooltipOption,n=t.componentModel,i=t.itemName,r=Object(I["C"])(e)?{formatter:e}:e,a=n.mainType,o=n.componentIndex,s={componentType:a,name:i,$vars:["name"]};s[a+"Index"]=o;var l=t.formatterParamsExtra;l&&Object(I["k"])(Object(I["F"])(l),(function(t){Object(I["q"])(s,t)||(s[t]=l[t],s.$vars.push(t))}));var u=Object(D["a"])(t.el);u.componentMainType=a,u.componentIndex=o,u.tooltipConfig={name:i,option:Object(I["i"])({content:i,formatterParams:s},r)}}function lt(t,e){var n;t.isGroup&&(n=e(t)),n||t.traverse(e)}function ut(t,e){if(t)if(Object(I["t"])(t))for(var n=0;n0&&a&&w(-h/o,0,o);var m,v,y=t[0],_=t[o-1];return b(),m<0&&O(-m,.8),v<0&&O(v,.8),b(),x(m,v,1),x(v,m,-1),b(),m<0&&S(-m),v<0&&S(v),u}function b(){m=y.rect[e]-i,v=r-_.rect[e]-_.rect[n]}function x(t,e,n){if(t<0){var i=Math.min(e,-t);if(i>0){w(i*n,0,o);var r=i+t;r<0&&O(-r*n,1)}else O(-t*n,1)}}function w(n,i,r){0!==n&&(u=!0);for(var a=i;a0)for(l=0;l0;l--){d=a[l-1]*h;w(-d,l,o)}}}function S(t){var e=t<0?-1:1;t=Math.abs(t);for(var n=Math.ceil(t/(o-1)),i=0;i0?w(n,0,i+1):w(-n,o-i-1,o),t-=n,t<=0)return}}function s(t,e,n,i){return o(t,"x","width",e,n,i)}function l(t,e,n,i){return o(t,"y","height",e,n,i)}function u(t){var e=[];t.sort((function(t,e){return e.priority-t.priority}));var n=new r["a"](0,0,0,0);function a(t){if(!t.ignore){var e=t.ensureState("emphasis");null==e.ignore&&(e.ignore=!1)}t.ignore=!0}for(var o=0;o=0||a&&i["r"](a,l)<0)){var u=n.getShallow(l,e);null!=u&&(o[t[s][0]]=u)}}return o}}},"286b":function(t,e,n){},"2b17":function(t,e,n){"use strict";n.d(e,"a",(function(){return d})),n.d(e,"c",(function(){return g})),n.d(e,"b",(function(){return y})),n.d(e,"d",(function(){return x})),n.d(e,"e",(function(){return O}));var i,r,a,o,s,l=n("6d8b"),u=n("e0d3"),c=n("ec6f"),h=n("07fd"),d=function(){function t(t,e){var n=Object(c["e"])(t)?t:Object(c["c"])(t);this._source=n;var i=this._data=n.data;n.sourceFormat===h["g"]&&(this._offset=0,this._dimSize=e,this._data=i),s(this,i,n)}return t.prototype.getSource=function(){return this._source},t.prototype.count=function(){return 0},t.prototype.getItem=function(t,e){},t.prototype.appendData=function(t){},t.prototype.clean=function(){},t.protoInitialize=function(){var e=t.prototype;e.pure=!1,e.persistent=!0}(),t.internalField=function(){var t;s=function(t,r,a){var s=a.sourceFormat,u=a.seriesLayoutBy,c=a.startIndex,d=a.dimensionsDefine,f=o[w(s,u)];if(Object(l["m"])(t,f),s===h["g"])t.getItem=e,t.count=i,t.fillStorage=n;else{var p=g(s,u);t.getItem=Object(l["c"])(p,null,r,c,d);var m=y(s,u);t.count=Object(l["c"])(m,null,r,c,d)}};var e=function(t,e){t-=this._offset,e=e||[];for(var n=this._data,i=this._dimSize,r=i*t,a=0;au&&(u=f)}s[0]=l,s[1]=u}},i=function(){return this._data?this._data.length/this._dimSize:0};function r(t){for(var e=0;e=0&&(n.splice(i,0,t),this._doAdd(t))}return this},e.prototype.replace=function(t,e){var n=r["r"](this._children,t);return n>=0&&this.replaceAt(e,n),this},e.prototype.replaceAt=function(t,e){var n=this._children,i=n[e];if(t&&t!==this&&t.parent!==this&&t!==i){n[e]=t,i.parent=null;var r=this.__zr;r&&i.removeSelfFromZr(r),this._doAdd(t)}return this},e.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var e=this.__zr;e&&e!==t.__zr&&t.addSelfToZr(e),e&&e.refresh()},e.prototype.remove=function(t){var e=this.__zr,n=this._children,i=r["r"](n,t);return i<0||(n.splice(i,1),t.parent=null,e&&t.removeSelfFromZr(e),e&&e.refresh()),this},e.prototype.removeAll=function(){for(var t=this._children,e=this.__zr,n=0;n=p:-u>=p),y=u>0?u%p:u%p+p,_=!1;_=!!v||!Object(o["j"])(m)&&y>=f===!!c;var b=t+n*d(a),x=e+i*h(a);this._start&&this._add("M",b,x);var w=Math.round(r*g);if(v){var O=1/this._p,S=(c?1:-1)*(p-O);this._add("A",n,i,w,1,+c,t+n*d(a+S),e+i*h(a+S)),O>.01&&this._add("A",n,i,w,0,+c,b,x)}else{var T=t+n*d(s),M=e+i*h(s);this._add("A",n,i,w,+_,+c,T,M)}},t.prototype.rect=function(t,e,n,i){this._add("M",t,e),this._add("l",n,0),this._add("l",0,i),this._add("l",-n,0),this._add("Z")},t.prototype.closePath=function(){this._d.length>0&&this._add("Z")},t.prototype._add=function(t,e,n,i,r,a,o,s,l){for(var u=[],c=this._p,h=1;h"}function P(t){return""}function N(t,e){e=e||{};var n=e.newline?"\n":"";function i(t){var e=t.children,r=t.tag,a=t.attrs;return j(r,a)+(t.text||"")+(e?""+n+Object(_["H"])(e,(function(t){return i(t)})).join(n)+n:"")+P(r)}return i(t)}function R(t,e,n){n=n||{};var i=n.newline?"\n":"",r=" {"+i,a=i+"}",o=Object(_["H"])(Object(_["F"])(t),(function(e){return e+r+Object(_["H"])(Object(_["F"])(t[e]),(function(n){return n+":"+t[e][n]+";"})).join(i)+a})).join(i),s=Object(_["H"])(Object(_["F"])(e),(function(t){return"@keyframes "+t+r+Object(_["H"])(Object(_["F"])(e[t]),(function(n){return n+r+Object(_["H"])(Object(_["F"])(e[t][n]),(function(i){var r=e[t][n][i];return"d"===i&&(r='path("'+r+'")'),i+":"+r+";"})).join(i)+a})).join(i)+a})).join(i);return o||s?[""].join(i):""}function k(t){return{zrId:t,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssClassIdx:0,cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function B(t,e,n,i){return E("svg","root",{width:t,height:e,xmlns:A,"xmlns:xlink":C,version:"1.1",baseProfile:"full",viewBox:!!i&&"0 0 "+t+" "+e},n)}var z=n("5e76"),V=n("8582"),F=n("20c8"),G=n("d4c6"),H=n("b362"),U={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},W="transform-origin";function X(t,e,n){var i=Object(_["m"])({},t.shape);Object(_["m"])(i,e),t.buildPath(n,i);var r=new v;return r.reset(Object(o["f"])(t)),n.rebuildPath(r,1),r.generateStr(),r.getStr()}function Z(t,e){var n=e.originX,i=e.originY;(n||i)&&(t[W]=n+"px "+i+"px")}var q={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function Y(t,e){var n=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[n]=t,n}function K(t,e,n){var i,r,a=t.shape.paths,o={};if(Object(_["k"])(a,(function(t){var e=k(n.zrId);e.animation=!0,J(t,{},e,!0);var a=e.cssAnims,s=e.cssNodes,l=Object(_["F"])(a),u=l.length;if(u){r=l[u-1];var c=a[r];for(var h in c){var d=c[h];o[h]=o[h]||{d:""},o[h].d+=d.d||""}for(var f in s){var p=s[f].animation;p.indexOf(r)>=0&&(i=p)}}})),i){e.d=!1;var s=Y(o,n);return i.replace(r,s)}}function Q(t){return Object(_["C"])(t)?U[t]?"cubic-bezier("+U[t]+")":Object(H["a"])(t)?t:"":""}function J(t,e,n,i){var r=t.animators,a=r.length,s=[];if(t instanceof G["a"]){var l=K(t,e,n);if(l)s.push(l);else if(!a)return}else if(!a)return;for(var u={},c=0;c0})).length){var L=Y(h,n);return L+" "+r[0]+" both"}}for(var v in u){l=m(u[v]);l&&s.push(l)}if(s.length){var y=n.zrId+"-cls-"+n.cssClassIdx++;n.cssNodes["."+y]={animation:s.join(",")},e["class"]=y}}var $=n("76a5"),tt=n("726e"),et=Math.round;function nt(t){return t&&Object(_["C"])(t.src)}function it(t){return t&&Object(_["w"])(t.toDataURL)}function rt(t,e,n,i){M((function(r,a){var s="fill"===r||"stroke"===r;s&&Object(o["k"])(a)?yt(e,t,r,i):s&&Object(o["n"])(a)?_t(n,t,r,i):t[r]=a}),e,n,!1),vt(n,t,i)}function at(t){return Object(o["j"])(t[0]-1)&&Object(o["j"])(t[1])&&Object(o["j"])(t[2])&&Object(o["j"])(t[3]-1)}function ot(t){return Object(o["j"])(t[4])&&Object(o["j"])(t[5])}function st(t,e,n){if(e&&(!ot(e)||!at(e))){var i=n?10:1e4;t.transform=at(e)?"translate("+et(e[4]*i)/i+" "+et(e[5]*i)/i+")":Object(o["e"])(e)}}function lt(t,e,n){for(var i=t.points,r=[],a=0;au?(o=null==n[d+1]?null:n[d+1].elm,Rt(t,o,n,l,d)):kt(t,e,s,u))}function Vt(t,e){var n=e.elm=t.elm,i=t.children,r=e.children;t!==e&&(Bt(t,e),Lt(e.text)?Et(i)&&Et(r)?i!==r&&zt(n,i,r):Et(r)?(Et(t.text)&&At(n,""),Rt(n,null,r,0,r.length-1)):Et(i)?kt(n,i,0,i.length-1):Et(t.text)&&At(n,""):t.text!==e.text&&(Et(i)&&kt(n,i,0,i.length-1),At(n,e.text)))}function Ft(t,e){if(Pt(t,e))Vt(t,e);else{var n=t.elm,i=Tt(n);Nt(e),null!==i&&(wt(i,e.elm,Mt(n)),kt(i,[t],0,0))}return e}var Gt=n("3437"),Ht=0,Ut=function(){function t(t,e,n){if(this.type="svg",this.refreshHover=Wt("refreshHover"),this.configLayer=Wt("configLayer"),this.storage=e,this._opts=n=Object(_["m"])({},n),this.root=t,this._id="zr"+Ht++,this._oldVNode=B(n.width,n.height),t&&!n.ssr){var i=this._viewport=document.createElement("div");i.style.cssText="position:relative;overflow:hidden";var r=this._svgDom=this._oldVNode.elm=L("svg");Bt(null,this._oldVNode),i.appendChild(r),t.appendChild(i)}this.resize(n.width,n.height)}return t.prototype.getType=function(){return this.type},t.prototype.getViewportRoot=function(){return this._viewport},t.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},t.prototype.getSvgDom=function(){return this._svgDom},t.prototype.refresh=function(){if(this.root){var t=this.renderToVNode({willUpdate:!0});t.attrs.style="position:absolute;left:0;top:0;user-select:none",Ft(this._oldVNode,t),this._oldVNode=t}},t.prototype.renderOneToVNode=function(t){return mt(t,k(this._id))},t.prototype.renderToVNode=function(t){t=t||{};var e=this.storage.getDisplayList(!0),n=this._backgroundColor,i=this._width,r=this._height,a=k(this._id);a.animation=t.animation,a.willUpdate=t.willUpdate,a.compress=t.compress;var s=[];if(n&&"none"!==n){var l=Object(o["p"])(n),u=l.color,c=l.opacity;this._bgVNode=E("rect","bg",{width:i,height:r,x:"0",y:"0",id:"0",fill:u,"fill-opacity":c}),s.push(this._bgVNode)}else this._bgVNode=null;var h=t.compress?null:this._mainVNode=E("g","main",{},[]);this._paintList(e,a,h?h.children:s),h&&s.push(h);var d=Object(_["H"])(Object(_["F"])(a.defs),(function(t){return a.defs[t]}));if(d.length&&s.push(E("defs","defs",{},d)),t.animation){var f=R(a.cssNodes,a.cssAnims,{newline:!0});if(f){var p=E("style","stl",{},[],f);s.push(p)}}return B(i,r,s,t.useViewBox)},t.prototype.renderToString=function(t){return t=t||{},N(this.renderToVNode({animation:Object(_["P"])(t.cssAnimation,!0),willUpdate:!1,compress:!0,useViewBox:Object(_["P"])(t.useViewBox,!0)}),{newline:!0})},t.prototype.setBackgroundColor=function(t){this._backgroundColor=t;var e=this._bgVNode;if(e&&e.elm){var n=Object(o["p"])(t),i=n.color,r=n.opacity;e.elm.setAttribute("fill",i),r<1&&e.elm.setAttribute("fill-opacity",r)}},t.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},t.prototype._paintList=function(t,e,n){for(var i,r,a=t.length,o=[],s=0,l=0,u=0;u=0;p--)if(h&&r&&h[p]===r[p])break;for(var g=f-1;g>p;g--)s--,i=o[s-1];for(var m=p+1;m-1&&(s.style.stroke=s.style.fill,s.style.fill="#fff",s.style.lineWidth=2),e},e.type="series.line",e.dependencies=["grid","polar"],e.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},e}(Kt["b"]),te=$t,ee=n("deab"),ne=n("2306"),ie=n("861c"),re=n("7d6c"),ae=n("2b17");function oe(t,e){var n=t.mapDimensionsAll("defaultedLabel"),i=n.length;if(1===i){var r=Object(ae["e"])(t,e,n[0]);return null!=r?r+"":null}if(i){for(var a=[],o=0;o=0&&i.push(e[a])}return i.join(" ")}var le=n("7837"),ue=function(t){function e(e,n,i,r){var a=t.call(this)||this;return a.updateData(e,n,i,r),a}return Object(qt["a"])(e,t),e.prototype._createSymbol=function(t,e,n,i,r){this.removeAll();var a=Object(Qt["a"])(t,-1,-1,2,2,null,r);a.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),a.drift=ce,this._symbolType=t,this.add(a)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){Object(re["r"])(this.childAt(0))},e.prototype.downplay=function(){Object(re["C"])(this.childAt(0))},e.prototype.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},e.prototype.setDraggable=function(t,e){var n=this.childAt(0);n.draggable=t,n.cursor=!e&&t?"move":n.cursor},e.prototype.updateData=function(t,n,i,r){this.silent=!1;var a=t.getItemVisual(n,"symbol")||"circle",o=t.hostModel,s=e.getSymbolSize(t,n),l=a!==this._symbolType,u=r&&r.disableAnimation;if(l){var c=t.getItemVisual(n,"symbolKeepAspect");this._createSymbol(a,t,n,s,c)}else{var h=this.childAt(0);h.silent=!1;var d={scaleX:s[0]/2,scaleY:s[1]/2};u?h.attr(d):ee["h"](h,d,o,n),Object(ee["g"])(h)}if(this._updateCommon(t,n,s,i,r),l){h=this.childAt(0);if(!u){d={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:h.style.opacity}};h.scaleX=h.scaleY=0,h.style.opacity=0,ee["c"](h,d,o,n)}}u&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,e,n,i,r){var a,o,s,u,c,h,d,f,p,g=this.childAt(0),m=t.hostModel;if(i&&(a=i.emphasisItemStyle,o=i.blurItemStyle,s=i.selectItemStyle,u=i.focus,c=i.blurScope,d=i.labelStatesModels,f=i.hoverScale,p=i.cursorStyle,h=i.emphasisDisabled),!i||t.hasItemOption){var v=i&&i.itemModel?i.itemModel:t.getItemModel(e),y=v.getModel("emphasis");a=y.getModel("itemStyle").getItemStyle(),s=v.getModel(["select","itemStyle"]).getItemStyle(),o=v.getModel(["blur","itemStyle"]).getItemStyle(),u=y.get("focus"),c=y.get("blurScope"),h=y.get("disabled"),d=Object(le["e"])(v),f=y.getShallow("scale"),p=v.getShallow("cursor")}var b=t.getItemVisual(e,"symbolRotate");g.attr("rotation",(b||0)*Math.PI/180||0);var x=Object(Qt["b"])(t.getItemVisual(e,"symbolOffset"),n);x&&(g.x=x[0],g.y=x[1]),p&&g.attr("cursor",p);var w=t.getItemVisual(e,"style"),O=w.fill;if(g instanceof l["a"]){var S=g.style;g.useStyle(Object(_["m"])({image:S.image,x:S.x,y:S.y,width:S.width,height:S.height},w))}else g.__isEmptyBrush?g.useStyle(Object(_["m"])({},w)):g.useStyle(w),g.style.decal=null,g.setColor(O,r&&r.symbolInnerColor),g.style.strokeNoScale=!0;var T=t.getItemVisual(e,"liftZ"),M=this._z2;null!=T?null==M&&(this._z2=g.z2,g.z2+=T):null!=M&&(g.z2=M,this._z2=null);var A=r&&r.useNameLabel;function C(e){return A?t.getName(e):oe(t,e)}Object(le["g"])(g,d,{labelFetcher:m,labelDataIndex:e,defaultText:C,inheritColor:O,defaultOpacity:w.opacity}),this._sizeX=n[0]/2,this._sizeY=n[1]/2;var I=g.ensureState("emphasis");if(I.style=a,g.ensureState("select").style=s,g.ensureState("blur").style=o,f){var D=Math.max(Object(_["z"])(f)?f:1.1,3/this._sizeY);I.scaleX=this._sizeX*D,I.scaleY=this._sizeY*D}this.setSymbolScale(1),Object(re["J"])(this,u,c,h)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,e,n){var i=this.childAt(0),r=Object(ie["a"])(this).dataIndex,a=n&&n.animation;if(this.silent=i.silent=!0,n&&n.fadeLabel){var o=i.getTextContent();o&&ee["e"](o,{style:{opacity:0}},e,{dataIndex:r,removeOpt:a,cb:function(){i.removeTextContent()}})}else i.removeTextContent();ee["e"](i,{style:{opacity:0},scaleX:0,scaleY:0},e,{dataIndex:r,cb:t,removeOpt:a})},e.getSymbolSize=function(t,e){return Object(Qt["c"])(t.getItemVisual(e,"symbolSize"))},e}(Jt["a"]);function ce(t,e){this.parent.drift(t,e)}var he=ue;function de(t,e,n,i){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(i.isIgnore&&i.isIgnore(n))&&!(i.clipShape&&!i.clipShape.contain(e[0],e[1]))&&"none"!==t.getItemVisual(n,"symbol")}function fe(t){return null==t||Object(_["A"])(t)||(t={isIgnore:t}),t||{}}function pe(t){var e=t.hostModel,n=e.getModel("emphasis");return{emphasisItemStyle:n.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:n.get("focus"),blurScope:n.get("blurScope"),emphasisDisabled:n.get("disabled"),hoverScale:n.get("scale"),labelStatesModels:Object(le["e"])(e),cursorStyle:e.get("cursor")}}var ge=function(){function t(t){this.group=new Jt["a"],this._SymbolCtor=t||he}return t.prototype.updateData=function(t,e){this._progressiveEls=null,e=fe(e);var n=this.group,i=t.hostModel,r=this._data,a=this._SymbolCtor,o=e.disableAnimation,s=pe(t),l={disableAnimation:o},u=e.getSymbolPoint||function(e){return t.getItemLayout(e)};r||n.removeAll(),t.diff(r).add((function(i){var r=u(i);if(de(t,r,i,e)){var o=new a(t,i,s,l);o.setPosition(r),t.setItemGraphicEl(i,o),n.add(o)}})).update((function(c,h){var d=r.getItemGraphicEl(h),f=u(c);if(de(t,f,c,e)){var p=t.getItemVisual(c,"symbol")||"circle",g=d&&d.getSymbolType&&d.getSymbolType();if(!d||g&&g!==p)n.remove(d),d=new a(t,c,s,l),d.setPosition(f);else{d.updateData(t,c,s,l);var m={x:f[0],y:f[1]};o?d.attr(m):ee["h"](d,m,i)}n.add(d),t.setItemGraphicEl(c,d)}else n.remove(d)})).remove((function(t){var e=r.getItemGraphicEl(t);e&&e.fadeOut((function(){n.remove(e)}),i)})).execute(),this._getSymbolPoint=u,this._data=t},t.prototype.updateLayout=function(){var t=this,e=this._data;e&&e.eachItemGraphicEl((function(e,n){var i=t._getSymbolPoint(n);e.setPosition(i),e.markRedraw()}))},t.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=pe(t),this._data=null,this.group.removeAll()},t.prototype.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[],n=fe(n);for(var r=t.start;r0?n=i[0]:i[1]<0&&(n=i[1]),n}function be(t,e,n,i){var r=NaN;t.stacked&&(r=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(r)&&(r=t.valueStart);var a=t.baseDataOffset,o=[];return o[a]=n.get(t.baseDim,i),o[1-a]=r,e.dataToPoint(o)}var xe=n("f658");function we(t,e){var n=[];return e.diff(t).add((function(t){n.push({cmd:"+",idx:t})})).update((function(t,e){n.push({cmd:"=",idx:e,idx1:t})})).remove((function(t){n.push({cmd:"-",idx:t})})).execute(),n}function Oe(t,e,n,i,r,a,o,s){for(var l=we(t,e),u=[],c=[],h=[],d=[],f=[],p=[],g=[],m=ye(r,e,o),v=t.getLayout("points")||[],y=e.getLayout("points")||[],_=0;_=r||g<0)break;if(Ie(v,y)){if(l){g+=a;continue}break}if(g===n)t[a>0?"moveTo":"lineTo"](v,y),h=v,d=y;else{var _=v-u,b=y-c;if(_*_+b*b<.5){g+=a;continue}if(o>0){var x=g+a,w=e[2*x],O=e[2*x+1];while(w===v&&O===y&&m=i||Ie(w,O))f=v,p=y;else{M=w-u,A=O-c;var D=v-u,L=w-v,E=y-c,j=O-y,P=void 0,N=void 0;if("x"===s){P=Math.abs(D),N=Math.abs(L);var R=M>0?1:-1;f=v-R*P*o,p=y,C=v+R*N*o,I=y}else if("y"===s){P=Math.abs(E),N=Math.abs(j);var k=A>0?1:-1;f=v,p=y-k*P*o,C=v,I=y+k*N*o}else P=Math.sqrt(D*D+E*E),N=Math.sqrt(L*L+j*j),T=N/(N+P),f=v-M*o*(1-T),p=y-A*o*(1-T),C=v+M*o*T,I=y+A*o*T,C=Ae(C,Ce(w,v)),I=Ae(I,Ce(O,y)),C=Ce(C,Ae(w,v)),I=Ce(I,Ae(O,y)),M=C-v,A=I-y,f=v-M*P/N,p=y-A*P/N,f=Ae(f,Ce(u,v)),p=Ae(p,Ce(c,y)),f=Ce(f,Ae(u,v)),p=Ce(p,Ae(c,y)),M=v-f,A=y-p,C=v+M*N/P,I=y+A*N/P}t.bezierCurveTo(h,d,f,p,v,y),h=C,d=I}else t.lineTo(v,y)}u=v,c=y,g+=a}return m}var Le=function(){function t(){this.smooth=0,this.smoothConstraint=!0}return t}(),Ee=function(t){function e(e){var n=t.call(this,e)||this;return n.type="ec-polyline",n}return Object(qt["a"])(e,t),e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Le},e.prototype.buildPath=function(t,e){var n=e.points,i=0,r=n.length/2;if(e.connectNulls){for(;r>0;r--)if(!Ie(n[2*r-2],n[2*r-1]))break;for(;i=0){var y=s?(d-i)*v+i:(h-n)*v+n;return s?[t,y]:[y,t]}n=h,i=d;break;case o.C:h=a[u++],d=a[u++],f=a[u++],p=a[u++],g=a[u++],m=a[u++];var _=s?Object(Me["f"])(n,h,f,g,t,l):Object(Me["f"])(i,d,p,m,t,l);if(_>0)for(var b=0;b<_;b++){var x=l[b];if(x<=1&&x>=0){y=s?Object(Me["a"])(i,d,p,m,x):Object(Me["a"])(n,h,f,g,x);return s?[t,y]:[y,t]}}n=g,i=m;break}}},e}(s["b"]),je=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e}(Le),Pe=function(t){function e(e){var n=t.call(this,e)||this;return n.type="ec-polygon",n}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new je},e.prototype.buildPath=function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,a=n.length/2,o=e.smoothMonotone;if(e.connectNulls){for(;a>0;a--)if(!Ie(n[2*a-2],n[2*a-1]))break;for(;re){i?r.push(o(i,l,e)):n&&r.push(o(n,l,0),o(n,l,e));break}n&&(r.push(o(n,l,0)),n=null),r.push(l),i=l}}return r}function Je(t,e,n){var i=t.getVisual("visualMeta");if(i&&i.length&&t.count()&&"cartesian2d"===e.type){for(var r,a,o=i.length-1;o>=0;o--){var s=t.getDimensionInfo(i[o].dimension);if(r=s&&s.coordDim,"x"===r||"y"===r){a=i[o];break}}if(a){var l=e.getAxis(r),u=_["H"](a.stops,(function(t){return{coord:l.toGlobalCoord(l.dataToCoord(t.value)),color:t.color}})),c=u.length,h=a.outerColors.slice();c&&u[0].coord>u[c-1].coord&&(u.reverse(),h.reverse());var d=Qe(u,"x"===r?n.getWidth():n.getHeight()),f=d.length;if(!f&&c)return u[0].coord<0?h[1]?h[1]:u[c-1].color:h[0]?h[0]:u[0].color;var p=10,g=d[0].coord-p,m=d[f-1].coord+p,v=m-g;if(v<.001)return"transparent";_["k"](d,(function(t){t.offset=(t.coord-g)/v})),d.push({offset:f?d[f-1].offset:.5,color:h[1]||"transparent"}),d.unshift({offset:f?d[0].offset:.5,color:h[0]||"transparent"});var y=new Se["a"](0,0,0,0,d,!0);return y[r]=g,y[r+"2"]=m,y}}}function $e(t,e,n){var i=t.get("showAllSymbol"),r="auto"===i;if(!i||r){var a=n.getAxesByScale("ordinal")[0];if(a&&(!r||!tn(a,e))){var o=e.mapDimension(a.dim),s={};return _["k"](a.getViewLabels(),(function(t){var e=a.scale.getRawOrdinalNumber(t.tickValue);s[e]=1})),function(t){return!s.hasOwnProperty(e.get(o,t))}}}}function tn(t,e){var n=t.getExtent(),i=Math.abs(n[1]-n[0])/t.scale.count();isNaN(i)&&(i=0);for(var r=e.count(),a=Math.max(1,Math.round(r/5)),o=0;oi)return!1;return!0}function en(t,e){return isNaN(t)||isNaN(e)}function nn(t){for(var e=t.length/2;e>0;e--)if(!en(t[2*e-2],t[2*e-1]))break;return e-1}function rn(t,e){return[t[2*e],t[2*e+1]]}function an(t,e,n){for(var i,r,a=t.length/2,o="x"===n?0:1,s=0,l=-1,u=0;u=e||i>=e&&r<=e){l=u;break}s=u,i=r}else i=r;return{range:[s,l],t:(e-i)/(r-i)}}function on(t){if(t.get(["endLabel","show"]))return!0;for(var e=0;e0&&"bolder"===t.get(["emphasis","lineStyle","width"])){var N=f.getState("emphasis").style;N.lineWidth=+f.style.lineWidth+1}Object(ie["a"])(f).seriesIndex=t.seriesIndex,Object(re["J"])(f,E,j,P);var R=qe(t.get("smooth")),k=t.get("smoothMonotone");if(f.setShape({smooth:R,smoothMonotone:k,connectNulls:O}),p){var B=o.getCalculationInfo("stackedOnSeries"),z=0;p.useStyle(_["i"](l.getAreaStyle(),{fill:C,opacity:.7,lineJoin:"bevel",decal:o.getVisual("style").decal})),B&&(z=qe(B.get("smooth"))),p.setShape({smooth:R,stackedOnSmooth:z,smoothMonotone:k,connectNulls:O}),Object(re["I"])(p,t,"areaStyle"),Object(ie["a"])(p).seriesIndex=t.seriesIndex,Object(re["J"])(p,E,j,P)}var V=function(t){i._changePolyState(t)};o.eachItemGraphicEl((function(t){t&&(t.onHoverStateChange=V)})),this._polyline.onHoverStateChange=V,this._data=o,this._coordSys=r,this._stackedOnPoints=x,this._points=u,this._step=A,this._valueOrigin=y,t.get("triggerLineEvent")&&(this.packEventData(t,f),p&&this.packEventData(t,p))},e.prototype.packEventData=function(t,e){Object(ie["a"])(e).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},e.prototype.highlight=function(t,e,n,i){var r=t.getData(),a=Te["u"](r,i);if(this._changePolyState("emphasis"),!(a instanceof Array)&&null!=a&&a>=0){var o=r.getLayout("points"),s=r.getItemGraphicEl(a);if(!s){var l=o[2*a],u=o[2*a+1];if(isNaN(l)||isNaN(u))return;if(this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(l,u))return;var c=t.get("zlevel"),h=t.get("z");s=new he(r,a),s.x=l,s.y=u,s.setZ(c,h);var d=s.getSymbolPath().getTextContent();d&&(d.zlevel=c,d.z=h,d.z2=this._polyline.z2+1),s.__temp=!0,r.setItemGraphicEl(a,s),s.stopSymbolAnimation(!0),this.group.add(s)}s.highlight()}else Ne["a"].prototype.highlight.call(this,t,e,n,i)},e.prototype.downplay=function(t,e,n,i){var r=t.getData(),a=Te["u"](r,i);if(this._changePolyState("normal"),null!=a&&a>=0){var o=r.getItemGraphicEl(a);o&&(o.__temp?(r.setItemGraphicEl(a,null),this.group.remove(o)):o.downplay())}else Ne["a"].prototype.downplay.call(this,t,e,n,i)},e.prototype._changePolyState=function(t){var e=this._polygon;Object(re["H"])(this._polyline,t),e&&Object(re["H"])(e,t)},e.prototype._newPolyline=function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new Ee({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(e),this._polyline=e,e},e.prototype._newPolygon=function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new Pe({shape:{points:t,stackedOnPoints:e},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},e.prototype._initSymbolLabelAnimation=function(t,e,n){var i,r,a=e.getBaseAxis(),o=a.inverse;"cartesian2d"===e.type?(i=a.isHorizontal(),r=!1):"polar"===e.type&&(i="angle"===a.dim,r=!0);var s=t.hostModel,l=s.get("animationDuration");_["w"](l)&&(l=l(null));var u=s.get("animationDelay")||0,c=_["w"](u)?u(null):u;t.eachItemGraphicEl((function(t,a){var s=t;if(s){var h=[t.x,t.y],d=void 0,f=void 0,p=void 0;if(n)if(r){var g=n,m=e.pointToCoord(h);i?(d=g.startAngle,f=g.endAngle,p=-m[1]/180*Math.PI):(d=g.r0,f=g.r,p=m[0])}else{var v=n;i?(d=v.x,f=v.x+v.width,p=t.x):(d=v.y+v.height,f=v.y,p=t.y)}var y=f===d?0:(p-d)/(f-d);o&&(y=1-y);var b=_["w"](u)?u(a):l*y+c,x=s.getSymbolPath(),w=x.getTextContent();s.attr({scaleX:0,scaleY:0}),s.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:b}),w&&w.animateFrom({style:{opacity:0}},{duration:300,delay:b}),x.disableLabelAnimation=!0}}))},e.prototype._initOrUpdateEndLabel=function(t,e,n){var i=t.getModel("endLabel");if(on(t)){var r=t.getData(),a=this._polyline,o=r.getLayout("points");if(!o)return a.removeTextContent(),void(this._endLabel=null);var s=this._endLabel;s||(s=this._endLabel=new $["a"]({z2:200}),s.ignoreClip=!0,a.setTextContent(this._endLabel),a.disableLabelAnimation=!0);var l=nn(o);l>=0&&(Object(le["g"])(a,Object(le["e"])(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:l,defaultText:function(t,e,n){return null!=n?se(r,n):oe(r,t)},enableTextSetter:!0},ln(i,e)),a.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,e,n,i,r,a,o){var s=this._endLabel,l=this._polyline;if(s){t<1&&null==i.originalX&&(i.originalX=s.x,i.originalY=s.y);var u=n.getLayout("points"),c=n.hostModel,h=c.get("connectNulls"),d=a.get("precision"),f=a.get("distance")||0,p=o.getBaseAxis(),g=p.isHorizontal(),m=p.inverse,v=e.shape,y=m?g?v.x:v.y+v.height:g?v.x+v.width:v.y,_=(g?f:0)*(m?-1:1),b=(g?0:-f)*(m?-1:1),x=g?"x":"y",w=an(u,y,x),O=w.range,S=O[1]-O[0],T=void 0;if(S>=1){if(S>1&&!h){var M=rn(u,O[0]);s.attr({x:M[0]+_,y:M[1]+b}),r&&(T=c.getRawValue(O[0]))}else{M=l.getPointOn(y,x);M&&s.attr({x:M[0]+_,y:M[1]+b});var A=c.getRawValue(O[0]),C=c.getRawValue(O[1]);r&&(T=Te["k"](n,d,A,C,w.t))}i.lastFrameIndex=O[0]}else{var I=1===t||i.lastFrameIndex>0?O[0]:0;M=rn(u,I);r&&(T=c.getRawValue(I)),s.attr({x:M[0]+_,y:M[1]+b})}r&&Object(le["f"])(s).setLabelText(T)}},e.prototype._doUpdateAnimation=function(t,e,n,i,r,a,o){var s=this._polyline,l=this._polygon,u=t.hostModel,c=Oe(this._data,t,this._stackedOnPoints,e,this._coordSys,n,this._valueOrigin,a),h=c.current,d=c.stackedOnCurrent,f=c.next,p=c.stackedOnNext;if(r&&(h=Ke(c.current,n,r,o),d=Ke(c.stackedOnCurrent,n,r,o),f=Ke(c.next,n,r,o),p=Ke(c.stackedOnNext,n,r,o)),Ze(h,f)>3e3||l&&Ze(d,p)>3e3)return s.stopAnimation(),s.setShape({points:f}),void(l&&(l.stopAnimation(),l.setShape({points:f,stackedOnPoints:p})));s.shape.__points=c.current,s.shape.points=h;var g={shape:{points:f}};c.current!==h&&(g.shape.__points=c.next),s.stopAnimation(),ee["h"](s,g,u),l&&(l.setShape({points:h,stackedOnPoints:d}),l.stopAnimation(),ee["h"](l,{shape:{stackedOnPoints:p}},u),s.shape.points!==l.shape.points&&(l.shape.points=s.shape.points));for(var m=[],v=c.status,y=0;ye&&(e=t[n]);return isFinite(e)?e:NaN},min:function(t){for(var e=1/0,n=0;n10&&"cartesian2d"===a.type&&r){var s=a.getBaseAxis(),l=a.getOtherAxis(s),u=s.getExtent(),c=n.getDevicePixelRatio(),h=Math.abs(u[1]-u[0])*(c||1),d=Math.round(o/h);if(isFinite(d)&&d>1){"lttb"===r&&t.setData(i.lttbDownSample(i.mapDimension(l.dim),1/d));var f=void 0;Object(_["C"])(r)?f=fn[r]:Object(_["w"])(r)&&(f=r),f&&t.setData(i.downSample(i.mapDimension(l.dim),1/d,f,pn))}}}}}function mn(t){t.registerChartView(cn),t.registerSeriesModel(te),t.registerLayout(dn("line",!0)),t.registerVisual({seriesType:"line",reset:function(t){var e=t.getData(),n=t.getModel("lineStyle").getLineStyle();n&&!n.stroke&&(n.stroke=e.getVisual("style").fill),e.setVisual("legendLineStyle",n)}}),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,gn("line"))}var vn=n("9d57"),yn=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t,e){return Object(Yt["a"])(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t){var e=this.coordinateSystem;if(e&&e.clampData){var n=e.dataToPoint(e.clampData(t)),i=this.getData(),r=i.getLayout("offset"),a=i.getLayout("size"),o=e.getBaseAxis().isHorizontal()?0:1;return n[o]+=r+a/2,n}return[NaN,NaN]},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},e}(Kt["b"]);Kt["b"].registerClass(yn);var _n=yn,bn=n("8918"),xn=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(){return Object(Yt["a"])(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return!!this.get("large")&&this.get("progressive")},e.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return e>t&&(t=e),t},e.prototype.brushSelector=function(t,e,n){return n.rect(e.getItemLayout(t))},e.type="series.bar",e.dependencies=["grid","polar"],e.defaultOption=Object(bn["d"])(_n.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),e}(_n),wn=xn,On=n("88b3"),Sn=function(){function t(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0}return t}(),Tn=function(t){function e(e){var n=t.call(this,e)||this;return n.type="sausage",n}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new Sn},e.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r0||0,0),a=Math.max(e.r,0),o=.5*(a-r),s=r+o,l=e.startAngle,u=e.endAngle,c=e.clockwise,h=2*Math.PI,d=c?u-lMath.PI/2&&c<1.5*Math.PI&&(c-=Math.PI),t.setTextConfig({rotation:c})}}function In(t,e,n){return e*Math.sin(t)*(n?-1:1)}function Dn(t,e,n){return e*Math.cos(t)*(n?1:-1)}var Ln=Math.max,En=Math.min;function jn(t,e){var n=t.getArea&&t.getArea();if(Ge(t,"cartesian2d")){var i=t.getBaseAxis();if("category"!==i.type||!i.onBand){var r=e.getLayout("bandWidth");i.isHorizontal()?(n.x-=r,n.width+=2*r):(n.y-=r,n.height+=2*r)}}return n}var Pn=function(t){function e(){var n=t.call(this)||this;return n.type=e.type,n._isFirstFrame=!0,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n,i){this._model=t,this._removeOnRenderedListener(n),this._updateDrawMode(t);var r=t.get("coordinateSystem");("cartesian2d"===r||"polar"===r)&&(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(t,e,n):this._renderNormal(t,e,n,i))},e.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},e.prototype.incrementalRender=function(t,e){this._progressiveEls=[],this._incrementalRenderLarge(t,e)},e.prototype.eachRendered=function(t){Object(ne["traverseElements"])(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var e=t.pipelineContext.large;null!=this._isLargeDraw&&e===this._isLargeDraw||(this._isLargeDraw=e,this._clear())},e.prototype._renderNormal=function(t,e,n,i){var r,a=this.group,o=t.getData(),s=this._data,l=t.coordinateSystem,u=l.getBaseAxis();"cartesian2d"===l.type?r=u.isHorizontal():"polar"===l.type&&(r="angle"===u.dim);var c=t.isAnimationEnabled()?t:null,h=kn(t,l);h&&this._enableRealtimeSort(h,o,n);var d=t.get("clip",!0)||h,f=jn(l,o);a.removeClipPath();var p=t.get("roundCap",!0),g=t.get("showBackground",!0),m=t.getModel("backgroundStyle"),v=m.get("borderRadius")||0,y=[],_=this._backgroundEls,b=i&&i.isInitSort,x=i&&"changeAxisOrder"===i.type;function w(t){var e=Hn[l.type](o,t),n=ti(l,r,e);return n.useStyle(m.getItemStyle()),"cartesian2d"===l.type&&n.setShape("r",v),y[t]=n,n}o.diff(s).add((function(e){var n=o.getItemModel(e),i=Hn[l.type](o,e,n);if(g&&w(e),o.hasValue(e)&&Gn[l.type](i)){var s=!1;d&&(s=Nn[l.type](f,i));var m=Rn[l.type](t,o,e,i,r,c,u.model,!1,p);h&&(m.forceLabelAnimation=!0),Xn(m,o,e,n,i,t,r,"polar"===l.type),b?m.attr({shape:i}):h?Bn(h,c,m,i,e,r,!1,!1):Object(ee["c"])(m,{shape:i},t,e),o.setItemGraphicEl(e,m),a.add(m),m.ignore=s}})).update((function(e,n){var i=o.getItemModel(e),O=Hn[l.type](o,e,i);if(g){var S=void 0;0===_.length?S=w(n):(S=_[n],S.useStyle(m.getItemStyle()),"cartesian2d"===l.type&&S.setShape("r",v),y[e]=S);var T=Hn[l.type](o,e),M=$n(r,T,l);Object(ee["h"])(S,{shape:M},c,e)}var A=s.getItemGraphicEl(n);if(o.hasValue(e)&&Gn[l.type](O)){var C=!1;if(d&&(C=Nn[l.type](f,O),C&&a.remove(A)),A?Object(ee["g"])(A):A=Rn[l.type](t,o,e,O,r,c,u.model,!!A,p),h&&(A.forceLabelAnimation=!0),x){var I=A.getTextContent();if(I){var D=Object(le["f"])(I);null!=D.prevValue&&(D.prevValue=D.value)}}else Xn(A,o,e,i,O,t,r,"polar"===l.type);b?A.attr({shape:O}):h?Bn(h,c,A,O,e,r,!0,x):Object(ee["h"])(A,{shape:O},t,e,null),o.setItemGraphicEl(e,A),A.ignore=C,a.add(A)}else a.remove(A)})).remove((function(e){var n=s.getItemGraphicEl(e);n&&Object(ee["f"])(n,t,e)})).execute();var O=this._backgroundGroup||(this._backgroundGroup=new Jt["a"]);O.removeAll();for(var S=0;Sa)return!0;a=u}return!1},e.prototype._isOrderDifferentInView=function(t,e){for(var n=e.scale,i=n.getExtent(),r=Math.max(0,i[0]),a=Math.min(i[1],n.getOrdinalMeta().categories.length-1);r<=a;++r)if(t.ordinalNumbers[r]!==n.getRawOrdinalNumber(r))return!0},e.prototype._updateSortWithinSameData=function(t,e,n,i){if(this._isOrderChangedWithinSameData(t,e,n)){var r=this._dataSort(t,n,e);this._isOrderDifferentInView(r,n)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:r}))}},e.prototype._dispatchInitSort=function(t,e,n){var i=e.baseAxis,r=this._dataSort(t,i,(function(n){return t.get(t.mapDimension(e.otherAxis.dim),n)}));n.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:r})},e.prototype.remove=function(t,e){this._clear(this._model),this._removeOnRenderedListener(e)},e.prototype.dispose=function(t,e){this._removeOnRenderedListener(e)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var e=this.group,n=this._data;t&&t.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl((function(e){Object(ee["f"])(e,t,Object(ie["a"])(e).dataIndex)}))):e.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type="bar",e}(Ne["a"]),Nn={cartesian2d:function(t,e){var n=e.width<0?-1:1,i=e.height<0?-1:1;n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height);var r=t.x+t.width,a=t.y+t.height,o=Ln(e.x,t.x),s=En(e.x+e.width,r),l=Ln(e.y,t.y),u=En(e.y+e.height,a),c=sr?s:o,e.y=h&&l>a?u:l,e.width=c?0:s-o,e.height=h?0:u-l,n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height),c||h},polar:function(t,e){var n=e.r0<=e.r?1:-1;if(n<0){var i=e.r;e.r=e.r0,e.r0=i}var r=En(e.r,t.r),a=Ln(e.r0,t.r0);e.r=r,e.r0=a;var o=r-a<0;if(n<0){i=e.r;e.r=e.r0,e.r0=i}return o}},Rn={cartesian2d:function(t,e,n,i,r,a,o,s,l){var u=new Re["a"]({shape:Object(_["m"])({},i),z2:1});if(u.__dataIndex=n,u.name="item",a){var c=u.shape,h=r?"height":"width";c[h]=0}return u},polar:function(t,e,n,i,r,a,o,s,l){var u=!r&&l?Mn:ke["a"],c=new u({shape:i,z2:1});c.name="item";var h=Wn(r);if(c.calculateTextPosition=An(h,{isRoundCap:u===Mn}),a){var d=c.shape,f=r?"r":"endAngle",p={};d[f]=r?0:i.startAngle,p[f]=i[f],(s?ee["h"]:ee["c"])(c,{shape:p},a)}return c}};function kn(t,e){var n=t.get("realtimeSort",!0),i=e.getBaseAxis();if(n&&"category"===i.type&&"cartesian2d"===e.type)return{baseAxis:i,otherAxis:e.getOtherAxis(i)}}function Bn(t,e,n,i,r,a,o,s){var l,u;a?(u={x:i.x,width:i.width},l={y:i.y,height:i.height}):(u={y:i.y,height:i.height},l={x:i.x,width:i.width}),s||(o?ee["h"]:ee["c"])(n,{shape:l},e,r,null);var c=e?t.baseAxis.model:null;(o?ee["h"]:ee["c"])(n,{shape:u},c,r)}function zn(t,e){for(var n=0;n0?1:-1,o=i.height>0?1:-1;return{x:i.x+a*r/2,y:i.y+o*r/2,width:i.width-a*r,height:i.height-o*r}},polar:function(t,e,n){var i=t.getItemLayout(e);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}}};function Un(t){return null!=t.startAngle&&null!=t.endAngle&&t.startAngle===t.endAngle}function Wn(t){return function(t){var e=t?"Arc":"Angle";return function(t){switch(t){case"start":case"insideStart":case"end":case"insideEnd":return t+e;default:return t}}}(t)}function Xn(t,e,n,i,r,a,o,s){var l=e.getItemVisual(n,"style");s||t.setShape("r",i.get(["itemStyle","borderRadius"])||0),t.useStyle(l);var u=i.getShallow("cursor");u&&t.attr("cursor",u);var c=s?o?r.r>=r.r0?"endArc":"startArc":r.endAngle>=r.startAngle?"endAngle":"startAngle":o?r.height>=0?"bottom":"top":r.width>=0?"right":"left",h=Object(le["e"])(i);Object(le["g"])(t,h,{labelFetcher:a,labelDataIndex:n,defaultText:oe(a.getData(),n),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:c});var d=t.getTextContent();if(s&&d){var f=i.get(["label","position"]);t.textConfig.inside="middle"===f||null,Cn(t,"outside"===f?c:f,Wn(o),i.get(["label","rotate"]))}Object(le["h"])(d,h,a.getRawValue(n),(function(t){return se(e,t)}));var p=i.getModel(["emphasis"]);Object(re["J"])(t,p.get("focus"),p.get("blurScope"),p.get("disabled")),Object(re["I"])(t,i),Un(r)&&(t.style.fill="none",t.style.stroke="none",Object(_["k"])(t.states,(function(t){t.style&&(t.style.fill=t.style.stroke="none")})))}function Zn(t,e){var n=t.get(["itemStyle","borderColor"]);if(!n||"none"===n)return 0;var i=t.get(["itemStyle","borderWidth"])||0,r=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),a=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height);return Math.min(i,r,a)}var qn=function(){function t(){}return t}(),Yn=function(t){function e(e){var n=t.call(this,e)||this;return n.type="largeBar",n}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new qn},e.prototype.buildPath=function(t,e){for(var n=e.points,i=this.baseDimIdx,r=1-this.baseDimIdx,a=[],o=[],s=this.barWidth,l=0;l=0?n:null}),30,!1);function Jn(t,e,n){for(var i=t.baseDimIdx,r=1-i,a=t.shape.points,o=t.largeDataIndices,s=[],l=[],u=t.barWidth,c=0,h=a.length/3;c=s[0]&&e<=s[0]+l[0]&&n>=s[1]&&n<=s[1]+l[1])return o[c]}return-1}function $n(t,e,n){if(Ge(n,"cartesian2d")){var i=e,r=n.getArea();return{x:t?i.x:r.x,y:t?r.y:i.y,width:t?i.width:r.width,height:t?r.height:i.height}}r=n.getArea();var a=e;return{cx:r.cx,cy:r.cy,r0:t?r.r0:a.r0,r:t?r.r:a.r,startAngle:t?a.startAngle:0,endAngle:t?a.endAngle:2*Math.PI}}function ti(t,e,n){var i="polar"===t.type?ke["a"]:Re["a"];return new i({shape:$n(e,n,t),silent:!0,z2:0})}var ei=Pn;function ni(t){t.registerChartView(ei),t.registerSeriesModel(wn),t.registerLayout(t.PRIORITY.VISUAL.LAYOUT,_["h"](vn["c"],"bar")),t.registerLayout(t.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,Object(vn["a"])("bar")),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,gn("bar")),t.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},(function(t,e){var n=t.componentType||"series";e.eachComponent({mainType:n,query:t},(function(e){t.sortInfo&&e.axis.setCategorySortInfo(t.sortInfo)}))}))}var ii=n("f3bb"),ri=n("f934"),ai=2*Math.PI,oi=Math.PI/180;function si(t,e){return ri["g"](t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function li(t,e){var n=si(t,e),i=t.get("center"),r=t.get("radius");_["t"](r)||(r=[0,r]),_["t"](i)||(i=[i,i]);var a=Object(Be["p"])(n.width,e.getWidth()),o=Object(Be["p"])(n.height,e.getHeight()),s=Math.min(a,o),l=Object(Be["p"])(i[0],a)+n.x,u=Object(Be["p"])(i[1],o)+n.y,c=Object(Be["p"])(r[0],s/2),h=Object(Be["p"])(r[1],s/2);return{cx:l,cy:u,r0:c,r:h}}function ui(t,e,n){e.eachSeriesByType(t,(function(t){var e=t.getData(),i=e.mapDimension("value"),r=si(t,n),a=li(t,n),o=a.cx,s=a.cy,l=a.r,u=a.r0,c=-t.get("startAngle")*oi,h=t.get("minAngle")*oi,d=0;e.each(i,(function(t){!isNaN(t)&&d++}));var f=e.getSum(i),p=Math.PI/(f||d)*2,g=t.get("clockwise"),m=t.get("roseType"),v=t.get("stillShowZeroSum"),y=e.getDataExtent(i);y[0]=0;var _=ai,b=0,x=c,w=g?1:-1;if(e.setLayout({viewRect:r,r:l}),e.each(i,(function(t,n){var i;if(isNaN(t))e.setItemLayout(n,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:g,cx:o,cy:s,r0:u,r:m?NaN:l});else{i="area"!==m?0===f&&v?p:t*p:ai/d,in?o:a,c=Math.abs(l.label.y-n);if(c>=u.maxY){var h=l.label.x-e-l.len2*r,d=i+l.len,p=Math.abs(h)t.unconstrainedWidth?null:f:null;i.setStyle("width",p)}var g=i.getBoundingRect();a.width=g.width;var m=(i.style.margin||0)+2.1;a.height=g.height+m,a.y-=(a.height-h)/2}}}function _i(t){return"center"===t.position}function bi(t){var e,n,i=t.getData(),r=[],a=!1,o=(t.get("minShowLabelAngle")||0)*gi,s=i.getLayout("viewRect"),l=i.getLayout("r"),u=s.width,c=s.x,h=s.y,d=s.height;function f(t){t.ignore=!0}function p(t){if(!t.ignore)return!0;for(var e in t.states)if(!1===t.states[e].ignore)return!0;return!1}i.each((function(t){var s=i.getItemGraphicEl(t),h=s.shape,d=s.getTextContent(),g=s.getTextGuideLine(),m=i.getItemModel(t),v=m.getModel("label"),y=v.get("position")||m.get(["emphasis","label","position"]),b=v.get("distanceToLabelLine"),x=v.get("alignTo"),w=Object(Be["p"])(v.get("edgeDistance"),u),O=v.get("bleedMargin"),S=m.getModel("labelLine"),T=S.get("length");T=Object(Be["p"])(T,u);var M=S.get("length2");if(M=Object(Be["p"])(M,u),Math.abs(h.endAngle-h.startAngle)0?"right":"left":E>0?"left":"right"}var F=Math.PI,G=0,H=v.get("rotate");if(Object(_["z"])(H))G=H*(F/180);else if("center"===y)G=0;else if("radial"===H||!0===H){var U=E<0?-L+F:-L;G=U}else if("tangential"===H&&"outside"!==y&&"outer"!==y){var W=Math.atan2(E,j);W<0&&(W=2*F+W);var X=j>0;X&&(W=F+W),G=W-F}if(a=!!G,d.x=A,d.y=C,d.rotation=G,d.setStyle({verticalAlign:"middle"}),P){d.setStyle({align:D});var Z=d.states.select;Z&&(Z.x+=d.x,Z.y+=d.y)}else{var q=d.getBoundingRect().clone();q.applyTransform(d.getComputedTransform());var Y=(d.style.margin||0)+2.1;q.y-=Y/2,q.height+=Y,r.push({label:d,labelLine:g,position:y,len:T,len2:M,minTurnAngle:S.get("minTurnAngle"),maxSurfaceAngle:S.get("maxSurfaceAngle"),surfaceNormal:new di["a"](E,j),linePoints:I,textAlign:D,labelDistance:b,labelAlignTo:x,edgeDistance:w,bleedMargin:O,rect:q,unconstrainedWidth:q.width,labelStyleWidth:d.style.width})}s.setTextConfig({inside:P})}})),!a&&t.get("avoidLabelOverlap")&&vi(r,e,n,l,u,d,c,h);for(var g=0;g0){for(var l=a.getItemLayout(0),u=1;isNaN(l&&l.startAngle)&&u=i.r0}},e.type="pie",e}(Ne["a"]),Si=Oi,Ti=n("b1d4"),Mi=n("b682");function Ai(t,e,n){e=Object(_["t"])(e)&&{coordDimensions:e}||Object(_["m"])({encodeDefine:t.getEncode()},e);var i=t.getSource(),r=Object(Ti["b"])(i,e).dimensions,a=new Mi["a"](r,t);return a.initData(i,n),a}var Ci=n("0f99"),Ii=function(){function t(t,e){this._getDataWithEncodedVisual=t,this._getRawData=e}return t.prototype.getAllNames=function(){var t=this._getRawData();return t.mapArray(t.getName)},t.prototype.containName=function(t){var e=this._getRawData();return e.indexOfName(t)>=0},t.prototype.indexOfName=function(t){var e=this._getDataWithEncodedVisual();return e.indexOfName(t)},t.prototype.getItemVisual=function(t,e){var n=this._getDataWithEncodedVisual();return n.getItemVisual(t,e)},t}(),Di=Ii,Li=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.init=function(e){t.prototype.init.apply(this,arguments),this.legendVisualProvider=new Di(_["c"](this.getData,this),_["c"](this.getRawData,this)),this._defaultLabelLine(e)},e.prototype.mergeOption=function(){t.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return Ai(this,{coordDimensions:["value"],encodeDefaulter:_["h"](Ci["d"],this)})},e.prototype.getDataParams=function(e){var n=this.getData(),i=t.prototype.getDataParams.call(this,e),r=[];return n.each(n.mapDimension("value"),(function(t){r.push(t)})),i.percent=Object(Be["e"])(r,e,n.hostModel.get("percentPrecision")),i.$vars.push("percent"),i},e.prototype._defaultLabelLine=function(t){Te["f"](t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.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,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}(Kt["b"]),Ei=Li;function ji(t){return{seriesType:t,reset:function(t,e){var n=t.getData();n.filterSelf((function(t){var e=n.mapDimension("value"),i=n.get(e,t);return!(Object(_["z"])(i)&&!isNaN(i)&&i<0)}))}}}function Pi(t){t.registerChartView(Si),t.registerSeriesModel(Ei),Object(ii["a"])("pie",t.registerAction),t.registerLayout(Object(_["h"])(ui,"pie")),t.registerProcessor(ci("pie")),t.registerProcessor(ji("pie"))}var Ni=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.hasSymbolVisual=!0,n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t,e){return Object(Yt["a"])(null,this,{useEncodeDefaulter:!0})},e.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},e.prototype.brushSelector=function(t,e,n){return n.point(e.getItemLayout(t))},e.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},e.type="series.scatter",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}},e}(Kt["b"]),Ri=Ni,ki=n("9850"),Bi=4,zi=function(){function t(){}return t}(),Vi=function(t){function e(e){var n=t.call(this,e)||this;return n._off=0,n.hoverDataIdx=-1,n}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new zi},e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.buildPath=function(t,e){var n,i=e.points,r=e.size,a=this.symbolProxy,o=a.shape,s=t.getContext?t.getContext():t,l=s&&r[0]=0;s--){var l=2*s,u=i[l]-a/2,c=i[l+1]-o/2;if(t>=u&&e>=c&&t<=u+a&&e<=c+o)return s}return-1},e.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();if(t=n[0],e=n[1],i.contain(t,e)){var r=this.hoverDataIdx=this.findDataIndex(t,e);return r>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var e=this.shape,n=e.points,i=e.size,r=i[0],a=i[1],o=1/0,s=1/0,l=-1/0,u=-1/0,c=0;c=0&&(l.dataIndex=n+(t.startIndex||0))}))},t.prototype.remove=function(){this._clear()},t.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},t}(),Gi=Fi,Hi=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=t.getData(),r=this._updateSymbolDraw(i,t);r.updateData(i,{clipShape:this._getClipShape(t)}),this._finished=!0},e.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData(),r=this._updateSymbolDraw(i,t);r.incrementalPrepareUpdate(i),this._finished=!1},e.prototype.incrementalRender=function(t,e,n){this._symbolDraw.incrementalUpdate(t,e.getData(),{clipShape:this._getClipShape(e)}),this._finished=t.end===e.getData().count()},e.prototype.updateTransform=function(t,e,n){var i=t.getData();if(this.group.dirty(),!this._finished||i.count()>1e4)return{update:!0};var r=dn("").reset(t,e,n);r.progress&&r.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},e.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},e.prototype._getClipShape=function(t){var e=t.coordinateSystem,n=e&&e.getArea&&e.getArea();return t.get("clip",!0)?n:null},e.prototype._updateSymbolDraw=function(t,e){var n=this._symbolDraw,i=e.pipelineContext,r=i.large;return n&&r===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=r?new Gi:new me,this._isLargeDraw=r,this.group.removeAll()),this.group.add(n.group),n},e.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},e.prototype.dispose=function(){},e.type="scatter",e}(Ne["a"]),Ui=Hi,Wi=n("b12f"),Xi=n("6cb7"),Zi=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},e}(Xi["a"]),qi=Zi,Yi=n("2023"),Ki=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Te["b"]).models[0]},e.type="cartesian2dAxis",e}(Xi["a"]);_["K"](Ki,Yi["a"]);var Qi={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},Ji=_["I"]({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},Qi),$i=_["I"]({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},Qi),tr=_["I"]({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},$i),er=_["i"]({logBase:10},$i),nr={category:Ji,value:$i,time:tr,log:er},ir=n("8e43"),rr={value:1,category:1,time:1,log:1};function ar(t,e,n,i){Object(_["k"])(rr,(function(r,a){var o=Object(_["I"])(Object(_["I"])({},nr[a],!0),i,!0),s=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e+"Axis."+a,n}return Object(qt["a"])(n,t),n.prototype.mergeDefaultAndTheme=function(t,e){var n=Object(ri["d"])(this),i=n?Object(ri["f"])(t):{},r=e.getTheme();Object(_["I"])(t,r.get(a+"Axis")),Object(_["I"])(t,this.getDefaultOption()),t.type=or(t),n&&Object(ri["h"])(t,i,n)},n.prototype.optionUpdated=function(){var t=this.option;"category"===t.type&&(this.__ordinalMeta=ir["a"].createByAxisModel(this))},n.prototype.getCategories=function(t){var e=this.option;if("category"===e.type)return t?e.data:this.__ordinalMeta.categories},n.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},n.type=e+"Axis."+a,n.defaultOption=o,n}(n);t.registerComponentModel(s)})),t.registerSubTypeDefaulter(e+"Axis",or)}function or(t){return t.type||(t.data?"category":"value")}var sr=n("697e"),lr=n("cf7e"),ur=n("1687"),cr=n("401b"),hr=["x","y"];function dr(t){return"interval"===t.type||"time"===t.type}var fr=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="cartesian2d",e.dimensions=hr,e}return Object(qt["a"])(e,t),e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,e=this.getAxis("y").scale;if(dr(t)&&dr(e)){var n=t.getExtent(),i=e.getExtent(),r=this.dataToPoint([n[0],i[0]]),a=this.dataToPoint([n[1],i[1]]),o=n[1]-n[0],s=i[1]-i[0];if(o&&s){var l=(a[0]-r[0])/o,u=(a[1]-r[1])/s,c=r[0]-n[0]*l,h=r[1]-i[0]*u,d=this._transform=[l,0,0,u,c,h];this._invTransform=Object(ur["e"])([],d)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var e=this.getAxis("x"),n=this.getAxis("y");return e.contain(e.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,e){var n=this.dataToPoint(t),i=this.dataToPoint(e),r=this.getArea(),a=new ki["a"](n[0],n[1],i[0]-n[0],i[1]-n[1]);return r.intersect(a)},e.prototype.dataToPoint=function(t,e,n){n=n||[];var i=t[0],r=t[1];if(this._transform&&null!=i&&isFinite(i)&&null!=r&&isFinite(r))return Object(cr["b"])(n,t,this._transform);var a=this.getAxis("x"),o=this.getAxis("y");return n[0]=a.toGlobalCoord(a.dataToCoord(i,e)),n[1]=o.toGlobalCoord(o.dataToCoord(r,e)),n},e.prototype.clampData=function(t,e){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,r=n.getExtent(),a=i.getExtent(),o=n.parse(t[0]),s=i.parse(t[1]);return e=e||[],e[0]=Math.min(Math.max(Math.min(r[0],r[1]),o),Math.max(r[0],r[1])),e[1]=Math.min(Math.max(Math.min(a[0],a[1]),s),Math.max(a[0],a[1])),e},e.prototype.pointToData=function(t,e){var n=[];if(this._invTransform)return Object(cr["b"])(n,t,this._invTransform);var i=this.getAxis("x"),r=this.getAxis("y");return n[0]=i.coordToData(i.toLocalCoord(t[0]),e),n[1]=r.coordToData(r.toLocalCoord(t[1]),e),n},e.prototype.getOtherAxis=function(t){return this.getAxis("x"===t.dim?"y":"x")},e.prototype.getArea=function(){var t=this.getAxis("x").getGlobalExtent(),e=this.getAxis("y").getGlobalExtent(),n=Math.min(t[0],t[1]),i=Math.min(e[0],e[1]),r=Math.max(t[0],t[1])-n,a=Math.max(e[0],e[1])-i;return new ki["a"](n,i,r,a)},e}(lr["a"]),pr=fr,gr=n("84ce"),mr=function(t){function e(e,n,i,r,a){var o=t.call(this,e,n,i)||this;return o.index=0,o.type=r||"value",o.position=a||"bottom",o}return Object(qt["a"])(e,t),e.prototype.isHorizontal=function(){var t=this.position;return"top"===t||"bottom"===t},e.prototype.getGlobalExtent=function(t){var e=this.getExtent();return e[0]=this.toGlobalCoord(e[0]),e[1]=this.toGlobalCoord(e[1]),t&&e[0]>e[1]&&e.reverse(),e},e.prototype.pointToData=function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},e.prototype.setCategorySortInfo=function(t){if("category"!==this.type)return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e}(gr["a"]),vr=mr;function yr(t,e,n){n=n||{};var i=t.coordinateSystem,r=e.axis,a={},o=r.getAxesOnZeroOf()[0],s=r.position,l=o?"onZero":s,u=r.dim,c=i.getRect(),h=[c.x,c.x+c.width,c.y,c.y+c.height],d={left:0,right:1,top:0,bottom:1,onZero:2},f=e.get("offset")||0,p="x"===u?[h[2]-f,h[3]+f]:[h[0]-f,h[1]+f];if(o){var g=o.toGlobalCoord(o.dataToCoord(0));p[d.onZero]=Math.max(Math.min(g,p[1]),p[0])}a.position=["y"===u?p[d[l]]:h[0],"x"===u?p[d[l]]:h[3]],a.rotation=Math.PI/2*("x"===u?0:1);var m={top:-1,bottom:1,left:-1,right:1};a.labelDirection=a.tickDirection=a.nameDirection=m[s],a.labelOffset=o?p[d[s]]-p[d.onZero]:0,e.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),_["O"](n.labelInside,e.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var v=e.get(["axisLabel","rotate"]);return a.labelRotate="top"===l?-v:v,a.z2=1,a}function _r(t){return"cartesian2d"===t.get("coordinateSystem")}function br(t){var e={xAxisModel:null,yAxisModel:null};return _["k"](e,(function(n,i){var r=i.replace(/Model$/,""),a=t.getReferringComponents(r,Te["b"]).models[0];e[i]=a})),e}var xr=n("944e"),wr=n("89e3"),Or=Math.log;function Sr(t,e,n){var i=wr["a"].prototype,r=i.getTicks.call(n),a=i.getTicks.call(n,!0),o=r.length-1,s=i.getInterval.call(n),l=Object(sr["f"])(t,e),u=l.extent,c=l.fixMin,h=l.fixMax;if("log"===t.type){var d=Or(t.base);u=[Or(u[0])/d,Or(u[1])/d]}t.setExtent(u[0],u[1]),t.calcNiceExtent({splitNumber:o,fixMin:c,fixMax:h});var f=i.getExtent.call(t);c&&(u[0]=f[0]),h&&(u[1]=f[1]);var p=i.getInterval.call(t),g=u[0],m=u[1];if(c&&h)p=(m-g)/o;else if(c){m=u[0]+p*o;while(mu[0]&&isFinite(g)&&isFinite(u[0]))p=Object(xr["c"])(p),g=u[1]-p*o}else{var v=t.getTicks().length-1;v>o&&(p=Object(xr["c"])(p));var y=p*o;m=Math.ceil(u[1]/p)*p,g=Object(Be["v"])(m-y),g<0&&u[0]>=0?(g=0,m=Object(Be["v"])(y)):m>0&&u[1]<=0&&(m=0,g=-Object(Be["v"])(y))}var _=(r[0].value-a[0].value)/s,b=(r[o].value-a[o].value)/s;i.setExtent.call(t,g+p*_,m+p*b),i.setInterval.call(t,p),(_||b)&&i.setNiceExtent.call(t,g+p,m-p)}var Tr=function(){function t(t,e,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=hr,this._initCartesian(t,e,n),this.model=t}return t.prototype.getRect=function(){return this._rect},t.prototype.update=function(t,e){var n=this._axesMap;function i(t){var e,n=Object(_["F"])(t),i=n.length;if(i){for(var r=[],a=i-1;a>=0;a--){var o=+n[a],s=t[o],l=s.model,u=s.scale;Object(xr["e"])(u)&&l.get("alignTicks")&&null==l.get("interval")?r.push(s):(Object(sr["i"])(u,l),Object(xr["e"])(u)&&(e=s))}r.length&&(e||(e=r.pop(),Object(sr["i"])(e.scale,e.model)),Object(_["k"])(r,(function(t){Sr(t.scale,t.model,e.scale)})))}}this._updateScale(t,this.model),i(n.x),i(n.y);var r={};Object(_["k"])(n.x,(function(t){Ar(n,"y",t,r)})),Object(_["k"])(n.y,(function(t){Ar(n,"x",t,r)})),this.resize(this.model,e)},t.prototype.resize=function(t,e,n){var i=t.getBoxLayoutParams(),r=!n&&t.get("containLabel"),a=Object(ri["g"])(i,{width:e.getWidth(),height:e.getHeight()});this._rect=a;var o=this._axesList;function s(){Object(_["k"])(o,(function(t){var e=t.isHorizontal(),n=e?[0,a.width]:[0,a.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),Ir(t,e?a.x:a.y)}))}s(),r&&(Object(_["k"])(o,(function(t){if(!t.model.get(["axisLabel","inside"])){var e=Object(sr["b"])(t);if(e){var n=t.isHorizontal()?"height":"width",i=t.model.get(["axisLabel","margin"]);a[n]-=e[n]+i,"top"===t.position?a.y+=e.height+i:"left"===t.position&&(a.x+=e.width+i)}}})),s()),Object(_["k"])(this._coordsList,(function(t){t.calcAffineTransform()}))},t.prototype.getAxis=function(t,e){var n=this._axesMap[t];if(null!=n)return n[e||0]},t.prototype.getAxes=function(){return this._axesList.slice()},t.prototype.getCartesian=function(t,e){if(null!=t&&null!=e){var n="x"+t+"y"+e;return this._coordsMap[n]}Object(_["A"])(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,r=this._coordsList;i0?"top":"bottom",i="center"):Object(Be["k"])(a-jr)?(r=n>0?"bottom":"top",i="center"):(r="middle",i=a>0&&a0?"right":"left":n>0?"left":"right"),{rotation:a,textAlign:i,textVerticalAlign:r}},t.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},t.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},t}(),Nr={axisLine:function(t,e,n,i){var r=e.get(["axisLine","show"]);if("auto"===r&&t.handleAutoShown&&(r=t.handleAutoShown("axisLine")),r){var a=e.axis.getExtent(),o=i.transform,s=[a[0],0],l=[a[1],0];o&&(Object(cr["b"])(s,s,o),Object(cr["b"])(l,l,o));var u=Object(_["m"])({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),c=new Lr["a"]({subPixelOptimize:!0,shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:u,strokeContainThreshold:t.strokeContainThreshold||5,silent:!0,z2:1});c.anid="line",n.add(c);var h=e.get(["axisLine","symbol"]);if(null!=h){var d=e.get(["axisLine","symbolSize"]);Object(_["C"])(h)&&(h=[h,h]),(Object(_["C"])(d)||Object(_["z"])(d))&&(d=[d,d]);var f=Object(Qt["b"])(e.get(["axisLine","symbolOffset"])||0,d),p=d[0],g=d[1];Object(_["k"])([{rotate:t.rotation+Math.PI/2,offset:f[0],r:0},{rotate:t.rotation-Math.PI/2,offset:f[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],(function(e,i){if("none"!==h[i]&&null!=h[i]){var r=Object(Qt["a"])(h[i],-p/2,-g/2,p,g,u.stroke,!0),a=e.r+e.offset;r.attr({rotation:e.rotate,x:s[0]+a*Math.cos(t.rotation),y:s[1]-a*Math.sin(t.rotation),silent:!0,z2:11}),n.add(r)}}))}}},axisTickLabel:function(t,e,n,i){var r=Gr(n,i,e,t),a=Ur(n,i,e,t);if(kr(e,a,r),Hr(n,i,e,t.tickDirection),e.get(["axisLabel","hideOverlap"])){var o=Object(pi["b"])(Object(_["H"])(a,(function(t){return{label:t,priority:t.z2,defaultAttr:{ignore:t.ignore}}})));Object(pi["a"])(o)}},axisName:function(t,e,n,i){var r=Object(_["O"])(t.axisName,e.get("name"));if(r){var a,o,s=e.get("nameLocation"),l=t.nameDirection,u=e.getModel("nameTextStyle"),c=e.get("nameGap")||0,h=e.axis.getExtent(),d=h[0]>h[1]?-1:1,f=["start"===s?h[0]-d*c:"end"===s?h[1]+d*c:(h[0]+h[1])/2,Vr(s)?t.labelOffset+l*c:0],p=e.get("nameRotate");null!=p&&(p=p*jr/180),Vr(s)?a=Pr.innerTextLayout(t.rotation,null!=p?p:t.rotation,l):(a=Rr(t.rotation,s,p||0,h),o=t.axisNameAvailableWidth,null!=o&&(o=Math.abs(o/Math.sin(a.rotation)),!isFinite(o)&&(o=null)));var g=u.getFont(),m=e.get("nameTruncate",!0)||{},v=m.ellipsis,y=Object(_["O"])(t.nameTruncateMaxWidth,m.maxWidth,o),b=new $["a"]({x:f[0],y:f[1],rotation:a.rotation,silent:Pr.isLabelSilent(e),style:Object(le["c"])(u,{text:r,font:g,overflow:"truncate",width:y,ellipsis:v,fill:u.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:u.get("align")||a.textAlign,verticalAlign:u.get("verticalAlign")||a.textVerticalAlign}),z2:1});if(ne["setTooltipConfig"]({el:b,componentModel:e,itemName:r}),b.__fullText=r,b.anid="name",e.get("triggerEvent")){var x=Pr.makeAxisEventDataBase(e);x.targetType="axisName",x.name=r,Object(ie["a"])(b).eventData=x}i.add(b),b.updateTransform(),n.add(b),b.decomposeTransform()}}};function Rr(t,e,n,i){var r,a,o=Object(Be["u"])(n-t),s=i[0]>i[1],l="start"===e&&!s||"start"!==e&&s;return Object(Be["k"])(o-jr/2)?(a=l?"bottom":"top",r="center"):Object(Be["k"])(o-1.5*jr)?(a=l?"top":"bottom",r="center"):(a="middle",r=o<1.5*jr&&o>jr/2?l?"left":"right":l?"right":"left"),{rotation:o,textAlign:r,textVerticalAlign:a}}function kr(t,e,n){if(!Object(sr["j"])(t.axis)){var i=t.get(["axisLabel","showMinLabel"]),r=t.get(["axisLabel","showMaxLabel"]);e=e||[],n=n||[];var a=e[0],o=e[1],s=e[e.length-1],l=e[e.length-2],u=n[0],c=n[1],h=n[n.length-1],d=n[n.length-2];!1===i?(Br(a),Br(u)):zr(a,o)&&(i?(Br(o),Br(c)):(Br(a),Br(u))),!1===r?(Br(s),Br(h)):zr(l,s)&&(r?(Br(l),Br(d)):(Br(s),Br(h)))}}function Br(t){t&&(t.ignore=!0)}function zr(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var r=ur["d"]([]);return ur["g"](r,r,-t.rotation),n.applyTransform(ur["f"]([],r,t.getLocalTransform())),i.applyTransform(ur["f"]([],r,e.getLocalTransform())),n.intersect(i)}}function Vr(t){return"middle"===t||"center"===t}function Fr(t,e,n,i,r){for(var a=[],o=[],s=[],l=0;l=0||t===e}function Jr(t){var e=$r(t);if(e){var n=e.axisPointerModel,i=e.axis.scale,r=n.option,a=n.get("status"),o=n.get("value");null!=o&&(o=i.parse(o));var s=ea(n);null==a&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==o||o>l[1])&&(o=l[1]),o0&&!h.min?h.min=0:null!=h.min&&h.min<0&&!h.max&&(h.max=0);var d=o;null!=h.color&&(d=_["i"]({color:h.color},o));var f=_["I"](_["d"](h),{boundaryGap:t,splitNumber:e,scale:n,axisLine:i,axisTick:r,axisLabel:a,name:h.text,showName:s,nameLocation:"end",nameGap:u,nameTextStyle:d,triggerEvent:c},!1);if(_["C"](l)){var p=f.name;f.name=l.replace("{value}",null!=p?p:"")}else _["w"](l)&&(f.name=l(f.name,f));var g=new Er["a"](f,null,this.ecModel);return _["K"](g,Yi["a"].prototype),g.mainType="radar",g.componentIndex=this.componentIndex,g}),this);this._indicatorModels=h},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:_["I"]({lineStyle:{color:"#bbb"}},Ia.axisLine),axisLabel:Da(Ia.axisLabel,!1),axisTick:Da(Ia.axisTick,!1),splitLine:Da(Ia.splitLine,!0),splitArea:Da(Ia.splitArea,!0),indicator:[]},e}(Xi["a"]),Ea=La,ja=n("d9fc"),Pa=n("4573"),Na=["axisLine","axisTickLabel","axisName"],Ra=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=this.group;i.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var e=t.coordinateSystem,n=e.getIndicatorAxes(),i=_["H"](n,(function(t){var n=t.model.get("showName")?t.name:"",i=new Wr(t.model,{axisName:n,position:[e.cx,e.cy],rotation:t.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return i}));_["k"](i,(function(t){_["k"](Na,t.add,t),this.group.add(t.getGroup())}),this)},e.prototype._buildSplitLineAndArea=function(t){var e=t.coordinateSystem,n=e.getIndicatorAxes();if(n.length){var i=t.get("shape"),r=t.getModel("splitLine"),a=t.getModel("splitArea"),o=r.getModel("lineStyle"),s=a.getModel("areaStyle"),l=r.get("show"),u=a.get("show"),c=o.get("color"),h=s.get("color"),d=_["t"](c)?c:[c],f=_["t"](h)?h:[h],p=[],g=[];if("circle"===i)for(var m=n[0].getTicksCoords(),v=e.cx,y=e.cy,b=0;b3?1.4:r>1?1.2:1.1,l=i>0?s:1/s;$a(this,"zoom","zoomOnMouseWheel",t,{scale:l,originX:a,originY:o,isAvailableBehavior:null})}if(n){var u=Math.abs(i),c=(i>0?1:-1)*(u>3?.4:u>1?.15:.05);$a(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:c,originX:a,originY:o,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){if(!Ka(this._zr,"globalPan")){var e=t.pinchScale>1?1.1:1/1.1;$a(this,"zoom",null,t,{scale:e,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e}(Ua["a"]);function $a(t,e,n,i,r){t.pointerChecker&&t.pointerChecker(i,r.originX,r.originY)&&(Wa["g"](i.event),to(t,e,n,i,r))}function to(t,e,n,i,r){r.isAvailableBehavior=Object(_["c"])(eo,null,n,i),t.trigger(e,r)}function eo(t,e,n){var i=n[t];return!t||i&&(!Object(_["C"])(i)||e.event[i+"Key"])}var no=Ja;function io(t,e,n){var i=t.target;i.x+=e,i.y+=n,i.dirty()}function ro(t,e,n,i){var r=t.target,a=t.zoomLimit,o=t.zoom=t.zoom||1;if(o*=e,a){var s=a.min||0,l=a.max||1/0;o=Math.max(Math.min(l,o),s)}var u=o/t.zoom;t.zoom=o,r.x-=(n-r.x)*(u-1),r.y-=(i-r.y)*(u-1),r.scaleX*=u,r.scaleY*=u,r.dirty()}var ao={axisPointer:1,tooltip:1,brush:1};function oo(t,e,n){var i=e.getComponentByElement(t.topTarget),r=i&&i.coordinateSystem;return i&&i!==n&&!ao.hasOwnProperty(i.mainType)&&r&&r.model!==n}var so,lo=n("ae69"),uo=n("342d"),co=n("dded");function ho(t){if(Object(_["C"])(t)){var e=new DOMParser;t=e.parseFromString(t,"text/xml")}var n=t;9===n.nodeType&&(n=n.firstChild);while("svg"!==n.nodeName.toLowerCase()||1!==n.nodeType)n=n.nextSibling;return n}var fo={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},po=Object(_["F"])(fo),go={"alignment-baseline":"textBaseline","stop-color":"stopColor"},mo=Object(_["F"])(go),vo=function(){function t(){this._defs={},this._root=null}return t.prototype.parse=function(t,e){e=e||{};var n=ho(t);this._defsUsePending=[];var i=new Jt["a"];this._root=i;var r=[],a=n.getAttribute("viewBox")||"",o=parseFloat(n.getAttribute("width")||e.width),s=parseFloat(n.getAttribute("height")||e.height);isNaN(o)&&(o=null),isNaN(s)&&(s=null),Oo(n,i,null,!0,!1);var l,u,c=n.firstChild;while(c)this._parseNode(c,i,r,null,!1,!1),c=c.nextSibling;if(Ao(this._defs,this._defsUsePending),this._defsUsePending=[],a){var h=Io(a);h.length>=4&&(l={x:parseFloat(h[0]||0),y:parseFloat(h[1]||0),width:parseFloat(h[2]),height:parseFloat(h[3])})}if(l&&null!=o&&null!=s&&(u=Ro(l,{x:0,y:0,width:o,height:s}),!e.ignoreViewBox)){var d=i;i=new Jt["a"],i.add(d),d.scaleX=d.scaleY=u.scale,d.x=u.x,d.y=u.y}return e.ignoreRootClip||null==o||null==s||i.setClipPath(new Re["a"]({shape:{x:0,y:0,width:o,height:s}})),{root:i,width:o,height:s,viewBoxRect:l,viewBoxTransform:u,named:r}},t.prototype._parseNode=function(t,e,n,i,r,a){var o,s=t.nodeName.toLowerCase(),l=i;if("defs"===s&&(r=!0),"text"===s&&(a=!0),"defs"===s||"switch"===s)o=e;else{if(!r){var u=so[s];if(u&&Object(_["q"])(so,s)){o=u.call(this,t,e);var c=t.getAttribute("name");if(c){var h={name:c,namedFrom:null,svgNodeTagLower:s,el:o};n.push(h),"g"===s&&(l=h)}else i&&n.push({name:i.name,namedFrom:i,svgNodeTagLower:s,el:o});e.add(o)}}var d=yo[s];if(d&&Object(_["q"])(yo,s)){var f=d.call(this,t),p=t.getAttribute("id");p&&(this._defs[p]=f)}}if(o&&o.isGroup){var g=t.firstChild;while(g)1===g.nodeType?this._parseNode(g,o,n,l,r,a):3===g.nodeType&&a&&this._parseText(g,o),g=g.nextSibling}},t.prototype._parseText=function(t,e){var n=new c["a"]({style:{text:t.textContent},silent:!0,x:this._textX||0,y:this._textY||0});xo(e,n),Oo(t,n,this._defsUsePending,!1,!1),So(n,e);var i=n.style,r=i.fontSize;r&&r<9&&(i.fontSize=9,n.scaleX*=r/9,n.scaleY*=r/9);var a=(i.fontSize||i.fontFamily)&&[i.fontStyle,i.fontWeight,(i.fontSize||12)+"px",i.fontFamily||"sans-serif"].join(" ");i.font=a;var o=n.getBoundingRect();return this._textX+=o.width,e.add(n),n},t.internalField=function(){so={g:function(t,e){var n=new Jt["a"];return xo(e,n),Oo(t,n,this._defsUsePending,!1,!1),n},rect:function(t,e){var n=new Re["a"];return xo(e,n),Oo(t,n,this._defsUsePending,!1,!1),n.setShape({x:parseFloat(t.getAttribute("x")||"0"),y:parseFloat(t.getAttribute("y")||"0"),width:parseFloat(t.getAttribute("width")||"0"),height:parseFloat(t.getAttribute("height")||"0")}),n.silent=!0,n},circle:function(t,e){var n=new ja["a"];return xo(e,n),Oo(t,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(t.getAttribute("cx")||"0"),cy:parseFloat(t.getAttribute("cy")||"0"),r:parseFloat(t.getAttribute("r")||"0")}),n.silent=!0,n},line:function(t,e){var n=new Lr["a"];return xo(e,n),Oo(t,n,this._defsUsePending,!1,!1),n.setShape({x1:parseFloat(t.getAttribute("x1")||"0"),y1:parseFloat(t.getAttribute("y1")||"0"),x2:parseFloat(t.getAttribute("x2")||"0"),y2:parseFloat(t.getAttribute("y2")||"0")}),n.silent=!0,n},ellipse:function(t,e){var n=new lo["a"];return xo(e,n),Oo(t,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(t.getAttribute("cx")||"0"),cy:parseFloat(t.getAttribute("cy")||"0"),rx:parseFloat(t.getAttribute("rx")||"0"),ry:parseFloat(t.getAttribute("ry")||"0")}),n.silent=!0,n},polygon:function(t,e){var n,i=t.getAttribute("points");i&&(n=wo(i));var r=new Oa["a"]({shape:{points:n||[]},silent:!0});return xo(e,r),Oo(t,r,this._defsUsePending,!1,!1),r},polyline:function(t,e){var n,i=t.getAttribute("points");i&&(n=wo(i));var r=new hi["a"]({shape:{points:n||[]},silent:!0});return xo(e,r),Oo(t,r,this._defsUsePending,!1,!1),r},image:function(t,e){var n=new l["a"];return xo(e,n),Oo(t,n,this._defsUsePending,!1,!1),n.setStyle({image:t.getAttribute("xlink:href")||t.getAttribute("href"),x:+t.getAttribute("x"),y:+t.getAttribute("y"),width:+t.getAttribute("width"),height:+t.getAttribute("height")}),n.silent=!0,n},text:function(t,e){var n=t.getAttribute("x")||"0",i=t.getAttribute("y")||"0",r=t.getAttribute("dx")||"0",a=t.getAttribute("dy")||"0";this._textX=parseFloat(n)+parseFloat(r),this._textY=parseFloat(i)+parseFloat(a);var o=new Jt["a"];return xo(e,o),Oo(t,o,this._defsUsePending,!1,!0),o},tspan:function(t,e){var n=t.getAttribute("x"),i=t.getAttribute("y");null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i));var r=t.getAttribute("dx")||"0",a=t.getAttribute("dy")||"0",o=new Jt["a"];return xo(e,o),Oo(t,o,this._defsUsePending,!1,!0),this._textX+=parseFloat(r),this._textY+=parseFloat(a),o},path:function(t,e){var n=t.getAttribute("d")||"",i=Object(uo["b"])(n);return xo(e,i),Oo(t,i,this._defsUsePending,!1,!1),i.silent=!0,i}}}(),t}(),yo={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||"0",10),n=parseInt(t.getAttribute("y1")||"0",10),i=parseInt(t.getAttribute("x2")||"10",10),r=parseInt(t.getAttribute("y2")||"0",10),a=new Se["a"](e,n,i,r);return _o(t,a),bo(t,a),a},radialgradient:function(t){var e=parseInt(t.getAttribute("cx")||"0",10),n=parseInt(t.getAttribute("cy")||"0",10),i=parseInt(t.getAttribute("r")||"0",10),r=new co["a"](e,n,i);return _o(t,r),bo(t,r),r}};function _o(t,e){var n=t.getAttribute("gradientUnits");"userSpaceOnUse"===n&&(e.global=!0)}function bo(t,e){var n=t.firstChild;while(n){if(1===n.nodeType&&"stop"===n.nodeName.toLocaleLowerCase()){var i=n.getAttribute("offset"),r=void 0;r=i&&i.indexOf("%")>0?parseInt(i,10)/100:i?parseFloat(i):0;var a={};Po(n,a,a);var o=a.stopColor||n.getAttribute("stop-color")||"#000000";e.colorStops.push({offset:r,color:o})}n=n.nextSibling}}function xo(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),Object(_["i"])(e.__inheritedStyle,t.__inheritedStyle))}function wo(t){for(var e=Io(t),n=[],i=0;i0;a-=2){var o=i[a],s=i[a-1],l=Io(o);switch(r=r||ur["c"](),s){case"translate":ur["i"](r,r,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":ur["h"](r,r,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":ur["g"](r,r,-parseFloat(l[0])*Lo);break;case"skewX":var u=Math.tan(parseFloat(l[0])*Lo);ur["f"](r,[1,0,u,1,0,0],r);break;case"skewY":var c=Math.tan(parseFloat(l[0])*Lo);ur["f"](r,[1,c,0,1,0,0],r);break;case"matrix":r[0]=parseFloat(l[0]),r[1]=parseFloat(l[1]),r[2]=parseFloat(l[2]),r[3]=parseFloat(l[3]),r[4]=parseFloat(l[4]),r[5]=parseFloat(l[5]);break}}e.setLocalTransform(r)}}var jo=/([^\s:;]+)\s*:\s*([^:;]+)/g;function Po(t,e,n){var i=t.getAttribute("style");if(i){var r;jo.lastIndex=0;while(null!=(r=jo.exec(i))){var a=r[1],o=Object(_["q"])(fo,a)?fo[a]:null;o&&(e[o]=r[2]);var s=Object(_["q"])(go,a)?go[a]:null;s&&(n[s]=r[2])}}}function No(t,e,n){for(var i=0;i0,g={api:n,geo:s,mapOrGeoModel:t,data:o,isVisualEncodedByVisualMap:p,isGeo:a,transformInfoRaw:h};"geoJSON"===s.resourceType?this._buildGeoJSON(g):"geoSVG"===s.resourceType&&this._buildSVG(g),this._updateController(t,e,n),this._updateMapSelectHandler(t,l,n,i)},t.prototype._buildGeoJSON=function(t){var e=this._regionsGroupByName=_["f"](),n=_["f"](),i=this._regionsGroup,r=t.transformInfoRaw,a=t.mapOrGeoModel,o=t.data,s=t.geo.projection,l=s&&s.stream;function u(t,e){return e&&(t=e(t)),t&&[t[0]*r.scaleX+r.x,t[1]*r.scaleY+r.y]}function c(t){for(var e=[],n=!l&&s&&s.project,i=0;i=0)&&(d=r);var f=o?{normal:{align:"center",verticalAlign:"middle"}}:null;Object(le["g"])(e,Object(le["e"])(i),{labelFetcher:d,labelDataIndex:h,defaultText:n},f);var p=e.getTextContent();if(p&&(hs(p).ignore=p.ignore,e.textConfig&&o)){var g=e.getBoundingRect().clone();e.textConfig.layoutRect=g,e.textConfig.position=[(o[0]-g.x)/g.width*100+"%",(o[1]-g.y)/g.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function vs(t,e,n,i,r,a){t.data?t.data.setItemGraphicEl(a,e):Object(ie["a"])(e).eventData={componentType:"geo",componentIndex:r.componentIndex,geoIndex:r.componentIndex,name:n,region:i&&i.option||{}}}function ys(t,e,n,i,r){t.data||ne["setTooltipConfig"]({el:e,componentModel:r,itemName:n,itemTooltipOption:i.get("tooltip")})}function _s(t,e,n,i,r){e.highDownSilentOnTouch=!!r.get("selectedMode");var a=i.getModel("emphasis"),o=a.get("focus");return Object(re["J"])(e,o,a.get("blurScope"),a.get("disabled")),t.isGeo&&Object(re["n"])(e,r,n),o}function bs(t,e,n){var i,r=[];function a(){i=[]}function o(){i.length&&(r.push(i),i=[])}var s=e({polygonStart:a,polygonEnd:o,lineStart:a,lineEnd:o,point:function(t,e){isFinite(t)&&isFinite(e)&&i.push([t,e])},sphere:function(){}});return!n&&s.polygonStart(),_["k"](t,(function(t){s.lineStart();for(var e=0;e-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},e}(Kt["b"]),Ts=Ss;function Ms(t,e){var n={};return _["k"](t,(function(t){t.each(t.mapDimension("value"),(function(e,i){var r="ec-"+t.getName(i);n[r]=n[r]||[],isNaN(e)||n[r].push(e)}))})),t[0].map(t[0].mapDimension("value"),(function(i,r){for(var a,o="ec-"+t[0].getName(r),s=0,l=1/0,u=-1/0,c=n[o].length,h=0;h1?(f.width=d,f.height=d/_):(f.height=d,f.width=d*_),f.y=h[1]-f.height/2,f.x=h[0]-f.width/2;else{var x=t.getBoxLayoutParams();x.aspect=_,f=ri["g"](x,{width:v,height:y})}this.setViewRect(f.x,f.y,f.width,f.height),this.setCenter(t.get("center"),e),this.setZoom(t.get("zoom"))}function zs(t,e){_["k"](e.get("geoCoord"),(function(e,n){t.addGeoCoord(n,e)}))}var Vs=function(){function t(){this.dimensions=Ps}return t.prototype.create=function(t,e){var n=[];function i(t){return{nameProperty:t.get("nameProperty"),aspectScale:t.get("aspectScale"),projection:t.get("projection")}}t.eachComponent("geo",(function(t,r){var a=t.get("map"),o=new ks(a+r,a,_["m"]({nameMap:t.get("nameMap")},i(t)));o.zoomLimit=t.get("scaleLimit"),n.push(o),t.coordinateSystem=o,o.model=t,o.resize=Bs,o.resize(t,e)})),t.eachSeries((function(t){var e=t.get("coordinateSystem");if("geo"===e){var i=t.get("geoIndex")||0;t.coordinateSystem=n[i]}}));var r={};return t.eachSeriesByType("map",(function(t){if(!t.getHostGeoModel()){var e=t.getMapType();r[e]=r[e]||[],r[e].push(t)}})),_["k"](r,(function(t,r){var a=_["H"](t,(function(t){return t.get("nameMap")})),o=new ks(r,r,_["m"]({nameMap:_["J"](a)},i(t[0])));o.zoomLimit=_["O"].apply(null,_["H"](t,(function(t){return t.get("scaleLimit")}))),n.push(o),o.resize=Bs,o.resize(t[0],e),_["k"](t,(function(t){t.coordinateSystem=o,zs(o,t)}))})),n},t.prototype.getFilledRegions=function(t,e,n,i){for(var r=(t||[]).slice(),a=_["f"](),o=0;o=0;o--){var s=i[o];s.hierNode={defaultAncestor:null,ancestor:s,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},r.push(s)}}function el(t,e){var n=t.isExpand?t.children:[],i=t.parentNode.children,r=t.hierNode.i?i[t.hierNode.i-1]:null;if(n.length){ol(t);var a=(n[0].hierNode.prelim+n[n.length-1].hierNode.prelim)/2;r?(t.hierNode.prelim=r.hierNode.prelim+e(t,r),t.hierNode.modifier=t.hierNode.prelim-a):t.hierNode.prelim=a}else r&&(t.hierNode.prelim=r.hierNode.prelim+e(t,r));t.parentNode.hierNode.defaultAncestor=sl(t,r,t.parentNode.hierNode.defaultAncestor||i[0],e)}function nl(t){var e=t.hierNode.prelim+t.parentNode.hierNode.modifier;t.setLayout({x:e},!0),t.hierNode.modifier+=t.parentNode.hierNode.modifier}function il(t){return arguments.length?t:dl}function rl(t,e){return t-=Math.PI/2,{x:e*Math.cos(t),y:e*Math.sin(t)}}function al(t,e){return ri["g"](t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function ol(t){var e=t.children,n=e.length,i=0,r=0;while(--n>=0){var a=e[n];a.hierNode.prelim+=i,a.hierNode.modifier+=i,r+=a.hierNode.change,i+=a.hierNode.shift+r}}function sl(t,e,n,i){if(e){var r=t,a=t,o=a.parentNode.children[0],s=e,l=r.hierNode.modifier,u=a.hierNode.modifier,c=o.hierNode.modifier,h=s.hierNode.modifier;while(s=ll(s),a=ul(a),s&&a){r=ll(r),o=ul(o),r.hierNode.ancestor=t;var d=s.hierNode.prelim+h-a.hierNode.prelim-u+i(s,a);d>0&&(hl(cl(s,t,n),t,d),u+=d,l+=d),h+=s.hierNode.modifier,u+=a.hierNode.modifier,l+=r.hierNode.modifier,c+=o.hierNode.modifier}s&&!ll(r)&&(r.hierNode.thread=s,r.hierNode.modifier+=h-l),a&&!ul(o)&&(o.hierNode.thread=a,o.hierNode.modifier+=u-c,n=t)}return n}function ll(t){var e=t.children;return e.length&&t.isExpand?e[e.length-1]:t.hierNode.thread}function ul(t){var e=t.children;return e.length&&t.isExpand?e[0]:t.hierNode.thread}function cl(t,e,n){return t.hierNode.ancestor.parentNode===e.parentNode?t.hierNode.ancestor:n}function hl(t,e,n){var i=n/(e.hierNode.i-t.hierNode.i);e.hierNode.change-=i,e.hierNode.shift+=n,e.hierNode.modifier+=n,e.hierNode.prelim+=n,t.hierNode.change+=i}function dl(t,e){return t.parentNode===e.parentNode?1:2}var fl=n("e263"),pl=function(){function t(){this.parentPoint=[],this.childPoints=[]}return t}(),gl=function(t){function e(e){return t.call(this,e)||this}return Object(qt["a"])(e,t),e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new pl},e.prototype.buildPath=function(t,e){var n=e.childPoints,i=n.length,r=e.parentPoint,a=n[0],o=n[i-1];if(1===i)return t.moveTo(r[0],r[1]),void t.lineTo(a[0],a[1]);var s=e.orient,l="TB"===s||"BT"===s?0:1,u=1-l,c=Object(Be["p"])(e.forkPosition,1),h=[];h[l]=r[l],h[u]=r[u]+(o[u]-r[u])*c,t.moveTo(r[0],r[1]),t.lineTo(h[0],h[1]),t.moveTo(a[0],a[1]),h[l]=a[l],t.lineTo(h[0],h[1]),h[l]=o[l],t.lineTo(h[0],h[1]),t.lineTo(o[0],o[1]);for(var d=1;dy.x,w||(x-=Math.PI));var S=w?"left":"right",T=s.getModel("label"),M=T.get("rotate"),A=M*(Math.PI/180),C=m.getTextContent();C&&(m.setTextConfig({position:T.get("position")||S,rotation:null==M?-x:A,origin:"center"}),C.setStyle("verticalAlign","middle"))}var I=s.get(["emphasis","focus"]),D="relative"===I?_["e"](o.getAncestorsIndices(),o.getDescendantIndices()):"ancestor"===I?o.getAncestorsIndices():"descendant"===I?o.getDescendantIndices():null;D&&(Object(ie["a"])(n).focus=D),_l(r,o,c,n,p,f,g,i),n.__edge&&(n.onHoverStateChange=function(e){if("blur"!==e){var i=o.parentNode&&t.getItemGraphicEl(o.parentNode.dataIndex);i&&i.hoverState===re["d"]||Object(re["H"])(n.__edge,e)}})}function _l(t,e,n,i,r,a,o,s){var l=e.getModel(),u=t.get("edgeShape"),c=t.get("layout"),h=t.getOrient(),d=t.get(["lineStyle","curveness"]),f=t.get("edgeForkPosition"),p=l.getModel("lineStyle").getLineStyle(),g=i.__edge;if("curve"===u)e.parentNode&&e.parentNode!==n&&(g||(g=i.__edge=new $s["a"]({shape:Ol(c,h,d,r,r)})),ee["h"](g,{shape:Ol(c,h,d,a,o)},t));else if("polyline"===u)if("orthogonal"===c){if(e!==n&&e.children&&0!==e.children.length&&!0===e.isExpand){for(var m=e.children,v=[],y=0;ye&&(e=i.height)}this.height=e+1},t.prototype.getNodeById=function(t){if(this.getId()===t)return this;for(var e=0,n=this.children,i=n.length;e=0&&this.hostTree.data.setItemLayout(this.dataIndex,t,e)},t.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},t.prototype.getModel=function(t){if(!(this.dataIndex<0)){var e=this.hostTree,n=e.data.getItemModel(this.dataIndex);return n.getModel(t)}},t.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},t.prototype.setVisual=function(t,e){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,t,e)},t.prototype.getVisual=function(t){return this.hostTree.data.getItemVisual(this.dataIndex,t)},t.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},t.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},t.prototype.getChildIndex=function(){if(this.parentNode){for(var t=this.parentNode.children,e=0;e=0){var i=n.getData().tree.root,r=t.targetNode;if(_["C"](r)&&(r=i.getNodeById(r)),r&&i.contains(r))return{node:r};var a=t.targetNodeId;if(null!=a&&(r=i.getNodeById(a)))return{node:r}}}function Ll(t){var e=[];while(t)t=t.parentNode,t&&e.push(t);return e.reverse()}function El(t,e){var n=Ll(t);return _["r"](n,e)>=0}function jl(t,e){var n=[];while(t){var i=t.dataIndex;n.push({name:t.name,dataIndex:i,value:e.getRawValue(i)}),t=t.parentNode}return n.reverse(),n}var Pl=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.hasSymbolVisual=!0,e.ignoreStyleOnData=!0,e}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t){var e={name:t.name,children:t.data},n=t.leaves||{},i=new Er["a"](n,this,this.ecModel),r=Il.createTree(e,this,a);function a(t){t.wrapMethod("getItemModel",(function(t,e){var n=r.getNodeByDataIndex(e);return n&&n.children.length&&n.isExpand||(t.parentModel=i),t}))}var o=0;r.eachNode("preorder",(function(t){t.depth>o&&(o=t.depth)}));var s=t.expandAndCollapse,l=s&&t.initialTreeDepth>=0?t.initialTreeDepth:o;return r.root.eachNode("preorder",(function(t){var e=t.hostTree.data.getRawDataItem(t.dataIndex);t.isExpand=e&&null!=e.collapsed?!e.collapsed:t.depth<=l})),r.data},e.prototype.getOrient=function(){var t=this.get("orient");return"horizontal"===t?t="LR":"vertical"===t&&(t="TB"),t},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.formatTooltip=function(t,e,n){var i=this.getData().tree,r=i.root.children[0],a=i.getNodeByDataIndex(t),o=a.getValue(),s=a.name;while(a&&a!==r)s=a.parentNode.name+"."+s,a=a.parentNode;return Object(Ma["c"])("nameValue",{name:s,value:o,noValue:isNaN(o)||null==o})},e.prototype.getDataParams=function(e){var n=t.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(e);return n.treeAncestors=jl(i,this),n.collapsed=!i.isExpand,n},e.type="series.tree",e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},e}(Kt["b"]),Nl=Pl;function Rl(t,e,n){var i,r=[t],a=[];while(i=r.pop())if(a.push(i),i.isExpand){var o=i.children;if(o.length)for(var s=0;s=0;a--)i.push(r[a])}}function Bl(t,e){t.eachSeriesByType("tree",(function(t){zl(t,e)}))}function zl(t,e){var n=al(t,e);t.layoutInfo=n;var i=t.get("layout"),r=0,a=0,o=null;"radial"===i?(r=2*Math.PI,a=Math.min(n.height,n.width)/2,o=il((function(t,e){return(t.parentNode===e.parentNode?1:2)/t.depth}))):(r=n.width,a=n.height,o=il());var s=t.getData().tree.root,l=s.children[0];if(l){tl(s),Rl(l,el,o),s.hierNode.modifier=-l.hierNode.prelim,kl(l,nl);var u=l,c=l,h=l;kl(l,(function(t){var e=t.getLayout().x;ec.getLayout().x&&(c=t),t.depth>h.depth&&(h=t)}));var d=u===c?1:o(u,c)/2,f=d-u.getLayout().x,p=0,g=0,m=0,v=0;if("radial"===i)p=r/(c.getLayout().x+d+f),g=a/(h.depth-1||1),kl(l,(function(t){m=(t.getLayout().x+f)*p,v=(t.depth-1)*g;var e=rl(m,v);t.setLayout({x:e.x,y:e.y,rawX:m,rawY:v},!0)}));else{var y=t.getOrient();"RL"===y||"LR"===y?(g=a/(c.getLayout().x+d+f),p=r/(h.depth-1||1),kl(l,(function(t){v=(t.getLayout().x+f)*g,m="LR"===y?(t.depth-1)*p:r-(t.depth-1)*p,t.setLayout({x:m,y:v},!0)}))):"TB"!==y&&"BT"!==y||(p=r/(c.getLayout().x+d+f),g=a/(h.depth-1||1),kl(l,(function(t){m=(t.getLayout().x+f)*p,v="TB"===y?(t.depth-1)*g:a-(t.depth-1)*g,t.setLayout({x:m,y:v},!0)})))}}}function Vl(t){t.eachSeriesByType("tree",(function(t){var e=t.getData(),n=e.tree;n.eachNode((function(t){var n=t.getModel(),i=n.getModel("itemStyle").getItemStyle(),r=e.ensureUniqueItemVisual(t.dataIndex,"style");Object(_["m"])(r,i)}))}))}function Fl(t){t.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},(function(t,e){e.eachComponent({mainType:"series",subType:"tree",query:t},(function(e){var n=t.dataIndex,i=e.getData().tree,r=i.getNodeByDataIndex(n);r.isExpand=!r.isExpand}))})),t.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},(function(t,e,n){e.eachComponent({mainType:"series",subType:"tree",query:t},(function(e){var i=e.coordinateSystem,r=Xs(i,t,void 0,n);e.setCenter&&e.setCenter(r.center),e.setZoom&&e.setZoom(r.zoom)}))}))}function Gl(t){t.registerChartView(Sl),t.registerSeriesModel(Nl),t.registerLayout(Bl),t.registerVisual(Vl),Fl(t)}var Hl=["treemapZoomToNode","treemapRender","treemapMove"];function Ul(t){for(var e=0;e1)n=n.parentNode;var r=Object(Wl["b"])(t.ecModel,n.name||n.dataIndex+"",i);e.setVisual("decal",r)}))}var Zl=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.preventUsingHoverLayer=!0,n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data};ql(n);var i=t.levels||[],r=this.designatedVisualItemStyle={},a=new Er["a"]({itemStyle:r},this,e);i=t.levels=Yl(i,e);var o=_["H"](i||[],(function(t){return new Er["a"](t,a,e)}),this),s=Il.createTree(n,this,l);function l(t){t.wrapMethod("getItemModel",(function(t,e){var n=s.getNodeByDataIndex(e),i=n?o[n.depth]:null;return t.parentModel=i||a,t}))}return s.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.formatTooltip=function(t,e,n){var i=this.getData(),r=this.getRawValue(t),a=i.getName(t);return Object(Ma["c"])("nameValue",{name:a,value:r})},e.prototype.getDataParams=function(e){var n=t.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(e);return n.treeAncestors=jl(i,this),n.treePathInfo=n.treeAncestors,n},e.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},_["m"](this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var e=this._idIndexMap;e||(e=this._idIndexMap=_["f"](),this._idIndexMapCount=0);var n=e.get(t);return null==n&&e.set(t,n=this._idIndexMapCount++),n},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var e=this.getRawData().tree.root;t&&(t===e||e.contains(t))||(this._viewRoot=e)},e.prototype.enableAriaDecal=function(){Xl(this)},e.type="series.treemap",e.layoutMode="box",e.defaultOption={progressive:0,left:"center",top:"middle",width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.1024,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",textStyle:{color:"#fff"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},e}(Kt["b"]);function ql(t){var e=0;_["k"](t.children,(function(t){ql(t);var n=t.value;_["t"](n)&&(n=n[0]),e+=n}));var n=t.value;_["t"](n)&&(n=n[0]),(null==n||isNaN(n))&&(n=e),n<0&&(n=0),_["t"](t.value)?t.value[0]=n:t.value=n}function Yl(t,e){var n=Object(Te["r"])(e.get("color")),i=Object(Te["r"])(e.get(["aria","decal","decals"]));if(n){var r,a;t=t||[],_["k"](t,(function(t){var e=new Er["a"](t),n=e.get("color"),i=e.get("decal");(e.get(["itemStyle","color"])||n&&"none"!==n)&&(r=!0),(e.get(["itemStyle","decal"])||i&&"none"!==i)&&(a=!0)}));var o=t[0]||(t[0]={});return r||(o.color=n.slice()),!a&&i&&(o.decal=i.slice()),t}}var Kl=Zl,Ql=n("80f0"),Jl=8,$l=8,tu=5,eu=function(){function t(t){this.group=new Jt["a"],t.add(this.group)}return t.prototype.render=function(t,e,n,i){var r=t.getModel("breadcrumb"),a=this.group;if(a.removeAll(),r.get("show")&&n){var o=r.getModel("itemStyle"),s=o.getModel("textStyle"),l={pos:{left:r.get("left"),right:r.get("right"),top:r.get("top"),bottom:r.get("bottom")},box:{width:e.getWidth(),height:e.getHeight()},emptyItemWidth:r.get("emptyItemWidth"),totalWidth:0,renderList:[]};this._prepare(n,l,s),this._renderContent(t,l,o,s,i),ri["i"](a,l.pos,l.box)}},t.prototype._prepare=function(t,e,n){for(var i=t;i;i=i.parentNode){var r=Object(Te["e"])(i.getModel().get("name"),""),a=n.getTextRect(r),o=Math.max(a.width+2*Jl,e.emptyItemWidth);e.totalWidth+=o+$l,e.renderList.push({node:i,text:r,width:o})}},t.prototype._renderContent=function(t,e,n,i,r){for(var a=0,o=e.emptyItemWidth,s=t.get(["breadcrumb","height"]),l=ri["e"](e.pos,e.box),u=e.totalWidth,c=e.renderList,h=c.length-1;h>=0;h--){var d=c[h],f=d.node,p=d.width,g=d.text;u>l.width&&(u-=p-o,p=o,g=null);var m=new Oa["a"]({shape:{points:nu(a,0,p,s,h===c.length-1,0===h)},style:Object(_["i"])(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new $["a"]({style:{text:g,fill:i.getTextColor(),font:i.getFont()}}),textConfig:{position:"inside"},z2:1e4*re["j"],onclick:Object(_["h"])(r,f)});m.disableLabelAnimation=!0,this.group.add(m),iu(m,t,f),a+=p+$l}},t.prototype.remove=function(){this.group.removeAll()},t}();function nu(t,e,n,i,r,a){var o=[[r?t:t-tu,e],[t+n,e],[t+n,e+i],[r?t:t-tu,e+i]];return!a&&o.splice(2,0,[t+n+tu,e+i/2]),!r&&o.push([t,e+i/2]),o}function iu(t,e,n){Object(ie["a"])(t).eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:n&&n.dataIndex,name:n&&n.name},treePathInfo:n&&jl(n,e)}}var ru=eu,au=function(){function t(){this._storage=[],this._elExistsMap={}}return t.prototype.add=function(t,e,n,i,r){return!this._elExistsMap[t.id]&&(this._elExistsMap[t.id]=!0,this._storage.push({el:t,target:e,duration:n,delay:i,easing:r}),!0)},t.prototype.finished=function(t){return this._finishedCallback=t,this},t.prototype.start=function(){for(var t=this,e=this._storage.length,n=function(){e--,e<=0&&(t._storage.length=0,t._elExistsMap={},t._finishedCallback&&t._finishedCallback())},i=0,r=this._storage.length;icu||Math.abs(t.dy)>cu)){var e=this.seriesModel.getData().tree.root;if(!e)return;var n=e.getLayout();if(!n)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+t.dx,y:n.y+t.dy,width:n.width,height:n.height}})}},e.prototype._onZoom=function(t){var e=t.originX,n=t.originY;if("animating"!==this._state){var i=this.seriesModel.getData().tree.root;if(!i)return;var r=i.getLayout();if(!r)return;var a=new ki["a"](r.x,r.y,r.width,r.height),o=this.seriesModel.layoutInfo;e-=o.x,n-=o.y;var s=ur["c"]();ur["i"](s,s,[-e,-n]),ur["h"](s,s,[t.scale,t.scale]),ur["i"](s,s,[e,n]),a.applyTransform(s),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:a.x,y:a.y,width:a.width,height:a.height}})}},e.prototype._initEvents=function(t){var e=this;t.on("click",(function(t){if("ready"===e._state){var n=e.seriesModel.get("nodeClick",!0);if(n){var i=e.findTarget(t.offsetX,t.offsetY);if(i){var r=i.node;if(r.getLayout().isLeafRoot)e._rootToNode(i);else if("zoomToNode"===n)e._zoomToNode(i);else if("link"===n){var a=r.hostTree.data.getItemModel(r.dataIndex),o=a.get("link",!0),s=a.get("target",!0)||"blank";o&&Object(He["l"])(o,s)}}}}}),this)},e.prototype._renderBreadcrumb=function(t,e,n){var i=this;n||(n=null!=t.get("leafDepth",!0)?{node:t.getViewRoot()}:this.findTarget(e.getWidth()/2,e.getHeight()/2),n||(n={node:t.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new ru(this.group))).render(t,e,n.node,(function(e){"animating"!==i._state&&(El(t.getViewRoot(),e)?i._rootToNode({node:e}):i._zoomToNode({node:e}))}))},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=bu(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},e.prototype.dispose=function(){this._clearController()},e.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype.findTarget=function(t,e){var n,i=this.seriesModel.getViewRoot();return i.eachNode({attr:"viewChildren",order:"preorder"},(function(i){var r=this._storage.background[i.getRawIndex()];if(r){var a=r.transformCoordToLocal(t,e),o=r.shape;if(!(o.x<=a[0]&&a[0]<=o.x+o.width&&o.y<=a[1]&&a[1]<=o.y+o.height))return!1;n={node:i,offsetX:a[0],offsetY:a[1]}}}),this),n},e.type="treemap",e}(Ne["a"]);function bu(){return{nodeGroup:[],background:[],content:[]}}function xu(t,e,n,i,r,a,o,s,l,u){if(o){var c=o.getLayout(),h=t.getData(),d=o.getModel();if(h.setItemGraphicEl(o.dataIndex,null),c&&c.isInView){var f=c.width,p=c.height,g=c.borderWidth,m=c.invisible,v=o.getRawIndex(),y=s&&s.getRawIndex(),b=o.viewChildren,x=c.upperHeight,w=b&&b.length,O=d.getModel("itemStyle"),S=d.getModel(["emphasis","itemStyle"]),T=d.getModel(["blur","itemStyle"]),M=d.getModel(["select","itemStyle"]),A=O.get("borderRadius")||0,C=F("nodeGroup",lu);if(C){if(l.add(C),C.x=c.x||0,C.y=c.y||0,C.markRedraw(),yu(C).nodeWidth=f,yu(C).nodeHeight=p,c.isAboveViewRoot)return C;var I=F("background",uu,u,pu);I&&R(C,I,w&&c.upperLabelHeight);var D=d.getModel("emphasis"),L=D.get("focus"),E=D.get("blurScope"),j=D.get("disabled"),P="ancestor"===L?o.getAncestorsIndices():"descendant"===L?o.getDescendantIndices():L;if(w)Object(re["y"])(C)&&Object(re["F"])(C,!1),I&&(Object(re["F"])(I,!j),h.setItemGraphicEl(o.dataIndex,I),Object(re["p"])(I,P,E));else{var N=F("content",uu,u,gu);N&&k(C,N),I.disableMorphing=!0,I&&Object(re["y"])(I)&&Object(re["F"])(I,!1),Object(re["F"])(C,!j),h.setItemGraphicEl(o.dataIndex,C),Object(re["p"])(C,P,E)}return C}}}function R(e,n,i){var r=Object(ie["a"])(n);if(r.dataIndex=o.dataIndex,r.seriesIndex=t.seriesIndex,n.setShape({x:0,y:0,width:f,height:p,r:A}),m)B(n);else{n.invisible=!1;var a=o.getVisual("style"),s=a.stroke,l=vu(O);l.fill=s;var u=mu(S);u.fill=S.get("borderColor");var c=mu(T);c.fill=T.get("borderColor");var h=mu(M);if(h.fill=M.get("borderColor"),i){var d=f-2*g;z(n,s,a.opacity,{x:g,y:0,width:d,height:x})}else n.removeTextContent();n.setStyle(l),n.ensureState("emphasis").style=u,n.ensureState("blur").style=c,n.ensureState("select").style=h,Object(re["G"])(n)}e.add(n)}function k(e,n){var i=Object(ie["a"])(n);i.dataIndex=o.dataIndex,i.seriesIndex=t.seriesIndex;var r=Math.max(f-2*g,0),a=Math.max(p-2*g,0);if(n.culling=!0,n.setShape({x:g,y:g,width:r,height:a,r:A}),m)B(n);else{n.invisible=!1;var s=o.getVisual("style"),l=s.fill,u=vu(O);u.fill=l,u.decal=s.decal;var c=mu(S),h=mu(T),d=mu(M);z(n,l,s.opacity,null),n.setStyle(u),n.ensureState("emphasis").style=c,n.ensureState("blur").style=h,n.ensureState("select").style=d,Object(re["G"])(n)}e.add(n)}function B(t){!t.invisible&&a.push(t)}function z(e,n,i,r){var a=d.getModel(r?du:hu),s=Object(Te["e"])(d.get("name"),null),l=a.getShallow("show");Object(le["g"])(e,Object(le["e"])(d,r?du:hu),{defaultText:l?s:null,inheritColor:n,defaultOpacity:i,labelFetcher:t,labelDataIndex:o.dataIndex});var u=e.getTextContent();if(u){var h=u.style,f=Object(_["M"])(h.padding||0);r&&(e.setTextConfig({layoutRect:r}),u.disableLabelLayout=!0),u.beforeUpdate=function(){var t=Math.max((r?r.width:e.shape.width)-f[1]-f[3],0),n=Math.max((r?r.height:e.shape.height)-f[0]-f[2],0);h.width===t&&h.height===n||u.setStyle({width:t,height:n})},h.truncateMinChar=2,h.lineOverflow="truncate",V(h,r,c);var p=u.getState("emphasis");V(p?p.style:null,r,c)}}function V(e,n,i){var r=e?e.text:null;if(!n&&i.isLeafRoot&&null!=r){var a=t.get("drillDownIcon",!0);e.text=a?a+" "+r:r}}function F(t,i,a,o){var s=null!=y&&n[t][y],l=r[t];return s?(n[t][y]=null,G(l,s)):m||(s=new i,s instanceof os["c"]&&(s.z2=wu(a,o)),H(l,s)),e[t][v]=s}function G(t,e){var n=t[v]={};e instanceof lu?(n.oldX=e.x,n.oldY=e.y):n.oldShape=Object(_["m"])({},e.shape)}function H(t,e){var n=t[v]={},a=o.parentNode,s=e instanceof Jt["a"];if(a&&(!i||"drillDown"===i.direction)){var l=0,u=0,c=r.background[a.getRawIndex()];!i&&c&&c.oldShape&&(l=c.oldShape.width,u=c.oldShape.height),s?(n.oldX=0,n.oldY=u):n.oldShape={x:l,y:u,width:0,height:0}}n.fadein=!s}}function wu(t,e){return t*fu+e}var Ou=_u,Su=n("edae"),Tu=_["k"],Mu=_["A"],Au=-1,Cu=function(){function t(e){var n=e.mappingMethod,i=e.type,r=this.option=_["d"](e);this.type=i,this.mappingMethod=n,this._normalizeData=Vu[n];var a=t.visualHandlers[i];this.applyVisual=a.applyVisual,this.getColorMapper=a.getColorMapper,this._normalizedToVisual=a._normalizedToVisual[n],"piecewise"===n?(Lu(r),Iu(r)):"category"===n?r.categories?Du(r):Lu(r,!0):(_["b"]("linear"!==n||r.dataExtent),Lu(r))}return t.prototype.mapValueToVisual=function(t){var e=this._normalizeData(t);return this._normalizedToVisual(e,t)},t.prototype.getNormalizer=function(){return _["c"](this._normalizeData,this)},t.listVisualTypes=function(){return _["F"](t.visualHandlers)},t.isValidType=function(e){return t.visualHandlers.hasOwnProperty(e)},t.eachVisual=function(t,e,n){_["A"](t)?_["k"](t,e,n):e.call(n,t)},t.mapVisual=function(e,n,i){var r,a=_["t"](e)?[]:_["A"](e)?{}:(r=!0,null);return t.eachVisual(e,(function(t,e){var o=n.call(i,t,e);r?a=o:a[e]=o})),a},t.retrieveVisuals=function(e){var n,i={};return e&&Tu(t.visualHandlers,(function(t,r){e.hasOwnProperty(r)&&(i[r]=e[r],n=!0)})),n?i:null},t.prepareVisualTypes=function(t){if(_["t"](t))t=t.slice();else{if(!Mu(t))return[];var e=[];Tu(t,(function(t,n){e.push(n)})),t=e}return t.sort((function(t,e){return"color"===e&&"color"!==t&&0===t.indexOf("color")?1:-1})),t},t.dependsOn=function(t,e){return"color"===e?!(!t||0!==t.indexOf(e)):t===e},t.findPieceIndex=function(t,e,n){for(var i,r=1/0,a=0,o=e.length;a=0;a--)null==i[a]&&(delete n[e[a]],e.pop())}function Lu(t,e){var n=t.visual,i=[];_["A"](n)?Tu(n,(function(t){i.push(t)})):null!=n&&i.push(n);var r={color:1,symbol:1};e||1!==i.length||r.hasOwnProperty(t.type)||(i[1]=i[0]),zu(t,i)}function Eu(t){return{applyVisual:function(e,n,i){var r=this.mapValueToVisual(e);i("color",t(n("color"),r))},_normalizedToVisual:ku([0,1])}}function ju(t){var e=this.option.visual;return e[Math.round(Object(Be["l"])(t,[0,1],[0,e.length-1],!0))]||{}}function Pu(t){return function(e,n,i){i(t,this.mapValueToVisual(e))}}function Nu(t){var e=this.option.visual;return e[this.option.loop&&t!==Au?t%e.length:t]}function Ru(){return this.option.visual[0]}function ku(t){return{linear:function(e){return Object(Be["l"])(e,t,this.option.visual,!0)},category:Nu,piecewise:function(e,n){var i=Bu.call(this,n);return null==i&&(i=Object(Be["l"])(e,t,this.option.visual,!0)),i},fixed:Ru}}function Bu(t){var e=this.option,n=e.pieceList;if(e.hasSpecialVisual){var i=Cu.findPieceIndex(t,n),r=n[i];if(r&&r.visual)return r.visual[this.type]}}function zu(t,e){return t.visual=e,"color"===t.type&&(t.parsedVisual=_["H"](e,(function(t){var e=Ue["parse"](t);return e||[0,0,0,1]}))),e}var Vu={linear:function(t){return Object(Be["l"])(t,this.option.dataExtent,[0,1],!0)},piecewise:function(t){var e=this.option.pieceList,n=Cu.findPieceIndex(t,e,!0);if(null!=n)return Object(Be["l"])(n,[0,e.length-1],[0,1],!0)},category:function(t){var e=this.option.categories?this.option.categoryMap[t]:t;return null==e?Au:e},fixed:_["L"]};function Fu(t,e,n){return t?e<=n:e=n.length||t===n[t.depth]){var a=$u(r,u,t,e,p,i);Xu(t,a,n,i)}}))}else s=qu(u),c.fill=s}}function Zu(t,e,n){var i=Object(_["m"])({},e),r=n.designatedVisualItemStyle;return Object(_["k"])(["color","colorAlpha","colorSaturation"],(function(n){r[n]=e[n];var a=t.get(n);r[n]=null,null!=a&&(i[n]=a)})),i}function qu(t){var e=Ku(t,"color");if(e){var n=Ku(t,"colorAlpha"),i=Ku(t,"colorSaturation");return i&&(e=Object(Ue["modifyHSL"])(e,null,null,i)),n&&(e=Object(Ue["modifyAlpha"])(e,n)),e}}function Yu(t,e){return null!=e?Object(Ue["modifyHSL"])(e,null,null,t):null}function Ku(t,e){var n=t[e];if(null!=n&&"none"!==n)return n}function Qu(t,e,n,i,r,a){if(a&&a.length){var o=Ju(e,"color")||null!=r.color&&"none"!==r.color&&(Ju(e,"colorAlpha")||Ju(e,"colorSaturation"));if(o){var s=e.get("visualMin"),l=e.get("visualMax"),u=n.dataExtent.slice();null!=s&&su[1]&&(u[1]=l);var c=e.get("colorMappingBy"),h={type:o.name,dataExtent:u,visual:o.range};"color"!==h.type||"index"!==c&&"id"!==c?h.mappingMethod="linear":(h.mappingMethod="category",h.loop=!0);var d=new Gu(h);return Uu(d).drColorMappingBy=c,d}}}function Ju(t,e){var n=t.get(e);return Object(_["t"])(n)&&n.length?{name:e,range:n}:null}function $u(t,e,n,i,r,a){var o=Object(_["m"])({},e);if(r){var s=r.type,l="color"===s&&Uu(r).drColorMappingBy,u="index"===l?i:"id"===l?a.mapIdToIndex(n.getId()):n.getValue(t.get("visualDimension"));o[s]=r.mapValueToVisual(u)}return o}var tc=Math.max,ec=Math.min,nc=_["O"],ic=_["k"],rc=["itemStyle","borderWidth"],ac=["itemStyle","gapWidth"],oc=["upperLabel","show"],sc=["upperLabel","height"],lc={seriesType:"treemap",reset:function(t,e,n,i){var r=n.getWidth(),a=n.getHeight(),o=t.option,s=ri["g"](t.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()}),l=o.size||[],u=Object(Be["p"])(nc(s.width,l[0]),r),c=Object(Be["p"])(nc(s.height,l[1]),a),h=i&&i.type,d=["treemapZoomToNode","treemapRootToNode"],f=Dl(i,d,t),p="treemapRender"===h||"treemapMove"===h?i.rootRect:null,g=t.getViewRoot(),m=Ll(g);if("treemapMove"!==h){var v="treemapZoomToNode"===h?mc(t,f,g,u,c):p?[p.width,p.height]:[u,c],y=o.sort;y&&"asc"!==y&&"desc"!==y&&(y="desc");var b={squareRatio:o.squareRatio,sort:y,leafDepth:o.leafDepth};g.hostTree.clearLayouts();var x={x:0,y:0,width:v[0],height:v[1],area:v[0]*v[1]};g.setLayout(x),uc(g,b,!1,0),x=g.getLayout(),ic(m,(function(t,e){var n=(m[e+1]||g).getValue();t.setLayout(_["m"]({dataExtent:[n,n],borderWidth:0,upperHeight:0},x))}))}var w=t.getData().tree.root;w.setLayout(vc(s,p,f),!0),t.setLayoutInfo(s),yc(w,new ki["a"](-s.x,-s.y,r,a),m,g,0)}};function uc(t,e,n,i){var r,a;if(!t.isRemoved()){var o=t.getLayout();r=o.width,a=o.height;var s=t.getModel(),l=s.get(rc),u=s.get(ac)/2,c=_c(s),h=Math.max(l,c),d=l-u,f=h-u;t.setLayout({borderWidth:l,upperHeight:h,upperLabelHeight:c},!0),r=tc(r-2*d,0),a=tc(a-d-f,0);var p=r*a,g=cc(t,s,p,e,n,i);if(g.length){var m={x:d,y:f,width:r,height:a},v=ec(r,a),y=1/0,_=[];_.area=0;for(var b=0,x=g.length;b=0;l--){var u=r["asc"===i?o-l-1:l].getValue();u/n*eo[1]&&(o[1]=e)}))):o=[NaN,NaN],{sum:i,dataExtent:o}}function pc(t,e,n){for(var i=0,r=1/0,a=0,o=void 0,s=t.length;ai&&(i=o));var l=t.area*t.area,u=e*e*n;return l?tc(u*i/l,l/(u*r)):1/0}function gc(t,e,n,i,r){var a=e===n.width?0:1,o=1-a,s=["x","y"],l=["width","height"],u=n[s[a]],c=e?t.area/e:0;(r||c>n[l[o]])&&(c=n[l[o]]);for(var h=0,d=t.length;hBe["a"]&&(u=Be["a"]),o=a}ui&&(i=e);var a=i%2?i+2:i+3;r=[];for(var o=0;o0&&(y[0]=-y[0],y[1]=-y[1]);var b=v[0]<0?-1:1;if("start"!==i.__position&&"end"!==i.__position){var x=-Math.atan2(v[1],v[0]);u[0].8?"left":c[0]<-.8?"right":"center",d=c[1]>.8?"top":c[1]<-.8?"bottom":"middle";break;case"start":i.x=-c[0]*p+l[0],i.y=-c[1]*g+l[1],h=c[0]>.8?"right":c[0]<-.8?"left":"center",d=c[1]>.8?"bottom":c[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=p*b+l[0],i.y=l[1]+w,h=v[0]<0?"right":"left",i.originX=-p*b,i.originY=-w;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=_[0],i.y=_[1]+w,h="center",i.originY=-w;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-p*b+u[0],i.y=u[1]+w,h=v[0]>=0?"right":"left",i.originX=p*b,i.originY=-w;break}i.scaleX=i.scaleY=r,i.setStyle({verticalAlign:i.__verticalAlign||d,align:i.__align||h})}}}function O(t,e){var n=t.__specifiedRotation;if(null==n){var i=o.tangentAt(e);t.attr("rotation",(1===e?-1:1)*Math.PI/2-Math.atan2(i[1],i[0]))}else t.attr("rotation",n)}},e}(Jt["a"]),uh=lh,ch=function(){function t(t){this.group=new Jt["a"],this._LineCtor=t||uh}return t.prototype.updateData=function(t){var e=this;this._progressiveEls=null;var n=this,i=n.group,r=n._lineData;n._lineData=t,r||i.removeAll();var a=dh(t);t.diff(r).add((function(n){e._doAdd(t,n,a)})).update((function(n,i){e._doUpdate(r,t,i,n,a)})).remove((function(t){i.remove(r.getItemGraphicEl(t))})).execute()},t.prototype.updateLayout=function(){var t=this._lineData;t&&t.eachItemGraphicEl((function(e,n){e.updateLayout(t,n)}),this)},t.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=dh(t),this._lineData=null,this.group.removeAll()},t.prototype.incrementalUpdate=function(t,e){function n(t){t.isGroup||hh(t)||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[];for(var i=t.start;i0}function dh(t){var e=t.hostModel,n=e.getModel("emphasis");return{lineStyle:e.getModel("lineStyle").getLineStyle(),emphasisLineStyle:n.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:e.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:e.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:n.get("disabled"),blurScope:n.get("blurScope"),focus:n.get("focus"),labelStatesModels:Object(le["e"])(e)}}function fh(t){return isNaN(t[0])||isNaN(t[1])}function ph(t){return t&&!fh(t[0])&&!fh(t[1])}var gh=ch,mh=[],vh=[],yh=[],_h=Me["h"],bh=cr["g"],xh=Math.abs;function wh(t,e,n){for(var i,r=t[0],a=t[1],o=t[2],s=1/0,l=n*n,u=.1,c=.1;c<=.9;c+=.1){mh[0]=_h(r[0],a[0],o[0],c),mh[1]=_h(r[1],a[1],o[1],c);var h=xh(bh(mh,e)-l);h=0?i+=u:i-=u:p>=0?i-=u:i+=u}return i}function Oh(t,e){var n=[],i=Me["n"],r=[[],[],[]],a=[[],[]],o=[];e/=2,t.eachEdge((function(t,s){var l=t.getLayout(),u=t.getVisual("fromSymbol"),c=t.getVisual("toSymbol");l.__original||(l.__original=[cr["c"](l[0]),cr["c"](l[1])],l[2]&&l.__original.push(cr["c"](l[2])));var h=l.__original;if(null!=l[2]){if(cr["d"](r[0],h[0]),cr["d"](r[1],h[2]),cr["d"](r[2],h[1]),u&&"none"!==u){var d=Vc(t.node1),f=wh(r,h[0],d*e);i(r[0][0],r[1][0],r[2][0],f,n),r[0][0]=n[3],r[1][0]=n[4],i(r[0][1],r[1][1],r[2][1],f,n),r[0][1]=n[3],r[1][1]=n[4]}if(c&&"none"!==c){d=Vc(t.node2),f=wh(r,h[1],d*e);i(r[0][0],r[1][0],r[2][0],f,n),r[1][0]=n[1],r[2][0]=n[2],i(r[0][1],r[1][1],r[2][1],f,n),r[1][1]=n[1],r[2][1]=n[2]}cr["d"](l[0],r[0]),cr["d"](l[1],r[2]),cr["d"](l[2],r[1])}else{if(cr["d"](a[0],h[0]),cr["d"](a[1],h[1]),cr["q"](o,a[1],a[0]),cr["m"](o,o),u&&"none"!==u){d=Vc(t.node1);cr["o"](a[0],a[0],o,d*e)}if(c&&"none"!==c){d=Vc(t.node2);cr["o"](a[1],a[1],o,-d*e)}cr["d"](l[0],a[0]),cr["d"](l[1],a[1])}}))}function Sh(t){return"view"===t.type}var Th=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(t,e){var n=new me,i=new gh,r=this.group;this._controller=new no(e.getZr()),this._controllerHost={target:r},r.add(n.group),r.add(i.group),this._symbolDraw=n,this._lineDraw=i,this._firstRender=!0},e.prototype.render=function(t,e,n){var i=this,r=t.coordinateSystem;this._model=t;var a=this._symbolDraw,o=this._lineDraw,s=this.group;if(Sh(r)){var l={x:r.x,y:r.y,scaleX:r.scaleX,scaleY:r.scaleY};this._firstRender?s.attr(l):ee["h"](s,l,t)}Oh(t.getGraph(),zc(t));var u=t.getData();a.updateData(u);var c=t.getEdgeData();o.updateData(c),this._updateNodeAndLinkScale(),this._updateController(t,e,n),clearTimeout(this._layoutTimeout);var h=t.forceLayout,d=t.get(["force","layoutAnimation"]);h&&this._startForceLayoutIteration(h,d),u.graph.eachNode((function(t){var e=t.dataIndex,n=t.getGraphicEl(),r=t.getModel();if(n){n.off("drag").off("dragend");var a=r.get("draggable");a&&n.on("drag",(function(){h&&(h.warmUp(),!i._layouting&&i._startForceLayoutIteration(h,d),h.setFixed(e),u.setItemLayout(e,[n.x,n.y]))})).on("dragend",(function(){h&&h.setUnfixed(e)})),n.setDraggable(a&&!!h,!!r.get("cursor"));var o=r.get(["emphasis","focus"]);"adjacency"===o&&(Object(ie["a"])(n).focus=t.getAdjacentDataIndices())}})),u.graph.eachEdge((function(t){var e=t.getGraphicEl(),n=t.getModel().get(["emphasis","focus"]);e&&"adjacency"===n&&(Object(ie["a"])(e).focus={edge:[t.dataIndex],node:[t.node1.dataIndex,t.node2.dataIndex]})}));var f="circular"===t.get("layout")&&t.get(["circular","rotateLabel"]),p=u.getLayout("cx"),g=u.getLayout("cy");u.eachItemGraphicEl((function(t,e){var n=u.getItemModel(e),i=n.get(["label","rotate"])||0,r=t.getSymbolPath();if(f){var a=u.getItemLayout(e),o=Math.atan2(a[1]-g,a[0]-p);o<0&&(o=2*Math.PI+o);var s=a[0] "+d)),u++)}var f,p=n.get("coordinateSystem");if("cartesian2d"===p||"polar"===p)f=Object(Yt["a"])(t,n);else{var g=Ch["a"].get(p),m=g&&g.dimensions||[];_["r"](m,"value")<0&&m.concat(["value"]);var v=Object(Ti["b"])(t,{coordDimensions:m,encodeDefine:n.getEncode()}).dimensions;f=new Mi["a"](v,n),f.initData(t)}var y=new Mi["a"](["value"],n);return y.initData(l,s),r&&r(f,y),Object(Tl["a"])({mainData:f,struct:a,structAttr:"graph",datas:{node:f,edge:y},datasAttr:{node:"data",edge:"edgeData"}}),a.update(),a}var Dh=n("f6d8"),Lh=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.hasSymbolVisual=!0,n}return Object(qt["a"])(e,t),e.prototype.init=function(e){t.prototype.init.apply(this,arguments);var n=this;function i(){return n._categoriesData}this.legendVisualProvider=new Di(i,i),this.fillDataTextStyle(e.edges||e.links),this._updateCategoriesData()},e.prototype.mergeOption=function(e){t.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(e.edges||e.links),this._updateCategoriesData()},e.prototype.mergeDefaultAndTheme=function(e){t.prototype.mergeDefaultAndTheme.apply(this,arguments),Object(Te["f"])(e,"edgeLabel",["show"])},e.prototype.getInitialData=function(t,e){var n=t.edges||t.links||[],i=t.data||t.nodes||[],r=this;if(i&&n){jc(this);var a=Ih(i,n,this,!0,o);return _["k"](a.edges,(function(t){Pc(t.node1,t.node2,this,t.dataIndex)}),this),a.data}function o(t,e){t.wrapMethod("getItemModel",(function(t){var e=r._categoriesModels,n=t.getShallow("category"),i=e[n];return i&&(i.parentModel=t.parentModel,t.parentModel=i),t}));var n=Er["a"].prototype.getModel;function i(t,e){var i=n.call(this,t,e);return i.resolveParentPath=a,i}function a(t){if(t&&("label"===t[0]||"label"===t[1])){var e=t.slice();return"label"===t[0]?e[0]="edgeLabel":"label"===t[1]&&(e[1]="edgeLabel"),e}return t}e.wrapMethod("getItemModel",(function(t){return t.resolveParentPath=a,t.getModel=i,t}))}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.getCategoriesData=function(){return this._categoriesData},e.prototype.formatTooltip=function(t,e,n){if("edge"===n){var i=this.getData(),r=this.getDataParams(t,n),a=i.graph.getEdgeByIndex(t),o=i.getName(a.node1.dataIndex),s=i.getName(a.node2.dataIndex),l=[];return null!=o&&l.push(o),null!=s&&l.push(s),Object(Ma["c"])("nameValue",{name:l.join(" > "),value:r.value,noValue:null==r.value})}var u=Object(Dh["a"])({series:this,dataIndex:t,multipleSeries:e});return u},e.prototype._updateCategoriesData=function(){var t=_["H"](this.option.categories||[],(function(t){return null!=t.value?t:_["m"]({value:0},t)})),e=new Mi["a"](["value"],this);e.initData(t),this._categoriesData=e,this._categoriesModels=e.mapArray((function(t){return e.getItemModel(t)}))},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.isAnimationEnabled=function(){return t.prototype.isAnimationEnabled.call(this)&&!("force"===this.get("layout")&&this.get(["force","layoutAnimation"]))},e.type="series.graph",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(Kt["b"]),Eh=Lh,jh={type:"graphRoam",event:"graphRoam",update:"none"};function Ph(t){t.registerChartView(Mh),t.registerSeriesModel(Eh),t.registerProcessor(xc),t.registerVisual(wc),t.registerVisual(Sc),t.registerLayout(Bc),t.registerLayout(t.PRIORITY.VISUAL.POST_CHART_LAYOUT,Wc),t.registerLayout(qc),t.registerCoordinateSystem("graphView",{dimensions:Es.dimensions,create:Kc}),t.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},_["L"]),t.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},_["L"]),t.registerAction(jh,(function(t,e,n){e.eachComponent({mainType:"series",query:t},(function(e){var i=e.coordinateSystem,r=Xs(i,t,void 0,n);e.setCenter&&e.setCenter(r.center),e.setZoom&&e.setZoom(r.zoom)}))}))}var Nh=function(){function t(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return t}(),Rh=function(t){function e(e){var n=t.call(this,e)||this;return n.type="pointer",n}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new Nh},e.prototype.buildPath=function(t,e){var n=Math.cos,i=Math.sin,r=e.r,a=e.width,o=e.angle,s=e.x-n(o)*a*(a>=r/3?1:2),l=e.y-i(o)*a*(a>=r/3?1:2);o=e.angle-Math.PI/2,t.moveTo(s,l),t.lineTo(e.x+n(o)*a,e.y+i(o)*a),t.lineTo(e.x+n(e.angle)*r,e.y+i(e.angle)*r),t.lineTo(e.x-n(o)*a,e.y-i(o)*a),t.lineTo(s,l)},e}(s["b"]),kh=Rh;function Bh(t,e){var n=t.get("center"),i=e.getWidth(),r=e.getHeight(),a=Math.min(i,r),o=Object(Be["p"])(n[0],e.getWidth()),s=Object(Be["p"])(n[1],e.getHeight()),l=Object(Be["p"])(t.get("radius"),a/2);return{cx:o,cy:s,r:l}}function zh(t,e){var n=null==t?"":t+"";return e&&(Object(_["C"])(e)?n=e.replace("{value}",n):Object(_["w"])(e)&&(n=e(t))),n}var Vh=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){this.group.removeAll();var i=t.get(["axisLine","lineStyle","color"]),r=Bh(t,n);this._renderMain(t,e,n,i,r),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,e,n,i,r){var a=this.group,o=t.get("clockwise"),s=-t.get("startAngle")/180*Math.PI,l=-t.get("endAngle")/180*Math.PI,u=t.getModel("axisLine"),c=u.get("roundCap"),h=c?Mn:ke["a"],d=u.get("show"),f=u.getModel("lineStyle"),p=f.get("width"),g=[s,l];Object(F["b"])(g,!o),s=g[0],l=g[1];for(var m=l-s,v=s,y=0;d&&y=t&&(0===e?0:i[e-1][0]).8?"bottom":"middle",align:u<-.4?"left":u>.4?"right":"center"},{inheritColor:P}),silent:!0}))}if(y.get("show")&&D!==b){L=y.get("distance");L=L?L+l:l;for(var N=0;N<=x;N++){u=Math.cos(S),c=Math.sin(S);var R=new Lr["a"]({shape:{x1:u*(p-L)+d,y1:c*(p-L)+f,x2:u*(p-O-L)+d,y2:c*(p-O-L)+f},silent:!0,style:C});"auto"===C.stroke&&R.setStyle({stroke:i((D+N/x)/b)}),h.add(R),S+=M}S-=M}else S+=T}},e.prototype._renderPointer=function(t,e,n,i,r,a,o,s,u){var c=this.group,h=this._data,d=this._progressEls,f=[],p=t.get(["pointer","show"]),g=t.getModel("progress"),m=g.get("show"),v=t.getData(),y=v.mapDimension("value"),b=+t.get("min"),x=+t.get("max"),w=[b,x],O=[a,o];function S(e,n){var i,a=v.getItemModel(e),o=a.getModel("pointer"),s=Object(Be["p"])(o.get("width"),r.r),l=Object(Be["p"])(o.get("length"),r.r),u=t.get(["pointer","icon"]),c=o.get("offsetCenter"),h=Object(Be["p"])(c[0],r.r),d=Object(Be["p"])(c[1],r.r),f=o.get("keepAspect");return i=u?Object(Qt["a"])(u,h-s/2,d-l,s,l,null,f):new kh({shape:{angle:-Math.PI/2,width:s,r:l,x:h,y:d}}),i.rotation=-(n+Math.PI/2),i.x=r.cx,i.y=r.cy,i}function T(t,e){var n=g.get("roundCap"),i=n?Mn:ke["a"],o=g.get("overlap"),l=o?g.get("width"):u/v.count(),c=o?r.r-l:r.r-(t+1)*l,h=o?r.r:r.r-t*l,d=new i({shape:{startAngle:a,endAngle:e,cx:r.cx,cy:r.cy,clockwise:s,r0:c,r:h}});return o&&(d.z2=x-v.get(y,t)%x),d}(m||p)&&(v.diff(h).add((function(e){var n=v.get(y,e);if(p){var i=S(e,a);ee["c"](i,{rotation:-((isNaN(+n)?O[0]:Object(Be["l"])(n,w,O,!0))+Math.PI/2)},t),c.add(i),v.setItemGraphicEl(e,i)}if(m){var r=T(e,a),o=g.get("clip");ee["c"](r,{shape:{endAngle:Object(Be["l"])(n,w,O,o)}},t),c.add(r),Object(ie["b"])(t.seriesIndex,v.dataType,e,r),f[e]=r}})).update((function(e,n){var i=v.get(y,e);if(p){var r=h.getItemGraphicEl(n),o=r?r.rotation:a,s=S(e,o);s.rotation=o,ee["h"](s,{rotation:-((isNaN(+i)?O[0]:Object(Be["l"])(i,w,O,!0))+Math.PI/2)},t),c.add(s),v.setItemGraphicEl(e,s)}if(m){var l=d[n],u=l?l.shape.endAngle:a,_=T(e,u),b=g.get("clip");ee["h"](_,{shape:{endAngle:Object(Be["l"])(i,w,O,b)}},t),c.add(_),Object(ie["b"])(t.seriesIndex,v.dataType,e,_),f[e]=_}})).execute(),v.each((function(t){var e=v.getItemModel(t),n=e.getModel("emphasis"),r=n.get("focus"),a=n.get("blurScope"),o=n.get("disabled");if(p){var s=v.getItemGraphicEl(t),u=v.getItemVisual(t,"style"),c=u.fill;if(s instanceof l["a"]){var h=s.style;s.useStyle(Object(_["m"])({image:h.image,x:h.x,y:h.y,width:h.width,height:h.height},u))}else s.useStyle(u),"pointer"!==s.type&&s.setColor(c);s.setStyle(e.getModel(["pointer","itemStyle"]).getItemStyle()),"auto"===s.style.fill&&s.setStyle("fill",i(Object(Be["l"])(v.get(y,t),w,[0,1],!0))),s.z2EmphasisLift=0,Object(re["I"])(s,e),Object(re["J"])(s,r,a,o)}if(m){var d=f[t];d.useStyle(v.getItemVisual(t,"style")),d.setStyle(e.getModel(["progress","itemStyle"]).getItemStyle()),d.z2EmphasisLift=0,Object(re["I"])(d,e),Object(re["J"])(d,r,a,o)}})),this._progressEls=f)},e.prototype._renderAnchor=function(t,e){var n=t.getModel("anchor"),i=n.get("show");if(i){var r=n.get("size"),a=n.get("icon"),o=n.get("offsetCenter"),s=n.get("keepAspect"),l=Object(Qt["a"])(a,e.cx-r/2+Object(Be["p"])(o[0],e.r),e.cy-r/2+Object(Be["p"])(o[1],e.r),r,r,null,s);l.z2=n.get("showAbove")?1:0,l.setStyle(n.getModel("itemStyle").getItemStyle()),this.group.add(l)}},e.prototype._renderTitleAndDetail=function(t,e,n,i,r){var a=this,o=t.getData(),s=o.mapDimension("value"),l=+t.get("min"),u=+t.get("max"),c=new Jt["a"],h=[],d=[],f=t.isAnimationEnabled(),p=t.get(["pointer","showAbove"]);o.diff(this._data).add((function(t){h[t]=new $["a"]({silent:!0}),d[t]=new $["a"]({silent:!0})})).update((function(t,e){h[t]=a._titleEls[e],d[t]=a._detailEls[e]})).execute(),o.each((function(e){var n=o.getItemModel(e),a=o.get(s,e),g=new Jt["a"],m=i(Object(Be["l"])(a,[l,u],[0,1],!0)),v=n.getModel("title");if(v.get("show")){var y=v.get("offsetCenter"),_=r.cx+Object(Be["p"])(y[0],r.r),b=r.cy+Object(Be["p"])(y[1],r.r),x=h[e];x.attr({z2:p?0:2,style:Object(le["c"])(v,{x:_,y:b,text:o.getName(e),align:"center",verticalAlign:"middle"},{inheritColor:m})}),g.add(x)}var w=n.getModel("detail");if(w.get("show")){var O=w.get("offsetCenter"),S=r.cx+Object(Be["p"])(O[0],r.r),T=r.cy+Object(Be["p"])(O[1],r.r),M=Object(Be["p"])(w.get("width"),r.r),A=Object(Be["p"])(w.get("height"),r.r),C=t.get(["progress","show"])?o.getItemVisual(e,"style").fill:m,I=(x=d[e],w.get("formatter"));x.attr({z2:p?0:2,style:Object(le["c"])(w,{x:S,y:T,text:zh(a,I),width:isNaN(M)?null:M,height:isNaN(A)?null:A,align:"center",verticalAlign:"middle"},{inheritColor:C})}),Object(le["h"])(x,{normal:w},a,(function(t){return zh(t,I)})),f&&Object(le["a"])(x,e,o,t,{getFormattedLabel:function(t,e,n,i,r,o){return zh(o?o.interpolatedValue:a,I)}}),g.add(x)}c.add(g)})),this.group.add(c),this._titleEls=h,this._detailEls=d},e.type="gauge",e}(Ne["a"]),Fh=Vh,Gh=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.visualStyleAccessPath="itemStyle",n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t,e){return Ai(this,["value"])},e.type="series.gauge",e.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e}(Kt["b"]),Hh=Gh;function Uh(t){t.registerChartView(Fh),t.registerSeriesModel(Hh)}var Wh=["itemStyle","opacity"],Xh=function(t){function e(e,n){var i=t.call(this)||this,r=i,a=new hi["a"],o=new $["a"];return r.setTextContent(o),i.setTextGuideLine(a),i.updateData(e,n,!0),i}return Object(qt["a"])(e,t),e.prototype.updateData=function(t,e,n){var i=this,r=t.hostModel,a=t.getItemModel(e),o=t.getItemLayout(e),s=a.getModel("emphasis"),l=a.get(Wh);l=null==l?1:l,n||Object(ee["g"])(i),i.useStyle(t.getItemVisual(e,"style")),i.style.lineJoin="round",n?(i.setShape({points:o.points}),i.style.opacity=0,ee["c"](i,{style:{opacity:l}},r,e)):ee["h"](i,{style:{opacity:l},shape:{points:o.points}},r,e),Object(re["I"])(i,a),this._updateLabel(t,e),Object(re["J"])(this,s.get("focus"),s.get("blurScope"),s.get("disabled"))},e.prototype._updateLabel=function(t,e){var n=this,i=this.getTextGuideLine(),r=n.getTextContent(),a=t.hostModel,o=t.getItemModel(e),s=t.getItemLayout(e),l=s.label,u=t.getItemVisual(e,"style"),c=u.fill;Object(le["g"])(r,Object(le["e"])(o),{labelFetcher:t.hostModel,labelDataIndex:e,defaultOpacity:u.opacity,defaultText:t.getName(e)},{normal:{align:l.textAlign,verticalAlign:l.verticalAlign}}),n.setTextConfig({local:!0,inside:!!l.inside,insideStroke:c,outsideFill:c});var h=l.linePoints;i.setShape({points:h}),n.textGuideLineConfig={anchor:h?new di["a"](h[0][0],h[0][1]):null},ee["h"](r,{style:{x:l.x,y:l.y}},a,e),r.attr({rotation:l.rotation,originX:l.x,originY:l.y,z2:10}),Object(fi["d"])(n,Object(fi["a"])(o),{stroke:c})},e}(Oa["a"]),Zh=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.ignoreLabelLineUpdate=!0,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=t.getData(),r=this._data,a=this.group;i.diff(r).add((function(t){var e=new Xh(i,t);i.setItemGraphicEl(t,e),a.add(e)})).update((function(t,e){var n=r.getItemGraphicEl(e);n.updateData(i,t),a.add(n),i.setItemGraphicEl(t,n)})).remove((function(e){var n=r.getItemGraphicEl(e);ee["f"](n,t,e)})).execute(),this._data=i},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.prototype.dispose=function(){},e.type="funnel",e}(Ne["a"]),qh=Zh,Yh=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(e){t.prototype.init.apply(this,arguments),this.legendVisualProvider=new Di(_["c"](this.getData,this),_["c"](this.getRawData,this)),this._defaultLabelLine(e)},e.prototype.getInitialData=function(t,e){return Ai(this,{coordDimensions:["value"],encodeDefaulter:_["h"](Ci["d"],this)})},e.prototype._defaultLabelLine=function(t){Object(Te["f"])(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.prototype.getDataParams=function(e){var n=this.getData(),i=t.prototype.getDataParams.call(this,e),r=n.mapDimension("value"),a=n.getSum(r);return i.percent=a?+(n.get(r,e)/a*100).toFixed(2):0,i.$vars.push("percent"),i},e.type="series.funnel",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(Kt["b"]),Kh=Yh;function Qh(t,e){return ri["g"](t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function Jh(t,e){for(var n=t.mapDimension("value"),i=t.mapArray(n,(function(t){return t})),r=[],a="ascending"===e,o=0,s=t.count();oxd)return;var r=this._model.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]);"none"!==r.behavior&&this._dispatchExpand({axisExpandWindow:r.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(t){if(!this._mouseDownPoint&&Sd(this,"mousemove")){var e=this._model,n=e.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]),i=n.behavior;"jump"===i&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand("none"===i?null:{axisExpandWindow:n.axisExpandWindow,animation:"jump"===i?null:{duration:0}})}}};function Sd(t,e){var n=t._model;return n.get("axisExpandable")&&n.get("axisExpandTriggerOn")===e}var Td=wd,Md=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(){t.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var e=this.option;t&&_["I"](e,t,!0),this._initDimensions()},e.prototype.contains=function(t,e){var n=t.get("parallelIndex");return null!=n&&e.getComponent("parallel",n)===this},e.prototype.setAxisExpand=function(t){_["k"](["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],(function(e){t.hasOwnProperty(e)&&(this.option[e]=t[e])}),this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],e=this.parallelAxisIndex=[],n=_["n"](this.ecModel.queryComponents({mainType:"parallelAxis"}),(function(t){return(t.get("parallelIndex")||0)===this.componentIndex}),this);_["k"](n,(function(n){t.push("dim"+n.get("dim")),e.push(n.componentIndex)}))},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e}(Xi["a"]),Ad=Md,Cd=function(t){function e(e,n,i,r,a){var o=t.call(this,e,n,i)||this;return o.type=r||"value",o.axisIndex=a,o}return Object(qt["a"])(e,t),e.prototype.isHorizontal=function(){return"horizontal"!==this.coordinateSystem.getModel().get("layout")},e}(gr["a"]),Id=Cd;function Dd(t,e,n,i,r,a){t=t||0;var o=n[1]-n[0];if(null!=r&&(r=Ed(r,[0,o])),null!=a&&(a=Math.max(a,null!=r?r:0)),"all"===i){var s=Math.abs(e[1]-e[0]);s=Ed(s,[0,o]),r=a=Ed(s,[r,a]),i=0}e[0]=Ed(e[0],n),e[1]=Ed(e[1],n);var l=Ld(e,i);e[i]+=t;var u,c=r||0,h=n.slice();return l.sign<0?h[0]+=c:h[1]-=c,e[i]=Ed(e[i],h),u=Ld(e,i),null!=r&&(u.sign!==l.sign||u.spana&&(e[1-i]=e[i]+u.sign*a),e}function Ld(t,e){var n=t[e]-t[1-e];return{span:Math.abs(n),sign:n>0?-1:n<0?1:e?-1:1}}function Ed(t,e){return Math.min(null!=e[1]?e[1]:1/0,Math.max(null!=e[0]?e[0]:-1/0,t))}var jd=_["k"],Pd=Math.min,Nd=Math.max,Rd=Math.floor,kd=Math.ceil,Bd=Be["v"],zd=Math.PI,Vd=function(){function t(t,e,n){this.type="parallel",this._axesMap=_["f"](),this._axesLayout={},this.dimensions=t.dimensions,this._model=t,this._init(t,e,n)}return t.prototype._init=function(t,e,n){var i=t.dimensions,r=t.parallelAxisIndex;jd(i,(function(t,n){var i=r[n],a=e.getComponent("parallelAxis",i),o=this._axesMap.set(t,new Id(t,sr["a"](a),[0,0],a.get("type"),i)),s="category"===o.type;o.onBand=s&&a.get("boundaryGap"),o.inverse=a.get("inverse"),a.axis=o,o.model=a,o.coordinateSystem=a.coordinateSystem=this}),this)},t.prototype.update=function(t,e){this._updateAxesFromSeries(this._model,t)},t.prototype.containPoint=function(t){var e=this._makeLayoutInfo(),n=e.axisBase,i=e.layoutBase,r=e.pixelDimIndex,a=t[1-r],o=t[r];return a>=n&&a<=n+e.axisLength&&o>=i&&o<=i+e.layoutLength},t.prototype.getModel=function(){return this._model},t.prototype._updateAxesFromSeries=function(t,e){e.eachSeries((function(n){if(t.contains(n,e)){var i=n.getData();jd(this.dimensions,(function(t){var e=this._axesMap.get(t);e.scale.unionExtentFromData(i,i.mapDimension(t)),sr["i"](e.scale,e.model)}),this)}}),this)},t.prototype.resize=function(t,e){this._rect=ri["g"](t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()}),this._layoutAxes()},t.prototype.getRect=function(){return this._rect},t.prototype._makeLayoutInfo=function(){var t,e=this._model,n=this._rect,i=["x","y"],r=["width","height"],a=e.get("layout"),o="horizontal"===a?0:1,s=n[r[o]],l=[0,s],u=this.dimensions.length,c=Fd(e.get("axisExpandWidth"),l),h=Fd(e.get("axisExpandCount")||0,[0,u]),d=e.get("axisExpandable")&&u>3&&u>h&&h>1&&c>0&&s>0,f=e.get("axisExpandWindow");if(f)t=Fd(f[1]-f[0],l),f[1]=f[0]+t;else{t=Fd(c*(h-1),l);var p=e.get("axisExpandCenter")||Rd(u/2);f=[c*p-t/2],f[1]=f[0]+t}var g=(s-t)/(u-h);g<3&&(g=0);var m=[Rd(Bd(f[0]/c,1))+1,kd(Bd(f[1]/c,1))-1],v=g/c*f[0];return{layout:a,pixelDimIndex:o,layoutBase:n[i[o]],layoutLength:s,axisBase:n[i[1-o]],axisLength:n[r[1-o]],axisExpandable:d,axisExpandWidth:c,axisCollapseWidth:g,axisExpandWindow:f,axisCount:u,winInnerIndices:m,axisExpandWindow0Pos:v}},t.prototype._layoutAxes=function(){var t=this._rect,e=this._axesMap,n=this.dimensions,i=this._makeLayoutInfo(),r=i.layout;e.each((function(t){var e=[0,i.axisLength],n=t.inverse?1:0;t.setExtent(e[n],e[1-n])})),jd(n,(function(e,n){var a=(i.axisExpandable?Hd:Gd)(n,i),o={horizontal:{x:a.position,y:i.axisLength},vertical:{x:0,y:a.position}},s={horizontal:zd/2,vertical:0},l=[o[r].x+t.x,o[r].y+t.y],u=s[r],c=ur["c"]();ur["g"](c,c,u),ur["i"](c,c,l),this._axesLayout[e]={position:l,rotation:u,transform:c,axisNameAvailableWidth:a.axisNameAvailableWidth,axisLabelShow:a.axisLabelShow,nameTruncateMaxWidth:a.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}}),this)},t.prototype.getAxis=function(t){return this._axesMap.get(t)},t.prototype.dataToPoint=function(t,e){return this.axisCoordToPoint(this._axesMap.get(e).dataToCoord(t),e)},t.prototype.eachActiveState=function(t,e,n,i){null==n&&(n=0),null==i&&(i=t.count());var r=this._axesMap,a=this.dimensions,o=[],s=[];_["k"](a,(function(e){o.push(t.mapDimension(e)),s.push(r.get(e).model)}));for(var l=this.hasAxisBrushed(),u=n;ur*(1-c[0])?(l="jump",o=s-r*(1-c[2])):(o=s-r*c[1])>=0&&(o=s-r*(1-c[1]))<=0&&(o=0),o*=e.axisExpandWidth/u,o?Dd(o,i,a,"all"):l="none";else{var d=i[1]-i[0],f=a[1]*s/d;i=[Nd(0,f-d/2)],i[1]=Pd(a[1],i[0]+d),i[0]=i[1]-d}return{axisExpandWindow:i,behavior:l}},t}();function Fd(t,e){return Pd(Nd(t,e[0]),e[1])}function Gd(t,e){var n=e.layoutLength/(e.axisCount-1);return{position:n*t,axisNameAvailableWidth:n,axisLabelShow:!0}}function Hd(t,e){var n,i,r=e.layoutLength,a=e.axisExpandWidth,o=e.axisCount,s=e.axisCollapseWidth,l=e.winInnerIndices,u=s,c=!1;return t=0;n--)Be["c"](e[n])},e.prototype.getActiveState=function(t){var e=this.activeIntervals;if(!e.length)return"normal";if(null==t||isNaN(+t))return"inactive";if(1===e.length){var n=e[0];if(n[0]<=t&&t<=n[1])return"active"}else for(var i=0,r=e.length;ief}function xf(t){var e=t.length-1;return e<0&&(e=0),[t[0],t[e]]}function wf(t,e,n,i){var r=new Jt["a"];return r.add(new Re["a"]({name:"main",style:Mf(n),silent:!0,draggable:!0,cursor:"move",drift:Object(_["h"])(Lf,t,e,r,["n","s","w","e"]),ondragend:Object(_["h"])(_f,e,{isEnd:!0})})),Object(_["k"])(i,(function(n){r.add(new Re["a"]({name:n.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:Object(_["h"])(Lf,t,e,r,n),ondragend:Object(_["h"])(_f,e,{isEnd:!0})}))})),r}function Of(t,e,n,i){var r=i.brushStyle.lineWidth||0,a=Jd(r,nf),o=n[0][0],s=n[1][0],l=o-r/2,u=s-r/2,c=n[0][1],h=n[1][1],d=c-a+r/2,f=h-a+r/2,p=c-o,g=h-s,m=p+r,v=g+r;Tf(t,e,"main",o,s,p,g),i.transformable&&(Tf(t,e,"w",l,u,a,v),Tf(t,e,"e",d,u,a,v),Tf(t,e,"n",l,u,m,a),Tf(t,e,"s",l,f,m,a),Tf(t,e,"nw",l,u,a,a),Tf(t,e,"ne",d,u,a,a),Tf(t,e,"sw",l,f,a,a),Tf(t,e,"se",d,f,a,a))}function Sf(t,e){var n=e.__brushOption,i=n.transformable,r=e.childAt(0);r.useStyle(Mf(n)),r.attr({silent:!i,cursor:i?"move":"default"}),Object(_["k"])([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],(function(n){var r=e.childOfName(n.join("")),a=1===n.length?If(t,n[0]):Df(t,n);r&&r.attr({silent:!i,invisible:!i,cursor:i?of[a]+"-resize":null})}))}function Tf(t,e,n,i,r,a,o){var s=e.childOfName(n);s&&s.setShape(Nf(Pf(t,e,[[i,r],[i+a,r+o]])))}function Mf(t){return Object(_["i"])({strokeNoScale:!0},t.brushStyle)}function Af(t,e,n,i){var r=[Qd(t,n),Qd(e,i)],a=[Jd(t,n),Jd(e,i)];return[[r[0],a[0]],[r[1],a[1]]]}function Cf(t){return ne["getTransform"](t.group)}function If(t,e){var n={w:"left",e:"right",n:"top",s:"bottom"},i={left:"w",right:"e",top:"n",bottom:"s"},r=ne["transformDirection"](n[e],Cf(t));return i[r]}function Df(t,e){var n=[If(t,e[0]),If(t,e[1])];return("e"===n[0]||"w"===n[0])&&n.reverse(),n.join("")}function Lf(t,e,n,i,r,a){var o=n.__brushOption,s=t.toRectRange(o.range),l=jf(e,r,a);Object(_["k"])(i,(function(t){var e=af[t];s[e[0]][e[1]]+=l[e[0]]})),o.range=t.fromRectRange(Af(s[0][0],s[1][0],s[0][1],s[1][1])),pf(e,n),_f(e,{isEnd:!1})}function Ef(t,e,n,i){var r=e.__brushOption.range,a=jf(t,n,i);Object(_["k"])(r,(function(t){t[0]+=a[0],t[1]+=a[1]})),pf(t,e),_f(t,{isEnd:!1})}function jf(t,e,n){var i=t.group,r=i.transformCoordToLocal(e,n),a=i.transformCoordToLocal(0,0);return[r[0]-a[0],r[1]-a[1]]}function Pf(t,e,n){var i=vf(t,e);return i&&i!==Kd?i.clipPath(n,t._transform):Object(_["d"])(n)}function Nf(t){var e=Qd(t[0][0],t[1][0]),n=Qd(t[0][1],t[1][1]),i=Jd(t[0][0],t[1][0]),r=Jd(t[0][1],t[1][1]);return{x:e,y:n,width:i-e,height:r-n}}function Rf(t,e,n){if(t._brushType&&!Hf(t,e.offsetX,e.offsetY)){var i=t._zr,r=t._covers,a=mf(t,e,n);if(!t._dragging)for(var o=0;oi.getWidth()||n<0||n>i.getHeight()}var Uf={lineX:Wf(0),lineY:Wf(1),rect:{createCover:function(t,e){function n(t){return t}return wf({toRectRange:n,fromRectRange:n},t,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(t){var e=xf(t);return Af(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(t,e,n,i){Of(t,e,n,i)},updateCommon:Sf,contain:Bf},polygon:{createCover:function(t,e){var n=new Jt["a"];return n.add(new hi["a"]({name:"main",style:Mf(e),silent:!0})),n},getCreatingRange:function(t){return t},endCreating:function(t,e){e.remove(e.childAt(0)),e.add(new Oa["a"]({name:"main",draggable:!0,drift:Object(_["h"])(Ef,t,e),ondragend:Object(_["h"])(_f,t,{isEnd:!0})}))},updateCoverShape:function(t,e,n,i){e.childAt(0).setShape({points:Pf(t,e,n)})},updateCommon:Sf,contain:Bf}};function Wf(t){return{createCover:function(e,n){return wf({toRectRange:function(e){var n=[e,[0,100]];return t&&n.reverse(),n},fromRectRange:function(e){return e[t]}},e,n,[[["w"],["e"]],[["n"],["s"]]][t])},getCreatingRange:function(e){var n=xf(e),i=Qd(n[0][t],n[1][t]),r=Jd(n[0][t],n[1][t]);return[i,r]},updateCoverShape:function(e,n,i,r){var a,o=vf(e,n);if(o!==Kd&&o.getLinearBrushOtherExtent)a=o.getLinearBrushOtherExtent(t);else{var s=e._zr;a=[0,[s.getWidth(),s.getHeight()][1-t]]}var l=[i,a];t&&l.reverse(),Of(e,n,l,r)},updateCommon:Sf,contain:Bf}}var Xf=uf;function Zf(t){return t=Kf(t),function(e){return ne["clipPointsByRect"](e,t)}}function qf(t,e){return t=Kf(t),function(n){var i=null!=e?e:n,r=i?t.width:t.height,a=i?t.x:t.y;return[a,a+(r||0)]}}function Yf(t,e,n){var i=Kf(t);return function(t,r){return i.contain(r[0],r[1])&&!oo(t,e,n)}}function Kf(t){return ki["a"].create(t)}var Qf=["axisLine","axisTickLabel","axisName"],Jf=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(e,n){t.prototype.init.apply(this,arguments),(this._brushController=new Xf(n.getZr())).on("brush",_["c"](this._onBrush,this))},e.prototype.render=function(t,e,n,i){if(!$f(t,e,i)){this.axisModel=t,this.api=n,this.group.removeAll();var r=this._axisGroup;if(this._axisGroup=new Jt["a"],this.group.add(this._axisGroup),t.get("show")){var a=ep(t,e),o=a.coordinateSystem,s=t.getAreaSelectStyle(),l=s.width,u=t.axis.dim,c=o.getAxisLayout(u),h=_["m"]({strokeContainThreshold:l},c),d=new Wr(t,h);_["k"](Qf,d.add,d),this._axisGroup.add(d.getGroup()),this._refreshBrushController(h,s,t,a,l,n),ne["groupTransition"](r,this._axisGroup,t)}}},e.prototype._refreshBrushController=function(t,e,n,i,r,a){var o=n.axis.getExtent(),s=o[1]-o[0],l=Math.min(30,.1*Math.abs(s)),u=ki["a"].create({x:o[0],y:-r/2,width:s,height:r});u.x-=l,u.width+=2*l,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:Zf(u),isTargetByCursor:Yf(u,a,i),getLinearBrushOtherExtent:qf(u,0)}]).enableBrush({brushType:"lineX",brushStyle:e,removeOnClick:!0}).updateCovers(tp(n))},e.prototype._onBrush=function(t){var e=t.areas,n=this.axisModel,i=n.axis,r=_["H"](e,(function(t){return[i.coordToData(t.range[0],!0),i.coordToData(t.range[1],!0)]}));(!n.option.realtime===t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:n.id,intervals:r})},e.prototype.dispose=function(){this._brushController.dispose()},e.type="parallelAxis",e}(Wi["a"]);function $f(t,e,n){return n&&"axisAreaSelect"===n.type&&e.findComponents({mainType:"parallelAxis",query:n})[0]===t}function tp(t){var e=t.axis;return _["H"](t.activeIntervals,(function(t){return{brushType:"lineX",panelId:"pl",range:[e.dataToCoord(t[0],!0),e.dataToCoord(t[1],!0)]}}))}function ep(t,e){return e.getComponent("parallel",t.get("parallelIndex"))}var np=Jf,ip={type:"axisAreaSelect",event:"axisAreaSelected"};function rp(t){t.registerAction(ip,(function(t,e){e.eachComponent({mainType:"parallelAxis",query:t},(function(e){e.axis.model.setActiveIntervals(t.intervals)}))})),t.registerAction("parallelAxisExpand",(function(t,e){e.eachComponent({mainType:"parallel",query:t},(function(e){e.setAxisExpand(t)}))}))}var ap={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function op(t){t.registerComponentView(Td),t.registerComponentModel(Ad),t.registerCoordinateSystem("parallel",Zd),t.registerPreprocessor(yd),t.registerComponentModel(Yd),t.registerComponentView(np),ar(t,"parallel",Yd,ap),rp(t)}function sp(t){Object(i["a"])(op),t.registerChartView(cd),t.registerSeriesModel(pd),t.registerVisual(t.PRIORITY.VISUAL.BRUSH,vd)}var lp=function(){function t(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0}return t}(),up=function(t){function e(e){return t.call(this,e)||this}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new lp},e.prototype.buildPath=function(t,e){var n=e.extent;t.moveTo(e.x1,e.y1),t.bezierCurveTo(e.cpx1,e.cpy1,e.cpx2,e.cpy2,e.x2,e.y2),"vertical"===e.orient?(t.lineTo(e.x2+n,e.y2),t.bezierCurveTo(e.cpx2+n,e.cpy2,e.cpx1+n,e.cpy1,e.x1+n,e.y1)):(t.lineTo(e.x2,e.y2+n),t.bezierCurveTo(e.cpx2,e.cpy2+n,e.cpx1,e.cpy1+n,e.x1,e.y1+n)),t.closePath()},e.prototype.highlight=function(){Object(re["r"])(this)},e.prototype.downplay=function(){Object(re["C"])(this)},e}(s["b"]),cp=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._focusAdjacencyDisabled=!1,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=this,r=t.getGraph(),a=this.group,o=t.layoutInfo,s=o.width,l=o.height,u=t.getData(),c=t.getData("edge"),h=t.get("orient");this._model=t,a.removeAll(),a.x=o.x,a.y=o.y,r.eachEdge((function(e){var n=new up,i=Object(ie["a"])(n);i.dataIndex=e.dataIndex,i.seriesIndex=t.seriesIndex,i.dataType="edge";var r,o,u,d,f,p,g,m,v=e.getModel(),y=v.getModel("lineStyle"),b=y.get("curveness"),x=e.node1.getLayout(),w=e.node1.getModel(),O=w.get("localX"),S=w.get("localY"),T=e.node2.getLayout(),M=e.node2.getModel(),A=M.get("localX"),C=M.get("localY"),I=e.getLayout();switch(n.shape.extent=Math.max(1,I.dy),n.shape.orient=h,"vertical"===h?(r=(null!=O?O*s:x.x)+I.sy,o=(null!=S?S*l:x.y)+x.dy,u=(null!=A?A*s:T.x)+I.ty,d=null!=C?C*l:T.y,f=r,p=o*(1-b)+d*b,g=u,m=o*b+d*(1-b)):(r=(null!=O?O*s:x.x)+x.dx,o=(null!=S?S*l:x.y)+I.sy,u=null!=A?A*s:T.x,d=(null!=C?C*l:T.y)+I.ty,f=r*(1-b)+u*b,p=o,g=r*b+u*(1-b),m=d),n.setShape({x1:r,y1:o,x2:u,y2:d,cpx1:f,cpy1:p,cpx2:g,cpy2:m}),n.useStyle(y.getItemStyle()),n.style.fill){case"source":n.style.fill=e.node1.getVisual("color"),n.style.decal=e.node1.getVisual("style").decal;break;case"target":n.style.fill=e.node2.getVisual("color"),n.style.decal=e.node2.getVisual("style").decal;break;case"gradient":var D=e.node1.getVisual("color"),L=e.node2.getVisual("color");Object(_["C"])(D)&&Object(_["C"])(L)&&(n.style.fill=new Se["a"](0,0,+("horizontal"===h),+("vertical"===h),[{color:D,offset:0},{color:L,offset:1}]))}var E=v.getModel("emphasis");Object(re["I"])(n,v,"lineStyle",(function(t){return t.getItemStyle()})),a.add(n),c.setItemGraphicEl(e.dataIndex,n);var j=E.get("focus");Object(re["J"])(n,"adjacency"===j?e.getAdjacentDataIndices():j,E.get("blurScope"),E.get("disabled")),Object(ie["a"])(n).dataType="edge"})),r.eachNode((function(e){var n=e.getLayout(),i=e.getModel(),r=i.get("localX"),o=i.get("localY"),c=i.getModel("emphasis"),h=new Re["a"]({shape:{x:null!=r?r*s:n.x,y:null!=o?o*l:n.y,width:n.dx,height:n.dy},style:i.getModel("itemStyle").getItemStyle(),z2:10});Object(le["g"])(h,Object(le["e"])(i),{labelFetcher:t,labelDataIndex:e.dataIndex,defaultText:e.id}),h.disableLabelAnimation=!0,h.setStyle("fill",e.getVisual("color")),h.setStyle("decal",e.getVisual("style").decal),Object(re["I"])(h,i),a.add(h),u.setItemGraphicEl(e.dataIndex,h),Object(ie["a"])(h).dataType="node";var d=c.get("focus");Object(re["J"])(h,"adjacency"===d?e.getAdjacentDataIndices():d,c.get("blurScope"),c.get("disabled"))})),u.eachItemGraphicEl((function(e,r){var a=u.getItemModel(r);a.get("draggable")&&(e.drift=function(e,a){i._focusAdjacencyDisabled=!0,this.shape.x+=e,this.shape.y+=a,this.dirty(),n.dispatchAction({type:"dragNode",seriesId:t.id,dataIndex:u.getRawIndex(r),localX:this.shape.x/s,localY:this.shape.y/l})},e.ondragend=function(){i._focusAdjacencyDisabled=!1},e.draggable=!0,e.cursor="move")})),!this._data&&t.isAnimationEnabled()&&a.setClipPath(hp(a.getBoundingRect(),t,(function(){a.removeClipPath()}))),this._data=t.getData()},e.prototype.dispose=function(){},e.type="sankey",e}(Ne["a"]);function hp(t,e,n){var i=new Re["a"]({shape:{x:t.x-10,y:t.y-10,width:0,height:t.height+20}});return ee["c"](i,{shape:{width:t.width+20}},e,n),i}var dp=cp,fp=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t,e){var n=t.edges||t.links,i=t.data||t.nodes,r=t.levels;this.levelModels=[];for(var a=this.levelModels,o=0;o=0&&(a[r[o].depth]=new Er["a"](r[o],this,e));if(i&&n){var s=Ih(i,n,this,!0,l);return s.data}function l(t,e){t.wrapMethod("getItemModel",(function(t,e){var n=t.parentModel,i=n.getData().getItemLayout(e);if(i){var r=i.depth,a=n.levelModels[r];a&&(t.parentModel=a)}return t})),e.wrapMethod("getItemModel",(function(t,e){var n=t.parentModel,i=n.getGraph().getEdgeByIndex(e),r=i.node1.getLayout();if(r){var a=r.depth,o=n.levelModels[a];o&&(t.parentModel=o)}return t}))}},e.prototype.setNodePosition=function(t,e){var n=this.option.data||this.option.nodes,i=n[t];i.localX=e[0],i.localY=e[1]},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,e,n){function i(t){return isNaN(t)||null==t}if("edge"===n){var r=this.getDataParams(t,n),a=r.data,o=r.value,s=a.source+" -- "+a.target;return Object(Ma["c"])("nameValue",{name:s,value:o,noValue:i(o)})}var l=this.getGraph().getNodeByIndex(t),u=l.getLayout().value,c=this.getDataParams(t,n).data.name;return Object(Ma["c"])("nameValue",{name:null!=c?c+"":null,value:u,noValue:i(u)})},e.prototype.optionUpdated=function(){},e.prototype.getDataParams=function(e,n){var i=t.prototype.getDataParams.call(this,e,n);if(null==i.value&&"node"===n){var r=this.getGraph().getNodeByIndex(e),a=r.getLayout().value;i.value=a}return i},e.type="series.sankey",e.defaultOption={z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3},e}(Kt["b"]),pp=fp;function gp(t,e){t.eachSeriesByType("sankey",(function(t){var n=t.get("nodeWidth"),i=t.get("nodeGap"),r=mp(t,e);t.layoutInfo=r;var a=r.width,o=r.height,s=t.getGraph(),l=s.nodes,u=s.edges;yp(l);var c=_["n"](l,(function(t){return 0===t.getLayout().value})),h=0!==c.length?0:t.get("layoutIterations"),d=t.get("orient"),f=t.get("nodeAlign");vp(l,u,n,i,a,o,h,d,f)}))}function mp(t,e){return ri["g"](t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function vp(t,e,n,i,r,a,o,s,l){_p(t,e,n,r,a,s,l),Sp(t,e,a,r,i,o,s),kp(t,s)}function yp(t){_["k"](t,(function(t){var e=Np(t.outEdges,Pp),n=Np(t.inEdges,Pp),i=t.getValue()||0,r=Math.max(e,n,i);t.setLayout({value:r},!0)}))}function _p(t,e,n,i,r,a,o){for(var s=[],l=[],u=[],c=[],h=0,d=0;d=0;v&&m.depth>f&&(f=m.depth),g.setLayout({depth:v?m.depth:h},!0),"vertical"===a?g.setLayout({dy:n},!0):g.setLayout({dx:n},!0);for(var y=0;yh-1?f:h-1;o&&"left"!==o&&xp(t,o,a,O);var S="vertical"===a?(r-n)/O:(i-n)/O;Op(t,S,a)}function bp(t){var e=t.hostGraph.data.getRawDataItem(t.dataIndex);return null!=e.depth&&e.depth>=0}function xp(t,e,n,i){if("right"===e){var r=[],a=t,o=0;while(a.length){for(var s=0;s0;a--)l*=.99,Cp(s,l,o),Ap(s,r,n,i,o),Rp(s,l,o),Ap(s,r,n,i,o)}function Tp(t,e){var n=[],i="vertical"===e?"y":"x",r=Object(Te["j"])(t,(function(t){return t.getLayout()[i]}));return r.keys.sort((function(t,e){return t-e})),_["k"](r.keys,(function(t){n.push(r.buckets.get(t))})),n}function Mp(t,e,n,i,r,a){var o=1/0;_["k"](t,(function(t){var e=t.length,s=0;_["k"](t,(function(t){s+=t.getLayout().value}));var l="vertical"===a?(i-(e-1)*r)/s:(n-(e-1)*r)/s;l0&&(o=s.getLayout()[a]+l,"vertical"===r?s.setLayout({x:o},!0):s.setLayout({y:o},!0)),u=s.getLayout()[a]+s.getLayout()[h]+e;var f="vertical"===r?i:n;if(l=u-e-f,l>0){o=s.getLayout()[a]-l,"vertical"===r?s.setLayout({x:o},!0):s.setLayout({y:o},!0),u=o;for(d=c-2;d>=0;--d)s=t[d],l=s.getLayout()[a]+s.getLayout()[h]+e-u,l>0&&(o=s.getLayout()[a]-l,"vertical"===r?s.setLayout({x:o},!0):s.setLayout({y:o},!0)),u=s.getLayout()[a]}}))}function Cp(t,e,n){_["k"](t.slice().reverse(),(function(t){_["k"](t,(function(t){if(t.outEdges.length){var i=Np(t.outEdges,Ip,n)/Np(t.outEdges,Pp);if(isNaN(i)){var r=t.outEdges.length;i=r?Np(t.outEdges,Dp,n)/r:0}if("vertical"===n){var a=t.getLayout().x+(i-jp(t,n))*e;t.setLayout({x:a},!0)}else{var o=t.getLayout().y+(i-jp(t,n))*e;t.setLayout({y:o},!0)}}}))}))}function Ip(t,e){return jp(t.node2,e)*t.getValue()}function Dp(t,e){return jp(t.node2,e)}function Lp(t,e){return jp(t.node1,e)*t.getValue()}function Ep(t,e){return jp(t.node1,e)}function jp(t,e){return"vertical"===e?t.getLayout().x+t.getLayout().dx/2:t.getLayout().y+t.getLayout().dy/2}function Pp(t){return t.getValue()}function Np(t,e,n){var i=0,r=t.length,a=-1;while(++ar&&(r=e)})),_["k"](n,(function(e){var n=new Gu({type:"color",mappingMethod:"linear",dataExtent:[i,r],visual:t.get("color")}),a=n.mapValueToVisual(e.getLayout().value),o=e.getModel().get(["itemStyle","color"]);null!=o?(e.setVisual("color",o),e.setVisual("style",{fill:o})):(e.setVisual("color",a),e.setVisual("style",{fill:a}))}))}}))}function zp(t){t.registerChartView(dp),t.registerSeriesModel(pp),t.registerLayout(gp),t.registerVisual(Bp),t.registerAction({type:"dragNode",event:"dragnode",update:"update"},(function(t,e){e.eachComponent({mainType:"series",subType:"sankey",query:t},(function(e){e.setNodePosition(t.dataIndex,[t.localX,t.localY])}))}))}var Vp=n("2f45"),Fp=function(){function t(){}return t.prototype.getInitialData=function(t,e){var n,i,r=e.getComponent("xAxis",this.get("xAxisIndex")),a=e.getComponent("yAxis",this.get("yAxisIndex")),o=r.get("type"),s=a.get("type");"category"===o?(t.layout="horizontal",n=r.getOrdinalMeta(),i=!0):"category"===s?(t.layout="vertical",n=a.getOrdinalMeta(),i=!0):t.layout=t.layout||"horizontal";var l=["x","y"],u="horizontal"===t.layout?0:1,c=this._baseAxisDim=l[u],h=l[1-u],d=[r,a],f=d[u].get("type"),p=d[1-u].get("type"),g=t.data;if(g&&i){var m=[];_["k"](g,(function(t,e){var n;_["t"](t)?(n=t.slice(),t.unshift(e)):_["t"](t.value)?(n=_["m"]({},t),n.value=n.value.slice(),t.value.unshift(e)):n=t,m.push(n)})),t.data=m}var v=this.defaultValueDimensions,y=[{name:c,type:Object(Vp["a"])(f),ordinalMeta:n,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:h,type:Object(Vp["a"])(p),dimsDef:v.slice()}];return Ai(this,{coordDimensions:y,dimensionsCount:v.length+1,encodeDefaulter:_["h"](Ci["c"],y,this)})},t.prototype.getBaseAxis=function(){var t=this._baseAxisDim;return this.ecModel.getComponent(t+"Axis",this.get(t+"AxisIndex")).axis},t}(),Gp=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],n.visualDrawType="stroke",n}return Object(qt["a"])(e,t),e.type="series.boxplot",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800},e}(Kt["b"]);Object(_["K"])(Gp,Fp,!0);var Hp=Gp,Up=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=t.getData(),r=this.group,a=this._data;this._data||r.removeAll();var o="horizontal"===t.get("layout")?1:0;i.diff(a).add((function(t){if(i.hasValue(t)){var e=i.getItemLayout(t),n=Zp(e,i,t,o,!0);i.setItemGraphicEl(t,n),r.add(n)}})).update((function(t,e){var n=a.getItemGraphicEl(e);if(i.hasValue(t)){var s=i.getItemLayout(t);n?(Object(ee["g"])(n),qp(s,n,i,t)):n=Zp(s,i,t,o),r.add(n),i.setItemGraphicEl(t,n)}else r.remove(n)})).remove((function(t){var e=a.getItemGraphicEl(t);e&&r.remove(e)})).execute(),this._data=i},e.prototype.remove=function(t){var e=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl((function(t){t&&e.remove(t)}))},e.type="boxplot",e}(Ne["a"]),Wp=function(){function t(){}return t}(),Xp=function(t){function e(e){var n=t.call(this,e)||this;return n.type="boxplotBoxPath",n}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new Wp},e.prototype.buildPath=function(t,e){var n=e.points,i=0;for(t.moveTo(n[i][0],n[i][1]),i++;i<4;i++)t.lineTo(n[i][0],n[i][1]);for(t.closePath();ig){var x=[v,b];i.push(x)}}}return{boxData:n,outliers:i}}var rg=n("07fd"),ag={type:"echarts:boxplot",transform:function(t){var e=t.upstream;if(e.sourceFormat!==rg["c"]){var n="";0,Object(Su["c"])(n)}var i=ig(e.getRawData(),t.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:i.boxData},{data:i.outliers}]}};function og(t){t.registerSeriesModel(Hp),t.registerChartView(Kp),t.registerVisual(Qp),t.registerLayout($p),t.registerTransform(ag)}var sg=["color","borderColor"],lg=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},e.prototype.incrementalPrepareRender=function(t,e,n){this._clear(),this._updateDrawMode(t)},e.prototype.incrementalRender=function(t,e,n,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,e):this._incrementalRenderNormal(t,e)},e.prototype.eachRendered=function(t){ne["traverseElements"](this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var e=t.pipelineContext.large;null!=this._isLargeDraw&&e===this._isLargeDraw||(this._isLargeDraw=e,this._clear())},e.prototype._renderNormal=function(t){var e=t.getData(),n=this._data,i=this.group,r=e.getLayout("isSimpleBox"),a=t.get("clip",!0),o=t.coordinateSystem,s=o.getArea&&o.getArea();this._data||i.removeAll(),e.diff(n).add((function(n){if(e.hasValue(n)){var o=e.getItemLayout(n);if(a&&dg(s,o))return;var l=hg(o,n,!0);ee["c"](l,{shape:{points:o.ends}},t,n),fg(l,e,n,r),i.add(l),e.setItemGraphicEl(n,l)}})).update((function(o,l){var u=n.getItemGraphicEl(l);if(e.hasValue(o)){var c=e.getItemLayout(o);a&&dg(s,c)?i.remove(u):(u?(ee["h"](u,{shape:{points:c.ends}},t,o),Object(ee["g"])(u)):u=hg(c,o),fg(u,e,o,r),i.add(u),e.setItemGraphicEl(o,u))}else i.remove(u)})).remove((function(t){var e=n.getItemGraphicEl(t);e&&i.remove(e)})).execute(),this._data=e},e.prototype._renderLarge=function(t){this._clear(),vg(t,this.group);var e=t.get("clip",!0)?Fe(t.coordinateSystem,!1,t):null;e?this.group.setClipPath(e):this.group.removeClipPath()},e.prototype._incrementalRenderNormal=function(t,e){var n,i=e.getData(),r=i.getLayout("isSimpleBox");while(null!=(n=t.next())){var a=i.getItemLayout(n),o=hg(a,n);fg(o,i,n,r),o.incremental=!0,this.group.add(o),this._progressiveEls.push(o)}},e.prototype._incrementalRenderLarge=function(t,e){vg(e,this.group,this._progressiveEls,!0)},e.prototype.remove=function(t){this._clear()},e.prototype._clear=function(){this.group.removeAll(),this._data=null},e.type="candlestick",e}(Ne["a"]),ug=function(){function t(){}return t}(),cg=function(t){function e(e){var n=t.call(this,e)||this;return n.type="normalCandlestickBox",n}return Object(qt["a"])(e,t),e.prototype.getDefaultShape=function(){return new ug},e.prototype.buildPath=function(t,e){var n=e.points;this.__simpleBox?(t.moveTo(n[4][0],n[4][1]),t.lineTo(n[6][0],n[6][1])):(t.moveTo(n[0][0],n[0][1]),t.lineTo(n[1][0],n[1][1]),t.lineTo(n[2][0],n[2][1]),t.lineTo(n[3][0],n[3][1]),t.closePath(),t.moveTo(n[4][0],n[4][1]),t.lineTo(n[5][0],n[5][1]),t.moveTo(n[6][0],n[6][1]),t.lineTo(n[7][0],n[7][1]))},e}(s["b"]);function hg(t,e,n){var i=t.ends;return new cg({shape:{points:n?pg(i,t):i},z2:100})}function dg(t,e){for(var n=!0,i=0;i0?"borderColor":"borderColor0"])||n.get(["itemStyle",t>0?"color":"color0"]),a=n.getModel("itemStyle").getItemStyle(sg);e.useStyle(a),e.style.fill=null,e.style.stroke=r}var _g=lg,bg=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],n}return Object(qt["a"])(e,t),e.prototype.getShadowDim=function(){return"open"},e.prototype.brushSelector=function(t,e,n){var i=e.getItemLayout(t);return i&&n.rect(i.brushRect)},e.type="series.candlestick",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e}(Kt["b"]);Object(_["K"])(bg,Fp,!0);var xg=bg;function wg(t){t&&_["t"](t.series)&&_["k"](t.series,(function(t){_["A"](t)&&"k"===t.type&&(t.type="candlestick")}))}var Og=["itemStyle","borderColor"],Sg=["itemStyle","borderColor0"],Tg=["itemStyle","color"],Mg=["itemStyle","color0"],Ag={seriesType:"candlestick",plan:Object(hn["a"])(),performRawSeries:!0,reset:function(t,e){function n(t,e){return e.get(t>0?Tg:Mg)}function i(t,e){return e.get(t>0?Og:Sg)}if(!e.isSeriesFiltered(t)){var r=t.pipelineContext.large;return!r&&{progress:function(t,e){var r;while(null!=(r=t.next())){var a=e.getItemModel(r),o=e.getItemLayout(r).sign,s=a.getItemStyle();s.fill=n(o,a),s.stroke=i(o,a)||s.fill;var l=e.ensureUniqueItemVisual(r,"style");Object(_["m"])(l,s)}}}}}},Cg=Ag,Ig={seriesType:"candlestick",plan:Object(hn["a"])(),reset:function(t){var e=t.coordinateSystem,n=t.getData(),i=Lg(t,n),r=0,a=1,o=["x","y"],s=n.getDimensionIndex(n.mapDimension(o[r])),l=Object(_["H"])(n.mapDimensionsAll(o[a]),n.getDimensionIndex,n),u=l[0],c=l[1],h=l[2],d=l[3];if(n.setLayout({candleWidth:i,isSimpleBox:i<=1.3}),!(s<0||l.length<4))return{progress:t.pipelineContext.large?p:f};function f(t,n){var o,l=n.getStore();while(null!=(o=t.next())){var f=l.get(s,o),p=l.get(u,o),g=l.get(c,o),m=l.get(h,o),v=l.get(d,o),y=Math.min(p,g),_=Math.max(p,g),b=T(y,f),x=T(_,f),w=T(m,f),O=T(v,f),S=[];M(S,x,0),M(S,b,1),S.push(C(O),C(x),C(w),C(b)),n.setItemLayout(o,{sign:Dg(l,o,p,g,c),initBaseline:p>g?x[a]:b[a],ends:S,brushRect:A(m,v,f)})}function T(t,n){var i=[];return i[r]=n,i[a]=t,isNaN(n)||isNaN(t)?[NaN,NaN]:e.dataToPoint(i)}function M(t,e,n){var a=e.slice(),o=e.slice();a[r]=Object(ne["subPixelOptimize"])(a[r]+i/2,1,!1),o[r]=Object(ne["subPixelOptimize"])(o[r]-i/2,1,!0),n?t.push(a,o):t.push(o,a)}function A(t,e,n){var o=T(t,n),s=T(e,n);return o[r]-=i/2,s[r]-=i/2,{x:o[0],y:o[1],width:a?i:s[0]-o[0],height:a?s[1]-o[1]:i}}function C(t){return t[r]=Object(ne["subPixelOptimize"])(t[r],1),t}}function p(t,n){var i,o,l=Object(xe["a"])(4*t.count),f=0,p=[],g=[],m=n.getStore();while(null!=(o=t.next())){var v=m.get(s,o),y=m.get(u,o),_=m.get(c,o),b=m.get(h,o),x=m.get(d,o);isNaN(v)||isNaN(b)||isNaN(x)?(l[f++]=NaN,f+=3):(l[f++]=Dg(m,o,y,_,c),p[r]=v,p[a]=b,i=e.dataToPoint(p,null,g),l[f++]=i?i[0]:NaN,l[f++]=i?i[1]:NaN,p[a]=x,i=e.dataToPoint(p,null,g),l[f++]=i?i[1]:NaN)}n.setLayout("largePoints",l)}}};function Dg(t,e,n,i,r){var a;return a=n>i?-1:n0?t.get(r,e-1)<=i?1:-1:1,a}function Lg(t,e){var n,i=t.getBaseAxis(),r="category"===i.type?i.getBandWidth():(n=i.getExtent(),Math.abs(n[1]-n[0])/e.count()),a=Object(Be["p"])(Object(_["P"])(t.get("barMaxWidth"),r),r),o=Object(Be["p"])(Object(_["P"])(t.get("barMinWidth"),1),r),s=t.get("barWidth");return null!=s?Object(Be["p"])(s,r):Math.max(Math.min(r/2,a),o)}var Eg=Ig;function jg(t){t.registerChartView(_g),t.registerSeriesModel(xg),t.registerPreprocessor(wg),t.registerVisual(Cg),t.registerLayout(Eg)}function Pg(t,e){var n=e.rippleEffectColor||e.color;t.eachChild((function(t){t.attr({z:e.z,zlevel:e.zlevel,style:{stroke:"stroke"===e.brushType?n:null,fill:"fill"===e.brushType?n:null}})}))}var Ng=function(t){function e(e,n){var i=t.call(this)||this,r=new he(e,n),a=new Jt["a"];return i.add(r),i.add(a),i.updateData(e,n),i}return Object(qt["a"])(e,t),e.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},e.prototype.startEffectAnimation=function(t){for(var e=t.symbolType,n=t.color,i=t.rippleNumber,r=this.childAt(1),a=0;a0&&(a=this._getLineLength(i)/s*1e3),a!==this._period||o!==this._loop){i.stopAnimation();var u=void 0;u=_["w"](l)?l(n):l,i.__t>0&&(u=-a*i.__t),this._animateSymbol(i,a,u,o)}this._period=a,this._loop=o}},e.prototype._animateSymbol=function(t,e,n,i){if(e>0){t.__t=0;var r=this,a=t.animate("",i).when(e,{__t:1}).delay(n).during((function(){r._updateSymbolPosition(t)}));i||a.done((function(){r.remove(t)})),a.start()}},e.prototype._getLineLength=function(t){return cr["f"](t.__p1,t.__cp1)+cr["f"](t.__cp1,t.__p2)},e.prototype._updateAnimationPoints=function(t,e){t.__p1=e[0],t.__p2=e[1],t.__cp1=e[2]||[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]},e.prototype.updateData=function(t,e,n){this.childAt(0).updateData(t,e,n),this._updateEffectSymbol(t,e)},e.prototype._updateSymbolPosition=function(t){var e=t.__p1,n=t.__p2,i=t.__cp1,r=t.__t,a=[t.x,t.y],o=a.slice(),s=Me["h"],l=Me["i"];a[0]=s(e[0],i[0],n[0],r),a[1]=s(e[1],i[1],n[1],r);var u=l(e[0],i[0],n[0],r),c=l(e[1],i[1],n[1],r);t.rotation=-Math.atan2(c,u)-Math.PI/2,"line"!==this._symbolType&&"rect"!==this._symbolType&&"roundRect"!==this._symbolType||(void 0!==t.__lastT&&t.__lastT=0;a--)if(i[a]<=e)break;a=Math.min(a,r-2)}else{for(a=o;ae)break;a=Math.min(a-1,r-2)}var l=(e-i[a])/(i[a+1]-i[a]),u=n[a],c=n[a+1];t.x=u[0]*(1-l)+l*c[0],t.y=u[1]*(1-l)+l*c[1];var h=c[0]-u[0],d=c[1]-u[1];t.rotation=-Math.atan2(d,h)-Math.PI/2,this._lastFrame=a,this._lastFramePercent=e,t.ignore=!1}},e}(Hg),Zg=Xg,qg=n("9680"),Yg=n("68ab"),Kg=function(){function t(){this.polyline=!1,this.curveness=0,this.segs=[]}return t}(),Qg=function(t){function e(e){var n=t.call(this,e)||this;return n._off=0,n.hoverDataIdx=-1,n}return Object(qt["a"])(e,t),e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Kg},e.prototype.buildPath=function(t,e){var n,i=e.segs,r=e.curveness;if(e.polyline)for(n=this._off;n0){t.moveTo(i[n++],i[n++]);for(var o=1;o0){var h=(s+u)/2-(l-c)*r,d=(l+c)/2-(u-s)*r;t.quadraticCurveTo(h,d,u,c)}else t.lineTo(u,c)}this.incremental&&(this._off=n,this.notClear=!0)},e.prototype.findDataIndex=function(t,e){var n=this.shape,i=n.segs,r=n.curveness,a=this.style.lineWidth;if(n.polyline)for(var o=0,s=0;s0)for(var u=i[s++],c=i[s++],h=1;h0){var p=(u+d)/2-(c-f)*r,g=(c+f)/2-(d-u)*r;if(Yg["a"](u,c,p,g,d,f,a,t,e))return o}else if(qg["a"](u,c,d,f,a,t,e))return o;o++}return-1},e.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();if(t=n[0],e=n[1],i.contain(t,e)){var r=this.hoverDataIdx=this.findDataIndex(t,e);return r>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var e=this.shape,n=e.segs,i=1/0,r=1/0,a=-1/0,o=-1/0,s=0;s0&&(a.dataIndex=n+t.__startIndex)}))},t.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},t}(),$g=Jg,tm={seriesType:"lines",plan:Object(hn["a"])(),reset:function(t){var e=t.coordinateSystem;if(e){var n=t.get("polyline"),i=t.pipelineContext.large;return{progress:function(r,a){var o=[];if(i){var s=void 0,l=r.end-r.start;if(n){for(var u=0,c=r.start;c0&&(l||s.configLayer(a,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(o/10+.9,1),0)})),r.updateData(i);var u=t.get("clip",!0)&&Fe(t.coordinateSystem,!1,t);u?this.group.setClipPath(u):this.group.removeClipPath(),this._lastZlevel=a,this._finished=!0},e.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData(),r=this._updateLineDraw(i,t);r.incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},e.prototype.incrementalRender=function(t,e,n){this._lineDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},e.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},e.prototype.updateTransform=function(t,e,n){var i=t.getData(),r=t.pipelineContext;if(!this._finished||r.large||r.progressiveRender)return{update:!0};var a=em.reset(t,e,n);a.progress&&a.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(n)},e.prototype._updateLineDraw=function(t,e){var n=this._lineDraw,i=this._showEffect(e),r=!!e.get("polyline"),a=e.pipelineContext,o=a.large;return n&&i===this._hasEffet&&r===this._isPolyline&&o===this._isLargeDraw||(n&&n.remove(),n=this._lineDraw=o?new $g:new gh(r?i?Zg:Wg:i?Hg:uh),this._hasEffet=i,this._isPolyline=r,this._isLargeDraw=o),this.group.add(n.group),n},e.prototype._showEffect=function(t){return!!t.get(["effect","show"])},e.prototype._clearLayer=function(t){var e=t.getZr(),n="svg"===e.painter.getType();n||null==this._lastZlevel||e.painter.getLayer(this._lastZlevel).clear(!0)},e.prototype.remove=function(t,e){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(e)},e.prototype.dispose=function(t,e){this.remove(t,e)},e.type="lines",e}(Ne["a"]),im=nm,rm="undefined"===typeof Uint32Array?Array:Uint32Array,am="undefined"===typeof Float64Array?Array:Float64Array;function om(t){var e=t.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(t.data=Object(_["H"])(e,(function(t){var e=[t[0].coord,t[1].coord],n={coords:e};return t[0].name&&(n.fromName=t[0].name),t[1].name&&(n.toName=t[1].name),Object(_["J"])([n,t[0],t[1]])})))}var sm=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.visualStyleAccessPath="lineStyle",n.visualDrawType="stroke",n}return Object(qt["a"])(e,t),e.prototype.init=function(e){e.data=e.data||[],om(e);var n=this._processFlatCoordsArray(e.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(e.data=new Float32Array(n.count)),t.prototype.init.apply(this,arguments)},e.prototype.mergeOption=function(e){if(om(e),e.data){var n=this._processFlatCoordsArray(e.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(e.data=new Float32Array(n.count))}t.prototype.mergeOption.apply(this,arguments)},e.prototype.appendData=function(t){var e=this._processFlatCoordsArray(t.data);e.flatCoords&&(this._flatCoords?(this._flatCoords=Object(_["e"])(this._flatCoords,e.flatCoords),this._flatCoordsOffset=Object(_["e"])(this._flatCoordsOffset,e.flatCoordsOffset)):(this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset),t.data=new Float32Array(e.count)),this.getRawData().appendData(t.data)},e.prototype._getCoordsFromItemModel=function(t){var e=this.getData().getItemModel(t),n=e.option instanceof Array?e.option:e.getShallow("coords");return n},e.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[2*t+1]:this._getCoordsFromItemModel(t).length},e.prototype.getLineCoords=function(t,e){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[2*t],i=this._flatCoordsOffset[2*t+1],r=0;r ")})},e.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},e.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?1e4:this.get("progressive"):t},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?2e4:this.get("progressiveThreshold"):t},e.prototype.getZLevelKey=function(){var t=this.getModel("effect"),e=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&e>0?e+"":""},e.type="series.lines",e.dependencies=["grid","polar","geo","calendar"],e.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},e}(Kt["b"]),lm=sm;function um(t){return t instanceof Array||(t=[t,t]),t}var cm={seriesType:"lines",reset:function(t){var e=um(t.get("symbol")),n=um(t.get("symbolSize")),i=t.getData();function r(t,e){var n=t.getItemModel(e),i=um(n.getShallow("symbol",!0)),r=um(n.getShallow("symbolSize",!0));i[0]&&t.setItemVisual(e,"fromSymbol",i[0]),i[1]&&t.setItemVisual(e,"toSymbol",i[1]),r[0]&&t.setItemVisual(e,"fromSymbolSize",r[0]),r[1]&&t.setItemVisual(e,"toSymbolSize",r[1])}return i.setVisual("fromSymbol",e&&e[0]),i.setVisual("toSymbol",e&&e[1]),i.setVisual("fromSymbolSize",n&&n[0]),i.setVisual("toSymbolSize",n&&n[1]),{dataEach:i.hasItemOption?r:null}}},hm=cm;function dm(t){t.registerChartView(im),t.registerSeriesModel(lm),t.registerLayout(em),t.registerVisual(hm)}var fm=256,pm=function(){function t(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var t=tt["d"].createCanvas();this.canvas=t}return t.prototype.update=function(t,e,n,i,r,a){var o=this._getBrush(),s=this._getGradient(r,"inRange"),l=this._getGradient(r,"outOfRange"),u=this.pointSize+this.blurSize,c=this.canvas,h=c.getContext("2d"),d=t.length;c.width=e,c.height=n;for(var f=0;f0){var A=a(y)?s:l;y>0&&(y=y*T+O),b[x++]=A[M],b[x++]=A[M+1],b[x++]=A[M+2],b[x++]=A[M+3]*y*256}else x+=4}return h.putImageData(_,0,0),c},t.prototype._getBrush=function(){var t=this._brushCanvas||(this._brushCanvas=tt["d"].createCanvas()),e=this.pointSize+this.blurSize,n=2*e;t.width=n,t.height=n;var i=t.getContext("2d");return i.clearRect(0,0,n,n),i.shadowOffsetX=n,i.shadowBlur=this.blurSize,i.shadowColor="#000",i.beginPath(),i.arc(-e,e,this.pointSize,0,2*Math.PI,!0),i.closePath(),i.fill(),t},t.prototype._getGradient=function(t,e){for(var n=this._gradientPixels,i=n[e]||(n[e]=new Uint8ClampedArray(1024)),r=[0,0,0,0],a=0,o=0;o<256;o++)t[e](o/255,!0,r),i[a++]=r[0],i[a++]=r[1],i[a++]=r[2],i[a++]=r[3];return i},t}(),gm=pm;function mm(t,e,n){var i=t[1]-t[0];e=_["H"](e,(function(e){return{interval:[(e.interval[0]-t[0])/i,(e.interval[1]-t[0])/i]}}));var r=e.length,a=0;return function(t){var i;for(i=a;i=0;i--){o=e[i].interval;if(o[0]<=t&&t<=o[1]){a=i;break}}return i>=0&&i=e[0]&&t<=e[1]}}function ym(t){var e=t.dimensions;return"lng"===e[0]&&"lat"===e[1]}var _m=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i;e.eachComponent("visualMap",(function(e){e.eachTargetSeries((function(n){n===t&&(i=e)}))})),this._progressiveEls=null,this.group.removeAll();var r=t.coordinateSystem;"cartesian2d"===r.type||"calendar"===r.type?this._renderOnCartesianAndCalendar(t,n,0,t.getData().count()):ym(r)&&this._renderOnGeo(r,t,i,n)},e.prototype.incrementalPrepareRender=function(t,e,n){this.group.removeAll()},e.prototype.incrementalRender=function(t,e,n,i){var r=e.coordinateSystem;r&&(ym(r)?this.render(e,n,i):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(e,i,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){ne["traverseElements"](this._progressiveEls||this.group,t)},e.prototype._renderOnCartesianAndCalendar=function(t,e,n,i,r){var a,o,s,l,u=t.coordinateSystem,c=Ge(u,"cartesian2d");if(c){var h=u.getAxis("x"),d=u.getAxis("y");0,a=h.getBandWidth()+.5,o=d.getBandWidth()+.5,s=h.scale.getExtent(),l=d.scale.getExtent()}for(var f=this.group,p=t.getData(),g=t.getModel(["emphasis","itemStyle"]).getItemStyle(),m=t.getModel(["blur","itemStyle"]).getItemStyle(),v=t.getModel(["select","itemStyle"]).getItemStyle(),y=t.get(["itemStyle","borderRadius"]),_=Object(le["e"])(t),b=t.getModel("emphasis"),x=b.get("focus"),w=b.get("blurScope"),O=b.get("disabled"),S=c?[p.mapDimension("x"),p.mapDimension("y"),p.mapDimension("value")]:[p.mapDimension("time"),p.mapDimension("value")],T=n;Ts[1]||Il[1])continue;var D=u.dataToPoint([C,I]);M=new Re["a"]({shape:{x:D[0]-a/2,y:D[1]-o/2,width:a,height:o},style:A})}else{if(isNaN(p.get(S[1],T)))continue;M=new Re["a"]({z2:1,shape:u.dataToRect([p.get(S[0],T)]).contentShape,style:A})}if(p.hasItemOption){var L=p.getItemModel(T),E=L.getModel("emphasis");g=E.getModel("itemStyle").getItemStyle(),m=L.getModel(["blur","itemStyle"]).getItemStyle(),v=L.getModel(["select","itemStyle"]).getItemStyle(),y=L.get(["itemStyle","borderRadius"]),x=E.get("focus"),w=E.get("blurScope"),O=E.get("disabled"),_=Object(le["e"])(L)}M.shape.r=y;var j=t.getRawValue(T),P="-";j&&null!=j[2]&&(P=j[2]+""),Object(le["g"])(M,_,{labelFetcher:t,labelDataIndex:T,defaultOpacity:A.opacity,defaultText:P}),M.ensureState("emphasis").style=g,M.ensureState("blur").style=m,M.ensureState("select").style=v,Object(re["J"])(M,x,w,O),M.incremental=r,r&&(M.states.emphasis.hoverLayer=!0),f.add(M),p.setItemGraphicEl(T,M),this._progressiveEls&&this._progressiveEls.push(M)}},e.prototype._renderOnGeo=function(t,e,n,i){var r=n.targetVisuals.inRange,a=n.targetVisuals.outOfRange,o=e.getData(),s=this._hmLayer||this._hmLayer||new gm;s.blurSize=e.get("blurSize"),s.pointSize=e.get("pointSize"),s.minOpacity=e.get("minOpacity"),s.maxOpacity=e.get("maxOpacity");var u=t.getViewRect().clone(),c=t.getRoamTransform();u.applyTransform(c);var h=Math.max(u.x,0),d=Math.max(u.y,0),f=Math.min(u.width+u.x,i.getWidth()),p=Math.min(u.height+u.y,i.getHeight()),g=f-h,m=p-d,v=[o.mapDimension("lng"),o.mapDimension("lat"),o.mapDimension("value")],y=o.mapArray(v,(function(e,n,i){var r=t.dataToPoint([e,n]);return r[0]-=h,r[1]-=d,r.push(i),r})),_=n.getExtent(),b="visualMap.continuous"===n.type?vm(_,n.option.range):mm(_,n.getPieceList(),n.option.selected);s.update(y,g,m,r.color.getNormalizer(),{inRange:r.color.getColorMapper(),outOfRange:a.color.getColorMapper()},b);var x=new l["a"]({style:{width:g,height:m,x:h,y:d,image:s.canvas},silent:!0});this.group.add(x)},e.type="heatmap",e}(Ne["a"]),bm=_m,xm=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t,e){return Object(Yt["a"])(null,this,{generateCoord:"value"})},e.prototype.preventIncremental=function(){var t=Ch["a"].get(this.get("coordinateSystem"));if(t&&t.dimensions)return"lng"===t.dimensions[0]&&"lat"===t.dimensions[1]},e.type="series.heatmap",e.dependencies=["grid","geo","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:"#212121"}}},e}(Kt["b"]),wm=xm;function Om(t){t.registerChartView(bm),t.registerSeriesModel(wm)}var Sm=["itemStyle","borderWidth"],Tm=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],Mm=new ja["a"],Am=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=this.group,r=t.getData(),a=this._data,o=t.coordinateSystem,s=o.getBaseAxis(),l=s.isHorizontal(),u=o.master.getRect(),c={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:t,coordSys:o,coordSysExtent:[[u.x,u.x+u.width],[u.y,u.y+u.height]],isHorizontal:l,valueDim:Tm[+l],categoryDim:Tm[1-+l]};return r.diff(a).add((function(t){if(r.hasValue(t)){var e=zm(r,t),n=Cm(r,t,e,c),a=Gm(r,c,n);r.setItemGraphicEl(t,a),i.add(a),qm(a,c,n)}})).update((function(t,e){var n=a.getItemGraphicEl(e);if(r.hasValue(t)){var o=zm(r,t),s=Cm(r,t,o,c),l=Wm(r,s);n&&l!==n.__pictorialShapeStr&&(i.remove(n),r.setItemGraphicEl(t,null),n=null),n?Hm(n,c,s):n=Gm(r,c,s,!0),r.setItemGraphicEl(t,n),n.__pictorialSymbolMeta=s,i.add(n),qm(n,c,s)}else i.remove(n)})).remove((function(t){var e=a.getItemGraphicEl(t);e&&Um(a,t,e.__pictorialSymbolMeta.animationModel,e)})).execute(),this._data=r,this.group},e.prototype.remove=function(t,e){var n=this.group,i=this._data;t.get("animation")?i&&i.eachItemGraphicEl((function(e){Um(i,Object(ie["a"])(e).dataIndex,t,e)})):n.removeAll()},e.type="pictorialBar",e}(Ne["a"]);function Cm(t,e,n,i){var r=t.getItemLayout(e),a=n.get("symbolRepeat"),o=n.get("symbolClip"),s=n.get("symbolPosition")||"start",l=n.get("symbolRotate"),u=(l||0)*Math.PI/180||0,c=n.get("symbolPatternSize")||2,h=n.isAnimationEnabled(),d={dataIndex:e,layout:r,itemModel:n,symbolType:t.getItemVisual(e,"symbol")||"circle",style:t.getItemVisual(e,"style"),symbolClip:o,symbolRepeat:a,symbolRepeatDirection:n.get("symbolRepeatDirection"),symbolPatternSize:c,rotation:u,animationModel:h?n:null,hoverScale:h&&n.get(["emphasis","scale"]),z2:n.getShallow("z",!0)||0};Im(n,a,r,i,d),Lm(t,e,r,a,o,d.boundingLength,d.pxSign,c,i,d),Em(n,d.symbolScale,u,i,d);var f=d.symbolSize,p=Object(Qt["b"])(n.get("symbolOffset"),f);return jm(n,f,r,a,o,p,s,d.valueLineWidth,d.boundingLength,d.repeatCutLength,i,d),d}function Im(t,e,n,i,r){var a,o=i.valueDim,s=t.get("symbolBoundingData"),l=i.coordSys.getOtherAxis(i.coordSys.getBaseAxis()),u=l.toGlobalCoord(l.dataToCoord(0)),c=1-+(n[o.wh]<=0);if(_["t"](s)){var h=[Dm(l,s[0])-u,Dm(l,s[1])-u];h[1]0?1:-1}function Dm(t,e){return t.toGlobalCoord(t.dataToCoord(t.scale.parse(e)))}function Lm(t,e,n,i,r,a,o,s,l,u){var c,h=l.valueDim,d=l.categoryDim,f=Math.abs(n[d.wh]),p=t.getItemVisual(e,"symbolSize");c=_["t"](p)?p.slice():null==p?["100%","100%"]:[p,p],c[d.index]=Object(Be["p"])(c[d.index],f),c[h.index]=Object(Be["p"])(c[h.index],i?f:Math.abs(a)),u.symbolSize=c;var g=u.symbolScale=[c[0]/s,c[1]/s];g[h.index]*=(l.isHorizontal?-1:1)*o}function Em(t,e,n,i,r){var a=t.get(Sm)||0;a&&(Mm.attr({scaleX:e[0],scaleY:e[1],rotation:n}),Mm.updateTransform(),a/=Mm.getLineScale(),a*=e[i.valueDim.index]),r.valueLineWidth=a||0}function jm(t,e,n,i,r,a,o,s,l,u,c,h){var d=c.categoryDim,f=c.valueDim,p=h.pxSign,g=Math.max(e[f.index]+s,0),m=g;if(i){var v=Math.abs(l),y=_["O"](t.get("symbolMargin"),"15%")+"",b=!1;y.lastIndexOf("!")===y.length-1&&(b=!0,y=y.slice(0,y.length-1));var x=Object(Be["p"])(y,e[f.index]),w=Math.max(g+2*x,0),O=b?0:2*x,S=Object(Be["j"])(i),T=S?i:Ym((v+O)/w),M=v-T*g;x=M/2/(b?T:Math.max(T-1,1)),w=g+2*x,O=b?0:2*x,S||"fixed"===i||(T=u?Ym((Math.abs(u)+O)/w):0),m=T*w-O,h.repeatTimes=T,h.symbolMargin=x}var A=p*(m/2),C=h.pathPosition=[];C[d.index]=n[d.wh]/2,C[f.index]="start"===o?A:"end"===o?l-A:l/2,a&&(C[0]+=a[0],C[1]+=a[1]);var I=h.bundlePosition=[];I[d.index]=n[d.xy],I[f.index]=n[f.xy];var D=h.barRectShape=_["m"]({},n);D[f.wh]=p*Math.max(Math.abs(n[f.wh]),Math.abs(C[f.index]+A)),D[d.wh]=n[d.wh];var L=h.clipShape={};L[d.xy]=-n[d.xy],L[d.wh]=c.ecSize[d.wh],L[f.xy]=0,L[f.wh]=n[f.wh]}function Pm(t){var e=t.symbolPatternSize,n=Object(Qt["a"])(t.symbolType,-e/2,-e/2,e,e);return n.attr({culling:!0}),"image"!==n.type&&n.setStyle({strokeNoScale:!0}),n}function Nm(t,e,n,i){var r=t.__pictorialBundle,a=n.symbolSize,o=n.valueLineWidth,s=n.pathPosition,l=e.valueDim,u=n.repeatTimes||0,c=0,h=a[e.valueDim.index]+o+2*n.symbolMargin;for(Xm(t,(function(t){t.__pictorialAnimationIndex=c,t.__pictorialRepeatTimes=u,c0:i<0)&&(r=u-1-t),e[l.index]=h*(r-u/2+.5)+s[l.index],{x:e[0],y:e[1],scaleX:n.symbolScale[0],scaleY:n.symbolScale[1],rotation:n.rotation}}}function Rm(t,e,n,i){var r=t.__pictorialBundle,a=t.__pictorialMainPath;a?Zm(a,null,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:n.symbolScale[0],scaleY:n.symbolScale[1],rotation:n.rotation},n,i):(a=t.__pictorialMainPath=Pm(n),r.add(a),Zm(a,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:0,scaleY:0,rotation:n.rotation},{scaleX:n.symbolScale[0],scaleY:n.symbolScale[1]},n,i))}function km(t,e,n){var i=_["m"]({},e.barRectShape),r=t.__pictorialBarRect;r?Zm(r,null,{shape:i},e,n):(r=t.__pictorialBarRect=new Re["a"]({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),r.disableMorphing=!0,t.add(r))}function Bm(t,e,n,i){if(n.symbolClip){var r=t.__pictorialClipPath,a=_["m"]({},n.clipShape),o=e.valueDim,s=n.animationModel,l=n.dataIndex;if(r)ee["h"](r,{shape:a},s,l);else{a[o.wh]=0,r=new Re["a"]({shape:a}),t.__pictorialBundle.setClipPath(r),t.__pictorialClipPath=r;var u={};u[o.wh]=n.clipShape[o.wh],ne[i?"updateProps":"initProps"](r,{shape:u},s,l)}}}function zm(t,e){var n=t.getItemModel(e);return n.getAnimationDelayParams=Vm,n.isAnimationEnabled=Fm,n}function Vm(t){return{index:t.__pictorialAnimationIndex,count:t.__pictorialRepeatTimes}}function Fm(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function Gm(t,e,n,i){var r=new Jt["a"],a=new Jt["a"];return r.add(a),r.__pictorialBundle=a,a.x=n.bundlePosition[0],a.y=n.bundlePosition[1],n.symbolRepeat?Nm(r,e,n):Rm(r,e,n),km(r,n,i),Bm(r,e,n,i),r.__pictorialShapeStr=Wm(t,n),r.__pictorialSymbolMeta=n,r}function Hm(t,e,n){var i=n.animationModel,r=n.dataIndex,a=t.__pictorialBundle;ee["h"](a,{x:n.bundlePosition[0],y:n.bundlePosition[1]},i,r),n.symbolRepeat?Nm(t,e,n,!0):Rm(t,e,n,!0),km(t,n,!0),Bm(t,e,n,!0)}function Um(t,e,n,i){var r=i.__pictorialBarRect;r&&r.removeTextContent();var a=[];Xm(i,(function(t){a.push(t)})),i.__pictorialMainPath&&a.push(i.__pictorialMainPath),i.__pictorialClipPath&&(n=null),_["k"](a,(function(t){ee["e"](t,{scaleX:0,scaleY:0},n,e,(function(){i.parent&&i.parent.remove(i)}))})),t.setItemGraphicEl(e,null)}function Wm(t,e){return[t.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function Xm(t,e,n){_["k"](t.__pictorialBundle.children(),(function(i){i!==t.__pictorialBarRect&&e.call(n,i)}))}function Zm(t,e,n,i,r,a){e&&t.attr(e),i.symbolClip&&!r?n&&t.attr(n):n&&ne[r?"updateProps":"initProps"](t,n,i.animationModel,i.dataIndex,a)}function qm(t,e,n){var i=n.dataIndex,r=n.itemModel,a=r.getModel("emphasis"),o=a.getModel("itemStyle").getItemStyle(),s=r.getModel(["blur","itemStyle"]).getItemStyle(),u=r.getModel(["select","itemStyle"]).getItemStyle(),c=r.getShallow("cursor"),h=a.get("focus"),d=a.get("blurScope"),f=a.get("scale");Xm(t,(function(t){if(t instanceof l["a"]){var e=t.style;t.useStyle(_["m"]({image:e.image,x:e.x,y:e.y,width:e.width,height:e.height},n.style))}else t.useStyle(n.style);var i=t.ensureState("emphasis");i.style=o,f&&(i.scaleX=1.1*t.scaleX,i.scaleY=1.1*t.scaleY),t.ensureState("blur").style=s,t.ensureState("select").style=u,c&&(t.cursor=c),t.z2=n.z2}));var p=e.valueDim.posDesc[+(n.boundingLength>0)],g=t.__pictorialBarRect;Object(le["g"])(g,Object(le["e"])(r),{labelFetcher:e.seriesModel,labelDataIndex:i,defaultText:oe(e.seriesModel.getData(),i),inheritColor:n.style.fill,defaultOpacity:n.style.opacity,defaultOutsidePosition:p}),Object(re["J"])(t,h,d,a.get("disabled"))}function Ym(t){var e=Math.round(t);return Math.abs(t-e)<1e-4?e:Math.ceil(t)}var Km=Am,Qm=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.hasSymbolVisual=!0,n.defaultSymbol="roundRect",n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(e){return e.stack=null,t.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=Object(bn["d"])(_n.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),e}(_n),Jm=Qm;function $m(t){t.registerChartView(Km),t.registerSeriesModel(Jm),t.registerLayout(t.PRIORITY.VISUAL.LAYOUT,Object(_["h"])(vn["c"],"pictorialBar")),t.registerLayout(t.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,Object(vn["a"])("pictorialBar"))}var tv=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._layers=[],n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=t.getData(),r=this,a=this.group,o=t.getLayerSeries(),s=i.getLayout("layoutInfo"),l=s.rect,u=s.boundaryGap;function c(t){return t.name}a.x=0,a.y=l.y+u[0];var h=new Ql["a"](this._layersSeries||[],o,c,c),d=[];function f(e,n,s){var l=r._layers;if("remove"!==e){for(var u,c,h=[],f=[],p=o[n].indices,g=0;ga&&(a=s),i.push(s)}for(var u=0;ua&&(a=h)}return{y0:r,max:a}}function uv(t){t.registerChartView(nv),t.registerSeriesModel(av),t.registerLayout(ov),t.registerProcessor(ci("themeRiver"))}var cv=2,hv=4,dv=function(t){function e(e,n,i,r){var a=t.call(this)||this;a.z2=cv,a.textConfig={inside:!0},Object(ie["a"])(a).seriesIndex=n.seriesIndex;var o=new $["a"]({z2:hv,silent:e.getModel().get(["label","silent"])});return a.setTextContent(o),a.updateData(!0,e,n,i,r),a}return Object(qt["a"])(e,t),e.prototype.updateData=function(t,e,n,i,r){this.node=e,e.piece=this,n=n||this._seriesModel,i=i||this._ecModel;var a=this;Object(ie["a"])(a).dataIndex=e.dataIndex;var o=e.getModel(),s=o.getModel("emphasis"),l=e.getLayout(),u=_["m"]({},l);u.label=null;var c=e.getVisual("style");c.lineJoin="bevel";var h=e.getVisual("decal");h&&(c.decal=Object(as["a"])(h,r));var d=xi(o.getModel("itemStyle"),u,!0);_["m"](u,d),_["k"](re["g"],(function(t){var e=a.ensureState(t),n=o.getModel([t,"itemStyle"]);e.style=n.getItemStyle();var i=xi(n,u);i&&(e.shape=i)})),t?(a.setShape(u),a.shape.r=l.r0,ee["h"](a,{shape:{r:l.r}},n,e.dataIndex)):(ee["h"](a,{shape:u},n),Object(ee["g"])(a)),a.useStyle(c),this._updateLabel(n);var f=o.getShallow("cursor");f&&a.attr("cursor",f),this._seriesModel=n||this._seriesModel,this._ecModel=i||this._ecModel;var p=s.get("focus"),g="ancestor"===p?e.getAncestorsIndices():"descendant"===p?e.getDescendantIndices():p;Object(re["J"])(this,g,s.get("blurScope"),s.get("disabled"))},e.prototype._updateLabel=function(t){var e=this,n=this.node.getModel(),i=n.getModel("label"),r=this.node.getLayout(),a=r.endAngle-r.startAngle,o=(r.startAngle+r.endAngle)/2,s=Math.cos(o),l=Math.sin(o),u=this,c=u.getTextContent(),h=this.node.dataIndex,d=i.get("minAngle")/180*Math.PI,f=i.get("show")&&!(null!=d&&Math.abs(a)Math.PI/2?"right":"left"):S&&"center"!==S?"left"===S?(y=r.r0+O,o>Math.PI/2&&(S="right")):"right"===S&&(y=r.r-O,o>Math.PI/2&&(S="left")):(y=a===2*Math.PI&&0===r.r0?0:(r.r+r.r0)/2,S="center"),g.style.align=S,g.style.verticalAlign=p(d,"verticalAlign")||"middle",g.x=y*s+r.cx,g.y=y*l+r.cy;var T=p(d,"rotate"),M=0;"radial"===T?(M=-o,M<-Math.PI/2&&(M+=Math.PI)):"tangential"===T?(M=Math.PI/2-o,M>Math.PI/2?M-=Math.PI:M<-Math.PI/2&&(M+=Math.PI)):_["z"](T)&&(M=T*Math.PI/180),g.rotation=M})),c.dirtyStyle()},e}(ke["a"]),fv=dv,pv="sunburstRootToNode",gv="sunburstHighlight",mv="sunburstUnhighlight";function vv(t){t.registerAction({type:pv,update:"updateView"},(function(t,e){function n(e,n){var i=Dl(t,[pv],e);if(i){var r=e.getViewRoot();r&&(t.direction=El(r,i.node)?"rollUp":"drillDown"),e.resetViewRoot(i.node)}}e.eachComponent({mainType:"series",subType:"sunburst",query:t},n)})),t.registerAction({type:gv,update:"none"},(function(t,e,n){function i(e){var n=Dl(t,[gv],e);n&&(t.dataIndex=n.node.dataIndex)}t=Object(_["m"])({},t),e.eachComponent({mainType:"series",subType:"sunburst",query:t},i),n.dispatchAction(Object(_["m"])(t,{type:"highlight"}))})),t.registerAction({type:mv,update:"updateView"},(function(t,e,n){t=Object(_["m"])({},t),n.dispatchAction(Object(_["m"])(t,{type:"downplay"}))}))}var yv=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n,i){var r=this;this.seriesModel=t,this.api=n,this.ecModel=e;var a=t.getData(),o=a.tree.root,s=t.getViewRoot(),l=this.group,u=t.get("renderLabelForZeroData"),c=[];s.eachNode((function(t){c.push(t)}));var h=this._oldChildren||[];function d(t,e){function n(t){return t.getId()}function i(n,i){var r=null==n?null:t[n],a=null==i?null:e[i];f(r,a)}0===t.length&&0===e.length||new Ql["a"](e,t,n,n).add(i).update(i).remove(_["h"](i,null)).execute()}function f(i,r){if(u||!i||i.getValue()||(i=null),i!==o&&r!==o)if(r&&r.piece)i?(r.piece.updateData(!1,i,t,e,n),a.setItemGraphicEl(i.dataIndex,r.piece)):p(r);else if(i){var s=new fv(i,t,e,n);l.add(s),a.setItemGraphicEl(i.dataIndex,s)}}function p(t){t&&t.piece&&(l.remove(t.piece),t.piece=null)}function g(i,a){a.depth>0?(r.virtualPiece?r.virtualPiece.updateData(!1,i,t,e,n):(r.virtualPiece=new fv(i,t,e,n),l.add(r.virtualPiece)),a.piece.off("click"),r.virtualPiece.on("click",(function(t){r._rootToNode(a.parentNode)}))):r.virtualPiece&&(l.remove(r.virtualPiece),r.virtualPiece=null)}d(c,h),g(o,s),this._initEvents(),this._oldChildren=c},e.prototype._initEvents=function(){var t=this;this.group.off("click"),this.group.on("click",(function(e){var n=!1,i=t.seriesModel.getViewRoot();i.eachNode((function(i){if(!n&&i.piece&&i.piece===e.target){var r=i.getModel().get("nodeClick");if("rootToNode"===r)t._rootToNode(i);else if("link"===r){var a=i.getModel(),o=a.get("link");if(o){var s=a.get("target",!0)||"_blank";Object(He["l"])(o,s)}}n=!0}}))}))},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:pv,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},e.prototype.containPoint=function(t,e){var n=e.getData(),i=n.getItemLayout(0);if(i){var r=t[0]-i.cx,a=t[1]-i.cy,o=Math.sqrt(r*r+a*a);return o<=i.r&&o>=i.r0}},e.type="sunburst",e}(Ne["a"]),_v=yv,bv=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.ignoreStyleOnData=!0,n}return Object(qt["a"])(e,t),e.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data};xv(n);var i=this._levelModels=_["H"](t.levels||[],(function(t){return new Er["a"](t,this,e)}),this),r=Il.createTree(n,this,a);function a(t){t.wrapMethod("getItemModel",(function(t,e){var n=r.getNodeByDataIndex(e),a=i[n.depth];return a&&(t.parentModel=a),t}))}return r.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.getDataParams=function(e){var n=t.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(e);return n.treePathInfo=jl(i,this),n},e.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var e=this.getRawData().tree.root;t&&(t===e||e.contains(t))||(this._viewRoot=e)},e.prototype.enableAriaDecal=function(){Xl(this)},e.type="series.sunburst",e.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},e}(Kt["b"]);function xv(t){var e=0;_["k"](t.children,(function(t){xv(t);var n=t.value;_["t"](n)&&(n=n[0]),e+=n}));var n=t.value;_["t"](n)&&(n=n[0]),(null==n||isNaN(n))&&(n=e),n<0&&(n=0),_["t"](t.value)?t.value[0]=n:t.value=n}var wv=bv,Ov=Math.PI/180;function Sv(t,e,n){e.eachSeriesByType(t,(function(t){var e=t.get("center"),i=t.get("radius");_["t"](i)||(i=[0,i]),_["t"](e)||(e=[e,e]);var r=n.getWidth(),a=n.getHeight(),o=Math.min(r,a),s=Object(Be["p"])(e[0],r),l=Object(Be["p"])(e[1],a),u=Object(Be["p"])(i[0],o/2),c=Object(Be["p"])(i[1],o/2),h=-t.get("startAngle")*Ov,d=t.get("minAngle")*Ov,f=t.getData().tree.root,p=t.getViewRoot(),g=p.depth,m=t.get("sort");null!=m&&Tv(p,m);var v=0;_["k"](p.children,(function(t){!isNaN(t.getValue())&&v++}));var y=p.getValue(),b=Math.PI/(y||v)*2,x=p.depth>0,w=p.height-(x?-1:1),O=(c-u)/(w||1),S=t.get("clockwise"),T=t.get("stillShowZeroSum"),M=S?1:-1,A=function(e,n){if(e){var i=n;if(e!==f){var r=e.getValue(),a=0===y&&T?b:r*b;a1)r=r.parentNode;var a=n.getColorFromPalette(r.name||r.dataIndex+"",e);return t.depth>1&&Object(_["C"])(a)&&(a=Object(Ue["lift"])(a,(t.depth-1)/(i-1)*.5)),a}t.eachSeriesByType("sunburst",(function(t){var e=t.getData(),i=e.tree;i.eachNode((function(r){var a=r.getModel(),o=a.getModel("itemStyle").getItemStyle();o.fill||(o.fill=n(r,t,i.root.height));var s=e.ensureUniqueItemVisual(r.dataIndex,"style");Object(_["m"])(s,o)}))}))}function Cv(t){t.registerChartView(_v),t.registerSeriesModel(wv),t.registerLayout(Object(_["h"])(Sv,"sunburst")),t.registerProcessor(Object(_["h"])(ci,"sunburst")),t.registerVisual(Av),vv(t)}var Iv={color:"fill",borderColor:"stroke"},Dv={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},Lv=Object(Te["o"])(),Ev=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},e.prototype.getInitialData=function(t,e){return Object(Yt["a"])(null,this)},e.prototype.getDataParams=function(e,n,i){var r=t.prototype.getDataParams.call(this,e,n);return i&&(r.info=Lv(i).info),r},e.type="series.custom",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},e}(Kt["b"]),jv=Ev;function Pv(t,e){return e=e||[0,0],_["H"](["x","y"],(function(n,i){var r=this.getAxis(n),a=e[i],o=t[i]/2;return"category"===r.type?r.getBandWidth():Math.abs(r.dataToCoord(a-o)-r.dataToCoord(a+o))}),this)}function Nv(t){var e=t.master.getRect();return{coordSys:{type:"cartesian2d",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(e){return t.dataToPoint(e)},size:_["c"](Pv,t)}}}function Rv(t,e){return e=e||[0,0],_["H"]([0,1],(function(n){var i=e[n],r=t[n]/2,a=[],o=[];return a[n]=i-r,o[n]=i+r,a[1-n]=o[1-n]=e[1-n],Math.abs(this.dataToPoint(a)[n]-this.dataToPoint(o)[n])}),this)}function kv(t){var e=t.getBoundingRect();return{coordSys:{type:"geo",x:e.x,y:e.y,width:e.width,height:e.height,zoom:t.getZoom()},api:{coord:function(e){return t.dataToPoint(e)},size:_["c"](Rv,t)}}}function Bv(t,e){var n=this.getAxis(),i=e instanceof Array?e[0]:e,r=(t instanceof Array?t[0]:t)/2;return"category"===n.type?n.getBandWidth():Math.abs(n.dataToCoord(i-r)-n.dataToCoord(i+r))}function zv(t){var e=t.getRect();return{coordSys:{type:"singleAxis",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(e){return t.dataToPoint(e)},size:Object(_["c"])(Bv,t)}}}function Vv(t,e){return e=e||[0,0],_["H"](["Radius","Angle"],(function(n,i){var r="get"+n+"Axis",a=this[r](),o=e[i],s=t[i]/2,l="category"===a.type?a.getBandWidth():Math.abs(a.dataToCoord(o-s)-a.dataToCoord(o+s));return"Angle"===n&&(l=l*Math.PI/180),l}),this)}function Fv(t){var e=t.getRadiusAxis(),n=t.getAngleAxis(),i=e.getExtent();return i[0]>i[1]&&i.reverse(),{coordSys:{type:"polar",cx:t.cx,cy:t.cy,r:i[1],r0:i[0]},api:{coord:function(i){var r=e.dataToRadius(i[0]),a=n.dataToAngle(i[1]),o=t.coordToPoint([r,a]);return o.push(r,a*Math.PI/180),o},size:_["c"](Vv,t)}}}function Gv(t){var e=t.getRect(),n=t.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:t.getCellWidth(),cellHeight:t.getCellHeight(),rangeInfo:{start:n.start,end:n.end,weeks:n.weeks,dayCount:n.allDay}},api:{coord:function(e,n){return t.dataToPoint(e,n)}}}}function Hv(t,e,n,i){return t&&(t.legacy||!1!==t.legacy&&!n&&!i&&"tspan"!==e&&("text"===e||Object(_["q"])(t,"text")))}function Uv(t,e,n){var i,r,a,o=t;if("text"===e)a=o;else{a={},Object(_["q"])(o,"text")&&(a.text=o.text),Object(_["q"])(o,"rich")&&(a.rich=o.rich),Object(_["q"])(o,"textFill")&&(a.fill=o.textFill),Object(_["q"])(o,"textStroke")&&(a.stroke=o.textStroke),Object(_["q"])(o,"fontFamily")&&(a.fontFamily=o.fontFamily),Object(_["q"])(o,"fontSize")&&(a.fontSize=o.fontSize),Object(_["q"])(o,"fontStyle")&&(a.fontStyle=o.fontStyle),Object(_["q"])(o,"fontWeight")&&(a.fontWeight=o.fontWeight),r={type:"text",style:a,silent:!0},i={};var s=Object(_["q"])(o,"textPosition");n?i.position=s?o.textPosition:"inside":s&&(i.position=o.textPosition),Object(_["q"])(o,"textPosition")&&(i.position=o.textPosition),Object(_["q"])(o,"textOffset")&&(i.offset=o.textOffset),Object(_["q"])(o,"textRotation")&&(i.rotation=o.textRotation),Object(_["q"])(o,"textDistance")&&(i.distance=o.textDistance)}return Wv(a,t),Object(_["k"])(a.rich,(function(t){Wv(t,t)})),{textConfig:i,textContent:r}}function Wv(t,e){e&&(e.font=e.textFont||e.font,Object(_["q"])(e,"textStrokeWidth")&&(t.lineWidth=e.textStrokeWidth),Object(_["q"])(e,"textAlign")&&(t.align=e.textAlign),Object(_["q"])(e,"textVerticalAlign")&&(t.verticalAlign=e.textVerticalAlign),Object(_["q"])(e,"textLineHeight")&&(t.lineHeight=e.textLineHeight),Object(_["q"])(e,"textWidth")&&(t.width=e.textWidth),Object(_["q"])(e,"textHeight")&&(t.height=e.textHeight),Object(_["q"])(e,"textBackgroundColor")&&(t.backgroundColor=e.textBackgroundColor),Object(_["q"])(e,"textPadding")&&(t.padding=e.textPadding),Object(_["q"])(e,"textBorderColor")&&(t.borderColor=e.textBorderColor),Object(_["q"])(e,"textBorderWidth")&&(t.borderWidth=e.textBorderWidth),Object(_["q"])(e,"textBorderRadius")&&(t.borderRadius=e.textBorderRadius),Object(_["q"])(e,"textBoxShadowColor")&&(t.shadowColor=e.textBoxShadowColor),Object(_["q"])(e,"textBoxShadowBlur")&&(t.shadowBlur=e.textBoxShadowBlur),Object(_["q"])(e,"textBoxShadowOffsetX")&&(t.shadowOffsetX=e.textBoxShadowOffsetX),Object(_["q"])(e,"textBoxShadowOffsetY")&&(t.shadowOffsetY=e.textBoxShadowOffsetY))}function Xv(t,e,n){var i=t;i.textPosition=i.textPosition||n.position||"inside",null!=n.offset&&(i.textOffset=n.offset),null!=n.rotation&&(i.textRotation=n.rotation),null!=n.distance&&(i.textDistance=n.distance);var r=i.textPosition.indexOf("inside")>=0,a=t.fill||"#000";Zv(i,e);var o=null==i.textFill;return r?o&&(i.textFill=n.insideFill||"#fff",!i.textStroke&&n.insideStroke&&(i.textStroke=n.insideStroke),!i.textStroke&&(i.textStroke=a),null==i.textStrokeWidth&&(i.textStrokeWidth=2)):(o&&(i.textFill=t.fill||n.outsideFill||"#000"),!i.textStroke&&n.outsideStroke&&(i.textStroke=n.outsideStroke)),i.text=e.text,i.rich=e.rich,Object(_["k"])(e.rich,(function(t){Zv(t,t)})),i}function Zv(t,e){e&&(Object(_["q"])(e,"fill")&&(t.textFill=e.fill),Object(_["q"])(e,"stroke")&&(t.textStroke=e.fill),Object(_["q"])(e,"lineWidth")&&(t.textStrokeWidth=e.lineWidth),Object(_["q"])(e,"font")&&(t.font=e.font),Object(_["q"])(e,"fontStyle")&&(t.fontStyle=e.fontStyle),Object(_["q"])(e,"fontWeight")&&(t.fontWeight=e.fontWeight),Object(_["q"])(e,"fontSize")&&(t.fontSize=e.fontSize),Object(_["q"])(e,"fontFamily")&&(t.fontFamily=e.fontFamily),Object(_["q"])(e,"align")&&(t.textAlign=e.align),Object(_["q"])(e,"verticalAlign")&&(t.textVerticalAlign=e.verticalAlign),Object(_["q"])(e,"lineHeight")&&(t.textLineHeight=e.lineHeight),Object(_["q"])(e,"width")&&(t.textWidth=e.width),Object(_["q"])(e,"height")&&(t.textHeight=e.height),Object(_["q"])(e,"backgroundColor")&&(t.textBackgroundColor=e.backgroundColor),Object(_["q"])(e,"padding")&&(t.textPadding=e.padding),Object(_["q"])(e,"borderColor")&&(t.textBorderColor=e.borderColor),Object(_["q"])(e,"borderWidth")&&(t.textBorderWidth=e.borderWidth),Object(_["q"])(e,"borderRadius")&&(t.textBorderRadius=e.borderRadius),Object(_["q"])(e,"shadowColor")&&(t.textBoxShadowColor=e.shadowColor),Object(_["q"])(e,"shadowBlur")&&(t.textBoxShadowBlur=e.shadowBlur),Object(_["q"])(e,"shadowOffsetX")&&(t.textBoxShadowOffsetX=e.shadowOffsetX),Object(_["q"])(e,"shadowOffsetY")&&(t.textBoxShadowOffsetY=e.shadowOffsetY),Object(_["q"])(e,"textShadowColor")&&(t.textShadowColor=e.textShadowColor),Object(_["q"])(e,"textShadowBlur")&&(t.textShadowBlur=e.textShadowBlur),Object(_["q"])(e,"textShadowOffsetX")&&(t.textShadowOffsetX=e.textShadowOffsetX),Object(_["q"])(e,"textShadowOffsetY")&&(t.textShadowOffsetY=e.textShadowOffsetY))}var qv=n("06ad"),Yv={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},Kv=Object(_["F"])(Yv),Qv=(Object(_["N"])(V["a"],(function(t,e){return t[e]=1,t}),{}),V["a"].join(", "),["","style","shape","extra"]),Jv=Object(Te["o"])();function $v(t,e,n,i,r){var a=t+"Animation",o=Object(ee["a"])(t,i,r)||{},s=Jv(e).userDuring;return o.duration>0&&(o.during=s?Object(_["c"])(uy,{el:e,userDuring:s}):null,o.setToFinal=!0,o.scope=t),Object(_["m"])(o,n[a]),o}function ty(t,e,n,i){i=i||{};var r=i.dataIndex,a=i.isInit,o=i.clearStyle,s=n.isAnimationEnabled(),l=Jv(t),u=e.style;l.userDuring=e.during;var c={},h={};if(fy(t,e,h),hy("shape",e,h),hy("extra",e,h),!a&&s&&(dy(t,e,c),cy("shape",t,e,c),cy("extra",t,e,c),py(t,e,u,c)),h.style=u,ry(t,h,o),oy(t,e),s)if(a){var d={};Object(_["k"])(Qv,(function(t){var n=t?e[t]:e;n&&n.enterFrom&&(t&&(d[t]=d[t]||{}),Object(_["m"])(t?d[t]:d,n.enterFrom))}));var f=$v("enter",t,e,n,r);f.duration>0&&t.animateFrom(d,f)}else ay(t,e,r||0,n,c);ey(t,e),u?t.dirty():t.markRedraw()}function ey(t,e){for(var n=Jv(t).leaveToProps,i=0;i0&&t.animateFrom(r,a)}}function oy(t,e){Object(_["q"])(e,"silent")&&(t.silent=e.silent),Object(_["q"])(e,"ignore")&&(t.ignore=e.ignore),t instanceof os["c"]&&Object(_["q"])(e,"invisible")&&(t.invisible=e.invisible),t instanceof s["b"]&&Object(_["q"])(e,"autoBatch")&&(t.autoBatch=e.autoBatch)}var sy={},ly={setTransform:function(t,e){return sy.el[t]=e,this},getTransform:function(t){return sy.el[t]},setShape:function(t,e){var n=sy.el,i=n.shape||(n.shape={});return i[t]=e,n.dirtyShape&&n.dirtyShape(),this},getShape:function(t){var e=sy.el.shape;if(e)return e[t]},setStyle:function(t,e){var n=sy.el,i=n.style;return i&&(i[t]=e,n.dirtyStyle&&n.dirtyStyle()),this},getStyle:function(t){var e=sy.el.style;if(e)return e[t]},setExtra:function(t,e){var n=sy.el.extra||(sy.el.extra={});return n[t]=e,this},getExtra:function(t){var e=sy.el.extra;if(e)return e[t]}};function uy(){var t=this,e=t.el;if(e){var n=Jv(e).userDuring,i=t.userDuring;n===i?(sy.el=e,i(ly)):t.el=t.userDuring=null}}function cy(t,e,n,i){var r=n[t];if(r){var a,o=e[t];if(o){var s=n.transition,l=r.transition;if(l)if(!a&&(a=i[t]={}),iy(l))Object(_["m"])(a,o);else for(var u=Object(Te["r"])(l),c=0;c=0){!a&&(a=i[t]={});var f=Object(_["F"])(o);for(c=0;c=0)){var d=t.getAnimationStyleProps(),f=d?d.style:null;if(f){!r&&(r=i.style={});var p=Object(_["F"])(n);for(u=0;u=0?e.getStore().get(r,n):void 0}var a=e.get(i.name,n),o=i&&i.ordinalMeta;return o?o.categories[a]:a}function O(n,i){null==i&&(i=s);var r=e.getItemVisual(i,"style"),a=r&&r.fill,o=r&&r.opacity,l=y(i,xy).getItemStyle();null!=a&&(l.fill=a),null!=o&&(l.opacity=o);var u={inheritColor:Object(_["C"])(a)?a:"#000"},c=b(i,xy),h=le["c"](c,null,u,!1,!0);h.text=c.getShallow("show")?Object(_["P"])(t.getFormattedLabel(i,xy),oe(e,i)):null;var d=le["b"](c,u,!1);return M(n,l),l=Xv(l,h,d),n&&T(l,n),l.legacy=!0,l}function S(n,i){null==i&&(i=s);var r=y(i,by).getItemStyle(),a=b(i,by),o=le["c"](a,null,null,!0,!0);o.text=a.getShallow("show")?Object(_["Q"])(t.getFormattedLabel(i,by),t.getFormattedLabel(i,xy),oe(e,i)):null;var l=le["b"](a,null,!0);return M(n,r),r=Xv(r,o,l),n&&T(r,n),r.legacy=!0,r}function T(t,e){for(var n in e)Object(_["q"])(e,n)&&(t[n]=e[n])}function M(t,e){t&&(t.textFill&&(e.textFill=t.textFill),t.textPosition&&(e.textPosition=t.textPosition))}function A(t,n){if(null==n&&(n=s),Object(_["q"])(Iv,t)){var i=e.getItemVisual(n,"style");return i?i[Iv[t]]:null}if(Object(_["q"])(Dv,t))return e.getItemVisual(n,t)}function C(t){if("cartesian2d"===a.type){var e=a.getBaseAxis();return Object(vn["b"])(Object(_["i"])({axis:e},t))}}function I(){return n.getCurrentSeriesIndices()}function D(t){return le["d"](t,n)}}function Gy(t){var e={};return Object(_["k"])(t.dimensions,(function(n){var i=t.getDimensionInfo(n);if(!i.isExtraCoord){var r=i.coordDim,a=e[r]=e[r]||[];a[i.coordDimIndex]=t.getDimensionIndex(n)}})),e}function Hy(t,e,n,i,r,a,o){if(i){var s=Uy(t,e,n,i,r,a);return s&&o.setItemGraphicEl(n,s),s&&Object(re["J"])(s,i.focus,i.blurScope,i.emphasisDisabled),s}a.remove(e)}function Uy(t,e,n,i,r,a){var o=-1,s=e;e&&Wy(e,i,r)&&(o=Object(_["r"])(a.childrenRef(),e),e=null);var l=!e,u=e;u?u.clearStates():(u=Ry(i),s&&jy(s,u)),!1===i.morph?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),Iy.normal.cfg=Iy.normal.conOpt=Iy.emphasis.cfg=Iy.emphasis.conOpt=Iy.blur.cfg=Iy.blur.conOpt=Iy.select.cfg=Iy.select.conOpt=null,Iy.isLegacy=!1,Zy(u,n,i,r,l,Iy),Xy(u,n,i,r,l),ky(t,u,n,i,Iy,r,l),Object(_["q"])(i,"info")&&(Lv(u).info=i.info);for(var c=0;c=0?a.replaceAt(u,o):a.add(u),u}function Wy(t,e,n){var i=Lv(t),r=e.type,a=e.shape,o=e.style;return n.isUniversalTransitionEnabled()||null!=r&&r!==i.customGraphicType||"path"===r&&i_(a)&&n_(a)!==i.customPathData||"image"===r&&Object(_["q"])(o,"image")&&o.image!==i.customImagePath}function Xy(t,e,n,i,r){var a=n.clipPath;if(!1===a)t&&t.getClipPath()&&t.removeClipPath();else if(a){var o=t.getClipPath();o&&Wy(o,a,i)&&(o=null),o||(o=Ry(a),t.setClipPath(o)),ky(null,o,e,a,null,i,r)}}function Zy(t,e,n,i,r,a){if(!t.isGroup){qy(n,null,a),qy(n,by,a);var o=a.normal.conOpt,s=a.emphasis.conOpt,l=a.blur.conOpt,u=a.select.conOpt;if(null!=o||null!=s||null!=u||null!=l){var c=t.getTextContent();if(!1===o)c&&t.removeTextContent();else{o=a.normal.conOpt=o||{type:"text"},c?c.clearStates():(c=Ry(o),t.setTextContent(c)),ky(null,c,e,o,null,i,r);for(var h=o&&o.style,d=0;d=c;h--){var d=e.childAt(h);ny(d,Lv(e).option,r)}}}function Jy(t){new Ql["a"](t.oldChildren,t.newChildren,$y,$y,t).add(t_).update(t_).remove(e_).execute()}function $y(t,e){var n=t&&t.name;return null!=n?n:Cy+e}function t_(t,e){var n=this.context,i=null!=t?n.newChildren[t]:null,r=null!=e?n.oldChildren[e]:null;Uy(n.api,r,n.dataIndex,i,n.seriesModel,n.group)}function e_(t){var e=this.context,n=e.oldChildren[t];ny(n,Lv(n).option,e.seriesModel)}function n_(t){return t&&(t.pathData||t.d)}function i_(t){return t&&(Object(_["q"])(t,"pathData")||Object(_["q"])(t,"d"))}function r_(t){t.registerChartView(Ny),t.registerSeriesModel(jv)}var a_=Object(Te["o"])(),o_=_["d"],s_=_["c"],l_=function(){function t(){this._dragging=!1,this.animationThreshold=15}return t.prototype.render=function(t,e,n,i){var r=e.get("value"),a=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==a){this._lastValue=r,this._lastStatus=a;var o=this._group,s=this._handle;if(!a||"hide"===a)return o&&o.hide(),void(s&&s.hide());o&&o.show(),s&&s.show();var l={};this.makeElOption(l,r,t,e,n);var u=l.graphicKey;u!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=u;var c=this._moveAnimation=this.determineAnimation(t,e);if(o){var h=_["h"](u_,e,c);this.updatePointerEl(o,l,h),this.updateLabelEl(o,l,h,e)}else o=this._group=new Jt["a"],this.createPointerEl(o,l,t,e),this.createLabelEl(o,l,t,e),n.getZr().add(o);f_(o,e,!0),this._renderHandle(r)}},t.prototype.remove=function(t){this.clear(t)},t.prototype.dispose=function(t){this.clear(t)},t.prototype.determineAnimation=function(t,e){var n=e.get("animation"),i=t.axis,r="category"===i.type,a=e.get("snap");if(!a&&!r)return!1;if("auto"===n||null==n){var o=this.animationThreshold;if(r&&i.getBandWidth()>o)return!0;if(a){var s=$r(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>o}return!1}return!0===n},t.prototype.makeElOption=function(t,e,n,i,r){},t.prototype.createPointerEl=function(t,e,n,i){var r=e.pointer;if(r){var a=a_(t).pointerEl=new ne[r.type](o_(e.pointer));t.add(a)}},t.prototype.createLabelEl=function(t,e,n,i){if(e.label){var r=a_(t).labelEl=new $["a"](o_(e.label));t.add(r),h_(r,i)}},t.prototype.updatePointerEl=function(t,e,n){var i=a_(t).pointerEl;i&&e.pointer&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},t.prototype.updateLabelEl=function(t,e,n,i){var r=a_(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{x:e.label.x,y:e.label.y}),h_(r,i))},t.prototype._renderHandle=function(t){if(!this._dragging&&this.updateHandleTransform){var e,n=this._axisPointerModel,i=this._api.getZr(),r=this._handle,a=n.getModel("handle"),o=n.get("status");if(!a.get("show")||!o||"hide"===o)return r&&i.remove(r),void(this._handle=null);this._handle||(e=!0,r=this._handle=ne["createIcon"](a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){Wa["g"](t.event)},onmousedown:s_(this._onHandleDragMove,this,0,0),drift:s_(this._onHandleDragMove,this),ondragend:s_(this._onHandleDragEnd,this)}),i.add(r)),f_(r,n,!1),r.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var s=a.get("size");_["t"](s)||(s=[s,s]),r.scaleX=s[0]/2,r.scaleY=s[1]/2,On["b"](this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,e)}},t.prototype._moveHandleToValue=function(t,e){u_(this._axisPointerModel,!e&&this._moveAnimation,this._handle,d_(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},t.prototype._onHandleDragMove=function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(d_(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(d_(i)),a_(n).lastProp=null,this._doDispatchAxisPointer()}},t.prototype._doDispatchAxisPointer=function(){var t=this._handle;if(t){var e=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},t.prototype._onHandleDragEnd=function(){this._dragging=!1;var t=this._handle;if(t){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},t.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,i=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),i&&e.remove(i),this._group=null,this._handle=null,this._payloadInfo=null),On["a"](this,"_doDispatchAxisPointer")},t.prototype.doClear=function(){},t.prototype.buildLabel=function(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}},t}();function u_(t,e,n,i){c_(a_(n).lastProp,i)||(a_(n).lastProp=i,e?ee["h"](n,i,t):(n.stopAnimation(),n.attr(i)))}function c_(t,e){if(_["A"](t)&&_["A"](e)){var n=!0;return _["k"](e,(function(e,i){n=n&&c_(t[i],e)})),!!n}return t===e}function h_(t,e){t[e.get(["label","show"])?"show":"hide"]()}function d_(t){return{x:t.x||0,y:t.y||0,rotation:t.rotation||0}}function f_(t,e,n){var i=e.get("z"),r=e.get("zlevel");t&&t.traverse((function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=r&&(t.zlevel=r),t.silent=n)}))}var p_=l_;function g_(t){var e,n=t.get("type"),i=t.getModel(n+"Style");return"line"===n?(e=i.getLineStyle(),e.fill=null):"shadow"===n&&(e=i.getAreaStyle(),e.stroke=null),e}function m_(t,e,n,i,r){var a=n.get("value"),o=y_(a,e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get(["label","precision"]),formatter:n.get(["label","formatter"])}),s=n.getModel("label"),l=He["j"](s.get("padding")||0),c=s.getFont(),h=u["d"](o,c),d=r.position,f=h.width+l[1]+l[3],p=h.height+l[0]+l[2],g=r.align;"right"===g&&(d[0]-=f),"center"===g&&(d[0]-=f/2);var m=r.verticalAlign;"bottom"===m&&(d[1]-=p),"middle"===m&&(d[1]-=p/2),v_(d,f,p,i);var v=s.get("backgroundColor");v&&"auto"!==v||(v=e.get(["axisLine","lineStyle","color"])),t.label={x:d[0],y:d[1],style:Object(le["c"])(s,{text:o,font:c,fill:s.getTextColor(),padding:l,backgroundColor:v}),z2:10}}function v_(t,e,n,i){var r=i.getWidth(),a=i.getHeight();t[0]=Math.min(t[0]+e,r)-e,t[1]=Math.min(t[1]+n,a)-n,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}function y_(t,e,n,i,r){t=e.scale.parse(t);var a=e.scale.getLabel({value:t},{precision:r.precision}),o=r.formatter;if(o){var s={value:sr["c"](e,{value:t}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};_["k"](i,(function(t){var e=n.getSeriesByIndex(t.seriesIndex),i=t.dataIndexInside,r=e&&e.getDataParams(i);r&&s.seriesData.push(r)})),_["C"](o)?a=o.replace("{value}",a):_["w"](o)&&(a=o(s))}return a}function __(t,e,n){var i=ur["c"]();return ur["g"](i,i,n.rotation),ur["i"](i,i,n.position),ne["applyTransform"]([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function b_(t,e,n,i,r,a){var o=Wr.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get(["label","margin"]),m_(e,i,r,a,{position:__(i.axis,t,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function x_(t,e,n){return n=n||0,{x1:t[n],y1:t[1-n],x2:e[n],y2:e[1-n]}}function w_(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}}function O_(t,e,n,i,r,a){return{cx:t,cy:e,r0:n,r:i,startAngle:r,endAngle:a,clockwise:!0}}var S_=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.makeElOption=function(t,e,n,i,r){var a=n.axis,o=a.grid,s=i.get("type"),l=T_(o,a).getOtherAxis(a).getGlobalExtent(),u=a.toGlobalCoord(a.dataToCoord(e,!0));if(s&&"none"!==s){var c=g_(i),h=M_[s](a,u,l);h.style=c,t.graphicKey=h.type,t.pointer=h}var d=yr(o.model,n);b_(e,t,d,n,i,r)},e.prototype.getHandleTransform=function(t,e,n){var i=yr(e.axis.grid.model,e,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var r=__(e.axis,t,i);return{x:r[0],y:r[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,e,n,i){var r=n.axis,a=r.grid,o=r.getGlobalExtent(!0),s=T_(a,r).getOtherAxis(r).getGlobalExtent(),l="x"===r.dim?0:1,u=[t.x,t.y];u[l]+=e[l],u[l]=Math.min(o[1],u[l]),u[l]=Math.max(o[0],u[l]);var c=(s[1]+s[0])/2,h=[c,c];h[l]=u[l];var d=[{verticalAlign:"middle"},{align:"center"}];return{x:u[0],y:u[1],rotation:t.rotation,cursorPoint:h,tooltipOption:d[l]}},e}(p_);function T_(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}var M_={line:function(t,e,n){var i=x_([e,n[0]],[e,n[1]],A_(t));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(t,e,n){var i=Math.max(1,t.getBandWidth()),r=n[1]-n[0];return{type:"Rect",shape:w_([e-i/2,n[0]],[i,r],A_(t))}}};function A_(t){return"x"===t.dim?0:1}var C_=S_,I_=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!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}(Xi["a"]),D_=I_,L_=n("22d1"),E_=Object(Te["o"])(),j_=_["k"];function P_(t,e,n){if(!L_["a"].node){var i=e.getZr();E_(i).records||(E_(i).records={}),N_(i,e);var r=E_(i).records[t]||(E_(i).records[t]={});r.handler=n}}function N_(t,e){function n(n,i){t.on(n,(function(n){var r=z_(e);j_(E_(t).records,(function(t){t&&i(t,n,r.dispatchAction)})),R_(r.pendings,e)}))}E_(t).initialized||(E_(t).initialized=!0,n("click",_["h"](B_,"click")),n("mousemove",_["h"](B_,"mousemove")),n("globalout",k_))}function R_(t,e){var n,i=t.showTip.length,r=t.hideTip.length;i?n=t.showTip[i-1]:r&&(n=t.hideTip[r-1]),n&&(n.dispatchAction=null,e.dispatchAction(n))}function k_(t,e,n){t.handler("leave",null,n)}function B_(t,e,n,i){e.handler(t,n,i)}function z_(t){var e={showTip:[],hideTip:[]},n=function(i){var r=e[i.type];r?r.push(i):(i.dispatchAction=n,t.dispatchAction(i))};return{dispatchAction:n,pendings:e}}function V_(t,e){if(!L_["a"].node){var n=e.getZr(),i=(E_(n).records||{})[t];i&&(E_(n).records[t]=null)}}var F_=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";P_("axisPointer",n,(function(t,e,n){"none"!==r&&("leave"===t||r.indexOf(t)>=0)&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})}))},e.prototype.remove=function(t,e){V_("axisPointer",e)},e.prototype.dispose=function(t,e){V_("axisPointer",e)},e.type="axisPointer",e}(Wi["a"]),G_=F_;function H_(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var a=n.getData(),o=Te["u"](a,t);if(null==o||o<0||_["t"](o))return{point:[]};var s=a.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(t.isStacked){var u=l.getBaseAxis(),c=l.getOtherAxis(u),h=c.dim,d=u.dim,f="x"===h||"radius"===h?1:0,p=a.mapDimension(d),g=[];g[f]=a.get(p,o),g[1-f]=a.get(a.getCalculationInfo("stackResultDimension"),o),i=l.dataToPoint(g)||[]}else i=l.dataToPoint(a.getValues(_["H"](l.dimensions,(function(t){return a.mapDimension(t)})),o))||[];else if(s){var m=s.getBoundingRect().clone();m.applyTransform(s.transform),i=[m.x+m.width/2,m.y+m.height/2]}return{point:i,el:s}}var U_=Object(Te["o"])();function W_(t,e,n){var i=t.currTrigger,r=[t.x,t.y],a=t,o=t.dispatchAction||Object(_["c"])(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){eb(r)&&(r=H_({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},e).point);var l=eb(r),u=a.axesInfo,c=s.axesInfo,h="leave"===i||eb(r),d={},f={},p={list:[],map:{}},g={showPointer:Object(_["h"])(q_,f),showTooltip:Object(_["h"])(Y_,p)};Object(_["k"])(s.coordSysMap,(function(t,e){var n=l||t.containPoint(r);Object(_["k"])(s.coordSysAxesInfo[e],(function(t,e){var i=t.axis,a=$_(u,t);if(!h&&n&&(!u||a)){var o=a&&a.value;null!=o||l||(o=i.pointToData(r)),null!=o&&X_(t,o,g,!1,d)}}))}));var m={};return Object(_["k"])(c,(function(t,e){var n=t.linkGroup;n&&!f[e]&&Object(_["k"])(n.axesInfo,(function(e,i){var r=f[i];if(e!==t&&r){var a=r.value;n.mapper&&(a=t.axis.scale.parse(n.mapper(a,tb(e),tb(t)))),m[t.key]=a}}))})),Object(_["k"])(m,(function(t,e){X_(c[e],t,g,!0,d)})),K_(f,c,d),Q_(p,r,t,o),J_(c,o,n),d}}function X_(t,e,n,i,r){var a=t.axis;if(!a.scale.isBlank()&&a.containData(e))if(t.involveSeries){var o=Z_(e,t),s=o.payloadBatch,l=o.snapToValue;s[0]&&null==r.seriesIndex&&Object(_["m"])(r,s[0]),!i&&t.snap&&a.containData(l)&&null!=l&&(e=l),n.showPointer(t,e,s),n.showTooltip(t,o,l)}else n.showPointer(t,e)}function Z_(t,e){var n=e.axis,i=n.dim,r=t,a=[],o=Number.MAX_VALUE,s=-1;return Object(_["k"])(e.seriesModels,(function(e,l){var u,c,h=e.getData().mapDimensionsAll(i);if(e.getAxisTooltipData){var d=e.getAxisTooltipData(h,t,n);c=d.dataIndices,u=d.nestestValue}else{if(c=e.getData().indicesOfNearest(h[0],t,"category"===n.type?.5:null),!c.length)return;u=e.getData().get(h[0],c[0])}if(null!=u&&isFinite(u)){var f=t-u,p=Math.abs(f);p<=o&&((p=0&&s<0)&&(o=p,s=f,r=u,a.length=0),Object(_["k"])(c,(function(t){a.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})})))}})),{payloadBatch:a,snapToValue:r}}function q_(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function Y_(t,e,n,i){var r=n.payloadBatch,a=e.axis,o=a.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,u=na(l),c=t.map[u];c||(c=t.map[u]={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:i,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:r.slice()})}}function K_(t,e,n){var i=n.axesInfo=[];Object(_["k"])(e,(function(e,n){var r=e.axisPointerModel.option,a=t[n];a?(!e.useHandle&&(r.status="show"),r.value=a.value,r.seriesDataIndices=(a.payloadBatch||[]).slice()):!e.useHandle&&(r.status="hide"),"show"===r.status&&i.push({axisDim:e.axis.dim,axisIndex:e.axis.model.componentIndex,value:r.value})}))}function Q_(t,e,n,i){if(!eb(e)&&t.list.length){var r=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:r.dataIndexInside,dataIndex:r.dataIndex,seriesIndex:r.seriesIndex,dataByCoordSys:t.list})}else i({type:"hideTip"})}function J_(t,e,n){var i=n.getZr(),r="axisPointerLastHighlights",a=U_(i)[r]||{},o=U_(i)[r]={};Object(_["k"])(t,(function(t,e){var n=t.axisPointerModel.option;"show"===n.status&&Object(_["k"])(n.seriesDataIndices,(function(t){var e=t.seriesIndex+" | "+t.dataIndex;o[e]=t}))}));var s=[],l=[];Object(_["k"])(a,(function(t,e){!o[e]&&l.push(t)})),Object(_["k"])(o,(function(t,e){!a[e]&&s.push(t)})),l.length&&n.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&n.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function $_(t,e){for(var n=0;n<(t||[]).length;n++){var i=t[n];if(e.axis.dim===i.axisDim&&e.axis.model.componentIndex===i.axisIndex)return i}}function tb(t){var e=t.axis.model,n={},i=n.axisDim=t.axis.dim;return n.axisIndex=n[i+"AxisIndex"]=e.componentIndex,n.axisName=n[i+"AxisName"]=e.name,n.axisId=n[i+"AxisId"]=e.id,n}function eb(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function nb(t){aa.registerAxisPointerClass("CartesianAxisPointer",C_),t.registerComponentModel(D_),t.registerComponentView(G_),t.registerPreprocessor((function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!Object(_["t"])(e)&&(t.axisPointer.link=[e])}})),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,(function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=Xr(t,e)})),t.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},W_)}function ib(t){Object(i["a"])(va),Object(i["a"])(nb)}var rb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.makeElOption=function(t,e,n,i,r){var a=n.axis;"angle"===a.dim&&(this.animationThreshold=Math.PI/18);var o=a.polar,s=o.getOtherAxis(a),l=s.getExtent(),u=a.dataToCoord(e),c=i.get("type");if(c&&"none"!==c){var h=g_(i),d=ob[c](a,o,u,l);d.style=h,t.graphicKey=d.type,t.pointer=d}var f=i.get(["label","margin"]),p=ab(e,n,i,o,f);m_(t,n,i,r,p)},e}(p_);function ab(t,e,n,i,r){var a=e.axis,o=a.dataToCoord(t),s=i.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l,u,c,h=i.getRadiusAxis().getExtent();if("radius"===a.dim){var d=ur["c"]();ur["g"](d,d,s),ur["i"](d,d,[i.cx,i.cy]),l=ne["applyTransform"]([o,-r],d);var f=e.getModel("axisLabel").get("rotate")||0,p=Wr.innerTextLayout(s,f*Math.PI/180,-1);u=p.textAlign,c=p.textVerticalAlign}else{var g=h[1];l=i.coordToPoint([g+r,o]);var m=i.cx,v=i.cy;u=Math.abs(l[0]-m)/g<.3?"center":l[0]>m?"left":"right",c=Math.abs(l[1]-v)/g<.3?"middle":l[1]>v?"top":"bottom"}return{position:l,align:u,verticalAlign:c}}var ob={line:function(t,e,n,i){return"angle"===t.dim?{type:"Line",shape:x_(e.coordToPoint([i[0],n]),e.coordToPoint([i[1],n]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:n}}},shadow:function(t,e,n,i){var r=Math.max(1,t.getBandWidth()),a=Math.PI/180;return"angle"===t.dim?{type:"Sector",shape:O_(e.cx,e.cy,i[0],i[1],(-n-r/2)*a,(r/2-n)*a)}:{type:"Sector",shape:O_(e.cx,e.cy,n-r/2,n+r/2,0,2*Math.PI)}}},sb=rb,lb=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.findAxisModel=function(t){var e,n=this.ecModel;return n.eachComponent(t,(function(t){t.getCoordSysModel()===this&&(e=t)}),this),e},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e}(Xi["a"]),ub=lb,cb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Te["b"]).models[0]},e.type="polarAxis",e}(Xi["a"]);_["K"](cb,Yi["a"]);var hb=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="angleAxis",e}(cb),db=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="radiusAxis",e}(cb),fb=function(t){function e(e,n){return t.call(this,"radius",e,n)||this}return Object(qt["a"])(e,t),e.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},e}(gr["a"]);fb.prototype.dataToRadius=gr["a"].prototype.dataToCoord,fb.prototype.radiusToData=gr["a"].prototype.coordToData;var pb=fb,gb=Object(Te["o"])(),mb=function(t){function e(e,n){return t.call(this,"angle",e,n||[0,360])||this}return Object(qt["a"])(e,t),e.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,e=t.getLabelModel(),n=t.scale,i=n.getExtent(),r=n.count();if(i[1]-i[0]<1)return 0;var a=i[0],o=t.dataToCoord(a+1)-t.dataToCoord(a),s=Math.abs(o),l=u["d"](null==a?"":a+"",e.getFont(),"center","top"),c=Math.max(l.height,7),h=c/s;isNaN(h)&&(h=1/0);var d=Math.max(0,Math.floor(h)),f=gb(t.model),p=f.lastAutoInterval,g=f.lastTickCount;return null!=p&&null!=g&&Math.abs(p-d)<=1&&Math.abs(g-r)<=1&&p>d?d=p:(f.lastTickCount=r,f.lastAutoInterval=d),d},e}(gr["a"]);mb.prototype.dataToAngle=gr["a"].prototype.dataToCoord,mb.prototype.angleToData=gr["a"].prototype.coordToData;var vb=mb,yb=["radius","angle"],_b=function(){function t(t){this.dimensions=yb,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new pb,this._angleAxis=new vb,this.axisPointerEnabled=!0,this.name=t||"",this._radiusAxis.polar=this._angleAxis.polar=this}return t.prototype.containPoint=function(t){var e=this.pointToCoord(t);return this._radiusAxis.contain(e[0])&&this._angleAxis.contain(e[1])},t.prototype.containData=function(t){return this._radiusAxis.containData(t[0])&&this._angleAxis.containData(t[1])},t.prototype.getAxis=function(t){var e="_"+t+"Axis";return this[e]},t.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},t.prototype.getAxesByScale=function(t){var e=[],n=this._angleAxis,i=this._radiusAxis;return n.scale.type===t&&e.push(n),i.scale.type===t&&e.push(i),e},t.prototype.getAngleAxis=function(){return this._angleAxis},t.prototype.getRadiusAxis=function(){return this._radiusAxis},t.prototype.getOtherAxis=function(t){var e=this._angleAxis;return t===e?this._radiusAxis:e},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},t.prototype.getTooltipAxes=function(t){var e=null!=t&&"auto"!==t?this.getAxis(t):this.getBaseAxis();return{baseAxes:[e],otherAxes:[this.getOtherAxis(e)]}},t.prototype.dataToPoint=function(t,e){return this.coordToPoint([this._radiusAxis.dataToRadius(t[0],e),this._angleAxis.dataToAngle(t[1],e)])},t.prototype.pointToData=function(t,e){var n=this.pointToCoord(t);return[this._radiusAxis.radiusToData(n[0],e),this._angleAxis.angleToData(n[1],e)]},t.prototype.pointToCoord=function(t){var e=t[0]-this.cx,n=t[1]-this.cy,i=this.getAngleAxis(),r=i.getExtent(),a=Math.min(r[0],r[1]),o=Math.max(r[0],r[1]);i.inverse?a=o-360:o=a+360;var s=Math.sqrt(e*e+n*n);e/=s,n/=s;var l=Math.atan2(-n,e)/Math.PI*180,u=lo)l+=360*u;return[s,l]},t.prototype.coordToPoint=function(t){var e=t[0],n=t[1]/180*Math.PI,i=Math.cos(n)*e+this.cx,r=-Math.sin(n)*e+this.cy;return[i,r]},t.prototype.getArea=function(){var t=this.getAngleAxis(),e=this.getRadiusAxis(),n=e.getExtent().slice();n[0]>n[1]&&n.reverse();var i=t.getExtent(),r=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:n[0],r:n[1],startAngle:-i[0]*r,endAngle:-i[1]*r,clockwise:t.inverse,contain:function(t,e){var n=t-this.cx,i=e-this.cy,r=n*n+i*i-1e-4,a=this.r,o=this.r0;return r<=a*a&&r>=o*o}}},t.prototype.convertToPixel=function(t,e,n){var i=bb(e);return i===this?this.dataToPoint(n):null},t.prototype.convertFromPixel=function(t,e,n){var i=bb(e);return i===this?this.pointToData(n):null},t}();function bb(t){var e=t.seriesModel,n=t.polarModel;return n&&n.coordinateSystem||e&&e.coordinateSystem}var xb=_b;function wb(t,e,n){var i=e.get("center"),r=n.getWidth(),a=n.getHeight();t.cx=Object(Be["p"])(i[0],r),t.cy=Object(Be["p"])(i[1],a);var o=t.getRadiusAxis(),s=Math.min(r,a)/2,l=e.get("radius");null==l?l=[0,"100%"]:_["t"](l)||(l=[0,l]);var u=[Object(Be["p"])(l[0],s),Object(Be["p"])(l[1],s)];o.inverse?o.setExtent(u[1],u[0]):o.setExtent(u[0],u[1])}function Ob(t,e){var n=this,i=n.getAngleAxis(),r=n.getRadiusAxis();if(i.scale.setExtent(1/0,-1/0),r.scale.setExtent(1/0,-1/0),t.eachSeries((function(t){if(t.coordinateSystem===n){var e=t.getData();_["k"](Object(sr["d"])(e,"radius"),(function(t){r.scale.unionExtentFromData(e,t)})),_["k"](Object(sr["d"])(e,"angle"),(function(t){i.scale.unionExtentFromData(e,t)}))}})),Object(sr["i"])(i.scale,i.model),Object(sr["i"])(r.scale,r.model),"category"===i.type&&!i.onBand){var a=i.getExtent(),o=360/i.scale.count();i.inverse?a[1]+=o:a[1]-=o,i.setExtent(a[0],a[1])}}function Sb(t){return"angleAxis"===t.mainType}function Tb(t,e){if(t.type=e.get("type"),t.scale=Object(sr["a"])(e),t.onBand=e.get("boundaryGap")&&"category"===t.type,t.inverse=e.get("inverse"),Sb(e)){t.inverse=t.inverse!==e.get("clockwise");var n=e.get("startAngle");t.setExtent(n,n+(t.inverse?-360:360))}e.axis=t,t.model=e}var Mb={dimensions:yb,create:function(t,e){var n=[];return t.eachComponent("polar",(function(t,i){var r=new xb(i+"");r.update=Ob;var a=r.getRadiusAxis(),o=r.getAngleAxis(),s=t.findAxisModel("radiusAxis"),l=t.findAxisModel("angleAxis");Tb(a,s),Tb(o,l),wb(r,t,e),n.push(r),t.coordinateSystem=r,r.model=t})),t.eachSeries((function(t){if("polar"===t.get("coordinateSystem")){var e=t.getReferringComponents("polar",Te["b"]).models[0];0,t.coordinateSystem=e.coordinateSystem}})),n}},Ab=Mb,Cb=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Ib(t,e,n){e[1]>e[0]&&(e=e.slice().reverse());var i=t.coordToPoint([e[0],n]),r=t.coordToPoint([e[1],n]);return{x1:i[0],y1:i[1],x2:r[0],y2:r[1]}}function Db(t){var e=t.getRadiusAxis();return e.inverse?0:1}function Lb(t){var e=t[0],n=t[t.length-1];e&&n&&Math.abs(Math.abs(e.coord-n.coord)-360)<1e-4&&t.pop()}var Eb=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.axisPointerClass="PolarAxisPointer",n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e){if(this.group.removeAll(),t.get("show")){var n=t.axis,i=n.polar,r=i.getRadiusAxis().getExtent(),a=n.getTicksCoords(),o=n.getMinorTicksCoords(),s=_["H"](n.getViewLabels(),(function(t){t=_["d"](t);var e=n.scale,i="ordinal"===e.type?e.getRawOrdinalNumber(t.tickValue):t.tickValue;return t.coord=n.dataToCoord(i),t}));Lb(s),Lb(a),_["k"](Cb,(function(e){!t.get([e,"show"])||n.scale.isBlank()&&"axisLine"!==e||jb[e](this.group,t,i,a,o,r,s)}),this)}},e.type="angleAxis",e}(aa),jb={axisLine:function(t,e,n,i,r,a){var o,s=e.getModel(["axisLine","lineStyle"]),l=Db(n),u=l?0:1;o=0===a[u]?new ja["a"]({shape:{cx:n.cx,cy:n.cy,r:a[l]},style:s.getLineStyle(),z2:1,silent:!0}):new Pa["a"]({shape:{cx:n.cx,cy:n.cy,r:a[l],r0:a[u]},style:s.getLineStyle(),z2:1,silent:!0}),o.style.fill=null,t.add(o)},axisTick:function(t,e,n,i,r,a){var o=e.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=a[Db(n)],u=_["H"](i,(function(t){return new Lr["a"]({shape:Ib(n,[l,l+s],t.coord)})}));t.add(ne["mergePath"](u,{style:_["i"](o.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(t,e,n,i,r,a){if(r.length){for(var o=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=a[Db(n)],c=[],h=0;hp?"left":"right",v=Math.abs(f[1]-g)/d<.3?"middle":f[1]>g?"top":"bottom";if(s&&s[h]){var y=s[h];_["A"](y)&&y.textStyle&&(o=new Er["a"](y.textStyle,l,l.ecModel))}var b=new $["a"]({silent:Wr.isLabelSilent(e),style:Object(le["c"])(o,{x:f[0],y:f[1],fill:o.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:i.formattedLabel,align:m,verticalAlign:v})});if(t.add(b),c){var x=Wr.makeAxisEventDataBase(e);x.targetType="axisLabel",x.value=i.rawLabel,Object(ie["a"])(b).eventData=x}}),this)},splitLine:function(t,e,n,i,r,a){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],h=0;h=0?"p":"n",M=b;y&&(i[s][S]||(i[s][S]={p:b,n:b}),M=i[s][S][T]);var A=void 0,C=void 0,I=void 0,D=void 0;if("radius"===h.dim){var L=h.dataToCoord(O)-b,E=a.dataToCoord(S);Math.abs(L)=D})}}}))}function Ub(t){var e={};_["k"](t,(function(t,n){var i=t.getData(),r=t.coordinateSystem,a=r.getBaseAxis(),o=Gb(r,a),s=a.getExtent(),l="category"===a.type?a.getBandWidth():Math.abs(s[1]-s[0])/i.count(),u=e[o]||{bandWidth:l,remainedWidth:l,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},c=u.stacks;e[o]=u;var h=Fb(t);c[h]||u.autoWidthCount++,c[h]=c[h]||{width:0,maxWidth:0};var d=Object(Be["p"])(t.get("barWidth"),l),f=Object(Be["p"])(t.get("barMaxWidth"),l),p=t.get("barGap"),g=t.get("barCategoryGap");d&&!c[h].width&&(d=Math.min(u.remainedWidth,d),c[h].width=d,u.remainedWidth-=d),f&&(c[h].maxWidth=f),null!=p&&(u.gap=p),null!=g&&(u.categoryGap=g)}));var n={};return _["k"](e,(function(t,e){n[e]={};var i=t.stacks,r=t.bandWidth,a=Object(Be["p"])(t.categoryGap,r),o=Object(Be["p"])(t.gap,1),s=t.remainedWidth,l=t.autoWidthCount,u=(s-a)/(l+(l-1)*o);u=Math.max(u,0),_["k"](i,(function(t,e){var n=t.maxWidth;n&&n=e.y&&t[1]<=e.y+e.height:n.contain(n.toLocalCoord(t[1]))&&t[0]>=e.y&&t[0]<=e.y+e.height},t.prototype.pointToData=function(t){var e=this.getAxis();return[e.coordToData(e.toLocalCoord(t["horizontal"===e.orient?0:1]))]},t.prototype.dataToPoint=function(t){var e=this.getAxis(),n=this.getRect(),i=[],r="horizontal"===e.orient?0:1;return t instanceof Array&&(t=t[0]),i[r]=e.toGlobalCoord(e.dataToCoord(+t)),i[1-r]=0===r?n.y+n.height/2:n.x+n.width/2,i},t.prototype.convertToPixel=function(t,e,n){var i=lx(e);return i===this?this.dataToPoint(n):null},t.prototype.convertFromPixel=function(t,e,n){var i=lx(e);return i===this?this.pointToData(n):null},t}();function lx(t){var e=t.seriesModel,n=t.singleAxisModel;return n&&n.coordinateSystem||e&&e.coordinateSystem}var ux=sx;function cx(t,e){var n=[];return t.eachComponent("singleAxis",(function(i,r){var a=new ux(i,t,e);a.name="single_"+r,a.resize(i,e),i.coordinateSystem=a,n.push(a)})),t.eachSeries((function(t){if("singleAxis"===t.get("coordinateSystem")){var e=t.getReferringComponents("singleAxis",Te["b"]).models[0];t.coordinateSystem=e&&e.coordinateSystem}})),n}var hx={create:cx,dimensions:ox},dx=hx,fx=["x","y"],px=["width","height"],gx=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.makeElOption=function(t,e,n,i,r){var a=n.axis,o=a.coordinateSystem,s=yx(o,1-vx(a)),l=o.dataToPoint(e)[0],u=i.get("type");if(u&&"none"!==u){var c=g_(i),h=mx[u](a,l,s);h.style=c,t.graphicKey=h.type,t.pointer=h}var d=Kb(n);b_(e,t,d,n,i,r)},e.prototype.getHandleTransform=function(t,e,n){var i=Kb(e,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var r=__(e.axis,t,i);return{x:r[0],y:r[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,e,n,i){var r=n.axis,a=r.coordinateSystem,o=vx(r),s=yx(a,o),l=[t.x,t.y];l[o]+=e[o],l[o]=Math.min(s[1],l[o]),l[o]=Math.max(s[0],l[o]);var u=yx(a,1-o),c=(u[1]+u[0])/2,h=[c,c];return h[o]=l[o],{x:l[0],y:l[1],rotation:t.rotation,cursorPoint:h,tooltipOption:{verticalAlign:"middle"}}},e}(p_),mx={line:function(t,e,n){var i=x_([e,n[0]],[e,n[1]],vx(t));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(t,e,n){var i=t.getBandWidth(),r=n[1]-n[0];return{type:"Rect",shape:w_([e-i/2,n[0]],[i,r],vx(t))}}};function vx(t){return t.isHorizontal()?0:1}function yx(t,e){var n=t.getRect();return[n[fx[e]],n[fx[e]]+n[px[e]]]}var _x=gx,bx=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="single",e}(Wi["a"]);function xx(t){Object(i["a"])(nb),aa.registerAxisPointerClass("SingleAxisPointer",_x),t.registerComponentView(bx),t.registerComponentView(ex),t.registerComponentModel(ix),ar(t,"single",ix,ix.defaultOption),t.registerCoordinateSystem("single",dx)}var wx=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(e,n,i){var r=Object(ri["f"])(e);t.prototype.init.apply(this,arguments),Ox(e,r)},e.prototype.mergeOption=function(e){t.prototype.mergeOption.apply(this,arguments),Ox(this.option,e)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e}(Xi["a"]);function Ox(t,e){var n,i=t.cellSize;n=_["t"](i)?i:t.cellSize=[i,i],1===n.length&&(n[1]=n[0]);var r=_["H"]([0,1],(function(t){return Object(ri["j"])(e,t)&&(n[t]="auto"),null!=n[t]&&"auto"!==n[t]}));Object(ri["h"])(t,e,{type:"box",ignoreSize:r})}var Sx=wx,Tx=n("ef59"),Mx=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i=this.group;i.removeAll();var r=t.coordinateSystem,a=r.getRangeInfo(),o=r.getOrient(),s=e.getLocaleModel();this._renderDayRect(t,a,i),this._renderLines(t,a,o,i),this._renderYearText(t,a,o,i),this._renderMonthText(t,s,o,i),this._renderWeekText(t,s,a,o,i)},e.prototype._renderDayRect=function(t,e,n){for(var i=t.coordinateSystem,r=t.getModel("itemStyle").getItemStyle(),a=i.getCellWidth(),o=i.getCellHeight(),s=e.start.time;s<=e.end.time;s=i.getNextNDay(s,1).time){var l=i.dataToRect([s],!1).tl,u=new Re["a"]({shape:{x:l[0],y:l[1],width:a,height:o},cursor:"default",style:r});n.add(u)}},e.prototype._renderLines=function(t,e,n,i){var r=this,a=t.coordinateSystem,o=t.getModel(["splitLine","lineStyle"]).getLineStyle(),s=t.get(["splitLine","show"]),l=o.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var u=e.start,c=0;u.time<=e.end.time;c++){d(u.formatedDate),0===c&&(u=a.getDateInfo(e.start.y+"-"+e.start.m));var h=u.date;h.setMonth(h.getMonth()+1),u=a.getDateInfo(h)}function d(e){r._firstDayOfMonth.push(a.getDateInfo(e)),r._firstDayPoints.push(a.dataToRect([e],!1).tl);var l=r._getLinePointsOfOneWeek(t,e,n);r._tlpoints.push(l[0]),r._blpoints.push(l[l.length-1]),s&&r._drawSplitline(l,o,i)}d(a.getNextNDay(e.end.time,1).formatedDate),s&&this._drawSplitline(r._getEdgesPoints(r._tlpoints,l,n),o,i),s&&this._drawSplitline(r._getEdgesPoints(r._blpoints,l,n),o,i)},e.prototype._getEdgesPoints=function(t,e,n){var i=[t[0].slice(),t[t.length-1].slice()],r="horizontal"===n?0:1;return i[0][r]=i[0][r]-e/2,i[1][r]=i[1][r]+e/2,i},e.prototype._drawSplitline=function(t,e,n){var i=new hi["a"]({z2:20,shape:{points:t},style:e});n.add(i)},e.prototype._getLinePointsOfOneWeek=function(t,e,n){for(var i=t.coordinateSystem,r=i.getDateInfo(e),a=[],o=0;o<7;o++){var s=i.getNextNDay(r.time,o),l=i.dataToRect([s.time],!1);a[2*s.day]=l.tl,a[2*s.day+1]=l["horizontal"===n?"bl":"tr"]}return a},e.prototype._formatterLabel=function(t,e){return Object(_["C"])(t)&&t?Object(He["g"])(t,e):Object(_["w"])(t)?t(e):e.nameMap},e.prototype._yearTextPositionControl=function(t,e,n,i,r){var a=e[0],o=e[1],s=["center","bottom"];"bottom"===i?(o+=r,s=["center","top"]):"left"===i?a-=r:"right"===i?(a+=r,s=["center","top"]):o-=r;var l=0;return"left"!==i&&"right"!==i||(l=Math.PI/2),{rotation:l,x:a,y:o,style:{align:s[0],verticalAlign:s[1]}}},e.prototype._renderYearText=function(t,e,n,i){var r=t.getModel("yearLabel");if(r.get("show")){var a=r.get("margin"),o=r.get("position");o||(o="horizontal"!==n?"top":"left");var s=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],l=(s[0][0]+s[1][0])/2,u=(s[0][1]+s[1][1])/2,c="horizontal"===n?0:1,h={top:[l,s[c][1]],bottom:[l,s[1-c][1]],left:[s[1-c][0],u],right:[s[c][0],u]},d=e.start.y;+e.end.y>+e.start.y&&(d=d+"-"+e.end.y);var f=r.get("formatter"),p={start:e.start.y,end:e.end.y,nameMap:d},g=this._formatterLabel(f,p),m=new $["a"]({z2:30,style:Object(le["c"])(r,{text:g})});m.attr(this._yearTextPositionControl(m,h[o],n,o,a)),i.add(m)}},e.prototype._monthTextPositionControl=function(t,e,n,i,r){var a="left",o="top",s=t[0],l=t[1];return"horizontal"===n?(l+=r,e&&(a="center"),"start"===i&&(o="bottom")):(s+=r,e&&(o="middle"),"start"===i&&(a="right")),{x:s,y:l,align:a,verticalAlign:o}},e.prototype._renderMonthText=function(t,e,n,i){var r=t.getModel("monthLabel");if(r.get("show")){var a=r.get("nameMap"),o=r.get("margin"),s=r.get("position"),l=r.get("align"),u=[this._tlpoints,this._blpoints];a&&!Object(_["C"])(a)||(a&&(e=Object(Tx["d"])(a)||e),a=e.get(["time","monthAbbr"])||[]);var c="start"===s?0:1,h="horizontal"===n?0:1;o="start"===s?-o:o;for(var d="center"===l,f=0;f=i.start.time&&n.timeo.end.time&&t.reverse(),t},t.prototype._getRangeInfo=function(t){var e,n=[this.getDateInfo(t[0]),this.getDateInfo(t[1])];n[0].time>n[1].time&&(e=!0,n.reverse());var i=Math.floor(n[1].time/Cx)-Math.floor(n[0].time/Cx)+1,r=new Date(n[0].time),a=r.getDate(),o=n[1].date.getDate();r.setDate(a+i-1);var s=r.getDate();if(s!==o){var l=r.getTime()-n[1].time>0?1:-1;while((s=r.getDate())!==o&&(r.getTime()-n[1].time)*l>0)i-=l,r.setDate(s-l)}var u=Math.floor((i+n[0].day+6)/7),c=e?1-u:u-1;return e&&n.reverse(),{range:[n[0].formatedDate,n[1].formatedDate],start:n[0],end:n[1],allDay:i,weeks:u,nthWeek:c,fweek:n[0].day,lweek:n[1].day}},t.prototype._getDateByWeeksAndDay=function(t,e,n){var i=this._getRangeInfo(n);if(t>i.weeks||0===t&&ei.lweek)return null;var r=7*(t-1)-i.fweek+e,a=new Date(i.start.time);return a.setDate(+i.start.d+r),this.getDateInfo(a)},t.create=function(e,n){var i=[];return e.eachComponent("calendar",(function(r){var a=new t(r,e,n);i.push(a),r.coordinateSystem=a})),e.eachSeries((function(t){"calendar"===t.get("coordinateSystem")&&(t.coordinateSystem=i[t.get("calendarIndex")||0])})),i},t.dimensions=["time","value"],t}();function Dx(t){var e=t.calendarModel,n=t.seriesModel,i=e?e.coordinateSystem:n?n.coordinateSystem:null;return i}var Lx=Ix;function Ex(t){t.registerComponentModel(Sx),t.registerComponentView(Ax),t.registerCoordinateSystem("calendar",Lx)}function jx(t,e){var n=t.existing;if(e.id=t.keyInfo.id,!e.type&&n&&(e.type=n.type),null==e.parentId){var i=e.parentOption;i?e.parentId=i.id:n&&(e.parentId=n.parentId)}e.parentOption=null}function Px(t,e){var n;return _["k"](e,(function(e){null!=t[e]&&"auto"!==t[e]&&(n=!0)})),n}function Nx(t,e,n){var i=_["m"]({},n),r=t[e],a=n.$action||"merge";"merge"===a?r?(_["I"](r,i,!0),Object(ri["h"])(r,i,{ignoreSize:!0}),Object(ri["c"])(n,r),Bx(n,r),Bx(n,r,"shape"),Bx(n,r,"style"),Bx(n,r,"extra"),n.clipPath=r.clipPath):t[e]=i:"replace"===a?t[e]=i:"remove"===a&&r&&(t[e]=null)}var Rx=["transition","enterFrom","leaveTo"],kx=Rx.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function Bx(t,e,n){if(n&&(!t[n]&&e[n]&&(t[n]={}),t=t[n],e=e[n]),t&&e)for(var i=n?Rx:kx,r=0;r=0;l--){u=n[l],c=Te["e"](u.id,null),h=null!=c?r.get(c):null;if(h){d=h.parent,g=Gx(d);var m=d===i?{width:a,height:o}:{width:g.width,height:g.height},v={},y=ri["i"](h,u,m,null,{hv:u.hv,boundingMode:u.bounding},v);if(!Gx(h).isNew&&y){for(var b=u.transition,x={},w=0;w=0)?x[O]=S:h[O]=S}Object(ee["h"])(h,x,t,0)}else h.attr(v)}}},e.prototype._clear=function(){var t=this,e=this._elMap;e.each((function(n){Xx(n,Gx(n).option,e,t._lastGraphicModel)})),this._elMap=_["f"]()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e}(Wi["a"]);function Ux(t){var e=_["q"](Fx,t)?Fx[t]:ne["getShapeClass"](t);var n=new e({});return Gx(n).type=t,n}function Wx(t,e,n,i){var r=Ux(n);return e.add(r),i.set(t,r),Gx(r).id=t,Gx(r).isNew=!0,r}function Xx(t,e,n,i){var r=t&&t.parent;r&&("group"===t.type&&t.traverse((function(t){Xx(t,e,n,i)})),ny(t,e,i),n.removeKey(Gx(t).id))}function Zx(t,e,n,i){t.isGroup||_["k"]([["cursor",os["c"].prototype.cursor],["zlevel",i||0],["z",n||0],["z2",0]],(function(n){var i=n[0];_["q"](e,i)?t[i]=_["P"](e[i],n[1]):null==t[i]&&(t[i]=n[1])})),_["k"](_["F"](e),(function(n){if(0===n.indexOf("on")){var i=e[n];t[n]=_["w"](i)?i:null}})),_["q"](e,"draggable")&&(t.draggable=e.draggable),null!=e.name&&(t.name=e.name),null!=e.id&&(t.id=e.id)}function qx(t){return t=_["m"]({},t),_["k"](["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(ri["a"]),(function(e){delete t[e]})),t}function Yx(t,e,n){var i=Object(ie["a"])(t).eventData;t.silent||t.ignore||i||(i=Object(ie["a"])(t).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:t.name}),i&&(i.info=n.info)}function Kx(t){t.registerComponentModel(Vx),t.registerComponentView(Hx),t.registerPreprocessor((function(t){var e=t.graphic;Object(_["t"])(e)?e[0]&&e[0].elements?t.graphic=[t.graphic[0]]:t.graphic=[{elements:e}]:e&&!e.elements&&(t.graphic=[{elements:[e]}])}))}var Qx=["x","y","radius","angle","single"],Jx=["cartesian2d","polar","singleAxis"];function $x(t){var e=t.get("coordinateSystem");return Object(_["r"])(Jx,e)>=0}function tw(t){return t+"Axis"}function ew(t,e){var n,i=Object(_["f"])(),r=[],a=Object(_["f"])();t.eachComponent({mainType:"dataZoom",query:e},(function(t){a.get(t.uid)||s(t)}));do{n=!1,t.eachComponent("dataZoom",o)}while(n);function o(t){!a.get(t.uid)&&l(t)&&(s(t),n=!0)}function s(t){a.set(t.uid,!0),r.push(t),u(t)}function l(t){var e=!1;return t.eachTargetAxis((function(t,n){var r=i.get(t);r&&r[n]&&(e=!0)})),e}function u(t){t.eachTargetAxis((function(t,e){(i.get(t)||i.set(t,[]))[e]=!0}))}return r}function nw(t){var e=t.ecModel,n={infoList:[],infoMap:Object(_["f"])()};return t.eachTargetAxis((function(t,i){var r=e.getComponent(tw(t),i);if(r){var a=r.getCoordSysModel();if(a){var o=a.uid,s=n.infoMap.get(o);s||(s={model:a,axisModels:[]},n.infoList.push(s),n.infoMap.set(o,s)),s.axisModels.push(r)}}})),n}var iw=function(){function t(){this.indexList=[],this.indexMap=[]}return t.prototype.add=function(t){this.indexMap[t]||(this.indexList.push(t),this.indexMap[t]=!0)},t}(),rw=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._autoThrottle=!0,n._noTarget=!0,n._rangePropMode=["percent","percent"],n}return Object(qt["a"])(e,t),e.prototype.init=function(t,e,n){var i=aw(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this._doInit(i)},e.prototype.mergeOption=function(t){var e=aw(t);Object(_["I"])(this.option,t,!0),Object(_["I"])(this.settledOption,e,!0),this._doInit(e)},e.prototype._doInit=function(t){var e=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var n=this.settledOption;Object(_["k"])([["start","startValue"],["end","endValue"]],(function(t,i){"value"===this._rangePropMode[i]&&(e[t[0]]=n[t[0]]=null)}),this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),e=this._targetAxisInfoMap=Object(_["f"])(),n=this._fillSpecifiedTargetAxis(e);n?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(e,this._orient)),this._noTarget=!0,e.each((function(t){t.indexList.length&&(this._noTarget=!1)}),this)},e.prototype._fillSpecifiedTargetAxis=function(t){var e=!1;return Object(_["k"])(Qx,(function(n){var i=this.getReferringComponents(tw(n),Te["a"]);if(i.specified){e=!0;var r=new iw;Object(_["k"])(i.models,(function(t){r.add(t.componentIndex)})),t.set(n,r)}}),this),e},e.prototype._fillAutoTargetAxisByOrient=function(t,e){var n=this.ecModel,i=!0;if(i){var r="vertical"===e?"y":"x",a=n.findComponents({mainType:r+"Axis"});o(a,r)}if(i){a=n.findComponents({mainType:"singleAxis",filter:function(t){return t.get("orient",!0)===e}});o(a,"single")}function o(e,n){var r=e[0];if(r){var a=new iw;if(a.add(r.componentIndex),t.set(n,a),i=!1,"x"===n||"y"===n){var o=r.getReferringComponents("grid",Te["b"]).models[0];o&&Object(_["k"])(e,(function(t){r.componentIndex!==t.componentIndex&&o===t.getReferringComponents("grid",Te["b"]).models[0]&&a.add(t.componentIndex)}))}}}i&&Object(_["k"])(Qx,(function(e){if(i){var r=n.findComponents({mainType:tw(e),filter:function(t){return"category"===t.get("type",!0)}});if(r[0]){var a=new iw;a.add(r[0].componentIndex),t.set(e,a),i=!1}}}),this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis((function(e){!t&&(t=e)}),this),"y"===t?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var e=this.ecModel.option;this.option.throttle=e.animation&&e.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var e=this._rangePropMode,n=this.get("rangeMode");Object(_["k"])([["start","startValue"],["end","endValue"]],(function(i,r){var a=null!=t[i[0]],o=null!=t[i[1]];a&&!o?e[r]="percent":!a&&o?e[r]="value":n?e[r]=n[r]:a&&(e[r]="percent")}))},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis((function(e,n){null==t&&(t=this.ecModel.getComponent(tw(e),n))}),this),t},e.prototype.eachTargetAxis=function(t,e){this._targetAxisInfoMap.each((function(n,i){Object(_["k"])(n.indexList,(function(n){t.call(e,i,n)}))}))},e.prototype.getAxisProxy=function(t,e){var n=this.getAxisModel(t,e);if(n)return n.__dzAxisProxy},e.prototype.getAxisModel=function(t,e){var n=this._targetAxisInfoMap.get(t);if(n&&n.indexMap[e])return this.ecModel.getComponent(tw(t),e)},e.prototype.setRawRange=function(t){var e=this.option,n=this.settledOption;Object(_["k"])([["start","startValue"],["end","endValue"]],(function(i){null==t[i[0]]&&null==t[i[1]]||(e[i[0]]=n[i[0]]=t[i[0]],e[i[1]]=n[i[1]]=t[i[1]])}),this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var e=this.option;Object(_["k"])(["start","startValue","end","endValue"],(function(n){e[n]=t[n]}))},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},e.prototype.getValueRange=function(t,e){if(null!=t||null!=e)return this.getAxisProxy(t,e).getDataValueWindow();var n=this.findRepresentativeAxisProxy();return n?n.getDataValueWindow():void 0},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var e,n=this._targetAxisInfoMap.keys(),i=0;ia[1];if(c&&!h&&!d)return!0;c&&(r=!0),h&&(e=!0),d&&(n=!0)}return r&&e&&n}))}else pw(i,(function(n){if("empty"===r)t.setData(e=e.map(n,(function(t){return o(t)?t:NaN})));else{var i={};i[n]=a,e.selectRange(i)}}));pw(i,(function(t){e.setApproximateExtent(a,t)}))}}))}function o(t){return t>=a[0]&&t<=a[1]}},t.prototype._updateMinMaxSpan=function(){var t=this._minMaxSpan={},e=this._dataZoomModel,n=this._dataExtent;pw(["min","max"],(function(i){var r=e.get(i+"Span"),a=e.get(i+"ValueSpan");null!=a&&(a=this.getAxisModel().axis.scale.parse(a)),null!=a?r=Be["l"](n[0]+a,n,[0,100],!0):null!=r&&(a=Be["l"](r,[0,100],n,!0)-n[0]),t[i+"Span"]=r,t[i+"ValueSpan"]=a}),this)},t.prototype._setAxisModel=function(){var t=this.getAxisModel(),e=this._percentWindow,n=this._valueWindow;if(e){var i=Be["f"](n,[0,500]);i=Math.min(i,20);var r=t.axis.scale.rawExtentInfo;0!==e[0]&&r.setDeterminedMinMax("min",+n[0].toFixed(i)),100!==e[1]&&r.setDeterminedMinMax("max",+n[1].toFixed(i)),r.freeze()}},t}();function vw(t,e,n){var i=[1/0,-1/0];pw(n,(function(t){Object(sr["k"])(i,t.getData(),e)}));var r=t.getAxisModel(),a=Object(fw["a"])(r.axis.scale,r,i).calculate();return[a.min,a.max]}var yw=mw,_w={getTargetSeries:function(t){function e(e){t.eachComponent("dataZoom",(function(n){n.eachTargetAxis((function(i,r){var a=t.getComponent(tw(i),r);e(i,r,a,n)}))}))}e((function(t,e,n,i){n.__dzAxisProxy=null}));var n=[];e((function(e,i,r,a){r.__dzAxisProxy||(r.__dzAxisProxy=new yw(e,i,a,t),n.push(r.__dzAxisProxy))}));var i=Object(_["f"])();return Object(_["k"])(n,(function(t){Object(_["k"])(t.getTargetSeriesModels(),(function(t){i.set(t.uid,t)}))})),i},overallReset:function(t,e){t.eachComponent("dataZoom",(function(t){t.eachTargetAxis((function(e,n){t.getAxisProxy(e,n).reset(t)})),t.eachTargetAxis((function(n,i){t.getAxisProxy(n,i).filterData(t,e)}))})),t.eachComponent("dataZoom",(function(t){var e=t.findRepresentativeAxisProxy();if(e){var n=e.getDataPercentWindow(),i=e.getDataValueWindow();t.setCalculatedRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]})}}))}},bw=_w;function xw(t){t.registerAction("dataZoom",(function(t,e){var n=ew(e,t);Object(_["k"])(n,(function(e){e.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})}))}))}var ww=!1;function Ow(t){ww||(ww=!0,t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,bw),xw(t),t.registerSubTypeDefaulter("dataZoom",(function(){return"slider"})))}function Sw(t){t.registerComponentModel(lw),t.registerComponentView(dw),Ow(t)}var Tw=function(){function t(){}return t}(),Mw={};function Aw(t,e){Mw[t]=e}function Cw(t){return Mw[t]}var Iw=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.optionUpdated=function(){t.prototype.optionUpdated.apply(this,arguments);var e=this.ecModel;_["k"](this.option.feature,(function(t,n){var i=Cw(n);i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(e)),_["I"](t,i.defaultOption))}))},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}},e}(Xi["a"]),Dw=Iw;function Lw(t,e,n){var i=e.getBoxLayoutParams(),r=e.get("padding"),a={width:n.getWidth(),height:n.getHeight()},o=Object(ri["g"])(i,a,r);Object(ri["b"])(e.get("orient"),t,e.get("itemGap"),o.width,o.height),Object(ri["i"])(t,i,a,r)}function Ew(t,e){var n=He["j"](e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),t=new Re["a"]({shape:{x:t.x-n[3],y:t.y-n[0],width:t.width+n[1]+n[3],height:t.height+n[0]+n[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1}),t}var jw=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n,i){var r=this.group;if(r.removeAll(),t.get("show")){var a=+t.get("itemSize"),o="vertical"===t.get("orient"),s=t.get("feature")||{},l=this._features||(this._features={}),c=[];_["k"](s,(function(t,e){c.push(e)})),new Ql["a"](this._featureNames||[],c).add(h).update(h).remove(_["h"](h,null)).execute(),this._featureNames=c,Lw(r,t,n),r.add(Ew(r.getBoundingRect(),t)),o||r.eachChild((function(t){var e=t.__title,i=t.ensureState("emphasis"),o=i.textConfig||(i.textConfig={}),s=t.getTextContent(),l=s&&s.ensureState("emphasis");if(l&&!_["w"](l)&&e){var c=l.style||(l.style={}),h=u["d"](e,$["a"].makeFont(c)),d=t.x+r.x,f=t.y+r.y+a,p=!1;f+h.height>n.getHeight()&&(o.position="top",p=!0);var g=p?-5-h.height:a+10;d+h.width/2>n.getWidth()?(o.position=["100%",g],c.align="right"):d-h.width/2<0&&(o.position=[0,g],c.align="left")}}))}function h(r,a){var o,u=c[r],h=c[a],f=s[u],p=new Er["a"](f,t,t.ecModel);if(i&&null!=i.newTitle&&i.featureName===u&&(f.title=i.newTitle),u&&!h){if(Pw(u))o={onclick:p.option.onclick,featureName:u};else{var g=Cw(u);if(!g)return;o=new g}l[u]=o}else if(o=l[h],!o)return;o.uid=Object(bn["c"])("toolbox-feature"),o.model=p,o.ecModel=e,o.api=n;var m=o instanceof Tw;u||!h?!p.get("show")||m&&o.unusable?m&&o.remove&&o.remove(e,n):(d(p,o,u),p.setIconStatus=function(t,e){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[t]=e,i[t]&&("emphasis"===e?re["r"]:re["C"])(i[t])},o instanceof Tw&&o.render&&o.render(p,e,n,i)):m&&o.dispose&&o.dispose(e,n)}function d(i,s,l){var u,c,h=i.getModel("iconStyle"),d=i.getModel(["emphasis","iconStyle"]),f=s instanceof Tw&&s.getIcons?s.getIcons():i.get("icon"),p=i.get("title")||{};_["C"](f)?(u={},u[l]=f):u=f,_["C"](p)?(c={},c[l]=p):c=p;var g=i.iconPaths={};_["k"](u,(function(l,u){var f=ne["createIcon"](l,{},{x:-a/2,y:-a/2,width:a,height:a});f.setStyle(h.getItemStyle());var p=f.ensureState("emphasis");p.style=d.getItemStyle();var m=new $["a"]({style:{text:c[u],align:d.get("textAlign"),borderRadius:d.get("textBorderRadius"),padding:d.get("textPadding"),fill:null},ignore:!0});f.setTextContent(m),ne["setTooltipConfig"]({el:f,componentModel:t,itemName:u,formatterParamsExtra:{title:c[u]}}),f.__title=c[u],f.on("mouseover",(function(){var e=d.getItemStyle(),i=o?null==t.get("right")&&"right"!==t.get("left")?"right":"left":null==t.get("bottom")&&"bottom"!==t.get("top")?"bottom":"top";m.setStyle({fill:d.get("textFill")||e.fill||e.stroke||"#000",backgroundColor:d.get("textBackgroundColor")}),f.setTextConfig({position:d.get("textPosition")||i}),m.ignore=!t.get("showTitle"),n.enterEmphasis(this)})).on("mouseout",(function(){"emphasis"!==i.get(["iconStatus",u])&&n.leaveEmphasis(this),m.hide()})),("emphasis"===i.get(["iconStatus",u])?re["r"]:re["C"])(f),r.add(f),f.on("click",_["c"](s.onclick,s,e,n,u)),g[u]=f}))}},e.prototype.updateView=function(t,e,n,i){_["k"](this._features,(function(t){t instanceof Tw&&t.updateView&&t.updateView(t.model,e,n,i)}))},e.prototype.remove=function(t,e){_["k"](this._features,(function(n){n instanceof Tw&&n.remove&&n.remove(t,e)})),this.group.removeAll()},e.prototype.dispose=function(t,e){_["k"](this._features,(function(n){n instanceof Tw&&n.dispose&&n.dispose(t,e)}))},e.type="toolbox",e}(Wi["a"]);function Pw(t){return 0===t.indexOf("my")}var Nw=jw,Rw=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.onclick=function(t,e){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",r="svg"===e.getZr().painter.getType(),a=r?"svg":n.get("type",!0)||"png",o=e.getConnectedDataURL({type:a,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")}),s=L_["a"].browser;if(Object(_["w"])(MouseEvent)&&(s.newEdge||!s.ie&&!s.edge)){var l=document.createElement("a");l.download=i+"."+a,l.target="_blank",l.href=o;var u=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});l.dispatchEvent(u)}else if(window.navigator.msSaveOrOpenBlob||r){var c=o.split(","),h=c[0].indexOf("base64")>-1,d=r?decodeURIComponent(c[1]):c[1];h&&(d=window.atob(d));var f=i+"."+a;if(window.navigator.msSaveOrOpenBlob){var p=d.length,g=new Uint8Array(p);while(p--)g[p]=d.charCodeAt(p);var m=new Blob([g]);window.navigator.msSaveOrOpenBlob(m,f)}else{var v=document.createElement("iframe");document.body.appendChild(v);var y=v.contentWindow,b=y.document;b.open("image/svg+xml","replace"),b.write(d),b.close(),y.focus(),b.execCommand("SaveAs",!0,f),document.body.removeChild(v)}}else{var x=n.get("lang"),w='',O=window.open();O.document.write(w),O.document.title=i}},e.getDefaultOption=function(t){var e={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return e},e}(Tw),kw=Rw,Bw="__ec_magicType_stack__",zw=[["line","bar"],["stack"]],Vw=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return _["k"](t.get("type"),(function(t){e[t]&&(n[t]=e[t])})),n},e.getDefaultOption=function(t){var e={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return e},e.prototype.onclick=function(t,e,n){var i=this.model,r=i.get(["seriesIndex",n]);if(Fw[n]){var a,o={series:[]},s=function(t){var e=t.subType,r=t.id,a=Fw[n](e,r,t,i);a&&(_["i"](a,t.option),o.series.push(a));var s=t.coordinateSystem;if(s&&"cartesian2d"===s.type&&("line"===n||"bar"===n)){var l=s.getAxesByScale("ordinal")[0];if(l){var u=l.dim,c=u+"Axis",h=t.getReferringComponents(c,Te["b"]).models[0],d=h.componentIndex;o[c]=o[c]||[];for(var f=0;f<=d;f++)o[c][d]=o[c][d]||{};o[c][d].boundaryGap="bar"===n}}};_["k"](zw,(function(t){_["r"](t,n)>=0&&_["k"](t,(function(t){i.setIconStatus(t,"normal")}))})),i.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:null==r?null:{seriesIndex:r}},s);var l=n;"stack"===n&&(a=_["I"]({stack:i.option.title.tiled,tiled:i.option.title.stack},i.option.title),"emphasis"!==i.get(["iconStatus",n])&&(l="tiled")),e.dispatchAction({type:"changeMagicType",currentType:l,newOption:o,newTitle:a,featureName:"magicType"})}},e}(Tw),Fw={line:function(t,e,n,i){if("bar"===t)return _["I"]({id:e,type:"line",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get(["option","line"])||{},!0)},bar:function(t,e,n,i){if("line"===t)return _["I"]({id:e,type:"bar",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get(["option","bar"])||{},!0)},stack:function(t,e,n,i){var r=n.get("stack")===Bw;if("line"===t||"bar"===t)return i.setIconStatus("stack",r?"normal":"emphasis"),_["I"]({id:e,stack:r?"":Bw},i.get(["option","stack"])||{},!0)}};Xa["e"]({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},(function(t,e){e.mergeOption(t.newOption)}));var Gw=Vw,Hw=new Array(60).join("-"),Uw="\t";function Ww(t){var e={},n=[],i=[];return t.eachRawSeries((function(t){var r=t.coordinateSystem;if(!r||"cartesian2d"!==r.type&&"polar"!==r.type)n.push(t);else{var a=r.getBaseAxis();if("category"===a.type){var o=a.dim+"_"+a.index;e[o]||(e[o]={categoryAxis:a,valueAxis:r.getOtherAxis(a),series:[]},i.push({axisDim:a.dim,axisIndex:a.index})),e[o].series.push(t)}else n.push(t)}})),{seriesGroupByCategoryAxis:e,other:n,meta:i}}function Xw(t){var e=[];return _["k"](t,(function(t,n){var i=t.categoryAxis,r=t.valueAxis,a=r.dim,o=[" "].concat(_["H"](t.series,(function(t){return t.name}))),s=[i.model.getCategories()];_["k"](t.series,(function(t){var e=t.getRawData();s.push(t.getRawData().mapArray(e.mapDimension(a),(function(t){return t})))}));for(var l=[o.join(Uw)],u=0;u=0)return!0}var Qw=new RegExp("["+Uw+"]+","g");function Jw(t){for(var e=t.split(/\n+/g),n=Yw(e.shift()).split(Qw),i=[],r=_["H"](n,(function(t){return{name:t,data:[]}})),a=0;a=0;r--){var a=n[r];if(a[i])break}if(r<0){var o=t.queryComponents({mainType:"dataZoom",subType:"select",id:i})[0];if(o){var s=o.getPercentRange();n[0][i]={dataZoomId:i,start:s[0],end:s[1]}}}})),n.push(e)}function sO(t){var e=cO(t),n=e[e.length-1];e.length>1&&e.pop();var i={};return rO(n,(function(t,n){for(var r=e.length-1;r>=0;r--)if(t=e[r][n],t){i[n]=t;break}})),i}function lO(t){aO(t).snapshots=null}function uO(t){return cO(t).length}function cO(t){var e=aO(t);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var hO=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.onclick=function(t,e){lO(t),e.dispatchAction({type:"restore",from:this.uid})},e.getDefaultOption=function(t){var e={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:t.getLocaleModel().get(["toolbox","restore","title"])};return e},e}(Tw);Xa["e"]({type:"restore",event:"restore",update:"prepareAndUpdate"},(function(t,e){e.resetOption("recreate")}));var dO=hO,fO=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],pO=function(){function t(t,e,n){var i=this;this._targetInfoList=[];var r=mO(e,t);Object(_["k"])(vO,(function(t,e){(!n||!n.include||Object(_["r"])(n.include,e)>=0)&&t(r,i._targetInfoList)}))}return t.prototype.setOutputRanges=function(t,e){return this.matchOutputRanges(t,e,(function(t,e,n){if((t.coordRanges||(t.coordRanges=[])).push(e),!t.coordRange){t.coordRange=e;var i=bO[t.brushType](0,n,e);t.__rangeOffset={offset:wO[t.brushType](i.values,t.range,[1,1]),xyMinMax:i.xyMinMax}}})),t},t.prototype.matchOutputRanges=function(t,e,n){Object(_["k"])(t,(function(t){var i=this.findTargetInfo(t,e);i&&!0!==i&&Object(_["k"])(i.coordSyses,(function(i){var r=bO[t.brushType](1,i,t.range,!0);n(t,r.values,i,e)}))}),this)},t.prototype.setInputRanges=function(t,e){Object(_["k"])(t,(function(t){var n=this.findTargetInfo(t,e);if(t.range=t.range||[],n&&!0!==n){t.panelId=n.panelId;var i=bO[t.brushType](0,n.coordSys,t.coordRange),r=t.__rangeOffset;t.range=r?wO[t.brushType](i.values,r.offset,SO(i.xyMinMax,r.xyMinMax)):i.values}}),this)},t.prototype.makePanelOpts=function(t,e){return Object(_["H"])(this._targetInfoList,(function(n){var i=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:e?e(n):null,clipPath:Zf(i),isTargetByCursor:Yf(i,t,n.coordSysModel),getLinearBrushOtherExtent:qf(i)}}))},t.prototype.controlSeries=function(t,e,n){var i=this.findTargetInfo(t,n);return!0===i||i&&Object(_["r"])(i.coordSyses,e.coordinateSystem)>=0},t.prototype.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=mO(e,t),r=0;rt[1]&&t.reverse(),t}function mO(t,e){return Object(Te["s"])(t,e,{includeMainTypes:fO})}var vO={grid:function(t,e){var n=t.xAxisModels,i=t.yAxisModels,r=t.gridModels,a=Object(_["f"])(),o={},s={};(n||i||r)&&(Object(_["k"])(n,(function(t){var e=t.axis.grid.model;a.set(e.id,e),o[e.id]=!0})),Object(_["k"])(i,(function(t){var e=t.axis.grid.model;a.set(e.id,e),s[e.id]=!0})),Object(_["k"])(r,(function(t){a.set(t.id,t),o[t.id]=!0,s[t.id]=!0})),a.each((function(t){var r=t.coordinateSystem,a=[];Object(_["k"])(r.getCartesians(),(function(t,e){(Object(_["r"])(n,t.getAxis("x").model)>=0||Object(_["r"])(i,t.getAxis("y").model)>=0)&&a.push(t)})),e.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:a[0],coordSyses:a,getPanelRect:_O.grid,xAxisDeclared:o[t.id],yAxisDeclared:s[t.id]})})))},geo:function(t,e){Object(_["k"])(t.geoModels,(function(t){var n=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:n,coordSyses:[n],getPanelRect:_O.geo})}))}},yO=[function(t,e){var n=t.xAxisModel,i=t.yAxisModel,r=t.gridModel;return!r&&n&&(r=n.axis.grid.model),!r&&i&&(r=i.axis.grid.model),r&&r===e.gridModel},function(t,e){var n=t.geoModel;return n&&n===e.geoModel}],_O={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(ne["getTransform"](t)),e}},bO={lineX:Object(_["h"])(xO,0),lineY:Object(_["h"])(xO,1),rect:function(t,e,n,i){var r=t?e.pointToData([n[0][0],n[1][0]],i):e.dataToPoint([n[0][0],n[1][0]],i),a=t?e.pointToData([n[0][1],n[1][1]],i):e.dataToPoint([n[0][1],n[1][1]],i),o=[gO([r[0],a[0]]),gO([r[1],a[1]])];return{values:o,xyMinMax:o}},polygon:function(t,e,n,i){var r=[[1/0,-1/0],[1/0,-1/0]],a=Object(_["H"])(n,(function(n){var a=t?e.pointToData(n,i):e.dataToPoint(n,i);return r[0][0]=Math.min(r[0][0],a[0]),r[1][0]=Math.min(r[1][0],a[1]),r[0][1]=Math.max(r[0][1],a[0]),r[1][1]=Math.max(r[1][1],a[1]),a}));return{values:a,xyMinMax:r}}};function xO(t,e,n,i){var r=n.getAxis(["x","y"][t]),a=gO(Object(_["H"])([0,1],(function(t){return e?r.coordToData(r.toLocalCoord(i[t]),!0):r.toGlobalCoord(r.dataToCoord(i[t]))}))),o=[];return o[t]=a,o[1-t]=[NaN,NaN],{values:a,xyMinMax:o}}var wO={lineX:Object(_["h"])(OO,0),lineY:Object(_["h"])(OO,1),rect:function(t,e,n){return[[t[0][0]-n[0]*e[0][0],t[0][1]-n[0]*e[0][1]],[t[1][0]-n[1]*e[1][0],t[1][1]-n[1]*e[1][1]]]},polygon:function(t,e,n){return Object(_["H"])(t,(function(t,i){return[t[0]-n[0]*e[i][0],t[1]-n[1]*e[i][1]]}))}};function OO(t,e,n,i){return[e[0]-i[t]*n[0],e[1]-i[t]*n[1]]}function SO(t,e){var n=TO(t),i=TO(e),r=[n[0]/i[0],n[1]/i[1]];return isNaN(r[0])&&(r[0]=1),isNaN(r[1])&&(r[1]=1),r}function TO(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[NaN,NaN]}var MO=pO,AO=n("2f1f"),CO=_["k"],IO=Object(Te["p"])("toolbox-dataZoom_"),DO=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n,i){this._brushController||(this._brushController=new Xf(n.getZr()),this._brushController.on("brush",_["c"](this._onBrush,this)).mount()),PO(t,e,this,i,n),jO(t,e)},e.prototype.onclick=function(t,e,n){LO[n].call(this)},e.prototype.remove=function(t,e){this._brushController&&this._brushController.unmount()},e.prototype.dispose=function(t,e){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var e=t.areas;if(t.isEnd&&e.length){var n={},i=this.ecModel;this._brushController.updateCovers([]);var r=new MO(EO(this.model),i,{include:["grid"]});r.matchOutputRanges(e,i,(function(t,e,n){if("cartesian2d"===n.type){var i=t.brushType;"rect"===i?(a("x",n,e[0]),a("y",n,e[1])):a({lineX:"x",lineY:"y"}[i],n,e)}})),oO(i,n),this._dispatchZoomAction(n)}function a(t,e,r){var a=e.getAxis(t),s=a.model,l=o(t,s,i),u=l.findRepresentativeAxisProxy(s).getMinMaxSpan();null==u.minValueSpan&&null==u.maxValueSpan||(r=Dd(0,r.slice(),a.scale.getExtent(),0,u.minValueSpan,u.maxValueSpan)),l&&(n[l.id]={dataZoomId:l.id,startValue:r[0],endValue:r[1]})}function o(t,e,n){var i;return n.eachComponent({mainType:"dataZoom",subType:"select"},(function(n){var r=n.getAxisModel(t,e.componentIndex);r&&(i=n)})),i}},e.prototype._dispatchZoomAction=function(t){var e=[];CO(t,(function(t,n){e.push(_["d"](t))})),e.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:e})},e.getDefaultOption=function(t){var e={show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}};return e},e}(Tw),LO={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(sO(this.ecModel))}};function EO(t){var e={xAxisIndex:t.get("xAxisIndex",!0),yAxisIndex:t.get("yAxisIndex",!0),xAxisId:t.get("xAxisId",!0),yAxisId:t.get("yAxisId",!0)};return null==e.xAxisIndex&&null==e.xAxisId&&(e.xAxisIndex="all"),null==e.yAxisIndex&&null==e.yAxisId&&(e.yAxisIndex="all"),e}function jO(t,e){t.setIconStatus("back",uO(e)>1?"emphasis":"normal")}function PO(t,e,n,i,r){var a=n._isZoomActive;i&&"takeGlobalCursor"===i.type&&(a="dataZoomSelect"===i.key&&i.dataZoomSelectActive),n._isZoomActive=a,t.setIconStatus("zoom",a?"emphasis":"normal");var o=new MO(EO(t),e,{include:["grid"]}),s=o.makePanelOpts(r,(function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"}));n._brushController.setPanels(s).enableBrush(!(!a||!s.length)&&{brushType:"auto",brushStyle:t.getModel("brushStyle").getItemStyle()})}Object(AO["b"])("dataZoom",(function(t){var e=t.getComponent("toolbox",0),n=["feature","dataZoom"];if(e&&null!=e.get(n)){var i=e.getModel(n),r=[],a=EO(i),o=Object(Te["s"])(t,a);return CO(o.xAxisModels,(function(t){return s(t,"xAxis","xAxisIndex")})),CO(o.yAxisModels,(function(t){return s(t,"yAxis","yAxisIndex")})),r}function s(t,e,n){var a=t.componentIndex,o={type:"select",$fromToolbox:!0,filterMode:i.get("filterMode",!0)||"filter",id:IO+e+a};o[n]=a,r.push(o)}}));var NO=DO;function RO(t){t.registerComponentModel(Dw),t.registerComponentView(Nw),Aw("saveAsImage",kw),Aw("magicType",Gw),Aw("dataView",iO),Aw("dataZoom",NO),Aw("restore",dO),Object(i["a"])(Sw)}var kO=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),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}(Xi["a"]),BO=kO,zO=n("65ed");function VO(t){var e=t.get("confine");return null!=e?!!e:"richText"===t.get("renderMode")}function FO(t){if(L_["a"].domSupported)for(var e=document.documentElement.style,n=0,i=t.length;n-1?(l+="top:50%",u+="translateY(-50%) rotate("+(a="left"===o?-225:-45)+"deg)"):(l+="left:50%",u+="translateX(-50%) rotate("+(a="top"===o?225:45)+"deg)");var c=a*Math.PI/180,h=s+r,d=h*Math.abs(Math.cos(c))+h*Math.abs(Math.sin(c)),f=Math.round(100*((d-Math.SQRT2*r)/2+Math.SQRT2*r-(d-h)/2))/100;l+=";"+o+":-"+f+"px";var p=e+" solid "+r+"px;",g=["position:absolute;width:"+s+"px;height:"+s+"px;",l+";"+u+";","border-bottom:"+p,"border-right:"+p,"background-color:"+i+";"];return'
'}function QO(t,e){var n="cubic-bezier(0.23,1,0.32,1)",i=" "+t/2+"s "+n,r="opacity"+i+",visibility"+i;return e||(i=" "+t+"s "+n,r+=L_["a"].transformSupported?","+ZO+i:",left"+i+",top"+i),XO+":"+r}function JO(t,e,n){var i=t.toFixed(0)+"px",r=e.toFixed(0)+"px";if(!L_["a"].transformSupported)return n?"top:"+r+";left:"+i+";":[["top",r],["left",i]];var a=L_["a"].transform3dSupported,o="translate"+(a?"3d":"")+"("+i+","+r+(a?",0":"")+")";return n?"top:0;left:0;"+ZO+":"+o+";":[["top",0],["left",0],[GO,o]]}function $O(t){var e=[],n=t.get("fontSize"),i=t.getTextColor();i&&e.push("color:"+i),e.push("font:"+t.getFont()),n&&e.push("line-height:"+Math.round(3*n/2)+"px");var r=t.get("textShadowColor"),a=t.get("textShadowBlur")||0,o=t.get("textShadowOffsetX")||0,s=t.get("textShadowOffsetY")||0;return r&&a&&e.push("text-shadow:"+o+"px "+s+"px "+a+"px "+r),Object(_["k"])(["decoration","align"],(function(n){var i=t.get(n);i&&e.push("text-"+n+":"+i)})),e.join(";")}function tS(t,e,n){var i=[],r=t.get("transitionDuration"),a=t.get("backgroundColor"),o=t.get("shadowBlur"),s=t.get("shadowColor"),l=t.get("shadowOffsetX"),u=t.get("shadowOffsetY"),c=t.getModel("textStyle"),h=Object(Ma["d"])(t,"html"),d=l+"px "+u+"px "+o+"px "+s;return i.push("box-shadow:"+d),e&&r&&i.push(QO(r,n)),a&&i.push("background-color:"+a),Object(_["k"])(["width","color","radius"],(function(e){var n="border-"+e,r=Object(He["k"])(n),a=t.get(r);null!=a&&i.push(n+":"+a+("color"===e?"":"px"))})),i.push($O(c)),null!=h&&i.push("padding:"+Object(He["j"])(h).join("px ")+"px"),i.join(";")+";"}function eS(t,e,n,i,r){var a=e&&e.painter;if(n){var o=a&&a.getViewportRoot();o&&Object(zO["c"])(t,o,document.body,i,r)}else{t[0]=i,t[1]=r;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 nS=function(){function t(t,e,n){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._firstShow=!0,this._longHide=!0,L_["a"].wxa)return null;var i=document.createElement("div");i.domBelongToZr=!0,this.el=i;var r=this._zr=e.getZr(),a=this._appendToBody=n&&n.appendToBody;eS(this._styleCoord,r,a,e.getWidth()/2,e.getHeight()/2),a?document.body.appendChild(i):t.appendChild(i),this._container=t;var o=this;i.onmouseenter=function(){o._enterable&&(clearTimeout(o._hideTimeout),o._show=!0),o._inContent=!0},i.onmousemove=function(t){if(t=t||window.event,!o._enterable){var e=r.handler,n=r.painter.getViewportRoot();Object(Wa["e"])(n,t,!0),e.dispatch("mousemove",t)}},i.onmouseleave=function(){o._inContent=!1,o._enterable&&o._show&&o.hideLater(o._hideDelay)}}return t.prototype.update=function(t){var e=this._container,n=WO(e,"position"),i=e.style;"absolute"!==i.position&&"absolute"!==n&&(i.position="relative");var r=t.get("alwaysShowContent");r&&this._moveIfResized(),this.el.className=t.get("className")||""},t.prototype.show=function(t,e){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,i=n.style,r=this._styleCoord;n.innerHTML?i.cssText=qO+tS(t,!this._firstShow,this._longHide)+JO(r[0],r[1],!0)+"border-color:"+Object(He["c"])(e)+";"+(t.get("extraCssText")||"")+";pointer-events:"+(this._enterable?"auto":"none"):i.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},t.prototype.setContent=function(t,e,n,i,r){var a=this.el;if(null!=t){var o="";if(Object(_["C"])(r)&&"item"===n.get("trigger")&&!VO(n)&&(o=KO(n,i,r)),Object(_["C"])(t))a.innerHTML=t+o;else if(t){a.innerHTML="",Object(_["t"])(t)||(t=[t]);for(var s=0;s=0?this._tryShow(n,i):"leave"===t&&this._hide(i))}),this))},e.prototype._keepShow=function(){var t=this._tooltipModel,e=this._ecModel,n=this._api,i=t.get("triggerOn");if(null!=this._lastX&&null!=this._lastY&&"none"!==i&&"click"!==i){var r=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout((function(){!n.isDisposed()&&r.manuallyShowTip(t,e,n,{x:r._lastX,y:r._lastY,dataByCoordSys:r._lastDataByCoordSys})}))}},e.prototype.manuallyShowTip=function(t,e,n,i){if(i.from!==this.uid&&!L_["a"].node&&n.getDom()){var r=pS(i,n);this._ticket="";var a=i.dataByCoordSys,o=_S(i,e,n);if(o){var s=o.el.getBoundingRect().clone();s.applyTransform(o.el.transform),this._tryShow({offsetX:s.x+s.width/2,offsetY:s.y+s.height/2,target:o.el,position:i.position,positionDefault:"bottom"},r)}else if(i.tooltip&&null!=i.x&&null!=i.y){var l=hS;l.x=i.x,l.y=i.y,l.update(),Object(ie["a"])(l).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:l},r)}else if(a)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:a,tooltipOption:i.tooltipOption},r);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(t,e,n,i))return;var u=H_(i,e),c=u.point[0],h=u.point[1];null!=c&&null!=h&&this._tryShow({offsetX:c,offsetY:h,target:u.el,position:i.position,positionDefault:"bottom"},r)}else null!=i.x&&null!=i.y&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target},r))}},e.prototype.manuallyHideTip=function(t,e,n,i){var r=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(pS(i,n))},e.prototype._manuallyAxisShowTip=function(t,e,n,i){var r=i.seriesIndex,a=i.dataIndex,o=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=a&&null!=o){var s=e.getSeriesByIndex(r);if(s){var l=s.getData(),u=fS([l.getItemModel(a),s,(s.coordinateSystem||{}).model],this._tooltipModel);if("axis"===u.get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:a,position:i.position}),!0}}},e.prototype._tryShow=function(t,e){var n=t.target,i=this._tooltipModel;if(i){this._lastX=t.offsetX,this._lastY=t.offsetY;var r=t.dataByCoordSys;if(r&&r.length)this._showAxisTooltip(r,t);else if(n){var a,o;this._lastDataByCoordSys=null,Object(Zs["a"])(n,(function(t){return null!=Object(ie["a"])(t).dataIndex?(a=t,!0):null!=Object(ie["a"])(t).tooltipConfig?(o=t,!0):void 0}),!0),a?this._showSeriesItemTooltip(t,a,e):o?this._showComponentItemTooltip(t,o,e):this._hide(e)}else this._lastDataByCoordSys=null,this._hide(e)}},e.prototype._showOrMove=function(t,e){var n=t.get("showDelay");e=Object(_["c"])(e,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(e,n):e()},e.prototype._showAxisTooltip=function(t,e){var n=this._ecModel,i=this._tooltipModel,r=[e.offsetX,e.offsetY],a=fS([e.tooltipOption],i),o=this._renderMode,s=[],l=Object(Ma["c"])("section",{blocks:[],noHeader:!0}),u=[],c=new Ma["a"];Object(_["k"])(t,(function(t){Object(_["k"])(t.dataByAxis,(function(t){var e=n.getComponent(t.axisDim+"Axis",t.axisIndex),r=t.value;if(e&&null!=r){var a=y_(r,e.axis,n,t.seriesDataIndices,t.valueLabelOpt),h=Object(Ma["c"])("section",{header:a,noHeader:!Object(_["T"])(a),sortBlocks:!0,blocks:[]});l.blocks.push(h),Object(_["k"])(t.seriesDataIndices,(function(l){var d=n.getSeriesByIndex(l.seriesIndex),f=l.dataIndexInside,p=d.getDataParams(f);if(!(p.dataIndex<0)){p.axisDim=t.axisDim,p.axisIndex=t.axisIndex,p.axisType=t.axisType,p.axisId=t.axisId,p.axisValue=sr["c"](e.axis,{value:r}),p.axisValueLabel=a,p.marker=c.makeTooltipMarker("item",Object(He["c"])(p.color),o);var g=Object(cS["b"])(d.formatTooltip(f,!0,null)),m=g.frag;if(m){var v=fS([d],i).get("valueFormatter");h.blocks.push(v?Object(_["m"])({valueFormatter:v},m):m)}g.text&&u.push(g.text),s.push(p)}}))}}))})),l.blocks.reverse(),u.reverse();var h=e.position,d=a.get("order"),f=Object(Ma["b"])(l,c,o,d,n.get("useUTC"),a.get("textStyle"));f&&u.unshift(f);var p="richText"===o?"\n\n":"
",g=u.join(p);this._showOrMove(a,(function(){this._updateContentNotChangedOnAxis(t,s)?this._updatePosition(a,h,r[0],r[1],this._tooltipContent,s):this._showTooltipContent(a,g,s,Math.random()+"",r[0],r[1],h,null,c)}))},e.prototype._showSeriesItemTooltip=function(t,e,n){var i=this._ecModel,r=Object(ie["a"])(e),a=r.seriesIndex,o=i.getSeriesByIndex(a),s=r.dataModel||o,l=r.dataIndex,u=r.dataType,c=s.getData(u),h=this._renderMode,d=t.positionDefault,f=fS([c.getItemModel(l),s,o&&(o.coordinateSystem||{}).model],this._tooltipModel,d?{position:d}:null),p=f.get("trigger");if(null==p||"item"===p){var g=s.getDataParams(l,u),m=new Ma["a"];g.marker=m.makeTooltipMarker("item",Object(He["c"])(g.color),h);var v=Object(cS["b"])(s.formatTooltip(l,!1,u)),y=f.get("order"),b=f.get("valueFormatter"),x=v.frag,w=x?Object(Ma["b"])(b?Object(_["m"])({valueFormatter:b},x):x,m,h,y,i.get("useUTC"),f.get("textStyle")):v.text,O="item_"+s.name+"_"+l;this._showOrMove(f,(function(){this._showTooltipContent(f,w,g,O,t.offsetX,t.offsetY,t.position,t.target,m)})),n({type:"showTip",dataIndexInside:l,dataIndex:c.getRawIndex(l),seriesIndex:a,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,e,n){var i=Object(ie["a"])(e),r=i.tooltipConfig,a=r.option||{};if(Object(_["C"])(a)){var o=a;a={content:o,formatter:o}}var s=[a],l=this._ecModel.getComponent(i.componentMainType,i.componentIndex);l&&s.push(l),s.push({formatter:a.content});var u=t.positionDefault,c=fS(s,this._tooltipModel,u?{position:u}:null),h=c.get("content"),d=Math.random()+"",f=new Ma["a"];this._showOrMove(c,(function(){var n=Object(_["d"])(c.get("formatterParams")||{});this._showTooltipContent(c,h,n,d,t.offsetX,t.offsetY,t.position,e,f)})),n({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,e,n,i,r,a,o,s,l){if(this._ticket="",t.get("showContent")&&t.get("show")){var u=this._tooltipContent;u.setEnterable(t.get("enterable"));var c=t.get("formatter");o=o||t.get("position");var h=e,d=this._getNearestPoint([r,a],n,t.get("trigger"),t.get("borderColor")),f=d.color;if(c)if(Object(_["C"])(c)){var p=t.ecModel.get("useUTC"),g=Object(_["t"])(n)?n[0]:n,m=g&&g.axisType&&g.axisType.indexOf("time")>=0;h=c,m&&(h=Object(uS["h"])(g.axisValue,h,p)),h=Object(He["f"])(h,n,!0)}else if(Object(_["w"])(c)){var v=Object(_["c"])((function(e,i){e===this._ticket&&(u.setContent(i,l,t,f,o),this._updatePosition(t,o,r,a,u,n,s))}),this);this._ticket=i,h=c(n,i,v)}else h=c;u.setContent(h,l,t,f,o),u.show(t,f),this._updatePosition(t,o,r,a,u,n,s)}},e.prototype._getNearestPoint=function(t,e,n,i){return"axis"===n||Object(_["t"])(e)?{color:i||("html"===this._renderMode?"#fff":"none")}:Object(_["t"])(e)?void 0:{color:i||e.color||e.borderColor}},e.prototype._updatePosition=function(t,e,n,i,r,a,o){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var u=r.getSize(),c=t.get("align"),h=t.get("verticalAlign"),d=o&&o.getBoundingRect().clone();if(o&&d.applyTransform(o.transform),Object(_["w"])(e)&&(e=e([n,i],a,r.el,d,{viewSize:[s,l],contentSize:u.slice()})),Object(_["t"])(e))n=Object(Be["p"])(e[0],s),i=Object(Be["p"])(e[1],l);else if(Object(_["A"])(e)){var f=e;f.width=u[0],f.height=u[1];var p=Object(ri["g"])(f,{width:s,height:l});n=p.x,i=p.y,c=null,h=null}else if(Object(_["C"])(e)&&o){var g=vS(e,d,u,t.get("borderWidth"));n=g[0],i=g[1]}else{g=gS(n,i,r,s,l,c?null:20,h?null:20);n=g[0],i=g[1]}if(c&&(n-=yS(c)?u[0]/2:"right"===c?u[0]:0),h&&(i-=yS(h)?u[1]/2:"bottom"===h?u[1]:0),VO(t)){g=mS(n,i,r,s,l);n=g[0],i=g[1]}r.moveTo(n,i)},e.prototype._updateContentNotChangedOnAxis=function(t,e){var n=this._lastDataByCoordSys,i=this._cbParamsList,r=!!n&&n.length===t.length;return r&&Object(_["k"])(n,(function(n,a){var o=n.dataByAxis||[],s=t[a]||{},l=s.dataByAxis||[];r=r&&o.length===l.length,r&&Object(_["k"])(o,(function(t,n){var a=l[n]||{},o=t.seriesDataIndices||[],s=a.seriesDataIndices||[];r=r&&t.value===a.value&&t.axisType===a.axisType&&t.axisId===a.axisId&&o.length===s.length,r&&Object(_["k"])(o,(function(t,e){var n=s[e];r=r&&t.seriesIndex===n.seriesIndex&&t.dataIndex===n.dataIndex})),i&&Object(_["k"])(t.seriesDataIndices,(function(t){var n=t.seriesIndex,a=e[n],o=i[n];a&&o&&o.data!==a.data&&(r=!1)}))}))})),this._lastDataByCoordSys=t,this._cbParamsList=e,!!r},e.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,e){!L_["a"].node&&e.getDom()&&(Object(On["a"])(this,"_updatePosition"),this._tooltipContent.dispose(),V_("itemTooltip",e))},e.type="tooltip",e}(Wi["a"]);function fS(t,e,n){var i,r=e.ecModel;n?(i=new Er["a"](n,r,r),i=new Er["a"](e.option,i,r)):i=e;for(var a=t.length-1;a>=0;a--){var o=t[a];o&&(o instanceof Er["a"]&&(o=o.get("tooltip",!0)),Object(_["C"])(o)&&(o={formatter:o}),o&&(i=new Er["a"](o,i,r)))}return i}function pS(t,e){return t.dispatchAction||Object(_["c"])(e.dispatchAction,e)}function gS(t,e,n,i,r,a,o){var s=n.getSize(),l=s[0],u=s[1];return null!=a&&(t+l+a+2>i?t-=l+a:t+=a),null!=o&&(e+u+o>r?e-=u+o:e+=o),[t,e]}function mS(t,e,n,i,r){var a=n.getSize(),o=a[0],s=a[1];return t=Math.min(t+o,i)-o,e=Math.min(e+s,r)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}function vS(t,e,n,i){var r=n[0],a=n[1],o=Math.ceil(Math.SQRT2*i)+8,s=0,l=0,u=e.width,c=e.height;switch(t){case"inside":s=e.x+u/2-r/2,l=e.y+c/2-a/2;break;case"top":s=e.x+u/2-r/2,l=e.y-a-o;break;case"bottom":s=e.x+u/2-r/2,l=e.y+c+o;break;case"left":s=e.x-r-o,l=e.y+c/2-a/2;break;case"right":s=e.x+u+o,l=e.y+c/2-a/2}return[s,l]}function yS(t){return"center"===t||"middle"===t}function _S(t,e,n){var i=Object(Te["t"])(t).queryOptionMap,r=i.keys()[0];if(r&&"series"!==r){var a=Object(Te["v"])(e,r,i.get(r),{useDefault:!1,enableAll:!1,enableNone:!1}),o=a.models[0];if(o){var s,l=n.getViewOfComponentModel(o);return l.group.traverse((function(e){var n=Object(ie["a"])(e).tooltipConfig;if(n&&n.name===t.name)return s=e,!0})),s?{componentMainType:r,componentIndex:o.componentIndex,el:s}:void 0}}}var bS=dS;function xS(t){Object(i["a"])(nb),t.registerComponentModel(BO),t.registerComponentView(bS),t.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},_["L"]),t.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},_["L"])}var wS=["rect","polygon","keep","clear"];function OS(t,e){var n=Object(Te["r"])(t?t.brush:[]);if(n.length){var i=[];_["k"](n,(function(t){var e=t.hasOwnProperty("toolbox")?t.toolbox:[];e instanceof Array&&(i=i.concat(e))}));var r=t&&t.toolbox;_["t"](r)&&(r=r[0]),r||(r={feature:{}},t.toolbox=[r]);var a=r.feature||(r.feature={}),o=a.brush||(a.brush={}),s=o.type||(o.type=[]);s.push.apply(s,i),SS(s),e&&!s.length&&s.push.apply(s,wS)}}function SS(t){var e={};_["k"](t,(function(t){e[t]=1})),t.length=0,_["k"](e,(function(e,n){t.push(n)}))}var TS=n("0924"),MS=_["k"];function AS(t){if(t)for(var e in t)if(t.hasOwnProperty(e))return!0}function CS(t,e,n){var i={};return MS(e,(function(e){var a=i[e]=r();MS(t[e],(function(t,i){if(Gu.isValidType(i)){var r={type:i,visual:t};n&&n(r,e),a[i]=new Gu(r),"opacity"===i&&(r=_["d"](r),r.type="colorAlpha",a.__hidden.__alphaForOpacity=new Gu(r))}}))})),i;function r(){var t=function(){};t.prototype.__hidden=t.prototype;var e=new t;return e}}function IS(t,e,n){var i;_["k"](n,(function(t){e.hasOwnProperty(t)&&AS(e[t])&&(i=!0)})),i&&_["k"](n,(function(n){e.hasOwnProperty(n)&&AS(e[n])?t[n]=_["d"](e[n]):delete t[n]}))}function DS(t,e,n,i,r,a){var o,s={};function l(t){return Object(TS["a"])(n,o,t)}function u(t,e){Object(TS["c"])(n,o,t,e)}function c(t,c){o=null==a?t:c;var h=n.getRawDataItem(o);if(!h||!1!==h.visualMap)for(var d=i.call(r,t),f=e[d],p=s[d],g=0,m=p.length;ge[0][1]&&(e[0][1]=a[0]),a[1]e[1][1]&&(e[1][1]=a[1])}return e&&ZS(e)}};function ZS(t){return new ki["a"](t[0][0],t[1][0],t[0][1]-t[0][0],t[1][1]-t[1][0])}var qS=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(t,e){this.ecModel=t,this.api=e,this.model,(this._brushController=new Xf(e.getZr())).on("brush",_["c"](this._onBrush,this)).mount()},e.prototype.render=function(t,e,n,i){this.model=t,this._updateController(t,e,n,i)},e.prototype.updateTransform=function(t,e,n,i){VS(e),this._updateController(t,e,n,i)},e.prototype.updateVisual=function(t,e,n,i){this.updateTransform(t,e,n,i)},e.prototype.updateView=function(t,e,n,i){this._updateController(t,e,n,i)},e.prototype._updateController=function(t,e,n,i){(!i||i.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(n)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var e=this.model.id,n=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:e,areas:_["d"](n),$from:e}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:e,areas:_["d"](n),$from:e})},e.type="brush",e}(Wi["a"]),YS=qS,KS="#ddd",QS=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.areas=[],n.brushOption={},n}return Object(qt["a"])(e,t),e.prototype.optionUpdated=function(t,e){var n=this.option;!e&&IS(n,t,["inBrush","outOfBrush"]);var i=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:KS},i.hasOwnProperty("liftZ")||(i.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=_["H"](t,(function(t){return JS(this.option,t)}),this))},e.prototype.setBrushOption=function(t){this.brushOption=JS(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},e}(Xi["a"]);function JS(t,e){return _["I"]({brushType:t.brushType,brushMode:t.brushMode,transformable:t.transformable,brushStyle:new Er["a"](t.brushStyle).getItemStyle(),removeOnClick:t.removeOnClick,z:t.z},e,!0)}var $S=QS,tT=["rect","polygon","lineX","lineY","keep","clear"],eT=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){var i,r,a;e.eachComponent({mainType:"brush"},(function(t){i=t.brushType,r=t.brushOption.brushMode||"single",a=a||!!t.areas.length})),this._brushType=i,this._brushMode=r,_["k"](t.get("type",!0),(function(e){t.setIconStatus(e,("keep"===e?"multiple"===r:"clear"===e?a:e===i)?"emphasis":"normal")}))},e.prototype.updateView=function(t,e,n){this.render(t,e,n)},e.prototype.getIcons=function(){var t=this.model,e=t.get("icon",!0),n={};return _["k"](t.get("type",!0),(function(t){e[t]&&(n[t]=e[t])})),n},e.prototype.onclick=function(t,e,n){var i=this._brushType,r=this._brushMode;"clear"===n?(e.dispatchAction({type:"axisAreaSelect",intervals:[]}),e.dispatchAction({type:"brush",command:"clear",areas:[]})):e.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:"keep"===n?i:i!==n&&n,brushMode:"keep"===n?"multiple"===r?"single":"multiple":r}})},e.getDefaultOption=function(t){var e={show:!0,type:tT.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])};return e},e}(Tw),nT=eT;function iT(t){t.registerComponentView(YS),t.registerComponentModel($S),t.registerPreprocessor(OS),t.registerVisual(t.PRIORITY.VISUAL.BRUSH,FS),t.registerAction({type:"brush",event:"brush",update:"updateVisual"},(function(t,e){e.eachComponent({mainType:"brush",query:t},(function(e){e.setAreas(t.areas)}))})),t.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},_["L"]),t.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},_["L"]),Aw("brush",nT)}var rT=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.layoutMode={type:"box",ignoreSize:!0},n}return Object(qt["a"])(e,t),e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}},e}(Xi["a"]),aT=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.render=function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),a=t.getModel("subtextStyle"),o=t.get("textAlign"),s=_["P"](t.get("textBaseline"),t.get("textVerticalAlign")),l=new $["a"]({style:Object(le["c"])(r,{text:t.get("text"),fill:r.getTextColor()},{disableBox:!0}),z2:10}),u=l.getBoundingRect(),c=t.get("subtext"),h=new $["a"]({style:Object(le["c"])(a,{text:c,fill:a.getTextColor(),y:u.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),f=t.get("sublink"),p=t.get("triggerEvent",!0);l.silent=!d&&!p,h.silent=!f&&!p,d&&l.on("click",(function(){Object(He["l"])(d,"_"+t.get("target"))})),f&&h.on("click",(function(){Object(He["l"])(f,"_"+t.get("subtarget"))})),Object(ie["a"])(l).eventData=Object(ie["a"])(h).eventData=p?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(l),c&&i.add(h);var g=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=g.width,m.height=g.height;var v=Object(ri["g"])(m,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));o||(o=t.get("left")||t.get("right"),"middle"===o&&(o="center"),"right"===o?v.x+=v.width:"center"===o&&(v.x+=v.width/2)),s||(s=t.get("top")||t.get("bottom"),"center"===s&&(s="middle"),"bottom"===s?v.y+=v.height:"middle"===s&&(v.y+=v.height/2),s=s||"top"),i.x=v.x,i.y=v.y,i.markRedraw();var y={align:o,verticalAlign:s};l.setStyle(y),h.setStyle(y),g=i.getBoundingRect();var b=v.margin,x=t.getItemStyle(["color","opacity"]);x.fill=t.get("backgroundColor");var w=new Re["a"]({shape:{x:g.x-b[3],y:g.y-b[0],width:g.width+b[1]+b[3],height:g.height+b[0]+b[2],r:t.get("borderRadius")},style:x,subPixelOptimize:!0,silent:!0});i.add(w)}},e.type="title",e}(Wi["a"]);function oT(t){t.registerComponentModel(rT),t.registerComponentView(aT)}var sT=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.layoutMode="box",n}return Object(qt["a"])(e,t),e.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),this._initData()},e.prototype.mergeOption=function(e){t.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){null==t&&(t=this.option.currentIndex);var e=this._data.count();this.option.loop?t=(t%e+e)%e:(t>=e&&(t=e-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t,e=this.option,n=e.data||[],i=e.axisType,r=this._names=[];"category"===i?(t=[],Object(_["k"])(n,(function(e,n){var i,a=Object(Te["e"])(Object(Te["h"])(e),"");Object(_["A"])(e)?(i=Object(_["d"])(e),i.value=n):i=n,t.push(i),r.push(a)}))):t=n;var a={category:"ordinal",time:"time",value:"number"}[i]||"number",o=this._data=new Mi["a"]([{name:"value",type:a}],this);o.initData(t,r)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if("category"===this.get("axisType"))return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},e}(Xi["a"]),lT=sT,uT=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="timeline.slider",e.defaultOption=Object(bn["d"])(lT.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),e}(lT);Object(_["K"])(uT,cS["a"].prototype);var cT=uT,hT=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="timeline",e}(Wi["a"]),dT=hT,fT=function(t){function e(e,n,i,r){var a=t.call(this,e,n,i)||this;return a.type=r||"value",a}return Object(qt["a"])(e,t),e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return"horizontal"===this.model.get("orient")},e}(gr["a"]),pT=fT,gT=n("18c0"),mT=n("216a"),vT=Math.PI,yT=Object(Te["o"])(),_T=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(t,e){this.api=e},e.prototype.render=function(t,e,n){if(this.model=t,this.api=n,this.ecModel=e,this.group.removeAll(),t.get("show",!0)){var i=this._layout(t,n),r=this._createGroup("_mainGroup"),a=this._createGroup("_labelGroup"),o=this._axis=this._createAxis(i,t);t.formatTooltip=function(t){var e=o.scale.getLabel({value:t});return Object(Ma["c"])("nameValue",{noName:!0,value:e})},Object(_["k"])(["AxisLine","AxisTick","Control","CurrentPointer"],(function(e){this["_render"+e](i,r,o,t)}),this),this._renderAxisLabel(i,a,o,t),this._position(i,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,e){var n,i=t.get(["label","position"]),r=t.get("orient"),a=xT(t,e);n=null==i||"auto"===i?"horizontal"===r?a.y+a.height/2=0||"+"===n?"left":"right"},c={horizontal:n>=0||"+"===n?"top":"bottom",vertical:"middle"},h={horizontal:0,vertical:vT/2},d="vertical"===r?a.height:a.width,f=t.getModel("controlStyle"),p=f.get("show",!0),g=p?f.get("itemSize"):0,m=p?f.get("itemGap"):0,v=g+m,y=t.get(["label","rotate"])||0;y=y*vT/180;var b=f.get("position",!0),x=p&&f.get("showPlayBtn",!0),w=p&&f.get("showPrevBtn",!0),O=p&&f.get("showNextBtn",!0),S=0,T=d;"left"===b||"bottom"===b?(x&&(o=[0,0],S+=v),w&&(s=[S,0],S+=v),O&&(l=[T-g,0],T-=v)):(x&&(o=[T-g,0],T-=v),w&&(s=[0,0],S+=v),O&&(l=[T-g,0],T-=v));var M=[S,T];return t.get("inverse")&&M.reverse(),{viewRect:a,mainLength:d,orient:r,rotation:h[r],labelRotation:y,labelPosOpt:n,labelAlign:t.get(["label","align"])||u[r],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||c[r],playPosition:o,prevBtnPosition:s,nextBtnPosition:l,axisExtent:M,controlSize:g,controlGap:m}},e.prototype._position=function(t,e){var n=this._mainGroup,i=this._labelGroup,r=t.viewRect;if("vertical"===t.orient){var a=ur["c"](),o=r.x,s=r.y+r.height;ur["i"](a,a,[-o,-s]),ur["g"](a,a,-vT/2),ur["i"](a,a,[o,s]),r=r.clone(),r.applyTransform(a)}var l=m(r),u=m(n.getBoundingRect()),c=m(i.getBoundingRect()),h=[n.x,n.y],d=[i.x,i.y];d[0]=h[0]=l[0][0];var f=t.labelPosOpt;if(null==f||Object(_["C"])(f)){var p="+"===f?0:1;v(h,u,l,1,p),v(d,c,l,1,1-p)}else{p=f>=0?0:1;v(h,u,l,1,p),d[1]=h[1]+f}function g(t){t.originX=l[0][0]-t.x,t.originY=l[1][0]-t.y}function m(t){return[[t.x,t.x+t.width],[t.y,t.y+t.height]]}function v(t,e,n,i,r){t[i]+=n[i][r]-e[i][r]}n.setPosition(h),i.setPosition(d),n.rotation=i.rotation=t.rotation,g(n),g(i)},e.prototype._createAxis=function(t,e){var n=e.getData(),i=e.get("axisType"),r=bT(e,i);r.getTicks=function(){return n.mapArray(["value"],(function(t){return{value:t}}))};var a=n.getDataExtent("value");r.setExtent(a[0],a[1]),r.calcNiceTicks();var o=new pT("value",r,t.axisExtent,i);return o.model=e,o},e.prototype._createGroup=function(t){var e=this[t]=new Jt["a"];return this.group.add(e),e},e.prototype._renderAxisLine=function(t,e,n,i){var r=n.getExtent();if(i.get(["lineStyle","show"])){var a=new Lr["a"]({shape:{x1:r[0],y1:0,x2:r[1],y2:0},style:Object(_["m"])({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});e.add(a);var o=this._progressLine=new Lr["a"]({shape:{x1:r[0],x2:this._currentPointer?this._currentPointer.x:r[0],y1:0,y2:0},style:Object(_["i"])({lineCap:"round",lineWidth:a.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});e.add(o)}},e.prototype._renderAxisTick=function(t,e,n,i){var r=this,a=i.getData(),o=n.scale.getTicks();this._tickSymbols=[],Object(_["k"])(o,(function(t){var o=n.dataToCoord(t.value),s=a.getItemModel(t.value),l=s.getModel("itemStyle"),u=s.getModel(["emphasis","itemStyle"]),c=s.getModel(["progress","itemStyle"]),h={x:o,y:0,onclick:Object(_["c"])(r._changeTimeline,r,t.value)},d=OT(s,l,e,h);d.ensureState("emphasis").style=u.getItemStyle(),d.ensureState("progress").style=c.getItemStyle(),Object(re["o"])(d);var f=Object(ie["a"])(d);s.get("tooltip")?(f.dataIndex=t.value,f.dataModel=i):f.dataIndex=f.dataModel=null,r._tickSymbols.push(d)}))},e.prototype._renderAxisLabel=function(t,e,n,i){var r=this,a=n.getLabelModel();if(a.get("show")){var o=i.getData(),s=n.getViewLabels();this._tickLabels=[],Object(_["k"])(s,(function(i){var a=i.tickValue,s=o.getItemModel(a),l=s.getModel("label"),u=s.getModel(["emphasis","label"]),c=s.getModel(["progress","label"]),h=n.dataToCoord(i.tickValue),d=new $["a"]({x:h,y:0,rotation:t.labelRotation-t.rotation,onclick:Object(_["c"])(r._changeTimeline,r,a),silent:!1,style:Object(le["c"])(l,{text:i.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});d.ensureState("emphasis").style=Object(le["c"])(u),d.ensureState("progress").style=Object(le["c"])(c),e.add(d),Object(re["o"])(d),yT(d).dataIndex=a,r._tickLabels.push(d)}))}},e.prototype._renderControl=function(t,e,n,i){var r=t.controlSize,a=t.rotation,o=i.getModel("controlStyle").getItemStyle(),s=i.getModel(["emphasis","controlStyle"]).getItemStyle(),l=i.getPlayState(),c=i.get("inverse",!0);function h(t,n,l,c){if(t){var h=Object(u["g"])(Object(_["P"])(i.get(["controlStyle",n+"BtnSize"]),r),r),d=[0,-h/2,h,h],f=wT(i,n+"Icon",d,{x:t[0],y:t[1],originX:r/2,originY:0,rotation:c?-a:0,rectHover:!0,style:o,onclick:l});f.ensureState("emphasis").style=s,e.add(f),Object(re["o"])(f)}}h(t.nextBtnPosition,"next",Object(_["c"])(this._changeTimeline,this,c?"-":"+")),h(t.prevBtnPosition,"prev",Object(_["c"])(this._changeTimeline,this,c?"+":"-")),h(t.playPosition,l?"stop":"play",Object(_["c"])(this._handlePlayClick,this,!l),!0)},e.prototype._renderCurrentPointer=function(t,e,n,i){var r=i.getData(),a=i.getCurrentIndex(),o=r.getItemModel(a).getModel("checkpointStyle"),s=this,l={onCreate:function(t){t.draggable=!0,t.drift=Object(_["c"])(s._handlePointerDrag,s),t.ondragend=Object(_["c"])(s._handlePointerDragend,s),ST(t,s._progressLine,a,n,i,!0)},onUpdate:function(t){ST(t,s._progressLine,a,n,i)}};this._currentPointer=OT(o,o,this._mainGroup,{},this._currentPointer,l)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,e,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,e){var n=this._toAxisCoord(t)[0],i=this._axis,r=Be["c"](i.getExtent().slice());n>r[1]&&(n=r[1]),n=0&&(o[a]=+o[a].toFixed(d)),[o,h]}var HT={min:Object(_["h"])(GT,"min"),max:Object(_["h"])(GT,"max"),average:Object(_["h"])(GT,"average"),median:Object(_["h"])(GT,"median")};function UT(t,e){var n=t.getData(),i=t.coordinateSystem;if(e&&!FT(e)&&!Object(_["t"])(e.coord)&&i){var r=i.dimensions,a=WT(e,n,i,t);if(e=Object(_["d"])(e),e.type&&HT[e.type]&&a.baseAxis&&a.valueAxis){var o=Object(_["r"])(r,a.baseAxis.dim),s=Object(_["r"])(r,a.valueAxis.dim),l=HT[e.type](n,a.baseDataDim,a.valueDataDim,o,s);e.coord=l[0],e.value=l[1]}else{for(var u=[null!=e.xAxis?e.xAxis:e.radiusAxis,null!=e.yAxis?e.yAxis:e.angleAxis],c=0;c<2;c++)HT[u[c]]&&(u[c]=KT(n,n.mapDimension(r[c]),u[c]));e.coord=u}}return e}function WT(t,e,n,i){var r={};return null!=t.valueIndex||null!=t.valueDim?(r.valueDataDim=null!=t.valueIndex?e.getDimension(t.valueIndex):t.valueDim,r.valueAxis=n.getAxis(XT(i,r.valueDataDim)),r.baseAxis=n.getOtherAxis(r.valueAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim)):(r.baseAxis=i.getBaseAxis(),r.valueAxis=n.getOtherAxis(r.baseAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim),r.valueDataDim=e.mapDimension(r.valueAxis.dim)),r}function XT(t,e){var n=t.getData().getDimensionInfo(e);return n&&n.coordDim}function ZT(t,e){return!(t&&t.containData&&e.coord&&!VT(e))||t.containData(e.coord)}function qT(t,e,n){return!(t&&t.containZone&&e.coord&&n.coord&&!VT(e)&&!VT(n))||t.containZone(e.coord,n.coord)}function YT(t,e){return t?function(t,n,i,r){var a=r<2?t.coord&&t.coord[r]:t.value;return Object(zT["d"])(a,e[r])}:function(t,n,i,r){return Object(zT["d"])(t.value,e[r])}}function KT(t,e,n){if("average"===n){var i=0,r=0;return t.each(e,(function(t,e){isNaN(t)||(i+=t,r++)})),i/r}return"median"===n?t.getMedian(e):t.getDataExtent(e)["max"===n?1:0]}var QT=Object(Te["o"])(),JT=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.init=function(){this.markerGroupMap=Object(_["f"])()},e.prototype.render=function(t,e,n){var i=this,r=this.markerGroupMap;r.each((function(t){QT(t).keep=!1})),e.eachSeries((function(t){var r=RT.getMarkerModelFromSeries(t,i.type);r&&i.renderSeries(t,r,e,n)})),r.each((function(t){!QT(t).keep&&i.group.remove(t.group)}))},e.prototype.markKeep=function(t){QT(t).keep=!0},e.prototype.toggleBlurSeries=function(t,e){var n=this;Object(_["k"])(t,(function(t){var i=RT.getMarkerModelFromSeries(t,n.type);if(i){var r=i.getData();r.eachItemGraphicEl((function(t){t&&(e?Object(re["q"])(t):Object(re["B"])(t))}))}}))},e.type="marker",e}(Wi["a"]),$T=JT;function tM(t,e,n){var i=e.coordinateSystem;t.each((function(r){var a,o=t.getItemModel(r),s=Be["p"](o.get("x"),n.getWidth()),l=Be["p"](o.get("y"),n.getHeight());if(isNaN(s)||isNaN(l)){if(e.getMarkerPosition)a=e.getMarkerPosition(t.getValues(t.dimensions,r));else if(i){var u=t.get(i.dimensions[0],r),c=t.get(i.dimensions[1],r);a=i.dataToPoint([u,c])}}else a=[s,l];isNaN(s)||(a[0]=s),isNaN(l)||(a[1]=l),t.setItemLayout(r,a)}))}var eM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.updateTransform=function(t,e,n){e.eachSeries((function(t){var e=RT.getMarkerModelFromSeries(t,"markPoint");e&&(tM(e.getData(),t,n),this.markerGroupMap.get(t.id).updateLayout())}),this)},e.prototype.renderSeries=function(t,e,n,i){var r=t.coordinateSystem,a=t.id,o=t.getData(),s=this.markerGroupMap,l=s.get(a)||s.set(a,new me),u=nM(r,t,e);e.setData(u),tM(e.getData(),t,i),u.each((function(t){var n=u.getItemModel(t),i=n.getShallow("symbol"),r=n.getShallow("symbolSize"),a=n.getShallow("symbolRotate"),s=n.getShallow("symbolOffset"),l=n.getShallow("symbolKeepAspect");if(Object(_["w"])(i)||Object(_["w"])(r)||Object(_["w"])(a)||Object(_["w"])(s)){var c=e.getRawValue(t),h=e.getDataParams(t);Object(_["w"])(i)&&(i=i(c,h)),Object(_["w"])(r)&&(r=r(c,h)),Object(_["w"])(a)&&(a=a(c,h)),Object(_["w"])(s)&&(s=s(c,h))}var d=n.getModel("itemStyle").getItemStyle(),f=Object(TS["b"])(o,"color");d.fill||(d.fill=f),u.setItemVisual(t,{symbol:i,symbolSize:r,symbolRotate:a,symbolOffset:s,symbolKeepAspect:l,style:d})})),l.updateData(u),this.group.add(l.group),u.eachItemGraphicEl((function(t){t.traverse((function(t){Object(ie["a"])(t).dataModel=e}))})),this.markKeep(l),l.group.silent=e.get("silent")||t.get("silent")},e.type="markPoint",e}($T);function nM(t,e,n){var i;i=t?Object(_["H"])(t&&t.dimensions,(function(t){var n=e.getData().getDimensionInfo(e.getData().mapDimension(t))||{};return Object(_["m"])(Object(_["m"])({},n),{name:t,ordinalMeta:null})})):[{name:"value",type:"float"}];var r=new Mi["a"](i,n),a=Object(_["H"])(n.get("data"),Object(_["h"])(UT,e));t&&(a=Object(_["n"])(a,Object(_["h"])(ZT,t)));var o=YT(!!t,i);return r.initData(a,null,o),r}var iM=eM;function rM(t){t.registerComponentModel(BT),t.registerComponentView(iM),t.registerPreprocessor((function(t){ET(t.series,"markPoint")&&(t.markPoint=t.markPoint||{})}))}var aM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.createMarkerModelFromSeries=function(t,n,i){return new e(t,n,i)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e}(RT),oM=aM,sM=Object(Te["o"])(),lM=function(t,e,n,i){var r,a=t.getData();if(Object(_["t"])(i))r=i;else{var o=i.type;if("min"===o||"max"===o||"average"===o||"median"===o||null!=i.xAxis||null!=i.yAxis){var s=void 0,l=void 0;if(null!=i.yAxis||null!=i.xAxis)s=e.getAxis(null!=i.yAxis?"y":"x"),l=Object(_["O"])(i.yAxis,i.xAxis);else{var u=WT(i,a,e,t);s=u.valueAxis;var c=Object(ve["b"])(a,u.valueDataDim);l=KT(a,c,o)}var h="x"===s.dim?0:1,d=1-h,f=Object(_["d"])(i),p={coord:[]};f.type=null,f.coord=[],f.coord[d]=-1/0,p.coord[d]=1/0;var g=n.get("precision");g>=0&&Object(_["z"])(l)&&(l=+l.toFixed(Math.min(g,20))),f.coord[h]=p.coord[h]=l,r=[f,p,{type:o,valueIndex:i.valueIndex,value:l}]}else r=[]}var m=[UT(t,r[0]),UT(t,r[1]),Object(_["m"])({},r[2])];return m[2].type=m[2].type||null,Object(_["I"])(m[2],m[0]),Object(_["I"])(m[2],m[1]),m};function uM(t){return!isNaN(t)&&!isFinite(t)}function cM(t,e,n,i){var r=1-t,a=i.dimensions[t];return uM(e[r])&&uM(n[r])&&e[t]===n[t]&&i.getAxis(a).containData(e[t])}function hM(t,e){if("cartesian2d"===t.type){var n=e[0].coord,i=e[1].coord;if(n&&i&&(cM(1,n,i,t)||cM(0,n,i,t)))return!0}return ZT(t,e[0])&&ZT(t,e[1])}function dM(t,e,n,i,r){var a,o=i.coordinateSystem,s=t.getItemModel(e),l=Be["p"](s.get("x"),r.getWidth()),u=Be["p"](s.get("y"),r.getHeight());if(isNaN(l)||isNaN(u)){if(i.getMarkerPosition)a=i.getMarkerPosition(t.getValues(t.dimensions,e));else{var c=o.dimensions,h=t.get(c[0],e),d=t.get(c[1],e);a=o.dataToPoint([h,d])}if(Ge(o,"cartesian2d")){var f=o.getAxis("x"),p=o.getAxis("y");c=o.dimensions;uM(t.get(c[0],e))?a[0]=f.toGlobalCoord(f.getExtent()[n?0:1]):uM(t.get(c[1],e))&&(a[1]=p.toGlobalCoord(p.getExtent()[n?0:1]))}isNaN(l)||(a[0]=l),isNaN(u)||(a[1]=u)}else a=[l,u];t.setItemLayout(e,a)}var fM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.updateTransform=function(t,e,n){e.eachSeries((function(t){var e=RT.getMarkerModelFromSeries(t,"markLine");if(e){var i=e.getData(),r=sM(e).from,a=sM(e).to;r.each((function(e){dM(r,e,!0,t,n),dM(a,e,!1,t,n)})),i.each((function(t){i.setItemLayout(t,[r.getItemLayout(t),a.getItemLayout(t)])})),this.markerGroupMap.get(t.id).updateLayout()}}),this)},e.prototype.renderSeries=function(t,e,n,i){var r=t.coordinateSystem,a=t.id,o=t.getData(),s=this.markerGroupMap,l=s.get(a)||s.set(a,new gh);this.group.add(l.group);var u=pM(r,t,e),c=u.from,h=u.to,d=u.line;sM(e).from=c,sM(e).to=h,e.setData(d);var f=e.get("symbol"),p=e.get("symbolSize"),g=e.get("symbolRotate"),m=e.get("symbolOffset");function v(e,n,r){var a=e.getItemModel(n);dM(e,n,r,t,i);var s=a.getModel("itemStyle").getItemStyle();null==s.fill&&(s.fill=Object(TS["b"])(o,"color")),e.setItemVisual(n,{symbolKeepAspect:a.get("symbolKeepAspect"),symbolOffset:Object(_["P"])(a.get("symbolOffset",!0),m[r?0:1]),symbolRotate:Object(_["P"])(a.get("symbolRotate",!0),g[r?0:1]),symbolSize:Object(_["P"])(a.get("symbolSize"),p[r?0:1]),symbol:Object(_["P"])(a.get("symbol",!0),f[r?0:1]),style:s})}Object(_["t"])(f)||(f=[f,f]),Object(_["t"])(p)||(p=[p,p]),Object(_["t"])(g)||(g=[g,g]),Object(_["t"])(m)||(m=[m,m]),u.from.each((function(t){v(c,t,!0),v(h,t,!1)})),d.each((function(t){var e=d.getItemModel(t).getModel("lineStyle").getLineStyle();d.setItemLayout(t,[c.getItemLayout(t),h.getItemLayout(t)]),null==e.stroke&&(e.stroke=c.getItemVisual(t,"style").fill),d.setItemVisual(t,{fromSymbolKeepAspect:c.getItemVisual(t,"symbolKeepAspect"),fromSymbolOffset:c.getItemVisual(t,"symbolOffset"),fromSymbolRotate:c.getItemVisual(t,"symbolRotate"),fromSymbolSize:c.getItemVisual(t,"symbolSize"),fromSymbol:c.getItemVisual(t,"symbol"),toSymbolKeepAspect:h.getItemVisual(t,"symbolKeepAspect"),toSymbolOffset:h.getItemVisual(t,"symbolOffset"),toSymbolRotate:h.getItemVisual(t,"symbolRotate"),toSymbolSize:h.getItemVisual(t,"symbolSize"),toSymbol:h.getItemVisual(t,"symbol"),style:e})})),l.updateData(d),u.line.eachItemGraphicEl((function(t){Object(ie["a"])(t).dataModel=e,t.traverse((function(t){Object(ie["a"])(t).dataModel=e}))})),this.markKeep(l),l.group.silent=e.get("silent")||t.get("silent")},e.type="markLine",e}($T);function pM(t,e,n){var i;i=t?Object(_["H"])(t&&t.dimensions,(function(t){var n=e.getData().getDimensionInfo(e.getData().mapDimension(t))||{};return Object(_["m"])(Object(_["m"])({},n),{name:t,ordinalMeta:null})})):[{name:"value",type:"float"}];var r=new Mi["a"](i,n),a=new Mi["a"](i,n),o=new Mi["a"]([],n),s=Object(_["H"])(n.get("data"),Object(_["h"])(lM,e,t,n));t&&(s=Object(_["n"])(s,Object(_["h"])(hM,t)));var l=YT(!!t,i);return r.initData(Object(_["H"])(s,(function(t){return t[0]})),null,l),a.initData(Object(_["H"])(s,(function(t){return t[1]})),null,l),o.initData(Object(_["H"])(s,(function(t){return t[2]}))),o.hasItemOption=!0,{from:r,to:a,line:o}}var gM=fM;function mM(t){t.registerComponentModel(oM),t.registerComponentView(gM),t.registerPreprocessor((function(t){ET(t.series,"markLine")&&(t.markLine=t.markLine||{})}))}var vM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.createMarkerModelFromSeries=function(t,n,i){return new e(t,n,i)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e}(RT),yM=vM,_M=Object(Te["o"])(),bM=function(t,e,n,i){var r=UT(t,i[0]),a=UT(t,i[1]),o=r.coord,s=a.coord;o[0]=Object(_["O"])(o[0],-1/0),o[1]=Object(_["O"])(o[1],-1/0),s[0]=Object(_["O"])(s[0],1/0),s[1]=Object(_["O"])(s[1],1/0);var l=Object(_["J"])([{},r,a]);return l.coord=[r.coord,a.coord],l.x0=r.x,l.y0=r.y,l.x1=a.x,l.y1=a.y,l};function xM(t){return!isNaN(t)&&!isFinite(t)}function wM(t,e,n,i){var r=1-t;return xM(e[r])&&xM(n[r])}function OM(t,e){var n=e.coord[0],i=e.coord[1],r={coord:n,x:e.x0,y:e.y0},a={coord:i,x:e.x1,y:e.y1};return Ge(t,"cartesian2d")?!(!n||!i||!wM(1,n,i,t)&&!wM(0,n,i,t))||qT(t,r,a):ZT(t,r)||ZT(t,a)}function SM(t,e,n,i,r){var a,o=i.coordinateSystem,s=t.getItemModel(e),l=Be["p"](s.get(n[0]),r.getWidth()),u=Be["p"](s.get(n[1]),r.getHeight());if(isNaN(l)||isNaN(u)){if(i.getMarkerPosition)a=i.getMarkerPosition(t.getValues(n,e));else{var c=t.get(n[0],e),h=t.get(n[1],e),d=[c,h];o.clampData&&o.clampData(d,d),a=o.dataToPoint(d,!0)}if(Ge(o,"cartesian2d")){var f=o.getAxis("x"),p=o.getAxis("y");c=t.get(n[0],e),h=t.get(n[1],e);xM(c)?a[0]=f.toGlobalCoord(f.getExtent()["x0"===n[0]?0:1]):xM(h)&&(a[1]=p.toGlobalCoord(p.getExtent()["y0"===n[1]?0:1]))}isNaN(l)||(a[0]=l),isNaN(u)||(a[1]=u)}else a=[l,u];return a}var TM=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],MM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.updateTransform=function(t,e,n){e.eachSeries((function(t){var e=RT.getMarkerModelFromSeries(t,"markArea");if(e){var i=e.getData();i.each((function(e){var r=Object(_["H"])(TM,(function(r){return SM(i,e,r,t,n)}));i.setItemLayout(e,r);var a=i.getItemGraphicEl(e);a.setShape("points",r)}))}}),this)},e.prototype.renderSeries=function(t,e,n,i){var r=t.coordinateSystem,a=t.id,o=t.getData(),s=this.markerGroupMap,l=s.get(a)||s.set(a,{group:new Jt["a"]});this.group.add(l.group),this.markKeep(l);var u=AM(r,t,e);e.setData(u),u.each((function(e){var n=Object(_["H"])(TM,(function(n){return SM(u,e,n,t,i)})),a=r.getAxis("x").scale,s=r.getAxis("y").scale,l=a.getExtent(),c=s.getExtent(),h=[a.parse(u.get("x0",e)),a.parse(u.get("x1",e))],d=[s.parse(u.get("y0",e)),s.parse(u.get("y1",e))];Be["c"](h),Be["c"](d);var f=!(l[0]>h[1]||l[1]d[1]||c[1]=0},e.prototype.getOrient=function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},e}(Xi["a"]),EM=LM,jM=_["h"],PM=_["k"],NM=Jt["a"],RM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.newlineDisabled=!1,n}return Object(qt["a"])(e,t),e.prototype.init=function(){this.group.add(this._contentGroup=new NM),this.group.add(this._selectorGroup=new NM),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,e,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var r=t.get("align"),a=t.get("orient");r&&"auto"!==r||(r="right"===t.get("left")&&"vertical"===a?"right":"left");var o=t.get("selector",!0),s=t.get("selectorPosition",!0);!o||s&&"auto"!==s||(s="horizontal"===a?"end":"start"),this.renderInner(r,t,e,n,o,a,s);var l=t.getBoxLayoutParams(),u={width:n.getWidth(),height:n.getHeight()},c=t.get("padding"),h=ri["g"](l,u,c),d=this.layoutInner(t,r,h,i,o,s),f=ri["g"](_["i"]({width:d.width,height:d.height},l),u,c);this.group.x=f.x-d.x,this.group.y=f.y-d.y,this.group.markRedraw(),this.group.add(this._backgroundEl=Ew(d,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,e,n,i,r,a,o){var s=this.getContentGroup(),l=_["f"](),u=e.get("selectedMode"),c=[];n.eachRawSeries((function(t){!t.get("legendHoverLink")&&c.push(t.id)})),PM(e.getData(),(function(r,a){var o=r.get("name");if(!this.newlineDisabled&&(""===o||"\n"===o)){var h=new NM;return h.newline=!0,void s.add(h)}var d=n.getSeriesByName(o)[0];if(!l.get(o)){if(d){var f=d.getData(),p=f.getVisual("legendLineStyle")||{},g=f.getVisual("legendIcon"),m=f.getVisual("style"),v=this._createItem(d,o,a,r,e,t,p,m,g,u,i);v.on("click",jM(zM,o,null,i,c)).on("mouseover",jM(FM,d.name,null,i,c)).on("mouseout",jM(GM,d.name,null,i,c)),l.set(o,!0)}else n.eachRawSeries((function(n){if(!l.get(o)&&n.legendVisualProvider){var s=n.legendVisualProvider;if(!s.containName(o))return;var h=s.indexOfName(o),d=s.getItemVisual(h,"style"),f=s.getItemVisual(h,"legendIcon"),p=Object(Ue["parse"])(d.fill);p&&0===p[3]&&(p[3]=.2,d=_["m"](_["m"]({},d),{fill:Object(Ue["stringify"])(p,"rgba")}));var g=this._createItem(n,o,a,r,e,t,{},d,f,u,i);g.on("click",jM(zM,null,o,i,c)).on("mouseover",jM(FM,null,o,i,c)).on("mouseout",jM(GM,null,o,i,c)),l.set(o,!0)}}),this);0}}),this),r&&this._createSelector(r,e,i,a,o)},e.prototype._createSelector=function(t,e,n,i,r){var a=this.getSelectorGroup();PM(t,(function(t){var i=t.type,r=new $["a"]({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:"all"===i?"legendAllSelect":"legendInverseSelect"})}});a.add(r);var o=e.getModel("selectorLabel"),s=e.getModel(["emphasis","selectorLabel"]);Object(le["g"])(r,{normal:o,emphasis:s},{defaultText:t.title}),Object(re["o"])(r)}))},e.prototype._createItem=function(t,e,n,i,r,a,o,s,l,u,c){var h=t.visualDrawType,d=r.get("itemWidth"),f=r.get("itemHeight"),p=r.isSelected(e),g=i.get("symbolRotate"),m=i.get("symbolKeepAspect"),v=i.get("icon");l=v||l||"roundRect";var y=kM(l,i,o,s,h,p,c),b=new NM,x=i.getModel("textStyle");if(!_["w"](t.getLegendIcon)||v&&"inherit"!==v){var w="inherit"===v&&t.getData().getVisual("symbol")?"inherit"===g?t.getData().getVisual("symbolRotate"):g:0;b.add(BM({itemWidth:d,itemHeight:f,icon:l,iconRotate:w,itemStyle:y.itemStyle,lineStyle:y.lineStyle,symbolKeepAspect:m}))}else b.add(t.getLegendIcon({itemWidth:d,itemHeight:f,icon:l,iconRotate:g,itemStyle:y.itemStyle,lineStyle:y.lineStyle,symbolKeepAspect:m}));var O="left"===a?d+5:-5,S=a,T=r.get("formatter"),M=e;_["C"](T)&&T?M=T.replace("{name}",null!=e?e:""):_["w"](T)&&(M=T(e));var A=i.get("inactiveColor");b.add(new $["a"]({style:Object(le["c"])(x,{text:M,x:O,y:f/2,fill:p?x.getTextColor():A,align:S,verticalAlign:"middle"})}));var C=new Re["a"]({shape:b.getBoundingRect(),invisible:!0}),I=i.getModel("tooltip");return I.get("show")&&ne["setTooltipConfig"]({el:C,componentModel:r,itemName:e,itemTooltipOption:I.option}),b.add(C),b.eachChild((function(t){t.silent=!0})),C.silent=!u,this.getContentGroup().add(b),Object(re["o"])(b),b.__legendDataIndex=n,b},e.prototype.layoutInner=function(t,e,n,i,r,a){var o=this.getContentGroup(),s=this.getSelectorGroup();ri["b"](t.get("orient"),o,t.get("itemGap"),n.width,n.height);var l=o.getBoundingRect(),u=[-l.x,-l.y];if(s.markRedraw(),o.markRedraw(),r){ri["b"]("horizontal",s,t.get("selectorItemGap",!0));var c=s.getBoundingRect(),h=[-c.x,-c.y],d=t.get("selectorButtonGap",!0),f=t.getOrient().index,p=0===f?"width":"height",g=0===f?"height":"width",m=0===f?"y":"x";"end"===a?h[f]+=l[p]+d:u[f]+=c[p]+d,h[1-f]+=l[g]/2-c[g]/2,s.x=h[0],s.y=h[1],o.x=u[0],o.y=u[1];var v={x:0,y:0};return v[p]=l[p]+d+c[p],v[g]=Math.max(l[g],c[g]),v[m]=Math.min(0,c[m]+h[1-f]),v}return o.x=u[0],o.y=u[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e}(Wi["a"]);function kM(t,e,n,i,r,a,o){function s(t,e){"auto"===t.lineWidth&&(t.lineWidth=e.lineWidth>0?2:0),PM(t,(function(n,i){"inherit"===t[i]&&(t[i]=e[i])}))}var l=e.getModel("itemStyle"),u=l.getItemStyle(),c=0===t.lastIndexOf("empty",0)?"fill":"stroke",h=l.getShallow("decal");u.decal=h&&"inherit"!==h?Object(as["a"])(h,o):i.decal,"inherit"===u.fill&&(u.fill=i[r]),"inherit"===u.stroke&&(u.stroke=i[c]),"inherit"===u.opacity&&(u.opacity=("fill"===r?i:n).opacity),s(u,i);var d=e.getModel("lineStyle"),f=d.getLineStyle();if(s(f,n),"auto"===u.fill&&(u.fill=i.fill),"auto"===u.stroke&&(u.stroke=i.fill),"auto"===f.stroke&&(f.stroke=i.fill),!a){var p=e.get("inactiveBorderWidth"),g=u[c];u.lineWidth="auto"===p?i.lineWidth>0&&g?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),f.stroke=d.get("inactiveColor"),f.lineWidth=d.get("inactiveWidth")}return{itemStyle:u,lineStyle:f}}function BM(t){var e=t.icon||"roundRect",n=Object(Qt["a"])(e,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill,t.symbolKeepAspect);return n.setStyle(t.itemStyle),n.rotation=(t.iconRotate||0)*Math.PI/180,n.setOrigin([t.itemWidth/2,t.itemHeight/2]),e.indexOf("empty")>-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n}function zM(t,e,n,i){GM(t,e,n,i),n.dispatchAction({type:"legendToggleSelect",name:null!=t?t:e}),FM(t,e,n,i)}function VM(t){var e,n=t.getZr().storage.getDisplayList(),i=0,r=n.length;while(in[r],p=[-h.x,-h.y];e||(p[i]=l[s]);var g=[0,0],m=[-d.x,-d.y],v=_["P"](t.get("pageButtonGap",!0),t.get("itemGap",!0));if(f){var y=t.get("pageButtonPosition",!0);"end"===y?m[i]+=n[r]-d[r]:g[i]+=d[r]+v}m[1-i]+=h[a]/2-d[a]/2,l.setPosition(p),u.setPosition(g),c.setPosition(m);var b={x:0,y:0};if(b[r]=f?n[r]:h[r],b[a]=Math.max(h[a],d[a]),b[o]=Math.min(0,d[o]+m[1-i]),u.__rectSize=n[r],f){var x={x:0,y:0};x[r]=Math.max(n[r]-d[r]-v,0),x[a]=b[a],u.setClipPath(new Re["a"]({shape:x})),u.__rectSize=x[r]}else c.eachChild((function(t){t.attr({invisible:!0,silent:!0})}));var w=this._getPageInfo(t);return null!=w.pageIndex&&ee["h"](l,{x:w.contentPosition[0],y:w.contentPosition[1]},f?t:null),this._updatePageInfoView(t,w),b},e.prototype._pageGo=function(t,e,n){var i=this._getPageInfo(e)[t];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:e.id})},e.prototype._updatePageInfoView=function(t,e){var n=this._controllerGroup;_["k"](["pagePrev","pageNext"],(function(i){var r=i+"DataIndex",a=null!=e[r],o=n.childOfName(i);o&&(o.setStyle("fill",a?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),o.cursor=a?"pointer":"default")}));var i=n.childOfName("pageText"),r=t.get("pageFormatter"),a=e.pageIndex,o=null!=a?a+1:0,s=e.pageCount;i&&r&&i.setStyle("text",_["C"](r)?r.replace("{current}",null==o?"":o+"").replace("{total}",null==s?"":s+""):r({current:o,total:s}))},e.prototype._getPageInfo=function(t){var e=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,r=t.getOrient().index,a=JM[r],o=$M[r],s=this._findTargetItemIndex(e),l=n.children(),u=l[s],c=l.length,h=c?1:0,d={contentPosition:[n.x,n.y],pageCount:h,pageIndex:h-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!u)return d;var f=y(u);d.contentPosition[r]=-f.s;for(var p=s+1,g=f,m=f,v=null;p<=c;++p)v=y(l[p]),(!v&&m.e>g.s+i||v&&!_(v,g.s))&&(g=m.i>g.i?m:v,g&&(null==d.pageNextDataIndex&&(d.pageNextDataIndex=g.i),++d.pageCount)),m=v;for(p=s-1,g=f,m=f,v=null;p>=-1;--p)v=y(l[p]),v&&_(m,v.s)||!(g.i=e&&t.s<=e+i}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var e,n,i=this.getContentGroup();return i.eachChild((function(i,r){var a=i.__legendDataIndex;null==n&&null!=a&&(n=r),a===t&&(e=r)})),null!=e?e:n},e.type="legend.scroll",e}(HM),eA=tA;function nA(t){t.registerAction("legendScroll","legendscroll",(function(t,e){var n=t.scrollDataIndex;null!=n&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},(function(t){t.setScrollDataIndex(n)}))}))}function iA(t){Object(i["a"])(ZM),t.registerComponentModel(KM),t.registerComponentView(eA),nA(t)}function rA(t){Object(i["a"])(ZM),Object(i["a"])(iA)}var aA=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="dataZoom.inside",e.defaultOption=Object(bn["d"])(ow.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e}(ow),oA=aA,sA=Object(Te["o"])();function lA(t,e,n){sA(t).coordSysRecordMap.each((function(t){var i=t.dataZoomInfoMap.get(e.uid);i&&(i.getRange=n)}))}function uA(t,e){for(var n=sA(t).coordSysRecordMap,i=n.keys(),r=0;ri[n+e]&&(e=o),r=r&&a.get("preventDefaultMouseMove",!0)})),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!r}}}function gA(t){t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,(function(t,e){var n=sA(e),i=n.coordSysRecordMap||(n.coordSysRecordMap=Object(_["f"])());i.each((function(t){t.dataZoomInfoMap=null})),t.eachComponent({mainType:"dataZoom",subType:"inside"},(function(t){var n=nw(t);Object(_["k"])(n.infoList,(function(n){var r=n.model.uid,a=i.get(r)||i.set(r,hA(e,n.model)),o=a.dataZoomInfoMap||(a.dataZoomInfoMap=Object(_["f"])());o.set(t.uid,{dzReferCoordSysInfo:n,model:t,getRange:null})}))})),i.each((function(t){var e,n=t.controller,r=t.dataZoomInfoMap;if(r){var a=r.keys()[0];null!=a&&(e=r.get(a))}if(e){var o=pA(r);n.enable(o.controlType,o.opt),n.setPointerChecker(t.containsPoint),On["b"](t,"dispatchAction",e.model.get("throttle",!0),"fixRate")}else cA(i,t)}))}))}var mA=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="dataZoom.inside",e}return Object(qt["a"])(e,t),e.prototype.render=function(e,n,i){t.prototype.render.apply(this,arguments),e.noTarget()?this._clear():(this.range=e.getPercentRange(),lA(i,e,{pan:Object(_["c"])(vA.pan,this),zoom:Object(_["c"])(vA.zoom,this),scrollMove:Object(_["c"])(vA.scrollMove,this)}))},e.prototype.dispose=function(){this._clear(),t.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){uA(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e}(cw),vA={zoom:function(t,e,n,i){var r=this.range,a=r.slice(),o=t.axisModels[0];if(o){var s=_A[e](null,[i.originX,i.originY],o,n,t),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],u=Math.max(1/i.scale,0);a[0]=(a[0]-l)*u+l,a[1]=(a[1]-l)*u+l;var c=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();return Dd(0,a,[0,100],0,c.minSpan,c.maxSpan),this.range=a,r[0]!==a[0]||r[1]!==a[1]?a:void 0}},pan:yA((function(t,e,n,i,r,a){var o=_A[i]([a.oldX,a.oldY],[a.newX,a.newY],e,r,n);return o.signal*(t[1]-t[0])*o.pixel/o.pixelLength})),scrollMove:yA((function(t,e,n,i,r,a){var o=_A[i]([0,0],[a.scrollDelta,a.scrollDelta],e,r,n);return o.signal*(t[1]-t[0])*a.scrollDelta}))};function yA(t){return function(e,n,i,r){var a=this.range,o=a.slice(),s=e.axisModels[0];if(s){var l=t(o,s,e,n,i,r);return Dd(l,o,[0,100],"all"),this.range=o,a[0]!==o[0]||a[1]!==o[1]?o:void 0}}}var _A={grid:function(t,e,n,i,r){var a=n.axis,o={},s=r.model.coordinateSystem.getRect();return t=t||[0,0],"x"===a.dim?(o.pixel=e[0]-t[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=e[1]-t[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(t,e,n,i,r){var a=n.axis,o={},s=r.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return t=t?s.pointToCoord(t):[0,0],e=s.pointToCoord(e),"radiusAxis"===n.mainType?(o.pixel=e[0]-t[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?1:-1):(o.pixel=e[1]-t[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=a.inverse?-1:1),o},singleAxis:function(t,e,n,i,r){var a=n.axis,o=r.model.coordinateSystem.getRect(),s={};return t=t||[0,0],"horizontal"===a.orient?(s.pixel=e[0]-t[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=e[1]-t[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}},bA=mA;function xA(t){Ow(t),t.registerComponentModel(oA),t.registerComponentView(bA),gA(t)}var wA=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=Object(bn["d"])(ow.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),e}(ow),OA=wA,SA=Re["a"],TA=7,MA=1,AA=30,CA=7,IA="horizontal",DA="vertical",LA=5,EA=["line","bar","candlestick","scatter"],jA={easing:"cubicOut",duration:100,delay:0},PA=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._displayables={},n}return Object(qt["a"])(e,t),e.prototype.init=function(t,e){this.api=e,this._onBrush=Object(_["c"])(this._onBrush,this),this._onBrushEnd=Object(_["c"])(this._onBrushEnd,this)},e.prototype.render=function(e,n,i,r){if(t.prototype.render.apply(this,arguments),On["b"](this,"_dispatchZoomAction",e.get("throttle"),"fixRate"),this._orient=e.getOrient(),!1!==e.get("show")){if(e.noTarget())return this._clear(),void this.group.removeAll();r&&"dataZoom"===r.type&&r.from===this.uid||this._buildView(),this._updateView()}else this.group.removeAll()},e.prototype.dispose=function(){this._clear(),t.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){On["a"](this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var e=this._displayables.sliderGroup=new Jt["a"];this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(e),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,e=this.api,n=t.get("brushSelect"),i=n?CA:0,r=this._findCoordRect(),a={width:e.getWidth(),height:e.getHeight()},o=this._orient===IA?{right:a.width-r.x-r.width,top:a.height-AA-TA-i,width:r.width,height:AA}:{right:TA,top:r.y,width:AA,height:r.height},s=ri["f"](t.option);Object(_["k"])(["right","top","width","height"],(function(t){"ph"===s[t]&&(s[t]=o[t])}));var l=ri["g"](s,a);this._location={x:l.x,y:l.y},this._size=[l.width,l.height],this._orient===DA&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,e=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),r=i&&i.get("inverse"),a=this._displayables.sliderGroup,o=(this._dataShadowInfo||{}).otherAxisInverse;a.attr(n!==IA||r?n===IA&&r?{scaleY:o?1:-1,scaleX:-1}:n!==DA||r?{scaleY:o?-1:1,scaleX:-1,rotation:Math.PI/2}:{scaleY:o?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:o?1:-1,scaleX:1});var s=t.getBoundingRect([a]);t.x=e.x-s.x,t.y=e.y-s.y,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,e=this._size,n=this._displayables.sliderGroup,i=t.get("brushSelect");n.add(new SA({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var r=new SA({shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:"transparent"},z2:0,onclick:Object(_["c"])(this._onClickPanel,this)}),a=this.api.getZr();i?(r.on("mousedown",this._onBrushStart,this),r.cursor="crosshair",a.on("mousemove",this._onBrush),a.on("mouseup",this._onBrushEnd)):(a.off("mousemove",this._onBrush),a.off("mouseup",this._onBrushEnd)),n.add(r)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],t){var e=this._size,n=this._shadowSize||[],i=t.series,r=i.getRawData(),a=i.getShadowDim?i.getShadowDim():t.otherDim;if(null!=a){var o=this._shadowPolygonPts,s=this._shadowPolylinePts;if(r!==this._shadowData||a!==this._shadowDim||e[0]!==n[0]||e[1]!==n[1]){var l=r.getDataExtent(a),u=.3*(l[1]-l[0]);l=[l[0]-u,l[1]+u];var c,h=[0,e[1]],d=[0,e[0]],f=[[e[0],0],[0,0]],p=[],g=d[1]/(r.count()-1),m=0,v=Math.round(r.count()/e[0]);r.each([a],(function(t,e){if(v>0&&e%v)m+=g;else{var n=null==t||isNaN(t)||""===t,i=n?0:Object(Be["l"])(t,l,h,!0);n&&!c&&e?(f.push([f[f.length-1][0],0]),p.push([p[p.length-1][0],0])):!n&&c&&(f.push([m,0]),p.push([m,0])),f.push([m,i]),p.push([m,i]),m+=g,c=n}})),o=this._shadowPolygonPts=f,s=this._shadowPolylinePts=p}this._shadowData=r,this._shadowDim=a,this._shadowSize=[e[0],e[1]];for(var y=this.dataZoomModel,_=0;_<3;_++){var b=x(1===_);this._displayables.sliderGroup.add(b),this._displayables.dataShadowSegs.push(b)}}}function x(t){var e=y.getModel(t?"selectedDataBackground":"dataBackground"),n=new Jt["a"],i=new Oa["a"]({shape:{points:o},segmentIgnoreThreshold:1,style:e.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),r=new hi["a"]({shape:{points:s},segmentIgnoreThreshold:1,style:e.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return n.add(i),n.add(r),n}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,e=t.get("showDataShadow");if(!1!==e){var n,i=this.ecModel;return t.eachTargetAxis((function(r,a){var o=t.getAxisProxy(r,a).getTargetSeriesModels();Object(_["k"])(o,(function(t){if(!n&&!(!0!==e&&Object(_["r"])(EA,t.get("type"))<0)){var o,s=i.getComponent(tw(r),a).axis,l=NA(r),u=t.coordinateSystem;null!=l&&u.getOtherAxis&&(o=u.getOtherAxis(s).inverse),l=t.getData().mapDimension(l),n={thisAxis:s,series:t,thisDim:r,otherDim:l,otherAxisInverse:o}}}),this)}),this),n}},e.prototype._renderHandle=function(){var t=this.group,e=this._displayables,n=e.handles=[null,null],i=e.handleLabels=[null,null],r=this._displayables.sliderGroup,a=this._size,o=this.dataZoomModel,s=this.api,l=o.get("borderRadius")||0,u=o.get("brushSelect"),c=e.filler=new SA({silent:u,style:{fill:o.get("fillerColor")},textConfig:{position:"inside"}});r.add(c),r.add(new SA({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:a[0],height:a[1],r:l},style:{stroke:o.get("dataBackgroundColor")||o.get("borderColor"),lineWidth:MA,fill:"rgba(0,0,0,0)"}})),Object(_["k"])([0,1],(function(e){var a=o.get("handleIcon");!Qt["d"][a]&&a.indexOf("path://")<0&&a.indexOf("image://")<0&&(a="path://"+a);var s=Object(Qt["a"])(a,-1,0,2,2,null,!0);s.attr({cursor:RA(this._orient),draggable:!0,drift:Object(_["c"])(this._onDragMove,this,e),ondragend:Object(_["c"])(this._onDragEnd,this),onmouseover:Object(_["c"])(this._showDataInfo,this,!0),onmouseout:Object(_["c"])(this._showDataInfo,this,!1),z2:5});var l=s.getBoundingRect(),u=o.get("handleSize");this._handleHeight=Object(Be["p"])(u,this._size[1]),this._handleWidth=l.width/l.height*this._handleHeight,s.setStyle(o.getModel("handleStyle").getItemStyle()),s.style.strokeNoScale=!0,s.rectHover=!0,s.ensureState("emphasis").style=o.getModel(["emphasis","handleStyle"]).getItemStyle(),Object(re["o"])(s);var c=o.get("handleColor");null!=c&&(s.style.fill=c),r.add(n[e]=s);var h=o.getModel("textStyle");t.add(i[e]=new $["a"]({silent:!0,invisible:!0,style:Object(le["c"])(h,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:h.getTextColor(),font:h.getFont()}),z2:10}))}),this);var h=c;if(u){var d=Object(Be["p"])(o.get("moveHandleSize"),a[1]),f=e.moveHandle=new Re["a"]({style:o.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:a[1]-.5,height:d}}),p=.8*d,g=e.moveHandleIcon=Object(Qt["a"])(o.get("moveHandleIcon"),-p/2,-p/2,p,p,"#fff",!0);g.silent=!0,g.y=a[1]+d/2-.5,f.ensureState("emphasis").style=o.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(a[1]/2,Math.max(d,10));h=e.moveZone=new Re["a"]({invisible:!0,shape:{y:a[1]-m,height:d+m}}),h.on("mouseover",(function(){s.enterEmphasis(f)})).on("mouseout",(function(){s.leaveEmphasis(f)})),r.add(f),r.add(g),r.add(h)}h.attr({draggable:!0,cursor:RA(this._orient),drift:Object(_["c"])(this._onDragMove,this,"all"),ondragstart:Object(_["c"])(this._showDataInfo,this,!0),ondragend:Object(_["c"])(this._onDragEnd,this),onmouseover:Object(_["c"])(this._showDataInfo,this,!0),onmouseout:Object(_["c"])(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[Object(Be["l"])(t[0],[0,100],e,!0),Object(Be["l"])(t[1],[0,100],e,!0)]},e.prototype._updateInterval=function(t,e){var n=this.dataZoomModel,i=this._handleEnds,r=this._getViewExtent(),a=n.findRepresentativeAxisProxy().getMinMaxSpan(),o=[0,100];Dd(e,i,r,n.get("zoomLock")?"all":t,null!=a.minSpan?Object(Be["l"])(a.minSpan,o,r,!0):null,null!=a.maxSpan?Object(Be["l"])(a.maxSpan,o,r,!0):null);var s=this._range,l=this._range=Object(Be["c"])([Object(Be["l"])(i[0],r,o,!0),Object(Be["l"])(i[1],r,o,!0)]);return!s||s[0]!==l[0]||s[1]!==l[1]},e.prototype._updateView=function(t){var e=this._displayables,n=this._handleEnds,i=Object(Be["c"])(n.slice()),r=this._size;Object(_["k"])([0,1],(function(t){var i=e.handles[t],a=this._handleHeight;i.attr({scaleX:a/2,scaleY:a/2,x:n[t]+(t?-1:1),y:r[1]/2-a/2})}),this),e.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:r[1]});var a={x:i[0],width:i[1]-i[0]};e.moveHandle&&(e.moveHandle.setShape(a),e.moveZone.setShape(a),e.moveZone.getBoundingRect(),e.moveHandleIcon&&e.moveHandleIcon.attr("x",a.x+a.width/2));for(var o=e.dataShadowSegs,s=[0,i[0],i[1],r[0]],l=0;le[0]||n[1]<0||n[1]>e[1])){var i=this._handleEnds,r=(i[0]+i[1])/2,a=this._updateInterval("all",n[0]-r);this._updateView(),a&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var e=t.offsetX,n=t.offsetY;this._brushStart=new di["a"](e,n),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var e=this._displayables.brushRect;if(this._brushing=!1,e){e.attr("ignore",!0);var n=e.shape,i=+new Date;if(!(i-this._brushStartTime<200&&Math.abs(n.width)<5)){var r=this._getViewExtent(),a=[0,100];this._range=Object(Be["c"])([Object(Be["l"])(n.x,r,a,!0),Object(Be["l"])(n.x+n.width,r,a,!0)]),this._handleEnds=[n.x,n.x+n.width],this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(Wa["g"](t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,e){var n=this._displayables,i=this.dataZoomModel,r=n.brushRect;r||(r=n.brushRect=new SA({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(r)),r.attr("ignore",!1);var a=this._brushStart,o=this._displayables.sliderGroup,s=o.transformCoordToLocal(t,e),l=o.transformCoordToLocal(a.x,a.y),u=this._size;s[0]=Math.max(Math.min(u[0],s[0]),0),r.setShape({x:l[0],y:0,width:s[0]-l[0],height:u[1]})},e.prototype._dispatchZoomAction=function(t){var e=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?jA:null,start:e[0],end:e[1]})},e.prototype._findCoordRect=function(){var t,e=nw(this.dataZoomModel).infoList;if(!t&&e.length){var n=e[0].model.coordinateSystem;t=n.getRect&&n.getRect()}if(!t){var i=this.api.getWidth(),r=this.api.getHeight();t={x:.2*i,y:.2*r,width:.6*i,height:.6*r}}return t},e.type="dataZoom.slider",e}(cw);function NA(t){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[t]}function RA(t){return"vertical"===t?"ns-resize":"ew-resize"}var kA=PA;function BA(t){t.registerComponentModel(OA),t.registerComponentView(kA),Ow(t)}function zA(t){Object(i["a"])(xA),Object(i["a"])(BA)}var VA={get:function(t,e,n){var i=_["d"]((FA[t]||{})[e]);return n&&_["t"](i)?i[i.length-1]:i}},FA={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},GA=VA,HA=Gu.mapVisual,UA=Gu.eachVisual,WA=_["t"],XA=_["k"],ZA=Be["c"],qA=Be["l"],YA=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.stateList=["inRange","outOfRange"],n.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],n.layoutMode={type:"box",ignoreSize:!0},n.dataBound=[-1/0,1/0],n.targetVisuals={},n.controllerVisuals={},n}return Object(qt["a"])(e,t),e.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n)},e.prototype.optionUpdated=function(t,e){var n=this.option;!e&&IS(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var e=this.stateList;t=_["c"](t,this),this.controllerVisuals=CS(this.option.controller,e,t),this.targetVisuals=CS(this.option.target,e,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,e=[];return null==t||"all"===t?this.ecModel.eachSeries((function(t,n){e.push(n)})):e=Te["r"](t),e},e.prototype.eachTargetSeries=function(t,e){_["k"](this.getTargetSeriesIndices(),(function(n){var i=this.ecModel.getSeriesByIndex(n);i&&t.call(e,i)}),this)},e.prototype.isTargetSeries=function(t){var e=!1;return this.eachTargetSeries((function(n){n===t&&(e=!0)})),e},e.prototype.formatValueText=function(t,e,n){var i,r=this.option,a=r.precision,o=this.dataBound,s=r.formatter;n=n||["<",">"],_["t"](t)&&(t=t.slice(),i=!0);var l=e?t:i?[u(t[0]),u(t[1])]:u(t);return _["C"](s)?s.replace("{value}",i?l[0]:l).replace("{value2}",i?l[1]:l):_["w"](s)?i?s(t[0],t[1]):s(t):i?t[0]===o[0]?n[0]+" "+l[1]:t[1]===o[1]?n[1]+" "+l[0]:l[0]+" - "+l[1]:l;function u(t){return t===o[0]?"min":t===o[1]?"max":(+t).toFixed(Math.min(a,20))}},e.prototype.resetExtent=function(){var t=this.option,e=ZA([t.min,t.max]);this._dataExtent=e},e.prototype.getDataDimensionIndex=function(t){var e=this.option.dimension;if(null!=e)return t.getDimensionIndex(e);for(var n=t.dimensions,i=n.length-1;i>=0;i--){var r=n[i],a=t.getDimensionInfo(r);if(!a.isCalculationCoord)return a.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,e=this.option,n={inRange:e.inRange,outOfRange:e.outOfRange},i=e.target||(e.target={}),r=e.controller||(e.controller={});_["I"](i,n),_["I"](r,n);var a=this.isCategory();function o(n){WA(e.color)&&!n.inRange&&(n.inRange={color:e.color.slice().reverse()}),n.inRange=n.inRange||{color:t.get("gradientColor")}}function s(t,e,n){var i=t[e],r=t[n];i&&!r&&(r=t[n]={},XA(i,(function(t,e){if(Gu.isValidType(e)){var n=GA.get(e,"inactive",a);null!=n&&(r[e]=n,"color"!==e||r.hasOwnProperty("opacity")||r.hasOwnProperty("colorAlpha")||(r.opacity=[0,0]))}})))}function l(t){var e=(t.inRange||{}).symbol||(t.outOfRange||{}).symbol,n=(t.inRange||{}).symbolSize||(t.outOfRange||{}).symbolSize,i=this.get("inactiveColor"),r=this.getItemSymbol(),o=r||"roundRect";XA(this.stateList,(function(r){var s=this.itemSize,l=t[r];l||(l=t[r]={color:a?i:[i]}),null==l.symbol&&(l.symbol=e&&_["d"](e)||(a?o:[o])),null==l.symbolSize&&(l.symbolSize=n&&_["d"](n)||(a?s[0]:[s[0],s[0]])),l.symbol=HA(l.symbol,(function(t){return"none"===t?o:t}));var u=l.symbolSize;if(null!=u){var c=-1/0;UA(u,(function(t){t>c&&(c=t)})),l.symbolSize=HA(u,(function(t){return qA(t,[0,c],[0,s[0]],!0)}))}}),this)}o.call(this,i),o.call(this,r),s.call(this,i,"inRange","outOfRange"),l.call(this,r)},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},e}(Xi["a"]),KA=YA,QA=[20,140],JA=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.optionUpdated=function(e,n){t.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual((function(t){t.mappingMethod="linear",t.dataExtent=this.getExtent()})),this._resetRange()},e.prototype.resetItemSize=function(){t.prototype.resetItemSize.apply(this,arguments);var e=this.itemSize;(null==e[0]||isNaN(e[0]))&&(e[0]=QA[0]),(null==e[1]||isNaN(e[1]))&&(e[1]=QA[1])},e.prototype._resetRange=function(){var t=this.getExtent(),e=this.option.range;!e||e.auto?(t.auto=1,this.option.range=t):_["t"](e)&&(e[0]>e[1]&&e.reverse(),e[0]=Math.max(e[0],t[0]),e[1]=Math.min(e[1],t[1]))},e.prototype.completeVisualOption=function(){t.prototype.completeVisualOption.apply(this,arguments),_["k"](this.stateList,(function(t){var e=this.option.controller[t].symbolSize;e&&e[0]!==e[1]&&(e[0]=e[1]/3)}),this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),e=Be["c"]((this.get("range")||[]).slice());return e[0]>t[1]&&(e[0]=t[1]),e[1]>t[1]&&(e[1]=t[1]),e[0]=n[1]||t<=e[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var e=[];return this.eachTargetSeries((function(n){var i=[],r=n.getData();r.each(this.getDataDimensionIndex(r),(function(e,n){t[0]<=e&&e<=t[1]&&i.push(n)}),this),e.push({seriesId:n.id,dataIndex:i})}),this),e},e.prototype.getVisualMeta=function(t){var e=$A(this,"outOfRange",this.getExtent()),n=$A(this,"inRange",this.option.range.slice()),i=[];function r(e,n){i.push({value:e,color:t(e,n)})}for(var a=0,o=0,s=n.length,l=e.length;ot[1])break;i.push({color:this.getControllerVisual(o,"color",e),offset:a/n})}return i.push({color:this.getControllerVisual(t[1],"color",e),offset:1}),i},e.prototype._createBarPoints=function(t,e){var n=this.visualMapModel.itemSize;return[[n[0]-e[0],t[0]],[n[0],t[0]],[n[0],t[1]],[n[0]-e[1],t[1]]]},e.prototype._createBarGroup=function(t){var e=this._orient,n=this.visualMapModel.get("inverse");return new Jt["a"]("horizontal"!==e||n?"horizontal"===e&&n?{scaleX:"bottom"===t?-1:1,rotation:-Math.PI/2}:"vertical"!==e||n?{scaleX:"left"===t?1:-1}:{scaleX:"left"===t?1:-1,scaleY:-1}:{scaleX:"bottom"===t?1:-1,rotation:Math.PI/2})},e.prototype._updateHandle=function(t,e){if(this._useHandle){var n=this._shapes,i=this.visualMapModel,r=n.handleThumbs,a=n.handleLabels,o=i.itemSize,s=i.getExtent();sC([0,1],(function(l){var u=r[l];u.setStyle("fill",e.handlesColor[l]),u.y=t[l];var c=oC(t[l],[0,o[1]],s,!0),h=this.getControllerVisual(c,"symbolSize");u.scaleX=u.scaleY=h/o[0],u.x=o[0]-h/2;var d=ne["applyTransform"](n.handleLabelPoints[l],ne["getTransform"](u,this.group));a[l].setStyle({x:d[0],y:d[1],text:i.formatValueText(this._dataInterval[l]),verticalAlign:"middle",align:"vertical"===this._orient?this._applyTransform("left",n.mainGroup):"center"})}),this)}},e.prototype._showIndicator=function(t,e,n,i){var r=this.visualMapModel,a=r.getExtent(),o=r.itemSize,s=[0,o[1]],l=this._shapes,u=l.indicator;if(u){u.attr("invisible",!1);var c={convertOpacityToAlpha:!0},h=this.getControllerVisual(t,"color",c),d=this.getControllerVisual(t,"symbolSize"),f=oC(t,a,s,!0),p=o[0]-d/2,g={x:u.x,y:u.y};u.y=f,u.x=p;var m=ne["applyTransform"](l.indicatorLabelPoint,ne["getTransform"](u,this.group)),v=l.indicatorLabel;v.attr("invisible",!1);var y=this._applyTransform("left",l.mainGroup),_=this._orient,b="horizontal"===_;v.setStyle({text:(n||"")+r.formatValueText(e),verticalAlign:b?y:"middle",align:b?"center":y});var x={x:p,y:f,style:{fill:h}},w={style:{x:m[0],y:m[1]}};if(r.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var O={duration:100,easing:"cubicInOut",additive:!0};u.x=g.x,u.y=g.y,u.animateTo(x,O),v.animateTo(w,O)}else u.attr(x),v.attr(w);this._firstShowIndicator=!1;var S=this._shapes.handleLabels;if(S)for(var T=0;Tr[1]&&(u[1]=1/0),e&&(u[0]===-1/0?this._showIndicator(l,u[1],"< ",o):u[1]===1/0?this._showIndicator(l,u[0],"> ",o):this._showIndicator(l,l,"≈ ",o));var c=this._hoverLinkDataIndices,h=[];(e||gC(n))&&(h=this._hoverLinkDataIndices=n.findTargetDataIndices(u));var d=Te["d"](c,h);this._dispatchHighDown("downplay",aC(d[0],n)),this._dispatchHighDown("highlight",aC(d[1],n))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var e=t.target,n=this.visualMapModel;if(e&&null!=Object(ie["a"])(e).dataIndex){var i=Object(ie["a"])(e),r=this.ecModel.getSeriesByIndex(i.seriesIndex);if(n.isTargetSeries(r)){var a=r.getData(i.dataType),o=a.getStore().get(n.getDataDimensionIndex(a),i.dataIndex);isNaN(o)||this._showIndicator(o,o)}}},e.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var e=this._shapes.handleLabels;if(e)for(var n=0;n=0&&(r.dimension=a,i.push(r))}})),t.getData().setVisual("visualMeta",i)}}];function xC(t,e,n,i){for(var r=e.targetVisuals[i],a=Gu.prepareVisualTypes(r),o={color:Object(TS["b"])(t.getData(),"color")},s=0,l=a.length;s0:t.splitNumber>0)&&!t.calculable?"piecewise":"continuous"})),t.registerAction(yC,_C),Object(_["k"])(bC,(function(e){t.registerVisual(t.PRIORITY.VISUAL.COMPONENT,e)})),t.registerPreprocessor(OC))}function AC(t){t.registerComponentModel(tC),t.registerComponentView(vC),MC(t)}var CC=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._pieceList=[],n}return Object(qt["a"])(e,t),e.prototype.optionUpdated=function(e,n){t.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var i=this._mode=this._determineMode();this._pieceList=[],IC[this._mode].call(this,this._pieceList),this._resetSelected(e,n);var r=this.option.categories;this.resetVisual((function(t,e){"categories"===i?(t.mappingMethod="category",t.categories=_["d"](r)):(t.dataExtent=this.getExtent(),t.mappingMethod="piecewise",t.pieceList=_["H"](this._pieceList,(function(t){return t=_["d"](t),"inRange"!==e&&(t.visual=null),t})))}))},e.prototype.completeVisualOption=function(){var e=this.option,n={},i=Gu.listVisualTypes(),r=this.isCategory();function a(t,e,n){return t&&t[e]&&t[e].hasOwnProperty(n)}_["k"](e.pieces,(function(t){_["k"](i,(function(e){t.hasOwnProperty(e)&&(n[e]=1)}))})),_["k"](n,(function(t,n){var i=!1;_["k"](this.stateList,(function(t){i=i||a(e,t,n)||a(e.target,t,n)}),this),!i&&_["k"](this.stateList,(function(t){(e[t]||(e[t]={}))[n]=GA.get(n,"inRange"===t?"active":"inactive",r)}))}),this),t.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,e){var n=this.option,i=this._pieceList,r=(e?n:t).selected||{};if(n.selected=r,_["k"](i,(function(t,e){var n=this.getSelectedMapKey(t);r.hasOwnProperty(n)||(r[n]=!0)}),this),"single"===n.selectedMode){var a=!1;_["k"](i,(function(t,e){var n=this.getSelectedMapKey(t);r[n]&&(a?r[n]=!1:a=!0)}),this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return"categories"===this._mode?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=_["d"](t)},e.prototype.getValueState=function(t){var e=Gu.findPieceIndex(t,this._pieceList);return null!=e&&this.option.selected[this.getSelectedMapKey(this._pieceList[e])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var e=[],n=this._pieceList;return this.eachTargetSeries((function(i){var r=[],a=i.getData();a.each(this.getDataDimensionIndex(a),(function(e,i){var a=Gu.findPieceIndex(e,n);a===t&&r.push(i)}),this),e.push({seriesId:i.id,dataIndex:r})}),this),e},e.prototype.getRepresentValue=function(t){var e;if(this.isCategory())e=t.value;else if(null!=t.value)e=t.value;else{var n=t.interval||[];e=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return e},e.prototype.getVisualMeta=function(t){if(!this.isCategory()){var e=[],n=["",""],i=this,r=this._pieceList.slice();if(r.length){var a=r[0].interval[0];a!==-1/0&&r.unshift({interval:[-1/0,a]}),a=r[r.length-1].interval[1],a!==1/0&&r.push({interval:[a,1/0]})}else r.push({interval:[-1/0,1/0]});var o=-1/0;return _["k"](r,(function(t){var e=t.interval;e&&(e[0]>o&&s([o,e[0]],"outOfRange"),s(e.slice()),o=e[1])}),this),{stops:e,outerColors:n}}function s(r,a){var o=i.getRepresentValue({interval:r});a||(a=i.getValueState(o));var s=t(o,a);r[0]===-1/0?n[0]=s:r[1]===1/0?n[1]=s:e.push({value:r[0],color:s},{value:r[1],color:s})}},e.type="visualMap.piecewise",e.defaultOption=Object(bn["d"])(KA.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e}(KA),IC={splitNumber:function(t){var e=this.option,n=Math.min(e.precision,20),i=this.getExtent(),r=e.splitNumber;r=Math.max(parseInt(r,10),1),e.splitNumber=r;var a=(i[1]-i[0])/r;while(+a.toFixed(n)!==a&&n<5)n++;e.precision=n,a=+a.toFixed(n),e.minOpen&&t.push({interval:[-1/0,i[0]],close:[0,0]});for(var o=0,s=i[0];o","≥"][e[0]]];t.text=t.text||this.formatValueText(null!=t.value?t.value:t.interval,!1,n)}),this)}};function DC(t,e){var n=t.inverse;("vertical"===t.orient?!n:n)&&e.reverse()}var LC=CC,EC=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return Object(qt["a"])(e,t),e.prototype.doRender=function(){var t=this.group;t.removeAll();var e=this.visualMapModel,n=e.get("textGap"),i=e.textStyleModel,r=i.getFont(),a=i.getTextColor(),o=this._getItemAlign(),s=e.itemSize,l=this._getViewData(),u=l.endsText,c=_["O"](e.get("showLabel",!0),!u);u&&this._renderEndsText(t,u[0],s,c,o),_["k"](l.viewPieceList,(function(i){var l=i.piece,u=new Jt["a"];u.onclick=_["c"](this._onItemClick,this,l),this._enableHoverLink(u,i.indexInModelPieceList);var h=e.getRepresentValue(l);if(this._createItemSymbol(u,h,[0,0,s[0],s[1]]),c){var d=this.visualMapModel.getValueState(h);u.add(new $["a"]({style:{x:"right"===o?-n:s[0]+n,y:s[1]/2,text:l.text,verticalAlign:"middle",align:o,font:r,fill:a,opacity:"outOfRange"===d?.5:1}}))}t.add(u)}),this),u&&this._renderEndsText(t,u[1],s,c,o),ri["b"](e.get("orient"),t,e.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,e){var n=this;t.on("mouseover",(function(){return i("highlight")})).on("mouseout",(function(){return i("downplay")}));var i=function(t){var i=n.visualMapModel;i.option.hoverLink&&n.api.dispatchAction({type:t,batch:aC(i.findTargetDataIndices(e),i)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,e=t.option;if("vertical"===e.orient)return rC(t,this.api,t.itemSize);var n=e.align;return n&&"auto"!==n||(n="left"),n},e.prototype._renderEndsText=function(t,e,n,i,r){if(e){var a=new Jt["a"],o=this.visualMapModel.textStyleModel;a.add(new $["a"]({style:Object(le["c"])(o,{x:i?"right"===r?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:i?r:"center",text:e})})),t.add(a)}},e.prototype._getViewData=function(){var t=this.visualMapModel,e=_["H"](t.getPieceList(),(function(t,e){return{piece:t,indexInModelPieceList:e}})),n=t.get("text"),i=t.get("orient"),r=t.get("inverse");return("horizontal"===i?r:!r)?e.reverse():n&&(n=n.slice().reverse()),{viewPieceList:e,endsText:n}},e.prototype._createItemSymbol=function(t,e,n){t.add(Object(Qt["a"])(this.getControllerVisual(e,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(e,"color")))},e.prototype._onItemClick=function(t){var e=this.visualMapModel,n=e.option,i=n.selectedMode;if(i){var r=_["d"](n.selected),a=e.getSelectedMapKey(t);"single"===i||!0===i?(r[a]=!0,_["k"](r,(function(t,e){r[e]=e===a}))):r[a]=!r[a],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:r})}},e.type="visualMap.piecewise",e}(nC),jC=EC;function PC(t){t.registerComponentModel(LC),t.registerComponentView(jC),MC(t)}function NC(t){Object(i["a"])(AC),Object(i["a"])(PC)}var RC={label:{enabled:!0},decal:{show:!1}},kC=Object(Te["o"])(),BC={};function zC(t,e){var n=t.getModel("aria");if(n.get("enabled")){var i=_["d"](RC);_["I"](i.label,t.getLocaleModel().get("aria"),!1),_["I"](n.option,i,!1),r(),a()}function r(){var e=n.getModel("decal"),i=e.get("show");if(i){var r=_["f"]();t.eachSeries((function(t){if(!t.isColorBySeries()){var e=r.get(t.type);e||(e={},r.set(t.type,e)),kC(t).scope=e}})),t.eachRawSeries((function(e){if(!t.isSeriesFiltered(e))if(_["w"](e.enableAriaDecal))e.enableAriaDecal();else{var n=e.getData();if(e.isColorBySeries()){var i=Object(Wl["b"])(e.ecModel,e.name,BC,t.getSeriesCount()),r=n.getVisual("decal");n.setVisual("decal",u(r,i))}else{var a=e.getRawData(),o={},s=kC(e).scope;n.each((function(t){var e=n.getRawIndex(t);o[e]=t}));var l=a.count();a.each((function(t){var i=o[t],r=a.getName(t)||t+"",c=Object(Wl["b"])(e.ecModel,r,s,l),h=n.getItemVisual(i,"decal");n.setItemVisual(i,"decal",u(h,c))}))}}function u(t,e){var n=t?_["m"](_["m"]({},e),t):e;return n.dirty=!0,n}}))}}function a(){var i=t.getLocaleModel().get("aria"),r=n.getModel("label");if(r.option=_["i"](r.option,i),r.get("enabled")){var a=e.getZr().dom;if(r.get("description"))a.setAttribute("aria-label",r.get("description"));else{var u,c=t.getSeriesCount(),h=r.get(["data","maxCount"])||10,d=r.get(["series","maxCount"])||10,f=Math.min(c,d);if(!(c<1)){var p=s();if(p){var g=r.get(["general","withTitle"]);u=o(g,{title:p})}else u=r.get(["general","withoutTitle"]);var m=[],v=c>1?r.get(["series","multiple","prefix"]):r.get(["series","single","prefix"]);u+=o(v,{seriesCount:c}),t.eachSeries((function(t,e){if(e1?r.get(["series","multiple",a]):r.get(["series","single",a]),n=o(n,{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:l(t.subType)});var s=t.getData();if(s.count()>h){var u=r.get(["data","partialData"]);n+=o(u,{displayCnt:h})}else n+=r.get(["data","allData"]);for(var d=r.get(["data","separator","middle"]),p=r.get(["data","separator","end"]),g=[],v=0;v":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},HC=function(){function t(t){var e=this._condVal=Object(_["C"])(t)?new RegExp(t):Object(_["B"])(t)?t:null;if(null==e){var n="";0,Object(Su["c"])(n)}}return t.prototype.evaluate=function(t){var e=typeof t;return Object(_["C"])(e)?this._condVal.test(t):!!Object(_["z"])(e)&&this._condVal.test(t+"")},t}(),UC=function(){function t(){}return t.prototype.evaluate=function(){return this.value},t}(),WC=function(){function t(){}return t.prototype.evaluate=function(){for(var t=this.children,e=0;e2&&l.push(e),e=[t,n]}function p(t,n,i,r){sI(t,i)&&sI(n,r)||e.push(t,n,i,r,i,r)}function g(t,n,i,r,a,o){var s=Math.abs(n-t),l=4*Math.tan(s/4)/3,u=nS:A2&&l.push(e),l}function uI(t,e,n,i,r,a,o,s,l,u){if(sI(t,n)&&sI(e,i)&&sI(r,o)&&sI(a,s))l.push(o,s);else{var c=2/u,h=c*c,d=o-t,f=s-e,p=Math.sqrt(d*d+f*f);d/=p,f/=p;var g=n-t,m=i-e,v=r-o,y=a-s,_=g*g+m*m,b=v*v+y*y;if(_=0&&S=0)l.push(o,s);else{var T=[],M=[];Object(Me["g"])(t,n,r,o,.5,T),Object(Me["g"])(e,i,a,s,.5,M),uI(T[0],M[0],T[1],M[1],T[2],M[2],T[3],M[3],l,u),uI(T[4],M[4],T[5],M[5],T[6],M[6],T[7],M[7],l,u)}}}}function cI(t,e){var n=lI(t),i=[];e=e||1;for(var r=0;r0)for(u=0;uMath.abs(u),h=hI([l,u],c?0:1,e),d=(c?s:u)/h.length,f=0;fr,o=hI([i,r],a?0:1,e),s=a?"width":"height",l=a?"height":"width",u=a?"x":"y",c=a?"y":"x",h=t[s]/o.length,d=0;d1?null:new di["a"](g*l+t,g*u+e)}function mI(t,e,n){var i=new di["a"];di["a"].sub(i,n,e),i.normalize();var r=new di["a"];di["a"].sub(r,t,e);var a=r.dot(i);return a}function vI(t,e){var n=t[t.length-1];n&&n[0]===e[0]&&n[1]===e[1]||t.push(e)}function yI(t,e,n){for(var i=t.length,r=[],a=0;ao?(u.x=c.x=s+a/2,u.y=l,c.y=l+o):(u.y=c.y=l+o/2,u.x=s,c.x=s+a),yI(e,u,c)}function bI(t,e,n,i){if(1===n)i.push(e);else{var r=Math.floor(n/2),a=t(e);bI(t,a[0],r,i),bI(t,a[1],n-r,i)}return i}function xI(t,e){for(var n=[],i=0;i0)for(var x=i/n,w=-i/2;w<=i/2;w+=x){var O=Math.sin(w),S=Math.cos(w),T=0;for(_=0;_0;u/=2){var c=0,h=0;(t&u)>0&&(c=1),(e&u)>0&&(h=1),l+=u*u*(3*c^h),0===h&&(1===c&&(t=u-1-t,e=u-1-e),s=t,t=e,e=s)}return l}function VI(t){var e=1/0,n=1/0,i=-1/0,r=-1/0,a=Object(_["H"])(t,(function(t){var a=t.getBoundingRect(),o=t.getComputedTransform(),s=a.x+a.width/2+(o?o[4]:0),l=a.y+a.height/2+(o?o[5]:0);return e=Math.min(s,e),n=Math.min(l,n),i=Math.max(s,i),r=Math.max(l,r),[s,l]})),o=Object(_["H"])(a,(function(a,o){return{cp:a,z:zI(a[0],a[1],e,n,i,r),path:t[o]}}));return o.sort((function(t,e){return t.z-e.z})).map((function(t){return t.path}))}function FI(t){return SI(t.path,t.count)}function GI(){return{fromIndividuals:[],toIndividuals:[],count:0}}function HI(t,e,n){var i=[];function r(t){for(var e=0;e=0;r--)if(!n[r].many.length){var l=n[s].many;if(l.length<=1){if(!s)return n;s=0}a=l.length;var u=Math.ceil(a/2);n[r].many=l.slice(u,a),n[s].many=l.slice(0,u),s++}return n}var ZI={clone:function(t){for(var e=[],n=1-Math.pow(1-t.path.style.opacity,1/t.count),i=0;i0){var s,l,u=i.getModel("universalTransition").get("delay"),c=Object.assign({setToFinal:!0},o);WI(t)&&(s=t,l=e),WI(e)&&(s=e,l=t);for(var h=s?s===t:t.length>e.length,d=s?XI(l,s):XI(h?e:t,[h?t:e]),f=0,p=0;pKI))for(var i=n.getIndices(),r=JI(n),a=0;a0&&r.group.traverse((function(t){t instanceof s["b"]&&!t.animators.length&&t.animateFrom({style:{opacity:0}},a)}))}))}function oD(t){var e=t.getModel("universalTransition").get("seriesKey");return e||t.id}function sD(t){return Object(_["t"])(t)?t.sort().join(","):t}function lD(t){if(t.hostModel)return t.hostModel.getModel("universalTransition").get("divideShape")}function uD(t,e){var n=Object(_["f"])(),i=Object(_["f"])(),r=Object(_["f"])();return Object(_["k"])(t.oldSeries,(function(e,n){var a=t.oldData[n],o=oD(e),s=sD(o);i.set(s,a),Object(_["t"])(o)&&Object(_["k"])(o,(function(t){r.set(t,{data:a,key:s})}))})),Object(_["k"])(e.updatedSeries,(function(t){if(t.isUniversalTransitionEnabled()&&t.isAnimationEnabled()){var e=t.getData(),a=oD(t),o=sD(a),s=i.get(o);if(s)n.set(o,{oldSeries:[{divide:lD(s),data:s}],newSeries:[{divide:lD(e),data:e}]});else if(Object(_["t"])(a)){0;var l=[];Object(_["k"])(a,(function(t){var e=i.get(t);e&&l.push({divide:lD(e),data:e})})),l.length&&n.set(o,{oldSeries:l,newSeries:[{data:e,divide:lD(e)}]})}else{var u=r.get(a);if(u){var c=n.get(u.key);c||(c={oldSeries:[{data:u.data,divide:lD(u.data)}],newSeries:[]},n.set(u.key,c)),c.newSeries.push({data:e,divide:lD(e)})}}}})),n}function cD(t,e){for(var n=0;n=0&&r.push({data:e.oldData[n],divide:lD(e.oldData[n]),dim:t.dimension})})),Object(_["k"])(Object(Te["r"])(t.to),(function(t){var e=cD(n.updatedSeries,t);if(e>=0){var i=n.updatedSeries[e].getData();a.push({data:i,divide:lD(i),dim:t.dimension})}})),r.length>0&&a.length>0&&aD(r,a,i)}function dD(t){t.registerUpdateLifecycle("series:beforeupdate",(function(t,e,n){Object(_["k"])(Object(Te["r"])(n.seriesTransition),(function(t){Object(_["k"])(Object(Te["r"])(t.to),(function(t){for(var e=n.updatedSeries,i=0;i1&&(o*=f(b),s*=f(b));var x=(r===a?-1:1)*f((o*o*(s*s)-o*o*(v*v)-s*s*(d*d))/(o*o*(v*v)+s*s*(d*d)))||0,w=x*o*v/s,O=x*-s*d/o,S=(t+n)/2+g(h)*w-p(h)*O,T=(e+i)/2+p(h)*w+g(h)*O,M=_([1,0],[(d-w)/o,(v-O)/s]),A=[(d-w)/o,(v-O)/s],C=[(-1*d-w)/o,(-1*v-O)/s],I=_(A,C);if(y(A,C)<=-1&&(I=m),y(A,C)>=1&&(I=0),I<0){var D=Math.round(I/m*1e6)/1e6;I=2*m+D%2*m}c.addData(u,S,T,o,s,M,I,h,a)}var x=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,w=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function O(t){var e=new a["a"];if(!t)return e;var n,i=0,r=0,o=i,s=r,l=a["a"].CMD,u=t.match(x);if(!u)return e;for(var c=0;c=0&&i(u)?u:.5;var c=t.createRadialGradient(s,l,0,s,l,u);return c}function o(t,e,n){for(var i="radial"===e.type?a(t,e,n):r(t,e,n),o=e.colorStops,s=0;s0){if(t<=r)return o;if(t>=a)return s}else{if(t>=r)return o;if(t<=a)return s}else{if(t===r)return o;if(t===a)return s}return(t-r)/l*u+o}function l(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 i["C"](t)?o(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t}function u(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),a),t=(+t).toFixed(e),n?t:+t}function c(t){return t.sort((function(t,e){return t-e})),t}function h(t){if(t=+t,isNaN(t))return 0;if(t>1e-14)for(var e=1,n=0;n<15;n++,e*=10)if(Math.round(t*e)/e===t)return n;return d(t)}function d(t){var e=t.toString().toLowerCase(),n=e.indexOf("e"),i=n>0?+e.slice(n+1):0,r=n>0?n:e.length,a=e.indexOf("."),o=a<0?0:r-1-a;return Math.max(0,o-i)}function f(t,e){var n=Math.log,i=Math.LN10,r=Math.floor(n(t[1]-t[0])/i),a=Math.round(n(Math.abs(e[1]-e[0]))/i),o=Math.min(Math.max(-r+a,0),20);return isFinite(o)?o:20}function p(t,e,n){if(!t[e])return 0;var r=i["N"](t,(function(t,e){return t+(isNaN(e)?0:e)}),0);if(0===r)return 0;var a=Math.pow(10,n),o=i["H"](t,(function(t){return(isNaN(t)?0:t)/r*a*100})),s=100*a,l=i["H"](o,(function(t){return Math.floor(t)})),u=i["N"](l,(function(t,e){return t+e}),0),c=i["H"](o,(function(t,e){return t-l[e]}));while(uh&&(h=c[f],d=f);++l[d],c[d]=0,++u}return l[e]/a}function g(t,e){var n=Math.max(h(t),h(e)),i=t+e;return n>a?i:u(i,n)}var m=9007199254740991;function v(t){var e=2*Math.PI;return(t%e+e)%e}function y(t){return t>-r&&t=10&&e++,e}function O(t,e){var n,i=w(t),r=Math.pow(10,i),a=t/r;return n=e?a<1.5?1:a<2.5?2:a<4?3:a<7?5:10:a<1?1:a<2?2:a<3?3:a<5?5:10,t=n*r,i>=-20?+t.toFixed(i<0?-i:0):t}function S(t,e){var n=(t.length-1)*e+1,i=Math.floor(n),r=+t[i-1],a=n-i;return a?r+a*(t[i]-r):r}function T(t){t.sort((function(t,e){return s(t,e,0)?-1:1}));for(var e=-1/0,n=1,i=0;i=0&&(s=u.interpolatedValue[l])}return null!=s?s+"":""}))}},t.prototype.getRawValue=function(t,e){return Object(r["e"])(this.getData(e),t)},t.prototype.formatTooltip=function(t,e,n){},t}();function l(t){var e,n;return i["A"](t)?t.type&&(n=t):e=t,{text:e,frag:n}}},"38ac":function(t,e,n){"use strict";n("a792")},3901:function(t,e,n){"use strict";n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return o}));var i=n("282b"),r=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],a=Object(i["a"])(r),o=function(){function t(){}return t.prototype.getLineStyle=function(t){return a(this,t)},t}()},"392f":function(t,e,n){"use strict";var i=n("21a10"),r=n("19eb"),a=n("9850"),o=[],s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.notClear=!0,e.incremental=!0,e._displayables=[],e._temporaryDisplayables=[],e._cursor=0,e}return Object(i["a"])(e,t),e.prototype.traverse=function(t,e){t.call(e,this)},e.prototype.useStyle=function(){this.style={}},e.prototype.getCursor=function(){return this._cursor},e.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},e.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},e.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},e.prototype.addDisplayable=function(t,e){e?this._temporaryDisplayables.push(t):this._displayables.push(t),this.markRedraw()},e.prototype.addDisplayables=function(t,e){e=e||!1;for(var n=0;n=400?t.onerror&&t.onerror():t.onload&&t.onload(e.response)},t.onerror&&(e.onerror=t.onerror),e.send(null)}e["a"]={get:i}},"401b":function(t,e,n){"use strict";function i(t,e){return null==t&&(t=0),null==e&&(e=0),[t,e]}function r(t,e){return t[0]=e[0],t[1]=e[1],t}function a(t){return[t[0],t[1]]}function o(t,e,n){return t[0]=e,t[1]=n,t}function s(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function l(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function u(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function c(t){return Math.sqrt(h(t))}n.d(e,"e",(function(){return i})),n.d(e,"d",(function(){return r})),n.d(e,"c",(function(){return a})),n.d(e,"p",(function(){return o})),n.d(e,"a",(function(){return s})),n.d(e,"o",(function(){return l})),n.d(e,"q",(function(){return u})),n.d(e,"i",(function(){return c})),n.d(e,"n",(function(){return d})),n.d(e,"m",(function(){return f})),n.d(e,"h",(function(){return p})),n.d(e,"f",(function(){return g})),n.d(e,"g",(function(){return v})),n.d(e,"j",(function(){return y})),n.d(e,"b",(function(){return _})),n.d(e,"l",(function(){return b})),n.d(e,"k",(function(){return x}));function h(t){return t[0]*t[0]+t[1]*t[1]}function d(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function f(t,e){var n=c(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t}function p(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}var g=p;function m(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}var v=m;function y(t,e,n,i){return t[0]=e[0]+i*(n[0]-e[0]),t[1]=e[1]+i*(n[1]-e[1]),t}function _(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t}function b(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function x(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}},4041:function(t,e,n){"use strict";n.d(e,"b",(function(){return s})),n.d(e,"a",(function(){return o}));var i=n("e0d3"),r=Object(i["o"])(),a=Object(i["o"])(),o=function(){function t(){}return t.prototype.getColorFromPalette=function(t,e,n){var a=Object(i["r"])(this.get("color",!0)),o=this.get("colorLayer",!0);return u(this,r,a,o,t,e,n)},t.prototype.clearColorPalette=function(){c(this,r)},t}();function s(t,e,n,r){var o=Object(i["r"])(t.get(["aria","decal","decals"]));return u(t,a,o,null,e,n,r)}function l(t,e){for(var n=t.length,i=0;ie)return t[i];return t[n-1]}function u(t,e,n,i,r,a,o){a=a||t;var s=e(a),u=s.paletteIdx||0,c=s.paletteNameMap=s.paletteNameMap||{};if(c.hasOwnProperty(r))return c[r];var h=null!=o&&i?l(i,o):n;if(h=h||n,h&&h.length){var d=h[u];return r&&(c[r]=d),s.paletteIdx=(u+1)%h.length,d}}function c(t,e){e(t).paletteIdx=0,e(t).paletteNameMap={}}},"41ef":function(t,e,n){"use strict";n.r(e),n.d(e,"parse",(function(){return v})),n.d(e,"lift",(function(){return b})),n.d(e,"toHex",(function(){return x})),n.d(e,"fastLerp",(function(){return w})),n.d(e,"fastMapToColor",(function(){return O})),n.d(e,"lerp",(function(){return S})),n.d(e,"mapToColor",(function(){return T})),n.d(e,"modifyHSL",(function(){return M})),n.d(e,"modifyAlpha",(function(){return A})),n.d(e,"stringify",(function(){return C})),n.d(e,"lum",(function(){return I})),n.d(e,"random",(function(){return D}));var i=n("d51b"),r={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function a(t){return t=Math.round(t),t<0?0:t>255?255:t}function o(t){return t=Math.round(t),t<0?0:t>360?360:t}function s(t){return t<0?0:t>1?1:t}function l(t){var e=t;return e.length&&"%"===e.charAt(e.length-1)?a(parseFloat(e)/100*255):a(parseInt(e,10))}function u(t){var e=t;return e.length&&"%"===e.charAt(e.length-1)?s(parseFloat(e)/100):s(parseFloat(e))}function c(t,e,n){return n<0?n+=1:n>1&&(n-=1),6*n<1?t+(e-t)*n*6:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}function h(t,e,n){return t+(e-t)*n}function d(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function f(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var p=new i["a"](20),g=null;function m(t,e){g&&f(g,e),g=p.put(t,g||e.slice())}function v(t,e){if(t){e=e||[];var n=p.get(t);if(n)return f(e,n);t+="";var i=t.replace(/ /g,"").toLowerCase();if(i in r)return f(e,r[i]),m(t,e),e;var a=i.length;if("#"!==i.charAt(0)){var o=i.indexOf("("),s=i.indexOf(")");if(-1!==o&&s+1===a){var c=i.substr(0,o),h=i.substr(o+1,s-(o+1)).split(","),g=1;switch(c){case"rgba":if(4!==h.length)return 3===h.length?d(e,+h[0],+h[1],+h[2],1):d(e,0,0,0,1);g=u(h.pop());case"rgb":return 3!==h.length?void d(e,0,0,0,1):(d(e,l(h[0]),l(h[1]),l(h[2]),g),m(t,e),e);case"hsla":return 4!==h.length?void d(e,0,0,0,1):(h[3]=u(h[3]),y(h,e),m(t,e),e);case"hsl":return 3!==h.length?void d(e,0,0,0,1):(y(h,e),m(t,e),e);default:return}}d(e,0,0,0,1)}else{if(4===a||5===a){var v=parseInt(i.slice(1,4),16);return v>=0&&v<=4095?(d(e,(3840&v)>>4|(3840&v)>>8,240&v|(240&v)>>4,15&v|(15&v)<<4,5===a?parseInt(i.slice(4),16)/15:1),m(t,e),e):void d(e,0,0,0,1)}if(7===a||9===a){v=parseInt(i.slice(1,7),16);return v>=0&&v<=16777215?(d(e,(16711680&v)>>16,(65280&v)>>8,255&v,9===a?parseInt(i.slice(7),16)/255:1),m(t,e),e):void d(e,0,0,0,1)}}}}function y(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=u(t[1]),r=u(t[2]),o=r<=.5?r*(i+1):r+i-r*i,s=2*r-o;return e=e||[],d(e,a(255*c(s,o,n+1/3)),a(255*c(s,o,n)),a(255*c(s,o,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function _(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,a=t[2]/255,o=Math.min(i,r,a),s=Math.max(i,r,a),l=s-o,u=(s+o)/2;if(0===l)e=0,n=0;else{n=u<.5?l/(s+o):l/(2-s-o);var c=((s-i)/6+l/2)/l,h=((s-r)/6+l/2)/l,d=((s-a)/6+l/2)/l;i===s?e=d-h:r===s?e=1/3+c-d:a===s&&(e=2/3+h-c),e<0&&(e+=1),e>1&&(e-=1)}var f=[360*e,n,u];return null!=t[3]&&f.push(t[3]),f}}function b(t,e){var n=v(t);if(n){for(var i=0;i<3;i++)n[i]=e<0?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0,n[i]>255?n[i]=255:n[i]<0&&(n[i]=0);return C(n,4===n.length?"rgba":"rgb")}}function x(t){var e=v(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function w(t,e,n){if(e&&e.length&&t>=0&&t<=1){n=n||[];var i=t*(e.length-1),r=Math.floor(i),o=Math.ceil(i),l=e[r],u=e[o],c=i-r;return n[0]=a(h(l[0],u[0],c)),n[1]=a(h(l[1],u[1],c)),n[2]=a(h(l[2],u[2],c)),n[3]=s(h(l[3],u[3],c)),n}}var O=w;function S(t,e,n){if(e&&e.length&&t>=0&&t<=1){var i=t*(e.length-1),r=Math.floor(i),o=Math.ceil(i),l=v(e[r]),u=v(e[o]),c=i-r,d=C([a(h(l[0],u[0],c)),a(h(l[1],u[1],c)),a(h(l[2],u[2],c)),s(h(l[3],u[3],c))],"rgba");return n?{color:d,leftIndex:r,rightIndex:o,value:i}:d}}var T=S;function M(t,e,n,i){var r=v(t);if(t)return r=_(r),null!=e&&(r[0]=o(e)),null!=n&&(r[1]=u(n)),null!=i&&(r[2]=u(i)),C(y(r),"rgba")}function A(t,e){var n=v(t);if(n&&null!=e)return n[3]=s(e),C(n,"rgba")}function C(t,e){if(t&&t.length){var n=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(n+=","+t[3]),e+"("+n+")"}}function I(t,e){var n=v(t);return n?(.299*n[0]+.587*n[1]+.114*n[2])*n[3]/255+(1-n[3])*e:0}function D(){return C([Math.round(255*Math.random()),Math.round(255*Math.random()),Math.round(255*Math.random())],"rgb")}},"42e5":function(t,e,n){"use strict";var i=function(){function t(t){this.colorStops=t||[]}return t.prototype.addColorStop=function(t,e){this.colorStops.push({offset:t,color:e})},t}();e["a"]=i},4319:function(t,e,n){"use strict";var i=n("22d1"),r=n("625e"),a=n("282b"),o=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],s=Object(a["a"])(o),l=function(){function t(){}return t.prototype.getAreaStyle=function(t,e){return s(this,t,e)},t}(),u=n("7837"),c=n("76a5"),h=["textStyle","color"],d=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],f=new c["a"],p=function(){function t(){}return t.prototype.getTextColor=function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(h):null)},t.prototype.getFont=function(){return Object(u["d"])({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},t.prototype.getTextRect=function(t){for(var e={text:t,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},n=0;n-o&&to||t<-o}function g(t,e,n,i,r){var a=1-r;return a*a*(a*t+3*r*e)+r*r*(r*i+3*a*n)}function m(t,e,n,i,r){var a=1-r;return 3*(((e-t)*a+2*(n-e)*r)*a+(i-n)*r*r)}function v(t,e,n,i,o,s){var c=i+3*(e-n)-t,h=3*(n-2*e+t),d=3*(e-t),p=t-o,g=h*h-3*c*d,m=h*d-9*c*p,v=d*d-3*h*p,y=0;if(f(g)&&f(m))if(f(h))s[0]=0;else{var _=-d/h;_>=0&&_<=1&&(s[y++]=_)}else{var b=m*m-4*g*v;if(f(b)){var x=m/g,w=(_=-h/c+x,-x/2);_>=0&&_<=1&&(s[y++]=_),w>=0&&w<=1&&(s[y++]=w)}else if(b>0){var O=a(b),S=g*h+1.5*c*(-m+O),T=g*h+1.5*c*(-m-O);S=S<0?-r(-S,u):r(S,u),T=T<0?-r(-T,u):r(T,u);_=(-h-(S+T))/(3*c);_>=0&&_<=1&&(s[y++]=_)}else{var M=(2*g*h-3*c*m)/(2*a(g*g*g)),A=Math.acos(M)/3,C=a(g),I=Math.cos(A),D=(_=(-h-2*C*I)/(3*c),w=(-h+C*(I+l*Math.sin(A)))/(3*c),(-h+C*(I-l*Math.sin(A)))/(3*c));_>=0&&_<=1&&(s[y++]=_),w>=0&&w<=1&&(s[y++]=w),D>=0&&D<=1&&(s[y++]=D)}}return y}function y(t,e,n,i,r){var o=6*n-12*e+6*t,s=9*e+3*i-3*t-9*n,l=3*e-3*t,u=0;if(f(s)){if(p(o)){var c=-l/o;c>=0&&c<=1&&(r[u++]=c)}}else{var h=o*o-4*s*l;if(f(h))r[0]=-o/(2*s);else if(h>0){var d=a(h),g=(c=(-o+d)/(2*s),(-o-d)/(2*s));c>=0&&c<=1&&(r[u++]=c),g>=0&&g<=1&&(r[u++]=g)}}return u}function _(t,e,n,i,r,a){var o=(e-t)*r+t,s=(n-e)*r+e,l=(i-n)*r+n,u=(s-o)*r+o,c=(l-s)*r+s,h=(c-u)*r+u;a[0]=t,a[1]=o,a[2]=u,a[3]=h,a[4]=h,a[5]=c,a[6]=l,a[7]=i}function b(t,e,n,r,o,l,u,f,p,m,v){var y,_,b,x,w,O=.005,S=1/0;c[0]=p,c[1]=m;for(var T=0;T<1;T+=.05)h[0]=g(t,n,o,u,T),h[1]=g(e,r,l,f,T),x=Object(i["g"])(c,h),x=0&&x=0&&c<=1&&(r[u++]=c)}}else{var h=s*s-4*o*l;if(f(h)){c=-s/(2*o);c>=0&&c<=1&&(r[u++]=c)}else if(h>0){var d=a(h),g=(c=(-s+d)/(2*o),(-s-d)/(2*o));c>=0&&c<=1&&(r[u++]=c),g>=0&&g<=1&&(r[u++]=g)}}return u}function T(t,e,n){var i=t+n-2*e;return 0===i?.5:(t-e)/i}function M(t,e,n,i,r){var a=(e-t)*i+t,o=(n-e)*i+e,s=(o-a)*i+a;r[0]=t,r[1]=a,r[2]=s,r[3]=s,r[4]=o,r[5]=n}function A(t,e,n,r,o,l,u,f,p){var g,m=.005,v=1/0;c[0]=u,c[1]=f;for(var y=0;y<1;y+=.05){h[0]=w(t,n,o,y),h[1]=w(e,r,l,y);var _=Object(i["g"])(c,h);_=0&&_E*E+j*j&&(M=C,A=I),{cx:M,cy:A,x0:-c,y0:-h,x1:M*(r/O-1),y1:A*(r/O-1)}}function _(t){var e;if(Object(a["t"])(t)){var n=t.length;if(!n)return t;e=1===n?[t[0],t[0],0,0]:2===n?[t[0],t[0],t[1],t[1]]:3===n?t.concat(t[2]):t}else e=[t,t,t,t];return e}function b(t,e){var n,i=p(e.r,0),r=p(e.r0||0,0),a=i>0,b=r>0;if(a||b){if(a||(i=r,r=0),r>i){var x=i;i=r,r=x}var w=e.startAngle,O=e.endAngle;if(!isNaN(w)&&!isNaN(O)){var S=e.cx,T=e.cy,M=!!e.clockwise,A=d(O-w),C=A>s&&A%s;if(C>m&&(A=C),i>m)if(A>s-m)t.moveTo(S+i*u(w),T+i*l(w)),t.arc(S,T,i,w,O,!M),r>m&&(t.moveTo(S+r*u(O),T+r*l(O)),t.arc(S,T,r,O,w,M));else{var I=void 0,D=void 0,L=void 0,E=void 0,j=void 0,P=void 0,N=void 0,R=void 0,k=void 0,B=void 0,z=void 0,V=void 0,F=void 0,G=void 0,H=void 0,U=void 0,W=i*u(w),X=i*l(w),Z=r*u(O),q=r*l(O),Y=A>m;if(Y){var K=e.cornerRadius;K&&(n=_(K),I=n[0],D=n[1],L=n[2],E=n[3]);var Q=d(i-r)/2;if(j=g(Q,L),P=g(Q,E),N=g(Q,I),R=g(Q,D),z=k=p(j,P),V=B=p(N,R),(k>m||B>m)&&(F=i*u(O),G=i*l(O),H=r*u(w),U=r*l(w),Am){var at=g(L,z),ot=g(E,z),st=y(H,U,W,X,i,at,M),lt=y(F,G,Z,q,i,ot,M);t.moveTo(S+st.cx+st.x0,T+st.cy+st.y0),z0&&t.arc(S+st.cx,T+st.cy,at,h(st.y0,st.x0),h(st.y1,st.x1),!M),t.arc(S,T,i,h(st.cy+st.y1,st.cx+st.x1),h(lt.cy+lt.y1,lt.cx+lt.x1),!M),ot>0&&t.arc(S+lt.cx,T+lt.cy,ot,h(lt.y1,lt.x1),h(lt.y0,lt.x0),!M))}else t.moveTo(S+W,T+X),t.arc(S,T,i,w,O,!M);else t.moveTo(S+W,T+X);if(r>m&&Y)if(V>m){at=g(I,V),ot=g(D,V),st=y(Z,q,F,G,r,-ot,M),lt=y(W,X,H,U,r,-at,M);t.lineTo(S+st.cx+st.x0,T+st.cy+st.y0),V0&&t.arc(S+st.cx,T+st.cy,ot,h(st.y0,st.x0),h(st.y1,st.x1),!M),t.arc(S,T,r,h(st.cy+st.y1,st.cx+st.x1),h(lt.cy+lt.y1,lt.cx+lt.x1),M),at>0&&t.arc(S+lt.cx,T+lt.cy,at,h(lt.y1,lt.x1),h(lt.y0,lt.x0),!M))}else t.lineTo(S+Z,T+q),t.arc(S,T,r,O,w,M);else t.lineTo(S+Z,T+q)}else t.moveTo(S,T);t.closePath()}}}var x=function(){function t(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0,this.cornerRadius=0}return t}(),w=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype.getDefaultShape=function(){return new x},e.prototype.buildPath=function(t,e){b(t,e)},e.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},e}(r["b"]);w.prototype.type="sector";e["a"]=w},"4bc4":function(t,e,n){"use strict";n.d(e,"a",(function(){return i})),n.d(e,"c",(function(){return r})),n.d(e,"b",(function(){return a}));var i=1,r=2,a=4},"4f85":function(t,e,n){"use strict";n.d(e,"a",(function(){return v}));var i=n("7fae"),r=n("6d8b"),a=n("22d1"),o=n("e0d3"),s=n("6cb7"),l=n("4041"),u=n("38a2"),c=n("f934"),h=n("9fbc"),d=n("625e"),f=n("f72b"),p=n("f6d8"),g=o["o"]();function m(t,e){return t.getName(e)||t.getId(e)}var v="__universalTransitionEnabled",y=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._selectedDataIndicesMap={},e}return Object(i["a"])(e,t),e.prototype.init=function(t,e,n){this.seriesIndex=this.componentIndex,this.dataTask=Object(h["a"])({count:x,reset:w}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n);var i=g(this).sourceManager=new f["a"](this);i.prepareSource();var r=this.getInitialData(t,n);S(r,this),this.dataTask.context.data=r,g(this).dataBeforeProcessed=r,_(this),this._initSelectedMapFromData(r)},e.prototype.mergeDefaultAndTheme=function(t,e){var n=Object(c["d"])(this),i=n?Object(c["f"])(t):{},a=this.subType;s["a"].hasClass(a)&&(a+="Series"),r["I"](t,e.getTheme().get(this.subType)),r["I"](t,this.getDefaultOption()),o["f"](t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Object(c["h"])(t,i,n)},e.prototype.mergeOption=function(t,e){t=r["I"](this.option,t,!0),this.fillDataTextStyle(t.data);var n=Object(c["d"])(this);n&&Object(c["h"])(this.option,t,n);var i=g(this).sourceManager;i.dirty(),i.prepareSource();var a=this.getInitialData(t,e);S(a,this),this.dataTask.dirty(),this.dataTask.context.data=a,g(this).dataBeforeProcessed=a,_(this),this._initSelectedMapFromData(a)},e.prototype.fillDataTextStyle=function(t){if(t&&!r["E"](t))for(var e=["show"],n=0;nthis.getShallow("animationThreshold")&&(e=!1),!!e},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,e,n){var i=this.ecModel,r=l["a"].prototype.getColorFromPalette.call(this,t,e,n);return r||(r=i.getColorFromPalette(t,e,n)),r},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,e){this._innerSelect(this.getData(e),t)},e.prototype.unselect=function(t,e){var n=this.option.selectedMap;if(n){var i=this.option.selectedMode,r=this.getData(e);if("series"===i||"all"===n)return this.option.selectedMap={},void(this._selectedDataIndicesMap={});for(var a=0;a=0&&n.push(a)}return n},e.prototype.isSelected=function(t,e){var n=this.option.selectedMap;if(!n)return!1;var i=this.getData(e);return("all"===n||n[m(i,t)])&&!i.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[v])return!0;var t=this.option.universalTransition;return!!t&&(!0===t||t&&t.enabled)},e.prototype._innerSelect=function(t,e){var n,i,a=this.option,o=a.selectedMode,s=e.length;if(o&&s)if("series"===o)a.selectedMap="all";else if("multiple"===o){r["A"](a.selectedMap)||(a.selectedMap={});for(var l=a.selectedMap,u=0;u0&&this._innerSelect(t,e)}},e.registerClass=function(t){return s["a"].registerClass(t)},e.protoInitialize=function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"}(),e}(s["a"]);function _(t){var e=t.name;o["n"](t)||(t.name=b(t)||e)}function b(t){var e=t.getRawData(),n=e.mapDimensionsAll("seriesName"),i=[];return r["k"](n,(function(t){var n=e.getDimensionInfo(t);n.displayName&&i.push(n.displayName)})),i.join(" ")}function x(t){return t.model.getRawData().count()}function w(t){var e=t.model;return e.setData(e.getRawData().cloneShallow()),O}function O(t,e){e.outputData&&t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function S(t,e){r["k"](r["e"](t.CHANGABLE_METHODS,t.DOWNSAMPLE_METHODS),(function(n){t.wrapMethod(n,r["h"](T,e))}))}function T(t,e){var n=M(t);return n&&n.setOutputEnd((e||this).count()),e}function M(t){var e=(t.ecModel||{}).scheduler,n=e&&e.getPipeline(t.uid);if(n){var i=n.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(t.uid))}return i}}r["K"](y,u["a"]),r["K"](y,l["a"]),Object(d["e"])(y,s["a"]),e["b"]=y},"4fac":function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var i=n("401b");function r(t,e,n,r){var a,o,s,l,u=[],c=[],h=[],d=[];if(r){s=[1/0,1/0],l=[-1/0,-1/0];for(var f=0,p=t.length;f=2){if(i){var o=r(a,i,n,e.smoothConstraint);t.moveTo(a[0][0],a[0][1]);for(var s=a.length,l=0;l<(n?s:s-1);l++){var u=o[2*l],c=o[2*l+1],h=a[(l+1)%s];t.bezierCurveTo(u[0],u[1],c[0],c[1],h[0],h[1])}}else{t.moveTo(a[0][0],a[0][1]);l=1;for(var d=a.length;l0))}function m(t){return"string"===typeof t&&"none"!==t}function v(t){var e=t.fill;return null!=e&&"none"!==e}function y(t,e){if(null!=e.fillOpacity&&1!==e.fillOpacity){var n=t.globalAlpha;t.globalAlpha=e.fillOpacity*e.opacity,t.fill(),t.globalAlpha=n}else t.fill()}function _(t,e){if(null!=e.strokeOpacity&&1!==e.strokeOpacity){var n=t.globalAlpha;t.globalAlpha=e.strokeOpacity*e.opacity,t.stroke(),t.globalAlpha=n}else t.stroke()}function b(t,e,n){var i=Object(a["a"])(e.image,e.__image,n);if(Object(a["c"])(i)){var r=t.createPattern(i,e.repeat||"repeat");if("function"===typeof DOMMatrix&&r&&r.setTransform){var o=new DOMMatrix;o.translateSelf(e.x||0,e.y||0),o.rotateSelf(0,0,(e.rotation||0)*c["a"]),o.scaleSelf(e.scaleX||1,e.scaleY||1),r.setTransform(o)}return r}}function x(t,e,n,i){var r,a=g(n),s=v(n),l=n.strokePercent,u=l<1,c=!e.path;e.silent&&!u||!c||e.createPathProxy();var f=e.path||p,m=e.__dirty;if(!i){var x=n.fill,w=n.stroke,O=s&&!!x.colorStops,S=a&&!!w.colorStops,T=s&&!!x.image,M=a&&!!w.image,A=void 0,C=void 0,I=void 0,D=void 0,L=void 0;(O||S)&&(L=e.getBoundingRect()),O&&(A=m?Object(o["a"])(t,x,L):e.__canvasFillGradient,e.__canvasFillGradient=A),S&&(C=m?Object(o["a"])(t,w,L):e.__canvasStrokeGradient,e.__canvasStrokeGradient=C),T&&(I=m||!e.__canvasFillPattern?b(t,x,e):e.__canvasFillPattern,e.__canvasFillPattern=I),M&&(D=m||!e.__canvasStrokePattern?b(t,w,e):e.__canvasStrokePattern,e.__canvasStrokePattern=I),O?t.fillStyle=A:T&&(I?t.fillStyle=I:s=!1),S?t.strokeStyle=C:M&&(D?t.strokeStyle=D:a=!1)}var E,j,P=e.getGlobalScale();f.setScale(P[0],P[1],e.segmentIgnoreThreshold),t.setLineDash&&n.lineDash&&(r=Object(h["a"])(e),E=r[0],j=r[1]);var N=!0;(c||m&d["b"])&&(f.setDPR(t.dpr),u?f.setContext(null):(f.setContext(t),N=!1),f.reset(),e.buildPath(f,e.shape,i),f.toStatic(),e.pathUpdated()),N&&f.rebuildPath(t,u?l:1),E&&(t.setLineDash(E),t.lineDashOffset=j),i||(n.strokeFirst?(a&&_(t,n),s&&y(t,n)):(s&&y(t,n),a&&_(t,n))),E&&t.setLineDash([])}function w(t,e,n){var i=e.__image=Object(a["a"])(n.image,e.__image,e,e.onload);if(i&&Object(a["c"])(i)){var r=n.x||0,o=n.y||0,s=e.getWidth(),l=e.getHeight(),u=i.width/i.height;if(null==s&&null!=l?s=l*u:null==l&&null!=s?l=s/u:null==s&&null==l&&(s=i.width,l=i.height),n.sWidth&&n.sHeight){var c=n.sx||0,h=n.sy||0;t.drawImage(i,c,h,n.sWidth,n.sHeight,r,o,s,l)}else if(n.sx&&n.sy){c=n.sx,h=n.sy;var d=s-c,f=l-h;t.drawImage(i,c,h,d,f,r,o,s,l)}else t.drawImage(i,r,o,s,l)}}function O(t,e,n){var i,r=n.text;if(null!=r&&(r+=""),r){t.font=n.font||f["a"],t.textAlign=n.textAlign,t.textBaseline=n.textBaseline;var a=void 0,o=void 0;t.setLineDash&&n.lineDash&&(i=Object(h["a"])(e),a=i[0],o=i[1]),a&&(t.setLineDash(a),t.lineDashOffset=o),n.strokeFirst?(g(n)&&t.strokeText(r,n.x,n.y),v(n)&&t.fillText(r,n.x,n.y)):(v(n)&&t.fillText(r,n.x,n.y),g(n)&&t.strokeText(r,n.x,n.y)),a&&t.setLineDash([])}}var S=["shadowBlur","shadowOffsetX","shadowOffsetY"],T=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function M(t,e,n,r,a){var o=!1;if(!r&&(n=n||{},e===n))return!1;if(r||e.opacity!==n.opacity){k(t,a),o=!0;var s=Math.max(Math.min(e.opacity,1),0);t.globalAlpha=isNaN(s)?i["b"].opacity:s}(r||e.blend!==n.blend)&&(o||(k(t,a),o=!0),t.globalCompositeOperation=e.blend||i["b"].blend);for(var l=0;l0&&l>0&&!u&&(s=0),s<0&&l<0&&!c&&(l=0));var d=this._determinedMin,f=this._determinedMax;return null!=d&&(s=d,u=!0),null!=f&&(l=f,c=!0),{min:s,max:l,minFixed:u,maxFixed:c,isBlank:h}},t.prototype.modifyDataMinMax=function(t,e){this[s[t]]=e},t.prototype.setDeterminedMinMax=function(t,e){var n=o[t];this[n]=e},t.prototype.freeze=function(){this.frozen=!0},t}(),o={min:"_determinedMin",max:"_determinedMax"},s={min:"_dataMin",max:"_dataMax"};function l(t,e,n){var i=t.rawExtentInfo;return i||(i=new a(t,e,n),t.rawExtentInfo=i,i)}function u(t,e){return null==e?null:Object(i["l"])(e)?NaN:t.parse(e)}},"551f":function(t,e,n){"use strict";n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return o}));var i=n("282b"),r=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],a=Object(i["a"])(r),o=function(){function t(){}return t.prototype.getItemStyle=function(t,e){return a(this,t,e)},t}()},5749:function(t,e,n){t.exports=n.p+"static/img/tjc.2254aa5c.png"},"58c9":function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"a",(function(){return a}));var i={};function r(t,e){i[t]=e}function a(t){return i[t]}},"5cfa":function(t,e,n){"use strict";n("ca7c")},"5e76":function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"a",(function(){return s})),n.d(e,"c",(function(){return u}));var i=n("d51b"),r=n("726e"),a=new i["a"](50);function o(t){if("string"===typeof t){var e=a.get(t);return e&&e.image}return t}function s(t,e,n,i,o){if(t){if("string"===typeof t){if(e&&e.__zrImageSrc===t||!n)return e;var s=a.get(t),c={hostEl:n,cb:i,cbPayload:o};return s?(e=s.image,!u(e)&&s.pending.push(c)):(e=r["d"].loadImage(t,l,l),e.__zrImageSrc=t,a.put(t,e.__cachedImgObj={image:e,pending:[c]})),e}return t}return e}function l(){var t=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e=0;if(r){var o="touchend"!==i?e.targetTouches[0]:e.changedTouches[0];o&&l(t,o,e,n)}else{l(t,e,e,n);var s=d(e);e.zrDelta=s?s/120:-(e.detail||0)/3}var u=e.button;return null==e.which&&void 0!==u&&a.test(e.type)&&(e.which=1&u?1:2&u?3:4&u?2:0),e}function d(t){var e=t.wheelDelta;if(e)return e;var n=t.deltaX,i=t.deltaY;if(null==n||null==i)return e;var r=0!==i?Math.abs(i):Math.abs(n),a=i>0?-1:i<0?1:n>0?-1:1;return 3*r*a}function f(t,e,n,i){t.addEventListener(e,n,i)}function p(t,e,n,i){t.removeEventListener(e,n,i)}var g=function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0};function m(t){return 2===t.which||3===t.which}},"60d9":function(t,e,n){},"615e":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAAoCAYAAAALz1FrAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAABWZJREFUeNqsV3tQlFUUP7uwwPJQdkNcyBesDBZKqMhgVH8kzRg44ujYaJk5MoO9zGpqpBmZ/KOih9QfZROMj1ILLOnxB40y6TiBvGQMUCJwcVN57rJLwLIQC2znXL77zfftg10azsxv7vv87j3nfOfeT+F0OsFVFAoFK/dXQDAWmxA5iEcRSxELEUOI+4gaxC+Iy6ey4V9hjUw+/zQNFJ5Icn9VqLA4iDiMiAbfYkZ8iPgCMeFKovRAkIBFPaLITwKSRcL8OkTiySwnELgEuhBswOIiQsv7FgbrYL1uBzwSvQViwh8CdeACGJkYgB7bn9BiqoCG3jIYnxzh09eSCVHPZiS5LpqfmwsH9FjUCruCQGUw5CS8C0/FvQEqZYjXI4w6rPBT+xG4eu8rcIJTaj7yoUE0FxLQib7nBOFBD8Dh9KuQpX9nVgKSMJUW9qz+EvJSvsONBUnNd55bivvkJcQ6foJDqRUQH5kuKvpnzAzGwdZZydJid8G+NSekXaTvVWYuDDmi/xsRQx07V30Mm+Pflin4rfMcNPb9DPkZF9D+dugdMcrGNSHREKlmRoCTzS9ATfcZPtSLWEHHeZoTaNXLIHPFIXHxjZ7LYB3rhTZLFdgcJkamVcfA8aZMGcnuxLOQqd/D6jsSC1kwTE6zSCa9WWSubD758SW5UrtC13A7I+i3tyFJD6vHRuiBhyghJSpPRhgZEgsp0VulXVl0kg28lRydJVuwddXLormI4GBaMWtL/TPqsLj5Zw3qaey7ILqLSJbzVmx4kjwlNByApoESyXdUwkxT2v68bF6qbpus/WDEamlzGZFoqBYcEA5BAWrZ5C0Jr6GP9qNf+uBU6zY4svEWc3JpO7B6nCaJ+U2j1snWRaiiZHFBPrFRzTE9Bk7ntNvRjzWmg2Wsm9U7rX/AncEW2Xi8JhnGHTZZ38S0Xdq0E4mJatPOKVR2VzaZL16yIJGV5BcKBpKeYQPzzY9/FUFx83PybGm/I2uSuZpoQ9TqGKyCqNA4cbR75DYrz7QeYCV3/N3hZma+GdPoYW9SsYykw1olbd6ik1zjrbrub2WT6QPMiT8OutCUmZOY6kUyHsJHH6tlPqGsMGORSWjoKZOquUIn+QHxEWWU1oFK6BysBb1mI1t0e6gc9iUfgyeW74SLhvXMP97krdQ69tVXd50G6/h93j1J+lkWxgRZio1dPIwLMhow0kKZzSmCRB95SClcaJ517B4crV7LMrMgZZiFd3OSldhxExEy81Fmwyvrylmy9FeGJ0xQVJ8JXSM3xT0hHkYSI8vCaFsDFq/zUbqMPqnfBCa7wS8CMnFhTYaUAAR9RmmqJyIKkW942zB4DQp+T4LzbW9C/2iHm2K6oIxD16Gk6VkorM1w3dBpQZ/79YuSJ7xInmRew0xaafyMQRuyFBaHJUCoSoPXr5ldvza8hj3IFcSL0g4ZCbJPoH+2Y7WSEpt0jCJGEjXepAGxnfTInlhenkSLhDfVSvBfDMK9bvb5JBJOZBYuM7OfBLPOV3pbJUQcmc7hg8AhzPMaisrZViNRNRbv+SCh8erZJij9MMUHlOS8jFF/oS8F/pBQ/sn3Mpbvhzn9IiGht3qLS1+L0A/zRUJS4qM9LyTldF2IWWWmPe8kfUKm5g7v+98k9JclhYs0CmXzHDbnliDdxvE3LVS4Z1TPfA2mcEw4dgsMlO1lidQh/FnZ8U09PlcSOuFieifI3jYW6CcSmxnoWaMWwAQ3Q2QmJLP76xOtKwHL4e9DZfcNyMXykoc19IjWzeUk9HcbRg9L2UmsMHWpwGsKocizeBpwS/UuziZziD5BBAinp0VTAsYF2HiIu+r8T4ABAP8HFTMQDaZoAAAAAElFTkSuQmCC"},"620a":function(t,e,n){"use strict";(function(t){var i,r=n("3db9"),a={supportWebGL:function(){if(null==i)try{var t=document.createElement("canvas"),e=t.getContext("webgl")||t.getContext("experimental-webgl");if(!e)throw new Error}catch(n){i=!1}return i}};a.Int8Array="undefined"===typeof Int8Array?Array:Int8Array,a.Uint8Array="undefined"===typeof Uint8Array?Array:Uint8Array,a.Uint16Array="undefined"===typeof Uint16Array?Array:Uint16Array,a.Uint32Array="undefined"===typeof Uint32Array?Array:Uint32Array,a.Int16Array="undefined"===typeof Int16Array?Array:Int16Array,a.Float32Array="undefined"===typeof Float32Array?Array:Float32Array,a.Float64Array="undefined"===typeof Float64Array?Array:Float64Array;var o={};"undefined"!==typeof window?o=window:"undefined"!==typeof t&&(o=t),a.requestAnimationFrame=o.requestAnimationFrame||o.msRequestAnimationFrame||o.mozRequestAnimationFrame||o.webkitRequestAnimationFrame||function(t){setTimeout(t,16)},a.createCanvas=function(){return document.createElement("canvas")},a.createImage=function(){return new o.Image},a.request={get:r["a"].get},a.addEventListener=function(t,e,n,i){t.addEventListener(e,n,i)},a.removeEventListener=function(t,e,n){t.removeEventListener(e,n)},e["a"]=a}).call(this,n("c8ba"))},"625e":function(t,e,n){"use strict";n.d(e,"f",(function(){return l})),n.d(e,"d",(function(){return c})),n.d(e,"b",(function(){return h})),n.d(e,"e",(function(){return f})),n.d(e,"a",(function(){return g})),n.d(e,"c",(function(){return y}));var i=n("7fae"),r=n("6d8b"),a=".",o="___EC__COMPONENT__CONTAINER___",s="___EC__EXTENDED_CLASS___";function l(t){var e={main:"",sub:""};if(t){var n=t.split(a);e.main=n[0]||"",e.sub=n[1]||""}return e}function u(t){r["b"](/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(t),'componentType "'+t+'" illegal')}function c(t){return!(!t||!t[s])}function h(t,e){t.$constructor=t,t.extend=function(t){var e,n=this;return d(n)?e=function(t){function e(){return t.apply(this,arguments)||this}return Object(i["a"])(e,t),e}(n):(e=function(){(t.$constructor||n).apply(this,arguments)},r["s"](e,this)),r["m"](e.prototype,t),e[s]=!0,e.extend=this.extend,e.superCall=m,e.superApply=v,e.superClass=n,e}}function d(t){return r["w"](t)&&/^class\s/.test(Function.prototype.toString.call(t))}function f(t,e){t.extend=e.extend}var p=Math.round(10*Math.random());function g(t){var e=["__\0is_clz",p++].join("_");t.prototype[e]=!0,t.isInstance=function(t){return!(!t||!t[e])}}function m(t,e){for(var n=[],i=2;i>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[l]+":0",r[u]+":0",i[1-l]+":auto",r[1-u]+":auto",""].join("!important;"),t.appendChild(o),n.push(o)}return n}function d(t,e,n){for(var i=n?"invTrans":"trans",r=e[i],a=e.srcCoords,s=[],l=[],u=!0,c=0;c<4;c++){var h=t[c].getBoundingClientRect(),d=2*c,f=h.left,p=h.top;s.push(f,p),u=u&&a&&f===a[d]&&p===a[d+1],l.push(t[c].offsetLeft,t[c].offsetTop)}return u&&r?r:(e.srcCoords=s,e[i]=n?o(l,s):o(s,l))}function f(t){return"CANVAS"===t.nodeName.toUpperCase()}},"68ab":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("4a3f");function r(t,e,n,r,a,o,s,l,u){if(0===s)return!1;var c=s;if(u>e+c&&u>r+c&&u>o+c||ut+c&&l>n+c&&l>a+c||l0)i*=10;var a=[h["v"](v(e[0]/i)*i),h["v"](m(e[1]/i)*i)];this._interval=i,this._niceExtent=a}},e.prototype.calcNiceExtent=function(t){p.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return t=_(t)/_(this.base),d["a"](t,this._extent)},e.prototype.normalize=function(t){return t=_(t)/_(this.base),d["f"](t,this._extent)},e.prototype.scale=function(t){return t=d["g"](t,this._extent),y(this.base,t)},e.type="log",e}(o["a"]),x=b.prototype;function w(t,e){return g(t,h["g"](e))}x.getMinorTicks=p.getMinorTicks,x.getLabel=p.getLabel,o["a"].registerClass(b);var O=b,S=n("ee1a"),T=n("538f");function M(t,e){var n=t.type,r=Object(T["a"])(t,e,t.getExtent()).calculate();t.setBlank(r.isBlank);var a=r.min,o=r.max,l=e.ecModel;if(l&&"time"===n){var u=Object(s["e"])("bar",l),c=!1;if(i["k"](u,(function(t){c=c||t.getBaseAxis()===e.axis})),c){var h=Object(s["d"])(u),d=A(a,o,e,h);a=d.min,o=d.max}}return{extent:[a,o],fixMin:r.minFixed,fixMax:r.maxFixed}}function A(t,e,n,r){var a=n.axis.getExtent(),o=a[1]-a[0],l=Object(s["f"])(r,n.axis);if(void 0===l)return{min:t,max:e};var u=1/0;i["k"](l,(function(t){u=Math.min(t.offset,u)}));var c=-1/0;i["k"](l,(function(t){c=Math.max(t.offset+t.width,c)})),u=Math.abs(u),c=Math.abs(c);var h=u+c,d=e-t,f=1-(u+c)/o,p=d/f-d;return e+=p*(c/h),t-=p*(u/h),{min:t,max:e}}function C(t,e){var n=e,i=M(t,n),r=i.extent,a=n.get("splitNumber");t instanceof O&&(t.base=n.get("logBase"));var o=t.type,s=n.get("interval"),l="interval"===o||"time"===o;t.setExtent(r[0],r[1]),t.calcNiceExtent({splitNumber:a,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:l?n.get("minInterval"):null,maxInterval:l?n.get("maxInterval"):null}),null!=s&&t.setInterval&&t.setInterval(s)}function I(t,e){if(e=e||t.get("type"),e)switch(e){case"category":return new r["a"]({ordinalMeta:t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),extent:[1/0,-1/0]});case"time":return new u["a"]({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC")});default:return new(o["a"].getClass(e)||a["a"])}}function D(t){var e=t.scale.getExtent(),n=e[0],i=e[1];return!(n>0&&i>0||n<0&&i<0)}function L(t){var e=t.getLabelModel().get("formatter"),n="category"===t.type?t.scale.getExtent()[0]:null;return"time"===t.scale.type?function(e){return function(n,i){return t.scale.getFormattedLabel(n,i,e)}}(e):i["C"](e)?function(e){return function(n){var i=t.scale.getLabel(n),r=e.replace("{value}",null!=i?i:"");return r}}(e):i["w"](e)?function(e){return function(i,r){return null!=n&&(r=i.value-n),e(E(t,i),r,null!=i.level?{level:i.level}:null)}}(e):function(e){return t.scale.getLabel(e)}}function E(t,e){return"category"===t.type?t.scale.getLabel(e):e.value}function j(t){var e=t.model,n=t.scale;if(e.get(["axisLabel","show"])&&!n.isBlank()){var i,a,o=n.getExtent();n instanceof r["a"]?a=n.count():(i=n.getTicks(),a=i.length);var s,l=t.getLabelModel(),u=L(t),c=1;a>40&&(c=Math.ceil(a/40));for(var h=0;ht[1]&&(t[1]=i[1])}))}},"697e7":function(t,e,n){"use strict";n.r(e),n.d(e,"init",(function(){return dt})),n.d(e,"dispose",(function(){return ft})),n.d(e,"disposeAll",(function(){return pt})),n.d(e,"getInstance",(function(){return gt})),n.d(e,"registerPainter",(function(){return mt})),n.d(e,"version",(function(){return vt}));var i=n("22d1"),r=n("6d8b"),a=n("21a10"),o=n("401b"),s=function(){function t(t,e){this.target=t,this.topTarget=e&&e.topTarget}return t}(),l=function(){function t(t){this.handler=t,t.on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}return t.prototype._dragStart=function(t){var e=t.target;while(e&&!e.draggable)e=e.parent||e.__hostTarget;e&&(this._draggingTarget=e,e.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new s(e,t),"dragstart",t.event))},t.prototype._drag=function(t){var e=this._draggingTarget;if(e){var n=t.offsetX,i=t.offsetY,r=n-this._x,a=i-this._y;this._x=n,this._y=i,e.drift(r,a,t),this.handler.dispatchToElement(new s(e,t),"drag",t.event);var o=this.handler.findHover(n,i,e).target,l=this._dropTarget;this._dropTarget=o,e!==o&&(l&&o!==l&&this.handler.dispatchToElement(new s(l,t),"dragleave",t.event),o&&o!==l&&this.handler.dispatchToElement(new s(o,t),"dragenter",t.event))}},t.prototype._dragEnd=function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.handler.dispatchToElement(new s(e,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new s(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},t}(),u=l,c=n("6fd3"),h=n("607d"),d=function(){function t(){this._track=[]}return t.prototype.recognize=function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},t.prototype.clear=function(){return this._track.length=0,this},t.prototype._doTrack=function(t,e,n){var i=t.touches;if(i){for(var r={points:[],touches:[],target:e,event:t},a=0,o=i.length;a1&&i&&i.length>1){var a=f(i)/f(r);!isFinite(a)&&(a=1),e.pinchScale=a;var o=p(i);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:t[0].target,event:e}}}}},m="silent";function v(t,e,n){return{type:t,event:n,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:y}}function y(){h["g"](this.event)}var _=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.handler=null,e}return Object(a["a"])(e,t),e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e}(c["a"]),b=function(){function t(t,e){this.x=t,this.y=e}return t}(),x=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],w=function(t){function e(e,n,i,r){var a=t.call(this)||this;return a._hovered=new b(0,0),a.storage=e,a.painter=n,a.painterRoot=r,i=i||new _,a.proxy=null,a.setHandlerProxy(i),a._draggingMgr=new u(a),a}return Object(a["a"])(e,t),e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(r["k"](x,(function(e){t.on&&t.on(e,this[e],this)}),this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var e=t.zrX,n=t.zrY,i=S(this,e,n),r=this._hovered,a=r.target;a&&!a.__zr&&(r=this.findHover(r.x,r.y),a=r.target);var o=this._hovered=i?new b(e,n):this.findHover(e,n),s=o.target,l=this.proxy;l.setCursor&&l.setCursor(s?s.cursor:"default"),a&&s!==a&&this.dispatchToElement(r,"mouseout",t),this.dispatchToElement(o,"mousemove",t),s&&s!==a&&this.dispatchToElement(o,"mouseover",t)},e.prototype.mouseout=function(t){var e=t.zrEventControl;"only_globalout"!==e&&this.dispatchToElement(this._hovered,"mouseout",t),"no_globalout"!==e&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new b(0,0)},e.prototype.dispatch=function(t,e){var n=this[t];n&&n.call(this,e)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},e.prototype.dispatchToElement=function(t,e,n){t=t||{};var i=t.target;if(!i||!i.silent){var r="on"+e,a=v(e,t,n);while(i)if(i[r]&&(a.cancelBubble=!!i[r].call(i,a)),i.trigger(e,a),i=i.__hostTarget?i.__hostTarget:i.parent,a.cancelBubble)break;a.cancelBubble||(this.trigger(e,a),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer((function(t){"function"===typeof t[r]&&t[r].call(t,a),t.trigger&&t.trigger(e,a)})))}},e.prototype.findHover=function(t,e,n){for(var i=this.storage.getDisplayList(),r=new b(t,e),a=i.length-1;a>=0;a--){var o=void 0;if(i[a]!==n&&!i[a].ignore&&(o=O(i[a],t,e))&&(!r.topTarget&&(r.topTarget=i[a]),o!==m)){r.target=i[a];break}}return r},e.prototype.processGesture=function(t,e){this._gestureMgr||(this._gestureMgr=new d);var n=this._gestureMgr;"start"===e&&n.clear();var i=n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===e&&n.clear(),i){var r=i.type;t.gestureEvent=r;var a=new b;a.target=i.target,this.dispatchToElement(a,r,i.event)}},e}(c["a"]);function O(t,e,n){if(t[t.rectHover?"rectContain":"contain"](e,n)){var i=t,r=void 0,a=!1;while(i){if(i.ignoreClip&&(a=!0),!a){var o=i.getClipPath();if(o&&!o.contain(e,n))return!1;i.silent&&(r=!0)}var s=i.__hostTarget;i=s||i.parent}return!r||m}return!1}function S(t,e,n){var i=t.painter;return e<0||e>i.getWidth()||n<0||n>i.getHeight()}r["k"](["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],(function(t){w.prototype[t]=function(e){var n,i,r=e.zrX,a=e.zrY,s=S(this,r,a);if("mouseup"===t&&s||(n=this.findHover(r,a),i=n.target),"mousedown"===t)this._downEl=i,this._downPoint=[e.zrX,e.zrY],this._upEl=i;else if("mouseup"===t)this._upEl=i;else if("click"===t){if(this._downEl!==this._upEl||!this._downPoint||o["f"](this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(n,t,e)}}));var T=w,M=n("04f6"),A=n("4bc4"),C=!1;function I(){C||(C=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function D(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}var L=function(){function t(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=D}return t.prototype.traverse=function(t,e){for(var n=0;n0&&(u.__clipPaths=[]),isNaN(u.z)&&(I(),u.z=0),isNaN(u.z2)&&(I(),u.z2=0),isNaN(u.zlevel)&&(I(),u.zlevel=0),this._displayList[this._displayListLen++]=u}var c=t.getDecalElement&&t.getDecalElement();c&&this._updateAndAddDisplayable(c,e,n);var h=t.getTextGuideLine();h&&this._updateAndAddDisplayable(h,e,n);var d=t.getTextContent();d&&this._updateAndAddDisplayable(d,e,n)}},t.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},t.prototype.delRoot=function(t){if(t instanceof Array)for(var e=0,n=t.length;e=0&&this._roots.splice(i,1)}},t.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},t.prototype.getRoots=function(){return this._roots},t.prototype.dispose=function(){this._displayList=null,this._roots=null},t}(),E=L,j=n("98b7"),P=n("06ad");function N(){return(new Date).getTime()}var R=function(t){function e(e){var n=t.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,e=e||{},n.stage=e.stage||{},n}return Object(a["a"])(e,t),e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var e=t.getClip();e&&this.addClip(e)},e.prototype.removeClip=function(t){if(t.animation){var e=t.prev,n=t.next;e?e.next=n:this._head=n,n?n.prev=e:this._tail=e,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var e=t.getClip();e&&this.removeClip(e),t.animation=null},e.prototype.update=function(t){var e=N()-this._pausedTime,n=e-this._time,i=this._head;while(i){var r=i.next,a=i.step(e,n);a?(i.ondestroy(),this.removeClip(i),i=r):i=r}this._time=e,t||(this.trigger("frame",n),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;function e(){t._running&&(Object(j["a"])(e),!t._paused&&t.update())}this._running=!0,Object(j["a"])(e)},e.prototype.start=function(){this._running||(this._time=N(),this._pausedTime=0,this._startLoop())},e.prototype.stop=function(){this._running=!1},e.prototype.pause=function(){this._paused||(this._pauseStart=N(),this._paused=!0)},e.prototype.resume=function(){this._paused&&(this._pausedTime+=N()-this._pauseStart,this._paused=!1)},e.prototype.clear=function(){var t=this._head;while(t){var e=t.next;t.prev=t.next=t.animation=null,t=e}this._head=this._tail=null},e.prototype.isFinished=function(){return null==this._head},e.prototype.animate=function(t,e){e=e||{},this.start();var n=new P["b"](t,e.loop);return this.addAnimator(n),n},e}(c["a"]),k=R,B=300,z=i["a"].domSupported,V=function(){var t=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],e=["touchstart","touchend","touchmove"],n={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},i=r["H"](t,(function(t){var e=t.replace("mouse","pointer");return n.hasOwnProperty(e)?e:t}));return{mouse:t,touch:e,pointer:i}}(),F={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},G=!1;function H(t){var e=t.pointerType;return"pen"===e||"touch"===e}function U(t){t.touching=!0,null!=t.touchTimer&&(clearTimeout(t.touchTimer),t.touchTimer=null),t.touchTimer=setTimeout((function(){t.touching=!1,t.touchTimer=null}),700)}function W(t){t&&(t.zrByTouch=!0)}function X(t,e){return Object(h["e"])(t.dom,new q(t,e),!0)}function Z(t,e){var n=e,i=!1;while(n&&9!==n.nodeType&&!(i=n.domBelongToZr||n!==e&&n===t.painterRoot))n=n.parentNode;return i}var q=function(){function t(t,e){this.stopPropagation=r["L"],this.stopImmediatePropagation=r["L"],this.preventDefault=r["L"],this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY}return t}(),Y={mousedown:function(t){t=Object(h["e"])(this.dom,t),this.__mayPointerCapture=[t.zrX,t.zrY],this.trigger("mousedown",t)},mousemove:function(t){t=Object(h["e"])(this.dom,t);var e=this.__mayPointerCapture;!e||t.zrX===e[0]&&t.zrY===e[1]||this.__togglePointerCapture(!0),this.trigger("mousemove",t)},mouseup:function(t){t=Object(h["e"])(this.dom,t),this.__togglePointerCapture(!1),this.trigger("mouseup",t)},mouseout:function(t){t=Object(h["e"])(this.dom,t);var e=t.toElement||t.relatedTarget;Z(this,e)||(this.__pointerCapturing&&(t.zrEventControl="no_globalout"),this.trigger("mouseout",t))},wheel:function(t){G=!0,t=Object(h["e"])(this.dom,t),this.trigger("mousewheel",t)},mousewheel:function(t){G||(t=Object(h["e"])(this.dom,t),this.trigger("mousewheel",t))},touchstart:function(t){t=Object(h["e"])(this.dom,t),W(t),this.__lastTouchMoment=new Date,this.handler.processGesture(t,"start"),Y.mousemove.call(this,t),Y.mousedown.call(this,t)},touchmove:function(t){t=Object(h["e"])(this.dom,t),W(t),this.handler.processGesture(t,"change"),Y.mousemove.call(this,t)},touchend:function(t){t=Object(h["e"])(this.dom,t),W(t),this.handler.processGesture(t,"end"),Y.mouseup.call(this,t),+new Date-+this.__lastTouchMoment0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},t.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},t.prototype.wakeUp=function(){this.animation.start(),this._stillFrameAccum=0},t.prototype.refreshHover=function(){this._needsRefreshHover=!0},t.prototype.refreshHoverImmediately=function(){this._needsRefreshHover=!1,this.painter.refreshHover&&"canvas"===this.painter.getType()&&this.painter.refreshHover()},t.prototype.resize=function(t){t=t||{},this.painter.resize(t.width,t.height),this.handler.resize()},t.prototype.clearAnimation=function(){this.animation.clear()},t.prototype.getWidth=function(){return this.painter.getWidth()},t.prototype.getHeight=function(){return this.painter.getHeight()},t.prototype.setCursorStyle=function(t){this.handler.setCursorStyle(t)},t.prototype.findHover=function(t,e){return this.handler.findHover(t,e)},t.prototype.on=function(t,e,n){return this.handler.on(t,e,n),this},t.prototype.off=function(t,e){this.handler.off(t,e)},t.prototype.trigger=function(t,e){this.handler.trigger(t,e)},t.prototype.clear=function(){for(var t=this.storage.getRoots(),e=0;e=0;l--)o=r["I"](o,n[l],!0);e.defaultOption=o}return e.defaultOption},e.prototype.getReferringComponents=function(t,e){var n=t+"Index",i=t+"Id";return Object(l["v"])(this.ecModel,t,{index:this.get(n,!0),id:this.get(i,!0)},e)},e.prototype.getBoxLayoutParams=function(){var t=this;return{left:t.get("left"),top:t.get("top"),right:t.get("right"),bottom:t.get("bottom"),width:t.get("width"),height:t.get("height")}},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0}(),e}(a["a"]);function d(t){var e=[];return r["k"](h.getClassesByMainType(t),(function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])})),e=r["H"](e,(function(t){return Object(s["f"])(t).main})),"dataset"!==t&&r["r"](e,"dataset")<=0&&e.unshift("dataset"),e}Object(s["e"])(h,a["a"]),Object(s["c"])(h),o["a"](h),o["b"](h,d),e["a"]=h},"6d8b":function(t,e,n){"use strict";n.d(e,"p",(function(){return m})),n.d(e,"G",(function(){return v})),n.d(e,"d",(function(){return y})),n.d(e,"I",(function(){return _})),n.d(e,"J",(function(){return b})),n.d(e,"m",(function(){return x})),n.d(e,"i",(function(){return w})),n.d(e,"r",(function(){return O})),n.d(e,"s",(function(){return S})),n.d(e,"K",(function(){return T})),n.d(e,"u",(function(){return M})),n.d(e,"k",(function(){return A})),n.d(e,"H",(function(){return C})),n.d(e,"N",(function(){return I})),n.d(e,"n",(function(){return D})),n.d(e,"o",(function(){return L})),n.d(e,"F",(function(){return E})),n.d(e,"c",(function(){return P})),n.d(e,"h",(function(){return N})),n.d(e,"t",(function(){return R})),n.d(e,"w",(function(){return k})),n.d(e,"C",(function(){return B})),n.d(e,"D",(function(){return z})),n.d(e,"z",(function(){return V})),n.d(e,"A",(function(){return F})),n.d(e,"E",(function(){return H})),n.d(e,"v",(function(){return U})),n.d(e,"x",(function(){return W})),n.d(e,"y",(function(){return X})),n.d(e,"B",(function(){return Z})),n.d(e,"l",(function(){return q})),n.d(e,"O",(function(){return Y})),n.d(e,"P",(function(){return K})),n.d(e,"Q",(function(){return Q})),n.d(e,"S",(function(){return J})),n.d(e,"M",(function(){return $})),n.d(e,"b",(function(){return tt})),n.d(e,"T",(function(){return et})),n.d(e,"R",(function(){return it})),n.d(e,"f",(function(){return ot})),n.d(e,"e",(function(){return st})),n.d(e,"g",(function(){return lt})),n.d(e,"j",(function(){return ut})),n.d(e,"q",(function(){return ct})),n.d(e,"L",(function(){return ht})),n.d(e,"a",(function(){return dt}));var i=n("726e"),r=I(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],(function(t,e){return t["[object "+e+"]"]=!0,t}),{}),a=I(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],(function(t,e){return t["[object "+e+"Array]"]=!0,t}),{}),o=Object.prototype.toString,s=Array.prototype,l=s.forEach,u=s.filter,c=s.slice,h=s.map,d=function(){}.constructor,f=d?d.prototype:null,p="__proto__",g=2311;function m(){return g++}function v(){for(var t=[],e=0;e=0)u=l*n.length;else for(var d=0;d=0&&t.call(e,n[r],r)},t.prototype.eachEdge=function(t,e){for(var n=this.edges,i=n.length,r=0;r=0&&n[r].node1.dataIndex>=0&&n[r].node2.dataIndex>=0&&t.call(e,n[r],r)},t.prototype.breadthFirstTraverse=function(t,e,n,i){if(e instanceof o||(e=this._nodesMap[r(e)]),e){for(var a="out"===n?"outEdges":"in"===n?"inEdges":"edges",s=0;s=0&&n.node2.dataIndex>=0}));for(r=0,a=i.length;r=0&&this[t][e].setItemVisual(this.dataIndex,n,i)},getVisual:function(n){return this[t][e].getItemVisual(this.dataIndex,n)},setLayout:function(n,i){this.dataIndex>=0&&this[t][e].setItemLayout(this.dataIndex,n,i)},getLayout:function(){return this[t][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[t][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[t][e].getRawIndex(this.dataIndex)}}}i["K"](o,l("hostGraph","data")),i["K"](s,l("hostGraph","edgeData")),e["a"]=a},"76a5":function(t,e,n){"use strict";n.d(e,"c",(function(){return b})),n.d(e,"b",(function(){return w}));var i=n("21a10"),r=n("d409"),a=n("dd4f"),o=n("6d8b"),s=n("e86a"),l=n("0da8"),u=n("c7a2"),c=n("9850"),h=n("19eb"),d=n("726e"),f={fill:"#000"},p=2,g={style:Object(o["i"])({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},h["a"].style)},m=function(t){function e(e){var n=t.call(this)||this;return n.type="text",n._children=[],n._defaultStyle=f,n.attr(e),n}return Object(i["a"])(e,t),e.prototype.childrenRef=function(){return this._children},e.prototype.update=function(){t.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var e=0;e0,B=null!=t.width&&("truncate"===t.overflow||"break"===t.overflow||"breakAll"===t.overflow),z=o.calculatedLineHeight,V=0;V=0&&(E=w[L],"right"===E.align))this._placeToken(E,t,S,v,D,"right",_),T-=E.width,D-=E.width,L--;A+=(i-(A-m)-(y-D)-T)/2;while(M<=L)E=w[M],this._placeToken(E,t,S,v,A+E.width/2,"center",_),A+=E.width,M++;v+=S}},e.prototype._placeToken=function(t,e,n,i,r,l,u){var h=e.rich[t.styleName]||{};h.text=t.text;var f=t.verticalAlign,g=i+n/2;"top"===f?g=i+t.height/2:"bottom"===f&&(g=i+n-t.height/2);var m=!t.isLineHolder&&I(h);m&&this._renderBackground(h,e,"right"===l?r-t.width:"center"===l?r-t.width/2:r,g-t.height/2,t.width,t.height);var v=!!h.backgroundColor,y=t.textPadding;y&&(r=A(r,l,y),g-=t.height/2-y[0]-t.innerHeight/2);var _=this._getOrCreateChild(a["a"]),b=_.createStyle();_.useStyle(b);var w=this._defaultStyle,O=!1,S=0,C=M("fill"in h?h.fill:"fill"in e?e.fill:(O=!0,w.fill)),D=T("stroke"in h?h.stroke:"stroke"in e?e.stroke:v||u||w.autoStroke&&!O?null:(S=p,w.stroke)),L=h.textShadowBlur>0||e.textShadowBlur>0;b.text=t.text,b.x=r,b.y=g,L&&(b.shadowBlur=h.textShadowBlur||e.textShadowBlur||0,b.shadowColor=h.textShadowColor||e.textShadowColor||"transparent",b.shadowOffsetX=h.textShadowOffsetX||e.textShadowOffsetX||0,b.shadowOffsetY=h.textShadowOffsetY||e.textShadowOffsetY||0),b.textAlign=l,b.textBaseline="middle",b.font=t.font||d["a"],b.opacity=Object(o["Q"])(h.opacity,e.opacity,1),x(b,h),D&&(b.lineWidth=Object(o["Q"])(h.lineWidth,e.lineWidth,S),b.lineDash=Object(o["P"])(h.lineDash,e.lineDash),b.lineDashOffset=e.lineDashOffset||0,b.stroke=D),C&&(b.fill=C);var E=t.contentWidth,j=t.contentHeight;_.setBoundingRect(new c["a"](Object(s["a"])(b.x,E,b.textAlign),Object(s["b"])(b.y,j,b.textBaseline),E,j))},e.prototype._renderBackground=function(t,e,n,i,r,a){var s,c,h=t.backgroundColor,d=t.borderWidth,f=t.borderColor,p=h&&h.image,g=h&&!p,m=t.borderRadius,v=this;if(g||t.lineHeight||d&&f){s=this._getOrCreateChild(u["a"]),s.useStyle(s.createStyle()),s.style.fill=null;var y=s.shape;y.x=n,y.y=i,y.width=r,y.height=a,y.r=m,s.dirtyShape()}if(g){var _=s.style;_.fill=h||null,_.fillOpacity=Object(o["P"])(t.fillOpacity,1)}else if(p){c=this._getOrCreateChild(l["a"]),c.onload=function(){v.dirtyStyle()};var b=c.style;b.image=h.image,b.x=n,b.y=i,b.width=r,b.height=a}if(d&&f){_=s.style;_.lineWidth=d,_.stroke=f,_.strokeOpacity=Object(o["P"])(t.strokeOpacity,1),_.lineDash=t.borderDash,_.lineDashOffset=t.borderDashOffset||0,s.strokeContainThreshold=0,s.hasFill()&&s.hasStroke()&&(_.strokeFirst=!0,_.lineWidth*=2)}var x=(s||c).style;x.shadowBlur=t.shadowBlur||0,x.shadowColor=t.shadowColor||"transparent",x.shadowOffsetX=t.shadowOffsetX||0,x.shadowOffsetY=t.shadowOffsetY||0,x.opacity=Object(o["Q"])(t.opacity,e.opacity,1)},e.makeFont=function(t){var e="";return w(t)&&(e=[t.fontStyle,t.fontWeight,b(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),e&&Object(o["T"])(e)||t.textFont||t.font},e}(h["c"]),v={left:!0,right:1,center:1},y={top:1,bottom:1,middle:1},_=["fontStyle","fontWeight","fontSize","fontFamily"];function b(t){return"string"!==typeof t||-1===t.indexOf("px")&&-1===t.indexOf("rem")&&-1===t.indexOf("em")?isNaN(+t)?d["c"]+"px":t+"px":t}function x(t,e){for(var n=0;n<_.length;n++){var i=_[n],r=e[i];null!=r&&(t[i]=r)}}function w(t){return null!=t.fontSize||t.fontFamily||t.fontWeight}function O(t){return S(t),Object(o["k"])(t.rich,S),t}function S(t){if(t){t.font=m.makeFont(t);var e=t.align;"middle"===e&&(e="center"),t.align=null==e||v[e]?e:"left";var n=t.verticalAlign;"center"===n&&(n="middle"),t.verticalAlign=null==n||y[n]?n:"top";var i=t.padding;i&&(t.padding=Object(o["M"])(t.padding))}}function T(t,e){return null==t||e<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function M(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function A(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function C(t){var e=t.text;return null!=e&&(e+=""),e}function I(t){return!!(t.backgroundColor||t.lineHeight||t.borderWidth&&t.borderColor)}e["a"]=m},7729:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAArCAYAAACNWyPFAAALpklEQVRYhY1Xe2xb133+zrnvyzdFihRJvW1LjhZLrt04Vlo3buykyZIWa4JgAdZuKTagbYZiQ7OhK7YCG4b90bXAhgHrHxm2YBv6SNJ16Owka5omnhPHcSpbkhXJtqyXKZmkRPEhkpf3fYZ75ZpGCmw+xAUvecnz/Z7f7zvk+a9/A97ieR7l7RrK25tIJbuQySRx/oM5EgoF41rLOFbYbD20sVEdazbMPhBOYnCNcFC+kctGP0yl1LOmRc52ReWbbU3DwOAgolEFrWYbhBDw+MhiDBAlAYZhhnTDeubih4tfqTQw4TgSeBJCOh1ENhNEcVNDqaQPNVbw4Pxy7blknK6M30O/5zjOvyqyWKKUeLsBIOAmJz/ho1BK0dLaYMyGIosTb/7P3L+fv5R/rmXyacaJ4AiH3kwchw/FsGeEIRTgYZoUO3UDoiSi2nRjH14pnDQs49FsOrocCavXHduF66ID4rkFwtBoNj/7+lvTLy0tbt7DqUFwvOcsBVyK+w7lEAgw1KtNGLoBRQEKN13fXl5goJKAcsXonp67+tuqRNxsJnlekgSXO/7gp8FzHAKqgmp158lTr577wVZJiwjxsIcM5gGAgiM8knEOXUkBcAh4aqG83cLWNg9KvcAwMNcCJzLYLqVXF1Y+HY0qxHWds/zSSt73JBhUcx+8P/cnlfKOLHen4DouGKNw/KfM/1ypmehzVDCiw3YZGg0FhmFDEAkYT+GCwPVyKnIwSQivvTX155Q4/8xrLW03XMwVLMcVPasNiwGmBWZoXhxARBGyoKBeqeHylAaB5+G6LlpNEwHFhekw6G0Hrmn5IacKBWwbtmuBEBf82OiwD6Io8ook8n9R17R/3Cg2+nqyXdjTn0ZQliBLPCRxd2NCCURJgZ9UZgBwYJoMusnQbgPbtRYWltehBujOyU8+8LfhoLLB64bpg5iWg0QifLq3J3qQA3vu2NGRrw/05yKqokBVFQiiCOKHg/i58vPkpYu4sG0bWqsFx3awuVWBKjTfM232rZd/9OLP/R602W6f8ISgUmshGgtUjhzc++NCafML5395KcJ79W47IDyFQDi4zAXzPfKwKBgjcF0GmzmQg0HozSZ6M+Hzhs299asO5HMSu1XCNhJhBWPpIWwbprg6P8t/8aFjyBsMr7x5BoX8OjTL/GjvgqMEye4kjt9/BM88cAD/9KOXceFKbfuBjx9wboOE+FuugIEPCHAkHhcXl9qG6Wh9e/dB3Cxjf64HRw/ci0gkjOpOA5rehiop6O6K+fcr+XVkoyE8cd84Zi9dxEJjdttlHYN4h3WsahtWZE889J3j/dkT908+GEuM7MPkGLBn/xjOXprB8UOHMTG6H4Tn4MVrZXUVr777Do4cPoQnJ48AkgtelPHEwYk/Orx/6EkAJ32Qnkz6Nohp2+PRcOjzvSPjcfU3DqJy6T3osRB6D92HldfewFitilAkDNguEAiCX89jcW0N2fFx0O4sUN1AOKggkh0YeWjy2Miv9qWOIMK7XFEEryjLO0RYyox/DMMDfRBDcazX2/iz5/8UL//HT3Du4rTfbJZhAMzFZqWKV06dxvN//Dz+8/SrQCyCoVwWgwMD0Bi9bTy15ABsJQiNl5GvtgpiOpNP5XI+PSvURS4WRnlrE612G7FwyGtaeGQDx0E8GoYkSSgVCxCZC8+C3q4YIjAwNXf5p7dz0j80ClGUkM+v499++OpvvXbm0ueVaAoSZzvh4ipJDwzQz504jkhQxaNH7wezTNR36ugSeOzr7cPv/OZjmL5yFWO5HkBrYbPRXH97ev5FIRL9zm0QQRB9a3iehkvl5rNzMzP4+ZuX8ehnDpz63rMnRzgOo19+7AT+4LOPQ1GCcCwTsizAsWzwjOEvv/pl6FoDCZXCyq+gyvMvyKnkX0VCsU51lTZLiERCuPzhlcfnriw/hkAvoJvoTne/uFCsZqOU+/vIwCAHymNzq4RirYpIOAZdL4IwB/2ZbgS7w0C9iKml5enNtvv91OAg1Gi2AzIze5nnOBp9/fWzvwfDAVwTH58c/UU0pJx76a2pzdK9feojnPiH6UxPtisqct5ELG40IAgE2e4kpKAAo5BvXbi29tM5k/+mEoutBhWKYmmjAxKLxRI38jfvf3dq/iRCUcB00RVg0zMzV4M8J42dnl/p+q/zU2tH9/RHJsfGIgeGBxCIKt5UxfbNMk7/5H2cunBpcU13y5868cmuwdzAqus42N/TaUB+eWXtxOrazQdgaBDCCXCiifMXrz3FS9HPqUpkoD1f5sr1mv3jt4voT13F73/hCTjlDYTCUVSojO/+ww8cvW2NcjKZ2Gma4wPZ4aeTqZFSJvhOh3oqNffvVvOlzzRMXvKGjUewbUOItNp8vK451HYiEKUUJTREiUwRGroH/z1VwdUKBRdNYHpmkUJN8oyoyC9e6xeVSDOT7jszqv4LQv1f3PWkWqv1W6YbguFC572h480tAZA4eC+P4EEcMM6E3qyjmi/gwKEjMFo1rMzOAIYNKgGEI3DELpSr7W+UioU3SFo7dztcTz/1yFfq9Ub/u+9NP2W4dLShOamWoUuu7bWcBcZ7DK34asYyXcxMzSLeJ8PUt1HfWEA00QWXctC8iSVwkCRebmmNezWLdEAG+nI/q9druH7t+isbW1piYrQ7uG8oHZubv66EAqG+6QXjW7neVPrggZQ3UfH2mVmszPwMhFKk0t3YO5zDdrWGa0tVNCiHd395DcvLq5HH95Y7idd1A7puwrKcqmE5VVWR0NcTQ+mmAL1dkzhO/Gq+UElbtgnHIjAsAYP9CVRrOioN4IP5VVi2DmYbUCQelcIWxu85rMSTdoe7bt+R3ZniOC5abR3BcALReILIkuTUdjQsrmxhZWMTuuWirknQIcBwTNRbLTTbpjc84ekVSAI4tiO9ceXoHSBk98YboZ4e5nkOPC8gk01h38iQLqtCy/uReOsZxwHhkAxuV2xB4Ch4ju6OfY8kPeKMqM565Q5aYYzBu1qajtHhFEaH06jWd2USczgIlNXoLX8p2dVV9aYGx3VAKbery3xd4c1/5r/ruqERZnVAPAXiCYLeXAqyLOPacun2Q4GnMA2jwRHB38gzxtvPG0ymZfo61w848+UWXC8wAodoNFb0iLfDwqKAeDyGTxyd9DXVnUtRRBRK57iljSYkjgf11AkAXbduabDdMQxK0DZ0oNUAH0hgeGDohqoG76yu3T+Ypr0ruu9YnuXJZOgKZZsMLiWE48FTDqrKo9n2Eun4uss1W053TLYDybAUSSbXXFiFtq53QMrllh+KjwL4OdFMjN878t1qpbpv6vLq0xADcJmC9bU6CGdB4mU0tQYk0ph75FOHf/Hsl373a4Vi6YOF+bmlRovrVFdQpfCoOSCTX7u87127XXv4oY/9jRqg25plwPCsp94IFkCICtvhkUylloNB+a9bzcZ0MhGf27tnyAiqyp1UL/6aBx9dlHKz0Vg0X9X0LoeooMT1D0UOUeDxTkAV2EBfT2Xx+tK3u7oShUwmg+2d9Q6IrKr/PwghLNsdmV1db014pelFlhHvPGL75ClzpNKd7IbpkJcsy0C+UEG9oXVAri1u/J8AuHUK607GLgpc4RmvsncLmfi6GNRBT0+qSAQFjXoFvdkU8qUmNO2OxG9XancBAqiKOEcFarqO1zTwm4M5uwfPWDy4RTjO753lG9to6F7ShQ5If1/PXXliWtaCGlBrOw0h4Hee/0AGxyuGbVgFSeCxf3QEK6t5tNoGAqrcASlv3rw7TwLBakJulVrlrSzEhHdOha0XoYpaW5GGGxzlocoqejL7cGz0FJLKCoCv7YJoWutuPEkWNgovmDvrE6xZAuSwyYlS02oU46IsRm8sp14ob018KRyOvAEugHTgBrLK+x1Pctnc3YCEz545O1QsFKuZbM/Cww+f/LZlWdsXLlz45sLV60fOvvNOon+wvz8QUrGxxTCMJqQokPD+DOB/AUTdPMSkWxHSAAAAAElFTkSuQmCC"},7837:function(t,e,n){"use strict";n.d(e,"g",(function(){return h})),n.d(e,"e",(function(){return d})),n.d(e,"c",(function(){return f})),n.d(e,"b",(function(){return p})),n.d(e,"d",(function(){return x})),n.d(e,"f",(function(){return w})),n.d(e,"h",(function(){return O})),n.d(e,"a",(function(){return S}));var i=n("76a5"),r=n("6d8b"),a=n("7d6c"),o=n("e0d3"),s=n("deab"),l={};function u(t,e){for(var n=0;n-1){var n=Object(r["parse"])(t);n&&(t="rgb("+n[0]+","+n[1]+","+n[2]+")",e=n[3])}}else t="none";return{color:t,opacity:null==e?1:e}}var l=1e-4;function u(t){return t-l}function c(t){return o(1e3*t)/1e3}function h(t){return o(1e4*t)/1e4}function d(t){return"matrix("+c(t[0])+","+c(t[1])+","+c(t[2])+","+c(t[3])+","+h(t[4])+","+h(t[5])+")"}var f={left:"start",right:"end",center:"middle",middle:"middle"};function p(t,e,n){return"top"===n?t+=e/2:"bottom"===n&&(t-=e/2),t}function g(t){return t&&(t.shadowBlur||t.shadowOffsetX||t.shadowOffsetY)}function m(t){var e=t.style,n=t.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),n[0],n[1]].join(",")}function v(t){return t&&!!t.image}function y(t){return t&&!!t.svgElement}function _(t){return v(t)||y(t)}function b(t){return"linear"===t.type}function x(t){return"radial"===t.type}function w(t){return t&&("linear"===t.type||"radial"===t.type)}function O(t){return"url(#"+t+")"}function S(t){var e=t.getGlobalScale(),n=Math.max(e[0],e[1]);return Math.max(Math.ceil(Math.log(n)/Math.log(10)),1)}function T(t){var e=t.x||0,n=t.y||0,r=(t.rotation||0)*i["a"],a=Object(i["P"])(t.scaleX,1),s=Object(i["P"])(t.scaleY,1),l=t.skewX||0,u=t.skewY||0,c=[];return(e||n)&&c.push("translate("+e+"px,"+n+"px)"),r&&c.push("rotate("+r+")"),1===a&&1===s||c.push("scale("+a+","+s+")"),(l||u)&&c.push("skew("+o(l*i["a"])+"deg, "+o(u*i["a"])+"deg)"),c.join(" ")}var M=function(){return a["a"].hasGlobalWindow&&Object(i["w"])(window.btoa)?function(t){return window.btoa(unescape(t))}:"undefined"!==typeof t?function(e){return t.from(e).toString("base64")}:function(t){return null}}()}).call(this,n("b639").Buffer)},"7d6c":function(t,e,n){"use strict";n.d(e,"d",(function(){return p})),n.d(e,"e",(function(){return g})),n.d(e,"g",(function(){return m})),n.d(e,"a",(function(){return v})),n.d(e,"j",(function(){return y})),n.d(e,"c",(function(){return b})),n.d(e,"b",(function(){return x})),n.d(e,"f",(function(){return w})),n.d(e,"i",(function(){return O})),n.d(e,"h",(function(){return S})),n.d(e,"H",(function(){return k})),n.d(e,"G",(function(){return H})),n.d(e,"r",(function(){return X})),n.d(e,"C",(function(){return Z})),n.d(e,"q",(function(){return q})),n.d(e,"B",(function(){return Y})),n.d(e,"s",(function(){return K})),n.d(e,"D",(function(){return Q})),n.d(e,"k",(function(){return $})),n.d(e,"l",(function(){return et})),n.d(e,"m",(function(){return nt})),n.d(e,"t",(function(){return it})),n.d(e,"x",(function(){return rt})),n.d(e,"w",(function(){return at})),n.d(e,"K",(function(){return ot})),n.d(e,"L",(function(){return st})),n.d(e,"u",(function(){return lt})),n.d(e,"o",(function(){return ut})),n.d(e,"J",(function(){return ht})),n.d(e,"p",(function(){return dt})),n.d(e,"I",(function(){return gt})),n.d(e,"F",(function(){return mt})),n.d(e,"y",(function(){return vt})),n.d(e,"n",(function(){return yt})),n.d(e,"v",(function(){return _t})),n.d(e,"A",(function(){return bt})),n.d(e,"z",(function(){return xt})),n.d(e,"E",(function(){return wt}));var i=n("d51b"),r=n("6d8b"),a=n("861c"),o=n("41ef"),s=n("e0d3"),l=n("cbe5"),u=1,c={},h=Object(s["o"])(),d=Object(s["o"])(),f=0,p=1,g=2,m=["emphasis","blur","select"],v=["normal","emphasis","blur","select"],y=10,_=9,b="highlight",x="downplay",w="select",O="unselect",S="toggleSelect";function T(t){return null!=t&&"none"!==t}var M=new i["a"](100);function A(t){if(Object(r["C"])(t)){var e=M.get(t);return e||(e=o["lift"](t,-.1),M.put(t,e)),e}if(Object(r["x"])(t)){var n=Object(r["m"])({},t);return n.colorStops=Object(r["H"])(t.colorStops,(function(t){return{offset:t.offset,color:o["lift"](t.color,-.1)}})),n}return t}function C(t,e,n){t.onHoverStateChange&&(t.hoverState||0)!==n&&t.onHoverStateChange(e),t.hoverState=n}function I(t){C(t,"emphasis",g)}function D(t){t.hoverState===g&&C(t,"normal",f)}function L(t){C(t,"blur",p)}function E(t){t.hoverState===p&&C(t,"normal",f)}function j(t){t.selected=!0}function P(t){t.selected=!1}function N(t,e,n){e(t,n)}function R(t,e,n){N(t,e,n),t.isGroup&&t.traverse((function(t){N(t,e,n)}))}function k(t,e){switch(e){case"emphasis":t.hoverState=g;break;case"normal":t.hoverState=f;break;case"blur":t.hoverState=p;break;case"select":t.selected=!0}}function B(t,e,n,i){for(var r=t.style,a={},o=0;o=0,o=!1;if(t instanceof l["b"]){var s=h(t),u=a&&s.selectFill||s.normalFill,c=a&&s.selectStroke||s.normalStroke;if(T(u)||T(c)){i=i||{};var d=i.style||{};"inherit"===d.fill?(o=!0,i=Object(r["m"])({},i),d=Object(r["m"])({},d),d.fill=u):!T(d.fill)&&T(u)?(o=!0,i=Object(r["m"])({},i),d=Object(r["m"])({},d),d.fill=A(u)):!T(d.stroke)&&T(c)&&(o||(i=Object(r["m"])({},i),d=Object(r["m"])({},d)),d.stroke=A(c)),i.style=d}}if(i&&null==i.z2){o||(i=Object(r["m"])({},i));var f=t.z2EmphasisLift;i.z2=t.z2+(null!=f?f:y)}return i}function V(t,e,n){if(n&&null==n.z2){n=Object(r["m"])({},n);var i=t.z2SelectLift;n.z2=t.z2+(null!=i?i:_)}return n}function F(t,e,n){var i=Object(r["r"])(t.currentStates,e)>=0,a=t.style.opacity,o=i?null:B(t,["opacity"],e,{opacity:1});n=n||{};var s=n.style||{};return null==s.opacity&&(n=Object(r["m"])({},n),s=Object(r["m"])({opacity:i?a:.1*o.opacity},s),n.style=s),n}function G(t,e){var n=this.states[t];if(this.style){if("emphasis"===t)return z(this,t,e,n);if("blur"===t)return F(this,t,n);if("select"===t)return V(this,t,n)}return n}function H(t){t.stateProxy=G;var e=t.getTextContent(),n=t.getTextGuideLine();e&&(e.stateProxy=G),n&&(n.stateProxy=G)}function U(t,e){!J(t,e)&&!t.__highByOuter&&R(t,I)}function W(t,e){!J(t,e)&&!t.__highByOuter&&R(t,D)}function X(t,e){t.__highByOuter|=1<<(e||0),R(t,I)}function Z(t,e){!(t.__highByOuter&=~(1<<(e||0)))&&R(t,D)}function q(t){R(t,L)}function Y(t){R(t,E)}function K(t){R(t,j)}function Q(t){R(t,P)}function J(t,e){return t.__highDownSilentOnTouch&&e.zrByTouch}function $(t){var e=t.getModel(),n=[],i=[];e.eachComponent((function(e,r){var a=d(r),o="series"===e,s=o?t.getViewOfSeriesModel(r):t.getViewOfComponentModel(r);!o&&i.push(s),a.isBlured&&(s.group.traverse((function(t){E(t)})),o&&n.push(r)),a.isBlured=!1})),Object(r["k"])(i,(function(t){t&&t.toggleBlurSeries&&t.toggleBlurSeries(n,!1,e)}))}function tt(t,e,n,i){var a=i.getModel();function o(t,e){for(var n=0;n0){var a={dataIndex:r,seriesIndex:t.seriesIndex};null!=i&&(a.dataType=i),e.push(a)}}))})),e}function ut(t,e,n){mt(t,!0),R(t,H),dt(t,e,n)}function ct(t){mt(t,!1)}function ht(t,e,n,i){i?ct(t):ut(t,e,n)}function dt(t,e,n){var i=Object(a["a"])(t);null!=e?(i.focus=e,i.blurScope=n):i.focus&&(i.focus=null)}var ft=["emphasis","blur","select"],pt={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function gt(t,e,n,i){n=n||"itemStyle";for(var r=0;r30}},"80f0":function(t,e,n){"use strict";function i(t){return null==t?0:t.length||1}function r(t){return t}var a=function(){function t(t,e,n,i,a,o){this._old=t,this._new=e,this._oldKeyGetter=n||r,this._newKeyGetter=i||r,this.context=a,this._diffModeMultiple="multiple"===o}return t.prototype.add=function(t){return this._add=t,this},t.prototype.update=function(t){return this._update=t,this},t.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},t.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},t.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},t.prototype.remove=function(t){return this._remove=t,this},t.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},t.prototype._executeOneToOne=function(){var t=this._old,e=this._new,n={},r=new Array(t.length),a=new Array(e.length);this._initIndexMap(t,null,r,"_oldKeyGetter"),this._initIndexMap(e,n,a,"_newKeyGetter");for(var o=0;o1){var c=l.shift();1===l.length&&(n[s]=l[0]),this._update&&this._update(c,o)}else 1===u?(n[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(a,n)},t.prototype._executeMultiple=function(){var t=this._old,e=this._new,n={},r={},a=[],o=[];this._initIndexMap(t,n,a,"_oldKeyGetter"),this._initIndexMap(e,r,o,"_newKeyGetter");for(var s=0;s1&&1===d)this._updateManyToOne&&this._updateManyToOne(c,u),r[l]=null;else if(1===h&&d>1)this._updateOneToMany&&this._updateOneToMany(c,u),r[l]=null;else if(1===h&&1===d)this._update&&this._update(c,u),r[l]=null;else if(h>1&&d>1)this._updateManyToMany&&this._updateManyToMany(c,u),r[l]=null;else if(h>1)for(var f=0;f1)for(var s=0;s40&&(c=Math.max(1,Math.floor(u/40)));for(var h=o[0],d=t.dataToCoord(h+1)-t.dataToCoord(h),f=Math.abs(d*Math.cos(i)),p=Math.abs(d*Math.sin(i)),g=0,m=0;h<=o[1];h+=c){var v=0,y=0,_=a["d"](n({value:h}),e.font,"center","top");v=1.3*_.width,y=1.3*_.height,g=Math.max(g,v,7),m=Math.max(m,y,7)}var x=g/f,w=m/p;isNaN(x)&&(x=1/0),isNaN(w)&&(w=1/0);var O=Math.max(0,Math.floor(Math.min(x,w))),S=l(t.model),T=t.getExtent(),M=S.lastAutoInterval,A=S.lastTickCount;return null!=M&&null!=A&&Math.abs(M-O)<=1&&Math.abs(A-u)<=1&&M>O&&S.axisExtent0===T[0]&&S.axisExtent1===T[1]?O=M:(S.lastTickCount=u,S.lastAutoInterval=O,S.axisExtent0=T[0],S.axisExtent1=T[1]),O}function b(t){var e=t.getLabelModel();return{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}function x(t,e,n){var i=Object(s["h"])(t),r=t.scale,a=r.getExtent(),o=t.getLabelModel(),l=[],u=Math.max((e||0)+1,1),c=a[0],h=r.count();0!==c&&u>1&&h/u>2&&(c=Math.round(Math.ceil(c/u)*u));var d=Object(s["j"])(t),f=o.get("showMinLabel")||d,p=o.get("showMaxLabel")||d;f&&c!==a[0]&&m(a[0]);for(var g=c;g<=a[1];g+=u)m(g);function m(t){var e={value:t};l.push(n?t:{formattedLabel:i(e),rawLabel:r.getLabel(e),tickValue:t})}return p&&g-u!==a[1]&&m(a[1]),l}function w(t,e,n){var r=t.scale,a=Object(s["h"])(t),o=[];return i["k"](r.getTicks(),(function(t){var i=r.getLabel(t),s=t.value;e(t.value,i)&&o.push(n?s:{formattedLabel:a(t),rawLabel:i,tickValue:s})})),o}var O=[0,1],S=function(){function t(t,e,n){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=e,this._extent=n||[0,0]}return t.prototype.contain=function(t){var e=this._extent,n=Math.min(e[0],e[1]),i=Math.max(e[0],e[1]);return t>=n&&t<=i},t.prototype.containData=function(t){return this.scale.contain(t)},t.prototype.getExtent=function(){return this._extent.slice()},t.prototype.getPixelPrecision=function(t){return Object(r["f"])(t||this.scale.getExtent(),this._extent)},t.prototype.setExtent=function(t,e){var n=this._extent;n[0]=t,n[1]=e},t.prototype.dataToCoord=function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&(n=n.slice(),T(n,i.count())),Object(r["l"])(t,O,n,e)},t.prototype.coordToData=function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&(n=n.slice(),T(n,i.count()));var a=Object(r["l"])(t,n,O,e);return this.scale.scale(a)},t.prototype.pointToData=function(t,e){},t.prototype.getTicksCoords=function(t){t=t||{};var e=t.tickModel||this.getTickModel(),n=c(this,e),r=n.ticks,a=Object(i["H"])(r,(function(t){return{coord:this.dataToCoord("ordinal"===this.scale.type?this.scale.getRawOrdinalNumber(t):t),tickValue:t}}),this),o=e.get("alignWithLabel");return M(this,a,o,t.clamp),a},t.prototype.getMinorTicksCoords=function(){if("ordinal"===this.scale.type)return[];var t=this.model.getModel("minorTick"),e=t.get("splitNumber");e>0&&e<100||(e=5);var n=this.scale.getMinorTicks(e),r=Object(i["H"])(n,(function(t){return Object(i["H"])(t,(function(t){return{coord:this.dataToCoord(t),tickValue:t}}),this)}),this);return r},t.prototype.getViewLabels=function(){return u(this).labels},t.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},t.prototype.getTickModel=function(){return this.model.getModel("axisTick")},t.prototype.getBandWidth=function(){var t=this._extent,e=this.scale.getExtent(),n=e[1]-e[0]+(this.onBand?1:0);0===n&&(n=1);var i=Math.abs(t[1]-t[0]);return Math.abs(i)/n},t.prototype.calculateCategoryInterval=function(){return _(this)},t}();function T(t,e){var n=t[1]-t[0],i=e,r=n/i/2;t[0]+=r,t[1]-=r}function M(t,e,n,a){var o=e.length;if(t.onBand&&!n&&o){var s,l,u=t.getExtent();if(1===o)e[0].coord=u[0],s=e[1]={coord:u[0]};else{var c=e[o-1].tickValue-e[0].tickValue,h=(e[o-1].coord-e[0].coord)/c;Object(i["k"])(e,(function(t){t.coord-=h/2}));var d=t.scale.getExtent();l=1+d[1]-e[o-1].tickValue,s={coord:e[o-1].coord+h*l},e.push(s)}var f=u[0]>u[1];p(e[0].coord,u[0])&&(a?e[0].coord=u[0]:e.shift()),a&&p(u[0],e[0].coord)&&e.unshift({coord:u[0]}),p(u[1],s.coord)&&(a?s.coord=u[1]:e.pop()),a&&p(s.coord,u[1])&&e.push({coord:u[1]})}function p(t,e){return t=Object(r["v"])(t),e=Object(r["v"])(e),f?t>e:to||t<-o}var l=[],u=[],c=i["c"](),h=Math.abs,d=function(){function t(){}return t.prototype.getLocalTransform=function(e){return t.getLocalTransform(this,e)},t.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},t.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},t.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},t.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},t.prototype.needLocalTransform=function(){return s(this.rotation)||s(this.x)||s(this.y)||s(this.scaleX-1)||s(this.scaleY-1)||s(this.skewX)||s(this.skewY)},t.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,e=this.needLocalTransform(),n=this.transform;e||t?(n=n||i["c"](),e?this.getLocalTransform(n):a(n),t&&(e?i["f"](n,t,n):i["b"](n,t)),this.transform=n,this._resolveGlobalScaleRatio(n)):n&&a(n)},t.prototype._resolveGlobalScaleRatio=function(t){var e=this.globalScaleRatio;if(null!=e&&1!==e){this.getGlobalScale(l);var n=l[0]<0?-1:1,r=l[1]<0?-1:1,a=((l[0]-n)*e+n)/l[0]||0,o=((l[1]-r)*e+r)/l[1]||0;t[0]*=a,t[1]*=a,t[2]*=o,t[3]*=o}this.invTransform=this.invTransform||i["c"](),i["e"](this.invTransform,t)},t.prototype.getComputedTransform=function(){var t=this,e=[];while(t)e.push(t),t=t.parent;while(t=e.pop())t.updateTransform();return this.transform},t.prototype.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],n=t[2]*t[2]+t[3]*t[3],i=Math.atan2(t[1],t[0]),r=Math.PI/2+i-Math.atan2(t[3],t[2]);n=Math.sqrt(n)*Math.cos(r),e=Math.sqrt(e),this.skewX=r,this.skewY=0,this.rotation=-i,this.x=+t[4],this.y=+t[5],this.scaleX=e,this.scaleY=n,this.originX=0,this.originY=0}},t.prototype.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(i["f"](u,t.invTransform,e),e=u);var n=this.originX,r=this.originY;(n||r)&&(c[4]=n,c[5]=r,i["f"](u,e,c),u[4]-=n,u[5]-=r,e=u),this.setLocalTransform(e)}},t.prototype.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},t.prototype.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&r["b"](n,n,i),n},t.prototype.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&r["b"](n,n,i),n},t.prototype.getLineScale=function(){var t=this.transform;return t&&h(t[0]-1)>1e-10&&h(t[3]-1)>1e-10?Math.sqrt(h(t[0]*t[3]-t[2]*t[1])):1},t.prototype.copyTransform=function(t){p(this,t)},t.getLocalTransform=function(t,e){e=e||[];var n=t.originX||0,r=t.originY||0,a=t.scaleX,o=t.scaleY,s=t.anchorX,l=t.anchorY,u=t.rotation||0,c=t.x,h=t.y,d=t.skewX?Math.tan(t.skewX):0,f=t.skewY?Math.tan(-t.skewY):0;if(n||r||s||l){var p=n+s,g=r+l;e[4]=-p*a-d*g*o,e[5]=-g*o-f*p*a}else e[4]=e[5]=0;return e[0]=a,e[3]=o,e[1]=f*a,e[2]=d*o,u&&i["g"](e,e,u),e[4]+=n+c,e[5]+=r+h,e},t.initDefaultProps=function(){var e=t.prototype;e.scaleX=e.scaleY=e.globalScaleRatio=1,e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0}(),t}(),f=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function p(t,e){for(var n=0;ne&&a>i||ar?s:0}n.d(e,"a",(function(){return i}))},"87b1":function(t,e,n){"use strict";var i=n("21a10"),r=n("cbe5"),a=n("4fac"),o=function(){function t(){this.points=null,this.smooth=0,this.smoothConstraint=null}return t}(),s=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype.getDefaultShape=function(){return new o},e.prototype.buildPath=function(t,e){a["a"](t,e,!0)},e}(r["b"]);s.prototype.type="polygon",e["a"]=s},"88b3":function(t,e,n){"use strict";n.d(e,"c",(function(){return o})),n.d(e,"b",(function(){return s})),n.d(e,"a",(function(){return l}));var i="\0__throttleOriginMethod",r="\0__throttleRate",a="\0__throttleType";function o(t,e,n){var i,r,a,o,s,l=0,u=0,c=null;function h(){u=(new Date).getTime(),c=null,t.apply(a,o||[])}e=e||0;var d=function(){for(var t=[],d=0;d=0?h():c=setTimeout(h,-r),l=i};return d.clear=function(){c&&(clearTimeout(c),c=null)},d.debounceNextCall=function(t){s=t},d}function s(t,e,n,s){var l=t[e];if(l){var u=l[i]||l,c=l[a],h=l[r];if(h!==n||c!==s){if(null==n||!s)return t[e]=u;l=t[e]=o(u,n,"debounce"===s),l[i]=u,l[a]=s,l[r]=n}return l}}function l(t,e){var n=t[e];n&&n[i]&&(n.clear&&n.clear(),t[e]=n[i])}},8918:function(t,e,n){"use strict";n.d(e,"c",(function(){return o})),n.d(e,"a",(function(){return s})),n.d(e,"b",(function(){return l})),n.d(e,"d",(function(){return u}));var i=n("6d8b"),r=n("625e"),a=Math.round(10*Math.random());function o(t){return[t||"",a++].join("_")}function s(t){var e={};t.registerSubTypeDefaulter=function(t,n){var i=Object(r["f"])(t);e[i.main]=n},t.determineSubType=function(n,i){var a=i.type;if(!a){var o=Object(r["f"])(n).main;t.hasSubTypes(n)&&e[o]&&(a=e[o](i))}return a}}function l(t,e){function n(t){var n={},o=[];return i["k"](t,(function(s){var l=r(n,s),u=l.originalDeps=e(s),c=a(u,t);l.entryCount=c.length,0===l.entryCount&&o.push(s),i["k"](c,(function(t){i["r"](l.predecessor,t)<0&&l.predecessor.push(t);var e=r(n,t);i["r"](e.successor,t)<0&&e.successor.push(s)}))})),{graph:n,noEntryList:o}}function r(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}function a(t,e){var n=[];return i["k"](t,(function(t){i["r"](e,t)>=0&&n.push(t)})),n}t.topologicalTravel=function(t,e,r,a){if(t.length){var o=n(e),s=o.graph,l=o.noEntryList,u={};i["k"](t,(function(t){u[t]=!0}));while(l.length){var c=l.pop(),h=s[c],d=!!u[c];d&&(r.call(a,c,h.originalDeps.slice()),delete u[c]),i["k"](h.successor,d?p:f)}i["k"](u,(function(){var t="";throw new Error(t)}))}function f(t){s[t].entryCount--,0===s[t].entryCount&&l.push(t)}function p(t){u[t]=!0,f(t)}}}function u(t,e){return i["I"](i["I"]({},t,!0),e,!0)}},"89b6":function(t,e,n){"use strict";n.d(e,"e",(function(){return C})),n.d(e,"c",(function(){return L})),n.d(e,"b",(function(){return E})),n.d(e,"d",(function(){return N})),n.d(e,"a",(function(){return R}));var i=n("dce8"),r=n("cbe5"),a=n("d498"),o=n("20c8"),s=n("857d"),l=n("4a3f"),u=n("6d8b"),c=n("1687"),h=n("401b"),d=n("7d6c"),f=2*Math.PI,p=o["a"].CMD,g=["top","right","bottom","left"];function m(t,e,n,i,r){var a=n.width,o=n.height;switch(t){case"top":i.set(n.x+a/2,n.y-e),r.set(0,-1);break;case"bottom":i.set(n.x+a/2,n.y+o+e),r.set(0,1);break;case"left":i.set(n.x-e,n.y+o/2),r.set(-1,0);break;case"right":i.set(n.x+a+e,n.y+o/2),r.set(1,0);break}}function v(t,e,n,i,r,a,o,l,u){o-=t,l-=e;var c=Math.sqrt(o*o+l*l);o/=c,l/=c;var h=o*n+t,d=l*n+e;if(Math.abs(i-r)%f<1e-4)return u[0]=h,u[1]=d,c-n;if(a){var p=i;i=Object(s["a"])(r),r=Object(s["a"])(p)}else i=Object(s["a"])(i),r=Object(s["a"])(r);i>r&&(r+=f);var g=Math.atan2(l,o);if(g<0&&(g+=f),g>=i&&g<=r||g+f>=i&&g+f<=r)return u[0]=h,u[1]=d,c-n;var m=n*Math.cos(i)+t,v=n*Math.sin(i)+e,y=n*Math.cos(r)+t,_=n*Math.sin(r)+e,b=(m-o)*(m-o)+(v-l)*(v-l),x=(y-o)*(y-o)+(_-l)*(_-l);return b0){e=e/180*Math.PI,O.fromArray(t[0]),S.fromArray(t[1]),T.fromArray(t[2]),i["a"].sub(M,O,S),i["a"].sub(A,T,S);var n=M.len(),r=A.len();if(!(n<.001||r<.001)){M.scale(1/n),A.scale(1/r);var a=M.dot(A),o=Math.cos(e);if(o1&&i["a"].copy(D,T),D.toArray(t[1])}}}}function E(t,e,n){if(n<=180&&n>0){n=n/180*Math.PI,O.fromArray(t[0]),S.fromArray(t[1]),T.fromArray(t[2]),i["a"].sub(M,S,O),i["a"].sub(A,T,S);var r=M.len(),a=A.len();if(!(r<.001||a<.001)){M.scale(1/r),A.scale(1/a);var o=M.dot(e),s=Math.cos(n);if(o=u)i["a"].copy(D,T);else{D.scaleAndAdd(A,l/Math.tan(Math.PI/2-h));var d=T.x!==S.x?(D.x-S.x)/(T.x-S.x):(D.y-S.y)/(T.y-S.y);if(isNaN(d))return;d<0?i["a"].copy(D,S):d>1&&i["a"].copy(D,T)}D.toArray(t[1])}}}}function j(t,e,n,i){var r="normal"===n,a=r?t:t.ensureState(n);a.ignore=e;var o=i.get("smooth");o&&!0===o&&(o=.3),a.shape=a.shape||{},o>0&&(a.shape.smooth=o);var s=i.getModel("lineStyle").getLineStyle();r?t.useStyle(s):a.style=s}function P(t,e){var n=e.smooth,i=e.points;if(i)if(t.moveTo(i[0][0],i[0][1]),n>0&&i.length>=3){var r=h["f"](i[0],i[1]),a=h["f"](i[1],i[2]);if(!r||!a)return t.lineTo(i[1][0],i[1][1]),void t.lineTo(i[2][0],i[2][1]);var o=Math.min(r,a)*n,s=h["j"]([],i[1],i[0],o/r),l=h["j"]([],i[1],i[2],o/a),u=h["j"]([],s,l,.5);t.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),t.bezierCurveTo(l[0],l[1],l[0],l[1],i[2][0],i[2][1])}else for(var c=1;ce[1]&&(e[1]=t[1]),this.setExtent(e[0],e[1])},e.prototype.getInterval=function(){return this._interval},e.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=s["b"](t)},e.prototype.getTicks=function(t){var e=this._interval,n=this._extent,i=this._niceExtent,r=this._intervalPrecision,a=[];if(!e)return a;var o=1e4;n[0]o)return[]}var u=a.length?a[a.length-1].value:i[1];return n[1]>u&&(t?a.push({value:l(u+e,r)}):a.push({value:n[1]})),a},e.prototype.getMinorTicks=function(t){for(var e=this.getTicks(!0),n=[],i=this.getExtent(),r=1;ri[0]&&d0?"dashed"===t?[4*e,2*e]:"dotted"===t?[e]:Object(i["z"])(t)?[t]:Object(i["t"])(t)?t:null:null}function a(t){var e=t.style,n=e.lineDash&&e.lineWidth>0&&r(e.lineDash,e.lineWidth),a=e.lineDashOffset;if(n){var o=e.strokeNoScale&&t.getLineScale?t.getLineScale():1;o&&1!==o&&(n=Object(i["H"])(n,(function(t){return t/o})),a/=o)}return[n,a]}},"8d32":function(t,e,n){"use strict";var i=n("21a10"),r=n("cbe5"),a=function(){function t(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0}return t}(),o=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new a},e.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r,0),a=e.startAngle,o=e.endAngle,s=e.clockwise,l=Math.cos(a),u=Math.sin(a);t.moveTo(l*r+n,u*r+i),t.arc(n,i,r,a,o,!s)},e}(r["b"]);o.prototype.type="arc",e["a"]=o},"8e43":function(t,e,n){"use strict";var i=n("6d8b"),r=0,a=function(){function t(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++r}return t.createByAxisModel=function(e){var n=e.option,r=n.data,a=r&&Object(i["H"])(r,o);return new t({categories:a,needCollect:!a,deduplication:!1!==n.dedplication})},t.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},t.prototype.parseAndCollect=function(t){var e,n=this._needCollect;if(!Object(i["C"])(t)&&!n)return t;if(n&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var r=this._getOrCreateMap();return e=r.get(t),null==e&&(n?(e=this.categories.length,this.categories[e]=t,r.set(t,e)):e=NaN),e},t.prototype._getOrCreateMap=function(){return this._map||(this._map=Object(i["f"])(this.categories))},t}();function o(t){return Object(i["A"])(t)&&null!=t.value?t.value:t+""}e["a"]=a},"92c1":function(t,e,n){t.exports=n.p+"static/img/car.78c4a90c.png"},"944e":function(t,e,n){"use strict";n.d(e,"e",(function(){return r})),n.d(e,"d",(function(){return a})),n.d(e,"c",(function(){return o})),n.d(e,"b",(function(){return s})),n.d(e,"a",(function(){return c})),n.d(e,"f",(function(){return h})),n.d(e,"g",(function(){return d}));var i=n("3842");function r(t){return"interval"===t.type||"log"===t.type}function a(t,e,n,r){var a={},o=t[1]-t[0],l=a.interval=Object(i["m"])(o/e,!0);null!=n&&lr&&(l=a.interval=r);var c=a.intervalPrecision=s(l),h=a.niceTickExtent=[Object(i["v"])(Math.ceil(t[0]/l)*l,c),Object(i["v"])(Math.floor(t[1]/l)*l,c)];return u(h,t),a}function o(t){var e=Math.pow(10,Object(i["s"])(t)),n=t/e;return n?2===n?n=3:3===n?n=5:n*=2:n=1,Object(i["v"])(n*e)}function s(t){return Object(i["g"])(t)+2}function l(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function u(t,e){!isFinite(t[0])&&(t[0]=e[0]),!isFinite(t[1])&&(t[1]=e[1]),l(t,0,e),l(t,1,e),t[0]>t[1]&&(t[0]=t[1])}function c(t,e){return t>=e[0]&&t<=e[1]}function h(t,e){return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])}function d(t,e){return t*(e[1]-e[0])+e[0]}},9680:function(t,e,n){"use strict";function i(t,e,n,i,r,a,o){if(0===r)return!1;var s=r,l=0,u=t;if(o>e+s&&o>i+s||ot+s&&a>n+s||av&&(v=w,y<_?r["a"].set(d,-y,0):r["a"].set(d,_,0)):wv&&(v=O,b=n.x&&t<=n.x+n.width&&e>=n.y&&e<=n.y+n.height},t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.copy=function(e){t.copy(this,e)},t.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},t.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},t.prototype.isZero=function(){return 0===this.width||0===this.height},t.create=function(e){return new t(e.x,e.y,e.width,e.height)},t.copy=function(t,e){t.x=e.x,t.y=e.y,t.width=e.width,t.height=e.height},t.applyTransform=function(e,n,i){if(i){if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var r=i[0],h=i[3],d=i[4],f=i[5];return e.x=n.x*r+d,e.y=n.y*h+f,e.width=n.width*r,e.height=n.height*h,e.width<0&&(e.x+=e.width,e.width=-e.width),void(e.height<0&&(e.y+=e.height,e.height=-e.height))}s.x=u.x=n.x,s.y=c.y=n.y,l.x=c.x=n.x+n.width,l.y=u.y=n.y+n.height,s.transform(i),c.transform(i),l.transform(i),u.transform(i),e.x=a(s.x,l.x,u.x,c.x),e.y=a(s.y,l.y,u.y,c.y);var p=o(s.x,l.x,u.x,c.x),g=o(s.y,l.y,u.y,c.y);e.width=p-e.x,e.height=g-e.y}else e!==n&&t.copy(e,n)},t}();e["a"]=f},"98b7":function(t,e,n){"use strict";var i,r=n("22d1");i=r["a"].hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){return setTimeout(t,16)},e["a"]=i},"98ce":function(t,e,n){"use strict";n.r(e);var i=n("7a23"),r=n("b893"),a=n("b932"),o=n("c5cb"),s=n("ad28");const l=Object(i["createTextVNode"])("详情");var u={__name:"index",setup(t,{expose:e}){const n=Object(i["reactive"])({tableData:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"null",loading:!1},total:0,pageConfiger:{pageSize:20,pageCurrent:1},tableHeight:143,controlsWidth:52,tableColumn:[{label:"线索名称",prop:"xsMc",width:"70px",showOverflowTooltip:!0},{label:"涉及人数",prop:"sjrs",width:"70px",showOverflowTooltip:!0},{label:"线索内容",prop:"xsNr",width:"120px",showOverflowTooltip:!0},{label:"指向地点",prop:"zxdz",width:"70px",showOverflowTooltip:!0}]}),r=Object(i["ref"])({});Object(i["onMounted"])(()=>{u()});const a=t=>{r.value=t,u()};function u(){let t={...r.value};delete t.dateRange,n.pageConfiger.loading=!0,Object(o["c"])(t,"/mosty-gsxt/qbcj/getRdXs").then(t=>{n.tableData=t||[],n.pageConfiger.loading=!1}).catch(()=>{n.pageConfiger.loading=!1})}return e({init:a}),(t,e)=>{const r=Object(i["resolveComponent"])("el-link");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",null,[(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:n.tableData,tableColumn:n.tableColumn,tableHeight:n.tableHeight,key:n.keyCount,fixed:!1,tableConfiger:n.tableConfiger,controlsWidth:n.controlsWidth},{controls:Object(i["withCtx"])(({row:e})=>[Object(i["createVNode"])(r,{size:"small",type:"primary",onClick:n=>t.addEdit("detail",e)},{default:Object(i["withCtx"])(()=>[l]),_:2},1032,["onClick"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"]))])}}},c=(n("38ac"),n("6b0d")),h=n.n(c);const d=h()(u,[["__scopeId","data-v-43394445"]]);var f=d;const p={key:0},g=Object(i["createTextVNode"])("详情");var m={__name:"index",setup(t,{expose:e}){const n=Object(i["reactive"])({tableData:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"null",loading:!1},total:0,pageConfiger:{pageSize:20,pageCurrent:1},tableHeight:143,controlsWidth:52,tableColumn:[{label:"组织名称",prop:"qtMc",width:"70px",showOverflowTooltip:!0},{label:"涉及人数",prop:"sjrs",width:"70px",showSolt:!0,showOverflowTooltip:!0},{label:"标签",prop:"bqList",width:"50px",showSolt:!0,showOverflowTooltip:!0},{label:"线索数",prop:"xssl",width:"70px",showOverflowTooltip:!0},{label:"指令数",prop:"zlsl",width:"70px",showOverflowTooltip:!0}]}),r=Object(i["ref"])({});Object(i["onMounted"])(()=>{l()});const a=t=>{r.value=t,l()};function l(){let t={...r.value};delete t.dateRange,n.pageConfiger.loading=!0,Object(o["c"])(t,"/mosty-gsxt/tbGsxtZdqt/getRdzz").then(t=>{n.tableData=t||[],n.pageConfiger.loading=!1}).catch(()=>{n.pageConfiger.loading=!1})}return e({init:a}),(t,e)=>{const r=Object(i["resolveComponent"])("el-link");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",null,[(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:n.tableData,tableColumn:n.tableColumn,tableHeight:n.tableHeight,key:n.keyCount,fixed:!1,tableConfiger:n.tableConfiger,controlsWidth:n.controlsWidth},{sjrs:Object(i["withCtx"])(({row:t})=>[Object(i["createElementVNode"])("span",null,Object(i["toDisplayString"])(t.zdryList?t.zdryList.length:0),1)]),bqList:Object(i["withCtx"])(({row:t})=>[t.bqList?(Object(i["openBlock"])(),Object(i["createElementBlock"])("span",p,[(Object(i["openBlock"])(!0),Object(i["createElementBlock"])(i["Fragment"],null,Object(i["renderList"])(t.bqList,(t,e)=>(Object(i["openBlock"])(),Object(i["createElementBlock"])("span",{key:e},Object(i["toDisplayString"])(t.bqMc)+"、",1))),128))])):Object(i["createCommentVNode"])("",!0)]),controls:Object(i["withCtx"])(({row:e})=>[Object(i["createVNode"])(r,{size:"small",type:"primary",onClick:n=>t.addEdit("detail",e)},{default:Object(i["withCtx"])(()=>[g]),_:2},1032,["onClick"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"]))])}}};n("0947");const v=h()(m,[["__scopeId","data-v-283f7c3a"]]);var y=v;const _={class:"ww100 hh100"},b={key:0},x=Object(i["createTextVNode"])("; "),w=Object(i["createTextVNode"])("详情");var O={__name:"index",setup(t,{expose:e}){const n=Object(i["reactive"])({tableData:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"null",loading:!1},total:0,pageConfiger:{pageSize:20,pageCurrent:1},tableHeight:143,controlsWidth:52,tableColumn:[{label:"姓名",prop:"ryXm",width:"70px",showOverflowTooltip:!0},{label:"身份证",prop:"rySfzh",width:"70px",showOverflowTooltip:!0},{label:"标签",prop:"bqList",width:"50px",showSolt:!0,showOverflowTooltip:!0},{label:"线索数",prop:"xssl",width:"70px",showOverflowTooltip:!0},{label:"指令数",prop:"zlsl",width:"70px",showOverflowTooltip:!0}]}),r=Object(i["ref"])({});Object(i["onMounted"])(()=>{l()});const a=t=>{r.value=t,l()};function l(){let t={...r.value};delete t.dateRange,n.pageConfiger.loading=!0,Object(o["c"])(t,"/mosty-gsxt/tbGsxtZdry/getRdRy").then(t=>{n.tableData=t||[],n.pageConfiger.loading=!1}).catch(()=>{n.pageConfiger.loading=!1})}return e({init:a}),(t,e)=>{const r=Object(i["resolveComponent"])("el-link");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",_,[(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:n.tableData,tableColumn:n.tableColumn,tableHeight:n.tableHeight,key:n.keyCount,fixed:!1,tableConfiger:n.tableConfiger,controlsWidth:n.controlsWidth},{bqList:Object(i["withCtx"])(({row:t})=>[t.bqList?(Object(i["openBlock"])(),Object(i["createElementBlock"])("span",b,[(Object(i["openBlock"])(!0),Object(i["createElementBlock"])(i["Fragment"],null,Object(i["renderList"])(t.bqList,t=>(Object(i["openBlock"])(),Object(i["createElementBlock"])("span",{key:t},Object(i["toDisplayString"])(t.bqMc),1))),128)),x])):Object(i["createCommentVNode"])("",!0)]),controls:Object(i["withCtx"])(({row:e})=>[Object(i["createVNode"])(r,{size:"small",type:"primary",onClick:n=>t.addEdit("detail",e)},{default:Object(i["withCtx"])(()=>[w]),_:2},1032,["onClick"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"]))])}}};n("9c28");const S=h()(O,[["__scopeId","data-v-b07a6e6e"]]);var T=S;const M=Object(i["createTextVNode"])("详情");var A={__name:"index",setup(t,{expose:e}){const n=Object(i["reactive"])({tableData:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"null",loading:!1},total:0,pageConfiger:{pageSize:20,pageCurrent:1},tableHeight:143,controlsWidth:52,tableColumn:[{label:"号码类型",prop:"hmlx",width:"70px",showOverflowTooltip:!0},{label:"号码",prop:"hm",width:"120px",showOverflowTooltip:!0},{label:"线索数",prop:"glxss",width:"70px",showOverflowTooltip:!0},{label:"指令数",prop:"glzls",width:"70px",showOverflowTooltip:!0}]}),r=Object(i["ref"])({});Object(i["onMounted"])(()=>{l()});const a=t=>{r.value=t,l()};function l(){let t={...r.value};delete t.dateRange,n.pageConfiger.loading=!0,Object(o["c"])(t,"/mosty-gsxt/tbGsxtZdqt/getRdhm").then(t=>{n.tableData=t||[],n.pageConfiger.loading=!1}).catch(()=>{n.pageConfiger.loading=!1})}return e({init:a}),(t,e)=>{const r=Object(i["resolveComponent"])("el-link");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",null,[(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:n.tableData,tableColumn:n.tableColumn,tableHeight:n.tableHeight,key:n.keyCount,fixed:!1,tableConfiger:n.tableConfiger,controlsWidth:n.controlsWidth},{controls:Object(i["withCtx"])(({row:e})=>[Object(i["createVNode"])(r,{size:"small",type:"primary",onClick:n=>t.addEdit("detail",e)},{default:Object(i["withCtx"])(()=>[M]),_:2},1032,["onClick"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"]))])}}};n("f5c8");const C=h()(A,[["__scopeId","data-v-d2f576e8"]]);var I=C,D=n("e767");const L={class:"comom-cnt"};var E={__name:"index",setup(t,{expose:e}){const n=Object(i["ref"])(!1),a=Object(i["ref"])([]),s=Object(i["ref"])({});Object(i["onMounted"])(()=>{u()});const l=t=>{s.value=t,u()};function u(){let t={...s.value};delete t.dateRange,n.value=!0,Object(o["c"])(t,"/mosty-gsxt/tbGsxtZdqt/getSqflTj").then(t=>{n.value=!1;let e=t||[];a.value=e.map(t=>{let e=Object(r["c"])(),n=Object(r["a"])(e,.5);return{label:t.zdmc,value:t.dm,color:[e,n]}})}).catch(()=>{n.value=!1})}return e({init:l}),(t,e)=>{const r=Object(i["resolveDirective"])("loading");return Object(i["withDirectives"])((Object(i["openBlock"])(),Object(i["createElementBlock"])("div",L,[Object(i["createVNode"])(D["a"],{echartsId:"zqflEcharts",color:"#333",data:a.value},null,8,["data"])])),[[r,n.value]])}}};n("cac2");const j=h()(E,[["__scopeId","data-v-1cf1d432"]]);var P=j;const N={class:"box-zl"};var R={__name:"index",setup(t,{expose:e}){const n=Object(i["ref"])([{label:"线索数量",num:0,type:"xs"},{label:"线索转指令数量",num:0,type:"zlxx"},{label:"关联群体数量",num:0,type:"zdqt"},{label:"关联人员数量",num:0,type:"zdry"}]),r=Object(i["ref"])(!1),a=Object(i["ref"])({});Object(i["onMounted"])(()=>{l()});const s=t=>{a.value=t,l()};function l(){let t={...a.value};delete t.dateRange,r.value=!0,Object(o["d"])(t,"/mosty-gsxt/qbcj/getXscjTjForZs").then(t=>{for(let e in t){let i=n.value.findIndex(t=>t.type==e);-1!=i&&(n.value[i].num=t[e])}r.value=!1}).catch(()=>{r.value=!1})}return e({init:s}),(t,e)=>{const a=Object(i["resolveDirective"])("loading");return Object(i["withDirectives"])((Object(i["openBlock"])(),Object(i["createElementBlock"])("ul",N,[(Object(i["openBlock"])(!0),Object(i["createElementBlock"])(i["Fragment"],null,Object(i["renderList"])(n.value,(t,e)=>(Object(i["openBlock"])(),Object(i["createElementBlock"])("li",{class:"items",key:e},[Object(i["createElementVNode"])("div",null,Object(i["toDisplayString"])(t.num),1),Object(i["createElementVNode"])("div",null,Object(i["toDisplayString"])(t.label),1)]))),128))])),[[a,r.value]])}}};n("26b4");const k=h()(R,[["__scopeId","data-v-7ffc6ca3"]]);var B=k,z=n("0007");const V={class:"comom-cnt"};var F={__name:"index",setup(t,{expose:e}){const n=Object(i["reactive"])({xData:[],color:["#0386FB","#00FFFF"],labelColor:"#333",list:[{label:"",val:[0,0,10,0,0,0,0]}]}),r=Object(i["ref"])(!1),a=Object(i["ref"])({});Object(i["onMounted"])(()=>{l()});const s=t=>{a.value=t,l()};function l(){let t={...a.value};delete t.dateRange,r.value=!0,Object(o["d"])(t,"/mosty-gsxt/qbcj/getXscjTjByXslx").then(t=>{r.value=!1;let e=t||[];n.xData=e.map(t=>t.zdmc),n.list[0].val=e.map(t=>t.count)}).catch(()=>{r.value=!1})}return e({init:s}),(t,e)=>{const a=Object(i["resolveDirective"])("loading");return Object(i["withDirectives"])((Object(i["openBlock"])(),Object(i["createElementBlock"])("div",V,[Object(i["createVNode"])(z["a"],{echartsId:"qbsbEcharts111",data:n},null,8,["data"])])),[[a,r.value]])}}};n("a1ba");const G=h()(F,[["__scopeId","data-v-1113afdc"]]);var H=G,U=n("2d16");const W=t=>(Object(i["pushScopeId"])("data-v-4d577da3"),t=t(),Object(i["popScopeId"])(),t),X={class:"container"},Z={class:"header flex just-between"},q=W(()=>Object(i["createElementVNode"])("span",null,"情报研判分析",-1)),Y={class:"seachsBox"},K={class:"flex align-center"},Q=["onClick"],J={class:"contant"},$={class:"contant-left aside"},tt={class:"model"},et=W(()=>Object(i["createElementVNode"])("div",{class:"modelTitle"},"热点线索",-1)),nt={class:"cnt"},it={class:"model"},rt=W(()=>Object(i["createElementVNode"])("div",{class:"modelTitle"},"热点组织",-1)),at={class:"cnt"},ot={class:"model"},st=W(()=>Object(i["createElementVNode"])("div",{class:"modelTitle"},"热点人员",-1)),lt={class:"cnt"},ut={class:"model"},ct=W(()=>Object(i["createElementVNode"])("div",{class:"modelTitle"},"热点号码",-1)),ht={class:"cnt"},dt={class:"map"},ft=W(()=>Object(i["createElementVNode"])("ul",{class:"btns"},[Object(i["createElementVNode"])("li",null,[Object(i["createElementVNode"])("span",null,"热点集访单位")]),Object(i["createElementVNode"])("li",null,[Object(i["createElementVNode"])("span",null,"点位图")]),Object(i["createElementVNode"])("li",null,[Object(i["createElementVNode"])("span",null,"指令分布")])],-1)),pt={class:"contant-right aside"},gt={class:"model"},mt=W(()=>Object(i["createElementVNode"])("div",{class:"modelTitle"},"诉求分类",-1)),vt={class:"cnt"},yt={class:"model"},_t=W(()=>Object(i["createElementVNode"])("div",{class:"modelTitle"},"重点线索分类",-1)),bt={class:"cnt"},xt={class:"model"},wt=W(()=>Object(i["createElementVNode"])("div",{class:"modelTitle"},"指令次数",-1)),Ot={class:"cnt"};var St={__name:"index",emits:["close"],setup(t,{emit:e}){const{proxy:n}=Object(i["getCurrentInstance"])(),{SGXTQTSQLX:o}=n.$dict("SGXTQTSQLX"),s=Object(i["ref"])({}),l=Object(i["ref"])(-1),u=Object(i["reactive"])([{label:"今天",value:"10"},{label:"本周",value:"20"},{label:"本月",value:"30"},{label:"本季度",value:"40"},{label:"本年",value:"50"}]),c=Object(i["reactive"])([{label:"所属部门",prop:"ssbmdm",placeholder:"请选择",showType:"department"},{label:"数据周期",prop:"sjzq",placeholder:"请选择",showType:"defaultSlot"},{label:"指向地点",prop:"zxdz",placeholder:"请输入",showType:"input"},{label:"诉求类型",prop:"qtsq",placeholder:"请选择",showType:"select",options:o}]),h=Object(i["ref"])(),d=Object(i["ref"])(),p=Object(i["ref"])(),g=Object(i["ref"])(),m=Object(i["ref"])(),v=Object(i["ref"])(),_=Object(i["ref"])(),b=t=>{switch(l.value=t,t){case 0:s.value.dateRange=Object(r["d"])("天");break;case 1:s.value.dateRange=Object(r["d"])("本周");break;case 2:s.value.dateRange=Object(r["d"])("本月");break;case 3:s.value.dateRange=Object(r["d"])("本季度");break;case 4:s.value.dateRange=Object(r["d"])("本年");break}s.value.hskssj=s.value.dateRange[0]+" 00:00:00",s.value.hsjssj=s.value.dateRange[1]+" 23:59:59"},x=t=>{l.value=-1,t&&(s.value.hskssj=t[0]+" 00:00:00",s.value.hsjssj=t[1]+" 23:59:59",t[0]==Object(r["d"])("天")[0]&&t[1]==Object(r["d"])("天")[1]&&(l.value=0),t[0]==Object(r["d"])("本周")[0]&&t[1]==Object(r["d"])("本月")[1]&&(l.value=1),t[0]==Object(r["d"])("本月")[0]&&t[1]==Object(r["d"])("本月")[1]&&(l.value=2),t[0]==Object(r["d"])("本季度")[0]&&t[1]==Object(r["d"])("本季度")[1]&&(l.value=3),t[0]==Object(r["d"])("本年")[0]&&t[1]==Object(r["d"])("本年")[1]&&(l.value=4))},w=t=>{s.value={...s.value,...t},S()},O=t=>{s.value={},l.value=-1,s.value.dateRange="",s.value.hskssj="",s.value.hsjssj="",S()},S=()=>{h.value.init(s.value),d.value.init(s.value),p.value.init(s.value),g.value.init(s.value),m.value.init(s.value),v.value.init(s.value),_.value.init(s.value)};function M(){e("close")}return(t,e)=>{const n=Object(i["resolveComponent"])("Close"),r=Object(i["resolveComponent"])("el-icon"),o=Object(i["resolveComponent"])("el-date-picker");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",X,[Object(i["createElementVNode"])("div",Z,[q,Object(i["createElementVNode"])("span",{class:"pointer",onClick:M},[Object(i["createVNode"])(r,null,{default:Object(i["withCtx"])(()=>[Object(i["createVNode"])(n)]),_:1})])]),Object(i["createElementVNode"])("div",Y,[Object(i["createVNode"])(U["a"],{searchArr:c,onSubmit:w,onReset:O},{defaultSlot:Object(i["withCtx"])(()=>[Object(i["createElementVNode"])("div",K,[(Object(i["openBlock"])(!0),Object(i["createElementBlock"])(i["Fragment"],null,Object(i["renderList"])(u,(t,e)=>(Object(i["openBlock"])(),Object(i["createElementBlock"])("span",{class:Object(i["normalizeClass"])(["marks",l.value==e?"activeBtn":""]),onClick:t=>b(e),key:e},Object(i["toDisplayString"])(t.label),11,Q))),128)),Object(i["createVNode"])(o,{onChange:x,modelValue:s.value.dateRange,"onUpdate:modelValue":e[0]||(e[0]=t=>s.value.dateRange=t),type:"daterange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期",format:"YYYY-MM-DD","value-format":"YYYY-MM-DD"},null,8,["modelValue"])])]),_:1},8,["searchArr"])]),Object(i["createElementVNode"])("div",J,[Object(i["createElementVNode"])("div",$,[Object(i["createElementVNode"])("div",tt,[et,Object(i["createElementVNode"])("div",nt,[Object(i["createVNode"])(f,{ref_key:"RedRdxs",ref:h},null,512)])]),Object(i["createElementVNode"])("div",it,[rt,Object(i["createElementVNode"])("div",at,[Object(i["createVNode"])(y,{ref_key:"RedRdzz",ref:d},null,512)])]),Object(i["createElementVNode"])("div",ot,[st,Object(i["createElementVNode"])("div",lt,[Object(i["createVNode"])(T,{ref_key:"RedRdry",ref:p},null,512)])]),Object(i["createElementVNode"])("div",ut,[ct,Object(i["createElementVNode"])("div",ht,[Object(i["createVNode"])(I,{ref_key:"RedRdhm",ref:g},null,512)])])]),Object(i["createElementVNode"])("div",dt,[Object(i["createVNode"])(a["a"]),ft]),Object(i["createElementVNode"])("div",pt,[Object(i["createElementVNode"])("div",gt,[mt,Object(i["createElementVNode"])("div",vt,[Object(i["createVNode"])(P,{ref_key:"RedSqfl",ref:m},null,512)])]),Object(i["createElementVNode"])("div",yt,[_t,Object(i["createElementVNode"])("div",bt,[Object(i["createVNode"])(H,{ref_key:"RedZdxsfl",ref:_},null,512)])]),Object(i["createElementVNode"])("div",xt,[wt,Object(i["createElementVNode"])("div",Ot,[Object(i["createVNode"])(B,{ref_key:"RedZlcs",ref:v},null,512)])])])])])}}};n("cb94");const Tt=h()(St,[["__scopeId","data-v-4d577da3"]]);var Mt=Tt,At=n("2e9d"),Ct=n("1090"),It=n("7902"),Dt=n("1d22");const Lt=t=>(Object(i["pushScopeId"])("data-v-4df5353a"),t=t(),Object(i["popScopeId"])(),t),Et={key:0,class:"dialog"},jt={class:"head_box"},Pt=Lt(()=>Object(i["createElementVNode"])("span",{class:"title"},"人力情报信息采集流转详情",-1)),Nt=Object(i["createTextVNode"])("关闭"),Rt={class:"form_cnt"},kt={style:{width:"100%",height:"10px"},class:"mb20"},Bt=Object(i["createTextVNode"])("基础信息"),zt={style:{width:"100%",height:"10px"},class:"mb20"},Vt=Object(i["createTextVNode"])("线索内容"),Ft={style:{width:"100%","padding-left":"50px"}},Gt=Lt(()=>Object(i["createElementVNode"])("div",null,[Object(i["createTextVNode"])("上传附件:"),Object(i["createElementVNode"])("span",{class:"f12"},"(可附电子表格、Word文档、图像、音视频文件)")],-1)),Ht=Lt(()=>Object(i["createElementVNode"])("span",{class:"mr20"},"相关人员",-1)),Ut={key:0};var Wt={__name:"addForm",props:{dic:Object},emits:["change"],setup(t,{expose:e,emit:n}){const r=t,{proxy:a}=Object(i["getCurrentInstance"])(),l=Object(i["ref"])(!1),u=Object(i["reactive"])({xsMc:[{required:!0,message:"请输入线索名称",trigger:"blur"}],xlLx:[{required:!0,message:"请选择线索类型",trigger:"change"}],qbLy:[{required:!0,message:"请选择情报来源",trigger:"change"}]}),c=Object(i["ref"])([{prop:"gapdive",type:"slot",width:"100%"},{label:"线索名称",prop:"xsMc",type:"input"},{label:"线索类型",prop:"xlLx",type:"select",options:r.dic.D_GS_XS_LX},{label:"情报来源",prop:"qbLy",type:"select",options:r.dic.D_GS_XS_LY},{label:"指向开始时间",prop:"zxkssj",type:"datetime"},{label:"指向结束时间",prop:"zxjssj",type:"datetime"},{label:"指向地点",prop:"zxdz",type:"input"},{label:"所属专题",prop:"sszt",type:"select",options:r.dic.D_BZ_SSZT},{prop:"gapline",type:"slot",width:"100%"},{prop:"scfj",type:"slot",width:"100%"},{label:"线索内容",prop:"xsNr",type:"textarea",width:"100%"},{label:"群体类型",prop:"qtlx",type:"select",options:r.dic.D_GS_XS_QTLX},{label:"群体名称",prop:"qtmc",type:"input"},{label:"涉及人数",prop:"sjrs",type:"inputNumber"},{label:"线索报送单位",prop:"ssbmdm",type:"department"}]),h=Object(i["ref"])(),d=Object(i["ref"])({}),f=Object(i["ref"])(!1),p=Object(i["ref"])(),g=Object(i["ref"])(""),m=Object(i["reactive"])({tableData:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"checkBox",loading:!1,haveControls:!1},controlsWidth:220,tableColumn:[{label:"姓名",prop:"xm"},{label:"性别",prop:"xb",showSolt:!0},{label:"身份证号",prop:"sfzh"},{label:"户籍地",prop:"hjdz"},{label:"户籍地派出所",prop:"hjdpcs"},{label:"标签",prop:"bqList",showSolt:!0}]});Object(i["onMounted"])(()=>{b()});const v=(t,e)=>{h.value=[],b(),l.value=!0,g.value="add"==t?"新增":"info"==t?"详情":"编辑",e&&y(e.id)},y=t=>{Object(o["c"])({id:t},"/mosty-gsxt/qbcj/selectByid").then(t=>{h.value=t.ossList||[],d.value=t,m.tableData=t.ryList||[]})},_=()=>{h.value=[],d.value={},l.value=!1,f.value=!1},b=()=>{m.tableHeight=window.innerHeight-720,window.onresize=function(){b()}};return e({init:v}),(t,e)=>{const n=Object(i["resolveComponent"])("el-button"),a=Object(i["resolveComponent"])("el-divider"),o=Object(i["resolveComponent"])("DictTag"),f=Object(i["resolveComponent"])("el-tag");return l.value?(Object(i["openBlock"])(),Object(i["createElementBlock"])("div",Et,[Object(i["createElementVNode"])("div",jt,[Pt,Object(i["createElementVNode"])("div",null,[Object(i["createVNode"])(n,{onClick:_},{default:Object(i["withCtx"])(()=>[Nt]),_:1})])]),Object(i["createElementVNode"])("div",Rt,[Object(i["createVNode"])(Dt["a"],{disabled:"",modelValue:d.value,"onUpdate:modelValue":e[1]||(e[1]=t=>d.value=t),formList:c.value,ref_key:"elform",ref:p,rules:u},{gapdive:Object(i["withCtx"])(()=>[Object(i["createElementVNode"])("div",kt,[Object(i["createVNode"])(a,{"content-position":"left"},{default:Object(i["withCtx"])(()=>[Bt]),_:1})])]),gapline:Object(i["withCtx"])(()=>[Object(i["createElementVNode"])("div",zt,[Object(i["createVNode"])(a,{"content-position":"left"},{default:Object(i["withCtx"])(()=>[Vt]),_:1})])]),scfj:Object(i["withCtx"])(()=>[Object(i["createElementVNode"])("div",Ft,[Gt,Object(i["createVNode"])(It["n"],{showBtn:!0,isAll:!0,isImg:!1,limit:10,modelValue:h.value,"onUpdate:modelValue":e[0]||(e[0]=t=>h.value=t)},null,8,["modelValue"])])]),_:1},8,["modelValue","formList","rules"]),Object(i["createVNode"])(a,{"content-position":"left"},{default:Object(i["withCtx"])(()=>[Ht]),_:1}),(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:m.tableData,tableColumn:m.tableColumn,tableHeight:m.tableHeight,key:m.keyCount,tableConfiger:m.tableConfiger,controlsWidth:m.controlsWidth},{xb:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{value:t.xb,tag:!1,options:r.dic.D_BZ_XB},null,8,["value","options"])]),bqList:Object(i["withCtx"])(({row:t})=>[t.bqList?(Object(i["openBlock"])(),Object(i["createElementBlock"])("div",Ut,[(Object(i["openBlock"])(!0),Object(i["createElementBlock"])(i["Fragment"],null,Object(i["renderList"])(t.bqList,(t,e)=>(Object(i["openBlock"])(),Object(i["createBlock"])(f,{type:"success",key:e},{default:Object(i["withCtx"])(()=>[Object(i["createTextVNode"])(Object(i["toDisplayString"])(t.bqMc),1)]),_:2},1024))),128))])):Object(i["createCommentVNode"])("",!0)]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"]))])])):Object(i["createCommentVNode"])("",!0)}}};n("52c4");const Xt=h()(Wt,[["__scopeId","data-v-4df5353a"]]);var Zt=Xt,qt=n("6605");const Yt=t=>(Object(i["pushScopeId"])("data-v-3bb037b8"),t=t(),Object(i["popScopeId"])(),t),Kt={key:0,class:"dialog"},Qt={class:"head_box"},Jt=Yt(()=>Object(i["createElementVNode"])("span",{class:"title"},"转为指令",-1)),$t=Object(i["createTextVNode"])("保存"),te=Object(i["createTextVNode"])("关闭"),ee={class:"form_cnt"};var ne={__name:"zlForm",props:{dic:Object},emits:["updateDate"],setup(t,{expose:e,emit:n}){const r=t,a=Object(qt["d"])(),{proxy:s}=Object(i["getCurrentInstance"])(),l=Object(i["ref"])(!1),u=Object(i["reactive"])({zlbt:[{required:!0,message:"请输入指令标题",trigger:"blur"}],zllx:[{required:!0,message:"请选择指令类型",trigger:"change"}],zldj:[{required:!0,message:"请选择指令等级",trigger:"change"}],jssj:[{required:!0,message:"请选择反馈结束时间",trigger:"change"}],zllxr:[{required:!0,message:"请输入联系人",trigger:"blur"}],zllxdh:[{required:!0,message:"请输入联系电话",trigger:"blur"}],zsdw:[{required:!0,message:"请选择主送单位",trigger:"change"}],csdw:[{required:!0,message:"请选择抄送单位",trigger:"change"}],zlnr:[{required:!0,message:"请输入指令内容",trigger:"blur"}]}),c=Object(i["ref"])([{label:"线索名称",prop:"glxs",type:"input",disabled:!0},{label:"指令标题",prop:"zlbt",type:"input"},{label:"指令类型",prop:"zllx",type:"select",options:r.dic.D_GS_XS_ZLLX},{label:"指令等级",prop:"zldj",type:"select",options:r.dic.D_GS_ZDQT_FXDJ},{label:"反馈结束时间",prop:"jssj",type:"datetime"},{label:"联系人",prop:"zllxr",type:"input"},{label:"联系电话",prop:"zllxdh",type:"input"},{label:"主送单位",prop:"zsdw",type:"department"},{label:"抄送单位",prop:"csdw",type:"department"},{label:"指令内容",prop:"zlnr",type:"textarea",width:"100%"},{label:"附件",prop:"fjzd",type:"upload",width:"100%"}]),h=Object(i["ref"])({}),d=Object(i["ref"])(!1),f=Object(i["ref"])();Object(i["onMounted"])(()=>{});const p=t=>{h.value.fjzd=null,l.value=!0,h.value.glxs=t.xsMc,h.value.glxsid=t.id},g=()=>{f.value.submit(t=>{let e={...t};e.fjzd=e.fjzd?e.fjzd.join(","):"",d.value=!0,Object(o["d"])(e,"/mosty-gsxt/zlxx/add").then(t=>{d.value=!1,s.$message({type:"success",message:"转发成功"}),a.push("/InstructionInformation")}).catch(()=>{d.value=!1})})},m=()=>{h.value={},l.value=!1,d.value=!1};return e({init:p}),(t,e)=>{const n=Object(i["resolveComponent"])("el-button");return l.value?(Object(i["openBlock"])(),Object(i["createElementBlock"])("div",Kt,[Object(i["createElementVNode"])("div",Qt,[Jt,Object(i["createElementVNode"])("div",null,[Object(i["createVNode"])(n,{type:"primary",size:"small",loading:d.value,onClick:g},{default:Object(i["withCtx"])(()=>[$t]),_:1},8,["loading"]),Object(i["createVNode"])(n,{size:"small",onClick:m},{default:Object(i["withCtx"])(()=>[te]),_:1})])]),Object(i["createElementVNode"])("div",ee,[Object(i["createVNode"])(Dt["a"],{modelValue:h.value,"onUpdate:modelValue":e[0]||(e[0]=t=>h.value=t),formList:c.value,ref_key:"elform",ref:f,rules:u},null,8,["modelValue","formList","rules"])])])):Object(i["createCommentVNode"])("",!0)}}};n("5119");const ie=h()(ne,[["__scopeId","data-v-3bb037b8"]]);var re=ie;const ae={style:{width:"100%"}};var oe={__name:"hbDetail",props:{modelValue:{type:Boolean,default:!1},dic:{type:Object,default:{}},id:{type:String,default:""}},emits:["update:modelValue"],setup(t,{emit:e}){const n=t,r=Object(i["reactive"])({tableData:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"null",loading:!1,haveControls:!1},tableHeight:600,tableColumn:[{label:"线索编号",prop:"xsBh"},{label:"线索名称",prop:"xsMc"},{label:"线索来源",prop:"qbLy",showSolt:!0},{label:"开始时间",prop:"zxkssj"},{label:"截至时间",prop:"zxjssj"},{label:"指向地点",prop:"zxdz"},{label:"线索内容",prop:"xsNr"},{label:"群体类型",prop:"qtlx",showSolt:!0},{label:"群体名称",prop:"qtmc"},{label:"上报单位",prop:"ssbm"},{label:"上报时间",prop:"sxsbsj"},{label:"涉及人数",prop:"sjrs"},{label:"附件",prop:"fjdz",showSolt:!0},{label:"处置状态",prop:"czzt",showSolt:!0},{label:"状态",prop:"shzt",showSolt:!0}]}),a=()=>{r.tableConfiger.loading=!0,Object(o["c"])({hcxsid:n.id},"/mosty-gsxt/qbcj/getXshbXq").then(t=>{r.tableData=t||[],r.tableConfiger.loading=!1}).catch(()=>{r.tableConfiger.loading=!1})},l=()=>{r.tableData=[],e("update:modelValue",!1)};return Object(i["watch"])(()=>n.modelValue,t=>{t&&a()},{immediate:!0,deep:!0}),(e,a)=>{const o=Object(i["resolveComponent"])("DictTag"),u=Object(i["resolveComponent"])("el-dialog");return Object(i["openBlock"])(),Object(i["createBlock"])(u,{modelValue:t.modelValue,"onUpdate:modelValue":a[0]||(a[0]=t=>Object(i["isRef"])(modelValue)?modelValue.value=t:null),title:"合并详情",width:"1500px",onClose:l},{default:Object(i["withCtx"])(()=>[Object(i["createElementVNode"])("div",ae,[(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:r.tableData,tableColumn:r.tableColumn,tableHeight:r.tableHeight,key:r.keyCount,tableConfiger:r.tableConfiger,controlsWidth:r.controlsWidth},{xlLx:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.xlLx,options:n.dic.D_GS_XS_LX},null,8,["value","options"])]),qbLy:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.qbLy,options:n.dic.D_GS_XS_LY},null,8,["value","options"])]),czzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.czzt,options:n.dic.D_GS_XS_CZZT},null,8,["value","options"])]),shzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.shzt,options:n.dic.D_BZ_XSSHZT},null,8,["value","options"])]),qtlx:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.qtlx,options:n.dic.D_GS_XS_QTLX},null,8,["value","options"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"]))])]),_:1},8,["modelValue"])}}};const se=oe;var le=se;const ue=t=>(Object(i["pushScopeId"])("data-v-44bf595e"),t=t(),Object(i["popScopeId"])(),t),ce={key:0,class:"dialog"},he={class:"head_box"},de=ue(()=>Object(i["createElementVNode"])("span",{class:"title"},"线索合并",-1)),fe=Object(i["createTextVNode"])("关闭"),pe={class:"form_cnt"},ge={class:"top hh48"},me={class:"flex nowrap align-center"},ve=ue(()=>Object(i["createElementVNode"])("span",null,"所属部门:",-1)),ye={class:"ml20 mr10"},_e=Object(i["createTextVNode"])("数据周期:"),be=Object(i["createTextVNode"])("查询"),xe=Object(i["createTextVNode"])("重置"),we=ue(()=>Object(i["createElementVNode"])("h3",null,"串并线索",-1)),Oe=Object(i["createTextVNode"])("详情"),Se={class:"flex just-end"},Te={class:"bottom hh48"},Me=ue(()=>Object(i["createElementVNode"])("h3",null,"来源线索",-1)),Ae={class:"flex align-center mb10"},Ce=ue(()=>Object(i["createElementVNode"])("span",null,"线索标题:",-1)),Ie=Object(i["createTextVNode"])("查询"),De=Object(i["createTextVNode"])("自动合并"),Le=Object(i["createTextVNode"])("手动合并");var Ee={__name:"hbForm",props:{dic:Object},emits:["change"],setup(t,{expose:e,emit:n}){const a=t,l=Object(i["ref"])(!1),u=Object(i["ref"])(""),c=Object(i["ref"])("本周"),h=Object(i["ref"])(["本周","本月","本季度","本年"]),{proxy:d}=Object(i["getCurrentInstance"])(),f=Object(i["ref"])(!1),p=Object(i["ref"])([]),g=Object(i["ref"])({times:Object(r["d"])("本周")}),m=Object(i["ref"])(""),v=Object(i["ref"])(!1),y=Object(i["reactive"])({tableData_hbh:[],tableData_hbq:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"checkBox",loading:!1,haveControls:!1},tableConfiger1:{rowHieght:61,showSelectType:"null",loading:!1},controlsWidth:100,tableColumn:[{label:"线索编号",prop:"xsBh"},{label:"线索名称",prop:"xsMc"},{label:"线索来源",prop:"qbLy",showSolt:!0},{label:"开始时间",prop:"zxkssj"},{label:"截至时间",prop:"zxjssj"},{label:"指向地点",prop:"zxdz"},{label:"线索内容",prop:"xsNr"},{label:"群体类型",prop:"qtlx",showSolt:!0},{label:"群体名称",prop:"qtmc"},{label:"上报单位",prop:"ssbm"},{label:"上报时间",prop:"sxsbsj"},{label:"涉及人数",prop:"sjrs"},{label:"附件",prop:"fjdz",showSolt:!0},{label:"处置状态",prop:"czzt",showSolt:!0},{label:"状态",prop:"shzt",showSolt:!0}]}),_=Object(i["reactive"])({pageCurrent:1,pageSize:10,total:0});Object(i["onMounted"])(()=>{j()});const b=()=>{f.value=!0,x(),M(),j()},x=()=>{Object(o["c"])({xsMc:m.value},"/mosty-gsxt/qbcj/getXshbFxcx").then(t=>{y.tableData_hbq=t||[]})},w=()=>{d.$confirm("是否确定要合并?","警告",{type:"warning"}).then(()=>{Object(o["d"])({xsMc:m.value},"/mosty-gsxt/qbcj/getXshbZdhb").then(t=>{d.$message({type:"success",message:"合并成功"}),x(),M()})})},O=()=>{if(p.value.length<2)return d.$message({type:"warning",message:"请先选择需要合并的数据,并且至少选择 2 条数据。"});d.$confirm("是否确定要合并?","警告",{type:"warning"}).then(()=>{Object(o["d"])(p.value,"/mosty-gsxt/qbcj/getXshbSdhb").then(t=>{d.$message({type:"success",message:"合并成功"}),x(),M()})})},S=()=>{c.value="本周",g.value={times:Object(r["d"])("本周")},_.pageCurrent=1,M()},T=()=>{_.pageCurrent=1,M()},M=()=>{let t={sfhb:1,..._,...g.value};t.times&&t.times.length>0&&(t.startTime=g.value.times[0],t.endTime=g.value.times[1]),delete t.times,y.tableConfiger.tableConfiger1=!0,Object(o["c"])(t,"/mosty-gsxt/qbcj/selectPage").then(t=>{console.log(t),y.tableConfiger.tableConfiger1=!1,y.tableData_hbh=t.records||[],_.total=t.total}).catch(()=>{y.tableConfiger.tableConfiger1=!1})},A=t=>{u.value=t.id,l.value=!0},C=t=>{_.pageCurrent=t,M()},I=t=>{_.pageSize=t,M()},D=t=>{switch(c.value=t,t){case"本周":g.value.times=Object(r["d"])("本周");break;case"本月":g.value.times=Object(r["d"])("本月");break;case"本季度":g.value.times=Object(r["d"])("本季度");break;case"本年":g.value.times=Object(r["d"])("本年");break}},L=t=>{Array.isArray(t)&&(p.value=t.map(t=>t.id))},E=()=>{c.value="本周",g.value={times:Object(r["d"])("本周")},m.value="",p.value=[],_.pageCurrent=1,f.value=!1,v.value=!1},j=()=>{y.tableHeight=window.innerHeight-660,y.tableHeight1=window.innerHeight-695,window.onresize=function(){j()}};return e({init:b}),(t,e)=>{const n=Object(i["resolveComponent"])("el-button"),r=Object(i["resolveComponent"])("el-date-picker"),o=Object(i["resolveComponent"])("DictTag"),d=Object(i["resolveComponent"])("el-link"),p=Object(i["resolveComponent"])("el-input");return Object(i["openBlock"])(),Object(i["createElementBlock"])(i["Fragment"],null,[f.value?(Object(i["openBlock"])(),Object(i["createElementBlock"])("div",ce,[Object(i["createElementVNode"])("div",he,[de,Object(i["createVNode"])(n,{onClick:E},{default:Object(i["withCtx"])(()=>[fe]),_:1})]),Object(i["createElementVNode"])("div",pe,[Object(i["createElementVNode"])("div",ge,[Object(i["createElementVNode"])("div",me,[ve,Object(i["createVNode"])(It["c"],{width:"300px",clearable:"",modelValue:g.value.ssbmdm,"onUpdate:modelValue":e[0]||(e[0]=t=>g.value.ssbmdm=t)},null,8,["modelValue"]),Object(i["createElementVNode"])("div",ye,[_e,(Object(i["openBlock"])(!0),Object(i["createElementBlock"])(i["Fragment"],null,Object(i["renderList"])(h.value,t=>(Object(i["openBlock"])(),Object(i["createBlock"])(n,{onClick:e=>D(t),key:t,type:c.value==t?"primary":"",size:"small"},{default:Object(i["withCtx"])(()=>[Object(i["createTextVNode"])(Object(i["toDisplayString"])(t),1)]),_:2},1032,["onClick","type"]))),128))]),Object(i["createVNode"])(r,{modelValue:g.value.times,"onUpdate:modelValue":e[1]||(e[1]=t=>g.value.times=t),type:"daterange","range-separator":"To","value-format":"YYYY-MM-DD","start-placeholder":"选择开始时间","end-placeholder":"选择结束时间"},null,8,["modelValue"]),Object(i["createVNode"])(n,{class:"ml10 mr20",type:"primary",size:"small",onClick:T},{default:Object(i["withCtx"])(()=>[be]),_:1}),Object(i["createVNode"])(n,{type:"primary",size:"small",onClick:S},{default:Object(i["withCtx"])(()=>[xe]),_:1})]),we,(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:y.tableData_hbh,tableColumn:y.tableColumn,tableHeight:y.tableHeight1,key:y.keyCount,tableConfiger:y.tableConfiger1,controlsWidth:y.controlsWidth},{xlLx:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.xlLx,options:a.dic.D_GS_XS_LX},null,8,["value","options"])]),qbLy:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.qbLy,options:a.dic.D_GS_XS_LY},null,8,["value","options"])]),czzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.czzt,options:a.dic.D_GS_XS_CZZT},null,8,["value","options"])]),shzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.shzt,options:a.dic.D_BZ_XSSHZT},null,8,["value","options"])]),qtlx:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.qtlx,options:a.dic.D_GS_XS_QTLX},null,8,["value","options"])]),controls:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(d,{size:"small",type:"primary",onClick:e=>A(t)},{default:Object(i["withCtx"])(()=>[Oe]),_:2},1032,["onClick"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"])),Object(i["createElementVNode"])("div",Se,[Object(i["createVNode"])(Ct["a"],{onChangeNo:C,onChangeSize:I,tableHeight:y.tableHeight1,pageConfiger:{..._}},null,8,["tableHeight","pageConfiger"])])]),Object(i["createElementVNode"])("div",Te,[Me,Object(i["createElementVNode"])("div",Ae,[Ce,Object(i["createVNode"])(p,{style:{width:"300px"},placeholder:"请输入标题",clearable:"",modelValue:m.value,"onUpdate:modelValue":e[2]||(e[2]=t=>m.value=t)},null,8,["modelValue"]),Object(i["createVNode"])(n,{class:"ml10 mr20",type:"primary",size:"small"},{default:Object(i["withCtx"])(()=>[Ie]),_:1}),Object(i["createVNode"])(n,{class:"mr10",type:"primary",size:"small",onClick:w},{default:Object(i["withCtx"])(()=>[De]),_:1}),Object(i["createVNode"])(n,{type:"primary",size:"small",onClick:O},{default:Object(i["withCtx"])(()=>[Le]),_:1})]),(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:y.tableData_hbq,tableColumn:y.tableColumn,tableHeight:y.tableHeight,key:y.keyCount,tableConfiger:y.tableConfiger,controlsWidth:y.controlsWidth,onChooseData:L},{xlLx:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.xlLx,options:a.dic.D_GS_XS_LX},null,8,["value","options"])]),qbLy:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.qbLy,options:a.dic.D_GS_XS_LY},null,8,["value","options"])]),czzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.czzt,options:a.dic.D_GS_XS_CZZT},null,8,["value","options"])]),shzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.shzt,options:a.dic.D_BZ_XSSHZT},null,8,["value","options"])]),qtlx:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(o,{tag:!1,value:t.qtlx,options:a.dic.D_GS_XS_QTLX},null,8,["value","options"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"]))])])])):Object(i["createCommentVNode"])("",!0),Object(i["createVNode"])(le,{modelValue:l.value,"onUpdate:modelValue":e[3]||(e[3]=t=>l.value=t),id:u.value},null,8,["modelValue","id"])],64)}}};n("3985");const je=h()(Ee,[["__scopeId","data-v-44bf595e"]]);var Pe=je;const Ne={class:"titleBox"},Re=Object(i["createTextVNode"])("情报研判分析"),ke=Object(i["createTextVNode"])("线索串联"),Be={class:"tabBox"},ze=Object(i["createTextVNode"])(" 至 "),Ve=Object(i["createTextVNode"])("转为指令"),Fe=Object(i["createTextVNode"])("详情");var Ge={__name:"index",setup(t){const{proxy:e}=Object(i["getCurrentInstance"])(),{D_GS_ZDQT_FXDJ:n,D_GS_XS_ZLLX:r,D_GS_XS_CZZT:a,D_GS_XS_LY:l,D_BZ_SSZT:u,D_BZ_SF:c,D_GS_XS_LX:h,D_GS_XS_QTLX:d,D_BZ_XB:f,D_BZ_XSSHZT:p}=e.$dict("D_GS_ZDQT_FXDJ","D_GS_XS_ZLLX","D_GS_XS_CZZT","D_GS_XS_LY","D_BZ_SSZT","D_BZ_SF","D_GS_XS_LX","D_GS_XS_QTLX","D_BZ_XB","D_BZ_XSSHZT"),g=Object(i["ref"])(),m=Object(i["ref"])(),v=Object(i["ref"])(!1),y=Object(i["ref"])(!1),_=Object(i["ref"])(!1),b=Object(i["ref"])(),x=Object(i["ref"])([{label:"线索名称",prop:"xsMc",placeholder:"请输入线索名称",showType:"input"},{label:"内容关键字",prop:"xsNr",placeholder:"请输入语义关键字",showType:"input"},{label:"线索类型",prop:"xlLx",placeholder:"请选择线索类型",showType:"select",options:h},{label:"线索来源",prop:"qbLy",placeholder:"请选择线索来源",showType:"select",options:l},{label:"指向地点",prop:"zxdz",placeholder:"请输入指向地点",showType:"input"}]),w=Object(i["reactive"])({tableData:[],keyCount:0,tableConfiger:{rowHieght:61,showSelectType:"checkBox",loading:!1},total:0,pageConfiger:{pageSize:20,pageCurrent:1},controlsWidth:150,tableColumn:[{label:"线索编号",prop:"xsBh"},{label:"线索名称",prop:"xsMc"},{label:"线索类型",prop:"xlLx",showSolt:!0},{label:"线索来源",prop:"qbLy",showSolt:!0},{label:"指向时间",prop:"zxkssj",showSolt:!0,showOverflowTooltip:!0},{label:"上报时间",prop:"sxsbsj",showOverflowTooltip:!0},{label:"指向地点",prop:"zxdz"},{label:"线索内容",prop:"xsNr",showOverflowTooltip:!0},{label:"处置状态",prop:"czzt",showSolt:!0},{label:"附件",prop:"fjdz",showSolt:!0},{label:"审核状态",prop:"shzt",showSolt:!0}]}),O=Object(i["ref"])({});Object(i["onMounted"])(()=>{A(),L()});const S=t=>{O.value={...t},w.pageConfiger.pageCurrent=1,A()},T=t=>{w.pageConfiger.pageCurrent=t,A()},M=t=>{w.pageConfiger.pageSize=t,A()},A=()=>{w.tableConfiger.loading=!0;let t={...w.pageConfiger,...O.value};Object(o["c"])(t,"/mosty-gsxt/qbcj/selectPage").then(t=>{w.tableData=t.records||[],w.total=t.total,w.tableConfiger.loading=!1}).catch(()=>{w.tableConfiger.loading=!1})},C=t=>{v.value=!0,setTimeout(()=>{_.value.init(t)},500)},I=(t,e)=>{v.value=!0,setTimeout(()=>{g.value.init(t,e)},500)},D=()=>{b.value.init()},L=()=>{w.tableHeight=window.innerHeight-m.value.offsetHeight-250,window.onresize=function(){L()}};return(t,e)=>{const o=Object(i["resolveComponent"])("el-button"),O=Object(i["resolveComponent"])("DictTag"),A=Object(i["resolveComponent"])("el-link");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",null,[Object(i["createElementVNode"])("div",Ne,[Object(i["createVNode"])(At["a"],{title:"人力情报信息采集流转"},{default:Object(i["withCtx"])(()=>[Object(i["createVNode"])(o,{type:"primary",onClick:e[0]||(e[0]=t=>y.value=!0)},{default:Object(i["withCtx"])(()=>[Re]),_:1}),Object(i["createVNode"])(o,{type:"primary",onClick:D},{default:Object(i["withCtx"])(()=>[ke]),_:1})]),_:1})]),Object(i["createElementVNode"])("div",{ref_key:"searchBox",ref:m},[(Object(i["openBlock"])(),Object(i["createBlock"])(U["a"],{searchArr:x.value,onSubmit:S,key:w.keyCount},null,8,["searchArr"]))],512),Object(i["createElementVNode"])("div",Be,[(Object(i["openBlock"])(),Object(i["createBlock"])(s["a"],{tableData:w.tableData,tableColumn:w.tableColumn,tableHeight:w.tableHeight,key:w.keyCount,tableConfiger:w.tableConfiger,controlsWidth:w.controlsWidth},{xlLx:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(O,{tag:!1,value:t.xlLx,options:Object(i["unref"])(h)},null,8,["value","options"])]),qbLy:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(O,{tag:!1,value:t.qbLy,options:Object(i["unref"])(l)},null,8,["value","options"])]),czzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(O,{tag:!1,value:t.czzt,options:Object(i["unref"])(a)},null,8,["value","options"])]),shzt:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(O,{tag:!1,value:t.shzt,options:Object(i["unref"])(p)},null,8,["value","options"])]),zxkssj:Object(i["withCtx"])(({row:t})=>[Object(i["createElementVNode"])("span",null,Object(i["toDisplayString"])(t.zxkssj),1),ze,Object(i["createElementVNode"])("span",null,Object(i["toDisplayString"])(t.zxjssj),1)]),controls:Object(i["withCtx"])(({row:t})=>[Object(i["createVNode"])(A,{size:"small",type:"primary",onClick:e=>C(t)},{default:Object(i["withCtx"])(()=>[Ve]),_:2},1032,["onClick"]),Object(i["createVNode"])(A,{size:"small",type:"primary",onClick:e=>I("detail",t)},{default:Object(i["withCtx"])(()=>[Fe]),_:2},1032,["onClick"])]),_:1},8,["tableData","tableColumn","tableHeight","tableConfiger","controlsWidth"])),Object(i["createVNode"])(Ct["a"],{onChangeNo:T,onChangeSize:M,tableHeight:w.tableHeight,pageConfiger:{...w.pageConfiger,total:w.total}},null,8,["tableHeight","pageConfiger"])]),v.value?(Object(i["openBlock"])(),Object(i["createBlock"])(Zt,{key:0,ref_key:"detailDiloag",ref:g,dic:{D_BZ_SF:Object(i["unref"])(c),D_BZ_XB:Object(i["unref"])(f),D_GS_XS_LY:Object(i["unref"])(l),D_BZ_SSZT:Object(i["unref"])(u),D_GS_XS_LX:Object(i["unref"])(h),D_GS_XS_QTLX:Object(i["unref"])(d)}},null,8,["dic"])):Object(i["createCommentVNode"])("",!0),v.value?(Object(i["openBlock"])(),Object(i["createBlock"])(re,{key:1,ref_key:"zlDialog",ref:_,dic:{D_GS_XS_ZLLX:Object(i["unref"])(r),D_GS_ZDQT_FXDJ:Object(i["unref"])(n)}},null,8,["dic"])):Object(i["createCommentVNode"])("",!0),Object(i["createVNode"])(Pe,{ref_key:"isShowhB",ref:b,dic:{D_GS_XS_LX:Object(i["unref"])(h),D_GS_XS_LY:Object(i["unref"])(l),D_GS_XS_CZZT:Object(i["unref"])(a),D_BZ_XSSHZT:Object(i["unref"])(p),D_GS_XS_QTLX:Object(i["unref"])(d)}},null,8,["dic"]),(Object(i["openBlock"])(),Object(i["createBlock"])(i["Teleport"],{to:"#app"},[y.value?(Object(i["openBlock"])(),Object(i["createBlock"])(Mt,{key:0,onClose:e[1]||(e[1]=t=>y.value=!1)})):Object(i["createCommentVNode"])("",!0)]))])}}};n("806c");const He=Ge;e["default"]=He},"998a":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("76a5");function r(t,e,n,r,a,o,s,l){var u=new i["a"]({style:{text:t,font:e,align:n,verticalAlign:r,padding:a,rich:o,overflow:s?"truncate":null,lineHeight:l}});return u.getBoundingRect()}},"9a7f":function(t,e,n){},"9c28":function(t,e,n){"use strict";n("bff8")},"9cf9":function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return o}));var i=Math.round;function r(t,e,n){if(e){var r=e.x1,a=e.x2,s=e.y1,l=e.y2;t.x1=r,t.x2=a,t.y1=s,t.y2=l;var u=n&&n.lineWidth;return u?(i(2*r)===i(2*a)&&(t.x1=t.x2=o(r,u,!0)),i(2*s)===i(2*l)&&(t.y1=t.y2=o(s,u,!0)),t):t}}function a(t,e,n){if(e){var i=e.x,r=e.y,a=e.width,s=e.height;t.x=i,t.y=r,t.width=a,t.height=s;var l=n&&n.lineWidth;return l?(t.x=o(i,l,!0),t.y=o(r,l,!0),t.width=Math.max(o(i+a,l,!1)-t.x,0===a?0:1),t.height=Math.max(o(r+s,l,!1)-t.y,0===s?0:1),t):t}}function o(t,e,n){if(!e)return t;var r=i(2*t);return(r+i(e))%2===0?r/2:(r+(n?1:-1))/2}},"9d57":function(t,e,n){"use strict";n.d(e,"b",(function(){return h})),n.d(e,"e",(function(){return d})),n.d(e,"d",(function(){return p})),n.d(e,"f",(function(){return m})),n.d(e,"c",(function(){return v})),n.d(e,"a",(function(){return y}));var i=n("6d8b"),r=n("3842"),a=n("ee1a"),o=n("cccd"),s=n("f658"),l="__ec_stack_";function u(t){return t.get("stack")||l+t.seriesIndex}function c(t){return t.dim+t.index}function h(t){var e=[],n=t.axis,r="axis0";if("category"===n.type){for(var a=n.getBandWidth(),o=0;o0&&(o=null===o?l:Math.min(o,l))}n[r]=o}}return n}function p(t){var e=f(t),n=[];return Object(i["k"])(t,(function(t){var i,a=t.coordinateSystem,o=a.getBaseAxis(),s=o.getExtent();if("category"===o.type)i=o.getBandWidth();else if("value"===o.type||"time"===o.type){var l=o.dim+"_"+o.index,h=e[l],d=Math.abs(s[1]-s[0]),f=o.scale.getExtent(),p=Math.abs(f[1]-f[0]);i=h?d/p*h:d}else{var g=t.getData();i=Math.abs(s[1]-s[0])/g.count()}var m=Object(r["p"])(t.get("barWidth"),i),v=Object(r["p"])(t.get("barMaxWidth"),i),y=Object(r["p"])(t.get("barMinWidth")||(b(t)?.5:1),i),_=t.get("barGap"),x=t.get("barCategoryGap");n.push({bandWidth:i,barWidth:m,barMaxWidth:v,barMinWidth:y,barGap:_,barCategoryGap:x,axisKey:c(o),stackId:u(t)})})),g(n)}function g(t){var e={};Object(i["k"])(t,(function(t,n){var i=t.axisKey,r=t.bandWidth,a=e[i]||{bandWidth:r,remainedWidth:r,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},o=a.stacks;e[i]=a;var s=t.stackId;o[s]||a.autoWidthCount++,o[s]=o[s]||{width:0,maxWidth:0};var l=t.barWidth;l&&!o[s].width&&(o[s].width=l,l=Math.min(a.remainedWidth,l),a.remainedWidth-=l);var u=t.barMaxWidth;u&&(o[s].maxWidth=u);var c=t.barMinWidth;c&&(o[s].minWidth=c);var h=t.barGap;null!=h&&(a.gap=h);var d=t.barCategoryGap;null!=d&&(a.categoryGap=d)}));var n={};return Object(i["k"])(e,(function(t,e){n[e]={};var a=t.stacks,o=t.bandWidth,s=t.categoryGap;if(null==s){var l=Object(i["F"])(a).length;s=Math.max(35-4*l,15)+"%"}var u=Object(r["p"])(s,o),c=Object(r["p"])(t.gap,1),h=t.remainedWidth,d=t.autoWidthCount,f=(h-u)/(d+(d-1)*c);f=Math.max(f,0),Object(i["k"])(a,(function(t){var e=t.maxWidth,n=t.minWidth;if(t.width){i=t.width;e&&(i=Math.min(i,e)),n&&(i=Math.max(i,n)),t.width=i,h-=i+c*i,d--}else{var i=f;e&&ei&&(i=n),i!==f&&(t.width=i,h-=i+c*i,d--)}})),f=(h-u)/(d+(d-1)*c),f=Math.max(f,0);var p,g=0;Object(i["k"])(a,(function(t,e){t.width||(t.width=f),p=t,g+=t.width*(1+c)})),p&&(g-=p.width*c);var m=-g/2;Object(i["k"])(a,(function(t,i){n[e][i]=n[e][i]||{bandWidth:o,offset:m,width:t.width},m+=t.width*(1+c)}))})),n}function m(t,e,n){if(t&&e){var i=t[c(e)];return null!=i&&null!=n?i[u(n)]:i}}function v(t,e){var n=d(t,e),r=p(n);Object(i["k"])(n,(function(t){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),a=u(t),o=r[c(i)][a],s=o.offset,l=o.width;e.setLayout({bandWidth:o.bandWidth,offset:s,size:l})}))}function y(t){return{seriesType:t,plan:Object(o["a"])(),reset:function(t){if(_(t)){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),r=n.getOtherAxis(i),o=e.getDimensionIndex(e.mapDimension(r.dim)),l=e.getDimensionIndex(e.mapDimension(i.dim)),u=t.get("showBackground",!0),c=e.mapDimension(r.dim),h=e.getCalculationInfo("stackResultDimension"),d=Object(a["c"])(e,c)&&!!e.getCalculationInfo("stackedOnSeries"),f=r.isHorizontal(),p=x(i,r),g=b(t),m=t.get("barMinHeight")||0,v=h&&e.getDimensionIndex(h),y=e.getLayout("size"),w=e.getLayout("offset");return{progress:function(t,e){var i,r=t.count,a=g&&Object(s["a"])(3*r),c=g&&u&&Object(s["a"])(3*r),h=g&&Object(s["a"])(r),_=n.master.getRect(),b=f?_.width:_.height,x=e.getStore(),O=0;while(null!=(i=t.next())){var S=x.get(d?v:o,i),T=x.get(l,i),M=p,A=void 0;d&&(A=+S-x.get(o,i));var C=void 0,I=void 0,D=void 0,L=void 0;if(f){var E=n.dataToPoint([S,T]);if(d){var j=n.dataToPoint([A,T]);M=j[0]}C=M,I=E[1]+w,D=E[0]-M,L=y,Math.abs(D)=1)&&(t=1),t}s===u&&l===c||(e="reset"),(this._dirty||"reset"===e)&&(this._dirty=!1,o=this._doReset(r)),this._modBy=u,this._modDataCount=c;var d=t&&t.step;if(this._dueEnd=n?n._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var f=this._dueIndex,p=Math.min(null!=d?this._dueIndex+d:1/0,this._dueEnd);if(!r&&(o||f1&&i>0?s:o}};return a;function o(){return e=t?null:a{}},tableData:{type:Array,default:()=>[]},tableColumn:{type:Array,default:()=>[]},controlsWidth:{type:Number,default:180},tableHeight:{type:Number||String},treePros:{type:Object,default:{children:"children",hasChildren:"hasChildren"}},fixed:{type:String,default:"right"}},emits:["chooseData"],setup(t,{emit:e}){const n=t,r=Object(i["ref"])(),a=Object(i["ref"])();let o=Object(i["reactive"])({showSelectType:null,showIndex:!0,rowKey:null,border:!0,defaultExpandAll:!1,loading:!1,align:"center",haveControls:!0,controls:"操作",stripe:!1,lazy:!0,portUrl:"",defaultSelectKeys:[],radioChoose:"",rowHeight:"41"});Object(i["watchEffect"])(()=>{o={...o,...n.tableConfiger},u()}),Object(i["onMounted"])(()=>{u()});const s=t=>{if("radio"===o.showSelectType&&t.length>1){let n=t.shift();r.value.toggleRowSelection(n,!1),a.value=t,e("chooseData",t)}else e("chooseData",t)},l=(t,e,n)=>{setTimeout(()=>{n([{id:31,date:"2016-05-01",name:"wangxiaohu",address:"No. 189, Grove St, Los Angeles"},{id:32,date:"2016-05-01",name:"wangxiaohu",address:"No. 189, Grove St, Los Angeles"}])},1e3)};function u(){Object(i["nextTick"])(()=>{var t,e;(null===(t=n.tableConfiger.defaultSelectKeys)||void 0===t?void 0:t.length)>0&&"checkBox"===n.tableConfiger.showSelectType?n.tableData.forEach(t=>{n.tableConfiger.defaultSelectKeys.findIndex(e=>e===t[n.tableConfiger.rowKey])>-1&&r.value.toggleRowSelection(t,!0)}):n.tableConfiger.defaultSelectKeys&&(null===(e=n.tableConfiger.defaultSelectKeys)||void 0===e?void 0:e.length)>0&&"radio"===n.tableConfiger.showSelectType&&(o.radioChoose=n.tableConfiger.defaultSelectKeys[0])})}return(e,n)=>{const a=Object(i["resolveComponent"])("el-table-column"),u=Object(i["resolveComponent"])("el-table"),c=Object(i["resolveDirective"])("loading");return Object(i["openBlock"])(),Object(i["createElementBlock"])("div",{style:{width:"100%"},class:Object(i["normalizeClass"])("radio"===Object(i["unref"])(o).showSelectType?"tabBoxRadio":"")},[Object(i["withDirectives"])((Object(i["openBlock"])(),Object(i["createBlock"])(u,{ref_key:"multipleTableRef",ref:r,data:t.tableData,onSelectionChange:s,"row-key":Object(i["unref"])(o).rowKey,border:Object(i["unref"])(o).border,"default-expand-all":Object(i["unref"])(o).defaultExpandAll,stripe:Object(i["unref"])(o).stripe,height:t.tableHeight,lazy:Object(i["unref"])(o).lazy,load:l,"tree-props":t.treePros,style:{width:"100%"},"header-cell-class-name":()=>"HeadBgColor","highlight-current-row":"radio"===Object(i["unref"])(o).showSelectType,"row-style":{height:"auto"===Object(i["unref"])(o).rowHeight?Object(i["unref"])(o).rowHeight:Object(i["unref"])(o).rowHeight+"px"}},{default:Object(i["withCtx"])(()=>{var n,r;return[Object(i["createVNode"])(a,{type:"selection",width:"55"}),Object(i["unref"])(o).showIndex?(Object(i["openBlock"])(),Object(i["createBlock"])(a,{key:0,type:"index",label:"序号",width:"60",align:null===(n=Object(i["unref"])(o))||void 0===n?void 0:n.align},null,8,["align"])):Object(i["createCommentVNode"])("",!0),(Object(i["openBlock"])(!0),Object(i["createElementBlock"])(i["Fragment"],null,Object(i["renderList"])(t.tableColumn,(t,n)=>{var r;return Object(i["openBlock"])(),Object(i["createBlock"])(a,{align:null===(r=Object(i["unref"])(o))||void 0===r?void 0:r.align,prop:t.prop,key:n,label:t.label,width:t.width,style:{width:"100%","font-size":"14px"},"show-overflow-tooltip":t.showOverflowTooltip||!1,sortable:t.sortable||!1},Object(i["createSlots"])({_:2},[t.showSolt?{name:"default",fn:Object(i["withCtx"])(n=>[Object(i["renderSlot"])(e.$slots,t.prop,Object(i["normalizeProps"])(Object(i["guardReactiveProps"])(n)))])}:{name:"default",fn:Object(i["withCtx"])(({row:e})=>[Object(i["createTextVNode"])(Object(i["toDisplayString"])(e[t.prop]),1)])}]),1032,["align","prop","label","width","show-overflow-tooltip","sortable"])}),128)),Object(i["unref"])(o).haveControls?(Object(i["openBlock"])(),Object(i["createBlock"])(a,{key:1,fixed:t.fixed,label:Object(i["unref"])(o).controls,width:t.controlsWidth,align:null===(r=Object(i["unref"])(o))||void 0===r?void 0:r.align},{default:Object(i["withCtx"])(t=>[Object(i["renderSlot"])(e.$slots,"controls",Object(i["normalizeProps"])(Object(i["guardReactiveProps"])(t)))]),_:3},8,["fixed","label","width","align"])):Object(i["createCommentVNode"])("",!0)]}),_:3},8,["data","row-key","border","default-expand-all","stripe","height","lazy","tree-props","header-cell-class-name","highlight-current-row","row-style"])),[[c,t.tableConfiger.loading]])],2)}}};n("47fe");const a=r;e["a"]=a},ae69:function(t,e,n){"use strict";var i=n("21a10"),r=n("cbe5"),a=function(){function t(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return t}(),o=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype.getDefaultShape=function(){return new a},e.prototype.buildPath=function(t,e){var n=.5522848,i=e.cx,r=e.cy,a=e.rx,o=e.ry,s=a*n,l=o*n;t.moveTo(i-a,r),t.bezierCurveTo(i-a,r-l,i-s,r-o,i,r-o),t.bezierCurveTo(i+s,r-o,i+a,r-l,i+a,r),t.bezierCurveTo(i+a,r+l,i+s,r+o,i,r+o),t.bezierCurveTo(i-s,r+o,i-a,r+l,i-a,r),t.closePath()},e}(r["b"]);o.prototype.type="ellipse",e["a"]=o},b12f:function(t,e,n){"use strict";var i=n("2dc5"),r=n("8918"),a=n("625e"),o=function(){function t(){this.group=new i["a"],this.uid=r["c"]("viewComponent")}return t.prototype.init=function(t,e){},t.prototype.render=function(t,e,n,i){},t.prototype.dispose=function(t,e){},t.prototype.updateView=function(t,e,n,i){},t.prototype.updateLayout=function(t,e,n,i){},t.prototype.updateVisual=function(t,e,n,i){},t.prototype.toggleBlurSeries=function(t,e,n){},t.prototype.eachRendered=function(t){var e=this.group;e&&e.traverse(t)},t}();a["b"](o),a["c"](o),e["a"]=o},b1d4:function(t,e,n){"use strict";n.d(e,"a",(function(){return h})),n.d(e,"b",(function(){return d}));var i=n("07fd"),r=n("cd70"),a=n("6d8b"),o=n("ec6f"),s=n("d0ce"),l=n("e0d3"),u=n("0f99"),c=n("80b9");function h(t,e){return d(t,e).dimensions}function d(t,e){Object(o["e"])(t)||(t=Object(o["c"])(t)),e=e||{};var n=e.coordDimensions||[],h=e.dimensionsDefine||t.dimensionsDefine||[],d=Object(a["f"])(),m=[],v=p(t,n,h,e.dimensionsCount),y=e.canOmitUnusedDimensions&&Object(c["e"])(v),_=h===t.dimensionsDefine,b=_?Object(c["c"])(t):Object(c["b"])(h),x=e.encodeDefine;!x&&e.encodeDefaulter&&(x=e.encodeDefaulter(t,v));for(var w=Object(a["f"])(x),O=new s["a"](v),S=0;S0&&(i.name=r+(o-1)),o++,e.set(r,o)}}function p(t,e,n,i){var r=Math.max(t.dimensionsDetectedCount||1,e.length,n.length,i||0);return Object(a["k"])(e,(function(t){var e;Object(a["A"])(t)&&(e=t.dimsDef)&&(r=Math.max(r,e.length))})),r}function g(t,e,n){var i=e.data;if(n||i.hasOwnProperty(t)){var r=0;while(i.hasOwnProperty(t+r))r++;t+=r}return e.set(t,!0),t}},b362:function(t,e,n){"use strict";n.d(e,"a",(function(){return o}));var i=n("4a3f"),r=n("6d8b"),a=/cubic-bezier\(([0-9,\.e ]+)\)/;function o(t){var e=t&&a.exec(t);if(e){var n=e[1].split(","),o=+Object(r["T"])(n[0]),s=+Object(r["T"])(n[1]),l=+Object(r["T"])(n[2]),u=+Object(r["T"])(n[3]);if(isNaN(o+s+l+u))return;var c=[];return function(t){return t<=0?0:t>=1?1:Object(i["f"])(0,o,l,1,t,c)&&Object(i["a"])(0,s,u,1,c[0])}}}},b3c1:function(t,e,n){"use strict";n.d(e,"a",(function(){return m}));var i=Math.round(9*Math.random()),r="function"===typeof Object.defineProperty,a=function(){function t(){this._id="__ec_inner_"+i++}return t.prototype.get=function(t){return this._guard(t)[this._id]},t.prototype.set=function(t,e){var n=this._guard(t);return r?Object.defineProperty(n,this._id,{value:e,enumerable:!1,configurable:!0}):n[this._id]=e,this},t.prototype["delete"]=function(t){return!!this.has(t)&&(delete this._guard(t)[this._id],!0)},t.prototype.has=function(t){return!!this._guard(t)[this._id]},t.prototype._guard=function(t){if(t!==Object(t))throw TypeError("Value of WeakMap is not a non-null object.");return t},t}(),o=a,s=n("d51b"),l=n("6d8b"),u=n("3842"),c=n("a15a"),h=n("5210"),d=n("726e"),f=new o,p=new s["a"](100),g=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function m(t,e){if("none"===t)return null;var n=e.getDevicePixelRatio(),i=e.getZr(),r="svg"===i.painter.type;t.dirty&&f["delete"](t);var a=f.get(t);if(a)return a;var o=Object(l["i"])(t,{symbol:"rect",symbolSize:1,symbolKeepAspect:!0,color:"rgba(0, 0, 0, 0.2)",backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});"none"===o.backgroundColor&&(o.backgroundColor=null);var s={repeat:"repeat"};return m(s),s.rotation=o.rotation,s.scaleX=s.scaleY=r?1:1/n,f.set(t,s),t.dirty=!1,s;function m(t){for(var e,a=[n],s=!0,f=0;f=e)){var n=this._store,r=n.getProvider();this._updateOrdinalMeta();var a=this._nameList,o=this._idList,s=r.getSource().sourceFormat,l=s===m["f"];if(l&&!r.pure)for(var c=[],h=t;h0},t.prototype.ensureUniqueItemVisual=function(t,e){var n=this._itemVisuals,i=n[t];i||(i=n[t]={});var r=i[e];return null==r&&(r=this.getVisual(e),c["t"](r)?r=r.slice():w(r)&&(r=c["m"]({},r)),i[e]=r),r},t.prototype.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{};this._itemVisuals[t]=i,w(e)?c["m"](i,e):i[e]=n},t.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},t.prototype.setLayout=function(t,e){w(t)?c["m"](this._layout,t):this._layout[t]=e},t.prototype.getLayout=function(t){return this._layout[t]},t.prototype.getItemLayout=function(t){return this._itemLayouts[t]},t.prototype.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?c["m"](this._itemLayouts[t]||{},e):e},t.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},t.prototype.setItemGraphicEl=function(t,e){var n=this.hostModel&&this.hostModel.seriesIndex;Object(y["b"])(n,this.dataType,t,e),this._graphicEls[t]=e},t.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},t.prototype.eachItemGraphicEl=function(t,e){c["k"](this._graphicEls,(function(n,i){n&&t&&t.call(e,n,i)}))},t.prototype.cloneShallow=function(e){return e||(e=new t(this._schema?this._schema:O(this.dimensions,this._getDimInfo,this),this.hostModel)),s(e,this),e._store=this._store,e},t.prototype.wrapMethod=function(t,e){var n=this[t];c["w"](n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(c["S"](arguments)))})},t.internalField=function(){i=function(t){var e=t._invertedIndicesMap;c["k"](e,(function(n,i){var r=t._dimInfos[i],a=r.ordinalMeta,o=t._store;if(a){n=e[i]=new S(a.categories.length);for(var s=0;s1&&(l+="__ec__"+c),i[e]=l}}}(),t}();e["a"]=I},b7d9:function(t,e,n){"use strict";n.d(e,"d",(function(){return o})),n.d(e,"c",(function(){return l})),n.d(e,"a",(function(){return h})),n.d(e,"b",(function(){return f}));var i=n("3842"),r=n("6d8b"),a=n("edae");function o(t,e){var n=e&&e.type;return"ordinal"===n?t:("time"!==n||Object(r["z"])(t)||null==t||"-"===t||(t=+Object(i["o"])(t)),null==t||""===t?NaN:+t)}var s=Object(r["f"])({number:function(t){return parseFloat(t)},time:function(t){return+Object(i["o"])(t)},trim:function(t){return Object(r["C"])(t)?Object(r["T"])(t):t}});function l(t){return s.get(t)}var u={lt:function(t,e){return te},gte:function(t,e){return t>=e}},c=function(){function t(t,e){if(!Object(r["z"])(e)){var n="";0,Object(a["c"])(n)}this._opFn=u[t],this._rvalFloat=Object(i["n"])(e)}return t.prototype.evaluate=function(t){return Object(r["z"])(t)?this._opFn(t,this._rvalFloat):this._opFn(Object(i["n"])(t),this._rvalFloat)},t}(),h=function(){function t(t,e){var n="desc"===t;this._resultLT=n?1:-1,null==e&&(e=n?"min":"max"),this._incomparable="min"===e?-1/0:1/0}return t.prototype.evaluate=function(t,e){var n=Object(r["z"])(t)?t:Object(i["n"])(t),a=Object(r["z"])(e)?e:Object(i["n"])(e),o=isNaN(n),s=isNaN(a);if(o&&(n=this._incomparable),s&&(a=this._incomparable),o&&s){var l=Object(r["C"])(t),u=Object(r["C"])(e);l&&(n=u?t:0),u&&(a=l?e:0)}return na?-this._resultLT:0},t}(),d=function(){function t(t,e){this._rval=e,this._isEQ=t,this._rvalTypeof=typeof e,this._rvalFloat=Object(i["n"])(e)}return t.prototype.evaluate=function(t){var e=t===this._rval;if(!e){var n=typeof t;n===this._rvalTypeof||"number"!==n&&"number"!==this._rvalTypeof||(e=Object(i["n"])(t)===this._rvalFloat)}return this._isEQ?e:!e},t}();function f(t,e){return"eq"===t||"ne"===t?new d("eq"===t,e):Object(r["q"])(u,t)?new c(t,e):null}},b932:function(t,e,n){"use strict";var i=n("7a23"),r=(n("caad"),n("986e"));function a(t){let e=this;e.mMap=t,e._self={},e._CustomDraw=null,e.polygonGeo=null,e.idsBox={},e.isCheck=!1,a.prototype.setMapCenter=(e,n)=>{t.mapboxGLMap.setCenter(e),t.mapboxGLMap.setZoom(n)},a.prototype.showPoint=n=>{let{coords:i,icon:r,flag:a,iconH:o}=n;if(!i)return;e._self[a]||(e._self[a]=[]);let s=i.map((t,e)=>{let n=t.kfdMc||t.wzBc||t.gajgmc||t.xm||t.jczmc,i={position:[t.jd,t.wd],userData:{deviceSn:"text"+e,area:n},id:t.id,text:n,data:t};if(t.jd&&t.wd)return i});const l=t.createdPoint(s,{image:r,scale:1,highlightImage:o||r,labelOption:{pixelOffset:[0,-2],allShow:!1,fontSize:"18px",fontWeight:600,fontColor:"#000000"}});e._self[a].push(l),l.addEventListener("click",t=>{let n=t.data?JSON.parse(t.data):{};e.openInfoDetail(a,[n])})},a.prototype.makerSki=n=>{let{coords:i,icon:r,flag:a,showTitle:o}=n;i&&(e._self[a]||(e._self[a]=[]),e.idsBox[a]||(e.idsBox[a]=[]),"rx"==a?e.handlePolice(i,r,a,o):i.forEach(n=>{let i=document.createElement("img");i.src=n.icon||r,i.style.width="kfd"==a?"32px":"25px",a.includes("jczMap_")&&(i.style.width="45px"),o&&e.makerShowTitle(n,[n.jd,n.wd],a);const s=t.Marker(i,[n.jd,n.wd],{anchor:"bottom",offset:[0,0]});i.addEventListener("click",()=>{e.openInfoDetail(a,n)}),e._self[a].push(s),e.idsBox[a].push(n.id)}))},a.prototype.handlePolice=(i,r,a,o)=>{i.forEach(i=>{let r=document.createElement("img"),s=n("dab1");switch(i.lx){case"01":s=n("0bb9");break;case"02":s=n("14c9");break;case"03":s=n("7729");break;default:s=n("0bb9");break}1==i.zzlx&&(s=n("dd70"));let l=i.cllx?i.cllx.split(","):[];(l.includes("03")||l.includes("04"))&&"02"==i.lx&&(s=n("157b")),(l.includes("03")||l.includes("04"))&&"01"==i.lx&&(s=n("5749")),(l.includes("08")||l.includes("06"))&&(s=n("e88d")),r.src=s;let u=l.includes("03")||l.includes("08");o&&e.makerShowTitle(i,[i.jd,i.wd],a),e.shouIcon(i,[i.jd,i.wd]);let c=u?[-10,0]:[0,0];l.includes("08")&&(c=[-12,-10]);const h=t.Marker(r,[i.jd,i.wd],{anchor:"bottom",offset:c});r.addEventListener("click",()=>{e.openInfoDetail(a,i)}),e._self[a].push(h),e.idsBox[a].push(i.id)})},a.prototype.makerShowTitle=(n,i,r,a)=>{let o="rx"==r?"rxTitle":"Title",s=r+o;e._self[s]||(e._self[s]=[]);let l=n.jzMc?n.jzMc:n.fzrXm+"警组";"sbwz_car"!=r&&"sbwz_sb"!=r&&"sbwz_zfjly"!=r||(l=n.sbmc),"gapText"==r&&(l=a);const u=document.createElement("div");u.className="makerTitle","sbwz_car"!=r&&"sbwz_sb"!=r&&"sbwz_zfjly"!=r||(u.className="makerTitlezb"),"rx"==r&&("0"==n.xfzt?u.classList.add("makerTitleLine"):"1"==n.xfzt?u.classList.add("makerTitlecj"):u.classList.add("makerTitleUnLine")),"gapText"==r&&(u.className="makerTitleGapText"),u.innerHTML=l;const c=t.Marker(u,i,{anchor:"bottom",offset:[0,-50]});e._self[s].push(c)},a.prototype.shouIcon=(i,r)=>{e._self.gpsZb||(e._self.gpsZb=[]);var a=n("bb77"),o=n("d8f9"),s=n("92c1");let l="string"==typeof i.jyqx?JSON.parse(i.jyqx):i.jyqx?i.jyqx:[],u="string"==typeof i.txzb?JSON.parse(i.txzb):i.txzb?i.txzb:[],c="string"==typeof i.pbcl?JSON.parse(i.pbcl):i.pbcl?i.pbcl:[],h=[],d=!!(c&&c.length>0),f=!!(u&&u.length>0),p=!!(l&&l.length>0);if(f){let e=document.createElement("img");e.style.width="15px",e.src=o;const n=t.Marker(e,r,{anchor:"bottom",offset:[20,-26]});h.push(n)}if(p){let e=document.createElement("img");e.style.width="15px",e.src=a;const n=t.Marker(e,r,{anchor:"bottom",offset:[20,-10]});h.push(n)}if(d){let e=document.createElement("img");e.style.width="20px",e.src=s;const n=t.Marker(e,r,{anchor:"bottom",offset:[20,2]});h.push(n)}e._self.gpsZb[i.id]=h},a.prototype.zdySquire=n=>{let{points:i,flag:r,distance:a}=n;e._self[r]||(e._self[r]=[]);let o="距离:"+a;const s=document.createElement("div");s.className="makerTitle","distance"==r&&(s.className="makerTitleDistance"),s.innerHTML=o;const l=t.Marker(s,i,{anchor:"bottom",offset:[0,-76]});e._self[r].push(l)},a.prototype.diffusionCircle=n=>{let{coords:i,flag:r,isClear:a}=n;e._self[r]||(e._self[r]={}),a&&e._self[r].destroy();let o=[{position:i}];e._self[r]=t.DiffuseCircle(o,{radius:10,color:"rgba(81,217,254)",duration:30,speed:4})},a.prototype.aggregateScatteringPoint=n=>{let{coords:i,icon:r,flag:a,isclear:o,scale:s,fontColor:l}=n,u=i.map(t=>(t.lng=t.jd,t.lat=t.wd,t));e._self[a]||(e._self[a]=[]),o&&e.removeElement(a);let c=t.clusterLayer(u,{id:a,size:18,pixelRange:60,gradient:{1:r,10:r,100:r,1e3:r},fontSize:14,fontColor:l||"#001022",style:"custom",image:r,scale:s||1,fontFamily:["Microsoft YaHei"]});e._self[a].push(c),c.addEventListener("click",t=>{e.openInfoDetail(a,[t])}),c.addEventListener("clusterClick",t=>{e.openInfoDetail(a,t)})},a.prototype.showHeatDrawing=n=>{let{coords:i,flag:r,isclear:a,color:o}=n;e._self[r]||(e._self[r]=[]),a&&e.removeElement(r);let s={type:"FeatureCollection",features:[]};for(let t=0;t10&&e.count<=50?1.6:1.9,o={properties:{mag:a},type:"Feature",geometry:{type:"Point",coordinates:[n,r,.1]}};s.features.push(o)}let l={0:"rgba(23,102,172,0)",.5:"rgb(209,229,240)",1:"rgb(178,24,43)"};o&&(l={0:o[0],.5:o[1],1:o[2]});let u=t.HeatMap(s,{colors:l});e._self[r].push(u)},a.prototype.removeAll=()=>{for(let t in e._self)if("rx"!=t&&"gpsZb"!=t&&!t.includes("rxTitle")){let n=e._self[t];for(let t=0;t{if("gpsZb"==t)for(let n in e._self.gpsZb){let t=e._self.gpsZb[n];if(t&&t.length>0){for(let e in t)t[e].destroy();e._self.gpsZb[n]=[]}}if("rx"==t&&(e.idsBox[t]=[]),!e._self[t])return!1;if("gpsZb"!==t){for(let r=0;r{if(!e.idsBox[t])return!1;let i=e.idsBox[t];i.forEach((i,r)=>{if(i==n&&(e.idsBox[t].splice(r,1),e._self[t][r]&&e._self[t][r].destroy(),e._self[t].splice(r,1),"rx"==t)){let i=t+"rxTitle";e._self[i][r]&&e._self[i][r].destroy(),e._self[i].splice(r,1),e.removeGpsZbOverlayById(n)}})},a.prototype.removeGpsZbOverlayById=t=>{if(e._self.gpsZb[t])try{let n=e._self.gpsZb[t];n&&(n.forEach(t=>{t.destroy()}),delete e._self.gpsZb[t])}catch(n){}},a.prototype.Drawplot=n=>{const{point:i,line:r,polygon:a,circle:o,rectangle:s,geoJson:l,remove:u,enableEdit:c}=t.draw({lineWidth:2,lineColor:"rgba(233,168,32,1)",fillColor:"rgba(233,168,32,0.5)",color:"rgba(233,168,32,1)",pixelSzie:0});e._CustomDraw={point:i,line:r,polygon:a,circle:o,rectangle:s,geoJson:l,remove:u,enableEdit:c}},a.prototype.plot=(t,n)=>{let{flag:i,color:r,linecolor:a,type:o,coords:s}=t;switch(e._self[i]||(e._self[i]=[]),t.isclear&&e.removePlot(i),!t.isclear||"polygon"!=t.type&&"line"!=t.type||e.removeEara(i),o){case"point":e._CustomDraw.point(t=>{e.handlePlot(t,o,i,n)});break;case"rectangle":e._CustomDraw.rectangle(t=>{e.handlePlot(t,o,i,n)});break;case"circle":e._CustomDraw.circle(t=>{e.handlePlot(t,o,i,n)});break;case"polygon":e._CustomDraw.polygon(t=>{e.handlePlot(t,o,i,n)},{fillColor:r||"rgba(233,168,32,0.5)",lineColor:a||"rgba(233,168,32,1)"});break;case"line":e._CustomDraw.line(t=>{e.handlePlot(t,o,i,n)});break;case"geoJson":let t={type:"FeatureCollection",features:[{type:"Feature",geometry:{type:"Polygon",coordinates:s},id:i,properties:{fillColor:r||"rgba(233,168,32,1)",lineColor:a||"rgba(233,168,32,1)"}}]};e._CustomDraw.geoJson(t,t=>{e.handlePlot(t,o,i,n)});break}},a.prototype.handlePlot=(t,n,i,r)=>{e._self[i].push(t.id);let a=t.positionData;r(a,n,i,t)},a.prototype.removePlot=t=>{if(!e._self[t])return!1;e._self[t].forEach(t=>{e._CustomDraw.remove(t)})},a.prototype.removeEara=t=>{e._CustomDraw.remove(t),e.removePlot(t)},a.prototype.createLine=n=>{let{type:i,coords:r,isclear:a,flag:o,color:s,width:l}=n;if(!r)return!1;e._self[o]||(e._self[o]=[]),a&&e.removeElement(o);let u=r.map((t,e)=>({position:t.coords[0],text:"",id:e,userData:{name:t.text}})),c=t.createLine(u,{color:s||"rgba(20, 237, 245,1)",width:l||8,type:i,highlightColor:"red",labelOption:{pixelOffset:[0,-1],allShow:!1,type:"text",fontColor:"rgba(20, 237, 245,1)"}});e._self[o].push(c)},a.prototype.echoPlane=n=>{let{type:i,coords:a,fontColor:o,fontSize:s,text:l="",radius:u=0,isclear:c,flag:h,id:d=1,color:f,linecolor:p}=n;if(!a)return;c&&e.removeElement(h),e._self[h]||(e._self[h]=[]);let g,m=f||"rgba(29,237,245,0.6)",v=p||"rgba(29,237,245,0.6)",y={color:m,outLineColor:v,outLineWidth:2,highlightColor:"rgba(255,0,0,0.5)",labelOption:{pixelOffset:[0,0],allShow:!0,fontColor:o||"#ffffff",fontSize:s||"12px"}};if("circle"==i){let e=[{center:a,radius:u,text:l,id:d}];g=t.createCircle(e,y)}"rectangle"==i&&(g=t.createRectangle(a,y)),"polygon"==i&&(g=t.createPolygon(a,y)),e._self[h].push(g),g.addEventListener("click",t=>{"xfq"==h&&(g.highlight(t.id),r["a"].emit("showXFQinfo",t),t.id==e.lightHeight&&(e.isCheck=!e.isCheck,e.isCheck?(g.highlight(0),r["a"].emit("showXFQinfo",null)):r["a"].emit("showXFQinfo",t)),e.lightHeight=t.id),"zdxl_fzyc"==h&&r["a"].emit("showFzycInfo",{info:t,type:!0})})},a.prototype.gapText=t=>{let{points:n,text:i,flag:r}=t;e.makerShowTitle({},n,r,i)},a.prototype.displayLineAnimation=i=>{let{coords:r,isClear:a,flag:s}=i;if(!r)return;e._self[s]||(e._self[s]=[]),a&&e._self[s]&&e.removeElement(s);let l=o().slice(3,5);const u=[{position:r,text:"实线",id:l,userData:{name:"测试1"}}],c=t.trajectoryRealtime(u,{color:"#28F",width:8,image:"images/car.png",speed:80,imageWidth:20,imageHeight:40,isShowLine:!1,isAgain:!1,traveledColor:"#32b1fb"});c.start(),c.on("length",t=>{let i={flag:s};if(t&&0==t[0].percent){i.icon=n("615e");let r=t[0].position[0];i.coords=[{jd:r[0],wd:r[1]}],e.makerSki(i)}if(t&&99==t[0].percent){let r=t[0].position.length,a=t[0].position[r-1];i.coords=[{jd:a[0],wd:a[1]}],i.icon=n("bfe1"),e.makerSki(i)}}),e._self[s].push(c)},a.prototype.removeTrajectory=t=>{e._self[t]&&(e._self[t].destroy(),e._self[t]=null)},a.prototype.createBoundarys=n=>{let{data:i}=n;if(!i)return!1;e.polygonGeo&&e.removeBj(),e.polygonGeo=t.createPolygon(i,{color:"rgba(20,237,245,0.3)",outLineColor:"#cf1010",outLineWidth:6,highlightColor:"red",type:"solid",labelOption:{pixelOffset:[2,0],allShow:!1,fontColor:"#ffffff"}}),e.polygonGeo.flyTo()},a.prototype.removeBj=t=>{e.polygonGeo.destroy()},a.prototype.openInfoDetail=(t,e)=>{switch(t){case"home_yj_map":r["a"].emit("showHomeYJ",e);break}}}function o(){for(var t=[],e="0123456789abcdefghijklmnopqrstuvwxyz",n=0;n<32;n++)t[n]=e.substr(Math.floor(16*Math.random()),1);t[14]="4",t[19]=e.substr(3&t[19]|8,1),t[8]=t[13]=t[18]=t[23];let i=t.join("");return i}var s=n("5d2d");const l=["id"],u={key:0,class:"changeMap_box"},c={class:"zoomTargetBox"};var h={__name:"index",props:{mapid:{type:String,default:"mapDiv"},isShow:{type:Boolean,default:!1},isShowMvt:{type:Boolean,default:!1},isShowZoom:{type:Boolean,default:!1},isShowDraw:{type:Boolean,default:!1}},setup(t){const e=t,n=Object(i["ref"])(!0),o=(Object(i["ref"])(null),Object(i["ref"])(null)),h=Object(i["ref"])(6);try{Object(s["a"])("deptId")[0].deptCode}catch(m){}let d;Object(i["onMounted"])(()=>{r["a"].on("followUp",t=>{let e=document.getElementsByClassName("changeMap_box");e&&(e[0].style.right=t?"398px":"4px",e[0].style.transition="0.5s")}),d=new EliMap({id:e.mapid,crs:"EPSG:3857",style:{glyphs:"./fonts/{fontstack}/{range}.pbf",center:[94.36,29.65],zoom:10},transformRequest:t=>{if(-1!=t.indexOf("TileMatrix=")){const e=t.split("TileMatrix="),n=e[1].split("&");e[0],Number(n[0]),n[1],n[2]}}}),window.map=d,d.mapboxGLMap.on("load",()=>{d.addGaudLayer({url:"http://webrd02.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}"}),h.value=d.mapboxGLMap.getZoom()}),o.value=new a(d),o.value.Drawplot(),r["a"].on("setMapCenter",t=>{o.value.setMapCenter(t.location,t.zoomLevel)}),r["a"].on("removePlot",t=>{o.value.removePlot(t)}),r["a"].on("removeAll",t=>{o.value.removeAll(t)}),r["a"].on("addPointArea",t=>{o.value.makerSki(t)}),r["a"].on("showPoint",t=>{o.value.showPoint(t)}),r["a"].on("deletePointArea",t=>{o.value.removeElement(t)}),r["a"].on("deletePointAreaOne",t=>{o.value.removeElementOne(t.flag,t.id)}),r["a"].on("showSquire",t=>{o.value.zdySquire(t)}),r["a"].on("drawShape",t=>{o.value.plot(t,f)}),r["a"].on("removeEara",t=>{o.value.removeEara(t)}),r["a"].on("echoPlane",t=>{o.value.echoPlane(t)}),r["a"].on("removeEara",t=>{o.value.removeEara(t)}),r["a"].on("echoLine",t=>{o.value.createLine(t,t.flag)}),r["a"].on("setBoundarys",t=>{o.value.createBoundarys(t)}),r["a"].on("removeBj",t=>{o.value.removeBj(t)}),r["a"].on("drawLineAnimation",t=>{o.value.displayLineAnimation(t)}),r["a"].on("addPoint",t=>{o.value.aggregateScatteringPoint(t)}),r["a"].on("thermodynamicChart",t=>{o.value.showHeatDrawing(t)}),r["a"].on("diffusionCircle",t=>{o.value.diffusionCircle(t)}),r["a"].on("showGapText",t=>{o.value.gapText(t)}),r["a"].on("getCurrentCenter",t=>{let e=d.mapboxGLMap.getCenter(),n=[e.lng,e.lat];r["a"].emit("getcentercoord",n)})});const f=(t,e,n,i)=>{r["a"].emit("coordString",{coord:t,type:e,flag:n,data:i})},p=t=>{d.mapboxGLMap.setZoom(t)},g=t=>{};return Object(i["onUnmounted"])(()=>{r["a"].off("removePlot"),r["a"].off("setMapCenter"),r["a"].off("addPointArea"),r["a"].off("showPoint"),r["a"].off("deletePointArea"),r["a"].off("deletePointAreaOne"),r["a"].off("drawShape"),r["a"].off("echoPlane"),r["a"].off("removeEara"),r["a"].off("echoLine"),r["a"].off("addPoint"),r["a"].off("thermodynamicChart"),r["a"].off("drawLineAnimation"),r["a"].off("aggregateScatteringPoint"),r["a"].off("hotmap"),r["a"].off("setBoundarys"),r["a"].off("diffusionCircle"),r["a"].off("SsCircle"),r["a"].off("ClearssCircle")}),(r,a)=>{const o=Object(i["resolveComponent"])("el-switch"),s=Object(i["resolveComponent"])("el-input-number");return Object(i["openBlock"])(),Object(i["createElementBlock"])(i["Fragment"],null,[Object(i["createElementVNode"])("div",{id:t.mapid,class:"map"},null,8,l),e.isShow?(Object(i["openBlock"])(),Object(i["createElementBlock"])("div",u,[Object(i["createVNode"])(o,{modelValue:n.value,"onUpdate:modelValue":a[0]||(a[0]=t=>n.value=t),onChange:g,"active-text":"打开路况","inactive-text":"关闭路况",style:{"--el-switch-color":"#13ce66","--el-switch-off-color":"#ff4949"}},null,8,["modelValue"]),Object(i["createElementVNode"])("div",c,[Object(i["createVNode"])(s,{min:7,max:18,modelValue:h.value,"onUpdate:modelValue":a[1]||(a[1]=t=>h.value=t),step:1,"step-strictly":"",onChange:p},null,8,["modelValue"])])])):Object(i["createCommentVNode"])("",!0)],64)}}},d=(n("4747"),n("6b0d")),f=n.n(d);const p=f()(h,[["__scopeId","data-v-96008730"]]);e["a"]=p},bb77:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAQCAYAAADJViUEAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAGqSURBVCiRpZNNSxtRFIafyU2ik0lmMimaqBjq58KFKy0uCmaVTVUQqSLd2n26KHRl+wcKbiWC0GWXguLCnWAtYim4aEMXLZZ8qLGINR91MpMudKYOiaD0rM5973nOOe+FK2np5FwdloAYd4+CBClJTSfz9wSdBt6boOKTeTE8y0xfgl61k9+lY0JKO9s/PrOyt8b6+S5G3bTLY6Jlqu+NfVpOvGRhaBKfVaV8ukv202u8UoSu2CCJnjEquTL71W/OaI+dRGWdmd4EAEatQkloCLmbkpAxLYOoGmF6cJx2EXZgr50MhLsdUQ/F0UNxaBtxmRR+QdgT5Ng8+wc/7hjmefwp+9kMbQHVBVjUqV37rFgwH5ng/a8NvhiHV7DikwmIVh4ENeLa7Q+/+fEDfhRaJB8AkppO1u3Lg7l3nBUsDssFctUT/piXAISFgmbofD//ymJutdGzHflqkWd7r1zaZGCM6dgTZ/1bYV0OsjW+3LBy9rQIFbfWAD/q72lml9GBh7xdz7g0T9PKO4Zr8k7+gHzupGmhYdb4eXHk0v7rY3gkSAGF+4ISpP4CnuF/V7XaAZMAAAAASUVORK5CYII="},bda7:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var i=n("6d8b"),r=n("f279");function a(t){if(!t.UTF8Encoding)return t;var e=t,n=e.UTF8Scale;null==n&&(n=1024);var r=e.features;return i["k"](r,(function(t){var e=t.geometry,r=e.encodeOffsets,a=e.coordinates;if(r)switch(e.type){case"LineString":e.coordinates=s(a,r,n);break;case"Polygon":o(a,r,n);break;case"MultiLineString":o(a,r,n);break;case"MultiPolygon":i["k"](a,(function(t,e){return o(t,r[e],n)}))}})),e.UTF8Encoding=!1,e}function o(t,e,n){for(var i=0;i>1^-(1&s),l=l>>1^-(1&l),s+=r,l+=a,r=s,a=l,i.push([s/n,l/n])}return i}function l(t,e){return t=a(t),i["H"](i["n"](t.features,(function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0})),(function(t){var n=t.properties,a=t.geometry,o=[];switch(a.type){case"Polygon":var s=a.coordinates;o.push(new r["b"](s[0],s.slice(1)));break;case"MultiPolygon":i["k"](a.coordinates,(function(t){t[0]&&o.push(new r["b"](t[0],t.slice(1)))}));break;case"LineString":o.push(new r["a"]([a.coordinates]));break;case"MultiLineString":o.push(new r["a"](a.coordinates))}var l=new r["c"](n[e||"name"],o,n.cp);return l.properties=n,l}))}},bfe1:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAAoCAYAAAALz1FrAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAABVxJREFUeNq0V2tsFFUUPjP7bsHSltIa2mLREkSJoqE1WxGxQGwNJSkaXSMSpQrGqrUaiyA/NK1ATCgxRAjgo9akYmwjKA8Li0paFHy0sEaBohURLX3RIm73MTvjOXdnZmd2t91dU0/y5e59zPnuPefcc89y/xQXQLgkO0+wFucs2BQjliLsiBxECmIYcQFxDLEH4cRvvPSNJEkR+rhoJCgmxDOIGsQUiC19iI2IrUmHj/uikuCEOuBeWJiPzW7EHEhcOhAO1HdGO2jUdpBgLjYHEWnqLtLSwTBvARjuuBP43DyApGSAK0Mgnu+GwDftEPiyFSS3W1lOGzuGeu5Fom8jToIT12P/a0RG0GBmMD1aAaZlDgCzedStS39fAf8720H4rIUcojWfHfWe0/qETkQ2u40NXpMClrrNwN94c9x2CnxxCLybXgUQ/MrQD4hCJBJ4eeAphYBOYKmrT4iAxLBgEZhfWKcdIn2V9INIyBYvq2H12CokuClkjsEBGHmgFAInO9SxkSceAW/9pggi46ISRKl26CV0g5lIShDXMjNNyQJT+YO6D/3NGGiT0oCfMTNoFiSTuruCvtjbwiB2nQ3FfsXTyGZSuqS3lHxxn7qTkjLtAhAv/gHC7gawbmsE7xu1YCyaD0L7V8ClprN54dMWRmj8aH/oTqRPBoN9HgSOHlGGSukkc1W7Ftp1p/DVbwT+roUg9veBePQwCAf2guTCk1weCJplaBBMz9awMNf5p6BI2y0gkmlKj582XX9Tp+YEydZXg3FlJUjDQ2B+pY4ppjFu9hwwlZVH+IbP0+nJJZJU9tNmA7BYdIstz9cwE3F5+WB2LAfbzg+Aw8tIZiKT0al8TY06n7DNpUzSdlPJJ1cRE8CL+U0ScQUfin10sn/7FuDt88G38y0Q/7rIFJtWVzG7C4cOgNC4C4S3t4IN/aKYTfJ4dImENPYGvSyCdKlHf5v7+9RbzWVmgaWyGqzvNzPnjyy5m623bNkB1oZmnV8k3Iw2eRJJp7pzV6c+7osXM6Vmx4pQxJ09zfoUcXSywPcngJ+arftO1Ov5kczVjmDeCzgPqpeJwtezYlnImRhlhtsLwL/nYxZp1CcyPn9GWH4JgIApRiNHKHdRCP2qZGTrm7uAnzU7eA+crcDPnBW5U3S0r6mBkVHUUVAoIuz/BHybN6hdxHQlQTYhHmI7zr0OTdGAoWWNma9oE9zkDDDcEnx6pN4e8Kxaznwoy4eYIB1KKK1HsJAQf/8NvK+txXzii0lCPlMJhi6Dd121loD0rVUSJMh5v0o16/F28LyIlw/9Eo+IP7nA81wFiN2/aIerUG93xPOLGfM9bEKhhHnMuPR+MC0pBy47N+y1kjDSfsYE2sTeEtAXEO+izsejPr8oT8oVyT1Bo/tBQCUELiMT+GycmjCRpRcJn19qowhlxtWxCgkqeVopsf2HQoJqqcWobziekihDrqluSIDgnPyu90UkzDHqqBK5jUfY+mgEY5EoO6NM4I9BQPPlSmWSKAlJG6I2xppaJGgbawEfhylepyQ3yhyNb4ilIB4Syj9rRplbg6fwjwcJyT7EqbCxU0iwL56P+QRCdEeM/riQNFOaUpKK3B93EnqbXRqH9/wfJCTfye1Jli44LioinoSxNOJfNJpPogeTKtDTRbf25ljN8KfX15/f1pkjX0R6eNzKexT13RlFOZ0wEzFRO47KLxHJBY/vPFVqMtSCU6583PGaKy2cgORhV1erc3B4JbafR/mG/h1kxX0S+d9tMhWROs97/YGyjjOjpRCKvIFoE1z4X+Iwx9m0PqFaWj49fRSQ4ZFxVQnxcJ3/CjAA4YgICJjJcpQAAAAASUVORK5CYII="},bff8:function(t,e,n){},c1ff:function(t,e,n){},c7a2:function(t,e,n){"use strict";var i=n("21a10"),r=n("cbe5");function a(t,e){var n,i,r,a,o,s=e.x,l=e.y,u=e.width,c=e.height,h=e.r;u<0&&(s+=u,u=-u),c<0&&(l+=c,c=-c),"number"===typeof h?n=i=r=a=h:h instanceof Array?1===h.length?n=i=r=a=h[0]:2===h.length?(n=r=h[0],i=a=h[1]):3===h.length?(n=h[0],i=a=h[1],r=h[2]):(n=h[0],i=h[1],r=h[2],a=h[3]):n=i=r=a=0,n+i>u&&(o=n+i,n*=u/o,i*=u/o),r+a>u&&(o=r+a,r*=u/o,a*=u/o),i+r>c&&(o=i+r,i*=c/o,r*=c/o),n+a>c&&(o=n+a,n*=c/o,a*=c/o),t.moveTo(s+n,l),t.lineTo(s+u-i,l),0!==i&&t.arc(s+u-i,l+i,i,-Math.PI/2,0),t.lineTo(s+u,l+c-r),0!==r&&t.arc(s+u-r,l+c-r,r,0,Math.PI/2),t.lineTo(s+a,l+c),0!==a&&t.arc(s+a,l+c-a,a,Math.PI/2,Math.PI),t.lineTo(s,l+n),0!==n&&t.arc(s+n,l+n,n,Math.PI,1.5*Math.PI)}var o=n("9cf9"),s=function(){function t(){this.x=0,this.y=0,this.width=0,this.height=0}return t}(),l={},u=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype.getDefaultShape=function(){return new s},e.prototype.buildPath=function(t,e){var n,i,r,s;if(this.subPixelOptimize){var u=Object(o["c"])(l,e,this.style);n=u.x,i=u.y,r=u.width,s=u.height,u.r=e.r,e=u}else n=e.x,i=e.y,r=e.width,s=e.height;e.r?a(t,e):t.rect(n,i,r,s)},e.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},e}(r["b"]);u.prototype.type="rect";e["a"]=u},ca7c:function(t,e,n){},ca80:function(t,e,n){"use strict";var i=n("dce8"),r=[0,0],a=[0,0],o=new i["a"],s=new i["a"],l=function(){function t(t,e){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new i["a"];for(n=0;n<2;n++)this._axes[n]=new i["a"];t&&this.fromBoundingRect(t,e)}return t.prototype.fromBoundingRect=function(t,e){var n=this._corners,r=this._axes,a=t.x,o=t.y,s=a+t.width,l=o+t.height;if(n[0].set(a,o),n[1].set(s,o),n[2].set(s,l),n[3].set(a,l),e)for(var u=0;u<4;u++)n[u].transform(e);i["a"].sub(r[0],n[1],n[0]),i["a"].sub(r[1],n[3],n[0]),r[0].normalize(),r[1].normalize();for(u=0;u<2;u++)this._origin[u]=r[u].dot(n[0])},t.prototype.intersect=function(t,e){var n=!0,r=!e;return o.set(1/0,1/0),s.set(0,0),!this._intersectCheckOneSide(this,t,o,s,r,1)&&(n=!1,r)||!this._intersectCheckOneSide(t,this,o,s,r,-1)&&(n=!1,r)||r||i["a"].copy(e,n?o:s),n},t.prototype._intersectCheckOneSide=function(t,e,n,o,s,l){for(var u=!0,c=0;c<2;c++){var h=this._axes[c];if(this._getProjMinMaxOnAxis(c,t._corners,r),this._getProjMinMaxOnAxis(c,e._corners,a),r[1]a[1]){if(u=!1,s)return u;var d=Math.abs(a[0]-r[1]),f=Math.abs(r[0]-a[1]);Math.min(d,f)>o.len()&&(de+d&&h>i+d&&h>a+d&&h>l+d||ht+d&&c>n+d&&c>r+d&&c>o+d||cn||d+ur&&(r+=h);var p=Math.atan2(l,s);return p<0&&(p+=h),p>=i&&p<=r||p+h>=i&&p+h<=r}var f=n("8728"),p=a["a"].CMD,g=2*Math.PI,m=1e-4;function v(t,e){return Math.abs(t-e)e&&c>i&&c>a&&c>l||c1&&b(),p=s["a"](e,i,a,l,_[0]),f>1&&(g=s["a"](e,i,a,l,_[1]))),2===f?v<_[0]?d+=pe&&l>i&&l>a||l=0&&c<=1){for(var h=0,d=s["h"](e,i,a,c),f=0;fn||s<-n)return 0;var l=Math.sqrt(n*n-s*s);y[0]=-l,y[1]=l;var u=Math.abs(i-r);if(u<1e-4)return 0;if(u>=g-1e-4){i=0,r=g;var c=a?1:-1;return o>=y[0]+t&&o<=y[1]+t?c:0}if(i>r){var h=i;i=r,r=h}i<0&&(i+=g,r+=g);for(var d=0,f=0;f<2;f++){var p=y[f];if(p+t>o){var m=Math.atan2(s,p);c=a?1:-1;m<0&&(m=g+m),(m>=i&&m<=r||m+g>=i&&m+g<=r)&&(m>Math.PI/2&&m<1.5*Math.PI&&(c=-c),d+=c)}}return d}function S(t,e,n,i,r){for(var a,s,c=t.data,h=t.len(),g=0,m=0,y=0,_=0,b=0,S=0;S1&&(n||(g+=Object(f["a"])(m,y,_,b,i,r))),M&&(m=c[S],y=c[S+1],_=m,b=y),T){case p.M:_=c[S++],b=c[S++],m=_,y=b;break;case p.L:if(n){if(o["a"](m,y,c[S],c[S+1],e,i,r))return!0}else g+=Object(f["a"])(m,y,c[S],c[S+1],i,r)||0;m=c[S++],y=c[S++];break;case p.C:if(n){if(l(m,y,c[S++],c[S++],c[S++],c[S++],c[S],c[S+1],e,i,r))return!0}else g+=x(m,y,c[S++],c[S++],c[S++],c[S++],c[S],c[S+1],i,r)||0;m=c[S++],y=c[S++];break;case p.Q:if(n){if(u["a"](m,y,c[S++],c[S++],c[S],c[S+1],e,i,r))return!0}else g+=w(m,y,c[S++],c[S++],c[S],c[S+1],i,r)||0;m=c[S++],y=c[S++];break;case p.A:var A=c[S++],C=c[S++],I=c[S++],D=c[S++],L=c[S++],E=c[S++];S+=1;var j=!!(1-c[S++]);a=Math.cos(L)*I+A,s=Math.sin(L)*D+C,M?(_=a,b=s):g+=Object(f["a"])(m,y,a,s,i,r);var P=(i-A)*D/I+A;if(n){if(d(A,C,D,L,L+E,j,e,P,r))return!0}else g+=O(A,C,D,L,L+E,j,P,r);m=Math.cos(L+E)*I+A,y=Math.sin(L+E)*D+C;break;case p.R:_=m=c[S++],b=y=c[S++];var N=c[S++],R=c[S++];if(a=_+N,s=b+R,n){if(o["a"](_,b,a,b,e,i,r)||o["a"](a,b,a,s,e,i,r)||o["a"](a,s,_,s,e,i,r)||o["a"](_,s,_,b,e,i,r))return!0}else g+=Object(f["a"])(a,b,a,s,i,r),g+=Object(f["a"])(_,s,_,b,i,r);break;case p.Z:if(n){if(o["a"](m,y,_,b,e,i,r))return!0}else g+=Object(f["a"])(m,y,_,b,i,r);m=_,y=b;break}}return n||v(y,b)||(g+=Object(f["a"])(m,y,_,b,i,r)||0),0!==g}function T(t,e,n){return S(t,0,!1,e,n)}function M(t,e,n,i){return S(t,e,!0,n,i)}var A=n("6d8b"),C=n("41ef"),I=n("2cf4"),D=n("4bc4"),L=n("8582"),E=Object(A["i"])({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},r["b"]),j={style:Object(A["i"])({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},r["a"].style)},P=L["a"].concat(["invisible","culling","z","z2","zlevel","parent"]),N=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype.update=function(){var n=this;t.prototype.update.call(this);var i=this.style;if(i.decal){var r=this._decalEl=this._decalEl||new e;r.buildPath===e.prototype.buildPath&&(r.buildPath=function(t){n.buildPath(t,n.shape)}),r.silent=!0;var a=r.style;for(var o in i)a[o]!==i[o]&&(a[o]=i[o]);a.fill=i.fill?i.decal:null,a.decal=null,a.shadowColor=null,i.strokeFirst&&(a.stroke=null);for(var s=0;s.5?I["a"]:e>.2?I["c"]:I["d"]}if(t)return I["d"]}return I["a"]},e.prototype.getInsideTextStroke=function(t){var e=this.style.fill;if(Object(A["C"])(e)){var n=this.__zr,i=!(!n||!n.isDarkMode()),r=Object(C["lum"])(t,0)0))},e.prototype.hasFill=function(){var t=this.style,e=t.fill;return null!=e&&"none"!==e},e.prototype.getBoundingRect=function(){var t=this._rect,e=this.style,n=!t;if(n){var i=!1;this.path||(i=!0,this.createPathProxy());var r=this.path;(i||this.__dirty&D["b"])&&(r.beginPath(),this.buildPath(r,this.shape,!1),this.pathUpdated()),t=r.getBoundingRect()}if(this._rect=t,this.hasStroke()&&this.path&&this.path.len()>0){var a=this._rectStroke||(this._rectStroke=t.clone());if(this.__dirty||n){a.copy(t);var o=e.strokeNoScale?this.getLineScale():1,s=e.lineWidth;if(!this.hasFill()){var l=this.strokeContainThreshold;s=Math.max(s,null==l?4:l)}o>1e-10&&(a.width+=s/o,a.height+=s/o,a.x-=s/o/2,a.y-=s/o/2)}return a}return t},e.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect(),r=this.style;if(t=n[0],e=n[1],i.contain(t,e)){var a=this.path;if(this.hasStroke()){var o=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(this.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),M(a,o/s,t,e)))return!0}if(this.hasFill())return T(a,t,e)}return!1},e.prototype.dirtyShape=function(){this.__dirty|=D["b"],this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},e.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},e.prototype.animateShape=function(t){return this.animate("shape",t)},e.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():"shape"===t?this.dirtyShape():this.markRedraw()},e.prototype.attrKV=function(e,n){"shape"===e?this.setShape(n):t.prototype.attrKV.call(this,e,n)},e.prototype.setShape=function(t,e){var n=this.shape;return n||(n=this.shape={}),"string"===typeof t?n[t]=e:Object(A["m"])(n,t),this.dirtyShape(),this},e.prototype.shapeChanged=function(){return!!(this.__dirty&D["b"])},e.prototype.createStyle=function(t){return Object(A["g"])(E,t)},e.prototype._innerSaveToNormal=function(e){t.prototype._innerSaveToNormal.call(this,e);var n=this._normalState;e.shape&&!n.shape&&(n.shape=Object(A["m"])({},this.shape))},e.prototype._applyStateObj=function(e,n,i,r,a,o){t.prototype._applyStateObj.call(this,e,n,i,r,a,o);var s,l=!(n&&r);if(n&&n.shape?a?r?s=n.shape:(s=Object(A["m"])({},i.shape),Object(A["m"])(s,n.shape)):(s=Object(A["m"])({},r?this.shape:i.shape),Object(A["m"])(s,n.shape)):l&&(s=i.shape),s)if(a){this.shape=Object(A["m"])({},this.shape);for(var u={},c=Object(A["F"])(s),h=0;h65535?l:u}function p(){return[1/0,-1/0]}function g(t){var e=t.constructor;return e===Array?t.slice():new e(t)}function m(t,e,n,i,r){var a=d[n||"float"];if(r){var o=t[e],s=o&&o.length;if(s!==i){for(var l=new a(i),u=0;uv[1]&&(v[1]=g)}return this._rawCount=this._count=l,{start:s,end:l}},t.prototype._initDataFromProvider=function(t,e,n){for(var i=this._provider,a=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=Object(r["H"])(o,(function(t){return t.property})),c=0;c_[1]&&(_[1]=y)}}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=e,this._extent=[]},t.prototype.count=function(){return this._count},t.prototype.get=function(t,e){if(!(e>=0&&e=0&&e=this._rawCount||t<0)return-1;if(!this._indices)return t;var e=this._indices,n=e[t];if(null!=n&&nt))return a;r=a-1}}return-1},t.prototype.indicesOfNearest=function(t,e,n){var i=this._chunks,r=i[t],a=[];if(!r)return a;null==n&&(n=1/0);for(var o=1/0,s=-1,l=0,u=0,c=this.count();u=0&&s<0)&&(o=f,s=d,l=0),d===s&&(a[l++]=u))}return a.length=l,a},t.prototype.getIndices=function(){var t,e=this._indices;if(e){var n=e.constructor,i=this._count;if(n===Array){t=new n(i);for(var r=0;r=h&&_<=d||isNaN(_))&&(l[u++]=m),m++}g=!0}else if(2===a){v=p[i[0]];var b=p[i[1]],x=t[i[1]][0],w=t[i[1]][1];for(y=0;y=h&&_<=d||isNaN(_))&&(O>=x&&O<=w||isNaN(O))&&(l[u++]=m),m++}g=!0}}if(!g)if(1===a)for(y=0;y=h&&_<=d||isNaN(_))&&(l[u++]=S)}else for(y=0;yt[A][1])&&(T=!1)}T&&(l[u++]=e.getRawIndex(y))}return uv[1]&&(v[1]=m)}}}},t.prototype.lttbDownSample=function(t,e){var n,i,r,a=this.clone([t],!0),o=a._chunks,s=o[t],l=this.count(),u=0,c=Math.floor(1/e),h=this.getRawIndex(0),d=new(f(this._rawCount))(Math.min(2*(Math.ceil(l/c)+2),l));d[u++]=h;for(var p=1;pn&&(n=i,r=b))}A>0&&Au-g&&(s=u-g,o.length=s);for(var m=0;mc[1]&&(c[1]=y),h[d++]=_}return r._count=d,r._indices=h,r._updateGetRawIdx(),r},t.prototype.each=function(t,e){if(this._count)for(var n=t.length,i=this._chunks,r=0,a=this.count();rs&&(s=c)}return i=[o,s],this._extent[t]=i,i},t.prototype.getRawDataItem=function(t){var e=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(e);for(var n=[],i=this._chunks,r=0;r=0?this._indices[t]:-1},t.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},t.internalField=function(){function t(t,e,n,i){return Object(a["d"])(t[i],this._dimensions[i])}i={arrayRows:t,objectRows:function(t,e,n,i){return Object(a["d"])(t[e],this._dimensions[i])},keyedColumns:t,original:function(t,e,n,i){var r=t&&(null==t.value?t:t.value);return Object(a["d"])(r instanceof Array?r[i]:r,this._dimensions[i])},typedArray:function(t,e,n,i){return t[i]}}}(),t}();e["b"]=v},d409:function(t,e,n){"use strict";n.d(e,"c",(function(){return s})),n.d(e,"a",(function(){return h})),n.d(e,"b",(function(){return g}));var i=n("5e76"),r=n("6d8b"),a=n("e86a"),o=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function s(t,e,n,i,r){if(!e)return"";var a=(t+"").split("\n");r=l(e,n,i,r);for(var o=0,s=a.length;o=l;c++)u-=l;var h=Object(a["f"])(n,e);return h>u&&(n="",h=0),u=t-h,o.ellipsis=n,o.ellipsisWidth=h,o.contentWidth=u,o.containerWidth=t,o}function u(t,e){var n=e.containerWidth,i=e.font,r=e.contentWidth;if(!n)return"";var o=Object(a["f"])(t,i);if(o<=n)return t;for(var s=0;;s++){if(o<=r||s>=e.maxIterations){t+=e.ellipsis;break}var l=0===s?c(t,r,e.ascCharWidth,e.cnCharWidth):o>0?Math.floor(t.length*r/o):0;t=t.substr(0,l),o=Object(a["f"])(t,i)}return""===t&&(t=e.placeholder),t}function c(t,e,n,i){for(var r=0,a=0,o=t.length;av&&p){var y=Math.floor(v/d);n=n.slice(0,y)}if(t&&c&&null!=g)for(var _=l(g,s,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),x=0;xf&&m(n,t.substring(f,g),e,d),m(n,l[2],e,d,l[1]),f=o.lastIndex}fc){C>0?(T.tokens=T.tokens.slice(0,C),O(T,A,M),n.lines=n.lines.slice(0,S+1)):n.lines=n.lines.slice(0,S);break t}var N=D.width,R=null==N||"auto"===N;if("string"===typeof N&&"%"===N.charAt(N.length-1))I.percentWidth=N,v.push(I),I.contentWidth=Object(a["f"])(I.text,j);else{if(R){var k=D.backgroundColor,B=k&&k.image;B&&(B=i["b"](B),i["c"](B)&&(I.width=Math.max(I.width,B.width*P/B.height)))}var z=x&&null!=u?u-A:null;null!=z&&z0&&v+i.accumWidth>i.width&&(o=e.split("\n"),p=!0),i.accumWidth=v}else{var y=b(e,h,i.width,i.breakAll,i.accumWidth);i.accumWidth=y.accumWidth+m,s=y.linesWidths,o=y.lines}}else o=e.split("\n");for(var _=0;_=33&&e<=383}var y=Object(r["N"])(",&?/;] ".split(""),(function(t,e){return t[e]=!0,t}),{});function _(t){return!v(t)||!!y[t]}function b(t,e,n,i,r){for(var o=[],s=[],l="",u="",c=0,h=0,d=0;dn:r+h+p>n)?h?(l||u)&&(g?(l||(l=u,u="",c=0,h=c),o.push(l),s.push(h-c),u+=f,c+=p,l="",h=c):(u&&(l+=u,u="",c=0),o.push(l),s.push(h),l=f,h=p)):g?(o.push(u),s.push(c),u=f,c=p):(o.push(f),s.push(p)):(h+=p,g?(u+=f,c+=p):(u&&(l+=u,u="",c=0),l+=f))}else u&&(l+=u,h+=c),o.push(l),s.push(h),l="",u="",c=0,h=0}return o.length||l||(l=t,u="",c=0),u&&(l+=u),l&&(o.push(l),s.push(h)),1===o.length&&(h+=r),{accumWidth:h,lines:o,linesWidths:s}}},d498:function(t,e,n){"use strict";var i=n("21a10"),r=n("cbe5"),a=n("4fac"),o=function(){function t(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return t}(),s=function(t){function e(e){return t.call(this,e)||this}return Object(i["a"])(e,t),e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new o},e.prototype.buildPath=function(t,e){a["a"](t,e,!1)},e}(r["b"]);s.prototype.type="polyline",e["a"]=s},d4c6:function(t,e,n){"use strict";var i=n("21a10"),r=n("cbe5"),a=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="compound",e}return Object(i["a"])(e,t),e.prototype._updatePathDirty=function(){for(var t=this.shape.paths,e=this.shapeChanged(),n=0;n=this._maxSize&&o>0){var l=n.head;n.remove(l),delete r[l.key],a=l.value,this._lastRemovedEntry=l}s?s.value=e:s=new i(e),s.key=t,n.insertEntry(s),r[t]=s}return a},t.prototype.get=function(t){var e=this._map[t],n=this._list;if(null!=e)return e!==n.tail&&(n.remove(e),n.insertEntry(e)),e.value},t.prototype.clear=function(){this._list.clear(),this._map={}},t.prototype.len=function(){return this._list.len()},t}();e["a"]=a},d5b7:function(t,e,n){"use strict";var i=n("8582"),r=n("06ad"),a=n("9850"),o=n("6fd3"),s=n("e86a"),l=n("6d8b"),u=n("2cf4"),c=n("41ef"),h=n("4bc4"),d="__zr_normal__",f=i["a"].concat(["ignore"]),p=Object(l["N"])(i["a"],(function(t,e){return t[e]=!0,t}),{ignore:!1}),g={},m=new a["a"](0,0,0,0),v=function(){function t(t){this.id=Object(l["p"])(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return t.prototype._init=function(t){this.attr(t)},t.prototype.drift=function(t,e,n){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0;break}var i=this.transform;i||(i=this.transform=[1,0,0,1,0,0]),i[4]+=t,i[5]+=e,this.decomposeTransform(),this.markRedraw()},t.prototype.beforeUpdate=function(){},t.prototype.afterUpdate=function(){},t.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},t.prototype.updateInnerText=function(t){var e=this._textContent;if(e&&(!e.ignore||t)){this.textConfig||(this.textConfig={});var n=this.textConfig,i=n.local,r=e.innerTransformable,a=void 0,o=void 0,l=!1;r.parent=i?this:null;var u=!1;if(r.copyTransform(e),null!=n.position){var c=m;n.layoutRect?c.copy(n.layoutRect):c.copy(this.getBoundingRect()),i||c.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(g,n,c):Object(s["c"])(g,n,c),r.x=g.x,r.y=g.y,a=g.align,o=g.verticalAlign;var d=n.origin;if(d&&null!=n.rotation){var f=void 0,p=void 0;"center"===d?(f=.5*c.width,p=.5*c.height):(f=Object(s["g"])(d[0],c.width),p=Object(s["g"])(d[1],c.height)),u=!0,r.originX=-r.x+f+(i?0:c.x),r.originY=-r.y+p+(i?0:c.y)}}null!=n.rotation&&(r.rotation=n.rotation);var v=n.offset;v&&(r.x+=v[0],r.y+=v[1],u||(r.originX=-v[0],r.originY=-v[1]));var y=null==n.inside?"string"===typeof n.position&&n.position.indexOf("inside")>=0:n.inside,_=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),b=void 0,x=void 0,w=void 0;y&&this.canBeInsideText()?(b=n.insideFill,x=n.insideStroke,null!=b&&"auto"!==b||(b=this.getInsideTextFill()),null!=x&&"auto"!==x||(x=this.getInsideTextStroke(b),w=!0)):(b=n.outsideFill,x=n.outsideStroke,null!=b&&"auto"!==b||(b=this.getOutsideFill()),null!=x&&"auto"!==x||(x=this.getOutsideStroke(b),w=!0)),b=b||"#000",b===_.fill&&x===_.stroke&&w===_.autoStroke&&a===_.align&&o===_.verticalAlign||(l=!0,_.fill=b,_.stroke=x,_.autoStroke=w,_.align=a,_.verticalAlign=o,e.setDefaultTextStyle(_)),e.__dirty|=h["a"],l&&e.dirtyStyle(!0)}},t.prototype.canBeInsideText=function(){return!0},t.prototype.getInsideTextFill=function(){return"#fff"},t.prototype.getInsideTextStroke=function(t){return"#000"},t.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?u["d"]:u["a"]},t.prototype.getOutsideStroke=function(t){var e=this.__zr&&this.__zr.getBackgroundColor(),n="string"===typeof e&&Object(c["parse"])(e);n||(n=[255,255,255,1]);for(var i=n[3],r=this.__zr.isDarkMode(),a=0;a<3;a++)n[a]=n[a]*i+(r?0:255)*(1-i);return n[3]=1,Object(c["stringify"])(n,"rgba")},t.prototype.traverse=function(t,e){},t.prototype.attrKV=function(t,e){"textConfig"===t?this.setTextConfig(e):"textContent"===t?this.setTextContent(e):"clipPath"===t?this.setClipPath(e):"extra"===t?(this.extra=this.extra||{},Object(l["m"])(this.extra,e)):this[t]=e},t.prototype.hide=function(){this.ignore=!0,this.markRedraw()},t.prototype.show=function(){this.ignore=!1,this.markRedraw()},t.prototype.attr=function(t,e){if("string"===typeof t)this.attrKV(t,e);else if(Object(l["A"])(t))for(var n=t,i=Object(l["F"])(n),r=0;r0},t.prototype.getState=function(t){return this.states[t]},t.prototype.ensureState=function(t){var e=this.states;return e[t]||(e[t]={}),e[t]},t.prototype.clearStates=function(t){this.useState(d,!1,t)},t.prototype.useState=function(t,e,n,i){var r=t===d,a=this.hasState();if(a||!r){var o=this.currentStates,s=this.stateTransition;if(!(Object(l["r"])(o,t)>=0)||!e&&1!==o.length){var u;if(this.stateProxy&&!r&&(u=this.stateProxy(t)),u||(u=this.states&&this.states[t]),u||r){r||this.saveCurrentToNormalState(u);var c=!!(u&&u.hoverLayer||i);c&&this._toggleHoverLayerFlag(!0),this._applyStateObj(t,u,this._normalState,e,!n&&!this.__inHover&&s&&s.duration>0,s);var f=this._textContent,p=this._textGuide;return f&&f.useState(t,e,n,c),p&&p.useState(t,e,n,c),r?(this.currentStates=[],this._normalState={}):e?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~h["a"]),u}Object(l["G"])("State "+t+" not exists.")}}},t.prototype.useStates=function(t,e,n){if(t.length){var i=[],r=this.currentStates,a=t.length,o=a===r.length;if(o)for(var s=0;s0,p);var g=this._textContent,m=this._textGuide;g&&g.useStates(t,e,d),m&&m.useStates(t,e,d),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!d&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~h["a"])}else this.clearStates()},t.prototype._updateAnimationTargets=function(){for(var t=0;t=0){var n=this.currentStates.slice();n.splice(e,1),this.useStates(n)}},t.prototype.replaceState=function(t,e,n){var i=this.currentStates.slice(),r=Object(l["r"])(i,t),a=Object(l["r"])(i,e)>=0;r>=0?a?i.splice(r,1):i[r]=e:n&&!a&&i.push(e),this.useStates(i)},t.prototype.toggleState=function(t,e){e?this.useState(t,!0):this.removeState(t)},t.prototype._mergeStates=function(t){for(var e,n={},i=0;i=0&&e.splice(n,1)})),this.animators.push(t),n&&n.animation.addAnimator(t),n&&n.wakeUp()},t.prototype.updateDuringAnimation=function(t){this.markRedraw()},t.prototype.stopAnimation=function(t,e){for(var n=this.animators,i=n.length,r=[],a=0;a0&&n.during&&a[0].during((function(t,e){n.during(e)}));for(var d=0;d0||a.force&&!s.length){var I=void 0,D=void 0,L=void 0;if(u){D={},p&&(I={});for(T=0;T0},e.prototype.hasFill=function(){var t=this.style,e=t.fill;return null!=e&&"none"!==e},e.prototype.createStyle=function(t){return Object(s["g"])(u,t)},e.prototype.setBoundingRect=function(t){this._rect=t},e.prototype.getBoundingRect=function(){var t=this.style;if(!this._rect){var e=t.text;null!=e?e+="":e="";var n=Object(a["d"])(e,t.font,t.textAlign,t.textBaseline);if(n.x+=t.x||0,n.y+=t.y||0,this.hasStroke()){var i=t.lineWidth;n.x-=i/2,n.y-=i/2,n.width+=i,n.height+=i}this._rect=n}return this._rect},e.initDefaultProps=function(){var t=e.prototype;t.dirtyRectTolerance=10}(),e}(r["c"]);c.prototype.type="tspan",e["a"]=c},dd70:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB0AAAAyCAYAAACgadDsAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAACxMAAAsTAQCanBgAAAucSURBVFhHvZhpVFPXFsfTvg5rva71+trX1dfX2taBtjhbq4gCUoQ6z9YRtYooDhW1iqitVRRlKPOgIKMgCCEIIWKYtM6IIoMBmRJmQYYwhWDm/zvnQtJE4+v7Yj/81t33nHv2f+9z9r3nJCwAfzlGG181RhtfNUYbXzVGG/VRqVRv9PX1va9QKN69fevWwr3Oe+LnzZ4jsLK0LPPy9HTnpqfbFxcXTxeLxf82Nt4YOqOoqMiA0tJSVmFhIcvf39/R2dk5b/myZQ2mJl9g+LBPQa9jvzLFyM8+ZzD94kvMMJ/eetLthH9LS4uJvoAxdIZUKjWAZMZKSkpaYWtrWzth4kT1Jx99jFHDR2D86DH4esJEhgnjxmEcuacBjCaBfP7JMJhPNWsTCASW+iLPY7SRwuVyHceMHav8ZsoUbP1hAw7u3oHNa1dh4vjxMDExgfVMK1hbW8PMzAyTSADjRo/GONPRGPX5cFhbWQm7u7vfpX40Gg2Dvm+DGy1dXV3DiEPxpK+/RlbieciE5ZCJyjFQLUBJNg8/79mNqZMnE7EJMCWZ0ufGj5+AMXQWJk7EZyTjvLy8VcZ8U3RGa2srQ0dHB4vH4y0wJZFvWLuaEewWFKJriP7KUshJAMVEPNLHiwTwI7ZtsMcuRwfs2LIZY0zHYDgRjY2JcVGr1SyZTMZgVNTDw4PBx8eH5eTktGQMWS9X511QiB6jvfgeWgrvQvzoARMAvUoqSqCsrWCC6hI8hILYD7O4GDViJFNsURERB1RKJUsq6WcwKlpRUcFQU1PDSmanzBpBKvIwEdU01SMjLgq/uuyFx9HDuJ7KJtk+Ql+FACkR4aTtEH49+BNupnHQU16K+Xa2+PCDD8HjXd5K/f7fayoVd1gvnz9HvXfnTvSX8dF0wweia/6oyvZCw40gdD66jY7iHNRe+w0VWZ6ozPFG03VfKIT3cHjfPthZmKO9sW499fU/RaVPagdpFr0lzc8queR7Ai67ndF56ygklcXYtXkzbCwscZ3th9abx1Cfsw21dzIxx8YWKxcvResDPnoL/eC69wA8d2+F7E5ml7yncyr1/VLR3ubaQZpEb3dcTRM1p8Wg6e5NNN/0wdOCRNTezoQgJwW1uafR9vtFtOafR/PtcFRd56LuDh9PboWirSCW2DchTI3B04w4SNualqmIbyVUxkX1kfd2T+otvevXI7jfLiZF0nafg44HbIgfstFxPwPt13jEzkdbYRo6C0kb6Wsv5KK7rAQ9jwrQdTe7WFJXuYdU71vG/L/QQNEMXQfaW7d3FuWT6iwhFKPrUTH6Guow0N5CsniCnuoK0l402FdWDHHJPUgaapJJdm8poWGpNYYZatEZKrVKh1Jrq5TvdFcJ7nSSV4a+JpSusodErIwggHjo9WEoIRmWFbXIZc8+UxJ/cpWSpdKomQS0SbwgqqaRPQd9WKWQD5PU1+T2lj+E5HExeoiouPQ+OgndxJZUkOxJn1T0WKB6JrVU0zFk7PMYFZWBfD2eQ077lPL3Swry/RJjY1Gcy0fzvevoEdCPxAPGLsnjgx0Xj4RkzpWunt73GH9kWjUkSxAff2BEVK6UGaAkg+Rd7ealuZl1UeEROOkdgGOnfRAWFITWvDRIbvKQEBKIw24eTJ+7tz/YlzKEjyurHZVKxWuDfv9EVKGS6VCREtcM9Jj8zr3UdIHDRTz7EuKTU3EmIhZuvwUh83wUarjx8PQPhV9wOM4nsnGB9CdfykBoxHkkXcpIkMll/6R+NUzWL3llNCqyhhQNsWUD/+KnskvCYxORwr2MlPTLSM3IROi5GPgGhcPJaScszKbA0y8UvwWewUVOOjjcTOa5uIsceAacwSUen01OHW8qyfdXTvZmo6IggiCCUCnf5GdkcLyCwpDATmMcsdN4OsKi4rF85TqYfDUanj5BuJDE0T1Dr4kpaQgMi4ZXwFnczr9/jPpWkkrW6RAMbgivXbv2e5BnYBiCwmOQlMo1EKRO0zOz8d3cRWQfnYDgs1FI45FC0nvmIhlDxwaQPr/QiIHmlqczntMwFBUIyrZ7B55lIg05F0ucZBg4pASGhsPCygZfmY5HZOwFMu1XDPoH1zUWQWEx8Ak+R9aXx1eqVG/r6+gM6YD0vci4i5UkOhJlNM7FJCCVrJO+Q5ppSFgUZlhY44svxxI7kq7dC88Eh0fjhHcg/M9EEuFwTW19w1yjonV19ct8Q87hN1IoJ7z8EUyKhq5P8tAU00Kh030uJh5Tp1lipMlo+ASEIO1yloEohxQcHXvKJ5iZZuqTn3vtV6OiQqFoh29IBDO19FWgUQ5OcwzORsUhNjGFvBop8PINgqWlNf4zbCTc3D2RfiXbUJQEF52QhIAzUcx4KhwUFu1mVLSx+clUEpWSPhhM1pNeKQFDV3cSuetJb+SnxKOOvKPuu7Zin8sRcPm5L4peSIY/KSRGMDwW3gGhx42KyuWKfySkpBV4k8rVCupz5IQXjrt7o4Psqer8K2jkxWO/iyvJNOelonQcFfYOfImoUiln9fX3jyCDrniRCqbFRMtey9HTvjh6whNFSZHgh3hh45JF+MHBCRlZeS+IhkXHMzNEBekykSDcjYrKZAPMVaFU/D3vxu0TRGiAvjbhMRcQFZfErCmZCTg4bscnn47Ex4SNm7eBpydKBc+dT8Rp32AmS7pMJGNpRbVwjlaHojPk8mdk/ySfK2Z3AKtEUL6LvPjt6ZlZGh4/h3wUspBIvsGbtmzHKFK5lA2btiLr6nWmj0sKipeVA7o57PvFHQfdvHHwmAcyruQkaTW06Ay5rF+HQt7PUpNPV7Ww7qNDRz0uH/zlNHwCw3Ga7CYO2/bD4tul+MZ8HjZu2YOzkfE46RkIlyOnYO+wF/ywYDxMjkFCaJA6NDzqerWobpq+IEVnqOjuMoRaI2f1S/tY5RXVrPWb96SYz1wCmzlrsPj7LZi7eCNs59kT4RWYvXADps9chinTF5IgFmKqxWIsWroJT8uKoiFusdEX0kdnaMiep0O3AeNvDtsOVE6etgA2s9cQkfWDLFgP27nrmAC+W2APu/n2TBvtmzV3LWrqmsyoTzXdsegmMqShRe+GHin0YdrfWLdxdy3NwtpuFeYs2sA4tp23DvabnEnmjkSUiC0aCoZgM3s1KiprZtHxxs5HFJ1BT276DG6+mtc2OuzLnzxtIZOpVvRb4tj1Z4/Hy1dv66GZagWH7P66+oZRCoWcJSPFqcWoaHml8AVqRA2srbsOsa3sVjKCWlEru+81cQmpc1au21GgL2o3fx1WrHF62inueUf6TEZ+XD/TYVRUrlS9gFqtYQWdiT41beZinSB1vOR7R2FvX//bP7m6ZVvPXqUTtSYzsHr9zrt9vb2v9/X1schVh1FRw0MUhZ5r1CyJpP+DTY57C+haUWEqcuCQeyQdczbywn6LWSuYdrq2JCBZztUbawcGaHaGfyf8oaMnqqQnQC0qObOuzMeC9JWXV0w2s1qimmazBuPMFoHLyz1C2+8VPPxm0oylarNZ6zDRfDHSuHzml9qfoTMUCnISHIIcIQcPaINfp9cJdjzfA9LkXRaI3T4NNYK7rrQqe7o7P714YN5AktNksF2WQC6R/Eie/VjrkylGtZJB20bRGTQrLWryk4K0faRQKPd3S8T52SXpysNxq1D2gAP+1SCEZXtcpj//rhRxIsM5zpr20lyk5HjhhiAXPZJusUKpPEXGkyMoCZoIMxgTbevsZmgntHaIzRuedg1UiZrglrgPq32ssNJnOk6yf8HjmhaUVwvvadRqVkNLU0O5sAlZhTewJ3oTXKK3wD3ZFaWVlWho6xZ3dEs2yOQK1jOZ/CWi7e06WlqfjhPVNXpU1dQerxKKjtfWNx1rbGx1q29sOt7Q2OzX2tpuT8eIausX3b5zf2+1SBhSJapNrRQKOWVVlZya2npOtaj+Rktrm8NgUQ3uYFoMbv4qjDa+aow2vlrA+i/YU+7hegGwiAAAAABJRU5ErkJggg=="},dded:function(t,e,n){"use strict";var i=n("21a10"),r=n("42e5"),a=function(t){function e(e,n,i,r,a){var o=t.call(this,r)||this;return o.x=null==e?.5:e,o.y=null==n?.5:n,o.r=null==i?.5:i,o.type="radial",o.global=a||!1,o}return Object(i["a"])(e,t),e}(r["a"]);e["a"]=a},deab:function(t,e,n){"use strict";n.d(e,"a",(function(){return o})),n.d(e,"h",(function(){return l})),n.d(e,"c",(function(){return u})),n.d(e,"d",(function(){return c})),n.d(e,"e",(function(){return h})),n.d(e,"f",(function(){return f})),n.d(e,"g",(function(){return p})),n.d(e,"b",(function(){return g}));var i=n("6d8b"),r=n("e0d3"),a=Object(r["o"])();function o(t,e,n,r,a){var o;if(e&&e.ecModel){var s=e.ecModel.getUpdatePayload();o=s&&s.animation}var l=e&&e.isAnimationEnabled(),u="update"===t;if(l){var c=void 0,h=void 0,d=void 0;r?(c=Object(i["P"])(r.duration,200),h=Object(i["P"])(r.easing,"cubicOut"),d=0):(c=e.getShallow(u?"animationDurationUpdate":"animationDuration"),h=e.getShallow(u?"animationEasingUpdate":"animationEasing"),d=e.getShallow(u?"animationDelayUpdate":"animationDelay")),o&&(null!=o.duration&&(c=o.duration),null!=o.easing&&(h=o.easing),null!=o.delay&&(d=o.delay)),Object(i["w"])(d)&&(d=d(n,a)),Object(i["w"])(c)&&(c=c(n));var f={duration:c||0,delay:d,easing:h};return f}return null}function s(t,e,n,r,a,s,l){var u,c=!1;Object(i["w"])(a)?(l=s,s=a,a=null):Object(i["A"])(a)&&(s=a.cb,l=a.during,c=a.isFrom,u=a.removeOpt,a=a.dataIndex);var h="leave"===t;h||e.stopAnimation("leave");var d=o(t,r,a,h?u||{}:null,r&&r.getAnimationDelayParams?r.getAnimationDelayParams(e,a):null);if(d&&d.duration>0){var f=d.duration,p=d.delay,g=d.easing,m={duration:f,delay:p||0,easing:g,done:s,force:!!s||!!l,setToFinal:!h,scope:t,during:l};c?e.animateFrom(n,m):e.animateTo(n,m)}else e.stopAnimation(),!c&&e.attr(n),l&&l(1),s&&s()}function l(t,e,n,i,r,a){s("update",t,e,n,i,r,a)}function u(t,e,n,i,r,a){s("enter",t,e,n,i,r,a)}function c(t){if(!t.__zr)return!0;for(var e=0;ee[1]&&(e[1]=t[1])},t.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},t.prototype.getExtent=function(){return this._extent.slice()},t.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},t.prototype.isInExtentRange=function(t){return this._extent[0]<=t&&this._extent[1]>=t},t.prototype.isBlank=function(){return this._isBlank},t.prototype.setBlank=function(t){this._isBlank=t},t}();i["c"](r),e["a"]=r},e263:function(t,e,n){"use strict";n.d(e,"d",(function(){return f})),n.d(e,"c",(function(){return p})),n.d(e,"b",(function(){return v})),n.d(e,"e",(function(){return y})),n.d(e,"a",(function(){return _}));var i=n("401b"),r=n("4a3f"),a=Math.min,o=Math.max,s=Math.sin,l=Math.cos,u=2*Math.PI,c=i["e"](),h=i["e"](),d=i["e"]();function f(t,e,n){if(0!==t.length){for(var i=t[0],r=i[0],s=i[0],l=i[1],u=i[1],c=1;c1e-4)return p[0]=t-n,p[1]=e-r,g[0]=t+n,void(g[1]=e+r);if(c[0]=l(a)*n+t,c[1]=s(a)*r+e,h[0]=l(o)*n+t,h[1]=s(o)*r+e,m(p,c,h),v(g,c,h),a%=u,a<0&&(a+=u),o%=u,o<0&&(o+=u),a>o&&!f?o+=u:aa&&(d[0]=l(b)*n+t,d[1]=s(b)*r+e,m(p,d,p),v(g,d,g))}},e767:function(t,e,n){"use strict";var i=n("7a23"),r=n("313e"),a=n("aa74"),o=n("22b4"),s=(n("1be7"),n("f95e")),l=n("5e81"),u=n("ee29");Object(o["a"])([s["a"],l["a"]]);function c(t,e,n){"object"==typeof e&&(n=e,e=null);var i,r=this;if(!(t instanceof Function))for(var a in i=[],t)t.hasOwnProperty(a)&&i.push(a);var o=function(e){if(r.apply(this,arguments),t instanceof Function?h(this,t.call(this,e)):d(this,t,i),this.constructor===o)for(var n=o.__initializers__,a=0;a=this._maxSize&&n>0){var i=this._list.head;this._list.remove(i),delete this._map[i.key]}var r=this._list.insert(e);r.key=t,this._map[t]=r}},E.prototype.get=function(t){var e=this._map[t];if(this._map.hasOwnProperty(t))return e!==this._list.tail&&(this._list.remove(e),this._list.insertEntry(e)),e.value},E.prototype.remove=function(t){var e=this._map[t];"undefined"!==typeof e&&(delete this._map[t],this._list.remove(e))},E.prototype.clear=function(){this._list.clear(),this._map={}};var j=E,P={},N={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function R(t){return t=Math.round(t),t<0?0:t>255?255:t}function k(t){return t=Math.round(t),t<0?0:t>360?360:t}function B(t){return t<0?0:t>1?1:t}function z(t){return t.length&&"%"===t.charAt(t.length-1)?R(parseFloat(t)/100*255):R(parseInt(t,10))}function V(t){return t.length&&"%"===t.charAt(t.length-1)?B(parseFloat(t)/100):B(parseFloat(t))}function F(t,e,n){return n<0?n+=1:n>1&&(n-=1),6*n<1?t+(e-t)*n*6:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}function G(t,e,n){return t+(e-t)*n}function H(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function U(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var W=new j(20),X=null;function Z(t,e){X&&U(X,e),X=W.put(t,X||e.slice())}function q(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=V(t[1]),r=V(t[2]),a=r<=.5?r*(i+1):r+i-r*i,o=2*r-a;return e=e||[],H(e,R(255*F(o,a,n+1/3)),R(255*F(o,a,n)),R(255*F(o,a,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function Y(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,a=t[2]/255,o=Math.min(i,r,a),s=Math.max(i,r,a),l=s-o,u=(s+o)/2;if(0===l)e=0,n=0;else{n=u<.5?l/(s+o):l/(2-s-o);var c=((s-i)/6+l/2)/l,h=((s-r)/6+l/2)/l,d=((s-a)/6+l/2)/l;i===s?e=d-h:r===s?e=1/3+c-d:a===s&&(e=2/3+h-c),e<0&&(e+=1),e>1&&(e-=1)}var f=[360*e,n,u];return null!=t[3]&&f.push(t[3]),f}}P.parse=function(t,e){if(t){e=e||[];var n=W.get(t);if(n)return U(e,n);t+="";var i=t.replace(/ /g,"").toLowerCase();if(i in N)return U(e,N[i]),Z(t,e),e;if("#"!==i.charAt(0)){var r=i.indexOf("("),a=i.indexOf(")");if(-1!==r&&a+1===i.length){var o=i.substr(0,r),s=i.substr(r+1,a-(r+1)).split(","),l=1;switch(o){case"rgba":if(4!==s.length)return void H(e,0,0,0,1);l=V(s.pop());case"rgb":return 3!==s.length?void H(e,0,0,0,1):(H(e,z(s[0]),z(s[1]),z(s[2]),l),Z(t,e),e);case"hsla":return 4!==s.length?void H(e,0,0,0,1):(s[3]=V(s[3]),q(s,e),Z(t,e),e);case"hsl":return 3!==s.length?void H(e,0,0,0,1):(q(s,e),Z(t,e),e);default:return}}H(e,0,0,0,1)}else{if(4===i.length){var u=parseInt(i.substr(1),16);return u>=0&&u<=4095?(H(e,(3840&u)>>4|(3840&u)>>8,240&u|(240&u)>>4,15&u|(15&u)<<4,1),Z(t,e),e):void H(e,0,0,0,1)}if(7===i.length){u=parseInt(i.substr(1),16);return u>=0&&u<=16777215?(H(e,(16711680&u)>>16,(65280&u)>>8,255&u,1),Z(t,e),e):void H(e,0,0,0,1)}}}},P.parseToFloat=function(t,e){if(e=P.parse(t,e),e)return e[0]/=255,e[1]/=255,e[2]/=255,e},P.lift=function(t,e){var n=P.parse(t);if(n){for(var i=0;i<3;i++)n[i]=e<0?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0;return P.stringify(n,4===n.length?"rgba":"rgb")}},P.toHex=function(t){var e=P.parse(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)},P.fastLerp=function(t,e,n){if(e&&e.length&&t>=0&&t<=1){n=n||[];var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=e[r],s=e[a],l=i-r;return n[0]=R(G(o[0],s[0],l)),n[1]=R(G(o[1],s[1],l)),n[2]=R(G(o[2],s[2],l)),n[3]=B(G(o[3],s[3],l)),n}},P.fastMapToColor=P.fastLerp,P.lerp=function(t,e,n){if(e&&e.length&&t>=0&&t<=1){var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=P.parse(e[r]),s=P.parse(e[a]),l=i-r,u=P.stringify([R(G(o[0],s[0],l)),R(G(o[1],s[1],l)),R(G(o[2],s[2],l)),B(G(o[3],s[3],l))],"rgba");return n?{color:u,leftIndex:r,rightIndex:a,value:i}:u}},P.mapToColor=P.lerp,P.modifyHSL=function(t,e,n,i){if(t=P.parse(t),t)return t=Y(t),null!=e&&(t[0]=k(e)),null!=n&&(t[1]=V(n)),null!=i&&(t[2]=V(i)),P.stringify(q(t),"rgba")},P.modifyAlpha=function(t,e){if(t=P.parse(t),t&&null!=e)return t[3]=B(e),P.stringify(t,"rgba")},P.stringify=function(t,e){if(t&&t.length){var n=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(n+=","+t[3]),e+"("+n+")"}};var K=P,Q=K.parseToFloat,J={};function $(t){var e=Object.keys(t);e.sort();for(var n=[],i=0;i=0},getEnabledUniforms:function(){return this._enabledUniforms},getTextureUniforms:function(){return this._textureUniforms},set:function(t,e){if("object"===typeof t)for(var n in t){var i=t[n];this.setUniform(n,i)}else this.setUniform(t,e)},get:function(t){var e=this.uniforms[t];if(e)return e.value},attachShader:function(t,e){var n=this.uniforms;this.uniforms=t.createUniforms(),this.shader=t;var i=this.uniforms;this._enabledUniforms=Object.keys(i),this._enabledUniforms.sort(),this._textureUniforms=this._enabledUniforms.filter((function(t){var e=this.uniforms[t].type;return"t"===e||"tv"===e}),this);var r=this.vertexDefines,a=this.fragmentDefines;if(this.vertexDefines=x.clone(t.vertexDefines),this.fragmentDefines=x.clone(t.fragmentDefines),e){for(var o in n)i[o]&&(i[o].value=n[o].value);x.defaults(this.vertexDefines,r),x.defaults(this.fragmentDefines,a)}var s={};for(var l in t.textures)s[l]={shaderType:t.textures[l].shaderType,type:t.textures[l].type,enabled:!(!e||!this._textureStatus[l])&&this._textureStatus[l].enabled};this._textureStatus=s,this._programKey=""},clone:function(){var t=new this.constructor({name:this.name,shader:this.shader});for(var e in this.uniforms)t.uniforms[e].value=this.uniforms[e].value;return t.depthTest=this.depthTest,t.depthMask=this.depthMask,t.transparent=this.transparent,t.blend=this.blend,t.vertexDefines=x.clone(this.vertexDefines),t.fragmentDefines=x.clone(this.fragmentDefines),t.enableTexture(this.getEnabledTextures()),t.precision=this.precision,t},define:function(t,e,n){var i=this.vertexDefines,r=this.fragmentDefines;"vertex"!==t&&"fragment"!==t&&"both"!==t&&arguments.length<3&&(n=e,e=t,t="both"),n=null!=n?n:null,"vertex"!==t&&"both"!==t||i[e]!==n&&(i[e]=n,this._programKey=""),"fragment"!==t&&"both"!==t||r[e]!==n&&(r[e]=n,"both"!==t&&(this._programKey=""))},undefine:function(t,e){"vertex"!==t&&"fragment"!==t&&"both"!==t&&arguments.length<2&&(e=t,t="both"),"vertex"!==t&&"both"!==t||this.isDefined("vertex",e)&&(delete this.vertexDefines[e],this._programKey=""),"fragment"!==t&&"both"!==t||this.isDefined("fragment",e)&&(delete this.fragmentDefines[e],"both"!==t&&(this._programKey=""))},isDefined:function(t,e){switch(t){case"vertex":return void 0!==this.vertexDefines[e];case"fragment":return void 0!==this.fragmentDefines[e]}},getDefine:function(t,e){switch(t){case"vertex":return this.vertexDefines[e];case"fragment":return this.fragmentDefines[e]}},enableTexture:function(t){if(Array.isArray(t))for(var e=0;e0&&(r=1/Math.sqrt(r),t[0]=e[0]*r,t[1]=e[1]*r),t},ot.dot=function(t,e){return t[0]*e[0]+t[1]*e[1]},ot.cross=function(t,e,n){var i=e[0]*n[1]-e[1]*n[0];return t[0]=t[1]=0,t[2]=i,t},ot.lerp=function(t,e,n,i){var r=e[0],a=e[1];return t[0]=r+i*(n[0]-r),t[1]=a+i*(n[1]-a),t},ot.random=function(t,e){e=e||1;var n=2*GLMAT_RANDOM()*Math.PI;return t[0]=Math.cos(n)*e,t[1]=Math.sin(n)*e,t},ot.transformMat2=function(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r,t[1]=n[1]*i+n[3]*r,t},ot.transformMat2d=function(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t},ot.transformMat3=function(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[3]*r+n[6],t[1]=n[1]*i+n[4]*r+n[7],t},ot.transformMat4=function(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[4]*r+n[12],t[1]=n[1]*i+n[5]*r+n[13],t},ot.forEach=function(){var t=ot.create();return function(e,n,i,r,a,o){var s,l;for(n||(n=2),i||(i=0),l=r?Math.min(r*n+i,e.length):e.length,s=i;s0&&i.push("#define "+r.toUpperCase()+"_COUNT "+a)}if(n)for(var o=0;ou.getMaxJointNumber()&&(f.USE_SKIN_MATRICES_TEXTURE=null),d+="\n"+wt(f)+"\n"}a&&(d+="\n#define INSTANCING\n");var p=d+wt(e.vertexDefines,l,h),g=d+wt(e.fragmentDefines,l,h),m=p+"\n"+e.shader.vertex,v=["OES_standard_derivatives","EXT_shader_texture_lod"].filter((function(t){return null!=u.getGLExtension(t)}));v.indexOf("EXT_shader_texture_lod")>=0&&(g+="\n#define SUPPORT_TEXTURE_LOD"),v.indexOf("OES_standard_derivatives")>=0&&(g+="\n#define SUPPORT_STANDARD_DERIVATIVES");var y=Ot(v)+"\n"+St(e.precision)+"\n"+g+"\n"+e.shader.fragment,_=xt(m,e.vertexDefines,l),b=xt(y,e.fragmentDefines,l);s=new _t;s.uniformSemantics=e.shader.uniformSemantics,s.attributes=e.shader.attributes;var x=s.buildProgram(c,e.shader,_,b);return s.__error=x,i[o]=s,s};var Mt=Tt,At=/uniform\s+(bool|float|int|vec2|vec3|vec4|ivec2|ivec3|ivec4|mat2|mat3|mat4|sampler2D|samplerCube)\s+([\s\S]*?);/g,Ct=/attribute\s+(float|int|vec2|vec3|vec4)\s+([\s\S]*?);/g,It=/#define\s+(\w+)?(\s+[\d-.]+)?\s*;?\s*\n/g,Dt={bool:"1i",int:"1i",sampler2D:"t",samplerCube:"t",float:"1f",vec2:"2f",vec3:"3f",vec4:"4f",ivec2:"2i",ivec3:"3i",ivec4:"4i",mat2:"m2",mat3:"m3",mat4:"m4"};function Lt(t){for(var e=[],n=0;n=0){if(f!==l&&f!==h){Ft();break}f=u,g=[]}else if(f!==l)if(f!==h)m(v),f=s;else{var y=v;jt.indexOf(y)>=0||Pt.indexOf(y)>=0||Nt.indexOf(y)>=0?p[o].semantic=y:"ignore"===y||"unconfigurable"===y?p[o].ignore=!0:p[o].value="bool"===t?"true"===y:parseFloat(y)}else p[o].value="bool"===t?"true"===v:parseFloat(v),g=null;else{if(f!==u){Ft();break}if(!(g instanceof Array)){Ft();break}g.push(+i[++a])}else p[o].value=new I["a"].Float32Array(g),g=null,f=d;else if(f===u){if(!(g instanceof Array)){Ft();break}g.push(+i[++a])}else f=d;else f=h;else{if(f!==s&&f!==c){Ft();break}f=l}}return p}function Ht(t,e){"object"===typeof t&&(e=t.fragment,t=t.vertex),t=Vt(t),e=Vt(e),this._shaderID=zt(t,e),this._vertexCode=Ht.parseImport(t),this._fragmentCode=Ht.parseImport(e),this.attributeSemantics={},this.matrixSemantics={},this.uniformSemantics={},this.matrixSemanticKeys=[],this.uniformTemplates={},this.attributes={},this.textures={},this.vertexDefines={},this.fragmentDefines={},this._parseAttributes(),this._parseUniforms(),this._parseDefines()}Ht.prototype={constructor:Ht,createUniforms:function(){var t={};for(var e in this.uniformTemplates){var n=this.uniformTemplates[e];t[e]={type:n.type,value:n.value()}}return t},_parseImport:function(){this._vertexCode=Ht.parseImport(this.vertex),this._fragmentCode=Ht.parseImport(this.fragment)},_addSemanticUniform:function(t,e,n){if(jt.indexOf(n)>=0)this.attributeSemantics[n]={symbol:t,type:e};else if(Nt.indexOf(n)>=0){var i=!1,r=n;n.match(/TRANSPOSE$/)&&(i=!0,r=n.slice(0,-9)),this.matrixSemantics[n]={symbol:t,type:e,isTranspose:i,semanticNoTranspose:r}}else Pt.indexOf(n)>=0&&(this.uniformSemantics[n]={symbol:t,type:e})},_addMaterialUniform:function(t,e,n,i,r,a){a[t]={type:n,value:r?Et["array"]:i||Et[e],semantic:null}},_parseUniforms:function(){var t={},e=this,n="vertex";function i(t){return null!=t?function(){return t}:null}function r(r,a,o){var s=Gt(a,o),l=[];for(var u in s){var c=s[u],h=c.semantic,d=u,f=Dt[a],p=i(s[u].value);s[u].isArray&&(d+="["+s[u].arraySize+"]",f+="v"),l.push(d),e._uniformList.push(u),c.ignore||("sampler2D"!==a&&"samplerCube"!==a||(e.textures[u]={shaderType:n,type:a}),h?e._addSemanticUniform(u,f,h):e._addMaterialUniform(u,a,f,p,s[u].isArray,t))}return l.length>0?"uniform "+a+" "+l.join(",")+";\n":""}this._uniformList=[],this._vertexCode=this._vertexCode.replace(At,r),n="fragment",this._fragmentCode=this._fragmentCode.replace(At,r),e.matrixSemanticKeys=Object.keys(this.matrixSemantics),this.uniformTemplates=t},_parseAttributes:function(){var t={},e=this;function n(n,i,r){var a=Gt(i,r),o=Rt[i]||1,s=[];for(var l in a){var u=a[l].semantic;if(t[l]={type:"float",size:o,semantic:u||null},u){if(jt.indexOf(u)<0)throw new Error('Unkown semantic "'+u+'"');e.attributeSemantics[u]={symbol:l,type:i}}s.push(l)}return"attribute "+i+" "+s.join(",")+";\n"}this._vertexCode=this._vertexCode.replace(Ct,n),this.attributes=t},_parseDefines:function(){var t=this,e="vertex";function n(n,i,r){var a="vertex"===e?t.vertexDefines:t.fragmentDefines;return a[i]||(a[i]="false"!==r&&("true"===r||(r?isNaN(parseFloat(r))?r.trim():parseFloat(r):null))),""}this._vertexCode=this._vertexCode.replace(It,n),e="fragment",this._fragmentCode=this._fragmentCode.replace(It,n)},clone:function(){var t=Bt[this._shaderID],e=new Ht(t.vertex,t.fragment);return e}},Object.defineProperty&&(Object.defineProperty(Ht.prototype,"shaderID",{get:function(){return this._shaderID}}),Object.defineProperty(Ht.prototype,"vertex",{get:function(){return this._vertexCode}}),Object.defineProperty(Ht.prototype,"fragment",{get:function(){return this._fragmentCode}}),Object.defineProperty(Ht.prototype,"uniforms",{get:function(){return this._uniformList}}));var Ut=/(@import)\s*([0-9a-zA-Z_\-\.]*)/g;Ht.parseImport=function(t){return t=t.replace(Ut,(function(t,e,n){t=Ht.source(n);return t?Ht.parseImport(t):(console.error('Shader chunk "'+n+'" not existed in library'),"")})),t};var Wt=/(@export)\s*([0-9a-zA-Z_\-\.]*)\s*\n([\s\S]*?)@end/g;Ht["import"]=function(t){t.replace(Wt,(function(t,e,n,i){i=i.replace(/(^[\s\t\xa0\u3000]+)|([\u3000\xa0\s\t]+\x24)/g,"");if(i){var r,a=n.split("."),o=Ht.codes,s=0;while(s 0.0) {\n if (texture2D(alphaMap, v_Texcoord).a <= alphaCutoff) {\n discard;\n }\n }\n gl_FragColor = vec4(0.0,0.0,0.0,1.0);\n}\n@end",qt={create:function(){var t=new rt(16);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},clone:function(t){var e=new rt(16);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t},identity:function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},transpose:function(t,e){if(t===e){var n=e[1],i=e[2],r=e[3],a=e[6],o=e[7],s=e[11];t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=n,t[6]=e[9],t[7]=e[13],t[8]=i,t[9]=a,t[11]=e[14],t[12]=r,t[13]=o,t[14]=s}else t[0]=e[0],t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=e[1],t[5]=e[5],t[6]=e[9],t[7]=e[13],t[8]=e[2],t[9]=e[6],t[10]=e[10],t[11]=e[14],t[12]=e[3],t[13]=e[7],t[14]=e[11],t[15]=e[15];return t},invert:function(t,e){var n=e[0],i=e[1],r=e[2],a=e[3],o=e[4],s=e[5],l=e[6],u=e[7],c=e[8],h=e[9],d=e[10],f=e[11],p=e[12],g=e[13],m=e[14],v=e[15],y=n*s-i*o,_=n*l-r*o,b=n*u-a*o,x=i*l-r*s,w=i*u-a*s,O=r*u-a*l,S=c*g-h*p,T=c*m-d*p,M=c*v-f*p,A=h*m-d*g,C=h*v-f*g,I=d*v-f*m,D=y*I-_*C+b*A+x*M-w*T+O*S;return D?(D=1/D,t[0]=(s*I-l*C+u*A)*D,t[1]=(r*C-i*I-a*A)*D,t[2]=(g*O-m*w+v*x)*D,t[3]=(d*w-h*O-f*x)*D,t[4]=(l*M-o*I-u*T)*D,t[5]=(n*I-r*M+a*T)*D,t[6]=(m*b-p*O-v*_)*D,t[7]=(c*O-d*b+f*_)*D,t[8]=(o*C-s*M+u*S)*D,t[9]=(i*M-n*C-a*S)*D,t[10]=(p*w-g*b+v*y)*D,t[11]=(h*b-c*w-f*y)*D,t[12]=(s*T-o*A-l*S)*D,t[13]=(n*A-i*T+r*S)*D,t[14]=(g*_-p*x-m*y)*D,t[15]=(c*x-h*_+d*y)*D,t):null},adjoint:function(t,e){var n=e[0],i=e[1],r=e[2],a=e[3],o=e[4],s=e[5],l=e[6],u=e[7],c=e[8],h=e[9],d=e[10],f=e[11],p=e[12],g=e[13],m=e[14],v=e[15];return t[0]=s*(d*v-f*m)-h*(l*v-u*m)+g*(l*f-u*d),t[1]=-(i*(d*v-f*m)-h*(r*v-a*m)+g*(r*f-a*d)),t[2]=i*(l*v-u*m)-s*(r*v-a*m)+g*(r*u-a*l),t[3]=-(i*(l*f-u*d)-s*(r*f-a*d)+h*(r*u-a*l)),t[4]=-(o*(d*v-f*m)-c*(l*v-u*m)+p*(l*f-u*d)),t[5]=n*(d*v-f*m)-c*(r*v-a*m)+p*(r*f-a*d),t[6]=-(n*(l*v-u*m)-o*(r*v-a*m)+p*(r*u-a*l)),t[7]=n*(l*f-u*d)-o*(r*f-a*d)+c*(r*u-a*l),t[8]=o*(h*v-f*g)-c*(s*v-u*g)+p*(s*f-u*h),t[9]=-(n*(h*v-f*g)-c*(i*v-a*g)+p*(i*f-a*h)),t[10]=n*(s*v-u*g)-o*(i*v-a*g)+p*(i*u-a*s),t[11]=-(n*(s*f-u*h)-o*(i*f-a*h)+c*(i*u-a*s)),t[12]=-(o*(h*m-d*g)-c*(s*m-l*g)+p*(s*d-l*h)),t[13]=n*(h*m-d*g)-c*(i*m-r*g)+p*(i*d-r*h),t[14]=-(n*(s*m-l*g)-o*(i*m-r*g)+p*(i*l-r*s)),t[15]=n*(s*d-l*h)-o*(i*d-r*h)+c*(i*l-r*s),t},determinant:function(t){var e=t[0],n=t[1],i=t[2],r=t[3],a=t[4],o=t[5],s=t[6],l=t[7],u=t[8],c=t[9],h=t[10],d=t[11],f=t[12],p=t[13],g=t[14],m=t[15],v=e*o-n*a,y=e*s-i*a,_=e*l-r*a,b=n*s-i*o,x=n*l-r*o,w=i*l-r*s,O=u*p-c*f,S=u*g-h*f,T=u*m-d*f,M=c*g-h*p,A=c*m-d*p,C=h*m-d*g;return v*C-y*A+_*M+b*T-x*S+w*O},multiply:function(t,e,n){var i=e[0],r=e[1],a=e[2],o=e[3],s=e[4],l=e[5],u=e[6],c=e[7],h=e[8],d=e[9],f=e[10],p=e[11],g=e[12],m=e[13],v=e[14],y=e[15],_=n[0],b=n[1],x=n[2],w=n[3];return t[0]=_*i+b*s+x*h+w*g,t[1]=_*r+b*l+x*d+w*m,t[2]=_*a+b*u+x*f+w*v,t[3]=_*o+b*c+x*p+w*y,_=n[4],b=n[5],x=n[6],w=n[7],t[4]=_*i+b*s+x*h+w*g,t[5]=_*r+b*l+x*d+w*m,t[6]=_*a+b*u+x*f+w*v,t[7]=_*o+b*c+x*p+w*y,_=n[8],b=n[9],x=n[10],w=n[11],t[8]=_*i+b*s+x*h+w*g,t[9]=_*r+b*l+x*d+w*m,t[10]=_*a+b*u+x*f+w*v,t[11]=_*o+b*c+x*p+w*y,_=n[12],b=n[13],x=n[14],w=n[15],t[12]=_*i+b*s+x*h+w*g,t[13]=_*r+b*l+x*d+w*m,t[14]=_*a+b*u+x*f+w*v,t[15]=_*o+b*c+x*p+w*y,t},multiplyAffine:function(t,e,n){var i=e[0],r=e[1],a=e[2],o=e[4],s=e[5],l=e[6],u=e[8],c=e[9],h=e[10],d=e[12],f=e[13],p=e[14],g=n[0],m=n[1],v=n[2];return t[0]=g*i+m*o+v*u,t[1]=g*r+m*s+v*c,t[2]=g*a+m*l+v*h,g=n[4],m=n[5],v=n[6],t[4]=g*i+m*o+v*u,t[5]=g*r+m*s+v*c,t[6]=g*a+m*l+v*h,g=n[8],m=n[9],v=n[10],t[8]=g*i+m*o+v*u,t[9]=g*r+m*s+v*c,t[10]=g*a+m*l+v*h,g=n[12],m=n[13],v=n[14],t[12]=g*i+m*o+v*u+d,t[13]=g*r+m*s+v*c+f,t[14]=g*a+m*l+v*h+p,t}};qt.mul=qt.multiply,qt.mulAffine=qt.multiplyAffine,qt.translate=function(t,e,n){var i,r,a,o,s,l,u,c,h,d,f,p,g=n[0],m=n[1],v=n[2];return e===t?(t[12]=e[0]*g+e[4]*m+e[8]*v+e[12],t[13]=e[1]*g+e[5]*m+e[9]*v+e[13],t[14]=e[2]*g+e[6]*m+e[10]*v+e[14],t[15]=e[3]*g+e[7]*m+e[11]*v+e[15]):(i=e[0],r=e[1],a=e[2],o=e[3],s=e[4],l=e[5],u=e[6],c=e[7],h=e[8],d=e[9],f=e[10],p=e[11],t[0]=i,t[1]=r,t[2]=a,t[3]=o,t[4]=s,t[5]=l,t[6]=u,t[7]=c,t[8]=h,t[9]=d,t[10]=f,t[11]=p,t[12]=i*g+s*m+h*v+e[12],t[13]=r*g+l*m+d*v+e[13],t[14]=a*g+u*m+f*v+e[14],t[15]=o*g+c*m+p*v+e[15]),t},qt.scale=function(t,e,n){var i=n[0],r=n[1],a=n[2];return t[0]=e[0]*i,t[1]=e[1]*i,t[2]=e[2]*i,t[3]=e[3]*i,t[4]=e[4]*r,t[5]=e[5]*r,t[6]=e[6]*r,t[7]=e[7]*r,t[8]=e[8]*a,t[9]=e[9]*a,t[10]=e[10]*a,t[11]=e[11]*a,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t},qt.rotate=function(t,e,n,i){var r,a,o,s,l,u,c,h,d,f,p,g,m,v,y,_,b,x,w,O,S,T,M,A,C=i[0],I=i[1],D=i[2],L=Math.sqrt(C*C+I*I+D*D);return Math.abs(L)0&&(a=1/Math.sqrt(a),t[0]=e[0]*a,t[1]=e[1]*a,t[2]=e[2]*a),t},Kt.dot=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]},Kt.cross=function(t,e,n){var i=e[0],r=e[1],a=e[2],o=n[0],s=n[1],l=n[2];return t[0]=r*l-a*s,t[1]=a*o-i*l,t[2]=i*s-r*o,t},Kt.lerp=function(t,e,n,i){var r=e[0],a=e[1],o=e[2];return t[0]=r+i*(n[0]-r),t[1]=a+i*(n[1]-a),t[2]=o+i*(n[2]-o),t},Kt.random=function(t,e){e=e||1;var n=2*at()*Math.PI,i=2*at()-1,r=Math.sqrt(1-i*i)*e;return t[0]=Math.cos(n)*r,t[1]=Math.sin(n)*r,t[2]=i*e,t},Kt.transformMat4=function(t,e,n){var i=e[0],r=e[1],a=e[2],o=n[3]*i+n[7]*r+n[11]*a+n[15];return o=o||1,t[0]=(n[0]*i+n[4]*r+n[8]*a+n[12])/o,t[1]=(n[1]*i+n[5]*r+n[9]*a+n[13])/o,t[2]=(n[2]*i+n[6]*r+n[10]*a+n[14])/o,t},Kt.transformMat3=function(t,e,n){var i=e[0],r=e[1],a=e[2];return t[0]=i*n[0]+r*n[3]+a*n[6],t[1]=i*n[1]+r*n[4]+a*n[7],t[2]=i*n[2]+r*n[5]+a*n[8],t},Kt.transformQuat=function(t,e,n){var i=e[0],r=e[1],a=e[2],o=n[0],s=n[1],l=n[2],u=n[3],c=u*i+s*a-l*r,h=u*r+l*i-o*a,d=u*a+o*r-s*i,f=-o*i-s*r-l*a;return t[0]=c*u+f*-o+h*-l-d*-s,t[1]=h*u+f*-s+d*-o-c*-l,t[2]=d*u+f*-l+c*-s-h*-o,t},Kt.rotateX=function(t,e,n,i){var r=[],a=[];return r[0]=e[0]-n[0],r[1]=e[1]-n[1],r[2]=e[2]-n[2],a[0]=r[0],a[1]=r[1]*Math.cos(i)-r[2]*Math.sin(i),a[2]=r[1]*Math.sin(i)+r[2]*Math.cos(i),t[0]=a[0]+n[0],t[1]=a[1]+n[1],t[2]=a[2]+n[2],t},Kt.rotateY=function(t,e,n,i){var r=[],a=[];return r[0]=e[0]-n[0],r[1]=e[1]-n[1],r[2]=e[2]-n[2],a[0]=r[2]*Math.sin(i)+r[0]*Math.cos(i),a[1]=r[1],a[2]=r[2]*Math.cos(i)-r[0]*Math.sin(i),t[0]=a[0]+n[0],t[1]=a[1]+n[1],t[2]=a[2]+n[2],t},Kt.rotateZ=function(t,e,n,i){var r=[],a=[];return r[0]=e[0]-n[0],r[1]=e[1]-n[1],r[2]=e[2]-n[2],a[0]=r[0]*Math.cos(i)-r[1]*Math.sin(i),a[1]=r[0]*Math.sin(i)+r[1]*Math.cos(i),a[2]=r[2],t[0]=a[0]+n[0],t[1]=a[1]+n[1],t[2]=a[2]+n[2],t},Kt.forEach=function(){var t=Kt.create();return function(e,n,i,r,a,o){var s,l;for(n||(n=3),i||(i=0),l=r?Math.min(r*n+i,e.length):e.length,s=i;s1?0:Math.acos(r)};var Qt=Kt;Xt["import"](Zt);var Jt=Yt.create,$t={};function te(t){return t.material}function ee(t,e,n){return e.uniforms[n].value}function ne(t,e,n,i){return n!==i}function ie(t){return!0}function re(){}var ae={float:C.FLOAT,byte:C.BYTE,ubyte:C.UNSIGNED_BYTE,short:C.SHORT,ushort:C.UNSIGNED_SHORT};function oe(t,e,n){this.availableAttributes=t,this.availableAttributeSymbols=e,this.indicesBuffer=n,this.vao=null}function se(t){var e,n;this.bind=function(t){e||(e=I["a"].createCanvas(),e.width=e.height=1,e.getContext("2d"));var i=t.gl,r=!n;r&&(n=i.createTexture()),i.bindTexture(i.TEXTURE_2D,n),r&&i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,e)},this.unbind=function(t){t.gl.bindTexture(t.gl.TEXTURE_2D,null)},this.isRenderable=function(){return!0}}var le=O.extend((function(){return{canvas:null,_width:100,_height:100,devicePixelRatio:"undefined"!==typeof window&&window.devicePixelRatio||1,clearColor:[0,0,0,0],clearBit:17664,alpha:!0,depth:!0,stencil:!1,antialias:!0,premultipliedAlpha:!0,preserveDrawingBuffer:!1,throwError:!0,gl:null,viewport:{},maxJointNumber:20,__currentFrameBuffer:null,_viewportStack:[],_clearStack:[],_sceneRendering:null}}),(function(){this.canvas||(this.canvas=I["a"].createCanvas());var t=this.canvas;try{var e={alpha:this.alpha,depth:this.depth,stencil:this.stencil,antialias:this.antialias,premultipliedAlpha:this.premultipliedAlpha,preserveDrawingBuffer:this.preserveDrawingBuffer};if(this.gl=t.getContext("webgl",e)||t.getContext("experimental-webgl",e),!this.gl)throw new Error;this._glinfo=new A(this.gl),this.gl.targetRenderer&&console.error("Already created a renderer"),this.gl.targetRenderer=this,this.resize()}catch(n){throw"Error creating WebGL Context "+n}this._programMgr=new Mt(this),this._placeholderTexture=new se(this)}),{resize:function(t,e){var n=this.canvas,i=this.devicePixelRatio;null!=t?(n.style&&(n.style.width=t+"px",n.style.height=e+"px"),n.width=t*i,n.height=e*i,this._width=t,this._height=e):(this._width=n.width/i,this._height=n.height/i),this.setViewport(0,0,this._width,this._height)},getWidth:function(){return this._width},getHeight:function(){return this._height},getViewportAspect:function(){var t=this.viewport;return t.width/t.height},setDevicePixelRatio:function(t){this.devicePixelRatio=t,this.resize(this._width,this._height)},getDevicePixelRatio:function(){return this.devicePixelRatio},getGLExtension:function(t){return this._glinfo.getExtension(t)},getGLParameter:function(t){return this._glinfo.getParameter(t)},setViewport:function(t,e,n,i,r){if("object"===typeof t){var a=t;t=a.x,e=a.y,n=a.width,i=a.height,r=a.devicePixelRatio}r=r||this.devicePixelRatio,this.gl.viewport(t*r,e*r,n*r,i*r),this.viewport={x:t,y:e,width:n,height:i,devicePixelRatio:r}},saveViewport:function(){this._viewportStack.push(this.viewport)},restoreViewport:function(){this._viewportStack.length>0&&this.setViewport(this._viewportStack.pop())},saveClear:function(){this._clearStack.push({clearBit:this.clearBit,clearColor:this.clearColor})},restoreClear:function(){if(this._clearStack.length>0){var t=this._clearStack.pop();this.clearColor=t.clearColor,this.clearBit=t.clearBit}},bindSceneRendering:function(t){this._sceneRendering=t},render:function(t,e,n,i){var r=this.gl,a=this.clearColor;if(this.clearBit){r.colorMask(!0,!0,!0,!0),r.depthMask(!0);var o=this.viewport,s=!1,l=o.devicePixelRatio;(o.width!==this._width||o.height!==this._height||l&&l!==this.devicePixelRatio||o.x||o.y)&&(s=!0,r.enable(r.SCISSOR_TEST),r.scissor(o.x*l,o.y*l,o.width*l,o.height*l)),r.clearColor(a[0],a[1],a[2],a[3]),r.clear(this.clearBit),s&&r.disable(r.SCISSOR_TEST)}if(n||t.update(!1),t.updateLights(),e=e||t.getMainCamera(),e){e.update();var u=t.updateRenderList(e,!0);this._sceneRendering=t;var c=u.opaque,h=u.transparent,d=t.material;t.trigger("beforerender",this,t,e,u),i?(this.renderPreZ(c,t,e),r.depthFunc(r.LEQUAL)):r.depthFunc(r.LESS);for(var f=Jt(),p=Qt.create(),g=0;g0){var s=t[r-1],l=s.joints?s.joints.length:0,u=a.joints?a.joints.length:0;if(u===l&&a.material===s.material&&a.lightGroup===s.lightGroup){a.__program=s.__program;continue}}var c=this._programMgr.getProgram(a,o,e);this.validateProgram(c),a.__program=c}},renderPass:function(t,e,n){this.trigger("beforerenderpass",this,t,e,n),n=n||{},n.getMaterial=n.getMaterial||te,n.getUniform=n.getUniform||ee,n.isMaterialChanged=n.isMaterialChanged||ne,n.beforeRender=n.beforeRender||re,n.afterRender=n.afterRender||re;var i=n.ifRender||ie;this.updatePrograms(t,this._sceneRendering,n),n.sortCompare&&t.sort(n.sortCompare);var r=this.viewport,a=r.devicePixelRatio,o=[r.x*a,r.y*a,r.width*a,r.height*a],s=this.devicePixelRatio,l=this.__currentFrameBuffer?[this.__currentFrameBuffer.getTextureWidth(),this.__currentFrameBuffer.getTextureHeight()]:[this._width*s,this._height*s],u=[o[2],o[3]],c=Date.now();e?(Yt.copy(ue.VIEW,e.viewMatrix.array),Yt.copy(ue.PROJECTION,e.projectionMatrix.array),Yt.copy(ue.VIEWINVERSE,e.worldTransform.array)):(Yt.identity(ue.VIEW),Yt.identity(ue.PROJECTION),Yt.identity(ue.VIEWINVERSE)),Yt.multiply(ue.VIEWPROJECTION,ue.PROJECTION,ue.VIEW),Yt.invert(ue.PROJECTIONINVERSE,ue.PROJECTION),Yt.invert(ue.VIEWPROJECTIONINVERSE,ue.VIEWPROJECTION);for(var h,d,f,p,g,m,v,y,_,b,x,w,O=this.gl,S=this._sceneRendering,T=null,M=0;Mthis.getMaxJointNumber()){var a=r.getSubSkinMatricesTexture(t.__uid__,t.joints);e.useTextureSlot(this,a,n),e.setUniform(i,"1i","skinMatricesTexture",n),e.setUniform(i,"1f","skinMatricesTextureSize",a.width)}else{var o=r.getSubSkinMatrices(t.__uid__,t.joints);e.setUniformOfSemantic(i,"SKIN_MATRIX",o)}},_renderObject:function(t,e,n){var i=this.gl,r=t.geometry,a=t.mode;null==a&&(a=4);var o=null,s=t.isInstancedMesh&&t.isInstancedMesh();if(!s||(o=this.getGLExtension("ANGLE_instanced_arrays"),o)){var l;if(s&&(l=this._bindInstancedAttributes(t,n,o)),e.indicesBuffer){var u=this.getGLExtension("OES_element_index_uint"),c=u&&r.indices instanceof Uint32Array,h=c?i.UNSIGNED_INT:i.UNSIGNED_SHORT;s?o.drawElementsInstancedANGLE(a,e.indicesBuffer.count,h,0,t.getInstanceCount()):i.drawElements(a,e.indicesBuffer.count,h,0)}else s?o.drawArraysInstancedANGLE(a,0,r.vertexCount,t.getInstanceCount()):i.drawArrays(a,0,r.vertexCount);if(s)for(var d=0;dn?n:t}he.add=function(t,e,n){return Qt.add(t.array,e.array,n.array),t._dirty=!0,t},he.set=function(t,e,n,i){Qt.set(t.array,e,n,i),t._dirty=!0},he.copy=function(t,e){return Qt.copy(t.array,e.array),t._dirty=!0,t},he.cross=function(t,e,n){return Qt.cross(t.array,e.array,n.array),t._dirty=!0,t},he.dist=function(t,e){return Qt.distance(t.array,e.array)},he.distance=he.dist,he.div=function(t,e,n){return Qt.divide(t.array,e.array,n.array),t._dirty=!0,t},he.divide=he.div,he.dot=function(t,e){return Qt.dot(t.array,e.array)},he.len=function(t){return Qt.length(t.array)},he.lerp=function(t,e,n,i){return Qt.lerp(t.array,e.array,n.array,i),t._dirty=!0,t},he.min=function(t,e,n){return Qt.min(t.array,e.array,n.array),t._dirty=!0,t},he.max=function(t,e,n){return Qt.max(t.array,e.array,n.array),t._dirty=!0,t},he.mul=function(t,e,n){return Qt.multiply(t.array,e.array,n.array),t._dirty=!0,t},he.multiply=he.mul,he.negate=function(t,e){return Qt.negate(t.array,e.array),t._dirty=!0,t},he.normalize=function(t,e){return Qt.normalize(t.array,e.array),t._dirty=!0,t},he.random=function(t,e){return Qt.random(t.array,e),t._dirty=!0,t},he.scale=function(t,e,n){return Qt.scale(t.array,e.array,n),t._dirty=!0,t},he.scaleAndAdd=function(t,e,n,i){return Qt.scaleAndAdd(t.array,e.array,n.array,i),t._dirty=!0,t},he.sqrDist=function(t,e){return Qt.sqrDist(t.array,e.array)},he.squaredDistance=he.sqrDist,he.sqrLen=function(t){return Qt.sqrLen(t.array)},he.squaredLength=he.sqrLen,he.sub=function(t,e,n){return Qt.subtract(t.array,e.array,n.array),t._dirty=!0,t},he.subtract=he.sub,he.transformMat3=function(t,e,n){return Qt.transformMat3(t.array,e.array,n.array),t._dirty=!0,t},he.transformMat4=function(t,e,n){return Qt.transformMat4(t.array,e.array,n.array),t._dirty=!0,t},he.transformQuat=function(t,e,n){return Qt.transformQuat(t.array,e.array,n.array),t._dirty=!0,t};var ge=Math.atan2,me=Math.asin,ve=Math.abs;he.eulerFromQuat=function(t,e,n){t._dirty=!0,e=e.array;var i=t.array,r=e[0],a=e[1],o=e[2],s=e[3],l=r*r,u=a*a,c=o*o,h=s*s;n=(n||"XYZ").toUpperCase();switch(n){case"XYZ":i[0]=ge(2*(r*s-a*o),h-l-u+c),i[1]=me(pe(2*(r*o+a*s),-1,1)),i[2]=ge(2*(o*s-r*a),h+l-u-c);break;case"YXZ":i[0]=me(pe(2*(r*s-a*o),-1,1)),i[1]=ge(2*(r*o+a*s),h-l-u+c),i[2]=ge(2*(r*a+o*s),h-l+u-c);break;case"ZXY":i[0]=me(pe(2*(r*s+a*o),-1,1)),i[1]=ge(2*(a*s-o*r),h-l-u+c),i[2]=ge(2*(o*s-r*a),h-l+u-c);break;case"ZYX":i[0]=ge(2*(r*s+o*a),h-l-u+c),i[1]=me(pe(2*(a*s-r*o),-1,1)),i[2]=ge(2*(r*a+o*s),h+l-u-c);break;case"YZX":i[0]=ge(2*(r*s-o*a),h-l+u-c),i[1]=ge(2*(a*s-r*o),h+l-u-c),i[2]=me(pe(2*(r*a+o*s),-1,1));break;case"XZY":i[0]=ge(2*(r*s+a*o),h-l+u-c),i[1]=ge(2*(r*o+a*s),h+l-u-c),i[2]=me(pe(2*(o*s-r*a),-1,1));break;default:console.warn("Unkown order: "+n)}return t},he.eulerFromMat3=function(t,e,n){var i=e.array,r=i[0],a=i[3],o=i[6],s=i[1],l=i[4],u=i[7],c=i[2],h=i[5],d=i[8],f=t.array;n=(n||"XYZ").toUpperCase();switch(n){case"XYZ":f[1]=me(pe(o,-1,1)),ve(o)<.99999?(f[0]=ge(-u,d),f[2]=ge(-a,r)):(f[0]=ge(h,l),f[2]=0);break;case"YXZ":f[0]=me(-pe(u,-1,1)),ve(u)<.99999?(f[1]=ge(o,d),f[2]=ge(s,l)):(f[1]=ge(-c,r),f[2]=0);break;case"ZXY":f[0]=me(pe(h,-1,1)),ve(h)<.99999?(f[1]=ge(-c,d),f[2]=ge(-a,l)):(f[1]=0,f[2]=ge(s,r));break;case"ZYX":f[1]=me(-pe(c,-1,1)),ve(c)<.99999?(f[0]=ge(h,d),f[2]=ge(s,r)):(f[0]=0,f[2]=ge(-a,l));break;case"YZX":f[2]=me(pe(s,-1,1)),ve(s)<.99999?(f[0]=ge(-u,l),f[1]=ge(-c,r)):(f[0]=0,f[1]=ge(o,d));break;case"XZY":f[2]=me(-pe(a,-1,1)),ve(a)<.99999?(f[0]=ge(h,l),f[1]=ge(o,r)):(f[0]=ge(-u,d),f[1]=0);break;default:console.warn("Unkown order: "+n)}return t._dirty=!0,t},Object.defineProperties(he,{POSITIVE_X:{get:function(){return new he(1,0,0)}},NEGATIVE_X:{get:function(){return new he(-1,0,0)}},POSITIVE_Y:{get:function(){return new he(0,1,0)}},NEGATIVE_Y:{get:function(){return new he(0,-1,0)}},POSITIVE_Z:{get:function(){return new he(0,0,1)}},NEGATIVE_Z:{get:function(){return new he(0,0,-1)}},UP:{get:function(){return new he(0,1,0)}},ZERO:{get:function(){return new he}}});var ye=he,_e=1e-5,be=function(t,e){this.origin=t||new ye,this.direction=e||new ye};be.prototype={constructor:be,intersectPlane:function(t,e){var n=t.normal.array,i=t.distance,r=this.origin.array,a=this.direction.array,o=Qt.dot(n,a);if(0===o)return null;e||(e=new ye);var s=(Qt.dot(n,r)-i)/o;return Qt.scaleAndAdd(e.array,r,a,-s),e._dirty=!0,e},mirrorAgainstPlane:function(t){var e=Qt.dot(t.normal.array,this.direction.array);Qt.scaleAndAdd(this.direction.array,this.direction.array,t.normal.array,2*-e),this.direction._dirty=!0},distanceToPoint:function(){var t=Qt.create();return function(e){Qt.sub(t,e,this.origin.array);var n=Qt.dot(t,this.direction.array);if(n<0)return Qt.distance(this.origin.array,e);var i=Qt.lenSquared(t);return Math.sqrt(i-n*n)}}(),intersectSphere:function(){var t=Qt.create();return function(e,n,i){var r=this.origin.array,a=this.direction.array;e=e.array,Qt.sub(t,e,r);var o=Qt.dot(t,a),s=Qt.squaredLength(t),l=s-o*o,u=n*n;if(!(l>u)){var c=Math.sqrt(u-l),h=o-c,d=o+c;return i||(i=new ye),h<0?d<0?null:(Qt.scaleAndAdd(i.array,r,a,d),i):(Qt.scaleAndAdd(i.array,r,a,h),i)}}}(),intersectBoundingBox:function(t,e){var n,i,r,a,o,s,l=this.direction.array,u=this.origin.array,c=t.min.array,h=t.max.array,d=1/l[0],f=1/l[1],p=1/l[2];if(d>=0?(n=(c[0]-u[0])*d,i=(h[0]-u[0])*d):(i=(c[0]-u[0])*d,n=(h[0]-u[0])*d),f>=0?(r=(c[1]-u[1])*f,a=(h[1]-u[1])*f):(a=(c[1]-u[1])*f,r=(h[1]-u[1])*f),n>a||r>i)return null;if((r>n||n!==n)&&(n=r),(a=0?(o=(c[2]-u[2])*p,s=(h[2]-u[2])*p):(s=(c[2]-u[2])*p,o=(h[2]-u[2])*p),n>s||o>i)return null;if((o>n||n!==n)&&(n=o),(s=0?n:i;return e||(e=new ye),Qt.scaleAndAdd(e.array,u,l,g),e},intersectTriangle:function(){var t=Qt.create(),e=Qt.create(),n=Qt.create(),i=Qt.create();return function(r,a,o,s,l,u){var c=this.direction.array,h=this.origin.array;r=r.array,a=a.array,o=o.array,Qt.sub(t,a,r),Qt.sub(e,o,r),Qt.cross(i,e,c);var d=Qt.dot(t,i);if(s){if(d>-_e)return null}else if(d>-_e&&d<_e)return null;Qt.sub(n,h,r);var f=Qt.dot(i,n)/d;if(f<0||f>1)return null;Qt.cross(i,t,n);var p=Qt.dot(c,i)/d;if(p<0||p>1||f+p>1)return null;Qt.cross(i,t,e);var g=-Qt.dot(n,i)/d;return g<0?null:(l||(l=new ye),u&&ye.set(u,1-f-p,f,p),Qt.scaleAndAdd(l.array,h,c,g),l)}}(),applyTransform:function(t){ye.add(this.direction,this.direction,this.origin),ye.transformMat4(this.origin,this.origin,t),ye.transformMat4(this.direction,this.direction,t),ye.sub(this.direction,this.direction,this.origin),ye.normalize(this.direction,this.direction)},copy:function(t){ye.copy(this.origin,t.origin),ye.copy(this.direction,t.direction)},clone:function(){var t=new be;return t.copy(this),t}};var xe=be,we={create:function(){var t=new rt(4);return t[0]=0,t[1]=0,t[2]=0,t[3]=0,t},clone:function(t){var e=new rt(4);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e},fromValues:function(t,e,n,i){var r=new rt(4);return r[0]=t,r[1]=e,r[2]=n,r[3]=i,r},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t},set:function(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t},add:function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t[3]=e[3]+n[3],t},subtract:function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t[3]=e[3]-n[3],t}};we.sub=we.subtract,we.multiply=function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t[3]=e[3]*n[3],t},we.mul=we.multiply,we.divide=function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[2],t[3]=e[3]/n[3],t},we.div=we.divide,we.min=function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t[2]=Math.min(e[2],n[2]),t[3]=Math.min(e[3],n[3]),t},we.max=function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t[2]=Math.max(e[2],n[2]),t[3]=Math.max(e[3],n[3]),t},we.scale=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t},we.scaleAndAdd=function(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t[2]=e[2]+n[2]*i,t[3]=e[3]+n[3]*i,t},we.distance=function(t,e){var n=e[0]-t[0],i=e[1]-t[1],r=e[2]-t[2],a=e[3]-t[3];return Math.sqrt(n*n+i*i+r*r+a*a)},we.dist=we.distance,we.squaredDistance=function(t,e){var n=e[0]-t[0],i=e[1]-t[1],r=e[2]-t[2],a=e[3]-t[3];return n*n+i*i+r*r+a*a},we.sqrDist=we.squaredDistance,we.length=function(t){var e=t[0],n=t[1],i=t[2],r=t[3];return Math.sqrt(e*e+n*n+i*i+r*r)},we.len=we.length,we.squaredLength=function(t){var e=t[0],n=t[1],i=t[2],r=t[3];return e*e+n*n+i*i+r*r},we.sqrLen=we.squaredLength,we.negate=function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t[3]=-e[3],t},we.inverse=function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t[3]=1/e[3],t},we.normalize=function(t,e){var n=e[0],i=e[1],r=e[2],a=e[3],o=n*n+i*i+r*r+a*a;return o>0&&(o=1/Math.sqrt(o),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o,t[3]=e[3]*o),t},we.dot=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]},we.lerp=function(t,e,n,i){var r=e[0],a=e[1],o=e[2],s=e[3];return t[0]=r+i*(n[0]-r),t[1]=a+i*(n[1]-a),t[2]=o+i*(n[2]-o),t[3]=s+i*(n[3]-s),t},we.random=function(t,e){return e=e||1,t[0]=at(),t[1]=at(),t[2]=at(),t[3]=at(),we.normalize(t,t),we.scale(t,t,e),t},we.transformMat4=function(t,e,n){var i=e[0],r=e[1],a=e[2],o=e[3];return t[0]=n[0]*i+n[4]*r+n[8]*a+n[12]*o,t[1]=n[1]*i+n[5]*r+n[9]*a+n[13]*o,t[2]=n[2]*i+n[6]*r+n[10]*a+n[14]*o,t[3]=n[3]*i+n[7]*r+n[11]*a+n[15]*o,t},we.transformQuat=function(t,e,n){var i=e[0],r=e[1],a=e[2],o=n[0],s=n[1],l=n[2],u=n[3],c=u*i+s*a-l*r,h=u*r+l*i-o*a,d=u*a+o*r-s*i,f=-o*i-s*r-l*a;return t[0]=c*u+f*-o+h*-l-d*-s,t[1]=h*u+f*-s+d*-o-c*-l,t[2]=d*u+f*-l+c*-s-h*-o,t},we.forEach=function(){var t=we.create();return function(e,n,i,r,a,o){var s,l;for(n||(n=4),i||(i=0),l=r?Math.min(r*n+i,e.length):e.length,s=i;s.999999?(i[0]=0,i[1]=0,i[2]=0,i[3]=1,i):(Qt.cross(t,r,a),i[0]=t[0],i[1]=t[1],i[2]=t[2],i[3]=1+o,Me.normalize(i,i))}}(),Me.setAxes=function(){var t=Te.create();return function(e,n,i,r){return t[0]=i[0],t[3]=i[1],t[6]=i[2],t[1]=r[0],t[4]=r[1],t[7]=r[2],t[2]=-n[0],t[5]=-n[1],t[8]=-n[2],Me.normalize(e,Me.fromMat3(e,t))}}(),Me.clone=Oe.clone,Me.fromValues=Oe.fromValues,Me.copy=Oe.copy,Me.set=Oe.set,Me.identity=function(t){return t[0]=0,t[1]=0,t[2]=0,t[3]=1,t},Me.setAxisAngle=function(t,e,n){n*=.5;var i=Math.sin(n);return t[0]=i*e[0],t[1]=i*e[1],t[2]=i*e[2],t[3]=Math.cos(n),t},Me.add=Oe.add,Me.multiply=function(t,e,n){var i=e[0],r=e[1],a=e[2],o=e[3],s=n[0],l=n[1],u=n[2],c=n[3];return t[0]=i*c+o*s+r*u-a*l,t[1]=r*c+o*l+a*s-i*u,t[2]=a*c+o*u+i*l-r*s,t[3]=o*c-i*s-r*l-a*u,t},Me.mul=Me.multiply,Me.scale=Oe.scale,Me.rotateX=function(t,e,n){n*=.5;var i=e[0],r=e[1],a=e[2],o=e[3],s=Math.sin(n),l=Math.cos(n);return t[0]=i*l+o*s,t[1]=r*l+a*s,t[2]=a*l-r*s,t[3]=o*l-i*s,t},Me.rotateY=function(t,e,n){n*=.5;var i=e[0],r=e[1],a=e[2],o=e[3],s=Math.sin(n),l=Math.cos(n);return t[0]=i*l-a*s,t[1]=r*l+o*s,t[2]=a*l+i*s,t[3]=o*l-r*s,t},Me.rotateZ=function(t,e,n){n*=.5;var i=e[0],r=e[1],a=e[2],o=e[3],s=Math.sin(n),l=Math.cos(n);return t[0]=i*l+r*s,t[1]=r*l-i*s,t[2]=a*l+o*s,t[3]=o*l-a*s,t},Me.calculateW=function(t,e){var n=e[0],i=e[1],r=e[2];return t[0]=n,t[1]=i,t[2]=r,t[3]=Math.sqrt(Math.abs(1-n*n-i*i-r*r)),t},Me.dot=Oe.dot,Me.lerp=Oe.lerp,Me.slerp=function(t,e,n,i){var r,a,o,s,l,u=e[0],c=e[1],h=e[2],d=e[3],f=n[0],p=n[1],g=n[2],m=n[3];return a=u*f+c*p+h*g+d*m,a<0&&(a=-a,f=-f,p=-p,g=-g,m=-m),1-a>1e-6?(r=Math.acos(a),o=Math.sin(r),s=Math.sin((1-i)*r)/o,l=Math.sin(i*r)/o):(s=1-i,l=i),t[0]=s*u+l*f,t[1]=s*c+l*p,t[2]=s*h+l*g,t[3]=s*d+l*m,t},Me.invert=function(t,e){var n=e[0],i=e[1],r=e[2],a=e[3],o=n*n+i*i+r*r+a*a,s=o?1/o:0;return t[0]=-n*s,t[1]=-i*s,t[2]=-r*s,t[3]=a*s,t},Me.conjugate=function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t[3]=e[3],t},Me.length=Oe.length,Me.len=Me.length,Me.squaredLength=Oe.squaredLength,Me.sqrLen=Me.squaredLength,Me.normalize=Oe.normalize,Me.fromMat3=function(t,e){var n,i=e[0]+e[4]+e[8];if(i>0)n=Math.sqrt(i+1),t[3]=.5*n,n=.5/n,t[0]=(e[5]-e[7])*n,t[1]=(e[6]-e[2])*n,t[2]=(e[1]-e[3])*n;else{var r=0;e[4]>e[0]&&(r=1),e[8]>e[3*r+r]&&(r=2);var a=(r+1)%3,o=(r+2)%3;n=Math.sqrt(e[3*r+r]-e[3*a+a]-e[3*o+o]+1),t[r]=.5*n,n=.5/n,t[3]=(e[3*a+o]-e[3*o+a])*n,t[a]=(e[3*a+r]+e[3*r+a])*n,t[o]=(e[3*o+r]+e[3*r+o])*n}return t};var Ae=Me,Ce=function(){this._axisX=new ye,this._axisY=new ye,this._axisZ=new ye,this.array=Yt.create(),this._dirty=!0};Ce.prototype={constructor:Ce,setArray:function(t){for(var e=0;e0){var e=this.min,n=this.max,i=e.array,r=n.array;ke(i,t[0]),ke(r,t[0]);for(var a=1;ar[0]&&(r[0]=o[0]),o[1]>r[1]&&(r[1]=o[1]),o[2]>r[2]&&(r[2]=o[2])}e._dirty=!0,n._dirty=!0}},union:function(t){var e=this.min,n=this.max;return Qt.min(e.array,e.array,t.min.array),Qt.max(n.array,n.array,t.max.array),e._dirty=!0,n._dirty=!0,this},intersection:function(t){var e=this.min,n=this.max;return Qt.max(e.array,e.array,t.min.array),Qt.min(n.array,n.array,t.max.array),e._dirty=!0,n._dirty=!0,this},intersectBoundingBox:function(t){var e=this.min.array,n=this.max.array,i=t.min.array,r=t.max.array;return!(e[0]>r[0]||e[1]>r[1]||e[2]>r[2]||n[0]=r[0]&&n[1]>=r[1]&&n[2]>=r[2]},containPoint:function(t){var e=this.min.array,n=this.max.array,i=t.array;return e[0]<=i[0]&&e[1]<=i[1]&&e[2]<=i[2]&&n[0]>=i[0]&&n[1]>=i[1]&&n[2]>=i[2]},isFinite:function(){var t=this.min.array,e=this.max.array;return isFinite(t[0])&&isFinite(t[1])&&isFinite(t[2])&&isFinite(e[0])&&isFinite(e[1])&&isFinite(e[2])},applyTransform:function(t){this.transformFrom(this,t)},transformFrom:function(){var t=Qt.create(),e=Qt.create(),n=Qt.create(),i=Qt.create(),r=Qt.create(),a=Qt.create();return function(o,s){var l=o.min.array,u=o.max.array,c=s.array;return t[0]=c[0]*l[0],t[1]=c[1]*l[0],t[2]=c[2]*l[0],e[0]=c[0]*u[0],e[1]=c[1]*u[0],e[2]=c[2]*u[0],n[0]=c[4]*l[1],n[1]=c[5]*l[1],n[2]=c[6]*l[1],i[0]=c[4]*u[1],i[1]=c[5]*u[1],i[2]=c[6]*u[1],r[0]=c[8]*l[2],r[1]=c[9]*l[2],r[2]=c[10]*l[2],a[0]=c[8]*u[2],a[1]=c[9]*u[2],a[2]=c[10]*u[2],l=this.min.array,u=this.max.array,l[0]=Math.min(t[0],e[0])+Math.min(n[0],i[0])+Math.min(r[0],a[0])+c[12],l[1]=Math.min(t[1],e[1])+Math.min(n[1],i[1])+Math.min(r[1],a[1])+c[13],l[2]=Math.min(t[2],e[2])+Math.min(n[2],i[2])+Math.min(r[2],a[2])+c[14],u[0]=Math.max(t[0],e[0])+Math.max(n[0],i[0])+Math.max(r[0],a[0])+c[12],u[1]=Math.max(t[1],e[1])+Math.max(n[1],i[1])+Math.max(r[1],a[1])+c[13],u[2]=Math.max(t[2],e[2])+Math.max(n[2],i[2])+Math.max(r[2],a[2])+c[14],this.min._dirty=!0,this.max._dirty=!0,this}}(),applyProjection:function(t){var e=this.min.array,n=this.max.array,i=t.array,r=e[0],a=e[1],o=e[2],s=n[0],l=n[1],u=e[2],c=n[0],h=n[1],d=n[2];if(1===i[15])e[0]=i[0]*r+i[12],e[1]=i[5]*a+i[13],n[2]=i[10]*o+i[14],n[0]=i[0]*c+i[12],n[1]=i[5]*h+i[13],e[2]=i[10]*d+i[14];else{var f=-1/o;e[0]=i[0]*r*f,e[1]=i[5]*a*f,n[2]=(i[10]*o+i[14])*f,f=-1/u,n[0]=i[0]*s*f,n[1]=i[5]*l*f,f=-1/d,e[2]=(i[10]*d+i[14])*f}return this.min._dirty=!0,this.max._dirty=!0,this},updateVertices:function(){var t=this.vertices;if(!t){t=[];for(var e=0;e<8;e++)t[e]=Qt.fromValues(0,0,0);this.vertices=t}var n=this.min.array,i=this.max.array;return Re(t[0],n[0],n[1],n[2]),Re(t[1],n[0],i[1],n[2]),Re(t[2],i[0],n[1],n[2]),Re(t[3],i[0],i[1],n[2]),Re(t[4],n[0],n[1],i[2]),Re(t[5],n[0],i[1],i[2]),Re(t[6],i[0],n[1],i[2]),Re(t[7],i[0],i[1],i[2]),this},copy:function(t){var e=this.min,n=this.max;return ke(e.array,t.min.array),ke(n.array,t.max.array),e._dirty=!0,n._dirty=!0,this},clone:function(){var t=new Be;return t.copy(this),t}};var ze=Be,Ve=0,Fe=O.extend({name:"",position:null,rotation:null,scale:null,worldTransform:null,localTransform:null,autoUpdateLocalTransform:!0,_parent:null,_scene:null,_needsUpdateWorldTransform:!0,_inIterating:!1,__depth:0},(function(){this.name||(this.name=(this.type||"NODE")+"_"+Ve++),this.position||(this.position=new ye),this.rotation||(this.rotation=new Ne),this.scale||(this.scale=new ye(1,1,1)),this.worldTransform=new Le,this.localTransform=new Le,this._children=[]}),{target:null,invisible:!1,isSkinnedMesh:function(){return!1},isRenderable:function(){return!1},setName:function(t){var e=this._scene;if(e){var n=e._nodeRepository;delete n[this.name],n[t]=this}this.name=t},add:function(t){var e=t._parent;if(e!==this){e&&e.remove(t),t._parent=this,this._children.push(t);var n=this._scene;n&&n!==t.scene&&t.traverse(this._addSelfToScene,this),t._needsUpdateWorldTransform=!0}},remove:function(t){var e=this._children,n=e.indexOf(t);n<0||(e.splice(n,1),t._parent=null,this._scene&&t.traverse(this._removeSelfFromScene,this))},removeAll:function(){for(var t=this._children,e=0;e0},beforeRender:function(t){},afterRender:function(t,e){},getBoundingBox:function(t,e){return e=Ge.prototype.getBoundingBox.call(this,t,e),this.geometry&&this.geometry.boundingBox&&e.union(this.geometry.boundingBox),e},clone:function(){var t=["castShadow","receiveShadow","mode","culling","cullFace","frontFace","frustumCulling","renderOrder","lineWidth","ignorePicking","ignorePreZ","ignoreGBuffer"];return function(){var e=Ge.prototype.clone.call(this);e.geometry=this.geometry,e.material=this.material;for(var n=0;n=0&&x[_]>1e-4&&(Qt.transformMat4(S,b,v[w[_]]),Qt.scaleAndAdd(O,O,S,x[_]));T.set(y,O)}}for(y=0;y>e;return t+1},dispose:function(t){var e=this._cache;e.use(t.__uid__);var n=e.get("webgl_texture");n&&t.gl.deleteTexture(n),e.deleteContext(t.__uid__)},isRenderable:function(){},isPowerOfTwo:function(){}});Object.defineProperty(Ke.prototype,"width",{get:function(){return this._width},set:function(t){this._width=t}}),Object.defineProperty(Ke.prototype,"height",{get:function(){return this._height},set:function(t){this._height=t}}),Ke.BYTE=C.BYTE,Ke.UNSIGNED_BYTE=C.UNSIGNED_BYTE,Ke.SHORT=C.SHORT,Ke.UNSIGNED_SHORT=C.UNSIGNED_SHORT,Ke.INT=C.INT,Ke.UNSIGNED_INT=C.UNSIGNED_INT,Ke.FLOAT=C.FLOAT,Ke.HALF_FLOAT=36193,Ke.UNSIGNED_INT_24_8_WEBGL=34042,Ke.DEPTH_COMPONENT=C.DEPTH_COMPONENT,Ke.DEPTH_STENCIL=C.DEPTH_STENCIL,Ke.ALPHA=C.ALPHA,Ke.RGB=C.RGB,Ke.RGBA=C.RGBA,Ke.LUMINANCE=C.LUMINANCE,Ke.LUMINANCE_ALPHA=C.LUMINANCE_ALPHA,Ke.SRGB=35904,Ke.SRGB_ALPHA=35906,Ke.COMPRESSED_RGB_S3TC_DXT1_EXT=33776,Ke.COMPRESSED_RGBA_S3TC_DXT1_EXT=33777,Ke.COMPRESSED_RGBA_S3TC_DXT3_EXT=33778,Ke.COMPRESSED_RGBA_S3TC_DXT5_EXT=33779,Ke.NEAREST=C.NEAREST,Ke.LINEAR=C.LINEAR,Ke.NEAREST_MIPMAP_NEAREST=C.NEAREST_MIPMAP_NEAREST,Ke.LINEAR_MIPMAP_NEAREST=C.LINEAR_MIPMAP_NEAREST,Ke.NEAREST_MIPMAP_LINEAR=C.NEAREST_MIPMAP_LINEAR,Ke.LINEAR_MIPMAP_LINEAR=C.LINEAR_MIPMAP_LINEAR,Ke.REPEAT=C.REPEAT,Ke.CLAMP_TO_EDGE=C.CLAMP_TO_EDGE,Ke.MIRRORED_REPEAT=C.MIRRORED_REPEAT;var Qe=Ke,Je=Ue.extend({skeleton:null,joints:null},(function(){this.joints||(this.joints=[])}),{offsetMatrix:null,isInstancedMesh:function(){return!1},isSkinnedMesh:function(){return!!(this.skeleton&&this.joints&&this.joints.length>0)},clone:function(){var t=Ue.prototype.clone.call(this);return t.skeleton=this.skeleton,this.joints&&(t.joints=this.joints.slice()),t}});Je.POINTS=C.POINTS,Je.LINES=C.LINES,Je.LINE_LOOP=C.LINE_LOOP,Je.LINE_STRIP=C.LINE_STRIP,Je.TRIANGLES=C.TRIANGLES,Je.TRIANGLE_STRIP=C.TRIANGLE_STRIP,Je.TRIANGLE_FAN=C.TRIANGLE_FAN,Je.BACK=C.BACK,Je.FRONT=C.FRONT,Je.FRONT_AND_BACK=C.FRONT_AND_BACK,Je.CW=C.CW,Je.CCW=C.CCW;var $e=Je,tn={isPowerOfTwo:function(t){return 0===(t&t-1)},nextPowerOfTwo:function(t){return t--,t|=t>>1,t|=t>>2,t|=t>>4,t|=t>>8,t|=t>>16,t++,t},nearestPowerOfTwo:function(t){return Math.pow(2,Math.round(Math.log(t)/Math.LN2))}},en=tn,nn=en.isPowerOfTwo;function rn(t){return Math.pow(2,Math.round(Math.log(t)/Math.LN2))}function an(t,e){var n=rn(t.width),i=rn(t.height);e=e||document.createElement("canvas"),e.width=n,e.height=i;var r=e.getContext("2d");return r.drawImage(t.image,0,0,n,i),e}var on=Qe.extend((function(){return{image:null,pixels:null,mipmaps:[],convertToPOT:!1}}),{textureType:"texture2D",update:function(t){var e=t.gl;e.bindTexture(e.TEXTURE_2D,this._cache.get("webgl_texture")),this.updateCommon(t);var n=this.format,i=this.type,r=!(!this.convertToPOT||this.mipmaps.length||!this.image||this.wrapS!==Qe.REPEAT&&this.wrapT!==Qe.REPEAT||!this.NPOT);e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,r?this.wrapS:this.getAvailableWrapS()),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,r?this.wrapT:this.getAvailableWrapT()),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,r?this.magFilter:this.getAvailableMagFilter()),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,r?this.minFilter:this.getAvailableMinFilter());var a=t.getGLExtension("EXT_texture_filter_anisotropic");if(a&&this.anisotropic>1&&e.texParameterf(e.TEXTURE_2D,a.TEXTURE_MAX_ANISOTROPY_EXT,this.anisotropic),36193===i){var o=t.getGLExtension("OES_texture_half_float");o||(i=C.FLOAT)}if(this.mipmaps.length)for(var s=this.width,l=this.height,u=0;u=Qe.COMPRESSED_RGB_S3TC_DXT1_EXT?t.compressedTexImage2D(t.TEXTURE_2D,n,a,i,r,0,e.pixels):t.texImage2D(t.TEXTURE_2D,n,a,i,r,0,a,o,e.pixels)},generateMipmap:function(t){var e=t.gl;this.useMipmap&&!this.NPOT&&(e.bindTexture(e.TEXTURE_2D,this._cache.get("webgl_texture")),e.generateMipmap(e.TEXTURE_2D))},isPowerOfTwo:function(){return nn(this.width)&&nn(this.height)},isRenderable:function(){return this.image?this.image.width>0&&this.image.height>0:!(!this.width||!this.height)},bind:function(t){t.gl.bindTexture(t.gl.TEXTURE_2D,this.getWebGLTexture(t))},unbind:function(t){t.gl.bindTexture(t.gl.TEXTURE_2D,null)},load:function(t,e){var n=I["a"].createImage();e&&(n.crossOrigin=e);var i=this;return n.onload=function(){i.dirty(),i.trigger("success",i)},n.onerror=function(){i.trigger("error",i)},n.src=t,this.image=n,this}});Object.defineProperty(on.prototype,"width",{get:function(){return this.image?this.image.width:this._width},set:function(t){this.image?console.warn("Texture from image can't set width"):(this._width!==t&&this.dirty(),this._width=t)}}),Object.defineProperty(on.prototype,"height",{get:function(){return this.image?this.image.height:this._height},set:function(t){this.image?console.warn("Texture from image can't set height"):(this._height!==t&&this.dirty(),this._height=t)}});var sn=on;function ln(t){return{byte:I["a"].Int8Array,ubyte:I["a"].Uint8Array,short:I["a"].Int16Array,ushort:I["a"].Uint16Array}[t]||I["a"].Float32Array}function un(t){return"attr_"+t}function cn(t,e,n,i){switch(this.name=t,this.type=e,this.size=n,this.semantic=i||"",this.value=null,n){case 1:this.get=function(t){return this.value[t]},this.set=function(t,e){this.value[t]=e},this.copy=function(t,e){this.value[t]=this.value[t]};break;case 2:this.get=function(t,e){var n=this.value;return e[0]=n[2*t],e[1]=n[2*t+1],e},this.set=function(t,e){var n=this.value;n[2*t]=e[0],n[2*t+1]=e[1]},this.copy=function(t,e){var n=this.value;e*=2,t*=2,n[t]=n[e],n[t+1]=n[e+1]};break;case 3:this.get=function(t,e){var n=3*t,i=this.value;return e[0]=i[n],e[1]=i[n+1],e[2]=i[n+2],e},this.set=function(t,e){var n=3*t,i=this.value;i[n]=e[0],i[n+1]=e[1],i[n+2]=e[2]},this.copy=function(t,e){var n=this.value;e*=3,t*=3,n[t]=n[e],n[t+1]=n[e+1],n[t+2]=n[e+2]};break;case 4:this.get=function(t,e){var n=this.value,i=4*t;return e[0]=n[i],e[1]=n[i+1],e[2]=n[i+2],e[3]=n[i+3],e},this.set=function(t,e){var n=this.value,i=4*t;n[i]=e[0],n[i+1]=e[1],n[i+2]=e[2],n[i+3]=e[3]},this.copy=function(t,e){var n=this.value;e*=4,t*=4,n[t]=n[e],n[t+1]=n[e+1],n[t+2]=n[e+2],n[t+3]=n[e+3]}}}function hn(t,e,n,i,r){this.name=t,this.type=e,this.buffer=n,this.size=i,this.semantic=r,this.symbol="",this.needsRemove=!1}function dn(t){this.buffer=t,this.count=0}cn.prototype.init=function(t){if(!this.value||this.value.length!==t*this.size){var e=ln(this.type);this.value=new e(t*this.size)}},cn.prototype.fromArray=function(t){var e,n=ln(this.type);if(t[0]&&t[0].length){var i=0,r=this.size;e=new n(t.length*r);for(var a=0;a=0){e||(e=[]);var n=this.indices;return e[0]=n[3*t],e[1]=n[3*t+1],e[2]=n[3*t+2],e}},setTriangleIndices:function(t,e){var n=this.indices;n[3*t]=e[0],n[3*t+1]=e[1],n[3*t+2]=e[2]},isUseIndices:function(){return!!this.indices},initIndicesFromArray:function(t){var e,n=this.vertexCount>65535?I["a"].Uint32Array:I["a"].Uint16Array;if(t[0]&&t[0].length){var i=0,r=3;e=new n(t.length*r);for(var a=0;a=0&&(e.splice(n,1),delete this.attributes[t],!0)},getAttribute:function(t){return this.attributes[t]},getEnabledAttributes:function(){var t=this._enabledAttributes,e=this._attributeList;if(t)return t;for(var n=[],i=this.vertexCount,r=0;ra[0]&&(a[0]=s),l>a[1]&&(a[1]=l),u>a[2]&&(a[2]=u)}n._dirty=!0,i._dirty=!0}},generateVertexNormals:function(){if(this.vertexCount){var t=this.indices,e=this.attributes,n=e.position.value,i=e.normal.value;if(i&&i.length===n.length)for(var r=0;r65535&&(this.indices=new I["a"].Uint32Array(this.indices));for(var t=this.attributes,e=this.indices,n=this.getEnabledAttributes(),i={},r=0;rthis.distance,r=1;r<8;r++)if(Qt.dot(e[r].array,n)>this.distance!=i)return!0},intersectLine:function(){var t=Qt.create();return function(e,n,i){var r=this.distanceToPoint(e),a=this.distanceToPoint(n);if(r>0&&a>0||r<0&&a<0)return null;var o=this.normal.array,s=this.distance,l=e.array;Qt.sub(t,n.array,e.array),Qt.normalize(t,t);var u=Qt.dot(o,t);if(0===u)return null;i||(i=new ye);var c=(Qt.dot(o,l)-s)/u;return Qt.scaleAndAdd(i.array,l,t,-c),i._dirty=!0,i}}(),applyTransform:function(){var t=Yt.create(),e=Oe.create(),n=Oe.create();return n[3]=1,function(i){i=i.array,Qt.scale(n,this.normal.array,this.distance),Oe.transformMat4(n,n,i),this.distance=Qt.dot(n,this.normal.array),Yt.invert(t,i),Yt.transpose(t,t),e[3]=0,Qt.copy(e,this.normal.array),Oe.transformMat4(e,e,t),Qt.copy(this.normal.array,e)}}(),copy:function(t){Qt.copy(this.normal.array,t.normal.array),this.normal._dirty=!0,this.distance=t.distance},clone:function(){var t=new Dn;return t.copy(this),t}};var Ln=Dn,En=Qt.set,jn=Qt.copy,Pn=Qt.transformMat4,Nn=Math.min,Rn=Math.max,kn=function(){this.planes=[];for(var t=0;t<6;t++)this.planes.push(new Ln);this.boundingBox=new ze,this.vertices=[];for(t=0;t<8;t++)this.vertices[t]=Qt.fromValues(0,0,0)};kn.prototype={setFromProjection:function(t){var e=this.planes,n=t.array,i=n[0],r=n[1],a=n[2],o=n[3],s=n[4],l=n[5],u=n[6],c=n[7],h=n[8],d=n[9],f=n[10],p=n[11],g=n[12],m=n[13],v=n[14],y=n[15];En(e[0].normal.array,o-i,c-s,p-h),e[0].distance=-(y-g),e[0].normalize(),En(e[1].normal.array,o+i,c+s,p+h),e[1].distance=-(y+g),e[1].normalize(),En(e[2].normal.array,o+r,c+l,p+d),e[2].distance=-(y+m),e[2].normalize(),En(e[3].normal.array,o-r,c-l,p-d),e[3].distance=-(y-m),e[3].normalize(),En(e[4].normal.array,o-a,c-u,p-f),e[4].distance=-(y-v),e[4].normalize(),En(e[5].normal.array,o+a,c+u,p+f),e[5].distance=-(y+v),e[5].normalize();var _=this.boundingBox,b=this.vertices;if(0===y){var x=l/i,w=-v/(f-1),O=-v/(f+1),S=-O/l,T=-w/l;_.min.set(-S*x,-S,O),_.max.set(S*x,S,w),En(b[0],-S*x,-S,O),En(b[1],-S*x,S,O),En(b[2],S*x,-S,O),En(b[3],S*x,S,O),En(b[4],-T*x,-T,w),En(b[5],-T*x,T,w),En(b[6],T*x,-T,w),En(b[7],T*x,T,w)}else{var M=(-1-g)/i,A=(1-g)/i,C=(1-m)/l,I=(-1-m)/l,D=(-1-v)/f,L=(1-v)/f;_.min.set(Math.min(M,A),Math.min(I,C),Math.min(L,D)),_.max.set(Math.max(A,M),Math.max(C,I),Math.max(D,L));var E=_.min.array,j=_.max.array;En(b[0],E[0],E[1],E[2]),En(b[1],E[0],j[1],E[2]),En(b[2],j[0],E[1],E[2]),En(b[3],j[0],j[1],E[2]),En(b[4],E[0],E[1],j[2]),En(b[5],E[0],j[1],j[2]),En(b[6],j[0],E[1],j[2]),En(b[7],j[0],j[1],j[2])}},getTransformedBoundingBox:function(){var t=Qt.create();return function(e,n){var i=this.vertices,r=n.array,a=e.min,o=e.max,s=a.array,l=o.array,u=i[0];Pn(t,u,r),jn(s,t),jn(l,t);for(var c=1;c<8;c++)u=i[c],Pn(t,u,r),s[0]=Nn(t[0],s[0]),s[1]=Nn(t[1],s[1]),s[2]=Nn(t[2],s[2]),l[0]=Rn(t[0],l[0]),l[1]=Rn(t[1],l[1]),l[2]=Rn(t[2],l[2]);return a._dirty=!0,o._dirty=!0,e}}()};var Bn=kn,zn=Ge.extend((function(){return{projectionMatrix:new Le,invProjectionMatrix:new Le,viewMatrix:new Le,frustum:new Bn}}),(function(){this.update(!0)}),{update:function(t){Ge.prototype.update.call(this,t),Le.invert(this.viewMatrix,this.worldTransform),this.updateProjectionMatrix(),Le.invert(this.invProjectionMatrix,this.projectionMatrix),this.frustum.setFromProjection(this.projectionMatrix)},setViewMatrix:function(t){Le.copy(this.viewMatrix,t),Le.invert(this.worldTransform,t),this.decomposeWorldTransform()},decomposeProjectionMatrix:function(){},setProjectionMatrix:function(t){Le.copy(this.projectionMatrix,t),Le.invert(this.invProjectionMatrix,t),this.decomposeProjectionMatrix()},updateProjectionMatrix:function(){},castRay:function(){var t=Oe.create();return function(e,n){var i=void 0!==n?n:new xe,r=e.array[0],a=e.array[1];return Oe.set(t,r,a,-1,1),Oe.transformMat4(t,t,this.invProjectionMatrix.array),Oe.transformMat4(t,t,this.worldTransform.array),Qt.scale(i.origin.array,t,1/t[3]),Oe.set(t,r,a,1,1),Oe.transformMat4(t,t,this.invProjectionMatrix.array),Oe.transformMat4(t,t,this.worldTransform.array),Qt.scale(t,t,1/t[3]),Qt.sub(i.direction.array,t,i.origin.array),Qt.normalize(i.direction.array,i.direction.array),i.direction._dirty=!0,i.origin._dirty=!0,i}}()}),Vn=zn,Fn=Yt.create(),Gn=Yt.create(),Hn={};function Un(t){var e=[],n=Object.keys(t);n.sort();for(var i=0;i0&&console.warn("Found multiple camera in one scene. Use the fist one."),this._cameraList.push(t)):t instanceof In&&this.lights.push(t),t.name&&(this._nodeRepository[t.name]=t)},removeFromScene:function(t){var e;t instanceof Vn?(e=this._cameraList.indexOf(t),e>=0&&this._cameraList.splice(e,1)):t instanceof In&&(e=this.lights.indexOf(t),e>=0&&this.lights.splice(e,1)),t.name&&delete this._nodeRepository[t.name]},getNode:function(t){return this._nodeRepository[t]},setMainCamera:function(t){var e=this._cameraList.indexOf(t);e>=0&&this._cameraList.splice(e,1),this._cameraList.unshift(t)},getMainCamera:function(){return this._cameraList[0]},getLights:function(){return this.lights},updateLights:function(){var t=this.lights;this._previousLightNumber=this._lightNumber;for(var e={},n=0;n0&&this._doUpdateRenderList(o,e,n,i,r)}},isFrustumCulled:function(){var t=new ze,e=new Le;return function(n,i,r){var a=n.boundingBox;if(a||(a=n.skeleton&&n.skeleton.boundingBox?n.skeleton.boundingBox:n.geometry.boundingBox),!a)return!1;if(e.array=r,t.transformFrom(a,e),n.castShadow&&this.viewBoundingBoxLastFrame.union(t),n.frustumCulling){if(!t.intersectBoundingBox(i.frustum.boundingBox))return!0;e.array=i.projectionMatrix.array,t.max.array[2]>0&&t.min.array[2]<0&&(t.max.array[2]=-1e-20),t.applyProjection(e);var o=t.min.array,s=t.max.array;if(s[0]<-1||o[0]>1||s[1]<-1||o[1]>1||s[2]<-1||o[2]>1)return!0}return!1}}(),_updateLightUniforms:function(){var t=this.lights;t.sort(Zn);var e=this._lightUniforms;for(var n in e)for(var i in e[n])e[n][i].value.length=0;for(var r=0;r1&&e.texParameterf(e.TEXTURE_CUBE_MAP,r.TEXTURE_MAX_ANISOTROPY_EXT,this.anisotropic),36193===i){var a=t.getGLExtension("OES_texture_half_float");a||(i=C.FLOAT)}if(this.mipmaps.length)for(var o=this.width,s=this.height,l=0;l0&&t.height>0}Object.defineProperty(Jn.prototype,"width",{get:function(){return this.image&&this.image.px?this.image.px.width:this._width},set:function(t){this.image&&this.image.px?console.warn("Texture from image can't set width"):(this._width!==t&&this.dirty(),this._width=t)}}),Object.defineProperty(Jn.prototype,"height",{get:function(){return this.image&&this.image.px?this.image.px.height:this._height},set:function(t){this.image&&this.image.px?console.warn("Texture from image can't set height"):(this._height!==t&&this.dirty(),this._height=t)}});var ti=Jn,ei=Vn.extend({fov:50,aspect:1,near:.1,far:2e3},{updateProjectionMatrix:function(){var t=this.fov/180*Math.PI;this.projectionMatrix.perspective(t,this.aspect,this.near,this.far)},decomposeProjectionMatrix:function(){var t=this.projectionMatrix.array,e=2*Math.atan(1/t[5]);this.fov=e/Math.PI*180,this.aspect=t[5]/t[0],this.near=t[14]/(t[10]-1),this.far=t[14]/(t[10]+1)},clone:function(){var t=Vn.prototype.clone.call(this);return t.fov=this.fov,t.aspect=this.aspect,t.near=this.near,t.far=this.far,t}}),ni=ei,ii="framebuffer",ri="renderbuffer",ai=ri+"_width",oi=ri+"_height",si=ri+"_attached",li="depthtexture_attached",ui=C.FRAMEBUFFER,ci=C.RENDERBUFFER,hi=C.DEPTH_ATTACHMENT,di=C.COLOR_ATTACHMENT0,fi=O.extend({depthBuffer:!0,viewport:null,_width:0,_height:0,_textures:null,_boundRenderer:null},(function(){this._cache=new Ye,this._textures={}}),{getTextureWidth:function(){return this._width},getTextureHeight:function(){return this._height},bind:function(t){if(t.__currentFrameBuffer){if(t.__currentFrameBuffer===this)return;console.warn("Renderer already bound with another framebuffer. Unbind it first")}t.__currentFrameBuffer=this;var e=t.gl;e.bindFramebuffer(ui,this._getFrameBufferGL(t)),this._boundRenderer=t;var n=this._cache;n.put("viewport",t.viewport);var i,r,a=!1;for(var o in this._textures){a=!0;var s=this._textures[o];s&&(i=s.texture.width,r=s.texture.height,this._doAttach(t,s.texture,o,s.target))}this._width=i,this._height=r,!a&&this.depthBuffer&&console.error("Must attach texture before bind, or renderbuffer may have incorrect width and height."),this.viewport?t.setViewport(this.viewport):t.setViewport(0,0,i,r,1);var l=n.get("attached_textures");if(l)for(var o in l)if(!this._textures[o]){var u=l[o];this._doDetach(e,o,u)}if(!n.get(li)&&this.depthBuffer){n.miss(ri)&&n.put(ri,e.createRenderbuffer());var c=n.get(ri);i===n.get(ai)&&r===n.get(oi)||(e.bindRenderbuffer(ci,c),e.renderbufferStorage(ci,e.DEPTH_COMPONENT16,i,r),n.put(ai,i),n.put(oi,r),e.bindRenderbuffer(ci,null)),n.get(si)||(e.framebufferRenderbuffer(ui,hi,ci,c),n.put(si,!0))}},unbind:function(t){t.__currentFrameBuffer=null;var e=t.gl;e.bindFramebuffer(ui,null),this._boundRenderer=null,this._cache.use(t.__uid__);var n=this._cache.get("viewport");n&&t.setViewport(n),this.updateMipmap(t)},updateMipmap:function(t){var e=t.gl;for(var n in this._textures){var i=this._textures[n];if(i){var r=i.texture;if(!r.NPOT&&r.useMipmap&&r.minFilter===Qe.LINEAR_MIPMAP_LINEAR){var a="textureCube"===r.textureType?C.TEXTURE_CUBE_MAP:C.TEXTURE_2D;e.bindTexture(a,r.getWebGLTexture(t)),e.generateMipmap(a),e.bindTexture(a,null)}}}},checkStatus:function(t){return t.checkFramebufferStatus(ui)},_getFrameBufferGL:function(t){var e=this._cache;return e.use(t.__uid__),e.miss(ii)&&e.put(ii,t.gl.createFramebuffer()),e.get(ii)},attach:function(t,e,n){if(!t.width)throw new Error("The texture attached to color buffer is not a valid.");e=e||di,n=n||C.TEXTURE_2D;var i,r=this._boundRenderer,a=r&&r.gl;if(a){var o=this._cache;o.use(r.__uid__),i=o.get("attached_textures")}var s=this._textures[e];if(!s||s.target!==n||s.texture!==t||!i||null==i[e]){var l=!0;r&&(l=this._doAttach(r,t,e,n),this.viewport||r.setViewport(0,0,t.width,t.height,1)),l&&(this._textures[e]=this._textures[e]||{},this._textures[e].texture=t,this._textures[e].target=n)}},_doAttach:function(t,e,n,i){var r=t.gl,a=e.getWebGLTexture(t),o=this._cache.get("attached_textures");if(o&&o[n]){var s=o[n];if(s.texture===e&&s.target===i)return}n=+n;var l=!0;if(n===hi||n===C.DEPTH_STENCIL_ATTACHMENT){var u=t.getGLExtension("WEBGL_depth_texture");if(u||(console.error("Depth texture is not supported by the browser"),l=!1),e.format!==C.DEPTH_COMPONENT&&e.format!==C.DEPTH_STENCIL&&(console.error("The texture attached to depth buffer is not a valid."),l=!1),l){var c=this._cache.get(ri);c&&(r.framebufferRenderbuffer(ui,hi,ci,null),r.deleteRenderbuffer(c),this._cache.put(ri,!1)),this._cache.put(si,!1),this._cache.put(li,!0)}}return r.framebufferTexture2D(ui,n,i,a,0),o||(o={},this._cache.put("attached_textures",o)),o[n]=o[n]||{},o[n].texture=e,o[n].target=i,l},_doDetach:function(t,e,n){t.framebufferTexture2D(ui,e,n,null,0);var i=this._cache.get("attached_textures");i&&i[e]&&(i[e]=null),e!==hi&&e!==C.DEPTH_STENCIL_ATTACHMENT||this._cache.put(li,!1)},detach:function(t,e){if(this._textures[t]=null,this._boundRenderer){var n=this._cache;n.use(this._boundRenderer.__uid__),this._doDetach(this._boundRenderer.gl,t,e)}},dispose:function(t){var e=t.gl,n=this._cache;n.use(t.__uid__);var i=n.get(ri);i&&e.deleteRenderbuffer(i);var r=n.get(ii);r&&e.deleteFramebuffer(r),n.deleteContext(t.__uid__),this._textures={}}});fi.DEPTH_ATTACHMENT=hi,fi.COLOR_ATTACHMENT0=di,fi.STENCIL_ATTACHMENT=C.STENCIL_ATTACHMENT,fi.DEPTH_STENCIL_ATTACHMENT=C.DEPTH_STENCIL_ATTACHMENT;var pi=fi,gi=["px","nx","py","ny","pz","nz"],mi=O.extend((function(){var t={position:new ye,far:1e3,near:.1,texture:null,shadowMapPass:null},e=t._cameras={px:new ni({fov:90}),nx:new ni({fov:90}),py:new ni({fov:90}),ny:new ni({fov:90}),pz:new ni({fov:90}),nz:new ni({fov:90})};return e.px.lookAt(ye.POSITIVE_X,ye.NEGATIVE_Y),e.nx.lookAt(ye.NEGATIVE_X,ye.NEGATIVE_Y),e.py.lookAt(ye.POSITIVE_Y,ye.POSITIVE_Z),e.ny.lookAt(ye.NEGATIVE_Y,ye.NEGATIVE_Z),e.pz.lookAt(ye.POSITIVE_Z,ye.NEGATIVE_Y),e.nz.lookAt(ye.NEGATIVE_Z,ye.NEGATIVE_Y),t._frameBuffer=new pi,t}),{getCamera:function(t){return this._cameras[t]},render:function(t,e,n){var i=t.gl;n||e.update();for(var r=this.texture.width,a=2*Math.atan(r/(r-.5))/Math.PI*180,o=0;o<6;o++){var s=gi[o],l=this._cameras[s];if(ye.copy(l.position,this.position),l.far=this.far,l.near=this.near,l.fov=a,this.shadowMapPass){l.update();var u=e.getBoundingBox();u.applyTransform(l.viewMatrix),e.viewBoundingBoxLastFrame.copy(u),this.shadowMapPass.render(t,e,l,!0)}this._frameBuffer.attach(this.texture,i.COLOR_ATTACHMENT0,i.TEXTURE_CUBE_MAP_POSITIVE_X+o),this._frameBuffer.bind(t),t.render(e,l,!0),this._frameBuffer.unbind(t)}},dispose:function(t){this._frameBuffer.dispose(t)}}),vi=mi,yi=bn.extend({dynamic:!1,widthSegments:1,heightSegments:1},(function(){this.build()}),{build:function(){for(var t=this.heightSegments,e=this.widthSegments,n=this.attributes,i=[],r=[],a=[],o=[],s=0;s<=t;s++)for(var l=s/t,u=0;u<=e;u++){var c=u/e;if(i.push([2*c-1,2*l-1,0]),r&&r.push([c,l]),a&&a.push([0,0,1]),u0?this.material.define("fragment","LOD"):this.material.undefine("fragment","LOD"),t.renderPass([this],n)}}),Mi=Ti,Ai=Mi,Ci=542327876,Ii=131072,Di=512,Li=4;function Ei(t){return t.charCodeAt(0)+(t.charCodeAt(1)<<8)+(t.charCodeAt(2)<<16)+(t.charCodeAt(3)<<24)}var ji=31,Pi=Ei("DXT1"),Ni=Ei("DXT3"),Ri=Ei("DXT5"),ki=0,Bi=1,zi=2,Vi=3,Fi=4,Gi=7,Hi=20,Ui=21,Wi=28,Xi={parse:function(t,e){var n=new Int32Array(t,0,ji);if(n[ki]!==Ci)return null;if(!n(Hi)&Li)return null;var i,r,a=n(Ui),o=n[Fi],s=n[Vi],l=n[Wi]&Di,u=n[zi]&Ii;switch(a){case Pi:i=8,r=Qe.COMPRESSED_RGB_S3TC_DXT1_EXT;break;case Ni:i=16,r=Qe.COMPRESSED_RGBA_S3TC_DXT3_EXT;break;case Ri:i=16,r=Qe.COMPRESSED_RGBA_S3TC_DXT5_EXT;break;default:return null}var c=n[Bi]+4,h=l?6:1,d=1;u&&(d=Math.max(1,n[Gi]));for(var f=[],p=0;p0){var r=Math.pow(2,t[3]-128-8+i);e[n+0]=t[0]*r,e[n+1]=t[1]*r,e[n+2]=t[2]*r}else e[n+0]=0,e[n+1]=0,e[n+2]=0;return e[n+3]=1,e}function Ji(t,e,n){for(var i="",r=e;r0)if(t[a][0]=e[n++],t[a][1]=e[n++],t[a][2]=e[n++],t[a][3]=e[n++],1===t[a][0]&&1===t[a][1]&&1===t[a][2]){for(var s=t[a][3]<>>0;s>0;s--)$i(t[a-1],t[a]),a++,o--;r+=8}else a++,o--,r=0;return n}function er(t,e,n,i){if(iKi)return tr(t,e,n,i);var r=e[n++];if(2!=r)return tr(t,e,n-1,i);if(t[0][1]=e[n++],t[0][2]=e[n++],r=e[n++],(t[0][2]<<8>>>0|r)>>>0!==i)return null;for(r=0;r<4;r++)for(var a=0;a128){o=(127&o)>>>0;var s=e[n++];while(o--)t[a++][r]=s}else while(o--)t[a++][r]=e[n++]}return n}var nr={parseRGBE:function(t,e,n){null==n&&(n=0);var i=new Uint8Array(t),r=i.length;if("#?"===Ji(i,0,2)){for(var a=2;a=r)){a+=2;for(var o="";a20)return console.warn("Given image is not a height map"),t}var f,p,g,m;l%(4*i)===0?(f=o.data[l],g=o.data[l+4]):l%(4*i)===4*(i-1)?(f=o.data[l-4],g=o.data[l]):(f=o.data[l-4],g=o.data[l+4]),l<4*i?(p=o.data[l],m=o.data[l+4*i]):l>i*(r-1)*4?(p=o.data[l-4*i],m=o.data[l]):(p=o.data[l-4*i],m=o.data[l+4*i]),s.data[l]=f-g+127,s.data[l+1]=p-m+127,s.data[l+2]=255,s.data[l+3]=255}return a.putImageData(s,0,0),n},isHeightImage:function(t,e,n){if(!t||!t.width||!t.height)return!1;var i=document.createElement("canvas"),r=i.getContext("2d"),a=e||32;n=n||20,i.width=i.height=a,r.drawImage(t,0,0,a,a);for(var o=r.getImageData(0,0,a,a),s=0;sn)return!1}return!0},_fetchTexture:function(t,e,n){I["a"].request.get({url:t,responseType:"arraybuffer",onload:e,onerror:n})},createChessboard:function(t,e,n,i){t=t||512,e=e||64,n=n||"black",i=i||"white";var r=Math.ceil(t/e),a=document.createElement("canvas");a.width=t,a.height=t;var o=a.getContext("2d");o.fillStyle=i,o.fillRect(0,0,t,t),o.fillStyle=n;for(var s=0;s=0||(or.forEach((function(e){t.on(e,this[sr(e)],this)}),this),this._meshes.push(t))},detachFromMesh:function(t){var e=this._meshes.indexOf(t);e>=0&&this._meshes.splice(e,1),or.forEach((function(e){t.off(e,this[sr(e)])}),this)},dispose:function(){this._meshes.forEach((function(t){this.detachFromMesh(t)}),this)}};var ur=lr,cr=Vn.extend({left:-1,right:1,near:-1,far:1,top:1,bottom:-1},{updateProjectionMatrix:function(){this.projectionMatrix.ortho(this.left,this.right,this.bottom,this.top,this.near,this.far)},decomposeProjectionMatrix:function(){var t=this.projectionMatrix.array;this.left=(-1-t[12])/t[0],this.right=(1-t[12])/t[0],this.top=(1-t[13])/t[5],this.bottom=(-1-t[13])/t[5],this.near=-(-1-t[14])/t[10],this.far=-(1-t[14])/t[10]},clone:function(){var t=Vn.prototype.clone.call(this);return t.left=this.left,t.right=this.right,t.near=this.near,t.far=this.far,t.top=this.top,t.bottom=this.bottom,t}}),hr=cr,dr="\n@export clay.compositor.vertex\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nattribute vec3 position : POSITION;\nattribute vec2 texcoord : TEXCOORD_0;\nvarying vec2 v_Texcoord;\nvoid main()\n{\n v_Texcoord = texcoord;\n gl_Position = worldViewProjection * vec4(position, 1.0);\n}\n@end";Xt["import"](dr);var fr=new _i,pr=new $e({geometry:fr,frustumCulling:!1}),gr=new hr,mr=O.extend((function(){return{fragment:"",outputs:null,material:null,blendWithPrevious:!1,clearColor:!1,clearDepth:!0}}),(function(){var t=new Xt(Xt.source("clay.compositor.vertex"),this.fragment),e=new nt({shader:t});e.enableTexturesAll(),this.material=e}),{setUniform:function(t,e){this.material.setUniform(t,e)},getUniform:function(t){var e=this.material.uniforms[t];if(e)return e.value},attachOutput:function(t,e){this.outputs||(this.outputs={}),e=e||C.COLOR_ATTACHMENT0,this.outputs[e]=t},detachOutput:function(t){for(var e in this.outputs)this.outputs[e]===t&&(this.outputs[e]=null)},bind:function(t,e){if(this.outputs)for(var n in this.outputs){var i=this.outputs[n];i&&e.attach(i,n)}e&&e.bind(t)},unbind:function(t,e){e.unbind(t)},render:function(t,e){var n=t.gl;if(e){this.bind(t,e);var i=t.getGLExtension("EXT_draw_buffers");if(i&&this.outputs){var r=[];for(var a in this.outputs)a=+a,a>=n.COLOR_ATTACHMENT0&&a<=n.COLOR_ATTACHMENT0+8&&r.push(a);i.drawBuffersEXT(r)}}this.trigger("beforerender",this,t);var o=this.clearDepth?n.DEPTH_BUFFER_BIT:0;if(n.depthMask(!0),this.clearColor){o|=n.COLOR_BUFFER_BIT,n.colorMask(!0,!0,!0,!0);var s=this.clearColor;Array.isArray(s)&&n.clearColor(s[0],s[1],s[2],s[3])}n.clear(o),this.blendWithPrevious?(n.enable(n.BLEND),this.material.transparent=!0):(n.disable(n.BLEND),this.material.transparent=!1),this.renderQuad(t),this.trigger("afterrender",this,t),e&&this.unbind(t,e)},renderQuad:function(t){pr.material=this.material,t.renderPass([pr],gr)},dispose:function(t){}}),vr=mr,yr="#define SAMPLE_NUMBER 1024\n#define PI 3.14159265358979\nuniform sampler2D normalDistribution;\nuniform vec2 viewportSize : [512, 256];\nconst vec3 N = vec3(0.0, 0.0, 1.0);\nconst float fSampleNumber = float(SAMPLE_NUMBER);\nvec3 importanceSampleNormal(float i, float roughness, vec3 N) {\n vec3 H = texture2D(normalDistribution, vec2(roughness, i)).rgb;\n vec3 upVector = abs(N.y) > 0.999 ? vec3(1.0, 0.0, 0.0) : vec3(0.0, 1.0, 0.0);\n vec3 tangentX = normalize(cross(N, upVector));\n vec3 tangentZ = cross(N, tangentX);\n return normalize(tangentX * H.x + N * H.y + tangentZ * H.z);\n}\nfloat G_Smith(float roughness, float NoV, float NoL) {\n float k = roughness * roughness / 2.0;\n float G1V = NoV / (NoV * (1.0 - k) + k);\n float G1L = NoL / (NoL * (1.0 - k) + k);\n return G1L * G1V;\n}\nvoid main() {\n vec2 uv = gl_FragCoord.xy / viewportSize;\n float NoV = uv.x;\n float roughness = uv.y;\n vec3 V;\n V.x = sqrt(1.0 - NoV * NoV);\n V.y = 0.0;\n V.z = NoV;\n float A = 0.0;\n float B = 0.0;\n for (int i = 0; i < SAMPLE_NUMBER; i++) {\n vec3 H = importanceSampleNormal(float(i) / fSampleNumber, roughness, N);\n vec3 L = reflect(-V, H);\n float NoL = clamp(L.z, 0.0, 1.0);\n float NoH = clamp(H.z, 0.0, 1.0);\n float VoH = clamp(dot(V, H), 0.0, 1.0);\n if (NoL > 0.0) {\n float G = G_Smith(roughness, NoV, NoL);\n float G_Vis = G * VoH / (NoH * NoV);\n float Fc = pow(1.0 - VoH, 5.0);\n A += (1.0 - Fc) * G_Vis;\n B += Fc * G_Vis;\n }\n }\n gl_FragColor = vec4(vec2(A, B) / fSampleNumber, 0.0, 1.0);\n}\n",_r="#define SHADER_NAME prefilter\n#define SAMPLE_NUMBER 1024\n#define PI 3.14159265358979\nuniform mat4 viewInverse : VIEWINVERSE;\nuniform samplerCube environmentMap;\nuniform sampler2D normalDistribution;\nuniform float roughness : 0.5;\nvarying vec2 v_Texcoord;\nvarying vec3 v_WorldPosition;\n@import clay.util.rgbm\nvec3 importanceSampleNormal(float i, float roughness, vec3 N) {\n vec3 H = texture2D(normalDistribution, vec2(roughness, i)).rgb;\n vec3 upVector = abs(N.y) > 0.999 ? vec3(1.0, 0.0, 0.0) : vec3(0.0, 1.0, 0.0);\n vec3 tangentX = normalize(cross(N, upVector));\n vec3 tangentZ = cross(N, tangentX);\n return normalize(tangentX * H.x + N * H.y + tangentZ * H.z);\n}\nvoid main() {\n vec3 eyePos = viewInverse[3].xyz;\n vec3 V = normalize(v_WorldPosition - eyePos);\n vec3 N = V;\n vec3 prefilteredColor = vec3(0.0);\n float totalWeight = 0.0;\n float fMaxSampleNumber = float(SAMPLE_NUMBER);\n for (int i = 0; i < SAMPLE_NUMBER; i++) {\n vec3 H = importanceSampleNormal(float(i) / fMaxSampleNumber, roughness, N);\n vec3 L = reflect(-V, H);\n float NoL = clamp(dot(N, L), 0.0, 1.0);\n if (NoL > 0.0) {\n prefilteredColor += decodeHDR(textureCube(environmentMap, L)).rgb * NoL;\n totalWeight += NoL;\n }\n }\n gl_FragColor = encodeHDR(vec4(prefilteredColor / totalWeight, 1.0));\n}\n",br={},xr=["px","nx","py","ny","pz","nz"];br.prefilterEnvironmentMap=function(t,e,n,i,r){r&&i||(i=br.generateNormalDistribution(),r=br.integrateBRDF(t,i)),n=n||{};var a=n.width||64,o=n.height||64,s=n.type||e.type,l=new ti({width:a,height:o,type:s,flipY:!1,mipmaps:[]});l.isPowerOfTwo()||console.warn("Width and height must be power of two to enable mipmap.");var u=Math.min(a,o),c=Math.log(u)/Math.log(2)+1,h=new nt({shader:new Xt({vertex:Xt.source("clay.skybox.vertex"),fragment:_r})});h.set("normalDistribution",i),n.encodeRGBM&&h.define("fragment","RGBM_ENCODE"),n.decodeRGBM&&h.define("fragment","RGBM_DECODE");var d,f=new qn;if("texture2D"===e.textureType){var p=new ti({width:a,height:o,type:s===Qe.FLOAT?Qe.HALF_FLOAT:s});ar.panoramaToCubeMap(t,e,p,{encodeRGBM:n.decodeRGBM}),e=p}d=new Mi({scene:f,material:h}),d.material.set("environmentMap",e);var g=new vi({texture:l});n.encodeRGBM&&(s=l.type=Qe.UNSIGNED_BYTE);for(var m=new sn({width:a,height:o,type:s}),v=new pi({depthBuffer:!1}),y=I["a"][s===Qe.UNSIGNED_BYTE?"Uint8Array":"Float32Array"],_=0;_>>16)>>>0;u=((1431655765&u)<<1|(2863311530&u)>>>1)>>>0,u=((858993459&u)<<2|(3435973836&u)>>>2)>>>0,u=((252645135&u)<<4|(4042322160&u)>>>4)>>>0,u=(((16711935&u)<<8|(4278255360&u)>>>8)>>>0)/4294967296;var c=Math.sqrt((1-u)/(1+(s*s-1)*u));r[l]=c}for(l=0;l65535?Uint32Array:Uint16Array,y=this.indices=new v(e*t*6),_=this.radius,b=this.phiStart,x=this.phiLength,w=this.thetaStart,O=this.thetaLength,S=(_=this.radius,[]),T=[],M=0,A=1/_;for(d=0;d<=t;d++)for(h=0;h<=e;h++)u=h/e,c=d/t,o=-_*Math.cos(b+u*x)*Math.sin(w+c*O),s=_*Math.cos(w+c*O),l=_*Math.sin(b+u*x)*Math.sin(w+c*O),S[0]=o,S[1]=s,S[2]=l,T[0]=u,T[1]=c,n.set(M,S),i.set(M,T),S[0]*=A,S[1]*=A,S[2]*=A,r.set(M,S),M++;var C=e+1,I=0;for(d=0;d=0&&l.splice(t,1)})),l.push(u),this.__zr&&this.__zr.animation.addAnimator(u),u},stopAnimation:function(t){this._animators=this._animators||[];for(var e=this._animators,n=e.length,i=0;i 1e-4)\n{\n skinMatrixWS += getSkinMatrix(joint.y) * weight.y;\n}\nif (weight.z > 1e-4)\n{\n skinMatrixWS += getSkinMatrix(joint.z) * weight.z;\n}\nfloat weightW = 1.0-weight.x-weight.y-weight.z;\nif (weightW > 1e-4)\n{\n skinMatrixWS += getSkinMatrix(joint.w) * weightW;\n}\n@end\n@export clay.chunk.instancing_header\n#ifdef INSTANCING\nattribute vec4 instanceMat1;\nattribute vec4 instanceMat2;\nattribute vec4 instanceMat3;\n#endif\n@end\n@export clay.chunk.instancing_matrix\nmat4 instanceMat = mat4(\n vec4(instanceMat1.xyz, 0.0),\n vec4(instanceMat2.xyz, 0.0),\n vec4(instanceMat3.xyz, 0.0),\n vec4(instanceMat1.w, instanceMat2.w, instanceMat3.w, 1.0)\n);\n@end\n@export clay.util.parallax_correct\nvec3 parallaxCorrect(in vec3 dir, in vec3 pos, in vec3 boxMin, in vec3 boxMax) {\n vec3 first = (boxMax - pos) / dir;\n vec3 second = (boxMin - pos) / dir;\n vec3 further = max(first, second);\n float dist = min(further.x, min(further.y, further.z));\n vec3 fixedPos = pos + dir * dist;\n vec3 boxCenter = (boxMax + boxMin) * 0.5;\n return normalize(fixedPos - boxCenter);\n}\n@end\n@export clay.util.clamp_sample\nvec4 clampSample(const in sampler2D texture, const in vec2 coord)\n{\n#ifdef STEREO\n float eye = step(0.5, coord.x) * 0.5;\n vec2 coordClamped = clamp(coord, vec2(eye, 0.0), vec2(0.5 + eye, 1.0));\n#else\n vec2 coordClamped = clamp(coord, vec2(0.0), vec2(1.0));\n#endif\n return texture2D(texture, coordClamped);\n}\n@end\n@export clay.util.ACES\nvec3 ACESToneMapping(vec3 color)\n{\n const float A = 2.51;\n const float B = 0.03;\n const float C = 2.43;\n const float D = 0.59;\n const float E = 0.14;\n return (color * (A * color + B)) / (color * (C * color + D) + E);\n}\n@end",ua="\n@export ecgl.common.transformUniforms\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nuniform mat4 worldInverseTranspose : WORLDINVERSETRANSPOSE;\nuniform mat4 world : WORLD;\n@end\n\n@export ecgl.common.attributes\nattribute vec3 position : POSITION;\nattribute vec2 texcoord : TEXCOORD_0;\nattribute vec3 normal : NORMAL;\n@end\n\n@export ecgl.common.uv.header\nuniform vec2 uvRepeat : [1.0, 1.0];\nuniform vec2 uvOffset : [0.0, 0.0];\nuniform vec2 detailUvRepeat : [1.0, 1.0];\nuniform vec2 detailUvOffset : [0.0, 0.0];\n\nvarying vec2 v_Texcoord;\nvarying vec2 v_DetailTexcoord;\n@end\n\n@export ecgl.common.uv.main\nv_Texcoord = texcoord * uvRepeat + uvOffset;\nv_DetailTexcoord = texcoord * detailUvRepeat + detailUvOffset;\n@end\n\n@export ecgl.common.uv.fragmentHeader\nvarying vec2 v_Texcoord;\nvarying vec2 v_DetailTexcoord;\n@end\n\n\n@export ecgl.common.albedo.main\n\n vec4 albedoTexel = vec4(1.0);\n#ifdef DIFFUSEMAP_ENABLED\n albedoTexel = texture2D(diffuseMap, v_Texcoord);\n #ifdef SRGB_DECODE\n albedoTexel = sRGBToLinear(albedoTexel);\n #endif\n#endif\n\n#ifdef DETAILMAP_ENABLED\n vec4 detailTexel = texture2D(detailMap, v_DetailTexcoord);\n #ifdef SRGB_DECODE\n detailTexel = sRGBToLinear(detailTexel);\n #endif\n albedoTexel.rgb = mix(albedoTexel.rgb, detailTexel.rgb, detailTexel.a);\n albedoTexel.a = detailTexel.a + (1.0 - detailTexel.a) * albedoTexel.a;\n#endif\n\n@end\n\n@export ecgl.common.wireframe.vertexHeader\n\n#ifdef WIREFRAME_QUAD\nattribute vec4 barycentric;\nvarying vec4 v_Barycentric;\n#elif defined(WIREFRAME_TRIANGLE)\nattribute vec3 barycentric;\nvarying vec3 v_Barycentric;\n#endif\n\n@end\n\n@export ecgl.common.wireframe.vertexMain\n\n#if defined(WIREFRAME_QUAD) || defined(WIREFRAME_TRIANGLE)\n v_Barycentric = barycentric;\n#endif\n\n@end\n\n\n@export ecgl.common.wireframe.fragmentHeader\n\nuniform float wireframeLineWidth : 1;\nuniform vec4 wireframeLineColor: [0, 0, 0, 0.5];\n\n#ifdef WIREFRAME_QUAD\nvarying vec4 v_Barycentric;\nfloat edgeFactor () {\n vec4 d = fwidth(v_Barycentric);\n vec4 a4 = smoothstep(vec4(0.0), d * wireframeLineWidth, v_Barycentric);\n return min(min(min(a4.x, a4.y), a4.z), a4.w);\n}\n#elif defined(WIREFRAME_TRIANGLE)\nvarying vec3 v_Barycentric;\nfloat edgeFactor () {\n vec3 d = fwidth(v_Barycentric);\n vec3 a3 = smoothstep(vec3(0.0), d * wireframeLineWidth, v_Barycentric);\n return min(min(a3.x, a3.y), a3.z);\n}\n#endif\n\n@end\n\n\n@export ecgl.common.wireframe.fragmentMain\n\n#if defined(WIREFRAME_QUAD) || defined(WIREFRAME_TRIANGLE)\n if (wireframeLineWidth > 0.) {\n vec4 lineColor = wireframeLineColor;\n#ifdef SRGB_DECODE\n lineColor = sRGBToLinear(lineColor);\n#endif\n\n gl_FragColor.rgb = mix(gl_FragColor.rgb, lineColor.rgb, (1.0 - edgeFactor()) * lineColor.a);\n }\n#endif\n@end\n\n\n\n\n@export ecgl.common.bumpMap.header\n\n#ifdef BUMPMAP_ENABLED\nuniform sampler2D bumpMap;\nuniform float bumpScale : 1.0;\n\n\nvec3 bumpNormal(vec3 surfPos, vec3 surfNormal, vec3 baseNormal)\n{\n vec2 dSTdx = dFdx(v_Texcoord);\n vec2 dSTdy = dFdy(v_Texcoord);\n\n float Hll = bumpScale * texture2D(bumpMap, v_Texcoord).x;\n float dHx = bumpScale * texture2D(bumpMap, v_Texcoord + dSTdx).x - Hll;\n float dHy = bumpScale * texture2D(bumpMap, v_Texcoord + dSTdy).x - Hll;\n\n vec3 vSigmaX = dFdx(surfPos);\n vec3 vSigmaY = dFdy(surfPos);\n vec3 vN = surfNormal;\n\n vec3 R1 = cross(vSigmaY, vN);\n vec3 R2 = cross(vN, vSigmaX);\n\n float fDet = dot(vSigmaX, R1);\n\n vec3 vGrad = sign(fDet) * (dHx * R1 + dHy * R2);\n return normalize(abs(fDet) * baseNormal - vGrad);\n\n}\n#endif\n\n@end\n\n@export ecgl.common.normalMap.vertexHeader\n\n#ifdef NORMALMAP_ENABLED\nattribute vec4 tangent : TANGENT;\nvarying vec3 v_Tangent;\nvarying vec3 v_Bitangent;\n#endif\n\n@end\n\n@export ecgl.common.normalMap.vertexMain\n\n#ifdef NORMALMAP_ENABLED\n if (dot(tangent, tangent) > 0.0) {\n v_Tangent = normalize((worldInverseTranspose * vec4(tangent.xyz, 0.0)).xyz);\n v_Bitangent = normalize(cross(v_Normal, v_Tangent) * tangent.w);\n }\n#endif\n\n@end\n\n\n@export ecgl.common.normalMap.fragmentHeader\n\n#ifdef NORMALMAP_ENABLED\nuniform sampler2D normalMap;\nvarying vec3 v_Tangent;\nvarying vec3 v_Bitangent;\n#endif\n\n@end\n\n@export ecgl.common.normalMap.fragmentMain\n#ifdef NORMALMAP_ENABLED\n if (dot(v_Tangent, v_Tangent) > 0.0) {\n vec3 normalTexel = texture2D(normalMap, v_DetailTexcoord).xyz;\n if (dot(normalTexel, normalTexel) > 0.0) { N = normalTexel * 2.0 - 1.0;\n mat3 tbn = mat3(v_Tangent, v_Bitangent, v_Normal);\n N = normalize(tbn * N);\n }\n }\n#endif\n@end\n\n\n\n@export ecgl.common.vertexAnimation.header\n\n#ifdef VERTEX_ANIMATION\nattribute vec3 prevPosition;\nattribute vec3 prevNormal;\nuniform float percent;\n#endif\n\n@end\n\n@export ecgl.common.vertexAnimation.main\n\n#ifdef VERTEX_ANIMATION\n vec3 pos = mix(prevPosition, position, percent);\n vec3 norm = mix(prevNormal, normal, percent);\n#else\n vec3 pos = position;\n vec3 norm = normal;\n#endif\n\n@end\n\n\n@export ecgl.common.ssaoMap.header\n#ifdef SSAOMAP_ENABLED\nuniform sampler2D ssaoMap;\nuniform vec4 viewport : VIEWPORT;\n#endif\n@end\n\n@export ecgl.common.ssaoMap.main\n float ao = 1.0;\n#ifdef SSAOMAP_ENABLED\n ao = texture2D(ssaoMap, (gl_FragCoord.xy - viewport.xy) / viewport.zw).r;\n#endif\n@end\n\n\n\n\n@export ecgl.common.diffuseLayer.header\n\n#if (LAYER_DIFFUSEMAP_COUNT > 0)\nuniform float layerDiffuseIntensity[LAYER_DIFFUSEMAP_COUNT];\nuniform sampler2D layerDiffuseMap[LAYER_DIFFUSEMAP_COUNT];\n#endif\n\n@end\n\n@export ecgl.common.emissiveLayer.header\n\n#if (LAYER_EMISSIVEMAP_COUNT > 0)\nuniform float layerEmissionIntensity[LAYER_EMISSIVEMAP_COUNT];\nuniform sampler2D layerEmissiveMap[LAYER_EMISSIVEMAP_COUNT];\n#endif\n\n@end\n\n@export ecgl.common.layers.header\n@import ecgl.common.diffuseLayer.header\n@import ecgl.common.emissiveLayer.header\n@end\n\n@export ecgl.common.diffuseLayer.main\n\n#if (LAYER_DIFFUSEMAP_COUNT > 0)\n for (int _idx_ = 0; _idx_ < LAYER_DIFFUSEMAP_COUNT; _idx_++) {{\n float intensity = layerDiffuseIntensity[_idx_];\n vec4 texel2 = texture2D(layerDiffuseMap[_idx_], v_Texcoord);\n #ifdef SRGB_DECODE\n texel2 = sRGBToLinear(texel2);\n #endif\n albedoTexel.rgb = mix(albedoTexel.rgb, texel2.rgb * intensity, texel2.a);\n albedoTexel.a = texel2.a + (1.0 - texel2.a) * albedoTexel.a;\n }}\n#endif\n\n@end\n\n@export ecgl.common.emissiveLayer.main\n\n#if (LAYER_EMISSIVEMAP_COUNT > 0)\n for (int _idx_ = 0; _idx_ < LAYER_EMISSIVEMAP_COUNT; _idx_++)\n {{\n vec4 texel2 = texture2D(layerEmissiveMap[_idx_], v_Texcoord) * layerEmissionIntensity[_idx_];\n #ifdef SRGB_DECODE\n texel2 = sRGBToLinear(texel2);\n #endif\n float intensity = layerEmissionIntensity[_idx_];\n gl_FragColor.rgb += texel2.rgb * texel2.a * intensity;\n }}\n#endif\n\n@end\n",ca="@export ecgl.color.vertex\n\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\n\n@import ecgl.common.uv.header\n\nattribute vec2 texcoord : TEXCOORD_0;\nattribute vec3 position: POSITION;\n\n@import ecgl.common.wireframe.vertexHeader\n\n#ifdef VERTEX_COLOR\nattribute vec4 a_Color : COLOR;\nvarying vec4 v_Color;\n#endif\n\n#ifdef VERTEX_ANIMATION\nattribute vec3 prevPosition;\nuniform float percent : 1.0;\n#endif\n\n#ifdef ATMOSPHERE_ENABLED\nattribute vec3 normal: NORMAL;\nuniform mat4 worldInverseTranspose : WORLDINVERSETRANSPOSE;\nvarying vec3 v_Normal;\n#endif\n\nvoid main()\n{\n#ifdef VERTEX_ANIMATION\n vec3 pos = mix(prevPosition, position, percent);\n#else\n vec3 pos = position;\n#endif\n\n gl_Position = worldViewProjection * vec4(pos, 1.0);\n\n @import ecgl.common.uv.main\n\n#ifdef VERTEX_COLOR\n v_Color = a_Color;\n#endif\n\n#ifdef ATMOSPHERE_ENABLED\n v_Normal = normalize((worldInverseTranspose * vec4(normal, 0.0)).xyz);\n#endif\n\n @import ecgl.common.wireframe.vertexMain\n\n}\n\n@end\n\n@export ecgl.color.fragment\n\n#define LAYER_DIFFUSEMAP_COUNT 0\n#define LAYER_EMISSIVEMAP_COUNT 0\n\nuniform sampler2D diffuseMap;\nuniform sampler2D detailMap;\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\n\n#ifdef ATMOSPHERE_ENABLED\nuniform mat4 viewTranspose: VIEWTRANSPOSE;\nuniform vec3 glowColor;\nuniform float glowPower;\nvarying vec3 v_Normal;\n#endif\n\n#ifdef VERTEX_COLOR\nvarying vec4 v_Color;\n#endif\n\n@import ecgl.common.layers.header\n\n@import ecgl.common.uv.fragmentHeader\n\n@import ecgl.common.wireframe.fragmentHeader\n\n@import clay.util.srgb\n\nvoid main()\n{\n#ifdef SRGB_DECODE\n gl_FragColor = sRGBToLinear(color);\n#else\n gl_FragColor = color;\n#endif\n\n#ifdef VERTEX_COLOR\n gl_FragColor *= v_Color;\n#endif\n\n @import ecgl.common.albedo.main\n\n @import ecgl.common.diffuseLayer.main\n\n gl_FragColor *= albedoTexel;\n\n#ifdef ATMOSPHERE_ENABLED\n float atmoIntensity = pow(1.0 - dot(v_Normal, (viewTranspose * vec4(0.0, 0.0, 1.0, 0.0)).xyz), glowPower);\n gl_FragColor.rgb += glowColor * atmoIntensity;\n#endif\n\n @import ecgl.common.emissiveLayer.main\n\n @import ecgl.common.wireframe.fragmentMain\n\n}\n@end",ha="/**\n * http: */\n\n@export ecgl.lambert.vertex\n\n@import ecgl.common.transformUniforms\n\n@import ecgl.common.uv.header\n\n\n@import ecgl.common.attributes\n\n@import ecgl.common.wireframe.vertexHeader\n\n#ifdef VERTEX_COLOR\nattribute vec4 a_Color : COLOR;\nvarying vec4 v_Color;\n#endif\n\n\n@import ecgl.common.vertexAnimation.header\n\n\nvarying vec3 v_Normal;\nvarying vec3 v_WorldPosition;\n\nvoid main()\n{\n @import ecgl.common.uv.main\n\n @import ecgl.common.vertexAnimation.main\n\n\n gl_Position = worldViewProjection * vec4(pos, 1.0);\n\n v_Normal = normalize((worldInverseTranspose * vec4(norm, 0.0)).xyz);\n v_WorldPosition = (world * vec4(pos, 1.0)).xyz;\n\n#ifdef VERTEX_COLOR\n v_Color = a_Color;\n#endif\n\n @import ecgl.common.wireframe.vertexMain\n}\n\n@end\n\n\n@export ecgl.lambert.fragment\n\n#define LAYER_DIFFUSEMAP_COUNT 0\n#define LAYER_EMISSIVEMAP_COUNT 0\n\n#define NORMAL_UP_AXIS 1\n#define NORMAL_FRONT_AXIS 2\n\n@import ecgl.common.uv.fragmentHeader\n\nvarying vec3 v_Normal;\nvarying vec3 v_WorldPosition;\n\nuniform sampler2D diffuseMap;\nuniform sampler2D detailMap;\n\n@import ecgl.common.layers.header\n\nuniform float emissionIntensity: 1.0;\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\n\nuniform mat4 viewInverse : VIEWINVERSE;\n\n#ifdef ATMOSPHERE_ENABLED\nuniform mat4 viewTranspose: VIEWTRANSPOSE;\nuniform vec3 glowColor;\nuniform float glowPower;\n#endif\n\n#ifdef AMBIENT_LIGHT_COUNT\n@import clay.header.ambient_light\n#endif\n#ifdef AMBIENT_SH_LIGHT_COUNT\n@import clay.header.ambient_sh_light\n#endif\n\n#ifdef DIRECTIONAL_LIGHT_COUNT\n@import clay.header.directional_light\n#endif\n\n#ifdef VERTEX_COLOR\nvarying vec4 v_Color;\n#endif\n\n\n@import ecgl.common.ssaoMap.header\n\n@import ecgl.common.bumpMap.header\n\n@import clay.util.srgb\n\n@import ecgl.common.wireframe.fragmentHeader\n\n@import clay.plugin.compute_shadow_map\n\nvoid main()\n{\n#ifdef SRGB_DECODE\n gl_FragColor = sRGBToLinear(color);\n#else\n gl_FragColor = color;\n#endif\n\n#ifdef VERTEX_COLOR\n #ifdef SRGB_DECODE\n gl_FragColor *= sRGBToLinear(v_Color);\n #else\n gl_FragColor *= v_Color;\n #endif\n#endif\n\n @import ecgl.common.albedo.main\n\n @import ecgl.common.diffuseLayer.main\n\n gl_FragColor *= albedoTexel;\n\n vec3 N = v_Normal;\n#ifdef DOUBLE_SIDED\n vec3 eyePos = viewInverse[3].xyz;\n vec3 V = normalize(eyePos - v_WorldPosition);\n\n if (dot(N, V) < 0.0) {\n N = -N;\n }\n#endif\n\n float ambientFactor = 1.0;\n\n#ifdef BUMPMAP_ENABLED\n N = bumpNormal(v_WorldPosition, v_Normal, N);\n ambientFactor = dot(v_Normal, N);\n#endif\n\n vec3 N2 = vec3(N.x, N[NORMAL_UP_AXIS], N[NORMAL_FRONT_AXIS]);\n\n vec3 diffuseColor = vec3(0.0, 0.0, 0.0);\n\n @import ecgl.common.ssaoMap.main\n\n#ifdef AMBIENT_LIGHT_COUNT\n for(int i = 0; i < AMBIENT_LIGHT_COUNT; i++)\n {\n diffuseColor += ambientLightColor[i] * ambientFactor * ao;\n }\n#endif\n#ifdef AMBIENT_SH_LIGHT_COUNT\n for(int _idx_ = 0; _idx_ < AMBIENT_SH_LIGHT_COUNT; _idx_++)\n {{\n diffuseColor += calcAmbientSHLight(_idx_, N2) * ambientSHLightColor[_idx_] * ao;\n }}\n#endif\n#ifdef DIRECTIONAL_LIGHT_COUNT\n#if defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT)\n float shadowContribsDir[DIRECTIONAL_LIGHT_COUNT];\n if(shadowEnabled)\n {\n computeShadowOfDirectionalLights(v_WorldPosition, shadowContribsDir);\n }\n#endif\n for(int i = 0; i < DIRECTIONAL_LIGHT_COUNT; i++)\n {\n vec3 lightDirection = -directionalLightDirection[i];\n vec3 lightColor = directionalLightColor[i];\n\n float shadowContrib = 1.0;\n#if defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT)\n if (shadowEnabled)\n {\n shadowContrib = shadowContribsDir[i];\n }\n#endif\n\n float ndl = dot(N, normalize(lightDirection)) * shadowContrib;\n\n diffuseColor += lightColor * clamp(ndl, 0.0, 1.0);\n }\n#endif\n\n gl_FragColor.rgb *= diffuseColor;\n\n#ifdef ATMOSPHERE_ENABLED\n float atmoIntensity = pow(1.0 - dot(v_Normal, (viewTranspose * vec4(0.0, 0.0, 1.0, 0.0)).xyz), glowPower);\n gl_FragColor.rgb += glowColor * atmoIntensity;\n#endif\n\n @import ecgl.common.emissiveLayer.main\n\n @import ecgl.common.wireframe.fragmentMain\n}\n\n@end",da="@export ecgl.realistic.vertex\n\n@import ecgl.common.transformUniforms\n\n@import ecgl.common.uv.header\n\n@import ecgl.common.attributes\n\n\n@import ecgl.common.wireframe.vertexHeader\n\n#ifdef VERTEX_COLOR\nattribute vec4 a_Color : COLOR;\nvarying vec4 v_Color;\n#endif\n\n#ifdef NORMALMAP_ENABLED\nattribute vec4 tangent : TANGENT;\nvarying vec3 v_Tangent;\nvarying vec3 v_Bitangent;\n#endif\n\n@import ecgl.common.vertexAnimation.header\n\nvarying vec3 v_Normal;\nvarying vec3 v_WorldPosition;\n\nvoid main()\n{\n\n @import ecgl.common.uv.main\n\n @import ecgl.common.vertexAnimation.main\n\n gl_Position = worldViewProjection * vec4(pos, 1.0);\n\n v_Normal = normalize((worldInverseTranspose * vec4(norm, 0.0)).xyz);\n v_WorldPosition = (world * vec4(pos, 1.0)).xyz;\n\n#ifdef VERTEX_COLOR\n v_Color = a_Color;\n#endif\n\n#ifdef NORMALMAP_ENABLED\n v_Tangent = normalize((worldInverseTranspose * vec4(tangent.xyz, 0.0)).xyz);\n v_Bitangent = normalize(cross(v_Normal, v_Tangent) * tangent.w);\n#endif\n\n @import ecgl.common.wireframe.vertexMain\n\n}\n\n@end\n\n\n\n@export ecgl.realistic.fragment\n\n#define LAYER_DIFFUSEMAP_COUNT 0\n#define LAYER_EMISSIVEMAP_COUNT 0\n#define PI 3.14159265358979\n#define ROUGHNESS_CHANEL 0\n#define METALNESS_CHANEL 1\n\n#define NORMAL_UP_AXIS 1\n#define NORMAL_FRONT_AXIS 2\n\n#ifdef VERTEX_COLOR\nvarying vec4 v_Color;\n#endif\n\n@import ecgl.common.uv.fragmentHeader\n\nvarying vec3 v_Normal;\nvarying vec3 v_WorldPosition;\n\nuniform sampler2D diffuseMap;\n\nuniform sampler2D detailMap;\nuniform sampler2D metalnessMap;\nuniform sampler2D roughnessMap;\n\n@import ecgl.common.layers.header\n\nuniform float emissionIntensity: 1.0;\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\n\nuniform float metalness : 0.0;\nuniform float roughness : 0.5;\n\nuniform mat4 viewInverse : VIEWINVERSE;\n\n#ifdef ATMOSPHERE_ENABLED\nuniform mat4 viewTranspose: VIEWTRANSPOSE;\nuniform vec3 glowColor;\nuniform float glowPower;\n#endif\n\n#ifdef AMBIENT_LIGHT_COUNT\n@import clay.header.ambient_light\n#endif\n\n#ifdef AMBIENT_SH_LIGHT_COUNT\n@import clay.header.ambient_sh_light\n#endif\n\n#ifdef AMBIENT_CUBEMAP_LIGHT_COUNT\n@import clay.header.ambient_cubemap_light\n#endif\n\n#ifdef DIRECTIONAL_LIGHT_COUNT\n@import clay.header.directional_light\n#endif\n\n@import ecgl.common.normalMap.fragmentHeader\n\n@import ecgl.common.ssaoMap.header\n\n@import ecgl.common.bumpMap.header\n\n@import clay.util.srgb\n\n@import clay.util.rgbm\n\n@import ecgl.common.wireframe.fragmentHeader\n\n@import clay.plugin.compute_shadow_map\n\nvec3 F_Schlick(float ndv, vec3 spec) {\n return spec + (1.0 - spec) * pow(1.0 - ndv, 5.0);\n}\n\nfloat D_Phong(float g, float ndh) {\n float a = pow(8192.0, g);\n return (a + 2.0) / 8.0 * pow(ndh, a);\n}\n\nvoid main()\n{\n vec4 albedoColor = color;\n\n vec3 eyePos = viewInverse[3].xyz;\n vec3 V = normalize(eyePos - v_WorldPosition);\n#ifdef VERTEX_COLOR\n #ifdef SRGB_DECODE\n albedoColor *= sRGBToLinear(v_Color);\n #else\n albedoColor *= v_Color;\n #endif\n#endif\n\n @import ecgl.common.albedo.main\n\n @import ecgl.common.diffuseLayer.main\n\n albedoColor *= albedoTexel;\n\n float m = metalness;\n\n#ifdef METALNESSMAP_ENABLED\n float m2 = texture2D(metalnessMap, v_DetailTexcoord)[METALNESS_CHANEL];\n m = clamp(m2 + (m - 0.5) * 2.0, 0.0, 1.0);\n#endif\n\n vec3 baseColor = albedoColor.rgb;\n albedoColor.rgb = baseColor * (1.0 - m);\n vec3 specFactor = mix(vec3(0.04), baseColor, m);\n\n float g = 1.0 - roughness;\n\n#ifdef ROUGHNESSMAP_ENABLED\n float g2 = 1.0 - texture2D(roughnessMap, v_DetailTexcoord)[ROUGHNESS_CHANEL];\n g = clamp(g2 + (g - 0.5) * 2.0, 0.0, 1.0);\n#endif\n\n vec3 N = v_Normal;\n\n#ifdef DOUBLE_SIDED\n if (dot(N, V) < 0.0) {\n N = -N;\n }\n#endif\n\n float ambientFactor = 1.0;\n\n#ifdef BUMPMAP_ENABLED\n N = bumpNormal(v_WorldPosition, v_Normal, N);\n ambientFactor = dot(v_Normal, N);\n#endif\n\n@import ecgl.common.normalMap.fragmentMain\n\n vec3 N2 = vec3(N.x, N[NORMAL_UP_AXIS], N[NORMAL_FRONT_AXIS]);\n\n vec3 diffuseTerm = vec3(0.0);\n vec3 specularTerm = vec3(0.0);\n\n float ndv = clamp(dot(N, V), 0.0, 1.0);\n vec3 fresnelTerm = F_Schlick(ndv, specFactor);\n\n @import ecgl.common.ssaoMap.main\n\n#ifdef AMBIENT_LIGHT_COUNT\n for(int _idx_ = 0; _idx_ < AMBIENT_LIGHT_COUNT; _idx_++)\n {{\n diffuseTerm += ambientLightColor[_idx_] * ambientFactor * ao;\n }}\n#endif\n\n#ifdef AMBIENT_SH_LIGHT_COUNT\n for(int _idx_ = 0; _idx_ < AMBIENT_SH_LIGHT_COUNT; _idx_++)\n {{\n diffuseTerm += calcAmbientSHLight(_idx_, N2) * ambientSHLightColor[_idx_] * ao;\n }}\n#endif\n\n#ifdef DIRECTIONAL_LIGHT_COUNT\n#if defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT)\n float shadowContribsDir[DIRECTIONAL_LIGHT_COUNT];\n if(shadowEnabled)\n {\n computeShadowOfDirectionalLights(v_WorldPosition, shadowContribsDir);\n }\n#endif\n for(int _idx_ = 0; _idx_ < DIRECTIONAL_LIGHT_COUNT; _idx_++)\n {{\n vec3 L = -directionalLightDirection[_idx_];\n vec3 lc = directionalLightColor[_idx_];\n\n vec3 H = normalize(L + V);\n float ndl = clamp(dot(N, normalize(L)), 0.0, 1.0);\n float ndh = clamp(dot(N, H), 0.0, 1.0);\n\n float shadowContrib = 1.0;\n#if defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT)\n if (shadowEnabled)\n {\n shadowContrib = shadowContribsDir[_idx_];\n }\n#endif\n\n vec3 li = lc * ndl * shadowContrib;\n\n diffuseTerm += li;\n specularTerm += li * fresnelTerm * D_Phong(g, ndh);\n }}\n#endif\n\n\n#ifdef AMBIENT_CUBEMAP_LIGHT_COUNT\n vec3 L = reflect(-V, N);\n L = vec3(L.x, L[NORMAL_UP_AXIS], L[NORMAL_FRONT_AXIS]);\n float rough2 = clamp(1.0 - g, 0.0, 1.0);\n float bias2 = rough2 * 5.0;\n vec2 brdfParam2 = texture2D(ambientCubemapLightBRDFLookup[0], vec2(rough2, ndv)).xy;\n vec3 envWeight2 = specFactor * brdfParam2.x + brdfParam2.y;\n vec3 envTexel2;\n for(int _idx_ = 0; _idx_ < AMBIENT_CUBEMAP_LIGHT_COUNT; _idx_++)\n {{\n envTexel2 = RGBMDecode(textureCubeLodEXT(ambientCubemapLightCubemap[_idx_], L, bias2), 8.12);\n specularTerm += ambientCubemapLightColor[_idx_] * envTexel2 * envWeight2 * ao;\n }}\n#endif\n\n gl_FragColor.rgb = albedoColor.rgb * diffuseTerm + specularTerm;\n gl_FragColor.a = albedoColor.a;\n\n#ifdef ATMOSPHERE_ENABLED\n float atmoIntensity = pow(1.0 - dot(v_Normal, (viewTranspose * vec4(0.0, 0.0, 1.0, 0.0)).xyz), glowPower);\n gl_FragColor.rgb += glowColor * atmoIntensity;\n#endif\n\n#ifdef SRGB_ENCODE\n gl_FragColor = linearTosRGB(gl_FragColor);\n#endif\n\n @import ecgl.common.emissiveLayer.main\n\n @import ecgl.common.wireframe.fragmentMain\n}\n\n@end",fa="@export ecgl.hatching.vertex\n\n@import ecgl.realistic.vertex\n\n@end\n\n\n@export ecgl.hatching.fragment\n\n#define NORMAL_UP_AXIS 1\n#define NORMAL_FRONT_AXIS 2\n\n@import ecgl.common.uv.fragmentHeader\n\nvarying vec3 v_Normal;\nvarying vec3 v_WorldPosition;\n\nuniform vec4 color : [0.0, 0.0, 0.0, 1.0];\nuniform vec4 paperColor : [1.0, 1.0, 1.0, 1.0];\n\nuniform mat4 viewInverse : VIEWINVERSE;\n\n#ifdef AMBIENT_LIGHT_COUNT\n@import clay.header.ambient_light\n#endif\n#ifdef AMBIENT_SH_LIGHT_COUNT\n@import clay.header.ambient_sh_light\n#endif\n\n#ifdef DIRECTIONAL_LIGHT_COUNT\n@import clay.header.directional_light\n#endif\n\n#ifdef VERTEX_COLOR\nvarying vec4 v_Color;\n#endif\n\n\n@import ecgl.common.ssaoMap.header\n\n@import ecgl.common.bumpMap.header\n\n@import clay.util.srgb\n\n@import ecgl.common.wireframe.fragmentHeader\n\n@import clay.plugin.compute_shadow_map\n\nuniform sampler2D hatch1;\nuniform sampler2D hatch2;\nuniform sampler2D hatch3;\nuniform sampler2D hatch4;\nuniform sampler2D hatch5;\nuniform sampler2D hatch6;\n\nfloat shade(in float tone) {\n vec4 c = vec4(1. ,1., 1., 1.);\n float step = 1. / 6.;\n vec2 uv = v_DetailTexcoord;\n if (tone <= step / 2.0) {\n c = mix(vec4(0.), texture2D(hatch6, uv), 12. * tone);\n }\n else if (tone <= step) {\n c = mix(texture2D(hatch6, uv), texture2D(hatch5, uv), 6. * tone);\n }\n if(tone > step && tone <= 2. * step){\n c = mix(texture2D(hatch5, uv), texture2D(hatch4, uv) , 6. * (tone - step));\n }\n if(tone > 2. * step && tone <= 3. * step){\n c = mix(texture2D(hatch4, uv), texture2D(hatch3, uv), 6. * (tone - 2. * step));\n }\n if(tone > 3. * step && tone <= 4. * step){\n c = mix(texture2D(hatch3, uv), texture2D(hatch2, uv), 6. * (tone - 3. * step));\n }\n if(tone > 4. * step && tone <= 5. * step){\n c = mix(texture2D(hatch2, uv), texture2D(hatch1, uv), 6. * (tone - 4. * step));\n }\n if(tone > 5. * step){\n c = mix(texture2D(hatch1, uv), vec4(1.), 6. * (tone - 5. * step));\n }\n\n return c.r;\n}\n\nconst vec3 w = vec3(0.2125, 0.7154, 0.0721);\n\nvoid main()\n{\n#ifdef SRGB_DECODE\n vec4 inkColor = sRGBToLinear(color);\n#else\n vec4 inkColor = color;\n#endif\n\n#ifdef VERTEX_COLOR\n #ifdef SRGB_DECODE\n inkColor *= sRGBToLinear(v_Color);\n #else\n inkColor *= v_Color;\n #endif\n#endif\n\n vec3 N = v_Normal;\n#ifdef DOUBLE_SIDED\n vec3 eyePos = viewInverse[3].xyz;\n vec3 V = normalize(eyePos - v_WorldPosition);\n\n if (dot(N, V) < 0.0) {\n N = -N;\n }\n#endif\n\n float tone = 0.0;\n\n float ambientFactor = 1.0;\n\n#ifdef BUMPMAP_ENABLED\n N = bumpNormal(v_WorldPosition, v_Normal, N);\n ambientFactor = dot(v_Normal, N);\n#endif\n\n vec3 N2 = vec3(N.x, N[NORMAL_UP_AXIS], N[NORMAL_FRONT_AXIS]);\n\n @import ecgl.common.ssaoMap.main\n\n#ifdef AMBIENT_LIGHT_COUNT\n for(int i = 0; i < AMBIENT_LIGHT_COUNT; i++)\n {\n tone += dot(ambientLightColor[i], w) * ambientFactor * ao;\n }\n#endif\n#ifdef AMBIENT_SH_LIGHT_COUNT\n for(int _idx_ = 0; _idx_ < AMBIENT_SH_LIGHT_COUNT; _idx_++)\n {{\n tone += dot(calcAmbientSHLight(_idx_, N2) * ambientSHLightColor[_idx_], w) * ao;\n }}\n#endif\n#ifdef DIRECTIONAL_LIGHT_COUNT\n#if defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT)\n float shadowContribsDir[DIRECTIONAL_LIGHT_COUNT];\n if(shadowEnabled)\n {\n computeShadowOfDirectionalLights(v_WorldPosition, shadowContribsDir);\n }\n#endif\n for(int i = 0; i < DIRECTIONAL_LIGHT_COUNT; i++)\n {\n vec3 lightDirection = -directionalLightDirection[i];\n float lightTone = dot(directionalLightColor[i], w);\n\n float shadowContrib = 1.0;\n#if defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT)\n if (shadowEnabled)\n {\n shadowContrib = shadowContribsDir[i];\n }\n#endif\n\n float ndl = dot(N, normalize(lightDirection)) * shadowContrib;\n\n tone += lightTone * clamp(ndl, 0.0, 1.0);\n }\n#endif\n\n gl_FragColor = mix(inkColor, paperColor, shade(clamp(tone, 0.0, 1.0)));\n }\n@end\n",pa="@export ecgl.sm.depth.vertex\n\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\n\nattribute vec3 position : POSITION;\nattribute vec2 texcoord : TEXCOORD_0;\n\n#ifdef VERTEX_ANIMATION\nattribute vec3 prevPosition;\nuniform float percent : 1.0;\n#endif\n\nvarying vec4 v_ViewPosition;\nvarying vec2 v_Texcoord;\n\nvoid main(){\n\n#ifdef VERTEX_ANIMATION\n vec3 pos = mix(prevPosition, position, percent);\n#else\n vec3 pos = position;\n#endif\n\n v_ViewPosition = worldViewProjection * vec4(pos, 1.0);\n gl_Position = v_ViewPosition;\n\n v_Texcoord = texcoord;\n\n}\n@end\n\n\n\n@export ecgl.sm.depth.fragment\n\n@import clay.sm.depth.fragment\n\n@end";function ga(t){return!t||"none"===t}function ma(t){return t instanceof HTMLCanvasElement||t instanceof HTMLImageElement||t instanceof Image}function va(t){return t.getZr&&t.setOption}Object.assign(Ge.prototype,sa),Xt.import(la),Xt.import(Zt),Xt.import(ua),Xt.import(ca),Xt.import(ha),Xt.import(da),Xt.import(fa),Xt.import(pa);var ya=qn.prototype.addToScene,_a=qn.prototype.removeFromScene;qn.prototype.addToScene=function(t){if(ya.call(this,t),this.__zr){var e=this.__zr;t.traverse((function(t){t.__zr=e,t.addAnimatorsToZr&&t.addAnimatorsToZr(e)}))}},qn.prototype.removeFromScene=function(t){_a.call(this,t),t.traverse((function(t){var e=t.__zr;t.__zr=null,e&&t.removeAnimatorsFromZr&&t.removeAnimatorsFromZr(e)}))},nt.prototype.setTextureImage=function(t,e,n,i){if(this.shader){var r,a=n.getZr(),o=this;return o.autoUpdateTextureStatus=!1,o.disableTexture(t),ga(e)||(r=ba.loadTexture(e,n,i,(function(e){o.enableTexture(t),a&&a.refresh()})),o.set(t,r)),r}};var ba={};ba.Renderer=ce,ba.Node=Ge,ba.Mesh=$e,ba.Shader=Xt,ba.Material=nt,ba.Texture=Qe,ba.Texture2D=sn,ba.Geometry=bn,ba.SphereGeometry=Rr,ba.PlaneGeometry=_i,ba.CubeGeometry=Oi,ba.AmbientLight=Br,ba.DirectionalLight=Vr,ba.PointLight=Gr,ba.SpotLight=Ur,ba.PerspectiveCamera=ni,ba.OrthographicCamera=hr,ba.Vector2=ct,ba.Vector3=ye,ba.Vector4=qr,ba.Quaternion=Ne,ba.Matrix2=Jr,ba.Matrix2d=na,ba.Matrix3=ra,ba.Matrix4=Le,ba.Plane=Ln,ba.Ray=xe,ba.BoundingBox=ze,ba.Frustum=Bn;var xa=null;function wa(){return null!==xa||(xa=ar.createBlank("rgba(255,255,255,0)").image),xa}function Oa(t){return Math.pow(2,Math.round(Math.log(t)/Math.LN2))}function Sa(t){if((t.wrapS===Qe.REPEAT||t.wrapT===Qe.REPEAT)&&t.image){var e=Oa(t.width),n=Oa(t.height);if(e!==t.width||n!==t.height){var i=document.createElement("canvas");i.width=e,i.height=n;var r=i.getContext("2d");r.drawImage(t.image,0,0,e,n),t.image=i}}}ba.loadTexture=function(t,e,n,i){"function"===typeof n&&(i=n,n={}),n=n||{};for(var r=Object.keys(n).sort(),a="",o=0;o3?e[3]=t[3]:e[3]=1,e):(e=a["h"].parse(t||"#000",e)||[0,0,0,0],e[0]/=255,e[1]/=255,e[2]/=255,e)},ba.directionFromAlphaBeta=function(t,e){var n=t/180*Math.PI+Math.PI/2,i=-e/180*Math.PI+Math.PI/2,r=[],a=Math.sin(n);return r[0]=a*Math.cos(i),r[1]=-Math.cos(n),r[2]=a*Math.sin(i),r},ba.getShadowResolution=function(t){var e=1024;switch(t){case"low":e=512;break;case"medium":break;case"high":e=2048;break;case"ultra":e=4096;break}return e},ba.COMMON_SHADERS=["lambert","color","realistic","hatching","shadow"],ba.createShader=function(t){"ecgl.shadow"===t&&(t="ecgl.displayShadow");var e=Xt.source(t+".vertex"),n=Xt.source(t+".fragment");e||console.error("Vertex shader of '%s' not exits",t),n||console.error("Fragment shader of '%s' not exits",t);var i=new Xt(e,n);return i.name=t,i},ba.createMaterial=function(t,e){e instanceof Array||(e=[e]);var n=ba.createShader(t),i=new nt({shader:n});return e.forEach((function(t){"string"===typeof t&&i.define(t)})),i},ba.setMaterialFromModel=function(t,e,n,i){e.autoUpdateTextureStatus=!1;var r=n.getModel(t+"Material"),a=r.get("detailTexture"),o=Pr.firstNotNull(r.get("textureTiling"),1),s=Pr.firstNotNull(r.get("textureOffset"),0);"number"===typeof o&&(o=[o,o]),"number"===typeof s&&(s=[s,s]);var l=o[0]>1||o[1]>1?ba.Texture.REPEAT:ba.Texture.CLAMP_TO_EDGE,u={anisotropic:8,wrapS:l,wrapT:l};if("realistic"===t){var c=r.get("roughness"),h=r.get("metalness");null!=h?isNaN(h)&&(e.setTextureImage("metalnessMap",h,i,u),h=Pr.firstNotNull(r.get("metalnessAdjust"),.5)):h=0,null!=c?isNaN(c)&&(e.setTextureImage("roughnessMap",c,i,u),c=Pr.firstNotNull(r.get("roughnessAdjust"),.5)):c=.5;var d=r.get("normalTexture");e.setTextureImage("detailMap",a,i,u),e.setTextureImage("normalMap",d,i,u),e.set({roughness:c,metalness:h,detailUvRepeat:o,detailUvOffset:s})}else if("lambert"===t)e.setTextureImage("detailMap",a,i,u),e.set({detailUvRepeat:o,detailUvOffset:s});else if("color"===t)e.setTextureImage("detailMap",a,i,u),e.set({detailUvRepeat:o,detailUvOffset:s});else if("hatching"===t){var f=r.get("hatchingTextures")||[];f.length;for(var p=0;p<6;p++)e.setTextureImage("hatch"+(p+1),f[p],i,{anisotropic:8,wrapS:ba.Texture.REPEAT,wrapT:ba.Texture.REPEAT});e.set({detailUvRepeat:o,detailUvOffset:s})}},ba.updateVertexAnimation=function(t,e,n,i){var r=i.get("animation"),a=i.get("animationDurationUpdate"),o=i.get("animationEasingUpdate"),s=n.shadowDepthMaterial;if(r&&e&&a>0&&e.geometry.vertexCount===n.geometry.vertexCount){n.material.define("vertex","VERTEX_ANIMATION"),n.ignorePreZ=!0,s&&s.define("vertex","VERTEX_ANIMATION");for(var l=0;l=0&&this._viewsToDispose.splice(e,1),this.views.push(t),t.layer=this;var n=this.zr;t.scene.traverse((function(t){t.__zr=n,t.addAnimatorsToZr&&t.addAnimatorsToZr(n)}))}},Aa.prototype.removeView=function(t){if(t.layer===this){var e=this.views.indexOf(t);e>=0&&(this.views.splice(e,1),t.scene.traverse(Ca,this),t.layer=null,this._viewsToDispose.push(t))}},Aa.prototype.removeViewsAll=function(){this.views.forEach((function(t){t.scene.traverse(Ca,this),t.layer=null,this._viewsToDispose.push(t)}),this),this.views.length=0},Aa.prototype.resize=function(t,e){var n=this.renderer;n.resize(t,e)},Aa.prototype.clear=function(){var t=this.renderer.gl,e=this._backgroundColor||[0,0,0,0];t.clearColor(e[0],e[1],e[2],e[3]),t.depthMask(!0),t.colorMask(!0,!0,!0,!0),t.clear(t.DEPTH_BUFFER_BIT|t.COLOR_BUFFER_BIT)},Aa.prototype.clearDepth=function(){var t=this.renderer.gl;t.clear(t.DEPTH_BUFFER_BIT)},Aa.prototype.clearColor=function(){var t=this.renderer.gl;t.clearColor(0,0,0,0),t.clear(t.COLOR_BUFFER_BIT)},Aa.prototype.needsRefresh=function(){this.zr.refresh()},Aa.prototype.refresh=function(t){this._backgroundColor=t?Ta.parseColor(t):[0,0,0,0],this.renderer.clearColor=this._backgroundColor;for(var e=0;e20)){t=t.event;var i=this.pickObject(t.offsetX,t.offsetY);i&&(this._dispatchEvent(t.type,t,i),this._dispatchDataEvent(t.type,t,i));var r=this._clickToSetFocusPoint(t);if(r){var a=r.view.setDOFFocusOnPoint(r.distance);a&&this.zr.refresh()}}}},Aa.prototype._clickToSetFocusPoint=function(t){for(var e=this.renderer,n=e.viewport,i=this.views.length-1;i>=0;i--){var r=this.views[i];if(r.hasDOF()&&r.containPoint(t.offsetX,t.offsetY)){this._picking.scene=r.scene,this._picking.camera=r.camera,e.viewport=r.viewport;var a=this._picking.pick(t.offsetX,t.offsetY,!0);if(a)return a.view=r,a}}e.viewport=n},Aa.prototype.onglobalout=function(t){var e=this._hovered;e&&this._dispatchEvent("mouseout",t,{target:e.target})},Aa.prototype.pickObject=function(t,e){for(var n=[],i=this.renderer,r=i.viewport,a=0;a=0&&(h.dataIndex=this._lastDataIndex,h.seriesIndex=this._lastSeriesIndex,this.zr.handler.dispatchToElement(c,"mouseout",e)),l=!0):null!=s&&s!==this._lastEventData&&(null!=this._lastEventData&&(h.eventData=this._lastEventData,this.zr.handler.dispatchToElement(c,"mouseout",e)),l=!0),this._lastEventData=s,this._lastDataIndex=r,this._lastSeriesIndex=o),h.eventData=s,h.dataIndex=r,h.seriesIndex=o,(null!=s||parseInt(r,10)>=0&&parseInt(o,10)>=0)&&(this.zr.handler.dispatchToElement(c,t,e),l&&this.zr.handler.dispatchToElement(c,"mouseover",e))},Aa.prototype._dispatchToView=function(t,e){for(var n=0;n=0&&(ka(e),"mapbox"===e.coordinateSystem&&(e.coordinateSystem="mapbox3D",t.mapbox3D=t.mapbox))})),Ba(t.xAxis3D),Ba(t.yAxis3D),Ba(t.zAxis3D),Ba(t.grid3D),Ra(t.geo3D)};function Va(t){this._layers={},this._zr=t}Va.prototype.update=function(t,e){var n=this,i=e.getZr();if(i.getWidth()&&i.getHeight()){for(var r in this._layers)this._layers[r].removeViewsAll();t.eachComponent((function(n,i){if("series"!==n){var r=e.getViewOfComponentModel(i),a=i.coordinateSystem;if(r.__ecgl__){if(a){if(!a.viewGL)return void console.error("Can't find viewGL in coordinateSystem of component "+i.id);l=a.viewGL}else{if(!i.viewGL)return void console.error("Can't find viewGL of component "+i.id);l=a.viewGL}var l=a.viewGL,u=o(i);u.addView(l),r.afterRender&&r.afterRender(i,t,e,u),s(r.groupGL,i.get("silent"))}}})),t.eachSeries((function(n){var i=e.getViewOfSeriesModel(n),r=n.coordinateSystem;if(i.__ecgl__){if(r&&!r.viewGL&&!i.viewGL)return void console.error("Can't find viewGL of series "+i.id);var a=r&&r.viewGL||i.viewGL,l=o(n);l.addView(a),i.afterRender&&i.afterRender(n,t,e,l),s(i.groupGL,n.get("silent"))}}))}else console.warn("Dom has no width or height");function o(t){var e;i.setSleepAfterStill(0),e=(t.coordinateSystem&&t.coordinateSystem.model,t.get("zlevel"));var r=n._layers,o=r[e];if(!o){if(o=r[e]=new Pa("gl-"+e,i),i.painter.isSingleCanvas()){o.virtual=!0;var s=new a["l"].Image({z:1e4,style:{image:o.renderer.canvas},silent:!0});o.__hostImage=s,i.add(s)}i.painter.insertLayer(e,o)}return o.__hostImage&&o.__hostImage.setStyle({width:o.renderer.getWidth(),height:o.renderer.getHeight()}),o}function s(t,e){t&&t.traverse((function(t){t.isRenderable&&t.isRenderable()&&(t.ignorePicking=null!=t.$ignorePicking?t.$ignorePicking:e)}))}},a["s"]((function(t){var e=t.getZr(),n=e.painter.dispose;e.painter.dispose=function(){"function"===typeof this.eachOtherLayer&&this.eachOtherLayer((function(t){t instanceof Pa&&t.dispose()})),n.call(this)},e.painter.getRenderedCanvas=function(t){if(t=t||{},this._singleCanvas)return this._layers[0].dom;var e=document.createElement("canvas"),n=t.pixelRatio||this.dpr;e.width=this.getWidth()*n,e.height=this.getHeight()*n;var i=e.getContext("2d");i.dpr=n,i.clearRect(0,0,e.width,e.height),t.backgroundColor&&(i.fillStyle=t.backgroundColor,i.fillRect(0,0,e.width,e.height));var r,a=this.storage.getDisplayList(!0),o={},s=this;function l(t,e){var n,r=s._zlevelList;null==t&&(t=-1/0);for(var a=0;at&&o0&&this._notFirst?this.animateTo({alpha:u,beta:c,center:h,distance:a,orthographicSize:o,easing:l.animationEasingUpdate,duration:l.animationDurationUpdate}):(this.setDistance(a),this.setAlpha(u),this.setBeta(c),this.setCenter(h),this.setOrthographicSize(o)),this._notFirst=!0,this._validateProperties()},_validateProperties:function(){0},animateTo:function(t){var e=this.zr,n=this,i={},r={};return null!=t.distance&&(i.distance=this.getDistance(),r.distance=t.distance),null!=t.orthographicSize&&(i.orthographicSize=this.getOrthographicSize(),r.orthographicSize=t.orthographicSize),null!=t.alpha&&(i.alpha=this.getAlpha(),r.alpha=t.alpha),null!=t.beta&&(i.beta=this.getBeta(),r.beta=t.beta),null!=t.center&&(i.center=this.getCenter(),r.center=t.center),this._addAnimator(e.animation.animate(i).when(t.duration||1e3,r).during((function(){null!=i.alpha&&n.setAlpha(i.alpha),null!=i.beta&&n.setBeta(i.beta),null!=i.distance&&n.setDistance(i.distance),null!=i.center&&n.setCenter(i.center),null!=i.orthographicSize&&n.setOrthographicSize(i.orthographicSize),n._needsUpdate=!0}))).start(t.easing||"linear")},stopAllAnimation:function(){for(var t=0;t0},_update:function(t){if(this._rotating){var e=("cw"===this.autoRotateDirection?1:-1)*this.autoRotateSpeed/180*Math.PI;this._phi-=e*t/1e3,this._needsUpdate=!0}else this._rotateVelocity.len()>0&&(this._needsUpdate=!0);(Math.abs(this._zoomSpeed)>.1||this._panVelocity.len()>0)&&(this._needsUpdate=!0),this._needsUpdate&&(t=Math.min(t,50),this._updateDistanceOrSize(t),this._updatePan(t),this._updateRotate(t),this._updateTransform(),this.getCamera().update(),this.zr&&this.zr.refresh(),this.trigger("update"),this._needsUpdate=!1)},_updateRotate:function(t){var e=this._rotateVelocity;this._phi=e.y*t/20+this._phi,this._theta=e.x*t/20+this._theta,this.setAlpha(this.getAlpha()),this.setBeta(this.getBeta()),this._vectorDamping(e,Math.pow(this.damping,t/16))},_updateDistanceOrSize:function(t){"perspective"===this._projection?this._setDistance(this._distance+this._zoomSpeed*t/20):this._setOrthoSize(this._orthoSize+this._zoomSpeed*t/20),this._zoomSpeed*=Math.pow(this.damping,t/16)},_setDistance:function(t){this._distance=Math.max(Math.min(t,this.maxDistance),this.minDistance)},_setOrthoSize:function(t){this._orthoSize=Math.max(Math.min(t,this.maxOrthographicSize),this.minOrthographicSize);var e=this.getCamera(),n=this._orthoSize,i=n/this.viewGL.viewport.height*this.viewGL.viewport.width;e.left=-i/2,e.right=i/2,e.top=n/2,e.bottom=-n/2},_updatePan:function(t){var e=this._panVelocity,n=this._distance,i=this.getCamera(),r=i.worldTransform.y,a=i.worldTransform.x;this._center.scaleAndAdd(a,-e.x*n/200).scaleAndAdd(r,-e.y*n/200),this._vectorDamping(e,0)},_updateTransform:function(){var t=this.getCamera(),e=new ye,n=this._theta+Math.PI/2,i=this._phi+Math.PI/2,r=Math.sin(n);e.x=r*Math.cos(i),e.y=-Math.cos(n),e.z=r*Math.sin(i),t.position.copy(this._center).scaleAndAdd(e,this._distance),t.rotation.identity().rotateY(-this._phi).rotateX(-this._theta)},_startCountingStill:function(){clearTimeout(this._stillTimeout);var t=this.autoRotateAfterStill,e=this;!isNaN(t)&&t>0&&(this._stillTimeout=setTimeout((function(){e._rotating=!0}),1e3*t))},_vectorDamping:function(t,e){var n=t.len();n*=e,n<1e-4&&(n=0),t.normalize().scale(n)},_decomposeTransform:function(){if(this.getCamera()){this.getCamera().updateWorldTransform();var t=this.getCamera().worldTransform.z,e=Math.asin(t.y),n=Math.atan2(t.x,t.z);this._theta=e,this._phi=-n,this.setBeta(this.getBeta()),this.setAlpha(this.getAlpha()),this.getCamera().aspect?this._setDistance(this.getCamera().position.dist(this._center)):this._setOrthoSize(this.getCamera().top-this.getCamera().bottom)}},_mouseDownHandler:function(t){if(!t.target&&!this._isAnimating()){var e=t.offsetX,n=t.offsetY;this.viewGL&&!this.viewGL.containPoint(e,n)||(this.zr.on("mousemove",this._mouseMoveHandler),this.zr.on("mouseup",this._mouseUpHandler),t.event.targetTouches?1===t.event.targetTouches.length&&(this._mode="rotate"):t.event.button===qa[this.rotateMouseButton]?this._mode="rotate":t.event.button===qa[this.panMouseButton]?this._mode="pan":this._mode="",this._rotateVelocity.set(0,0),this._rotating=!1,this.autoRotate&&this._startCountingStill(),this._mouseX=t.offsetX,this._mouseY=t.offsetY)}},_mouseMoveHandler:function(t){if((!t.target||!t.target.__isGLToZRProxy)&&!this._isAnimating()){var e=Ya(this.panSensitivity),n=Ya(this.rotateSensitivity);"rotate"===this._mode?(this._rotateVelocity.y=(t.offsetX-this._mouseX)/this.zr.getHeight()*2*n[0],this._rotateVelocity.x=(t.offsetY-this._mouseY)/this.zr.getWidth()*2*n[1]):"pan"===this._mode&&(this._panVelocity.x=(t.offsetX-this._mouseX)/this.zr.getWidth()*e[0]*400,this._panVelocity.y=(-t.offsetY+this._mouseY)/this.zr.getHeight()*e[1]*400),this._mouseX=t.offsetX,this._mouseY=t.offsetY,t.event.preventDefault()}},_mouseWheelHandler:function(t){if(!this._isAnimating()){var e=t.event.wheelDelta||-t.event.detail;this._zoomHandler(t,e)}},_pinchHandler:function(t){this._isAnimating()||(this._zoomHandler(t,t.pinchScale>1?1:-1),this._mode="")},_zoomHandler:function(t,e){if(0!==e){var n,i=t.offsetX,r=t.offsetY;if(!this.viewGL||this.viewGL.containPoint(i,r))n="perspective"===this._projection?Math.max(Math.max(Math.min(this._distance-this.minDistance,this.maxDistance-this._distance))/20,.5):Math.max(Math.max(Math.min(this._orthoSize-this.minOrthographicSize,this.maxOrthographicSize-this._orthoSize))/20,.5),this._zoomSpeed=(e>0?-1:1)*n*this.zoomSensitivity,this._rotating=!1,this.autoRotate&&"rotate"===this._mode&&this._startCountingStill(),t.event.preventDefault()}},_mouseUpHandler:function(){this.zr.off("mousemove",this._mouseMoveHandler),this.zr.off("mouseup",this._mouseUpHandler)},_isRightMouseButtonUsed:function(){return"right"===this.rotateMouseButton||"right"===this.panMouseButton},_contextMenuHandler:function(t){this._isRightMouseButtonUsed()&&t.preventDefault()},_addAnimator:function(t){var e=this._animators;return e.push(t),t.done((function(){var n=e.indexOf(t);n>=0&&e.splice(n,1)})),t}});Object.defineProperty(Ka.prototype,"autoRotate",{get:function(t){return this._autoRotate},set:function(t){this._autoRotate=t,this._rotating=t}});var Qa=Ka,Ja={convertToDynamicArray:function(t){t&&this.resetOffset();var e=this.attributes;for(var n in e)t||!e[n].value?e[n].value=[]:e[n].value=Array.prototype.slice.call(e[n].value);t||!this.indices?this.indices=[]:this.indices=Array.prototype.slice.call(this.indices)},convertToTypedArray:function(){var t=this.attributes;for(var e in t)t[e].value&&t[e].value.length>0?t[e].value=new Float32Array(t[e].value):t[e].value=null;this.indices&&this.indices.length>0&&(this.indices=this.vertexCount>65535?new Uint32Array(this.indices):new Uint16Array(this.indices)),this.dirty()}},$a={vec2:st,vec3:Qt,vec4:Oe,mat2:Kr,mat2d:ta,mat3:Te,mat4:Yt,quat:Ae},to=$a,eo=to.vec3,no=[[0,0],[1,1]],io=bn.extend((function(){return{segmentScale:1,dynamic:!0,useNativeLine:!0,attributes:{position:new bn.Attribute("position","float",3,"POSITION"),positionPrev:new bn.Attribute("positionPrev","float",3),positionNext:new bn.Attribute("positionNext","float",3),prevPositionPrev:new bn.Attribute("prevPositionPrev","float",3),prevPosition:new bn.Attribute("prevPosition","float",3),prevPositionNext:new bn.Attribute("prevPositionNext","float",3),offset:new bn.Attribute("offset","float",1),color:new bn.Attribute("color","float",4,"COLOR")}}}),{resetOffset:function(){this._vertexOffset=0,this._triangleOffset=0,this._itemVertexOffsets=[]},setVertexCount:function(t){var e=this.attributes;this.vertexCount!==t&&(e.position.init(t),e.color.init(t),this.useNativeLine||(e.positionPrev.init(t),e.positionNext.init(t),e.offset.init(t)),t>65535?this.indices instanceof Uint16Array&&(this.indices=new Uint32Array(this.indices)):this.indices instanceof Uint32Array&&(this.indices=new Uint16Array(this.indices)))},setTriangleCount:function(t){this.triangleCount!==t&&(this.indices=0===t?null:this.vertexCount>65535?new Uint32Array(3*t):new Uint16Array(3*t))},_getCubicCurveApproxStep:function(t,e,n,i){var r=eo.dist(t,e)+eo.dist(n,e)+eo.dist(i,n),a=1/(r+1)*this.segmentScale;return a},getCubicCurveVertexCount:function(t,e,n,i){var r=this._getCubicCurveApproxStep(t,e,n,i),a=Math.ceil(1/r);return this.useNativeLine?2*a:2*a+2},getCubicCurveTriangleCount:function(t,e,n,i){var r=this._getCubicCurveApproxStep(t,e,n,i),a=Math.ceil(1/r);return this.useNativeLine?0:2*a},getLineVertexCount:function(){return this.getPolylineVertexCount(no)},getLineTriangleCount:function(){return this.getPolylineTriangleCount(no)},getPolylineVertexCount:function(t){var e;if("number"===typeof t)e=t;else{var n="number"!==typeof t[0];e=n?t.length:t.length/3}return this.useNativeLine?2*(e-1):2*(e-1)+2},getPolylineTriangleCount:function(t){var e;if("number"===typeof t)e=t;else{var n="number"!==typeof t[0];e=n?t.length:t.length/3}return this.useNativeLine?0:2*Math.max(e-1,0)},addCubicCurve:function(t,e,n,i,r,a){null==a&&(a=1);var o=t[0],s=t[1],l=t[2],u=e[0],c=e[1],h=e[2],d=n[0],f=n[1],p=n[2],g=i[0],m=i[1],v=i[2],y=this._getCubicCurveApproxStep(t,e,n,i),_=y*y,b=_*y,x=3*y,w=3*_,O=6*_,S=6*b,T=o-2*u+d,M=s-2*c+f,A=l-2*h+p,C=3*(u-d)-o+g,I=3*(c-f)-s+m,D=3*(h-p)-l+v,L=o,E=s,j=l,P=(u-o)*x+T*w+C*b,N=(c-s)*x+M*w+I*b,R=(h-l)*x+A*w+D*b,k=T*O+C*S,B=M*O+I*S,z=A*O+D*S,V=C*S,F=I*S,G=D*S,H=0,U=0,W=Math.ceil(1/y),X=new Float32Array(3*(W+1)),Z=(X=[],0);for(U=0;U1&&(L=P>0?Math.min(L,g):Math.max(L,g),E=N>0?Math.min(E,m):Math.max(E,m),j=R>0?Math.min(j,v):Math.max(j,v));return this.addPolyline(X,r,a)},addLine:function(t,e,n,i){return this.addPolyline([t,e],n,i)},addPolyline:function(t,e,n,i,r){if(t.length){var a="number"!==typeof t[0];if(null==r&&(r=a?t.length:t.length/3),!(r<2)){null==i&&(i=0),null==n&&(n=1),this._itemVertexOffsets.push(this._vertexOffset);a="number"!==typeof t[0];var o,s,l=a?"number"!==typeof e[0]:e.length/4===r,u=this.attributes.position,c=this.attributes.positionPrev,h=this.attributes.positionNext,d=this.attributes.color,f=this.attributes.offset,p=this.indices,g=this._vertexOffset;n=Math.max(n,.01);for(var m=i;m1&&(u.copy(g,g-1),d.copy(g,g-1),g++):(m0&&(h.set(g-2,o),h.set(g-1,o)),u.set(g,o),u.set(g+1,o),d.set(g,s),d.set(g+1,s),f.set(g,n/2),f.set(g+1,-n/2),g+=2),this.useNativeLine)d.set(g,s),u.set(g,o),g++;else if(m>0){var _=3*this._triangleOffset;p=this.indices;p[_]=g-4,p[_+1]=g-3,p[_+2]=g-2,p[_+3]=g-3,p[_+4]=g-1,p[_+5]=g-2,this._triangleOffset+=2}}if(!this.useNativeLine){var b=this._vertexOffset,x=this._vertexOffset+2*r;c.copy(b,b+2),c.copy(b+1,b+3),h.copy(x-1,x-3),h.copy(x-2,x-4)}return this._vertexOffset=g,this._vertexOffset}}},setItemColor:function(t,e){for(var n=this._itemVertexOffsets[t],i=to&&(r=this._x=0,a+=this._rowHeight+l,this._y=a,this._rowHeight=0),this._x+=e+l,this._rowHeight=Math.max(this._rowHeight,n),a+n+l>s)return null;t.x+=this.offsetX*this.dpr+r,t.y+=this.offsetY*this.dpr+a,this._zr.add(t);var u=[this.offsetX/this.width,this.offsetY/this.height],c=[[r/o+u[0],a/s+u[1]],[(r+e)/o+u[0],(a+n)/s+u[1]]];return c},_fitElement:function(t,e,n){var i=t.getBoundingRect(),r=e/i.width,a=n/i.height;t.x=-i.x*r,t.y=-i.y*a,t.scaleX=r,t.scaleY=a,t.update()}},oo.prototype={clear:function(){for(var t=0;t=t)){var a=(i+this._nodeWidth)*this._dpr,o=(r+this._nodeHeight)*this._dpr;try{this._zr.resize({width:a,height:o})}catch(l){this._canvas.width=a,this._canvas.height=o}var s=new ao(this._zr,i,r,this._nodeWidth,this._nodeHeight,this._gap,this._dpr);return this._textureAtlasNodes.push(s),s}},add:function(t,e,n){if(this._coords[t.id])return this._coords[t.id];var i=this._getCurrentNode().add(t,e,n);if(!i){var r=this._expand();if(!r)return;i=r.add(t,e,n)}return this._coords[t.id]=i,i},getCoordsScale:function(){var t=this._dpr;return[this._nodeWidth/this._canvas.width*t,this._nodeHeight/this._canvas.height*t]},getCoords:function(t){return this._coords[t]},dispose:function(){this._zr.dispose()}};var so=oo;function lo(){}lo.prototype={constructor:lo,setScene:function(t){this._scene=t,this._skybox&&this._skybox.attachScene(this._scene)},initLight:function(t){this._lightRoot=t,this.mainLight=new Ta.DirectionalLight({shadowBias:.005}),this.ambientLight=new Ta.AmbientLight,t.add(this.mainLight),t.add(this.ambientLight)},dispose:function(){this._lightRoot&&(this._lightRoot.remove(this.mainLight),this._lightRoot.remove(this.ambientLight))},updateLight:function(t){var e=this.mainLight,n=this.ambientLight,i=t.getModel("light"),r=i.getModel("main"),a=i.getModel("ambient");e.intensity=r.get("intensity"),n.intensity=a.get("intensity"),e.color=Ta.parseColor(r.get("color")).slice(0,3),n.color=Ta.parseColor(a.get("color")).slice(0,3);var o=r.get("alpha")||0,s=r.get("beta")||0;e.position.setArray(Ta.directionFromAlphaBeta(o,s)),e.lookAt(Ta.Vector3.ZERO),e.castShadow=r.get("shadow"),e.shadowResolution=Ta.getShadowResolution(r.get("shadowQuality"))},updateAmbientCubemap:function(t,e,n){var i=e.getModel("light.ambientCubemap"),r=i.get("texture");if(r){this._cubemapLightsCache=this._cubemapLightsCache||{};var a=this._cubemapLightsCache[r];if(!a){var o=this;a=this._cubemapLightsCache[r]=Ta.createAmbientCubemap(i.option,t,n,(function(){o._isSkyboxFromAmbientCubemap&&o._skybox.setEnvironmentMap(a.specular.cubemap),n.getZr().refresh()}))}this._lightRoot.add(a.diffuse),this._lightRoot.add(a.specular),this._currentCubemapLights=a}else this._currentCubemapLights&&(this._lightRoot.remove(this._currentCubemapLights.diffuse),this._lightRoot.remove(this._currentCubemapLights.specular),this._currentCubemapLights=null)},updateSkybox:function(t,e,n){var i=e.get("environment"),r=this;function o(){return r._skybox=r._skybox||new Mi,r._skybox}var s=o();if(i&&"none"!==i)if("auto"===i)if(this._isSkyboxFromAmbientCubemap=!0,this._currentCubemapLights){var l=this._currentCubemapLights.specular.cubemap;s.setEnvironmentMap(l),this._scene&&s.attachScene(this._scene),s.material.set("lod",3)}else this._skybox&&this._skybox.detachScene();else if("object"===typeof i&&i.colorStops||"string"===typeof i&&a["h"].parse(i)){this._isSkyboxFromAmbientCubemap=!1;var u=new Ta.Texture2D({anisotropic:8,flipY:!1});s.setEnvironmentMap(u);var c=u.image=document.createElement("canvas");c.width=c.height=16;var h=c.getContext("2d"),d=new a["l"].Rect({shape:{x:0,y:0,width:16,height:16},style:{fill:i}});a["o"](h,d),s.attachScene(this._scene)}else{this._isSkyboxFromAmbientCubemap=!1;u=Ta.loadTexture(i,n,{anisotropic:8,flipY:!1});s.setEnvironmentMap(u),s.attachScene(this._scene)}else this._skybox&&this._skybox.detachScene(this._scene),this._skybox=null;var f=e.coordinateSystem;if(this._skybox)if(!f||!f.viewGL||"auto"===i||i.match&&i.match(/.hdr$/))this._skybox.material.undefine("fragment","SRGB_DECODE");else{var p=f.viewGL.isLinearSpace()?"define":"undefine";this._skybox.material[p]("fragment","SRGB_DECODE")}}};var uo=lo,co=to.vec3,ho=bn.extend((function(){return{segmentScale:1,useNativeLine:!0,attributes:{position:new bn.Attribute("position","float",3,"POSITION"),normal:new bn.Attribute("normal","float",3,"NORMAL"),color:new bn.Attribute("color","float",4,"COLOR")}}}),{resetOffset:function(){this._vertexOffset=0,this._faceOffset=0},setQuadCount:function(t){var e=this.attributes,n=this.getQuadVertexCount()*t,i=this.getQuadTriangleCount()*t;this.vertexCount!==n&&(e.position.init(n),e.normal.init(n),e.color.init(n)),this.triangleCount!==i&&(this.indices=n>65535?new Uint32Array(3*i):new Uint16Array(3*i))},getQuadVertexCount:function(){return 4},getQuadTriangleCount:function(){return 2},addQuad:function(){var t=co.create(),e=co.create(),n=co.create(),i=[0,3,1,3,2,1];return function(r,a){var o=this.attributes.position,s=this.attributes.normal,l=this.attributes.color;co.sub(t,r[1],r[0]),co.sub(e,r[2],r[1]),co.cross(n,t,e),co.normalize(n,n);for(var u=0;u<4;u++)o.set(this._vertexOffset+u,r[u]),l.set(this._vertexOffset+u,a),s.set(this._vertexOffset+u,n);var c=3*this._faceOffset;for(u=0;u<6;u++)this.indices[c+u]=i[u]+this._vertexOffset;this._vertexOffset+=4,this._faceOffset+=2}}()});a["w"].defaults(ho.prototype,Ja);var fo=ho,po=Pr.firstNotNull,go={x:0,y:2,z:1};function mo(t,e,n,i){var r=[0,0,0],a=i<0?n.getExtentMin():n.getExtentMax();r[go[n.dim]]=a,t.position.setArray(r),t.rotation.identity(),e.distance=-Math.abs(a),e.normal.set(0,0,0),"x"===n.dim?(t.rotation.rotateY(i*Math.PI/2),e.normal.x=-i):"z"===n.dim?(t.rotation.rotateX(-i*Math.PI/2),e.normal.y=-i):(i>0&&t.rotation.rotateY(Math.PI),e.normal.z=-i)}function vo(t,e,n){this.rootNode=new Ta.Node;var i=new Ta.Mesh({geometry:new ro({useNativeLine:!1}),material:e,castShadow:!1,ignorePicking:!0,$ignorePicking:!0,renderOrder:1}),r=new Ta.Mesh({geometry:new fo,material:n,castShadow:!1,culling:!1,ignorePicking:!0,$ignorePicking:!0,renderOrder:0});this.rootNode.add(r),this.rootNode.add(i),this.faceInfo=t,this.plane=new Ta.Plane,this.linesMesh=i,this.quadsMesh=r}vo.prototype.update=function(t,e,n){var i=t.coordinateSystem,r=[i.getAxis(this.faceInfo[0]),i.getAxis(this.faceInfo[1])],a=this.linesMesh.geometry,o=this.quadsMesh.geometry;a.convertToDynamicArray(!0),o.convertToDynamicArray(!0),this._updateSplitLines(a,r,t,n),this._udpateSplitAreas(o,r,t,n),a.convertToTypedArray(),o.convertToTypedArray();var s=i.getAxis(this.faceInfo[2]);mo(this.rootNode,this.plane,s,this.faceInfo[3])},vo.prototype._updateSplitLines=function(t,e,n,i){var r=i.getDevicePixelRatio();e.forEach((function(i,o){var s=i.model,l=e[1-o].getExtent();if(!i.scale.isBlank()){var u=s.getModel("splitLine",n.getModel("splitLine"));if(u.get("show")){var c=u.getModel("lineStyle"),h=c.get("color"),d=po(c.get("opacity"),1),f=po(c.get("width"),1);h=a["w"].isArray(h)?h:[h];for(var p=i.getTicksCoords({tickModel:u}),g=0,m=0;m65535?new Uint32Array(3*n):new Uint16Array(3*n))},setSpriteAlign:function(t,e,n,i,r){var a,o,s,l;switch(null==n&&(n="left"),null==i&&(i="top"),r=r||0,n){case"left":a=r,s=e[0]+r;break;case"center":case"middle":a=-e[0]/2,s=e[0]/2;break;case"right":a=-e[0]-r,s=-r;break}switch(i){case"bottom":o=r,l=e[1]+r;break;case"middle":o=-e[1]/2,l=e[1]/2;break;case"top":o=-e[1]-r,l=-r;break}var u=4*t,c=this.attributes.offset;c.set(u,[a,l]),c.set(u+1,[s,l]),c.set(u+2,[s,o]),c.set(u+3,[a,o])},addSprite:function(t,e,n,i,r,a){var o=this._vertexOffset;this.setSprite(this._vertexOffset/4,t,e,n,i,r,a);for(var s=0;s<_o.length;s++)this.indices[3*this._faceOffset+s]=_o[s]+o;return this._faceOffset+=2,this._vertexOffset+=4,o/4},setSprite:function(t,e,n,i,r,a,o){for(var s=4*t,l=this.attributes,u=0;u<4;u++)l.position.set(s+u,e);var c=l.texcoord;c.set(s,[i[0][0],i[0][1]]),c.set(s+1,[i[1][0],i[0][1]]),c.set(s+2,[i[1][0],i[1][1]]),c.set(s+3,[i[0][0],i[1][1]]),this.setSpriteAlign(t,n,r,a,o)}});a["w"].defaults(bo.prototype,Ja);var xo=bo,wo="@export ecgl.labels.vertex\n\nattribute vec3 position: POSITION;\nattribute vec2 texcoord: TEXCOORD_0;\nattribute vec2 offset;\n#ifdef VERTEX_COLOR\nattribute vec4 a_Color : COLOR;\nvarying vec4 v_Color;\n#endif\n\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nuniform vec4 viewport : VIEWPORT;\n\nvarying vec2 v_Texcoord;\n\nvoid main()\n{\n vec4 proj = worldViewProjection * vec4(position, 1.0);\n\n vec2 screen = (proj.xy / abs(proj.w) + 1.0) * 0.5 * viewport.zw;\n\n screen += offset;\n\n proj.xy = (screen / viewport.zw - 0.5) * 2.0 * abs(proj.w);\n gl_Position = proj;\n#ifdef VERTEX_COLOR\n v_Color = a_Color;\n#endif\n v_Texcoord = texcoord;\n}\n@end\n\n\n@export ecgl.labels.fragment\n\nuniform vec3 color : [1.0, 1.0, 1.0];\nuniform float alpha : 1.0;\nuniform sampler2D textureAtlas;\nuniform vec2 uvScale: [1.0, 1.0];\n\n#ifdef VERTEX_COLOR\nvarying vec4 v_Color;\n#endif\nvarying float v_Miter;\n\nvarying vec2 v_Texcoord;\n\nvoid main()\n{\n gl_FragColor = vec4(color, alpha) * texture2D(textureAtlas, v_Texcoord * uvScale);\n#ifdef VERTEX_COLOR\n gl_FragColor *= v_Color;\n#endif\n}\n\n@end";Ta.Shader.import(wo);var Oo=Ta.Mesh.extend((function(){var t=new xo({dynamic:!0}),e=new Ta.Material({shader:Ta.createShader("ecgl.labels"),transparent:!0,depthMask:!1});return{geometry:t,material:e,culling:!1,castShadow:!1,ignorePicking:!0}})),So=Pr.firstNotNull,To={x:0,y:2,z:1};function Mo(t,e){var n=new Ta.Mesh({geometry:new ro({useNativeLine:!1}),material:e,castShadow:!1,ignorePicking:!0,renderOrder:2}),i=new Oo;i.material.depthMask=!1;var r=new Ta.Node;r.add(n),r.add(i),this.rootNode=r,this.dim=t,this.linesMesh=n,this.labelsMesh=i,this.axisLineCoords=null,this.labelElements=[]}var Ao={x:"y",y:"x",z:"y"};Mo.prototype.update=function(t,e,n){var i=t.coordinateSystem,r=i.getAxis(this.dim),o=this.linesMesh.geometry,s=this.labelsMesh.geometry;o.convertToDynamicArray(!0),s.convertToDynamicArray(!0);var l=r.model,u=r.getExtent(),c=n.getDevicePixelRatio(),h=l.getModel("axisLine",t.getModel("axisLine")),d=l.getModel("axisTick",t.getModel("axisTick")),f=l.getModel("axisLabel",t.getModel("axisLabel")),p=h.get("lineStyle.color");if(h.get("show")){var g=h.getModel("lineStyle"),m=[0,0,0],v=[0,0,0],y=To[r.dim];m[y]=u[0],v[y]=u[1],this.axisLineCoords=[m,v];var _=Ta.parseColor(p),b=So(g.get("width"),1),x=So(g.get("opacity"),1);_[3]*=x,o.addLine(m,v,_,b*c)}if(d.get("show")){var w=d.getModel("lineStyle"),O=Ta.parseColor(So(w.get("color"),p));b=So(w.get("width"),1);O[3]*=So(w.get("opacity"),1);for(var S=r.getTicksCoords(),T=d.get("length"),M=0;M 0.0) {\n currProj = clipNear(currProj, nextProj);\n }\n else if (prevProj.w > 0.0) {\n currProj = clipNear(currProj, prevProj);\n }\n }\n\n vec2 prevScreen = (prevProj.xy / abs(prevProj.w) + 1.0) * 0.5 * viewport.zw;\n vec2 currScreen = (currProj.xy / abs(currProj.w) + 1.0) * 0.5 * viewport.zw;\n vec2 nextScreen = (nextProj.xy / abs(nextProj.w) + 1.0) * 0.5 * viewport.zw;\n\n vec2 dir;\n float len = offset;\n if (position == positionPrev) {\n dir = normalize(nextScreen - currScreen);\n }\n else if (position == positionNext) {\n dir = normalize(currScreen - prevScreen);\n }\n else {\n vec2 dirA = normalize(currScreen - prevScreen);\n vec2 dirB = normalize(nextScreen - currScreen);\n\n vec2 tanget = normalize(dirA + dirB);\n\n float miter = 1.0 / max(dot(tanget, dirA), 0.5);\n len *= miter;\n dir = tanget;\n }\n\n dir = vec2(-dir.y, dir.x) * len;\n currScreen += dir;\n\n currProj.xy = (currScreen / viewport.zw - 0.5) * 2.0 * abs(currProj.w);\n@end\n\n\n@export ecgl.meshLines3D.vertex\n\nattribute vec3 position: POSITION;\nattribute vec3 positionPrev;\nattribute vec3 positionNext;\nattribute float offset;\nattribute vec4 a_Color : COLOR;\n\n#ifdef VERTEX_ANIMATION\nattribute vec3 prevPosition;\nattribute vec3 prevPositionPrev;\nattribute vec3 prevPositionNext;\nuniform float percent : 1.0;\n#endif\n\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nuniform vec4 viewport : VIEWPORT;\nuniform float near : NEAR;\n\nvarying vec4 v_Color;\n\n@import ecgl.common.wireframe.vertexHeader\n\n@import ecgl.lines3D.clipNear\n\nvoid main()\n{\n @import ecgl.lines3D.expandLine\n\n gl_Position = currProj;\n\n v_Color = a_Color;\n\n @import ecgl.common.wireframe.vertexMain\n}\n@end\n\n\n@export ecgl.meshLines3D.fragment\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\n\nvarying vec4 v_Color;\n\n@import ecgl.common.wireframe.fragmentHeader\n\n@import clay.util.srgb\n\nvoid main()\n{\n#ifdef SRGB_DECODE\n gl_FragColor = sRGBToLinear(color * v_Color);\n#else\n gl_FragColor = color * v_Color;\n#endif\n\n @import ecgl.common.wireframe.fragmentMain\n}\n\n@end",Do=Pr.firstNotNull;Ta.Shader.import(Io);var Lo={x:0,y:2,z:1},Eo=a["d"].extend({type:"grid3D",__ecgl__:!0,init:function(t,e){var n=[["y","z","x",-1,"left"],["y","z","x",1,"right"],["x","y","z",-1,"bottom"],["x","y","z",1,"top"],["x","z","y",-1,"far"],["x","z","y",1,"near"]],i=["x","y","z"],r=new Ta.Material({shader:Ta.createShader("ecgl.color"),depthMask:!1,transparent:!0}),a=new Ta.Material({shader:Ta.createShader("ecgl.meshLines3D"),depthMask:!1,transparent:!0});r.define("fragment","DOUBLE_SIDED"),r.define("both","VERTEX_COLOR"),this.groupGL=new Ta.Node,this._control=new Qa({zr:e.getZr()}),this._control.init(),this._faces=n.map((function(t){var e=new yo(t,a,r);return this.groupGL.add(e.rootNode),e}),this),this._axes=i.map((function(t){var e=new Co(t,a);return this.groupGL.add(e.rootNode),e}),this);var o=e.getDevicePixelRatio();this._axisLabelSurface=new so({width:256,height:256,devicePixelRatio:o}),this._axisLabelSurface.onupdate=function(){e.getZr().refresh()},this._axisPointerLineMesh=new Ta.Mesh({geometry:new ro({useNativeLine:!1}),material:a,castShadow:!1,ignorePicking:!0,renderOrder:3}),this.groupGL.add(this._axisPointerLineMesh),this._axisPointerLabelsSurface=new so({width:128,height:128,devicePixelRatio:o}),this._axisPointerLabelsMesh=new Oo({ignorePicking:!0,renderOrder:4,castShadow:!1}),this._axisPointerLabelsMesh.material.set("textureAtlas",this._axisPointerLabelsSurface.getTexture()),this.groupGL.add(this._axisPointerLabelsMesh),this._lightRoot=new Ta.Node,this._sceneHelper=new uo,this._sceneHelper.initLight(this._lightRoot)},render:function(t,e,n){this._model=t,this._api=n;var i=t.coordinateSystem;i.viewGL.add(this._lightRoot),t.get("show")?i.viewGL.add(this.groupGL):i.viewGL.remove(this.groupGL);var r=this._control;r.setViewGL(i.viewGL);var a=t.getModel("viewControl");r.setFromViewControlModel(a,0),this._axisLabelSurface.clear(),r.off("update"),t.get("show")&&(this._faces.forEach((function(i){i.update(t,e,n)}),this),this._axes.forEach((function(e){e.update(t,this._axisLabelSurface,n)}),this)),r.on("update",this._onCameraChange.bind(this,t,n),this),this._sceneHelper.setScene(i.viewGL.scene),this._sceneHelper.updateLight(t),i.viewGL.setPostEffect(t.getModel("postEffect"),n),i.viewGL.setTemporalSuperSampling(t.getModel("temporalSuperSampling")),this._initMouseHandler(t)},afterRender:function(t,e,n,i){var r=i.renderer;this._sceneHelper.updateAmbientCubemap(r,t,n),this._sceneHelper.updateSkybox(r,t,n)},showAxisPointer:function(t,e,n,i){this._doShowAxisPointer(),this._updateAxisPointer(i.value)},hideAxisPointer:function(t,e,n,i){this._doHideAxisPointer()},_initMouseHandler:function(t){var e=t.coordinateSystem,n=e.viewGL;t.get("show")&&t.get("axisPointer.show")?n.on("mousemove",this._updateAxisPointerOnMousePosition,this):n.off("mousemove",this._updateAxisPointerOnMousePosition)},_updateAxisPointerOnMousePosition:function(t){if(!t.target){for(var e,n=this._model,i=n.coordinateSystem,r=i.viewGL,a=r.castRay(t.offsetX,t.offsetY,new Ta.Ray),o=0;oi[1]?0:1,s=this._faces[2*n+o],l=this._faces[2*n+1-o];s.rootNode.invisible=!0,l.rootNode.invisible=!1}},_updateAxisLinePosition:function(){var t=this._model.coordinateSystem,e=t.getAxis("x"),n=t.getAxis("y"),i=t.getAxis("z"),r=i.getExtentMax(),a=i.getExtentMin(),o=e.getExtentMin(),s=e.getExtentMax(),l=n.getExtentMax(),u=n.getExtentMin(),c=this._axes[0].rootNode,h=this._axes[1].rootNode,d=this._axes[2].rootNode,f=this._faces,p=f[4].rootNode.invisible?u:l,g=f[2].rootNode.invisible?r:a,m=f[0].rootNode.invisible?o:s,v=f[2].rootNode.invisible?r:a,y=f[0].rootNode.invisible?s:o,_=f[4].rootNode.invisible?u:l;c.rotation.identity(),h.rotation.identity(),d.rotation.identity(),f[4].rootNode.invisible&&(this._axes[0].flipped=!0,c.rotation.rotateX(Math.PI)),f[0].rootNode.invisible&&(this._axes[1].flipped=!0,h.rotation.rotateZ(Math.PI)),f[4].rootNode.invisible&&(this._axes[2].flipped=!0,d.rotation.rotateY(Math.PI)),c.position.set(0,g,p),h.position.set(m,v,0),d.position.set(y,0,_),c.update(),h.update(),d.update(),this._updateAxisLabelAlign()},_updateAxisLabelAlign:function(){var t=this._control.getCamera(),e=[new Ta.Vector4,new Ta.Vector4],n=new Ta.Vector4;this.groupGL.getWorldPosition(n),n.w=1,n.transformMat4(t.viewMatrix).transformMat4(t.projectionMatrix),n.x/=n.w,n.y/=n.w,this._axes.forEach((function(i){for(var r=i.axisLineCoords,a=(i.labelsMesh.geometry,0);an.y?"bottom":"top"):(s="middle",o=c>n.x?"left":"right"),i.setSpriteAlign(o,s,this._api)}),this)},_doShowAxisPointer:function(){this._axisPointerLineMesh.invisible&&(this._axisPointerLineMesh.invisible=!1,this._axisPointerLabelsMesh.invisible=!1,this._api.getZr().refresh())},_doHideAxisPointer:function(){this._axisPointerLineMesh.invisible||(this._axisPointerLineMesh.invisible=!0,this._axisPointerLabelsMesh.invisible=!0,this._api.getZr().refresh())},_updateAxisPointer:function(t){var e=this._model.coordinateSystem,n=e.dataToPoint(t),i=this._axisPointerLineMesh,r=i.geometry,a=this._model.getModel("axisPointer"),o=this._api.getDevicePixelRatio();function s(t){return Pr.firstNotNull(t.model.get("axisPointer.show"),a.get("show"))}function l(t){var e=t.model.getModel("axisPointer",a),n=e.getModel("lineStyle"),i=Ta.parseColor(n.get("color")),r=Do(n.get("width"),1),o=Do(n.get("opacity"),1);return i[3]*=o,{color:i,lineWidth:r}}r.convertToDynamicArray(!0);for(var u=0;u 0.0) {\n if (texture2D(alphaMap, v_Texcoord).a <= alphaCutoff) {\n discard;\n }\n }\n#ifdef USE_VSM\n depth = depth * 0.5 + 0.5;\n float moment1 = depth;\n float moment2 = depth * depth;\n #ifdef SUPPORT_STANDARD_DERIVATIVES\n float dx = dFdx(depth);\n float dy = dFdy(depth);\n moment2 += 0.25*(dx*dx+dy*dy);\n #endif\n gl_FragColor = vec4(moment1, moment2, 0.0, 1.0);\n#else\n #ifdef SUPPORT_STANDARD_DERIVATIVES\n float dx = dFdx(depth);\n float dy = dFdy(depth);\n depth += sqrt(dx*dx + dy*dy) * slopeScale + bias;\n #else\n depth += bias;\n #endif\n gl_FragColor = encodeFloat(depth * 0.5 + 0.5);\n#endif\n}\n@end\n@export clay.sm.debug_depth\nuniform sampler2D depthMap;\nvarying vec2 v_Texcoord;\n@import clay.util.decode_float\nvoid main() {\n vec4 tex = texture2D(depthMap, v_Texcoord);\n#ifdef USE_VSM\n gl_FragColor = vec4(tex.rgb, 1.0);\n#else\n float depth = decodeFloat(tex);\n gl_FragColor = vec4(depth, depth, depth, 1.0);\n#endif\n}\n@end\n@export clay.sm.distance.vertex\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nuniform mat4 world : WORLD;\nattribute vec3 position : POSITION;\n@import clay.chunk.skinning_header\nvarying vec3 v_WorldPosition;\nvoid main (){\n vec4 P = vec4(position, 1.0);\n#ifdef SKINNING\n @import clay.chunk.skin_matrix\n P = skinMatrixWS * P;\n#endif\n#ifdef INSTANCING\n @import clay.chunk.instancing_matrix\n P = instanceMat * P;\n#endif\n gl_Position = worldViewProjection * P;\n v_WorldPosition = (world * P).xyz;\n}\n@end\n@export clay.sm.distance.fragment\nuniform vec3 lightPosition;\nuniform float range : 100;\nvarying vec3 v_WorldPosition;\n@import clay.util.encode_float\nvoid main(){\n float dist = distance(lightPosition, v_WorldPosition);\n#ifdef USE_VSM\n gl_FragColor = vec4(dist, dist * dist, 0.0, 0.0);\n#else\n dist = dist / range;\n gl_FragColor = encodeFloat(dist);\n#endif\n}\n@end\n@export clay.plugin.shadow_map_common\n@import clay.util.decode_float\nfloat tapShadowMap(sampler2D map, vec2 uv, float z){\n vec4 tex = texture2D(map, uv);\n return step(z, decodeFloat(tex) * 2.0 - 1.0);\n}\nfloat pcf(sampler2D map, vec2 uv, float z, float textureSize, vec2 scale) {\n float shadowContrib = tapShadowMap(map, uv, z);\n vec2 offset = vec2(1.0 / textureSize) * scale;\n#ifdef PCF_KERNEL_SIZE\n for (int _idx_ = 0; _idx_ < PCF_KERNEL_SIZE; _idx_++) {{\n shadowContrib += tapShadowMap(map, uv + offset * pcfKernel[_idx_], z);\n }}\n return shadowContrib / float(PCF_KERNEL_SIZE + 1);\n#else\n shadowContrib += tapShadowMap(map, uv+vec2(offset.x, 0.0), z);\n shadowContrib += tapShadowMap(map, uv+vec2(offset.x, offset.y), z);\n shadowContrib += tapShadowMap(map, uv+vec2(-offset.x, offset.y), z);\n shadowContrib += tapShadowMap(map, uv+vec2(0.0, offset.y), z);\n shadowContrib += tapShadowMap(map, uv+vec2(-offset.x, 0.0), z);\n shadowContrib += tapShadowMap(map, uv+vec2(-offset.x, -offset.y), z);\n shadowContrib += tapShadowMap(map, uv+vec2(offset.x, -offset.y), z);\n shadowContrib += tapShadowMap(map, uv+vec2(0.0, -offset.y), z);\n return shadowContrib / 9.0;\n#endif\n}\nfloat pcf(sampler2D map, vec2 uv, float z, float textureSize) {\n return pcf(map, uv, z, textureSize, vec2(1.0));\n}\nfloat chebyshevUpperBound(vec2 moments, float z){\n float p = 0.0;\n z = z * 0.5 + 0.5;\n if (z <= moments.x) {\n p = 1.0;\n }\n float variance = moments.y - moments.x * moments.x;\n variance = max(variance, 0.0000001);\n float mD = moments.x - z;\n float pMax = variance / (variance + mD * mD);\n pMax = clamp((pMax-0.4)/(1.0-0.4), 0.0, 1.0);\n return max(p, pMax);\n}\nfloat computeShadowContrib(\n sampler2D map, mat4 lightVPM, vec3 position, float textureSize, vec2 scale, vec2 offset\n) {\n vec4 posInLightSpace = lightVPM * vec4(position, 1.0);\n posInLightSpace.xyz /= posInLightSpace.w;\n float z = posInLightSpace.z;\n if(all(greaterThan(posInLightSpace.xyz, vec3(-0.99, -0.99, -1.0))) &&\n all(lessThan(posInLightSpace.xyz, vec3(0.99, 0.99, 1.0)))){\n vec2 uv = (posInLightSpace.xy+1.0) / 2.0;\n #ifdef USE_VSM\n vec2 moments = texture2D(map, uv * scale + offset).xy;\n return chebyshevUpperBound(moments, z);\n #else\n return pcf(map, uv * scale + offset, z, textureSize, scale);\n #endif\n }\n return 1.0;\n}\nfloat computeShadowContrib(sampler2D map, mat4 lightVPM, vec3 position, float textureSize) {\n return computeShadowContrib(map, lightVPM, position, textureSize, vec2(1.0), vec2(0.0));\n}\nfloat computeShadowContribOmni(samplerCube map, vec3 direction, float range)\n{\n float dist = length(direction);\n vec4 shadowTex = textureCube(map, direction);\n#ifdef USE_VSM\n vec2 moments = shadowTex.xy;\n float variance = moments.y - moments.x * moments.x;\n float mD = moments.x - dist;\n float p = variance / (variance + mD * mD);\n if(moments.x + 0.001 < dist){\n return clamp(p, 0.0, 1.0);\n }else{\n return 1.0;\n }\n#else\n return step(dist, (decodeFloat(shadowTex) + 0.0002) * range);\n#endif\n}\n@end\n@export clay.plugin.compute_shadow_map\n#if defined(SPOT_LIGHT_SHADOWMAP_COUNT) || defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT) || defined(POINT_LIGHT_SHADOWMAP_COUNT)\n#ifdef SPOT_LIGHT_SHADOWMAP_COUNT\nuniform sampler2D spotLightShadowMaps[SPOT_LIGHT_SHADOWMAP_COUNT]:unconfigurable;\nuniform mat4 spotLightMatrices[SPOT_LIGHT_SHADOWMAP_COUNT]:unconfigurable;\nuniform float spotLightShadowMapSizes[SPOT_LIGHT_SHADOWMAP_COUNT]:unconfigurable;\n#endif\n#ifdef DIRECTIONAL_LIGHT_SHADOWMAP_COUNT\n#if defined(SHADOW_CASCADE)\nuniform sampler2D directionalLightShadowMaps[1]:unconfigurable;\nuniform mat4 directionalLightMatrices[SHADOW_CASCADE]:unconfigurable;\nuniform float directionalLightShadowMapSizes[1]:unconfigurable;\nuniform float shadowCascadeClipsNear[SHADOW_CASCADE]:unconfigurable;\nuniform float shadowCascadeClipsFar[SHADOW_CASCADE]:unconfigurable;\n#else\nuniform sampler2D directionalLightShadowMaps[DIRECTIONAL_LIGHT_SHADOWMAP_COUNT]:unconfigurable;\nuniform mat4 directionalLightMatrices[DIRECTIONAL_LIGHT_SHADOWMAP_COUNT]:unconfigurable;\nuniform float directionalLightShadowMapSizes[DIRECTIONAL_LIGHT_SHADOWMAP_COUNT]:unconfigurable;\n#endif\n#endif\n#ifdef POINT_LIGHT_SHADOWMAP_COUNT\nuniform samplerCube pointLightShadowMaps[POINT_LIGHT_SHADOWMAP_COUNT]:unconfigurable;\n#endif\nuniform bool shadowEnabled : true;\n#ifdef PCF_KERNEL_SIZE\nuniform vec2 pcfKernel[PCF_KERNEL_SIZE];\n#endif\n@import clay.plugin.shadow_map_common\n#if defined(SPOT_LIGHT_SHADOWMAP_COUNT)\nvoid computeShadowOfSpotLights(vec3 position, inout float shadowContribs[SPOT_LIGHT_COUNT] ) {\n float shadowContrib;\n for(int _idx_ = 0; _idx_ < SPOT_LIGHT_SHADOWMAP_COUNT; _idx_++) {{\n shadowContrib = computeShadowContrib(\n spotLightShadowMaps[_idx_], spotLightMatrices[_idx_], position,\n spotLightShadowMapSizes[_idx_]\n );\n shadowContribs[_idx_] = shadowContrib;\n }}\n for(int _idx_ = SPOT_LIGHT_SHADOWMAP_COUNT; _idx_ < SPOT_LIGHT_COUNT; _idx_++){{\n shadowContribs[_idx_] = 1.0;\n }}\n}\n#endif\n#if defined(DIRECTIONAL_LIGHT_SHADOWMAP_COUNT)\n#ifdef SHADOW_CASCADE\nvoid computeShadowOfDirectionalLights(vec3 position, inout float shadowContribs[DIRECTIONAL_LIGHT_COUNT]){\n float depth = (2.0 * gl_FragCoord.z - gl_DepthRange.near - gl_DepthRange.far)\n / (gl_DepthRange.far - gl_DepthRange.near);\n float shadowContrib;\n shadowContribs[0] = 1.0;\n for (int _idx_ = 0; _idx_ < SHADOW_CASCADE; _idx_++) {{\n if (\n depth >= shadowCascadeClipsNear[_idx_] &&\n depth <= shadowCascadeClipsFar[_idx_]\n ) {\n shadowContrib = computeShadowContrib(\n directionalLightShadowMaps[0], directionalLightMatrices[_idx_], position,\n directionalLightShadowMapSizes[0],\n vec2(1.0 / float(SHADOW_CASCADE), 1.0),\n vec2(float(_idx_) / float(SHADOW_CASCADE), 0.0)\n );\n shadowContribs[0] = shadowContrib;\n }\n }}\n for(int _idx_ = DIRECTIONAL_LIGHT_SHADOWMAP_COUNT; _idx_ < DIRECTIONAL_LIGHT_COUNT; _idx_++) {{\n shadowContribs[_idx_] = 1.0;\n }}\n}\n#else\nvoid computeShadowOfDirectionalLights(vec3 position, inout float shadowContribs[DIRECTIONAL_LIGHT_COUNT]){\n float shadowContrib;\n for(int _idx_ = 0; _idx_ < DIRECTIONAL_LIGHT_SHADOWMAP_COUNT; _idx_++) {{\n shadowContrib = computeShadowContrib(\n directionalLightShadowMaps[_idx_], directionalLightMatrices[_idx_], position,\n directionalLightShadowMapSizes[_idx_]\n );\n shadowContribs[_idx_] = shadowContrib;\n }}\n for(int _idx_ = DIRECTIONAL_LIGHT_SHADOWMAP_COUNT; _idx_ < DIRECTIONAL_LIGHT_COUNT; _idx_++) {{\n shadowContribs[_idx_] = 1.0;\n }}\n}\n#endif\n#endif\n#if defined(POINT_LIGHT_SHADOWMAP_COUNT)\nvoid computeShadowOfPointLights(vec3 position, inout float shadowContribs[POINT_LIGHT_COUNT] ){\n vec3 lightPosition;\n vec3 direction;\n for(int _idx_ = 0; _idx_ < POINT_LIGHT_SHADOWMAP_COUNT; _idx_++) {{\n lightPosition = pointLightPosition[_idx_];\n direction = position - lightPosition;\n shadowContribs[_idx_] = computeShadowContribOmni(pointLightShadowMaps[_idx_], direction, pointLightRange[_idx_]);\n }}\n for(int _idx_ = POINT_LIGHT_SHADOWMAP_COUNT; _idx_ < POINT_LIGHT_COUNT; _idx_++) {{\n shadowContribs[_idx_] = 1.0;\n }}\n}\n#endif\n#endif\n@end",Zo=["px","nx","py","ny","pz","nz"];function qo(t,e,n){if("alphaMap"===n)return t.material.get("diffuseMap");if("alphaCutoff"===n){if(t.material.isDefined("fragment","ALPHA_TEST")&&t.material.get("diffuseMap")){var i=t.material.get("alphaCutoff");return i||0}return 0}return"uvRepeat"===n?t.material.get("uvRepeat"):"uvOffset"===n?t.material.get("uvOffset"):e.get(n)}function Yo(t,e){var n=t.material,i=e.material;return n.get("diffuseMap")!==i.get("diffuseMap")||(n.get("alphaCutoff")||0)!==(i.get("alphaCutoff")||0)}Xt["import"](Xo);var Ko=O.extend((function(){return{softShadow:Ko.PCF,shadowBlur:1,lightFrustumBias:"auto",kernelPCF:new Float32Array([1,0,1,1,-1,1,0,1,-1,0,-1,-1,1,-1,0,-1]),precision:"highp",_lastRenderNotCastShadow:!1,_frameBuffer:new pi,_textures:{},_shadowMapNumber:{POINT_LIGHT:0,DIRECTIONAL_LIGHT:0,SPOT_LIGHT:0},_depthMaterials:{},_distanceMaterials:{},_receivers:[],_lightsCastShadow:[],_lightCameras:{},_lightMaterials:{},_texturePool:new Wo}}),(function(){this._gaussianPassH=new vr({fragment:Xt.source("clay.compositor.gaussian_blur")}),this._gaussianPassV=new vr({fragment:Xt.source("clay.compositor.gaussian_blur")}),this._gaussianPassH.setUniform("blurSize",this.shadowBlur),this._gaussianPassH.setUniform("blurDir",0),this._gaussianPassV.setUniform("blurSize",this.shadowBlur),this._gaussianPassV.setUniform("blurDir",1),this._outputDepthPass=new vr({fragment:Xt.source("clay.sm.debug_depth")})}),{render:function(t,e,n,i){n||(n=e.getMainCamera()),this.trigger("beforerender",this,t,e,n),this._renderShadowPass(t,e,n,i),this.trigger("afterrender",this,t,e,n)},renderDebug:function(t,e){t.saveClear();var n=t.viewport,i=0,r=0,a=e||n.width/4,o=a;for(var s in this.softShadow===Ko.VSM?this._outputDepthPass.material.define("fragment","USE_VSM"):this._outputDepthPass.material.undefine("fragment","USE_VSM"),this._textures){var l=this._textures[s];t.setViewport(i,r,a*l.width/l.height,o),this._outputDepthPass.setUniform("depthMap",l),this._outputDepthPass.render(t),i+=a*l.width/l.height}t.setViewport(n),t.restoreClear()},_updateReceivers:function(t,e){if(e.receiveShadow?(this._receivers.push(e),e.material.set("shadowEnabled",1),e.material.set("pcfKernel",this.kernelPCF)):e.material.set("shadowEnabled",0),this.softShadow===Ko.VSM)e.material.define("fragment","USE_VSM"),e.material.undefine("fragment","PCF_KERNEL_SIZE");else{e.material.undefine("fragment","USE_VSM");var n=this.kernelPCF;n&&n.length?e.material.define("fragment","PCF_KERNEL_SIZE",n.length/2):e.material.undefine("fragment","PCF_KERNEL_SIZE")}},_update:function(t,e){var n=this;e.traverse((function(e){e.isRenderable()&&n._updateReceivers(t,e)}));for(var i=0;i4){console.warn("Support at most 4 cascade");continue}p.shadowCascade>1&&(o=p),this.renderDirectionalLightShadow(t,e,n,p,h,c,u)}else"SPOT_LIGHT"===p.type?this.renderSpotLightShadow(t,e,p,l,s):"POINT_LIGHT"===p.type&&this.renderPointLightShadow(t,e,p,d);this._shadowMapNumber[p.type]++}for(var g in this._shadowMapNumber){var m=this._shadowMapNumber[g],v=g+"_SHADOWMAP_COUNT";for(f=0;f0?_.define("fragment",v,m):_.isDefined("fragment",v)&&_.undefine("fragment",v))}}for(f=0;f0){var x=u.map(T);if(b.directionalLightShadowMaps={value:u,type:"tv"},b.directionalLightMatrices={value:c,type:"m4v"},b.directionalLightShadowMapSizes={value:x,type:"1fv"},o){var w=h.slice(),O=h.slice();w.pop(),O.shift(),w.reverse(),O.reverse(),c.reverse(),b.shadowCascadeClipsNear={value:w,type:"1fv"},b.shadowCascadeClipsFar={value:O,type:"1fv"}}}if(s.length>0){var S=s.map(T);b=e.shadowUniforms;b.spotLightShadowMaps={value:s,type:"tv"},b.spotLightMatrices={value:l,type:"m4v"},b.spotLightShadowMapSizes={value:S,type:"1fv"}}d.length>0&&(b.pointLightShadowMaps={value:d,type:"tv"})}function T(t){return t.height}},renderDirectionalLightShadow:function(){var t=new Bn,e=new Le,n=new ze,i=new Le,r=new Le,a=new Le,o=new Le;return function(s,l,u,c,h,d,f){var p=this._getDepthMaterial(c),g={getMaterial:function(t){return t.shadowDepthMaterial||p},isMaterialChanged:Yo,getUniform:qo,ifRender:function(t){return t.castShadow},sortCompare:ce.opaqueSortCompare};if(!l.viewBoundingBoxLastFrame.isFinite()){var m=l.getBoundingBox();l.viewBoundingBoxLastFrame.copy(m).applyTransform(u.viewMatrix)}var v=Math.min(-l.viewBoundingBoxLastFrame.min.z,u.far),y=Math.max(-l.viewBoundingBoxLastFrame.max.z,u.near),_=this._getDirectionalLightCamera(c,l,u),b=a.array;o.copy(_.projectionMatrix),Yt.invert(r.array,_.worldTransform.array),Yt.multiply(r.array,r.array,u.worldTransform.array),Yt.multiply(b,o.array,r.array);for(var x=[],w=u instanceof ni,O=(u.near+u.far)/(u.near-u.far),S=2*u.near*u.far/(u.near-u.far),T=0;T<=c.shadowCascade;T++){var M=y*Math.pow(v/y,T/c.shadowCascade),A=y+(v-y)*T/c.shadowCascade,C=M*c.cascadeSplitLogFactor+A*(1-c.cascadeSplitLogFactor);x.push(C),h.push(-(-C*O+S)/-C)}var I=this._getTexture(c,c.shadowCascade);f.push(I);var D=s.viewport,L=s.gl;this._frameBuffer.attach(I),this._frameBuffer.bind(s),L.clear(L.COLOR_BUFFER_BIT|L.DEPTH_BUFFER_BIT);for(T=0;Td?s>f?p[r>0?"px":"nx"]=!0:p[o>0?"pz":"nz"]=!0:d>f?p[a>0?"py":"ny"]=!0:p[o>0?"pz":"nz"]=!0}for(n=0;n0){var e=this.outputs[t];e.keepLastFrame?(this._prevOutputTextures[t]&&this._compositor.releaseTexture(this._prevOutputTextures[t]),this._prevOutputTextures[t]=this._outputTextures[t]):this._compositor.releaseTexture(this._outputTextures[t])}}}),$o=Jo,ts=O.extend((function(){return{nodes:[]}}),{dirty:function(){this._dirty=!0},addNode:function(t){this.nodes.indexOf(t)>=0||(this.nodes.push(t),this._dirty=!0)},removeNode:function(t){"string"===typeof t&&(t=this.getNodeByName(t));var e=this.nodes.indexOf(t);e>=0&&(this.nodes.splice(e,1),this._dirty=!0)},getNodeByName:function(t){for(var e=0;e=n.COLOR_ATTACHMENT0&&l<=n.COLOR_ATTACHMENT0+8&&c.push(l);u.drawBuffersEXT(c)}t.saveClear(),t.clearBit=C.DEPTH_BUFFER_BIT|C.COLOR_BUFFER_BIT,e=t.render(this.scene,this.camera,!this.autoUpdateScene,this.preZ),t.restoreClear(),i.unbind(t)}else e=t.render(this.scene,this.camera,!this.autoUpdateScene,this.preZ);this.trigger("afterrender",e),this._rendering=!1,this._rendered=!0}}),as=rs,os=$o.extend((function(){return{texture:null,outputs:{color:{}}}}),(function(){}),{getOutput:function(t,e){return this.texture},beforeFrame:function(){},afterFrame:function(){}}),ss=os,ls=$o.extend((function(){return{name:"",inputs:{},outputs:null,shader:"",inputLinks:{},outputLinks:{},pass:null,_prevOutputTextures:{},_outputTextures:{},_outputReferences:{},_rendering:!1,_rendered:!1,_compositor:null}}),(function(){var t=new vr({fragment:this.shader});this.pass=t}),{render:function(t,e){this.trigger("beforerender",t),this._rendering=!0;var n=t.gl;for(var i in this.inputLinks){var r=this.inputLinks[i],a=r.node.getOutput(t,r.pin);this.pass.setUniform(i,a)}if(this.outputs){this.pass.outputs={};var o={};for(var s in this.outputs){var l=this.updateParameter(s,t);isNaN(l.width)&&this.updateParameter(s,t);var u=this.outputs[s],c=this._compositor.allocateTexture(l);this._outputTextures[s]=c;var h=u.attachment||n.COLOR_ATTACHMENT0;"string"===typeof h&&(h=n[h]),o[h]=c}for(var h in this._compositor.getFrameBuffer().bind(t),o)this._compositor.getFrameBuffer().attach(o[h],h);this.pass.render(t),this._compositor.getFrameBuffer().updateMipmap(t)}else this.pass.outputs=null,this._compositor.getFrameBuffer().unbind(t),this.pass.render(t,e);for(var i in this.inputLinks){r=this.inputLinks[i];r.node.removeReference(r.pin)}this._rendering=!1,this._rendered=!0,this.trigger("afterrender",t)},updateParameter:function(t,e){var n,i,r=this.outputs[t],a=r.parameters,o=r._parametersCopy;if(o||(o=r._parametersCopy={}),a)for(var s in a)"width"!==s&&"height"!==s&&(o[s]=a[s]);return n="function"===typeof a.width?a.width.call(this,e):a.width,i="function"===typeof a.height?a.height.call(this,e):a.height,n=Math.ceil(n),i=Math.ceil(i),o.width===n&&o.height===i||this._outputTextures[t]&&this._outputTextures[t].dispose(e),o.width=n,o.height=i,o},setParameter:function(t,e){this.pass.setUniform(t,e)},getParameter:function(t){return this.pass.getUniform(t)},setParameters:function(t){for(var e in t)this.setParameter(e,t[e])},define:function(t,e){this.pass.material.define("fragment",t,e)},undefine:function(t){this.pass.material.undefine("fragment",t)},removeReference:function(t){if(this._outputReferences[t]--,0===this._outputReferences[t]){var e=this.outputs[t];e.keepLastFrame?(this._prevOutputTextures[t]&&this._compositor.releaseTexture(this._prevOutputTextures[t]),this._prevOutputTextures[t]=this._outputTextures[t]):this._compositor.releaseTexture(this._outputTextures[t])}},clear:function(){$o.prototype.clear.call(this),this.pass.material.disableTexturesAll()}}),us=ls,cs="@export clay.compositor.coloradjust\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform float brightness : 0.0;\nuniform float contrast : 1.0;\nuniform float exposure : 0.0;\nuniform float gamma : 1.0;\nuniform float saturation : 1.0;\nconst vec3 w = vec3(0.2125, 0.7154, 0.0721);\nvoid main()\n{\n vec4 tex = texture2D( texture, v_Texcoord);\n vec3 color = clamp(tex.rgb + vec3(brightness), 0.0, 1.0);\n color = clamp( (color-vec3(0.5))*contrast+vec3(0.5), 0.0, 1.0);\n color = clamp( color * pow(2.0, exposure), 0.0, 1.0);\n color = clamp( pow(color, vec3(gamma)), 0.0, 1.0);\n float luminance = dot( color, w );\n color = mix(vec3(luminance), color, saturation);\n gl_FragColor = vec4(color, tex.a);\n}\n@end\n@export clay.compositor.brightness\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform float brightness : 0.0;\nvoid main()\n{\n vec4 tex = texture2D( texture, v_Texcoord);\n vec3 color = tex.rgb + vec3(brightness);\n gl_FragColor = vec4(color, tex.a);\n}\n@end\n@export clay.compositor.contrast\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform float contrast : 1.0;\nvoid main()\n{\n vec4 tex = texture2D( texture, v_Texcoord);\n vec3 color = (tex.rgb-vec3(0.5))*contrast+vec3(0.5);\n gl_FragColor = vec4(color, tex.a);\n}\n@end\n@export clay.compositor.exposure\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform float exposure : 0.0;\nvoid main()\n{\n vec4 tex = texture2D(texture, v_Texcoord);\n vec3 color = tex.rgb * pow(2.0, exposure);\n gl_FragColor = vec4(color, tex.a);\n}\n@end\n@export clay.compositor.gamma\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform float gamma : 1.0;\nvoid main()\n{\n vec4 tex = texture2D(texture, v_Texcoord);\n vec3 color = pow(tex.rgb, vec3(gamma));\n gl_FragColor = vec4(color, tex.a);\n}\n@end\n@export clay.compositor.saturation\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform float saturation : 1.0;\nconst vec3 w = vec3(0.2125, 0.7154, 0.0721);\nvoid main()\n{\n vec4 tex = texture2D(texture, v_Texcoord);\n vec3 color = tex.rgb;\n float luminance = dot(color, w);\n color = mix(vec3(luminance), color, saturation);\n gl_FragColor = vec4(color, tex.a);\n}\n@end",hs="@export clay.compositor.kernel.gaussian_9\nfloat gaussianKernel[9];\ngaussianKernel[0] = 0.07;\ngaussianKernel[1] = 0.09;\ngaussianKernel[2] = 0.12;\ngaussianKernel[3] = 0.14;\ngaussianKernel[4] = 0.16;\ngaussianKernel[5] = 0.14;\ngaussianKernel[6] = 0.12;\ngaussianKernel[7] = 0.09;\ngaussianKernel[8] = 0.07;\n@end\n@export clay.compositor.kernel.gaussian_13\nfloat gaussianKernel[13];\ngaussianKernel[0] = 0.02;\ngaussianKernel[1] = 0.03;\ngaussianKernel[2] = 0.06;\ngaussianKernel[3] = 0.08;\ngaussianKernel[4] = 0.11;\ngaussianKernel[5] = 0.13;\ngaussianKernel[6] = 0.14;\ngaussianKernel[7] = 0.13;\ngaussianKernel[8] = 0.11;\ngaussianKernel[9] = 0.08;\ngaussianKernel[10] = 0.06;\ngaussianKernel[11] = 0.03;\ngaussianKernel[12] = 0.02;\n@end\n@export clay.compositor.gaussian_blur\n#define SHADER_NAME gaussian_blur\nuniform sampler2D texture;varying vec2 v_Texcoord;\nuniform float blurSize : 2.0;\nuniform vec2 textureSize : [512.0, 512.0];\nuniform float blurDir : 0.0;\n@import clay.util.rgbm\n@import clay.util.clamp_sample\nvoid main (void)\n{\n @import clay.compositor.kernel.gaussian_9\n vec2 off = blurSize / textureSize;\n off *= vec2(1.0 - blurDir, blurDir);\n vec4 sum = vec4(0.0);\n float weightAll = 0.0;\n for (int i = 0; i < 9; i++) {\n float w = gaussianKernel[i];\n vec4 texel = decodeHDR(clampSample(texture, v_Texcoord + float(i - 4) * off));\n sum += texel * w;\n weightAll += w;\n }\n gl_FragColor = encodeHDR(sum / max(weightAll, 0.01));\n}\n@end\n",ds="@export clay.compositor.hdr.log_lum\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nconst vec3 w = vec3(0.2125, 0.7154, 0.0721);\n@import clay.util.rgbm\nvoid main()\n{\n vec4 tex = decodeHDR(texture2D(texture, v_Texcoord));\n float luminance = dot(tex.rgb, w);\n luminance = log(luminance + 0.001);\n gl_FragColor = encodeHDR(vec4(vec3(luminance), 1.0));\n}\n@end\n@export clay.compositor.hdr.lum_adaption\nvarying vec2 v_Texcoord;\nuniform sampler2D adaptedLum;\nuniform sampler2D currentLum;\nuniform float frameTime : 0.02;\n@import clay.util.rgbm\nvoid main()\n{\n float fAdaptedLum = decodeHDR(texture2D(adaptedLum, vec2(0.5, 0.5))).r;\n float fCurrentLum = exp(encodeHDR(texture2D(currentLum, vec2(0.5, 0.5))).r);\n fAdaptedLum += (fCurrentLum - fAdaptedLum) * (1.0 - pow(0.98, 30.0 * frameTime));\n gl_FragColor = encodeHDR(vec4(vec3(fAdaptedLum), 1.0));\n}\n@end\n@export clay.compositor.lum\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nconst vec3 w = vec3(0.2125, 0.7154, 0.0721);\nvoid main()\n{\n vec4 tex = texture2D( texture, v_Texcoord );\n float luminance = dot(tex.rgb, w);\n gl_FragColor = vec4(vec3(luminance), 1.0);\n}\n@end",fs="\n@export clay.compositor.lut\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform sampler2D lookup;\nvoid main()\n{\n vec4 tex = texture2D(texture, v_Texcoord);\n float blueColor = tex.b * 63.0;\n vec2 quad1;\n quad1.y = floor(floor(blueColor) / 8.0);\n quad1.x = floor(blueColor) - (quad1.y * 8.0);\n vec2 quad2;\n quad2.y = floor(ceil(blueColor) / 8.0);\n quad2.x = ceil(blueColor) - (quad2.y * 8.0);\n vec2 texPos1;\n texPos1.x = (quad1.x * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * tex.r);\n texPos1.y = (quad1.y * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * tex.g);\n vec2 texPos2;\n texPos2.x = (quad2.x * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * tex.r);\n texPos2.y = (quad2.y * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * tex.g);\n vec4 newColor1 = texture2D(lookup, texPos1);\n vec4 newColor2 = texture2D(lookup, texPos2);\n vec4 newColor = mix(newColor1, newColor2, fract(blueColor));\n gl_FragColor = vec4(newColor.rgb, tex.w);\n}\n@end",ps="@export clay.compositor.vignette\n#define OUTPUT_ALPHA\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\nuniform float darkness: 1;\nuniform float offset: 1;\n@import clay.util.rgbm\nvoid main()\n{\n vec4 texel = decodeHDR(texture2D(texture, v_Texcoord));\n gl_FragColor.rgb = texel.rgb;\n vec2 uv = (v_Texcoord - vec2(0.5)) * vec2(offset);\n gl_FragColor = encodeHDR(vec4(mix(texel.rgb, vec3(1.0 - darkness), dot(uv, uv)), texel.a));\n}\n@end",gs="@export clay.compositor.output\n#define OUTPUT_ALPHA\nvarying vec2 v_Texcoord;\nuniform sampler2D texture;\n@import clay.util.rgbm\nvoid main()\n{\n vec4 tex = decodeHDR(texture2D(texture, v_Texcoord));\n gl_FragColor.rgb = tex.rgb;\n#ifdef OUTPUT_ALPHA\n gl_FragColor.a = tex.a;\n#else\n gl_FragColor.a = 1.0;\n#endif\n gl_FragColor = encodeHDR(gl_FragColor);\n#ifdef PREMULTIPLY_ALPHA\n gl_FragColor.rgb *= gl_FragColor.a;\n#endif\n}\n@end",ms="@export clay.compositor.bright\nuniform sampler2D texture;\nuniform float threshold : 1;\nuniform float scale : 1.0;\nuniform vec2 textureSize: [512, 512];\nvarying vec2 v_Texcoord;\nconst vec3 lumWeight = vec3(0.2125, 0.7154, 0.0721);\n@import clay.util.rgbm\nvec4 median(vec4 a, vec4 b, vec4 c)\n{\n return a + b + c - min(min(a, b), c) - max(max(a, b), c);\n}\nvoid main()\n{\n vec4 texel = decodeHDR(texture2D(texture, v_Texcoord));\n#ifdef ANTI_FLICKER\n vec3 d = 1.0 / textureSize.xyx * vec3(1.0, 1.0, 0.0);\n vec4 s1 = decodeHDR(texture2D(texture, v_Texcoord - d.xz));\n vec4 s2 = decodeHDR(texture2D(texture, v_Texcoord + d.xz));\n vec4 s3 = decodeHDR(texture2D(texture, v_Texcoord - d.zy));\n vec4 s4 = decodeHDR(texture2D(texture, v_Texcoord + d.zy));\n texel = median(median(texel, s1, s2), s3, s4);\n#endif\n float lum = dot(texel.rgb , lumWeight);\n vec4 color;\n if (lum > threshold && texel.a > 0.0)\n {\n color = vec4(texel.rgb * scale, texel.a * scale);\n }\n else\n {\n color = vec4(0.0);\n }\n gl_FragColor = encodeHDR(color);\n}\n@end\n",vs="@export clay.compositor.downsample\nuniform sampler2D texture;\nuniform vec2 textureSize : [512, 512];\nvarying vec2 v_Texcoord;\n@import clay.util.rgbm\nfloat brightness(vec3 c)\n{\n return max(max(c.r, c.g), c.b);\n}\n@import clay.util.clamp_sample\nvoid main()\n{\n vec4 d = vec4(-1.0, -1.0, 1.0, 1.0) / textureSize.xyxy;\n#ifdef ANTI_FLICKER\n vec3 s1 = decodeHDR(clampSample(texture, v_Texcoord + d.xy)).rgb;\n vec3 s2 = decodeHDR(clampSample(texture, v_Texcoord + d.zy)).rgb;\n vec3 s3 = decodeHDR(clampSample(texture, v_Texcoord + d.xw)).rgb;\n vec3 s4 = decodeHDR(clampSample(texture, v_Texcoord + d.zw)).rgb;\n float s1w = 1.0 / (brightness(s1) + 1.0);\n float s2w = 1.0 / (brightness(s2) + 1.0);\n float s3w = 1.0 / (brightness(s3) + 1.0);\n float s4w = 1.0 / (brightness(s4) + 1.0);\n float oneDivideSum = 1.0 / (s1w + s2w + s3w + s4w);\n vec4 color = vec4(\n (s1 * s1w + s2 * s2w + s3 * s3w + s4 * s4w) * oneDivideSum,\n 1.0\n );\n#else\n vec4 color = decodeHDR(clampSample(texture, v_Texcoord + d.xy));\n color += decodeHDR(clampSample(texture, v_Texcoord + d.zy));\n color += decodeHDR(clampSample(texture, v_Texcoord + d.xw));\n color += decodeHDR(clampSample(texture, v_Texcoord + d.zw));\n color *= 0.25;\n#endif\n gl_FragColor = encodeHDR(color);\n}\n@end",ys="\n@export clay.compositor.upsample\n#define HIGH_QUALITY\nuniform sampler2D texture;\nuniform vec2 textureSize : [512, 512];\nuniform float sampleScale: 0.5;\nvarying vec2 v_Texcoord;\n@import clay.util.rgbm\n@import clay.util.clamp_sample\nvoid main()\n{\n#ifdef HIGH_QUALITY\n vec4 d = vec4(1.0, 1.0, -1.0, 0.0) / textureSize.xyxy * sampleScale;\n vec4 s;\n s = decodeHDR(clampSample(texture, v_Texcoord - d.xy));\n s += decodeHDR(clampSample(texture, v_Texcoord - d.wy)) * 2.0;\n s += decodeHDR(clampSample(texture, v_Texcoord - d.zy));\n s += decodeHDR(clampSample(texture, v_Texcoord + d.zw)) * 2.0;\n s += decodeHDR(clampSample(texture, v_Texcoord )) * 4.0;\n s += decodeHDR(clampSample(texture, v_Texcoord + d.xw)) * 2.0;\n s += decodeHDR(clampSample(texture, v_Texcoord + d.zy));\n s += decodeHDR(clampSample(texture, v_Texcoord + d.wy)) * 2.0;\n s += decodeHDR(clampSample(texture, v_Texcoord + d.xy));\n gl_FragColor = encodeHDR(s / 16.0);\n#else\n vec4 d = vec4(-1.0, -1.0, +1.0, +1.0) / textureSize.xyxy;\n vec4 s;\n s = decodeHDR(clampSample(texture, v_Texcoord + d.xy));\n s += decodeHDR(clampSample(texture, v_Texcoord + d.zy));\n s += decodeHDR(clampSample(texture, v_Texcoord + d.xw));\n s += decodeHDR(clampSample(texture, v_Texcoord + d.zw));\n gl_FragColor = encodeHDR(s / 4.0);\n#endif\n}\n@end",_s="@export clay.compositor.hdr.composite\n#define TONEMAPPING\nuniform sampler2D texture;\n#ifdef BLOOM_ENABLED\nuniform sampler2D bloom;\n#endif\n#ifdef LENSFLARE_ENABLED\nuniform sampler2D lensflare;\nuniform sampler2D lensdirt;\n#endif\n#ifdef LUM_ENABLED\nuniform sampler2D lum;\n#endif\n#ifdef LUT_ENABLED\nuniform sampler2D lut;\n#endif\n#ifdef COLOR_CORRECTION\nuniform float brightness : 0.0;\nuniform float contrast : 1.0;\nuniform float saturation : 1.0;\n#endif\n#ifdef VIGNETTE\nuniform float vignetteDarkness: 1.0;\nuniform float vignetteOffset: 1.0;\n#endif\nuniform float exposure : 1.0;\nuniform float bloomIntensity : 0.25;\nuniform float lensflareIntensity : 1;\nvarying vec2 v_Texcoord;\n@import clay.util.srgb\nvec3 ACESToneMapping(vec3 color)\n{\n const float A = 2.51;\n const float B = 0.03;\n const float C = 2.43;\n const float D = 0.59;\n const float E = 0.14;\n return (color * (A * color + B)) / (color * (C * color + D) + E);\n}\nfloat eyeAdaption(float fLum)\n{\n return mix(0.2, fLum, 0.5);\n}\n#ifdef LUT_ENABLED\nvec3 lutTransform(vec3 color) {\n float blueColor = color.b * 63.0;\n vec2 quad1;\n quad1.y = floor(floor(blueColor) / 8.0);\n quad1.x = floor(blueColor) - (quad1.y * 8.0);\n vec2 quad2;\n quad2.y = floor(ceil(blueColor) / 8.0);\n quad2.x = ceil(blueColor) - (quad2.y * 8.0);\n vec2 texPos1;\n texPos1.x = (quad1.x * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * color.r);\n texPos1.y = (quad1.y * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * color.g);\n vec2 texPos2;\n texPos2.x = (quad2.x * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * color.r);\n texPos2.y = (quad2.y * 0.125) + 0.5/512.0 + ((0.125 - 1.0/512.0) * color.g);\n vec4 newColor1 = texture2D(lut, texPos1);\n vec4 newColor2 = texture2D(lut, texPos2);\n vec4 newColor = mix(newColor1, newColor2, fract(blueColor));\n return newColor.rgb;\n}\n#endif\n@import clay.util.rgbm\nvoid main()\n{\n vec4 texel = vec4(0.0);\n vec4 originalTexel = vec4(0.0);\n#ifdef TEXTURE_ENABLED\n texel = decodeHDR(texture2D(texture, v_Texcoord));\n originalTexel = texel;\n#endif\n#ifdef BLOOM_ENABLED\n vec4 bloomTexel = decodeHDR(texture2D(bloom, v_Texcoord));\n texel.rgb += bloomTexel.rgb * bloomIntensity;\n texel.a += bloomTexel.a * bloomIntensity;\n#endif\n#ifdef LENSFLARE_ENABLED\n texel += decodeHDR(texture2D(lensflare, v_Texcoord)) * texture2D(lensdirt, v_Texcoord) * lensflareIntensity;\n#endif\n texel.a = min(texel.a, 1.0);\n#ifdef LUM_ENABLED\n float fLum = texture2D(lum, vec2(0.5, 0.5)).r;\n float adaptedLumDest = 3.0 / (max(0.1, 1.0 + 10.0*eyeAdaption(fLum)));\n float exposureBias = adaptedLumDest * exposure;\n#else\n float exposureBias = exposure;\n#endif\n#ifdef TONEMAPPING\n texel.rgb *= exposureBias;\n texel.rgb = ACESToneMapping(texel.rgb);\n#endif\n texel = linearTosRGB(texel);\n#ifdef LUT_ENABLED\n texel.rgb = lutTransform(clamp(texel.rgb,vec3(0.0),vec3(1.0)));\n#endif\n#ifdef COLOR_CORRECTION\n texel.rgb = clamp(texel.rgb + vec3(brightness), 0.0, 1.0);\n texel.rgb = clamp((texel.rgb - vec3(0.5))*contrast+vec3(0.5), 0.0, 1.0);\n float lum = dot(texel.rgb, vec3(0.2125, 0.7154, 0.0721));\n texel.rgb = mix(vec3(lum), texel.rgb, saturation);\n#endif\n#ifdef VIGNETTE\n vec2 uv = (v_Texcoord - vec2(0.5)) * vec2(vignetteOffset);\n texel.rgb = mix(texel.rgb, vec3(1.0 - vignetteDarkness), dot(uv, uv));\n#endif\n gl_FragColor = encodeHDR(texel);\n#ifdef DEBUG\n #if DEBUG == 1\n gl_FragColor = encodeHDR(decodeHDR(texture2D(texture, v_Texcoord)));\n #elif DEBUG == 2\n gl_FragColor = encodeHDR(decodeHDR(texture2D(bloom, v_Texcoord)) * bloomIntensity);\n #elif DEBUG == 3\n gl_FragColor = encodeHDR(decodeHDR(texture2D(lensflare, v_Texcoord) * lensflareIntensity));\n #endif\n#endif\n if (originalTexel.a <= 0.01 && gl_FragColor.a > 1e-5) {\n gl_FragColor.a = dot(gl_FragColor.rgb, vec3(0.2125, 0.7154, 0.0721));\n }\n#ifdef PREMULTIPLY_ALPHA\n gl_FragColor.rgb *= gl_FragColor.a;\n#endif\n}\n@end",bs="@export clay.compositor.lensflare\n#define SAMPLE_NUMBER 8\nuniform sampler2D texture;\nuniform sampler2D lenscolor;\nuniform vec2 textureSize : [512, 512];\nuniform float dispersal : 0.3;\nuniform float haloWidth : 0.4;\nuniform float distortion : 1.0;\nvarying vec2 v_Texcoord;\n@import clay.util.rgbm\nvec4 textureDistorted(\n in vec2 texcoord,\n in vec2 direction,\n in vec3 distortion\n) {\n return vec4(\n decodeHDR(texture2D(texture, texcoord + direction * distortion.r)).r,\n decodeHDR(texture2D(texture, texcoord + direction * distortion.g)).g,\n decodeHDR(texture2D(texture, texcoord + direction * distortion.b)).b,\n 1.0\n );\n}\nvoid main()\n{\n vec2 texcoord = -v_Texcoord + vec2(1.0); vec2 textureOffset = 1.0 / textureSize;\n vec2 ghostVec = (vec2(0.5) - texcoord) * dispersal;\n vec2 haloVec = normalize(ghostVec) * haloWidth;\n vec3 distortion = vec3(-textureOffset.x * distortion, 0.0, textureOffset.x * distortion);\n vec4 result = vec4(0.0);\n for (int i = 0; i < SAMPLE_NUMBER; i++)\n {\n vec2 offset = fract(texcoord + ghostVec * float(i));\n float weight = length(vec2(0.5) - offset) / length(vec2(0.5));\n weight = pow(1.0 - weight, 10.0);\n result += textureDistorted(offset, normalize(ghostVec), distortion) * weight;\n }\n result *= texture2D(lenscolor, vec2(length(vec2(0.5) - texcoord)) / length(vec2(0.5)));\n float weight = length(vec2(0.5) - fract(texcoord + haloVec)) / length(vec2(0.5));\n weight = pow(1.0 - weight, 10.0);\n vec2 offset = fract(texcoord + haloVec);\n result += textureDistorted(offset, normalize(ghostVec), distortion) * weight;\n gl_FragColor = result;\n}\n@end",xs="@export clay.compositor.blend\n#define SHADER_NAME blend\n#ifdef TEXTURE1_ENABLED\nuniform sampler2D texture1;\nuniform float weight1 : 1.0;\n#endif\n#ifdef TEXTURE2_ENABLED\nuniform sampler2D texture2;\nuniform float weight2 : 1.0;\n#endif\n#ifdef TEXTURE3_ENABLED\nuniform sampler2D texture3;\nuniform float weight3 : 1.0;\n#endif\n#ifdef TEXTURE4_ENABLED\nuniform sampler2D texture4;\nuniform float weight4 : 1.0;\n#endif\n#ifdef TEXTURE5_ENABLED\nuniform sampler2D texture5;\nuniform float weight5 : 1.0;\n#endif\n#ifdef TEXTURE6_ENABLED\nuniform sampler2D texture6;\nuniform float weight6 : 1.0;\n#endif\nvarying vec2 v_Texcoord;\n@import clay.util.rgbm\nvoid main()\n{\n vec4 tex = vec4(0.0);\n#ifdef TEXTURE1_ENABLED\n tex += decodeHDR(texture2D(texture1, v_Texcoord)) * weight1;\n#endif\n#ifdef TEXTURE2_ENABLED\n tex += decodeHDR(texture2D(texture2, v_Texcoord)) * weight2;\n#endif\n#ifdef TEXTURE3_ENABLED\n tex += decodeHDR(texture2D(texture3, v_Texcoord)) * weight3;\n#endif\n#ifdef TEXTURE4_ENABLED\n tex += decodeHDR(texture2D(texture4, v_Texcoord)) * weight4;\n#endif\n#ifdef TEXTURE5_ENABLED\n tex += decodeHDR(texture2D(texture5, v_Texcoord)) * weight5;\n#endif\n#ifdef TEXTURE6_ENABLED\n tex += decodeHDR(texture2D(texture6, v_Texcoord)) * weight6;\n#endif\n gl_FragColor = encodeHDR(tex);\n}\n@end",ws="@export clay.compositor.fxaa\nuniform sampler2D texture;\nuniform vec4 viewport : VIEWPORT;\nvarying vec2 v_Texcoord;\n#define FXAA_REDUCE_MIN (1.0/128.0)\n#define FXAA_REDUCE_MUL (1.0/8.0)\n#define FXAA_SPAN_MAX 8.0\n@import clay.util.rgbm\nvoid main()\n{\n vec2 resolution = 1.0 / viewport.zw;\n vec3 rgbNW = decodeHDR( texture2D( texture, ( gl_FragCoord.xy + vec2( -1.0, -1.0 ) ) * resolution ) ).xyz;\n vec3 rgbNE = decodeHDR( texture2D( texture, ( gl_FragCoord.xy + vec2( 1.0, -1.0 ) ) * resolution ) ).xyz;\n vec3 rgbSW = decodeHDR( texture2D( texture, ( gl_FragCoord.xy + vec2( -1.0, 1.0 ) ) * resolution ) ).xyz;\n vec3 rgbSE = decodeHDR( texture2D( texture, ( gl_FragCoord.xy + vec2( 1.0, 1.0 ) ) * resolution ) ).xyz;\n vec4 rgbaM = decodeHDR( texture2D( texture, gl_FragCoord.xy * resolution ) );\n vec3 rgbM = rgbaM.xyz;\n float opacity = rgbaM.w;\n vec3 luma = vec3( 0.299, 0.587, 0.114 );\n float lumaNW = dot( rgbNW, luma );\n float lumaNE = dot( rgbNE, luma );\n float lumaSW = dot( rgbSW, luma );\n float lumaSE = dot( rgbSE, luma );\n float lumaM = dot( rgbM, luma );\n float lumaMin = min( lumaM, min( min( lumaNW, lumaNE ), min( lumaSW, lumaSE ) ) );\n float lumaMax = max( lumaM, max( max( lumaNW, lumaNE) , max( lumaSW, lumaSE ) ) );\n vec2 dir;\n dir.x = -((lumaNW + lumaNE) - (lumaSW + lumaSE));\n dir.y = ((lumaNW + lumaSW) - (lumaNE + lumaSE));\n float dirReduce = max( ( lumaNW + lumaNE + lumaSW + lumaSE ) * ( 0.25 * FXAA_REDUCE_MUL ), FXAA_REDUCE_MIN );\n float rcpDirMin = 1.0 / ( min( abs( dir.x ), abs( dir.y ) ) + dirReduce );\n dir = min( vec2( FXAA_SPAN_MAX, FXAA_SPAN_MAX),\n max( vec2(-FXAA_SPAN_MAX, -FXAA_SPAN_MAX),\n dir * rcpDirMin)) * resolution;\n vec3 rgbA = decodeHDR( texture2D( texture, gl_FragCoord.xy * resolution + dir * ( 1.0 / 3.0 - 0.5 ) ) ).xyz;\n rgbA += decodeHDR( texture2D( texture, gl_FragCoord.xy * resolution + dir * ( 2.0 / 3.0 - 0.5 ) ) ).xyz;\n rgbA *= 0.5;\n vec3 rgbB = decodeHDR( texture2D( texture, gl_FragCoord.xy * resolution + dir * -0.5 ) ).xyz;\n rgbB += decodeHDR( texture2D( texture, gl_FragCoord.xy * resolution + dir * 0.5 ) ).xyz;\n rgbB *= 0.25;\n rgbB += rgbA * 0.5;\n float lumaB = dot( rgbB, luma );\n if ( ( lumaB < lumaMin ) || ( lumaB > lumaMax ) )\n {\n gl_FragColor = vec4( rgbA, opacity );\n }\n else {\n gl_FragColor = vec4( rgbB, opacity );\n }\n}\n@end";function Os(t){t["import"](cs),t["import"](hs),t["import"](ds),t["import"](fs),t["import"](ps),t["import"](gs),t["import"](ms),t["import"](vs),t["import"](ys),t["import"](_s),t["import"](bs),t["import"](xs),t["import"](ws)}Os(Xt);var Ss=/^#source\((.*?)\)/;function Ts(t,e){var n=new is;e=e||{};var i={textures:{},parameters:{}},r=function(r,a){for(var o=0;o0)n+=i*(r%e),r=Math.floor(r/e),i/=e;return n}var ks=Rs,Bs="@export ecgl.ssao.estimate\n\nuniform sampler2D depthTex;\n\nuniform sampler2D normalTex;\n\nuniform sampler2D noiseTex;\n\nuniform vec2 depthTexSize;\n\nuniform vec2 noiseTexSize;\n\nuniform mat4 projection;\n\nuniform mat4 projectionInv;\n\nuniform mat4 viewInverseTranspose;\n\nuniform vec3 kernel[KERNEL_SIZE];\n\nuniform float radius : 1;\n\nuniform float power : 1;\n\nuniform float bias: 1e-2;\n\nuniform float intensity: 1.0;\n\nvarying vec2 v_Texcoord;\n\nfloat ssaoEstimator(in vec3 originPos, in mat3 kernelBasis) {\n float occlusion = 0.0;\n\n for (int i = 0; i < KERNEL_SIZE; i++) {\n vec3 samplePos = kernel[i];\n#ifdef NORMALTEX_ENABLED\n samplePos = kernelBasis * samplePos;\n#endif\n samplePos = samplePos * radius + originPos;\n\n vec4 texCoord = projection * vec4(samplePos, 1.0);\n texCoord.xy /= texCoord.w;\n\n vec4 depthTexel = texture2D(depthTex, texCoord.xy * 0.5 + 0.5);\n\n float sampleDepth = depthTexel.r * 2.0 - 1.0;\n if (projection[3][3] == 0.0) {\n sampleDepth = projection[3][2] / (sampleDepth * projection[2][3] - projection[2][2]);\n }\n else {\n sampleDepth = (sampleDepth - projection[3][2]) / projection[2][2];\n }\n \n float rangeCheck = smoothstep(0.0, 1.0, radius / abs(originPos.z - sampleDepth));\n occlusion += rangeCheck * step(samplePos.z, sampleDepth - bias);\n }\n#ifdef NORMALTEX_ENABLED\n occlusion = 1.0 - occlusion / float(KERNEL_SIZE);\n#else\n occlusion = 1.0 - clamp((occlusion / float(KERNEL_SIZE) - 0.6) * 2.5, 0.0, 1.0);\n#endif\n return pow(occlusion, power);\n}\n\nvoid main()\n{\n\n vec4 depthTexel = texture2D(depthTex, v_Texcoord);\n\n#ifdef NORMALTEX_ENABLED\n vec4 tex = texture2D(normalTex, v_Texcoord);\n if (dot(tex.rgb, tex.rgb) == 0.0) {\n gl_FragColor = vec4(1.0);\n return;\n }\n vec3 N = tex.rgb * 2.0 - 1.0;\n N = (viewInverseTranspose * vec4(N, 0.0)).xyz;\n\n vec2 noiseTexCoord = depthTexSize / vec2(noiseTexSize) * v_Texcoord;\n vec3 rvec = texture2D(noiseTex, noiseTexCoord).rgb * 2.0 - 1.0;\n vec3 T = normalize(rvec - N * dot(rvec, N));\n vec3 BT = normalize(cross(N, T));\n mat3 kernelBasis = mat3(T, BT, N);\n#else\n if (depthTexel.r > 0.99999) {\n gl_FragColor = vec4(1.0);\n return;\n }\n mat3 kernelBasis;\n#endif\n\n float z = depthTexel.r * 2.0 - 1.0;\n\n vec4 projectedPos = vec4(v_Texcoord * 2.0 - 1.0, z, 1.0);\n vec4 p4 = projectionInv * projectedPos;\n\n vec3 position = p4.xyz / p4.w;\n\n float ao = ssaoEstimator(position, kernelBasis);\n ao = clamp(1.0 - (1.0 - ao) * intensity, 0.0, 1.0);\n gl_FragColor = vec4(vec3(ao), 1.0);\n}\n\n@end\n\n\n@export ecgl.ssao.blur\n#define SHADER_NAME SSAO_BLUR\n\nuniform sampler2D ssaoTexture;\n\n#ifdef NORMALTEX_ENABLED\nuniform sampler2D normalTex;\n#endif\n\nvarying vec2 v_Texcoord;\n\nuniform vec2 textureSize;\nuniform float blurSize : 1.0;\n\nuniform int direction: 0.0;\n\n#ifdef DEPTHTEX_ENABLED\nuniform sampler2D depthTex;\nuniform mat4 projection;\nuniform float depthRange : 0.5;\n\nfloat getLinearDepth(vec2 coord)\n{\n float depth = texture2D(depthTex, coord).r * 2.0 - 1.0;\n return projection[3][2] / (depth * projection[2][3] - projection[2][2]);\n}\n#endif\n\nvoid main()\n{\n float kernel[5];\n kernel[0] = 0.122581;\n kernel[1] = 0.233062;\n kernel[2] = 0.288713;\n kernel[3] = 0.233062;\n kernel[4] = 0.122581;\n\n vec2 off = vec2(0.0);\n if (direction == 0) {\n off[0] = blurSize / textureSize.x;\n }\n else {\n off[1] = blurSize / textureSize.y;\n }\n\n vec2 coord = v_Texcoord;\n\n float sum = 0.0;\n float weightAll = 0.0;\n\n#ifdef NORMALTEX_ENABLED\n vec3 centerNormal = texture2D(normalTex, v_Texcoord).rgb * 2.0 - 1.0;\n#endif\n#if defined(DEPTHTEX_ENABLED)\n float centerDepth = getLinearDepth(v_Texcoord);\n#endif\n\n for (int i = 0; i < 5; i++) {\n vec2 coord = clamp(v_Texcoord + vec2(float(i) - 2.0) * off, vec2(0.0), vec2(1.0));\n\n float w = kernel[i];\n#ifdef NORMALTEX_ENABLED\n vec3 normal = texture2D(normalTex, coord).rgb * 2.0 - 1.0;\n w *= clamp(dot(normal, centerNormal), 0.0, 1.0);\n#endif\n#ifdef DEPTHTEX_ENABLED\n float d = getLinearDepth(coord);\n w *= (1.0 - smoothstep(abs(centerDepth - d) / depthRange, 0.0, 1.0));\n#endif\n\n weightAll += w;\n sum += texture2D(ssaoTexture, coord).r * w;\n }\n\n gl_FragColor = vec4(vec3(sum / weightAll), 1.0);\n}\n\n@end\n";function zs(t){for(var e=new Uint8Array(t*t*4),n=0,i=new ye,r=0;r 0.999 ? vec3(1.0, 0.0, 0.0) : vec3(0.0, 1.0, 0.0);\n vec3 tangentX = normalize(cross(N, upVector));\n vec3 tangentZ = cross(N, tangentX);\n return normalize(tangentX * H.x + N * H.y + tangentZ * H.z);\n}\nvec3 importanceSampleNormalGGX(float i, float roughness, vec3 N) {\n float p = fract((i + sampleOffset) / float(TOTAL_SAMPLES));\n vec3 H = texture2D(normalDistribution,vec2(roughness, p)).rgb;\n return transformNormal(H, N);\n}\nfloat G_Smith(float g, float ndv, float ndl) {\n float roughness = 1.0 - g;\n float k = roughness * roughness / 2.0;\n float G1V = ndv / (ndv * (1.0 - k) + k);\n float G1L = ndl / (ndl * (1.0 - k) + k);\n return G1L * G1V;\n}\nvec3 F_Schlick(float ndv, vec3 spec) {\n return spec + (1.0 - spec) * pow(1.0 - ndv, 5.0);\n}\n#endif\n\nfloat fetchDepth(sampler2D depthTexture, vec2 uv)\n{\n vec4 depthTexel = texture2D(depthTexture, uv);\n return depthTexel.r * 2.0 - 1.0;\n}\n\nfloat linearDepth(float depth)\n{\n if (projection[3][3] == 0.0) {\n return projection[3][2] / (depth * projection[2][3] - projection[2][2]);\n }\n else {\n return (depth - projection[3][2]) / projection[2][2];\n }\n}\n\nbool rayIntersectDepth(float rayZNear, float rayZFar, vec2 hitPixel)\n{\n if (rayZFar > rayZNear)\n {\n float t = rayZFar; rayZFar = rayZNear; rayZNear = t;\n }\n float cameraZ = linearDepth(fetchDepth(gBufferTexture2, hitPixel));\n return rayZFar <= cameraZ && rayZNear >= cameraZ - zThicknessThreshold;\n}\n\n\nbool traceScreenSpaceRay(\n vec3 rayOrigin, vec3 rayDir, float jitter,\n out vec2 hitPixel, out vec3 hitPoint, out float iterationCount\n)\n{\n float rayLength = ((rayOrigin.z + rayDir.z * maxRayDistance) > -nearZ)\n ? (-nearZ - rayOrigin.z) / rayDir.z : maxRayDistance;\n\n vec3 rayEnd = rayOrigin + rayDir * rayLength;\n\n vec4 H0 = projection * vec4(rayOrigin, 1.0);\n vec4 H1 = projection * vec4(rayEnd, 1.0);\n\n float k0 = 1.0 / H0.w, k1 = 1.0 / H1.w;\n\n vec3 Q0 = rayOrigin * k0, Q1 = rayEnd * k1;\n\n vec2 P0 = (H0.xy * k0 * 0.5 + 0.5) * viewportSize;\n vec2 P1 = (H1.xy * k1 * 0.5 + 0.5) * viewportSize;\n\n P1 += dot(P1 - P0, P1 - P0) < 0.0001 ? 0.01 : 0.0;\n vec2 delta = P1 - P0;\n\n bool permute = false;\n if (abs(delta.x) < abs(delta.y)) {\n permute = true;\n delta = delta.yx;\n P0 = P0.yx;\n P1 = P1.yx;\n }\n float stepDir = sign(delta.x);\n float invdx = stepDir / delta.x;\n\n vec3 dQ = (Q1 - Q0) * invdx;\n float dk = (k1 - k0) * invdx;\n\n vec2 dP = vec2(stepDir, delta.y * invdx);\n\n float strideScaler = 1.0 - min(1.0, -rayOrigin.z / pixelStrideZCutoff);\n float pixStride = 1.0 + strideScaler * pixelStride;\n\n dP *= pixStride; dQ *= pixStride; dk *= pixStride;\n\n vec4 pqk = vec4(P0, Q0.z, k0);\n vec4 dPQK = vec4(dP, dQ.z, dk);\n\n pqk += dPQK * jitter;\n float rayZFar = (dPQK.z * 0.5 + pqk.z) / (dPQK.w * 0.5 + pqk.w);\n float rayZNear;\n\n bool intersect = false;\n\n vec2 texelSize = 1.0 / viewportSize;\n\n iterationCount = 0.0;\n\n for (int i = 0; i < MAX_ITERATION; i++)\n {\n pqk += dPQK;\n\n rayZNear = rayZFar;\n rayZFar = (dPQK.z * 0.5 + pqk.z) / (dPQK.w * 0.5 + pqk.w);\n\n hitPixel = permute ? pqk.yx : pqk.xy;\n hitPixel *= texelSize;\n\n intersect = rayIntersectDepth(rayZNear, rayZFar, hitPixel);\n\n iterationCount += 1.0;\n\n dPQK *= 1.2;\n\n if (intersect) {\n break;\n }\n }\n\n Q0.xy += dQ.xy * iterationCount;\n Q0.z = pqk.z;\n hitPoint = Q0 / pqk.w;\n\n return intersect;\n}\n\nfloat calculateAlpha(\n float iterationCount, float reflectivity,\n vec2 hitPixel, vec3 hitPoint, float dist, vec3 rayDir\n)\n{\n float alpha = clamp(reflectivity, 0.0, 1.0);\n alpha *= 1.0 - (iterationCount / float(MAX_ITERATION));\n vec2 hitPixelNDC = hitPixel * 2.0 - 1.0;\n float maxDimension = min(1.0, max(abs(hitPixelNDC.x), abs(hitPixelNDC.y)));\n alpha *= 1.0 - max(0.0, maxDimension - screenEdgeFadeStart) / (1.0 - screenEdgeFadeStart);\n\n float _eyeFadeStart = eyeFadeStart;\n float _eyeFadeEnd = eyeFadeEnd;\n if (_eyeFadeStart > _eyeFadeEnd) {\n float tmp = _eyeFadeEnd;\n _eyeFadeEnd = _eyeFadeStart;\n _eyeFadeStart = tmp;\n }\n\n float eyeDir = clamp(rayDir.z, _eyeFadeStart, _eyeFadeEnd);\n alpha *= 1.0 - (eyeDir - _eyeFadeStart) / (_eyeFadeEnd - _eyeFadeStart);\n\n alpha *= 1.0 - clamp(dist / maxRayDistance, 0.0, 1.0);\n\n return alpha;\n}\n\n@import clay.util.rand\n\n@import clay.util.rgbm\n\nvoid main()\n{\n vec4 normalAndGloss = texture2D(gBufferTexture1, v_Texcoord);\n\n if (dot(normalAndGloss.rgb, vec3(1.0)) == 0.0) {\n discard;\n }\n\n float g = normalAndGloss.a;\n#if !defined(PHYSICALLY_CORRECT)\n if (g <= minGlossiness) {\n discard;\n }\n#endif\n\n float reflectivity = (g - minGlossiness) / (1.0 - minGlossiness);\n\n vec3 N = normalize(normalAndGloss.rgb * 2.0 - 1.0);\n N = normalize((toViewSpace * vec4(N, 0.0)).xyz);\n\n vec4 projectedPos = vec4(v_Texcoord * 2.0 - 1.0, fetchDepth(gBufferTexture2, v_Texcoord), 1.0);\n vec4 pos = projectionInv * projectedPos;\n vec3 rayOrigin = pos.xyz / pos.w;\n vec3 V = -normalize(rayOrigin);\n\n float ndv = clamp(dot(N, V), 0.0, 1.0);\n float iterationCount;\n float jitter = rand(fract(v_Texcoord + jitterOffset));\n\n#ifdef PHYSICALLY_CORRECT\n vec4 color = vec4(vec3(0.0), 1.0);\n vec4 albedoMetalness = texture2D(gBufferTexture3, v_Texcoord);\n vec3 albedo = albedoMetalness.rgb;\n float m = albedoMetalness.a;\n vec3 diffuseColor = albedo * (1.0 - m);\n vec3 spec = mix(vec3(0.04), albedo, m);\n\n float jitter2 = rand(fract(v_Texcoord)) * float(TOTAL_SAMPLES);\n\n for (int i = 0; i < SAMPLE_PER_FRAME; i++) {\n vec3 H = importanceSampleNormalGGX(float(i) + jitter2, 1.0 - g, N);\n vec3 rayDir = normalize(reflect(-V, H));\n#else\n vec3 rayDir = normalize(reflect(-V, N));\n#endif\n vec2 hitPixel;\n vec3 hitPoint;\n\n bool intersect = traceScreenSpaceRay(rayOrigin, rayDir, jitter, hitPixel, hitPoint, iterationCount);\n\n float dist = distance(rayOrigin, hitPoint);\n\n vec3 hitNormal = texture2D(gBufferTexture1, hitPixel).rgb * 2.0 - 1.0;\n hitNormal = normalize((toViewSpace * vec4(hitNormal, 0.0)).xyz);\n#ifdef PHYSICALLY_CORRECT\n float ndl = clamp(dot(N, rayDir), 0.0, 1.0);\n float vdh = clamp(dot(V, H), 0.0, 1.0);\n float ndh = clamp(dot(N, H), 0.0, 1.0);\n vec3 litTexel = vec3(0.0);\n if (dot(hitNormal, rayDir) < 0.0 && intersect) {\n litTexel = texture2D(sourceTexture, hitPixel).rgb;\n litTexel *= pow(clamp(1.0 - dist / 200.0, 0.0, 1.0), 3.0);\n\n }\n else {\n #ifdef SPECULARCUBEMAP_ENABLED\n vec3 rayDirW = normalize(toWorldSpace * vec4(rayDir, 0.0)).rgb;\n litTexel = RGBMDecode(textureCubeLodEXT(specularCubemap, rayDirW, 0.0), 8.12).rgb * specularIntensity;\n#endif\n }\n color.rgb += ndl * litTexel * (\n F_Schlick(ndl, spec) * G_Smith(g, ndv, ndl) * vdh / (ndh * ndv + 0.001)\n );\n }\n color.rgb /= float(SAMPLE_PER_FRAME);\n#else\n #if !defined(SPECULARCUBEMAP_ENABLED)\n if (dot(hitNormal, rayDir) >= 0.0) {\n discard;\n }\n if (!intersect) {\n discard;\n }\n#endif\n float alpha = clamp(calculateAlpha(iterationCount, reflectivity, hitPixel, hitPoint, dist, rayDir), 0.0, 1.0);\n vec4 color = texture2D(sourceTexture, hitPixel);\n color.rgb *= alpha;\n\n#ifdef SPECULARCUBEMAP_ENABLED\n vec3 rayDirW = normalize(toWorldSpace * vec4(rayDir, 0.0)).rgb;\n alpha = alpha * (intersect ? 1.0 : 0.0);\n float bias = (1.0 -g) * 5.0;\n color.rgb += (1.0 - alpha)\n * RGBMDecode(textureCubeLodEXT(specularCubemap, rayDirW, bias), 8.12).rgb\n * specularIntensity;\n#endif\n\n#endif\n\n gl_FragColor = encodeHDR(color);\n}\n@end\n\n@export ecgl.ssr.blur\n\nuniform sampler2D texture;\nuniform sampler2D gBufferTexture1;\nuniform sampler2D gBufferTexture2;\nuniform mat4 projection;\nuniform float depthRange : 0.05;\n\nvarying vec2 v_Texcoord;\n\nuniform vec2 textureSize;\nuniform float blurSize : 1.0;\n\n#ifdef BLEND\n #ifdef SSAOTEX_ENABLED\nuniform sampler2D ssaoTex;\n #endif\nuniform sampler2D sourceTexture;\n#endif\n\nfloat getLinearDepth(vec2 coord)\n{\n float depth = texture2D(gBufferTexture2, coord).r * 2.0 - 1.0;\n return projection[3][2] / (depth * projection[2][3] - projection[2][2]);\n}\n\n@import clay.util.rgbm\n\n\nvoid main()\n{\n @import clay.compositor.kernel.gaussian_9\n\n vec4 centerNTexel = texture2D(gBufferTexture1, v_Texcoord);\n float g = centerNTexel.a;\n float maxBlurSize = clamp(1.0 - g, 0.0, 1.0) * blurSize;\n#ifdef VERTICAL\n vec2 off = vec2(0.0, maxBlurSize / textureSize.y);\n#else\n vec2 off = vec2(maxBlurSize / textureSize.x, 0.0);\n#endif\n\n vec2 coord = v_Texcoord;\n\n vec4 sum = vec4(0.0);\n float weightAll = 0.0;\n\n vec3 cN = centerNTexel.rgb * 2.0 - 1.0;\n float cD = getLinearDepth(v_Texcoord);\n for (int i = 0; i < 9; i++) {\n vec2 coord = clamp((float(i) - 4.0) * off + v_Texcoord, vec2(0.0), vec2(1.0));\n float w = gaussianKernel[i]\n * clamp(dot(cN, texture2D(gBufferTexture1, coord).rgb * 2.0 - 1.0), 0.0, 1.0);\n float d = getLinearDepth(coord);\n w *= (1.0 - smoothstep(abs(cD - d) / depthRange, 0.0, 1.0));\n\n weightAll += w;\n sum += decodeHDR(texture2D(texture, coord)) * w;\n }\n\n#ifdef BLEND\n float aoFactor = 1.0;\n #ifdef SSAOTEX_ENABLED\n aoFactor = texture2D(ssaoTex, v_Texcoord).r;\n #endif\n gl_FragColor = encodeHDR(\n sum / weightAll * aoFactor + decodeHDR(texture2D(sourceTexture, v_Texcoord))\n );\n#else\n gl_FragColor = encodeHDR(sum / weightAll);\n#endif\n}\n\n@end";function Ws(t){t=t||{},this._ssrPass=new vr({fragment:Xt.source("ecgl.ssr.main"),clearColor:[0,0,0,0]}),this._blurPass1=new vr({fragment:Xt.source("ecgl.ssr.blur"),clearColor:[0,0,0,0]}),this._blurPass2=new vr({fragment:Xt.source("ecgl.ssr.blur"),clearColor:[0,0,0,0]}),this._blendPass=new vr({fragment:Xt.source("clay.compositor.blend")}),this._blendPass.material.disableTexturesAll(),this._blendPass.material.enableTexture(["texture1","texture2"]),this._ssrPass.setUniform("gBufferTexture1",t.normalTexture),this._ssrPass.setUniform("gBufferTexture2",t.depthTexture),this._blurPass1.setUniform("gBufferTexture1",t.normalTexture),this._blurPass1.setUniform("gBufferTexture2",t.depthTexture),this._blurPass2.setUniform("gBufferTexture1",t.normalTexture),this._blurPass2.setUniform("gBufferTexture2",t.depthTexture),this._blurPass2.material.define("fragment","VERTICAL"),this._blurPass2.material.define("fragment","BLEND"),this._ssrTexture=new sn({type:Qe.HALF_FLOAT}),this._texture2=new sn({type:Qe.HALF_FLOAT}),this._texture3=new sn({type:Qe.HALF_FLOAT}),this._prevTexture=new sn({type:Qe.HALF_FLOAT}),this._currentTexture=new sn({type:Qe.HALF_FLOAT}),this._frameBuffer=new pi({depthBuffer:!1}),this._normalDistribution=null,this._totalSamples=256,this._samplePerFrame=4,this._ssrPass.material.define("fragment","SAMPLE_PER_FRAME",this._samplePerFrame),this._ssrPass.material.define("fragment","TOTAL_SAMPLES",this._totalSamples),this._downScale=1}Xt.import(Us),Ws.prototype.setAmbientCubemap=function(t,e){this._ssrPass.material.set("specularCubemap",t),this._ssrPass.material.set("specularIntensity",e);var n=t&&e;this._ssrPass.material[n?"enableTexture":"disableTexture"]("specularCubemap")},Ws.prototype.update=function(t,e,n,i){var r=t.getWidth(),a=t.getHeight(),o=this._ssrTexture,s=this._texture2,l=this._texture3;o.width=this._prevTexture.width=this._currentTexture.width=r/this._downScale,o.height=this._prevTexture.height=this._currentTexture.height=a/this._downScale,s.width=l.width=r,s.height=l.height=a;var u=this._frameBuffer,c=this._ssrPass,h=this._blurPass1,d=this._blurPass2,f=this._blendPass,p=new Le,g=new Le;Le.transpose(p,e.worldTransform),Le.transpose(g,e.viewMatrix),c.setUniform("sourceTexture",n),c.setUniform("projection",e.projectionMatrix.array),c.setUniform("projectionInv",e.invProjectionMatrix.array),c.setUniform("toViewSpace",p.array),c.setUniform("toWorldSpace",g.array),c.setUniform("nearZ",e.near);var m=i/this._totalSamples*this._samplePerFrame;if(c.setUniform("jitterOffset",m),c.setUniform("sampleOffset",i*this._samplePerFrame),h.setUniform("textureSize",[o.width,o.height]),d.setUniform("textureSize",[r,a]),d.setUniform("sourceTexture",n),h.setUniform("projection",e.projectionMatrix.array),d.setUniform("projection",e.projectionMatrix.array),u.attach(o),u.bind(t),c.render(t),this._physicallyCorrect&&(u.attach(this._currentTexture),f.setUniform("texture1",this._prevTexture),f.setUniform("texture2",o),f.material.set({weight1:i>=1?.95:0,weight2:i>=1?.05:1}),f.render(t)),u.attach(s),h.setUniform("texture",this._physicallyCorrect?this._currentTexture:o),h.render(t),u.attach(l),d.setUniform("texture",s),d.render(t),u.unbind(t),this._physicallyCorrect){var v=this._prevTexture;this._prevTexture=this._currentTexture,this._currentTexture=v}},Ws.prototype.getTargetTexture=function(){return this._texture3},Ws.prototype.setParameter=function(t,e){"maxIteration"===t?this._ssrPass.material.define("fragment","MAX_ITERATION",e):this._ssrPass.setUniform(t,e)},Ws.prototype.setPhysicallyCorrect=function(t){t?(this._normalDistribution||(this._normalDistribution=wr.generateNormalDistribution(64,this._totalSamples)),this._ssrPass.material.define("fragment","PHYSICALLY_CORRECT"),this._ssrPass.material.set("normalDistribution",this._normalDistribution),this._ssrPass.material.set("normalDistributionSize",[64,this._totalSamples])):this._ssrPass.material.undefine("fragment","PHYSICALLY_CORRECT"),this._physicallyCorrect=t},Ws.prototype.setSSAOTexture=function(t){var e=this._blurPass2;t?(e.material.enableTexture("ssaoTex"),e.material.set("ssaoTex",t)):e.material.disableTexture("ssaoTex")},Ws.prototype.isFinished=function(t){return!this._physicallyCorrect||t>this._totalSamples/this._samplePerFrame},Ws.prototype.dispose=function(t){this._ssrTexture.dispose(t),this._texture2.dispose(t),this._texture3.dispose(t),this._prevTexture.dispose(t),this._currentTexture.dispose(t),this._frameBuffer.dispose(t)};var Xs=Ws,Zs=[0,0,-.321585265978,-.154972575841,.458126042375,.188473391593,.842080129861,.527766490688,.147304551086,-.659453822776,-.331943915203,-.940619700594,.0479226680259,.54812163202,.701581552186,-.709825561388,-.295436780218,.940589268233,-.901489676764,.237713156085,.973570876096,-.109899459384,-.866792314779,-.451805525005,.330975007087,.800048655954,-.344275183665,.381779221166,-.386139432542,-.437418421534,-.576478634965,-.0148463392551,.385798197415,-.262426961053,-.666302061145,.682427250835,-.628010632582,-.732836215494,.10163141741,-.987658134403,.711995289051,-.320024291314,.0296005138058,.950296523438,.0130612307608,-.351024443122,-.879596633704,-.10478487883,.435712737232,.504254490347,.779203817497,.206477676721,.388264289969,-.896736162545,-.153106280781,-.629203242522,-.245517550697,.657969239148,.126830499058,.26862328493,-.634888119007,-.302301223431,.617074219636,.779817204925],qs="@export ecgl.normal.vertex\n\n@import ecgl.common.transformUniforms\n\n@import ecgl.common.uv.header\n\n@import ecgl.common.attributes\n\nvarying vec3 v_Normal;\nvarying vec3 v_WorldPosition;\n\n@import ecgl.common.normalMap.vertexHeader\n\n@import ecgl.common.vertexAnimation.header\n\nvoid main()\n{\n\n @import ecgl.common.vertexAnimation.main\n\n @import ecgl.common.uv.main\n\n v_Normal = normalize((worldInverseTranspose * vec4(normal, 0.0)).xyz);\n v_WorldPosition = (world * vec4(pos, 1.0)).xyz;\n\n @import ecgl.common.normalMap.vertexMain\n\n gl_Position = worldViewProjection * vec4(pos, 1.0);\n\n}\n\n\n@end\n\n\n@export ecgl.normal.fragment\n\n#define ROUGHNESS_CHANEL 0\n\nuniform bool useBumpMap;\nuniform bool useRoughnessMap;\nuniform bool doubleSide;\nuniform float roughness;\n\n@import ecgl.common.uv.fragmentHeader\n\nvarying vec3 v_Normal;\nvarying vec3 v_WorldPosition;\n\nuniform mat4 viewInverse : VIEWINVERSE;\n\n@import ecgl.common.normalMap.fragmentHeader\n@import ecgl.common.bumpMap.header\n\nuniform sampler2D roughnessMap;\n\nvoid main()\n{\n vec3 N = v_Normal;\n \n bool flipNormal = false;\n if (doubleSide) {\n vec3 eyePos = viewInverse[3].xyz;\n vec3 V = normalize(eyePos - v_WorldPosition);\n\n if (dot(N, V) < 0.0) {\n flipNormal = true;\n }\n }\n\n @import ecgl.common.normalMap.fragmentMain\n\n if (useBumpMap) {\n N = bumpNormal(v_WorldPosition, v_Normal, N);\n }\n\n float g = 1.0 - roughness;\n\n if (useRoughnessMap) {\n float g2 = 1.0 - texture2D(roughnessMap, v_DetailTexcoord)[ROUGHNESS_CHANEL];\n g = clamp(g2 + (g - 0.5) * 2.0, 0.0, 1.0);\n }\n\n if (flipNormal) {\n N = -N;\n }\n\n gl_FragColor.rgb = (N.xyz + 1.0) * 0.5;\n gl_FragColor.a = g;\n}\n@end";function Ys(t,e,n,i,r){var a=t.gl;e.setUniform(a,"1i",n,r),a.activeTexture(a.TEXTURE0+r),i.isRenderable()?i.bind(t):i.unbind(t)}function Ks(t,e,n,i,r){var a,o,s,l,u=t.gl;return function(r,c,h){if(!l||l.material!==r.material){var d=r.material,f=r.__program,p=d.get("roughness");null==p&&(p=1);var g=d.get("normalMap")||e,m=d.get("roughnessMap"),v=d.get("bumpMap"),y=d.get("uvRepeat"),_=d.get("uvOffset"),b=d.get("detailUvRepeat"),x=d.get("detailUvOffset"),w=!!v&&d.isTextureEnabled("bumpMap"),O=!!m&&d.isTextureEnabled("roughnessMap"),S=d.isDefined("fragment","DOUBLE_SIDED");v=v||n,m=m||i,h!==c?(c.set("normalMap",g),c.set("bumpMap",v),c.set("roughnessMap",m),c.set("useBumpMap",w),c.set("useRoughnessMap",O),c.set("doubleSide",S),null!=y&&c.set("uvRepeat",y),null!=_&&c.set("uvOffset",_),null!=b&&c.set("detailUvRepeat",b),null!=x&&c.set("detailUvOffset",x),c.set("roughness",p)):(f.setUniform(u,"1f","roughness",p),a!==g&&Ys(t,f,"normalMap",g,0),o!==v&&v&&Ys(t,f,"bumpMap",v,1),s!==m&&m&&Ys(t,f,"roughnessMap",m,2),null!=y&&f.setUniform(u,"2f","uvRepeat",y),null!=_&&f.setUniform(u,"2f","uvOffset",_),null!=b&&f.setUniform(u,"2f","detailUvRepeat",b),null!=x&&f.setUniform(u,"2f","detailUvOffset",x),f.setUniform(u,"1i","useBumpMap",+w),f.setUniform(u,"1i","useRoughnessMap",+O),f.setUniform(u,"1i","doubleSide",+S)),a=g,o=v,s=m,l=r}}}function Qs(t){t=t||{},this._depthTex=new sn({format:Qe.DEPTH_COMPONENT,type:Qe.UNSIGNED_INT}),this._normalTex=new sn({type:Qe.HALF_FLOAT}),this._framebuffer=new pi,this._framebuffer.attach(this._normalTex),this._framebuffer.attach(this._depthTex,pi.DEPTH_ATTACHMENT),this._normalMaterial=new nt({shader:new Xt(Xt.source("ecgl.normal.vertex"),Xt.source("ecgl.normal.fragment"))}),this._normalMaterial.enableTexture(["normalMap","bumpMap","roughnessMap"]),this._defaultNormalMap=ar.createBlank("#000"),this._defaultBumpMap=ar.createBlank("#000"),this._defaultRoughessMap=ar.createBlank("#000"),this._debugPass=new vr({fragment:Xt.source("clay.compositor.output")}),this._debugPass.setUniform("texture",this._normalTex),this._debugPass.material.undefine("fragment","OUTPUT_ALPHA")}Xt.import(qs),Qs.prototype.getDepthTexture=function(){return this._depthTex},Qs.prototype.getNormalTexture=function(){return this._normalTex},Qs.prototype.update=function(t,e,n){var i=t.getWidth(),r=t.getHeight(),a=this._depthTex,o=this._normalTex,s=this._normalMaterial;a.width=i,a.height=r,o.width=i,o.height=r;var l=e.getRenderList(n).opaque;this._framebuffer.bind(t),t.gl.clearColor(0,0,0,0),t.gl.clear(t.gl.COLOR_BUFFER_BIT|t.gl.DEPTH_BUFFER_BIT),t.gl.disable(t.gl.BLEND),t.renderPass(l,n,{getMaterial:function(){return s},ifRender:function(t){return t.renderNormal},beforeRender:Ks(t,this._defaultNormalMap,this._defaultBumpMap,this._defaultRoughessMap,this._normalMaterial),sort:t.opaqueSortCompare}),this._framebuffer.unbind(t)},Qs.prototype.renderDebug=function(t){this._debugPass.render(t)},Qs.prototype.dispose=function(t){this._depthTex.dispose(t),this._normalTex.dispose(t)};var Js=Qs;function $s(t){t=t||{},this._edgePass=new vr({fragment:Xt.source("ecgl.edge")}),this._edgePass.setUniform("normalTexture",t.normalTexture),this._edgePass.setUniform("depthTexture",t.depthTexture),this._targetTexture=new sn({type:Qe.HALF_FLOAT}),this._frameBuffer=new pi,this._frameBuffer.attach(this._targetTexture)}$s.prototype.update=function(t,e,n,i){var r=t.getWidth(),a=t.getHeight(),o=this._targetTexture;o.width=r,o.height=a;var s=this._frameBuffer;s.bind(t),this._edgePass.setUniform("projectionInv",e.invProjectionMatrix.array),this._edgePass.setUniform("textureSize",[r,a]),this._edgePass.setUniform("texture",n),this._edgePass.render(t),s.unbind(t)},$s.prototype.getTargetTexture=function(){return this._targetTexture},$s.prototype.setParameter=function(t,e){this._edgePass.setUniform(t,e)},$s.prototype.dispose=function(t){this._targetTexture.dispose(t),this._frameBuffer.dispose(t)};var tl=$s,el={type:"compositor",nodes:[{name:"source",type:"texture",outputs:{color:{}}},{name:"source_half",shader:"#source(clay.compositor.downsample)",inputs:{texture:"source"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 2)",height:"expr(height * 1.0 / 2)",type:"HALF_FLOAT"}}},parameters:{textureSize:"expr( [width * 1.0, height * 1.0] )"}},{name:"bright",shader:"#source(clay.compositor.bright)",inputs:{texture:"source_half"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 2)",height:"expr(height * 1.0 / 2)",type:"HALF_FLOAT"}}},parameters:{threshold:2,scale:4,textureSize:"expr([width * 1.0 / 2, height / 2])"}},{name:"bright_downsample_4",shader:"#source(clay.compositor.downsample)",inputs:{texture:"bright"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 4)",height:"expr(height * 1.0 / 4)",type:"HALF_FLOAT"}}},parameters:{textureSize:"expr( [width * 1.0 / 2, height / 2] )"}},{name:"bright_downsample_8",shader:"#source(clay.compositor.downsample)",inputs:{texture:"bright_downsample_4"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 8)",height:"expr(height * 1.0 / 8)",type:"HALF_FLOAT"}}},parameters:{textureSize:"expr( [width * 1.0 / 4, height / 4] )"}},{name:"bright_downsample_16",shader:"#source(clay.compositor.downsample)",inputs:{texture:"bright_downsample_8"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 16)",height:"expr(height * 1.0 / 16)",type:"HALF_FLOAT"}}},parameters:{textureSize:"expr( [width * 1.0 / 8, height / 8] )"}},{name:"bright_downsample_32",shader:"#source(clay.compositor.downsample)",inputs:{texture:"bright_downsample_16"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 32)",height:"expr(height * 1.0 / 32)",type:"HALF_FLOAT"}}},parameters:{textureSize:"expr( [width * 1.0 / 16, height / 16] )"}},{name:"bright_upsample_16_blur_h",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_downsample_32"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 16)",height:"expr(height * 1.0 / 16)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:0,textureSize:"expr( [width * 1.0 / 32, height / 32] )"}},{name:"bright_upsample_16_blur_v",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_upsample_16_blur_h"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 16)",height:"expr(height * 1.0 / 16)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:1,textureSize:"expr( [width * 1.0 / 16, height * 1.0 / 16] )"}},{name:"bright_upsample_8_blur_h",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_downsample_16"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 8)",height:"expr(height * 1.0 / 8)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:0,textureSize:"expr( [width * 1.0 / 16, height * 1.0 / 16] )"}},{name:"bright_upsample_8_blur_v",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_upsample_8_blur_h"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 8)",height:"expr(height * 1.0 / 8)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:1,textureSize:"expr( [width * 1.0 / 8, height * 1.0 / 8] )"}},{name:"bright_upsample_8_blend",shader:"#source(clay.compositor.blend)",inputs:{texture1:"bright_upsample_8_blur_v",texture2:"bright_upsample_16_blur_v"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 8)",height:"expr(height * 1.0 / 8)",type:"HALF_FLOAT"}}},parameters:{weight1:.3,weight2:.7}},{name:"bright_upsample_4_blur_h",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_downsample_8"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 4)",height:"expr(height * 1.0 / 4)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:0,textureSize:"expr( [width * 1.0 / 8, height * 1.0 / 8] )"}},{name:"bright_upsample_4_blur_v",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_upsample_4_blur_h"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 4)",height:"expr(height * 1.0 / 4)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:1,textureSize:"expr( [width * 1.0 / 4, height * 1.0 / 4] )"}},{name:"bright_upsample_4_blend",shader:"#source(clay.compositor.blend)",inputs:{texture1:"bright_upsample_4_blur_v",texture2:"bright_upsample_8_blend"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 4)",height:"expr(height * 1.0 / 4)",type:"HALF_FLOAT"}}},parameters:{weight1:.3,weight2:.7}},{name:"bright_upsample_2_blur_h",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_downsample_4"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 2)",height:"expr(height * 1.0 / 2)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:0,textureSize:"expr( [width * 1.0 / 4, height * 1.0 / 4] )"}},{name:"bright_upsample_2_blur_v",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_upsample_2_blur_h"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 2)",height:"expr(height * 1.0 / 2)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:1,textureSize:"expr( [width * 1.0 / 2, height * 1.0 / 2] )"}},{name:"bright_upsample_2_blend",shader:"#source(clay.compositor.blend)",inputs:{texture1:"bright_upsample_2_blur_v",texture2:"bright_upsample_4_blend"},outputs:{color:{parameters:{width:"expr(width * 1.0 / 2)",height:"expr(height * 1.0 / 2)",type:"HALF_FLOAT"}}},parameters:{weight1:.3,weight2:.7}},{name:"bright_upsample_full_blur_h",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright"},outputs:{color:{parameters:{width:"expr(width * 1.0)",height:"expr(height * 1.0)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:0,textureSize:"expr( [width * 1.0 / 2, height * 1.0 / 2] )"}},{name:"bright_upsample_full_blur_v",shader:"#source(clay.compositor.gaussian_blur)",inputs:{texture:"bright_upsample_full_blur_h"},outputs:{color:{parameters:{width:"expr(width * 1.0)",height:"expr(height * 1.0)",type:"HALF_FLOAT"}}},parameters:{blurSize:1,blurDir:1,textureSize:"expr( [width * 1.0, height * 1.0] )"}},{name:"bloom_composite",shader:"#source(clay.compositor.blend)",inputs:{texture1:"bright_upsample_full_blur_v",texture2:"bright_upsample_2_blend"},outputs:{color:{parameters:{width:"expr(width * 1.0)",height:"expr(height * 1.0)",type:"HALF_FLOAT"}}},parameters:{weight1:.3,weight2:.7}},{name:"coc",shader:"#source(ecgl.dof.coc)",outputs:{color:{parameters:{minFilter:"NEAREST",magFilter:"NEAREST",width:"expr(width * 1.0)",height:"expr(height * 1.0)"}}},parameters:{focalDist:50,focalRange:30}},{name:"dof_far_blur",shader:"#source(ecgl.dof.diskBlur)",inputs:{texture:"source",coc:"coc"},outputs:{color:{parameters:{width:"expr(width * 1.0)",height:"expr(height * 1.0)",type:"HALF_FLOAT"}}},parameters:{textureSize:"expr( [width * 1.0, height * 1.0] )"}},{name:"dof_near_blur",shader:"#source(ecgl.dof.diskBlur)",inputs:{texture:"source",coc:"coc"},outputs:{color:{parameters:{width:"expr(width * 1.0)",height:"expr(height * 1.0)",type:"HALF_FLOAT"}}},parameters:{textureSize:"expr( [width * 1.0, height * 1.0] )"},defines:{BLUR_NEARFIELD:null}},{name:"dof_coc_blur",shader:"#source(ecgl.dof.diskBlur)",inputs:{texture:"coc"},outputs:{color:{parameters:{minFilter:"NEAREST",magFilter:"NEAREST",width:"expr(width * 1.0)",height:"expr(height * 1.0)"}}},parameters:{textureSize:"expr( [width * 1.0, height * 1.0] )"},defines:{BLUR_COC:null}},{name:"dof_composite",shader:"#source(ecgl.dof.composite)",inputs:{original:"source",blurred:"dof_far_blur",nearfield:"dof_near_blur",coc:"coc",nearcoc:"dof_coc_blur"},outputs:{color:{parameters:{width:"expr(width * 1.0)",height:"expr(height * 1.0)",type:"HALF_FLOAT"}}}},{name:"composite",shader:"#source(clay.compositor.hdr.composite)",inputs:{texture:"source",bloom:"bloom_composite"},outputs:{color:{parameters:{width:"expr(width * 1.0)",height:"expr(height * 1.0)"}}},defines:{}},{name:"FXAA",shader:"#source(clay.compositor.fxaa)",inputs:{texture:"composite"}}]},nl="@export ecgl.dof.coc\n\nuniform sampler2D depth;\n\nuniform float zNear: 0.1;\nuniform float zFar: 2000;\n\nuniform float focalDistance: 3;\nuniform float focalRange: 1;\nuniform float focalLength: 30;\nuniform float fstop: 2.8;\n\nvarying vec2 v_Texcoord;\n\n@import clay.util.encode_float\n\nvoid main()\n{\n float z = texture2D(depth, v_Texcoord).r * 2.0 - 1.0;\n\n float dist = 2.0 * zNear * zFar / (zFar + zNear - z * (zFar - zNear));\n\n float aperture = focalLength / fstop;\n\n float coc;\n\n float uppper = focalDistance + focalRange;\n float lower = focalDistance - focalRange;\n if (dist <= uppper && dist >= lower) {\n coc = 0.5;\n }\n else {\n float focalAdjusted = dist > uppper ? uppper : lower;\n\n coc = abs(aperture * (focalLength * (dist - focalAdjusted)) / (dist * (focalAdjusted - focalLength)));\n coc = clamp(coc, 0.0, 2.0) / 2.00001;\n\n if (dist < lower) {\n coc = -coc;\n }\n coc = coc * 0.5 + 0.5;\n }\n\n gl_FragColor = encodeFloat(coc);\n}\n@end\n\n\n@export ecgl.dof.composite\n\n#define DEBUG 0\n\nuniform sampler2D original;\nuniform sampler2D blurred;\nuniform sampler2D nearfield;\nuniform sampler2D coc;\nuniform sampler2D nearcoc;\nvarying vec2 v_Texcoord;\n\n@import clay.util.rgbm\n@import clay.util.float\n\nvoid main()\n{\n vec4 blurredColor = texture2D(blurred, v_Texcoord);\n vec4 originalColor = texture2D(original, v_Texcoord);\n\n float fCoc = decodeFloat(texture2D(coc, v_Texcoord));\n\n fCoc = abs(fCoc * 2.0 - 1.0);\n\n float weight = smoothstep(0.0, 1.0, fCoc);\n \n#ifdef NEARFIELD_ENABLED\n vec4 nearfieldColor = texture2D(nearfield, v_Texcoord);\n float fNearCoc = decodeFloat(texture2D(nearcoc, v_Texcoord));\n fNearCoc = abs(fNearCoc * 2.0 - 1.0);\n\n gl_FragColor = encodeHDR(\n mix(\n nearfieldColor, mix(originalColor, blurredColor, weight),\n pow(1.0 - fNearCoc, 4.0)\n )\n );\n#else\n gl_FragColor = encodeHDR(mix(originalColor, blurredColor, weight));\n#endif\n\n}\n\n@end\n\n\n\n@export ecgl.dof.diskBlur\n\n#define POISSON_KERNEL_SIZE 16;\n\nuniform sampler2D texture;\nuniform sampler2D coc;\nvarying vec2 v_Texcoord;\n\nuniform float blurRadius : 10.0;\nuniform vec2 textureSize : [512.0, 512.0];\n\nuniform vec2 poissonKernel[POISSON_KERNEL_SIZE];\n\nuniform float percent;\n\nfloat nrand(const in vec2 n) {\n return fract(sin(dot(n.xy ,vec2(12.9898,78.233))) * 43758.5453);\n}\n\n@import clay.util.rgbm\n@import clay.util.float\n\n\nvoid main()\n{\n vec2 offset = blurRadius / textureSize;\n\n float rnd = 6.28318 * nrand(v_Texcoord + 0.07 * percent );\n float cosa = cos(rnd);\n float sina = sin(rnd);\n vec4 basis = vec4(cosa, -sina, sina, cosa);\n\n#if !defined(BLUR_NEARFIELD) && !defined(BLUR_COC)\n offset *= abs(decodeFloat(texture2D(coc, v_Texcoord)) * 2.0 - 1.0);\n#endif\n\n#ifdef BLUR_COC\n float cocSum = 0.0;\n#else\n vec4 color = vec4(0.0);\n#endif\n\n\n float weightSum = 0.0;\n\n for (int i = 0; i < POISSON_KERNEL_SIZE; i++) {\n vec2 ofs = poissonKernel[i];\n\n ofs = vec2(dot(ofs, basis.xy), dot(ofs, basis.zw));\n\n vec2 uv = v_Texcoord + ofs * offset;\n vec4 texel = texture2D(texture, uv);\n\n float w = 1.0;\n#ifdef BLUR_COC\n float fCoc = decodeFloat(texel) * 2.0 - 1.0;\n cocSum += clamp(fCoc, -1.0, 0.0) * w;\n#else\n texel = texel;\n #if !defined(BLUR_NEARFIELD)\n float fCoc = decodeFloat(texture2D(coc, uv)) * 2.0 - 1.0;\n w *= abs(fCoc);\n #endif\n texel.rgb *= texel.a;\n color += texel * w;\n#endif\n\n weightSum += w;\n }\n\n#ifdef BLUR_COC\n gl_FragColor = encodeFloat(clamp(cocSum / weightSum, -1.0, 0.0) * 0.5 + 0.5);\n#else\n color /= weightSum;\n color.rgb /= (color.a + 0.0001);\n gl_FragColor = color;\n#endif\n}\n\n@end",il="@export ecgl.edge\n\nuniform sampler2D texture;\n\nuniform sampler2D normalTexture;\nuniform sampler2D depthTexture;\n\nuniform mat4 projectionInv;\n\nuniform vec2 textureSize;\n\nuniform vec4 edgeColor: [0,0,0,0.8];\n\nvarying vec2 v_Texcoord;\n\nvec3 packColor(vec2 coord) {\n float z = texture2D(depthTexture, coord).r * 2.0 - 1.0;\n vec4 p = vec4(v_Texcoord * 2.0 - 1.0, z, 1.0);\n vec4 p4 = projectionInv * p;\n\n return vec3(\n texture2D(normalTexture, coord).rg,\n -p4.z / p4.w / 5.0\n );\n}\n\nvoid main() {\n vec2 cc = v_Texcoord;\n vec3 center = packColor(cc);\n\n float size = clamp(1.0 - (center.z - 10.0) / 100.0, 0.0, 1.0) * 0.5;\n float dx = size / textureSize.x;\n float dy = size / textureSize.y;\n\n vec2 coord;\n vec3 topLeft = packColor(cc+vec2(-dx, -dy));\n vec3 top = packColor(cc+vec2(0.0, -dy));\n vec3 topRight = packColor(cc+vec2(dx, -dy));\n vec3 left = packColor(cc+vec2(-dx, 0.0));\n vec3 right = packColor(cc+vec2(dx, 0.0));\n vec3 bottomLeft = packColor(cc+vec2(-dx, dy));\n vec3 bottom = packColor(cc+vec2(0.0, dy));\n vec3 bottomRight = packColor(cc+vec2(dx, dy));\n\n vec3 v = -topLeft-2.0*top-topRight+bottomLeft+2.0*bottom+bottomRight;\n vec3 h = -bottomLeft-2.0*left-topLeft+bottomRight+2.0*right+topRight;\n\n float edge = sqrt(dot(h, h) + dot(v, v));\n\n edge = smoothstep(0.8, 1.0, edge);\n\n gl_FragColor = mix(texture2D(texture, v_Texcoord), vec4(edgeColor.rgb, 1.0), edgeColor.a * edge);\n}\n@end";function rl(t,e){return{color:{parameters:{width:t,height:e}}}}Xt["import"](hs),Xt["import"](fs),Xt["import"](gs),Xt["import"](ms),Xt["import"](vs),Xt["import"](ys),Xt["import"](_s),Xt["import"](xs),Xt["import"](ws),Xt["import"](nl),Xt["import"](il);var al=["composite","FXAA"];function ol(){this._width,this._height,this._dpr,this._sourceTexture=new sn({type:Qe.HALF_FLOAT}),this._depthTexture=new sn({format:Qe.DEPTH_COMPONENT,type:Qe.UNSIGNED_INT}),this._framebuffer=new pi,this._framebuffer.attach(this._sourceTexture),this._framebuffer.attach(this._depthTexture,pi.DEPTH_ATTACHMENT),this._normalPass=new Js,this._compositor=Ns(el);var t=this._compositor.getNodeByName("source");t.texture=this._sourceTexture;var e=this._compositor.getNodeByName("coc");this._sourceNode=t,this._cocNode=e,this._compositeNode=this._compositor.getNodeByName("composite"),this._fxaaNode=this._compositor.getNodeByName("FXAA"),this._dofBlurNodes=["dof_far_blur","dof_near_blur","dof_coc_blur"].map((function(t){return this._compositor.getNodeByName(t)}),this),this._dofBlurKernel=0,this._dofBlurKernelSize=new Float32Array(0),this._finalNodesChain=al.map((function(t){return this._compositor.getNodeByName(t)}),this);var n={normalTexture:this._normalPass.getNormalTexture(),depthTexture:this._normalPass.getDepthTexture()};this._ssaoPass=new Hs(n),this._ssrPass=new Xs(n),this._edgePass=new tl(n)}ol.prototype.resize=function(t,e,n){n=n||1;t*=n,e*=n;var i=this._sourceTexture,r=this._depthTexture;i.width=t,i.height=e,r.width=t,r.height=e;var a={getWidth:function(){return t},getHeight:function(){return e},getDevicePixelRatio:function(){return n}};function o(t,e){if("function"===typeof t[e]){var n=t[e].__original||t[e];t[e]=function(t){return n.call(this,a)},t[e].__original=n}}this._compositor.nodes.forEach((function(t){for(var e in t.outputs){var n=t.outputs[e].parameters;n&&(o(n,"width"),o(n,"height"))}for(var i in t.parameters)o(t.parameters,i)})),this._width=t,this._height=e,this._dpr=n},ol.prototype.getWidth=function(){return this._width},ol.prototype.getHeight=function(){return this._height},ol.prototype._ifRenderNormalPass=function(){return this._enableSSAO||this._enableEdge||this._enableSSR},ol.prototype._getPrevNode=function(t){var e=al.indexOf(t.name)-1,n=this._finalNodesChain[e];while(n&&!this._compositor.getNodeByName(n.name))e-=1,n=this._finalNodesChain[e];return n},ol.prototype._getNextNode=function(t){var e=al.indexOf(t.name)+1,n=this._finalNodesChain[e];while(n&&!this._compositor.getNodeByName(n.name))e+=1,n=this._finalNodesChain[e];return n},ol.prototype._addChainNode=function(t){var e=this._getPrevNode(t),n=this._getNextNode(t);e&&(t.inputs.texture=e.name,n?(t.outputs=rl(this.getWidth.bind(this),this.getHeight.bind(this)),n.inputs.texture=t.name):t.outputs=null,this._compositor.addNode(t))},ol.prototype._removeChainNode=function(t){var e=this._getPrevNode(t),n=this._getNextNode(t);e&&(n?(e.outputs=rl(this.getWidth.bind(this),this.getHeight.bind(this)),n.inputs.texture=e.name):e.outputs=null,this._compositor.removeNode(t))},ol.prototype.updateNormal=function(t,e,n,i){this._ifRenderNormalPass()&&this._normalPass.update(t,e,n)},ol.prototype.updateSSAO=function(t,e,n,i){this._ssaoPass.update(t,n,i)},ol.prototype.enableSSAO=function(){this._enableSSAO=!0},ol.prototype.disableSSAO=function(){this._enableSSAO=!1},ol.prototype.enableSSR=function(){this._enableSSR=!0},ol.prototype.disableSSR=function(){this._enableSSR=!1},ol.prototype.getSSAOTexture=function(){return this._ssaoPass.getTargetTexture()},ol.prototype.getSourceFrameBuffer=function(){return this._framebuffer},ol.prototype.getSourceTexture=function(){return this._sourceTexture},ol.prototype.disableFXAA=function(){this._removeChainNode(this._fxaaNode)},ol.prototype.enableFXAA=function(){this._addChainNode(this._fxaaNode)},ol.prototype.enableBloom=function(){this._compositeNode.inputs.bloom="bloom_composite",this._compositor.dirty()},ol.prototype.disableBloom=function(){this._compositeNode.inputs.bloom=null,this._compositor.dirty()},ol.prototype.enableDOF=function(){this._compositeNode.inputs.texture="dof_composite",this._compositor.dirty()},ol.prototype.disableDOF=function(){this._compositeNode.inputs.texture="source",this._compositor.dirty()},ol.prototype.enableColorCorrection=function(){this._compositeNode.define("COLOR_CORRECTION"),this._enableColorCorrection=!0},ol.prototype.disableColorCorrection=function(){this._compositeNode.undefine("COLOR_CORRECTION"),this._enableColorCorrection=!1},ol.prototype.enableEdge=function(){this._enableEdge=!0},ol.prototype.disableEdge=function(){this._enableEdge=!1},ol.prototype.setBloomIntensity=function(t){this._compositeNode.setParameter("bloomIntensity",t)},ol.prototype.setSSAOParameter=function(t,e){switch(t){case"quality":var n={low:6,medium:12,high:32,ultra:62}[e]||12;this._ssaoPass.setParameter("kernelSize",n);break;case"radius":this._ssaoPass.setParameter(t,e),this._ssaoPass.setParameter("bias",e/200);break;case"intensity":this._ssaoPass.setParameter(t,e);break;default:0}},ol.prototype.setDOFParameter=function(t,e){switch(t){case"focalDistance":case"focalRange":case"fstop":this._cocNode.setParameter(t,e);break;case"blurRadius":for(var n=0;n=this._haltonSequence.length},render:function(t,e,n){var i=this._blendPass;0===this._frame?(i.setUniform("weight1",0),i.setUniform("weight2",1)):(i.setUniform("weight1",.9),i.setUniform("weight2",.1)),i.setUniform("texture1",this._prevFrameTex),i.setUniform("texture2",e||this._sourceTex),this._blendFb.attach(this._outputTex),this._blendFb.bind(t),i.render(t),this._blendFb.unbind(t),n||(this._outputPass.setUniform("texture",this._outputTex),this._outputPass.render(t));var r=this._prevFrameTex;this._prevFrameTex=this._outputTex,this._outputTex=r,this._frame++},dispose:function(t){this._sourceFb.dispose(t),this._blendFb.dispose(t),this._prevFrameTex.dispose(t),this._outputTex.dispose(t),this._sourceTex.dispose(t),this._outputPass.dispose(t),this._blendPass.dispose(t)}};var ul=ll;function cl(t){t=t||"perspective",this.layer=null,this.scene=new qn,this.rootNode=this.scene,this.viewport={x:0,y:0,width:0,height:0},this.setProjection(t),this._compositor=new sl,this._temporalSS=new ul,this._shadowMapPass=new Qo;for(var e=[],n=0,i=0;i<30;i++){for(var r=[],a=0;a<6;a++)r.push(4*ks(n,2)-2),r.push(4*ks(n,3)-2),n++;e.push(r)}this._pcfKernels=e,this.scene.on("beforerender",(function(t,e,n){this.needsTemporalSS()&&this._temporalSS.jitterProjection(t,n)}),this)}cl.prototype.setProjection=function(t){var e=this.camera;e&&e.update(),"perspective"===t?this.camera instanceof ni||(this.camera=new ni,e&&this.camera.setLocalTransform(e.localTransform)):this.camera instanceof hr||(this.camera=new hr,e&&this.camera.setLocalTransform(e.localTransform)),this.camera.near=.1,this.camera.far=2e3},cl.prototype.setViewport=function(t,e,n,i,r){this.camera instanceof ni&&(this.camera.aspect=n/i),r=r||1,this.viewport.x=t,this.viewport.y=e,this.viewport.width=n,this.viewport.height=i,this.viewport.devicePixelRatio=r,this._compositor.resize(n*r,i*r),this._temporalSS.resize(n*r,i*r)},cl.prototype.containPoint=function(t,e){var n=this.viewport,i=this.layer.renderer.getHeight();return e=i-e,t>=n.x&&e>=n.y&&t<=n.x+n.width&&e<=n.y+n.height};var hl=new ct;cl.prototype.castRay=function(t,e,n){var i=this.layer.renderer,r=i.viewport;return i.viewport=this.viewport,i.screenToNDC(t,e,hl),this.camera.castRay(hl,n),i.viewport=r,n},cl.prototype.prepareRender=function(){this.scene.update(),this.camera.update(),this.scene.updateLights();var t=this.scene.updateRenderList(this.camera);this._needsSortProgressively=!1;for(var e=0;e30},cl.prototype._doRender=function(t,e,n){var i=this.scene,r=this.camera;n=n||0,this._updateTransparent(t,i,r,n),e||(this._shadowMapPass.kernelPCF=this._pcfKernels[0],this._shadowMapPass.render(t,i,r,!0)),this._updateShadowPCFKernel(n);var a=t.clearColor;if(t.gl.clearColor(a[0],a[1],a[2],a[3]),this._enablePostEffect&&(this.needsTemporalSS()&&this._temporalSS.jitterProjection(t,r),this._compositor.updateNormal(t,i,r,this._temporalSS.getFrame())),this._updateSSAO(t,i,r,this._temporalSS.getFrame()),this._enablePostEffect){var o=this._compositor.getSourceFrameBuffer();o.bind(t),t.gl.clear(t.gl.DEPTH_BUFFER_BIT|t.gl.COLOR_BUFFER_BIT),t.render(i,r,!0,!0),o.unbind(t),this.needsTemporalSS()&&e?(this._compositor.composite(t,i,r,this._temporalSS.getSourceFrameBuffer(),this._temporalSS.getFrame()),t.setViewport(this.viewport),this._temporalSS.render(t)):(t.setViewport(this.viewport),this._compositor.composite(t,i,r,null,0))}else if(this.needsTemporalSS()&&e){o=this._temporalSS.getSourceFrameBuffer();o.bind(t),t.saveClear(),t.clearBit=t.gl.DEPTH_BUFFER_BIT|t.gl.COLOR_BUFFER_BIT,t.render(i,r,!0,!0),t.restoreClear(),o.unbind(t),t.setViewport(this.viewport),this._temporalSS.render(t)}else t.setViewport(this.viewport),t.render(i,r,!0,!0)},cl.prototype._updateTransparent=function(t,e,n,i){for(var r=new ye,a=new Le,o=n.getWorldPosition(),s=e.getRenderList(n).transparent,l=0;lthis.camera.far||t80*n){i=a=t[0],r=o=t[1];for(var p=n;pa&&(a=s),l>o&&(o=l);u=Math.max(a-i,o-r)}return Bl(d,f,n,i,r,u),f}function Rl(t,e,n,i,r){var a,o;if(r===uu(t,e,n,i)>0)for(a=e;a=e;a-=i)o=ou(a,t[a],t[a+1],o);return o&&tu(o,o.next)&&(su(o),o=o.next),o}function kl(t,e){if(!t)return t;e||(e=t);var n,i=t;do{if(n=!1,i.steiner||!tu(i,i.next)&&0!==$l(i.prev,i,i.next))i=i.next;else{if(su(i),i=e=i.prev,i===i.next)return null;n=!0}}while(n||i!==e);return e}function Bl(t,e,n,i,r,a,o){if(t){!o&&a&&Zl(t,i,r,a);var s,l,u=t;while(t.prev!==t.next)if(s=t.prev,l=t.next,a?Vl(t,i,r,a):zl(t))e.push(s.i/n),e.push(t.i/n),e.push(l.i/n),su(t),t=l.next,u=l.next;else if(t=l,t===u){o?1===o?(t=Fl(t,e,n),Bl(t,e,n,i,r,a,2)):2===o&&Gl(t,e,n,i,r,a):Bl(kl(t),e,n,i,r,a,1);break}}}function zl(t){var e=t.prev,n=t,i=t.next;if($l(e,n,i)>=0)return!1;var r=t.next.next;while(r!==t.prev){if(Ql(e.x,e.y,n.x,n.y,i.x,i.y,r.x,r.y)&&$l(r.prev,r,r.next)>=0)return!1;r=r.next}return!0}function Vl(t,e,n,i){var r=t.prev,a=t,o=t.next;if($l(r,a,o)>=0)return!1;var s=r.xa.x?r.x>o.x?r.x:o.x:a.x>o.x?a.x:o.x,c=r.y>a.y?r.y>o.y?r.y:o.y:a.y>o.y?a.y:o.y,h=Yl(s,l,e,n,i),d=Yl(u,c,e,n,i),f=t.nextZ;while(f&&f.z<=d){if(f!==t.prev&&f!==t.next&&Ql(r.x,r.y,a.x,a.y,o.x,o.y,f.x,f.y)&&$l(f.prev,f,f.next)>=0)return!1;f=f.nextZ}f=t.prevZ;while(f&&f.z>=h){if(f!==t.prev&&f!==t.next&&Ql(r.x,r.y,a.x,a.y,o.x,o.y,f.x,f.y)&&$l(f.prev,f,f.next)>=0)return!1;f=f.prevZ}return!0}function Fl(t,e,n){var i=t;do{var r=i.prev,a=i.next.next;!tu(r,a)&&eu(r,i,i.next,a)&&iu(r,a)&&iu(a,r)&&(e.push(r.i/n),e.push(i.i/n),e.push(a.i/n),su(i),su(i.next),i=t=a),i=i.next}while(i!==t);return i}function Gl(t,e,n,i,r,a){var o=t;do{var s=o.next.next;while(s!==o.prev){if(o.i!==s.i&&Jl(o,s)){var l=au(o,s);return o=kl(o,o.next),l=kl(l,l.next),Bl(o,e,n,i,r,a),void Bl(l,e,n,i,r,a)}s=s.next}o=o.next}while(o!==t)}function Hl(t,e,n,i){var r,a,o,s,l,u=[];for(r=0,a=e.length;r=i.next.y&&i.next.y!==i.y){var s=i.x+(a-i.y)*(i.next.x-i.x)/(i.next.y-i.y);if(s<=r&&s>o){if(o=s,s===r){if(a===i.y)return i;if(a===i.next.y)return i.next}n=i.x=i.x&&i.x>=c&&r!==i.x&&Ql(an.x)&&iu(i,t)&&(n=i,d=l)),i=i.next;return n}function Zl(t,e,n,i){var r=t;do{null===r.z&&(r.z=Yl(r.x,r.y,e,n,i)),r.prevZ=r.prev,r.nextZ=r.next,r=r.next}while(r!==t);r.prevZ.nextZ=null,r.prevZ=null,ql(r)}function ql(t){var e,n,i,r,a,o,s,l,u=1;do{n=t,t=null,a=null,o=0;while(n){for(o++,i=n,s=0,e=0;e0||l>0&&i)0!==s&&(0===l||!i||n.z<=i.z)?(r=n,n=n.nextZ,s--):(r=i,i=i.nextZ,l--),a?a.nextZ=r:t=r,r.prevZ=a,a=r;n=i}a.nextZ=null,u*=2}while(o>1);return t}function Yl(t,e,n,i,r){return t=32767*(t-n)/r,e=32767*(e-i)/r,t=16711935&(t|t<<8),t=252645135&(t|t<<4),t=858993459&(t|t<<2),t=1431655765&(t|t<<1),e=16711935&(e|e<<8),e=252645135&(e|e<<4),e=858993459&(e|e<<2),e=1431655765&(e|e<<1),t|e<<1}function Kl(t){var e=t,n=t;do{e.x=0&&(t-o)*(i-s)-(n-o)*(e-s)>=0&&(n-o)*(a-s)-(r-o)*(i-s)>=0}function Jl(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!nu(t,e)&&iu(t,e)&&iu(e,t)&&ru(t,e)}function $l(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function tu(t,e){return t.x===e.x&&t.y===e.y}function eu(t,e,n,i){return!!(tu(t,e)&&tu(n,i)||tu(t,i)&&tu(n,e))||$l(t,e,n)>0!==$l(t,e,i)>0&&$l(n,i,t)>0!==$l(n,i,e)>0}function nu(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&eu(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}function iu(t,e){return $l(t.prev,t,t.next)<0?$l(t,e,t.next)>=0&&$l(t,t.prev,e)>=0:$l(t,e,t.prev)<0||$l(t,t.next,e)<0}function ru(t,e){var n=t,i=!1,r=(t.x+e.x)/2,a=(t.y+e.y)/2;do{n.y>a!==n.next.y>a&&n.next.y!==n.y&&r<(n.next.x-n.x)*(a-n.y)/(n.next.y-n.y)+n.x&&(i=!i),n=n.next}while(n!==t);return i}function au(t,e){var n=new lu(t.i,t.x,t.y),i=new lu(e.i,e.x,e.y),r=t.next,a=e.prev;return t.next=e,e.prev=t,n.next=r,r.prev=n,i.next=n,n.prev=i,a.next=i,i.prev=a,i}function ou(t,e,n,i){var r=new lu(t,e,n);return i?(r.next=i.next,r.prev=i,i.next.prev=r,i.next=r):(r.prev=r,r.next=r),r}function su(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function lu(t,e,n){this.i=t,this.x=e,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function uu(t,e,n,i){for(var r=0,a=e,o=n-i;al&&s.push({pivot:Math.floor((u+l)/2),left:l,right:u});l=a[o].pivot+1,u=a[o].right;u>l&&s.push({pivot:Math.floor((u+l)/2),left:l,right:u})}a=this._parts=s}else for(o=0;o=2e4},doSortTriangles:function(t,e){var n=this.indices;if(0===e){var i=this.attributes.position;t=t.array;this._triangleZList&&this._triangleZList.length===this.triangleCount||(this._triangleZList=new Float32Array(this.triangleCount),this._sortedTriangleIndices=new Uint32Array(this.triangleCount),this._indicesTmp=new n.constructor(n.length),this._triangleZListTmp=new Float32Array(this.triangleCount));for(var r,a=0,o=0;o0,n={},i=0;i65535?new Uint32Array(3*o):new Uint16Array(3*o),d.material.shader!==e&&d.material.attachShader(e,!0),Ta.setMaterialFromModel(e.__shading,d.material,t,n),s>0&&(this._linesMesh.geometry.resetOffset(),this._linesMesh.geometry.setVertexCount(s),this._linesMesh.geometry.setTriangleCount(l)),this._dataIndexOfVertex=new Uint32Array(a),this._vertexRangeOfDataIndex=new Uint32Array(2*(r-i))},_updateRegionMesh:function(t,e,n,i){for(var r=t.getData(),a=0,o=0,s=!1,l=this._polygonMesh,u=this._linesMesh,c=n;c0;w&&(x*=e.getDevicePixelRatio(),this._updateLinesGeometry(u.geometry,t,c,y,x,t.coordinateSystem.transform)),u.invisible=!w,u.material.set({color:m})}l=this._polygonMesh;l.material.transparent=s,l.material.depthMask=!s,l.geometry.updateBoundingBox(),l.frontFace=this.extrudeY?Ta.Mesh.CCW:Ta.Mesh.CW,l.material.get("normalMap")&&l.geometry.generateTangents(),l.seriesIndex=t.seriesIndex,l.on("mousemove",this._onmousemove,this),l.on("mouseout",this._onmouseout,this)},_updateDebugWireframe:function(t){var e=t.getModel("debug.wireframe");if(e.get("show")){var n=Ta.parseColor(e.get("lineStyle.color")||"rgba(0,0,0,0.5)"),i=Pr.firstNotNull(e.get("lineStyle.width"),1),r=this._polygonMesh;r.geometry.generateBarycentric(),r.material.define("both","WIREFRAME_TRIANGLE"),r.material.set("wireframeLineColor",n),r.material.set("wireframeLineWidth",i)}},_onmousemove:function(t){var e=this._dataIndexOfVertex[t.triangle[0]];null==e&&(e=-1),e!==this._lastHoverDataIndex&&(this.downplay(this._lastHoverDataIndex),this.highlight(e),this._labelsBuilder.updateLabels([e])),this._lastHoverDataIndex=e,this._polygonMesh.dataIndex=e},_onmouseout:function(t){t.target&&(this.downplay(this._lastHoverDataIndex),this._lastHoverDataIndex=-1,this._polygonMesh.dataIndex=-1),this._labelsBuilder.updateLabels([])},_updateGroundPlane:function(t,e,n){var i=t.getModel("groundPlane",t);if(this._groundMesh.invisible=!i.get("show",!0),!this._groundMesh.invisible){var r=t.get("shading"),a=this._groundMaterials[r];a||(a=this._groundMaterials.lambert),Ta.setMaterialFromModel(r,a,i,n),a.get("normalMap")&&this._groundMesh.geometry.generateTangents(),this._groundMesh.material=a,this._groundMesh.material.set("color",Ta.parseColor(i.get("color"))),this._groundMesh.scale.set(e.size[0],e.size[2],1)}},_triangulation:function(t,e,n){this._triangulationResults=[];for(var i=[1/0,1/0,1/0],r=[-1/0,-1/0,-1/0],a=t.coordinateSystem,o=e;o1?i:0,L[F][m]=A.points[H+2],l.set(r+F,L[F]),s?(N[0]=(A.points[H]*v[0]-y[0])/b,N[1]=(A.points[H+2]*v[m]-y[m])/b):(N[0]=(G?R:R+V)/b,N[1]=(L[F][g]*v[g]-y[g])/b),c.set(r+F,N)}Cu.sub(E,L[1],L[0]),Cu.sub(j,L[3],L[0]),Cu.cross(P,E,j),Cu.normalize(P,P);for(F=0;F<4;F++)u.set(r+F,P),f&&h.set(r+F,o);for(F=0;F<6;F++)p[3*a+F]=D[F]+r;r+=4,a+=2,R+=V}}return e.dirty(),{vertexOffset:r,triangleOffset:a}},_getRegionLinesInfo:function(t,e,n){var i=0,r=0,a=e.getRegionModel(t),o=a.getModel("itemStyle"),s=o.get("borderWidth");if(s>0){var l=e.getRegionPolygonCoords(t);l.forEach((function(t){var e=t.exterior,a=t.interiors;i+=n.getPolylineVertexCount(e),r+=n.getPolylineTriangleCount(e);for(var o=0;othis._endIndex)){e-=this._startIndex;for(var i=this._vertexRangeOfDataIndex[2*e];i0},_displacementChanged:!0,_displacementScale:0,updateDisplacementHash:function(){var t=this.getDisplacementTexture(),e=this.getDisplacemenScale();this._displacementChanged=this._displacementTexture!==t||this._displacementScale!==e,this._displacementTexture=t,this._displacementScale=e},isDisplacementChanged:function(){return this._displacementChanged}});a["w"].merge(Zu.prototype,Fa),a["w"].merge(Zu.prototype,Ga),a["w"].merge(Zu.prototype,Ha),a["w"].merge(Zu.prototype,Dl);var qu=Zu,Yu=Math.PI,Ku=Math.sin,Qu=Math.cos,Ju=Math.tan,$u=Math.asin,tc=Math.atan2,ec=Yu/180,nc=864e5,ic=2440588,rc=2451545;function ac(t){return t.valueOf()/nc-.5+ic}function oc(t){return ac(t)-rc}var sc=23.4397*ec;function lc(t,e){return tc(Ku(t)*Qu(sc)-Ju(e)*Ku(sc),Qu(t))}function uc(t,e){return $u(Ku(e)*Qu(sc)+Qu(e)*Ku(sc)*Ku(t))}function cc(t,e,n){return tc(Ku(t),Qu(t)*Ku(e)-Ju(n)*Qu(e))}function hc(t,e,n){return $u(Ku(e)*Ku(n)+Qu(e)*Qu(n)*Qu(t))}function dc(t,e){return ec*(280.16+360.9856235*t)-e}function fc(t){return ec*(357.5291+.98560028*t)}function pc(t){var e=ec*(1.9148*Ku(t)+.02*Ku(2*t)+3e-4*Ku(3*t)),n=102.9372*ec;return t+e+n+Yu}function gc(t){var e=fc(t),n=pc(e);return{dec:uc(n,0),ra:lc(n,0)}}var mc={getPosition:function(t,e,n){var i=ec*-n,r=ec*e,a=oc(t),o=gc(a),s=dc(a,i)-o.ra;return{azimuth:cc(s,r,o.dec),altitude:hc(s,r,o.dec)}}},vc=mc,yc="@export ecgl.atmosphere.vertex\nattribute vec3 position: POSITION;\nattribute vec3 normal : NORMAL;\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nuniform mat4 normalMatrix : WORLDINVERSETRANSPOSE;\n\nvarying vec3 v_Normal;\n\nvoid main() {\n v_Normal = normalize((normalMatrix * vec4(normal, 0.0)).xyz);\n gl_Position = worldViewProjection * vec4(position, 1.0);\n}\n@end\n\n\n@export ecgl.atmosphere.fragment\nuniform mat4 viewTranspose: VIEWTRANSPOSE;\nuniform float glowPower;\nuniform vec3 glowColor;\n\nvarying vec3 v_Normal;\n\nvoid main() {\n float intensity = pow(1.0 - dot(v_Normal, (viewTranspose * vec4(0.0, 0.0, 1.0, 0.0)).xyz), glowPower);\n gl_FragColor = vec4(glowColor, intensity * intensity);\n}\n@end";Ta.Shader["import"](la),Ta.Shader["import"](yc);var _c=a["d"].extend({type:"globe",__ecgl__:!0,_displacementScale:0,init:function(t,e){this.groupGL=new Ta.Node,this._sphereGeometry=new Ta.SphereGeometry({widthSegments:200,heightSegments:100,dynamic:!0}),this._overlayGeometry=new Ta.SphereGeometry({widthSegments:80,heightSegments:40}),this._planeGeometry=new Ta.PlaneGeometry,this._earthMesh=new Ta.Mesh({renderNormal:!0}),this._atmosphereMesh=new Ta.Mesh,this._atmosphereGeometry=new Ta.SphereGeometry({widthSegments:80,heightSegments:40}),this._atmosphereMaterial=new Ta.Material({shader:new Ta.Shader(Ta.Shader.source("ecgl.atmosphere.vertex"),Ta.Shader.source("ecgl.atmosphere.fragment")),transparent:!0}),this._atmosphereMesh.geometry=this._atmosphereGeometry,this._atmosphereMesh.material=this._atmosphereMaterial,this._atmosphereMesh.frontFace=Ta.Mesh.CW,this._lightRoot=new Ta.Node,this._sceneHelper=new uo,this._sceneHelper.initLight(this._lightRoot),this.groupGL.add(this._atmosphereMesh),this.groupGL.add(this._earthMesh),this._control=new Qa({zr:e.getZr()}),this._control.init(),this._layerMeshes={}},render:function(t,e,n){var i=t.coordinateSystem,r=t.get("shading");i.viewGL.add(this._lightRoot),t.get("show")?i.viewGL.add(this.groupGL):i.viewGL.remove(this.groupGL),this._sceneHelper.setScene(i.viewGL.scene),i.viewGL.setPostEffect(t.getModel("postEffect"),n),i.viewGL.setTemporalSuperSampling(t.getModel("temporalSuperSampling"));var a=this._earthMesh;a.geometry=this._sphereGeometry;var o="ecgl."+r;a.material&&a.material.shader.name===o||(a.material=Ta.createMaterial(o)),Ta.setMaterialFromModel(r,a.material,t,n),["roughnessMap","metalnessMap","detailMap","normalMap"].forEach((function(t){var e=a.material.get(t);e&&(e.flipY=!1)})),a.material.set("color",Ta.parseColor(t.get("baseColor")));var s=.99*i.radius;if(a.scale.set(s,s,s),t.get("atmosphere.show")){a.material.define("both","ATMOSPHERE_ENABLED"),this._atmosphereMesh.invisible=!1,this._atmosphereMaterial.setUniforms({glowPower:t.get("atmosphere.glowPower")||6,glowColor:t.get("atmosphere.color")||"#ffffff"}),a.material.setUniforms({glowPower:t.get("atmosphere.innerGlowPower")||2,glowColor:t.get("atmosphere.color")||"#ffffff"});var l=t.get("atmosphere.offset")||5;this._atmosphereMesh.scale.set(s+l,s+l,s+l)}else a.material.undefine("both","ATMOSPHERE_ENABLED"),this._atmosphereMesh.invisible=!0;var u=a.material.setTextureImage("diffuseMap",t.get("baseTexture"),n,{flipY:!1,anisotropic:8});u&&u.surface&&u.surface.attachToMesh(a);var c=a.material.setTextureImage("bumpMap",t.get("heightTexture"),n,{flipY:!1,anisotropic:8});c&&c.surface&&c.surface.attachToMesh(a),a.material[t.get("postEffect.enable")?"define":"undefine"]("fragment","SRGB_DECODE"),this._updateLight(t,n),this._displaceVertices(t,n),this._updateViewControl(t,n),this._updateLayers(t,n)},afterRender:function(t,e,n,i){var r=i.renderer;this._sceneHelper.updateAmbientCubemap(r,t,n),this._sceneHelper.updateSkybox(r,t,n)},_updateLayers:function(t,e){var n=t.coordinateSystem,i=t.get("layers"),r=n.radius,o=[],s=[],l=[],u=[];a["w"].each(i,(function(t){var i=new a["f"](t),c=i.get("type"),h=Ta.loadTexture(i.get("texture"),e,{flipY:!1,anisotropic:8});if(h.surface&&h.surface.attachToMesh(this._earthMesh),"blend"===c){var d=i.get("blendTo"),f=Pr.firstNotNull(i.get("intensity"),1);"emission"===d?(l.push(h),u.push(f)):(o.push(h),s.push(f))}else{var p=i.get("id"),g=this._layerMeshes[p];g||(g=this._layerMeshes[p]=new Ta.Mesh({geometry:this._overlayGeometry,castShadow:!1,ignorePicking:!0}));var m=i.get("shading");"lambert"===m?(g.material=g.__lambertMaterial||new Ta.Material({autoUpdateTextureStatus:!1,shader:Ta.createShader("ecgl.lambert"),transparent:!0,depthMask:!1}),g.__lambertMaterial=g.material):(g.material=g.__colorMaterial||new Ta.Material({autoUpdateTextureStatus:!1,shader:Ta.createShader("ecgl.color"),transparent:!0,depthMask:!1}),g.__colorMaterial=g.material),g.material.enableTexture("diffuseMap");var v=i.get("distance"),y=r+(null==v?n.radius/100:v);g.scale.set(y,y,y),r=y;var _=this._blankTexture||(this._blankTexture=Ta.createBlankTexture("rgba(255, 255, 255, 0)"));g.material.set("diffuseMap",_),Ta.loadTexture(i.get("texture"),e,{flipY:!1,anisotropic:8},(function(t){t.surface&&t.surface.attachToMesh(g),g.material.set("diffuseMap",t),e.getZr().refresh()})),i.get("show")?this.groupGL.add(g):this.groupGL.remove(g)}}),this);var c=this._earthMesh.material;c.define("fragment","LAYER_DIFFUSEMAP_COUNT",o.length),c.define("fragment","LAYER_EMISSIVEMAP_COUNT",l.length),c.set("layerDiffuseMap",o),c.set("layerDiffuseIntensity",s),c.set("layerEmissiveMap",l),c.set("layerEmissionIntensity",u);var h=t.getModel("debug.wireframe");if(h.get("show")){c.define("both","WIREFRAME_TRIANGLE");var d=Ta.parseColor(h.get("lineStyle.color")||"rgba(0,0,0,0.5)"),f=Pr.firstNotNull(h.get("lineStyle.width"),1);c.set("wireframeLineWidth",f),c.set("wireframeLineColor",d)}else c.undefine("both","WIREFRAME_TRIANGLE")},_updateViewControl:function(t,e){var n=t.coordinateSystem,i=t.getModel("viewControl"),r=(n.viewGL.camera,this);function a(){return{type:"globeChangeCamera",alpha:o.getAlpha(),beta:o.getBeta(),distance:o.getDistance()-n.radius,center:o.getCenter(),from:r.uid,globeId:t.id}}var o=this._control;o.setViewGL(n.viewGL);var s,l,u=i.get("targetCoord");null!=u&&(l=u[0]+90,s=u[1]),o.setFromViewControlModel(i,{baseDistance:n.radius,alpha:s,beta:l}),o.off("update"),o.on("update",(function(){e.dispatchAction(a())}))},_displaceVertices:function(t,e){var n=t.get("displacementQuality"),i=t.get("debug.wireframe.show"),r=t.coordinateSystem;if(t.isDisplacementChanged()||n!==this._displacementQuality||i!==this._showDebugWireframe){this._displacementQuality=n,this._showDebugWireframe=i;var a=this._sphereGeometry,o={low:100,medium:200,high:400,ultra:800}[n]||200,s=o/2;(a.widthSegments!==o||i)&&(a.widthSegments=o,a.heightSegments=s,a.build()),this._doDisplaceVertices(a,r),i&&a.generateBarycentric()}},_doDisplaceVertices:function(t,e){var n=t.attributes.position.value,i=t.attributes.texcoord0.value,r=t.__originalPosition;r&&r.length===n.length||(r=new Float32Array(n.length),r.set(n),t.__originalPosition=r);for(var a=e.displacementWidth,o=e.displacementHeight,s=e.displacementData,l=0;l50&&(o=1e3);var s=[];kc.perspective(s,zc,this.width/this.height,1,o),this.viewGL.camera.projectionMatrix.setArray(s),this.viewGL.camera.decomposeProjectionMatrix();s=kc.identity([]);var l=this.dataToPoint(this.center);kc.scale(s,s,[1,-1,1]),kc.translate(s,s,[0,0,-t]),kc.rotateX(s,s,e),kc.rotateZ(s,s,-this.bearing/180*Math.PI),kc.translate(s,s,[-l[0]*this.getScale()*Fc,-l[1]*this.getScale()*Fc,0]),this.viewGL.camera.viewMatrix.array=s;var u=[];kc.invert(u,s),this.viewGL.camera.worldTransform.array=u,this.viewGL.camera.decomposeWorldTransform();var c,h=Bc*this.getScale();if(this.altitudeExtent&&!isNaN(this.boxHeight)){var d=this.altitudeExtent[1]-this.altitudeExtent[0];c=this.boxHeight/d*this.getScale()/Math.pow(2,this._initialZoom-this.zoomOffset)}else c=h/(2*Math.PI*6378e3*Math.abs(Math.cos(this.center[1]*(Math.PI/180))))*this.altitudeScale*Fc;this.viewGL.rootNode.scale.set(this.getScale()*Fc,this.getScale()*Fc,c)}},getScale:function(){return Math.pow(2,this.zoom-this.zoomOffset)},projectOnTile:function(t,e){return this.projectOnTileWithScale(t,this.getScale()*Bc,e)},projectOnTileWithScale:function(t,e,n){var i=t[0],r=t[1],a=i*Vc/180,o=r*Vc/180,s=e*(a+Vc)/(2*Vc),l=e*(Vc-Math.log(Math.tan(Vc/4+.5*o)))/(2*Vc);return n=n||[],n[0]=s,n[1]=l,n},unprojectFromTile:function(t,e){return this.unprojectOnTileWithScale(t,this.getScale()*Bc,e)},unprojectOnTileWithScale:function(t,e,n){var i=t[0],r=t[1],a=i/e*(2*Vc)-Vc,o=2*(Math.atan(Math.exp(Vc-r/e*(2*Vc)))-Vc/4);return n=n||[],n[0]=180*a/Vc,n[1]=180*o/Vc,n},dataToPoint:function(t,e){return e=this.projectOnTileWithScale(t,Bc,e),e[0]-=this._origin[0],e[1]-=this._origin[1],e[2]=isNaN(t[2])?0:t[2],isNaN(t[2])||(e[2]=t[2],this.altitudeExtent&&(e[2]-=this.altitudeExtent[0])),e}};var Hc=Gc;function Uc(){Hc.apply(this,arguments)}Uc.prototype=new Hc,Uc.prototype.constructor=Uc,Uc.prototype.type="mapbox3D";var Wc=Uc,Xc=function(t,e,n){function i(t,e){var n=e.getWidth(),i=e.getHeight(),r=e.getDevicePixelRatio();this.viewGL.setViewport(0,0,n,i,r),this.width=n,this.height=i,this.altitudeScale=t.get("altitudeScale"),this.boxHeight=t.get("boxHeight")}function r(t,e){if("auto"!==this.model.get("boxHeight")){var n=[1/0,-1/0];t.eachSeries((function(t){if(t.coordinateSystem===this){var e=t.getData(),i=t.coordDimToDataDim("alt")[0];if(i){var r=e.getDataExtent(i,!0);n[0]=Math.min(n[0],r[0]),n[1]=Math.max(n[1],r[1])}}}),this),n&&isFinite(n[1]-n[0])&&(this.altitudeExtent=n)}}return{dimensions:e.prototype.dimensions,create:function(a,o){var s=[];return a.eachComponent(t,(function(t){var n=t.__viewGL;n||(n=t.__viewGL=new dl,n.setRootNode(new Ta.Node));var a=new e;a.viewGL=t.__viewGL,a.resize=i,a.resize(t,o),s.push(a),t.coordinateSystem=a,a.model=t,a.update=r})),a.eachSeries((function(e){if(e.get("coordinateSystem")===t){var n=e.getReferringComponents(t).models[0];if(n||(n=a.getComponent(t)),!n)throw new Error(t+' "'+Pr.firstNotNull(e.get(t+"Index"),e.get(t+"Id"),0)+'" not found');e.coordinateSystem=n.coordinateSystem}})),n&&n(s,a,o),s}}},Zc=Xc("mapbox3D",Wc,(function(t){t.forEach((function(t){t.setCameraOption(t.model.getMapboxCameraOption())}))})),qc=Zc;function Yc(t){t.registerComponentModel(Lc),t.registerComponentView(Rc),t.registerCoordinateSystem("mapbox3D",qc),t.registerAction({type:"mapbox3DChangeCamera",event:"mapbox3dcamerachanged",update:"mapbox3D:updateCamera"},(function(t,e){e.eachComponent({mainType:"mapbox3D",query:t},(function(e){e.setMapboxCameraOption(t)}))}))}Object(a["v"])(Yc);var Kc=["zoom","center","pitch","bearing"],Qc=a["c"].extend({type:"maptalks3D",layoutMode:"box",coordinateSystem:null,defaultOption:{zlevel:-10,urlTemplate:"http://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors, © CARTO',center:[0,0],zoom:0,pitch:0,bearing:0,light:{main:{alpha:20,beta:30}},altitudeScale:1,boxHeight:"auto"},getMaptalksCameraOption:function(){var t=this;return Kc.reduce((function(e,n){return e[n]=t.get(n),e}),{})},setMaptalksCameraOption:function(t){null!=t&&Kc.forEach((function(e){null!=t[e]&&(this.option[e]=t[e])}),this)},getMaptalks:function(){return this._maptalks},setMaptalks:function(t){this._maptalks=t}});a["w"].merge(Qc.prototype,Ga),a["w"].merge(Qc.prototype,Ha);var Jc=Qc;function $c(t,e,n,i){if(this.id=t,this.zr=e,this.dom=document.createElement("div"),this.dom.style.cssText="position:absolute;left:0;right:0;top:0;bottom:0;",!maptalks)throw new Error("Maptalks library must be included. See https://maptalks.org");this._maptalks=new maptalks.Map(this.dom,{center:n,zoom:i,doubleClickZoom:!1,fog:!1}),this._initEvents()}$c.prototype.setUnpainted=function(){},$c.prototype.resize=function(){this._maptalks.checkSize()},$c.prototype.getMaptalks=function(){return this._maptalks},$c.prototype.clear=function(){},$c.prototype.refresh=function(){this._maptalks.checkSize()};var th=["mousedown","mouseup","click","dblclick","mousemove","mousewheel","DOMMouseScroll","touchstart","touchend","touchmove","touchcancel"];$c.prototype._initEvents=function(){var t=this.dom;this._handlers=this._handlers||{contextmenu:function(t){return t.preventDefault(),!1}},th.forEach((function(e){this._handlers[e]=function(n){var i={};for(var r in n)i[r]=n[r];i.bubbles=!1;var a=new n.constructor(n.type,i);"mousewheel"===e||"DOMMouseScroll"===e?t.dispatchEvent(a):t.firstElementChild.dispatchEvent(a)},this.zr.dom.addEventListener(e,this._handlers[e])}),this),this.zr.dom.addEventListener("contextmenu",this._handlers.contextmenu)},$c.prototype.dispose=function(){th.forEach((function(t){this.zr.dom.removeEventListener(t,this._handlers[t])}),this),this._maptalks.remove()};var eh=$c;Ta.Shader.import(Nc);var nh=a["d"].extend({type:"maptalks3D",__ecgl__:!0,init:function(t,e){this._groundMesh=new Ta.Mesh({geometry:new Ta.PlaneGeometry,material:new Ta.Material({shader:new Ta.Shader({vertex:Ta.Shader.source("ecgl.displayShadow.vertex"),fragment:Ta.Shader.source("ecgl.displayShadow.fragment")}),depthMask:!1}),renderOrder:-100,culling:!1,castShadow:!1,$ignorePicking:!0,renderNormal:!0})},_initMaptalksLayer:function(t,e){var n=e.getZr();this._zrLayer=new eh("maptalks3D",n,t.get("center"),t.get("zoom")),n.painter.insertLayer(-1e3,this._zrLayer),this._lightRoot=new Ta.Node,this._sceneHelper=new uo(this._lightRoot),this._sceneHelper.initLight(this._lightRoot);var i=this._zrLayer.getMaptalks(),r=this._dispatchInteractAction.bind(this,e,i);["zoomend","zooming","zoomstart","dragrotating","pitch","pitchend","movestart","moving","moveend","resize","touchstart","touchmove","touchend","animating"].forEach((function(t){i.on(t,r)}))},render:function(t,e,n){this._zrLayer||this._initMaptalksLayer(t,n);var i=this._zrLayer.getMaptalks(),r=t.get("urlTemplate"),a=i.getBaseLayer();r!==this._oldUrlTemplate&&(a?a.setOptions({urlTemplate:r,attribution:t.get("attribution")}):(a=new maptalks.TileLayer("maptalks-echarts-gl-baselayer",{urlTemplate:r,subdomains:["a","b","c"],attribution:t.get("attribution")}),i.setBaseLayer(a))),this._oldUrlTemplate=r,i.setCenter(t.get("center")),i.setZoom(t.get("zoom"),{animation:!1}),i.setPitch(t.get("pitch")),i.setBearing(t.get("bearing")),t.setMaptalks(i);var o=t.coordinateSystem;o.viewGL.scene.add(this._lightRoot),o.viewGL.add(this._groundMesh),this._updateGroundMesh(),this._sceneHelper.setScene(o.viewGL.scene),this._sceneHelper.updateLight(t),o.viewGL.setPostEffect(t.getModel("postEffect"),n),o.viewGL.setTemporalSuperSampling(t.getModel("temporalSuperSampling")),this._maptalks3DModel=t},afterRender:function(t,e,n,i){var r=i.renderer;this._sceneHelper.updateAmbientCubemap(r,t,n),this._sceneHelper.updateSkybox(r,t,n),t.coordinateSystem.viewGL.scene.traverse((function(t){t.material&&(t.material.define("fragment","NORMAL_UP_AXIS",2),t.material.define("fragment","NORMAL_FRONT_AXIS",1))}))},updateCamera:function(t,e,n,i){t.coordinateSystem.setCameraOption(i),this._updateGroundMesh(),n.getZr().refresh()},_dispatchInteractAction:function(t,e,n){t.dispatchAction({type:"maptalks3DChangeCamera",pitch:e.getPitch(),zoom:rh(e.getResolution())+1,center:e.getCenter().toArray(),bearing:e.getBearing(),maptalks3DId:this._maptalks3DModel&&this._maptalks3DModel.id})},_updateGroundMesh:function(){if(this._maptalks3DModel){var t=this._maptalks3DModel.coordinateSystem,e=t.dataToPoint(t.center);this._groundMesh.position.set(e[0],e[1],-.001);var n=new Ta.Plane(new Ta.Vector3(0,0,1),0),i=t.viewGL.camera.castRay(new Ta.Vector2(-1,-1)),r=t.viewGL.camera.castRay(new Ta.Vector2(1,1)),a=i.intersectPlane(n),o=r.intersectPlane(n),s=a.dist(o)/t.viewGL.rootNode.scale.x;this._groundMesh.scale.set(s,s,1)}},dispose:function(t,e){this._zrLayer&&this._zrLayer.dispose(),e.getZr().painter.delLayer(-1e3)}});const ih=12756274*Math.PI/(256*Math.pow(2,20));function rh(t){return 19-Math.log(t/ih)/Math.LN2}function ah(){Hc.apply(this,arguments),this.maxPitch=85,this.zoomOffset=1}ah.prototype=new Hc,ah.prototype.constructor=ah,ah.prototype.type="maptalks3D";var oh=ah,sh=Xc("maptalks3D",oh,(function(t){t.forEach((function(t){t.setCameraOption(t.model.getMaptalksCameraOption())}))})),lh=sh;function uh(t){t.registerComponentModel(Jc),t.registerComponentView(nh),t.registerCoordinateSystem("maptalks3D",lh),t.registerAction({type:"maptalks3DChangeCamera",event:"maptalks3dcamerachanged",update:"maptalks3D:updateCamera"},(function(t,e){e.eachComponent({mainType:"maptalks3D",query:t},(function(e){e.setMaptalksCameraOption(t)}))}))}Object(a["v"])(uh);var ch=to.vec3,hh=a["m"].dataStack.isDimensionStacked;function dh(t){var e=t[0],n=t[1];return!(e>0&&n>0||e<0&&n<0)}function fh(t,e){var n=t.getData(),i=t.get("barSize");if(null==i){var r,o,s=e.size,l=e.getAxis("x"),u=e.getAxis("y");r="category"===l.type?.7*l.getBandWidth():.6*Math.round(s[0]/Math.sqrt(n.count())),o="category"===u.type?.7*u.getBandWidth():.6*Math.round(s[1]/Math.sqrt(n.count())),i=[r,o]}else a["w"].isArray(i)||(i=[i,i]);var c=e.getAxis("z").scale.getExtent(),h=dh(c),d=["x","y","z"].map((function(e){return t.coordDimToDataDim(e)[0]})),f=hh(n,d[2]),p=f?n.getCalculationInfo("stackResultDimension"):d[2];n.each(d,(function(t,r,a,o){var s=n.get(p,o),l=f?s-a:h?0:c[0],u=e.dataToPoint([t,r,l]),d=e.dataToPoint([t,r,s]),g=ch.dist(u,d),m=[0,d[1]":"")+o.join(i?"
":", ")}var r=t.getData(),o=t.getRawValue(e),s=a["w"].isArray(o)?i(o):a["i"].encodeHTML(a["i"].addCommas(o)),l=r.getName(e),u=wu(r,e);a["w"].isObject(u)&&u.colorStops&&(u=(u.colorStops[0]||{}).color),u=u||"transparent";var c=a["i"].getTooltipMarker(u),h=t.name;return"\0-"===h&&(h=""),h=h?a["i"].encodeHTML(h)+(n?": ":"
"):"",n?c+h+s:h+c+(l?a["i"].encodeHTML(l)+": "+s:s)},Ah=function(t,e,n){n=n||t.getSource();var i=e||a["j"](t.get("coordinateSystem"))||["x","y","z"],r=a["m"].createDimensions(n,{dimensionsDefine:n.dimensionsDefine||t.get("dimensions"),encodeDefine:n.encodeDefine||t.get("encode"),coordDimensions:i.map((function(e){var n=t.getReferringComponents(e+"Axis3D").models[0];return{type:n&&"category"===n.get("type")?"ordinal":"float",name:e}}))});"cartesian3D"===t.get("coordinateSystem")&&r.forEach((function(e){if(i.indexOf(e.coordDim)>=0){var n=t.getReferringComponents(e.coordDim+"Axis3D").models[0];n&&"category"===n.get("type")&&(e.ordinalMeta=n.getOrdinalMeta())}}));var o=a["m"].dataStack.enableDataStack(t,r,{byIndex:!0,stackedCoordDimension:"z"}),s=new a["e"](r,t);return s.setCalculationInfo(o),s.initData(n),s},Ch=a["g"].extend({type:"series.bar3D",dependencies:["globe"],visualStyleAccessPathvisu:"itemStyle",getInitialData:function(t,e){return Ah(this)},getFormattedLabel:function(t,e,n,i){var r=Sh.getFormattedLabel(this,t,e,n,i);return null==r&&(r=this.getData().get("z",t)),r},formatTooltip:function(t){return Mh(this,t)},defaultOption:{coordinateSystem:"cartesian3D",globeIndex:0,grid3DIndex:0,zlevel:-10,bevelSize:0,bevelSmoothness:2,onGridPlane:"xy",shading:"color",minHeight:0,itemStyle:{opacity:1},label:{show:!1,distance:2,textStyle:{fontSize:14,color:"#000",backgroundColor:"rgba(255,255,255,0.7)",padding:3,borderRadius:3}},emphasis:{label:{show:!0}},animationDurationUpdate:500}});a["w"].merge(Ch.prototype,Dl);var Ih=Ch,Dh=to.vec3,Lh=to.mat3,Eh=bn.extend((function(){return{attributes:{position:new bn.Attribute("position","float",3,"POSITION"),normal:new bn.Attribute("normal","float",3,"NORMAL"),color:new bn.Attribute("color","float",4,"COLOR"),prevPosition:new bn.Attribute("prevPosition","float",3),prevNormal:new bn.Attribute("prevNormal","float",3)},dynamic:!0,enableNormal:!1,bevelSize:1,bevelSegments:0,_dataIndices:null,_vertexOffset:0,_triangleOffset:0}}),{resetOffset:function(){this._vertexOffset=0,this._triangleOffset=0},setBarCount:function(t){var e=this.enableNormal,n=this.getBarVertexCount()*t,i=this.getBarTriangleCount()*t;this.vertexCount!==n&&(this.attributes.position.init(n),e?this.attributes.normal.init(n):this.attributes.normal.value=null,this.attributes.color.init(n)),this.triangleCount!==i&&(this.indices=n>65535?new Uint32Array(3*i):new Uint16Array(3*i),this._dataIndices=new Uint32Array(n))},getBarVertexCount:function(){var t=this.bevelSize>0?this.bevelSegments:0;return t>0?this._getBevelBarVertexCount(t):this.enableNormal?24:8},getBarTriangleCount:function(){var t=this.bevelSize>0?this.bevelSegments:0;return t>0?this._getBevelBarTriangleCount(t):12},_getBevelBarVertexCount:function(t){return 4*(t+1)*(t+1)*2},_getBevelBarTriangleCount:function(t){var e=4*t+3,n=2*t+1;return(e+1)*n*2+4},setColor:function(t,e){for(var n=this.getBarVertexCount(),i=n*t,r=n*(t+1),a=i;a0&&this.bevelSegments>0)this._addBevelBar(t,h,g,m,this.bevelSize,this.bevelSegments,v);else{Dh.copy(r,h),Dh.normalize(r,r),Dh.cross(a,g,r),Dh.normalize(a,a),Dh.cross(i,r,a),Dh.normalize(a,a),Dh.negate(o,i),Dh.negate(s,r),Dh.negate(l,a),e(u[0],t,i,m[0]/2),e(u[0],u[0],a,m[2]/2),e(u[1],t,i,m[0]/2),e(u[1],u[1],l,m[2]/2),e(u[2],t,o,m[0]/2),e(u[2],u[2],l,m[2]/2),e(u[3],t,o,m[0]/2),e(u[3],u[3],a,m[2]/2),e(n,t,r,m[1]),e(u[4],n,i,m[0]/2),e(u[4],u[4],a,m[2]/2),e(u[5],n,i,m[0]/2),e(u[5],u[5],l,m[2]/2),e(u[6],n,o,m[0]/2),e(u[6],u[6],l,m[2]/2),e(u[7],n,o,m[0]/2),e(u[7],u[7],a,m[2]/2);var b=this.attributes;if(this.enableNormal){c[0]=i,c[1]=o,c[2]=r,c[3]=s,c[4]=a,c[5]=l;for(var x=this._vertexOffset,w=0;w0&&(f++,c[3]<.99&&(p=!0))}})),o.geometry.setBarCount(f);var g=n.getLayout("orient"),m=this._barIndexOfData=new Int32Array(n.count());f=0;n.each((function(t){if(n.hasValue(t)){var e=n.getItemLayout(t),i=e[0],r=e[1],o=e[2],s=4*t;c[0]=h[s++],c[1]=h[s++],c[2]=h[s++],c[3]=h[s++],c[3]>0&&(a._barMesh.geometry.addBar(i,r,g,o,c,t),m[t]=f++)}else m[t]=-1})),o.geometry.dirty(),o.geometry.updateBoundingBox();var v=o.material;v.transparent=p,v.depthMask=!p,o.geometry.sortTriangles=p,this._initHandler(t,e)},_initHandler:function(t,e){var n=t.getData(),i=this._barMesh,r="cartesian3D"===t.coordinateSystem.type;i.seriesIndex=t.seriesIndex;var a=-1;i.off("mousemove"),i.off("mouseout"),i.on("mousemove",(function(t){var o=i.geometry.getDataIndexOfVertex(t.triangle[0]);o!==a&&(this._downplay(a),this._highlight(o),this._labelsBuilder.updateLabels([o]),r&&e.dispatchAction({type:"grid3DShowAxisPointer",value:[n.get("x",o),n.get("y",o),n.get("z",o,!0)]})),a=o,i.dataIndex=o}),this),i.on("mouseout",(function(t){this._downplay(a),this._labelsBuilder.updateLabels(),a=-1,i.dataIndex=-1,r&&e.dispatchAction({type:"grid3DHideAxisPointer"})}),this)},_highlight:function(t){var e=this._data;if(e){var n=this._barIndexOfData[t];if(!(n<0)){var i=e.getItemModel(t),r=i.getModel("emphasis.itemStyle"),o=r.get("color"),s=r.get("opacity");if(null==o){var l=wu(e,t);o=a["h"].lift(l,-.4)}null==s&&(s=Ou(e,t));var u=Ta.parseColor(o);u[3]*=s,this._barMesh.geometry.setColor(n,u),this._api.getZr().refresh()}}},_downplay:function(t){var e=this._data;if(e){var n=this._barIndexOfData[t];if(!(n<0)){var i=wu(e,t),r=Ou(e,t),a=Ta.parseColor(i);a[3]*=r,this._barMesh.geometry.setColor(n,a),this._api.getZr().refresh()}}},highlight:function(t,e,n,i){this._toggleStatus("highlight",t,e,n,i)},downplay:function(t,e,n,i){this._toggleStatus("downplay",t,e,n,i)},_toggleStatus:function(t,e,n,i,r){var o=e.getData(),s=Pr.queryDataIndex(o,r),l=this;null!=s?a["w"].each(Sh.normalizeToArray(s),(function(e){"highlight"===t?this._highlight(e):this._downplay(e)}),this):o.each((function(e){"highlight"===t?l._highlight(e):l._downplay(e)}))},remove:function(){this.groupGL.removeAll()},dispose:function(){this._labelsBuilder.dispose(),this.groupGL.removeAll()}});function Rh(t){t.registerChartView(Nh),t.registerSeriesModel(Ih),wh(t),t.registerProcessor((function(t,e){t.eachSeriesByType("bar3d",(function(t){var e=t.getData();e.filterSelf((function(t){return e.hasValue(t)}))}))}))}Object(a["v"])(Rh);var kh=a["g"].extend({type:"series.line3D",dependencies:["grid3D"],visualStyleAccessPath:"lineStyle",visualDrawType:"stroke",getInitialData:function(t,e){return Ah(this)},formatTooltip:function(t){return Mh(this,t)},defaultOption:{coordinateSystem:"cartesian3D",zlevel:-10,grid3DIndex:0,lineStyle:{width:2},animationDurationUpdate:500}}),Bh=kh,zh=n("9680"),Vh=to.vec3;Ta.Shader.import(Io);var Fh=a["b"].extend({type:"line3D",__ecgl__:!0,init:function(t,e){this.groupGL=new Ta.Node,this._api=e},render:function(t,e,n){var i=this._prevLine3DMesh;this._prevLine3DMesh=this._line3DMesh,this._line3DMesh=i,this._line3DMesh||(this._line3DMesh=new Ta.Mesh({geometry:new ro({useNativeLine:!1,sortTriangles:!0}),material:new Ta.Material({shader:Ta.createShader("ecgl.meshLines3D")}),renderOrder:10}),this._line3DMesh.geometry.pick=this._pick.bind(this)),this.groupGL.remove(this._prevLine3DMesh),this.groupGL.add(this._line3DMesh);var r=t.coordinateSystem;if(r&&r.viewGL){r.viewGL.add(this.groupGL);var a=r.viewGL.isLinearSpace()?"define":"undefine";this._line3DMesh.material[a]("fragment","SRGB_DECODE")}this._doRender(t,n),this._data=t.getData(),this._camera=r.viewGL.camera,this.updateCamera(),this._updateAnimation(t)},updateCamera:function(){this._updateNDCPosition()},_doRender:function(t,e){var n=t.getData(),i=this._line3DMesh;i.geometry.resetOffset();var r=n.getLayout("points"),a=[],o=new Float32Array(r.length/3*4),s=0,l=!1;n.each((function(t){var e=wu(n,t),i=Ou(n,t);null==i&&(i=1),Ta.parseColor(e,a),a[3]*=i,o[s++]=a[0],o[s++]=a[1],o[s++]=a[2],o[s++]=a[3],a[3]<.99&&(l=!0)})),i.geometry.setVertexCount(i.geometry.getPolylineVertexCount(r)),i.geometry.setTriangleCount(i.geometry.getPolylineTriangleCount(r)),i.geometry.addPolyline(r,o,Pr.firstNotNull(t.get("lineStyle.width"),1)),i.geometry.dirty(),i.geometry.updateBoundingBox();var u=i.material;u.transparent=l,u.depthMask=!l;var c=t.getModel("debug.wireframe");c.get("show")?(i.geometry.createAttribute("barycentric","float",3),i.geometry.generateBarycentric(),i.material.set("both","WIREFRAME_TRIANGLE"),i.material.set("wireframeLineColor",Ta.parseColor(c.get("lineStyle.color")||"rgba(0,0,0,0.5)")),i.material.set("wireframeLineWidth",Pr.firstNotNull(c.get("lineStyle.width"),1))):i.material.set("both","WIREFRAME_TRIANGLE"),this._points=r,this._initHandler(t,e)},_updateAnimation:function(t){Ta.updateVertexAnimation([["prevPosition","position"],["prevPositionPrev","positionPrev"],["prevPositionNext","positionNext"]],this._prevLine3DMesh,this._line3DMesh,t)},_initHandler:function(t,e){var n=t.getData(),i=t.coordinateSystem,r=this._line3DMesh,a=-1;r.seriesIndex=t.seriesIndex,r.off("mousemove"),r.off("mouseout"),r.on("mousemove",(function(t){var o=i.pointToData(t.point.array),s=n.indicesOfNearest("x",o[0])[0];s!==a&&(e.dispatchAction({type:"grid3DShowAxisPointer",value:[n.get("x",s),n.get("y",s),n.get("z",s)]}),r.dataIndex=s),a=s}),this),r.on("mouseout",(function(t){a=-1,r.dataIndex=-1,e.dispatchAction({type:"grid3DHideAxisPointer"})}),this)},_updateNDCPosition:function(){var t=new Le,e=this._camera;Le.multiply(t,e.projectionMatrix,e.viewMatrix);var n=this._positionNDC,i=this._points,r=i.length/3;n&&n.length/2===r||(n=this._positionNDC=new Float32Array(2*r));for(var a=[],o=0;o=0){var x=3*u,w=new ye(this._points[x],this._points[x+1],this._points[x+2]);a.push({dataIndex:u,point:w,pointWorld:w.clone(),target:this._line3DMesh,distance:this._camera.getWorldPosition().dist(w)})}},remove:function(){this.groupGL.removeAll()},dispose:function(){this.groupGL.removeAll()}});function Gh(t){t.registerChartView(Fh),t.registerSeriesModel(Bh),t.registerLayout((function(t,e){t.eachSeriesByType("line3D",(function(t){var e=t.getData(),n=t.coordinateSystem;if(n){if("cartesian3D"!==n.type)return void 0;var i=new Float32Array(3*e.count()),r=[],a=[],o=n.dimensions,s=o.map((function(e){return t.coordDimToDataDim(e)[0]}));n&&e.each(s,(function(t,e,o,s){r[0]=t,r[1]=e,r[2]=o,n.dataToPoint(r,a),i[3*s]=a[0],i[3*s+1]=a[1],i[3*s+2]=a[2]})),e.setLayout("points",i)}}))}))}Object(a["v"])(Gh);var Hh=a["g"].extend({type:"series.scatter3D",dependencies:["globe","grid3D","geo3D"],visualStyleAccessPath:"itemStyle",hasSymbolVisual:!0,getInitialData:function(t,e){return Ah(this)},getFormattedLabel:function(t,e,n,i){var r=Sh.getFormattedLabel(this,t,e,n,i);if(null==r){var a=this.getData(),o=a.dimensions[a.dimensions.length-1];r=a.get(o,t)}return r},formatTooltip:function(t){return Mh(this,t)},defaultOption:{coordinateSystem:"cartesian3D",zlevel:-10,progressive:1e5,progressiveThreshold:1e5,grid3DIndex:0,globeIndex:0,symbol:"circle",symbolSize:10,blendMode:"source-over",label:{show:!1,position:"right",distance:5,textStyle:{fontSize:14,color:"#000",backgroundColor:"rgba(255,255,255,0.7)",padding:3,borderRadius:3}},itemStyle:{opacity:.8},emphasis:{label:{show:!0}},animationDurationUpdate:500}});function Uh(t,e,n){e=e||document.createElement("canvas");e.width=t,e.height=t;var i=e.getContext("2d");return n&&n(i),e}function Wh(t,e,n,i){a["w"].isArray(e)||(e=[e,e]);var r=Zh.getMarginByStyle(n,i),o=e[0]+r.left+r.right,s=e[1]+r.top+r.bottom,l=a["m"].createSymbol(t,0,0,e[0],e[1]),u=Math.max(o,s);l.x=r.left,l.y=r.top,o>s?l.y+=(u-s)/2:l.x+=(u-o)/2;var c=l.getBoundingRect();return l.x-=c.x,l.y-=c.y,l.setStyle(n),l.update(),l.__size=u,l}function Xh(t,e,n){var i=e.width,r=e.height,a=t.canvas.width,o=t.canvas.height,s=i/a,l=r/o;function u(t){return t<128?1:-1}function c(t,a){var o=1/0;t=Math.floor(t*s),a=Math.floor(a*l);for(var c=a*i+t,h=e.data[4*c],d=u(h),f=Math.max(a-n,0);f=2e4},doSortVertices:function(t,e){var n=this.indices,i=Yh.create();if(!n){n=this.indices=this.vertexCount>65535?new Uint32Array(this.vertexCount):new Uint16Array(this.vertexCount);for(var r=0;r.05);else for(r=0;r<3;r++)this._progressiveQuickSort(3*e+r);this.dirtyIndices()},_simpleSort:function(t){var e=this._zList,n=this.indices;function i(t,n){return e[n]-e[t]}t?Array.prototype.sort.call(n,i):pu.sort(n,i,0,n.length-1)},_progressiveQuickSort:function(t){var e=this._zList,n=this.indices;this._quickSort=this._quickSort||new pu,this._quickSort.step(n,(function(t,n){return e[n]-e[t]}),t)}},Qh="@export ecgl.sdfSprite.vertex\n\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nuniform float elapsedTime : 0;\n\nattribute vec3 position : POSITION;\n\n#ifdef VERTEX_SIZE\nattribute float size;\n#else\nuniform float u_Size;\n#endif\n\n#ifdef VERTEX_COLOR\nattribute vec4 a_FillColor: COLOR;\nvarying vec4 v_Color;\n#endif\n\n#ifdef VERTEX_ANIMATION\nattribute vec3 prevPosition;\nattribute float prevSize;\nuniform float percent : 1.0;\n#endif\n\n\n#ifdef POSITIONTEXTURE_ENABLED\nuniform sampler2D positionTexture;\n#endif\n\nvarying float v_Size;\n\nvoid main()\n{\n\n#ifdef POSITIONTEXTURE_ENABLED\n gl_Position = worldViewProjection * vec4(texture2D(positionTexture, position.xy).xy, -10.0, 1.0);\n#else\n\n #ifdef VERTEX_ANIMATION\n vec3 pos = mix(prevPosition, position, percent);\n #else\n vec3 pos = position;\n #endif\n gl_Position = worldViewProjection * vec4(pos, 1.0);\n#endif\n\n#ifdef VERTEX_SIZE\n#ifdef VERTEX_ANIMATION\n v_Size = mix(prevSize, size, percent);\n#else\n v_Size = size;\n#endif\n#else\n v_Size = u_Size;\n#endif\n\n#ifdef VERTEX_COLOR\n v_Color = a_FillColor;\n #endif\n\n gl_PointSize = v_Size;\n}\n\n@end\n\n@export ecgl.sdfSprite.fragment\n\nuniform vec4 color: [1, 1, 1, 1];\nuniform vec4 strokeColor: [1, 1, 1, 1];\nuniform float smoothing: 0.07;\n\nuniform float lineWidth: 0.0;\n\n#ifdef VERTEX_COLOR\nvarying vec4 v_Color;\n#endif\n\nvarying float v_Size;\n\nuniform sampler2D sprite;\n\n@import clay.util.srgb\n\nvoid main()\n{\n gl_FragColor = color;\n\n vec4 _strokeColor = strokeColor;\n\n#ifdef VERTEX_COLOR\n gl_FragColor *= v_Color;\n #endif\n\n#ifdef SPRITE_ENABLED\n float d = texture2D(sprite, gl_PointCoord).r;\n gl_FragColor.a *= smoothstep(0.5 - smoothing, 0.5 + smoothing, d);\n\n if (lineWidth > 0.0) {\n float sLineWidth = lineWidth / 2.0;\n\n float outlineMaxValue0 = 0.5 + sLineWidth;\n float outlineMaxValue1 = 0.5 + sLineWidth + smoothing;\n float outlineMinValue0 = 0.5 - sLineWidth - smoothing;\n float outlineMinValue1 = 0.5 - sLineWidth;\n\n if (d <= outlineMaxValue1 && d >= outlineMinValue0) {\n float a = _strokeColor.a;\n if (d <= outlineMinValue1) {\n a = a * smoothstep(outlineMinValue0, outlineMinValue1, d);\n }\n else {\n a = a * smoothstep(outlineMaxValue1, outlineMaxValue0, d);\n }\n gl_FragColor.rgb = mix(gl_FragColor.rgb * gl_FragColor.a, _strokeColor.rgb, a);\n gl_FragColor.a = gl_FragColor.a * (1.0 - a) + a;\n }\n }\n#endif\n\n#ifdef SRGB_DECODE\n gl_FragColor = sRGBToLinear(gl_FragColor);\n#endif\n}\n@end",Jh=to.vec4;Ta.Shader.import(Qh);var $h=Ta.Mesh.extend((function(){var t=new Ta.Geometry({dynamic:!0,attributes:{color:new Ta.Geometry.Attribute("color","float",4,"COLOR"),position:new Ta.Geometry.Attribute("position","float",3,"POSITION"),size:new Ta.Geometry.Attribute("size","float",1),prevPosition:new Ta.Geometry.Attribute("prevPosition","float",3),prevSize:new Ta.Geometry.Attribute("prevSize","float",1)}});Object.assign(t,Kh);var e=new Ta.Material({shader:Ta.createShader("ecgl.sdfSprite"),transparent:!0,depthMask:!1});e.enableTexture("sprite"),e.define("both","VERTEX_COLOR"),e.define("both","VERTEX_SIZE");var n=new Ta.Texture2D({image:document.createElement("canvas"),flipY:!1});return e.set("sprite",n),t.pick=this._pick.bind(this),{geometry:t,material:e,mode:Ta.Mesh.POINTS,sizeScale:1}}),{_pick:function(t,e,n,i,r,a){var o=this._positionNDC;if(o)for(var s=n.viewport,l=2/s.width,u=2/s.height,c=this.geometry.vertexCount-1;c>=0;c--){var h;h=this.geometry.indices?this.geometry.indices[c]:c;var d=o[2*h],f=o[2*h+1],p=this.geometry.attributes.size.get(h)/this.sizeScale,g=p/2;if(t>d-g*l&&tf-g*u&&e2?(p=this._updateSymbolSprite(t,d,c,h),s.enableTexture("sprite")):s.disableTexture("sprite"),u.position.init(r-i);var g=[];if(f){s.undefine("VERTEX_SIZE"),s.undefine("VERTEX_COLOR");var m=bu(o),v=xu(o);Ta.parseColor(m,g),g[3]*=v,s.set({color:g,u_Size:c.maxSize*this._sizeScale})}else s.set({color:[1,1,1,1]}),s.define("VERTEX_SIZE"),s.define("VERTEX_COLOR"),u.size.init(r-i),u.color.init(r-i),this._originalOpacity=new Float32Array(r-i);for(var y=o.getLayout("points"),_=u.position.value,b=0;b1?(r[0]=n.maxSize,r[1]=n.maxSize/n.aspect):(r[1]=n.maxSize,r[0]=n.maxSize*n.aspect),r[0]=r[0]||1,r[1]=r[1]||1,this._symbolType===n.type&&id(this._symbolSize,r)&&this._lineWidth===e.lineWidth||(qh.createSymbolSprite(n.type,r,{fill:"#fff",lineWidth:e.lineWidth,stroke:"transparent",shadowColor:"transparent",minMargin:Math.min(r[0]/2,10)},this._spriteImageCanvas),qh.createSDFFromCanvas(this._spriteImageCanvas,Math.min(this._spriteImageCanvas.width,32),ed,this._mesh.material.get("sprite").image),this._symbolType=n.type,this._symbolSize=r,this._lineWidth=e.lineWidth),this._spriteImageCanvas.width/n.maxSize*i},_updateMaterial:function(t,e){var n="lighter"===t.get("blendMode")?Ta.additiveBlend:null,i=this._mesh.material;i.blend=n,i.set("lineWidth",e.lineWidth/ed);var r=Ta.parseColor(e.stroke);i.set("strokeColor",r),i.transparent=!0,i.depthMask=!1,i.depthTest=!this.is2D,i.sortVertices=!this.is2D},_updateLabelBuilder:function(t,e,n){var i=t.getData(),r=this._mesh.geometry,a=r.attributes.position.value,o=(e=this._startDataIndex,this._mesh.sizeScale);this._labelsBuilder.updateData(i,e,n),this._labelsBuilder.getLabelPosition=function(t,n,i){var r=3*(t-e);return[a[r],a[r+1],a[r+2]]},this._labelsBuilder.getLabelDistance=function(t,n,i){var a=r.attributes.size.get(t-e)/o;return a/2+i},this._labelsBuilder.updateLabels()},_updateAnimation:function(t){Ta.updateVertexAnimation([["prevPosition","position"],["prevSize","size"]],this._prevMesh,this._mesh,t)},_updateHandler:function(t,e,n){var i,r=t.getData(),a=this._mesh,o=this,s=-1,l=t.coordinateSystem&&"cartesian3D"===t.coordinateSystem.type;l&&(i=t.coordinateSystem.model),a.seriesIndex=t.seriesIndex,a.off("mousemove"),a.off("mouseout"),a.on("mousemove",(function(e){var u=e.vertexIndex+o._startDataIndex;u!==s&&(this.highlightOnMouseover&&(this.downplay(r,s),this.highlight(r,u),this._labelsBuilder.updateLabels([u])),l&&n.dispatchAction({type:"grid3DShowAxisPointer",value:[r.get(t.coordDimToDataDim("x")[0],u),r.get(t.coordDimToDataDim("y")[0],u),r.get(t.coordDimToDataDim("z")[0],u)],grid3DIndex:i.componentIndex})),a.dataIndex=u,s=u}),this),a.on("mouseout",(function(t){var e=t.vertexIndex+o._startDataIndex;this.highlightOnMouseover&&(this.downplay(r,e),this._labelsBuilder.updateLabels()),s=-1,a.dataIndex=-1,l&&n.dispatchAction({type:"grid3DHideAxisPointer",grid3DIndex:i.componentIndex})}),this)},updateLayout:function(t,e,n){var i=t.getData();if(this._mesh){var r=this._mesh.geometry.attributes.position.value,a=i.getLayout("points");if(this.is2D)for(var o=0;othis._endDataIndex||ethis._endDataIndex||e0?1:-1}Ta.Shader.import(Id);var Ed=Ta.Mesh.extend((function(){var t=new Ta.Material({shader:new Ta.Shader(Ta.Shader.source("ecgl.trail2.vertex"),Ta.Shader.source("ecgl.trail2.fragment")),transparent:!0,depthMask:!1}),e=new ro({dynamic:!0});return e.createAttribute("dist","float",1),e.createAttribute("distAll","float",1),e.createAttribute("start","float",1),{geometry:e,material:t,culling:!1,$ignorePicking:!0}}),{updateData:function(t,e,n){var i=t.hostModel,r=this.geometry,a=i.getModel("effect"),o=a.get("trailWidth")*e.getDevicePixelRatio(),s=a.get("trailLength"),l=i.get("effect.constantSpeed"),u=1e3*i.get("effect.period"),c=null!=l;c?this.material.set("speed",l/1e3):this.material.set("period",u),this.material[c?"define":"undefine"]("vertex","CONSTANT_SPEED");var h=i.get("polyline");r.trailLength=s,this.material.set("trailLength",s),r.resetOffset(),["position","positionPrev","positionNext"].forEach((function(t){r.attributes[t].value=n.attributes[t].value}));var d=["dist","distAll","start","offset","color"];d.forEach((function(t){r.attributes[t].init(r.vertexCount)})),r.indices=n.indices;var f=[],p=a.get("trailColor"),g=a.get("trailOpacity"),m=null!=p,v=null!=g;this.updateWorldTransform();var y=this.worldTransform.x.len(),_=this.worldTransform.y.len(),b=this.worldTransform.z.len(),x=0,w=0;t.each((function(e){var i=t.getItemLayout(e),a=v?g:Ou(t,e),s=wu(t,e);null==a&&(a=1),f=Ta.parseColor(m?p:s,f),f[3]*=a;for(var l=h?n.getPolylineVertexCount(i):n.getCubicCurveVertexCount(i[0],i[1],i[2],i[3]),d=0,O=[],S=[],T=x;Tx&&(d+=Dd.dist(O,S)),r.attributes.dist.set(T,d),Dd.copy(S,O);w=Math.max(w,d);var M=Math.random()*(c?d:u);for(T=x;T0;this._updateSurfaceMesh(this._surfaceMesh,t,c,f);var p=this._surfaceMesh.material;f?(p.define("WIREFRAME_QUAD"),p.set("wireframeLineWidth",d),p.set("wireframeLineColor",Ta.parseColor(h.get("lineStyle.color")))):p.undefine("WIREFRAME_QUAD"),this._initHandler(t,n),this._updateAnimation(t)},_updateAnimation:function(t){Ta.updateVertexAnimation([["prevPosition","position"],["prevNormal","normal"]],this._prevSurfaceMesh,this._surfaceMesh,t)},_createSurfaceMesh:function(){var t=new Ta.Mesh({geometry:new Ta.Geometry({dynamic:!0,sortTriangles:!0}),shadowDepthMaterial:new Ta.Material({shader:new Ta.Shader(Ta.Shader.source("ecgl.sm.depth.vertex"),Ta.Shader.source("ecgl.sm.depth.fragment"))}),culling:!1,renderOrder:10,renderNormal:!0});return t.geometry.createAttribute("barycentric","float",4),t.geometry.createAttribute("prevPosition","float",3),t.geometry.createAttribute("prevNormal","float",3),Object.assign(t.geometry,_u),t},_initHandler:function(t,e){var n=t.getData(),i=this._surfaceMesh,r=t.coordinateSystem;function a(t,e){for(var n=1/0,r=-1,a=[],o=0;o=0){var l=[];i.geometry.attributes.position.get(s,l);for(var u=r.pointToData(l),c=1/0,h=-1,d=[],f=0;f65535?Uint32Array:Uint16Array)((p-1)*(g-1)*6),w=function(t,e,n){n[1]=t*g+e,n[0]=t*g+e+1,n[3]=(t+1)*g+e+1,n[2]=(t+1)*g+e},O=!1;if(l){var S=[],T=[],M=0;v?c.init(r.vertexCount):c.value=null;for(var A=[[],[],[]],C=[],I=[],D=Hd.create(),L=function(t,e,n){var i=3*e;return n[0]=t[i],n[1]=t[i+1],n[2]=t[i+2],n},E=new Float32Array(o.length),j=new Float32Array(o.length/3*4),P=0;P0){if(Math.floor(s/c)===s/c)return[c,s/c];c--}return c=Math.floor(Math.sqrt(s)),[c,c]},dispose:function(){this.groupGL.removeAll()},remove:function(){this.groupGL.removeAll()}});function Xd(t){t.registerChartView(Wd),t.registerSeriesModel(Gd),t.registerLayout((function(t,e){t.eachSeriesByType("surface",(function(t){var e=t.coordinateSystem;e&&e.type;var n=t.getData(),i=new Float32Array(3*n.count()),r=[NaN,NaN,NaN];if(e&&"cartesian3D"===e.type){var a=e.dimensions,o=a.map((function(e){return t.coordDimToDataDim(e)[0]}));n.each(o,(function(t,a,o,s){var l;l=n.hasValue(s)?e.dataToPoint([t,a,o]):r,i[3*s]=l[0],i[3*s+1]=l[1],i[3*s+2]=l[2]}))}n.setLayout("points",i)}))}))}function Zd(t,e){for(var n=[],i=0;i "+p)),h++)}var g=a["m"].createDimensions(t,{coordDimensions:["value"]});l=new a["e"](g,n),l.initData(t);var m=new a["e"](["value"],n);return m.initData(c,u),r&&r(l,m),lf({mainData:l,struct:o,structAttr:"graph",datas:{node:l,edge:m},datasAttr:{node:"data",edge:"edgeData"}}),o.update(),o},cf=a["g"].extend({type:"series.graphGL",visualStyleAccessPath:"itemStyle",hasSymbolVisual:!0,init:function(t){cf.superApply(this,"init",arguments),this.legendDataProvider=function(){return this._categoriesData},this._updateCategoriesData()},mergeOption:function(t){cf.superApply(this,"mergeOption",arguments),this._updateCategoriesData()},getFormattedLabel:function(t,e,n,i){var r=Sh.getFormattedLabel(this,t,e,n,i);if(null==r){var a=this.getData(),o=a.dimensions[a.dimensions.length-1];r=a.get(o,t)}return r},getInitialData:function(t,e){var n=t.edges||t.links||[],i=t.data||t.nodes||[],r=this;if(i&&n)return uf(i,n,this,!0,a).data;function a(t,n){t.wrapMethod("getItemModel",(function(t){const e=r._categoriesModels,n=t.getShallow("category"),i=e[n];return i&&(i.parentModel=t.parentModel,t.parentModel=i),t}));const i=e.getModel([]).getModel;function a(t,e){const n=i.call(this,t,e);return n.resolveParentPath=o,n}function o(t){if(t&&("label"===t[0]||"label"===t[1])){const e=t.slice();return"label"===t[0]?e[0]="edgeLabel":"label"===t[1]&&(e[1]="edgeLabel"),e}return t}n.wrapMethod("getItemModel",(function(t){return t.resolveParentPath=o,t.getModel=a,t}))}},getGraph:function(){return this.getData().graph},getEdgeData:function(){return this.getGraph().edgeData},getCategoriesData:function(){return this._categoriesData},formatTooltip:function(t,e,n){if("edge"===n){var i=this.getData(),r=this.getDataParams(t,n),o=i.graph.getEdgeByIndex(t),s=i.getName(o.node1.dataIndex),l=i.getName(o.node2.dataIndex),u=[];return null!=s&&u.push(s),null!=l&&u.push(l),u=a["i"].encodeHTML(u.join(" > ")),r.value&&(u+=" : "+a["i"].encodeHTML(r.value)),u}return cf.superApply(this,"formatTooltip",arguments)},_updateCategoriesData:function(){var t=(this.option.categories||[]).map((function(t){return null!=t.value?t:Object.assign({value:0},t)})),e=new a["e"](["value"],this);e.initData(t),this._categoriesData=e,this._categoriesModels=e.mapArray((function(t){return e.getItemModel(t,!0)}))},setView:function(t){null!=t.zoom&&(this.option.zoom=t.zoom),null!=t.offset&&(this.option.offset=t.offset)},setNodePosition:function(t){for(var e=0;e65535?this.indices instanceof Uint16Array&&(this.indices=new Uint32Array(this.indices)):this.indices instanceof Uint32Array&&(this.indices=new Uint16Array(this.indices)))},setTriangleCount:function(t){this.triangleCount!==t&&(this.indices=0===t?null:this.vertexCount>65535?new Uint32Array(3*t):new Uint16Array(3*t))},_getCubicCurveApproxStep:function(t,e,n,i){var r=df.dist(t,e)+df.dist(n,e)+df.dist(i,n),a=1/(r+1)*this.segmentScale;return a},getCubicCurveVertexCount:function(t,e,n,i){var r=this._getCubicCurveApproxStep(t,e,n,i),a=Math.ceil(1/r);return this.useNativeLine?2*a:2*a+2},getCubicCurveTriangleCount:function(t,e,n,i){var r=this._getCubicCurveApproxStep(t,e,n,i),a=Math.ceil(1/r);return this.useNativeLine?0:2*a},getLineVertexCount:function(){return this.getPolylineVertexCount(ff)},getLineTriangleCount:function(){return this.getPolylineTriangleCount(ff)},getPolylineVertexCount:function(t){var e;if("number"===typeof t)e=t;else{var n="number"!==typeof t[0];e=n?t.length:t.length/2}return this.useNativeLine?2*(e-1):2*(e-1)+2},getPolylineTriangleCount:function(t){var e;if("number"===typeof t)e=t;else{var n="number"!==typeof t[0];e=n?t.length:t.length/2}return this.useNativeLine?0:2*(e-1)},addCubicCurve:function(t,e,n,i,r,a){null==a&&(a=1);var o=t[0],s=t[1],l=e[0],u=e[1],c=n[0],h=n[1],d=i[0],f=i[1],p=this._getCubicCurveApproxStep(t,e,n,i),g=p*p,m=g*p,v=3*p,y=3*g,_=6*g,b=6*m,x=o-2*l+c,w=s-2*u+h,O=3*(l-c)-o+d,S=3*(u-h)-s+f,T=o,M=s,A=(l-o)*v+x*y+O*m,C=(u-s)*v+w*y+S*m,I=x*_+O*b,D=w*_+S*b,L=O*b,E=S*b,j=0,P=0,N=Math.ceil(1/p),R=new Float32Array(3*(N+1)),k=(R=[],0);for(P=0;P1&&(T=A>0?Math.min(T,d):Math.max(T,d),M=C>0?Math.min(M,f):Math.max(M,f));this.addPolyline(R,r,a)},addLine:function(t,e,n,i){this.addPolyline([t,e],n,i)},addPolyline:function(){var t=df.create(),e=df.create(),n=df.create(),i=df.create(),r=[],a=[],o=[];return function(s,l,u,c,h){if(s.length){var d="number"!==typeof s[0];if(null==h&&(h=d?s.length:s.length/2),!(h<2)){null==c&&(c=0),null==u&&(u=1),this._itemVertexOffsets.push(this._vertexOffset);for(var f,p=d?"number"!==typeof l[0]:l.length/4===h,g=this.attributes.position,m=this.attributes.color,v=this.attributes.offset,y=this.attributes.normal,_=this.indices,b=this._vertexOffset,x=0;x1&&(g.copy(b,b-1),m.copy(b,b-1),b++);else{var S;if(x0){df.sub(t,r,o),df.sub(e,a,r),df.normalize(t,t),df.normalize(e,e),df.add(i,t,e),df.normalize(i,i);var T=u/2*Math.min(1/df.dot(t,i),2);n[0]=-i[1],n[1]=i[0],S=T}else df.sub(t,a,r),df.normalize(t,t),n[0]=-t[1],n[1]=t[0],S=u/2}else df.sub(t,r,o),df.normalize(t,t),n[0]=-t[1],n[1]=t[0],S=u/2;y.set(b,n),y.set(b+1,n),v.set(b,S),v.set(b+1,-S),df.copy(o,r),g.set(b,r),g.set(b+1,r),m.set(b,f),m.set(b+1,f),b+=2}if(this.useNativeLine)m.set(b,f),g.set(b,r),b++;else if(x>0){var M=3*this._faceOffset;_=this.indices;_[M]=b-4,_[M+1]=b-3,_[M+2]=b-2,_[M+3]=b-3,_[M+4]=b-1,_[M+5]=b-2,this._faceOffset+=2}}this._vertexOffset=b}}}}(),setItemColor:function(t,e){for(var n=this._itemVertexOffsets[t],i=t 0.0) {\n float factor = 0.0;\n if (preventOverlap) {\n float d = sqrt(d2);\n d = d - n0.w - n1.w;\n if (d > 0.0) {\n factor = scaling * n0.z * n1.z / (d * d);\n }\n else if (d < 0.0) {\n factor = scaling * 100.0 * n0.z * n1.z;\n }\n }\n else {\n factor = scaling * n0.z * n1.z / d2;\n }\n force += dir * factor;\n }\n }\n\n vec2 dir = gravityCenter - n0.xy;\n float d = 1.0;\n if (!strongGravityMode) {\n d = length(dir);\n }\n\n force += dir * n0.z * gravity / (d + 1.0);\n\n gl_FragColor = vec4(force, 0.0, 1.0);\n}\n@end\n\n@export ecgl.forceAtlas2.updateEdgeAttraction.vertex\n\nattribute vec2 node1;\nattribute vec2 node2;\nattribute float weight;\n\nuniform sampler2D positionTex;\nuniform float edgeWeightInfluence;\nuniform bool preventOverlap;\nuniform bool linLogMode;\n\nuniform vec2 windowSize: WINDOW_SIZE;\n\nvarying vec2 v_Force;\n\nvoid main() {\n\n vec4 n0 = texture2D(positionTex, node1);\n vec4 n1 = texture2D(positionTex, node2);\n\n vec2 dir = n1.xy - n0.xy;\n float d = length(dir);\n float w;\n if (edgeWeightInfluence == 0.0) {\n w = 1.0;\n }\n else if (edgeWeightInfluence == 1.0) {\n w = weight;\n }\n else {\n w = pow(weight, edgeWeightInfluence);\n }\n vec2 offset = vec2(1.0 / windowSize.x, 1.0 / windowSize.y);\n vec2 scale = vec2((windowSize.x - 1.0) / windowSize.x, (windowSize.y - 1.0) / windowSize.y);\n vec2 pos = node1 * scale * 2.0 - 1.0;\n gl_Position = vec4(pos + offset, 0.0, 1.0);\n gl_PointSize = 1.0;\n\n float factor;\n if (preventOverlap) {\n d = d - n1.w - n0.w;\n }\n if (d <= 0.0) {\n v_Force = vec2(0.0);\n return;\n }\n\n if (linLogMode) {\n factor = w * log(d) / d;\n }\n else {\n factor = w;\n }\n v_Force = dir * factor;\n}\n@end\n\n@export ecgl.forceAtlas2.updateEdgeAttraction.fragment\n\nvarying vec2 v_Force;\n\nvoid main() {\n gl_FragColor = vec4(v_Force, 0.0, 0.0);\n}\n@end\n\n@export ecgl.forceAtlas2.calcWeightedSum.vertex\n\nattribute vec2 node;\n\nvarying vec2 v_NodeUv;\n\nvoid main() {\n\n v_NodeUv = node;\n gl_Position = vec4(0.0, 0.0, 0.0, 1.0);\n gl_PointSize = 1.0;\n}\n@end\n\n@export ecgl.forceAtlas2.calcWeightedSum.fragment\n\nvarying vec2 v_NodeUv;\n\nuniform sampler2D positionTex;\nuniform sampler2D forceTex;\nuniform sampler2D forcePrevTex;\n\nvoid main() {\n vec2 force = texture2D(forceTex, v_NodeUv).rg;\n vec2 forcePrev = texture2D(forcePrevTex, v_NodeUv).rg;\n\n float mass = texture2D(positionTex, v_NodeUv).z;\n float swing = length(force - forcePrev) * mass;\n float traction = length(force + forcePrev) * 0.5 * mass;\n\n gl_FragColor = vec4(swing, traction, 0.0, 0.0);\n}\n@end\n\n@export ecgl.forceAtlas2.calcGlobalSpeed\n\nuniform sampler2D globalSpeedPrevTex;\nuniform sampler2D weightedSumTex;\nuniform float jitterTolerence;\n\nvoid main() {\n vec2 weightedSum = texture2D(weightedSumTex, vec2(0.5)).xy;\n float prevGlobalSpeed = texture2D(globalSpeedPrevTex, vec2(0.5)).x;\n float globalSpeed = jitterTolerence * jitterTolerence\n * weightedSum.y / weightedSum.x;\n if (prevGlobalSpeed > 0.0) {\n globalSpeed = min(globalSpeed / prevGlobalSpeed, 1.5) * prevGlobalSpeed;\n }\n gl_FragColor = vec4(globalSpeed, 0.0, 0.0, 1.0);\n}\n@end\n\n@export ecgl.forceAtlas2.updatePosition\n\nuniform sampler2D forceTex;\nuniform sampler2D forcePrevTex;\nuniform sampler2D positionTex;\nuniform sampler2D globalSpeedTex;\n\nvarying vec2 v_Texcoord;\n\nvoid main() {\n vec2 force = texture2D(forceTex, v_Texcoord).xy;\n vec2 forcePrev = texture2D(forcePrevTex, v_Texcoord).xy;\n vec4 node = texture2D(positionTex, v_Texcoord);\n\n float globalSpeed = texture2D(globalSpeedTex, vec2(0.5)).r;\n float swing = length(force - forcePrev);\n float speed = 0.1 * globalSpeed / (0.1 + globalSpeed * sqrt(swing));\n\n float df = length(force);\n if (df > 0.0) {\n speed = min(df * speed, 10.0) / df;\n\n gl_FragColor = vec4(node.xy + speed * force, node.zw);\n }\n else {\n gl_FragColor = node;\n }\n}\n@end\n\n@export ecgl.forceAtlas2.edges.vertex\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\n\nattribute vec2 node;\nattribute vec4 a_Color : COLOR;\nvarying vec4 v_Color;\n\nuniform sampler2D positionTex;\n\nvoid main()\n{\n gl_Position = worldViewProjection * vec4(\n texture2D(positionTex, node).xy, -10.0, 1.0\n );\n v_Color = a_Color;\n}\n@end\n\n@export ecgl.forceAtlas2.edges.fragment\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\nvarying vec4 v_Color;\nvoid main() {\n gl_FragColor = color * v_Color;\n}\n@end";Ta.Shader.import(mf);var vf={repulsionByDegree:!0,linLogMode:!1,strongGravityMode:!1,gravity:1,scaling:1,edgeWeightInfluence:1,jitterTolerence:.1,preventOverlap:!1,dissuadeHubs:!1,gravityCenter:null};function yf(t){var e={type:Ta.Texture.FLOAT,minFilter:Ta.Texture.NEAREST,magFilter:Ta.Texture.NEAREST};this._positionSourceTex=new Ta.Texture2D(e),this._positionSourceTex.flipY=!1,this._positionTex=new Ta.Texture2D(e),this._positionPrevTex=new Ta.Texture2D(e),this._forceTex=new Ta.Texture2D(e),this._forcePrevTex=new Ta.Texture2D(e),this._weightedSumTex=new Ta.Texture2D(e),this._weightedSumTex.width=this._weightedSumTex.height=1,this._globalSpeedTex=new Ta.Texture2D(e),this._globalSpeedPrevTex=new Ta.Texture2D(e),this._globalSpeedTex.width=this._globalSpeedTex.height=1,this._globalSpeedPrevTex.width=this._globalSpeedPrevTex.height=1,this._nodeRepulsionPass=new vr({fragment:Ta.Shader.source("ecgl.forceAtlas2.updateNodeRepulsion")}),this._positionPass=new vr({fragment:Ta.Shader.source("ecgl.forceAtlas2.updatePosition")}),this._globalSpeedPass=new vr({fragment:Ta.Shader.source("ecgl.forceAtlas2.calcGlobalSpeed")}),this._copyPass=new vr({fragment:Ta.Shader.source("clay.compositor.output")});var n=function(t){t.blendEquation(t.FUNC_ADD),t.blendFunc(t.ONE,t.ONE)};this._edgeForceMesh=new Ta.Mesh({geometry:new Ta.Geometry({attributes:{node1:new Ta.Geometry.Attribute("node1","float",2),node2:new Ta.Geometry.Attribute("node2","float",2),weight:new Ta.Geometry.Attribute("weight","float",1)},dynamic:!0,mainAttribute:"node1"}),material:new Ta.Material({transparent:!0,shader:Ta.createShader("ecgl.forceAtlas2.updateEdgeAttraction"),blend:n,depthMask:!1,depthText:!1}),mode:Ta.Mesh.POINTS}),this._weightedSumMesh=new Ta.Mesh({geometry:new Ta.Geometry({attributes:{node:new Ta.Geometry.Attribute("node","float",2)},dynamic:!0,mainAttribute:"node"}),material:new Ta.Material({transparent:!0,shader:Ta.createShader("ecgl.forceAtlas2.calcWeightedSum"),blend:n,depthMask:!1,depthText:!1}),mode:Ta.Mesh.POINTS}),this._framebuffer=new pi({depthBuffer:!1}),this._dummyCamera=new Ta.OrthographicCamera({left:-1,right:1,top:1,bottom:-1,near:0,far:100}),this._globalSpeed=0}yf.prototype.updateOption=function(t){for(var e in vf)this[e]=vf[e];var n=this._nodes.length;if(this.jitterTolerence=n>5e4?10:n>5e3?1:.1,this.scaling=n>100?2:10,t)for(var e in vf)null!=t[e]&&(this[e]=t[e]);if(this.repulsionByDegree)for(var i=this._positionSourceTex.pixels,r=0;rt},yf.prototype._swapTexture=function(){var t=this._positionPrevTex;this._positionPrevTex=this._positionTex,this._positionTex=t;t=this._forcePrevTex;this._forcePrevTex=this._forceTex,this._forceTex=t;t=this._globalSpeedPrevTex;this._globalSpeedPrevTex=this._globalSpeedTex,this._globalSpeedTex=t},yf.prototype._initFromSource=function(t){this._framebuffer.attach(this._positionPrevTex),this._framebuffer.bind(t),this._copyPass.setUniform("texture",this._positionSourceTex),this._copyPass.render(t),t.gl.clearColor(0,0,0,0),this._framebuffer.attach(this._forcePrevTex),t.gl.clear(t.gl.COLOR_BUFFER_BIT),this._framebuffer.attach(this._globalSpeedPrevTex),t.gl.clear(t.gl.COLOR_BUFFER_BIT),this._framebuffer.unbind(t)},yf.prototype._resize=function(t,e){["_positionSourceTex","_positionTex","_positionPrevTex","_forceTex","_forcePrevTex"].forEach((function(n){this[n].width=t,this[n].height=e,this[n].dirty()}),this)},yf.prototype.dispose=function(t){this._framebuffer.dispose(t),this._copyPass.dispose(t),this._nodeRepulsionPass.dispose(t),this._positionPass.dispose(t),this._globalSpeedPass.dispose(t),this._edgeForceMesh.geometry.dispose(t),this._weightedSumMesh.geometry.dispose(t),this._positionSourceTex.dispose(t),this._positionTex.dispose(t),this._positionPrevTex.dispose(t),this._forceTex.dispose(t),this._forcePrevTex.dispose(t),this._weightedSumTex.dispose(t),this._globalSpeedTex.dispose(t),this._globalSpeedPrevTex.dispose(t)};var _f=yf;function bf(){var t={create:function(){return new Float32Array(2)},dist:function(t,e){var n=e[0]-t[0],i=e[1]-t[1];return Math.sqrt(n*n+i*i)},len:function(t){var e=t[0],n=t[1];return Math.sqrt(e*e+n*n)},scaleAndAdd:function(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t},scale:function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t},add:function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t},sub:function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t},normalize:function(t,e){var n=e[0],i=e[1],r=n*n+i*i;return r>0&&(r=1/Math.sqrt(r),t[0]=e[0]*r,t[1]=e[1]*r),t},negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t},set:function(t,e,n){return t[0]=e,t[1]=n,t}};function e(){this.subRegions=[],this.nSubRegions=0,this.node=null,this.mass=0,this.centerOfMass=null,this.bbox=new Float32Array(4),this.size=0}var n=e.prototype;function i(){this.position=new Float32Array(2),this.force=t.create(),this.forcePrev=t.create(),this.mass=1,this.inDegree=0,this.outDegree=0}function r(t,e){this.source=t,this.target=e,this.weight=1}function a(){this.autoSettings=!0,this.barnesHutOptimize=!0,this.barnesHutTheta=1.5,this.repulsionByDegree=!0,this.linLogMode=!1,this.strongGravityMode=!1,this.gravity=1,this.scaling=1,this.edgeWeightInfluence=1,this.jitterTolerence=.1,this.preventOverlap=!1,this.dissuadeHubs=!1,this.rootRegion=new e,this.rootRegion.centerOfMass=t.create(),this.nodes=[],this.edges=[],this.bbox=new Float32Array(4),this.gravityCenter=null,this._massArr=null,this._swingingArr=null,this._sizeArr=null,this._globalSpeed=0}n.beforeUpdate=function(){for(var t=0;t=t&&this.bbox[1]<=e&&this.bbox[3]>=e},n.setBBox=function(t,e,n,i){this.bbox[0]=t,this.bbox[1]=e,this.bbox[2]=n,this.bbox[3]=i,this.size=(n-t+i-e)/2},n._newSubRegion=function(){var t=this.subRegions[this.nSubRegions];return t||(t=new e,this.subRegions[this.nSubRegions]=t),this.nSubRegions++,t},n._addNodeToSubRegion=function(t){var e=this.findSubRegion(t.position[0],t.position[1]),n=this.bbox;if(!e){var i=(n[0]+n[2])/2,r=(n[1]+n[3])/2,a=(n[2]-n[0])/2,o=(n[3]-n[1])/2,s=t.position[0]>=i?1:0,l=t.position[1]>=r?1:0;e=this._newSubRegion();e.setBBox(s*a+n[0],l*o+n[1],(s+1)*a+n[0],(l+1)*o+n[1])}e.addNode(t)},n._updateCenterOfMass=function(t){null==this.centerOfMass&&(this.centerOfMass=new Float32Array(2));var e=this.centerOfMass[0]*this.mass,n=this.centerOfMass[1]*this.mass;e+=t.position[0]*t.mass,n+=t.position[1]*t.mass,this.mass+=t.mass,this.centerOfMass[0]=e/this.mass,this.centerOfMass[1]=n/this.mass};var o=a.prototype;o.initNodes=function(t,e,n){var r=e.length;this.nodes.length=0;for(var a="undefined"!=typeof n,o=0;o0&&(this.strongGravityMode?this.applyNodeStrongGravity(r):this.applyNodeGravity(r))}for(n=0;n0&&(d=Math.min(d/this._globalSpeed,1.5)*this._globalSpeed),this._globalSpeed=d;for(n=0;n0&&(f=Math.min(p*f,10)/p,t.scaleAndAdd(i.position,i.position,i.force,f))}},o.applyRegionToNodeRepulsion=function(){var e=t.create();return function(n,i){if(n.node)this.applyNodeToNodeRepulsion(n.node,i,!0);else{t.sub(e,i.position,n.centerOfMass);var r=e[0]*e[0]+e[1]*e[1];if(r>this.barnesHutTheta*n.size*n.size){var a=this.scaling*i.mass*n.mass/r;t.scaleAndAdd(i.force,i.force,e,a)}else for(var o=0;o0)o=this.scaling*n.mass*i.mass/(s*s);else{if(!(s<0))return;o=100*this.scaling*n.mass*i.mass}}else o=this.scaling*n.mass*i.mass/a;t.scaleAndAdd(n.force,n.force,e,o),t.scaleAndAdd(i.force,i.force,e,-o)}}}}(),o.applyEdgeAttraction=function(){var e=t.create();return function(n){var i=n.source,r=n.target;t.sub(e,i.position,r.position);var a,o,s=t.len(e);a=0===this.edgeWeightInfluence?1:1===this.edgeWeightInfluence?n.weight:Math.pow(n.weight,this.edgeWeightInfluence),this.preventOverlap&&(s=s-i.size-r.size,s<=0)||(o=this.linLogMode?-a*Math.log(s+1)/(s+1):-a,t.scaleAndAdd(i.force,i.force,e,o),t.scaleAndAdd(r.force,r.force,e,-o))}}(),o.applyNodeGravity=function(){var e=t.create();return function(n){t.sub(e,this.gravityCenter,n.position);var i=t.len(e);t.scaleAndAdd(n.force,n.force,e,this.gravity*n.mass/(i+1))}}(),o.applyNodeStrongGravity=function(){var e=t.create();return function(n){t.sub(e,this.gravityCenter,n.position),t.scaleAndAdd(n.force,n.force,e,this.gravity*n.mass)}}(),o.updateBBox=function(){for(var t=1/0,e=1/0,n=-1/0,i=-1/0,r=0;r5e4?10:a>5e3?1:.1,e.scaling=a>100?2:10,e.barnesHutOptimize=a>1e3,t)for(var n in Of)null!=t[n]&&(e[n]=t[n]);if(!e.gravityCenter){for(var o=[1/0,1/0],s=[-1/0,-1/0],l=0;lt},Sf.prototype.getNodePosition=function(t,e){if(e||(e=new Float32Array(2*this._nodes.length)),this._positionArr)for(var n=0;n0?1.1:.9,a=Math.max(Math.min(this._zoom*r,this.maxZoom),this.minZoom);r=a/this._zoom;var o=this._convertPos(n,i),s=(o.x-this._dx)*(r-1),l=(o.y-this._dy)*(r-1);this._dx-=s,this._dy-=l,this._zoom=a,this._needsUpdate=!0}}},dispose:function(){var t=this.zr;t.off("mousedown",this._mouseDownHandler),t.off("mousemove",this._mouseMoveHandler),t.off("mouseup",this._mouseUpHandler),t.off("mousewheel",this._mouseWheelHandler),t.off("globalout",this._mouseUpHandler),t.animation.off("frame",this._update)}}),Af=Mf,Cf="@export ecgl.lines2D.vertex\n\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\n\nattribute vec2 position: POSITION;\nattribute vec4 a_Color : COLOR;\nvarying vec4 v_Color;\n\n#ifdef POSITIONTEXTURE_ENABLED\nuniform sampler2D positionTexture;\n#endif\n\nvoid main()\n{\n gl_Position = worldViewProjection * vec4(position, -10.0, 1.0);\n\n v_Color = a_Color;\n}\n\n@end\n\n@export ecgl.lines2D.fragment\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\n\nvarying vec4 v_Color;\n\nvoid main()\n{\n gl_FragColor = color * v_Color;\n}\n@end\n\n\n@export ecgl.meshLines2D.vertex\n\nattribute vec2 position: POSITION;\nattribute vec2 normal;\nattribute float offset;\nattribute vec4 a_Color : COLOR;\n\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\nuniform vec4 viewport : VIEWPORT;\n\nvarying vec4 v_Color;\nvarying float v_Miter;\n\nvoid main()\n{\n vec4 p2 = worldViewProjection * vec4(position + normal, -10.0, 1.0);\n gl_Position = worldViewProjection * vec4(position, -10.0, 1.0);\n\n p2.xy /= p2.w;\n gl_Position.xy /= gl_Position.w;\n\n vec2 N = normalize(p2.xy - gl_Position.xy);\n gl_Position.xy += N * offset / viewport.zw * 2.0;\n\n gl_Position.xy *= gl_Position.w;\n\n v_Color = a_Color;\n}\n@end\n\n\n@export ecgl.meshLines2D.fragment\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\n\nvarying vec4 v_Color;\nvarying float v_Miter;\n\nvoid main()\n{\n gl_FragColor = color * v_Color;\n}\n\n@end",If=to.vec2;Ta.Shader.import(Cf);var Df=1,Lf=a["b"].extend({type:"graphGL",__ecgl__:!0,init:function(t,e){this.groupGL=new Ta.Node,this.viewGL=new dl("orthographic"),this.viewGL.camera.left=this.viewGL.camera.right=0,this.viewGL.add(this.groupGL),this._pointsBuilder=new ad(!0,e),this._forceEdgesMesh=new Ta.Mesh({material:new Ta.Material({shader:Ta.createShader("ecgl.forceAtlas2.edges"),transparent:!0,depthMask:!1,depthTest:!1}),$ignorePicking:!0,geometry:new Ta.Geometry({attributes:{node:new Ta.Geometry.Attribute("node","float",2),color:new Ta.Geometry.Attribute("color","float",4,"COLOR")},dynamic:!0,mainAttribute:"node"}),renderOrder:-1,mode:Ta.Mesh.LINES}),this._edgesMesh=new Ta.Mesh({material:new Ta.Material({shader:Ta.createShader("ecgl.meshLines2D"),transparent:!0,depthMask:!1,depthTest:!1}),$ignorePicking:!0,geometry:new gf({useNativeLine:!1,dynamic:!0}),renderOrder:-1,culling:!1}),this._layoutId=0,this._control=new Af({zr:e.getZr(),viewGL:this.viewGL}),this._control.setTarget(this.groupGL),this._control.init(),this._clickHandler=this._clickHandler.bind(this)},render:function(t,e,n){this.groupGL.add(this._pointsBuilder.rootNode),this._model=t,this._api=n,this._initLayout(t,e,n),this._pointsBuilder.update(t,e,n),this._forceLayoutInstance instanceof _f||this.groupGL.remove(this._forceEdgesMesh),this._updateCamera(t,n),this._control.off("update"),this._control.on("update",(function(){n.dispatchAction({type:"graphGLRoam",seriesId:t.id,zoom:this._control.getZoom(),offset:this._control.getOffset()}),this._pointsBuilder.updateView(this.viewGL.camera)}),this),this._control.setZoom(Pr.firstNotNull(t.get("zoom"),1)),this._control.setOffset(t.get("offset")||[0,0]);var i=this._pointsBuilder.getPointsMesh();if(i.off("mousemove",this._mousemoveHandler),i.off("mouseout",this._mouseOutHandler,this),n.getZr().off("click",this._clickHandler),this._pointsBuilder.highlightOnMouseover=!0,t.get("focusNodeAdjacency")){var r=t.get("focusNodeAdjacencyOn");"click"===r?n.getZr().on("click",this._clickHandler):"mouseover"===r&&(i.on("mousemove",this._mousemoveHandler,this),i.on("mouseout",this._mouseOutHandler,this),this._pointsBuilder.highlightOnMouseover=!1)}this._lastMouseOverDataIndex=-1},_clickHandler:function(t){if(!this._layouting){var e=this._pointsBuilder.getPointsMesh().dataIndex;e>=0?this._api.dispatchAction({type:"graphGLFocusNodeAdjacency",seriesId:this._model.id,dataIndex:e}):this._api.dispatchAction({type:"graphGLUnfocusNodeAdjacency",seriesId:this._model.id})}},_mousemoveHandler:function(t){if(!this._layouting){var e=this._pointsBuilder.getPointsMesh().dataIndex;e>=0?e!==this._lastMouseOverDataIndex&&this._api.dispatchAction({type:"graphGLFocusNodeAdjacency",seriesId:this._model.id,dataIndex:e}):this._mouseOutHandler(t),this._lastMouseOverDataIndex=e}},_mouseOutHandler:function(t){this._layouting||(this._api.dispatchAction({type:"graphGLUnfocusNodeAdjacency",seriesId:this._model.id}),this._lastMouseOverDataIndex=-1)},_updateForceEdgesGeometry:function(t,e){var n=this._forceEdgesMesh.geometry,i=e.getEdgeData(),r=0,a=this._forceLayoutInstance,o=2*i.count();n.attributes.node.init(o),n.attributes.color.init(o),i.each((function(e){var o=t[e];n.attributes.node.set(r,a.getNodeUV(o.node1)),n.attributes.node.set(r+1,a.getNodeUV(o.node2));var s=wu(i,o.dataIndex),l=Ta.parseColor(s);l[3]*=Pr.firstNotNull(Ou(i,o.dataIndex),1),n.attributes.color.set(r,l),n.attributes.color.set(r+1,l),r+=2})),n.dirty()},_updateMeshLinesGeometry:function(){var t=this._model.getEdgeData(),e=this._edgesMesh.geometry,n=(t=this._model.getEdgeData(),this._model.getData().getLayout("points"));e.resetOffset(),e.setVertexCount(t.count()*e.getLineVertexCount()),e.setTriangleCount(t.count()*e.getLineTriangleCount());var i=[],r=[],a=["lineStyle","width"];this._originalEdgeColors=new Float32Array(4*t.count()),this._edgeIndicesMap=new Float32Array(t.count()),t.each((function(o){var s=t.graph.getEdgeByIndex(o),l=2*s.node1.dataIndex,u=2*s.node2.dataIndex;i[0]=n[l],i[1]=n[l+1],r[0]=n[u],r[1]=n[u+1];var c=wu(t,s.dataIndex),h=Ta.parseColor(c);h[3]*=Pr.firstNotNull(Ou(t,s.dataIndex),1);var d=t.getItemModel(s.dataIndex),f=Pr.firstNotNull(d.get(a),1)*this._api.getDevicePixelRatio();e.addLine(i,r,h,f);for(var p=0;p<4;p++)this._originalEdgeColors[4*s.dataIndex+p]=h[p];this._edgeIndicesMap[s.dataIndex]=o}),this),e.dirty()},_updateForceNodesGeometry:function(t){for(var e=this._pointsBuilder.getPointsMesh(),n=[],i=0;i=f&&(l._syncNodePosition(t),d=0),n.getZr().refresh(),Object(Ma["a"])((function(){p(e)}))}))};Object(Ma["a"])((function(){l._forceLayoutInstanceToDispose&&(l._forceLayoutInstanceToDispose.dispose(r.layer.renderer),l._forceLayoutInstanceToDispose=null),p(u)})),this._layouting=!0}}},stopLayout:function(t,e,n,i){i&&null!=i.from&&i.from!==this.uid||(this._layoutId=0,this.groupGL.remove(this._forceEdgesMesh),this.groupGL.add(this._edgesMesh),this._forceLayoutInstance&&this.viewGL.layer&&(i&&i.beforeLayout||(this._syncNodePosition(t),this._updateAfterLayout(t,e,n)),this._api.getZr().refresh(),this._layouting=!1))},_syncNodePosition:function(t){var e=this._forceLayoutInstance.getNodePosition(this.viewGL.layer.renderer);t.getData().setLayout("points",e),t.setNodePosition(e)},_updateAfterLayout:function(t,e,n){this._updateMeshLinesGeometry(),this._pointsBuilder.removePositionTexture(),this._pointsBuilder.updateLayout(t,e,n),this._pointsBuilder.updateView(this.viewGL.camera),this._pointsBuilder.updateLabels(),this._pointsBuilder.showLabels()},focusNodeAdjacency:function(t,e,n,i){var r=this._model.getData();this._downplayAll();var a=i.dataIndex,o=r.graph,s=[],l=o.getNodeByIndex(a);s.push(l),l.edges.forEach((function(t){t.dataIndex<0||(t.node1!==l&&s.push(t.node1),t.node2!==l&&s.push(t.node2))}),this),this._pointsBuilder.fadeOutAll(.05),this._fadeOutEdgesAll(.05),s.forEach((function(t){this._pointsBuilder.highlight(r,t.dataIndex)}),this),this._pointsBuilder.updateLabels(s.map((function(t){return t.dataIndex})));var u=[];l.edges.forEach((function(t){t.dataIndex>=0&&(this._highlightEdge(t.dataIndex),u.push(t))}),this),this._focusNodes=s,this._focusEdges=u},unfocusNodeAdjacency:function(t,e,n,i){this._downplayAll(),this._pointsBuilder.fadeInAll(),this._fadeInEdgesAll(),this._pointsBuilder.updateLabels()},_highlightEdge:function(t){var e=this._model.getEdgeData().getItemModel(t),n=Ta.parseColor(e.get("emphasis.lineStyle.color")||e.get("lineStyle.color")),i=Pr.firstNotNull(e.get("emphasis.lineStyle.opacity"),e.get("lineStyle.opacity"),1);n[3]*=i,this._edgesMesh.geometry.setItemColor(this._edgeIndicesMap[t],n)},_downplayAll:function(){this._focusNodes&&this._focusNodes.forEach((function(t){this._pointsBuilder.downplay(this._model.getData(),t.dataIndex)}),this),this._focusEdges&&this._focusEdges.forEach((function(t){this._downplayEdge(t.dataIndex)}),this)},_downplayEdge:function(t){var e=this._getColor(t,[]);this._edgesMesh.geometry.setItemColor(this._edgeIndicesMap[t],e)},_setEdgeFade:function(){var t=[];return function(e,n){this._getColor(e,t),t[3]*=n,this._edgesMesh.geometry.setItemColor(this._edgeIndicesMap[e],t)}}(),_getColor:function(t,e){for(var n=0;n<4;n++)e[n]=this._originalEdgeColors[4*t+n];return e},_fadeOutEdgesAll:function(t){var e=this._model.getData().graph;e.eachEdge((function(e){this._setEdgeFade(e.dataIndex,t)}),this)},_fadeInEdgesAll:function(){this._fadeOutEdgesAll(1)},_updateCamera:function(t,e){this.viewGL.setViewport(0,0,e.getWidth(),e.getHeight(),e.getDevicePixelRatio());for(var n=this.viewGL.camera,i=t.getData(),r=i.getLayout("points"),a=If.create(1/0,1/0),o=If.create(-1/0,-1/0),s=[],l=0;ln.left&&cn.top)){var h=Math.max(o[0]-a[0],10),d=h/e.getWidth()*e.getHeight();h*=1.4,d*=1.4,a[0]-=.2*h,n.left=a[0],n.top=u-d/2,n.bottom=u+d/2,n.right=h+a[0],n.near=0,n.far=100}},dispose:function(){var t=this.viewGL.layer.renderer;this._forceLayoutInstance&&this._forceLayoutInstance.dispose(t),this.groupGL.removeAll(),this._layoutId=-1,this._pointsBuilder.dispose()},remove:function(){this.groupGL.removeAll(),this._control.dispose()}});function Ef(t){return t instanceof Array||(t=[t,t]),t}function jf(t){function e(){}t.registerChartView(Lf),t.registerSeriesModel(hf),t.registerVisual((function(t){const e={};t.eachSeriesByType("graphGL",(function(t){var n=t.getCategoriesData(),i=t.getData(),r={};n.each((function(i){var a=n.getName(i);r["ec-"+a]=i;var o=n.getItemModel(i),s=o.getModel("itemStyle").getItemStyle();s.fill||(s.fill=t.getColorFromPalette(a,e)),n.setItemVisual(i,"style",s);var l=["symbol","symbolSize","symbolKeepAspect"];for(let t=0;t65535?new Uint32Array(3*i):new Uint16Array(3*i))},addLine:function(t){var e=this._vertexOffset;this.attributes.position.set(e,[t[0],t[1],1]),this.attributes.position.set(e+1,[t[0],t[1],-1]),this.attributes.position.set(e+2,[t[0],t[1],2]),this.attributes.position.set(e+3,[t[0],t[1],-2]),this.setTriangleIndices(this._faceOffset++,[e,e+1,e+2]),this.setTriangleIndices(this._faceOffset++,[e+1,e+2,e+3]),this._vertexOffset+=4}}),Rf=Nf,kf="@export ecgl.vfParticle.particle.fragment\n\nuniform sampler2D particleTexture;\nuniform sampler2D spawnTexture;\nuniform sampler2D velocityTexture;\n\nuniform float deltaTime;\nuniform float elapsedTime;\n\nuniform float speedScaling : 1.0;\n\nuniform vec2 textureSize;\nuniform vec4 region : [0, 0, 1, 1];\nuniform float firstFrameTime;\n\nvarying vec2 v_Texcoord;\n\n\nvoid main()\n{\n vec4 p = texture2D(particleTexture, v_Texcoord);\n bool spawn = false;\n if (p.w <= 0.0) {\n p = texture2D(spawnTexture, fract(v_Texcoord + elapsedTime / 10.0));\n p.w -= firstFrameTime;\n spawn = true;\n }\n vec2 v = texture2D(velocityTexture, fract(p.xy * region.zw + region.xy)).xy;\n v = (v - 0.5) * 2.0;\n p.z = length(v);\n p.xy += v * deltaTime / 10.0 * speedScaling;\n p.w -= deltaTime;\n\n if (spawn || p.xy != fract(p.xy)) {\n p.z = 0.0;\n }\n p.xy = fract(p.xy);\n\n gl_FragColor = p;\n}\n@end\n\n@export ecgl.vfParticle.renderPoints.vertex\n\n#define PI 3.1415926\n\nattribute vec2 texcoord : TEXCOORD_0;\n\nuniform sampler2D particleTexture;\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\n\nuniform float size : 1.0;\n\nvarying float v_Mag;\nvarying vec2 v_Uv;\n\nvoid main()\n{\n vec4 p = texture2D(particleTexture, texcoord);\n\n if (p.w > 0.0 && p.z > 1e-5) {\n gl_Position = worldViewProjection * vec4(p.xy * 2.0 - 1.0, 0.0, 1.0);\n }\n else {\n gl_Position = vec4(100000.0, 100000.0, 100000.0, 1.0);\n }\n\n v_Mag = p.z;\n v_Uv = p.xy;\n\n gl_PointSize = size;\n}\n\n@end\n\n@export ecgl.vfParticle.renderPoints.fragment\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\nuniform sampler2D gradientTexture;\nuniform sampler2D colorTexture;\nuniform sampler2D spriteTexture;\n\nvarying float v_Mag;\nvarying vec2 v_Uv;\n\nvoid main()\n{\n gl_FragColor = color;\n#ifdef SPRITETEXTURE_ENABLED\n gl_FragColor *= texture2D(spriteTexture, gl_PointCoord);\n if (color.a == 0.0) {\n discard;\n }\n#endif\n#ifdef GRADIENTTEXTURE_ENABLED\n gl_FragColor *= texture2D(gradientTexture, vec2(v_Mag, 0.5));\n#endif\n#ifdef COLORTEXTURE_ENABLED\n gl_FragColor *= texture2D(colorTexture, v_Uv);\n#endif\n}\n\n@end\n\n@export ecgl.vfParticle.renderLines.vertex\n\n#define PI 3.1415926\n\nattribute vec3 position : POSITION;\n\nuniform sampler2D particleTexture;\nuniform sampler2D prevParticleTexture;\n\nuniform float size : 1.0;\nuniform vec4 vp: VIEWPORT;\nuniform mat4 worldViewProjection : WORLDVIEWPROJECTION;\n\nvarying float v_Mag;\nvarying vec2 v_Uv;\n\n@import clay.util.rand\n\nvoid main()\n{\n vec4 p = texture2D(particleTexture, position.xy);\n vec4 p2 = texture2D(prevParticleTexture, position.xy);\n\n p.xy = p.xy * 2.0 - 1.0;\n p2.xy = p2.xy * 2.0 - 1.0;\n\n if (p.w > 0.0 && p.z > 1e-5) {\n vec2 dir = normalize(p.xy - p2.xy);\n vec2 norm = vec2(dir.y / vp.z, -dir.x / vp.w) * sign(position.z) * size;\n if (abs(position.z) == 2.0) {\n gl_Position = vec4(p.xy + norm, 0.0, 1.0);\n v_Uv = p.xy;\n v_Mag = p.z;\n }\n else {\n gl_Position = vec4(p2.xy + norm, 0.0, 1.0);\n v_Mag = p2.z;\n v_Uv = p2.xy;\n }\n gl_Position = worldViewProjection * gl_Position;\n }\n else {\n gl_Position = vec4(100000.0, 100000.0, 100000.0, 1.0);\n }\n}\n\n@end\n\n@export ecgl.vfParticle.renderLines.fragment\n\nuniform vec4 color : [1.0, 1.0, 1.0, 1.0];\nuniform sampler2D gradientTexture;\nuniform sampler2D colorTexture;\n\nvarying float v_Mag;\nvarying vec2 v_Uv;\n\nvoid main()\n{\n gl_FragColor = color;\n #ifdef GRADIENTTEXTURE_ENABLED\n gl_FragColor *= texture2D(gradientTexture, vec2(v_Mag, 0.5));\n#endif\n#ifdef COLORTEXTURE_ENABLED\n gl_FragColor *= texture2D(colorTexture, v_Uv);\n#endif\n}\n\n@end\n";function Bf(t){var e=document.createElement("canvas");e.width=e.height=t;var n=e.getContext("2d");return n.fillStyle="#fff",n.arc(t/2,t/2,t/2,0,2*Math.PI),n.fill(),e}Xt["import"](kf);var zf=function(){this.motionBlurFactor=.99,this.vectorFieldTexture=new sn({type:Qe.FLOAT,flipY:!1}),this.particleLife=[5,20],this._particleType="point",this._particleSize=1,this.particleColor=[1,1,1,1],this.particleSpeedScaling=1,this._thisFrameTexture=null,this._particlePass=null,this._spawnTexture=null,this._particleTexture0=null,this._particleTexture1=null,this._particlePointsMesh=null,this._surfaceFrameBuffer=null,this._elapsedTime=0,this._scene=null,this._camera=null,this._lastFrameTexture=null,this._supersampling=1,this._downsampleTextures=[],this._width=512,this._height=512,this.init()};zf.prototype={constructor:zf,init:function(){var t={type:Qe.FLOAT,minFilter:Qe.NEAREST,magFilter:Qe.NEAREST,useMipmap:!1};this._spawnTexture=new sn(t),this._particleTexture0=new sn(t),this._particleTexture1=new sn(t),this._frameBuffer=new pi({depthBuffer:!1}),this._particlePass=new vr({fragment:Xt.source("ecgl.vfParticle.particle.fragment")}),this._particlePass.setUniform("velocityTexture",this.vectorFieldTexture),this._particlePass.setUniform("spawnTexture",this._spawnTexture),this._downsamplePass=new vr({fragment:Xt.source("clay.compositor.downsample")});var e=new $e({renderOrder:10,material:new nt({shader:new Xt(Xt.source("ecgl.vfParticle.renderPoints.vertex"),Xt.source("ecgl.vfParticle.renderPoints.fragment"))}),mode:$e.POINTS,geometry:new bn({dynamic:!0,mainAttribute:"texcoord0"})}),n=new $e({renderOrder:10,material:new nt({shader:new Xt(Xt.source("ecgl.vfParticle.renderLines.vertex"),Xt.source("ecgl.vfParticle.renderLines.fragment"))}),geometry:new Rf,culling:!1}),i=new $e({material:new nt({shader:new Xt(Xt.source("ecgl.color.vertex"),Xt.source("ecgl.color.fragment"))}),geometry:new _i});i.material.enableTexture("diffuseMap"),this._particlePointsMesh=e,this._particleLinesMesh=n,this._lastFrameFullQuadMesh=i,this._camera=new hr,this._thisFrameTexture=new sn,this._lastFrameTexture=new sn},setParticleDensity:function(t,e){for(var n=t*e,i=new Float32Array(4*n),r=0,a=this.particleLife,o=0;o0?t[t.length-1]:this._lastFrameTexture},setRegion:function(t){this._particlePass.setUniform("region",t)},resize:function(t,e){this._lastFrameTexture.width=t*this._supersampling,this._lastFrameTexture.height=e*this._supersampling,this._thisFrameTexture.width=t*this._supersampling,this._thisFrameTexture.height=e*this._supersampling,this._width=t,this._height=e},setParticleSize:function(t){var e=this._getParticleMesh();if(t<=2)return e.material.disableTexture("spriteTexture"),void(e.material.transparent=!1);this._spriteTexture||(this._spriteTexture=new sn),this._spriteTexture.image&&this._spriteTexture.image.width===t||(this._spriteTexture.image=Bf(t),this._spriteTexture.dirty()),e.material.transparent=!0,e.material.enableTexture("spriteTexture"),e.material.set("spriteTexture",this._spriteTexture),this._particleSize=t},setGradientTexture:function(t){var e=this._getParticleMesh().material;e[t?"enableTexture":"disableTexture"]("gradientTexture"),e.setUniform("gradientTexture",t)},setColorTextureImage:function(t,e){var n=this._getParticleMesh().material;n.setTextureImage("colorTexture",t,e,{flipY:!0})},setParticleType:function(t){this._particleType=t},clearFrame:function(t){var e=this._frameBuffer;e.attach(this._lastFrameTexture),e.bind(t),t.gl.clear(t.gl.DEPTH_BUFFER_BIT|t.gl.COLOR_BUFFER_BIT),e.unbind(t)},setSupersampling:function(t){this._supersampling=t,this.resize(this._width,this._height)},_updateDownsampleTextures:function(t,e){for(var n=this._downsampleTextures,i=Math.max(Math.floor(Math.log(this._supersampling/e.getDevicePixelRatio())/Math.log(2)),0),r=2,a=this._width*this._supersampling,o=this._height*this._supersampling,s=0;s=359;s&&(r[0]>0&&(r[0]=0),a[0]1?(e.material.shader!==this._meshLinesShader&&e.material.attachShader(this._meshLinesShader),e.mode=Ta.Mesh.TRIANGLES):(e.material.shader!==this._nativeLinesShader&&e.material.attachShader(this._nativeLinesShader),e.mode=Ta.Mesh.LINES),n=n||0,i=i||r.count(),s.resetOffset();var c=0,h=0,d=[],f=[],p=[],g=[],m=[],v=.3,y=.7;function _(){f[0]=d[0]*y+g[0]*v-(d[1]-g[1])*a,f[1]=d[1]*y+g[1]*v-(g[0]-d[0])*a,p[0]=d[0]*v+g[0]*y-(d[1]-g[1])*a,p[1]=d[1]*v+g[1]*y-(g[0]-d[0])*a}if(o||0!==a)for(var b=n;be.data,t=>{Object(i["nextTick"])(()=>{n(t)})},{immediate:!0,deep:!0});const n=t=>{let e=t.map(t=>{let e={value:t.value,name:t.label};return t.color&&(e.itemStyle={color:new r["a"].LinearGradient(0,0,0,1,[{offset:0,color:t.color[0]},{offset:1,color:t.color[1]}])}),e});a(e)},a=t=>{var n=r["b"](document.getElementById(e.echartsId));const i={backgroundColor:"transparent",tooltip:{trigger:"item",formatter:"{a}
{b}: {c} ({d}%)",backgroundColor:"rgba(0,0,0,0.7)",borderColor:"#0C2E5A",textStyle:{color:"#fff"}},legend:{top:"middle",right:"5%",orient:"vertical",itemGap:20,textStyle:{color:e.color,fontSize:14},itemWidth:15,itemHeight:15,icon:"roundRect",formatter:function(t){const e=i.series[0].data,n=e.find(e=>e.label===t);return n?`${t} ${n.value} ${(n.value/50*100).toFixed(0)}%`:t}},series:[{name:"情报反馈统计",type:"pie",radius:["40%","75%"],center:["30%","50%"],startAngle:90,zlevel:10,itemStyle:{},selectedMode:"single",selectedOffset:30,animation:!0,animationType:"scale",animationEasing:"elasticOut",label:{show:!1},labelLine:{show:!1},data:t,zlevel:10,emphasis:{scale:!0,scaleSize:10,itemStyle:{shadowBlur:30,shadowColor:"rgba(0,0,0,0.6)"}}}]};i&&n.setOption(i),window.addEventListener("resize",()=>{n.resize()})};return(e,n)=>(Object(i["openBlock"])(),Object(i["createElementBlock"])("div",{style:{height:"100%",width:"100%"},id:t.echartsId},null,8,qf))}},Kf=(n("5cfa"),n("6b0d")),Qf=n.n(Kf);const Jf=Qf()(Yf,[["__scopeId","data-v-75b106ee"]]);e["a"]=Jf},e86a:function(t,e,n){"use strict";n.d(e,"f",(function(){return s})),n.d(e,"d",(function(){return u})),n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return h})),n.d(e,"e",(function(){return d})),n.d(e,"g",(function(){return f})),n.d(e,"c",(function(){return p}));var i=n("9850"),r=n("d51b"),a=n("726e"),o={};function s(t,e){e=e||a["a"];var n=o[e];n||(n=o[e]=new r["a"](500));var i=n.get(t);return null==i&&(i=a["d"].measureText(t,e).width,n.put(t,i)),i}function l(t,e,n,r){var a=s(t,e),o=d(e),l=c(0,a,n),u=h(0,o,r),f=new i["a"](l,u,a,o);return f}function u(t,e,n,r){var a=((t||"")+"").split("\n"),o=a.length;if(1===o)return l(a[0],e,n,r);for(var s=new i["a"](0,0,0,0),u=0;u=0?parseFloat(t)/100*e:parseFloat(t):t}function p(t,e,n){var i=e.position||"inside",r=null!=e.distance?e.distance:5,a=n.height,o=n.width,s=a/2,l=n.x,u=n.y,c="left",h="top";if(i instanceof Array)l+=f(i[0],n.width),u+=f(i[1],n.height),c=null,h=null;else switch(i){case"left":l-=r,u+=s,c="right",h="middle";break;case"right":l+=r+o,u+=s,h="middle";break;case"top":l+=o/2,u-=r,c="center",h="bottom";break;case"bottom":l+=o/2,u+=a+r,c="center";break;case"inside":l+=o/2,u+=s,c="center",h="middle";break;case"insideLeft":l+=r,u+=s,h="middle";break;case"insideRight":l+=o-r,u+=s,c="right",h="middle";break;case"insideTop":l+=o/2,u+=r,c="center";break;case"insideBottom":l+=o/2,u+=a-r,c="center",h="bottom";break;case"insideTopLeft":l+=r,u+=r;break;case"insideTopRight":l+=o-r,u+=r,c="right";break;case"insideBottomLeft":l+=r,u+=a-r,h="bottom";break;case"insideBottomRight":l+=o-r,u+=a-r,c="right",h="bottom";break}return t=t||{},t.x=l,t.y=u,t.align=c,t.verticalAlign=h,t}},e887:function(t,e,n){"use strict";var i=n("6d8b"),r=n("2dc5"),a=n("8918"),o=n("625e"),s=n("e0d3"),l=n("7d6c"),u=n("9fbc"),c=n("cccd"),h=n("2306"),d=s["o"](),f=Object(c["a"])(),p=function(){function t(){this.group=new r["a"],this.uid=a["c"]("viewChart"),this.renderTask=Object(u["a"])({plan:v,reset:y}),this.renderTask.context={view:this}}return t.prototype.init=function(t,e){},t.prototype.render=function(t,e,n,i){0},t.prototype.highlight=function(t,e,n,i){var r=t.getData(i&&i.dataType);r&&m(r,i,"emphasis")},t.prototype.downplay=function(t,e,n,i){var r=t.getData(i&&i.dataType);r&&m(r,i,"normal")},t.prototype.remove=function(t,e){this.group.removeAll()},t.prototype.dispose=function(t,e){},t.prototype.updateView=function(t,e,n,i){this.render(t,e,n,i)},t.prototype.updateLayout=function(t,e,n,i){this.render(t,e,n,i)},t.prototype.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},t.prototype.eachRendered=function(t){Object(h["traverseElements"])(this.group,t)},t.markUpdateMethod=function(t,e){d(t).updateMethod=e},t.protoInitialize=function(){var e=t.prototype;e.type="chart"}(),t}();function g(t,e,n){t&&Object(l["y"])(t)&&("emphasis"===e?l["r"]:l["C"])(t,n)}function m(t,e,n){var r=s["u"](t,e),a=e&&null!=e.highlightKey?Object(l["v"])(e.highlightKey):null;null!=r?Object(i["k"])(s["r"](r),(function(e){g(t.getItemGraphicEl(e),n,a)})):t.eachItemGraphicEl((function(t){g(t,n,a)}))}function v(t){return f(t.model)}function y(t){var e=t.model,n=t.ecModel,i=t.api,r=t.payload,a=e.pipelineContext.progressiveRender,o=t.view,s=r&&d(r).updateMethod,l=a?"incrementalPrepareRender":s&&o[s]?s:"render";return"render"!==l&&o[l](e,n,i,r),_[l]}o["b"](p,["dispose"]),o["c"](p);var _={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)}}};e["a"]=p},e88d:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAC4AAAAWCAYAAAC/kK73AAAAAXNSR0IArs4c6QAACT5JREFUWEetl3tQXNUdx7/n7t7H3t2FBZYsyyMLSQmBGIwPMLRCAqYx0bTyRzWjTu30MZN06tTWto7TcZRO/2raMam1taW106hjJ5PYan3EZ6rkUQ1QISp5KoRAWBbYhd27e9/3ds4hQUisWKdn9s7dPefccz+/928JAGzZsvVOD+9ZXZBfgGQqdb3sk6Zlv//9O++4DaZtQMvpUHUN2UwW2azmKopCDEN3VVUjdN40TVfTdGiaSpRMdi3HkQKB52GYJnyS76SiKO+UlYUe6ezsNOn76JCk9047jrGUEM6IRkPVQ0NV8Ytrn+VO6KbNN9/2F0GIfGNivB1XVb+MW4LvYM/UUpxPm3BdB3ABEEI/9MuFc+nkwuGyKQKOXAfHXon1nj+hxjbxB84HF87BLTe2HVJ1jWQzCghHtpdES0KJxITd29v321xOy6qqFj906NVHATiLwTOKe5s3/GAgr3AnYVCMcrHnPnHdsiy4s/Rs2LYFuA48Hi+8PA/Hvshzcc8lSiDY5iHq7v379+uLAbAnf9647odHwpGHqUq9ogB/YQgiz4MDQWpiErqqzZ0jBvzwBf2QeJ4JmBgdg2PbbN2yTMihEERZguDlYag5jA4NQhREiD4ZPMnAcV2YThDE64Xkk8DNmhFTiQT8vsDDL72050eLQc/Z/aYtW+9xHHcXIQSFFaW4YlMbfIKAklA+Dux5FufODM65R+yaKxG7uh55sg/hQAD7fvNHKGmFWcqybKzasA7v/vMVlJaVYvPWO7B7xyPgvTxzs4YqAQLPoeu4gvqbNuKLm9pQnJcHuC4euOubkLzBM3kBrNq7d6+xGDwTl4G77i7qKj6fCNt2YBgGJElizzuOy357PBy7DMOEKIrgeS903YBpWiDEgWU60A0VddVR6IaJoZEZcJyH7aPjoTvWwesheGD3Aay+aQPqmptQXRJha491/AxT55KIRApv2f3nx/4xH7ylpaWiq6vr3Py5BeDUbN/ddhfOnBnCK6+/ha1f+wrKy6MYHY1j3zMv4LrrrkF5WQn27H0eNTXLsXHDOvz9uf1snRAXpmkzt7m97QrEkxm82nMajm1BEASm8S+tqYapanj7+FlUN61F6aoaFAUCCEo+PP/UE3ANDo6hdT77t6e3zYesra1t53n++LFjx05enF8A7vV4sHlTG4oKQzja3Ye62mrQNLckEsbR7n6sbbyKBdo7R3tx+swgbvnqJvT3D+CDgZMMrDgcQioZR0lREc7H40imM5DEfIiCjfHxcZiWxeKevqc0WgrdFkEu5ALTNEAt7vV6TUGUkm2t1ye8Hs+ILPtOJBLx86dOnepT1UzXRTf6GNxxd9FDA36Z+Sr1d8dxYNs2eBqoBCywqBsJvBeqqkMUBQaSy2ns7nEz+PCjQei6zrILPauqcjk0w8C5kbOwLRvRaBQ0+4iiD5w3b06xlqnDtk3wgghJ8s/FlOu4EAQvQgX5bmRJOCEH5Iff6+sRGPjuJ5/e5uG433++JPixUd988wCOHDnMoDmOY9fGjTcim1Px9r8OU21icnKSKaK5uQXr199wWV0YGh7BkSM9c1mKZTqPB4auQRAlFBeHkZkZe3lO467r7loskhdbT8+MI5dNM2tReHrneQmOY8MwdHAcYdoWBBGCIEEOFH+sccuE41hMKGoN0zTZfsJ52J5iZwpRn4OxvJVQZuJvXJZVFsK5zF1yShqmocMr8JD9+czPLx207kwnR2BaBlzHZs/xvABe8DEX0DWNgVFwBifJyMuPsmOokDYDpy4KZLMzULPp2fpA6IcKwIHnRcRiVSCc9QaprKyUCsPRX8qB/LsvrZiGlkMiPsxyNH2ZZZpwXGBJpAKiL3BZgVWVKWSVDCtErEgQglBBEUIBGcPn49C13IV5IFZeDkW9RHxChR+HrqvgBYG5Gk3DtJh7vbOaLy0thU+WXyTLli27nRDydEG4bMEplmlgYnwE0WgJCgrDcF2OtRCZdAojIyMoWlLGzD03XKBl9VI833X0guZob8OhfX0T6ipL8etnXoVtztYVj8eDe7feiF/99WXWYDAhAUxPp5illi9fDl6QZ5sPl2akMRYbNEbC4TAV6Hekqqrq65ZtPxGJVs5nQDqVgMB7ULF0GfLyChGJFGFiMoVUchLxsWFklBwKwtEFXc31dTG81f/BXAtAi0/L6hV469gZ6LrCMhK1HCtsLi1WJstA9PL5fEin06iurobgy0dFeTkCsg+Dw6OwjCxOHH/ftiyLI7NDIbFY7FuEkMcLi8vhzskPTI6PoKpyKfyBCFbVLcPQ0EeIxSpx/OQwtNwETp46jSXR2EIrGQZMPUMrOIPzenlYjod2gjC1NAs4qm0KOT09PedOdJ76eWVlJQLBPAQCYRSH/ZiamkKkpIwVRDWXevLs2bMTAERCyDSRZfk5BxBNfWF7sH379qtTqWTxTNrElfU1rBXQdRPv9p+EKJhO09om94UXXnRd13XoS03T1FOpZMLv91cARKAZwbbtXEZRxqgbBIPBUsdxcoQQSxTFSEVFBQNXFIUJQuPh/vvvx4MPdUCSCnD1VTVs7vzYJM4Nj0DTZh557bXX7rmoqf+aukdHR7/T2dl5c1/f++0gIkIFQcxMK3AdFaqq/HTfvn2dwWCQto0s4git+QAaGhpOrFmzpmZmZgaDg4Ovd3d3f5nONzY2HtR1PQFgNBAI3LZz584f01agt7eXa21t7VdVVVyxYoW/vb39Qc7jW0+LEFVWMjkDD6fbqVSypaur68ii4JTl1ltv5cbHx34RzC/4vpfjedu2nGw28/j4+PjdAwMDn9jBNTQ0HG9qalqZSqVw4sSJN7q7uzdcAO/SNO0jACOCIGzt6empnu9nHR0d3o6ODquurq4kGo3ukeVAC40RXVfT2azyvYMHDz41f/9nKpb19fXlsiyvNE1zsLe398PLkvi8CQre2trKwPv6+ubAGxoaugzD6LNte0ySpG/39PR84VPOIY2NjfUAihKJxL+HhoZmA2Le+EzgnwZ66dq11147sHnz5lrqKocPHz7Q29t7Q3Nzc9RxnDdzudxPHMdJ+v3+pziOazt06BC1wOca/1fw2tralqKiop333XefSVPcjh07+Gw2e5fjOHFRFIv6+/tPUcra2toYIUQfGBj4n/4gz5fwP8dBTbJl22GWAAAAAElFTkSuQmCC"},ec6f:function(t,e,n){"use strict";n.d(e,"e",(function(){return l})),n.d(e,"b",(function(){return u})),n.d(e,"c",(function(){return c})),n.d(e,"a",(function(){return h})),n.d(e,"d",(function(){return d})),n.d(e,"f",(function(){return v}));var i=n("6d8b"),r=n("07fd"),a=n("e0d3"),o=n("0f99"),s=function(){function t(t){this.data=t.data||(t.sourceFormat===r["d"]?{}:[]),this.sourceFormat=t.sourceFormat||r["h"],this.seriesLayoutBy=t.seriesLayoutBy||r["a"],this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var e=this.dimensionsDefine=t.dimensionsDefine;if(e)for(var n=0;n1?"."+e[1]:"")}function s(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,(function(t,e){return e.toUpperCase()})),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}var l=i["M"],u=/([&<>"'])/g,c={"&":"&","<":"<",">":">",'"':""","'":"'"};function h(t){return null==t?"":(t+"").replace(u,(function(t,e){return c[e]}))}function d(t,e,n){var s="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function l(t){return t&&i["T"](t)?t:"-"}function u(t){return!(null==t||isNaN(t)||!isFinite(t))}var c="time"===e,h=t instanceof Date;if(c||h){var d=c?Object(r["o"])(t):t;if(!isNaN(+d))return Object(a["h"])(d,s,n);if(h)return"-"}if("ordinal"===e)return i["D"](t)?l(t):i["z"](t)&&u(t)?t+"":"-";var f=Object(r["n"])(t);return u(f)?o(f):i["D"](t)?l(t):"boolean"===typeof t?t+"":"-"}var f=["a","b","c","d","e","f","g"],p=function(t,e){return"{"+t+(null==e?"":e)+"}"};function g(t,e,n){i["t"](e)||(e=[e]);var r=e.length;if(!r)return"";for(var a=e[0].$vars||[],o=0;o':'';var s=n.markerId||"markerX";return{renderMode:o,content:"{"+s+"|} ",style:"subItem"===a?{width:4,height:4,borderRadius:2,backgroundColor:r}:{width:10,height:10,borderRadius:5,backgroundColor:r}}}function y(t,e,n){"week"!==t&&"month"!==t&&"quarter"!==t&&"half-year"!==t&&"year"!==t||(t="MM-dd\nyyyy");var i=Object(r["o"])(e),o=n?"getUTC":"get",s=i[o+"FullYear"](),l=i[o+"Month"]()+1,u=i[o+"Date"](),c=i[o+"Hours"](),h=i[o+"Minutes"](),d=i[o+"Seconds"](),f=i[o+"Milliseconds"]();return t=t.replace("MM",Object(a["y"])(l,2)).replace("M",l).replace("yyyy",s).replace("yy",Object(a["y"])(s%100+"",2)).replace("dd",Object(a["y"])(u,2)).replace("d",u).replace("hh",Object(a["y"])(c,2)).replace("h",c).replace("mm",Object(a["y"])(h,2)).replace("m",h).replace("ss",Object(a["y"])(d,2)).replace("s",d).replace("SSS",Object(a["y"])(f,3)),t}function _(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}function b(t,e){return e=e||"transparent",i["C"](t)?t:i["A"](t)&&t.colorStops&&(t.colorStops[0]||{}).color||e}function x(t,e){if("_blank"===e||"blank"===e){var n=window.open();n.opener=null,n.location.href=t}else window.open(t,e)}},edae:function(t,e,n){"use strict";n.d(e,"d",(function(){return s})),n.d(e,"b",(function(){return l})),n.d(e,"a",(function(){return u})),n.d(e,"c",(function(){return c}));var i="[ECharts] ",r={},a="undefined"!==typeof console&&console.warn&&console.log;function o(t,e,n){if(a){if(n){if(r[e])return;r[e]=!0}console[t](i+e)}}function s(t,e){o("warn",t,e)}function l(t,e){o("error",t,e)}function u(t){0}function c(t){throw new Error(t)}},ee1a:function(t,e,n){"use strict";n.d(e,"a",(function(){return a})),n.d(e,"c",(function(){return s})),n.d(e,"b",(function(){return l}));var i=n("6d8b"),r=n("80b9");function a(t,e,n){n=n||{};var r,a,s,l=n.byIndex,u=n.stackedCoordDimension;o(e)?r=e:(a=e.schema,r=a.dimensions,s=e.store);var c,h,d,f,p=!(!t||!t.get("stack"));if(Object(i["k"])(r,(function(t,e){Object(i["C"])(t)&&(r[e]=t={name:t}),p&&!t.isExtraCoord&&(l||c||!t.ordinalMeta||(c=t),h||"ordinal"===t.type||"time"===t.type||u&&u!==t.coordDim||(h=t))})),!h||l||c||(l=!0),h){d="__\0ecstackresult_"+t.id,f="__\0ecstackedover_"+t.id,c&&(c.createInvertedIndices=!0);var g=h.coordDim,m=h.type,v=0;Object(i["k"])(r,(function(t){t.coordDim===g&&v++}));var y={name:d,coordDim:g,coordDimIndex:v,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:r.length},_={name:f,coordDim:f,coordDimIndex:v+1,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:r.length+1};a?(s&&(y.storeDimIndex=s.ensureCalculationDimension(f,m),_.storeDimIndex=s.ensureCalculationDimension(d,m)),a.appendCalculationDimension(y),a.appendCalculationDimension(_)):(r.push(y),r.push(_))}return{stackedDimension:h&&h.name,stackedByDimension:c&&c.name,isStackedByIndex:l,stackedOverDimension:f,stackResultDimension:d}}function o(t){return!Object(r["d"])(t.schema)}function s(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function l(t,e){return s(t,e)?t.getCalculationInfo("stackResultDimension"):e}},ee29:function(t,e,n){"use strict";n.d(e,"a",(function(){return S}));var i=n("e0d3"),r=n("9850"),a=n("deab"),o=n("861c"),s=n("3842"),l=n("8582"),u=n("89b6"),c=n("6d8b"),h=n("2355"),d=n("7837");function f(t){if(t){for(var e=[],n=0;n=0&&n.attr(r.oldLayoutSelect),Object(c["r"])(p,"emphasis")>=0&&n.attr(r.oldLayoutEmphasis)),Object(a["h"])(n,h,e,u)}else if(n.attr(h),!Object(d["f"])(n).valueAnimation){var g=Object(c["P"])(n.style.opacity,1);n.style.opacity=0,Object(a["c"])(n,{style:{opacity:g}},e,u)}if(r.oldLayout=h,n.states.select){var m=r.oldLayoutSelect={};_(m,h,b),_(m,n.states.select,b)}if(n.states.emphasis){var x=r.oldLayoutEmphasis={};_(x,h,b),_(x,n.states.emphasis,b)}Object(d["a"])(n,u,f,e,e)}if(i&&!i.ignore&&!i.invisible){r=y(i),s=r.oldLayout;var w={points:i.shape.points};s?(i.attr({shape:s}),Object(a["h"])(i,{shape:w},e)):(i.setShape(w),i.style.strokePercent=0,Object(a["c"])(i,{style:{strokePercent:1}},e)),r.oldLayout=w}},t}(),w=x,O=Object(i["o"])();function S(t){t.registerUpdateLifecycle("series:beforeupdate",(function(t,e,n){var i=O(e).labelManager;i||(i=O(e).labelManager=new w),i.clearLabels()})),t.registerUpdateLifecycle("series:layoutlabels",(function(t,e,n){var i=O(e).labelManager;n.updatedSeries.forEach((function(t){i.addLabelsOfSeries(e.getViewOfSeriesModel(t))})),i.updateLayoutConfig(e),i.layout(e),i.processLabelsOverall()}))}},ef59:function(t,e,n){"use strict";n.d(e,"a",(function(){return f})),n.d(e,"b",(function(){return g})),n.d(e,"d",(function(){return m})),n.d(e,"c",(function(){return v}));var i=n("4319"),r=n("22d1"),a={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"}},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:". "}}}},o={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}},s=n("6d8b"),l="ZH",u="EN",c=u,h={},d={},f=r["a"].domSupported?function(){var t=(document.documentElement.lang||navigator.language||navigator.browserLanguage).toUpperCase();return t.indexOf(l)>-1?l:c}():c;function p(t,e){t=t.toUpperCase(),d[t]=new i["a"](e),h[t]=e}function g(t){if(Object(s["C"])(t)){var e=h[t.toUpperCase()]||{};return t===l||t===u?Object(s["d"])(e):Object(s["I"])(Object(s["d"])(e),Object(s["d"])(h[c]),!1)}return Object(s["I"])(Object(s["d"])(t),Object(s["d"])(h[c]),!1)}function m(t){return d[t]}function v(){return d[c]}p(u,a),p(l,o)},f279:function(t,e,n){"use strict";n.d(e,"b",(function(){return p})),n.d(e,"a",(function(){return g})),n.d(e,"c",(function(){return m})),n.d(e,"d",(function(){return v}));var i=n("7fae"),r=n("9850"),a=n("401b"),o=n("0655"),s=n("1687"),l=n("6d8b"),u=[];function c(t,e){for(var n=0;nn&&(t=r,n=o)}if(t)return d(t.exterior);var s=this.getBoundingRect();return[s.x+s.width/2,s.y+s.height/2]},e.prototype.getBoundingRect=function(t){var e=this._rect;if(e&&!t)return e;var n=[1/0,1/0],i=[-1/0,-1/0],a=this.geometries;return Object(l["k"])(a,(function(e){"polygon"===e.type?h(e.exterior,n,i,t):Object(l["k"])(e.points,(function(e){h(e,n,i,t)}))})),isFinite(n[0])&&isFinite(n[1])&&isFinite(i[0])&&isFinite(i[1])||(n[0]=n[1]=i[0]=i[1]=0),e=new r["a"](n[0],n[1],i[0]-n[0],i[1]-n[1]),t||(this._rect=e),e},e.prototype.contain=function(t){var e=this.getBoundingRect(),n=this.geometries;if(!e.contain(t[0],t[1]))return!1;t:for(var i=0,r=n.length;i1||v&&!g){var _=l(m,c,h,p,y);e=_.inlineValues,n=_.inlineValueTypes,s=_.blocks,u=_.inlineValues[0]}else if(g){var b=f.getDimensionInfo(p[0]);u=e=Object(a["e"])(f,h,p[0]),n=b.type}else u=e=v?m[0]:m;var x=Object(o["n"])(c),w=x&&c.name||"",O=f.getName(h),S=d?w:O;return Object(r["c"])("section",{header:w,noHeader:d||!x,sortParam:u,blocks:[Object(r["c"])("nameValue",{markerType:"item",markerColor:y,name:S,noName:!Object(i["T"])(S),value:e,valueType:n})].concat(s||[])})}function l(t,e,n,o,s){var l=e.getData(),u=Object(i["N"])(t,(function(t,e,n){var i=l.getDimensionInfo(n);return t||i&&!1!==i.tooltip&&null!=i.displayName}),!1),c=[],h=[],d=[];function f(t,e){var n=l.getDimensionInfo(e);n&&!1!==n.otherDims.tooltip&&(u?d.push(Object(r["c"])("nameValue",{markerType:"subItem",markerColor:s,name:n.displayName,value:t,valueType:n.type})):(c.push(t),h.push(n.type)))}return o.length?Object(i["k"])(o,(function(t){f(Object(a["e"])(l,n,t),t)})):Object(i["k"])(t,f),{inlineValues:c,inlineValueTypes:h,blocks:d}}},f72b:function(t,e,n){"use strict";n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return h}));var i=n("6d8b"),r=n("ec6f"),a=n("07fd"),o=n("0f99"),s=n("04f7"),l=n("d0ce"),u=n("2b17"),c=function(){function t(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}return t.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},t.prototype._setLocalSource=function(t,e){this._sourceList=t,this._upstreamSignList=e,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 t,e,n=this._sourceHost,o=this._getUpstreamSourceManagers(),s=!!o.length;if(d(n)){var l=n,u=void 0,c=void 0,h=void 0;if(s){var f=o[0];f.prepareSource(),h=f.getSource(),u=h.data,c=h.sourceFormat,e=[f._getVersionSign()]}else u=l.get("data",!0),c=Object(i["E"])(u)?a["g"]:a["f"],e=[];var p=this._getSourceMetaRawOption()||{},g=h&&h.metaRawOption||{},m=Object(i["P"])(p.seriesLayoutBy,g.seriesLayoutBy)||null,v=Object(i["P"])(p.sourceHeader,g.sourceHeader),y=Object(i["P"])(p.dimensions,g.dimensions),_=m!==g.seriesLayoutBy||!!v!==!!g.sourceHeader||y;t=_?[Object(r["b"])(u,{seriesLayoutBy:m,sourceHeader:v,dimensions:y},c)]:[]}else{var b=n;if(s){var x=this._applyTransform(o);t=x.sourceList,e=x.upstreamSignList}else{var w=b.get("source",!0);t=[Object(r["b"])(w,this._getSourceMetaRawOption(),null)],e=[]}}this._setLocalSource(t,e)},t.prototype._applyTransform=function(t){var e,n=this._sourceHost,a=n.get("transform",!0),o=n.get("fromTransformResult",!0);if(null!=o){var l="";1!==t.length&&f(l)}var u=[],c=[];return Object(i["k"])(t,(function(t){t.prepareSource();var e=t.getSource(o||0),n="";null==o||e||f(n),u.push(e),c.push(t._getVersionSign())})),a?e=Object(s["a"])(a,u,{datasetIndex:n.componentIndex}):null!=o&&(e=[Object(r["a"])(u[0])]),{sourceList:e,upstreamSignList:c}},t.prototype._isDirty=function(){if(this._dirty)return!0;for(var t=this._getUpstreamSourceManagers(),e=0;e0)for(var l=0;l=0;--l)if(u[c]){o=u[c];break}o=o||s.none}if(i["t"](o)){var f=null==t.level?0:t.level>=0?t.level:o.length+t.level;f=Math.min(f,o.length-1),o=o[f]}}return x(new Date(t.value),o,a,r)}function O(t,e){var n=r["o"](t),i=n[M(e)]()+1,a=n[A(e)](),o=n[C(e)](),s=n[I(e)](),l=n[D(e)](),u=n[L(e)](),c=0===u,h=c&&0===l,d=h&&0===s,f=d&&0===o,p=f&&1===a,g=p&&1===i;return g?"year":p?"month":f?"day":d?"hour":h?"minute":c?"second":"millisecond"}function S(t,e,n){var a=i["z"](t)?r["o"](t):t;switch(e=e||O(t,n),e){case"year":return a[T(n)]();case"half-year":return a[M(n)]()>=6?1:0;case"quarter":return Math.floor((a[M(n)]()+1)/4);case"month":return a[M(n)]();case"day":return a[A(n)]();case"half-day":return a[C(n)]()/24;case"hour":return a[C(n)]();case"minute":return a[I(n)]();case"second":return a[D(n)]();case"millisecond":return a[L(n)]()}}function T(t){return t?"getUTCFullYear":"getFullYear"}function M(t){return t?"getUTCMonth":"getMonth"}function A(t){return t?"getUTCDate":"getDate"}function C(t){return t?"getUTCHours":"getHours"}function I(t){return t?"getUTCMinutes":"getMinutes"}function D(t){return t?"getUTCSeconds":"getSeconds"}function L(t){return t?"getUTCMilliseconds":"getMilliseconds"}function E(t){return t?"setUTCFullYear":"setFullYear"}function j(t){return t?"setUTCMonth":"setMonth"}function P(t){return t?"setUTCDate":"setDate"}function N(t){return t?"setUTCHours":"setHours"}function R(t){return t?"setUTCMinutes":"setMinutes"}function k(t){return t?"setUTCSeconds":"setSeconds"}function B(t){return t?"setUTCMilliseconds":"setMilliseconds"}},f934:function(t,e,n){"use strict";n.d(e,"a",(function(){return l})),n.d(e,"b",(function(){return h})),n.d(e,"e",(function(){return d})),n.d(e,"g",(function(){return f})),n.d(e,"i",(function(){return p})),n.d(e,"j",(function(){return g})),n.d(e,"d",(function(){return m})),n.d(e,"h",(function(){return v})),n.d(e,"f",(function(){return y})),n.d(e,"c",(function(){return _}));var i=n("6d8b"),r=n("9850"),a=n("3842"),o=n("eda2"),s=i["k"],l=["left","right","top","bottom","width","height"],u=[["width","left","right"],["height","top","bottom"]];function c(t,e,n,i,r){var a=0,o=0;null==i&&(i=1/0),null==r&&(r=1/0);var s=0;e.eachChild((function(l,u){var c,h,d=l.getBoundingRect(),f=e.childAt(u+1),p=f&&f.getBoundingRect();if("horizontal"===t){var g=d.width+(p?-p.x+d.x:0);c=a+g,c>i||l.newline?(a=0,c=g,o+=s+n,s=d.height):s=Math.max(s,d.height)}else{var m=d.height+(p?-p.y+d.y:0);h=o+m,h>r||l.newline?(a+=s+n,o=0,h=m,s=d.width):s=Math.max(s,d.width)}l.newline||(l.x=a,l.y=o,l.markRedraw(),"horizontal"===t?a=c+n:o=h+n)}))}var h=c;i["h"](c,"vertical"),i["h"](c,"horizontal");function d(t,e,n){var i=e.width,r=e.height,s=Object(a["p"])(t.left,i),l=Object(a["p"])(t.top,r),u=Object(a["p"])(t.right,i),c=Object(a["p"])(t.bottom,r);return(isNaN(s)||isNaN(parseFloat(t.left)))&&(s=0),(isNaN(u)||isNaN(parseFloat(t.right)))&&(u=i),(isNaN(l)||isNaN(parseFloat(t.top)))&&(l=0),(isNaN(c)||isNaN(parseFloat(t.bottom)))&&(c=r),n=o["j"](n||0),{width:Math.max(u-s-n[1]-n[3],0),height:Math.max(c-l-n[0]-n[2],0)}}function f(t,e,n){n=o["j"](n||0);var i=e.width,s=e.height,l=Object(a["p"])(t.left,i),u=Object(a["p"])(t.top,s),c=Object(a["p"])(t.right,i),h=Object(a["p"])(t.bottom,s),d=Object(a["p"])(t.width,i),f=Object(a["p"])(t.height,s),p=n[2]+n[0],g=n[1]+n[3],m=t.aspect;switch(isNaN(d)&&(d=i-c-g-l),isNaN(f)&&(f=s-h-p-u),null!=m&&(isNaN(d)&&isNaN(f)&&(m>i/s?d=.8*i:f=.8*s),isNaN(d)&&(d=m*f),isNaN(f)&&(f=d/m)),isNaN(l)&&(l=i-c-d-g),isNaN(u)&&(u=s-h-f-p),t.left||t.right){case"center":l=i/2-d/2-n[3];break;case"right":l=i-d-g;break}switch(t.top||t.bottom){case"middle":case"center":u=s/2-f/2-n[0];break;case"bottom":u=s-f-p;break}l=l||0,u=u||0,isNaN(d)&&(d=i-g-l-(c||0)),isNaN(f)&&(f=s-p-u-(h||0));var v=new r["a"](l+n[3],u+n[0],d,f);return v.margin=n,v}function p(t,e,n,a,o,s){var l,u=!o||!o.hv||o.hv[0],c=!o||!o.hv||o.hv[1],h=o&&o.boundingMode||"all";if(s=s||t,s.x=t.x,s.y=t.y,!u&&!c)return!1;if("raw"===h)l="group"===t.type?new r["a"](0,0,+e.width||0,+e.height||0):t.getBoundingRect();else if(l=t.getBoundingRect(),t.needLocalTransform()){var d=t.getLocalTransform();l=l.clone(),l.applyTransform(d)}var p=f(i["i"]({width:l.width,height:l.height},e),n,a),g=u?p.x-l.x:0,m=c?p.y-l.y:0;return"raw"===h?(s.x=g,s.y=m):(s.x+=g,s.y+=m),s===t&&t.markRedraw(),!0}function g(t,e){return null!=t[u[e][0]]||null!=t[u[e][1]]&&null!=t[u[e][2]]}function m(t){var e=t.layoutMode||t.constructor.layoutMode;return i["A"](e)?e:e?{type:e}:null}function v(t,e,n){var r=n&&n.ignoreSize;!i["t"](r)&&(r=[r,r]);var a=l(u[0],0),o=l(u[1],1);function l(n,i){var a={},o=0,l={},u=0,d=2;if(s(n,(function(e){l[e]=t[e]})),s(n,(function(t){c(e,t)&&(a[t]=l[t]=e[t]),h(a,t)&&o++,h(l,t)&&u++})),r[i])return h(e,n[1])?l[n[2]]=null:h(e,n[2])&&(l[n[1]]=null),l;if(u!==d&&o){if(o>=d)return a;for(var f=0;f=o)}}for(var d=this.__startIndex;d15)break}}n.prevElClipPaths&&u.restore()};if(d)if(0===d.length)s=l.__endIndex;else for(var b=f.dpr,x=0;x0&&t>i[0]){for(s=0;st)break;o=n[i[s]]}if(i.splice(s+1,0,t),n[t]=e,!e.virtual)if(o){var l=o.dom;l.nextSibling?a.insertBefore(e.dom,l.nextSibling):a.appendChild(e.dom)}else a.firstChild?a.insertBefore(e.dom,a.firstChild):a.appendChild(e.dom);e.__painter=this}},t.prototype.eachLayer=function(t,e){for(var n=this._zlevelList,i=0;i0?_:0),this._needsManuallyCompositing),h.__builtin__||r["G"]("ZLevel "+u+" has been used by unkown layer "+h.id),h!==s&&(h.__used=!0,h.__startIndex!==o&&(h.__dirty=!0),h.__startIndex=o,h.incremental?h.__drawIndex=-1:h.__drawIndex=o,e(o),s=h),i.__dirty&c["a"]&&!i.__inHover&&(h.__dirty=!0,h.incremental&&h.__drawIndex<0&&(h.__drawIndex=o))}e(o),this.eachBuiltinLayer((function(t,e){!t.__used&&t.getElementCount()>0&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)}))},t.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},t.prototype._clearLayer=function(t){t.clear()},t.prototype.setBackgroundColor=function(t){this._backgroundColor=t,r["k"](this._layers,(function(t){t.setUnpainted()}))},t.prototype.configLayer=function(t,e){if(e){var n=this._layerConfig;n[t]?r["I"](n[t],e,!0):n[t]=e;for(var i=0;i