diff --git a/data/dashboard/asset-manifest.json b/data/dashboard/asset-manifest.json index b14bb2ca..78f3c908 100644 --- a/data/dashboard/asset-manifest.json +++ b/data/dashboard/asset-manifest.json @@ -1,7 +1,7 @@ { "files": { "main.css": "/df9a0d86-3283-4920-82dc-4555fc0d1d8b/static/css/main.1e415bb7.css", - "main.js": "/df9a0d86-3283-4920-82dc-4555fc0d1d8b/static/js/main.ab64643f.js", + "main.js": "/df9a0d86-3283-4920-82dc-4555fc0d1d8b/static/js/main.065fe6b4.js", "static/media/signInImage.png": "/df9a0d86-3283-4920-82dc-4555fc0d1d8b/static/media/signInImage.eeb0c777f5867442d1a2.png", "static/media/BgSignUp.png": "/df9a0d86-3283-4920-82dc-4555fc0d1d8b/static/media/BgSignUp.2dea4acf779bbfe49e5c.png", "static/media/roboto-all-500-normal.woff": "/df9a0d86-3283-4920-82dc-4555fc0d1d8b/static/media/roboto-all-500-normal.0ab669b7a0d19b178f57.woff", @@ -33,6 +33,6 @@ }, "entrypoints": [ "static/css/main.1e415bb7.css", - "static/js/main.ab64643f.js" + "static/js/main.065fe6b4.js" ] } \ No newline at end of file diff --git a/data/dashboard/index.html b/data/dashboard/index.html index 3b8dbb66..0b5d280f 100644 --- a/data/dashboard/index.html +++ b/data/dashboard/index.html @@ -1 +1 @@ -Oxygen Metrics
\ No newline at end of file +Oxygen Metrics
\ No newline at end of file diff --git a/data/dashboard/static/js/main.ab64643f.js b/data/dashboard/static/js/main.065fe6b4.js similarity index 92% rename from data/dashboard/static/js/main.ab64643f.js rename to data/dashboard/static/js/main.065fe6b4.js index 0aa5a609..e205521d 100644 --- a/data/dashboard/static/js/main.ab64643f.js +++ b/data/dashboard/static/js/main.065fe6b4.js @@ -1,2 +1,2 @@ -/*! For license information please see main.ab64643f.js.LICENSE.txt */ -!function(){var e={910:function(e,t,n){"use strict";var r;function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n>16,o=n>>8&255,s=255&n;return"#"+(16777216+65536*(Math.round((r-a)*i)+a)+256*(Math.round((r-o)*i)+o)+(Math.round((r-s)*i)+s)).toString(16).slice(1)}},{key:"shadeColor",value:function(t,n){return e.isColorHex(n)?this.shadeHexColor(t,n):this.shadeRGBColor(t,n)}}],[{key:"bind",value:function(e,t){return function(){return e.apply(t,arguments)}}},{key:"isObject",value:function(e){return e&&"object"===o(e)&&!Array.isArray(e)&&null!=e}},{key:"is",value:function(e,t){return Object.prototype.toString.call(t)==="[object "+e+"]"}},{key:"listToArray",value:function(e){var t,n=[];for(t=0;t1&&void 0!==arguments[1]?arguments[1]:2;return Number.isInteger(e)?e:parseFloat(e.toPrecision(t))}},{key:"randomId",value:function(){return(Math.random()+1).toString(36).substring(4)}},{key:"noExponents",value:function(e){var t=String(e).split(/[eE]/);if(1===t.length)return t[0];var n="",r=e<0?"-":"",i=t[0].replace(".",""),a=Number(t[1])+1;if(a<0){for(n=r+"0.";a++;)n+="0";return n+i.replace(/^-/,"")}for(a-=i.length;a--;)n+="0";return i+n}},{key:"getDimensions",value:function(e){var t=getComputedStyle(e,null),n=e.clientHeight,r=e.clientWidth;return n-=parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),[r-=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight),n]}},{key:"getBoundingClientRect",value:function(e){var t=e.getBoundingClientRect();return{top:t.top,right:t.right,bottom:t.bottom,left:t.left,width:e.clientWidth,height:e.clientHeight,x:t.left,y:t.top}}},{key:"getLargestStringFromArr",value:function(e){return e.reduce((function(e,t){return Array.isArray(t)&&(t=t.reduce((function(e,t){return e.length>t.length?e:t}))),e.length>t.length?e:t}),0)}},{key:"hexToRgba",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"#999999",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.6;"#"!==e.substring(0,1)&&(e="#999999");var n=e.replace("#","");n=n.match(new RegExp("(.{"+n.length/3+"})","g"));for(var r=0;r1&&void 0!==arguments[1]?arguments[1]:"x",n=e.toString().slice();return n.replace(/[` ~!@#$%^&*()|+\=?;:'",.<>{}[\]\\/]/gi,t)}},{key:"negToZero",value:function(e){return e<0?0:e}},{key:"moveIndexInArray",value:function(e,t,n){if(n>=e.length)for(var r=n-e.length+1;r--;)e.push(void 0);return e.splice(n,0,e.splice(t,1)[0]),e}},{key:"extractNumber",value:function(e){return parseFloat(e.replace(/[^\d.]*/g,""))}},{key:"findAncestor",value:function(e,t){for(;(e=e.parentElement)&&!e.classList.contains(t););return e}},{key:"setELstyles",value:function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e.style.key=t[n])}},{key:"isNumber",value:function(e){return!isNaN(e)&&parseFloat(Number(e))===e&&!isNaN(parseInt(e,10))}},{key:"isFloat",value:function(e){return Number(e)===e&&e%1!=0}},{key:"isSafari",value:function(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}},{key:"isFirefox",value:function(){return navigator.userAgent.toLowerCase().indexOf("firefox")>-1}},{key:"isIE11",value:function(){if(-1!==window.navigator.userAgent.indexOf("MSIE")||window.navigator.appVersion.indexOf("Trident/")>-1)return!0}},{key:"isIE",value:function(){var e=window.navigator.userAgent,t=e.indexOf("MSIE ");if(t>0)return parseInt(e.substring(t+5,e.indexOf(".",t)),10);if(e.indexOf("Trident/")>0){var n=e.indexOf("rv:");return parseInt(e.substring(n+3,e.indexOf(".",n)),10)}var r=e.indexOf("Edge/");return r>0&&parseInt(e.substring(r+5,e.indexOf(".",r)),10)}}]),e}(),w=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.setEasingFunctions()}return c(e,[{key:"setEasingFunctions",value:function(){var e;if(!this.w.globals.easing){switch(this.w.config.chart.animations.easing){case"linear":e="-";break;case"easein":e="<";break;case"easeout":e=">";break;case"easeinout":default:e="<>";break;case"swing":e=function(e){var t=1.70158;return(e-=1)*e*((t+1)*e+t)+1};break;case"bounce":e=function(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375};break;case"elastic":e=function(e){return e===!!e?e:Math.pow(2,-10*e)*Math.sin((e-.075)*(2*Math.PI)/.3)+1}}this.w.globals.easing=e}}},{key:"animateLine",value:function(e,t,n,r){e.attr(t).animate(r).attr(n)}},{key:"animateMarker",value:function(e,t,n,r,i,a){t||(t=0),e.attr({r:t,width:t,height:t}).animate(r,i).attr({r:n,width:n.width,height:n.height}).afterAll((function(){a()}))}},{key:"animateCircle",value:function(e,t,n,r,i){e.attr({r:t.r,cx:t.cx,cy:t.cy}).animate(r,i).attr({r:n.r,cx:n.cx,cy:n.cy})}},{key:"animateRect",value:function(e,t,n,r,i){e.attr(t).animate(r).attr(n).afterAll((function(){return i()}))}},{key:"animatePathsGradually",value:function(e){var t=e.el,n=e.realIndex,r=e.j,i=e.fill,a=e.pathFrom,o=e.pathTo,s=e.speed,l=e.delay,c=this.w,u=0;c.config.chart.animations.animateGradually.enabled&&(u=c.config.chart.animations.animateGradually.delay),c.config.chart.animations.dynamicAnimation.enabled&&c.globals.dataChanged&&"bar"!==c.config.chart.type&&(u=0),this.morphSVG(t,n,r,"line"!==c.config.chart.type||c.globals.comboCharts?i:"stroke",a,o,s,l*u)}},{key:"showDelayedElements",value:function(){this.w.globals.delayedElements.forEach((function(e){var t=e.el;t.classList.remove("apexcharts-element-hidden"),t.classList.add("apexcharts-hidden-element-shown")}))}},{key:"animationCompleted",value:function(e){var t=this.w;t.globals.animationEnded||(t.globals.animationEnded=!0,this.showDelayedElements(),"function"==typeof t.config.chart.events.animationEnd&&t.config.chart.events.animationEnd(this.ctx,{el:e,w:t}))}},{key:"morphSVG",value:function(e,t,n,r,i,a,o,s){var l=this,c=this.w;i||(i=e.attr("pathFrom")),a||(a=e.attr("pathTo"));var u=function(e){return"radar"===c.config.chart.type&&(o=1),"M 0 ".concat(c.globals.gridHeight)};(!i||i.indexOf("undefined")>-1||i.indexOf("NaN")>-1)&&(i=u()),(!a||a.indexOf("undefined")>-1||a.indexOf("NaN")>-1)&&(a=u()),c.globals.shouldAnimate||(o=1),e.plot(i).animate(1,c.globals.easing,s).plot(i).animate(o,c.globals.easing,s).plot(a).afterAll((function(){y.isNumber(n)?n===c.globals.series[c.globals.maxValsInArrayIndex].length-2&&c.globals.shouldAnimate&&l.animationCompleted(e):"none"!==r&&c.globals.shouldAnimate&&(!c.globals.comboCharts&&t===c.globals.series.length-1||c.globals.comboCharts)&&l.animationCompleted(e),l.showDelayedElements()}))}}]),e}(),k=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"getDefaultFilter",value:function(e,t){var n=this.w;e.unfilter(!0),(new window.SVG.Filter).size("120%","180%","-5%","-40%"),"none"!==n.config.states.normal.filter?this.applyFilter(e,t,n.config.states.normal.filter.type,n.config.states.normal.filter.value):n.config.chart.dropShadow.enabled&&this.dropShadow(e,n.config.chart.dropShadow,t)}},{key:"addNormalFilter",value:function(e,t){var n=this.w;n.config.chart.dropShadow.enabled&&!e.node.classList.contains("apexcharts-marker")&&this.dropShadow(e,n.config.chart.dropShadow,t)}},{key:"addLightenFilter",value:function(e,t,n){var r=this,i=this.w,a=n.intensity;e.unfilter(!0),new window.SVG.Filter,e.filter((function(e){var n=i.config.chart.dropShadow;(n.enabled?r.addShadow(e,t,n):e).componentTransfer({rgb:{type:"linear",slope:1.5,intercept:a}})})),e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)}},{key:"addDarkenFilter",value:function(e,t,n){var r=this,i=this.w,a=n.intensity;e.unfilter(!0),new window.SVG.Filter,e.filter((function(e){var n=i.config.chart.dropShadow;(n.enabled?r.addShadow(e,t,n):e).componentTransfer({rgb:{type:"linear",slope:a}})})),e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)}},{key:"applyFilter",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:.5;switch(n){case"none":this.addNormalFilter(e,t);break;case"lighten":this.addLightenFilter(e,t,{intensity:r});break;case"darken":this.addDarkenFilter(e,t,{intensity:r})}}},{key:"addShadow",value:function(e,t,n){var r=n.blur,i=n.top,a=n.left,o=n.color,s=n.opacity,l=e.flood(Array.isArray(o)?o[t]:o,s).composite(e.sourceAlpha,"in").offset(a,i).gaussianBlur(r).merge(e.source);return e.blend(e.source,l)}},{key:"dropShadow",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=t.top,i=t.left,a=t.blur,o=t.color,s=t.opacity,l=t.noUserSpaceOnUse,c=this.w;return e.unfilter(!0),y.isIE()&&"radialBar"===c.config.chart.type||(o=Array.isArray(o)?o[n]:o,e.filter((function(e){var t;t=y.isSafari()||y.isFirefox()||y.isIE()?e.flood(o,s).composite(e.sourceAlpha,"in").offset(i,r).gaussianBlur(a):e.flood(o,s).composite(e.sourceAlpha,"in").offset(i,r).gaussianBlur(a).merge(e.source),e.blend(e.source,t)})),l||e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)),e}},{key:"setSelectionFilter",value:function(e,t,n){var r=this.w;if(void 0!==r.globals.selectedDataPoints[t]&&r.globals.selectedDataPoints[t].indexOf(n)>-1){e.node.setAttribute("selected",!0);var i=r.config.states.active.filter;"none"!==i&&this.applyFilter(e,t,i.type,i.value)}}},{key:"_scaleFilterSize",value:function(e){!function(t){for(var n in t)t.hasOwnProperty(n)&&e.setAttribute(n,t[n])}({width:"200%",height:"200%",x:"-50%",y:"-50%"})}}]),e}(),S=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"roundPathCorners",value:function(e,t){function n(e,t,n){var i=t.x-e.x,a=t.y-e.y,o=Math.sqrt(i*i+a*a);return r(e,t,Math.min(1,n/o))}function r(e,t,n){return{x:e.x+(t.x-e.x)*n,y:e.y+(t.y-e.y)*n}}function i(e,t){e.length>2&&(e[e.length-2]=t.x,e[e.length-1]=t.y)}function a(e){return{x:parseFloat(e[e.length-2]),y:parseFloat(e[e.length-1])}}e.indexOf("NaN")>-1&&(e="");var o=e.split(/[,\s]/).reduce((function(e,t){var n=t.match("([a-zA-Z])(.+)");return n?(e.push(n[1]),e.push(n[2])):e.push(t),e}),[]).reduce((function(e,t){return parseFloat(t)==t&&e.length?e[e.length-1].push(t):e.push([t]),e}),[]),s=[];if(o.length>1){var l=a(o[0]),c=null;"Z"==o[o.length-1][0]&&o[0].length>2&&(c=["L",l.x,l.y],o[o.length-1]=c),s.push(o[0]);for(var u=1;u2&&"L"==h[0]&&f.length>2&&"L"==f[0]){var p,g,m=a(d),v=a(h),x=a(f);p=n(v,m,t),g=n(v,x,t),i(h,p),h.origPoint=v,s.push(h);var b=r(p,v,.5),y=r(v,g,.5),w=["C",b.x,b.y,y.x,y.y,g.x,g.y];w.origPoint=v,s.push(w)}else s.push(h)}if(c){var k=a(s[s.length-1]);s.push(["Z"]),i(s[0],k)}}else s=o;return s.reduce((function(e,t){return e+t.join(" ")+" "}),"")}},{key:"drawLine",value:function(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"#a8a8a8",a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,s=arguments.length>7&&void 0!==arguments[7]?arguments[7]:"butt";return this.w.globals.dom.Paper.line().attr({x1:e,y1:t,x2:n,y2:r,stroke:i,"stroke-dasharray":a,"stroke-width":o,"stroke-linecap":s})}},{key:"drawRect",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"#fefefe",o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:1,s=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,l=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,c=arguments.length>9&&void 0!==arguments[9]?arguments[9]:0,u=this.w.globals.dom.Paper.rect();return u.attr({x:e,y:t,width:n>0?n:0,height:r>0?r:0,rx:i,ry:i,opacity:o,"stroke-width":null!==s?s:0,stroke:null!==l?l:"none","stroke-dasharray":c}),u.node.setAttribute("fill",a),u}},{key:"drawPolygon",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"#e1e1e1",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"none";return this.w.globals.dom.Paper.polygon(e).attr({fill:r,stroke:t,"stroke-width":n})}},{key:"drawCircle",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;e<0&&(e=0);var n=this.w.globals.dom.Paper.circle(2*e);return null!==t&&n.attr(t),n}},{key:"drawPath",value:function(e){var t=e.d,n=void 0===t?"":t,r=e.stroke,i=void 0===r?"#a8a8a8":r,a=e.strokeWidth,o=void 0===a?1:a,s=e.fill,l=e.fillOpacity,c=void 0===l?1:l,u=e.strokeOpacity,d=void 0===u?1:u,h=e.classes,f=e.strokeLinecap,p=void 0===f?null:f,g=e.strokeDashArray,m=void 0===g?0:g,v=this.w;return null===p&&(p=v.config.stroke.lineCap),(n.indexOf("undefined")>-1||n.indexOf("NaN")>-1)&&(n="M 0 ".concat(v.globals.gridHeight)),v.globals.dom.Paper.path(n).attr({fill:s,"fill-opacity":c,stroke:i,"stroke-opacity":d,"stroke-linecap":p,"stroke-width":o,"stroke-dasharray":m,class:h})}},{key:"group",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=this.w.globals.dom.Paper.group();return null!==e&&t.attr(e),t}},{key:"move",value:function(e,t){return["M",e,t].join(" ")}},{key:"line",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=null;return null===n?r=[" L",e,t].join(" "):"H"===n?r=[" H",e].join(" "):"V"===n&&(r=[" V",t].join(" ")),r}},{key:"curve",value:function(e,t,n,r,i,a){return["C",e,t,n,r,i,a].join(" ")}},{key:"quadraticCurve",value:function(e,t,n,r){return["Q",e,t,n,r].join(" ")}},{key:"arc",value:function(e,t,n,r,i,a,o){var s="A";return arguments.length>7&&void 0!==arguments[7]&&arguments[7]&&(s="a"),[s,e,t,n,r,i,a,o].join(" ")}},{key:"renderPaths",value:function(e){var t,n=e.j,r=e.realIndex,i=e.pathFrom,o=e.pathTo,s=e.stroke,l=e.strokeWidth,c=e.strokeLinecap,u=e.fill,d=e.animationDelay,h=e.initialSpeed,f=e.dataChangeSpeed,p=e.className,g=e.shouldClipToGrid,m=void 0===g||g,v=e.bindEventsOnPaths,x=void 0===v||v,b=e.drawShadow,y=void 0===b||b,S=this.w,C=new k(this.ctx),A=new w(this.ctx),E=this.w.config.chart.animations.enabled,P=E&&this.w.config.chart.animations.dynamicAnimation.enabled,T=!!(E&&!S.globals.resized||P&&S.globals.dataChanged&&S.globals.shouldAnimate);T?t=i:(t=o,S.globals.animationEnded=!0);var M,_=S.config.stroke.dashArray;M=Array.isArray(_)?_[r]:S.config.stroke.dashArray;var L=this.drawPath({d:t,stroke:s,strokeWidth:l,fill:u,fillOpacity:1,classes:p,strokeLinecap:c,strokeDashArray:M});if(L.attr("index",r),m&&L.attr({"clip-path":"url(#gridRectMask".concat(S.globals.cuid,")")}),"none"!==S.config.states.normal.filter.type)C.getDefaultFilter(L,r);else if(S.config.chart.dropShadow.enabled&&y&&(!S.config.chart.dropShadow.enabledOnSeries||S.config.chart.dropShadow.enabledOnSeries&&-1!==S.config.chart.dropShadow.enabledOnSeries.indexOf(r))){var O=S.config.chart.dropShadow;C.dropShadow(L,O,r)}x&&(L.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,L)),L.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,L)),L.node.addEventListener("mousedown",this.pathMouseDown.bind(this,L))),L.attr({pathTo:o,pathFrom:i});var I={el:L,j:n,realIndex:r,pathFrom:i,pathTo:o,fill:u,strokeWidth:l,delay:d};return!E||S.globals.resized||S.globals.dataChanged?!S.globals.resized&&S.globals.dataChanged||A.showDelayedElements():A.animatePathsGradually(a(a({},I),{},{speed:h})),S.globals.dataChanged&&P&&T&&A.animatePathsGradually(a(a({},I),{},{speed:f})),L}},{key:"drawPattern",value:function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"#a8a8a8",i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;return this.w.globals.dom.Paper.pattern(t,n,(function(a){"horizontalLines"===e?a.line(0,0,n,0).stroke({color:r,width:i+1}):"verticalLines"===e?a.line(0,0,0,t).stroke({color:r,width:i+1}):"slantedLines"===e?a.line(0,0,t,n).stroke({color:r,width:i}):"squares"===e?a.rect(t,n).fill("none").stroke({color:r,width:i}):"circles"===e&&a.circle(t).fill("none").stroke({color:r,width:i})}))}},{key:"drawGradient",value:function(e,t,n,r,i){var a,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,s=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,l=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,c=arguments.length>8&&void 0!==arguments[8]?arguments[8]:0,u=this.w;t.length<9&&0===t.indexOf("#")&&(t=y.hexToRgba(t,r)),n.length<9&&0===n.indexOf("#")&&(n=y.hexToRgba(n,i));var d=0,h=1,f=1,p=null;null!==s&&(d=void 0!==s[0]?s[0]/100:0,h=void 0!==s[1]?s[1]/100:1,f=void 0!==s[2]?s[2]/100:1,p=void 0!==s[3]?s[3]/100:null);var g=!("donut"!==u.config.chart.type&&"pie"!==u.config.chart.type&&"polarArea"!==u.config.chart.type&&"bubble"!==u.config.chart.type);if(a=null===l||0===l.length?u.globals.dom.Paper.gradient(g?"radial":"linear",(function(e){e.at(d,t,r),e.at(h,n,i),e.at(f,n,i),null!==p&&e.at(p,t,r)})):u.globals.dom.Paper.gradient(g?"radial":"linear",(function(e){(Array.isArray(l[c])?l[c]:l).forEach((function(t){e.at(t.offset/100,t.color,t.opacity)}))})),g){var m=u.globals.gridWidth/2,v=u.globals.gridHeight/2;"bubble"!==u.config.chart.type?a.attr({gradientUnits:"userSpaceOnUse",cx:m,cy:v,r:o}):a.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else"vertical"===e?a.from(0,0).to(0,1):"diagonal"===e?a.from(0,0).to(1,1):"horizontal"===e?a.from(0,1).to(1,1):"diagonal2"===e&&a.from(1,0).to(0,1);return a}},{key:"getTextBasedOnMaxWidth",value:function(e){var t=e.text,n=e.maxWidth,r=e.fontSize,i=e.fontFamily,a=this.getTextRects(t,r,i),o=a.width/t.length,s=Math.floor(n/o);return n-1){var s=n.globals.selectedDataPoints[i].indexOf(a);n.globals.selectedDataPoints[i].splice(s,1)}}else{if(!n.config.states.active.allowMultipleDataPointsSelection&&n.globals.selectedDataPoints.length>0){n.globals.selectedDataPoints=[];var l=n.globals.dom.Paper.select(".apexcharts-series path").members,c=n.globals.dom.Paper.select(".apexcharts-series circle, .apexcharts-series rect").members,u=function(e){Array.prototype.forEach.call(e,(function(e){e.node.setAttribute("selected","false"),r.getDefaultFilter(e,i)}))};u(l),u(c)}e.node.setAttribute("selected","true"),o="true",void 0===n.globals.selectedDataPoints[i]&&(n.globals.selectedDataPoints[i]=[]),n.globals.selectedDataPoints[i].push(a)}if("true"===o){var d=n.config.states.active.filter;if("none"!==d)r.applyFilter(e,i,d.type,d.value);else if("none"!==n.config.states.hover.filter&&!n.globals.isTouchDevice){var h=n.config.states.hover.filter;r.applyFilter(e,i,h.type,h.value)}}else"none"!==n.config.states.active.filter.type&&("none"===n.config.states.hover.filter.type||n.globals.isTouchDevice?r.getDefaultFilter(e,i):(h=n.config.states.hover.filter,r.applyFilter(e,i,h.type,h.value)));"function"==typeof n.config.chart.events.dataPointSelection&&n.config.chart.events.dataPointSelection(t,this.ctx,{selectedDataPoints:n.globals.selectedDataPoints,seriesIndex:i,dataPointIndex:a,w:n}),t&&this.ctx.events.fireEvent("dataPointSelection",[t,this.ctx,{selectedDataPoints:n.globals.selectedDataPoints,seriesIndex:i,dataPointIndex:a,w:n}])}},{key:"rotateAroundCenter",value:function(e){var t={};return e&&"function"==typeof e.getBBox&&(t=e.getBBox()),{x:t.x+t.width/2,y:t.y+t.height/2}}},{key:"getTextRects",value:function(e,t,n,r){var i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=this.w,o=this.drawText({x:-200,y:-200,text:e,textAnchor:"start",fontSize:t,fontFamily:n,foreColor:"#fff",opacity:0});r&&o.attr("transform",r),a.globals.dom.Paper.add(o);var s=o.bbox();return i||(s=o.node.getBoundingClientRect()),o.remove(),{width:s.width,height:s.height}}},{key:"placeTextWithEllipsis",value:function(e,t,n){if("function"==typeof e.getComputedTextLength&&(e.textContent=t,t.length>0&&e.getComputedTextLength()>=n/1.1)){for(var r=t.length-3;r>0;r-=3)if(e.getSubStringLength(0,r)<=n/1.1)return void(e.textContent=t.substring(0,r)+"...");e.textContent="."}}}],[{key:"setAttrs",value:function(e,t){for(var n in t)t.hasOwnProperty(n)&&e.setAttribute(n,t[n])}}]),e}(),C=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"getStackedSeriesTotals",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=this.w,n=[];if(0===t.globals.series.length)return n;for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:null;return null===e?this.w.config.series.reduce((function(e,t){return e+t}),0):this.w.globals.series[e].reduce((function(e,t){return e+t}),0)}},{key:"getStackedSeriesTotalsByGroups",value:function(){var e=this,t=this.w,n=[];return t.globals.seriesGroups.forEach((function(r){var i=[];t.config.series.forEach((function(e,t){r.indexOf(e.name)>-1&&i.push(t)}));var a=t.globals.series.map((function(e,t){return-1===i.indexOf(t)?t:-1})).filter((function(e){return-1!==e}));n.push(e.getStackedSeriesTotals(a))})),n}},{key:"isSeriesNull",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return 0===(null===e?this.w.config.series.filter((function(e){return null!==e})):this.w.config.series[e].data.filter((function(e){return null!==e}))).length}},{key:"seriesHaveSameValues",value:function(e){return this.w.globals.series[e].every((function(e,t,n){return e===n[0]}))}},{key:"getCategoryLabels",value:function(e){var t=this.w,n=e.slice();return t.config.xaxis.convertedCatToNumeric&&(n=e.map((function(e,n){return t.config.xaxis.labels.formatter(e-t.globals.minX+1)}))),n}},{key:"getLargestSeries",value:function(){var e=this.w;e.globals.maxValsInArrayIndex=e.globals.series.map((function(e){return e.length})).indexOf(Math.max.apply(Math,e.globals.series.map((function(e){return e.length}))))}},{key:"getLargestMarkerSize",value:function(){var e=this.w,t=0;return e.globals.markers.size.forEach((function(e){t=Math.max(t,e)})),e.config.markers.discrete&&e.config.markers.discrete.length&&e.config.markers.discrete.forEach((function(e){t=Math.max(t,e.size)})),t>0&&(t+=e.config.markers.hover.sizeOffset+1),e.globals.markers.largestSize=t,t}},{key:"getSeriesTotals",value:function(){var e=this.w;e.globals.seriesTotals=e.globals.series.map((function(e,t){var n=0;if(Array.isArray(e))for(var r=0;re&&n.globals.seriesX[i][o]0&&(t=!0),{comboBarCount:n,comboCharts:t}}},{key:"extendArrayProps",value:function(e,t,n){return t.yaxis&&(t=e.extendYAxis(t,n)),t.annotations&&(t.annotations.yaxis&&(t=e.extendYAxisAnnotations(t)),t.annotations.xaxis&&(t=e.extendXAxisAnnotations(t)),t.annotations.points&&(t=e.extendPointAnnotations(t))),t}}]),e}(),A=function(){function e(t){s(this,e),this.w=t.w,this.annoCtx=t}return c(e,[{key:"setOrientations",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=this.w;if("vertical"===e.label.orientation){var r=null!==t?t:0,i=n.globals.dom.baseEl.querySelector(".apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='".concat(r,"']"));if(null!==i){var a=i.getBoundingClientRect();i.setAttribute("x",parseFloat(i.getAttribute("x"))-a.height+4),"top"===e.label.position?i.setAttribute("y",parseFloat(i.getAttribute("y"))+a.width):i.setAttribute("y",parseFloat(i.getAttribute("y"))-a.width);var o=this.annoCtx.graphics.rotateAroundCenter(i),s=o.x,l=o.y;i.setAttribute("transform","rotate(-90 ".concat(s," ").concat(l,")"))}}}},{key:"addBackgroundToAnno",value:function(e,t){var n=this.w;if(!e||void 0===t.label.text||void 0!==t.label.text&&!String(t.label.text).trim())return null;var r=n.globals.dom.baseEl.querySelector(".apexcharts-grid").getBoundingClientRect(),i=e.getBoundingClientRect(),a=t.label.style.padding.left,o=t.label.style.padding.right,s=t.label.style.padding.top,l=t.label.style.padding.bottom;"vertical"===t.label.orientation&&(s=t.label.style.padding.left,l=t.label.style.padding.right,a=t.label.style.padding.top,o=t.label.style.padding.bottom);var c=i.left-r.left-a,u=i.top-r.top-s,d=this.annoCtx.graphics.drawRect(c-n.globals.barPadForNumericAxis,u,i.width+a+o,i.height+s+l,t.label.borderRadius,t.label.style.background,1,t.label.borderWidth,t.label.borderColor,0);return t.id&&d.node.classList.add(t.id),d}},{key:"annotationsBackground",value:function(){var e=this,t=this.w,n=function(n,r,i){var a=t.globals.dom.baseEl.querySelector(".apexcharts-".concat(i,"-annotations .apexcharts-").concat(i,"-annotation-label[rel='").concat(r,"']"));if(a){var o=a.parentNode,s=e.addBackgroundToAnno(a,n);s&&(o.insertBefore(s.node,a),n.label.mouseEnter&&s.node.addEventListener("mouseenter",n.label.mouseEnter.bind(e,n)),n.label.mouseLeave&&s.node.addEventListener("mouseleave",n.label.mouseLeave.bind(e,n)),n.label.click&&s.node.addEventListener("click",n.label.click.bind(e,n)))}};t.config.annotations.xaxis.map((function(e,t){n(e,t,"xaxis")})),t.config.annotations.yaxis.map((function(e,t){n(e,t,"yaxis")})),t.config.annotations.points.map((function(e,t){n(e,t,"point")}))}},{key:"getY1Y2",value:function(e,t){var n,r="y1"===e?t.y:t.y2,i=this.w;if(this.annoCtx.invertAxis){var a=i.globals.labels.indexOf(r);i.config.xaxis.convertedCatToNumeric&&(a=i.globals.categoryLabels.indexOf(r));var o=i.globals.dom.baseEl.querySelector(".apexcharts-yaxis-texts-g text:nth-child("+(a+1)+")");o&&(n=parseFloat(o.getAttribute("y"))),void 0!==t.seriesIndex&&i.globals.barHeight&&(n=n-i.globals.barHeight/2*(i.globals.series.length-1)+i.globals.barHeight*t.seriesIndex)}else{var s;s=i.config.yaxis[t.yAxisIndex].logarithmic?(r=new C(this.annoCtx.ctx).getLogVal(r,t.yAxisIndex))/i.globals.yLogRatio[t.yAxisIndex]:(r-i.globals.minYArr[t.yAxisIndex])/(i.globals.yRange[t.yAxisIndex]/i.globals.gridHeight),n=i.globals.gridHeight-s,!t.marker||void 0!==t.y&&null!==t.y||(n=0),i.config.yaxis[t.yAxisIndex]&&i.config.yaxis[t.yAxisIndex].reversed&&(n=s)}return"string"==typeof r&&r.indexOf("px")>-1&&(n=parseFloat(r)),n}},{key:"getX1X2",value:function(e,t){var n=this.w,r=this.annoCtx.invertAxis?n.globals.minY:n.globals.minX,i=this.annoCtx.invertAxis?n.globals.maxY:n.globals.maxX,a=this.annoCtx.invertAxis?n.globals.yRange[0]:n.globals.xRange,o=(t.x-r)/(a/n.globals.gridWidth);this.annoCtx.inversedReversedAxis&&(o=(i-t.x)/(a/n.globals.gridWidth)),"category"!==n.config.xaxis.type&&!n.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||n.globals.dataFormatXNumeric||(o=this.getStringX(t.x));var s=(t.x2-r)/(a/n.globals.gridWidth);return this.annoCtx.inversedReversedAxis&&(s=(i-t.x2)/(a/n.globals.gridWidth)),"category"!==n.config.xaxis.type&&!n.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||n.globals.dataFormatXNumeric||(s=this.getStringX(t.x2)),void 0!==t.x&&null!==t.x||!t.marker||(o=n.globals.gridWidth),"x1"===e&&"string"==typeof t.x&&t.x.indexOf("px")>-1&&(o=parseFloat(t.x)),"x2"===e&&"string"==typeof t.x2&&t.x2.indexOf("px")>-1&&(s=parseFloat(t.x2)),void 0!==t.seriesIndex&&n.globals.barWidth&&!this.annoCtx.invertAxis&&(o=o-n.globals.barWidth/2*(n.globals.series.length-1)+n.globals.barWidth*t.seriesIndex),"x1"===e?o:s}},{key:"getStringX",value:function(e){var t=this.w,n=e;t.config.xaxis.convertedCatToNumeric&&t.globals.categoryLabels.length&&(e=t.globals.categoryLabels.indexOf(e)+1);var r=t.globals.labels.indexOf(e),i=t.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g text:nth-child("+(r+1)+")");return i&&(n=parseFloat(i.getAttribute("x"))),n}}]),e}(),E=function(){function e(t){s(this,e),this.w=t.w,this.annoCtx=t,this.invertAxis=this.annoCtx.invertAxis,this.helpers=new A(this.annoCtx)}return c(e,[{key:"addXaxisAnnotation",value:function(e,t,n){var r,i=this.w,a=this.helpers.getX1X2("x1",e),o=e.label.text,s=e.strokeDashArray;if(y.isNumber(a)){if(null===e.x2||void 0===e.x2){var l=this.annoCtx.graphics.drawLine(a+e.offsetX,0+e.offsetY,a+e.offsetX,i.globals.gridHeight+e.offsetY,e.borderColor,s,e.borderWidth);t.appendChild(l.node),e.id&&l.node.classList.add(e.id)}else{if((r=this.helpers.getX1X2("x2",e))o){var c=o;o=r,r=c}var u=this.annoCtx.graphics.drawRect(0+e.offsetX,r+e.offsetY,this._getYAxisAnnotationWidth(e),o-r,0,e.fillColor,e.opacity,1,e.borderColor,a);u.node.classList.add("apexcharts-annotation-rect"),u.attr("clip-path","url(#gridRectMask".concat(i.globals.cuid,")")),t.appendChild(u.node),e.id&&u.node.classList.add(e.id)}var d="right"===e.label.position?i.globals.gridWidth:"center"===e.label.position?i.globals.gridWidth/2:0,h=this.annoCtx.graphics.drawText({x:d+e.label.offsetX,y:(null!=r?r:o)+e.label.offsetY-3,text:s,textAnchor:e.label.textAnchor,fontSize:e.label.style.fontSize,fontFamily:e.label.style.fontFamily,fontWeight:e.label.style.fontWeight,foreColor:e.label.style.color,cssClass:"apexcharts-yaxis-annotation-label ".concat(e.label.style.cssClass," ").concat(e.id?e.id:"")});h.attr({rel:n}),t.appendChild(h.node)}},{key:"_getYAxisAnnotationWidth",value:function(e){var t=this.w;return t.globals.gridWidth,(e.width.indexOf("%")>-1?t.globals.gridWidth*parseInt(e.width,10)/100:parseInt(e.width,10))+e.offsetX}},{key:"drawYAxisAnnotations",value:function(){var e=this,t=this.w,n=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return t.config.annotations.yaxis.map((function(t,r){e.addYaxisAnnotation(t,n.node,r)})),n}}]),e}(),T=function(){function e(t){s(this,e),this.w=t.w,this.annoCtx=t,this.helpers=new A(this.annoCtx)}return c(e,[{key:"addPointAnnotation",value:function(e,t,n){this.w;var r=this.helpers.getX1X2("x1",e),i=this.helpers.getY1Y2("y1",e);if(y.isNumber(r)){var a={pSize:e.marker.size,pointStrokeWidth:e.marker.strokeWidth,pointFillColor:e.marker.fillColor,pointStrokeColor:e.marker.strokeColor,shape:e.marker.shape,pRadius:e.marker.radius,class:"apexcharts-point-annotation-marker ".concat(e.marker.cssClass," ").concat(e.id?e.id:"")},o=this.annoCtx.graphics.drawMarker(r+e.marker.offsetX,i+e.marker.offsetY,a);t.appendChild(o.node);var s=e.label.text?e.label.text:"",l=this.annoCtx.graphics.drawText({x:r+e.label.offsetX,y:i+e.label.offsetY-e.marker.size-parseFloat(e.label.style.fontSize)/1.6,text:s,textAnchor:e.label.textAnchor,fontSize:e.label.style.fontSize,fontFamily:e.label.style.fontFamily,fontWeight:e.label.style.fontWeight,foreColor:e.label.style.color,cssClass:"apexcharts-point-annotation-label ".concat(e.label.style.cssClass," ").concat(e.id?e.id:"")});if(l.attr({rel:n}),t.appendChild(l.node),e.customSVG.SVG){var c=this.annoCtx.graphics.group({class:"apexcharts-point-annotations-custom-svg "+e.customSVG.cssClass});c.attr({transform:"translate(".concat(r+e.customSVG.offsetX,", ").concat(i+e.customSVG.offsetY,")")}),c.node.innerHTML=e.customSVG.SVG,t.appendChild(c.node)}if(e.image.path){var u=e.image.width?e.image.width:20,d=e.image.height?e.image.height:20;o=this.annoCtx.addImage({x:r+e.image.offsetX-u/2,y:i+e.image.offsetY-d/2,width:u,height:d,path:e.image.path,appendTo:".apexcharts-point-annotations"})}e.mouseEnter&&o.node.addEventListener("mouseenter",e.mouseEnter.bind(this,e)),e.mouseLeave&&o.node.addEventListener("mouseleave",e.mouseLeave.bind(this,e)),e.click&&o.node.addEventListener("click",e.click.bind(this,e))}}},{key:"drawPointAnnotations",value:function(){var e=this,t=this.w,n=this.annoCtx.graphics.group({class:"apexcharts-point-annotations"});return t.config.annotations.points.map((function(t,r){e.addPointAnnotation(t,n.node,r)})),n}}]),e}(),M={name:"en",options:{months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],toolbar:{exportToSVG:"Download SVG",exportToPNG:"Download PNG",exportToCSV:"Download CSV",menu:"Menu",selection:"Selection",selectionZoom:"Selection Zoom",zoomIn:"Zoom In",zoomOut:"Zoom Out",pan:"Panning",reset:"Reset Zoom"}}},_=function(){function e(){s(this,e),this.yAxis={show:!0,showAlways:!1,showForNullSeries:!0,seriesName:void 0,opposite:!1,reversed:!1,logarithmic:!1,logBase:10,tickAmount:void 0,stepSize:void 0,forceNiceScale:!1,max:void 0,min:void 0,floating:!1,decimalsInFloat:void 0,labels:{show:!0,minWidth:0,maxWidth:160,offsetX:0,offsetY:0,align:void 0,rotate:0,padding:20,style:{colors:[],fontSize:"11px",fontWeight:400,fontFamily:void 0,cssClass:""},formatter:void 0},axisBorder:{show:!1,color:"#e0e0e0",width:1,offsetX:0,offsetY:0},axisTicks:{show:!1,color:"#e0e0e0",width:6,offsetX:0,offsetY:0},title:{text:void 0,rotate:-90,offsetY:0,offsetX:0,style:{color:void 0,fontSize:"11px",fontWeight:900,fontFamily:void 0,cssClass:""}},tooltip:{enabled:!1,offsetX:0},crosshairs:{show:!0,position:"front",stroke:{color:"#b6b6b6",width:1,dashArray:0}}},this.pointAnnotation={id:void 0,x:0,y:null,yAxisIndex:0,seriesIndex:void 0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,marker:{size:4,fillColor:"#fff",strokeWidth:2,strokeColor:"#333",shape:"circle",offsetX:0,offsetY:0,radius:2,cssClass:""},label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}},customSVG:{SVG:void 0,cssClass:void 0,offsetX:0,offsetY:0},image:{path:void 0,width:20,height:20,offsetX:0,offsetY:0}},this.yAxisAnnotation={id:void 0,y:0,y2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,width:"100%",yAxisIndex:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"end",position:"right",offsetX:0,offsetY:-3,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.xAxisAnnotation={id:void 0,x:0,x2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",orientation:"vertical",position:"top",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.text={x:0,y:0,text:"",textAnchor:"start",foreColor:void 0,fontSize:"13px",fontFamily:void 0,fontWeight:400,appendTo:".apexcharts-annotations",backgroundColor:"transparent",borderColor:"#c2c2c2",borderRadius:0,borderWidth:0,paddingLeft:4,paddingRight:4,paddingTop:2,paddingBottom:2}}return c(e,[{key:"init",value:function(){return{annotations:{yaxis:[this.yAxisAnnotation],xaxis:[this.xAxisAnnotation],points:[this.pointAnnotation],texts:[],images:[],shapes:[]},chart:{animations:{enabled:!0,easing:"easeinout",speed:800,animateGradually:{delay:150,enabled:!0},dynamicAnimation:{enabled:!0,speed:350}},background:"transparent",locales:[M],defaultLocale:"en",dropShadow:{enabled:!1,enabledOnSeries:void 0,top:2,left:2,blur:4,color:"#000",opacity:.35},events:{animationEnd:void 0,beforeMount:void 0,mounted:void 0,updated:void 0,click:void 0,mouseMove:void 0,mouseLeave:void 0,xAxisLabelClick:void 0,legendClick:void 0,markerClick:void 0,selection:void 0,dataPointSelection:void 0,dataPointMouseEnter:void 0,dataPointMouseLeave:void 0,beforeZoom:void 0,beforeResetZoom:void 0,zoomed:void 0,scrolled:void 0,brushScrolled:void 0},foreColor:"#373d3f",fontFamily:"Helvetica, Arial, sans-serif",height:"auto",parentHeightOffset:15,redrawOnParentResize:!0,redrawOnWindowResize:!0,id:void 0,group:void 0,nonce:void 0,offsetX:0,offsetY:0,selection:{enabled:!1,type:"x",fill:{color:"#24292e",opacity:.1},stroke:{width:1,color:"#24292e",opacity:.4,dashArray:3},xaxis:{min:void 0,max:void 0},yaxis:{min:void 0,max:void 0}},sparkline:{enabled:!1},brush:{enabled:!1,autoScaleYaxis:!0,target:void 0,targets:void 0},stacked:!1,stackOnlyBar:!0,stackType:"normal",toolbar:{show:!0,offsetX:0,offsetY:0,tools:{download:!0,selection:!0,zoom:!0,zoomin:!0,zoomout:!0,pan:!0,reset:!0,customIcons:[]},export:{csv:{filename:void 0,columnDelimiter:",",headerCategory:"category",headerValue:"value",dateFormatter:function(e){return new Date(e).toDateString()}},png:{filename:void 0},svg:{filename:void 0}},autoSelected:"zoom"},type:"line",width:"100%",zoom:{enabled:!0,type:"x",autoScaleYaxis:!1,zoomedArea:{fill:{color:"#90CAF9",opacity:.4},stroke:{color:"#0D47A1",opacity:.4,width:1}}}},plotOptions:{area:{fillTo:"origin"},bar:{horizontal:!1,columnWidth:"70%",barHeight:"70%",distributed:!1,borderRadius:0,borderRadiusApplication:"around",borderRadiusWhenStacked:"last",rangeBarOverlap:!0,rangeBarGroupRows:!1,hideZeroBarsWhenGrouped:!1,isDumbbell:!1,dumbbellColors:void 0,isFunnel:!1,isFunnel3d:!0,colors:{ranges:[],backgroundBarColors:[],backgroundBarOpacity:1,backgroundBarRadius:0},dataLabels:{position:"top",maxItems:100,hideOverflowingLabels:!0,orientation:"horizontal",total:{enabled:!1,formatter:void 0,offsetX:0,offsetY:0,style:{color:"#373d3f",fontSize:"12px",fontFamily:void 0,fontWeight:600}}}},bubble:{zScaling:!0,minBubbleRadius:void 0,maxBubbleRadius:void 0},candlestick:{colors:{upward:"#00B746",downward:"#EF403C"},wick:{useFillColor:!0}},boxPlot:{colors:{upper:"#00E396",lower:"#008FFB"}},heatmap:{radius:2,enableShades:!0,shadeIntensity:.5,reverseNegativeShade:!1,distributed:!1,useFillColorAsStroke:!1,colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},treemap:{enableShades:!0,shadeIntensity:.5,distributed:!1,reverseNegativeShade:!1,useFillColorAsStroke:!1,dataLabels:{format:"scale"},colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},radialBar:{inverseOrder:!1,startAngle:0,endAngle:360,offsetX:0,offsetY:0,hollow:{margin:5,size:"50%",background:"transparent",image:void 0,imageWidth:150,imageHeight:150,imageOffsetX:0,imageOffsetY:0,imageClipped:!0,position:"front",dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},track:{show:!0,startAngle:void 0,endAngle:void 0,background:"#f2f2f2",strokeWidth:"97%",opacity:1,margin:5,dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},dataLabels:{show:!0,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:0,formatter:function(e){return e}},value:{show:!0,fontSize:"14px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:16,formatter:function(e){return e+"%"}},total:{show:!1,label:"Total",fontSize:"16px",fontWeight:600,fontFamily:void 0,color:void 0,formatter:function(e){return e.globals.seriesTotals.reduce((function(e,t){return e+t}),0)/e.globals.series.length+"%"}}},barLabels:{enabled:!1,margin:5,useSeriesColors:!0,fontFamily:void 0,fontWeight:600,fontSize:"16px",formatter:function(e){return e},onClick:void 0}},pie:{customScale:1,offsetX:0,offsetY:0,startAngle:0,endAngle:360,expandOnClick:!0,dataLabels:{offset:0,minAngleToShowLabel:10},donut:{size:"65%",background:"transparent",labels:{show:!1,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:-10,formatter:function(e){return e}},value:{show:!0,fontSize:"20px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:10,formatter:function(e){return e}},total:{show:!1,showAlways:!1,label:"Total",fontSize:"16px",fontWeight:400,fontFamily:void 0,color:void 0,formatter:function(e){return e.globals.seriesTotals.reduce((function(e,t){return e+t}),0)}}}}},polarArea:{rings:{strokeWidth:1,strokeColor:"#e8e8e8"},spokes:{strokeWidth:1,connectorColors:"#e8e8e8"}},radar:{size:void 0,offsetX:0,offsetY:0,polygons:{strokeWidth:1,strokeColors:"#e8e8e8",connectorColors:"#e8e8e8",fill:{colors:void 0}}}},colors:void 0,dataLabels:{enabled:!0,enabledOnSeries:void 0,formatter:function(e){return null!==e?e:""},textAnchor:"middle",distributed:!1,offsetX:0,offsetY:0,style:{fontSize:"12px",fontFamily:void 0,fontWeight:600,colors:void 0},background:{enabled:!0,foreColor:"#fff",borderRadius:2,padding:4,opacity:.9,borderWidth:1,borderColor:"#fff",dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]},image:{src:[],width:void 0,height:void 0},pattern:{style:"squares",width:6,height:6,strokeWidth:2}},forecastDataPoints:{count:0,fillOpacity:.5,strokeWidth:void 0,dashArray:4},grid:{show:!0,borderColor:"#e0e0e0",strokeDashArray:0,position:"back",xaxis:{lines:{show:!1}},yaxis:{lines:{show:!0}},row:{colors:void 0,opacity:.5},column:{colors:void 0,opacity:.5},padding:{top:0,right:10,bottom:0,left:12}},labels:[],legend:{show:!0,showForSingleSeries:!1,showForNullSeries:!0,showForZeroSeries:!0,floating:!1,position:"bottom",horizontalAlign:"center",inverseOrder:!1,fontSize:"12px",fontFamily:void 0,fontWeight:400,width:void 0,height:void 0,formatter:void 0,tooltipHoverFormatter:void 0,offsetX:-20,offsetY:4,customLegendItems:[],labels:{colors:void 0,useSeriesColors:!1},markers:{width:12,height:12,strokeWidth:0,fillColors:void 0,strokeColor:"#fff",radius:12,customHTML:void 0,offsetX:0,offsetY:0,onClick:void 0},itemMargin:{horizontal:5,vertical:2},onItemClick:{toggleDataSeries:!0},onItemHover:{highlightDataSeries:!0}},markers:{discrete:[],size:0,colors:void 0,strokeColors:"#fff",strokeWidth:2,strokeOpacity:.9,strokeDashArray:0,fillOpacity:1,shape:"circle",width:8,height:8,radius:2,offsetX:0,offsetY:0,onClick:void 0,onDblClick:void 0,showNullDataPoints:!0,hover:{size:void 0,sizeOffset:3}},noData:{text:void 0,align:"center",verticalAlign:"middle",offsetX:0,offsetY:0,style:{color:void 0,fontSize:"14px",fontFamily:void 0}},responsive:[],series:void 0,states:{normal:{filter:{type:"none",value:0}},hover:{filter:{type:"lighten",value:.1}},active:{allowMultipleDataPointsSelection:!1,filter:{type:"darken",value:.5}}},title:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:0,floating:!1,style:{fontSize:"14px",fontWeight:900,fontFamily:void 0,color:void 0}},subtitle:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:30,floating:!1,style:{fontSize:"12px",fontWeight:400,fontFamily:void 0,color:void 0}},stroke:{show:!0,curve:"smooth",lineCap:"butt",width:2,colors:void 0,dashArray:0,fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]}}},tooltip:{enabled:!0,enabledOnSeries:void 0,shared:!0,hideEmptySeries:!0,followCursor:!1,intersect:!1,inverseOrder:!1,custom:void 0,fillSeriesColor:!1,theme:"light",cssClass:"",style:{fontSize:"12px",fontFamily:void 0},onDatasetHover:{highlightDataSeries:!1},x:{show:!0,format:"dd MMM",formatter:void 0},y:{formatter:void 0,title:{formatter:function(e){return e?e+": ":""}}},z:{formatter:void 0,title:"Size: "},marker:{show:!0,fillColors:void 0},items:{display:"flex"},fixed:{enabled:!1,position:"topRight",offsetX:0,offsetY:0}},xaxis:{type:"category",categories:[],convertedCatToNumeric:!1,offsetX:0,offsetY:0,overwriteCategories:void 0,labels:{show:!0,rotate:-45,rotateAlways:!1,hideOverlappingLabels:!0,trim:!1,minHeight:void 0,maxHeight:120,showDuplicates:!0,style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""},offsetX:0,offsetY:0,format:void 0,formatter:void 0,datetimeUTC:!0,datetimeFormatter:{year:"yyyy",month:"MMM 'yy",day:"dd MMM",hour:"HH:mm",minute:"HH:mm:ss",second:"HH:mm:ss"}},group:{groups:[],style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""}},axisBorder:{show:!0,color:"#e0e0e0",width:"100%",height:1,offsetX:0,offsetY:0},axisTicks:{show:!0,color:"#e0e0e0",height:6,offsetX:0,offsetY:0},stepSize:void 0,tickAmount:void 0,tickPlacement:"on",min:void 0,max:void 0,range:void 0,floating:!1,decimalsInFloat:void 0,position:"bottom",title:{text:void 0,offsetX:0,offsetY:0,style:{color:void 0,fontSize:"12px",fontWeight:900,fontFamily:void 0,cssClass:""}},crosshairs:{show:!0,width:1,position:"back",opacity:.9,stroke:{color:"#b6b6b6",width:1,dashArray:3},fill:{type:"solid",color:"#B1B9C4",gradient:{colorFrom:"#D8E3F0",colorTo:"#BED1E6",stops:[0,100],opacityFrom:.4,opacityTo:.5}},dropShadow:{enabled:!1,left:0,top:0,blur:1,opacity:.4}},tooltip:{enabled:!0,offsetY:0,formatter:void 0,style:{fontSize:"12px",fontFamily:void 0}}},yaxis:this.yAxis,theme:{mode:"light",palette:"palette1",monochrome:{enabled:!1,color:"#008FFB",shadeTo:"light",shadeIntensity:.65}}}}}]),e}(),L=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.graphics=new S(this.ctx),this.w.globals.isBarHorizontal&&(this.invertAxis=!0),this.helpers=new A(this),this.xAxisAnnotations=new E(this),this.yAxisAnnotations=new P(this),this.pointsAnnotations=new T(this),this.w.globals.isBarHorizontal&&this.w.config.yaxis[0].reversed&&(this.inversedReversedAxis=!0),this.xDivision=this.w.globals.gridWidth/this.w.globals.dataPoints}return c(e,[{key:"drawAxesAnnotations",value:function(){var e=this.w;if(e.globals.axisCharts){for(var t=this.yAxisAnnotations.drawYAxisAnnotations(),n=this.xAxisAnnotations.drawXAxisAnnotations(),r=this.pointsAnnotations.drawPointAnnotations(),i=e.config.chart.animations.enabled,a=[t,n,r],o=[n.node,t.node,r.node],s=0;s<3;s++)e.globals.dom.elGraphical.add(a[s]),!i||e.globals.resized||e.globals.dataChanged||"scatter"!==e.config.chart.type&&"bubble"!==e.config.chart.type&&e.globals.dataPoints>1&&o[s].classList.add("apexcharts-element-hidden"),e.globals.delayedElements.push({el:o[s],index:0});this.helpers.annotationsBackground()}}},{key:"drawImageAnnos",value:function(){var e=this;this.w.config.annotations.images.map((function(t,n){e.addImage(t,n)}))}},{key:"drawTextAnnos",value:function(){var e=this;this.w.config.annotations.texts.map((function(t,n){e.addText(t,n)}))}},{key:"addXaxisAnnotation",value:function(e,t,n){this.xAxisAnnotations.addXaxisAnnotation(e,t,n)}},{key:"addYaxisAnnotation",value:function(e,t,n){this.yAxisAnnotations.addYaxisAnnotation(e,t,n)}},{key:"addPointAnnotation",value:function(e,t,n){this.pointsAnnotations.addPointAnnotation(e,t,n)}},{key:"addText",value:function(e,t){var n=e.x,r=e.y,i=e.text,a=e.textAnchor,o=e.foreColor,s=e.fontSize,l=e.fontFamily,c=e.fontWeight,u=e.cssClass,d=e.backgroundColor,h=e.borderWidth,f=e.strokeDashArray,p=e.borderRadius,g=e.borderColor,m=e.appendTo,v=void 0===m?".apexcharts-svg":m,x=e.paddingLeft,b=void 0===x?4:x,y=e.paddingRight,w=void 0===y?4:y,k=e.paddingBottom,S=void 0===k?2:k,C=e.paddingTop,A=void 0===C?2:C,E=this.w,P=this.graphics.drawText({x:n,y:r,text:i,textAnchor:a||"start",fontSize:s||"12px",fontWeight:c||"regular",fontFamily:l||E.config.chart.fontFamily,foreColor:o||E.config.chart.foreColor,cssClass:u}),T=E.globals.dom.baseEl.querySelector(v);T&&T.appendChild(P.node);var M=P.bbox();if(i){var _=this.graphics.drawRect(M.x-b,M.y-A,M.width+b+w,M.height+S+A,p,d||"transparent",1,h,g,f);T.insertBefore(_.node,P.node)}}},{key:"addImage",value:function(e,t){var n=this.w,r=e.path,i=e.x,a=void 0===i?0:i,o=e.y,s=void 0===o?0:o,l=e.width,c=void 0===l?20:l,u=e.height,d=void 0===u?20:u,h=e.appendTo,f=void 0===h?".apexcharts-svg":h,p=n.globals.dom.Paper.image(r);p.size(c,d).move(a,s);var g=n.globals.dom.baseEl.querySelector(f);return g&&g.appendChild(p.node),p}},{key:"addXaxisAnnotationExternal",value:function(e,t,n){return this.addAnnotationExternal({params:e,pushToMemory:t,context:n,type:"xaxis",contextMethod:n.addXaxisAnnotation}),n}},{key:"addYaxisAnnotationExternal",value:function(e,t,n){return this.addAnnotationExternal({params:e,pushToMemory:t,context:n,type:"yaxis",contextMethod:n.addYaxisAnnotation}),n}},{key:"addPointAnnotationExternal",value:function(e,t,n){return void 0===this.invertAxis&&(this.invertAxis=n.w.globals.isBarHorizontal),this.addAnnotationExternal({params:e,pushToMemory:t,context:n,type:"point",contextMethod:n.addPointAnnotation}),n}},{key:"addAnnotationExternal",value:function(e){var t=e.params,n=e.pushToMemory,r=e.context,i=e.type,a=e.contextMethod,o=r,s=o.w,l=s.globals.dom.baseEl.querySelector(".apexcharts-".concat(i,"-annotations")),c=l.childNodes.length+1,u=new _,d=Object.assign({},"xaxis"===i?u.xAxisAnnotation:"yaxis"===i?u.yAxisAnnotation:u.pointAnnotation),h=y.extend(d,t);switch(i){case"xaxis":this.addXaxisAnnotation(h,l,c);break;case"yaxis":this.addYaxisAnnotation(h,l,c);break;case"point":this.addPointAnnotation(h,l,c)}var f=s.globals.dom.baseEl.querySelector(".apexcharts-".concat(i,"-annotations .apexcharts-").concat(i,"-annotation-label[rel='").concat(c,"']")),p=this.helpers.addBackgroundToAnno(f,h);return p&&l.insertBefore(p.node,f),n&&s.globals.memory.methodsToExec.push({context:o,id:h.id?h.id:y.randomId(),method:a,label:"addAnnotation",params:t}),r}},{key:"clearAnnotations",value:function(e){var t=e.w,n=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-annotations, .apexcharts-xaxis-annotations, .apexcharts-point-annotations");t.globals.memory.methodsToExec.map((function(e,n){"addText"!==e.label&&"addAnnotation"!==e.label||t.globals.memory.methodsToExec.splice(n,1)})),n=y.listToArray(n),Array.prototype.forEach.call(n,(function(e){for(;e.firstChild;)e.removeChild(e.firstChild)}))}},{key:"removeAnnotation",value:function(e,t){var n=e.w,r=n.globals.dom.baseEl.querySelectorAll(".".concat(t));r&&(n.globals.memory.methodsToExec.map((function(e,r){e.id===t&&n.globals.memory.methodsToExec.splice(r,1)})),Array.prototype.forEach.call(r,(function(e){e.parentElement.removeChild(e)})))}}]),e}(),O=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.months31=[1,3,5,7,8,10,12],this.months30=[2,4,6,9,11],this.daysCntOfYear=[0,31,59,90,120,151,181,212,243,273,304,334]}return c(e,[{key:"isValidDate",value:function(e){return"number"!=typeof e&&!isNaN(this.parseDate(e))}},{key:"getTimeStamp",value:function(e){return Date.parse(e)?this.w.config.xaxis.labels.datetimeUTC?new Date(new Date(e).toISOString().substr(0,25)).getTime():new Date(e).getTime():e}},{key:"getDate",value:function(e){return this.w.config.xaxis.labels.datetimeUTC?new Date(new Date(e).toUTCString()):new Date(e)}},{key:"parseDate",value:function(e){var t=Date.parse(e);if(!isNaN(t))return this.getTimeStamp(e);var n=Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "));return this.getTimeStamp(n)}},{key:"parseDateWithTimezone",value:function(e){return Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "))}},{key:"formatDate",value:function(e,t){var n=this.w.globals.locale,r=this.w.config.xaxis.labels.datetimeUTC,i=["\0"].concat(v(n.months)),a=["\x01"].concat(v(n.shortMonths)),o=["\x02"].concat(v(n.days)),s=["\x03"].concat(v(n.shortDays));function l(e,t){var n=e+"";for(t=t||2;n.length12?h-12:0===h?12:h;t=(t=(t=(t=t.replace(/(^|[^\\])HH+/g,"$1"+l(h))).replace(/(^|[^\\])H/g,"$1"+h)).replace(/(^|[^\\])hh+/g,"$1"+l(f))).replace(/(^|[^\\])h/g,"$1"+f);var p=r?e.getUTCMinutes():e.getMinutes();t=(t=t.replace(/(^|[^\\])mm+/g,"$1"+l(p))).replace(/(^|[^\\])m/g,"$1"+p);var g=r?e.getUTCSeconds():e.getSeconds();t=(t=t.replace(/(^|[^\\])ss+/g,"$1"+l(g))).replace(/(^|[^\\])s/g,"$1"+g);var m=r?e.getUTCMilliseconds():e.getMilliseconds();t=t.replace(/(^|[^\\])fff+/g,"$1"+l(m,3)),m=Math.round(m/10),t=t.replace(/(^|[^\\])ff/g,"$1"+l(m)),m=Math.round(m/10);var x=h<12?"AM":"PM";t=(t=(t=t.replace(/(^|[^\\])f/g,"$1"+m)).replace(/(^|[^\\])TT+/g,"$1"+x)).replace(/(^|[^\\])T/g,"$1"+x.charAt(0));var b=x.toLowerCase();t=(t=t.replace(/(^|[^\\])tt+/g,"$1"+b)).replace(/(^|[^\\])t/g,"$1"+b.charAt(0));var y=-e.getTimezoneOffset(),w=r||!y?"Z":y>0?"+":"-";if(!r){var k=(y=Math.abs(y))%60;w+=l(Math.floor(y/60))+":"+l(k)}t=t.replace(/(^|[^\\])K/g,"$1"+w);var S=(r?e.getUTCDay():e.getDay())+1;return(t=(t=(t=(t=t.replace(new RegExp(o[0],"g"),o[S])).replace(new RegExp(s[0],"g"),s[S])).replace(new RegExp(i[0],"g"),i[u])).replace(new RegExp(a[0],"g"),a[u])).replace(/\\(.)/g,"$1")}},{key:"getTimeUnitsfromTimestamp",value:function(e,t,n){var r=this.w;void 0!==r.config.xaxis.min&&(e=r.config.xaxis.min),void 0!==r.config.xaxis.max&&(t=r.config.xaxis.max);var i=this.getDate(e),a=this.getDate(t),o=this.formatDate(i,"yyyy MM dd HH mm ss fff").split(" "),s=this.formatDate(a,"yyyy MM dd HH mm ss fff").split(" ");return{minMillisecond:parseInt(o[6],10),maxMillisecond:parseInt(s[6],10),minSecond:parseInt(o[5],10),maxSecond:parseInt(s[5],10),minMinute:parseInt(o[4],10),maxMinute:parseInt(s[4],10),minHour:parseInt(o[3],10),maxHour:parseInt(s[3],10),minDate:parseInt(o[2],10),maxDate:parseInt(s[2],10),minMonth:parseInt(o[1],10)-1,maxMonth:parseInt(s[1],10)-1,minYear:parseInt(o[0],10),maxYear:parseInt(s[0],10)}}},{key:"isLeapYear",value:function(e){return e%4==0&&e%100!=0||e%400==0}},{key:"calculcateLastDaysOfMonth",value:function(e,t,n){return this.determineDaysOfMonths(e,t)-n}},{key:"determineDaysOfYear",value:function(e){var t=365;return this.isLeapYear(e)&&(t=366),t}},{key:"determineRemainingDaysOfYear",value:function(e,t,n){var r=this.daysCntOfYear[t]+n;return t>1&&this.isLeapYear()&&r++,r}},{key:"determineDaysOfMonths",value:function(e,t){var n=30;switch(e=y.monthMod(e),!0){case this.months30.indexOf(e)>-1:2===e&&(n=this.isLeapYear(t)?29:28);break;case this.months31.indexOf(e)>-1:default:n=31}return n}}]),e}(),I=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.tooltipKeyFormat="dd MMM"}return c(e,[{key:"xLabelFormat",value:function(e,t,n,r){var i=this.w;if("datetime"===i.config.xaxis.type&&void 0===i.config.xaxis.labels.formatter&&void 0===i.config.tooltip.x.formatter){var a=new O(this.ctx);return a.formatDate(a.getDate(t),i.config.tooltip.x.format)}return e(t,n,r)}},{key:"defaultGeneralFormatter",value:function(e){return Array.isArray(e)?e.map((function(e){return e})):e}},{key:"defaultYFormatter",value:function(e,t,n){var r=this.w;return y.isNumber(e)&&(e=0!==r.globals.yValueDecimal?e.toFixed(void 0!==t.decimalsInFloat?t.decimalsInFloat:r.globals.yValueDecimal):r.globals.maxYArr[n]-r.globals.minYArr[n]<5?e.toFixed(1):e.toFixed(0)),e}},{key:"setLabelFormatters",value:function(){var e=this,t=this.w;return t.globals.xaxisTooltipFormatter=function(t){return e.defaultGeneralFormatter(t)},t.globals.ttKeyFormatter=function(t){return e.defaultGeneralFormatter(t)},t.globals.ttZFormatter=function(e){return e},t.globals.legendFormatter=function(t){return e.defaultGeneralFormatter(t)},void 0!==t.config.xaxis.labels.formatter?t.globals.xLabelFormatter=t.config.xaxis.labels.formatter:t.globals.xLabelFormatter=function(e){if(y.isNumber(e)){if(!t.config.xaxis.convertedCatToNumeric&&"numeric"===t.config.xaxis.type){if(y.isNumber(t.config.xaxis.decimalsInFloat))return e.toFixed(t.config.xaxis.decimalsInFloat);var n=t.globals.maxX-t.globals.minX;return n>0&&n<100?e.toFixed(1):e.toFixed(0)}return t.globals.isBarHorizontal&&t.globals.maxY-t.globals.minYArr<4?e.toFixed(1):e.toFixed(0)}return e},"function"==typeof t.config.tooltip.x.formatter?t.globals.ttKeyFormatter=t.config.tooltip.x.formatter:t.globals.ttKeyFormatter=t.globals.xLabelFormatter,"function"==typeof t.config.xaxis.tooltip.formatter&&(t.globals.xaxisTooltipFormatter=t.config.xaxis.tooltip.formatter),(Array.isArray(t.config.tooltip.y)||void 0!==t.config.tooltip.y.formatter)&&(t.globals.ttVal=t.config.tooltip.y),void 0!==t.config.tooltip.z.formatter&&(t.globals.ttZFormatter=t.config.tooltip.z.formatter),void 0!==t.config.legend.formatter&&(t.globals.legendFormatter=t.config.legend.formatter),t.config.yaxis.forEach((function(n,r){void 0!==n.labels.formatter?t.globals.yLabelFormatters[r]=n.labels.formatter:t.globals.yLabelFormatters[r]=function(i){return t.globals.xyCharts?Array.isArray(i)?i.map((function(t){return e.defaultYFormatter(t,n,r)})):e.defaultYFormatter(i,n,r):i}})),t.globals}},{key:"heatmapLabelFormatters",value:function(){var e=this.w;if("heatmap"===e.config.chart.type){e.globals.yAxisScale[0].result=e.globals.seriesNames.slice();var t=e.globals.seriesNames.reduce((function(e,t){return e.length>t.length?e:t}),0);e.globals.yAxisScale[0].niceMax=t,e.globals.yAxisScale[0].niceMin=t}}}]),e}(),R=function(e){var t,n=e.isTimeline,r=e.ctx,i=e.seriesIndex,a=e.dataPointIndex,o=e.y1,s=e.y2,l=e.w,c=l.globals.seriesRangeStart[i][a],u=l.globals.seriesRangeEnd[i][a],d=l.globals.labels[a],h=l.config.series[i].name?l.config.series[i].name:"",f=l.globals.ttKeyFormatter,p=l.config.tooltip.y.title.formatter,g={w:l,seriesIndex:i,dataPointIndex:a,start:c,end:u};"function"==typeof p&&(h=p(h,g)),null!==(t=l.config.series[i].data[a])&&void 0!==t&&t.x&&(d=l.config.series[i].data[a].x),n||"datetime"===l.config.xaxis.type&&(d=new I(r).xLabelFormat(l.globals.ttKeyFormatter,d,d,{i:void 0,dateFormatter:new O(r).formatDate,w:l})),"function"==typeof f&&(d=f(d,g)),Number.isFinite(o)&&Number.isFinite(s)&&(c=o,u=s);var m="",v="",x=l.globals.colors[i];if(void 0===l.config.tooltip.x.formatter)if("datetime"===l.config.xaxis.type){var b=new O(r);m=b.formatDate(b.getDate(c),l.config.tooltip.x.format),v=b.formatDate(b.getDate(u),l.config.tooltip.x.format)}else m=c,v=u;else m=l.config.tooltip.x.formatter(c),v=l.config.tooltip.x.formatter(u);return{start:c,end:u,startVal:m,endVal:v,ylabel:d,color:x,seriesName:h}},z=function(e){var t=e.color,n=e.seriesName,r=e.ylabel,i=e.start,a=e.end,o=e.seriesIndex,s=e.dataPointIndex,l=e.ctx.tooltip.tooltipLabels.getFormatters(o);i=l.yLbFormatter(i),a=l.yLbFormatter(a);var c=l.yLbFormatter(e.w.globals.series[o][s]),u='\n '.concat(i,'\n - \n ').concat(a,"\n ");return'
'+(n||"")+'
'+r+": "+(e.w.globals.comboCharts?"rangeArea"===e.w.config.series[o].type||"rangeBar"===e.w.config.series[o].type?u:"".concat(c,""):u)+"
"},D=function(){function e(t){s(this,e),this.opts=t}return c(e,[{key:"hideYAxis",value:function(){this.opts.yaxis[0].show=!1,this.opts.yaxis[0].title.text="",this.opts.yaxis[0].axisBorder.show=!1,this.opts.yaxis[0].axisTicks.show=!1,this.opts.yaxis[0].floating=!0}},{key:"line",value:function(){return{chart:{animations:{easing:"swing"}},dataLabels:{enabled:!1},stroke:{width:5,curve:"straight"},markers:{size:0,hover:{sizeOffset:6}},xaxis:{crosshairs:{width:1}}}}},{key:"sparkline",value:function(e){return this.hideYAxis(),y.extend(e,{grid:{show:!1,padding:{left:0,right:0,top:0,bottom:0}},legend:{show:!1},xaxis:{labels:{show:!1},tooltip:{enabled:!1},axisBorder:{show:!1},axisTicks:{show:!1}},chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1}})}},{key:"bar",value:function(){return{chart:{stacked:!1,animations:{easing:"swing"}},plotOptions:{bar:{dataLabels:{position:"center"}}},dataLabels:{style:{colors:["#fff"]},background:{enabled:!1}},stroke:{width:0,lineCap:"round"},fill:{opacity:.85},legend:{markers:{shape:"square",radius:2,size:8}},tooltip:{shared:!1,intersect:!0},xaxis:{tooltip:{enabled:!1},tickPlacement:"between",crosshairs:{width:"barWidth",position:"back",fill:{type:"gradient"},dropShadow:{enabled:!1},stroke:{width:0}}}}}},{key:"funnel",value:function(){return this.hideYAxis(),a(a({},this.bar()),{},{chart:{animations:{easing:"linear",speed:800,animateGradually:{enabled:!1}}},plotOptions:{bar:{horizontal:!0,borderRadiusApplication:"around",borderRadius:0,dataLabels:{position:"center"}}},grid:{show:!1,padding:{left:0,right:0}},xaxis:{labels:{show:!1},tooltip:{enabled:!1},axisBorder:{show:!1},axisTicks:{show:!1}}})}},{key:"candlestick",value:function(){var e=this;return{stroke:{width:1,colors:["#333"]},fill:{opacity:1},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(t){var n=t.seriesIndex,r=t.dataPointIndex,i=t.w;return e._getBoxTooltip(i,n,r,["Open","High","","Low","Close"],"candlestick")}},states:{active:{filter:{type:"none"}}},xaxis:{crosshairs:{width:1}}}}},{key:"boxPlot",value:function(){var e=this;return{chart:{animations:{dynamicAnimation:{enabled:!1}}},stroke:{width:1,colors:["#24292e"]},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(t){var n=t.seriesIndex,r=t.dataPointIndex,i=t.w;return e._getBoxTooltip(i,n,r,["Minimum","Q1","Median","Q3","Maximum"],"boxPlot")}},markers:{size:5,strokeWidth:1,strokeColors:"#111"},xaxis:{crosshairs:{width:1}}}}},{key:"rangeBar",value:function(){return{chart:{animations:{animateGradually:!1}},stroke:{width:0,lineCap:"square"},plotOptions:{bar:{borderRadius:0,dataLabels:{position:"center"}}},dataLabels:{enabled:!1,formatter:function(e,t){t.ctx;var n=t.seriesIndex,r=t.dataPointIndex,i=t.w,a=function(){var e=i.globals.seriesRangeStart[n][r];return i.globals.seriesRangeEnd[n][r]-e};return i.globals.comboCharts?"rangeBar"===i.config.series[n].type||"rangeArea"===i.config.series[n].type?a():e:a()},background:{enabled:!1},style:{colors:["#fff"]}},markers:{size:10},tooltip:{shared:!1,followCursor:!0,custom:function(e){return e.w.config.plotOptions&&e.w.config.plotOptions.bar&&e.w.config.plotOptions.bar.horizontal?function(e){var t=R(a(a({},e),{},{isTimeline:!0})),n=t.color,r=t.seriesName,i=t.ylabel,o=t.startVal,s=t.endVal;return z(a(a({},e),{},{color:n,seriesName:r,ylabel:i,start:o,end:s}))}(e):function(e){var t=R(e),n=t.color,r=t.seriesName,i=t.ylabel,o=t.start,s=t.end;return z(a(a({},e),{},{color:n,seriesName:r,ylabel:i,start:o,end:s}))}(e)}},xaxis:{tickPlacement:"between",tooltip:{enabled:!1},crosshairs:{stroke:{width:0}}}}}},{key:"dumbbell",value:function(e){var t,n;return null!==(t=e.plotOptions.bar)&&void 0!==t&&t.barHeight||(e.plotOptions.bar.barHeight=2),null!==(n=e.plotOptions.bar)&&void 0!==n&&n.columnWidth||(e.plotOptions.bar.columnWidth=2),e}},{key:"area",value:function(){return{stroke:{width:4,fill:{type:"solid",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}}},fill:{type:"gradient",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}},markers:{size:0,hover:{sizeOffset:6}},tooltip:{followCursor:!1}}}},{key:"rangeArea",value:function(){return{stroke:{curve:"straight",width:0},fill:{type:"solid",opacity:.6},markers:{size:0},states:{hover:{filter:{type:"none"}},active:{filter:{type:"none"}}},tooltip:{intersect:!1,shared:!0,followCursor:!0,custom:function(e){return function(e){var t=R(e),n=t.color,r=t.seriesName,i=t.ylabel,o=t.start,s=t.end;return z(a(a({},e),{},{color:n,seriesName:r,ylabel:i,start:o,end:s}))}(e)}}}}},{key:"brush",value:function(e){return y.extend(e,{chart:{toolbar:{autoSelected:"selection",show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1},stroke:{width:1},tooltip:{enabled:!1},xaxis:{tooltip:{enabled:!1}}})}},{key:"stacked100",value:function(e){e.dataLabels=e.dataLabels||{},e.dataLabels.formatter=e.dataLabels.formatter||void 0;var t=e.dataLabels.formatter;return e.yaxis.forEach((function(t,n){e.yaxis[n].min=0,e.yaxis[n].max=100})),"bar"===e.chart.type&&(e.dataLabels.formatter=t||function(e){return"number"==typeof e&&e?e.toFixed(0)+"%":e}),e}},{key:"stackedBars",value:function(){var e=this.bar();return a(a({},e),{},{plotOptions:a(a({},e.plotOptions),{},{bar:a(a({},e.plotOptions.bar),{},{borderRadiusApplication:"end",borderRadiusWhenStacked:"last"})})})}},{key:"convertCatToNumeric",value:function(e){return e.xaxis.convertedCatToNumeric=!0,e}},{key:"convertCatToNumericXaxis",value:function(e,t,n){e.xaxis.type="numeric",e.xaxis.labels=e.xaxis.labels||{},e.xaxis.labels.formatter=e.xaxis.labels.formatter||function(e){return y.isNumber(e)?Math.floor(e):e};var r=e.xaxis.labels.formatter,i=e.xaxis.categories&&e.xaxis.categories.length?e.xaxis.categories:e.labels;return n&&n.length&&(i=n.map((function(e){return Array.isArray(e)?e:String(e)}))),i&&i.length&&(e.xaxis.labels.formatter=function(e){return y.isNumber(e)?r(i[Math.floor(e)-1]):r(e)}),e.xaxis.categories=[],e.labels=[],e.xaxis.tickAmount=e.xaxis.tickAmount||"dataPoints",e}},{key:"bubble",value:function(){return{dataLabels:{style:{colors:["#fff"]}},tooltip:{shared:!1,intersect:!0},xaxis:{crosshairs:{width:0}},fill:{type:"solid",gradient:{shade:"light",inverse:!0,shadeIntensity:.55,opacityFrom:.4,opacityTo:.8}}}}},{key:"scatter",value:function(){return{dataLabels:{enabled:!1},tooltip:{shared:!1,intersect:!0},markers:{size:6,strokeWidth:1,hover:{sizeOffset:2}}}}},{key:"heatmap",value:function(){return{chart:{stacked:!1},fill:{opacity:1},dataLabels:{style:{colors:["#fff"]}},stroke:{colors:["#fff"]},tooltip:{followCursor:!0,marker:{show:!1},x:{show:!1}},legend:{position:"top",markers:{shape:"square",size:10,offsetY:2}},grid:{padding:{right:20}}}}},{key:"treemap",value:function(){return{chart:{zoom:{enabled:!1}},dataLabels:{style:{fontSize:14,fontWeight:600,colors:["#fff"]}},stroke:{show:!0,width:2,colors:["#fff"]},legend:{show:!1},fill:{gradient:{stops:[0,100]}},tooltip:{followCursor:!0,x:{show:!1}},grid:{padding:{left:0,right:0}},xaxis:{crosshairs:{show:!1},tooltip:{enabled:!1}}}}},{key:"pie",value:function(){return{chart:{toolbar:{show:!1}},plotOptions:{pie:{donut:{labels:{show:!1}}}},dataLabels:{formatter:function(e){return e.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",stops:[0,100]}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"donut",value:function(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(e){return e.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",shadeIntensity:.35,stops:[80,100],opacityFrom:1,opacityTo:1}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"polarArea",value:function(){return this.opts.yaxis[0].tickAmount=this.opts.yaxis[0].tickAmount?this.opts.yaxis[0].tickAmount:6,{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(e){return e.toFixed(1)+"%"},enabled:!1},stroke:{show:!0,width:2},fill:{opacity:.7},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"radar",value:function(){return this.opts.yaxis[0].labels.offsetY=this.opts.yaxis[0].labels.offsetY?this.opts.yaxis[0].labels.offsetY:6,{dataLabels:{enabled:!1,style:{fontSize:"11px"}},stroke:{width:2},markers:{size:3,strokeWidth:1,strokeOpacity:1},fill:{opacity:.2},tooltip:{shared:!1,intersect:!0,followCursor:!0},grid:{show:!1},xaxis:{labels:{formatter:function(e){return e},style:{colors:["#a8a8a8"],fontSize:"11px"}},tooltip:{enabled:!1},crosshairs:{show:!1}}}}},{key:"radialBar",value:function(){return{chart:{animations:{dynamicAnimation:{enabled:!0,speed:800}},toolbar:{show:!1}},fill:{gradient:{shade:"dark",shadeIntensity:.4,inverseColors:!1,type:"diagonal2",opacityFrom:1,opacityTo:1,stops:[70,98,100]}},legend:{show:!1,position:"right"},tooltip:{enabled:!1,fillSeriesColor:!0}}}},{key:"_getBoxTooltip",value:function(e,t,n,r,i){var a=e.globals.seriesCandleO[t][n],o=e.globals.seriesCandleH[t][n],s=e.globals.seriesCandleM[t][n],l=e.globals.seriesCandleL[t][n],c=e.globals.seriesCandleC[t][n];return e.config.series[t].type&&e.config.series[t].type!==i?'
\n '.concat(e.config.series[t].name?e.config.series[t].name:"series-"+(t+1),": ").concat(e.globals.series[t][n],"\n
"):'
')+"
".concat(r[0],': ')+a+"
"+"
".concat(r[1],': ')+o+"
"+(s?"
".concat(r[2],': ')+s+"
":"")+"
".concat(r[3],': ')+l+"
"+"
".concat(r[4],': ')+c+"
"}}]),e}(),F=function(){function e(t){s(this,e),this.opts=t}return c(e,[{key:"init",value:function(e){var t=e.responsiveOverride,n=this.opts,r=new _,i=new D(n);this.chartType=n.chart.type,n=this.extendYAxis(n),n=this.extendAnnotations(n);var a=r.init(),s={};if(n&&"object"===o(n)){var l,c,u,d,h,f,p,g,m,v,x={};x=-1!==["line","area","bar","candlestick","boxPlot","rangeBar","rangeArea","bubble","scatter","heatmap","treemap","pie","polarArea","donut","radar","radialBar"].indexOf(n.chart.type)?i[n.chart.type]():i.line(),null!==(l=n.plotOptions)&&void 0!==l&&null!==(c=l.bar)&&void 0!==c&&c.isFunnel&&(x=i.funnel()),n.chart.stacked&&"bar"===n.chart.type&&(x=i.stackedBars()),null!==(u=n.chart.brush)&&void 0!==u&&u.enabled&&(x=i.brush(x)),n.chart.stacked&&"100%"===n.chart.stackType&&(n=i.stacked100(n)),null!==(d=n.plotOptions)&&void 0!==d&&null!==(h=d.bar)&&void 0!==h&&h.isDumbbell&&(n=i.dumbbell(n)),"monotoneCubic"===(null===(f=n)||void 0===f||null===(p=f.stroke)||void 0===p?void 0:p.curve)&&(n.stroke.curve="smooth"),this.checkForDarkTheme(window.Apex),this.checkForDarkTheme(n),n.xaxis=n.xaxis||window.Apex.xaxis||{},t||(n.xaxis.convertedCatToNumeric=!1),(null!==(g=(n=this.checkForCatToNumericXAxis(this.chartType,x,n)).chart.sparkline)&&void 0!==g&&g.enabled||null!==(m=window.Apex.chart)&&void 0!==m&&null!==(v=m.sparkline)&&void 0!==v&&v.enabled)&&(x=i.sparkline(x)),s=y.extend(a,x)}var b=y.extend(s,window.Apex);return a=y.extend(b,n),this.handleUserInputErrors(a)}},{key:"checkForCatToNumericXAxis",value:function(e,t,n){var r,i,a=new D(n),o=("bar"===e||"boxPlot"===e)&&(null===(r=n.plotOptions)||void 0===r||null===(i=r.bar)||void 0===i?void 0:i.horizontal),s="pie"===e||"polarArea"===e||"donut"===e||"radar"===e||"radialBar"===e||"heatmap"===e,l="datetime"!==n.xaxis.type&&"numeric"!==n.xaxis.type,c=n.xaxis.tickPlacement?n.xaxis.tickPlacement:t.xaxis&&t.xaxis.tickPlacement;return o||s||!l||"between"===c||(n=a.convertCatToNumeric(n)),n}},{key:"extendYAxis",value:function(e,t){var n=new _;(void 0===e.yaxis||!e.yaxis||Array.isArray(e.yaxis)&&0===e.yaxis.length)&&(e.yaxis={}),e.yaxis.constructor!==Array&&window.Apex.yaxis&&window.Apex.yaxis.constructor!==Array&&(e.yaxis=y.extend(e.yaxis,window.Apex.yaxis)),e.yaxis.constructor!==Array?e.yaxis=[y.extend(n.yAxis,e.yaxis)]:e.yaxis=y.extendArray(e.yaxis,n.yAxis);var r=!1;e.yaxis.forEach((function(e){e.logarithmic&&(r=!0)}));var i=e.series;return t&&!i&&(i=t.config.series),r&&i.length!==e.yaxis.length&&i.length&&(e.yaxis=i.map((function(t,r){if(t.name||(i[r].name="series-".concat(r+1)),e.yaxis[r])return e.yaxis[r].seriesName=i[r].name,e.yaxis[r];var a=y.extend(n.yAxis,e.yaxis[0]);return a.show=!1,a}))),r&&i.length>1&&i.length!==e.yaxis.length&&console.warn("A multi-series logarithmic chart should have equal number of series and y-axes"),e}},{key:"extendAnnotations",value:function(e){return void 0===e.annotations&&(e.annotations={},e.annotations.yaxis=[],e.annotations.xaxis=[],e.annotations.points=[]),e=this.extendYAxisAnnotations(e),e=this.extendXAxisAnnotations(e),this.extendPointAnnotations(e)}},{key:"extendYAxisAnnotations",value:function(e){var t=new _;return e.annotations.yaxis=y.extendArray(void 0!==e.annotations.yaxis?e.annotations.yaxis:[],t.yAxisAnnotation),e}},{key:"extendXAxisAnnotations",value:function(e){var t=new _;return e.annotations.xaxis=y.extendArray(void 0!==e.annotations.xaxis?e.annotations.xaxis:[],t.xAxisAnnotation),e}},{key:"extendPointAnnotations",value:function(e){var t=new _;return e.annotations.points=y.extendArray(void 0!==e.annotations.points?e.annotations.points:[],t.pointAnnotation),e}},{key:"checkForDarkTheme",value:function(e){e.theme&&"dark"===e.theme.mode&&(e.tooltip||(e.tooltip={}),"light"!==e.tooltip.theme&&(e.tooltip.theme="dark"),e.chart.foreColor||(e.chart.foreColor="#f6f7f8"),e.chart.background||(e.chart.background="#424242"),e.theme.palette||(e.theme.palette="palette4"))}},{key:"handleUserInputErrors",value:function(e){var t=e;if(t.tooltip.shared&&t.tooltip.intersect)throw new Error("tooltip.shared cannot be enabled when tooltip.intersect is true. Turn off any other option by setting it to false.");if("bar"===t.chart.type&&t.plotOptions.bar.horizontal){if(t.yaxis.length>1)throw new Error("Multiple Y Axis for bars are not supported. Switch to column chart by setting plotOptions.bar.horizontal=false");t.yaxis[0].reversed&&(t.yaxis[0].opposite=!0),t.xaxis.tooltip.enabled=!1,t.yaxis[0].tooltip.enabled=!1,t.chart.zoom.enabled=!1}return"bar"!==t.chart.type&&"rangeBar"!==t.chart.type||t.tooltip.shared&&"barWidth"===t.xaxis.crosshairs.width&&t.series.length>1&&(t.xaxis.crosshairs.width="tickWidth"),"candlestick"!==t.chart.type&&"boxPlot"!==t.chart.type||t.yaxis[0].reversed&&(console.warn("Reversed y-axis in ".concat(t.chart.type," chart is not supported.")),t.yaxis[0].reversed=!1),t}}]),e}(),N=function(){function e(){s(this,e)}return c(e,[{key:"initGlobalVars",value:function(e){e.series=[],e.seriesCandleO=[],e.seriesCandleH=[],e.seriesCandleM=[],e.seriesCandleL=[],e.seriesCandleC=[],e.seriesRangeStart=[],e.seriesRangeEnd=[],e.seriesRange=[],e.seriesPercent=[],e.seriesGoals=[],e.seriesX=[],e.seriesZ=[],e.seriesNames=[],e.seriesTotals=[],e.seriesLog=[],e.seriesColors=[],e.stackedSeriesTotals=[],e.seriesXvalues=[],e.seriesYvalues=[],e.labels=[],e.hasXaxisGroups=!1,e.groups=[],e.hasSeriesGroups=!1,e.seriesGroups=[],e.categoryLabels=[],e.timescaleLabels=[],e.noLabelsProvided=!1,e.resizeTimer=null,e.selectionResizeTimer=null,e.delayedElements=[],e.pointsArray=[],e.dataLabelsRects=[],e.isXNumeric=!1,e.skipLastTimelinelabel=!1,e.skipFirstTimelinelabel=!1,e.isDataXYZ=!1,e.isMultiLineX=!1,e.isMultipleYAxis=!1,e.maxY=-Number.MAX_VALUE,e.minY=Number.MIN_VALUE,e.minYArr=[],e.maxYArr=[],e.maxX=-Number.MAX_VALUE,e.minX=Number.MAX_VALUE,e.initialMaxX=-Number.MAX_VALUE,e.initialMinX=Number.MAX_VALUE,e.maxDate=0,e.minDate=Number.MAX_VALUE,e.minZ=Number.MAX_VALUE,e.maxZ=-Number.MAX_VALUE,e.minXDiff=Number.MAX_VALUE,e.yAxisScale=[],e.xAxisScale=null,e.xAxisTicksPositions=[],e.yLabelsCoords=[],e.yTitleCoords=[],e.barPadForNumericAxis=0,e.padHorizontal=0,e.xRange=0,e.yRange=[],e.zRange=0,e.dataPoints=0,e.xTickAmount=0}},{key:"globalVars",value:function(e){return{chartID:null,cuid:null,events:{beforeMount:[],mounted:[],updated:[],clicked:[],selection:[],dataPointSelection:[],zoomed:[],scrolled:[]},colors:[],clientX:null,clientY:null,fill:{colors:[]},stroke:{colors:[]},dataLabels:{style:{colors:[]}},radarPolygons:{fill:{colors:[]}},markers:{colors:[],size:e.markers.size,largestSize:0},animationEnded:!1,isTouchDevice:"ontouchstart"in window||navigator.msMaxTouchPoints,isDirty:!1,isExecCalled:!1,initialConfig:null,initialSeries:[],lastXAxis:[],lastYAxis:[],columnSeries:null,labels:[],timescaleLabels:[],noLabelsProvided:!1,allSeriesCollapsed:!1,collapsedSeries:[],collapsedSeriesIndices:[],ancillaryCollapsedSeries:[],ancillaryCollapsedSeriesIndices:[],risingSeries:[],dataFormatXNumeric:!1,capturedSeriesIndex:-1,capturedDataPointIndex:-1,selectedDataPoints:[],goldenPadding:35,invalidLogScale:!1,ignoreYAxisIndexes:[],yAxisSameScaleIndices:[],maxValsInArrayIndex:0,radialSize:0,selection:void 0,zoomEnabled:"zoom"===e.chart.toolbar.autoSelected&&e.chart.toolbar.tools.zoom&&e.chart.zoom.enabled,panEnabled:"pan"===e.chart.toolbar.autoSelected&&e.chart.toolbar.tools.pan,selectionEnabled:"selection"===e.chart.toolbar.autoSelected&&e.chart.toolbar.tools.selection,yaxis:null,mousedown:!1,lastClientPosition:{},visibleXRange:void 0,yValueDecimal:0,total:0,SVGNS:"http://www.w3.org/2000/svg",svgWidth:0,svgHeight:0,noData:!1,locale:{},dom:{},memory:{methodsToExec:[]},shouldAnimate:!0,skipLastTimelinelabel:!1,skipFirstTimelinelabel:!1,delayedElements:[],axisCharts:!0,isDataXYZ:!1,resized:!1,resizeTimer:null,comboCharts:!1,dataChanged:!1,previousPaths:[],allSeriesHasEqualX:!0,pointsArray:[],dataLabelsRects:[],lastDrawnDataLabelsIndexes:[],hasNullValues:!1,easing:null,zoomed:!1,gridWidth:0,gridHeight:0,rotateXLabels:!1,defaultLabels:!1,xLabelFormatter:void 0,yLabelFormatters:[],xaxisTooltipFormatter:void 0,ttKeyFormatter:void 0,ttVal:void 0,ttZFormatter:void 0,LINE_HEIGHT_RATIO:1.618,xAxisLabelsHeight:0,xAxisGroupLabelsHeight:0,xAxisLabelsWidth:0,yAxisLabelsWidth:0,scaleX:1,scaleY:1,translateX:0,translateY:0,translateYAxisX:[],yAxisWidths:[],translateXAxisY:0,translateXAxisX:0,tooltip:null}}},{key:"init",value:function(e){var t=this.globalVars(e);return this.initGlobalVars(t),t.initialConfig=y.extend({},e),t.initialSeries=y.clone(e.series),t.lastXAxis=y.clone(t.initialConfig.xaxis),t.lastYAxis=y.clone(t.initialConfig.yaxis),t}}]),e}(),j=function(){function e(t){s(this,e),this.opts=t}return c(e,[{key:"init",value:function(){var e=new F(this.opts).init({responsiveOverride:!1});return{config:e,globals:(new N).init(e)}}}]),e}(),B=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.opts=null,this.seriesIndex=0}return c(e,[{key:"clippedImgArea",value:function(e){var t=this.w,n=t.config,r=parseInt(t.globals.gridWidth,10),i=parseInt(t.globals.gridHeight,10),a=r>i?r:i,o=e.image,s=0,l=0;void 0===e.width&&void 0===e.height?void 0!==n.fill.image.width&&void 0!==n.fill.image.height?(s=n.fill.image.width+1,l=n.fill.image.height):(s=a+1,l=a):(s=e.width,l=e.height);var c=document.createElementNS(t.globals.SVGNS,"pattern");S.setAttrs(c,{id:e.patternID,patternUnits:e.patternUnits?e.patternUnits:"userSpaceOnUse",width:s+"px",height:l+"px"});var u=document.createElementNS(t.globals.SVGNS,"image");c.appendChild(u),u.setAttributeNS(window.SVG.xlink,"href",o),S.setAttrs(u,{x:0,y:0,preserveAspectRatio:"none",width:s+"px",height:l+"px"}),u.style.opacity=e.opacity,t.globals.dom.elDefs.node.appendChild(c)}},{key:"getSeriesIndex",value:function(e){var t=this.w,n=t.config.chart.type;return("bar"===n||"rangeBar"===n)&&t.config.plotOptions.bar.distributed||"heatmap"===n||"treemap"===n?this.seriesIndex=e.seriesNumber:this.seriesIndex=e.seriesNumber%t.globals.series.length,this.seriesIndex}},{key:"fillPath",value:function(e){var t=this.w;this.opts=e;var n,r,i,a=this.w.config;this.seriesIndex=this.getSeriesIndex(e);var o=this.getFillColors()[this.seriesIndex];void 0!==t.globals.seriesColors[this.seriesIndex]&&(o=t.globals.seriesColors[this.seriesIndex]),"function"==typeof o&&(o=o({seriesIndex:this.seriesIndex,dataPointIndex:e.dataPointIndex,value:e.value,w:t}));var s=e.fillType?e.fillType:this.getFillType(this.seriesIndex),l=Array.isArray(a.fill.opacity)?a.fill.opacity[this.seriesIndex]:a.fill.opacity;e.color&&(o=e.color),o||(o="#fff",console.warn("undefined color - ApexCharts"));var c=o;if(-1===o.indexOf("rgb")?o.length<9&&(c=y.hexToRgba(o,l)):o.indexOf("rgba")>-1&&(l=y.getOpacityFromRGBA(o)),e.opacity&&(l=e.opacity),"pattern"===s&&(r=this.handlePatternFill({fillConfig:e.fillConfig,patternFill:r,fillColor:o,fillOpacity:l,defaultColor:c})),"gradient"===s&&(i=this.handleGradientFill({fillConfig:e.fillConfig,fillColor:o,fillOpacity:l,i:this.seriesIndex})),"image"===s){var u=a.fill.image.src,d=e.patternID?e.patternID:"";this.clippedImgArea({opacity:l,image:Array.isArray(u)?e.seriesNumber-1&&(f=y.getOpacityFromRGBA(h));var p=void 0===o.gradient.opacityTo?n:Array.isArray(o.gradient.opacityTo)?o.gradient.opacityTo[i]:o.gradient.opacityTo;if(void 0===o.gradient.gradientToColors||0===o.gradient.gradientToColors.length)s="dark"===o.gradient.shade?u.shadeColor(-1*parseFloat(o.gradient.shadeIntensity),t.indexOf("rgb")>-1?y.rgb2hex(t):t):u.shadeColor(parseFloat(o.gradient.shadeIntensity),t.indexOf("rgb")>-1?y.rgb2hex(t):t);else if(o.gradient.gradientToColors[l.seriesNumber]){var g=o.gradient.gradientToColors[l.seriesNumber];s=g,g.indexOf("rgba")>-1&&(p=y.getOpacityFromRGBA(g))}else s=t;if(o.gradient.gradientFrom&&(h=o.gradient.gradientFrom),o.gradient.gradientTo&&(s=o.gradient.gradientTo),o.gradient.inverseColors){var m=h;h=s,s=m}return h.indexOf("rgb")>-1&&(h=y.rgb2hex(h)),s.indexOf("rgb")>-1&&(s=y.rgb2hex(s)),c.drawGradient(d,h,s,f,p,l.size,o.gradient.stops,o.gradient.colorStops,i)}}]),e}(),Y=function(){function e(t,n){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"setGlobalMarkerSize",value:function(){var e=this.w;if(e.globals.markers.size=Array.isArray(e.config.markers.size)?e.config.markers.size:[e.config.markers.size],e.globals.markers.size.length>0){if(e.globals.markers.size.length4&&void 0!==arguments[4]&&arguments[4],o=this.w,s=t,l=e,c=null,u=new S(this.ctx),d=o.config.markers.discrete&&o.config.markers.discrete.length;if((o.globals.markers.size[t]>0||a||d)&&(c=u.group({class:a||d?"":"apexcharts-series-markers"})).attr("clip-path","url(#gridRectMarkerMask".concat(o.globals.cuid,")")),Array.isArray(l.x))for(var h=0;h0:o.config.markers.size>0)||a||d){y.isNumber(l.y[h])?p+=" w".concat(y.randomId()):p="apexcharts-nullpoint";var g=this.getMarkerConfig({cssClass:p,seriesIndex:t,dataPointIndex:f});o.config.series[s].data[f]&&(o.config.series[s].data[f].fillColor&&(g.pointFillColor=o.config.series[s].data[f].fillColor),o.config.series[s].data[f].strokeColor&&(g.pointStrokeColor=o.config.series[s].data[f].strokeColor)),r&&(g.pSize=r),(l.x[h]<0||l.x[h]>o.globals.gridWidth||l.y[h]<-o.globals.markers.largestSize||l.y[h]>o.globals.gridHeight+o.globals.markers.largestSize)&&(g.pSize=0),(i=u.drawMarker(l.x[h],l.y[h],g)).attr("rel",f),i.attr("j",f),i.attr("index",t),i.node.setAttribute("default-marker-size",g.pSize),new k(this.ctx).setSelectionFilter(i,t,f),this.addEvents(i),c&&c.add(i)}else void 0===o.globals.pointsArray[t]&&(o.globals.pointsArray[t]=[]),o.globals.pointsArray[t].push([l.x[h],l.y[h]])}return c}},{key:"getMarkerConfig",value:function(e){var t=e.cssClass,n=e.seriesIndex,r=e.dataPointIndex,i=void 0===r?null:r,a=e.finishRadius,o=void 0===a?null:a,s=this.w,l=this.getMarkerStyle(n),c=s.globals.markers.size[n],u=s.config.markers;return null!==i&&u.discrete.length&&u.discrete.map((function(e){e.seriesIndex===n&&e.dataPointIndex===i&&(l.pointStrokeColor=e.strokeColor,l.pointFillColor=e.fillColor,c=e.size,l.pointShape=e.shape)})),{pSize:null===o?c:o,pRadius:u.radius,width:Array.isArray(u.width)?u.width[n]:u.width,height:Array.isArray(u.height)?u.height[n]:u.height,pointStrokeWidth:Array.isArray(u.strokeWidth)?u.strokeWidth[n]:u.strokeWidth,pointStrokeColor:l.pointStrokeColor,pointFillColor:l.pointFillColor,shape:l.pointShape||(Array.isArray(u.shape)?u.shape[n]:u.shape),class:t,pointStrokeOpacity:Array.isArray(u.strokeOpacity)?u.strokeOpacity[n]:u.strokeOpacity,pointStrokeDashArray:Array.isArray(u.strokeDashArray)?u.strokeDashArray[n]:u.strokeDashArray,pointFillOpacity:Array.isArray(u.fillOpacity)?u.fillOpacity[n]:u.fillOpacity,seriesIndex:n}}},{key:"addEvents",value:function(e){var t=this.w,n=new S(this.ctx);e.node.addEventListener("mouseenter",n.pathMouseEnter.bind(this.ctx,e)),e.node.addEventListener("mouseleave",n.pathMouseLeave.bind(this.ctx,e)),e.node.addEventListener("mousedown",n.pathMouseDown.bind(this.ctx,e)),e.node.addEventListener("click",t.config.markers.onClick),e.node.addEventListener("dblclick",t.config.markers.onDblClick),e.node.addEventListener("touchstart",n.pathMouseDown.bind(this.ctx,e),{passive:!0})}},{key:"getMarkerStyle",value:function(e){var t=this.w,n=t.globals.markers.colors,r=t.config.markers.strokeColor||t.config.markers.strokeColors;return{pointStrokeColor:Array.isArray(r)?r[e]:r,pointFillColor:Array.isArray(n)?n[e]:n}}}]),e}(),H=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.initialAnim=this.w.config.chart.animations.enabled,this.dynamicAnim=this.initialAnim&&this.w.config.chart.animations.dynamicAnimation.enabled}return c(e,[{key:"draw",value:function(e,t,n){var r=this.w,i=new S(this.ctx),a=n.realIndex,o=n.pointsPos,s=n.zRatio,l=n.elParent,c=i.group({class:"apexcharts-series-markers apexcharts-series-".concat(r.config.chart.type)});if(c.attr("clip-path","url(#gridRectMarkerMask".concat(r.globals.cuid,")")),Array.isArray(o.x))for(var u=0;ug.maxBubbleRadius&&(p=g.maxBubbleRadius)}r.config.chart.animations.enabled||(f=p);var m=o.x[u],v=o.y[u];if(f=f||0,null!==v&&void 0!==r.globals.series[a][d]||(h=!1),h){var x=this.drawPoint(m,v,f,p,a,d,t);c.add(x)}l.add(c)}}},{key:"drawPoint",value:function(e,t,n,r,i,a,o){var s=this.w,l=i,c=new w(this.ctx),u=new k(this.ctx),d=new B(this.ctx),h=new Y(this.ctx),f=new S(this.ctx),p=h.getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:l,dataPointIndex:a,finishRadius:"bubble"===s.config.chart.type||s.globals.comboCharts&&s.config.series[i]&&"bubble"===s.config.series[i].type?r:null});r=p.pSize;var g,m=d.fillPath({seriesNumber:i,dataPointIndex:a,color:p.pointFillColor,patternUnits:"objectBoundingBox",value:s.globals.series[i][o]});if("circle"===p.shape?g=f.drawCircle(n):"square"!==p.shape&&"rect"!==p.shape||(g=f.drawRect(0,0,p.width-p.pointStrokeWidth/2,p.height-p.pointStrokeWidth/2,p.pRadius)),s.config.series[l].data[a]&&s.config.series[l].data[a].fillColor&&(m=s.config.series[l].data[a].fillColor),g.attr({x:e-p.width/2-p.pointStrokeWidth/2,y:t-p.height/2-p.pointStrokeWidth/2,cx:e,cy:t,fill:m,"fill-opacity":p.pointFillOpacity,stroke:p.pointStrokeColor,r:r,"stroke-width":p.pointStrokeWidth,"stroke-dasharray":p.pointStrokeDashArray,"stroke-opacity":p.pointStrokeOpacity}),s.config.chart.dropShadow.enabled){var v=s.config.chart.dropShadow;u.dropShadow(g,v,i)}if(!this.initialAnim||s.globals.dataChanged||s.globals.resized)s.globals.animationEnded=!0;else{var x=s.config.chart.animations.speed;c.animateMarker(g,0,"circle"===p.shape?r:{width:p.width,height:p.height},x,s.globals.easing,(function(){window.setTimeout((function(){c.animationCompleted(g)}),100)}))}if(s.globals.dataChanged&&"circle"===p.shape)if(this.dynamicAnim){var b,y,C,A,E=s.config.chart.animations.dynamicAnimation.speed;null!=(A=s.globals.previousPaths[i]&&s.globals.previousPaths[i][o])&&(b=A.x,y=A.y,C=void 0!==A.r?A.r:r);for(var P=0;Ps.globals.gridHeight+d&&(t=s.globals.gridHeight+d/2),void 0===s.globals.dataLabelsRects[r]&&(s.globals.dataLabelsRects[r]=[]),s.globals.dataLabelsRects[r].push({x:e,y:t,width:u,height:d});var h=s.globals.dataLabelsRects[r].length-2,f=void 0!==s.globals.lastDrawnDataLabelsIndexes[r]?s.globals.lastDrawnDataLabelsIndexes[r][s.globals.lastDrawnDataLabelsIndexes[r].length-1]:0;if(void 0!==s.globals.dataLabelsRects[r][h]){var p=s.globals.dataLabelsRects[r][f];(e>p.x+p.width||t>p.y+p.height||t+dt.globals.gridWidth+g.textRects.width+30)&&(s="");var m=t.globals.dataLabels.style.colors[a];(("bar"===t.config.chart.type||"rangeBar"===t.config.chart.type)&&t.config.plotOptions.bar.distributed||t.config.dataLabels.distributed)&&(m=t.globals.dataLabels.style.colors[o]),"function"==typeof m&&(m=m({series:t.globals.series,seriesIndex:a,dataPointIndex:o,w:t})),h&&(m=h);var v=d.offsetX,x=d.offsetY;if("bar"!==t.config.chart.type&&"rangeBar"!==t.config.chart.type||(v=0,x=0),g.drawnextLabel){var b=n.drawText({width:100,height:parseInt(d.style.fontSize,10),x:r+v,y:i+x,foreColor:m,textAnchor:l||d.textAnchor,text:s,fontSize:c||d.style.fontSize,fontFamily:d.style.fontFamily,fontWeight:d.style.fontWeight||"normal"});if(b.attr({class:"apexcharts-datalabel",cx:r,cy:i}),d.dropShadow.enabled){var y=d.dropShadow;new k(this.ctx).dropShadow(b,y)}u.add(b),void 0===t.globals.lastDrawnDataLabelsIndexes[a]&&(t.globals.lastDrawnDataLabelsIndexes[a]=[]),t.globals.lastDrawnDataLabelsIndexes[a].push(o)}}}},{key:"addBackgroundToDataLabel",value:function(e,t){var n=this.w,r=n.config.dataLabels.background,i=r.padding,a=r.padding/2,o=t.width,s=t.height,l=new S(this.ctx).drawRect(t.x-i,t.y-a/2,o+2*i,s+a,r.borderRadius,"transparent"===n.config.chart.background?"#fff":n.config.chart.background,r.opacity,r.borderWidth,r.borderColor);return r.dropShadow.enabled&&new k(this.ctx).dropShadow(l,r.dropShadow),l}},{key:"dataLabelsBackground",value:function(){var e=this.w;if("bubble"!==e.config.chart.type)for(var t=e.globals.dom.baseEl.querySelectorAll(".apexcharts-datalabels text"),n=0;n0&&void 0!==arguments[0])||arguments[0],t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=this.w,i=y.clone(r.globals.initialSeries);r.globals.previousPaths=[],n?(r.globals.collapsedSeries=[],r.globals.ancillaryCollapsedSeries=[],r.globals.collapsedSeriesIndices=[],r.globals.ancillaryCollapsedSeriesIndices=[]):i=this.emptyCollapsedSeries(i),r.config.series=i,e&&(t&&(r.globals.zoomed=!1,this.ctx.updateHelpers.revertDefaultAxisMinMax()),this.ctx.updateHelpers._updateSeries(i,r.config.chart.animations.dynamicAnimation.enabled))}},{key:"emptyCollapsedSeries",value:function(e){for(var t=this.w,n=0;n-1&&(e[n].data=[]);return e}},{key:"toggleSeriesOnHover",value:function(e,t){var n=this.w;t||(t=e.target);var r=n.globals.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels");if("mousemove"===e.type){var i=parseInt(t.getAttribute("rel"),10)-1,a=null,o=null;n.globals.axisCharts||"radialBar"===n.config.chart.type?n.globals.axisCharts?(a=n.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(i,"']")),o=n.globals.dom.baseEl.querySelector(".apexcharts-datalabels[data\\:realIndex='".concat(i,"']"))):a=n.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(i+1,"']")):a=n.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(i+1,"'] path"));for(var s=0;s=e.from&&r<=e.to&&i[t].classList.remove(n.legendInactiveClass)}}(r.config.plotOptions.heatmap.colorScale.ranges[o])}else"mouseout"===e.type&&a("remove")}},{key:"getActiveConfigSeriesIndex",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"asc",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=this.w,r=0;if(n.config.series.length>1)for(var i=n.config.series.map((function(e,r){return e.data&&e.data.length>0&&-1===n.globals.collapsedSeriesIndices.indexOf(r)&&(!n.globals.comboCharts||0===t.length||t.length&&t.indexOf(n.config.series[r].type)>-1)?r:-1})),a="asc"===e?0:i.length-1;"asc"===e?a=0;"asc"===e?a++:a--)if(-1!==i[a]){r=i[a];break}return r}},{key:"getBarSeriesIndices",value:function(){return this.w.globals.comboCharts?this.w.config.series.map((function(e,t){return"bar"===e.type||"column"===e.type?t:-1})).filter((function(e){return-1!==e})):this.w.config.series.map((function(e,t){return t}))}},{key:"getPreviousPaths",value:function(){var e=this.w;function t(t,n,r){for(var i=t[n].childNodes,a={type:r,paths:[],realIndex:t[n].getAttribute("data:realIndex")},o=0;o0)for(var r=function(t){for(var n=e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e.config.chart.type," .apexcharts-series[data\\:realIndex='").concat(t,"'] rect")),r=[],i=function(e){var t=function(t){return n[e].getAttribute(t)},i={x:parseFloat(t("x")),y:parseFloat(t("y")),width:parseFloat(t("width")),height:parseFloat(t("height"))};r.push({rect:i,color:n[e].getAttribute("color")})},a=0;a0)for(var r=0;r0?e:[]}))}}]),e}(),V=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.twoDSeries=[],this.threeDSeries=[],this.twoDSeriesX=[],this.seriesGoals=[],this.coreUtils=new C(this.ctx)}return c(e,[{key:"isMultiFormat",value:function(){return this.isFormatXY()||this.isFormat2DArray()}},{key:"isFormatXY",value:function(){var e=this.w.config.series.slice(),t=new X(this.ctx);if(this.activeSeriesIndex=t.getActiveConfigSeriesIndex(),void 0!==e[this.activeSeriesIndex].data&&e[this.activeSeriesIndex].data.length>0&&null!==e[this.activeSeriesIndex].data[0]&&void 0!==e[this.activeSeriesIndex].data[0].x&&null!==e[this.activeSeriesIndex].data[0])return!0}},{key:"isFormat2DArray",value:function(){var e=this.w.config.series.slice(),t=new X(this.ctx);if(this.activeSeriesIndex=t.getActiveConfigSeriesIndex(),void 0!==e[this.activeSeriesIndex].data&&e[this.activeSeriesIndex].data.length>0&&void 0!==e[this.activeSeriesIndex].data[0]&&null!==e[this.activeSeriesIndex].data[0]&&e[this.activeSeriesIndex].data[0].constructor===Array)return!0}},{key:"handleFormat2DArray",value:function(e,t){for(var n=this.w.config,r=this.w.globals,i="boxPlot"===n.chart.type||"boxPlot"===n.series[t].type,a=0;a=5?this.twoDSeries.push(y.parseNumber(e[t].data[a][4])):this.twoDSeries.push(y.parseNumber(e[t].data[a][1])),r.dataFormatXNumeric=!0),"datetime"===n.xaxis.type){var o=new Date(e[t].data[a][0]);o=new Date(o).getTime(),this.twoDSeriesX.push(o)}else this.twoDSeriesX.push(e[t].data[a][0]);for(var s=0;s-1&&(a=this.activeSeriesIndex);for(var o=0;o1&&void 0!==arguments[1]?arguments[1]:this.ctx,i=this.w.config,a=this.w.globals,o=new O(r),s=i.labels.length>0?i.labels.slice():i.xaxis.categories.slice();if(a.isRangeBar="rangeBar"===i.chart.type&&a.isBarHorizontal,a.hasXaxisGroups="category"===i.xaxis.type&&i.xaxis.group.groups.length>0,a.hasXaxisGroups&&(a.groups=i.xaxis.group.groups),a.hasSeriesGroups=null===(t=e[0])||void 0===t?void 0:t.group,a.hasSeriesGroups){var l=[],c=v(new Set(e.map((function(e){return e.group}))));e.forEach((function(e,t){var n=c.indexOf(e.group);l[n]||(l[n]=[]),l[n].push(e.name)})),a.seriesGroups=l}for(var u=function(){for(var e=0;e0&&(this.twoDSeriesX=s,a.seriesX.push(this.twoDSeriesX))),a.labels.push(this.twoDSeriesX);var h=e[d].data.map((function(e){return y.parseNumber(e)}));a.series.push(h)}a.seriesZ.push(this.threeDSeries),void 0!==e[d].name?a.seriesNames.push(e[d].name):a.seriesNames.push("series-"+parseInt(d+1,10)),void 0!==e[d].color?a.seriesColors.push(e[d].color):a.seriesColors.push(void 0)}return this.w}},{key:"parseDataNonAxisCharts",value:function(e){var t=this.w.globals,n=this.w.config;t.series=e.slice(),t.seriesNames=n.labels.slice();for(var r=0;r0?n.labels=t.xaxis.categories:t.labels.length>0?n.labels=t.labels.slice():this.fallbackToCategory?(n.labels=n.labels[0],n.seriesRange.length&&(n.seriesRange.map((function(e){e.forEach((function(e){n.labels.indexOf(e.x)<0&&e.x&&n.labels.push(e.x)}))})),n.labels=Array.from(new Set(n.labels.map(JSON.stringify)),JSON.parse)),t.xaxis.convertedCatToNumeric&&(new D(t).convertCatToNumericXaxis(t,this.ctx,n.seriesX[0]),this._generateExternalLabels(e))):this._generateExternalLabels(e)}},{key:"_generateExternalLabels",value:function(e){var t=this.w.globals,n=this.w.config,r=[];if(t.axisCharts){if(t.series.length>0)if(this.isFormatXY())for(var i=n.series.map((function(e,t){return e.data.filter((function(e,t,n){return n.findIndex((function(t){return t.x===e.x}))===t}))})),a=i.reduce((function(e,t,n,r){return r[e].length>t.length?e:n}),0),o=0;o4&&void 0!==arguments[4]?arguments[4]:[],s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"12px",l=!(arguments.length>6&&void 0!==arguments[6])||arguments[6],c=this.w,u=void 0===e[r]?"":e[r],d=u,h=c.globals.xLabelFormatter,f=c.config.xaxis.labels.formatter,p=!1,g=new I(this.ctx),m=u;l&&(d=g.xLabelFormat(h,u,m,{i:r,dateFormatter:new O(this.ctx).formatDate,w:c}),void 0!==f&&(d=f(u,e[r],{i:r,dateFormatter:new O(this.ctx).formatDate,w:c}))),t.length>0?(i=t[r].unit,a=null,t.forEach((function(e){"month"===e.unit?a="year":"day"===e.unit?a="month":"hour"===e.unit?a="day":"minute"===e.unit&&(a="hour")})),p=a===i,n=t[r].position,d=t[r].value):"datetime"===c.config.xaxis.type&&void 0===f&&(d=""),void 0===d&&(d=""),d=Array.isArray(d)?d:d.toString();var v,x=new S(this.ctx);v=c.globals.rotateXLabels&&l?x.getTextRects(d,parseInt(s,10),null,"rotate(".concat(c.config.xaxis.labels.rotate," 0 0)"),!1):x.getTextRects(d,parseInt(s,10));var b=!c.config.xaxis.labels.showDuplicates&&this.ctx.timeScale;return!Array.isArray(d)&&(0===d.indexOf("NaN")||0===d.toLowerCase().indexOf("invalid")||d.toLowerCase().indexOf("infinity")>=0||o.indexOf(d)>=0&&b)&&(d=""),{x:n,text:d,textRect:v,isBold:p}}},{key:"checkLabelBasedOnTickamount",value:function(e,t,n){var r=this.w,i=r.config.xaxis.tickAmount;return"dataPoints"===i&&(i=Math.round(r.globals.gridWidth/120)),i>n||e%Math.round(n/(i+1))==0||(t.text=""),t}},{key:"checkForOverflowingLabels",value:function(e,t,n,r,i){var a=this.w;if(0===e&&a.globals.skipFirstTimelinelabel&&(t.text=""),e===n-1&&a.globals.skipLastTimelinelabel&&(t.text=""),a.config.xaxis.labels.hideOverlappingLabels&&r.length>0){var o=i[i.length-1];t.x0){!0===s.config.yaxis[i].opposite&&(e+=r.width);for(var u=t;u>=0;u--){var d=c+t/10+s.config.yaxis[i].labels.offsetY-1;s.globals.isBarHorizontal&&(d=a*u),"heatmap"===s.config.chart.type&&(d+=a/2);var h=l.drawLine(e+n.offsetX-r.width+r.offsetX,d+r.offsetY,e+n.offsetX+r.offsetX,d+r.offsetY,r.color);o.add(h),c+=a}}}}]),e}(),U=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"scaleSvgNode",value:function(e,t){var n=parseFloat(e.getAttributeNS(null,"width")),r=parseFloat(e.getAttributeNS(null,"height"));e.setAttributeNS(null,"width",n*t),e.setAttributeNS(null,"height",r*t),e.setAttributeNS(null,"viewBox","0 0 "+n+" "+r)}},{key:"fixSvgStringForIe11",value:function(e){if(!y.isIE11())return e.replace(/ /g," ");var t=0,n=e.replace(/xmlns="http:\/\/www.w3.org\/2000\/svg"/g,(function(e){return 2===++t?'xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.dev"':e}));return(n=n.replace(/xmlns:NS\d+=""/g,"")).replace(/NS\d+:(\w+:\w+=")/g,"$1")}},{key:"getSvgString",value:function(e){null==e&&(e=1);var t=this.w.globals.dom.Paper.svg();if(1!==e){var n=this.w.globals.dom.Paper.node.cloneNode(!0);this.scaleSvgNode(n,e),t=(new XMLSerializer).serializeToString(n)}return this.fixSvgStringForIe11(t)}},{key:"cleanup",value:function(){var e=this.w,t=e.globals.dom.baseEl.getElementsByClassName("apexcharts-xcrosshairs"),n=e.globals.dom.baseEl.getElementsByClassName("apexcharts-ycrosshairs"),r=e.globals.dom.baseEl.querySelectorAll(".apexcharts-zoom-rect, .apexcharts-selection-rect");Array.prototype.forEach.call(r,(function(e){e.setAttribute("width",0)})),t&&t[0]&&(t[0].setAttribute("x",-500),t[0].setAttribute("x1",-500),t[0].setAttribute("x2",-500)),n&&n[0]&&(n[0].setAttribute("y",-100),n[0].setAttribute("y1",-100),n[0].setAttribute("y2",-100))}},{key:"svgUrl",value:function(){this.cleanup();var e=this.getSvgString(),t=new Blob([e],{type:"image/svg+xml;charset=utf-8"});return URL.createObjectURL(t)}},{key:"dataURI",value:function(e){var t=this;return new Promise((function(n){var r=t.w,i=e?e.scale||e.width/r.globals.svgWidth:1;t.cleanup();var a=document.createElement("canvas");a.width=r.globals.svgWidth*i,a.height=parseInt(r.globals.dom.elWrap.style.height,10)*i;var o="transparent"===r.config.chart.background?"#fff":r.config.chart.background,s=a.getContext("2d");s.fillStyle=o,s.fillRect(0,0,a.width*i,a.height*i);var l=t.getSvgString(i);if(window.canvg&&y.isIE11()){var c=window.canvg.Canvg.fromString(s,l,{ignoreClear:!0,ignoreDimensions:!0});c.start();var u=a.msToBlob();c.stop(),n({blob:u})}else{var d="data:image/svg+xml,"+encodeURIComponent(l),h=new Image;h.crossOrigin="anonymous",h.onload=function(){if(s.drawImage(h,0,0),a.msToBlob){var e=a.msToBlob();n({blob:e})}else{var t=a.toDataURL("image/png");n({imgURI:t})}},h.src=d}}))}},{key:"exportToSVG",value:function(){this.triggerDownload(this.svgUrl(),this.w.config.chart.toolbar.export.svg.filename,".svg")}},{key:"exportToPng",value:function(){var e=this;this.dataURI().then((function(t){var n=t.imgURI,r=t.blob;r?navigator.msSaveOrOpenBlob(r,e.w.globals.chartID+".png"):e.triggerDownload(n,e.w.config.chart.toolbar.export.png.filename,".png")}))}},{key:"exportToCSV",value:function(e){var t=this,n=e.series,r=e.fileName,i=e.columnDelimiter,a=void 0===i?",":i,o=e.lineDelimiter,s=void 0===o?"\n":o,l=this.w;n||(n=l.config.series);var c,u,d=[],h=[],f="",p=l.globals.series.map((function(e,t){return-1===l.globals.collapsedSeriesIndices.indexOf(t)?e:[]})),g=function(e){return"datetime"===l.config.xaxis.type&&String(e).length>=10},m=Math.max.apply(Math,v(n.map((function(e){return e.data?e.data.length:0})))),x=new V(this.ctx),b=new G(this.ctx),w=function(e){var n="";if(l.globals.axisCharts){if("category"===l.config.xaxis.type||l.config.xaxis.convertedCatToNumeric)if(l.globals.isBarHorizontal){var r=l.globals.yLabelFormatters[0],i=new X(t.ctx).getActiveConfigSeriesIndex();n=r(l.globals.labels[e],{seriesIndex:i,dataPointIndex:e,w:l})}else n=b.getLabel(l.globals.labels,l.globals.timescaleLabels,0,e).text;"datetime"===l.config.xaxis.type&&(l.config.xaxis.categories.length?n=l.config.xaxis.categories[e]:l.config.labels.length&&(n=l.config.labels[e]))}else n=l.config.labels[e];return Array.isArray(n)&&(n=n.join(" ")),y.isNumber(n)?n:n.split(a).join("")};d.push(l.config.chart.toolbar.export.csv.headerCategory),"boxPlot"===l.config.chart.type?(d.push("minimum"),d.push("q1"),d.push("median"),d.push("q3"),d.push("maximum")):"candlestick"===l.config.chart.type?(d.push("open"),d.push("high"),d.push("low"),d.push("close")):"rangeBar"===l.config.chart.type?(d.push("minimum"),d.push("maximum")):n.map((function(e,t){var n=(e.name?e.name:"series-".concat(t))+"";l.globals.axisCharts&&d.push(n.split(a).join("")?n.split(a).join(""):"series-".concat(t))})),l.globals.axisCharts||(d.push(l.config.chart.toolbar.export.csv.headerValue),h.push(d.join(a))),l.globals.allSeriesHasEqualX||!l.globals.axisCharts||l.config.xaxis.categories.length||l.config.labels.length?n.map((function(e,t){l.globals.axisCharts?function(e,t){if(d.length&&0===t&&h.push(d.join(a)),e.data){e.data=e.data.length&&e.data||v(Array(m)).map((function(){return""}));for(var r=0;r0&&!r.globals.isBarHorizontal&&(this.xaxisLabels=r.globals.timescaleLabels.slice()),r.config.xaxis.overwriteCategories&&(this.xaxisLabels=r.config.xaxis.overwriteCategories),this.drawnLabels=[],this.drawnLabelsRects=[],"top"===r.config.xaxis.position?this.offY=0:this.offY=r.globals.gridHeight+1,this.offY=this.offY+r.config.xaxis.axisBorder.offsetY,this.isCategoryBarHorizontal="bar"===r.config.chart.type&&r.config.plotOptions.bar.horizontal,this.xaxisFontSize=r.config.xaxis.labels.style.fontSize,this.xaxisFontFamily=r.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=r.config.xaxis.labels.style.colors,this.xaxisBorderWidth=r.config.xaxis.axisBorder.width,this.isCategoryBarHorizontal&&(this.xaxisBorderWidth=r.config.yaxis[0].axisBorder.width.toString()),this.xaxisBorderWidth.indexOf("%")>-1?this.xaxisBorderWidth=r.globals.gridWidth*parseInt(this.xaxisBorderWidth,10)/100:this.xaxisBorderWidth=parseInt(this.xaxisBorderWidth,10),this.xaxisBorderHeight=r.config.xaxis.axisBorder.height,this.yaxis=r.config.yaxis[0]}return c(e,[{key:"drawXaxis",value:function(){var e=this.w,t=new S(this.ctx),n=t.group({class:"apexcharts-xaxis",transform:"translate(".concat(e.config.xaxis.offsetX,", ").concat(e.config.xaxis.offsetY,")")}),r=t.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(e.globals.translateXAxisX,", ").concat(e.globals.translateXAxisY,")")});n.add(r);for(var i=[],a=0;a6&&void 0!==arguments[6]?arguments[6]:{},c=[],u=[],d=this.w,h=l.xaxisFontSize||this.xaxisFontSize,f=l.xaxisFontFamily||this.xaxisFontFamily,p=l.xaxisForeColors||this.xaxisForeColors,g=l.fontWeight||d.config.xaxis.labels.style.fontWeight,m=l.cssClass||d.config.xaxis.labels.style.cssClass,v=d.globals.padHorizontal,x=r.length,b="category"===d.config.xaxis.type?d.globals.dataPoints:x;if(0===b&&x>b&&(b=x),i){var y=b>1?b-1:b;o=d.globals.gridWidth/Math.min(y,x-1),v=v+a(0,o)/2+d.config.xaxis.labels.offsetX}else o=d.globals.gridWidth/b,v=v+a(0,o)+d.config.xaxis.labels.offsetX;for(var w=function(i){var l=v-a(i,o)/2+d.config.xaxis.labels.offsetX;0===i&&1===x&&o/2===v&&1===b&&(l=d.globals.gridWidth/2);var y=s.axesUtils.getLabel(r,d.globals.timescaleLabels,l,i,c,h,e),w=28;if(d.globals.rotateXLabels&&e&&(w=22),d.config.xaxis.title.text&&"top"===d.config.xaxis.position&&(w+=parseFloat(d.config.xaxis.title.style.fontSize)+2),e||(w=w+parseFloat(h)+(d.globals.xAxisLabelsHeight-d.globals.xAxisGroupLabelsHeight)+(d.globals.rotateXLabels?10:0)),y=void 0!==d.config.xaxis.tickAmount&&"dataPoints"!==d.config.xaxis.tickAmount&&"datetime"!==d.config.xaxis.type?s.axesUtils.checkLabelBasedOnTickamount(i,y,x):s.axesUtils.checkForOverflowingLabels(i,y,x,c,u),d.config.xaxis.labels.show){var k=t.drawText({x:y.x,y:s.offY+d.config.xaxis.labels.offsetY+w-("top"===d.config.xaxis.position?d.globals.xAxisHeight+d.config.xaxis.axisTicks.height-2:0),text:y.text,textAnchor:"middle",fontWeight:y.isBold?600:g,fontSize:h,fontFamily:f,foreColor:Array.isArray(p)?e&&d.config.xaxis.convertedCatToNumeric?p[d.globals.minX+i-1]:p[i]:p,isPlainText:!1,cssClass:(e?"apexcharts-xaxis-label ":"apexcharts-xaxis-group-label ")+m});if(n.add(k),k.on("click",(function(e){if("function"==typeof d.config.chart.events.xAxisLabelClick){var t=Object.assign({},d,{labelIndex:i});d.config.chart.events.xAxisLabelClick(e,s.ctx,t)}})),e){var S=document.createElementNS(d.globals.SVGNS,"title");S.textContent=Array.isArray(y.text)?y.text.join(" "):y.text,k.node.appendChild(S),""!==y.text&&(c.push(y.text),u.push(y))}}ir.globals.gridWidth)){var a=this.offY+r.config.xaxis.axisTicks.offsetY;if(t=t+a+r.config.xaxis.axisTicks.height,"top"===r.config.xaxis.position&&(t=a-r.config.xaxis.axisTicks.height),r.config.xaxis.axisTicks.show){var o=new S(this.ctx).drawLine(e+r.config.xaxis.axisTicks.offsetX,a+r.config.xaxis.offsetY,i+r.config.xaxis.axisTicks.offsetX,t+r.config.xaxis.offsetY,r.config.xaxis.axisTicks.color);n.add(o),o.node.classList.add("apexcharts-xaxis-tick")}}}},{key:"getXAxisTicksPositions",value:function(){var e=this.w,t=[],n=this.xaxisLabels.length,r=e.globals.padHorizontal;if(e.globals.timescaleLabels.length>0)for(var i=0;i0){var c=i[i.length-1].getBBox(),u=i[0].getBBox();c.x<-20&&i[i.length-1].parentNode.removeChild(i[i.length-1]),u.x+u.width>e.globals.gridWidth&&!e.globals.isBarHorizontal&&i[0].parentNode.removeChild(i[0]);for(var d=0;d0&&(this.xaxisLabels=n.globals.timescaleLabels.slice())}return c(e,[{key:"drawGridArea",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=this.w,n=new S(this.ctx);null===e&&(e=n.group({class:"apexcharts-grid"}));var r=n.drawLine(t.globals.padHorizontal,1,t.globals.padHorizontal,t.globals.gridHeight,"transparent"),i=n.drawLine(t.globals.padHorizontal,t.globals.gridHeight,t.globals.gridWidth,t.globals.gridHeight,"transparent");return e.add(i),e.add(r),e}},{key:"drawGrid",value:function(){var e=null;return this.w.globals.axisCharts&&(e=this.renderGrid(),this.drawGridArea(e.el)),e}},{key:"createGridMask",value:function(){var e=this.w,t=e.globals,n=new S(this.ctx),r=Array.isArray(e.config.stroke.width)?0:e.config.stroke.width;if(Array.isArray(e.config.stroke.width)){var i=0;e.config.stroke.width.forEach((function(e){i=Math.max(i,e)})),r=i}t.dom.elGridRectMask=document.createElementNS(t.SVGNS,"clipPath"),t.dom.elGridRectMask.setAttribute("id","gridRectMask".concat(t.cuid)),t.dom.elGridRectMarkerMask=document.createElementNS(t.SVGNS,"clipPath"),t.dom.elGridRectMarkerMask.setAttribute("id","gridRectMarkerMask".concat(t.cuid)),t.dom.elForecastMask=document.createElementNS(t.SVGNS,"clipPath"),t.dom.elForecastMask.setAttribute("id","forecastMask".concat(t.cuid)),t.dom.elNonForecastMask=document.createElementNS(t.SVGNS,"clipPath"),t.dom.elNonForecastMask.setAttribute("id","nonForecastMask".concat(t.cuid));var a=e.config.chart.type,o=0,s=0;("bar"===a||"rangeBar"===a||"candlestick"===a||"boxPlot"===a||e.globals.comboBarCount>0)&&e.globals.isXNumeric&&!e.globals.isBarHorizontal&&(o=e.config.grid.padding.left,s=e.config.grid.padding.right,t.barPadForNumericAxis>o&&(o=t.barPadForNumericAxis,s=t.barPadForNumericAxis)),t.dom.elGridRect=n.drawRect(-r-o-2,2*-r-2,t.gridWidth+r+s+o+4,t.gridHeight+4*r+4,0,"#fff");var l=e.globals.markers.largestSize+1;t.dom.elGridRectMarker=n.drawRect(2*-l,2*-l,t.gridWidth+4*l,t.gridHeight+4*l,0,"#fff"),t.dom.elGridRectMask.appendChild(t.dom.elGridRect.node),t.dom.elGridRectMarkerMask.appendChild(t.dom.elGridRectMarker.node);var c=t.dom.baseEl.querySelector("defs");c.appendChild(t.dom.elGridRectMask),c.appendChild(t.dom.elForecastMask),c.appendChild(t.dom.elNonForecastMask),c.appendChild(t.dom.elGridRectMarkerMask)}},{key:"_drawGridLines",value:function(e){var t=e.i,n=e.x1,r=e.y1,i=e.x2,a=e.y2,o=e.xCount,s=e.parent,l=this.w;if(!(0===t&&l.globals.skipFirstTimelinelabel||t===o-1&&l.globals.skipLastTimelinelabel&&!l.config.xaxis.labels.formatter||"radar"===l.config.chart.type)){l.config.grid.xaxis.lines.show&&this._drawGridLine({i:t,x1:n,y1:r,x2:i,y2:a,xCount:o,parent:s});var c=0;if(l.globals.hasXaxisGroups&&"between"===l.config.xaxis.tickPlacement){var u=l.globals.groups;if(u){for(var d=0,h=0;d2));s++);!r.globals.isBarHorizontal||this.isRangeBar?(a=this.xaxisLabels.length,this.isRangeBar&&(a--,o=r.globals.labels.length,r.config.xaxis.tickAmount&&r.config.xaxis.labels.formatter&&(a=r.config.xaxis.tickAmount),(null===(e=r.globals.yAxisScale)||void 0===e||null===(t=e[0])||void 0===t||null===(n=t.result)||void 0===n?void 0:n.length)>0&&"datetime"!==r.config.xaxis.type&&(a=r.globals.yAxisScale[0].result.length-1)),this._drawXYLines({xCount:a,tickAmount:o})):(a=o,o=r.globals.xTickAmount,this._drawInvertedXYLines({xCount:a,tickAmount:o}));return this.drawGridBands(a,o),{el:this.elg,elGridBorders:this.elGridBorders,xAxisTickWidth:r.globals.gridWidth/a}}},{key:"drawGridBands",value:function(e,t){var n=this.w;if(void 0!==n.config.grid.row.colors&&n.config.grid.row.colors.length>0)for(var r=0,i=n.globals.gridHeight/t,a=n.globals.gridWidth,o=0,s=0;o=n.config.grid.row.colors.length&&(s=0),this._drawGridBandRect({c:s,x1:0,y1:r,x2:a,y2:i,type:"row"}),r+=n.globals.gridHeight/t;if(void 0!==n.config.grid.column.colors&&n.config.grid.column.colors.length>0)for(var l=n.globals.isBarHorizontal||"on"!==n.config.xaxis.tickPlacement||"category"!==n.config.xaxis.type&&!n.config.xaxis.convertedCatToNumeric?e:e-1,c=n.globals.padHorizontal,u=n.globals.padHorizontal+n.globals.gridWidth/l,d=n.globals.gridHeight,h=0,f=0;h=n.config.grid.column.colors.length&&(f=0),this._drawGridBandRect({c:f,x1:c,y1:0,x2:u,y2:d,type:"column"}),c+=n.globals.gridWidth/l}}]),e}(),$=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"niceScale",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4?arguments[4]:void 0,a=this.w,o=Math.abs(t-e);if("dataPoints"===(n=this._adjustTicksForSmallRange(n,r,o))&&(n=a.globals.dataPoints-1),e===Number.MIN_VALUE&&0===t||!y.isNumber(e)&&!y.isNumber(t)||e===Number.MIN_VALUE&&t===-Number.MAX_VALUE)return e=0,t=n,this.linearScale(e,t,n,r,a.config.yaxis[r].stepSize);e>t?(console.warn("axis.min cannot be greater than axis.max"),t=e+.1):e===t&&(e=0===e?0:e-.5,t=0===t?2:t+.5);var s=[];o<1&&i&&("candlestick"===a.config.chart.type||"candlestick"===a.config.series[r].type||"boxPlot"===a.config.chart.type||"boxPlot"===a.config.series[r].type||a.globals.isRangeData)&&(t*=1.01);var l=n+1;l<2?l=2:l>2&&(l-=2);var c=o/l,u=Math.floor(y.log10(c)),d=Math.pow(10,u),h=Math.round(c/d);h<1&&(h=1);var f=h*d;a.config.yaxis[r].stepSize&&(f=a.config.yaxis[r].stepSize),a.globals.isBarHorizontal&&a.config.xaxis.stepSize&&"datetime"!==a.config.xaxis.type&&(f=a.config.xaxis.stepSize);var p=f*Math.floor(e/f),g=f*Math.ceil(t/f),m=p;if(i&&o>2){for(;s.push(y.stripNumber(m,7)),!((m+=f)>g););return{result:s,niceMin:s[0],niceMax:s[s.length-1]}}var v=e;(s=[]).push(y.stripNumber(v,7));for(var x=Math.abs(t-e)/n,b=0;b<=n;b++)v+=x,s.push(v);return s[s.length-2]>=t&&s.pop(),{result:s,niceMin:s[0],niceMax:s[s.length-1]}}},{key:"linearScale",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0,a=Math.abs(t-e);"dataPoints"===(n=this._adjustTicksForSmallRange(n,r,a))&&(n=this.w.globals.dataPoints-1),i||(i=a/n),n===Number.MAX_VALUE&&(n=5,i=1);for(var o=[],s=e;n>=0;)o.push(s),s+=i,n-=1;return{result:o,niceMin:o[0],niceMax:o[o.length-1]}}},{key:"logarithmicScaleNice",value:function(e,t,n){t<=0&&(t=Math.max(e,n)),e<=0&&(e=Math.min(t,n));for(var r=[],i=Math.ceil(Math.log(t)/Math.log(n)+1),a=Math.floor(Math.log(e)/Math.log(n));a5)r.allSeriesCollapsed=!1,r.yAxisScale[e]=this.logarithmicScale(t,n,a.logBase),r.yAxisScale[e]=a.forceNiceScale?this.logarithmicScaleNice(t,n,a.logBase):this.logarithmicScale(t,n,a.logBase);else if(n!==-Number.MAX_VALUE&&y.isNumber(n))if(r.allSeriesCollapsed=!1,void 0===a.min&&void 0===a.max||a.forceNiceScale){var s=void 0===i.yaxis[e].max&&void 0===i.yaxis[e].min||i.yaxis[e].forceNiceScale;r.yAxisScale[e]=this.niceScale(t,n,a.tickAmount?a.tickAmount:o<5&&o>1?o+1:5,e,s)}else r.yAxisScale[e]=this.linearScale(t,n,a.tickAmount,e,i.yaxis[e].stepSize);else r.yAxisScale[e]=this.linearScale(0,5,5,e,i.yaxis[e].stepSize)}},{key:"setXScale",value:function(e,t){var n=this.w,r=n.globals,i=Math.abs(t-e);return t!==-Number.MAX_VALUE&&y.isNumber(t)?r.xAxisScale=this.linearScale(e,t,n.config.xaxis.tickAmount?n.config.xaxis.tickAmount:i<5&&i>1?i+1:5,0,n.config.xaxis.stepSize):r.xAxisScale=this.linearScale(0,5,5),r.xAxisScale}},{key:"setMultipleYScales",value:function(){var e=this,t=this.w.globals,n=this.w.config,r=t.minYArr.concat([]),i=t.maxYArr.concat([]),a=[];n.yaxis.forEach((function(t,o){var s=o;n.series.forEach((function(e,n){e.name===t.seriesName&&(s=n,o!==n?a.push({index:n,similarIndex:o,alreadyExists:!0}):a.push({index:n}))}));var l=r[s],c=i[s];e.setYScaleForIndex(o,l,c)})),this.sameScaleInMultipleAxes(r,i,a)}},{key:"sameScaleInMultipleAxes",value:function(e,t,n){var r=this,i=this.w.config,a=this.w.globals,o=[];n.forEach((function(e){e.alreadyExists&&(void 0===o[e.index]&&(o[e.index]=[]),o[e.index].push(e.index),o[e.index].push(e.similarIndex))})),a.yAxisSameScaleIndices=o,o.forEach((function(e,t){o.forEach((function(n,r){var i,a;t!==r&&(i=e,a=n,i.filter((function(e){return-1!==a.indexOf(e)}))).length>0&&(o[t]=o[t].concat(o[r]))}))}));var s=o.map((function(e){return e.filter((function(t,n){return e.indexOf(t)===n}))})).map((function(e){return e.sort()}));o=o.filter((function(e){return!!e}));var l=s.slice(),c=l.map((function(e){return JSON.stringify(e)}));l=l.filter((function(e,t){return c.indexOf(JSON.stringify(e))===t}));var u=[],d=[];e.forEach((function(e,n){l.forEach((function(r,i){r.indexOf(n)>-1&&(void 0===u[i]&&(u[i]=[],d[i]=[]),u[i].push({key:n,value:e}),d[i].push({key:n,value:t[n]}))}))}));var h=Array.apply(null,Array(l.length)).map(Number.prototype.valueOf,Number.MIN_VALUE),f=Array.apply(null,Array(l.length)).map(Number.prototype.valueOf,-Number.MAX_VALUE);u.forEach((function(e,t){e.forEach((function(e,n){h[t]=Math.min(e.value,h[t])}))})),d.forEach((function(e,t){e.forEach((function(e,n){f[t]=Math.max(e.value,f[t])}))})),e.forEach((function(e,t){d.forEach((function(e,n){var o=h[n],s=f[n];i.chart.stacked&&(s=0,e.forEach((function(e,t){e.value!==-Number.MAX_VALUE&&(s+=e.value),o!==Number.MIN_VALUE&&(o+=u[n][t].value)}))),e.forEach((function(n,l){e[l].key===t&&(void 0!==i.yaxis[t].min&&(o="function"==typeof i.yaxis[t].min?i.yaxis[t].min(a.minY):i.yaxis[t].min),void 0!==i.yaxis[t].max&&(s="function"==typeof i.yaxis[t].max?i.yaxis[t].max(a.maxY):i.yaxis[t].max),r.setYScaleForIndex(t,o,s))}))}))}))}},{key:"autoScaleY",value:function(e,t,n){e||(e=this);var r=e.w;if(r.globals.isMultipleYAxis||r.globals.collapsedSeries.length)return console.warn("autoScaleYaxis not supported in a multi-yaxis chart."),t;var i=r.globals.seriesX[0],a=r.config.chart.stacked;return t.forEach((function(e,o){for(var s=0,l=0;l=n.xaxis.min){s=l;break}var c,u,d=r.globals.minYArr[o],h=r.globals.maxYArr[o],f=r.globals.stackedSeriesTotals;r.globals.series.forEach((function(o,l){var p=o[s];a?(p=f[s],c=u=p,f.forEach((function(e,t){i[t]<=n.xaxis.max&&i[t]>=n.xaxis.min&&(e>u&&null!==e&&(u=e),o[t]=n.xaxis.min){var a=e,o=e;r.globals.series.forEach((function(n,r){null!==e&&(a=Math.min(n[t],a),o=Math.max(n[t],o))})),o>u&&null!==o&&(u=o),ad&&(c=d),t.length>1?(t[l].min=void 0===e.min?c:e.min,t[l].max=void 0===e.max?u:e.max):(t[0].min=void 0===e.min?c:e.min,t[0].max=void 0===e.max?u:e.max)}))})),t}}]),e}(),Q=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.scales=new $(t)}return c(e,[{key:"init",value:function(){this.setYRange(),this.setXRange(),this.setZRange()}},{key:"getMinYMaxY",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:-Number.MAX_VALUE,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=this.w.config,a=this.w.globals,o=-Number.MAX_VALUE,s=Number.MIN_VALUE;null===r&&(r=e+1);var l=a.series,c=l,u=l;"candlestick"===i.chart.type?(c=a.seriesCandleL,u=a.seriesCandleH):"boxPlot"===i.chart.type?(c=a.seriesCandleO,u=a.seriesCandleC):a.isRangeData&&(c=a.seriesRangeStart,u=a.seriesRangeEnd);for(var d=e;dc[d][h]&&c[d][h]<0&&(s=c[d][h])):a.hasNullValues=!0}}return"rangeBar"===i.chart.type&&a.seriesRangeStart.length&&a.isBarHorizontal&&(s=t),"bar"===i.chart.type&&(s<0&&o<0&&(o=0),s===Number.MIN_VALUE&&(s=0)),{minY:s,maxY:o,lowestY:t,highestY:n}}},{key:"setYRange",value:function(){var e=this.w.globals,t=this.w.config;e.maxY=-Number.MAX_VALUE,e.minY=Number.MIN_VALUE;var n=Number.MAX_VALUE;if(e.isMultipleYAxis)for(var r=0;r=0&&n<=10||void 0!==t.yaxis[0].min||void 0!==t.yaxis[0].max)&&(o=0),e.minY=n-5*o/100,n>0&&e.minY<0&&(e.minY=0),e.maxY=e.maxY+5*o/100}return t.yaxis.forEach((function(t,n){void 0!==t.max&&("number"==typeof t.max?e.maxYArr[n]=t.max:"function"==typeof t.max&&(e.maxYArr[n]=t.max(e.isMultipleYAxis?e.maxYArr[n]:e.maxY)),e.maxY=e.maxYArr[n]),void 0!==t.min&&("number"==typeof t.min?e.minYArr[n]=t.min:"function"==typeof t.min&&(e.minYArr[n]=t.min(e.isMultipleYAxis?e.minYArr[n]===Number.MIN_VALUE?0:e.minYArr[n]:e.minY)),e.minY=e.minYArr[n])})),e.isBarHorizontal&&["min","max"].forEach((function(n){void 0!==t.xaxis[n]&&"number"==typeof t.xaxis[n]&&("min"===n?e.minY=t.xaxis[n]:e.maxY=t.xaxis[n])})),e.isMultipleYAxis?(this.scales.setMultipleYScales(),e.minY=n,e.yAxisScale.forEach((function(t,n){e.minYArr[n]=t.niceMin,e.maxYArr[n]=t.niceMax}))):(this.scales.setYScaleForIndex(0,e.minY,e.maxY),e.minY=e.yAxisScale[0].niceMin,e.maxY=e.yAxisScale[0].niceMax,e.minYArr[0]=e.yAxisScale[0].niceMin,e.maxYArr[0]=e.yAxisScale[0].niceMax),{minY:e.minY,maxY:e.maxY,minYArr:e.minYArr,maxYArr:e.maxYArr,yAxisScale:e.yAxisScale}}},{key:"setXRange",value:function(){var e=this.w.globals,t=this.w.config,n="numeric"===t.xaxis.type||"datetime"===t.xaxis.type||"category"===t.xaxis.type&&!e.noLabelsProvided||e.noLabelsProvided||e.isXNumeric;if(e.isXNumeric&&function(){for(var t=0;te.dataPoints&&0!==e.dataPoints&&(r=e.dataPoints-1)):"dataPoints"===t.xaxis.tickAmount?(e.series.length>1&&(r=e.series[e.maxValsInArrayIndex].length-1),e.isXNumeric&&(r=e.maxX-e.minX-1)):r=t.xaxis.tickAmount,e.xTickAmount=r,void 0!==t.xaxis.max&&"number"==typeof t.xaxis.max&&(e.maxX=t.xaxis.max),void 0!==t.xaxis.min&&"number"==typeof t.xaxis.min&&(e.minX=t.xaxis.min),void 0!==t.xaxis.range&&(e.minX=e.maxX-t.xaxis.range),e.minX!==Number.MAX_VALUE&&e.maxX!==-Number.MAX_VALUE)if(t.xaxis.convertedCatToNumeric&&!e.dataFormatXNumeric){for(var i=[],a=e.minX-1;a0&&(e.xAxisScale=this.scales.linearScale(1,e.labels.length,r-1,0,t.xaxis.stepSize),e.seriesX=e.labels.slice());n&&(e.labels=e.xAxisScale.result.slice())}return e.isBarHorizontal&&e.labels.length&&(e.xTickAmount=e.labels.length),this._handleSingleDataPoint(),this._getMinXDiff(),{minX:e.minX,maxX:e.maxX}}},{key:"setZRange",value:function(){var e=this.w.globals;if(e.isDataXYZ)for(var t=0;t0){var i=t-r[n-1];i>0&&(e.minXDiff=Math.min(i,e.minXDiff))}})),1!==e.dataPoints&&e.minXDiff!==Number.MAX_VALUE||(e.minXDiff=.5)}))}},{key:"_setStackedMinMax",value:function(){var e=this,t=this.w.globals;if(t.series.length){var n=t.seriesGroups;n.length||(n=[this.w.config.series.map((function(e){return e.name}))]);var r={},i={};n.forEach((function(n){r[n]=[],i[n]=[],e.w.config.series.map((function(e,t){return n.indexOf(e.name)>-1?t:null})).filter((function(e){return null!==e})).forEach((function(a){for(var o=0;o0?r[n][o]+=parseFloat(t.series[a][o])+1e-4:i[n][o]+=parseFloat(t.series[a][o]))}}))})),Object.entries(r).forEach((function(e){var n=m(e,1)[0];r[n].forEach((function(e,a){t.maxY=Math.max(t.maxY,r[n][a]),t.minY=Math.min(t.minY,i[n][a])}))}))}}}]),e}(),K=function(){function e(t,n){s(this,e),this.ctx=t,this.elgrid=n,this.w=t.w;var r=this.w;this.xaxisFontSize=r.config.xaxis.labels.style.fontSize,this.axisFontFamily=r.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=r.config.xaxis.labels.style.colors,this.isCategoryBarHorizontal="bar"===r.config.chart.type&&r.config.plotOptions.bar.horizontal,this.xAxisoffX=0,"bottom"===r.config.xaxis.position&&(this.xAxisoffX=r.globals.gridHeight),this.drawnLabels=[],this.axesUtils=new G(t)}return c(e,[{key:"drawYaxis",value:function(e){var t=this,n=this.w,r=new S(this.ctx),i=n.config.yaxis[e].labels.style,a=i.fontSize,o=i.fontFamily,s=i.fontWeight,l=r.group({class:"apexcharts-yaxis",rel:e,transform:"translate("+n.globals.translateYAxisX[e]+", 0)"});if(this.axesUtils.isYAxisHidden(e))return l;var c=r.group({class:"apexcharts-yaxis-texts-g"});l.add(c);var u=n.globals.yAxisScale[e].result.length-1,d=n.globals.gridHeight/u,h=n.globals.translateY,f=n.globals.yLabelFormatters[e],p=n.globals.yAxisScale[e].result.slice();p=this.axesUtils.checkForReversedLabels(e,p);var g="";if(n.config.yaxis[e].labels.show)for(var m=function(l){var m=p[l];m=f(m,l,n);var v=n.config.yaxis[e].labels.padding;n.config.yaxis[e].opposite&&0!==n.config.yaxis.length&&(v*=-1);var x="end";n.config.yaxis[e].opposite&&(x="start"),"left"===n.config.yaxis[e].labels.align?x="start":"center"===n.config.yaxis[e].labels.align?x="middle":"right"===n.config.yaxis[e].labels.align&&(x="end");var b=t.axesUtils.getYAxisForeColor(i.colors,e),y=n.config.yaxis[e].labels.offsetY;"heatmap"===n.config.chart.type&&(y-=(n.globals.gridHeight/n.globals.series.length-1)/2);var w=r.drawText({x:v,y:h+u/10+y+1,text:m,textAnchor:x,fontSize:a,fontFamily:o,fontWeight:s,maxWidth:n.config.yaxis[e].labels.maxWidth,foreColor:Array.isArray(b)?b[l]:b,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+i.cssClass});l===u&&(g=w),c.add(w);var k=document.createElementNS(n.globals.SVGNS,"title");if(k.textContent=Array.isArray(m)?m.join(" "):m,w.node.appendChild(k),0!==n.config.yaxis[e].labels.rotate){var S=r.rotateAroundCenter(g.node),C=r.rotateAroundCenter(w.node);w.node.setAttribute("transform","rotate(".concat(n.config.yaxis[e].labels.rotate," ").concat(S.x," ").concat(C.y,")"))}h+=d},v=u;v>=0;v--)m(v);if(void 0!==n.config.yaxis[e].title.text){var x=r.group({class:"apexcharts-yaxis-title"}),b=0;n.config.yaxis[e].opposite&&(b=n.globals.translateYAxisX[e]);var y=r.drawText({x:b,y:n.globals.gridHeight/2+n.globals.translateY+n.config.yaxis[e].title.offsetY,text:n.config.yaxis[e].title.text,textAnchor:"end",foreColor:n.config.yaxis[e].title.style.color,fontSize:n.config.yaxis[e].title.style.fontSize,fontWeight:n.config.yaxis[e].title.style.fontWeight,fontFamily:n.config.yaxis[e].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+n.config.yaxis[e].title.style.cssClass});x.add(y),l.add(x)}var w=n.config.yaxis[e].axisBorder,k=31+w.offsetX;if(n.config.yaxis[e].opposite&&(k=-31-w.offsetX),w.show){var C=r.drawLine(k,n.globals.translateY+w.offsetY-2,k,n.globals.gridHeight+n.globals.translateY+w.offsetY+2,w.color,0,w.width);l.add(C)}return n.config.yaxis[e].axisTicks.show&&this.axesUtils.drawYAxisTicks(k,u,w,n.config.yaxis[e].axisTicks,e,d,l),l}},{key:"drawYaxisInversed",value:function(e){var t=this.w,n=new S(this.ctx),r=n.group({class:"apexcharts-xaxis apexcharts-yaxis-inversed"}),i=n.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(t.globals.translateXAxisX,", ").concat(t.globals.translateXAxisY,")")});r.add(i);var a=t.globals.yAxisScale[e].result.length-1,o=t.globals.gridWidth/a+.1,s=o+t.config.xaxis.labels.offsetX,l=t.globals.xLabelFormatter,c=t.globals.yAxisScale[e].result.slice(),u=t.globals.timescaleLabels;u.length>0&&(this.xaxisLabels=u.slice(),a=(c=u.slice()).length),c=this.axesUtils.checkForReversedLabels(e,c);var d=u.length;if(t.config.xaxis.labels.show)for(var h=d?0:a;d?h=0;d?h++:h--){var f=c[h];f=l(f,h,t);var p=t.globals.gridWidth+t.globals.padHorizontal-(s-o+t.config.xaxis.labels.offsetX);if(u.length){var g=this.axesUtils.getLabel(c,u,p,h,this.drawnLabels,this.xaxisFontSize);p=g.x,f=g.text,this.drawnLabels.push(g.text),0===h&&t.globals.skipFirstTimelinelabel&&(f=""),h===c.length-1&&t.globals.skipLastTimelinelabel&&(f="")}var m=n.drawText({x:p,y:this.xAxisoffX+t.config.xaxis.labels.offsetY+30-("top"===t.config.xaxis.position?t.globals.xAxisHeight+t.config.xaxis.axisTicks.height-2:0),text:f,textAnchor:"middle",foreColor:Array.isArray(this.xaxisForeColors)?this.xaxisForeColors[e]:this.xaxisForeColors,fontSize:this.xaxisFontSize,fontFamily:this.xaxisFontFamily,fontWeight:t.config.xaxis.labels.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-xaxis-label "+t.config.xaxis.labels.style.cssClass});i.add(m),m.tspan(f);var v=document.createElementNS(t.globals.SVGNS,"title");v.textContent=f,m.node.appendChild(v),s+=o}return this.inversedYAxisTitleText(r),this.inversedYAxisBorder(r),r}},{key:"inversedYAxisBorder",value:function(e){var t=this.w,n=new S(this.ctx),r=t.config.xaxis.axisBorder;if(r.show){var i=0;"bar"===t.config.chart.type&&t.globals.isXNumeric&&(i-=15);var a=n.drawLine(t.globals.padHorizontal+i+r.offsetX,this.xAxisoffX,t.globals.gridWidth,this.xAxisoffX,r.color,0,r.height);this.elgrid&&this.elgrid.elGridBorders&&t.config.grid.show?this.elgrid.elGridBorders.add(a):e.add(a)}}},{key:"inversedYAxisTitleText",value:function(e){var t=this.w,n=new S(this.ctx);if(void 0!==t.config.xaxis.title.text){var r=n.group({class:"apexcharts-xaxis-title apexcharts-yaxis-title-inversed"}),i=n.drawText({x:t.globals.gridWidth/2+t.config.xaxis.title.offsetX,y:this.xAxisoffX+parseFloat(this.xaxisFontSize)+parseFloat(t.config.xaxis.title.style.fontSize)+t.config.xaxis.title.offsetY+20,text:t.config.xaxis.title.text,textAnchor:"middle",fontSize:t.config.xaxis.title.style.fontSize,fontFamily:t.config.xaxis.title.style.fontFamily,fontWeight:t.config.xaxis.title.style.fontWeight,foreColor:t.config.xaxis.title.style.color,cssClass:"apexcharts-xaxis-title-text "+t.config.xaxis.title.style.cssClass});r.add(i),e.add(r)}}},{key:"yAxisTitleRotate",value:function(e,t){var n=this.w,r=new S(this.ctx),i={width:0,height:0},a={width:0,height:0},o=n.globals.dom.baseEl.querySelector(" .apexcharts-yaxis[rel='".concat(e,"'] .apexcharts-yaxis-texts-g"));null!==o&&(i=o.getBoundingClientRect());var s=n.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(e,"'] .apexcharts-yaxis-title text"));if(null!==s&&(a=s.getBoundingClientRect()),null!==s){var l=this.xPaddingForYAxisTitle(e,i,a,t);s.setAttribute("x",l.xPos-(t?10:0))}if(null!==s){var c=r.rotateAroundCenter(s);s.setAttribute("transform","rotate(".concat(t?-1*n.config.yaxis[e].title.rotate:n.config.yaxis[e].title.rotate," ").concat(c.x," ").concat(c.y,")"))}}},{key:"xPaddingForYAxisTitle",value:function(e,t,n,r){var i=this.w,a=0,o=0,s=10;return void 0===i.config.yaxis[e].title.text||e<0?{xPos:o,padd:0}:(r?(o=t.width+i.config.yaxis[e].title.offsetX+n.width/2+s/2,0===(a+=1)&&(o-=s/2)):(o=-1*t.width+i.config.yaxis[e].title.offsetX+s/2+n.width/2,i.globals.isBarHorizontal&&(s=25,o=-1*t.width-i.config.yaxis[e].title.offsetX-s)),{xPos:o,padd:s})}},{key:"setYAxisXPosition",value:function(e,t){var n=this.w,r=0,i=0,a=18,o=1;n.config.yaxis.length>1&&(this.multipleYs=!0),n.config.yaxis.map((function(s,l){var c=n.globals.ignoreYAxisIndexes.indexOf(l)>-1||!s.show||s.floating||0===e[l].width,u=e[l].width+t[l].width;s.opposite?n.globals.isBarHorizontal?(i=n.globals.gridWidth+n.globals.translateX-1,n.globals.translateYAxisX[l]=i-s.labels.offsetX):(i=n.globals.gridWidth+n.globals.translateX+o,c||(o=o+u+20),n.globals.translateYAxisX[l]=i-s.labels.offsetX+20):(r=n.globals.translateX-a,c||(a=a+u+20),n.globals.translateYAxisX[l]=r+s.labels.offsetX)}))}},{key:"setYAxisTextAlignments",value:function(){var e=this.w,t=e.globals.dom.baseEl.getElementsByClassName("apexcharts-yaxis");(t=y.listToArray(t)).forEach((function(t,n){var r=e.config.yaxis[n];if(r&&!r.floating&&void 0!==r.labels.align){var i=e.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(n,"'] .apexcharts-yaxis-texts-g")),a=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(n,"'] .apexcharts-yaxis-label"));a=y.listToArray(a);var o=i.getBoundingClientRect();"left"===r.labels.align?(a.forEach((function(e,t){e.setAttribute("text-anchor","start")})),r.opposite||i.setAttribute("transform","translate(-".concat(o.width,", 0)"))):"center"===r.labels.align?(a.forEach((function(e,t){e.setAttribute("text-anchor","middle")})),i.setAttribute("transform","translate(".concat(o.width/2*(r.opposite?1:-1),", 0)"))):"right"===r.labels.align&&(a.forEach((function(e,t){e.setAttribute("text-anchor","end")})),r.opposite&&i.setAttribute("transform","translate(".concat(o.width,", 0)")))}}))}}]),e}(),J=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.documentEvent=y.bind(this.documentEvent,this)}return c(e,[{key:"addEventListener",value:function(e,t){var n=this.w;n.globals.events.hasOwnProperty(e)?n.globals.events[e].push(t):n.globals.events[e]=[t]}},{key:"removeEventListener",value:function(e,t){var n=this.w;if(n.globals.events.hasOwnProperty(e)){var r=n.globals.events[e].indexOf(t);-1!==r&&n.globals.events[e].splice(r,1)}}},{key:"fireEvent",value:function(e,t){var n=this.w;if(n.globals.events.hasOwnProperty(e)){t&&t.length||(t=[]);for(var r=n.globals.events[e],i=r.length,a=0;a0&&(t=this.w.config.chart.locales.concat(window.Apex.chart.locales));var n=t.filter((function(t){return t.name===e}))[0];if(!n)throw new Error("Wrong locale name provided. Please make sure you set the correct locale name in options");var r=y.extend(M,n);this.w.globals.locale=r.options}}]),e}(),te=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"drawAxis",value:function(e,t){var n,r,i=this,a=this.w.globals,o=this.w.config,s=new Z(this.ctx,t),l=new K(this.ctx,t);a.axisCharts&&"radar"!==e&&(a.isBarHorizontal?(r=l.drawYaxisInversed(0),n=s.drawXaxisInversed(0),a.dom.elGraphical.add(n),a.dom.elGraphical.add(r)):(n=s.drawXaxis(),a.dom.elGraphical.add(n),o.yaxis.map((function(e,t){if(-1===a.ignoreYAxisIndexes.indexOf(t)&&(r=l.drawYaxis(t),a.dom.Paper.add(r),"back"===i.w.config.grid.position)){var n=a.dom.Paper.children()[1];n.remove(),a.dom.Paper.add(n)}}))))}}]),e}(),ne=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"drawXCrosshairs",value:function(){var e=this.w,t=new S(this.ctx),n=new k(this.ctx),r=e.config.xaxis.crosshairs.fill.gradient,i=e.config.xaxis.crosshairs.dropShadow,a=e.config.xaxis.crosshairs.fill.type,o=r.colorFrom,s=r.colorTo,l=r.opacityFrom,c=r.opacityTo,u=r.stops,d=i.enabled,h=i.left,f=i.top,p=i.blur,g=i.color,m=i.opacity,v=e.config.xaxis.crosshairs.fill.color;if(e.config.xaxis.crosshairs.show){"gradient"===a&&(v=t.drawGradient("vertical",o,s,l,c,null,u,null));var x=t.drawRect();1===e.config.xaxis.crosshairs.width&&(x=t.drawLine());var b=e.globals.gridHeight;(!y.isNumber(b)||b<0)&&(b=0);var w=e.config.xaxis.crosshairs.width;(!y.isNumber(w)||w<0)&&(w=0),x.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:b,width:w,height:b,fill:v,filter:"none","fill-opacity":e.config.xaxis.crosshairs.opacity,stroke:e.config.xaxis.crosshairs.stroke.color,"stroke-width":e.config.xaxis.crosshairs.stroke.width,"stroke-dasharray":e.config.xaxis.crosshairs.stroke.dashArray}),d&&(x=n.dropShadow(x,{left:h,top:f,blur:p,color:g,opacity:m})),e.globals.dom.elGraphical.add(x)}}},{key:"drawYCrosshairs",value:function(){var e=this.w,t=new S(this.ctx),n=e.config.yaxis[0].crosshairs,r=e.globals.barPadForNumericAxis;if(e.config.yaxis[0].crosshairs.show){var i=t.drawLine(-r,0,e.globals.gridWidth+r,0,n.stroke.color,n.stroke.dashArray,n.stroke.width);i.attr({class:"apexcharts-ycrosshairs"}),e.globals.dom.elGraphical.add(i)}var a=t.drawLine(-r,0,e.globals.gridWidth+r,0,n.stroke.color,0,0);a.attr({class:"apexcharts-ycrosshairs-hidden"}),e.globals.dom.elGraphical.add(a)}}]),e}(),re=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"checkResponsiveConfig",value:function(e){var t=this,n=this.w,r=n.config;if(0!==r.responsive.length){var i=r.responsive.slice();i.sort((function(e,t){return e.breakpoint>t.breakpoint?1:t.breakpoint>e.breakpoint?-1:0})).reverse();var a=new F({}),o=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=i[0].breakpoint,o=window.innerWidth>0?window.innerWidth:screen.width;if(o>r){var s=C.extendArrayProps(a,n.globals.initialConfig,n);e=y.extend(s,e),e=y.extend(n.config,e),t.overrideResponsiveOptions(e)}else for(var l=0;l0&&"function"==typeof n.config.colors[0]&&(n.globals.colors=n.config.series.map((function(e,r){var i=n.config.colors[r];return i||(i=n.config.colors[0]),"function"==typeof i?(t.isColorFn=!0,i({value:n.globals.axisCharts?n.globals.series[r][0]?n.globals.series[r][0]:0:n.globals.series[r],seriesIndex:r,dataPointIndex:r,w:n})):i})))),n.globals.seriesColors.map((function(e,t){e&&(n.globals.colors[t]=e)})),n.config.theme.monochrome.enabled){var i=[],a=n.globals.series.length;(this.isBarDistributed||this.isHeatmapDistributed)&&(a=n.globals.series[0].length*n.globals.series.length);for(var o=n.config.theme.monochrome.color,s=1/(a/n.config.theme.monochrome.shadeIntensity),l=n.config.theme.monochrome.shadeTo,c=0,u=0;u2&&void 0!==arguments[2]?arguments[2]:null,r=this.w,i=t||r.globals.series.length;if(null===n&&(n=this.isBarDistributed||this.isHeatmapDistributed||"heatmap"===r.config.chart.type&&r.config.plotOptions.heatmap.colorScale.inverse),n&&r.globals.series.length&&(i=r.globals.series[r.globals.maxValsInArrayIndex].length*r.globals.series.length),e.lengthe.globals.svgWidth&&(this.dCtx.lgRect.width=e.globals.svgWidth/1.5),this.dCtx.lgRect}},{key:"getLargestStringFromMultiArr",value:function(e,t){var n=e;if(this.w.globals.isMultiLineX){var r=t.map((function(e,t){return Array.isArray(e)?e.length:1})),i=Math.max.apply(Math,v(r));n=t[r.indexOf(i)]}return n}}]),e}(),se=function(){function e(t){s(this,e),this.w=t.w,this.dCtx=t}return c(e,[{key:"getxAxisLabelsCoords",value:function(){var e,t=this.w,n=t.globals.labels.slice();if(t.config.xaxis.convertedCatToNumeric&&0===n.length&&(n=t.globals.categoryLabels),t.globals.timescaleLabels.length>0){var r=this.getxAxisTimeScaleLabelsCoords();e={width:r.width,height:r.height},t.globals.rotateXLabels=!1}else{this.dCtx.lgWidthForSideLegends="left"!==t.config.legend.position&&"right"!==t.config.legend.position||t.config.legend.floating?0:this.dCtx.lgRect.width;var i=t.globals.xLabelFormatter,a=y.getLargestStringFromArr(n),o=this.dCtx.dimHelpers.getLargestStringFromMultiArr(a,n);t.globals.isBarHorizontal&&(o=a=t.globals.yAxisScale[0].result.reduce((function(e,t){return e.length>t.length?e:t}),0));var s=new I(this.dCtx.ctx),l=a;a=s.xLabelFormat(i,a,l,{i:void 0,dateFormatter:new O(this.dCtx.ctx).formatDate,w:t}),o=s.xLabelFormat(i,o,l,{i:void 0,dateFormatter:new O(this.dCtx.ctx).formatDate,w:t}),(t.config.xaxis.convertedCatToNumeric&&void 0===a||""===String(a).trim())&&(o=a="1");var c=new S(this.dCtx.ctx),u=c.getTextRects(a,t.config.xaxis.labels.style.fontSize),d=u;if(a!==o&&(d=c.getTextRects(o,t.config.xaxis.labels.style.fontSize)),(e={width:u.width>=d.width?u.width:d.width,height:u.height>=d.height?u.height:d.height}).width*n.length>t.globals.svgWidth-this.dCtx.lgWidthForSideLegends-this.dCtx.yAxisWidth-this.dCtx.gridPad.left-this.dCtx.gridPad.right&&0!==t.config.xaxis.labels.rotate||t.config.xaxis.labels.rotateAlways){if(!t.globals.isBarHorizontal){t.globals.rotateXLabels=!0;var h=function(e){return c.getTextRects(e,t.config.xaxis.labels.style.fontSize,t.config.xaxis.labels.style.fontFamily,"rotate(".concat(t.config.xaxis.labels.rotate," 0 0)"),!1)};u=h(a),a!==o&&(d=h(o)),e.height=(u.height>d.height?u.height:d.height)/1.5,e.width=u.width>d.width?u.width:d.width}}else t.globals.rotateXLabels=!1}return t.config.xaxis.labels.show||(e={width:0,height:0}),{width:e.width,height:e.height}}},{key:"getxAxisGroupLabelsCoords",value:function(){var e,t=this.w;if(!t.globals.hasXaxisGroups)return{width:0,height:0};var n,r=(null===(e=t.config.xaxis.group.style)||void 0===e?void 0:e.fontSize)||t.config.xaxis.labels.style.fontSize,i=t.globals.groups.map((function(e){return e.title})),a=y.getLargestStringFromArr(i),o=this.dCtx.dimHelpers.getLargestStringFromMultiArr(a,i),s=new S(this.dCtx.ctx),l=s.getTextRects(a,r),c=l;return a!==o&&(c=s.getTextRects(o,r)),n={width:l.width>=c.width?l.width:c.width,height:l.height>=c.height?l.height:c.height},t.config.xaxis.labels.show||(n={width:0,height:0}),{width:n.width,height:n.height}}},{key:"getxAxisTitleCoords",value:function(){var e=this.w,t=0,n=0;if(void 0!==e.config.xaxis.title.text){var r=new S(this.dCtx.ctx).getTextRects(e.config.xaxis.title.text,e.config.xaxis.title.style.fontSize);t=r.width,n=r.height}return{width:t,height:n}}},{key:"getxAxisTimeScaleLabelsCoords",value:function(){var e,t=this.w;this.dCtx.timescaleLabels=t.globals.timescaleLabels.slice();var n=this.dCtx.timescaleLabels.map((function(e){return e.value})),r=n.reduce((function(e,t){return void 0===e?(console.error("You have possibly supplied invalid Date format. Please supply a valid JavaScript Date"),0):e.length>t.length?e:t}),0);return 1.05*(e=new S(this.dCtx.ctx).getTextRects(r,t.config.xaxis.labels.style.fontSize)).width*n.length>t.globals.gridWidth&&0!==t.config.xaxis.labels.rotate&&(t.globals.overlappingXLabels=!0),e}},{key:"additionalPaddingXLabels",value:function(e){var t=this,n=this.w,r=n.globals,i=n.config,a=i.xaxis.type,o=e.width;r.skipLastTimelinelabel=!1,r.skipFirstTimelinelabel=!1;var s=n.config.yaxis[0].opposite&&n.globals.isBarHorizontal,l=function(e,s){i.yaxis.length>1&&function(e){return-1!==r.collapsedSeriesIndices.indexOf(e)}(s)||function(e){if(t.dCtx.timescaleLabels&&t.dCtx.timescaleLabels.length){var s=t.dCtx.timescaleLabels[0],l=t.dCtx.timescaleLabels[t.dCtx.timescaleLabels.length-1].position+o/1.75-t.dCtx.yAxisWidthRight,c=s.position-o/1.75+t.dCtx.yAxisWidthLeft,u="right"===n.config.legend.position&&t.dCtx.lgRect.width>0?t.dCtx.lgRect.width:0;l>r.svgWidth-r.translateX-u&&(r.skipLastTimelinelabel=!0),c<-(e.show&&!e.floating||"bar"!==i.chart.type&&"candlestick"!==i.chart.type&&"rangeBar"!==i.chart.type&&"boxPlot"!==i.chart.type?10:o/1.75)&&(r.skipFirstTimelinelabel=!0)}else"datetime"===a?t.dCtx.gridPad.right(null===(r=String(u(t,s)))||void 0===r?void 0:r.length)?e:t}),d),f=h=u(h,s);if(void 0!==h&&0!==h.length||(h=l.niceMax),t.globals.isBarHorizontal){r=0;var p=t.globals.labels.slice();h=y.getLargestStringFromArr(p),h=u(h,{seriesIndex:o,dataPointIndex:-1,w:t}),f=e.dCtx.dimHelpers.getLargestStringFromMultiArr(h,p)}var g=new S(e.dCtx.ctx),m="rotate(".concat(a.labels.rotate," 0 0)"),v=g.getTextRects(h,a.labels.style.fontSize,a.labels.style.fontFamily,m,!1),x=v;h!==f&&(x=g.getTextRects(f,a.labels.style.fontSize,a.labels.style.fontFamily,m,!1)),n.push({width:(c>x.width||c>v.width?c:x.width>v.width?x.width:v.width)+r,height:x.height>v.height?x.height:v.height})}else n.push({width:0,height:0})})),n}},{key:"getyAxisTitleCoords",value:function(){var e=this,t=this.w,n=[];return t.config.yaxis.map((function(t,r){if(t.show&&void 0!==t.title.text){var i=new S(e.dCtx.ctx),a="rotate(".concat(t.title.rotate," 0 0)"),o=i.getTextRects(t.title.text,t.title.style.fontSize,t.title.style.fontFamily,a,!1);n.push({width:o.width,height:o.height})}else n.push({width:0,height:0})})),n}},{key:"getTotalYAxisWidth",value:function(){var e=this.w,t=0,n=0,r=0,i=e.globals.yAxisScale.length>1?10:0,a=new G(this.dCtx.ctx),o=function(o,s){var l=e.config.yaxis[s].floating,c=0;o.width>0&&!l?(c=o.width+i,function(t){return e.globals.ignoreYAxisIndexes.indexOf(t)>-1}(s)&&(c=c-o.width-i)):c=l||a.isYAxisHidden(s)?0:5,e.config.yaxis[s].opposite?r+=c:n+=c,t+=c};return e.globals.yLabelsCoords.map((function(e,t){o(e,t)})),e.globals.yTitleCoords.map((function(e,t){o(e,t)})),e.globals.isBarHorizontal&&!e.config.yaxis[0].floating&&(t=e.globals.yLabelsCoords[0].width+e.globals.yTitleCoords[0].width+15),this.dCtx.yAxisWidthLeft=n,this.dCtx.yAxisWidthRight=r,t}}]),e}(),ce=function(){function e(t){s(this,e),this.w=t.w,this.dCtx=t}return c(e,[{key:"gridPadForColumnsInNumericAxis",value:function(e){var t=this.w;if(t.globals.noData||t.globals.allSeriesCollapsed)return 0;var n=function(e){return"bar"===e||"rangeBar"===e||"candlestick"===e||"boxPlot"===e},r=t.config.chart.type,i=0,a=n(r)?t.config.series.length:1;if(t.globals.comboBarCount>0&&(a=t.globals.comboBarCount),t.globals.collapsedSeries.forEach((function(e){n(e.type)&&(a-=1)})),t.config.chart.stacked&&(a=1),(n(r)||t.globals.comboBarCount>0)&&t.globals.isXNumeric&&!t.globals.isBarHorizontal&&a>0){var o,s,l=Math.abs(t.globals.initialMaxX-t.globals.initialMinX);l<=3&&(l=t.globals.dataPoints),o=l/e,t.globals.minXDiff&&t.globals.minXDiff/o>0&&(s=t.globals.minXDiff/o),s>e/2&&(s/=2),(i=s/a*parseInt(t.config.plotOptions.bar.columnWidth,10)/100)<1&&(i=1),i=i/(a>1?1:1.5)+5,t.globals.barPadForNumericAxis=i}return i}},{key:"gridPadFortitleSubtitle",value:function(){var e=this,t=this.w,n=t.globals,r=this.dCtx.isSparkline||!t.globals.axisCharts?0:10;["title","subtitle"].forEach((function(n){void 0!==t.config[n].text?r+=t.config[n].margin:r+=e.dCtx.isSparkline||!t.globals.axisCharts?0:5})),!t.config.legend.show||"bottom"!==t.config.legend.position||t.config.legend.floating||t.globals.axisCharts||(r+=10);var i=this.dCtx.dimHelpers.getTitleSubtitleCoords("title"),a=this.dCtx.dimHelpers.getTitleSubtitleCoords("subtitle");n.gridHeight=n.gridHeight-i.height-a.height-r,n.translateY=n.translateY+i.height+a.height+r}},{key:"setGridXPosForDualYAxis",value:function(e,t){var n=this.w,r=new G(this.dCtx.ctx);n.config.yaxis.map((function(i,a){-1!==n.globals.ignoreYAxisIndexes.indexOf(a)||i.floating||r.isYAxisHidden(a)||(i.opposite&&(n.globals.translateX=n.globals.translateX-(t[a].width+e[a].width)-parseInt(n.config.yaxis[a].labels.style.fontSize,10)/1.2-12),n.globals.translateX<2&&(n.globals.translateX=2))}))}}]),e}(),ue=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.lgRect={},this.yAxisWidth=0,this.yAxisWidthLeft=0,this.yAxisWidthRight=0,this.xAxisHeight=0,this.isSparkline=this.w.config.chart.sparkline.enabled,this.dimHelpers=new oe(this),this.dimYAxis=new le(this),this.dimXAxis=new se(this),this.dimGrid=new ce(this),this.lgWidthForSideLegends=0,this.gridPad=this.w.config.grid.padding,this.xPadRight=0,this.xPadLeft=0}return c(e,[{key:"plotCoords",value:function(){var e=this,t=this.w,n=t.globals;this.lgRect=this.dimHelpers.getLegendsRect(),this.isSparkline&&((t.config.markers.discrete.length>0||t.config.markers.size>0)&&Object.entries(this.gridPad).forEach((function(t){var n=m(t,2),r=n[0],i=n[1];e.gridPad[r]=Math.max(i,e.w.globals.markers.largestSize/1.5)})),this.gridPad.top=Math.max(t.config.stroke.width/2,this.gridPad.top),this.gridPad.bottom=Math.max(t.config.stroke.width/2,this.gridPad.bottom)),n.axisCharts?this.setDimensionsForAxisCharts():this.setDimensionsForNonAxisCharts(),this.dimGrid.gridPadFortitleSubtitle(),n.gridHeight=n.gridHeight-this.gridPad.top-this.gridPad.bottom,n.gridWidth=n.gridWidth-this.gridPad.left-this.gridPad.right-this.xPadRight-this.xPadLeft;var r=this.dimGrid.gridPadForColumnsInNumericAxis(n.gridWidth);n.gridWidth=n.gridWidth-2*r,n.translateX=n.translateX+this.gridPad.left+this.xPadLeft+(r>0?r+4:0),n.translateY=n.translateY+this.gridPad.top}},{key:"setDimensionsForAxisCharts",value:function(){var e=this,t=this.w,n=t.globals,r=this.dimYAxis.getyAxisLabelsCoords(),i=this.dimYAxis.getyAxisTitleCoords();t.globals.yLabelsCoords=[],t.globals.yTitleCoords=[],t.config.yaxis.map((function(e,n){t.globals.yLabelsCoords.push({width:r[n].width,index:n}),t.globals.yTitleCoords.push({width:i[n].width,index:n})})),this.yAxisWidth=this.dimYAxis.getTotalYAxisWidth();var a=this.dimXAxis.getxAxisLabelsCoords(),o=this.dimXAxis.getxAxisGroupLabelsCoords(),s=this.dimXAxis.getxAxisTitleCoords();this.conditionalChecksForAxisCoords(a,s,o),n.translateXAxisY=t.globals.rotateXLabels?this.xAxisHeight/8:-4,n.translateXAxisX=t.globals.rotateXLabels&&t.globals.isXNumeric&&t.config.xaxis.labels.rotate<=-45?-this.xAxisWidth/4:0,t.globals.isBarHorizontal&&(n.rotateXLabels=!1,n.translateXAxisY=parseInt(t.config.xaxis.labels.style.fontSize,10)/1.5*-1),n.translateXAxisY=n.translateXAxisY+t.config.xaxis.labels.offsetY,n.translateXAxisX=n.translateXAxisX+t.config.xaxis.labels.offsetX;var l=this.yAxisWidth,c=this.xAxisHeight;n.xAxisLabelsHeight=this.xAxisHeight-s.height,n.xAxisGroupLabelsHeight=n.xAxisLabelsHeight-a.height,n.xAxisLabelsWidth=this.xAxisWidth,n.xAxisHeight=this.xAxisHeight;var u=10;("radar"===t.config.chart.type||this.isSparkline)&&(l=0,c=n.goldenPadding),this.isSparkline&&(this.lgRect={height:0,width:0}),(this.isSparkline||"treemap"===t.config.chart.type)&&(l=0,c=0,u=0),this.isSparkline||this.dimXAxis.additionalPaddingXLabels(a);var d=function(){n.translateX=l,n.gridHeight=n.svgHeight-e.lgRect.height-c-(e.isSparkline||"treemap"===t.config.chart.type?0:t.globals.rotateXLabels?10:15),n.gridWidth=n.svgWidth-l};switch("top"===t.config.xaxis.position&&(u=n.xAxisHeight-t.config.xaxis.axisTicks.height-5),t.config.legend.position){case"bottom":n.translateY=u,d();break;case"top":n.translateY=this.lgRect.height+u,d();break;case"left":n.translateY=u,n.translateX=this.lgRect.width+l,n.gridHeight=n.svgHeight-c-12,n.gridWidth=n.svgWidth-this.lgRect.width-l;break;case"right":n.translateY=u,n.translateX=l,n.gridHeight=n.svgHeight-c-12,n.gridWidth=n.svgWidth-this.lgRect.width-l-5;break;default:throw new Error("Legend position not supported")}this.dimGrid.setGridXPosForDualYAxis(i,r),new K(this.ctx).setYAxisXPosition(r,i)}},{key:"setDimensionsForNonAxisCharts",value:function(){var e=this.w,t=e.globals,n=e.config,r=0;e.config.legend.show&&!e.config.legend.floating&&(r=20);var i="pie"===n.chart.type||"polarArea"===n.chart.type||"donut"===n.chart.type?"pie":"radialBar",a=n.plotOptions[i].offsetY,o=n.plotOptions[i].offsetX;if(!n.legend.show||n.legend.floating)return t.gridHeight=t.svgHeight-n.grid.padding.left+n.grid.padding.right,t.gridWidth=t.gridHeight,t.translateY=a,void(t.translateX=o+(t.svgWidth-t.gridWidth)/2);switch(n.legend.position){case"bottom":t.gridHeight=t.svgHeight-this.lgRect.height-t.goldenPadding,t.gridWidth=t.svgWidth,t.translateY=a-10,t.translateX=o+(t.svgWidth-t.gridWidth)/2;break;case"top":t.gridHeight=t.svgHeight-this.lgRect.height-t.goldenPadding,t.gridWidth=t.svgWidth,t.translateY=this.lgRect.height+a+10,t.translateX=o+(t.svgWidth-t.gridWidth)/2;break;case"left":t.gridWidth=t.svgWidth-this.lgRect.width-r,t.gridHeight="auto"!==n.chart.height?t.svgHeight:t.gridWidth,t.translateY=a,t.translateX=o+this.lgRect.width+r;break;case"right":t.gridWidth=t.svgWidth-this.lgRect.width-r-5,t.gridHeight="auto"!==n.chart.height?t.svgHeight:t.gridWidth,t.translateY=a,t.translateX=o+10;break;default:throw new Error("Legend position not supported")}}},{key:"conditionalChecksForAxisCoords",value:function(e,t,n){var r=this.w,i=r.globals.hasXaxisGroups?2:1,a=n.height+e.height+t.height,o=r.globals.isMultiLineX?1.2:r.globals.LINE_HEIGHT_RATIO,s=r.globals.rotateXLabels?22:10,l=r.globals.rotateXLabels&&"bottom"===r.config.legend.position?10:0;this.xAxisHeight=a*o+i*s+l,this.xAxisWidth=e.width,this.xAxisHeight-t.height>r.config.xaxis.labels.maxHeight&&(this.xAxisHeight=r.config.xaxis.labels.maxHeight),r.config.xaxis.labels.minHeight&&this.xAxisHeightu&&(this.yAxisWidth=u)}}]),e}(),de=function(){function e(t){s(this,e),this.w=t.w,this.lgCtx=t}return c(e,[{key:"getLegendStyles",value:function(){var e,t,n,r=document.createElement("style");r.setAttribute("type","text/css");var i=(null===(e=this.lgCtx.ctx)||void 0===e||null===(t=e.opts)||void 0===t||null===(n=t.chart)||void 0===n?void 0:n.nonce)||this.w.config.chart.nonce;i&&r.setAttribute("nonce",i);var a=document.createTextNode("\t\n \t\n .apexcharts-legend {\t\n display: flex;\t\n overflow: auto;\t\n padding: 0 10px;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom, .apexcharts-legend.apx-legend-position-top {\t\n flex-wrap: wrap\t\n }\t\n .apexcharts-legend.apx-legend-position-right, .apexcharts-legend.apx-legend-position-left {\t\n flex-direction: column;\t\n bottom: 0;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-left, .apexcharts-legend.apx-legend-position-top.apexcharts-align-left, .apexcharts-legend.apx-legend-position-right, .apexcharts-legend.apx-legend-position-left {\t\n justify-content: flex-start;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-center, .apexcharts-legend.apx-legend-position-top.apexcharts-align-center {\t\n justify-content: center; \t\n }\t\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-right, .apexcharts-legend.apx-legend-position-top.apexcharts-align-right {\t\n justify-content: flex-end;\t\n }\t\n .apexcharts-legend-series {\t\n cursor: pointer;\t\n line-height: normal;\t\n }\t\n .apexcharts-legend.apx-legend-position-bottom .apexcharts-legend-series, .apexcharts-legend.apx-legend-position-top .apexcharts-legend-series{\t\n display: flex;\t\n align-items: center;\t\n }\t\n .apexcharts-legend-text {\t\n position: relative;\t\n font-size: 14px;\t\n }\t\n .apexcharts-legend-text *, .apexcharts-legend-marker * {\t\n pointer-events: none;\t\n }\t\n .apexcharts-legend-marker {\t\n position: relative;\t\n display: inline-block;\t\n cursor: pointer;\t\n margin-right: 3px;\t\n border-style: solid;\n }\t\n \t\n .apexcharts-legend.apexcharts-align-right .apexcharts-legend-series, .apexcharts-legend.apexcharts-align-left .apexcharts-legend-series{\t\n display: inline-block;\t\n }\t\n .apexcharts-legend-series.apexcharts-no-click {\t\n cursor: auto;\t\n }\t\n .apexcharts-legend .apexcharts-hidden-zero-series, .apexcharts-legend .apexcharts-hidden-null-series {\t\n display: none !important;\t\n }\t\n .apexcharts-inactive-legend {\t\n opacity: 0.45;\t\n }");return r.appendChild(a),r}},{key:"getLegendBBox",value:function(){var e=this.w.globals.dom.baseEl.querySelector(".apexcharts-legend").getBoundingClientRect(),t=e.width;return{clwh:e.height,clww:t}}},{key:"appendToForeignObject",value:function(){this.w.globals.dom.elLegendForeign.appendChild(this.getLegendStyles())}},{key:"toggleDataSeries",value:function(e,t){var n=this,r=this.w;if(r.globals.axisCharts||"radialBar"===r.config.chart.type){r.globals.resized=!0;var i=null,a=null;r.globals.risingSeries=[],r.globals.axisCharts?(i=r.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(e,"']")),a=parseInt(i.getAttribute("data:realIndex"),10)):(i=r.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(e+1,"']")),a=parseInt(i.getAttribute("rel"),10)-1),t?[{cs:r.globals.collapsedSeries,csi:r.globals.collapsedSeriesIndices},{cs:r.globals.ancillaryCollapsedSeries,csi:r.globals.ancillaryCollapsedSeriesIndices}].forEach((function(e){n.riseCollapsedSeries(e.cs,e.csi,a)})):this.hideSeries({seriesEl:i,realIndex:a})}else{var o=r.globals.dom.Paper.select(" .apexcharts-series[rel='".concat(e+1,"'] path")),s=r.config.chart.type;if("pie"===s||"polarArea"===s||"donut"===s){var l=r.config.plotOptions.pie.donut.labels;new S(this.lgCtx.ctx).pathMouseDown(o.members[0],null),this.lgCtx.ctx.pie.printDataLabelsInner(o.members[0].node,l)}o.fire("click")}}},{key:"hideSeries",value:function(e){var t=e.seriesEl,n=e.realIndex,r=this.w,i=y.clone(r.config.series);if(r.globals.axisCharts){var a=!1;if(r.config.yaxis[n]&&r.config.yaxis[n].show&&r.config.yaxis[n].showAlways&&(a=!0,r.globals.ancillaryCollapsedSeriesIndices.indexOf(n)<0&&(r.globals.ancillaryCollapsedSeries.push({index:n,data:i[n].data.slice(),type:t.parentNode.className.baseVal.split("-")[1]}),r.globals.ancillaryCollapsedSeriesIndices.push(n))),!a){r.globals.collapsedSeries.push({index:n,data:i[n].data.slice(),type:t.parentNode.className.baseVal.split("-")[1]}),r.globals.collapsedSeriesIndices.push(n);var o=r.globals.risingSeries.indexOf(n);r.globals.risingSeries.splice(o,1)}}else r.globals.collapsedSeries.push({index:n,data:i[n]}),r.globals.collapsedSeriesIndices.push(n);for(var s=t.childNodes,l=0;l0){for(var a=0;a-1&&(e[r].data=[])})):e.forEach((function(n,r){t.globals.collapsedSeriesIndices.indexOf(r)>-1&&(e[r]=0)})),e}}]),e}(),he=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.onLegendClick=this.onLegendClick.bind(this),this.onLegendHovered=this.onLegendHovered.bind(this),this.isBarsDistributed="bar"===this.w.config.chart.type&&this.w.config.plotOptions.bar.distributed&&1===this.w.config.series.length,this.legendHelpers=new de(this)}return c(e,[{key:"init",value:function(){var e=this.w,t=e.globals,n=e.config;if((n.legend.showForSingleSeries&&1===t.series.length||this.isBarsDistributed||t.series.length>1||!t.axisCharts)&&n.legend.show){for(;t.dom.elLegendWrap.firstChild;)t.dom.elLegendWrap.removeChild(t.dom.elLegendWrap.firstChild);this.drawLegends(),y.isIE11()?document.getElementsByTagName("head")[0].appendChild(this.legendHelpers.getLegendStyles()):this.legendHelpers.appendToForeignObject(),"bottom"===n.legend.position||"top"===n.legend.position?this.legendAlignHorizontal():"right"!==n.legend.position&&"left"!==n.legend.position||this.legendAlignVertical()}}},{key:"drawLegends",value:function(){var e=this,t=this.w,n=t.config.legend.fontFamily,r=t.globals.seriesNames,i=t.globals.colors.slice();if("heatmap"===t.config.chart.type){var a=t.config.plotOptions.heatmap.colorScale.ranges;r=a.map((function(e){return e.name?e.name:e.from+" - "+e.to})),i=a.map((function(e){return e.color}))}else this.isBarsDistributed&&(r=t.globals.labels.slice());t.config.legend.customLegendItems.length&&(r=t.config.legend.customLegendItems);for(var o=t.globals.legendFormatter,s=t.config.legend.inverseOrder,l=s?r.length-1:0;s?l>=0:l<=r.length-1;s?l--:l++){var c,u=o(r[l],{seriesIndex:l,w:t}),d=!1,h=!1;if(t.globals.collapsedSeries.length>0)for(var f=0;f0)for(var p=0;p0?l-10:0)+(c>0?c-10:0)}r.style.position="absolute",a=a+e+n.config.legend.offsetX,o=o+t+n.config.legend.offsetY,r.style.left=a+"px",r.style.top=o+"px","bottom"===n.config.legend.position?(r.style.top="auto",r.style.bottom=5-n.config.legend.offsetY+"px"):"right"===n.config.legend.position&&(r.style.left="auto",r.style.right=25+n.config.legend.offsetX+"px"),["width","height"].forEach((function(e){r.style[e]&&(r.style[e]=parseInt(n.config.legend[e],10)+"px")}))}},{key:"legendAlignHorizontal",value:function(){var e=this.w;e.globals.dom.elLegendWrap.style.right=0;var t=this.legendHelpers.getLegendBBox(),n=new ue(this.ctx),r=n.dimHelpers.getTitleSubtitleCoords("title"),i=n.dimHelpers.getTitleSubtitleCoords("subtitle"),a=0;"bottom"===e.config.legend.position?a=-t.clwh/1.8:"top"===e.config.legend.position&&(a=r.height+i.height+e.config.title.margin+e.config.subtitle.margin-10),this.setLegendWrapXY(20,a)}},{key:"legendAlignVertical",value:function(){var e=this.w,t=this.legendHelpers.getLegendBBox(),n=0;"left"===e.config.legend.position&&(n=20),"right"===e.config.legend.position&&(n=e.globals.svgWidth-t.clww-10),this.setLegendWrapXY(n,20)}},{key:"onLegendHovered",value:function(e){var t=this.w,n=e.target.classList.contains("apexcharts-legend-series")||e.target.classList.contains("apexcharts-legend-text")||e.target.classList.contains("apexcharts-legend-marker");if("heatmap"===t.config.chart.type||this.isBarsDistributed){if(n){var r=parseInt(e.target.getAttribute("rel"),10)-1;this.ctx.events.fireEvent("legendHover",[this.ctx,r,this.w]),new X(this.ctx).highlightRangeInSeries(e,e.target)}}else!e.target.classList.contains("apexcharts-inactive-legend")&&n&&new X(this.ctx).toggleSeriesOnHover(e,e.target)}},{key:"onLegendClick",value:function(e){var t=this.w;if(!t.config.legend.customLegendItems.length&&(e.target.classList.contains("apexcharts-legend-series")||e.target.classList.contains("apexcharts-legend-text")||e.target.classList.contains("apexcharts-legend-marker"))){var n=parseInt(e.target.getAttribute("rel"),10)-1,r="true"===e.target.getAttribute("data:collapsed"),i=this.w.config.chart.events.legendClick;"function"==typeof i&&i(this.ctx,n,this.w),this.ctx.events.fireEvent("legendClick",[this.ctx,n,this.w]);var a=this.w.config.legend.markers.onClick;"function"==typeof a&&e.target.classList.contains("apexcharts-legend-marker")&&(a(this.ctx,n,this.w),this.ctx.events.fireEvent("legendMarkerClick",[this.ctx,n,this.w])),"treemap"!==t.config.chart.type&&"heatmap"!==t.config.chart.type&&!this.isBarsDistributed&&t.config.legend.onItemClick.toggleDataSeries&&this.legendHelpers.toggleDataSeries(n,r)}}}]),e}(),fe=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w;var n=this.w;this.ev=this.w.config.chart.events,this.selectedClass="apexcharts-selected",this.localeValues=this.w.globals.locale.toolbar,this.minX=n.globals.minX,this.maxX=n.globals.maxX}return c(e,[{key:"createToolbar",value:function(){var e=this,t=this.w,n=function(){return document.createElement("div")},r=n();if(r.setAttribute("class","apexcharts-toolbar"),r.style.top=t.config.chart.toolbar.offsetY+"px",r.style.right=3-t.config.chart.toolbar.offsetX+"px",t.globals.dom.elWrap.appendChild(r),this.elZoom=n(),this.elZoomIn=n(),this.elZoomOut=n(),this.elPan=n(),this.elSelection=n(),this.elZoomReset=n(),this.elMenuIcon=n(),this.elMenu=n(),this.elCustomIcons=[],this.t=t.config.chart.toolbar.tools,Array.isArray(this.t.customIcons))for(var i=0;i\n \n \n\n'),o("zoomOut",this.elZoomOut,'\n \n \n\n');var s=function(n){e.t[n]&&t.config.chart[n].enabled&&a.push({el:"zoom"===n?e.elZoom:e.elSelection,icon:"string"==typeof e.t[n]?e.t[n]:"zoom"===n?'\n \n \n \n':'\n \n \n',title:e.localeValues["zoom"===n?"selectionZoom":"selection"],class:t.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-".concat(n,"-icon")})};s("zoom"),s("selection"),this.t.pan&&t.config.chart.zoom.enabled&&a.push({el:this.elPan,icon:"string"==typeof this.t.pan?this.t.pan:'\n \n \n \n \n \n \n \n',title:this.localeValues.pan,class:t.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-pan-icon"}),o("reset",this.elZoomReset,'\n \n \n'),this.t.download&&a.push({el:this.elMenuIcon,icon:"string"==typeof this.t.download?this.t.download:'',title:this.localeValues.menu,class:"apexcharts-menu-icon"});for(var l=0;l0&&t.height>0&&this.slDraggableRect.selectize({points:"l, r",pointSize:8,pointType:"rect"}).resize({constraint:{minX:0,minY:0,maxX:e.globals.gridWidth,maxY:e.globals.gridHeight}}).on("resizing",this.selectionDragging.bind(this,"resizing"))}}},{key:"preselectedSelection",value:function(){var e=this.w,t=this.xyRatios;if(!e.globals.zoomEnabled)if(void 0!==e.globals.selection&&null!==e.globals.selection)this.drawSelectionRect(e.globals.selection);else if(void 0!==e.config.chart.selection.xaxis.min&&void 0!==e.config.chart.selection.xaxis.max){var n=(e.config.chart.selection.xaxis.min-e.globals.minX)/t.xRatio,r=e.globals.gridWidth-(e.globals.maxX-e.config.chart.selection.xaxis.max)/t.xRatio-n;e.globals.isRangeBar&&(n=(e.config.chart.selection.xaxis.min-e.globals.yAxisScale[0].niceMin)/t.invertedYRatio,r=(e.config.chart.selection.xaxis.max-e.config.chart.selection.xaxis.min)/t.invertedYRatio);var i={x:n,y:0,width:r,height:e.globals.gridHeight,translateX:0,translateY:0,selectionEnabled:!0};this.drawSelectionRect(i),this.makeSelectionRectDraggable(),"function"==typeof e.config.chart.events.selection&&e.config.chart.events.selection(this.ctx,{xaxis:{min:e.config.chart.selection.xaxis.min,max:e.config.chart.selection.xaxis.max},yaxis:{}})}}},{key:"drawSelectionRect",value:function(e){var t=e.x,n=e.y,r=e.width,i=e.height,a=e.translateX,o=void 0===a?0:a,s=e.translateY,l=void 0===s?0:s,c=this.w,u=this.zoomRect,d=this.selectionRect;if(this.dragged||null!==c.globals.selection){var h={transform:"translate("+o+", "+l+")"};c.globals.zoomEnabled&&this.dragged&&(r<0&&(r=1),u.attr({x:t,y:n,width:r,height:i,fill:c.config.chart.zoom.zoomedArea.fill.color,"fill-opacity":c.config.chart.zoom.zoomedArea.fill.opacity,stroke:c.config.chart.zoom.zoomedArea.stroke.color,"stroke-width":c.config.chart.zoom.zoomedArea.stroke.width,"stroke-opacity":c.config.chart.zoom.zoomedArea.stroke.opacity}),S.setAttrs(u.node,h)),c.globals.selectionEnabled&&(d.attr({x:t,y:n,width:r>0?r:0,height:i>0?i:0,fill:c.config.chart.selection.fill.color,"fill-opacity":c.config.chart.selection.fill.opacity,stroke:c.config.chart.selection.stroke.color,"stroke-width":c.config.chart.selection.stroke.width,"stroke-dasharray":c.config.chart.selection.stroke.dashArray,"stroke-opacity":c.config.chart.selection.stroke.opacity}),S.setAttrs(d.node,h))}}},{key:"hideSelectionRect",value:function(e){e&&e.attr({x:0,y:0,width:0,height:0})}},{key:"selectionDrawing",value:function(e){var t,n=e.context,r=e.zoomtype,i=this.w,a=n,o=this.gridRect.getBoundingClientRect(),s=a.startX-1,l=a.startY,c=!1,u=!1,d=a.clientX-o.left-s,h=a.clientY-o.top-l;return Math.abs(d+s)>i.globals.gridWidth?d=i.globals.gridWidth-s:a.clientX-o.left<0&&(d=s),s>a.clientX-o.left&&(c=!0,d=Math.abs(d)),l>a.clientY-o.top&&(u=!0,h=Math.abs(h)),t="x"===r?{x:c?s-d:s,y:0,width:d,height:i.globals.gridHeight}:"y"===r?{x:0,y:u?l-h:l,width:i.globals.gridWidth,height:h}:{x:c?s-d:s,y:u?l-h:l,width:d,height:h},a.drawSelectionRect(t),a.selectionDragging("resizing"),t}},{key:"selectionDragging",value:function(e,t){var n=this,r=this.w,i=this.xyRatios,a=this.selectionRect,o=0;"resizing"===e&&(o=30);var s=function(e){return parseFloat(a.node.getAttribute(e))},l={x:s("x"),y:s("y"),width:s("width"),height:s("height")};r.globals.selection=l,"function"==typeof r.config.chart.events.selection&&r.globals.selectionEnabled&&(clearTimeout(this.w.globals.selectionResizeTimer),this.w.globals.selectionResizeTimer=window.setTimeout((function(){var e,t,o,s,l=n.gridRect.getBoundingClientRect(),c=a.node.getBoundingClientRect();r.globals.isRangeBar?(e=r.globals.yAxisScale[0].niceMin+(c.left-l.left)*i.invertedYRatio,t=r.globals.yAxisScale[0].niceMin+(c.right-l.left)*i.invertedYRatio,o=0,s=1):(e=r.globals.xAxisScale.niceMin+(c.left-l.left)*i.xRatio,t=r.globals.xAxisScale.niceMin+(c.right-l.left)*i.xRatio,o=r.globals.yAxisScale[0].niceMin+(l.bottom-c.bottom)*i.yRatio[0],s=r.globals.yAxisScale[0].niceMax-(c.top-l.top)*i.yRatio[0]);var u={xaxis:{min:e,max:t},yaxis:{min:o,max:s}};r.config.chart.events.selection(n.ctx,u),r.config.chart.brush.enabled&&void 0!==r.config.chart.events.brushScrolled&&r.config.chart.events.brushScrolled(n.ctx,u)}),o))}},{key:"selectionDrawn",value:function(e){var t=e.context,n=e.zoomtype,r=this.w,i=t,a=this.xyRatios,o=this.ctx.toolbar;if(i.startX>i.endX){var s=i.startX;i.startX=i.endX,i.endX=s}if(i.startY>i.endY){var l=i.startY;i.startY=i.endY,i.endY=l}var c=void 0,u=void 0;r.globals.isRangeBar?(c=r.globals.yAxisScale[0].niceMin+i.startX*a.invertedYRatio,u=r.globals.yAxisScale[0].niceMin+i.endX*a.invertedYRatio):(c=r.globals.xAxisScale.niceMin+i.startX*a.xRatio,u=r.globals.xAxisScale.niceMin+i.endX*a.xRatio);var d=[],h=[];if(r.config.yaxis.forEach((function(e,t){d.push(r.globals.yAxisScale[t].niceMax-a.yRatio[t]*i.startY),h.push(r.globals.yAxisScale[t].niceMax-a.yRatio[t]*i.endY)})),i.dragged&&(i.dragX>10||i.dragY>10)&&c!==u)if(r.globals.zoomEnabled){var f=y.clone(r.globals.initialConfig.yaxis),p=y.clone(r.globals.initialConfig.xaxis);if(r.globals.zoomed=!0,r.config.xaxis.convertedCatToNumeric&&(c=Math.floor(c),u=Math.floor(u),c<1&&(c=1,u=r.globals.dataPoints),u-c<2&&(u=c+1)),"xy"!==n&&"x"!==n||(p={min:c,max:u}),"xy"!==n&&"y"!==n||f.forEach((function(e,t){f[t].min=h[t],f[t].max=d[t]})),r.config.chart.zoom.autoScaleYaxis){var g=new $(i.ctx);f=g.autoScaleY(i.ctx,f,{xaxis:p})}if(o){var m=o.getBeforeZoomRange(p,f);m&&(p=m.xaxis?m.xaxis:p,f=m.yaxis?m.yaxis:f)}var v={xaxis:p};r.config.chart.group||(v.yaxis=f),i.ctx.updateHelpers._updateOptions(v,!1,i.w.config.chart.animations.dynamicAnimation.enabled),"function"==typeof r.config.chart.events.zoomed&&o.zoomCallback(p,f)}else if(r.globals.selectionEnabled){var x,b=null;x={min:c,max:u},"xy"!==n&&"y"!==n||(b=y.clone(r.config.yaxis)).forEach((function(e,t){b[t].min=h[t],b[t].max=d[t]})),r.globals.selection=i.selection,"function"==typeof r.config.chart.events.selection&&r.config.chart.events.selection(i.ctx,{xaxis:x,yaxis:b})}}},{key:"panDragging",value:function(e){var t=e.context,n=this.w,r=t;if(void 0!==n.globals.lastClientPosition.x){var i=n.globals.lastClientPosition.x-r.clientX,a=n.globals.lastClientPosition.y-r.clientY;Math.abs(i)>Math.abs(a)&&i>0?this.moveDirection="left":Math.abs(i)>Math.abs(a)&&i<0?this.moveDirection="right":Math.abs(a)>Math.abs(i)&&a>0?this.moveDirection="up":Math.abs(a)>Math.abs(i)&&a<0&&(this.moveDirection="down")}n.globals.lastClientPosition={x:r.clientX,y:r.clientY};var o=n.globals.isRangeBar?n.globals.minY:n.globals.minX,s=n.globals.isRangeBar?n.globals.maxY:n.globals.maxX;n.config.xaxis.convertedCatToNumeric||r.panScrolled(o,s)}},{key:"delayedPanScrolled",value:function(){var e=this.w,t=e.globals.minX,n=e.globals.maxX,r=(e.globals.maxX-e.globals.minX)/2;"left"===this.moveDirection?(t=e.globals.minX+r,n=e.globals.maxX+r):"right"===this.moveDirection&&(t=e.globals.minX-r,n=e.globals.maxX-r),t=Math.floor(t),n=Math.floor(n),this.updateScrolledChart({xaxis:{min:t,max:n}},t,n)}},{key:"panScrolled",value:function(e,t){var n=this.w,r=this.xyRatios,i=y.clone(n.globals.initialConfig.yaxis),a=r.xRatio,o=n.globals.minX,s=n.globals.maxX;n.globals.isRangeBar&&(a=r.invertedYRatio,o=n.globals.minY,s=n.globals.maxY),"left"===this.moveDirection?(e=o+n.globals.gridWidth/15*a,t=s+n.globals.gridWidth/15*a):"right"===this.moveDirection&&(e=o-n.globals.gridWidth/15*a,t=s-n.globals.gridWidth/15*a),n.globals.isRangeBar||(en.globals.initialMaxX)&&(e=o,t=s);var l={min:e,max:t};n.config.chart.zoom.autoScaleYaxis&&(i=new $(this.ctx).autoScaleY(this.ctx,i,{xaxis:l}));var c={xaxis:{min:e,max:t}};n.config.chart.group||(c.yaxis=i),this.updateScrolledChart(c,e,t)}},{key:"updateScrolledChart",value:function(e,t,n){var r=this.w;this.ctx.updateHelpers._updateOptions(e,!1,!1),"function"==typeof r.config.chart.events.scrolled&&r.config.chart.events.scrolled(this.ctx,{xaxis:{min:t,max:n}})}}]),n}(),ge=function(){function e(t){s(this,e),this.w=t.w,this.ttCtx=t,this.ctx=t.ctx}return c(e,[{key:"getNearestValues",value:function(e){var t=e.hoverArea,n=e.elGrid,r=e.clientX,i=e.clientY,a=this.w,o=n.getBoundingClientRect(),s=o.width,l=o.height,c=s/(a.globals.dataPoints-1),u=l/a.globals.dataPoints,d=this.hasBars();!a.globals.comboCharts&&!d||a.config.xaxis.convertedCatToNumeric||(c=s/a.globals.dataPoints);var h=r-o.left-a.globals.barPadForNumericAxis,f=i-o.top;h<0||f<0||h>s||f>l?(t.classList.remove("hovering-zoom"),t.classList.remove("hovering-pan")):a.globals.zoomEnabled?(t.classList.remove("hovering-pan"),t.classList.add("hovering-zoom")):a.globals.panEnabled&&(t.classList.remove("hovering-zoom"),t.classList.add("hovering-pan"));var p=Math.round(h/c),g=Math.floor(f/u);d&&!a.config.xaxis.convertedCatToNumeric&&(p=Math.ceil(h/c),p-=1);var m=null,v=null,x=a.globals.seriesXvalues.map((function(e){return e.filter((function(e){return y.isNumber(e)}))})),b=a.globals.seriesYvalues.map((function(e){return e.filter((function(e){return y.isNumber(e)}))}));if(a.globals.isXNumeric){var w=this.ttCtx.getElGrid().getBoundingClientRect(),k=h*(w.width/s),S=f*(w.height/l);m=(v=this.closestInMultiArray(k,S,x,b)).index,p=v.j,null!==m&&(x=a.globals.seriesXvalues[m],p=(v=this.closestInArray(k,x)).index)}return a.globals.capturedSeriesIndex=null===m?-1:m,(!p||p<1)&&(p=0),a.globals.isBarHorizontal?a.globals.capturedDataPointIndex=g:a.globals.capturedDataPointIndex=p,{capturedSeries:m,j:a.globals.isBarHorizontal?g:p,hoverX:h,hoverY:f}}},{key:"closestInMultiArray",value:function(e,t,n,r){var i=this.w,a=0,o=null,s=-1;i.globals.series.length>1?a=this.getFirstActiveXArray(n):o=0;var l=n[a][0],c=Math.abs(e-l);if(n.forEach((function(t){t.forEach((function(t,n){var r=Math.abs(e-t);r<=c&&(c=r,s=n)}))})),-1!==s){var u=r[a][s],d=Math.abs(t-u);o=a,r.forEach((function(e,n){var r=Math.abs(t-e[s]);r<=d&&(d=r,o=n)}))}return{index:o,j:s}}},{key:"getFirstActiveXArray",value:function(e){for(var t=this.w,n=0,r=e.map((function(e,t){return e.length>0?t:-1})),i=0;i0)for(var r=0;r *")):this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap > *")}},{key:"getAllMarkers",value:function(){var e=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap");(e=v(e)).sort((function(e,t){var n=Number(e.getAttribute("data:realIndex")),r=Number(t.getAttribute("data:realIndex"));return rn?-1:0}));var t=[];return e.forEach((function(e){t.push(e.querySelector(".apexcharts-marker"))})),t}},{key:"hasMarkers",value:function(e){return this.getElMarkers(e).length>0}},{key:"getElBars",value:function(){return this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-bar-series, .apexcharts-candlestick-series, .apexcharts-boxPlot-series, .apexcharts-rangebar-series")}},{key:"hasBars",value:function(){return this.getElBars().length>0}},{key:"getHoverMarkerSize",value:function(e){var t=this.w,n=t.config.markers.hover.size;return void 0===n&&(n=t.globals.markers.size[e]+t.config.markers.hover.sizeOffset),n}},{key:"toggleAllTooltipSeriesGroups",value:function(e){var t=this.w,n=this.ttCtx;0===n.allTooltipSeriesGroups.length&&(n.allTooltipSeriesGroups=t.globals.dom.baseEl.querySelectorAll(".apexcharts-tooltip-series-group"));for(var r=n.allTooltipSeriesGroups,i=0;i ').concat(n.attrs.name,""),t+="
".concat(n.val,"
")})),x.innerHTML=e+"",b.innerHTML=t+""};o?l.globals.seriesGoals[t][n]&&Array.isArray(l.globals.seriesGoals[t][n])?y():(x.innerHTML="",b.innerHTML=""):y()}else x.innerHTML="",b.innerHTML="";if(null!==p&&(r[t].querySelector(".apexcharts-tooltip-text-z-label").innerHTML=l.config.tooltip.z.title,r[t].querySelector(".apexcharts-tooltip-text-z-value").innerHTML=void 0!==p?p:""),o&&g[0]){if(l.config.tooltip.hideEmptySeries){var w=r[t].querySelector(".apexcharts-tooltip-marker"),k=r[t].querySelector(".apexcharts-tooltip-text");0==parseFloat(u)?(w.style.display="none",k.style.display="none"):(w.style.display="block",k.style.display="block")}null==u||l.globals.ancillaryCollapsedSeriesIndices.indexOf(t)>-1||l.globals.collapsedSeriesIndices.indexOf(t)>-1?g[0].parentNode.style.display="none":g[0].parentNode.style.display=l.config.tooltip.items.display}}},{key:"toggleActiveInactiveSeries",value:function(e){var t=this.w;if(e)this.tooltipUtil.toggleAllTooltipSeriesGroups("enable");else{this.tooltipUtil.toggleAllTooltipSeriesGroups("disable");var n=t.globals.dom.baseEl.querySelector(".apexcharts-tooltip-series-group");n&&(n.classList.add("apexcharts-active"),n.style.display=t.config.tooltip.items.display)}}},{key:"getValuesToPrint",value:function(e){var t=e.i,n=e.j,r=this.w,i=this.ctx.series.filteredSeriesX(),a="",o="",s=null,l=null,c={series:r.globals.series,seriesIndex:t,dataPointIndex:n,w:r},u=r.globals.ttZFormatter;null===n?l=r.globals.series[t]:r.globals.isXNumeric&&"treemap"!==r.config.chart.type?(a=i[t][n],0===i[t].length&&(a=i[this.tooltipUtil.getFirstActiveXArray(i)][n])):a=void 0!==r.globals.labels[n]?r.globals.labels[n]:"";var d=a;return a=r.globals.isXNumeric&&"datetime"===r.config.xaxis.type?new I(this.ctx).xLabelFormat(r.globals.ttKeyFormatter,d,d,{i:void 0,dateFormatter:new O(this.ctx).formatDate,w:this.w}):r.globals.isBarHorizontal?r.globals.yLabelFormatters[0](d,c):r.globals.xLabelFormatter(d,c),void 0!==r.config.tooltip.x.formatter&&(a=r.globals.ttKeyFormatter(d,c)),r.globals.seriesZ.length>0&&r.globals.seriesZ[t].length>0&&(s=u(r.globals.seriesZ[t][n],r)),o="function"==typeof r.config.xaxis.tooltip.formatter?r.globals.xaxisTooltipFormatter(d,c):a,{val:Array.isArray(l)?l.join(" "):l,xVal:Array.isArray(a)?a.join(" "):a,xAxisTTVal:Array.isArray(o)?o.join(" "):o,zVal:s}}},{key:"handleCustomTooltip",value:function(e){var t=e.i,n=e.j,r=e.y1,i=e.y2,a=e.w,o=this.ttCtx.getElTooltip(),s=a.config.tooltip.custom;Array.isArray(s)&&s[t]&&(s=s[t]),o.innerHTML=s({ctx:this.ctx,series:a.globals.series,seriesIndex:t,dataPointIndex:n,y1:r,y2:i,w:a})}}]),e}(),ve=function(){function e(t){s(this,e),this.ttCtx=t,this.ctx=t.ctx,this.w=t.w}return c(e,[{key:"moveXCrosshairs",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=this.ttCtx,r=this.w,i=n.getElXCrosshairs(),a=e-n.xcrosshairsWidth/2,o=r.globals.labels.slice().length;if(null!==t&&(a=r.globals.gridWidth/o*t),null===i||r.globals.isBarHorizontal||(i.setAttribute("x",a),i.setAttribute("x1",a),i.setAttribute("x2",a),i.setAttribute("y2",r.globals.gridHeight),i.classList.add("apexcharts-active")),a<0&&(a=0),a>r.globals.gridWidth&&(a=r.globals.gridWidth),n.isXAxisTooltipEnabled){var s=a;"tickWidth"!==r.config.xaxis.crosshairs.width&&"barWidth"!==r.config.xaxis.crosshairs.width||(s=a+n.xcrosshairsWidth/2),this.moveXAxisTooltip(s)}}},{key:"moveYCrosshairs",value:function(e){var t=this.ttCtx;null!==t.ycrosshairs&&S.setAttrs(t.ycrosshairs,{y1:e,y2:e}),null!==t.ycrosshairsHidden&&S.setAttrs(t.ycrosshairsHidden,{y1:e,y2:e})}},{key:"moveXAxisTooltip",value:function(e){var t=this.w,n=this.ttCtx;if(null!==n.xaxisTooltip&&0!==n.xcrosshairsWidth){n.xaxisTooltip.classList.add("apexcharts-active");var r,i=n.xaxisOffY+t.config.xaxis.tooltip.offsetY+t.globals.translateY+1+t.config.xaxis.offsetY;if(e-=n.xaxisTooltip.getBoundingClientRect().width/2,!isNaN(e))e+=t.globals.translateX,r=new S(this.ctx).getTextRects(n.xaxisTooltipText.innerHTML),n.xaxisTooltipText.style.minWidth=r.width+"px",n.xaxisTooltip.style.left=e+"px",n.xaxisTooltip.style.top=i+"px"}}},{key:"moveYAxisTooltip",value:function(e){var t=this.w,n=this.ttCtx;null===n.yaxisTTEls&&(n.yaxisTTEls=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));var r=parseInt(n.ycrosshairsHidden.getAttribute("y1"),10),i=t.globals.translateY+r,a=n.yaxisTTEls[e].getBoundingClientRect().height,o=t.globals.translateYAxisX[e]-2;t.config.yaxis[e].opposite&&(o-=26),i-=a/2,-1===t.globals.ignoreYAxisIndexes.indexOf(e)?(n.yaxisTTEls[e].classList.add("apexcharts-active"),n.yaxisTTEls[e].style.top=i+"px",n.yaxisTTEls[e].style.left=o+t.config.yaxis[e].tooltip.offsetX+"px"):n.yaxisTTEls[e].classList.remove("apexcharts-active")}},{key:"moveTooltip",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=this.w,i=this.ttCtx,a=i.getElTooltip(),o=i.tooltipRect,s=null!==n?parseFloat(n):1,l=parseFloat(e)+s+5,c=parseFloat(t)+s/2;if(l>r.globals.gridWidth/2&&(l=l-o.ttWidth-s-10),l>r.globals.gridWidth-o.ttWidth-10&&(l=r.globals.gridWidth-o.ttWidth),l<-20&&(l=-20),r.config.tooltip.followCursor){var u=i.getElGrid().getBoundingClientRect();(l=i.e.clientX-u.left)>r.globals.gridWidth/2&&(l-=i.tooltipRect.ttWidth),(c=i.e.clientY+r.globals.translateY-u.top)>r.globals.gridHeight/2&&(c-=i.tooltipRect.ttHeight)}else r.globals.isBarHorizontal||o.ttHeight/2+c>r.globals.gridHeight&&(c=r.globals.gridHeight-o.ttHeight+r.globals.translateY);isNaN(l)||(l+=r.globals.translateX,a.style.left=l+"px",a.style.top=c+"px")}},{key:"moveMarkers",value:function(e,t){var n=this.w,r=this.ttCtx;if(n.globals.markers.size[e]>0)for(var i=n.globals.dom.baseEl.querySelectorAll(" .apexcharts-series[data\\:realIndex='".concat(e,"'] .apexcharts-marker")),a=0;a0&&(c.setAttribute("r",s),c.setAttribute("cx",n),c.setAttribute("cy",r)),this.moveXCrosshairs(n),a.fixedTooltip||this.moveTooltip(n,r,s)}}},{key:"moveDynamicPointsOnHover",value:function(e){var t,n=this.ttCtx,r=n.w,i=0,a=0,o=r.globals.pointsArray;t=new X(this.ctx).getActiveConfigSeriesIndex("asc",["line","area","scatter","bubble"]);var s=n.tooltipUtil.getHoverMarkerSize(t);o[t]&&(i=o[t][e][0],a=o[t][e][1]);var l=n.tooltipUtil.getAllMarkers();if(null!==l)for(var c=0;c0?(l[c]&&l[c].setAttribute("r",s),l[c]&&l[c].setAttribute("cy",d)):l[c]&&l[c].setAttribute("r",0)}}this.moveXCrosshairs(i),n.fixedTooltip||this.moveTooltip(i,a||r.globals.gridHeight,s)}},{key:"moveStickyTooltipOverBars",value:function(e,t){var n=this.w,r=this.ttCtx,i=n.globals.columnSeries?n.globals.columnSeries.length:n.globals.series.length,a=i>=2&&i%2==0?Math.floor(i/2):Math.floor(i/2)+1;n.globals.isBarHorizontal&&(a=new X(this.ctx).getActiveConfigSeriesIndex("desc")+1);var o=n.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[rel='".concat(a,"'] path[j='").concat(e,"'], .apexcharts-candlestick-series .apexcharts-series[rel='").concat(a,"'] path[j='").concat(e,"'], .apexcharts-boxPlot-series .apexcharts-series[rel='").concat(a,"'] path[j='").concat(e,"'], .apexcharts-rangebar-series .apexcharts-series[rel='").concat(a,"'] path[j='").concat(e,"']"));o||"number"!=typeof t||(o=n.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[data\\:realIndex='".concat(t,"'] path[j='").concat(e,"'],\n .apexcharts-candlestick-series .apexcharts-series[data\\:realIndex='").concat(t,"'] path[j='").concat(e,"'],\n .apexcharts-boxPlot-series .apexcharts-series[data\\:realIndex='").concat(t,"'] path[j='").concat(e,"'],\n .apexcharts-rangebar-series .apexcharts-series[data\\:realIndex='").concat(t,"'] path[j='").concat(e,"']")));var s=o?parseFloat(o.getAttribute("cx")):0,l=o?parseFloat(o.getAttribute("cy")):0,c=o?parseFloat(o.getAttribute("barWidth")):0,u=r.getElGrid().getBoundingClientRect(),d=o&&(o.classList.contains("apexcharts-candlestick-area")||o.classList.contains("apexcharts-boxPlot-area"));n.globals.isXNumeric?(o&&!d&&(s-=i%2!=0?c/2:0),o&&d&&n.globals.comboCharts&&(s-=c/2)):n.globals.isBarHorizontal||(s=r.xAxisTicksPositions[e-1]+r.dataPointsDividedWidth/2,isNaN(s)&&(s=r.xAxisTicksPositions[e]-r.dataPointsDividedWidth/2)),n.globals.isBarHorizontal?l-=r.tooltipRect.ttHeight:n.config.tooltip.followCursor?l=r.e.clientY-u.top-r.tooltipRect.ttHeight/2:l+r.tooltipRect.ttHeight+15>n.globals.gridHeight&&(l=n.globals.gridHeight),n.globals.isBarHorizontal||this.moveXCrosshairs(s),r.fixedTooltip||this.moveTooltip(s,l||n.globals.gridHeight)}}]),e}(),xe=function(){function e(t){s(this,e),this.w=t.w,this.ttCtx=t,this.ctx=t.ctx,this.tooltipPosition=new ve(t)}return c(e,[{key:"drawDynamicPoints",value:function(){var e=this.w,t=new S(this.ctx),n=new Y(this.ctx),r=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series");r=v(r),e.config.chart.stacked&&r.sort((function(e,t){return parseFloat(e.getAttribute("data:realIndex"))-parseFloat(t.getAttribute("data:realIndex"))}));for(var i=0;i2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=this.w;"bubble"!==i.config.chart.type&&this.newPointSize(e,t);var a=t.getAttribute("cx"),o=t.getAttribute("cy");if(null!==n&&null!==r&&(a=n,o=r),this.tooltipPosition.moveXCrosshairs(a),!this.fixedTooltip){if("radar"===i.config.chart.type){var s=this.ttCtx.getElGrid().getBoundingClientRect();a=this.ttCtx.e.clientX-s.left}this.tooltipPosition.moveTooltip(a,o,i.config.markers.hover.size)}}},{key:"enlargePoints",value:function(e){for(var t=this.w,n=this,r=this.ttCtx,i=e,a=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),o=t.config.markers.hover.size,s=0;s=0?e[t].setAttribute("r",n):e[t].setAttribute("r",0)}}}]),e}(),be=function(){function e(t){s(this,e),this.w=t.w;var n=this.w;this.ttCtx=t,this.isVerticalGroupedRangeBar=!n.globals.isBarHorizontal&&"rangeBar"===n.config.chart.type&&n.config.plotOptions.bar.rangeBarGroupRows}return c(e,[{key:"getAttr",value:function(e,t){return parseFloat(e.target.getAttribute(t))}},{key:"handleHeatTreeTooltip",value:function(e){var t=e.e,n=e.opt,r=e.x,i=e.y,a=e.type,o=this.ttCtx,s=this.w;if(t.target.classList.contains("apexcharts-".concat(a,"-rect"))){var l=this.getAttr(t,"i"),c=this.getAttr(t,"j"),u=this.getAttr(t,"cx"),d=this.getAttr(t,"cy"),h=this.getAttr(t,"width"),f=this.getAttr(t,"height");if(o.tooltipLabels.drawSeriesTexts({ttItems:n.ttItems,i:l,j:c,shared:!1,e:t}),s.globals.capturedSeriesIndex=l,s.globals.capturedDataPointIndex=c,r=u+o.tooltipRect.ttWidth/2+h,i=d+o.tooltipRect.ttHeight/2-f/2,o.tooltipPosition.moveXCrosshairs(u+h/2),r>s.globals.gridWidth/2&&(r=u-o.tooltipRect.ttWidth/2+h),o.w.config.tooltip.followCursor){var p=s.globals.dom.elWrap.getBoundingClientRect();r=s.globals.clientX-p.left-(r>s.globals.gridWidth/2?o.tooltipRect.ttWidth:0),i=s.globals.clientY-p.top-(i>s.globals.gridHeight/2?o.tooltipRect.ttHeight:0)}}return{x:r,y:i}}},{key:"handleMarkerTooltip",value:function(e){var t,n,r=e.e,i=e.opt,a=e.x,o=e.y,s=this.w,l=this.ttCtx;if(r.target.classList.contains("apexcharts-marker")){var c=parseInt(i.paths.getAttribute("cx"),10),u=parseInt(i.paths.getAttribute("cy"),10),d=parseFloat(i.paths.getAttribute("val"));if(n=parseInt(i.paths.getAttribute("rel"),10),t=parseInt(i.paths.parentNode.parentNode.parentNode.getAttribute("rel"),10)-1,l.intersect){var h=y.findAncestor(i.paths,"apexcharts-series");h&&(t=parseInt(h.getAttribute("data:realIndex"),10))}if(l.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:t,j:n,shared:!l.showOnIntersect&&s.config.tooltip.shared,e:r}),"mouseup"===r.type&&l.markerClick(r,t,n),s.globals.capturedSeriesIndex=t,s.globals.capturedDataPointIndex=n,a=c,o=u+s.globals.translateY-1.4*l.tooltipRect.ttHeight,l.w.config.tooltip.followCursor){var f=l.getElGrid().getBoundingClientRect();o=l.e.clientY+s.globals.translateY-f.top}d<0&&(o=u),l.marker.enlargeCurrentPoint(n,i.paths,a,o)}return{x:a,y:o}}},{key:"handleBarTooltip",value:function(e){var t,n,r=e.e,i=e.opt,a=this.w,o=this.ttCtx,s=o.getElTooltip(),l=0,c=0,u=0,d=this.getBarTooltipXY({e:r,opt:i});t=d.i;var h=d.barHeight,f=d.j;a.globals.capturedSeriesIndex=t,a.globals.capturedDataPointIndex=f,a.globals.isBarHorizontal&&o.tooltipUtil.hasBars()||!a.config.tooltip.shared?(c=d.x,u=d.y,n=Array.isArray(a.config.stroke.width)?a.config.stroke.width[t]:a.config.stroke.width,l=c):a.globals.comboCharts||a.config.tooltip.shared||(l/=2),isNaN(u)&&(u=a.globals.svgHeight-o.tooltipRect.ttHeight);var p=parseInt(i.paths.parentNode.getAttribute("data:realIndex"),10),g=a.globals.isMultipleYAxis?a.config.yaxis[p]&&a.config.yaxis[p].reversed:a.config.yaxis[0].reversed;if(c+o.tooltipRect.ttWidth>a.globals.gridWidth&&!g?c-=o.tooltipRect.ttWidth:c<0&&(c=0),o.w.config.tooltip.followCursor){var m=o.getElGrid().getBoundingClientRect();u=o.e.clientY-m.top}null===o.tooltip&&(o.tooltip=a.globals.dom.baseEl.querySelector(".apexcharts-tooltip")),a.config.tooltip.shared||(a.globals.comboBarCount>0?o.tooltipPosition.moveXCrosshairs(l+n/2):o.tooltipPosition.moveXCrosshairs(l)),!o.fixedTooltip&&(!a.config.tooltip.shared||a.globals.isBarHorizontal&&o.tooltipUtil.hasBars())&&(g&&(c-=o.tooltipRect.ttWidth)<0&&(c=0),!g||a.globals.isBarHorizontal&&o.tooltipUtil.hasBars()||(u=u+h-2*(a.globals.series[t][f]<0?h:0)),u=u+a.globals.translateY-o.tooltipRect.ttHeight/2,s.style.left=c+a.globals.translateX+"px",s.style.top=u+"px")}},{key:"getBarTooltipXY",value:function(e){var t=this,n=e.e,r=e.opt,i=this.w,a=null,o=this.ttCtx,s=0,l=0,c=0,u=0,d=0,h=n.target.classList;if(h.contains("apexcharts-bar-area")||h.contains("apexcharts-candlestick-area")||h.contains("apexcharts-boxPlot-area")||h.contains("apexcharts-rangebar-area")){var f=n.target,p=f.getBoundingClientRect(),g=r.elGrid.getBoundingClientRect(),m=p.height;d=p.height;var v=p.width,x=parseInt(f.getAttribute("cx"),10),b=parseInt(f.getAttribute("cy"),10);u=parseFloat(f.getAttribute("barWidth"));var y="touchmove"===n.type?n.touches[0].clientX:n.clientX;a=parseInt(f.getAttribute("j"),10),s=parseInt(f.parentNode.getAttribute("rel"),10)-1;var w=f.getAttribute("data-range-y1"),k=f.getAttribute("data-range-y2");i.globals.comboCharts&&(s=parseInt(f.parentNode.getAttribute("data:realIndex"),10));var S=function(e){return i.globals.isXNumeric?x-v/2:t.isVerticalGroupedRangeBar?x+v/2:x-o.dataPointsDividedWidth+v/2},C=function(){return b-o.dataPointsDividedHeight+m/2-o.tooltipRect.ttHeight/2};o.tooltipLabels.drawSeriesTexts({ttItems:r.ttItems,i:s,j:a,y1:w?parseInt(w,10):null,y2:k?parseInt(k,10):null,shared:!o.showOnIntersect&&i.config.tooltip.shared,e:n}),i.config.tooltip.followCursor?i.globals.isBarHorizontal?(l=y-g.left+15,c=C()):(l=S(),c=n.clientY-g.top-o.tooltipRect.ttHeight/2-15):i.globals.isBarHorizontal?((l=x)0&&n.setAttribute("width",t.xcrosshairsWidth)}},{key:"handleYCrosshair",value:function(){var e=this.w,t=this.ttCtx;t.ycrosshairs=e.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs"),t.ycrosshairsHidden=e.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs-hidden")}},{key:"drawYaxisTooltipText",value:function(e,t,n){var r=this.ttCtx,i=this.w,a=i.globals.yLabelFormatters[e];if(r.yaxisTooltips[e]){var o=r.getElGrid().getBoundingClientRect(),s=(t-o.top)*n.yRatio[e],l=i.globals.maxYArr[e]-i.globals.minYArr[e],c=i.globals.minYArr[e]+(l-s);r.tooltipPosition.moveYCrosshairs(t-o.top),r.yaxisTooltipText[e].innerHTML=a(c),r.tooltipPosition.moveYAxisTooltip(e)}}}]),e}(),we=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w;var n=this.w;this.tConfig=n.config.tooltip,this.tooltipUtil=new ge(this),this.tooltipLabels=new me(this),this.tooltipPosition=new ve(this),this.marker=new xe(this),this.intersect=new be(this),this.axesTooltip=new ye(this),this.showOnIntersect=this.tConfig.intersect,this.showTooltipTitle=this.tConfig.x.show,this.fixedTooltip=this.tConfig.fixed.enabled,this.xaxisTooltip=null,this.yaxisTTEls=null,this.isBarShared=!n.globals.isBarHorizontal&&this.tConfig.shared,this.lastHoverTime=Date.now()}return c(e,[{key:"getElTooltip",value:function(e){return e||(e=this),e.w.globals.dom.baseEl?e.w.globals.dom.baseEl.querySelector(".apexcharts-tooltip"):null}},{key:"getElXCrosshairs",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-xcrosshairs")}},{key:"getElGrid",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-grid")}},{key:"drawTooltip",value:function(e){var t=this.w;this.xyRatios=e,this.isXAxisTooltipEnabled=t.config.xaxis.tooltip.enabled&&t.globals.axisCharts,this.yaxisTooltips=t.config.yaxis.map((function(e,n){return!!(e.show&&e.tooltip.enabled&&t.globals.axisCharts)})),this.allTooltipSeriesGroups=[],t.globals.axisCharts||(this.showTooltipTitle=!1);var n=document.createElement("div");if(n.classList.add("apexcharts-tooltip"),t.config.tooltip.cssClass&&n.classList.add(t.config.tooltip.cssClass),n.classList.add("apexcharts-theme-".concat(this.tConfig.theme)),t.globals.dom.elWrap.appendChild(n),t.globals.axisCharts){this.axesTooltip.drawXaxisTooltip(),this.axesTooltip.drawYaxisTooltip(),this.axesTooltip.setXCrosshairWidth(),this.axesTooltip.handleYCrosshair();var r=new Z(this.ctx);this.xAxisTicksPositions=r.getXAxisTicksPositions()}if(!t.globals.comboCharts&&!this.tConfig.intersect&&"rangeBar"!==t.config.chart.type||this.tConfig.shared||(this.showOnIntersect=!0),0!==t.config.markers.size&&0!==t.globals.markers.largestSize||this.marker.drawDynamicPoints(this),t.globals.collapsedSeries.length!==t.globals.series.length){this.dataPointsDividedHeight=t.globals.gridHeight/t.globals.dataPoints,this.dataPointsDividedWidth=t.globals.gridWidth/t.globals.dataPoints,this.showTooltipTitle&&(this.tooltipTitle=document.createElement("div"),this.tooltipTitle.classList.add("apexcharts-tooltip-title"),this.tooltipTitle.style.fontFamily=this.tConfig.style.fontFamily||t.config.chart.fontFamily,this.tooltipTitle.style.fontSize=this.tConfig.style.fontSize,n.appendChild(this.tooltipTitle));var i=t.globals.series.length;(t.globals.xyCharts||t.globals.comboCharts)&&this.tConfig.shared&&(i=this.showOnIntersect?1:t.globals.series.length),this.legendLabels=t.globals.dom.baseEl.querySelectorAll(".apexcharts-legend-text"),this.ttItems=this.createTTElements(i),this.addSVGEvents()}}},{key:"createTTElements",value:function(e){for(var t=this,n=this.w,r=[],i=this.getElTooltip(),a=function(a){var o=document.createElement("div");o.classList.add("apexcharts-tooltip-series-group"),o.style.order=n.config.tooltip.inverseOrder?e-a:a+1,t.tConfig.shared&&t.tConfig.enabledOnSeries&&Array.isArray(t.tConfig.enabledOnSeries)&&t.tConfig.enabledOnSeries.indexOf(a)<0&&o.classList.add("apexcharts-tooltip-series-group-hidden");var s=document.createElement("span");s.classList.add("apexcharts-tooltip-marker"),s.style.backgroundColor=n.globals.colors[a],o.appendChild(s);var l=document.createElement("div");l.classList.add("apexcharts-tooltip-text"),l.style.fontFamily=t.tConfig.style.fontFamily||n.config.chart.fontFamily,l.style.fontSize=t.tConfig.style.fontSize,["y","goals","z"].forEach((function(e){var t=document.createElement("div");t.classList.add("apexcharts-tooltip-".concat(e,"-group"));var n=document.createElement("span");n.classList.add("apexcharts-tooltip-text-".concat(e,"-label")),t.appendChild(n);var r=document.createElement("span");r.classList.add("apexcharts-tooltip-text-".concat(e,"-value")),t.appendChild(r),l.appendChild(t)})),o.appendChild(l),i.appendChild(o),r.push(o)},o=0;o0&&this.addPathsEventListeners(f,u),this.tooltipUtil.hasBars()&&!this.tConfig.shared&&this.addDatapointEventsListeners(u)}}},{key:"drawFixedTooltipRect",value:function(){var e=this.w,t=this.getElTooltip(),n=t.getBoundingClientRect(),r=n.width+10,i=n.height+10,a=this.tConfig.fixed.offsetX,o=this.tConfig.fixed.offsetY,s=this.tConfig.fixed.position.toLowerCase();return s.indexOf("right")>-1&&(a=a+e.globals.svgWidth-r+10),s.indexOf("bottom")>-1&&(o=o+e.globals.svgHeight-i-10),t.style.left=a+"px",t.style.top=o+"px",{x:a,y:o,ttWidth:r,ttHeight:i}}},{key:"addDatapointEventsListeners",value:function(e){var t=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers .apexcharts-marker, .apexcharts-bar-area, .apexcharts-candlestick-area, .apexcharts-boxPlot-area, .apexcharts-rangebar-area");this.addPathsEventListeners(t,e)}},{key:"addPathsEventListeners",value:function(e,t){for(var n=this,r=function(r){var i={paths:e[r],tooltipEl:t.tooltipEl,tooltipY:t.tooltipY,tooltipX:t.tooltipX,elGrid:t.elGrid,hoverArea:t.hoverArea,ttItems:t.ttItems};["mousemove","mouseup","touchmove","mouseout","touchend"].map((function(t){return e[r].addEventListener(t,n.onSeriesHover.bind(n,i),{capture:!1,passive:!0})}))},i=0;i=100?this.seriesHover(e,t):(clearTimeout(this.seriesHoverTimeout),this.seriesHoverTimeout=setTimeout((function(){n.seriesHover(e,t)}),100-r))}},{key:"seriesHover",value:function(e,t){var n=this;this.lastHoverTime=Date.now();var r=[],i=this.w;i.config.chart.group&&(r=this.ctx.getGroupedCharts()),i.globals.axisCharts&&(i.globals.minX===-1/0&&i.globals.maxX===1/0||0===i.globals.dataPoints)||(r.length?r.forEach((function(r){var i=n.getElTooltip(r),a={paths:e.paths,tooltipEl:i,tooltipY:e.tooltipY,tooltipX:e.tooltipX,elGrid:e.elGrid,hoverArea:e.hoverArea,ttItems:r.w.globals.tooltip.ttItems};r.w.globals.minX===n.w.globals.minX&&r.w.globals.maxX===n.w.globals.maxX&&r.w.globals.tooltip.seriesHoverByContext({chartCtx:r,ttCtx:r.w.globals.tooltip,opt:a,e:t})})):this.seriesHoverByContext({chartCtx:this.ctx,ttCtx:this.w.globals.tooltip,opt:e,e:t}))}},{key:"seriesHoverByContext",value:function(e){var t=e.chartCtx,n=e.ttCtx,r=e.opt,i=e.e,a=t.w,o=this.getElTooltip();o&&(n.tooltipRect={x:0,y:0,ttWidth:o.getBoundingClientRect().width,ttHeight:o.getBoundingClientRect().height},n.e=i,!n.tooltipUtil.hasBars()||a.globals.comboCharts||n.isBarShared||this.tConfig.onDatasetHover.highlightDataSeries&&new X(t).toggleSeriesOnHover(i,i.target.parentNode),n.fixedTooltip&&n.drawFixedTooltipRect(),a.globals.axisCharts?n.axisChartsTooltips({e:i,opt:r,tooltipRect:n.tooltipRect}):n.nonAxisChartsTooltips({e:i,opt:r,tooltipRect:n.tooltipRect}))}},{key:"axisChartsTooltips",value:function(e){var t,n,r=e.e,i=e.opt,a=this.w,o=i.elGrid.getBoundingClientRect(),s="touchmove"===r.type?r.touches[0].clientX:r.clientX,l="touchmove"===r.type?r.touches[0].clientY:r.clientY;if(this.clientY=l,this.clientX=s,a.globals.capturedSeriesIndex=-1,a.globals.capturedDataPointIndex=-1,lo.top+o.height)this.handleMouseOut(i);else{if(Array.isArray(this.tConfig.enabledOnSeries)&&!a.config.tooltip.shared){var c=parseInt(i.paths.getAttribute("index"),10);if(this.tConfig.enabledOnSeries.indexOf(c)<0)return void this.handleMouseOut(i)}var u=this.getElTooltip(),d=this.getElXCrosshairs(),h=a.globals.xyCharts||"bar"===a.config.chart.type&&!a.globals.isBarHorizontal&&this.tooltipUtil.hasBars()&&this.tConfig.shared||a.globals.comboCharts&&this.tooltipUtil.hasBars();if("mousemove"===r.type||"touchmove"===r.type||"mouseup"===r.type){if(a.globals.collapsedSeries.length+a.globals.ancillaryCollapsedSeries.length===a.globals.series.length)return;null!==d&&d.classList.add("apexcharts-active");var f=this.yaxisTooltips.filter((function(e){return!0===e}));if(null!==this.ycrosshairs&&f.length&&this.ycrosshairs.classList.add("apexcharts-active"),h&&!this.showOnIntersect)this.handleStickyTooltip(r,s,l,i);else if("heatmap"===a.config.chart.type||"treemap"===a.config.chart.type){var p=this.intersect.handleHeatTreeTooltip({e:r,opt:i,x:t,y:n,type:a.config.chart.type});t=p.x,n=p.y,u.style.left=t+"px",u.style.top=n+"px"}else this.tooltipUtil.hasBars()&&this.intersect.handleBarTooltip({e:r,opt:i}),this.tooltipUtil.hasMarkers()&&this.intersect.handleMarkerTooltip({e:r,opt:i,x:t,y:n});if(this.yaxisTooltips.length)for(var g=0;gl.width)this.handleMouseOut(r);else if(null!==s)this.handleStickyCapturedSeries(e,s,r,o);else if(this.tooltipUtil.isXoverlap(o)||i.globals.isBarHorizontal){var c=i.globals.series.findIndex((function(e,t){return!i.globals.collapsedSeriesIndices.includes(t)}));this.create(e,this,c,o,r.ttItems)}}},{key:"handleStickyCapturedSeries",value:function(e,t,n,r){var i=this.w;if(this.tConfig.shared||null!==i.globals.series[t][r]){if(void 0!==i.globals.series[t][r])this.tConfig.shared&&this.tooltipUtil.isXoverlap(r)&&this.tooltipUtil.isInitialSeriesSameLen()?this.create(e,this,t,r,n.ttItems):this.create(e,this,t,r,n.ttItems,!1);else if(this.tooltipUtil.isXoverlap(r)){var a=i.globals.series.findIndex((function(e,t){return!i.globals.collapsedSeriesIndices.includes(t)}));this.create(e,this,a,r,n.ttItems)}}else this.handleMouseOut(n)}},{key:"deactivateHoverFilter",value:function(){for(var e=this.w,t=new S(this.ctx),n=e.globals.dom.Paper.select(".apexcharts-bar-area"),r=0;r5&&void 0!==arguments[5]?arguments[5]:null,C=this.w,A=t;"mouseup"===e.type&&this.markerClick(e,n,r),null===k&&(k=this.tConfig.shared);var E=this.tooltipUtil.hasMarkers(n),P=this.tooltipUtil.getElBars();if(C.config.legend.tooltipHoverFormatter){var T=C.config.legend.tooltipHoverFormatter,M=Array.from(this.legendLabels);M.forEach((function(e){var t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(t)}));for(var _=0;_0?A.marker.enlargePoints(r):A.tooltipPosition.moveDynamicPointsOnHover(r);else if(this.tooltipUtil.hasBars()&&(this.barSeriesHeight=this.tooltipUtil.getBarsHeight(P),this.barSeriesHeight>0)){var D=new S(this.ctx),F=C.globals.dom.Paper.select(".apexcharts-bar-area[j='".concat(r,"']"));this.deactivateHoverFilter(),this.tooltipPosition.moveStickyTooltipOverBars(r,n);for(var N=0;N0&&r.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(f-=u*k)),w&&(f=f+h.height/2-x/2-2);var A=this.barCtx.series[i][a]<0,E=l;switch(this.barCtx.isReversed&&(E=l-d+(A?2*d:0),l-=d),m.position){case"center":p=w?A?E-d/2+y:E+d/2-y:A?E-d/2+h.height/2+y:E+d/2+h.height/2-y;break;case"bottom":p=w?A?E-d+y:E+d-y:A?E-d+h.height+x+y:E+d-h.height/2+x-y;break;case"top":p=w?A?E+y:E-y:A?E-h.height/2-y:E+h.height+y}if(this.barCtx.lastActiveBarSerieIndex===o&&v.enabled){var P=new S(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:o,j:a}),g.fontSize);t=A?E-P.height/2-y-v.offsetY+18:E+P.height+y+v.offsetY-18,n=f+v.offsetX}return r.config.chart.stacked||(p<0?p=0+x:p+h.height/3>r.globals.gridHeight&&(p=r.globals.gridHeight-x)),{bcx:c,bcy:l,dataLabelsX:f,dataLabelsY:p,totalDataLabelsX:n,totalDataLabelsY:t,totalDataLabelsAnchor:"middle"}}},{key:"calculateBarsDataLabelsPosition",value:function(e){var t=this.w,n=e.x,r=e.i,i=e.j,a=e.realIndex,o=e.groupIndex,s=e.bcy,l=e.barHeight,c=e.barWidth,u=e.textRects,d=e.dataLabelsX,h=e.strokeWidth,f=e.dataLabelsConfig,p=e.barDataLabelsConfig,g=e.barTotalDataLabelsConfig,m=e.offX,v=e.offY,x=t.globals.gridHeight/t.globals.dataPoints;c=Math.abs(c);var b,y,w=(s+=-1!==o?o*l:0)-(this.barCtx.isRangeBar?0:x)+l/2+u.height/2+v-3,k="start",C=this.barCtx.series[r][i]<0,A=n;switch(this.barCtx.isReversed&&(A=n+c-(C?2*c:0),n=t.globals.gridWidth-c),p.position){case"center":d=C?A+c/2-m:Math.max(u.width/2,A-c/2)+m;break;case"bottom":d=C?A+c-h-Math.round(u.width/2)-m:A-c+h+Math.round(u.width/2)+m;break;case"top":d=C?A-h+Math.round(u.width/2)-m:A-h-Math.round(u.width/2)+m}if(this.barCtx.lastActiveBarSerieIndex===a&&g.enabled){var E=new S(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:a,j:i}),f.fontSize);C?(b=A-h+Math.round(E.width/2)-m-g.offsetX-15,k="end"):b=A-h-Math.round(E.width/2)+m+g.offsetX+15,y=w+g.offsetY}return t.config.chart.stacked||(d<0?d=d+u.width+h:d+u.width/2>t.globals.gridWidth&&(d=t.globals.gridWidth-u.width-h)),{bcx:n,bcy:s,dataLabelsX:d,dataLabelsY:w,totalDataLabelsX:b,totalDataLabelsY:y,totalDataLabelsAnchor:k}}},{key:"drawCalculatedDataLabels",value:function(e){var t=e.x,n=e.y,r=e.val,i=e.i,o=e.j,s=e.textRects,l=e.barHeight,c=e.barWidth,u=e.dataLabelsConfig,d=this.w,h="rotate(0)";"vertical"===d.config.plotOptions.bar.dataLabels.orientation&&(h="rotate(-90, ".concat(t,", ").concat(n,")"));var f=new W(this.barCtx.ctx),p=new S(this.barCtx.ctx),g=u.formatter,m=null,v=d.globals.collapsedSeriesIndices.indexOf(i)>-1;if(u.enabled&&!v){m=p.group({class:"apexcharts-data-labels",transform:h});var x="";void 0!==r&&(x=g(r,a(a({},d),{},{seriesIndex:i,dataPointIndex:o,w:d}))),!r&&d.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(x="");var b=d.globals.series[i][o]<0,y=d.config.plotOptions.bar.dataLabels.position;"vertical"===d.config.plotOptions.bar.dataLabels.orientation&&("top"===y&&(u.textAnchor=b?"end":"start"),"center"===y&&(u.textAnchor="middle"),"bottom"===y&&(u.textAnchor=b?"end":"start")),this.barCtx.isRangeBar&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&cMath.abs(c)&&(x=""):s.height/1.6>Math.abs(l)&&(x=""));var w=a({},u);this.barCtx.isHorizontal&&r<0&&("start"===u.textAnchor?w.textAnchor="end":"end"===u.textAnchor&&(w.textAnchor="start")),f.plotDataLabelsText({x:t,y:n,text:x,i:i,j:o,parent:m,dataLabelsConfig:w,alwaysDrawDataLabel:!0,offsetCorrection:!0})}return m}},{key:"drawTotalDataLabels",value:function(e){var t,n=e.x,r=e.y,i=e.val,a=e.barWidth,o=e.barHeight,s=e.realIndex,l=e.textAnchor,c=e.barTotalDataLabelsConfig,u=this.w,d=new S(this.barCtx.ctx);return c.enabled&&void 0!==n&&void 0!==r&&this.barCtx.lastActiveBarSerieIndex===s&&(t=d.drawText({x:n-(!u.globals.isBarHorizontal&&u.globals.seriesGroups.length?a/u.globals.seriesGroups.length:0),y:r-(u.globals.isBarHorizontal&&u.globals.seriesGroups.length?o/u.globals.seriesGroups.length:0),foreColor:c.style.color,text:i,textAnchor:l,fontFamily:c.style.fontFamily,fontSize:c.style.fontSize,fontWeight:c.style.fontWeight})),t}}]),e}(),Se=function(){function e(t){s(this,e),this.w=t.w,this.barCtx=t}return c(e,[{key:"initVariables",value:function(e){var t=this.w;this.barCtx.series=e,this.barCtx.totalItems=0,this.barCtx.seriesLen=0,this.barCtx.visibleI=-1,this.barCtx.visibleItems=1;for(var n=0;n0&&(this.barCtx.seriesLen=this.barCtx.seriesLen+1,this.barCtx.totalItems+=e[n].length),t.globals.isXNumeric)for(var r=0;rt.globals.minX&&t.globals.seriesX[n][r]0&&(r=l.globals.minXDiff/d),(a=r/u*parseInt(this.barCtx.barOptions.columnWidth,10)/100)<1&&(a=1)}-1===String(this.barCtx.barOptions.columnWidth).indexOf("%")&&(a=parseInt(this.barCtx.barOptions.columnWidth,10)),o=l.globals.gridHeight-this.barCtx.baseLineY[this.barCtx.yaxisIndex]-(this.barCtx.isReversed?l.globals.gridHeight:0)+(this.barCtx.isReversed?2*this.barCtx.baseLineY[this.barCtx.yaxisIndex]:0),e=l.globals.padHorizontal+(r-a*this.barCtx.seriesLen)/2}return l.globals.barHeight=i,l.globals.barWidth=a,{x:e,y:t,yDivision:n,xDivision:r,barHeight:i,barWidth:a,zeroH:o,zeroW:s}}},{key:"initializeStackedPrevVars",value:function(e){var t=e.w;t.globals.hasSeriesGroups?t.globals.seriesGroups.forEach((function(t){e[t]||(e[t]={}),e[t].prevY=[],e[t].prevX=[],e[t].prevYF=[],e[t].prevXF=[],e[t].prevYVal=[],e[t].prevXVal=[]})):(e.prevY=[],e.prevX=[],e.prevYF=[],e.prevXF=[],e.prevYVal=[],e.prevXVal=[])}},{key:"initializeStackedXYVars",value:function(e){var t=e.w;t.globals.hasSeriesGroups?t.globals.seriesGroups.forEach((function(t){e[t]||(e[t]={}),e[t].xArrj=[],e[t].xArrjF=[],e[t].xArrjVal=[],e[t].yArrj=[],e[t].yArrjF=[],e[t].yArrjVal=[]})):(e.xArrj=[],e.xArrjF=[],e.xArrjVal=[],e.yArrj=[],e.yArrjF=[],e.yArrjVal=[])}},{key:"getPathFillColor",value:function(e,t,n,r){var i,a,o,s,l=this.w,c=new B(this.barCtx.ctx),u=null,d=this.barCtx.barOptions.distributed?n:t;return this.barCtx.barOptions.colors.ranges.length>0&&this.barCtx.barOptions.colors.ranges.map((function(r){e[t][n]>=r.from&&e[t][n]<=r.to&&(u=r.color)})),l.config.series[t].data[n]&&l.config.series[t].data[n].fillColor&&(u=l.config.series[t].data[n].fillColor),c.fillPath({seriesNumber:this.barCtx.barOptions.distributed?d:r,dataPointIndex:n,color:u,value:e[t][n],fillConfig:null===(i=l.config.series[t].data[n])||void 0===i?void 0:i.fill,fillType:null!==(a=l.config.series[t].data[n])&&void 0!==a&&null!==(o=a.fill)&&void 0!==o&&o.type?null===(s=l.config.series[t].data[n])||void 0===s?void 0:s.fill.type:Array.isArray(l.config.fill.type)?l.config.fill.type[t]:l.config.fill.type})}},{key:"getStrokeWidth",value:function(e,t,n){var r=0,i=this.w;return this.barCtx.series[e][t]?this.barCtx.isNullValue=!1:this.barCtx.isNullValue=!0,i.config.stroke.show&&(this.barCtx.isNullValue||(r=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[n]:this.barCtx.strokeWidth)),r}},{key:"shouldApplyRadius",value:function(e){var t=this.w,n=!1;return t.config.plotOptions.bar.borderRadius>0&&(t.config.chart.stacked&&"last"===t.config.plotOptions.bar.borderRadiusWhenStacked?this.barCtx.lastActiveBarSerieIndex===e&&(n=!0):n=!0),n}},{key:"barBackground",value:function(e){var t=e.j,n=e.i,r=e.x1,i=e.x2,a=e.y1,o=e.y2,s=e.elSeries,l=this.w,c=new S(this.barCtx.ctx),u=new X(this.barCtx.ctx).getActiveConfigSeriesIndex();if(this.barCtx.barOptions.colors.backgroundBarColors.length>0&&u===n){t>=this.barCtx.barOptions.colors.backgroundBarColors.length&&(t%=this.barCtx.barOptions.colors.backgroundBarColors.length);var d=this.barCtx.barOptions.colors.backgroundBarColors[t],h=c.drawRect(void 0!==r?r:0,void 0!==a?a:0,void 0!==i?i:l.globals.gridWidth,void 0!==o?o:l.globals.gridHeight,this.barCtx.barOptions.colors.backgroundBarRadius,d,this.barCtx.barOptions.colors.backgroundBarOpacity);s.add(h),h.node.classList.add("apexcharts-backgroundBar")}}},{key:"getColumnPaths",value:function(e){var t,n=e.barWidth,r=e.barXPosition,i=e.y1,a=e.y2,o=e.strokeWidth,s=e.seriesGroup,l=e.realIndex,c=e.i,u=e.j,d=e.w,h=new S(this.barCtx.ctx);(o=Array.isArray(o)?o[l]:o)||(o=0);var f=n,p=r;null!==(t=d.config.series[l].data[u])&&void 0!==t&&t.columnWidthOffset&&(p=r-d.config.series[l].data[u].columnWidthOffset/2,f=n+d.config.series[l].data[u].columnWidthOffset);var g=p,m=p+f;i+=.001,a+=.001;var v=h.move(g,i),x=h.move(g,i),b=h.line(m-o,i);if(d.globals.previousPaths.length>0&&(x=this.barCtx.getPreviousPath(l,u,!1)),v=v+h.line(g,a)+h.line(m-o,a)+h.line(m-o,i)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),x=x+h.line(g,i)+b+b+b+b+b+h.line(g,i)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(l)&&(v=h.roundPathCorners(v,d.config.plotOptions.bar.borderRadius)),d.config.chart.stacked){var y=this.barCtx;d.globals.hasSeriesGroups&&s&&(y=this.barCtx[s]),y.yArrj.push(a),y.yArrjF.push(Math.abs(i-a)),y.yArrjVal.push(this.barCtx.series[c][u])}return{pathTo:v,pathFrom:x}}},{key:"getBarpaths",value:function(e){var t,n=e.barYPosition,r=e.barHeight,i=e.x1,a=e.x2,o=e.strokeWidth,s=e.seriesGroup,l=e.realIndex,c=e.i,u=e.j,d=e.w,h=new S(this.barCtx.ctx);(o=Array.isArray(o)?o[l]:o)||(o=0);var f=n,p=r;null!==(t=d.config.series[l].data[u])&&void 0!==t&&t.barHeightOffset&&(f=n-d.config.series[l].data[u].barHeightOffset/2,p=r+d.config.series[l].data[u].barHeightOffset);var g=f,m=f+p;i+=.001,a+=.001;var v=h.move(i,g),x=h.move(i,g);d.globals.previousPaths.length>0&&(x=this.barCtx.getPreviousPath(l,u,!1));var b=h.line(i,m-o);if(v=v+h.line(a,g)+h.line(a,m-o)+b+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),x=x+h.line(i,g)+b+b+b+b+b+h.line(i,g)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(l)&&(v=h.roundPathCorners(v,d.config.plotOptions.bar.borderRadius)),d.config.chart.stacked){var y=this.barCtx;d.globals.hasSeriesGroups&&s&&(y=this.barCtx[s]),y.xArrj.push(a),y.xArrjF.push(Math.abs(i-a)),y.xArrjVal.push(this.barCtx.series[c][u])}return{pathTo:v,pathFrom:x}}},{key:"checkZeroSeries",value:function(e){for(var t=e.series,n=this.w,r=0;r2&&void 0!==arguments[2]&&!arguments[2]?null:t;return null!=e&&(n=t+e/this.barCtx.invertedYRatio-2*(this.barCtx.isReversed?e/this.barCtx.invertedYRatio:0)),n}},{key:"getYForValue",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&!arguments[2]?null:t;return null!=e&&(n=t-e/this.barCtx.yRatio[this.barCtx.yaxisIndex]+2*(this.barCtx.isReversed?e/this.barCtx.yRatio[this.barCtx.yaxisIndex]:0)),n}},{key:"getGoalValues",value:function(e,t,n,r,i){var o=this,s=this.w,l=[],c=function(r,i){var a;l.push((u(a={},e,"x"===e?o.getXForValue(r,t,!1):o.getYForValue(r,n,!1)),u(a,"attrs",i),a))};if(s.globals.seriesGoals[r]&&s.globals.seriesGoals[r][i]&&Array.isArray(s.globals.seriesGoals[r][i])&&s.globals.seriesGoals[r][i].forEach((function(e){c(e.value,e)})),this.barCtx.barOptions.isDumbbell&&s.globals.seriesRange.length){var d=this.barCtx.barOptions.dumbbellColors?this.barCtx.barOptions.dumbbellColors:s.globals.colors,h={strokeHeight:"x"===e?0:s.globals.markers.size[r],strokeWidth:"x"===e?s.globals.markers.size[r]:0,strokeDashArray:0,strokeLineCap:"round",strokeColor:Array.isArray(d[r])?d[r][0]:d[r]};c(s.globals.seriesRangeStart[r][i],h),c(s.globals.seriesRangeEnd[r][i],a(a({},h),{},{strokeColor:Array.isArray(d[r])?d[r][1]:d[r]}))}return l}},{key:"drawGoalLine",value:function(e){var t=e.barXPosition,n=e.barYPosition,r=e.goalX,i=e.goalY,a=e.barWidth,o=e.barHeight,s=new S(this.barCtx.ctx),l=s.group({className:"apexcharts-bar-goals-groups"});l.node.classList.add("apexcharts-element-hidden"),this.barCtx.w.globals.delayedElements.push({el:l.node}),l.attr("clip-path","url(#gridRectMarkerMask".concat(this.barCtx.w.globals.cuid,")"));var c=null;return this.barCtx.isHorizontal?Array.isArray(r)&&r.forEach((function(e){var t=void 0!==e.attrs.strokeHeight?e.attrs.strokeHeight:o/2,r=n+t+o/2;c=s.drawLine(e.x,r-2*t,e.x,r,e.attrs.strokeColor?e.attrs.strokeColor:void 0,e.attrs.strokeDashArray,e.attrs.strokeWidth?e.attrs.strokeWidth:2,e.attrs.strokeLineCap),l.add(c)})):Array.isArray(i)&&i.forEach((function(e){var n=void 0!==e.attrs.strokeWidth?e.attrs.strokeWidth:a/2,r=t+n+a/2;c=s.drawLine(r-2*n,e.y,r,e.y,e.attrs.strokeColor?e.attrs.strokeColor:void 0,e.attrs.strokeDashArray,e.attrs.strokeHeight?e.attrs.strokeHeight:2,e.attrs.strokeLineCap),l.add(c)})),l}},{key:"drawBarShadow",value:function(e){var t=e.prevPaths,n=e.currPaths,r=e.color,i=this.w,a=t.x,o=t.x1,s=t.barYPosition,l=n.x,c=n.x1,u=n.barYPosition,d=s+n.barHeight,h=new S(this.barCtx.ctx),f=new y,p=h.move(o,d)+h.line(a,d)+h.line(l,u)+h.line(c,u)+h.line(o,d)+("around"===i.config.plotOptions.bar.borderRadiusApplication?" Z":" z");return h.drawPath({d:p,fill:f.shadeColor(.5,y.rgb2hex(r)),stroke:"none",strokeWidth:0,fillOpacity:1,classes:"apexcharts-bar-shadows"})}},{key:"getZeroValueEncounters",value:function(e){var t=e.i,n=e.j,r=this.w,i=0,a=0;return r.globals.seriesPercent.forEach((function(e,r){e[n]&&i++,rthis.barOptions.dataLabels.maxItems&&console.warn("WARNING: DataLabels are enabled but there are too many to display. This may cause performance issue when rendering - ApexCharts");for(var s=0,l=0;s0&&(this.visibleI=this.visibleI+1);var b=0,w=0;this.yRatio.length>1&&(this.yaxisIndex=v),this.isReversed=n.config.yaxis[this.yaxisIndex]&&n.config.yaxis[this.yaxisIndex].reversed;var k=this.barHelpers.initialPositions();p=k.y,b=k.barHeight,u=k.yDivision,h=k.zeroW,f=k.x,w=k.barWidth,c=k.xDivision,d=k.zeroH,this.horizontal||m.push(f+w/2);var A=r.group({class:"apexcharts-datalabels","data:realIndex":v});n.globals.delayedElements.push({el:A.node}),A.node.classList.add("apexcharts-element-hidden");var E=r.group({class:"apexcharts-bar-goals-markers"}),P=r.group({class:"apexcharts-bar-shadows"});n.globals.delayedElements.push({el:P.node}),P.node.classList.add("apexcharts-element-hidden");for(var T=0;T0){var I=this.barHelpers.drawBarShadow({color:"string"==typeof O&&-1===(null==O?void 0:O.indexOf("url"))?O:y.hexToRgba(n.globals.colors[s]),prevPaths:this.pathArr[this.pathArr.length-1],currPaths:_});I&&P.add(I)}this.pathArr.push(_);var R=this.barHelpers.drawGoalLine({barXPosition:_.barXPosition,barYPosition:_.barYPosition,goalX:_.goalX,goalY:_.goalY,barHeight:b,barWidth:w});R&&E.add(R),p=_.y,f=_.x,T>0&&m.push(f+w/2),g.push(p),this.renderSeries({realIndex:v,pathFill:O,j:T,i:s,pathFrom:_.pathFrom,pathTo:_.pathTo,strokeWidth:M,elSeries:x,x:f,y:p,series:e,barHeight:_.barHeight?_.barHeight:b,barWidth:_.barWidth?_.barWidth:w,elDataLabelsWrap:A,elGoalsMarkers:E,elBarShadows:P,visibleSeries:this.visibleI,type:"bar"})}n.globals.seriesXvalues[v]=m,n.globals.seriesYvalues[v]=g,o.add(x)}return o}},{key:"renderSeries",value:function(e){var t=e.realIndex,n=e.pathFill,r=e.lineFill,i=e.j,a=e.i,o=e.groupIndex,s=e.pathFrom,l=e.pathTo,c=e.strokeWidth,u=e.elSeries,d=e.x,h=e.y,f=e.y1,p=e.y2,g=e.series,m=e.barHeight,v=e.barWidth,x=e.barXPosition,b=e.barYPosition,y=e.elDataLabelsWrap,w=e.elGoalsMarkers,C=e.elBarShadows,A=e.visibleSeries,E=e.type,P=this.w,T=new S(this.ctx);r||(r=this.barOptions.distributed?P.globals.stroke.colors[i]:P.globals.stroke.colors[t]),P.config.series[a].data[i]&&P.config.series[a].data[i].strokeColor&&(r=P.config.series[a].data[i].strokeColor),this.isNullValue&&(n="none");var M=i/P.config.chart.animations.animateGradually.delay*(P.config.chart.animations.speed/P.globals.dataPoints)/2.4,_=T.renderPaths({i:a,j:i,realIndex:t,pathFrom:s,pathTo:l,stroke:r,strokeWidth:c,strokeLineCap:P.config.stroke.lineCap,fill:n,animationDelay:M,initialSpeed:P.config.chart.animations.speed,dataChangeSpeed:P.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(E,"-area")});_.attr("clip-path","url(#gridRectMask".concat(P.globals.cuid,")"));var L=P.config.forecastDataPoints;L.count>0&&i>=P.globals.dataPoints-L.count&&(_.node.setAttribute("stroke-dasharray",L.dashArray),_.node.setAttribute("stroke-width",L.strokeWidth),_.node.setAttribute("fill-opacity",L.fillOpacity)),void 0!==f&&void 0!==p&&(_.attr("data-range-y1",f),_.attr("data-range-y2",p)),new k(this.ctx).setSelectionFilter(_,t,i),u.add(_);var O=new ke(this).handleBarDataLabels({x:d,y:h,y1:f,y2:p,i:a,j:i,series:g,realIndex:t,groupIndex:o,barHeight:m,barWidth:v,barXPosition:x,barYPosition:b,renderedPath:_,visibleSeries:A});return null!==O.dataLabels&&y.add(O.dataLabels),O.totalDataLabels&&y.add(O.totalDataLabels),u.add(y),w&&u.add(w),C&&u.add(C),u}},{key:"drawBarPaths",value:function(e){var t,n=e.indexes,r=e.barHeight,i=e.strokeWidth,a=e.zeroW,o=e.x,s=e.y,l=e.yDivision,c=e.elSeries,u=this.w,d=n.i,h=n.j;if(u.globals.isXNumeric)t=(s=(u.globals.seriesX[d][h]-u.globals.minX)/this.invertedXRatio-r)+r*this.visibleI;else if(u.config.plotOptions.bar.hideZeroBarsWhenGrouped){var f=0,p=0;u.globals.seriesPercent.forEach((function(e,t){e[h]&&f++,t0&&(r=this.seriesLen*r/f),t=s+r*this.visibleI,t-=r*p}else t=s+r*this.visibleI;this.isFunnel&&(a-=(this.barHelpers.getXForValue(this.series[d][h],a)-a)/2),o=this.barHelpers.getXForValue(this.series[d][h],a);var g=this.barHelpers.getBarpaths({barYPosition:t,barHeight:r,x1:a,x2:o,strokeWidth:i,series:this.series,realIndex:n.realIndex,i:d,j:h,w:u});return u.globals.isXNumeric||(s+=l),this.barHelpers.barBackground({j:h,i:d,y1:t-r*this.visibleI,y2:r*this.seriesLen,elSeries:c}),{pathTo:g.pathTo,pathFrom:g.pathFrom,x1:a,x:o,y:s,goalX:this.barHelpers.getGoalValues("x",a,null,d,h),barYPosition:t,barHeight:r}}},{key:"drawColumnPaths",value:function(e){var t,n=e.indexes,r=e.x,i=e.y,a=e.xDivision,o=e.barWidth,s=e.zeroH,l=e.strokeWidth,c=e.elSeries,u=this.w,d=n.realIndex,h=n.i,f=n.j,p=n.bc;if(u.globals.isXNumeric){var g=this.getBarXForNumericXAxis({x:r,j:f,realIndex:d,barWidth:o});r=g.x,t=g.barXPosition}else if(u.config.plotOptions.bar.hideZeroBarsWhenGrouped){var m=this.barHelpers.getZeroValueEncounters({i:h,j:f}),v=m.nonZeroColumns,x=m.zeroEncounters;v>0&&(o=this.seriesLen*o/v),t=r+o*this.visibleI,t-=o*x}else t=r+o*this.visibleI;i=this.barHelpers.getYForValue(this.series[h][f],s);var b=this.barHelpers.getColumnPaths({barXPosition:t,barWidth:o,y1:s,y2:i,strokeWidth:l,series:this.series,realIndex:n.realIndex,i:h,j:f,w:u});return u.globals.isXNumeric||(r+=a),this.barHelpers.barBackground({bc:p,j:f,i:h,x1:t-l/2-o*this.visibleI,x2:o*this.seriesLen+l/2,elSeries:c}),{pathTo:b.pathTo,pathFrom:b.pathFrom,x:r,y:i,goalY:this.barHelpers.getGoalValues("y",null,s,h,f),barXPosition:t,barWidth:o}}},{key:"getBarXForNumericXAxis",value:function(e){var t=e.x,n=e.barWidth,r=e.realIndex,i=e.j,a=this.w,o=r;return a.globals.seriesX[r].length||(o=a.globals.maxValsInArrayIndex),a.globals.seriesX[o][i]&&(t=(a.globals.seriesX[o][i]-a.globals.minX)/this.xRatio-n*this.seriesLen/2),{barXPosition:t+n*this.visibleI,x:t}}},{key:"getPreviousPath",value:function(e,t){for(var n,r=this.w,i=0;i0&&parseInt(a.realIndex,10)===parseInt(e,10)&&void 0!==r.globals.previousPaths[i].paths[t]&&(n=r.globals.previousPaths[i].paths[t].d)}return n}}]),e}(),Ae=function(e){d(n,Ce);var t=g(n);function n(){return s(this,n),t.apply(this,arguments)}return c(n,[{key:"draw",value:function(e,t){var n=this,r=this.w;this.graphics=new S(this.ctx),this.bar=new Ce(this.ctx,this.xyRatios);var i=new C(this.ctx,r);e=i.getLogSeries(e),this.yRatio=i.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e),"100%"===r.config.chart.stackType&&(e=r.globals.seriesPercent.slice()),this.series=e,this.barHelpers.initializeStackedPrevVars(this);for(var o=this.graphics.group({class:"apexcharts-bar-series apexcharts-plot-series"}),s=0,l=0,c=function(i,c){var u=void 0,d=void 0,h=void 0,f=void 0,p=-1;n.groupCtx=n,r.globals.seriesGroups.forEach((function(e,t){e.indexOf(r.config.series[i].name)>-1&&(p=t)})),-1!==p&&(n.groupCtx=n[r.globals.seriesGroups[p]]);var g=[],m=[],v=r.globals.comboCharts?t[i]:i;n.yRatio.length>1&&(n.yaxisIndex=v),n.isReversed=r.config.yaxis[n.yaxisIndex]&&r.config.yaxis[n.yaxisIndex].reversed;var x=n.graphics.group({class:"apexcharts-series",seriesName:y.escapeString(r.globals.seriesNames[v]),rel:i+1,"data:realIndex":v});n.ctx.series.addCollapsedClassToSeries(x,v);var b=n.graphics.group({class:"apexcharts-datalabels","data:realIndex":v}),w=n.graphics.group({class:"apexcharts-bar-goals-markers"}),k=0,S=0,C=n.initialPositions(s,l,u,d,h,f);l=C.y,k=C.barHeight,d=C.yDivision,f=C.zeroW,s=C.x,S=C.barWidth,u=C.xDivision,h=C.zeroH,r.globals.barHeight=k,r.globals.barWidth=S,n.barHelpers.initializeStackedXYVars(n),1===n.groupCtx.prevY.length&&n.groupCtx.prevY[0].every((function(e){return isNaN(e)}))&&(n.groupCtx.prevY[0]=n.groupCtx.prevY[0].map((function(e){return h})),n.groupCtx.prevYF[0]=n.groupCtx.prevYF[0].map((function(e){return 0})));for(var A=0;A1?(n=u.globals.minXDiff/this.xRatio)*parseInt(this.barOptions.columnWidth,10)/100:c*parseInt(u.config.plotOptions.bar.columnWidth,10)/100,-1===String(u.config.plotOptions.bar.columnWidth).indexOf("%")&&(c=parseInt(u.config.plotOptions.bar.columnWidth,10)),i=u.globals.gridHeight-this.baseLineY[this.yaxisIndex]-(this.isReversed?u.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[this.yaxisIndex]:0),e=u.globals.padHorizontal+(n-c)/2),{x:e,y:t,yDivision:r,xDivision:n,barHeight:null!==(o=u.globals.seriesGroups)&&void 0!==o&&o.length?l/u.globals.seriesGroups.length:l,barWidth:null!==(s=u.globals.seriesGroups)&&void 0!==s&&s.length?c/u.globals.seriesGroups.length:c,zeroH:i,zeroW:a}}},{key:"drawStackedBarPaths",value:function(e){for(var t,n=e.indexes,r=e.barHeight,i=e.strokeWidth,a=e.zeroW,o=e.x,s=e.y,l=e.groupIndex,c=e.seriesGroup,u=e.yDivision,d=e.elSeries,h=this.w,f=s+(-1!==l?l*r:0),p=n.i,g=n.j,m=0,v=0;v0){var b=a;this.groupCtx.prevXVal[x-1][g]<0?b=this.series[p][g]>=0?this.groupCtx.prevX[x-1][g]+m-2*(this.isReversed?m:0):this.groupCtx.prevX[x-1][g]:this.groupCtx.prevXVal[x-1][g]>=0&&(b=this.series[p][g]>=0?this.groupCtx.prevX[x-1][g]:this.groupCtx.prevX[x-1][g]-m+2*(this.isReversed?m:0)),t=b}else t=a;o=null===this.series[p][g]?t:t+this.series[p][g]/this.invertedYRatio-2*(this.isReversed?this.series[p][g]/this.invertedYRatio:0);var y=this.barHelpers.getBarpaths({barYPosition:f,barHeight:r,x1:t,x2:o,strokeWidth:i,series:this.series,realIndex:n.realIndex,seriesGroup:c,i:p,j:g,w:h});return this.barHelpers.barBackground({j:g,i:p,y1:f,y2:r,elSeries:d}),s+=u,{pathTo:y.pathTo,pathFrom:y.pathFrom,goalX:this.barHelpers.getGoalValues("x",a,null,p,g),barYPosition:f,x:o,y:s}}},{key:"drawStackedColumnPaths",value:function(e){var t=e.indexes,n=e.x,r=e.y,i=e.xDivision,a=e.barWidth,o=e.zeroH,s=e.groupIndex,l=e.seriesGroup,c=e.elSeries,u=this.w,d=t.i,h=t.j,f=t.bc;if(u.globals.isXNumeric){var p=u.globals.seriesX[d][h];p||(p=0),n=(p-u.globals.minX)/this.xRatio-a/2,u.globals.seriesGroups.length&&(n=(p-u.globals.minX)/this.xRatio-a/2*u.globals.seriesGroups.length)}for(var g,m=n+(-1!==s?s*a:0),v=0,x=0;x0&&!u.globals.isXNumeric||b>0&&u.globals.isXNumeric&&u.globals.seriesX[d-1][h]===u.globals.seriesX[d][h]){var y,w,k,S=Math.min(this.yRatio.length+1,d+1);if(void 0!==this.groupCtx.prevY[b-1]&&this.groupCtx.prevY[b-1].length)for(var C=1;C=0?k-v+2*(this.isReversed?v:0):k;break}if((null===(T=this.groupCtx.prevYVal[b-E])||void 0===T?void 0:T[h])>=0){w=this.series[d][h]>=0?k:k+v-2*(this.isReversed?v:0);break}}void 0===w&&(w=u.globals.gridHeight),g=null!==(y=this.groupCtx.prevYF[0])&&void 0!==y&&y.every((function(e){return 0===e}))&&this.groupCtx.prevYF.slice(1,b).every((function(e){return e.every((function(e){return isNaN(e)}))}))?o:w}else g=o;r=this.series[d][h]?g-this.series[d][h]/this.yRatio[this.yaxisIndex]+2*(this.isReversed?this.series[d][h]/this.yRatio[this.yaxisIndex]:0):g;var M=this.barHelpers.getColumnPaths({barXPosition:m,barWidth:a,y1:g,y2:r,yRatio:this.yRatio[this.yaxisIndex],strokeWidth:this.strokeWidth,series:this.series,seriesGroup:l,realIndex:t.realIndex,i:d,j:h,w:u});return this.barHelpers.barBackground({bc:f,j:h,i:d,x1:m,x2:a,elSeries:c}),n+=i,{pathTo:M.pathTo,pathFrom:M.pathFrom,goalY:this.barHelpers.getGoalValues("y",null,o,d,h),barXPosition:m,x:u.globals.isXNumeric?n-i:n,y:r}}}]),n}(),Ee=function(e){d(n,Ce);var t=g(n);function n(){return s(this,n),t.apply(this,arguments)}return c(n,[{key:"draw",value:function(e,t,n){var r=this,i=this.w,o=new S(this.ctx),s=i.globals.comboCharts?t:i.config.chart.type,l=new B(this.ctx);this.candlestickOptions=this.w.config.plotOptions.candlestick,this.boxOptions=this.w.config.plotOptions.boxPlot,this.isHorizontal=i.config.plotOptions.bar.horizontal;var c=new C(this.ctx,i);e=c.getLogSeries(e),this.series=e,this.yRatio=c.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e);for(var u=o.group({class:"apexcharts-".concat(s,"-series apexcharts-plot-series")}),d=function(t){r.isBoxPlot="boxPlot"===i.config.chart.type||"boxPlot"===i.config.series[t].type;var s,c,d,h,f,p,g=void 0,m=void 0,v=[],x=[],b=i.globals.comboCharts?n[t]:t,w=o.group({class:"apexcharts-series",seriesName:y.escapeString(i.globals.seriesNames[b]),rel:t+1,"data:realIndex":b});r.ctx.series.addCollapsedClassToSeries(w,b),e[t].length>0&&(r.visibleI=r.visibleI+1),r.yRatio.length>1&&(r.yaxisIndex=b);var k=r.barHelpers.initialPositions();m=k.y,f=k.barHeight,c=k.yDivision,h=k.zeroW,g=k.x,p=k.barWidth,s=k.xDivision,d=k.zeroH,x.push(g+p/2);for(var S=o.group({class:"apexcharts-datalabels","data:realIndex":b}),C=function(n){var o=r.barHelpers.getStrokeWidth(t,n,b),u=null,y={indexes:{i:t,j:n,realIndex:b},x:g,y:m,strokeWidth:o,elSeries:w};u=r.isHorizontal?r.drawHorizontalBoxPaths(a(a({},y),{},{yDivision:c,barHeight:f,zeroW:h})):r.drawVerticalBoxPaths(a(a({},y),{},{xDivision:s,barWidth:p,zeroH:d})),m=u.y,g=u.x,n>0&&x.push(g+p/2),v.push(m),u.pathTo.forEach((function(a,s){var c=!r.isBoxPlot&&r.candlestickOptions.wick.useFillColor?u.color[s]:i.globals.stroke.colors[t],d=l.fillPath({seriesNumber:b,dataPointIndex:n,color:u.color[s],value:e[t][n]});r.renderSeries({realIndex:b,pathFill:d,lineFill:c,j:n,i:t,pathFrom:u.pathFrom,pathTo:a,strokeWidth:o,elSeries:w,x:g,y:m,series:e,barHeight:f,barWidth:p,elDataLabelsWrap:S,visibleSeries:r.visibleI,type:i.config.chart.type})}))},A=0;Av.c&&(d=!1);var y=Math.min(v.o,v.c),w=Math.max(v.o,v.c),k=v.m;s.globals.isXNumeric&&(n=(s.globals.seriesX[m][u]-s.globals.minX)/this.xRatio-i/2);var C=n+i*this.visibleI;void 0===this.series[c][u]||null===this.series[c][u]?(y=a,w=a):(y=a-y/g,w=a-w/g,x=a-v.h/g,b=a-v.l/g,k=a-v.m/g);var A=l.move(C,a),E=l.move(C+i/2,y);return s.globals.previousPaths.length>0&&(E=this.getPreviousPath(m,u,!0)),A=this.isBoxPlot?[l.move(C,y)+l.line(C+i/2,y)+l.line(C+i/2,x)+l.line(C+i/4,x)+l.line(C+i-i/4,x)+l.line(C+i/2,x)+l.line(C+i/2,y)+l.line(C+i,y)+l.line(C+i,k)+l.line(C,k)+l.line(C,y+o/2),l.move(C,k)+l.line(C+i,k)+l.line(C+i,w)+l.line(C+i/2,w)+l.line(C+i/2,b)+l.line(C+i-i/4,b)+l.line(C+i/4,b)+l.line(C+i/2,b)+l.line(C+i/2,w)+l.line(C,w)+l.line(C,k)+"z"]:[l.move(C,w)+l.line(C+i/2,w)+l.line(C+i/2,x)+l.line(C+i/2,w)+l.line(C+i,w)+l.line(C+i,y)+l.line(C+i/2,y)+l.line(C+i/2,b)+l.line(C+i/2,y)+l.line(C,y)+l.line(C,w-o/2)],E+=l.move(C,y),s.globals.isXNumeric||(n+=r),{pathTo:A,pathFrom:E,x:n,y:w,barXPosition:C,color:this.isBoxPlot?p:d?[h]:[f]}}},{key:"drawHorizontalBoxPaths",value:function(e){var t=e.indexes;e.x;var n=e.y,r=e.yDivision,i=e.barHeight,a=e.zeroW,o=e.strokeWidth,s=this.w,l=new S(this.ctx),c=t.i,u=t.j,d=this.boxOptions.colors.lower;this.isBoxPlot&&(d=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var h=this.invertedYRatio,f=t.realIndex,p=this.getOHLCValue(f,u),g=a,m=a,v=Math.min(p.o,p.c),x=Math.max(p.o,p.c),b=p.m;s.globals.isXNumeric&&(n=(s.globals.seriesX[f][u]-s.globals.minX)/this.invertedXRatio-i/2);var y=n+i*this.visibleI;void 0===this.series[c][u]||null===this.series[c][u]?(v=a,x=a):(v=a+v/h,x=a+x/h,g=a+p.h/h,m=a+p.l/h,b=a+p.m/h);var w=l.move(a,y),k=l.move(v,y+i/2);return s.globals.previousPaths.length>0&&(k=this.getPreviousPath(f,u,!0)),w=[l.move(v,y)+l.line(v,y+i/2)+l.line(g,y+i/2)+l.line(g,y+i/2-i/4)+l.line(g,y+i/2+i/4)+l.line(g,y+i/2)+l.line(v,y+i/2)+l.line(v,y+i)+l.line(b,y+i)+l.line(b,y)+l.line(v+o/2,y),l.move(b,y)+l.line(b,y+i)+l.line(x,y+i)+l.line(x,y+i/2)+l.line(m,y+i/2)+l.line(m,y+i-i/4)+l.line(m,y+i/4)+l.line(m,y+i/2)+l.line(x,y+i/2)+l.line(x,y)+l.line(b,y)+"z"],k+=l.move(v,y),s.globals.isXNumeric||(n+=r),{pathTo:w,pathFrom:k,x:x,y:n,barYPosition:y,color:d}}},{key:"getOHLCValue",value:function(e,t){var n=this.w;return{o:this.isBoxPlot?n.globals.seriesCandleH[e][t]:n.globals.seriesCandleO[e][t],h:this.isBoxPlot?n.globals.seriesCandleO[e][t]:n.globals.seriesCandleH[e][t],m:n.globals.seriesCandleM[e][t],l:this.isBoxPlot?n.globals.seriesCandleC[e][t]:n.globals.seriesCandleL[e][t],c:this.isBoxPlot?n.globals.seriesCandleL[e][t]:n.globals.seriesCandleC[e][t]}}}]),n}(),Pe=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"checkColorRange",value:function(){var e=this.w,t=!1,n=e.config.plotOptions[e.config.chart.type];return n.colorScale.ranges.length>0&&n.colorScale.ranges.map((function(e,n){e.from<=0&&(t=!0)})),t}},{key:"getShadeColor",value:function(e,t,n,r){var i=this.w,a=1,o=i.config.plotOptions[e].shadeIntensity,s=this.determineColor(e,t,n);i.globals.hasNegs||r?a=i.config.plotOptions[e].reverseNegativeShade?s.percent<0?s.percent/100*(1.25*o):(1-s.percent/100)*(1.25*o):s.percent<=0?1-(1+s.percent/100)*o:(1-s.percent/100)*o:(a=1-s.percent/100,"treemap"===e&&(a=(1-s.percent/100)*(1.25*o)));var l=s.color,c=new y;return i.config.plotOptions[e].enableShades&&(l="dark"===this.w.config.theme.mode?y.hexToRgba(c.shadeColor(-1*a,s.color),i.config.fill.opacity):y.hexToRgba(c.shadeColor(a,s.color),i.config.fill.opacity)),{color:l,colorProps:s}}},{key:"determineColor",value:function(e,t,n){var r=this.w,i=r.globals.series[t][n],a=r.config.plotOptions[e],o=a.colorScale.inverse?n:t;a.distributed&&"treemap"===r.config.chart.type&&(o=n);var s=r.globals.colors[o],l=null,c=Math.min.apply(Math,v(r.globals.series[t])),u=Math.max.apply(Math,v(r.globals.series[t]));a.distributed||"heatmap"!==e||(c=r.globals.minY,u=r.globals.maxY),void 0!==a.colorScale.min&&(c=a.colorScale.minr.globals.maxY?a.colorScale.max:r.globals.maxY);var d=Math.abs(u)+Math.abs(c),h=100*i/(0===d?d-1e-6:d);return a.colorScale.ranges.length>0&&a.colorScale.ranges.map((function(e,t){if(i>=e.from&&i<=e.to){s=e.color,l=e.foreColor?e.foreColor:null,c=e.from,u=e.to;var n=Math.abs(u)+Math.abs(c);h=100*i/(0===n?n-1e-6:n)}})),{color:s,foreColor:l,percent:h}}},{key:"calculateDataLabels",value:function(e){var t=e.text,n=e.x,r=e.y,i=e.i,a=e.j,o=e.colorProps,s=e.fontSize,l=this.w.config.dataLabels,c=new S(this.ctx),u=new W(this.ctx),d=null;if(l.enabled){d=c.group({class:"apexcharts-data-labels"});var h=l.offsetX,f=l.offsetY,p=n+h,g=r+parseFloat(l.style.fontSize)/3+f;u.plotDataLabelsText({x:p,y:g,text:t,i:i,j:a,color:o.foreColor,parent:d,fontSize:s,dataLabelsConfig:l})}return d}},{key:"addListeners",value:function(e){var t=new S(this.ctx);e.node.addEventListener("mouseenter",t.pathMouseEnter.bind(this,e)),e.node.addEventListener("mouseleave",t.pathMouseLeave.bind(this,e)),e.node.addEventListener("mousedown",t.pathMouseDown.bind(this,e))}}]),e}(),Te=function(){function e(t,n){s(this,e),this.ctx=t,this.w=t.w,this.xRatio=n.xRatio,this.yRatio=n.yRatio,this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.helpers=new Pe(t),this.rectRadius=this.w.config.plotOptions.heatmap.radius,this.strokeWidth=this.w.config.stroke.show?this.w.config.stroke.width:0}return c(e,[{key:"draw",value:function(e){var t=this.w,n=new S(this.ctx),r=n.group({class:"apexcharts-heatmap"});r.attr("clip-path","url(#gridRectMask".concat(t.globals.cuid,")"));var i=t.globals.gridWidth/t.globals.dataPoints,a=t.globals.gridHeight/t.globals.series.length,o=0,s=!1;this.negRange=this.helpers.checkColorRange();var l=e.slice();t.config.yaxis[0].reversed&&(s=!0,l.reverse());for(var c=s?0:l.length-1;s?c=0;s?c++:c--){var u=n.group({class:"apexcharts-series apexcharts-heatmap-series",seriesName:y.escapeString(t.globals.seriesNames[c]),rel:c+1,"data:realIndex":c});if(this.ctx.series.addCollapsedClassToSeries(u,c),t.config.chart.dropShadow.enabled){var d=t.config.chart.dropShadow;new k(this.ctx).dropShadow(u,d,c)}for(var h=0,f=t.config.plotOptions.heatmap.shadeIntensity,p=0;p-1&&this.pieClicked(d),n.config.dataLabels.enabled){var w=x.x,C=x.y,A=100*f/this.fullAngle+"%";if(0!==f&&n.config.plotOptions.pie.dataLabels.minAngleToShowLabelthis.fullAngle?t.endAngle=t.endAngle-(r+o):r+o=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle&&(c=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle-.01),Math.ceil(c)>this.fullAngle&&(c-=this.fullAngle);var u=Math.PI*(c-90)/180,d=n.centerX+a*Math.cos(l),h=n.centerY+a*Math.sin(l),f=n.centerX+a*Math.cos(u),p=n.centerY+a*Math.sin(u),g=y.polarToCartesian(n.centerX,n.centerY,n.donutSize,c),m=y.polarToCartesian(n.centerX,n.centerY,n.donutSize,s),v=i>180?1:0,x=["M",d,h,"A",a,a,0,v,1,f,p];return t="donut"===n.chartType?[].concat(x,["L",g.x,g.y,"A",n.donutSize,n.donutSize,0,v,0,m.x,m.y,"L",d,h,"z"]).join(" "):"pie"===n.chartType||"polarArea"===n.chartType?[].concat(x,["L",n.centerX,n.centerY,"L",d,h]).join(" "):[].concat(x).join(" "),o.roundPathCorners(t,2*this.strokeWidth)}},{key:"drawPolarElements",value:function(e){var t=this.w,n=new $(this.ctx),r=new S(this.ctx),i=new Me(this.ctx),a=r.group(),o=r.group(),s=n.niceScale(0,Math.ceil(this.maxY),t.config.yaxis[0].tickAmount,0,!0),l=s.result.reverse(),c=s.result.length;this.maxY=s.niceMax;for(var u=t.globals.radialSize,d=u/(c-1),h=0;h1&&e.total.show&&(i=e.total.color);var o=a.globals.dom.baseEl.querySelector(".apexcharts-datalabel-label"),s=a.globals.dom.baseEl.querySelector(".apexcharts-datalabel-value");n=(0,e.value.formatter)(n,a),r||"function"!=typeof e.total.formatter||(n=e.total.formatter(a));var l=t===e.total.label;t=e.name.formatter(t,l,a),null!==o&&(o.textContent=t),null!==s&&(s.textContent=n),null!==o&&(o.style.fill=i)}},{key:"printDataLabelsInner",value:function(e,t){var n=this.w,r=e.getAttribute("data:value"),i=n.globals.seriesNames[parseInt(e.parentNode.getAttribute("rel"),10)-1];n.globals.series.length>1&&this.printInnerLabels(t,i,r,e);var a=n.globals.dom.baseEl.querySelector(".apexcharts-datalabels-group");null!==a&&(a.style.opacity=1)}},{key:"drawSpokes",value:function(e){var t=this,n=this.w,r=new S(this.ctx),i=n.config.plotOptions.polarArea.spokes;if(0!==i.strokeWidth){for(var a=[],o=360/n.globals.series.length,s=0;s1)o&&!t.total.showAlways?l({makeSliceOut:!1,printLabel:!0}):this.printInnerLabels(t,t.total.label,t.total.formatter(i));else if(l({makeSliceOut:!1,printLabel:!0}),!o)if(i.globals.selectedDataPoints.length&&i.globals.series.length>1)if(i.globals.selectedDataPoints[0].length>0){var c=i.globals.selectedDataPoints[0],u=i.globals.dom.baseEl.querySelector(".apexcharts-".concat(this.chartType.toLowerCase(),"-slice-").concat(c));this.printDataLabelsInner(u,t)}else a&&i.globals.selectedDataPoints.length&&0===i.globals.selectedDataPoints[0].length&&(a.style.opacity=0);else a&&i.globals.series.length>1&&(a.style.opacity=0)}}]),e}(),Le=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.chartType=this.w.config.chart.type,this.initialAnim=this.w.config.chart.animations.enabled,this.dynamicAnim=this.initialAnim&&this.w.config.chart.animations.dynamicAnimation.enabled,this.animDur=0;var n=this.w;this.graphics=new S(this.ctx),this.lineColorArr=void 0!==n.globals.stroke.colors?n.globals.stroke.colors:n.globals.colors,this.defaultSize=n.globals.svgHeight0&&(g=t.getPreviousPath(s));for(var m=0;m=10?e.x>0?(n="start",r+=10):e.x<0&&(n="end",r-=10):n="middle",Math.abs(e.y)>=t-10&&(e.y<0?i-=10:e.y>0&&(i+=10)),{textAnchor:n,newX:r,newY:i}}},{key:"getPreviousPath",value:function(e){for(var t=this.w,n=null,r=0;r0&&parseInt(i.realIndex,10)===parseInt(e,10)&&void 0!==t.globals.previousPaths[r].paths[0]&&(n=t.globals.previousPaths[r].paths[0].d)}return n}},{key:"getDataPointsPos",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.dataPointsLen;e=e||[],t=t||[];for(var r=[],i=0;i=360&&(h=360-Math.abs(this.startAngle)-.1);var f=n.drawPath({d:"",stroke:u,strokeWidth:o*parseInt(c.strokeWidth,10)/100,fill:"none",strokeOpacity:c.opacity,classes:"apexcharts-radialbar-area"});if(c.dropShadow.enabled){var p=c.dropShadow;i.dropShadow(f,p)}l.add(f),f.attr("id","apexcharts-radialbarTrack-"+s),this.animatePaths(f,{centerX:e.centerX,centerY:e.centerY,endAngle:h,startAngle:d,size:e.size,i:s,totalItems:2,animBeginArr:0,dur:0,isTrack:!0,easing:t.globals.easing})}return r}},{key:"drawArcs",value:function(e){var t=this.w,n=new S(this.ctx),r=new B(this.ctx),i=new k(this.ctx),a=n.group(),o=this.getStrokeWidth(e);e.size=e.size-o/2;var s=t.config.plotOptions.radialBar.hollow.background,l=e.size-o*e.series.length-this.margin*e.series.length-o*parseInt(t.config.plotOptions.radialBar.track.strokeWidth,10)/100/2,c=l-t.config.plotOptions.radialBar.hollow.margin;void 0!==t.config.plotOptions.radialBar.hollow.image&&(s=this.drawHollowImage(e,a,l,s));var u=this.drawHollow({size:c,centerX:e.centerX,centerY:e.centerY,fill:s||"transparent"});if(t.config.plotOptions.radialBar.hollow.dropShadow.enabled){var d=t.config.plotOptions.radialBar.hollow.dropShadow;i.dropShadow(u,d)}var h=1;!this.radialDataLabels.total.show&&t.globals.series.length>1&&(h=0);var f=null;this.radialDataLabels.show&&(f=this.renderInnerDataLabels(this.radialDataLabels,{hollowSize:l,centerX:e.centerX,centerY:e.centerY,opacity:h})),"back"===t.config.plotOptions.radialBar.hollow.position&&(a.add(u),f&&a.add(f));var p=!1;t.config.plotOptions.radialBar.inverseOrder&&(p=!0);for(var g=p?e.series.length-1:0;p?g>=0:g100?100:e.series[g])/100,C=Math.round(this.totalAngle*w)+this.startAngle,A=void 0;t.globals.dataChanged&&(b=this.startAngle,A=Math.round(this.totalAngle*y.negToZero(t.globals.previousPaths[g])/100)+b),Math.abs(C)+Math.abs(x)>=360&&(C-=.01),Math.abs(A)+Math.abs(b)>=360&&(A-=.01);var E=C-x,P=Array.isArray(t.config.stroke.dashArray)?t.config.stroke.dashArray[g]:t.config.stroke.dashArray,T=n.drawPath({d:"",stroke:v,strokeWidth:o,fill:"none",fillOpacity:t.config.fill.opacity,classes:"apexcharts-radialbar-area apexcharts-radialbar-slice-"+g,strokeDashArray:P});if(S.setAttrs(T.node,{"data:angle":E,"data:value":e.series[g]}),t.config.chart.dropShadow.enabled){var M=t.config.chart.dropShadow;i.dropShadow(T,M,g)}if(i.setSelectionFilter(T,0,g),this.addListeners(T,this.radialDataLabels),m.add(T),T.attr({index:0,j:g}),this.barLabels.enabled){var _=y.polarToCartesian(e.centerX,e.centerY,e.size,x),L=this.barLabels.formatter(t.globals.seriesNames[g],{seriesIndex:g,w:t}),O=["apexcharts-radialbar-label"];this.barLabels.onClick||O.push("apexcharts-no-click");var I=this.barLabels.useSeriesColors?t.globals.colors[g]:t.config.chart.foreColor;I||(I=t.config.chart.foreColor);var R=_.x-this.barLabels.margin,z=_.y,D=n.drawText({x:R,y:z,text:L,textAnchor:"end",dominantBaseline:"middle",fontFamily:this.barLabels.fontFamily,fontWeight:this.barLabels.fontWeight,fontSize:this.barLabels.fontSize,foreColor:I,cssClass:O.join(" ")});D.on("click",this.onBarLabelClick),D.attr({rel:g+1}),0!==x&&D.attr({"transform-origin":"".concat(R," ").concat(z),transform:"rotate(".concat(x," 0 0)")}),m.add(D)}var F=0;!this.initialAnim||t.globals.resized||t.globals.dataChanged||(F=t.config.chart.animations.speed),t.globals.dataChanged&&(F=t.config.chart.animations.dynamicAnimation.speed),this.animDur=F/(1.2*e.series.length)+this.animDur,this.animBeginArr.push(this.animDur),this.animatePaths(T,{centerX:e.centerX,centerY:e.centerY,endAngle:C,startAngle:x,prevEndAngle:A,prevStartAngle:b,size:e.size,i:g,totalItems:2,animBeginArr:this.animBeginArr,dur:F,shouldSetPrevPaths:!0,easing:t.globals.easing})}return{g:a,elHollow:u,dataLabels:f}}},{key:"drawHollow",value:function(e){var t=new S(this.ctx).drawCircle(2*e.size);return t.attr({class:"apexcharts-radialbar-hollow",cx:e.centerX,cy:e.centerY,r:e.size,fill:e.fill}),t}},{key:"drawHollowImage",value:function(e,t,n,r){var i=this.w,a=new B(this.ctx),o=y.randomId(),s=i.config.plotOptions.radialBar.hollow.image;if(i.config.plotOptions.radialBar.hollow.imageClipped)a.clippedImgArea({width:n,height:n,image:s,patternID:"pattern".concat(i.globals.cuid).concat(o)}),r="url(#pattern".concat(i.globals.cuid).concat(o,")");else{var l=i.config.plotOptions.radialBar.hollow.imageWidth,c=i.config.plotOptions.radialBar.hollow.imageHeight;if(void 0===l&&void 0===c){var u=i.globals.dom.Paper.image(s).loaded((function(t){this.move(e.centerX-t.width/2+i.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-t.height/2+i.config.plotOptions.radialBar.hollow.imageOffsetY)}));t.add(u)}else{var d=i.globals.dom.Paper.image(s).loaded((function(t){this.move(e.centerX-l/2+i.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-c/2+i.config.plotOptions.radialBar.hollow.imageOffsetY),this.size(l,c)}));t.add(d)}}return r}},{key:"getStrokeWidth",value:function(e){var t=this.w;return e.size*(100-parseInt(t.config.plotOptions.radialBar.hollow.size,10))/100/(e.series.length+1)-this.margin}},{key:"onBarLabelClick",value:function(e){var t=parseInt(e.target.getAttribute("rel"),10)-1,n=this.barLabels.onClick,r=this.w;n&&n(r.globals.seriesNames[t],{w:r,seriesIndex:t})}}]),n}(),Ie=function(e){d(n,Ce);var t=g(n);function n(){return s(this,n),t.apply(this,arguments)}return c(n,[{key:"draw",value:function(e,t){var n=this.w,r=new S(this.ctx);this.rangeBarOptions=this.w.config.plotOptions.rangeBar,this.series=e,this.seriesRangeStart=n.globals.seriesRangeStart,this.seriesRangeEnd=n.globals.seriesRangeEnd,this.barHelpers.initVariables(e);for(var i=r.group({class:"apexcharts-rangebar-series apexcharts-plot-series"}),o=0;o0&&(this.visibleI=this.visibleI+1);var m=0,v=0;this.yRatio.length>1&&(this.yaxisIndex=p);var x=this.barHelpers.initialPositions();f=x.y,d=x.zeroW,h=x.x,v=x.barWidth,m=x.barHeight,s=x.xDivision,l=x.yDivision,c=x.zeroH;for(var b=r.group({class:"apexcharts-datalabels","data:realIndex":p}),w=r.group({class:"apexcharts-rangebar-goals-markers"}),k=0;k0}));return this.isHorizontal?(r=h.config.plotOptions.bar.rangeBarGroupRows?a+c*v:a+s*this.visibleI+c*v,x>-1&&!h.config.plotOptions.bar.rangeBarOverlap&&(f=h.globals.seriesRange[t][x].overlaps).indexOf(p)>-1&&(r=(s=d.barHeight/f.length)*this.visibleI+c*(100-parseInt(this.barOptions.barHeight,10))/100/2+s*(this.visibleI+f.indexOf(p))+c*v)):(v>-1&&(i=h.config.plotOptions.bar.rangeBarGroupRows?o+u*v:o+l*this.visibleI+u*v),x>-1&&!h.config.plotOptions.bar.rangeBarOverlap&&(f=h.globals.seriesRange[t][x].overlaps).indexOf(p)>-1&&(i=(l=d.barWidth/f.length)*this.visibleI+u*(100-parseInt(this.barOptions.barWidth,10))/100/2+l*(this.visibleI+f.indexOf(p))+u*v)),{barYPosition:r,barXPosition:i,barHeight:s,barWidth:l}}},{key:"drawRangeColumnPaths",value:function(e){var t=e.indexes,n=e.x,r=e.xDivision,i=e.barWidth,a=e.barXPosition,o=e.zeroH,s=this.w,l=t.i,c=t.j,u=this.yRatio[this.yaxisIndex],d=t.realIndex,h=this.getRangeValue(d,c),f=Math.min(h.start,h.end),p=Math.max(h.start,h.end);void 0===this.series[l][c]||null===this.series[l][c]?f=o:(f=o-f/u,p=o-p/u);var g=Math.abs(p-f),m=this.barHelpers.getColumnPaths({barXPosition:a,barWidth:i,y1:f,y2:p,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,realIndex:t.realIndex,i:d,j:c,w:s});if(s.globals.isXNumeric){var v=this.getBarXForNumericXAxis({x:n,j:c,realIndex:d,barWidth:i});n=v.x,a=v.barXPosition}else n+=r;return{pathTo:m.pathTo,pathFrom:m.pathFrom,barHeight:g,x:n,y:p,goalY:this.barHelpers.getGoalValues("y",null,o,l,c),barXPosition:a}}},{key:"drawRangeBarPaths",value:function(e){var t=e.indexes,n=e.y,r=e.y1,i=e.y2,a=e.yDivision,o=e.barHeight,s=e.barYPosition,l=e.zeroW,c=this.w,u=l+r/this.invertedYRatio,d=l+i/this.invertedYRatio,h=Math.abs(d-u),f=this.barHelpers.getBarpaths({barYPosition:s,barHeight:o,x1:u,x2:d,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,i:t.realIndex,realIndex:t.realIndex,j:t.j,w:c});return c.globals.isXNumeric||(n+=a),{pathTo:f.pathTo,pathFrom:f.pathFrom,barWidth:h,x:d,goalX:this.barHelpers.getGoalValues("x",l,null,t.realIndex,t.j),y:n}}},{key:"getRangeValue",value:function(e,t){var n=this.w;return{start:n.globals.seriesRangeStart[e][t],end:n.globals.seriesRangeEnd[e][t]}}}]),n}(),Re=function(){function e(t){s(this,e),this.w=t.w,this.lineCtx=t}return c(e,[{key:"sameValueSeriesFix",value:function(e,t){var n=this.w;if(("gradient"===n.config.fill.type||"gradient"===n.config.fill.type[e])&&new C(this.lineCtx.ctx,n).seriesHaveSameValues(e)){var r=t[e].slice();r[r.length-1]=r[r.length-1]+1e-6,t[e]=r}return t}},{key:"calculatePoints",value:function(e){var t=e.series,n=e.realIndex,r=e.x,i=e.y,a=e.i,o=e.j,s=e.prevY,l=this.w,c=[],u=[];if(0===o){var d=this.lineCtx.categoryAxisCorrection+l.config.markers.offsetX;l.globals.isXNumeric&&(d=(l.globals.seriesX[n][0]-l.globals.minX)/this.lineCtx.xRatio+l.config.markers.offsetX),c.push(d),u.push(y.isNumber(t[a][0])?s+l.config.markers.offsetY:null),c.push(r+l.config.markers.offsetX),u.push(y.isNumber(t[a][o+1])?i+l.config.markers.offsetY:null)}else c.push(r+l.config.markers.offsetX),u.push(y.isNumber(t[a][o+1])?i+l.config.markers.offsetY:null);return{x:c,y:u}}},{key:"checkPreviousPaths",value:function(e){for(var t=e.pathFromLine,n=e.pathFromArea,r=e.realIndex,i=this.w,a=0;a0&&parseInt(o.realIndex,10)===parseInt(r,10)&&("line"===o.type?(this.lineCtx.appendPathFrom=!1,t=i.globals.previousPaths[a].paths[0].d):"area"===o.type&&(this.lineCtx.appendPathFrom=!1,n=i.globals.previousPaths[a].paths[0].d,i.config.stroke.show&&i.globals.previousPaths[a].paths[1]&&(t=i.globals.previousPaths[a].paths[1].d)))}return{pathFromLine:t,pathFromArea:n}}},{key:"determineFirstPrevY",value:function(e){var t,n,r=e.i,i=e.series,a=e.prevY,o=e.lineYPosition,s=this.w,l=s.config.chart.stacked&&!s.globals.comboCharts||s.config.chart.stacked&&s.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||"bar"===(null===(t=this.w.config.series[r])||void 0===t?void 0:t.type));if(void 0!==(null===(n=i[r])||void 0===n?void 0:n[0]))a=(o=l&&r>0?this.lineCtx.prevSeriesY[r-1][0]:this.lineCtx.zeroY)-i[r][0]/this.lineCtx.yRatio[this.lineCtx.yaxisIndex]+2*(this.lineCtx.isReversed?i[r][0]/this.lineCtx.yRatio[this.lineCtx.yaxisIndex]:0);else if(l&&r>0&&void 0===i[r][0])for(var c=r-1;c>=0;c--)if(null!==i[c][0]&&void 0!==i[c][0]){a=o=this.lineCtx.prevSeriesY[c][0];break}return{prevY:a,lineYPosition:o}}}]),e}(),ze=function(e,t){for(var n="",r=0;r1&&Math.abs(i[o-2]-a[s-2])4?(n+="C".concat(i[0],", ").concat(i[1]),n+=", ".concat(i[2],", ").concat(i[3]),n+=", ".concat(i[4],", ").concat(i[5])):o>2&&(n+="S".concat(i[0],", ").concat(i[1]),n+=", ".concat(i[2],", ").concat(i[3]))}return n},De=function(e){var t=function(e){for(var t,n,r,i,a=function(e){for(var t=[],n=e[0],r=e[1],i=t[0]=Fe(n,r),a=1,o=e.length-1;a9&&(i=3*r/Math.sqrt(i),a[l]=i*t,a[l+1]=i*n);for(var c=0;c<=o;c++)i=(e[Math.min(o,c+1)][0]-e[Math.max(0,c-1)][0])/(6*(1+a[c]*a[c])),s.push([i||0,a[c]*i||0]);return s}(e),n=e[1],r=e[0],i=[],a=t[1],o=t[0];i.push(r,[r[0]+o[0],r[1]+o[1],n[0]-a[0],n[1]-a[1],n[0],n[1]]);for(var s=2,l=t.length;s0&&(v=(o.globals.seriesX[f][0]-o.globals.minX)/this.xRatio),m.push(v);var x=v,b=this.zeroY,y=this.zeroY;b=this.lineHelpers.determineFirstPrevY({i:h,series:e,prevY:b,lineYPosition:0}).prevY,"smooth"===o.config.stroke.curve&&null===e[h][0]?p.push(null):p.push(b),"rangeArea"===l&&(y=this.lineHelpers.determineFirstPrevY({i:h,series:r,prevY:y,lineYPosition:0}).prevY,g.push(y));var w={type:l,series:e,realIndex:f,i:h,x:v,y:1,pathsFrom:this._calculatePathsFrom({type:l,series:e,i:h,realIndex:f,prevX:x,prevY:b,prevY2:y}),linePaths:[],areaPaths:[],seriesIndex:n,lineYPosition:0,xArrj:m,yArrj:p,y2Arrj:g,seriesRangeEnd:r},k=this._iterateOverDataPoints(a(a({},w),{},{iterations:"rangeArea"===l?e[h].length-1:void 0,isRangeStart:!0}));if("rangeArea"===l){var A=this._calculatePathsFrom({series:r,i:h,realIndex:f,prevX:x,prevY:y}),E=this._iterateOverDataPoints(a(a({},w),{},{series:r,pathsFrom:A,iterations:r[h].length-1,isRangeStart:!1}));k.linePaths[0]=E.linePath+k.linePath,k.pathFromLine=E.pathFromLine+k.pathFromLine}this._handlePaths({type:l,realIndex:f,i:h,paths:k}),this.elSeries.add(this.elPointsMain),this.elSeries.add(this.elDataLabelsWrap),d.push(this.elSeries)}if(void 0!==(null===(i=o.config.series[0])||void 0===i?void 0:i.zIndex)&&d.sort((function(e,t){return Number(e.node.getAttribute("zIndex"))-Number(t.node.getAttribute("zIndex"))})),o.config.chart.stacked)for(var P=d.length;P>0;P--)c.add(d[P-1]);else for(var T=0;T1&&(this.yaxisIndex=n),this.isReversed=r.config.yaxis[this.yaxisIndex]&&r.config.yaxis[this.yaxisIndex].reversed,this.zeroY=r.globals.gridHeight-this.baseLineY[this.yaxisIndex]-(this.isReversed?r.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[this.yaxisIndex]:0),this.areaBottomY=this.zeroY,(this.zeroY>r.globals.gridHeight||"end"===r.config.plotOptions.area.fillTo)&&(this.areaBottomY=r.globals.gridHeight),this.categoryAxisCorrection=this.xDivision/2,this.elSeries=i.group({class:"apexcharts-series",zIndex:void 0!==r.config.series[n].zIndex?r.config.series[n].zIndex:n,seriesName:y.escapeString(r.globals.seriesNames[n])}),this.elPointsMain=i.group({class:"apexcharts-series-markers-wrap","data:realIndex":n}),this.elDataLabelsWrap=i.group({class:"apexcharts-datalabels","data:realIndex":n});var a=e[t].length===r.globals.dataPoints;this.elSeries.attr({"data:longestSeries":a,rel:t+1,"data:realIndex":n}),this.appendPathFrom=!0}},{key:"_calculatePathsFrom",value:function(e){var t,n,r,i,a=e.type,o=e.series,s=e.i,l=e.realIndex,c=e.prevX,u=e.prevY,d=e.prevY2,h=this.w,f=new S(this.ctx);if(null===o[s][0]){for(var p=0;p0){var g=this.lineHelpers.checkPreviousPaths({pathFromLine:r,pathFromArea:i,realIndex:l});r=g.pathFromLine,i=g.pathFromArea}return{prevX:c,prevY:u,linePath:t,areaPath:n,pathFromLine:r,pathFromArea:i}}},{key:"_handlePaths",value:function(e){var t=e.type,n=e.realIndex,r=e.i,i=e.paths,o=this.w,s=new S(this.ctx),l=new B(this.ctx);this.prevSeriesY.push(i.yArrj),o.globals.seriesXvalues[n]=i.xArrj,o.globals.seriesYvalues[n]=i.yArrj;var c=o.config.forecastDataPoints;if(c.count>0&&"rangeArea"!==t){var u=o.globals.seriesXvalues[n][o.globals.seriesXvalues[n].length-c.count-1],d=s.drawRect(u,0,o.globals.gridWidth,o.globals.gridHeight,0);o.globals.dom.elForecastMask.appendChild(d.node);var h=s.drawRect(0,0,u,o.globals.gridHeight,0);o.globals.dom.elNonForecastMask.appendChild(h.node)}this.pointsChart||o.globals.delayedElements.push({el:this.elPointsMain.node,index:n});var f={i:r,realIndex:n,animationDelay:r,initialSpeed:o.config.chart.animations.speed,dataChangeSpeed:o.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(t)};if("area"===t)for(var p=l.fillPath({seriesNumber:n}),g=0;g0&&"rangeArea"!==t){var C=s.renderPaths(w);C.node.setAttribute("stroke-dasharray",c.dashArray),c.strokeWidth&&C.node.setAttribute("stroke-width",c.strokeWidth),this.elSeries.add(C),C.attr("clip-path","url(#forecastMask".concat(o.globals.cuid,")")),k.attr("clip-path","url(#nonForecastMask".concat(o.globals.cuid,")"))}}}}},{key:"_iterateOverDataPoints",value:function(e){var t,n=this,r=e.type,i=e.series,a=e.iterations,o=e.realIndex,s=e.i,l=e.x,c=e.y,u=e.pathsFrom,d=e.linePaths,h=e.areaPaths,f=e.seriesIndex,p=e.lineYPosition,g=e.xArrj,m=e.yArrj,v=e.y2Arrj,x=e.isRangeStart,b=e.seriesRangeEnd,w=this.w,k=new S(this.ctx),C=this.yRatio,A=u.prevY,E=u.linePath,P=u.areaPath,T=u.pathFromLine,M=u.pathFromArea,_=y.isNumber(w.globals.minYArr[o])?w.globals.minYArr[o]:w.globals.minY;a||(a=w.globals.dataPoints>1?w.globals.dataPoints-1:w.globals.dataPoints);for(var L=function(e,t){return t-e/C[n.yaxisIndex]+2*(n.isReversed?e/C[n.yaxisIndex]:0)},O=c,I=w.config.chart.stacked&&!w.globals.comboCharts||w.config.chart.stacked&&w.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||"bar"===(null===(t=this.w.config.series[o])||void 0===t?void 0:t.type)),R=0;R0&&w.globals.collapsedSeries.length-1){t--;break}return t>=0?t:0}(s-1)][R+1]:this.zeroY,z?c=L(_,p):(c=L(i[s][R+1],p),"rangeArea"===r&&(O=L(b[s][R+1],p))),g.push(l),z&&"smooth"===w.config.stroke.curve?m.push(null):m.push(c),v.push(O);var F=this.lineHelpers.calculatePoints({series:i,x:l,y:c,realIndex:o,i:s,j:R,prevY:A}),N=this._createPaths({type:r,series:i,i:s,realIndex:o,j:R,x:l,y:c,y2:O,xArrj:g,yArrj:m,y2Arrj:v,linePath:E,areaPath:P,linePaths:d,areaPaths:h,seriesIndex:f,isRangeStart:x});h=N.areaPaths,d=N.linePaths,P=N.areaPath,E=N.linePath,!this.appendPathFrom||"smooth"===w.config.stroke.curve&&"rangeArea"===r||(T+=k.line(l,this.zeroY),M+=k.line(l,this.zeroY)),this.handleNullDataPoints(i,F,s,R,o),this._handleMarkersAndLabels({type:r,pointsPos:F,i:s,j:R,realIndex:o,isRangeStart:x})}return{yArrj:m,xArrj:g,pathFromArea:M,areaPaths:h,pathFromLine:T,linePaths:d,linePath:E,areaPath:P}}},{key:"_handleMarkersAndLabels",value:function(e){var t=e.type,n=e.pointsPos,r=e.isRangeStart,i=e.i,a=e.j,o=e.realIndex,s=this.w,l=new W(this.ctx);if(this.pointsChart)this.scatter.draw(this.elSeries,a,{realIndex:o,pointsPos:n,zRatio:this.zRatio,elParent:this.elPointsMain});else{s.globals.series[i].length>1&&this.elPointsMain.node.classList.add("apexcharts-element-hidden");var c=this.markers.plotChartMarkers(n,o,a+1);null!==c&&this.elPointsMain.add(c)}var u=l.drawDataLabel({type:t,isRangeStart:r,pos:n,i:o,j:a+1});null!==u&&this.elDataLabelsWrap.add(u)}},{key:"_createPaths",value:function(e){var t=e.type,n=e.series,r=e.i,i=e.realIndex,a=e.j,o=e.x,s=e.y,l=e.xArrj,c=e.yArrj,u=e.y2,d=e.y2Arrj,h=e.linePath,f=e.areaPath,p=e.linePaths,g=e.areaPaths,m=e.seriesIndex,v=e.isRangeStart,x=this.w,b=new S(this.ctx),y=x.config.stroke.curve,w=this.areaBottomY;if(Array.isArray(x.config.stroke.curve)&&(y=Array.isArray(m)?x.config.stroke.curve[m[r]]:x.config.stroke.curve[r]),"rangeArea"===t&&(x.globals.hasNullValues||x.config.forecastDataPoints.count>0)&&"smooth"===y&&(y="straight"),"smooth"===y){var k="rangeArea"===t?l.length===x.globals.dataPoints:a===n[r].length-2,C=l.map((function(e,t){return[l[t],c[t]]})).filter((function(e){return null!==e[1]}));if(k&&C.length>1){var A=De(C);if(h+=ze(A,x.globals.gridWidth),null===n[r][0]?f=h:f+=ze(A,x.globals.gridWidth),"rangeArea"===t&&v){h+=b.line(l[l.length-1],d[d.length-1]);var E=l.slice().reverse(),P=d.slice().reverse(),T=E.map((function(e,t){return[E[t],P[t]]})),M=De(T);f=h+=ze(M,x.globals.gridWidth)}else f+=b.line(C[C.length-1][0],w)+b.line(C[0][0],w)+b.move(C[0][0],C[0][1])+"z";p.push(h),g.push(f)}}else{if(null===n[r][a+1]){h+=b.move(o,s);var _=x.globals.isXNumeric?(x.globals.seriesX[i][a]-x.globals.minX)/this.xRatio:o-this.xDivision;f=f+b.line(_,w)+b.move(o,s)+"z"}null===n[r][a]&&(h+=b.move(o,s),f+=b.move(o,w)),"stepline"===y?(h=h+b.line(o,null,"H")+b.line(null,s,"V"),f=f+b.line(o,null,"H")+b.line(null,s,"V")):"straight"===y&&(h+=b.line(o,s),f+=b.line(o,s)),a===n[r].length-2&&(f=f+b.line(o,w)+b.move(o,s)+"z","rangeArea"===t&&v?h=h+b.line(o,u)+b.move(o,u)+"z":(p.push(h),g.push(f)))}return{linePaths:p,areaPaths:g,linePath:h,areaPath:f}}},{key:"handleNullDataPoints",value:function(e,t,n,r,i){var a=this.w;if(null===e[n][r]&&a.config.markers.showNullDataPoints||1===e[n].length){var o=this.markers.plotChartMarkers(t,i,r+1,this.strokeWidth-a.config.markers.strokeWidth/2,!0);null!==o&&this.elPointsMain.add(o)}}}]),e}();window.TreemapSquared={},window.TreemapSquared.generate=function(){function e(t,n,r,i){this.xoffset=t,this.yoffset=n,this.height=i,this.width=r,this.shortestEdge=function(){return Math.min(this.height,this.width)},this.getCoordinates=function(e){var t,n=[],r=this.xoffset,i=this.yoffset,o=a(e)/this.height,s=a(e)/this.width;if(this.width>=this.height)for(t=0;t=this.height){var r=t/this.height,i=this.width-r;n=new e(this.xoffset+r,this.yoffset,i,this.height)}else{var a=t/this.width,o=this.height-a;n=new e(this.xoffset,this.yoffset+a,this.width,o)}return n}}function t(t,r,i,o,s){o=void 0===o?0:o,s=void 0===s?0:s;var l=n(function(e,t){var n,r=[],i=t/a(e);for(n=0;n=r(i,n))}(t,l=e[0],s)?(t.push(l),n(e.slice(1),t,i,o)):(c=i.cutArea(a(t),o),o.push(i.getCoordinates(t)),n(e,[],c,o)),o;o.push(i.getCoordinates(t))}function r(e,t){var n=Math.min.apply(Math,e),r=Math.max.apply(Math,e),i=a(e);return Math.max(Math.pow(t,2)*r/Math.pow(i,2),Math.pow(i,2)/(Math.pow(t,2)*n))}function i(e){return e&&e.constructor===Array}function a(e){var t,n=0;for(t=0;ta-r&&l.width<=o-i){var c=s.rotateAroundCenter(e.node);e.node.setAttribute("transform","rotate(-90 ".concat(c.x," ").concat(c.y,") translate(").concat(l.height/3,")"))}}},{key:"truncateLabels",value:function(e,t,n,r,i,a){var o=new S(this.ctx),s=o.getTextRects(e,t).width+this.w.config.stroke.width+5>i-n&&a-r>i-n?a-r:i-n,l=o.getTextBasedOnMaxWidth({text:e,maxWidth:s,fontSize:t});return e.length!==l.length&&s/t<5?"":l}},{key:"animateTreemap",value:function(e,t,n,r){var i=new w(this.ctx);i.animateRect(e,{x:t.x,y:t.y,width:t.width,height:t.height},{x:n.x,y:n.y,width:n.width,height:n.height},r,(function(){i.animationCompleted(e)}))}}]),e}(),He=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w,this.timeScaleArray=[],this.utc=this.w.config.xaxis.labels.datetimeUTC}return c(e,[{key:"calculateTimeScaleTicks",value:function(e,t){var n=this,r=this.w;if(r.globals.allSeriesCollapsed)return r.globals.labels=[],r.globals.timescaleLabels=[],[];var i=new O(this.ctx),o=(t-e)/864e5;this.determineInterval(o),r.globals.disableZoomIn=!1,r.globals.disableZoomOut=!1,o<.00011574074074074075?r.globals.disableZoomIn=!0:o>5e4&&(r.globals.disableZoomOut=!0);var s=i.getTimeUnitsfromTimestamp(e,t,this.utc),l=r.globals.gridWidth/o,c=l/24,u=c/60,d=u/60,h=Math.floor(24*o),f=Math.floor(1440*o),p=Math.floor(86400*o),g=Math.floor(o),m=Math.floor(o/30),v=Math.floor(o/365),x={minMillisecond:s.minMillisecond,minSecond:s.minSecond,minMinute:s.minMinute,minHour:s.minHour,minDate:s.minDate,minMonth:s.minMonth,minYear:s.minYear},b={firstVal:x,currentMillisecond:x.minMillisecond,currentSecond:x.minSecond,currentMinute:x.minMinute,currentHour:x.minHour,currentMonthDate:x.minDate,currentDate:x.minDate,currentMonth:x.minMonth,currentYear:x.minYear,daysWidthOnXAxis:l,hoursWidthOnXAxis:c,minutesWidthOnXAxis:u,secondsWidthOnXAxis:d,numberOfSeconds:p,numberOfMinutes:f,numberOfHours:h,numberOfDays:g,numberOfMonths:m,numberOfYears:v};switch(this.tickInterval){case"years":this.generateYearScale(b);break;case"months":case"half_year":this.generateMonthScale(b);break;case"months_days":case"months_fortnight":case"days":case"week_days":this.generateDayScale(b);break;case"hours":this.generateHourScale(b);break;case"minutes_fives":case"minutes":this.generateMinuteScale(b);break;case"seconds_tens":case"seconds_fives":case"seconds":this.generateSecondScale(b)}var y=this.timeScaleArray.map((function(e){var t={position:e.position,unit:e.unit,year:e.year,day:e.day?e.day:1,hour:e.hour?e.hour:0,month:e.month+1};return"month"===e.unit?a(a({},t),{},{day:1,value:e.value+1}):"day"===e.unit||"hour"===e.unit?a(a({},t),{},{value:e.value}):"minute"===e.unit?a(a({},t),{},{value:e.value,minute:e.value}):"second"===e.unit?a(a({},t),{},{value:e.value,minute:e.minute,second:e.second}):e}));return y.filter((function(e){var t=1,i=Math.ceil(r.globals.gridWidth/120),a=e.value;void 0!==r.config.xaxis.tickAmount&&(i=r.config.xaxis.tickAmount),y.length>i&&(t=Math.floor(y.length/i));var o=!1,s=!1;switch(n.tickInterval){case"years":"year"===e.unit&&(o=!0);break;case"half_year":t=7,"year"===e.unit&&(o=!0);break;case"months":t=1,"year"===e.unit&&(o=!0);break;case"months_fortnight":t=15,"year"!==e.unit&&"month"!==e.unit||(o=!0),30===a&&(s=!0);break;case"months_days":t=10,"month"===e.unit&&(o=!0),30===a&&(s=!0);break;case"week_days":t=8,"month"===e.unit&&(o=!0);break;case"days":t=1,"month"===e.unit&&(o=!0);break;case"hours":"day"===e.unit&&(o=!0);break;case"minutes_fives":case"seconds_fives":a%5!=0&&(s=!0);break;case"seconds_tens":a%10!=0&&(s=!0)}if("hours"===n.tickInterval||"minutes_fives"===n.tickInterval||"seconds_tens"===n.tickInterval||"seconds_fives"===n.tickInterval){if(!s)return!0}else if((a%t==0||o)&&!s)return!0}))}},{key:"recalcDimensionsBasedOnFormat",value:function(e,t){var n=this.w,r=this.formatDates(e),i=this.removeOverlappingTS(r);n.globals.timescaleLabels=i.slice(),new ue(this.ctx).plotCoords()}},{key:"determineInterval",value:function(e){var t=24*e,n=60*t;switch(!0){case e/365>5:this.tickInterval="years";break;case e>800:this.tickInterval="half_year";break;case e>180:this.tickInterval="months";break;case e>90:this.tickInterval="months_fortnight";break;case e>60:this.tickInterval="months_days";break;case e>30:this.tickInterval="week_days";break;case e>2:this.tickInterval="days";break;case t>2.4:this.tickInterval="hours";break;case n>15:this.tickInterval="minutes_fives";break;case n>5:this.tickInterval="minutes";break;case n>1:this.tickInterval="seconds_tens";break;case 60*n>20:this.tickInterval="seconds_fives";break;default:this.tickInterval="seconds"}}},{key:"generateYearScale",value:function(e){var t=e.firstVal,n=e.currentMonth,r=e.currentYear,i=e.daysWidthOnXAxis,a=e.numberOfYears,o=t.minYear,s=0,l=new O(this.ctx),c="year";if(t.minDate>1||t.minMonth>0){var u=l.determineRemainingDaysOfYear(t.minYear,t.minMonth,t.minDate);s=(l.determineDaysOfYear(t.minYear)-u+1)*i,o=t.minYear+1,this.timeScaleArray.push({position:s,value:o,unit:c,year:o,month:y.monthMod(n+1)})}else 1===t.minDate&&0===t.minMonth&&this.timeScaleArray.push({position:s,value:o,unit:c,year:r,month:y.monthMod(n+1)});for(var d=o,h=s,f=0;f1){l=(c.determineDaysOfMonths(r+1,t.minYear)-n+1)*a,s=y.monthMod(r+1);var h=i+d,f=y.monthMod(s),p=s;0===s&&(u="year",p=h,f=1,h+=d+=1),this.timeScaleArray.push({position:l,value:p,unit:u,year:h,month:f})}else this.timeScaleArray.push({position:l,value:s,unit:u,year:i,month:y.monthMod(r)});for(var g=s+1,m=l,v=0,x=1;vo.determineDaysOfMonths(t+1,n)?(c=1,s="month",h=t+=1,t):t},d=(24-t.minHour)*i,h=l,f=u(c,n,r);0===t.minHour&&1===t.minDate?(d=0,h=y.monthMod(t.minMonth),s="month",c=t.minDate):1!==t.minDate&&0===t.minHour&&0===t.minMinute&&(d=0,l=t.minDate,h=l,f=u(c=l,n,r)),this.timeScaleArray.push({position:d,value:h,unit:s,year:this._getYear(r,f,0),month:y.monthMod(f),day:c});for(var p=d,g=0;gs.determineDaysOfMonths(t+1,i)&&(g=1,t+=1),{month:t,date:g}},u=function(e,t){return e>s.determineDaysOfMonths(t+1,i)?t+=1:t},d=60-(t.minMinute+t.minSecond/60),h=d*a,f=t.minHour+1,p=f;60===d&&(h=0,p=f=t.minHour);var g=n;p>=24&&(p=0,g+=1,l="day");var m=c(g,r).month;m=u(g,m),this.timeScaleArray.push({position:h,value:f,unit:l,day:g,hour:p,year:i,month:y.monthMod(m)}),p++;for(var v=h,x=0;x=24&&(p=0,l="day",m=c(g+=1,m).month,m=u(g,m));var b=this._getYear(i,m,0);v=60*a+v;var w=0===p?g:p;this.timeScaleArray.push({position:v,value:w,unit:l,hour:p,day:g,year:b,month:y.monthMod(m)}),p++}}},{key:"generateMinuteScale",value:function(e){for(var t=e.currentMillisecond,n=e.currentSecond,r=e.currentMinute,i=e.currentHour,a=e.currentDate,o=e.currentMonth,s=e.currentYear,l=e.minutesWidthOnXAxis,c=e.secondsWidthOnXAxis,u=e.numberOfMinutes,d=r+1,h=a,f=o,p=s,g=i,m=(60-n-t/1e3)*c,v=0;v=60&&(d=0,24===(g+=1)&&(g=0)),this.timeScaleArray.push({position:m,value:d,unit:"minute",hour:g,minute:d,day:h,year:this._getYear(p,f,0),month:y.monthMod(f)}),m+=l,d++}},{key:"generateSecondScale",value:function(e){for(var t=e.currentMillisecond,n=e.currentSecond,r=e.currentMinute,i=e.currentHour,a=e.currentDate,o=e.currentMonth,s=e.currentYear,l=e.secondsWidthOnXAxis,c=e.numberOfSeconds,u=n+1,d=r,h=a,f=o,p=s,g=i,m=(1e3-t)/1e3*l,v=0;v=60&&(u=0,++d>=60&&(d=0,24===++g&&(g=0))),this.timeScaleArray.push({position:m,value:u,unit:"second",hour:g,minute:d,second:u,day:h,year:this._getYear(p,f,0),month:y.monthMod(f)}),m+=l,u++}},{key:"createRawDateString",value:function(e,t){var n=e.year;return 0===e.month&&(e.month=1),n+="-"+("0"+e.month.toString()).slice(-2),"day"===e.unit?n+="day"===e.unit?"-"+("0"+t).slice(-2):"-01":n+="-"+("0"+(e.day?e.day:"1")).slice(-2),"hour"===e.unit?n+="hour"===e.unit?"T"+("0"+t).slice(-2):"T00":n+="T"+("0"+(e.hour?e.hour:"0")).slice(-2),"minute"===e.unit?n+=":"+("0"+t).slice(-2):n+=":"+(e.minute?("0"+e.minute).slice(-2):"00"),"second"===e.unit?n+=":"+("0"+t).slice(-2):n+=":00",this.utc&&(n+=".000Z"),n}},{key:"formatDates",value:function(e){var t=this,n=this.w;return e.map((function(e){var r=e.value.toString(),i=new O(t.ctx),a=t.createRawDateString(e,r),o=i.getDate(i.parseDate(a));if(t.utc||(o=i.getDate(i.parseDateWithTimezone(a))),void 0===n.config.xaxis.labels.format){var s="dd MMM",l=n.config.xaxis.labels.datetimeFormatter;"year"===e.unit&&(s=l.year),"month"===e.unit&&(s=l.month),"day"===e.unit&&(s=l.day),"hour"===e.unit&&(s=l.hour),"minute"===e.unit&&(s=l.minute),"second"===e.unit&&(s=l.second),r=i.formatDate(o,s)}else r=i.formatDate(o,n.config.xaxis.labels.format);return{dateString:a,position:e.position,value:r,unit:e.unit,year:e.year,month:e.month}}))}},{key:"removeOverlappingTS",value:function(e){var t,n=this,r=new S(this.ctx),i=!1;e.length>0&&e[0].value&&e.every((function(t){return t.value.length===e[0].value.length}))&&(i=!0,t=r.getTextRects(e[0].value).width);var a=0,o=e.map((function(o,s){if(s>0&&n.w.config.xaxis.labels.hideOverlappingLabels){var l=i?t:r.getTextRects(e[a].value).width,c=e[a].position;return o.position>c+l+10?(a=s,o):null}return o}));return o.filter((function(e){return null!==e}))}},{key:"_getYear",value:function(e,t,n){return e+Math.floor(t/12)+n}}]),e}(),We=function(){function e(t,n){s(this,e),this.ctx=n,this.w=n.w,this.el=t}return c(e,[{key:"setupElements",value:function(){var e=this.w.globals,t=this.w.config,n=t.chart.type;e.axisCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble","radar","heatmap","treemap"].indexOf(n)>-1,e.xyCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble"].indexOf(n)>-1,e.isBarHorizontal=("bar"===t.chart.type||"rangeBar"===t.chart.type||"boxPlot"===t.chart.type)&&t.plotOptions.bar.horizontal,e.chartClass=".apexcharts"+e.chartID,e.dom.baseEl=this.el,e.dom.elWrap=document.createElement("div"),S.setAttrs(e.dom.elWrap,{id:e.chartClass.substring(1),class:"apexcharts-canvas "+e.chartClass.substring(1)}),this.el.appendChild(e.dom.elWrap),e.dom.Paper=new window.SVG.Doc(e.dom.elWrap),e.dom.Paper.attr({class:"apexcharts-svg","xmlns:data":"ApexChartsNS",transform:"translate(".concat(t.chart.offsetX,", ").concat(t.chart.offsetY,")")}),e.dom.Paper.node.style.background="dark"!==t.theme.mode||t.chart.background?t.chart.background:"rgba(0, 0, 0, 0.8)",this.setSVGDimensions(),e.dom.elLegendForeign=document.createElementNS(e.SVGNS,"foreignObject"),S.setAttrs(e.dom.elLegendForeign,{x:0,y:0,width:e.svgWidth,height:e.svgHeight}),e.dom.elLegendWrap=document.createElement("div"),e.dom.elLegendWrap.classList.add("apexcharts-legend"),e.dom.elLegendWrap.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),e.dom.elLegendForeign.appendChild(e.dom.elLegendWrap),e.dom.Paper.node.appendChild(e.dom.elLegendForeign),e.dom.elGraphical=e.dom.Paper.group().attr({class:"apexcharts-inner apexcharts-graphical"}),e.dom.elDefs=e.dom.Paper.defs(),e.dom.Paper.add(e.dom.elGraphical),e.dom.elGraphical.add(e.dom.elDefs)}},{key:"plotChartType",value:function(e,t){var n=this.w,r=n.config,i=n.globals,a={series:[],i:[]},o={series:[],i:[]},s={series:[],i:[]},l={series:[],i:[]},c={series:[],i:[]},u={series:[],i:[]},d={series:[],i:[]},h={series:[],i:[]},f={series:[],seriesRangeEnd:[],i:[]};i.series.map((function(t,p){var g=0;void 0!==e[p].type?("column"===e[p].type||"bar"===e[p].type?(i.series.length>1&&r.plotOptions.bar.horizontal&&console.warn("Horizontal bars are not supported in a mixed/combo chart. Please turn off `plotOptions.bar.horizontal`"),c.series.push(t),c.i.push(p),g++,n.globals.columnSeries=c.series):"area"===e[p].type?(o.series.push(t),o.i.push(p),g++):"line"===e[p].type?(a.series.push(t),a.i.push(p),g++):"scatter"===e[p].type?(s.series.push(t),s.i.push(p)):"bubble"===e[p].type?(l.series.push(t),l.i.push(p),g++):"candlestick"===e[p].type?(u.series.push(t),u.i.push(p),g++):"boxPlot"===e[p].type?(d.series.push(t),d.i.push(p),g++):"rangeBar"===e[p].type?(h.series.push(t),h.i.push(p),g++):"rangeArea"===e[p].type?(f.series.push(i.seriesRangeStart[p]),f.seriesRangeEnd.push(i.seriesRangeEnd[p]),f.i.push(p),g++):console.warn("You have specified an unrecognized chart type. Available types for this property are line/area/column/bar/scatter/bubble/candlestick/boxPlot/rangeBar/rangeArea"),g>1&&(i.comboCharts=!0)):(a.series.push(t),a.i.push(p))}));var p=new Ne(this.ctx,t),g=new Ee(this.ctx,t);this.ctx.pie=new _e(this.ctx);var m=new Oe(this.ctx);this.ctx.rangeBar=new Ie(this.ctx,t);var v=new Le(this.ctx),x=[];if(i.comboCharts){if(o.series.length>0&&x.push(p.draw(o.series,"area",o.i)),c.series.length>0)if(n.config.chart.stacked){var b=new Ae(this.ctx,t);x.push(b.draw(c.series,c.i))}else this.ctx.bar=new Ce(this.ctx,t),x.push(this.ctx.bar.draw(c.series,c.i));if(f.series.length>0&&x.push(p.draw(f.series,"rangeArea",f.i,f.seriesRangeEnd)),a.series.length>0&&x.push(p.draw(a.series,"line",a.i)),u.series.length>0&&x.push(g.draw(u.series,"candlestick",u.i)),d.series.length>0&&x.push(g.draw(d.series,"boxPlot",d.i)),h.series.length>0&&x.push(this.ctx.rangeBar.draw(h.series,h.i)),s.series.length>0){var y=new Ne(this.ctx,t,!0);x.push(y.draw(s.series,"scatter",s.i))}if(l.series.length>0){var w=new Ne(this.ctx,t,!0);x.push(w.draw(l.series,"bubble",l.i))}}else switch(r.chart.type){case"line":x=p.draw(i.series,"line");break;case"area":x=p.draw(i.series,"area");break;case"bar":r.chart.stacked?x=new Ae(this.ctx,t).draw(i.series):(this.ctx.bar=new Ce(this.ctx,t),x=this.ctx.bar.draw(i.series));break;case"candlestick":x=new Ee(this.ctx,t).draw(i.series,"candlestick");break;case"boxPlot":x=new Ee(this.ctx,t).draw(i.series,r.chart.type);break;case"rangeBar":x=this.ctx.rangeBar.draw(i.series);break;case"rangeArea":x=p.draw(i.seriesRangeStart,"rangeArea",void 0,i.seriesRangeEnd);break;case"heatmap":x=new Te(this.ctx,t).draw(i.series);break;case"treemap":x=new Ye(this.ctx,t).draw(i.series);break;case"pie":case"donut":case"polarArea":x=this.ctx.pie.draw(i.series);break;case"radialBar":x=m.draw(i.series);break;case"radar":x=v.draw(i.series);break;default:x=p.draw(i.series)}return x}},{key:"setSVGDimensions",value:function(){var e=this.w.globals,t=this.w.config;e.svgWidth=t.chart.width,e.svgHeight=t.chart.height;var n=y.getDimensions(this.el),r=t.chart.width.toString().split(/[0-9]+/g).pop();"%"===r?y.isNumber(n[0])&&(0===n[0].width&&(n=y.getDimensions(this.el.parentNode)),e.svgWidth=n[0]*parseInt(t.chart.width,10)/100):"px"!==r&&""!==r||(e.svgWidth=parseInt(t.chart.width,10));var i=t.chart.height.toString().split(/[0-9]+/g).pop();if("auto"!==e.svgHeight&&""!==e.svgHeight)if("%"===i){var a=y.getDimensions(this.el.parentNode);e.svgHeight=a[1]*parseInt(t.chart.height,10)/100}else e.svgHeight=parseInt(t.chart.height,10);else e.axisCharts?e.svgHeight=e.svgWidth/1.61:e.svgHeight=e.svgWidth/1.2;if(e.svgWidth<0&&(e.svgWidth=0),e.svgHeight<0&&(e.svgHeight=0),S.setAttrs(e.dom.Paper.node,{width:e.svgWidth,height:e.svgHeight}),"%"!==i){var o=t.chart.sparkline.enabled?0:e.axisCharts?t.chart.parentHeightOffset:0;e.dom.Paper.node.parentNode.parentNode.style.minHeight=e.svgHeight+o+"px"}e.dom.elWrap.style.width=e.svgWidth+"px",e.dom.elWrap.style.height=e.svgHeight+"px"}},{key:"shiftGraphPosition",value:function(){var e=this.w.globals,t=e.translateY,n={transform:"translate("+e.translateX+", "+t+")"};S.setAttrs(e.dom.elGraphical.node,n)}},{key:"resizeNonAxisCharts",value:function(){var e=this.w,t=e.globals,n=0,r=e.config.chart.sparkline.enabled?1:15;r+=e.config.grid.padding.bottom,"top"!==e.config.legend.position&&"bottom"!==e.config.legend.position||!e.config.legend.show||e.config.legend.floating||(n=new he(this.ctx).legendHelpers.getLegendBBox().clwh+10);var i=e.globals.dom.baseEl.querySelector(".apexcharts-radialbar, .apexcharts-pie"),a=2.05*e.globals.radialSize;if(i&&!e.config.chart.sparkline.enabled&&0!==e.config.plotOptions.radialBar.startAngle){var o=y.getBoundingClientRect(i);a=o.bottom;var s=o.bottom-o.top;a=Math.max(2.05*e.globals.radialSize,s)}var l=a+t.translateY+n+r;t.dom.elLegendForeign&&t.dom.elLegendForeign.setAttribute("height",l),e.config.chart.height&&String(e.config.chart.height).indexOf("%")>0||(t.dom.elWrap.style.height=l+"px",S.setAttrs(t.dom.Paper.node,{height:l}),t.dom.Paper.node.parentNode.parentNode.style.minHeight=l+"px")}},{key:"coreCalculations",value:function(){new Q(this.ctx).init()}},{key:"resetGlobals",value:function(){var e=this,t=function(){return e.w.config.series.map((function(e){return[]}))},n=new N,r=this.w.globals;n.initGlobalVars(r),r.seriesXvalues=t(),r.seriesYvalues=t()}},{key:"isMultipleY",value:function(){if(this.w.config.yaxis.constructor===Array&&this.w.config.yaxis.length>1)return this.w.globals.isMultipleYAxis=!0,!0}},{key:"xySettings",value:function(){var e=null,t=this.w;if(t.globals.axisCharts){if("back"===t.config.xaxis.crosshairs.position&&new ne(this.ctx).drawXCrosshairs(),"back"===t.config.yaxis[0].crosshairs.position&&new ne(this.ctx).drawYCrosshairs(),"datetime"===t.config.xaxis.type&&void 0===t.config.xaxis.labels.formatter){this.ctx.timeScale=new He(this.ctx);var n=[];isFinite(t.globals.minX)&&isFinite(t.globals.maxX)&&!t.globals.isBarHorizontal?n=this.ctx.timeScale.calculateTimeScaleTicks(t.globals.minX,t.globals.maxX):t.globals.isBarHorizontal&&(n=this.ctx.timeScale.calculateTimeScaleTicks(t.globals.minY,t.globals.maxY)),this.ctx.timeScale.recalcDimensionsBasedOnFormat(n)}e=new C(this.ctx).getCalculatedRatios()}return e}},{key:"updateSourceChart",value:function(e){this.ctx.w.globals.selection=void 0,this.ctx.updateHelpers._updateOptions({chart:{selection:{xaxis:{min:e.w.globals.minX,max:e.w.globals.maxX}}}},!1,!1)}},{key:"setupBrushHandler",value:function(){var e=this,t=this.w;if(t.config.chart.brush.enabled&&"function"!=typeof t.config.chart.events.selection){var n=Array.isArray(t.config.chart.brush.targets)||[t.config.chart.brush.target];n.forEach((function(t){var n=ApexCharts.getChartByID(t);n.w.globals.brushSource=e.ctx,"function"!=typeof n.w.config.chart.events.zoomed&&(n.w.config.chart.events.zoomed=function(){e.updateSourceChart(n)}),"function"!=typeof n.w.config.chart.events.scrolled&&(n.w.config.chart.events.scrolled=function(){e.updateSourceChart(n)})})),t.config.chart.events.selection=function(e,r){n.forEach((function(e){var n=ApexCharts.getChartByID(e),i=y.clone(t.config.yaxis);if(t.config.chart.brush.autoScaleYaxis&&1===n.w.globals.series.length){var o=new $(n);i=o.autoScaleY(n,i,r)}var s=n.w.config.yaxis.reduce((function(e,t,r){return[].concat(v(e),[a(a({},n.w.config.yaxis[r]),{},{min:i[0].min,max:i[0].max})])}),[]);n.ctx.updateHelpers._updateOptions({xaxis:{min:r.xaxis.min,max:r.xaxis.max},yaxis:s},!1,!1,!1,!1)}))}}}}]),e}(),Xe=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"_updateOptions",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return new Promise((function(s){var l=[t.ctx];i&&(l=t.ctx.getSyncedCharts()),t.ctx.w.globals.isExecCalled&&(l=[t.ctx],t.ctx.w.globals.isExecCalled=!1),l.forEach((function(i,c){var u=i.w;if(u.globals.shouldAnimate=r,n||(u.globals.resized=!0,u.globals.dataChanged=!0,r&&i.series.getPreviousPaths()),e&&"object"===o(e)&&(i.config=new F(e),e=C.extendArrayProps(i.config,e,u),i.w.globals.chartID!==t.ctx.w.globals.chartID&&delete e.series,u.config=y.extend(u.config,e),a&&(u.globals.lastXAxis=e.xaxis?y.clone(e.xaxis):[],u.globals.lastYAxis=e.yaxis?y.clone(e.yaxis):[],u.globals.initialConfig=y.extend({},u.config),u.globals.initialSeries=y.clone(u.config.series),e.series))){for(var d=0;d2&&void 0!==arguments[2]&&arguments[2];return new Promise((function(i){var a,o=n.w;return o.globals.shouldAnimate=t,o.globals.dataChanged=!0,t&&n.ctx.series.getPreviousPaths(),o.globals.axisCharts?(0===(a=e.map((function(e,t){return n._extendSeries(e,t)}))).length&&(a=[{data:[]}]),o.config.series=a):o.config.series=e.slice(),r&&(o.globals.initialConfig.series=y.clone(o.config.series),o.globals.initialSeries=y.clone(o.config.series)),n.ctx.update().then((function(){i(n.ctx)}))}))}},{key:"_extendSeries",value:function(e,t){var n=this.w,r=n.config.series[t];return a(a({},n.config.series[t]),{},{name:e.name?e.name:null==r?void 0:r.name,color:e.color?e.color:null==r?void 0:r.color,type:e.type?e.type:null==r?void 0:r.type,group:e.group?e.group:null==r?void 0:r.group,data:e.data?e.data:null==r?void 0:r.data,zIndex:void 0!==e.zIndex?e.zIndex:t})}},{key:"toggleDataPointSelection",value:function(e,t){var n=this.w,r=null,i=".apexcharts-series[data\\:realIndex='".concat(e,"']");return n.globals.axisCharts?r=n.globals.dom.Paper.select("".concat(i," path[j='").concat(t,"'], ").concat(i," circle[j='").concat(t,"'], ").concat(i," rect[j='").concat(t,"']")).members[0]:void 0===t&&(r=n.globals.dom.Paper.select("".concat(i," path[j='").concat(e,"']")).members[0],"pie"!==n.config.chart.type&&"polarArea"!==n.config.chart.type&&"donut"!==n.config.chart.type||this.ctx.pie.pieClicked(e)),r?(new S(this.ctx).pathMouseDown(r,null),r.node?r.node:null):(console.warn("toggleDataPointSelection: Element not found"),null)}},{key:"forceXAxisUpdate",value:function(e){var t=this.w;if(["min","max"].forEach((function(n){void 0!==e.xaxis[n]&&(t.config.xaxis[n]=e.xaxis[n],t.globals.lastXAxis[n]=e.xaxis[n])})),e.xaxis.categories&&e.xaxis.categories.length&&(t.config.xaxis.categories=e.xaxis.categories),t.config.xaxis.convertedCatToNumeric){var n=new D(e);e=n.convertCatToNumericXaxis(e,this.ctx)}return e}},{key:"forceYAxisUpdate",value:function(e){return e.chart&&e.chart.stacked&&"100%"===e.chart.stackType&&(Array.isArray(e.yaxis)?e.yaxis.forEach((function(t,n){e.yaxis[n].min=0,e.yaxis[n].max=100})):(e.yaxis.min=0,e.yaxis.max=100)),e}},{key:"revertDefaultAxisMinMax",value:function(e){var t=this,n=this.w,r=n.globals.lastXAxis,i=n.globals.lastYAxis;e&&e.xaxis&&(r=e.xaxis),e&&e.yaxis&&(i=e.yaxis),n.config.xaxis.min=r.min,n.config.xaxis.max=r.max;n.config.yaxis.map((function(e,r){n.globals.zoomed||void 0!==i[r]?function(e){void 0!==i[e]&&(n.config.yaxis[e].min=i[e].min,n.config.yaxis[e].max=i[e].max)}(r):void 0!==t.ctx.opts.yaxis[r]&&(e.min=t.ctx.opts.yaxis[r].min,e.max=t.ctx.opts.yaxis[r].max)}))}}]),e}();je="undefined"!=typeof window?window:void 0,Be=function(e,t){var n=(void 0!==this?this:e).SVG=function(e){if(n.supported)return e=new n.Doc(e),n.parser.draw||n.prepare(),e};if(n.ns="http://www.w3.org/2000/svg",n.xmlns="http://www.w3.org/2000/xmlns/",n.xlink="http://www.w3.org/1999/xlink",n.svgjs="http://svgjs.dev",n.supported=!0,!n.supported)return!1;n.did=1e3,n.eid=function(e){return"Svgjs"+d(e)+n.did++},n.create=function(e){var n=t.createElementNS(this.ns,e);return n.setAttribute("id",this.eid(e)),n},n.extend=function(){var e,t;t=(e=[].slice.call(arguments)).pop();for(var r=e.length-1;r>=0;r--)if(e[r])for(var i in t)e[r].prototype[i]=t[i];n.Set&&n.Set.inherit&&n.Set.inherit()},n.invent=function(e){var t="function"==typeof e.create?e.create:function(){this.constructor.call(this,n.create(e.create))};return e.inherit&&(t.prototype=new e.inherit),e.extend&&n.extend(t,e.extend),e.construct&&n.extend(e.parent||n.Container,e.construct),t},n.adopt=function(t){return t?t.instance?t.instance:((r="svg"==t.nodeName?t.parentNode instanceof e.SVGElement?new n.Nested:new n.Doc:"linearGradient"==t.nodeName?new n.Gradient("linear"):"radialGradient"==t.nodeName?new n.Gradient("radial"):n[d(t.nodeName)]?new(n[d(t.nodeName)]):new n.Element(t)).type=t.nodeName,r.node=t,t.instance=r,r instanceof n.Doc&&r.namespace().defs(),r.setData(JSON.parse(t.getAttribute("svgjs:data"))||{}),r):null;var r},n.prepare=function(){var e=t.getElementsByTagName("body")[0],r=(e?new n.Doc(e):n.adopt(t.documentElement).nested()).size(2,0);n.parser={body:e||t.documentElement,draw:r.style("opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden").node,poly:r.polyline().node,path:r.path().node,native:n.create("svg")}},n.parser={native:n.create("svg")},t.addEventListener("DOMContentLoaded",(function(){n.parser.draw||n.prepare()}),!1),n.regex={numberAndUnit:/^([+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?)([a-z%]*)$/i,hex:/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,rgb:/rgb\((\d+),(\d+),(\d+)\)/,reference:/#([a-z0-9\-_]+)/i,transforms:/\)\s*,?\s*/,whitespace:/\s/g,isHex:/^#[a-f0-9]{3,6}$/i,isRgb:/^rgb\(/,isCss:/[^:]+:[^;]+;?/,isBlank:/^(\s+)?$/,isNumber:/^[+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,isPercent:/^-?[\d\.]+%$/,isImage:/\.(jpg|jpeg|png|gif|svg)(\?[^=]+.*)?/i,delimiter:/[\s,]+/,hyphen:/([^e])\-/gi,pathLetters:/[MLHVCSQTAZ]/gi,isPathLetter:/[MLHVCSQTAZ]/i,numbersWithDots:/((\d?\.\d+(?:e[+-]?\d+)?)((?:\.\d+(?:e[+-]?\d+)?)+))+/gi,dots:/\./g},n.utils={map:function(e,t){for(var n=e.length,r=[],i=0;i1?1:e,new n.Color({r:~~(this.r+(this.destination.r-this.r)*e),g:~~(this.g+(this.destination.g-this.g)*e),b:~~(this.b+(this.destination.b-this.b)*e)})):this}}),n.Color.test=function(e){return e+="",n.regex.isHex.test(e)||n.regex.isRgb.test(e)},n.Color.isRgb=function(e){return e&&"number"==typeof e.r&&"number"==typeof e.g&&"number"==typeof e.b},n.Color.isColor=function(e){return n.Color.isRgb(e)||n.Color.test(e)},n.Array=function(e,t){0==(e=(e||[]).valueOf()).length&&t&&(e=t.valueOf()),this.value=this.parse(e)},n.extend(n.Array,{toString:function(){return this.value.join(" ")},valueOf:function(){return this.value},parse:function(e){return e=e.valueOf(),Array.isArray(e)?e:this.split(e)}}),n.PointArray=function(e,t){n.Array.call(this,e,t||[[0,0]])},n.PointArray.prototype=new n.Array,n.PointArray.prototype.constructor=n.PointArray;for(var r={M:function(e,t,n){return t.x=n.x=e[0],t.y=n.y=e[1],["M",t.x,t.y]},L:function(e,t){return t.x=e[0],t.y=e[1],["L",e[0],e[1]]},H:function(e,t){return t.x=e[0],["H",e[0]]},V:function(e,t){return t.y=e[0],["V",e[0]]},C:function(e,t){return t.x=e[4],t.y=e[5],["C",e[0],e[1],e[2],e[3],e[4],e[5]]},Q:function(e,t){return t.x=e[2],t.y=e[3],["Q",e[0],e[1],e[2],e[3]]},S:function(e,t){return t.x=e[2],t.y=e[3],["S",e[0],e[1],e[2],e[3]]},Z:function(e,t,n){return t.x=n.x,t.y=n.y,["Z"]}},i="mlhvqtcsaz".split(""),a=0,s=i.length;al);return a},bbox:function(){return n.parser.draw||n.prepare(),n.parser.path.setAttribute("d",this.toString()),n.parser.path.getBBox()}}),n.Number=n.invent({create:function(e,t){this.value=0,this.unit=t||"","number"==typeof e?this.value=isNaN(e)?0:isFinite(e)?e:e<0?-34e37:34e37:"string"==typeof e?(t=e.match(n.regex.numberAndUnit))&&(this.value=parseFloat(t[1]),"%"==t[5]?this.value/=100:"s"==t[5]&&(this.value*=1e3),this.unit=t[5]):e instanceof n.Number&&(this.value=e.valueOf(),this.unit=e.unit)},extend:{toString:function(){return("%"==this.unit?~~(1e8*this.value)/1e6:"s"==this.unit?this.value/1e3:this.value)+this.unit},toJSON:function(){return this.toString()},valueOf:function(){return this.value},plus:function(e){return e=new n.Number(e),new n.Number(this+e,this.unit||e.unit)},minus:function(e){return e=new n.Number(e),new n.Number(this-e,this.unit||e.unit)},times:function(e){return e=new n.Number(e),new n.Number(this*e,this.unit||e.unit)},divide:function(e){return e=new n.Number(e),new n.Number(this/e,this.unit||e.unit)},to:function(e){var t=new n.Number(this);return"string"==typeof e&&(t.unit=e),t},morph:function(e){return this.destination=new n.Number(e),e.relative&&(this.destination.value+=this.value),this},at:function(e){return this.destination?new n.Number(this.destination).minus(this).times(e).plus(this):this}}}),n.Element=n.invent({create:function(e){this._stroke=n.defaults.attrs.stroke,this._event=null,this.dom={},(this.node=e)&&(this.type=e.nodeName,this.node.instance=this,this._stroke=e.getAttribute("stroke")||this._stroke)},extend:{x:function(e){return this.attr("x",e)},y:function(e){return this.attr("y",e)},cx:function(e){return null==e?this.x()+this.width()/2:this.x(e-this.width()/2)},cy:function(e){return null==e?this.y()+this.height()/2:this.y(e-this.height()/2)},move:function(e,t){return this.x(e).y(t)},center:function(e,t){return this.cx(e).cy(t)},width:function(e){return this.attr("width",e)},height:function(e){return this.attr("height",e)},size:function(e,t){var r=f(this,e,t);return this.width(new n.Number(r.width)).height(new n.Number(r.height))},clone:function(e){this.writeDataToDom();var t=m(this.node.cloneNode(!0));return e?e.add(t):this.after(t),t},remove:function(){return this.parent()&&this.parent().removeElement(this),this},replace:function(e){return this.after(e).remove(),e},addTo:function(e){return e.put(this)},putIn:function(e){return e.add(this)},id:function(e){return this.attr("id",e)},show:function(){return this.style("display","")},hide:function(){return this.style("display","none")},visible:function(){return"none"!=this.style("display")},toString:function(){return this.attr("id")},classes:function(){var e=this.attr("class");return null==e?[]:e.trim().split(n.regex.delimiter)},hasClass:function(e){return-1!=this.classes().indexOf(e)},addClass:function(e){if(!this.hasClass(e)){var t=this.classes();t.push(e),this.attr("class",t.join(" "))}return this},removeClass:function(e){return this.hasClass(e)&&this.attr("class",this.classes().filter((function(t){return t!=e})).join(" ")),this},toggleClass:function(e){return this.hasClass(e)?this.removeClass(e):this.addClass(e)},reference:function(e){return n.get(this.attr(e))},parent:function(t){var r=this;if(!r.node.parentNode)return null;if(r=n.adopt(r.node.parentNode),!t)return r;for(;r&&r.node instanceof e.SVGElement;){if("string"==typeof t?r.matches(t):r instanceof t)return r;if(!r.node.parentNode||"#document"==r.node.parentNode.nodeName)return null;r=n.adopt(r.node.parentNode)}},doc:function(){return this instanceof n.Doc?this:this.parent(n.Doc)},parents:function(e){var t=[],n=this;do{if(!(n=n.parent(e))||!n.node)break;t.push(n)}while(n.parent);return t},matches:function(e){return function(e,t){return(e.matches||e.matchesSelector||e.msMatchesSelector||e.mozMatchesSelector||e.webkitMatchesSelector||e.oMatchesSelector).call(e,t)}(this.node,e)},native:function(){return this.node},svg:function(e){var r=t.createElement("svg");if(!(e&&this instanceof n.Parent))return r.appendChild(e=t.createElement("svg")),this.writeDataToDom(),e.appendChild(this.node.cloneNode(!0)),r.innerHTML.replace(/^/,"").replace(/<\/svg>$/,"");r.innerHTML=""+e.replace(/\n/,"").replace(/<([\w:-]+)([^<]+?)\/>/g,"<$1$2>")+"";for(var i=0,a=r.firstChild.childNodes.length;i":function(e){return-Math.cos(e*Math.PI)/2+.5},">":function(e){return Math.sin(e*Math.PI/2)},"<":function(e){return 1-Math.cos(e*Math.PI/2)}},n.morph=function(e){return function(t,r){return new n.MorphObj(t,r).at(e)}},n.Situation=n.invent({create:function(e){this.init=!1,this.reversed=!1,this.reversing=!1,this.duration=new n.Number(e.duration).valueOf(),this.delay=new n.Number(e.delay).valueOf(),this.start=+new Date+this.delay,this.finish=this.start+this.duration,this.ease=e.ease,this.loop=0,this.loops=!1,this.animations={},this.attrs={},this.styles={},this.transforms=[],this.once={}}}),n.FX=n.invent({create:function(e){this._target=e,this.situations=[],this.active=!1,this.situation=null,this.paused=!1,this.lastPos=0,this.pos=0,this.absPos=0,this._speed=1},extend:{animate:function(e,t,r){"object"===o(e)&&(t=e.ease,r=e.delay,e=e.duration);var i=new n.Situation({duration:e||1e3,delay:r||0,ease:n.easing[t||"-"]||t});return this.queue(i),this},target:function(e){return e&&e instanceof n.Element?(this._target=e,this):this._target},timeToAbsPos:function(e){return(e-this.situation.start)/(this.situation.duration/this._speed)},absPosToTime:function(e){return this.situation.duration/this._speed*e+this.situation.start},startAnimFrame:function(){this.stopAnimFrame(),this.animationFrame=e.requestAnimationFrame(function(){this.step()}.bind(this))},stopAnimFrame:function(){e.cancelAnimationFrame(this.animationFrame)},start:function(){return!this.active&&this.situation&&(this.active=!0,this.startCurrent()),this},startCurrent:function(){return this.situation.start=+new Date+this.situation.delay/this._speed,this.situation.finish=this.situation.start+this.situation.duration/this._speed,this.initAnimations().step()},queue:function(e){return("function"==typeof e||e instanceof n.Situation)&&this.situations.push(e),this.situation||(this.situation=this.situations.shift()),this},dequeue:function(){return this.stop(),this.situation=this.situations.shift(),this.situation&&(this.situation instanceof n.Situation?this.start():this.situation.call(this)),this},initAnimations:function(){var e,t=this.situation;if(t.init)return this;for(var r in t.animations){e=this.target()[r](),Array.isArray(e)||(e=[e]),Array.isArray(t.animations[r])||(t.animations[r]=[t.animations[r]]);for(var i=e.length;i--;)t.animations[r][i]instanceof n.Number&&(e[i]=new n.Number(e[i])),t.animations[r][i]=e[i].morph(t.animations[r][i])}for(var r in t.attrs)t.attrs[r]=new n.MorphObj(this.target().attr(r),t.attrs[r]);for(var r in t.styles)t.styles[r]=new n.MorphObj(this.target().style(r),t.styles[r]);return t.initialTransformation=this.target().matrixify(),t.init=!0,this},clearQueue:function(){return this.situations=[],this},clearCurrent:function(){return this.situation=null,this},stop:function(e,t){var n=this.active;return this.active=!1,t&&this.clearQueue(),e&&this.situation&&(!n&&this.startCurrent(),this.atEnd()),this.stopAnimFrame(),this.clearCurrent()},after:function(e){var t=this.last();return this.target().on("finished.fx",(function n(r){r.detail.situation==t&&(e.call(this,t),this.off("finished.fx",n))})),this._callStart()},during:function(e){var t=this.last(),r=function(r){r.detail.situation==t&&e.call(this,r.detail.pos,n.morph(r.detail.pos),r.detail.eased,t)};return this.target().off("during.fx",r).on("during.fx",r),this.after((function(){this.off("during.fx",r)})),this._callStart()},afterAll:function(e){var t=function t(n){e.call(this),this.off("allfinished.fx",t)};return this.target().off("allfinished.fx",t).on("allfinished.fx",t),this._callStart()},last:function(){return this.situations.length?this.situations[this.situations.length-1]:this.situation},add:function(e,t,n){return this.last()[n||"animations"][e]=t,this._callStart()},step:function(e){var t,n,r;e||(this.absPos=this.timeToAbsPos(+new Date)),!1!==this.situation.loops?(t=Math.max(this.absPos,0),n=Math.floor(t),!0===this.situation.loops||nthis.lastPos&&a<=i&&(this.situation.once[a].call(this.target(),this.pos,i),delete this.situation.once[a]);return this.active&&this.target().fire("during",{pos:this.pos,eased:i,fx:this,situation:this.situation}),this.situation?(this.eachAt(),1==this.pos&&!this.situation.reversed||this.situation.reversed&&0==this.pos?(this.stopAnimFrame(),this.target().fire("finished",{fx:this,situation:this.situation}),this.situations.length||(this.target().fire("allfinished"),this.situations.length||(this.target().off(".fx"),this.active=!1)),this.active?this.dequeue():this.clearCurrent()):!this.paused&&this.active&&this.startAnimFrame(),this.lastPos=i,this):this},eachAt:function(){var e,t=this,r=this.target(),i=this.situation;for(var a in i.animations)e=[].concat(i.animations[a]).map((function(e){return"string"!=typeof e&&e.at?e.at(i.ease(t.pos),t.pos):e})),r[a].apply(r,e);for(var a in i.attrs)e=[a].concat(i.attrs[a]).map((function(e){return"string"!=typeof e&&e.at?e.at(i.ease(t.pos),t.pos):e})),r.attr.apply(r,e);for(var a in i.styles)e=[a].concat(i.styles[a]).map((function(e){return"string"!=typeof e&&e.at?e.at(i.ease(t.pos),t.pos):e})),r.style.apply(r,e);if(i.transforms.length){e=i.initialTransformation,a=0;for(var o=i.transforms.length;a=0;--r)this[x[r]]=null!=e[x[r]]?e[x[r]]:t[x[r]]},extend:{extract:function(){var e=p(this,0,1);p(this,1,0);var t=180/Math.PI*Math.atan2(e.y,e.x)-90;return{x:this.e,y:this.f,transformedX:(this.e*Math.cos(t*Math.PI/180)+this.f*Math.sin(t*Math.PI/180))/Math.sqrt(this.a*this.a+this.b*this.b),transformedY:(this.f*Math.cos(t*Math.PI/180)+this.e*Math.sin(-t*Math.PI/180))/Math.sqrt(this.c*this.c+this.d*this.d),rotation:t,a:this.a,b:this.b,c:this.c,d:this.d,e:this.e,f:this.f,matrix:new n.Matrix(this)}},clone:function(){return new n.Matrix(this)},morph:function(e){return this.destination=new n.Matrix(e),this},multiply:function(e){return new n.Matrix(this.native().multiply(function(e){return e instanceof n.Matrix||(e=new n.Matrix(e)),e}(e).native()))},inverse:function(){return new n.Matrix(this.native().inverse())},translate:function(e,t){return new n.Matrix(this.native().translate(e||0,t||0))},native:function(){for(var e=n.parser.native.createSVGMatrix(),t=x.length-1;t>=0;t--)e[x[t]]=this[x[t]];return e},toString:function(){return"matrix("+v(this.a)+","+v(this.b)+","+v(this.c)+","+v(this.d)+","+v(this.e)+","+v(this.f)+")"}},parent:n.Element,construct:{ctm:function(){return new n.Matrix(this.node.getCTM())},screenCTM:function(){if(this instanceof n.Nested){var e=this.rect(1,1),t=e.node.getScreenCTM();return e.remove(),new n.Matrix(t)}return new n.Matrix(this.node.getScreenCTM())}}}),n.Point=n.invent({create:function(e,t){var n;n=Array.isArray(e)?{x:e[0],y:e[1]}:"object"===o(e)?{x:e.x,y:e.y}:null!=e?{x:e,y:null!=t?t:e}:{x:0,y:0},this.x=n.x,this.y=n.y},extend:{clone:function(){return new n.Point(this)},morph:function(e,t){return this.destination=new n.Point(e,t),this}}}),n.extend(n.Element,{point:function(e,t){return new n.Point(e,t).transform(this.screenCTM().inverse())}}),n.extend(n.Element,{attr:function(e,t,r){if(null==e){for(e={},r=(t=this.node.attributes).length-1;r>=0;r--)e[t[r].nodeName]=n.regex.isNumber.test(t[r].nodeValue)?parseFloat(t[r].nodeValue):t[r].nodeValue;return e}if("object"===o(e))for(var i in e)this.attr(i,e[i]);else if(null===t)this.node.removeAttribute(e);else{if(null==t)return null==(t=this.node.getAttribute(e))?n.defaults.attrs[e]:n.regex.isNumber.test(t)?parseFloat(t):t;"stroke-width"==e?this.attr("stroke",parseFloat(t)>0?this._stroke:null):"stroke"==e&&(this._stroke=t),"fill"!=e&&"stroke"!=e||(n.regex.isImage.test(t)&&(t=this.doc().defs().image(t,0,0)),t instanceof n.Image&&(t=this.doc().defs().pattern(0,0,(function(){this.add(t)})))),"number"==typeof t?t=new n.Number(t):n.Color.isColor(t)?t=new n.Color(t):Array.isArray(t)&&(t=new n.Array(t)),"leading"==e?this.leading&&this.leading(t):"string"==typeof r?this.node.setAttributeNS(r,e,t.toString()):this.node.setAttribute(e,t.toString()),!this.rebuild||"font-size"!=e&&"x"!=e||this.rebuild(e,t)}return this}}),n.extend(n.Element,{transform:function(e,t){var r;return"object"!==o(e)?(r=new n.Matrix(this).extract(),"string"==typeof e?r[e]:r):(r=new n.Matrix(this),t=!!t||!!e.relative,null!=e.a&&(r=t?r.multiply(new n.Matrix(e)):new n.Matrix(e)),this.attr("transform",r))}}),n.extend(n.Element,{untransform:function(){return this.attr("transform",null)},matrixify:function(){return(this.attr("transform")||"").split(n.regex.transforms).slice(0,-1).map((function(e){var t=e.trim().split("(");return[t[0],t[1].split(n.regex.delimiter).map((function(e){return parseFloat(e)}))]})).reduce((function(e,t){return"matrix"==t[0]?e.multiply(g(t[1])):e[t[0]].apply(e,t[1])}),new n.Matrix)},toParent:function(e){if(this==e)return this;var t=this.screenCTM(),n=e.screenCTM().inverse();return this.addTo(e).untransform().transform(n.multiply(t)),this},toDoc:function(){return this.toParent(this.doc())}}),n.Transformation=n.invent({create:function(e,t){if(arguments.length>1&&"boolean"!=typeof t)return this.constructor.call(this,[].slice.call(arguments));if(Array.isArray(e))for(var n=0,r=this.arguments.length;n=0},index:function(e){return[].slice.call(this.node.childNodes).indexOf(e.node)},get:function(e){return n.adopt(this.node.childNodes[e])},first:function(){return this.get(0)},last:function(){return this.get(this.node.childNodes.length-1)},each:function(e,t){for(var r=this.children(),i=0,a=r.length;i=0;r--)t.childNodes[r]instanceof e.SVGElement&&m(t.childNodes[r]);return n.adopt(t).id(n.eid(t.nodeName))}function v(e){return Math.abs(e)>1e-37?e:0}["fill","stroke"].forEach((function(e){var t={};t[e]=function(t){if(void 0===t)return this;if("string"==typeof t||n.Color.isRgb(t)||t&&"function"==typeof t.fill)this.attr(e,t);else for(var r=l[e].length-1;r>=0;r--)null!=t[l[e][r]]&&this.attr(l.prefix(e,l[e][r]),t[l[e][r]]);return this},n.extend(n.Element,n.FX,t)})),n.extend(n.Element,n.FX,{translate:function(e,t){return this.transform({x:e,y:t})},matrix:function(e){return this.attr("transform",new n.Matrix(6==arguments.length?[].slice.call(arguments):e))},opacity:function(e){return this.attr("opacity",e)},dx:function(e){return this.x(new n.Number(e).plus(this instanceof n.FX?0:this.x()),!0)},dy:function(e){return this.y(new n.Number(e).plus(this instanceof n.FX?0:this.y()),!0)}}),n.extend(n.Path,{length:function(){return this.node.getTotalLength()},pointAt:function(e){return this.node.getPointAtLength(e)}}),n.Set=n.invent({create:function(e){Array.isArray(e)?this.members=e:this.clear()},extend:{add:function(){for(var e=[].slice.call(arguments),t=0,n=e.length;t-1&&this.members.splice(t,1),this},each:function(e){for(var t=0,n=this.members.length;t=0},index:function(e){return this.members.indexOf(e)},get:function(e){return this.members[e]},first:function(){return this.get(0)},last:function(){return this.get(this.members.length-1)},valueOf:function(){return this.members}},construct:{set:function(e){return new n.Set(e)}}}),n.FX.Set=n.invent({create:function(e){this.set=e}}),n.Set.inherit=function(){var e=[];for(var t in n.Shape.prototype)"function"==typeof n.Shape.prototype[t]&&"function"!=typeof n.Set.prototype[t]&&e.push(t);for(var t in e.forEach((function(e){n.Set.prototype[e]=function(){for(var t=0,r=this.members.length;t=0;e--)delete this.memory()[arguments[e]];return this},memory:function(){return this._memory||(this._memory={})}}),n.get=function(e){var r=t.getElementById(function(e){var t=(e||"").toString().match(n.regex.reference);if(t)return t[1]}(e)||e);return n.adopt(r)},n.select=function(e,r){return new n.Set(n.utils.map((r||t).querySelectorAll(e),(function(e){return n.adopt(e)})))},n.extend(n.Parent,{select:function(e){return n.select(e,this.node)}});var x="abcdef".split("");if("function"!=typeof e.CustomEvent){var b=function(e,n){n=n||{bubbles:!1,cancelable:!1,detail:void 0};var r=t.createEvent("CustomEvent");return r.initCustomEvent(e,n.bubbles,n.cancelable,n.detail),r};b.prototype=e.Event.prototype,n.CustomEvent=b}else n.CustomEvent=e.CustomEvent;return n},void 0!==(r=function(){return Be(je,je.document)}.call(t,n,t,e))&&(e.exports=r),function(){SVG.Filter=SVG.invent({create:"filter",inherit:SVG.Parent,extend:{source:"SourceGraphic",sourceAlpha:"SourceAlpha",background:"BackgroundImage",backgroundAlpha:"BackgroundAlpha",fill:"FillPaint",stroke:"StrokePaint",autoSetIn:!0,put:function(e,t){return this.add(e,t),!e.attr("in")&&this.autoSetIn&&e.attr("in",this.source),e.attr("result")||e.attr("result",e),e},blend:function(e,t,n){return this.put(new SVG.BlendEffect(e,t,n))},colorMatrix:function(e,t){return this.put(new SVG.ColorMatrixEffect(e,t))},convolveMatrix:function(e){return this.put(new SVG.ConvolveMatrixEffect(e))},componentTransfer:function(e){return this.put(new SVG.ComponentTransferEffect(e))},composite:function(e,t,n){return this.put(new SVG.CompositeEffect(e,t,n))},flood:function(e,t){return this.put(new SVG.FloodEffect(e,t))},offset:function(e,t){return this.put(new SVG.OffsetEffect(e,t))},image:function(e){return this.put(new SVG.ImageEffect(e))},merge:function(){var e=[void 0];for(var t in arguments)e.push(arguments[t]);return this.put(new(SVG.MergeEffect.bind.apply(SVG.MergeEffect,e)))},gaussianBlur:function(e,t){return this.put(new SVG.GaussianBlurEffect(e,t))},morphology:function(e,t){return this.put(new SVG.MorphologyEffect(e,t))},diffuseLighting:function(e,t,n){return this.put(new SVG.DiffuseLightingEffect(e,t,n))},displacementMap:function(e,t,n,r,i){return this.put(new SVG.DisplacementMapEffect(e,t,n,r,i))},specularLighting:function(e,t,n,r){return this.put(new SVG.SpecularLightingEffect(e,t,n,r))},tile:function(){return this.put(new SVG.TileEffect)},turbulence:function(e,t,n,r,i){return this.put(new SVG.TurbulenceEffect(e,t,n,r,i))},toString:function(){return"url(#"+this.attr("id")+")"}}}),SVG.extend(SVG.Defs,{filter:function(e){var t=this.put(new SVG.Filter);return"function"==typeof e&&e.call(t,t),t}}),SVG.extend(SVG.Container,{filter:function(e){return this.defs().filter(e)}}),SVG.extend(SVG.Element,SVG.G,SVG.Nested,{filter:function(e){return this.filterer=e instanceof SVG.Element?e:this.doc().filter(e),this.doc()&&this.filterer.doc()!==this.doc()&&this.doc().defs().add(this.filterer),this.attr("filter",this.filterer),this.filterer},unfilter:function(e){return this.filterer&&!0===e&&this.filterer.remove(),delete this.filterer,this.attr("filter",null)}}),SVG.Effect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(e){return null==e?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",e)},result:function(e){return null==e?this.attr("result"):this.attr("result",e)},toString:function(){return this.result()}}}),SVG.ParentEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Parent,extend:{in:function(e){return null==e?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",e)},result:function(e){return null==e?this.attr("result"):this.attr("result",e)},toString:function(){return this.result()}}});var e={blend:function(e,t){return this.parent()&&this.parent().blend(this,e,t)},colorMatrix:function(e,t){return this.parent()&&this.parent().colorMatrix(e,t).in(this)},convolveMatrix:function(e){return this.parent()&&this.parent().convolveMatrix(e).in(this)},componentTransfer:function(e){return this.parent()&&this.parent().componentTransfer(e).in(this)},composite:function(e,t){return this.parent()&&this.parent().composite(this,e,t)},flood:function(e,t){return this.parent()&&this.parent().flood(e,t)},offset:function(e,t){return this.parent()&&this.parent().offset(e,t).in(this)},image:function(e){return this.parent()&&this.parent().image(e)},merge:function(){return this.parent()&&this.parent().merge.apply(this.parent(),[this].concat(arguments))},gaussianBlur:function(e,t){return this.parent()&&this.parent().gaussianBlur(e,t).in(this)},morphology:function(e,t){return this.parent()&&this.parent().morphology(e,t).in(this)},diffuseLighting:function(e,t,n){return this.parent()&&this.parent().diffuseLighting(e,t,n).in(this)},displacementMap:function(e,t,n,r){return this.parent()&&this.parent().displacementMap(this,e,t,n,r)},specularLighting:function(e,t,n,r){return this.parent()&&this.parent().specularLighting(e,t,n,r).in(this)},tile:function(){return this.parent()&&this.parent().tile().in(this)},turbulence:function(e,t,n,r,i){return this.parent()&&this.parent().turbulence(e,t,n,r,i).in(this)}};SVG.extend(SVG.Effect,e),SVG.extend(SVG.ParentEffect,e),SVG.ChildEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(e){this.attr("in",e)}}});var t={blend:function(e,t,n){this.attr({in:e,in2:t,mode:n||"normal"})},colorMatrix:function(e,t){"matrix"==e&&(t=i(t)),this.attr({type:e,values:void 0===t?null:t})},convolveMatrix:function(e){e=i(e),this.attr({order:Math.sqrt(e.split(" ").length),kernelMatrix:e})},composite:function(e,t,n){this.attr({in:e,in2:t,operator:n})},flood:function(e,t){this.attr("flood-color",e),null!=t&&this.attr("flood-opacity",t)},offset:function(e,t){this.attr({dx:e,dy:t})},image:function(e){this.attr("href",e,SVG.xlink)},displacementMap:function(e,t,n,r,i){this.attr({in:e,in2:t,scale:n,xChannelSelector:r,yChannelSelector:i})},gaussianBlur:function(e,t){null!=e||null!=t?this.attr("stdDeviation",function(e){if(!Array.isArray(e))return e;for(var t=0,n=e.length,r=[];t1&&(T*=r=Math.sqrt(r),M*=r),i=(new SVG.Matrix).rotate(_).scale(1/T,1/M).rotate(-_),z=z.transform(i),s=(a=[(D=D.transform(i)).x-z.x,D.y-z.y])[0]*a[0]+a[1]*a[1],o=Math.sqrt(s),a[0]/=o,a[1]/=o,l=s<4?Math.sqrt(1-s/4):0,L===O&&(l*=-1),c=new SVG.Point((D.x+z.x)/2+l*-a[1],(D.y+z.y)/2+l*a[0]),u=new SVG.Point(z.x-c.x,z.y-c.y),d=new SVG.Point(D.x-c.x,D.y-c.y),h=Math.acos(u.x/Math.sqrt(u.x*u.x+u.y*u.y)),u.y<0&&(h*=-1),f=Math.acos(d.x/Math.sqrt(d.x*d.x+d.y*d.y)),d.y<0&&(f*=-1),O&&h>f&&(f+=2*Math.PI),!O&&ha.maxX-t.width&&(o=(r=a.maxX-t.width)-this.startPoints.box.x),null!=a.minY&&ia.maxY-t.height&&(s=(i=a.maxY-t.height)-this.startPoints.box.y),null!=a.snapToGrid&&(r-=r%a.snapToGrid,i-=i%a.snapToGrid,o-=o%a.snapToGrid,s-=s%a.snapToGrid),this.el instanceof SVG.G?this.el.matrix(this.startPoints.transform).transform({x:o,y:s},!0):this.el.move(r,i));return n},e.prototype.end=function(e){var t=this.drag(e);this.el.fire("dragend",{event:e,p:t,m:this.m,handler:this}),SVG.off(window,"mousemove.drag"),SVG.off(window,"touchmove.drag"),SVG.off(window,"mouseup.drag"),SVG.off(window,"touchend.drag")},SVG.extend(SVG.Element,{draggable:function(t,n){"function"!=typeof t&&"object"!=typeof t||(n=t,t=!0);var r=this.remember("_draggable")||new e(this);return(t=void 0===t||t)?r.init(n||{},t):(this.off("mousedown.drag"),this.off("touchstart.drag")),this}})}.call(void 0),function(){function e(e){this.el=e,e.remember("_selectHandler",this),this.pointSelection={isSelected:!1},this.rectSelection={isSelected:!1},this.pointsList={lt:[0,0],rt:["width",0],rb:["width","height"],lb:[0,"height"],t:["width",0],r:["width","height"],b:["width","height"],l:[0,"height"]},this.pointCoord=function(e,t,n){var r="string"!=typeof e?e:t[e];return n?r/2:r},this.pointCoords=function(e,t){var n=this.pointsList[e];return{x:this.pointCoord(n[0],t,"t"===e||"b"===e),y:this.pointCoord(n[1],t,"r"===e||"l"===e)}}}e.prototype.init=function(e,t){var n=this.el.bbox();this.options={};var r=this.el.selectize.defaults.points;for(var i in this.el.selectize.defaults)this.options[i]=this.el.selectize.defaults[i],void 0!==t[i]&&(this.options[i]=t[i]);var a=["points","pointsExclude"];for(var i in a){var o=this.options[a[i]];"string"==typeof o?o=o.length>0?o.split(/\s*,\s*/i):[]:"boolean"==typeof o&&"points"===a[i]&&(o=o?r:[]),this.options[a[i]]=o}this.options.points=[r,this.options.points].reduce((function(e,t){return e.filter((function(e){return t.indexOf(e)>-1}))})),this.options.points=[this.options.points,this.options.pointsExclude].reduce((function(e,t){return e.filter((function(e){return t.indexOf(e)<0}))})),this.parent=this.el.parent(),this.nested=this.nested||this.parent.group(),this.nested.matrix(new SVG.Matrix(this.el).translate(n.x,n.y)),this.options.deepSelect&&-1!==["line","polyline","polygon"].indexOf(this.el.type)?this.selectPoints(e):this.selectRect(e),this.observe(),this.cleanup()},e.prototype.selectPoints=function(e){return this.pointSelection.isSelected=e,this.pointSelection.set||(this.pointSelection.set=this.parent.set(),this.drawPoints()),this},e.prototype.getPointArray=function(){var e=this.el.bbox();return this.el.array().valueOf().map((function(t){return[t[0]-e.x,t[1]-e.y]}))},e.prototype.drawPoints=function(){for(var e=this,t=this.getPointArray(),n=0,r=t.length;n0&&this.parameters.box.height-n[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+n[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-n[0]);n=this.checkAspectRatio(n),this.el.move(this.parameters.box.x+n[0],this.parameters.box.y+n[1]).size(this.parameters.box.width-n[0],this.parameters.box.height-n[1])}};break;case"rt":this.calc=function(e,t){var n=this.snapToGrid(e,t,2);if(this.parameters.box.width+n[0]>0&&this.parameters.box.height-n[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-n[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+n[0]);n=this.checkAspectRatio(n,!0),this.el.move(this.parameters.box.x,this.parameters.box.y+n[1]).size(this.parameters.box.width+n[0],this.parameters.box.height-n[1])}};break;case"rb":this.calc=function(e,t){var n=this.snapToGrid(e,t,0);if(this.parameters.box.width+n[0]>0&&this.parameters.box.height+n[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-n[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+n[0]);n=this.checkAspectRatio(n),this.el.move(this.parameters.box.x,this.parameters.box.y).size(this.parameters.box.width+n[0],this.parameters.box.height+n[1])}};break;case"lb":this.calc=function(e,t){var n=this.snapToGrid(e,t,1);if(this.parameters.box.width-n[0]>0&&this.parameters.box.height+n[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+n[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-n[0]);n=this.checkAspectRatio(n,!0),this.el.move(this.parameters.box.x+n[0],this.parameters.box.y).size(this.parameters.box.width-n[0],this.parameters.box.height+n[1])}};break;case"t":this.calc=function(e,t){var n=this.snapToGrid(e,t,2);if(this.parameters.box.height-n[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y+n[1]).height(this.parameters.box.height-n[1])}};break;case"r":this.calc=function(e,t){var n=this.snapToGrid(e,t,0);if(this.parameters.box.width+n[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).width(this.parameters.box.width+n[0])}};break;case"b":this.calc=function(e,t){var n=this.snapToGrid(e,t,0);if(this.parameters.box.height+n[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).height(this.parameters.box.height+n[1])}};break;case"l":this.calc=function(e,t){var n=this.snapToGrid(e,t,1);if(this.parameters.box.width-n[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x+n[0],this.parameters.box.y).width(this.parameters.box.width-n[0])}};break;case"rot":this.calc=function(e,t){var n=e+this.parameters.p.x,r=t+this.parameters.p.y,i=Math.atan2(this.parameters.p.y-this.parameters.box.y-this.parameters.box.height/2,this.parameters.p.x-this.parameters.box.x-this.parameters.box.width/2),a=Math.atan2(r-this.parameters.box.y-this.parameters.box.height/2,n-this.parameters.box.x-this.parameters.box.width/2),o=this.parameters.rotation+180*(a-i)/Math.PI+this.options.snapToAngle/2;this.el.center(this.parameters.box.cx,this.parameters.box.cy).rotate(o-o%this.options.snapToAngle,this.parameters.box.cx,this.parameters.box.cy)};break;case"point":this.calc=function(e,t){var n=this.snapToGrid(e,t,this.parameters.pointCoords[0],this.parameters.pointCoords[1]),r=this.el.array().valueOf();r[this.parameters.i][0]=this.parameters.pointCoords[0]+n[0],r[this.parameters.i][1]=this.parameters.pointCoords[1]+n[1],this.el.plot(r)}}this.el.fire("resizestart",{dx:this.parameters.x,dy:this.parameters.y,event:e}),SVG.on(window,"touchmove.resize",(function(e){t.update(e||window.event)})),SVG.on(window,"touchend.resize",(function(){t.done()})),SVG.on(window,"mousemove.resize",(function(e){t.update(e||window.event)})),SVG.on(window,"mouseup.resize",(function(){t.done()}))},e.prototype.update=function(e){if(e){var t=this._extractPosition(e),n=this.transformPoint(t.x,t.y),r=n.x-this.parameters.p.x,i=n.y-this.parameters.p.y;this.lastUpdateCall=[r,i],this.calc(r,i),this.el.fire("resizing",{dx:r,dy:i,event:e})}else this.lastUpdateCall&&this.calc(this.lastUpdateCall[0],this.lastUpdateCall[1])},e.prototype.done=function(){this.lastUpdateCall=null,SVG.off(window,"mousemove.resize"),SVG.off(window,"mouseup.resize"),SVG.off(window,"touchmove.resize"),SVG.off(window,"touchend.resize"),this.el.fire("resizedone")},e.prototype.snapToGrid=function(e,t,n,r){var i;return void 0!==r?i=[(n+e)%this.options.snapToGrid,(r+t)%this.options.snapToGrid]:(n=null==n?3:n,i=[(this.parameters.box.x+e+(1&n?0:this.parameters.box.width))%this.options.snapToGrid,(this.parameters.box.y+t+(2&n?0:this.parameters.box.height))%this.options.snapToGrid]),e<0&&(i[0]-=this.options.snapToGrid),t<0&&(i[1]-=this.options.snapToGrid),e-=Math.abs(i[0])o.maxX&&(e=o.maxX-i),void 0!==o.minY&&a+to.maxY&&(t=o.maxY-a),[e,t]},e.prototype.checkAspectRatio=function(e,t){if(!this.options.saveAspectRatio)return e;var n=e.slice(),r=this.parameters.box.width/this.parameters.box.height,i=this.parameters.box.width+e[0],a=this.parameters.box.height-e[1],o=i/a;return or&&(n[0]=this.parameters.box.width-a*r,t&&(n[0]=-n[0])),n},SVG.extend(SVG.Element,{resize:function(t){return(this.remember("_resizeHandler")||new e(this)).init(t||{}),this}}),SVG.Element.prototype.resize.defaults={snapToAngle:.1,snapToGrid:1,constraint:{},saveAspectRatio:!1}}).call(this)}(),void 0===window.Apex&&(window.Apex={});var Ve=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"initModules",value:function(){this.ctx.publicMethods=["updateOptions","updateSeries","appendData","appendSeries","isSeriesHidden","toggleSeries","showSeries","hideSeries","setLocale","resetSeries","zoomX","toggleDataPointSelection","dataURI","exportToCSV","addXaxisAnnotation","addYaxisAnnotation","addPointAnnotation","clearAnnotations","removeAnnotation","paper","destroy"],this.ctx.eventList=["click","mousedown","mousemove","mouseleave","touchstart","touchmove","touchleave","mouseup","touchend"],this.ctx.animations=new w(this.ctx),this.ctx.axes=new te(this.ctx),this.ctx.core=new We(this.ctx.el,this.ctx),this.ctx.config=new F({}),this.ctx.data=new V(this.ctx),this.ctx.grid=new q(this.ctx),this.ctx.graphics=new S(this.ctx),this.ctx.coreUtils=new C(this.ctx),this.ctx.crosshairs=new ne(this.ctx),this.ctx.events=new J(this.ctx),this.ctx.exports=new U(this.ctx),this.ctx.localization=new ee(this.ctx),this.ctx.options=new _,this.ctx.responsive=new re(this.ctx),this.ctx.series=new X(this.ctx),this.ctx.theme=new ie(this.ctx),this.ctx.formatters=new I(this.ctx),this.ctx.titleSubtitle=new ae(this.ctx),this.ctx.legend=new he(this.ctx),this.ctx.toolbar=new fe(this.ctx),this.ctx.tooltip=new we(this.ctx),this.ctx.dimensions=new ue(this.ctx),this.ctx.updateHelpers=new Xe(this.ctx),this.ctx.zoomPanSelection=new pe(this.ctx),this.ctx.w.globals.tooltip=new we(this.ctx)}}]),e}(),Ge=function(){function e(t){s(this,e),this.ctx=t,this.w=t.w}return c(e,[{key:"clear",value:function(e){var t=e.isUpdating;this.ctx.zoomPanSelection&&this.ctx.zoomPanSelection.destroy(),this.ctx.toolbar&&this.ctx.toolbar.destroy(),this.ctx.animations=null,this.ctx.axes=null,this.ctx.annotations=null,this.ctx.core=null,this.ctx.data=null,this.ctx.grid=null,this.ctx.series=null,this.ctx.responsive=null,this.ctx.theme=null,this.ctx.formatters=null,this.ctx.titleSubtitle=null,this.ctx.legend=null,this.ctx.dimensions=null,this.ctx.options=null,this.ctx.crosshairs=null,this.ctx.zoomPanSelection=null,this.ctx.updateHelpers=null,this.ctx.toolbar=null,this.ctx.localization=null,this.ctx.w.globals.tooltip=null,this.clearDomElements({isUpdating:t})}},{key:"killSVG",value:function(e){e.each((function(e,t){this.removeClass("*"),this.off(),this.stop()}),!0),e.ungroup(),e.clear()}},{key:"clearDomElements",value:function(e){var t=this,n=e.isUpdating,r=this.w.globals.dom.Paper.node;r.parentNode&&r.parentNode.parentNode&&!n&&(r.parentNode.parentNode.style.minHeight="unset");var i=this.w.globals.dom.baseEl;i&&this.ctx.eventList.forEach((function(e){i.removeEventListener(e,t.ctx.events.documentEvent)}));var a=this.w.globals.dom;if(null!==this.ctx.el)for(;this.ctx.el.firstChild;)this.ctx.el.removeChild(this.ctx.el.firstChild);this.killSVG(a.Paper),a.Paper.remove(),a.elWrap=null,a.elGraphical=null,a.elLegendWrap=null,a.elLegendForeign=null,a.baseEl=null,a.elGridRect=null,a.elGridRectMask=null,a.elGridRectMarkerMask=null,a.elForecastMask=null,a.elNonForecastMask=null,a.elDefs=null}}]),e}(),Ue=new WeakMap,Ze=function(){function e(t,n){s(this,e),this.opts=n,this.ctx=this,this.w=new j(n).init(),this.el=t,this.w.globals.cuid=y.randomId(),this.w.globals.chartID=this.w.config.chart.id?y.escapeString(this.w.config.chart.id):this.w.globals.cuid,new Ve(this).initModules(),this.create=y.bind(this.create,this),this.windowResizeHandler=this._windowResizeHandler.bind(this),this.parentResizeHandler=this._parentResizeCallback.bind(this)}return c(e,[{key:"render",value:function(){var e=this;return new Promise((function(t,n){if(null!==e.el){void 0===Apex._chartInstances&&(Apex._chartInstances=[]),e.w.config.chart.id&&Apex._chartInstances.push({id:e.w.globals.chartID,group:e.w.config.chart.group,chart:e}),e.setLocale(e.w.config.chart.defaultLocale);var r=e.w.config.chart.events.beforeMount;if("function"==typeof r&&r(e,e.w),e.events.fireEvent("beforeMount",[e,e.w]),window.addEventListener("resize",e.windowResizeHandler),function(e,t){var n=!1;if(e.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var r=e.getBoundingClientRect();"none"!==e.style.display&&0!==r.width||(n=!0)}var i=new ResizeObserver((function(r){n&&t.call(e,r),n=!0}));e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?Array.from(e.children).forEach((function(e){return i.observe(e)})):i.observe(e),Ue.set(t,i)}(e.el.parentNode,e.parentResizeHandler),!e.css){var i=e.el.getRootNode&&e.el.getRootNode(),a=y.is("ShadowRoot",i),o=e.el.ownerDocument,s=o.getElementById("apexcharts-css");if(a||!s){var l;e.css=document.createElement("style"),e.css.id="apexcharts-css",e.css.textContent='@keyframes opaque {\n 0% {\n opacity: 0\n }\n\n to {\n opacity: 1\n }\n}\n\n@keyframes resizeanim {\n 0%,to {\n opacity: 0\n }\n}\n\n.apexcharts-canvas {\n position: relative;\n user-select: none\n}\n\n.apexcharts-canvas ::-webkit-scrollbar {\n -webkit-appearance: none;\n width: 6px\n}\n\n.apexcharts-canvas ::-webkit-scrollbar-thumb {\n border-radius: 4px;\n background-color: rgba(0,0,0,.5);\n box-shadow: 0 0 1px rgba(255,255,255,.5);\n -webkit-box-shadow: 0 0 1px rgba(255,255,255,.5)\n}\n\n.apexcharts-inner {\n position: relative\n}\n\n.apexcharts-text tspan {\n font-family: inherit\n}\n\n.legend-mouseover-inactive {\n transition: .15s ease all;\n opacity: .2\n}\n\n.apexcharts-legend-text {\n padding-left: 15px;\n margin-left: -15px;\n}\n\n.apexcharts-series-collapsed {\n opacity: 0\n}\n\n.apexcharts-tooltip {\n border-radius: 5px;\n box-shadow: 2px 2px 6px -4px #999;\n cursor: default;\n font-size: 14px;\n left: 62px;\n opacity: 0;\n pointer-events: none;\n position: absolute;\n top: 20px;\n display: flex;\n flex-direction: column;\n overflow: hidden;\n white-space: nowrap;\n z-index: 12;\n transition: .15s ease all\n}\n\n.apexcharts-tooltip.apexcharts-active {\n opacity: 1;\n transition: .15s ease all\n}\n\n.apexcharts-tooltip.apexcharts-theme-light {\n border: 1px solid #e3e3e3;\n background: rgba(255,255,255,.96)\n}\n\n.apexcharts-tooltip.apexcharts-theme-dark {\n color: #fff;\n background: rgba(30,30,30,.8)\n}\n\n.apexcharts-tooltip * {\n font-family: inherit\n}\n\n.apexcharts-tooltip-title {\n padding: 6px;\n font-size: 15px;\n margin-bottom: 4px\n}\n\n.apexcharts-tooltip.apexcharts-theme-light .apexcharts-tooltip-title {\n background: #eceff1;\n border-bottom: 1px solid #ddd\n}\n\n.apexcharts-tooltip.apexcharts-theme-dark .apexcharts-tooltip-title {\n background: rgba(0,0,0,.7);\n border-bottom: 1px solid #333\n}\n\n.apexcharts-tooltip-text-goals-value,.apexcharts-tooltip-text-y-value,.apexcharts-tooltip-text-z-value {\n display: inline-block;\n margin-left: 5px;\n font-weight: 600\n}\n\n.apexcharts-tooltip-text-goals-label:empty,.apexcharts-tooltip-text-goals-value:empty,.apexcharts-tooltip-text-y-label:empty,.apexcharts-tooltip-text-y-value:empty,.apexcharts-tooltip-text-z-value:empty,.apexcharts-tooltip-title:empty {\n display: none\n}\n\n.apexcharts-tooltip-text-goals-label,.apexcharts-tooltip-text-goals-value {\n padding: 6px 0 5px\n}\n\n.apexcharts-tooltip-goals-group,.apexcharts-tooltip-text-goals-label,.apexcharts-tooltip-text-goals-value {\n display: flex\n}\n\n.apexcharts-tooltip-text-goals-label:not(:empty),.apexcharts-tooltip-text-goals-value:not(:empty) {\n margin-top: -6px\n}\n\n.apexcharts-tooltip-marker {\n width: 12px;\n height: 12px;\n position: relative;\n top: 0;\n margin-right: 10px;\n border-radius: 50%\n}\n\n.apexcharts-tooltip-series-group {\n padding: 0 10px;\n display: none;\n text-align: left;\n justify-content: left;\n align-items: center\n}\n\n.apexcharts-tooltip-series-group.apexcharts-active .apexcharts-tooltip-marker {\n opacity: 1\n}\n\n.apexcharts-tooltip-series-group.apexcharts-active,.apexcharts-tooltip-series-group:last-child {\n padding-bottom: 4px\n}\n\n.apexcharts-tooltip-series-group-hidden {\n opacity: 0;\n height: 0;\n line-height: 0;\n padding: 0!important\n}\n\n.apexcharts-tooltip-y-group {\n padding: 6px 0 5px\n}\n\n.apexcharts-custom-tooltip,.apexcharts-tooltip-box {\n padding: 4px 8px\n}\n\n.apexcharts-tooltip-boxPlot {\n display: flex;\n flex-direction: column-reverse\n}\n\n.apexcharts-tooltip-box>div {\n margin: 4px 0\n}\n\n.apexcharts-tooltip-box span.value {\n font-weight: 700\n}\n\n.apexcharts-tooltip-rangebar {\n padding: 5px 8px\n}\n\n.apexcharts-tooltip-rangebar .category {\n font-weight: 600;\n color: #777\n}\n\n.apexcharts-tooltip-rangebar .series-name {\n font-weight: 700;\n display: block;\n margin-bottom: 5px\n}\n\n.apexcharts-xaxistooltip,.apexcharts-yaxistooltip {\n opacity: 0;\n pointer-events: none;\n color: #373d3f;\n font-size: 13px;\n text-align: center;\n border-radius: 2px;\n position: absolute;\n z-index: 10;\n background: #eceff1;\n border: 1px solid #90a4ae\n}\n\n.apexcharts-xaxistooltip {\n padding: 9px 10px;\n transition: .15s ease all\n}\n\n.apexcharts-xaxistooltip.apexcharts-theme-dark {\n background: rgba(0,0,0,.7);\n border: 1px solid rgba(0,0,0,.5);\n color: #fff\n}\n\n.apexcharts-xaxistooltip:after,.apexcharts-xaxistooltip:before {\n left: 50%;\n border: solid transparent;\n content: " ";\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none\n}\n\n.apexcharts-xaxistooltip:after {\n border-color: transparent;\n border-width: 6px;\n margin-left: -6px\n}\n\n.apexcharts-xaxistooltip:before {\n border-color: transparent;\n border-width: 7px;\n margin-left: -7px\n}\n\n.apexcharts-xaxistooltip-bottom:after,.apexcharts-xaxistooltip-bottom:before {\n bottom: 100%\n}\n\n.apexcharts-xaxistooltip-top:after,.apexcharts-xaxistooltip-top:before {\n top: 100%\n}\n\n.apexcharts-xaxistooltip-bottom:after {\n border-bottom-color: #eceff1\n}\n\n.apexcharts-xaxistooltip-bottom:before {\n border-bottom-color: #90a4ae\n}\n\n.apexcharts-xaxistooltip-bottom.apexcharts-theme-dark:after,.apexcharts-xaxistooltip-bottom.apexcharts-theme-dark:before {\n border-bottom-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-xaxistooltip-top:after {\n border-top-color: #eceff1\n}\n\n.apexcharts-xaxistooltip-top:before {\n border-top-color: #90a4ae\n}\n\n.apexcharts-xaxistooltip-top.apexcharts-theme-dark:after,.apexcharts-xaxistooltip-top.apexcharts-theme-dark:before {\n border-top-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-xaxistooltip.apexcharts-active {\n opacity: 1;\n transition: .15s ease all\n}\n\n.apexcharts-yaxistooltip {\n padding: 4px 10px\n}\n\n.apexcharts-yaxistooltip.apexcharts-theme-dark {\n background: rgba(0,0,0,.7);\n border: 1px solid rgba(0,0,0,.5);\n color: #fff\n}\n\n.apexcharts-yaxistooltip:after,.apexcharts-yaxistooltip:before {\n top: 50%;\n border: solid transparent;\n content: " ";\n height: 0;\n width: 0;\n position: absolute;\n pointer-events: none\n}\n\n.apexcharts-yaxistooltip:after {\n border-color: transparent;\n border-width: 6px;\n margin-top: -6px\n}\n\n.apexcharts-yaxistooltip:before {\n border-color: transparent;\n border-width: 7px;\n margin-top: -7px\n}\n\n.apexcharts-yaxistooltip-left:after,.apexcharts-yaxistooltip-left:before {\n left: 100%\n}\n\n.apexcharts-yaxistooltip-right:after,.apexcharts-yaxistooltip-right:before {\n right: 100%\n}\n\n.apexcharts-yaxistooltip-left:after {\n border-left-color: #eceff1\n}\n\n.apexcharts-yaxistooltip-left:before {\n border-left-color: #90a4ae\n}\n\n.apexcharts-yaxistooltip-left.apexcharts-theme-dark:after,.apexcharts-yaxistooltip-left.apexcharts-theme-dark:before {\n border-left-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-yaxistooltip-right:after {\n border-right-color: #eceff1\n}\n\n.apexcharts-yaxistooltip-right:before {\n border-right-color: #90a4ae\n}\n\n.apexcharts-yaxistooltip-right.apexcharts-theme-dark:after,.apexcharts-yaxistooltip-right.apexcharts-theme-dark:before {\n border-right-color: rgba(0,0,0,.5)\n}\n\n.apexcharts-yaxistooltip.apexcharts-active {\n opacity: 1\n}\n\n.apexcharts-yaxistooltip-hidden {\n display: none\n}\n\n.apexcharts-xcrosshairs,.apexcharts-ycrosshairs {\n pointer-events: none;\n opacity: 0;\n transition: .15s ease all\n}\n\n.apexcharts-xcrosshairs.apexcharts-active,.apexcharts-ycrosshairs.apexcharts-active {\n opacity: 1;\n transition: .15s ease all\n}\n\n.apexcharts-ycrosshairs-hidden {\n opacity: 0\n}\n\n.apexcharts-selection-rect {\n cursor: move\n}\n\n.svg_select_boundingRect,.svg_select_points_rot {\n pointer-events: none;\n opacity: 0;\n visibility: hidden\n}\n\n.apexcharts-selection-rect+g .svg_select_boundingRect,.apexcharts-selection-rect+g .svg_select_points_rot {\n opacity: 0;\n visibility: hidden\n}\n\n.apexcharts-selection-rect+g .svg_select_points_l,.apexcharts-selection-rect+g .svg_select_points_r {\n cursor: ew-resize;\n opacity: 1;\n visibility: visible\n}\n\n.svg_select_points {\n fill: #efefef;\n stroke: #333;\n rx: 2\n}\n\n.apexcharts-svg.apexcharts-zoomable.hovering-zoom {\n cursor: crosshair\n}\n\n.apexcharts-svg.apexcharts-zoomable.hovering-pan {\n cursor: move\n}\n\n.apexcharts-menu-icon,.apexcharts-pan-icon,.apexcharts-reset-icon,.apexcharts-selection-icon,.apexcharts-toolbar-custom-icon,.apexcharts-zoom-icon,.apexcharts-zoomin-icon,.apexcharts-zoomout-icon {\n cursor: pointer;\n width: 20px;\n height: 20px;\n line-height: 24px;\n color: #6e8192;\n text-align: center\n}\n\n.apexcharts-menu-icon svg,.apexcharts-reset-icon svg,.apexcharts-zoom-icon svg,.apexcharts-zoomin-icon svg,.apexcharts-zoomout-icon svg {\n fill: #6e8192\n}\n\n.apexcharts-selection-icon svg {\n fill: #444;\n transform: scale(.76)\n}\n\n.apexcharts-theme-dark .apexcharts-menu-icon svg,.apexcharts-theme-dark .apexcharts-pan-icon svg,.apexcharts-theme-dark .apexcharts-reset-icon svg,.apexcharts-theme-dark .apexcharts-selection-icon svg,.apexcharts-theme-dark .apexcharts-toolbar-custom-icon svg,.apexcharts-theme-dark .apexcharts-zoom-icon svg,.apexcharts-theme-dark .apexcharts-zoomin-icon svg,.apexcharts-theme-dark .apexcharts-zoomout-icon svg {\n fill: #f3f4f5\n}\n\n.apexcharts-canvas .apexcharts-reset-zoom-icon.apexcharts-selected svg,.apexcharts-canvas .apexcharts-selection-icon.apexcharts-selected svg,.apexcharts-canvas .apexcharts-zoom-icon.apexcharts-selected svg {\n fill: #008ffb\n}\n\n.apexcharts-theme-light .apexcharts-menu-icon:hover svg,.apexcharts-theme-light .apexcharts-reset-icon:hover svg,.apexcharts-theme-light .apexcharts-selection-icon:not(.apexcharts-selected):hover svg,.apexcharts-theme-light .apexcharts-zoom-icon:not(.apexcharts-selected):hover svg,.apexcharts-theme-light .apexcharts-zoomin-icon:hover svg,.apexcharts-theme-light .apexcharts-zoomout-icon:hover svg {\n fill: #333\n}\n\n.apexcharts-menu-icon,.apexcharts-selection-icon {\n position: relative\n}\n\n.apexcharts-reset-icon {\n margin-left: 5px\n}\n\n.apexcharts-menu-icon,.apexcharts-reset-icon,.apexcharts-zoom-icon {\n transform: scale(.85)\n}\n\n.apexcharts-zoomin-icon,.apexcharts-zoomout-icon {\n transform: scale(.7)\n}\n\n.apexcharts-zoomout-icon {\n margin-right: 3px\n}\n\n.apexcharts-pan-icon {\n transform: scale(.62);\n position: relative;\n left: 1px;\n top: 0\n}\n\n.apexcharts-pan-icon svg {\n fill: #fff;\n stroke: #6e8192;\n stroke-width: 2\n}\n\n.apexcharts-pan-icon.apexcharts-selected svg {\n stroke: #008ffb\n}\n\n.apexcharts-pan-icon:not(.apexcharts-selected):hover svg {\n stroke: #333\n}\n\n.apexcharts-toolbar {\n position: absolute;\n z-index: 11;\n max-width: 176px;\n text-align: right;\n border-radius: 3px;\n padding: 0 6px 2px;\n display: flex;\n justify-content: space-between;\n align-items: center\n}\n\n.apexcharts-menu {\n background: #fff;\n position: absolute;\n top: 100%;\n border: 1px solid #ddd;\n border-radius: 3px;\n padding: 3px;\n right: 10px;\n opacity: 0;\n min-width: 110px;\n transition: .15s ease all;\n pointer-events: none\n}\n\n.apexcharts-menu.apexcharts-menu-open {\n opacity: 1;\n pointer-events: all;\n transition: .15s ease all\n}\n\n.apexcharts-menu-item {\n padding: 6px 7px;\n font-size: 12px;\n cursor: pointer\n}\n\n.apexcharts-theme-light .apexcharts-menu-item:hover {\n background: #eee\n}\n\n.apexcharts-theme-dark .apexcharts-menu {\n background: rgba(0,0,0,.7);\n color: #fff\n}\n\n@media screen and (min-width:768px) {\n .apexcharts-canvas:hover .apexcharts-toolbar {\n opacity: 1\n }\n}\n\n.apexcharts-canvas .apexcharts-element-hidden,.apexcharts-datalabel.apexcharts-element-hidden,.apexcharts-hide .apexcharts-series-points {\n opacity: 0\n}\n\n.apexcharts-hidden-element-shown {\n opacity: 1;\n transition: 0.25s ease all;\n}\n.apexcharts-datalabel,.apexcharts-datalabel-label,.apexcharts-datalabel-value,.apexcharts-datalabels,.apexcharts-pie-label {\n cursor: default;\n pointer-events: none\n}\n\n.apexcharts-pie-label-delay {\n opacity: 0;\n animation-name: opaque;\n animation-duration: .3s;\n animation-fill-mode: forwards;\n animation-timing-function: ease\n}\n\n.apexcharts-radialbar-label {\n cursor: pointer;\n}\n\n.apexcharts-annotation-rect,.apexcharts-area-series .apexcharts-area,.apexcharts-area-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,.apexcharts-gridline,.apexcharts-line,.apexcharts-line-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,.apexcharts-point-annotation-label,.apexcharts-radar-series path,.apexcharts-radar-series polygon,.apexcharts-toolbar svg,.apexcharts-tooltip .apexcharts-marker,.apexcharts-xaxis-annotation-label,.apexcharts-yaxis-annotation-label,.apexcharts-zoom-rect {\n pointer-events: none\n}\n\n.apexcharts-marker {\n transition: .15s ease all\n}\n\n.resize-triggers {\n animation: 1ms resizeanim;\n visibility: hidden;\n opacity: 0;\n height: 100%;\n width: 100%;\n overflow: hidden\n}\n\n.contract-trigger:before,.resize-triggers,.resize-triggers>div {\n content: " ";\n display: block;\n position: absolute;\n top: 0;\n left: 0\n}\n\n.resize-triggers>div {\n height: 100%;\n width: 100%;\n background: #eee;\n overflow: auto\n}\n\n.contract-trigger:before {\n overflow: hidden;\n width: 200%;\n height: 200%\n}\n\n.apexcharts-bar-goals-markers{\n pointer-events: none\n}\n\n.apexcharts-bar-shadows{\n pointer-events: none\n}\n\n.apexcharts-rangebar-goals-markers{\n pointer-events: none\n}';var c=(null===(l=e.opts.chart)||void 0===l?void 0:l.nonce)||e.w.config.chart.nonce;c&&e.css.setAttribute("nonce",c),a?i.prepend(e.css):o.head.appendChild(e.css)}}var u=e.create(e.w.config.series,{});if(!u)return t(e);e.mount(u).then((function(){"function"==typeof e.w.config.chart.events.mounted&&e.w.config.chart.events.mounted(e,e.w),e.events.fireEvent("mounted",[e,e.w]),t(u)})).catch((function(e){n(e)}))}else n(new Error("Element not found"))}))}},{key:"create",value:function(e,t){var n=this.w;new Ve(this).initModules();var r=this.w.globals;if(r.noData=!1,r.animationEnded=!1,this.responsive.checkResponsiveConfig(t),n.config.xaxis.convertedCatToNumeric&&new D(n.config).convertCatToNumericXaxis(n.config,this.ctx),null===this.el)return r.animationEnded=!0,null;if(this.core.setupElements(),"treemap"===n.config.chart.type&&(n.config.grid.show=!1,n.config.yaxis[0].show=!1),0===r.svgWidth)return r.animationEnded=!0,null;var i=C.checkComboSeries(e);r.comboCharts=i.comboCharts,r.comboBarCount=i.comboBarCount;var a=e.every((function(e){return e.data&&0===e.data.length}));(0===e.length||a)&&this.series.handleNoData(),this.events.setupEventHandlers(),this.data.parseData(e),this.theme.init(),new Y(this).setGlobalMarkerSize(),this.formatters.setLabelFormatters(),this.titleSubtitle.draw(),r.noData&&r.collapsedSeries.length!==r.series.length&&!n.config.legend.showForSingleSeries||this.legend.init(),this.series.hasAllSeriesEqualX(),r.axisCharts&&(this.core.coreCalculations(),"category"!==n.config.xaxis.type&&this.formatters.setLabelFormatters(),this.ctx.toolbar.minX=n.globals.minX,this.ctx.toolbar.maxX=n.globals.maxX),this.formatters.heatmapLabelFormatters(),new C(this).getLargestMarkerSize(),this.dimensions.plotCoords();var o=this.core.xySettings();this.grid.createGridMask();var s=this.core.plotChartType(e,o),l=new W(this);return l.bringForward(),n.config.dataLabels.background.enabled&&l.dataLabelsBackground(),this.core.shiftGraphPosition(),{elGraph:s,xyRatios:o,dimensions:{plot:{left:n.globals.translateX,top:n.globals.translateY,width:n.globals.gridWidth,height:n.globals.gridHeight}}}}},{key:"mount",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=this,r=n.w;return new Promise((function(i,a){if(null===n.el)return a(new Error("Not enough data to display or target element not found"));(null===t||r.globals.allSeriesCollapsed)&&n.series.handleNoData(),n.grid=new q(n);var o,s,l=n.grid.drawGrid();if(n.annotations=new L(n),n.annotations.drawImageAnnos(),n.annotations.drawTextAnnos(),"back"===r.config.grid.position&&(l&&r.globals.dom.elGraphical.add(l.el),null!=l&&null!==(o=l.elGridBorders)&&void 0!==o&&o.node&&r.globals.dom.elGraphical.add(l.elGridBorders)),Array.isArray(t.elGraph))for(var c=0;c0&&r.globals.memory.methodsToExec.forEach((function(e){e.method(e.params,!1,e.context)})),r.globals.axisCharts||r.globals.noData||n.core.resizeNonAxisCharts(),i(n)}))}},{key:"destroy",value:function(){var e,t;window.removeEventListener("resize",this.windowResizeHandler),this.el.parentNode,e=this.parentResizeHandler,(t=Ue.get(e))&&(t.disconnect(),Ue.delete(e));var n=this.w.config.chart.id;n&&Apex._chartInstances.forEach((function(e,t){e.id===y.escapeString(n)&&Apex._chartInstances.splice(t,1)})),new Ge(this.ctx).clear({isUpdating:!1})}},{key:"updateOptions",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],o=this.w;return o.globals.selection=void 0,e.series&&(this.series.resetSeries(!1,!0,!1),e.series.length&&e.series[0].data&&(e.series=e.series.map((function(e,n){return t.updateHelpers._extendSeries(e,n)}))),this.updateHelpers.revertDefaultAxisMinMax()),e.xaxis&&(e=this.updateHelpers.forceXAxisUpdate(e)),e.yaxis&&(e=this.updateHelpers.forceYAxisUpdate(e)),o.globals.collapsedSeriesIndices.length>0&&this.series.clearPreviousPaths(),e.theme&&(e=this.theme.updateThemeOptions(e)),this.updateHelpers._updateOptions(e,n,r,i,a)}},{key:"updateSeries",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(e,t,n)}},{key:"appendSeries",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=this.w.config.series.slice();return r.push(e),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(r,t,n)}},{key:"appendData",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=this;n.w.globals.dataChanged=!0,n.series.getPreviousPaths();for(var r=n.w.config.series.slice(),i=0;i0&&void 0!==arguments[0])||arguments[0],t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];this.series.resetSeries(e,t)}},{key:"addEventListener",value:function(e,t){this.events.addEventListener(e,t)}},{key:"removeEventListener",value:function(e,t){this.events.removeEventListener(e,t)}},{key:"addXaxisAnnotation",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=this;n&&(r=n),r.annotations.addXaxisAnnotationExternal(e,t,r)}},{key:"addYaxisAnnotation",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=this;n&&(r=n),r.annotations.addYaxisAnnotationExternal(e,t,r)}},{key:"addPointAnnotation",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=this;n&&(r=n),r.annotations.addPointAnnotationExternal(e,t,r)}},{key:"clearAnnotations",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,t=this;e&&(t=e),t.annotations.clearAnnotations(t)}},{key:"removeAnnotation",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,n=this;t&&(n=t),n.annotations.removeAnnotation(n,e)}},{key:"getChartArea",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-inner")}},{key:"getSeriesTotalXRange",value:function(e,t){return this.coreUtils.getSeriesTotalsXRange(e,t)}},{key:"getHighestValueInSeries",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return new Q(this.ctx).getMinYMaxY(e).highestY}},{key:"getLowestValueInSeries",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return new Q(this.ctx).getMinYMaxY(e).lowestY}},{key:"getSeriesTotal",value:function(){return this.w.globals.seriesTotals}},{key:"toggleDataPointSelection",value:function(e,t){return this.updateHelpers.toggleDataPointSelection(e,t)}},{key:"zoomX",value:function(e,t){this.ctx.toolbar.zoomUpdateOptions(e,t)}},{key:"setLocale",value:function(e){this.localization.setCurrentLocaleValues(e)}},{key:"dataURI",value:function(e){return new U(this.ctx).dataURI(e)}},{key:"exportToCSV",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new U(this.ctx).exportToCSV(e)}},{key:"paper",value:function(){return this.w.globals.dom.Paper}},{key:"_parentResizeCallback",value:function(){this.w.globals.animationEnded&&this.w.config.chart.redrawOnParentResize&&this._windowResize()}},{key:"_windowResize",value:function(){var e=this;clearTimeout(this.w.globals.resizeTimer),this.w.globals.resizeTimer=window.setTimeout((function(){e.w.globals.resized=!0,e.w.globals.dataChanged=!1,e.ctx.update()}),150)}},{key:"_windowResizeHandler",value:function(){var e=this.w.config.chart.redrawOnWindowResize;"function"==typeof e&&(e=e()),e&&this._windowResize()}}],[{key:"getChartByID",value:function(e){var t=y.escapeString(e);if(Apex._chartInstances){var n=Apex._chartInstances.filter((function(e){return e.id===t}))[0];return n&&n.chart}}},{key:"initOnLoad",value:function(){for(var t=document.querySelectorAll("[data-apexcharts]"),n=0;n2?i-2:0),o=2;o
'}}},download:{heights:{16:{width:16,path:''}}},eye:{heights:{16:{width:16,path:''}}},heart:{heights:{16:{width:16,path:''}}},"issue-opened":{heights:{16:{width:16,path:''}}},"mark-github":{heights:{16:{width:16,path:''}}},package:{heights:{16:{width:16,path:''}}},play:{heights:{16:{width:16,path:''}}},"repo-forked":{heights:{16:{width:16,path:''}}},"repo-template":{heights:{16:{width:16,path:''}}},star:{heights:{16:{width:16,path:''}}}},k=function(e,t){e=d(e).replace(/^octicon-/,""),u(w,e)||(e="mark-github");var n=t>=24&&24 in w[e].heights?24:16,r=w[e].heights[n];return'"},S={},C=function(e,t){var n=S[e]||(S[e]=[]);if(!(n.push(t)>1)){var r=function(e){var t;return function(){t||(t=1,e.apply(this,arguments))}}((function(){for(delete S[e];t=n.shift();)t.apply(null,arguments)}));if(p){var i=new o;m(i,"abort",r),m(i,"error",r),m(i,"load",(function(){var e;try{e=JSON.parse(this.responseText)}catch(t){return void r(t)}r(200!==this.status,e)})),i.open("GET",e),i.send()}else{var a=this||window;a._=function(e){a._=null,r(200!==e.meta.status,e.data)};var s=l(a.document)("script",{async:!0,src:e+(-1!==e.indexOf("?")?"&":"?")+"callback=_"}),c=function(){a._&&a._({meta:{}})};m(s,"load",c),m(s,"error",c),function(e,t,n){if(null!=e.readyState){var r="readystatechange";m(e,r,(function i(){if(t.test(e.readyState))return v(e,r,i),n.apply(this,arguments)}))}}(s,/de|m/,c),a.document.getElementsByTagName("head")[0].appendChild(s)}}},A=function(e,t,n){var r=l(e.ownerDocument),i=e.appendChild(r("style",{type:"text/css"})),a="body{margin:0}a{text-decoration:none;outline:0}.widget{display:inline-block;overflow:hidden;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-serif;font-size:0;line-height:0;white-space:nowrap}.btn,.social-count{position:relative;display:inline-block;display:inline-flex;height:14px;padding:2px 5px;font-size:11px;font-weight:600;line-height:14px;vertical-align:bottom;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-repeat:repeat-x;background-position:-1px -1px;background-size:110% 110%;border:1px solid}.btn{border-radius:.25em}.btn:not(:last-child){border-radius:.25em 0 0 .25em}.social-count{border-left:0;border-radius:0 .25em .25em 0}.widget-lg .btn,.widget-lg .social-count{height:16px;padding:5px 10px;font-size:12px;line-height:16px}.octicon{display:inline-block;vertical-align:text-top;fill:currentColor;overflow:visible}"+y(t["data-color-scheme"]);i.styleSheet?i.styleSheet.cssText=a:i.appendChild(e.ownerDocument.createTextNode(a));var o="large"===d(t["data-size"]),s=r("a",{className:"btn",href:t.href,rel:"noopener",target:"_blank",title:t.title||void 0,"aria-label":t["aria-label"]||void 0,innerHTML:k(t["data-icon"],o?16:14)+" "},[r("span",{},[t["data-text"]||""])]),c=e.appendChild(r("div",{className:"widget"+(o?" widget-lg":"")},[s])),u=s.hostname.replace(/\.$/,"");if(("."+u).substring(u.length-10)!=="."+h)return s.removeAttribute("href"),void n(c);var p=(" /"+s.pathname).split(/\/+/);if(((u===h||u==="gist."+h)&&"archive"===p[3]||u===h&&"releases"===p[3]&&("download"===p[4]||"latest"===p[4]&&"download"===p[5])||u==="codeload."+h)&&(s.target="_top"),"true"===d(t["data-show-count"])&&u===h&&"marketplace"!==p[1]&&"sponsors"!==p[1]&&"orgs"!==p[1]&&"users"!==p[1]&&"-"!==p[1]){var g,m;if(!p[2]&&p[1])m="followers",g="?tab=followers";else if(!p[3]&&p[2])m="stargazers_count",g="/stargazers";else if(p[4]||"subscription"!==p[3])if(p[4]||"fork"!==p[3]){if("issues"!==p[3])return void n(c);m="open_issues_count",g="/issues"}else m="forks_count",g="/forks";else m="subscribers_count",g="/watchers";var v=p[2]?"/repos/"+p[1]+"/"+p[2]:"/users/"+p[1];C.call(this,f+v,(function(e,t){if(!e){var i=t[m];c.appendChild(r("a",{className:"social-count",href:t.html_url+g,rel:"noopener",target:"_blank","aria-label":i+" "+m.replace(/_count$/,"").replace("_"," ").slice(0,i<2?-1:void 0)+" on GitHub"},[(""+i).replace(/\B(?=(\d{3})+(?!\d))/g,",")]))}n(c)}))}else n(c)},E=window.devicePixelRatio||1,P=function(e){return(E>1?i.ceil(i.round(e*E)/E*2)/2:i.ceil(e))||0},T=function(e,t){e.style.width=t[0]+"px",e.style.height=t[1]+"px"},M=function(e,t){if(null!=e&&null!=t)if(e.getAttribute&&(e=function(e){var t={href:e.href,title:e.title,"aria-label":e.getAttribute("aria-label")};return s(["icon","color-scheme","text","size","show-count"],(function(n){var r="data-"+n;t[r]=e.getAttribute(r)})),null==t["data-text"]&&(t["data-text"]=e.textContent||e.innerText),t}(e)),g){var n=c("span");A(n.attachShadow({mode:"closed"}),e,(function(){t(n)}))}else{var a=c("iframe",{src:"javascript:0",title:e.title||void 0,allowtransparency:!0,scrolling:"no",frameBorder:0});T(a,[0,0]),a.style.border="none";m(a,"load",(function n(){var o,s=a.contentWindow;try{o=s.document.body}catch(l){return void r.body.appendChild(a.parentNode.removeChild(a))}v(a,"load",n),A.call(s,o,e,(function(n){var r=function(e){var t=e.offsetWidth,n=e.offsetHeight;if(e.getBoundingClientRect){var r=e.getBoundingClientRect();t=i.max(t,P(r.width)),n=i.max(n,P(r.height))}return[t,n]}(n);a.parentNode.removeChild(a),function(e,t,n){m(e,t,(function r(){return v(e,t,r),n.apply(this,arguments)}))}(a,"load",(function(){T(a,r)})),a.src="https://unpkg.com/github-buttons@2.27.0/dist/buttons.html#"+(a.name=function(e,t,n,r){null==t&&(t="&"),null==n&&(n="="),null==r&&(r=window.encodeURIComponent);var i=[];for(var a in e){var o=e[a];null!=o&&i.push(r(a)+n+r(o))}return i.join(t)}(e)),t(a)}))})),r.body.appendChild(a)}}},861:function(e,t,n){"use strict";var r=n(214),i={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},a={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},o={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return r.isMemo(e)?o:s[e.$$typeof]||i}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[r.Memo]=o;var c=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,n,r){if("string"!==typeof n){if(p){var i=f(n);i&&i!==p&&e(t,i,r)}var o=u(n);d&&(o=o.concat(d(n)));for(var s=l(t),g=l(n),m=0;m-1},ee.prototype.set=function(e,t){var n=this.__data__,r=oe(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},te.prototype.clear=function(){this.size=0,this.__data__={hash:new J,map:new($||ee),string:new J}},te.prototype.delete=function(e){var t=ve(this,e).delete(e);return this.size-=t?1:0,t},te.prototype.get=function(e){return ve(this,e).get(e)},te.prototype.has=function(e){return ve(this,e).has(e)},te.prototype.set=function(e,t){var n=ve(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},ne.prototype.clear=function(){this.__data__=new ee,this.size=0},ne.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},ne.prototype.get=function(e){return this.__data__.get(e)},ne.prototype.has=function(e){return this.__data__.has(e)},ne.prototype.set=function(e,t){var n=this.__data__;if(n instanceof ee){var r=n.__data__;if(!$||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new te(r)}return n.set(e,t),this.size=n.size,this};var le,ce=function(e,t,n){for(var r=-1,i=Object(e),a=n(e),o=a.length;o--;){var s=a[le?o:++r];if(!1===t(i[s],s,i))break}return e};function ue(e){return null==e?void 0===e?h:c:V&&V in Object(e)?function(e){var t=O.call(e,V),n=e[V];try{e[V]=void 0;var r=!0}catch(a){}var i=R.call(e);r&&(t?e[V]=n:delete e[V]);return i}(e):function(e){return R.call(e)}(e)}function de(e){return Le(e)&&ue(e)==a}function he(e){return!(!_e(e)||function(e){return!!I&&I in e}(e))&&(Te(e)?D:f).test(function(e){if(null!=e){try{return L.call(e)}catch(t){}try{return e+""}catch(t){}}return""}(e))}function fe(e){if(!_e(e))return function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}(e);var t=ye(e),n=[];for(var r in e)("constructor"!=r||!t&&O.call(e,r))&&n.push(r);return n}function pe(e,t,n,r,i){e!==t&&ce(t,(function(a,o){if(i||(i=new ne),_e(a))!function(e,t,n,r,i,a,o){var s=we(e,n),l=we(t,n),c=o.get(l);if(c)return void ie(e,n,c);var d=a?a(s,l,n+"",e,t,o):void 0,h=void 0===d;if(h){var f=Ae(l),p=!f&&Pe(l),g=!f&&!p&&Oe(l);d=l,f||p||g?Ae(s)?d=s:Le(m=s)&&Ee(m)?d=function(e,t){var n=-1,r=e.length;t||(t=Array(r));for(;++n-1&&e%1==0&&e0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(me);function Se(e,t){return e===t||e!==e&&t!==t}var Ce=de(function(){return arguments}())?de:function(e){return Le(e)&&O.call(e,"callee")&&!W.call(e,"callee")},Ae=Array.isArray;function Ee(e){return null!=e&&Me(e.length)&&!Te(e)}var Pe=U||function(){return!1};function Te(e){if(!_e(e))return!1;var t=ue(e);return t==s||t==l||t==o||t==d}function Me(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=i}function _e(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Le(e){return null!=e&&"object"==typeof e}var Oe=C?function(e){return function(t){return e(t)}}(C):function(e){return Le(e)&&Me(e.length)&&!!g[ue(e)]};function Ie(e){return Ee(e)?re(e,!0):fe(e)}var Re,ze=(Re=function(e,t,n,r){pe(e,t,n,r)},ge((function(e,t){var n=-1,r=t.length,i=r>1?t[r-1]:void 0,a=r>2?t[2]:void 0;for(i=Re.length>3&&"function"==typeof i?(r--,i):void 0,a&&function(e,t,n){if(!_e(n))return!1;var r=typeof t;return!!("number"==r?Ee(n)&&be(t,n.length):"string"==r&&t in n)&&Se(n[t],e)}(t[0],t[1],a)&&(i=r<3?void 0:i,r=1),e=Object(e);++n>>0;for(t=0;t0)for(n=0;n=0?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}var D=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,F=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,N={},j={};function B(e,t,n,r){var i=r;"string"===typeof r&&(i=function(){return this[r]()}),e&&(j[e]=i),t&&(j[t[0]]=function(){return z(i.apply(this,arguments),t[1],t[2])}),n&&(j[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),e)})}function Y(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function H(e){var t,n,r=e.match(D);for(t=0,n=r.length;t=0&&F.test(e);)e=e.replace(F,r),F.lastIndex=0,n-=1;return e}var V={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};function G(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(D).map((function(e){return"MMMM"===e||"MM"===e||"DD"===e||"dddd"===e?e.slice(1):e})).join(""),this._longDateFormat[e])}var U="Invalid date";function Z(){return this._invalidDate}var q="%d",$=/\d{1,2}/;function Q(e){return this._ordinal.replace("%d",e)}var K={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function J(e,t,n,r){var i=this._relativeTime[n];return M(i)?i(e,t,n,r):i.replace(/%d/i,e)}function ee(e,t){var n=this._relativeTime[e>0?"future":"past"];return M(n)?n(t):n.replace(/%s/i,t)}var te={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function ne(e){return"string"===typeof e?te[e]||te[e.toLowerCase()]:void 0}function re(e){var t,n,r={};for(n in e)s(e,n)&&(t=ne(n))&&(r[t]=e[n]);return r}var ie={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1};function ae(e){var t,n=[];for(t in e)s(e,t)&&n.push({unit:t,priority:ie[t]});return n.sort((function(e,t){return e.priority-t.priority})),n}var oe,se=/\d/,le=/\d\d/,ce=/\d{3}/,ue=/\d{4}/,de=/[+-]?\d{6}/,he=/\d\d?/,fe=/\d\d\d\d?/,pe=/\d\d\d\d\d\d?/,ge=/\d{1,3}/,me=/\d{1,4}/,ve=/[+-]?\d{1,6}/,xe=/\d+/,be=/[+-]?\d+/,ye=/Z|[+-]\d\d:?\d\d/gi,we=/Z|[+-]\d\d(?::?\d\d)?/gi,ke=/[+-]?\d+(\.\d{1,3})?/,Se=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,Ce=/^[1-9]\d?/,Ae=/^([1-9]\d|\d)/;function Ee(e,t,n){oe[e]=M(t)?t:function(e,r){return e&&n?n:t}}function Pe(e,t){return s(oe,e)?oe[e](t._strict,t._locale):new RegExp(Te(e))}function Te(e){return Me(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(e,t,n,r,i){return t||n||r||i})))}function Me(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function _e(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function Le(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=_e(t)),n}oe={};var Oe={};function Ie(e,t){var n,r,i=t;for("string"===typeof e&&(e=[e]),u(t)&&(i=function(e,n){n[t]=Le(e)}),r=e.length,n=0;n68?1900:2e3)};var Ue,Ze=$e("FullYear",!0);function qe(){return De(this.year())}function $e(e,t){return function(n){return null!=n?(Ke(this,e,n),r.updateOffset(this,t),this):Qe(this,e)}}function Qe(e,t){if(!e.isValid())return NaN;var n=e._d,r=e._isUTC;switch(t){case"Milliseconds":return r?n.getUTCMilliseconds():n.getMilliseconds();case"Seconds":return r?n.getUTCSeconds():n.getSeconds();case"Minutes":return r?n.getUTCMinutes():n.getMinutes();case"Hours":return r?n.getUTCHours():n.getHours();case"Date":return r?n.getUTCDate():n.getDate();case"Day":return r?n.getUTCDay():n.getDay();case"Month":return r?n.getUTCMonth():n.getMonth();case"FullYear":return r?n.getUTCFullYear():n.getFullYear();default:return NaN}}function Ke(e,t,n){var r,i,a,o,s;if(e.isValid()&&!isNaN(n)){switch(r=e._d,i=e._isUTC,t){case"Milliseconds":return void(i?r.setUTCMilliseconds(n):r.setMilliseconds(n));case"Seconds":return void(i?r.setUTCSeconds(n):r.setSeconds(n));case"Minutes":return void(i?r.setUTCMinutes(n):r.setMinutes(n));case"Hours":return void(i?r.setUTCHours(n):r.setHours(n));case"Date":return void(i?r.setUTCDate(n):r.setDate(n));case"FullYear":break;default:return}a=n,o=e.month(),s=29!==(s=e.date())||1!==o||De(a)?s:28,i?r.setUTCFullYear(a,o,s):r.setFullYear(a,o,s)}}function Je(e){return M(this[e=ne(e)])?this[e]():this}function et(e,t){if("object"===typeof e){var n,r=ae(e=re(e)),i=r.length;for(n=0;n=0?(s=new Date(e+400,t,n,r,i,a,o),isFinite(s.getFullYear())&&s.setFullYear(e)):s=new Date(e,t,n,r,i,a,o),s}function bt(e){var t,n;return e<100&&e>=0?((n=Array.prototype.slice.call(arguments))[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function yt(e,t,n){var r=7+t-n;return-(7+bt(e,0,r).getUTCDay()-t)%7+r-1}function wt(e,t,n,r,i){var a,o,s=1+7*(t-1)+(7+n-r)%7+yt(e,r,i);return s<=0?o=Ge(a=e-1)+s:s>Ge(e)?(a=e+1,o=s-Ge(e)):(a=e,o=s),{year:a,dayOfYear:o}}function kt(e,t,n){var r,i,a=yt(e.year(),t,n),o=Math.floor((e.dayOfYear()-a-1)/7)+1;return o<1?r=o+St(i=e.year()-1,t,n):o>St(e.year(),t,n)?(r=o-St(e.year(),t,n),i=e.year()+1):(i=e.year(),r=o),{week:r,year:i}}function St(e,t,n){var r=yt(e,t,n),i=yt(e+1,t,n);return(Ge(e)-r+i)/7}function Ct(e){return kt(e,this._week.dow,this._week.doy).week}B("w",["ww",2],"wo","week"),B("W",["WW",2],"Wo","isoWeek"),Ee("w",he,Ce),Ee("ww",he,le),Ee("W",he,Ce),Ee("WW",he,le),Re(["w","ww","W","WW"],(function(e,t,n,r){t[r.substr(0,1)]=Le(e)}));var At={dow:0,doy:6};function Et(){return this._week.dow}function Pt(){return this._week.doy}function Tt(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")}function Mt(e){var t=kt(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")}function _t(e,t){return"string"!==typeof e?e:isNaN(e)?"number"===typeof(e=t.weekdaysParse(e))?e:null:parseInt(e,10)}function Lt(e,t){return"string"===typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}function Ot(e,t){return e.slice(t,7).concat(e.slice(0,t))}B("d",0,"do","day"),B("dd",0,0,(function(e){return this.localeData().weekdaysMin(this,e)})),B("ddd",0,0,(function(e){return this.localeData().weekdaysShort(this,e)})),B("dddd",0,0,(function(e){return this.localeData().weekdays(this,e)})),B("e",0,0,"weekday"),B("E",0,0,"isoWeekday"),Ee("d",he),Ee("e",he),Ee("E",he),Ee("dd",(function(e,t){return t.weekdaysMinRegex(e)})),Ee("ddd",(function(e,t){return t.weekdaysShortRegex(e)})),Ee("dddd",(function(e,t){return t.weekdaysRegex(e)})),Re(["dd","ddd","dddd"],(function(e,t,n,r){var i=n._locale.weekdaysParse(e,r,n._strict);null!=i?t.d=i:m(n).invalidWeekday=e})),Re(["d","e","E"],(function(e,t,n,r){t[r]=Le(e)}));var It="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Rt="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),zt="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Dt=Se,Ft=Se,Nt=Se;function jt(e,t){var n=a(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?Ot(n,this._week.dow):e?n[e.day()]:n}function Bt(e){return!0===e?Ot(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort}function Yt(e){return!0===e?Ot(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin}function Ht(e,t,n){var r,i,a,o=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)a=p([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(a,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(a,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(a,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(i=Ue.call(this._weekdaysParse,o))?i:null:"ddd"===t?-1!==(i=Ue.call(this._shortWeekdaysParse,o))?i:null:-1!==(i=Ue.call(this._minWeekdaysParse,o))?i:null:"dddd"===t?-1!==(i=Ue.call(this._weekdaysParse,o))||-1!==(i=Ue.call(this._shortWeekdaysParse,o))||-1!==(i=Ue.call(this._minWeekdaysParse,o))?i:null:"ddd"===t?-1!==(i=Ue.call(this._shortWeekdaysParse,o))||-1!==(i=Ue.call(this._weekdaysParse,o))||-1!==(i=Ue.call(this._minWeekdaysParse,o))?i:null:-1!==(i=Ue.call(this._minWeekdaysParse,o))||-1!==(i=Ue.call(this._weekdaysParse,o))||-1!==(i=Ue.call(this._shortWeekdaysParse,o))?i:null}function Wt(e,t,n){var r,i,a;if(this._weekdaysParseExact)return Ht.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(i=p([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(i,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(i,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(i,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(a="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[r]=new RegExp(a.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[r].test(e))return r;if(n&&"ddd"===t&&this._shortWeekdaysParse[r].test(e))return r;if(n&&"dd"===t&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}}function Xt(e){if(!this.isValid())return null!=e?this:NaN;var t=Qe(this,"Day");return null!=e?(e=_t(e,this.localeData()),this.add(e-t,"d")):t}function Vt(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")}function Gt(e){if(!this.isValid())return null!=e?this:NaN;if(null!=e){var t=Lt(e,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7}function Ut(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||$t.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(s(this,"_weekdaysRegex")||(this._weekdaysRegex=Dt),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)}function Zt(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||$t.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(s(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=Ft),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function qt(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||$t.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(s(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Nt),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function $t(){function e(e,t){return t.length-e.length}var t,n,r,i,a,o=[],s=[],l=[],c=[];for(t=0;t<7;t++)n=p([2e3,1]).day(t),r=Me(this.weekdaysMin(n,"")),i=Me(this.weekdaysShort(n,"")),a=Me(this.weekdays(n,"")),o.push(r),s.push(i),l.push(a),c.push(r),c.push(i),c.push(a);o.sort(e),s.sort(e),l.sort(e),c.sort(e),this._weekdaysRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+o.join("|")+")","i")}function Qt(){return this.hours()%12||12}function Kt(){return this.hours()||24}function Jt(e,t){B(e,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)}))}function en(e,t){return t._meridiemParse}function tn(e){return"p"===(e+"").toLowerCase().charAt(0)}B("H",["HH",2],0,"hour"),B("h",["hh",2],0,Qt),B("k",["kk",2],0,Kt),B("hmm",0,0,(function(){return""+Qt.apply(this)+z(this.minutes(),2)})),B("hmmss",0,0,(function(){return""+Qt.apply(this)+z(this.minutes(),2)+z(this.seconds(),2)})),B("Hmm",0,0,(function(){return""+this.hours()+z(this.minutes(),2)})),B("Hmmss",0,0,(function(){return""+this.hours()+z(this.minutes(),2)+z(this.seconds(),2)})),Jt("a",!0),Jt("A",!1),Ee("a",en),Ee("A",en),Ee("H",he,Ae),Ee("h",he,Ce),Ee("k",he,Ce),Ee("HH",he,le),Ee("hh",he,le),Ee("kk",he,le),Ee("hmm",fe),Ee("hmmss",pe),Ee("Hmm",fe),Ee("Hmmss",pe),Ie(["H","HH"],Be),Ie(["k","kk"],(function(e,t,n){var r=Le(e);t[Be]=24===r?0:r})),Ie(["a","A"],(function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e})),Ie(["h","hh"],(function(e,t,n){t[Be]=Le(e),m(n).bigHour=!0})),Ie("hmm",(function(e,t,n){var r=e.length-2;t[Be]=Le(e.substr(0,r)),t[Ye]=Le(e.substr(r)),m(n).bigHour=!0})),Ie("hmmss",(function(e,t,n){var r=e.length-4,i=e.length-2;t[Be]=Le(e.substr(0,r)),t[Ye]=Le(e.substr(r,2)),t[He]=Le(e.substr(i)),m(n).bigHour=!0})),Ie("Hmm",(function(e,t,n){var r=e.length-2;t[Be]=Le(e.substr(0,r)),t[Ye]=Le(e.substr(r))})),Ie("Hmmss",(function(e,t,n){var r=e.length-4,i=e.length-2;t[Be]=Le(e.substr(0,r)),t[Ye]=Le(e.substr(r,2)),t[He]=Le(e.substr(i))}));var nn=/[ap]\.?m?\.?/i,rn=$e("Hours",!0);function an(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"}var on,sn={calendar:I,longDateFormat:V,invalidDate:U,ordinal:q,dayOfMonthOrdinalParse:$,relativeTime:K,months:rt,monthsShort:it,week:At,weekdays:It,weekdaysMin:zt,weekdaysShort:Rt,meridiemParse:nn},ln={},cn={};function un(e,t){var n,r=Math.min(e.length,t.length);for(n=0;n0;){if(r=pn(i.slice(0,t).join("-")))return r;if(n&&n.length>=t&&un(i,n)>=t-1)break;t--}a++}return on}function fn(e){return!(!e||!e.match("^[^/\\\\]*$"))}function pn(t){var n=null;if(void 0===ln[t]&&e&&e.exports&&fn(t))try{n=on._abbr,Object(function(){var e=new Error("Cannot find module 'undefined'");throw e.code="MODULE_NOT_FOUND",e}()),gn(n)}catch(r){ln[t]=null}return ln[t]}function gn(e,t){var n;return e&&((n=c(t)?xn(e):mn(e,t))?on=n:"undefined"!==typeof console&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),on._abbr}function mn(e,t){if(null!==t){var n,r=sn;if(t.abbr=e,null!=ln[e])T("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=ln[e]._config;else if(null!=t.parentLocale)if(null!=ln[t.parentLocale])r=ln[t.parentLocale]._config;else{if(null==(n=pn(t.parentLocale)))return cn[t.parentLocale]||(cn[t.parentLocale]=[]),cn[t.parentLocale].push({name:e,config:t}),null;r=n._config}return ln[e]=new O(L(r,t)),cn[e]&&cn[e].forEach((function(e){mn(e.name,e.config)})),gn(e),ln[e]}return delete ln[e],null}function vn(e,t){if(null!=t){var n,r,i=sn;null!=ln[e]&&null!=ln[e].parentLocale?ln[e].set(L(ln[e]._config,t)):(null!=(r=pn(e))&&(i=r._config),t=L(i,t),null==r&&(t.abbr=e),(n=new O(t)).parentLocale=ln[e],ln[e]=n),gn(e)}else null!=ln[e]&&(null!=ln[e].parentLocale?(ln[e]=ln[e].parentLocale,e===gn()&&gn(e)):null!=ln[e]&&delete ln[e]);return ln[e]}function xn(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return on;if(!a(e)){if(t=pn(e))return t;e=[e]}return hn(e)}function bn(){return E(ln)}function yn(e){var t,n=e._a;return n&&-2===m(e).overflow&&(t=n[Ne]<0||n[Ne]>11?Ne:n[je]<1||n[je]>nt(n[Fe],n[Ne])?je:n[Be]<0||n[Be]>24||24===n[Be]&&(0!==n[Ye]||0!==n[He]||0!==n[We])?Be:n[Ye]<0||n[Ye]>59?Ye:n[He]<0||n[He]>59?He:n[We]<0||n[We]>999?We:-1,m(e)._overflowDayOfYear&&(tje)&&(t=je),m(e)._overflowWeeks&&-1===t&&(t=Xe),m(e)._overflowWeekday&&-1===t&&(t=Ve),m(e).overflow=t),e}var wn=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,kn=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Sn=/Z|[+-]\d\d(?::?\d\d)?/,Cn=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],An=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],En=/^\/?Date\((-?\d+)/i,Pn=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,Tn={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function Mn(e){var t,n,r,i,a,o,s=e._i,l=wn.exec(s)||kn.exec(s),c=Cn.length,u=An.length;if(l){for(m(e).iso=!0,t=0,n=c;tGe(a)||0===e._dayOfYear)&&(m(e)._overflowDayOfYear=!0),n=bt(a,0,e._dayOfYear),e._a[Ne]=n.getUTCMonth(),e._a[je]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=o[t]=r[t];for(;t<7;t++)e._a[t]=o[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[Be]&&0===e._a[Ye]&&0===e._a[He]&&0===e._a[We]&&(e._nextDay=!0,e._a[Be]=0),e._d=(e._useUTC?bt:xt).apply(null,o),i=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[Be]=24),e._w&&"undefined"!==typeof e._w.d&&e._w.d!==i&&(m(e).weekdayMismatch=!0)}}function Bn(e){var t,n,r,i,a,o,s,l,c;null!=(t=e._w).GG||null!=t.W||null!=t.E?(a=1,o=4,n=Fn(t.GG,e._a[Fe],kt(qn(),1,4).year),r=Fn(t.W,1),((i=Fn(t.E,1))<1||i>7)&&(l=!0)):(a=e._locale._week.dow,o=e._locale._week.doy,c=kt(qn(),a,o),n=Fn(t.gg,e._a[Fe],c.year),r=Fn(t.w,c.week),null!=t.d?((i=t.d)<0||i>6)&&(l=!0):null!=t.e?(i=t.e+a,(t.e<0||t.e>6)&&(l=!0)):i=a),r<1||r>St(n,a,o)?m(e)._overflowWeeks=!0:null!=l?m(e)._overflowWeekday=!0:(s=wt(n,r,i,a,o),e._a[Fe]=s.year,e._dayOfYear=s.dayOfYear)}function Yn(e){if(e._f!==r.ISO_8601)if(e._f!==r.RFC_2822){e._a=[],m(e).empty=!0;var t,n,i,a,o,s,l,c=""+e._i,u=c.length,d=0;for(l=(i=X(e._f,e._locale).match(D)||[]).length,t=0;t0&&m(e).unusedInput.push(o),c=c.slice(c.indexOf(n)+n.length),d+=n.length),j[a]?(n?m(e).empty=!1:m(e).unusedTokens.push(a),ze(a,n,e)):e._strict&&!n&&m(e).unusedTokens.push(a);m(e).charsLeftOver=u-d,c.length>0&&m(e).unusedInput.push(c),e._a[Be]<=12&&!0===m(e).bigHour&&e._a[Be]>0&&(m(e).bigHour=void 0),m(e).parsedDateParts=e._a.slice(0),m(e).meridiem=e._meridiem,e._a[Be]=Hn(e._locale,e._a[Be],e._meridiem),null!==(s=m(e).era)&&(e._a[Fe]=e._locale.erasConvertYear(s,e._a[Fe])),jn(e),yn(e)}else zn(e);else Mn(e)}function Hn(e,t,n){var r;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?((r=e.isPM(n))&&t<12&&(t+=12),r||12!==t||(t=0),t):t}function Wn(e){var t,n,r,i,a,o,s=!1,l=e._f.length;if(0===l)return m(e).invalidFormat=!0,void(e._d=new Date(NaN));for(i=0;ithis?this:e:x()}));function Kn(e,t){var n,r;if(1===t.length&&a(t[0])&&(t=t[0]),!t.length)return qn();for(n=t[0],r=1;rthis.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function kr(){if(!c(this._isDSTShifted))return this._isDSTShifted;var e,t={};return w(t,this),(t=Gn(t))._a?(e=t._isUTC?p(t._a):qn(t._a),this._isDSTShifted=this.isValid()&&cr(t._a,e.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function Sr(){return!!this.isValid()&&!this._isUTC}function Cr(){return!!this.isValid()&&this._isUTC}function Ar(){return!!this.isValid()&&this._isUTC&&0===this._offset}r.updateOffset=function(){};var Er=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,Pr=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function Tr(e,t){var n,r,i,a=e,o=null;return sr(e)?a={ms:e._milliseconds,d:e._days,M:e._months}:u(e)||!isNaN(+e)?(a={},t?a[t]=+e:a.milliseconds=+e):(o=Er.exec(e))?(n="-"===o[1]?-1:1,a={y:0,d:Le(o[je])*n,h:Le(o[Be])*n,m:Le(o[Ye])*n,s:Le(o[He])*n,ms:Le(lr(1e3*o[We]))*n}):(o=Pr.exec(e))?(n="-"===o[1]?-1:1,a={y:Mr(o[2],n),M:Mr(o[3],n),w:Mr(o[4],n),d:Mr(o[5],n),h:Mr(o[6],n),m:Mr(o[7],n),s:Mr(o[8],n)}):null==a?a={}:"object"===typeof a&&("from"in a||"to"in a)&&(i=Lr(qn(a.from),qn(a.to)),(a={}).ms=i.milliseconds,a.M=i.months),r=new or(a),sr(e)&&s(e,"_locale")&&(r._locale=e._locale),sr(e)&&s(e,"_isValid")&&(r._isValid=e._isValid),r}function Mr(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function _r(e,t){var n={};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Lr(e,t){var n;return e.isValid()&&t.isValid()?(t=fr(t,e),e.isBefore(t)?n=_r(e,t):((n=_r(t,e)).milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function Or(e,t){return function(n,r){var i;return null===r||isNaN(+r)||(T(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),i=n,n=r,r=i),Ir(this,Tr(n,r),e),this}}function Ir(e,t,n,i){var a=t._milliseconds,o=lr(t._days),s=lr(t._months);e.isValid()&&(i=null==i||i,s&&ht(e,Qe(e,"Month")+s*n),o&&Ke(e,"Date",Qe(e,"Date")+o*n),a&&e._d.setTime(e._d.valueOf()+a*n),i&&r.updateOffset(e,o||s))}Tr.fn=or.prototype,Tr.invalid=ar;var Rr=Or(1,"add"),zr=Or(-1,"subtract");function Dr(e){return"string"===typeof e||e instanceof String}function Fr(e){return S(e)||d(e)||Dr(e)||u(e)||jr(e)||Nr(e)||null===e||void 0===e}function Nr(e){var t,n,r=o(e)&&!l(e),i=!1,a=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],c=a.length;for(t=0;tn.valueOf():n.valueOf()9999?W(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):M(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",W(n,"Z")):W(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function ei(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e,t,n,r,i="moment",a="";return this.isLocal()||(i=0===this.utcOffset()?"moment.utc":"moment.parseZone",a="Z"),e="["+i+'("]',t=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",n="-MM-DD[T]HH:mm:ss.SSS",r=a+'[")]',this.format(e+t+n+r)}function ti(e){e||(e=this.isUtc()?r.defaultFormatUtc:r.defaultFormat);var t=W(this,e);return this.localeData().postformat(t)}function ni(e,t){return this.isValid()&&(S(e)&&e.isValid()||qn(e).isValid())?Tr({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function ri(e){return this.from(qn(),e)}function ii(e,t){return this.isValid()&&(S(e)&&e.isValid()||qn(e).isValid())?Tr({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function ai(e){return this.to(qn(),e)}function oi(e){var t;return void 0===e?this._locale._abbr:(null!=(t=xn(e))&&(this._locale=t),this)}r.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",r.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var si=A("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",(function(e){return void 0===e?this.localeData():this.locale(e)}));function li(){return this._locale}var ci=1e3,ui=60*ci,di=60*ui,hi=3506328*di;function fi(e,t){return(e%t+t)%t}function pi(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-hi:new Date(e,t,n).valueOf()}function gi(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-hi:Date.UTC(e,t,n)}function mi(e){var t,n;if(void 0===(e=ne(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?gi:pi,e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=fi(t+(this._isUTC?0:this.utcOffset()*ui),di);break;case"minute":t=this._d.valueOf(),t-=fi(t,ui);break;case"second":t=this._d.valueOf(),t-=fi(t,ci)}return this._d.setTime(t),r.updateOffset(this,!0),this}function vi(e){var t,n;if(void 0===(e=ne(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?gi:pi,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=di-fi(t+(this._isUTC?0:this.utcOffset()*ui),di)-1;break;case"minute":t=this._d.valueOf(),t+=ui-fi(t,ui)-1;break;case"second":t=this._d.valueOf(),t+=ci-fi(t,ci)-1}return this._d.setTime(t),r.updateOffset(this,!0),this}function xi(){return this._d.valueOf()-6e4*(this._offset||0)}function bi(){return Math.floor(this.valueOf()/1e3)}function yi(){return new Date(this.valueOf())}function wi(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]}function ki(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}}function Si(){return this.isValid()?this.toISOString():null}function Ci(){return v(this)}function Ai(){return f({},m(this))}function Ei(){return m(this).overflow}function Pi(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}function Ti(e,t){var n,i,a,o=this._eras||xn("en")._eras;for(n=0,i=o.length;n=0)return l[r]}function _i(e,t){var n=e.since<=e.until?1:-1;return void 0===t?r(e.since).year():r(e.since).year()+(t-e.offset)*n}function Li(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e(a=St(e,r,i))&&(t=a),Qi.call(this,e,t,n,r,i))}function Qi(e,t,n,r,i){var a=wt(e,t,n,r,i),o=bt(a.year,0,a.dayOfYear);return this.year(o.getUTCFullYear()),this.month(o.getUTCMonth()),this.date(o.getUTCDate()),this}function Ki(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)}B("N",0,0,"eraAbbr"),B("NN",0,0,"eraAbbr"),B("NNN",0,0,"eraAbbr"),B("NNNN",0,0,"eraName"),B("NNNNN",0,0,"eraNarrow"),B("y",["y",1],"yo","eraYear"),B("y",["yy",2],0,"eraYear"),B("y",["yyy",3],0,"eraYear"),B("y",["yyyy",4],0,"eraYear"),Ee("N",Ni),Ee("NN",Ni),Ee("NNN",Ni),Ee("NNNN",ji),Ee("NNNNN",Bi),Ie(["N","NN","NNN","NNNN","NNNNN"],(function(e,t,n,r){var i=n._locale.erasParse(e,r,n._strict);i?m(n).era=i:m(n).invalidEra=e})),Ee("y",xe),Ee("yy",xe),Ee("yyy",xe),Ee("yyyy",xe),Ee("yo",Yi),Ie(["y","yy","yyy","yyyy"],Fe),Ie(["yo"],(function(e,t,n,r){var i;n._locale._eraYearOrdinalRegex&&(i=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[Fe]=n._locale.eraYearOrdinalParse(e,i):t[Fe]=parseInt(e,10)})),B(0,["gg",2],0,(function(){return this.weekYear()%100})),B(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),Wi("gggg","weekYear"),Wi("ggggg","weekYear"),Wi("GGGG","isoWeekYear"),Wi("GGGGG","isoWeekYear"),Ee("G",be),Ee("g",be),Ee("GG",he,le),Ee("gg",he,le),Ee("GGGG",me,ue),Ee("gggg",me,ue),Ee("GGGGG",ve,de),Ee("ggggg",ve,de),Re(["gggg","ggggg","GGGG","GGGGG"],(function(e,t,n,r){t[r.substr(0,2)]=Le(e)})),Re(["gg","GG"],(function(e,t,n,i){t[i]=r.parseTwoDigitYear(e)})),B("Q",0,"Qo","quarter"),Ee("Q",se),Ie("Q",(function(e,t){t[Ne]=3*(Le(e)-1)})),B("D",["DD",2],"Do","date"),Ee("D",he,Ce),Ee("DD",he,le),Ee("Do",(function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient})),Ie(["D","DD"],je),Ie("Do",(function(e,t){t[je]=Le(e.match(he)[0])}));var Ji=$e("Date",!0);function ea(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")}B("DDD",["DDDD",3],"DDDo","dayOfYear"),Ee("DDD",ge),Ee("DDDD",ce),Ie(["DDD","DDDD"],(function(e,t,n){n._dayOfYear=Le(e)})),B("m",["mm",2],0,"minute"),Ee("m",he,Ae),Ee("mm",he,le),Ie(["m","mm"],Ye);var ta=$e("Minutes",!1);B("s",["ss",2],0,"second"),Ee("s",he,Ae),Ee("ss",he,le),Ie(["s","ss"],He);var na,ra,ia=$e("Seconds",!1);for(B("S",0,0,(function(){return~~(this.millisecond()/100)})),B(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),B(0,["SSS",3],0,"millisecond"),B(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),B(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),B(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),B(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),B(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),B(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),Ee("S",ge,se),Ee("SS",ge,le),Ee("SSS",ge,ce),na="SSSS";na.length<=9;na+="S")Ee(na,xe);function aa(e,t){t[We]=Le(1e3*("0."+e))}for(na="S";na.length<=9;na+="S")Ie(na,aa);function oa(){return this._isUTC?"UTC":""}function sa(){return this._isUTC?"Coordinated Universal Time":""}ra=$e("Milliseconds",!1),B("z",0,0,"zoneAbbr"),B("zz",0,0,"zoneName");var la=k.prototype;function ca(e){return qn(1e3*e)}function ua(){return qn.apply(null,arguments).parseZone()}function da(e){return e}la.add=Rr,la.calendar=Hr,la.clone=Wr,la.diff=$r,la.endOf=vi,la.format=ti,la.from=ni,la.fromNow=ri,la.to=ii,la.toNow=ai,la.get=Je,la.invalidAt=Ei,la.isAfter=Xr,la.isBefore=Vr,la.isBetween=Gr,la.isSame=Ur,la.isSameOrAfter=Zr,la.isSameOrBefore=qr,la.isValid=Ci,la.lang=si,la.locale=oi,la.localeData=li,la.max=Qn,la.min=$n,la.parsingFlags=Ai,la.set=et,la.startOf=mi,la.subtract=zr,la.toArray=wi,la.toObject=ki,la.toDate=yi,la.toISOString=Jr,la.inspect=ei,"undefined"!==typeof Symbol&&null!=Symbol.for&&(la[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),la.toJSON=Si,la.toString=Kr,la.unix=bi,la.valueOf=xi,la.creationData=Pi,la.eraName=Li,la.eraNarrow=Oi,la.eraAbbr=Ii,la.eraYear=Ri,la.year=Ze,la.isLeapYear=qe,la.weekYear=Xi,la.isoWeekYear=Vi,la.quarter=la.quarters=Ki,la.month=ft,la.daysInMonth=pt,la.week=la.weeks=Tt,la.isoWeek=la.isoWeeks=Mt,la.weeksInYear=Zi,la.weeksInWeekYear=qi,la.isoWeeksInYear=Gi,la.isoWeeksInISOWeekYear=Ui,la.date=Ji,la.day=la.days=Xt,la.weekday=Vt,la.isoWeekday=Gt,la.dayOfYear=ea,la.hour=la.hours=rn,la.minute=la.minutes=ta,la.second=la.seconds=ia,la.millisecond=la.milliseconds=ra,la.utcOffset=gr,la.utc=vr,la.local=xr,la.parseZone=br,la.hasAlignedHourOffset=yr,la.isDST=wr,la.isLocal=Sr,la.isUtcOffset=Cr,la.isUtc=Ar,la.isUTC=Ar,la.zoneAbbr=oa,la.zoneName=sa,la.dates=A("dates accessor is deprecated. Use date instead.",Ji),la.months=A("months accessor is deprecated. Use month instead",ft),la.years=A("years accessor is deprecated. Use year instead",Ze),la.zone=A("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",mr),la.isDSTShifted=A("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",kr);var ha=O.prototype;function fa(e,t,n,r){var i=xn(),a=p().set(r,t);return i[n](a,e)}function pa(e,t,n){if(u(e)&&(t=e,e=void 0),e=e||"",null!=t)return fa(e,t,n,"month");var r,i=[];for(r=0;r<12;r++)i[r]=fa(e,r,n,"month");return i}function ga(e,t,n,r){"boolean"===typeof e?(u(t)&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,u(t)&&(n=t,t=void 0),t=t||"");var i,a=xn(),o=e?a._week.dow:0,s=[];if(null!=n)return fa(t,(n+o)%7,r,"day");for(i=0;i<7;i++)s[i]=fa(t,(i+o)%7,r,"day");return s}function ma(e,t){return pa(e,t,"months")}function va(e,t){return pa(e,t,"monthsShort")}function xa(e,t,n){return ga(e,t,n,"weekdays")}function ba(e,t,n){return ga(e,t,n,"weekdaysShort")}function ya(e,t,n){return ga(e,t,n,"weekdaysMin")}ha.calendar=R,ha.longDateFormat=G,ha.invalidDate=Z,ha.ordinal=Q,ha.preparse=da,ha.postformat=da,ha.relativeTime=J,ha.pastFuture=ee,ha.set=_,ha.eras=Ti,ha.erasParse=Mi,ha.erasConvertYear=_i,ha.erasAbbrRegex=Di,ha.erasNameRegex=zi,ha.erasNarrowRegex=Fi,ha.months=lt,ha.monthsShort=ct,ha.monthsParse=dt,ha.monthsRegex=mt,ha.monthsShortRegex=gt,ha.week=Ct,ha.firstDayOfYear=Pt,ha.firstDayOfWeek=Et,ha.weekdays=jt,ha.weekdaysMin=Yt,ha.weekdaysShort=Bt,ha.weekdaysParse=Wt,ha.weekdaysRegex=Ut,ha.weekdaysShortRegex=Zt,ha.weekdaysMinRegex=qt,ha.isPM=tn,ha.meridiem=an,gn("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===Le(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),r.lang=A("moment.lang is deprecated. Use moment.locale instead.",gn),r.langData=A("moment.langData is deprecated. Use moment.localeData instead.",xn);var wa=Math.abs;function ka(){var e=this._data;return this._milliseconds=wa(this._milliseconds),this._days=wa(this._days),this._months=wa(this._months),e.milliseconds=wa(e.milliseconds),e.seconds=wa(e.seconds),e.minutes=wa(e.minutes),e.hours=wa(e.hours),e.months=wa(e.months),e.years=wa(e.years),this}function Sa(e,t,n,r){var i=Tr(t,n);return e._milliseconds+=r*i._milliseconds,e._days+=r*i._days,e._months+=r*i._months,e._bubble()}function Ca(e,t){return Sa(this,e,t,1)}function Aa(e,t){return Sa(this,e,t,-1)}function Ea(e){return e<0?Math.floor(e):Math.ceil(e)}function Pa(){var e,t,n,r,i,a=this._milliseconds,o=this._days,s=this._months,l=this._data;return a>=0&&o>=0&&s>=0||a<=0&&o<=0&&s<=0||(a+=864e5*Ea(Ma(s)+o),o=0,s=0),l.milliseconds=a%1e3,e=_e(a/1e3),l.seconds=e%60,t=_e(e/60),l.minutes=t%60,n=_e(t/60),l.hours=n%24,o+=_e(n/24),s+=i=_e(Ta(o)),o-=Ea(Ma(i)),r=_e(s/12),s%=12,l.days=o,l.months=s,l.years=r,this}function Ta(e){return 4800*e/146097}function Ma(e){return 146097*e/4800}function _a(e){if(!this.isValid())return NaN;var t,n,r=this._milliseconds;if("month"===(e=ne(e))||"quarter"===e||"year"===e)switch(t=this._days+r/864e5,n=this._months+Ta(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(Ma(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw new Error("Unknown unit "+e)}}function La(e){return function(){return this.as(e)}}var Oa=La("ms"),Ia=La("s"),Ra=La("m"),za=La("h"),Da=La("d"),Fa=La("w"),Na=La("M"),ja=La("Q"),Ba=La("y"),Ya=Oa;function Ha(){return Tr(this)}function Wa(e){return e=ne(e),this.isValid()?this[e+"s"]():NaN}function Xa(e){return function(){return this.isValid()?this._data[e]:NaN}}var Va=Xa("milliseconds"),Ga=Xa("seconds"),Ua=Xa("minutes"),Za=Xa("hours"),qa=Xa("days"),$a=Xa("months"),Qa=Xa("years");function Ka(){return _e(this.days()/7)}var Ja=Math.round,eo={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function to(e,t,n,r,i){return i.relativeTime(t||1,!!n,e,r)}function no(e,t,n,r){var i=Tr(e).abs(),a=Ja(i.as("s")),o=Ja(i.as("m")),s=Ja(i.as("h")),l=Ja(i.as("d")),c=Ja(i.as("M")),u=Ja(i.as("w")),d=Ja(i.as("y")),h=a<=n.ss&&["s",a]||a0,h[4]=r,to.apply(null,h)}function ro(e){return void 0===e?Ja:"function"===typeof e&&(Ja=e,!0)}function io(e,t){return void 0!==eo[e]&&(void 0===t?eo[e]:(eo[e]=t,"s"===e&&(eo.ss=t-1),!0))}function ao(e,t){if(!this.isValid())return this.localeData().invalidDate();var n,r,i=!1,a=eo;return"object"===typeof e&&(t=e,e=!1),"boolean"===typeof e&&(i=e),"object"===typeof t&&(a=Object.assign({},eo,t),null!=t.s&&null==t.ss&&(a.ss=t.s-1)),r=no(this,!i,a,n=this.localeData()),i&&(r=n.pastFuture(+this,r)),n.postformat(r)}var oo=Math.abs;function so(e){return(e>0)-(e<0)||+e}function lo(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,r,i,a,o,s,l=oo(this._milliseconds)/1e3,c=oo(this._days),u=oo(this._months),d=this.asSeconds();return d?(e=_e(l/60),t=_e(e/60),l%=60,e%=60,n=_e(u/12),u%=12,r=l?l.toFixed(3).replace(/\.?0+$/,""):"",i=d<0?"-":"",a=so(this._months)!==so(d)?"-":"",o=so(this._days)!==so(d)?"-":"",s=so(this._milliseconds)!==so(d)?"-":"",i+"P"+(n?a+n+"Y":"")+(u?a+u+"M":"")+(c?o+c+"D":"")+(t||e||l?"T":"")+(t?s+t+"H":"")+(e?s+e+"M":"")+(l?s+r+"S":"")):"P0D"}var co=or.prototype;return co.isValid=ir,co.abs=ka,co.add=Ca,co.subtract=Aa,co.as=_a,co.asMilliseconds=Oa,co.asSeconds=Ia,co.asMinutes=Ra,co.asHours=za,co.asDays=Da,co.asWeeks=Fa,co.asMonths=Na,co.asQuarters=ja,co.asYears=Ba,co.valueOf=Ya,co._bubble=Pa,co.clone=Ha,co.get=Wa,co.milliseconds=Va,co.seconds=Ga,co.minutes=Ua,co.hours=Za,co.days=qa,co.weeks=Ka,co.months=$a,co.years=Qa,co.humanize=ao,co.toISOString=lo,co.toString=lo,co.toJSON=lo,co.locale=oi,co.localeData=li,co.toIsoString=A("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",lo),co.lang=si,B("X",0,0,"unix"),B("x",0,0,"valueOf"),Ee("x",be),Ee("X",ke),Ie("X",(function(e,t,n){n._d=new Date(1e3*parseFloat(e))})),Ie("x",(function(e,t,n){n._d=new Date(Le(e))})),r.version="2.30.1",i(qn),r.fn=la,r.min=Jn,r.max=er,r.now=tr,r.utc=p,r.unix=ca,r.months=ma,r.isDate=d,r.locale=gn,r.invalid=x,r.duration=Tr,r.isMoment=S,r.weekdays=xa,r.parseZone=ua,r.localeData=xn,r.isDuration=sr,r.monthsShort=va,r.weekdaysMin=ya,r.defineLocale=mn,r.updateLocale=vn,r.locales=bn,r.weekdaysShort=ba,r.normalizeUnits=ne,r.relativeTimeRounding=ro,r.relativeTimeThreshold=io,r.calendarFormat=Yr,r.prototype=la,r.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},r}()},843:function(e){"use strict";var t=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(i){return!1}}()?Object.assign:function(e,i){for(var a,o,s=function(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),l=1;l