pages-index-index.ea286f4d.js 114 KB
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-index-index"],{"0730":function(t,e,i){"use strict";(function(e){i("99af"),i("cb29"),i("4de4"),i("4160"),i("c975"),i("d81d"),i("13d5"),i("26e9"),i("fb6a"),i("4e82"),i("a9e3"),i("b680"),i("d3b7"),i("e25e"),i("ac1f"),i("25f0"),i("5319"),i("1276"),i("159b");var a={yAxisWidth:15,yAxisSplit:5,xAxisHeight:22,xAxisLineHeight:22,legendHeight:15,yAxisTitleWidth:15,padding:[10,10,10,10],pixelRatio:1,rotate:!1,columePadding:3,fontSize:13,dataPointShape:["circle","circle","circle","circle"],colors:["#1890ff","#2fc25b","#facc14","#f04864","#8543e0","#90ed7d"],pieChartLinePadding:15,pieChartTextPadding:5,xAxisTextPadding:3,titleColor:"#333333",titleFontSize:20,subtitleColor:"#999999",subtitleFontSize:15,toolTipPadding:3,toolTipBackground:"#000000",toolTipOpacity:.7,toolTipLineHeight:20,radarLabelTextMargin:15,gaugeLabelTextMargin:15},n=function(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),a=1;a<e;a++)i[a-1]=arguments[a];if(null==t)throw new TypeError("Cannot convert undefined or null to object");if(!i||i.length<=0)return t;function n(t,e){for(var i in e)t[i]=t[i]&&"[object Object]"===t[i].toString()?n(t[i],e[i]):t[i]=e[i];return t}return i.forEach((function(e){t=n(t,e)})),t},o={toFixed:function(t,e){return e=e||2,this.isFloat(t)&&(t=t.toFixed(e)),t},isFloat:function(t){return t%1!==0},approximatelyEqual:function(t,e){return Math.abs(t-e)<1e-10},isSameSign:function(t,e){return Math.abs(t)===t&&Math.abs(e)===e||Math.abs(t)!==t&&Math.abs(e)!==e},isSameXCoordinateArea:function(t,e){return this.isSameSign(t.x,e.x)},isCollision:function(t,e){t.end={},t.end.x=t.start.x+t.width,t.end.y=t.start.y-t.height,e.end={},e.end.x=e.start.x+e.width,e.end.y=e.start.y-e.height;var i=e.start.x>t.end.x||e.end.x<t.start.x||e.end.y>t.start.y||e.start.y<t.end.y;return!i}};function r(t,e){var i=/^#?([a-f\d])([a-f\d])([a-f\d])$/i,a=t.replace(i,(function(t,e,i,a){return e+e+i+i+a+a})),n=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(a),o=parseInt(n[1],16),r=parseInt(n[2],16),l=parseInt(n[3],16);return"rgba("+o+","+r+","+l+","+e+")"}function l(t,e,i){if(isNaN(t))throw new Error("[uCharts] unvalid series data!");i=i||10,e=e||"upper";var a=1;while(i<1)i*=10,a*=10;t="upper"===e?Math.ceil(t*a):Math.floor(t*a);while(t%i!==0)"upper"===e?t++:t--;return t/a}function s(t,e,i,a){for(var n=[],o=0;o<t.length;o++){for(var r={data:[],name:e[o],color:i[o]},l=0,s=a.length;l<s;l++)if(l<t[o])r.data.push(null);else{for(var c=0,h=0;h<t[o];h++)c+=a[l-h][1];r.data.push(+(c/t[o]).toFixed(3))}n.push(r)}return n}function c(t,e,i,a,n){var o=n.width-n.area[1]-n.area[3],r=i.eachSpacing*(n.chartData.xAxisData.xAxisPoints.length-1),l=e;return e>=0?(l=0,t.event.trigger("scrollLeft")):Math.abs(e)>=r-o&&(l=o-r,t.event.trigger("scrollRight")),l}function h(t,e,i){function a(t){while(t<0)t+=2*Math.PI;while(t>2*Math.PI)t-=2*Math.PI;return t}return t=a(t),e=a(e),i=a(i),e>i&&(i+=2*Math.PI,t<e&&(t+=2*Math.PI)),t>=e&&t<=i}function d(t,e,i){var a=t,n=i-e,o=a+(i-n-a)/Math.sqrt(2);o*=-1;var r=(i-n)*(Math.sqrt(2)-1)-(i-n-a)/Math.sqrt(2);return{transX:o,transY:r}}function u(t,e){function i(t,e){return!(!t[e-1]||!t[e+1])&&(t[e].y>=Math.max(t[e-1].y,t[e+1].y)||t[e].y<=Math.min(t[e-1].y,t[e+1].y))}function a(t,e){return!(!t[e-1]||!t[e+1])&&(t[e].x>=Math.max(t[e-1].x,t[e+1].x)||t[e].x<=Math.min(t[e-1].x,t[e+1].x))}var n=.2,o=.2,r=null,l=null,s=null,c=null;if(e<1?(r=t[0].x+(t[1].x-t[0].x)*n,l=t[0].y+(t[1].y-t[0].y)*n):(r=t[e].x+(t[e+1].x-t[e-1].x)*n,l=t[e].y+(t[e+1].y-t[e-1].y)*n),e>t.length-3){var h=t.length-1;s=t[h].x-(t[h].x-t[h-1].x)*o,c=t[h].y-(t[h].y-t[h-1].y)*o}else s=t[e+1].x-(t[e+2].x-t[e].x)*o,c=t[e+1].y-(t[e+2].y-t[e].y)*o;return i(t,e+1)&&(c=t[e+1].y),i(t,e)&&(l=t[e].y),a(t,e+1)&&(s=t[e+1].x),a(t,e)&&(r=t[e].x),(l>=Math.max(t[e].y,t[e+1].y)||l<=Math.min(t[e].y,t[e+1].y))&&(l=t[e].y),(c>=Math.max(t[e].y,t[e+1].y)||c<=Math.min(t[e].y,t[e+1].y))&&(c=t[e+1].y),(r>=Math.max(t[e].x,t[e+1].x)||r<=Math.min(t[e].x,t[e+1].x))&&(r=t[e].x),(s>=Math.max(t[e].x,t[e+1].x)||s<=Math.min(t[e].x,t[e+1].x))&&(s=t[e+1].x),{ctrA:{x:r,y:l},ctrB:{x:s,y:c}}}function f(t,e,i){return{x:i.x+t,y:i.y-e}}function p(t,e){if(e)while(o.isCollision(t,e))t.start.x>0?t.start.y--:t.start.x<0||t.start.y>0?t.start.y++:t.start.y--;return t}function x(t,e,i){var a=0;return t.map((function(t){if(t.color||(t.color=i.colors[a],a=(a+1)%i.colors.length),t.index||(t.index=0),t.type||(t.type=e.type),"undefined"==typeof t.show&&(t.show=!0),t.type||(t.type=e.type),t.pointShape||(t.pointShape="circle"),!t.legendShape)switch(t.type){case"line":t.legendShape="line";break;case"column":t.legendShape="rect";break;case"area":t.legendShape="triangle";break;default:t.legendShape="circle"}return t}))}function g(t,e){var i=0,a=e-t;return i=a>=1e4?1e3:a>=1e3?100:a>=100?10:a>=10?5:a>=1?1:a>=.1?.1:a>=.01?.01:a>=.001?.001:a>=1e-4?1e-4:a>=1e-5?1e-5:1e-6,{minRange:l(t,"lower",i),maxRange:l(e,"upper",i)}}function v(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a.fontSize;t=String(t);t=t.split("");for(var i=0,n=0;n<t.length;n++){var o=t[n];/[a-zA-Z]/.test(o)?i+=7:/[0-9]/.test(o)?i+=5.5:/\./.test(o)?i+=2.7:/-/.test(o)?i+=3.25:/[\u4e00-\u9fa5]/.test(o)?i+=10:/\(|\)/.test(o)?i+=3.73:/\s/.test(o)?i+=2.5:/%/.test(o)?i+=8:i+=10}return i*e/10}function y(t){return t.reduce((function(t,e){return(t.data?t.data:t).concat(e.data)}),[])}function m(t,e){for(var i=new Array(e),a=0;a<i.length;a++)i[a]=0;for(var n=0;n<t.length;n++)for(a=0;a<i.length;a++)i[a]+=t[n].data[a];return t.reduce((function(t,e){return(t.data?t.data:t).concat(e.data).concat(i)}),[])}function b(t,e,i){var a,n;return t.clientX?e.rotate?(n=e.height-t.clientX*e.pixelRatio,a=(t.pageY-i.currentTarget.offsetTop-e.height/e.pixelRatio/2*(e.pixelRatio-1))*e.pixelRatio):(a=t.clientX*e.pixelRatio,n=(t.pageY-i.currentTarget.offsetTop-e.height/e.pixelRatio/2*(e.pixelRatio-1))*e.pixelRatio):e.rotate?(n=e.height-t.x*e.pixelRatio,a=t.y*e.pixelRatio):(a=t.x*e.pixelRatio,n=t.y*e.pixelRatio),{x:a,y:n}}function w(t,e){for(var i=[],a=0;a<t.length;a++){var n=t[a];if(null!==n.data[e]&&"undefined"!==typeof n.data[e]&&n.show){var o={};o.color=n.color,o.type=n.type,o.style=n.style,o.pointShape=n.pointShape,o.disableLegend=n.disableLegend,o.name=n.name,o.show=n.show,o.data=n.format?n.format(n.data[e]):n.data[e],i.push(o)}}return i}function S(t){var e=t.map((function(t){return v(t)}));return Math.max.apply(null,e)}function T(t){for(var e=2*Math.PI/t,i=[],a=0;a<t;a++)i.push(e*a);return i.map((function(t){return-1*t+Math.PI/2}))}function A(t,e,i,a){for(var n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},o=t.map((function(t){var e=[];return e=a||t.data,{text:n.format?n.format(t,e[i]):t.name+": "+t.data,color:t.color}})),r=[],l={x:0,y:0},s=0;s<e.length;s++){var c=e[s];"undefined"!==typeof c[i]&&null!==c[i]&&r.push(c[i])}for(var h=0;h<r.length;h++){var d=r[h];l.x=Math.round(d.x),l.y+=d.y}return l.y/=r.length,{textList:o,offset:l}}function P(t,e,i,a){var n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},o=t.map((function(t){return{text:n.format?n.format(t,a[i]):t.name+": "+t.data,color:t.color,disableLegend:!!t.disableLegend}}));o=o.filter((function(t){if(!0!==t.disableLegend)return t}));for(var r=[],l={x:0,y:0},s=0;s<e.length;s++){var c=e[s];"undefined"!==typeof c[i]&&null!==c[i]&&r.push(c[i])}for(var h=0;h<r.length;h++){var d=r[h];l.x=Math.round(d.x),l.y+=d.y}return l.y/=r.length,{textList:o,offset:l}}function _(t,e,i,a,n,o){var r=o.color.upFill,l=o.color.downFill,s=[r,r,l,r],c=[],h={text:n[a],color:null};c.push(h),e.map((function(e){0==a?e.data[1]-e.data[0]<0?s[1]=l:s[1]=r:(e.data[0]<t[a-1][1]&&(s[0]=l),e.data[1]<e.data[0]&&(s[1]=l),e.data[2]>t[a-1][1]&&(s[2]=r),e.data[3]<t[a-1][1]&&(s[3]=l));var i={text:"开盘:"+e.data[0],color:s[0]},n={text:"收盘:"+e.data[1],color:s[1]},o={text:"最低:"+e.data[2],color:s[2]},h={text:"最高:"+e.data[3],color:s[3]};c.push(i,n,o,h)}));for(var d=[],u={x:0,y:0},f=0;f<i.length;f++){var p=i[f];"undefined"!==typeof p[a]&&null!==p[a]&&d.push(p[a])}return u.x=Math.round(d[0][0].x),{textList:c,offset:u}}function k(t){for(var e=[],i=0;i<t.length;i++)1==t[i].show&&e.push(t[i]);return e}function M(t,e,i,a){var n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,o=-1,r=i.chartData.eachSpacing/2,l=[];if(e&&e.length>0){for(var s=1;s<i.chartData.xAxisPoints.length;s++)l.push(i.chartData.xAxisPoints[s]-r);"line"!=i.type&&"area"!=i.type||"justify"!=i.xAxis.boundaryGap||(r=i.chartData.eachSpacing/2),i.categories||(r=0),F(t,i,a)&&l.forEach((function(e,i){t.x+n+r>e&&(o=i)}))}return o}function C(t,e,i){var a=-1;if(L(t,e.area)){for(var n=e.points,o=-1,r=0,l=n.length;r<l;r++)for(var s=n[r],c=0;c<s.length;c++){o+=1;var h=s[c]["area"];if(t.x>h[0]&&t.x<h[2]&&t.y>h[1]&&t.y<h[3]){a=o;break}}return a}return a}function L(t,e){return t.x>e.start.x&&t.x<e.end.x&&t.y>e.start.y&&t.y<e.end.y}function F(t,e,i){return t.x<=e.width-e.area[1]+10&&t.x>=e.area[3]-10&&t.y>=e.area[0]&&t.y<=e.height-e.area[2]}function D(t,e,i){var a=2*Math.PI/i,n=-1;if(O(t,e.center,e.radius)){var o=function(t){return t<0&&(t+=2*Math.PI),t>2*Math.PI&&(t-=2*Math.PI),t},r=Math.atan2(e.center.y-t.y,t.x-e.center.x);r*=-1,r<0&&(r+=2*Math.PI);var l=e.angleList.map((function(t){return t=o(-1*t),t}));l.forEach((function(t,e){var i=o(t-a/2),l=o(t+a/2);l<i&&(l+=2*Math.PI),(r>=i&&r<=l||r+2*Math.PI>=i&&r+2*Math.PI<=l)&&(n=e)}))}return n}function R(t,e){for(var i=-1,a=0,n=e.series.length;a<n;a++){var o=e.series[a];if(t.x>o.funnelArea[0]&&t.x<o.funnelArea[2]&&t.y>o.funnelArea[1]&&t.y<o.funnelArea[3]){i=a;break}}return i}function z(t,e){for(var i=-1,a=0,n=e.length;a<n;a++){var o=e[a];if(t.x>o.area[0]&&t.x<o.area[2]&&t.y>o.area[1]&&t.y<o.area[3]){i=a;break}}return i}function I(t,e){for(var i=-1,a=e.chartData.mapData,n=e.series,o=Bt(t.y,t.x,a.bounds,a.scale,a.xoffset,a.yoffset),r=[o.x,o.y],l=0,s=n.length;l<s;l++){var c=n[l].geometry.coordinates;if(Ht(r,c)){i=l;break}}return i}function W(t,e){var i=-1;if(O(t,e.center,e.radius)){var a=Math.atan2(e.center.y-t.y,t.x-e.center.x);a=-a;for(var n=0,o=e.series.length;n<o;n++){var r=e.series[n];if(h(a,r._start_,r._start_+2*r._proportion_*Math.PI)){i=n;break}}}return i}function O(t,e,i){return Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)<=Math.pow(i,2)}function E(t){var e=[],i=[];return t.forEach((function(t,a){null!==t?i.push(t):(i.length&&e.push(i),i=[])})),i.length&&e.push(i),e}function B(t,e,i,a){var n={area:{start:{x:0,y:0},end:{x:0,y:0},width:0,height:0,wholeWidth:0,wholeHeight:0},points:[],widthArr:[],heightArr:[]};if(!1===e.legend.show)return a.legendData=n,n;var o=e.legend.padding,r=e.legend.margin,l=e.legend.fontSize,s=15*e.pixelRatio,c=5*e.pixelRatio,h=Math.max(e.legend.lineHeight*e.pixelRatio,l);if("top"==e.legend.position||"bottom"==e.legend.position){for(var d=[],u=0,f=[],p=[],x=0;x<t.length;x++){var g=t[x],y=s+c+v(g.name||"undefined",l)+e.legend.itemGap;u+y>e.width-e.padding[1]-e.padding[3]?(d.push(p),f.push(u-e.legend.itemGap),u=y,p=[g]):(u+=y,p.push(g))}if(p.length){d.push(p),f.push(u-e.legend.itemGap),n.widthArr=f;var m=Math.max.apply(null,f);switch(e.legend.float){case"left":n.area.start.x=e.padding[3],n.area.end.x=e.padding[3]+2*o;break;case"right":n.area.start.x=e.width-e.padding[1]-m-2*o,n.area.end.x=e.width-e.padding[1];break;default:n.area.start.x=(e.width-m)/2-o,n.area.end.x=(e.width+m)/2+o}n.area.width=m+2*o,n.area.wholeWidth=m+2*o,n.area.height=d.length*h+2*o,n.area.wholeHeight=d.length*h+2*o+2*r,n.points=d}}else{var b=t.length,w=e.height-e.padding[0]-e.padding[2]-2*r-2*o,S=Math.min(Math.floor(w/h),b);switch(n.area.height=S*h+2*o,n.area.wholeHeight=S*h+2*o,e.legend.float){case"top":n.area.start.y=e.padding[0]+r,n.area.end.y=e.padding[0]+r+n.area.height;break;case"bottom":n.area.start.y=e.height-e.padding[2]-r-n.area.height,n.area.end.y=e.height-e.padding[2]-r;break;default:n.area.start.y=(e.height-n.area.height)/2,n.area.end.y=(e.height+n.area.height)/2}for(var T=b%S===0?b/S:Math.floor(b/S+1),A=[],P=0;P<T;P++){var _=t.slice(P*S,P*S+S);A.push(_)}if(n.points=A,A.length){for(var k=0;k<A.length;k++){for(var M=A[k],C=0,L=0;L<M.length;L++){var F=s+c+v(M[L].name||"undefined",l)+e.legend.itemGap;F>C&&(C=F)}n.widthArr.push(C),n.heightArr.push(M.length*h+2*o)}for(var D=0,R=0;R<n.widthArr.length;R++)D+=n.widthArr[R];n.area.width=D-e.legend.itemGap+2*o,n.area.wholeWidth=n.area.width+o}}switch(e.legend.position){case"top":n.area.start.y=e.padding[0]+r,n.area.end.y=e.padding[0]+r+n.area.height;break;case"bottom":n.area.start.y=e.height-e.padding[2]-n.area.height-r,n.area.end.y=e.height-e.padding[2]-r;break;case"left":n.area.start.x=e.padding[3],n.area.end.x=e.padding[3]+n.area.width;break;case"right":n.area.start.x=e.width-e.padding[1]-n.area.width,n.area.end.x=e.width-e.padding[1];break}return a.legendData=n,n}function N(t,e,i,a){var n={angle:0,xAxisHeight:i.xAxisHeight},o=t.map((function(t){return v(t,e.xAxis.fontSize||i.fontSize)})),r=Math.max.apply(this,o);return 1==e.xAxis.rotateLabel&&r+2*i.xAxisTextPadding>a&&(n.angle=45*Math.PI/180,n.xAxisHeight=2*i.xAxisTextPadding+r*Math.sin(n.angle)),n}function H(t,e,i){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1,n=y(t),o=[];n=n.filter((function(t){return"object"===typeof t&&null!==t?t.constructor.toString().indexOf("Array")>-1?null!==t:null!==t.value:null!==t})),n.map((function(t){"object"===typeof t?t.constructor.toString().indexOf("Array")>-1?"candle"==e.type?t.map((function(t){o.push(t)})):o.push(t[0]):o.push(t.value):o.push(t)}));var r=0,l=0;if(o.length>0&&(r=Math.min.apply(this,o),l=Math.max.apply(this,o)),a>-1?("number"===typeof e.xAxis.data[a].min&&(r=Math.min(e.xAxis.data[a].min,r)),"number"===typeof e.xAxis.data[a].max&&(l=Math.max(e.xAxis.data[a].max,l))):("number"===typeof e.xAxis.min&&(r=Math.min(e.xAxis.min,r)),"number"===typeof e.xAxis.max&&(l=Math.max(e.xAxis.max,l))),r===l){var s=l||10;l+=s}for(var c=r,h=l,d=[],u=(h-c)/e.xAxis.splitNumber,f=0;f<=e.xAxis.splitNumber;f++)d.push(c+u*f);return d}function j(t,e,i){var a={angle:0,xAxisHeight:i.xAxisHeight};a.ranges=H(t,e,i),a.rangesFormat=a.ranges.map((function(t){return t=e.xAxis.format?e.xAxis.format(t):o.toFixed(t,2),t}));var n=a.ranges.map((function(t){return t=o.toFixed(t,2),t=e.xAxis.format?e.xAxis.format(Number(t)):t,t}));a=Object.assign(a,tt(n,e,i));var r=a.eachSpacing,l=n.map((function(t){return v(t)})),s=Math.max.apply(this,l);return s+2*i.xAxisTextPadding>r&&(a.angle=45*Math.PI/180,a.xAxisHeight=2*i.xAxisTextPadding+s*Math.sin(a.angle)),!0===e.xAxis.disabled&&(a.xAxisHeight=0),a}function X(t,e,i,a,n){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,r=n.extra.radar||{};r.max=r.max||0;for(var l=Math.max(r.max,Math.max.apply(null,y(a))),s=[],c=function(n){var r=a[n],c={};c.color=r.color,c.legendShape=r.legendShape,c.pointShape=r.pointShape,c.data=[],r.data.forEach((function(a,n){var r={};r.angle=t[n],r.proportion=a/l,r.position=f(i*r.proportion*o*Math.cos(r.angle),i*r.proportion*o*Math.sin(r.angle),e),c.data.push(r)})),s.push(c)},h=0;h<a.length;h++)c(h);return s}function G(t,e){for(var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=0,n=0,o=0;o<t.length;o++){var r=t[o];r.data=null===r.data?0:r.data,a+=r.data}for(var l=0;l<t.length;l++){var s=t[l];s.data=null===s.data?0:s.data,s._proportion_=0===a?1/t.length*i:s.data/a*i,s._radius_=e}for(var c=0;c<t.length;c++){var h=t[c];h._start_=n,n+=2*h._proportion_*Math.PI}return t}function $(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;t=t.sort((function(t,e){return parseInt(e.data)-parseInt(t.data)}));for(var a=0;a<t.length;a++)t[a].radius=t[a].data/t[0].data*e*i,t[a]._proportion_=t[a].data/t[0].data;return t.reverse()}function q(t,e,i,a){for(var n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,o=0,r=0,l=[],s=0;s<t.length;s++){var c=t[s];c.data=null===c.data?0:c.data,o+=c.data,l.push(c.data)}for(var h=Math.min.apply(null,l),d=Math.max.apply(null,l),u=a-i,f=0;f<t.length;f++){var p=t[f];p.data=null===p.data?0:p.data,0===o||"area"==e?(p._proportion_=p.data/o*n,p._rose_proportion_=1/t.length*n):(p._proportion_=p.data/o*n,p._rose_proportion_=p.data/o*n),p._radius_=i+u*((p.data-h)/(d-h))}for(var x=0;x<t.length;x++){var g=t[x];g._start_=r,r+=2*g._rose_proportion_*Math.PI}return t}function U(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;1==i&&(i=.999999);for(var a=0;a<t.length;a++){var n=t[a];n.data=null===n.data?0:n.data;var o=void 0;o="circle"==e.type?2:e.endAngle<e.startAngle?2+e.endAngle-e.startAngle:e.startAngle-e.endAngle,n._proportion_=o*n.data*i+e.startAngle,n._proportion_>=2&&(n._proportion_=n._proportion_%2)}return t}function J(t,e,i){for(var a=e-i+1,n=e,o=0;o<t.length;o++)t[o].value=null===t[o].value?0:t[o].value,t[o]._startAngle_=n,t[o]._endAngle_=a*t[o].value+e,t[o]._endAngle_>=2&&(t[o]._endAngle_=t[o]._endAngle_%2),n=t[o]._endAngle_;return t}function Y(t,e,i){for(var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,n=0;n<t.length;n++){var o=t[n];if(o.data=null===o.data?0:o.data,"auto"==i.pointer.color){for(var r=0;r<e.length;r++)if(o.data<=e[r].value){o.color=e[r].color;break}}else o.color=i.pointer.color;var l=i.startAngle-i.endAngle+1;o._endAngle_=l*o.data+i.startAngle,o._oldAngle_=i.oldAngle,i.oldAngle<i.endAngle&&(o._oldAngle_+=2),o.data>=i.oldData?o._proportion_=(o._endAngle_-o._oldAngle_)*a+i.oldAngle:o._proportion_=o._oldAngle_-(o._oldAngle_-o._endAngle_)*a,o._proportion_>=2&&(o._proportion_=o._proportion_%2)}return t}function Q(t){t=G(t);for(var e=0,i=0;i<t.length;i++){var a=t[i],n=a.format?a.format(+a._proportion_.toFixed(2)):o.toFixed(100*a._proportion_)+"%";e=Math.max(e,v(n))}return e}function Z(t,e,i,a,n,o){return t.map((function(t){return null===t?null:(t.width=Math.ceil((e-2*n.columePadding)/i),o.extra.column&&o.extra.column.width&&+o.extra.column.width>0&&(t.width=Math.min(t.width,+o.extra.column.width)),t.width<=0&&(t.width=1),t.x+=(a+.5-i/2)*t.width,t)}))}function K(t,e,i,a,n,o,r){return t.map((function(t){return null===t?null:(t.width=Math.ceil((e-2*n.columePadding)/2),o.extra.column&&o.extra.column.width&&+o.extra.column.width>0&&(t.width=Math.min(t.width,+o.extra.column.width)),a>0&&(t.width-=2*r),t)}))}function V(t,e,i,a,n,o,r){return t.map((function(t,i){return null===t?null:(t.width=Math.ceil((e-2*n.columePadding)/2),o.extra.column&&o.extra.column.width&&+o.extra.column.width>0&&(t.width=Math.min(t.width,+o.extra.column.width)),t)}))}function tt(t,e,i){var a=e.width-e.area[1]-e.area[3],n=e.enableScroll?Math.min(e.xAxis.itemCount,t.length):t.length;("line"==e.type||"area"==e.type)&&n>1&&"justify"==e.xAxis.boundaryGap&&(n-=1);var o=a/n,r=[],l=e.area[3],s=e.width-e.area[1];return t.forEach((function(t,e){r.push(l+e*o)})),"justify"!==e.xAxis.boundaryGap&&(!0===e.enableScroll?r.push(l+t.length*o):r.push(s)),{xAxisPoints:r,startX:l,endX:s,eachSpacing:o}}function et(t,e,i,a,n,o,r){var l=arguments.length>7&&void 0!==arguments[7]?arguments[7]:1,s=[],c=o.height-o.area[0]-o.area[2];return t.forEach((function(t,r){if(null===t)s.push(null);else{var h=[];t.forEach((function(t,s){var d={};d.x=a[r]+Math.round(n/2);var u=t.value||t,f=c*(u-e)/(i-e);f*=l,d.y=o.height-Math.round(f)-o.area[2],h.push(d)})),s.push(h)}})),s}function it(t,e,i,a,n,o,r){var l=arguments.length>7&&void 0!==arguments[7]?arguments[7]:1,s="center";"line"!=o.type&&"area"!=o.type||(s=o.xAxis.boundaryGap);var c=[],h=o.height-o.area[0]-o.area[2],d=o.width-o.area[1]-o.area[3];return t.forEach((function(t,r){if(null===t)c.push(null);else{var u={};u.color=t.color,u.x=a[r];var f,p,x,g=t;if("object"===typeof t&&null!==t)if(t.constructor.toString().indexOf("Array")>-1)f=[].concat(o.chartData.xAxisData.ranges),p=f.shift(),x=f.pop(),g=t[1],u.x=o.area[3]+d*(t[0]-p)/(x-p);else g=t.value;"center"==s&&(u.x+=Math.round(n/2));var v=h*(g-e)/(i-e);v*=l,u.y=o.height-Math.round(v)-o.area[2],c.push(u)}})),c}function at(t,e,i,a,n,o,r,l,s){var c=arguments.length>9&&void 0!==arguments[9]?arguments[9]:1,h=[],d=o.height-o.area[0]-o.area[2];return t.forEach((function(t,r){if(null===t)h.push(null);else{var u={};if(u.color=t.color,u.x=a[r]+Math.round(n/2),l>0){for(var f=0,p=0;p<=l;p++)f+=s[p].data[r];var x=f-t,g=d*(f-e)/(i-e),v=d*(x-e)/(i-e)}else f=t,g=d*(f-e)/(i-e),v=0;var y=v;g*=c,y*=c,u.y=o.height-Math.round(g)-o.area[2],u.y0=o.height-Math.round(y)-o.area[2],h.push(u)}})),h}function nt(t,e,i,a){var n,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1;n="stack"==a?m(t,e.categories.length):y(t);var r=[];n=n.filter((function(t){return"object"===typeof t&&null!==t?t.constructor.toString().indexOf("Array")>-1?null!==t:null!==t.value:null!==t})),n.map((function(t){"object"===typeof t?t.constructor.toString().indexOf("Array")>-1?"candle"==e.type?t.map((function(t){r.push(t)})):r.push(t[1]):r.push(t.value):r.push(t)}));var l=0,s=0;if(r.length>0&&(l=Math.min.apply(this,r),s=Math.max.apply(this,r)),o>-1?("number"===typeof e.yAxis.data[o].min&&(l=Math.min(e.yAxis.data[o].min,l)),"number"===typeof e.yAxis.data[o].max&&(s=Math.max(e.yAxis.data[o].max,s))):("number"===typeof e.yAxis.min&&(l=Math.min(e.yAxis.min,l)),"number"===typeof e.yAxis.max&&(s=Math.max(e.yAxis.max,s))),l===s){var c=s||10;s+=c}for(var h=g(l,s),d=h.minRange,u=h.maxRange,f=[],p=(u-d)/e.yAxis.splitNumber,x=0;x<=e.yAxis.splitNumber;x++)f.push(d+p*x);return f.reverse()}function ot(t,e,i){var a=n({},{type:""},e.extra.column),r=e.yAxis.data.length,l=new Array(r);if(r>0){for(var s=0;s<r;s++){l[s]=[];for(var c=0;c<t.length;c++)t[c].index==s&&l[s].push(t[c])}for(var h=new Array(r),d=new Array(r),u=new Array(r),f=function(t){var n=e.yAxis.data[t];1==e.yAxis.disabled&&(n.disabled=!0),h[t]=nt(l[t],e,i,a.type,t);var r=n.fontSize||i.fontSize;u[t]={position:n.position?n.position:"left",width:0},d[t]=h[t].map((function(e){return e=o.toFixed(e,6),e=n.format?n.format(Number(e)):e,u[t].width=Math.max(u[t].width,v(e,r)+5),e}));var s=n.calibration?4*e.pixelRatio:0;u[t].width+=s+3*e.pixelRatio,!0===n.disabled&&(u[t].width=0)},p=0;p<r;p++)f(p)}else{h=new Array(1),d=new Array(1),u=new Array(1);h[0]=nt(t,e,i,a.type),u[0]={position:"left",width:0};var x=e.yAxis.fontSize||i.fontSize;d[0]=h[0].map((function(t){return t=o.toFixed(t,6),t=e.yAxis.format?e.yAxis.format(Number(t)):t,u[0].width=Math.max(u[0].width,v(t,x)+5),t})),u[0].width+=3*e.pixelRatio,!0===e.yAxis.disabled?(u[0]={position:"left",width:0},e.yAxis.data[0]={disabled:!0}):e.yAxis.data[0]={disabled:!1,position:"left",max:e.yAxis.max,min:e.yAxis.min,format:e.yAxis.format}}return{rangesFormat:d,ranges:h,yAxisWidth:u}}function rt(t,e,i,a,n){for(var o=[].concat(i.chartData.yAxisData.ranges),r=i.height-i.area[0]-i.area[2],l=i.area[0],s=[],c=0;c<o.length;c++){var h=o[c].shift(),d=o[c].pop(),u=h-(h-d)*(t-l)/r;u=i.yAxis.data[c].format?i.yAxis.data[c].format(Number(u)):u.toFixed(0),s.push(String(u))}return s}function lt(t,e){for(var i,a,n=e.height-e.area[0]-e.area[2],o=0;o<t.length;o++){t[o].yAxisIndex=t[o].yAxisIndex?t[o].yAxisIndex:0;var r=[].concat(e.chartData.yAxisData.ranges[t[o].yAxisIndex]);i=r.pop(),a=r.shift();var l=n*(t[o].value-i)/(a-i);t[o].y=e.height-Math.round(l)-e.area[2]}return t}function st(t,e){!0!==e.rotateLock?(t.translate(e.height,0),t.rotate(90*Math.PI/180)):!0!==e._rotate_&&(t.translate(e.height,0),t.rotate(90*Math.PI/180),e._rotate_=!0)}function ct(t,e,i,a,n){a.beginPath(),"hollow"==n.dataPointShapeType?(a.setStrokeStyle(e),a.setFillStyle(n.background),a.setLineWidth(2*n.pixelRatio)):(a.setStrokeStyle("#ffffff"),a.setFillStyle(e),a.setLineWidth(1*n.pixelRatio)),"diamond"===i?t.forEach((function(t,e){null!==t&&(a.moveTo(t.x,t.y-4.5),a.lineTo(t.x-4.5,t.y),a.lineTo(t.x,t.y+4.5),a.lineTo(t.x+4.5,t.y),a.lineTo(t.x,t.y-4.5))})):"circle"===i?t.forEach((function(t,e){null!==t&&(a.moveTo(t.x+2.5*n.pixelRatio,t.y),a.arc(t.x,t.y,3*n.pixelRatio,0,2*Math.PI,!1))})):"rect"===i?t.forEach((function(t,e){null!==t&&(a.moveTo(t.x-3.5,t.y-3.5),a.rect(t.x-3.5,t.y-3.5,7,7))})):"triangle"===i&&t.forEach((function(t,e){null!==t&&(a.moveTo(t.x,t.y-4.5),a.lineTo(t.x-4.5,t.y+4.5),a.lineTo(t.x+4.5,t.y+4.5),a.lineTo(t.x,t.y-4.5))})),a.closePath(),a.fill(),a.stroke()}function ht(t,e,i,a){var n=t.title.fontSize||e.titleFontSize,o=t.subtitle.fontSize||e.subtitleFontSize,r=t.title.name||"",l=t.subtitle.name||"",s=t.title.color||e.titleColor,c=t.subtitle.color||e.subtitleColor,h=r?n:0,d=l?o:0,u=5;if(l){var f=v(l,o),p=a.x-f/2+(t.subtitle.offsetX||0),x=a.y+o/2+(t.subtitle.offsetY||0);r&&(x+=(h+u)/2),i.beginPath(),i.setFontSize(o),i.setFillStyle(c),i.fillText(l,p,x),i.closePath(),i.stroke()}if(r){var g=v(r,n),y=a.x-g/2+(t.title.offsetX||0),m=a.y+n/2+(t.title.offsetY||0);l&&(m-=(d+u)/2),i.beginPath(),i.setFontSize(n),i.setFillStyle(s),i.fillText(r,y,m),i.closePath(),i.stroke()}}function dt(t,e,i,a){var n=e.data;t.forEach((function(t,o){if(null!==t){a.beginPath(),a.setFontSize(e.textSize||i.fontSize),a.setFillStyle(e.textColor||"#666666");var r=n[o];"object"===typeof n[o]&&null!==n[o]&&(r=n[o].constructor==Array?n[o][1]:n[o].value);var l=e.format?e.format(r):r;a.fillText(String(l),t.x-v(l,e.textSize||i.fontSize)/2,t.y-4),a.closePath(),a.stroke()}}))}function ut(t,e,i,a,n,o){e-=t.width/2+n.gaugeLabelTextMargin;for(var r=t.startAngle-t.endAngle+1,l=r/t.splitLine.splitNumber,s=t.endNumber-t.startNumber,c=s/t.splitLine.splitNumber,h=t.startAngle,d=t.startNumber,u=0;u<t.splitLine.splitNumber+1;u++){var f={x:e*Math.cos(h*Math.PI),y:e*Math.sin(h*Math.PI)},p=t.labelFormat?t.labelFormat(d):d;f.x+=i.x-v(p)/2,f.y+=i.y;var x=f.x,g=f.y;o.beginPath(),o.setFontSize(n.fontSize),o.setFillStyle(t.labelColor||"#666666"),o.fillText(p,x,g+n.fontSize/2),o.closePath(),o.stroke(),h+=l,h>=2&&(h%=2),d+=c}}function ft(t,e,i,a,n,r){var l=a.extra.radar||{};e+=n.radarLabelTextMargin,t.forEach((function(t,s){var c={x:e*Math.cos(t),y:e*Math.sin(t)},h=f(c.x,c.y,i),d=h.x,u=h.y;o.approximatelyEqual(c.x,0)?d-=v(a.categories[s]||"")/2:c.x<0&&(d-=v(a.categories[s]||"")),r.beginPath(),r.setFontSize(n.fontSize),r.setFillStyle(l.labelColor||"#666666"),r.fillText(a.categories[s]||"",d,u+n.fontSize/2),r.closePath(),r.stroke()}))}function pt(t,e,i,a,n,r){for(var l=i.pieChartLinePadding,s=[],c=null,h=t.map((function(t){var e=t.format?t.format(+t._proportion_.toFixed(2)):o.toFixed(100*t._proportion_.toFixed(4))+"%";t._rose_proportion_&&(t._proportion_=t._rose_proportion_);var i=2*Math.PI-(t._start_+2*Math.PI*t._proportion_/2),a=t.color,n=t._radius_;return{arc:i,text:e,color:a,radius:n,textColor:t.textColor,textSize:t.textSize}})),d=0;d<h.length;d++){var u=h[d],x=Math.cos(u.arc)*(u.radius+l),g=Math.sin(u.arc)*(u.radius+l),y=Math.cos(u.arc)*u.radius,m=Math.sin(u.arc)*u.radius,b=x>=0?x+i.pieChartTextPadding:x-i.pieChartTextPadding,w=g,S=v(u.text,u.textSize||i.fontSize),T=w;c&&o.isSameXCoordinateArea(c.start,{x:b})&&(T=b>0?Math.min(w,c.start.y):x<0||w>0?Math.max(w,c.start.y):Math.min(w,c.start.y)),b<0&&(b-=S);var A={lineStart:{x:y,y:m},lineEnd:{x:x,y:g},start:{x:b,y:T},width:S,height:i.fontSize,text:u.text,color:u.color,textColor:u.textColor,textSize:u.textSize};c=p(A,c),s.push(c)}for(var P=0;P<s.length;P++){var _=s[P],k=f(_.lineStart.x,_.lineStart.y,r),M=f(_.lineEnd.x,_.lineEnd.y,r),C=f(_.start.x,_.start.y,r);a.setLineWidth(1*e.pixelRatio),a.setFontSize(i.fontSize),a.beginPath(),a.setStrokeStyle(_.color),a.setFillStyle(_.color),a.moveTo(k.x,k.y);var L=_.start.x<0?C.x+_.width:C.x,F=_.start.x<0?C.x-5:C.x+5;a.quadraticCurveTo(M.x,M.y,L,C.y),a.moveTo(k.x,k.y),a.stroke(),a.closePath(),a.beginPath(),a.moveTo(C.x+_.width,C.y),a.arc(L,C.y,2,0,2*Math.PI),a.closePath(),a.fill(),a.beginPath(),a.setFontSize(_.textSize||i.fontSize),a.setFillStyle(_.textColor||"#666666"),a.fillText(_.text,F,C.y+3),a.closePath(),a.stroke(),a.closePath()}}function xt(t,e,i,a){var n=e.extra.tooltip||{};n.gridType=void 0==n.gridType?"solid":n.gridType,n.dashLength=void 0==n.dashLength?4:n.dashLength;var o=e.area[0],l=e.height-e.area[2];if("dash"==n.gridType&&a.setLineDash([n.dashLength,n.dashLength]),a.setStrokeStyle(n.gridColor||"#cccccc"),a.setLineWidth(1*e.pixelRatio),a.beginPath(),a.moveTo(t,o),a.lineTo(t,l),a.stroke(),a.setLineDash([]),n.xAxisLabel){var s=e.categories[e.tooltip.index];a.setFontSize(i.fontSize);var c=v(s,i.fontSize),h=t-.5*c,d=l;a.beginPath(),a.setFillStyle(r(n.labelBgColor||i.toolTipBackground,n.labelBgOpacity||i.toolTipOpacity)),a.setStrokeStyle(n.labelBgColor||i.toolTipBackground),a.setLineWidth(1*e.pixelRatio),a.rect(h-i.toolTipPadding,d,c+2*i.toolTipPadding,i.fontSize+2*i.toolTipPadding),a.closePath(),a.stroke(),a.fill(),a.beginPath(),a.setFontSize(i.fontSize),a.setFillStyle(n.labelFontColor||i.fontColor),a.fillText(String(s),h,d+i.toolTipPadding+i.fontSize),a.closePath(),a.stroke()}}function gt(t,e,i){for(var a=n({},{type:"solid",dashLength:4,data:[]},t.extra.markLine),o=t.area[3],l=t.width-t.area[1],s=lt(a.data,t),c=0;c<s.length;c++){var h=n({},{lineColor:"#DE4A42",showLabel:!1,labelFontColor:"#666666",labelBgColor:"#DFE8FF",labelBgOpacity:.8,yAxisIndex:0},s[c]);if("dash"==a.type&&i.setLineDash([a.dashLength,a.dashLength]),i.setStrokeStyle(h.lineColor),i.setLineWidth(1*t.pixelRatio),i.beginPath(),i.moveTo(o,h.y),i.lineTo(l,h.y),i.stroke(),i.setLineDash([]),h.showLabel){var d=t.yAxis.format?t.yAxis.format(Number(h.value)):h.value;i.setFontSize(e.fontSize);var u=v(d,e.fontSize),f=t.padding[3]+e.yAxisTitleWidth-e.toolTipPadding,p=Math.max(t.area[3],u+2*e.toolTipPadding),x=p-f,g=f+(x-u)/2,y=h.y;i.setFillStyle(r(h.labelBgColor,h.labelBgOpacity)),i.setStrokeStyle(h.labelBgColor),i.setLineWidth(1*t.pixelRatio),i.beginPath(),i.rect(f,y-.5*e.fontSize-e.toolTipPadding,x,e.fontSize+2*e.toolTipPadding),i.closePath(),i.stroke(),i.fill(),i.beginPath(),i.setFontSize(e.fontSize),i.setFillStyle(h.labelFontColor),i.fillText(String(d),g,y+.5*e.fontSize),i.stroke()}}}function vt(t,e,i,a,o){var l=n({},{gridType:"solid",dashLength:4},t.extra.tooltip),s=t.area[3],c=t.width-t.area[1];if("dash"==l.gridType&&i.setLineDash([l.dashLength,l.dashLength]),i.setStrokeStyle(l.gridColor||"#cccccc"),i.setLineWidth(1*t.pixelRatio),i.beginPath(),i.moveTo(s,t.tooltip.offset.y),i.lineTo(c,t.tooltip.offset.y),i.stroke(),i.setLineDash([]),l.yAxisLabel)for(var h=rt(t.tooltip.offset.y,t.series,t,e,a),d=t.chartData.yAxisData.yAxisWidth,u=t.area[3],f=t.width-t.area[1],p=0;p<h.length;p++){i.setFontSize(e.fontSize);var x=v(h[p],e.fontSize),g=void 0,y=void 0,m=void 0;"left"==d[p].position?(g=u-d[p].width,y=Math.max(g,g+x+2*e.toolTipPadding)):(g=f,y=Math.max(g+d[p].width,g+x+2*e.toolTipPadding)),m=y-g;var b=g+(m-x)/2,w=t.tooltip.offset.y;i.beginPath(),i.setFillStyle(r(l.labelBgColor||e.toolTipBackground,l.labelBgOpacity||e.toolTipOpacity)),i.setStrokeStyle(l.labelBgColor||e.toolTipBackground),i.setLineWidth(1*t.pixelRatio),i.rect(g,w-.5*e.fontSize-e.toolTipPadding,m,e.fontSize+2*e.toolTipPadding),i.closePath(),i.stroke(),i.fill(),i.beginPath(),i.setFontSize(e.fontSize),i.setFillStyle(l.labelFontColor||e.fontColor),i.fillText(h[p],b,w+.5*e.fontSize),i.closePath(),i.stroke(),"left"==d[p].position?u-=d[p].width+t.yAxis.padding:f+=d[p].width+t.yAxis.padding}}function yt(t,e,i,a,o){var l=n({},{activeBgColor:"#000000",activeBgOpacity:.08},e.extra.tooltip),s=e.area[0],c=e.height-e.area[2];a.beginPath(),a.setFillStyle(r(l.activeBgColor,l.activeBgOpacity)),a.rect(t-o/2,s,o,c-s),a.closePath(),a.fill()}function mt(t,e,i,a,o,l,s){var c=n({},{showBox:!0,bgColor:"#000000",bgOpacity:.7,fontColor:"#FFFFFF"},i.extra.tooltip),h=4*i.pixelRatio,d=5*i.pixelRatio,u=8*i.pixelRatio,f=!1;"line"!=i.type&&"area"!=i.type&&"candle"!=i.type&&"mix"!=i.type||xt(i.tooltip.offset.x,i,a,o),e=n({x:0,y:0},e),e.y-=8*i.pixelRatio;var p=t.map((function(t){return v(t.text,a.fontSize)})),x=h+d+4*a.toolTipPadding+Math.max.apply(null,p),g=2*a.toolTipPadding+t.length*a.toolTipLineHeight;0!=c.showBox&&(e.x-Math.abs(i._scrollDistance_)+u+x>i.width&&(f=!0),g+e.y>i.height&&(e.y=i.height-g),o.beginPath(),o.setFillStyle(r(c.bgColor||a.toolTipBackground,c.bgOpacity||a.toolTipOpacity)),f?(o.moveTo(e.x,e.y+10*i.pixelRatio),o.lineTo(e.x-u,e.y+10*i.pixelRatio-5*i.pixelRatio),o.lineTo(e.x-u,e.y),o.lineTo(e.x-u-Math.round(x),e.y),o.lineTo(e.x-u-Math.round(x),e.y+g),o.lineTo(e.x-u,e.y+g),o.lineTo(e.x-u,e.y+10*i.pixelRatio+5*i.pixelRatio),o.lineTo(e.x,e.y+10*i.pixelRatio)):(o.moveTo(e.x,e.y+10*i.pixelRatio),o.lineTo(e.x+u,e.y+10*i.pixelRatio-5*i.pixelRatio),o.lineTo(e.x+u,e.y),o.lineTo(e.x+u+Math.round(x),e.y),o.lineTo(e.x+u+Math.round(x),e.y+g),o.lineTo(e.x+u,e.y+g),o.lineTo(e.x+u,e.y+10*i.pixelRatio+5*i.pixelRatio),o.lineTo(e.x,e.y+10*i.pixelRatio)),o.closePath(),o.fill(),t.forEach((function(t,i){if(null!==t.color){o.beginPath(),o.setFillStyle(t.color);var n=e.x+u+2*a.toolTipPadding,r=e.y+(a.toolTipLineHeight-a.fontSize)/2+a.toolTipLineHeight*i+a.toolTipPadding+1;f&&(n=e.x-x-u+2*a.toolTipPadding),o.fillRect(n,r,h,a.fontSize),o.closePath()}})),t.forEach((function(t,i){var n=e.x+u+2*a.toolTipPadding+h+d;f&&(n=e.x-x-u+2*a.toolTipPadding+ +h+d);var r=e.y+(a.toolTipLineHeight-a.fontSize)/2+a.toolTipLineHeight*i+a.toolTipPadding;o.beginPath(),o.setFontSize(a.fontSize),o.setFillStyle(c.fontColor),o.fillText(t.text,n,r+a.fontSize),o.closePath(),o.stroke()})))}function bt(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,r=e.chartData.xAxisData,l=r.xAxisPoints,s=r.eachSpacing,c=n({},{type:"group",width:s/2,meter:{border:4,fillColor:"#FFFFFF"}},e.extra.column),h=[];a.save();var d=-2,u=l.length+2;return e._scrollDistance_&&0!==e._scrollDistance_&&!0===e.enableScroll&&(a.translate(e._scrollDistance_,0),d=Math.floor(-e._scrollDistance_/s)-2,u=d+e.xAxis.itemCount+4),e.tooltip&&e.tooltip.textList&&e.tooltip.textList.length&&1===o&&yt(e.tooltip.offset.x,e,i,a,s),t.forEach((function(n,r){var f,p,x;f=[].concat(e.chartData.yAxisData.ranges[n.index]),p=f.pop(),x=f.shift();var g=n.data;switch(c.type){case"group":var v=it(g,p,x,l,s,e,i,o),y=at(g,p,x,l,s,e,i,r,t,o);h.push(y),v=Z(v,s,t.length,r,i,e);for(var m=0;m<v.length;m++){var b=v[m];if(null!==b&&m>d&&m<u){a.beginPath(),a.setStrokeStyle(b.color||n.color),a.setLineWidth(1),a.setFillStyle(b.color||n.color);var w=b.x-b.width/2,S=e.height-b.y-e.area[2];a.moveTo(w,b.y),a.lineTo(w+b.width-2,b.y),a.lineTo(w+b.width-2,e.height-e.area[2]),a.lineTo(w,e.height-e.area[2]),a.lineTo(w,b.y),a.closePath(),a.stroke(),a.fill()}}break;case"stack":v=at(g,p,x,l,s,e,i,r,t,o);h.push(v),v=V(v,s,t.length,r,i,e,t);for(var T=0;T<v.length;T++){var A=v[T];if(null!==A&&T>d&&T<u){a.beginPath(),a.setFillStyle(A.color||n.color);w=A.x-A.width/2+1,S=e.height-A.y-e.area[2];var P=e.height-A.y0-e.area[2];r>0&&(S-=P),a.moveTo(w,A.y),a.fillRect(w,A.y,A.width-2,S),a.closePath(),a.fill()}}break;case"meter":v=it(g,p,x,l,s,e,i,o);if(h.push(v),v=K(v,s,t.length,r,i,e,c.meter.border),0==r)for(var _=0;_<v.length;_++){var k=v[_];if(null!==k&&_>d&&_<u){a.beginPath(),a.setFillStyle(c.meter.fillColor);w=k.x-k.width/2,S=e.height-k.y-e.area[2];a.moveTo(w,k.y),a.fillRect(w,k.y,k.width,S),a.closePath(),a.fill(),c.meter.border>0&&(a.beginPath(),a.setStrokeStyle(n.color),a.setLineWidth(c.meter.border*e.pixelRatio),a.moveTo(w+.5*c.meter.border,k.y+S),a.lineTo(w+.5*c.meter.border,k.y+.5*c.meter.border),a.lineTo(w+k.width-.5*c.meter.border,k.y+.5*c.meter.border),a.lineTo(w+k.width-.5*c.meter.border,k.y+S),a.stroke())}}else for(var M=0;M<v.length;M++){var C=v[M];if(null!==C&&M>d&&M<u){a.beginPath(),a.setFillStyle(C.color||n.color);w=C.x-C.width/2,S=e.height-C.y-e.area[2];a.moveTo(w,C.y),a.fillRect(w,C.y,C.width,S),a.closePath(),a.fill()}}break}})),!1!==e.dataLabel&&1===o&&t.forEach((function(n,r){var h,d,u;h=[].concat(e.chartData.yAxisData.ranges[n.index]),d=h.pop(),u=h.shift();var f=n.data;switch(c.type){case"group":var p=it(f,d,u,l,s,e,i,o);p=Z(p,s,t.length,r,i,e),dt(p,n,i,a);break;case"stack":p=at(f,d,u,l,s,e,i,r,t,o);dt(p,n,i,a);break;case"meter":p=it(f,d,u,l,s,e,i,o);dt(p,n,i,a);break}})),a.restore(),{xAxisPoints:l,calPoints:h,eachSpacing:s}}function wt(t,e,i,a,o){var r=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,l=n({},{color:{},average:{}},i.extra.candle);l.color=n({},{upLine:"#f04864",upFill:"#f04864",downLine:"#2fc25b",downFill:"#2fc25b"},l.color),l.average=n({},{show:!1,name:[],day:[],color:a.colors},l.average),i.extra.candle=l;var s=i.chartData.xAxisData,c=s.xAxisPoints,h=s.eachSpacing,d=[];o.save();var f=-2,p=c.length+2,x=0,g=i.width+h;return i._scrollDistance_&&0!==i._scrollDistance_&&!0===i.enableScroll&&(o.translate(i._scrollDistance_,0),f=Math.floor(-i._scrollDistance_/h)-2,p=f+i.xAxis.itemCount+4,x=-i._scrollDistance_-h+i.area[3],g=x+(i.xAxis.itemCount+4)*h),(l.average.show||e)&&e.forEach((function(t,e){var n,l,s;n=[].concat(i.chartData.yAxisData.ranges[t.index]),l=n.pop(),s=n.shift();for(var d=t.data,f=it(d,l,s,c,h,i,a,r),p=E(f),v=0;v<p.length;v++){var y=p[v];if(o.beginPath(),o.setStrokeStyle(t.color),o.setLineWidth(1),1===y.length)o.moveTo(y[0].x,y[0].y),o.arc(y[0].x,y[0].y,1,0,2*Math.PI);else{o.moveTo(y[0].x,y[0].y);for(var m=0,b=0;b<y.length;b++){var w=y[b];if(0==m&&w.x>x&&(o.moveTo(w.x,w.y),m=1),b>0&&w.x>x&&w.x<g){var S=u(y,b-1);o.bezierCurveTo(S.ctrA.x,S.ctrA.y,S.ctrB.x,S.ctrB.y,w.x,w.y)}}o.moveTo(y[0].x,y[0].y)}o.closePath(),o.stroke()}})),t.forEach((function(t,e){var n,s,u;n=[].concat(i.chartData.yAxisData.ranges[t.index]),s=n.pop(),u=n.shift();var x=t.data,g=et(x,s,u,c,h,i,a,r);d.push(g);for(var v=E(g),y=0;y<v[0].length;y++)if(y>f&&y<p){var m=v[0][y];o.beginPath(),x[y][1]-x[y][0]>0?(o.setStrokeStyle(l.color.upLine),o.setFillStyle(l.color.upFill),o.setLineWidth(1*i.pixelRatio),o.moveTo(m[3].x,m[3].y),o.lineTo(m[1].x,m[1].y),o.lineTo(m[1].x-h/4,m[1].y),o.lineTo(m[0].x-h/4,m[0].y),o.lineTo(m[0].x,m[0].y),o.lineTo(m[2].x,m[2].y),o.lineTo(m[0].x,m[0].y),o.lineTo(m[0].x+h/4,m[0].y),o.lineTo(m[1].x+h/4,m[1].y),o.lineTo(m[1].x,m[1].y),o.moveTo(m[3].x,m[3].y)):(o.setStrokeStyle(l.color.downLine),o.setFillStyle(l.color.downFill),o.setLineWidth(1*i.pixelRatio),o.moveTo(m[3].x,m[3].y),o.lineTo(m[0].x,m[0].y),o.lineTo(m[0].x-h/4,m[0].y),o.lineTo(m[1].x-h/4,m[1].y),o.lineTo(m[1].x,m[1].y),o.lineTo(m[2].x,m[2].y),o.lineTo(m[1].x,m[1].y),o.lineTo(m[1].x+h/4,m[1].y),o.lineTo(m[0].x+h/4,m[0].y),o.lineTo(m[0].x,m[0].y),o.moveTo(m[3].x,m[3].y)),o.closePath(),o.fill(),o.stroke()}})),o.restore(),{xAxisPoints:c,calPoints:d,eachSpacing:h}}function St(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,l=n({},{type:"straight",opacity:.2,addLine:!1,width:2,gradient:!1},e.extra.area),s=e.chartData.xAxisData,c=s.xAxisPoints,h=s.eachSpacing,d=e.height-e.area[2],f=[];a.save();var p=0,x=e.width+h;return e._scrollDistance_&&0!==e._scrollDistance_&&!0===e.enableScroll&&(a.translate(e._scrollDistance_,0),p=-e._scrollDistance_-h+e.area[3],x=p+(e.xAxis.itemCount+4)*h),t.forEach((function(t,n){var s,g,v;s=[].concat(e.chartData.yAxisData.ranges[t.index]),g=s.pop(),v=s.shift();var y=t.data,m=it(y,g,v,c,h,e,i,o);f.push(m);for(var b=E(m),w=0;w<b.length;w++){var S=b[w];if(a.beginPath(),a.setStrokeStyle(r(t.color,l.opacity)),l.gradient){var T=a.createLinearGradient(0,e.area[0],0,e.height-e.area[2]);T.addColorStop("0",r(t.color,l.opacity)),T.addColorStop("1.0",r("#FFFFFF",.1)),a.setFillStyle(T)}else a.setFillStyle(r(t.color,l.opacity));if(a.setLineWidth(l.width*e.pixelRatio),S.length>1){var A=S[0],P=S[S.length-1];a.moveTo(A.x,A.y);var _=0;if("curve"===l.type)for(var k=0;k<S.length;k++){var M=S[k];if(0==_&&M.x>p&&(a.moveTo(M.x,M.y),_=1),k>0&&M.x>p&&M.x<x){var C=u(S,k-1);a.bezierCurveTo(C.ctrA.x,C.ctrA.y,C.ctrB.x,C.ctrB.y,M.x,M.y)}}else for(var L=0;L<S.length;L++){var F=S[L];0==_&&F.x>p&&(a.moveTo(F.x,F.y),_=1),L>0&&F.x>p&&F.x<x&&a.lineTo(F.x,F.y)}a.lineTo(P.x,d),a.lineTo(A.x,d),a.lineTo(A.x,A.y)}else{var D=S[0];a.moveTo(D.x-h/2,D.y),a.lineTo(D.x+h/2,D.y),a.lineTo(D.x+h/2,d),a.lineTo(D.x-h/2,d),a.moveTo(D.x-h/2,D.y)}if(a.closePath(),a.fill(),l.addLine){if("dash"==t.lineType){var R=t.dashLength?t.dashLength:8;R*=e.pixelRatio,a.setLineDash([R,R])}if(a.beginPath(),a.setStrokeStyle(t.color),a.setLineWidth(l.width*e.pixelRatio),1===S.length)a.moveTo(S[0].x,S[0].y),a.arc(S[0].x,S[0].y,1,0,2*Math.PI);else{a.moveTo(S[0].x,S[0].y);var z=0;if("curve"===l.type)for(var I=0;I<S.length;I++){var W=S[I];if(0==z&&W.x>p&&(a.moveTo(W.x,W.y),z=1),I>0&&W.x>p&&W.x<x){var O=u(S,I-1);a.bezierCurveTo(O.ctrA.x,O.ctrA.y,O.ctrB.x,O.ctrB.y,W.x,W.y)}}else for(var B=0;B<S.length;B++){var N=S[B];0==z&&N.x>p&&(a.moveTo(N.x,N.y),z=1),B>0&&N.x>p&&N.x<x&&a.lineTo(N.x,N.y)}a.moveTo(S[0].x,S[0].y)}a.stroke(),a.setLineDash([])}}!1!==e.dataPointShape&&ct(m,t.color,t.pointShape,a,e)})),!1!==e.dataLabel&&1===o&&t.forEach((function(t,n){var r,l,s;r=[].concat(e.chartData.yAxisData.ranges[t.index]),l=r.pop(),s=r.shift();var d=t.data,u=it(d,l,s,c,h,e,i,o);dt(u,t,i,a)})),a.restore(),{xAxisPoints:c,calPoints:f,eachSpacing:h}}function Tt(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,r=n({},{type:"straight",width:2},e.extra.line);r.width*=e.pixelRatio;var l=e.chartData.xAxisData,s=l.xAxisPoints,c=l.eachSpacing,h=[];a.save();var d=0,f=e.width+c;return e._scrollDistance_&&0!==e._scrollDistance_&&!0===e.enableScroll&&(a.translate(e._scrollDistance_,0),d=-e._scrollDistance_-c+e.area[3],f=d+(e.xAxis.itemCount+4)*c),t.forEach((function(t,n){var l,p,x;l=[].concat(e.chartData.yAxisData.ranges[t.index]),p=l.pop(),x=l.shift();var g=t.data,v=it(g,p,x,s,c,e,i,o);h.push(v);var y=E(v);if("dash"==t.lineType){var m=t.dashLength?t.dashLength:8;m*=e.pixelRatio,a.setLineDash([m,m])}a.beginPath(),a.setStrokeStyle(t.color),a.setLineWidth(r.width),y.forEach((function(t,e){if(1===t.length)a.moveTo(t[0].x,t[0].y),a.arc(t[0].x,t[0].y,1,0,2*Math.PI);else{a.moveTo(t[0].x,t[0].y);var i=0;if("curve"===r.type)for(var n=0;n<t.length;n++){var o=t[n];if(0==i&&o.x>d&&(a.moveTo(o.x,o.y),i=1),n>0&&o.x>d&&o.x<f){var l=u(t,n-1);a.bezierCurveTo(l.ctrA.x,l.ctrA.y,l.ctrB.x,l.ctrB.y,o.x,o.y)}}if("straight"===r.type)for(var s=0;s<t.length;s++){var c=t[s];0==i&&c.x>d&&(a.moveTo(c.x,c.y),i=1),s>0&&c.x>d&&c.x<f&&a.lineTo(c.x,c.y)}if("step"===r.type)for(var h=0;h<t.length;h++){var p=t[h];0==i&&p.x>d&&(a.moveTo(p.x,p.y),i=1),h>0&&p.x>d&&p.x<f&&(a.lineTo(p.x,t[h-1].y),a.lineTo(p.x,p.y))}a.moveTo(t[0].x,t[0].y)}})),a.stroke(),a.setLineDash([]),!1!==e.dataPointShape&&ct(v,t.color,t.pointShape,a,e)})),!1!==e.dataLabel&&1===o&&t.forEach((function(t,n){var r,l,h;r=[].concat(e.chartData.yAxisData.ranges[t.index]),l=r.pop(),h=r.shift();var d=t.data,u=it(d,l,h,s,c,e,i,o);dt(u,t,i,a)})),a.restore(),{xAxisPoints:s,calPoints:h,eachSpacing:c}}function At(t,e,i,a){var n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,o=e.chartData.xAxisData,l=o.xAxisPoints,s=o.eachSpacing,c=e.height-e.area[2],h=[],d=0,f=0;t.forEach((function(t,e){"column"==t.type&&(f+=1)})),a.save();var p=-2,x=l.length+2,g=0,v=e.width+s;if(e._scrollDistance_&&0!==e._scrollDistance_&&!0===e.enableScroll&&(a.translate(e._scrollDistance_,0),p=Math.floor(-e._scrollDistance_/s)-2,x=p+e.xAxis.itemCount+4,g=-e._scrollDistance_-s+e.area[3],v=g+(e.xAxis.itemCount+4)*s),t.forEach((function(t,o){var y,m,b;y=[].concat(e.chartData.yAxisData.ranges[t.index]),m=y.pop(),b=y.shift();var w=t.data,S=it(w,m,b,l,s,e,i,n);if(h.push(S),"column"==t.type){S=Z(S,s,f,d,i,e);for(var T=0;T<S.length;T++){var A=S[T];if(null!==A&&T>p&&T<x){a.beginPath(),a.setStrokeStyle(A.color||t.color),a.setLineWidth(1),a.setFillStyle(A.color||t.color);var P=A.x-A.width/2;e.height,A.y,e.area[2];a.moveTo(P,A.y),a.moveTo(P,A.y),a.lineTo(P+A.width-2,A.y),a.lineTo(P+A.width-2,e.height-e.area[2]),a.lineTo(P,e.height-e.area[2]),a.lineTo(P,A.y),a.closePath(),a.stroke(),a.fill(),a.closePath(),a.fill()}}d+=1}if("area"==t.type)for(var _=E(S),k=0;k<_.length;k++){var M=_[k];if(a.beginPath(),a.setStrokeStyle(t.color),a.setFillStyle(r(t.color,.2)),a.setLineWidth(2*e.pixelRatio),M.length>1){var C=M[0],L=M[M.length-1];a.moveTo(C.x,C.y);var F=0;if("curve"===t.style)for(var D=0;D<M.length;D++){var R=M[D];if(0==F&&R.x>g&&(a.moveTo(R.x,R.y),F=1),D>0&&R.x>g&&R.x<v){var z=u(M,D-1);a.bezierCurveTo(z.ctrA.x,z.ctrA.y,z.ctrB.x,z.ctrB.y,R.x,R.y)}}else for(var I=0;I<M.length;I++){var W=M[I];0==F&&W.x>g&&(a.moveTo(W.x,W.y),F=1),I>0&&W.x>g&&W.x<v&&a.lineTo(W.x,W.y)}a.lineTo(L.x,c),a.lineTo(C.x,c),a.lineTo(C.x,C.y)}else{var O=M[0];a.moveTo(O.x-s/2,O.y),a.lineTo(O.x+s/2,O.y),a.lineTo(O.x+s/2,c),a.lineTo(O.x-s/2,c),a.moveTo(O.x-s/2,O.y)}a.closePath(),a.fill()}if("line"==t.type){var B=E(S);B.forEach((function(i,n){if("dash"==t.lineType){var o=t.dashLength?t.dashLength:8;o*=e.pixelRatio,a.setLineDash([o,o])}if(a.beginPath(),a.setStrokeStyle(t.color),a.setLineWidth(2*e.pixelRatio),1===i.length)a.moveTo(i[0].x,i[0].y),a.arc(i[0].x,i[0].y,1,0,2*Math.PI);else{a.moveTo(i[0].x,i[0].y);var r=0;if("curve"==t.style)for(var l=0;l<i.length;l++){var s=i[l];if(0==r&&s.x>g&&(a.moveTo(s.x,s.y),r=1),l>0&&s.x>g&&s.x<v){var c=u(i,l-1);a.bezierCurveTo(c.ctrA.x,c.ctrA.y,c.ctrB.x,c.ctrB.y,s.x,s.y)}}else for(var h=0;h<i.length;h++){var d=i[h];0==r&&d.x>g&&(a.moveTo(d.x,d.y),r=1),h>0&&d.x>g&&d.x<v&&a.lineTo(d.x,d.y)}a.moveTo(i[0].x,i[0].y)}a.stroke(),a.setLineDash([])}))}"point"==t.type&&(t.addPoint=!0),1==t.addPoint&&"column"!==t.type&&ct(S,t.color,t.pointShape,a,e)})),!1!==e.dataLabel&&1===n){d=0;t.forEach((function(t,o){var r,c,h;r=[].concat(e.chartData.yAxisData.ranges[t.index]),c=r.pop(),h=r.shift();var u=t.data,p=it(u,c,h,l,s,e,i,n);"column"!==t.type?dt(p,t,i,a):(p=Z(p,s,f,d,i,e),dt(p,t,i,a),d+=1)}))}return a.restore(),{xAxisPoints:l,calPoints:h,eachSpacing:s}}function Pt(t,e,i,a,n,o){var r=t.extra.tooltip||{};r.horizentalLine&&t.tooltip&&1===a&&("line"==t.type||"area"==t.type||"column"==t.type||"candle"==t.type||"mix"==t.type)&&vt(t,e,i,n,o),i.save(),t._scrollDistance_&&0!==t._scrollDistance_&&!0===t.enableScroll&&i.translate(t._scrollDistance_,0),t.tooltip&&t.tooltip.textList&&t.tooltip.textList.length&&1===a&&mt(t.tooltip.textList,t.tooltip.offset,t,e,i,n,o),i.restore()}function _t(t,e,i,a){var n=e.chartData.xAxisData,o=n.xAxisPoints,r=n.startX,l=n.endX,s=n.eachSpacing,c="center";"line"!=e.type&&"area"!=e.type||(c=e.xAxis.boundaryGap);var h=e.height-e.area[2],u=e.area[0];if(e.enableScroll&&e.xAxis.scrollShow){var f=e.height-e.area[2]+i.xAxisHeight,p=l-r,x=s*(o.length-1),g=p*p/x,y=0;e._scrollDistance_&&(y=-e._scrollDistance_*p/x),a.beginPath(),a.setLineCap("round"),a.setLineWidth(6*e.pixelRatio),a.setStrokeStyle(e.xAxis.scrollBackgroundColor||"#EFEBEF"),a.moveTo(r,f),a.lineTo(l,f),a.stroke(),a.closePath(),a.beginPath(),a.setLineCap("round"),a.setLineWidth(6*e.pixelRatio),a.setStrokeStyle(e.xAxis.scrollColor||"#A6A6A6"),a.moveTo(r+y,f),a.lineTo(r+y+g,f),a.stroke(),a.closePath(),a.setLineCap("butt")}if(a.save(),e._scrollDistance_&&0!==e._scrollDistance_&&a.translate(e._scrollDistance_,0),!0===e.xAxis.calibration&&(a.setStrokeStyle(e.xAxis.gridColor||"#cccccc"),a.setLineCap("butt"),a.setLineWidth(1*e.pixelRatio),o.forEach((function(t,i){i>0&&(a.beginPath(),a.moveTo(t-s/2,h),a.lineTo(t-s/2,h+3*e.pixelRatio),a.closePath(),a.stroke())}))),!0!==e.xAxis.disableGrid&&(a.setStrokeStyle(e.xAxis.gridColor||"#cccccc"),a.setLineCap("butt"),a.setLineWidth(1*e.pixelRatio),"dash"==e.xAxis.gridType&&a.setLineDash([e.xAxis.dashLength,e.xAxis.dashLength]),e.xAxis.gridEval=e.xAxis.gridEval||1,o.forEach((function(t,i){i%e.xAxis.gridEval==0&&(a.beginPath(),a.moveTo(t,h),a.lineTo(t,u),a.stroke())})),a.setLineDash([])),!0!==e.xAxis.disabled){var m=t.length;e.xAxis.labelCount&&(m=e.xAxis.itemCount?Math.ceil(t.length/e.xAxis.itemCount*e.xAxis.labelCount):e.xAxis.labelCount,m-=1);for(var b=Math.ceil(t.length/m),w=[],S=t.length,T=0;T<S;T++)T%b!==0?w.push(""):w.push(t[T]);w[S-1]=t[S-1];var A=e.xAxis.fontSize||i.fontSize;0===i._xAxisTextAngle_?w.forEach((function(t,n){var r=-v(String(t),A)/2;"center"==c&&(r+=s/2);var l=0;e.xAxis.scrollShow&&(l=6*e.pixelRatio),a.beginPath(),a.setFontSize(A),a.setFillStyle(e.xAxis.fontColor||"#666666"),a.fillText(String(t),o[n]+r,h+A+(i.xAxisHeight-l-A)/2),a.closePath(),a.stroke()})):w.forEach((function(t,n){a.save(),a.beginPath(),a.setFontSize(A),a.setFillStyle(e.xAxis.fontColor||"#666666");var r=v(String(t),A),l=-r;"center"==c&&(l+=s/2);var u=d(o[n]+s/2,h+A/2+5,e.height),f=u.transX,p=u.transY;a.rotate(-1*i._xAxisTextAngle_),a.translate(f,p),a.fillText(String(t),o[n]+l,h+A+5),a.closePath(),a.stroke(),a.restore()}))}a.restore(),e.xAxis.axisLine&&(a.beginPath(),a.setStrokeStyle(e.xAxis.axisLineColor),a.setLineWidth(1*e.pixelRatio),a.moveTo(r,e.height-e.area[2]),a.lineTo(l,e.height-e.area[2]),a.stroke())}function kt(t,e,i,a){if(!0!==e.yAxis.disableGrid){for(var n=e.height-e.area[0]-e.area[2],o=n/e.yAxis.splitNumber,r=e.area[3],l=e.chartData.xAxisData.xAxisPoints,s=e.chartData.xAxisData.eachSpacing,c=s*(l.length-1),h=r+c,d=[],u=0;u<e.yAxis.splitNumber+1;u++)d.push(e.height-e.area[2]-o*u);a.save(),e._scrollDistance_&&0!==e._scrollDistance_&&a.translate(e._scrollDistance_,0),"dash"==e.yAxis.gridType&&a.setLineDash([e.yAxis.dashLength,e.yAxis.dashLength]),a.setStrokeStyle(e.yAxis.gridColor),a.setLineWidth(1*e.pixelRatio),d.forEach((function(t,e){a.beginPath(),a.moveTo(r,t),a.lineTo(h,t),a.stroke()})),a.setLineDash([]),a.restore()}}function Mt(t,e,i,a){if(!0!==e.yAxis.disabled){var n=e.height-e.area[0]-e.area[2],o=n/e.yAxis.splitNumber,r=e.area[3],l=e.width-e.area[1],s=e.height-e.area[2],c=s+i.xAxisHeight;e.xAxis.scrollShow&&(c-=3*e.pixelRatio),e.xAxis.rotateLabel&&(c=e.height-e.area[2]+3),a.beginPath(),a.setFillStyle(e.background||"#ffffff"),e._scrollDistance_<0&&a.fillRect(0,0,r,c),1==e.enableScroll&&a.fillRect(l,0,e.width,c),a.closePath(),a.stroke();for(var h=[],d=0;d<=e.yAxis.splitNumber;d++)h.push(e.area[0]+o*d);for(var u=e.area[3],f=e.width-e.area[1],p=function(t){var n=e.yAxis.data[t];if(!0!==n.disabled){var o=e.chartData.yAxisData.rangesFormat[t],r=n.fontSize||i.fontSize,l=e.chartData.yAxisData.yAxisWidth[t];if(o.forEach((function(t,i){var o=h[i]?h[i]:s;a.beginPath(),a.setFontSize(r),a.setLineWidth(1*e.pixelRatio),a.setStrokeStyle(n.axisLineColor||"#cccccc"),a.setFillStyle(n.fontColor||"#666666"),"left"==l.position?(a.fillText(String(t),u-l.width,o+r/2),1==n.calibration&&(a.moveTo(u,o),a.lineTo(u-3*e.pixelRatio,o))):(a.fillText(String(t),f+4*e.pixelRatio,o+r/2),1==n.calibration&&(a.moveTo(f,o),a.lineTo(f+3*e.pixelRatio,o))),a.closePath(),a.stroke()})),!1!==n.axisLine&&(a.beginPath(),a.setStrokeStyle(n.axisLineColor||"#cccccc"),a.setLineWidth(1*e.pixelRatio),"left"==l.position?(a.moveTo(u,e.height-e.area[2]),a.lineTo(u,e.area[0])):(a.moveTo(f,e.height-e.area[2]),a.lineTo(f,e.area[0])),a.stroke()),e.yAxis.showTitle){var c=n.titleFontSize||i.fontSize,d=n.title;a.beginPath(),a.setFontSize(c),a.setFillStyle(n.titleFontColor||"#666666"),"left"==l.position?a.fillText(d,u-v(d,c)/2,e.area[0]-10*e.pixelRatio):a.fillText(d,f-v(d,c)/2,e.area[0]-10*e.pixelRatio),a.closePath(),a.stroke()}"left"==l.position?u-=l.width+e.yAxis.padding:f+=l.width+e.yAxis.padding}},x=0;x<e.yAxis.data.length;x++)p(x)}}function Ct(t,e,i,a,n){if(!1!==e.legend.show){var o=n.legendData,r=o.points,l=o.area,s=e.legend.padding,c=e.legend.fontSize,h=15*e.pixelRatio,d=5*e.pixelRatio,u=e.legend.itemGap,f=Math.max(e.legend.lineHeight*e.pixelRatio,c);a.beginPath(),a.setLineWidth(e.legend.borderWidth),a.setStrokeStyle(e.legend.borderColor),a.setFillStyle(e.legend.backgroundColor),a.moveTo(l.start.x,l.start.y),a.rect(l.start.x,l.start.y,l.width,l.height),a.closePath(),a.fill(),a.stroke(),r.forEach((function(t,n){var r=0,p=0;r=o.widthArr[n],p=o.heightArr[n];var x=0,g=0;"top"==e.legend.position||"bottom"==e.legend.position?(x=l.start.x+(l.width-r)/2,g=l.start.y+s+n*f):(r=0==n?0:o.widthArr[n-1],x=l.start.x+s+r,g=l.start.y+s+(l.height-p)/2),a.setFontSize(i.fontSize);for(var y=0;y<t.length;y++){var m=t[y];switch(m.area=[0,0,0,0],m.area[0]=x,m.area[1]=g,m.area[3]=g+f,a.beginPath(),a.setLineWidth(1*e.pixelRatio),a.setStrokeStyle(m.show?m.color:e.legend.hiddenColor),a.setFillStyle(m.show?m.color:e.legend.hiddenColor),m.legendShape){case"line":a.moveTo(x,g+.5*f-2*e.pixelRatio),a.fillRect(x,g+.5*f-2*e.pixelRatio,15*e.pixelRatio,4*e.pixelRatio);break;case"triangle":a.moveTo(x+7.5*e.pixelRatio,g+.5*f-5*e.pixelRatio),a.lineTo(x+2.5*e.pixelRatio,g+.5*f+5*e.pixelRatio),a.lineTo(x+12.5*e.pixelRatio,g+.5*f+5*e.pixelRatio),a.lineTo(x+7.5*e.pixelRatio,g+.5*f-5*e.pixelRatio);break;case"diamond":a.moveTo(x+7.5*e.pixelRatio,g+.5*f-5*e.pixelRatio),a.lineTo(x+2.5*e.pixelRatio,g+.5*f),a.lineTo(x+7.5*e.pixelRatio,g+.5*f+5*e.pixelRatio),a.lineTo(x+12.5*e.pixelRatio,g+.5*f),a.lineTo(x+7.5*e.pixelRatio,g+.5*f-5*e.pixelRatio);break;case"circle":a.moveTo(x+7.5*e.pixelRatio,g+.5*f),a.arc(x+7.5*e.pixelRatio,g+.5*f,5*e.pixelRatio,0,2*Math.PI);break;case"rect":a.moveTo(x,g+.5*f-5*e.pixelRatio),a.fillRect(x,g+.5*f-5*e.pixelRatio,15*e.pixelRatio,10*e.pixelRatio);break;default:a.moveTo(x,g+.5*f-5*e.pixelRatio),a.fillRect(x,g+.5*f-5*e.pixelRatio,15*e.pixelRatio,10*e.pixelRatio)}a.closePath(),a.fill(),a.stroke(),x+=h+d;var b=.5*f+.5*c-2;a.beginPath(),a.setFontSize(c),a.setFillStyle(m.show?e.legend.fontColor:e.legend.hiddenColor),a.fillText(m.name,x,g+b),a.closePath(),a.stroke(),"top"==e.legend.position||"bottom"==e.legend.position?(x+=v(m.name,c)+u,m.area[2]=x):(m.area[2]=x+v(m.name,c)+u,x-=h+d,g+=f)}}))}}function Lt(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,l=n({},{activeOpacity:.5,activeRadius:10*e.pixelRatio,offsetAngle:0,labelWidth:15*e.pixelRatio,ringWidth:0,border:!1,borderWidth:2,borderColor:"#FFFFFF"},e.extra.pie),s={x:e.area[3]+(e.width-e.area[1]-e.area[3])/2,y:e.area[0]+(e.height-e.area[0]-e.area[2])/2};0==i.pieChartLinePadding&&(i.pieChartLinePadding=l.activeRadius);var c=Math.min((e.width-e.area[1]-e.area[3])/2-i.pieChartLinePadding-i.pieChartTextPadding-i._pieTextMaxLength_,(e.height-e.area[0]-e.area[2])/2-i.pieChartLinePadding-i.pieChartTextPadding);t=G(t,c,o);var h=l.activeRadius;if(t=t.map((function(t){return t._start_+=l.offsetAngle*Math.PI/180,t})),t.forEach((function(t,i){e.tooltip&&e.tooltip.index==i&&(a.beginPath(),a.setFillStyle(r(t.color,e.extra.pie.activeOpacity||.5)),a.moveTo(s.x,s.y),a.arc(s.x,s.y,t._radius_+h,t._start_,t._start_+2*t._proportion_*Math.PI),a.closePath(),a.fill()),a.beginPath(),a.setLineWidth(l.borderWidth*e.pixelRatio),a.lineJoin="round",a.setStrokeStyle(l.borderColor),a.setFillStyle(t.color),a.moveTo(s.x,s.y),a.arc(s.x,s.y,t._radius_,t._start_,t._start_+2*t._proportion_*Math.PI),a.closePath(),a.fill(),1==l.border&&a.stroke()})),"ring"===e.type){var d=.6*c;"number"===typeof e.extra.pie.ringWidth&&e.extra.pie.ringWidth>0&&(d=Math.max(0,c-e.extra.pie.ringWidth)),a.beginPath(),a.setFillStyle(e.background||"#ffffff"),a.moveTo(s.x,s.y),a.arc(s.x,s.y,d,0,2*Math.PI),a.closePath(),a.fill()}if(!1!==e.dataLabel&&1===o){for(var u=!1,f=0,p=t.length;f<p;f++)if(t[f].data>0){u=!0;break}u&&pt(t,e,i,a,c,s)}return 1===o&&"ring"===e.type&&ht(e,i,a,s),{center:s,radius:c,series:t}}function Ft(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,l=n({},{type:"area",activeOpacity:.5,activeRadius:10*e.pixelRatio,offsetAngle:0,labelWidth:15*e.pixelRatio,border:!1,borderWidth:2,borderColor:"#FFFFFF"},e.extra.rose);0==i.pieChartLinePadding&&(i.pieChartLinePadding=l.activeRadius);var s={x:e.area[3]+(e.width-e.area[1]-e.area[3])/2,y:e.area[0]+(e.height-e.area[0]-e.area[2])/2},c=Math.min((e.width-e.area[1]-e.area[3])/2-i.pieChartLinePadding-i.pieChartTextPadding-i._pieTextMaxLength_,(e.height-e.area[0]-e.area[2])/2-i.pieChartLinePadding-i.pieChartTextPadding),h=l.minRadius||.5*c;t=q(t,l.type,h,c,o);var d=l.activeRadius;if(t=t.map((function(t){return t._start_+=(l.offsetAngle||0)*Math.PI/180,t})),t.forEach((function(t,i){e.tooltip&&e.tooltip.index==i&&(a.beginPath(),a.setFillStyle(r(t.color,l.activeOpacity||.5)),a.moveTo(s.x,s.y),a.arc(s.x,s.y,d+t._radius_,t._start_,t._start_+2*t._rose_proportion_*Math.PI),a.closePath(),a.fill()),a.beginPath(),a.setLineWidth(l.borderWidth*e.pixelRatio),a.lineJoin="round",a.setStrokeStyle(l.borderColor),a.setFillStyle(t.color),a.moveTo(s.x,s.y),a.arc(s.x,s.y,t._radius_,t._start_,t._start_+2*t._rose_proportion_*Math.PI),a.closePath(),a.fill(),1==l.border&&a.stroke()})),!1!==e.dataLabel&&1===o){for(var u=!1,f=0,p=t.length;f<p;f++)if(t[f].data>0){u=!0;break}u&&pt(t,e,i,a,c,s)}return{center:s,radius:c,series:t}}function Dt(t,e,i,a){var o,r,l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,s=n({},{startAngle:.75,endAngle:.25,type:"default",width:12*e.pixelRatio,gap:2*e.pixelRatio},e.extra.arcbar);t=U(t,s,l),o=s.center?s.center:{x:e.width/2,y:e.height/2},s.radius?r=s.radius:(r=Math.min(o.x,o.y),r-=5*e.pixelRatio,r-=s.width/2);for(var c=0;c<t.length;c++){var h=t[c];a.setLineWidth(s.width),a.setStrokeStyle(s.backgroundColor||"#E9E9E9"),a.setLineCap("round"),a.beginPath(),"default"==s.type?a.arc(o.x,o.y,r-(s.width+s.gap)*c,s.startAngle*Math.PI,s.endAngle*Math.PI,!1):a.arc(o.x,o.y,r-(s.width+s.gap)*c,0,2*Math.PI,!1),a.stroke(),a.setLineWidth(s.width),a.setStrokeStyle(h.color),a.setLineCap("round"),a.beginPath(),a.arc(o.x,o.y,r-(s.width+s.gap)*c,s.startAngle*Math.PI,h._proportion_*Math.PI,!1),a.stroke()}return ht(e,i,a,o),{center:o,radius:r,series:t}}function Rt(t,e,i,a,o){var l=arguments.length>5&&void 0!==arguments[5]?arguments[5]:1,s=n({},{type:"default",startAngle:.75,endAngle:.25,width:15,splitLine:{fixRadius:0,splitNumber:10,width:15,color:"#FFFFFF",childNumber:5,childWidth:5},pointer:{width:15,color:"auto"}},i.extra.gauge);void 0==s.oldAngle&&(s.oldAngle=s.startAngle),void 0==s.oldData&&(s.oldData=0),t=J(t,s.startAngle,s.endAngle);var c={x:i.width/2,y:i.height/2},h=Math.min(c.x,c.y);h-=5*i.pixelRatio,h-=s.width/2;var d=h-s.width,u=0;if("progress"==s.type){var f=h-3*s.width;o.beginPath();var p=o.createLinearGradient(c.x,c.y-f,c.x,c.y+f);p.addColorStop("0",r(e[0].color,.3)),p.addColorStop("1.0",r("#FFFFFF",.1)),o.setFillStyle(p),o.arc(c.x,c.y,f,0,2*Math.PI,!1),o.fill(),o.setLineWidth(s.width),o.setStrokeStyle(r(e[0].color,.3)),o.setLineCap("round"),o.beginPath(),o.arc(c.x,c.y,d,s.startAngle*Math.PI,s.endAngle*Math.PI,!1),o.stroke(),u=s.startAngle-s.endAngle+1;s.splitLine.splitNumber;var x=u/s.splitLine.splitNumber/s.splitLine.childNumber,g=-h-.5*s.width-s.splitLine.fixRadius,v=-h-s.width-s.splitLine.fixRadius+s.splitLine.width;o.save(),o.translate(c.x,c.y),o.rotate((s.startAngle-1)*Math.PI);for(var y=s.splitLine.splitNumber*s.splitLine.childNumber+1,m=e[0].data*l,b=0;b<y;b++)o.beginPath(),m>b/y?o.setStrokeStyle(r(e[0].color,1)):o.setStrokeStyle(r(e[0].color,.3)),o.setLineWidth(3*i.pixelRatio),o.moveTo(g,0),o.lineTo(v,0),o.stroke(),o.rotate(x*Math.PI);o.restore(),e=U(e,s,l),o.setLineWidth(s.width),o.setStrokeStyle(e[0].color),o.setLineCap("round"),o.beginPath(),o.arc(c.x,c.y,d,s.startAngle*Math.PI,e[0]._proportion_*Math.PI,!1),o.stroke();var w=h-2.5*s.width;o.save(),o.translate(c.x,c.y),o.rotate((e[0]._proportion_-1)*Math.PI),o.beginPath(),o.setLineWidth(s.width/3);var S=o.createLinearGradient(0,.6*-w,0,.6*w);S.addColorStop("0",r("#FFFFFF",0)),S.addColorStop("0.5",r(e[0].color,1)),S.addColorStop("1.0",r("#FFFFFF",0)),o.setStrokeStyle(S),o.arc(0,0,w,.85*Math.PI,1.15*Math.PI,!1),o.stroke(),o.beginPath(),o.setLineWidth(1),o.setStrokeStyle(e[0].color),o.setFillStyle(e[0].color),o.moveTo(-w-s.width/3/2,-4),o.lineTo(-w-s.width/3/2-4,0),o.lineTo(-w-s.width/3/2,4),o.lineTo(-w-s.width/3/2,-4),o.stroke(),o.fill(),o.restore()}else{o.setLineWidth(s.width),o.setLineCap("butt");for(var T=0;T<t.length;T++){var A=t[T];o.beginPath(),o.setStrokeStyle(A.color),o.arc(c.x,c.y,h,A._startAngle_*Math.PI,A._endAngle_*Math.PI,!1),o.stroke()}o.save(),u=s.startAngle-s.endAngle+1;var P=u/s.splitLine.splitNumber,_=u/s.splitLine.splitNumber/s.splitLine.childNumber,k=-h-.5*s.width-s.splitLine.fixRadius,M=-h-.5*s.width-s.splitLine.fixRadius+s.splitLine.width,C=-h-.5*s.width-s.splitLine.fixRadius+s.splitLine.childWidth;o.translate(c.x,c.y),o.rotate((s.startAngle-1)*Math.PI);for(var L=0;L<s.splitLine.splitNumber+1;L++)o.beginPath(),o.setStrokeStyle(s.splitLine.color),o.setLineWidth(2*i.pixelRatio),o.moveTo(k,0),o.lineTo(M,0),o.stroke(),o.rotate(P*Math.PI);o.restore(),o.save(),o.translate(c.x,c.y),o.rotate((s.startAngle-1)*Math.PI);for(var F=0;F<s.splitLine.splitNumber*s.splitLine.childNumber+1;F++)o.beginPath(),o.setStrokeStyle(s.splitLine.color),o.setLineWidth(1*i.pixelRatio),o.moveTo(k,0),o.lineTo(C,0),o.stroke(),o.rotate(_*Math.PI);o.restore(),e=Y(e,t,s,l);for(var D=0;D<e.length;D++){var R=e[D];o.save(),o.translate(c.x,c.y),o.rotate((R._proportion_-1)*Math.PI),o.beginPath(),o.setFillStyle(R.color),o.moveTo(s.pointer.width,0),o.lineTo(0,-s.pointer.width/2),o.lineTo(-d,0),o.lineTo(0,s.pointer.width/2),o.lineTo(s.pointer.width,0),o.closePath(),o.fill(),o.beginPath(),o.setFillStyle("#FFFFFF"),o.arc(0,0,s.pointer.width/6,0,2*Math.PI,!1),o.fill(),o.restore()}!1!==i.dataLabel&&ut(s,h,c,i,a,o)}return ht(i,a,o,c),1===l&&"gauge"===i.type&&(i.extra.gauge.oldAngle=e[0]._proportion_,i.extra.gauge.oldData=e[0].data),{center:c,radius:h,innerRadius:d,categories:t,totalAngle:u}}function zt(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,l=n({},{gridColor:"#cccccc",gridType:"radar",labelColor:"#666666",opacity:.2,gridCount:3},e.extra.radar),s=T(e.categories.length),c={x:e.area[3]+(e.width-e.area[1]-e.area[3])/2,y:e.area[0]+(e.height-e.area[0]-e.area[2])/2},h=Math.min(c.x-(S(e.categories)+i.radarLabelTextMargin),c.y-i.radarLabelTextMargin);h-=e.padding[1],a.beginPath(),a.setLineWidth(1*e.pixelRatio),a.setStrokeStyle(l.gridColor),s.forEach((function(t){var e=f(h*Math.cos(t),h*Math.sin(t),c);a.moveTo(c.x,c.y),a.lineTo(e.x,e.y)})),a.stroke(),a.closePath();for(var d=function(t){var i={};if(a.beginPath(),a.setLineWidth(1*e.pixelRatio),a.setStrokeStyle(l.gridColor),"radar"==l.gridType)s.forEach((function(e,n){var o=f(h/l.gridCount*t*Math.cos(e),h/l.gridCount*t*Math.sin(e),c);0===n?(i=o,a.moveTo(o.x,o.y)):a.lineTo(o.x,o.y)})),a.lineTo(i.x,i.y);else{var n=f(h/l.gridCount*t*Math.cos(1.5),h/l.gridCount*t*Math.sin(1.5),c);a.arc(c.x,c.y,c.y-n.y,0,2*Math.PI,!1)}a.stroke(),a.closePath()},u=1;u<=l.gridCount;u++)d(u);var p=X(s,c,h,t,e,o);return p.forEach((function(t,i){if(a.beginPath(),a.setFillStyle(r(t.color,l.opacity)),t.data.forEach((function(t,e){0===e?a.moveTo(t.position.x,t.position.y):a.lineTo(t.position.x,t.position.y)})),a.closePath(),a.fill(),!1!==e.dataPointShape){var n=t.data.map((function(t){return t.position}));ct(n,t.color,t.pointShape,a,e)}})),ft(s,h,c,e,i,a),{center:c,radius:h,angleList:s}}function It(t,e,i){i=0==i?1:i;for(var a=[],n=0;n<i;n++)a[n]=Math.random();return Math.floor(a.reduce((function(t,e){return t+e}))/i*(e-t))+t}function Wt(t,e,i,a){for(var n=!1,o=0;o<e.length;o++)if(e[o].area){if(!(t[3]<e[o].area[1]||t[0]>e[o].area[2]||t[1]>e[o].area[3]||t[2]<e[o].area[0])){n=!0;break}if(t[0]<0||t[1]<0||t[2]>i||t[3]>a){n=!0;break}n=!1}return n}function Ot(t){var e,i={};i.xMin=180,i.xMax=0,i.yMin=90,i.yMax=0;for(var a=0;a<t.length;a++)for(var n=t[a].geometry.coordinates,o=0;o<n.length;o++){e=n[o],1==e.length&&(e=e[0]);for(var r=0;r<e.length;r++){var l=e[r][0],s=e[r][1],c={x:l,y:s};i.xMin=i.xMin<c.x?i.xMin:c.x,i.xMax=i.xMax>c.x?i.xMax:c.x,i.yMin=i.yMin<c.y?i.yMin:c.y,i.yMax=i.yMax>c.y?i.yMax:c.y}}return i}function Et(t,e,i,a,n,o){return{x:(e-i.xMin)*a+n,y:(i.yMax-t)*a+o}}function Bt(t,e,i,a,n,o){return{x:(e-n)/a+i.xMin,y:i.yMax-(t-o)/a}}function Nt(t,e,i){if(e[1]==i[1])return!1;if(e[1]>t[1]&&i[1]>t[1])return!1;if(e[1]<t[1]&&i[1]<t[1])return!1;if(e[1]==t[1]&&i[1]>t[1])return!1;if(i[1]==t[1]&&e[1]>t[1])return!1;if(e[0]<t[0]&&i[1]<t[1])return!1;var a=i[0]-(i[0]-e[0])*(i[1]-t[1])/(i[1]-e[1]);return!(a<t[0])}function Ht(t,e){for(var i=0,a=0;a<e.length;a++){var n=e[a][0];1==e.length&&(n=e[a][0]);for(var o=0;o<n.length-1;o++){var r=n[o],l=n[o+1];Nt(t,r,l)&&(i+=1)}}return i%2==1}function jt(t,e,i,a){var o,l,s=n({},{border:!0,borderWidth:1,borderColor:"#666666",fillOpacity:.6,activeBorderColor:"#f04864",activeFillColor:"#facc14",activeFillOpacity:1},e.extra.map),c=t,h=Ot(c),d=e.width/Math.abs(h.xMax-h.xMin),u=e.height/Math.abs(h.yMax-h.yMin),f=d<u?d:u,p=e.width/2-Math.abs(h.xMax-h.xMin)/2*f,x=e.height/2-Math.abs(h.yMax-h.yMin)/2*f;a.beginPath(),a.clearRect(0,0,e.width,e.height),a.setFillStyle(e.background||"#FFFFFF"),a.rect(0,0,e.width,e.height),a.fill();for(var g=0;g<c.length;g++){a.beginPath(),a.setLineWidth(s.borderWidth*e.pixelRatio),a.setStrokeStyle(s.borderColor),a.setFillStyle(r(t[g].color,s.fillOpacity)),e.tooltip&&e.tooltip.index==g&&(a.setStrokeStyle(s.activeBorderColor),a.setFillStyle(r(s.activeFillColor,s.activeFillOpacity)));for(var y=c[g].geometry.coordinates,m=0;m<y.length;m++){o=y[m],1==o.length&&(o=o[0]);for(var b=0;b<o.length;b++)l=Et(o[b][1],o[b][0],h,f,p,x),0===b?(a.beginPath(),a.moveTo(l.x,l.y)):a.lineTo(l.x,l.y);a.fill(),1==s.border&&a.stroke()}if(1==e.dataLabel){var w=c[g].properties.centroid;if(w){l=Et(w[1],w[0],h,f,p,x);var S=c[g].textSize||i.fontSize,T=c[g].properties.name;a.beginPath(),a.setFontSize(S),a.setFillStyle(c[g].textColor||"#666666"),a.fillText(T,l.x-v(T,S)/2,l.y+S/2),a.closePath(),a.stroke()}}}e.chartData.mapData={bounds:h,scale:f,xoffset:p,yoffset:x},Pt(e,i,a,1),a.draw()}function Xt(t,e){var i=t.series.sort((function(t,e){return parseInt(e.textSize)-parseInt(t.textSize)}));switch(e){case"normal":for(var a=0;a<i.length;a++){var n=i[a].name,o=i[a].textSize,r=v(n,o),l=void 0,s=void 0,c=void 0,h=0;while(1){h++,l=It(-t.width/2,t.width/2,5)-r/2,s=It(-t.height/2,t.height/2,5)+o/2,c=[l-5+t.width/2,s-5-o+t.height/2,l+r+5+t.width/2,s+5+t.height/2];var d=Wt(c,i,t.width,t.height);if(!d)break;if(1e3==h){c=[-100,-100,-100,-100];break}}i[a].area=c}break;case"vertical":for(var u=function(){return Math.random()>.7},f=0;f<i.length;f++){var p=i[f].name,x=i[f].textSize,g=v(p,x),y=u(),m=void 0,b=void 0,w=void 0,S=void 0,T=0;while(1){T++;var A=void 0;if(y?(m=It(-t.width/2,t.width/2,5)-g/2,b=It(-t.height/2,t.height/2,5)+x/2,w=[b-5-g+t.width/2,-m-5+t.height/2,b+5+t.width/2,-m+x+5+t.height/2],S=[t.width-(t.width/2-t.height/2)-(-m+x+5+t.height/2)-5,t.height/2-t.width/2+(b-5-g+t.width/2)-5,t.width-(t.width/2-t.height/2)-(-m+x+5+t.height/2)+x,t.height/2-t.width/2+(b-5-g+t.width/2)+g+5],A=Wt(S,i,t.height,t.width)):(m=It(-t.width/2,t.width/2,5)-g/2,b=It(-t.height/2,t.height/2,5)+x/2,w=[m-5+t.width/2,b-5-x+t.height/2,m+g+5+t.width/2,b+5+t.height/2],A=Wt(w,i,t.width,t.height)),!A)break;if(1e3==T){w=[-1e3,-1e3,-1e3,-1e3];break}}y?(i[f].area=S,i[f].areav=w):i[f].area=w,i[f].rotate=y}break}return i}function Gt(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1;n({},{type:"normal",autoColors:!0},e.extra.word);a.beginPath(),a.setFillStyle(e.background||"#FFFFFF"),a.rect(0,0,e.width,e.height),a.fill(),a.save();var r=e.chartData.wordCloudData;a.translate(e.width/2,e.height/2);for(var l=0;l<r.length;l++){a.save(),r[l].rotate&&a.rotate(90*Math.PI/180);var s=r[l].name,c=r[l].textSize,h=v(s,c);a.beginPath(),a.setStrokeStyle(r[l].color),a.setFillStyle(r[l].color),a.setFontSize(c),r[l].rotate?r[l].areav[0]>0&&(e.tooltip&&e.tooltip.index==l?a.strokeText(s,(r[l].areav[0]+5-e.width/2)*o-h*(1-o)/2,(r[l].areav[1]+5+c-e.height/2)*o):a.fillText(s,(r[l].areav[0]+5-e.width/2)*o-h*(1-o)/2,(r[l].areav[1]+5+c-e.height/2)*o)):r[l].area[0]>0&&(e.tooltip&&e.tooltip.index==l?a.strokeText(s,(r[l].area[0]+5-e.width/2)*o-h*(1-o)/2,(r[l].area[1]+5+c-e.height/2)*o):a.fillText(s,(r[l].area[0]+5-e.width/2)*o-h*(1-o)/2,(r[l].area[1]+5+c-e.height/2)*o)),a.stroke(),a.restore()}a.restore()}function $t(t,e,i,a){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1,l=n({},{activeWidth:10,activeOpacity:.3,border:!1,borderWidth:2,borderColor:"#FFFFFF",fillOpacity:1,labelAlign:"right"},e.extra.funnel),s=(e.height-e.area[0]-e.area[2])/t.length,c={x:e.area[3]+(e.width-e.area[1]-e.area[3])/2,y:e.height-e.area[2]},h=l.activeWidth,d=Math.min((e.width-e.area[1]-e.area[3])/2-h,(e.height-e.area[0]-e.area[2])/2-h);t=$(t,d,o),a.save(),a.translate(c.x,c.y);for(var u=0;u<t.length;u++)0==u?(e.tooltip&&e.tooltip.index==u&&(a.beginPath(),a.setFillStyle(r(t[u].color,l.activeOpacity)),a.moveTo(-h,0),a.lineTo(-t[u].radius-h,-s),a.lineTo(t[u].radius+h,-s),a.lineTo(h,0),a.lineTo(-h,0),a.closePath(),a.fill()),t[u].funnelArea=[c.x-t[u].radius,c.y-s,c.x+t[u].radius,c.y],a.beginPath(),a.setLineWidth(l.borderWidth*e.pixelRatio),a.setStrokeStyle(l.borderColor),a.setFillStyle(r(t[u].color,l.fillOpacity)),a.moveTo(0,0),a.lineTo(-t[u].radius,-s),a.lineTo(t[u].radius,-s),a.lineTo(0,0),a.closePath(),a.fill(),1==l.border&&a.stroke()):(e.tooltip&&e.tooltip.index==u&&(a.beginPath(),a.setFillStyle(r(t[u].color,l.activeOpacity)),a.moveTo(0,0),a.lineTo(-t[u-1].radius-h,0),a.lineTo(-t[u].radius-h,-s),a.lineTo(t[u].radius+h,-s),a.lineTo(t[u-1].radius+h,0),a.lineTo(0,0),a.closePath(),a.fill()),t[u].funnelArea=[c.x-t[u].radius,c.y-s*(u+1),c.x+t[u].radius,c.y-s*u],a.beginPath(),a.setLineWidth(l.borderWidth*e.pixelRatio),a.setStrokeStyle(l.borderColor),a.setFillStyle(r(t[u].color,l.fillOpacity)),a.moveTo(0,0),a.lineTo(-t[u-1].radius,0),a.lineTo(-t[u].radius,-s),a.lineTo(t[u].radius,-s),a.lineTo(t[u-1].radius,0),a.lineTo(0,0),a.closePath(),a.fill(),1==l.border&&a.stroke()),a.translate(0,-s);return a.restore(),!1!==e.dataLabel&&1===o&&qt(t,e,a,s,l.labelAlign,h,c),{center:c,radius:d,series:t}}function qt(t,e,i,a,n,r,l){for(var s=0;s<t.length;s++){var c=t[s],h=void 0,d=void 0,u=void 0,f=void 0,p=c.format?c.format(+c._proportion_.toFixed(2)):o.toFixed(100*c._proportion_)+"%";"right"==n?(h=0==s?(c.funnelArea[2]+l.x)/2:(c.funnelArea[2]+t[s-1].funnelArea[2])/2,d=h+2*r,u=c.funnelArea[1]+a/2,f=c.textSize||e.fontSize,i.setLineWidth(1*e.pixelRatio),i.setStrokeStyle(c.color),i.setFillStyle(c.color),i.beginPath(),i.moveTo(h,u),i.lineTo(d,u),i.stroke(),i.closePath(),i.beginPath(),i.moveTo(d,u),i.arc(d,u,2,0,2*Math.PI),i.closePath(),i.fill(),i.beginPath(),i.setFontSize(f),i.setFillStyle(c.textColor||"#666666"),i.fillText(p,d+5,u+f/2-2),i.closePath(),i.stroke(),i.closePath()):(h=0==s?(c.funnelArea[0]+l.x)/2:(c.funnelArea[0]+t[s-1].funnelArea[0])/2,d=h-2*r,u=c.funnelArea[1]+a/2,f=c.textSize||e.fontSize,i.setLineWidth(1*e.pixelRatio),i.setStrokeStyle(c.color),i.setFillStyle(c.color),i.beginPath(),i.moveTo(h,u),i.lineTo(d,u),i.stroke(),i.closePath(),i.beginPath(),i.moveTo(d,u),i.arc(d,u,2,0,2*Math.PI),i.closePath(),i.fill(),i.beginPath(),i.setFontSize(f),i.setFillStyle(c.textColor||"#666666"),i.fillText(p,d-5-v(p),u+f/2-2),i.closePath(),i.stroke(),i.closePath())}}function Ut(t,e){e.draw()}var Jt={easeIn:function(t){return Math.pow(t,3)},easeOut:function(t){return Math.pow(t-1,3)+1},easeInOut:function(t){return(t/=.5)<1?.5*Math.pow(t,3):.5*(Math.pow(t-2,3)+2)},linear:function(t){return t}};function Yt(t){this.isStop=!1,t.duration="undefined"===typeof t.duration?1e3:t.duration,t.timing=t.timing||"linear";var e=17;function i(){return"undefined"!==typeof setTimeout?function(t,e){setTimeout((function(){var e=+new Date;t(e)}),e)}:"undefined"!==typeof requestAnimationFrame?requestAnimationFrame:function(t){t(null)}}var a=i(),n=null,o=function(i){if(null===i||!0===this.isStop)return t.onProcess&&t.onProcess(1),void(t.onAnimationFinish&&t.onAnimationFinish());if(null===n&&(n=i),i-n<t.duration){var r=(i-n)/t.duration,l=Jt[t.timing];r=l(r),t.onProcess&&t.onProcess(r),a(o,e)}else t.onProcess&&t.onProcess(1),t.onAnimationFinish&&t.onAnimationFinish()};o=o.bind(this),a(o,e)}function Qt(t,e,i,a){var o=this,r=e.series,l=e.categories;r=x(r,e,i);var c=e.animation?e.duration:0;o.animationInstance&&o.animationInstance.stop();var h=null;if("candle"==t){var d=n({},e.extra.candle.average);d.show?(h=s(d.day,d.name,d.color,r[0].data),h=x(h,e,i),e.seriesMA=h):h=e.seriesMA?e.seriesMA=x(e.seriesMA,e,i):r}else h=r;e._series_=r=k(r),e.area=new Array(4);for(var u=0;u<4;u++)e.area[u]=e.padding[u];var f=B(h,e,i,e.chartData),p=f.area.wholeHeight,g=f.area.wholeWidth;switch(e.legend.position){case"top":e.area[0]+=p;break;case"bottom":e.area[2]+=p;break;case"left":e.area[3]+=g;break;case"right":e.area[1]+=g;break}var v={},y=0;if("line"===e.type||"column"===e.type||"area"===e.type||"mix"===e.type||"candle"===e.type){if(v=ot(r,e,i),y=v.yAxisWidth,e.yAxis.showTitle){for(var m=0,b=0;b<e.yAxis.data.length;b++)m=Math.max(m,e.yAxis.data[b].titleFontSize?e.yAxis.data[b].titleFontSize:i.fontSize);e.area[0]+=(m+6)*e.pixelRatio}for(var w=0,S=0,T=0;T<y.length;T++)"left"==y[T].position?(e.area[3]+=S>0?y[T].width+e.yAxis.padding:y[T].width,S+=1):(e.area[1]+=w>0?y[T].width+e.yAxis.padding:y[T].width,w+=1)}else i.yAxisWidth=y;if(e.chartData.yAxisData=v,e.categories&&e.categories.length){e.chartData.xAxisData=tt(e.categories,e,i);var A=N(e.categories,e,i,e.chartData.xAxisData.eachSpacing),P=A.xAxisHeight,_=A.angle;i.xAxisHeight=P,i._xAxisTextAngle_=_,e.area[2]+=P,e.chartData.categoriesData=A}else if("line"===e.type||"area"===e.type||"points"===e.type){e.chartData.xAxisData=j(r,e,i),l=e.chartData.xAxisData.rangesFormat;var M=N(l,e,i,e.chartData.xAxisData.eachSpacing),C=M.xAxisHeight,L=M.angle;i.xAxisHeight=C,i._xAxisTextAngle_=L,e.area[2]+=C,e.chartData.categoriesData=M}else e.chartData.xAxisData={xAxisPoints:[]};if(e.enableScroll&&"right"==e.xAxis.scrollAlign&&void 0===e._scrollDistance_){var F=0,D=e.chartData.xAxisData.xAxisPoints,R=e.chartData.xAxisData.startX,z=e.chartData.xAxisData.endX,I=e.chartData.xAxisData.eachSpacing,W=I*(D.length-1),O=z-R;F=O-W,o.scrollOption={currentOffset:F,startTouchX:F,distance:0,lastMoveTime:0},e._scrollDistance_=F}switch("pie"!==t&&"ring"!==t&&"rose"!==t||(i._pieTextMaxLength_=!1===e.dataLabel?0:Q(h)),t){case"word":var E=n({},{type:"normal",autoColors:!0},e.extra.word);1!=e.updateData&&void 0!=e.updateData||(e.chartData.wordCloudData=Xt(e,E.type)),this.animationInstance=new Yt({timing:"easeInOut",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),Gt(r,e,i,a,t),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"map":a.clearRect(0,0,e.width,e.height),jt(r,e,i,a);break;case"funnel":this.animationInstance=new Yt({timing:"easeInOut",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),e.chartData.funnelData=$t(r,e,i,a,t),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"line":this.animationInstance=new Yt({timing:"easeIn",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),kt(l,e,i,a),_t(l,e,i,a);var n=Tt(r,e,i,a,t),o=n.xAxisPoints,s=n.calPoints,c=n.eachSpacing;e.chartData.xAxisPoints=o,e.chartData.calPoints=s,e.chartData.eachSpacing=c,Mt(r,e,i,a),!1!==e.enableMarkLine&&1===t&&gt(e,i,a),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t,c,o),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"mix":this.animationInstance=new Yt({timing:"easeIn",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),kt(l,e,i,a),_t(l,e,i,a);var n=At(r,e,i,a,t),o=n.xAxisPoints,s=n.calPoints,c=n.eachSpacing;e.chartData.xAxisPoints=o,e.chartData.calPoints=s,e.chartData.eachSpacing=c,Mt(r,e,i,a),!1!==e.enableMarkLine&&1===t&&gt(e,i,a),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t,c,o),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"column":this.animationInstance=new Yt({timing:"easeIn",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),kt(l,e,i,a),_t(l,e,i,a);var n=bt(r,e,i,a,t),o=n.xAxisPoints,s=n.calPoints,c=n.eachSpacing;e.chartData.xAxisPoints=o,e.chartData.calPoints=s,e.chartData.eachSpacing=c,Mt(r,e,i,a),!1!==e.enableMarkLine&&1===t&&gt(e,i,a),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t,c,o),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"area":this.animationInstance=new Yt({timing:"easeIn",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),kt(l,e,i,a),_t(l,e,i,a);var n=St(r,e,i,a,t),o=n.xAxisPoints,s=n.calPoints,c=n.eachSpacing;e.chartData.xAxisPoints=o,e.chartData.calPoints=s,e.chartData.eachSpacing=c,Mt(r,e,i,a),!1!==e.enableMarkLine&&1===t&&gt(e,i,a),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t,c,o),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"ring":case"pie":this.animationInstance=new Yt({timing:"easeInOut",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),e.chartData.pieData=Lt(r,e,i,a,t),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"rose":this.animationInstance=new Yt({timing:"easeInOut",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),e.chartData.pieData=Ft(r,e,i,a,t),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"radar":this.animationInstance=new Yt({timing:"easeInOut",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),e.chartData.radarData=zt(r,e,i,a,t),Ct(e.series,e,i,a,e.chartData),Pt(e,i,a,t),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"arcbar":this.animationInstance=new Yt({timing:"easeInOut",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),e.chartData.arcbarData=Dt(r,e,i,a,t),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"gauge":this.animationInstance=new Yt({timing:"easeInOut",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),e.chartData.gaugeData=Rt(l,r,e,i,a,t),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break;case"candle":this.animationInstance=new Yt({timing:"easeIn",duration:c,onProcess:function(t){a.clearRect(0,0,e.width,e.height),e.rotate&&st(a,e),kt(l,e,i,a),_t(l,e,i,a);var n=wt(r,h,e,i,a,t),o=n.xAxisPoints,s=n.calPoints,c=n.eachSpacing;e.chartData.xAxisPoints=o,e.chartData.calPoints=s,e.chartData.eachSpacing=c,Mt(r,e,i,a),!1!==e.enableMarkLine&&1===t&&gt(e,i,a),Ct(h||e.series,e,i,a,e.chartData),Pt(e,i,a,t,c,o),Ut(e,a)},onAnimationFinish:function(){o.event.trigger("renderComplete")}});break}}function Zt(){this.events={}}Yt.prototype.stop=function(){this.isStop=!0},Zt.prototype.addEventListener=function(t,e){this.events[t]=this.events[t]||[],this.events[t].push(e)},Zt.prototype.delEventListener=function(t){this.events[t]=[]},Zt.prototype.trigger=function(){for(var t=arguments.length,i=Array(t),a=0;a<t;a++)i[a]=arguments[a];var n=i[0],o=i.slice(1);this.events[n]&&this.events[n].forEach((function(t){try{t.apply(null,o)}catch(i){e.error(i)}}))};var Kt=function(t){t.pixelRatio=t.pixelRatio?t.pixelRatio:1,t.fontSize=t.fontSize?t.fontSize*t.pixelRatio:13*t.pixelRatio,t.title=n({},t.title),t.subtitle=n({},t.subtitle),t.duration=t.duration?t.duration:1e3,t.yAxis=n({},{data:[],showTitle:!1,disabled:!1,disableGrid:!1,splitNumber:5,gridType:"solid",dashLength:4*t.pixelRatio,gridColor:"#cccccc",padding:10,fontColor:"#666666"},t.yAxis),t.yAxis.dashLength*=t.pixelRatio,t.yAxis.padding*=t.pixelRatio,t.xAxis=n({},{rotateLabel:!1,type:"calibration",gridType:"solid",dashLength:4,scrollAlign:"left",boundaryGap:"center",axisLine:!0,axisLineColor:"#cccccc"},t.xAxis),t.xAxis.dashLength*=t.pixelRatio,t.legend=n({},{show:!0,position:"bottom",float:"center",backgroundColor:"rgba(0,0,0,0)",borderColor:"rgba(0,0,0,0)",borderWidth:0,padding:5,margin:5,itemGap:10,fontSize:t.fontSize,lineHeight:t.fontSize,fontColor:"#333333",format:{},hiddenColor:"#CECECE"},t.legend),t.legend.borderWidth=t.legend.borderWidth*t.pixelRatio,t.legend.itemGap=t.legend.itemGap*t.pixelRatio,t.legend.padding=t.legend.padding*t.pixelRatio,t.legend.margin=t.legend.margin*t.pixelRatio,t.extra=n({},t.extra),t.rotate=!!t.rotate,t.animation=!!t.animation,t.rotate=!!t.rotate,t.canvas2d=!!t.canvas2d;var e=JSON.parse(JSON.stringify(a));if(e.colors=t.colors?t.colors:e.colors,e.yAxisTitleWidth=!0!==t.yAxis.disabled&&t.yAxis.title?e.yAxisTitleWidth:0,"pie"!=t.type&&"ring"!=t.type||(e.pieChartLinePadding=!1===t.dataLabel?0:t.extra.pie.labelWidth*t.pixelRatio||e.pieChartLinePadding*t.pixelRatio),"rose"==t.type&&(e.pieChartLinePadding=!1===t.dataLabel?0:t.extra.rose.labelWidth*t.pixelRatio||e.pieChartLinePadding*t.pixelRatio),e.pieChartTextPadding=!1===t.dataLabel?0:e.pieChartTextPadding*t.pixelRatio,e.yAxisSplit=t.yAxis.splitNumber?t.yAxis.splitNumber:a.yAxisSplit,e.rotate=t.rotate,t.rotate){var i=t.width,o=t.height;t.width=o,t.height=i}t.padding=t.padding?t.padding:e.padding;for(var r=0;r<4;r++)t.padding[r]*=t.pixelRatio;e.yAxisWidth=a.yAxisWidth*t.pixelRatio,e.xAxisHeight=a.xAxisHeight*t.pixelRatio,t.enableScroll&&t.xAxis.scrollShow&&(e.xAxisHeight+=6*t.pixelRatio),e.xAxisLineHeight=a.xAxisLineHeight*t.pixelRatio,e.fontSize=t.fontSize,e.titleFontSize=a.titleFontSize*t.pixelRatio,e.subtitleFontSize=a.subtitleFontSize*t.pixelRatio,e.toolTipPadding=a.toolTipPadding*t.pixelRatio,e.toolTipLineHeight=a.toolTipLineHeight*t.pixelRatio,e.columePadding=a.columePadding*t.pixelRatio,this.context=t.context?t.context:uni.createCanvasContext(t.canvasId,t.$this),t.canvas2d&&(this.context.setStrokeStyle=function(t){return this.strokeStyle=t},this.context.setLineWidth=function(t){return this.lineWidth=t},this.context.setLineCap=function(t){return this.lineCap=t},this.context.setFontSize=function(t){return this.font=t+"px sans-serif"},this.context.setFillStyle=function(t){return this.fillStyle=t},this.context.draw=function(){}),t.chartData={},this.event=new Zt,this.scrollOption={currentOffset:0,startTouchX:0,distance:0,lastMoveTime:0},this.opts=t,this.config=e,Qt.call(this,t.type,t,e,this.context)};Kt.prototype.updateData=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.opts=n({},this.opts,t),this.opts.updateData=!0;var e=t.scrollPosition||"current";switch(e){case"current":this.opts._scrollDistance_=this.scrollOption.currentOffset;break;case"left":this.opts._scrollDistance_=0,this.scrollOption={currentOffset:0,startTouchX:0,distance:0,lastMoveTime:0};break;case"right":var i=ot(this.opts.series,this.opts,this.config),a=i.yAxisWidth;this.config.yAxisWidth=a;var o=0,r=tt(this.opts.categories,this.opts,this.config),l=r.xAxisPoints,s=r.startX,c=r.endX,h=r.eachSpacing,d=h*(l.length-1),u=c-s;o=u-d,this.scrollOption={currentOffset:o,startTouchX:o,distance:0,lastMoveTime:0},this.opts._scrollDistance_=o;break}Qt.call(this,this.opts.type,this.opts,this.config,this.context)},Kt.prototype.zoom=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.opts.xAxis.itemCount;if(!0===this.opts.enableScroll){var i=Math.round(Math.abs(this.scrollOption.currentOffset)/this.opts.chartData.eachSpacing)+Math.round(this.opts.xAxis.itemCount/2);this.opts.animation=!1,this.opts.xAxis.itemCount=t.itemCount;var a=ot(this.opts.series,this.opts,this.config),n=a.yAxisWidth;this.config.yAxisWidth=n;var o=0,r=tt(this.opts.categories,this.opts,this.config),l=r.xAxisPoints,s=r.startX,c=r.endX,h=r.eachSpacing,d=h*i,u=c-s,f=u-h*(l.length-1);o=u/2-d,o>0&&(o=0),o<f&&(o=f),this.scrollOption={currentOffset:o,startTouchX:o,distance:0,lastMoveTime:0},this.opts._scrollDistance_=o,Qt.call(this,this.opts.type,this.opts,this.config,this.context)}else e.log("请启用滚动条后使用!")},Kt.prototype.stopAnimation=function(){this.animationInstance&&this.animationInstance.stop()},Kt.prototype.addEventListener=function(t,e){this.event.addEventListener(t,e)},Kt.prototype.delEventListener=function(t){this.event.delEventListener(t)},Kt.prototype.getCurrentDataIndex=function(t){var e=null;if(e=t.changedTouches?t.changedTouches[0]:t.mp.changedTouches[0],e){var i=b(e,this.opts,t);return"pie"===this.opts.type||"ring"===this.opts.type||"rose"===this.opts.type?W({x:i.x,y:i.y},this.opts.chartData.pieData):"radar"===this.opts.type?D({x:i.x,y:i.y},this.opts.chartData.radarData,this.opts.categories.length):"funnel"===this.opts.type?R({x:i.x,y:i.y},this.opts.chartData.funnelData):"map"===this.opts.type?I({x:i.x,y:i.y},this.opts):"word"===this.opts.type?z({x:i.x,y:i.y},this.opts.chartData.wordCloudData):M({x:i.x,y:i.y},this.opts.chartData.calPoints,this.opts,this.config,Math.abs(this.scrollOption.currentOffset))}return-1},Kt.prototype.getLegendDataIndex=function(t){var e=null;if(e=t.changedTouches?t.changedTouches[0]:t.mp.changedTouches[0],e){var i=b(e,this.opts,t);return C({x:i.x,y:i.y},this.opts.chartData.legendData)}return-1},Kt.prototype.touchLegend=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=null;if(i=t.changedTouches?t.changedTouches[0]:t.mp.changedTouches[0],i){b(i,this.opts,t);var a=this.getLegendDataIndex(t);a>=0&&(this.opts.series[a].show=!this.opts.series[a].show,this.opts.animation=!!e.animation,this.opts._scrollDistance_=this.scrollOption.currentOffset,Qt.call(this,this.opts.type,this.opts,this.config,this.context))}},Kt.prototype.showToolTip=function(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=null;a=t.changedTouches?t.changedTouches[0]:t.mp.changedTouches[0],a||e.log("touchError");var o=b(a,this.opts,t),r=this.scrollOption.currentOffset,l=n({},this.opts,{_scrollDistance_:r,animation:!1});if("line"===this.opts.type||"area"===this.opts.type||"column"===this.opts.type){var s=void 0==i.index?this.getCurrentDataIndex(t):i.index;if(s>-1){var c=w(this.opts.series,s);if(0!==c.length){var h=A(c,this.opts.chartData.calPoints,s,this.opts.categories,i),d=h.textList,u=h.offset;u.y=o.y,l.tooltip={textList:i.textList?i.textList:d,offset:u,option:i,index:s}}}Qt.call(this,l.type,l,this.config,this.context)}if("mix"===this.opts.type){s=void 0==i.index?this.getCurrentDataIndex(t):i.index;if(s>-1){r=this.scrollOption.currentOffset,l=n({},this.opts,{_scrollDistance_:r,animation:!1}),c=w(this.opts.series,s);if(0!==c.length){var f=P(c,this.opts.chartData.calPoints,s,this.opts.categories,i);d=f.textList,u=f.offset;u.y=o.y,l.tooltip={textList:i.textList?i.textList:d,offset:u,option:i,index:s}}}Qt.call(this,l.type,l,this.config,this.context)}if("candle"===this.opts.type){s=void 0==i.index?this.getCurrentDataIndex(t):i.index;if(s>-1){r=this.scrollOption.currentOffset,l=n({},this.opts,{_scrollDistance_:r,animation:!1}),c=w(this.opts.series,s);if(0!==c.length){h=_(this.opts.series[0].data,c,this.opts.chartData.calPoints,s,this.opts.categories,this.opts.extra.candle,i),d=h.textList,u=h.offset;u.y=o.y,l.tooltip={textList:i.textList?i.textList:d,offset:u,option:i,index:s}}}Qt.call(this,l.type,l,this.config,this.context)}if("pie"===this.opts.type||"ring"===this.opts.type||"rose"===this.opts.type||"funnel"===this.opts.type){s=void 0==i.index?this.getCurrentDataIndex(t):i.index;if(s>-1){r=this.scrollOption.currentOffset,l=n({},this.opts,{_scrollDistance_:r,animation:!1}),c=this.opts._series_[s],d=[{text:i.format?i.format(c):c.name+": "+c.data,color:c.color}],u={x:o.x,y:o.y};l.tooltip={textList:i.textList?i.textList:d,offset:u,option:i,index:s}}Qt.call(this,l.type,l,this.config,this.context)}if("map"===this.opts.type||"word"===this.opts.type){s=void 0==i.index?this.getCurrentDataIndex(t):i.index;if(s>-1){r=this.scrollOption.currentOffset,l=n({},this.opts,{_scrollDistance_:r,animation:!1}),c=this.opts._series_[s],d=[{text:i.format?i.format(c):c.properties.name,color:c.color}],u={x:o.x,y:o.y};l.tooltip={textList:i.textList?i.textList:d,offset:u,option:i,index:s}}l.updateData=!1,Qt.call(this,l.type,l,this.config,this.context)}if("radar"===this.opts.type){s=void 0==i.index?this.getCurrentDataIndex(t):i.index;if(s>-1){r=this.scrollOption.currentOffset,l=n({},this.opts,{_scrollDistance_:r,animation:!1}),c=w(this.opts.series,s);if(0!==c.length){d=c.map((function(t){return{text:i.format?i.format(t):t.name+": "+t.data,color:t.color}})),u={x:o.x,y:o.y};l.tooltip={textList:i.textList?i.textList:d,offset:u,option:i,index:s}}}Qt.call(this,l.type,l,this.config,this.context)}},Kt.prototype.translate=function(t){this.scrollOption={currentOffset:t,startTouchX:t,distance:0,lastMoveTime:0};var e=n({},this.opts,{_scrollDistance_:t,animation:!1});Qt.call(this,this.opts.type,e,this.config,this.context)},Kt.prototype.scrollStart=function(t){var e=null;e=t.changedTouches?t.changedTouches[0]:t.mp.changedTouches[0];var i=b(e,this.opts,t);e&&!0===this.opts.enableScroll&&(this.scrollOption.startTouchX=i.x)},Kt.prototype.scroll=function(t){0===this.scrollOption.lastMoveTime&&(this.scrollOption.lastMoveTime=Date.now());var e=this.opts.extra.touchMoveLimit||20,i=Date.now(),a=i-this.scrollOption.lastMoveTime;if(!(a<Math.floor(1e3/e))){this.scrollOption.lastMoveTime=i;var o=null;if(o=t.changedTouches?t.changedTouches[0]:t.mp.changedTouches[0],o&&!0===this.opts.enableScroll){var r,l=b(o,this.opts,t);r=l.x-this.scrollOption.startTouchX;var s=this.scrollOption.currentOffset,h=c(this,s+r,this.opts.chartData,this.config,this.opts);this.scrollOption.distance=r=h-s;var d=n({},this.opts,{_scrollDistance_:s+r,animation:!1});return Qt.call(this,d.type,d,this.config,this.context),s+r}}},Kt.prototype.scrollEnd=function(t){if(!0===this.opts.enableScroll){var e=this.scrollOption,i=e.currentOffset,a=e.distance;this.scrollOption.currentOffset=i+a,this.scrollOption.distance=0}},"object"===typeof t.exports&&(t.exports=Kt)}).call(this,i("5a52")["default"])},1148:function(t,e,i){"use strict";var a=i("a691"),n=i("1d80");t.exports="".repeat||function(t){var e=String(n(this)),i="",o=a(t);if(o<0||o==1/0)throw RangeError("Wrong number of repetitions");for(;o>0;(o>>>=1)&&(e+=e))1&o&&(i+=e);return i}},"13d5":function(t,e,i){"use strict";var a=i("23e7"),n=i("d58f").left,o=i("a640"),r=i("ae40"),l=o("reduce"),s=r("reduce",{1:0});a({target:"Array",proto:!0,forced:!l||!s},{reduce:function(t){return n(this,t,arguments.length,arguments.length>1?arguments[1]:void 0)}})},"179e":function(t,e,i){var a=i("a9f7");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var n=i("4f06").default;n("156f4b8b",a,!0,{sourceMap:!1,shadowMode:!1})},"1bbb":function(t,e,i){"use strict";var a=i("c742"),n=i.n(a);n.a},"25e9":function(t,e,i){"use strict";i.r(e);var a=i("9188"),n=i.n(a);for(var o in a)"default"!==o&&function(t){i.d(e,t,(function(){return a[t]}))}(o);e["default"]=n.a},"371f":function(t,e,i){var a=i("5684");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var n=i("4f06").default;n("b25e6210",a,!0,{sourceMap:!1,shadowMode:!1})},"3cb5":function(t,e,i){"use strict";i.r(e);var a=i("738d"),n=i("25e9");for(var o in n)"default"!==o&&function(t){i.d(e,t,(function(){return n[t]}))}(o);i("db70");var r,l=i("f0c5"),s=Object(l["a"])(n["default"],a["b"],a["c"],!1,null,"40d68653",null,!1,a["a"],r);e["default"]=s.exports},"408a":function(t,e,i){var a=i("c6b6");t.exports=function(t){if("number"!=typeof t&&"Number"!=a(t))throw TypeError("Incorrect invocation");return+t}},4689:function(t,e,i){"use strict";var a=i("371f"),n=i.n(a);n.a},"46d9":function(t,e,i){"use strict";i.r(e);var a=i("e304"),n=i("c48d");for(var o in n)"default"!==o&&function(t){i.d(e,t,(function(){return n[t]}))}(o);i("4689");var r,l=i("f0c5"),s=Object(l["a"])(n["default"],a["b"],a["c"],!1,null,"bfa32e04",null,!1,a["a"],r);e["default"]=s.exports},"4aac":function(t,e,i){"use strict";var a;i.d(e,"b",(function(){return n})),i.d(e,"c",(function(){return o})),i.d(e,"a",(function(){return a}));var n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return t.text?i("v-uni-text",{staticClass:"uni-badge",class:t.inverted?"uni-badge--"+t.type+" uni-badge--"+t.size+" uni-badge--"+t.type+"-inverted":"uni-badge--"+t.type+" uni-badge--"+t.size,style:t.badgeStyle,on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.onClick()}}},[t._v(t._s(t.text))]):t._e()},o=[]},"4e82":function(t,e,i){"use strict";var a=i("23e7"),n=i("1c0b"),o=i("7b0b"),r=i("d039"),l=i("a640"),s=[],c=s.sort,h=r((function(){s.sort(void 0)})),d=r((function(){s.sort(null)})),u=l("sort"),f=h||!d||!u;a({target:"Array",proto:!0,forced:f},{sort:function(t){return void 0===t?c.call(o(this)):c.call(o(this),n(t))}})},"54f5":function(t,e,i){"use strict";i("a9e3"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var a={name:"UniBadge",props:{type:{type:String,default:"default"},inverted:{type:Boolean,default:!1},text:{type:[String,Number],default:""},size:{type:String,default:"normal"}},data:function(){return{badgeStyle:""}},watch:{text:function(){this.setStyle()}},mounted:function(){this.setStyle()},methods:{setStyle:function(){this.badgeStyle="width: ".concat(8*String(this.text).length+12,"px")},onClick:function(){this.$emit("click")}}};e.default=a},5681:function(t,e,i){"use strict";var a=i("4ea4");i("4de4"),i("caad"),i("d81d"),i("d3b7"),i("25f0"),i("2532"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n,o=a(i("0730")),r=null,l={data:function(){return{todayInfo:{},menuList:[{src:"/static/img/index/inventory.png",tit:"总库存",path:"/pages/inventory/inventory"},{src:"/static/img/index/receipt.png",tit:"入库管理",path:"/pages/receipt/receipt"},{src:"/static/img/index/shipment.png",tit:"出库管理",path:"/pages/shipment/shipment"},{src:"/static/img/index/material.png",tit:"物料",path:"/pages/material/material"},{src:"/static/img/index/task.png",tit:"任务",path:"/pages/task/task"},{src:"/static/img/index/check.png",tit:"盘点单",path:"/pages/cycle/cycle"},{src:"/static/img/index/config.png",tit:"预警设置",path:"/pages/material/warn-config/warn-config"}],cWidth:"",cHeight:"",pixelRatio:1,inventoryTotal:null,warningProp:{},timer:null}},onPullDownRefresh:function(){this.getTask(),this.getMaterialWarningProp(),this.getInventoryProp(),uni.stopPullDownRefresh(),this.timer=setTimeout((function(){uni.stopPullDownRefresh()}),1e3)},onShow:function(){try{var t=uni.getStorageSync("feature_select");t&&this.handleSelect(t)}catch(e){}this.getTask(),this.getMaterialWarningProp(),n=this,this.cWidth=uni.upx2px(710),this.cHeight=uni.upx2px(300),this.getInventoryProp()},onUnload:function(){this.timer&&(clearTimeout(this.timer),this.timer=null)},methods:{goInventory:function(){uni.navigateTo({url:"../inventory/inventory"})},selectFeature:function(){uni.navigateTo({url:"feature"})},handleSelect:function(t){var e=[{src:"/static/img/index/inventory.png",tit:"总库存",path:"/pages/inventory/inventory"},{src:"/static/img/index/receipt.png",tit:"入库管理",path:"/pages/receipt/receipt"},{src:"/static/img/index/shipment.png",tit:"出库管理",path:"/pages/shipment/shipment"},{src:"/static/img/index/material.png",tit:"物料",path:"/pages/material/material"},{src:"/static/img/index/task.png",tit:"任务",path:"/pages/task/task"},{src:"/static/img/index/check.png",tit:"盘点单",path:"/pages/cycle/cycle"},{src:"/static/img/index/config.png",tit:"预警设置",path:"/pages/material/warn-config/warn-config"}];this.menuList=e.filter((function(e){if(t.includes(e.tit))return e}))},getTask:function(){var t=this,e={companyCode:uni.getStorageSync("userData").companies.toString()};this.$api.task.searchTodayInfo(e).then((function(e){t.todayInfo=e.data.data}))},getInventoryProp:function(){var t=this;this.$api.inventory.getInventoryProp().then((function(e){t.inventoryTotal=e.data.data.total,delete e.data.data.list[0],delete e.data.data.list[4],delete e.data.data.list[5],delete e.data.data.list[6],delete e.data.data.list[7],delete e.data.data.list[8],delete e.data.data.list[9];var i=[],a=null;e.data.data.list.map((function(t){i.push({name:t.name,data:t.value}),a+=t.value}));var o=e.data.data.total-a;i.push({name:"其它",data:o}),n.showPie("canvasPie",i)}))},showPie:function(t,e){r=new o.default({$this:n,canvasId:t,type:"pie",fontSize:11,legend:{show:!0,position:"right",float:"center",itemGap:10,padding:5,lineHeight:26,margin:5,borderWidth:1},background:"#FFFFFF",pixelRatio:n.pixelRatio,series:e,animation:!0,width:n.cWidth*n.pixelRatio,height:n.cHeight*n.pixelRatio,dataLabel:!0,extra:{pie:{labelWidth:15}}})},touchPie:function(t){r.showToolTip(t,{format:function(t){return t.name+":"+t.data}})},goAbout:function(){uni.navigateTo({url:"../my/about-us"})},getMaterialWarningProp:function(){var t=this;this.$api.inventory.getMaterialWarningProp().then((function(e){t.warningProp=e.data.data}))},jumpPage:function(t){"总库存"==t?uni.navigateTo({url:"../inventory/inventory"}):"待办"==t?uni.navigateTo({url:"../task/task?status=2"}):"超储预警"==t?uni.navigateTo({url:"../inventory/warn/warn?status=upper"}):uni.navigateTo({url:"../inventory/warn/warn?status=lower"})},analyzeClick:function(t){"全部物料"==t?uni.navigateTo({url:"../inventory/warn/warn?status=all"}):"超储物料"==t?uni.navigateTo({url:"../inventory/warn/warn?status=upper"}):uni.navigateTo({url:"../inventory/warn/warn?status=lower"})}}};e.default=l},5684:function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,".uni-grid-wrap[data-v-bfa32e04]{\ndisplay:-webkit-box;display:-webkit-flex;display:flex;\n-webkit-box-flex:1;-webkit-flex:1;flex:1;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;flex-direction:column;\nwidth:100%\n}.uni-grid[data-v-bfa32e04]{\ndisplay:-webkit-box;display:-webkit-flex;display:flex;\n\n\t\t/* flex: 1;\n */-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;flex-direction:row;-webkit-flex-wrap:wrap;flex-wrap:wrap}.uni-grid--border[data-v-bfa32e04]{position:relative;\n\n\nz-index:1;border-left:1px #e5e5e5 solid\n}",""]),t.exports=e},"5a12":function(t,e,i){var a=i("a446");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var n=i("4f06").default;n("7041d725",a,!0,{sourceMap:!1,shadowMode:!1})},6241:function(t,e,i){"use strict";i.r(e);var a=i("f0e9"),n=i("6507");for(var o in n)"default"!==o&&function(t){i.d(e,t,(function(){return n[t]}))}(o);i("76d3");var r,l=i("f0c5"),s=Object(l["a"])(n["default"],a["b"],a["c"],!1,null,"3fc1c52d",null,!1,a["a"],r);e["default"]=s.exports},6507:function(t,e,i){"use strict";i.r(e);var a=i("5681"),n=i.n(a);for(var o in a)"default"!==o&&function(t){i.d(e,t,(function(){return a[t]}))}(o);e["default"]=n.a},7369:function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.uni-badge[data-v-fe4056fe]{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden;-webkit-box-pack:center;-webkit-justify-content:center;justify-content:center;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;flex-direction:row;height:20px;line-height:20px;color:#333;-webkit-border-radius:100px;border-radius:100px;background-color:#f1f1f1;background-color:transparent;text-align:center;font-family:Helvetica Neue,Helvetica,sans-serif;font-size:12px;padding:0 6px}.uni-badge--inverted[data-v-fe4056fe]{padding:0 5px 0 0;color:#f1f1f1}.uni-badge--default[data-v-fe4056fe]{color:#333;background-color:#f1f1f1}.uni-badge--default-inverted[data-v-fe4056fe]{color:#999;background-color:transparent}.uni-badge--primary[data-v-fe4056fe]{color:#fff;background-color:#007aff}.uni-badge--primary-inverted[data-v-fe4056fe]{color:#007aff;background-color:transparent}.uni-badge--success[data-v-fe4056fe]{color:#fff;background-color:#4cd964}.uni-badge--success-inverted[data-v-fe4056fe]{color:#4cd964;background-color:transparent}.uni-badge--warning[data-v-fe4056fe]{color:#fff;background-color:#f0ad4e}.uni-badge--warning-inverted[data-v-fe4056fe]{color:#f0ad4e;background-color:transparent}.uni-badge--error[data-v-fe4056fe]{color:#fff;background-color:#dd524d}.uni-badge--error-inverted[data-v-fe4056fe]{color:#dd524d;background-color:transparent}.uni-badge--small[data-v-fe4056fe]{-webkit-transform:scale(.8);transform:scale(.8);-webkit-transform-origin:center center;transform-origin:center center}',""]),t.exports=e},"738d":function(t,e,i){"use strict";var a;i.d(e,"b",(function(){return n})),i.d(e,"c",(function(){return o})),i.d(e,"a",(function(){return a}));var n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return t.width?i("v-uni-view",{staticClass:"uni-grid-item",style:"width:"+t.width+";"+(t.square?"height:"+t.width:"")},[i("v-uni-view",{staticClass:"uni-grid-item__box",class:{"uni-grid-item--border":t.showBorder,"uni-grid-item--border-top":t.showBorder&&t.index<t.column,"uni-highlight":t.highlight},style:{"border-right-color":t.borderColor,"border-bottom-color":t.borderColor,"border-top-color":t.borderColor},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t._onClick.apply(void 0,arguments)}}},[t._t("default")],2)],1):t._e()},o=[]},"76d3":function(t,e,i){"use strict";var a=i("5a12"),n=i.n(a);n.a},"7bf8":function(t,e,i){"use strict";i.r(e);var a=i("4aac"),n=i("e7ad");for(var o in n)"default"!==o&&function(t){i.d(e,t,(function(){return n[t]}))}(o);i("1bbb");var r,l=i("f0c5"),s=Object(l["a"])(n["default"],a["b"],a["c"],!1,null,"fe4056fe",null,!1,a["a"],r);e["default"]=s.exports},9188:function(t,e,i){"use strict";i("4160"),i("a434"),i("a9e3"),i("159b"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var a={name:"UniGridItem",inject:["grid"],props:{index:{type:Number,default:0}},data:function(){return{column:0,showBorder:!0,square:!0,highlight:!0,left:0,top:0,openNum:2,width:0,borderColor:"#e5e5e5"}},created:function(){this.column=this.grid.column,this.showBorder=this.grid.showBorder,this.square=this.grid.square,this.highlight=this.grid.highlight,this.top=0===this.hor?this.grid.hor:this.hor,this.left=0===this.ver?this.grid.ver:this.ver,this.borderColor=this.grid.borderColor,this.grid.children.push(this),this.width=this.grid.width},beforeDestroy:function(){var t=this;this.grid.children.forEach((function(e,i){e===t&&t.grid.children.splice(i,1)}))},methods:{_onClick:function(){this.grid.change({detail:{index:this.index}})}}};e.default=a},a446:function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\r\n/**\r\n * 这里是uni-app内置的常用样式变量\r\n *\r\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\r\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\r\n *\r\n */\r\n/**\r\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\r\n *\r\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\r\n */\r\n/* 颜色变量 */\r\n/* 行为相关颜色 */\r\n/* 文字基本颜色 */\r\n/* 背景颜色 */\r\n/* 边框颜色 */\r\n/* 尺寸变量 */\r\n/* 文字尺寸 */\r\n/* 图片尺寸 */\r\n/* Border Radius */\r\n/* 水平间距 */\r\n/* 垂直间距 */\r\n/* 透明度 */\r\n/* 文章场景相关 */.menu .panel-b[data-v-3fc1c52d]{height:%?210?%;padding:%?10?% %?30?% 0;color:#fff;background-color:#007aff}.menu .panel-b .total[data-v-3fc1c52d],\r\n.menu .panel-b .n-v[data-v-3fc1c52d]{font-size:%?32?%;font-weight:700}.menu .panel-b .n-v[data-v-3fc1c52d]{margin-bottom:%?10?%;font-size:%?36?%}.menu .panel-t[data-v-3fc1c52d]{height:%?250?%;margin:%?-60?% %?20?% 0;-webkit-border-radius:%?10?%;border-radius:%?10?%;background-color:#fff}.menu .panel-t .header[data-v-3fc1c52d]{border-bottom:%?2?% solid #e5e5e5}.menu .panel-t .header .h-item[data-v-3fc1c52d]{width:25%;height:%?160?%}.menu .panel-t .header .h-item .i-f[data-v-3fc1c52d]{position:relative;width:%?60?%;height:%?60?%;line-height:%?60?%;text-align:center;background-color:#007aff}.menu .panel-t .header .h-item .i-f .dot[data-v-3fc1c52d]{position:absolute;left:%?36?%;top:%?-16?%}.menu .panel-t .header .h-item .inventory[data-v-3fc1c52d]{background-color:#40b5fb}.menu .panel-t .header .h-item .up[data-v-3fc1c52d]{background-color:#f6bb19}.menu .panel-t .header .h-item .warn-upper[data-v-3fc1c52d]{background-color:#ed1e64}.menu .panel-t .header .h-item .warn-lower[data-v-3fc1c52d]{background-color:#f87314}.menu .panel-t .header .h-item .h-tit[data-v-3fc1c52d]{margin-top:%?20?%}.menu .panel-t .bottom[data-v-3fc1c52d]{line-height:%?90?%}.menu .panel-t .bottom .notice[data-v-3fc1c52d]{margin-left:%?20?%}.menu .menu-box[data-v-3fc1c52d]{margin:%?20?% %?20?% 0;padding:%?40?% %?20?% %?10?%;background:#fff;-webkit-border-top-left-radius:%?10?%;border-top-left-radius:%?10?%;-webkit-border-top-right-radius:%?10?%;border-top-right-radius:%?10?%}.menu .menu-box .feature[data-v-3fc1c52d]{font-size:%?32?%;font-weight:700}.menu .menu-box .uni-grid-wrap[data-v-3fc1c52d] .uni-grid-item__box{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;align-items:center}.menu .menu-box .uni-grid-wrap[data-v-3fc1c52d] .uni-grid-item__box uni-image{width:%?60?%;height:%?60?%;margin-bottom:%?10?%}.menu .echarts-container[data-v-3fc1c52d]{height:%?450?%;margin:%?20?% %?20?%;background-color:#fff;-webkit-border-radius:%?10?%;border-radius:%?10?%}.menu .echarts-container .e-t[data-v-3fc1c52d]{padding-top:%?40?%;font-size:%?32?%;font-weight:700}.menu .echarts-container .stock[data-v-3fc1c52d]{height:%?40?%;padding:0 %?20?%;margin-top:%?20?%;background-color:#f4f7ff;font-size:%?24?%}.menu .echarts-container .chart[data-v-3fc1c52d]{width:100%}.menu .echarts-container .chart .charts-pie[data-v-3fc1c52d]{width:100%}.menu .material-container[data-v-3fc1c52d]{height:%?340?%;margin:%?20?% %?20?%;-webkit-border-radius:%?10?%;border-radius:%?10?%;background-color:#fff}.menu .material-container .m-a[data-v-3fc1c52d]{padding:%?40?% 0 %?20?%;font-size:%?32?%;font-weight:700}.menu .material-container .m-c[data-v-3fc1c52d]{height:%?220?%}.menu .material-container .m-c .num[data-v-3fc1c52d]{color:red;font-weight:700;font-size:%?32?%}.menu .material-container .m-c .unit[data-v-3fc1c52d]{color:#979797;font-size:%?24?%;margin-left:%?10?%}.menu .material-container .m-c .l-c[data-v-3fc1c52d],\r\n.menu .material-container .m-c .r-c[data-v-3fc1c52d]{width:47%;height:100%}.menu .material-container .m-c .l-c[data-v-3fc1c52d]{padding-left:%?20?%;background-color:#f4f7ff}.menu .material-container .m-c .l-c .s-fw[data-v-3fc1c52d]{font-weight:700}.menu .material-container .m-c .r-c .c-t[data-v-3fc1c52d],\r\n.menu .material-container .m-c .r-c .c-b[data-v-3fc1c52d]{height:%?100?%;padding-left:%?20?%;background-color:#f4f7ff}.menu .material-container .m-c .r-c .c-t .s-fs[data-v-3fc1c52d],\r\n.menu .material-container .m-c .r-c .c-b .s-fs[data-v-3fc1c52d]{font-size:%?24?%}.menu .material-container .m-c .r-c .c-b[data-v-3fc1c52d]{margin-top:%?20?%}',""]),t.exports=e},a9f7:function(t,e,i){var a=i("24fb");e=a(!1),e.push([t.i,".uni-grid-item[data-v-40d68653]{\nheight:100%;display:-webkit-box;display:-webkit-flex;display:flex\n}.uni-grid-item__box[data-v-40d68653]{\ndisplay:-webkit-box;display:-webkit-flex;display:flex;width:100%;\nposition:relative;-webkit-box-flex:1;-webkit-flex:1;flex:1;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;flex-direction:column\n\t\t/* justify-content: center;\n */\n\t\t/* align-items: center;\n */}.uni-grid-item--border[data-v-40d68653]{position:relative;\n\n\nz-index:0;border-bottom:1px #e5e5e5 solid;border-right:1px #e5e5e5 solid\n}.uni-grid-item--border-top[data-v-40d68653]{position:relative;\n\n\nborder-top:1px #e5e5e5 solid;z-index:0\n}.uni-highlight[data-v-40d68653]:active{background-color:#f1f1f1}",""]),t.exports=e},b680:function(t,e,i){"use strict";var a=i("23e7"),n=i("a691"),o=i("408a"),r=i("1148"),l=i("d039"),s=1..toFixed,c=Math.floor,h=function(t,e,i){return 0===e?i:e%2===1?h(t,e-1,i*t):h(t*t,e/2,i)},d=function(t){var e=0,i=t;while(i>=4096)e+=12,i/=4096;while(i>=2)e+=1,i/=2;return e},u=s&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!l((function(){s.call({})}));a({target:"Number",proto:!0,forced:u},{toFixed:function(t){var e,i,a,l,s=o(this),u=n(t),f=[0,0,0,0,0,0],p="",x="0",g=function(t,e){var i=-1,a=e;while(++i<6)a+=t*f[i],f[i]=a%1e7,a=c(a/1e7)},v=function(t){var e=6,i=0;while(--e>=0)i+=f[e],f[e]=c(i/t),i=i%t*1e7},y=function(){var t=6,e="";while(--t>=0)if(""!==e||0===t||0!==f[t]){var i=String(f[t]);e=""===e?i:e+r.call("0",7-i.length)+i}return e};if(u<0||u>20)throw RangeError("Incorrect fraction digits");if(s!=s)return"NaN";if(s<=-1e21||s>=1e21)return String(s);if(s<0&&(p="-",s=-s),s>1e-21)if(e=d(s*h(2,69,1))-69,i=e<0?s*h(2,-e,1):s/h(2,e,1),i*=4503599627370496,e=52-e,e>0){g(0,i),a=u;while(a>=7)g(1e7,0),a-=7;g(h(10,a,1),0),a=e-1;while(a>=23)v(1<<23),a-=23;v(1<<a),g(1,1),v(2),x=y()}else g(0,i),g(1<<-e,0),x=y()+r.call("0",u);return u>0?(l=x.length,x=p+(l<=u?"0."+r.call("0",u-l)+x:x.slice(0,l-u)+"."+x.slice(l-u))):x=p+x,x}})},c48d:function(t,e,i){"use strict";i.r(e);var a=i("cba9"),n=i.n(a);for(var o in a)"default"!==o&&function(t){i.d(e,t,(function(){return a[t]}))}(o);e["default"]=n.a},c742:function(t,e,i){var a=i("7369");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var n=i("4f06").default;n("c138fd92",a,!0,{sourceMap:!1,shadowMode:!1})},cb29:function(t,e,i){var a=i("23e7"),n=i("81d5"),o=i("44d2");a({target:"Array",proto:!0},{fill:n}),o("fill")},cba9:function(t,e,i){"use strict";i("4160"),i("a9e3"),i("d3b7"),i("e25e"),i("ac1f"),i("25f0"),i("159b"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var a={name:"UniGrid",props:{column:{type:Number,default:3},showBorder:{type:Boolean,default:!0},borderColor:{type:String,default:"#e5e5e5"},square:{type:Boolean,default:!0},highlight:{type:Boolean,default:!0}},provide:function(){return{grid:this}},data:function(){var t="Uni_".concat(Math.ceil(1e6*Math.random()).toString(36));return{elId:t,width:0}},created:function(){this.children=[]},mounted:function(){var t=this;this.$nextTick((function(){t.init()}))},methods:{init:function(){var t=this;setTimeout((function(){t._getSize((function(e){t.children.forEach((function(t,i){t.width=e}))}))}),50)},change:function(t){this.$emit("change",t)},_getSize:function(t){var e=this;uni.createSelectorQuery().in(this).select("#".concat(this.elId)).boundingClientRect().exec((function(i){e.width=parseInt((i[0].width-1)/e.column)+"px",t(e.width)}))}}};e.default=a},db70:function(t,e,i){"use strict";var a=i("179e"),n=i.n(a);n.a},e304:function(t,e,i){"use strict";var a;i.d(e,"b",(function(){return n})),i.d(e,"c",(function(){return o})),i.d(e,"a",(function(){return a}));var n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{staticClass:"uni-grid-wrap"},[i("v-uni-view",{ref:"uni-grid",staticClass:"uni-grid",class:{"uni-grid--border":t.showBorder},style:{"border-left-color":t.borderColor},attrs:{id:t.elId}},[t._t("default")],2)],1)},o=[]},e7ad:function(t,e,i){"use strict";i.r(e);var a=i("54f5"),n=i.n(a);for(var o in a)"default"!==o&&function(t){i.d(e,t,(function(){return a[t]}))}(o);e["default"]=n.a},f0e9:function(t,e,i){"use strict";i.d(e,"b",(function(){return n})),i.d(e,"c",(function(){return o})),i.d(e,"a",(function(){return a}));var a={uniBadge:i("7bf8").default,uniIcons:i("1968").default,uniGrid:i("46d9").default,uniGridItem:i("3cb5").default},n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{staticClass:"menu"},[i("v-uni-view",{staticClass:"panel-b"},[i("v-uni-view",{staticClass:"total"},[t._v("库存总数")]),i("v-uni-view",{staticClass:"n-v"},[t._v(t._s(t.inventoryTotal))]),i("v-uni-view",{staticClass:"u-f"},[i("v-uni-view",{staticClass:"u-f1"},[t._v("今日入库数 "+t._s(t.todayInfo.todayReceipt))]),i("v-uni-view",{staticClass:"u-f1"},[t._v("今日出库数 "+t._s(Math.abs(t.todayInfo.todayShipment)))])],1)],1),i("v-uni-view",{staticClass:"panel-t"},[i("v-uni-view",{staticClass:"header u-f"},[i("v-uni-view",{staticClass:"h-item u-f u-f-column u-f-jcc u-f-aic",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.jumpPage("总库存")}}},[i("v-uni-view",{staticClass:"i-f inventory"},[i("v-uni-text",{staticClass:"icon iconfont icon-kucunguanli"})],1),i("v-uni-view",{staticClass:"h-tit"},[t._v("总库存")])],1),i("v-uni-view",{staticClass:"h-item u-f u-f-column u-f-jcc u-f-aic",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.jumpPage("待办")}}},[i("v-uni-view",{staticClass:"i-f up"},[i("v-uni-text",{staticClass:"icon iconfont icon-to-diagnose"}),i("v-uni-view",{staticClass:"dot"},[i("uni-badge",{attrs:{type:"error",text:0==t.todayInfo.todayTAask?"":t.todayInfo.todayTAask}})],1)],1),i("v-uni-view",{staticClass:"h-tit"},[t._v("待办")])],1),i("v-uni-view",{staticClass:"h-item u-f u-f-column u-f-jcc u-f-aic",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.jumpPage("超储预警")}}},[i("v-uni-view",{staticClass:"i-f warn-upper"},[i("v-uni-text",{staticClass:"icon iconfont icon-baojing"}),i("v-uni-view",{staticClass:"dot"},[i("uni-badge",{attrs:{type:"error",text:0==t.warningProp.upper?"":t.warningProp.upper}})],1)],1),i("v-uni-view",{staticClass:"h-tit"},[t._v("超储预警")])],1),i("v-uni-view",{staticClass:"h-item u-f u-f-column u-f-jcc u-f-aic",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.jumpPage("缺货预警")}}},[i("v-uni-view",{staticClass:"i-f warn-lower"},[i("v-uni-text",{staticClass:"icon iconfont icon-baojing"}),i("v-uni-view",{staticClass:"dot"},[i("uni-badge",{attrs:{type:"error",text:0==t.warningProp.lower?"":t.warningProp.lower}})],1)],1),i("v-uni-view",{staticClass:"h-tit"},[t._v("缺货预警")])],1)],1),i("v-uni-view",{staticClass:"bottom plr-10 u-f u-f-aic",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.goAbout.apply(void 0,arguments)}}},[i("uni-icons",{attrs:{type:"sound",size:"24",color:"gray"}}),i("v-uni-text",{staticClass:"notice"},[t._v("您好,欢迎使用,点击了解")])],1)],1),i("v-uni-view",{staticClass:"menu-box"},[i("v-uni-view",{staticClass:"u-f u-f-jcsb u-f-aic"},[i("v-uni-view",{staticClass:"feature"},[t._v("常用功能")]),i("v-uni-view",{on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.selectFeature.apply(void 0,arguments)}}},[i("v-uni-text",{staticClass:"iconfont icon-edit-square"})],1)],1),i("uni-grid",{attrs:{column:4,showBorder:!1,square:!0}},t._l(t.menuList,(function(e,a){return i("v-uni-navigator",{key:a,attrs:{url:e.path,"hover-class":"none"}},[i("uni-grid-item",[i("v-uni-image",{attrs:{src:e.src,mode:"aspectFit"}}),i("v-uni-text",{staticClass:"text"},[t._v(t._s(e.tit))])],1)],1)})),1)],1),i("v-uni-view",{staticClass:"echarts-container plr-10"},[i("v-uni-view",{staticClass:"e-t"},[t._v("库存分布")]),i("v-uni-view",{staticClass:"stock u-f u-f-jcsb u-f-aic"},[i("v-uni-view",[t._v("库存总数")]),i("v-uni-view",[t._v(t._s(t.inventoryTotal))])],1),i("v-uni-view",{staticClass:"u-f u-f-row chart"},[i("v-uni-canvas",{staticClass:"charts-pie",attrs:{"canvas-id":"canvasPie",id:"canvasPie"},on:{touchstart:function(e){arguments[0]=e=t.$handleEvent(e),t.touchPie.apply(void 0,arguments)}}})],1)],1),i("v-uni-view",{staticClass:"material-container plr-10"},[i("v-uni-view",{staticClass:"m-a"},[t._v("物料分析")]),i("v-uni-view",{staticClass:"m-c u-f u-f-jcsb"},[i("v-uni-view",{staticClass:"l-c u-f",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.analyzeClick("全部物料")}}},[i("v-uni-view",{staticClass:"u-f-asc"},[i("v-uni-view",{staticClass:"s-fw mb-5"},[t._v("全部物料")]),i("v-uni-view",[i("v-uni-text",{staticClass:"num"},[t._v(t._s(t.warningProp.all?t.warningProp.all:0))]),i("v-uni-text",{staticClass:"unit"},[t._v("种")])],1)],1)],1),i("v-uni-view",{staticClass:"r-c"},[i("v-uni-view",{staticClass:"c-t u-f",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.analyzeClick("超储物料")}}},[i("v-uni-view",{staticClass:"u-f-asc"},[i("v-uni-view",{staticClass:"s-fs mb-5"},[t._v("超储物料")]),i("v-uni-view",[i("v-uni-text",{staticClass:"num"},[t._v(t._s(t.warningProp.upper?t.warningProp.upper:0))]),i("v-uni-text",{staticClass:"unit"},[t._v("种")])],1)],1)],1),i("v-uni-view",{staticClass:"c-b u-f",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.analyzeClick("缺货物料")}}},[i("v-uni-view",{staticClass:"u-f-asc"},[i("v-uni-view",{staticClass:"s-fs mb-5"},[t._v("缺货物料")]),i("v-uni-view",[i("v-uni-text",{staticClass:"num"},[t._v(t._s(t.warningProp.lower?t.warningProp.lower:0))]),i("v-uni-text",{staticClass:"unit"},[t._v("种")])],1)],1)],1)],1)],1)],1)],1)},o=[]}}]);