apexcharts 3.50.0 → 3.52.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see apexcharts.amd.js.LICENSE.txt */
2
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.ApexCharts=t():e.ApexCharts=t()}(self,(()=>(()=>{var e={922:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var i="",a=void 0!==t[5];return t[4]&&(i+="@supports (".concat(t[4],") {")),t[2]&&(i+="@media ".concat(t[2]," {")),a&&(i+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),i+=e(t),a&&(i+="}"),t[2]&&(i+="}"),t[4]&&(i+="}"),i})).join("")},t.i=function(e,i,a,r,s){"string"==typeof e&&(e=[[null,e,void 0]]);var n={};if(a)for(var o=0;o<this.length;o++){var l=this[o][0];null!=l&&(n[l]=!0)}for(var c=0;c<e.length;c++){var h=[].concat(e[c]);a&&n[h[0]]||(void 0!==s&&(void 0===h[5]||(h[1]="@layer".concat(h[5].length>0?" ".concat(h[5]):""," {").concat(h[1],"}")),h[5]=s),i&&(h[2]?(h[1]="@media ".concat(h[2]," {").concat(h[1],"}"),h[2]=i):h[2]=i),r&&(h[4]?(h[1]="@supports (".concat(h[4],") {").concat(h[1],"}"),h[4]=r):h[4]="".concat(r)),t.push(h))}},t}},499:e=>{"use strict";e.exports=function(e){return e[1]}},372:function(){function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}(function(){function t(e){e.remember("_draggable",this),this.el=e}t.prototype.init=function(e,t){var i=this;this.constraint=e,this.value=t,this.el.on("mousedown.drag",(function(e){i.start(e)})),this.el.on("touchstart.drag",(function(e){i.start(e)}))},t.prototype.transformPoint=function(e,t){var i=(e=e||window.event).changedTouches&&e.changedTouches[0]||e;return this.p.x=i.clientX-(t||0),this.p.y=i.clientY,this.p.matrixTransform(this.m)},t.prototype.getBBox=function(){var e=this.el.bbox();return this.el instanceof SVG.Nested&&(e=this.el.rbox()),(this.el instanceof SVG.G||this.el instanceof SVG.Use||this.el instanceof SVG.Nested)&&(e.x=this.el.x(),e.y=this.el.y()),e},t.prototype.start=function(e){if("click"!=e.type&&"mousedown"!=e.type&&"mousemove"!=e.type||1==(e.which||e.buttons)){var t=this;if(this.el.fire("beforedrag",{event:e,handler:this}),!this.el.event().defaultPrevented){e.preventDefault(),e.stopPropagation(),this.parent=this.parent||this.el.parent(SVG.Nested)||this.el.parent(SVG.Doc),this.p=this.parent.node.createSVGPoint(),this.m=this.el.node.getScreenCTM().inverse();var i,a=this.getBBox();if(this.el instanceof SVG.Text)switch(i=this.el.node.getComputedTextLength(),this.el.attr("text-anchor")){case"middle":i/=2;break;case"start":i=0}this.startPoints={point:this.transformPoint(e,i),box:a,transform:this.el.transform()},SVG.on(window,"mousemove.drag",(function(e){t.drag(e)})),SVG.on(window,"touchmove.drag",(function(e){t.drag(e)})),SVG.on(window,"mouseup.drag",(function(e){t.end(e)})),SVG.on(window,"touchend.drag",(function(e){t.end(e)})),this.el.fire("dragstart",{event:e,p:this.startPoints.point,m:this.m,handler:this})}}},t.prototype.drag=function(t){var i=this.getBBox(),a=this.transformPoint(t),r=this.startPoints.box.x+a.x-this.startPoints.point.x,s=this.startPoints.box.y+a.y-this.startPoints.point.y,n=this.constraint,o=a.x-this.startPoints.point.x,l=a.y-this.startPoints.point.y;if(this.el.fire("dragmove",{event:t,p:a,m:this.m,handler:this}),this.el.event().defaultPrevented)return a;if("function"==typeof n){var c=n.call(this.el,r,s,this.m);"boolean"==typeof c&&(c={x:c,y:c}),!0===c.x?this.el.x(r):!1!==c.x&&this.el.x(c.x),!0===c.y?this.el.y(s):!1!==c.y&&this.el.y(c.y)}else"object"==e(n)&&(null!=n.minX&&r<n.minX?o=(r=n.minX)-this.startPoints.box.x:null!=n.maxX&&r>n.maxX-i.width&&(o=(r=n.maxX-i.width)-this.startPoints.box.x),null!=n.minY&&s<n.minY?l=(s=n.minY)-this.startPoints.box.y:null!=n.maxY&&s>n.maxY-i.height&&(l=(s=n.maxY-i.height)-this.startPoints.box.y),null!=n.snapToGrid&&(r-=r%n.snapToGrid,s-=s%n.snapToGrid,o-=o%n.snapToGrid,l-=l%n.snapToGrid),this.el instanceof SVG.G?this.el.matrix(this.startPoints.transform).transform({x:o,y:l},!0):this.el.move(r,s));return a},t.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(i,a){"function"!=typeof i&&"object"!=e(i)||(a=i,i=!0);var r=this.remember("_draggable")||new t(this);return(i=void 0===i||i)?r.init(a||{},i):(this.off("mousedown.drag"),this.off("touchstart.drag")),this}})}).call(this)},872:function(){(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,i){return this.put(new SVG.BlendEffect(e,t,i))},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,i){return this.put(new SVG.CompositeEffect(e,t,i))},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,i){return this.put(new SVG.DiffuseLightingEffect(e,t,i))},displacementMap:function(e,t,i,a,r){return this.put(new SVG.DisplacementMapEffect(e,t,i,a,r))},specularLighting:function(e,t,i,a){return this.put(new SVG.SpecularLightingEffect(e,t,i,a))},tile:function(){return this.put(new SVG.TileEffect)},turbulence:function(e,t,i,a,r){return this.put(new SVG.TurbulenceEffect(e,t,i,a,r))},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,i){return this.parent()&&this.parent().diffuseLighting(e,t,i).in(this)},displacementMap:function(e,t,i,a){return this.parent()&&this.parent().displacementMap(this,e,t,i,a)},specularLighting:function(e,t,i,a){return this.parent()&&this.parent().specularLighting(e,t,i,a).in(this)},tile:function(){return this.parent()&&this.parent().tile().in(this)},turbulence:function(e,t,i,a,r){return this.parent()&&this.parent().turbulence(e,t,i,a,r).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,i){this.attr({in:e,in2:t,mode:i||"normal"})},colorMatrix:function(e,t){"matrix"==e&&(t=r(t)),this.attr({type:e,values:void 0===t?null:t})},convolveMatrix:function(e){e=r(e),this.attr({order:Math.sqrt(e.split(" ").length),kernelMatrix:e})},composite:function(e,t,i){this.attr({in:e,in2:t,operator:i})},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,i,a,r){this.attr({in:e,in2:t,scale:i,xChannelSelector:a,yChannelSelector:r})},gaussianBlur:function(e,t){null!=e||null!=t?this.attr("stdDeviation",function(e){if(!Array.isArray(e))return e;for(var t=0,i=e.length,a=[];t<i;t++)a.push(e[t]);return a.join(" ")}(Array.prototype.slice.call(arguments))):this.attr("stdDeviation","0 0")},morphology:function(e,t){this.attr({operator:e,radius:t})},tile:function(){},turbulence:function(e,t,i,a,r){this.attr({numOctaves:t,seed:i,stitchTiles:a,baseFrequency:e,type:r})}},i={merge:function(){var e;if(arguments[0]instanceof SVG.Set){var t=this;arguments[0].each((function(e){this instanceof SVG.MergeNode?t.put(this):(this instanceof SVG.Effect||this instanceof SVG.ParentEffect)&&t.put(new SVG.MergeNode(this))}))}else{e=Array.isArray(arguments[0])?arguments[0]:arguments;for(var i=0;i<e.length;i++)e[i]instanceof SVG.MergeNode?this.put(e[i]):this.put(new SVG.MergeNode(e[i]))}},componentTransfer:function(e){if(this.rgb=new SVG.Set,["r","g","b","a"].forEach(function(e){this[e]=new(SVG["Func"+e.toUpperCase()])("identity"),this.rgb.add(this[e]),this.node.appendChild(this[e].node)}.bind(this)),e)for(var t in e.rgb&&(["r","g","b"].forEach(function(t){this[t].attr(e.rgb)}.bind(this)),delete e.rgb),e)this[t].attr(e[t])},diffuseLighting:function(e,t,i){this.attr({surfaceScale:e,diffuseConstant:t,kernelUnitLength:i})},specularLighting:function(e,t,i,a){this.attr({surfaceScale:e,diffuseConstant:t,specularExponent:i,kernelUnitLength:a})}},a={distantLight:function(e,t){this.attr({azimuth:e,elevation:t})},pointLight:function(e,t,i){this.attr({x:e,y:t,z:i})},spotLight:function(e,t,i,a,r,s){this.attr({x:e,y:t,z:i,pointsAtX:a,pointsAtY:r,pointsAtZ:s})},mergeNode:function(e){this.attr("in",e)}};function r(e){return Array.isArray(e)&&(e=new SVG.Array(e)),e.toString().replace(/^\s+/,"").replace(/\s+$/,"").replace(/\s+/g," ")}function s(){var e=function(){};for(var t in"function"==typeof arguments[arguments.length-1]&&(e=arguments[arguments.length-1],Array.prototype.splice.call(arguments,arguments.length-1,1)),arguments)for(var i in arguments[t])e(arguments[t][i],i,arguments[t])}["r","g","b","a"].forEach((function(e){a["Func"+e.toUpperCase()]=function(e){switch(this.attr("type",e),e){case"table":this.attr("tableValues",arguments[1]);break;case"linear":this.attr("slope",arguments[1]),this.attr("intercept",arguments[2]);break;case"gamma":this.attr("amplitude",arguments[1]),this.attr("exponent",arguments[2]),this.attr("offset",arguments[2])}}})),s(t,(function(e,t){var i=t.charAt(0).toUpperCase()+t.slice(1);SVG[i+"Effect"]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),e.apply(this,arguments),this.result(this.attr("id")+"Out")},inherit:SVG.Effect,extend:{}})})),s(i,(function(e,t){var i=t.charAt(0).toUpperCase()+t.slice(1);SVG[i+"Effect"]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),e.apply(this,arguments),this.result(this.attr("id")+"Out")},inherit:SVG.ParentEffect,extend:{}})})),s(a,(function(e,t){var i=t.charAt(0).toUpperCase()+t.slice(1);SVG[i]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),e.apply(this,arguments)},inherit:SVG.ChildEffect,extend:{}})})),SVG.extend(SVG.MergeEffect,{in:function(e){return e instanceof SVG.MergeNode?this.add(e,0):this.add(new SVG.MergeNode(e),0),this}}),SVG.extend(SVG.CompositeEffect,SVG.BlendEffect,SVG.DisplacementMapEffect,{in2:function(e){return null==e?this.parent()&&this.parent().select('[result="'+this.attr("in2")+'"]').get(0)||this.attr("in2"):this.attr("in2",e)}}),SVG.filter={sepiatone:[.343,.669,.119,0,0,.249,.626,.13,0,0,.172,.334,.111,0,0,0,0,0,1,0]}}).call(this)},25:()=>{!function(){"use strict";function e(e,r,s,n,o,l,c){for(var h=e.slice(r,s||c),d=n.slice(o,l||c),u=0,g={pos:[0,0],start:[0,0]},f={pos:[0,0],start:[0,0]};h[u]=t.call(g,h[u]),d[u]=t.call(f,d[u]),h[u][0]!=d[u][0]||"M"==h[u][0]||"A"==h[u][0]&&(h[u][4]!=d[u][4]||h[u][5]!=d[u][5])?(Array.prototype.splice.apply(h,[u,1].concat(a.call(g,h[u]))),Array.prototype.splice.apply(d,[u,1].concat(a.call(f,d[u])))):(h[u]=i.call(g,h[u]),d[u]=i.call(f,d[u])),++u!=h.length||u!=d.length;)u==h.length&&h.push(["C",g.pos[0],g.pos[1],g.pos[0],g.pos[1],g.pos[0],g.pos[1]]),u==d.length&&d.push(["C",f.pos[0],f.pos[1],f.pos[0],f.pos[1],f.pos[0],f.pos[1]]);return{start:h,dest:d}}function t(e){switch(e[0]){case"z":case"Z":e[0]="L",e[1]=this.start[0],e[2]=this.start[1];break;case"H":e[0]="L",e[2]=this.pos[1];break;case"V":e[0]="L",e[2]=e[1],e[1]=this.pos[0];break;case"T":e[0]="Q",e[3]=e[1],e[4]=e[2],e[1]=this.reflection[1],e[2]=this.reflection[0];break;case"S":e[0]="C",e[6]=e[4],e[5]=e[3],e[4]=e[2],e[3]=e[1],e[2]=this.reflection[1],e[1]=this.reflection[0]}return e}function i(e){var t=e.length;return this.pos=[e[t-2],e[t-1]],-1!="SCQT".indexOf(e[0])&&(this.reflection=[2*this.pos[0]-e[t-4],2*this.pos[1]-e[t-3]]),e}function a(e){var t=[e];switch(e[0]){case"M":return this.pos=this.start=[e[1],e[2]],t;case"L":e[5]=e[3]=e[1],e[6]=e[4]=e[2],e[1]=this.pos[0],e[2]=this.pos[1];break;case"Q":e[6]=e[4],e[5]=e[3],e[4]=1*e[4]/3+2*e[2]/3,e[3]=1*e[3]/3+2*e[1]/3,e[2]=1*this.pos[1]/3+2*e[2]/3,e[1]=1*this.pos[0]/3+2*e[1]/3;break;case"A":t=function(e,t){var i,a,r,s,n,o,l,c,h,d,u,g,f,p,x,b,v,m,y,w,k,A,S,C,P,L,O=Math.abs(t[1]),M=Math.abs(t[2]),T=t[3]%360,I=t[4],E=t[5],z=t[6],X=t[7],Y=new SVG.Point(e),R=new SVG.Point(z,X),D=[];if(0===O||0===M||Y.x===R.x&&Y.y===R.y)return[["C",Y.x,Y.y,R.x,R.y,R.x,R.y]];for((a=(i=new SVG.Point((Y.x-R.x)/2,(Y.y-R.y)/2).transform((new SVG.Matrix).rotate(T))).x*i.x/(O*O)+i.y*i.y/(M*M))>1&&(O*=a=Math.sqrt(a),M*=a),r=(new SVG.Matrix).rotate(T).scale(1/O,1/M).rotate(-T),Y=Y.transform(r),o=(s=[(R=R.transform(r)).x-Y.x,R.y-Y.y])[0]*s[0]+s[1]*s[1],n=Math.sqrt(o),s[0]/=n,s[1]/=n,l=o<4?Math.sqrt(1-o/4):0,I===E&&(l*=-1),c=new SVG.Point((R.x+Y.x)/2+l*-s[1],(R.y+Y.y)/2+l*s[0]),h=new SVG.Point(Y.x-c.x,Y.y-c.y),d=new SVG.Point(R.x-c.x,R.y-c.y),u=Math.acos(h.x/Math.sqrt(h.x*h.x+h.y*h.y)),h.y<0&&(u*=-1),g=Math.acos(d.x/Math.sqrt(d.x*d.x+d.y*d.y)),d.y<0&&(g*=-1),E&&u>g&&(g+=2*Math.PI),!E&&u<g&&(g-=2*Math.PI),b=[],v=u,f=(g-u)/(p=Math.ceil(2*Math.abs(u-g)/Math.PI)),x=4*Math.tan(f/4)/3,k=0;k<=p;k++)y=Math.cos(v),m=Math.sin(v),w=new SVG.Point(c.x+y,c.y+m),b[k]=[new SVG.Point(w.x+x*m,w.y-x*y),w,new SVG.Point(w.x-x*m,w.y+x*y)],v+=f;for(b[0][0]=b[0][1].clone(),b[b.length-1][2]=b[b.length-1][1].clone(),r=(new SVG.Matrix).rotate(T).scale(O,M).rotate(-T),k=0,A=b.length;k<A;k++)b[k][0]=b[k][0].transform(r),b[k][1]=b[k][1].transform(r),b[k][2]=b[k][2].transform(r);for(k=1,A=b.length;k<A;k++)S=(w=b[k-1][2]).x,C=w.y,P=(w=b[k][0]).x,L=w.y,z=(w=b[k][1]).x,X=w.y,D.push(["C",S,C,P,L,z,X]);return D}(this.pos,e),e=t[0]}return e[0]="C",this.pos=[e[5],e[6]],this.reflection=[2*e[5]-e[3],2*e[6]-e[4]],t}function r(e,t){if(!1===t)return!1;for(var i=t,a=e.length;i<a;++i)if("M"==e[i][0])return i;return!1}SVG.extend(SVG.PathArray,{morph:function(t){for(var i=this.value,a=this.parse(t),s=0,n=0,o=!1,l=!1;!1!==s||!1!==n;){var c;o=r(i,!1!==s&&s+1),l=r(a,!1!==n&&n+1),!1===s&&(s=0==(c=new SVG.PathArray(h.start).bbox()).height||0==c.width?i.push(i[0])-1:i.push(["M",c.x+c.width/2,c.y+c.height/2])-1),!1===n&&(n=0==(c=new SVG.PathArray(h.dest).bbox()).height||0==c.width?a.push(a[0])-1:a.push(["M",c.x+c.width/2,c.y+c.height/2])-1);var h=e(i,s,o,a,n,l);i=i.slice(0,s).concat(h.start,!1===o?[]:i.slice(o)),a=a.slice(0,n).concat(h.dest,!1===l?[]:a.slice(l)),s=!1!==o&&s+h.start.length,n=!1!==l&&n+h.dest.length}return this.value=i,this.destination=new SVG.PathArray,this.destination.value=a,this}})}()},882:()=>{!function(){"use strict";(function(){function e(e){e.remember("_resizeHandler",this),this.el=e,this.parameters={},this.lastUpdateCall=null,this.p=e.doc().node.createSVGPoint()}e.prototype.transformPoint=function(e,t,i){return this.p.x=e-(this.offset.x-window.pageXOffset),this.p.y=t-(this.offset.y-window.pageYOffset),this.p.matrixTransform(i||this.m)},e.prototype._extractPosition=function(e){return{x:null!=e.clientX?e.clientX:e.touches[0].clientX,y:null!=e.clientY?e.clientY:e.touches[0].clientY}},e.prototype.init=function(e){var t=this;if(this.stop(),"stop"!==e){for(var i in this.options={},this.el.resize.defaults)this.options[i]=this.el.resize.defaults[i],void 0!==e[i]&&(this.options[i]=e[i]);this.el.on("lt.resize",(function(e){t.resize(e||window.event)})),this.el.on("rt.resize",(function(e){t.resize(e||window.event)})),this.el.on("rb.resize",(function(e){t.resize(e||window.event)})),this.el.on("lb.resize",(function(e){t.resize(e||window.event)})),this.el.on("t.resize",(function(e){t.resize(e||window.event)})),this.el.on("r.resize",(function(e){t.resize(e||window.event)})),this.el.on("b.resize",(function(e){t.resize(e||window.event)})),this.el.on("l.resize",(function(e){t.resize(e||window.event)})),this.el.on("rot.resize",(function(e){t.resize(e||window.event)})),this.el.on("point.resize",(function(e){t.resize(e||window.event)})),this.update()}},e.prototype.stop=function(){return this.el.off("lt.resize"),this.el.off("rt.resize"),this.el.off("rb.resize"),this.el.off("lb.resize"),this.el.off("t.resize"),this.el.off("r.resize"),this.el.off("b.resize"),this.el.off("l.resize"),this.el.off("rot.resize"),this.el.off("point.resize"),this},e.prototype.resize=function(e){var t=this;this.m=this.el.node.getScreenCTM().inverse(),this.offset={x:window.pageXOffset,y:window.pageYOffset};var i=this._extractPosition(e.detail.event);if(this.parameters={type:this.el.type,p:this.transformPoint(i.x,i.y),x:e.detail.x,y:e.detail.y,box:this.el.bbox(),rotation:this.el.transform().rotation},"text"===this.el.type&&(this.parameters.fontSize=this.el.attr()["font-size"]),void 0!==e.detail.i){var a=this.el.array().valueOf();this.parameters.i=e.detail.i,this.parameters.pointCoords=[a[e.detail.i][0],a[e.detail.i][1]]}switch(e.type){case"lt":this.calc=function(e,t){var i=this.snapToGrid(e,t);if(this.parameters.box.width-i[0]>0&&this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-i[0]);i=this.checkAspectRatio(i),this.el.move(this.parameters.box.x+i[0],this.parameters.box.y+i[1]).size(this.parameters.box.width-i[0],this.parameters.box.height-i[1])}};break;case"rt":this.calc=function(e,t){var i=this.snapToGrid(e,t,2);if(this.parameters.box.width+i[0]>0&&this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+i[0]);i=this.checkAspectRatio(i,!0),this.el.move(this.parameters.box.x,this.parameters.box.y+i[1]).size(this.parameters.box.width+i[0],this.parameters.box.height-i[1])}};break;case"rb":this.calc=function(e,t){var i=this.snapToGrid(e,t,0);if(this.parameters.box.width+i[0]>0&&this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+i[0]);i=this.checkAspectRatio(i),this.el.move(this.parameters.box.x,this.parameters.box.y).size(this.parameters.box.width+i[0],this.parameters.box.height+i[1])}};break;case"lb":this.calc=function(e,t){var i=this.snapToGrid(e,t,1);if(this.parameters.box.width-i[0]>0&&this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-i[0]);i=this.checkAspectRatio(i,!0),this.el.move(this.parameters.box.x+i[0],this.parameters.box.y).size(this.parameters.box.width-i[0],this.parameters.box.height+i[1])}};break;case"t":this.calc=function(e,t){var i=this.snapToGrid(e,t,2);if(this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y+i[1]).height(this.parameters.box.height-i[1])}};break;case"r":this.calc=function(e,t){var i=this.snapToGrid(e,t,0);if(this.parameters.box.width+i[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).width(this.parameters.box.width+i[0])}};break;case"b":this.calc=function(e,t){var i=this.snapToGrid(e,t,0);if(this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).height(this.parameters.box.height+i[1])}};break;case"l":this.calc=function(e,t){var i=this.snapToGrid(e,t,1);if(this.parameters.box.width-i[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x+i[0],this.parameters.box.y).width(this.parameters.box.width-i[0])}};break;case"rot":this.calc=function(e,t){var i=e+this.parameters.p.x,a=t+this.parameters.p.y,r=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),s=Math.atan2(a-this.parameters.box.y-this.parameters.box.height/2,i-this.parameters.box.x-this.parameters.box.width/2),n=this.parameters.rotation+180*(s-r)/Math.PI+this.options.snapToAngle/2;this.el.center(this.parameters.box.cx,this.parameters.box.cy).rotate(n-n%this.options.snapToAngle,this.parameters.box.cx,this.parameters.box.cy)};break;case"point":this.calc=function(e,t){var i=this.snapToGrid(e,t,this.parameters.pointCoords[0],this.parameters.pointCoords[1]),a=this.el.array().valueOf();a[this.parameters.i][0]=this.parameters.pointCoords[0]+i[0],a[this.parameters.i][1]=this.parameters.pointCoords[1]+i[1],this.el.plot(a)}}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),i=this.transformPoint(t.x,t.y),a=i.x-this.parameters.p.x,r=i.y-this.parameters.p.y;this.lastUpdateCall=[a,r],this.calc(a,r),this.el.fire("resizing",{dx:a,dy:r,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,i,a){var r;return void 0!==a?r=[(i+e)%this.options.snapToGrid,(a+t)%this.options.snapToGrid]:(i=null==i?3:i,r=[(this.parameters.box.x+e+(1&i?0:this.parameters.box.width))%this.options.snapToGrid,(this.parameters.box.y+t+(2&i?0:this.parameters.box.height))%this.options.snapToGrid]),e<0&&(r[0]-=this.options.snapToGrid),t<0&&(r[1]-=this.options.snapToGrid),e-=Math.abs(r[0])<this.options.snapToGrid/2?r[0]:r[0]-(e<0?-this.options.snapToGrid:this.options.snapToGrid),t-=Math.abs(r[1])<this.options.snapToGrid/2?r[1]:r[1]-(t<0?-this.options.snapToGrid:this.options.snapToGrid),this.constraintToBox(e,t,i,a)},e.prototype.constraintToBox=function(e,t,i,a){var r,s,n=this.options.constraint||{};return void 0!==a?(r=i,s=a):(r=this.parameters.box.x+(1&i?0:this.parameters.box.width),s=this.parameters.box.y+(2&i?0:this.parameters.box.height)),void 0!==n.minX&&r+e<n.minX&&(e=n.minX-r),void 0!==n.maxX&&r+e>n.maxX&&(e=n.maxX-r),void 0!==n.minY&&s+t<n.minY&&(t=n.minY-s),void 0!==n.maxY&&s+t>n.maxY&&(t=n.maxY-s),[e,t]},e.prototype.checkAspectRatio=function(e,t){if(!this.options.saveAspectRatio)return e;var i=e.slice(),a=this.parameters.box.width/this.parameters.box.height,r=this.parameters.box.width+e[0],s=this.parameters.box.height-e[1],n=r/s;return n<a?(i[1]=r/a-this.parameters.box.height,t&&(i[1]=-i[1])):n>a&&(i[0]=this.parameters.box.width-s*a,t&&(i[0]=-i[0])),i},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)}()},769:()=>{function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}!function(){"use strict";function t(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,i){var a="string"!=typeof e?e:t[e];return i?a/2:a},this.pointCoords=function(e,t){var i=this.pointsList[e];return{x:this.pointCoord(i[0],t,"t"===e||"b"===e),y:this.pointCoord(i[1],t,"r"===e||"l"===e)}}}t.prototype.init=function(e,t){var i=this.el.bbox();this.options={};var a=this.el.selectize.defaults.points;for(var r in this.el.selectize.defaults)this.options[r]=this.el.selectize.defaults[r],void 0!==t[r]&&(this.options[r]=t[r]);var s=["points","pointsExclude"];for(var r in s){var n=this.options[s[r]];"string"==typeof n?n=n.length>0?n.split(/\s*,\s*/i):[]:"boolean"==typeof n&&"points"===s[r]&&(n=n?a:[]),this.options[s[r]]=n}this.options.points=[a,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(i.x,i.y)),this.options.deepSelect&&-1!==["line","polyline","polygon"].indexOf(this.el.type)?this.selectPoints(e):this.selectRect(e),this.observe(),this.cleanup()},t.prototype.selectPoints=function(e){return this.pointSelection.isSelected=e,this.pointSelection.set||(this.pointSelection.set=this.parent.set(),this.drawPoints()),this},t.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]}))},t.prototype.drawPoints=function(){for(var e=this,t=this.getPointArray(),i=0,a=t.length;i<a;++i){var r=function(t){return function(i){(i=i||window.event).preventDefault?i.preventDefault():i.returnValue=!1,i.stopPropagation();var a=i.pageX||i.touches[0].pageX,r=i.pageY||i.touches[0].pageY;e.el.fire("point",{x:a,y:r,i:t,event:i})}}(i),s=this.drawPoint(t[i][0],t[i][1]).addClass(this.options.classPoints).addClass(this.options.classPoints+"_point").on("touchstart",r).on("mousedown",r);this.pointSelection.set.add(s)}},t.prototype.drawPoint=function(e,t){var i=this.options.pointType;switch(i){case"circle":return this.drawCircle(e,t);case"rect":return this.drawRect(e,t);default:if("function"==typeof i)return i.call(this,e,t);throw new Error("Unknown "+i+" point type!")}},t.prototype.drawCircle=function(e,t){return this.nested.circle(this.options.pointSize).center(e,t)},t.prototype.drawRect=function(e,t){return this.nested.rect(this.options.pointSize,this.options.pointSize).center(e,t)},t.prototype.updatePointSelection=function(){var e=this.getPointArray();this.pointSelection.set.each((function(t){this.cx()===e[t][0]&&this.cy()===e[t][1]||this.center(e[t][0],e[t][1])}))},t.prototype.updateRectSelection=function(){var e=this,t=this.el.bbox();if(this.rectSelection.set.get(0).attr({width:t.width,height:t.height}),this.options.points.length&&this.options.points.map((function(i,a){var r=e.pointCoords(i,t);e.rectSelection.set.get(a+1).center(r.x,r.y)})),this.options.rotationPoint){var i=this.rectSelection.set.length();this.rectSelection.set.get(i-1).center(t.width/2,20)}},t.prototype.selectRect=function(e){var t=this,i=this.el.bbox();function a(e){return function(i){(i=i||window.event).preventDefault?i.preventDefault():i.returnValue=!1,i.stopPropagation();var a=i.pageX||i.touches[0].pageX,r=i.pageY||i.touches[0].pageY;t.el.fire(e,{x:a,y:r,event:i})}}if(this.rectSelection.isSelected=e,this.rectSelection.set=this.rectSelection.set||this.parent.set(),this.rectSelection.set.get(0)||this.rectSelection.set.add(this.nested.rect(i.width,i.height).addClass(this.options.classRect)),this.options.points.length&&this.rectSelection.set.length()<2&&(this.options.points.map((function(e,r){var s=t.pointCoords(e,i),n=t.drawPoint(s.x,s.y).attr("class",t.options.classPoints+"_"+e).on("mousedown",a(e)).on("touchstart",a(e));t.rectSelection.set.add(n)})),this.rectSelection.set.each((function(){this.addClass(t.options.classPoints)}))),this.options.rotationPoint&&(this.options.points&&!this.rectSelection.set.get(9)||!this.options.points&&!this.rectSelection.set.get(1))){var r=function(e){(e=e||window.event).preventDefault?e.preventDefault():e.returnValue=!1,e.stopPropagation();var i=e.pageX||e.touches[0].pageX,a=e.pageY||e.touches[0].pageY;t.el.fire("rot",{x:i,y:a,event:e})},s=this.drawPoint(i.width/2,20).attr("class",this.options.classPoints+"_rot").on("touchstart",r).on("mousedown",r);this.rectSelection.set.add(s)}},t.prototype.handler=function(){var e=this.el.bbox();this.nested.matrix(new SVG.Matrix(this.el).translate(e.x,e.y)),this.rectSelection.isSelected&&this.updateRectSelection(),this.pointSelection.isSelected&&this.updatePointSelection()},t.prototype.observe=function(){var e=this;if(MutationObserver)if(this.rectSelection.isSelected||this.pointSelection.isSelected)this.observerInst=this.observerInst||new MutationObserver((function(){e.handler()})),this.observerInst.observe(this.el.node,{attributes:!0});else try{this.observerInst.disconnect(),delete this.observerInst}catch(e){}else this.el.off("DOMAttrModified.select"),(this.rectSelection.isSelected||this.pointSelection.isSelected)&&this.el.on("DOMAttrModified.select",(function(){e.handler()}))},t.prototype.cleanup=function(){!this.rectSelection.isSelected&&this.rectSelection.set&&(this.rectSelection.set.each((function(){this.remove()})),this.rectSelection.set.clear(),delete this.rectSelection.set),!this.pointSelection.isSelected&&this.pointSelection.set&&(this.pointSelection.set.each((function(){this.remove()})),this.pointSelection.set.clear(),delete this.pointSelection.set),this.pointSelection.isSelected||this.rectSelection.isSelected||(this.nested.remove(),delete this.nested)},SVG.extend(SVG.Element,{selectize:function(i,a){return"object"===e(i)&&(a=i,i=!0),(this.remember("_selectHandler")||new t(this)).init(void 0===i||i,a||{}),this}}),SVG.Element.prototype.selectize.defaults={points:["lt","rt","rb","lb","t","r","b","l"],pointsExclude:[],classRect:"svg_select_boundingRect",classPoints:"svg_select_points",pointSize:7,rotationPoint:!0,deepSelect:!1,pointType:"circle"}}()},600:()=>{window.TreemapSquared={},function(){"use strict";window.TreemapSquared.generate=function(){function e(t,i,a,r){this.xoffset=t,this.yoffset=i,this.height=r,this.width=a,this.shortestEdge=function(){return Math.min(this.height,this.width)},this.getCoordinates=function(e){var t,i=[],a=this.xoffset,r=this.yoffset,n=s(e)/this.height,o=s(e)/this.width;if(this.width>=this.height)for(t=0;t<e.length;t++)i.push([a,r,a+n,r+e[t]/n]),r+=e[t]/n;else for(t=0;t<e.length;t++)i.push([a,r,a+e[t]/o,r+o]),a+=e[t]/o;return i},this.cutArea=function(t){var i;if(this.width>=this.height){var a=t/this.height,r=this.width-a;i=new e(this.xoffset+a,this.yoffset,r,this.height)}else{var s=t/this.width,n=this.height-s;i=new e(this.xoffset,this.yoffset+s,this.width,n)}return i}}function t(t,a,r,n,o){n=void 0===n?0:n,o=void 0===o?0:o;var l=i(function(e,t){var i,a=[],r=t/s(e);for(i=0;i<e.length;i++)a[i]=e[i]*r;return a}(t,a*r),[],new e(n,o,a,r),[]);return function(e){var t,i,a=[];for(t=0;t<e.length;t++)for(i=0;i<e[t].length;i++)a.push(e[t][i]);return a}(l)}function i(e,t,r,n){var o,l,c;if(0!==e.length)return o=r.shortestEdge(),function(e,t,i){var r;return 0===e.length||((r=e.slice()).push(t),a(e,i)>=a(r,i))}(t,l=e[0],o)?(t.push(l),i(e.slice(1),t,r,n)):(c=r.cutArea(s(t),n),n.push(r.getCoordinates(t)),i(e,[],c,n)),n;n.push(r.getCoordinates(t))}function a(e,t){var i=Math.min.apply(Math,e),a=Math.max.apply(Math,e),r=s(e);return Math.max(Math.pow(t,2)*a/Math.pow(r,2),Math.pow(r,2)/(Math.pow(t,2)*i))}function r(e){return e&&e.constructor===Array}function s(e){var t,i=0;for(t=0;t<e.length;t++)i+=e[t];return i}function n(e){var t,i=0;if(r(e[0]))for(t=0;t<e.length;t++)i+=n(e[t]);else i=s(e);return i}return function e(i,a,s,o,l){o=void 0===o?0:o,l=void 0===l?0:l;var c,h,d=[],u=[];if(r(i[0])){for(h=0;h<i.length;h++)d[h]=n(i[h]);for(c=t(d,a,s,o,l),h=0;h<i.length;h++)u.push(e(i[h],c[h][2]-c[h][0],c[h][3]-c[h][1],c[h][0],c[h][1]))}else u=t(i,a,s,o,l);return u}}()}()},482:function(e,t,i){var a,r;function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}r="undefined"!=typeof window?window:this,a=function(){return function(e,t){var i=(void 0!==this?this:e).SVG=function(e){if(i.supported)return e=new i.Doc(e),i.parser.draw||i.prepare(),e};if(i.ns="http://www.w3.org/2000/svg",i.xmlns="http://www.w3.org/2000/xmlns/",i.xlink="http://www.w3.org/1999/xlink",i.svgjs="http://svgjs.dev",i.supported=!0,!i.supported)return!1;i.did=1e3,i.eid=function(e){return"Svgjs"+d(e)+i.did++},i.create=function(e){var i=t.createElementNS(this.ns,e);return i.setAttribute("id",this.eid(e)),i},i.extend=function(){var e,t;t=(e=[].slice.call(arguments)).pop();for(var a=e.length-1;a>=0;a--)if(e[a])for(var r in t)e[a].prototype[r]=t[r];i.Set&&i.Set.inherit&&i.Set.inherit()},i.invent=function(e){var t="function"==typeof e.create?e.create:function(){this.constructor.call(this,i.create(e.create))};return e.inherit&&(t.prototype=new e.inherit),e.extend&&i.extend(t,e.extend),e.construct&&i.extend(e.parent||i.Container,e.construct),t},i.adopt=function(t){return t?t.instance?t.instance:((a="svg"==t.nodeName?t.parentNode instanceof e.SVGElement?new i.Nested:new i.Doc:"linearGradient"==t.nodeName?new i.Gradient("linear"):"radialGradient"==t.nodeName?new i.Gradient("radial"):i[d(t.nodeName)]?new(i[d(t.nodeName)]):new i.Element(t)).type=t.nodeName,a.node=t,t.instance=a,a instanceof i.Doc&&a.namespace().defs(),a.setData(JSON.parse(t.getAttribute("svgjs:data"))||{}),a):null;var a},i.prepare=function(){var e=t.getElementsByTagName("body")[0],a=(e?new i.Doc(e):i.adopt(t.documentElement).nested()).size(2,0);i.parser={body:e||t.documentElement,draw:a.style("opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden").node,poly:a.polyline().node,path:a.path().node,native:i.create("svg")}},i.parser={native:i.create("svg")},t.addEventListener("DOMContentLoaded",(function(){i.parser.draw||i.prepare()}),!1),i.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},i.utils={map:function(e,t){for(var i=e.length,a=[],r=0;r<i;r++)a.push(t(e[r]));return a},filter:function(e,t){for(var i=e.length,a=[],r=0;r<i;r++)t(e[r])&&a.push(e[r]);return a},filterSVGElements:function(t){return this.filter(t,(function(t){return t instanceof e.SVGElement}))}},i.defaults={attrs:{"fill-opacity":1,"stroke-opacity":1,"stroke-width":0,"stroke-linejoin":"miter","stroke-linecap":"butt",fill:"#000000",stroke:"#000000",opacity:1,x:0,y:0,cx:0,cy:0,width:0,height:0,r:0,rx:0,ry:0,offset:0,"stop-opacity":1,"stop-color":"#000000","font-size":16,"font-family":"Helvetica, Arial, sans-serif","text-anchor":"start"}},i.Color=function(e){var t,a;this.r=0,this.g=0,this.b=0,e&&("string"==typeof e?i.regex.isRgb.test(e)?(t=i.regex.rgb.exec(e.replace(i.regex.whitespace,"")),this.r=parseInt(t[1]),this.g=parseInt(t[2]),this.b=parseInt(t[3])):i.regex.isHex.test(e)&&(t=i.regex.hex.exec(4==(a=e).length?["#",a.substring(1,2),a.substring(1,2),a.substring(2,3),a.substring(2,3),a.substring(3,4),a.substring(3,4)].join(""):a),this.r=parseInt(t[1],16),this.g=parseInt(t[2],16),this.b=parseInt(t[3],16)):"object"===s(e)&&(this.r=e.r,this.g=e.g,this.b=e.b))},i.extend(i.Color,{toString:function(){return this.toHex()},toHex:function(){return"#"+u(this.r)+u(this.g)+u(this.b)},toRgb:function(){return"rgb("+[this.r,this.g,this.b].join()+")"},brightness:function(){return this.r/255*.3+this.g/255*.59+this.b/255*.11},morph:function(e){return this.destination=new i.Color(e),this},at:function(e){return this.destination?(e=e<0?0:e>1?1:e,new i.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}}),i.Color.test=function(e){return e+="",i.regex.isHex.test(e)||i.regex.isRgb.test(e)},i.Color.isRgb=function(e){return e&&"number"==typeof e.r&&"number"==typeof e.g&&"number"==typeof e.b},i.Color.isColor=function(e){return i.Color.isRgb(e)||i.Color.test(e)},i.Array=function(e,t){0==(e=(e||[]).valueOf()).length&&t&&(e=t.valueOf()),this.value=this.parse(e)},i.extend(i.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)}}),i.PointArray=function(e,t){i.Array.call(this,e,t||[[0,0]])},i.PointArray.prototype=new i.Array,i.PointArray.prototype.constructor=i.PointArray;for(var a={M:function(e,t,i){return t.x=i.x=e[0],t.y=i.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,i){return t.x=i.x,t.y=i.y,["Z"]}},r="mlhvqtcsaz".split(""),n=0,o=r.length;n<o;++n)a[r[n]]=function(e){return function(t,i,r){if("H"==e)t[0]=t[0]+i.x;else if("V"==e)t[0]=t[0]+i.y;else if("A"==e)t[5]=t[5]+i.x,t[6]=t[6]+i.y;else for(var s=0,n=t.length;s<n;++s)t[s]=t[s]+(s%2?i.y:i.x);if(a&&"function"==typeof a[e])return a[e](t,i,r)}}(r[n].toUpperCase());i.PathArray=function(e,t){i.Array.call(this,e,t||[["M",0,0]])},i.PathArray.prototype=new i.Array,i.PathArray.prototype.constructor=i.PathArray,i.extend(i.PathArray,{toString:function(){return function(e){for(var t=0,i=e.length,a="";t<i;t++)a+=e[t][0],null!=e[t][1]&&(a+=e[t][1],null!=e[t][2]&&(a+=" ",a+=e[t][2],null!=e[t][3]&&(a+=" ",a+=e[t][3],a+=" ",a+=e[t][4],null!=e[t][5]&&(a+=" ",a+=e[t][5],a+=" ",a+=e[t][6],null!=e[t][7]&&(a+=" ",a+=e[t][7])))));return a+" "}(this.value)},move:function(e,t){var i=this.bbox();return i.x,i.y,this},at:function(e){if(!this.destination)return this;for(var t=this.value,a=this.destination.value,r=[],s=new i.PathArray,n=0,o=t.length;n<o;n++){r[n]=[t[n][0]];for(var l=1,c=t[n].length;l<c;l++)r[n][l]=t[n][l]+(a[n][l]-t[n][l])*e;"A"===r[n][0]&&(r[n][4]=+(0!=r[n][4]),r[n][5]=+(0!=r[n][5]))}return s.value=r,s},parse:function(e){if(e instanceof i.PathArray)return e.valueOf();var t,r={M:2,L:2,H:1,V:1,C:6,S:4,Q:4,T:2,A:7,Z:0};e="string"==typeof e?e.replace(i.regex.numbersWithDots,c).replace(i.regex.pathLetters," $& ").replace(i.regex.hyphen,"$1 -").trim().split(i.regex.delimiter):e.reduce((function(e,t){return[].concat.call(e,t)}),[]);var s=[],n=new i.Point,o=new i.Point,l=0,h=e.length;do{i.regex.isPathLetter.test(e[l])?(t=e[l],++l):"M"==t?t="L":"m"==t&&(t="l"),s.push(a[t].call(null,e.slice(l,l+=r[t.toUpperCase()]).map(parseFloat),n,o))}while(h>l);return s},bbox:function(){return i.parser.draw||i.prepare(),i.parser.path.setAttribute("d",this.toString()),i.parser.path.getBBox()}}),i.Number=i.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(i.regex.numberAndUnit))&&(this.value=parseFloat(t[1]),"%"==t[5]?this.value/=100:"s"==t[5]&&(this.value*=1e3),this.unit=t[5]):e instanceof i.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 i.Number(e),new i.Number(this+e,this.unit||e.unit)},minus:function(e){return e=new i.Number(e),new i.Number(this-e,this.unit||e.unit)},times:function(e){return e=new i.Number(e),new i.Number(this*e,this.unit||e.unit)},divide:function(e){return e=new i.Number(e),new i.Number(this/e,this.unit||e.unit)},to:function(e){var t=new i.Number(this);return"string"==typeof e&&(t.unit=e),t},morph:function(e){return this.destination=new i.Number(e),e.relative&&(this.destination.value+=this.value),this},at:function(e){return this.destination?new i.Number(this.destination).minus(this).times(e).plus(this):this}}}),i.Element=i.invent({create:function(e){this._stroke=i.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 a=g(this,e,t);return this.width(new i.Number(a.width)).height(new i.Number(a.height))},clone:function(e){this.writeDataToDom();var t=x(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(i.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 i.get(this.attr(e))},parent:function(t){var a=this;if(!a.node.parentNode)return null;if(a=i.adopt(a.node.parentNode),!t)return a;for(;a&&a.node instanceof e.SVGElement;){if("string"==typeof t?a.matches(t):a instanceof t)return a;if(!a.node.parentNode||"#document"==a.node.parentNode.nodeName)return null;a=i.adopt(a.node.parentNode)}},doc:function(){return this instanceof i.Doc?this:this.parent(i.Doc)},parents:function(e){var t=[],i=this;do{if(!(i=i.parent(e))||!i.node)break;t.push(i)}while(i.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 a=t.createElementNS("http://www.w3.org/2000/svg","svg");if(!(e&&this instanceof i.Parent))return a.appendChild(e=t.createElementNS("http://www.w3.org/2000/svg","svg")),this.writeDataToDom(),e.appendChild(this.node.cloneNode(!0)),a.innerHTML.replace(/^<svg>/,"").replace(/<\/svg>$/,"");a.innerHTML="<svg>"+e.replace(/\n/,"").replace(/<([\w:-]+)([^<]+?)\/>/g,"<$1$2></$1>")+"</svg>";for(var r=0,s=a.firstChild.childNodes.length;r<s;r++)this.node.appendChild(a.firstChild.firstChild);return this},writeDataToDom:function(){return(this.each||this.lines)&&(this.each?this:this.lines()).each((function(){this.writeDataToDom()})),this.node.removeAttribute("svgjs:data"),Object.keys(this.dom).length&&this.node.setAttribute("svgjs:data",JSON.stringify(this.dom)),this},setData:function(e){return this.dom=e,this},is:function(e){return function(e,t){return e instanceof t}(this,e)}}}),i.easing={"-":function(e){return e},"<>":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)}},i.morph=function(e){return function(t,a){return new i.MorphObj(t,a).at(e)}},i.Situation=i.invent({create:function(e){this.init=!1,this.reversed=!1,this.reversing=!1,this.duration=new i.Number(e.duration).valueOf(),this.delay=new i.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={}}}),i.FX=i.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,a){"object"===s(e)&&(t=e.ease,a=e.delay,e=e.duration);var r=new i.Situation({duration:e||1e3,delay:a||0,ease:i.easing[t||"-"]||t});return this.queue(r),this},target:function(e){return e&&e instanceof i.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 i.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 i.Situation?this.start():this.situation.call(this)),this},initAnimations:function(){var e,t=this.situation;if(t.init)return this;for(var a in t.animations){e=this.target()[a](),Array.isArray(e)||(e=[e]),Array.isArray(t.animations[a])||(t.animations[a]=[t.animations[a]]);for(var r=e.length;r--;)t.animations[a][r]instanceof i.Number&&(e[r]=new i.Number(e[r])),t.animations[a][r]=e[r].morph(t.animations[a][r])}for(var a in t.attrs)t.attrs[a]=new i.MorphObj(this.target().attr(a),t.attrs[a]);for(var a in t.styles)t.styles[a]=new i.MorphObj(this.target().style(a),t.styles[a]);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 i=this.active;return this.active=!1,t&&this.clearQueue(),e&&this.situation&&(!i&&this.startCurrent(),this.atEnd()),this.stopAnimFrame(),this.clearCurrent()},after:function(e){var t=this.last();return this.target().on("finished.fx",(function i(a){a.detail.situation==t&&(e.call(this,t),this.off("finished.fx",i))})),this._callStart()},during:function(e){var t=this.last(),a=function(a){a.detail.situation==t&&e.call(this,a.detail.pos,i.morph(a.detail.pos),a.detail.eased,t)};return this.target().off("during.fx",a).on("during.fx",a),this.after((function(){this.off("during.fx",a)})),this._callStart()},afterAll:function(e){var t=function t(i){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,i){return this.last()[i||"animations"][e]=t,this._callStart()},step:function(e){var t,i,a;e||(this.absPos=this.timeToAbsPos(+new Date)),!1!==this.situation.loops?(t=Math.max(this.absPos,0),i=Math.floor(t),!0===this.situation.loops||i<this.situation.loops?(this.pos=t-i,a=this.situation.loop,this.situation.loop=i):(this.absPos=this.situation.loops,this.pos=1,a=this.situation.loop-1,this.situation.loop=this.situation.loops),this.situation.reversing&&(this.situation.reversed=this.situation.reversed!=Boolean((this.situation.loop-a)%2))):(this.absPos=Math.min(this.absPos,1),this.pos=this.absPos),this.pos<0&&(this.pos=0),this.situation.reversed&&(this.pos=1-this.pos);var r=this.situation.ease(this.pos);for(var s in this.situation.once)s>this.lastPos&&s<=r&&(this.situation.once[s].call(this.target(),this.pos,r),delete this.situation.once[s]);return this.active&&this.target().fire("during",{pos:this.pos,eased:r,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=r,this):this},eachAt:function(){var e,t=this,a=this.target(),r=this.situation;for(var s in r.animations)e=[].concat(r.animations[s]).map((function(e){return"string"!=typeof e&&e.at?e.at(r.ease(t.pos),t.pos):e})),a[s].apply(a,e);for(var s in r.attrs)e=[s].concat(r.attrs[s]).map((function(e){return"string"!=typeof e&&e.at?e.at(r.ease(t.pos),t.pos):e})),a.attr.apply(a,e);for(var s in r.styles)e=[s].concat(r.styles[s]).map((function(e){return"string"!=typeof e&&e.at?e.at(r.ease(t.pos),t.pos):e})),a.style.apply(a,e);if(r.transforms.length){e=r.initialTransformation,s=0;for(var n=r.transforms.length;s<n;s++){var o=r.transforms[s];o instanceof i.Matrix?e=o.relative?e.multiply((new i.Matrix).morph(o).at(r.ease(this.pos))):e.morph(o).at(r.ease(this.pos)):(o.relative||o.undo(e.extract()),e=e.multiply(o.at(r.ease(this.pos))))}a.matrix(e)}return this},once:function(e,t,i){var a=this.last();return i||(e=a.ease(e)),a.once[e]=t,this},_callStart:function(){return setTimeout(function(){this.start()}.bind(this),0),this}},parent:i.Element,construct:{animate:function(e,t,a){return(this.fx||(this.fx=new i.FX(this))).animate(e,t,a)},delay:function(e){return(this.fx||(this.fx=new i.FX(this))).delay(e)},stop:function(e,t){return this.fx&&this.fx.stop(e,t),this},finish:function(){return this.fx&&this.fx.finish(),this}}}),i.MorphObj=i.invent({create:function(e,t){return i.Color.isColor(t)?new i.Color(e).morph(t):i.regex.delimiter.test(e)?i.regex.pathLetters.test(e)?new i.PathArray(e).morph(t):new i.Array(e).morph(t):i.regex.numberAndUnit.test(t)?new i.Number(e).morph(t):(this.value=e,void(this.destination=t))},extend:{at:function(e,t){return t<1?this.value:this.destination},valueOf:function(){return this.value}}}),i.extend(i.FX,{attr:function(e,t,i){if("object"===s(e))for(var a in e)this.attr(a,e[a]);else this.add(e,t,"attrs");return this},plot:function(e,t,i,a){return 4==arguments.length?this.plot([e,t,i,a]):this.add("plot",new(this.target().morphArray)(e))}}),i.Box=i.invent({create:function(e,t,a,r){if(!("object"!==s(e)||e instanceof i.Element))return i.Box.call(this,null!=e.left?e.left:e.x,null!=e.top?e.top:e.y,e.width,e.height);var n;4==arguments.length&&(this.x=e,this.y=t,this.width=a,this.height=r),null==(n=this).x&&(n.x=0,n.y=0,n.width=0,n.height=0),n.w=n.width,n.h=n.height,n.x2=n.x+n.width,n.y2=n.y+n.height,n.cx=n.x+n.width/2,n.cy=n.y+n.height/2}}),i.BBox=i.invent({create:function(e){if(i.Box.apply(this,[].slice.call(arguments)),e instanceof i.Element){var a;try{if(!t.documentElement.contains){for(var r=e.node;r.parentNode;)r=r.parentNode;if(r!=t)throw new Error("Element not in the dom")}a=e.node.getBBox()}catch(t){if(e instanceof i.Shape){i.parser.draw||i.prepare();var s=e.clone(i.parser.draw.instance).show();s&&s.node&&"function"==typeof s.node.getBBox&&(a=s.node.getBBox()),s&&"function"==typeof s.remove&&s.remove()}else a={x:e.node.clientLeft,y:e.node.clientTop,width:e.node.clientWidth,height:e.node.clientHeight}}i.Box.call(this,a)}},inherit:i.Box,parent:i.Element,construct:{bbox:function(){return new i.BBox(this)}}}),i.BBox.prototype.constructor=i.BBox,i.Matrix=i.invent({create:function(e){var t=p([1,0,0,1,0,0]);e=null===e?t:e instanceof i.Element?e.matrixify():"string"==typeof e?p(e.split(i.regex.delimiter).map(parseFloat)):6==arguments.length?p([].slice.call(arguments)):Array.isArray(e)?p(e):e&&"object"===s(e)?e:t;for(var a=v.length-1;a>=0;--a)this[v[a]]=null!=e[v[a]]?e[v[a]]:t[v[a]]},extend:{extract:function(){var e=f(this,0,1),t=(f(this,1,0),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 i.Matrix(this)}},clone:function(){return new i.Matrix(this)},morph:function(e){return this.destination=new i.Matrix(e),this},multiply:function(e){return new i.Matrix(this.native().multiply(function(e){return e instanceof i.Matrix||(e=new i.Matrix(e)),e}(e).native()))},inverse:function(){return new i.Matrix(this.native().inverse())},translate:function(e,t){return new i.Matrix(this.native().translate(e||0,t||0))},native:function(){for(var e=i.parser.native.createSVGMatrix(),t=v.length-1;t>=0;t--)e[v[t]]=this[v[t]];return e},toString:function(){return"matrix("+b(this.a)+","+b(this.b)+","+b(this.c)+","+b(this.d)+","+b(this.e)+","+b(this.f)+")"}},parent:i.Element,construct:{ctm:function(){return new i.Matrix(this.node.getCTM())},screenCTM:function(){if(this instanceof i.Nested){var e=this.rect(1,1),t=e.node.getScreenCTM();return e.remove(),new i.Matrix(t)}return new i.Matrix(this.node.getScreenCTM())}}}),i.Point=i.invent({create:function(e,t){var i;i=Array.isArray(e)?{x:e[0],y:e[1]}:"object"===s(e)?{x:e.x,y:e.y}:null!=e?{x:e,y:null!=t?t:e}:{x:0,y:0},this.x=i.x,this.y=i.y},extend:{clone:function(){return new i.Point(this)},morph:function(e,t){return this.destination=new i.Point(e,t),this}}}),i.extend(i.Element,{point:function(e,t){return new i.Point(e,t).transform(this.screenCTM().inverse())}}),i.extend(i.Element,{attr:function(e,t,a){if(null==e){for(e={},a=(t=this.node.attributes).length-1;a>=0;a--)e[t[a].nodeName]=i.regex.isNumber.test(t[a].nodeValue)?parseFloat(t[a].nodeValue):t[a].nodeValue;return e}if("object"===s(e))for(var r in e)this.attr(r,e[r]);else if(null===t)this.node.removeAttribute(e);else{if(null==t)return null==(t=this.node.getAttribute(e))?i.defaults.attrs[e]:i.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||(i.regex.isImage.test(t)&&(t=this.doc().defs().image(t,0,0)),t instanceof i.Image&&(t=this.doc().defs().pattern(0,0,(function(){this.add(t)})))),"number"==typeof t?t=new i.Number(t):i.Color.isColor(t)?t=new i.Color(t):Array.isArray(t)&&(t=new i.Array(t)),"leading"==e?this.leading&&this.leading(t):"string"==typeof a?this.node.setAttributeNS(a,e,t.toString()):this.node.setAttribute(e,t.toString()),!this.rebuild||"font-size"!=e&&"x"!=e||this.rebuild(e,t)}return this}}),i.extend(i.Element,{transform:function(e,t){var a;return"object"!==s(e)?(a=new i.Matrix(this).extract(),"string"==typeof e?a[e]:a):(a=new i.Matrix(this),t=!!t||!!e.relative,null!=e.a&&(a=t?a.multiply(new i.Matrix(e)):new i.Matrix(e)),this.attr("transform",a))}}),i.extend(i.Element,{untransform:function(){return this.attr("transform",null)},matrixify:function(){return(this.attr("transform")||"").split(i.regex.transforms).slice(0,-1).map((function(e){var t=e.trim().split("(");return[t[0],t[1].split(i.regex.delimiter).map((function(e){return parseFloat(e)}))]})).reduce((function(e,t){return"matrix"==t[0]?e.multiply(p(t[1])):e[t[0]].apply(e,t[1])}),new i.Matrix)},toParent:function(e){if(this==e)return this;var t=this.screenCTM(),i=e.screenCTM().inverse();return this.addTo(e).untransform().transform(i.multiply(t)),this},toDoc:function(){return this.toParent(this.doc())}}),i.Transformation=i.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 i=0,a=this.arguments.length;i<a;++i)this[this.arguments[i]]=e[i];else if(e&&"object"===s(e))for(i=0,a=this.arguments.length;i<a;++i)this[this.arguments[i]]=e[this.arguments[i]];this.inversed=!1,!0===t&&(this.inversed=!0)}}),i.Translate=i.invent({parent:i.Matrix,inherit:i.Transformation,create:function(e,t){this.constructor.apply(this,[].slice.call(arguments))},extend:{arguments:["transformedX","transformedY"],method:"translate"}}),i.extend(i.Element,{style:function(e,t){if(0==arguments.length)return this.node.style.cssText||"";if(arguments.length<2)if("object"===s(e))for(var a in e)this.style(a,e[a]);else{if(!i.regex.isCss.test(e))return this.node.style[h(e)];for(e=e.split(/\s*;\s*/).filter((function(e){return!!e})).map((function(e){return e.split(/\s*:\s*/)}));t=e.pop();)this.style(t[0],t[1])}else this.node.style[h(e)]=null===t||i.regex.isBlank.test(t)?"":t;return this}}),i.Parent=i.invent({create:function(e){this.constructor.call(this,e)},inherit:i.Element,extend:{children:function(){return i.utils.map(i.utils.filterSVGElements(this.node.childNodes),(function(e){return i.adopt(e)}))},add:function(e,t){return null==t?this.node.appendChild(e.node):e.node!=this.node.childNodes[t]&&this.node.insertBefore(e.node,this.node.childNodes[t]),this},put:function(e,t){return this.add(e,t),e},has:function(e){return this.index(e)>=0},index:function(e){return[].slice.call(this.node.childNodes).indexOf(e.node)},get:function(e){return i.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 a=this.children(),r=0,s=a.length;r<s;r++)a[r]instanceof i.Element&&e.apply(a[r],[r,a]),t&&a[r]instanceof i.Container&&a[r].each(e,t);return this},removeElement:function(e){return this.node.removeChild(e.node),this},clear:function(){for(;this.node.hasChildNodes();)this.node.removeChild(this.node.lastChild);return delete this._defs,this},defs:function(){return this.doc().defs()}}}),i.extend(i.Parent,{ungroup:function(e,t){return 0===t||this instanceof i.Defs||this.node==i.parser.draw||(e=e||(this instanceof i.Doc?this:this.parent(i.Parent)),t=t||1/0,this.each((function(){return this instanceof i.Defs?this:this instanceof i.Parent?this.ungroup(e,t-1):this.toParent(e)})),this.node.firstChild||this.remove()),this},flatten:function(e,t){return this.ungroup(e,t)}}),i.Container=i.invent({create:function(e){this.constructor.call(this,e)},inherit:i.Parent}),i.ViewBox=i.invent({parent:i.Container,construct:{}}),["click","dblclick","mousedown","mouseup","mouseover","mouseout","mousemove","touchstart","touchmove","touchleave","touchend","touchcancel"].forEach((function(e){i.Element.prototype[e]=function(t){return i.on(this.node,e,t),this}})),i.listeners=[],i.handlerMap=[],i.listenerId=0,i.on=function(e,t,a,r,s){var n=a.bind(r||e.instance||e),o=(i.handlerMap.indexOf(e)+1||i.handlerMap.push(e))-1,l=t.split(".")[0],c=t.split(".")[1]||"*";i.listeners[o]=i.listeners[o]||{},i.listeners[o][l]=i.listeners[o][l]||{},i.listeners[o][l][c]=i.listeners[o][l][c]||{},a._svgjsListenerId||(a._svgjsListenerId=++i.listenerId),i.listeners[o][l][c][a._svgjsListenerId]=n,e.addEventListener(l,n,s||{passive:!1})},i.off=function(e,t,a){var r=i.handlerMap.indexOf(e),s=t&&t.split(".")[0],n=t&&t.split(".")[1],o="";if(-1!=r)if(a){if("function"==typeof a&&(a=a._svgjsListenerId),!a)return;i.listeners[r][s]&&i.listeners[r][s][n||"*"]&&(e.removeEventListener(s,i.listeners[r][s][n||"*"][a],!1),delete i.listeners[r][s][n||"*"][a])}else if(n&&s){if(i.listeners[r][s]&&i.listeners[r][s][n]){for(var l in i.listeners[r][s][n])i.off(e,[s,n].join("."),l);delete i.listeners[r][s][n]}}else if(n)for(var c in i.listeners[r])for(var o in i.listeners[r][c])n===o&&i.off(e,[c,n].join("."));else if(s){if(i.listeners[r][s]){for(var o in i.listeners[r][s])i.off(e,[s,o].join("."));delete i.listeners[r][s]}}else{for(var c in i.listeners[r])i.off(e,c);delete i.listeners[r],delete i.handlerMap[r]}},i.extend(i.Element,{on:function(e,t,a,r){return i.on(this.node,e,t,a,r),this},off:function(e,t){return i.off(this.node,e,t),this},fire:function(t,a){return t instanceof e.Event?this.node.dispatchEvent(t):this.node.dispatchEvent(t=new i.CustomEvent(t,{detail:a,cancelable:!0})),this._event=t,this},event:function(){return this._event}}),i.Defs=i.invent({create:"defs",inherit:i.Container}),i.G=i.invent({create:"g",inherit:i.Container,extend:{x:function(e){return null==e?this.transform("x"):this.transform({x:e-this.x()},!0)}},construct:{group:function(){return this.put(new i.G)}}}),i.Doc=i.invent({create:function(e){e&&("svg"==(e="string"==typeof e?t.getElementById(e):e).nodeName?this.constructor.call(this,e):(this.constructor.call(this,i.create("svg")),e.appendChild(this.node),this.size("100%","100%")),this.namespace().defs())},inherit:i.Container,extend:{namespace:function(){return this.attr({xmlns:i.ns,version:"1.1"}).attr("xmlns:xlink",i.xlink,i.xmlns).attr("xmlns:svgjs",i.svgjs,i.xmlns)},defs:function(){var e;return this._defs||((e=this.node.getElementsByTagName("defs")[0])?this._defs=i.adopt(e):this._defs=new i.Defs,this.node.appendChild(this._defs.node)),this._defs},parent:function(){return this.node.parentNode&&"#document"!=this.node.parentNode.nodeName?this.node.parentNode:null},remove:function(){return this.parent()&&this.parent().removeChild(this.node),this},clear:function(){for(;this.node.hasChildNodes();)this.node.removeChild(this.node.lastChild);return delete this._defs,i.parser.draw&&!i.parser.draw.parentNode&&this.node.appendChild(i.parser.draw),this},clone:function(e){this.writeDataToDom();var t=this.node,i=x(t.cloneNode(!0));return e?(e.node||e).appendChild(i.node):t.parentNode.insertBefore(i.node,t.nextSibling),i}}}),i.extend(i.Element,{}),i.Gradient=i.invent({create:function(e){this.constructor.call(this,i.create(e+"Gradient")),this.type=e},inherit:i.Container,extend:{at:function(e,t,a){return this.put(new i.Stop).update(e,t,a)},update:function(e){return this.clear(),"function"==typeof e&&e.call(this,this),this},fill:function(){return"url(#"+this.id()+")"},toString:function(){return this.fill()},attr:function(e,t,a){return"transform"==e&&(e="gradientTransform"),i.Container.prototype.attr.call(this,e,t,a)}},construct:{gradient:function(e,t){return this.defs().gradient(e,t)}}}),i.extend(i.Gradient,i.FX,{from:function(e,t){return"radial"==(this._target||this).type?this.attr({fx:new i.Number(e),fy:new i.Number(t)}):this.attr({x1:new i.Number(e),y1:new i.Number(t)})},to:function(e,t){return"radial"==(this._target||this).type?this.attr({cx:new i.Number(e),cy:new i.Number(t)}):this.attr({x2:new i.Number(e),y2:new i.Number(t)})}}),i.extend(i.Defs,{gradient:function(e,t){return this.put(new i.Gradient(e)).update(t)}}),i.Stop=i.invent({create:"stop",inherit:i.Element,extend:{update:function(e){return("number"==typeof e||e instanceof i.Number)&&(e={offset:arguments[0],color:arguments[1],opacity:arguments[2]}),null!=e.opacity&&this.attr("stop-opacity",e.opacity),null!=e.color&&this.attr("stop-color",e.color),null!=e.offset&&this.attr("offset",new i.Number(e.offset)),this}}}),i.Pattern=i.invent({create:"pattern",inherit:i.Container,extend:{fill:function(){return"url(#"+this.id()+")"},update:function(e){return this.clear(),"function"==typeof e&&e.call(this,this),this},toString:function(){return this.fill()},attr:function(e,t,a){return"transform"==e&&(e="patternTransform"),i.Container.prototype.attr.call(this,e,t,a)}},construct:{pattern:function(e,t,i){return this.defs().pattern(e,t,i)}}}),i.extend(i.Defs,{pattern:function(e,t,a){return this.put(new i.Pattern).update(a).attr({x:0,y:0,width:e,height:t,patternUnits:"userSpaceOnUse"})}}),i.Shape=i.invent({create:function(e){this.constructor.call(this,e)},inherit:i.Element}),i.Symbol=i.invent({create:"symbol",inherit:i.Container,construct:{symbol:function(){return this.put(new i.Symbol)}}}),i.Use=i.invent({create:"use",inherit:i.Shape,extend:{element:function(e,t){return this.attr("href",(t||"")+"#"+e,i.xlink)}},construct:{use:function(e,t){return this.put(new i.Use).element(e,t)}}}),i.Rect=i.invent({create:"rect",inherit:i.Shape,construct:{rect:function(e,t){return this.put(new i.Rect).size(e,t)}}}),i.Circle=i.invent({create:"circle",inherit:i.Shape,construct:{circle:function(e){return this.put(new i.Circle).rx(new i.Number(e).divide(2)).move(0,0)}}}),i.extend(i.Circle,i.FX,{rx:function(e){return this.attr("r",e)},ry:function(e){return this.rx(e)}}),i.Ellipse=i.invent({create:"ellipse",inherit:i.Shape,construct:{ellipse:function(e,t){return this.put(new i.Ellipse).size(e,t).move(0,0)}}}),i.extend(i.Ellipse,i.Rect,i.FX,{rx:function(e){return this.attr("rx",e)},ry:function(e){return this.attr("ry",e)}}),i.extend(i.Circle,i.Ellipse,{x:function(e){return null==e?this.cx()-this.rx():this.cx(e+this.rx())},y:function(e){return null==e?this.cy()-this.ry():this.cy(e+this.ry())},cx:function(e){return null==e?this.attr("cx"):this.attr("cx",e)},cy:function(e){return null==e?this.attr("cy"):this.attr("cy",e)},width:function(e){return null==e?2*this.rx():this.rx(new i.Number(e).divide(2))},height:function(e){return null==e?2*this.ry():this.ry(new i.Number(e).divide(2))},size:function(e,t){var a=g(this,e,t);return this.rx(new i.Number(a.width).divide(2)).ry(new i.Number(a.height).divide(2))}}),i.Line=i.invent({create:"line",inherit:i.Shape,extend:{array:function(){return new i.PointArray([[this.attr("x1"),this.attr("y1")],[this.attr("x2"),this.attr("y2")]])},plot:function(e,t,a,r){return null==e?this.array():(e=void 0!==t?{x1:e,y1:t,x2:a,y2:r}:new i.PointArray(e).toLine(),this.attr(e))},move:function(e,t){return this.attr(this.array().move(e,t).toLine())},size:function(e,t){var i=g(this,e,t);return this.attr(this.array().size(i.width,i.height).toLine())}},construct:{line:function(e,t,a,r){return i.Line.prototype.plot.apply(this.put(new i.Line),null!=e?[e,t,a,r]:[0,0,0,0])}}}),i.Polyline=i.invent({create:"polyline",inherit:i.Shape,construct:{polyline:function(e){return this.put(new i.Polyline).plot(e||new i.PointArray)}}}),i.Polygon=i.invent({create:"polygon",inherit:i.Shape,construct:{polygon:function(e){return this.put(new i.Polygon).plot(e||new i.PointArray)}}}),i.extend(i.Polyline,i.Polygon,{array:function(){return this._array||(this._array=new i.PointArray(this.attr("points")))},plot:function(e){return null==e?this.array():this.clear().attr("points","string"==typeof e?e:this._array=new i.PointArray(e))},clear:function(){return delete this._array,this},move:function(e,t){return this.attr("points",this.array().move(e,t))},size:function(e,t){var i=g(this,e,t);return this.attr("points",this.array().size(i.width,i.height))}}),i.extend(i.Line,i.Polyline,i.Polygon,{morphArray:i.PointArray,x:function(e){return null==e?this.bbox().x:this.move(e,this.bbox().y)},y:function(e){return null==e?this.bbox().y:this.move(this.bbox().x,e)},width:function(e){var t=this.bbox();return null==e?t.width:this.size(e,t.height)},height:function(e){var t=this.bbox();return null==e?t.height:this.size(t.width,e)}}),i.Path=i.invent({create:"path",inherit:i.Shape,extend:{morphArray:i.PathArray,array:function(){return this._array||(this._array=new i.PathArray(this.attr("d")))},plot:function(e){return null==e?this.array():this.clear().attr("d","string"==typeof e?e:this._array=new i.PathArray(e))},clear:function(){return delete this._array,this}},construct:{path:function(e){return this.put(new i.Path).plot(e||new i.PathArray)}}}),i.Image=i.invent({create:"image",inherit:i.Shape,extend:{load:function(t){if(!t)return this;var a=this,r=new e.Image;return i.on(r,"load",(function(){i.off(r);var e=a.parent(i.Pattern);null!==e&&(0==a.width()&&0==a.height()&&a.size(r.width,r.height),e&&0==e.width()&&0==e.height()&&e.size(a.width(),a.height()),"function"==typeof a._loaded&&a._loaded.call(a,{width:r.width,height:r.height,ratio:r.width/r.height,url:t}))})),i.on(r,"error",(function(e){i.off(r),"function"==typeof a._error&&a._error.call(a,e)})),this.attr("href",r.src=this.src=t,i.xlink)},loaded:function(e){return this._loaded=e,this},error:function(e){return this._error=e,this}},construct:{image:function(e,t,a){return this.put(new i.Image).load(e).size(t||0,a||t||0)}}}),i.Text=i.invent({create:function(){this.constructor.call(this,i.create("text")),this.dom.leading=new i.Number(1.3),this._rebuild=!0,this._build=!1,this.attr("font-family",i.defaults.attrs["font-family"])},inherit:i.Shape,extend:{x:function(e){return null==e?this.attr("x"):this.attr("x",e)},text:function(e){if(void 0===e){e="";for(var t=this.node.childNodes,a=0,r=t.length;a<r;++a)0!=a&&3!=t[a].nodeType&&1==i.adopt(t[a]).dom.newLined&&(e+="\n"),e+=t[a].textContent;return e}if(this.clear().build(!0),"function"==typeof e)e.call(this,this);else{a=0;for(var s=(e=e.split("\n")).length;a<s;a++)this.tspan(e[a]).newLine()}return this.build(!1).rebuild()},size:function(e){return this.attr("font-size",e).rebuild()},leading:function(e){return null==e?this.dom.leading:(this.dom.leading=new i.Number(e),this.rebuild())},lines:function(){var e=(this.textPath&&this.textPath()||this).node,t=i.utils.map(i.utils.filterSVGElements(e.childNodes),(function(e){return i.adopt(e)}));return new i.Set(t)},rebuild:function(e){if("boolean"==typeof e&&(this._rebuild=e),this._rebuild){var t=this,a=0,r=this.dom.leading*new i.Number(this.attr("font-size"));this.lines().each((function(){this.dom.newLined&&(t.textPath()||this.attr("x",t.attr("x")),"\n"==this.text()?a+=r:(this.attr("dy",r+a),a=0))})),this.fire("rebuild")}return this},build:function(e){return this._build=!!e,this},setData:function(e){return this.dom=e,this.dom.leading=new i.Number(e.leading||1.3),this}},construct:{text:function(e){return this.put(new i.Text).text(e)},plain:function(e){return this.put(new i.Text).plain(e)}}}),i.Tspan=i.invent({create:"tspan",inherit:i.Shape,extend:{text:function(e){return null==e?this.node.textContent+(this.dom.newLined?"\n":""):("function"==typeof e?e.call(this,this):this.plain(e),this)},dx:function(e){return this.attr("dx",e)},dy:function(e){return this.attr("dy",e)},newLine:function(){var e=this.parent(i.Text);return this.dom.newLined=!0,this.dy(e.dom.leading*e.attr("font-size")).attr("x",e.x())}}}),i.extend(i.Text,i.Tspan,{plain:function(e){return!1===this._build&&this.clear(),this.node.appendChild(t.createTextNode(e)),this},tspan:function(e){var t=(this.textPath&&this.textPath()||this).node,a=new i.Tspan;return!1===this._build&&this.clear(),t.appendChild(a.node),a.text(e)},clear:function(){for(var e=(this.textPath&&this.textPath()||this).node;e.hasChildNodes();)e.removeChild(e.lastChild);return this},length:function(){return this.node.getComputedTextLength()}}),i.TextPath=i.invent({create:"textPath",inherit:i.Parent,parent:i.Text,construct:{morphArray:i.PathArray,array:function(){var e=this.track();return e?e.array():null},plot:function(e){var t=this.track(),i=null;return t&&(i=t.plot(e)),null==e?i:this},track:function(){var e=this.textPath();if(e)return e.reference("href")},textPath:function(){if(this.node.firstChild&&"textPath"==this.node.firstChild.nodeName)return i.adopt(this.node.firstChild)}}}),i.Nested=i.invent({create:function(){this.constructor.call(this,i.create("svg")),this.style("overflow","visible")},inherit:i.Container,construct:{nested:function(){return this.put(new i.Nested)}}});var l={stroke:["color","width","opacity","linecap","linejoin","miterlimit","dasharray","dashoffset"],fill:["color","opacity","rule"],prefix:function(e,t){return"color"==t?e:e+"-"+t}};function c(e,t,a,r){return a+r.replace(i.regex.dots," .")}function h(e){return e.toLowerCase().replace(/-(.)/g,(function(e,t){return t.toUpperCase()}))}function d(e){return e.charAt(0).toUpperCase()+e.slice(1)}function u(e){var t=e.toString(16);return 1==t.length?"0"+t:t}function g(e,t,i){if(null==t||null==i){var a=e.bbox();null==t?t=a.width/a.height*i:null==i&&(i=a.height/a.width*t)}return{width:t,height:i}}function f(e,t,i){return{x:t*e.a+i*e.c+0,y:t*e.b+i*e.d+0}}function p(e){return{a:e[0],b:e[1],c:e[2],d:e[3],e:e[4],f:e[5]}}function x(t){for(var a=t.childNodes.length-1;a>=0;a--)t.childNodes[a]instanceof e.SVGElement&&x(t.childNodes[a]);return i.adopt(t).id(i.eid(t.nodeName))}function b(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||i.Color.isRgb(t)||t&&"function"==typeof t.fill)this.attr(e,t);else for(var a=l[e].length-1;a>=0;a--)null!=t[l[e][a]]&&this.attr(l.prefix(e,l[e][a]),t[l[e][a]]);return this},i.extend(i.Element,i.FX,t)})),i.extend(i.Element,i.FX,{translate:function(e,t){return this.transform({x:e,y:t})},matrix:function(e){return this.attr("transform",new i.Matrix(6==arguments.length?[].slice.call(arguments):e))},opacity:function(e){return this.attr("opacity",e)},dx:function(e){return this.x(new i.Number(e).plus(this instanceof i.FX?0:this.x()),!0)},dy:function(e){return this.y(new i.Number(e).plus(this instanceof i.FX?0:this.y()),!0)}}),i.extend(i.Path,{length:function(){return this.node.getTotalLength()},pointAt:function(e){return this.node.getPointAtLength(e)}}),i.Set=i.invent({create:function(e){Array.isArray(e)?this.members=e:this.clear()},extend:{add:function(){for(var e=[].slice.call(arguments),t=0,i=e.length;t<i;t++)this.members.push(e[t]);return this},remove:function(e){var t=this.index(e);return t>-1&&this.members.splice(t,1),this},each:function(e){for(var t=0,i=this.members.length;t<i;t++)e.apply(this.members[t],[t,this.members]);return this},clear:function(){return this.members=[],this},length:function(){return this.members.length},has:function(e){return this.index(e)>=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 i.Set(e)}}}),i.FX.Set=i.invent({create:function(e){this.set=e}}),i.Set.inherit=function(){var e=[];for(var t in i.Shape.prototype)"function"==typeof i.Shape.prototype[t]&&"function"!=typeof i.Set.prototype[t]&&e.push(t);for(var t in e.forEach((function(e){i.Set.prototype[e]=function(){for(var t=0,a=this.members.length;t<a;t++)this.members[t]&&"function"==typeof this.members[t][e]&&this.members[t][e].apply(this.members[t],arguments);return"animate"==e?this.fx||(this.fx=new i.FX.Set(this)):this}})),e=[],i.FX.prototype)"function"==typeof i.FX.prototype[t]&&"function"!=typeof i.FX.Set.prototype[t]&&e.push(t);e.forEach((function(e){i.FX.Set.prototype[e]=function(){for(var t=0,i=this.set.members.length;t<i;t++)this.set.members[t].fx[e].apply(this.set.members[t].fx,arguments);return this}}))},i.extend(i.Element,{}),i.extend(i.Element,{remember:function(e,t){if("object"===s(arguments[0]))for(var i in e)this.remember(i,e[i]);else{if(1==arguments.length)return this.memory()[e];this.memory()[e]=t}return this},forget:function(){if(0==arguments.length)this._memory={};else for(var e=arguments.length-1;e>=0;e--)delete this.memory()[arguments[e]];return this},memory:function(){return this._memory||(this._memory={})}}),i.get=function(e){var a=t.getElementById(function(e){var t=(e||"").toString().match(i.regex.reference);if(t)return t[1]}(e)||e);return i.adopt(a)},i.select=function(e,a){return new i.Set(i.utils.map((a||t).querySelectorAll(e),(function(e){return i.adopt(e)})))},i.extend(i.Parent,{select:function(e){return i.select(e,this.node)}});var v="abcdef".split("");if("function"!=typeof e.CustomEvent){var m=function(e,i){i=i||{bubbles:!1,cancelable:!1,detail:void 0};var a=t.createEvent("CustomEvent");return a.initCustomEvent(e,i.bubbles,i.cancelable,i.detail),a};m.prototype=e.Event.prototype,i.CustomEvent=m}else i.CustomEvent=e.CustomEvent;return i}(r,r.document)}.call(t,i,t,e),void 0===a||(e.exports=a)},539:(e,t,i)=>{"use strict";i.r(t),i.d(t,{default:()=>o});var a=i(499),r=i.n(a),s=i(922),n=i.n(s)()(r());n.push([e.id,'@keyframes opaque {\n 0% {\n opacity: 0\n }\n\n to {\n opacity: 1\n }\n}\n\n@keyframes resizeanim {\n\n 0%,\n 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\nrect.legend-mouseover-inactive,\n.legend-mouseover-inactive rect,\n.legend-mouseover-inactive path,\n.legend-mouseover-inactive circle,\n.legend-mouseover-inactive line,\n.legend-mouseover-inactive text.apexcharts-yaxis-title-text,\n.legend-mouseover-inactive text.apexcharts-yaxis-label {\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,\n.apexcharts-tooltip-text-y-value,\n.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,\n.apexcharts-tooltip-text-goals-value:empty,\n.apexcharts-tooltip-text-y-label:empty,\n.apexcharts-tooltip-text-y-value:empty,\n.apexcharts-tooltip-text-z-value:empty,\n.apexcharts-tooltip-title:empty {\n display: none\n}\n\n.apexcharts-tooltip-text-goals-label,\n.apexcharts-tooltip-text-goals-value {\n padding: 6px 0 5px\n}\n\n.apexcharts-tooltip-goals-group,\n.apexcharts-tooltip-text-goals-label,\n.apexcharts-tooltip-text-goals-value {\n display: flex\n}\n\n.apexcharts-tooltip-text-goals-label:not(:empty),\n.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,\n.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,\n.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,\n.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,\n.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,\n.apexcharts-xaxistooltip-bottom:before {\n bottom: 100%\n}\n\n.apexcharts-xaxistooltip-top:after,\n.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,\n.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,\n.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,\n.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,\n.apexcharts-yaxistooltip-left:before {\n left: 100%\n}\n\n.apexcharts-yaxistooltip-right:after,\n.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,\n.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,\n.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,\n.apexcharts-ycrosshairs {\n pointer-events: none;\n opacity: 0;\n transition: .15s ease all\n}\n\n.apexcharts-xcrosshairs.apexcharts-active,\n.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,\n.svg_select_points_rot {\n pointer-events: none;\n opacity: 0;\n visibility: hidden\n}\n\n.apexcharts-selection-rect+g .svg_select_boundingRect,\n.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,\n.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,\n.apexcharts-pan-icon,\n.apexcharts-reset-icon,\n.apexcharts-selection-icon,\n.apexcharts-toolbar-custom-icon,\n.apexcharts-zoom-icon,\n.apexcharts-zoomin-icon,\n.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,\n.apexcharts-reset-icon svg,\n.apexcharts-zoom-icon svg,\n.apexcharts-zoomin-icon svg,\n.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,\n.apexcharts-theme-dark .apexcharts-pan-icon svg,\n.apexcharts-theme-dark .apexcharts-reset-icon svg,\n.apexcharts-theme-dark .apexcharts-selection-icon svg,\n.apexcharts-theme-dark .apexcharts-toolbar-custom-icon svg,\n.apexcharts-theme-dark .apexcharts-zoom-icon svg,\n.apexcharts-theme-dark .apexcharts-zoomin-icon svg,\n.apexcharts-theme-dark .apexcharts-zoomout-icon svg {\n fill: #f3f4f5\n}\n\n.apexcharts-canvas .apexcharts-reset-zoom-icon.apexcharts-selected svg,\n.apexcharts-canvas .apexcharts-selection-icon.apexcharts-selected svg,\n.apexcharts-canvas .apexcharts-zoom-icon.apexcharts-selected svg {\n fill: #008ffb\n}\n\n.apexcharts-theme-light .apexcharts-menu-icon:hover svg,\n.apexcharts-theme-light .apexcharts-reset-icon:hover svg,\n.apexcharts-theme-light .apexcharts-selection-icon:not(.apexcharts-selected):hover svg,\n.apexcharts-theme-light .apexcharts-zoom-icon:not(.apexcharts-selected):hover svg,\n.apexcharts-theme-light .apexcharts-zoomin-icon:hover svg,\n.apexcharts-theme-light .apexcharts-zoomout-icon:hover svg {\n fill: #333\n}\n\n.apexcharts-menu-icon,\n.apexcharts-selection-icon {\n position: relative\n}\n\n.apexcharts-reset-icon {\n margin-left: 5px\n}\n\n.apexcharts-menu-icon,\n.apexcharts-reset-icon,\n.apexcharts-zoom-icon {\n transform: scale(.85)\n}\n\n.apexcharts-zoomin-icon,\n.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,\n.apexcharts-datalabel.apexcharts-element-hidden,\n.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\n.apexcharts-datalabel,\n.apexcharts-datalabel-label,\n.apexcharts-datalabel-value,\n.apexcharts-datalabels,\n.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,\n.apexcharts-area-series .apexcharts-area,\n.apexcharts-area-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,\n.apexcharts-gridline,\n.apexcharts-line,\n.apexcharts-line-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,\n.apexcharts-point-annotation-label,\n.apexcharts-radar-series path,\n.apexcharts-radar-series polygon,\n.apexcharts-toolbar svg,\n.apexcharts-tooltip .apexcharts-marker,\n.apexcharts-xaxis-annotation-label,\n.apexcharts-yaxis-annotation-label,\n.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,\n.resize-triggers,\n.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}',""]);const o=n},274:(e,t,i)=>{var a=i(379),r=i(539);"string"==typeof(r=r.__esModule?r.default:r)&&(r=[[e.id,r,""]]);var s=(a(e.id,r,{insert:"head",singleton:!1}),r.locals?r.locals:{});e.exports=s},379:(e,t,i)=>{"use strict";var a,r=function(){var e={};return function(t){if(void 0===e[t]){var i=document.querySelector(t);if(window.HTMLIFrameElement&&i instanceof window.HTMLIFrameElement)try{i=i.contentDocument.head}catch(e){i=null}e[t]=i}return e[t]}}(),s={};function n(e,t,i){for(var a=0;a<t.length;a++){var r={css:t[a][1],media:t[a][2],sourceMap:t[a][3]};s[e][a]?s[e][a](r):s[e].push(f(r,i))}}function o(e){var t=document.createElement("style"),a=e.attributes||{};if(void 0===a.nonce){var s=i.nc;s&&(a.nonce=s)}if(Object.keys(a).forEach((function(e){t.setAttribute(e,a[e])})),"function"==typeof e.insert)e.insert(t);else{var n=r(e.insert||"head");if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(t)}return t}var l,c=(l=[],function(e,t){return l[e]=t,l.filter(Boolean).join("\n")});function h(e,t,i,a){var r=i?"":a.css;if(e.styleSheet)e.styleSheet.cssText=c(t,r);else{var s=document.createTextNode(r),n=e.childNodes;n[t]&&e.removeChild(n[t]),n.length?e.insertBefore(s,n[t]):e.appendChild(s)}}function d(e,t,i){var a=i.css,r=i.media,s=i.sourceMap;if(r?e.setAttribute("media",r):e.removeAttribute("media"),s&&btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(s))))," */")),e.styleSheet)e.styleSheet.cssText=a;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(a))}}var u=null,g=0;function f(e,t){var i,a,r;if(t.singleton){var s=g++;i=u||(u=o(t)),a=h.bind(null,i,s,!1),r=h.bind(null,i,s,!0)}else i=o(t),a=d.bind(null,i,t),r=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(i)};return a(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;a(e=t)}else r()}}e.exports=function(e,t,i){return(i=i||{}).singleton||"boolean"==typeof i.singleton||(i.singleton=(void 0===a&&(a=Boolean(window&&document&&document.all&&!window.atob)),a)),e=i.base?e+i.base:e,t=t||[],s[e]||(s[e]=[]),n(e,t,i),function(t){if(t=t||[],"[object Array]"===Object.prototype.toString.call(t)){s[e]||(s[e]=[]),n(e,t,i);for(var a=t.length;a<s[e].length;a++)s[e][a]();s[e].length=t.length,0===s[e].length&&delete s[e]}}}},149:e=>{e.exports='<svg fill="#000000" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"></path><path d="M0 0h24v24H0z" fill="none"></path></svg>'},355:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"></path><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"></path></svg>'},686:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M0 0h24v24H0z" fill="none"></path><path d="M7 11v2h10v-2H7zm5-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"></path></svg>'},798:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="#000000" viewBox="0 0 24 24"><defs><path d="M0 0h24v24H0z" id="a"></path></defs><clipPath id="b"><use overflow="visible" xlink:href="#a"></use></clipPath><path clip-path="url(#b)" d="M23 5.5V20c0 2.2-1.8 4-4 4h-7.3c-1.08 0-2.1-.43-2.85-1.19L1 14.83s1.26-1.23 1.3-1.25c.22-.19.49-.29.79-.29.22 0 .42.06.6.16.04.01 4.31 2.46 4.31 2.46V4c0-.83.67-1.5 1.5-1.5S11 3.17 11 4v7h1V1.5c0-.83.67-1.5 1.5-1.5S15 .67 15 1.5V11h1V2.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V11h1V5.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5z"></path></svg>'},323:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M0 0h24v24H0z" fill="none"></path><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"></path></svg>'},618:e=>{e.exports='<svg fill="#6E8192" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h24v24H0z" fill="none"></path><path d="M3 5h2V3c-1.1 0-2 .9-2 2zm0 8h2v-2H3v2zm4 8h2v-2H7v2zM3 9h2V7H3v2zm10-6h-2v2h2V3zm6 0v2h2c0-1.1-.9-2-2-2zM5 21v-2H3c0 1.1.9 2 2 2zm-2-4h2v-2H3v2zM9 3H7v2h2V3zm2 18h2v-2h-2v2zm8-8h2v-2h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2zm0-12h2V7h-2v2zm0 8h2v-2h-2v2zm-4 4h2v-2h-2v2zm0-16h2V3h-2v2z"></path></svg>'},688:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" fill="#000000" viewBox="0 0 24 24"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"></path><path d="M0 0h24v24H0V0z" fill="none"></path><path d="M12 10h-2v2H9v-2H7V9h2V7h1v2h2v1z"></path></svg>'}},t={};function i(a){var r=t[a];if(void 0!==r)return r.exports;var s=t[a]={id:a,exports:{}};return e[a].call(s.exports,s,s.exports,i),s.exports}i.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},i.d=(e,t)=>{for(var a in t)i.o(t,a)&&!i.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nc=void 0;var a={};return(()=>{"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}i.r(a),i.d(a,{default:()=>Wa});const r=function(){function i(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i)}var a,r,s;return a=i,s=[{key:"bind",value:function(e,t){return function(){return e.apply(t,arguments)}}},{key:"isObject",value:function(t){return t&&"object"===e(t)&&!Array.isArray(t)&&null!=t}},{key:"is",value:function(e,t){return Object.prototype.toString.call(t)==="[object "+e+"]"}},{key:"listToArray",value:function(e){var t,i=[];for(t=0;t<e.length;t++)i[t]=e[t];return i}},{key:"extend",value:function(e,t){var i=this;"function"!=typeof Object.assign&&(Object.assign=function(e){if(null==e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),i=1;i<arguments.length;i++){var a=arguments[i];if(null!=a)for(var r in a)a.hasOwnProperty(r)&&(t[r]=a[r])}return t});var a=Object.assign({},e);return this.isObject(e)&&this.isObject(t)&&Object.keys(t).forEach((function(r){i.isObject(t[r])&&r in e?a[r]=i.extend(e[r],t[r]):Object.assign(a,function(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}({},r,t[r]))})),a}},{key:"extendArray",value:function(e,t){var a=[];return e.map((function(e){a.push(i.extend(t,e))})),a}},{key:"monthMod",value:function(e){return e%12}},{key:"clone",value:function(t){if(i.is("Array",t)){for(var a=[],r=0;r<t.length;r++)a[r]=this.clone(t[r]);return a}if(i.is("Null",t))return null;if(i.is("Date",t))return t;if("object"===e(t)){var s={};for(var n in t)t.hasOwnProperty(n)&&(s[n]=this.clone(t[n]));return s}return t}},{key:"log10",value:function(e){return Math.log(e)/Math.LN10}},{key:"roundToBase10",value:function(e){return Math.pow(10,Math.floor(Math.log10(e)))}},{key:"roundToBase",value:function(e,t){return Math.pow(t,Math.floor(Math.log(e)/Math.log(t)))}},{key:"parseNumber",value:function(e){return null===e?e:parseFloat(e)}},{key:"stripNumber",value:function(e){var t=arguments.length>1&&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 i="",a=e<0?"-":"",r=t[0].replace(".",""),s=Number(t[1])+1;if(s<0){for(i=a+"0.";s++;)i+="0";return i+r.replace(/^-/,"")}for(s-=r.length;s--;)i+="0";return r+i}},{key:"getDimensions",value:function(e){var t=getComputedStyle(e,null),i=e.clientHeight,a=e.clientWidth;return i-=parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),[a-=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight),i]}},{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 i=e.replace("#","");i=i.match(new RegExp("(.{"+i.length/3+"})","g"));for(var a=0;a<i.length;a++)i[a]=parseInt(1===i[a].length?i[a]+i[a]:i[a],16);return void 0!==t&&i.push(t),"rgba("+i.join(",")+")"}},{key:"getOpacityFromRGBA",value:function(e){return parseFloat(e.replace(/^.*,(.+)\)/,"$1"))}},{key:"rgb2hex",value:function(e){return(e=e.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i))&&4===e.length?"#"+("0"+parseInt(e[1],10).toString(16)).slice(-2)+("0"+parseInt(e[2],10).toString(16)).slice(-2)+("0"+parseInt(e[3],10).toString(16)).slice(-2):""}},{key:"isColorHex",value:function(e){return/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)|(^#[0-9A-F]{8}$)/i.test(e)}},{key:"getPolygonPos",value:function(e,t){for(var i=[],a=2*Math.PI/t,r=0;r<t;r++){var s={};s.x=e*Math.sin(r*a),s.y=-e*Math.cos(r*a),i.push(s)}return i}},{key:"polarToCartesian",value:function(e,t,i,a){var r=(a-90)*Math.PI/180;return{x:e+i*Math.cos(r),y:t+i*Math.sin(r)}}},{key:"escapeString",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"x",i=e.toString().slice();return i.replace(/[` ~!@#$%^&*()|+\=?;:'",.<>{}[\]\\/]/gi,t)}},{key:"negToZero",value:function(e){return e<0?0:e}},{key:"moveIndexInArray",value:function(e,t,i){if(i>=e.length)for(var a=i-e.length+1;a--;)e.push(void 0);return e.splice(i,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 i in t)t.hasOwnProperty(i)&&(e.style.key=t[i])}},{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 i=e.indexOf("rv:");return parseInt(e.substring(i+3,e.indexOf(".",i)),10)}var a=e.indexOf("Edge/");return a>0&&parseInt(e.substring(a+5,e.indexOf(".",a)),10)}},{key:"getGCD",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:7,a=Math.pow(10,i-Math.floor(Math.log10(Math.max(e,t))));for(e=Math.round(Math.abs(e)*a),t=Math.round(Math.abs(t)*a);t;){var r=t;t=e%t,e=r}return e/a}},{key:"getPrimeFactors",value:function(e){for(var t=[],i=2;e>=2;)e%i==0?(t.push(i),e/=i):i++;return t}},{key:"mod",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:7,a=Math.pow(10,i-Math.floor(Math.log10(Math.max(e,t))));return(e=Math.round(Math.abs(e)*a))%(t=Math.round(Math.abs(t)*a))/a}}],(r=[{key:"shadeRGBColor",value:function(e,t){var i=t.split(","),a=e<0?0:255,r=e<0?-1*e:e,s=parseInt(i[0].slice(4),10),n=parseInt(i[1],10),o=parseInt(i[2],10);return"rgb("+(Math.round((a-s)*r)+s)+","+(Math.round((a-n)*r)+n)+","+(Math.round((a-o)*r)+o)+")"}},{key:"shadeHexColor",value:function(e,t){var i=parseInt(t.slice(1),16),a=e<0?0:255,r=e<0?-1*e:e,s=i>>16,n=i>>8&255,o=255&i;return"#"+(16777216+65536*(Math.round((a-s)*r)+s)+256*(Math.round((a-n)*r)+n)+(Math.round((a-o)*r)+o)).toString(16).slice(1)}},{key:"shadeColor",value:function(e,t){return i.isColorHex(t)?this.shadeHexColor(e,t):this.shadeRGBColor(e,t)}}])&&t(a.prototype,r),s&&t(a,s),i}();function s(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var n=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.setEasingFunctions()}var t,i;return t=e,(i=[{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,i,a){e.attr(t).animate(a).attr(i)}},{key:"animateMarker",value:function(e,t,i,a,r,s){t||(t=0),e.attr({r:t,opacity:0}).animate(a,r).attr({r:i,opacity:1}).afterAll((function(){s()}))}},{key:"animateRect",value:function(e,t,i,a,r){e.attr(t).animate(a).attr(i).afterAll((function(){return r()}))}},{key:"animatePathsGradually",value:function(e){var t=e.el,i=e.realIndex,a=e.j,r=e.fill,s=e.pathFrom,n=e.pathTo,o=e.speed,l=e.delay,c=this.w,h=0;c.config.chart.animations.animateGradually.enabled&&(h=c.config.chart.animations.animateGradually.delay),c.config.chart.animations.dynamicAnimation.enabled&&c.globals.dataChanged&&"bar"!==c.config.chart.type&&(h=0),this.morphSVG(t,i,a,"line"!==c.config.chart.type||c.globals.comboCharts?r:"stroke",s,n,o,l*h)}},{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,i,a,s,n,o,l){var c=this,h=this.w;s||(s=e.attr("pathFrom")),n||(n=e.attr("pathTo"));var d=function(e){return"radar"===h.config.chart.type&&(o=1),"M 0 ".concat(h.globals.gridHeight)};(!s||s.indexOf("undefined")>-1||s.indexOf("NaN")>-1)&&(s=d()),(!n||n.indexOf("undefined")>-1||n.indexOf("NaN")>-1)&&(n=d()),h.globals.shouldAnimate||(o=1),e.plot(s).animate(1,h.globals.easing,l).plot(s).animate(o,h.globals.easing,l).plot(n).afterAll((function(){r.isNumber(i)?i===h.globals.series[h.globals.maxValsInArrayIndex].length-2&&h.globals.shouldAnimate&&c.animationCompleted(e):"none"!==a&&h.globals.shouldAnimate&&(!h.globals.comboCharts&&t===h.globals.series.length-1||h.globals.comboCharts)&&c.animationCompleted(e),c.showDelayedElements()}))}}])&&s(t.prototype,i),e}();function o(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const l=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"getDefaultFilter",value:function(e,t){var i=this.w;e.unfilter(!0),(new window.SVG.Filter).size("120%","180%","-5%","-40%"),"none"!==i.config.states.normal.filter?this.applyFilter(e,t,i.config.states.normal.filter.type,i.config.states.normal.filter.value):i.config.chart.dropShadow.enabled&&this.dropShadow(e,i.config.chart.dropShadow,t)}},{key:"addNormalFilter",value:function(e,t){var i=this.w;i.config.chart.dropShadow.enabled&&!e.node.classList.contains("apexcharts-marker")&&this.dropShadow(e,i.config.chart.dropShadow,t)}},{key:"addLightenFilter",value:function(e,t,i){var a=this,r=this.w,s=i.intensity;e.unfilter(!0),new window.SVG.Filter,e.filter((function(e){var i=r.config.chart.dropShadow;(i.enabled?a.addShadow(e,t,i):e).componentTransfer({rgb:{type:"linear",slope:1.5,intercept:s}})})),e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)}},{key:"addDarkenFilter",value:function(e,t,i){var a=this,r=this.w,s=i.intensity;e.unfilter(!0),new window.SVG.Filter,e.filter((function(e){var i=r.config.chart.dropShadow;(i.enabled?a.addShadow(e,t,i):e).componentTransfer({rgb:{type:"linear",slope:s}})})),e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)}},{key:"applyFilter",value:function(e,t,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:.5;switch(i){case"none":this.addNormalFilter(e,t);break;case"lighten":this.addLightenFilter(e,t,{intensity:a});break;case"darken":this.addDarkenFilter(e,t,{intensity:a})}}},{key:"addShadow",value:function(e,t,i){var a,r=this.w,s=i.blur,n=i.top,o=i.left,l=i.color,c=i.opacity;if((null===(a=r.config.chart.dropShadow.enabledOnSeries)||void 0===a?void 0:a.length)>0&&-1===r.config.chart.dropShadow.enabledOnSeries.indexOf(t))return e;var h=e.flood(Array.isArray(l)?l[t]:l,c).composite(e.sourceAlpha,"in").offset(o,n).gaussianBlur(s).merge(e.source);return e.blend(e.source,h)}},{key:"dropShadow",value:function(e,t){var i,a,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,n=t.top,o=t.left,l=t.blur,c=t.color,h=t.opacity,d=t.noUserSpaceOnUse,u=this.w;return e.unfilter(!0),r.isIE()&&"radialBar"===u.config.chart.type||(null===(i=u.config.chart.dropShadow.enabledOnSeries)||void 0===i?void 0:i.length)>0&&-1===(null===(a=u.config.chart.dropShadow.enabledOnSeries)||void 0===a?void 0:a.indexOf(s))||(c=Array.isArray(c)?c[s]:c,e.filter((function(e){var t;t=r.isSafari()||r.isFirefox()||r.isIE()?e.flood(c,h).composite(e.sourceAlpha,"in").offset(o,n).gaussianBlur(l):e.flood(c,h).composite(e.sourceAlpha,"in").offset(o,n).gaussianBlur(l).merge(e.source),e.blend(e.source,t)})),d||e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)),e}},{key:"setSelectionFilter",value:function(e,t,i){var a=this.w;if(void 0!==a.globals.selectedDataPoints[t]&&a.globals.selectedDataPoints[t].indexOf(i)>-1){e.node.setAttribute("selected",!0);var r=a.config.states.active.filter;"none"!==r&&this.applyFilter(e,t,r.type,r.value)}}},{key:"_scaleFilterSize",value:function(e){!function(t){for(var i in t)t.hasOwnProperty(i)&&e.setAttribute(i,t[i])}({width:"200%",height:"200%",x:"-50%",y:"-50%"})}}],i&&o(t.prototype,i),e}();function c(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function h(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?c(Object(i),!0).forEach((function(t){d(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):c(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function d(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function u(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const g=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i,a;return t=e,i=[{key:"roundPathCorners",value:function(e,t){function i(e,t,i){var r=t.x-e.x,s=t.y-e.y,n=Math.sqrt(r*r+s*s);return a(e,t,Math.min(1,i/n))}function a(e,t,i){return{x:e.x+(t.x-e.x)*i,y:e.y+(t.y-e.y)*i}}function r(e,t){e.length>2&&(e[e.length-2]=t.x,e[e.length-1]=t.y)}function s(e){return{x:parseFloat(e[e.length-2]),y:parseFloat(e[e.length-1])}}e.indexOf("NaN")>-1&&(e="");var n=e.split(/[,\s]/).reduce((function(e,t){var i=t.match("([a-zA-Z])(.+)");return i?(e.push(i[1]),e.push(i[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}),[]),o=[];if(n.length>1){var l=s(n[0]),c=null;"Z"==n[n.length-1][0]&&n[0].length>2&&(c=["L",l.x,l.y],n[n.length-1]=c),o.push(n[0]);for(var h=1;h<n.length;h++){var d=o[o.length-1],u=n[h],g=u==c?n[1]:n[h+1];if(g&&d&&d.length>2&&"L"==u[0]&&g.length>2&&"L"==g[0]){var f,p,x=s(d),b=s(u),v=s(g);f=i(b,x,t),p=i(b,v,t),r(u,f),u.origPoint=b,o.push(u);var m=a(f,b,.5),y=a(b,p,.5),w=["C",m.x,m.y,y.x,y.y,p.x,p.y];w.origPoint=b,o.push(w)}else o.push(u)}if(c){var k=s(o[o.length-1]);o.push(["Z"]),r(o[0],k)}}else o=n;return o.reduce((function(e,t){return e+t.join(" ")+" "}),"")}},{key:"drawLine",value:function(e,t,i,a){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"#a8a8a8",s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,n=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:"butt";return this.w.globals.dom.Paper.line().attr({x1:e,y1:t,x2:i,y2:a,stroke:r,"stroke-dasharray":s,"stroke-width":n,"stroke-linecap":o})}},{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,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"#fefefe",n=arguments.length>6&&void 0!==arguments[6]?arguments[6]:1,o=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,h=this.w.globals.dom.Paper.rect();return h.attr({x:e,y:t,width:i>0?i:0,height:a>0?a:0,rx:r,ry:r,opacity:n,"stroke-width":null!==o?o:0,stroke:null!==l?l:"none","stroke-dasharray":c}),h.node.setAttribute("fill",s),h}},{key:"drawPolygon",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"#e1e1e1",i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"none";return this.w.globals.dom.Paper.polygon(e).attr({fill:a,stroke:t,"stroke-width":i})}},{key:"drawCircle",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;e<0&&(e=0);var i=this.w.globals.dom.Paper.circle(2*e);return null!==t&&i.attr(t),i}},{key:"drawPath",value:function(e){var t=e.d,i=void 0===t?"":t,a=e.stroke,r=void 0===a?"#a8a8a8":a,s=e.strokeWidth,n=void 0===s?1:s,o=e.fill,l=e.fillOpacity,c=void 0===l?1:l,h=e.strokeOpacity,d=void 0===h?1:h,u=e.classes,g=e.strokeLinecap,f=void 0===g?null:g,p=e.strokeDashArray,x=void 0===p?0:p,b=this.w;return null===f&&(f=b.config.stroke.lineCap),(i.indexOf("undefined")>-1||i.indexOf("NaN")>-1)&&(i="M 0 ".concat(b.globals.gridHeight)),b.globals.dom.Paper.path(i).attr({fill:o,"fill-opacity":c,stroke:r,"stroke-opacity":d,"stroke-linecap":f,"stroke-width":n,"stroke-dasharray":x,class:u})}},{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 i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=null;return null===i?a=[" L",e,t].join(" "):"H"===i?a=[" H",e].join(" "):"V"===i&&(a=[" V",t].join(" ")),a}},{key:"curve",value:function(e,t,i,a,r,s){return["C",e,t,i,a,r,s].join(" ")}},{key:"quadraticCurve",value:function(e,t,i,a){return["Q",e,t,i,a].join(" ")}},{key:"arc",value:function(e,t,i,a,r,s,n){var o="A";return arguments.length>7&&void 0!==arguments[7]&&arguments[7]&&(o="a"),[o,e,t,i,a,r,s,n].join(" ")}},{key:"renderPaths",value:function(e){var t,i=e.j,a=e.realIndex,r=e.pathFrom,s=e.pathTo,o=e.stroke,c=e.strokeWidth,d=e.strokeLinecap,u=e.fill,g=e.animationDelay,f=e.initialSpeed,p=e.dataChangeSpeed,x=e.className,b=e.shouldClipToGrid,v=void 0===b||b,m=e.bindEventsOnPaths,y=void 0===m||m,w=e.drawShadow,k=void 0===w||w,A=this.w,S=new l(this.ctx),C=new n(this.ctx),P=this.w.config.chart.animations.enabled,L=P&&this.w.config.chart.animations.dynamicAnimation.enabled,O=!!(P&&!A.globals.resized||L&&A.globals.dataChanged&&A.globals.shouldAnimate);O?t=r:(t=s,A.globals.animationEnded=!0);var M,T=A.config.stroke.dashArray;M=Array.isArray(T)?T[a]:A.config.stroke.dashArray;var I=this.drawPath({d:t,stroke:o,strokeWidth:c,fill:u,fillOpacity:1,classes:x,strokeLinecap:d,strokeDashArray:M});if(I.attr("index",a),v&&I.attr({"clip-path":"url(#gridRectMask".concat(A.globals.cuid,")")}),"none"!==A.config.states.normal.filter.type)S.getDefaultFilter(I,a);else if(A.config.chart.dropShadow.enabled&&k){var E=A.config.chart.dropShadow;S.dropShadow(I,E,a)}y&&(I.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,I)),I.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,I)),I.node.addEventListener("mousedown",this.pathMouseDown.bind(this,I))),I.attr({pathTo:s,pathFrom:r});var z={el:I,j:i,realIndex:a,pathFrom:r,pathTo:s,fill:u,strokeWidth:c,delay:g};return!P||A.globals.resized||A.globals.dataChanged?!A.globals.resized&&A.globals.dataChanged||C.showDelayedElements():C.animatePathsGradually(h(h({},z),{},{speed:f})),A.globals.dataChanged&&L&&O&&C.animatePathsGradually(h(h({},z),{},{speed:p})),I}},{key:"drawPattern",value:function(e,t,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"#a8a8a8",r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;return this.w.globals.dom.Paper.pattern(t,i,(function(s){"horizontalLines"===e?s.line(0,0,i,0).stroke({color:a,width:r+1}):"verticalLines"===e?s.line(0,0,0,t).stroke({color:a,width:r+1}):"slantedLines"===e?s.line(0,0,t,i).stroke({color:a,width:r}):"squares"===e?s.rect(t,i).fill("none").stroke({color:a,width:r}):"circles"===e&&s.circle(t).fill("none").stroke({color:a,width:r})}))}},{key:"drawGradient",value:function(e,t,i,a,s){var n,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,l=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,h=arguments.length>8&&void 0!==arguments[8]?arguments[8]:0,d=this.w;t.length<9&&0===t.indexOf("#")&&(t=r.hexToRgba(t,a)),i.length<9&&0===i.indexOf("#")&&(i=r.hexToRgba(i,s));var u=0,g=1,f=1,p=null;null!==l&&(u=void 0!==l[0]?l[0]/100:0,g=void 0!==l[1]?l[1]/100:1,f=void 0!==l[2]?l[2]/100:1,p=void 0!==l[3]?l[3]/100:null);var x=!("donut"!==d.config.chart.type&&"pie"!==d.config.chart.type&&"polarArea"!==d.config.chart.type&&"bubble"!==d.config.chart.type);if(n=null===c||0===c.length?d.globals.dom.Paper.gradient(x?"radial":"linear",(function(e){e.at(u,t,a),e.at(g,i,s),e.at(f,i,s),null!==p&&e.at(p,t,a)})):d.globals.dom.Paper.gradient(x?"radial":"linear",(function(e){(Array.isArray(c[h])?c[h]:c).forEach((function(t){e.at(t.offset/100,t.color,t.opacity)}))})),x){var b=d.globals.gridWidth/2,v=d.globals.gridHeight/2;"bubble"!==d.config.chart.type?n.attr({gradientUnits:"userSpaceOnUse",cx:b,cy:v,r:o}):n.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else"vertical"===e?n.from(0,0).to(0,1):"diagonal"===e?n.from(0,0).to(1,1):"horizontal"===e?n.from(0,1).to(1,1):"diagonal2"===e&&n.from(1,0).to(0,1);return n}},{key:"getTextBasedOnMaxWidth",value:function(e){var t=e.text,i=e.maxWidth,a=e.fontSize,r=e.fontFamily,s=this.getTextRects(t,a,r),n=s.width/t.length,o=Math.floor(i/n);return i<s.width?t.slice(0,o-3)+"...":t}},{key:"drawText",value:function(e){var t=this,i=e.x,a=e.y,r=e.text,s=e.textAnchor,n=e.fontSize,o=e.fontFamily,l=e.fontWeight,c=e.foreColor,d=e.opacity,u=e.maxWidth,g=e.cssClass,f=void 0===g?"":g,p=e.isPlainText,x=void 0===p||p,b=e.dominantBaseline,v=void 0===b?"auto":b,m=this.w;void 0===r&&(r="");var y=r;s||(s="start"),c&&c.length||(c=m.config.chart.foreColor),o=o||m.config.chart.fontFamily,l=l||"regular";var w,k={maxWidth:u,fontSize:n=n||"11px",fontFamily:o};return Array.isArray(r)?w=m.globals.dom.Paper.text((function(e){for(var i=0;i<r.length;i++)y=r[i],u&&(y=t.getTextBasedOnMaxWidth(h({text:r[i]},k))),0===i?e.tspan(y):e.tspan(y).newLine()})):(u&&(y=this.getTextBasedOnMaxWidth(h({text:r},k))),w=x?m.globals.dom.Paper.plain(r):m.globals.dom.Paper.text((function(e){return e.tspan(y)}))),w.attr({x:i,y:a,"text-anchor":s,"dominant-baseline":v,"font-size":n,"font-family":o,"font-weight":l,fill:c,class:"apexcharts-text "+f}),w.node.style.fontFamily=o,w.node.style.opacity=d,w}},{key:"drawXMarker",value:function(e,t,i,a,r){var s=a/2,n="cross"===i?"M ".concat(e-s," ").concat(t-s," L ").concat(e+s," ").concat(t+s," M ").concat(e-s," ").concat(t+s," L ").concat(e+s," ").concat(t-s):"M ".concat(e-s," ").concat(t," L ").concat(e+s," ").concat(t," M ").concat(e," ").concat(t-s," L ").concat(e," ").concat(t+s),o=this.drawPath({d:n,stroke:r.pointStrokeColor,strokeDashArray:r.pointStrokeDashArray,strokeWidth:r.pointStrokeWidth,fill:r.pointFillColor});return o.attr({cx:e,cy:t,class:r.class?r.class:""}),o}},{key:"drawMarker",value:function(e,t,i){e=e||0;var a=i.pSize||0,s=null;if("cross"===(null==i?void 0:i.shape))s=this.drawXMarker(e,t,null==i?void 0:i.shape,1.8*a,h(h({},i),{},{pointStrokeColor:i.pointFillColor}));else if("plus"===(null==i?void 0:i.shape))s=this.drawXMarker(e,t,null==i?void 0:i.shape,2*a,h(h({},i),{},{pointStrokeColor:i.pointFillColor}));else if("line"===(null==i?void 0:i.shape))(s=this.drawLine(e-a,t,e+a,t,i.pointFillColor,i.pointStrokeDashArray,i.pointStrokeWidth,i.pointStrokeLineCap)).attr({cx:e,cy:t,class:i.class?i.class:""});else if("square"===i.shape||"rect"===i.shape){var n=void 0===i.pRadius?a:i.pRadius;null!==t&&a||(a=0,n=0);var o=2*a,l=this.drawRect(o,o,o,o,n);l.attr({x:e-o/2,y:t-o/2,cx:e,cy:t,class:i.class?i.class:"",fill:i.pointFillColor,"fill-opacity":i.pointFillOpacity?i.pointFillOpacity:1,stroke:i.pointStrokeColor,"stroke-width":i.pointStrokeWidth?i.pointStrokeWidth:0,"stroke-opacity":i.pointStrokeOpacity?i.pointStrokeOpacity:1}),s=l}else"circle"!==i.shape&&i.shape||(r.isNumber(t)||(a=0,t=0),s=this.drawCircle(a,{cx:e,cy:t,class:i.class?i.class:"",stroke:i.pointStrokeColor,fill:i.pointFillColor,"fill-opacity":i.pointFillOpacity?i.pointFillOpacity:1,"stroke-width":i.pointStrokeWidth?i.pointStrokeWidth:0,"stroke-opacity":i.pointStrokeOpacity?i.pointStrokeOpacity:1}));return s}},{key:"pathMouseEnter",value:function(e,t){var i=this.w,a=new l(this.ctx),r=parseInt(e.node.getAttribute("index"),10),s=parseInt(e.node.getAttribute("j"),10);if("function"==typeof i.config.chart.events.dataPointMouseEnter&&i.config.chart.events.dataPointMouseEnter(t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}),this.ctx.events.fireEvent("dataPointMouseEnter",[t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}]),("none"===i.config.states.active.filter.type||"true"!==e.node.getAttribute("selected"))&&"none"!==i.config.states.hover.filter.type&&!i.globals.isTouchDevice){var n=i.config.states.hover.filter;a.applyFilter(e,r,n.type,n.value)}}},{key:"pathMouseLeave",value:function(e,t){var i=this.w,a=new l(this.ctx),r=parseInt(e.node.getAttribute("index"),10),s=parseInt(e.node.getAttribute("j"),10);"function"==typeof i.config.chart.events.dataPointMouseLeave&&i.config.chart.events.dataPointMouseLeave(t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}),this.ctx.events.fireEvent("dataPointMouseLeave",[t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}]),"none"!==i.config.states.active.filter.type&&"true"===e.node.getAttribute("selected")||"none"!==i.config.states.hover.filter.type&&a.getDefaultFilter(e,r)}},{key:"pathMouseDown",value:function(e,t){var i=this.w,a=new l(this.ctx),r=parseInt(e.node.getAttribute("index"),10),s=parseInt(e.node.getAttribute("j"),10),n="false";if("true"===e.node.getAttribute("selected")){if(e.node.setAttribute("selected","false"),i.globals.selectedDataPoints[r].indexOf(s)>-1){var o=i.globals.selectedDataPoints[r].indexOf(s);i.globals.selectedDataPoints[r].splice(o,1)}}else{if(!i.config.states.active.allowMultipleDataPointsSelection&&i.globals.selectedDataPoints.length>0){i.globals.selectedDataPoints=[];var c=i.globals.dom.Paper.select(".apexcharts-series path").members,h=i.globals.dom.Paper.select(".apexcharts-series circle, .apexcharts-series rect").members,d=function(e){Array.prototype.forEach.call(e,(function(e){e.node.setAttribute("selected","false"),a.getDefaultFilter(e,r)}))};d(c),d(h)}e.node.setAttribute("selected","true"),n="true",void 0===i.globals.selectedDataPoints[r]&&(i.globals.selectedDataPoints[r]=[]),i.globals.selectedDataPoints[r].push(s)}if("true"===n){var u=i.config.states.active.filter;if("none"!==u)a.applyFilter(e,r,u.type,u.value);else if("none"!==i.config.states.hover.filter&&!i.globals.isTouchDevice){var g=i.config.states.hover.filter;a.applyFilter(e,r,g.type,g.value)}}else"none"!==i.config.states.active.filter.type&&("none"===i.config.states.hover.filter.type||i.globals.isTouchDevice?a.getDefaultFilter(e,r):(g=i.config.states.hover.filter,a.applyFilter(e,r,g.type,g.value)));"function"==typeof i.config.chart.events.dataPointSelection&&i.config.chart.events.dataPointSelection(t,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:r,dataPointIndex:s,w:i}),t&&this.ctx.events.fireEvent("dataPointSelection",[t,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:r,dataPointIndex:s,w:i}])}},{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,i,a){var r=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=this.w,n=this.drawText({x:-200,y:-200,text:e,textAnchor:"start",fontSize:t,fontFamily:i,foreColor:"#fff",opacity:0});a&&n.attr("transform",a),s.globals.dom.Paper.add(n);var o=n.bbox();return r||(o=n.node.getBoundingClientRect()),n.remove(),{width:o.width,height:o.height}}},{key:"placeTextWithEllipsis",value:function(e,t,i){if("function"==typeof e.getComputedTextLength&&(e.textContent=t,t.length>0&&e.getComputedTextLength()>=i/1.1)){for(var a=t.length-3;a>0;a-=3)if(e.getSubStringLength(0,a)<=i/1.1)return void(e.textContent=t.substring(0,a)+"...");e.textContent="."}}}],a=[{key:"setAttrs",value:function(e,t){for(var i in t)t.hasOwnProperty(i)&&e.setAttribute(i,t[i])}}],i&&u(t.prototype,i),a&&u(t,a),e}();function f(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const p=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i,a;return t=e,i=[{key:"getStackedSeriesTotals",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=this.w,i=[];if(0===t.globals.series.length)return i;for(var a=0;a<t.globals.series[t.globals.maxValsInArrayIndex].length;a++){for(var r=0,s=0;s<t.globals.series.length;s++)void 0!==t.globals.series[s][a]&&-1===e.indexOf(s)&&(r+=t.globals.series[s][a]);i.push(r)}return i}},{key:"getSeriesTotalByIndex",value:function(){var e=arguments.length>0&&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,i=[];return t.globals.seriesGroups.forEach((function(a){var r=[];t.config.series.forEach((function(e,i){a.indexOf(t.globals.seriesNames[i])>-1&&r.push(i)}));var s=t.globals.series.map((function(e,t){return-1===r.indexOf(t)?t:-1})).filter((function(e){return-1!==e}));i.push(e.getStackedSeriesTotals(s))})),i}},{key:"setSeriesYAxisMappings",value:function(){var e=this.w.globals,t=this.w.config,i=[],a=[],r=[],s=e.series.length>t.yaxis.length||t.yaxis.some((function(e){return Array.isArray(e.seriesName)}));t.series.forEach((function(e,t){r.push(t),a.push(null)})),t.yaxis.forEach((function(e,t){i[t]=[]}));var n=[];t.yaxis.forEach((function(e,a){var o=!1;if(e.seriesName){var l=[];Array.isArray(e.seriesName)?l=e.seriesName:l.push(e.seriesName),l.forEach((function(e){t.series.forEach((function(t,n){if(t.name===e){var l=n;a===n||s?!s||r.indexOf(n)>-1?i[a].push([a,n]):console.warn("Series '"+t.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(i[n].push([n,a]),l=a),o=!0,-1!==(l=r.indexOf(l))&&r.splice(l,1)}}))}))}o||n.push(a)})),i=i.map((function(e,t){var i=[];return e.forEach((function(e){a[e[1]]=e[0],i.push(e[1])})),i}));for(var o=t.yaxis.length-1,l=0;l<n.length&&(o=n[l],i[o]=[],r);l++){var c=r[0];r.shift(),i[o].push(c),a[c]=o}r.forEach((function(e){i[o].push(e),a[e]=o})),e.seriesYAxisMap=i.map((function(e){return e})),e.seriesYAxisReverseMap=a.map((function(e){return e})),e.seriesYAxisMap.forEach((function(e,i){e.forEach((function(e){t.series[e]&&void 0===t.series[e].group&&(t.series[e].group="apexcharts-axis-".concat(i.toString()))}))}))}},{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,i){return e===i[0]}))}},{key:"getCategoryLabels",value:function(e){var t=this.w,i=e.slice();return t.config.xaxis.convertedCatToNumeric&&(i=e.map((function(e,i){return t.config.xaxis.labels.formatter(e-t.globals.minX+1)}))),i}},{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 i=0;if(Array.isArray(e))for(var a=0;a<e.length;a++)i+=e[a];else i+=e;return i}))}},{key:"getSeriesTotalsXRange",value:function(e,t){var i=this.w;return i.globals.series.map((function(a,r){for(var s=0,n=0;n<a.length;n++)i.globals.seriesX[r][n]>e&&i.globals.seriesX[r][n]<t&&(s+=a[n]);return s}))}},{key:"getPercentSeries",value:function(){var e=this.w;e.globals.seriesPercent=e.globals.series.map((function(t,i){var a=[];if(Array.isArray(t))for(var r=0;r<t.length;r++){var s=e.globals.stackedSeriesTotals[r],n=0;s&&(n=100*t[r]/s),a.push(n)}else{var o=100*t/e.globals.seriesTotals.reduce((function(e,t){return e+t}),0);a.push(o)}return a}))}},{key:"getCalculatedRatios",value:function(){var e,t,i,a=this,r=this.w,s=r.globals,n=[],o=0,l=[],c=.1,h=0;if(s.yRange=[],s.isMultipleYAxis)for(var d=0;d<s.minYArr.length;d++)s.yRange.push(Math.abs(s.minYArr[d]-s.maxYArr[d])),l.push(0);else s.yRange.push(Math.abs(s.minY-s.maxY));s.xRange=Math.abs(s.maxX-s.minX),s.zRange=Math.abs(s.maxZ-s.minZ);for(var u=0;u<s.yRange.length;u++)n.push(s.yRange[u]/s.gridHeight);if(t=s.xRange/s.gridWidth,e=s.yRange/s.gridWidth,i=s.xRange/s.gridHeight,(o=s.zRange/s.gridHeight*16)||(o=1),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(s.hasNegs=!0),r.globals.seriesYAxisReverseMap.length>0){var g=function(e,t){var i=r.config.yaxis[r.globals.seriesYAxisReverseMap[t]],s=e<0?-1:1;return e=Math.abs(e),i.logarithmic&&(e=a.getBaseLog(i.logBase,e)),-s*e/n[t]};if(s.isMultipleYAxis){l=[];for(var f=0;f<n.length;f++)l.push(g(s.minYArr[f],f))}else(l=[]).push(g(s.minY,0)),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(c=-s.minY/e,h=s.minX/t)}else(l=[]).push(0),c=0,h=0;return{yRatio:n,invertedYRatio:e,zRatio:o,xRatio:t,invertedXRatio:i,baseLineInvertedY:c,baseLineY:l,baseLineX:h}}},{key:"getLogSeries",value:function(e){var t=this,i=this.w;return i.globals.seriesLog=e.map((function(e,a){var r=i.globals.seriesYAxisReverseMap[a];return i.config.yaxis[r]&&i.config.yaxis[r].logarithmic?e.map((function(e){return null===e?null:t.getLogVal(i.config.yaxis[r].logBase,e,a)})):e})),i.globals.invalidLogScale?e:i.globals.seriesLog}},{key:"getBaseLog",value:function(e,t){return Math.log(t)/Math.log(e)}},{key:"getLogVal",value:function(e,t,i){if(t<=0)return 0;var a=this.w,r=0===a.globals.minYArr[i]?-1:this.getBaseLog(e,a.globals.minYArr[i]),s=(0===a.globals.maxYArr[i]?0:this.getBaseLog(e,a.globals.maxYArr[i]))-r;return t<1?t/s:(this.getBaseLog(e,t)-r)/s}},{key:"getLogYRatios",value:function(e){var t=this,i=this.w,a=this.w.globals;return a.yLogRatio=e.slice(),a.logYRange=a.yRange.map((function(e,r){var s=i.globals.seriesYAxisReverseMap[r];if(i.config.yaxis[s]&&t.w.config.yaxis[s].logarithmic){var n,o=-Number.MAX_VALUE,l=Number.MIN_VALUE;return a.seriesLog.forEach((function(e,t){e.forEach((function(e){i.config.yaxis[t]&&i.config.yaxis[t].logarithmic&&(o=Math.max(e,o),l=Math.min(e,l))}))})),n=Math.pow(a.yRange[r],Math.abs(l-o)/a.yRange[r]),a.yLogRatio[r]=n/a.gridHeight,n}})),a.invalidLogScale?e.slice():a.yLogRatio}},{key:"drawSeriesByGroup",value:function(e,t,i,a){var r=this.w,s=[];return e.series.length>0&&t.forEach((function(t){var n=[],o=[];e.i.forEach((function(i,a){r.config.series[i].group===t&&(n.push(e.series[a]),o.push(i))})),n.length>0&&s.push(a.draw(n,i,o))})),s}}],a=[{key:"checkComboSeries",value:function(e,t){var i=!1,a=0,r=0;return void 0===t&&(t="line"),e.length&&void 0!==e[0].type&&e.forEach((function(e){"bar"!==e.type&&"column"!==e.type&&"candlestick"!==e.type&&"boxPlot"!==e.type||a++,void 0!==e.type&&e.type!==t&&r++})),r>0&&(i=!0),{comboBarCount:a,comboCharts:i}}},{key:"extendArrayProps",value:function(e,t,i){var a,r,s,n,o,l;return null!==(a=t)&&void 0!==a&&a.yaxis&&(t=e.extendYAxis(t,i)),null!==(r=t)&&void 0!==r&&r.annotations&&(t.annotations.yaxis&&(t=e.extendYAxisAnnotations(t)),null!==(s=t)&&void 0!==s&&null!==(n=s.annotations)&&void 0!==n&&n.xaxis&&(t=e.extendXAxisAnnotations(t)),null!==(o=t)&&void 0!==o&&null!==(l=o.annotations)&&void 0!==l&&l.points&&(t=e.extendPointAnnotations(t))),t}}],i&&f(t.prototype,i),a&&f(t,a),e}();function x(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var b=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t}var t,i;return t=e,i=[{key:"setOrientations",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.w;if("vertical"===e.label.orientation){var a=null!==t?t:0,r=i.globals.dom.baseEl.querySelector(".apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='".concat(a,"']"));if(null!==r){var s=r.getBoundingClientRect();r.setAttribute("x",parseFloat(r.getAttribute("x"))-s.height+4),"top"===e.label.position?r.setAttribute("y",parseFloat(r.getAttribute("y"))+s.width):r.setAttribute("y",parseFloat(r.getAttribute("y"))-s.width);var n=this.annoCtx.graphics.rotateAroundCenter(r),o=n.x,l=n.y;r.setAttribute("transform","rotate(-90 ".concat(o," ").concat(l,")"))}}}},{key:"addBackgroundToAnno",value:function(e,t){var i=this.w;if(!e||void 0===t.label.text||void 0!==t.label.text&&!String(t.label.text).trim())return null;var a=i.globals.dom.baseEl.querySelector(".apexcharts-grid").getBoundingClientRect(),r=e.getBoundingClientRect(),s=t.label.style.padding.left,n=t.label.style.padding.right,o=t.label.style.padding.top,l=t.label.style.padding.bottom;"vertical"===t.label.orientation&&(o=t.label.style.padding.left,l=t.label.style.padding.right,s=t.label.style.padding.top,n=t.label.style.padding.bottom);var c=r.left-a.left-s,h=r.top-a.top-o,d=this.annoCtx.graphics.drawRect(c-i.globals.barPadForNumericAxis,h,r.width+s+n,r.height+o+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,i=function(i,a,r){var s=t.globals.dom.baseEl.querySelector(".apexcharts-".concat(r,"-annotations .apexcharts-").concat(r,"-annotation-label[rel='").concat(a,"']"));if(s){var n=s.parentNode,o=e.addBackgroundToAnno(s,i);o&&(n.insertBefore(o.node,s),i.label.mouseEnter&&o.node.addEventListener("mouseenter",i.label.mouseEnter.bind(e,i)),i.label.mouseLeave&&o.node.addEventListener("mouseleave",i.label.mouseLeave.bind(e,i)),i.label.click&&o.node.addEventListener("click",i.label.click.bind(e,i)))}};t.config.annotations.xaxis.map((function(e,t){i(e,t,"xaxis")})),t.config.annotations.yaxis.map((function(e,t){i(e,t,"yaxis")})),t.config.annotations.points.map((function(e,t){i(e,t,"point")}))}},{key:"getY1Y2",value:function(e,t){var i,a="y1"===e?t.y:t.y2,r=!1,s=this.w;if(this.annoCtx.invertAxis){var n=s.globals.labels;s.config.xaxis.convertedCatToNumeric&&(n=s.globals.categoryLabels);var o=n.indexOf(a),l=s.globals.dom.baseEl.querySelector(".apexcharts-yaxis-texts-g text:nth-child("+(o+1)+")");i=l?parseFloat(l.getAttribute("y")):(s.globals.gridHeight/n.length-1)*(o+1)-s.globals.barHeight,void 0!==t.seriesIndex&&s.globals.barHeight&&(i=i-s.globals.barHeight/2*(s.globals.series.length-1)+s.globals.barHeight*t.seriesIndex)}else{var c,h=s.globals.seriesYAxisMap[t.yAxisIndex][0];(c=s.config.yaxis[t.yAxisIndex].logarithmic?(a=new p(this.annoCtx.ctx).getLogVal(s.config.yaxis[t.yAxisIndex].logBase,a,h))/s.globals.yLogRatio[h]:(a-s.globals.minYArr[h])/(s.globals.yRange[h]/s.globals.gridHeight))>s.globals.gridHeight?(c=s.globals.gridHeight,r=!0):c<0&&(c=0,r=!0),i=s.globals.gridHeight-c,!t.marker||void 0!==t.y&&null!==t.y||(i=0),s.config.yaxis[t.yAxisIndex]&&s.config.yaxis[t.yAxisIndex].reversed&&(i=c)}return"string"==typeof a&&a.indexOf("px")>-1&&(i=parseFloat(a)),{yP:i,clipped:r}}},{key:"getX1X2",value:function(e,t){var i,a="x1"===e?t.x:t.x2,r=this.w,s=this.annoCtx.invertAxis?r.globals.minY:r.globals.minX,n=this.annoCtx.invertAxis?r.globals.maxY:r.globals.maxX,o=this.annoCtx.invertAxis?r.globals.yRange[0]:r.globals.xRange,l=!1;return i=this.annoCtx.inversedReversedAxis?(n-a)/(o/r.globals.gridWidth):(a-s)/(o/r.globals.gridWidth),"category"!==r.config.xaxis.type&&!r.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||r.globals.dataFormatXNumeric||r.config.chart.sparkline.enabled||(i=this.getStringX(a)),"string"==typeof a&&a.indexOf("px")>-1&&(i=parseFloat(a)),null==a&&t.marker&&(i=r.globals.gridWidth),void 0!==t.seriesIndex&&r.globals.barWidth&&!this.annoCtx.invertAxis&&(i=i-r.globals.barWidth/2*(r.globals.series.length-1)+r.globals.barWidth*t.seriesIndex),i>r.globals.gridWidth?(i=r.globals.gridWidth,l=!0):i<0&&(i=0,l=!0),{x:i,clipped:l}}},{key:"getStringX",value:function(e){var t=this.w,i=e;t.config.xaxis.convertedCatToNumeric&&t.globals.categoryLabels.length&&(e=t.globals.categoryLabels.indexOf(e)+1);var a=t.globals.labels.indexOf(e),r=t.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g text:nth-child("+(a+1)+")");return r&&(i=parseFloat(r.getAttribute("x"))),i}}],i&&x(t.prototype,i),e}();function v(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var m=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t,this.invertAxis=this.annoCtx.invertAxis,this.helpers=new b(this.annoCtx)}var t,i;return t=e,(i=[{key:"addXaxisAnnotation",value:function(e,t,i){var a,s=this.w,n=this.helpers.getX1X2("x1",e),o=n.x,l=n.clipped,c=!0,h=e.label.text,d=e.strokeDashArray;if(r.isNumber(o)){if(null===e.x2||void 0===e.x2){if(!l){var u=this.annoCtx.graphics.drawLine(o+e.offsetX,0+e.offsetY,o+e.offsetX,s.globals.gridHeight+e.offsetY,e.borderColor,d,e.borderWidth);t.appendChild(u.node),e.id&&u.node.classList.add(e.id)}}else{var g=this.helpers.getX1X2("x2",e);if(a=g.x,c=g.clipped,!l||!c){if(a<o){var f=o;o=a,a=f}var p=this.annoCtx.graphics.drawRect(o+e.offsetX,0+e.offsetY,a-o,s.globals.gridHeight+e.offsetY,0,e.fillColor,e.opacity,1,e.borderColor,d);p.node.classList.add("apexcharts-annotation-rect"),p.attr("clip-path","url(#gridRectMask".concat(s.globals.cuid,")")),t.appendChild(p.node),e.id&&p.node.classList.add(e.id)}}if(!l||!c){var x=this.annoCtx.graphics.getTextRects(h,parseFloat(e.label.style.fontSize)),b="top"===e.label.position?4:"center"===e.label.position?s.globals.gridHeight/2+("vertical"===e.label.orientation?x.width/2:0):s.globals.gridHeight,v=this.annoCtx.graphics.drawText({x:o+e.label.offsetX,y:b+e.label.offsetY-("vertical"===e.label.orientation?"top"===e.label.position?x.width/2-12:-x.width/2:0),text:h,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-xaxis-annotation-label ".concat(e.label.style.cssClass," ").concat(e.id?e.id:"")});v.attr({rel:i}),t.appendChild(v.node),this.annoCtx.helpers.setOrientations(e,i)}}}},{key:"drawXAxisAnnotations",value:function(){var e=this,t=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-xaxis-annotations"});return t.config.annotations.xaxis.map((function(t,a){e.addXaxisAnnotation(t,i.node,a)})),i}}])&&v(t.prototype,i),e}();function y(e){return function(e){if(Array.isArray(e))return w(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return w(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?w(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function k(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const A=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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]}var t,i;return t=e,(i=[{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 i=Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "));return this.getTimeStamp(i)}},{key:"parseDateWithTimezone",value:function(e){return Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "))}},{key:"formatDate",value:function(e,t){var i=this.w.globals.locale,a=this.w.config.xaxis.labels.datetimeUTC,r=["\0"].concat(y(i.months)),s=[""].concat(y(i.shortMonths)),n=[""].concat(y(i.days)),o=[""].concat(y(i.shortDays));function l(e,t){var i=e+"";for(t=t||2;i.length<t;)i="0"+i;return i}var c=a?e.getUTCFullYear():e.getFullYear();t=(t=(t=t.replace(/(^|[^\\])yyyy+/g,"$1"+c)).replace(/(^|[^\\])yy/g,"$1"+c.toString().substr(2,2))).replace(/(^|[^\\])y/g,"$1"+c);var h=(a?e.getUTCMonth():e.getMonth())+1;t=(t=(t=(t=t.replace(/(^|[^\\])MMMM+/g,"$1"+r[0])).replace(/(^|[^\\])MMM/g,"$1"+s[0])).replace(/(^|[^\\])MM/g,"$1"+l(h))).replace(/(^|[^\\])M/g,"$1"+h);var d=a?e.getUTCDate():e.getDate();t=(t=(t=(t=t.replace(/(^|[^\\])dddd+/g,"$1"+n[0])).replace(/(^|[^\\])ddd/g,"$1"+o[0])).replace(/(^|[^\\])dd/g,"$1"+l(d))).replace(/(^|[^\\])d/g,"$1"+d);var u=a?e.getUTCHours():e.getHours(),g=u>12?u-12:0===u?12:u;t=(t=(t=(t=t.replace(/(^|[^\\])HH+/g,"$1"+l(u))).replace(/(^|[^\\])H/g,"$1"+u)).replace(/(^|[^\\])hh+/g,"$1"+l(g))).replace(/(^|[^\\])h/g,"$1"+g);var f=a?e.getUTCMinutes():e.getMinutes();t=(t=t.replace(/(^|[^\\])mm+/g,"$1"+l(f))).replace(/(^|[^\\])m/g,"$1"+f);var p=a?e.getUTCSeconds():e.getSeconds();t=(t=t.replace(/(^|[^\\])ss+/g,"$1"+l(p))).replace(/(^|[^\\])s/g,"$1"+p);var x=a?e.getUTCMilliseconds():e.getMilliseconds();t=t.replace(/(^|[^\\])fff+/g,"$1"+l(x,3)),x=Math.round(x/10),t=t.replace(/(^|[^\\])ff/g,"$1"+l(x)),x=Math.round(x/10);var b=u<12?"AM":"PM";t=(t=(t=t.replace(/(^|[^\\])f/g,"$1"+x)).replace(/(^|[^\\])TT+/g,"$1"+b)).replace(/(^|[^\\])T/g,"$1"+b.charAt(0));var v=b.toLowerCase();t=(t=t.replace(/(^|[^\\])tt+/g,"$1"+v)).replace(/(^|[^\\])t/g,"$1"+v.charAt(0));var m=-e.getTimezoneOffset(),w=a||!m?"Z":m>0?"+":"-";if(!a){var k=(m=Math.abs(m))%60;w+=l(Math.floor(m/60))+":"+l(k)}t=t.replace(/(^|[^\\])K/g,"$1"+w);var A=(a?e.getUTCDay():e.getDay())+1;return(t=(t=(t=(t=t.replace(new RegExp(n[0],"g"),n[A])).replace(new RegExp(o[0],"g"),o[A])).replace(new RegExp(r[0],"g"),r[h])).replace(new RegExp(s[0],"g"),s[h])).replace(/\\(.)/g,"$1")}},{key:"getTimeUnitsfromTimestamp",value:function(e,t,i){var a=this.w;void 0!==a.config.xaxis.min&&(e=a.config.xaxis.min),void 0!==a.config.xaxis.max&&(t=a.config.xaxis.max);var r=this.getDate(e),s=this.getDate(t),n=this.formatDate(r,"yyyy MM dd HH mm ss fff").split(" "),o=this.formatDate(s,"yyyy MM dd HH mm ss fff").split(" ");return{minMillisecond:parseInt(n[6],10),maxMillisecond:parseInt(o[6],10),minSecond:parseInt(n[5],10),maxSecond:parseInt(o[5],10),minMinute:parseInt(n[4],10),maxMinute:parseInt(o[4],10),minHour:parseInt(n[3],10),maxHour:parseInt(o[3],10),minDate:parseInt(n[2],10),maxDate:parseInt(o[2],10),minMonth:parseInt(n[1],10)-1,maxMonth:parseInt(o[1],10)-1,minYear:parseInt(n[0],10),maxYear:parseInt(o[0],10)}}},{key:"isLeapYear",value:function(e){return e%4==0&&e%100!=0||e%400==0}},{key:"calculcateLastDaysOfMonth",value:function(e,t,i){return this.determineDaysOfMonths(e,t)-i}},{key:"determineDaysOfYear",value:function(e){var t=365;return this.isLeapYear(e)&&(t=366),t}},{key:"determineRemainingDaysOfYear",value:function(e,t,i){var a=this.daysCntOfYear[t]+i;return t>1&&this.isLeapYear()&&a++,a}},{key:"determineDaysOfMonths",value:function(e,t){var i=30;switch(e=r.monthMod(e),!0){case this.months30.indexOf(e)>-1:2===e&&(i=this.isLeapYear(t)?29:28);break;case this.months31.indexOf(e)>-1:default:i=31}return i}}])&&k(t.prototype,i),e}();function S(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const C=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.tooltipKeyFormat="dd MMM"}var t,i;return t=e,(i=[{key:"xLabelFormat",value:function(e,t,i,a){var r=this.w;if("datetime"===r.config.xaxis.type&&void 0===r.config.xaxis.labels.formatter&&void 0===r.config.tooltip.x.formatter){var s=new A(this.ctx);return s.formatDate(s.getDate(t),r.config.tooltip.x.format)}return e(t,i,a)}},{key:"defaultGeneralFormatter",value:function(e){return Array.isArray(e)?e.map((function(e){return e})):e}},{key:"defaultYFormatter",value:function(e,t,i){var a=this.w;if(r.isNumber(e))if(0!==a.globals.yValueDecimal)e=e.toFixed(void 0!==t.decimalsInFloat?t.decimalsInFloat:a.globals.yValueDecimal);else{var s=e.toFixed(0);e=e==s?s:e.toFixed(1)}return 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(r.isNumber(e)){if(!t.config.xaxis.convertedCatToNumeric&&"numeric"===t.config.xaxis.type){if(r.isNumber(t.config.xaxis.decimalsInFloat))return e.toFixed(t.config.xaxis.decimalsInFloat);var i=t.globals.maxX-t.globals.minX;return i>0&&i<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(i,a){void 0!==i.labels.formatter?t.globals.yLabelFormatters[a]=i.labels.formatter:t.globals.yLabelFormatters[a]=function(r){return t.globals.xyCharts?Array.isArray(r)?r.map((function(t){return e.defaultYFormatter(t,i,a)})):e.defaultYFormatter(r,i,a):r}})),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}}}])&&S(t.prototype,i),e}();function P(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var L=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"getLabel",value:function(e,t,i,a){var r,s,n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"12px",l=!(arguments.length>6&&void 0!==arguments[6])||arguments[6],c=this.w,h=void 0===e[a]?"":e[a],d=h,u=c.globals.xLabelFormatter,f=c.config.xaxis.labels.formatter,p=!1,x=new C(this.ctx),b=h;l&&(d=x.xLabelFormat(u,h,b,{i:a,dateFormatter:new A(this.ctx).formatDate,w:c}),void 0!==f&&(d=f(h,e[a],{i:a,dateFormatter:new A(this.ctx).formatDate,w:c}))),t.length>0?(r=t[a].unit,s=null,t.forEach((function(e){"month"===e.unit?s="year":"day"===e.unit?s="month":"hour"===e.unit?s="day":"minute"===e.unit&&(s="hour")})),p=s===r,i=t[a].position,d=t[a].value):"datetime"===c.config.xaxis.type&&void 0===f&&(d=""),void 0===d&&(d=""),d=Array.isArray(d)?d:d.toString();var v,m=new g(this.ctx);v=c.globals.rotateXLabels&&l?m.getTextRects(d,parseInt(o,10),null,"rotate(".concat(c.config.xaxis.labels.rotate," 0 0)"),!1):m.getTextRects(d,parseInt(o,10));var y=!c.config.xaxis.labels.showDuplicates&&this.ctx.timeScale;return!Array.isArray(d)&&("NaN"===String(d)||n.indexOf(d)>=0&&y)&&(d=""),{x:i,text:d,textRect:v,isBold:p}}},{key:"checkLabelBasedOnTickamount",value:function(e,t,i){var a=this.w,r=a.config.xaxis.tickAmount;return"dataPoints"===r&&(r=Math.round(a.globals.gridWidth/120)),r>i||e%Math.round(i/(r+1))==0||(t.text=""),t}},{key:"checkForOverflowingLabels",value:function(e,t,i,a,r){var s=this.w;if(0===e&&s.globals.skipFirstTimelinelabel&&(t.text=""),e===i-1&&s.globals.skipLastTimelinelabel&&(t.text=""),s.config.xaxis.labels.hideOverlappingLabels&&a.length>0){var n=r[r.length-1];t.x<n.textRect.width/(s.globals.rotateXLabels?Math.abs(s.config.xaxis.labels.rotate)/12:1.01)+n.x&&(t.text="")}return t}},{key:"checkForReversedLabels",value:function(e,t){var i=this.w;return i.config.yaxis[e]&&i.config.yaxis[e].reversed&&t.reverse(),t}},{key:"yAxisAllSeriesCollapsed",value:function(e){var t=this.w.globals;return!t.seriesYAxisMap[e].some((function(e){return-1===t.collapsedSeriesIndices.indexOf(e)}))}},{key:"translateYAxisIndex",value:function(e){var t=this.w,i=t.globals,a=t.config.yaxis;return i.series.length>a.length||a.some((function(e){return Array.isArray(e.seriesName)}))?e:i.seriesYAxisReverseMap[e]}},{key:"isYAxisHidden",value:function(e){var t=this.w,i=t.config.yaxis[e];if(!i.show||this.yAxisAllSeriesCollapsed(e))return!0;if(!i.showForNullSeries){var a=t.globals.seriesYAxisMap[e],r=new p(this.ctx);return a.every((function(e){return r.isSeriesNull(e)}))}return!1}},{key:"getYAxisForeColor",value:function(e,t){var i=this.w;return Array.isArray(e)&&i.globals.yAxisScale[t]&&this.ctx.theme.pushExtraColors(e,i.globals.yAxisScale[t].result.length,!1),e}},{key:"drawYAxisTicks",value:function(e,t,i,a,r,s,n){var o=this.w,l=new g(this.ctx),c=o.globals.translateY+o.config.yaxis[r].labels.offsetY;if(o.globals.isBarHorizontal?c=0:"heatmap"===o.config.chart.type&&(c+=s/2),a.show&&t>0){!0===o.config.yaxis[r].opposite&&(e+=a.width);for(var h=t;h>=0;h--){var d=l.drawLine(e+i.offsetX-a.width+a.offsetX,c+a.offsetY,e+i.offsetX+a.offsetX,c+a.offsetY,a.color);n.add(d),c+=s}}}}],i&&P(t.prototype,i),e}();function O(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var M=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t,this.helpers=new b(this.annoCtx),this.axesUtils=new L(this.annoCtx)}var t,i;return t=e,(i=[{key:"addYaxisAnnotation",value:function(e,t,i){var a,r=this.w,s=e.strokeDashArray,n=this.helpers.getY1Y2("y1",e),o=n.yP,l=n.clipped,c=!0,h=!1,d=e.label.text;if(null===e.y2||void 0===e.y2){if(!l){h=!0;var u=this.annoCtx.graphics.drawLine(0+e.offsetX,o+e.offsetY,this._getYAxisAnnotationWidth(e),o+e.offsetY,e.borderColor,s,e.borderWidth);t.appendChild(u.node),e.id&&u.node.classList.add(e.id)}}else{if(a=(n=this.helpers.getY1Y2("y2",e)).yP,c=n.clipped,a>o){var g=o;o=a,a=g}if(!l||!c){h=!0;var f=this.annoCtx.graphics.drawRect(0+e.offsetX,a+e.offsetY,this._getYAxisAnnotationWidth(e),o-a,0,e.fillColor,e.opacity,1,e.borderColor,s);f.node.classList.add("apexcharts-annotation-rect"),f.attr("clip-path","url(#gridRectMask".concat(r.globals.cuid,")")),t.appendChild(f.node),e.id&&f.node.classList.add(e.id)}}if(h){var p="right"===e.label.position?r.globals.gridWidth:"center"===e.label.position?r.globals.gridWidth/2:0,x=this.annoCtx.graphics.drawText({x:p+e.label.offsetX,y:(null!=a?a:o)+e.label.offsetY-3,text:d,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:"")});x.attr({rel:i}),t.appendChild(x.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,i=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return t.config.annotations.yaxis.forEach((function(t,a){t.yAxisIndex=e.axesUtils.translateYAxisIndex(t.yAxisIndex),e.axesUtils.isYAxisHidden(t.yAxisIndex)&&e.axesUtils.yAxisAllSeriesCollapsed(t.yAxisIndex)||e.addYaxisAnnotation(t,i.node,a)})),i}}])&&O(t.prototype,i),e}();function T(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var I=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t,this.helpers=new b(this.annoCtx)}var t,i;return t=e,(i=[{key:"addPointAnnotation",value:function(e,t,i){if(!(this.w.globals.collapsedSeriesIndices.indexOf(e.seriesIndex)>-1)){var a=this.helpers.getX1X2("x1",e),s=a.x,n=a.clipped,o=(a=this.helpers.getY1Y2("y1",e)).yP,l=a.clipped;if(r.isNumber(s)&&!l&&!n){var c={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:"")},h=this.annoCtx.graphics.drawMarker(s+e.marker.offsetX,o+e.marker.offsetY,c);t.appendChild(h.node);var d=e.label.text?e.label.text:"",u=this.annoCtx.graphics.drawText({x:s+e.label.offsetX,y:o+e.label.offsetY-e.marker.size-parseFloat(e.label.style.fontSize)/1.6,text:d,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(u.attr({rel:i}),t.appendChild(u.node),e.customSVG.SVG){var g=this.annoCtx.graphics.group({class:"apexcharts-point-annotations-custom-svg "+e.customSVG.cssClass});g.attr({transform:"translate(".concat(s+e.customSVG.offsetX,", ").concat(o+e.customSVG.offsetY,")")}),g.node.innerHTML=e.customSVG.SVG,t.appendChild(g.node)}if(e.image.path){var f=e.image.width?e.image.width:20,p=e.image.height?e.image.height:20;h=this.annoCtx.addImage({x:s+e.image.offsetX-f/2,y:o+e.image.offsetY-p/2,width:f,height:p,path:e.image.path,appendTo:".apexcharts-point-annotations"})}e.mouseEnter&&h.node.addEventListener("mouseenter",e.mouseEnter.bind(this,e)),e.mouseLeave&&h.node.addEventListener("mouseleave",e.mouseLeave.bind(this,e)),e.click&&h.node.addEventListener("click",e.click.bind(this,e))}}}},{key:"drawPointAnnotations",value:function(){var e=this,t=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-point-annotations"});return t.config.annotations.points.map((function(t,a){e.addPointAnnotation(t,i.node,a)})),i}}])&&T(t.prototype,i),e}();const E=JSON.parse('{"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 z(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var X=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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}}var t,i;return t=e,(i=[{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:"",locales:[E],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",categoryFormatter:void 0,valueFormatter:void 0},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:{line:{isSlopeChart:!1},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,borderRadius:4,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:{size:6,fillColors:void 0,strokeWidth:2,shape:void 0,radius:2,offsetX:0,offsetY:0,customHTML:void 0,onClick:void 0},itemMargin:{horizontal:5,vertical:4},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",radius:2,offsetX:0,offsetY:0,showNullDataPoints:!0,onClick:void 0,onDblClick:void 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:!1,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:"",palette:"palette1",monochrome:{enabled:!1,color:"#008FFB",shadeTo:"light",shadeIntensity:.65}}}}}])&&z(t.prototype,i),e}();function Y(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var R=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.graphics=new g(this.ctx),this.w.globals.isBarHorizontal&&(this.invertAxis=!0),this.helpers=new b(this),this.xAxisAnnotations=new m(this),this.yAxisAnnotations=new M(this),this.pointsAnnotations=new I(this),this.w.globals.isBarHorizontal&&this.w.config.yaxis[0].reversed&&(this.inversedReversedAxis=!0),this.xDivision=this.w.globals.gridWidth/this.w.globals.dataPoints}var t,i;return t=e,(i=[{key:"drawAxesAnnotations",value:function(){var e=this.w;if(e.globals.axisCharts){for(var t=this.yAxisAnnotations.drawYAxisAnnotations(),i=this.xAxisAnnotations.drawXAxisAnnotations(),a=this.pointsAnnotations.drawPointAnnotations(),r=e.config.chart.animations.enabled,s=[t,i,a],n=[i.node,t.node,a.node],o=0;o<3;o++)e.globals.dom.elGraphical.add(s[o]),!r||e.globals.resized||e.globals.dataChanged||"scatter"!==e.config.chart.type&&"bubble"!==e.config.chart.type&&e.globals.dataPoints>1&&n[o].classList.add("apexcharts-element-hidden"),e.globals.delayedElements.push({el:n[o],index:0});this.helpers.annotationsBackground()}}},{key:"drawImageAnnos",value:function(){var e=this;this.w.config.annotations.images.map((function(t,i){e.addImage(t,i)}))}},{key:"drawTextAnnos",value:function(){var e=this;this.w.config.annotations.texts.map((function(t,i){e.addText(t,i)}))}},{key:"addXaxisAnnotation",value:function(e,t,i){this.xAxisAnnotations.addXaxisAnnotation(e,t,i)}},{key:"addYaxisAnnotation",value:function(e,t,i){this.yAxisAnnotations.addYaxisAnnotation(e,t,i)}},{key:"addPointAnnotation",value:function(e,t,i){this.pointsAnnotations.addPointAnnotation(e,t,i)}},{key:"addText",value:function(e,t){var i=e.x,a=e.y,r=e.text,s=e.textAnchor,n=e.foreColor,o=e.fontSize,l=e.fontFamily,c=e.fontWeight,h=e.cssClass,d=e.backgroundColor,u=e.borderWidth,g=e.strokeDashArray,f=e.borderRadius,p=e.borderColor,x=e.appendTo,b=void 0===x?".apexcharts-svg":x,v=e.paddingLeft,m=void 0===v?4:v,y=e.paddingRight,w=void 0===y?4:y,k=e.paddingBottom,A=void 0===k?2:k,S=e.paddingTop,C=void 0===S?2:S,P=this.w,L=this.graphics.drawText({x:i,y:a,text:r,textAnchor:s||"start",fontSize:o||"12px",fontWeight:c||"regular",fontFamily:l||P.config.chart.fontFamily,foreColor:n||P.config.chart.foreColor,cssClass:h}),O=P.globals.dom.baseEl.querySelector(b);O&&O.appendChild(L.node);var M=L.bbox();if(r){var T=this.graphics.drawRect(M.x-m,M.y-C,M.width+m+w,M.height+A+C,f,d||"transparent",1,u,p,g);O.insertBefore(T.node,L.node)}}},{key:"addImage",value:function(e,t){var i=this.w,a=e.path,r=e.x,s=void 0===r?0:r,n=e.y,o=void 0===n?0:n,l=e.width,c=void 0===l?20:l,h=e.height,d=void 0===h?20:h,u=e.appendTo,g=void 0===u?".apexcharts-svg":u,f=i.globals.dom.Paper.image(a);f.size(c,d).move(s,o);var p=i.globals.dom.baseEl.querySelector(g);return p&&p.appendChild(f.node),f}},{key:"addXaxisAnnotationExternal",value:function(e,t,i){return this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"xaxis",contextMethod:i.addXaxisAnnotation}),i}},{key:"addYaxisAnnotationExternal",value:function(e,t,i){return this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"yaxis",contextMethod:i.addYaxisAnnotation}),i}},{key:"addPointAnnotationExternal",value:function(e,t,i){return void 0===this.invertAxis&&(this.invertAxis=i.w.globals.isBarHorizontal),this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"point",contextMethod:i.addPointAnnotation}),i}},{key:"addAnnotationExternal",value:function(e){var t=e.params,i=e.pushToMemory,a=e.context,s=e.type,n=e.contextMethod,o=a,l=o.w,c=l.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations")),h=c.childNodes.length+1,d=new X,u=Object.assign({},"xaxis"===s?d.xAxisAnnotation:"yaxis"===s?d.yAxisAnnotation:d.pointAnnotation),g=r.extend(u,t);switch(s){case"xaxis":this.addXaxisAnnotation(g,c,h);break;case"yaxis":this.addYaxisAnnotation(g,c,h);break;case"point":this.addPointAnnotation(g,c,h)}var f=l.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations .apexcharts-").concat(s,"-annotation-label[rel='").concat(h,"']")),p=this.helpers.addBackgroundToAnno(f,g);return p&&c.insertBefore(p.node,f),i&&l.globals.memory.methodsToExec.push({context:o,id:g.id?g.id:r.randomId(),method:n,label:"addAnnotation",params:t}),a}},{key:"clearAnnotations",value:function(e){var t=e.w,i=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-annotations, .apexcharts-xaxis-annotations, .apexcharts-point-annotations");t.globals.memory.methodsToExec.map((function(e,i){"addText"!==e.label&&"addAnnotation"!==e.label||t.globals.memory.methodsToExec.splice(i,1)})),i=r.listToArray(i),Array.prototype.forEach.call(i,(function(e){for(;e.firstChild;)e.removeChild(e.firstChild)}))}},{key:"removeAnnotation",value:function(e,t){var i=e.w,a=i.globals.dom.baseEl.querySelectorAll(".".concat(t));a&&(i.globals.memory.methodsToExec.map((function(e,a){e.id===t&&i.globals.memory.methodsToExec.splice(a,1)})),Array.prototype.forEach.call(a,(function(e){e.parentElement.removeChild(e)})))}}])&&Y(t.prototype,i),e}();function D(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function F(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?D(Object(i),!0).forEach((function(t){H(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):D(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function H(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function N(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var W=function(e){var t,i=e.isTimeline,a=e.ctx,r=e.seriesIndex,s=e.dataPointIndex,n=e.y1,o=e.y2,l=e.w,c=l.globals.seriesRangeStart[r][s],h=l.globals.seriesRangeEnd[r][s],d=l.globals.labels[s],u=l.config.series[r].name?l.config.series[r].name:"",g=l.globals.ttKeyFormatter,f=l.config.tooltip.y.title.formatter,p={w:l,seriesIndex:r,dataPointIndex:s,start:c,end:h};"function"==typeof f&&(u=f(u,p)),null!==(t=l.config.series[r].data[s])&&void 0!==t&&t.x&&(d=l.config.series[r].data[s].x),i||"datetime"===l.config.xaxis.type&&(d=new C(a).xLabelFormat(l.globals.ttKeyFormatter,d,d,{i:void 0,dateFormatter:new A(a).formatDate,w:l})),"function"==typeof g&&(d=g(d,p)),Number.isFinite(n)&&Number.isFinite(o)&&(c=n,h=o);var x="",b="",v=l.globals.colors[r];if(void 0===l.config.tooltip.x.formatter)if("datetime"===l.config.xaxis.type){var m=new A(a);x=m.formatDate(m.getDate(c),l.config.tooltip.x.format),b=m.formatDate(m.getDate(h),l.config.tooltip.x.format)}else x=c,b=h;else x=l.config.tooltip.x.formatter(c),b=l.config.tooltip.x.formatter(h);return{start:c,end:h,startVal:x,endVal:b,ylabel:d,color:v,seriesName:u}},B=function(e){var t=e.color,i=e.seriesName,a=e.ylabel,r=e.start,s=e.end,n=e.seriesIndex,o=e.dataPointIndex,l=e.ctx.tooltip.tooltipLabels.getFormatters(n);r=l.yLbFormatter(r),s=l.yLbFormatter(s);var c=l.yLbFormatter(e.w.globals.series[n][o]),h='<span class="value start-value">\n '.concat(r,'\n </span> <span class="separator">-</span> <span class="value end-value">\n ').concat(s,"\n </span>");return'<div class="apexcharts-tooltip-rangebar"><div> <span class="series-name" style="color: '+t+'">'+(i||"")+'</span></div><div> <span class="category">'+a+": </span> "+(e.w.globals.comboCharts?"rangeArea"===e.w.config.series[n].type||"rangeBar"===e.w.config.series[n].type?h:"<span>".concat(c,"</span>"):h)+" </div></div>"},j=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=t}var t,i;return t=e,(i=[{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(),r.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:"slope",value:function(){return this.hideYAxis(),{chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!0,formatter:function(e,t){var i=t.w.config.series[t.seriesIndex].name;return null!==e?i+": "+e:""},background:{enabled:!1},offsetX:-5},grid:{xaxis:{lines:{show:!0}},yaxis:{lines:{show:!1}}},xaxis:{position:"top",labels:{style:{fontSize:14,fontWeight:900}},tooltip:{enabled:!1},crosshairs:{show:!1}},markers:{size:8,hover:{sizeOffset:1}},legend:{show:!1},tooltip:{shared:!1,intersect:!0,followCursor:!0},stroke:{width:5,curve:"straight"}}}},{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}},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(),F(F({},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 i=t.seriesIndex,a=t.dataPointIndex,r=t.w;return e._getBoxTooltip(r,i,a,["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 i=t.seriesIndex,a=t.dataPointIndex,r=t.w;return e._getBoxTooltip(r,i,a,["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 i=t.seriesIndex,a=t.dataPointIndex,r=t.w,s=function(){var e=r.globals.seriesRangeStart[i][a];return r.globals.seriesRangeEnd[i][a]-e};return r.globals.comboCharts?"rangeBar"===r.config.series[i].type||"rangeArea"===r.config.series[i].type?s():e:s()},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=W(F(F({},e),{},{isTimeline:!0})),i=t.color,a=t.seriesName,r=t.ylabel,s=t.startVal,n=t.endVal;return B(F(F({},e),{},{color:i,seriesName:a,ylabel:r,start:s,end:n}))}(e):function(e){var t=W(e),i=t.color,a=t.seriesName,r=t.ylabel,s=t.start,n=t.end;return B(F(F({},e),{},{color:i,seriesName:a,ylabel:r,start:s,end:n}))}(e)}},xaxis:{tickPlacement:"between",tooltip:{enabled:!1},crosshairs:{stroke:{width:0}}}}}},{key:"dumbbell",value:function(e){var t,i;return null!==(t=e.plotOptions.bar)&&void 0!==t&&t.barHeight||(e.plotOptions.bar.barHeight=2),null!==(i=e.plotOptions.bar)&&void 0!==i&&i.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=W(e),i=t.color,a=t.seriesName,r=t.ylabel,s=t.start,n=t.end;return B(F(F({},e),{},{color:i,seriesName:a,ylabel:r,start:s,end:n}))}(e)}}}}},{key:"brush",value:function(e){return r.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,i){e.yaxis[i].min=0,e.yaxis[i].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 F(F({},e),{},{plotOptions:F(F({},e.plotOptions),{},{bar:F(F({},e.plotOptions.bar),{},{borderRadiusApplication:"end",borderRadiusWhenStacked:"last"})})})}},{key:"convertCatToNumeric",value:function(e){return e.xaxis.convertedCatToNumeric=!0,e}},{key:"convertCatToNumericXaxis",value:function(e,t,i){e.xaxis.type="numeric",e.xaxis.labels=e.xaxis.labels||{},e.xaxis.labels.formatter=e.xaxis.labels.formatter||function(e){return r.isNumber(e)?Math.floor(e):e};var a=e.xaxis.labels.formatter,s=e.xaxis.categories&&e.xaxis.categories.length?e.xaxis.categories:e.labels;return i&&i.length&&(s=i.map((function(e){return Array.isArray(e)?e:String(e)}))),s&&s.length&&(e.xaxis.labels.formatter=function(e){return r.isNumber(e)?a(s[Math.floor(e)-1]):a(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"}},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:{opacity:1,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{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,i,a,r){var s=e.globals.seriesCandleO[t][i],n=e.globals.seriesCandleH[t][i],o=e.globals.seriesCandleM[t][i],l=e.globals.seriesCandleL[t][i],c=e.globals.seriesCandleC[t][i];return e.config.series[t].type&&e.config.series[t].type!==r?'<div class="apexcharts-custom-tooltip">\n '.concat(e.config.series[t].name?e.config.series[t].name:"series-"+(t+1),": <strong>").concat(e.globals.series[t][i],"</strong>\n </div>"):'<div class="apexcharts-tooltip-box apexcharts-tooltip-'.concat(e.config.chart.type,'">')+"<div>".concat(a[0],': <span class="value">')+s+"</span></div>"+"<div>".concat(a[1],': <span class="value">')+n+"</span></div>"+(o?"<div>".concat(a[2],': <span class="value">')+o+"</span></div>":"")+"<div>".concat(a[3],': <span class="value">')+l+"</span></div>"+"<div>".concat(a[4],': <span class="value">')+c+"</span></div></div>"}}])&&N(t.prototype,i),e}();function G(e){return G="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},G(e)}function V(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var _=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=t}var t,i;return t=e,(i=[{key:"init",value:function(e){var t=e.responsiveOverride,i=this.opts,a=new X,s=new j(i);this.chartType=i.chart.type,i=this.extendYAxis(i),i=this.extendAnnotations(i);var n=a.init(),o={};if(i&&"object"===G(i)){var l,c,h,d,u,g,f,p,x,b,v={};v=-1!==["line","area","bar","candlestick","boxPlot","rangeBar","rangeArea","bubble","scatter","heatmap","treemap","pie","polarArea","donut","radar","radialBar"].indexOf(i.chart.type)?s[i.chart.type]():s.line(),null!==(l=i.plotOptions)&&void 0!==l&&null!==(c=l.bar)&&void 0!==c&&c.isFunnel&&(v=s.funnel()),i.chart.stacked&&"bar"===i.chart.type&&(v=s.stackedBars()),null!==(h=i.chart.brush)&&void 0!==h&&h.enabled&&(v=s.brush(v)),null!==(d=i.plotOptions)&&void 0!==d&&null!==(u=d.line)&&void 0!==u&&u.isSlopeChart&&(v=s.slope()),i.chart.stacked&&"100%"===i.chart.stackType&&(i=s.stacked100(i)),null!==(g=i.plotOptions)&&void 0!==g&&null!==(f=g.bar)&&void 0!==f&&f.isDumbbell&&(i=s.dumbbell(i)),this.checkForDarkTheme(window.Apex),this.checkForDarkTheme(i),i.xaxis=i.xaxis||window.Apex.xaxis||{},t||(i.xaxis.convertedCatToNumeric=!1),(null!==(p=(i=this.checkForCatToNumericXAxis(this.chartType,v,i)).chart.sparkline)&&void 0!==p&&p.enabled||null!==(x=window.Apex.chart)&&void 0!==x&&null!==(b=x.sparkline)&&void 0!==b&&b.enabled)&&(v=s.sparkline(v)),o=r.extend(n,v)}var m=r.extend(o,window.Apex);return n=r.extend(m,i),this.handleUserInputErrors(n)}},{key:"checkForCatToNumericXAxis",value:function(e,t,i){var a,r,s=new j(i),n=("bar"===e||"boxPlot"===e)&&(null===(a=i.plotOptions)||void 0===a||null===(r=a.bar)||void 0===r?void 0:r.horizontal),o="pie"===e||"polarArea"===e||"donut"===e||"radar"===e||"radialBar"===e||"heatmap"===e,l="datetime"!==i.xaxis.type&&"numeric"!==i.xaxis.type,c=i.xaxis.tickPlacement?i.xaxis.tickPlacement:t.xaxis&&t.xaxis.tickPlacement;return n||o||!l||"between"===c||(i=s.convertCatToNumeric(i)),i}},{key:"extendYAxis",value:function(e,t){var i=new X;(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=r.extend(e.yaxis,window.Apex.yaxis)),e.yaxis.constructor!==Array?e.yaxis=[r.extend(i.yAxis,e.yaxis)]:e.yaxis=r.extendArray(e.yaxis,i.yAxis);var a=!1;e.yaxis.forEach((function(e){e.logarithmic&&(a=!0)}));var s=e.series;return t&&!s&&(s=t.config.series),a&&s.length!==e.yaxis.length&&s.length&&(e.yaxis=s.map((function(t,a){if(t.name||(s[a].name="series-".concat(a+1)),e.yaxis[a])return e.yaxis[a].seriesName=s[a].name,e.yaxis[a];var n=r.extend(i.yAxis,e.yaxis[0]);return n.show=!1,n}))),a&&s.length>1&&s.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 X;return e.annotations.yaxis=r.extendArray(void 0!==e.annotations.yaxis?e.annotations.yaxis:[],t.yAxisAnnotation),e}},{key:"extendXAxisAnnotations",value:function(e){var t=new X;return e.annotations.xaxis=r.extendArray(void 0!==e.annotations.xaxis?e.annotations.xaxis:[],t.xAxisAnnotation),e}},{key:"extendPointAnnotations",value:function(e){var t=new X;return e.annotations.points=r.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.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}}])&&V(t.prototype,i),e}();function U(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var q=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,i;return t=e,(i=[{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.barGroups=[],e.lineGroups=[],e.areaGroups=[],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,e.multiAxisTickAmount=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:[],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,isSlopeChart:e.plotOptions.line.isSlopeChart,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,niceScaleAllowedMagMsd:[[1,1,2,5,5,5,10,10,10,10,10],[1,1,2,5,5,5,10,10,10,10,10]],niceScaleDefaultTicks:[1,2,4,4,6,6,6,6,6,6,6,6,6,6,6,6,6,6,12,12,12,12,12,12,12,12,12,24],seriesYAxisMap:[],seriesYAxisReverseMap:[]}}},{key:"init",value:function(e){var t=this.globalVars(e);return this.initGlobalVars(t),t.initialConfig=r.extend({},e),t.initialSeries=r.clone(e.series),t.lastXAxis=r.clone(t.initialConfig.xaxis),t.lastYAxis=r.clone(t.initialConfig.yaxis),t}}])&&U(t.prototype,i),e}();function Z(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var $=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=t}var t,i;return t=e,(i=[{key:"init",value:function(){var e=new _(this.opts).init({responsiveOverride:!1});return{config:e,globals:(new q).init(e)}}}])&&Z(t.prototype,i),e}();function J(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Q(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?J(Object(i),!0).forEach((function(t){K(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):J(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function K(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ee(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const te=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.opts=null,this.seriesIndex=0}var t,i;return t=e,(i=[{key:"clippedImgArea",value:function(e){var t=this.w,i=t.config,a=parseInt(t.globals.gridWidth,10),r=parseInt(t.globals.gridHeight,10),s=a>r?a:r,n=e.image,o=0,l=0;void 0===e.width&&void 0===e.height?void 0!==i.fill.image.width&&void 0!==i.fill.image.height?(o=i.fill.image.width+1,l=i.fill.image.height):(o=s+1,l=s):(o=e.width,l=e.height);var c=document.createElementNS(t.globals.SVGNS,"pattern");g.setAttrs(c,{id:e.patternID,patternUnits:e.patternUnits?e.patternUnits:"userSpaceOnUse",width:o+"px",height:l+"px"});var h=document.createElementNS(t.globals.SVGNS,"image");c.appendChild(h),h.setAttributeNS(window.SVG.xlink,"href",n),g.setAttrs(h,{x:0,y:0,preserveAspectRatio:"none",width:o+"px",height:l+"px"}),h.style.opacity=e.opacity,t.globals.dom.elDefs.node.appendChild(c)}},{key:"getSeriesIndex",value:function(e){var t=this.w,i=t.config.chart.type;return("bar"===i||"rangeBar"===i)&&t.config.plotOptions.bar.distributed||"heatmap"===i||"treemap"===i?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 i,a,s,n=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 l=e.fillType?e.fillType:this.getFillType(this.seriesIndex),c=Array.isArray(n.fill.opacity)?n.fill.opacity[this.seriesIndex]:n.fill.opacity;e.color&&(o=e.color),o||(o="#fff",console.warn("undefined color - ApexCharts"));var h=o;if(-1===o.indexOf("rgb")?o.length<9&&(h=r.hexToRgba(o,c)):o.indexOf("rgba")>-1&&(c=r.getOpacityFromRGBA(o)),e.opacity&&(c=e.opacity),"pattern"===l&&(a=this.handlePatternFill({fillConfig:e.fillConfig,patternFill:a,fillColor:o,fillOpacity:c,defaultColor:h})),"gradient"===l&&(s=this.handleGradientFill({fillConfig:e.fillConfig,fillColor:o,fillOpacity:c,i:this.seriesIndex})),"image"===l){var d=n.fill.image.src,u=e.patternID?e.patternID:"";this.clippedImgArea({opacity:c,image:Array.isArray(d)?e.seriesNumber<d.length?d[e.seriesNumber]:d[0]:d,width:e.width?e.width:void 0,height:e.height?e.height:void 0,patternUnits:e.patternUnits,patternID:"pattern".concat(t.globals.cuid).concat(e.seriesNumber+1).concat(u)}),i="url(#pattern".concat(t.globals.cuid).concat(e.seriesNumber+1).concat(u,")")}else i="gradient"===l?s:"pattern"===l?a:h;return e.solid&&(i=h),i}},{key:"getFillType",value:function(e){var t=this.w;return Array.isArray(t.config.fill.type)?t.config.fill.type[e]:t.config.fill.type}},{key:"getFillColors",value:function(){var e=this.w,t=e.config,i=this.opts,a=[];return e.globals.comboCharts?"line"===e.config.series[this.seriesIndex].type?Array.isArray(e.globals.stroke.colors)?a=e.globals.stroke.colors:a.push(e.globals.stroke.colors):Array.isArray(e.globals.fill.colors)?a=e.globals.fill.colors:a.push(e.globals.fill.colors):"line"===t.chart.type?Array.isArray(e.globals.stroke.colors)?a=e.globals.stroke.colors:a.push(e.globals.stroke.colors):Array.isArray(e.globals.fill.colors)?a=e.globals.fill.colors:a.push(e.globals.fill.colors),void 0!==i.fillColors&&(a=[],Array.isArray(i.fillColors)?a=i.fillColors.slice():a.push(i.fillColors)),a}},{key:"handlePatternFill",value:function(e){var t=e.fillConfig,i=(e.patternFill,e.fillColor),a=e.fillOpacity,r=e.defaultColor,s=this.w.config.fill;t&&(s=t);var n=this.opts,o=new g(this.ctx),l=Array.isArray(s.pattern.strokeWidth)?s.pattern.strokeWidth[this.seriesIndex]:s.pattern.strokeWidth,c=i;return Array.isArray(s.pattern.style)?void 0!==s.pattern.style[n.seriesNumber]?o.drawPattern(s.pattern.style[n.seriesNumber],s.pattern.width,s.pattern.height,c,l,a):r:o.drawPattern(s.pattern.style,s.pattern.width,s.pattern.height,c,l,a)}},{key:"handleGradientFill",value:function(e){var t=e.fillColor,i=e.fillOpacity,a=e.fillConfig,s=e.i,n=this.w.config.fill;a&&(n=Q(Q({},n),a));var o,l=this.opts,c=new g(this.ctx),h=new r,d=n.gradient.type,u=t,f=void 0===n.gradient.opacityFrom?i:Array.isArray(n.gradient.opacityFrom)?n.gradient.opacityFrom[s]:n.gradient.opacityFrom;u.indexOf("rgba")>-1&&(f=r.getOpacityFromRGBA(u));var p=void 0===n.gradient.opacityTo?i:Array.isArray(n.gradient.opacityTo)?n.gradient.opacityTo[s]:n.gradient.opacityTo;if(void 0===n.gradient.gradientToColors||0===n.gradient.gradientToColors.length)o="dark"===n.gradient.shade?h.shadeColor(-1*parseFloat(n.gradient.shadeIntensity),t.indexOf("rgb")>-1?r.rgb2hex(t):t):h.shadeColor(parseFloat(n.gradient.shadeIntensity),t.indexOf("rgb")>-1?r.rgb2hex(t):t);else if(n.gradient.gradientToColors[l.seriesNumber]){var x=n.gradient.gradientToColors[l.seriesNumber];o=x,x.indexOf("rgba")>-1&&(p=r.getOpacityFromRGBA(x))}else o=t;if(n.gradient.gradientFrom&&(u=n.gradient.gradientFrom),n.gradient.gradientTo&&(o=n.gradient.gradientTo),n.gradient.inverseColors){var b=u;u=o,o=b}return u.indexOf("rgb")>-1&&(u=r.rgb2hex(u)),o.indexOf("rgb")>-1&&(o=r.rgb2hex(o)),c.drawGradient(d,u,o,f,p,l.size,n.gradient.stops,n.gradient.colorStops,s)}}])&&ee(t.prototype,i),e}();function ie(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ae=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{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.length<e.globals.series.length+1)for(var t=0;t<=e.globals.series.length;t++)void 0===e.globals.markers.size[t]&&e.globals.markers.size.push(e.globals.markers.size[0])}else e.globals.markers.size=e.config.series.map((function(t){return e.config.markers.size}))}},{key:"plotChartMarkers",value:function(e,t,i,a){var s,n=arguments.length>4&&void 0!==arguments[4]&&arguments[4],o=this.w,c=t,h=e,d=null,u=new g(this.ctx),f=o.config.markers.discrete&&o.config.markers.discrete.length;if((o.globals.markers.size[t]>0||n||f)&&(d=u.group({class:n||f?"":"apexcharts-series-markers"})).attr("clip-path","url(#gridRectMarkerMask".concat(o.globals.cuid,")")),Array.isArray(h.x))for(var p=0;p<h.x.length;p++){var x=i;1===i&&0===p&&(x=0),1===i&&1===p&&(x=1);var b="apexcharts-marker";if("line"!==o.config.chart.type&&"area"!==o.config.chart.type||o.globals.comboCharts||o.config.tooltip.intersect||(b+=" no-pointer-events"),(Array.isArray(o.config.markers.size)?o.globals.markers.size[t]>0:o.config.markers.size>0)||n||f){r.isNumber(h.y[p])?b+=" w".concat(r.randomId()):b="apexcharts-nullpoint";var v=this.getMarkerConfig({cssClass:b,seriesIndex:t,dataPointIndex:x});o.config.series[c].data[x]&&(o.config.series[c].data[x].fillColor&&(v.pointFillColor=o.config.series[c].data[x].fillColor),o.config.series[c].data[x].strokeColor&&(v.pointStrokeColor=o.config.series[c].data[x].strokeColor)),a&&(v.pSize=a),(h.x[p]<-o.globals.markers.largestSize||h.x[p]>o.globals.gridWidth+o.globals.markers.largestSize||h.y[p]<-o.globals.markers.largestSize||h.y[p]>o.globals.gridHeight+o.globals.markers.largestSize)&&(v.pSize=0),(s=u.drawMarker(h.x[p],h.y[p],v)).attr("rel",x),s.attr("j",x),s.attr("index",t),s.node.setAttribute("default-marker-size",v.pSize),new l(this.ctx).setSelectionFilter(s,t,x),this.addEvents(s),d&&d.add(s)}else void 0===o.globals.pointsArray[t]&&(o.globals.pointsArray[t]=[]),o.globals.pointsArray[t].push([h.x[p],h.y[p]])}return d}},{key:"getMarkerConfig",value:function(e){var t=e.cssClass,i=e.seriesIndex,a=e.dataPointIndex,r=void 0===a?null:a,s=e.radius,n=void 0===s?null:s,o=e.size,l=void 0===o?null:o,c=e.strokeWidth,h=void 0===c?null:c,d=this.w,u=this.getMarkerStyle(i),g=null===l?d.globals.markers.size[i]:l,f=d.config.markers;return null!==r&&f.discrete.length&&f.discrete.map((function(e){e.seriesIndex===i&&e.dataPointIndex===r&&(u.pointStrokeColor=e.strokeColor,u.pointFillColor=e.fillColor,g=e.size,u.pointShape=e.shape)})),{pSize:null===n?g:n,pRadius:null!==n?n:f.radius,pointStrokeWidth:null!==h?h:Array.isArray(f.strokeWidth)?f.strokeWidth[i]:f.strokeWidth,pointStrokeColor:u.pointStrokeColor,pointFillColor:u.pointFillColor,shape:u.pointShape||(Array.isArray(f.shape)?f.shape[i]:f.shape),class:t,pointStrokeOpacity:Array.isArray(f.strokeOpacity)?f.strokeOpacity[i]:f.strokeOpacity,pointStrokeDashArray:Array.isArray(f.strokeDashArray)?f.strokeDashArray[i]:f.strokeDashArray,pointFillOpacity:Array.isArray(f.fillOpacity)?f.fillOpacity[i]:f.fillOpacity,seriesIndex:i}}},{key:"addEvents",value:function(e){var t=this.w,i=new g(this.ctx);e.node.addEventListener("mouseenter",i.pathMouseEnter.bind(this.ctx,e)),e.node.addEventListener("mouseleave",i.pathMouseLeave.bind(this.ctx,e)),e.node.addEventListener("mousedown",i.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",i.pathMouseDown.bind(this.ctx,e),{passive:!0})}},{key:"getMarkerStyle",value:function(e){var t=this.w,i=t.globals.markers.colors,a=t.config.markers.strokeColor||t.config.markers.strokeColors;return{pointStrokeColor:Array.isArray(a)?a[e]:a,pointFillColor:Array.isArray(i)?i[e]:i}}}],i&&ie(t.prototype,i),e}();function re(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var se=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.initialAnim=this.w.config.chart.animations.enabled}var t,i;return t=e,(i=[{key:"draw",value:function(e,t,i){var a=this.w,r=new g(this.ctx),s=i.realIndex,n=i.pointsPos,o=i.zRatio,l=i.elParent,c=r.group({class:"apexcharts-series-markers apexcharts-series-".concat(a.config.chart.type)});if(c.attr("clip-path","url(#gridRectMarkerMask".concat(a.globals.cuid,")")),Array.isArray(n.x))for(var h=0;h<n.x.length;h++){var d=t+1,u=!0;0===t&&0===h&&(d=0),0===t&&1===h&&(d=1);var f=a.globals.markers.size[s];if(o!==1/0){var p=a.config.plotOptions.bubble;f=a.globals.seriesZ[s][d],p.zScaling&&(f/=o),p.minBubbleRadius&&f<p.minBubbleRadius&&(f=p.minBubbleRadius),p.maxBubbleRadius&&f>p.maxBubbleRadius&&(f=p.maxBubbleRadius)}var x=n.x[h],b=n.y[h];if(f=f||0,null!==b&&void 0!==a.globals.series[s][d]||(u=!1),u){var v=this.drawPoint(x,b,f,s,d,t);c.add(v)}l.add(c)}}},{key:"drawPoint",value:function(e,t,i,a,r,s){var o=this.w,c=a,h=new n(this.ctx),d=new l(this.ctx),u=new te(this.ctx),f=new ae(this.ctx),p=new g(this.ctx),x=f.getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:c,dataPointIndex:r,radius:"bubble"===o.config.chart.type||o.globals.comboCharts&&o.config.series[a]&&"bubble"===o.config.series[a].type?i:null});i=x.pSize;var b=u.fillPath({seriesNumber:a,dataPointIndex:r,color:x.pointFillColor,patternUnits:"objectBoundingBox",value:o.globals.series[a][s]}),v=p.drawMarker(e,t,x);if(o.config.series[c].data[r]&&o.config.series[c].data[r].fillColor&&(b=o.config.series[c].data[r].fillColor),v.attr({fill:b,r:i}),o.config.chart.dropShadow.enabled){var m=o.config.chart.dropShadow;d.dropShadow(v,m,a)}if(!this.initialAnim||o.globals.dataChanged||o.globals.resized)o.globals.animationEnded=!0;else{var y=o.config.chart.animations.speed;h.animateMarker(v,0,i,y,o.globals.easing,(function(){window.setTimeout((function(){h.animationCompleted(v)}),100)}))}return v.attr({rel:r,j:r,index:a,"default-marker-size":i}),d.setSelectionFilter(v,a,r),f.addEvents(v),v.node.classList.add("apexcharts-marker"),v}},{key:"centerTextInBubble",value:function(e){var t=this.w;return{y:e+=parseInt(t.config.dataLabels.style.fontSize,10)/4}}}])&&re(t.prototype,i),e}();function ne(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const oe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"dataLabelsCorrection",value:function(e,t,i,a,r,s,n){var o=this.w,l=!1,c=new g(this.ctx).getTextRects(i,n),h=c.width,d=c.height;t<0&&(t=0),t>o.globals.gridHeight+d&&(t=o.globals.gridHeight+d/2),void 0===o.globals.dataLabelsRects[a]&&(o.globals.dataLabelsRects[a]=[]),o.globals.dataLabelsRects[a].push({x:e,y:t,width:h,height:d});var u=o.globals.dataLabelsRects[a].length-2,f=void 0!==o.globals.lastDrawnDataLabelsIndexes[a]?o.globals.lastDrawnDataLabelsIndexes[a][o.globals.lastDrawnDataLabelsIndexes[a].length-1]:0;if(void 0!==o.globals.dataLabelsRects[a][u]){var p=o.globals.dataLabelsRects[a][f];(e>p.x+p.width||t>p.y+p.height||t+d<p.y||e+h<p.x)&&(l=!0)}return(0===r||s)&&(l=!0),{x:e,y:t,textRects:c,drawnextLabel:l}}},{key:"drawDataLabel",value:function(e){var t=this,i=e.type,a=e.pos,r=e.i,s=e.j,n=e.isRangeStart,o=e.strokeWidth,l=void 0===o?2:o,c=this.w,h=new g(this.ctx),d=c.config.dataLabels,u=0,f=0,p=s,x=null;if(-1!==c.globals.collapsedSeriesIndices.indexOf(r)||!d.enabled||!Array.isArray(a.x))return x;x=h.group({class:"apexcharts-data-labels"});for(var b=0;b<a.x.length;b++)if(u=a.x[b]+d.offsetX,f=a.y[b]+d.offsetY+l,!isNaN(u)){1===s&&0===b&&(p=0),1===s&&1===b&&(p=1);var v=c.globals.series[r][p];"rangeArea"===i&&(v=n?c.globals.seriesRangeStart[r][p]:c.globals.seriesRangeEnd[r][p]);var m="",y=function(e){return c.config.dataLabels.formatter(e,{ctx:t.ctx,seriesIndex:r,dataPointIndex:p,w:c})};"bubble"===c.config.chart.type?(m=y(v=c.globals.seriesZ[r][p]),f=a.y[b],f=new se(this.ctx).centerTextInBubble(f,r,p).y):void 0!==v&&(m=y(v));var w=c.config.dataLabels.textAnchor;c.globals.isSlopeChart&&(w=0===p?"end":p===c.config.series[r].data.length-1?"start":"middle"),this.plotDataLabelsText({x:u,y:f,text:m,i:r,j:p,parent:x,offsetCorrection:!0,dataLabelsConfig:c.config.dataLabels,textAnchor:w})}return x}},{key:"plotDataLabelsText",value:function(e){var t=this.w,i=new g(this.ctx),a=e.x,r=e.y,s=e.i,n=e.j,o=e.text,c=e.textAnchor,h=e.fontSize,d=e.parent,u=e.dataLabelsConfig,f=e.color,p=e.alwaysDrawDataLabel,x=e.offsetCorrection,b=e.className,v=null;if(Array.isArray(t.config.dataLabels.enabledOnSeries)&&t.config.dataLabels.enabledOnSeries.indexOf(s)<0)return v;var m={x:a,y:r,drawnextLabel:!0,textRects:null};x&&(m=this.dataLabelsCorrection(a,r,o,s,n,p,parseInt(u.style.fontSize,10))),t.globals.zoomed||(a=m.x,r=m.y),m.textRects&&(a<-20-m.textRects.width||a>t.globals.gridWidth+m.textRects.width+30)&&(o="");var y=t.globals.dataLabels.style.colors[s];(("bar"===t.config.chart.type||"rangeBar"===t.config.chart.type)&&t.config.plotOptions.bar.distributed||t.config.dataLabels.distributed)&&(y=t.globals.dataLabels.style.colors[n]),"function"==typeof y&&(y=y({series:t.globals.series,seriesIndex:s,dataPointIndex:n,w:t})),f&&(y=f);var w=u.offsetX,k=u.offsetY;if("bar"!==t.config.chart.type&&"rangeBar"!==t.config.chart.type||(w=0,k=0),t.globals.isSlopeChart&&(0!==n&&(w=-2*u.offsetX+5),0!==n&&n!==t.config.series[s].data.length-1&&(w=0)),m.drawnextLabel){if((v=i.drawText({width:100,height:parseInt(u.style.fontSize,10),x:a+w,y:r+k,foreColor:y,textAnchor:c||u.textAnchor,text:o,fontSize:h||u.style.fontSize,fontFamily:u.style.fontFamily,fontWeight:u.style.fontWeight||"normal"})).attr({class:b||"apexcharts-datalabel",cx:a,cy:r}),u.dropShadow.enabled){var A=u.dropShadow;new l(this.ctx).dropShadow(v,A)}d.add(v),void 0===t.globals.lastDrawnDataLabelsIndexes[s]&&(t.globals.lastDrawnDataLabelsIndexes[s]=[]),t.globals.lastDrawnDataLabelsIndexes[s].push(n)}return v}},{key:"addBackgroundToDataLabel",value:function(e,t){var i=this.w,a=i.config.dataLabels.background,r=a.padding,s=a.padding/2,n=t.width,o=t.height,c=new g(this.ctx).drawRect(t.x-r,t.y-s/2,n+2*r,o+s,a.borderRadius,"transparent"!==i.config.chart.background&&i.config.chart.background?i.config.chart.background:"#fff",a.opacity,a.borderWidth,a.borderColor);return a.dropShadow.enabled&&new l(this.ctx).dropShadow(c,a.dropShadow),c}},{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"),i=0;i<t.length;i++){var a=t[i],r=a.getBBox(),s=null;if(r.width&&r.height&&(s=this.addBackgroundToDataLabel(a,r)),s){a.parentNode.insertBefore(s.node,a);var n=a.getAttribute("fill");!e.config.chart.animations.enabled||e.globals.resized||e.globals.dataChanged?s.attr({fill:n}):s.animate().attr({fill:n}),a.setAttribute("fill",e.config.dataLabels.background.foreColor)}}}},{key:"bringForward",value:function(){for(var e=this.w,t=e.globals.dom.baseEl.querySelectorAll(".apexcharts-datalabels"),i=e.globals.dom.baseEl.querySelector(".apexcharts-plot-series:last-child"),a=0;a<t.length;a++)i&&i.insertBefore(t[a],i.nextSibling)}}])&&ne(t.prototype,i),e}();function le(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ce=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.legendInactiveClass="legend-mouseover-inactive"}var t,i;return t=e,i=[{key:"getAllSeriesEls",value:function(){return this.w.globals.dom.baseEl.getElementsByClassName("apexcharts-series")}},{key:"getSeriesByName",value:function(e){return this.w.globals.dom.baseEl.querySelector(".apexcharts-inner .apexcharts-series[seriesName='".concat(r.escapeString(e),"']"))}},{key:"isSeriesHidden",value:function(e){var t=this.getSeriesByName(e),i=parseInt(t.getAttribute("data:realIndex"),10);return{isHidden:t.classList.contains("apexcharts-series-collapsed"),realIndex:i}}},{key:"addCollapsedClassToSeries",value:function(e,t){var i=this.w;function a(i){for(var a=0;a<i.length;a++)i[a].index===t&&e.node.classList.add("apexcharts-series-collapsed")}a(i.globals.collapsedSeries),a(i.globals.ancillaryCollapsedSeries)}},{key:"toggleSeries",value:function(e){var t=this.isSeriesHidden(e);return this.ctx.legend.legendHelpers.toggleDataSeries(t.realIndex,t.isHidden),t.isHidden}},{key:"showSeries",value:function(e){var t=this.isSeriesHidden(e);t.isHidden&&this.ctx.legend.legendHelpers.toggleDataSeries(t.realIndex,!0)}},{key:"hideSeries",value:function(e){var t=this.isSeriesHidden(e);t.isHidden||this.ctx.legend.legendHelpers.toggleDataSeries(t.realIndex,!1)}},{key:"resetSeries",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=this.w,s=r.clone(a.globals.initialSeries);a.globals.previousPaths=[],i?(a.globals.collapsedSeries=[],a.globals.ancillaryCollapsedSeries=[],a.globals.collapsedSeriesIndices=[],a.globals.ancillaryCollapsedSeriesIndices=[]):s=this.emptyCollapsedSeries(s),a.config.series=s,e&&(t&&(a.globals.zoomed=!1,this.ctx.updateHelpers.revertDefaultAxisMinMax()),this.ctx.updateHelpers._updateSeries(s,a.config.chart.animations.dynamicAnimation.enabled))}},{key:"emptyCollapsedSeries",value:function(e){for(var t=this.w,i=0;i<e.length;i++)t.globals.collapsedSeriesIndices.indexOf(i)>-1&&(e[i].data=[]);return e}},{key:"toggleSeriesOnHover",value:function(e,t){var i=this.w;t||(t=e.target);var a=i.globals.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels, .apexcharts-yaxis");if("mousemove"===e.type){var r=parseInt(t.getAttribute("rel"),10)-1,s=null,n=null,o=null;if(i.globals.axisCharts||"radialBar"===i.config.chart.type)if(i.globals.axisCharts){s=i.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(r,"']")),n=i.globals.dom.baseEl.querySelector(".apexcharts-datalabels[data\\:realIndex='".concat(r,"']"));var l=i.globals.seriesYAxisReverseMap[r];o=i.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(l,"']"))}else s=i.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(r+1,"']"));else s=i.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(r+1,"'] path"));for(var c=0;c<a.length;c++)a[c].classList.add(this.legendInactiveClass);null!==s&&(i.globals.axisCharts||s.parentNode.classList.remove(this.legendInactiveClass),s.classList.remove(this.legendInactiveClass),null!==n&&n.classList.remove(this.legendInactiveClass),null!==o&&o.classList.remove(this.legendInactiveClass))}else if("mouseout"===e.type)for(var h=0;h<a.length;h++)a[h].classList.remove(this.legendInactiveClass)}},{key:"highlightRangeInSeries",value:function(e,t){var i=this,a=this.w,r=a.globals.dom.baseEl.getElementsByClassName("apexcharts-heatmap-rect"),s=function(e){for(var t=0;t<r.length;t++)r[t].classList[e](i.legendInactiveClass)};if("mousemove"===e.type){var n=parseInt(t.getAttribute("rel"),10)-1;s("add"),function(e){for(var t=0;t<r.length;t++){var a=parseInt(r[t].getAttribute("val"),10);a>=e.from&&a<=e.to&&r[t].classList.remove(i.legendInactiveClass)}}(a.config.plotOptions.heatmap.colorScale.ranges[n])}else"mouseout"===e.type&&s("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]:[],i=this.w,a=0;if(i.config.series.length>1)for(var r=i.config.series.map((function(e,a){return e.data&&e.data.length>0&&-1===i.globals.collapsedSeriesIndices.indexOf(a)&&(!i.globals.comboCharts||0===t.length||t.length&&t.indexOf(i.config.series[a].type)>-1)?a:-1})),s="asc"===e?0:r.length-1;"asc"===e?s<r.length:s>=0;"asc"===e?s++:s--)if(-1!==r[s]){a=r[s];break}return a}},{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,i,a){for(var r=t[i].childNodes,s={type:a,paths:[],realIndex:t[i].getAttribute("data:realIndex")},n=0;n<r.length;n++)if(r[n].hasAttribute("pathTo")){var o=r[n].getAttribute("pathTo");s.paths.push({d:o})}e.globals.previousPaths.push(s)}e.globals.previousPaths=[],["line","area","bar","rangebar","rangeArea","candlestick","radar"].forEach((function(i){for(var a,r=(a=i,e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(a,"-series .apexcharts-series"))),s=0;s<r.length;s++)t(r,s,i)})),this.handlePrevBubbleScatterPaths("bubble"),this.handlePrevBubbleScatterPaths("scatter");var i=e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e.config.chart.type," .apexcharts-series"));if(i.length>0)for(var a=function(t){for(var i=e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e.config.chart.type," .apexcharts-series[data\\:realIndex='").concat(t,"'] rect")),a=[],r=function(e){var t=function(t){return i[e].getAttribute(t)},r={x:parseFloat(t("x")),y:parseFloat(t("y")),width:parseFloat(t("width")),height:parseFloat(t("height"))};a.push({rect:r,color:i[e].getAttribute("color")})},s=0;s<i.length;s++)r(s);e.globals.previousPaths.push(a)},r=0;r<i.length;r++)a(r);e.globals.axisCharts||(e.globals.previousPaths=e.globals.series)}},{key:"handlePrevBubbleScatterPaths",value:function(e){var t=this.w,i=t.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e,"-series .apexcharts-series"));if(i.length>0)for(var a=0;a<i.length;a++){for(var r=t.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e,"-series .apexcharts-series[data\\:realIndex='").concat(a,"'] circle")),s=[],n=0;n<r.length;n++)s.push({x:r[n].getAttribute("cx"),y:r[n].getAttribute("cy"),r:r[n].getAttribute("r")});t.globals.previousPaths.push(s)}}},{key:"clearPreviousPaths",value:function(){var e=this.w;e.globals.previousPaths=[],e.globals.allSeriesCollapsed=!1}},{key:"handleNoData",value:function(){var e=this.w,t=e.config.noData,i=new g(this.ctx),a=e.globals.svgWidth/2,r=e.globals.svgHeight/2,s="middle";if(e.globals.noData=!0,e.globals.animationEnded=!0,"left"===t.align?(a=10,s="start"):"right"===t.align&&(a=e.globals.svgWidth-10,s="end"),"top"===t.verticalAlign?r=50:"bottom"===t.verticalAlign&&(r=e.globals.svgHeight-50),a+=t.offsetX,r=r+parseInt(t.style.fontSize,10)+2+t.offsetY,void 0!==t.text&&""!==t.text){var n=i.drawText({x:a,y:r,text:t.text,textAnchor:s,fontSize:t.style.fontSize,fontFamily:t.style.fontFamily,foreColor:t.style.color,opacity:1,class:"apexcharts-text-nodata"});e.globals.dom.Paper.add(n)}}},{key:"setNullSeriesToZeroValues",value:function(e){for(var t=this.w,i=0;i<e.length;i++)if(0===e[i].length)for(var a=0;a<e[t.globals.maxValsInArrayIndex].length;a++)e[i].push(0);return e}},{key:"hasAllSeriesEqualX",value:function(){for(var e=!0,t=this.w,i=this.filteredSeriesX(),a=0;a<i.length-1;a++)if(i[a][0]!==i[a+1][0]){e=!1;break}return t.globals.allSeriesHasEqualX=e,e}},{key:"filteredSeriesX",value:function(){return this.w.globals.seriesX.map((function(e){return e.length>0?e:[]}))}}],i&&le(t.prototype,i),e}();function he(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function de(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ue=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.twoDSeries=[],this.threeDSeries=[],this.twoDSeriesX=[],this.seriesGoals=[],this.coreUtils=new p(this.ctx)}var t,i;return t=e,i=[{key:"isMultiFormat",value:function(){return this.isFormatXY()||this.isFormat2DArray()}},{key:"isFormatXY",value:function(){var e=this.w.config.series.slice(),t=new ce(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 ce(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 i=this.w.config,a=this.w.globals,s="boxPlot"===i.chart.type||"boxPlot"===i.series[t].type,n=0;n<e[t].data.length;n++)if(void 0!==e[t].data[n][1]&&(Array.isArray(e[t].data[n][1])&&4===e[t].data[n][1].length&&!s?this.twoDSeries.push(r.parseNumber(e[t].data[n][1][3])):e[t].data[n].length>=5?this.twoDSeries.push(r.parseNumber(e[t].data[n][4])):this.twoDSeries.push(r.parseNumber(e[t].data[n][1])),a.dataFormatXNumeric=!0),"datetime"===i.xaxis.type){var o=new Date(e[t].data[n][0]);o=new Date(o).getTime(),this.twoDSeriesX.push(o)}else this.twoDSeriesX.push(e[t].data[n][0]);for(var l=0;l<e[t].data.length;l++)void 0!==e[t].data[l][2]&&(this.threeDSeries.push(e[t].data[l][2]),a.isDataXYZ=!0)}},{key:"handleFormatXY",value:function(e,t){var i=this.w.config,a=this.w.globals,s=new A(this.ctx),n=t;a.collapsedSeriesIndices.indexOf(t)>-1&&(n=this.activeSeriesIndex);for(var o=0;o<e[t].data.length;o++)void 0!==e[t].data[o].y&&(Array.isArray(e[t].data[o].y)?this.twoDSeries.push(r.parseNumber(e[t].data[o].y[e[t].data[o].y.length-1])):this.twoDSeries.push(r.parseNumber(e[t].data[o].y))),void 0!==e[t].data[o].goals&&Array.isArray(e[t].data[o].goals)?(void 0===this.seriesGoals[t]&&(this.seriesGoals[t]=[]),this.seriesGoals[t].push(e[t].data[o].goals)):(void 0===this.seriesGoals[t]&&(this.seriesGoals[t]=[]),this.seriesGoals[t].push(null));for(var l=0;l<e[n].data.length;l++){var c="string"==typeof e[n].data[l].x,h=Array.isArray(e[n].data[l].x),d=!h&&!!s.isValidDate(e[n].data[l].x);if(c||d)if(c||i.xaxis.convertedCatToNumeric){var u=a.isBarHorizontal&&a.isRangeData;"datetime"!==i.xaxis.type||u?(this.fallbackToCategory=!0,this.twoDSeriesX.push(e[n].data[l].x),isNaN(e[n].data[l].x)||"category"===this.w.config.xaxis.type||"string"==typeof e[n].data[l].x||(a.isXNumeric=!0)):this.twoDSeriesX.push(s.parseDate(e[n].data[l].x))}else"datetime"===i.xaxis.type?this.twoDSeriesX.push(s.parseDate(e[n].data[l].x.toString())):(a.dataFormatXNumeric=!0,a.isXNumeric=!0,this.twoDSeriesX.push(parseFloat(e[n].data[l].x)));else h?(this.fallbackToCategory=!0,this.twoDSeriesX.push(e[n].data[l].x)):(a.isXNumeric=!0,a.dataFormatXNumeric=!0,this.twoDSeriesX.push(e[n].data[l].x))}if(e[t].data[0]&&void 0!==e[t].data[0].z){for(var g=0;g<e[t].data.length;g++)this.threeDSeries.push(e[t].data[g].z);a.isDataXYZ=!0}}},{key:"handleRangeData",value:function(e,t){var i=this.w.globals,a={};return this.isFormat2DArray()?a=this.handleRangeDataFormat("array",e,t):this.isFormatXY()&&(a=this.handleRangeDataFormat("xy",e,t)),i.seriesRangeStart.push(void 0===a.start?[]:a.start),i.seriesRangeEnd.push(void 0===a.end?[]:a.end),i.seriesRange.push(a.rangeUniques),i.seriesRange.forEach((function(e,t){e&&e.forEach((function(e,t){e.y.forEach((function(t,i){for(var a=0;a<e.y.length;a++)if(i!==a){var r=t.y1,s=t.y2,n=e.y[a].y1;r<=e.y[a].y2&&n<=s&&(e.overlaps.indexOf(t.rangeName)<0&&e.overlaps.push(t.rangeName),e.overlaps.indexOf(e.y[a].rangeName)<0&&e.overlaps.push(e.y[a].rangeName))}}))}))})),a}},{key:"handleCandleStickBoxData",value:function(e,t){var i=this.w.globals,a={};return this.isFormat2DArray()?a=this.handleCandleStickBoxDataFormat("array",e,t):this.isFormatXY()&&(a=this.handleCandleStickBoxDataFormat("xy",e,t)),i.seriesCandleO[t]=a.o,i.seriesCandleH[t]=a.h,i.seriesCandleM[t]=a.m,i.seriesCandleL[t]=a.l,i.seriesCandleC[t]=a.c,a}},{key:"handleRangeDataFormat",value:function(e,t,i){var a=[],s=[],n=t[i].data.filter((function(e,t,i){return t===i.findIndex((function(t){return t.x===e.x}))})).map((function(e,t){return{x:e.x,overlaps:[],y:[]}}));if("array"===e)for(var o=0;o<t[i].data.length;o++)Array.isArray(t[i].data[o])?(a.push(t[i].data[o][1][0]),s.push(t[i].data[o][1][1])):(a.push(t[i].data[o]),s.push(t[i].data[o]));else if("xy"===e)for(var l=function(e){var o=Array.isArray(t[i].data[e].y),l=r.randomId(),c=t[i].data[e].x,h={y1:o?t[i].data[e].y[0]:t[i].data[e].y,y2:o?t[i].data[e].y[1]:t[i].data[e].y,rangeName:l};t[i].data[e].rangeName=l;var d=n.findIndex((function(e){return e.x===c}));n[d].y.push(h),a.push(h.y1),s.push(h.y2)},c=0;c<t[i].data.length;c++)l(c);return{start:a,end:s,rangeUniques:n}}},{key:"handleCandleStickBoxDataFormat",value:function(e,t,i){var a=this.w,r="boxPlot"===a.config.chart.type||"boxPlot"===a.config.series[i].type,s=[],n=[],o=[],l=[],c=[];if("array"===e)if(r&&6===t[i].data[0].length||!r&&5===t[i].data[0].length)for(var h=0;h<t[i].data.length;h++)s.push(t[i].data[h][1]),n.push(t[i].data[h][2]),r?(o.push(t[i].data[h][3]),l.push(t[i].data[h][4]),c.push(t[i].data[h][5])):(l.push(t[i].data[h][3]),c.push(t[i].data[h][4]));else for(var d=0;d<t[i].data.length;d++)Array.isArray(t[i].data[d][1])&&(s.push(t[i].data[d][1][0]),n.push(t[i].data[d][1][1]),r?(o.push(t[i].data[d][1][2]),l.push(t[i].data[d][1][3]),c.push(t[i].data[d][1][4])):(l.push(t[i].data[d][1][2]),c.push(t[i].data[d][1][3])));else if("xy"===e)for(var u=0;u<t[i].data.length;u++)Array.isArray(t[i].data[u].y)&&(s.push(t[i].data[u].y[0]),n.push(t[i].data[u].y[1]),r?(o.push(t[i].data[u].y[2]),l.push(t[i].data[u].y[3]),c.push(t[i].data[u].y[4])):(l.push(t[i].data[u].y[2]),c.push(t[i].data[u].y[3])));return{o:s,h:n,m:o,l,c}}},{key:"parseDataAxisCharts",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.ctx,a=this.w.config,s=this.w.globals,n=new A(i),o=a.labels.length>0?a.labels.slice():a.xaxis.categories.slice();s.isRangeBar="rangeBar"===a.chart.type&&s.isBarHorizontal,s.hasXaxisGroups="category"===a.xaxis.type&&a.xaxis.group.groups.length>0,s.hasXaxisGroups&&(s.groups=a.xaxis.group.groups),e.forEach((function(e,t){void 0!==e.name?s.seriesNames.push(e.name):s.seriesNames.push("series-"+parseInt(t+1,10))})),this.coreUtils.setSeriesYAxisMappings();var l,c=[],h=function(e){if(Array.isArray(e))return he(e)}(l=new Set(a.series.map((function(e){return e.group}))))||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(l)||function(e,t){if(e){if("string"==typeof e)return he(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?he(e,t):void 0}}(l)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}();a.series.forEach((function(e,t){var i=h.indexOf(e.group);c[i]||(c[i]=[]),c[i].push(s.seriesNames[t])})),s.seriesGroups=c;for(var d=function(){for(var e=0;e<o.length;e++)if("string"==typeof o[e]){if(!n.isValidDate(o[e]))throw new Error("You have provided invalid Date format. Please provide a valid JavaScript Date");t.twoDSeriesX.push(n.parseDate(o[e]))}else t.twoDSeriesX.push(o[e])},u=0;u<e.length;u++){if(this.twoDSeries=[],this.twoDSeriesX=[],this.threeDSeries=[],void 0===e[u].data)return void console.error("It is a possibility that you may have not included 'data' property in series.");if("rangeBar"!==a.chart.type&&"rangeArea"!==a.chart.type&&"rangeBar"!==e[u].type&&"rangeArea"!==e[u].type||(s.isRangeData=!0,"rangeBar"!==a.chart.type&&"rangeArea"!==a.chart.type||this.handleRangeData(e,u)),this.isMultiFormat())this.isFormat2DArray()?this.handleFormat2DArray(e,u):this.isFormatXY()&&this.handleFormatXY(e,u),"candlestick"!==a.chart.type&&"candlestick"!==e[u].type&&"boxPlot"!==a.chart.type&&"boxPlot"!==e[u].type||this.handleCandleStickBoxData(e,u),s.series.push(this.twoDSeries),s.labels.push(this.twoDSeriesX),s.seriesX.push(this.twoDSeriesX),s.seriesGoals=this.seriesGoals,u!==this.activeSeriesIndex||this.fallbackToCategory||(s.isXNumeric=!0);else{"datetime"===a.xaxis.type?(s.isXNumeric=!0,d(),s.seriesX.push(this.twoDSeriesX)):"numeric"===a.xaxis.type&&(s.isXNumeric=!0,o.length>0&&(this.twoDSeriesX=o,s.seriesX.push(this.twoDSeriesX))),s.labels.push(this.twoDSeriesX);var g=e[u].data.map((function(e){return r.parseNumber(e)}));s.series.push(g)}s.seriesZ.push(this.threeDSeries),void 0!==e[u].color?s.seriesColors.push(e[u].color):s.seriesColors.push(void 0)}return this.w}},{key:"parseDataNonAxisCharts",value:function(e){var t=this.w.globals,i=this.w.config;t.series=e.slice(),t.seriesNames=i.labels.slice();for(var a=0;a<t.series.length;a++)void 0===t.seriesNames[a]&&t.seriesNames.push("series-"+(a+1));return this.w}},{key:"handleExternalLabelsData",value:function(e){var t=this.w.config,i=this.w.globals;t.xaxis.categories.length>0?i.labels=t.xaxis.categories:t.labels.length>0?i.labels=t.labels.slice():this.fallbackToCategory?(i.labels=i.labels[0],i.seriesRange.length&&(i.seriesRange.map((function(e){e.forEach((function(e){i.labels.indexOf(e.x)<0&&e.x&&i.labels.push(e.x)}))})),i.labels=Array.from(new Set(i.labels.map(JSON.stringify)),JSON.parse)),t.xaxis.convertedCatToNumeric&&(new j(t).convertCatToNumericXaxis(t,this.ctx,i.seriesX[0]),this._generateExternalLabels(e))):this._generateExternalLabels(e)}},{key:"_generateExternalLabels",value:function(e){var t=this.w.globals,i=this.w.config,a=[];if(t.axisCharts){if(t.series.length>0)if(this.isFormatXY())for(var r=i.series.map((function(e,t){return e.data.filter((function(e,t,i){return i.findIndex((function(t){return t.x===e.x}))===t}))})),s=r.reduce((function(e,t,i,a){return a[e].length>t.length?e:i}),0),n=0;n<r[s].length;n++)a.push(n+1);else for(var o=0;o<t.series[t.maxValsInArrayIndex].length;o++)a.push(o+1);t.seriesX=[];for(var l=0;l<e.length;l++)t.seriesX.push(a);this.w.globals.isBarHorizontal||(t.isXNumeric=!0)}if(0===a.length){a=t.axisCharts?[]:t.series.map((function(e,t){return t+1}));for(var c=0;c<e.length;c++)t.seriesX.push(a)}t.labels=a,i.xaxis.convertedCatToNumeric&&(t.categoryLabels=a.map((function(e){return i.xaxis.labels.formatter(e)}))),t.noLabelsProvided=!0}},{key:"parseData",value:function(e){var t=this.w,i=t.config,a=t.globals;if(this.excludeCollapsedSeriesInYAxis(),this.fallbackToCategory=!1,this.ctx.core.resetGlobals(),this.ctx.core.isMultipleY(),a.axisCharts?(this.parseDataAxisCharts(e),this.coreUtils.getLargestSeries()):this.parseDataNonAxisCharts(e),i.chart.stacked){var r=new ce(this.ctx);a.series=r.setNullSeriesToZeroValues(a.series)}this.coreUtils.getSeriesTotals(),a.axisCharts&&(a.stackedSeriesTotals=this.coreUtils.getStackedSeriesTotals(),a.stackedSeriesTotalsByGroups=this.coreUtils.getStackedSeriesTotalsByGroups()),this.coreUtils.getPercentSeries(),a.dataFormatXNumeric||a.isXNumeric&&("numeric"!==i.xaxis.type||0!==i.labels.length||0!==i.xaxis.categories.length)||this.handleExternalLabelsData(e);for(var s=this.coreUtils.getCategoryLabels(a.labels),n=0;n<s.length;n++)if(Array.isArray(s[n])){a.isMultiLineX=!0;break}}},{key:"excludeCollapsedSeriesInYAxis",value:function(){var e=this.w,t=[];e.globals.seriesYAxisMap.forEach((function(i,a){var r=0;i.forEach((function(t){-1!==e.globals.collapsedSeriesIndices.indexOf(t)&&r++})),r>0&&r==i.length&&t.push(a)})),e.globals.ignoreYAxisIndexes=t.map((function(e){return e}))}}],i&&de(t.prototype,i),e}();function ge(e){return function(e){if(Array.isArray(e))return fe(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return fe(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?fe(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function fe(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function pe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const xe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"scaleSvgNode",value:function(e,t){var i=parseFloat(e.getAttributeNS(null,"width")),a=parseFloat(e.getAttributeNS(null,"height"));e.setAttributeNS(null,"width",i*t),e.setAttributeNS(null,"height",a*t),e.setAttributeNS(null,"viewBox","0 0 "+i+" "+a)}},{key:"fixSvgStringForIe11",value:function(e){if(!r.isIE11())return e.replace(/&nbsp;/g,"&#160;");var t=0,i=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(i=i.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 i=this.w.globals.dom.Paper.node.cloneNode(!0);this.scaleSvgNode(i,e),t=(new XMLSerializer).serializeToString(i)}return this.fixSvgStringForIe11(t)}},{key:"cleanup",value:function(){var e=this.w,t=e.globals.dom.baseEl.getElementsByClassName("apexcharts-xcrosshairs"),i=e.globals.dom.baseEl.getElementsByClassName("apexcharts-ycrosshairs"),a=e.globals.dom.baseEl.querySelectorAll(".apexcharts-zoom-rect, .apexcharts-selection-rect");Array.prototype.forEach.call(a,(function(e){e.setAttribute("width",0)})),t&&t[0]&&(t[0].setAttribute("x",-500),t[0].setAttribute("x1",-500),t[0].setAttribute("x2",-500)),i&&i[0]&&(i[0].setAttribute("y",-100),i[0].setAttribute("y1",-100),i[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(i){var a=t.w,s=e?e.scale||e.width/a.globals.svgWidth:1;t.cleanup();var n=document.createElement("canvas");n.width=a.globals.svgWidth*s,n.height=parseInt(a.globals.dom.elWrap.style.height,10)*s;var o="transparent"!==a.config.chart.background&&a.config.chart.background?a.config.chart.background:"#fff",l=n.getContext("2d");l.fillStyle=o,l.fillRect(0,0,n.width*s,n.height*s);var c=t.getSvgString(s);if(window.canvg&&r.isIE11()){var h=window.canvg.Canvg.fromString(l,c,{ignoreClear:!0,ignoreDimensions:!0});h.start();var d=n.msToBlob();h.stop(),i({blob:d})}else{var u="data:image/svg+xml,"+encodeURIComponent(c),g=new Image;g.crossOrigin="anonymous",g.onload=function(){if(l.drawImage(g,0,0),n.msToBlob){var e=n.msToBlob();i({blob:e})}else{var t=n.toDataURL("image/png");i({imgURI:t})}},g.src=u}}))}},{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 i=t.imgURI,a=t.blob;a?navigator.msSaveOrOpenBlob(a,e.w.globals.chartID+".png"):e.triggerDownload(i,e.w.config.chart.toolbar.export.png.filename,".png")}))}},{key:"exportToCSV",value:function(e){var t=this,i=e.series,a=e.fileName,s=e.columnDelimiter,n=void 0===s?",":s,o=e.lineDelimiter,l=void 0===o?"\n":o,c=this.w;i||(i=c.config.series);var h,d,u=[],g=[],f="",p=c.globals.series.map((function(e,t){return-1===c.globals.collapsedSeriesIndices.indexOf(t)?e:[]})),x=function(e){return"function"==typeof c.config.chart.toolbar.export.csv.categoryFormatter?c.config.chart.toolbar.export.csv.categoryFormatter(e):"datetime"===c.config.xaxis.type&&String(e).length>=10?new Date(e).toDateString():r.isNumber(e)?e:e.split(n).join("")},b=function(e){return"function"==typeof c.config.chart.toolbar.export.csv.valueFormatter?c.config.chart.toolbar.export.csv.valueFormatter(e):e},v=Math.max.apply(Math,ge(i.map((function(e){return e.data?e.data.length:0})))),m=new ue(this.ctx),y=new L(this.ctx),w=function(e){var i="";if(c.globals.axisCharts){if("category"===c.config.xaxis.type||c.config.xaxis.convertedCatToNumeric)if(c.globals.isBarHorizontal){var a=c.globals.yLabelFormatters[0],s=new ce(t.ctx).getActiveConfigSeriesIndex();i=a(c.globals.labels[e],{seriesIndex:s,dataPointIndex:e,w:c})}else i=y.getLabel(c.globals.labels,c.globals.timescaleLabels,0,e).text;"datetime"===c.config.xaxis.type&&(c.config.xaxis.categories.length?i=c.config.xaxis.categories[e]:c.config.labels.length&&(i=c.config.labels[e]))}else i=c.config.labels[e];return null===i?"nullvalue":(Array.isArray(i)&&(i=i.join(" ")),r.isNumber(i)?i:i.split(n).join(""))};u.push(c.config.chart.toolbar.export.csv.headerCategory),"boxPlot"===c.config.chart.type?(u.push("minimum"),u.push("q1"),u.push("median"),u.push("q3"),u.push("maximum")):"candlestick"===c.config.chart.type?(u.push("open"),u.push("high"),u.push("low"),u.push("close")):"rangeBar"===c.config.chart.type?(u.push("minimum"),u.push("maximum")):i.map((function(e,t){var i=(e.name?e.name:"series-".concat(t))+"";c.globals.axisCharts&&u.push(i.split(n).join("")?i.split(n).join(""):"series-".concat(t))})),c.globals.axisCharts||(u.push(c.config.chart.toolbar.export.csv.headerValue),g.push(u.join(n))),c.globals.allSeriesHasEqualX||!c.globals.axisCharts||c.config.xaxis.categories.length||c.config.labels.length?i.map((function(e,t){c.globals.axisCharts?function(e,t){if(u.length&&0===t&&g.push(u.join(n)),e.data){e.data=e.data.length&&e.data||ge(Array(v)).map((function(){return""}));for(var a=0;a<e.data.length;a++){u=[];var r=w(a);if("nullvalue"!==r){if(r||(m.isFormatXY()?r=i[t].data[a].x:m.isFormat2DArray()&&(r=i[t].data[a]?i[t].data[a][0]:"")),0===t){u.push(x(r));for(var s=0;s<c.globals.series.length;s++){var o,l=m.isFormatXY()?null===(o=i[s].data[a])||void 0===o?void 0:o.y:p[s][a];u.push(b(l))}}("candlestick"===c.config.chart.type||e.type&&"candlestick"===e.type)&&(u.pop(),u.push(c.globals.seriesCandleO[t][a]),u.push(c.globals.seriesCandleH[t][a]),u.push(c.globals.seriesCandleL[t][a]),u.push(c.globals.seriesCandleC[t][a])),("boxPlot"===c.config.chart.type||e.type&&"boxPlot"===e.type)&&(u.pop(),u.push(c.globals.seriesCandleO[t][a]),u.push(c.globals.seriesCandleH[t][a]),u.push(c.globals.seriesCandleM[t][a]),u.push(c.globals.seriesCandleL[t][a]),u.push(c.globals.seriesCandleC[t][a])),"rangeBar"===c.config.chart.type&&(u.pop(),u.push(c.globals.seriesRangeStart[t][a]),u.push(c.globals.seriesRangeEnd[t][a])),u.length&&g.push(u.join(n))}}}}(e,t):((u=[]).push(x(c.globals.labels[t])),u.push(b(p[t])),g.push(u.join(n)))})):(h=new Set,d={},i.forEach((function(e,t){null==e||e.data.forEach((function(e){var a,r;if(m.isFormatXY())a=e.x,r=e.y;else{if(!m.isFormat2DArray())return;a=e[0],r=e[1]}d[a]||(d[a]=Array(i.length).fill("")),d[a][t]=b(r),h.add(a)}))})),u.length&&g.push(u.join(n)),Array.from(h).sort().forEach((function(e){g.push([x(e),d[e].join(n)])}))),f+=g.join(l),this.triggerDownload("data:text/csv; charset=utf-8,"+encodeURIComponent("\ufeff"+f),a||c.config.chart.toolbar.export.csv.filename,".csv")}},{key:"triggerDownload",value:function(e,t,i){var a=document.createElement("a");a.href=e,a.download=(t||this.w.globals.chartID)+i,document.body.appendChild(a),a.click(),document.body.removeChild(a)}}])&&pe(t.prototype,i),e}();function be(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ve=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.elgrid=i,this.w=t.w;var a=this.w;this.axesUtils=new L(t),this.xaxisLabels=a.globals.labels.slice(),a.globals.timescaleLabels.length>0&&!a.globals.isBarHorizontal&&(this.xaxisLabels=a.globals.timescaleLabels.slice()),a.config.xaxis.overwriteCategories&&(this.xaxisLabels=a.config.xaxis.overwriteCategories),this.drawnLabels=[],this.drawnLabelsRects=[],"top"===a.config.xaxis.position?this.offY=0:this.offY=a.globals.gridHeight,this.offY=this.offY+a.config.xaxis.axisBorder.offsetY,this.isCategoryBarHorizontal="bar"===a.config.chart.type&&a.config.plotOptions.bar.horizontal,this.xaxisFontSize=a.config.xaxis.labels.style.fontSize,this.xaxisFontFamily=a.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=a.config.xaxis.labels.style.colors,this.xaxisBorderWidth=a.config.xaxis.axisBorder.width,this.isCategoryBarHorizontal&&(this.xaxisBorderWidth=a.config.yaxis[0].axisBorder.width.toString()),this.xaxisBorderWidth.indexOf("%")>-1?this.xaxisBorderWidth=a.globals.gridWidth*parseInt(this.xaxisBorderWidth,10)/100:this.xaxisBorderWidth=parseInt(this.xaxisBorderWidth,10),this.xaxisBorderHeight=a.config.xaxis.axisBorder.height,this.yaxis=a.config.yaxis[0]}var t,i;return t=e,i=[{key:"drawXaxis",value:function(){var e=this.w,t=new g(this.ctx),i=t.group({class:"apexcharts-xaxis",transform:"translate(".concat(e.config.xaxis.offsetX,", ").concat(e.config.xaxis.offsetY,")")}),a=t.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(e.globals.translateXAxisX,", ").concat(e.globals.translateXAxisY,")")});i.add(a);for(var r=[],s=0;s<this.xaxisLabels.length;s++)r.push(this.xaxisLabels[s]);if(this.drawXAxisLabelAndGroup(!0,t,a,r,e.globals.isXNumeric,(function(e,t){return t})),e.globals.hasXaxisGroups){var n=e.globals.groups;r=[];for(var o=0;o<n.length;o++)r.push(n[o].title);var l={};e.config.xaxis.group.style&&(l.xaxisFontSize=e.config.xaxis.group.style.fontSize,l.xaxisFontFamily=e.config.xaxis.group.style.fontFamily,l.xaxisForeColors=e.config.xaxis.group.style.colors,l.fontWeight=e.config.xaxis.group.style.fontWeight,l.cssClass=e.config.xaxis.group.style.cssClass),this.drawXAxisLabelAndGroup(!1,t,a,r,!1,(function(e,t){return n[e].cols*t}),l)}if(void 0!==e.config.xaxis.title.text){var c=t.group({class:"apexcharts-xaxis-title"}),h=t.drawText({x:e.globals.gridWidth/2+e.config.xaxis.title.offsetX,y:this.offY+parseFloat(this.xaxisFontSize)+("bottom"===e.config.xaxis.position?e.globals.xAxisLabelsHeight:-e.globals.xAxisLabelsHeight-10)+e.config.xaxis.title.offsetY,text:e.config.xaxis.title.text,textAnchor:"middle",fontSize:e.config.xaxis.title.style.fontSize,fontFamily:e.config.xaxis.title.style.fontFamily,fontWeight:e.config.xaxis.title.style.fontWeight,foreColor:e.config.xaxis.title.style.color,cssClass:"apexcharts-xaxis-title-text "+e.config.xaxis.title.style.cssClass});c.add(h),i.add(c)}if(e.config.xaxis.axisBorder.show){var d=e.globals.barPadForNumericAxis,u=t.drawLine(e.globals.padHorizontal+e.config.xaxis.axisBorder.offsetX-d,this.offY,this.xaxisBorderWidth+d,this.offY,e.config.xaxis.axisBorder.color,0,this.xaxisBorderHeight);this.elgrid&&this.elgrid.elGridBorders&&e.config.grid.show?this.elgrid.elGridBorders.add(u):i.add(u)}return i}},{key:"drawXAxisLabelAndGroup",value:function(e,t,i,a,r,s){var n,o=this,l=arguments.length>6&&void 0!==arguments[6]?arguments[6]:{},c=[],h=[],d=this.w,u=l.xaxisFontSize||this.xaxisFontSize,g=l.xaxisFontFamily||this.xaxisFontFamily,f=l.xaxisForeColors||this.xaxisForeColors,p=l.fontWeight||d.config.xaxis.labels.style.fontWeight,x=l.cssClass||d.config.xaxis.labels.style.cssClass,b=d.globals.padHorizontal,v=a.length,m="category"===d.config.xaxis.type?d.globals.dataPoints:v;if(0===m&&v>m&&(m=v),r){var y=m>1?m-1:m;n=d.globals.gridWidth/Math.min(y,v-1),b=b+s(0,n)/2+d.config.xaxis.labels.offsetX}else n=d.globals.gridWidth/m,b=b+s(0,n)+d.config.xaxis.labels.offsetX;for(var w=function(r){var l=b-s(r,n)/2+d.config.xaxis.labels.offsetX;0===r&&1===v&&n/2===b&&1===m&&(l=d.globals.gridWidth/2);var y=o.axesUtils.getLabel(a,d.globals.timescaleLabels,l,r,c,u,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(u)+(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?o.axesUtils.checkLabelBasedOnTickamount(r,y,v):o.axesUtils.checkForOverflowingLabels(r,y,v,c,h),d.config.xaxis.labels.show){var k=t.drawText({x:y.x,y:o.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:p,fontSize:u,fontFamily:g,foreColor:Array.isArray(f)?e&&d.config.xaxis.convertedCatToNumeric?f[d.globals.minX+r-1]:f[r]:f,isPlainText:!1,cssClass:(e?"apexcharts-xaxis-label ":"apexcharts-xaxis-group-label ")+x});if(i.add(k),k.on("click",(function(e){if("function"==typeof d.config.chart.events.xAxisLabelClick){var t=Object.assign({},d,{labelIndex:r});d.config.chart.events.xAxisLabelClick(e,o.ctx,t)}})),e){var A=document.createElementNS(d.globals.SVGNS,"title");A.textContent=Array.isArray(y.text)?y.text.join(" "):y.text,k.node.appendChild(A),""!==y.text&&(c.push(y.text),h.push(y))}}r<v-1&&(b+=s(r+1,n))},k=0;k<=v-1;k++)w(k)}},{key:"drawXaxisInversed",value:function(e){var t,i,a=this,r=this.w,s=new g(this.ctx),n=r.config.yaxis[0].opposite?r.globals.translateYAxisX[e]:0,o=s.group({class:"apexcharts-yaxis apexcharts-xaxis-inversed",rel:e}),l=s.group({class:"apexcharts-yaxis-texts-g apexcharts-xaxis-inversed-texts-g",transform:"translate("+n+", 0)"});o.add(l);var c=[];if(r.config.yaxis[e].show)for(var h=0;h<this.xaxisLabels.length;h++)c.push(this.xaxisLabels[h]);t=r.globals.gridHeight/c.length,i=-t/2.2;var d=r.globals.yLabelFormatters[0],u=r.config.yaxis[0].labels;if(u.show)for(var f=function(n){var o=void 0===c[n]?"":c[n];o=d(o,{seriesIndex:e,dataPointIndex:n,w:r});var h=a.axesUtils.getYAxisForeColor(u.style.colors,e),g=0;Array.isArray(o)&&(g=o.length/2*parseInt(u.style.fontSize,10));var f=u.offsetX-15,p="end";a.yaxis.opposite&&(p="start"),"left"===r.config.yaxis[0].labels.align?(f=u.offsetX,p="start"):"center"===r.config.yaxis[0].labels.align?(f=u.offsetX,p="middle"):"right"===r.config.yaxis[0].labels.align&&(p="end");var x=s.drawText({x:f,y:i+t+u.offsetY-g,text:o,textAnchor:p,foreColor:Array.isArray(h)?h[n]:h,fontSize:u.style.fontSize,fontFamily:u.style.fontFamily,fontWeight:u.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+u.style.cssClass,maxWidth:u.maxWidth});l.add(x),x.on("click",(function(e){if("function"==typeof r.config.chart.events.xAxisLabelClick){var t=Object.assign({},r,{labelIndex:n});r.config.chart.events.xAxisLabelClick(e,a.ctx,t)}}));var b=document.createElementNS(r.globals.SVGNS,"title");if(b.textContent=Array.isArray(o)?o.join(" "):o,x.node.appendChild(b),0!==r.config.yaxis[e].labels.rotate){var v=s.rotateAroundCenter(x.node);x.node.setAttribute("transform","rotate(".concat(r.config.yaxis[e].labels.rotate," 0 ").concat(v.y,")"))}i+=t},p=0;p<=c.length-1;p++)f(p);if(void 0!==r.config.yaxis[0].title.text){var x=s.group({class:"apexcharts-yaxis-title apexcharts-xaxis-title-inversed",transform:"translate("+n+", 0)"}),b=s.drawText({x:r.config.yaxis[0].title.offsetX,y:r.globals.gridHeight/2+r.config.yaxis[0].title.offsetY,text:r.config.yaxis[0].title.text,textAnchor:"middle",foreColor:r.config.yaxis[0].title.style.color,fontSize:r.config.yaxis[0].title.style.fontSize,fontWeight:r.config.yaxis[0].title.style.fontWeight,fontFamily:r.config.yaxis[0].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+r.config.yaxis[0].title.style.cssClass});x.add(b),o.add(x)}var v=0;this.isCategoryBarHorizontal&&r.config.yaxis[0].opposite&&(v=r.globals.gridWidth);var m=r.config.xaxis.axisBorder;if(m.show){var y=s.drawLine(r.globals.padHorizontal+m.offsetX+v,1+m.offsetY,r.globals.padHorizontal+m.offsetX+v,r.globals.gridHeight+m.offsetY,m.color,0);this.elgrid&&this.elgrid.elGridBorders&&r.config.grid.show?this.elgrid.elGridBorders.add(y):o.add(y)}return r.config.yaxis[0].axisTicks.show&&this.axesUtils.drawYAxisTicks(v,c.length,r.config.yaxis[0].axisBorder,r.config.yaxis[0].axisTicks,0,t,o),o}},{key:"drawXaxisTicks",value:function(e,t,i){var a=this.w,r=e;if(!(e<0||e-2>a.globals.gridWidth)){var s=this.offY+a.config.xaxis.axisTicks.offsetY;if(t=t+s+a.config.xaxis.axisTicks.height,"top"===a.config.xaxis.position&&(t=s-a.config.xaxis.axisTicks.height),a.config.xaxis.axisTicks.show){var n=new g(this.ctx).drawLine(e+a.config.xaxis.axisTicks.offsetX,s+a.config.xaxis.offsetY,r+a.config.xaxis.axisTicks.offsetX,t+a.config.xaxis.offsetY,a.config.xaxis.axisTicks.color);i.add(n),n.node.classList.add("apexcharts-xaxis-tick")}}}},{key:"getXAxisTicksPositions",value:function(){var e=this.w,t=[],i=this.xaxisLabels.length,a=e.globals.padHorizontal;if(e.globals.timescaleLabels.length>0)for(var r=0;r<i;r++)a=this.xaxisLabels[r].position,t.push(a);else for(var s=i,n=0;n<s;n++){var o=s;e.globals.isXNumeric&&"bar"!==e.config.chart.type&&(o-=1),a+=e.globals.gridWidth/o,t.push(a)}return t}},{key:"xAxisLabelCorrections",value:function(){var e=this.w,t=new g(this.ctx),i=e.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g"),a=e.globals.dom.baseEl.querySelectorAll(".apexcharts-xaxis-texts-g text:not(.apexcharts-xaxis-group-label)"),r=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-inversed text"),s=e.globals.dom.baseEl.querySelectorAll(".apexcharts-xaxis-inversed-texts-g text tspan");if(e.globals.rotateXLabels||e.config.xaxis.labels.rotateAlways)for(var n=0;n<a.length;n++){var o=t.rotateAroundCenter(a[n]);o.y=o.y-1,o.x=o.x+1,a[n].setAttribute("transform","rotate(".concat(e.config.xaxis.labels.rotate," ").concat(o.x," ").concat(o.y,")")),a[n].setAttribute("text-anchor","end"),i.setAttribute("transform","translate(0, ".concat(-10,")"));var l=a[n].childNodes;e.config.xaxis.labels.trim&&Array.prototype.forEach.call(l,(function(i){t.placeTextWithEllipsis(i,i.textContent,e.globals.xAxisLabelsHeight-("bottom"===e.config.legend.position?20:10))}))}else!function(){for(var i=e.globals.gridWidth/(e.globals.labels.length+1),r=0;r<a.length;r++){var s=a[r].childNodes;e.config.xaxis.labels.trim&&"datetime"!==e.config.xaxis.type&&Array.prototype.forEach.call(s,(function(e){t.placeTextWithEllipsis(e,e.textContent,i)}))}}();if(r.length>0){var c=r[r.length-1].getBBox(),h=r[0].getBBox();c.x<-20&&r[r.length-1].parentNode.removeChild(r[r.length-1]),h.x+h.width>e.globals.gridWidth&&!e.globals.isBarHorizontal&&r[0].parentNode.removeChild(r[0]);for(var d=0;d<s.length;d++)t.placeTextWithEllipsis(s[d],s[d].textContent,e.config.yaxis[0].labels.maxWidth-(e.config.yaxis[0].title.text?2*parseFloat(e.config.yaxis[0].title.style.fontSize):0)-15)}}}],i&&be(t.prototype,i),e}();function me(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ye=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.w;this.xaxisLabels=i.globals.labels.slice(),this.axesUtils=new L(t),this.isRangeBar=i.globals.seriesRange.length&&i.globals.isBarHorizontal,i.globals.timescaleLabels.length>0&&(this.xaxisLabels=i.globals.timescaleLabels.slice())}var t,i;return t=e,i=[{key:"drawGridArea",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=this.w,i=new g(this.ctx);null===e&&(e=i.group({class:"apexcharts-grid"}));var a=i.drawLine(t.globals.padHorizontal,1,t.globals.padHorizontal,t.globals.gridHeight,"transparent"),r=i.drawLine(t.globals.padHorizontal,t.globals.gridHeight,t.globals.gridWidth,t.globals.gridHeight,"transparent");return e.add(r),e.add(a),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,i=new g(this.ctx),a=Array.isArray(e.config.stroke.width)?0:e.config.stroke.width;if(Array.isArray(e.config.stroke.width)){var r=0;e.config.stroke.width.forEach((function(e){r=Math.max(r,e)})),a=r}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 s=e.config.chart.type,n=0,o=0;("bar"===s||"rangeBar"===s||"candlestick"===s||"boxPlot"===s||e.globals.comboBarCount>0)&&e.globals.isXNumeric&&!e.globals.isBarHorizontal&&(n=e.config.grid.padding.left,o=e.config.grid.padding.right,t.barPadForNumericAxis>n&&(n=t.barPadForNumericAxis,o=t.barPadForNumericAxis)),t.dom.elGridRect=i.drawRect(-a/2-n-2,-a/2-2,t.gridWidth+a+o+n+4,t.gridHeight+a+4,0,"#fff");var l=e.globals.markers.largestSize+1;t.dom.elGridRectMarker=i.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,i=e.x1,a=e.y1,r=e.x2,s=e.y2,n=e.xCount,o=e.parent,l=this.w;if(!(0===t&&l.globals.skipFirstTimelinelabel||t===n-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:i,y1:a,x2:r,y2:s,xCount:n,parent:o});var c=0;if(l.globals.hasXaxisGroups&&"between"===l.config.xaxis.tickPlacement){var h=l.globals.groups;if(h){for(var d=0,u=0;d<t&&u<h.length;u++)d+=h[u].cols;d===t&&(c=.6*l.globals.xAxisLabelsHeight)}}new ve(this.ctx).drawXaxisTicks(i,c,l.globals.dom.elGraphical)}}},{key:"_drawGridLine",value:function(e){var t=e.i,i=e.x1,a=e.y1,r=e.x2,s=e.y2,n=e.xCount,o=e.parent,l=this.w,c=!1,h=o.node.classList.contains("apexcharts-gridlines-horizontal"),d=l.config.grid.strokeDashArray,u=l.globals.barPadForNumericAxis;(0===a&&0===s||0===i&&0===r)&&(c=!0),a===l.globals.gridHeight&&s===l.globals.gridHeight&&(c=!0),!l.globals.isBarHorizontal||0!==t&&t!==n-1||(c=!0);var f=new g(this).drawLine(i-(h?u:0),a,r+(h?u:0),s,l.config.grid.borderColor,d);f.node.classList.add("apexcharts-gridline"),c&&l.config.grid.show?this.elGridBorders.add(f):o.add(f)}},{key:"_drawGridBandRect",value:function(e){var t=e.c,i=e.x1,a=e.y1,r=e.x2,s=e.y2,n=e.type,o=this.w,l=new g(this.ctx),c=o.globals.barPadForNumericAxis;if("column"!==n||"datetime"!==o.config.xaxis.type){var h=o.config.grid[n].colors[t],d=l.drawRect(i-("row"===n?c:0),a,r+("row"===n?2*c:0),s,0,h,o.config.grid[n].opacity);this.elg.add(d),d.attr("clip-path","url(#gridRectMask".concat(o.globals.cuid,")")),d.node.classList.add("apexcharts-grid-".concat(n))}}},{key:"_drawXYLines",value:function(e){var t=this,i=e.xCount,a=e.tickAmount,r=this.w;if(r.config.grid.xaxis.lines.show||r.config.xaxis.axisTicks.show){var s,n=r.globals.padHorizontal,o=r.globals.gridHeight;r.globals.timescaleLabels.length?function(e){for(var a=e.xC,r=e.x1,s=e.y1,n=e.x2,o=e.y2,l=0;l<a;l++)r=t.xaxisLabels[l].position,n=t.xaxisLabels[l].position,t._drawGridLines({i:l,x1:r,y1:s,x2:n,y2:o,xCount:i,parent:t.elgridLinesV})}({xC:i,x1:n,y1:0,x2:s,y2:o}):(r.globals.isXNumeric&&(i=r.globals.xAxisScale.result.length),function(e){for(var a=e.xC,s=e.x1,n=e.y1,o=e.x2,l=e.y2,c=0;c<a+(r.globals.isXNumeric?0:1);c++)0===c&&1===a&&1===r.globals.dataPoints&&(o=s=r.globals.gridWidth/2),t._drawGridLines({i:c,x1:s,y1:n,x2:o,y2:l,xCount:i,parent:t.elgridLinesV}),o=s+=r.globals.gridWidth/(r.globals.isXNumeric?a-1:a)}({xC:i,x1:n,y1:0,x2:s,y2:o}))}if(r.config.grid.yaxis.lines.show){var l=0,c=0,h=r.globals.gridWidth,d=a+1;this.isRangeBar&&(d=r.globals.labels.length);for(var u=0;u<d+(this.isRangeBar?1:0);u++)this._drawGridLine({i:u,xCount:d+(this.isRangeBar?1:0),x1:0,y1:l,x2:h,y2:c,parent:this.elgridLinesH}),c=l+=r.globals.gridHeight/(this.isRangeBar?d:a)}}},{key:"_drawInvertedXYLines",value:function(e){var t=e.xCount,i=this.w;if(i.config.grid.xaxis.lines.show||i.config.xaxis.axisTicks.show)for(var a,r=i.globals.padHorizontal,s=i.globals.gridHeight,n=0;n<t+1;n++)i.config.grid.xaxis.lines.show&&this._drawGridLine({i:n,xCount:t+1,x1:r,y1:0,x2:a,y2:s,parent:this.elgridLinesV}),new ve(this.ctx).drawXaxisTicks(r,0,i.globals.dom.elGraphical),a=r+=i.globals.gridWidth/t;if(i.config.grid.yaxis.lines.show)for(var o=0,l=0,c=i.globals.gridWidth,h=0;h<i.globals.dataPoints+1;h++)this._drawGridLine({i:h,xCount:i.globals.dataPoints+1,x1:0,y1:o,x2:c,y2:l,parent:this.elgridLinesH}),l=o+=i.globals.gridHeight/i.globals.dataPoints}},{key:"renderGrid",value:function(){var e=this.w,t=e.globals,i=new g(this.ctx);this.elg=i.group({class:"apexcharts-grid"}),this.elgridLinesH=i.group({class:"apexcharts-gridlines-horizontal"}),this.elgridLinesV=i.group({class:"apexcharts-gridlines-vertical"}),this.elGridBorders=i.group({class:"apexcharts-grid-borders"}),this.elg.add(this.elgridLinesH),this.elg.add(this.elgridLinesV),e.config.grid.show||(this.elgridLinesV.hide(),this.elgridLinesH.hide(),this.elGridBorders.hide());for(var a=0;a<t.seriesYAxisMap.length&&-1!==t.ignoreYAxisIndexes.indexOf(a);)a++;a===t.seriesYAxisMap.length&&(a=0);var r,s,n,o,l=t.yAxisScale[a].result.length-1;return!t.isBarHorizontal||this.isRangeBar?(r=this.xaxisLabels.length,this.isRangeBar&&(l=t.labels.length,e.config.xaxis.tickAmount&&e.config.xaxis.labels.formatter&&(r=e.config.xaxis.tickAmount),(null===(s=t.yAxisScale)||void 0===s||null===(n=s[a])||void 0===n||null===(o=n.result)||void 0===o?void 0:o.length)>0&&"datetime"!==e.config.xaxis.type&&(r=t.yAxisScale[a].result.length-1)),this._drawXYLines({xCount:r,tickAmount:l})):(r=l,l=t.xTickAmount,this._drawInvertedXYLines({xCount:r,tickAmount:l})),this.drawGridBands(r,l),{el:this.elg,elGridBorders:this.elGridBorders,xAxisTickWidth:t.gridWidth/r}}},{key:"drawGridBands",value:function(e,t){var i=this.w;if(void 0!==i.config.grid.row.colors&&i.config.grid.row.colors.length>0)for(var a=0,r=i.globals.gridHeight/t,s=i.globals.gridWidth,n=0,o=0;n<t;n++,o++)o>=i.config.grid.row.colors.length&&(o=0),this._drawGridBandRect({c:o,x1:0,y1:a,x2:s,y2:r,type:"row"}),a+=i.globals.gridHeight/t;if(void 0!==i.config.grid.column.colors&&i.config.grid.column.colors.length>0)for(var l=i.globals.isBarHorizontal||"on"!==i.config.xaxis.tickPlacement||"category"!==i.config.xaxis.type&&!i.config.xaxis.convertedCatToNumeric?e:e-1,c=i.globals.padHorizontal,h=i.globals.padHorizontal+i.globals.gridWidth/l,d=i.globals.gridHeight,u=0,g=0;u<e;u++,g++)g>=i.config.grid.column.colors.length&&(g=0),this._drawGridBandRect({c:g,x1:c,y1:0,x2:h,y2:d,type:"column"}),c+=i.globals.gridWidth/l}}],i&&me(t.prototype,i),e}();function we(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ke=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"niceScale",value:function(e,t){var i,a,s,n,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,l=1e-11,c=this.w,h=c.globals;h.isBarHorizontal?(i=c.config.xaxis,a=Math.max((h.svgWidth-100)/25,2)):(i=c.config.yaxis[o],a=Math.max((h.svgHeight-100)/15,2)),s=void 0!==i.min&&null!==i.min,n=void 0!==i.max&&null!==i.min;var d=void 0!==i.stepSize&&null!==i.stepSize,u=void 0!==i.tickAmount&&null!==i.tickAmount,g=u?i.tickAmount:i.forceNiceScale?h.niceScaleDefaultTicks[Math.min(Math.round(a/2),h.niceScaleDefaultTicks.length-1)]:10;if(h.isMultipleYAxis&&!u&&h.multiAxisTickAmount>0&&(g=h.multiAxisTickAmount,u=!0),g="dataPoints"===g?h.dataPoints-1:Math.abs(Math.round(g)),(e===Number.MIN_VALUE&&0===t||!r.isNumber(e)&&!r.isNumber(t)||e===Number.MIN_VALUE&&t===-Number.MAX_VALUE)&&(e=r.isNumber(i.min)?i.min:0,t=r.isNumber(i.max)?i.max:e+g,h.allSeriesCollapsed=!1),e>t){console.warn("axis.min cannot be greater than axis.max: swapping min and max");var f=t;t=e,e=f}else e===t&&(e=0===e?0:e-1,t=0===t?2:t+1);var p=[];g<1&&(g=1);var x=g,b=Math.abs(t-e);i.forceNiceScale&&(!s&&e>0&&e/b<.15&&(e=0,s=!0),!n&&t<0&&-t/b<.15&&(t=0,n=!0),b=Math.abs(t-e));var v=b/x,m=v,y=Math.floor(Math.log10(m)),w=Math.pow(10,y),k=Math.ceil(m/w);if(v=m=(k=h.niceScaleAllowedMagMsd[0===h.yValueDecimal?0:1][k])*w,h.isBarHorizontal&&i.stepSize&&"datetime"!==i.type?(v=i.stepSize,d=!0):d&&(v=i.stepSize),d&&i.forceNiceScale){var A=Math.floor(Math.log10(v));v*=Math.pow(10,y-A)}if(s&&n){var S=b/x;if(u)if(d)if(0!=r.mod(b,v)){var C=r.getGCD(v,S);v=S/C<10?C:S}else 0==r.mod(v,S)?v=S:(S=v,u=!1);else v=S;else if(d)0==r.mod(b,v)?S=v:v=S;else if(0==r.mod(b,v))S=v;else{S=b/(x=Math.ceil(b/v));var P=r.getGCD(b,v);b/P<a&&(S=P),v=S}x=Math.round(b/v)}else{if(s||n){if(n)if(u)e=t-v*x;else{var L=e;e=v*Math.floor(e/v),Math.abs(t-e)/r.getGCD(b,v)>a&&(e=t-v*g,e+=v*Math.floor((L-e)/v))}else if(s)if(u)t=e+v*x;else{var O=t;t=v*Math.ceil(t/v),Math.abs(t-e)/r.getGCD(b,v)>a&&(t=e+v*g,t+=v*Math.ceil((O-t)/v))}}else if(u){var M=v/(t-e>t?1:2),T=M*Math.floor(e/M);Math.abs(T-e)<=M/2?t=(e=T)+v*x:e=(t=M*Math.ceil(t/M))-v*x}else e=v*Math.floor(e/v),t=v*Math.ceil(t/v);b=Math.abs(t-e),v=r.getGCD(b,v),x=Math.round(b/v)}if(u||s||n||(x=Math.ceil((b-l)/(v+l)))>16&&r.getPrimeFactors(x).length<2&&x++,!u&&i.forceNiceScale&&0===h.yValueDecimal&&x>b&&(x=b,v=Math.round(b/x)),x>a&&(!u&&!d||i.forceNiceScale)){var I=r.getPrimeFactors(x),E=I.length-1,z=x;e:for(var X=0;X<E;X++)for(var Y=0;Y<=E-X;Y++){for(var R=Math.min(Y+X,E),D=z,F=1,H=Y;H<=R;H++)F*=I[H];if((D/=F)<a){z=D;break e}}v=z===x?b:b/z,x=Math.round(b/v)}h.isMultipleYAxis&&0==h.multiAxisTickAmount&&h.ignoreYAxisIndexes.indexOf(o)<0&&(h.multiAxisTickAmount=x);var N=e-v,W=v*l;do{N+=v,p.push(r.stripNumber(N,7))}while(t-N>W);return{result:p,niceMin:p[0],niceMax:p[p.length-1]}}},{key:"linearScale",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0,s=Math.abs(t-e);"dataPoints"===(i=this._adjustTicksForSmallRange(i,a,s))&&(i=this.w.globals.dataPoints-1),r||(r=s/i),i===Number.MAX_VALUE&&(i=5,r=1);for(var n=[],o=e;i>=0;)n.push(o),o+=r,i-=1;return{result:n,niceMin:n[0],niceMax:n[n.length-1]}}},{key:"logarithmicScaleNice",value:function(e,t,i){t<=0&&(t=Math.max(e,i)),e<=0&&(e=Math.min(t,i));for(var a=[],r=Math.ceil(Math.log(t)/Math.log(i)+1),s=Math.floor(Math.log(e)/Math.log(i));s<r;s++)a.push(Math.pow(i,s));return{result:a,niceMin:a[0],niceMax:a[a.length-1]}}},{key:"logarithmicScale",value:function(e,t,i){t<=0&&(t=Math.max(e,i)),e<=0&&(e=Math.min(t,i));for(var a=[],r=Math.log(t)/Math.log(i),s=Math.log(e)/Math.log(i),n=r-s,o=Math.round(n),l=n/o,c=0,h=s;c<o;c++,h+=l)a.push(Math.pow(i,h));return a.push(Math.pow(i,r)),{result:a,niceMin:e,niceMax:t}}},{key:"_adjustTicksForSmallRange",value:function(e,t,i){var a=e;if(void 0!==t&&this.w.config.yaxis[t].labels.formatter&&void 0===this.w.config.yaxis[t].tickAmount){var s=Number(this.w.config.yaxis[t].labels.formatter(1));r.isNumber(s)&&0===this.w.globals.yValueDecimal&&(a=Math.ceil(i))}return a<e?a:e}},{key:"setYScaleForIndex",value:function(e,t,i){var a=this.w.globals,s=this.w.config,n=a.isBarHorizontal?s.xaxis:s.yaxis[e];void 0===a.yAxisScale[e]&&(a.yAxisScale[e]=[]);var o=Math.abs(i-t);n.logarithmic&&o<=5&&(a.invalidLogScale=!0),n.logarithmic&&o>5?(a.allSeriesCollapsed=!1,a.yAxisScale[e]=n.forceNiceScale?this.logarithmicScaleNice(t,i,n.logBase):this.logarithmicScale(t,i,n.logBase)):i!==-Number.MAX_VALUE&&r.isNumber(i)&&t!==Number.MAX_VALUE&&r.isNumber(t)?(a.allSeriesCollapsed=!1,a.yAxisScale[e]=this.niceScale(t,i,e)):a.yAxisScale[e]=this.niceScale(Number.MIN_VALUE,0,e)}},{key:"setXScale",value:function(e,t){var i=this.w,a=i.globals,s=Math.abs(t-e);return t!==-Number.MAX_VALUE&&r.isNumber(t)?a.xAxisScale=this.linearScale(e,t,i.config.xaxis.tickAmount?i.config.xaxis.tickAmount:s<10&&s>1?s+1:10,0,i.config.xaxis.stepSize):a.xAxisScale=this.linearScale(0,10,10),a.xAxisScale}},{key:"setSeriesYAxisMappings",value:function(){var e=this.w.globals,t=this.w.config,i=[],a=[],r=[],s=e.series.length>t.yaxis.length||t.yaxis.some((function(e){return Array.isArray(e.seriesName)}));t.series.forEach((function(e,t){r.push(t),a.push(null)})),t.yaxis.forEach((function(e,t){i[t]=[]}));var n=[];t.yaxis.forEach((function(e,a){var o=!1;if(e.seriesName){var l=[];Array.isArray(e.seriesName)?l=e.seriesName:l.push(e.seriesName),l.forEach((function(e){t.series.forEach((function(t,n){if(t.name===e){var l=n;a===n||s?!s||r.indexOf(n)>-1?i[a].push([a,n]):console.warn("Series '"+t.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(i[n].push([n,a]),l=a),o=!0,-1!==(l=r.indexOf(l))&&r.splice(l,1)}}))}))}o||n.push(a)})),i=i.map((function(e,t){var i=[];return e.forEach((function(e){a[e[1]]=e[0],i.push(e[1])})),i}));for(var o=t.yaxis.length-1,l=0;l<n.length&&(o=n[l],i[o]=[],r);l++){var c=r[0];r.shift(),i[o].push(c),a[c]=o}r.forEach((function(e){i[o].push(e),a[e]=o})),e.seriesYAxisMap=i.map((function(e){return e})),e.seriesYAxisReverseMap=a.map((function(e){return e}))}},{key:"scaleMultipleYAxes",value:function(){var e=this,t=this.w.config,i=this.w.globals;this.setSeriesYAxisMappings();var a=i.seriesYAxisMap,r=i.minYArr,s=i.maxYArr;i.allSeriesCollapsed=!0,i.barGroups=[],a.forEach((function(a,n){var o=[];a.forEach((function(e){var i=t.series[e].group;o.indexOf(i)<0&&o.push(i)})),a.length>0?function(){var l,c,h=Number.MAX_VALUE,d=-Number.MAX_VALUE,u=h,g=d;if(t.chart.stacked)!function(){var e=i.seriesX[a[0]],r=[],s=[],f=[];o.forEach((function(){r.push(e.map((function(){return Number.MIN_VALUE}))),s.push(e.map((function(){return Number.MIN_VALUE}))),f.push(e.map((function(){return Number.MIN_VALUE})))}));for(var p=function(e){!l&&t.series[a[e]].type&&(l=t.series[a[e]].type);var h=a[e];c=t.series[h].group?t.series[h].group:"axis-".concat(n),!(i.collapsedSeriesIndices.indexOf(h)<0&&i.ancillaryCollapsedSeriesIndices.indexOf(h)<0)||(i.allSeriesCollapsed=!1,o.forEach((function(e,a){if(t.series[h].group===e)for(var n=0;n<i.series[h].length;n++){var o=i.series[h][n];o>=0?s[a][n]+=o:f[a][n]+=o,r[a][n]+=o,u=Math.min(u,o),g=Math.max(g,o)}}))),"bar"!==l&&"column"!==l||i.barGroups.push(c)},x=0;x<a.length;x++)p(x);l||(l=t.chart.type),"bar"===l||"column"===l?o.forEach((function(e,t){h=Math.min(h,Math.min.apply(null,f[t])),d=Math.max(d,Math.max.apply(null,s[t]))})):(o.forEach((function(e,t){u=Math.min(u,Math.min.apply(null,r[t])),g=Math.max(g,Math.max.apply(null,r[t]))})),h=u,d=g),h===Number.MIN_VALUE&&d===Number.MIN_VALUE&&(d=-Number.MAX_VALUE)}();else for(var f=0;f<a.length;f++){var p=a[f];h=Math.min(h,r[p]),d=Math.max(d,s[p]),!(i.collapsedSeriesIndices.indexOf(p)<0&&i.ancillaryCollapsedSeriesIndices.indexOf(p)<0)||(i.allSeriesCollapsed=!1)}void 0!==t.yaxis[n].min&&(h="function"==typeof t.yaxis[n].min?t.yaxis[n].min(h):t.yaxis[n].min),void 0!==t.yaxis[n].max&&(d="function"==typeof t.yaxis[n].max?t.yaxis[n].max(d):t.yaxis[n].max),i.barGroups=i.barGroups.filter((function(e,t,i){return i.indexOf(e)===t})),e.setYScaleForIndex(n,h,d),a.forEach((function(e){r[e]=i.yAxisScale[n].niceMin,s[e]=i.yAxisScale[n].niceMax}))}():e.setYScaleForIndex(n,0,-Number.MAX_VALUE)}))}}],i&&we(t.prototype,i),e}();function Ae(e){return function(e){if(Array.isArray(e))return Ce(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Se(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Se(e,t){if(e){if("string"==typeof e)return Ce(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Ce(e,t):void 0}}function Ce(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Pe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const Le=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.scales=new ke(t)}var t,i;return t=e,i=[{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,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:-Number.MAX_VALUE,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=this.w.config,n=this.w.globals,o=-Number.MAX_VALUE,l=Number.MIN_VALUE;null===a&&(a=e+1);var c=0,h=0,d=void 0;if(n.seriesX.length>=a){var u,g;c=0,h=(d=Ae(new Set((u=[]).concat.apply(u,Ae(n.seriesX.slice(e,a)))))).length-1;var f=null===(g=n.brushSource)||void 0===g?void 0:g.w.config.chart.brush;if(s.chart.zoom.enabled&&s.chart.zoom.autoScaleYaxis||null!=f&&f.enabled&&null!=f&&f.autoScaleYaxis){if(s.xaxis.min)for(c=0;c<h&&d[c]<s.xaxis.min;c++);if(s.xaxis.max)for(;h>c&&d[h]>s.xaxis.max;h--);}}var p=n.series,x=p,b=p;"candlestick"===s.chart.type?(x=n.seriesCandleL,b=n.seriesCandleH):"boxPlot"===s.chart.type?(x=n.seriesCandleO,b=n.seriesCandleC):n.isRangeData&&(x=n.seriesRangeStart,b=n.seriesRangeEnd);for(var v=e;v<a;v++){n.dataPoints=Math.max(n.dataPoints,p[v].length);var m=s.series[v].type;n.categoryLabels.length&&(n.dataPoints=n.categoryLabels.filter((function(e){return void 0!==e})).length),n.labels.length&&"datetime"!==s.xaxis.type&&0!==n.series.reduce((function(e,t){return e+t.length}),0)&&(n.dataPoints=Math.max(n.dataPoints,n.labels.length)),d||(c=0,h=n.series[v].length);for(var y=c;y<=h&&y<n.series[v].length;y++){var w=p[v][y];if(null!==w&&r.isNumber(w)){switch(void 0!==b[v][y]&&(o=Math.max(o,b[v][y]),t=Math.min(t,b[v][y])),void 0!==x[v][y]&&(t=Math.min(t,x[v][y]),i=Math.max(i,x[v][y])),m){case"candlestick":void 0!==n.seriesCandleC[v][y]&&(o=Math.max(o,n.seriesCandleH[v][y]),t=Math.min(t,n.seriesCandleL[v][y]));break;case"boxPlot":void 0!==n.seriesCandleC[v][y]&&(o=Math.max(o,n.seriesCandleC[v][y]),t=Math.min(t,n.seriesCandleO[v][y]))}m&&"candlestick"!==m&&"boxPlot"!==m&&"rangeArea"!==m&&"rangeBar"!==m&&(o=Math.max(o,n.series[v][y]),t=Math.min(t,n.series[v][y])),i=o,n.seriesGoals[v]&&n.seriesGoals[v][y]&&Array.isArray(n.seriesGoals[v][y])&&n.seriesGoals[v][y].forEach((function(e){l!==Number.MIN_VALUE&&(l=Math.min(l,e.value),t=l),o=Math.max(o,e.value),i=o})),r.isFloat(w)&&(w=r.noExponents(w),n.yValueDecimal=Math.max(n.yValueDecimal,w.toString().split(".")[1].length)),l>x[v][y]&&x[v][y]<0&&(l=x[v][y])}else n.hasNullValues=!0}"bar"!==m&&"column"!==m||(l<0&&o<0&&(o=0,i=Math.max(i,0)),l===Number.MIN_VALUE&&(l=0,t=Math.min(t,0)))}return"rangeBar"===s.chart.type&&n.seriesRangeStart.length&&n.isBarHorizontal&&(l=t),"bar"===s.chart.type&&(l<0&&o<0&&(o=0),l===Number.MIN_VALUE&&(l=0)),{minY:l,maxY:o,lowestY:t,highestY:i}}},{key:"setYRange",value:function(){var e=this.w.globals,t=this.w.config;e.maxY=-Number.MAX_VALUE,e.minY=Number.MIN_VALUE;var i,a=Number.MAX_VALUE;if(e.isMultipleYAxis){a=Number.MAX_VALUE;for(var r=0;r<e.series.length;r++)i=this.getMinYMaxY(r),e.minYArr[r]=i.lowestY,e.maxYArr[r]=i.highestY,a=Math.min(a,i.lowestY)}return i=this.getMinYMaxY(0,a,null,e.series.length),"bar"===t.chart.type?(e.minY=i.minY,e.maxY=i.maxY):(e.minY=i.lowestY,e.maxY=i.highestY),a=i.lowestY,t.chart.stacked&&this._setStackedMinMax(),"line"===t.chart.type||"area"===t.chart.type||"scatter"===t.chart.type||"candlestick"===t.chart.type||"boxPlot"===t.chart.type||"rangeBar"===t.chart.type&&!e.isBarHorizontal?e.minY===Number.MIN_VALUE&&a!==-Number.MAX_VALUE&&a!==e.maxY&&(e.minY=a):e.minY=i.minY,t.yaxis.forEach((function(t,i){void 0!==t.max&&("number"==typeof t.max?e.maxYArr[i]=t.max:"function"==typeof t.max&&(e.maxYArr[i]=t.max(e.isMultipleYAxis?e.maxYArr[i]:e.maxY)),e.maxY=e.maxYArr[i]),void 0!==t.min&&("number"==typeof t.min?e.minYArr[i]=t.min:"function"==typeof t.min&&(e.minYArr[i]=t.min(e.isMultipleYAxis?e.minYArr[i]===Number.MIN_VALUE?0:e.minYArr[i]:e.minY)),e.minY=e.minYArr[i])})),e.isBarHorizontal&&["min","max"].forEach((function(i){void 0!==t.xaxis[i]&&"number"==typeof t.xaxis[i]&&("min"===i?e.minY=t.xaxis[i]:e.maxY=t.xaxis[i])})),e.isMultipleYAxis?(this.scales.scaleMultipleYAxes(),e.minY=a):(this.scales.setYScaleForIndex(0,e.minY,e.maxY),e.minY=e.yAxisScale[0].niceMin,e.maxY=e.yAxisScale[0].niceMax,e.minYArr[0]=e.minY,e.maxYArr[0]=e.maxY),e.barGroups=[],e.lineGroups=[],e.areaGroups=[],t.series.forEach((function(i){switch(i.type||t.chart.type){case"bar":case"column":e.barGroups.push(i.group);break;case"line":e.lineGroups.push(i.group);break;case"area":e.areaGroups.push(i.group)}})),e.barGroups=e.barGroups.filter((function(e,t,i){return i.indexOf(e)===t})),e.lineGroups=e.lineGroups.filter((function(e,t,i){return i.indexOf(e)===t})),e.areaGroups=e.areaGroups.filter((function(e,t,i){return i.indexOf(e)===t})),{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,i="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;t<e.series.length;t++)if(e.labels[t])for(var i=0;i<e.labels[t].length;i++)null!==e.labels[t][i]&&r.isNumber(e.labels[t][i])&&(e.maxX=Math.max(e.maxX,e.labels[t][i]),e.initialMaxX=Math.max(e.maxX,e.labels[t][i]),e.minX=Math.min(e.minX,e.labels[t][i]),e.initialMinX=Math.min(e.minX,e.labels[t][i]))}(),e.noLabelsProvided&&0===t.xaxis.categories.length&&(e.maxX=e.labels[e.labels.length-1],e.initialMaxX=e.labels[e.labels.length-1],e.minX=1,e.initialMinX=1),e.isXNumeric||e.noLabelsProvided||e.dataFormatXNumeric){var a;if(void 0===t.xaxis.tickAmount?(a=Math.round(e.svgWidth/150),"numeric"===t.xaxis.type&&e.dataPoints<30&&(a=e.dataPoints-1),a>e.dataPoints&&0!==e.dataPoints&&(a=e.dataPoints-1)):"dataPoints"===t.xaxis.tickAmount?(e.series.length>1&&(a=e.series[e.maxValsInArrayIndex].length-1),e.isXNumeric&&(a=e.maxX-e.minX-1)):a=t.xaxis.tickAmount,e.xTickAmount=a,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 s=[],n=e.minX-1;n<e.maxX;n++)s.push(n+1);e.xAxisScale={result:s,niceMin:s[0],niceMax:s[s.length-1]}}else e.xAxisScale=this.scales.setXScale(e.minX,e.maxX);else e.xAxisScale=this.scales.linearScale(0,a,a,0,t.xaxis.stepSize),e.noLabelsProvided&&e.labels.length>0&&(e.xAxisScale=this.scales.linearScale(1,e.labels.length,a-1,0,t.xaxis.stepSize),e.seriesX=e.labels.slice());i&&(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;t<e.series.length;t++)if(void 0!==e.seriesZ[t])for(var i=0;i<e.seriesZ[t].length;i++)null!==e.seriesZ[t][i]&&r.isNumber(e.seriesZ[t][i])&&(e.maxZ=Math.max(e.maxZ,e.seriesZ[t][i]),e.minZ=Math.min(e.minZ,e.seriesZ[t][i]))}},{key:"_handleSingleDataPoint",value:function(){var e=this.w.globals,t=this.w.config;if(e.minX===e.maxX){var i=new A(this.ctx);if("datetime"===t.xaxis.type){var a=i.getDate(e.minX);t.xaxis.labels.datetimeUTC?a.setUTCDate(a.getUTCDate()-2):a.setDate(a.getDate()-2),e.minX=new Date(a).getTime();var r=i.getDate(e.maxX);t.xaxis.labels.datetimeUTC?r.setUTCDate(r.getUTCDate()+2):r.setDate(r.getDate()+2),e.maxX=new Date(r).getTime()}else("numeric"===t.xaxis.type||"category"===t.xaxis.type&&!e.noLabelsProvided)&&(e.minX=e.minX-2,e.initialMinX=e.minX,e.maxX=e.maxX+2,e.initialMaxX=e.maxX)}}},{key:"_getMinXDiff",value:function(){var e=this.w.globals;e.isXNumeric&&e.seriesX.forEach((function(t,i){1===t.length&&t.push(e.seriesX[e.maxValsInArrayIndex][e.seriesX[e.maxValsInArrayIndex].length-1]);var a=t.slice();a.sort((function(e,t){return e-t})),a.forEach((function(t,i){if(i>0){var r=t-a[i-1];r>0&&(e.minXDiff=Math.min(r,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 i=t.seriesGroups;i.length||(i=[this.w.globals.seriesNames.map((function(e){return e}))]);var a={},s={};i.forEach((function(i){a[i]=[],s[i]=[],e.w.config.series.map((function(e,a){return i.indexOf(t.seriesNames[a])>-1?a:null})).filter((function(e){return null!==e})).forEach((function(n){for(var o=0;o<t.series[t.maxValsInArrayIndex].length;o++){var l,c,h,d;void 0===a[i][o]&&(a[i][o]=0,s[i][o]=0),(e.w.config.chart.stacked&&!t.comboCharts||e.w.config.chart.stacked&&t.comboCharts&&(!e.w.config.chart.stackOnlyBar||"bar"===(null===(l=e.w.config.series)||void 0===l||null===(c=l[n])||void 0===c?void 0:c.type)||"column"===(null===(h=e.w.config.series)||void 0===h||null===(d=h[n])||void 0===d?void 0:d.type)))&&null!==t.series[n][o]&&r.isNumber(t.series[n][o])&&(t.series[n][o]>0?a[i][o]+=parseFloat(t.series[n][o])+1e-4:s[i][o]+=parseFloat(t.series[n][o]))}}))})),Object.entries(a).forEach((function(e){var i,r,n=(i=e,r=1,function(e){if(Array.isArray(e))return e}(i)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var a,r,s=[],n=!0,o=!1;try{for(i=i.call(e);!(n=(a=i.next()).done)&&(s.push(a.value),!t||s.length!==t);n=!0);}catch(e){o=!0,r=e}finally{try{n||null==i.return||i.return()}finally{if(o)throw r}}return s}}(i,r)||Se(i,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0];a[n].forEach((function(e,i){t.maxY=Math.max(t.maxY,a[n][i]),t.minY=Math.min(t.minY,s[n][i])}))}))}}}],i&&Pe(t.prototype,i),e}();function Oe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Me=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.elgrid=i,this.w=t.w;var a=this.w;this.xaxisFontSize=a.config.xaxis.labels.style.fontSize,this.axisFontFamily=a.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=a.config.xaxis.labels.style.colors,this.isCategoryBarHorizontal="bar"===a.config.chart.type&&a.config.plotOptions.bar.horizontal,this.xAxisoffX=0,"bottom"===a.config.xaxis.position&&(this.xAxisoffX=a.globals.gridHeight),this.drawnLabels=[],this.axesUtils=new L(t)}var t,i;return t=e,(i=[{key:"drawYaxis",value:function(e){var t=this,i=this.w,a=new g(this.ctx),r=i.config.yaxis[e].labels.style,s=r.fontSize,n=r.fontFamily,o=r.fontWeight,l=a.group({class:"apexcharts-yaxis",rel:e,transform:"translate("+i.globals.translateYAxisX[e]+", 0)"});if(this.axesUtils.isYAxisHidden(e))return l;var c=a.group({class:"apexcharts-yaxis-texts-g"});l.add(c);var h=i.globals.yAxisScale[e].result.length-1,d=i.globals.gridHeight/h,u=i.globals.yLabelFormatters[e],f=i.globals.yAxisScale[e].result.slice();f=this.axesUtils.checkForReversedLabels(e,f);var p="";if(i.config.yaxis[e].labels.show){var x=i.globals.translateY+i.config.yaxis[e].labels.offsetY;i.globals.isBarHorizontal?x=0:"heatmap"===i.config.chart.type&&(x-=d/2),x+=parseInt(i.config.yaxis[e].labels.style.fontSize,10)/3;for(var b=function(l){var g=f[l];g=u(g,l,i);var b=i.config.yaxis[e].labels.padding;i.config.yaxis[e].opposite&&0!==i.config.yaxis.length&&(b*=-1);var v="end";i.config.yaxis[e].opposite&&(v="start"),"left"===i.config.yaxis[e].labels.align?v="start":"center"===i.config.yaxis[e].labels.align?v="middle":"right"===i.config.yaxis[e].labels.align&&(v="end");var m=t.axesUtils.getYAxisForeColor(r.colors,e),y=a.drawText({x:b,y:x,text:g,textAnchor:v,fontSize:s,fontFamily:n,fontWeight:o,maxWidth:i.config.yaxis[e].labels.maxWidth,foreColor:Array.isArray(m)?m[l]:m,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+r.cssClass});l===h&&(p=y),c.add(y);var w=document.createElementNS(i.globals.SVGNS,"title");if(w.textContent=Array.isArray(g)?g.join(" "):g,y.node.appendChild(w),0!==i.config.yaxis[e].labels.rotate){var k=a.rotateAroundCenter(p.node),A=a.rotateAroundCenter(y.node);y.node.setAttribute("transform","rotate(".concat(i.config.yaxis[e].labels.rotate," ").concat(k.x," ").concat(A.y,")"))}x+=d},v=h;v>=0;v--)b(v)}if(void 0!==i.config.yaxis[e].title.text){var m=a.group({class:"apexcharts-yaxis-title"}),y=0;i.config.yaxis[e].opposite&&(y=i.globals.translateYAxisX[e]);var w=a.drawText({x:y,y:i.globals.gridHeight/2+i.globals.translateY+i.config.yaxis[e].title.offsetY,text:i.config.yaxis[e].title.text,textAnchor:"end",foreColor:i.config.yaxis[e].title.style.color,fontSize:i.config.yaxis[e].title.style.fontSize,fontWeight:i.config.yaxis[e].title.style.fontWeight,fontFamily:i.config.yaxis[e].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+i.config.yaxis[e].title.style.cssClass});m.add(w),l.add(m)}var k=i.config.yaxis[e].axisBorder,A=31+k.offsetX;if(i.config.yaxis[e].opposite&&(A=-31-k.offsetX),k.show){var S=a.drawLine(A,i.globals.translateY+k.offsetY-2,A,i.globals.gridHeight+i.globals.translateY+k.offsetY+2,k.color,0,k.width);l.add(S)}return i.config.yaxis[e].axisTicks.show&&this.axesUtils.drawYAxisTicks(A,h,k,i.config.yaxis[e].axisTicks,e,d,l),l}},{key:"drawYaxisInversed",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-xaxis apexcharts-yaxis-inversed"}),r=i.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(t.globals.translateXAxisX,", ").concat(t.globals.translateXAxisY,")")});a.add(r);var s=t.globals.yAxisScale[e].result.length-1,n=t.globals.gridWidth/s+.1,o=n+t.config.xaxis.labels.offsetX,l=t.globals.xLabelFormatter,c=t.globals.yAxisScale[e].result.slice(),h=t.globals.timescaleLabels;h.length>0&&(this.xaxisLabels=h.slice(),s=(c=h.slice()).length),c=this.axesUtils.checkForReversedLabels(e,c);var d=h.length;if(t.config.xaxis.labels.show)for(var u=d?0:s;d?u<d:u>=0;d?u++:u--){var f=c[u];f=l(f,u,t);var p=t.globals.gridWidth+t.globals.padHorizontal-(o-n+t.config.xaxis.labels.offsetX);if(h.length){var x=this.axesUtils.getLabel(c,h,p,u,this.drawnLabels,this.xaxisFontSize);p=x.x,f=x.text,this.drawnLabels.push(x.text),0===u&&t.globals.skipFirstTimelinelabel&&(f=""),u===c.length-1&&t.globals.skipLastTimelinelabel&&(f="")}var b=i.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});r.add(b),b.tspan(f);var v=document.createElementNS(t.globals.SVGNS,"title");v.textContent=f,b.node.appendChild(v),o+=n}return this.inversedYAxisTitleText(a),this.inversedYAxisBorder(a),a}},{key:"inversedYAxisBorder",value:function(e){var t=this.w,i=new g(this.ctx),a=t.config.xaxis.axisBorder;if(a.show){var r=0;"bar"===t.config.chart.type&&t.globals.isXNumeric&&(r-=15);var s=i.drawLine(t.globals.padHorizontal+r+a.offsetX,this.xAxisoffX,t.globals.gridWidth,this.xAxisoffX,a.color,0,a.height);this.elgrid&&this.elgrid.elGridBorders&&t.config.grid.show?this.elgrid.elGridBorders.add(s):e.add(s)}}},{key:"inversedYAxisTitleText",value:function(e){var t=this.w,i=new g(this.ctx);if(void 0!==t.config.xaxis.title.text){var a=i.group({class:"apexcharts-xaxis-title apexcharts-yaxis-title-inversed"}),r=i.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});a.add(r),e.add(a)}}},{key:"yAxisTitleRotate",value:function(e,t){var i=this.w,a=new g(this.ctx),r={width:0,height:0},s={width:0,height:0},n=i.globals.dom.baseEl.querySelector(" .apexcharts-yaxis[rel='".concat(e,"'] .apexcharts-yaxis-texts-g"));null!==n&&(r=n.getBoundingClientRect());var o=i.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(e,"'] .apexcharts-yaxis-title text"));if(null!==o&&(s=o.getBoundingClientRect()),null!==o){var l=this.xPaddingForYAxisTitle(e,r,s,t);o.setAttribute("x",l.xPos-(t?10:0))}if(null!==o){var c=a.rotateAroundCenter(o);o.setAttribute("transform","rotate(".concat(t?-1*i.config.yaxis[e].title.rotate:i.config.yaxis[e].title.rotate," ").concat(c.x," ").concat(c.y,")"))}}},{key:"xPaddingForYAxisTitle",value:function(e,t,i,a){var r=this.w,s=0,n=0,o=10;return void 0===r.config.yaxis[e].title.text||e<0?{xPos:n,padd:0}:(a?(n=t.width+r.config.yaxis[e].title.offsetX+i.width/2+o/2,0===(s+=1)&&(n-=o/2)):(n=-1*t.width+r.config.yaxis[e].title.offsetX+o/2+i.width/2,r.globals.isBarHorizontal&&(o=25,n=-1*t.width-r.config.yaxis[e].title.offsetX-o)),{xPos:n,padd:o})}},{key:"setYAxisXPosition",value:function(e,t){var i=this.w,a=0,r=0,s=18,n=1;i.config.yaxis.length>1&&(this.multipleYs=!0),i.config.yaxis.map((function(o,l){var c=i.globals.ignoreYAxisIndexes.indexOf(l)>-1||!o.show||o.floating||0===e[l].width,h=e[l].width+t[l].width;o.opposite?i.globals.isBarHorizontal?(r=i.globals.gridWidth+i.globals.translateX-1,i.globals.translateYAxisX[l]=r-o.labels.offsetX):(r=i.globals.gridWidth+i.globals.translateX+n,c||(n=n+h+20),i.globals.translateYAxisX[l]=r-o.labels.offsetX+20):(a=i.globals.translateX-s,c||(s=s+h+20),i.globals.translateYAxisX[l]=a+o.labels.offsetX)}))}},{key:"setYAxisTextAlignments",value:function(){var e=this.w,t=e.globals.dom.baseEl.getElementsByClassName("apexcharts-yaxis");(t=r.listToArray(t)).forEach((function(t,i){var a=e.config.yaxis[i];if(a&&!a.floating&&void 0!==a.labels.align){var s=e.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(i,"'] .apexcharts-yaxis-texts-g")),n=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(i,"'] .apexcharts-yaxis-label"));n=r.listToArray(n);var o=s.getBoundingClientRect();"left"===a.labels.align?(n.forEach((function(e,t){e.setAttribute("text-anchor","start")})),a.opposite||s.setAttribute("transform","translate(-".concat(o.width,", 0)"))):"center"===a.labels.align?(n.forEach((function(e,t){e.setAttribute("text-anchor","middle")})),s.setAttribute("transform","translate(".concat(o.width/2*(a.opposite?1:-1),", 0)"))):"right"===a.labels.align&&(n.forEach((function(e,t){e.setAttribute("text-anchor","end")})),a.opposite&&s.setAttribute("transform","translate(".concat(o.width,", 0)")))}}))}}])&&Oe(t.prototype,i),e}();function Te(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ie=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.documentEvent=r.bind(this.documentEvent,this)}var t,i;return t=e,(i=[{key:"addEventListener",value:function(e,t){var i=this.w;i.globals.events.hasOwnProperty(e)?i.globals.events[e].push(t):i.globals.events[e]=[t]}},{key:"removeEventListener",value:function(e,t){var i=this.w;if(i.globals.events.hasOwnProperty(e)){var a=i.globals.events[e].indexOf(t);-1!==a&&i.globals.events[e].splice(a,1)}}},{key:"fireEvent",value:function(e,t){var i=this.w;if(i.globals.events.hasOwnProperty(e)){t&&t.length||(t=[]);for(var a=i.globals.events[e],r=a.length,s=0;s<r;s++)a[s].apply(null,t)}}},{key:"setupEventHandlers",value:function(){var e=this,t=this.w,i=this.ctx,a=t.globals.dom.baseEl.querySelector(t.globals.chartClass);this.ctx.eventList.forEach((function(e){a.addEventListener(e,(function(e){var a=Object.assign({},t,{seriesIndex:t.globals.axisCharts?t.globals.capturedSeriesIndex:0,dataPointIndex:t.globals.capturedDataPointIndex});"mousemove"===e.type||"touchmove"===e.type?"function"==typeof t.config.chart.events.mouseMove&&t.config.chart.events.mouseMove(e,i,a):"mouseleave"===e.type||"touchleave"===e.type?"function"==typeof t.config.chart.events.mouseLeave&&t.config.chart.events.mouseLeave(e,i,a):("mouseup"===e.type&&1===e.which||"touchend"===e.type)&&("function"==typeof t.config.chart.events.click&&t.config.chart.events.click(e,i,a),i.ctx.events.fireEvent("click",[e,i,a]))}),{capture:!1,passive:!0})})),this.ctx.eventList.forEach((function(i){t.globals.dom.baseEl.addEventListener(i,e.documentEvent,{passive:!0})})),this.ctx.core.setupBrushHandler()}},{key:"documentEvent",value:function(e){var t=this.w,i=e.target.className;if("click"===e.type){var a=t.globals.dom.baseEl.querySelector(".apexcharts-menu");a&&a.classList.contains("apexcharts-menu-open")&&"apexcharts-menu-icon"!==i&&a.classList.remove("apexcharts-menu-open")}t.globals.clientX="touchmove"===e.type?e.touches[0].clientX:e.clientX,t.globals.clientY="touchmove"===e.type?e.touches[0].clientY:e.clientY}}])&&Te(t.prototype,i),e}();function Ee(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ze=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"setCurrentLocaleValues",value:function(e){var t=this.w.config.chart.locales;window.Apex.chart&&window.Apex.chart.locales&&window.Apex.chart.locales.length>0&&(t=this.w.config.chart.locales.concat(window.Apex.chart.locales));var i=t.filter((function(t){return t.name===e}))[0];if(!i)throw new Error("Wrong locale name provided. Please make sure you set the correct locale name in options");var a=r.extend(E,i);this.w.globals.locale=a.options}}])&&Ee(t.prototype,i),e}();function Xe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ye=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"drawAxis",value:function(e,t){var i,a,r=this,s=this.w.globals,n=this.w.config,o=new ve(this.ctx,t),l=new Me(this.ctx,t);s.axisCharts&&"radar"!==e&&(s.isBarHorizontal?(a=l.drawYaxisInversed(0),i=o.drawXaxisInversed(0),s.dom.elGraphical.add(i),s.dom.elGraphical.add(a)):(i=o.drawXaxis(),s.dom.elGraphical.add(i),n.yaxis.map((function(e,t){if(-1===s.ignoreYAxisIndexes.indexOf(t)&&(a=l.drawYaxis(t),s.dom.Paper.add(a),"back"===r.w.config.grid.position)){var i=s.dom.Paper.children()[1];i.remove(),s.dom.Paper.add(i)}}))))}}])&&Xe(t.prototype,i),e}();function Re(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const De=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"drawXCrosshairs",value:function(){var e=this.w,t=new g(this.ctx),i=new l(this.ctx),a=e.config.xaxis.crosshairs.fill.gradient,s=e.config.xaxis.crosshairs.dropShadow,n=e.config.xaxis.crosshairs.fill.type,o=a.colorFrom,c=a.colorTo,h=a.opacityFrom,d=a.opacityTo,u=a.stops,f=s.enabled,p=s.left,x=s.top,b=s.blur,v=s.color,m=s.opacity,y=e.config.xaxis.crosshairs.fill.color;if(e.config.xaxis.crosshairs.show){"gradient"===n&&(y=t.drawGradient("vertical",o,c,h,d,null,u,null));var w=t.drawRect();1===e.config.xaxis.crosshairs.width&&(w=t.drawLine());var k=e.globals.gridHeight;(!r.isNumber(k)||k<0)&&(k=0);var A=e.config.xaxis.crosshairs.width;(!r.isNumber(A)||A<0)&&(A=0),w.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:k,width:A,height:k,fill:y,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}),f&&(w=i.dropShadow(w,{left:p,top:x,blur:b,color:v,opacity:m})),e.globals.dom.elGraphical.add(w)}}},{key:"drawYCrosshairs",value:function(){var e=this.w,t=new g(this.ctx),i=e.config.yaxis[0].crosshairs,a=e.globals.barPadForNumericAxis;if(e.config.yaxis[0].crosshairs.show){var r=t.drawLine(-a,0,e.globals.gridWidth+a,0,i.stroke.color,i.stroke.dashArray,i.stroke.width);r.attr({class:"apexcharts-ycrosshairs"}),e.globals.dom.elGraphical.add(r)}var s=t.drawLine(-a,0,e.globals.gridWidth+a,0,i.stroke.color,0,0);s.attr({class:"apexcharts-ycrosshairs-hidden"}),e.globals.dom.elGraphical.add(s)}}])&&Re(t.prototype,i),e}();function Fe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var He=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"checkResponsiveConfig",value:function(e){var t=this,i=this.w,a=i.config;if(0!==a.responsive.length){var s=a.responsive.slice();s.sort((function(e,t){return e.breakpoint>t.breakpoint?1:t.breakpoint>e.breakpoint?-1:0})).reverse();var n=new _({}),o=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=s[0].breakpoint,o=window.innerWidth>0?window.innerWidth:screen.width;if(o>a){var l=r.clone(i.globals.initialConfig);l.series=r.clone(i.config.series);var c=p.extendArrayProps(n,l,i);e=r.extend(c,e),e=r.extend(i.config,e),t.overrideResponsiveOptions(e)}else for(var h=0;h<s.length;h++)o<s[h].breakpoint&&(e=p.extendArrayProps(n,s[h].options,i),e=r.extend(i.config,e),t.overrideResponsiveOptions(e))};if(e){var l=p.extendArrayProps(n,e,i);l=r.extend(i.config,l),o(l=r.extend(l,e))}else o({})}}},{key:"overrideResponsiveOptions",value:function(e){var t=new _(e).init({responsiveOverride:!0});this.w.config=t}}],i&&Fe(t.prototype,i),e}();function Ne(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var We=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.colors=[],this.w=t.w;var i=this.w;this.isColorFn=!1,this.isHeatmapDistributed="treemap"===i.config.chart.type&&i.config.plotOptions.treemap.distributed||"heatmap"===i.config.chart.type&&i.config.plotOptions.heatmap.distributed,this.isBarDistributed=i.config.plotOptions.bar.distributed&&("bar"===i.config.chart.type||"rangeBar"===i.config.chart.type)}var t,i;return t=e,i=[{key:"init",value:function(){this.setDefaultColors()}},{key:"setDefaultColors",value:function(){var e,t=this,i=this.w,a=new r;if(i.globals.dom.elWrap.classList.add("apexcharts-theme-".concat(i.config.theme.mode)),void 0===i.config.colors||0===(null===(e=i.config.colors)||void 0===e?void 0:e.length)?i.globals.colors=this.predefined():(i.globals.colors=i.config.colors,Array.isArray(i.config.colors)&&i.config.colors.length>0&&"function"==typeof i.config.colors[0]&&(i.globals.colors=i.config.series.map((function(e,a){var r=i.config.colors[a];return r||(r=i.config.colors[0]),"function"==typeof r?(t.isColorFn=!0,r({value:i.globals.axisCharts?i.globals.series[a][0]?i.globals.series[a][0]:0:i.globals.series[a],seriesIndex:a,dataPointIndex:a,w:i})):r})))),i.globals.seriesColors.map((function(e,t){e&&(i.globals.colors[t]=e)})),i.config.theme.monochrome.enabled){var s=[],n=i.globals.series.length;(this.isBarDistributed||this.isHeatmapDistributed)&&(n=i.globals.series[0].length*i.globals.series.length);for(var o=i.config.theme.monochrome.color,l=1/(n/i.config.theme.monochrome.shadeIntensity),c=i.config.theme.monochrome.shadeTo,h=0,d=0;d<n;d++){var u=void 0;"dark"===c?(u=a.shadeColor(-1*h,o),h+=l):(u=a.shadeColor(h,o),h+=l),s.push(u)}i.globals.colors=s.slice()}var g=i.globals.colors.slice();this.pushExtraColors(i.globals.colors),["fill","stroke"].forEach((function(e){void 0===i.config[e].colors?i.globals[e].colors=t.isColorFn?i.config.colors:g:i.globals[e].colors=i.config[e].colors.slice(),t.pushExtraColors(i.globals[e].colors)})),void 0===i.config.dataLabels.style.colors?i.globals.dataLabels.style.colors=g:i.globals.dataLabels.style.colors=i.config.dataLabels.style.colors.slice(),this.pushExtraColors(i.globals.dataLabels.style.colors,50),void 0===i.config.plotOptions.radar.polygons.fill.colors?i.globals.radarPolygons.fill.colors=["dark"===i.config.theme.mode?"#424242":"none"]:i.globals.radarPolygons.fill.colors=i.config.plotOptions.radar.polygons.fill.colors.slice(),this.pushExtraColors(i.globals.radarPolygons.fill.colors,20),void 0===i.config.markers.colors?i.globals.markers.colors=g:i.globals.markers.colors=i.config.markers.colors.slice(),this.pushExtraColors(i.globals.markers.colors)}},{key:"pushExtraColors",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=this.w,r=t||a.globals.series.length;if(null===i&&(i=this.isBarDistributed||this.isHeatmapDistributed||"heatmap"===a.config.chart.type&&a.config.plotOptions.heatmap.colorScale.inverse),i&&a.globals.series.length&&(r=a.globals.series[a.globals.maxValsInArrayIndex].length*a.globals.series.length),e.length<r)for(var s=r-e.length,n=0;n<s;n++)e.push(e[n])}},{key:"updateThemeOptions",value:function(e){e.chart=e.chart||{},e.tooltip=e.tooltip||{};var t=e.theme.mode,i="dark"===t?"palette4":"light"===t?"palette1":e.theme.palette||"palette1",a="dark"===t?"#f6f7f8":"light"===t?"#373d3f":e.chart.foreColor||"#373d3f";return e.tooltip.theme=t||"light",e.chart.foreColor=a,e.theme.palette=i,e}},{key:"predefined",value:function(){switch(this.w.config.theme.palette){case"palette1":default:this.colors=["#008FFB","#00E396","#FEB019","#FF4560","#775DD0"];break;case"palette2":this.colors=["#3f51b5","#03a9f4","#4caf50","#f9ce1d","#FF9800"];break;case"palette3":this.colors=["#33b2df","#546E7A","#d4526e","#13d8aa","#A5978B"];break;case"palette4":this.colors=["#4ecdc4","#c7f464","#81D4FA","#fd6a6a","#546E7A"];break;case"palette5":this.colors=["#2b908f","#f9a3a4","#90ee7e","#fa4443","#69d2e7"];break;case"palette6":this.colors=["#449DD1","#F86624","#EA3546","#662E9B","#C5D86D"];break;case"palette7":this.colors=["#D7263D","#1B998B","#2E294E","#F46036","#E2C044"];break;case"palette8":this.colors=["#662E9B","#F86624","#F9C80E","#EA3546","#43BCCD"];break;case"palette9":this.colors=["#5C4742","#A5978B","#8D5B4C","#5A2A27","#C4BBAF"];break;case"palette10":this.colors=["#A300D6","#7D02EB","#5653FE","#2983FF","#00B1F2"]}return this.colors}}],i&&Ne(t.prototype,i),e}();function Be(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var je=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"draw",value:function(){this.drawTitleSubtitle("title"),this.drawTitleSubtitle("subtitle")}},{key:"drawTitleSubtitle",value:function(e){var t=this.w,i="title"===e?t.config.title:t.config.subtitle,a=t.globals.svgWidth/2,r=i.offsetY,s="middle";if("left"===i.align?(a=10,s="start"):"right"===i.align&&(a=t.globals.svgWidth-10,s="end"),a+=i.offsetX,r=r+parseInt(i.style.fontSize,10)+i.margin/2,void 0!==i.text){var n=new g(this.ctx).drawText({x:a,y:r,text:i.text,textAnchor:s,fontSize:i.style.fontSize,fontFamily:i.style.fontFamily,fontWeight:i.style.fontWeight,foreColor:i.style.color,opacity:1});n.node.setAttribute("class","apexcharts-".concat(e,"-text")),t.globals.dom.Paper.add(n)}}}])&&Be(t.prototype,i),e}();function Ge(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Ve(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var _e=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"getTitleSubtitleCoords",value:function(e){var t=this.w,i=0,a=0,r="title"===e?t.config.title.floating:t.config.subtitle.floating,s=t.globals.dom.baseEl.querySelector(".apexcharts-".concat(e,"-text"));if(null!==s&&!r){var n=s.getBoundingClientRect();i=n.width,a=t.globals.axisCharts?n.height+5:n.height}return{width:i,height:a}}},{key:"getLegendsRect",value:function(){var e=this.w,t=e.globals.dom.elLegendWrap;e.config.legend.height||"top"!==e.config.legend.position&&"bottom"!==e.config.legend.position||(t.style.maxHeight=e.globals.svgHeight/2+"px");var i=Object.assign({},r.getBoundingClientRect(t));return null!==t&&!e.config.legend.floating&&e.config.legend.show?this.dCtx.lgRect={x:i.x,y:i.y,height:i.height,width:0===i.height?0:i.width}:this.dCtx.lgRect={x:0,y:0,height:0,width:0},"left"!==e.config.legend.position&&"right"!==e.config.legend.position||1.5*this.dCtx.lgRect.width>e.globals.svgWidth&&(this.dCtx.lgRect.width=e.globals.svgWidth/1.5),this.dCtx.lgRect}},{key:"getDatalabelsRect",value:function(){var e=this,t=this.w,i=[];t.config.series.forEach((function(r,s){r.data.forEach((function(r,n){var o;o=t.globals.series[s][n],a=t.config.dataLabels.formatter(o,{ctx:e.dCtx.ctx,seriesIndex:s,dataPointIndex:n,w:t}),i.push(a)}))}));var a=r.getLargestStringFromArr(i),s=new g(this.dCtx.ctx),n=t.config.dataLabels.style,o=s.getTextRects(a,parseInt(n.fontSize),n.fontFamily);return{width:1.05*o.width,height:o.height}}},{key:"getLargestStringFromMultiArr",value:function(e,t){var i=e;if(this.w.globals.isMultiLineX){var a=t.map((function(e,t){return Array.isArray(e)?e.length:1})),r=Math.max.apply(Math,function(e){return function(e){if(Array.isArray(e))return Ge(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Ge(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Ge(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(a));i=t[a.indexOf(r)]}return i}}])&&Ve(t.prototype,i),e}();function Ue(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var qe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"getxAxisLabelsCoords",value:function(){var e,t=this.w,i=t.globals.labels.slice();if(t.config.xaxis.convertedCatToNumeric&&0===i.length&&(i=t.globals.categoryLabels),t.globals.timescaleLabels.length>0){var a=this.getxAxisTimeScaleLabelsCoords();e={width:a.width,height:a.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 s=t.globals.xLabelFormatter,n=r.getLargestStringFromArr(i),o=this.dCtx.dimHelpers.getLargestStringFromMultiArr(n,i);t.globals.isBarHorizontal&&(o=n=t.globals.yAxisScale[0].result.reduce((function(e,t){return e.length>t.length?e:t}),0));var l=new C(this.dCtx.ctx),c=n;n=l.xLabelFormat(s,n,c,{i:void 0,dateFormatter:new A(this.dCtx.ctx).formatDate,w:t}),o=l.xLabelFormat(s,o,c,{i:void 0,dateFormatter:new A(this.dCtx.ctx).formatDate,w:t}),(t.config.xaxis.convertedCatToNumeric&&void 0===n||""===String(n).trim())&&(o=n="1");var h=new g(this.dCtx.ctx),d=h.getTextRects(n,t.config.xaxis.labels.style.fontSize),u=d;if(n!==o&&(u=h.getTextRects(o,t.config.xaxis.labels.style.fontSize)),(e={width:d.width>=u.width?d.width:u.width,height:d.height>=u.height?d.height:u.height}).width*i.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 f=function(e){return h.getTextRects(e,t.config.xaxis.labels.style.fontSize,t.config.xaxis.labels.style.fontFamily,"rotate(".concat(t.config.xaxis.labels.rotate," 0 0)"),!1)};d=f(n),n!==o&&(u=f(o)),e.height=(d.height>u.height?d.height:u.height)/1.5,e.width=d.width>u.width?d.width:u.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 i,a=(null===(e=t.config.xaxis.group.style)||void 0===e?void 0:e.fontSize)||t.config.xaxis.labels.style.fontSize,s=t.globals.groups.map((function(e){return e.title})),n=r.getLargestStringFromArr(s),o=this.dCtx.dimHelpers.getLargestStringFromMultiArr(n,s),l=new g(this.dCtx.ctx),c=l.getTextRects(n,a),h=c;return n!==o&&(h=l.getTextRects(o,a)),i={width:c.width>=h.width?c.width:h.width,height:c.height>=h.height?c.height:h.height},t.config.xaxis.labels.show||(i={width:0,height:0}),{width:i.width,height:i.height}}},{key:"getxAxisTitleCoords",value:function(){var e=this.w,t=0,i=0;if(void 0!==e.config.xaxis.title.text){var a=new g(this.dCtx.ctx).getTextRects(e.config.xaxis.title.text,e.config.xaxis.title.style.fontSize);t=a.width,i=a.height}return{width:t,height:i}}},{key:"getxAxisTimeScaleLabelsCoords",value:function(){var e,t=this.w;this.dCtx.timescaleLabels=t.globals.timescaleLabels.slice();var i=this.dCtx.timescaleLabels.map((function(e){return e.value})),a=i.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 g(this.dCtx.ctx).getTextRects(a,t.config.xaxis.labels.style.fontSize)).width*i.length>t.globals.gridWidth&&0!==t.config.xaxis.labels.rotate&&(t.globals.overlappingXLabels=!0),e}},{key:"additionalPaddingXLabels",value:function(e){var t=this,i=this.w,a=i.globals,r=i.config,s=r.xaxis.type,n=e.width;a.skipLastTimelinelabel=!1,a.skipFirstTimelinelabel=!1;var o=i.config.yaxis[0].opposite&&i.globals.isBarHorizontal;r.yaxis.forEach((function(e,l){o?(t.dCtx.gridPad.left<n&&(t.dCtx.xPadLeft=n/2+1),t.dCtx.xPadRight=n/2+1):function(e,o){r.yaxis.length>1&&function(e){return-1!==a.collapsedSeriesIndices.indexOf(e)}(o)||function(e){if(t.dCtx.timescaleLabels&&t.dCtx.timescaleLabels.length){var o=t.dCtx.timescaleLabels[0],l=t.dCtx.timescaleLabels[t.dCtx.timescaleLabels.length-1].position+n/1.75-t.dCtx.yAxisWidthRight,c=o.position-n/1.75+t.dCtx.yAxisWidthLeft,h="right"===i.config.legend.position&&t.dCtx.lgRect.width>0?t.dCtx.lgRect.width:0;l>a.svgWidth-a.translateX-h&&(a.skipLastTimelinelabel=!0),c<-(e.show&&!e.floating||"bar"!==r.chart.type&&"candlestick"!==r.chart.type&&"rangeBar"!==r.chart.type&&"boxPlot"!==r.chart.type?10:n/1.75)&&(a.skipFirstTimelinelabel=!0)}else"datetime"===s?t.dCtx.gridPad.right<n&&!a.rotateXLabels&&(a.skipLastTimelinelabel=!0):"datetime"!==s&&t.dCtx.gridPad.right<n/2-t.dCtx.yAxisWidthRight&&!a.rotateXLabels&&!i.config.xaxis.labels.trim&&("between"!==i.config.xaxis.tickPlacement||i.globals.isBarHorizontal)&&(t.dCtx.xPadRight=n/2+1)}(e)}(e,l)}))}}])&&Ue(t.prototype,i),e}();function Ze(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var $e=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"getyAxisLabelsCoords",value:function(){var e=this,t=this.w,i=[],a=10,s=new L(this.dCtx.ctx);return t.config.yaxis.map((function(n,o){var l={seriesIndex:o,dataPointIndex:-1,w:t},c=t.globals.yAxisScale[o],h=0;if(!s.isYAxisHidden(o)&&n.labels.show&&void 0!==n.labels.minWidth&&(h=n.labels.minWidth),!s.isYAxisHidden(o)&&n.labels.show&&c.result.length){var d=t.globals.yLabelFormatters[o],u=c.niceMin===Number.MIN_VALUE?0:c.niceMin,f=c.result.reduce((function(e,t){var i,a;return(null===(i=String(d(e,l)))||void 0===i?void 0:i.length)>(null===(a=String(d(t,l)))||void 0===a?void 0:a.length)?e:t}),u),p=f=d(f,l);if(void 0!==f&&0!==f.length||(f=c.niceMax),t.globals.isBarHorizontal){a=0;var x=t.globals.labels.slice();f=r.getLargestStringFromArr(x),f=d(f,{seriesIndex:o,dataPointIndex:-1,w:t}),p=e.dCtx.dimHelpers.getLargestStringFromMultiArr(f,x)}var b=new g(e.dCtx.ctx),v="rotate(".concat(n.labels.rotate," 0 0)"),m=b.getTextRects(f,n.labels.style.fontSize,n.labels.style.fontFamily,v,!1),y=m;f!==p&&(y=b.getTextRects(p,n.labels.style.fontSize,n.labels.style.fontFamily,v,!1)),i.push({width:(h>y.width||h>m.width?h:y.width>m.width?y.width:m.width)+a,height:y.height>m.height?y.height:m.height})}else i.push({width:0,height:0})})),i}},{key:"getyAxisTitleCoords",value:function(){var e=this,t=this.w,i=[];return t.config.yaxis.map((function(t,a){if(t.show&&void 0!==t.title.text){var r=new g(e.dCtx.ctx),s="rotate(".concat(t.title.rotate," 0 0)"),n=r.getTextRects(t.title.text,t.title.style.fontSize,t.title.style.fontFamily,s,!1);i.push({width:n.width,height:n.height})}else i.push({width:0,height:0})})),i}},{key:"getTotalYAxisWidth",value:function(){var e=this.w,t=0,i=0,a=0,r=e.globals.yAxisScale.length>1?10:0,s=new L(this.dCtx.ctx),n=function(n,o){var l=e.config.yaxis[o].floating,c=0;n.width>0&&!l?(c=n.width+r,function(t){return e.globals.ignoreYAxisIndexes.indexOf(t)>-1}(o)&&(c=c-n.width-r)):c=l||s.isYAxisHidden(o)?0:5,e.config.yaxis[o].opposite?a+=c:i+=c,t+=c};return e.globals.yLabelsCoords.map((function(e,t){n(e,t)})),e.globals.yTitleCoords.map((function(e,t){n(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=i,this.dCtx.yAxisWidthRight=a,t}}])&&Ze(t.prototype,i),e}();function Je(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Qe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"gridPadForColumnsInNumericAxis",value:function(e){var t=this.w,i=t.config,a=t.globals;if(a.noData||a.collapsedSeries.length+a.ancillaryCollapsedSeries.length===i.series.length)return 0;var r=function(e){return"bar"===e||"rangeBar"===e||"candlestick"===e||"boxPlot"===e},s=i.chart.type,n=0,o=r(s)?i.series.length:1;a.comboBarCount>0&&(o=a.comboBarCount),a.collapsedSeries.forEach((function(e){r(e.type)&&(o-=1)})),i.chart.stacked&&(o=1);var l,c,h=r(s)||a.comboBarCount>0,d=Math.abs(a.initialMaxX-a.initialMinX);return h&&a.isXNumeric&&!a.isBarHorizontal&&o>0&&0!==d&&(d<=3&&(d=a.dataPoints),l=d/e,a.minXDiff&&a.minXDiff/l>0&&(c=a.minXDiff/l),c>e/2&&(c/=2),(n=c*parseInt(i.plotOptions.bar.columnWidth,10)/100)<1&&(n=1),a.barPadForNumericAxis=n),n}},{key:"gridPadFortitleSubtitle",value:function(){var e=this,t=this.w,i=t.globals,a=this.dCtx.isSparkline||!t.globals.axisCharts?0:10;["title","subtitle"].forEach((function(i){void 0!==t.config[i].text?a+=t.config[i].margin:a+=e.dCtx.isSparkline||!t.globals.axisCharts?0:5})),!t.config.legend.show||"bottom"!==t.config.legend.position||t.config.legend.floating||t.globals.axisCharts||(a+=10);var r=this.dCtx.dimHelpers.getTitleSubtitleCoords("title"),s=this.dCtx.dimHelpers.getTitleSubtitleCoords("subtitle");i.gridHeight=i.gridHeight-r.height-s.height-a,i.translateY=i.translateY+r.height+s.height+a}},{key:"setGridXPosForDualYAxis",value:function(e,t){var i=this.w,a=new L(this.dCtx.ctx);i.config.yaxis.map((function(r,s){-1!==i.globals.ignoreYAxisIndexes.indexOf(s)||r.floating||a.isYAxisHidden(s)||(r.opposite&&(i.globals.translateX=i.globals.translateX-(t[s].width+e[s].width)-parseInt(i.config.yaxis[s].labels.style.fontSize,10)/1.2-12),i.globals.translateX<2&&(i.globals.translateX=2))}))}}])&&Je(t.prototype,i),e}();function Ke(e,t){if(e){if("string"==typeof e)return et(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?et(e,t):void 0}}function et(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function tt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var it=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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 _e(this),this.dimYAxis=new $e(this),this.dimXAxis=new qe(this),this.dimGrid=new Qe(this),this.lgWidthForSideLegends=0,this.gridPad=this.w.config.grid.padding,this.xPadRight=0,this.xPadLeft=0}var t,i;return t=e,(i=[{key:"plotCoords",value:function(){var e=this,t=this.w,i=t.globals;this.lgRect=this.dimHelpers.getLegendsRect(),this.datalabelsCoords={width:0,height:0};var a,r=Array.isArray(t.config.stroke.width)?Math.max.apply(Math,function(e){if(Array.isArray(e))return et(e)}(a=t.config.stroke.width)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||Ke(a)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()):t.config.stroke.width;this.isSparkline&&((t.config.markers.discrete.length>0||t.config.markers.size>0)&&Object.entries(this.gridPad).forEach((function(t){var i=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var a,r,s=[],n=!0,o=!1;try{for(i=i.call(e);!(n=(a=i.next()).done)&&(s.push(a.value),!t||s.length!==t);n=!0);}catch(e){o=!0,r=e}finally{try{n||null==i.return||i.return()}finally{if(o)throw r}}return s}}(e,t)||Ke(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),a=i[0],r=i[1];e.gridPad[a]=Math.max(r,e.w.globals.markers.largestSize/1.5)})),this.gridPad.top=Math.max(r/2,this.gridPad.top),this.gridPad.bottom=Math.max(r/2,this.gridPad.bottom)),i.axisCharts?this.setDimensionsForAxisCharts():this.setDimensionsForNonAxisCharts(),this.dimGrid.gridPadFortitleSubtitle(),i.gridHeight=i.gridHeight-this.gridPad.top-this.gridPad.bottom,i.gridWidth=i.gridWidth-this.gridPad.left-this.gridPad.right-this.xPadRight-this.xPadLeft;var s=this.dimGrid.gridPadForColumnsInNumericAxis(i.gridWidth);i.gridWidth=i.gridWidth-2*s,i.translateX=i.translateX+this.gridPad.left+this.xPadLeft+(s>0?s:0),i.translateY=i.translateY+this.gridPad.top}},{key:"setDimensionsForAxisCharts",value:function(){var e=this,t=this.w,i=t.globals,a=this.dimYAxis.getyAxisLabelsCoords(),r=this.dimYAxis.getyAxisTitleCoords();i.isSlopeChart&&(this.datalabelsCoords=this.dimHelpers.getDatalabelsRect()),t.globals.yLabelsCoords=[],t.globals.yTitleCoords=[],t.config.yaxis.map((function(e,i){t.globals.yLabelsCoords.push({width:a[i].width,index:i}),t.globals.yTitleCoords.push({width:r[i].width,index:i})})),this.yAxisWidth=this.dimYAxis.getTotalYAxisWidth();var s=this.dimXAxis.getxAxisLabelsCoords(),n=this.dimXAxis.getxAxisGroupLabelsCoords(),o=this.dimXAxis.getxAxisTitleCoords();this.conditionalChecksForAxisCoords(s,o,n),i.translateXAxisY=t.globals.rotateXLabels?this.xAxisHeight/8:-4,i.translateXAxisX=t.globals.rotateXLabels&&t.globals.isXNumeric&&t.config.xaxis.labels.rotate<=-45?-this.xAxisWidth/4:0,t.globals.isBarHorizontal&&(i.rotateXLabels=!1,i.translateXAxisY=parseInt(t.config.xaxis.labels.style.fontSize,10)/1.5*-1),i.translateXAxisY=i.translateXAxisY+t.config.xaxis.labels.offsetY,i.translateXAxisX=i.translateXAxisX+t.config.xaxis.labels.offsetX;var l=this.yAxisWidth,c=this.xAxisHeight;i.xAxisLabelsHeight=this.xAxisHeight-o.height,i.xAxisGroupLabelsHeight=i.xAxisLabelsHeight-s.height,i.xAxisLabelsWidth=this.xAxisWidth,i.xAxisHeight=this.xAxisHeight;var h=10;("radar"===t.config.chart.type||this.isSparkline)&&(l=0,c=i.goldenPadding),this.isSparkline&&(this.lgRect={height:0,width:0}),(this.isSparkline||"treemap"===t.config.chart.type)&&(l=0,c=0,h=0),this.isSparkline||this.dimXAxis.additionalPaddingXLabels(s);var d=function(){i.translateX=l+e.datalabelsCoords.width,i.gridHeight=i.svgHeight-e.lgRect.height-c-(e.isSparkline||"treemap"===t.config.chart.type?0:t.globals.rotateXLabels?10:15),i.gridWidth=i.svgWidth-l-2*e.datalabelsCoords.width};switch("top"===t.config.xaxis.position&&(h=i.xAxisHeight-t.config.xaxis.axisTicks.height-5),t.config.legend.position){case"bottom":i.translateY=h,d();break;case"top":i.translateY=this.lgRect.height+h,d();break;case"left":i.translateY=h,i.translateX=this.lgRect.width+l+this.datalabelsCoords.width,i.gridHeight=i.svgHeight-c-12,i.gridWidth=i.svgWidth-this.lgRect.width-l-2*this.datalabelsCoords.width;break;case"right":i.translateY=h,i.translateX=l+this.datalabelsCoords.width,i.gridHeight=i.svgHeight-c-12,i.gridWidth=i.svgWidth-this.lgRect.width-l-2*this.datalabelsCoords.width-5;break;default:throw new Error("Legend position not supported")}this.dimGrid.setGridXPosForDualYAxis(r,a),new Me(this.ctx).setYAxisXPosition(a,r)}},{key:"setDimensionsForNonAxisCharts",value:function(){var e=this.w,t=e.globals,i=e.config,a=0;e.config.legend.show&&!e.config.legend.floating&&(a=20);var r="pie"===i.chart.type||"polarArea"===i.chart.type||"donut"===i.chart.type?"pie":"radialBar",s=i.plotOptions[r].offsetY,n=i.plotOptions[r].offsetX;if(!i.legend.show||i.legend.floating){t.gridHeight=t.svgHeight-i.grid.padding.top-i.grid.padding.bottom;var o=t.dom.elWrap.getBoundingClientRect().width;return t.gridWidth=Math.min(o,t.gridHeight)-i.grid.padding.left-i.grid.padding.right,t.translateY=s,void(t.translateX=n+(t.svgWidth-t.gridWidth)/2)}switch(i.legend.position){case"bottom":t.gridHeight=t.svgHeight-this.lgRect.height-t.goldenPadding,t.gridWidth=t.svgWidth,t.translateY=s-10,t.translateX=n+(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+s+10,t.translateX=n+(t.svgWidth-t.gridWidth)/2;break;case"left":t.gridWidth=t.svgWidth-this.lgRect.width-a,t.gridHeight="auto"!==i.chart.height?t.svgHeight:t.gridWidth,t.translateY=s,t.translateX=n+this.lgRect.width+a;break;case"right":t.gridWidth=t.svgWidth-this.lgRect.width-a-5,t.gridHeight="auto"!==i.chart.height?t.svgHeight:t.gridWidth,t.translateY=s,t.translateX=n+10;break;default:throw new Error("Legend position not supported")}}},{key:"conditionalChecksForAxisCoords",value:function(e,t,i){var a=this.w,r=a.globals.hasXaxisGroups?2:1,s=i.height+e.height+t.height,n=a.globals.isMultiLineX?1.2:a.globals.LINE_HEIGHT_RATIO,o=a.globals.rotateXLabels?22:10,l=a.globals.rotateXLabels&&"bottom"===a.config.legend.position?10:0;this.xAxisHeight=s*n+r*o+l,this.xAxisWidth=e.width,this.xAxisHeight-t.height>a.config.xaxis.labels.maxHeight&&(this.xAxisHeight=a.config.xaxis.labels.maxHeight),a.config.xaxis.labels.minHeight&&this.xAxisHeight<a.config.xaxis.labels.minHeight&&(this.xAxisHeight=a.config.xaxis.labels.minHeight),a.config.xaxis.floating&&(this.xAxisHeight=0);var c=0,h=0;a.config.yaxis.forEach((function(e){c+=e.labels.minWidth,h+=e.labels.maxWidth})),this.yAxisWidth<c&&(this.yAxisWidth=c),this.yAxisWidth>h&&(this.yAxisWidth=h)}}])&&tt(t.prototype,i),e}();function at(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var rt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.lgCtx=t}var t,i;return t=e,(i=[{key:"getLegendStyles",value:function(){var e,t,i,a=document.createElement("style");a.setAttribute("type","text/css");var r=(null===(e=this.lgCtx.ctx)||void 0===e||null===(t=e.opts)||void 0===t||null===(i=t.chart)||void 0===i?void 0:i.nonce)||this.w.config.chart.nonce;r&&a.setAttribute("nonce",r);var s=document.createTextNode("\n .apexcharts-legend {\n display: flex;\n overflow: auto;\n padding: 0 10px;\n }\n .apexcharts-legend.apx-legend-position-bottom, .apexcharts-legend.apx-legend-position-top {\n flex-wrap: wrap\n }\n .apexcharts-legend.apx-legend-position-right, .apexcharts-legend.apx-legend-position-left {\n flex-direction: column;\n bottom: 0;\n }\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 {\n justify-content: flex-start;\n }\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-center, .apexcharts-legend.apx-legend-position-top.apexcharts-align-center {\n justify-content: center;\n }\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-right, .apexcharts-legend.apx-legend-position-top.apexcharts-align-right {\n justify-content: flex-end;\n }\n .apexcharts-legend-series {\n cursor: pointer;\n line-height: normal;\n display: flex;\n }\n .apexcharts-legend.apx-legend-position-bottom .apexcharts-legend-series, .apexcharts-legend.apx-legend-position-top .apexcharts-legend-series{\n align-items: center;\n }\n .apexcharts-legend-text {\n position: relative;\n font-size: 14px;\n }\n .apexcharts-legend-text *, .apexcharts-legend-marker * {\n pointer-events: none;\n }\n .apexcharts-legend-marker {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n margin-right: 3px;\n }\n\n .apexcharts-legend-series.apexcharts-no-click {\n cursor: auto;\n }\n .apexcharts-legend .apexcharts-hidden-zero-series, .apexcharts-legend .apexcharts-hidden-null-series {\n display: none !important;\n }\n .apexcharts-inactive-legend {\n opacity: 0.45;\n }");return a.appendChild(s),a}},{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 i=this,a=this.w;if(a.globals.axisCharts||"radialBar"===a.config.chart.type){a.globals.resized=!0;var r=null,s=null;a.globals.risingSeries=[],a.globals.axisCharts?(r=a.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(e,"']")),s=parseInt(r.getAttribute("data:realIndex"),10)):(r=a.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(e+1,"']")),s=parseInt(r.getAttribute("rel"),10)-1),t?[{cs:a.globals.collapsedSeries,csi:a.globals.collapsedSeriesIndices},{cs:a.globals.ancillaryCollapsedSeries,csi:a.globals.ancillaryCollapsedSeriesIndices}].forEach((function(e){i.riseCollapsedSeries(e.cs,e.csi,s)})):this.hideSeries({seriesEl:r,realIndex:s})}else{var n=a.globals.dom.Paper.select(" .apexcharts-series[rel='".concat(e+1,"'] path")),o=a.config.chart.type;if("pie"===o||"polarArea"===o||"donut"===o){var l=a.config.plotOptions.pie.donut.labels;new g(this.lgCtx.ctx).pathMouseDown(n.members[0],null),this.lgCtx.ctx.pie.printDataLabelsInner(n.members[0].node,l)}n.fire("click")}}},{key:"hideSeries",value:function(e){var t=e.seriesEl,i=e.realIndex,a=this.w,s=a.globals,n=r.clone(a.config.series);if(s.axisCharts){var o=a.config.yaxis[s.seriesYAxisReverseMap[i]];if(o&&o.show&&o.showAlways)s.ancillaryCollapsedSeriesIndices.indexOf(i)<0&&(s.ancillaryCollapsedSeries.push({index:i,data:n[i].data.slice(),type:t.parentNode.className.baseVal.split("-")[1]}),s.ancillaryCollapsedSeriesIndices.push(i));else if(s.collapsedSeriesIndices.indexOf(i)<0){s.collapsedSeries.push({index:i,data:n[i].data.slice(),type:t.parentNode.className.baseVal.split("-")[1]}),s.collapsedSeriesIndices.push(i);var l=s.risingSeries.indexOf(i);s.risingSeries.splice(l,1)}}else s.collapsedSeries.push({index:i,data:n[i]}),s.collapsedSeriesIndices.push(i);for(var c=t.childNodes,h=0;h<c.length;h++)c[h].classList.contains("apexcharts-series-markers-wrap")&&(c[h].classList.contains("apexcharts-hide")?c[h].classList.remove("apexcharts-hide"):c[h].classList.add("apexcharts-hide"));s.allSeriesCollapsed=s.collapsedSeries.length+s.ancillaryCollapsedSeries.length===a.config.series.length,n=this._getSeriesBasedOnCollapsedState(n),this.lgCtx.ctx.updateHelpers._updateSeries(n,a.config.chart.animations.dynamicAnimation.enabled)}},{key:"riseCollapsedSeries",value:function(e,t,i){var a=this.w,s=r.clone(a.config.series);if(e.length>0){for(var n=0;n<e.length;n++)e[n].index===i&&(a.globals.axisCharts?(s[i].data=e[n].data.slice(),e.splice(n,1),t.splice(n,1),a.globals.risingSeries.push(i)):(s[i]=e[n].data,e.splice(n,1),t.splice(n,1),a.globals.risingSeries.push(i)));s=this._getSeriesBasedOnCollapsedState(s),this.lgCtx.ctx.updateHelpers._updateSeries(s,a.config.chart.animations.dynamicAnimation.enabled)}}},{key:"_getSeriesBasedOnCollapsedState",value:function(e){var t=this.w,i=0;return t.globals.axisCharts?e.forEach((function(a,r){t.globals.collapsedSeriesIndices.indexOf(r)<0&&t.globals.ancillaryCollapsedSeriesIndices.indexOf(r)<0||(e[r].data=[],i++)})):e.forEach((function(a,r){!t.globals.collapsedSeriesIndices.indexOf(r)<0&&(e[r]=0,i++)})),t.globals.allSeriesCollapsed=i===e.length,e}}])&&at(t.prototype,i),e}();function st(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function nt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?st(Object(i),!0).forEach((function(t){ot(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):st(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ot(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function lt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ct=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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 rt(this)}var t,i;return t=e,(i=[{key:"init",value:function(){var e=this.w,t=e.globals,i=e.config;if((i.legend.showForSingleSeries&&1===t.series.length||this.isBarsDistributed||t.series.length>1||!t.axisCharts)&&i.legend.show){for(;t.dom.elLegendWrap.firstChild;)t.dom.elLegendWrap.removeChild(t.dom.elLegendWrap.firstChild);this.drawLegends(),r.isIE11()?document.getElementsByTagName("head")[0].appendChild(this.legendHelpers.getLegendStyles()):this.legendHelpers.appendToForeignObject(),"bottom"===i.legend.position||"top"===i.legend.position?this.legendAlignHorizontal():"right"!==i.legend.position&&"left"!==i.legend.position||this.legendAlignVertical()}}},{key:"createLegendMarker",value:function(e){var t=e.i,i=e.fillcolor,a=this.w,r=document.createElement("span");r.classList.add("apexcharts-legend-marker");var s=a.config.legend.markers.shape||a.config.markers.shape,n=a.config.legend.markers.size,o=a.config.legend.markers.offsetX,l=a.config.legend.markers.offsetY,c=a.config.legend.markers.strokeWidth,h=a.config.legend.markers.strokeColor,d=a.config.legend.markers.radius,u=r.style;u.height=(Array.isArray(n)?2*parseFloat(n[t]):2*parseFloat(n))+"px",u.width=(Array.isArray(n)?2*parseFloat(n[t]):2*parseFloat(n))+"px",u.left=(Array.isArray(o)?parseFloat(o[t]):parseFloat(o))+"px",u.top=(Array.isArray(l)?parseFloat(l[t]):parseFloat(l))+"px",u.borderWidth=Array.isArray(c)?c[t]:c,u.borderColor=Array.isArray(h)?h[t]:h,u.borderRadius=Array.isArray(d)?parseFloat(d[t])+"px":parseFloat(d)+"px",a.config.legend.markers.customHTML&&(u.background="transparent",Array.isArray(a.config.legend.markers.customHTML)?a.config.legend.markers.customHTML[t]&&(r.innerHTML=a.config.legend.markers.customHTML[t]()):r.innerHTML=a.config.legend.markers.customHTML());var f=s;if(Array.isArray(s)&&(f=s[t]),"circle"!==f){var p=new ae(this.ctx).getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:t,size:n,pRadius:Array.isArray(d)?d[t]:d,strokeWidth:"plus"===f||"cross"===f||"line"===f?Array.isArray(c)?c[t]:c:0}),x=SVG(r).size("100%","100%"),b=new g(this.ctx).drawMarker(0,0,nt(nt({},p),{},{pointFillColor:Array.isArray(a.config.legend.markers.fillColors)?i[t]:p.pointFillColor,shape:f}));SVG.select(".apexcharts-marker").members.forEach((function(e){e.node.style.transform="translate(50%, 50%)"})),x.add(b)}else u.color=i[t],u.borderRadius="100%",a.config.legend.markers.customHTML||(u.background=i[t],u.setProperty("background",i[t],"important"),void 0!==a.globals.seriesColors[t]&&(u.background=a.globals.seriesColors[t],u.color=a.globals.seriesColors[t]));return r}},{key:"drawLegends",value:function(){var e=this,t=this.w,i=t.config.legend.fontFamily,a=t.globals.seriesNames,s=t.config.legend.markers.fillColors?t.config.legend.markers.fillColors.slice():t.globals.colors.slice();if("heatmap"===t.config.chart.type){var n=t.config.plotOptions.heatmap.colorScale.ranges;a=n.map((function(e){return e.name?e.name:e.from+" - "+e.to})),s=n.map((function(e){return e.color}))}else this.isBarsDistributed&&(a=t.globals.labels.slice());t.config.legend.customLegendItems.length&&(a=t.config.legend.customLegendItems);for(var o=t.globals.legendFormatter,l=t.config.legend.inverseOrder,c=l?a.length-1:0;l?c>=0:c<=a.length-1;l?c--:c++){var h,d=o(a[c],{seriesIndex:c,w:t}),u=!1,f=!1;if(t.globals.collapsedSeries.length>0)for(var x=0;x<t.globals.collapsedSeries.length;x++)t.globals.collapsedSeries[x].index===c&&(u=!0);if(t.globals.ancillaryCollapsedSeriesIndices.length>0)for(var b=0;b<t.globals.ancillaryCollapsedSeriesIndices.length;b++)t.globals.ancillaryCollapsedSeriesIndices[b]===c&&(f=!0);var v=this.createLegendMarker({i:c,fillcolor:s});g.setAttrs(v,{rel:c+1,"data:collapsed":u||f}),(u||f)&&v.classList.add("apexcharts-inactive-legend");var m=document.createElement("div"),y=document.createElement("span");y.classList.add("apexcharts-legend-text"),y.innerHTML=Array.isArray(d)?d.join(" "):d;var w=t.config.legend.labels.useSeriesColors?t.globals.colors[c]:Array.isArray(t.config.legend.labels.colors)?null===(h=t.config.legend.labels.colors)||void 0===h?void 0:h[c]:t.config.legend.labels.colors;w||(w=t.config.chart.foreColor),y.style.color=w,y.style.fontSize=parseFloat(t.config.legend.fontSize)+"px",y.style.fontWeight=t.config.legend.fontWeight,y.style.fontFamily=i||t.config.chart.fontFamily,g.setAttrs(y,{rel:c+1,i:c,"data:default-text":encodeURIComponent(d),"data:collapsed":u||f}),m.appendChild(v),m.appendChild(y);var k=new p(this.ctx);t.config.legend.showForZeroSeries||0===k.getSeriesTotalByIndex(c)&&k.seriesHaveSameValues(c)&&!k.isSeriesNull(c)&&-1===t.globals.collapsedSeriesIndices.indexOf(c)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(c)&&m.classList.add("apexcharts-hidden-zero-series"),t.config.legend.showForNullSeries||k.isSeriesNull(c)&&-1===t.globals.collapsedSeriesIndices.indexOf(c)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(c)&&m.classList.add("apexcharts-hidden-null-series"),t.globals.dom.elLegendWrap.appendChild(m),t.globals.dom.elLegendWrap.classList.add("apexcharts-align-".concat(t.config.legend.horizontalAlign)),t.globals.dom.elLegendWrap.classList.add("apx-legend-position-"+t.config.legend.position),m.classList.add("apexcharts-legend-series"),m.style.margin="".concat(t.config.legend.itemMargin.vertical,"px ").concat(t.config.legend.itemMargin.horizontal,"px"),t.globals.dom.elLegendWrap.style.width=t.config.legend.width?t.config.legend.width+"px":"",t.globals.dom.elLegendWrap.style.height=t.config.legend.height?t.config.legend.height+"px":"",g.setAttrs(m,{rel:c+1,seriesName:r.escapeString(a[c]),"data:collapsed":u||f}),(u||f)&&m.classList.add("apexcharts-inactive-legend"),t.config.legend.onItemClick.toggleDataSeries||m.classList.add("apexcharts-no-click")}t.globals.dom.elWrap.addEventListener("click",e.onLegendClick,!0),t.config.legend.onItemHover.highlightDataSeries&&0===t.config.legend.customLegendItems.length&&(t.globals.dom.elWrap.addEventListener("mousemove",e.onLegendHovered,!0),t.globals.dom.elWrap.addEventListener("mouseout",e.onLegendHovered,!0))}},{key:"setLegendWrapXY",value:function(e,t){var i=this.w,a=i.globals.dom.elLegendWrap,r=a.getBoundingClientRect(),s=0,n=0;if("bottom"===i.config.legend.position)n+=i.globals.svgHeight-r.height/2;else if("top"===i.config.legend.position){var o=new it(this.ctx),l=o.dimHelpers.getTitleSubtitleCoords("title").height,c=o.dimHelpers.getTitleSubtitleCoords("subtitle").height;n=n+(l>0?l-10:0)+(c>0?c-10:0)}a.style.position="absolute",s=s+e+i.config.legend.offsetX,n=n+t+i.config.legend.offsetY,a.style.left=s+"px",a.style.top=n+"px","bottom"===i.config.legend.position?(a.style.top="auto",a.style.bottom=5-i.config.legend.offsetY+"px"):"right"===i.config.legend.position&&(a.style.left="auto",a.style.right=25+i.config.legend.offsetX+"px"),["width","height"].forEach((function(e){a.style[e]&&(a.style[e]=parseInt(i.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(),i=new it(this.ctx),a=i.dimHelpers.getTitleSubtitleCoords("title"),r=i.dimHelpers.getTitleSubtitleCoords("subtitle"),s=0;"bottom"===e.config.legend.position?s=-t.clwh/1.8:"top"===e.config.legend.position&&(s=a.height+r.height+e.config.title.margin+e.config.subtitle.margin-10),this.setLegendWrapXY(20,s)}},{key:"legendAlignVertical",value:function(){var e=this.w,t=this.legendHelpers.getLegendBBox(),i=0;"left"===e.config.legend.position&&(i=20),"right"===e.config.legend.position&&(i=e.globals.svgWidth-t.clww-10),this.setLegendWrapXY(i,20)}},{key:"onLegendHovered",value:function(e){var t=this.w,i=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(i){var a=parseInt(e.target.getAttribute("rel"),10)-1;this.ctx.events.fireEvent("legendHover",[this.ctx,a,this.w]),new ce(this.ctx).highlightRangeInSeries(e,e.target)}}else!e.target.classList.contains("apexcharts-inactive-legend")&&i&&new ce(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 i=parseInt(e.target.getAttribute("rel"),10)-1,a="true"===e.target.getAttribute("data:collapsed"),r=this.w.config.chart.events.legendClick;"function"==typeof r&&r(this.ctx,i,this.w),this.ctx.events.fireEvent("legendClick",[this.ctx,i,this.w]);var s=this.w.config.legend.markers.onClick;"function"==typeof s&&e.target.classList.contains("apexcharts-legend-marker")&&(s(this.ctx,i,this.w),this.ctx.events.fireEvent("legendMarkerClick",[this.ctx,i,this.w])),"treemap"!==t.config.chart.type&&"heatmap"!==t.config.chart.type&&!this.isBarsDistributed&&t.config.legend.onItemClick.toggleDataSeries&&this.legendHelpers.toggleDataSeries(i,a)}}}])&&lt(t.prototype,i),e}();var ht=i(798),dt=i.n(ht),ut=i(688),gt=i.n(ut),ft=i(149),pt=i.n(ft),xt=i(323),bt=i.n(xt),vt=i(686),mt=i.n(vt),yt=i(618),wt=i.n(yt),kt=i(355),At=i.n(kt);function St(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ct=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.w;this.ev=this.w.config.chart.events,this.selectedClass="apexcharts-selected",this.localeValues=this.w.globals.locale.toolbar,this.minX=i.globals.minX,this.maxX=i.globals.maxX}var t,i;return t=e,(i=[{key:"createToolbar",value:function(){var e=this,t=this.w,i=function(){return document.createElement("div")},a=i();if(a.setAttribute("class","apexcharts-toolbar"),a.style.top=t.config.chart.toolbar.offsetY+"px",a.style.right=3-t.config.chart.toolbar.offsetX+"px",t.globals.dom.elWrap.appendChild(a),this.elZoom=i(),this.elZoomIn=i(),this.elZoomOut=i(),this.elPan=i(),this.elSelection=i(),this.elZoomReset=i(),this.elMenuIcon=i(),this.elMenu=i(),this.elCustomIcons=[],this.t=t.config.chart.toolbar.tools,Array.isArray(this.t.customIcons))for(var s=0;s<this.t.customIcons.length;s++)this.elCustomIcons.push(i());var n=[],o=function(i,a,r){var s=i.toLowerCase();e.t[s]&&t.config.chart.zoom.enabled&&n.push({el:a,icon:"string"==typeof e.t[s]?e.t[s]:r,title:e.localeValues[i],class:"apexcharts-".concat(s,"-icon")})};o("zoomIn",this.elZoomIn,bt()),o("zoomOut",this.elZoomOut,mt());var l=function(i){e.t[i]&&t.config.chart[i].enabled&&n.push({el:"zoom"===i?e.elZoom:e.elSelection,icon:"string"==typeof e.t[i]?e.t[i]:"zoom"===i?gt():wt(),title:e.localeValues["zoom"===i?"selectionZoom":"selection"],class:t.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-".concat(i,"-icon")})};l("zoom"),l("selection"),this.t.pan&&t.config.chart.zoom.enabled&&n.push({el:this.elPan,icon:"string"==typeof this.t.pan?this.t.pan:dt(),title:this.localeValues.pan,class:t.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-pan-icon"}),o("reset",this.elZoomReset,pt()),this.t.download&&n.push({el:this.elMenuIcon,icon:"string"==typeof this.t.download?this.t.download:At(),title:this.localeValues.menu,class:"apexcharts-menu-icon"});for(var c=0;c<this.elCustomIcons.length;c++)n.push({el:this.elCustomIcons[c],icon:this.t.customIcons[c].icon,title:this.t.customIcons[c].title,index:this.t.customIcons[c].index,class:"apexcharts-toolbar-custom-icon "+this.t.customIcons[c].class});n.forEach((function(e,t){e.index&&r.moveIndexInArray(n,t,e.index)}));for(var h=0;h<n.length;h++)g.setAttrs(n[h].el,{class:n[h].class,title:n[h].title}),n[h].el.innerHTML=n[h].icon,a.appendChild(n[h].el);this._createHamburgerMenu(a),t.globals.zoomEnabled?this.elZoom.classList.add(this.selectedClass):t.globals.panEnabled?this.elPan.classList.add(this.selectedClass):t.globals.selectionEnabled&&this.elSelection.classList.add(this.selectedClass),this.addToolbarEventListeners()}},{key:"_createHamburgerMenu",value:function(e){this.elMenuItems=[],e.appendChild(this.elMenu),g.setAttrs(this.elMenu,{class:"apexcharts-menu"});for(var t=[{name:"exportSVG",title:this.localeValues.exportToSVG},{name:"exportPNG",title:this.localeValues.exportToPNG},{name:"exportCSV",title:this.localeValues.exportToCSV}],i=0;i<t.length;i++)this.elMenuItems.push(document.createElement("div")),this.elMenuItems[i].innerHTML=t[i].title,g.setAttrs(this.elMenuItems[i],{class:"apexcharts-menu-item ".concat(t[i].name),title:t[i].title}),this.elMenu.appendChild(this.elMenuItems[i])}},{key:"addToolbarEventListeners",value:function(){var e=this;this.elZoomReset.addEventListener("click",this.handleZoomReset.bind(this)),this.elSelection.addEventListener("click",this.toggleZoomSelection.bind(this,"selection")),this.elZoom.addEventListener("click",this.toggleZoomSelection.bind(this,"zoom")),this.elZoomIn.addEventListener("click",this.handleZoomIn.bind(this)),this.elZoomOut.addEventListener("click",this.handleZoomOut.bind(this)),this.elPan.addEventListener("click",this.togglePanning.bind(this)),this.elMenuIcon.addEventListener("click",this.toggleMenu.bind(this)),this.elMenuItems.forEach((function(t){t.classList.contains("exportSVG")?t.addEventListener("click",e.handleDownload.bind(e,"svg")):t.classList.contains("exportPNG")?t.addEventListener("click",e.handleDownload.bind(e,"png")):t.classList.contains("exportCSV")&&t.addEventListener("click",e.handleDownload.bind(e,"csv"))}));for(var t=0;t<this.t.customIcons.length;t++)this.elCustomIcons[t].addEventListener("click",this.t.customIcons[t].click.bind(this,this.ctx,this.ctx.w))}},{key:"toggleZoomSelection",value:function(e){this.ctx.getSyncedCharts().forEach((function(t){t.ctx.toolbar.toggleOtherControls();var i="selection"===e?t.ctx.toolbar.elSelection:t.ctx.toolbar.elZoom,a="selection"===e?"selectionEnabled":"zoomEnabled";t.w.globals[a]=!t.w.globals[a],i.classList.contains(t.ctx.toolbar.selectedClass)?i.classList.remove(t.ctx.toolbar.selectedClass):i.classList.add(t.ctx.toolbar.selectedClass)}))}},{key:"getToolbarIconsReference",value:function(){var e=this.w;this.elZoom||(this.elZoom=e.globals.dom.baseEl.querySelector(".apexcharts-zoom-icon")),this.elPan||(this.elPan=e.globals.dom.baseEl.querySelector(".apexcharts-pan-icon")),this.elSelection||(this.elSelection=e.globals.dom.baseEl.querySelector(".apexcharts-selection-icon"))}},{key:"enableZoomPanFromToolbar",value:function(e){this.toggleOtherControls(),"pan"===e?this.w.globals.panEnabled=!0:this.w.globals.zoomEnabled=!0;var t="pan"===e?this.elPan:this.elZoom,i="pan"===e?this.elZoom:this.elPan;t&&t.classList.add(this.selectedClass),i&&i.classList.remove(this.selectedClass)}},{key:"togglePanning",value:function(){this.ctx.getSyncedCharts().forEach((function(e){e.ctx.toolbar.toggleOtherControls(),e.w.globals.panEnabled=!e.w.globals.panEnabled,e.ctx.toolbar.elPan.classList.contains(e.ctx.toolbar.selectedClass)?e.ctx.toolbar.elPan.classList.remove(e.ctx.toolbar.selectedClass):e.ctx.toolbar.elPan.classList.add(e.ctx.toolbar.selectedClass)}))}},{key:"toggleOtherControls",value:function(){var e=this,t=this.w;t.globals.panEnabled=!1,t.globals.zoomEnabled=!1,t.globals.selectionEnabled=!1,this.getToolbarIconsReference(),[this.elPan,this.elSelection,this.elZoom].forEach((function(t){t&&t.classList.remove(e.selectedClass)}))}},{key:"handleZoomIn",value:function(){var e=this.w;e.globals.isRangeBar&&(this.minX=e.globals.minY,this.maxX=e.globals.maxY);var t=(this.minX+this.maxX)/2,i=(this.minX+t)/2,a=(this.maxX+t)/2,r=this._getNewMinXMaxX(i,a);e.globals.disableZoomIn||this.zoomUpdateOptions(r.minX,r.maxX)}},{key:"handleZoomOut",value:function(){var e=this.w;if(e.globals.isRangeBar&&(this.minX=e.globals.minY,this.maxX=e.globals.maxY),!("datetime"===e.config.xaxis.type&&new Date(this.minX).getUTCFullYear()<1e3)){var t=(this.minX+this.maxX)/2,i=this.minX-(t-this.minX),a=this.maxX-(t-this.maxX),r=this._getNewMinXMaxX(i,a);e.globals.disableZoomOut||this.zoomUpdateOptions(r.minX,r.maxX)}}},{key:"_getNewMinXMaxX",value:function(e,t){var i=this.w.config.xaxis.convertedCatToNumeric;return{minX:i?Math.floor(e):e,maxX:i?Math.floor(t):t}}},{key:"zoomUpdateOptions",value:function(e,t){var i=this.w;if(void 0!==e||void 0!==t){if(!(i.config.xaxis.convertedCatToNumeric&&(e<1&&(e=1,t=i.globals.dataPoints),t-e<2))){var a={min:e,max:t},s=this.getBeforeZoomRange(a);s&&(a=s.xaxis);var n={xaxis:a},o=r.clone(i.globals.initialConfig.yaxis);i.config.chart.group||(n.yaxis=o),this.w.globals.zoomed=!0,this.ctx.updateHelpers._updateOptions(n,!1,this.w.config.chart.animations.dynamicAnimation.enabled),this.zoomCallback(a,o)}}else this.handleZoomReset()}},{key:"zoomCallback",value:function(e,t){"function"==typeof this.ev.zoomed&&this.ev.zoomed(this.ctx,{xaxis:e,yaxis:t})}},{key:"getBeforeZoomRange",value:function(e,t){var i=null;return"function"==typeof this.ev.beforeZoom&&(i=this.ev.beforeZoom(this,{xaxis:e,yaxis:t})),i}},{key:"toggleMenu",value:function(){var e=this;window.setTimeout((function(){e.elMenu.classList.contains("apexcharts-menu-open")?e.elMenu.classList.remove("apexcharts-menu-open"):e.elMenu.classList.add("apexcharts-menu-open")}),0)}},{key:"handleDownload",value:function(e){var t=this.w,i=new xe(this.ctx);switch(e){case"svg":i.exportToSVG(this.ctx);break;case"png":i.exportToPng(this.ctx);break;case"csv":i.exportToCSV({series:t.config.series,columnDelimiter:t.config.chart.toolbar.export.csv.columnDelimiter})}}},{key:"handleZoomReset",value:function(e){this.ctx.getSyncedCharts().forEach((function(e){var t=e.w;if(t.globals.lastXAxis.min=t.globals.initialConfig.xaxis.min,t.globals.lastXAxis.max=t.globals.initialConfig.xaxis.max,e.updateHelpers.revertDefaultAxisMinMax(),"function"==typeof t.config.chart.events.beforeResetZoom){var i=t.config.chart.events.beforeResetZoom(e,t);i&&e.updateHelpers.revertDefaultAxisMinMax(i)}"function"==typeof t.config.chart.events.zoomed&&e.ctx.toolbar.zoomCallback({min:t.config.xaxis.min,max:t.config.xaxis.max}),t.globals.zoomed=!1;var a=e.ctx.series.emptyCollapsedSeries(r.clone(t.globals.initialSeries));e.updateHelpers._updateSeries(a,t.config.chart.animations.dynamicAnimation.enabled)}))}},{key:"destroy",value:function(){this.elZoom=null,this.elZoomIn=null,this.elZoomOut=null,this.elPan=null,this.elSelection=null,this.elZoomReset=null,this.elMenuIcon=null}}])&&St(t.prototype,i),e}();function Pt(e){return Pt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pt(e)}function Lt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function Ot(e,t){return Ot=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Ot(e,t)}function Mt(e){return Mt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Mt(e)}var Tt=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ot(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Mt(a);if(s){var i=Mt(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Pt(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=n.call(this,e)).ctx=e,t.w=e.w,t.dragged=!1,t.graphics=new g(t.ctx),t.eventList=["mousedown","mouseleave","mousemove","touchstart","touchmove","mouseup","touchend"],t.clientX=0,t.clientY=0,t.startX=0,t.endX=0,t.dragX=0,t.startY=0,t.endY=0,t.dragY=0,t.moveDirection="none",t}return t=o,(i=[{key:"init",value:function(e){var t=this,i=e.xyRatios,a=this.w,r=this;this.xyRatios=i,this.zoomRect=this.graphics.drawRect(0,0,0,0),this.selectionRect=this.graphics.drawRect(0,0,0,0),this.gridRect=a.globals.dom.baseEl.querySelector(".apexcharts-grid"),this.zoomRect.node.classList.add("apexcharts-zoom-rect"),this.selectionRect.node.classList.add("apexcharts-selection-rect"),a.globals.dom.elGraphical.add(this.zoomRect),a.globals.dom.elGraphical.add(this.selectionRect),"x"===a.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,minY:0,maxX:a.globals.gridWidth,maxY:a.globals.gridHeight}).on("dragmove",this.selectionDragging.bind(this,"dragging")):"y"===a.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,maxX:a.globals.gridWidth}).on("dragmove",this.selectionDragging.bind(this,"dragging")):this.slDraggableRect=this.selectionRect.draggable().on("dragmove",this.selectionDragging.bind(this,"dragging")),this.preselectedSelection(),this.hoverArea=a.globals.dom.baseEl.querySelector("".concat(a.globals.chartClass," .apexcharts-svg")),this.hoverArea.classList.add("apexcharts-zoomable"),this.eventList.forEach((function(e){t.hoverArea.addEventListener(e,r.svgMouseEvents.bind(r,i),{capture:!1,passive:!0})}))}},{key:"destroy",value:function(){this.slDraggableRect&&(this.slDraggableRect.draggable(!1),this.slDraggableRect.off(),this.selectionRect.off()),this.selectionRect=null,this.zoomRect=null,this.gridRect=null}},{key:"svgMouseEvents",value:function(e,t){var i=this.w,a=this,r=this.ctx.toolbar,s=i.globals.zoomEnabled?i.config.chart.zoom.type:i.config.chart.selection.type,n=i.config.chart.toolbar.autoSelected;if(t.shiftKey?(this.shiftWasPressed=!0,r.enableZoomPanFromToolbar("pan"===n?"zoom":"pan")):this.shiftWasPressed&&(r.enableZoomPanFromToolbar(n),this.shiftWasPressed=!1),t.target){var o,l=t.target.classList;if(t.target.parentNode&&null!==t.target.parentNode&&(o=t.target.parentNode.classList),!(l.contains("apexcharts-selection-rect")||l.contains("apexcharts-legend-marker")||l.contains("apexcharts-legend-text")||o&&o.contains("apexcharts-toolbar"))){if(a.clientX="touchmove"===t.type||"touchstart"===t.type?t.touches[0].clientX:"touchend"===t.type?t.changedTouches[0].clientX:t.clientX,a.clientY="touchmove"===t.type||"touchstart"===t.type?t.touches[0].clientY:"touchend"===t.type?t.changedTouches[0].clientY:t.clientY,"mousedown"===t.type&&1===t.which){var c=a.gridRect.getBoundingClientRect();a.startX=a.clientX-c.left,a.startY=a.clientY-c.top,a.dragged=!1,a.w.globals.mousedown=!0}if(("mousemove"===t.type&&1===t.which||"touchmove"===t.type)&&(a.dragged=!0,i.globals.panEnabled?(i.globals.selection=null,a.w.globals.mousedown&&a.panDragging({context:a,zoomtype:s,xyRatios:e})):(a.w.globals.mousedown&&i.globals.zoomEnabled||a.w.globals.mousedown&&i.globals.selectionEnabled)&&(a.selection=a.selectionDrawing({context:a,zoomtype:s}))),"mouseup"===t.type||"touchend"===t.type||"mouseleave"===t.type){var h=a.gridRect.getBoundingClientRect();a.w.globals.mousedown&&(a.endX=a.clientX-h.left,a.endY=a.clientY-h.top,a.dragX=Math.abs(a.endX-a.startX),a.dragY=Math.abs(a.endY-a.startY),(i.globals.zoomEnabled||i.globals.selectionEnabled)&&a.selectionDrawn({context:a,zoomtype:s}),i.globals.panEnabled&&i.config.xaxis.convertedCatToNumeric&&a.delayedPanScrolled()),i.globals.zoomEnabled&&a.hideSelectionRect(this.selectionRect),a.dragged=!1,a.w.globals.mousedown=!1}this.makeSelectionRectDraggable()}}}},{key:"makeSelectionRectDraggable",value:function(){var e=this.w;if(this.selectionRect){var t=this.selectionRect.node.getBoundingClientRect();t.width>0&&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 i=(e.config.chart.selection.xaxis.min-e.globals.minX)/t.xRatio,a=e.globals.gridWidth-(e.globals.maxX-e.config.chart.selection.xaxis.max)/t.xRatio-i;e.globals.isRangeBar&&(i=(e.config.chart.selection.xaxis.min-e.globals.yAxisScale[0].niceMin)/t.invertedYRatio,a=(e.config.chart.selection.xaxis.max-e.config.chart.selection.xaxis.min)/t.invertedYRatio);var r={x:i,y:0,width:a,height:e.globals.gridHeight,translateX:0,translateY:0,selectionEnabled:!0};this.drawSelectionRect(r),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,i=e.y,a=e.width,r=e.height,s=e.translateX,n=void 0===s?0:s,o=e.translateY,l=void 0===o?0:o,c=this.w,h=this.zoomRect,d=this.selectionRect;if(this.dragged||null!==c.globals.selection){var u={transform:"translate("+n+", "+l+")"};c.globals.zoomEnabled&&this.dragged&&(a<0&&(a=1),h.attr({x:t,y:i,width:a,height:r,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}),g.setAttrs(h.node,u)),c.globals.selectionEnabled&&(d.attr({x:t,y:i,width:a>0?a:0,height:r>0?r: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}),g.setAttrs(d.node,u))}}},{key:"hideSelectionRect",value:function(e){e&&e.attr({x:0,y:0,width:0,height:0})}},{key:"selectionDrawing",value:function(e){var t,i=e.context,a=e.zoomtype,r=this.w,s=i,n=this.gridRect.getBoundingClientRect(),o=s.startX-1,l=s.startY,c=!1,h=!1,d=s.clientX-n.left-o,u=s.clientY-n.top-l;return Math.abs(d+o)>r.globals.gridWidth?d=r.globals.gridWidth-o:s.clientX-n.left<0&&(d=o),o>s.clientX-n.left&&(c=!0,d=Math.abs(d)),l>s.clientY-n.top&&(h=!0,u=Math.abs(u)),t="x"===a?{x:c?o-d:o,y:0,width:d,height:r.globals.gridHeight}:"y"===a?{x:0,y:h?l-u:l,width:r.globals.gridWidth,height:u}:{x:c?o-d:o,y:h?l-u:l,width:d,height:u},s.drawSelectionRect(t),s.selectionDragging("resizing"),t}},{key:"selectionDragging",value:function(e,t){var i=this,a=this.w,r=this.xyRatios,s=this.selectionRect,n=0;"resizing"===e&&(n=30);var o=function(e){return parseFloat(s.node.getAttribute(e))},l={x:o("x"),y:o("y"),width:o("width"),height:o("height")};a.globals.selection=l,"function"==typeof a.config.chart.events.selection&&a.globals.selectionEnabled&&(clearTimeout(this.w.globals.selectionResizeTimer),this.w.globals.selectionResizeTimer=window.setTimeout((function(){var e,t,n,o,l=i.gridRect.getBoundingClientRect(),c=s.node.getBoundingClientRect();a.globals.isRangeBar?(e=a.globals.yAxisScale[0].niceMin+(c.left-l.left)*r.invertedYRatio,t=a.globals.yAxisScale[0].niceMin+(c.right-l.left)*r.invertedYRatio,n=0,o=1):(e=a.globals.xAxisScale.niceMin+(c.left-l.left)*r.xRatio,t=a.globals.xAxisScale.niceMin+(c.right-l.left)*r.xRatio,n=a.globals.yAxisScale[0].niceMin+(l.bottom-c.bottom)*r.yRatio[0],o=a.globals.yAxisScale[0].niceMax-(c.top-l.top)*r.yRatio[0]);var h={xaxis:{min:e,max:t},yaxis:{min:n,max:o}};a.config.chart.events.selection(i.ctx,h),a.config.chart.brush.enabled&&void 0!==a.config.chart.events.brushScrolled&&a.config.chart.events.brushScrolled(i.ctx,h)}),n))}},{key:"selectionDrawn",value:function(e){var t=e.context,i=e.zoomtype,a=this.w,s=t,n=this.xyRatios,o=this.ctx.toolbar;if(s.startX>s.endX){var l=s.startX;s.startX=s.endX,s.endX=l}if(s.startY>s.endY){var c=s.startY;s.startY=s.endY,s.endY=c}var h=void 0,d=void 0;a.globals.isRangeBar?(h=a.globals.yAxisScale[0].niceMin+s.startX*n.invertedYRatio,d=a.globals.yAxisScale[0].niceMin+s.endX*n.invertedYRatio):(h=a.globals.xAxisScale.niceMin+s.startX*n.xRatio,d=a.globals.xAxisScale.niceMin+s.endX*n.xRatio);var u=[],g=[];if(a.config.yaxis.forEach((function(e,t){if(a.globals.seriesYAxisMap[t].length>0){var i=a.globals.seriesYAxisMap[t][0];u.push(a.globals.yAxisScale[t].niceMax-n.yRatio[i]*s.startY),g.push(a.globals.yAxisScale[t].niceMax-n.yRatio[i]*s.endY)}})),s.dragged&&(s.dragX>10||s.dragY>10)&&h!==d)if(a.globals.zoomEnabled){var f=r.clone(a.globals.initialConfig.yaxis),p=r.clone(a.globals.initialConfig.xaxis);if(a.globals.zoomed=!0,a.config.xaxis.convertedCatToNumeric&&(h=Math.floor(h),d=Math.floor(d),h<1&&(h=1,d=a.globals.dataPoints),d-h<2&&(d=h+1)),"xy"!==i&&"x"!==i||(p={min:h,max:d}),"xy"!==i&&"y"!==i||f.forEach((function(e,t){f[t].min=g[t],f[t].max=u[t]})),o){var x=o.getBeforeZoomRange(p,f);x&&(p=x.xaxis?x.xaxis:p,f=x.yaxis?x.yaxis:f)}var b={xaxis:p};a.config.chart.group||(b.yaxis=f),s.ctx.updateHelpers._updateOptions(b,!1,s.w.config.chart.animations.dynamicAnimation.enabled),"function"==typeof a.config.chart.events.zoomed&&o.zoomCallback(p,f)}else if(a.globals.selectionEnabled){var v,m=null;v={min:h,max:d},"xy"!==i&&"y"!==i||(m=r.clone(a.config.yaxis)).forEach((function(e,t){m[t].min=g[t],m[t].max=u[t]})),a.globals.selection=s.selection,"function"==typeof a.config.chart.events.selection&&a.config.chart.events.selection(s.ctx,{xaxis:v,yaxis:m})}}},{key:"panDragging",value:function(e){var t=e.context,i=this.w,a=t;if(void 0!==i.globals.lastClientPosition.x){var r=i.globals.lastClientPosition.x-a.clientX,s=i.globals.lastClientPosition.y-a.clientY;Math.abs(r)>Math.abs(s)&&r>0?this.moveDirection="left":Math.abs(r)>Math.abs(s)&&r<0?this.moveDirection="right":Math.abs(s)>Math.abs(r)&&s>0?this.moveDirection="up":Math.abs(s)>Math.abs(r)&&s<0&&(this.moveDirection="down")}i.globals.lastClientPosition={x:a.clientX,y:a.clientY};var n=i.globals.isRangeBar?i.globals.minY:i.globals.minX,o=i.globals.isRangeBar?i.globals.maxY:i.globals.maxX;i.config.xaxis.convertedCatToNumeric||a.panScrolled(n,o)}},{key:"delayedPanScrolled",value:function(){var e=this.w,t=e.globals.minX,i=e.globals.maxX,a=(e.globals.maxX-e.globals.minX)/2;"left"===this.moveDirection?(t=e.globals.minX+a,i=e.globals.maxX+a):"right"===this.moveDirection&&(t=e.globals.minX-a,i=e.globals.maxX-a),t=Math.floor(t),i=Math.floor(i),this.updateScrolledChart({xaxis:{min:t,max:i}},t,i)}},{key:"panScrolled",value:function(e,t){var i=this.w,a=this.xyRatios,s=r.clone(i.globals.initialConfig.yaxis),n=a.xRatio,o=i.globals.minX,l=i.globals.maxX;i.globals.isRangeBar&&(n=a.invertedYRatio,o=i.globals.minY,l=i.globals.maxY),"left"===this.moveDirection?(e=o+i.globals.gridWidth/15*n,t=l+i.globals.gridWidth/15*n):"right"===this.moveDirection&&(e=o-i.globals.gridWidth/15*n,t=l-i.globals.gridWidth/15*n),i.globals.isRangeBar||(e<i.globals.initialMinX||t>i.globals.initialMaxX)&&(e=o,t=l);var c={xaxis:{min:e,max:t}};i.config.chart.group||(c.yaxis=s),this.updateScrolledChart(c,e,t)}},{key:"updateScrolledChart",value:function(e,t,i){var a=this.w;this.ctx.updateHelpers._updateOptions(e,!1,!1),"function"==typeof a.config.chart.events.scrolled&&a.config.chart.events.scrolled(this.ctx,{xaxis:{min:t,max:i}})}}])&&Lt(t.prototype,i),o}(Ct);function It(e){return function(e){if(Array.isArray(e))return Et(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Et(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Et(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Et(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function zt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Xt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ttCtx=t,this.ctx=t.ctx}var t,i;return t=e,(i=[{key:"getNearestValues",value:function(e){var t=e.hoverArea,i=e.elGrid,a=e.clientX,s=e.clientY,n=this.w,o=i.getBoundingClientRect(),l=o.width,c=o.height,h=l/(n.globals.dataPoints-1),d=c/n.globals.dataPoints,u=this.hasBars();!n.globals.comboCharts&&!u||n.config.xaxis.convertedCatToNumeric||(h=l/n.globals.dataPoints);var g=a-o.left-n.globals.barPadForNumericAxis,f=s-o.top;g<0||f<0||g>l||f>c?(t.classList.remove("hovering-zoom"),t.classList.remove("hovering-pan")):n.globals.zoomEnabled?(t.classList.remove("hovering-pan"),t.classList.add("hovering-zoom")):n.globals.panEnabled&&(t.classList.remove("hovering-zoom"),t.classList.add("hovering-pan"));var p=Math.round(g/h),x=Math.floor(f/d);u&&!n.config.xaxis.convertedCatToNumeric&&(p=Math.ceil(g/h),p-=1);var b=null,v=null,m=n.globals.seriesXvalues.map((function(e){return e.filter((function(e){return r.isNumber(e)}))})),y=n.globals.seriesYvalues.map((function(e){return e.filter((function(e){return r.isNumber(e)}))}));if(n.globals.isXNumeric){var w=this.ttCtx.getElGrid().getBoundingClientRect(),k=g*(w.width/l),A=f*(w.height/c);b=(v=this.closestInMultiArray(k,A,m,y)).index,p=v.j,null!==b&&(m=n.globals.seriesXvalues[b],p=(v=this.closestInArray(k,m)).index)}return n.globals.capturedSeriesIndex=null===b?-1:b,(!p||p<1)&&(p=0),n.globals.isBarHorizontal?n.globals.capturedDataPointIndex=x:n.globals.capturedDataPointIndex=p,{capturedSeries:b,j:n.globals.isBarHorizontal?x:p,hoverX:g,hoverY:f}}},{key:"closestInMultiArray",value:function(e,t,i,a){var r=this.w,s=0,n=null,o=-1;r.globals.series.length>1?s=this.getFirstActiveXArray(i):n=0;var l=i[s][0],c=Math.abs(e-l);if(i.forEach((function(t){t.forEach((function(t,i){var a=Math.abs(e-t);a<=c&&(c=a,o=i)}))})),-1!==o){var h=a[s][o],d=Math.abs(t-h);n=s,a.forEach((function(e,i){var a=Math.abs(t-e[o]);a<=d&&(d=a,n=i)}))}return{index:n,j:o}}},{key:"getFirstActiveXArray",value:function(e){for(var t=this.w,i=0,a=e.map((function(e,t){return e.length>0?t:-1})),r=0;r<a.length;r++)if(-1!==a[r]&&-1===t.globals.collapsedSeriesIndices.indexOf(r)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(r)){i=a[r];break}return i}},{key:"closestInArray",value:function(e,t){for(var i=t[0],a=null,r=Math.abs(e-i),s=0;s<t.length;s++){var n=Math.abs(e-t[s]);n<r&&(r=n,a=s)}return{index:a}}},{key:"isXoverlap",value:function(e){var t=[],i=this.w.globals.seriesX.filter((function(e){return void 0!==e[0]}));if(i.length>0)for(var a=0;a<i.length-1;a++)void 0!==i[a][e]&&void 0!==i[a+1][e]&&i[a][e]!==i[a+1][e]&&t.push("unEqual");return 0===t.length}},{key:"isInitialSeriesSameLen",value:function(){for(var e=!0,t=this.w.globals.initialSeries,i=0;i<t.length-1;i++)if(t[i].data.length!==t[i+1].data.length){e=!1;break}return e}},{key:"getBarsHeight",value:function(e){return It(e).reduce((function(e,t){return e+t.getBBox().height}),0)}},{key:"getElMarkers",value:function(e){return"number"==typeof e?this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series[data\\:realIndex='".concat(e,"'] .apexcharts-series-markers-wrap > *")):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=It(e)).sort((function(e,t){var i=Number(e.getAttribute("data:realIndex")),a=Number(t.getAttribute("data:realIndex"));return a<i?1:a>i?-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,i=t.config.markers.hover.size;return void 0===i&&(i=t.globals.markers.size[e]+t.config.markers.hover.sizeOffset),i}},{key:"toggleAllTooltipSeriesGroups",value:function(e){var t=this.w,i=this.ttCtx;0===i.allTooltipSeriesGroups.length&&(i.allTooltipSeriesGroups=t.globals.dom.baseEl.querySelectorAll(".apexcharts-tooltip-series-group"));for(var a=i.allTooltipSeriesGroups,r=0;r<a.length;r++)"enable"===e?(a[r].classList.add("apexcharts-active"),a[r].style.display=t.config.tooltip.items.display):(a[r].classList.remove("apexcharts-active"),a[r].style.display="none")}}])&&zt(t.prototype,i),e}();function Yt(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Rt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Yt(Object(i),!0).forEach((function(t){Dt(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Yt(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Dt(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Ft(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ht=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ctx=t.ctx,this.ttCtx=t,this.tooltipUtil=new Xt(t)}var t,i;return t=e,(i=[{key:"drawSeriesTexts",value:function(e){var t=e.shared,i=void 0===t||t,a=e.ttItems,r=e.i,s=void 0===r?0:r,n=e.j,o=void 0===n?null:n,l=e.y1,c=e.y2,h=e.e,d=this.w;void 0!==d.config.tooltip.custom?this.handleCustomTooltip({i:s,j:o,y1:l,y2:c,w:d}):this.toggleActiveInactiveSeries(i);var u=this.getValuesToPrint({i:s,j:o});this.printLabels({i:s,j:o,values:u,ttItems:a,shared:i,e:h});var g=this.ttCtx.getElTooltip();this.ttCtx.tooltipRect.ttWidth=g.getBoundingClientRect().width,this.ttCtx.tooltipRect.ttHeight=g.getBoundingClientRect().height}},{key:"printLabels",value:function(e){var t,i=this,a=e.i,r=e.j,s=e.values,n=e.ttItems,o=e.shared,l=e.e,c=this.w,h=[],d=function(e){return c.globals.seriesGoals[e]&&c.globals.seriesGoals[e][r]&&Array.isArray(c.globals.seriesGoals[e][r])},u=s.xVal,g=s.zVal,f=s.xAxisTTVal,p="",x=c.globals.colors[a];null!==r&&c.config.plotOptions.bar.distributed&&(x=c.globals.colors[r]);for(var b=function(e,s){var b=i.getFormatters(a);p=i.getSeriesName({fn:b.yLbTitleFormatter,index:a,seriesIndex:a,j:r}),"treemap"===c.config.chart.type&&(p=b.yLbTitleFormatter(String(c.config.series[a].data[r].x),{series:c.globals.series,seriesIndex:a,dataPointIndex:r,w:c}));var v=c.config.tooltip.inverseOrder?s:e;if(c.globals.axisCharts){var m=function(e){var t,i,a,s;return c.globals.isRangeData?b.yLbFormatter(null===(t=c.globals.seriesRangeStart)||void 0===t||null===(i=t[e])||void 0===i?void 0:i[r],{series:c.globals.seriesRangeStart,seriesIndex:e,dataPointIndex:r,w:c})+" - "+b.yLbFormatter(null===(a=c.globals.seriesRangeEnd)||void 0===a||null===(s=a[e])||void 0===s?void 0:s[r],{series:c.globals.seriesRangeEnd,seriesIndex:e,dataPointIndex:r,w:c}):b.yLbFormatter(c.globals.series[e][r],{series:c.globals.series,seriesIndex:e,dataPointIndex:r,w:c})};if(o)b=i.getFormatters(v),p=i.getSeriesName({fn:b.yLbTitleFormatter,index:v,seriesIndex:a,j:r}),x=c.globals.colors[v],t=m(v),d(v)&&(h=c.globals.seriesGoals[v][r].map((function(e){return{attrs:e,val:b.yLbFormatter(e.value,{seriesIndex:v,dataPointIndex:r,w:c})}})));else{var y,w=null==l||null===(y=l.target)||void 0===y?void 0:y.getAttribute("fill");w&&(x=-1!==w.indexOf("url")?document.querySelector(w.substr(4).slice(0,-1)).childNodes[0].getAttribute("stroke"):w),t=m(a),d(a)&&Array.isArray(c.globals.seriesGoals[a][r])&&(h=c.globals.seriesGoals[a][r].map((function(e){return{attrs:e,val:b.yLbFormatter(e.value,{seriesIndex:a,dataPointIndex:r,w:c})}})))}}null===r&&(t=b.yLbFormatter(c.globals.series[a],Rt(Rt({},c),{},{seriesIndex:a,dataPointIndex:a}))),i.DOMHandling({i:a,t:v,j:r,ttItems:n,values:{val:t,goalVals:h,xVal:u,xAxisTTVal:f,zVal:g},seriesName:p,shared:o,pColor:x})},v=0,m=c.globals.series.length-1;v<c.globals.series.length;v++,m--)b(v,m)}},{key:"getFormatters",value:function(e){var t,i=this.w,a=i.globals.yLabelFormatters[e];return void 0!==i.globals.ttVal?Array.isArray(i.globals.ttVal)?(a=i.globals.ttVal[e]&&i.globals.ttVal[e].formatter,t=i.globals.ttVal[e]&&i.globals.ttVal[e].title&&i.globals.ttVal[e].title.formatter):(a=i.globals.ttVal.formatter,"function"==typeof i.globals.ttVal.title.formatter&&(t=i.globals.ttVal.title.formatter)):t=i.config.tooltip.y.title.formatter,"function"!=typeof a&&(a=i.globals.yLabelFormatters[0]?i.globals.yLabelFormatters[0]:function(e){return e}),"function"!=typeof t&&(t=function(e){return e}),{yLbFormatter:a,yLbTitleFormatter:t}}},{key:"getSeriesName",value:function(e){var t=e.fn,i=e.index,a=e.seriesIndex,r=e.j,s=this.w;return t(String(s.globals.seriesNames[i]),{series:s.globals.series,seriesIndex:a,dataPointIndex:r,w:s})}},{key:"DOMHandling",value:function(e){e.i;var t=e.t,i=e.j,a=e.ttItems,r=e.values,s=e.seriesName,n=e.shared,o=e.pColor,l=this.w,c=this.ttCtx,h=r.val,d=r.goalVals,u=r.xVal,g=r.xAxisTTVal,f=r.zVal,p=null;p=a[t].children,l.config.tooltip.fillSeriesColor&&(a[t].style.backgroundColor=o,p[0].style.display="none"),c.showTooltipTitle&&(null===c.tooltipTitle&&(c.tooltipTitle=l.globals.dom.baseEl.querySelector(".apexcharts-tooltip-title")),c.tooltipTitle.innerHTML=u),c.isXAxisTooltipEnabled&&(c.xaxisTooltipText.innerHTML=""!==g?g:u);var x=a[t].querySelector(".apexcharts-tooltip-text-y-label");x&&(x.innerHTML=s||"");var b=a[t].querySelector(".apexcharts-tooltip-text-y-value");b&&(b.innerHTML=void 0!==h?h:""),p[0]&&p[0].classList.contains("apexcharts-tooltip-marker")&&(l.config.tooltip.marker.fillColors&&Array.isArray(l.config.tooltip.marker.fillColors)&&(o=l.config.tooltip.marker.fillColors[t]),p[0].style.backgroundColor=o),l.config.tooltip.marker.show||(p[0].style.display="none");var v=a[t].querySelector(".apexcharts-tooltip-text-goals-label"),m=a[t].querySelector(".apexcharts-tooltip-text-goals-value");if(d.length&&l.globals.seriesGoals[t]){var y=function(){var e="<div >",t="<div>";d.forEach((function(i,a){e+=' <div style="display: flex"><span class="apexcharts-tooltip-marker" style="background-color: '.concat(i.attrs.strokeColor,'; height: 3px; border-radius: 0; top: 5px;"></span> ').concat(i.attrs.name,"</div>"),t+="<div>".concat(i.val,"</div>")})),v.innerHTML=e+"</div>",m.innerHTML=t+"</div>"};n?l.globals.seriesGoals[t][i]&&Array.isArray(l.globals.seriesGoals[t][i])?y():(v.innerHTML="",m.innerHTML=""):y()}else v.innerHTML="",m.innerHTML="";if(null!==f&&(a[t].querySelector(".apexcharts-tooltip-text-z-label").innerHTML=l.config.tooltip.z.title,a[t].querySelector(".apexcharts-tooltip-text-z-value").innerHTML=void 0!==f?f:""),n&&p[0]){if(l.config.tooltip.hideEmptySeries){var w=a[t].querySelector(".apexcharts-tooltip-marker"),k=a[t].querySelector(".apexcharts-tooltip-text");0==parseFloat(h)?(w.style.display="none",k.style.display="none"):(w.style.display="block",k.style.display="block")}null==h||l.globals.ancillaryCollapsedSeriesIndices.indexOf(t)>-1||l.globals.collapsedSeriesIndices.indexOf(t)>-1?p[0].parentNode.style.display="none":p[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 i=t.globals.dom.baseEl.querySelector(".apexcharts-tooltip-series-group");i&&(i.classList.add("apexcharts-active"),i.style.display=t.config.tooltip.items.display)}}},{key:"getValuesToPrint",value:function(e){var t=e.i,i=e.j,a=this.w,r=this.ctx.series.filteredSeriesX(),s="",n="",o=null,l=null,c={series:a.globals.series,seriesIndex:t,dataPointIndex:i,w:a},h=a.globals.ttZFormatter;null===i?l=a.globals.series[t]:a.globals.isXNumeric&&"treemap"!==a.config.chart.type?(s=r[t][i],0===r[t].length&&(s=r[this.tooltipUtil.getFirstActiveXArray(r)][i])):s=void 0!==a.globals.labels[i]?a.globals.labels[i]:"";var d=s;return s=a.globals.isXNumeric&&"datetime"===a.config.xaxis.type?new C(this.ctx).xLabelFormat(a.globals.ttKeyFormatter,d,d,{i:void 0,dateFormatter:new A(this.ctx).formatDate,w:this.w}):a.globals.isBarHorizontal?a.globals.yLabelFormatters[0](d,c):a.globals.xLabelFormatter(d,c),void 0!==a.config.tooltip.x.formatter&&(s=a.globals.ttKeyFormatter(d,c)),a.globals.seriesZ.length>0&&a.globals.seriesZ[t].length>0&&(o=h(a.globals.seriesZ[t][i],a)),n="function"==typeof a.config.xaxis.tooltip.formatter?a.globals.xaxisTooltipFormatter(d,c):s,{val:Array.isArray(l)?l.join(" "):l,xVal:Array.isArray(s)?s.join(" "):s,xAxisTTVal:Array.isArray(n)?n.join(" "):n,zVal:o}}},{key:"handleCustomTooltip",value:function(e){var t=e.i,i=e.j,a=e.y1,r=e.y2,s=e.w,n=this.ttCtx.getElTooltip(),o=s.config.tooltip.custom;Array.isArray(o)&&o[t]&&(o=o[t]),n.innerHTML=o({ctx:this.ctx,series:s.globals.series,seriesIndex:t,dataPointIndex:i,y1:a,y2:r,w:s})}}])&&Ft(t.prototype,i),e}();function Nt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Wt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ttCtx=t,this.ctx=t.ctx,this.w=t.w}var t,i;return t=e,i=[{key:"moveXCrosshairs",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.ttCtx,a=this.w,r=i.getElXCrosshairs(),s=e-i.xcrosshairsWidth/2,n=a.globals.labels.slice().length;if(null!==t&&(s=a.globals.gridWidth/n*t),null===r||a.globals.isBarHorizontal||(r.setAttribute("x",s),r.setAttribute("x1",s),r.setAttribute("x2",s),r.setAttribute("y2",a.globals.gridHeight),r.classList.add("apexcharts-active")),s<0&&(s=0),s>a.globals.gridWidth&&(s=a.globals.gridWidth),i.isXAxisTooltipEnabled){var o=s;"tickWidth"!==a.config.xaxis.crosshairs.width&&"barWidth"!==a.config.xaxis.crosshairs.width||(o=s+i.xcrosshairsWidth/2),this.moveXAxisTooltip(o)}}},{key:"moveYCrosshairs",value:function(e){var t=this.ttCtx;null!==t.ycrosshairs&&g.setAttrs(t.ycrosshairs,{y1:e,y2:e}),null!==t.ycrosshairsHidden&&g.setAttrs(t.ycrosshairsHidden,{y1:e,y2:e})}},{key:"moveXAxisTooltip",value:function(e){var t=this.w,i=this.ttCtx;if(null!==i.xaxisTooltip&&0!==i.xcrosshairsWidth){i.xaxisTooltip.classList.add("apexcharts-active");var a,r=i.xaxisOffY+t.config.xaxis.tooltip.offsetY+t.globals.translateY+1+t.config.xaxis.offsetY;e-=i.xaxisTooltip.getBoundingClientRect().width/2,isNaN(e)||(e+=t.globals.translateX,a=new g(this.ctx).getTextRects(i.xaxisTooltipText.innerHTML),i.xaxisTooltipText.style.minWidth=a.width+"px",i.xaxisTooltip.style.left=e+"px",i.xaxisTooltip.style.top=r+"px")}}},{key:"moveYAxisTooltip",value:function(e){var t=this.w,i=this.ttCtx;null===i.yaxisTTEls&&(i.yaxisTTEls=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));var a=parseInt(i.ycrosshairsHidden.getAttribute("y1"),10),r=t.globals.translateY+a,s=i.yaxisTTEls[e].getBoundingClientRect().height,n=t.globals.translateYAxisX[e]-2;t.config.yaxis[e].opposite&&(n-=26),r-=s/2,-1===t.globals.ignoreYAxisIndexes.indexOf(e)?(i.yaxisTTEls[e].classList.add("apexcharts-active"),i.yaxisTTEls[e].style.top=r+"px",i.yaxisTTEls[e].style.left=n+t.config.yaxis[e].tooltip.offsetX+"px"):i.yaxisTTEls[e].classList.remove("apexcharts-active")}},{key:"moveTooltip",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=this.w,r=this.ttCtx,s=r.getElTooltip(),n=r.tooltipRect,o=null!==i?parseFloat(i):1,l=parseFloat(e)+o+5,c=parseFloat(t)+o/2;if(l>a.globals.gridWidth/2&&(l=l-n.ttWidth-o-10),l>a.globals.gridWidth-n.ttWidth-10&&(l=a.globals.gridWidth-n.ttWidth),l<-20&&(l=-20),a.config.tooltip.followCursor){var h=r.getElGrid().getBoundingClientRect();(l=r.e.clientX-h.left)>a.globals.gridWidth/2&&(l-=r.tooltipRect.ttWidth),(c=r.e.clientY+a.globals.translateY-h.top)>a.globals.gridHeight/2&&(c-=r.tooltipRect.ttHeight)}else a.globals.isBarHorizontal||n.ttHeight/2+c>a.globals.gridHeight&&(c=a.globals.gridHeight-n.ttHeight+a.globals.translateY);isNaN(l)||(l+=a.globals.translateX,s.style.left=l+"px",s.style.top=c+"px")}},{key:"moveMarkers",value:function(e,t){var i=this.w,a=this.ttCtx;if(i.globals.markers.size[e]>0)for(var r=i.globals.dom.baseEl.querySelectorAll(" .apexcharts-series[data\\:realIndex='".concat(e,"'] .apexcharts-marker")),s=0;s<r.length;s++)parseInt(r[s].getAttribute("rel"),10)===t&&(a.marker.resetPointsSize(),a.marker.enlargeCurrentPoint(t,r[s]));else a.marker.resetPointsSize(),this.moveDynamicPointOnHover(t,e)}},{key:"moveDynamicPointOnHover",value:function(e,t){var i,a,r,s,n=this.w,o=this.ttCtx,l=n.globals.pointsArray,c=o.tooltipUtil.getHoverMarkerSize(t),h=n.config.series[t].type;if(!h||"column"!==h&&"candlestick"!==h&&"boxPlot"!==h){r=null===(i=l[t][e])||void 0===i?void 0:i[0],s=(null===(a=l[t][e])||void 0===a?void 0:a[1])||0;var d=n.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(t,"'] .apexcharts-series-markers circle"));d&&s<n.globals.gridHeight&&s>0&&(d.setAttribute("r",c),d.setAttribute("cx",r),d.setAttribute("cy",s)),this.moveXCrosshairs(r),o.fixedTooltip||this.moveTooltip(r,s,c)}}},{key:"moveDynamicPointsOnHover",value:function(e){var t,i=this.ttCtx,a=i.w,r=0,s=0,n=a.globals.pointsArray;t=new ce(this.ctx).getActiveConfigSeriesIndex("asc",["line","area","scatter","bubble"]);var o=i.tooltipUtil.getHoverMarkerSize(t);n[t]&&(r=n[t][e][0],s=n[t][e][1]);var l=i.tooltipUtil.getAllMarkers();if(null!==l)for(var c=0;c<a.globals.series.length;c++){var h=n[c];if(a.globals.comboCharts&&void 0===h&&l.splice(c,0,null),h&&h.length){var d=n[c][e][1],u=void 0;if(l[c].setAttribute("cx",r),"rangeArea"===a.config.chart.type&&!a.globals.comboCharts){var g=e+a.globals.series[c].length;u=n[c][g][1],d-=Math.abs(d-u)/2}null!==d&&!isNaN(d)&&d<a.globals.gridHeight+o&&d+o>0?(l[c]&&l[c].setAttribute("r",o),l[c]&&l[c].setAttribute("cy",d)):l[c]&&l[c].setAttribute("r",0)}}this.moveXCrosshairs(r),i.fixedTooltip||this.moveTooltip(r,s||a.globals.gridHeight,o)}},{key:"moveStickyTooltipOverBars",value:function(e,t){var i=this.w,a=this.ttCtx,r=i.globals.columnSeries?i.globals.columnSeries.length:i.globals.series.length,s=r>=2&&r%2==0?Math.floor(r/2):Math.floor(r/2)+1;i.globals.isBarHorizontal&&(s=new ce(this.ctx).getActiveConfigSeriesIndex("desc")+1);var n=i.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[rel='".concat(s,"'] path[j='").concat(e,"'], .apexcharts-candlestick-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(e,"'], .apexcharts-boxPlot-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(e,"'], .apexcharts-rangebar-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(e,"']"));n||"number"!=typeof t||(n=i.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 o=n?parseFloat(n.getAttribute("cx")):0,l=n?parseFloat(n.getAttribute("cy")):0,c=n?parseFloat(n.getAttribute("barWidth")):0,h=a.getElGrid().getBoundingClientRect(),d=n&&(n.classList.contains("apexcharts-candlestick-area")||n.classList.contains("apexcharts-boxPlot-area"));i.globals.isXNumeric?(n&&!d&&(o-=r%2!=0?c/2:0),n&&d&&i.globals.comboCharts&&(o-=c/2)):i.globals.isBarHorizontal||(o=a.xAxisTicksPositions[e-1]+a.dataPointsDividedWidth/2,isNaN(o)&&(o=a.xAxisTicksPositions[e]-a.dataPointsDividedWidth/2)),i.globals.isBarHorizontal?l-=a.tooltipRect.ttHeight:i.config.tooltip.followCursor?l=a.e.clientY-h.top-a.tooltipRect.ttHeight/2:l+a.tooltipRect.ttHeight+15>i.globals.gridHeight&&(l=i.globals.gridHeight),i.globals.isBarHorizontal||this.moveXCrosshairs(o),a.fixedTooltip||this.moveTooltip(o,l||i.globals.gridHeight)}}],i&&Nt(t.prototype,i),e}();function Bt(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function jt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Gt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ttCtx=t,this.ctx=t.ctx,this.tooltipPosition=new Wt(t)}var t,i;return t=e,i=[{key:"drawDynamicPoints",value:function(){var e,t=this.w,i=new g(this.ctx),a=new ae(this.ctx),r=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series");r=function(e){if(Array.isArray(e))return Bt(e)}(e=r)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Bt(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Bt(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),t.config.chart.stacked&&r.sort((function(e,t){return parseFloat(e.getAttribute("data:realIndex"))-parseFloat(t.getAttribute("data:realIndex"))}));for(var s=0;s<r.length;s++){var n=r[s].querySelector(".apexcharts-series-markers-wrap");if(null!==n){var o=void 0,l="apexcharts-marker w".concat((Math.random()+1).toString(36).substring(4));"line"!==t.config.chart.type&&"area"!==t.config.chart.type||t.globals.comboCharts||t.config.tooltip.intersect||(l+=" no-pointer-events");var c=a.getMarkerConfig({cssClass:l,seriesIndex:Number(n.getAttribute("data:realIndex"))});(o=i.drawMarker(0,0,c)).node.setAttribute("default-marker-size",0);var h=document.createElementNS(t.globals.SVGNS,"g");h.classList.add("apexcharts-series-markers"),h.appendChild(o.node),n.appendChild(h)}}}},{key:"enlargeCurrentPoint",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=this.w;"bubble"!==r.config.chart.type&&this.newPointSize(e,t);var s=t.getAttribute("cx"),n=t.getAttribute("cy");if(null!==i&&null!==a&&(s=i,n=a),this.tooltipPosition.moveXCrosshairs(s),!this.fixedTooltip){if("radar"===r.config.chart.type){var o=this.ttCtx.getElGrid().getBoundingClientRect();s=this.ttCtx.e.clientX-o.left}this.tooltipPosition.moveTooltip(s,n,r.config.markers.hover.size)}}},{key:"enlargePoints",value:function(e){for(var t=this.w,i=this,a=this.ttCtx,r=e,s=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),n=t.config.markers.hover.size,o=0;o<s.length;o++){var l=s[o].getAttribute("rel"),c=s[o].getAttribute("index");if(void 0===n&&(n=t.globals.markers.size[c]+t.config.markers.hover.sizeOffset),r===parseInt(l,10)){i.newPointSize(r,s[o]);var h=s[o].getAttribute("cx"),d=s[o].getAttribute("cy");i.tooltipPosition.moveXCrosshairs(h),a.fixedTooltip||i.tooltipPosition.moveTooltip(h,d,n)}else i.oldPointSize(s[o])}}},{key:"newPointSize",value:function(e,t){var i=this.w,a=i.config.markers.hover.size,r=0===e?t.parentNode.firstChild:t.parentNode.lastChild;if("0"!==r.getAttribute("default-marker-size")){var s=parseInt(r.getAttribute("index"),10);void 0===a&&(a=i.globals.markers.size[s]+i.config.markers.hover.sizeOffset),a<0&&(a=0),r.setAttribute("r",a)}}},{key:"oldPointSize",value:function(e){var t=parseFloat(e.getAttribute("default-marker-size"));e.setAttribute("r",t)}},{key:"resetPointsSize",value:function(){for(var e=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),t=0;t<e.length;t++){var i=parseFloat(e[t].getAttribute("default-marker-size"));r.isNumber(i)&&i>=0?e[t].setAttribute("r",i):e[t].setAttribute("r",0)}}}],i&&jt(t.prototype,i),e}();function Vt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const _t=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w;var i=this.w;this.ttCtx=t,this.isVerticalGroupedRangeBar=!i.globals.isBarHorizontal&&"rangeBar"===i.config.chart.type&&i.config.plotOptions.bar.rangeBarGroupRows}var t,i;return t=e,(i=[{key:"getAttr",value:function(e,t){return parseFloat(e.target.getAttribute(t))}},{key:"handleHeatTreeTooltip",value:function(e){var t=e.e,i=e.opt,a=e.x,r=e.y,s=e.type,n=this.ttCtx,o=this.w;if(t.target.classList.contains("apexcharts-".concat(s,"-rect"))){var l=this.getAttr(t,"i"),c=this.getAttr(t,"j"),h=this.getAttr(t,"cx"),d=this.getAttr(t,"cy"),u=this.getAttr(t,"width"),g=this.getAttr(t,"height");if(n.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:l,j:c,shared:!1,e:t}),o.globals.capturedSeriesIndex=l,o.globals.capturedDataPointIndex=c,a=h+n.tooltipRect.ttWidth/2+u,r=d+n.tooltipRect.ttHeight/2-g/2,n.tooltipPosition.moveXCrosshairs(h+u/2),a>o.globals.gridWidth/2&&(a=h-n.tooltipRect.ttWidth/2+u),n.w.config.tooltip.followCursor){var f=o.globals.dom.elWrap.getBoundingClientRect();a=o.globals.clientX-f.left-(a>o.globals.gridWidth/2?n.tooltipRect.ttWidth:0),r=o.globals.clientY-f.top-(r>o.globals.gridHeight/2?n.tooltipRect.ttHeight:0)}}return{x:a,y:r}}},{key:"handleMarkerTooltip",value:function(e){var t,i,a=e.e,s=e.opt,n=e.x,o=e.y,l=this.w,c=this.ttCtx;if(a.target.classList.contains("apexcharts-marker")){var h=parseInt(s.paths.getAttribute("cx"),10),d=parseInt(s.paths.getAttribute("cy"),10),u=parseFloat(s.paths.getAttribute("val"));if(i=parseInt(s.paths.getAttribute("rel"),10),t=parseInt(s.paths.parentNode.parentNode.parentNode.getAttribute("rel"),10)-1,c.intersect){var g=r.findAncestor(s.paths,"apexcharts-series");g&&(t=parseInt(g.getAttribute("data:realIndex"),10))}if(c.tooltipLabels.drawSeriesTexts({ttItems:s.ttItems,i:t,j:i,shared:!c.showOnIntersect&&l.config.tooltip.shared,e:a}),"mouseup"===a.type&&c.markerClick(a,t,i),l.globals.capturedSeriesIndex=t,l.globals.capturedDataPointIndex=i,n=h,o=d+l.globals.translateY-1.4*c.tooltipRect.ttHeight,c.w.config.tooltip.followCursor){var f=c.getElGrid().getBoundingClientRect();o=c.e.clientY+l.globals.translateY-f.top}u<0&&(o=d),c.marker.enlargeCurrentPoint(i,s.paths,n,o)}return{x:n,y:o}}},{key:"handleBarTooltip",value:function(e){var t,i,a=e.e,r=e.opt,s=this.w,n=this.ttCtx,o=n.getElTooltip(),l=0,c=0,h=0,d=this.getBarTooltipXY({e:a,opt:r});t=d.i;var u=d.barHeight,g=d.j;s.globals.capturedSeriesIndex=t,s.globals.capturedDataPointIndex=g,s.globals.isBarHorizontal&&n.tooltipUtil.hasBars()||!s.config.tooltip.shared?(c=d.x,h=d.y,i=Array.isArray(s.config.stroke.width)?s.config.stroke.width[t]:s.config.stroke.width,l=c):s.globals.comboCharts||s.config.tooltip.shared||(l/=2),isNaN(h)&&(h=s.globals.svgHeight-n.tooltipRect.ttHeight);var f=parseInt(r.paths.parentNode.getAttribute("data:realIndex"),10),p=s.globals.isMultipleYAxis?s.config.yaxis[f]&&s.config.yaxis[f].reversed:s.config.yaxis[0].reversed;if(c+n.tooltipRect.ttWidth>s.globals.gridWidth&&!p?c-=n.tooltipRect.ttWidth:c<0&&(c=0),n.w.config.tooltip.followCursor){var x=n.getElGrid().getBoundingClientRect();h=n.e.clientY-x.top}null===n.tooltip&&(n.tooltip=s.globals.dom.baseEl.querySelector(".apexcharts-tooltip")),s.config.tooltip.shared||(s.globals.comboBarCount>0?n.tooltipPosition.moveXCrosshairs(l+i/2):n.tooltipPosition.moveXCrosshairs(l)),!n.fixedTooltip&&(!s.config.tooltip.shared||s.globals.isBarHorizontal&&n.tooltipUtil.hasBars())&&(p&&(c-=n.tooltipRect.ttWidth)<0&&(c=0),!p||s.globals.isBarHorizontal&&n.tooltipUtil.hasBars()||(h=h+u-2*(s.globals.series[t][g]<0?u:0)),h=h+s.globals.translateY-n.tooltipRect.ttHeight/2,o.style.left=c+s.globals.translateX+"px",o.style.top=h+"px")}},{key:"getBarTooltipXY",value:function(e){var t=this,i=e.e,a=e.opt,r=this.w,s=null,n=this.ttCtx,o=0,l=0,c=0,h=0,d=0,u=i.target.classList;if(u.contains("apexcharts-bar-area")||u.contains("apexcharts-candlestick-area")||u.contains("apexcharts-boxPlot-area")||u.contains("apexcharts-rangebar-area")){var g=i.target,f=g.getBoundingClientRect(),p=a.elGrid.getBoundingClientRect(),x=f.height;d=f.height;var b=f.width,v=parseInt(g.getAttribute("cx"),10),m=parseInt(g.getAttribute("cy"),10);h=parseFloat(g.getAttribute("barWidth"));var y="touchmove"===i.type?i.touches[0].clientX:i.clientX;s=parseInt(g.getAttribute("j"),10),o=parseInt(g.parentNode.getAttribute("rel"),10)-1;var w=g.getAttribute("data-range-y1"),k=g.getAttribute("data-range-y2");r.globals.comboCharts&&(o=parseInt(g.parentNode.getAttribute("data:realIndex"),10));var A=function(e){return r.globals.isXNumeric?v-b/2:t.isVerticalGroupedRangeBar?v+b/2:v-n.dataPointsDividedWidth+b/2},S=function(){return m-n.dataPointsDividedHeight+x/2-n.tooltipRect.ttHeight/2};n.tooltipLabels.drawSeriesTexts({ttItems:a.ttItems,i:o,j:s,y1:w?parseInt(w,10):null,y2:k?parseInt(k,10):null,shared:!n.showOnIntersect&&r.config.tooltip.shared,e:i}),r.config.tooltip.followCursor?r.globals.isBarHorizontal?(l=y-p.left+15,c=S()):(l=A(),c=i.clientY-p.top-n.tooltipRect.ttHeight/2-15):r.globals.isBarHorizontal?((l=v)<n.xyRatios.baseLineInvertedY&&(l=v-n.tooltipRect.ttWidth),c=S()):(l=A(),c=m)}return{x:l,y:c,barHeight:d,barWidth:h,i:o,j:s}}}])&&Vt(t.prototype,i),e}();function Ut(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const qt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ttCtx=t}var t,i;return t=e,(i=[{key:"drawXaxisTooltip",value:function(){var e=this.w,t=this.ttCtx,i="bottom"===e.config.xaxis.position;t.xaxisOffY=i?e.globals.gridHeight+1:-e.globals.xAxisHeight-e.config.xaxis.axisTicks.height+3;var a=i?"apexcharts-xaxistooltip apexcharts-xaxistooltip-bottom":"apexcharts-xaxistooltip apexcharts-xaxistooltip-top",r=e.globals.dom.elWrap;t.isXAxisTooltipEnabled&&null===e.globals.dom.baseEl.querySelector(".apexcharts-xaxistooltip")&&(t.xaxisTooltip=document.createElement("div"),t.xaxisTooltip.setAttribute("class",a+" apexcharts-theme-"+e.config.tooltip.theme),r.appendChild(t.xaxisTooltip),t.xaxisTooltipText=document.createElement("div"),t.xaxisTooltipText.classList.add("apexcharts-xaxistooltip-text"),t.xaxisTooltipText.style.fontFamily=e.config.xaxis.tooltip.style.fontFamily||e.config.chart.fontFamily,t.xaxisTooltipText.style.fontSize=e.config.xaxis.tooltip.style.fontSize,t.xaxisTooltip.appendChild(t.xaxisTooltipText))}},{key:"drawYaxisTooltip",value:function(){for(var e=this.w,t=this.ttCtx,i=0;i<e.config.yaxis.length;i++){var a=e.config.yaxis[i].opposite||e.config.yaxis[i].crosshairs.opposite;t.yaxisOffX=a?e.globals.gridWidth+1:1;var r="apexcharts-yaxistooltip apexcharts-yaxistooltip-".concat(i,a?" apexcharts-yaxistooltip-right":" apexcharts-yaxistooltip-left"),s=e.globals.dom.elWrap;null===e.globals.dom.baseEl.querySelector(".apexcharts-yaxistooltip apexcharts-yaxistooltip-".concat(i))&&(t.yaxisTooltip=document.createElement("div"),t.yaxisTooltip.setAttribute("class",r+" apexcharts-theme-"+e.config.tooltip.theme),s.appendChild(t.yaxisTooltip),0===i&&(t.yaxisTooltipText=[]),t.yaxisTooltipText[i]=document.createElement("div"),t.yaxisTooltipText[i].classList.add("apexcharts-yaxistooltip-text"),t.yaxisTooltip.appendChild(t.yaxisTooltipText[i]))}}},{key:"setXCrosshairWidth",value:function(){var e=this.w,t=this.ttCtx,i=t.getElXCrosshairs();if(t.xcrosshairsWidth=parseInt(e.config.xaxis.crosshairs.width,10),e.globals.comboCharts){var a=e.globals.dom.baseEl.querySelector(".apexcharts-bar-area");if(null!==a&&"barWidth"===e.config.xaxis.crosshairs.width){var r=parseFloat(a.getAttribute("barWidth"));t.xcrosshairsWidth=r}else if("tickWidth"===e.config.xaxis.crosshairs.width){var s=e.globals.labels.length;t.xcrosshairsWidth=e.globals.gridWidth/s}}else if("tickWidth"===e.config.xaxis.crosshairs.width){var n=e.globals.labels.length;t.xcrosshairsWidth=e.globals.gridWidth/n}else if("barWidth"===e.config.xaxis.crosshairs.width){var o=e.globals.dom.baseEl.querySelector(".apexcharts-bar-area");if(null!==o){var l=parseFloat(o.getAttribute("barWidth"));t.xcrosshairsWidth=l}else t.xcrosshairsWidth=1}e.globals.isBarHorizontal&&(t.xcrosshairsWidth=0),null!==i&&t.xcrosshairsWidth>0&&i.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,i){var a=this.ttCtx,r=this.w,s=r.globals,n=s.seriesYAxisMap[e];if(a.yaxisTooltips[e]&&n.length>0){var o=s.yLabelFormatters[e],l=a.getElGrid().getBoundingClientRect(),c=n[0],h=0;i.yRatio.length>1&&(h=c);var d=(t-l.top)*i.yRatio[h],u=s.maxYArr[c]-s.minYArr[c],g=s.minYArr[c]+(u-d);r.config.yaxis[e].reversed&&(g=s.maxYArr[c]-(u-d)),a.tooltipPosition.moveYCrosshairs(t-l.top),a.yaxisTooltipText[e].innerHTML=o(g),a.tooltipPosition.moveYAxisTooltip(e)}}}])&&Ut(t.prototype,i),e}();function Zt(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function $t(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Zt(Object(i),!0).forEach((function(t){Jt(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Zt(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Jt(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Qt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Kt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.w;this.tConfig=i.config.tooltip,this.tooltipUtil=new Xt(this),this.tooltipLabels=new Ht(this),this.tooltipPosition=new Wt(this),this.marker=new Gt(this),this.intersect=new _t(this),this.axesTooltip=new qt(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=!i.globals.isBarHorizontal&&this.tConfig.shared,this.lastHoverTime=Date.now()}var t,i;return t=e,i=[{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,i){return!!(e.show&&e.tooltip.enabled&&t.globals.axisCharts)})),this.allTooltipSeriesGroups=[],t.globals.axisCharts||(this.showTooltipTitle=!1);var i=document.createElement("div");if(i.classList.add("apexcharts-tooltip"),t.config.tooltip.cssClass&&i.classList.add(t.config.tooltip.cssClass),i.classList.add("apexcharts-theme-".concat(this.tConfig.theme)),t.globals.dom.elWrap.appendChild(i),t.globals.axisCharts){this.axesTooltip.drawXaxisTooltip(),this.axesTooltip.drawYaxisTooltip(),this.axesTooltip.setXCrosshairWidth(),this.axesTooltip.handleYCrosshair();var a=new ve(this.ctx);this.xAxisTicksPositions=a.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,i.appendChild(this.tooltipTitle));var r=t.globals.series.length;(t.globals.xyCharts||t.globals.comboCharts)&&this.tConfig.shared&&(r=this.showOnIntersect?1:t.globals.series.length),this.legendLabels=t.globals.dom.baseEl.querySelectorAll(".apexcharts-legend-text"),this.ttItems=this.createTTElements(r),this.addSVGEvents()}}},{key:"createTTElements",value:function(e){for(var t=this,i=this.w,a=[],r=this.getElTooltip(),s=function(s){var n=document.createElement("div");n.classList.add("apexcharts-tooltip-series-group"),n.style.order=i.config.tooltip.inverseOrder?e-s:s+1,t.tConfig.shared&&t.tConfig.enabledOnSeries&&Array.isArray(t.tConfig.enabledOnSeries)&&t.tConfig.enabledOnSeries.indexOf(s)<0&&n.classList.add("apexcharts-tooltip-series-group-hidden");var o=document.createElement("span");o.classList.add("apexcharts-tooltip-marker"),o.style.backgroundColor=i.globals.colors[s],n.appendChild(o);var l=document.createElement("div");l.classList.add("apexcharts-tooltip-text"),l.style.fontFamily=t.tConfig.style.fontFamily||i.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 i=document.createElement("span");i.classList.add("apexcharts-tooltip-text-".concat(e,"-label")),t.appendChild(i);var a=document.createElement("span");a.classList.add("apexcharts-tooltip-text-".concat(e,"-value")),t.appendChild(a),l.appendChild(t)})),n.appendChild(l),r.appendChild(n),a.push(n)},n=0;n<e;n++)s(n);return a}},{key:"addSVGEvents",value:function(){var e=this.w,t=e.config.chart.type,i=this.getElTooltip(),a=!("bar"!==t&&"candlestick"!==t&&"boxPlot"!==t&&"rangeBar"!==t),r="area"===t||"line"===t||"scatter"===t||"bubble"===t||"radar"===t,s=e.globals.dom.Paper.node,n=this.getElGrid();n&&(this.seriesBound=n.getBoundingClientRect());var o,l=[],c=[],h={hoverArea:s,elGrid:n,tooltipEl:i,tooltipY:l,tooltipX:c,ttItems:this.ttItems};if(e.globals.axisCharts&&(r?o=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series[data\\:longestSeries='true'] .apexcharts-marker"):a?o=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-bar-area, .apexcharts-series .apexcharts-candlestick-area, .apexcharts-series .apexcharts-boxPlot-area, .apexcharts-series .apexcharts-rangebar-area"):"heatmap"!==t&&"treemap"!==t||(o=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-heatmap, .apexcharts-series .apexcharts-treemap")),o&&o.length))for(var d=0;d<o.length;d++)l.push(o[d].getAttribute("cy")),c.push(o[d].getAttribute("cx"));if(e.globals.xyCharts&&!this.showOnIntersect||e.globals.comboCharts&&!this.showOnIntersect||a&&this.tooltipUtil.hasBars()&&this.tConfig.shared)this.addPathsEventListeners([s],h);else if(a&&!e.globals.comboCharts||r&&this.showOnIntersect)this.addDatapointEventsListeners(h);else if(!e.globals.axisCharts||"heatmap"===t||"treemap"===t){var u=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series");this.addPathsEventListeners(u,h)}if(this.showOnIntersect){var g=e.globals.dom.baseEl.querySelectorAll(".apexcharts-line-series .apexcharts-marker, .apexcharts-area-series .apexcharts-marker");g.length>0&&this.addPathsEventListeners(g,h),this.tooltipUtil.hasBars()&&!this.tConfig.shared&&this.addDatapointEventsListeners(h)}}},{key:"drawFixedTooltipRect",value:function(){var e=this.w,t=this.getElTooltip(),i=t.getBoundingClientRect(),a=i.width+10,r=i.height+10,s=this.tConfig.fixed.offsetX,n=this.tConfig.fixed.offsetY,o=this.tConfig.fixed.position.toLowerCase();return o.indexOf("right")>-1&&(s=s+e.globals.svgWidth-a+10),o.indexOf("bottom")>-1&&(n=n+e.globals.svgHeight-r-10),t.style.left=s+"px",t.style.top=n+"px",{x:s,y:n,ttWidth:a,ttHeight:r}}},{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 i=this,a=function(a){var r={paths:e[a],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[a].addEventListener(t,i.onSeriesHover.bind(i,r),{capture:!1,passive:!0})}))},r=0;r<e.length;r++)a(r)}},{key:"onSeriesHover",value:function(e,t){var i=this,a=Date.now()-this.lastHoverTime;a>=100?this.seriesHover(e,t):(clearTimeout(this.seriesHoverTimeout),this.seriesHoverTimeout=setTimeout((function(){i.seriesHover(e,t)}),100-a))}},{key:"seriesHover",value:function(e,t){var i=this;this.lastHoverTime=Date.now();var a=[],r=this.w;r.config.chart.group&&(a=this.ctx.getGroupedCharts()),r.globals.axisCharts&&(r.globals.minX===-1/0&&r.globals.maxX===1/0||0===r.globals.dataPoints)||(a.length?a.forEach((function(a){var r=i.getElTooltip(a),s={paths:e.paths,tooltipEl:r,tooltipY:e.tooltipY,tooltipX:e.tooltipX,elGrid:e.elGrid,hoverArea:e.hoverArea,ttItems:a.w.globals.tooltip.ttItems};a.w.globals.minX===i.w.globals.minX&&a.w.globals.maxX===i.w.globals.maxX&&a.w.globals.tooltip.seriesHoverByContext({chartCtx:a,ttCtx:a.w.globals.tooltip,opt:s,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,i=e.ttCtx,a=e.opt,r=e.e,s=t.w,n=this.getElTooltip();n&&(i.tooltipRect={x:0,y:0,ttWidth:n.getBoundingClientRect().width,ttHeight:n.getBoundingClientRect().height},i.e=r,!i.tooltipUtil.hasBars()||s.globals.comboCharts||i.isBarShared||this.tConfig.onDatasetHover.highlightDataSeries&&new ce(t).toggleSeriesOnHover(r,r.target.parentNode),i.fixedTooltip&&i.drawFixedTooltipRect(),s.globals.axisCharts?i.axisChartsTooltips({e:r,opt:a,tooltipRect:i.tooltipRect}):i.nonAxisChartsTooltips({e:r,opt:a,tooltipRect:i.tooltipRect}))}},{key:"axisChartsTooltips",value:function(e){var t,i,a=e.e,r=e.opt,s=this.w,n=r.elGrid.getBoundingClientRect(),o="touchmove"===a.type?a.touches[0].clientX:a.clientX,l="touchmove"===a.type?a.touches[0].clientY:a.clientY;if(this.clientY=l,this.clientX=o,s.globals.capturedSeriesIndex=-1,s.globals.capturedDataPointIndex=-1,l<n.top||l>n.top+n.height)this.handleMouseOut(r);else{if(Array.isArray(this.tConfig.enabledOnSeries)&&!s.config.tooltip.shared){var c=parseInt(r.paths.getAttribute("index"),10);if(this.tConfig.enabledOnSeries.indexOf(c)<0)return void this.handleMouseOut(r)}var h=this.getElTooltip(),d=this.getElXCrosshairs(),u=s.globals.xyCharts||"bar"===s.config.chart.type&&!s.globals.isBarHorizontal&&this.tooltipUtil.hasBars()&&this.tConfig.shared||s.globals.comboCharts&&this.tooltipUtil.hasBars();if("mousemove"===a.type||"touchmove"===a.type||"mouseup"===a.type){if(s.globals.collapsedSeries.length+s.globals.ancillaryCollapsedSeries.length===s.globals.series.length)return;null!==d&&d.classList.add("apexcharts-active");var g=this.yaxisTooltips.filter((function(e){return!0===e}));if(null!==this.ycrosshairs&&g.length&&this.ycrosshairs.classList.add("apexcharts-active"),u&&!this.showOnIntersect)this.handleStickyTooltip(a,o,l,r);else if("heatmap"===s.config.chart.type||"treemap"===s.config.chart.type){var f=this.intersect.handleHeatTreeTooltip({e:a,opt:r,x:t,y:i,type:s.config.chart.type});t=f.x,i=f.y,h.style.left=t+"px",h.style.top=i+"px"}else this.tooltipUtil.hasBars()&&this.intersect.handleBarTooltip({e:a,opt:r}),this.tooltipUtil.hasMarkers()&&this.intersect.handleMarkerTooltip({e:a,opt:r,x:t,y:i});if(this.yaxisTooltips.length)for(var p=0;p<s.config.yaxis.length;p++)this.axesTooltip.drawYaxisTooltipText(p,l,this.xyRatios);r.tooltipEl.classList.add("apexcharts-active")}else"mouseout"!==a.type&&"touchend"!==a.type||this.handleMouseOut(r)}}},{key:"nonAxisChartsTooltips",value:function(e){var t=e.e,i=e.opt,a=e.tooltipRect,r=this.w,s=i.paths.getAttribute("rel"),n=this.getElTooltip(),o=r.globals.dom.elWrap.getBoundingClientRect();if("mousemove"===t.type||"touchmove"===t.type){n.classList.add("apexcharts-active"),this.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:parseInt(s,10)-1,shared:!1});var l=r.globals.clientX-o.left-a.ttWidth/2,c=r.globals.clientY-o.top-a.ttHeight-10;if(n.style.left=l+"px",n.style.top=c+"px",r.config.legend.tooltipHoverFormatter){var h=s-1,d=(0,r.config.legend.tooltipHoverFormatter)(this.legendLabels[h].getAttribute("data:default-text"),{seriesIndex:h,dataPointIndex:h,w:r});this.legendLabels[h].innerHTML=d}}else"mouseout"!==t.type&&"touchend"!==t.type||(n.classList.remove("apexcharts-active"),r.config.legend.tooltipHoverFormatter&&this.legendLabels.forEach((function(e){var t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(t)})))}},{key:"handleStickyTooltip",value:function(e,t,i,a){var r=this.w,s=this.tooltipUtil.getNearestValues({context:this,hoverArea:a.hoverArea,elGrid:a.elGrid,clientX:t,clientY:i}),n=s.j,o=s.capturedSeries;r.globals.collapsedSeriesIndices.includes(o)&&(o=null);var l=a.elGrid.getBoundingClientRect();if(s.hoverX<0||s.hoverX>l.width)this.handleMouseOut(a);else if(null!==o)this.handleStickyCapturedSeries(e,o,a,n);else if(this.tooltipUtil.isXoverlap(n)||r.globals.isBarHorizontal){var c=r.globals.series.findIndex((function(e,t){return!r.globals.collapsedSeriesIndices.includes(t)}));this.create(e,this,c,n,a.ttItems)}}},{key:"handleStickyCapturedSeries",value:function(e,t,i,a){var r=this.w;if(this.tConfig.shared||null!==r.globals.series[t][a]){if(void 0!==r.globals.series[t][a])this.tConfig.shared&&this.tooltipUtil.isXoverlap(a)&&this.tooltipUtil.isInitialSeriesSameLen()?this.create(e,this,t,a,i.ttItems):this.create(e,this,t,a,i.ttItems,!1);else if(this.tooltipUtil.isXoverlap(a)){var s=r.globals.series.findIndex((function(e,t){return!r.globals.collapsedSeriesIndices.includes(t)}));this.create(e,this,s,a,i.ttItems)}}else this.handleMouseOut(i)}},{key:"deactivateHoverFilter",value:function(){for(var e=this.w,t=new g(this.ctx),i=e.globals.dom.Paper.select(".apexcharts-bar-area"),a=0;a<i.length;a++)t.pathMouseLeave(i[a])}},{key:"handleMouseOut",value:function(e){var t=this.w,i=this.getElXCrosshairs();if(e.tooltipEl.classList.remove("apexcharts-active"),this.deactivateHoverFilter(),"bubble"!==t.config.chart.type&&this.marker.resetPointsSize(),null!==i&&i.classList.remove("apexcharts-active"),null!==this.ycrosshairs&&this.ycrosshairs.classList.remove("apexcharts-active"),this.isXAxisTooltipEnabled&&this.xaxisTooltip.classList.remove("apexcharts-active"),this.yaxisTooltips.length){null===this.yaxisTTEls&&(this.yaxisTTEls=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));for(var a=0;a<this.yaxisTTEls.length;a++)this.yaxisTTEls[a].classList.remove("apexcharts-active")}t.config.legend.tooltipHoverFormatter&&this.legendLabels.forEach((function(e){var t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(t)}))}},{key:"markerClick",value:function(e,t,i){var a=this.w;"function"==typeof a.config.chart.events.markerClick&&a.config.chart.events.markerClick(e,this.ctx,{seriesIndex:t,dataPointIndex:i,w:a}),this.ctx.events.fireEvent("markerClick",[e,this.ctx,{seriesIndex:t,dataPointIndex:i,w:a}])}},{key:"create",value:function(e,t,i,a,r){var s,n,o,l,c,h,d,u,f,p,x,b,v,m,y,w,k=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,A=this.w,S=t;"mouseup"===e.type&&this.markerClick(e,i,a),null===k&&(k=this.tConfig.shared);var C=this.tooltipUtil.hasMarkers(i),P=this.tooltipUtil.getElBars();if(A.config.legend.tooltipHoverFormatter){var L=A.config.legend.tooltipHoverFormatter,O=Array.from(this.legendLabels);O.forEach((function(e){var t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(t)}));for(var M=0;M<O.length;M++){var T=O[M],I=parseInt(T.getAttribute("i"),10),E=decodeURIComponent(T.getAttribute("data:default-text")),z=L(E,{seriesIndex:k?I:i,dataPointIndex:a,w:A});if(k)T.innerHTML=A.globals.collapsedSeriesIndices.indexOf(I)<0?z:E;else if(T.innerHTML=I===i?z:E,i===I)break}}var X=$t($t({ttItems:r,i,j:a},void 0!==(null===(s=A.globals.seriesRange)||void 0===s||null===(n=s[i])||void 0===n||null===(o=n[a])||void 0===o||null===(l=o.y[0])||void 0===l?void 0:l.y1)&&{y1:null===(c=A.globals.seriesRange)||void 0===c||null===(h=c[i])||void 0===h||null===(d=h[a])||void 0===d||null===(u=d.y[0])||void 0===u?void 0:u.y1}),void 0!==(null===(f=A.globals.seriesRange)||void 0===f||null===(p=f[i])||void 0===p||null===(x=p[a])||void 0===x||null===(b=x.y[0])||void 0===b?void 0:b.y2)&&{y2:null===(v=A.globals.seriesRange)||void 0===v||null===(m=v[i])||void 0===m||null===(y=m[a])||void 0===y||null===(w=y.y[0])||void 0===w?void 0:w.y2});if(k){if(S.tooltipLabels.drawSeriesTexts($t($t({},X),{},{shared:!this.showOnIntersect&&this.tConfig.shared})),C)A.globals.markers.largestSize>0?S.marker.enlargePoints(a):S.tooltipPosition.moveDynamicPointsOnHover(a);else if(this.tooltipUtil.hasBars()&&(this.barSeriesHeight=this.tooltipUtil.getBarsHeight(P),this.barSeriesHeight>0)){var Y=new g(this.ctx),R=A.globals.dom.Paper.select(".apexcharts-bar-area[j='".concat(a,"']"));this.deactivateHoverFilter(),this.tooltipPosition.moveStickyTooltipOverBars(a,i);for(var D=0;D<R.length;D++)Y.pathMouseEnter(R[D])}}else S.tooltipLabels.drawSeriesTexts($t({shared:!1},X)),this.tooltipUtil.hasBars()&&S.tooltipPosition.moveStickyTooltipOverBars(a,i),C&&S.tooltipPosition.moveMarkers(i,a)}}],i&&Qt(t.prototype,i),e}();function ei(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ti(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ei(Object(i),!0).forEach((function(t){ii(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ei(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ii(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ai(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ri=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.barCtx=t,this.totalFormatter=this.w.config.plotOptions.bar.dataLabels.total.formatter,this.totalFormatter||(this.totalFormatter=this.w.config.dataLabels.formatter)}var t,i;return t=e,(i=[{key:"handleBarDataLabels",value:function(e){var t,i,a=e.x,r=e.y,s=e.y1,n=e.y2,o=e.i,l=e.j,c=e.realIndex,h=e.columnGroupIndex,d=e.series,u=e.barHeight,f=e.barWidth,p=e.barXPosition,x=e.barYPosition,b=e.visibleSeries,v=e.renderedPath,m=this.w,y=new g(this.barCtx.ctx),w=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[c]:this.barCtx.strokeWidth;m.globals.isXNumeric&&!m.globals.isBarHorizontal?(t=a+parseFloat(f*(b+1)),i=r+parseFloat(u*(b+1))-w):(t=a+parseFloat(f*b),i=r+parseFloat(u*b));var k,A,S=null,C=a,P=r,L=m.config.dataLabels,O=this.barCtx.barOptions.dataLabels,M=this.barCtx.barOptions.dataLabels.total;void 0!==x&&this.barCtx.isRangeBar&&(i=x,P=x),void 0!==p&&this.barCtx.isVerticalGroupedRangeBar&&(t=p,C=p);var T=L.offsetX,I=L.offsetY,E={width:0,height:0};if(m.config.dataLabels.enabled){var z=this.barCtx.series[o][l];E=y.getTextRects(m.globals.yLabelFormatters[0](z),parseFloat(L.style.fontSize))}var X={x:a,y:r,i:o,j:l,realIndex:c,columnGroupIndex:h,renderedPath:v,bcx:t,bcy:i,barHeight:u,barWidth:f,textRects:E,strokeWidth:w,dataLabelsX:C,dataLabelsY:P,dataLabelsConfig:L,barDataLabelsConfig:O,barTotalDataLabelsConfig:M,offX:T,offY:I};return A=this.barCtx.isHorizontal?this.calculateBarsDataLabelsPosition(X):this.calculateColumnsDataLabelsPosition(X),v.attr({cy:A.bcy,cx:A.bcx,j:l,val:d[o][l],barHeight:u,barWidth:f}),k=this.drawCalculatedDataLabels({x:A.dataLabelsX,y:A.dataLabelsY,val:this.barCtx.isRangeBar?[s,n]:d[o][l],i:c,j:l,barWidth:f,barHeight:u,textRects:E,dataLabelsConfig:L}),m.config.chart.stacked&&M.enabled&&(S=this.drawTotalDataLabels({x:A.totalDataLabelsX,y:A.totalDataLabelsY,barWidth:f,barHeight:u,realIndex:c,textAnchor:A.totalDataLabelsAnchor,val:this.getStackedTotalDataLabel({realIndex:c,j:l}),dataLabelsConfig:L,barTotalDataLabelsConfig:M})),{dataLabels:k,totalDataLabels:S}}},{key:"getStackedTotalDataLabel",value:function(e){var t=e.realIndex,i=e.j,a=this.w,r=this.barCtx.stackedSeriesTotals[i];return this.totalFormatter&&(r=this.totalFormatter(r,ti(ti({},a),{},{seriesIndex:t,dataPointIndex:i,w:a}))),r}},{key:"calculateColumnsDataLabelsPosition",value:function(e){var t,i,a=this.w,r=e.i,s=e.j,n=e.realIndex,o=e.columnGroupIndex,l=e.y,c=e.bcx,h=e.barWidth,d=e.barHeight,u=e.textRects,f=e.dataLabelsX,p=e.dataLabelsY,x=e.dataLabelsConfig,b=e.barDataLabelsConfig,v=e.barTotalDataLabelsConfig,m=e.strokeWidth,y=e.offX,w=e.offY,k=c;d=Math.abs(d);var A="vertical"===a.config.plotOptions.bar.dataLabels.orientation,S=this.barCtx.barHelpers.getZeroValueEncounters({i:r,j:s}).zeroEncounters;c=c-m/2+o*h;var C=a.globals.gridWidth/a.globals.dataPoints;this.barCtx.isVerticalGroupedRangeBar?f+=h/2:(f=a.globals.isXNumeric?c-h/2+y:c-C+h/2+y,S>0&&a.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(f-=h*S)),A&&(f=f+u.height/2-m/2-2);var P=this.barCtx.series[r][s]<0,L=l;switch(this.barCtx.isReversed&&(L=l+(P?d:-d),l-=d),b.position){case"center":p=A?P?L-d/2+w:L+d/2-w:P?L-d/2+u.height/2+w:L+d/2+u.height/2-w;break;case"bottom":p=A?P?L-d+w:L+d-w:P?L-d+u.height+m+w:L+d-u.height/2+m-w;break;case"top":p=A?P?L+w:L-w:P?L-u.height/2-w:L+u.height+w}if(this.barCtx.lastActiveBarSerieIndex===n&&v.enabled){var O=new g(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:n,j:s}),x.fontSize);t=P?L-O.height/2-w-v.offsetY+18:L+O.height+w+v.offsetY-18;var M=a.globals.gridWidth/a.globals.dataPoints;i=k+h*(a.globals.barGroups.length-.5)-(a.globals.isXNumeric?h:M)+v.offsetX}return a.config.chart.stacked||(p<0?p=0+m:p+u.height/3>a.globals.gridHeight&&(p=a.globals.gridHeight-m)),{bcx:c,bcy:l,dataLabelsX:f,dataLabelsY:p,totalDataLabelsX:i,totalDataLabelsY:t,totalDataLabelsAnchor:"middle"}}},{key:"calculateBarsDataLabelsPosition",value:function(e){var t=this.w,i=e.x,a=e.i,r=e.j,s=e.realIndex,n=e.columnGroupIndex,o=e.bcy,l=e.barHeight,c=e.barWidth,h=e.textRects,d=e.dataLabelsX,u=e.strokeWidth,f=e.dataLabelsConfig,p=e.barDataLabelsConfig,x=e.barTotalDataLabelsConfig,b=e.offX,v=e.offY,m=t.globals.gridHeight/t.globals.dataPoints;c=Math.abs(c);var y,w,k=(o+=n*l)-(this.barCtx.isRangeBar?0:m)+l/2+h.height/2+v-3,A="start",S=this.barCtx.series[a][r]<0,C=i;switch(this.barCtx.isReversed&&(C=i+(S?-c:c),i=t.globals.gridWidth-c,A=S?"start":"end"),p.position){case"center":d=S?C+c/2-b:Math.max(h.width/2,C-c/2)+b;break;case"bottom":d=S?C+c-u-Math.round(h.width/2)-b:C-c+u+Math.round(h.width/2)+b;break;case"top":d=S?C-u+Math.round(h.width/2)-b:C-u-Math.round(h.width/2)+b}if(this.barCtx.lastActiveBarSerieIndex===s&&x.enabled){var P=new g(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:s,j:r}),f.fontSize);S?(y=C-u-b-x.offsetX,A="end"):y=C+b+x.offsetX+(this.barCtx.isReversed?-(c+u):u),w=k-h.height/2+P.height/2+x.offsetY+u}return t.config.chart.stacked||(d<0?d=d+h.width+u:d+h.width/2>t.globals.gridWidth&&(d=t.globals.gridWidth-h.width-u)),{bcx:i,bcy:o,dataLabelsX:d,dataLabelsY:k,totalDataLabelsX:y,totalDataLabelsY:w,totalDataLabelsAnchor:A}}},{key:"drawCalculatedDataLabels",value:function(e){var t=e.x,i=e.y,a=e.val,r=e.i,s=e.j,n=e.textRects,o=e.barHeight,l=e.barWidth,c=e.dataLabelsConfig,h=this.w,d="rotate(0)";"vertical"===h.config.plotOptions.bar.dataLabels.orientation&&(d="rotate(-90, ".concat(t,", ").concat(i,")"));var u=new oe(this.barCtx.ctx),f=new g(this.barCtx.ctx),p=c.formatter,x=null,b=h.globals.collapsedSeriesIndices.indexOf(r)>-1;if(c.enabled&&!b){x=f.group({class:"apexcharts-data-labels",transform:d});var v="";void 0!==a&&(v=p(a,ti(ti({},h),{},{seriesIndex:r,dataPointIndex:s,w:h}))),!a&&h.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(v="");var m=h.globals.series[r][s]<0,y=h.config.plotOptions.bar.dataLabels.position;"vertical"===h.config.plotOptions.bar.dataLabels.orientation&&("top"===y&&(c.textAnchor=m?"end":"start"),"center"===y&&(c.textAnchor="middle"),"bottom"===y&&(c.textAnchor=m?"end":"start")),this.barCtx.isRangeBar&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&l<f.getTextRects(v,parseFloat(c.style.fontSize)).width&&(v=""),h.config.chart.stacked&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&(this.barCtx.isHorizontal?n.width/1.6>Math.abs(l)&&(v=""):n.height/1.6>Math.abs(o)&&(v=""));var w=ti({},c);this.barCtx.isHorizontal&&a<0&&("start"===c.textAnchor?w.textAnchor="end":"end"===c.textAnchor&&(w.textAnchor="start")),u.plotDataLabelsText({x:t,y:i,text:v,i:r,j:s,parent:x,dataLabelsConfig:w,alwaysDrawDataLabel:!0,offsetCorrection:!0})}return x}},{key:"drawTotalDataLabels",value:function(e){var t,i=e.x,a=e.y,r=e.val,s=e.barWidth,n=e.barHeight,o=e.realIndex,l=e.textAnchor,c=e.barTotalDataLabelsConfig,h=this.w,d=new g(this.barCtx.ctx);return c.enabled&&void 0!==i&&void 0!==a&&this.barCtx.lastActiveBarSerieIndex===o&&(t=d.drawText({x:i-(!h.globals.isBarHorizontal&&h.globals.barGroups.length?s*(h.globals.barGroups.length-1)/2:0),y:a-(h.globals.isBarHorizontal&&h.globals.barGroups.length?n*(h.globals.barGroups.length-1)/2:0),foreColor:c.style.color,text:r,textAnchor:l,fontFamily:c.style.fontFamily,fontSize:c.style.fontSize,fontWeight:c.style.fontWeight})),t}}])&&ai(t.prototype,i),e}();function si(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ni(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?si(Object(i),!0).forEach((function(t){oi(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):si(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function oi(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function li(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ci=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.barCtx=t}var t,i;return t=e,i=[{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 i=0;i<e.length;i++)if(e[i].length>0&&(this.barCtx.seriesLen=this.barCtx.seriesLen+1,this.barCtx.totalItems+=e[i].length),t.globals.isXNumeric)for(var a=0;a<e[i].length;a++)t.globals.seriesX[i][a]>t.globals.minX&&t.globals.seriesX[i][a]<t.globals.maxX&&this.barCtx.visibleItems++;else this.barCtx.visibleItems=t.globals.dataPoints;0===this.barCtx.seriesLen&&(this.barCtx.seriesLen=1),this.barCtx.zeroSerieses=[],t.globals.comboCharts||this.checkZeroSeries({series:e})}},{key:"initialPositions",value:function(){var e,t,i,a,r,s,n,o,l=this.w,c=l.globals.dataPoints;this.barCtx.isRangeBar&&(c=l.globals.labels.length);var h=this.barCtx.seriesLen;if(l.config.plotOptions.bar.rangeBarGroupRows&&(h=1),this.barCtx.isHorizontal)r=(i=l.globals.gridHeight/c)/h,l.globals.isXNumeric&&(r=(i=l.globals.gridHeight/this.barCtx.totalItems)/this.barCtx.seriesLen),r=r*parseInt(this.barCtx.barOptions.barHeight,10)/100,-1===String(this.barCtx.barOptions.barHeight).indexOf("%")&&(r=parseInt(this.barCtx.barOptions.barHeight,10)),o=this.barCtx.baseLineInvertedY+l.globals.padHorizontal+(this.barCtx.isReversed?l.globals.gridWidth:0)-(this.barCtx.isReversed?2*this.barCtx.baseLineInvertedY:0),this.barCtx.isFunnel&&(o=l.globals.gridWidth/2),t=(i-r*this.barCtx.seriesLen)/2;else{if(a=l.globals.gridWidth/this.barCtx.visibleItems,l.config.xaxis.convertedCatToNumeric&&(a=l.globals.gridWidth/l.globals.dataPoints),s=a/h*parseInt(this.barCtx.barOptions.columnWidth,10)/100,l.globals.isXNumeric){var d=this.barCtx.xRatio;l.globals.minXDiff&&.5!==l.globals.minXDiff&&l.globals.minXDiff/d>0&&(a=l.globals.minXDiff/d),(s=a/h*parseInt(this.barCtx.barOptions.columnWidth,10)/100)<1&&(s=1)}-1===String(this.barCtx.barOptions.columnWidth).indexOf("%")&&(s=parseInt(this.barCtx.barOptions.columnWidth,10)),n=l.globals.gridHeight-this.barCtx.baseLineY[this.barCtx.translationsIndex]-(this.barCtx.isReversed?l.globals.gridHeight:0)+(this.barCtx.isReversed?2*this.barCtx.baseLineY[this.barCtx.translationsIndex]:0),e=l.globals.padHorizontal+(a-s*this.barCtx.seriesLen)/2}return l.globals.barHeight=r,l.globals.barWidth=s,{x:e,y:t,yDivision:i,xDivision:a,barHeight:r,barWidth:s,zeroH:n,zeroW:o}}},{key:"initializeStackedPrevVars",value:function(e){e.w.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=[]}))}},{key:"initializeStackedXYVars",value:function(e){e.w.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=[]}))}},{key:"getPathFillColor",value:function(e,t,i,a){var r,s,n,o,l=this.w,c=new te(this.barCtx.ctx),h=null,d=this.barCtx.barOptions.distributed?i:t;return this.barCtx.barOptions.colors.ranges.length>0&&this.barCtx.barOptions.colors.ranges.map((function(a){e[t][i]>=a.from&&e[t][i]<=a.to&&(h=a.color)})),l.config.series[t].data[i]&&l.config.series[t].data[i].fillColor&&(h=l.config.series[t].data[i].fillColor),c.fillPath({seriesNumber:this.barCtx.barOptions.distributed?d:a,dataPointIndex:i,color:h,value:e[t][i],fillConfig:null===(r=l.config.series[t].data[i])||void 0===r?void 0:r.fill,fillType:null!==(s=l.config.series[t].data[i])&&void 0!==s&&null!==(n=s.fill)&&void 0!==n&&n.type?null===(o=l.config.series[t].data[i])||void 0===o?void 0:o.fill.type:Array.isArray(l.config.fill.type)?l.config.fill.type[t]:l.config.fill.type})}},{key:"getStrokeWidth",value:function(e,t,i){var a=0,r=this.w;return void 0===this.barCtx.series[e][t]||null===this.barCtx.series[e][t]?this.barCtx.isNullValue=!0:this.barCtx.isNullValue=!1,r.config.stroke.show&&(this.barCtx.isNullValue||(a=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[i]:this.barCtx.strokeWidth)),a}},{key:"shouldApplyRadius",value:function(e){var t=this.w,i=!1;return t.config.plotOptions.bar.borderRadius>0&&(t.config.chart.stacked&&"last"===t.config.plotOptions.bar.borderRadiusWhenStacked?this.barCtx.lastActiveBarSerieIndex===e&&(i=!0):i=!0),i}},{key:"barBackground",value:function(e){var t=e.j,i=e.i,a=e.x1,r=e.x2,s=e.y1,n=e.y2,o=e.elSeries,l=this.w,c=new g(this.barCtx.ctx),h=new ce(this.barCtx.ctx).getActiveConfigSeriesIndex();if(this.barCtx.barOptions.colors.backgroundBarColors.length>0&&h===i){t>=this.barCtx.barOptions.colors.backgroundBarColors.length&&(t%=this.barCtx.barOptions.colors.backgroundBarColors.length);var d=this.barCtx.barOptions.colors.backgroundBarColors[t],u=c.drawRect(void 0!==a?a:0,void 0!==s?s:0,void 0!==r?r:l.globals.gridWidth,void 0!==n?n:l.globals.gridHeight,this.barCtx.barOptions.colors.backgroundBarRadius,d,this.barCtx.barOptions.colors.backgroundBarOpacity);o.add(u),u.node.classList.add("apexcharts-backgroundBar")}}},{key:"getColumnPaths",value:function(e){var t,i=e.barWidth,a=e.barXPosition,r=e.y1,s=e.y2,n=e.strokeWidth,o=e.seriesGroup,l=e.realIndex,c=e.i,h=e.j,d=e.w,u=new g(this.barCtx.ctx);(n=Array.isArray(n)?n[l]:n)||(n=0);var f=i,p=a;null!==(t=d.config.series[l].data[h])&&void 0!==t&&t.columnWidthOffset&&(p=a-d.config.series[l].data[h].columnWidthOffset/2,f=i+d.config.series[l].data[h].columnWidthOffset);var x=n/2,b=p+x,v=p+f-x;r+=.001-x,s+=.001+x;var m=u.move(b,r),y=u.move(b,r),w=u.line(v,r);if(d.globals.previousPaths.length>0&&(y=this.barCtx.getPreviousPath(l,h,!1)),m=m+u.line(b,s)+u.line(v,s)+u.line(v,r)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),y=y+u.line(b,r)+w+w+w+w+w+u.line(b,r)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(l)&&(m=u.roundPathCorners(m,d.config.plotOptions.bar.borderRadius)),d.config.chart.stacked){var k=this.barCtx;(k=this.barCtx[o]).yArrj.push(s-x),k.yArrjF.push(Math.abs(r-s+n)),k.yArrjVal.push(this.barCtx.series[c][h])}return{pathTo:m,pathFrom:y}}},{key:"getBarpaths",value:function(e){var t,i=e.barYPosition,a=e.barHeight,r=e.x1,s=e.x2,n=e.strokeWidth,o=e.seriesGroup,l=e.realIndex,c=e.i,h=e.j,d=e.w,u=new g(this.barCtx.ctx);(n=Array.isArray(n)?n[l]:n)||(n=0);var f=i,p=a;null!==(t=d.config.series[l].data[h])&&void 0!==t&&t.barHeightOffset&&(f=i-d.config.series[l].data[h].barHeightOffset/2,p=a+d.config.series[l].data[h].barHeightOffset);var x=n/2,b=f+x,v=f+p-x;r+=.001-x,s+=.001+x;var m=u.move(r,b),y=u.move(r,b);d.globals.previousPaths.length>0&&(y=this.barCtx.getPreviousPath(l,h,!1));var w=u.line(r,v);if(m=m+u.line(s,b)+u.line(s,v)+w+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),y=y+u.line(r,b)+w+w+w+w+w+u.line(r,b)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(l)&&(m=u.roundPathCorners(m,d.config.plotOptions.bar.borderRadius)),d.config.chart.stacked){var k=this.barCtx;(k=this.barCtx[o]).xArrj.push(s+x),k.xArrjF.push(Math.abs(r-s)),k.xArrjVal.push(this.barCtx.series[c][h])}return{pathTo:m,pathFrom:y}}},{key:"checkZeroSeries",value:function(e){for(var t=e.series,i=this.w,a=0;a<t.length;a++){for(var r=0,s=0;s<t[i.globals.maxValsInArrayIndex].length;s++)r+=t[a][s];0===r&&this.barCtx.zeroSerieses.push(a)}}},{key:"getXForValue",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&!arguments[2]?null:t;return null!=e&&(i=t+e/this.barCtx.invertedYRatio-2*(this.barCtx.isReversed?e/this.barCtx.invertedYRatio:0)),i}},{key:"getYForValue",value:function(e,t,i){var a=arguments.length>3&&void 0!==arguments[3]&&!arguments[3]?null:t;return null!=e&&(a=t-e/this.barCtx.yRatio[i]+2*(this.barCtx.isReversed?e/this.barCtx.yRatio[i]:0)),a}},{key:"getGoalValues",value:function(e,t,i,a,r,s){var n=this,o=this.w,l=[],c=function(a,r){var o;l.push((oi(o={},e,"x"===e?n.getXForValue(a,t,!1):n.getYForValue(a,i,s,!1)),oi(o,"attrs",r),o))};if(o.globals.seriesGoals[a]&&o.globals.seriesGoals[a][r]&&Array.isArray(o.globals.seriesGoals[a][r])&&o.globals.seriesGoals[a][r].forEach((function(e){c(e.value,e)})),this.barCtx.barOptions.isDumbbell&&o.globals.seriesRange.length){var h=this.barCtx.barOptions.dumbbellColors?this.barCtx.barOptions.dumbbellColors:o.globals.colors,d={strokeHeight:"x"===e?0:o.globals.markers.size[a],strokeWidth:"x"===e?o.globals.markers.size[a]:0,strokeDashArray:0,strokeLineCap:"round",strokeColor:Array.isArray(h[a])?h[a][0]:h[a]};c(o.globals.seriesRangeStart[a][r],d),c(o.globals.seriesRangeEnd[a][r],ni(ni({},d),{},{strokeColor:Array.isArray(h[a])?h[a][1]:h[a]}))}return l}},{key:"drawGoalLine",value:function(e){var t=e.barXPosition,i=e.barYPosition,a=e.goalX,r=e.goalY,s=e.barWidth,n=e.barHeight,o=new g(this.barCtx.ctx),l=o.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(a)&&a.forEach((function(e){if(e.x>=-1&&e.x<=o.w.globals.gridWidth+1){var t=void 0!==e.attrs.strokeHeight?e.attrs.strokeHeight:n/2,a=i+t+n/2;c=o.drawLine(e.x,a-2*t,e.x,a,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(r)&&r.forEach((function(e){if(e.y>=-1&&e.y<=o.w.globals.gridHeight+1){var i=void 0!==e.attrs.strokeWidth?e.attrs.strokeWidth:s/2,a=t+i+s/2;c=o.drawLine(a-2*i,e.y,a,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,i=e.currPaths,a=e.color,s=this.w,n=t.x,o=t.x1,l=t.barYPosition,c=i.x,h=i.x1,d=i.barYPosition,u=l+i.barHeight,f=new g(this.barCtx.ctx),p=new r,x=f.move(o,u)+f.line(n,u)+f.line(c,d)+f.line(h,d)+f.line(o,u)+("around"===s.config.plotOptions.bar.borderRadiusApplication?" Z":" z");return f.drawPath({d:x,fill:p.shadeColor(.5,r.rgb2hex(a)),stroke:"none",strokeWidth:0,fillOpacity:1,classes:"apexcharts-bar-shadows"})}},{key:"getZeroValueEncounters",value:function(e){var t,i=e.i,a=e.j,r=this.w,s=0,n=0;return(r.config.plotOptions.bar.horizontal?r.globals.series.map((function(e,t){return t})):(null===(t=r.globals.columnSeries)||void 0===t?void 0:t.i.map((function(e){return e})))||[]).forEach((function(e){var t=r.globals.seriesPercent[e][a];t&&s++,e<i&&0===t&&n++})),{nonZeroColumns:s,zeroEncounters:n}}},{key:"getGroupIndex",value:function(e){var t=this.w,i=t.globals.seriesGroups.findIndex((function(i){return i.indexOf(t.globals.seriesNames[e])>-1})),a=this.barCtx.columnGroupIndices,r=a.indexOf(i);return r<0&&(a.push(i),r=a.length-1),{groupIndex:i,columnGroupIndex:r}}}],i&&li(t.prototype,i),e}();function hi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function di(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?hi(Object(i),!0).forEach((function(t){ui(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):hi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ui(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function gi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const fi=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var a=this.w;this.barOptions=a.config.plotOptions.bar,this.isHorizontal=this.barOptions.horizontal,this.strokeWidth=a.config.stroke.width,this.isNullValue=!1,this.isRangeBar=a.globals.seriesRange.length&&this.isHorizontal,this.isVerticalGroupedRangeBar=!a.globals.isBarHorizontal&&a.globals.seriesRange.length&&a.config.plotOptions.bar.rangeBarGroupRows,this.isFunnel=this.barOptions.isFunnel,this.xyRatios=i,null!==this.xyRatios&&(this.xRatio=i.xRatio,this.yRatio=i.yRatio,this.invertedXRatio=i.invertedXRatio,this.invertedYRatio=i.invertedYRatio,this.baseLineY=i.baseLineY,this.baseLineInvertedY=i.baseLineInvertedY),this.yaxisIndex=0,this.translationsIndex=0,this.seriesLen=0,this.pathArr=[];var r=new ce(this.ctx);this.lastActiveBarSerieIndex=r.getActiveConfigSeriesIndex("desc",["bar","column"]),this.columnGroupIndices=[];var s=r.getBarSeriesIndices(),n=new p(this.ctx);this.stackedSeriesTotals=n.getStackedSeriesTotals(this.w.config.series.map((function(e,t){return-1===s.indexOf(t)?t:-1})).filter((function(e){return-1!==e}))),this.barHelpers=new ci(this)}var t,i;return t=e,(i=[{key:"draw",value:function(e,t){var i=this.w,a=new g(this.ctx),s=new p(this.ctx,i);e=s.getLogSeries(e),this.series=e,this.yRatio=s.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e);var n=a.group({class:"apexcharts-bar-series apexcharts-plot-series"});i.config.dataLabels.enabled&&this.totalItems>this.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 o=0,l=0;o<e.length;o++,l++){var c,h,d,u,f=void 0,x=void 0,b=[],v=[],m=i.globals.comboCharts?t[o]:o,y=this.barHelpers.getGroupIndex(m).columnGroupIndex,w=a.group({class:"apexcharts-series",rel:o+1,seriesName:r.escapeString(i.globals.seriesNames[m]),"data:realIndex":m});this.ctx.series.addCollapsedClassToSeries(w,m),e[o].length>0&&(this.visibleI=this.visibleI+1);var k=0,A=0;this.yRatio.length>1&&(this.yaxisIndex=i.globals.seriesYAxisReverseMap[m],this.translationsIndex=m);var S=this.translationsIndex;this.isReversed=i.config.yaxis[this.yaxisIndex]&&i.config.yaxis[this.yaxisIndex].reversed;var C=this.barHelpers.initialPositions();x=C.y,k=C.barHeight,h=C.yDivision,u=C.zeroW,f=C.x,A=C.barWidth,c=C.xDivision,d=C.zeroH,this.horizontal||v.push(f+A/2);var P=a.group({class:"apexcharts-datalabels","data:realIndex":m});i.globals.delayedElements.push({el:P.node}),P.node.classList.add("apexcharts-element-hidden");var L=a.group({class:"apexcharts-bar-goals-markers"}),O=a.group({class:"apexcharts-bar-shadows"});i.globals.delayedElements.push({el:O.node}),O.node.classList.add("apexcharts-element-hidden");for(var M=0;M<e[o].length;M++){var T=this.barHelpers.getStrokeWidth(o,M,m),I=null,E={indexes:{i:o,j:M,realIndex:m,translationsIndex:S,bc:l},x:f,y:x,strokeWidth:T,elSeries:w};this.isHorizontal?(I=this.drawBarPaths(di(di({},E),{},{barHeight:k,zeroW:u,yDivision:h})),A=this.series[o][M]/this.invertedYRatio):(I=this.drawColumnPaths(di(di({},E),{},{xDivision:c,barWidth:A,zeroH:d})),k=this.series[o][M]/this.yRatio[S]);var z=this.barHelpers.getPathFillColor(e,o,M,m);if(this.isFunnel&&this.barOptions.isFunnel3d&&this.pathArr.length&&M>0){var X=this.barHelpers.drawBarShadow({color:"string"==typeof z&&-1===(null==z?void 0:z.indexOf("url"))?z:r.hexToRgba(i.globals.colors[o]),prevPaths:this.pathArr[this.pathArr.length-1],currPaths:I});X&&O.add(X)}this.pathArr.push(I);var Y=this.barHelpers.drawGoalLine({barXPosition:I.barXPosition,barYPosition:I.barYPosition,goalX:I.goalX,goalY:I.goalY,barHeight:k,barWidth:A});Y&&L.add(Y),x=I.y,f=I.x,M>0&&v.push(f+A/2),b.push(x),this.renderSeries({realIndex:m,pathFill:z,j:M,i:o,columnGroupIndex:y,pathFrom:I.pathFrom,pathTo:I.pathTo,strokeWidth:T,elSeries:w,x:f,y:x,series:e,barHeight:I.barHeight?I.barHeight:k,barWidth:I.barWidth?I.barWidth:A,elDataLabelsWrap:P,elGoalsMarkers:L,elBarShadows:O,visibleSeries:this.visibleI,type:"bar"})}i.globals.seriesXvalues[m]=v,i.globals.seriesYvalues[m]=b,n.add(w)}return n}},{key:"renderSeries",value:function(e){var t=e.realIndex,i=e.pathFill,a=e.lineFill,r=e.j,s=e.i,n=e.columnGroupIndex,o=e.pathFrom,c=e.pathTo,h=e.strokeWidth,d=e.elSeries,u=e.x,f=e.y,p=e.y1,x=e.y2,b=e.series,v=e.barHeight,m=e.barWidth,y=e.barXPosition,w=e.barYPosition,k=e.elDataLabelsWrap,A=e.elGoalsMarkers,S=e.elBarShadows,C=e.visibleSeries,P=e.type,L=this.w,O=new g(this.ctx);if(!a){var M="function"==typeof L.globals.stroke.colors[t]?function(e){var t,i=L.config.stroke.colors;return Array.isArray(i)&&i.length>0&&((t=i[e])||(t=""),"function"==typeof t)?t({value:L.globals.series[e][r],dataPointIndex:r,w:L}):t}(t):L.globals.stroke.colors[t];a=this.barOptions.distributed?L.globals.stroke.colors[r]:M}L.config.series[s].data[r]&&L.config.series[s].data[r].strokeColor&&(a=L.config.series[s].data[r].strokeColor),this.isNullValue&&(i="none");var T=r/L.config.chart.animations.animateGradually.delay*(L.config.chart.animations.speed/L.globals.dataPoints)/2.4,I=O.renderPaths({i:s,j:r,realIndex:t,pathFrom:o,pathTo:c,stroke:a,strokeWidth:h,strokeLineCap:L.config.stroke.lineCap,fill:i,animationDelay:T,initialSpeed:L.config.chart.animations.speed,dataChangeSpeed:L.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(P,"-area")});I.attr("clip-path","url(#gridRectMask".concat(L.globals.cuid,")"));var E=L.config.forecastDataPoints;E.count>0&&r>=L.globals.dataPoints-E.count&&(I.node.setAttribute("stroke-dasharray",E.dashArray),I.node.setAttribute("stroke-width",E.strokeWidth),I.node.setAttribute("fill-opacity",E.fillOpacity)),void 0!==p&&void 0!==x&&(I.attr("data-range-y1",p),I.attr("data-range-y2",x)),new l(this.ctx).setSelectionFilter(I,t,r),d.add(I);var z=new ri(this).handleBarDataLabels({x:u,y:f,y1:p,y2:x,i:s,j:r,series:b,realIndex:t,columnGroupIndex:n,barHeight:v,barWidth:m,barXPosition:y,barYPosition:w,renderedPath:I,visibleSeries:C});return null!==z.dataLabels&&k.add(z.dataLabels),z.totalDataLabels&&k.add(z.totalDataLabels),d.add(k),A&&d.add(A),S&&d.add(S),d}},{key:"drawBarPaths",value:function(e){var t,i=e.indexes,a=e.barHeight,r=e.strokeWidth,s=e.zeroW,n=e.x,o=e.y,l=e.yDivision,c=e.elSeries,h=this.w,d=i.i,u=i.j;if(h.globals.isXNumeric)t=(o=(h.globals.seriesX[d][u]-h.globals.minX)/this.invertedXRatio-a)+a*this.visibleI;else if(h.config.plotOptions.bar.hideZeroBarsWhenGrouped){var g=0,f=0;h.globals.seriesPercent.forEach((function(e,t){e[u]&&g++,t<d&&0===e[u]&&f++})),g>0&&(a=this.seriesLen*a/g),t=o+a*this.visibleI,t-=a*f}else t=o+a*this.visibleI;this.isFunnel&&(s-=(this.barHelpers.getXForValue(this.series[d][u],s)-s)/2),n=this.barHelpers.getXForValue(this.series[d][u],s);var p=this.barHelpers.getBarpaths({barYPosition:t,barHeight:a,x1:s,x2:n,strokeWidth:r,series:this.series,realIndex:i.realIndex,i:d,j:u,w:h});return h.globals.isXNumeric||(o+=l),this.barHelpers.barBackground({j:u,i:d,y1:t-a*this.visibleI,y2:a*this.seriesLen,elSeries:c}),{pathTo:p.pathTo,pathFrom:p.pathFrom,x1:s,x:n,y:o,goalX:this.barHelpers.getGoalValues("x",s,null,d,u),barYPosition:t,barHeight:a}}},{key:"drawColumnPaths",value:function(e){var t,i=e.indexes,a=e.x,r=e.y,s=e.xDivision,n=e.barWidth,o=e.zeroH,l=e.strokeWidth,c=e.elSeries,h=this.w,d=i.realIndex,u=i.translationsIndex,g=i.i,f=i.j,p=i.bc;if(h.globals.isXNumeric){var x=this.getBarXForNumericXAxis({x:a,j:f,realIndex:d,barWidth:n});a=x.x,t=x.barXPosition}else if(h.config.plotOptions.bar.hideZeroBarsWhenGrouped){var b=this.barHelpers.getZeroValueEncounters({i:g,j:f}),v=b.nonZeroColumns,m=b.zeroEncounters;v>0&&(n=this.seriesLen*n/v),t=a+n*this.visibleI,t-=n*m}else t=a+n*this.visibleI;r=this.barHelpers.getYForValue(this.series[g][f],o,u);var y=this.barHelpers.getColumnPaths({barXPosition:t,barWidth:n,y1:o,y2:r,strokeWidth:l,series:this.series,realIndex:d,i:g,j:f,w:h});return h.globals.isXNumeric||(a+=s),this.barHelpers.barBackground({bc:p,j:f,i:g,x1:t-l/2-n*this.visibleI,x2:n*this.seriesLen+l/2,elSeries:c}),{pathTo:y.pathTo,pathFrom:y.pathFrom,x:a,y:r,goalY:this.barHelpers.getGoalValues("y",null,o,g,f,u),barXPosition:t,barWidth:n}}},{key:"getBarXForNumericXAxis",value:function(e){var t=e.x,i=e.barWidth,a=e.realIndex,r=e.j,s=this.w,n=a;return s.globals.seriesX[a].length||(n=s.globals.maxValsInArrayIndex),s.globals.seriesX[n][r]&&(t=(s.globals.seriesX[n][r]-s.globals.minX)/this.xRatio-i*this.seriesLen/2),{barXPosition:t+i*this.visibleI,x:t}}},{key:"getPreviousPath",value:function(e,t){for(var i,a=this.w,r=0;r<a.globals.previousPaths.length;r++){var s=a.globals.previousPaths[r];s.paths&&s.paths.length>0&&parseInt(s.realIndex,10)===parseInt(e,10)&&void 0!==a.globals.previousPaths[r].paths[t]&&(i=a.globals.previousPaths[r].paths[t].d)}return i}}])&&gi(t.prototype,i),e}();function pi(e){return pi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},pi(e)}function xi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function bi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?xi(Object(i),!0).forEach((function(t){vi(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):xi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function vi(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function mi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function yi(e,t){return yi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},yi(e,t)}function wi(e){return wi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},wi(e)}const ki=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&yi(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=wi(a);if(s){var i=wi(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===pi(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n.apply(this,arguments)}return t=o,(i=[{key:"draw",value:function(e,t){var i=this,a=this.w;this.graphics=new g(this.ctx),this.bar=new fi(this.ctx,this.xyRatios);var s=new p(this.ctx,a);e=s.getLogSeries(e),this.yRatio=s.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e),"100%"===a.config.chart.stackType&&(e=a.globals.comboCharts?t.map((function(e){return a.globals.seriesPercent[e]})):a.globals.seriesPercent.slice()),this.series=e,this.barHelpers.initializeStackedPrevVars(this);for(var n=this.graphics.group({class:"apexcharts-bar-series apexcharts-plot-series"}),o=0,l=0,c=function(s,c){var h=void 0,d=void 0,u=void 0,g=void 0,f=a.globals.comboCharts?t[s]:s,p=i.barHelpers.getGroupIndex(f),x=p.groupIndex,b=p.columnGroupIndex;i.groupCtx=i[a.globals.seriesGroups[x]];var v=[],m=[],y=0;i.yRatio.length>1&&(i.yaxisIndex=a.globals.seriesYAxisReverseMap[f][0],y=f),i.isReversed=a.config.yaxis[i.yaxisIndex]&&a.config.yaxis[i.yaxisIndex].reversed;var w=i.graphics.group({class:"apexcharts-series",seriesName:r.escapeString(a.globals.seriesNames[f]),rel:s+1,"data:realIndex":f});i.ctx.series.addCollapsedClassToSeries(w,f);var k=i.graphics.group({class:"apexcharts-datalabels","data:realIndex":f}),A=i.graphics.group({class:"apexcharts-bar-goals-markers"}),S=0,C=0,P=i.initialPositions(o,l,h,d,u,g,y);l=P.y,S=P.barHeight,d=P.yDivision,g=P.zeroW,o=P.x,C=P.barWidth,h=P.xDivision,u=P.zeroH,a.globals.barHeight=S,a.globals.barWidth=C,i.barHelpers.initializeStackedXYVars(i),1===i.groupCtx.prevY.length&&i.groupCtx.prevY[0].every((function(e){return isNaN(e)}))&&(i.groupCtx.prevY[0]=i.groupCtx.prevY[0].map((function(){return u})),i.groupCtx.prevYF[0]=i.groupCtx.prevYF[0].map((function(){return 0})));for(var L=0;L<a.globals.dataPoints;L++){var O=i.barHelpers.getStrokeWidth(s,L,f),M={indexes:{i:s,j:L,realIndex:f,translationsIndex:y,bc:c},strokeWidth:O,x:o,y:l,elSeries:w,columnGroupIndex:b,seriesGroup:a.globals.seriesGroups[x]},T=null;i.isHorizontal?(T=i.drawStackedBarPaths(bi(bi({},M),{},{zeroW:g,barHeight:S,yDivision:d})),C=i.series[s][L]/i.invertedYRatio):(T=i.drawStackedColumnPaths(bi(bi({},M),{},{xDivision:h,barWidth:C,zeroH:u})),S=i.series[s][L]/i.yRatio[y]);var I=i.barHelpers.drawGoalLine({barXPosition:T.barXPosition,barYPosition:T.barYPosition,goalX:T.goalX,goalY:T.goalY,barHeight:S,barWidth:C});I&&A.add(I),l=T.y,o=T.x,v.push(o),m.push(l);var E=i.barHelpers.getPathFillColor(e,s,L,f);w=i.renderSeries({realIndex:f,pathFill:E,j:L,i:s,columnGroupIndex:b,pathFrom:T.pathFrom,pathTo:T.pathTo,strokeWidth:O,elSeries:w,x:o,y:l,series:e,barHeight:S,barWidth:C,elDataLabelsWrap:k,elGoalsMarkers:A,type:"bar",visibleSeries:0})}a.globals.seriesXvalues[f]=v,a.globals.seriesYvalues[f]=m,i.groupCtx.prevY.push(i.groupCtx.yArrj),i.groupCtx.prevYF.push(i.groupCtx.yArrjF),i.groupCtx.prevYVal.push(i.groupCtx.yArrjVal),i.groupCtx.prevX.push(i.groupCtx.xArrj),i.groupCtx.prevXF.push(i.groupCtx.xArrjF),i.groupCtx.prevXVal.push(i.groupCtx.xArrjVal),n.add(w)},h=0,d=0;h<e.length;h++,d++)c(h,d);return n}},{key:"initialPositions",value:function(e,t,i,a,r,s,n){var o,l,c=this.w;if(this.isHorizontal){a=c.globals.gridHeight/c.globals.dataPoints;var h=c.config.plotOptions.bar.barHeight;o=-1===String(h).indexOf("%")?parseInt(h,10):a*parseInt(h,10)/100,s=c.globals.padHorizontal+(this.isReversed?c.globals.gridWidth-this.baseLineInvertedY:this.baseLineInvertedY),t=(a-o)/2}else{l=i=c.globals.gridWidth/c.globals.dataPoints;var d=c.config.plotOptions.bar.columnWidth;c.globals.isXNumeric&&c.globals.dataPoints>1?l=(i=c.globals.minXDiff/this.xRatio)*parseInt(this.barOptions.columnWidth,10)/100:-1===String(d).indexOf("%")?l=parseInt(d,10):l*=parseInt(d,10)/100,r=c.globals.gridHeight-this.baseLineY[n]-(this.isReversed?c.globals.gridHeight:0),e=c.globals.padHorizontal+(i-l)/2}var u=c.globals.barGroups.length||1;return{x:e,y:t,yDivision:a,xDivision:i,barHeight:o/u,barWidth:l/u,zeroH:r,zeroW:s}}},{key:"drawStackedBarPaths",value:function(e){for(var t,i=e.indexes,a=e.barHeight,r=e.strokeWidth,s=e.zeroW,n=e.x,o=e.y,l=e.columnGroupIndex,c=e.seriesGroup,h=e.yDivision,d=e.elSeries,u=this.w,g=o+l*a,f=i.i,p=i.j,x=i.realIndex,b=i.translationsIndex,v=0,m=0;m<this.groupCtx.prevXF.length;m++)v+=this.groupCtx.prevXF[m][p];var y;if((y=c.indexOf(u.config.series[x].name))>0){var w=s;this.groupCtx.prevXVal[y-1][p]<0?w=this.series[f][p]>=0?this.groupCtx.prevX[y-1][p]+v-2*(this.isReversed?v:0):this.groupCtx.prevX[y-1][p]:this.groupCtx.prevXVal[y-1][p]>=0&&(w=this.series[f][p]>=0?this.groupCtx.prevX[y-1][p]:this.groupCtx.prevX[y-1][p]-v+2*(this.isReversed?v:0)),t=w}else t=s;n=null===this.series[f][p]?t:t+this.series[f][p]/this.invertedYRatio-2*(this.isReversed?this.series[f][p]/this.invertedYRatio:0);var k=this.barHelpers.getBarpaths({barYPosition:g,barHeight:a,x1:t,x2:n,strokeWidth:r,series:this.series,realIndex:i.realIndex,seriesGroup:c,i:f,j:p,w:u});return this.barHelpers.barBackground({j:p,i:f,y1:g,y2:a,elSeries:d}),o+=h,{pathTo:k.pathTo,pathFrom:k.pathFrom,goalX:this.barHelpers.getGoalValues("x",s,null,f,p,b),barXPosition:t,barYPosition:g,x:n,y:o}}},{key:"drawStackedColumnPaths",value:function(e){var t=e.indexes,i=e.x,a=e.y,r=e.xDivision,s=e.barWidth,n=e.zeroH,o=e.columnGroupIndex,l=e.seriesGroup,c=e.elSeries,h=this.w,d=t.i,u=t.j,g=t.bc,f=t.realIndex,p=t.translationsIndex;if(h.globals.isXNumeric){var x=h.globals.seriesX[f][u];x||(x=0),i=(x-h.globals.minX)/this.xRatio-s/2*h.globals.barGroups.length}for(var b,v=i+o*s,m=0,y=0;y<this.groupCtx.prevYF.length;y++)m+=isNaN(this.groupCtx.prevYF[y][u])?0:this.groupCtx.prevYF[y][u];var w=d;if(l&&(w=l.indexOf(h.globals.seriesNames[f])),w>0&&!h.globals.isXNumeric||w>0&&h.globals.isXNumeric&&h.globals.seriesX[f-1][u]===h.globals.seriesX[f][u]){var k,A,S,C=Math.min(this.yRatio.length+1,f+1);if(void 0!==this.groupCtx.prevY[w-1]&&this.groupCtx.prevY[w-1].length)for(var P=1;P<C;P++){var L;if(!isNaN(null===(L=this.groupCtx.prevY[w-P])||void 0===L?void 0:L[u])){S=this.groupCtx.prevY[w-P][u];break}}for(var O=1;O<C;O++){var M,T;if((null===(M=this.groupCtx.prevYVal[w-O])||void 0===M?void 0:M[u])<0){A=this.series[d][u]>=0?S-m+2*(this.isReversed?m:0):S;break}if((null===(T=this.groupCtx.prevYVal[w-O])||void 0===T?void 0:T[u])>=0){A=this.series[d][u]>=0?S:S+m-2*(this.isReversed?m:0);break}}void 0===A&&(A=h.globals.gridHeight),b=null!==(k=this.groupCtx.prevYF[0])&&void 0!==k&&k.every((function(e){return 0===e}))&&this.groupCtx.prevYF.slice(1,w).every((function(e){return e.every((function(e){return isNaN(e)}))}))?n:A}else b=n;a=this.series[d][u]?b-this.series[d][u]/this.yRatio[p]+2*(this.isReversed?this.series[d][u]/this.yRatio[p]:0):b;var I=this.barHelpers.getColumnPaths({barXPosition:v,barWidth:s,y1:b,y2:a,yRatio:this.yRatio[p],strokeWidth:this.strokeWidth,series:this.series,seriesGroup:l,realIndex:t.realIndex,i:d,j:u,w:h});return this.barHelpers.barBackground({bc:g,j:u,i:d,x1:v,x2:s,elSeries:c}),{pathTo:I.pathTo,pathFrom:I.pathFrom,goalY:this.barHelpers.getGoalValues("y",null,n,d,u),barXPosition:v,x:h.globals.isXNumeric?i:i+r,y:a}}}])&&mi(t.prototype,i),o}(fi);function Ai(e){return Ai="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ai(e)}function Si(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Ci(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Si(Object(i),!0).forEach((function(t){Pi(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Si(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Pi(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Li(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function Oi(e,t){return Oi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Oi(e,t)}function Mi(e){return Mi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Mi(e)}const Ti=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Oi(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Mi(a);if(s){var i=Mi(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Ai(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n.apply(this,arguments)}return t=o,(i=[{key:"draw",value:function(e,t,i){var a=this,s=this.w,n=new g(this.ctx),o=s.globals.comboCharts?t:s.config.chart.type,l=new te(this.ctx);this.candlestickOptions=this.w.config.plotOptions.candlestick,this.boxOptions=this.w.config.plotOptions.boxPlot,this.isHorizontal=s.config.plotOptions.bar.horizontal;var c=new p(this.ctx,s);e=c.getLogSeries(e),this.series=e,this.yRatio=c.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e);for(var h=n.group({class:"apexcharts-".concat(o,"-series apexcharts-plot-series")}),d=function(t){a.isBoxPlot="boxPlot"===s.config.chart.type||"boxPlot"===s.config.series[t].type;var o,c,d,u,g=void 0,f=void 0,p=[],x=[],b=s.globals.comboCharts?i[t]:t,v=a.barHelpers.getGroupIndex(b).columnGroupIndex,m=n.group({class:"apexcharts-series",seriesName:r.escapeString(s.globals.seriesNames[b]),rel:t+1,"data:realIndex":b});a.ctx.series.addCollapsedClassToSeries(m,b),e[t].length>0&&(a.visibleI=a.visibleI+1);var y,w,k=0;a.yRatio.length>1&&(a.yaxisIndex=s.globals.seriesYAxisReverseMap[b][0],k=b);var A=a.barHelpers.initialPositions();f=A.y,y=A.barHeight,c=A.yDivision,u=A.zeroW,g=A.x,w=A.barWidth,o=A.xDivision,d=A.zeroH,x.push(g+w/2);for(var S=n.group({class:"apexcharts-datalabels","data:realIndex":b}),C=function(i){var r=a.barHelpers.getStrokeWidth(t,i,b),n=null,h={indexes:{i:t,j:i,realIndex:b,translationsIndex:k},x:g,y:f,strokeWidth:r,elSeries:m};n=a.isHorizontal?a.drawHorizontalBoxPaths(Ci(Ci({},h),{},{yDivision:c,barHeight:y,zeroW:u})):a.drawVerticalBoxPaths(Ci(Ci({},h),{},{xDivision:o,barWidth:w,zeroH:d})),f=n.y,g=n.x,i>0&&x.push(g+w/2),p.push(f),n.pathTo.forEach((function(o,c){var h=!a.isBoxPlot&&a.candlestickOptions.wick.useFillColor?n.color[c]:s.globals.stroke.colors[t],d=l.fillPath({seriesNumber:b,dataPointIndex:i,color:n.color[c],value:e[t][i]});a.renderSeries({realIndex:b,pathFill:d,lineFill:h,j:i,i:t,pathFrom:n.pathFrom,pathTo:o,strokeWidth:r,elSeries:m,x:g,y:f,series:e,columnGroupIndex:v,barHeight:y,barWidth:w,elDataLabelsWrap:S,visibleSeries:a.visibleI,type:s.config.chart.type})}))},P=0;P<s.globals.dataPoints;P++)C(P);s.globals.seriesXvalues[b]=x,s.globals.seriesYvalues[b]=p,h.add(m)},u=0;u<e.length;u++)d(u);return h}},{key:"drawVerticalBoxPaths",value:function(e){var t=e.indexes,i=e.x,a=(e.y,e.xDivision),r=e.barWidth,s=e.zeroH,n=e.strokeWidth,o=this.w,l=new g(this.ctx),c=t.i,h=t.j,d=!0,u=o.config.plotOptions.candlestick.colors.upward,f=o.config.plotOptions.candlestick.colors.downward,p="";this.isBoxPlot&&(p=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var x=this.yRatio[t.translationsIndex],b=t.realIndex,v=this.getOHLCValue(b,h),m=s,y=s;v.o>v.c&&(d=!1);var w=Math.min(v.o,v.c),k=Math.max(v.o,v.c),A=v.m;o.globals.isXNumeric&&(i=(o.globals.seriesX[b][h]-o.globals.minX)/this.xRatio-r/2);var S=i+r*this.visibleI;void 0===this.series[c][h]||null===this.series[c][h]?(w=s,k=s):(w=s-w/x,k=s-k/x,m=s-v.h/x,y=s-v.l/x,A=s-v.m/x);var C=l.move(S,s),P=l.move(S+r/2,w);return o.globals.previousPaths.length>0&&(P=this.getPreviousPath(b,h,!0)),C=this.isBoxPlot?[l.move(S,w)+l.line(S+r/2,w)+l.line(S+r/2,m)+l.line(S+r/4,m)+l.line(S+r-r/4,m)+l.line(S+r/2,m)+l.line(S+r/2,w)+l.line(S+r,w)+l.line(S+r,A)+l.line(S,A)+l.line(S,w+n/2),l.move(S,A)+l.line(S+r,A)+l.line(S+r,k)+l.line(S+r/2,k)+l.line(S+r/2,y)+l.line(S+r-r/4,y)+l.line(S+r/4,y)+l.line(S+r/2,y)+l.line(S+r/2,k)+l.line(S,k)+l.line(S,A)+"z"]:[l.move(S,k)+l.line(S+r/2,k)+l.line(S+r/2,m)+l.line(S+r/2,k)+l.line(S+r,k)+l.line(S+r,w)+l.line(S+r/2,w)+l.line(S+r/2,y)+l.line(S+r/2,w)+l.line(S,w)+l.line(S,k-n/2)],P+=l.move(S,w),o.globals.isXNumeric||(i+=a),{pathTo:C,pathFrom:P,x:i,y:k,barXPosition:S,color:this.isBoxPlot?p:d?[u]:[f]}}},{key:"drawHorizontalBoxPaths",value:function(e){var t=e.indexes,i=(e.x,e.y),a=e.yDivision,r=e.barHeight,s=e.zeroW,n=e.strokeWidth,o=this.w,l=new g(this.ctx),c=t.i,h=t.j,d=this.boxOptions.colors.lower;this.isBoxPlot&&(d=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var u=this.invertedYRatio,f=t.realIndex,p=this.getOHLCValue(f,h),x=s,b=s,v=Math.min(p.o,p.c),m=Math.max(p.o,p.c),y=p.m;o.globals.isXNumeric&&(i=(o.globals.seriesX[f][h]-o.globals.minX)/this.invertedXRatio-r/2);var w=i+r*this.visibleI;void 0===this.series[c][h]||null===this.series[c][h]?(v=s,m=s):(v=s+v/u,m=s+m/u,x=s+p.h/u,b=s+p.l/u,y=s+p.m/u);var k=l.move(s,w),A=l.move(v,w+r/2);return o.globals.previousPaths.length>0&&(A=this.getPreviousPath(f,h,!0)),k=[l.move(v,w)+l.line(v,w+r/2)+l.line(x,w+r/2)+l.line(x,w+r/2-r/4)+l.line(x,w+r/2+r/4)+l.line(x,w+r/2)+l.line(v,w+r/2)+l.line(v,w+r)+l.line(y,w+r)+l.line(y,w)+l.line(v+n/2,w),l.move(y,w)+l.line(y,w+r)+l.line(m,w+r)+l.line(m,w+r/2)+l.line(b,w+r/2)+l.line(b,w+r-r/4)+l.line(b,w+r/4)+l.line(b,w+r/2)+l.line(m,w+r/2)+l.line(m,w)+l.line(y,w)+"z"],A+=l.move(v,w),o.globals.isXNumeric||(i+=a),{pathTo:k,pathFrom:A,x:m,y:i,barYPosition:w,color:d}}},{key:"getOHLCValue",value:function(e,t){var i=this.w;return{o:this.isBoxPlot?i.globals.seriesCandleH[e][t]:i.globals.seriesCandleO[e][t],h:this.isBoxPlot?i.globals.seriesCandleO[e][t]:i.globals.seriesCandleH[e][t],m:i.globals.seriesCandleM[e][t],l:this.isBoxPlot?i.globals.seriesCandleC[e][t]:i.globals.seriesCandleL[e][t],c:this.isBoxPlot?i.globals.seriesCandleL[e][t]:i.globals.seriesCandleC[e][t]}}}])&&Li(t.prototype,i),o}(fi);function Ii(e){return function(e){if(Array.isArray(e))return Ei(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Ei(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Ei(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ei(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function zi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Xi=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"checkColorRange",value:function(){var e=this.w,t=!1,i=e.config.plotOptions[e.config.chart.type];return i.colorScale.ranges.length>0&&i.colorScale.ranges.map((function(e,i){e.from<=0&&(t=!0)})),t}},{key:"getShadeColor",value:function(e,t,i,a){var s=this.w,n=1,o=s.config.plotOptions[e].shadeIntensity,l=this.determineColor(e,t,i);s.globals.hasNegs||a?n=s.config.plotOptions[e].reverseNegativeShade?l.percent<0?l.percent/100*(1.25*o):(1-l.percent/100)*(1.25*o):l.percent<=0?1-(1+l.percent/100)*o:(1-l.percent/100)*o:(n=1-l.percent/100,"treemap"===e&&(n=(1-l.percent/100)*(1.25*o)));var c=l.color,h=new r;return s.config.plotOptions[e].enableShades&&(c="dark"===this.w.config.theme.mode?r.hexToRgba(h.shadeColor(-1*n,l.color),s.config.fill.opacity):r.hexToRgba(h.shadeColor(n,l.color),s.config.fill.opacity)),{color:c,colorProps:l}}},{key:"determineColor",value:function(e,t,i){var a=this.w,r=a.globals.series[t][i],s=a.config.plotOptions[e],n=s.colorScale.inverse?i:t;s.distributed&&"treemap"===a.config.chart.type&&(n=i);var o=a.globals.colors[n],l=null,c=Math.min.apply(Math,Ii(a.globals.series[t])),h=Math.max.apply(Math,Ii(a.globals.series[t]));s.distributed||"heatmap"!==e||(c=a.globals.minY,h=a.globals.maxY),void 0!==s.colorScale.min&&(c=s.colorScale.min<a.globals.minY?s.colorScale.min:a.globals.minY,h=s.colorScale.max>a.globals.maxY?s.colorScale.max:a.globals.maxY);var d=Math.abs(h)+Math.abs(c),u=100*r/(0===d?d-1e-6:d);return s.colorScale.ranges.length>0&&s.colorScale.ranges.map((function(e,t){if(r>=e.from&&r<=e.to){o=e.color,l=e.foreColor?e.foreColor:null,c=e.from,h=e.to;var i=Math.abs(h)+Math.abs(c);u=100*r/(0===i?i-1e-6:i)}})),{color:o,foreColor:l,percent:u}}},{key:"calculateDataLabels",value:function(e){var t=e.text,i=e.x,a=e.y,r=e.i,s=e.j,n=e.colorProps,o=e.fontSize,l=this.w.config.dataLabels,c=new g(this.ctx),h=new oe(this.ctx),d=null;if(l.enabled){d=c.group({class:"apexcharts-data-labels"});var u=l.offsetX,f=l.offsetY,p=i+u,x=a+parseFloat(l.style.fontSize)/3+f;h.plotDataLabelsText({x:p,y:x,text:t,i:r,j:s,color:n.foreColor,parent:d,fontSize:o,dataLabelsConfig:l})}return d}},{key:"addListeners",value:function(e){var t=new g(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))}}])&&zi(t.prototype,i),e}();function Yi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ri=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.xRatio=i.xRatio,this.yRatio=i.yRatio,this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.helpers=new Xi(t),this.rectRadius=this.w.config.plotOptions.heatmap.radius,this.strokeWidth=this.w.config.stroke.show?this.w.config.stroke.width:0}var t,i;return t=e,(i=[{key:"draw",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-heatmap"});a.attr("clip-path","url(#gridRectMask".concat(t.globals.cuid,")"));var s=t.globals.gridWidth/t.globals.dataPoints,n=t.globals.gridHeight/t.globals.series.length,o=0,c=!1;this.negRange=this.helpers.checkColorRange();var h=e.slice();t.config.yaxis[0].reversed&&(c=!0,h.reverse());for(var d=c?0:h.length-1;c?d<h.length:d>=0;c?d++:d--){var u=i.group({class:"apexcharts-series apexcharts-heatmap-series",seriesName:r.escapeString(t.globals.seriesNames[d]),rel:d+1,"data:realIndex":d});if(this.ctx.series.addCollapsedClassToSeries(u,d),t.config.chart.dropShadow.enabled){var f=t.config.chart.dropShadow;new l(this.ctx).dropShadow(u,f,d)}for(var p=0,x=t.config.plotOptions.heatmap.shadeIntensity,b=0;b<h[d].length;b++){var v=this.helpers.getShadeColor(t.config.chart.type,d,b,this.negRange),m=v.color,y=v.colorProps;"image"===t.config.fill.type&&(m=new te(this.ctx).fillPath({seriesNumber:d,dataPointIndex:b,opacity:t.globals.hasNegs?y.percent<0?1-(1+y.percent/100):x+y.percent/100:y.percent/100,patternID:r.randomId(),width:t.config.fill.image.width?t.config.fill.image.width:s,height:t.config.fill.image.height?t.config.fill.image.height:n}));var w=this.rectRadius,k=i.drawRect(p,o,s,n,w);if(k.attr({cx:p,cy:o}),k.node.classList.add("apexcharts-heatmap-rect"),u.add(k),k.attr({fill:m,i:d,index:d,j:b,val:e[d][b],"stroke-width":this.strokeWidth,stroke:t.config.plotOptions.heatmap.useFillColorAsStroke?m:t.globals.stroke.colors[0],color:m}),this.helpers.addListeners(k),t.config.chart.animations.enabled&&!t.globals.dataChanged){var A=1;t.globals.resized||(A=t.config.chart.animations.speed),this.animateHeatMap(k,p,o,s,n,A)}if(t.globals.dataChanged){var S=1;if(this.dynamicAnim.enabled&&t.globals.shouldAnimate){S=this.dynamicAnim.speed;var C=t.globals.previousPaths[d]&&t.globals.previousPaths[d][b]&&t.globals.previousPaths[d][b].color;C||(C="rgba(255, 255, 255, 0)"),this.animateHeatColor(k,r.isColorHex(C)?C:r.rgb2hex(C),r.isColorHex(m)?m:r.rgb2hex(m),S)}}var P=(0,t.config.dataLabels.formatter)(t.globals.series[d][b],{value:t.globals.series[d][b],seriesIndex:d,dataPointIndex:b,w:t}),L=this.helpers.calculateDataLabels({text:P,x:p+s/2,y:o+n/2,i:d,j:b,colorProps:y,series:h});null!==L&&u.add(L),p+=s}o+=n,a.add(u)}var O=t.globals.yAxisScale[0].result.slice();return t.config.yaxis[0].reversed?O.unshift(""):O.push(""),t.globals.yAxisScale[0].result=O,a}},{key:"animateHeatMap",value:function(e,t,i,a,r,s){var o=new n(this.ctx);o.animateRect(e,{x:t+a/2,y:i+r/2,width:0,height:0},{x:t,y:i,width:a,height:r},s,(function(){o.animationCompleted(e)}))}},{key:"animateHeatColor",value:function(e,t,i,a){e.attr({fill:t}).animate(a).attr({fill:i})}}])&&Yi(t.prototype,i),e}();function Di(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Fi=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"drawYAxisTexts",value:function(e,t,i,a){var r=this.w,s=r.config.yaxis[0],n=r.globals.yLabelFormatters[0];return new g(this.ctx).drawText({x:e+s.labels.offsetX,y:t+s.labels.offsetY,text:n(a,i),textAnchor:"middle",fontSize:s.labels.style.fontSize,fontFamily:s.labels.style.fontFamily,foreColor:Array.isArray(s.labels.style.colors)?s.labels.style.colors[i]:s.labels.style.colors})}}])&&Di(t.prototype,i),e}();function Hi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const Ni=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.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.animBeginArr=[0],this.animDur=0,this.donutDataLabels=this.w.config.plotOptions.pie.donut.labels,this.lineColorArr=void 0!==i.globals.stroke.colors?i.globals.stroke.colors:i.globals.colors,this.defaultSize=Math.min(i.globals.gridWidth,i.globals.gridHeight),this.centerY=this.defaultSize/2,this.centerX=i.globals.gridWidth/2,"radialBar"===i.config.chart.type?this.fullAngle=360:this.fullAngle=Math.abs(i.config.plotOptions.pie.endAngle-i.config.plotOptions.pie.startAngle),this.initialAngle=i.config.plotOptions.pie.startAngle%this.fullAngle,i.globals.radialSize=this.defaultSize/2.05-i.config.stroke.width-(i.config.chart.sparkline.enabled?0:i.config.chart.dropShadow.blur),this.donutSize=i.globals.radialSize*parseInt(i.config.plotOptions.pie.donut.size,10)/100;var a=i.config.plotOptions.pie.customScale,r=i.globals.gridWidth/2,s=i.globals.gridHeight/2;this.translateX=r-r*a,this.translateY=s-s*a,this.dataLabelsGroup=new g(this.ctx).group({class:"apexcharts-datalabels-group",transform:"translate(".concat(this.translateX,", ").concat(this.translateY,") scale(").concat(a,")")}),this.maxY=0,this.sliceLabels=[],this.sliceSizes=[],this.prevSectorAngleArr=[]}var t,i;return t=e,(i=[{key:"draw",value:function(e){var t=this,i=this.w,a=new g(this.ctx),s=a.group({class:"apexcharts-pie"});if(i.globals.noData)return s;for(var n=0,o=0;o<e.length;o++)n+=r.negToZero(e[o]);var l=[],c=a.group();0===n&&(n=1e-5),e.forEach((function(e){t.maxY=Math.max(t.maxY,e)})),i.config.yaxis[0].max&&(this.maxY=i.config.yaxis[0].max),"back"===i.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(s);for(var h=0;h<e.length;h++){var d=this.fullAngle*r.negToZero(e[h])/n;l.push(d),"polarArea"===this.chartType?(l[h]=this.fullAngle/e.length,this.sliceSizes.push(i.globals.radialSize*e[h]/this.maxY)):this.sliceSizes.push(i.globals.radialSize)}if(i.globals.dataChanged){for(var u,f=0,p=0;p<i.globals.previousPaths.length;p++)f+=r.negToZero(i.globals.previousPaths[p]);for(var x=0;x<i.globals.previousPaths.length;x++)u=this.fullAngle*r.negToZero(i.globals.previousPaths[x])/f,this.prevSectorAngleArr.push(u)}if(this.donutSize<0&&(this.donutSize=0),"donut"===this.chartType){var b=a.drawCircle(this.donutSize);b.attr({cx:this.centerX,cy:this.centerY,fill:i.config.plotOptions.pie.donut.background?i.config.plotOptions.pie.donut.background:"transparent"}),c.add(b)}var v=this.drawArcs(l,e);if(this.sliceLabels.forEach((function(e){v.add(e)})),c.attr({transform:"translate(".concat(this.translateX,", ").concat(this.translateY,") scale(").concat(i.config.plotOptions.pie.customScale,")")}),c.add(v),s.add(c),this.donutDataLabels.show){var m=this.renderInnerDataLabels(this.dataLabelsGroup,this.donutDataLabels,{hollowSize:this.donutSize,centerX:this.centerX,centerY:this.centerY,opacity:this.donutDataLabels.show});s.add(m)}return"front"===i.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(s),s}},{key:"drawArcs",value:function(e,t){var i=this.w,a=new l(this.ctx),s=new g(this.ctx),n=new te(this.ctx),o=s.group({class:"apexcharts-slices"}),c=this.initialAngle,h=this.initialAngle,d=this.initialAngle,u=this.initialAngle;this.strokeWidth=i.config.stroke.show?i.config.stroke.width:0;for(var f=0;f<e.length;f++){var p=s.group({class:"apexcharts-series apexcharts-pie-series",seriesName:r.escapeString(i.globals.seriesNames[f]),rel:f+1,"data:realIndex":f});o.add(p),h=u,d=(c=d)+e[f],u=h+this.prevSectorAngleArr[f];var x=d<c?this.fullAngle+d-c:d-c,b=n.fillPath({seriesNumber:f,size:this.sliceSizes[f],value:t[f]}),v=this.getChangedPath(h,u),m=s.drawPath({d:v,stroke:Array.isArray(this.lineColorArr)?this.lineColorArr[f]:this.lineColorArr,strokeWidth:0,fill:b,fillOpacity:i.config.fill.opacity,classes:"apexcharts-pie-area apexcharts-".concat(this.chartType.toLowerCase(),"-slice-").concat(f)});if(m.attr({index:0,j:f}),a.setSelectionFilter(m,0,f),i.config.chart.dropShadow.enabled){var y=i.config.chart.dropShadow;a.dropShadow(m,y,f)}this.addListeners(m,this.donutDataLabels),g.setAttrs(m.node,{"data:angle":x,"data:startAngle":c,"data:strokeWidth":this.strokeWidth,"data:value":t[f]});var w={x:0,y:0};"pie"===this.chartType||"polarArea"===this.chartType?w=r.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize/1.25+i.config.plotOptions.pie.dataLabels.offset,(c+x/2)%this.fullAngle):"donut"===this.chartType&&(w=r.polarToCartesian(this.centerX,this.centerY,(i.globals.radialSize+this.donutSize)/2+i.config.plotOptions.pie.dataLabels.offset,(c+x/2)%this.fullAngle)),p.add(m);var k=0;if(!this.initialAnim||i.globals.resized||i.globals.dataChanged?this.animBeginArr.push(0):(0==(k=x/this.fullAngle*i.config.chart.animations.speed)&&(k=1),this.animDur=k+this.animDur,this.animBeginArr.push(this.animDur)),this.dynamicAnim&&i.globals.dataChanged?this.animatePaths(m,{size:this.sliceSizes[f],endAngle:d,startAngle:c,prevStartAngle:h,prevEndAngle:u,animateStartingPos:!0,i:f,animBeginArr:this.animBeginArr,shouldSetPrevPaths:!0,dur:i.config.chart.animations.dynamicAnimation.speed}):this.animatePaths(m,{size:this.sliceSizes[f],endAngle:d,startAngle:c,i:f,totalItems:e.length-1,animBeginArr:this.animBeginArr,dur:k}),i.config.plotOptions.pie.expandOnClick&&"polarArea"!==this.chartType&&m.node.addEventListener("mouseup",this.pieClicked.bind(this,f)),void 0!==i.globals.selectedDataPoints[0]&&i.globals.selectedDataPoints[0].indexOf(f)>-1&&this.pieClicked(f),i.config.dataLabels.enabled){var A=w.x,S=w.y,C=100*x/this.fullAngle+"%";if(0!==x&&i.config.plotOptions.pie.dataLabels.minAngleToShowLabel<e[f]){var P=i.config.dataLabels.formatter;void 0!==P&&(C=P(i.globals.seriesPercent[f][0],{seriesIndex:f,w:i}));var L=i.globals.dataLabels.style.colors[f],O=s.group({class:"apexcharts-datalabels"}),M=s.drawText({x:A,y:S,text:C,textAnchor:"middle",fontSize:i.config.dataLabels.style.fontSize,fontFamily:i.config.dataLabels.style.fontFamily,fontWeight:i.config.dataLabels.style.fontWeight,foreColor:L});if(O.add(M),i.config.dataLabels.dropShadow.enabled){var T=i.config.dataLabels.dropShadow;a.dropShadow(M,T)}M.node.classList.add("apexcharts-pie-label"),i.config.chart.animations.animate&&!1===i.globals.resized&&(M.node.classList.add("apexcharts-pie-label-delay"),M.node.style.animationDelay=i.config.chart.animations.speed/940+"s"),this.sliceLabels.push(O)}}}return o}},{key:"addListeners",value:function(e,t){var i=new g(this.ctx);e.node.addEventListener("mouseenter",i.pathMouseEnter.bind(this,e)),e.node.addEventListener("mouseleave",i.pathMouseLeave.bind(this,e)),e.node.addEventListener("mouseleave",this.revertDataLabelsInner.bind(this,e.node,t)),e.node.addEventListener("mousedown",i.pathMouseDown.bind(this,e)),this.donutDataLabels.total.showAlways||(e.node.addEventListener("mouseenter",this.printDataLabelsInner.bind(this,e.node,t)),e.node.addEventListener("mousedown",this.printDataLabelsInner.bind(this,e.node,t)))}},{key:"animatePaths",value:function(e,t){var i=this.w,a=t.endAngle<t.startAngle?this.fullAngle+t.endAngle-t.startAngle:t.endAngle-t.startAngle,r=a,s=t.startAngle,n=t.startAngle;void 0!==t.prevStartAngle&&void 0!==t.prevEndAngle&&(s=t.prevEndAngle,r=t.prevEndAngle<t.prevStartAngle?this.fullAngle+t.prevEndAngle-t.prevStartAngle:t.prevEndAngle-t.prevStartAngle),t.i===i.config.series.length-1&&(a+n>this.fullAngle?t.endAngle=t.endAngle-(a+n):a+n<this.fullAngle&&(t.endAngle=t.endAngle+(this.fullAngle-(a+n)))),a===this.fullAngle&&(a=this.fullAngle-.01),this.animateArc(e,s,n,a,r,t)}},{key:"animateArc",value:function(e,t,i,a,r,s){var o,l=this,c=this.w,h=new n(this.ctx),d=s.size;(isNaN(t)||isNaN(r))&&(t=i,r=a,s.dur=0);var u=a,g=i,f=t<i?this.fullAngle+t-i:t-i;c.globals.dataChanged&&s.shouldSetPrevPaths&&s.prevEndAngle&&(o=l.getPiePath({me:l,startAngle:s.prevStartAngle,angle:s.prevEndAngle<s.prevStartAngle?this.fullAngle+s.prevEndAngle-s.prevStartAngle:s.prevEndAngle-s.prevStartAngle,size:d}),e.attr({d:o})),0!==s.dur?e.animate(s.dur,c.globals.easing,s.animBeginArr[s.i]).afterAll((function(){"pie"!==l.chartType&&"donut"!==l.chartType&&"polarArea"!==l.chartType||this.animate(c.config.chart.animations.dynamicAnimation.speed).attr({"stroke-width":l.strokeWidth}),s.i===c.config.series.length-1&&h.animationCompleted(e)})).during((function(n){u=f+(a-f)*n,s.animateStartingPos&&(u=r+(a-r)*n,g=t-r+(i-(t-r))*n),o=l.getPiePath({me:l,startAngle:g,angle:u,size:d}),e.node.setAttribute("data:pathOrig",o),e.attr({d:o})})):(o=l.getPiePath({me:l,startAngle:g,angle:a,size:d}),s.isTrack||(c.globals.animationEnded=!0),e.node.setAttribute("data:pathOrig",o),e.attr({d:o,"stroke-width":l.strokeWidth}))}},{key:"pieClicked",value:function(e){var t,i=this.w,a=this,r=a.sliceSizes[e]+(i.config.plotOptions.pie.expandOnClick?4:0),s=i.globals.dom.Paper.select(".apexcharts-".concat(a.chartType.toLowerCase(),"-slice-").concat(e)).members[0];if("true"!==s.attr("data:pieClicked")){var n=i.globals.dom.baseEl.getElementsByClassName("apexcharts-pie-area");Array.prototype.forEach.call(n,(function(e){e.setAttribute("data:pieClicked","false");var t=e.getAttribute("data:pathOrig");t&&e.setAttribute("d",t)})),i.globals.capturedDataPointIndex=e,s.attr("data:pieClicked","true");var o=parseInt(s.attr("data:startAngle"),10),l=parseInt(s.attr("data:angle"),10);t=a.getPiePath({me:a,startAngle:o,angle:l,size:r}),360!==l&&s.plot(t)}else{s.attr({"data:pieClicked":"false"}),this.revertDataLabelsInner(s.node,this.donutDataLabels);var c=s.attr("data:pathOrig");s.attr({d:c})}}},{key:"getChangedPath",value:function(e,t){var i="";return this.dynamicAnim&&this.w.globals.dataChanged&&(i=this.getPiePath({me:this,startAngle:e,angle:t-e,size:this.size})),i}},{key:"getPiePath",value:function(e){var t,i=e.me,a=e.startAngle,s=e.angle,n=e.size,o=new g(this.ctx),l=a,c=Math.PI*(l-90)/180,h=s+a;Math.ceil(h)>=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle&&(h=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle-.01),Math.ceil(h)>this.fullAngle&&(h-=this.fullAngle);var d=Math.PI*(h-90)/180,u=i.centerX+n*Math.cos(c),f=i.centerY+n*Math.sin(c),p=i.centerX+n*Math.cos(d),x=i.centerY+n*Math.sin(d),b=r.polarToCartesian(i.centerX,i.centerY,i.donutSize,h),v=r.polarToCartesian(i.centerX,i.centerY,i.donutSize,l),m=s>180?1:0,y=["M",u,f,"A",n,n,0,m,1,p,x];return t="donut"===i.chartType?[].concat(y,["L",b.x,b.y,"A",i.donutSize,i.donutSize,0,m,0,v.x,v.y,"L",u,f,"z"]).join(" "):"pie"===i.chartType||"polarArea"===i.chartType?[].concat(y,["L",i.centerX,i.centerY,"L",u,f]).join(" "):[].concat(y).join(" "),o.roundPathCorners(t,2*this.strokeWidth)}},{key:"drawPolarElements",value:function(e){var t=this.w,i=new ke(this.ctx),a=new g(this.ctx),r=new Fi(this.ctx),s=a.group(),n=a.group(),o=i.niceScale(0,Math.ceil(this.maxY),0),l=o.result.reverse(),c=o.result.length;this.maxY=o.niceMax;for(var h=t.globals.radialSize,d=h/(c-1),u=0;u<c-1;u++){var f=a.drawCircle(h);if(f.attr({cx:this.centerX,cy:this.centerY,fill:"none","stroke-width":t.config.plotOptions.polarArea.rings.strokeWidth,stroke:t.config.plotOptions.polarArea.rings.strokeColor}),t.config.yaxis[0].show){var p=r.drawYAxisTexts(this.centerX,this.centerY-h+parseInt(t.config.yaxis[0].labels.style.fontSize,10)/2,u,l[u]);n.add(p)}s.add(f),h-=d}this.drawSpokes(e),e.add(s),e.add(n)}},{key:"renderInnerDataLabels",value:function(e,t,i){var a=this.w,r=new g(this.ctx),s=t.total.show;e.node.innerHTML="",e.node.style.opacity=i.opacity;var n,o,l=i.centerX,c=i.centerY;n=void 0===t.name.color?a.globals.colors[0]:t.name.color;var h=t.name.fontSize,d=t.name.fontFamily,u=t.name.fontWeight;o=void 0===t.value.color?a.config.chart.foreColor:t.value.color;var f=t.value.formatter,p="",x="";if(s?(n=t.total.color,h=t.total.fontSize,d=t.total.fontFamily,u=t.total.fontWeight,x=t.total.label,p=t.total.formatter(a)):1===a.globals.series.length&&(p=f(a.globals.series[0],a),x=a.globals.seriesNames[0]),x&&(x=t.name.formatter(x,t.total.show,a)),t.name.show){var b=r.drawText({x:l,y:c+parseFloat(t.name.offsetY),text:x,textAnchor:"middle",foreColor:n,fontSize:h,fontWeight:u,fontFamily:d});b.node.classList.add("apexcharts-datalabel-label"),e.add(b)}if(t.value.show){var v=t.name.show?parseFloat(t.value.offsetY)+16:t.value.offsetY,m=r.drawText({x:l,y:c+v,text:p,textAnchor:"middle",foreColor:o,fontWeight:t.value.fontWeight,fontSize:t.value.fontSize,fontFamily:t.value.fontFamily});m.node.classList.add("apexcharts-datalabel-value"),e.add(m)}return e}},{key:"printInnerLabels",value:function(e,t,i,a){var r,s=this.w;a?r=void 0===e.name.color?s.globals.colors[parseInt(a.parentNode.getAttribute("rel"),10)-1]:e.name.color:s.globals.series.length>1&&e.total.show&&(r=e.total.color);var n=s.globals.dom.baseEl.querySelector(".apexcharts-datalabel-label"),o=s.globals.dom.baseEl.querySelector(".apexcharts-datalabel-value");i=(0,e.value.formatter)(i,s),a||"function"!=typeof e.total.formatter||(i=e.total.formatter(s));var l=t===e.total.label;t=e.name.formatter(t,l,s),null!==n&&(n.textContent=t),null!==o&&(o.textContent=i),null!==n&&(n.style.fill=r)}},{key:"printDataLabelsInner",value:function(e,t){var i=this.w,a=e.getAttribute("data:value"),r=i.globals.seriesNames[parseInt(e.parentNode.getAttribute("rel"),10)-1];i.globals.series.length>1&&this.printInnerLabels(t,r,a,e);var s=i.globals.dom.baseEl.querySelector(".apexcharts-datalabels-group");null!==s&&(s.style.opacity=1)}},{key:"drawSpokes",value:function(e){var t=this,i=this.w,a=new g(this.ctx),s=i.config.plotOptions.polarArea.spokes;if(0!==s.strokeWidth){for(var n=[],o=360/i.globals.series.length,l=0;l<i.globals.series.length;l++)n.push(r.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize,i.config.plotOptions.pie.startAngle+o*l));n.forEach((function(i,r){var n=a.drawLine(i.x,i.y,t.centerX,t.centerY,Array.isArray(s.connectorColors)?s.connectorColors[r]:s.connectorColors);e.add(n)}))}}},{key:"revertDataLabelsInner",value:function(){var e=this.w;if(this.donutDataLabels.show){var t=e.globals.dom.Paper.select(".apexcharts-datalabels-group").members[0],i=this.renderInnerDataLabels(t,this.donutDataLabels,{hollowSize:this.donutSize,centerX:this.centerX,centerY:this.centerY,opacity:this.donutDataLabels.show});e.globals.dom.Paper.select(".apexcharts-radialbar, .apexcharts-pie").members[0].add(i)}}}])&&Hi(t.prototype,i),e}();function Wi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Bi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Wi(Object(i),!0).forEach((function(t){ji(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Wi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ji(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Gi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const Vi=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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 i=this.w;this.graphics=new g(this.ctx),this.lineColorArr=void 0!==i.globals.stroke.colors?i.globals.stroke.colors:i.globals.colors,this.defaultSize=i.globals.svgHeight<i.globals.svgWidth?i.globals.gridHeight+1.5*i.globals.goldenPadding:i.globals.gridWidth,this.isLog=i.config.yaxis[0].logarithmic,this.logBase=i.config.yaxis[0].logBase,this.coreUtils=new p(this.ctx),this.maxValue=this.isLog?this.coreUtils.getLogVal(this.logBase,i.globals.maxY,0):i.globals.maxY,this.minValue=this.isLog?this.coreUtils.getLogVal(this.logBase,this.w.globals.minY,0):i.globals.minY,this.polygons=i.config.plotOptions.radar.polygons,this.strokeWidth=i.config.stroke.show?i.config.stroke.width:0,this.size=this.defaultSize/2.1-this.strokeWidth-i.config.chart.dropShadow.blur,i.config.xaxis.labels.show&&(this.size=this.size-i.globals.xAxisLabelsWidth/1.75),void 0!==i.config.plotOptions.radar.size&&(this.size=i.config.plotOptions.radar.size),this.dataRadiusOfPercent=[],this.dataRadius=[],this.angleArr=[],this.yaxisLabelsTextsPos=[]}var t,i;return t=e,i=[{key:"draw",value:function(e){var t=this,i=this.w,a=new te(this.ctx),s=[],n=new oe(this.ctx);e.length&&(this.dataPointsLen=e[i.globals.maxValsInArrayIndex].length),this.disAngle=2*Math.PI/this.dataPointsLen;var o=i.globals.gridWidth/2,c=i.globals.gridHeight/2,h=o+i.config.plotOptions.radar.offsetX,d=c+i.config.plotOptions.radar.offsetY,u=this.graphics.group({class:"apexcharts-radar-series apexcharts-plot-series",transform:"translate(".concat(h||0,", ").concat(d||0,")")}),g=[],f=null,p=null;if(this.yaxisLabels=this.graphics.group({class:"apexcharts-yaxis"}),e.forEach((function(e,o){var c=e.length===i.globals.dataPoints,h=t.graphics.group().attr({class:"apexcharts-series","data:longestSeries":c,seriesName:r.escapeString(i.globals.seriesNames[o]),rel:o+1,"data:realIndex":o});t.dataRadiusOfPercent[o]=[],t.dataRadius[o]=[],t.angleArr[o]=[],e.forEach((function(e,i){var a=Math.abs(t.maxValue-t.minValue);e-=t.minValue,t.isLog&&(e=t.coreUtils.getLogVal(t.logBase,e,0)),t.dataRadiusOfPercent[o][i]=e/a,t.dataRadius[o][i]=t.dataRadiusOfPercent[o][i]*t.size,t.angleArr[o][i]=i*t.disAngle})),g=t.getDataPointsPos(t.dataRadius[o],t.angleArr[o]);var d=t.createPaths(g,{x:0,y:0});f=t.graphics.group({class:"apexcharts-series-markers-wrap apexcharts-element-hidden"}),p=t.graphics.group({class:"apexcharts-datalabels","data:realIndex":o}),i.globals.delayedElements.push({el:f.node,index:o});var u={i:o,realIndex:o,animationDelay:o,initialSpeed:i.config.chart.animations.speed,dataChangeSpeed:i.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-radar",shouldClipToGrid:!1,bindEventsOnPaths:!1,stroke:i.globals.stroke.colors[o],strokeLineCap:i.config.stroke.lineCap},x=null;i.globals.previousPaths.length>0&&(x=t.getPreviousPath(o));for(var b=0;b<d.linePathsTo.length;b++){var v=t.graphics.renderPaths(Bi(Bi({},u),{},{pathFrom:null===x?d.linePathsFrom[b]:x,pathTo:d.linePathsTo[b],strokeWidth:Array.isArray(t.strokeWidth)?t.strokeWidth[o]:t.strokeWidth,fill:"none",drawShadow:!1}));h.add(v);var m=a.fillPath({seriesNumber:o}),y=t.graphics.renderPaths(Bi(Bi({},u),{},{pathFrom:null===x?d.areaPathsFrom[b]:x,pathTo:d.areaPathsTo[b],strokeWidth:0,fill:m,drawShadow:!1}));if(i.config.chart.dropShadow.enabled){var w=new l(t.ctx),k=i.config.chart.dropShadow;w.dropShadow(y,Object.assign({},k,{noUserSpaceOnUse:!0}),o)}h.add(y)}e.forEach((function(e,a){var r=new ae(t.ctx).getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:o,dataPointIndex:a}),s=t.graphics.drawMarker(g[a].x,g[a].y,r);s.attr("rel",a),s.attr("j",a),s.attr("index",o),s.node.setAttribute("default-marker-size",r.pSize);var l=t.graphics.group({class:"apexcharts-series-markers"});l&&l.add(s),f.add(l),h.add(f);var c=i.config.dataLabels;if(c.enabled){var d=c.formatter(i.globals.series[o][a],{seriesIndex:o,dataPointIndex:a,w:i});n.plotDataLabelsText({x:g[a].x,y:g[a].y,text:d,textAnchor:"middle",i:o,j:o,parent:p,offsetCorrection:!1,dataLabelsConfig:Bi({},c)})}h.add(p)})),s.push(h)})),this.drawPolygons({parent:u}),i.config.xaxis.labels.show){var x=this.drawXAxisTexts();u.add(x)}return s.forEach((function(e){u.add(e)})),u.add(this.yaxisLabels),u}},{key:"drawPolygons",value:function(e){for(var t=this,i=this.w,a=e.parent,s=new Fi(this.ctx),n=i.globals.yAxisScale[0].result.reverse(),o=n.length,l=[],c=this.size/(o-1),h=0;h<o;h++)l[h]=c*h;l.reverse();var d=[],u=[];l.forEach((function(e,i){var a=r.getPolygonPos(e,t.dataPointsLen),s="";a.forEach((function(e,a){if(0===i){var r=t.graphics.drawLine(e.x,e.y,0,0,Array.isArray(t.polygons.connectorColors)?t.polygons.connectorColors[a]:t.polygons.connectorColors);u.push(r)}0===a&&t.yaxisLabelsTextsPos.push({x:e.x,y:e.y}),s+=e.x+","+e.y+" "})),d.push(s)})),d.forEach((function(e,r){var s=t.polygons.strokeColors,n=t.polygons.strokeWidth,o=t.graphics.drawPolygon(e,Array.isArray(s)?s[r]:s,Array.isArray(n)?n[r]:n,i.globals.radarPolygons.fill.colors[r]);a.add(o)})),u.forEach((function(e){a.add(e)})),i.config.yaxis[0].show&&this.yaxisLabelsTextsPos.forEach((function(e,i){var a=s.drawYAxisTexts(e.x,e.y,i,n[i]);t.yaxisLabels.add(a)}))}},{key:"drawXAxisTexts",value:function(){var e=this,t=this.w,i=t.config.xaxis.labels,a=this.graphics.group({class:"apexcharts-xaxis"}),s=r.getPolygonPos(this.size,this.dataPointsLen);return t.globals.labels.forEach((function(r,n){var o=t.config.xaxis.labels.formatter,l=new oe(e.ctx);if(s[n]){var c=e.getTextPos(s[n],e.size),h=o(r,{seriesIndex:-1,dataPointIndex:n,w:t});l.plotDataLabelsText({x:c.newX,y:c.newY,text:h,textAnchor:c.textAnchor,i:n,j:n,parent:a,className:"apexcharts-xaxis-label",color:Array.isArray(i.style.colors)&&i.style.colors[n]?i.style.colors[n]:"#a8a8a8",dataLabelsConfig:Bi({textAnchor:c.textAnchor,dropShadow:{enabled:!1}},i),offsetCorrection:!1}).on("click",(function(i){if("function"==typeof t.config.chart.events.xAxisLabelClick){var a=Object.assign({},t,{labelIndex:n});t.config.chart.events.xAxisLabelClick(i,e.ctx,a)}}))}})),a}},{key:"createPaths",value:function(e,t){var i=this,a=[],r=[],s=[],n=[];if(e.length){r=[this.graphics.move(t.x,t.y)],n=[this.graphics.move(t.x,t.y)];var o=this.graphics.move(e[0].x,e[0].y),l=this.graphics.move(e[0].x,e[0].y);e.forEach((function(t,a){o+=i.graphics.line(t.x,t.y),l+=i.graphics.line(t.x,t.y),a===e.length-1&&(o+="Z",l+="Z")})),a.push(o),s.push(l)}return{linePathsFrom:r,linePathsTo:a,areaPathsFrom:n,areaPathsTo:s}}},{key:"getTextPos",value:function(e,t){var i="middle",a=e.x,r=e.y;return Math.abs(e.x)>=10?e.x>0?(i="start",a+=10):e.x<0&&(i="end",a-=10):i="middle",Math.abs(e.y)>=t-10&&(e.y<0?r-=10:e.y>0&&(r+=10)),{textAnchor:i,newX:a,newY:r}}},{key:"getPreviousPath",value:function(e){for(var t=this.w,i=null,a=0;a<t.globals.previousPaths.length;a++){var r=t.globals.previousPaths[a];r.paths.length>0&&parseInt(r.realIndex,10)===parseInt(e,10)&&void 0!==t.globals.previousPaths[a].paths[0]&&(i=t.globals.previousPaths[a].paths[0].d)}return i}},{key:"getDataPointsPos",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.dataPointsLen;e=e||[],t=t||[];for(var a=[],r=0;r<i;r++){var s={};s.x=e[r]*Math.sin(t[r]),s.y=-e[r]*Math.cos(t[r]),a.push(s)}return a}}],i&&Gi(t.prototype,i),e}();function _i(e){return _i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_i(e)}function Ui(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function qi(e,t){return qi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},qi(e,t)}function Zi(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $i(e){return $i=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},$i(e)}const Ji=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&qi(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=$i(a);if(s){var i=$i(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===_i(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Zi(e)}(this,e)});function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=n.call(this,e)).ctx=e,t.w=e.w,t.animBeginArr=[0],t.animDur=0;var i=t.w;return t.startAngle=i.config.plotOptions.radialBar.startAngle,t.endAngle=i.config.plotOptions.radialBar.endAngle,t.totalAngle=Math.abs(i.config.plotOptions.radialBar.endAngle-i.config.plotOptions.radialBar.startAngle),t.trackStartAngle=i.config.plotOptions.radialBar.track.startAngle,t.trackEndAngle=i.config.plotOptions.radialBar.track.endAngle,t.barLabels=t.w.config.plotOptions.radialBar.barLabels,t.donutDataLabels=t.w.config.plotOptions.radialBar.dataLabels,t.radialDataLabels=t.donutDataLabels,t.trackStartAngle||(t.trackStartAngle=t.startAngle),t.trackEndAngle||(t.trackEndAngle=t.endAngle),360===t.endAngle&&(t.endAngle=359.99),t.margin=parseInt(i.config.plotOptions.radialBar.track.margin,10),t.onBarLabelClick=t.onBarLabelClick.bind(Zi(t)),t}return t=o,(i=[{key:"draw",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-radialbar"});if(t.globals.noData)return a;var r=i.group(),s=this.defaultSize/2,n=t.globals.gridWidth/2,o=this.defaultSize/2.05;t.config.chart.sparkline.enabled||(o=o-t.config.stroke.width-t.config.chart.dropShadow.blur);var l=t.globals.fill.colors;if(t.config.plotOptions.radialBar.track.show){var c=this.drawTracks({size:o,centerX:n,centerY:s,colorArr:l,series:e});r.add(c)}var h=this.drawArcs({size:o,centerX:n,centerY:s,colorArr:l,series:e}),d=360;t.config.plotOptions.radialBar.startAngle<0&&(d=this.totalAngle);var u=(360-d)/360;if(t.globals.radialSize=o-o*u,this.radialDataLabels.value.show){var f=Math.max(this.radialDataLabels.value.offsetY,this.radialDataLabels.name.offsetY);t.globals.radialSize+=f*u}return r.add(h.g),"front"===t.config.plotOptions.radialBar.hollow.position&&(h.g.add(h.elHollow),h.dataLabels&&h.g.add(h.dataLabels)),a.add(r),a}},{key:"drawTracks",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-tracks"}),r=new l(this.ctx),s=new te(this.ctx),n=this.getStrokeWidth(e);e.size=e.size-n/2;for(var o=0;o<e.series.length;o++){var c=i.group({class:"apexcharts-radialbar-track apexcharts-track"});a.add(c),c.attr({rel:o+1}),e.size=e.size-n-this.margin;var h=t.config.plotOptions.radialBar.track,d=s.fillPath({seriesNumber:0,size:e.size,fillColors:Array.isArray(h.background)?h.background[o]:h.background,solid:!0}),u=this.trackStartAngle,f=this.trackEndAngle;Math.abs(f)+Math.abs(u)>=360&&(f=360-Math.abs(this.startAngle)-.1);var p=i.drawPath({d:"",stroke:d,strokeWidth:n*parseInt(h.strokeWidth,10)/100,fill:"none",strokeOpacity:h.opacity,classes:"apexcharts-radialbar-area"});if(h.dropShadow.enabled){var x=h.dropShadow;r.dropShadow(p,x)}c.add(p),p.attr("id","apexcharts-radialbarTrack-"+o),this.animatePaths(p,{centerX:e.centerX,centerY:e.centerY,endAngle:f,startAngle:u,size:e.size,i:o,totalItems:2,animBeginArr:0,dur:0,isTrack:!0,easing:t.globals.easing})}return a}},{key:"drawArcs",value:function(e){var t=this.w,i=new g(this.ctx),a=new te(this.ctx),s=new l(this.ctx),n=i.group(),o=this.getStrokeWidth(e);e.size=e.size-o/2;var c=t.config.plotOptions.radialBar.hollow.background,h=e.size-o*e.series.length-this.margin*e.series.length-o*parseInt(t.config.plotOptions.radialBar.track.strokeWidth,10)/100/2,d=h-t.config.plotOptions.radialBar.hollow.margin;void 0!==t.config.plotOptions.radialBar.hollow.image&&(c=this.drawHollowImage(e,n,h,c));var u=this.drawHollow({size:d,centerX:e.centerX,centerY:e.centerY,fill:c||"transparent"});if(t.config.plotOptions.radialBar.hollow.dropShadow.enabled){var f=t.config.plotOptions.radialBar.hollow.dropShadow;s.dropShadow(u,f)}var p=1;!this.radialDataLabels.total.show&&t.globals.series.length>1&&(p=0);var x=null;if(this.radialDataLabels.show){var b=t.globals.dom.Paper.select(".apexcharts-datalabels-group").members[0];x=this.renderInnerDataLabels(b,this.radialDataLabels,{hollowSize:h,centerX:e.centerX,centerY:e.centerY,opacity:p})}"back"===t.config.plotOptions.radialBar.hollow.position&&(n.add(u),x&&n.add(x));var v=!1;t.config.plotOptions.radialBar.inverseOrder&&(v=!0);for(var m=v?e.series.length-1:0;v?m>=0:m<e.series.length;v?m--:m++){var y=i.group({class:"apexcharts-series apexcharts-radial-series",seriesName:r.escapeString(t.globals.seriesNames[m])});n.add(y),y.attr({rel:m+1,"data:realIndex":m}),this.ctx.series.addCollapsedClassToSeries(y,m),e.size=e.size-o-this.margin;var w=a.fillPath({seriesNumber:m,size:e.size,value:e.series[m]}),k=this.startAngle,A=void 0,S=r.negToZero(e.series[m]>100?100:e.series[m])/100,C=Math.round(this.totalAngle*S)+this.startAngle,P=void 0;t.globals.dataChanged&&(A=this.startAngle,P=Math.round(this.totalAngle*r.negToZero(t.globals.previousPaths[m])/100)+A),Math.abs(C)+Math.abs(k)>=360&&(C-=.01),Math.abs(P)+Math.abs(A)>=360&&(P-=.01);var L=C-k,O=Array.isArray(t.config.stroke.dashArray)?t.config.stroke.dashArray[m]:t.config.stroke.dashArray,M=i.drawPath({d:"",stroke:w,strokeWidth:o,fill:"none",fillOpacity:t.config.fill.opacity,classes:"apexcharts-radialbar-area apexcharts-radialbar-slice-"+m,strokeDashArray:O});if(g.setAttrs(M.node,{"data:angle":L,"data:value":e.series[m]}),t.config.chart.dropShadow.enabled){var T=t.config.chart.dropShadow;s.dropShadow(M,T,m)}if(s.setSelectionFilter(M,0,m),this.addListeners(M,this.radialDataLabels),y.add(M),M.attr({index:0,j:m}),this.barLabels.enabled){var I=r.polarToCartesian(e.centerX,e.centerY,e.size,k),E=this.barLabels.formatter(t.globals.seriesNames[m],{seriesIndex:m,w:t}),z=["apexcharts-radialbar-label"];this.barLabels.onClick||z.push("apexcharts-no-click");var X=this.barLabels.useSeriesColors?t.globals.colors[m]:t.config.chart.foreColor;X||(X=t.config.chart.foreColor);var Y=I.x-this.barLabels.margin,R=I.y,D=i.drawText({x:Y,y:R,text:E,textAnchor:"end",dominantBaseline:"middle",fontFamily:this.barLabels.fontFamily,fontWeight:this.barLabels.fontWeight,fontSize:this.barLabels.fontSize,foreColor:X,cssClass:z.join(" ")});D.on("click",this.onBarLabelClick),D.attr({rel:m+1}),0!==k&&D.attr({"transform-origin":"".concat(Y," ").concat(R),transform:"rotate(".concat(k," 0 0)")}),y.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(M,{centerX:e.centerX,centerY:e.centerY,endAngle:C,startAngle:k,prevEndAngle:P,prevStartAngle:A,size:e.size,i:m,totalItems:2,animBeginArr:this.animBeginArr,dur:F,shouldSetPrevPaths:!0,easing:t.globals.easing})}return{g:n,elHollow:u,dataLabels:x}}},{key:"drawHollow",value:function(e){var t=new g(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,i,a){var s=this.w,n=new te(this.ctx),o=r.randomId(),l=s.config.plotOptions.radialBar.hollow.image;if(s.config.plotOptions.radialBar.hollow.imageClipped)n.clippedImgArea({width:i,height:i,image:l,patternID:"pattern".concat(s.globals.cuid).concat(o)}),a="url(#pattern".concat(s.globals.cuid).concat(o,")");else{var c=s.config.plotOptions.radialBar.hollow.imageWidth,h=s.config.plotOptions.radialBar.hollow.imageHeight;if(void 0===c&&void 0===h){var d=s.globals.dom.Paper.image(l).loaded((function(t){this.move(e.centerX-t.width/2+s.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-t.height/2+s.config.plotOptions.radialBar.hollow.imageOffsetY)}));t.add(d)}else{var u=s.globals.dom.Paper.image(l).loaded((function(t){this.move(e.centerX-c/2+s.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-h/2+s.config.plotOptions.radialBar.hollow.imageOffsetY),this.size(c,h)}));t.add(u)}}return a}},{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,i=this.barLabels.onClick,a=this.w;i&&i(a.globals.seriesNames[t],{w:a,seriesIndex:t})}}])&&Ui(t.prototype,i),o}(Ni);function Qi(e){return Qi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Qi(e)}function Ki(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ea(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ki(Object(i),!0).forEach((function(t){ta(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ki(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ta(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ia(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function aa(e,t){return aa=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},aa(e,t)}function ra(e){return ra=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},ra(e)}const sa=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&aa(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=ra(a);if(s){var i=ra(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Qi(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n.apply(this,arguments)}return t=o,(i=[{key:"draw",value:function(e,t){var i=this.w,a=new g(this.ctx);this.rangeBarOptions=this.w.config.plotOptions.rangeBar,this.series=e,this.seriesRangeStart=i.globals.seriesRangeStart,this.seriesRangeEnd=i.globals.seriesRangeEnd,this.barHelpers.initVariables(e);for(var s=a.group({class:"apexcharts-rangebar-series apexcharts-plot-series"}),n=0;n<e.length;n++){var o,l,c,h,d=void 0,u=void 0,f=i.globals.comboCharts?t[n]:n,p=this.barHelpers.getGroupIndex(f).columnGroupIndex,x=a.group({class:"apexcharts-series",seriesName:r.escapeString(i.globals.seriesNames[f]),rel:n+1,"data:realIndex":f});this.ctx.series.addCollapsedClassToSeries(x,f),e[n].length>0&&(this.visibleI=this.visibleI+1);var b=0,v=0,m=0;this.yRatio.length>1&&(this.yaxisIndex=i.globals.seriesYAxisReverseMap[f][0],m=f);var y=this.barHelpers.initialPositions();u=y.y,h=y.zeroW,d=y.x,v=y.barWidth,b=y.barHeight,o=y.xDivision,l=y.yDivision,c=y.zeroH;for(var w=a.group({class:"apexcharts-datalabels","data:realIndex":f}),k=a.group({class:"apexcharts-rangebar-goals-markers"}),A=0;A<i.globals.dataPoints;A++){var S=this.barHelpers.getStrokeWidth(n,A,f),C=this.seriesRangeStart[n][A],P=this.seriesRangeEnd[n][A],L=null,O=null,M=null,T={x:d,y:u,strokeWidth:S,elSeries:x},I=this.seriesLen;if(i.config.plotOptions.bar.rangeBarGroupRows&&(I=1),void 0===i.config.series[n].data[A])break;if(this.isHorizontal){M=u+b*this.visibleI;var E=(l-b*I)/2;if(i.config.series[n].data[A].x){var z=this.detectOverlappingBars({i:n,j:A,barYPosition:M,srty:E,barHeight:b,yDivision:l,initPositions:y});b=z.barHeight,M=z.barYPosition}v=(L=this.drawRangeBarPaths(ea({indexes:{i:n,j:A,realIndex:f},barHeight:b,barYPosition:M,zeroW:h,yDivision:l,y1:C,y2:P},T))).barWidth}else{i.globals.isXNumeric&&(d=(i.globals.seriesX[n][A]-i.globals.minX)/this.xRatio-v/2),O=d+v*this.visibleI;var X=(o-v*I)/2;if(i.config.series[n].data[A].x){var Y=this.detectOverlappingBars({i:n,j:A,barXPosition:O,srtx:X,barWidth:v,xDivision:o,initPositions:y});v=Y.barWidth,O=Y.barXPosition}b=(L=this.drawRangeColumnPaths(ea({indexes:{i:n,j:A,realIndex:f,translationsIndex:m},barWidth:v,barXPosition:O,zeroH:c,xDivision:o},T))).barHeight}var R=this.barHelpers.drawGoalLine({barXPosition:L.barXPosition,barYPosition:M,goalX:L.goalX,goalY:L.goalY,barHeight:b,barWidth:v});R&&k.add(R),u=L.y,d=L.x;var D=this.barHelpers.getPathFillColor(e,n,A,f),F=i.globals.stroke.colors[f];this.renderSeries({realIndex:f,pathFill:D,lineFill:F,j:A,i:n,x:d,y:u,y1:C,y2:P,pathFrom:L.pathFrom,pathTo:L.pathTo,strokeWidth:S,elSeries:x,series:e,barHeight:b,barWidth:v,barXPosition:O,barYPosition:M,columnGroupIndex:p,elDataLabelsWrap:w,elGoalsMarkers:k,visibleSeries:this.visibleI,type:"rangebar"})}s.add(x)}return s}},{key:"detectOverlappingBars",value:function(e){var t=e.i,i=e.j,a=e.barYPosition,r=e.barXPosition,s=e.srty,n=e.srtx,o=e.barHeight,l=e.barWidth,c=e.yDivision,h=e.xDivision,d=e.initPositions,u=this.w,g=[],f=u.config.series[t].data[i].rangeName,p=u.config.series[t].data[i].x,x=Array.isArray(p)?p.join(" "):p,b=u.globals.labels.map((function(e){return Array.isArray(e)?e.join(" "):e})).indexOf(x),v=u.globals.seriesRange[t].findIndex((function(e){return e.x===x&&e.overlaps.length>0}));return this.isHorizontal?(a=u.config.plotOptions.bar.rangeBarGroupRows?s+c*b:s+o*this.visibleI+c*b,v>-1&&!u.config.plotOptions.bar.rangeBarOverlap&&(g=u.globals.seriesRange[t][v].overlaps).indexOf(f)>-1&&(a=(o=d.barHeight/g.length)*this.visibleI+c*(100-parseInt(this.barOptions.barHeight,10))/100/2+o*(this.visibleI+g.indexOf(f))+c*b)):(b>-1&&!u.globals.timescaleLabels.length&&(r=u.config.plotOptions.bar.rangeBarGroupRows?n+h*b:n+l*this.visibleI+h*b),v>-1&&!u.config.plotOptions.bar.rangeBarOverlap&&(g=u.globals.seriesRange[t][v].overlaps).indexOf(f)>-1&&(r=(l=d.barWidth/g.length)*this.visibleI+h*(100-parseInt(this.barOptions.barWidth,10))/100/2+l*(this.visibleI+g.indexOf(f))+h*b)),{barYPosition:a,barXPosition:r,barHeight:o,barWidth:l}}},{key:"drawRangeColumnPaths",value:function(e){var t=e.indexes,i=e.x,a=e.xDivision,r=e.barWidth,s=e.barXPosition,n=e.zeroH,o=this.w,l=t.i,c=t.j,h=t.realIndex,d=t.translationsIndex,u=this.yRatio[d],g=this.getRangeValue(h,c),f=Math.min(g.start,g.end),p=Math.max(g.start,g.end);void 0===this.series[l][c]||null===this.series[l][c]?f=n:(f=n-f/u,p=n-p/u);var x=Math.abs(p-f),b=this.barHelpers.getColumnPaths({barXPosition:s,barWidth:r,y1:f,y2:p,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,realIndex:h,i:h,j:c,w:o});if(o.globals.isXNumeric){var v=this.getBarXForNumericXAxis({x:i,j:c,realIndex:h,barWidth:r});i=v.x,s=v.barXPosition}else i+=a;return{pathTo:b.pathTo,pathFrom:b.pathFrom,barHeight:x,x:i,y:g.start<0&&g.end<0?f:p,goalY:this.barHelpers.getGoalValues("y",null,n,l,c,d),barXPosition:s}}},{key:"preventBarOverflow",value:function(e){var t=this.w;return e<0&&(e=0),e>t.globals.gridWidth&&(e=t.globals.gridWidth),e}},{key:"drawRangeBarPaths",value:function(e){var t=e.indexes,i=e.y,a=e.y1,r=e.y2,s=e.yDivision,n=e.barHeight,o=e.barYPosition,l=e.zeroW,c=this.w,h=t.realIndex,d=t.j,u=this.preventBarOverflow(l+a/this.invertedYRatio),g=this.preventBarOverflow(l+r/this.invertedYRatio),f=this.getRangeValue(h,d),p=Math.abs(g-u),x=this.barHelpers.getBarpaths({barYPosition:o,barHeight:n,x1:u,x2:g,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,i:h,realIndex:h,j:d,w:c});return c.globals.isXNumeric||(i+=s),{pathTo:x.pathTo,pathFrom:x.pathFrom,barWidth:p,x:f.start<0&&f.end<0?u:g,goalX:this.barHelpers.getGoalValues("x",l,null,h,d),y:i}}},{key:"getRangeValue",value:function(e,t){var i=this.w;return{start:i.globals.seriesRangeStart[e][t],end:i.globals.seriesRangeEnd[e][t]}}}])&&ia(t.prototype,i),o}(fi);function na(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var oa=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.lineCtx=t}var t,i;return t=e,(i=[{key:"sameValueSeriesFix",value:function(e,t){var i=this.w;if(("gradient"===i.config.fill.type||"gradient"===i.config.fill.type[e])&&new p(this.lineCtx.ctx,i).seriesHaveSameValues(e)){var a=t[e].slice();a[a.length-1]=a[a.length-1]+1e-6,t[e]=a}return t}},{key:"calculatePoints",value:function(e){var t=e.series,i=e.realIndex,a=e.x,s=e.y,n=e.i,o=e.j,l=e.prevY,c=this.w,h=[],d=[];if(0===o){var u=this.lineCtx.categoryAxisCorrection+c.config.markers.offsetX;c.globals.isXNumeric&&(u=(c.globals.seriesX[i][0]-c.globals.minX)/this.lineCtx.xRatio+c.config.markers.offsetX),h.push(u),d.push(r.isNumber(t[n][0])?l+c.config.markers.offsetY:null),h.push(a+c.config.markers.offsetX),d.push(r.isNumber(t[n][o+1])?s+c.config.markers.offsetY:null)}else h.push(a+c.config.markers.offsetX),d.push(r.isNumber(t[n][o+1])?s+c.config.markers.offsetY:null);return{x:h,y:d}}},{key:"checkPreviousPaths",value:function(e){for(var t=e.pathFromLine,i=e.pathFromArea,a=e.realIndex,r=this.w,s=0;s<r.globals.previousPaths.length;s++){var n=r.globals.previousPaths[s];("line"===n.type||"area"===n.type)&&n.paths.length>0&&parseInt(n.realIndex,10)===parseInt(a,10)&&("line"===n.type?(this.lineCtx.appendPathFrom=!1,t=r.globals.previousPaths[s].paths[0].d):"area"===n.type&&(this.lineCtx.appendPathFrom=!1,i=r.globals.previousPaths[s].paths[0].d,r.config.stroke.show&&r.globals.previousPaths[s].paths[1]&&(t=r.globals.previousPaths[s].paths[1].d)))}return{pathFromLine:t,pathFromArea:i}}},{key:"determineFirstPrevY",value:function(e){var t,i,a,r=e.i,s=e.realIndex,n=e.series,o=e.prevY,l=e.lineYPosition,c=e.translationsIndex,h=this.w,d=h.config.chart.stacked&&!h.globals.comboCharts||h.config.chart.stacked&&h.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||"bar"===(null===(t=this.w.config.series[s])||void 0===t?void 0:t.type)||"column"===(null===(i=this.w.config.series[s])||void 0===i?void 0:i.type));if(void 0!==(null===(a=n[r])||void 0===a?void 0:a[0]))o=(l=d&&r>0?this.lineCtx.prevSeriesY[r-1][0]:this.lineCtx.zeroY)-n[r][0]/this.lineCtx.yRatio[c]+2*(this.lineCtx.isReversed?n[r][0]/this.lineCtx.yRatio[c]:0);else if(d&&r>0&&void 0===n[r][0])for(var u=r-1;u>=0;u--)if(null!==n[u][0]&&void 0!==n[u][0]){o=l=this.lineCtx.prevSeriesY[u][0];break}return{prevY:o,lineYPosition:l}}}])&&na(t.prototype,i),e}(),la=function(e){var t=function(e){for(var t,i,a,r,s=function(e){for(var t=[],i=e[0],a=e[1],r=t[0]=ha(i,a),s=1,n=e.length-1;s<n;s++)i=a,a=e[s+1],t[s]=.5*(r+(r=ha(i,a)));return t[s]=r,t}(e),n=e.length-1,o=[],l=0;l<n;l++)a=ha(e[l],e[l+1]),Math.abs(a)<1e-6?s[l]=s[l+1]=0:(r=(t=s[l]/a)*t+(i=s[l+1]/a)*i)>9&&(r=3*a/Math.sqrt(r),s[l]=r*t,s[l+1]=r*i);for(var c=0;c<=n;c++)r=(e[Math.min(n,c+1)][0]-e[Math.max(0,c-1)][0])/(6*(1+s[c]*s[c])),o.push([r||0,s[c]*r||0]);return o}(e),i=e[1],a=e[0],r=[],s=t[1],n=t[0];r.push(a,[a[0]+n[0],a[1]+n[1],i[0]-s[0],i[1]-s[1],i[0],i[1]]);for(var o=2,l=t.length;o<l;o++){var c=e[o],h=t[o];r.push([c[0]-h[0],c[1]-h[1],c[0],c[1]])}return r},ca=function(e,t,i){var a=e.slice(t,i);if(t){if(i-t>1&&a[1].length<6){var r=a[0].length;a[1]=[2*a[0][r-2]-a[0][r-4],2*a[0][r-1]-a[0][r-3]].concat(a[1])}a[0]=a[0].slice(-2)}return a};function ha(e,t){return(t[1]-e[1])/(t[0]-e[0])}function da(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ua(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?da(Object(i),!0).forEach((function(t){ga(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):da(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ga(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function fa(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const pa=function(){function e(t,i,a){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.xyRatios=i,this.pointsChart=!("bubble"!==this.w.config.chart.type&&"scatter"!==this.w.config.chart.type)||a,this.scatter=new se(this.ctx),this.noNegatives=this.w.globals.minX===Number.MAX_VALUE,this.lineHelpers=new oa(this),this.markers=new ae(this.ctx),this.prevSeriesY=[],this.categoryAxisCorrection=0,this.yaxisIndex=0}var t,i;return t=e,(i=[{key:"draw",value:function(e,t,i,a){var r,s=this.w,n=new g(this.ctx),o=s.globals.comboCharts?t:s.config.chart.type,l=n.group({class:"apexcharts-".concat(o,"-series apexcharts-plot-series")}),c=new p(this.ctx,s);this.yRatio=this.xyRatios.yRatio,this.zRatio=this.xyRatios.zRatio,this.xRatio=this.xyRatios.xRatio,this.baseLineY=this.xyRatios.baseLineY,e=c.getLogSeries(e),this.yRatio=c.getLogYRatios(this.yRatio),this.prevSeriesY=[];for(var h=[],d=0;d<e.length;d++){e=this.lineHelpers.sameValueSeriesFix(d,e);var u=s.globals.comboCharts?i[d]:d,f=this.yRatio.length>1?u:0;this._initSerieVariables(e,d,u);var x=[],b=[],v=[],m=s.globals.padHorizontal+this.categoryAxisCorrection;this.ctx.series.addCollapsedClassToSeries(this.elSeries,u),s.globals.isXNumeric&&s.globals.seriesX.length>0&&(m=(s.globals.seriesX[u][0]-s.globals.minX)/this.xRatio),v.push(m);var y,w=m,k=void 0,A=w,S=this.zeroY,C=this.zeroY;S=this.lineHelpers.determineFirstPrevY({i:d,realIndex:u,series:e,prevY:S,lineYPosition:0,translationsIndex:f}).prevY,"monotoneCubic"===s.config.stroke.curve&&null===e[d][0]?x.push(null):x.push(S),y=S,"rangeArea"===o&&(k=C=this.lineHelpers.determineFirstPrevY({i:d,realIndex:u,series:a,prevY:C,lineYPosition:0,translationsIndex:f}).prevY,b.push(null!==x[0]?C:null));var P=this._calculatePathsFrom({type:o,series:e,i:d,realIndex:u,translationsIndex:f,prevX:A,prevY:S,prevY2:C}),L=[x[0]],O=[b[0]],M={type:o,series:e,realIndex:u,translationsIndex:f,i:d,x:m,y:1,pX:w,pY:y,pathsFrom:P,linePaths:[],areaPaths:[],seriesIndex:i,lineYPosition:0,xArrj:v,yArrj:x,y2Arrj:b,seriesRangeEnd:a},T=this._iterateOverDataPoints(ua(ua({},M),{},{iterations:"rangeArea"===o?e[d].length-1:void 0,isRangeStart:!0}));if("rangeArea"===o){for(var I=this._calculatePathsFrom({series:a,i:d,realIndex:u,prevX:A,prevY:C}),E=this._iterateOverDataPoints(ua(ua({},M),{},{series:a,xArrj:[m],yArrj:L,y2Arrj:O,pY:k,areaPaths:T.areaPaths,pathsFrom:I,iterations:a[d].length-1,isRangeStart:!1})),z=T.linePaths.length/2,X=0;X<z;X++)T.linePaths[X]=E.linePaths[X+z]+T.linePaths[X];T.linePaths.splice(z),T.pathFromLine=E.pathFromLine+T.pathFromLine}else T.pathFromArea+="z";this._handlePaths({type:o,realIndex:u,i:d,paths:T}),this.elSeries.add(this.elPointsMain),this.elSeries.add(this.elDataLabelsWrap),h.push(this.elSeries)}if(void 0!==(null===(r=s.config.series[0])||void 0===r?void 0:r.zIndex)&&h.sort((function(e,t){return Number(e.node.getAttribute("zIndex"))-Number(t.node.getAttribute("zIndex"))})),s.config.chart.stacked)for(var Y=h.length-1;Y>=0;Y--)l.add(h[Y]);else for(var R=0;R<h.length;R++)l.add(h[R]);return l}},{key:"_initSerieVariables",value:function(e,t,i){var a=this.w,s=new g(this.ctx);this.xDivision=a.globals.gridWidth/(a.globals.dataPoints-("on"===a.config.xaxis.tickPlacement?1:0)),this.strokeWidth=Array.isArray(a.config.stroke.width)?a.config.stroke.width[i]:a.config.stroke.width;var n=0;this.yRatio.length>1&&(this.yaxisIndex=a.globals.seriesYAxisReverseMap[i],n=i),this.isReversed=a.config.yaxis[this.yaxisIndex]&&a.config.yaxis[this.yaxisIndex].reversed,this.zeroY=a.globals.gridHeight-this.baseLineY[n]-(this.isReversed?a.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[n]:0),this.areaBottomY=this.zeroY,(this.zeroY>a.globals.gridHeight||"end"===a.config.plotOptions.area.fillTo)&&(this.areaBottomY=a.globals.gridHeight),this.categoryAxisCorrection=this.xDivision/2,this.elSeries=s.group({class:"apexcharts-series",zIndex:void 0!==a.config.series[i].zIndex?a.config.series[i].zIndex:i,seriesName:r.escapeString(a.globals.seriesNames[i])}),this.elPointsMain=s.group({class:"apexcharts-series-markers-wrap","data:realIndex":i}),this.elDataLabelsWrap=s.group({class:"apexcharts-datalabels","data:realIndex":i});var o=e[t].length===a.globals.dataPoints;this.elSeries.attr({"data:longestSeries":o,rel:t+1,"data:realIndex":i}),this.appendPathFrom=!0}},{key:"_calculatePathsFrom",value:function(e){var t,i,a,r,s=e.type,n=e.series,o=e.i,l=e.realIndex,c=e.translationsIndex,h=e.prevX,d=e.prevY,u=e.prevY2,f=this.w,p=new g(this.ctx);if(null===n[o][0]){for(var x=0;x<n[o].length;x++)if(null!==n[o][x]){h=this.xDivision*x,d=this.zeroY-n[o][x]/this.yRatio[c],t=p.move(h,d),i=p.move(h,this.areaBottomY);break}}else t=p.move(h,d),"rangeArea"===s&&(t=p.move(h,u)+p.line(h,d)),i=p.move(h,this.areaBottomY)+p.line(h,d);if(a=p.move(0,this.zeroY)+p.line(0,this.zeroY),r=p.move(0,this.zeroY)+p.line(0,this.zeroY),f.globals.previousPaths.length>0){var b=this.lineHelpers.checkPreviousPaths({pathFromLine:a,pathFromArea:r,realIndex:l});a=b.pathFromLine,r=b.pathFromArea}return{prevX:h,prevY:d,linePath:t,areaPath:i,pathFromLine:a,pathFromArea:r}}},{key:"_handlePaths",value:function(e){var t=e.type,i=e.realIndex,a=e.i,r=e.paths,s=this.w,n=new g(this.ctx),o=new te(this.ctx);this.prevSeriesY.push(r.yArrj),s.globals.seriesXvalues[i]=r.xArrj,s.globals.seriesYvalues[i]=r.yArrj;var l=s.config.forecastDataPoints;if(l.count>0&&"rangeArea"!==t){var c=s.globals.seriesXvalues[i][s.globals.seriesXvalues[i].length-l.count-1],h=n.drawRect(c,0,s.globals.gridWidth,s.globals.gridHeight,0);s.globals.dom.elForecastMask.appendChild(h.node);var d=n.drawRect(0,0,c,s.globals.gridHeight,0);s.globals.dom.elNonForecastMask.appendChild(d.node)}this.pointsChart||s.globals.delayedElements.push({el:this.elPointsMain.node,index:i});var u={i:a,realIndex:i,animationDelay:a,initialSpeed:s.config.chart.animations.speed,dataChangeSpeed:s.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(t)};if("area"===t)for(var f=o.fillPath({seriesNumber:i}),p=0;p<r.areaPaths.length;p++){var x=n.renderPaths(ua(ua({},u),{},{pathFrom:r.pathFromArea,pathTo:r.areaPaths[p],stroke:"none",strokeWidth:0,strokeLineCap:null,fill:f}));this.elSeries.add(x)}if(s.config.stroke.show&&!this.pointsChart){var b=null;if("line"===t)b=o.fillPath({seriesNumber:i,i:a});else if("solid"===s.config.stroke.fill.type)b=s.globals.stroke.colors[i];else{var v=s.config.fill;s.config.fill=s.config.stroke.fill,b=o.fillPath({seriesNumber:i,i:a}),s.config.fill=v}for(var m=0;m<r.linePaths.length;m++){var y=b;"rangeArea"===t&&(y=o.fillPath({seriesNumber:i}));var w=ua(ua({},u),{},{pathFrom:r.pathFromLine,pathTo:r.linePaths[m],stroke:b,strokeWidth:this.strokeWidth,strokeLineCap:s.config.stroke.lineCap,fill:"rangeArea"===t?y:"none"}),k=n.renderPaths(w);if(this.elSeries.add(k),k.attr("fill-rule","evenodd"),l.count>0&&"rangeArea"!==t){var A=n.renderPaths(w);A.node.setAttribute("stroke-dasharray",l.dashArray),l.strokeWidth&&A.node.setAttribute("stroke-width",l.strokeWidth),this.elSeries.add(A),A.attr("clip-path","url(#forecastMask".concat(s.globals.cuid,")")),k.attr("clip-path","url(#nonForecastMask".concat(s.globals.cuid,")"))}}}}},{key:"_iterateOverDataPoints",value:function(e){var t,i,a=this,s=e.type,n=e.series,o=e.iterations,l=e.realIndex,c=e.translationsIndex,h=e.i,d=e.x,u=e.y,f=e.pX,p=e.pY,x=e.pathsFrom,b=e.linePaths,v=e.areaPaths,m=e.seriesIndex,y=e.lineYPosition,w=e.xArrj,k=e.yArrj,A=e.y2Arrj,S=e.isRangeStart,C=e.seriesRangeEnd,P=this.w,L=new g(this.ctx),O=this.yRatio,M=x.prevY,T=x.linePath,I=x.areaPath,E=x.pathFromLine,z=x.pathFromArea,X=r.isNumber(P.globals.minYArr[l])?P.globals.minYArr[l]:P.globals.minY;o||(o=P.globals.dataPoints>1?P.globals.dataPoints-1:P.globals.dataPoints);var Y=function(e,t){return t-e/O[c]+2*(a.isReversed?e/O[c]:0)},R=u,D=P.config.chart.stacked&&!P.globals.comboCharts||P.config.chart.stacked&&P.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||"bar"===(null===(t=this.w.config.series[l])||void 0===t?void 0:t.type)||"column"===(null===(i=this.w.config.series[l])||void 0===i?void 0:i.type)),F=P.config.stroke.curve;Array.isArray(F)&&(F=Array.isArray(m)?F[m[h]]:F[h]);for(var H,N=0,W=0;W<o;W++){var B=void 0===n[h][W+1]||null===n[h][W+1];if(P.globals.isXNumeric){var j=P.globals.seriesX[l][W+1];void 0===P.globals.seriesX[l][W+1]&&(j=P.globals.seriesX[l][o-1]),d=(j-P.globals.minX)/this.xRatio}else d+=this.xDivision;y=D&&h>0&&P.globals.collapsedSeries.length<P.config.series.length-1?this.prevSeriesY[function(e){for(var t=e;t>0;t--){if(!(P.globals.collapsedSeriesIndices.indexOf((null==m?void 0:m[t])||t)>-1))return t;t--}return 0}(h-1)][W+1]:this.zeroY,B?u=Y(X,y):(u=Y(n[h][W+1],y),"rangeArea"===s&&(R=Y(C[h][W+1],y))),w.push(d),!B||"smooth"!==P.config.stroke.curve&&"monotoneCubic"!==P.config.stroke.curve?(k.push(u),A.push(R)):(k.push(null),A.push(null));var G=this.lineHelpers.calculatePoints({series:n,x:d,y:u,realIndex:l,i:h,j:W,prevY:M}),V=this._createPaths({type:s,series:n,i:h,realIndex:l,j:W,x:d,y:u,y2:R,xArrj:w,yArrj:k,y2Arrj:A,pX:f,pY:p,pathState:N,segmentStartX:H,linePath:T,areaPath:I,linePaths:b,areaPaths:v,curve:F,isRangeStart:S});v=V.areaPaths,b=V.linePaths,f=V.pX,p=V.pY,N=V.pathState,H=V.segmentStartX,I=V.areaPath,T=V.linePath,!this.appendPathFrom||"monotoneCubic"===F&&"rangeArea"===s||(E+=L.line(d,this.zeroY),z+=L.line(d,this.zeroY)),this.handleNullDataPoints(n,G,h,W,l),this._handleMarkersAndLabels({type:s,pointsPos:G,i:h,j:W,realIndex:l,isRangeStart:S})}return{yArrj:k,xArrj:w,pathFromArea:z,areaPaths:v,pathFromLine:E,linePaths:b,linePath:T,areaPath:I}}},{key:"_handleMarkersAndLabels",value:function(e){var t=e.type,i=e.pointsPos,a=e.isRangeStart,r=e.i,s=e.j,n=e.realIndex,o=this.w,l=new oe(this.ctx);if(this.pointsChart)this.scatter.draw(this.elSeries,s,{realIndex:n,pointsPos:i,zRatio:this.zRatio,elParent:this.elPointsMain});else{o.globals.series[r].length>1&&this.elPointsMain.node.classList.add("apexcharts-element-hidden");var c=this.markers.plotChartMarkers(i,n,s+1);null!==c&&this.elPointsMain.add(c)}var h=l.drawDataLabel({type:t,isRangeStart:a,pos:i,i:n,j:s+1});null!==h&&this.elDataLabelsWrap.add(h)}},{key:"_createPaths",value:function(e){var t,i=e.type,a=e.series,r=e.i,s=(e.realIndex,e.j),n=e.x,o=e.y,l=e.xArrj,c=e.yArrj,h=e.y2,d=e.y2Arrj,u=e.pX,f=e.pY,p=e.pathState,x=e.segmentStartX,b=e.linePath,v=e.areaPath,m=e.linePaths,y=e.areaPaths,w=e.curve,k=e.isRangeStart,A=(this.w,new g(this.ctx)),S=this.areaBottomY,C="rangeArea"===i,P="rangeArea"===i&&k;switch(w){case"monotoneCubic":var L=k?c:d;switch(p){case 0:if(null===L[s+1])break;p=1;case 1:if(!(C?l.length===a[r].length:s===a[r].length-2))break;case 2:var O=k?l:l.slice().reverse(),M=k?L:L.slice().reverse(),T=(t=M,O.map((function(e,i){return[e,t[i]]})).filter((function(e){return null!==e[1]}))),I=T.length>1?la(T):T,E=[];C&&(P?y=T:E=y.reverse());var z=0,X=0;if(function(e,t){for(var i=function(e){var t=[],i=0;return e.forEach((function(e){null!==e?i++:i>0&&(t.push(i),i=0)})),i>0&&t.push(i),t}(e),a=[],r=0,s=0;r<i.length;s+=i[r++])a[r]=ca(t,s,s+i[r]);return a}(M,I).forEach((function(e){z++;var t=function(e){for(var t="",i=0;i<e.length;i++){var a=e[i],r=a.length;r>4?(t+="C".concat(a[0],", ").concat(a[1]),t+=", ".concat(a[2],", ").concat(a[3]),t+=", ".concat(a[4],", ").concat(a[5])):r>2&&(t+="S".concat(a[0],", ").concat(a[1]),t+=", ".concat(a[2],", ").concat(a[3]))}return t}(e),i=X,a=(X+=e.length)-1;P?b=A.move(T[i][0],T[i][1])+t:C?b=A.move(E[i][0],E[i][1])+A.line(T[i][0],T[i][1])+t+A.line(E[a][0],E[a][1]):(b=A.move(T[i][0],T[i][1])+t,v=b+A.line(T[a][0],S)+A.line(T[i][0],S)+"z",y.push(v)),m.push(b)})),C&&z>1&&!P){var Y=m.slice(z).reverse();m.splice(z),Y.forEach((function(e){return m.push(e)}))}p=0}break;case"smooth":var R=.35*(n-u);if(null===a[r][s])p=0;else switch(p){case 0:if(x=u,b=P?A.move(u,d[s])+A.line(u,f):A.move(u,f),v=A.move(u,f),p=1,s<a[r].length-2){var D=A.curve(u+R,f,n-R,o,n,o);b+=D,v+=D;break}case 1:if(null===a[r][s+1])b+=P?A.line(u,h):A.move(u,f),v+=A.line(u,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1;else{var F=A.curve(u+R,f,n-R,o,n,o);b+=F,v+=F,s>=a[r].length-2&&(P&&(b+=A.curve(n,o,n,o,n,h)+A.move(n,h)),v+=A.curve(n,o,n,o,n,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1)}}u=n,f=o;break;default:var H=function(e,t,i){var a=[];switch(e){case"stepline":a=A.line(t,null,"H")+A.line(null,i,"V");break;case"linestep":a=A.line(null,i,"V")+A.line(t,null,"H");break;case"straight":a=A.line(t,i)}return a};if(null===a[r][s])p=0;else switch(p){case 0:if(x=u,b=P?A.move(u,d[s])+A.line(u,f):A.move(u,f),v=A.move(u,f),p=1,s<a[r].length-2){var N=H(w,n,o);b+=N,v+=N;break}case 1:if(null===a[r][s+1])b+=P?A.line(u,h):A.move(u,f),v+=A.line(u,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1;else{var W=H(w,n,o);b+=W,v+=W,s>=a[r].length-2&&(P&&(b+=A.line(n,h)),v+=A.line(n,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1)}}u=n,f=o}return{linePaths:m,areaPaths:y,pX:u,pY:f,pathState:p,segmentStartX:x,linePath:b,areaPath:v}}},{key:"handleNullDataPoints",value:function(e,t,i,a,r){var s=this.w;if(null===e[i][a]&&s.config.markers.showNullDataPoints||1===e[i].length){var n=this.strokeWidth-s.config.markers.strokeWidth/2;n>0||(n=0);var o=this.markers.plotChartMarkers(t,r,a+1,n,!0);null!==o&&this.elPointsMain.add(o)}}}])&&fa(t.prototype,i),e}();function xa(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}i(600);var ba=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.strokeWidth=this.w.config.stroke.width,this.helpers=new Xi(t),this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.labels=[]}var t,i;return t=e,(i=[{key:"draw",value:function(e){var t=this,i=this.w,a=new g(this.ctx),s=new te(this.ctx),n=a.group({class:"apexcharts-treemap"});if(i.globals.noData)return n;var o=[];return e.forEach((function(e){var t=e.map((function(e){return Math.abs(e)}));o.push(t)})),this.negRange=this.helpers.checkColorRange(),i.config.series.forEach((function(e,i){e.data.forEach((function(e){Array.isArray(t.labels[i])||(t.labels[i]=[]),t.labels[i].push(e.x)}))})),window.TreemapSquared.generate(o,i.globals.gridWidth,i.globals.gridHeight).forEach((function(o,c){var h=a.group({class:"apexcharts-series apexcharts-treemap-series",seriesName:r.escapeString(i.globals.seriesNames[c]),rel:c+1,"data:realIndex":c});if(i.config.chart.dropShadow.enabled){var d=i.config.chart.dropShadow;new l(t.ctx).dropShadow(n,d,c)}var u=a.group({class:"apexcharts-data-labels"});o.forEach((function(r,n){var o=r[0],l=r[1],d=r[2],u=r[3],g=a.drawRect(o,l,d-o,u-l,i.config.plotOptions.treemap.borderRadius,"#fff",1,t.strokeWidth,i.config.plotOptions.treemap.useFillColorAsStroke?p:i.globals.stroke.colors[c]);g.attr({cx:o,cy:l,index:c,i:c,j:n,width:d-o,height:u-l});var f=t.helpers.getShadeColor(i.config.chart.type,c,n,t.negRange),p=f.color;void 0!==i.config.series[c].data[n]&&i.config.series[c].data[n].fillColor&&(p=i.config.series[c].data[n].fillColor);var x=s.fillPath({color:p,seriesNumber:c,dataPointIndex:n});g.node.classList.add("apexcharts-treemap-rect"),g.attr({fill:x}),t.helpers.addListeners(g);var b={x:o+(d-o)/2,y:l+(u-l)/2,width:0,height:0},v={x:o,y:l,width:d-o,height:u-l};if(i.config.chart.animations.enabled&&!i.globals.dataChanged){var m=1;i.globals.resized||(m=i.config.chart.animations.speed),t.animateTreemap(g,b,v,m)}if(i.globals.dataChanged){var y=1;t.dynamicAnim.enabled&&i.globals.shouldAnimate&&(y=t.dynamicAnim.speed,i.globals.previousPaths[c]&&i.globals.previousPaths[c][n]&&i.globals.previousPaths[c][n].rect&&(b=i.globals.previousPaths[c][n].rect),t.animateTreemap(g,b,v,y))}var w=t.getFontSize(r),k=i.config.dataLabels.formatter(t.labels[c][n],{value:i.globals.series[c][n],seriesIndex:c,dataPointIndex:n,w:i});"truncate"===i.config.plotOptions.treemap.dataLabels.format&&(w=parseInt(i.config.dataLabels.style.fontSize,10),k=t.truncateLabels(k,w,o,l,d,u));var A=t.helpers.calculateDataLabels({text:k,x:(o+d)/2,y:(l+u)/2+t.strokeWidth/2+w/3,i:c,j:n,colorProps:f,fontSize:w,series:e});i.config.dataLabels.enabled&&A&&t.rotateToFitLabel(A,w,k,o,l,d,u),h.add(g),null!==A&&h.add(A)})),h.add(u),n.add(h)})),n}},{key:"getFontSize",value:function(e){var t,i,a=this.w,r=function e(t){var i,a=0;if(Array.isArray(t[0]))for(i=0;i<t.length;i++)a+=e(t[i]);else for(i=0;i<t.length;i++)a+=t[i].length;return a}(this.labels)/function e(t){var i,a=0;if(Array.isArray(t[0]))for(i=0;i<t.length;i++)a+=e(t[i]);else for(i=0;i<t.length;i++)a+=1;return a}(this.labels);return t=(e[2]-e[0])*(e[3]-e[1]),i=Math.pow(t,.5),Math.min(i/r,parseInt(a.config.dataLabels.style.fontSize,10))}},{key:"rotateToFitLabel",value:function(e,t,i,a,r,s,n){var o=new g(this.ctx),l=o.getTextRects(i,t);if(l.width+this.w.config.stroke.width+5>s-a&&l.width<=n-r){var c=o.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,i,a,r,s){var n=new g(this.ctx),o=n.getTextRects(e,t).width+this.w.config.stroke.width+5>r-i&&s-a>r-i?s-a:r-i,l=n.getTextBasedOnMaxWidth({text:e,maxWidth:o,fontSize:t});return e.length!==l.length&&o/t<5?"":l}},{key:"animateTreemap",value:function(e,t,i,a){var r=new n(this.ctx);r.animateRect(e,{x:t.x,y:t.y,width:t.width,height:t.height},{x:i.x,y:i.y,width:i.width,height:i.height},a,(function(){r.animationCompleted(e)}))}}])&&xa(t.prototype,i),e}();function va(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ma(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?va(Object(i),!0).forEach((function(t){ya(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):va(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ya(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function wa(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ka=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.timeScaleArray=[],this.utc=this.w.config.xaxis.labels.datetimeUTC}var t,i;return t=e,(i=[{key:"calculateTimeScaleTicks",value:function(e,t){var i=this,a=this.w;if(a.globals.allSeriesCollapsed)return a.globals.labels=[],a.globals.timescaleLabels=[],[];var r=new A(this.ctx),s=(t-e)/864e5;this.determineInterval(s),a.globals.disableZoomIn=!1,a.globals.disableZoomOut=!1,s<.00011574074074074075?a.globals.disableZoomIn=!0:s>5e4&&(a.globals.disableZoomOut=!0);var n=r.getTimeUnitsfromTimestamp(e,t,this.utc),o=a.globals.gridWidth/s,l=o/24,c=l/60,h=c/60,d=Math.floor(24*s),u=Math.floor(1440*s),g=Math.floor(86400*s),f=Math.floor(s),p=Math.floor(s/30),x=Math.floor(s/365),b={minMillisecond:n.minMillisecond,minSecond:n.minSecond,minMinute:n.minMinute,minHour:n.minHour,minDate:n.minDate,minMonth:n.minMonth,minYear:n.minYear},v={firstVal:b,currentMillisecond:b.minMillisecond,currentSecond:b.minSecond,currentMinute:b.minMinute,currentHour:b.minHour,currentMonthDate:b.minDate,currentDate:b.minDate,currentMonth:b.minMonth,currentYear:b.minYear,daysWidthOnXAxis:o,hoursWidthOnXAxis:l,minutesWidthOnXAxis:c,secondsWidthOnXAxis:h,numberOfSeconds:g,numberOfMinutes:u,numberOfHours:d,numberOfDays:f,numberOfMonths:p,numberOfYears:x};switch(this.tickInterval){case"years":this.generateYearScale(v);break;case"months":case"half_year":this.generateMonthScale(v);break;case"months_days":case"months_fortnight":case"days":case"week_days":this.generateDayScale(v);break;case"hours":this.generateHourScale(v);break;case"minutes_fives":case"minutes":this.generateMinuteScale(v);break;case"seconds_tens":case"seconds_fives":case"seconds":this.generateSecondScale(v)}var m=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?ma(ma({},t),{},{day:1,value:e.value+1}):"day"===e.unit||"hour"===e.unit?ma(ma({},t),{},{value:e.value}):"minute"===e.unit?ma(ma({},t),{},{value:e.value,minute:e.value}):"second"===e.unit?ma(ma({},t),{},{value:e.value,minute:e.minute,second:e.second}):e}));return m.filter((function(e){var t=1,r=Math.ceil(a.globals.gridWidth/120),s=e.value;void 0!==a.config.xaxis.tickAmount&&(r=a.config.xaxis.tickAmount),m.length>r&&(t=Math.floor(m.length/r));var n=!1,o=!1;switch(i.tickInterval){case"years":"year"===e.unit&&(n=!0);break;case"half_year":t=7,"year"===e.unit&&(n=!0);break;case"months":t=1,"year"===e.unit&&(n=!0);break;case"months_fortnight":t=15,"year"!==e.unit&&"month"!==e.unit||(n=!0),30===s&&(o=!0);break;case"months_days":t=10,"month"===e.unit&&(n=!0),30===s&&(o=!0);break;case"week_days":t=8,"month"===e.unit&&(n=!0);break;case"days":t=1,"month"===e.unit&&(n=!0);break;case"hours":"day"===e.unit&&(n=!0);break;case"minutes_fives":case"seconds_fives":s%5!=0&&(o=!0);break;case"seconds_tens":s%10!=0&&(o=!0)}if("hours"===i.tickInterval||"minutes_fives"===i.tickInterval||"seconds_tens"===i.tickInterval||"seconds_fives"===i.tickInterval){if(!o)return!0}else if((s%t==0||n)&&!o)return!0}))}},{key:"recalcDimensionsBasedOnFormat",value:function(e,t){var i=this.w,a=this.formatDates(e),r=this.removeOverlappingTS(a);i.globals.timescaleLabels=r.slice(),new it(this.ctx).plotCoords()}},{key:"determineInterval",value:function(e){var t=24*e,i=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 i>15:this.tickInterval="minutes_fives";break;case i>5:this.tickInterval="minutes";break;case i>1:this.tickInterval="seconds_tens";break;case 60*i>20:this.tickInterval="seconds_fives";break;default:this.tickInterval="seconds"}}},{key:"generateYearScale",value:function(e){var t=e.firstVal,i=e.currentMonth,a=e.currentYear,s=e.daysWidthOnXAxis,n=e.numberOfYears,o=t.minYear,l=0,c=new A(this.ctx),h="year";if(t.minDate>1||t.minMonth>0){var d=c.determineRemainingDaysOfYear(t.minYear,t.minMonth,t.minDate);l=(c.determineDaysOfYear(t.minYear)-d+1)*s,o=t.minYear+1,this.timeScaleArray.push({position:l,value:o,unit:h,year:o,month:r.monthMod(i+1)})}else 1===t.minDate&&0===t.minMonth&&this.timeScaleArray.push({position:l,value:o,unit:h,year:a,month:r.monthMod(i+1)});for(var u=o,g=l,f=0;f<n;f++)u++,g=c.determineDaysOfYear(u-1)*s+g,this.timeScaleArray.push({position:g,value:u,unit:h,year:u,month:1})}},{key:"generateMonthScale",value:function(e){var t=e.firstVal,i=e.currentMonthDate,a=e.currentMonth,s=e.currentYear,n=e.daysWidthOnXAxis,o=e.numberOfMonths,l=a,c=0,h=new A(this.ctx),d="month",u=0;if(t.minDate>1){c=(h.determineDaysOfMonths(a+1,t.minYear)-i+1)*n,l=r.monthMod(a+1);var g=s+u,f=r.monthMod(l),p=l;0===l&&(d="year",p=g,f=1,g+=u+=1),this.timeScaleArray.push({position:c,value:p,unit:d,year:g,month:f})}else this.timeScaleArray.push({position:c,value:l,unit:d,year:s,month:r.monthMod(a)});for(var x=l+1,b=c,v=0,m=1;v<o;v++,m++){0===(x=r.monthMod(x))?(d="year",u+=1):d="month";var y=this._getYear(s,x,u);b=h.determineDaysOfMonths(x,y)*n+b;var w=0===x?y:x;this.timeScaleArray.push({position:b,value:w,unit:d,year:y,month:0===x?1:x}),x++}}},{key:"generateDayScale",value:function(e){var t=e.firstVal,i=e.currentMonth,a=e.currentYear,s=e.hoursWidthOnXAxis,n=e.numberOfDays,o=new A(this.ctx),l="day",c=t.minDate+1,h=c,d=function(e,t,i){return e>o.determineDaysOfMonths(t+1,i)?(h=1,l="month",g=t+=1,t):t},u=(24-t.minHour)*s,g=c,f=d(h,i,a);0===t.minHour&&1===t.minDate?(u=0,g=r.monthMod(t.minMonth),l="month",h=t.minDate):1!==t.minDate&&0===t.minHour&&0===t.minMinute&&(u=0,c=t.minDate,g=c,f=d(h=c,i,a)),this.timeScaleArray.push({position:u,value:g,unit:l,year:this._getYear(a,f,0),month:r.monthMod(f),day:h});for(var p=u,x=0;x<n;x++){l="day",f=d(h+=1,f,this._getYear(a,f,0));var b=this._getYear(a,f,0);p=24*s+p;var v=1===h?r.monthMod(f):h;this.timeScaleArray.push({position:p,value:v,unit:l,year:b,month:r.monthMod(f),day:v})}}},{key:"generateHourScale",value:function(e){var t=e.firstVal,i=e.currentDate,a=e.currentMonth,s=e.currentYear,n=e.minutesWidthOnXAxis,o=e.numberOfHours,l=new A(this.ctx),c="hour",h=function(e,t){return e>l.determineDaysOfMonths(t+1,s)&&(x=1,t+=1),{month:t,date:x}},d=function(e,t){return e>l.determineDaysOfMonths(t+1,s)?t+=1:t},u=60-(t.minMinute+t.minSecond/60),g=u*n,f=t.minHour+1,p=f;60===u&&(g=0,p=f=t.minHour);var x=i;p>=24&&(p=0,x+=1,c="day");var b=h(x,a).month;b=d(x,b),this.timeScaleArray.push({position:g,value:f,unit:c,day:x,hour:p,year:s,month:r.monthMod(b)}),p++;for(var v=g,m=0;m<o;m++){c="hour",p>=24&&(p=0,c="day",b=h(x+=1,b).month,b=d(x,b));var y=this._getYear(s,b,0);v=60*n+v;var w=0===p?x:p;this.timeScaleArray.push({position:v,value:w,unit:c,hour:p,day:x,year:y,month:r.monthMod(b)}),p++}}},{key:"generateMinuteScale",value:function(e){for(var t=e.currentMillisecond,i=e.currentSecond,a=e.currentMinute,s=e.currentHour,n=e.currentDate,o=e.currentMonth,l=e.currentYear,c=e.minutesWidthOnXAxis,h=e.secondsWidthOnXAxis,d=e.numberOfMinutes,u=a+1,g=n,f=o,p=l,x=s,b=(60-i-t/1e3)*h,v=0;v<d;v++)u>=60&&(u=0,24===(x+=1)&&(x=0)),this.timeScaleArray.push({position:b,value:u,unit:"minute",hour:x,minute:u,day:g,year:this._getYear(p,f,0),month:r.monthMod(f)}),b+=c,u++}},{key:"generateSecondScale",value:function(e){for(var t=e.currentMillisecond,i=e.currentSecond,a=e.currentMinute,s=e.currentHour,n=e.currentDate,o=e.currentMonth,l=e.currentYear,c=e.secondsWidthOnXAxis,h=e.numberOfSeconds,d=i+1,u=a,g=n,f=o,p=l,x=s,b=(1e3-t)/1e3*c,v=0;v<h;v++)d>=60&&(d=0,++u>=60&&(u=0,24==++x&&(x=0))),this.timeScaleArray.push({position:b,value:d,unit:"second",hour:x,minute:u,second:d,day:g,year:this._getYear(p,f,0),month:r.monthMod(f)}),b+=c,d++}},{key:"createRawDateString",value:function(e,t){var i=e.year;return 0===e.month&&(e.month=1),i+="-"+("0"+e.month.toString()).slice(-2),"day"===e.unit?i+="day"===e.unit?"-"+("0"+t).slice(-2):"-01":i+="-"+("0"+(e.day?e.day:"1")).slice(-2),"hour"===e.unit?i+="hour"===e.unit?"T"+("0"+t).slice(-2):"T00":i+="T"+("0"+(e.hour?e.hour:"0")).slice(-2),"minute"===e.unit?i+=":"+("0"+t).slice(-2):i+=":"+(e.minute?("0"+e.minute).slice(-2):"00"),"second"===e.unit?i+=":"+("0"+t).slice(-2):i+=":00",this.utc&&(i+=".000Z"),i}},{key:"formatDates",value:function(e){var t=this,i=this.w;return e.map((function(e){var a=e.value.toString(),r=new A(t.ctx),s=t.createRawDateString(e,a),n=r.getDate(r.parseDate(s));if(t.utc||(n=r.getDate(r.parseDateWithTimezone(s))),void 0===i.config.xaxis.labels.format){var o="dd MMM",l=i.config.xaxis.labels.datetimeFormatter;"year"===e.unit&&(o=l.year),"month"===e.unit&&(o=l.month),"day"===e.unit&&(o=l.day),"hour"===e.unit&&(o=l.hour),"minute"===e.unit&&(o=l.minute),"second"===e.unit&&(o=l.second),a=r.formatDate(n,o)}else a=r.formatDate(n,i.config.xaxis.labels.format);return{dateString:s,position:e.position,value:a,unit:e.unit,year:e.year,month:e.month}}))}},{key:"removeOverlappingTS",value:function(e){var t,i=this,a=new g(this.ctx),r=!1;e.length>0&&e[0].value&&e.every((function(t){return t.value.length===e[0].value.length}))&&(r=!0,t=a.getTextRects(e[0].value).width);var s=0,n=e.map((function(n,o){if(o>0&&i.w.config.xaxis.labels.hideOverlappingLabels){var l=r?t:a.getTextRects(e[s].value).width,c=e[s].position;return n.position>c+l+10?(s=o,n):null}return n}));return n.filter((function(e){return null!==e}))}},{key:"_getYear",value:function(e,t,i){return e+Math.floor(t/12)+i}}])&&wa(t.prototype,i),e}();function Aa(e){return function(e){if(Array.isArray(e))return Sa(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Sa(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Sa(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Sa(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Ca(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Pa=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=i,this.w=i.w,this.el=t}var t,i;return t=e,(i=[{key:"setupElements",value:function(){var e=this.w.globals,t=this.w.config,i=t.chart.type;e.axisCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble","radar","heatmap","treemap"].indexOf(i)>-1,e.xyCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble"].indexOf(i)>-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"),g.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?"light"!==t.theme.mode||t.chart.background?t.chart.background:"#fff":"#424242",this.setSVGDimensions(),e.dom.elLegendForeign=document.createElementNS(e.SVGNS,"foreignObject"),g.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 i=this.w,a=i.config,r=i.globals,s={series:[],i:[]},n={series:[],i:[]},o={series:[],i:[]},l={series:[],i:[]},c={series:[],i:[]},h={series:[],i:[]},d={series:[],i:[]},u={series:[],i:[]},g={series:[],seriesRangeEnd:[],i:[]},f=void 0!==a.chart.type?a.chart.type:"line",x=null,b=0;r.series.forEach((function(t,a){var p=e[a].type||f;switch(p){case"column":case"bar":c.series.push(t),c.i.push(a),i.globals.columnSeries=c;break;case"area":n.series.push(t),n.i.push(a);break;case"line":s.series.push(t),s.i.push(a);break;case"scatter":o.series.push(t),o.i.push(a);break;case"bubble":l.series.push(t),l.i.push(a);break;case"candlestick":h.series.push(t),h.i.push(a);break;case"boxPlot":d.series.push(t),d.i.push(a);break;case"rangeBar":u.series.push(t),u.i.push(a);break;case"rangeArea":g.series.push(r.seriesRangeStart[a]),g.seriesRangeEnd.push(r.seriesRangeEnd[a]),g.i.push(a);break;case"heatmap":case"treemap":case"pie":case"donut":case"polarArea":case"radialBar":case"radar":x=p;break;default:console.warn("You have specified an unrecognized series type (",p,").")}f!==p&&"scatter"!==p&&b++})),b>0&&(null!==x&&console.warn("Chart or series type ",x," can not appear with other chart or series types."),c.series.length>0&&a.plotOptions.bar.horizontal&&(b-=c.length,c={series:[],i:[]},i.globals.columnSeries={series:[],i:[]},console.warn("Horizontal bars are not supported in a mixed/combo chart. Please turn off `plotOptions.bar.horizontal`"))),r.comboCharts||(r.comboCharts=b>0);var v=new pa(this.ctx,t),m=new Ti(this.ctx,t);this.ctx.pie=new Ni(this.ctx);var y=new Ji(this.ctx);this.ctx.rangeBar=new sa(this.ctx,t);var w=new Vi(this.ctx),k=[];if(r.comboCharts){var A,S,C=new p(this.ctx);if(n.series.length>0&&(A=k).push.apply(A,Aa(C.drawSeriesByGroup(n,r.areaGroups,"area",v))),c.series.length>0)if(i.config.chart.stacked){var P=new ki(this.ctx,t);k.push(P.draw(c.series,c.i))}else this.ctx.bar=new fi(this.ctx,t),k.push(this.ctx.bar.draw(c.series,c.i));if(g.series.length>0&&k.push(v.draw(g.series,"rangeArea",g.i,g.seriesRangeEnd)),s.series.length>0&&(S=k).push.apply(S,Aa(C.drawSeriesByGroup(s,r.lineGroups,"line",v))),h.series.length>0&&k.push(m.draw(h.series,"candlestick",h.i)),d.series.length>0&&k.push(m.draw(d.series,"boxPlot",d.i)),u.series.length>0&&k.push(this.ctx.rangeBar.draw(u.series,u.i)),o.series.length>0){var L=new pa(this.ctx,t,!0);k.push(L.draw(o.series,"scatter",o.i))}if(l.series.length>0){var O=new pa(this.ctx,t,!0);k.push(O.draw(l.series,"bubble",l.i))}}else switch(a.chart.type){case"line":k=v.draw(r.series,"line");break;case"area":k=v.draw(r.series,"area");break;case"bar":a.chart.stacked?k=new ki(this.ctx,t).draw(r.series):(this.ctx.bar=new fi(this.ctx,t),k=this.ctx.bar.draw(r.series));break;case"candlestick":k=new Ti(this.ctx,t).draw(r.series,"candlestick");break;case"boxPlot":k=new Ti(this.ctx,t).draw(r.series,a.chart.type);break;case"rangeBar":k=this.ctx.rangeBar.draw(r.series);break;case"rangeArea":k=v.draw(r.seriesRangeStart,"rangeArea",void 0,r.seriesRangeEnd);break;case"heatmap":k=new Ri(this.ctx,t).draw(r.series);break;case"treemap":k=new ba(this.ctx,t).draw(r.series);break;case"pie":case"donut":case"polarArea":k=this.ctx.pie.draw(r.series);break;case"radialBar":k=y.draw(r.series);break;case"radar":k=w.draw(r.series);break;default:k=v.draw(r.series)}return k}},{key:"setSVGDimensions",value:function(){var e=this.w.globals,t=this.w.config;e.svgWidth=t.chart.width,e.svgHeight=t.chart.height;var i=r.getDimensions(this.el),a=t.chart.width.toString().split(/[0-9]+/g).pop();"%"===a?r.isNumber(i[0])&&(0===i[0].width&&(i=r.getDimensions(this.el.parentNode)),e.svgWidth=i[0]*parseInt(t.chart.width,10)/100):"px"!==a&&""!==a||(e.svgWidth=parseInt(t.chart.width,10));var s=t.chart.height.toString().split(/[0-9]+/g).pop();if("auto"!==e.svgHeight&&""!==e.svgHeight)if("%"===s){var n=r.getDimensions(this.el.parentNode);e.svgHeight=n[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),g.setAttrs(e.dom.Paper.node,{width:e.svgWidth,height:e.svgHeight}),"%"!==s){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,i={transform:"translate("+e.translateX+", "+t+")"};g.setAttrs(e.dom.elGraphical.node,i)}},{key:"resizeNonAxisCharts",value:function(){var e=this.w,t=e.globals,i=0,a=e.config.chart.sparkline.enabled?1:15;a+=e.config.grid.padding.bottom,"top"!==e.config.legend.position&&"bottom"!==e.config.legend.position||!e.config.legend.show||e.config.legend.floating||(i=new ct(this.ctx).legendHelpers.getLegendBBox().clwh+10);var s=e.globals.dom.baseEl.querySelector(".apexcharts-radialbar, .apexcharts-pie"),n=2.05*e.globals.radialSize;if(s&&!e.config.chart.sparkline.enabled&&0!==e.config.plotOptions.radialBar.startAngle){var o=r.getBoundingClientRect(s);n=o.bottom;var l=o.bottom-o.top;n=Math.max(2.05*e.globals.radialSize,l)}var c=n+t.translateY+i+a;t.dom.elLegendForeign&&t.dom.elLegendForeign.setAttribute("height",c),e.config.chart.height&&String(e.config.chart.height).indexOf("%")>0||(t.dom.elWrap.style.height=c+"px",g.setAttrs(t.dom.Paper.node,{height:c}),t.dom.Paper.node.parentNode.parentNode.style.minHeight=c+"px")}},{key:"coreCalculations",value:function(){new Le(this.ctx).init()}},{key:"resetGlobals",value:function(){var e=this,t=function(){return e.w.config.series.map((function(e){return[]}))},i=new q,a=this.w.globals;i.initGlobalVars(a),a.seriesXvalues=t(),a.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 De(this.ctx).drawXCrosshairs(),"back"===t.config.yaxis[0].crosshairs.position&&new De(this.ctx).drawYCrosshairs(),"datetime"===t.config.xaxis.type&&void 0===t.config.xaxis.labels.formatter){this.ctx.timeScale=new ka(this.ctx);var i=[];isFinite(t.globals.minX)&&isFinite(t.globals.maxX)&&!t.globals.isBarHorizontal?i=this.ctx.timeScale.calculateTimeScaleTicks(t.globals.minX,t.globals.maxX):t.globals.isBarHorizontal&&(i=this.ctx.timeScale.calculateTimeScaleTicks(t.globals.minY,t.globals.maxY)),this.ctx.timeScale.recalcDimensionsBasedOnFormat(i)}e=new p(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 i=Array.isArray(t.config.chart.brush.targets)?t.config.chart.brush.targets:[t.config.chart.brush.target];i.forEach((function(t){var i=ApexCharts.getChartByID(t);i.w.globals.brushSource=e.ctx,"function"!=typeof i.w.config.chart.events.zoomed&&(i.w.config.chart.events.zoomed=function(){e.updateSourceChart(i)}),"function"!=typeof i.w.config.chart.events.scrolled&&(i.w.config.chart.events.scrolled=function(){e.updateSourceChart(i)})})),t.config.chart.events.selection=function(e,t){i.forEach((function(e){ApexCharts.getChartByID(e).ctx.updateHelpers._updateOptions({xaxis:{min:t.xaxis.min,max:t.xaxis.max}},!1,!1,!1,!1)}))}}}}])&&Ca(t.prototype,i),e}();function La(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Oa(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?La(Object(i),!0).forEach((function(t){Ma(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):La(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Ma(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Ta(e){return Ta="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ta(e)}function Ia(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ea=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"_updateOptions",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],n=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return new Promise((function(o){var l=[t.ctx];s&&(l=t.ctx.getSyncedCharts()),t.ctx.w.globals.isExecCalled&&(l=[t.ctx],t.ctx.w.globals.isExecCalled=!1),l.forEach((function(s,c){var h=s.w;if(h.globals.shouldAnimate=a,i||(h.globals.resized=!0,h.globals.dataChanged=!0,a&&s.series.getPreviousPaths()),e&&"object"===Ta(e)&&(s.config=new _(e),e=p.extendArrayProps(s.config,e,h),s.w.globals.chartID!==t.ctx.w.globals.chartID&&delete e.series,h.config=r.extend(h.config,e),n&&(h.globals.lastXAxis=e.xaxis?r.clone(e.xaxis):[],h.globals.lastYAxis=e.yaxis?r.clone(e.yaxis):[],h.globals.initialConfig=r.extend({},h.config),h.globals.initialSeries=r.clone(h.config.series),e.series))){for(var d=0;d<h.globals.collapsedSeriesIndices.length;d++){var u=h.config.series[h.globals.collapsedSeriesIndices[d]];h.globals.collapsedSeries[d].data=h.globals.axisCharts?u.data.slice():u}for(var g=0;g<h.globals.ancillaryCollapsedSeriesIndices.length;g++){var f=h.config.series[h.globals.ancillaryCollapsedSeriesIndices[g]];h.globals.ancillaryCollapsedSeries[g].data=h.globals.axisCharts?f.data.slice():f}s.series.emptyCollapsedSeries(h.config.series)}return s.update(e).then((function(){c===l.length-1&&o(s)}))}))}))}},{key:"_updateSeries",value:function(e,t){var i=this,a=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return new Promise((function(s){var n,o=i.w;return o.globals.shouldAnimate=t,o.globals.dataChanged=!0,t&&i.ctx.series.getPreviousPaths(),o.globals.axisCharts?(0===(n=e.map((function(e,t){return i._extendSeries(e,t)}))).length&&(n=[{data:[]}]),o.config.series=n):o.config.series=e.slice(),a&&(o.globals.initialConfig.series=r.clone(o.config.series),o.globals.initialSeries=r.clone(o.config.series)),i.ctx.update().then((function(){s(i.ctx)}))}))}},{key:"_extendSeries",value:function(e,t){var i=this.w,a=i.config.series[t];return Oa(Oa({},i.config.series[t]),{},{name:e.name?e.name:null==a?void 0:a.name,color:e.color?e.color:null==a?void 0:a.color,type:e.type?e.type:null==a?void 0:a.type,group:e.group?e.group:null==a?void 0:a.group,data:e.data?e.data:null==a?void 0:a.data,zIndex:void 0!==e.zIndex?e.zIndex:t})}},{key:"toggleDataPointSelection",value:function(e,t){var i=this.w,a=null,r=".apexcharts-series[data\\:realIndex='".concat(e,"']");return i.globals.axisCharts?a=i.globals.dom.Paper.select("".concat(r," path[j='").concat(t,"'], ").concat(r," circle[j='").concat(t,"'], ").concat(r," rect[j='").concat(t,"']")).members[0]:void 0===t&&(a=i.globals.dom.Paper.select("".concat(r," path[j='").concat(e,"']")).members[0],"pie"!==i.config.chart.type&&"polarArea"!==i.config.chart.type&&"donut"!==i.config.chart.type||this.ctx.pie.pieClicked(e)),a?(new g(this.ctx).pathMouseDown(a,null),a.node?a.node:null):(console.warn("toggleDataPointSelection: Element not found"),null)}},{key:"forceXAxisUpdate",value:function(e){var t=this.w;if(["min","max"].forEach((function(i){void 0!==e.xaxis[i]&&(t.config.xaxis[i]=e.xaxis[i],t.globals.lastXAxis[i]=e.xaxis[i])})),e.xaxis.categories&&e.xaxis.categories.length&&(t.config.xaxis.categories=e.xaxis.categories),t.config.xaxis.convertedCatToNumeric){var i=new j(e);e=i.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,i){e.yaxis[i].min=0,e.yaxis[i].max=100})):(e.yaxis.min=0,e.yaxis.max=100)),e}},{key:"revertDefaultAxisMinMax",value:function(e){var t=this,i=this.w,a=i.globals.lastXAxis,r=i.globals.lastYAxis;e&&e.xaxis&&(a=e.xaxis),e&&e.yaxis&&(r=e.yaxis),i.config.xaxis.min=a.min,i.config.xaxis.max=a.max;i.config.yaxis.map((function(e,a){i.globals.zoomed||void 0!==r[a]?function(e){void 0!==r[e]&&(i.config.yaxis[e].min=r[e].min,i.config.yaxis[e].max=r[e].max)}(a):void 0!==t.ctx.opts.yaxis[a]&&(e.min=t.ctx.opts.yaxis[a].min,e.max=t.ctx.opts.yaxis[a].max)}))}}],i&&Ia(t.prototype,i),e}();function za(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}i(482),i(872),i(25),i(372),i(769),i(882),void 0===window.Apex&&(window.Apex={});var Xa=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{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 n(this.ctx),this.ctx.axes=new Ye(this.ctx),this.ctx.core=new Pa(this.ctx.el,this.ctx),this.ctx.config=new _({}),this.ctx.data=new ue(this.ctx),this.ctx.grid=new ye(this.ctx),this.ctx.graphics=new g(this.ctx),this.ctx.coreUtils=new p(this.ctx),this.ctx.crosshairs=new De(this.ctx),this.ctx.events=new Ie(this.ctx),this.ctx.exports=new xe(this.ctx),this.ctx.localization=new ze(this.ctx),this.ctx.options=new X,this.ctx.responsive=new He(this.ctx),this.ctx.series=new ce(this.ctx),this.ctx.theme=new We(this.ctx),this.ctx.formatters=new C(this.ctx),this.ctx.titleSubtitle=new je(this.ctx),this.ctx.legend=new ct(this.ctx),this.ctx.toolbar=new Ct(this.ctx),this.ctx.tooltip=new Kt(this.ctx),this.ctx.dimensions=new it(this.ctx),this.ctx.updateHelpers=new Ea(this.ctx),this.ctx.zoomPanSelection=new Tt(this.ctx),this.ctx.w.globals.tooltip=new Kt(this.ctx)}}])&&za(t.prototype,i),e}();function Ya(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ra=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{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,i=e.isUpdating,a=this.w.globals.dom.Paper.node;a.parentNode&&a.parentNode.parentNode&&!i&&(a.parentNode.parentNode.style.minHeight="unset");var r=this.w.globals.dom.baseEl;r&&this.ctx.eventList.forEach((function(e){r.removeEventListener(e,t.ctx.events.documentEvent)}));var s=this.w.globals.dom;if(null!==this.ctx.el)for(;this.ctx.el.firstChild;)this.ctx.el.removeChild(this.ctx.el.firstChild);this.killSVG(s.Paper),s.Paper.remove(),s.elWrap=null,s.elGraphical=null,s.elLegendWrap=null,s.elLegendForeign=null,s.baseEl=null,s.elGridRect=null,s.elGridRectMask=null,s.elGridRectMarkerMask=null,s.elForecastMask=null,s.elNonForecastMask=null,s.elDefs=null}}])&&Ya(t.prototype,i),e}(),Da=new WeakMap,Fa=i(274),Ha=i.n(Fa);function Na(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Wa=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=i,this.ctx=this,this.w=new $(i).init(),this.el=t,this.w.globals.cuid=r.randomId(),this.w.globals.chartID=this.w.config.chart.id?r.escapeString(this.w.config.chart.id):this.w.globals.cuid,new Xa(this).initModules(),this.create=r.bind(this.create,this),this.windowResizeHandler=this._windowResizeHandler.bind(this),this.parentResizeHandler=this._parentResizeCallback.bind(this)}var t,i,a;return t=e,i=[{key:"render",value:function(){var e=this;return new Promise((function(t,i){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 a=e.w.config.chart.events.beforeMount;"function"==typeof a&&a(e,e.w),e.events.fireEvent("beforeMount",[e,e.w]),window.addEventListener("resize",e.windowResizeHandler),function(e,t){var i=!1;if(e.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var a=e.getBoundingClientRect();"none"!==e.style.display&&0!==a.width||(i=!0)}var r=new ResizeObserver((function(a){i&&t.call(e,a),i=!0}));e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?Array.from(e.children).forEach((function(e){return r.observe(e)})):r.observe(e),Da.set(t,r)}(e.el.parentNode,e.parentResizeHandler);var s=e.el.getRootNode&&e.el.getRootNode(),n=r.is("ShadowRoot",s),o=e.el.ownerDocument,l=n?s.getElementById("apexcharts-css"):o.getElementById("apexcharts-css");if(!l){var c;(l=document.createElement("style")).id="apexcharts-css",l.textContent=Ha();var h=(null===(c=e.opts.chart)||void 0===c?void 0:c.nonce)||e.w.config.chart.nonce;h&&l.setAttribute("nonce",h),n?s.prepend(l):o.head.appendChild(l)}var d=e.create(e.w.config.series,{});if(!d)return t(e);e.mount(d).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(d)})).catch((function(e){i(e)}))}else i(new Error("Element not found"))}))}},{key:"create",value:function(e,t){var i=this.w;new Xa(this).initModules();var a=this.w.globals;if(a.noData=!1,a.animationEnded=!1,this.responsive.checkResponsiveConfig(t),i.config.xaxis.convertedCatToNumeric&&new j(i.config).convertCatToNumericXaxis(i.config,this.ctx),null===this.el)return a.animationEnded=!0,null;if(this.core.setupElements(),"treemap"===i.config.chart.type&&(i.config.grid.show=!1,i.config.yaxis[0].show=!1),0===a.svgWidth)return a.animationEnded=!0,null;var r=p.checkComboSeries(e,i.config.chart.type);a.comboCharts=r.comboCharts,a.comboBarCount=r.comboBarCount;var s=e.every((function(e){return e.data&&0===e.data.length}));(0===e.length||s&&a.collapsedSeries.length<1)&&this.series.handleNoData(),this.events.setupEventHandlers(),this.data.parseData(e),this.theme.init(),new ae(this).setGlobalMarkerSize(),this.formatters.setLabelFormatters(),this.titleSubtitle.draw(),a.noData&&a.collapsedSeries.length!==a.series.length&&!i.config.legend.showForSingleSeries||this.legend.init(),this.series.hasAllSeriesEqualX(),a.axisCharts&&(this.core.coreCalculations(),"category"!==i.config.xaxis.type&&this.formatters.setLabelFormatters(),this.ctx.toolbar.minX=i.globals.minX,this.ctx.toolbar.maxX=i.globals.maxX),this.formatters.heatmapLabelFormatters(),new p(this).getLargestMarkerSize(),this.dimensions.plotCoords();var n=this.core.xySettings();this.grid.createGridMask();var o=this.core.plotChartType(e,n),l=new oe(this);return l.bringForward(),i.config.dataLabels.background.enabled&&l.dataLabelsBackground(),this.core.shiftGraphPosition(),{elGraph:o,xyRatios:n,dimensions:{plot:{left:i.globals.translateX,top:i.globals.translateY,width:i.globals.gridWidth,height:i.globals.gridHeight}}}}},{key:"mount",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,i=this,a=i.w;return new Promise((function(r,s){if(null===i.el)return s(new Error("Not enough data to display or target element not found"));(null===t||a.globals.allSeriesCollapsed)&&i.series.handleNoData(),i.grid=new ye(i);var n,o,l=i.grid.drawGrid();if(i.annotations=new R(i),i.annotations.drawImageAnnos(),i.annotations.drawTextAnnos(),"back"===a.config.grid.position&&(l&&a.globals.dom.elGraphical.add(l.el),null!=l&&null!==(n=l.elGridBorders)&&void 0!==n&&n.node&&a.globals.dom.elGraphical.add(l.elGridBorders)),Array.isArray(t.elGraph))for(var c=0;c<t.elGraph.length;c++)a.globals.dom.elGraphical.add(t.elGraph[c]);else a.globals.dom.elGraphical.add(t.elGraph);"front"===a.config.grid.position&&(l&&a.globals.dom.elGraphical.add(l.el),null!=l&&null!==(o=l.elGridBorders)&&void 0!==o&&o.node&&a.globals.dom.elGraphical.add(l.elGridBorders)),"front"===a.config.xaxis.crosshairs.position&&i.crosshairs.drawXCrosshairs(),"front"===a.config.yaxis[0].crosshairs.position&&i.crosshairs.drawYCrosshairs(),"treemap"!==a.config.chart.type&&i.axes.drawAxis(a.config.chart.type,l);var h=new ve(e.ctx,l),d=new Me(e.ctx,l);if(null!==l&&(h.xAxisLabelCorrections(l.xAxisTickWidth),d.setYAxisTextAlignments(),a.config.yaxis.map((function(e,t){-1===a.globals.ignoreYAxisIndexes.indexOf(t)&&d.yAxisTitleRotate(t,e.opposite)}))),i.annotations.drawAxesAnnotations(),!a.globals.noData){if(a.config.tooltip.enabled&&!a.globals.noData&&i.w.globals.tooltip.drawTooltip(t.xyRatios),a.globals.axisCharts&&(a.globals.isXNumeric||a.config.xaxis.convertedCatToNumeric||a.globals.isRangeBar))(a.config.chart.zoom.enabled||a.config.chart.selection&&a.config.chart.selection.enabled||a.config.chart.pan&&a.config.chart.pan.enabled)&&i.zoomPanSelection.init({xyRatios:t.xyRatios});else{var u=a.config.chart.toolbar.tools;["zoom","zoomin","zoomout","selection","pan","reset"].forEach((function(e){u[e]=!1}))}a.config.chart.toolbar.show&&!a.globals.allSeriesCollapsed&&i.toolbar.createToolbar()}a.globals.memory.methodsToExec.length>0&&a.globals.memory.methodsToExec.forEach((function(e){e.method(e.params,!1,e.context)})),a.globals.axisCharts||a.globals.noData||i.core.resizeNonAxisCharts(),r(i)}))}},{key:"destroy",value:function(){var e,t;window.removeEventListener("resize",this.windowResizeHandler),this.el.parentNode,e=this.parentResizeHandler,(t=Da.get(e))&&(t.disconnect(),Da.delete(e));var i=this.w.config.chart.id;i&&Apex._chartInstances.forEach((function(e,t){e.id===r.escapeString(i)&&Apex._chartInstances.splice(t,1)})),new Ra(this.ctx).clear({isUpdating:!1})}},{key:"updateOptions",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],s=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],n=this.w;return n.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,i){return t.updateHelpers._extendSeries(e,i)}))),this.updateHelpers.revertDefaultAxisMinMax()),e.xaxis&&(e=this.updateHelpers.forceXAxisUpdate(e)),e.yaxis&&(e=this.updateHelpers.forceYAxisUpdate(e)),n.globals.collapsedSeriesIndices.length>0&&this.series.clearPreviousPaths(),e.theme&&(e=this.theme.updateThemeOptions(e)),this.updateHelpers._updateOptions(e,i,a,r,s)}},{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],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(e,t,i)}},{key:"appendSeries",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=this.w.config.series.slice();return a.push(e),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(a,t,i)}},{key:"appendData",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this;i.w.globals.dataChanged=!0,i.series.getPreviousPaths();for(var a=i.w.config.series.slice(),s=0;s<a.length;s++)if(null!==e[s]&&void 0!==e[s])for(var n=0;n<e[s].data.length;n++)a[s].data.push(e[s].data[n]);return i.w.config.series=a,t&&(i.w.globals.initialSeries=r.clone(i.w.config.series)),this.update()}},{key:"update",value:function(e){var t=this;return new Promise((function(i,a){new Ra(t.ctx).clear({isUpdating:!0});var r=t.create(t.w.config.series,e);if(!r)return i(t);t.mount(r).then((function(){"function"==typeof t.w.config.chart.events.updated&&t.w.config.chart.events.updated(t,t.w),t.events.fireEvent("updated",[t,t.w]),t.w.globals.isDirty=!0,i(t)})).catch((function(e){a(e)}))}))}},{key:"getSyncedCharts",value:function(){var e=this.getGroupedCharts(),t=[this];return e.length&&(t=[],e.forEach((function(e){t.push(e)}))),t}},{key:"getGroupedCharts",value:function(){var e=this;return Apex._chartInstances.filter((function(e){if(e.group)return!0})).map((function(t){return e.w.config.chart.group===t.group?t.chart:e}))}},{key:"toggleSeries",value:function(e){return this.series.toggleSeries(e)}},{key:"highlightSeriesOnLegendHover",value:function(e,t){return this.series.toggleSeriesOnHover(e,t)}},{key:"showSeries",value:function(e){this.series.showSeries(e)}},{key:"hideSeries",value:function(e){this.series.hideSeries(e)}},{key:"isSeriesHidden",value:function(e){this.series.isSeriesHidden(e)}},{key:"resetSeries",value:function(){var e=!(arguments.length>0&&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],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addXaxisAnnotationExternal(e,t,a)}},{key:"addYaxisAnnotation",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addYaxisAnnotationExternal(e,t,a)}},{key:"addPointAnnotation",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addPointAnnotationExternal(e,t,a)}},{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,i=this;t&&(i=t),i.annotations.removeAnnotation(i,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 Le(this.ctx).getMinYMaxY(e).highestY}},{key:"getLowestValueInSeries",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return new Le(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 xe(this.ctx).dataURI(e)}},{key:"exportToCSV",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new xe(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()}}],a=[{key:"getChartByID",value:function(e){var t=r.escapeString(e);if(Apex._chartInstances){var i=Apex._chartInstances.filter((function(e){return e.id===t}))[0];return i&&i.chart}}},{key:"initOnLoad",value:function(){for(var t=document.querySelectorAll("[data-apexcharts]"),i=0;i<t.length;i++)new e(t[i],JSON.parse(t[i].getAttribute("data-options"))).render()}},{key:"exec",value:function(e,t){var i=this.getChartByID(e);if(i){i.w.globals.isExecCalled=!0;var a=null;if(-1!==i.publicMethods.indexOf(t)){for(var r=arguments.length,s=new Array(r>2?r-2:0),n=2;n<r;n++)s[n-2]=arguments[n];a=i[t].apply(i,s)}return a}}},{key:"merge",value:function(e,t){return r.extend(e,t)}}],i&&Na(t.prototype,i),a&&Na(t,a),e}()})(),a})()));
2
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.ApexCharts=t():e.ApexCharts=t()}(self,(()=>(()=>{var e={922:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var i="",a=void 0!==t[5];return t[4]&&(i+="@supports (".concat(t[4],") {")),t[2]&&(i+="@media ".concat(t[2]," {")),a&&(i+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),i+=e(t),a&&(i+="}"),t[2]&&(i+="}"),t[4]&&(i+="}"),i})).join("")},t.i=function(e,i,a,r,s){"string"==typeof e&&(e=[[null,e,void 0]]);var n={};if(a)for(var o=0;o<this.length;o++){var l=this[o][0];null!=l&&(n[l]=!0)}for(var c=0;c<e.length;c++){var h=[].concat(e[c]);a&&n[h[0]]||(void 0!==s&&(void 0===h[5]||(h[1]="@layer".concat(h[5].length>0?" ".concat(h[5]):""," {").concat(h[1],"}")),h[5]=s),i&&(h[2]?(h[1]="@media ".concat(h[2]," {").concat(h[1],"}"),h[2]=i):h[2]=i),r&&(h[4]?(h[1]="@supports (".concat(h[4],") {").concat(h[1],"}"),h[4]=r):h[4]="".concat(r)),t.push(h))}},t}},499:e=>{"use strict";e.exports=function(e){return e[1]}},372:function(){function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}(function(){function t(e){e.remember("_draggable",this),this.el=e}t.prototype.init=function(e,t){var i=this;this.constraint=e,this.value=t,this.el.on("mousedown.drag",(function(e){i.start(e)})),this.el.on("touchstart.drag",(function(e){i.start(e)}))},t.prototype.transformPoint=function(e,t){var i=(e=e||window.event).changedTouches&&e.changedTouches[0]||e;return this.p.x=i.clientX-(t||0),this.p.y=i.clientY,this.p.matrixTransform(this.m)},t.prototype.getBBox=function(){var e=this.el.bbox();return this.el instanceof SVG.Nested&&(e=this.el.rbox()),(this.el instanceof SVG.G||this.el instanceof SVG.Use||this.el instanceof SVG.Nested)&&(e.x=this.el.x(),e.y=this.el.y()),e},t.prototype.start=function(e){if("click"!=e.type&&"mousedown"!=e.type&&"mousemove"!=e.type||1==(e.which||e.buttons)){var t=this;if(this.el.fire("beforedrag",{event:e,handler:this}),!this.el.event().defaultPrevented){e.preventDefault(),e.stopPropagation(),this.parent=this.parent||this.el.parent(SVG.Nested)||this.el.parent(SVG.Doc),this.p=this.parent.node.createSVGPoint(),this.m=this.el.node.getScreenCTM().inverse();var i,a=this.getBBox();if(this.el instanceof SVG.Text)switch(i=this.el.node.getComputedTextLength(),this.el.attr("text-anchor")){case"middle":i/=2;break;case"start":i=0}this.startPoints={point:this.transformPoint(e,i),box:a,transform:this.el.transform()},SVG.on(window,"mousemove.drag",(function(e){t.drag(e)})),SVG.on(window,"touchmove.drag",(function(e){t.drag(e)})),SVG.on(window,"mouseup.drag",(function(e){t.end(e)})),SVG.on(window,"touchend.drag",(function(e){t.end(e)})),this.el.fire("dragstart",{event:e,p:this.startPoints.point,m:this.m,handler:this})}}},t.prototype.drag=function(t){var i=this.getBBox(),a=this.transformPoint(t),r=this.startPoints.box.x+a.x-this.startPoints.point.x,s=this.startPoints.box.y+a.y-this.startPoints.point.y,n=this.constraint,o=a.x-this.startPoints.point.x,l=a.y-this.startPoints.point.y;if(this.el.fire("dragmove",{event:t,p:a,m:this.m,handler:this}),this.el.event().defaultPrevented)return a;if("function"==typeof n){var c=n.call(this.el,r,s,this.m);"boolean"==typeof c&&(c={x:c,y:c}),!0===c.x?this.el.x(r):!1!==c.x&&this.el.x(c.x),!0===c.y?this.el.y(s):!1!==c.y&&this.el.y(c.y)}else"object"==e(n)&&(null!=n.minX&&r<n.minX?o=(r=n.minX)-this.startPoints.box.x:null!=n.maxX&&r>n.maxX-i.width&&(o=(r=n.maxX-i.width)-this.startPoints.box.x),null!=n.minY&&s<n.minY?l=(s=n.minY)-this.startPoints.box.y:null!=n.maxY&&s>n.maxY-i.height&&(l=(s=n.maxY-i.height)-this.startPoints.box.y),null!=n.snapToGrid&&(r-=r%n.snapToGrid,s-=s%n.snapToGrid,o-=o%n.snapToGrid,l-=l%n.snapToGrid),this.el instanceof SVG.G?this.el.matrix(this.startPoints.transform).transform({x:o,y:l},!0):this.el.move(r,s));return a},t.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(i,a){"function"!=typeof i&&"object"!=e(i)||(a=i,i=!0);var r=this.remember("_draggable")||new t(this);return(i=void 0===i||i)?r.init(a||{},i):(this.off("mousedown.drag"),this.off("touchstart.drag")),this}})}).call(this)},872:function(){(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,i){return this.put(new SVG.BlendEffect(e,t,i))},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,i){return this.put(new SVG.CompositeEffect(e,t,i))},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,i){return this.put(new SVG.DiffuseLightingEffect(e,t,i))},displacementMap:function(e,t,i,a,r){return this.put(new SVG.DisplacementMapEffect(e,t,i,a,r))},specularLighting:function(e,t,i,a){return this.put(new SVG.SpecularLightingEffect(e,t,i,a))},tile:function(){return this.put(new SVG.TileEffect)},turbulence:function(e,t,i,a,r){return this.put(new SVG.TurbulenceEffect(e,t,i,a,r))},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,i){return this.parent()&&this.parent().diffuseLighting(e,t,i).in(this)},displacementMap:function(e,t,i,a){return this.parent()&&this.parent().displacementMap(this,e,t,i,a)},specularLighting:function(e,t,i,a){return this.parent()&&this.parent().specularLighting(e,t,i,a).in(this)},tile:function(){return this.parent()&&this.parent().tile().in(this)},turbulence:function(e,t,i,a,r){return this.parent()&&this.parent().turbulence(e,t,i,a,r).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,i){this.attr({in:e,in2:t,mode:i||"normal"})},colorMatrix:function(e,t){"matrix"==e&&(t=r(t)),this.attr({type:e,values:void 0===t?null:t})},convolveMatrix:function(e){e=r(e),this.attr({order:Math.sqrt(e.split(" ").length),kernelMatrix:e})},composite:function(e,t,i){this.attr({in:e,in2:t,operator:i})},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,i,a,r){this.attr({in:e,in2:t,scale:i,xChannelSelector:a,yChannelSelector:r})},gaussianBlur:function(e,t){null!=e||null!=t?this.attr("stdDeviation",function(e){if(!Array.isArray(e))return e;for(var t=0,i=e.length,a=[];t<i;t++)a.push(e[t]);return a.join(" ")}(Array.prototype.slice.call(arguments))):this.attr("stdDeviation","0 0")},morphology:function(e,t){this.attr({operator:e,radius:t})},tile:function(){},turbulence:function(e,t,i,a,r){this.attr({numOctaves:t,seed:i,stitchTiles:a,baseFrequency:e,type:r})}},i={merge:function(){var e;if(arguments[0]instanceof SVG.Set){var t=this;arguments[0].each((function(e){this instanceof SVG.MergeNode?t.put(this):(this instanceof SVG.Effect||this instanceof SVG.ParentEffect)&&t.put(new SVG.MergeNode(this))}))}else{e=Array.isArray(arguments[0])?arguments[0]:arguments;for(var i=0;i<e.length;i++)e[i]instanceof SVG.MergeNode?this.put(e[i]):this.put(new SVG.MergeNode(e[i]))}},componentTransfer:function(e){if(this.rgb=new SVG.Set,["r","g","b","a"].forEach(function(e){this[e]=new(SVG["Func"+e.toUpperCase()])("identity"),this.rgb.add(this[e]),this.node.appendChild(this[e].node)}.bind(this)),e)for(var t in e.rgb&&(["r","g","b"].forEach(function(t){this[t].attr(e.rgb)}.bind(this)),delete e.rgb),e)this[t].attr(e[t])},diffuseLighting:function(e,t,i){this.attr({surfaceScale:e,diffuseConstant:t,kernelUnitLength:i})},specularLighting:function(e,t,i,a){this.attr({surfaceScale:e,diffuseConstant:t,specularExponent:i,kernelUnitLength:a})}},a={distantLight:function(e,t){this.attr({azimuth:e,elevation:t})},pointLight:function(e,t,i){this.attr({x:e,y:t,z:i})},spotLight:function(e,t,i,a,r,s){this.attr({x:e,y:t,z:i,pointsAtX:a,pointsAtY:r,pointsAtZ:s})},mergeNode:function(e){this.attr("in",e)}};function r(e){return Array.isArray(e)&&(e=new SVG.Array(e)),e.toString().replace(/^\s+/,"").replace(/\s+$/,"").replace(/\s+/g," ")}function s(){var e=function(){};for(var t in"function"==typeof arguments[arguments.length-1]&&(e=arguments[arguments.length-1],Array.prototype.splice.call(arguments,arguments.length-1,1)),arguments)for(var i in arguments[t])e(arguments[t][i],i,arguments[t])}["r","g","b","a"].forEach((function(e){a["Func"+e.toUpperCase()]=function(e){switch(this.attr("type",e),e){case"table":this.attr("tableValues",arguments[1]);break;case"linear":this.attr("slope",arguments[1]),this.attr("intercept",arguments[2]);break;case"gamma":this.attr("amplitude",arguments[1]),this.attr("exponent",arguments[2]),this.attr("offset",arguments[2])}}})),s(t,(function(e,t){var i=t.charAt(0).toUpperCase()+t.slice(1);SVG[i+"Effect"]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),e.apply(this,arguments),this.result(this.attr("id")+"Out")},inherit:SVG.Effect,extend:{}})})),s(i,(function(e,t){var i=t.charAt(0).toUpperCase()+t.slice(1);SVG[i+"Effect"]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),e.apply(this,arguments),this.result(this.attr("id")+"Out")},inherit:SVG.ParentEffect,extend:{}})})),s(a,(function(e,t){var i=t.charAt(0).toUpperCase()+t.slice(1);SVG[i]=SVG.invent({create:function(){this.constructor.call(this,SVG.create("fe"+i)),e.apply(this,arguments)},inherit:SVG.ChildEffect,extend:{}})})),SVG.extend(SVG.MergeEffect,{in:function(e){return e instanceof SVG.MergeNode?this.add(e,0):this.add(new SVG.MergeNode(e),0),this}}),SVG.extend(SVG.CompositeEffect,SVG.BlendEffect,SVG.DisplacementMapEffect,{in2:function(e){return null==e?this.parent()&&this.parent().select('[result="'+this.attr("in2")+'"]').get(0)||this.attr("in2"):this.attr("in2",e)}}),SVG.filter={sepiatone:[.343,.669,.119,0,0,.249,.626,.13,0,0,.172,.334,.111,0,0,0,0,0,1,0]}}).call(this)},25:()=>{!function(){"use strict";function e(e,r,s,n,o,l,c){for(var h=e.slice(r,s||c),d=n.slice(o,l||c),u=0,g={pos:[0,0],start:[0,0]},f={pos:[0,0],start:[0,0]};h[u]=t.call(g,h[u]),d[u]=t.call(f,d[u]),h[u][0]!=d[u][0]||"M"==h[u][0]||"A"==h[u][0]&&(h[u][4]!=d[u][4]||h[u][5]!=d[u][5])?(Array.prototype.splice.apply(h,[u,1].concat(a.call(g,h[u]))),Array.prototype.splice.apply(d,[u,1].concat(a.call(f,d[u])))):(h[u]=i.call(g,h[u]),d[u]=i.call(f,d[u])),++u!=h.length||u!=d.length;)u==h.length&&h.push(["C",g.pos[0],g.pos[1],g.pos[0],g.pos[1],g.pos[0],g.pos[1]]),u==d.length&&d.push(["C",f.pos[0],f.pos[1],f.pos[0],f.pos[1],f.pos[0],f.pos[1]]);return{start:h,dest:d}}function t(e){switch(e[0]){case"z":case"Z":e[0]="L",e[1]=this.start[0],e[2]=this.start[1];break;case"H":e[0]="L",e[2]=this.pos[1];break;case"V":e[0]="L",e[2]=e[1],e[1]=this.pos[0];break;case"T":e[0]="Q",e[3]=e[1],e[4]=e[2],e[1]=this.reflection[1],e[2]=this.reflection[0];break;case"S":e[0]="C",e[6]=e[4],e[5]=e[3],e[4]=e[2],e[3]=e[1],e[2]=this.reflection[1],e[1]=this.reflection[0]}return e}function i(e){var t=e.length;return this.pos=[e[t-2],e[t-1]],-1!="SCQT".indexOf(e[0])&&(this.reflection=[2*this.pos[0]-e[t-4],2*this.pos[1]-e[t-3]]),e}function a(e){var t=[e];switch(e[0]){case"M":return this.pos=this.start=[e[1],e[2]],t;case"L":e[5]=e[3]=e[1],e[6]=e[4]=e[2],e[1]=this.pos[0],e[2]=this.pos[1];break;case"Q":e[6]=e[4],e[5]=e[3],e[4]=1*e[4]/3+2*e[2]/3,e[3]=1*e[3]/3+2*e[1]/3,e[2]=1*this.pos[1]/3+2*e[2]/3,e[1]=1*this.pos[0]/3+2*e[1]/3;break;case"A":t=function(e,t){var i,a,r,s,n,o,l,c,h,d,u,g,f,p,x,b,v,m,y,w,k,A,S,C,P,L,O=Math.abs(t[1]),M=Math.abs(t[2]),T=t[3]%360,I=t[4],E=t[5],z=t[6],X=t[7],Y=new SVG.Point(e),D=new SVG.Point(z,X),R=[];if(0===O||0===M||Y.x===D.x&&Y.y===D.y)return[["C",Y.x,Y.y,D.x,D.y,D.x,D.y]];for((a=(i=new SVG.Point((Y.x-D.x)/2,(Y.y-D.y)/2).transform((new SVG.Matrix).rotate(T))).x*i.x/(O*O)+i.y*i.y/(M*M))>1&&(O*=a=Math.sqrt(a),M*=a),r=(new SVG.Matrix).rotate(T).scale(1/O,1/M).rotate(-T),Y=Y.transform(r),o=(s=[(D=D.transform(r)).x-Y.x,D.y-Y.y])[0]*s[0]+s[1]*s[1],n=Math.sqrt(o),s[0]/=n,s[1]/=n,l=o<4?Math.sqrt(1-o/4):0,I===E&&(l*=-1),c=new SVG.Point((D.x+Y.x)/2+l*-s[1],(D.y+Y.y)/2+l*s[0]),h=new SVG.Point(Y.x-c.x,Y.y-c.y),d=new SVG.Point(D.x-c.x,D.y-c.y),u=Math.acos(h.x/Math.sqrt(h.x*h.x+h.y*h.y)),h.y<0&&(u*=-1),g=Math.acos(d.x/Math.sqrt(d.x*d.x+d.y*d.y)),d.y<0&&(g*=-1),E&&u>g&&(g+=2*Math.PI),!E&&u<g&&(g-=2*Math.PI),b=[],v=u,f=(g-u)/(p=Math.ceil(2*Math.abs(u-g)/Math.PI)),x=4*Math.tan(f/4)/3,k=0;k<=p;k++)y=Math.cos(v),m=Math.sin(v),w=new SVG.Point(c.x+y,c.y+m),b[k]=[new SVG.Point(w.x+x*m,w.y-x*y),w,new SVG.Point(w.x-x*m,w.y+x*y)],v+=f;for(b[0][0]=b[0][1].clone(),b[b.length-1][2]=b[b.length-1][1].clone(),r=(new SVG.Matrix).rotate(T).scale(O,M).rotate(-T),k=0,A=b.length;k<A;k++)b[k][0]=b[k][0].transform(r),b[k][1]=b[k][1].transform(r),b[k][2]=b[k][2].transform(r);for(k=1,A=b.length;k<A;k++)S=(w=b[k-1][2]).x,C=w.y,P=(w=b[k][0]).x,L=w.y,z=(w=b[k][1]).x,X=w.y,R.push(["C",S,C,P,L,z,X]);return R}(this.pos,e),e=t[0]}return e[0]="C",this.pos=[e[5],e[6]],this.reflection=[2*e[5]-e[3],2*e[6]-e[4]],t}function r(e,t){if(!1===t)return!1;for(var i=t,a=e.length;i<a;++i)if("M"==e[i][0])return i;return!1}SVG.extend(SVG.PathArray,{morph:function(t){for(var i=this.value,a=this.parse(t),s=0,n=0,o=!1,l=!1;!1!==s||!1!==n;){var c;o=r(i,!1!==s&&s+1),l=r(a,!1!==n&&n+1),!1===s&&(s=0==(c=new SVG.PathArray(h.start).bbox()).height||0==c.width?i.push(i[0])-1:i.push(["M",c.x+c.width/2,c.y+c.height/2])-1),!1===n&&(n=0==(c=new SVG.PathArray(h.dest).bbox()).height||0==c.width?a.push(a[0])-1:a.push(["M",c.x+c.width/2,c.y+c.height/2])-1);var h=e(i,s,o,a,n,l);i=i.slice(0,s).concat(h.start,!1===o?[]:i.slice(o)),a=a.slice(0,n).concat(h.dest,!1===l?[]:a.slice(l)),s=!1!==o&&s+h.start.length,n=!1!==l&&n+h.dest.length}return this.value=i,this.destination=new SVG.PathArray,this.destination.value=a,this}})}()},882:()=>{!function(){"use strict";(function(){function e(e){e.remember("_resizeHandler",this),this.el=e,this.parameters={},this.lastUpdateCall=null,this.p=e.doc().node.createSVGPoint()}e.prototype.transformPoint=function(e,t,i){return this.p.x=e-(this.offset.x-window.pageXOffset),this.p.y=t-(this.offset.y-window.pageYOffset),this.p.matrixTransform(i||this.m)},e.prototype._extractPosition=function(e){return{x:null!=e.clientX?e.clientX:e.touches[0].clientX,y:null!=e.clientY?e.clientY:e.touches[0].clientY}},e.prototype.init=function(e){var t=this;if(this.stop(),"stop"!==e){for(var i in this.options={},this.el.resize.defaults)this.options[i]=this.el.resize.defaults[i],void 0!==e[i]&&(this.options[i]=e[i]);this.el.on("lt.resize",(function(e){t.resize(e||window.event)})),this.el.on("rt.resize",(function(e){t.resize(e||window.event)})),this.el.on("rb.resize",(function(e){t.resize(e||window.event)})),this.el.on("lb.resize",(function(e){t.resize(e||window.event)})),this.el.on("t.resize",(function(e){t.resize(e||window.event)})),this.el.on("r.resize",(function(e){t.resize(e||window.event)})),this.el.on("b.resize",(function(e){t.resize(e||window.event)})),this.el.on("l.resize",(function(e){t.resize(e||window.event)})),this.el.on("rot.resize",(function(e){t.resize(e||window.event)})),this.el.on("point.resize",(function(e){t.resize(e||window.event)})),this.update()}},e.prototype.stop=function(){return this.el.off("lt.resize"),this.el.off("rt.resize"),this.el.off("rb.resize"),this.el.off("lb.resize"),this.el.off("t.resize"),this.el.off("r.resize"),this.el.off("b.resize"),this.el.off("l.resize"),this.el.off("rot.resize"),this.el.off("point.resize"),this},e.prototype.resize=function(e){var t=this;this.m=this.el.node.getScreenCTM().inverse(),this.offset={x:window.pageXOffset,y:window.pageYOffset};var i=this._extractPosition(e.detail.event);if(this.parameters={type:this.el.type,p:this.transformPoint(i.x,i.y),x:e.detail.x,y:e.detail.y,box:this.el.bbox(),rotation:this.el.transform().rotation},"text"===this.el.type&&(this.parameters.fontSize=this.el.attr()["font-size"]),void 0!==e.detail.i){var a=this.el.array().valueOf();this.parameters.i=e.detail.i,this.parameters.pointCoords=[a[e.detail.i][0],a[e.detail.i][1]]}switch(e.type){case"lt":this.calc=function(e,t){var i=this.snapToGrid(e,t);if(this.parameters.box.width-i[0]>0&&this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-i[0]);i=this.checkAspectRatio(i),this.el.move(this.parameters.box.x+i[0],this.parameters.box.y+i[1]).size(this.parameters.box.width-i[0],this.parameters.box.height-i[1])}};break;case"rt":this.calc=function(e,t){var i=this.snapToGrid(e,t,2);if(this.parameters.box.width+i[0]>0&&this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+i[0]);i=this.checkAspectRatio(i,!0),this.el.move(this.parameters.box.x,this.parameters.box.y+i[1]).size(this.parameters.box.width+i[0],this.parameters.box.height-i[1])}};break;case"rb":this.calc=function(e,t){var i=this.snapToGrid(e,t,0);if(this.parameters.box.width+i[0]>0&&this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x-i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+i[0]);i=this.checkAspectRatio(i),this.el.move(this.parameters.box.x,this.parameters.box.y).size(this.parameters.box.width+i[0],this.parameters.box.height+i[1])}};break;case"lb":this.calc=function(e,t){var i=this.snapToGrid(e,t,1);if(this.parameters.box.width-i[0]>0&&this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return this.el.move(this.parameters.box.x+i[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-i[0]);i=this.checkAspectRatio(i,!0),this.el.move(this.parameters.box.x+i[0],this.parameters.box.y).size(this.parameters.box.width-i[0],this.parameters.box.height+i[1])}};break;case"t":this.calc=function(e,t){var i=this.snapToGrid(e,t,2);if(this.parameters.box.height-i[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y+i[1]).height(this.parameters.box.height-i[1])}};break;case"r":this.calc=function(e,t){var i=this.snapToGrid(e,t,0);if(this.parameters.box.width+i[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).width(this.parameters.box.width+i[0])}};break;case"b":this.calc=function(e,t){var i=this.snapToGrid(e,t,0);if(this.parameters.box.height+i[1]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x,this.parameters.box.y).height(this.parameters.box.height+i[1])}};break;case"l":this.calc=function(e,t){var i=this.snapToGrid(e,t,1);if(this.parameters.box.width-i[0]>0){if("text"===this.parameters.type)return;this.el.move(this.parameters.box.x+i[0],this.parameters.box.y).width(this.parameters.box.width-i[0])}};break;case"rot":this.calc=function(e,t){var i=e+this.parameters.p.x,a=t+this.parameters.p.y,r=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),s=Math.atan2(a-this.parameters.box.y-this.parameters.box.height/2,i-this.parameters.box.x-this.parameters.box.width/2),n=this.parameters.rotation+180*(s-r)/Math.PI+this.options.snapToAngle/2;this.el.center(this.parameters.box.cx,this.parameters.box.cy).rotate(n-n%this.options.snapToAngle,this.parameters.box.cx,this.parameters.box.cy)};break;case"point":this.calc=function(e,t){var i=this.snapToGrid(e,t,this.parameters.pointCoords[0],this.parameters.pointCoords[1]),a=this.el.array().valueOf();a[this.parameters.i][0]=this.parameters.pointCoords[0]+i[0],a[this.parameters.i][1]=this.parameters.pointCoords[1]+i[1],this.el.plot(a)}}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),i=this.transformPoint(t.x,t.y),a=i.x-this.parameters.p.x,r=i.y-this.parameters.p.y;this.lastUpdateCall=[a,r],this.calc(a,r),this.el.fire("resizing",{dx:a,dy:r,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,i,a){var r;return void 0!==a?r=[(i+e)%this.options.snapToGrid,(a+t)%this.options.snapToGrid]:(i=null==i?3:i,r=[(this.parameters.box.x+e+(1&i?0:this.parameters.box.width))%this.options.snapToGrid,(this.parameters.box.y+t+(2&i?0:this.parameters.box.height))%this.options.snapToGrid]),e<0&&(r[0]-=this.options.snapToGrid),t<0&&(r[1]-=this.options.snapToGrid),e-=Math.abs(r[0])<this.options.snapToGrid/2?r[0]:r[0]-(e<0?-this.options.snapToGrid:this.options.snapToGrid),t-=Math.abs(r[1])<this.options.snapToGrid/2?r[1]:r[1]-(t<0?-this.options.snapToGrid:this.options.snapToGrid),this.constraintToBox(e,t,i,a)},e.prototype.constraintToBox=function(e,t,i,a){var r,s,n=this.options.constraint||{};return void 0!==a?(r=i,s=a):(r=this.parameters.box.x+(1&i?0:this.parameters.box.width),s=this.parameters.box.y+(2&i?0:this.parameters.box.height)),void 0!==n.minX&&r+e<n.minX&&(e=n.minX-r),void 0!==n.maxX&&r+e>n.maxX&&(e=n.maxX-r),void 0!==n.minY&&s+t<n.minY&&(t=n.minY-s),void 0!==n.maxY&&s+t>n.maxY&&(t=n.maxY-s),[e,t]},e.prototype.checkAspectRatio=function(e,t){if(!this.options.saveAspectRatio)return e;var i=e.slice(),a=this.parameters.box.width/this.parameters.box.height,r=this.parameters.box.width+e[0],s=this.parameters.box.height-e[1],n=r/s;return n<a?(i[1]=r/a-this.parameters.box.height,t&&(i[1]=-i[1])):n>a&&(i[0]=this.parameters.box.width-s*a,t&&(i[0]=-i[0])),i},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)}()},769:()=>{function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}!function(){"use strict";function t(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,i){var a="string"!=typeof e?e:t[e];return i?a/2:a},this.pointCoords=function(e,t){var i=this.pointsList[e];return{x:this.pointCoord(i[0],t,"t"===e||"b"===e),y:this.pointCoord(i[1],t,"r"===e||"l"===e)}}}t.prototype.init=function(e,t){var i=this.el.bbox();this.options={};var a=this.el.selectize.defaults.points;for(var r in this.el.selectize.defaults)this.options[r]=this.el.selectize.defaults[r],void 0!==t[r]&&(this.options[r]=t[r]);var s=["points","pointsExclude"];for(var r in s){var n=this.options[s[r]];"string"==typeof n?n=n.length>0?n.split(/\s*,\s*/i):[]:"boolean"==typeof n&&"points"===s[r]&&(n=n?a:[]),this.options[s[r]]=n}this.options.points=[a,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(i.x,i.y)),this.options.deepSelect&&-1!==["line","polyline","polygon"].indexOf(this.el.type)?this.selectPoints(e):this.selectRect(e),this.observe(),this.cleanup()},t.prototype.selectPoints=function(e){return this.pointSelection.isSelected=e,this.pointSelection.set||(this.pointSelection.set=this.parent.set(),this.drawPoints()),this},t.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]}))},t.prototype.drawPoints=function(){for(var e=this,t=this.getPointArray(),i=0,a=t.length;i<a;++i){var r=function(t){return function(i){(i=i||window.event).preventDefault?i.preventDefault():i.returnValue=!1,i.stopPropagation();var a=i.pageX||i.touches[0].pageX,r=i.pageY||i.touches[0].pageY;e.el.fire("point",{x:a,y:r,i:t,event:i})}}(i),s=this.drawPoint(t[i][0],t[i][1]).addClass(this.options.classPoints).addClass(this.options.classPoints+"_point").on("touchstart",r).on("mousedown",r);this.pointSelection.set.add(s)}},t.prototype.drawPoint=function(e,t){var i=this.options.pointType;switch(i){case"circle":return this.drawCircle(e,t);case"rect":return this.drawRect(e,t);default:if("function"==typeof i)return i.call(this,e,t);throw new Error("Unknown "+i+" point type!")}},t.prototype.drawCircle=function(e,t){return this.nested.circle(this.options.pointSize).center(e,t)},t.prototype.drawRect=function(e,t){return this.nested.rect(this.options.pointSize,this.options.pointSize).center(e,t)},t.prototype.updatePointSelection=function(){var e=this.getPointArray();this.pointSelection.set.each((function(t){this.cx()===e[t][0]&&this.cy()===e[t][1]||this.center(e[t][0],e[t][1])}))},t.prototype.updateRectSelection=function(){var e=this,t=this.el.bbox();if(this.rectSelection.set.get(0).attr({width:t.width,height:t.height}),this.options.points.length&&this.options.points.map((function(i,a){var r=e.pointCoords(i,t);e.rectSelection.set.get(a+1).center(r.x,r.y)})),this.options.rotationPoint){var i=this.rectSelection.set.length();this.rectSelection.set.get(i-1).center(t.width/2,20)}},t.prototype.selectRect=function(e){var t=this,i=this.el.bbox();function a(e){return function(i){(i=i||window.event).preventDefault?i.preventDefault():i.returnValue=!1,i.stopPropagation();var a=i.pageX||i.touches[0].pageX,r=i.pageY||i.touches[0].pageY;t.el.fire(e,{x:a,y:r,event:i})}}if(this.rectSelection.isSelected=e,this.rectSelection.set=this.rectSelection.set||this.parent.set(),this.rectSelection.set.get(0)||this.rectSelection.set.add(this.nested.rect(i.width,i.height).addClass(this.options.classRect)),this.options.points.length&&this.rectSelection.set.length()<2&&(this.options.points.map((function(e,r){var s=t.pointCoords(e,i),n=t.drawPoint(s.x,s.y).attr("class",t.options.classPoints+"_"+e).on("mousedown",a(e)).on("touchstart",a(e));t.rectSelection.set.add(n)})),this.rectSelection.set.each((function(){this.addClass(t.options.classPoints)}))),this.options.rotationPoint&&(this.options.points&&!this.rectSelection.set.get(9)||!this.options.points&&!this.rectSelection.set.get(1))){var r=function(e){(e=e||window.event).preventDefault?e.preventDefault():e.returnValue=!1,e.stopPropagation();var i=e.pageX||e.touches[0].pageX,a=e.pageY||e.touches[0].pageY;t.el.fire("rot",{x:i,y:a,event:e})},s=this.drawPoint(i.width/2,20).attr("class",this.options.classPoints+"_rot").on("touchstart",r).on("mousedown",r);this.rectSelection.set.add(s)}},t.prototype.handler=function(){var e=this.el.bbox();this.nested.matrix(new SVG.Matrix(this.el).translate(e.x,e.y)),this.rectSelection.isSelected&&this.updateRectSelection(),this.pointSelection.isSelected&&this.updatePointSelection()},t.prototype.observe=function(){var e=this;if(MutationObserver)if(this.rectSelection.isSelected||this.pointSelection.isSelected)this.observerInst=this.observerInst||new MutationObserver((function(){e.handler()})),this.observerInst.observe(this.el.node,{attributes:!0});else try{this.observerInst.disconnect(),delete this.observerInst}catch(e){}else this.el.off("DOMAttrModified.select"),(this.rectSelection.isSelected||this.pointSelection.isSelected)&&this.el.on("DOMAttrModified.select",(function(){e.handler()}))},t.prototype.cleanup=function(){!this.rectSelection.isSelected&&this.rectSelection.set&&(this.rectSelection.set.each((function(){this.remove()})),this.rectSelection.set.clear(),delete this.rectSelection.set),!this.pointSelection.isSelected&&this.pointSelection.set&&(this.pointSelection.set.each((function(){this.remove()})),this.pointSelection.set.clear(),delete this.pointSelection.set),this.pointSelection.isSelected||this.rectSelection.isSelected||(this.nested.remove(),delete this.nested)},SVG.extend(SVG.Element,{selectize:function(i,a){return"object"===e(i)&&(a=i,i=!0),(this.remember("_selectHandler")||new t(this)).init(void 0===i||i,a||{}),this}}),SVG.Element.prototype.selectize.defaults={points:["lt","rt","rb","lb","t","r","b","l"],pointsExclude:[],classRect:"svg_select_boundingRect",classPoints:"svg_select_points",pointSize:7,rotationPoint:!0,deepSelect:!1,pointType:"circle"}}()},600:()=>{window.TreemapSquared={},function(){"use strict";window.TreemapSquared.generate=function(){function e(t,i,a,r){this.xoffset=t,this.yoffset=i,this.height=r,this.width=a,this.shortestEdge=function(){return Math.min(this.height,this.width)},this.getCoordinates=function(e){var t,i=[],a=this.xoffset,r=this.yoffset,n=s(e)/this.height,o=s(e)/this.width;if(this.width>=this.height)for(t=0;t<e.length;t++)i.push([a,r,a+n,r+e[t]/n]),r+=e[t]/n;else for(t=0;t<e.length;t++)i.push([a,r,a+e[t]/o,r+o]),a+=e[t]/o;return i},this.cutArea=function(t){var i;if(this.width>=this.height){var a=t/this.height,r=this.width-a;i=new e(this.xoffset+a,this.yoffset,r,this.height)}else{var s=t/this.width,n=this.height-s;i=new e(this.xoffset,this.yoffset+s,this.width,n)}return i}}function t(t,a,r,n,o){n=void 0===n?0:n,o=void 0===o?0:o;var l=i(function(e,t){var i,a=[],r=t/s(e);for(i=0;i<e.length;i++)a[i]=e[i]*r;return a}(t,a*r),[],new e(n,o,a,r),[]);return function(e){var t,i,a=[];for(t=0;t<e.length;t++)for(i=0;i<e[t].length;i++)a.push(e[t][i]);return a}(l)}function i(e,t,r,n){var o,l,c;if(0!==e.length)return o=r.shortestEdge(),function(e,t,i){var r;return 0===e.length||((r=e.slice()).push(t),a(e,i)>=a(r,i))}(t,l=e[0],o)?(t.push(l),i(e.slice(1),t,r,n)):(c=r.cutArea(s(t),n),n.push(r.getCoordinates(t)),i(e,[],c,n)),n;n.push(r.getCoordinates(t))}function a(e,t){var i=Math.min.apply(Math,e),a=Math.max.apply(Math,e),r=s(e);return Math.max(Math.pow(t,2)*a/Math.pow(r,2),Math.pow(r,2)/(Math.pow(t,2)*i))}function r(e){return e&&e.constructor===Array}function s(e){var t,i=0;for(t=0;t<e.length;t++)i+=e[t];return i}function n(e){var t,i=0;if(r(e[0]))for(t=0;t<e.length;t++)i+=n(e[t]);else i=s(e);return i}return function e(i,a,s,o,l){o=void 0===o?0:o,l=void 0===l?0:l;var c,h,d=[],u=[];if(r(i[0])){for(h=0;h<i.length;h++)d[h]=n(i[h]);for(c=t(d,a,s,o,l),h=0;h<i.length;h++)u.push(e(i[h],c[h][2]-c[h][0],c[h][3]-c[h][1],c[h][0],c[h][1]))}else u=t(i,a,s,o,l);return u}}()}()},482:function(e,t,i){var a,r;function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}r="undefined"!=typeof window?window:this,a=function(){return function(e,t){var i=(void 0!==this?this:e).SVG=function(e){if(i.supported)return e=new i.Doc(e),i.parser.draw||i.prepare(),e};if(i.ns="http://www.w3.org/2000/svg",i.xmlns="http://www.w3.org/2000/xmlns/",i.xlink="http://www.w3.org/1999/xlink",i.svgjs="http://svgjs.dev",i.supported=!0,!i.supported)return!1;i.did=1e3,i.eid=function(e){return"Svgjs"+d(e)+i.did++},i.create=function(e){var i=t.createElementNS(this.ns,e);return i.setAttribute("id",this.eid(e)),i},i.extend=function(){var e,t;t=(e=[].slice.call(arguments)).pop();for(var a=e.length-1;a>=0;a--)if(e[a])for(var r in t)e[a].prototype[r]=t[r];i.Set&&i.Set.inherit&&i.Set.inherit()},i.invent=function(e){var t="function"==typeof e.create?e.create:function(){this.constructor.call(this,i.create(e.create))};return e.inherit&&(t.prototype=new e.inherit),e.extend&&i.extend(t,e.extend),e.construct&&i.extend(e.parent||i.Container,e.construct),t},i.adopt=function(t){return t?t.instance?t.instance:((a="svg"==t.nodeName?t.parentNode instanceof e.SVGElement?new i.Nested:new i.Doc:"linearGradient"==t.nodeName?new i.Gradient("linear"):"radialGradient"==t.nodeName?new i.Gradient("radial"):i[d(t.nodeName)]?new(i[d(t.nodeName)]):new i.Element(t)).type=t.nodeName,a.node=t,t.instance=a,a instanceof i.Doc&&a.namespace().defs(),a.setData(JSON.parse(t.getAttribute("svgjs:data"))||{}),a):null;var a},i.prepare=function(){var e=t.getElementsByTagName("body")[0],a=(e?new i.Doc(e):i.adopt(t.documentElement).nested()).size(2,0);i.parser={body:e||t.documentElement,draw:a.style("opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden").node,poly:a.polyline().node,path:a.path().node,native:i.create("svg")}},i.parser={native:i.create("svg")},t.addEventListener("DOMContentLoaded",(function(){i.parser.draw||i.prepare()}),!1),i.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},i.utils={map:function(e,t){for(var i=e.length,a=[],r=0;r<i;r++)a.push(t(e[r]));return a},filter:function(e,t){for(var i=e.length,a=[],r=0;r<i;r++)t(e[r])&&a.push(e[r]);return a},filterSVGElements:function(t){return this.filter(t,(function(t){return t instanceof e.SVGElement}))}},i.defaults={attrs:{"fill-opacity":1,"stroke-opacity":1,"stroke-width":0,"stroke-linejoin":"miter","stroke-linecap":"butt",fill:"#000000",stroke:"#000000",opacity:1,x:0,y:0,cx:0,cy:0,width:0,height:0,r:0,rx:0,ry:0,offset:0,"stop-opacity":1,"stop-color":"#000000","font-size":16,"font-family":"Helvetica, Arial, sans-serif","text-anchor":"start"}},i.Color=function(e){var t,a;this.r=0,this.g=0,this.b=0,e&&("string"==typeof e?i.regex.isRgb.test(e)?(t=i.regex.rgb.exec(e.replace(i.regex.whitespace,"")),this.r=parseInt(t[1]),this.g=parseInt(t[2]),this.b=parseInt(t[3])):i.regex.isHex.test(e)&&(t=i.regex.hex.exec(4==(a=e).length?["#",a.substring(1,2),a.substring(1,2),a.substring(2,3),a.substring(2,3),a.substring(3,4),a.substring(3,4)].join(""):a),this.r=parseInt(t[1],16),this.g=parseInt(t[2],16),this.b=parseInt(t[3],16)):"object"===s(e)&&(this.r=e.r,this.g=e.g,this.b=e.b))},i.extend(i.Color,{toString:function(){return this.toHex()},toHex:function(){return"#"+u(this.r)+u(this.g)+u(this.b)},toRgb:function(){return"rgb("+[this.r,this.g,this.b].join()+")"},brightness:function(){return this.r/255*.3+this.g/255*.59+this.b/255*.11},morph:function(e){return this.destination=new i.Color(e),this},at:function(e){return this.destination?(e=e<0?0:e>1?1:e,new i.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}}),i.Color.test=function(e){return e+="",i.regex.isHex.test(e)||i.regex.isRgb.test(e)},i.Color.isRgb=function(e){return e&&"number"==typeof e.r&&"number"==typeof e.g&&"number"==typeof e.b},i.Color.isColor=function(e){return i.Color.isRgb(e)||i.Color.test(e)},i.Array=function(e,t){0==(e=(e||[]).valueOf()).length&&t&&(e=t.valueOf()),this.value=this.parse(e)},i.extend(i.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)}}),i.PointArray=function(e,t){i.Array.call(this,e,t||[[0,0]])},i.PointArray.prototype=new i.Array,i.PointArray.prototype.constructor=i.PointArray;for(var a={M:function(e,t,i){return t.x=i.x=e[0],t.y=i.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,i){return t.x=i.x,t.y=i.y,["Z"]}},r="mlhvqtcsaz".split(""),n=0,o=r.length;n<o;++n)a[r[n]]=function(e){return function(t,i,r){if("H"==e)t[0]=t[0]+i.x;else if("V"==e)t[0]=t[0]+i.y;else if("A"==e)t[5]=t[5]+i.x,t[6]=t[6]+i.y;else for(var s=0,n=t.length;s<n;++s)t[s]=t[s]+(s%2?i.y:i.x);if(a&&"function"==typeof a[e])return a[e](t,i,r)}}(r[n].toUpperCase());i.PathArray=function(e,t){i.Array.call(this,e,t||[["M",0,0]])},i.PathArray.prototype=new i.Array,i.PathArray.prototype.constructor=i.PathArray,i.extend(i.PathArray,{toString:function(){return function(e){for(var t=0,i=e.length,a="";t<i;t++)a+=e[t][0],null!=e[t][1]&&(a+=e[t][1],null!=e[t][2]&&(a+=" ",a+=e[t][2],null!=e[t][3]&&(a+=" ",a+=e[t][3],a+=" ",a+=e[t][4],null!=e[t][5]&&(a+=" ",a+=e[t][5],a+=" ",a+=e[t][6],null!=e[t][7]&&(a+=" ",a+=e[t][7])))));return a+" "}(this.value)},move:function(e,t){var i=this.bbox();return i.x,i.y,this},at:function(e){if(!this.destination)return this;for(var t=this.value,a=this.destination.value,r=[],s=new i.PathArray,n=0,o=t.length;n<o;n++){r[n]=[t[n][0]];for(var l=1,c=t[n].length;l<c;l++)r[n][l]=t[n][l]+(a[n][l]-t[n][l])*e;"A"===r[n][0]&&(r[n][4]=+(0!=r[n][4]),r[n][5]=+(0!=r[n][5]))}return s.value=r,s},parse:function(e){if(e instanceof i.PathArray)return e.valueOf();var t,r={M:2,L:2,H:1,V:1,C:6,S:4,Q:4,T:2,A:7,Z:0};e="string"==typeof e?e.replace(i.regex.numbersWithDots,c).replace(i.regex.pathLetters," $& ").replace(i.regex.hyphen,"$1 -").trim().split(i.regex.delimiter):e.reduce((function(e,t){return[].concat.call(e,t)}),[]);var s=[],n=new i.Point,o=new i.Point,l=0,h=e.length;do{i.regex.isPathLetter.test(e[l])?(t=e[l],++l):"M"==t?t="L":"m"==t&&(t="l"),s.push(a[t].call(null,e.slice(l,l+=r[t.toUpperCase()]).map(parseFloat),n,o))}while(h>l);return s},bbox:function(){return i.parser.draw||i.prepare(),i.parser.path.setAttribute("d",this.toString()),i.parser.path.getBBox()}}),i.Number=i.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(i.regex.numberAndUnit))&&(this.value=parseFloat(t[1]),"%"==t[5]?this.value/=100:"s"==t[5]&&(this.value*=1e3),this.unit=t[5]):e instanceof i.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 i.Number(e),new i.Number(this+e,this.unit||e.unit)},minus:function(e){return e=new i.Number(e),new i.Number(this-e,this.unit||e.unit)},times:function(e){return e=new i.Number(e),new i.Number(this*e,this.unit||e.unit)},divide:function(e){return e=new i.Number(e),new i.Number(this/e,this.unit||e.unit)},to:function(e){var t=new i.Number(this);return"string"==typeof e&&(t.unit=e),t},morph:function(e){return this.destination=new i.Number(e),e.relative&&(this.destination.value+=this.value),this},at:function(e){return this.destination?new i.Number(this.destination).minus(this).times(e).plus(this):this}}}),i.Element=i.invent({create:function(e){this._stroke=i.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 a=g(this,e,t);return this.width(new i.Number(a.width)).height(new i.Number(a.height))},clone:function(e){this.writeDataToDom();var t=x(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(i.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 i.get(this.attr(e))},parent:function(t){var a=this;if(!a.node.parentNode)return null;if(a=i.adopt(a.node.parentNode),!t)return a;for(;a&&a.node instanceof e.SVGElement;){if("string"==typeof t?a.matches(t):a instanceof t)return a;if(!a.node.parentNode||"#document"==a.node.parentNode.nodeName)return null;a=i.adopt(a.node.parentNode)}},doc:function(){return this instanceof i.Doc?this:this.parent(i.Doc)},parents:function(e){var t=[],i=this;do{if(!(i=i.parent(e))||!i.node)break;t.push(i)}while(i.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 a=t.createElementNS("http://www.w3.org/2000/svg","svg");if(!(e&&this instanceof i.Parent))return a.appendChild(e=t.createElementNS("http://www.w3.org/2000/svg","svg")),this.writeDataToDom(),e.appendChild(this.node.cloneNode(!0)),a.innerHTML.replace(/^<svg>/,"").replace(/<\/svg>$/,"");a.innerHTML="<svg>"+e.replace(/\n/,"").replace(/<([\w:-]+)([^<]+?)\/>/g,"<$1$2></$1>")+"</svg>";for(var r=0,s=a.firstChild.childNodes.length;r<s;r++)this.node.appendChild(a.firstChild.firstChild);return this},writeDataToDom:function(){return(this.each||this.lines)&&(this.each?this:this.lines()).each((function(){this.writeDataToDom()})),this.node.removeAttribute("svgjs:data"),Object.keys(this.dom).length&&this.node.setAttribute("svgjs:data",JSON.stringify(this.dom)),this},setData:function(e){return this.dom=e,this},is:function(e){return function(e,t){return e instanceof t}(this,e)}}}),i.easing={"-":function(e){return e},"<>":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)}},i.morph=function(e){return function(t,a){return new i.MorphObj(t,a).at(e)}},i.Situation=i.invent({create:function(e){this.init=!1,this.reversed=!1,this.reversing=!1,this.duration=new i.Number(e.duration).valueOf(),this.delay=new i.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={}}}),i.FX=i.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,a){"object"===s(e)&&(t=e.ease,a=e.delay,e=e.duration);var r=new i.Situation({duration:e||1e3,delay:a||0,ease:i.easing[t||"-"]||t});return this.queue(r),this},target:function(e){return e&&e instanceof i.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 i.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 i.Situation?this.start():this.situation.call(this)),this},initAnimations:function(){var e,t=this.situation;if(t.init)return this;for(var a in t.animations){e=this.target()[a](),Array.isArray(e)||(e=[e]),Array.isArray(t.animations[a])||(t.animations[a]=[t.animations[a]]);for(var r=e.length;r--;)t.animations[a][r]instanceof i.Number&&(e[r]=new i.Number(e[r])),t.animations[a][r]=e[r].morph(t.animations[a][r])}for(var a in t.attrs)t.attrs[a]=new i.MorphObj(this.target().attr(a),t.attrs[a]);for(var a in t.styles)t.styles[a]=new i.MorphObj(this.target().style(a),t.styles[a]);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 i=this.active;return this.active=!1,t&&this.clearQueue(),e&&this.situation&&(!i&&this.startCurrent(),this.atEnd()),this.stopAnimFrame(),this.clearCurrent()},after:function(e){var t=this.last();return this.target().on("finished.fx",(function i(a){a.detail.situation==t&&(e.call(this,t),this.off("finished.fx",i))})),this._callStart()},during:function(e){var t=this.last(),a=function(a){a.detail.situation==t&&e.call(this,a.detail.pos,i.morph(a.detail.pos),a.detail.eased,t)};return this.target().off("during.fx",a).on("during.fx",a),this.after((function(){this.off("during.fx",a)})),this._callStart()},afterAll:function(e){var t=function t(i){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,i){return this.last()[i||"animations"][e]=t,this._callStart()},step:function(e){var t,i,a;e||(this.absPos=this.timeToAbsPos(+new Date)),!1!==this.situation.loops?(t=Math.max(this.absPos,0),i=Math.floor(t),!0===this.situation.loops||i<this.situation.loops?(this.pos=t-i,a=this.situation.loop,this.situation.loop=i):(this.absPos=this.situation.loops,this.pos=1,a=this.situation.loop-1,this.situation.loop=this.situation.loops),this.situation.reversing&&(this.situation.reversed=this.situation.reversed!=Boolean((this.situation.loop-a)%2))):(this.absPos=Math.min(this.absPos,1),this.pos=this.absPos),this.pos<0&&(this.pos=0),this.situation.reversed&&(this.pos=1-this.pos);var r=this.situation.ease(this.pos);for(var s in this.situation.once)s>this.lastPos&&s<=r&&(this.situation.once[s].call(this.target(),this.pos,r),delete this.situation.once[s]);return this.active&&this.target().fire("during",{pos:this.pos,eased:r,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=r,this):this},eachAt:function(){var e,t=this,a=this.target(),r=this.situation;for(var s in r.animations)e=[].concat(r.animations[s]).map((function(e){return"string"!=typeof e&&e.at?e.at(r.ease(t.pos),t.pos):e})),a[s].apply(a,e);for(var s in r.attrs)e=[s].concat(r.attrs[s]).map((function(e){return"string"!=typeof e&&e.at?e.at(r.ease(t.pos),t.pos):e})),a.attr.apply(a,e);for(var s in r.styles)e=[s].concat(r.styles[s]).map((function(e){return"string"!=typeof e&&e.at?e.at(r.ease(t.pos),t.pos):e})),a.style.apply(a,e);if(r.transforms.length){e=r.initialTransformation,s=0;for(var n=r.transforms.length;s<n;s++){var o=r.transforms[s];o instanceof i.Matrix?e=o.relative?e.multiply((new i.Matrix).morph(o).at(r.ease(this.pos))):e.morph(o).at(r.ease(this.pos)):(o.relative||o.undo(e.extract()),e=e.multiply(o.at(r.ease(this.pos))))}a.matrix(e)}return this},once:function(e,t,i){var a=this.last();return i||(e=a.ease(e)),a.once[e]=t,this},_callStart:function(){return setTimeout(function(){this.start()}.bind(this),0),this}},parent:i.Element,construct:{animate:function(e,t,a){return(this.fx||(this.fx=new i.FX(this))).animate(e,t,a)},delay:function(e){return(this.fx||(this.fx=new i.FX(this))).delay(e)},stop:function(e,t){return this.fx&&this.fx.stop(e,t),this},finish:function(){return this.fx&&this.fx.finish(),this}}}),i.MorphObj=i.invent({create:function(e,t){return i.Color.isColor(t)?new i.Color(e).morph(t):i.regex.delimiter.test(e)?i.regex.pathLetters.test(e)?new i.PathArray(e).morph(t):new i.Array(e).morph(t):i.regex.numberAndUnit.test(t)?new i.Number(e).morph(t):(this.value=e,void(this.destination=t))},extend:{at:function(e,t){return t<1?this.value:this.destination},valueOf:function(){return this.value}}}),i.extend(i.FX,{attr:function(e,t,i){if("object"===s(e))for(var a in e)this.attr(a,e[a]);else this.add(e,t,"attrs");return this},plot:function(e,t,i,a){return 4==arguments.length?this.plot([e,t,i,a]):this.add("plot",new(this.target().morphArray)(e))}}),i.Box=i.invent({create:function(e,t,a,r){if(!("object"!==s(e)||e instanceof i.Element))return i.Box.call(this,null!=e.left?e.left:e.x,null!=e.top?e.top:e.y,e.width,e.height);var n;4==arguments.length&&(this.x=e,this.y=t,this.width=a,this.height=r),null==(n=this).x&&(n.x=0,n.y=0,n.width=0,n.height=0),n.w=n.width,n.h=n.height,n.x2=n.x+n.width,n.y2=n.y+n.height,n.cx=n.x+n.width/2,n.cy=n.y+n.height/2}}),i.BBox=i.invent({create:function(e){if(i.Box.apply(this,[].slice.call(arguments)),e instanceof i.Element){var a;try{if(!t.documentElement.contains){for(var r=e.node;r.parentNode;)r=r.parentNode;if(r!=t)throw new Error("Element not in the dom")}a=e.node.getBBox()}catch(t){if(e instanceof i.Shape){i.parser.draw||i.prepare();var s=e.clone(i.parser.draw.instance).show();s&&s.node&&"function"==typeof s.node.getBBox&&(a=s.node.getBBox()),s&&"function"==typeof s.remove&&s.remove()}else a={x:e.node.clientLeft,y:e.node.clientTop,width:e.node.clientWidth,height:e.node.clientHeight}}i.Box.call(this,a)}},inherit:i.Box,parent:i.Element,construct:{bbox:function(){return new i.BBox(this)}}}),i.BBox.prototype.constructor=i.BBox,i.Matrix=i.invent({create:function(e){var t=p([1,0,0,1,0,0]);e=null===e?t:e instanceof i.Element?e.matrixify():"string"==typeof e?p(e.split(i.regex.delimiter).map(parseFloat)):6==arguments.length?p([].slice.call(arguments)):Array.isArray(e)?p(e):e&&"object"===s(e)?e:t;for(var a=v.length-1;a>=0;--a)this[v[a]]=null!=e[v[a]]?e[v[a]]:t[v[a]]},extend:{extract:function(){var e=f(this,0,1),t=(f(this,1,0),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 i.Matrix(this)}},clone:function(){return new i.Matrix(this)},morph:function(e){return this.destination=new i.Matrix(e),this},multiply:function(e){return new i.Matrix(this.native().multiply(function(e){return e instanceof i.Matrix||(e=new i.Matrix(e)),e}(e).native()))},inverse:function(){return new i.Matrix(this.native().inverse())},translate:function(e,t){return new i.Matrix(this.native().translate(e||0,t||0))},native:function(){for(var e=i.parser.native.createSVGMatrix(),t=v.length-1;t>=0;t--)e[v[t]]=this[v[t]];return e},toString:function(){return"matrix("+b(this.a)+","+b(this.b)+","+b(this.c)+","+b(this.d)+","+b(this.e)+","+b(this.f)+")"}},parent:i.Element,construct:{ctm:function(){return new i.Matrix(this.node.getCTM())},screenCTM:function(){if(this instanceof i.Nested){var e=this.rect(1,1),t=e.node.getScreenCTM();return e.remove(),new i.Matrix(t)}return new i.Matrix(this.node.getScreenCTM())}}}),i.Point=i.invent({create:function(e,t){var i;i=Array.isArray(e)?{x:e[0],y:e[1]}:"object"===s(e)?{x:e.x,y:e.y}:null!=e?{x:e,y:null!=t?t:e}:{x:0,y:0},this.x=i.x,this.y=i.y},extend:{clone:function(){return new i.Point(this)},morph:function(e,t){return this.destination=new i.Point(e,t),this}}}),i.extend(i.Element,{point:function(e,t){return new i.Point(e,t).transform(this.screenCTM().inverse())}}),i.extend(i.Element,{attr:function(e,t,a){if(null==e){for(e={},a=(t=this.node.attributes).length-1;a>=0;a--)e[t[a].nodeName]=i.regex.isNumber.test(t[a].nodeValue)?parseFloat(t[a].nodeValue):t[a].nodeValue;return e}if("object"===s(e))for(var r in e)this.attr(r,e[r]);else if(null===t)this.node.removeAttribute(e);else{if(null==t)return null==(t=this.node.getAttribute(e))?i.defaults.attrs[e]:i.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||(i.regex.isImage.test(t)&&(t=this.doc().defs().image(t,0,0)),t instanceof i.Image&&(t=this.doc().defs().pattern(0,0,(function(){this.add(t)})))),"number"==typeof t?t=new i.Number(t):i.Color.isColor(t)?t=new i.Color(t):Array.isArray(t)&&(t=new i.Array(t)),"leading"==e?this.leading&&this.leading(t):"string"==typeof a?this.node.setAttributeNS(a,e,t.toString()):this.node.setAttribute(e,t.toString()),!this.rebuild||"font-size"!=e&&"x"!=e||this.rebuild(e,t)}return this}}),i.extend(i.Element,{transform:function(e,t){var a;return"object"!==s(e)?(a=new i.Matrix(this).extract(),"string"==typeof e?a[e]:a):(a=new i.Matrix(this),t=!!t||!!e.relative,null!=e.a&&(a=t?a.multiply(new i.Matrix(e)):new i.Matrix(e)),this.attr("transform",a))}}),i.extend(i.Element,{untransform:function(){return this.attr("transform",null)},matrixify:function(){return(this.attr("transform")||"").split(i.regex.transforms).slice(0,-1).map((function(e){var t=e.trim().split("(");return[t[0],t[1].split(i.regex.delimiter).map((function(e){return parseFloat(e)}))]})).reduce((function(e,t){return"matrix"==t[0]?e.multiply(p(t[1])):e[t[0]].apply(e,t[1])}),new i.Matrix)},toParent:function(e){if(this==e)return this;var t=this.screenCTM(),i=e.screenCTM().inverse();return this.addTo(e).untransform().transform(i.multiply(t)),this},toDoc:function(){return this.toParent(this.doc())}}),i.Transformation=i.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 i=0,a=this.arguments.length;i<a;++i)this[this.arguments[i]]=e[i];else if(e&&"object"===s(e))for(i=0,a=this.arguments.length;i<a;++i)this[this.arguments[i]]=e[this.arguments[i]];this.inversed=!1,!0===t&&(this.inversed=!0)}}),i.Translate=i.invent({parent:i.Matrix,inherit:i.Transformation,create:function(e,t){this.constructor.apply(this,[].slice.call(arguments))},extend:{arguments:["transformedX","transformedY"],method:"translate"}}),i.extend(i.Element,{style:function(e,t){if(0==arguments.length)return this.node.style.cssText||"";if(arguments.length<2)if("object"===s(e))for(var a in e)this.style(a,e[a]);else{if(!i.regex.isCss.test(e))return this.node.style[h(e)];for(e=e.split(/\s*;\s*/).filter((function(e){return!!e})).map((function(e){return e.split(/\s*:\s*/)}));t=e.pop();)this.style(t[0],t[1])}else this.node.style[h(e)]=null===t||i.regex.isBlank.test(t)?"":t;return this}}),i.Parent=i.invent({create:function(e){this.constructor.call(this,e)},inherit:i.Element,extend:{children:function(){return i.utils.map(i.utils.filterSVGElements(this.node.childNodes),(function(e){return i.adopt(e)}))},add:function(e,t){return null==t?this.node.appendChild(e.node):e.node!=this.node.childNodes[t]&&this.node.insertBefore(e.node,this.node.childNodes[t]),this},put:function(e,t){return this.add(e,t),e},has:function(e){return this.index(e)>=0},index:function(e){return[].slice.call(this.node.childNodes).indexOf(e.node)},get:function(e){return i.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 a=this.children(),r=0,s=a.length;r<s;r++)a[r]instanceof i.Element&&e.apply(a[r],[r,a]),t&&a[r]instanceof i.Container&&a[r].each(e,t);return this},removeElement:function(e){return this.node.removeChild(e.node),this},clear:function(){for(;this.node.hasChildNodes();)this.node.removeChild(this.node.lastChild);return delete this._defs,this},defs:function(){return this.doc().defs()}}}),i.extend(i.Parent,{ungroup:function(e,t){return 0===t||this instanceof i.Defs||this.node==i.parser.draw||(e=e||(this instanceof i.Doc?this:this.parent(i.Parent)),t=t||1/0,this.each((function(){return this instanceof i.Defs?this:this instanceof i.Parent?this.ungroup(e,t-1):this.toParent(e)})),this.node.firstChild||this.remove()),this},flatten:function(e,t){return this.ungroup(e,t)}}),i.Container=i.invent({create:function(e){this.constructor.call(this,e)},inherit:i.Parent}),i.ViewBox=i.invent({parent:i.Container,construct:{}}),["click","dblclick","mousedown","mouseup","mouseover","mouseout","mousemove","touchstart","touchmove","touchleave","touchend","touchcancel"].forEach((function(e){i.Element.prototype[e]=function(t){return i.on(this.node,e,t),this}})),i.listeners=[],i.handlerMap=[],i.listenerId=0,i.on=function(e,t,a,r,s){var n=a.bind(r||e.instance||e),o=(i.handlerMap.indexOf(e)+1||i.handlerMap.push(e))-1,l=t.split(".")[0],c=t.split(".")[1]||"*";i.listeners[o]=i.listeners[o]||{},i.listeners[o][l]=i.listeners[o][l]||{},i.listeners[o][l][c]=i.listeners[o][l][c]||{},a._svgjsListenerId||(a._svgjsListenerId=++i.listenerId),i.listeners[o][l][c][a._svgjsListenerId]=n,e.addEventListener(l,n,s||{passive:!1})},i.off=function(e,t,a){var r=i.handlerMap.indexOf(e),s=t&&t.split(".")[0],n=t&&t.split(".")[1],o="";if(-1!=r)if(a){if("function"==typeof a&&(a=a._svgjsListenerId),!a)return;i.listeners[r][s]&&i.listeners[r][s][n||"*"]&&(e.removeEventListener(s,i.listeners[r][s][n||"*"][a],!1),delete i.listeners[r][s][n||"*"][a])}else if(n&&s){if(i.listeners[r][s]&&i.listeners[r][s][n]){for(var l in i.listeners[r][s][n])i.off(e,[s,n].join("."),l);delete i.listeners[r][s][n]}}else if(n)for(var c in i.listeners[r])for(var o in i.listeners[r][c])n===o&&i.off(e,[c,n].join("."));else if(s){if(i.listeners[r][s]){for(var o in i.listeners[r][s])i.off(e,[s,o].join("."));delete i.listeners[r][s]}}else{for(var c in i.listeners[r])i.off(e,c);delete i.listeners[r],delete i.handlerMap[r]}},i.extend(i.Element,{on:function(e,t,a,r){return i.on(this.node,e,t,a,r),this},off:function(e,t){return i.off(this.node,e,t),this},fire:function(t,a){return t instanceof e.Event?this.node.dispatchEvent(t):this.node.dispatchEvent(t=new i.CustomEvent(t,{detail:a,cancelable:!0})),this._event=t,this},event:function(){return this._event}}),i.Defs=i.invent({create:"defs",inherit:i.Container}),i.G=i.invent({create:"g",inherit:i.Container,extend:{x:function(e){return null==e?this.transform("x"):this.transform({x:e-this.x()},!0)}},construct:{group:function(){return this.put(new i.G)}}}),i.Doc=i.invent({create:function(e){e&&("svg"==(e="string"==typeof e?t.getElementById(e):e).nodeName?this.constructor.call(this,e):(this.constructor.call(this,i.create("svg")),e.appendChild(this.node),this.size("100%","100%")),this.namespace().defs())},inherit:i.Container,extend:{namespace:function(){return this.attr({xmlns:i.ns,version:"1.1"}).attr("xmlns:xlink",i.xlink,i.xmlns).attr("xmlns:svgjs",i.svgjs,i.xmlns)},defs:function(){var e;return this._defs||((e=this.node.getElementsByTagName("defs")[0])?this._defs=i.adopt(e):this._defs=new i.Defs,this.node.appendChild(this._defs.node)),this._defs},parent:function(){return this.node.parentNode&&"#document"!=this.node.parentNode.nodeName?this.node.parentNode:null},remove:function(){return this.parent()&&this.parent().removeChild(this.node),this},clear:function(){for(;this.node.hasChildNodes();)this.node.removeChild(this.node.lastChild);return delete this._defs,i.parser.draw&&!i.parser.draw.parentNode&&this.node.appendChild(i.parser.draw),this},clone:function(e){this.writeDataToDom();var t=this.node,i=x(t.cloneNode(!0));return e?(e.node||e).appendChild(i.node):t.parentNode.insertBefore(i.node,t.nextSibling),i}}}),i.extend(i.Element,{}),i.Gradient=i.invent({create:function(e){this.constructor.call(this,i.create(e+"Gradient")),this.type=e},inherit:i.Container,extend:{at:function(e,t,a){return this.put(new i.Stop).update(e,t,a)},update:function(e){return this.clear(),"function"==typeof e&&e.call(this,this),this},fill:function(){return"url(#"+this.id()+")"},toString:function(){return this.fill()},attr:function(e,t,a){return"transform"==e&&(e="gradientTransform"),i.Container.prototype.attr.call(this,e,t,a)}},construct:{gradient:function(e,t){return this.defs().gradient(e,t)}}}),i.extend(i.Gradient,i.FX,{from:function(e,t){return"radial"==(this._target||this).type?this.attr({fx:new i.Number(e),fy:new i.Number(t)}):this.attr({x1:new i.Number(e),y1:new i.Number(t)})},to:function(e,t){return"radial"==(this._target||this).type?this.attr({cx:new i.Number(e),cy:new i.Number(t)}):this.attr({x2:new i.Number(e),y2:new i.Number(t)})}}),i.extend(i.Defs,{gradient:function(e,t){return this.put(new i.Gradient(e)).update(t)}}),i.Stop=i.invent({create:"stop",inherit:i.Element,extend:{update:function(e){return("number"==typeof e||e instanceof i.Number)&&(e={offset:arguments[0],color:arguments[1],opacity:arguments[2]}),null!=e.opacity&&this.attr("stop-opacity",e.opacity),null!=e.color&&this.attr("stop-color",e.color),null!=e.offset&&this.attr("offset",new i.Number(e.offset)),this}}}),i.Pattern=i.invent({create:"pattern",inherit:i.Container,extend:{fill:function(){return"url(#"+this.id()+")"},update:function(e){return this.clear(),"function"==typeof e&&e.call(this,this),this},toString:function(){return this.fill()},attr:function(e,t,a){return"transform"==e&&(e="patternTransform"),i.Container.prototype.attr.call(this,e,t,a)}},construct:{pattern:function(e,t,i){return this.defs().pattern(e,t,i)}}}),i.extend(i.Defs,{pattern:function(e,t,a){return this.put(new i.Pattern).update(a).attr({x:0,y:0,width:e,height:t,patternUnits:"userSpaceOnUse"})}}),i.Shape=i.invent({create:function(e){this.constructor.call(this,e)},inherit:i.Element}),i.Symbol=i.invent({create:"symbol",inherit:i.Container,construct:{symbol:function(){return this.put(new i.Symbol)}}}),i.Use=i.invent({create:"use",inherit:i.Shape,extend:{element:function(e,t){return this.attr("href",(t||"")+"#"+e,i.xlink)}},construct:{use:function(e,t){return this.put(new i.Use).element(e,t)}}}),i.Rect=i.invent({create:"rect",inherit:i.Shape,construct:{rect:function(e,t){return this.put(new i.Rect).size(e,t)}}}),i.Circle=i.invent({create:"circle",inherit:i.Shape,construct:{circle:function(e){return this.put(new i.Circle).rx(new i.Number(e).divide(2)).move(0,0)}}}),i.extend(i.Circle,i.FX,{rx:function(e){return this.attr("r",e)},ry:function(e){return this.rx(e)}}),i.Ellipse=i.invent({create:"ellipse",inherit:i.Shape,construct:{ellipse:function(e,t){return this.put(new i.Ellipse).size(e,t).move(0,0)}}}),i.extend(i.Ellipse,i.Rect,i.FX,{rx:function(e){return this.attr("rx",e)},ry:function(e){return this.attr("ry",e)}}),i.extend(i.Circle,i.Ellipse,{x:function(e){return null==e?this.cx()-this.rx():this.cx(e+this.rx())},y:function(e){return null==e?this.cy()-this.ry():this.cy(e+this.ry())},cx:function(e){return null==e?this.attr("cx"):this.attr("cx",e)},cy:function(e){return null==e?this.attr("cy"):this.attr("cy",e)},width:function(e){return null==e?2*this.rx():this.rx(new i.Number(e).divide(2))},height:function(e){return null==e?2*this.ry():this.ry(new i.Number(e).divide(2))},size:function(e,t){var a=g(this,e,t);return this.rx(new i.Number(a.width).divide(2)).ry(new i.Number(a.height).divide(2))}}),i.Line=i.invent({create:"line",inherit:i.Shape,extend:{array:function(){return new i.PointArray([[this.attr("x1"),this.attr("y1")],[this.attr("x2"),this.attr("y2")]])},plot:function(e,t,a,r){return null==e?this.array():(e=void 0!==t?{x1:e,y1:t,x2:a,y2:r}:new i.PointArray(e).toLine(),this.attr(e))},move:function(e,t){return this.attr(this.array().move(e,t).toLine())},size:function(e,t){var i=g(this,e,t);return this.attr(this.array().size(i.width,i.height).toLine())}},construct:{line:function(e,t,a,r){return i.Line.prototype.plot.apply(this.put(new i.Line),null!=e?[e,t,a,r]:[0,0,0,0])}}}),i.Polyline=i.invent({create:"polyline",inherit:i.Shape,construct:{polyline:function(e){return this.put(new i.Polyline).plot(e||new i.PointArray)}}}),i.Polygon=i.invent({create:"polygon",inherit:i.Shape,construct:{polygon:function(e){return this.put(new i.Polygon).plot(e||new i.PointArray)}}}),i.extend(i.Polyline,i.Polygon,{array:function(){return this._array||(this._array=new i.PointArray(this.attr("points")))},plot:function(e){return null==e?this.array():this.clear().attr("points","string"==typeof e?e:this._array=new i.PointArray(e))},clear:function(){return delete this._array,this},move:function(e,t){return this.attr("points",this.array().move(e,t))},size:function(e,t){var i=g(this,e,t);return this.attr("points",this.array().size(i.width,i.height))}}),i.extend(i.Line,i.Polyline,i.Polygon,{morphArray:i.PointArray,x:function(e){return null==e?this.bbox().x:this.move(e,this.bbox().y)},y:function(e){return null==e?this.bbox().y:this.move(this.bbox().x,e)},width:function(e){var t=this.bbox();return null==e?t.width:this.size(e,t.height)},height:function(e){var t=this.bbox();return null==e?t.height:this.size(t.width,e)}}),i.Path=i.invent({create:"path",inherit:i.Shape,extend:{morphArray:i.PathArray,array:function(){return this._array||(this._array=new i.PathArray(this.attr("d")))},plot:function(e){return null==e?this.array():this.clear().attr("d","string"==typeof e?e:this._array=new i.PathArray(e))},clear:function(){return delete this._array,this}},construct:{path:function(e){return this.put(new i.Path).plot(e||new i.PathArray)}}}),i.Image=i.invent({create:"image",inherit:i.Shape,extend:{load:function(t){if(!t)return this;var a=this,r=new e.Image;return i.on(r,"load",(function(){i.off(r);var e=a.parent(i.Pattern);null!==e&&(0==a.width()&&0==a.height()&&a.size(r.width,r.height),e&&0==e.width()&&0==e.height()&&e.size(a.width(),a.height()),"function"==typeof a._loaded&&a._loaded.call(a,{width:r.width,height:r.height,ratio:r.width/r.height,url:t}))})),i.on(r,"error",(function(e){i.off(r),"function"==typeof a._error&&a._error.call(a,e)})),this.attr("href",r.src=this.src=t,i.xlink)},loaded:function(e){return this._loaded=e,this},error:function(e){return this._error=e,this}},construct:{image:function(e,t,a){return this.put(new i.Image).load(e).size(t||0,a||t||0)}}}),i.Text=i.invent({create:function(){this.constructor.call(this,i.create("text")),this.dom.leading=new i.Number(1.3),this._rebuild=!0,this._build=!1,this.attr("font-family",i.defaults.attrs["font-family"])},inherit:i.Shape,extend:{x:function(e){return null==e?this.attr("x"):this.attr("x",e)},text:function(e){if(void 0===e){e="";for(var t=this.node.childNodes,a=0,r=t.length;a<r;++a)0!=a&&3!=t[a].nodeType&&1==i.adopt(t[a]).dom.newLined&&(e+="\n"),e+=t[a].textContent;return e}if(this.clear().build(!0),"function"==typeof e)e.call(this,this);else{a=0;for(var s=(e=e.split("\n")).length;a<s;a++)this.tspan(e[a]).newLine()}return this.build(!1).rebuild()},size:function(e){return this.attr("font-size",e).rebuild()},leading:function(e){return null==e?this.dom.leading:(this.dom.leading=new i.Number(e),this.rebuild())},lines:function(){var e=(this.textPath&&this.textPath()||this).node,t=i.utils.map(i.utils.filterSVGElements(e.childNodes),(function(e){return i.adopt(e)}));return new i.Set(t)},rebuild:function(e){if("boolean"==typeof e&&(this._rebuild=e),this._rebuild){var t=this,a=0,r=this.dom.leading*new i.Number(this.attr("font-size"));this.lines().each((function(){this.dom.newLined&&(t.textPath()||this.attr("x",t.attr("x")),"\n"==this.text()?a+=r:(this.attr("dy",r+a),a=0))})),this.fire("rebuild")}return this},build:function(e){return this._build=!!e,this},setData:function(e){return this.dom=e,this.dom.leading=new i.Number(e.leading||1.3),this}},construct:{text:function(e){return this.put(new i.Text).text(e)},plain:function(e){return this.put(new i.Text).plain(e)}}}),i.Tspan=i.invent({create:"tspan",inherit:i.Shape,extend:{text:function(e){return null==e?this.node.textContent+(this.dom.newLined?"\n":""):("function"==typeof e?e.call(this,this):this.plain(e),this)},dx:function(e){return this.attr("dx",e)},dy:function(e){return this.attr("dy",e)},newLine:function(){var e=this.parent(i.Text);return this.dom.newLined=!0,this.dy(e.dom.leading*e.attr("font-size")).attr("x",e.x())}}}),i.extend(i.Text,i.Tspan,{plain:function(e){return!1===this._build&&this.clear(),this.node.appendChild(t.createTextNode(e)),this},tspan:function(e){var t=(this.textPath&&this.textPath()||this).node,a=new i.Tspan;return!1===this._build&&this.clear(),t.appendChild(a.node),a.text(e)},clear:function(){for(var e=(this.textPath&&this.textPath()||this).node;e.hasChildNodes();)e.removeChild(e.lastChild);return this},length:function(){return this.node.getComputedTextLength()}}),i.TextPath=i.invent({create:"textPath",inherit:i.Parent,parent:i.Text,construct:{morphArray:i.PathArray,array:function(){var e=this.track();return e?e.array():null},plot:function(e){var t=this.track(),i=null;return t&&(i=t.plot(e)),null==e?i:this},track:function(){var e=this.textPath();if(e)return e.reference("href")},textPath:function(){if(this.node.firstChild&&"textPath"==this.node.firstChild.nodeName)return i.adopt(this.node.firstChild)}}}),i.Nested=i.invent({create:function(){this.constructor.call(this,i.create("svg")),this.style("overflow","visible")},inherit:i.Container,construct:{nested:function(){return this.put(new i.Nested)}}});var l={stroke:["color","width","opacity","linecap","linejoin","miterlimit","dasharray","dashoffset"],fill:["color","opacity","rule"],prefix:function(e,t){return"color"==t?e:e+"-"+t}};function c(e,t,a,r){return a+r.replace(i.regex.dots," .")}function h(e){return e.toLowerCase().replace(/-(.)/g,(function(e,t){return t.toUpperCase()}))}function d(e){return e.charAt(0).toUpperCase()+e.slice(1)}function u(e){var t=e.toString(16);return 1==t.length?"0"+t:t}function g(e,t,i){if(null==t||null==i){var a=e.bbox();null==t?t=a.width/a.height*i:null==i&&(i=a.height/a.width*t)}return{width:t,height:i}}function f(e,t,i){return{x:t*e.a+i*e.c+0,y:t*e.b+i*e.d+0}}function p(e){return{a:e[0],b:e[1],c:e[2],d:e[3],e:e[4],f:e[5]}}function x(t){for(var a=t.childNodes.length-1;a>=0;a--)t.childNodes[a]instanceof e.SVGElement&&x(t.childNodes[a]);return i.adopt(t).id(i.eid(t.nodeName))}function b(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||i.Color.isRgb(t)||t&&"function"==typeof t.fill)this.attr(e,t);else for(var a=l[e].length-1;a>=0;a--)null!=t[l[e][a]]&&this.attr(l.prefix(e,l[e][a]),t[l[e][a]]);return this},i.extend(i.Element,i.FX,t)})),i.extend(i.Element,i.FX,{translate:function(e,t){return this.transform({x:e,y:t})},matrix:function(e){return this.attr("transform",new i.Matrix(6==arguments.length?[].slice.call(arguments):e))},opacity:function(e){return this.attr("opacity",e)},dx:function(e){return this.x(new i.Number(e).plus(this instanceof i.FX?0:this.x()),!0)},dy:function(e){return this.y(new i.Number(e).plus(this instanceof i.FX?0:this.y()),!0)}}),i.extend(i.Path,{length:function(){return this.node.getTotalLength()},pointAt:function(e){return this.node.getPointAtLength(e)}}),i.Set=i.invent({create:function(e){Array.isArray(e)?this.members=e:this.clear()},extend:{add:function(){for(var e=[].slice.call(arguments),t=0,i=e.length;t<i;t++)this.members.push(e[t]);return this},remove:function(e){var t=this.index(e);return t>-1&&this.members.splice(t,1),this},each:function(e){for(var t=0,i=this.members.length;t<i;t++)e.apply(this.members[t],[t,this.members]);return this},clear:function(){return this.members=[],this},length:function(){return this.members.length},has:function(e){return this.index(e)>=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 i.Set(e)}}}),i.FX.Set=i.invent({create:function(e){this.set=e}}),i.Set.inherit=function(){var e=[];for(var t in i.Shape.prototype)"function"==typeof i.Shape.prototype[t]&&"function"!=typeof i.Set.prototype[t]&&e.push(t);for(var t in e.forEach((function(e){i.Set.prototype[e]=function(){for(var t=0,a=this.members.length;t<a;t++)this.members[t]&&"function"==typeof this.members[t][e]&&this.members[t][e].apply(this.members[t],arguments);return"animate"==e?this.fx||(this.fx=new i.FX.Set(this)):this}})),e=[],i.FX.prototype)"function"==typeof i.FX.prototype[t]&&"function"!=typeof i.FX.Set.prototype[t]&&e.push(t);e.forEach((function(e){i.FX.Set.prototype[e]=function(){for(var t=0,i=this.set.members.length;t<i;t++)this.set.members[t].fx[e].apply(this.set.members[t].fx,arguments);return this}}))},i.extend(i.Element,{}),i.extend(i.Element,{remember:function(e,t){if("object"===s(arguments[0]))for(var i in e)this.remember(i,e[i]);else{if(1==arguments.length)return this.memory()[e];this.memory()[e]=t}return this},forget:function(){if(0==arguments.length)this._memory={};else for(var e=arguments.length-1;e>=0;e--)delete this.memory()[arguments[e]];return this},memory:function(){return this._memory||(this._memory={})}}),i.get=function(e){var a=t.getElementById(function(e){var t=(e||"").toString().match(i.regex.reference);if(t)return t[1]}(e)||e);return i.adopt(a)},i.select=function(e,a){return new i.Set(i.utils.map((a||t).querySelectorAll(e),(function(e){return i.adopt(e)})))},i.extend(i.Parent,{select:function(e){return i.select(e,this.node)}});var v="abcdef".split("");if("function"!=typeof e.CustomEvent){var m=function(e,i){i=i||{bubbles:!1,cancelable:!1,detail:void 0};var a=t.createEvent("CustomEvent");return a.initCustomEvent(e,i.bubbles,i.cancelable,i.detail),a};m.prototype=e.Event.prototype,i.CustomEvent=m}else i.CustomEvent=e.CustomEvent;return i}(r,r.document)}.call(t,i,t,e),void 0===a||(e.exports=a)},539:(e,t,i)=>{"use strict";i.r(t),i.d(t,{default:()=>o});var a=i(499),r=i.n(a),s=i(922),n=i.n(s)()(r());n.push([e.id,'@keyframes opaque {\n 0% {\n opacity: 0\n }\n\n to {\n opacity: 1\n }\n}\n\n@keyframes resizeanim {\n\n 0%,\n 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\nrect.legend-mouseover-inactive,\n.legend-mouseover-inactive rect,\n.legend-mouseover-inactive path,\n.legend-mouseover-inactive circle,\n.legend-mouseover-inactive line,\n.legend-mouseover-inactive text.apexcharts-yaxis-title-text,\n.legend-mouseover-inactive text.apexcharts-yaxis-label {\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,\n.apexcharts-tooltip-text-y-value,\n.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,\n.apexcharts-tooltip-text-goals-value:empty,\n.apexcharts-tooltip-text-y-label:empty,\n.apexcharts-tooltip-text-y-value:empty,\n.apexcharts-tooltip-text-z-value:empty,\n.apexcharts-tooltip-title:empty {\n display: none\n}\n\n.apexcharts-tooltip-text-goals-label,\n.apexcharts-tooltip-text-goals-value {\n padding: 6px 0 5px\n}\n\n.apexcharts-tooltip-goals-group,\n.apexcharts-tooltip-text-goals-label,\n.apexcharts-tooltip-text-goals-value {\n display: flex\n}\n\n.apexcharts-tooltip-text-goals-label:not(:empty),\n.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,\n.apexcharts-tooltip-series-group:last-child {\n padding-bottom: 4px\n}\n\n.apexcharts-tooltip-y-group {\n padding: 6px 0 5px\n}\n\n.apexcharts-custom-tooltip,\n.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,\n.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,\n.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,\n.apexcharts-xaxistooltip-bottom:before {\n bottom: 100%\n}\n\n.apexcharts-xaxistooltip-top:after,\n.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,\n.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,\n.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,\n.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,\n.apexcharts-yaxistooltip-left:before {\n left: 100%\n}\n\n.apexcharts-yaxistooltip-right:after,\n.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,\n.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,\n.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,\n.apexcharts-ycrosshairs {\n pointer-events: none;\n opacity: 0;\n transition: .15s ease all\n}\n\n.apexcharts-xcrosshairs.apexcharts-active,\n.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,\n.svg_select_points_rot {\n pointer-events: none;\n opacity: 0;\n visibility: hidden\n}\n\n.apexcharts-selection-rect+g .svg_select_boundingRect,\n.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,\n.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,\n.apexcharts-pan-icon,\n.apexcharts-reset-icon,\n.apexcharts-selection-icon,\n.apexcharts-toolbar-custom-icon,\n.apexcharts-zoom-icon,\n.apexcharts-zoomin-icon,\n.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,\n.apexcharts-reset-icon svg,\n.apexcharts-zoom-icon svg,\n.apexcharts-zoomin-icon svg,\n.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,\n.apexcharts-theme-dark .apexcharts-pan-icon svg,\n.apexcharts-theme-dark .apexcharts-reset-icon svg,\n.apexcharts-theme-dark .apexcharts-selection-icon svg,\n.apexcharts-theme-dark .apexcharts-toolbar-custom-icon svg,\n.apexcharts-theme-dark .apexcharts-zoom-icon svg,\n.apexcharts-theme-dark .apexcharts-zoomin-icon svg,\n.apexcharts-theme-dark .apexcharts-zoomout-icon svg {\n fill: #f3f4f5\n}\n\n.apexcharts-canvas .apexcharts-reset-zoom-icon.apexcharts-selected svg,\n.apexcharts-canvas .apexcharts-selection-icon.apexcharts-selected svg,\n.apexcharts-canvas .apexcharts-zoom-icon.apexcharts-selected svg {\n fill: #008ffb\n}\n\n.apexcharts-theme-light .apexcharts-menu-icon:hover svg,\n.apexcharts-theme-light .apexcharts-reset-icon:hover svg,\n.apexcharts-theme-light .apexcharts-selection-icon:not(.apexcharts-selected):hover svg,\n.apexcharts-theme-light .apexcharts-zoom-icon:not(.apexcharts-selected):hover svg,\n.apexcharts-theme-light .apexcharts-zoomin-icon:hover svg,\n.apexcharts-theme-light .apexcharts-zoomout-icon:hover svg {\n fill: #333\n}\n\n.apexcharts-menu-icon,\n.apexcharts-selection-icon {\n position: relative\n}\n\n.apexcharts-reset-icon {\n margin-left: 5px\n}\n\n.apexcharts-menu-icon,\n.apexcharts-reset-icon,\n.apexcharts-zoom-icon {\n transform: scale(.85)\n}\n\n.apexcharts-zoomin-icon,\n.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,\n.apexcharts-datalabel.apexcharts-element-hidden,\n.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\n.apexcharts-datalabel,\n.apexcharts-datalabel-label,\n.apexcharts-datalabel-value,\n.apexcharts-datalabels,\n.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,\n.apexcharts-area-series .apexcharts-area,\n.apexcharts-area-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,\n.apexcharts-gridline,\n.apexcharts-line,\n.apexcharts-line-series .apexcharts-series-markers .apexcharts-marker.no-pointer-events,\n.apexcharts-point-annotation-label,\n.apexcharts-radar-series path:not(.apexcharts-marker),\n.apexcharts-radar-series polygon,\n.apexcharts-toolbar svg,\n.apexcharts-tooltip .apexcharts-marker,\n.apexcharts-xaxis-annotation-label,\n.apexcharts-yaxis-annotation-label,\n.apexcharts-zoom-rect {\n pointer-events: none\n}\n\n.apexcharts-tooltip-active .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,\n.resize-triggers,\n.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}',""]);const o=n},274:(e,t,i)=>{var a=i(379),r=i(539);"string"==typeof(r=r.__esModule?r.default:r)&&(r=[[e.id,r,""]]);var s=(a(e.id,r,{insert:"head",singleton:!1}),r.locals?r.locals:{});e.exports=s},379:(e,t,i)=>{"use strict";var a,r=function(){var e={};return function(t){if(void 0===e[t]){var i=document.querySelector(t);if(window.HTMLIFrameElement&&i instanceof window.HTMLIFrameElement)try{i=i.contentDocument.head}catch(e){i=null}e[t]=i}return e[t]}}(),s={};function n(e,t,i){for(var a=0;a<t.length;a++){var r={css:t[a][1],media:t[a][2],sourceMap:t[a][3]};s[e][a]?s[e][a](r):s[e].push(f(r,i))}}function o(e){var t=document.createElement("style"),a=e.attributes||{};if(void 0===a.nonce){var s=i.nc;s&&(a.nonce=s)}if(Object.keys(a).forEach((function(e){t.setAttribute(e,a[e])})),"function"==typeof e.insert)e.insert(t);else{var n=r(e.insert||"head");if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(t)}return t}var l,c=(l=[],function(e,t){return l[e]=t,l.filter(Boolean).join("\n")});function h(e,t,i,a){var r=i?"":a.css;if(e.styleSheet)e.styleSheet.cssText=c(t,r);else{var s=document.createTextNode(r),n=e.childNodes;n[t]&&e.removeChild(n[t]),n.length?e.insertBefore(s,n[t]):e.appendChild(s)}}function d(e,t,i){var a=i.css,r=i.media,s=i.sourceMap;if(r?e.setAttribute("media",r):e.removeAttribute("media"),s&&btoa&&(a+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(s))))," */")),e.styleSheet)e.styleSheet.cssText=a;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(a))}}var u=null,g=0;function f(e,t){var i,a,r;if(t.singleton){var s=g++;i=u||(u=o(t)),a=h.bind(null,i,s,!1),r=h.bind(null,i,s,!0)}else i=o(t),a=d.bind(null,i,t),r=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(i)};return a(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;a(e=t)}else r()}}e.exports=function(e,t,i){return(i=i||{}).singleton||"boolean"==typeof i.singleton||(i.singleton=(void 0===a&&(a=Boolean(window&&document&&document.all&&!window.atob)),a)),e=i.base?e+i.base:e,t=t||[],s[e]||(s[e]=[]),n(e,t,i),function(t){if(t=t||[],"[object Array]"===Object.prototype.toString.call(t)){s[e]||(s[e]=[]),n(e,t,i);for(var a=t.length;a<s[e].length;a++)s[e][a]();s[e].length=t.length,0===s[e].length&&delete s[e]}}}},149:e=>{e.exports='<svg fill="#000000" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"></path><path d="M0 0h24v24H0z" fill="none"></path></svg>'},355:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"></path><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"></path></svg>'},686:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M0 0h24v24H0z" fill="none"></path><path d="M7 11v2h10v-2H7zm5-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"></path></svg>'},798:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="#000000" viewBox="0 0 24 24"><defs><path d="M0 0h24v24H0z" id="a"></path></defs><clipPath id="b"><use overflow="visible" xlink:href="#a"></use></clipPath><path clip-path="url(#b)" d="M23 5.5V20c0 2.2-1.8 4-4 4h-7.3c-1.08 0-2.1-.43-2.85-1.19L1 14.83s1.26-1.23 1.3-1.25c.22-.19.49-.29.79-.29.22 0 .42.06.6.16.04.01 4.31 2.46 4.31 2.46V4c0-.83.67-1.5 1.5-1.5S11 3.17 11 4v7h1V1.5c0-.83.67-1.5 1.5-1.5S15 .67 15 1.5V11h1V2.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V11h1V5.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5z"></path></svg>'},323:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M0 0h24v24H0z" fill="none"></path><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"></path></svg>'},618:e=>{e.exports='<svg fill="#6E8192" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h24v24H0z" fill="none"></path><path d="M3 5h2V3c-1.1 0-2 .9-2 2zm0 8h2v-2H3v2zm4 8h2v-2H7v2zM3 9h2V7H3v2zm10-6h-2v2h2V3zm6 0v2h2c0-1.1-.9-2-2-2zM5 21v-2H3c0 1.1.9 2 2 2zm-2-4h2v-2H3v2zM9 3H7v2h2V3zm2 18h2v-2h-2v2zm8-8h2v-2h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2zm0-12h2V7h-2v2zm0 8h2v-2h-2v2zm-4 4h2v-2h-2v2zm0-16h2V3h-2v2z"></path></svg>'},688:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" fill="#000000" viewBox="0 0 24 24"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"></path><path d="M0 0h24v24H0V0z" fill="none"></path><path d="M12 10h-2v2H9v-2H7V9h2V7h1v2h2v1z"></path></svg>'}},t={};function i(a){var r=t[a];if(void 0!==r)return r.exports;var s=t[a]={id:a,exports:{}};return e[a].call(s.exports,s,s.exports,i),s.exports}i.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},i.d=(e,t)=>{for(var a in t)i.o(t,a)&&!i.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nc=void 0;var a={};return(()=>{"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}i.r(a),i.d(a,{default:()=>Ha});const r=function(){function i(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i)}var a,r,s;return a=i,s=[{key:"bind",value:function(e,t){return function(){return e.apply(t,arguments)}}},{key:"isObject",value:function(t){return t&&"object"===e(t)&&!Array.isArray(t)&&null!=t}},{key:"is",value:function(e,t){return Object.prototype.toString.call(t)==="[object "+e+"]"}},{key:"listToArray",value:function(e){var t,i=[];for(t=0;t<e.length;t++)i[t]=e[t];return i}},{key:"extend",value:function(e,t){var i=this;"function"!=typeof Object.assign&&(Object.assign=function(e){if(null==e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),i=1;i<arguments.length;i++){var a=arguments[i];if(null!=a)for(var r in a)a.hasOwnProperty(r)&&(t[r]=a[r])}return t});var a=Object.assign({},e);return this.isObject(e)&&this.isObject(t)&&Object.keys(t).forEach((function(r){i.isObject(t[r])&&r in e?a[r]=i.extend(e[r],t[r]):Object.assign(a,function(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}({},r,t[r]))})),a}},{key:"extendArray",value:function(e,t){var a=[];return e.map((function(e){a.push(i.extend(t,e))})),a}},{key:"monthMod",value:function(e){return e%12}},{key:"clone",value:function(t){if(i.is("Array",t)){for(var a=[],r=0;r<t.length;r++)a[r]=this.clone(t[r]);return a}if(i.is("Null",t))return null;if(i.is("Date",t))return t;if("object"===e(t)){var s={};for(var n in t)t.hasOwnProperty(n)&&(s[n]=this.clone(t[n]));return s}return t}},{key:"log10",value:function(e){return Math.log(e)/Math.LN10}},{key:"roundToBase10",value:function(e){return Math.pow(10,Math.floor(Math.log10(e)))}},{key:"roundToBase",value:function(e,t){return Math.pow(t,Math.floor(Math.log(e)/Math.log(t)))}},{key:"parseNumber",value:function(e){return null===e?e:parseFloat(e)}},{key:"stripNumber",value:function(e){var t=arguments.length>1&&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 i="",a=e<0?"-":"",r=t[0].replace(".",""),s=Number(t[1])+1;if(s<0){for(i=a+"0.";s++;)i+="0";return i+r.replace(/^-/,"")}for(s-=r.length;s--;)i+="0";return r+i}},{key:"getDimensions",value:function(e){var t=getComputedStyle(e,null),i=e.clientHeight,a=e.clientWidth;return i-=parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),[a-=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight),i]}},{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 i=e.replace("#","");i=i.match(new RegExp("(.{"+i.length/3+"})","g"));for(var a=0;a<i.length;a++)i[a]=parseInt(1===i[a].length?i[a]+i[a]:i[a],16);return void 0!==t&&i.push(t),"rgba("+i.join(",")+")"}},{key:"getOpacityFromRGBA",value:function(e){return parseFloat(e.replace(/^.*,(.+)\)/,"$1"))}},{key:"rgb2hex",value:function(e){return(e=e.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i))&&4===e.length?"#"+("0"+parseInt(e[1],10).toString(16)).slice(-2)+("0"+parseInt(e[2],10).toString(16)).slice(-2)+("0"+parseInt(e[3],10).toString(16)).slice(-2):""}},{key:"isColorHex",value:function(e){return/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)|(^#[0-9A-F]{8}$)/i.test(e)}},{key:"getPolygonPos",value:function(e,t){for(var i=[],a=2*Math.PI/t,r=0;r<t;r++){var s={};s.x=e*Math.sin(r*a),s.y=-e*Math.cos(r*a),i.push(s)}return i}},{key:"polarToCartesian",value:function(e,t,i,a){var r=(a-90)*Math.PI/180;return{x:e+i*Math.cos(r),y:t+i*Math.sin(r)}}},{key:"escapeString",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"x",i=e.toString().slice();return i.replace(/[` ~!@#$%^&*()|+\=?;:'",.<>{}[\]\\/]/gi,t)}},{key:"negToZero",value:function(e){return e<0?0:e}},{key:"moveIndexInArray",value:function(e,t,i){if(i>=e.length)for(var a=i-e.length+1;a--;)e.push(void 0);return e.splice(i,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 i in t)t.hasOwnProperty(i)&&(e.style.key=t[i])}},{key:"preciseAddition",value:function(e,t){var i=(String(e).split(".")[1]||"").length,a=(String(t).split(".")[1]||"").length,r=Math.pow(10,Math.max(i,a));return(Math.round(e*r)+Math.round(t*r))/r}},{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 i=e.indexOf("rv:");return parseInt(e.substring(i+3,e.indexOf(".",i)),10)}var a=e.indexOf("Edge/");return a>0&&parseInt(e.substring(a+5,e.indexOf(".",a)),10)}},{key:"getGCD",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:7,a=Math.pow(10,i-Math.floor(Math.log10(Math.max(e,t))));for(e=Math.round(Math.abs(e)*a),t=Math.round(Math.abs(t)*a);t;){var r=t;t=e%t,e=r}return e/a}},{key:"getPrimeFactors",value:function(e){for(var t=[],i=2;e>=2;)e%i==0?(t.push(i),e/=i):i++;return t}},{key:"mod",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:7,a=Math.pow(10,i-Math.floor(Math.log10(Math.max(e,t))));return(e=Math.round(Math.abs(e)*a))%(t=Math.round(Math.abs(t)*a))/a}}],(r=[{key:"shadeRGBColor",value:function(e,t){var i=t.split(","),a=e<0?0:255,r=e<0?-1*e:e,s=parseInt(i[0].slice(4),10),n=parseInt(i[1],10),o=parseInt(i[2],10);return"rgb("+(Math.round((a-s)*r)+s)+","+(Math.round((a-n)*r)+n)+","+(Math.round((a-o)*r)+o)+")"}},{key:"shadeHexColor",value:function(e,t){var i=parseInt(t.slice(1),16),a=e<0?0:255,r=e<0?-1*e:e,s=i>>16,n=i>>8&255,o=255&i;return"#"+(16777216+65536*(Math.round((a-s)*r)+s)+256*(Math.round((a-n)*r)+n)+(Math.round((a-o)*r)+o)).toString(16).slice(1)}},{key:"shadeColor",value:function(e,t){return i.isColorHex(t)?this.shadeHexColor(e,t):this.shadeRGBColor(e,t)}}])&&t(a.prototype,r),s&&t(a,s),i}();function s(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var n=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.setEasingFunctions()}var t,i;return t=e,(i=[{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,i,a){e.attr(t).animate(a).attr(i)}},{key:"animateMarker",value:function(e,t,i,a){e.attr({opacity:0}).animate(t,i).attr({opacity:1}).afterAll((function(){a()}))}},{key:"animateRect",value:function(e,t,i,a,r){e.attr(t).animate(a).attr(i).afterAll((function(){return r()}))}},{key:"animatePathsGradually",value:function(e){var t=e.el,i=e.realIndex,a=e.j,r=e.fill,s=e.pathFrom,n=e.pathTo,o=e.speed,l=e.delay,c=this.w,h=0;c.config.chart.animations.animateGradually.enabled&&(h=c.config.chart.animations.animateGradually.delay),c.config.chart.animations.dynamicAnimation.enabled&&c.globals.dataChanged&&"bar"!==c.config.chart.type&&(h=0),this.morphSVG(t,i,a,"line"!==c.config.chart.type||c.globals.comboCharts?r:"stroke",s,n,o,l*h)}},{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,i,a,s,n,o,l){var c=this,h=this.w;s||(s=e.attr("pathFrom")),n||(n=e.attr("pathTo"));var d=function(e){return"radar"===h.config.chart.type&&(o=1),"M 0 ".concat(h.globals.gridHeight)};(!s||s.indexOf("undefined")>-1||s.indexOf("NaN")>-1)&&(s=d()),(!n||n.indexOf("undefined")>-1||n.indexOf("NaN")>-1)&&(n=d()),h.globals.shouldAnimate||(o=1),e.plot(s).animate(1,h.globals.easing,l).plot(s).animate(o,h.globals.easing,l).plot(n).afterAll((function(){r.isNumber(i)?i===h.globals.series[h.globals.maxValsInArrayIndex].length-2&&h.globals.shouldAnimate&&c.animationCompleted(e):"none"!==a&&h.globals.shouldAnimate&&(!h.globals.comboCharts&&t===h.globals.series.length-1||h.globals.comboCharts)&&c.animationCompleted(e),c.showDelayedElements()}))}}])&&s(t.prototype,i),e}();function o(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const l=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"getDefaultFilter",value:function(e,t){var i=this.w;e.unfilter(!0),(new window.SVG.Filter).size("120%","180%","-5%","-40%"),"none"!==i.config.states.normal.filter?this.applyFilter(e,t,i.config.states.normal.filter.type,i.config.states.normal.filter.value):i.config.chart.dropShadow.enabled&&this.dropShadow(e,i.config.chart.dropShadow,t)}},{key:"addNormalFilter",value:function(e,t){var i=this.w;i.config.chart.dropShadow.enabled&&!e.node.classList.contains("apexcharts-marker")&&this.dropShadow(e,i.config.chart.dropShadow,t)}},{key:"addLightenFilter",value:function(e,t,i){var a=this,r=this.w,s=i.intensity;e.unfilter(!0),new window.SVG.Filter,e.filter((function(e){var i=r.config.chart.dropShadow;(i.enabled?a.addShadow(e,t,i):e).componentTransfer({rgb:{type:"linear",slope:1.5,intercept:s}})})),e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)}},{key:"addDarkenFilter",value:function(e,t,i){var a=this,r=this.w,s=i.intensity;e.unfilter(!0),new window.SVG.Filter,e.filter((function(e){var i=r.config.chart.dropShadow;(i.enabled?a.addShadow(e,t,i):e).componentTransfer({rgb:{type:"linear",slope:s}})})),e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)}},{key:"applyFilter",value:function(e,t,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:.5;switch(i){case"none":this.addNormalFilter(e,t);break;case"lighten":this.addLightenFilter(e,t,{intensity:a});break;case"darken":this.addDarkenFilter(e,t,{intensity:a})}}},{key:"addShadow",value:function(e,t,i){var a,r=this.w,s=i.blur,n=i.top,o=i.left,l=i.color,c=i.opacity;if((null===(a=r.config.chart.dropShadow.enabledOnSeries)||void 0===a?void 0:a.length)>0&&-1===r.config.chart.dropShadow.enabledOnSeries.indexOf(t))return e;var h=e.flood(Array.isArray(l)?l[t]:l,c).composite(e.sourceAlpha,"in").offset(o,n).gaussianBlur(s).merge(e.source);return e.blend(e.source,h)}},{key:"dropShadow",value:function(e,t){var i,a,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,n=t.top,o=t.left,l=t.blur,c=t.color,h=t.opacity,d=t.noUserSpaceOnUse,u=this.w;return e.unfilter(!0),r.isIE()&&"radialBar"===u.config.chart.type||(null===(i=u.config.chart.dropShadow.enabledOnSeries)||void 0===i?void 0:i.length)>0&&-1===(null===(a=u.config.chart.dropShadow.enabledOnSeries)||void 0===a?void 0:a.indexOf(s))||(c=Array.isArray(c)?c[s]:c,e.filter((function(e){var t;t=r.isSafari()||r.isFirefox()||r.isIE()?e.flood(c,h).composite(e.sourceAlpha,"in").offset(o,n).gaussianBlur(l):e.flood(c,h).composite(e.sourceAlpha,"in").offset(o,n).gaussianBlur(l).merge(e.source),e.blend(e.source,t)})),d||e.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(e.filterer.node)),e}},{key:"setSelectionFilter",value:function(e,t,i){var a=this.w;if(void 0!==a.globals.selectedDataPoints[t]&&a.globals.selectedDataPoints[t].indexOf(i)>-1){e.node.setAttribute("selected",!0);var r=a.config.states.active.filter;"none"!==r&&this.applyFilter(e,t,r.type,r.value)}}},{key:"_scaleFilterSize",value:function(e){!function(t){for(var i in t)t.hasOwnProperty(i)&&e.setAttribute(i,t[i])}({width:"200%",height:"200%",x:"-50%",y:"-50%"})}}],i&&o(t.prototype,i),e}();function c(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function h(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?c(Object(i),!0).forEach((function(t){d(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):c(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function d(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function u(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const g=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i,a;return t=e,i=[{key:"roundPathCorners",value:function(e,t){function i(e,t,i){var r=t.x-e.x,s=t.y-e.y,n=Math.sqrt(r*r+s*s);return a(e,t,Math.min(1,i/n))}function a(e,t,i){return{x:e.x+(t.x-e.x)*i,y:e.y+(t.y-e.y)*i}}function r(e,t){e.length>2&&(e[e.length-2]=t.x,e[e.length-1]=t.y)}function s(e){return{x:parseFloat(e[e.length-2]),y:parseFloat(e[e.length-1])}}e.indexOf("NaN")>-1&&(e="");var n=e.split(/[,\s]/).reduce((function(e,t){var i=t.match("([a-zA-Z])(.+)");return i?(e.push(i[1]),e.push(i[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}),[]),o=[];if(n.length>1){var l=s(n[0]),c=null;"Z"==n[n.length-1][0]&&n[0].length>2&&(c=["L",l.x,l.y],n[n.length-1]=c),o.push(n[0]);for(var h=1;h<n.length;h++){var d=o[o.length-1],u=n[h],g=u==c?n[1]:n[h+1];if(g&&d&&d.length>2&&"L"==u[0]&&g.length>2&&"L"==g[0]){var f,p,x=s(d),b=s(u),v=s(g);f=i(b,x,t),p=i(b,v,t),r(u,f),u.origPoint=b,o.push(u);var m=a(f,b,.5),y=a(b,p,.5),w=["C",m.x,m.y,y.x,y.y,p.x,p.y];w.origPoint=b,o.push(w)}else o.push(u)}if(c){var k=s(o[o.length-1]);o.push(["Z"]),r(o[0],k)}}else o=n;return o.reduce((function(e,t){return e+t.join(" ")+" "}),"")}},{key:"drawLine",value:function(e,t,i,a){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"#a8a8a8",s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,n=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,o=arguments.length>7&&void 0!==arguments[7]?arguments[7]:"butt";return this.w.globals.dom.Paper.line().attr({x1:e,y1:t,x2:i,y2:a,stroke:r,"stroke-dasharray":s,"stroke-width":n,"stroke-linecap":o})}},{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,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"#fefefe",n=arguments.length>6&&void 0!==arguments[6]?arguments[6]:1,o=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,h=this.w.globals.dom.Paper.rect();return h.attr({x:e,y:t,width:i>0?i:0,height:a>0?a:0,rx:r,ry:r,opacity:n,"stroke-width":null!==o?o:0,stroke:null!==l?l:"none","stroke-dasharray":c}),h.node.setAttribute("fill",s),h}},{key:"drawPolygon",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"#e1e1e1",i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"none";return this.w.globals.dom.Paper.polygon(e).attr({fill:a,stroke:t,"stroke-width":i})}},{key:"drawCircle",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;e<0&&(e=0);var i=this.w.globals.dom.Paper.circle(2*e);return null!==t&&i.attr(t),i}},{key:"drawPath",value:function(e){var t=e.d,i=void 0===t?"":t,a=e.stroke,r=void 0===a?"#a8a8a8":a,s=e.strokeWidth,n=void 0===s?1:s,o=e.fill,l=e.fillOpacity,c=void 0===l?1:l,h=e.strokeOpacity,d=void 0===h?1:h,u=e.classes,g=e.strokeLinecap,f=void 0===g?null:g,p=e.strokeDashArray,x=void 0===p?0:p,b=this.w;return null===f&&(f=b.config.stroke.lineCap),(i.indexOf("undefined")>-1||i.indexOf("NaN")>-1)&&(i="M 0 ".concat(b.globals.gridHeight)),b.globals.dom.Paper.path(i).attr({fill:o,"fill-opacity":c,stroke:r,"stroke-opacity":d,"stroke-linecap":f,"stroke-width":n,"stroke-dasharray":x,class:u})}},{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 i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=null;return null===i?a=[" L",e,t].join(" "):"H"===i?a=[" H",e].join(" "):"V"===i&&(a=[" V",t].join(" ")),a}},{key:"curve",value:function(e,t,i,a,r,s){return["C",e,t,i,a,r,s].join(" ")}},{key:"quadraticCurve",value:function(e,t,i,a){return["Q",e,t,i,a].join(" ")}},{key:"arc",value:function(e,t,i,a,r,s,n){var o="A";return arguments.length>7&&void 0!==arguments[7]&&arguments[7]&&(o="a"),[o,e,t,i,a,r,s,n].join(" ")}},{key:"renderPaths",value:function(e){var t,i=e.j,a=e.realIndex,r=e.pathFrom,s=e.pathTo,o=e.stroke,c=e.strokeWidth,d=e.strokeLinecap,u=e.fill,g=e.animationDelay,f=e.initialSpeed,p=e.dataChangeSpeed,x=e.className,b=e.shouldClipToGrid,v=void 0===b||b,m=e.bindEventsOnPaths,y=void 0===m||m,w=e.drawShadow,k=void 0===w||w,A=this.w,S=new l(this.ctx),C=new n(this.ctx),P=this.w.config.chart.animations.enabled,L=P&&this.w.config.chart.animations.dynamicAnimation.enabled,O=!!(P&&!A.globals.resized||L&&A.globals.dataChanged&&A.globals.shouldAnimate);O?t=r:(t=s,A.globals.animationEnded=!0);var M,T=A.config.stroke.dashArray;M=Array.isArray(T)?T[a]:A.config.stroke.dashArray;var I=this.drawPath({d:t,stroke:o,strokeWidth:c,fill:u,fillOpacity:1,classes:x,strokeLinecap:d,strokeDashArray:M});if(I.attr("index",a),v&&I.attr({"clip-path":"url(#gridRectMask".concat(A.globals.cuid,")")}),"none"!==A.config.states.normal.filter.type)S.getDefaultFilter(I,a);else if(A.config.chart.dropShadow.enabled&&k){var E=A.config.chart.dropShadow;S.dropShadow(I,E,a)}y&&(I.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,I)),I.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,I)),I.node.addEventListener("mousedown",this.pathMouseDown.bind(this,I))),I.attr({pathTo:s,pathFrom:r});var z={el:I,j:i,realIndex:a,pathFrom:r,pathTo:s,fill:u,strokeWidth:c,delay:g};return!P||A.globals.resized||A.globals.dataChanged?!A.globals.resized&&A.globals.dataChanged||C.showDelayedElements():C.animatePathsGradually(h(h({},z),{},{speed:f})),A.globals.dataChanged&&L&&O&&C.animatePathsGradually(h(h({},z),{},{speed:p})),I}},{key:"drawPattern",value:function(e,t,i){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"#a8a8a8",r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;return this.w.globals.dom.Paper.pattern(t,i,(function(s){"horizontalLines"===e?s.line(0,0,i,0).stroke({color:a,width:r+1}):"verticalLines"===e?s.line(0,0,0,t).stroke({color:a,width:r+1}):"slantedLines"===e?s.line(0,0,t,i).stroke({color:a,width:r}):"squares"===e?s.rect(t,i).fill("none").stroke({color:a,width:r}):"circles"===e&&s.circle(t).fill("none").stroke({color:a,width:r})}))}},{key:"drawGradient",value:function(e,t,i,a,s){var n,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,l=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,h=arguments.length>8&&void 0!==arguments[8]?arguments[8]:0,d=this.w;t.length<9&&0===t.indexOf("#")&&(t=r.hexToRgba(t,a)),i.length<9&&0===i.indexOf("#")&&(i=r.hexToRgba(i,s));var u=0,g=1,f=1,p=null;null!==l&&(u=void 0!==l[0]?l[0]/100:0,g=void 0!==l[1]?l[1]/100:1,f=void 0!==l[2]?l[2]/100:1,p=void 0!==l[3]?l[3]/100:null);var x=!("donut"!==d.config.chart.type&&"pie"!==d.config.chart.type&&"polarArea"!==d.config.chart.type&&"bubble"!==d.config.chart.type);if(n=null===c||0===c.length?d.globals.dom.Paper.gradient(x?"radial":"linear",(function(e){e.at(u,t,a),e.at(g,i,s),e.at(f,i,s),null!==p&&e.at(p,t,a)})):d.globals.dom.Paper.gradient(x?"radial":"linear",(function(e){(Array.isArray(c[h])?c[h]:c).forEach((function(t){e.at(t.offset/100,t.color,t.opacity)}))})),x){var b=d.globals.gridWidth/2,v=d.globals.gridHeight/2;"bubble"!==d.config.chart.type?n.attr({gradientUnits:"userSpaceOnUse",cx:b,cy:v,r:o}):n.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else"vertical"===e?n.from(0,0).to(0,1):"diagonal"===e?n.from(0,0).to(1,1):"horizontal"===e?n.from(0,1).to(1,1):"diagonal2"===e&&n.from(1,0).to(0,1);return n}},{key:"getTextBasedOnMaxWidth",value:function(e){var t=e.text,i=e.maxWidth,a=e.fontSize,r=e.fontFamily,s=this.getTextRects(t,a,r),n=s.width/t.length,o=Math.floor(i/n);return i<s.width?t.slice(0,o-3)+"...":t}},{key:"drawText",value:function(e){var t=this,i=e.x,a=e.y,r=e.text,s=e.textAnchor,n=e.fontSize,o=e.fontFamily,l=e.fontWeight,c=e.foreColor,d=e.opacity,u=e.maxWidth,g=e.cssClass,f=void 0===g?"":g,p=e.isPlainText,x=void 0===p||p,b=e.dominantBaseline,v=void 0===b?"auto":b,m=this.w;void 0===r&&(r="");var y=r;s||(s="start"),c&&c.length||(c=m.config.chart.foreColor),o=o||m.config.chart.fontFamily,l=l||"regular";var w,k={maxWidth:u,fontSize:n=n||"11px",fontFamily:o};return Array.isArray(r)?w=m.globals.dom.Paper.text((function(e){for(var i=0;i<r.length;i++)y=r[i],u&&(y=t.getTextBasedOnMaxWidth(h({text:r[i]},k))),0===i?e.tspan(y):e.tspan(y).newLine()})):(u&&(y=this.getTextBasedOnMaxWidth(h({text:r},k))),w=x?m.globals.dom.Paper.plain(r):m.globals.dom.Paper.text((function(e){return e.tspan(y)}))),w.attr({x:i,y:a,"text-anchor":s,"dominant-baseline":v,"font-size":n,"font-family":o,"font-weight":l,fill:c,class:"apexcharts-text "+f}),w.node.style.fontFamily=o,w.node.style.opacity=d,w}},{key:"getMarkerPath",value:function(e,t,i,a){var r="";switch(i){case"cross":r="M ".concat(e-(a/=1.4)," ").concat(t-a," L ").concat(e+a," ").concat(t+a," M ").concat(e-a," ").concat(t+a," L ").concat(e+a," ").concat(t-a);break;case"plus":r="M ".concat(e-(a/=1.12)," ").concat(t," L ").concat(e+a," ").concat(t," M ").concat(e," ").concat(t-a," L ").concat(e," ").concat(t+a);break;case"star":case"sparkle":var s=5;a*=1.15,"sparkle"===i&&(a/=1.1,s=4);for(var n=Math.PI/s,o=0;o<=2*s;o++){var l=o*n,c=o%2==0?a:a/2;r+=(0===o?"M":"L")+(e+c*Math.sin(l))+","+(t-c*Math.cos(l))}r+="Z";break;case"triangle":r="M ".concat(e," ").concat(t-a," \n L ").concat(e+a," ").concat(t+a," \n L ").concat(e-a," ").concat(t+a," \n Z");break;case"square":case"rect":r="M ".concat(e-(a/=1.125)," ").concat(t-a," \n L ").concat(e+a," ").concat(t-a," \n L ").concat(e+a," ").concat(t+a," \n L ").concat(e-a," ").concat(t+a," \n Z");break;case"diamond":a*=1.05,r="M ".concat(e," ").concat(t-a," \n L ").concat(e+a," ").concat(t," \n L ").concat(e," ").concat(t+a," \n L ").concat(e-a," ").concat(t," \n Z");break;case"line":r="M ".concat(e-(a/=1.1)," ").concat(t," \n L ").concat(e+a," ").concat(t);break;default:a*=2,r="M ".concat(e,", ").concat(t," \n m -").concat(a/2,", 0 \n a ").concat(a/2,",").concat(a/2," 0 1,0 ").concat(a,",0 \n a ").concat(a/2,",").concat(a/2," 0 1,0 -").concat(a,",0")}return r}},{key:"drawMarkerShape",value:function(e,t,i,a,r){var s=this.drawPath({d:this.getMarkerPath(e,t,i,a,r),stroke:r.pointStrokeColor,strokeDashArray:r.pointStrokeDashArray,strokeWidth:r.pointStrokeWidth,fill:r.pointFillColor,fillOpacity:r.pointFillOpacity,strokeOpacity:r.pointStrokeOpacity});return s.attr({cx:e,cy:t,shape:r.shape,class:r.class?r.class:""}),s}},{key:"drawMarker",value:function(e,t,i){e=e||0;var a=i.pSize||0;return r.isNumber(t)||(a=0,t=0),this.drawMarkerShape(e,t,null==i?void 0:i.shape,a,h(h({},i),"line"===i.shape||"plus"===i.shape||"cross"===i.shape?{pointStrokeColor:i.pointFillColor,pointStrokeOpacity:i.pointFillOpacity}:{}))}},{key:"pathMouseEnter",value:function(e,t){var i=this.w,a=new l(this.ctx),r=parseInt(e.node.getAttribute("index"),10),s=parseInt(e.node.getAttribute("j"),10);if("function"==typeof i.config.chart.events.dataPointMouseEnter&&i.config.chart.events.dataPointMouseEnter(t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}),this.ctx.events.fireEvent("dataPointMouseEnter",[t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}]),("none"===i.config.states.active.filter.type||"true"!==e.node.getAttribute("selected"))&&"none"!==i.config.states.hover.filter.type&&!i.globals.isTouchDevice){var n=i.config.states.hover.filter;a.applyFilter(e,r,n.type,n.value)}}},{key:"pathMouseLeave",value:function(e,t){var i=this.w,a=new l(this.ctx),r=parseInt(e.node.getAttribute("index"),10),s=parseInt(e.node.getAttribute("j"),10);"function"==typeof i.config.chart.events.dataPointMouseLeave&&i.config.chart.events.dataPointMouseLeave(t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}),this.ctx.events.fireEvent("dataPointMouseLeave",[t,this.ctx,{seriesIndex:r,dataPointIndex:s,w:i}]),"none"!==i.config.states.active.filter.type&&"true"===e.node.getAttribute("selected")||"none"!==i.config.states.hover.filter.type&&a.getDefaultFilter(e,r)}},{key:"pathMouseDown",value:function(e,t){var i=this.w,a=new l(this.ctx),r=parseInt(e.node.getAttribute("index"),10),s=parseInt(e.node.getAttribute("j"),10),n="false";if("true"===e.node.getAttribute("selected")){if(e.node.setAttribute("selected","false"),i.globals.selectedDataPoints[r].indexOf(s)>-1){var o=i.globals.selectedDataPoints[r].indexOf(s);i.globals.selectedDataPoints[r].splice(o,1)}}else{if(!i.config.states.active.allowMultipleDataPointsSelection&&i.globals.selectedDataPoints.length>0){i.globals.selectedDataPoints=[];var c=i.globals.dom.Paper.select(".apexcharts-series path").members,h=i.globals.dom.Paper.select(".apexcharts-series circle, .apexcharts-series rect").members,d=function(e){Array.prototype.forEach.call(e,(function(e){e.node.setAttribute("selected","false"),a.getDefaultFilter(e,r)}))};d(c),d(h)}e.node.setAttribute("selected","true"),n="true",void 0===i.globals.selectedDataPoints[r]&&(i.globals.selectedDataPoints[r]=[]),i.globals.selectedDataPoints[r].push(s)}if("true"===n){var u=i.config.states.active.filter;if("none"!==u)a.applyFilter(e,r,u.type,u.value);else if("none"!==i.config.states.hover.filter&&!i.globals.isTouchDevice){var g=i.config.states.hover.filter;a.applyFilter(e,r,g.type,g.value)}}else"none"!==i.config.states.active.filter.type&&("none"===i.config.states.hover.filter.type||i.globals.isTouchDevice?a.getDefaultFilter(e,r):(g=i.config.states.hover.filter,a.applyFilter(e,r,g.type,g.value)));"function"==typeof i.config.chart.events.dataPointSelection&&i.config.chart.events.dataPointSelection(t,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:r,dataPointIndex:s,w:i}),t&&this.ctx.events.fireEvent("dataPointSelection",[t,this.ctx,{selectedDataPoints:i.globals.selectedDataPoints,seriesIndex:r,dataPointIndex:s,w:i}])}},{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,i,a){var r=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=this.w,n=this.drawText({x:-200,y:-200,text:e,textAnchor:"start",fontSize:t,fontFamily:i,foreColor:"#fff",opacity:0});a&&n.attr("transform",a),s.globals.dom.Paper.add(n);var o=n.bbox();return r||(o=n.node.getBoundingClientRect()),n.remove(),{width:o.width,height:o.height}}},{key:"placeTextWithEllipsis",value:function(e,t,i){if("function"==typeof e.getComputedTextLength&&(e.textContent=t,t.length>0&&e.getComputedTextLength()>=i/1.1)){for(var a=t.length-3;a>0;a-=3)if(e.getSubStringLength(0,a)<=i/1.1)return void(e.textContent=t.substring(0,a)+"...");e.textContent="."}}}],a=[{key:"setAttrs",value:function(e,t){for(var i in t)t.hasOwnProperty(i)&&e.setAttribute(i,t[i])}}],i&&u(t.prototype,i),a&&u(t,a),e}();function f(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const p=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i,a;return t=e,i=[{key:"getStackedSeriesTotals",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=this.w,i=[];if(0===t.globals.series.length)return i;for(var a=0;a<t.globals.series[t.globals.maxValsInArrayIndex].length;a++){for(var r=0,s=0;s<t.globals.series.length;s++)void 0!==t.globals.series[s][a]&&-1===e.indexOf(s)&&(r+=t.globals.series[s][a]);i.push(r)}return i}},{key:"getSeriesTotalByIndex",value:function(){var e=arguments.length>0&&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,i=[];return t.globals.seriesGroups.forEach((function(a){var r=[];t.config.series.forEach((function(e,i){a.indexOf(t.globals.seriesNames[i])>-1&&r.push(i)}));var s=t.globals.series.map((function(e,t){return-1===r.indexOf(t)?t:-1})).filter((function(e){return-1!==e}));i.push(e.getStackedSeriesTotals(s))})),i}},{key:"setSeriesYAxisMappings",value:function(){var e=this.w.globals,t=this.w.config,i=[],a=[],r=[],s=e.series.length>t.yaxis.length||t.yaxis.some((function(e){return Array.isArray(e.seriesName)}));t.series.forEach((function(e,t){r.push(t),a.push(null)})),t.yaxis.forEach((function(e,t){i[t]=[]}));var n=[];t.yaxis.forEach((function(e,a){var o=!1;if(e.seriesName){var l=[];Array.isArray(e.seriesName)?l=e.seriesName:l.push(e.seriesName),l.forEach((function(e){t.series.forEach((function(t,n){if(t.name===e){var l=n;a===n||s?!s||r.indexOf(n)>-1?i[a].push([a,n]):console.warn("Series '"+t.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(i[n].push([n,a]),l=a),o=!0,-1!==(l=r.indexOf(l))&&r.splice(l,1)}}))}))}o||n.push(a)})),i=i.map((function(e,t){var i=[];return e.forEach((function(e){a[e[1]]=e[0],i.push(e[1])})),i}));for(var o=t.yaxis.length-1,l=0;l<n.length&&(o=n[l],i[o]=[],r);l++){var c=r[0];r.shift(),i[o].push(c),a[c]=o}r.forEach((function(e){i[o].push(e),a[e]=o})),e.seriesYAxisMap=i.map((function(e){return e})),e.seriesYAxisReverseMap=a.map((function(e){return e})),e.seriesYAxisMap.forEach((function(e,i){e.forEach((function(e){t.series[e]&&void 0===t.series[e].group&&(t.series[e].group="apexcharts-axis-".concat(i.toString()))}))}))}},{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,i){return e===i[0]}))}},{key:"getCategoryLabels",value:function(e){var t=this.w,i=e.slice();return t.config.xaxis.convertedCatToNumeric&&(i=e.map((function(e,i){return t.config.xaxis.labels.formatter(e-t.globals.minX+1)}))),i}},{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 i=0;if(Array.isArray(e))for(var a=0;a<e.length;a++)i+=e[a];else i+=e;return i}))}},{key:"getSeriesTotalsXRange",value:function(e,t){var i=this.w;return i.globals.series.map((function(a,r){for(var s=0,n=0;n<a.length;n++)i.globals.seriesX[r][n]>e&&i.globals.seriesX[r][n]<t&&(s+=a[n]);return s}))}},{key:"getPercentSeries",value:function(){var e=this.w;e.globals.seriesPercent=e.globals.series.map((function(t,i){var a=[];if(Array.isArray(t))for(var r=0;r<t.length;r++){var s=e.globals.stackedSeriesTotals[r],n=0;s&&(n=100*t[r]/s),a.push(n)}else{var o=100*t/e.globals.seriesTotals.reduce((function(e,t){return e+t}),0);a.push(o)}return a}))}},{key:"getCalculatedRatios",value:function(){var e,t,i,a=this,r=this.w,s=r.globals,n=[],o=0,l=[],c=.1,h=0;if(s.yRange=[],s.isMultipleYAxis)for(var d=0;d<s.minYArr.length;d++)s.yRange.push(Math.abs(s.minYArr[d]-s.maxYArr[d])),l.push(0);else s.yRange.push(Math.abs(s.minY-s.maxY));s.xRange=Math.abs(s.maxX-s.minX),s.zRange=Math.abs(s.maxZ-s.minZ);for(var u=0;u<s.yRange.length;u++)n.push(s.yRange[u]/s.gridHeight);if(t=s.xRange/s.gridWidth,e=s.yRange/s.gridWidth,i=s.xRange/s.gridHeight,(o=s.zRange/s.gridHeight*16)||(o=1),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(s.hasNegs=!0),r.globals.seriesYAxisReverseMap.length>0){var g=function(e,t){var i=r.config.yaxis[r.globals.seriesYAxisReverseMap[t]],s=e<0?-1:1;return e=Math.abs(e),i.logarithmic&&(e=a.getBaseLog(i.logBase,e)),-s*e/n[t]};if(s.isMultipleYAxis){l=[];for(var f=0;f<n.length;f++)l.push(g(s.minYArr[f],f))}else(l=[]).push(g(s.minY,0)),s.minY!==Number.MIN_VALUE&&0!==Math.abs(s.minY)&&(c=-s.minY/e,h=s.minX/t)}else(l=[]).push(0),c=0,h=0;return{yRatio:n,invertedYRatio:e,zRatio:o,xRatio:t,invertedXRatio:i,baseLineInvertedY:c,baseLineY:l,baseLineX:h}}},{key:"getLogSeries",value:function(e){var t=this,i=this.w;return i.globals.seriesLog=e.map((function(e,a){var r=i.globals.seriesYAxisReverseMap[a];return i.config.yaxis[r]&&i.config.yaxis[r].logarithmic?e.map((function(e){return null===e?null:t.getLogVal(i.config.yaxis[r].logBase,e,a)})):e})),i.globals.invalidLogScale?e:i.globals.seriesLog}},{key:"getBaseLog",value:function(e,t){return Math.log(t)/Math.log(e)}},{key:"getLogVal",value:function(e,t,i){if(t<=0)return 0;var a=this.w,r=0===a.globals.minYArr[i]?-1:this.getBaseLog(e,a.globals.minYArr[i]),s=(0===a.globals.maxYArr[i]?0:this.getBaseLog(e,a.globals.maxYArr[i]))-r;return t<1?t/s:(this.getBaseLog(e,t)-r)/s}},{key:"getLogYRatios",value:function(e){var t=this,i=this.w,a=this.w.globals;return a.yLogRatio=e.slice(),a.logYRange=a.yRange.map((function(e,r){var s=i.globals.seriesYAxisReverseMap[r];if(i.config.yaxis[s]&&t.w.config.yaxis[s].logarithmic){var n,o=-Number.MAX_VALUE,l=Number.MIN_VALUE;return a.seriesLog.forEach((function(e,t){e.forEach((function(e){i.config.yaxis[t]&&i.config.yaxis[t].logarithmic&&(o=Math.max(e,o),l=Math.min(e,l))}))})),n=Math.pow(a.yRange[r],Math.abs(l-o)/a.yRange[r]),a.yLogRatio[r]=n/a.gridHeight,n}})),a.invalidLogScale?e.slice():a.yLogRatio}},{key:"drawSeriesByGroup",value:function(e,t,i,a){var r=this.w,s=[];return e.series.length>0&&t.forEach((function(t){var n=[],o=[];e.i.forEach((function(i,a){r.config.series[i].group===t&&(n.push(e.series[a]),o.push(i))})),n.length>0&&s.push(a.draw(n,i,o))})),s}}],a=[{key:"checkComboSeries",value:function(e,t){var i=!1,a=0,r=0;return void 0===t&&(t="line"),e.length&&void 0!==e[0].type&&e.forEach((function(e){"bar"!==e.type&&"column"!==e.type&&"candlestick"!==e.type&&"boxPlot"!==e.type||a++,void 0!==e.type&&e.type!==t&&r++})),r>0&&(i=!0),{comboBarCount:a,comboCharts:i}}},{key:"extendArrayProps",value:function(e,t,i){var a,r,s,n,o,l;return null!==(a=t)&&void 0!==a&&a.yaxis&&(t=e.extendYAxis(t,i)),null!==(r=t)&&void 0!==r&&r.annotations&&(t.annotations.yaxis&&(t=e.extendYAxisAnnotations(t)),null!==(s=t)&&void 0!==s&&null!==(n=s.annotations)&&void 0!==n&&n.xaxis&&(t=e.extendXAxisAnnotations(t)),null!==(o=t)&&void 0!==o&&null!==(l=o.annotations)&&void 0!==l&&l.points&&(t=e.extendPointAnnotations(t))),t}}],i&&f(t.prototype,i),a&&f(t,a),e}();function x(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var b=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t}var t,i;return t=e,i=[{key:"setOrientations",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.w;if("vertical"===e.label.orientation){var a=null!==t?t:0,r=i.globals.dom.baseEl.querySelector(".apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='".concat(a,"']"));if(null!==r){var s=r.getBoundingClientRect();r.setAttribute("x",parseFloat(r.getAttribute("x"))-s.height+4),"top"===e.label.position?r.setAttribute("y",parseFloat(r.getAttribute("y"))+s.width):r.setAttribute("y",parseFloat(r.getAttribute("y"))-s.width);var n=this.annoCtx.graphics.rotateAroundCenter(r),o=n.x,l=n.y;r.setAttribute("transform","rotate(-90 ".concat(o," ").concat(l,")"))}}}},{key:"addBackgroundToAnno",value:function(e,t){var i=this.w;if(!e||void 0===t.label.text||void 0!==t.label.text&&!String(t.label.text).trim())return null;var a=i.globals.dom.baseEl.querySelector(".apexcharts-grid").getBoundingClientRect(),r=e.getBoundingClientRect(),s=t.label.style.padding.left,n=t.label.style.padding.right,o=t.label.style.padding.top,l=t.label.style.padding.bottom;"vertical"===t.label.orientation&&(o=t.label.style.padding.left,l=t.label.style.padding.right,s=t.label.style.padding.top,n=t.label.style.padding.bottom);var c=r.left-a.left-s,h=r.top-a.top-o,d=this.annoCtx.graphics.drawRect(c-i.globals.barPadForNumericAxis,h,r.width+s+n,r.height+o+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,i=function(i,a,r){var s=t.globals.dom.baseEl.querySelector(".apexcharts-".concat(r,"-annotations .apexcharts-").concat(r,"-annotation-label[rel='").concat(a,"']"));if(s){var n=s.parentNode,o=e.addBackgroundToAnno(s,i);o&&(n.insertBefore(o.node,s),i.label.mouseEnter&&o.node.addEventListener("mouseenter",i.label.mouseEnter.bind(e,i)),i.label.mouseLeave&&o.node.addEventListener("mouseleave",i.label.mouseLeave.bind(e,i)),i.label.click&&o.node.addEventListener("click",i.label.click.bind(e,i)))}};t.config.annotations.xaxis.map((function(e,t){i(e,t,"xaxis")})),t.config.annotations.yaxis.map((function(e,t){i(e,t,"yaxis")})),t.config.annotations.points.map((function(e,t){i(e,t,"point")}))}},{key:"getY1Y2",value:function(e,t){var i,a="y1"===e?t.y:t.y2,r=!1,s=this.w;if(this.annoCtx.invertAxis){var n=s.globals.labels;s.config.xaxis.convertedCatToNumeric&&(n=s.globals.categoryLabels);var o=n.indexOf(a),l=s.globals.dom.baseEl.querySelector(".apexcharts-yaxis-texts-g text:nth-child("+(o+1)+")");i=l?parseFloat(l.getAttribute("y")):(s.globals.gridHeight/n.length-1)*(o+1)-s.globals.barHeight,void 0!==t.seriesIndex&&s.globals.barHeight&&(i=i-s.globals.barHeight/2*(s.globals.series.length-1)+s.globals.barHeight*t.seriesIndex)}else{var c,h=s.globals.seriesYAxisMap[t.yAxisIndex][0];(c=s.config.yaxis[t.yAxisIndex].logarithmic?(a=new p(this.annoCtx.ctx).getLogVal(s.config.yaxis[t.yAxisIndex].logBase,a,h))/s.globals.yLogRatio[h]:(a-s.globals.minYArr[h])/(s.globals.yRange[h]/s.globals.gridHeight))>s.globals.gridHeight?(c=s.globals.gridHeight,r=!0):c<0&&(c=0,r=!0),i=s.globals.gridHeight-c,!t.marker||void 0!==t.y&&null!==t.y||(i=0),s.config.yaxis[t.yAxisIndex]&&s.config.yaxis[t.yAxisIndex].reversed&&(i=c)}return"string"==typeof a&&a.indexOf("px")>-1&&(i=parseFloat(a)),{yP:i,clipped:r}}},{key:"getX1X2",value:function(e,t){var i,a="x1"===e?t.x:t.x2,r=this.w,s=this.annoCtx.invertAxis?r.globals.minY:r.globals.minX,n=this.annoCtx.invertAxis?r.globals.maxY:r.globals.maxX,o=this.annoCtx.invertAxis?r.globals.yRange[0]:r.globals.xRange,l=!1;return i=this.annoCtx.inversedReversedAxis?(n-a)/(o/r.globals.gridWidth):(a-s)/(o/r.globals.gridWidth),"category"!==r.config.xaxis.type&&!r.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||r.globals.dataFormatXNumeric||r.config.chart.sparkline.enabled||(i=this.getStringX(a)),"string"==typeof a&&a.indexOf("px")>-1&&(i=parseFloat(a)),null==a&&t.marker&&(i=r.globals.gridWidth),void 0!==t.seriesIndex&&r.globals.barWidth&&!this.annoCtx.invertAxis&&(i=i-r.globals.barWidth/2*(r.globals.series.length-1)+r.globals.barWidth*t.seriesIndex),i>r.globals.gridWidth?(i=r.globals.gridWidth,l=!0):i<0&&(i=0,l=!0),{x:i,clipped:l}}},{key:"getStringX",value:function(e){var t=this.w,i=e;t.config.xaxis.convertedCatToNumeric&&t.globals.categoryLabels.length&&(e=t.globals.categoryLabels.indexOf(e)+1);var a=t.globals.labels.indexOf(e),r=t.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g text:nth-child("+(a+1)+")");return r&&(i=parseFloat(r.getAttribute("x"))),i}}],i&&x(t.prototype,i),e}();function v(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var m=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t,this.invertAxis=this.annoCtx.invertAxis,this.helpers=new b(this.annoCtx)}var t,i;return t=e,(i=[{key:"addXaxisAnnotation",value:function(e,t,i){var a,s=this.w,n=this.helpers.getX1X2("x1",e),o=n.x,l=n.clipped,c=!0,h=e.label.text,d=e.strokeDashArray;if(r.isNumber(o)){if(null===e.x2||void 0===e.x2){if(!l){var u=this.annoCtx.graphics.drawLine(o+e.offsetX,0+e.offsetY,o+e.offsetX,s.globals.gridHeight+e.offsetY,e.borderColor,d,e.borderWidth);t.appendChild(u.node),e.id&&u.node.classList.add(e.id)}}else{var g=this.helpers.getX1X2("x2",e);if(a=g.x,c=g.clipped,!l||!c){if(a<o){var f=o;o=a,a=f}var p=this.annoCtx.graphics.drawRect(o+e.offsetX,0+e.offsetY,a-o,s.globals.gridHeight+e.offsetY,0,e.fillColor,e.opacity,1,e.borderColor,d);p.node.classList.add("apexcharts-annotation-rect"),p.attr("clip-path","url(#gridRectMask".concat(s.globals.cuid,")")),t.appendChild(p.node),e.id&&p.node.classList.add(e.id)}}if(!l||!c){var x=this.annoCtx.graphics.getTextRects(h,parseFloat(e.label.style.fontSize)),b="top"===e.label.position?4:"center"===e.label.position?s.globals.gridHeight/2+("vertical"===e.label.orientation?x.width/2:0):s.globals.gridHeight,v=this.annoCtx.graphics.drawText({x:o+e.label.offsetX,y:b+e.label.offsetY-("vertical"===e.label.orientation?"top"===e.label.position?x.width/2-12:-x.width/2:0),text:h,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-xaxis-annotation-label ".concat(e.label.style.cssClass," ").concat(e.id?e.id:"")});v.attr({rel:i}),t.appendChild(v.node),this.annoCtx.helpers.setOrientations(e,i)}}}},{key:"drawXAxisAnnotations",value:function(){var e=this,t=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-xaxis-annotations"});return t.config.annotations.xaxis.map((function(t,a){e.addXaxisAnnotation(t,i.node,a)})),i}}])&&v(t.prototype,i),e}();function y(e){return function(e){if(Array.isArray(e))return w(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return w(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?w(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function k(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const A=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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]}var t,i;return t=e,(i=[{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 i=Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "));return this.getTimeStamp(i)}},{key:"parseDateWithTimezone",value:function(e){return Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "))}},{key:"formatDate",value:function(e,t){var i=this.w.globals.locale,a=this.w.config.xaxis.labels.datetimeUTC,r=["\0"].concat(y(i.months)),s=[""].concat(y(i.shortMonths)),n=[""].concat(y(i.days)),o=[""].concat(y(i.shortDays));function l(e,t){var i=e+"";for(t=t||2;i.length<t;)i="0"+i;return i}var c=a?e.getUTCFullYear():e.getFullYear();t=(t=(t=t.replace(/(^|[^\\])yyyy+/g,"$1"+c)).replace(/(^|[^\\])yy/g,"$1"+c.toString().substr(2,2))).replace(/(^|[^\\])y/g,"$1"+c);var h=(a?e.getUTCMonth():e.getMonth())+1;t=(t=(t=(t=t.replace(/(^|[^\\])MMMM+/g,"$1"+r[0])).replace(/(^|[^\\])MMM/g,"$1"+s[0])).replace(/(^|[^\\])MM/g,"$1"+l(h))).replace(/(^|[^\\])M/g,"$1"+h);var d=a?e.getUTCDate():e.getDate();t=(t=(t=(t=t.replace(/(^|[^\\])dddd+/g,"$1"+n[0])).replace(/(^|[^\\])ddd/g,"$1"+o[0])).replace(/(^|[^\\])dd/g,"$1"+l(d))).replace(/(^|[^\\])d/g,"$1"+d);var u=a?e.getUTCHours():e.getHours(),g=u>12?u-12:0===u?12:u;t=(t=(t=(t=t.replace(/(^|[^\\])HH+/g,"$1"+l(u))).replace(/(^|[^\\])H/g,"$1"+u)).replace(/(^|[^\\])hh+/g,"$1"+l(g))).replace(/(^|[^\\])h/g,"$1"+g);var f=a?e.getUTCMinutes():e.getMinutes();t=(t=t.replace(/(^|[^\\])mm+/g,"$1"+l(f))).replace(/(^|[^\\])m/g,"$1"+f);var p=a?e.getUTCSeconds():e.getSeconds();t=(t=t.replace(/(^|[^\\])ss+/g,"$1"+l(p))).replace(/(^|[^\\])s/g,"$1"+p);var x=a?e.getUTCMilliseconds():e.getMilliseconds();t=t.replace(/(^|[^\\])fff+/g,"$1"+l(x,3)),x=Math.round(x/10),t=t.replace(/(^|[^\\])ff/g,"$1"+l(x)),x=Math.round(x/10);var b=u<12?"AM":"PM";t=(t=(t=t.replace(/(^|[^\\])f/g,"$1"+x)).replace(/(^|[^\\])TT+/g,"$1"+b)).replace(/(^|[^\\])T/g,"$1"+b.charAt(0));var v=b.toLowerCase();t=(t=t.replace(/(^|[^\\])tt+/g,"$1"+v)).replace(/(^|[^\\])t/g,"$1"+v.charAt(0));var m=-e.getTimezoneOffset(),w=a||!m?"Z":m>0?"+":"-";if(!a){var k=(m=Math.abs(m))%60;w+=l(Math.floor(m/60))+":"+l(k)}t=t.replace(/(^|[^\\])K/g,"$1"+w);var A=(a?e.getUTCDay():e.getDay())+1;return(t=(t=(t=(t=t.replace(new RegExp(n[0],"g"),n[A])).replace(new RegExp(o[0],"g"),o[A])).replace(new RegExp(r[0],"g"),r[h])).replace(new RegExp(s[0],"g"),s[h])).replace(/\\(.)/g,"$1")}},{key:"getTimeUnitsfromTimestamp",value:function(e,t,i){var a=this.w;void 0!==a.config.xaxis.min&&(e=a.config.xaxis.min),void 0!==a.config.xaxis.max&&(t=a.config.xaxis.max);var r=this.getDate(e),s=this.getDate(t),n=this.formatDate(r,"yyyy MM dd HH mm ss fff").split(" "),o=this.formatDate(s,"yyyy MM dd HH mm ss fff").split(" ");return{minMillisecond:parseInt(n[6],10),maxMillisecond:parseInt(o[6],10),minSecond:parseInt(n[5],10),maxSecond:parseInt(o[5],10),minMinute:parseInt(n[4],10),maxMinute:parseInt(o[4],10),minHour:parseInt(n[3],10),maxHour:parseInt(o[3],10),minDate:parseInt(n[2],10),maxDate:parseInt(o[2],10),minMonth:parseInt(n[1],10)-1,maxMonth:parseInt(o[1],10)-1,minYear:parseInt(n[0],10),maxYear:parseInt(o[0],10)}}},{key:"isLeapYear",value:function(e){return e%4==0&&e%100!=0||e%400==0}},{key:"calculcateLastDaysOfMonth",value:function(e,t,i){return this.determineDaysOfMonths(e,t)-i}},{key:"determineDaysOfYear",value:function(e){var t=365;return this.isLeapYear(e)&&(t=366),t}},{key:"determineRemainingDaysOfYear",value:function(e,t,i){var a=this.daysCntOfYear[t]+i;return t>1&&this.isLeapYear()&&a++,a}},{key:"determineDaysOfMonths",value:function(e,t){var i=30;switch(e=r.monthMod(e),!0){case this.months30.indexOf(e)>-1:2===e&&(i=this.isLeapYear(t)?29:28);break;case this.months31.indexOf(e)>-1:default:i=31}return i}}])&&k(t.prototype,i),e}();function S(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const C=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.tooltipKeyFormat="dd MMM"}var t,i;return t=e,(i=[{key:"xLabelFormat",value:function(e,t,i,a){var r=this.w;if("datetime"===r.config.xaxis.type&&void 0===r.config.xaxis.labels.formatter&&void 0===r.config.tooltip.x.formatter){var s=new A(this.ctx);return s.formatDate(s.getDate(t),r.config.tooltip.x.format)}return e(t,i,a)}},{key:"defaultGeneralFormatter",value:function(e){return Array.isArray(e)?e.map((function(e){return e})):e}},{key:"defaultYFormatter",value:function(e,t,i){var a=this.w;if(r.isNumber(e))if(0!==a.globals.yValueDecimal)e=e.toFixed(void 0!==t.decimalsInFloat?t.decimalsInFloat:a.globals.yValueDecimal);else{var s=e.toFixed(0);e=e==s?s:e.toFixed(1)}return 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(r.isNumber(e)){if(!t.config.xaxis.convertedCatToNumeric&&"numeric"===t.config.xaxis.type){if(r.isNumber(t.config.xaxis.decimalsInFloat))return e.toFixed(t.config.xaxis.decimalsInFloat);var i=t.globals.maxX-t.globals.minX;return i>0&&i<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(i,a){void 0!==i.labels.formatter?t.globals.yLabelFormatters[a]=i.labels.formatter:t.globals.yLabelFormatters[a]=function(r){return t.globals.xyCharts?Array.isArray(r)?r.map((function(t){return e.defaultYFormatter(t,i,a)})):e.defaultYFormatter(r,i,a):r}})),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}}}])&&S(t.prototype,i),e}();function P(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var L=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"getLabel",value:function(e,t,i,a){var r,s,n=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"12px",l=!(arguments.length>6&&void 0!==arguments[6])||arguments[6],c=this.w,h=void 0===e[a]?"":e[a],d=h,u=c.globals.xLabelFormatter,f=c.config.xaxis.labels.formatter,p=!1,x=new C(this.ctx),b=h;l&&(d=x.xLabelFormat(u,h,b,{i:a,dateFormatter:new A(this.ctx).formatDate,w:c}),void 0!==f&&(d=f(h,e[a],{i:a,dateFormatter:new A(this.ctx).formatDate,w:c}))),t.length>0?(r=t[a].unit,s=null,t.forEach((function(e){"month"===e.unit?s="year":"day"===e.unit?s="month":"hour"===e.unit?s="day":"minute"===e.unit&&(s="hour")})),p=s===r,i=t[a].position,d=t[a].value):"datetime"===c.config.xaxis.type&&void 0===f&&(d=""),void 0===d&&(d=""),d=Array.isArray(d)?d:d.toString();var v,m=new g(this.ctx);v=c.globals.rotateXLabels&&l?m.getTextRects(d,parseInt(o,10),null,"rotate(".concat(c.config.xaxis.labels.rotate," 0 0)"),!1):m.getTextRects(d,parseInt(o,10));var y=!c.config.xaxis.labels.showDuplicates&&this.ctx.timeScale;return!Array.isArray(d)&&("NaN"===String(d)||n.indexOf(d)>=0&&y)&&(d=""),{x:i,text:d,textRect:v,isBold:p}}},{key:"checkLabelBasedOnTickamount",value:function(e,t,i){var a=this.w,r=a.config.xaxis.tickAmount;return"dataPoints"===r&&(r=Math.round(a.globals.gridWidth/120)),r>i||e%Math.round(i/(r+1))==0||(t.text=""),t}},{key:"checkForOverflowingLabels",value:function(e,t,i,a,r){var s=this.w;if(0===e&&s.globals.skipFirstTimelinelabel&&(t.text=""),e===i-1&&s.globals.skipLastTimelinelabel&&(t.text=""),s.config.xaxis.labels.hideOverlappingLabels&&a.length>0){var n=r[r.length-1];t.x<n.textRect.width/(s.globals.rotateXLabels?Math.abs(s.config.xaxis.labels.rotate)/12:1.01)+n.x&&(t.text="")}return t}},{key:"checkForReversedLabels",value:function(e,t){var i=this.w;return i.config.yaxis[e]&&i.config.yaxis[e].reversed&&t.reverse(),t}},{key:"yAxisAllSeriesCollapsed",value:function(e){var t=this.w.globals;return!t.seriesYAxisMap[e].some((function(e){return-1===t.collapsedSeriesIndices.indexOf(e)}))}},{key:"translateYAxisIndex",value:function(e){var t=this.w,i=t.globals,a=t.config.yaxis;return i.series.length>a.length||a.some((function(e){return Array.isArray(e.seriesName)}))?e:i.seriesYAxisReverseMap[e]}},{key:"isYAxisHidden",value:function(e){var t=this.w,i=t.config.yaxis[e];if(!i.show||this.yAxisAllSeriesCollapsed(e))return!0;if(!i.showForNullSeries){var a=t.globals.seriesYAxisMap[e],r=new p(this.ctx);return a.every((function(e){return r.isSeriesNull(e)}))}return!1}},{key:"getYAxisForeColor",value:function(e,t){var i=this.w;return Array.isArray(e)&&i.globals.yAxisScale[t]&&this.ctx.theme.pushExtraColors(e,i.globals.yAxisScale[t].result.length,!1),e}},{key:"drawYAxisTicks",value:function(e,t,i,a,r,s,n){var o=this.w,l=new g(this.ctx),c=o.globals.translateY+o.config.yaxis[r].labels.offsetY;if(o.globals.isBarHorizontal?c=0:"heatmap"===o.config.chart.type&&(c+=s/2),a.show&&t>0){!0===o.config.yaxis[r].opposite&&(e+=a.width);for(var h=t;h>=0;h--){var d=l.drawLine(e+i.offsetX-a.width+a.offsetX,c+a.offsetY,e+i.offsetX+a.offsetX,c+a.offsetY,a.color);n.add(d),c+=s}}}}],i&&P(t.prototype,i),e}();function O(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var M=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t,this.helpers=new b(this.annoCtx),this.axesUtils=new L(this.annoCtx)}var t,i;return t=e,(i=[{key:"addYaxisAnnotation",value:function(e,t,i){var a,r=this.w,s=e.strokeDashArray,n=this.helpers.getY1Y2("y1",e),o=n.yP,l=n.clipped,c=!0,h=!1,d=e.label.text;if(null===e.y2||void 0===e.y2){if(!l){h=!0;var u=this.annoCtx.graphics.drawLine(0+e.offsetX,o+e.offsetY,this._getYAxisAnnotationWidth(e),o+e.offsetY,e.borderColor,s,e.borderWidth);t.appendChild(u.node),e.id&&u.node.classList.add(e.id)}}else{if(a=(n=this.helpers.getY1Y2("y2",e)).yP,c=n.clipped,a>o){var g=o;o=a,a=g}if(!l||!c){h=!0;var f=this.annoCtx.graphics.drawRect(0+e.offsetX,a+e.offsetY,this._getYAxisAnnotationWidth(e),o-a,0,e.fillColor,e.opacity,1,e.borderColor,s);f.node.classList.add("apexcharts-annotation-rect"),f.attr("clip-path","url(#gridRectMask".concat(r.globals.cuid,")")),t.appendChild(f.node),e.id&&f.node.classList.add(e.id)}}if(h){var p="right"===e.label.position?r.globals.gridWidth:"center"===e.label.position?r.globals.gridWidth/2:0,x=this.annoCtx.graphics.drawText({x:p+e.label.offsetX,y:(null!=a?a:o)+e.label.offsetY-3,text:d,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:"")});x.attr({rel:i}),t.appendChild(x.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,i=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return t.config.annotations.yaxis.forEach((function(t,a){t.yAxisIndex=e.axesUtils.translateYAxisIndex(t.yAxisIndex),e.axesUtils.isYAxisHidden(t.yAxisIndex)&&e.axesUtils.yAxisAllSeriesCollapsed(t.yAxisIndex)||e.addYaxisAnnotation(t,i.node,a)})),i}}])&&O(t.prototype,i),e}();function T(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var I=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.annoCtx=t,this.helpers=new b(this.annoCtx)}var t,i;return t=e,(i=[{key:"addPointAnnotation",value:function(e,t,i){if(!(this.w.globals.collapsedSeriesIndices.indexOf(e.seriesIndex)>-1)){var a=this.helpers.getX1X2("x1",e),s=a.x,n=a.clipped,o=(a=this.helpers.getY1Y2("y1",e)).yP,l=a.clipped;if(r.isNumber(s)&&!l&&!n){var c={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:"")},h=this.annoCtx.graphics.drawMarker(s+e.marker.offsetX,o+e.marker.offsetY,c);t.appendChild(h.node);var d=e.label.text?e.label.text:"",u=this.annoCtx.graphics.drawText({x:s+e.label.offsetX,y:o+e.label.offsetY-e.marker.size-parseFloat(e.label.style.fontSize)/1.6,text:d,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(u.attr({rel:i}),t.appendChild(u.node),e.customSVG.SVG){var g=this.annoCtx.graphics.group({class:"apexcharts-point-annotations-custom-svg "+e.customSVG.cssClass});g.attr({transform:"translate(".concat(s+e.customSVG.offsetX,", ").concat(o+e.customSVG.offsetY,")")}),g.node.innerHTML=e.customSVG.SVG,t.appendChild(g.node)}if(e.image.path){var f=e.image.width?e.image.width:20,p=e.image.height?e.image.height:20;h=this.annoCtx.addImage({x:s+e.image.offsetX-f/2,y:o+e.image.offsetY-p/2,width:f,height:p,path:e.image.path,appendTo:".apexcharts-point-annotations"})}e.mouseEnter&&h.node.addEventListener("mouseenter",e.mouseEnter.bind(this,e)),e.mouseLeave&&h.node.addEventListener("mouseleave",e.mouseLeave.bind(this,e)),e.click&&h.node.addEventListener("click",e.click.bind(this,e))}}}},{key:"drawPointAnnotations",value:function(){var e=this,t=this.w,i=this.annoCtx.graphics.group({class:"apexcharts-point-annotations"});return t.config.annotations.points.map((function(t,a){e.addPointAnnotation(t,i.node,a)})),i}}])&&T(t.prototype,i),e}();const E=JSON.parse('{"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 z(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var X=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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,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}}var t,i;return t=e,(i=[{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:"",locales:[E],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",categoryFormatter:void 0,valueFormatter:void 0},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:{line:{isSlopeChart:!1},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,borderRadius:4,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,offsetX:0,offsetY:0,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:{size:7,fillColors:void 0,strokeWidth:1,shape:void 0,offsetX:0,offsetY:0,customHTML:void 0,onClick:void 0},itemMargin:{horizontal:5,vertical:4},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",offsetX:0,offsetY:0,showNullDataPoints:!0,onClick:void 0,onDblClick:void 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:!1,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:"",palette:"palette1",monochrome:{enabled:!1,color:"#008FFB",shadeTo:"light",shadeIntensity:.65}}}}}])&&z(t.prototype,i),e}();function Y(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var D=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.graphics=new g(this.ctx),this.w.globals.isBarHorizontal&&(this.invertAxis=!0),this.helpers=new b(this),this.xAxisAnnotations=new m(this),this.yAxisAnnotations=new M(this),this.pointsAnnotations=new I(this),this.w.globals.isBarHorizontal&&this.w.config.yaxis[0].reversed&&(this.inversedReversedAxis=!0),this.xDivision=this.w.globals.gridWidth/this.w.globals.dataPoints}var t,i;return t=e,(i=[{key:"drawAxesAnnotations",value:function(){var e=this.w;if(e.globals.axisCharts){for(var t=this.yAxisAnnotations.drawYAxisAnnotations(),i=this.xAxisAnnotations.drawXAxisAnnotations(),a=this.pointsAnnotations.drawPointAnnotations(),r=e.config.chart.animations.enabled,s=[t,i,a],n=[i.node,t.node,a.node],o=0;o<3;o++)e.globals.dom.elGraphical.add(s[o]),!r||e.globals.resized||e.globals.dataChanged||"scatter"!==e.config.chart.type&&"bubble"!==e.config.chart.type&&e.globals.dataPoints>1&&n[o].classList.add("apexcharts-element-hidden"),e.globals.delayedElements.push({el:n[o],index:0});this.helpers.annotationsBackground()}}},{key:"drawImageAnnos",value:function(){var e=this;this.w.config.annotations.images.map((function(t,i){e.addImage(t,i)}))}},{key:"drawTextAnnos",value:function(){var e=this;this.w.config.annotations.texts.map((function(t,i){e.addText(t,i)}))}},{key:"addXaxisAnnotation",value:function(e,t,i){this.xAxisAnnotations.addXaxisAnnotation(e,t,i)}},{key:"addYaxisAnnotation",value:function(e,t,i){this.yAxisAnnotations.addYaxisAnnotation(e,t,i)}},{key:"addPointAnnotation",value:function(e,t,i){this.pointsAnnotations.addPointAnnotation(e,t,i)}},{key:"addText",value:function(e,t){var i=e.x,a=e.y,r=e.text,s=e.textAnchor,n=e.foreColor,o=e.fontSize,l=e.fontFamily,c=e.fontWeight,h=e.cssClass,d=e.backgroundColor,u=e.borderWidth,g=e.strokeDashArray,f=e.borderRadius,p=e.borderColor,x=e.appendTo,b=void 0===x?".apexcharts-svg":x,v=e.paddingLeft,m=void 0===v?4:v,y=e.paddingRight,w=void 0===y?4:y,k=e.paddingBottom,A=void 0===k?2:k,S=e.paddingTop,C=void 0===S?2:S,P=this.w,L=this.graphics.drawText({x:i,y:a,text:r,textAnchor:s||"start",fontSize:o||"12px",fontWeight:c||"regular",fontFamily:l||P.config.chart.fontFamily,foreColor:n||P.config.chart.foreColor,cssClass:h}),O=P.globals.dom.baseEl.querySelector(b);O&&O.appendChild(L.node);var M=L.bbox();if(r){var T=this.graphics.drawRect(M.x-m,M.y-C,M.width+m+w,M.height+A+C,f,d||"transparent",1,u,p,g);O.insertBefore(T.node,L.node)}}},{key:"addImage",value:function(e,t){var i=this.w,a=e.path,r=e.x,s=void 0===r?0:r,n=e.y,o=void 0===n?0:n,l=e.width,c=void 0===l?20:l,h=e.height,d=void 0===h?20:h,u=e.appendTo,g=void 0===u?".apexcharts-svg":u,f=i.globals.dom.Paper.image(a);f.size(c,d).move(s,o);var p=i.globals.dom.baseEl.querySelector(g);return p&&p.appendChild(f.node),f}},{key:"addXaxisAnnotationExternal",value:function(e,t,i){return this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"xaxis",contextMethod:i.addXaxisAnnotation}),i}},{key:"addYaxisAnnotationExternal",value:function(e,t,i){return this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"yaxis",contextMethod:i.addYaxisAnnotation}),i}},{key:"addPointAnnotationExternal",value:function(e,t,i){return void 0===this.invertAxis&&(this.invertAxis=i.w.globals.isBarHorizontal),this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"point",contextMethod:i.addPointAnnotation}),i}},{key:"addAnnotationExternal",value:function(e){var t=e.params,i=e.pushToMemory,a=e.context,s=e.type,n=e.contextMethod,o=a,l=o.w,c=l.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations")),h=c.childNodes.length+1,d=new X,u=Object.assign({},"xaxis"===s?d.xAxisAnnotation:"yaxis"===s?d.yAxisAnnotation:d.pointAnnotation),g=r.extend(u,t);switch(s){case"xaxis":this.addXaxisAnnotation(g,c,h);break;case"yaxis":this.addYaxisAnnotation(g,c,h);break;case"point":this.addPointAnnotation(g,c,h)}var f=l.globals.dom.baseEl.querySelector(".apexcharts-".concat(s,"-annotations .apexcharts-").concat(s,"-annotation-label[rel='").concat(h,"']")),p=this.helpers.addBackgroundToAnno(f,g);return p&&c.insertBefore(p.node,f),i&&l.globals.memory.methodsToExec.push({context:o,id:g.id?g.id:r.randomId(),method:n,label:"addAnnotation",params:t}),a}},{key:"clearAnnotations",value:function(e){var t=e.w,i=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-annotations, .apexcharts-xaxis-annotations, .apexcharts-point-annotations");t.globals.memory.methodsToExec.map((function(e,i){"addText"!==e.label&&"addAnnotation"!==e.label||t.globals.memory.methodsToExec.splice(i,1)})),i=r.listToArray(i),Array.prototype.forEach.call(i,(function(e){for(;e.firstChild;)e.removeChild(e.firstChild)}))}},{key:"removeAnnotation",value:function(e,t){var i=e.w,a=i.globals.dom.baseEl.querySelectorAll(".".concat(t));a&&(i.globals.memory.methodsToExec.map((function(e,a){e.id===t&&i.globals.memory.methodsToExec.splice(a,1)})),Array.prototype.forEach.call(a,(function(e){e.parentElement.removeChild(e)})))}}])&&Y(t.prototype,i),e}();function R(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function F(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?R(Object(i),!0).forEach((function(t){H(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):R(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function H(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function N(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var W=function(e){var t,i=e.isTimeline,a=e.ctx,r=e.seriesIndex,s=e.dataPointIndex,n=e.y1,o=e.y2,l=e.w,c=l.globals.seriesRangeStart[r][s],h=l.globals.seriesRangeEnd[r][s],d=l.globals.labels[s],u=l.config.series[r].name?l.config.series[r].name:"",g=l.globals.ttKeyFormatter,f=l.config.tooltip.y.title.formatter,p={w:l,seriesIndex:r,dataPointIndex:s,start:c,end:h};"function"==typeof f&&(u=f(u,p)),null!==(t=l.config.series[r].data[s])&&void 0!==t&&t.x&&(d=l.config.series[r].data[s].x),i||"datetime"===l.config.xaxis.type&&(d=new C(a).xLabelFormat(l.globals.ttKeyFormatter,d,d,{i:void 0,dateFormatter:new A(a).formatDate,w:l})),"function"==typeof g&&(d=g(d,p)),Number.isFinite(n)&&Number.isFinite(o)&&(c=n,h=o);var x="",b="",v=l.globals.colors[r];if(void 0===l.config.tooltip.x.formatter)if("datetime"===l.config.xaxis.type){var m=new A(a);x=m.formatDate(m.getDate(c),l.config.tooltip.x.format),b=m.formatDate(m.getDate(h),l.config.tooltip.x.format)}else x=c,b=h;else x=l.config.tooltip.x.formatter(c),b=l.config.tooltip.x.formatter(h);return{start:c,end:h,startVal:x,endVal:b,ylabel:d,color:v,seriesName:u}},B=function(e){var t=e.color,i=e.seriesName,a=e.ylabel,r=e.start,s=e.end,n=e.seriesIndex,o=e.dataPointIndex,l=e.ctx.tooltip.tooltipLabels.getFormatters(n);r=l.yLbFormatter(r),s=l.yLbFormatter(s);var c=l.yLbFormatter(e.w.globals.series[n][o]),h='<span class="value start-value">\n '.concat(r,'\n </span> <span class="separator">-</span> <span class="value end-value">\n ').concat(s,"\n </span>");return'<div class="apexcharts-tooltip-rangebar"><div> <span class="series-name" style="color: '+t+'">'+(i||"")+'</span></div><div> <span class="category">'+a+": </span> "+(e.w.globals.comboCharts?"rangeArea"===e.w.config.series[n].type||"rangeBar"===e.w.config.series[n].type?h:"<span>".concat(c,"</span>"):h)+" </div></div>"},j=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=t}var t,i;return t=e,(i=[{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(),r.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:"slope",value:function(){return this.hideYAxis(),{chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!0,formatter:function(e,t){var i=t.w.config.series[t.seriesIndex].name;return null!==e?i+": "+e:""},background:{enabled:!1},offsetX:-5},grid:{xaxis:{lines:{show:!0}},yaxis:{lines:{show:!1}}},xaxis:{position:"top",labels:{style:{fontSize:14,fontWeight:900}},tooltip:{enabled:!1},crosshairs:{show:!1}},markers:{size:8,hover:{sizeOffset:1}},legend:{show:!1},tooltip:{shared:!1,intersect:!0,followCursor:!0},stroke:{width:5,curve:"straight"}}}},{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"}},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(),F(F({},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 i=t.seriesIndex,a=t.dataPointIndex,r=t.w;return e._getBoxTooltip(r,i,a,["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 i=t.seriesIndex,a=t.dataPointIndex,r=t.w;return e._getBoxTooltip(r,i,a,["Minimum","Q1","Median","Q3","Maximum"],"boxPlot")}},markers:{size:7,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 i=t.seriesIndex,a=t.dataPointIndex,r=t.w,s=function(){var e=r.globals.seriesRangeStart[i][a];return r.globals.seriesRangeEnd[i][a]-e};return r.globals.comboCharts?"rangeBar"===r.config.series[i].type||"rangeArea"===r.config.series[i].type?s():e:s()},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=W(F(F({},e),{},{isTimeline:!0})),i=t.color,a=t.seriesName,r=t.ylabel,s=t.startVal,n=t.endVal;return B(F(F({},e),{},{color:i,seriesName:a,ylabel:r,start:s,end:n}))}(e):function(e){var t=W(e),i=t.color,a=t.seriesName,r=t.ylabel,s=t.start,n=t.end;return B(F(F({},e),{},{color:i,seriesName:a,ylabel:r,start:s,end:n}))}(e)}},xaxis:{tickPlacement:"between",tooltip:{enabled:!1},crosshairs:{stroke:{width:0}}}}}},{key:"dumbbell",value:function(e){var t,i;return null!==(t=e.plotOptions.bar)&&void 0!==t&&t.barHeight||(e.plotOptions.bar.barHeight=2),null!==(i=e.plotOptions.bar)&&void 0!==i&&i.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=W(e),i=t.color,a=t.seriesName,r=t.ylabel,s=t.start,n=t.end;return B(F(F({},e),{},{color:i,seriesName:a,ylabel:r,start:s,end:n}))}(e)}}}}},{key:"brush",value:function(e){return r.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,i){e.yaxis[i].min=0,e.yaxis[i].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 F(F({},e),{},{plotOptions:F(F({},e.plotOptions),{},{bar:F(F({},e.plotOptions.bar),{},{borderRadiusApplication:"end",borderRadiusWhenStacked:"last"})})})}},{key:"convertCatToNumeric",value:function(e){return e.xaxis.convertedCatToNumeric=!0,e}},{key:"convertCatToNumericXaxis",value:function(e,t,i){e.xaxis.type="numeric",e.xaxis.labels=e.xaxis.labels||{},e.xaxis.labels.formatter=e.xaxis.labels.formatter||function(e){return r.isNumber(e)?Math.floor(e):e};var a=e.xaxis.labels.formatter,s=e.xaxis.categories&&e.xaxis.categories.length?e.xaxis.categories:e.labels;return i&&i.length&&(s=i.map((function(e){return Array.isArray(e)?e:String(e)}))),s&&s.length&&(e.xaxis.labels.formatter=function(e){return r.isNumber(e)?a(s[Math.floor(e)-1]):a(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"}},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:{opacity:1,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{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:5,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,i,a,r){var s=e.globals.seriesCandleO[t][i],n=e.globals.seriesCandleH[t][i],o=e.globals.seriesCandleM[t][i],l=e.globals.seriesCandleL[t][i],c=e.globals.seriesCandleC[t][i];return e.config.series[t].type&&e.config.series[t].type!==r?'<div class="apexcharts-custom-tooltip">\n '.concat(e.config.series[t].name?e.config.series[t].name:"series-"+(t+1),": <strong>").concat(e.globals.series[t][i],"</strong>\n </div>"):'<div class="apexcharts-tooltip-box apexcharts-tooltip-'.concat(e.config.chart.type,'">')+"<div>".concat(a[0],': <span class="value">')+s+"</span></div>"+"<div>".concat(a[1],': <span class="value">')+n+"</span></div>"+(o?"<div>".concat(a[2],': <span class="value">')+o+"</span></div>":"")+"<div>".concat(a[3],': <span class="value">')+l+"</span></div>"+"<div>".concat(a[4],': <span class="value">')+c+"</span></div></div>"}}])&&N(t.prototype,i),e}();function G(e){return G="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},G(e)}function V(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var _=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=t}var t,i;return t=e,(i=[{key:"init",value:function(e){var t=e.responsiveOverride,i=this.opts,a=new X,s=new j(i);this.chartType=i.chart.type,i=this.extendYAxis(i),i=this.extendAnnotations(i);var n=a.init(),o={};if(i&&"object"===G(i)){var l,c,h,d,u,g,f,p,x,b,v={};v=-1!==["line","area","bar","candlestick","boxPlot","rangeBar","rangeArea","bubble","scatter","heatmap","treemap","pie","polarArea","donut","radar","radialBar"].indexOf(i.chart.type)?s[i.chart.type]():s.line(),null!==(l=i.plotOptions)&&void 0!==l&&null!==(c=l.bar)&&void 0!==c&&c.isFunnel&&(v=s.funnel()),i.chart.stacked&&"bar"===i.chart.type&&(v=s.stackedBars()),null!==(h=i.chart.brush)&&void 0!==h&&h.enabled&&(v=s.brush(v)),null!==(d=i.plotOptions)&&void 0!==d&&null!==(u=d.line)&&void 0!==u&&u.isSlopeChart&&(v=s.slope()),i.chart.stacked&&"100%"===i.chart.stackType&&(i=s.stacked100(i)),null!==(g=i.plotOptions)&&void 0!==g&&null!==(f=g.bar)&&void 0!==f&&f.isDumbbell&&(i=s.dumbbell(i)),this.checkForDarkTheme(window.Apex),this.checkForDarkTheme(i),i.xaxis=i.xaxis||window.Apex.xaxis||{},t||(i.xaxis.convertedCatToNumeric=!1),(null!==(p=(i=this.checkForCatToNumericXAxis(this.chartType,v,i)).chart.sparkline)&&void 0!==p&&p.enabled||null!==(x=window.Apex.chart)&&void 0!==x&&null!==(b=x.sparkline)&&void 0!==b&&b.enabled)&&(v=s.sparkline(v)),o=r.extend(n,v)}var m=r.extend(o,window.Apex);return n=r.extend(m,i),this.handleUserInputErrors(n)}},{key:"checkForCatToNumericXAxis",value:function(e,t,i){var a,r,s=new j(i),n=("bar"===e||"boxPlot"===e)&&(null===(a=i.plotOptions)||void 0===a||null===(r=a.bar)||void 0===r?void 0:r.horizontal),o="pie"===e||"polarArea"===e||"donut"===e||"radar"===e||"radialBar"===e||"heatmap"===e,l="datetime"!==i.xaxis.type&&"numeric"!==i.xaxis.type,c=i.xaxis.tickPlacement?i.xaxis.tickPlacement:t.xaxis&&t.xaxis.tickPlacement;return n||o||!l||"between"===c||(i=s.convertCatToNumeric(i)),i}},{key:"extendYAxis",value:function(e,t){var i=new X;(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=r.extend(e.yaxis,window.Apex.yaxis)),e.yaxis.constructor!==Array?e.yaxis=[r.extend(i.yAxis,e.yaxis)]:e.yaxis=r.extendArray(e.yaxis,i.yAxis);var a=!1;e.yaxis.forEach((function(e){e.logarithmic&&(a=!0)}));var s=e.series;return t&&!s&&(s=t.config.series),a&&s.length!==e.yaxis.length&&s.length&&(e.yaxis=s.map((function(t,a){if(t.name||(s[a].name="series-".concat(a+1)),e.yaxis[a])return e.yaxis[a].seriesName=s[a].name,e.yaxis[a];var n=r.extend(i.yAxis,e.yaxis[0]);return n.show=!1,n}))),a&&s.length>1&&s.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 X;return e.annotations.yaxis=r.extendArray(void 0!==e.annotations.yaxis?e.annotations.yaxis:[],t.yAxisAnnotation),e}},{key:"extendXAxisAnnotations",value:function(e){var t=new X;return e.annotations.xaxis=r.extendArray(void 0!==e.annotations.xaxis?e.annotations.xaxis:[],t.xAxisAnnotation),e}},{key:"extendPointAnnotations",value:function(e){var t=new X;return e.annotations.points=r.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.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}}])&&V(t.prototype,i),e}();function U(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var q=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,i;return t=e,(i=[{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.barGroups=[],e.lineGroups=[],e.areaGroups=[],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,e.multiAxisTickAmount=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:[],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,isSlopeChart:e.plotOptions.line.isSlopeChart,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,niceScaleAllowedMagMsd:[[1,1,2,5,5,5,10,10,10,10,10],[1,1,2,5,5,5,10,10,10,10,10]],niceScaleDefaultTicks:[1,2,4,4,6,6,6,6,6,6,6,6,6,6,6,6,6,6,12,12,12,12,12,12,12,12,12,24],seriesYAxisMap:[],seriesYAxisReverseMap:[]}}},{key:"init",value:function(e){var t=this.globalVars(e);return this.initGlobalVars(t),t.initialConfig=r.extend({},e),t.initialSeries=r.clone(e.series),t.lastXAxis=r.clone(t.initialConfig.xaxis),t.lastYAxis=r.clone(t.initialConfig.yaxis),t}}])&&U(t.prototype,i),e}();function Z(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var $=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=t}var t,i;return t=e,(i=[{key:"init",value:function(){var e=new _(this.opts).init({responsiveOverride:!1});return{config:e,globals:(new q).init(e)}}}])&&Z(t.prototype,i),e}();function J(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Q(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?J(Object(i),!0).forEach((function(t){K(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):J(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function K(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ee(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const te=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.opts=null,this.seriesIndex=0}var t,i;return t=e,(i=[{key:"clippedImgArea",value:function(e){var t=this.w,i=t.config,a=parseInt(t.globals.gridWidth,10),r=parseInt(t.globals.gridHeight,10),s=a>r?a:r,n=e.image,o=0,l=0;void 0===e.width&&void 0===e.height?void 0!==i.fill.image.width&&void 0!==i.fill.image.height?(o=i.fill.image.width+1,l=i.fill.image.height):(o=s+1,l=s):(o=e.width,l=e.height);var c=document.createElementNS(t.globals.SVGNS,"pattern");g.setAttrs(c,{id:e.patternID,patternUnits:e.patternUnits?e.patternUnits:"userSpaceOnUse",width:o+"px",height:l+"px"});var h=document.createElementNS(t.globals.SVGNS,"image");c.appendChild(h),h.setAttributeNS(window.SVG.xlink,"href",n),g.setAttrs(h,{x:0,y:0,preserveAspectRatio:"none",width:o+"px",height:l+"px"}),h.style.opacity=e.opacity,t.globals.dom.elDefs.node.appendChild(c)}},{key:"getSeriesIndex",value:function(e){var t=this.w,i=t.config.chart.type;return("bar"===i||"rangeBar"===i)&&t.config.plotOptions.bar.distributed||"heatmap"===i||"treemap"===i?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 i,a,s,n=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 l=e.fillType?e.fillType:this.getFillType(this.seriesIndex),c=Array.isArray(n.fill.opacity)?n.fill.opacity[this.seriesIndex]:n.fill.opacity;e.color&&(o=e.color),o||(o="#fff",console.warn("undefined color - ApexCharts"));var h=o;if(-1===o.indexOf("rgb")?o.length<9&&(h=r.hexToRgba(o,c)):o.indexOf("rgba")>-1&&(c=r.getOpacityFromRGBA(o)),e.opacity&&(c=e.opacity),"pattern"===l&&(a=this.handlePatternFill({fillConfig:e.fillConfig,patternFill:a,fillColor:o,fillOpacity:c,defaultColor:h})),"gradient"===l&&(s=this.handleGradientFill({fillConfig:e.fillConfig,fillColor:o,fillOpacity:c,i:this.seriesIndex})),"image"===l){var d=n.fill.image.src,u=e.patternID?e.patternID:"";this.clippedImgArea({opacity:c,image:Array.isArray(d)?e.seriesNumber<d.length?d[e.seriesNumber]:d[0]:d,width:e.width?e.width:void 0,height:e.height?e.height:void 0,patternUnits:e.patternUnits,patternID:"pattern".concat(t.globals.cuid).concat(e.seriesNumber+1).concat(u)}),i="url(#pattern".concat(t.globals.cuid).concat(e.seriesNumber+1).concat(u,")")}else i="gradient"===l?s:"pattern"===l?a:h;return e.solid&&(i=h),i}},{key:"getFillType",value:function(e){var t=this.w;return Array.isArray(t.config.fill.type)?t.config.fill.type[e]:t.config.fill.type}},{key:"getFillColors",value:function(){var e=this.w,t=e.config,i=this.opts,a=[];return e.globals.comboCharts?"line"===e.config.series[this.seriesIndex].type?Array.isArray(e.globals.stroke.colors)?a=e.globals.stroke.colors:a.push(e.globals.stroke.colors):Array.isArray(e.globals.fill.colors)?a=e.globals.fill.colors:a.push(e.globals.fill.colors):"line"===t.chart.type?Array.isArray(e.globals.stroke.colors)?a=e.globals.stroke.colors:a.push(e.globals.stroke.colors):Array.isArray(e.globals.fill.colors)?a=e.globals.fill.colors:a.push(e.globals.fill.colors),void 0!==i.fillColors&&(a=[],Array.isArray(i.fillColors)?a=i.fillColors.slice():a.push(i.fillColors)),a}},{key:"handlePatternFill",value:function(e){var t=e.fillConfig,i=(e.patternFill,e.fillColor),a=e.fillOpacity,r=e.defaultColor,s=this.w.config.fill;t&&(s=t);var n=this.opts,o=new g(this.ctx),l=Array.isArray(s.pattern.strokeWidth)?s.pattern.strokeWidth[this.seriesIndex]:s.pattern.strokeWidth,c=i;return Array.isArray(s.pattern.style)?void 0!==s.pattern.style[n.seriesNumber]?o.drawPattern(s.pattern.style[n.seriesNumber],s.pattern.width,s.pattern.height,c,l,a):r:o.drawPattern(s.pattern.style,s.pattern.width,s.pattern.height,c,l,a)}},{key:"handleGradientFill",value:function(e){var t=e.fillColor,i=e.fillOpacity,a=e.fillConfig,s=e.i,n=this.w.config.fill;a&&(n=Q(Q({},n),a));var o,l=this.opts,c=new g(this.ctx),h=new r,d=n.gradient.type,u=t,f=void 0===n.gradient.opacityFrom?i:Array.isArray(n.gradient.opacityFrom)?n.gradient.opacityFrom[s]:n.gradient.opacityFrom;u.indexOf("rgba")>-1&&(f=r.getOpacityFromRGBA(u));var p=void 0===n.gradient.opacityTo?i:Array.isArray(n.gradient.opacityTo)?n.gradient.opacityTo[s]:n.gradient.opacityTo;if(void 0===n.gradient.gradientToColors||0===n.gradient.gradientToColors.length)o="dark"===n.gradient.shade?h.shadeColor(-1*parseFloat(n.gradient.shadeIntensity),t.indexOf("rgb")>-1?r.rgb2hex(t):t):h.shadeColor(parseFloat(n.gradient.shadeIntensity),t.indexOf("rgb")>-1?r.rgb2hex(t):t);else if(n.gradient.gradientToColors[l.seriesNumber]){var x=n.gradient.gradientToColors[l.seriesNumber];o=x,x.indexOf("rgba")>-1&&(p=r.getOpacityFromRGBA(x))}else o=t;if(n.gradient.gradientFrom&&(u=n.gradient.gradientFrom),n.gradient.gradientTo&&(o=n.gradient.gradientTo),n.gradient.inverseColors){var b=u;u=o,o=b}return u.indexOf("rgb")>-1&&(u=r.rgb2hex(u)),o.indexOf("rgb")>-1&&(o=r.rgb2hex(o)),c.drawGradient(d,u,o,f,p,l.size,n.gradient.stops,n.gradient.colorStops,s)}}])&&ee(t.prototype,i),e}();function ie(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ae=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{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.length<e.globals.series.length+1)for(var t=0;t<=e.globals.series.length;t++)void 0===e.globals.markers.size[t]&&e.globals.markers.size.push(e.globals.markers.size[0])}else e.globals.markers.size=e.config.series.map((function(t){return e.config.markers.size}))}},{key:"plotChartMarkers",value:function(e,t,i,a){var s,n=arguments.length>4&&void 0!==arguments[4]&&arguments[4],o=this.w,c=t,h=e,d=null,u=new g(this.ctx),f=o.config.markers.discrete&&o.config.markers.discrete.length;if((o.globals.markers.size[t]>0||n||f)&&(d=u.group({class:n||f?"":"apexcharts-series-markers"})).attr("clip-path","url(#gridRectMarkerMask".concat(o.globals.cuid,")")),Array.isArray(h.x))for(var p=0;p<h.x.length;p++){var x=i;1===i&&0===p&&(x=0),1===i&&1===p&&(x=1);var b="apexcharts-marker";if("line"!==o.config.chart.type&&"area"!==o.config.chart.type||o.globals.comboCharts||o.config.tooltip.intersect||(b+=" no-pointer-events"),(Array.isArray(o.config.markers.size)?o.globals.markers.size[t]>0:o.config.markers.size>0)||n||f){r.isNumber(h.y[p])?b+=" w".concat(r.randomId()):b="apexcharts-nullpoint";var v=this.getMarkerConfig({cssClass:b,seriesIndex:t,dataPointIndex:x});o.config.series[c].data[x]&&(o.config.series[c].data[x].fillColor&&(v.pointFillColor=o.config.series[c].data[x].fillColor),o.config.series[c].data[x].strokeColor&&(v.pointStrokeColor=o.config.series[c].data[x].strokeColor)),void 0!==a&&(v.pSize=a),(h.x[p]<-o.globals.markers.largestSize||h.x[p]>o.globals.gridWidth+o.globals.markers.largestSize||h.y[p]<-o.globals.markers.largestSize||h.y[p]>o.globals.gridHeight+o.globals.markers.largestSize)&&(v.pSize=0),(s=u.drawMarker(h.x[p],h.y[p],v)).attr("rel",x),s.attr("j",x),s.attr("index",t),s.node.setAttribute("default-marker-size",v.pSize),new l(this.ctx).setSelectionFilter(s,t,x),this.addEvents(s),d&&d.add(s)}else void 0===o.globals.pointsArray[t]&&(o.globals.pointsArray[t]=[]),o.globals.pointsArray[t].push([h.x[p],h.y[p]])}return d}},{key:"getMarkerConfig",value:function(e){var t=e.cssClass,i=e.seriesIndex,a=e.dataPointIndex,r=void 0===a?null:a,s=e.radius,n=void 0===s?null:s,o=e.size,l=void 0===o?null:o,c=e.strokeWidth,h=void 0===c?null:c,d=this.w,u=this.getMarkerStyle(i),g=null===l?d.globals.markers.size[i]:l,f=d.config.markers;return null!==r&&f.discrete.length&&f.discrete.map((function(e){e.seriesIndex===i&&e.dataPointIndex===r&&(u.pointStrokeColor=e.strokeColor,u.pointFillColor=e.fillColor,g=e.size,u.pointShape=e.shape)})),{pSize:null===n?g:n,pRadius:null!==n?n:f.radius,pointStrokeWidth:null!==h?h:Array.isArray(f.strokeWidth)?f.strokeWidth[i]:f.strokeWidth,pointStrokeColor:u.pointStrokeColor,pointFillColor:u.pointFillColor,shape:u.pointShape||(Array.isArray(f.shape)?f.shape[i]:f.shape),class:t,pointStrokeOpacity:Array.isArray(f.strokeOpacity)?f.strokeOpacity[i]:f.strokeOpacity,pointStrokeDashArray:Array.isArray(f.strokeDashArray)?f.strokeDashArray[i]:f.strokeDashArray,pointFillOpacity:Array.isArray(f.fillOpacity)?f.fillOpacity[i]:f.fillOpacity,seriesIndex:i}}},{key:"addEvents",value:function(e){var t=this.w,i=new g(this.ctx);e.node.addEventListener("mouseenter",i.pathMouseEnter.bind(this.ctx,e)),e.node.addEventListener("mouseleave",i.pathMouseLeave.bind(this.ctx,e)),e.node.addEventListener("mousedown",i.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",i.pathMouseDown.bind(this.ctx,e),{passive:!0})}},{key:"getMarkerStyle",value:function(e){var t=this.w,i=t.globals.markers.colors,a=t.config.markers.strokeColor||t.config.markers.strokeColors;return{pointStrokeColor:Array.isArray(a)?a[e]:a,pointFillColor:Array.isArray(i)?i[e]:i}}}],i&&ie(t.prototype,i),e}();function re(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var se=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.initialAnim=this.w.config.chart.animations.enabled}var t,i;return t=e,(i=[{key:"draw",value:function(e,t,i){var a=this.w,r=new g(this.ctx),s=i.realIndex,n=i.pointsPos,o=i.zRatio,l=i.elParent,c=r.group({class:"apexcharts-series-markers apexcharts-series-".concat(a.config.chart.type)});if(c.attr("clip-path","url(#gridRectMarkerMask".concat(a.globals.cuid,")")),Array.isArray(n.x))for(var h=0;h<n.x.length;h++){var d=t+1,u=!0;0===t&&0===h&&(d=0),0===t&&1===h&&(d=1);var f=a.globals.markers.size[s];if(o!==1/0){var p=a.config.plotOptions.bubble;f=a.globals.seriesZ[s][d],p.zScaling&&(f/=o),p.minBubbleRadius&&f<p.minBubbleRadius&&(f=p.minBubbleRadius),p.maxBubbleRadius&&f>p.maxBubbleRadius&&(f=p.maxBubbleRadius)}var x=n.x[h],b=n.y[h];if(f=f||0,null!==b&&void 0!==a.globals.series[s][d]||(u=!1),u){var v=this.drawPoint(x,b,f,s,d,t);c.add(v)}l.add(c)}}},{key:"drawPoint",value:function(e,t,i,a,r,s){var o=this.w,c=a,h=new n(this.ctx),d=new l(this.ctx),u=new te(this.ctx),f=new ae(this.ctx),p=new g(this.ctx),x=f.getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:c,dataPointIndex:r,radius:"bubble"===o.config.chart.type||o.globals.comboCharts&&o.config.series[a]&&"bubble"===o.config.series[a].type?i:null}),b=u.fillPath({seriesNumber:a,dataPointIndex:r,color:x.pointFillColor,patternUnits:"objectBoundingBox",value:o.globals.series[a][s]}),v=p.drawMarker(e,t,x);if(o.config.series[c].data[r]&&o.config.series[c].data[r].fillColor&&(b=o.config.series[c].data[r].fillColor),v.attr({fill:b}),o.config.chart.dropShadow.enabled){var m=o.config.chart.dropShadow;d.dropShadow(v,m,a)}if(!this.initialAnim||o.globals.dataChanged||o.globals.resized)o.globals.animationEnded=!0;else{var y=o.config.chart.animations.speed;h.animateMarker(v,y,o.globals.easing,(function(){window.setTimeout((function(){h.animationCompleted(v)}),100)}))}return v.attr({rel:r,j:r,index:a,"default-marker-size":x.pSize}),d.setSelectionFilter(v,a,r),f.addEvents(v),v.node.classList.add("apexcharts-marker"),v}},{key:"centerTextInBubble",value:function(e){var t=this.w;return{y:e+=parseInt(t.config.dataLabels.style.fontSize,10)/4}}}])&&re(t.prototype,i),e}();function ne(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const oe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"dataLabelsCorrection",value:function(e,t,i,a,r,s,n){var o=this.w,l=!1,c=new g(this.ctx).getTextRects(i,n),h=c.width,d=c.height;t<0&&(t=0),t>o.globals.gridHeight+d&&(t=o.globals.gridHeight+d/2),void 0===o.globals.dataLabelsRects[a]&&(o.globals.dataLabelsRects[a]=[]),o.globals.dataLabelsRects[a].push({x:e,y:t,width:h,height:d});var u=o.globals.dataLabelsRects[a].length-2,f=void 0!==o.globals.lastDrawnDataLabelsIndexes[a]?o.globals.lastDrawnDataLabelsIndexes[a][o.globals.lastDrawnDataLabelsIndexes[a].length-1]:0;if(void 0!==o.globals.dataLabelsRects[a][u]){var p=o.globals.dataLabelsRects[a][f];(e>p.x+p.width||t>p.y+p.height||t+d<p.y||e+h<p.x)&&(l=!0)}return(0===r||s)&&(l=!0),{x:e,y:t,textRects:c,drawnextLabel:l}}},{key:"drawDataLabel",value:function(e){var t=this,i=e.type,a=e.pos,r=e.i,s=e.j,n=e.isRangeStart,o=e.strokeWidth,l=void 0===o?2:o,c=this.w,h=new g(this.ctx),d=c.config.dataLabels,u=0,f=0,p=s,x=null;if(-1!==c.globals.collapsedSeriesIndices.indexOf(r)||!d.enabled||!Array.isArray(a.x))return x;x=h.group({class:"apexcharts-data-labels"});for(var b=0;b<a.x.length;b++)if(u=a.x[b]+d.offsetX,f=a.y[b]+d.offsetY+l,!isNaN(u)){1===s&&0===b&&(p=0),1===s&&1===b&&(p=1);var v=c.globals.series[r][p];"rangeArea"===i&&(v=n?c.globals.seriesRangeStart[r][p]:c.globals.seriesRangeEnd[r][p]);var m="",y=function(e){return c.config.dataLabels.formatter(e,{ctx:t.ctx,seriesIndex:r,dataPointIndex:p,w:c})};"bubble"===c.config.chart.type?(m=y(v=c.globals.seriesZ[r][p]),f=a.y[b],f=new se(this.ctx).centerTextInBubble(f,r,p).y):void 0!==v&&(m=y(v));var w=c.config.dataLabels.textAnchor;c.globals.isSlopeChart&&(w=0===p?"end":p===c.config.series[r].data.length-1?"start":"middle"),this.plotDataLabelsText({x:u,y:f,text:m,i:r,j:p,parent:x,offsetCorrection:!0,dataLabelsConfig:c.config.dataLabels,textAnchor:w})}return x}},{key:"plotDataLabelsText",value:function(e){var t=this.w,i=new g(this.ctx),a=e.x,r=e.y,s=e.i,n=e.j,o=e.text,c=e.textAnchor,h=e.fontSize,d=e.parent,u=e.dataLabelsConfig,f=e.color,p=e.alwaysDrawDataLabel,x=e.offsetCorrection,b=e.className,v=null;if(Array.isArray(t.config.dataLabels.enabledOnSeries)&&t.config.dataLabels.enabledOnSeries.indexOf(s)<0)return v;var m={x:a,y:r,drawnextLabel:!0,textRects:null};x&&(m=this.dataLabelsCorrection(a,r,o,s,n,p,parseInt(u.style.fontSize,10))),t.globals.zoomed||(a=m.x,r=m.y),m.textRects&&(a<-20-m.textRects.width||a>t.globals.gridWidth+m.textRects.width+30)&&(o="");var y=t.globals.dataLabels.style.colors[s];(("bar"===t.config.chart.type||"rangeBar"===t.config.chart.type)&&t.config.plotOptions.bar.distributed||t.config.dataLabels.distributed)&&(y=t.globals.dataLabels.style.colors[n]),"function"==typeof y&&(y=y({series:t.globals.series,seriesIndex:s,dataPointIndex:n,w:t})),f&&(y=f);var w=u.offsetX,k=u.offsetY;if("bar"!==t.config.chart.type&&"rangeBar"!==t.config.chart.type||(w=0,k=0),t.globals.isSlopeChart&&(0!==n&&(w=-2*u.offsetX+5),0!==n&&n!==t.config.series[s].data.length-1&&(w=0)),m.drawnextLabel){if((v=i.drawText({width:100,height:parseInt(u.style.fontSize,10),x:a+w,y:r+k,foreColor:y,textAnchor:c||u.textAnchor,text:o,fontSize:h||u.style.fontSize,fontFamily:u.style.fontFamily,fontWeight:u.style.fontWeight||"normal"})).attr({class:b||"apexcharts-datalabel",cx:a,cy:r}),u.dropShadow.enabled){var A=u.dropShadow;new l(this.ctx).dropShadow(v,A)}d.add(v),void 0===t.globals.lastDrawnDataLabelsIndexes[s]&&(t.globals.lastDrawnDataLabelsIndexes[s]=[]),t.globals.lastDrawnDataLabelsIndexes[s].push(n)}return v}},{key:"addBackgroundToDataLabel",value:function(e,t){var i=this.w,a=i.config.dataLabels.background,r=a.padding,s=a.padding/2,n=t.width,o=t.height,c=new g(this.ctx).drawRect(t.x-r,t.y-s/2,n+2*r,o+s,a.borderRadius,"transparent"!==i.config.chart.background&&i.config.chart.background?i.config.chart.background:"#fff",a.opacity,a.borderWidth,a.borderColor);return a.dropShadow.enabled&&new l(this.ctx).dropShadow(c,a.dropShadow),c}},{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"),i=0;i<t.length;i++){var a=t[i],r=a.getBBox(),s=null;if(r.width&&r.height&&(s=this.addBackgroundToDataLabel(a,r)),s){a.parentNode.insertBefore(s.node,a);var n=a.getAttribute("fill");!e.config.chart.animations.enabled||e.globals.resized||e.globals.dataChanged?s.attr({fill:n}):s.animate().attr({fill:n}),a.setAttribute("fill",e.config.dataLabels.background.foreColor)}}}},{key:"bringForward",value:function(){for(var e=this.w,t=e.globals.dom.baseEl.querySelectorAll(".apexcharts-datalabels"),i=e.globals.dom.baseEl.querySelector(".apexcharts-plot-series:last-child"),a=0;a<t.length;a++)i&&i.insertBefore(t[a],i.nextSibling)}}])&&ne(t.prototype,i),e}();function le(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ce=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.legendInactiveClass="legend-mouseover-inactive"}var t,i;return t=e,i=[{key:"getAllSeriesEls",value:function(){return this.w.globals.dom.baseEl.getElementsByClassName("apexcharts-series")}},{key:"getSeriesByName",value:function(e){return this.w.globals.dom.baseEl.querySelector(".apexcharts-inner .apexcharts-series[seriesName='".concat(r.escapeString(e),"']"))}},{key:"isSeriesHidden",value:function(e){var t=this.getSeriesByName(e),i=parseInt(t.getAttribute("data:realIndex"),10);return{isHidden:t.classList.contains("apexcharts-series-collapsed"),realIndex:i}}},{key:"addCollapsedClassToSeries",value:function(e,t){var i=this.w;function a(i){for(var a=0;a<i.length;a++)i[a].index===t&&e.node.classList.add("apexcharts-series-collapsed")}a(i.globals.collapsedSeries),a(i.globals.ancillaryCollapsedSeries)}},{key:"toggleSeries",value:function(e){var t=this.isSeriesHidden(e);return this.ctx.legend.legendHelpers.toggleDataSeries(t.realIndex,t.isHidden),t.isHidden}},{key:"showSeries",value:function(e){var t=this.isSeriesHidden(e);t.isHidden&&this.ctx.legend.legendHelpers.toggleDataSeries(t.realIndex,!0)}},{key:"hideSeries",value:function(e){var t=this.isSeriesHidden(e);t.isHidden||this.ctx.legend.legendHelpers.toggleDataSeries(t.realIndex,!1)}},{key:"resetSeries",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=this.w,s=r.clone(a.globals.initialSeries);a.globals.previousPaths=[],i?(a.globals.collapsedSeries=[],a.globals.ancillaryCollapsedSeries=[],a.globals.collapsedSeriesIndices=[],a.globals.ancillaryCollapsedSeriesIndices=[]):s=this.emptyCollapsedSeries(s),a.config.series=s,e&&(t&&(a.globals.zoomed=!1,this.ctx.updateHelpers.revertDefaultAxisMinMax()),this.ctx.updateHelpers._updateSeries(s,a.config.chart.animations.dynamicAnimation.enabled))}},{key:"emptyCollapsedSeries",value:function(e){for(var t=this.w,i=0;i<e.length;i++)t.globals.collapsedSeriesIndices.indexOf(i)>-1&&(e[i].data=[]);return e}},{key:"toggleSeriesOnHover",value:function(e,t){var i=this.w;t||(t=e.target);var a=i.globals.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels, .apexcharts-yaxis");if("mousemove"===e.type){var r=parseInt(t.getAttribute("rel"),10)-1,s=null,n=null,o=null;if(i.globals.axisCharts||"radialBar"===i.config.chart.type)if(i.globals.axisCharts){s=i.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(r,"']")),n=i.globals.dom.baseEl.querySelector(".apexcharts-datalabels[data\\:realIndex='".concat(r,"']"));var l=i.globals.seriesYAxisReverseMap[r];o=i.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(l,"']"))}else s=i.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(r+1,"']"));else s=i.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(r+1,"'] path"));for(var c=0;c<a.length;c++)a[c].classList.add(this.legendInactiveClass);null!==s&&(i.globals.axisCharts||s.parentNode.classList.remove(this.legendInactiveClass),s.classList.remove(this.legendInactiveClass),null!==n&&n.classList.remove(this.legendInactiveClass),null!==o&&o.classList.remove(this.legendInactiveClass))}else if("mouseout"===e.type)for(var h=0;h<a.length;h++)a[h].classList.remove(this.legendInactiveClass)}},{key:"highlightRangeInSeries",value:function(e,t){var i=this,a=this.w,r=a.globals.dom.baseEl.getElementsByClassName("apexcharts-heatmap-rect"),s=function(e){for(var t=0;t<r.length;t++)r[t].classList[e](i.legendInactiveClass)};if("mousemove"===e.type){var n=parseInt(t.getAttribute("rel"),10)-1;s("add"),function(e){for(var t=0;t<r.length;t++){var a=parseInt(r[t].getAttribute("val"),10);a>=e.from&&a<=e.to&&r[t].classList.remove(i.legendInactiveClass)}}(a.config.plotOptions.heatmap.colorScale.ranges[n])}else"mouseout"===e.type&&s("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]:[],i=this.w,a=0;if(i.config.series.length>1)for(var r=i.config.series.map((function(e,a){return e.data&&e.data.length>0&&-1===i.globals.collapsedSeriesIndices.indexOf(a)&&(!i.globals.comboCharts||0===t.length||t.length&&t.indexOf(i.config.series[a].type)>-1)?a:-1})),s="asc"===e?0:r.length-1;"asc"===e?s<r.length:s>=0;"asc"===e?s++:s--)if(-1!==r[s]){a=r[s];break}return a}},{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,i,a){for(var r=t[i].childNodes,s={type:a,paths:[],realIndex:t[i].getAttribute("data:realIndex")},n=0;n<r.length;n++)if(r[n].hasAttribute("pathTo")){var o=r[n].getAttribute("pathTo");s.paths.push({d:o})}e.globals.previousPaths.push(s)}e.globals.previousPaths=[],["line","area","bar","rangebar","rangeArea","candlestick","radar"].forEach((function(i){for(var a,r=(a=i,e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(a,"-series .apexcharts-series"))),s=0;s<r.length;s++)t(r,s,i)})),this.handlePrevBubbleScatterPaths("bubble"),this.handlePrevBubbleScatterPaths("scatter");var i=e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e.config.chart.type," .apexcharts-series"));if(i.length>0)for(var a=function(t){for(var i=e.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e.config.chart.type," .apexcharts-series[data\\:realIndex='").concat(t,"'] rect")),a=[],r=function(e){var t=function(t){return i[e].getAttribute(t)},r={x:parseFloat(t("x")),y:parseFloat(t("y")),width:parseFloat(t("width")),height:parseFloat(t("height"))};a.push({rect:r,color:i[e].getAttribute("color")})},s=0;s<i.length;s++)r(s);e.globals.previousPaths.push(a)},r=0;r<i.length;r++)a(r);e.globals.axisCharts||(e.globals.previousPaths=e.globals.series)}},{key:"handlePrevBubbleScatterPaths",value:function(e){var t=this.w,i=t.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e,"-series .apexcharts-series"));if(i.length>0)for(var a=0;a<i.length;a++){for(var r=t.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(e,"-series .apexcharts-series[data\\:realIndex='").concat(a,"'] circle")),s=[],n=0;n<r.length;n++)s.push({x:r[n].getAttribute("cx"),y:r[n].getAttribute("cy"),r:r[n].getAttribute("r")});t.globals.previousPaths.push(s)}}},{key:"clearPreviousPaths",value:function(){var e=this.w;e.globals.previousPaths=[],e.globals.allSeriesCollapsed=!1}},{key:"handleNoData",value:function(){var e=this.w,t=e.config.noData,i=new g(this.ctx),a=e.globals.svgWidth/2,r=e.globals.svgHeight/2,s="middle";if(e.globals.noData=!0,e.globals.animationEnded=!0,"left"===t.align?(a=10,s="start"):"right"===t.align&&(a=e.globals.svgWidth-10,s="end"),"top"===t.verticalAlign?r=50:"bottom"===t.verticalAlign&&(r=e.globals.svgHeight-50),a+=t.offsetX,r=r+parseInt(t.style.fontSize,10)+2+t.offsetY,void 0!==t.text&&""!==t.text){var n=i.drawText({x:a,y:r,text:t.text,textAnchor:s,fontSize:t.style.fontSize,fontFamily:t.style.fontFamily,foreColor:t.style.color,opacity:1,class:"apexcharts-text-nodata"});e.globals.dom.Paper.add(n)}}},{key:"setNullSeriesToZeroValues",value:function(e){for(var t=this.w,i=0;i<e.length;i++)if(0===e[i].length)for(var a=0;a<e[t.globals.maxValsInArrayIndex].length;a++)e[i].push(0);return e}},{key:"hasAllSeriesEqualX",value:function(){for(var e=!0,t=this.w,i=this.filteredSeriesX(),a=0;a<i.length-1;a++)if(i[a][0]!==i[a+1][0]){e=!1;break}return t.globals.allSeriesHasEqualX=e,e}},{key:"filteredSeriesX",value:function(){return this.w.globals.seriesX.map((function(e){return e.length>0?e:[]}))}}],i&&le(t.prototype,i),e}();function he(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function de(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ue=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.twoDSeries=[],this.threeDSeries=[],this.twoDSeriesX=[],this.seriesGoals=[],this.coreUtils=new p(this.ctx)}var t,i;return t=e,i=[{key:"isMultiFormat",value:function(){return this.isFormatXY()||this.isFormat2DArray()}},{key:"isFormatXY",value:function(){var e=this.w.config.series.slice(),t=new ce(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 ce(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 i=this.w.config,a=this.w.globals,s="boxPlot"===i.chart.type||"boxPlot"===i.series[t].type,n=0;n<e[t].data.length;n++)if(void 0!==e[t].data[n][1]&&(Array.isArray(e[t].data[n][1])&&4===e[t].data[n][1].length&&!s?this.twoDSeries.push(r.parseNumber(e[t].data[n][1][3])):e[t].data[n].length>=5?this.twoDSeries.push(r.parseNumber(e[t].data[n][4])):this.twoDSeries.push(r.parseNumber(e[t].data[n][1])),a.dataFormatXNumeric=!0),"datetime"===i.xaxis.type){var o=new Date(e[t].data[n][0]);o=new Date(o).getTime(),this.twoDSeriesX.push(o)}else this.twoDSeriesX.push(e[t].data[n][0]);for(var l=0;l<e[t].data.length;l++)void 0!==e[t].data[l][2]&&(this.threeDSeries.push(e[t].data[l][2]),a.isDataXYZ=!0)}},{key:"handleFormatXY",value:function(e,t){var i=this.w.config,a=this.w.globals,s=new A(this.ctx),n=t;a.collapsedSeriesIndices.indexOf(t)>-1&&(n=this.activeSeriesIndex);for(var o=0;o<e[t].data.length;o++)void 0!==e[t].data[o].y&&(Array.isArray(e[t].data[o].y)?this.twoDSeries.push(r.parseNumber(e[t].data[o].y[e[t].data[o].y.length-1])):this.twoDSeries.push(r.parseNumber(e[t].data[o].y))),void 0!==e[t].data[o].goals&&Array.isArray(e[t].data[o].goals)?(void 0===this.seriesGoals[t]&&(this.seriesGoals[t]=[]),this.seriesGoals[t].push(e[t].data[o].goals)):(void 0===this.seriesGoals[t]&&(this.seriesGoals[t]=[]),this.seriesGoals[t].push(null));for(var l=0;l<e[n].data.length;l++){var c="string"==typeof e[n].data[l].x,h=Array.isArray(e[n].data[l].x),d=!h&&!!s.isValidDate(e[n].data[l].x);if(c||d)if(c||i.xaxis.convertedCatToNumeric){var u=a.isBarHorizontal&&a.isRangeData;"datetime"!==i.xaxis.type||u?(this.fallbackToCategory=!0,this.twoDSeriesX.push(e[n].data[l].x),isNaN(e[n].data[l].x)||"category"===this.w.config.xaxis.type||"string"==typeof e[n].data[l].x||(a.isXNumeric=!0)):this.twoDSeriesX.push(s.parseDate(e[n].data[l].x))}else"datetime"===i.xaxis.type?this.twoDSeriesX.push(s.parseDate(e[n].data[l].x.toString())):(a.dataFormatXNumeric=!0,a.isXNumeric=!0,this.twoDSeriesX.push(parseFloat(e[n].data[l].x)));else h?(this.fallbackToCategory=!0,this.twoDSeriesX.push(e[n].data[l].x)):(a.isXNumeric=!0,a.dataFormatXNumeric=!0,this.twoDSeriesX.push(e[n].data[l].x))}if(e[t].data[0]&&void 0!==e[t].data[0].z){for(var g=0;g<e[t].data.length;g++)this.threeDSeries.push(e[t].data[g].z);a.isDataXYZ=!0}}},{key:"handleRangeData",value:function(e,t){var i=this.w.globals,a={};return this.isFormat2DArray()?a=this.handleRangeDataFormat("array",e,t):this.isFormatXY()&&(a=this.handleRangeDataFormat("xy",e,t)),i.seriesRangeStart.push(void 0===a.start?[]:a.start),i.seriesRangeEnd.push(void 0===a.end?[]:a.end),i.seriesRange.push(a.rangeUniques),i.seriesRange.forEach((function(e,t){e&&e.forEach((function(e,t){e.y.forEach((function(t,i){for(var a=0;a<e.y.length;a++)if(i!==a){var r=t.y1,s=t.y2,n=e.y[a].y1;r<=e.y[a].y2&&n<=s&&(e.overlaps.indexOf(t.rangeName)<0&&e.overlaps.push(t.rangeName),e.overlaps.indexOf(e.y[a].rangeName)<0&&e.overlaps.push(e.y[a].rangeName))}}))}))})),a}},{key:"handleCandleStickBoxData",value:function(e,t){var i=this.w.globals,a={};return this.isFormat2DArray()?a=this.handleCandleStickBoxDataFormat("array",e,t):this.isFormatXY()&&(a=this.handleCandleStickBoxDataFormat("xy",e,t)),i.seriesCandleO[t]=a.o,i.seriesCandleH[t]=a.h,i.seriesCandleM[t]=a.m,i.seriesCandleL[t]=a.l,i.seriesCandleC[t]=a.c,a}},{key:"handleRangeDataFormat",value:function(e,t,i){var a=[],s=[],n=t[i].data.filter((function(e,t,i){return t===i.findIndex((function(t){return t.x===e.x}))})).map((function(e,t){return{x:e.x,overlaps:[],y:[]}}));if("array"===e)for(var o=0;o<t[i].data.length;o++)Array.isArray(t[i].data[o])?(a.push(t[i].data[o][1][0]),s.push(t[i].data[o][1][1])):(a.push(t[i].data[o]),s.push(t[i].data[o]));else if("xy"===e)for(var l=function(e){var o=Array.isArray(t[i].data[e].y),l=r.randomId(),c=t[i].data[e].x,h={y1:o?t[i].data[e].y[0]:t[i].data[e].y,y2:o?t[i].data[e].y[1]:t[i].data[e].y,rangeName:l};t[i].data[e].rangeName=l;var d=n.findIndex((function(e){return e.x===c}));n[d].y.push(h),a.push(h.y1),s.push(h.y2)},c=0;c<t[i].data.length;c++)l(c);return{start:a,end:s,rangeUniques:n}}},{key:"handleCandleStickBoxDataFormat",value:function(e,t,i){var a=this.w,r="boxPlot"===a.config.chart.type||"boxPlot"===a.config.series[i].type,s=[],n=[],o=[],l=[],c=[];if("array"===e)if(r&&6===t[i].data[0].length||!r&&5===t[i].data[0].length)for(var h=0;h<t[i].data.length;h++)s.push(t[i].data[h][1]),n.push(t[i].data[h][2]),r?(o.push(t[i].data[h][3]),l.push(t[i].data[h][4]),c.push(t[i].data[h][5])):(l.push(t[i].data[h][3]),c.push(t[i].data[h][4]));else for(var d=0;d<t[i].data.length;d++)Array.isArray(t[i].data[d][1])&&(s.push(t[i].data[d][1][0]),n.push(t[i].data[d][1][1]),r?(o.push(t[i].data[d][1][2]),l.push(t[i].data[d][1][3]),c.push(t[i].data[d][1][4])):(l.push(t[i].data[d][1][2]),c.push(t[i].data[d][1][3])));else if("xy"===e)for(var u=0;u<t[i].data.length;u++)Array.isArray(t[i].data[u].y)&&(s.push(t[i].data[u].y[0]),n.push(t[i].data[u].y[1]),r?(o.push(t[i].data[u].y[2]),l.push(t[i].data[u].y[3]),c.push(t[i].data[u].y[4])):(l.push(t[i].data[u].y[2]),c.push(t[i].data[u].y[3])));return{o:s,h:n,m:o,l,c}}},{key:"parseDataAxisCharts",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.ctx,a=this.w.config,s=this.w.globals,n=new A(i),o=a.labels.length>0?a.labels.slice():a.xaxis.categories.slice();s.isRangeBar="rangeBar"===a.chart.type&&s.isBarHorizontal,s.hasXaxisGroups="category"===a.xaxis.type&&a.xaxis.group.groups.length>0,s.hasXaxisGroups&&(s.groups=a.xaxis.group.groups),e.forEach((function(e,t){void 0!==e.name?s.seriesNames.push(e.name):s.seriesNames.push("series-"+parseInt(t+1,10))})),this.coreUtils.setSeriesYAxisMappings();var l,c=[],h=function(e){if(Array.isArray(e))return he(e)}(l=new Set(a.series.map((function(e){return e.group}))))||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(l)||function(e,t){if(e){if("string"==typeof e)return he(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?he(e,t):void 0}}(l)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}();a.series.forEach((function(e,t){var i=h.indexOf(e.group);c[i]||(c[i]=[]),c[i].push(s.seriesNames[t])})),s.seriesGroups=c;for(var d=function(){for(var e=0;e<o.length;e++)if("string"==typeof o[e]){if(!n.isValidDate(o[e]))throw new Error("You have provided invalid Date format. Please provide a valid JavaScript Date");t.twoDSeriesX.push(n.parseDate(o[e]))}else t.twoDSeriesX.push(o[e])},u=0;u<e.length;u++){if(this.twoDSeries=[],this.twoDSeriesX=[],this.threeDSeries=[],void 0===e[u].data)return void console.error("It is a possibility that you may have not included 'data' property in series.");if("rangeBar"!==a.chart.type&&"rangeArea"!==a.chart.type&&"rangeBar"!==e[u].type&&"rangeArea"!==e[u].type||(s.isRangeData=!0,"rangeBar"!==a.chart.type&&"rangeArea"!==a.chart.type||this.handleRangeData(e,u)),this.isMultiFormat())this.isFormat2DArray()?this.handleFormat2DArray(e,u):this.isFormatXY()&&this.handleFormatXY(e,u),"candlestick"!==a.chart.type&&"candlestick"!==e[u].type&&"boxPlot"!==a.chart.type&&"boxPlot"!==e[u].type||this.handleCandleStickBoxData(e,u),s.series.push(this.twoDSeries),s.labels.push(this.twoDSeriesX),s.seriesX.push(this.twoDSeriesX),s.seriesGoals=this.seriesGoals,u!==this.activeSeriesIndex||this.fallbackToCategory||(s.isXNumeric=!0);else{"datetime"===a.xaxis.type?(s.isXNumeric=!0,d(),s.seriesX.push(this.twoDSeriesX)):"numeric"===a.xaxis.type&&(s.isXNumeric=!0,o.length>0&&(this.twoDSeriesX=o,s.seriesX.push(this.twoDSeriesX))),s.labels.push(this.twoDSeriesX);var g=e[u].data.map((function(e){return r.parseNumber(e)}));s.series.push(g)}s.seriesZ.push(this.threeDSeries),void 0!==e[u].color?s.seriesColors.push(e[u].color):s.seriesColors.push(void 0)}return this.w}},{key:"parseDataNonAxisCharts",value:function(e){var t=this.w.globals,i=this.w.config;t.series=e.slice(),t.seriesNames=i.labels.slice();for(var a=0;a<t.series.length;a++)void 0===t.seriesNames[a]&&t.seriesNames.push("series-"+(a+1));return this.w}},{key:"handleExternalLabelsData",value:function(e){var t=this.w.config,i=this.w.globals;t.xaxis.categories.length>0?i.labels=t.xaxis.categories:t.labels.length>0?i.labels=t.labels.slice():this.fallbackToCategory?(i.labels=i.labels[0],i.seriesRange.length&&(i.seriesRange.map((function(e){e.forEach((function(e){i.labels.indexOf(e.x)<0&&e.x&&i.labels.push(e.x)}))})),i.labels=Array.from(new Set(i.labels.map(JSON.stringify)),JSON.parse)),t.xaxis.convertedCatToNumeric&&(new j(t).convertCatToNumericXaxis(t,this.ctx,i.seriesX[0]),this._generateExternalLabels(e))):this._generateExternalLabels(e)}},{key:"_generateExternalLabels",value:function(e){var t=this.w.globals,i=this.w.config,a=[];if(t.axisCharts){if(t.series.length>0)if(this.isFormatXY())for(var r=i.series.map((function(e,t){return e.data.filter((function(e,t,i){return i.findIndex((function(t){return t.x===e.x}))===t}))})),s=r.reduce((function(e,t,i,a){return a[e].length>t.length?e:i}),0),n=0;n<r[s].length;n++)a.push(n+1);else for(var o=0;o<t.series[t.maxValsInArrayIndex].length;o++)a.push(o+1);t.seriesX=[];for(var l=0;l<e.length;l++)t.seriesX.push(a);this.w.globals.isBarHorizontal||(t.isXNumeric=!0)}if(0===a.length){a=t.axisCharts?[]:t.series.map((function(e,t){return t+1}));for(var c=0;c<e.length;c++)t.seriesX.push(a)}t.labels=a,i.xaxis.convertedCatToNumeric&&(t.categoryLabels=a.map((function(e){return i.xaxis.labels.formatter(e)}))),t.noLabelsProvided=!0}},{key:"parseData",value:function(e){var t=this.w,i=t.config,a=t.globals;if(this.excludeCollapsedSeriesInYAxis(),this.fallbackToCategory=!1,this.ctx.core.resetGlobals(),this.ctx.core.isMultipleY(),a.axisCharts?(this.parseDataAxisCharts(e),this.coreUtils.getLargestSeries()):this.parseDataNonAxisCharts(e),i.chart.stacked){var r=new ce(this.ctx);a.series=r.setNullSeriesToZeroValues(a.series)}this.coreUtils.getSeriesTotals(),a.axisCharts&&(a.stackedSeriesTotals=this.coreUtils.getStackedSeriesTotals(),a.stackedSeriesTotalsByGroups=this.coreUtils.getStackedSeriesTotalsByGroups()),this.coreUtils.getPercentSeries(),a.dataFormatXNumeric||a.isXNumeric&&("numeric"!==i.xaxis.type||0!==i.labels.length||0!==i.xaxis.categories.length)||this.handleExternalLabelsData(e);for(var s=this.coreUtils.getCategoryLabels(a.labels),n=0;n<s.length;n++)if(Array.isArray(s[n])){a.isMultiLineX=!0;break}}},{key:"excludeCollapsedSeriesInYAxis",value:function(){var e=this.w,t=[];e.globals.seriesYAxisMap.forEach((function(i,a){var r=0;i.forEach((function(t){-1!==e.globals.collapsedSeriesIndices.indexOf(t)&&r++})),r>0&&r==i.length&&t.push(a)})),e.globals.ignoreYAxisIndexes=t.map((function(e){return e}))}}],i&&de(t.prototype,i),e}();function ge(e){return function(e){if(Array.isArray(e))return fe(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return fe(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?fe(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function fe(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function pe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const xe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"scaleSvgNode",value:function(e,t){var i=parseFloat(e.getAttributeNS(null,"width")),a=parseFloat(e.getAttributeNS(null,"height"));e.setAttributeNS(null,"width",i*t),e.setAttributeNS(null,"height",a*t),e.setAttributeNS(null,"viewBox","0 0 "+i+" "+a)}},{key:"fixSvgStringForIe11",value:function(e){if(!r.isIE11())return e.replace(/&nbsp;/g,"&#160;");var t=0,i=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(i=i.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 i=this.w.globals.dom.Paper.node.cloneNode(!0);this.scaleSvgNode(i,e),t=(new XMLSerializer).serializeToString(i)}return this.fixSvgStringForIe11(t)}},{key:"cleanup",value:function(){var e=this.w,t=e.globals.dom.baseEl.getElementsByClassName("apexcharts-xcrosshairs"),i=e.globals.dom.baseEl.getElementsByClassName("apexcharts-ycrosshairs"),a=e.globals.dom.baseEl.querySelectorAll(".apexcharts-zoom-rect, .apexcharts-selection-rect");Array.prototype.forEach.call(a,(function(e){e.setAttribute("width",0)})),t&&t[0]&&(t[0].setAttribute("x",-500),t[0].setAttribute("x1",-500),t[0].setAttribute("x2",-500)),i&&i[0]&&(i[0].setAttribute("y",-100),i[0].setAttribute("y1",-100),i[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(i){var a=t.w,s=e?e.scale||e.width/a.globals.svgWidth:1;t.cleanup();var n=document.createElement("canvas");n.width=a.globals.svgWidth*s,n.height=parseInt(a.globals.dom.elWrap.style.height,10)*s;var o="transparent"!==a.config.chart.background&&a.config.chart.background?a.config.chart.background:"#fff",l=n.getContext("2d");l.fillStyle=o,l.fillRect(0,0,n.width*s,n.height*s);var c=t.getSvgString(s);if(window.canvg&&r.isIE11()){var h=window.canvg.Canvg.fromString(l,c,{ignoreClear:!0,ignoreDimensions:!0});h.start();var d=n.msToBlob();h.stop(),i({blob:d})}else{var u="data:image/svg+xml,"+encodeURIComponent(c),g=new Image;g.crossOrigin="anonymous",g.onload=function(){if(l.drawImage(g,0,0),n.msToBlob){var e=n.msToBlob();i({blob:e})}else{var t=n.toDataURL("image/png");i({imgURI:t})}},g.src=u}}))}},{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 i=t.imgURI,a=t.blob;a?navigator.msSaveOrOpenBlob(a,e.w.globals.chartID+".png"):e.triggerDownload(i,e.w.config.chart.toolbar.export.png.filename,".png")}))}},{key:"exportToCSV",value:function(e){var t=this,i=e.series,a=e.fileName,s=e.columnDelimiter,n=void 0===s?",":s,o=e.lineDelimiter,l=void 0===o?"\n":o,c=this.w;i||(i=c.config.series);var h,d,u=[],g=[],f="",p=c.globals.series.map((function(e,t){return-1===c.globals.collapsedSeriesIndices.indexOf(t)?e:[]})),x=function(e){return"function"==typeof c.config.chart.toolbar.export.csv.categoryFormatter?c.config.chart.toolbar.export.csv.categoryFormatter(e):"datetime"===c.config.xaxis.type&&String(e).length>=10?new Date(e).toDateString():r.isNumber(e)?e:e.split(n).join("")},b=function(e){return"function"==typeof c.config.chart.toolbar.export.csv.valueFormatter?c.config.chart.toolbar.export.csv.valueFormatter(e):e},v=Math.max.apply(Math,ge(i.map((function(e){return e.data?e.data.length:0})))),m=new ue(this.ctx),y=new L(this.ctx),w=function(e){var i="";if(c.globals.axisCharts){if("category"===c.config.xaxis.type||c.config.xaxis.convertedCatToNumeric)if(c.globals.isBarHorizontal){var a=c.globals.yLabelFormatters[0],s=new ce(t.ctx).getActiveConfigSeriesIndex();i=a(c.globals.labels[e],{seriesIndex:s,dataPointIndex:e,w:c})}else i=y.getLabel(c.globals.labels,c.globals.timescaleLabels,0,e).text;"datetime"===c.config.xaxis.type&&(c.config.xaxis.categories.length?i=c.config.xaxis.categories[e]:c.config.labels.length&&(i=c.config.labels[e]))}else i=c.config.labels[e];return null===i?"nullvalue":(Array.isArray(i)&&(i=i.join(" ")),r.isNumber(i)?i:i.split(n).join(""))};u.push(c.config.chart.toolbar.export.csv.headerCategory),"boxPlot"===c.config.chart.type?(u.push("minimum"),u.push("q1"),u.push("median"),u.push("q3"),u.push("maximum")):"candlestick"===c.config.chart.type?(u.push("open"),u.push("high"),u.push("low"),u.push("close")):"rangeBar"===c.config.chart.type?(u.push("minimum"),u.push("maximum")):i.map((function(e,t){var i=(e.name?e.name:"series-".concat(t))+"";c.globals.axisCharts&&u.push(i.split(n).join("")?i.split(n).join(""):"series-".concat(t))})),c.globals.axisCharts||(u.push(c.config.chart.toolbar.export.csv.headerValue),g.push(u.join(n))),c.globals.allSeriesHasEqualX||!c.globals.axisCharts||c.config.xaxis.categories.length||c.config.labels.length?i.map((function(e,t){c.globals.axisCharts?function(e,t){if(u.length&&0===t&&g.push(u.join(n)),e.data){e.data=e.data.length&&e.data||ge(Array(v)).map((function(){return""}));for(var a=0;a<e.data.length;a++){u=[];var r=w(a);if("nullvalue"!==r){if(r||(m.isFormatXY()?r=i[t].data[a].x:m.isFormat2DArray()&&(r=i[t].data[a]?i[t].data[a][0]:"")),0===t){u.push(x(r));for(var s=0;s<c.globals.series.length;s++){var o,l=m.isFormatXY()?null===(o=i[s].data[a])||void 0===o?void 0:o.y:p[s][a];u.push(b(l))}}("candlestick"===c.config.chart.type||e.type&&"candlestick"===e.type)&&(u.pop(),u.push(c.globals.seriesCandleO[t][a]),u.push(c.globals.seriesCandleH[t][a]),u.push(c.globals.seriesCandleL[t][a]),u.push(c.globals.seriesCandleC[t][a])),("boxPlot"===c.config.chart.type||e.type&&"boxPlot"===e.type)&&(u.pop(),u.push(c.globals.seriesCandleO[t][a]),u.push(c.globals.seriesCandleH[t][a]),u.push(c.globals.seriesCandleM[t][a]),u.push(c.globals.seriesCandleL[t][a]),u.push(c.globals.seriesCandleC[t][a])),"rangeBar"===c.config.chart.type&&(u.pop(),u.push(c.globals.seriesRangeStart[t][a]),u.push(c.globals.seriesRangeEnd[t][a])),u.length&&g.push(u.join(n))}}}}(e,t):((u=[]).push(x(c.globals.labels[t])),u.push(b(p[t])),g.push(u.join(n)))})):(h=new Set,d={},i.forEach((function(e,t){null==e||e.data.forEach((function(e){var a,r;if(m.isFormatXY())a=e.x,r=e.y;else{if(!m.isFormat2DArray())return;a=e[0],r=e[1]}d[a]||(d[a]=Array(i.length).fill("")),d[a][t]=b(r),h.add(a)}))})),u.length&&g.push(u.join(n)),Array.from(h).sort().forEach((function(e){g.push([x(e),d[e].join(n)])}))),f+=g.join(l),this.triggerDownload("data:text/csv; charset=utf-8,"+encodeURIComponent("\ufeff"+f),a||c.config.chart.toolbar.export.csv.filename,".csv")}},{key:"triggerDownload",value:function(e,t,i){var a=document.createElement("a");a.href=e,a.download=(t||this.w.globals.chartID)+i,document.body.appendChild(a),a.click(),document.body.removeChild(a)}}])&&pe(t.prototype,i),e}();function be(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ve=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.elgrid=i,this.w=t.w;var a=this.w;this.axesUtils=new L(t),this.xaxisLabels=a.globals.labels.slice(),a.globals.timescaleLabels.length>0&&!a.globals.isBarHorizontal&&(this.xaxisLabels=a.globals.timescaleLabels.slice()),a.config.xaxis.overwriteCategories&&(this.xaxisLabels=a.config.xaxis.overwriteCategories),this.drawnLabels=[],this.drawnLabelsRects=[],"top"===a.config.xaxis.position?this.offY=0:this.offY=a.globals.gridHeight,this.offY=this.offY+a.config.xaxis.axisBorder.offsetY,this.isCategoryBarHorizontal="bar"===a.config.chart.type&&a.config.plotOptions.bar.horizontal,this.xaxisFontSize=a.config.xaxis.labels.style.fontSize,this.xaxisFontFamily=a.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=a.config.xaxis.labels.style.colors,this.xaxisBorderWidth=a.config.xaxis.axisBorder.width,this.isCategoryBarHorizontal&&(this.xaxisBorderWidth=a.config.yaxis[0].axisBorder.width.toString()),this.xaxisBorderWidth.indexOf("%")>-1?this.xaxisBorderWidth=a.globals.gridWidth*parseInt(this.xaxisBorderWidth,10)/100:this.xaxisBorderWidth=parseInt(this.xaxisBorderWidth,10),this.xaxisBorderHeight=a.config.xaxis.axisBorder.height,this.yaxis=a.config.yaxis[0]}var t,i;return t=e,i=[{key:"drawXaxis",value:function(){var e=this.w,t=new g(this.ctx),i=t.group({class:"apexcharts-xaxis",transform:"translate(".concat(e.config.xaxis.offsetX,", ").concat(e.config.xaxis.offsetY,")")}),a=t.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(e.globals.translateXAxisX,", ").concat(e.globals.translateXAxisY,")")});i.add(a);for(var r=[],s=0;s<this.xaxisLabels.length;s++)r.push(this.xaxisLabels[s]);if(this.drawXAxisLabelAndGroup(!0,t,a,r,e.globals.isXNumeric,(function(e,t){return t})),e.globals.hasXaxisGroups){var n=e.globals.groups;r=[];for(var o=0;o<n.length;o++)r.push(n[o].title);var l={};e.config.xaxis.group.style&&(l.xaxisFontSize=e.config.xaxis.group.style.fontSize,l.xaxisFontFamily=e.config.xaxis.group.style.fontFamily,l.xaxisForeColors=e.config.xaxis.group.style.colors,l.fontWeight=e.config.xaxis.group.style.fontWeight,l.cssClass=e.config.xaxis.group.style.cssClass),this.drawXAxisLabelAndGroup(!1,t,a,r,!1,(function(e,t){return n[e].cols*t}),l)}if(void 0!==e.config.xaxis.title.text){var c=t.group({class:"apexcharts-xaxis-title"}),h=t.drawText({x:e.globals.gridWidth/2+e.config.xaxis.title.offsetX,y:this.offY+parseFloat(this.xaxisFontSize)+("bottom"===e.config.xaxis.position?e.globals.xAxisLabelsHeight:-e.globals.xAxisLabelsHeight-10)+e.config.xaxis.title.offsetY,text:e.config.xaxis.title.text,textAnchor:"middle",fontSize:e.config.xaxis.title.style.fontSize,fontFamily:e.config.xaxis.title.style.fontFamily,fontWeight:e.config.xaxis.title.style.fontWeight,foreColor:e.config.xaxis.title.style.color,cssClass:"apexcharts-xaxis-title-text "+e.config.xaxis.title.style.cssClass});c.add(h),i.add(c)}if(e.config.xaxis.axisBorder.show){var d=e.globals.barPadForNumericAxis,u=t.drawLine(e.globals.padHorizontal+e.config.xaxis.axisBorder.offsetX-d,this.offY,this.xaxisBorderWidth+d,this.offY,e.config.xaxis.axisBorder.color,0,this.xaxisBorderHeight);this.elgrid&&this.elgrid.elGridBorders&&e.config.grid.show?this.elgrid.elGridBorders.add(u):i.add(u)}return i}},{key:"drawXAxisLabelAndGroup",value:function(e,t,i,a,r,s){var n,o=this,l=arguments.length>6&&void 0!==arguments[6]?arguments[6]:{},c=[],h=[],d=this.w,u=l.xaxisFontSize||this.xaxisFontSize,g=l.xaxisFontFamily||this.xaxisFontFamily,f=l.xaxisForeColors||this.xaxisForeColors,p=l.fontWeight||d.config.xaxis.labels.style.fontWeight,x=l.cssClass||d.config.xaxis.labels.style.cssClass,b=d.globals.padHorizontal,v=a.length,m="category"===d.config.xaxis.type?d.globals.dataPoints:v;if(0===m&&v>m&&(m=v),r){var y=m>1?m-1:m;n=d.globals.gridWidth/Math.min(y,v-1),b=b+s(0,n)/2+d.config.xaxis.labels.offsetX}else n=d.globals.gridWidth/m,b=b+s(0,n)+d.config.xaxis.labels.offsetX;for(var w=function(r){var l=b-s(r,n)/2+d.config.xaxis.labels.offsetX;0===r&&1===v&&n/2===b&&1===m&&(l=d.globals.gridWidth/2);var y=o.axesUtils.getLabel(a,d.globals.timescaleLabels,l,r,c,u,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(u)+(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?o.axesUtils.checkLabelBasedOnTickamount(r,y,v):o.axesUtils.checkForOverflowingLabels(r,y,v,c,h),d.config.xaxis.labels.show){var k=t.drawText({x:y.x,y:o.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:p,fontSize:u,fontFamily:g,foreColor:Array.isArray(f)?e&&d.config.xaxis.convertedCatToNumeric?f[d.globals.minX+r-1]:f[r]:f,isPlainText:!1,cssClass:(e?"apexcharts-xaxis-label ":"apexcharts-xaxis-group-label ")+x});if(i.add(k),k.on("click",(function(e){if("function"==typeof d.config.chart.events.xAxisLabelClick){var t=Object.assign({},d,{labelIndex:r});d.config.chart.events.xAxisLabelClick(e,o.ctx,t)}})),e){var A=document.createElementNS(d.globals.SVGNS,"title");A.textContent=Array.isArray(y.text)?y.text.join(" "):y.text,k.node.appendChild(A),""!==y.text&&(c.push(y.text),h.push(y))}}r<v-1&&(b+=s(r+1,n))},k=0;k<=v-1;k++)w(k)}},{key:"drawXaxisInversed",value:function(e){var t,i,a=this,r=this.w,s=new g(this.ctx),n=r.config.yaxis[0].opposite?r.globals.translateYAxisX[e]:0,o=s.group({class:"apexcharts-yaxis apexcharts-xaxis-inversed",rel:e}),l=s.group({class:"apexcharts-yaxis-texts-g apexcharts-xaxis-inversed-texts-g",transform:"translate("+n+", 0)"});o.add(l);var c=[];if(r.config.yaxis[e].show)for(var h=0;h<this.xaxisLabels.length;h++)c.push(this.xaxisLabels[h]);t=r.globals.gridHeight/c.length,i=-t/2.2;var d=r.globals.yLabelFormatters[0],u=r.config.yaxis[0].labels;if(u.show)for(var f=function(n){var o=void 0===c[n]?"":c[n];o=d(o,{seriesIndex:e,dataPointIndex:n,w:r});var h=a.axesUtils.getYAxisForeColor(u.style.colors,e),g=0;Array.isArray(o)&&(g=o.length/2*parseInt(u.style.fontSize,10));var f=u.offsetX-15,p="end";a.yaxis.opposite&&(p="start"),"left"===r.config.yaxis[0].labels.align?(f=u.offsetX,p="start"):"center"===r.config.yaxis[0].labels.align?(f=u.offsetX,p="middle"):"right"===r.config.yaxis[0].labels.align&&(p="end");var x=s.drawText({x:f,y:i+t+u.offsetY-g,text:o,textAnchor:p,foreColor:Array.isArray(h)?h[n]:h,fontSize:u.style.fontSize,fontFamily:u.style.fontFamily,fontWeight:u.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+u.style.cssClass,maxWidth:u.maxWidth});l.add(x),x.on("click",(function(e){if("function"==typeof r.config.chart.events.xAxisLabelClick){var t=Object.assign({},r,{labelIndex:n});r.config.chart.events.xAxisLabelClick(e,a.ctx,t)}}));var b=document.createElementNS(r.globals.SVGNS,"title");if(b.textContent=Array.isArray(o)?o.join(" "):o,x.node.appendChild(b),0!==r.config.yaxis[e].labels.rotate){var v=s.rotateAroundCenter(x.node);x.node.setAttribute("transform","rotate(".concat(r.config.yaxis[e].labels.rotate," 0 ").concat(v.y,")"))}i+=t},p=0;p<=c.length-1;p++)f(p);if(void 0!==r.config.yaxis[0].title.text){var x=s.group({class:"apexcharts-yaxis-title apexcharts-xaxis-title-inversed",transform:"translate("+n+", 0)"}),b=s.drawText({x:r.config.yaxis[0].title.offsetX,y:r.globals.gridHeight/2+r.config.yaxis[0].title.offsetY,text:r.config.yaxis[0].title.text,textAnchor:"middle",foreColor:r.config.yaxis[0].title.style.color,fontSize:r.config.yaxis[0].title.style.fontSize,fontWeight:r.config.yaxis[0].title.style.fontWeight,fontFamily:r.config.yaxis[0].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+r.config.yaxis[0].title.style.cssClass});x.add(b),o.add(x)}var v=0;this.isCategoryBarHorizontal&&r.config.yaxis[0].opposite&&(v=r.globals.gridWidth);var m=r.config.xaxis.axisBorder;if(m.show){var y=s.drawLine(r.globals.padHorizontal+m.offsetX+v,1+m.offsetY,r.globals.padHorizontal+m.offsetX+v,r.globals.gridHeight+m.offsetY,m.color,0);this.elgrid&&this.elgrid.elGridBorders&&r.config.grid.show?this.elgrid.elGridBorders.add(y):o.add(y)}return r.config.yaxis[0].axisTicks.show&&this.axesUtils.drawYAxisTicks(v,c.length,r.config.yaxis[0].axisBorder,r.config.yaxis[0].axisTicks,0,t,o),o}},{key:"drawXaxisTicks",value:function(e,t,i){var a=this.w,r=e;if(!(e<0||e-2>a.globals.gridWidth)){var s=this.offY+a.config.xaxis.axisTicks.offsetY;if(t=t+s+a.config.xaxis.axisTicks.height,"top"===a.config.xaxis.position&&(t=s-a.config.xaxis.axisTicks.height),a.config.xaxis.axisTicks.show){var n=new g(this.ctx).drawLine(e+a.config.xaxis.axisTicks.offsetX,s+a.config.xaxis.offsetY,r+a.config.xaxis.axisTicks.offsetX,t+a.config.xaxis.offsetY,a.config.xaxis.axisTicks.color);i.add(n),n.node.classList.add("apexcharts-xaxis-tick")}}}},{key:"getXAxisTicksPositions",value:function(){var e=this.w,t=[],i=this.xaxisLabels.length,a=e.globals.padHorizontal;if(e.globals.timescaleLabels.length>0)for(var r=0;r<i;r++)a=this.xaxisLabels[r].position,t.push(a);else for(var s=i,n=0;n<s;n++){var o=s;e.globals.isXNumeric&&"bar"!==e.config.chart.type&&(o-=1),a+=e.globals.gridWidth/o,t.push(a)}return t}},{key:"xAxisLabelCorrections",value:function(){var e=this.w,t=new g(this.ctx),i=e.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g"),a=e.globals.dom.baseEl.querySelectorAll(".apexcharts-xaxis-texts-g text:not(.apexcharts-xaxis-group-label)"),r=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-inversed text"),s=e.globals.dom.baseEl.querySelectorAll(".apexcharts-xaxis-inversed-texts-g text tspan");if(e.globals.rotateXLabels||e.config.xaxis.labels.rotateAlways)for(var n=0;n<a.length;n++){var o=t.rotateAroundCenter(a[n]);o.y=o.y-1,o.x=o.x+1,a[n].setAttribute("transform","rotate(".concat(e.config.xaxis.labels.rotate," ").concat(o.x," ").concat(o.y,")")),a[n].setAttribute("text-anchor","end"),i.setAttribute("transform","translate(0, ".concat(-10,")"));var l=a[n].childNodes;e.config.xaxis.labels.trim&&Array.prototype.forEach.call(l,(function(i){t.placeTextWithEllipsis(i,i.textContent,e.globals.xAxisLabelsHeight-("bottom"===e.config.legend.position?20:10))}))}else!function(){for(var i=e.globals.gridWidth/(e.globals.labels.length+1),r=0;r<a.length;r++){var s=a[r].childNodes;e.config.xaxis.labels.trim&&"datetime"!==e.config.xaxis.type&&Array.prototype.forEach.call(s,(function(e){t.placeTextWithEllipsis(e,e.textContent,i)}))}}();if(r.length>0){var c=r[r.length-1].getBBox(),h=r[0].getBBox();c.x<-20&&r[r.length-1].parentNode.removeChild(r[r.length-1]),h.x+h.width>e.globals.gridWidth&&!e.globals.isBarHorizontal&&r[0].parentNode.removeChild(r[0]);for(var d=0;d<s.length;d++)t.placeTextWithEllipsis(s[d],s[d].textContent,e.config.yaxis[0].labels.maxWidth-(e.config.yaxis[0].title.text?2*parseFloat(e.config.yaxis[0].title.style.fontSize):0)-15)}}}],i&&be(t.prototype,i),e}();function me(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ye=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.w;this.xaxisLabels=i.globals.labels.slice(),this.axesUtils=new L(t),this.isRangeBar=i.globals.seriesRange.length&&i.globals.isBarHorizontal,i.globals.timescaleLabels.length>0&&(this.xaxisLabels=i.globals.timescaleLabels.slice())}var t,i;return t=e,i=[{key:"drawGridArea",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=this.w,i=new g(this.ctx);null===e&&(e=i.group({class:"apexcharts-grid"}));var a=i.drawLine(t.globals.padHorizontal,1,t.globals.padHorizontal,t.globals.gridHeight,"transparent"),r=i.drawLine(t.globals.padHorizontal,t.globals.gridHeight,t.globals.gridWidth,t.globals.gridHeight,"transparent");return e.add(r),e.add(a),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,i=new g(this.ctx),a=Array.isArray(e.config.stroke.width)?0:e.config.stroke.width;if(Array.isArray(e.config.stroke.width)){var r=0;e.config.stroke.width.forEach((function(e){r=Math.max(r,e)})),a=r}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 s=e.config.chart.type,n=0,o=0;("bar"===s||"rangeBar"===s||"candlestick"===s||"boxPlot"===s||e.globals.comboBarCount>0)&&e.globals.isXNumeric&&!e.globals.isBarHorizontal&&(n=e.config.grid.padding.left,o=e.config.grid.padding.right,t.barPadForNumericAxis>n&&(n=t.barPadForNumericAxis,o=t.barPadForNumericAxis)),t.dom.elGridRect=i.drawRect(-a/2-n-2,-a/2-2,t.gridWidth+a+o+n+4,t.gridHeight+a+4,0,"#fff");var l=e.globals.markers.largestSize+1;t.dom.elGridRectMarker=i.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,i=e.x1,a=e.y1,r=e.x2,s=e.y2,n=e.xCount,o=e.parent,l=this.w;if(!(0===t&&l.globals.skipFirstTimelinelabel||t===n-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:i,y1:a,x2:r,y2:s,xCount:n,parent:o});var c=0;if(l.globals.hasXaxisGroups&&"between"===l.config.xaxis.tickPlacement){var h=l.globals.groups;if(h){for(var d=0,u=0;d<t&&u<h.length;u++)d+=h[u].cols;d===t&&(c=.6*l.globals.xAxisLabelsHeight)}}new ve(this.ctx).drawXaxisTicks(i,c,l.globals.dom.elGraphical)}}},{key:"_drawGridLine",value:function(e){var t=e.i,i=e.x1,a=e.y1,r=e.x2,s=e.y2,n=e.xCount,o=e.parent,l=this.w,c=!1,h=o.node.classList.contains("apexcharts-gridlines-horizontal"),d=l.config.grid.strokeDashArray,u=l.globals.barPadForNumericAxis;(0===a&&0===s||0===i&&0===r)&&(c=!0),a===l.globals.gridHeight&&s===l.globals.gridHeight&&(c=!0),!l.globals.isBarHorizontal||0!==t&&t!==n-1||(c=!0);var f=new g(this).drawLine(i-(h?u:0),a,r+(h?u:0),s,l.config.grid.borderColor,d);f.node.classList.add("apexcharts-gridline"),c&&l.config.grid.show?this.elGridBorders.add(f):o.add(f)}},{key:"_drawGridBandRect",value:function(e){var t=e.c,i=e.x1,a=e.y1,r=e.x2,s=e.y2,n=e.type,o=this.w,l=new g(this.ctx),c=o.globals.barPadForNumericAxis;if("column"!==n||"datetime"!==o.config.xaxis.type){var h=o.config.grid[n].colors[t],d=l.drawRect(i-("row"===n?c:0),a,r+("row"===n?2*c:0),s,0,h,o.config.grid[n].opacity);this.elg.add(d),d.attr("clip-path","url(#gridRectMask".concat(o.globals.cuid,")")),d.node.classList.add("apexcharts-grid-".concat(n))}}},{key:"_drawXYLines",value:function(e){var t=this,i=e.xCount,a=e.tickAmount,r=this.w;if(r.config.grid.xaxis.lines.show||r.config.xaxis.axisTicks.show){var s,n=r.globals.padHorizontal,o=r.globals.gridHeight;r.globals.timescaleLabels.length?function(e){for(var a=e.xC,r=e.x1,s=e.y1,n=e.x2,o=e.y2,l=0;l<a;l++)r=t.xaxisLabels[l].position,n=t.xaxisLabels[l].position,t._drawGridLines({i:l,x1:r,y1:s,x2:n,y2:o,xCount:i,parent:t.elgridLinesV})}({xC:i,x1:n,y1:0,x2:s,y2:o}):(r.globals.isXNumeric&&(i=r.globals.xAxisScale.result.length),function(e){for(var a=e.xC,s=e.x1,n=e.y1,o=e.x2,l=e.y2,c=0;c<a+(r.globals.isXNumeric?0:1);c++)0===c&&1===a&&1===r.globals.dataPoints&&(o=s=r.globals.gridWidth/2),t._drawGridLines({i:c,x1:s,y1:n,x2:o,y2:l,xCount:i,parent:t.elgridLinesV}),o=s+=r.globals.gridWidth/(r.globals.isXNumeric?a-1:a)}({xC:i,x1:n,y1:0,x2:s,y2:o}))}if(r.config.grid.yaxis.lines.show){var l=0,c=0,h=r.globals.gridWidth,d=a+1;this.isRangeBar&&(d=r.globals.labels.length);for(var u=0;u<d+(this.isRangeBar?1:0);u++)this._drawGridLine({i:u,xCount:d+(this.isRangeBar?1:0),x1:0,y1:l,x2:h,y2:c,parent:this.elgridLinesH}),c=l+=r.globals.gridHeight/(this.isRangeBar?d:a)}}},{key:"_drawInvertedXYLines",value:function(e){var t=e.xCount,i=this.w;if(i.config.grid.xaxis.lines.show||i.config.xaxis.axisTicks.show)for(var a,r=i.globals.padHorizontal,s=i.globals.gridHeight,n=0;n<t+1;n++)i.config.grid.xaxis.lines.show&&this._drawGridLine({i:n,xCount:t+1,x1:r,y1:0,x2:a,y2:s,parent:this.elgridLinesV}),new ve(this.ctx).drawXaxisTicks(r,0,i.globals.dom.elGraphical),a=r+=i.globals.gridWidth/t;if(i.config.grid.yaxis.lines.show)for(var o=0,l=0,c=i.globals.gridWidth,h=0;h<i.globals.dataPoints+1;h++)this._drawGridLine({i:h,xCount:i.globals.dataPoints+1,x1:0,y1:o,x2:c,y2:l,parent:this.elgridLinesH}),l=o+=i.globals.gridHeight/i.globals.dataPoints}},{key:"renderGrid",value:function(){var e=this.w,t=e.globals,i=new g(this.ctx);this.elg=i.group({class:"apexcharts-grid"}),this.elgridLinesH=i.group({class:"apexcharts-gridlines-horizontal"}),this.elgridLinesV=i.group({class:"apexcharts-gridlines-vertical"}),this.elGridBorders=i.group({class:"apexcharts-grid-borders"}),this.elg.add(this.elgridLinesH),this.elg.add(this.elgridLinesV),e.config.grid.show||(this.elgridLinesV.hide(),this.elgridLinesH.hide(),this.elGridBorders.hide());for(var a=0;a<t.seriesYAxisMap.length&&-1!==t.ignoreYAxisIndexes.indexOf(a);)a++;a===t.seriesYAxisMap.length&&(a=0);var r,s,n,o,l=t.yAxisScale[a].result.length-1;return!t.isBarHorizontal||this.isRangeBar?(r=this.xaxisLabels.length,this.isRangeBar&&(l=t.labels.length,e.config.xaxis.tickAmount&&e.config.xaxis.labels.formatter&&(r=e.config.xaxis.tickAmount),(null===(s=t.yAxisScale)||void 0===s||null===(n=s[a])||void 0===n||null===(o=n.result)||void 0===o?void 0:o.length)>0&&"datetime"!==e.config.xaxis.type&&(r=t.yAxisScale[a].result.length-1)),this._drawXYLines({xCount:r,tickAmount:l})):(r=l,l=t.xTickAmount,this._drawInvertedXYLines({xCount:r,tickAmount:l})),this.drawGridBands(r,l),{el:this.elg,elGridBorders:this.elGridBorders,xAxisTickWidth:t.gridWidth/r}}},{key:"drawGridBands",value:function(e,t){var i=this.w;if(void 0!==i.config.grid.row.colors&&i.config.grid.row.colors.length>0)for(var a=0,r=i.globals.gridHeight/t,s=i.globals.gridWidth,n=0,o=0;n<t;n++,o++)o>=i.config.grid.row.colors.length&&(o=0),this._drawGridBandRect({c:o,x1:0,y1:a,x2:s,y2:r,type:"row"}),a+=i.globals.gridHeight/t;if(void 0!==i.config.grid.column.colors&&i.config.grid.column.colors.length>0)for(var l=i.globals.isBarHorizontal||"on"!==i.config.xaxis.tickPlacement||"category"!==i.config.xaxis.type&&!i.config.xaxis.convertedCatToNumeric?e:e-1,c=i.globals.padHorizontal,h=i.globals.padHorizontal+i.globals.gridWidth/l,d=i.globals.gridHeight,u=0,g=0;u<e;u++,g++)g>=i.config.grid.column.colors.length&&(g=0),this._drawGridBandRect({c:g,x1:c,y1:0,x2:h,y2:d,type:"column"}),c+=i.globals.gridWidth/l}}],i&&me(t.prototype,i),e}();function we(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ke=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"niceScale",value:function(e,t){var i,a,s,n,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,l=1e-11,c=this.w,h=c.globals;h.isBarHorizontal?(i=c.config.xaxis,a=Math.max((h.svgWidth-100)/25,2)):(i=c.config.yaxis[o],a=Math.max((h.svgHeight-100)/15,2)),s=void 0!==i.min&&null!==i.min,n=void 0!==i.max&&null!==i.min;var d=void 0!==i.stepSize&&null!==i.stepSize,u=void 0!==i.tickAmount&&null!==i.tickAmount,g=u?i.tickAmount:i.forceNiceScale?h.niceScaleDefaultTicks[Math.min(Math.round(a/2),h.niceScaleDefaultTicks.length-1)]:10;if(h.isMultipleYAxis&&!u&&h.multiAxisTickAmount>0&&(g=h.multiAxisTickAmount,u=!0),g="dataPoints"===g?h.dataPoints-1:Math.abs(Math.round(g)),(e===Number.MIN_VALUE&&0===t||!r.isNumber(e)&&!r.isNumber(t)||e===Number.MIN_VALUE&&t===-Number.MAX_VALUE)&&(e=r.isNumber(i.min)?i.min:0,t=r.isNumber(i.max)?i.max:e+g,h.allSeriesCollapsed=!1),e>t){console.warn("axis.min cannot be greater than axis.max: swapping min and max");var f=t;t=e,e=f}else e===t&&(e=0===e?0:e-1,t=0===t?2:t+1);var p=[];g<1&&(g=1);var x=g,b=Math.abs(t-e);i.forceNiceScale&&(!s&&e>0&&e/b<.15&&(e=0,s=!0),!n&&t<0&&-t/b<.15&&(t=0,n=!0),b=Math.abs(t-e));var v=b/x,m=v,y=Math.floor(Math.log10(m)),w=Math.pow(10,y),k=Math.ceil(m/w);if(v=m=(k=h.niceScaleAllowedMagMsd[0===h.yValueDecimal?0:1][k])*w,h.isBarHorizontal&&i.stepSize&&"datetime"!==i.type?(v=i.stepSize,d=!0):d&&(v=i.stepSize),d&&i.forceNiceScale){var A=Math.floor(Math.log10(v));v*=Math.pow(10,y-A)}if(s&&n){var S=b/x;if(u)if(d)if(0!=r.mod(b,v)){var C=r.getGCD(v,S);v=S/C<10?C:S}else 0==r.mod(v,S)?v=S:(S=v,u=!1);else v=S;else if(d)0==r.mod(b,v)?S=v:v=S;else if(0==r.mod(b,v))S=v;else{S=b/(x=Math.ceil(b/v));var P=r.getGCD(b,v);b/P<a&&(S=P),v=S}x=Math.round(b/v)}else{if(s||n){if(n)if(u)e=t-v*x;else{var L=e;e=v*Math.floor(e/v),Math.abs(t-e)/r.getGCD(b,v)>a&&(e=t-v*g,e+=v*Math.floor((L-e)/v))}else if(s)if(u)t=e+v*x;else{var O=t;t=v*Math.ceil(t/v),Math.abs(t-e)/r.getGCD(b,v)>a&&(t=e+v*g,t+=v*Math.ceil((O-t)/v))}}else if(u){var M=v/(t-e>t?1:2),T=M*Math.floor(e/M);Math.abs(T-e)<=M/2?t=(e=T)+v*x:e=(t=M*Math.ceil(t/M))-v*x}else e=v*Math.floor(e/v),t=v*Math.ceil(t/v);b=Math.abs(t-e),v=r.getGCD(b,v),x=Math.round(b/v)}if(u||s||n||(x=Math.ceil((b-l)/(v+l)))>16&&r.getPrimeFactors(x).length<2&&x++,!u&&i.forceNiceScale&&0===h.yValueDecimal&&x>b&&(x=b,v=Math.round(b/x)),x>a&&(!u&&!d||i.forceNiceScale)){var I=r.getPrimeFactors(x),E=I.length-1,z=x;e:for(var X=0;X<E;X++)for(var Y=0;Y<=E-X;Y++){for(var D=Math.min(Y+X,E),R=z,F=1,H=Y;H<=D;H++)F*=I[H];if((R/=F)<a){z=R;break e}}v=z===x?b:b/z,x=Math.round(b/v)}h.isMultipleYAxis&&0==h.multiAxisTickAmount&&h.ignoreYAxisIndexes.indexOf(o)<0&&(h.multiAxisTickAmount=x);var N=e-v,W=v*l;do{N+=v,p.push(r.stripNumber(N,7))}while(t-N>W);return{result:p,niceMin:p[0],niceMax:p[p.length-1]}}},{key:"linearScale",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0,n=Math.abs(t-e),o=[];if(e===t)return{result:o=[e],niceMin:o[0],niceMax:o[o.length-1]};"dataPoints"===(i=this._adjustTicksForSmallRange(i,a,n))&&(i=this.w.globals.dataPoints-1),s||(s=n/i),s=Math.round(10*(s+Number.EPSILON))/10,i===Number.MAX_VALUE&&(i=5,s=1);for(var l=e;i>=0;)o.push(l),l=r.preciseAddition(l,s),i-=1;return{result:o,niceMin:o[0],niceMax:o[o.length-1]}}},{key:"logarithmicScaleNice",value:function(e,t,i){t<=0&&(t=Math.max(e,i)),e<=0&&(e=Math.min(t,i));for(var a=[],r=Math.ceil(Math.log(t)/Math.log(i)+1),s=Math.floor(Math.log(e)/Math.log(i));s<r;s++)a.push(Math.pow(i,s));return{result:a,niceMin:a[0],niceMax:a[a.length-1]}}},{key:"logarithmicScale",value:function(e,t,i){t<=0&&(t=Math.max(e,i)),e<=0&&(e=Math.min(t,i));for(var a=[],r=Math.log(t)/Math.log(i),s=Math.log(e)/Math.log(i),n=r-s,o=Math.round(n),l=n/o,c=0,h=s;c<o;c++,h+=l)a.push(Math.pow(i,h));return a.push(Math.pow(i,r)),{result:a,niceMin:e,niceMax:t}}},{key:"_adjustTicksForSmallRange",value:function(e,t,i){var a=e;if(void 0!==t&&this.w.config.yaxis[t].labels.formatter&&void 0===this.w.config.yaxis[t].tickAmount){var s=Number(this.w.config.yaxis[t].labels.formatter(1));r.isNumber(s)&&0===this.w.globals.yValueDecimal&&(a=Math.ceil(i))}return a<e?a:e}},{key:"setYScaleForIndex",value:function(e,t,i){var a=this.w.globals,s=this.w.config,n=a.isBarHorizontal?s.xaxis:s.yaxis[e];void 0===a.yAxisScale[e]&&(a.yAxisScale[e]=[]);var o=Math.abs(i-t);n.logarithmic&&o<=5&&(a.invalidLogScale=!0),n.logarithmic&&o>5?(a.allSeriesCollapsed=!1,a.yAxisScale[e]=n.forceNiceScale?this.logarithmicScaleNice(t,i,n.logBase):this.logarithmicScale(t,i,n.logBase)):i!==-Number.MAX_VALUE&&r.isNumber(i)&&t!==Number.MAX_VALUE&&r.isNumber(t)?(a.allSeriesCollapsed=!1,a.yAxisScale[e]=this.niceScale(t,i,e)):a.yAxisScale[e]=this.niceScale(Number.MIN_VALUE,0,e)}},{key:"setXScale",value:function(e,t){var i=this.w,a=i.globals,s=Math.abs(t-e);if(t!==-Number.MAX_VALUE&&r.isNumber(t)){var n=a.xTickAmount+1;s<10&&s>1&&(n=s),a.xAxisScale=this.linearScale(e,t,n,0,i.config.xaxis.stepSize)}else a.xAxisScale=this.linearScale(0,10,10);return a.xAxisScale}},{key:"setSeriesYAxisMappings",value:function(){var e=this.w.globals,t=this.w.config,i=[],a=[],r=[],s=e.series.length>t.yaxis.length||t.yaxis.some((function(e){return Array.isArray(e.seriesName)}));t.series.forEach((function(e,t){r.push(t),a.push(null)})),t.yaxis.forEach((function(e,t){i[t]=[]}));var n=[];t.yaxis.forEach((function(e,a){var o=!1;if(e.seriesName){var l=[];Array.isArray(e.seriesName)?l=e.seriesName:l.push(e.seriesName),l.forEach((function(e){t.series.forEach((function(t,n){if(t.name===e){var l=n;a===n||s?!s||r.indexOf(n)>-1?i[a].push([a,n]):console.warn("Series '"+t.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(i[n].push([n,a]),l=a),o=!0,-1!==(l=r.indexOf(l))&&r.splice(l,1)}}))}))}o||n.push(a)})),i=i.map((function(e,t){var i=[];return e.forEach((function(e){a[e[1]]=e[0],i.push(e[1])})),i}));for(var o=t.yaxis.length-1,l=0;l<n.length&&(o=n[l],i[o]=[],r);l++){var c=r[0];r.shift(),i[o].push(c),a[c]=o}r.forEach((function(e){i[o].push(e),a[e]=o})),e.seriesYAxisMap=i.map((function(e){return e})),e.seriesYAxisReverseMap=a.map((function(e){return e}))}},{key:"scaleMultipleYAxes",value:function(){var e=this,t=this.w.config,i=this.w.globals;this.setSeriesYAxisMappings();var a=i.seriesYAxisMap,r=i.minYArr,s=i.maxYArr;i.allSeriesCollapsed=!0,i.barGroups=[],a.forEach((function(a,n){var o=[];a.forEach((function(e){var i=t.series[e].group;o.indexOf(i)<0&&o.push(i)})),a.length>0?function(){var l,c,h=Number.MAX_VALUE,d=-Number.MAX_VALUE,u=h,g=d;if(t.chart.stacked)!function(){var e=i.seriesX[a[0]],r=[],s=[],f=[];o.forEach((function(){r.push(e.map((function(){return Number.MIN_VALUE}))),s.push(e.map((function(){return Number.MIN_VALUE}))),f.push(e.map((function(){return Number.MIN_VALUE})))}));for(var p=function(e){!l&&t.series[a[e]].type&&(l=t.series[a[e]].type);var h=a[e];c=t.series[h].group?t.series[h].group:"axis-".concat(n),!(i.collapsedSeriesIndices.indexOf(h)<0&&i.ancillaryCollapsedSeriesIndices.indexOf(h)<0)||(i.allSeriesCollapsed=!1,o.forEach((function(e,a){if(t.series[h].group===e)for(var n=0;n<i.series[h].length;n++){var o=i.series[h][n];o>=0?s[a][n]+=o:f[a][n]+=o,r[a][n]+=o,u=Math.min(u,o),g=Math.max(g,o)}}))),"bar"!==l&&"column"!==l||i.barGroups.push(c)},x=0;x<a.length;x++)p(x);l||(l=t.chart.type),"bar"===l||"column"===l?o.forEach((function(e,t){h=Math.min(h,Math.min.apply(null,f[t])),d=Math.max(d,Math.max.apply(null,s[t]))})):(o.forEach((function(e,t){u=Math.min(u,Math.min.apply(null,r[t])),g=Math.max(g,Math.max.apply(null,r[t]))})),h=u,d=g),h===Number.MIN_VALUE&&d===Number.MIN_VALUE&&(d=-Number.MAX_VALUE)}();else for(var f=0;f<a.length;f++){var p=a[f];h=Math.min(h,r[p]),d=Math.max(d,s[p]),!(i.collapsedSeriesIndices.indexOf(p)<0&&i.ancillaryCollapsedSeriesIndices.indexOf(p)<0)||(i.allSeriesCollapsed=!1)}void 0!==t.yaxis[n].min&&(h="function"==typeof t.yaxis[n].min?t.yaxis[n].min(h):t.yaxis[n].min),void 0!==t.yaxis[n].max&&(d="function"==typeof t.yaxis[n].max?t.yaxis[n].max(d):t.yaxis[n].max),i.barGroups=i.barGroups.filter((function(e,t,i){return i.indexOf(e)===t})),e.setYScaleForIndex(n,h,d),a.forEach((function(e){r[e]=i.yAxisScale[n].niceMin,s[e]=i.yAxisScale[n].niceMax}))}():e.setYScaleForIndex(n,0,-Number.MAX_VALUE)}))}}],i&&we(t.prototype,i),e}();function Ae(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Se(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const Ce=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.scales=new ke(t)}var t,i;return t=e,i=[{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,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:-Number.MAX_VALUE,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=this.w.config,n=this.w.globals,o=-Number.MAX_VALUE,l=Number.MIN_VALUE;null===a&&(a=e+1);var c=n.series,h=c,d=c;"candlestick"===s.chart.type?(h=n.seriesCandleL,d=n.seriesCandleH):"boxPlot"===s.chart.type?(h=n.seriesCandleO,d=n.seriesCandleC):n.isRangeData&&(h=n.seriesRangeStart,d=n.seriesRangeEnd);var u=!1;if(n.seriesX.length>=a){var g,f=null===(g=n.brushSource)||void 0===g?void 0:g.w.config.chart.brush;(s.chart.zoom.enabled&&s.chart.zoom.autoScaleYaxis||null!=f&&f.enabled&&null!=f&&f.autoScaleYaxis)&&(u=!0)}for(var p=e;p<a;p++){n.dataPoints=Math.max(n.dataPoints,c[p].length);var x=s.series[p].type;n.categoryLabels.length&&(n.dataPoints=n.categoryLabels.filter((function(e){return void 0!==e})).length),n.labels.length&&"datetime"!==s.xaxis.type&&0!==n.series.reduce((function(e,t){return e+t.length}),0)&&(n.dataPoints=Math.max(n.dataPoints,n.labels.length));var b=0,v=c[p].length-1;if(u){if(s.xaxis.min)for(;b<v&&n.seriesX[p][b]<s.xaxis.min;b++);if(s.xaxis.max)for(;v>b&&n.seriesX[p][v]>s.xaxis.max;v--);}for(var m=b;m<=v&&m<n.series[p].length;m++){var y=c[p][m];if(null!==y&&r.isNumber(y)){switch(void 0!==d[p][m]&&(o=Math.max(o,d[p][m]),t=Math.min(t,d[p][m])),void 0!==h[p][m]&&(t=Math.min(t,h[p][m]),i=Math.max(i,h[p][m])),x){case"candlestick":void 0!==n.seriesCandleC[p][m]&&(o=Math.max(o,n.seriesCandleH[p][m]),t=Math.min(t,n.seriesCandleL[p][m]));break;case"boxPlot":void 0!==n.seriesCandleC[p][m]&&(o=Math.max(o,n.seriesCandleC[p][m]),t=Math.min(t,n.seriesCandleO[p][m]))}x&&"candlestick"!==x&&"boxPlot"!==x&&"rangeArea"!==x&&"rangeBar"!==x&&(o=Math.max(o,n.series[p][m]),t=Math.min(t,n.series[p][m])),i=o,n.seriesGoals[p]&&n.seriesGoals[p][m]&&Array.isArray(n.seriesGoals[p][m])&&n.seriesGoals[p][m].forEach((function(e){l!==Number.MIN_VALUE&&(l=Math.min(l,e.value),t=l),o=Math.max(o,e.value),i=o})),r.isFloat(y)&&(y=r.noExponents(y),n.yValueDecimal=Math.max(n.yValueDecimal,y.toString().split(".")[1].length)),l>h[p][m]&&h[p][m]<0&&(l=h[p][m])}else n.hasNullValues=!0}"bar"!==x&&"column"!==x||(l<0&&o<0&&(o=0,i=Math.max(i,0)),l===Number.MIN_VALUE&&(l=0,t=Math.min(t,0)))}return"rangeBar"===s.chart.type&&n.seriesRangeStart.length&&n.isBarHorizontal&&(l=t),"bar"===s.chart.type&&(l<0&&o<0&&(o=0),l===Number.MIN_VALUE&&(l=0)),{minY:l,maxY:o,lowestY:t,highestY:i}}},{key:"setYRange",value:function(){var e=this.w.globals,t=this.w.config;e.maxY=-Number.MAX_VALUE,e.minY=Number.MIN_VALUE;var i,a=Number.MAX_VALUE;if(e.isMultipleYAxis){a=Number.MAX_VALUE;for(var r=0;r<e.series.length;r++)i=this.getMinYMaxY(r),e.minYArr[r]=i.lowestY,e.maxYArr[r]=i.highestY,a=Math.min(a,i.lowestY)}return i=this.getMinYMaxY(0,a,null,e.series.length),"bar"===t.chart.type?(e.minY=i.minY,e.maxY=i.maxY):(e.minY=i.lowestY,e.maxY=i.highestY),a=i.lowestY,t.chart.stacked&&this._setStackedMinMax(),"line"===t.chart.type||"area"===t.chart.type||"scatter"===t.chart.type||"candlestick"===t.chart.type||"boxPlot"===t.chart.type||"rangeBar"===t.chart.type&&!e.isBarHorizontal?e.minY===Number.MIN_VALUE&&a!==-Number.MAX_VALUE&&a!==e.maxY&&(e.minY=a):e.minY=i.minY,t.yaxis.forEach((function(t,i){void 0!==t.max&&("number"==typeof t.max?e.maxYArr[i]=t.max:"function"==typeof t.max&&(e.maxYArr[i]=t.max(e.isMultipleYAxis?e.maxYArr[i]:e.maxY)),e.maxY=e.maxYArr[i]),void 0!==t.min&&("number"==typeof t.min?e.minYArr[i]=t.min:"function"==typeof t.min&&(e.minYArr[i]=t.min(e.isMultipleYAxis?e.minYArr[i]===Number.MIN_VALUE?0:e.minYArr[i]:e.minY)),e.minY=e.minYArr[i])})),e.isBarHorizontal&&["min","max"].forEach((function(i){void 0!==t.xaxis[i]&&"number"==typeof t.xaxis[i]&&("min"===i?e.minY=t.xaxis[i]:e.maxY=t.xaxis[i])})),e.isMultipleYAxis?(this.scales.scaleMultipleYAxes(),e.minY=a):(this.scales.setYScaleForIndex(0,e.minY,e.maxY),e.minY=e.yAxisScale[0].niceMin,e.maxY=e.yAxisScale[0].niceMax,e.minYArr[0]=e.minY,e.maxYArr[0]=e.maxY),e.barGroups=[],e.lineGroups=[],e.areaGroups=[],t.series.forEach((function(i){switch(i.type||t.chart.type){case"bar":case"column":e.barGroups.push(i.group);break;case"line":e.lineGroups.push(i.group);break;case"area":e.areaGroups.push(i.group)}})),e.barGroups=e.barGroups.filter((function(e,t,i){return i.indexOf(e)===t})),e.lineGroups=e.lineGroups.filter((function(e,t,i){return i.indexOf(e)===t})),e.areaGroups=e.areaGroups.filter((function(e,t,i){return i.indexOf(e)===t})),{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,i="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;t<e.series.length;t++)if(e.labels[t])for(var i=0;i<e.labels[t].length;i++)null!==e.labels[t][i]&&r.isNumber(e.labels[t][i])&&(e.maxX=Math.max(e.maxX,e.labels[t][i]),e.initialMaxX=Math.max(e.maxX,e.labels[t][i]),e.minX=Math.min(e.minX,e.labels[t][i]),e.initialMinX=Math.min(e.minX,e.labels[t][i]))}(),e.noLabelsProvided&&0===t.xaxis.categories.length&&(e.maxX=e.labels[e.labels.length-1],e.initialMaxX=e.labels[e.labels.length-1],e.minX=1,e.initialMinX=1),e.isXNumeric||e.noLabelsProvided||e.dataFormatXNumeric){var a;if(void 0===t.xaxis.tickAmount?(a=Math.round(e.svgWidth/150),"numeric"===t.xaxis.type&&e.dataPoints<30&&(a=e.dataPoints-1),a>e.dataPoints&&0!==e.dataPoints&&(a=e.dataPoints-1)):"dataPoints"===t.xaxis.tickAmount?(e.series.length>1&&(a=e.series[e.maxValsInArrayIndex].length-1),e.isXNumeric&&(a=e.maxX-e.minX-1)):a=t.xaxis.tickAmount,e.xTickAmount=a,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 s=[],n=e.minX-1;n<e.maxX;n++)s.push(n+1);e.xAxisScale={result:s,niceMin:s[0],niceMax:s[s.length-1]}}else e.xAxisScale=this.scales.setXScale(e.minX,e.maxX);else e.xAxisScale=this.scales.linearScale(0,a,a,0,t.xaxis.stepSize),e.noLabelsProvided&&e.labels.length>0&&(e.xAxisScale=this.scales.linearScale(1,e.labels.length,a-1,0,t.xaxis.stepSize),e.seriesX=e.labels.slice());i&&(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;t<e.series.length;t++)if(void 0!==e.seriesZ[t])for(var i=0;i<e.seriesZ[t].length;i++)null!==e.seriesZ[t][i]&&r.isNumber(e.seriesZ[t][i])&&(e.maxZ=Math.max(e.maxZ,e.seriesZ[t][i]),e.minZ=Math.min(e.minZ,e.seriesZ[t][i]))}},{key:"_handleSingleDataPoint",value:function(){var e=this.w.globals,t=this.w.config;if(e.minX===e.maxX){var i=new A(this.ctx);if("datetime"===t.xaxis.type){var a=i.getDate(e.minX);t.xaxis.labels.datetimeUTC?a.setUTCDate(a.getUTCDate()-2):a.setDate(a.getDate()-2),e.minX=new Date(a).getTime();var r=i.getDate(e.maxX);t.xaxis.labels.datetimeUTC?r.setUTCDate(r.getUTCDate()+2):r.setDate(r.getDate()+2),e.maxX=new Date(r).getTime()}else("numeric"===t.xaxis.type||"category"===t.xaxis.type&&!e.noLabelsProvided)&&(e.minX=e.minX-2,e.initialMinX=e.minX,e.maxX=e.maxX+2,e.initialMaxX=e.maxX)}}},{key:"_getMinXDiff",value:function(){var e=this.w.globals;e.isXNumeric&&e.seriesX.forEach((function(t,i){1===t.length&&t.push(e.seriesX[e.maxValsInArrayIndex][e.seriesX[e.maxValsInArrayIndex].length-1]);var a=t.slice();a.sort((function(e,t){return e-t})),a.forEach((function(t,i){if(i>0){var r=t-a[i-1];r>0&&(e.minXDiff=Math.min(r,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 i=t.seriesGroups;i.length||(i=[this.w.globals.seriesNames.map((function(e){return e}))]);var a={},s={};i.forEach((function(i){a[i]=[],s[i]=[],e.w.config.series.map((function(e,a){return i.indexOf(t.seriesNames[a])>-1?a:null})).filter((function(e){return null!==e})).forEach((function(n){for(var o=0;o<t.series[t.maxValsInArrayIndex].length;o++){var l,c,h,d;void 0===a[i][o]&&(a[i][o]=0,s[i][o]=0),(e.w.config.chart.stacked&&!t.comboCharts||e.w.config.chart.stacked&&t.comboCharts&&(!e.w.config.chart.stackOnlyBar||"bar"===(null===(l=e.w.config.series)||void 0===l||null===(c=l[n])||void 0===c?void 0:c.type)||"column"===(null===(h=e.w.config.series)||void 0===h||null===(d=h[n])||void 0===d?void 0:d.type)))&&null!==t.series[n][o]&&r.isNumber(t.series[n][o])&&(t.series[n][o]>0?a[i][o]+=parseFloat(t.series[n][o])+1e-4:s[i][o]+=parseFloat(t.series[n][o]))}}))})),Object.entries(a).forEach((function(e){var i,r,n=(i=e,r=1,function(e){if(Array.isArray(e))return e}(i)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var a,r,s=[],n=!0,o=!1;try{for(i=i.call(e);!(n=(a=i.next()).done)&&(s.push(a.value),!t||s.length!==t);n=!0);}catch(e){o=!0,r=e}finally{try{n||null==i.return||i.return()}finally{if(o)throw r}}return s}}(i,r)||function(e,t){if(e){if("string"==typeof e)return Ae(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Ae(e,t):void 0}}(i,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0];a[n].forEach((function(e,i){t.maxY=Math.max(t.maxY,a[n][i]),t.minY=Math.min(t.minY,s[n][i])}))}))}}}],i&&Se(t.prototype,i),e}();function Pe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Le=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.elgrid=i,this.w=t.w;var a=this.w;this.xaxisFontSize=a.config.xaxis.labels.style.fontSize,this.axisFontFamily=a.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=a.config.xaxis.labels.style.colors,this.isCategoryBarHorizontal="bar"===a.config.chart.type&&a.config.plotOptions.bar.horizontal,this.xAxisoffX=0,"bottom"===a.config.xaxis.position&&(this.xAxisoffX=a.globals.gridHeight),this.drawnLabels=[],this.axesUtils=new L(t)}var t,i;return t=e,(i=[{key:"drawYaxis",value:function(e){var t=this,i=this.w,a=new g(this.ctx),s=i.config.yaxis[e].labels.style,n=s.fontSize,o=s.fontFamily,l=s.fontWeight,c=a.group({class:"apexcharts-yaxis",rel:e,transform:"translate("+i.globals.translateYAxisX[e]+", 0)"});if(this.axesUtils.isYAxisHidden(e))return c;var h=a.group({class:"apexcharts-yaxis-texts-g"});c.add(h);var d=i.globals.yAxisScale[e].result.length-1,u=i.globals.gridHeight/d,f=i.globals.yLabelFormatters[e],p=i.globals.yAxisScale[e].result.slice();p=this.axesUtils.checkForReversedLabels(e,p);var x="";if(i.config.yaxis[e].labels.show){var b=i.globals.translateY+i.config.yaxis[e].labels.offsetY;i.globals.isBarHorizontal?b=0:"heatmap"===i.config.chart.type&&(b-=u/2),b+=parseInt(i.config.yaxis[e].labels.style.fontSize,10)/3;for(var v=function(c){var g=p[c];g=f(g,c,i);var v=i.config.yaxis[e].labels.padding;i.config.yaxis[e].opposite&&0!==i.config.yaxis.length&&(v*=-1);var m="end";i.config.yaxis[e].opposite&&(m="start"),"left"===i.config.yaxis[e].labels.align?m="start":"center"===i.config.yaxis[e].labels.align?m="middle":"right"===i.config.yaxis[e].labels.align&&(m="end");var y=t.axesUtils.getYAxisForeColor(s.colors,e),w=r.listToArray(i.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(e,"'] .apexcharts-yaxis-label tspan"))).map((function(e){return e.textContent})),k=a.drawText({x:v,y:b,text:w.indexOf(g)>=0?"":g,textAnchor:m,fontSize:n,fontFamily:o,fontWeight:l,maxWidth:i.config.yaxis[e].labels.maxWidth,foreColor:Array.isArray(y)?y[c]:y,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+s.cssClass});c===d&&(x=k),h.add(k);var A=document.createElementNS(i.globals.SVGNS,"title");if(A.textContent=Array.isArray(g)?g.join(" "):g,k.node.appendChild(A),0!==i.config.yaxis[e].labels.rotate){var S=a.rotateAroundCenter(x.node),C=a.rotateAroundCenter(k.node);k.node.setAttribute("transform","rotate(".concat(i.config.yaxis[e].labels.rotate," ").concat(S.x," ").concat(C.y,")"))}b+=u},m=d;m>=0;m--)v(m)}if(void 0!==i.config.yaxis[e].title.text){var y=a.group({class:"apexcharts-yaxis-title"}),w=0;i.config.yaxis[e].opposite&&(w=i.globals.translateYAxisX[e]);var k=a.drawText({x:w,y:i.globals.gridHeight/2+i.globals.translateY+i.config.yaxis[e].title.offsetY,text:i.config.yaxis[e].title.text,textAnchor:"end",foreColor:i.config.yaxis[e].title.style.color,fontSize:i.config.yaxis[e].title.style.fontSize,fontWeight:i.config.yaxis[e].title.style.fontWeight,fontFamily:i.config.yaxis[e].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+i.config.yaxis[e].title.style.cssClass});y.add(k),c.add(y)}var A=i.config.yaxis[e].axisBorder,S=31+A.offsetX;if(i.config.yaxis[e].opposite&&(S=-31-A.offsetX),A.show){var C=a.drawLine(S,i.globals.translateY+A.offsetY-2,S,i.globals.gridHeight+i.globals.translateY+A.offsetY+2,A.color,0,A.width);c.add(C)}return i.config.yaxis[e].axisTicks.show&&this.axesUtils.drawYAxisTicks(S,d,A,i.config.yaxis[e].axisTicks,e,u,c),c}},{key:"drawYaxisInversed",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-xaxis apexcharts-yaxis-inversed"}),r=i.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(t.globals.translateXAxisX,", ").concat(t.globals.translateXAxisY,")")});a.add(r);var s=t.globals.yAxisScale[e].result.length-1,n=t.globals.gridWidth/s+.1,o=n+t.config.xaxis.labels.offsetX,l=t.globals.xLabelFormatter,c=t.globals.yAxisScale[e].result.slice(),h=t.globals.timescaleLabels;h.length>0&&(this.xaxisLabels=h.slice(),s=(c=h.slice()).length),c=this.axesUtils.checkForReversedLabels(e,c);var d=h.length;if(t.config.xaxis.labels.show)for(var u=d?0:s;d?u<d:u>=0;d?u++:u--){var f=c[u];f=l(f,u,t);var p=t.globals.gridWidth+t.globals.padHorizontal-(o-n+t.config.xaxis.labels.offsetX);if(h.length){var x=this.axesUtils.getLabel(c,h,p,u,this.drawnLabels,this.xaxisFontSize);p=x.x,f=x.text,this.drawnLabels.push(x.text),0===u&&t.globals.skipFirstTimelinelabel&&(f=""),u===c.length-1&&t.globals.skipLastTimelinelabel&&(f="")}var b=i.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});r.add(b),b.tspan(f);var v=document.createElementNS(t.globals.SVGNS,"title");v.textContent=f,b.node.appendChild(v),o+=n}return this.inversedYAxisTitleText(a),this.inversedYAxisBorder(a),a}},{key:"inversedYAxisBorder",value:function(e){var t=this.w,i=new g(this.ctx),a=t.config.xaxis.axisBorder;if(a.show){var r=0;"bar"===t.config.chart.type&&t.globals.isXNumeric&&(r-=15);var s=i.drawLine(t.globals.padHorizontal+r+a.offsetX,this.xAxisoffX,t.globals.gridWidth,this.xAxisoffX,a.color,0,a.height);this.elgrid&&this.elgrid.elGridBorders&&t.config.grid.show?this.elgrid.elGridBorders.add(s):e.add(s)}}},{key:"inversedYAxisTitleText",value:function(e){var t=this.w,i=new g(this.ctx);if(void 0!==t.config.xaxis.title.text){var a=i.group({class:"apexcharts-xaxis-title apexcharts-yaxis-title-inversed"}),r=i.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});a.add(r),e.add(a)}}},{key:"yAxisTitleRotate",value:function(e,t){var i=this.w,a=new g(this.ctx),r={width:0,height:0},s={width:0,height:0},n=i.globals.dom.baseEl.querySelector(" .apexcharts-yaxis[rel='".concat(e,"'] .apexcharts-yaxis-texts-g"));null!==n&&(r=n.getBoundingClientRect());var o=i.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(e,"'] .apexcharts-yaxis-title text"));if(null!==o&&(s=o.getBoundingClientRect()),null!==o){var l=this.xPaddingForYAxisTitle(e,r,s,t);o.setAttribute("x",l.xPos-(t?10:0))}if(null!==o){var c=a.rotateAroundCenter(o);o.setAttribute("transform","rotate(".concat(t?-1*i.config.yaxis[e].title.rotate:i.config.yaxis[e].title.rotate," ").concat(c.x," ").concat(c.y,")"))}}},{key:"xPaddingForYAxisTitle",value:function(e,t,i,a){var r=this.w,s=0,n=0,o=10;return void 0===r.config.yaxis[e].title.text||e<0?{xPos:n,padd:0}:(a?(n=t.width+r.config.yaxis[e].title.offsetX+i.width/2+o/2,0===(s+=1)&&(n-=o/2)):(n=-1*t.width+r.config.yaxis[e].title.offsetX+o/2+i.width/2,r.globals.isBarHorizontal&&(o=25,n=-1*t.width-r.config.yaxis[e].title.offsetX-o)),{xPos:n,padd:o})}},{key:"setYAxisXPosition",value:function(e,t){var i=this.w,a=0,r=0,s=18,n=1;i.config.yaxis.length>1&&(this.multipleYs=!0),i.config.yaxis.map((function(o,l){var c=i.globals.ignoreYAxisIndexes.indexOf(l)>-1||!o.show||o.floating||0===e[l].width,h=e[l].width+t[l].width;o.opposite?i.globals.isBarHorizontal?(r=i.globals.gridWidth+i.globals.translateX-1,i.globals.translateYAxisX[l]=r-o.labels.offsetX):(r=i.globals.gridWidth+i.globals.translateX+n,c||(n=n+h+20),i.globals.translateYAxisX[l]=r-o.labels.offsetX+20):(a=i.globals.translateX-s,c||(s=s+h+20),i.globals.translateYAxisX[l]=a+o.labels.offsetX)}))}},{key:"setYAxisTextAlignments",value:function(){var e=this.w,t=e.globals.dom.baseEl.getElementsByClassName("apexcharts-yaxis");(t=r.listToArray(t)).forEach((function(t,i){var a=e.config.yaxis[i];if(a&&!a.floating&&void 0!==a.labels.align){var s=e.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(i,"'] .apexcharts-yaxis-texts-g")),n=e.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(i,"'] .apexcharts-yaxis-label"));n=r.listToArray(n);var o=s.getBoundingClientRect();"left"===a.labels.align?(n.forEach((function(e,t){e.setAttribute("text-anchor","start")})),a.opposite||s.setAttribute("transform","translate(-".concat(o.width,", 0)"))):"center"===a.labels.align?(n.forEach((function(e,t){e.setAttribute("text-anchor","middle")})),s.setAttribute("transform","translate(".concat(o.width/2*(a.opposite?1:-1),", 0)"))):"right"===a.labels.align&&(n.forEach((function(e,t){e.setAttribute("text-anchor","end")})),a.opposite&&s.setAttribute("transform","translate(".concat(o.width,", 0)")))}}))}}])&&Pe(t.prototype,i),e}();function Oe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Me=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.documentEvent=r.bind(this.documentEvent,this)}var t,i;return t=e,(i=[{key:"addEventListener",value:function(e,t){var i=this.w;i.globals.events.hasOwnProperty(e)?i.globals.events[e].push(t):i.globals.events[e]=[t]}},{key:"removeEventListener",value:function(e,t){var i=this.w;if(i.globals.events.hasOwnProperty(e)){var a=i.globals.events[e].indexOf(t);-1!==a&&i.globals.events[e].splice(a,1)}}},{key:"fireEvent",value:function(e,t){var i=this.w;if(i.globals.events.hasOwnProperty(e)){t&&t.length||(t=[]);for(var a=i.globals.events[e],r=a.length,s=0;s<r;s++)a[s].apply(null,t)}}},{key:"setupEventHandlers",value:function(){var e=this,t=this.w,i=this.ctx,a=t.globals.dom.baseEl.querySelector(t.globals.chartClass);this.ctx.eventList.forEach((function(e){a.addEventListener(e,(function(e){var a=Object.assign({},t,{seriesIndex:t.globals.axisCharts?t.globals.capturedSeriesIndex:0,dataPointIndex:t.globals.capturedDataPointIndex});"mousemove"===e.type||"touchmove"===e.type?"function"==typeof t.config.chart.events.mouseMove&&t.config.chart.events.mouseMove(e,i,a):"mouseleave"===e.type||"touchleave"===e.type?"function"==typeof t.config.chart.events.mouseLeave&&t.config.chart.events.mouseLeave(e,i,a):("mouseup"===e.type&&1===e.which||"touchend"===e.type)&&("function"==typeof t.config.chart.events.click&&t.config.chart.events.click(e,i,a),i.ctx.events.fireEvent("click",[e,i,a]))}),{capture:!1,passive:!0})})),this.ctx.eventList.forEach((function(i){t.globals.dom.baseEl.addEventListener(i,e.documentEvent,{passive:!0})})),this.ctx.core.setupBrushHandler()}},{key:"documentEvent",value:function(e){var t=this.w,i=e.target.className;if("click"===e.type){var a=t.globals.dom.baseEl.querySelector(".apexcharts-menu");a&&a.classList.contains("apexcharts-menu-open")&&"apexcharts-menu-icon"!==i&&a.classList.remove("apexcharts-menu-open")}t.globals.clientX="touchmove"===e.type?e.touches[0].clientX:e.clientX,t.globals.clientY="touchmove"===e.type?e.touches[0].clientY:e.clientY}}])&&Oe(t.prototype,i),e}();function Te(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ie=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"setCurrentLocaleValues",value:function(e){var t=this.w.config.chart.locales;window.Apex.chart&&window.Apex.chart.locales&&window.Apex.chart.locales.length>0&&(t=this.w.config.chart.locales.concat(window.Apex.chart.locales));var i=t.filter((function(t){return t.name===e}))[0];if(!i)throw new Error("Wrong locale name provided. Please make sure you set the correct locale name in options");var a=r.extend(E,i);this.w.globals.locale=a.options}}])&&Te(t.prototype,i),e}();function Ee(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ze=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"drawAxis",value:function(e,t){var i,a,r=this,s=this.w.globals,n=this.w.config,o=new ve(this.ctx,t),l=new Le(this.ctx,t);s.axisCharts&&"radar"!==e&&(s.isBarHorizontal?(a=l.drawYaxisInversed(0),i=o.drawXaxisInversed(0),s.dom.elGraphical.add(i),s.dom.elGraphical.add(a)):(i=o.drawXaxis(),s.dom.elGraphical.add(i),n.yaxis.map((function(e,t){if(-1===s.ignoreYAxisIndexes.indexOf(t)&&(a=l.drawYaxis(t),s.dom.Paper.add(a),"back"===r.w.config.grid.position)){var i=s.dom.Paper.children()[1];i.remove(),s.dom.Paper.add(i)}}))))}}])&&Ee(t.prototype,i),e}();function Xe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const Ye=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"drawXCrosshairs",value:function(){var e=this.w,t=new g(this.ctx),i=new l(this.ctx),a=e.config.xaxis.crosshairs.fill.gradient,s=e.config.xaxis.crosshairs.dropShadow,n=e.config.xaxis.crosshairs.fill.type,o=a.colorFrom,c=a.colorTo,h=a.opacityFrom,d=a.opacityTo,u=a.stops,f=s.enabled,p=s.left,x=s.top,b=s.blur,v=s.color,m=s.opacity,y=e.config.xaxis.crosshairs.fill.color;if(e.config.xaxis.crosshairs.show){"gradient"===n&&(y=t.drawGradient("vertical",o,c,h,d,null,u,null));var w=t.drawRect();1===e.config.xaxis.crosshairs.width&&(w=t.drawLine());var k=e.globals.gridHeight;(!r.isNumber(k)||k<0)&&(k=0);var A=e.config.xaxis.crosshairs.width;(!r.isNumber(A)||A<0)&&(A=0),w.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:k,width:A,height:k,fill:y,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}),f&&(w=i.dropShadow(w,{left:p,top:x,blur:b,color:v,opacity:m})),e.globals.dom.elGraphical.add(w)}}},{key:"drawYCrosshairs",value:function(){var e=this.w,t=new g(this.ctx),i=e.config.yaxis[0].crosshairs,a=e.globals.barPadForNumericAxis;if(e.config.yaxis[0].crosshairs.show){var r=t.drawLine(-a,0,e.globals.gridWidth+a,0,i.stroke.color,i.stroke.dashArray,i.stroke.width);r.attr({class:"apexcharts-ycrosshairs"}),e.globals.dom.elGraphical.add(r)}var s=t.drawLine(-a,0,e.globals.gridWidth+a,0,i.stroke.color,0,0);s.attr({class:"apexcharts-ycrosshairs-hidden"}),e.globals.dom.elGraphical.add(s)}}])&&Xe(t.prototype,i),e}();function De(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Re=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"checkResponsiveConfig",value:function(e){var t=this,i=this.w,a=i.config;if(0!==a.responsive.length){var s=a.responsive.slice();s.sort((function(e,t){return e.breakpoint>t.breakpoint?1:t.breakpoint>e.breakpoint?-1:0})).reverse();var n=new _({}),o=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=s[0].breakpoint,o=window.innerWidth>0?window.innerWidth:screen.width;if(o>a){var l=r.clone(i.globals.initialConfig);l.series=r.clone(i.config.series);var c=p.extendArrayProps(n,l,i);e=r.extend(c,e),e=r.extend(i.config,e),t.overrideResponsiveOptions(e)}else for(var h=0;h<s.length;h++)o<s[h].breakpoint&&(e=p.extendArrayProps(n,s[h].options,i),e=r.extend(i.config,e),t.overrideResponsiveOptions(e))};if(e){var l=p.extendArrayProps(n,e,i);l=r.extend(i.config,l),o(l=r.extend(l,e))}else o({})}}},{key:"overrideResponsiveOptions",value:function(e){var t=new _(e).init({responsiveOverride:!0});this.w.config=t}}],i&&De(t.prototype,i),e}();function Fe(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var He=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.colors=[],this.w=t.w;var i=this.w;this.isColorFn=!1,this.isHeatmapDistributed="treemap"===i.config.chart.type&&i.config.plotOptions.treemap.distributed||"heatmap"===i.config.chart.type&&i.config.plotOptions.heatmap.distributed,this.isBarDistributed=i.config.plotOptions.bar.distributed&&("bar"===i.config.chart.type||"rangeBar"===i.config.chart.type)}var t,i;return t=e,i=[{key:"init",value:function(){this.setDefaultColors()}},{key:"setDefaultColors",value:function(){var e,t=this,i=this.w,a=new r;if(i.globals.dom.elWrap.classList.add("apexcharts-theme-".concat(i.config.theme.mode)),void 0===i.config.colors||0===(null===(e=i.config.colors)||void 0===e?void 0:e.length)?i.globals.colors=this.predefined():(i.globals.colors=i.config.colors,Array.isArray(i.config.colors)&&i.config.colors.length>0&&"function"==typeof i.config.colors[0]&&(i.globals.colors=i.config.series.map((function(e,a){var r=i.config.colors[a];return r||(r=i.config.colors[0]),"function"==typeof r?(t.isColorFn=!0,r({value:i.globals.axisCharts?i.globals.series[a][0]?i.globals.series[a][0]:0:i.globals.series[a],seriesIndex:a,dataPointIndex:a,w:i})):r})))),i.globals.seriesColors.map((function(e,t){e&&(i.globals.colors[t]=e)})),i.config.theme.monochrome.enabled){var s=[],n=i.globals.series.length;(this.isBarDistributed||this.isHeatmapDistributed)&&(n=i.globals.series[0].length*i.globals.series.length);for(var o=i.config.theme.monochrome.color,l=1/(n/i.config.theme.monochrome.shadeIntensity),c=i.config.theme.monochrome.shadeTo,h=0,d=0;d<n;d++){var u=void 0;"dark"===c?(u=a.shadeColor(-1*h,o),h+=l):(u=a.shadeColor(h,o),h+=l),s.push(u)}i.globals.colors=s.slice()}var g=i.globals.colors.slice();this.pushExtraColors(i.globals.colors),["fill","stroke"].forEach((function(e){void 0===i.config[e].colors?i.globals[e].colors=t.isColorFn?i.config.colors:g:i.globals[e].colors=i.config[e].colors.slice(),t.pushExtraColors(i.globals[e].colors)})),void 0===i.config.dataLabels.style.colors?i.globals.dataLabels.style.colors=g:i.globals.dataLabels.style.colors=i.config.dataLabels.style.colors.slice(),this.pushExtraColors(i.globals.dataLabels.style.colors,50),void 0===i.config.plotOptions.radar.polygons.fill.colors?i.globals.radarPolygons.fill.colors=["dark"===i.config.theme.mode?"#424242":"none"]:i.globals.radarPolygons.fill.colors=i.config.plotOptions.radar.polygons.fill.colors.slice(),this.pushExtraColors(i.globals.radarPolygons.fill.colors,20),void 0===i.config.markers.colors?i.globals.markers.colors=g:i.globals.markers.colors=i.config.markers.colors.slice(),this.pushExtraColors(i.globals.markers.colors)}},{key:"pushExtraColors",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=this.w,r=t||a.globals.series.length;if(null===i&&(i=this.isBarDistributed||this.isHeatmapDistributed||"heatmap"===a.config.chart.type&&a.config.plotOptions.heatmap.colorScale.inverse),i&&a.globals.series.length&&(r=a.globals.series[a.globals.maxValsInArrayIndex].length*a.globals.series.length),e.length<r)for(var s=r-e.length,n=0;n<s;n++)e.push(e[n])}},{key:"updateThemeOptions",value:function(e){e.chart=e.chart||{},e.tooltip=e.tooltip||{};var t=e.theme.mode,i="dark"===t?"palette4":"light"===t?"palette1":e.theme.palette||"palette1",a="dark"===t?"#f6f7f8":"light"===t?"#373d3f":e.chart.foreColor||"#373d3f";return e.tooltip.theme=t||"light",e.chart.foreColor=a,e.theme.palette=i,e}},{key:"predefined",value:function(){switch(this.w.config.theme.palette){case"palette1":default:this.colors=["#008FFB","#00E396","#FEB019","#FF4560","#775DD0"];break;case"palette2":this.colors=["#3f51b5","#03a9f4","#4caf50","#f9ce1d","#FF9800"];break;case"palette3":this.colors=["#33b2df","#546E7A","#d4526e","#13d8aa","#A5978B"];break;case"palette4":this.colors=["#4ecdc4","#c7f464","#81D4FA","#fd6a6a","#546E7A"];break;case"palette5":this.colors=["#2b908f","#f9a3a4","#90ee7e","#fa4443","#69d2e7"];break;case"palette6":this.colors=["#449DD1","#F86624","#EA3546","#662E9B","#C5D86D"];break;case"palette7":this.colors=["#D7263D","#1B998B","#2E294E","#F46036","#E2C044"];break;case"palette8":this.colors=["#662E9B","#F86624","#F9C80E","#EA3546","#43BCCD"];break;case"palette9":this.colors=["#5C4742","#A5978B","#8D5B4C","#5A2A27","#C4BBAF"];break;case"palette10":this.colors=["#A300D6","#7D02EB","#5653FE","#2983FF","#00B1F2"]}return this.colors}}],i&&Fe(t.prototype,i),e}();function Ne(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var We=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"draw",value:function(){this.drawTitleSubtitle("title"),this.drawTitleSubtitle("subtitle")}},{key:"drawTitleSubtitle",value:function(e){var t=this.w,i="title"===e?t.config.title:t.config.subtitle,a=t.globals.svgWidth/2,r=i.offsetY,s="middle";if("left"===i.align?(a=10,s="start"):"right"===i.align&&(a=t.globals.svgWidth-10,s="end"),a+=i.offsetX,r=r+parseInt(i.style.fontSize,10)+i.margin/2,void 0!==i.text){var n=new g(this.ctx).drawText({x:a,y:r,text:i.text,textAnchor:s,fontSize:i.style.fontSize,fontFamily:i.style.fontFamily,fontWeight:i.style.fontWeight,foreColor:i.style.color,opacity:1});n.node.setAttribute("class","apexcharts-".concat(e,"-text")),t.globals.dom.Paper.add(n)}}}])&&Ne(t.prototype,i),e}();function Be(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function je(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ge=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"getTitleSubtitleCoords",value:function(e){var t=this.w,i=0,a=0,r="title"===e?t.config.title.floating:t.config.subtitle.floating,s=t.globals.dom.baseEl.querySelector(".apexcharts-".concat(e,"-text"));if(null!==s&&!r){var n=s.getBoundingClientRect();i=n.width,a=t.globals.axisCharts?n.height+5:n.height}return{width:i,height:a}}},{key:"getLegendsRect",value:function(){var e=this.w,t=e.globals.dom.elLegendWrap;e.config.legend.height||"top"!==e.config.legend.position&&"bottom"!==e.config.legend.position||(t.style.maxHeight=e.globals.svgHeight/2+"px");var i=Object.assign({},r.getBoundingClientRect(t));return null!==t&&!e.config.legend.floating&&e.config.legend.show?this.dCtx.lgRect={x:i.x,y:i.y,height:i.height,width:0===i.height?0:i.width}:this.dCtx.lgRect={x:0,y:0,height:0,width:0},"left"!==e.config.legend.position&&"right"!==e.config.legend.position||1.5*this.dCtx.lgRect.width>e.globals.svgWidth&&(this.dCtx.lgRect.width=e.globals.svgWidth/1.5),this.dCtx.lgRect}},{key:"getDatalabelsRect",value:function(){var e=this,t=this.w,i=[];t.config.series.forEach((function(r,s){r.data.forEach((function(r,n){var o;o=t.globals.series[s][n],a=t.config.dataLabels.formatter(o,{ctx:e.dCtx.ctx,seriesIndex:s,dataPointIndex:n,w:t}),i.push(a)}))}));var a=r.getLargestStringFromArr(i),s=new g(this.dCtx.ctx),n=t.config.dataLabels.style,o=s.getTextRects(a,parseInt(n.fontSize),n.fontFamily);return{width:1.05*o.width,height:o.height}}},{key:"getLargestStringFromMultiArr",value:function(e,t){var i=e;if(this.w.globals.isMultiLineX){var a=t.map((function(e,t){return Array.isArray(e)?e.length:1})),r=Math.max.apply(Math,function(e){return function(e){if(Array.isArray(e))return Be(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Be(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Be(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(a));i=t[a.indexOf(r)]}return i}}])&&je(t.prototype,i),e}();function Ve(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var _e=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"getxAxisLabelsCoords",value:function(){var e,t=this.w,i=t.globals.labels.slice();if(t.config.xaxis.convertedCatToNumeric&&0===i.length&&(i=t.globals.categoryLabels),t.globals.timescaleLabels.length>0){var a=this.getxAxisTimeScaleLabelsCoords();e={width:a.width,height:a.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 s=t.globals.xLabelFormatter,n=r.getLargestStringFromArr(i),o=this.dCtx.dimHelpers.getLargestStringFromMultiArr(n,i);t.globals.isBarHorizontal&&(o=n=t.globals.yAxisScale[0].result.reduce((function(e,t){return e.length>t.length?e:t}),0));var l=new C(this.dCtx.ctx),c=n;n=l.xLabelFormat(s,n,c,{i:void 0,dateFormatter:new A(this.dCtx.ctx).formatDate,w:t}),o=l.xLabelFormat(s,o,c,{i:void 0,dateFormatter:new A(this.dCtx.ctx).formatDate,w:t}),(t.config.xaxis.convertedCatToNumeric&&void 0===n||""===String(n).trim())&&(o=n="1");var h=new g(this.dCtx.ctx),d=h.getTextRects(n,t.config.xaxis.labels.style.fontSize),u=d;if(n!==o&&(u=h.getTextRects(o,t.config.xaxis.labels.style.fontSize)),(e={width:d.width>=u.width?d.width:u.width,height:d.height>=u.height?d.height:u.height}).width*i.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 f=function(e){return h.getTextRects(e,t.config.xaxis.labels.style.fontSize,t.config.xaxis.labels.style.fontFamily,"rotate(".concat(t.config.xaxis.labels.rotate," 0 0)"),!1)};d=f(n),n!==o&&(u=f(o)),e.height=(d.height>u.height?d.height:u.height)/1.5,e.width=d.width>u.width?d.width:u.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 i,a=(null===(e=t.config.xaxis.group.style)||void 0===e?void 0:e.fontSize)||t.config.xaxis.labels.style.fontSize,s=t.globals.groups.map((function(e){return e.title})),n=r.getLargestStringFromArr(s),o=this.dCtx.dimHelpers.getLargestStringFromMultiArr(n,s),l=new g(this.dCtx.ctx),c=l.getTextRects(n,a),h=c;return n!==o&&(h=l.getTextRects(o,a)),i={width:c.width>=h.width?c.width:h.width,height:c.height>=h.height?c.height:h.height},t.config.xaxis.labels.show||(i={width:0,height:0}),{width:i.width,height:i.height}}},{key:"getxAxisTitleCoords",value:function(){var e=this.w,t=0,i=0;if(void 0!==e.config.xaxis.title.text){var a=new g(this.dCtx.ctx).getTextRects(e.config.xaxis.title.text,e.config.xaxis.title.style.fontSize);t=a.width,i=a.height}return{width:t,height:i}}},{key:"getxAxisTimeScaleLabelsCoords",value:function(){var e,t=this.w;this.dCtx.timescaleLabels=t.globals.timescaleLabels.slice();var i=this.dCtx.timescaleLabels.map((function(e){return e.value})),a=i.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 g(this.dCtx.ctx).getTextRects(a,t.config.xaxis.labels.style.fontSize)).width*i.length>t.globals.gridWidth&&0!==t.config.xaxis.labels.rotate&&(t.globals.overlappingXLabels=!0),e}},{key:"additionalPaddingXLabels",value:function(e){var t=this,i=this.w,a=i.globals,r=i.config,s=r.xaxis.type,n=e.width;a.skipLastTimelinelabel=!1,a.skipFirstTimelinelabel=!1;var o=i.config.yaxis[0].opposite&&i.globals.isBarHorizontal;r.yaxis.forEach((function(e,l){o?(t.dCtx.gridPad.left<n&&(t.dCtx.xPadLeft=n/2+1),t.dCtx.xPadRight=n/2+1):function(e,o){r.yaxis.length>1&&function(e){return-1!==a.collapsedSeriesIndices.indexOf(e)}(o)||function(e){if(t.dCtx.timescaleLabels&&t.dCtx.timescaleLabels.length){var o=t.dCtx.timescaleLabels[0],l=t.dCtx.timescaleLabels[t.dCtx.timescaleLabels.length-1].position+n/1.75-t.dCtx.yAxisWidthRight,c=o.position-n/1.75+t.dCtx.yAxisWidthLeft,h="right"===i.config.legend.position&&t.dCtx.lgRect.width>0?t.dCtx.lgRect.width:0;l>a.svgWidth-a.translateX-h&&(a.skipLastTimelinelabel=!0),c<-(e.show&&!e.floating||"bar"!==r.chart.type&&"candlestick"!==r.chart.type&&"rangeBar"!==r.chart.type&&"boxPlot"!==r.chart.type?10:n/1.75)&&(a.skipFirstTimelinelabel=!0)}else"datetime"===s?t.dCtx.gridPad.right<n&&!a.rotateXLabels&&(a.skipLastTimelinelabel=!0):"datetime"!==s&&t.dCtx.gridPad.right<n/2-t.dCtx.yAxisWidthRight&&!a.rotateXLabels&&!i.config.xaxis.labels.trim&&(t.dCtx.xPadRight=n/2+1)}(e)}(e,l)}))}}])&&Ve(t.prototype,i),e}();function Ue(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var qe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"getyAxisLabelsCoords",value:function(){var e=this,t=this.w,i=[],a=10,s=new L(this.dCtx.ctx);return t.config.yaxis.map((function(n,o){var l={seriesIndex:o,dataPointIndex:-1,w:t},c=t.globals.yAxisScale[o],h=0;if(!s.isYAxisHidden(o)&&n.labels.show&&void 0!==n.labels.minWidth&&(h=n.labels.minWidth),!s.isYAxisHidden(o)&&n.labels.show&&c.result.length){var d=t.globals.yLabelFormatters[o],u=c.niceMin===Number.MIN_VALUE?0:c.niceMin,f=c.result.reduce((function(e,t){var i,a;return(null===(i=String(d(e,l)))||void 0===i?void 0:i.length)>(null===(a=String(d(t,l)))||void 0===a?void 0:a.length)?e:t}),u),p=f=d(f,l);if(void 0!==f&&0!==f.length||(f=c.niceMax),t.globals.isBarHorizontal){a=0;var x=t.globals.labels.slice();f=r.getLargestStringFromArr(x),f=d(f,{seriesIndex:o,dataPointIndex:-1,w:t}),p=e.dCtx.dimHelpers.getLargestStringFromMultiArr(f,x)}var b=new g(e.dCtx.ctx),v="rotate(".concat(n.labels.rotate," 0 0)"),m=b.getTextRects(f,n.labels.style.fontSize,n.labels.style.fontFamily,v,!1),y=m;f!==p&&(y=b.getTextRects(p,n.labels.style.fontSize,n.labels.style.fontFamily,v,!1)),i.push({width:(h>y.width||h>m.width?h:y.width>m.width?y.width:m.width)+a,height:y.height>m.height?y.height:m.height})}else i.push({width:0,height:0})})),i}},{key:"getyAxisTitleCoords",value:function(){var e=this,t=this.w,i=[];return t.config.yaxis.map((function(t,a){if(t.show&&void 0!==t.title.text){var r=new g(e.dCtx.ctx),s="rotate(".concat(t.title.rotate," 0 0)"),n=r.getTextRects(t.title.text,t.title.style.fontSize,t.title.style.fontFamily,s,!1);i.push({width:n.width,height:n.height})}else i.push({width:0,height:0})})),i}},{key:"getTotalYAxisWidth",value:function(){var e=this.w,t=0,i=0,a=0,r=e.globals.yAxisScale.length>1?10:0,s=new L(this.dCtx.ctx),n=function(n,o){var l=e.config.yaxis[o].floating,c=0;n.width>0&&!l?(c=n.width+r,function(t){return e.globals.ignoreYAxisIndexes.indexOf(t)>-1}(o)&&(c=c-n.width-r)):c=l||s.isYAxisHidden(o)?0:5,e.config.yaxis[o].opposite?a+=c:i+=c,t+=c};return e.globals.yLabelsCoords.map((function(e,t){n(e,t)})),e.globals.yTitleCoords.map((function(e,t){n(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=i,this.dCtx.yAxisWidthRight=a,t}}])&&Ue(t.prototype,i),e}();function Ze(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var $e=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.dCtx=t}var t,i;return t=e,(i=[{key:"gridPadForColumnsInNumericAxis",value:function(e){var t=this.w,i=t.config,a=t.globals;if(a.noData||a.collapsedSeries.length+a.ancillaryCollapsedSeries.length===i.series.length)return 0;var r=function(e){return"bar"===e||"rangeBar"===e||"candlestick"===e||"boxPlot"===e},s=i.chart.type,n=0,o=r(s)?i.series.length:1;a.comboBarCount>0&&(o=a.comboBarCount),a.collapsedSeries.forEach((function(e){r(e.type)&&(o-=1)})),i.chart.stacked&&(o=1);var l,c,h=r(s)||a.comboBarCount>0,d=Math.abs(a.initialMaxX-a.initialMinX);return h&&a.isXNumeric&&!a.isBarHorizontal&&o>0&&0!==d&&(d<=3&&(d=a.dataPoints),l=d/e,a.minXDiff&&a.minXDiff/l>0&&(c=a.minXDiff/l),c>e/2&&(c/=2),(n=c*parseInt(i.plotOptions.bar.columnWidth,10)/100)<1&&(n=1),a.barPadForNumericAxis=n),n}},{key:"gridPadFortitleSubtitle",value:function(){var e=this,t=this.w,i=t.globals,a=this.dCtx.isSparkline||!t.globals.axisCharts?0:10;["title","subtitle"].forEach((function(i){void 0!==t.config[i].text?a+=t.config[i].margin:a+=e.dCtx.isSparkline||!t.globals.axisCharts?0:5})),!t.config.legend.show||"bottom"!==t.config.legend.position||t.config.legend.floating||t.globals.axisCharts||(a+=10);var r=this.dCtx.dimHelpers.getTitleSubtitleCoords("title"),s=this.dCtx.dimHelpers.getTitleSubtitleCoords("subtitle");i.gridHeight=i.gridHeight-r.height-s.height-a,i.translateY=i.translateY+r.height+s.height+a}},{key:"setGridXPosForDualYAxis",value:function(e,t){var i=this.w,a=new L(this.dCtx.ctx);i.config.yaxis.map((function(r,s){-1!==i.globals.ignoreYAxisIndexes.indexOf(s)||r.floating||a.isYAxisHidden(s)||(r.opposite&&(i.globals.translateX=i.globals.translateX-(t[s].width+e[s].width)-parseInt(i.config.yaxis[s].labels.style.fontSize,10)/1.2-12),i.globals.translateX<2&&(i.globals.translateX=2))}))}}])&&Ze(t.prototype,i),e}();function Je(e,t){if(e){if("string"==typeof e)return Qe(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Qe(e,t):void 0}}function Qe(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Ke(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var et=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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 Ge(this),this.dimYAxis=new qe(this),this.dimXAxis=new _e(this),this.dimGrid=new $e(this),this.lgWidthForSideLegends=0,this.gridPad=this.w.config.grid.padding,this.xPadRight=0,this.xPadLeft=0}var t,i;return t=e,(i=[{key:"plotCoords",value:function(){var e=this,t=this.w,i=t.globals;this.lgRect=this.dimHelpers.getLegendsRect(),this.datalabelsCoords={width:0,height:0};var a,r=Array.isArray(t.config.stroke.width)?Math.max.apply(Math,function(e){if(Array.isArray(e))return Qe(e)}(a=t.config.stroke.width)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||Je(a)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()):t.config.stroke.width;this.isSparkline&&((t.config.markers.discrete.length>0||t.config.markers.size>0)&&Object.entries(this.gridPad).forEach((function(t){var i=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var a,r,s=[],n=!0,o=!1;try{for(i=i.call(e);!(n=(a=i.next()).done)&&(s.push(a.value),!t||s.length!==t);n=!0);}catch(e){o=!0,r=e}finally{try{n||null==i.return||i.return()}finally{if(o)throw r}}return s}}(e,t)||Je(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),a=i[0],r=i[1];e.gridPad[a]=Math.max(r,e.w.globals.markers.largestSize/1.5)})),this.gridPad.top=Math.max(r/2,this.gridPad.top),this.gridPad.bottom=Math.max(r/2,this.gridPad.bottom)),i.axisCharts?this.setDimensionsForAxisCharts():this.setDimensionsForNonAxisCharts(),this.dimGrid.gridPadFortitleSubtitle(),i.gridHeight=i.gridHeight-this.gridPad.top-this.gridPad.bottom,i.gridWidth=i.gridWidth-this.gridPad.left-this.gridPad.right-this.xPadRight-this.xPadLeft;var s=this.dimGrid.gridPadForColumnsInNumericAxis(i.gridWidth);i.gridWidth=i.gridWidth-2*s,i.translateX=i.translateX+this.gridPad.left+this.xPadLeft+(s>0?s:0),i.translateY=i.translateY+this.gridPad.top}},{key:"setDimensionsForAxisCharts",value:function(){var e=this,t=this.w,i=t.globals,a=this.dimYAxis.getyAxisLabelsCoords(),r=this.dimYAxis.getyAxisTitleCoords();i.isSlopeChart&&(this.datalabelsCoords=this.dimHelpers.getDatalabelsRect()),t.globals.yLabelsCoords=[],t.globals.yTitleCoords=[],t.config.yaxis.map((function(e,i){t.globals.yLabelsCoords.push({width:a[i].width,index:i}),t.globals.yTitleCoords.push({width:r[i].width,index:i})})),this.yAxisWidth=this.dimYAxis.getTotalYAxisWidth();var s=this.dimXAxis.getxAxisLabelsCoords(),n=this.dimXAxis.getxAxisGroupLabelsCoords(),o=this.dimXAxis.getxAxisTitleCoords();this.conditionalChecksForAxisCoords(s,o,n),i.translateXAxisY=t.globals.rotateXLabels?this.xAxisHeight/8:-4,i.translateXAxisX=t.globals.rotateXLabels&&t.globals.isXNumeric&&t.config.xaxis.labels.rotate<=-45?-this.xAxisWidth/4:0,t.globals.isBarHorizontal&&(i.rotateXLabels=!1,i.translateXAxisY=parseInt(t.config.xaxis.labels.style.fontSize,10)/1.5*-1),i.translateXAxisY=i.translateXAxisY+t.config.xaxis.labels.offsetY,i.translateXAxisX=i.translateXAxisX+t.config.xaxis.labels.offsetX;var l=this.yAxisWidth,c=this.xAxisHeight;i.xAxisLabelsHeight=this.xAxisHeight-o.height,i.xAxisGroupLabelsHeight=i.xAxisLabelsHeight-s.height,i.xAxisLabelsWidth=this.xAxisWidth,i.xAxisHeight=this.xAxisHeight;var h=10;("radar"===t.config.chart.type||this.isSparkline)&&(l=0,c=i.goldenPadding),this.isSparkline&&(this.lgRect={height:0,width:0}),(this.isSparkline||"treemap"===t.config.chart.type)&&(l=0,c=0,h=0),this.isSparkline||this.dimXAxis.additionalPaddingXLabels(s);var d=function(){i.translateX=l+e.datalabelsCoords.width,i.gridHeight=i.svgHeight-e.lgRect.height-c-(e.isSparkline||"treemap"===t.config.chart.type?0:t.globals.rotateXLabels?10:15),i.gridWidth=i.svgWidth-l-2*e.datalabelsCoords.width};switch("top"===t.config.xaxis.position&&(h=i.xAxisHeight-t.config.xaxis.axisTicks.height-5),t.config.legend.position){case"bottom":i.translateY=h,d();break;case"top":i.translateY=this.lgRect.height+h,d();break;case"left":i.translateY=h,i.translateX=this.lgRect.width+l+this.datalabelsCoords.width,i.gridHeight=i.svgHeight-c-12,i.gridWidth=i.svgWidth-this.lgRect.width-l-2*this.datalabelsCoords.width;break;case"right":i.translateY=h,i.translateX=l+this.datalabelsCoords.width,i.gridHeight=i.svgHeight-c-12,i.gridWidth=i.svgWidth-this.lgRect.width-l-2*this.datalabelsCoords.width-5;break;default:throw new Error("Legend position not supported")}this.dimGrid.setGridXPosForDualYAxis(r,a),new Le(this.ctx).setYAxisXPosition(a,r)}},{key:"setDimensionsForNonAxisCharts",value:function(){var e=this.w,t=e.globals,i=e.config,a=0;e.config.legend.show&&!e.config.legend.floating&&(a=20);var r="pie"===i.chart.type||"polarArea"===i.chart.type||"donut"===i.chart.type?"pie":"radialBar",s=i.plotOptions[r].offsetY,n=i.plotOptions[r].offsetX;if(!i.legend.show||i.legend.floating){t.gridHeight=t.svgHeight-i.grid.padding.top-i.grid.padding.bottom;var o=t.dom.elWrap.getBoundingClientRect().width;return t.gridWidth=Math.min(o,t.gridHeight)-i.grid.padding.left-i.grid.padding.right,t.translateY=s,void(t.translateX=n+(t.svgWidth-t.gridWidth)/2)}switch(i.legend.position){case"bottom":t.gridHeight=t.svgHeight-this.lgRect.height-t.goldenPadding,t.gridWidth=t.svgWidth,t.translateY=s-10,t.translateX=n+(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+s+10,t.translateX=n+(t.svgWidth-t.gridWidth)/2;break;case"left":t.gridWidth=t.svgWidth-this.lgRect.width-a,t.gridHeight="auto"!==i.chart.height?t.svgHeight:t.gridWidth,t.translateY=s,t.translateX=n+this.lgRect.width+a;break;case"right":t.gridWidth=t.svgWidth-this.lgRect.width-a-5,t.gridHeight="auto"!==i.chart.height?t.svgHeight:t.gridWidth,t.translateY=s,t.translateX=n+10;break;default:throw new Error("Legend position not supported")}}},{key:"conditionalChecksForAxisCoords",value:function(e,t,i){var a=this.w,r=a.globals.hasXaxisGroups?2:1,s=i.height+e.height+t.height,n=a.globals.isMultiLineX?1.2:a.globals.LINE_HEIGHT_RATIO,o=a.globals.rotateXLabels?22:10,l=a.globals.rotateXLabels&&"bottom"===a.config.legend.position?10:0;this.xAxisHeight=s*n+r*o+l,this.xAxisWidth=e.width,this.xAxisHeight-t.height>a.config.xaxis.labels.maxHeight&&(this.xAxisHeight=a.config.xaxis.labels.maxHeight),a.config.xaxis.labels.minHeight&&this.xAxisHeight<a.config.xaxis.labels.minHeight&&(this.xAxisHeight=a.config.xaxis.labels.minHeight),a.config.xaxis.floating&&(this.xAxisHeight=0);var c=0,h=0;a.config.yaxis.forEach((function(e){c+=e.labels.minWidth,h+=e.labels.maxWidth})),this.yAxisWidth<c&&(this.yAxisWidth=c),this.yAxisWidth>h&&(this.yAxisWidth=h)}}])&&Ke(t.prototype,i),e}();function tt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var it=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.lgCtx=t}var t,i;return t=e,(i=[{key:"getLegendStyles",value:function(){var e,t,i,a=document.createElement("style");a.setAttribute("type","text/css");var r=(null===(e=this.lgCtx.ctx)||void 0===e||null===(t=e.opts)||void 0===t||null===(i=t.chart)||void 0===i?void 0:i.nonce)||this.w.config.chart.nonce;r&&a.setAttribute("nonce",r);var s=document.createTextNode("\n .apexcharts-legend {\n display: flex;\n overflow: auto;\n padding: 0 10px;\n }\n .apexcharts-legend.apx-legend-position-bottom, .apexcharts-legend.apx-legend-position-top {\n flex-wrap: wrap\n }\n .apexcharts-legend.apx-legend-position-right, .apexcharts-legend.apx-legend-position-left {\n flex-direction: column;\n bottom: 0;\n }\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 {\n justify-content: flex-start;\n }\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-center, .apexcharts-legend.apx-legend-position-top.apexcharts-align-center {\n justify-content: center;\n }\n .apexcharts-legend.apx-legend-position-bottom.apexcharts-align-right, .apexcharts-legend.apx-legend-position-top.apexcharts-align-right {\n justify-content: flex-end;\n }\n .apexcharts-legend-series {\n cursor: pointer;\n line-height: normal;\n display: flex;\n align-items: center;\n }\n .apexcharts-legend-text {\n position: relative;\n font-size: 14px;\n }\n .apexcharts-legend-text *, .apexcharts-legend-marker * {\n pointer-events: none;\n }\n .apexcharts-legend-marker {\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n margin-right: 1px;\n }\n\n .apexcharts-legend-series.apexcharts-no-click {\n cursor: auto;\n }\n .apexcharts-legend .apexcharts-hidden-zero-series, .apexcharts-legend .apexcharts-hidden-null-series {\n display: none !important;\n }\n .apexcharts-inactive-legend {\n opacity: 0.45;\n }");return a.appendChild(s),a}},{key:"getLegendDimensions",value:function(){var e=this.w.globals.dom.baseEl.querySelector(".apexcharts-legend"),t=e.offsetWidth;return{clwh:e.offsetHeight,clww:t}}},{key:"appendToForeignObject",value:function(){this.w.globals.dom.elLegendForeign.appendChild(this.getLegendStyles())}},{key:"toggleDataSeries",value:function(e,t){var i=this,a=this.w;if(a.globals.axisCharts||"radialBar"===a.config.chart.type){a.globals.resized=!0;var r=null,s=null;a.globals.risingSeries=[],a.globals.axisCharts?(r=a.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(e,"']")),s=parseInt(r.getAttribute("data:realIndex"),10)):(r=a.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(e+1,"']")),s=parseInt(r.getAttribute("rel"),10)-1),t?[{cs:a.globals.collapsedSeries,csi:a.globals.collapsedSeriesIndices},{cs:a.globals.ancillaryCollapsedSeries,csi:a.globals.ancillaryCollapsedSeriesIndices}].forEach((function(e){i.riseCollapsedSeries(e.cs,e.csi,s)})):this.hideSeries({seriesEl:r,realIndex:s})}else{var n=a.globals.dom.Paper.select(" .apexcharts-series[rel='".concat(e+1,"'] path")),o=a.config.chart.type;if("pie"===o||"polarArea"===o||"donut"===o){var l=a.config.plotOptions.pie.donut.labels;new g(this.lgCtx.ctx).pathMouseDown(n.members[0],null),this.lgCtx.ctx.pie.printDataLabelsInner(n.members[0].node,l)}n.fire("click")}}},{key:"hideSeries",value:function(e){var t=e.seriesEl,i=e.realIndex,a=this.w,s=a.globals,n=r.clone(a.config.series);if(s.axisCharts){var o=a.config.yaxis[s.seriesYAxisReverseMap[i]];if(o&&o.show&&o.showAlways)s.ancillaryCollapsedSeriesIndices.indexOf(i)<0&&(s.ancillaryCollapsedSeries.push({index:i,data:n[i].data.slice(),type:t.parentNode.className.baseVal.split("-")[1]}),s.ancillaryCollapsedSeriesIndices.push(i));else if(s.collapsedSeriesIndices.indexOf(i)<0){s.collapsedSeries.push({index:i,data:n[i].data.slice(),type:t.parentNode.className.baseVal.split("-")[1]}),s.collapsedSeriesIndices.push(i);var l=s.risingSeries.indexOf(i);s.risingSeries.splice(l,1)}}else s.collapsedSeries.push({index:i,data:n[i]}),s.collapsedSeriesIndices.push(i);for(var c=t.childNodes,h=0;h<c.length;h++)c[h].classList.contains("apexcharts-series-markers-wrap")&&(c[h].classList.contains("apexcharts-hide")?c[h].classList.remove("apexcharts-hide"):c[h].classList.add("apexcharts-hide"));s.allSeriesCollapsed=s.collapsedSeries.length+s.ancillaryCollapsedSeries.length===a.config.series.length,n=this._getSeriesBasedOnCollapsedState(n),this.lgCtx.ctx.updateHelpers._updateSeries(n,a.config.chart.animations.dynamicAnimation.enabled)}},{key:"riseCollapsedSeries",value:function(e,t,i){var a=this.w,s=r.clone(a.config.series);if(e.length>0){for(var n=0;n<e.length;n++)e[n].index===i&&(a.globals.axisCharts?(s[i].data=e[n].data.slice(),e.splice(n,1),t.splice(n,1),a.globals.risingSeries.push(i)):(s[i]=e[n].data,e.splice(n,1),t.splice(n,1),a.globals.risingSeries.push(i)));s=this._getSeriesBasedOnCollapsedState(s),this.lgCtx.ctx.updateHelpers._updateSeries(s,a.config.chart.animations.dynamicAnimation.enabled)}}},{key:"_getSeriesBasedOnCollapsedState",value:function(e){var t=this.w,i=0;return t.globals.axisCharts?e.forEach((function(a,r){t.globals.collapsedSeriesIndices.indexOf(r)<0&&t.globals.ancillaryCollapsedSeriesIndices.indexOf(r)<0||(e[r].data=[],i++)})):e.forEach((function(a,r){!t.globals.collapsedSeriesIndices.indexOf(r)<0&&(e[r]=0,i++)})),t.globals.allSeriesCollapsed=i===e.length,e}}])&&tt(t.prototype,i),e}();function at(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function rt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?at(Object(i),!0).forEach((function(t){st(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):at(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function st(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function nt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ot=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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 it(this)}var t,i;return t=e,(i=[{key:"init",value:function(){var e=this.w,t=e.globals,i=e.config;if((i.legend.showForSingleSeries&&1===t.series.length||this.isBarsDistributed||t.series.length>1||!t.axisCharts)&&i.legend.show){for(;t.dom.elLegendWrap.firstChild;)t.dom.elLegendWrap.removeChild(t.dom.elLegendWrap.firstChild);this.drawLegends(),r.isIE11()?document.getElementsByTagName("head")[0].appendChild(this.legendHelpers.getLegendStyles()):this.legendHelpers.appendToForeignObject(),"bottom"===i.legend.position||"top"===i.legend.position?this.legendAlignHorizontal():"right"!==i.legend.position&&"left"!==i.legend.position||this.legendAlignVertical()}}},{key:"createLegendMarker",value:function(e){var t=e.i,i=e.fillcolor,a=this.w,r=document.createElement("span");r.classList.add("apexcharts-legend-marker");var s=a.config.legend.markers.shape||a.config.markers.shape,n=s;Array.isArray(s)&&(n=s[t]);var o=Array.isArray(a.config.legend.markers.size)?parseFloat(a.config.legend.markers.size[t]):parseFloat(a.config.legend.markers.size),l=Array.isArray(a.config.legend.markers.offsetX)?parseFloat(a.config.legend.markers.offsetX[t]):parseFloat(a.config.legend.markers.offsetX),c=Array.isArray(a.config.legend.markers.offsetY)?parseFloat(a.config.legend.markers.offsetY[t]):parseFloat(a.config.legend.markers.offsetY),h=Array.isArray(a.config.legend.markers.strokeWidth)?parseFloat(a.config.legend.markers.strokeWidth[t]):parseFloat(a.config.legend.markers.strokeWidth),d=r.style;if(d.height=2*(o+h)+"px",d.width=2*(o+h)+"px",d.left=l+"px",d.top=c+"px",a.config.legend.markers.customHTML)d.background="transparent",d.color=i[t],Array.isArray(a.config.legend.markers.customHTML)?a.config.legend.markers.customHTML[t]&&(r.innerHTML=a.config.legend.markers.customHTML[t]()):r.innerHTML=a.config.legend.markers.customHTML();else{var u=new ae(this.ctx).getMarkerConfig({cssClass:"apexcharts-legend-marker apexcharts-marker apexcharts-marker-".concat(n),seriesIndex:t,strokeWidth:h,size:o}),f=SVG(r).size("100%","100%"),p=new g(this.ctx).drawMarker(0,0,rt(rt({},u),{},{pointFillColor:Array.isArray(i)?i[t]:u.pointFillColor,shape:n}));SVG.select(".apexcharts-legend-marker.apexcharts-marker").members.forEach((function(e){e.node.classList.contains("apexcharts-marker-triangle")?e.node.style.transform="translate(50%, 45%)":e.node.style.transform="translate(50%, 50%)"})),f.add(p)}return r}},{key:"drawLegends",value:function(){var e=this,t=this.w,i=t.config.legend.fontFamily,a=t.globals.seriesNames,s=t.config.legend.markers.fillColors?t.config.legend.markers.fillColors.slice():t.globals.colors.slice();if("heatmap"===t.config.chart.type){var n=t.config.plotOptions.heatmap.colorScale.ranges;a=n.map((function(e){return e.name?e.name:e.from+" - "+e.to})),s=n.map((function(e){return e.color}))}else this.isBarsDistributed&&(a=t.globals.labels.slice());t.config.legend.customLegendItems.length&&(a=t.config.legend.customLegendItems);for(var o=t.globals.legendFormatter,l=t.config.legend.inverseOrder,c=l?a.length-1:0;l?c>=0:c<=a.length-1;l?c--:c++){var h,d=o(a[c],{seriesIndex:c,w:t}),u=!1,f=!1;if(t.globals.collapsedSeries.length>0)for(var x=0;x<t.globals.collapsedSeries.length;x++)t.globals.collapsedSeries[x].index===c&&(u=!0);if(t.globals.ancillaryCollapsedSeriesIndices.length>0)for(var b=0;b<t.globals.ancillaryCollapsedSeriesIndices.length;b++)t.globals.ancillaryCollapsedSeriesIndices[b]===c&&(f=!0);var v=this.createLegendMarker({i:c,fillcolor:s});g.setAttrs(v,{rel:c+1,"data:collapsed":u||f}),(u||f)&&v.classList.add("apexcharts-inactive-legend");var m=document.createElement("div"),y=document.createElement("span");y.classList.add("apexcharts-legend-text"),y.innerHTML=Array.isArray(d)?d.join(" "):d;var w=t.config.legend.labels.useSeriesColors?t.globals.colors[c]:Array.isArray(t.config.legend.labels.colors)?null===(h=t.config.legend.labels.colors)||void 0===h?void 0:h[c]:t.config.legend.labels.colors;w||(w=t.config.chart.foreColor),y.style.color=w,y.style.fontSize=parseFloat(t.config.legend.fontSize)+"px",y.style.fontWeight=t.config.legend.fontWeight,y.style.fontFamily=i||t.config.chart.fontFamily,g.setAttrs(y,{rel:c+1,i:c,"data:default-text":encodeURIComponent(d),"data:collapsed":u||f}),m.appendChild(v),m.appendChild(y);var k=new p(this.ctx);t.config.legend.showForZeroSeries||0===k.getSeriesTotalByIndex(c)&&k.seriesHaveSameValues(c)&&!k.isSeriesNull(c)&&-1===t.globals.collapsedSeriesIndices.indexOf(c)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(c)&&m.classList.add("apexcharts-hidden-zero-series"),t.config.legend.showForNullSeries||k.isSeriesNull(c)&&-1===t.globals.collapsedSeriesIndices.indexOf(c)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(c)&&m.classList.add("apexcharts-hidden-null-series"),t.globals.dom.elLegendWrap.appendChild(m),t.globals.dom.elLegendWrap.classList.add("apexcharts-align-".concat(t.config.legend.horizontalAlign)),t.globals.dom.elLegendWrap.classList.add("apx-legend-position-"+t.config.legend.position),m.classList.add("apexcharts-legend-series"),m.style.margin="".concat(t.config.legend.itemMargin.vertical,"px ").concat(t.config.legend.itemMargin.horizontal,"px"),t.globals.dom.elLegendWrap.style.width=t.config.legend.width?t.config.legend.width+"px":"",t.globals.dom.elLegendWrap.style.height=t.config.legend.height?t.config.legend.height+"px":"",g.setAttrs(m,{rel:c+1,seriesName:r.escapeString(a[c]),"data:collapsed":u||f}),(u||f)&&m.classList.add("apexcharts-inactive-legend"),t.config.legend.onItemClick.toggleDataSeries||m.classList.add("apexcharts-no-click")}t.globals.dom.elWrap.addEventListener("click",e.onLegendClick,!0),t.config.legend.onItemHover.highlightDataSeries&&0===t.config.legend.customLegendItems.length&&(t.globals.dom.elWrap.addEventListener("mousemove",e.onLegendHovered,!0),t.globals.dom.elWrap.addEventListener("mouseout",e.onLegendHovered,!0))}},{key:"setLegendWrapXY",value:function(e,t){var i=this.w,a=i.globals.dom.elLegendWrap,r=a.getBoundingClientRect(),s=0,n=0;if("bottom"===i.config.legend.position)n+=i.globals.svgHeight-r.height/2;else if("top"===i.config.legend.position){var o=new et(this.ctx),l=o.dimHelpers.getTitleSubtitleCoords("title").height,c=o.dimHelpers.getTitleSubtitleCoords("subtitle").height;n=n+(l>0?l-10:0)+(c>0?c-10:0)}a.style.position="absolute",s=s+e+i.config.legend.offsetX,n=n+t+i.config.legend.offsetY,a.style.left=s+"px",a.style.top=n+"px","bottom"===i.config.legend.position?(a.style.top="auto",a.style.bottom=5-i.config.legend.offsetY+"px"):"right"===i.config.legend.position&&(a.style.left="auto",a.style.right=25+i.config.legend.offsetX+"px"),["width","height"].forEach((function(e){a.style[e]&&(a.style[e]=parseInt(i.config.legend[e],10)+"px")}))}},{key:"legendAlignHorizontal",value:function(){var e=this.w;e.globals.dom.elLegendWrap.style.right=0;var t=this.legendHelpers.getLegendDimensions(),i=new et(this.ctx),a=i.dimHelpers.getTitleSubtitleCoords("title"),r=i.dimHelpers.getTitleSubtitleCoords("subtitle"),s=0;"bottom"===e.config.legend.position?s=-t.clwh/1.8:"top"===e.config.legend.position&&(s=a.height+r.height+e.config.title.margin+e.config.subtitle.margin-10),this.setLegendWrapXY(20,s)}},{key:"legendAlignVertical",value:function(){var e=this.w,t=this.legendHelpers.getLegendDimensions(),i=0;"left"===e.config.legend.position&&(i=20),"right"===e.config.legend.position&&(i=e.globals.svgWidth-t.clww-10),this.setLegendWrapXY(i,20)}},{key:"onLegendHovered",value:function(e){var t=this.w,i=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(i){var a=parseInt(e.target.getAttribute("rel"),10)-1;this.ctx.events.fireEvent("legendHover",[this.ctx,a,this.w]),new ce(this.ctx).highlightRangeInSeries(e,e.target)}}else!e.target.classList.contains("apexcharts-inactive-legend")&&i&&new ce(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 i=parseInt(e.target.getAttribute("rel"),10)-1,a="true"===e.target.getAttribute("data:collapsed"),r=this.w.config.chart.events.legendClick;"function"==typeof r&&r(this.ctx,i,this.w),this.ctx.events.fireEvent("legendClick",[this.ctx,i,this.w]);var s=this.w.config.legend.markers.onClick;"function"==typeof s&&e.target.classList.contains("apexcharts-legend-marker")&&(s(this.ctx,i,this.w),this.ctx.events.fireEvent("legendMarkerClick",[this.ctx,i,this.w])),"treemap"!==t.config.chart.type&&"heatmap"!==t.config.chart.type&&!this.isBarsDistributed&&t.config.legend.onItemClick.toggleDataSeries&&this.legendHelpers.toggleDataSeries(i,a)}}}])&&nt(t.prototype,i),e}();var lt=i(798),ct=i.n(lt),ht=i(688),dt=i.n(ht),ut=i(149),gt=i.n(ut),ft=i(323),pt=i.n(ft),xt=i(686),bt=i.n(xt),vt=i(618),mt=i.n(vt),yt=i(355),wt=i.n(yt);function kt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var At=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.w;this.ev=this.w.config.chart.events,this.selectedClass="apexcharts-selected",this.localeValues=this.w.globals.locale.toolbar,this.minX=i.globals.minX,this.maxX=i.globals.maxX}var t,i;return t=e,(i=[{key:"createToolbar",value:function(){var e=this,t=this.w,i=function(){return document.createElement("div")},a=i();if(a.setAttribute("class","apexcharts-toolbar"),a.style.top=t.config.chart.toolbar.offsetY+"px",a.style.right=3-t.config.chart.toolbar.offsetX+"px",t.globals.dom.elWrap.appendChild(a),this.elZoom=i(),this.elZoomIn=i(),this.elZoomOut=i(),this.elPan=i(),this.elSelection=i(),this.elZoomReset=i(),this.elMenuIcon=i(),this.elMenu=i(),this.elCustomIcons=[],this.t=t.config.chart.toolbar.tools,Array.isArray(this.t.customIcons))for(var s=0;s<this.t.customIcons.length;s++)this.elCustomIcons.push(i());var n=[],o=function(i,a,r){var s=i.toLowerCase();e.t[s]&&t.config.chart.zoom.enabled&&n.push({el:a,icon:"string"==typeof e.t[s]?e.t[s]:r,title:e.localeValues[i],class:"apexcharts-".concat(s,"-icon")})};o("zoomIn",this.elZoomIn,pt()),o("zoomOut",this.elZoomOut,bt());var l=function(i){e.t[i]&&t.config.chart[i].enabled&&n.push({el:"zoom"===i?e.elZoom:e.elSelection,icon:"string"==typeof e.t[i]?e.t[i]:"zoom"===i?dt():mt(),title:e.localeValues["zoom"===i?"selectionZoom":"selection"],class:t.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-".concat(i,"-icon")})};l("zoom"),l("selection"),this.t.pan&&t.config.chart.zoom.enabled&&n.push({el:this.elPan,icon:"string"==typeof this.t.pan?this.t.pan:ct(),title:this.localeValues.pan,class:t.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-pan-icon"}),o("reset",this.elZoomReset,gt()),this.t.download&&n.push({el:this.elMenuIcon,icon:"string"==typeof this.t.download?this.t.download:wt(),title:this.localeValues.menu,class:"apexcharts-menu-icon"});for(var c=0;c<this.elCustomIcons.length;c++)n.push({el:this.elCustomIcons[c],icon:this.t.customIcons[c].icon,title:this.t.customIcons[c].title,index:this.t.customIcons[c].index,class:"apexcharts-toolbar-custom-icon "+this.t.customIcons[c].class});n.forEach((function(e,t){e.index&&r.moveIndexInArray(n,t,e.index)}));for(var h=0;h<n.length;h++)g.setAttrs(n[h].el,{class:n[h].class,title:n[h].title}),n[h].el.innerHTML=n[h].icon,a.appendChild(n[h].el);this._createHamburgerMenu(a),t.globals.zoomEnabled?this.elZoom.classList.add(this.selectedClass):t.globals.panEnabled?this.elPan.classList.add(this.selectedClass):t.globals.selectionEnabled&&this.elSelection.classList.add(this.selectedClass),this.addToolbarEventListeners()}},{key:"_createHamburgerMenu",value:function(e){this.elMenuItems=[],e.appendChild(this.elMenu),g.setAttrs(this.elMenu,{class:"apexcharts-menu"});for(var t=[{name:"exportSVG",title:this.localeValues.exportToSVG},{name:"exportPNG",title:this.localeValues.exportToPNG},{name:"exportCSV",title:this.localeValues.exportToCSV}],i=0;i<t.length;i++)this.elMenuItems.push(document.createElement("div")),this.elMenuItems[i].innerHTML=t[i].title,g.setAttrs(this.elMenuItems[i],{class:"apexcharts-menu-item ".concat(t[i].name),title:t[i].title}),this.elMenu.appendChild(this.elMenuItems[i])}},{key:"addToolbarEventListeners",value:function(){var e=this;this.elZoomReset.addEventListener("click",this.handleZoomReset.bind(this)),this.elSelection.addEventListener("click",this.toggleZoomSelection.bind(this,"selection")),this.elZoom.addEventListener("click",this.toggleZoomSelection.bind(this,"zoom")),this.elZoomIn.addEventListener("click",this.handleZoomIn.bind(this)),this.elZoomOut.addEventListener("click",this.handleZoomOut.bind(this)),this.elPan.addEventListener("click",this.togglePanning.bind(this)),this.elMenuIcon.addEventListener("click",this.toggleMenu.bind(this)),this.elMenuItems.forEach((function(t){t.classList.contains("exportSVG")?t.addEventListener("click",e.handleDownload.bind(e,"svg")):t.classList.contains("exportPNG")?t.addEventListener("click",e.handleDownload.bind(e,"png")):t.classList.contains("exportCSV")&&t.addEventListener("click",e.handleDownload.bind(e,"csv"))}));for(var t=0;t<this.t.customIcons.length;t++)this.elCustomIcons[t].addEventListener("click",this.t.customIcons[t].click.bind(this,this.ctx,this.ctx.w))}},{key:"toggleZoomSelection",value:function(e){this.ctx.getSyncedCharts().forEach((function(t){t.ctx.toolbar.toggleOtherControls();var i="selection"===e?t.ctx.toolbar.elSelection:t.ctx.toolbar.elZoom,a="selection"===e?"selectionEnabled":"zoomEnabled";t.w.globals[a]=!t.w.globals[a],i.classList.contains(t.ctx.toolbar.selectedClass)?i.classList.remove(t.ctx.toolbar.selectedClass):i.classList.add(t.ctx.toolbar.selectedClass)}))}},{key:"getToolbarIconsReference",value:function(){var e=this.w;this.elZoom||(this.elZoom=e.globals.dom.baseEl.querySelector(".apexcharts-zoom-icon")),this.elPan||(this.elPan=e.globals.dom.baseEl.querySelector(".apexcharts-pan-icon")),this.elSelection||(this.elSelection=e.globals.dom.baseEl.querySelector(".apexcharts-selection-icon"))}},{key:"enableZoomPanFromToolbar",value:function(e){this.toggleOtherControls(),"pan"===e?this.w.globals.panEnabled=!0:this.w.globals.zoomEnabled=!0;var t="pan"===e?this.elPan:this.elZoom,i="pan"===e?this.elZoom:this.elPan;t&&t.classList.add(this.selectedClass),i&&i.classList.remove(this.selectedClass)}},{key:"togglePanning",value:function(){this.ctx.getSyncedCharts().forEach((function(e){e.ctx.toolbar.toggleOtherControls(),e.w.globals.panEnabled=!e.w.globals.panEnabled,e.ctx.toolbar.elPan.classList.contains(e.ctx.toolbar.selectedClass)?e.ctx.toolbar.elPan.classList.remove(e.ctx.toolbar.selectedClass):e.ctx.toolbar.elPan.classList.add(e.ctx.toolbar.selectedClass)}))}},{key:"toggleOtherControls",value:function(){var e=this,t=this.w;t.globals.panEnabled=!1,t.globals.zoomEnabled=!1,t.globals.selectionEnabled=!1,this.getToolbarIconsReference(),[this.elPan,this.elSelection,this.elZoom].forEach((function(t){t&&t.classList.remove(e.selectedClass)}))}},{key:"handleZoomIn",value:function(){var e=this.w;e.globals.isRangeBar&&(this.minX=e.globals.minY,this.maxX=e.globals.maxY);var t=(this.minX+this.maxX)/2,i=(this.minX+t)/2,a=(this.maxX+t)/2,r=this._getNewMinXMaxX(i,a);e.globals.disableZoomIn||this.zoomUpdateOptions(r.minX,r.maxX)}},{key:"handleZoomOut",value:function(){var e=this.w;if(e.globals.isRangeBar&&(this.minX=e.globals.minY,this.maxX=e.globals.maxY),!("datetime"===e.config.xaxis.type&&new Date(this.minX).getUTCFullYear()<1e3)){var t=(this.minX+this.maxX)/2,i=this.minX-(t-this.minX),a=this.maxX-(t-this.maxX),r=this._getNewMinXMaxX(i,a);e.globals.disableZoomOut||this.zoomUpdateOptions(r.minX,r.maxX)}}},{key:"_getNewMinXMaxX",value:function(e,t){var i=this.w.config.xaxis.convertedCatToNumeric;return{minX:i?Math.floor(e):e,maxX:i?Math.floor(t):t}}},{key:"zoomUpdateOptions",value:function(e,t){var i=this.w;if(void 0!==e||void 0!==t){if(!(i.config.xaxis.convertedCatToNumeric&&(e<1&&(e=1,t=i.globals.dataPoints),t-e<2))){var a={min:e,max:t},s=this.getBeforeZoomRange(a);s&&(a=s.xaxis);var n={xaxis:a},o=r.clone(i.globals.initialConfig.yaxis);i.config.chart.group||(n.yaxis=o),this.w.globals.zoomed=!0,this.ctx.updateHelpers._updateOptions(n,!1,this.w.config.chart.animations.dynamicAnimation.enabled),this.zoomCallback(a,o)}}else this.handleZoomReset()}},{key:"zoomCallback",value:function(e,t){"function"==typeof this.ev.zoomed&&this.ev.zoomed(this.ctx,{xaxis:e,yaxis:t})}},{key:"getBeforeZoomRange",value:function(e,t){var i=null;return"function"==typeof this.ev.beforeZoom&&(i=this.ev.beforeZoom(this,{xaxis:e,yaxis:t})),i}},{key:"toggleMenu",value:function(){var e=this;window.setTimeout((function(){e.elMenu.classList.contains("apexcharts-menu-open")?e.elMenu.classList.remove("apexcharts-menu-open"):e.elMenu.classList.add("apexcharts-menu-open")}),0)}},{key:"handleDownload",value:function(e){var t=this.w,i=new xe(this.ctx);switch(e){case"svg":i.exportToSVG(this.ctx);break;case"png":i.exportToPng(this.ctx);break;case"csv":i.exportToCSV({series:t.config.series,columnDelimiter:t.config.chart.toolbar.export.csv.columnDelimiter})}}},{key:"handleZoomReset",value:function(e){this.ctx.getSyncedCharts().forEach((function(e){var t=e.w;if(t.globals.lastXAxis.min=t.globals.initialConfig.xaxis.min,t.globals.lastXAxis.max=t.globals.initialConfig.xaxis.max,e.updateHelpers.revertDefaultAxisMinMax(),"function"==typeof t.config.chart.events.beforeResetZoom){var i=t.config.chart.events.beforeResetZoom(e,t);i&&e.updateHelpers.revertDefaultAxisMinMax(i)}"function"==typeof t.config.chart.events.zoomed&&e.ctx.toolbar.zoomCallback({min:t.config.xaxis.min,max:t.config.xaxis.max}),t.globals.zoomed=!1;var a=e.ctx.series.emptyCollapsedSeries(r.clone(t.globals.initialSeries));e.updateHelpers._updateSeries(a,t.config.chart.animations.dynamicAnimation.enabled)}))}},{key:"destroy",value:function(){this.elZoom=null,this.elZoomIn=null,this.elZoomOut=null,this.elPan=null,this.elSelection=null,this.elZoomReset=null,this.elMenuIcon=null}}])&&kt(t.prototype,i),e}();function St(e){return St="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},St(e)}function Ct(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function Pt(e,t){return Pt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Pt(e,t)}function Lt(e){return Lt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Lt(e)}var Ot=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Pt(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Lt(a);if(s){var i=Lt(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===St(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=n.call(this,e)).ctx=e,t.w=e.w,t.dragged=!1,t.graphics=new g(t.ctx),t.eventList=["mousedown","mouseleave","mousemove","touchstart","touchmove","mouseup","touchend"],t.clientX=0,t.clientY=0,t.startX=0,t.endX=0,t.dragX=0,t.startY=0,t.endY=0,t.dragY=0,t.moveDirection="none",t}return t=o,(i=[{key:"init",value:function(e){var t=this,i=e.xyRatios,a=this.w,r=this;this.xyRatios=i,this.zoomRect=this.graphics.drawRect(0,0,0,0),this.selectionRect=this.graphics.drawRect(0,0,0,0),this.gridRect=a.globals.dom.baseEl.querySelector(".apexcharts-grid"),this.zoomRect.node.classList.add("apexcharts-zoom-rect"),this.selectionRect.node.classList.add("apexcharts-selection-rect"),a.globals.dom.elGraphical.add(this.zoomRect),a.globals.dom.elGraphical.add(this.selectionRect),"x"===a.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,minY:0,maxX:a.globals.gridWidth,maxY:a.globals.gridHeight}).on("dragmove",this.selectionDragging.bind(this,"dragging")):"y"===a.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,maxX:a.globals.gridWidth}).on("dragmove",this.selectionDragging.bind(this,"dragging")):this.slDraggableRect=this.selectionRect.draggable().on("dragmove",this.selectionDragging.bind(this,"dragging")),this.preselectedSelection(),this.hoverArea=a.globals.dom.baseEl.querySelector("".concat(a.globals.chartClass," .apexcharts-svg")),this.hoverArea.classList.add("apexcharts-zoomable"),this.eventList.forEach((function(e){t.hoverArea.addEventListener(e,r.svgMouseEvents.bind(r,i),{capture:!1,passive:!0})}))}},{key:"destroy",value:function(){this.slDraggableRect&&(this.slDraggableRect.draggable(!1),this.slDraggableRect.off(),this.selectionRect.off()),this.selectionRect=null,this.zoomRect=null,this.gridRect=null}},{key:"svgMouseEvents",value:function(e,t){var i=this.w,a=this,r=this.ctx.toolbar,s=i.globals.zoomEnabled?i.config.chart.zoom.type:i.config.chart.selection.type,n=i.config.chart.toolbar.autoSelected;if(t.shiftKey?(this.shiftWasPressed=!0,r.enableZoomPanFromToolbar("pan"===n?"zoom":"pan")):this.shiftWasPressed&&(r.enableZoomPanFromToolbar(n),this.shiftWasPressed=!1),t.target){var o,l=t.target.classList;if(t.target.parentNode&&null!==t.target.parentNode&&(o=t.target.parentNode.classList),!(l.contains("apexcharts-selection-rect")||l.contains("apexcharts-legend-marker")||l.contains("apexcharts-legend-text")||o&&o.contains("apexcharts-toolbar"))){if(a.clientX="touchmove"===t.type||"touchstart"===t.type?t.touches[0].clientX:"touchend"===t.type?t.changedTouches[0].clientX:t.clientX,a.clientY="touchmove"===t.type||"touchstart"===t.type?t.touches[0].clientY:"touchend"===t.type?t.changedTouches[0].clientY:t.clientY,"mousedown"===t.type&&1===t.which){var c=a.gridRect.getBoundingClientRect();a.startX=a.clientX-c.left,a.startY=a.clientY-c.top,a.dragged=!1,a.w.globals.mousedown=!0}if(("mousemove"===t.type&&1===t.which||"touchmove"===t.type)&&(a.dragged=!0,i.globals.panEnabled?(i.globals.selection=null,a.w.globals.mousedown&&a.panDragging({context:a,zoomtype:s,xyRatios:e})):(a.w.globals.mousedown&&i.globals.zoomEnabled||a.w.globals.mousedown&&i.globals.selectionEnabled)&&(a.selection=a.selectionDrawing({context:a,zoomtype:s}))),"mouseup"===t.type||"touchend"===t.type||"mouseleave"===t.type){var h,d=null===(h=a.gridRect)||void 0===h?void 0:h.getBoundingClientRect();d&&a.w.globals.mousedown&&(a.endX=a.clientX-d.left,a.endY=a.clientY-d.top,a.dragX=Math.abs(a.endX-a.startX),a.dragY=Math.abs(a.endY-a.startY),(i.globals.zoomEnabled||i.globals.selectionEnabled)&&a.selectionDrawn({context:a,zoomtype:s}),i.globals.panEnabled&&i.config.xaxis.convertedCatToNumeric&&a.delayedPanScrolled()),i.globals.zoomEnabled&&a.hideSelectionRect(this.selectionRect),a.dragged=!1,a.w.globals.mousedown=!1}this.makeSelectionRectDraggable()}}}},{key:"makeSelectionRectDraggable",value:function(){var e=this.w;if(this.selectionRect){var t=this.selectionRect.node.getBoundingClientRect();t.width>0&&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 i=(e.config.chart.selection.xaxis.min-e.globals.minX)/t.xRatio,a=e.globals.gridWidth-(e.globals.maxX-e.config.chart.selection.xaxis.max)/t.xRatio-i;e.globals.isRangeBar&&(i=(e.config.chart.selection.xaxis.min-e.globals.yAxisScale[0].niceMin)/t.invertedYRatio,a=(e.config.chart.selection.xaxis.max-e.config.chart.selection.xaxis.min)/t.invertedYRatio);var r={x:i,y:0,width:a,height:e.globals.gridHeight,translateX:0,translateY:0,selectionEnabled:!0};this.drawSelectionRect(r),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,i=e.y,a=e.width,r=e.height,s=e.translateX,n=void 0===s?0:s,o=e.translateY,l=void 0===o?0:o,c=this.w,h=this.zoomRect,d=this.selectionRect;if(this.dragged||null!==c.globals.selection){var u={transform:"translate("+n+", "+l+")"};c.globals.zoomEnabled&&this.dragged&&(a<0&&(a=1),h.attr({x:t,y:i,width:a,height:r,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}),g.setAttrs(h.node,u)),c.globals.selectionEnabled&&(d.attr({x:t,y:i,width:a>0?a:0,height:r>0?r: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}),g.setAttrs(d.node,u))}}},{key:"hideSelectionRect",value:function(e){e&&e.attr({x:0,y:0,width:0,height:0})}},{key:"selectionDrawing",value:function(e){var t,i=e.context,a=e.zoomtype,r=this.w,s=i,n=this.gridRect.getBoundingClientRect(),o=s.startX-1,l=s.startY,c=!1,h=!1,d=s.clientX-n.left-o,u=s.clientY-n.top-l;return Math.abs(d+o)>r.globals.gridWidth?d=r.globals.gridWidth-o:s.clientX-n.left<0&&(d=o),o>s.clientX-n.left&&(c=!0,d=Math.abs(d)),l>s.clientY-n.top&&(h=!0,u=Math.abs(u)),t="x"===a?{x:c?o-d:o,y:0,width:d,height:r.globals.gridHeight}:"y"===a?{x:0,y:h?l-u:l,width:r.globals.gridWidth,height:u}:{x:c?o-d:o,y:h?l-u:l,width:d,height:u},s.drawSelectionRect(t),s.selectionDragging("resizing"),t}},{key:"selectionDragging",value:function(e,t){var i=this,a=this.w,r=this.xyRatios,s=this.selectionRect,n=0;"resizing"===e&&(n=30);var o=function(e){return parseFloat(s.node.getAttribute(e))},l={x:o("x"),y:o("y"),width:o("width"),height:o("height")};a.globals.selection=l,"function"==typeof a.config.chart.events.selection&&a.globals.selectionEnabled&&(clearTimeout(this.w.globals.selectionResizeTimer),this.w.globals.selectionResizeTimer=window.setTimeout((function(){var e,t,n,o,l=i.gridRect.getBoundingClientRect(),c=s.node.getBoundingClientRect();a.globals.isRangeBar?(e=a.globals.yAxisScale[0].niceMin+(c.left-l.left)*r.invertedYRatio,t=a.globals.yAxisScale[0].niceMin+(c.right-l.left)*r.invertedYRatio,n=0,o=1):(e=a.globals.xAxisScale.niceMin+(c.left-l.left)*r.xRatio,t=a.globals.xAxisScale.niceMin+(c.right-l.left)*r.xRatio,n=a.globals.yAxisScale[0].niceMin+(l.bottom-c.bottom)*r.yRatio[0],o=a.globals.yAxisScale[0].niceMax-(c.top-l.top)*r.yRatio[0]);var h={xaxis:{min:e,max:t},yaxis:{min:n,max:o}};a.config.chart.events.selection(i.ctx,h),a.config.chart.brush.enabled&&void 0!==a.config.chart.events.brushScrolled&&a.config.chart.events.brushScrolled(i.ctx,h)}),n))}},{key:"selectionDrawn",value:function(e){var t=e.context,i=e.zoomtype,a=this.w,s=t,n=this.xyRatios,o=this.ctx.toolbar;if(s.startX>s.endX){var l=s.startX;s.startX=s.endX,s.endX=l}if(s.startY>s.endY){var c=s.startY;s.startY=s.endY,s.endY=c}var h=void 0,d=void 0;a.globals.isRangeBar?(h=a.globals.yAxisScale[0].niceMin+s.startX*n.invertedYRatio,d=a.globals.yAxisScale[0].niceMin+s.endX*n.invertedYRatio):(h=a.globals.xAxisScale.niceMin+s.startX*n.xRatio,d=a.globals.xAxisScale.niceMin+s.endX*n.xRatio);var u=[],g=[];if(a.config.yaxis.forEach((function(e,t){var i=a.globals.seriesYAxisMap[t][0];u.push(a.globals.yAxisScale[t].niceMax-n.yRatio[i]*s.startY),g.push(a.globals.yAxisScale[t].niceMax-n.yRatio[i]*s.endY)})),s.dragged&&(s.dragX>10||s.dragY>10)&&h!==d)if(a.globals.zoomEnabled){var f=r.clone(a.globals.initialConfig.yaxis),p=r.clone(a.globals.initialConfig.xaxis);if(a.globals.zoomed=!0,a.config.xaxis.convertedCatToNumeric&&(h=Math.floor(h),d=Math.floor(d),h<1&&(h=1,d=a.globals.dataPoints),d-h<2&&(d=h+1)),"xy"!==i&&"x"!==i||(p={min:h,max:d}),"xy"!==i&&"y"!==i||f.forEach((function(e,t){f[t].min=g[t],f[t].max=u[t]})),o){var x=o.getBeforeZoomRange(p,f);x&&(p=x.xaxis?x.xaxis:p,f=x.yaxis?x.yaxis:f)}var b={xaxis:p};a.config.chart.group||(b.yaxis=f),s.ctx.updateHelpers._updateOptions(b,!1,s.w.config.chart.animations.dynamicAnimation.enabled),"function"==typeof a.config.chart.events.zoomed&&o.zoomCallback(p,f)}else if(a.globals.selectionEnabled){var v,m=null;v={min:h,max:d},"xy"!==i&&"y"!==i||(m=r.clone(a.config.yaxis)).forEach((function(e,t){m[t].min=g[t],m[t].max=u[t]})),a.globals.selection=s.selection,"function"==typeof a.config.chart.events.selection&&a.config.chart.events.selection(s.ctx,{xaxis:v,yaxis:m})}}},{key:"panDragging",value:function(e){var t=e.context,i=this.w,a=t;if(void 0!==i.globals.lastClientPosition.x){var r=i.globals.lastClientPosition.x-a.clientX,s=i.globals.lastClientPosition.y-a.clientY;Math.abs(r)>Math.abs(s)&&r>0?this.moveDirection="left":Math.abs(r)>Math.abs(s)&&r<0?this.moveDirection="right":Math.abs(s)>Math.abs(r)&&s>0?this.moveDirection="up":Math.abs(s)>Math.abs(r)&&s<0&&(this.moveDirection="down")}i.globals.lastClientPosition={x:a.clientX,y:a.clientY};var n=i.globals.isRangeBar?i.globals.minY:i.globals.minX,o=i.globals.isRangeBar?i.globals.maxY:i.globals.maxX;i.config.xaxis.convertedCatToNumeric||a.panScrolled(n,o)}},{key:"delayedPanScrolled",value:function(){var e=this.w,t=e.globals.minX,i=e.globals.maxX,a=(e.globals.maxX-e.globals.minX)/2;"left"===this.moveDirection?(t=e.globals.minX+a,i=e.globals.maxX+a):"right"===this.moveDirection&&(t=e.globals.minX-a,i=e.globals.maxX-a),t=Math.floor(t),i=Math.floor(i),this.updateScrolledChart({xaxis:{min:t,max:i}},t,i)}},{key:"panScrolled",value:function(e,t){var i=this.w,a=this.xyRatios,s=r.clone(i.globals.initialConfig.yaxis),n=a.xRatio,o=i.globals.minX,l=i.globals.maxX;i.globals.isRangeBar&&(n=a.invertedYRatio,o=i.globals.minY,l=i.globals.maxY),"left"===this.moveDirection?(e=o+i.globals.gridWidth/15*n,t=l+i.globals.gridWidth/15*n):"right"===this.moveDirection&&(e=o-i.globals.gridWidth/15*n,t=l-i.globals.gridWidth/15*n),i.globals.isRangeBar||(e<i.globals.initialMinX||t>i.globals.initialMaxX)&&(e=o,t=l);var c={xaxis:{min:e,max:t}};i.config.chart.group||(c.yaxis=s),this.updateScrolledChart(c,e,t)}},{key:"updateScrolledChart",value:function(e,t,i){var a=this.w;this.ctx.updateHelpers._updateOptions(e,!1,!1),"function"==typeof a.config.chart.events.scrolled&&a.config.chart.events.scrolled(this.ctx,{xaxis:{min:t,max:i}})}}])&&Ct(t.prototype,i),o}(At);function Mt(e){return function(e){if(Array.isArray(e))return Tt(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Tt(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Tt(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Tt(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function It(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Et=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ttCtx=t,this.ctx=t.ctx}var t,i;return t=e,(i=[{key:"getNearestValues",value:function(e){var t=e.hoverArea,i=e.elGrid,a=e.clientX,s=e.clientY,n=this.w,o=i.getBoundingClientRect(),l=o.width,c=o.height,h=l/(n.globals.dataPoints-1),d=c/n.globals.dataPoints,u=this.hasBars();!n.globals.comboCharts&&!u||n.config.xaxis.convertedCatToNumeric||(h=l/n.globals.dataPoints);var g=a-o.left-n.globals.barPadForNumericAxis,f=s-o.top;g<0||f<0||g>l||f>c?(t.classList.remove("hovering-zoom"),t.classList.remove("hovering-pan")):n.globals.zoomEnabled?(t.classList.remove("hovering-pan"),t.classList.add("hovering-zoom")):n.globals.panEnabled&&(t.classList.remove("hovering-zoom"),t.classList.add("hovering-pan"));var p=Math.round(g/h),x=Math.floor(f/d);u&&!n.config.xaxis.convertedCatToNumeric&&(p=Math.ceil(g/h),p-=1);var b=null,v=null,m=n.globals.seriesXvalues.map((function(e){return e.filter((function(e){return r.isNumber(e)}))})),y=n.globals.seriesYvalues.map((function(e){return e.filter((function(e){return r.isNumber(e)}))}));if(n.globals.isXNumeric){var w=this.ttCtx.getElGrid().getBoundingClientRect(),k=g*(w.width/l),A=f*(w.height/c);b=(v=this.closestInMultiArray(k,A,m,y)).index,p=v.j,null!==b&&(m=n.globals.seriesXvalues[b],p=(v=this.closestInArray(k,m)).index)}return n.globals.capturedSeriesIndex=null===b?-1:b,(!p||p<1)&&(p=0),n.globals.isBarHorizontal?n.globals.capturedDataPointIndex=x:n.globals.capturedDataPointIndex=p,{capturedSeries:b,j:n.globals.isBarHorizontal?x:p,hoverX:g,hoverY:f}}},{key:"closestInMultiArray",value:function(e,t,i,a){var r=this.w,s=0,n=null,o=-1;r.globals.series.length>1?s=this.getFirstActiveXArray(i):n=0;var l=i[s][0],c=Math.abs(e-l);if(i.forEach((function(t){t.forEach((function(t,i){var a=Math.abs(e-t);a<=c&&(c=a,o=i)}))})),-1!==o){var h=a[s][o],d=Math.abs(t-h);n=s,a.forEach((function(e,i){var a=Math.abs(t-e[o]);a<=d&&(d=a,n=i)}))}return{index:n,j:o}}},{key:"getFirstActiveXArray",value:function(e){for(var t=this.w,i=0,a=e.map((function(e,t){return e.length>0?t:-1})),r=0;r<a.length;r++)if(-1!==a[r]&&-1===t.globals.collapsedSeriesIndices.indexOf(r)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(r)){i=a[r];break}return i}},{key:"closestInArray",value:function(e,t){for(var i=t[0],a=null,r=Math.abs(e-i),s=0;s<t.length;s++){var n=Math.abs(e-t[s]);n<r&&(r=n,a=s)}return{index:a}}},{key:"isXoverlap",value:function(e){var t=[],i=this.w.globals.seriesX.filter((function(e){return void 0!==e[0]}));if(i.length>0)for(var a=0;a<i.length-1;a++)void 0!==i[a][e]&&void 0!==i[a+1][e]&&i[a][e]!==i[a+1][e]&&t.push("unEqual");return 0===t.length}},{key:"isInitialSeriesSameLen",value:function(){for(var e=!0,t=this.w.globals.initialSeries,i=0;i<t.length-1;i++)if(t[i].data.length!==t[i+1].data.length){e=!1;break}return e}},{key:"getBarsHeight",value:function(e){return Mt(e).reduce((function(e,t){return e+t.getBBox().height}),0)}},{key:"getElMarkers",value:function(e){return"number"==typeof e?this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series[data\\:realIndex='".concat(e,"'] .apexcharts-series-markers-wrap > *")):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=Mt(e)).sort((function(e,t){var i=Number(e.getAttribute("data:realIndex")),a=Number(t.getAttribute("data:realIndex"));return a<i?1:a>i?-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:"getPathFromPoint",value:function(e,t){var i=Number(e.getAttribute("cx")),a=Number(e.getAttribute("cy")),r=e.getAttribute("shape");return new g(this.ctx).getMarkerPath(i,a,r,t)}},{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,i=t.config.markers.hover.size;return void 0===i&&(i=t.globals.markers.size[e]+t.config.markers.hover.sizeOffset),i}},{key:"toggleAllTooltipSeriesGroups",value:function(e){var t=this.w,i=this.ttCtx;0===i.allTooltipSeriesGroups.length&&(i.allTooltipSeriesGroups=t.globals.dom.baseEl.querySelectorAll(".apexcharts-tooltip-series-group"));for(var a=i.allTooltipSeriesGroups,r=0;r<a.length;r++)"enable"===e?(a[r].classList.add("apexcharts-active"),a[r].style.display=t.config.tooltip.items.display):(a[r].classList.remove("apexcharts-active"),a[r].style.display="none")}}])&&It(t.prototype,i),e}();function zt(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Xt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?zt(Object(i),!0).forEach((function(t){Yt(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):zt(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Yt(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Dt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Rt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ctx=t.ctx,this.ttCtx=t,this.tooltipUtil=new Et(t)}var t,i;return t=e,(i=[{key:"drawSeriesTexts",value:function(e){var t=e.shared,i=void 0===t||t,a=e.ttItems,r=e.i,s=void 0===r?0:r,n=e.j,o=void 0===n?null:n,l=e.y1,c=e.y2,h=e.e,d=this.w;void 0!==d.config.tooltip.custom?this.handleCustomTooltip({i:s,j:o,y1:l,y2:c,w:d}):this.toggleActiveInactiveSeries(i,s);var u=this.getValuesToPrint({i:s,j:o});this.printLabels({i:s,j:o,values:u,ttItems:a,shared:i,e:h});var g=this.ttCtx.getElTooltip();this.ttCtx.tooltipRect.ttWidth=g.getBoundingClientRect().width,this.ttCtx.tooltipRect.ttHeight=g.getBoundingClientRect().height}},{key:"printLabels",value:function(e){var t,i=this,a=e.i,r=e.j,s=e.values,n=e.ttItems,o=e.shared,l=e.e,c=this.w,h=[],d=function(e){return c.globals.seriesGoals[e]&&c.globals.seriesGoals[e][r]&&Array.isArray(c.globals.seriesGoals[e][r])},u=s.xVal,g=s.zVal,f=s.xAxisTTVal,p="",x=c.globals.colors[a];null!==r&&c.config.plotOptions.bar.distributed&&(x=c.globals.colors[r]);for(var b=function(e,s){var b=i.getFormatters(a);p=i.getSeriesName({fn:b.yLbTitleFormatter,index:a,seriesIndex:a,j:r}),"treemap"===c.config.chart.type&&(p=b.yLbTitleFormatter(String(c.config.series[a].data[r].x),{series:c.globals.series,seriesIndex:a,dataPointIndex:r,w:c}));var v=c.config.tooltip.inverseOrder?s:e;if(c.globals.axisCharts){var m=function(e){var t,i,a,s;return c.globals.isRangeData?b.yLbFormatter(null===(t=c.globals.seriesRangeStart)||void 0===t||null===(i=t[e])||void 0===i?void 0:i[r],{series:c.globals.seriesRangeStart,seriesIndex:e,dataPointIndex:r,w:c})+" - "+b.yLbFormatter(null===(a=c.globals.seriesRangeEnd)||void 0===a||null===(s=a[e])||void 0===s?void 0:s[r],{series:c.globals.seriesRangeEnd,seriesIndex:e,dataPointIndex:r,w:c}):b.yLbFormatter(c.globals.series[e][r],{series:c.globals.series,seriesIndex:e,dataPointIndex:r,w:c})};if(o)b=i.getFormatters(v),p=i.getSeriesName({fn:b.yLbTitleFormatter,index:v,seriesIndex:a,j:r}),x=c.globals.colors[v],t=m(v),d(v)&&(h=c.globals.seriesGoals[v][r].map((function(e){return{attrs:e,val:b.yLbFormatter(e.value,{seriesIndex:v,dataPointIndex:r,w:c})}})));else{var y,w=null==l||null===(y=l.target)||void 0===y?void 0:y.getAttribute("fill");w&&(x=-1!==w.indexOf("url")?document.querySelector(w.substr(4).slice(0,-1)).childNodes[0].getAttribute("stroke"):w),t=m(a),d(a)&&Array.isArray(c.globals.seriesGoals[a][r])&&(h=c.globals.seriesGoals[a][r].map((function(e){return{attrs:e,val:b.yLbFormatter(e.value,{seriesIndex:a,dataPointIndex:r,w:c})}})))}}null===r&&(t=b.yLbFormatter(c.globals.series[a],Xt(Xt({},c),{},{seriesIndex:a,dataPointIndex:a}))),i.DOMHandling({i:a,t:v,j:r,ttItems:n,values:{val:t,goalVals:h,xVal:u,xAxisTTVal:f,zVal:g},seriesName:p,shared:o,pColor:x})},v=0,m=c.globals.series.length-1;v<c.globals.series.length;v++,m--)b(v,m)}},{key:"getFormatters",value:function(e){var t,i=this.w,a=i.globals.yLabelFormatters[e];return void 0!==i.globals.ttVal?Array.isArray(i.globals.ttVal)?(a=i.globals.ttVal[e]&&i.globals.ttVal[e].formatter,t=i.globals.ttVal[e]&&i.globals.ttVal[e].title&&i.globals.ttVal[e].title.formatter):(a=i.globals.ttVal.formatter,"function"==typeof i.globals.ttVal.title.formatter&&(t=i.globals.ttVal.title.formatter)):t=i.config.tooltip.y.title.formatter,"function"!=typeof a&&(a=i.globals.yLabelFormatters[0]?i.globals.yLabelFormatters[0]:function(e){return e}),"function"!=typeof t&&(t=function(e){return e}),{yLbFormatter:a,yLbTitleFormatter:t}}},{key:"getSeriesName",value:function(e){var t=e.fn,i=e.index,a=e.seriesIndex,r=e.j,s=this.w;return t(String(s.globals.seriesNames[i]),{series:s.globals.series,seriesIndex:a,dataPointIndex:r,w:s})}},{key:"DOMHandling",value:function(e){e.i;var t=e.t,i=e.j,a=e.ttItems,r=e.values,s=e.seriesName,n=e.shared,o=e.pColor,l=this.w,c=this.ttCtx,h=r.val,d=r.goalVals,u=r.xVal,g=r.xAxisTTVal,f=r.zVal,p=null;p=a[t].children,l.config.tooltip.fillSeriesColor&&(a[t].style.backgroundColor=o,p[0].style.display="none"),c.showTooltipTitle&&(null===c.tooltipTitle&&(c.tooltipTitle=l.globals.dom.baseEl.querySelector(".apexcharts-tooltip-title")),c.tooltipTitle.innerHTML=u),c.isXAxisTooltipEnabled&&(c.xaxisTooltipText.innerHTML=""!==g?g:u);var x=a[t].querySelector(".apexcharts-tooltip-text-y-label");x&&(x.innerHTML=s||"");var b=a[t].querySelector(".apexcharts-tooltip-text-y-value");b&&(b.innerHTML=void 0!==h?h:""),p[0]&&p[0].classList.contains("apexcharts-tooltip-marker")&&(l.config.tooltip.marker.fillColors&&Array.isArray(l.config.tooltip.marker.fillColors)&&(o=l.config.tooltip.marker.fillColors[t]),p[0].style.backgroundColor=o),l.config.tooltip.marker.show||(p[0].style.display="none");var v=a[t].querySelector(".apexcharts-tooltip-text-goals-label"),m=a[t].querySelector(".apexcharts-tooltip-text-goals-value");if(d.length&&l.globals.seriesGoals[t]){var y=function(){var e="<div >",t="<div>";d.forEach((function(i,a){e+=' <div style="display: flex"><span class="apexcharts-tooltip-marker" style="background-color: '.concat(i.attrs.strokeColor,'; height: 3px; border-radius: 0; top: 5px;"></span> ').concat(i.attrs.name,"</div>"),t+="<div>".concat(i.val,"</div>")})),v.innerHTML=e+"</div>",m.innerHTML=t+"</div>"};n?l.globals.seriesGoals[t][i]&&Array.isArray(l.globals.seriesGoals[t][i])?y():(v.innerHTML="",m.innerHTML=""):y()}else v.innerHTML="",m.innerHTML="";if(null!==f&&(a[t].querySelector(".apexcharts-tooltip-text-z-label").innerHTML=l.config.tooltip.z.title,a[t].querySelector(".apexcharts-tooltip-text-z-value").innerHTML=void 0!==f?f:""),n&&p[0]){if(l.config.tooltip.hideEmptySeries){var w=a[t].querySelector(".apexcharts-tooltip-marker"),k=a[t].querySelector(".apexcharts-tooltip-text");0==parseFloat(h)?(w.style.display="none",k.style.display="none"):(w.style.display="block",k.style.display="block")}null==h||l.globals.ancillaryCollapsedSeriesIndices.indexOf(t)>-1||l.globals.collapsedSeriesIndices.indexOf(t)>-1||Array.isArray(c.tConfig.enabledOnSeries)&&-1===c.tConfig.enabledOnSeries.indexOf(t)?p[0].parentNode.style.display="none":p[0].parentNode.style.display=l.config.tooltip.items.display}else Array.isArray(c.tConfig.enabledOnSeries)&&-1===c.tConfig.enabledOnSeries.indexOf(t)&&(p[0].parentNode.style.display="none")}},{key:"toggleActiveInactiveSeries",value:function(e,t){var i=this.w;if(e)this.tooltipUtil.toggleAllTooltipSeriesGroups("enable");else{this.tooltipUtil.toggleAllTooltipSeriesGroups("disable");var a=i.globals.dom.baseEl.querySelector(".apexcharts-tooltip-series-group-".concat(t));a&&(a.classList.add("apexcharts-active"),a.style.display=i.config.tooltip.items.display)}}},{key:"getValuesToPrint",value:function(e){var t=e.i,i=e.j,a=this.w,r=this.ctx.series.filteredSeriesX(),s="",n="",o=null,l=null,c={series:a.globals.series,seriesIndex:t,dataPointIndex:i,w:a},h=a.globals.ttZFormatter;null===i?l=a.globals.series[t]:a.globals.isXNumeric&&"treemap"!==a.config.chart.type?(s=r[t][i],0===r[t].length&&(s=r[this.tooltipUtil.getFirstActiveXArray(r)][i])):s=void 0!==a.globals.labels[i]?a.globals.labels[i]:"";var d=s;return s=a.globals.isXNumeric&&"datetime"===a.config.xaxis.type?new C(this.ctx).xLabelFormat(a.globals.ttKeyFormatter,d,d,{i:void 0,dateFormatter:new A(this.ctx).formatDate,w:this.w}):a.globals.isBarHorizontal?a.globals.yLabelFormatters[0](d,c):a.globals.xLabelFormatter(d,c),void 0!==a.config.tooltip.x.formatter&&(s=a.globals.ttKeyFormatter(d,c)),a.globals.seriesZ.length>0&&a.globals.seriesZ[t].length>0&&(o=h(a.globals.seriesZ[t][i],a)),n="function"==typeof a.config.xaxis.tooltip.formatter?a.globals.xaxisTooltipFormatter(d,c):s,{val:Array.isArray(l)?l.join(" "):l,xVal:Array.isArray(s)?s.join(" "):s,xAxisTTVal:Array.isArray(n)?n.join(" "):n,zVal:o}}},{key:"handleCustomTooltip",value:function(e){var t=e.i,i=e.j,a=e.y1,r=e.y2,s=e.w,n=this.ttCtx.getElTooltip(),o=s.config.tooltip.custom;Array.isArray(o)&&o[t]&&(o=o[t]),n.innerHTML=o({ctx:this.ctx,series:s.globals.series,seriesIndex:t,dataPointIndex:i,y1:a,y2:r,w:s})}}])&&Dt(t.prototype,i),e}();function Ft(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ht=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ttCtx=t,this.ctx=t.ctx,this.w=t.w}var t,i;return t=e,i=[{key:"moveXCrosshairs",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=this.ttCtx,a=this.w,r=i.getElXCrosshairs(),s=e-i.xcrosshairsWidth/2,n=a.globals.labels.slice().length;if(null!==t&&(s=a.globals.gridWidth/n*t),null===r||a.globals.isBarHorizontal||(r.setAttribute("x",s),r.setAttribute("x1",s),r.setAttribute("x2",s),r.setAttribute("y2",a.globals.gridHeight),r.classList.add("apexcharts-active")),s<0&&(s=0),s>a.globals.gridWidth&&(s=a.globals.gridWidth),i.isXAxisTooltipEnabled){var o=s;"tickWidth"!==a.config.xaxis.crosshairs.width&&"barWidth"!==a.config.xaxis.crosshairs.width||(o=s+i.xcrosshairsWidth/2),this.moveXAxisTooltip(o)}}},{key:"moveYCrosshairs",value:function(e){var t=this.ttCtx;null!==t.ycrosshairs&&g.setAttrs(t.ycrosshairs,{y1:e,y2:e}),null!==t.ycrosshairsHidden&&g.setAttrs(t.ycrosshairsHidden,{y1:e,y2:e})}},{key:"moveXAxisTooltip",value:function(e){var t=this.w,i=this.ttCtx;if(null!==i.xaxisTooltip&&0!==i.xcrosshairsWidth){i.xaxisTooltip.classList.add("apexcharts-active");var a,r=i.xaxisOffY+t.config.xaxis.tooltip.offsetY+t.globals.translateY+1+t.config.xaxis.offsetY;e-=i.xaxisTooltip.getBoundingClientRect().width/2,isNaN(e)||(e+=t.globals.translateX,a=new g(this.ctx).getTextRects(i.xaxisTooltipText.innerHTML),i.xaxisTooltipText.style.minWidth=a.width+"px",i.xaxisTooltip.style.left=e+"px",i.xaxisTooltip.style.top=r+"px")}}},{key:"moveYAxisTooltip",value:function(e){var t=this.w,i=this.ttCtx;null===i.yaxisTTEls&&(i.yaxisTTEls=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));var a=parseInt(i.ycrosshairsHidden.getAttribute("y1"),10),r=t.globals.translateY+a,s=i.yaxisTTEls[e].getBoundingClientRect().height,n=t.globals.translateYAxisX[e]-2;t.config.yaxis[e].opposite&&(n-=26),r-=s/2,-1===t.globals.ignoreYAxisIndexes.indexOf(e)?(i.yaxisTTEls[e].classList.add("apexcharts-active"),i.yaxisTTEls[e].style.top=r+"px",i.yaxisTTEls[e].style.left=n+t.config.yaxis[e].tooltip.offsetX+"px"):i.yaxisTTEls[e].classList.remove("apexcharts-active")}},{key:"moveTooltip",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=this.w,r=this.ttCtx,s=r.getElTooltip(),n=r.tooltipRect,o=null!==i?parseFloat(i):1,l=parseFloat(e)+o+5,c=parseFloat(t)+o/2;if(l>a.globals.gridWidth/2&&(l=l-n.ttWidth-o-10),l>a.globals.gridWidth-n.ttWidth-10&&(l=a.globals.gridWidth-n.ttWidth),l<-20&&(l=-20),a.config.tooltip.followCursor){var h=r.getElGrid().getBoundingClientRect();(l=r.e.clientX-h.left)>a.globals.gridWidth/2&&(l-=r.tooltipRect.ttWidth),(c=r.e.clientY+a.globals.translateY-h.top)>a.globals.gridHeight/2&&(c-=r.tooltipRect.ttHeight)}else a.globals.isBarHorizontal||n.ttHeight/2+c>a.globals.gridHeight&&(c=a.globals.gridHeight-n.ttHeight+a.globals.translateY);isNaN(l)||(l+=a.globals.translateX,s.style.left=l+"px",s.style.top=c+"px")}},{key:"moveMarkers",value:function(e,t){var i=this.w,a=this.ttCtx;if(i.globals.markers.size[e]>0)for(var r=i.globals.dom.baseEl.querySelectorAll(" .apexcharts-series[data\\:realIndex='".concat(e,"'] .apexcharts-marker")),s=0;s<r.length;s++)parseInt(r[s].getAttribute("rel"),10)===t&&(a.marker.resetPointsSize(),a.marker.enlargeCurrentPoint(t,r[s]));else a.marker.resetPointsSize(),this.moveDynamicPointOnHover(t,e)}},{key:"moveDynamicPointOnHover",value:function(e,t){var i,a,r,s,n=this.w,o=this.ttCtx,l=new g(this.ctx),c=n.globals.pointsArray,h=o.tooltipUtil.getHoverMarkerSize(t),d=n.config.series[t].type;if(!d||"column"!==d&&"candlestick"!==d&&"boxPlot"!==d){r=null===(i=c[t][e])||void 0===i?void 0:i[0],s=(null===(a=c[t][e])||void 0===a?void 0:a[1])||0;var u=n.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(t,"'] .apexcharts-series-markers path"));if(u&&s<n.globals.gridHeight&&s>0){var f=u.getAttribute("shape"),p=l.getMarkerPath(r,s,f,1.5*h);u.setAttribute("d",p)}this.moveXCrosshairs(r),o.fixedTooltip||this.moveTooltip(r,s,h)}}},{key:"moveDynamicPointsOnHover",value:function(e){var t,i=this.ttCtx,a=i.w,r=0,s=0,n=a.globals.pointsArray,o=new ce(this.ctx),l=new g(this.ctx);t=o.getActiveConfigSeriesIndex("asc",["line","area","scatter","bubble"]);var c=i.tooltipUtil.getHoverMarkerSize(t);n[t]&&(r=n[t][e][0],s=n[t][e][1]);var h=i.tooltipUtil.getAllMarkers();if(null!==h)for(var d=0;d<a.globals.series.length;d++){var u=n[d];if(a.globals.comboCharts&&void 0===u&&h.splice(d,0,null),u&&u.length){var f=n[d][e][1],p=void 0;h[d].setAttribute("cx",r);var x=h[d].getAttribute("shape");if("rangeArea"===a.config.chart.type&&!a.globals.comboCharts){var b=e+a.globals.series[d].length;p=n[d][b][1],f-=Math.abs(f-p)/2}if(null!==f&&!isNaN(f)&&f<a.globals.gridHeight+c&&f+c>0){var v=l.getMarkerPath(r,f,x,c);h[d].setAttribute("d",v)}else h[d].setAttribute("d","")}}this.moveXCrosshairs(r),i.fixedTooltip||this.moveTooltip(r,s||a.globals.gridHeight,c)}},{key:"moveStickyTooltipOverBars",value:function(e,t){var i=this.w,a=this.ttCtx,r=i.globals.columnSeries?i.globals.columnSeries.length:i.globals.series.length,s=r>=2&&r%2==0?Math.floor(r/2):Math.floor(r/2)+1;i.globals.isBarHorizontal&&(s=new ce(this.ctx).getActiveConfigSeriesIndex("desc")+1);var n=i.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[rel='".concat(s,"'] path[j='").concat(e,"'], .apexcharts-candlestick-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(e,"'], .apexcharts-boxPlot-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(e,"'], .apexcharts-rangebar-series .apexcharts-series[rel='").concat(s,"'] path[j='").concat(e,"']"));n||"number"!=typeof t||(n=i.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 o=n?parseFloat(n.getAttribute("cx")):0,l=n?parseFloat(n.getAttribute("cy")):0,c=n?parseFloat(n.getAttribute("barWidth")):0,h=a.getElGrid().getBoundingClientRect(),d=n&&(n.classList.contains("apexcharts-candlestick-area")||n.classList.contains("apexcharts-boxPlot-area"));i.globals.isXNumeric?(n&&!d&&(o-=r%2!=0?c/2:0),n&&d&&i.globals.comboCharts&&(o-=c/2)):i.globals.isBarHorizontal||(o=a.xAxisTicksPositions[e-1]+a.dataPointsDividedWidth/2,isNaN(o)&&(o=a.xAxisTicksPositions[e]-a.dataPointsDividedWidth/2)),i.globals.isBarHorizontal?l-=a.tooltipRect.ttHeight:i.config.tooltip.followCursor?l=a.e.clientY-h.top-a.tooltipRect.ttHeight/2:l+a.tooltipRect.ttHeight+15>i.globals.gridHeight&&(l=i.globals.gridHeight),i.globals.isBarHorizontal||this.moveXCrosshairs(o),a.fixedTooltip||this.moveTooltip(o,l||i.globals.gridHeight)}}],i&&Ft(t.prototype,i),e}();function Nt(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Wt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Bt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ttCtx=t,this.ctx=t.ctx,this.tooltipPosition=new Ht(t)}var t,i;return t=e,i=[{key:"drawDynamicPoints",value:function(){var e,t=this.w,i=new g(this.ctx),a=new ae(this.ctx),r=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series");r=function(e){if(Array.isArray(e))return Nt(e)}(e=r)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Nt(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Nt(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),t.config.chart.stacked&&r.sort((function(e,t){return parseFloat(e.getAttribute("data:realIndex"))-parseFloat(t.getAttribute("data:realIndex"))}));for(var s=0;s<r.length;s++){var n=r[s].querySelector(".apexcharts-series-markers-wrap");if(null!==n){var o=void 0,l="apexcharts-marker w".concat((Math.random()+1).toString(36).substring(4));"line"!==t.config.chart.type&&"area"!==t.config.chart.type||t.globals.comboCharts||t.config.tooltip.intersect||(l+=" no-pointer-events");var c=a.getMarkerConfig({cssClass:l,seriesIndex:Number(n.getAttribute("data:realIndex"))});(o=i.drawMarker(0,0,c)).node.setAttribute("default-marker-size",0);var h=document.createElementNS(t.globals.SVGNS,"g");h.classList.add("apexcharts-series-markers"),h.appendChild(o.node),n.appendChild(h)}}}},{key:"enlargeCurrentPoint",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=this.w;"bubble"!==r.config.chart.type&&this.newPointSize(e,t);var s=t.getAttribute("cx"),n=t.getAttribute("cy");if(null!==i&&null!==a&&(s=i,n=a),this.tooltipPosition.moveXCrosshairs(s),!this.fixedTooltip){if("radar"===r.config.chart.type){var o=this.ttCtx.getElGrid().getBoundingClientRect();s=this.ttCtx.e.clientX-o.left}this.tooltipPosition.moveTooltip(s,n,r.config.markers.hover.size)}}},{key:"enlargePoints",value:function(e){for(var t=this.w,i=this,a=this.ttCtx,r=e,s=t.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),n=t.config.markers.hover.size,o=0;o<s.length;o++){var l=s[o].getAttribute("rel"),c=s[o].getAttribute("index");if(void 0===n&&(n=t.globals.markers.size[c]+t.config.markers.hover.sizeOffset),r===parseInt(l,10)){i.newPointSize(r,s[o]);var h=s[o].getAttribute("cx"),d=s[o].getAttribute("cy");i.tooltipPosition.moveXCrosshairs(h),a.fixedTooltip||i.tooltipPosition.moveTooltip(h,d,n)}else i.oldPointSize(s[o])}}},{key:"newPointSize",value:function(e,t){var i=this.w,a=i.config.markers.hover.size,r=0===e?t.parentNode.firstChild:t.parentNode.lastChild;if("0"!==r.getAttribute("default-marker-size")){var s=parseInt(r.getAttribute("index"),10);void 0===a&&(a=i.globals.markers.size[s]+i.config.markers.hover.sizeOffset),a<0&&(a=0);var n=this.ttCtx.tooltipUtil.getPathFromPoint(t,a);t.setAttribute("d",n)}}},{key:"oldPointSize",value:function(e){var t=parseFloat(e.getAttribute("default-marker-size")),i=this.ttCtx.tooltipUtil.getPathFromPoint(e,t);e.setAttribute("d",i)}},{key:"resetPointsSize",value:function(){for(var e=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),t=0;t<e.length;t++){var i=parseFloat(e[t].getAttribute("default-marker-size"));if(r.isNumber(i)&&i>=0){var a=this.ttCtx.tooltipUtil.getPathFromPoint(e[t],i);e[t].setAttribute("d",a)}else e[t].setAttribute("d","M0,0")}}}],i&&Wt(t.prototype,i),e}();function jt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const Gt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w;var i=this.w;this.ttCtx=t,this.isVerticalGroupedRangeBar=!i.globals.isBarHorizontal&&"rangeBar"===i.config.chart.type&&i.config.plotOptions.bar.rangeBarGroupRows}var t,i;return t=e,(i=[{key:"getAttr",value:function(e,t){return parseFloat(e.target.getAttribute(t))}},{key:"handleHeatTreeTooltip",value:function(e){var t=e.e,i=e.opt,a=e.x,r=e.y,s=e.type,n=this.ttCtx,o=this.w;if(t.target.classList.contains("apexcharts-".concat(s,"-rect"))){var l=this.getAttr(t,"i"),c=this.getAttr(t,"j"),h=this.getAttr(t,"cx"),d=this.getAttr(t,"cy"),u=this.getAttr(t,"width"),g=this.getAttr(t,"height");if(n.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:l,j:c,shared:!1,e:t}),o.globals.capturedSeriesIndex=l,o.globals.capturedDataPointIndex=c,a=h+n.tooltipRect.ttWidth/2+u,r=d+n.tooltipRect.ttHeight/2-g/2,n.tooltipPosition.moveXCrosshairs(h+u/2),a>o.globals.gridWidth/2&&(a=h-n.tooltipRect.ttWidth/2+u),n.w.config.tooltip.followCursor){var f=o.globals.dom.elWrap.getBoundingClientRect();a=o.globals.clientX-f.left-(a>o.globals.gridWidth/2?n.tooltipRect.ttWidth:0),r=o.globals.clientY-f.top-(r>o.globals.gridHeight/2?n.tooltipRect.ttHeight:0)}}return{x:a,y:r}}},{key:"handleMarkerTooltip",value:function(e){var t,i,a=e.e,s=e.opt,n=e.x,o=e.y,l=this.w,c=this.ttCtx;if(a.target.classList.contains("apexcharts-marker")){var h=parseInt(s.paths.getAttribute("cx"),10),d=parseInt(s.paths.getAttribute("cy"),10),u=parseFloat(s.paths.getAttribute("val"));if(i=parseInt(s.paths.getAttribute("rel"),10),t=parseInt(s.paths.parentNode.parentNode.parentNode.getAttribute("rel"),10)-1,c.intersect){var g=r.findAncestor(s.paths,"apexcharts-series");g&&(t=parseInt(g.getAttribute("data:realIndex"),10))}if(c.tooltipLabels.drawSeriesTexts({ttItems:s.ttItems,i:t,j:i,shared:!c.showOnIntersect&&l.config.tooltip.shared,e:a}),"mouseup"===a.type&&c.markerClick(a,t,i),l.globals.capturedSeriesIndex=t,l.globals.capturedDataPointIndex=i,n=h,o=d+l.globals.translateY-1.4*c.tooltipRect.ttHeight,c.w.config.tooltip.followCursor){var f=c.getElGrid().getBoundingClientRect();o=c.e.clientY+l.globals.translateY-f.top}u<0&&(o=d),c.marker.enlargeCurrentPoint(i,s.paths,n,o)}return{x:n,y:o}}},{key:"handleBarTooltip",value:function(e){var t,i,a=e.e,r=e.opt,s=this.w,n=this.ttCtx,o=n.getElTooltip(),l=0,c=0,h=0,d=this.getBarTooltipXY({e:a,opt:r});t=d.i,d.barHeight;var u=d.j;s.globals.capturedSeriesIndex=t,s.globals.capturedDataPointIndex=u,s.globals.isBarHorizontal&&n.tooltipUtil.hasBars()||!s.config.tooltip.shared?(c=d.x,h=d.y,i=Array.isArray(s.config.stroke.width)?s.config.stroke.width[t]:s.config.stroke.width,l=c):s.globals.comboCharts||s.config.tooltip.shared||(l/=2),isNaN(h)&&(h=s.globals.svgHeight-n.tooltipRect.ttHeight);var g=parseInt(r.paths.parentNode.getAttribute("data:realIndex"),10);if(s.globals.isMultipleYAxis?s.config.yaxis[g]&&s.config.yaxis[g].reversed:s.config.yaxis[0].reversed,c+n.tooltipRect.ttWidth>s.globals.gridWidth?c-=n.tooltipRect.ttWidth:c<0&&(c=0),n.w.config.tooltip.followCursor){var f=n.getElGrid().getBoundingClientRect();h=n.e.clientY-f.top}null===n.tooltip&&(n.tooltip=s.globals.dom.baseEl.querySelector(".apexcharts-tooltip")),s.config.tooltip.shared||(s.globals.comboBarCount>0?n.tooltipPosition.moveXCrosshairs(l+i/2):n.tooltipPosition.moveXCrosshairs(l)),!n.fixedTooltip&&(!s.config.tooltip.shared||s.globals.isBarHorizontal&&n.tooltipUtil.hasBars())&&(h=h+s.globals.translateY-n.tooltipRect.ttHeight/2,o.style.left=c+s.globals.translateX+"px",o.style.top=h+"px")}},{key:"getBarTooltipXY",value:function(e){var t=this,i=e.e,a=e.opt,r=this.w,s=null,n=this.ttCtx,o=0,l=0,c=0,h=0,d=0,u=i.target.classList;if(u.contains("apexcharts-bar-area")||u.contains("apexcharts-candlestick-area")||u.contains("apexcharts-boxPlot-area")||u.contains("apexcharts-rangebar-area")){var g=i.target,f=g.getBoundingClientRect(),p=a.elGrid.getBoundingClientRect(),x=f.height;d=f.height;var b=f.width,v=parseInt(g.getAttribute("cx"),10),m=parseInt(g.getAttribute("cy"),10);h=parseFloat(g.getAttribute("barWidth"));var y="touchmove"===i.type?i.touches[0].clientX:i.clientX;s=parseInt(g.getAttribute("j"),10),o=parseInt(g.parentNode.getAttribute("rel"),10)-1;var w=g.getAttribute("data-range-y1"),k=g.getAttribute("data-range-y2");r.globals.comboCharts&&(o=parseInt(g.parentNode.getAttribute("data:realIndex"),10));var A=function(e){return r.globals.isXNumeric?v-b/2:t.isVerticalGroupedRangeBar?v+b/2:v-n.dataPointsDividedWidth+b/2},S=function(){return m-n.dataPointsDividedHeight+x/2-n.tooltipRect.ttHeight/2};n.tooltipLabels.drawSeriesTexts({ttItems:a.ttItems,i:o,j:s,y1:w?parseInt(w,10):null,y2:k?parseInt(k,10):null,shared:!n.showOnIntersect&&r.config.tooltip.shared,e:i}),r.config.tooltip.followCursor?r.globals.isBarHorizontal?(l=y-p.left+15,c=S()):(l=A(),c=i.clientY-p.top-n.tooltipRect.ttHeight/2-15):r.globals.isBarHorizontal?((l=v)<n.xyRatios.baseLineInvertedY&&(l=v-n.tooltipRect.ttWidth),c=S()):(l=A(),c=m)}return{x:l,y:c,barHeight:d,barWidth:h,i:o,j:s}}}])&&jt(t.prototype,i),e}();function Vt(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const _t=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.ttCtx=t}var t,i;return t=e,(i=[{key:"drawXaxisTooltip",value:function(){var e=this.w,t=this.ttCtx,i="bottom"===e.config.xaxis.position;t.xaxisOffY=i?e.globals.gridHeight+1:-e.globals.xAxisHeight-e.config.xaxis.axisTicks.height+3;var a=i?"apexcharts-xaxistooltip apexcharts-xaxistooltip-bottom":"apexcharts-xaxistooltip apexcharts-xaxistooltip-top",r=e.globals.dom.elWrap;t.isXAxisTooltipEnabled&&null===e.globals.dom.baseEl.querySelector(".apexcharts-xaxistooltip")&&(t.xaxisTooltip=document.createElement("div"),t.xaxisTooltip.setAttribute("class",a+" apexcharts-theme-"+e.config.tooltip.theme),r.appendChild(t.xaxisTooltip),t.xaxisTooltipText=document.createElement("div"),t.xaxisTooltipText.classList.add("apexcharts-xaxistooltip-text"),t.xaxisTooltipText.style.fontFamily=e.config.xaxis.tooltip.style.fontFamily||e.config.chart.fontFamily,t.xaxisTooltipText.style.fontSize=e.config.xaxis.tooltip.style.fontSize,t.xaxisTooltip.appendChild(t.xaxisTooltipText))}},{key:"drawYaxisTooltip",value:function(){for(var e=this.w,t=this.ttCtx,i=0;i<e.config.yaxis.length;i++){var a=e.config.yaxis[i].opposite||e.config.yaxis[i].crosshairs.opposite;t.yaxisOffX=a?e.globals.gridWidth+1:1;var r="apexcharts-yaxistooltip apexcharts-yaxistooltip-".concat(i,a?" apexcharts-yaxistooltip-right":" apexcharts-yaxistooltip-left"),s=e.globals.dom.elWrap;null===e.globals.dom.baseEl.querySelector(".apexcharts-yaxistooltip apexcharts-yaxistooltip-".concat(i))&&(t.yaxisTooltip=document.createElement("div"),t.yaxisTooltip.setAttribute("class",r+" apexcharts-theme-"+e.config.tooltip.theme),s.appendChild(t.yaxisTooltip),0===i&&(t.yaxisTooltipText=[]),t.yaxisTooltipText[i]=document.createElement("div"),t.yaxisTooltipText[i].classList.add("apexcharts-yaxistooltip-text"),t.yaxisTooltip.appendChild(t.yaxisTooltipText[i]))}}},{key:"setXCrosshairWidth",value:function(){var e=this.w,t=this.ttCtx,i=t.getElXCrosshairs();if(t.xcrosshairsWidth=parseInt(e.config.xaxis.crosshairs.width,10),e.globals.comboCharts){var a=e.globals.dom.baseEl.querySelector(".apexcharts-bar-area");if(null!==a&&"barWidth"===e.config.xaxis.crosshairs.width){var r=parseFloat(a.getAttribute("barWidth"));t.xcrosshairsWidth=r}else if("tickWidth"===e.config.xaxis.crosshairs.width){var s=e.globals.labels.length;t.xcrosshairsWidth=e.globals.gridWidth/s}}else if("tickWidth"===e.config.xaxis.crosshairs.width){var n=e.globals.labels.length;t.xcrosshairsWidth=e.globals.gridWidth/n}else if("barWidth"===e.config.xaxis.crosshairs.width){var o=e.globals.dom.baseEl.querySelector(".apexcharts-bar-area");if(null!==o){var l=parseFloat(o.getAttribute("barWidth"));t.xcrosshairsWidth=l}else t.xcrosshairsWidth=1}e.globals.isBarHorizontal&&(t.xcrosshairsWidth=0),null!==i&&t.xcrosshairsWidth>0&&i.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,i){var a=this.ttCtx,r=this.w,s=r.globals,n=s.seriesYAxisMap[e];if(a.yaxisTooltips[e]&&n.length>0){var o=s.yLabelFormatters[e],l=a.getElGrid().getBoundingClientRect(),c=n[0],h=0;i.yRatio.length>1&&(h=c);var d=(t-l.top)*i.yRatio[h],u=s.maxYArr[c]-s.minYArr[c],g=s.minYArr[c]+(u-d);r.config.yaxis[e].reversed&&(g=s.maxYArr[c]-(u-d)),a.tooltipPosition.moveYCrosshairs(t-l.top),a.yaxisTooltipText[e].innerHTML=o(g),a.tooltipPosition.moveYAxisTooltip(e)}}}])&&Vt(t.prototype,i),e}();function Ut(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function qt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ut(Object(i),!0).forEach((function(t){Zt(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ut(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Zt(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function $t(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Jt=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.w;this.tConfig=i.config.tooltip,this.tooltipUtil=new Et(this),this.tooltipLabels=new Rt(this),this.tooltipPosition=new Ht(this),this.marker=new Bt(this),this.intersect=new Gt(this),this.axesTooltip=new _t(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=!i.globals.isBarHorizontal&&this.tConfig.shared,this.lastHoverTime=Date.now()}var t,i;return t=e,i=[{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,i){return!!(e.show&&e.tooltip.enabled&&t.globals.axisCharts)})),this.allTooltipSeriesGroups=[],t.globals.axisCharts||(this.showTooltipTitle=!1);var i=document.createElement("div");if(i.classList.add("apexcharts-tooltip"),t.config.tooltip.cssClass&&i.classList.add(t.config.tooltip.cssClass),i.classList.add("apexcharts-theme-".concat(this.tConfig.theme)),t.globals.dom.elWrap.appendChild(i),t.globals.axisCharts){this.axesTooltip.drawXaxisTooltip(),this.axesTooltip.drawYaxisTooltip(),this.axesTooltip.setXCrosshairWidth(),this.axesTooltip.handleYCrosshair();var a=new ve(this.ctx);this.xAxisTicksPositions=a.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,i.appendChild(this.tooltipTitle));var r=t.globals.series.length;(t.globals.xyCharts||t.globals.comboCharts)&&this.tConfig.shared&&(r=this.showOnIntersect?1:t.globals.series.length),this.legendLabels=t.globals.dom.baseEl.querySelectorAll(".apexcharts-legend-text"),this.ttItems=this.createTTElements(r),this.addSVGEvents()}}},{key:"createTTElements",value:function(e){for(var t=this,i=this.w,a=[],r=this.getElTooltip(),s=function(s){var n=document.createElement("div");n.classList.add("apexcharts-tooltip-series-group","apexcharts-tooltip-series-group-".concat(s)),n.style.order=i.config.tooltip.inverseOrder?e-s:s+1;var o=document.createElement("span");o.classList.add("apexcharts-tooltip-marker"),o.style.backgroundColor=i.globals.colors[s],n.appendChild(o);var l=document.createElement("div");l.classList.add("apexcharts-tooltip-text"),l.style.fontFamily=t.tConfig.style.fontFamily||i.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 i=document.createElement("span");i.classList.add("apexcharts-tooltip-text-".concat(e,"-label")),t.appendChild(i);var a=document.createElement("span");a.classList.add("apexcharts-tooltip-text-".concat(e,"-value")),t.appendChild(a),l.appendChild(t)})),n.appendChild(l),r.appendChild(n),a.push(n)},n=0;n<e;n++)s(n);return a}},{key:"addSVGEvents",value:function(){var e=this.w,t=e.config.chart.type,i=this.getElTooltip(),a=!("bar"!==t&&"candlestick"!==t&&"boxPlot"!==t&&"rangeBar"!==t),r="area"===t||"line"===t||"scatter"===t||"bubble"===t||"radar"===t,s=e.globals.dom.Paper.node,n=this.getElGrid();n&&(this.seriesBound=n.getBoundingClientRect());var o,l=[],c=[],h={hoverArea:s,elGrid:n,tooltipEl:i,tooltipY:l,tooltipX:c,ttItems:this.ttItems};if(e.globals.axisCharts&&(r?o=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series[data\\:longestSeries='true'] .apexcharts-marker"):a?o=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-bar-area, .apexcharts-series .apexcharts-candlestick-area, .apexcharts-series .apexcharts-boxPlot-area, .apexcharts-series .apexcharts-rangebar-area"):"heatmap"!==t&&"treemap"!==t||(o=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-heatmap, .apexcharts-series .apexcharts-treemap")),o&&o.length))for(var d=0;d<o.length;d++)l.push(o[d].getAttribute("cy")),c.push(o[d].getAttribute("cx"));if(e.globals.xyCharts&&!this.showOnIntersect||e.globals.comboCharts&&!this.showOnIntersect||a&&this.tooltipUtil.hasBars()&&this.tConfig.shared)this.addPathsEventListeners([s],h);else if(a&&!e.globals.comboCharts||r&&this.showOnIntersect)this.addDatapointEventsListeners(h);else if(!e.globals.axisCharts||"heatmap"===t||"treemap"===t){var u=e.globals.dom.baseEl.querySelectorAll(".apexcharts-series");this.addPathsEventListeners(u,h)}if(this.showOnIntersect){var g=e.globals.dom.baseEl.querySelectorAll(".apexcharts-line-series .apexcharts-marker, .apexcharts-area-series .apexcharts-marker");g.length>0&&this.addPathsEventListeners(g,h),this.tooltipUtil.hasBars()&&!this.tConfig.shared&&this.addDatapointEventsListeners(h)}}},{key:"drawFixedTooltipRect",value:function(){var e=this.w,t=this.getElTooltip(),i=t.getBoundingClientRect(),a=i.width+10,r=i.height+10,s=this.tConfig.fixed.offsetX,n=this.tConfig.fixed.offsetY,o=this.tConfig.fixed.position.toLowerCase();return o.indexOf("right")>-1&&(s=s+e.globals.svgWidth-a+10),o.indexOf("bottom")>-1&&(n=n+e.globals.svgHeight-r-10),t.style.left=s+"px",t.style.top=n+"px",{x:s,y:n,ttWidth:a,ttHeight:r}}},{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 i=this,a=function(a){var r={paths:e[a],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[a].addEventListener(t,i.onSeriesHover.bind(i,r),{capture:!1,passive:!0})}))},r=0;r<e.length;r++)a(r)}},{key:"onSeriesHover",value:function(e,t){var i=this,a=Date.now()-this.lastHoverTime;a>=100?this.seriesHover(e,t):(clearTimeout(this.seriesHoverTimeout),this.seriesHoverTimeout=setTimeout((function(){i.seriesHover(e,t)}),100-a))}},{key:"seriesHover",value:function(e,t){var i=this;this.lastHoverTime=Date.now();var a=[],r=this.w;r.config.chart.group&&(a=this.ctx.getGroupedCharts()),r.globals.axisCharts&&(r.globals.minX===-1/0&&r.globals.maxX===1/0||0===r.globals.dataPoints)||(a.length?a.forEach((function(a){var r=i.getElTooltip(a),s={paths:e.paths,tooltipEl:r,tooltipY:e.tooltipY,tooltipX:e.tooltipX,elGrid:e.elGrid,hoverArea:e.hoverArea,ttItems:a.w.globals.tooltip.ttItems};a.w.globals.minX===i.w.globals.minX&&a.w.globals.maxX===i.w.globals.maxX&&a.w.globals.tooltip.seriesHoverByContext({chartCtx:a,ttCtx:a.w.globals.tooltip,opt:s,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,i=e.ttCtx,a=e.opt,r=e.e,s=t.w,n=this.getElTooltip();n&&(i.tooltipRect={x:0,y:0,ttWidth:n.getBoundingClientRect().width,ttHeight:n.getBoundingClientRect().height},i.e=r,!i.tooltipUtil.hasBars()||s.globals.comboCharts||i.isBarShared||this.tConfig.onDatasetHover.highlightDataSeries&&new ce(t).toggleSeriesOnHover(r,r.target.parentNode),i.fixedTooltip&&i.drawFixedTooltipRect(),s.globals.axisCharts?i.axisChartsTooltips({e:r,opt:a,tooltipRect:i.tooltipRect}):i.nonAxisChartsTooltips({e:r,opt:a,tooltipRect:i.tooltipRect}))}},{key:"axisChartsTooltips",value:function(e){var t,i,a=e.e,r=e.opt,s=this.w,n=r.elGrid.getBoundingClientRect(),o="touchmove"===a.type?a.touches[0].clientX:a.clientX,l="touchmove"===a.type?a.touches[0].clientY:a.clientY;if(this.clientY=l,this.clientX=o,s.globals.capturedSeriesIndex=-1,s.globals.capturedDataPointIndex=-1,l<n.top||l>n.top+n.height)this.handleMouseOut(r);else{if(Array.isArray(this.tConfig.enabledOnSeries)&&!s.config.tooltip.shared){var c=parseInt(r.paths.getAttribute("index"),10);if(this.tConfig.enabledOnSeries.indexOf(c)<0)return void this.handleMouseOut(r)}var h=this.getElTooltip(),d=this.getElXCrosshairs(),u=s.globals.xyCharts||"bar"===s.config.chart.type&&!s.globals.isBarHorizontal&&this.tooltipUtil.hasBars()&&this.tConfig.shared||s.globals.comboCharts&&this.tooltipUtil.hasBars();if("mousemove"===a.type||"touchmove"===a.type||"mouseup"===a.type){if(s.globals.collapsedSeries.length+s.globals.ancillaryCollapsedSeries.length===s.globals.series.length)return;null!==d&&d.classList.add("apexcharts-active");var g=this.yaxisTooltips.filter((function(e){return!0===e}));if(null!==this.ycrosshairs&&g.length&&this.ycrosshairs.classList.add("apexcharts-active"),u&&!this.showOnIntersect)this.handleStickyTooltip(a,o,l,r);else if("heatmap"===s.config.chart.type||"treemap"===s.config.chart.type){var f=this.intersect.handleHeatTreeTooltip({e:a,opt:r,x:t,y:i,type:s.config.chart.type});t=f.x,i=f.y,h.style.left=t+"px",h.style.top=i+"px"}else this.tooltipUtil.hasBars()&&this.intersect.handleBarTooltip({e:a,opt:r}),this.tooltipUtil.hasMarkers()&&this.intersect.handleMarkerTooltip({e:a,opt:r,x:t,y:i});if(this.yaxisTooltips.length)for(var p=0;p<s.config.yaxis.length;p++)this.axesTooltip.drawYaxisTooltipText(p,l,this.xyRatios);s.globals.dom.baseEl.classList.add("apexcharts-tooltip-active"),r.tooltipEl.classList.add("apexcharts-active")}else"mouseout"!==a.type&&"touchend"!==a.type||this.handleMouseOut(r)}}},{key:"nonAxisChartsTooltips",value:function(e){var t=e.e,i=e.opt,a=e.tooltipRect,r=this.w,s=i.paths.getAttribute("rel"),n=this.getElTooltip(),o=r.globals.dom.elWrap.getBoundingClientRect();if("mousemove"===t.type||"touchmove"===t.type){r.globals.dom.baseEl.classList.add("apexcharts-tooltip-active"),n.classList.add("apexcharts-active"),this.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:parseInt(s,10)-1,shared:!1});var l=r.globals.clientX-o.left-a.ttWidth/2,c=r.globals.clientY-o.top-a.ttHeight-10;if(n.style.left=l+"px",n.style.top=c+"px",r.config.legend.tooltipHoverFormatter){var h=s-1,d=(0,r.config.legend.tooltipHoverFormatter)(this.legendLabels[h].getAttribute("data:default-text"),{seriesIndex:h,dataPointIndex:h,w:r});this.legendLabels[h].innerHTML=d}}else"mouseout"!==t.type&&"touchend"!==t.type||(n.classList.remove("apexcharts-active"),r.globals.dom.baseEl.classList.remove("apexcharts-tooltip-active"),r.config.legend.tooltipHoverFormatter&&this.legendLabels.forEach((function(e){var t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(t)})))}},{key:"handleStickyTooltip",value:function(e,t,i,a){var r=this.w,s=this.tooltipUtil.getNearestValues({context:this,hoverArea:a.hoverArea,elGrid:a.elGrid,clientX:t,clientY:i}),n=s.j,o=s.capturedSeries;r.globals.collapsedSeriesIndices.includes(o)&&(o=null);var l=a.elGrid.getBoundingClientRect();if(s.hoverX<0||s.hoverX>l.width)this.handleMouseOut(a);else if(null!==o)this.handleStickyCapturedSeries(e,o,a,n);else if(this.tooltipUtil.isXoverlap(n)||r.globals.isBarHorizontal){var c=r.globals.series.findIndex((function(e,t){return!r.globals.collapsedSeriesIndices.includes(t)}));this.create(e,this,c,n,a.ttItems)}}},{key:"handleStickyCapturedSeries",value:function(e,t,i,a){var r=this.w;if(this.tConfig.shared||null!==r.globals.series[t][a]){if(void 0!==r.globals.series[t][a])this.tConfig.shared&&this.tooltipUtil.isXoverlap(a)&&this.tooltipUtil.isInitialSeriesSameLen()?this.create(e,this,t,a,i.ttItems):this.create(e,this,t,a,i.ttItems,!1);else if(this.tooltipUtil.isXoverlap(a)){var s=r.globals.series.findIndex((function(e,t){return!r.globals.collapsedSeriesIndices.includes(t)}));this.create(e,this,s,a,i.ttItems)}}else this.handleMouseOut(i)}},{key:"deactivateHoverFilter",value:function(){for(var e=this.w,t=new g(this.ctx),i=e.globals.dom.Paper.select(".apexcharts-bar-area"),a=0;a<i.length;a++)t.pathMouseLeave(i[a])}},{key:"handleMouseOut",value:function(e){var t=this.w,i=this.getElXCrosshairs();if(t.globals.dom.baseEl.classList.remove("apexcharts-tooltip-active"),e.tooltipEl.classList.remove("apexcharts-active"),this.deactivateHoverFilter(),"bubble"!==t.config.chart.type&&this.marker.resetPointsSize(),null!==i&&i.classList.remove("apexcharts-active"),null!==this.ycrosshairs&&this.ycrosshairs.classList.remove("apexcharts-active"),this.isXAxisTooltipEnabled&&this.xaxisTooltip.classList.remove("apexcharts-active"),this.yaxisTooltips.length){null===this.yaxisTTEls&&(this.yaxisTTEls=t.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));for(var a=0;a<this.yaxisTTEls.length;a++)this.yaxisTTEls[a].classList.remove("apexcharts-active")}t.config.legend.tooltipHoverFormatter&&this.legendLabels.forEach((function(e){var t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(t)}))}},{key:"markerClick",value:function(e,t,i){var a=this.w;"function"==typeof a.config.chart.events.markerClick&&a.config.chart.events.markerClick(e,this.ctx,{seriesIndex:t,dataPointIndex:i,w:a}),this.ctx.events.fireEvent("markerClick",[e,this.ctx,{seriesIndex:t,dataPointIndex:i,w:a}])}},{key:"create",value:function(e,t,i,a,r){var s,n,o,l,c,h,d,u,f,p,x,b,v,m,y,w,k=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,A=this.w,S=t;"mouseup"===e.type&&this.markerClick(e,i,a),null===k&&(k=this.tConfig.shared);var C=this.tooltipUtil.hasMarkers(i),P=this.tooltipUtil.getElBars();if(A.config.legend.tooltipHoverFormatter){var L=A.config.legend.tooltipHoverFormatter,O=Array.from(this.legendLabels);O.forEach((function(e){var t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(t)}));for(var M=0;M<O.length;M++){var T=O[M],I=parseInt(T.getAttribute("i"),10),E=decodeURIComponent(T.getAttribute("data:default-text")),z=L(E,{seriesIndex:k?I:i,dataPointIndex:a,w:A});if(k)T.innerHTML=A.globals.collapsedSeriesIndices.indexOf(I)<0?z:E;else if(T.innerHTML=I===i?z:E,i===I)break}}var X=qt(qt({ttItems:r,i,j:a},void 0!==(null===(s=A.globals.seriesRange)||void 0===s||null===(n=s[i])||void 0===n||null===(o=n[a])||void 0===o||null===(l=o.y[0])||void 0===l?void 0:l.y1)&&{y1:null===(c=A.globals.seriesRange)||void 0===c||null===(h=c[i])||void 0===h||null===(d=h[a])||void 0===d||null===(u=d.y[0])||void 0===u?void 0:u.y1}),void 0!==(null===(f=A.globals.seriesRange)||void 0===f||null===(p=f[i])||void 0===p||null===(x=p[a])||void 0===x||null===(b=x.y[0])||void 0===b?void 0:b.y2)&&{y2:null===(v=A.globals.seriesRange)||void 0===v||null===(m=v[i])||void 0===m||null===(y=m[a])||void 0===y||null===(w=y.y[0])||void 0===w?void 0:w.y2});if(k){if(S.tooltipLabels.drawSeriesTexts(qt(qt({},X),{},{shared:!this.showOnIntersect&&this.tConfig.shared})),C)A.globals.markers.largestSize>0?S.marker.enlargePoints(a):S.tooltipPosition.moveDynamicPointsOnHover(a);else if(this.tooltipUtil.hasBars()&&(this.barSeriesHeight=this.tooltipUtil.getBarsHeight(P),this.barSeriesHeight>0)){var Y=new g(this.ctx),D=A.globals.dom.Paper.select(".apexcharts-bar-area[j='".concat(a,"']"));this.deactivateHoverFilter(),this.tooltipPosition.moveStickyTooltipOverBars(a,i);for(var R=0;R<D.length;R++)Y.pathMouseEnter(D[R])}}else S.tooltipLabels.drawSeriesTexts(qt({shared:!1},X)),this.tooltipUtil.hasBars()&&S.tooltipPosition.moveStickyTooltipOverBars(a,i),C&&S.tooltipPosition.moveMarkers(i,a)}}],i&&$t(t.prototype,i),e}();function Qt(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Kt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Qt(Object(i),!0).forEach((function(t){ei(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Qt(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ei(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ti(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var ii=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.barCtx=t,this.totalFormatter=this.w.config.plotOptions.bar.dataLabels.total.formatter,this.totalFormatter||(this.totalFormatter=this.w.config.dataLabels.formatter)}var t,i;return t=e,(i=[{key:"handleBarDataLabels",value:function(e){var t,i,a=e.x,r=e.y,s=e.y1,n=e.y2,o=e.i,l=e.j,c=e.realIndex,h=e.columnGroupIndex,d=e.series,u=e.barHeight,f=e.barWidth,p=e.barXPosition,x=e.barYPosition,b=e.visibleSeries,v=e.renderedPath,m=this.w,y=new g(this.barCtx.ctx),w=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[c]:this.barCtx.strokeWidth;m.globals.isXNumeric&&!m.globals.isBarHorizontal?(t=a+parseFloat(f*(b+1)),i=r+parseFloat(u*(b+1))-w):(t=a+parseFloat(f*b),i=r+parseFloat(u*b));var k,A,S=null,C=a,P=r,L=m.config.dataLabels,O=this.barCtx.barOptions.dataLabels,M=this.barCtx.barOptions.dataLabels.total;void 0!==x&&this.barCtx.isRangeBar&&(i=x,P=x),void 0!==p&&this.barCtx.isVerticalGroupedRangeBar&&(t=p,C=p);var T=L.offsetX,I=L.offsetY,E={width:0,height:0};if(m.config.dataLabels.enabled){var z=m.globals.series[o][l];E=y.getTextRects(m.globals.yLabelFormatters[0](z),parseFloat(L.style.fontSize))}var X={x:a,y:r,i:o,j:l,realIndex:c,columnGroupIndex:h,renderedPath:v,bcx:t,bcy:i,barHeight:u,barWidth:f,textRects:E,strokeWidth:w,dataLabelsX:C,dataLabelsY:P,dataLabelsConfig:L,barDataLabelsConfig:O,barTotalDataLabelsConfig:M,offX:T,offY:I};return A=this.barCtx.isHorizontal?this.calculateBarsDataLabelsPosition(X):this.calculateColumnsDataLabelsPosition(X),v.attr({cy:A.bcy,cx:A.bcx,j:l,val:m.globals.series[o][l],barHeight:u,barWidth:f}),k=this.drawCalculatedDataLabels({x:A.dataLabelsX,y:A.dataLabelsY,val:this.barCtx.isRangeBar?[s,n]:"100%"===m.config.chart.stackType?d[o][l]:m.globals.series[o][l],i:c,j:l,barWidth:f,barHeight:u,textRects:E,dataLabelsConfig:L}),m.config.chart.stacked&&M.enabled&&(S=this.drawTotalDataLabels({x:A.totalDataLabelsX,y:A.totalDataLabelsY,barWidth:f,barHeight:u,realIndex:c,textAnchor:A.totalDataLabelsAnchor,val:this.getStackedTotalDataLabel({realIndex:c,j:l}),dataLabelsConfig:L,barTotalDataLabelsConfig:M})),{dataLabels:k,totalDataLabels:S}}},{key:"getStackedTotalDataLabel",value:function(e){var t=e.realIndex,i=e.j,a=this.w,r=this.barCtx.stackedSeriesTotals[i];return this.totalFormatter&&(r=this.totalFormatter(r,Kt(Kt({},a),{},{seriesIndex:t,dataPointIndex:i,w:a}))),r}},{key:"calculateColumnsDataLabelsPosition",value:function(e){var t,i,a=this.w,r=e.i,s=e.j,n=e.realIndex,o=(e.columnGroupIndex,e.y),l=e.bcx,c=e.barWidth,h=e.barHeight,d=e.textRects,u=e.dataLabelsX,f=e.dataLabelsY,p=e.dataLabelsConfig,x=e.barDataLabelsConfig,b=e.barTotalDataLabelsConfig,v=e.strokeWidth,m=e.offX,y=e.offY,w=l;h=Math.abs(h);var k="vertical"===a.config.plotOptions.bar.dataLabels.orientation,A=this.barCtx.barHelpers.getZeroValueEncounters({i:r,j:s}).zeroEncounters;l-=v/2;var S=a.globals.gridWidth/a.globals.dataPoints;this.barCtx.isVerticalGroupedRangeBar?u+=c/2:(u=a.globals.isXNumeric?l-c/2+m:l-S+c/2+m,A>0&&a.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(u-=c*A)),k&&(u=u+d.height/2-v/2-2);var C=a.globals.series[r][s]<0,P=o;switch(this.barCtx.isReversed&&(P=o+(C?h:-h)),x.position){case"center":f=k?C?P-h/2+y:P+h/2-y:C?P-h/2+d.height/2+y:P+h/2+d.height/2-y;break;case"bottom":f=k?C?P-h+y:P+h-y:C?P-h+d.height+v+y:P+h-d.height/2+v-y;break;case"top":f=k?C?P+y:P-y:C?P-d.height/2-y:P+d.height+y}if(this.barCtx.lastActiveBarSerieIndex===n&&b.enabled){var L=new g(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:n,j:s}),p.fontSize);t=C?P-L.height/2-y-b.offsetY+18:P+L.height+y+b.offsetY-18;var O=S;i=w+(a.globals.isXNumeric?-c*a.globals.barGroups.length/2:a.globals.barGroups.length*c/2-(a.globals.barGroups.length-1)*c-O)+b.offsetX}return a.config.chart.stacked||(f<0?f=0+v:f+d.height/3>a.globals.gridHeight&&(f=a.globals.gridHeight-v)),{bcx:l,bcy:o,dataLabelsX:u,dataLabelsY:f,totalDataLabelsX:i,totalDataLabelsY:t,totalDataLabelsAnchor:"middle"}}},{key:"calculateBarsDataLabelsPosition",value:function(e){var t=this.w,i=e.x,a=e.i,r=e.j,s=e.realIndex,n=(e.columnGroupIndex,e.bcy),o=e.barHeight,l=e.barWidth,c=e.textRects,h=e.dataLabelsX,d=e.strokeWidth,u=e.dataLabelsConfig,f=e.barDataLabelsConfig,p=e.barTotalDataLabelsConfig,x=e.offX,b=e.offY,v=t.globals.gridHeight/t.globals.dataPoints;l=Math.abs(l);var m,y,w=n-(this.barCtx.isRangeBar?0:v)+o/2+c.height/2+b-3,k="start",A=t.globals.series[a][r]<0,S=i;switch(this.barCtx.isReversed&&(S=i+(A?-l:l),k=A?"start":"end"),f.position){case"center":h=A?S+l/2-x:Math.max(c.width/2,S-l/2)+x;break;case"bottom":h=A?S+l-d-Math.round(c.width/2)-x:S-l+d+Math.round(c.width/2)+x;break;case"top":h=A?S-d+Math.round(c.width/2)-x:S-d-Math.round(c.width/2)+x}if(this.barCtx.lastActiveBarSerieIndex===s&&p.enabled){var C=new g(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:s,j:r}),u.fontSize);A?(m=S-d-x-p.offsetX,k="end"):m=S+x+p.offsetX+(this.barCtx.isReversed?-(l+d):d),y=w-c.height/2+C.height/2+p.offsetY+d}return t.config.chart.stacked||(h<0?h=h+c.width+d:h+c.width/2>t.globals.gridWidth&&(h=t.globals.gridWidth-c.width-d)),{bcx:i,bcy:n,dataLabelsX:h,dataLabelsY:w,totalDataLabelsX:m,totalDataLabelsY:y,totalDataLabelsAnchor:k}}},{key:"drawCalculatedDataLabels",value:function(e){var t=e.x,i=e.y,a=e.val,r=e.i,s=e.j,n=e.textRects,o=e.barHeight,l=e.barWidth,c=e.dataLabelsConfig,h=this.w,d="rotate(0)";"vertical"===h.config.plotOptions.bar.dataLabels.orientation&&(d="rotate(-90, ".concat(t,", ").concat(i,")"));var u=new oe(this.barCtx.ctx),f=new g(this.barCtx.ctx),p=c.formatter,x=null,b=h.globals.collapsedSeriesIndices.indexOf(r)>-1;if(c.enabled&&!b){x=f.group({class:"apexcharts-data-labels",transform:d});var v="";void 0!==a&&(v=p(a,Kt(Kt({},h),{},{seriesIndex:r,dataPointIndex:s,w:h}))),!a&&h.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(v="");var m=h.globals.series[r][s]<0,y=h.config.plotOptions.bar.dataLabels.position;"vertical"===h.config.plotOptions.bar.dataLabels.orientation&&("top"===y&&(c.textAnchor=m?"end":"start"),"center"===y&&(c.textAnchor="middle"),"bottom"===y&&(c.textAnchor=m?"end":"start")),this.barCtx.isRangeBar&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&l<f.getTextRects(v,parseFloat(c.style.fontSize)).width&&(v=""),h.config.chart.stacked&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&(this.barCtx.isHorizontal?n.width/1.6>Math.abs(l)&&(v=""):n.height/1.6>Math.abs(o)&&(v=""));var w=Kt({},c);this.barCtx.isHorizontal&&a<0&&("start"===c.textAnchor?w.textAnchor="end":"end"===c.textAnchor&&(w.textAnchor="start")),u.plotDataLabelsText({x:t,y:i,text:v,i:r,j:s,parent:x,dataLabelsConfig:w,alwaysDrawDataLabel:!0,offsetCorrection:!0})}return x}},{key:"drawTotalDataLabels",value:function(e){var t,i=e.x,a=e.y,r=e.val,s=(e.barWidth,e.barHeight,e.realIndex),n=e.textAnchor,o=e.barTotalDataLabelsConfig,l=(this.w,new g(this.barCtx.ctx));return o.enabled&&void 0!==i&&void 0!==a&&this.barCtx.lastActiveBarSerieIndex===s&&(t=l.drawText({x:i,y:a,foreColor:o.style.color,text:r,textAnchor:n,fontFamily:o.style.fontFamily,fontSize:o.style.fontSize,fontWeight:o.style.fontWeight})),t}}])&&ti(t.prototype,i),e}();function ai(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ri(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ai(Object(i),!0).forEach((function(t){si(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ai(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function si(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ni(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var oi=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.barCtx=t}var t,i;return t=e,i=[{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 i=0;i<e.length;i++)if(e[i].length>0&&(this.barCtx.seriesLen=this.barCtx.seriesLen+1,this.barCtx.totalItems+=e[i].length),t.globals.isXNumeric)for(var a=0;a<e[i].length;a++)t.globals.seriesX[i][a]>t.globals.minX&&t.globals.seriesX[i][a]<t.globals.maxX&&this.barCtx.visibleItems++;else this.barCtx.visibleItems=t.globals.dataPoints;0===this.barCtx.seriesLen&&(this.barCtx.seriesLen=1),this.barCtx.zeroSerieses=[],t.globals.comboCharts||this.checkZeroSeries({series:e})}},{key:"initialPositions",value:function(){var e,t,i,a,r,s,n,o,l=this.w,c=l.globals.dataPoints;this.barCtx.isRangeBar&&(c=l.globals.labels.length);var h=this.barCtx.seriesLen;if(l.config.plotOptions.bar.rangeBarGroupRows&&(h=1),this.barCtx.isHorizontal)r=(i=l.globals.gridHeight/c)/h,l.globals.isXNumeric&&(r=(i=l.globals.gridHeight/this.barCtx.totalItems)/this.barCtx.seriesLen),r=r*parseInt(this.barCtx.barOptions.barHeight,10)/100,-1===String(this.barCtx.barOptions.barHeight).indexOf("%")&&(r=parseInt(this.barCtx.barOptions.barHeight,10)),o=this.barCtx.baseLineInvertedY+l.globals.padHorizontal+(this.barCtx.isReversed?l.globals.gridWidth:0)-(this.barCtx.isReversed?2*this.barCtx.baseLineInvertedY:0),this.barCtx.isFunnel&&(o=l.globals.gridWidth/2),t=(i-r*this.barCtx.seriesLen)/2;else{if(a=l.globals.gridWidth/this.barCtx.visibleItems,l.config.xaxis.convertedCatToNumeric&&(a=l.globals.gridWidth/l.globals.dataPoints),s=a/h*parseInt(this.barCtx.barOptions.columnWidth,10)/100,l.globals.isXNumeric){var d=this.barCtx.xRatio;l.globals.minXDiff&&.5!==l.globals.minXDiff&&l.globals.minXDiff/d>0&&(a=l.globals.minXDiff/d),(s=a/h*parseInt(this.barCtx.barOptions.columnWidth,10)/100)<1&&(s=1)}-1===String(this.barCtx.barOptions.columnWidth).indexOf("%")&&(s=parseInt(this.barCtx.barOptions.columnWidth,10)),n=l.globals.gridHeight-this.barCtx.baseLineY[this.barCtx.translationsIndex]-(this.barCtx.isReversed?l.globals.gridHeight:0)+(this.barCtx.isReversed?2*this.barCtx.baseLineY[this.barCtx.translationsIndex]:0),e=l.globals.padHorizontal+(a-s*this.barCtx.seriesLen)/2}return l.globals.barHeight=r,l.globals.barWidth=s,{x:e,y:t,yDivision:i,xDivision:a,barHeight:r,barWidth:s,zeroH:n,zeroW:o}}},{key:"initializeStackedPrevVars",value:function(e){e.w.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=[]}))}},{key:"initializeStackedXYVars",value:function(e){e.w.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=[]}))}},{key:"getPathFillColor",value:function(e,t,i,a){var r,s,n,o,l,c=this.w,h=new te(this.barCtx.ctx),d=null,u=this.barCtx.barOptions.distributed?i:t;return this.barCtx.barOptions.colors.ranges.length>0&&this.barCtx.barOptions.colors.ranges.map((function(a){e[t][i]>=a.from&&e[t][i]<=a.to&&(d=a.color)})),null!==(r=c.config.series[t].data[i])&&void 0!==r&&r.fillColor&&(d=c.config.series[t].data[i].fillColor),h.fillPath({seriesNumber:this.barCtx.barOptions.distributed?u:a,dataPointIndex:i,color:d,value:e[t][i],fillConfig:null===(s=c.config.series[t].data[i])||void 0===s?void 0:s.fill,fillType:null!==(n=c.config.series[t].data[i])&&void 0!==n&&null!==(o=n.fill)&&void 0!==o&&o.type?null===(l=c.config.series[t].data[i])||void 0===l?void 0:l.fill.type:Array.isArray(c.config.fill.type)?c.config.fill.type[a]:c.config.fill.type})}},{key:"getStrokeWidth",value:function(e,t,i){var a=0,r=this.w;return void 0===this.barCtx.series[e][t]||null===this.barCtx.series[e][t]?this.barCtx.isNullValue=!0:this.barCtx.isNullValue=!1,r.config.stroke.show&&(this.barCtx.isNullValue||(a=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[i]:this.barCtx.strokeWidth)),a}},{key:"shouldApplyRadius",value:function(e){var t=this.w,i=!1;return t.config.plotOptions.bar.borderRadius>0&&(t.config.chart.stacked&&"last"===t.config.plotOptions.bar.borderRadiusWhenStacked?this.barCtx.lastActiveBarSerieIndex===e&&(i=!0):i=!0),i}},{key:"barBackground",value:function(e){var t=e.j,i=e.i,a=e.x1,r=e.x2,s=e.y1,n=e.y2,o=e.elSeries,l=this.w,c=new g(this.barCtx.ctx),h=new ce(this.barCtx.ctx).getActiveConfigSeriesIndex();if(this.barCtx.barOptions.colors.backgroundBarColors.length>0&&h===i){t>=this.barCtx.barOptions.colors.backgroundBarColors.length&&(t%=this.barCtx.barOptions.colors.backgroundBarColors.length);var d=this.barCtx.barOptions.colors.backgroundBarColors[t],u=c.drawRect(void 0!==a?a:0,void 0!==s?s:0,void 0!==r?r:l.globals.gridWidth,void 0!==n?n:l.globals.gridHeight,this.barCtx.barOptions.colors.backgroundBarRadius,d,this.barCtx.barOptions.colors.backgroundBarOpacity);o.add(u),u.node.classList.add("apexcharts-backgroundBar")}}},{key:"getColumnPaths",value:function(e){var t,i=e.barWidth,a=e.barXPosition,r=e.y1,s=e.y2,n=e.strokeWidth,o=e.seriesGroup,l=e.realIndex,c=e.i,h=e.j,d=e.w,u=new g(this.barCtx.ctx);(n=Array.isArray(n)?n[l]:n)||(n=0);var f=i,p=a;null!==(t=d.config.series[l].data[h])&&void 0!==t&&t.columnWidthOffset&&(p=a-d.config.series[l].data[h].columnWidthOffset/2,f=i+d.config.series[l].data[h].columnWidthOffset);var x=n/2,b=p+x,v=p+f-x;r+=.001-x,s+=.001+x;var m=u.move(b,r),y=u.move(b,r),w=u.line(v,r);if(d.globals.previousPaths.length>0&&(y=this.barCtx.getPreviousPath(l,h,!1)),m=m+u.line(b,s)+u.line(v,s)+u.line(v,r)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),y=y+u.line(b,r)+w+w+w+w+w+u.line(b,r)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(l)&&(m=u.roundPathCorners(m,d.config.plotOptions.bar.borderRadius)),d.config.chart.stacked){var k=this.barCtx;(k=this.barCtx[o]).yArrj.push(s-x),k.yArrjF.push(Math.abs(r-s+n)),k.yArrjVal.push(this.barCtx.series[c][h])}return{pathTo:m,pathFrom:y}}},{key:"getBarpaths",value:function(e){var t,i=e.barYPosition,a=e.barHeight,r=e.x1,s=e.x2,n=e.strokeWidth,o=e.seriesGroup,l=e.realIndex,c=e.i,h=e.j,d=e.w,u=new g(this.barCtx.ctx);(n=Array.isArray(n)?n[l]:n)||(n=0);var f=i,p=a;null!==(t=d.config.series[l].data[h])&&void 0!==t&&t.barHeightOffset&&(f=i-d.config.series[l].data[h].barHeightOffset/2,p=a+d.config.series[l].data[h].barHeightOffset);var x=n/2,b=f+x,v=f+p-x;r+=.001-x,s+=.001+x;var m=u.move(r,b),y=u.move(r,b);d.globals.previousPaths.length>0&&(y=this.barCtx.getPreviousPath(l,h,!1));var w=u.line(r,v);if(m=m+u.line(s,b)+u.line(s,v)+w+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),y=y+u.line(r,b)+w+w+w+w+w+u.line(r,b)+("around"===d.config.plotOptions.bar.borderRadiusApplication?" Z":" z"),this.shouldApplyRadius(l)&&(m=u.roundPathCorners(m,d.config.plotOptions.bar.borderRadius)),d.config.chart.stacked){var k=this.barCtx;(k=this.barCtx[o]).xArrj.push(s+x),k.xArrjF.push(Math.abs(r-s)),k.xArrjVal.push(this.barCtx.series[c][h])}return{pathTo:m,pathFrom:y}}},{key:"checkZeroSeries",value:function(e){for(var t=e.series,i=this.w,a=0;a<t.length;a++){for(var r=0,s=0;s<t[i.globals.maxValsInArrayIndex].length;s++)r+=t[a][s];0===r&&this.barCtx.zeroSerieses.push(a)}}},{key:"getXForValue",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&!arguments[2]?null:t;return null!=e&&(i=t+e/this.barCtx.invertedYRatio-2*(this.barCtx.isReversed?e/this.barCtx.invertedYRatio:0)),i}},{key:"getYForValue",value:function(e,t,i){var a=arguments.length>3&&void 0!==arguments[3]&&!arguments[3]?null:t;return null!=e&&(a=t-e/this.barCtx.yRatio[i]+2*(this.barCtx.isReversed?e/this.barCtx.yRatio[i]:0)),a}},{key:"getGoalValues",value:function(e,t,i,a,r,s){var n=this,o=this.w,l=[],c=function(a,r){var o;l.push((si(o={},e,"x"===e?n.getXForValue(a,t,!1):n.getYForValue(a,i,s,!1)),si(o,"attrs",r),o))};if(o.globals.seriesGoals[a]&&o.globals.seriesGoals[a][r]&&Array.isArray(o.globals.seriesGoals[a][r])&&o.globals.seriesGoals[a][r].forEach((function(e){c(e.value,e)})),this.barCtx.barOptions.isDumbbell&&o.globals.seriesRange.length){var h=this.barCtx.barOptions.dumbbellColors?this.barCtx.barOptions.dumbbellColors:o.globals.colors,d={strokeHeight:"x"===e?0:o.globals.markers.size[a],strokeWidth:"x"===e?o.globals.markers.size[a]:0,strokeDashArray:0,strokeLineCap:"round",strokeColor:Array.isArray(h[a])?h[a][0]:h[a]};c(o.globals.seriesRangeStart[a][r],d),c(o.globals.seriesRangeEnd[a][r],ri(ri({},d),{},{strokeColor:Array.isArray(h[a])?h[a][1]:h[a]}))}return l}},{key:"drawGoalLine",value:function(e){var t=e.barXPosition,i=e.barYPosition,a=e.goalX,r=e.goalY,s=e.barWidth,n=e.barHeight,o=new g(this.barCtx.ctx),l=o.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(a)&&a.forEach((function(e){if(e.x>=-1&&e.x<=o.w.globals.gridWidth+1){var t=void 0!==e.attrs.strokeHeight?e.attrs.strokeHeight:n/2,a=i+t+n/2;c=o.drawLine(e.x,a-2*t,e.x,a,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(r)&&r.forEach((function(e){if(e.y>=-1&&e.y<=o.w.globals.gridHeight+1){var i=void 0!==e.attrs.strokeWidth?e.attrs.strokeWidth:s/2,a=t+i+s/2;c=o.drawLine(a-2*i,e.y,a,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,i=e.currPaths,a=e.color,s=this.w,n=t.x,o=t.x1,l=t.barYPosition,c=i.x,h=i.x1,d=i.barYPosition,u=l+i.barHeight,f=new g(this.barCtx.ctx),p=new r,x=f.move(o,u)+f.line(n,u)+f.line(c,d)+f.line(h,d)+f.line(o,u)+("around"===s.config.plotOptions.bar.borderRadiusApplication?" Z":" z");return f.drawPath({d:x,fill:p.shadeColor(.5,r.rgb2hex(a)),stroke:"none",strokeWidth:0,fillOpacity:1,classes:"apexcharts-bar-shadows"})}},{key:"getZeroValueEncounters",value:function(e){var t,i=e.i,a=e.j,r=this.w,s=0,n=0;return(r.config.plotOptions.bar.horizontal?r.globals.series.map((function(e,t){return t})):(null===(t=r.globals.columnSeries)||void 0===t?void 0:t.i.map((function(e){return e})))||[]).forEach((function(e){var t=r.globals.seriesPercent[e][a];t&&s++,e<i&&0===t&&n++})),{nonZeroColumns:s,zeroEncounters:n}}},{key:"getGroupIndex",value:function(e){var t=this.w,i=t.globals.seriesGroups.findIndex((function(i){return i.indexOf(t.globals.seriesNames[e])>-1})),a=this.barCtx.columnGroupIndices,r=a.indexOf(i);return r<0&&(a.push(i),r=a.length-1),{groupIndex:i,columnGroupIndex:r}}}],i&&ni(t.prototype,i),e}();function li(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ci(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?li(Object(i),!0).forEach((function(t){hi(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):li(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function hi(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function di(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ui=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var a=this.w;this.barOptions=a.config.plotOptions.bar,this.isHorizontal=this.barOptions.horizontal,this.strokeWidth=a.config.stroke.width,this.isNullValue=!1,this.isRangeBar=a.globals.seriesRange.length&&this.isHorizontal,this.isVerticalGroupedRangeBar=!a.globals.isBarHorizontal&&a.globals.seriesRange.length&&a.config.plotOptions.bar.rangeBarGroupRows,this.isFunnel=this.barOptions.isFunnel,this.xyRatios=i,null!==this.xyRatios&&(this.xRatio=i.xRatio,this.yRatio=i.yRatio,this.invertedXRatio=i.invertedXRatio,this.invertedYRatio=i.invertedYRatio,this.baseLineY=i.baseLineY,this.baseLineInvertedY=i.baseLineInvertedY),this.yaxisIndex=0,this.translationsIndex=0,this.seriesLen=0,this.pathArr=[];var r=new ce(this.ctx);this.lastActiveBarSerieIndex=r.getActiveConfigSeriesIndex("desc",["bar","column"]),this.columnGroupIndices=[];var s=r.getBarSeriesIndices(),n=new p(this.ctx);this.stackedSeriesTotals=n.getStackedSeriesTotals(this.w.config.series.map((function(e,t){return-1===s.indexOf(t)?t:-1})).filter((function(e){return-1!==e}))),this.barHelpers=new oi(this)}var t,i;return t=e,(i=[{key:"draw",value:function(e,t){var i=this.w,a=new g(this.ctx),s=new p(this.ctx,i);e=s.getLogSeries(e),this.series=e,this.yRatio=s.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e);var n=a.group({class:"apexcharts-bar-series apexcharts-plot-series"});i.config.dataLabels.enabled&&this.totalItems>this.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 o=0,l=0;o<e.length;o++,l++){var c,h,d,u,f=void 0,x=void 0,b=[],v=[],m=i.globals.comboCharts?t[o]:o,y=this.barHelpers.getGroupIndex(m).columnGroupIndex,w=a.group({class:"apexcharts-series",rel:o+1,seriesName:r.escapeString(i.globals.seriesNames[m]),"data:realIndex":m});this.ctx.series.addCollapsedClassToSeries(w,m),e[o].length>0&&(this.visibleI=this.visibleI+1);var k=0,A=0;this.yRatio.length>1&&(this.yaxisIndex=i.globals.seriesYAxisReverseMap[m],this.translationsIndex=m);var S=this.translationsIndex;this.isReversed=i.config.yaxis[this.yaxisIndex]&&i.config.yaxis[this.yaxisIndex].reversed;var C=this.barHelpers.initialPositions();x=C.y,k=C.barHeight,h=C.yDivision,u=C.zeroW,f=C.x,A=C.barWidth,c=C.xDivision,d=C.zeroH,this.horizontal||v.push(f+A/2);var P=a.group({class:"apexcharts-datalabels","data:realIndex":m});i.globals.delayedElements.push({el:P.node}),P.node.classList.add("apexcharts-element-hidden");var L=a.group({class:"apexcharts-bar-goals-markers"}),O=a.group({class:"apexcharts-bar-shadows"});i.globals.delayedElements.push({el:O.node}),O.node.classList.add("apexcharts-element-hidden");for(var M=0;M<e[o].length;M++){var T=this.barHelpers.getStrokeWidth(o,M,m),I=null,E={indexes:{i:o,j:M,realIndex:m,translationsIndex:S,bc:l},x:f,y:x,strokeWidth:T,elSeries:w};this.isHorizontal?(I=this.drawBarPaths(ci(ci({},E),{},{barHeight:k,zeroW:u,yDivision:h})),A=this.series[o][M]/this.invertedYRatio):(I=this.drawColumnPaths(ci(ci({},E),{},{xDivision:c,barWidth:A,zeroH:d})),k=this.series[o][M]/this.yRatio[S]);var z=this.barHelpers.getPathFillColor(e,o,M,m);if(this.isFunnel&&this.barOptions.isFunnel3d&&this.pathArr.length&&M>0){var X=this.barHelpers.drawBarShadow({color:"string"==typeof z&&-1===(null==z?void 0:z.indexOf("url"))?z:r.hexToRgba(i.globals.colors[o]),prevPaths:this.pathArr[this.pathArr.length-1],currPaths:I});X&&O.add(X)}this.pathArr.push(I);var Y=this.barHelpers.drawGoalLine({barXPosition:I.barXPosition,barYPosition:I.barYPosition,goalX:I.goalX,goalY:I.goalY,barHeight:k,barWidth:A});Y&&L.add(Y),x=I.y,f=I.x,M>0&&v.push(f+A/2),b.push(x),this.renderSeries({realIndex:m,pathFill:z,j:M,i:o,columnGroupIndex:y,pathFrom:I.pathFrom,pathTo:I.pathTo,strokeWidth:T,elSeries:w,x:f,y:x,series:e,barHeight:Math.abs(I.barHeight?I.barHeight:k),barWidth:Math.abs(I.barWidth?I.barWidth:A),elDataLabelsWrap:P,elGoalsMarkers:L,elBarShadows:O,visibleSeries:this.visibleI,type:"bar"})}i.globals.seriesXvalues[m]=v,i.globals.seriesYvalues[m]=b,n.add(w)}return n}},{key:"renderSeries",value:function(e){var t=e.realIndex,i=e.pathFill,a=e.lineFill,r=e.j,s=e.i,n=e.columnGroupIndex,o=e.pathFrom,c=e.pathTo,h=e.strokeWidth,d=e.elSeries,u=e.x,f=e.y,p=e.y1,x=e.y2,b=e.series,v=e.barHeight,m=e.barWidth,y=e.barXPosition,w=e.barYPosition,k=e.elDataLabelsWrap,A=e.elGoalsMarkers,S=e.elBarShadows,C=e.visibleSeries,P=e.type,L=this.w,O=new g(this.ctx);if(!a){var M="function"==typeof L.globals.stroke.colors[t]?function(e){var t,i=L.config.stroke.colors;return Array.isArray(i)&&i.length>0&&((t=i[e])||(t=""),"function"==typeof t)?t({value:L.globals.series[e][r],dataPointIndex:r,w:L}):t}(t):L.globals.stroke.colors[t];a=this.barOptions.distributed?L.globals.stroke.colors[r]:M}L.config.series[s].data[r]&&L.config.series[s].data[r].strokeColor&&(a=L.config.series[s].data[r].strokeColor),this.isNullValue&&(i="none");var T=r/L.config.chart.animations.animateGradually.delay*(L.config.chart.animations.speed/L.globals.dataPoints)/2.4,I=O.renderPaths({i:s,j:r,realIndex:t,pathFrom:o,pathTo:c,stroke:a,strokeWidth:h,strokeLineCap:L.config.stroke.lineCap,fill:i,animationDelay:T,initialSpeed:L.config.chart.animations.speed,dataChangeSpeed:L.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(P,"-area")});I.attr("clip-path","url(#gridRectMask".concat(L.globals.cuid,")"));var E=L.config.forecastDataPoints;E.count>0&&r>=L.globals.dataPoints-E.count&&(I.node.setAttribute("stroke-dasharray",E.dashArray),I.node.setAttribute("stroke-width",E.strokeWidth),I.node.setAttribute("fill-opacity",E.fillOpacity)),void 0!==p&&void 0!==x&&(I.attr("data-range-y1",p),I.attr("data-range-y2",x)),new l(this.ctx).setSelectionFilter(I,t,r),d.add(I);var z=new ii(this).handleBarDataLabels({x:u,y:f,y1:p,y2:x,i:s,j:r,series:b,realIndex:t,columnGroupIndex:n,barHeight:v,barWidth:m,barXPosition:y,barYPosition:w,renderedPath:I,visibleSeries:C});return null!==z.dataLabels&&k.add(z.dataLabels),z.totalDataLabels&&k.add(z.totalDataLabels),d.add(k),A&&d.add(A),S&&d.add(S),d}},{key:"drawBarPaths",value:function(e){var t,i=e.indexes,a=e.barHeight,r=e.strokeWidth,s=e.zeroW,n=e.x,o=e.y,l=e.yDivision,c=e.elSeries,h=this.w,d=i.i,u=i.j;if(h.globals.isXNumeric)t=(o=(h.globals.seriesX[d][u]-h.globals.minX)/this.invertedXRatio-a)+a*this.visibleI;else if(h.config.plotOptions.bar.hideZeroBarsWhenGrouped){var g=0,f=0;h.globals.seriesPercent.forEach((function(e,t){e[u]&&g++,t<d&&0===e[u]&&f++})),g>0&&(a=this.seriesLen*a/g),t=o+a*this.visibleI,t-=a*f}else t=o+a*this.visibleI;this.isFunnel&&(s-=(this.barHelpers.getXForValue(this.series[d][u],s)-s)/2),n=this.barHelpers.getXForValue(this.series[d][u],s);var p=this.barHelpers.getBarpaths({barYPosition:t,barHeight:a,x1:s,x2:n,strokeWidth:r,series:this.series,realIndex:i.realIndex,i:d,j:u,w:h});return h.globals.isXNumeric||(o+=l),this.barHelpers.barBackground({j:u,i:d,y1:t-a*this.visibleI,y2:a*this.seriesLen,elSeries:c}),{pathTo:p.pathTo,pathFrom:p.pathFrom,x1:s,x:n,y:o,goalX:this.barHelpers.getGoalValues("x",s,null,d,u),barYPosition:t,barHeight:a}}},{key:"drawColumnPaths",value:function(e){var t,i=e.indexes,a=e.x,r=e.y,s=e.xDivision,n=e.barWidth,o=e.zeroH,l=e.strokeWidth,c=e.elSeries,h=this.w,d=i.realIndex,u=i.translationsIndex,g=i.i,f=i.j,p=i.bc;if(h.globals.isXNumeric){var x=this.getBarXForNumericXAxis({x:a,j:f,realIndex:d,barWidth:n});a=x.x,t=x.barXPosition}else if(h.config.plotOptions.bar.hideZeroBarsWhenGrouped){var b=this.barHelpers.getZeroValueEncounters({i:g,j:f}),v=b.nonZeroColumns,m=b.zeroEncounters;v>0&&(n=this.seriesLen*n/v),t=a+n*this.visibleI,t-=n*m}else t=a+n*this.visibleI;r=this.barHelpers.getYForValue(this.series[g][f],o,u);var y=this.barHelpers.getColumnPaths({barXPosition:t,barWidth:n,y1:o,y2:r,strokeWidth:l,series:this.series,realIndex:d,i:g,j:f,w:h});return h.globals.isXNumeric||(a+=s),this.barHelpers.barBackground({bc:p,j:f,i:g,x1:t-l/2-n*this.visibleI,x2:n*this.seriesLen+l/2,elSeries:c}),{pathTo:y.pathTo,pathFrom:y.pathFrom,x:a,y:r,goalY:this.barHelpers.getGoalValues("y",null,o,g,f,u),barXPosition:t,barWidth:n}}},{key:"getBarXForNumericXAxis",value:function(e){var t=e.x,i=e.barWidth,a=e.realIndex,r=e.j,s=this.w,n=a;return s.globals.seriesX[a].length||(n=s.globals.maxValsInArrayIndex),s.globals.seriesX[n][r]&&(t=(s.globals.seriesX[n][r]-s.globals.minX)/this.xRatio-i*this.seriesLen/2),{barXPosition:t+i*this.visibleI,x:t}}},{key:"getPreviousPath",value:function(e,t){for(var i,a=this.w,r=0;r<a.globals.previousPaths.length;r++){var s=a.globals.previousPaths[r];s.paths&&s.paths.length>0&&parseInt(s.realIndex,10)===parseInt(e,10)&&void 0!==a.globals.previousPaths[r].paths[t]&&(i=a.globals.previousPaths[r].paths[t].d)}return i}}])&&di(t.prototype,i),e}();function gi(e){return gi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},gi(e)}function fi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function pi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?fi(Object(i),!0).forEach((function(t){xi(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):fi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function xi(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function bi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function vi(e,t){return vi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},vi(e,t)}function mi(e){return mi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},mi(e)}const yi=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&vi(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=mi(a);if(s){var i=mi(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===gi(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n.apply(this,arguments)}return t=o,(i=[{key:"draw",value:function(e,t){var i=this,a=this.w;this.graphics=new g(this.ctx),this.bar=new ui(this.ctx,this.xyRatios);var s=new p(this.ctx,a);e=s.getLogSeries(e),this.yRatio=s.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e),"100%"===a.config.chart.stackType&&(e=a.globals.comboCharts?t.map((function(e){return a.globals.seriesPercent[e]})):a.globals.seriesPercent.slice()),this.series=e,this.barHelpers.initializeStackedPrevVars(this);for(var n=this.graphics.group({class:"apexcharts-bar-series apexcharts-plot-series"}),o=0,l=0,c=function(s,c){var h=void 0,d=void 0,u=void 0,g=void 0,f=a.globals.comboCharts?t[s]:s,p=i.barHelpers.getGroupIndex(f),x=p.groupIndex,b=p.columnGroupIndex;i.groupCtx=i[a.globals.seriesGroups[x]];var v=[],m=[],y=0;i.yRatio.length>1&&(i.yaxisIndex=a.globals.seriesYAxisReverseMap[f][0],y=f),i.isReversed=a.config.yaxis[i.yaxisIndex]&&a.config.yaxis[i.yaxisIndex].reversed;var w=i.graphics.group({class:"apexcharts-series",seriesName:r.escapeString(a.globals.seriesNames[f]),rel:s+1,"data:realIndex":f});i.ctx.series.addCollapsedClassToSeries(w,f);var k=i.graphics.group({class:"apexcharts-datalabels","data:realIndex":f}),A=i.graphics.group({class:"apexcharts-bar-goals-markers"}),S=0,C=0,P=i.initialPositions(o,l,h,d,u,g,y);l=P.y,S=P.barHeight,d=P.yDivision,g=P.zeroW,o=P.x,C=P.barWidth,h=P.xDivision,u=P.zeroH,a.globals.barHeight=S,a.globals.barWidth=C,i.barHelpers.initializeStackedXYVars(i),1===i.groupCtx.prevY.length&&i.groupCtx.prevY[0].every((function(e){return isNaN(e)}))&&(i.groupCtx.prevY[0]=i.groupCtx.prevY[0].map((function(){return u})),i.groupCtx.prevYF[0]=i.groupCtx.prevYF[0].map((function(){return 0})));for(var L=0;L<a.globals.dataPoints;L++){var O=i.barHelpers.getStrokeWidth(s,L,f),M={indexes:{i:s,j:L,realIndex:f,translationsIndex:y,bc:c},strokeWidth:O,x:o,y:l,elSeries:w,columnGroupIndex:b,seriesGroup:a.globals.seriesGroups[x]},T=null;i.isHorizontal?(T=i.drawStackedBarPaths(pi(pi({},M),{},{zeroW:g,barHeight:S,yDivision:d})),C=i.series[s][L]/i.invertedYRatio):(T=i.drawStackedColumnPaths(pi(pi({},M),{},{xDivision:h,barWidth:C,zeroH:u})),S=i.series[s][L]/i.yRatio[y]);var I=i.barHelpers.drawGoalLine({barXPosition:T.barXPosition,barYPosition:T.barYPosition,goalX:T.goalX,goalY:T.goalY,barHeight:S,barWidth:C});I&&A.add(I),l=T.y,o=T.x,v.push(o),m.push(l);var E=i.barHelpers.getPathFillColor(e,s,L,f);w=i.renderSeries({realIndex:f,pathFill:E,j:L,i:s,columnGroupIndex:b,pathFrom:T.pathFrom,pathTo:T.pathTo,strokeWidth:O,elSeries:w,x:o,y:l,series:e,barHeight:S,barWidth:C,elDataLabelsWrap:k,elGoalsMarkers:A,type:"bar",visibleSeries:b})}a.globals.seriesXvalues[f]=v,a.globals.seriesYvalues[f]=m,i.groupCtx.prevY.push(i.groupCtx.yArrj),i.groupCtx.prevYF.push(i.groupCtx.yArrjF),i.groupCtx.prevYVal.push(i.groupCtx.yArrjVal),i.groupCtx.prevX.push(i.groupCtx.xArrj),i.groupCtx.prevXF.push(i.groupCtx.xArrjF),i.groupCtx.prevXVal.push(i.groupCtx.xArrjVal),n.add(w)},h=0,d=0;h<e.length;h++,d++)c(h,d);return n}},{key:"initialPositions",value:function(e,t,i,a,r,s,n){var o,l,c=this.w;if(this.isHorizontal){a=c.globals.gridHeight/c.globals.dataPoints;var h=c.config.plotOptions.bar.barHeight;o=-1===String(h).indexOf("%")?parseInt(h,10):a*parseInt(h,10)/100,s=c.globals.padHorizontal+(this.isReversed?c.globals.gridWidth-this.baseLineInvertedY:this.baseLineInvertedY),t=(a-o)/2}else{l=i=c.globals.gridWidth/c.globals.dataPoints;var d=c.config.plotOptions.bar.columnWidth;c.globals.isXNumeric&&c.globals.dataPoints>1?l=(i=c.globals.minXDiff/this.xRatio)*parseInt(this.barOptions.columnWidth,10)/100:-1===String(d).indexOf("%")?l=parseInt(d,10):l*=parseInt(d,10)/100,r=c.globals.gridHeight-this.baseLineY[n]-(this.isReversed?c.globals.gridHeight:0),e=c.globals.padHorizontal+(i-l)/2}var u=c.globals.barGroups.length||1;return{x:e,y:t,yDivision:a,xDivision:i,barHeight:o/u,barWidth:l/u,zeroH:r,zeroW:s}}},{key:"drawStackedBarPaths",value:function(e){for(var t,i=e.indexes,a=e.barHeight,r=e.strokeWidth,s=e.zeroW,n=e.x,o=e.y,l=e.columnGroupIndex,c=e.seriesGroup,h=e.yDivision,d=e.elSeries,u=this.w,g=o+l*a,f=i.i,p=i.j,x=i.realIndex,b=i.translationsIndex,v=0,m=0;m<this.groupCtx.prevXF.length;m++)v+=this.groupCtx.prevXF[m][p];var y;if((y=c.indexOf(u.config.series[x].name))>0){var w=s;this.groupCtx.prevXVal[y-1][p]<0?w=this.series[f][p]>=0?this.groupCtx.prevX[y-1][p]+v-2*(this.isReversed?v:0):this.groupCtx.prevX[y-1][p]:this.groupCtx.prevXVal[y-1][p]>=0&&(w=this.series[f][p]>=0?this.groupCtx.prevX[y-1][p]:this.groupCtx.prevX[y-1][p]-v+2*(this.isReversed?v:0)),t=w}else t=s;n=null===this.series[f][p]?t:t+this.series[f][p]/this.invertedYRatio-2*(this.isReversed?this.series[f][p]/this.invertedYRatio:0);var k=this.barHelpers.getBarpaths({barYPosition:g,barHeight:a,x1:t,x2:n,strokeWidth:r,series:this.series,realIndex:i.realIndex,seriesGroup:c,i:f,j:p,w:u});return this.barHelpers.barBackground({j:p,i:f,y1:g,y2:a,elSeries:d}),o+=h,{pathTo:k.pathTo,pathFrom:k.pathFrom,goalX:this.barHelpers.getGoalValues("x",s,null,f,p,b),barXPosition:t,barYPosition:g,x:n,y:o}}},{key:"drawStackedColumnPaths",value:function(e){var t=e.indexes,i=e.x,a=e.y,r=e.xDivision,s=e.barWidth,n=e.zeroH,o=e.columnGroupIndex,l=e.seriesGroup,c=e.elSeries,h=this.w,d=t.i,u=t.j,g=t.bc,f=t.realIndex,p=t.translationsIndex;if(h.globals.isXNumeric){var x=h.globals.seriesX[f][u];x||(x=0),i=(x-h.globals.minX)/this.xRatio-s/2*h.globals.barGroups.length}for(var b,v=i+o*s,m=0,y=0;y<this.groupCtx.prevYF.length;y++)m+=isNaN(this.groupCtx.prevYF[y][u])?0:this.groupCtx.prevYF[y][u];var w=d;if(l&&(w=l.indexOf(h.globals.seriesNames[f])),w>0&&!h.globals.isXNumeric||w>0&&h.globals.isXNumeric&&h.globals.seriesX[f-1][u]===h.globals.seriesX[f][u]){var k,A,S,C=Math.min(this.yRatio.length+1,f+1);if(void 0!==this.groupCtx.prevY[w-1]&&this.groupCtx.prevY[w-1].length)for(var P=1;P<C;P++){var L;if(!isNaN(null===(L=this.groupCtx.prevY[w-P])||void 0===L?void 0:L[u])){S=this.groupCtx.prevY[w-P][u];break}}for(var O=1;O<C;O++){var M,T;if((null===(M=this.groupCtx.prevYVal[w-O])||void 0===M?void 0:M[u])<0){A=this.series[d][u]>=0?S-m+2*(this.isReversed?m:0):S;break}if((null===(T=this.groupCtx.prevYVal[w-O])||void 0===T?void 0:T[u])>=0){A=this.series[d][u]>=0?S:S+m-2*(this.isReversed?m:0);break}}void 0===A&&(A=h.globals.gridHeight),b=null!==(k=this.groupCtx.prevYF[0])&&void 0!==k&&k.every((function(e){return 0===e}))&&this.groupCtx.prevYF.slice(1,w).every((function(e){return e.every((function(e){return isNaN(e)}))}))?n:A}else b=n;a=this.series[d][u]?b-this.series[d][u]/this.yRatio[p]+2*(this.isReversed?this.series[d][u]/this.yRatio[p]:0):b;var I=this.barHelpers.getColumnPaths({barXPosition:v,barWidth:s,y1:b,y2:a,yRatio:this.yRatio[p],strokeWidth:this.strokeWidth,series:this.series,seriesGroup:l,realIndex:t.realIndex,i:d,j:u,w:h});return this.barHelpers.barBackground({bc:g,j:u,i:d,x1:v,x2:s,elSeries:c}),{pathTo:I.pathTo,pathFrom:I.pathFrom,goalY:this.barHelpers.getGoalValues("y",null,n,d,u),barXPosition:v,x:h.globals.isXNumeric?i:i+r,y:a}}}])&&bi(t.prototype,i),o}(ui);function wi(e){return wi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wi(e)}function ki(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Ai(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ki(Object(i),!0).forEach((function(t){Si(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ki(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Si(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Ci(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function Pi(e,t){return Pi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Pi(e,t)}function Li(e){return Li=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Li(e)}const Oi=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Pi(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Li(a);if(s){var i=Li(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===wi(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n.apply(this,arguments)}return t=o,(i=[{key:"draw",value:function(e,t,i){var a=this,s=this.w,n=new g(this.ctx),o=s.globals.comboCharts?t:s.config.chart.type,l=new te(this.ctx);this.candlestickOptions=this.w.config.plotOptions.candlestick,this.boxOptions=this.w.config.plotOptions.boxPlot,this.isHorizontal=s.config.plotOptions.bar.horizontal;var c=new p(this.ctx,s);e=c.getLogSeries(e),this.series=e,this.yRatio=c.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e);for(var h=n.group({class:"apexcharts-".concat(o,"-series apexcharts-plot-series")}),d=function(t){a.isBoxPlot="boxPlot"===s.config.chart.type||"boxPlot"===s.config.series[t].type;var o,c,d,u,g=void 0,f=void 0,p=[],x=[],b=s.globals.comboCharts?i[t]:t,v=a.barHelpers.getGroupIndex(b).columnGroupIndex,m=n.group({class:"apexcharts-series",seriesName:r.escapeString(s.globals.seriesNames[b]),rel:t+1,"data:realIndex":b});a.ctx.series.addCollapsedClassToSeries(m,b),e[t].length>0&&(a.visibleI=a.visibleI+1);var y,w,k=0;a.yRatio.length>1&&(a.yaxisIndex=s.globals.seriesYAxisReverseMap[b][0],k=b);var A=a.barHelpers.initialPositions();f=A.y,y=A.barHeight,c=A.yDivision,u=A.zeroW,g=A.x,w=A.barWidth,o=A.xDivision,d=A.zeroH,x.push(g+w/2);for(var S=n.group({class:"apexcharts-datalabels","data:realIndex":b}),C=function(i){var r=a.barHelpers.getStrokeWidth(t,i,b),n=null,h={indexes:{i:t,j:i,realIndex:b,translationsIndex:k},x:g,y:f,strokeWidth:r,elSeries:m};n=a.isHorizontal?a.drawHorizontalBoxPaths(Ai(Ai({},h),{},{yDivision:c,barHeight:y,zeroW:u})):a.drawVerticalBoxPaths(Ai(Ai({},h),{},{xDivision:o,barWidth:w,zeroH:d})),f=n.y,g=n.x,i>0&&x.push(g+w/2),p.push(f),n.pathTo.forEach((function(o,c){var h=!a.isBoxPlot&&a.candlestickOptions.wick.useFillColor?n.color[c]:s.globals.stroke.colors[t],d=l.fillPath({seriesNumber:b,dataPointIndex:i,color:n.color[c],value:e[t][i]});a.renderSeries({realIndex:b,pathFill:d,lineFill:h,j:i,i:t,pathFrom:n.pathFrom,pathTo:o,strokeWidth:r,elSeries:m,x:g,y:f,series:e,columnGroupIndex:v,barHeight:y,barWidth:w,elDataLabelsWrap:S,visibleSeries:a.visibleI,type:s.config.chart.type})}))},P=0;P<s.globals.dataPoints;P++)C(P);s.globals.seriesXvalues[b]=x,s.globals.seriesYvalues[b]=p,h.add(m)},u=0;u<e.length;u++)d(u);return h}},{key:"drawVerticalBoxPaths",value:function(e){var t=e.indexes,i=e.x,a=(e.y,e.xDivision),r=e.barWidth,s=e.zeroH,n=e.strokeWidth,o=this.w,l=new g(this.ctx),c=t.i,h=t.j,d=!0,u=o.config.plotOptions.candlestick.colors.upward,f=o.config.plotOptions.candlestick.colors.downward,p="";this.isBoxPlot&&(p=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var x=this.yRatio[t.translationsIndex],b=t.realIndex,v=this.getOHLCValue(b,h),m=s,y=s;v.o>v.c&&(d=!1);var w=Math.min(v.o,v.c),k=Math.max(v.o,v.c),A=v.m;o.globals.isXNumeric&&(i=(o.globals.seriesX[b][h]-o.globals.minX)/this.xRatio-r/2);var S=i+r*this.visibleI;void 0===this.series[c][h]||null===this.series[c][h]?(w=s,k=s):(w=s-w/x,k=s-k/x,m=s-v.h/x,y=s-v.l/x,A=s-v.m/x);var C=l.move(S,s),P=l.move(S+r/2,w);return o.globals.previousPaths.length>0&&(P=this.getPreviousPath(b,h,!0)),C=this.isBoxPlot?[l.move(S,w)+l.line(S+r/2,w)+l.line(S+r/2,m)+l.line(S+r/4,m)+l.line(S+r-r/4,m)+l.line(S+r/2,m)+l.line(S+r/2,w)+l.line(S+r,w)+l.line(S+r,A)+l.line(S,A)+l.line(S,w+n/2),l.move(S,A)+l.line(S+r,A)+l.line(S+r,k)+l.line(S+r/2,k)+l.line(S+r/2,y)+l.line(S+r-r/4,y)+l.line(S+r/4,y)+l.line(S+r/2,y)+l.line(S+r/2,k)+l.line(S,k)+l.line(S,A)+"z"]:[l.move(S,k)+l.line(S+r/2,k)+l.line(S+r/2,m)+l.line(S+r/2,k)+l.line(S+r,k)+l.line(S+r,w)+l.line(S+r/2,w)+l.line(S+r/2,y)+l.line(S+r/2,w)+l.line(S,w)+l.line(S,k-n/2)],P+=l.move(S,w),o.globals.isXNumeric||(i+=a),{pathTo:C,pathFrom:P,x:i,y:k,barXPosition:S,color:this.isBoxPlot?p:d?[u]:[f]}}},{key:"drawHorizontalBoxPaths",value:function(e){var t=e.indexes,i=(e.x,e.y),a=e.yDivision,r=e.barHeight,s=e.zeroW,n=e.strokeWidth,o=this.w,l=new g(this.ctx),c=t.i,h=t.j,d=this.boxOptions.colors.lower;this.isBoxPlot&&(d=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var u=this.invertedYRatio,f=t.realIndex,p=this.getOHLCValue(f,h),x=s,b=s,v=Math.min(p.o,p.c),m=Math.max(p.o,p.c),y=p.m;o.globals.isXNumeric&&(i=(o.globals.seriesX[f][h]-o.globals.minX)/this.invertedXRatio-r/2);var w=i+r*this.visibleI;void 0===this.series[c][h]||null===this.series[c][h]?(v=s,m=s):(v=s+v/u,m=s+m/u,x=s+p.h/u,b=s+p.l/u,y=s+p.m/u);var k=l.move(s,w),A=l.move(v,w+r/2);return o.globals.previousPaths.length>0&&(A=this.getPreviousPath(f,h,!0)),k=[l.move(v,w)+l.line(v,w+r/2)+l.line(x,w+r/2)+l.line(x,w+r/2-r/4)+l.line(x,w+r/2+r/4)+l.line(x,w+r/2)+l.line(v,w+r/2)+l.line(v,w+r)+l.line(y,w+r)+l.line(y,w)+l.line(v+n/2,w),l.move(y,w)+l.line(y,w+r)+l.line(m,w+r)+l.line(m,w+r/2)+l.line(b,w+r/2)+l.line(b,w+r-r/4)+l.line(b,w+r/4)+l.line(b,w+r/2)+l.line(m,w+r/2)+l.line(m,w)+l.line(y,w)+"z"],A+=l.move(v,w),o.globals.isXNumeric||(i+=a),{pathTo:k,pathFrom:A,x:m,y:i,barYPosition:w,color:d}}},{key:"getOHLCValue",value:function(e,t){var i=this.w;return{o:this.isBoxPlot?i.globals.seriesCandleH[e][t]:i.globals.seriesCandleO[e][t],h:this.isBoxPlot?i.globals.seriesCandleO[e][t]:i.globals.seriesCandleH[e][t],m:i.globals.seriesCandleM[e][t],l:this.isBoxPlot?i.globals.seriesCandleC[e][t]:i.globals.seriesCandleL[e][t],c:this.isBoxPlot?i.globals.seriesCandleL[e][t]:i.globals.seriesCandleC[e][t]}}}])&&Ci(t.prototype,i),o}(ui);function Mi(e){return function(e){if(Array.isArray(e))return Ti(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return Ti(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Ti(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ti(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Ii(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ei=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"checkColorRange",value:function(){var e=this.w,t=!1,i=e.config.plotOptions[e.config.chart.type];return i.colorScale.ranges.length>0&&i.colorScale.ranges.map((function(e,i){e.from<=0&&(t=!0)})),t}},{key:"getShadeColor",value:function(e,t,i,a){var s=this.w,n=1,o=s.config.plotOptions[e].shadeIntensity,l=this.determineColor(e,t,i);s.globals.hasNegs||a?n=s.config.plotOptions[e].reverseNegativeShade?l.percent<0?l.percent/100*(1.25*o):(1-l.percent/100)*(1.25*o):l.percent<=0?1-(1+l.percent/100)*o:(1-l.percent/100)*o:(n=1-l.percent/100,"treemap"===e&&(n=(1-l.percent/100)*(1.25*o)));var c=l.color,h=new r;return s.config.plotOptions[e].enableShades&&(c="dark"===this.w.config.theme.mode?r.hexToRgba(h.shadeColor(-1*n,l.color),s.config.fill.opacity):r.hexToRgba(h.shadeColor(n,l.color),s.config.fill.opacity)),{color:c,colorProps:l}}},{key:"determineColor",value:function(e,t,i){var a=this.w,r=a.globals.series[t][i],s=a.config.plotOptions[e],n=s.colorScale.inverse?i:t;s.distributed&&"treemap"===a.config.chart.type&&(n=i);var o=a.globals.colors[n],l=null,c=Math.min.apply(Math,Mi(a.globals.series[t])),h=Math.max.apply(Math,Mi(a.globals.series[t]));s.distributed||"heatmap"!==e||(c=a.globals.minY,h=a.globals.maxY),void 0!==s.colorScale.min&&(c=s.colorScale.min<a.globals.minY?s.colorScale.min:a.globals.minY,h=s.colorScale.max>a.globals.maxY?s.colorScale.max:a.globals.maxY);var d=Math.abs(h)+Math.abs(c),u=100*r/(0===d?d-1e-6:d);return s.colorScale.ranges.length>0&&s.colorScale.ranges.map((function(e,t){if(r>=e.from&&r<=e.to){o=e.color,l=e.foreColor?e.foreColor:null,c=e.from,h=e.to;var i=Math.abs(h)+Math.abs(c);u=100*r/(0===i?i-1e-6:i)}})),{color:o,foreColor:l,percent:u}}},{key:"calculateDataLabels",value:function(e){var t=e.text,i=e.x,a=e.y,r=e.i,s=e.j,n=e.colorProps,o=e.fontSize,l=this.w.config.dataLabels,c=new g(this.ctx),h=new oe(this.ctx),d=null;if(l.enabled){d=c.group({class:"apexcharts-data-labels"});var u=l.offsetX,f=l.offsetY,p=i+u,x=a+parseFloat(l.style.fontSize)/3+f;h.plotDataLabelsText({x:p,y:x,text:t,i:r,j:s,color:n.foreColor,parent:d,fontSize:o,dataLabelsConfig:l})}return d}},{key:"addListeners",value:function(e){var t=new g(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))}}])&&Ii(t.prototype,i),e}();function zi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Xi=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.xRatio=i.xRatio,this.yRatio=i.yRatio,this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.helpers=new Ei(t),this.rectRadius=this.w.config.plotOptions.heatmap.radius,this.strokeWidth=this.w.config.stroke.show?this.w.config.stroke.width:0}var t,i;return t=e,(i=[{key:"draw",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-heatmap"});a.attr("clip-path","url(#gridRectMask".concat(t.globals.cuid,")"));var s=t.globals.gridWidth/t.globals.dataPoints,n=t.globals.gridHeight/t.globals.series.length,o=0,c=!1;this.negRange=this.helpers.checkColorRange();var h=e.slice();t.config.yaxis[0].reversed&&(c=!0,h.reverse());for(var d=c?0:h.length-1;c?d<h.length:d>=0;c?d++:d--){var u=i.group({class:"apexcharts-series apexcharts-heatmap-series",seriesName:r.escapeString(t.globals.seriesNames[d]),rel:d+1,"data:realIndex":d});if(this.ctx.series.addCollapsedClassToSeries(u,d),t.config.chart.dropShadow.enabled){var f=t.config.chart.dropShadow;new l(this.ctx).dropShadow(u,f,d)}for(var p=0,x=t.config.plotOptions.heatmap.shadeIntensity,b=0;b<h[d].length;b++){var v=this.helpers.getShadeColor(t.config.chart.type,d,b,this.negRange),m=v.color,y=v.colorProps;"image"===t.config.fill.type&&(m=new te(this.ctx).fillPath({seriesNumber:d,dataPointIndex:b,opacity:t.globals.hasNegs?y.percent<0?1-(1+y.percent/100):x+y.percent/100:y.percent/100,patternID:r.randomId(),width:t.config.fill.image.width?t.config.fill.image.width:s,height:t.config.fill.image.height?t.config.fill.image.height:n}));var w=this.rectRadius,k=i.drawRect(p,o,s,n,w);if(k.attr({cx:p,cy:o}),k.node.classList.add("apexcharts-heatmap-rect"),u.add(k),k.attr({fill:m,i:d,index:d,j:b,val:e[d][b],"stroke-width":this.strokeWidth,stroke:t.config.plotOptions.heatmap.useFillColorAsStroke?m:t.globals.stroke.colors[0],color:m}),this.helpers.addListeners(k),t.config.chart.animations.enabled&&!t.globals.dataChanged){var A=1;t.globals.resized||(A=t.config.chart.animations.speed),this.animateHeatMap(k,p,o,s,n,A)}if(t.globals.dataChanged){var S=1;if(this.dynamicAnim.enabled&&t.globals.shouldAnimate){S=this.dynamicAnim.speed;var C=t.globals.previousPaths[d]&&t.globals.previousPaths[d][b]&&t.globals.previousPaths[d][b].color;C||(C="rgba(255, 255, 255, 0)"),this.animateHeatColor(k,r.isColorHex(C)?C:r.rgb2hex(C),r.isColorHex(m)?m:r.rgb2hex(m),S)}}var P=(0,t.config.dataLabels.formatter)(t.globals.series[d][b],{value:t.globals.series[d][b],seriesIndex:d,dataPointIndex:b,w:t}),L=this.helpers.calculateDataLabels({text:P,x:p+s/2,y:o+n/2,i:d,j:b,colorProps:y,series:h});null!==L&&u.add(L),p+=s}o+=n,a.add(u)}var O=t.globals.yAxisScale[0].result.slice();return t.config.yaxis[0].reversed?O.unshift(""):O.push(""),t.globals.yAxisScale[0].result=O,a}},{key:"animateHeatMap",value:function(e,t,i,a,r,s){var o=new n(this.ctx);o.animateRect(e,{x:t+a/2,y:i+r/2,width:0,height:0},{x:t,y:i,width:a,height:r},s,(function(){o.animationCompleted(e)}))}},{key:"animateHeatColor",value:function(e,t,i,a){e.attr({fill:t}).animate(a).attr({fill:i})}}])&&zi(t.prototype,i),e}();function Yi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Di=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{key:"drawYAxisTexts",value:function(e,t,i,a){var r=this.w,s=r.config.yaxis[0],n=r.globals.yLabelFormatters[0];return new g(this.ctx).drawText({x:e+s.labels.offsetX,y:t+s.labels.offsetY,text:n(a,i),textAnchor:"middle",fontSize:s.labels.style.fontSize,fontFamily:s.labels.style.fontFamily,foreColor:Array.isArray(s.labels.style.colors)?s.labels.style.colors[i]:s.labels.style.colors})}}])&&Yi(t.prototype,i),e}();function Ri(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const Fi=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w;var i=this.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.animBeginArr=[0],this.animDur=0,this.donutDataLabels=this.w.config.plotOptions.pie.donut.labels,this.lineColorArr=void 0!==i.globals.stroke.colors?i.globals.stroke.colors:i.globals.colors,this.defaultSize=Math.min(i.globals.gridWidth,i.globals.gridHeight),this.centerY=this.defaultSize/2,this.centerX=i.globals.gridWidth/2,"radialBar"===i.config.chart.type?this.fullAngle=360:this.fullAngle=Math.abs(i.config.plotOptions.pie.endAngle-i.config.plotOptions.pie.startAngle),this.initialAngle=i.config.plotOptions.pie.startAngle%this.fullAngle,i.globals.radialSize=this.defaultSize/2.05-i.config.stroke.width-(i.config.chart.sparkline.enabled?0:i.config.chart.dropShadow.blur),this.donutSize=i.globals.radialSize*parseInt(i.config.plotOptions.pie.donut.size,10)/100;var a=i.config.plotOptions.pie.customScale,r=i.globals.gridWidth/2,s=i.globals.gridHeight/2;this.translateX=r-r*a,this.translateY=s-s*a,this.dataLabelsGroup=new g(this.ctx).group({class:"apexcharts-datalabels-group",transform:"translate(".concat(this.translateX,", ").concat(this.translateY,") scale(").concat(a,")")}),this.maxY=0,this.sliceLabels=[],this.sliceSizes=[],this.prevSectorAngleArr=[]}var t,i;return t=e,(i=[{key:"draw",value:function(e){var t=this,i=this.w,a=new g(this.ctx),s=a.group({class:"apexcharts-pie"});if(i.globals.noData)return s;for(var n=0,o=0;o<e.length;o++)n+=r.negToZero(e[o]);var l=[],c=a.group();0===n&&(n=1e-5),e.forEach((function(e){t.maxY=Math.max(t.maxY,e)})),i.config.yaxis[0].max&&(this.maxY=i.config.yaxis[0].max),"back"===i.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(s);for(var h=0;h<e.length;h++){var d=this.fullAngle*r.negToZero(e[h])/n;l.push(d),"polarArea"===this.chartType?(l[h]=this.fullAngle/e.length,this.sliceSizes.push(i.globals.radialSize*e[h]/this.maxY)):this.sliceSizes.push(i.globals.radialSize)}if(i.globals.dataChanged){for(var u,f=0,p=0;p<i.globals.previousPaths.length;p++)f+=r.negToZero(i.globals.previousPaths[p]);for(var x=0;x<i.globals.previousPaths.length;x++)u=this.fullAngle*r.negToZero(i.globals.previousPaths[x])/f,this.prevSectorAngleArr.push(u)}if(this.donutSize<0&&(this.donutSize=0),"donut"===this.chartType){var b=a.drawCircle(this.donutSize);b.attr({cx:this.centerX,cy:this.centerY,fill:i.config.plotOptions.pie.donut.background?i.config.plotOptions.pie.donut.background:"transparent"}),c.add(b)}var v=this.drawArcs(l,e);if(this.sliceLabels.forEach((function(e){v.add(e)})),c.attr({transform:"translate(".concat(this.translateX,", ").concat(this.translateY,") scale(").concat(i.config.plotOptions.pie.customScale,")")}),c.add(v),s.add(c),this.donutDataLabels.show){var m=this.renderInnerDataLabels(this.dataLabelsGroup,this.donutDataLabels,{hollowSize:this.donutSize,centerX:this.centerX,centerY:this.centerY,opacity:this.donutDataLabels.show});s.add(m)}return"front"===i.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(s),s}},{key:"drawArcs",value:function(e,t){var i=this.w,a=new l(this.ctx),s=new g(this.ctx),n=new te(this.ctx),o=s.group({class:"apexcharts-slices"}),c=this.initialAngle,h=this.initialAngle,d=this.initialAngle,u=this.initialAngle;this.strokeWidth=i.config.stroke.show?i.config.stroke.width:0;for(var f=0;f<e.length;f++){var p=s.group({class:"apexcharts-series apexcharts-pie-series",seriesName:r.escapeString(i.globals.seriesNames[f]),rel:f+1,"data:realIndex":f});o.add(p),h=u,d=(c=d)+e[f],u=h+this.prevSectorAngleArr[f];var x=d<c?this.fullAngle+d-c:d-c,b=n.fillPath({seriesNumber:f,size:this.sliceSizes[f],value:t[f]}),v=this.getChangedPath(h,u),m=s.drawPath({d:v,stroke:Array.isArray(this.lineColorArr)?this.lineColorArr[f]:this.lineColorArr,strokeWidth:0,fill:b,fillOpacity:i.config.fill.opacity,classes:"apexcharts-pie-area apexcharts-".concat(this.chartType.toLowerCase(),"-slice-").concat(f)});if(m.attr({index:0,j:f}),a.setSelectionFilter(m,0,f),i.config.chart.dropShadow.enabled){var y=i.config.chart.dropShadow;a.dropShadow(m,y,f)}this.addListeners(m,this.donutDataLabels),g.setAttrs(m.node,{"data:angle":x,"data:startAngle":c,"data:strokeWidth":this.strokeWidth,"data:value":t[f]});var w={x:0,y:0};"pie"===this.chartType||"polarArea"===this.chartType?w=r.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize/1.25+i.config.plotOptions.pie.dataLabels.offset,(c+x/2)%this.fullAngle):"donut"===this.chartType&&(w=r.polarToCartesian(this.centerX,this.centerY,(i.globals.radialSize+this.donutSize)/2+i.config.plotOptions.pie.dataLabels.offset,(c+x/2)%this.fullAngle)),p.add(m);var k=0;if(!this.initialAnim||i.globals.resized||i.globals.dataChanged?this.animBeginArr.push(0):(0==(k=x/this.fullAngle*i.config.chart.animations.speed)&&(k=1),this.animDur=k+this.animDur,this.animBeginArr.push(this.animDur)),this.dynamicAnim&&i.globals.dataChanged?this.animatePaths(m,{size:this.sliceSizes[f],endAngle:d,startAngle:c,prevStartAngle:h,prevEndAngle:u,animateStartingPos:!0,i:f,animBeginArr:this.animBeginArr,shouldSetPrevPaths:!0,dur:i.config.chart.animations.dynamicAnimation.speed}):this.animatePaths(m,{size:this.sliceSizes[f],endAngle:d,startAngle:c,i:f,totalItems:e.length-1,animBeginArr:this.animBeginArr,dur:k}),i.config.plotOptions.pie.expandOnClick&&"polarArea"!==this.chartType&&m.node.addEventListener("mouseup",this.pieClicked.bind(this,f)),void 0!==i.globals.selectedDataPoints[0]&&i.globals.selectedDataPoints[0].indexOf(f)>-1&&this.pieClicked(f),i.config.dataLabels.enabled){var A=w.x,S=w.y,C=100*x/this.fullAngle+"%";if(0!==x&&i.config.plotOptions.pie.dataLabels.minAngleToShowLabel<e[f]){var P=i.config.dataLabels.formatter;void 0!==P&&(C=P(i.globals.seriesPercent[f][0],{seriesIndex:f,w:i}));var L=i.globals.dataLabels.style.colors[f],O=s.group({class:"apexcharts-datalabels"}),M=s.drawText({x:A,y:S,text:C,textAnchor:"middle",fontSize:i.config.dataLabels.style.fontSize,fontFamily:i.config.dataLabels.style.fontFamily,fontWeight:i.config.dataLabels.style.fontWeight,foreColor:L});if(O.add(M),i.config.dataLabels.dropShadow.enabled){var T=i.config.dataLabels.dropShadow;a.dropShadow(M,T)}M.node.classList.add("apexcharts-pie-label"),i.config.chart.animations.animate&&!1===i.globals.resized&&(M.node.classList.add("apexcharts-pie-label-delay"),M.node.style.animationDelay=i.config.chart.animations.speed/940+"s"),this.sliceLabels.push(O)}}}return o}},{key:"addListeners",value:function(e,t){var i=new g(this.ctx);e.node.addEventListener("mouseenter",i.pathMouseEnter.bind(this,e)),e.node.addEventListener("mouseleave",i.pathMouseLeave.bind(this,e)),e.node.addEventListener("mouseleave",this.revertDataLabelsInner.bind(this,e.node,t)),e.node.addEventListener("mousedown",i.pathMouseDown.bind(this,e)),this.donutDataLabels.total.showAlways||(e.node.addEventListener("mouseenter",this.printDataLabelsInner.bind(this,e.node,t)),e.node.addEventListener("mousedown",this.printDataLabelsInner.bind(this,e.node,t)))}},{key:"animatePaths",value:function(e,t){var i=this.w,a=t.endAngle<t.startAngle?this.fullAngle+t.endAngle-t.startAngle:t.endAngle-t.startAngle,r=a,s=t.startAngle,n=t.startAngle;void 0!==t.prevStartAngle&&void 0!==t.prevEndAngle&&(s=t.prevEndAngle,r=t.prevEndAngle<t.prevStartAngle?this.fullAngle+t.prevEndAngle-t.prevStartAngle:t.prevEndAngle-t.prevStartAngle),t.i===i.config.series.length-1&&(a+n>this.fullAngle?t.endAngle=t.endAngle-(a+n):a+n<this.fullAngle&&(t.endAngle=t.endAngle+(this.fullAngle-(a+n)))),a===this.fullAngle&&(a=this.fullAngle-.01),this.animateArc(e,s,n,a,r,t)}},{key:"animateArc",value:function(e,t,i,a,r,s){var o,l=this,c=this.w,h=new n(this.ctx),d=s.size;(isNaN(t)||isNaN(r))&&(t=i,r=a,s.dur=0);var u=a,g=i,f=t<i?this.fullAngle+t-i:t-i;c.globals.dataChanged&&s.shouldSetPrevPaths&&s.prevEndAngle&&(o=l.getPiePath({me:l,startAngle:s.prevStartAngle,angle:s.prevEndAngle<s.prevStartAngle?this.fullAngle+s.prevEndAngle-s.prevStartAngle:s.prevEndAngle-s.prevStartAngle,size:d}),e.attr({d:o})),0!==s.dur?e.animate(s.dur,c.globals.easing,s.animBeginArr[s.i]).afterAll((function(){"pie"!==l.chartType&&"donut"!==l.chartType&&"polarArea"!==l.chartType||this.animate(c.config.chart.animations.dynamicAnimation.speed).attr({"stroke-width":l.strokeWidth}),s.i===c.config.series.length-1&&h.animationCompleted(e)})).during((function(n){u=f+(a-f)*n,s.animateStartingPos&&(u=r+(a-r)*n,g=t-r+(i-(t-r))*n),o=l.getPiePath({me:l,startAngle:g,angle:u,size:d}),e.node.setAttribute("data:pathOrig",o),e.attr({d:o})})):(o=l.getPiePath({me:l,startAngle:g,angle:a,size:d}),s.isTrack||(c.globals.animationEnded=!0),e.node.setAttribute("data:pathOrig",o),e.attr({d:o,"stroke-width":l.strokeWidth}))}},{key:"pieClicked",value:function(e){var t,i=this.w,a=this,r=a.sliceSizes[e]+(i.config.plotOptions.pie.expandOnClick?4:0),s=i.globals.dom.Paper.select(".apexcharts-".concat(a.chartType.toLowerCase(),"-slice-").concat(e)).members[0];if("true"!==s.attr("data:pieClicked")){var n=i.globals.dom.baseEl.getElementsByClassName("apexcharts-pie-area");Array.prototype.forEach.call(n,(function(e){e.setAttribute("data:pieClicked","false");var t=e.getAttribute("data:pathOrig");t&&e.setAttribute("d",t)})),i.globals.capturedDataPointIndex=e,s.attr("data:pieClicked","true");var o=parseInt(s.attr("data:startAngle"),10),l=parseInt(s.attr("data:angle"),10);t=a.getPiePath({me:a,startAngle:o,angle:l,size:r}),360!==l&&s.plot(t)}else{s.attr({"data:pieClicked":"false"}),this.revertDataLabelsInner(s.node,this.donutDataLabels);var c=s.attr("data:pathOrig");s.attr({d:c})}}},{key:"getChangedPath",value:function(e,t){var i="";return this.dynamicAnim&&this.w.globals.dataChanged&&(i=this.getPiePath({me:this,startAngle:e,angle:t-e,size:this.size})),i}},{key:"getPiePath",value:function(e){var t,i=e.me,a=e.startAngle,s=e.angle,n=e.size,o=new g(this.ctx),l=a,c=Math.PI*(l-90)/180,h=s+a;Math.ceil(h)>=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle&&(h=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle-.01),Math.ceil(h)>this.fullAngle&&(h-=this.fullAngle);var d=Math.PI*(h-90)/180,u=i.centerX+n*Math.cos(c),f=i.centerY+n*Math.sin(c),p=i.centerX+n*Math.cos(d),x=i.centerY+n*Math.sin(d),b=r.polarToCartesian(i.centerX,i.centerY,i.donutSize,h),v=r.polarToCartesian(i.centerX,i.centerY,i.donutSize,l),m=s>180?1:0,y=["M",u,f,"A",n,n,0,m,1,p,x];return t="donut"===i.chartType?[].concat(y,["L",b.x,b.y,"A",i.donutSize,i.donutSize,0,m,0,v.x,v.y,"L",u,f,"z"]).join(" "):"pie"===i.chartType||"polarArea"===i.chartType?[].concat(y,["L",i.centerX,i.centerY,"L",u,f]).join(" "):[].concat(y).join(" "),o.roundPathCorners(t,2*this.strokeWidth)}},{key:"drawPolarElements",value:function(e){var t=this.w,i=new ke(this.ctx),a=new g(this.ctx),r=new Di(this.ctx),s=a.group(),n=a.group(),o=i.niceScale(0,Math.ceil(this.maxY),0),l=o.result.reverse(),c=o.result.length;this.maxY=o.niceMax;for(var h=t.globals.radialSize,d=h/(c-1),u=0;u<c-1;u++){var f=a.drawCircle(h);if(f.attr({cx:this.centerX,cy:this.centerY,fill:"none","stroke-width":t.config.plotOptions.polarArea.rings.strokeWidth,stroke:t.config.plotOptions.polarArea.rings.strokeColor}),t.config.yaxis[0].show){var p=r.drawYAxisTexts(this.centerX,this.centerY-h+parseInt(t.config.yaxis[0].labels.style.fontSize,10)/2,u,l[u]);n.add(p)}s.add(f),h-=d}this.drawSpokes(e),e.add(s),e.add(n)}},{key:"renderInnerDataLabels",value:function(e,t,i){var a=this.w,r=new g(this.ctx),s=t.total.show;e.node.innerHTML="",e.node.style.opacity=i.opacity;var n,o,l=i.centerX,c=i.centerY;n=void 0===t.name.color?a.globals.colors[0]:t.name.color;var h=t.name.fontSize,d=t.name.fontFamily,u=t.name.fontWeight;o=void 0===t.value.color?a.config.chart.foreColor:t.value.color;var f=t.value.formatter,p="",x="";if(s?(n=t.total.color,h=t.total.fontSize,d=t.total.fontFamily,u=t.total.fontWeight,x=t.total.label,p=t.total.formatter(a)):1===a.globals.series.length&&(p=f(a.globals.series[0],a),x=a.globals.seriesNames[0]),x&&(x=t.name.formatter(x,t.total.show,a)),t.name.show){var b=r.drawText({x:l,y:c+parseFloat(t.name.offsetY),text:x,textAnchor:"middle",foreColor:n,fontSize:h,fontWeight:u,fontFamily:d});b.node.classList.add("apexcharts-datalabel-label"),e.add(b)}if(t.value.show){var v=t.name.show?parseFloat(t.value.offsetY)+16:t.value.offsetY,m=r.drawText({x:l,y:c+v,text:p,textAnchor:"middle",foreColor:o,fontWeight:t.value.fontWeight,fontSize:t.value.fontSize,fontFamily:t.value.fontFamily});m.node.classList.add("apexcharts-datalabel-value"),e.add(m)}return e}},{key:"printInnerLabels",value:function(e,t,i,a){var r,s=this.w;a?r=void 0===e.name.color?s.globals.colors[parseInt(a.parentNode.getAttribute("rel"),10)-1]:e.name.color:s.globals.series.length>1&&e.total.show&&(r=e.total.color);var n=s.globals.dom.baseEl.querySelector(".apexcharts-datalabel-label"),o=s.globals.dom.baseEl.querySelector(".apexcharts-datalabel-value");i=(0,e.value.formatter)(i,s),a||"function"!=typeof e.total.formatter||(i=e.total.formatter(s));var l=t===e.total.label;t=e.name.formatter(t,l,s),null!==n&&(n.textContent=t),null!==o&&(o.textContent=i),null!==n&&(n.style.fill=r)}},{key:"printDataLabelsInner",value:function(e,t){var i=this.w,a=e.getAttribute("data:value"),r=i.globals.seriesNames[parseInt(e.parentNode.getAttribute("rel"),10)-1];i.globals.series.length>1&&this.printInnerLabels(t,r,a,e);var s=i.globals.dom.baseEl.querySelector(".apexcharts-datalabels-group");null!==s&&(s.style.opacity=1)}},{key:"drawSpokes",value:function(e){var t=this,i=this.w,a=new g(this.ctx),s=i.config.plotOptions.polarArea.spokes;if(0!==s.strokeWidth){for(var n=[],o=360/i.globals.series.length,l=0;l<i.globals.series.length;l++)n.push(r.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize,i.config.plotOptions.pie.startAngle+o*l));n.forEach((function(i,r){var n=a.drawLine(i.x,i.y,t.centerX,t.centerY,Array.isArray(s.connectorColors)?s.connectorColors[r]:s.connectorColors);e.add(n)}))}}},{key:"revertDataLabelsInner",value:function(){var e=this.w;if(this.donutDataLabels.show){var t=e.globals.dom.Paper.select(".apexcharts-datalabels-group").members[0],i=this.renderInnerDataLabels(t,this.donutDataLabels,{hollowSize:this.donutSize,centerX:this.centerX,centerY:this.centerY,opacity:this.donutDataLabels.show});e.globals.dom.Paper.select(".apexcharts-radialbar, .apexcharts-pie").members[0].add(i)}}}])&&Ri(t.prototype,i),e}();function Hi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Ni(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Hi(Object(i),!0).forEach((function(t){Wi(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Hi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Wi(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Bi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ji=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(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 i=this.w;this.graphics=new g(this.ctx),this.lineColorArr=void 0!==i.globals.stroke.colors?i.globals.stroke.colors:i.globals.colors,this.defaultSize=i.globals.svgHeight<i.globals.svgWidth?i.globals.gridHeight+1.5*i.globals.goldenPadding:i.globals.gridWidth,this.isLog=i.config.yaxis[0].logarithmic,this.logBase=i.config.yaxis[0].logBase,this.coreUtils=new p(this.ctx),this.maxValue=this.isLog?this.coreUtils.getLogVal(this.logBase,i.globals.maxY,0):i.globals.maxY,this.minValue=this.isLog?this.coreUtils.getLogVal(this.logBase,this.w.globals.minY,0):i.globals.minY,this.polygons=i.config.plotOptions.radar.polygons,this.strokeWidth=i.config.stroke.show?i.config.stroke.width:0,this.size=this.defaultSize/2.1-this.strokeWidth-i.config.chart.dropShadow.blur,i.config.xaxis.labels.show&&(this.size=this.size-i.globals.xAxisLabelsWidth/1.75),void 0!==i.config.plotOptions.radar.size&&(this.size=i.config.plotOptions.radar.size),this.dataRadiusOfPercent=[],this.dataRadius=[],this.angleArr=[],this.yaxisLabelsTextsPos=[]}var t,i;return t=e,i=[{key:"draw",value:function(e){var t=this,i=this.w,a=new te(this.ctx),s=[],n=new oe(this.ctx);e.length&&(this.dataPointsLen=e[i.globals.maxValsInArrayIndex].length),this.disAngle=2*Math.PI/this.dataPointsLen;var o=i.globals.gridWidth/2,c=i.globals.gridHeight/2,h=o+i.config.plotOptions.radar.offsetX,d=c+i.config.plotOptions.radar.offsetY,u=this.graphics.group({class:"apexcharts-radar-series apexcharts-plot-series",transform:"translate(".concat(h||0,", ").concat(d||0,")")}),g=[],f=null,p=null;if(this.yaxisLabels=this.graphics.group({class:"apexcharts-yaxis"}),e.forEach((function(e,o){var c=e.length===i.globals.dataPoints,h=t.graphics.group().attr({class:"apexcharts-series","data:longestSeries":c,seriesName:r.escapeString(i.globals.seriesNames[o]),rel:o+1,"data:realIndex":o});t.dataRadiusOfPercent[o]=[],t.dataRadius[o]=[],t.angleArr[o]=[],e.forEach((function(e,i){var a=Math.abs(t.maxValue-t.minValue);e-=t.minValue,t.isLog&&(e=t.coreUtils.getLogVal(t.logBase,e,0)),t.dataRadiusOfPercent[o][i]=e/a,t.dataRadius[o][i]=t.dataRadiusOfPercent[o][i]*t.size,t.angleArr[o][i]=i*t.disAngle})),g=t.getDataPointsPos(t.dataRadius[o],t.angleArr[o]);var d=t.createPaths(g,{x:0,y:0});f=t.graphics.group({class:"apexcharts-series-markers-wrap apexcharts-element-hidden"}),p=t.graphics.group({class:"apexcharts-datalabels","data:realIndex":o}),i.globals.delayedElements.push({el:f.node,index:o});var u={i:o,realIndex:o,animationDelay:o,initialSpeed:i.config.chart.animations.speed,dataChangeSpeed:i.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-radar",shouldClipToGrid:!1,bindEventsOnPaths:!1,stroke:i.globals.stroke.colors[o],strokeLineCap:i.config.stroke.lineCap},x=null;i.globals.previousPaths.length>0&&(x=t.getPreviousPath(o));for(var b=0;b<d.linePathsTo.length;b++){var v=t.graphics.renderPaths(Ni(Ni({},u),{},{pathFrom:null===x?d.linePathsFrom[b]:x,pathTo:d.linePathsTo[b],strokeWidth:Array.isArray(t.strokeWidth)?t.strokeWidth[o]:t.strokeWidth,fill:"none",drawShadow:!1}));h.add(v);var m=a.fillPath({seriesNumber:o}),y=t.graphics.renderPaths(Ni(Ni({},u),{},{pathFrom:null===x?d.areaPathsFrom[b]:x,pathTo:d.areaPathsTo[b],strokeWidth:0,fill:m,drawShadow:!1}));if(i.config.chart.dropShadow.enabled){var w=new l(t.ctx),k=i.config.chart.dropShadow;w.dropShadow(y,Object.assign({},k,{noUserSpaceOnUse:!0}),o)}h.add(y)}e.forEach((function(e,a){var r=new ae(t.ctx).getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:o,dataPointIndex:a}),s=t.graphics.drawMarker(g[a].x,g[a].y,r);s.attr("rel",a),s.attr("j",a),s.attr("index",o),s.node.setAttribute("default-marker-size",r.pSize);var l=t.graphics.group({class:"apexcharts-series-markers"});l&&l.add(s),f.add(l),h.add(f);var c=i.config.dataLabels;if(c.enabled){var d=c.formatter(i.globals.series[o][a],{seriesIndex:o,dataPointIndex:a,w:i});n.plotDataLabelsText({x:g[a].x,y:g[a].y,text:d,textAnchor:"middle",i:o,j:o,parent:p,offsetCorrection:!1,dataLabelsConfig:Ni({},c)})}h.add(p)})),s.push(h)})),this.drawPolygons({parent:u}),i.config.xaxis.labels.show){var x=this.drawXAxisTexts();u.add(x)}return s.forEach((function(e){u.add(e)})),u.add(this.yaxisLabels),u}},{key:"drawPolygons",value:function(e){for(var t=this,i=this.w,a=e.parent,s=new Di(this.ctx),n=i.globals.yAxisScale[0].result.reverse(),o=n.length,l=[],c=this.size/(o-1),h=0;h<o;h++)l[h]=c*h;l.reverse();var d=[],u=[];l.forEach((function(e,i){var a=r.getPolygonPos(e,t.dataPointsLen),s="";a.forEach((function(e,a){if(0===i){var r=t.graphics.drawLine(e.x,e.y,0,0,Array.isArray(t.polygons.connectorColors)?t.polygons.connectorColors[a]:t.polygons.connectorColors);u.push(r)}0===a&&t.yaxisLabelsTextsPos.push({x:e.x,y:e.y}),s+=e.x+","+e.y+" "})),d.push(s)})),d.forEach((function(e,r){var s=t.polygons.strokeColors,n=t.polygons.strokeWidth,o=t.graphics.drawPolygon(e,Array.isArray(s)?s[r]:s,Array.isArray(n)?n[r]:n,i.globals.radarPolygons.fill.colors[r]);a.add(o)})),u.forEach((function(e){a.add(e)})),i.config.yaxis[0].show&&this.yaxisLabelsTextsPos.forEach((function(e,i){var a=s.drawYAxisTexts(e.x,e.y,i,n[i]);t.yaxisLabels.add(a)}))}},{key:"drawXAxisTexts",value:function(){var e=this,t=this.w,i=t.config.xaxis.labels,a=this.graphics.group({class:"apexcharts-xaxis"}),s=r.getPolygonPos(this.size,this.dataPointsLen);return t.globals.labels.forEach((function(r,n){var o=t.config.xaxis.labels.formatter,l=new oe(e.ctx);if(s[n]){var c=e.getTextPos(s[n],e.size),h=o(r,{seriesIndex:-1,dataPointIndex:n,w:t});l.plotDataLabelsText({x:c.newX,y:c.newY,text:h,textAnchor:c.textAnchor,i:n,j:n,parent:a,className:"apexcharts-xaxis-label",color:Array.isArray(i.style.colors)&&i.style.colors[n]?i.style.colors[n]:"#a8a8a8",dataLabelsConfig:Ni({textAnchor:c.textAnchor,dropShadow:{enabled:!1}},i),offsetCorrection:!1}).on("click",(function(i){if("function"==typeof t.config.chart.events.xAxisLabelClick){var a=Object.assign({},t,{labelIndex:n});t.config.chart.events.xAxisLabelClick(i,e.ctx,a)}}))}})),a}},{key:"createPaths",value:function(e,t){var i=this,a=[],r=[],s=[],n=[];if(e.length){r=[this.graphics.move(t.x,t.y)],n=[this.graphics.move(t.x,t.y)];var o=this.graphics.move(e[0].x,e[0].y),l=this.graphics.move(e[0].x,e[0].y);e.forEach((function(t,a){o+=i.graphics.line(t.x,t.y),l+=i.graphics.line(t.x,t.y),a===e.length-1&&(o+="Z",l+="Z")})),a.push(o),s.push(l)}return{linePathsFrom:r,linePathsTo:a,areaPathsFrom:n,areaPathsTo:s}}},{key:"getTextPos",value:function(e,t){var i="middle",a=e.x,r=e.y;return Math.abs(e.x)>=10?e.x>0?(i="start",a+=10):e.x<0&&(i="end",a-=10):i="middle",Math.abs(e.y)>=t-10&&(e.y<0?r-=10:e.y>0&&(r+=10)),{textAnchor:i,newX:a,newY:r}}},{key:"getPreviousPath",value:function(e){for(var t=this.w,i=null,a=0;a<t.globals.previousPaths.length;a++){var r=t.globals.previousPaths[a];r.paths.length>0&&parseInt(r.realIndex,10)===parseInt(e,10)&&void 0!==t.globals.previousPaths[a].paths[0]&&(i=t.globals.previousPaths[a].paths[0].d)}return i}},{key:"getDataPointsPos",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.dataPointsLen;e=e||[],t=t||[];for(var a=[],r=0;r<i;r++){var s={};s.x=e[r]*Math.sin(t[r]),s.y=-e[r]*Math.cos(t[r]),a.push(s)}return a}}],i&&Bi(t.prototype,i),e}();function Gi(e){return Gi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Gi(e)}function Vi(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function _i(e,t){return _i=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},_i(e,t)}function Ui(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function qi(e){return qi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},qi(e)}const Zi=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&_i(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=qi(a);if(s){var i=qi(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Gi(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Ui(e)}(this,e)});function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(t=n.call(this,e)).ctx=e,t.w=e.w,t.animBeginArr=[0],t.animDur=0;var i=t.w;return t.startAngle=i.config.plotOptions.radialBar.startAngle,t.endAngle=i.config.plotOptions.radialBar.endAngle,t.totalAngle=Math.abs(i.config.plotOptions.radialBar.endAngle-i.config.plotOptions.radialBar.startAngle),t.trackStartAngle=i.config.plotOptions.radialBar.track.startAngle,t.trackEndAngle=i.config.plotOptions.radialBar.track.endAngle,t.barLabels=t.w.config.plotOptions.radialBar.barLabels,t.donutDataLabels=t.w.config.plotOptions.radialBar.dataLabels,t.radialDataLabels=t.donutDataLabels,t.trackStartAngle||(t.trackStartAngle=t.startAngle),t.trackEndAngle||(t.trackEndAngle=t.endAngle),360===t.endAngle&&(t.endAngle=359.99),t.margin=parseInt(i.config.plotOptions.radialBar.track.margin,10),t.onBarLabelClick=t.onBarLabelClick.bind(Ui(t)),t}return t=o,(i=[{key:"draw",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-radialbar"});if(t.globals.noData)return a;var r=i.group(),s=this.defaultSize/2,n=t.globals.gridWidth/2,o=this.defaultSize/2.05;t.config.chart.sparkline.enabled||(o=o-t.config.stroke.width-t.config.chart.dropShadow.blur);var l=t.globals.fill.colors;if(t.config.plotOptions.radialBar.track.show){var c=this.drawTracks({size:o,centerX:n,centerY:s,colorArr:l,series:e});r.add(c)}var h=this.drawArcs({size:o,centerX:n,centerY:s,colorArr:l,series:e}),d=360;t.config.plotOptions.radialBar.startAngle<0&&(d=this.totalAngle);var u=(360-d)/360;if(t.globals.radialSize=o-o*u,this.radialDataLabels.value.show){var f=Math.max(this.radialDataLabels.value.offsetY,this.radialDataLabels.name.offsetY);t.globals.radialSize+=f*u}return r.add(h.g),"front"===t.config.plotOptions.radialBar.hollow.position&&(h.g.add(h.elHollow),h.dataLabels&&h.g.add(h.dataLabels)),a.add(r),a}},{key:"drawTracks",value:function(e){var t=this.w,i=new g(this.ctx),a=i.group({class:"apexcharts-tracks"}),r=new l(this.ctx),s=new te(this.ctx),n=this.getStrokeWidth(e);e.size=e.size-n/2;for(var o=0;o<e.series.length;o++){var c=i.group({class:"apexcharts-radialbar-track apexcharts-track"});a.add(c),c.attr({rel:o+1}),e.size=e.size-n-this.margin;var h=t.config.plotOptions.radialBar.track,d=s.fillPath({seriesNumber:0,size:e.size,fillColors:Array.isArray(h.background)?h.background[o]:h.background,solid:!0}),u=this.trackStartAngle,f=this.trackEndAngle;Math.abs(f)+Math.abs(u)>=360&&(f=360-Math.abs(this.startAngle)-.1);var p=i.drawPath({d:"",stroke:d,strokeWidth:n*parseInt(h.strokeWidth,10)/100,fill:"none",strokeOpacity:h.opacity,classes:"apexcharts-radialbar-area"});if(h.dropShadow.enabled){var x=h.dropShadow;r.dropShadow(p,x)}c.add(p),p.attr("id","apexcharts-radialbarTrack-"+o),this.animatePaths(p,{centerX:e.centerX,centerY:e.centerY,endAngle:f,startAngle:u,size:e.size,i:o,totalItems:2,animBeginArr:0,dur:0,isTrack:!0,easing:t.globals.easing})}return a}},{key:"drawArcs",value:function(e){var t=this.w,i=new g(this.ctx),a=new te(this.ctx),s=new l(this.ctx),n=i.group(),o=this.getStrokeWidth(e);e.size=e.size-o/2;var c=t.config.plotOptions.radialBar.hollow.background,h=e.size-o*e.series.length-this.margin*e.series.length-o*parseInt(t.config.plotOptions.radialBar.track.strokeWidth,10)/100/2,d=h-t.config.plotOptions.radialBar.hollow.margin;void 0!==t.config.plotOptions.radialBar.hollow.image&&(c=this.drawHollowImage(e,n,h,c));var u=this.drawHollow({size:d,centerX:e.centerX,centerY:e.centerY,fill:c||"transparent"});if(t.config.plotOptions.radialBar.hollow.dropShadow.enabled){var f=t.config.plotOptions.radialBar.hollow.dropShadow;s.dropShadow(u,f)}var p=1;!this.radialDataLabels.total.show&&t.globals.series.length>1&&(p=0);var x=null;if(this.radialDataLabels.show){var b=t.globals.dom.Paper.select(".apexcharts-datalabels-group").members[0];x=this.renderInnerDataLabels(b,this.radialDataLabels,{hollowSize:h,centerX:e.centerX,centerY:e.centerY,opacity:p})}"back"===t.config.plotOptions.radialBar.hollow.position&&(n.add(u),x&&n.add(x));var v=!1;t.config.plotOptions.radialBar.inverseOrder&&(v=!0);for(var m=v?e.series.length-1:0;v?m>=0:m<e.series.length;v?m--:m++){var y=i.group({class:"apexcharts-series apexcharts-radial-series",seriesName:r.escapeString(t.globals.seriesNames[m])});n.add(y),y.attr({rel:m+1,"data:realIndex":m}),this.ctx.series.addCollapsedClassToSeries(y,m),e.size=e.size-o-this.margin;var w=a.fillPath({seriesNumber:m,size:e.size,value:e.series[m]}),k=this.startAngle,A=void 0,S=r.negToZero(e.series[m]>100?100:e.series[m])/100,C=Math.round(this.totalAngle*S)+this.startAngle,P=void 0;t.globals.dataChanged&&(A=this.startAngle,P=Math.round(this.totalAngle*r.negToZero(t.globals.previousPaths[m])/100)+A),Math.abs(C)+Math.abs(k)>=360&&(C-=.01),Math.abs(P)+Math.abs(A)>=360&&(P-=.01);var L=C-k,O=Array.isArray(t.config.stroke.dashArray)?t.config.stroke.dashArray[m]:t.config.stroke.dashArray,M=i.drawPath({d:"",stroke:w,strokeWidth:o,fill:"none",fillOpacity:t.config.fill.opacity,classes:"apexcharts-radialbar-area apexcharts-radialbar-slice-"+m,strokeDashArray:O});if(g.setAttrs(M.node,{"data:angle":L,"data:value":e.series[m]}),t.config.chart.dropShadow.enabled){var T=t.config.chart.dropShadow;s.dropShadow(M,T,m)}if(s.setSelectionFilter(M,0,m),this.addListeners(M,this.radialDataLabels),y.add(M),M.attr({index:0,j:m}),this.barLabels.enabled){var I=r.polarToCartesian(e.centerX,e.centerY,e.size,k),E=this.barLabels.formatter(t.globals.seriesNames[m],{seriesIndex:m,w:t}),z=["apexcharts-radialbar-label"];this.barLabels.onClick||z.push("apexcharts-no-click");var X=this.barLabels.useSeriesColors?t.globals.colors[m]:t.config.chart.foreColor;X||(X=t.config.chart.foreColor);var Y=I.x+this.barLabels.offsetX,D=I.y+this.barLabels.offsetY,R=i.drawText({x:Y,y:D,text:E,textAnchor:"end",dominantBaseline:"middle",fontFamily:this.barLabels.fontFamily,fontWeight:this.barLabels.fontWeight,fontSize:this.barLabels.fontSize,foreColor:X,cssClass:z.join(" ")});R.on("click",this.onBarLabelClick),R.attr({rel:m+1}),0!==k&&R.attr({"transform-origin":"".concat(Y," ").concat(D),transform:"rotate(".concat(k," 0 0)")}),y.add(R)}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(M,{centerX:e.centerX,centerY:e.centerY,endAngle:C,startAngle:k,prevEndAngle:P,prevStartAngle:A,size:e.size,i:m,totalItems:2,animBeginArr:this.animBeginArr,dur:F,shouldSetPrevPaths:!0,easing:t.globals.easing})}return{g:n,elHollow:u,dataLabels:x}}},{key:"drawHollow",value:function(e){var t=new g(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,i,a){var s=this.w,n=new te(this.ctx),o=r.randomId(),l=s.config.plotOptions.radialBar.hollow.image;if(s.config.plotOptions.radialBar.hollow.imageClipped)n.clippedImgArea({width:i,height:i,image:l,patternID:"pattern".concat(s.globals.cuid).concat(o)}),a="url(#pattern".concat(s.globals.cuid).concat(o,")");else{var c=s.config.plotOptions.radialBar.hollow.imageWidth,h=s.config.plotOptions.radialBar.hollow.imageHeight;if(void 0===c&&void 0===h){var d=s.globals.dom.Paper.image(l).loaded((function(t){this.move(e.centerX-t.width/2+s.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-t.height/2+s.config.plotOptions.radialBar.hollow.imageOffsetY)}));t.add(d)}else{var u=s.globals.dom.Paper.image(l).loaded((function(t){this.move(e.centerX-c/2+s.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-h/2+s.config.plotOptions.radialBar.hollow.imageOffsetY),this.size(c,h)}));t.add(u)}}return a}},{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,i=this.barLabels.onClick,a=this.w;i&&i(a.globals.seriesNames[t],{w:a,seriesIndex:t})}}])&&Vi(t.prototype,i),o}(Fi);function $i(e){return $i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$i(e)}function Ji(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Qi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ji(Object(i),!0).forEach((function(t){Ki(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ji(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Ki(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ea(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function ta(e,t){return ta=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ta(e,t)}function ia(e){return ia=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},ia(e)}const aa=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ta(e,t)}(o,e);var t,i,a,s,n=(a=o,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=ia(a);if(s){var i=ia(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===$i(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),n.apply(this,arguments)}return t=o,(i=[{key:"draw",value:function(e,t){var i=this.w,a=new g(this.ctx);this.rangeBarOptions=this.w.config.plotOptions.rangeBar,this.series=e,this.seriesRangeStart=i.globals.seriesRangeStart,this.seriesRangeEnd=i.globals.seriesRangeEnd,this.barHelpers.initVariables(e);for(var s=a.group({class:"apexcharts-rangebar-series apexcharts-plot-series"}),n=0;n<e.length;n++){var o,l,c,h,d=void 0,u=void 0,f=i.globals.comboCharts?t[n]:n,p=this.barHelpers.getGroupIndex(f).columnGroupIndex,x=a.group({class:"apexcharts-series",seriesName:r.escapeString(i.globals.seriesNames[f]),rel:n+1,"data:realIndex":f});this.ctx.series.addCollapsedClassToSeries(x,f),e[n].length>0&&(this.visibleI=this.visibleI+1);var b=0,v=0,m=0;this.yRatio.length>1&&(this.yaxisIndex=i.globals.seriesYAxisReverseMap[f][0],m=f);var y=this.barHelpers.initialPositions();u=y.y,h=y.zeroW,d=y.x,v=y.barWidth,b=y.barHeight,o=y.xDivision,l=y.yDivision,c=y.zeroH;for(var w=a.group({class:"apexcharts-datalabels","data:realIndex":f}),k=a.group({class:"apexcharts-rangebar-goals-markers"}),A=0;A<i.globals.dataPoints;A++){var S=this.barHelpers.getStrokeWidth(n,A,f),C=this.seriesRangeStart[n][A],P=this.seriesRangeEnd[n][A],L=null,O=null,M=null,T={x:d,y:u,strokeWidth:S,elSeries:x},I=this.seriesLen;if(i.config.plotOptions.bar.rangeBarGroupRows&&(I=1),void 0===i.config.series[n].data[A])break;if(this.isHorizontal){M=u+b*this.visibleI;var E=(l-b*I)/2;if(i.config.series[n].data[A].x){var z=this.detectOverlappingBars({i:n,j:A,barYPosition:M,srty:E,barHeight:b,yDivision:l,initPositions:y});b=z.barHeight,M=z.barYPosition}v=(L=this.drawRangeBarPaths(Qi({indexes:{i:n,j:A,realIndex:f},barHeight:b,barYPosition:M,zeroW:h,yDivision:l,y1:C,y2:P},T))).barWidth}else{i.globals.isXNumeric&&(d=(i.globals.seriesX[n][A]-i.globals.minX)/this.xRatio-v/2),O=d+v*this.visibleI;var X=(o-v*I)/2;if(i.config.series[n].data[A].x){var Y=this.detectOverlappingBars({i:n,j:A,barXPosition:O,srtx:X,barWidth:v,xDivision:o,initPositions:y});v=Y.barWidth,O=Y.barXPosition}b=(L=this.drawRangeColumnPaths(Qi({indexes:{i:n,j:A,realIndex:f,translationsIndex:m},barWidth:v,barXPosition:O,zeroH:c,xDivision:o},T))).barHeight}var D=this.barHelpers.drawGoalLine({barXPosition:L.barXPosition,barYPosition:M,goalX:L.goalX,goalY:L.goalY,barHeight:b,barWidth:v});D&&k.add(D),u=L.y,d=L.x;var R=this.barHelpers.getPathFillColor(e,n,A,f),F=i.globals.stroke.colors[f];this.renderSeries({realIndex:f,pathFill:R,lineFill:F,j:A,i:n,x:d,y:u,y1:C,y2:P,pathFrom:L.pathFrom,pathTo:L.pathTo,strokeWidth:S,elSeries:x,series:e,barHeight:b,barWidth:v,barXPosition:O,barYPosition:M,columnGroupIndex:p,elDataLabelsWrap:w,elGoalsMarkers:k,visibleSeries:this.visibleI,type:"rangebar"})}s.add(x)}return s}},{key:"detectOverlappingBars",value:function(e){var t=e.i,i=e.j,a=e.barYPosition,r=e.barXPosition,s=e.srty,n=e.srtx,o=e.barHeight,l=e.barWidth,c=e.yDivision,h=e.xDivision,d=e.initPositions,u=this.w,g=[],f=u.config.series[t].data[i].rangeName,p=u.config.series[t].data[i].x,x=Array.isArray(p)?p.join(" "):p,b=u.globals.labels.map((function(e){return Array.isArray(e)?e.join(" "):e})).indexOf(x),v=u.globals.seriesRange[t].findIndex((function(e){return e.x===x&&e.overlaps.length>0}));return this.isHorizontal?(a=u.config.plotOptions.bar.rangeBarGroupRows?s+c*b:s+o*this.visibleI+c*b,v>-1&&!u.config.plotOptions.bar.rangeBarOverlap&&(g=u.globals.seriesRange[t][v].overlaps).indexOf(f)>-1&&(a=(o=d.barHeight/g.length)*this.visibleI+c*(100-parseInt(this.barOptions.barHeight,10))/100/2+o*(this.visibleI+g.indexOf(f))+c*b)):(b>-1&&!u.globals.timescaleLabels.length&&(r=u.config.plotOptions.bar.rangeBarGroupRows?n+h*b:n+l*this.visibleI+h*b),v>-1&&!u.config.plotOptions.bar.rangeBarOverlap&&(g=u.globals.seriesRange[t][v].overlaps).indexOf(f)>-1&&(r=(l=d.barWidth/g.length)*this.visibleI+h*(100-parseInt(this.barOptions.barWidth,10))/100/2+l*(this.visibleI+g.indexOf(f))+h*b)),{barYPosition:a,barXPosition:r,barHeight:o,barWidth:l}}},{key:"drawRangeColumnPaths",value:function(e){var t=e.indexes,i=e.x,a=e.xDivision,r=e.barWidth,s=e.barXPosition,n=e.zeroH,o=this.w,l=t.i,c=t.j,h=t.realIndex,d=t.translationsIndex,u=this.yRatio[d],g=this.getRangeValue(h,c),f=Math.min(g.start,g.end),p=Math.max(g.start,g.end);void 0===this.series[l][c]||null===this.series[l][c]?f=n:(f=n-f/u,p=n-p/u);var x=Math.abs(p-f),b=this.barHelpers.getColumnPaths({barXPosition:s,barWidth:r,y1:f,y2:p,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,realIndex:h,i:h,j:c,w:o});if(o.globals.isXNumeric){var v=this.getBarXForNumericXAxis({x:i,j:c,realIndex:h,barWidth:r});i=v.x,s=v.barXPosition}else i+=a;return{pathTo:b.pathTo,pathFrom:b.pathFrom,barHeight:x,x:i,y:g.start<0&&g.end<0?f:p,goalY:this.barHelpers.getGoalValues("y",null,n,l,c,d),barXPosition:s}}},{key:"preventBarOverflow",value:function(e){var t=this.w;return e<0&&(e=0),e>t.globals.gridWidth&&(e=t.globals.gridWidth),e}},{key:"drawRangeBarPaths",value:function(e){var t=e.indexes,i=e.y,a=e.y1,r=e.y2,s=e.yDivision,n=e.barHeight,o=e.barYPosition,l=e.zeroW,c=this.w,h=t.realIndex,d=t.j,u=this.preventBarOverflow(l+a/this.invertedYRatio),g=this.preventBarOverflow(l+r/this.invertedYRatio),f=this.getRangeValue(h,d),p=Math.abs(g-u),x=this.barHelpers.getBarpaths({barYPosition:o,barHeight:n,x1:u,x2:g,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,i:h,realIndex:h,j:d,w:c});return c.globals.isXNumeric||(i+=s),{pathTo:x.pathTo,pathFrom:x.pathFrom,barWidth:p,x:f.start<0&&f.end<0?u:g,goalX:this.barHelpers.getGoalValues("x",l,null,h,d),y:i}}},{key:"getRangeValue",value:function(e,t){var i=this.w;return{start:i.globals.seriesRangeStart[e][t],end:i.globals.seriesRangeEnd[e][t]}}}])&&ea(t.prototype,i),o}(ui);function ra(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var sa=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.w=t.w,this.lineCtx=t}var t,i;return t=e,(i=[{key:"sameValueSeriesFix",value:function(e,t){var i=this.w;if(("gradient"===i.config.fill.type||"gradient"===i.config.fill.type[e])&&new p(this.lineCtx.ctx,i).seriesHaveSameValues(e)){var a=t[e].slice();a[a.length-1]=a[a.length-1]+1e-6,t[e]=a}return t}},{key:"calculatePoints",value:function(e){var t=e.series,i=e.realIndex,a=e.x,s=e.y,n=e.i,o=e.j,l=e.prevY,c=this.w,h=[],d=[];if(0===o){var u=this.lineCtx.categoryAxisCorrection+c.config.markers.offsetX;c.globals.isXNumeric&&(u=(c.globals.seriesX[i][0]-c.globals.minX)/this.lineCtx.xRatio+c.config.markers.offsetX),h.push(u),d.push(r.isNumber(t[n][0])?l+c.config.markers.offsetY:null),h.push(a+c.config.markers.offsetX),d.push(r.isNumber(t[n][o+1])?s+c.config.markers.offsetY:null)}else h.push(a+c.config.markers.offsetX),d.push(r.isNumber(t[n][o+1])?s+c.config.markers.offsetY:null);return{x:h,y:d}}},{key:"checkPreviousPaths",value:function(e){for(var t=e.pathFromLine,i=e.pathFromArea,a=e.realIndex,r=this.w,s=0;s<r.globals.previousPaths.length;s++){var n=r.globals.previousPaths[s];("line"===n.type||"area"===n.type)&&n.paths.length>0&&parseInt(n.realIndex,10)===parseInt(a,10)&&("line"===n.type?(this.lineCtx.appendPathFrom=!1,t=r.globals.previousPaths[s].paths[0].d):"area"===n.type&&(this.lineCtx.appendPathFrom=!1,i=r.globals.previousPaths[s].paths[0].d,r.config.stroke.show&&r.globals.previousPaths[s].paths[1]&&(t=r.globals.previousPaths[s].paths[1].d)))}return{pathFromLine:t,pathFromArea:i}}},{key:"determineFirstPrevY",value:function(e){var t,i,a,r=e.i,s=e.realIndex,n=e.series,o=e.prevY,l=e.lineYPosition,c=e.translationsIndex,h=this.w,d=h.config.chart.stacked&&!h.globals.comboCharts||h.config.chart.stacked&&h.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||"bar"===(null===(t=this.w.config.series[s])||void 0===t?void 0:t.type)||"column"===(null===(i=this.w.config.series[s])||void 0===i?void 0:i.type));if(void 0!==(null===(a=n[r])||void 0===a?void 0:a[0]))o=(l=d&&r>0?this.lineCtx.prevSeriesY[r-1][0]:this.lineCtx.zeroY)-n[r][0]/this.lineCtx.yRatio[c]+2*(this.lineCtx.isReversed?n[r][0]/this.lineCtx.yRatio[c]:0);else if(d&&r>0&&void 0===n[r][0])for(var u=r-1;u>=0;u--)if(null!==n[u][0]&&void 0!==n[u][0]){o=l=this.lineCtx.prevSeriesY[u][0];break}return{prevY:o,lineYPosition:l}}}])&&ra(t.prototype,i),e}(),na=function(e){var t=function(e){for(var t,i,a,r,s=function(e){for(var t=[],i=e[0],a=e[1],r=t[0]=la(i,a),s=1,n=e.length-1;s<n;s++)i=a,a=e[s+1],t[s]=.5*(r+(r=la(i,a)));return t[s]=r,t}(e),n=e.length-1,o=[],l=0;l<n;l++)a=la(e[l],e[l+1]),Math.abs(a)<1e-6?s[l]=s[l+1]=0:(r=(t=s[l]/a)*t+(i=s[l+1]/a)*i)>9&&(r=3*a/Math.sqrt(r),s[l]=r*t,s[l+1]=r*i);for(var c=0;c<=n;c++)r=(e[Math.min(n,c+1)][0]-e[Math.max(0,c-1)][0])/(6*(1+s[c]*s[c])),o.push([r||0,s[c]*r||0]);return o}(e),i=e[1],a=e[0],r=[],s=t[1],n=t[0];r.push(a,[a[0]+n[0],a[1]+n[1],i[0]-s[0],i[1]-s[1],i[0],i[1]]);for(var o=2,l=t.length;o<l;o++){var c=e[o],h=t[o];r.push([c[0]-h[0],c[1]-h[1],c[0],c[1]])}return r},oa=function(e,t,i){var a=e.slice(t,i);if(t){if(i-t>1&&a[1].length<6){var r=a[0].length;a[1]=[2*a[0][r-2]-a[0][r-4],2*a[0][r-1]-a[0][r-3]].concat(a[1])}a[0]=a[0].slice(-2)}return a};function la(e,t){return(t[1]-e[1])/(t[0]-e[0])}function ca(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ha(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ca(Object(i),!0).forEach((function(t){da(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ca(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function da(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ua(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ga=function(){function e(t,i,a){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.xyRatios=i,this.pointsChart=!("bubble"!==this.w.config.chart.type&&"scatter"!==this.w.config.chart.type)||a,this.scatter=new se(this.ctx),this.noNegatives=this.w.globals.minX===Number.MAX_VALUE,this.lineHelpers=new sa(this),this.markers=new ae(this.ctx),this.prevSeriesY=[],this.categoryAxisCorrection=0,this.yaxisIndex=0}var t,i;return t=e,(i=[{key:"draw",value:function(e,t,i,a){var r,s=this.w,n=new g(this.ctx),o=s.globals.comboCharts?t:s.config.chart.type,l=n.group({class:"apexcharts-".concat(o,"-series apexcharts-plot-series")}),c=new p(this.ctx,s);this.yRatio=this.xyRatios.yRatio,this.zRatio=this.xyRatios.zRatio,this.xRatio=this.xyRatios.xRatio,this.baseLineY=this.xyRatios.baseLineY,e=c.getLogSeries(e),this.yRatio=c.getLogYRatios(this.yRatio),this.prevSeriesY=[];for(var h=[],d=0;d<e.length;d++){e=this.lineHelpers.sameValueSeriesFix(d,e);var u=s.globals.comboCharts?i[d]:d,f=this.yRatio.length>1?u:0;this._initSerieVariables(e,d,u);var x=[],b=[],v=[],m=s.globals.padHorizontal+this.categoryAxisCorrection;this.ctx.series.addCollapsedClassToSeries(this.elSeries,u),s.globals.isXNumeric&&s.globals.seriesX.length>0&&(m=(s.globals.seriesX[u][0]-s.globals.minX)/this.xRatio),v.push(m);var y,w=m,k=void 0,A=w,S=this.zeroY,C=this.zeroY;S=this.lineHelpers.determineFirstPrevY({i:d,realIndex:u,series:e,prevY:S,lineYPosition:0,translationsIndex:f}).prevY,"monotoneCubic"===s.config.stroke.curve&&null===e[d][0]?x.push(null):x.push(S),y=S,"rangeArea"===o&&(k=C=this.lineHelpers.determineFirstPrevY({i:d,realIndex:u,series:a,prevY:C,lineYPosition:0,translationsIndex:f}).prevY,b.push(null!==x[0]?C:null));var P=this._calculatePathsFrom({type:o,series:e,i:d,realIndex:u,translationsIndex:f,prevX:A,prevY:S,prevY2:C}),L=[x[0]],O=[b[0]],M={type:o,series:e,realIndex:u,translationsIndex:f,i:d,x:m,y:1,pX:w,pY:y,pathsFrom:P,linePaths:[],areaPaths:[],seriesIndex:i,lineYPosition:0,xArrj:v,yArrj:x,y2Arrj:b,seriesRangeEnd:a},T=this._iterateOverDataPoints(ha(ha({},M),{},{iterations:"rangeArea"===o?e[d].length-1:void 0,isRangeStart:!0}));if("rangeArea"===o){for(var I=this._calculatePathsFrom({series:a,i:d,realIndex:u,prevX:A,prevY:C}),E=this._iterateOverDataPoints(ha(ha({},M),{},{series:a,xArrj:[m],yArrj:L,y2Arrj:O,pY:k,areaPaths:T.areaPaths,pathsFrom:I,iterations:a[d].length-1,isRangeStart:!1})),z=T.linePaths.length/2,X=0;X<z;X++)T.linePaths[X]=E.linePaths[X+z]+T.linePaths[X];T.linePaths.splice(z),T.pathFromLine=E.pathFromLine+T.pathFromLine}else T.pathFromArea+="z";this._handlePaths({type:o,realIndex:u,i:d,paths:T}),this.elSeries.add(this.elPointsMain),this.elSeries.add(this.elDataLabelsWrap),h.push(this.elSeries)}if(void 0!==(null===(r=s.config.series[0])||void 0===r?void 0:r.zIndex)&&h.sort((function(e,t){return Number(e.node.getAttribute("zIndex"))-Number(t.node.getAttribute("zIndex"))})),s.config.chart.stacked)for(var Y=h.length-1;Y>=0;Y--)l.add(h[Y]);else for(var D=0;D<h.length;D++)l.add(h[D]);return l}},{key:"_initSerieVariables",value:function(e,t,i){var a=this.w,s=new g(this.ctx);this.xDivision=a.globals.gridWidth/(a.globals.dataPoints-("on"===a.config.xaxis.tickPlacement?1:0)),this.strokeWidth=Array.isArray(a.config.stroke.width)?a.config.stroke.width[i]:a.config.stroke.width;var n=0;this.yRatio.length>1&&(this.yaxisIndex=a.globals.seriesYAxisReverseMap[i],n=i),this.isReversed=a.config.yaxis[this.yaxisIndex]&&a.config.yaxis[this.yaxisIndex].reversed,this.zeroY=a.globals.gridHeight-this.baseLineY[n]-(this.isReversed?a.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[n]:0),this.areaBottomY=this.zeroY,(this.zeroY>a.globals.gridHeight||"end"===a.config.plotOptions.area.fillTo)&&(this.areaBottomY=a.globals.gridHeight),this.categoryAxisCorrection=this.xDivision/2,this.elSeries=s.group({class:"apexcharts-series",zIndex:void 0!==a.config.series[i].zIndex?a.config.series[i].zIndex:i,seriesName:r.escapeString(a.globals.seriesNames[i])}),this.elPointsMain=s.group({class:"apexcharts-series-markers-wrap","data:realIndex":i}),this.elDataLabelsWrap=s.group({class:"apexcharts-datalabels","data:realIndex":i});var o=e[t].length===a.globals.dataPoints;this.elSeries.attr({"data:longestSeries":o,rel:t+1,"data:realIndex":i}),this.appendPathFrom=!0}},{key:"_calculatePathsFrom",value:function(e){var t,i,a,r,s=e.type,n=e.series,o=e.i,l=e.realIndex,c=e.translationsIndex,h=e.prevX,d=e.prevY,u=e.prevY2,f=this.w,p=new g(this.ctx);if(null===n[o][0]){for(var x=0;x<n[o].length;x++)if(null!==n[o][x]){h=this.xDivision*x,d=this.zeroY-n[o][x]/this.yRatio[c],t=p.move(h,d),i=p.move(h,this.areaBottomY);break}}else t=p.move(h,d),"rangeArea"===s&&(t=p.move(h,u)+p.line(h,d)),i=p.move(h,this.areaBottomY)+p.line(h,d);if(a=p.move(0,this.zeroY)+p.line(0,this.zeroY),r=p.move(0,this.zeroY)+p.line(0,this.zeroY),f.globals.previousPaths.length>0){var b=this.lineHelpers.checkPreviousPaths({pathFromLine:a,pathFromArea:r,realIndex:l});a=b.pathFromLine,r=b.pathFromArea}return{prevX:h,prevY:d,linePath:t,areaPath:i,pathFromLine:a,pathFromArea:r}}},{key:"_handlePaths",value:function(e){var t=e.type,i=e.realIndex,a=e.i,r=e.paths,s=this.w,n=new g(this.ctx),o=new te(this.ctx);this.prevSeriesY.push(r.yArrj),s.globals.seriesXvalues[i]=r.xArrj,s.globals.seriesYvalues[i]=r.yArrj;var l=s.config.forecastDataPoints;if(l.count>0&&"rangeArea"!==t){var c=s.globals.seriesXvalues[i][s.globals.seriesXvalues[i].length-l.count-1],h=n.drawRect(c,0,s.globals.gridWidth,s.globals.gridHeight,0);s.globals.dom.elForecastMask.appendChild(h.node);var d=n.drawRect(0,0,c,s.globals.gridHeight,0);s.globals.dom.elNonForecastMask.appendChild(d.node)}this.pointsChart||s.globals.delayedElements.push({el:this.elPointsMain.node,index:i});var u={i:a,realIndex:i,animationDelay:a,initialSpeed:s.config.chart.animations.speed,dataChangeSpeed:s.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(t)};if("area"===t)for(var f=o.fillPath({seriesNumber:i}),p=0;p<r.areaPaths.length;p++){var x=n.renderPaths(ha(ha({},u),{},{pathFrom:r.pathFromArea,pathTo:r.areaPaths[p],stroke:"none",strokeWidth:0,strokeLineCap:null,fill:f}));this.elSeries.add(x)}if(s.config.stroke.show&&!this.pointsChart){var b=null;if("line"===t)b=o.fillPath({seriesNumber:i,i:a});else if("solid"===s.config.stroke.fill.type)b=s.globals.stroke.colors[i];else{var v=s.config.fill;s.config.fill=s.config.stroke.fill,b=o.fillPath({seriesNumber:i,i:a}),s.config.fill=v}for(var m=0;m<r.linePaths.length;m++){var y=b;"rangeArea"===t&&(y=o.fillPath({seriesNumber:i}));var w=ha(ha({},u),{},{pathFrom:r.pathFromLine,pathTo:r.linePaths[m],stroke:b,strokeWidth:this.strokeWidth,strokeLineCap:s.config.stroke.lineCap,fill:"rangeArea"===t?y:"none"}),k=n.renderPaths(w);if(this.elSeries.add(k),k.attr("fill-rule","evenodd"),l.count>0&&"rangeArea"!==t){var A=n.renderPaths(w);A.node.setAttribute("stroke-dasharray",l.dashArray),l.strokeWidth&&A.node.setAttribute("stroke-width",l.strokeWidth),this.elSeries.add(A),A.attr("clip-path","url(#forecastMask".concat(s.globals.cuid,")")),k.attr("clip-path","url(#nonForecastMask".concat(s.globals.cuid,")"))}}}}},{key:"_iterateOverDataPoints",value:function(e){var t,i,a=this,s=e.type,n=e.series,o=e.iterations,l=e.realIndex,c=e.translationsIndex,h=e.i,d=e.x,u=e.y,f=e.pX,p=e.pY,x=e.pathsFrom,b=e.linePaths,v=e.areaPaths,m=e.seriesIndex,y=e.lineYPosition,w=e.xArrj,k=e.yArrj,A=e.y2Arrj,S=e.isRangeStart,C=e.seriesRangeEnd,P=this.w,L=new g(this.ctx),O=this.yRatio,M=x.prevY,T=x.linePath,I=x.areaPath,E=x.pathFromLine,z=x.pathFromArea,X=r.isNumber(P.globals.minYArr[l])?P.globals.minYArr[l]:P.globals.minY;o||(o=P.globals.dataPoints>1?P.globals.dataPoints-1:P.globals.dataPoints);var Y=function(e,t){return t-e/O[c]+2*(a.isReversed?e/O[c]:0)},D=u,R=P.config.chart.stacked&&!P.globals.comboCharts||P.config.chart.stacked&&P.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||"bar"===(null===(t=this.w.config.series[l])||void 0===t?void 0:t.type)||"column"===(null===(i=this.w.config.series[l])||void 0===i?void 0:i.type)),F=P.config.stroke.curve;Array.isArray(F)&&(F=Array.isArray(m)?F[m[h]]:F[h]);for(var H,N=0,W=0;W<o;W++){var B=void 0===n[h][W+1]||null===n[h][W+1];if(P.globals.isXNumeric){var j=P.globals.seriesX[l][W+1];void 0===P.globals.seriesX[l][W+1]&&(j=P.globals.seriesX[l][o-1]),d=(j-P.globals.minX)/this.xRatio}else d+=this.xDivision;y=R&&h>0&&P.globals.collapsedSeries.length<P.config.series.length-1?this.prevSeriesY[function(e){for(var t=e;t>0;t--){if(!(P.globals.collapsedSeriesIndices.indexOf((null==m?void 0:m[t])||t)>-1))return t;t--}return 0}(h-1)][W+1]:this.zeroY,B?u=Y(X,y):(u=Y(n[h][W+1],y),"rangeArea"===s&&(D=Y(C[h][W+1],y))),w.push(d),!B||"smooth"!==P.config.stroke.curve&&"monotoneCubic"!==P.config.stroke.curve?(k.push(u),A.push(D)):(k.push(null),A.push(null));var G=this.lineHelpers.calculatePoints({series:n,x:d,y:u,realIndex:l,i:h,j:W,prevY:M}),V=this._createPaths({type:s,series:n,i:h,realIndex:l,j:W,x:d,y:u,y2:D,xArrj:w,yArrj:k,y2Arrj:A,pX:f,pY:p,pathState:N,segmentStartX:H,linePath:T,areaPath:I,linePaths:b,areaPaths:v,curve:F,isRangeStart:S});v=V.areaPaths,b=V.linePaths,f=V.pX,p=V.pY,N=V.pathState,H=V.segmentStartX,I=V.areaPath,T=V.linePath,!this.appendPathFrom||"monotoneCubic"===F&&"rangeArea"===s||(E+=L.line(d,this.zeroY),z+=L.line(d,this.zeroY)),this.handleNullDataPoints(n,G,h,W,l),this._handleMarkersAndLabels({type:s,pointsPos:G,i:h,j:W,realIndex:l,isRangeStart:S})}return{yArrj:k,xArrj:w,pathFromArea:z,areaPaths:v,pathFromLine:E,linePaths:b,linePath:T,areaPath:I}}},{key:"_handleMarkersAndLabels",value:function(e){var t=e.type,i=e.pointsPos,a=e.isRangeStart,r=e.i,s=e.j,n=e.realIndex,o=this.w,l=new oe(this.ctx);if(this.pointsChart)this.scatter.draw(this.elSeries,s,{realIndex:n,pointsPos:i,zRatio:this.zRatio,elParent:this.elPointsMain});else{o.globals.series[r].length>1&&this.elPointsMain.node.classList.add("apexcharts-element-hidden");var c=this.markers.plotChartMarkers(i,n,s+1);null!==c&&this.elPointsMain.add(c)}var h=l.drawDataLabel({type:t,isRangeStart:a,pos:i,i:n,j:s+1});null!==h&&this.elDataLabelsWrap.add(h)}},{key:"_createPaths",value:function(e){var t,i=e.type,a=e.series,r=e.i,s=(e.realIndex,e.j),n=e.x,o=e.y,l=e.xArrj,c=e.yArrj,h=e.y2,d=e.y2Arrj,u=e.pX,f=e.pY,p=e.pathState,x=e.segmentStartX,b=e.linePath,v=e.areaPath,m=e.linePaths,y=e.areaPaths,w=e.curve,k=e.isRangeStart,A=(this.w,new g(this.ctx)),S=this.areaBottomY,C="rangeArea"===i,P="rangeArea"===i&&k;switch(w){case"monotoneCubic":var L=k?c:d;switch(p){case 0:if(null===L[s+1])break;p=1;case 1:if(!(C?l.length===a[r].length:s===a[r].length-2))break;case 2:var O=k?l:l.slice().reverse(),M=k?L:L.slice().reverse(),T=(t=M,O.map((function(e,i){return[e,t[i]]})).filter((function(e){return null!==e[1]}))),I=T.length>1?na(T):T,E=[];C&&(P?y=T:E=y.reverse());var z=0,X=0;if(function(e,t){for(var i=function(e){var t=[],i=0;return e.forEach((function(e){null!==e?i++:i>0&&(t.push(i),i=0)})),i>0&&t.push(i),t}(e),a=[],r=0,s=0;r<i.length;s+=i[r++])a[r]=oa(t,s,s+i[r]);return a}(M,I).forEach((function(e){z++;var t=function(e){for(var t="",i=0;i<e.length;i++){var a=e[i],r=a.length;r>4?(t+="C".concat(a[0],", ").concat(a[1]),t+=", ".concat(a[2],", ").concat(a[3]),t+=", ".concat(a[4],", ").concat(a[5])):r>2&&(t+="S".concat(a[0],", ").concat(a[1]),t+=", ".concat(a[2],", ").concat(a[3]))}return t}(e),i=X,a=(X+=e.length)-1;P?b=A.move(T[i][0],T[i][1])+t:C?b=A.move(E[i][0],E[i][1])+A.line(T[i][0],T[i][1])+t+A.line(E[a][0],E[a][1]):(b=A.move(T[i][0],T[i][1])+t,v=b+A.line(T[a][0],S)+A.line(T[i][0],S)+"z",y.push(v)),m.push(b)})),C&&z>1&&!P){var Y=m.slice(z).reverse();m.splice(z),Y.forEach((function(e){return m.push(e)}))}p=0}break;case"smooth":var D=.35*(n-u);if(null===a[r][s])p=0;else switch(p){case 0:if(x=u,b=P?A.move(u,d[s])+A.line(u,f):A.move(u,f),v=A.move(u,f),p=1,s<a[r].length-2){var R=A.curve(u+D,f,n-D,o,n,o);b+=R,v+=R;break}case 1:if(null===a[r][s+1])b+=P?A.line(u,h):A.move(u,f),v+=A.line(u,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1;else{var F=A.curve(u+D,f,n-D,o,n,o);b+=F,v+=F,s>=a[r].length-2&&(P&&(b+=A.curve(n,o,n,o,n,h)+A.move(n,h)),v+=A.curve(n,o,n,o,n,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1)}}u=n,f=o;break;default:var H=function(e,t,i){var a=[];switch(e){case"stepline":a=A.line(t,null,"H")+A.line(null,i,"V");break;case"linestep":a=A.line(null,i,"V")+A.line(t,null,"H");break;case"straight":a=A.line(t,i)}return a};if(null===a[r][s])p=0;else switch(p){case 0:if(x=u,b=P?A.move(u,d[s])+A.line(u,f):A.move(u,f),v=A.move(u,f),p=1,s<a[r].length-2){var N=H(w,n,o);b+=N,v+=N;break}case 1:if(null===a[r][s+1])b+=P?A.line(u,h):A.move(u,f),v+=A.line(u,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1;else{var W=H(w,n,o);b+=W,v+=W,s>=a[r].length-2&&(P&&(b+=A.line(n,h)),v+=A.line(n,S)+A.line(x,S)+"z",m.push(b),y.push(v),p=-1)}}u=n,f=o}return{linePaths:m,areaPaths:y,pX:u,pY:f,pathState:p,segmentStartX:x,linePath:b,areaPath:v}}},{key:"handleNullDataPoints",value:function(e,t,i,a,r){var s=this.w;if(null===e[i][a]&&s.config.markers.showNullDataPoints||1===e[i].length){var n=this.strokeWidth-s.config.markers.strokeWidth/2;n>0||(n=0);var o=this.markers.plotChartMarkers(t,r,a+1,n,!0);null!==o&&this.elPointsMain.add(o)}}}])&&ua(t.prototype,i),e}();function fa(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}i(600);var pa=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.strokeWidth=this.w.config.stroke.width,this.helpers=new Ei(t),this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.labels=[]}var t,i;return t=e,(i=[{key:"draw",value:function(e){var t=this,i=this.w,a=new g(this.ctx),s=new te(this.ctx),n=a.group({class:"apexcharts-treemap"});if(i.globals.noData)return n;var o=[];return e.forEach((function(e){var t=e.map((function(e){return Math.abs(e)}));o.push(t)})),this.negRange=this.helpers.checkColorRange(),i.config.series.forEach((function(e,i){e.data.forEach((function(e){Array.isArray(t.labels[i])||(t.labels[i]=[]),t.labels[i].push(e.x)}))})),window.TreemapSquared.generate(o,i.globals.gridWidth,i.globals.gridHeight).forEach((function(o,c){var h=a.group({class:"apexcharts-series apexcharts-treemap-series",seriesName:r.escapeString(i.globals.seriesNames[c]),rel:c+1,"data:realIndex":c});if(i.config.chart.dropShadow.enabled){var d=i.config.chart.dropShadow;new l(t.ctx).dropShadow(n,d,c)}var u=a.group({class:"apexcharts-data-labels"});o.forEach((function(r,n){var o=r[0],l=r[1],d=r[2],u=r[3],g=a.drawRect(o,l,d-o,u-l,i.config.plotOptions.treemap.borderRadius,"#fff",1,t.strokeWidth,i.config.plotOptions.treemap.useFillColorAsStroke?p:i.globals.stroke.colors[c]);g.attr({cx:o,cy:l,index:c,i:c,j:n,width:d-o,height:u-l});var f=t.helpers.getShadeColor(i.config.chart.type,c,n,t.negRange),p=f.color;void 0!==i.config.series[c].data[n]&&i.config.series[c].data[n].fillColor&&(p=i.config.series[c].data[n].fillColor);var x=s.fillPath({color:p,seriesNumber:c,dataPointIndex:n});g.node.classList.add("apexcharts-treemap-rect"),g.attr({fill:x}),t.helpers.addListeners(g);var b={x:o+(d-o)/2,y:l+(u-l)/2,width:0,height:0},v={x:o,y:l,width:d-o,height:u-l};if(i.config.chart.animations.enabled&&!i.globals.dataChanged){var m=1;i.globals.resized||(m=i.config.chart.animations.speed),t.animateTreemap(g,b,v,m)}if(i.globals.dataChanged){var y=1;t.dynamicAnim.enabled&&i.globals.shouldAnimate&&(y=t.dynamicAnim.speed,i.globals.previousPaths[c]&&i.globals.previousPaths[c][n]&&i.globals.previousPaths[c][n].rect&&(b=i.globals.previousPaths[c][n].rect),t.animateTreemap(g,b,v,y))}var w=t.getFontSize(r),k=i.config.dataLabels.formatter(t.labels[c][n],{value:i.globals.series[c][n],seriesIndex:c,dataPointIndex:n,w:i});"truncate"===i.config.plotOptions.treemap.dataLabels.format&&(w=parseInt(i.config.dataLabels.style.fontSize,10),k=t.truncateLabels(k,w,o,l,d,u));var A=t.helpers.calculateDataLabels({text:k,x:(o+d)/2,y:(l+u)/2+t.strokeWidth/2+w/3,i:c,j:n,colorProps:f,fontSize:w,series:e});i.config.dataLabels.enabled&&A&&t.rotateToFitLabel(A,w,k,o,l,d,u),h.add(g),null!==A&&h.add(A)})),h.add(u),n.add(h)})),n}},{key:"getFontSize",value:function(e){var t,i,a=this.w,r=function e(t){var i,a=0;if(Array.isArray(t[0]))for(i=0;i<t.length;i++)a+=e(t[i]);else for(i=0;i<t.length;i++)a+=t[i].length;return a}(this.labels)/function e(t){var i,a=0;if(Array.isArray(t[0]))for(i=0;i<t.length;i++)a+=e(t[i]);else for(i=0;i<t.length;i++)a+=1;return a}(this.labels);return t=(e[2]-e[0])*(e[3]-e[1]),i=Math.pow(t,.5),Math.min(i/r,parseInt(a.config.dataLabels.style.fontSize,10))}},{key:"rotateToFitLabel",value:function(e,t,i,a,r,s,n){var o=new g(this.ctx),l=o.getTextRects(i,t);if(l.width+this.w.config.stroke.width+5>s-a&&l.width<=n-r){var c=o.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,i,a,r,s){var n=new g(this.ctx),o=n.getTextRects(e,t).width+this.w.config.stroke.width+5>r-i&&s-a>r-i?s-a:r-i,l=n.getTextBasedOnMaxWidth({text:e,maxWidth:o,fontSize:t});return e.length!==l.length&&o/t<5?"":l}},{key:"animateTreemap",value:function(e,t,i,a){var r=new n(this.ctx);r.animateRect(e,{x:t.x,y:t.y,width:t.width,height:t.height},{x:i.x,y:i.y,width:i.width,height:i.height},a,(function(){r.animationCompleted(e)}))}}])&&fa(t.prototype,i),e}();function xa(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function ba(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?xa(Object(i),!0).forEach((function(t){va(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):xa(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function va(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ma(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}const ya=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w,this.timeScaleArray=[],this.utc=this.w.config.xaxis.labels.datetimeUTC}var t,i;return t=e,(i=[{key:"calculateTimeScaleTicks",value:function(e,t){var i=this,a=this.w;if(a.globals.allSeriesCollapsed)return a.globals.labels=[],a.globals.timescaleLabels=[],[];var r=new A(this.ctx),s=(t-e)/864e5;this.determineInterval(s),a.globals.disableZoomIn=!1,a.globals.disableZoomOut=!1,s<.00011574074074074075?a.globals.disableZoomIn=!0:s>5e4&&(a.globals.disableZoomOut=!0);var n=r.getTimeUnitsfromTimestamp(e,t,this.utc),o=a.globals.gridWidth/s,l=o/24,c=l/60,h=c/60,d=Math.floor(24*s),u=Math.floor(1440*s),g=Math.floor(86400*s),f=Math.floor(s),p=Math.floor(s/30),x=Math.floor(s/365),b={minMillisecond:n.minMillisecond,minSecond:n.minSecond,minMinute:n.minMinute,minHour:n.minHour,minDate:n.minDate,minMonth:n.minMonth,minYear:n.minYear},v={firstVal:b,currentMillisecond:b.minMillisecond,currentSecond:b.minSecond,currentMinute:b.minMinute,currentHour:b.minHour,currentMonthDate:b.minDate,currentDate:b.minDate,currentMonth:b.minMonth,currentYear:b.minYear,daysWidthOnXAxis:o,hoursWidthOnXAxis:l,minutesWidthOnXAxis:c,secondsWidthOnXAxis:h,numberOfSeconds:g,numberOfMinutes:u,numberOfHours:d,numberOfDays:f,numberOfMonths:p,numberOfYears:x};switch(this.tickInterval){case"years":this.generateYearScale(v);break;case"months":case"half_year":this.generateMonthScale(v);break;case"months_days":case"months_fortnight":case"days":case"week_days":this.generateDayScale(v);break;case"hours":this.generateHourScale(v);break;case"minutes_fives":case"minutes":this.generateMinuteScale(v);break;case"seconds_tens":case"seconds_fives":case"seconds":this.generateSecondScale(v)}var m=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?ba(ba({},t),{},{day:1,value:e.value+1}):"day"===e.unit||"hour"===e.unit?ba(ba({},t),{},{value:e.value}):"minute"===e.unit?ba(ba({},t),{},{value:e.value,minute:e.value}):"second"===e.unit?ba(ba({},t),{},{value:e.value,minute:e.minute,second:e.second}):e}));return m.filter((function(e){var t=1,r=Math.ceil(a.globals.gridWidth/120),s=e.value;void 0!==a.config.xaxis.tickAmount&&(r=a.config.xaxis.tickAmount),m.length>r&&(t=Math.floor(m.length/r));var n=!1,o=!1;switch(i.tickInterval){case"years":"year"===e.unit&&(n=!0);break;case"half_year":t=7,"year"===e.unit&&(n=!0);break;case"months":t=1,"year"===e.unit&&(n=!0);break;case"months_fortnight":t=15,"year"!==e.unit&&"month"!==e.unit||(n=!0),30===s&&(o=!0);break;case"months_days":t=10,"month"===e.unit&&(n=!0),30===s&&(o=!0);break;case"week_days":t=8,"month"===e.unit&&(n=!0);break;case"days":t=1,"month"===e.unit&&(n=!0);break;case"hours":"day"===e.unit&&(n=!0);break;case"minutes_fives":case"seconds_fives":s%5!=0&&(o=!0);break;case"seconds_tens":s%10!=0&&(o=!0)}if("hours"===i.tickInterval||"minutes_fives"===i.tickInterval||"seconds_tens"===i.tickInterval||"seconds_fives"===i.tickInterval){if(!o)return!0}else if((s%t==0||n)&&!o)return!0}))}},{key:"recalcDimensionsBasedOnFormat",value:function(e,t){var i=this.w,a=this.formatDates(e),r=this.removeOverlappingTS(a);i.globals.timescaleLabels=r.slice(),new et(this.ctx).plotCoords()}},{key:"determineInterval",value:function(e){var t=24*e,i=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 i>15:this.tickInterval="minutes_fives";break;case i>5:this.tickInterval="minutes";break;case i>1:this.tickInterval="seconds_tens";break;case 60*i>20:this.tickInterval="seconds_fives";break;default:this.tickInterval="seconds"}}},{key:"generateYearScale",value:function(e){var t=e.firstVal,i=e.currentMonth,a=e.currentYear,s=e.daysWidthOnXAxis,n=e.numberOfYears,o=t.minYear,l=0,c=new A(this.ctx),h="year";if(t.minDate>1||t.minMonth>0){var d=c.determineRemainingDaysOfYear(t.minYear,t.minMonth,t.minDate);l=(c.determineDaysOfYear(t.minYear)-d+1)*s,o=t.minYear+1,this.timeScaleArray.push({position:l,value:o,unit:h,year:o,month:r.monthMod(i+1)})}else 1===t.minDate&&0===t.minMonth&&this.timeScaleArray.push({position:l,value:o,unit:h,year:a,month:r.monthMod(i+1)});for(var u=o,g=l,f=0;f<n;f++)u++,g=c.determineDaysOfYear(u-1)*s+g,this.timeScaleArray.push({position:g,value:u,unit:h,year:u,month:1})}},{key:"generateMonthScale",value:function(e){var t=e.firstVal,i=e.currentMonthDate,a=e.currentMonth,s=e.currentYear,n=e.daysWidthOnXAxis,o=e.numberOfMonths,l=a,c=0,h=new A(this.ctx),d="month",u=0;if(t.minDate>1){c=(h.determineDaysOfMonths(a+1,t.minYear)-i+1)*n,l=r.monthMod(a+1);var g=s+u,f=r.monthMod(l),p=l;0===l&&(d="year",p=g,f=1,g+=u+=1),this.timeScaleArray.push({position:c,value:p,unit:d,year:g,month:f})}else this.timeScaleArray.push({position:c,value:l,unit:d,year:s,month:r.monthMod(a)});for(var x=l+1,b=c,v=0,m=1;v<o;v++,m++){0===(x=r.monthMod(x))?(d="year",u+=1):d="month";var y=this._getYear(s,x,u);b=h.determineDaysOfMonths(x,y)*n+b;var w=0===x?y:x;this.timeScaleArray.push({position:b,value:w,unit:d,year:y,month:0===x?1:x}),x++}}},{key:"generateDayScale",value:function(e){var t=e.firstVal,i=e.currentMonth,a=e.currentYear,s=e.hoursWidthOnXAxis,n=e.numberOfDays,o=new A(this.ctx),l="day",c=t.minDate+1,h=c,d=function(e,t,i){return e>o.determineDaysOfMonths(t+1,i)?(h=1,l="month",g=t+=1,t):t},u=(24-t.minHour)*s,g=c,f=d(h,i,a);0===t.minHour&&1===t.minDate?(u=0,g=r.monthMod(t.minMonth),l="month",h=t.minDate):1!==t.minDate&&0===t.minHour&&0===t.minMinute&&(u=0,c=t.minDate,g=c,f=d(h=c,i,a)),this.timeScaleArray.push({position:u,value:g,unit:l,year:this._getYear(a,f,0),month:r.monthMod(f),day:h});for(var p=u,x=0;x<n;x++){l="day",f=d(h+=1,f,this._getYear(a,f,0));var b=this._getYear(a,f,0);p=24*s+p;var v=1===h?r.monthMod(f):h;this.timeScaleArray.push({position:p,value:v,unit:l,year:b,month:r.monthMod(f),day:v})}}},{key:"generateHourScale",value:function(e){var t=e.firstVal,i=e.currentDate,a=e.currentMonth,s=e.currentYear,n=e.minutesWidthOnXAxis,o=e.numberOfHours,l=new A(this.ctx),c="hour",h=function(e,t){return e>l.determineDaysOfMonths(t+1,s)&&(x=1,t+=1),{month:t,date:x}},d=function(e,t){return e>l.determineDaysOfMonths(t+1,s)?t+=1:t},u=60-(t.minMinute+t.minSecond/60),g=u*n,f=t.minHour+1,p=f;60===u&&(g=0,p=f=t.minHour);var x=i;p>=24&&(p=0,x+=1,c="day");var b=h(x,a).month;b=d(x,b),this.timeScaleArray.push({position:g,value:f,unit:c,day:x,hour:p,year:s,month:r.monthMod(b)}),p++;for(var v=g,m=0;m<o;m++){c="hour",p>=24&&(p=0,c="day",b=h(x+=1,b).month,b=d(x,b));var y=this._getYear(s,b,0);v=60*n+v;var w=0===p?x:p;this.timeScaleArray.push({position:v,value:w,unit:c,hour:p,day:x,year:y,month:r.monthMod(b)}),p++}}},{key:"generateMinuteScale",value:function(e){for(var t=e.currentMillisecond,i=e.currentSecond,a=e.currentMinute,s=e.currentHour,n=e.currentDate,o=e.currentMonth,l=e.currentYear,c=e.minutesWidthOnXAxis,h=e.secondsWidthOnXAxis,d=e.numberOfMinutes,u=a+1,g=n,f=o,p=l,x=s,b=(60-i-t/1e3)*h,v=0;v<d;v++)u>=60&&(u=0,24===(x+=1)&&(x=0)),this.timeScaleArray.push({position:b,value:u,unit:"minute",hour:x,minute:u,day:g,year:this._getYear(p,f,0),month:r.monthMod(f)}),b+=c,u++}},{key:"generateSecondScale",value:function(e){for(var t=e.currentMillisecond,i=e.currentSecond,a=e.currentMinute,s=e.currentHour,n=e.currentDate,o=e.currentMonth,l=e.currentYear,c=e.secondsWidthOnXAxis,h=e.numberOfSeconds,d=i+1,u=a,g=n,f=o,p=l,x=s,b=(1e3-t)/1e3*c,v=0;v<h;v++)d>=60&&(d=0,++u>=60&&(u=0,24==++x&&(x=0))),this.timeScaleArray.push({position:b,value:d,unit:"second",hour:x,minute:u,second:d,day:g,year:this._getYear(p,f,0),month:r.monthMod(f)}),b+=c,d++}},{key:"createRawDateString",value:function(e,t){var i=e.year;return 0===e.month&&(e.month=1),i+="-"+("0"+e.month.toString()).slice(-2),"day"===e.unit?i+="day"===e.unit?"-"+("0"+t).slice(-2):"-01":i+="-"+("0"+(e.day?e.day:"1")).slice(-2),"hour"===e.unit?i+="hour"===e.unit?"T"+("0"+t).slice(-2):"T00":i+="T"+("0"+(e.hour?e.hour:"0")).slice(-2),"minute"===e.unit?i+=":"+("0"+t).slice(-2):i+=":"+(e.minute?("0"+e.minute).slice(-2):"00"),"second"===e.unit?i+=":"+("0"+t).slice(-2):i+=":00",this.utc&&(i+=".000Z"),i}},{key:"formatDates",value:function(e){var t=this,i=this.w;return e.map((function(e){var a=e.value.toString(),r=new A(t.ctx),s=t.createRawDateString(e,a),n=r.getDate(r.parseDate(s));if(t.utc||(n=r.getDate(r.parseDateWithTimezone(s))),void 0===i.config.xaxis.labels.format){var o="dd MMM",l=i.config.xaxis.labels.datetimeFormatter;"year"===e.unit&&(o=l.year),"month"===e.unit&&(o=l.month),"day"===e.unit&&(o=l.day),"hour"===e.unit&&(o=l.hour),"minute"===e.unit&&(o=l.minute),"second"===e.unit&&(o=l.second),a=r.formatDate(n,o)}else a=r.formatDate(n,i.config.xaxis.labels.format);return{dateString:s,position:e.position,value:a,unit:e.unit,year:e.year,month:e.month}}))}},{key:"removeOverlappingTS",value:function(e){var t,i=this,a=new g(this.ctx),r=!1;e.length>0&&e[0].value&&e.every((function(t){return t.value.length===e[0].value.length}))&&(r=!0,t=a.getTextRects(e[0].value).width);var s=0,n=e.map((function(n,o){if(o>0&&i.w.config.xaxis.labels.hideOverlappingLabels){var l=r?t:a.getTextRects(e[s].value).width,c=e[s].position;return n.position>c+l+10?(s=o,n):null}return n}));return n.filter((function(e){return null!==e}))}},{key:"_getYear",value:function(e,t,i){return e+Math.floor(t/12)+i}}])&&ma(t.prototype,i),e}();function wa(e){return function(e){if(Array.isArray(e))return ka(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return ka(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?ka(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ka(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,a=new Array(t);i<t;i++)a[i]=e[i];return a}function Aa(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Sa=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=i,this.w=i.w,this.el=t}var t,i;return t=e,(i=[{key:"setupElements",value:function(){var e=this.w.globals,t=this.w.config,i=t.chart.type;e.axisCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble","radar","heatmap","treemap"].indexOf(i)>-1,e.xyCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble"].indexOf(i)>-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"),g.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?"light"!==t.theme.mode||t.chart.background?t.chart.background:"#fff":"#424242",this.setSVGDimensions(),e.dom.elLegendForeign=document.createElementNS(e.SVGNS,"foreignObject"),g.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 i=this.w,a=i.config,r=i.globals,s={series:[],i:[]},n={series:[],i:[]},o={series:[],i:[]},l={series:[],i:[]},c={series:[],i:[]},h={series:[],i:[]},d={series:[],i:[]},u={series:[],i:[]},g={series:[],seriesRangeEnd:[],i:[]},f=void 0!==a.chart.type?a.chart.type:"line",x=null,b=0;r.series.forEach((function(t,a){var p=e[a].type||f;switch(p){case"column":case"bar":c.series.push(t),c.i.push(a),i.globals.columnSeries=c;break;case"area":n.series.push(t),n.i.push(a);break;case"line":s.series.push(t),s.i.push(a);break;case"scatter":o.series.push(t),o.i.push(a);break;case"bubble":l.series.push(t),l.i.push(a);break;case"candlestick":h.series.push(t),h.i.push(a);break;case"boxPlot":d.series.push(t),d.i.push(a);break;case"rangeBar":u.series.push(t),u.i.push(a);break;case"rangeArea":g.series.push(r.seriesRangeStart[a]),g.seriesRangeEnd.push(r.seriesRangeEnd[a]),g.i.push(a);break;case"heatmap":case"treemap":case"pie":case"donut":case"polarArea":case"radialBar":case"radar":x=p;break;default:console.warn("You have specified an unrecognized series type (",p,").")}f!==p&&"scatter"!==p&&b++})),b>0&&(null!==x&&console.warn("Chart or series type ",x," can not appear with other chart or series types."),c.series.length>0&&a.plotOptions.bar.horizontal&&(b-=c.length,c={series:[],i:[]},i.globals.columnSeries={series:[],i:[]},console.warn("Horizontal bars are not supported in a mixed/combo chart. Please turn off `plotOptions.bar.horizontal`"))),r.comboCharts||(r.comboCharts=b>0);var v=new ga(this.ctx,t),m=new Oi(this.ctx,t);this.ctx.pie=new Fi(this.ctx);var y=new Zi(this.ctx);this.ctx.rangeBar=new aa(this.ctx,t);var w=new ji(this.ctx),k=[];if(r.comboCharts){var A,S,C=new p(this.ctx);if(n.series.length>0&&(A=k).push.apply(A,wa(C.drawSeriesByGroup(n,r.areaGroups,"area",v))),c.series.length>0)if(i.config.chart.stacked){var P=new yi(this.ctx,t);k.push(P.draw(c.series,c.i))}else this.ctx.bar=new ui(this.ctx,t),k.push(this.ctx.bar.draw(c.series,c.i));if(g.series.length>0&&k.push(v.draw(g.series,"rangeArea",g.i,g.seriesRangeEnd)),s.series.length>0&&(S=k).push.apply(S,wa(C.drawSeriesByGroup(s,r.lineGroups,"line",v))),h.series.length>0&&k.push(m.draw(h.series,"candlestick",h.i)),d.series.length>0&&k.push(m.draw(d.series,"boxPlot",d.i)),u.series.length>0&&k.push(this.ctx.rangeBar.draw(u.series,u.i)),o.series.length>0){var L=new ga(this.ctx,t,!0);k.push(L.draw(o.series,"scatter",o.i))}if(l.series.length>0){var O=new ga(this.ctx,t,!0);k.push(O.draw(l.series,"bubble",l.i))}}else switch(a.chart.type){case"line":k=v.draw(r.series,"line");break;case"area":k=v.draw(r.series,"area");break;case"bar":a.chart.stacked?k=new yi(this.ctx,t).draw(r.series):(this.ctx.bar=new ui(this.ctx,t),k=this.ctx.bar.draw(r.series));break;case"candlestick":k=new Oi(this.ctx,t).draw(r.series,"candlestick");break;case"boxPlot":k=new Oi(this.ctx,t).draw(r.series,a.chart.type);break;case"rangeBar":k=this.ctx.rangeBar.draw(r.series);break;case"rangeArea":k=v.draw(r.seriesRangeStart,"rangeArea",void 0,r.seriesRangeEnd);break;case"heatmap":k=new Xi(this.ctx,t).draw(r.series);break;case"treemap":k=new pa(this.ctx,t).draw(r.series);break;case"pie":case"donut":case"polarArea":k=this.ctx.pie.draw(r.series);break;case"radialBar":k=y.draw(r.series);break;case"radar":k=w.draw(r.series);break;default:k=v.draw(r.series)}return k}},{key:"setSVGDimensions",value:function(){var e=this.w.globals,t=this.w.config;t.chart.width||(t.chart.width="100%"),t.chart.height||(t.chart.height="auto"),e.svgWidth=t.chart.width,e.svgHeight=t.chart.height;var i=r.getDimensions(this.el),a=t.chart.width.toString().split(/[0-9]+/g).pop();"%"===a?r.isNumber(i[0])&&(0===i[0].width&&(i=r.getDimensions(this.el.parentNode)),e.svgWidth=i[0]*parseInt(t.chart.width,10)/100):"px"!==a&&""!==a||(e.svgWidth=parseInt(t.chart.width,10));var s=String(t.chart.height).toString().split(/[0-9]+/g).pop();if("auto"!==e.svgHeight&&""!==e.svgHeight)if("%"===s){var n=r.getDimensions(this.el.parentNode);e.svgHeight=n[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),g.setAttrs(e.dom.Paper.node,{width:e.svgWidth,height:e.svgHeight}),"%"!==s){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,i={transform:"translate("+e.translateX+", "+t+")"};g.setAttrs(e.dom.elGraphical.node,i)}},{key:"resizeNonAxisCharts",value:function(){var e=this.w,t=e.globals,i=0,a=e.config.chart.sparkline.enabled?1:15;a+=e.config.grid.padding.bottom,"top"!==e.config.legend.position&&"bottom"!==e.config.legend.position||!e.config.legend.show||e.config.legend.floating||(i=new ot(this.ctx).legendHelpers.getLegendDimensions().clwh+10);var s=e.globals.dom.baseEl.querySelector(".apexcharts-radialbar, .apexcharts-pie"),n=2.05*e.globals.radialSize;if(s&&!e.config.chart.sparkline.enabled&&0!==e.config.plotOptions.radialBar.startAngle){var o=r.getBoundingClientRect(s);n=o.bottom;var l=o.bottom-o.top;n=Math.max(2.05*e.globals.radialSize,l)}var c=n+t.translateY+i+a;t.dom.elLegendForeign&&t.dom.elLegendForeign.setAttribute("height",c),e.config.chart.height&&String(e.config.chart.height).indexOf("%")>0||(t.dom.elWrap.style.height=c+"px",g.setAttrs(t.dom.Paper.node,{height:c}),t.dom.Paper.node.parentNode.parentNode.style.minHeight=c+"px")}},{key:"coreCalculations",value:function(){new Ce(this.ctx).init()}},{key:"resetGlobals",value:function(){var e=this,t=function(){return e.w.config.series.map((function(e){return[]}))},i=new q,a=this.w.globals;i.initGlobalVars(a),a.seriesXvalues=t(),a.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 Ye(this.ctx).drawXCrosshairs(),"back"===t.config.yaxis[0].crosshairs.position&&new Ye(this.ctx).drawYCrosshairs(),"datetime"===t.config.xaxis.type&&void 0===t.config.xaxis.labels.formatter){this.ctx.timeScale=new ya(this.ctx);var i=[];isFinite(t.globals.minX)&&isFinite(t.globals.maxX)&&!t.globals.isBarHorizontal?i=this.ctx.timeScale.calculateTimeScaleTicks(t.globals.minX,t.globals.maxX):t.globals.isBarHorizontal&&(i=this.ctx.timeScale.calculateTimeScaleTicks(t.globals.minY,t.globals.maxY)),this.ctx.timeScale.recalcDimensionsBasedOnFormat(i)}e=new p(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 i=Array.isArray(t.config.chart.brush.targets)?t.config.chart.brush.targets:[t.config.chart.brush.target];i.forEach((function(t){var i=ApexCharts.getChartByID(t);i.w.globals.brushSource=e.ctx,"function"!=typeof i.w.config.chart.events.zoomed&&(i.w.config.chart.events.zoomed=function(){e.updateSourceChart(i)}),"function"!=typeof i.w.config.chart.events.scrolled&&(i.w.config.chart.events.scrolled=function(){e.updateSourceChart(i)})})),t.config.chart.events.selection=function(e,t){i.forEach((function(e){ApexCharts.getChartByID(e).ctx.updateHelpers._updateOptions({xaxis:{min:t.xaxis.min,max:t.xaxis.max}},!1,!1,!1,!1)}))}}}}])&&Aa(t.prototype,i),e}();function Ca(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,a)}return i}function Pa(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ca(Object(i),!0).forEach((function(t){La(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ca(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function La(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Oa(e){return Oa="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Oa(e)}function Ma(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ta=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,i=[{key:"_updateOptions",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],n=arguments.length>4&&void 0!==arguments[4]&&arguments[4];return new Promise((function(o){var l=[t.ctx];s&&(l=t.ctx.getSyncedCharts()),t.ctx.w.globals.isExecCalled&&(l=[t.ctx],t.ctx.w.globals.isExecCalled=!1),l.forEach((function(s,c){var h=s.w;if(h.globals.shouldAnimate=a,i||(h.globals.resized=!0,h.globals.dataChanged=!0,a&&s.series.getPreviousPaths()),e&&"object"===Oa(e)&&(s.config=new _(e),e=p.extendArrayProps(s.config,e,h),s.w.globals.chartID!==t.ctx.w.globals.chartID&&delete e.series,h.config=r.extend(h.config,e),n&&(h.globals.lastXAxis=e.xaxis?r.clone(e.xaxis):[],h.globals.lastYAxis=e.yaxis?r.clone(e.yaxis):[],h.globals.initialConfig=r.extend({},h.config),h.globals.initialSeries=r.clone(h.config.series),e.series))){for(var d=0;d<h.globals.collapsedSeriesIndices.length;d++){var u=h.config.series[h.globals.collapsedSeriesIndices[d]];h.globals.collapsedSeries[d].data=h.globals.axisCharts?u.data.slice():u}for(var g=0;g<h.globals.ancillaryCollapsedSeriesIndices.length;g++){var f=h.config.series[h.globals.ancillaryCollapsedSeriesIndices[g]];h.globals.ancillaryCollapsedSeries[g].data=h.globals.axisCharts?f.data.slice():f}s.series.emptyCollapsedSeries(h.config.series)}return s.update(e).then((function(){c===l.length-1&&o(s)}))}))}))}},{key:"_updateSeries",value:function(e,t){var i=this,a=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return new Promise((function(s){var n,o=i.w;return o.globals.shouldAnimate=t,o.globals.dataChanged=!0,t&&i.ctx.series.getPreviousPaths(),o.globals.axisCharts?(0===(n=e.map((function(e,t){return i._extendSeries(e,t)}))).length&&(n=[{data:[]}]),o.config.series=n):o.config.series=e.slice(),a&&(o.globals.initialConfig.series=r.clone(o.config.series),o.globals.initialSeries=r.clone(o.config.series)),i.ctx.update().then((function(){s(i.ctx)}))}))}},{key:"_extendSeries",value:function(e,t){var i=this.w,a=i.config.series[t];return Pa(Pa({},i.config.series[t]),{},{name:e.name?e.name:null==a?void 0:a.name,color:e.color?e.color:null==a?void 0:a.color,type:e.type?e.type:null==a?void 0:a.type,group:e.group?e.group:null==a?void 0:a.group,data:e.data?e.data:null==a?void 0:a.data,zIndex:void 0!==e.zIndex?e.zIndex:t})}},{key:"toggleDataPointSelection",value:function(e,t){var i=this.w,a=null,r=".apexcharts-series[data\\:realIndex='".concat(e,"']");return i.globals.axisCharts?a=i.globals.dom.Paper.select("".concat(r," path[j='").concat(t,"'], ").concat(r," circle[j='").concat(t,"'], ").concat(r," rect[j='").concat(t,"']")).members[0]:void 0===t&&(a=i.globals.dom.Paper.select("".concat(r," path[j='").concat(e,"']")).members[0],"pie"!==i.config.chart.type&&"polarArea"!==i.config.chart.type&&"donut"!==i.config.chart.type||this.ctx.pie.pieClicked(e)),a?(new g(this.ctx).pathMouseDown(a,null),a.node?a.node:null):(console.warn("toggleDataPointSelection: Element not found"),null)}},{key:"forceXAxisUpdate",value:function(e){var t=this.w;if(["min","max"].forEach((function(i){void 0!==e.xaxis[i]&&(t.config.xaxis[i]=e.xaxis[i],t.globals.lastXAxis[i]=e.xaxis[i])})),e.xaxis.categories&&e.xaxis.categories.length&&(t.config.xaxis.categories=e.xaxis.categories),t.config.xaxis.convertedCatToNumeric){var i=new j(e);e=i.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,i){e.yaxis[i].min=0,e.yaxis[i].max=100})):(e.yaxis.min=0,e.yaxis.max=100)),e}},{key:"revertDefaultAxisMinMax",value:function(e){var t=this,i=this.w,a=i.globals.lastXAxis,r=i.globals.lastYAxis;e&&e.xaxis&&(a=e.xaxis),e&&e.yaxis&&(r=e.yaxis),i.config.xaxis.min=a.min,i.config.xaxis.max=a.max;i.config.yaxis.map((function(e,a){i.globals.zoomed||void 0!==r[a]?function(e){void 0!==r[e]&&(i.config.yaxis[e].min=r[e].min,i.config.yaxis[e].max=r[e].max)}(a):void 0!==t.ctx.opts.yaxis[a]&&(e.min=t.ctx.opts.yaxis[a].min,e.max=t.ctx.opts.yaxis[a].max)}))}}],i&&Ma(t.prototype,i),e}();function Ia(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}i(482),i(872),i(25),i(372),i(769),i(882),void 0===window.Apex&&(window.Apex={});var Ea=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{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 n(this.ctx),this.ctx.axes=new ze(this.ctx),this.ctx.core=new Sa(this.ctx.el,this.ctx),this.ctx.config=new _({}),this.ctx.data=new ue(this.ctx),this.ctx.grid=new ye(this.ctx),this.ctx.graphics=new g(this.ctx),this.ctx.coreUtils=new p(this.ctx),this.ctx.crosshairs=new Ye(this.ctx),this.ctx.events=new Me(this.ctx),this.ctx.exports=new xe(this.ctx),this.ctx.localization=new Ie(this.ctx),this.ctx.options=new X,this.ctx.responsive=new Re(this.ctx),this.ctx.series=new ce(this.ctx),this.ctx.theme=new He(this.ctx),this.ctx.formatters=new C(this.ctx),this.ctx.titleSubtitle=new We(this.ctx),this.ctx.legend=new ot(this.ctx),this.ctx.toolbar=new At(this.ctx),this.ctx.tooltip=new Jt(this.ctx),this.ctx.dimensions=new et(this.ctx),this.ctx.updateHelpers=new Ta(this.ctx),this.ctx.zoomPanSelection=new Ot(this.ctx),this.ctx.w.globals.tooltip=new Jt(this.ctx)}}])&&Ia(t.prototype,i),e}();function za(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Xa=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ctx=t,this.w=t.w}var t,i;return t=e,(i=[{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,i=e.isUpdating,a=this.w.globals.dom.Paper.node;a.parentNode&&a.parentNode.parentNode&&!i&&(a.parentNode.parentNode.style.minHeight="unset");var r=this.w.globals.dom.baseEl;r&&this.ctx.eventList.forEach((function(e){r.removeEventListener(e,t.ctx.events.documentEvent)}));var s=this.w.globals.dom;if(null!==this.ctx.el)for(;this.ctx.el.firstChild;)this.ctx.el.removeChild(this.ctx.el.firstChild);this.killSVG(s.Paper),s.Paper.remove(),s.elWrap=null,s.elGraphical=null,s.elLegendWrap=null,s.elLegendForeign=null,s.baseEl=null,s.elGridRect=null,s.elGridRectMask=null,s.elGridRectMarkerMask=null,s.elForecastMask=null,s.elNonForecastMask=null,s.elDefs=null}}])&&za(t.prototype,i),e}(),Ya=new WeakMap,Da=i(274),Ra=i.n(Da);function Fa(e,t){for(var i=0;i<t.length;i++){var a=t[i];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}var Ha=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.opts=i,this.ctx=this,this.w=new $(i).init(),this.el=t,this.w.globals.cuid=r.randomId(),this.w.globals.chartID=this.w.config.chart.id?r.escapeString(this.w.config.chart.id):this.w.globals.cuid,new Ea(this).initModules(),this.create=r.bind(this.create,this),this.windowResizeHandler=this._windowResizeHandler.bind(this),this.parentResizeHandler=this._parentResizeCallback.bind(this)}var t,i,a;return t=e,i=[{key:"render",value:function(){var e=this;return new Promise((function(t,i){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 a=e.w.config.chart.events.beforeMount;"function"==typeof a&&a(e,e.w),e.events.fireEvent("beforeMount",[e,e.w]),window.addEventListener("resize",e.windowResizeHandler),function(e,t){var i=!1;if(e.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var a=e.getBoundingClientRect();"none"!==e.style.display&&0!==a.width||(i=!0)}var r=new ResizeObserver((function(a){i&&t.call(e,a),i=!0}));e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?Array.from(e.children).forEach((function(e){return r.observe(e)})):r.observe(e),Ya.set(t,r)}(e.el.parentNode,e.parentResizeHandler);var s=e.el.getRootNode&&e.el.getRootNode(),n=r.is("ShadowRoot",s),o=e.el.ownerDocument,l=n?s.getElementById("apexcharts-css"):o.getElementById("apexcharts-css");if(!l){var c;(l=document.createElement("style")).id="apexcharts-css",l.textContent=Ra();var h=(null===(c=e.opts.chart)||void 0===c?void 0:c.nonce)||e.w.config.chart.nonce;h&&l.setAttribute("nonce",h),n?s.prepend(l):o.head.appendChild(l)}var d=e.create(e.w.config.series,{});if(!d)return t(e);e.mount(d).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(d)})).catch((function(e){i(e)}))}else i(new Error("Element not found"))}))}},{key:"create",value:function(e,t){var i=this.w;new Ea(this).initModules();var a=this.w.globals;if(a.noData=!1,a.animationEnded=!1,this.responsive.checkResponsiveConfig(t),i.config.xaxis.convertedCatToNumeric&&new j(i.config).convertCatToNumericXaxis(i.config,this.ctx),null===this.el)return a.animationEnded=!0,null;if(this.core.setupElements(),"treemap"===i.config.chart.type&&(i.config.grid.show=!1,i.config.yaxis[0].show=!1),0===a.svgWidth)return a.animationEnded=!0,null;var r=p.checkComboSeries(e,i.config.chart.type);a.comboCharts=r.comboCharts,a.comboBarCount=r.comboBarCount;var s=e.every((function(e){return e.data&&0===e.data.length}));(0===e.length||s&&a.collapsedSeries.length<1)&&this.series.handleNoData(),this.events.setupEventHandlers(),this.data.parseData(e),this.theme.init(),new ae(this).setGlobalMarkerSize(),this.formatters.setLabelFormatters(),this.titleSubtitle.draw(),a.noData&&a.collapsedSeries.length!==a.series.length&&!i.config.legend.showForSingleSeries||this.legend.init(),this.series.hasAllSeriesEqualX(),a.axisCharts&&(this.core.coreCalculations(),"category"!==i.config.xaxis.type&&this.formatters.setLabelFormatters(),this.ctx.toolbar.minX=i.globals.minX,this.ctx.toolbar.maxX=i.globals.maxX),this.formatters.heatmapLabelFormatters(),new p(this).getLargestMarkerSize(),this.dimensions.plotCoords();var n=this.core.xySettings();this.grid.createGridMask();var o=this.core.plotChartType(e,n),l=new oe(this);return l.bringForward(),i.config.dataLabels.background.enabled&&l.dataLabelsBackground(),this.core.shiftGraphPosition(),{elGraph:o,xyRatios:n,dimensions:{plot:{left:i.globals.translateX,top:i.globals.translateY,width:i.globals.gridWidth,height:i.globals.gridHeight}}}}},{key:"mount",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,i=this,a=i.w;return new Promise((function(r,s){if(null===i.el)return s(new Error("Not enough data to display or target element not found"));(null===t||a.globals.allSeriesCollapsed)&&i.series.handleNoData(),i.grid=new ye(i);var n,o,l=i.grid.drawGrid();if(i.annotations=new D(i),i.annotations.drawImageAnnos(),i.annotations.drawTextAnnos(),"back"===a.config.grid.position&&(l&&a.globals.dom.elGraphical.add(l.el),null!=l&&null!==(n=l.elGridBorders)&&void 0!==n&&n.node&&a.globals.dom.elGraphical.add(l.elGridBorders)),Array.isArray(t.elGraph))for(var c=0;c<t.elGraph.length;c++)a.globals.dom.elGraphical.add(t.elGraph[c]);else a.globals.dom.elGraphical.add(t.elGraph);"front"===a.config.grid.position&&(l&&a.globals.dom.elGraphical.add(l.el),null!=l&&null!==(o=l.elGridBorders)&&void 0!==o&&o.node&&a.globals.dom.elGraphical.add(l.elGridBorders)),"front"===a.config.xaxis.crosshairs.position&&i.crosshairs.drawXCrosshairs(),"front"===a.config.yaxis[0].crosshairs.position&&i.crosshairs.drawYCrosshairs(),"treemap"!==a.config.chart.type&&i.axes.drawAxis(a.config.chart.type,l);var h=new ve(e.ctx,l),d=new Le(e.ctx,l);if(null!==l&&(h.xAxisLabelCorrections(l.xAxisTickWidth),d.setYAxisTextAlignments(),a.config.yaxis.map((function(e,t){-1===a.globals.ignoreYAxisIndexes.indexOf(t)&&d.yAxisTitleRotate(t,e.opposite)}))),i.annotations.drawAxesAnnotations(),!a.globals.noData){if(a.config.tooltip.enabled&&!a.globals.noData&&i.w.globals.tooltip.drawTooltip(t.xyRatios),a.globals.axisCharts&&(a.globals.isXNumeric||a.config.xaxis.convertedCatToNumeric||a.globals.isRangeBar))(a.config.chart.zoom.enabled||a.config.chart.selection&&a.config.chart.selection.enabled||a.config.chart.pan&&a.config.chart.pan.enabled)&&i.zoomPanSelection.init({xyRatios:t.xyRatios});else{var u=a.config.chart.toolbar.tools;["zoom","zoomin","zoomout","selection","pan","reset"].forEach((function(e){u[e]=!1}))}a.config.chart.toolbar.show&&!a.globals.allSeriesCollapsed&&i.toolbar.createToolbar()}a.globals.memory.methodsToExec.length>0&&a.globals.memory.methodsToExec.forEach((function(e){e.method(e.params,!1,e.context)})),a.globals.axisCharts||a.globals.noData||i.core.resizeNonAxisCharts(),r(i)}))}},{key:"destroy",value:function(){var e,t;window.removeEventListener("resize",this.windowResizeHandler),this.el.parentNode,e=this.parentResizeHandler,(t=Ya.get(e))&&(t.disconnect(),Ya.delete(e));var i=this.w.config.chart.id;i&&Apex._chartInstances.forEach((function(e,t){e.id===r.escapeString(i)&&Apex._chartInstances.splice(t,1)})),new Xa(this.ctx).clear({isUpdating:!1})}},{key:"updateOptions",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],s=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],n=this.w;return n.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,i){return t.updateHelpers._extendSeries(e,i)}))),this.updateHelpers.revertDefaultAxisMinMax()),e.xaxis&&(e=this.updateHelpers.forceXAxisUpdate(e)),e.yaxis&&(e=this.updateHelpers.forceYAxisUpdate(e)),n.globals.collapsedSeriesIndices.length>0&&this.series.clearPreviousPaths(),e.theme&&(e=this.theme.updateThemeOptions(e)),this.updateHelpers._updateOptions(e,i,a,r,s)}},{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],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(e,t,i)}},{key:"appendSeries",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],a=this.w.config.series.slice();return a.push(e),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(a,t,i)}},{key:"appendData",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this;i.w.globals.dataChanged=!0,i.series.getPreviousPaths();for(var a=i.w.config.series.slice(),s=0;s<a.length;s++)if(null!==e[s]&&void 0!==e[s])for(var n=0;n<e[s].data.length;n++)a[s].data.push(e[s].data[n]);return i.w.config.series=a,t&&(i.w.globals.initialSeries=r.clone(i.w.config.series)),this.update()}},{key:"update",value:function(e){var t=this;return new Promise((function(i,a){new Xa(t.ctx).clear({isUpdating:!0});var r=t.create(t.w.config.series,e);if(!r)return i(t);t.mount(r).then((function(){"function"==typeof t.w.config.chart.events.updated&&t.w.config.chart.events.updated(t,t.w),t.events.fireEvent("updated",[t,t.w]),t.w.globals.isDirty=!0,i(t)})).catch((function(e){a(e)}))}))}},{key:"getSyncedCharts",value:function(){var e=this.getGroupedCharts(),t=[this];return e.length&&(t=[],e.forEach((function(e){t.push(e)}))),t}},{key:"getGroupedCharts",value:function(){var e=this;return Apex._chartInstances.filter((function(e){if(e.group)return!0})).map((function(t){return e.w.config.chart.group===t.group?t.chart:e}))}},{key:"toggleSeries",value:function(e){return this.series.toggleSeries(e)}},{key:"highlightSeriesOnLegendHover",value:function(e,t){return this.series.toggleSeriesOnHover(e,t)}},{key:"showSeries",value:function(e){this.series.showSeries(e)}},{key:"hideSeries",value:function(e){this.series.hideSeries(e)}},{key:"isSeriesHidden",value:function(e){this.series.isSeriesHidden(e)}},{key:"resetSeries",value:function(){var e=!(arguments.length>0&&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],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addXaxisAnnotationExternal(e,t,a)}},{key:"addYaxisAnnotation",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addYaxisAnnotationExternal(e,t,a)}},{key:"addPointAnnotation",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,a=this;i&&(a=i),a.annotations.addPointAnnotationExternal(e,t,a)}},{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,i=this;t&&(i=t),i.annotations.removeAnnotation(i,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 Ce(this.ctx).getMinYMaxY(e).highestY}},{key:"getLowestValueInSeries",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return new Ce(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 xe(this.ctx).dataURI(e)}},{key:"exportToCSV",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new xe(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()}}],a=[{key:"getChartByID",value:function(e){var t=r.escapeString(e);if(Apex._chartInstances){var i=Apex._chartInstances.filter((function(e){return e.id===t}))[0];return i&&i.chart}}},{key:"initOnLoad",value:function(){for(var t=document.querySelectorAll("[data-apexcharts]"),i=0;i<t.length;i++)new e(t[i],JSON.parse(t[i].getAttribute("data-options"))).render()}},{key:"exec",value:function(e,t){var i=this.getChartByID(e);if(i){i.w.globals.isExecCalled=!0;var a=null;if(-1!==i.publicMethods.indexOf(t)){for(var r=arguments.length,s=new Array(r>2?r-2:0),n=2;n<r;n++)s[n-2]=arguments[n];a=i[t].apply(i,s)}return a}}},{key:"merge",value:function(e,t){return r.extend(e,t)}}],i&&Fa(t.prototype,i),a&&Fa(t,a),e}()})(),a})()));