PageSourceSearch

https://www.customreport.ai/_next/static/chunks/cb4e5a67.9e6ed1159473c8cc.js

js customreport.ai collected 2026-10-05 14:37:00 UTC 521,979 bytes, 903 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9522],{95520:(e,t,i)=>{i.d(t,{A:()=>eJ});var s=Object.defineProperty,a=Object.defineProperties,r=Object.getOwnPropertyDescriptors,l=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable,h=(e,t,i)=>t in e?s(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,d=(e,t)=>{for(var i in t||(t={}))o.call(t,i)&&h(e,i,t[i]);if(l)for(var i of l(t))n.call(t,i)&&h(e,i,t[i]);return e},c=(e,t)=>a(e,r(t)),g=(e,t,i)=>h(e,"symbol"!=typeof t?t+"":t,i);class p{static isSSR(){return"undefined"==typeof window||"undefined"==typeof document}static isBrowser(){return!this.isSSR()}static hasAPI(e){return!this.isSSR()&&void 0!==window[e]}static getApex(){return"undefined"!=typeof window&&window.Apex?window.Apex:void 0!==i.g&&i.g.Apex?i.g.Apex:{}}}class x{constructor(e,t=null){this.nodeName=e,this.namespaceURI=t,this.attributes=new Map,this.children=[],this.textContent="",this.style={},this.classList=new u,this.parentNode=null,this._ssrWidth=void 0,this._ssrHeight=void 0,this._ssrMode=void 0}setAttribute(e,t){this.attributes.set(e,t)}getAttribute(e){return this.attributes.get(e)}removeAttribute(e){this.attributes.delete(e)}hasAttribute(e){return this.attributes.has(e)}appendChild(e){if(e&&e!==this){if(e.parentNode&&e.parentNode!==this)e.parentNode.removeChild(e);else if(e.parentNode===this){let t=this.children.indexOf(e);-1!==t&&this.children.splice(t,1)}e.parentNode=this,this.children.push(e)}return e}removeChild(e){let t=this.children.indexOf(e);return -1!==t&&(this.children.splice(t,1),e.parentNode=null),e}insertBefore(e,t){if(!t)return this.appendChild(e);if(e.parentNode&&e.parentNode!==this)e.parentNode.removeChild(e);else if(e.parentNode===this){let t=this.children.indexOf(e);-1!==t&&this.children.splice(t,1)}let i=this.children.indexOf(t);return -1!==i&&(e.parentNode=this,this.children.splice(i,0,e)),e}cloneNode(e=!1){let t=new x(this.nodeName,this.namespaceURI);return t.textContent=this.textContent,this.attributes.forEach((e,i)=>{t.attributes.set(i,e)}),Object.assign(t.style,this.style),e&&this.children.forEach(e=>{e.cloneNode&&t.appendChild(e.cloneNode(!0))}),t}getBoundingClientRect(){return{width:this._ssrWidth||0,height:this._ssrHeight||0,top:0,left:0,right:this._ssrWidth||0,bottom:this._ssrHeight||0,x:0,y:0}}getRootNode(){let e=this;for(;e.parentNode;)e=e.parentNode;return e}querySelector(){return null}querySelectorAll(){return[]}getElementsByClassName(){return[]}addEventListener(){}removeEventListener(){}get childNodes(){return this.children}toString(){let e="";if(this.attributes.forEach((t,i)=>{e+=` ${i}="${t}"`}),0===this.children.length&&!this.textContent)return`<${this.nodeName}${e}/>`;let t=this.children.map(e=>e.toString()).join("");return`<${this.nodeName}${e}>${this.textContent}${t}</${this.nodeName}>`}get innerHTML(){return this.children.map(e=>e.toString()).join("")}set innerHTML(e){this.children=[],this.textContent=e}get outerHTML(){return this.toString()}get isConnected(){return!0}}class u{constructor(){this.classes=new Set}add(...e){e.forEach(e=>this.classes.add(e))}remove(...e){e.forEach(e=>this.classes.delete(e))}contains(e){return this.classes.has(e)}toggle(e,t){return!0===t?(this.classes.add(e),!0):!1===t?(this.classes.delete(e),!1):this.classes.has(e)?(this.classes.delete(e),!1):(this.classes.add(e),!0)}toString(){return Array.from(this.classes).join(" ")}}class f{constructor(){this.SVGNS="http://www.w3.org/2000/svg",this.XLINKNS="http://www.w3.org/1999/xlink"}createElementNS(e,t){return new x(t,e)}createTextNode(e){let t={nodeName:"#text",nodeType:3,textContent:e,toString:()=>t.textContent};return t}querySelector(){return null}querySelectorAll(){return[]}getComputedStyle(){return{}}getBoundingClientRect(e){return e&&e.getBoundingClientRect?e.getBoundingClientRect():{width:0,height:0,top:0,left:0,right:0,bottom:0,x:0,y:0}}createXMLSerializer(){return{serializeToString:e=>e.toString?e.toString():""}}createDOMParser(){return{parseFromString(e,t){let i=new x("root");return i.innerHTML=e,{documentElement:i}}}}}let m=null,b=null,y=null;class w{static init(){p.isSSR()&&!m&&(m=new f)}static createElement(e){return p.isSSR()?(m||this.init(),m.createElementNS(null,e)):document.createElement(e)}static createElementNS(e,t){return p.isSSR()?(m||this.init(),m.createElementNS(e,t)):document.createElementNS(e,t)}static createTextNode(e){return p.isSSR()?(m||this.init(),m.createTextNode(e)):document.createTextNode(e)}static querySelector(e){return p.isSSR()?null:document.querySelector(e)}static querySelectorAll(e){return p.isSSR()?[]:document.querySelectorAll(e)}static getComputedStyle(e){return p.isSSR()?{}:window.getComputedStyle(e)}static getBoundingClientRect(e){return p.isSSR()?(m||this.init(),m.getBoundingClientRect(e)):e?e.getBoundingClientRect():{width:0,height:0,top:0,left:0,right:0,bottom:0,x:0,y:0}}static getXMLSerializer(){return p.isSSR()?(m||this.init(),b||(b=m.createXMLSerializer())):b||(b=ne
1w XMLSerializer),b}static getDOMParser(){return p.isSSR()?(m||this.init(),y||(y=m.createDOMParser())):y||(y=new DOMParser),y}static addWindowEventListener(e,t,i){p.isBrowser()&&window.addEventListener(e,t,i)}static removeWindowEventListener(e,t,i){p.isBrowser()&&window.removeEventListener(e,t,i)}static requestAnimationFrame(e){return p.isBrowser()?window.requestAnimationFrame(e):(e(0),null)}static cancelAnimationFrame(e){p.isBrowser()&&e&&window.cancelAnimationFrame(e)}static elementExists(e){return!!e&&(p.isSSR()?!0===e._ssrMode||void 0!==e.nodeName:!!e.getRootNode&&(e.getRootNode({composed:!0})===document||e.isConnected))}static getWindow(){return p.isBrowser()?window:null}static getDocument(){return p.isBrowser()?document:null}static _getShim(){return m}static _resetShim(){m=null,b=null,y=null}}let v=class e{static isObject(e){return e&&"object"==typeof e&&!Array.isArray(e)}static is(e,t){return Object.prototype.toString.call(t)==="[object "+e+"]"}static isSafari(){return p.isBrowser()&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}static extend(e,t){let i=Object.assign({},e);return this.isObject(e)&&this.isObject(t)&&Object.keys(t).forEach(s=>{this.isObject(t[s])&&s in e?i[s]=this.extend(e[s],t[s]):Object.assign(i,{[s]:t[s]})}),i}static extendArray(t,i){let s=[];return t.map(t=>{s.push(e.extend(i,t))}),t=s}static monthMod(e){return e%12}static clone(e,t=new WeakMap,i=!1){let s;if(null===e||"object"!=typeof e)return e;if(t.has(e))return t.get(e);if(Array.isArray(e))if(i)s=e.slice();else{s=[],t.set(e,s);for(let i=0;i<e.length;i++)s[i]=this.clone(e[i],t,!1)}else if(e instanceof Date)s=new Date(e.getTime());else if(i)s=Object.assign({},e);else for(let i in s={},t.set(e,s),e)Object.prototype.hasOwnProperty.call(e,i)&&(s[i]=this.clone(e[i],t,!1));return s}static shallowClone(e){return null===e||"object"!=typeof e?e:Array.isArray(e)?e.slice():Object.assign({},e)}static shallowEqual(e,t){if(e===t)return!0;if(!e||!t)return!1;if("object"!=typeof e||"object"!=typeof t)return e===t;let i=Object.keys(e),s=Object.keys(t);if(i.length!==s.length)return!1;for(let s of i)if(e[s]!==t[s])return!1;return!0}static log10(e){return Math.log(e)/Math.LN10}static roundToBase10(e){return Math.pow(10,Math.floor(Math.log10(e)))}static roundToBase(e,t){return Math.pow(t,Math.floor(Math.log(e)/Math.log(t)))}static parseNumber(e){return"number"==typeof e||null===e?e:parseFloat(e)}static stripNumber(e,t=2){return Number.isInteger(e)?e:parseFloat(e.toPrecision(t))}static randomId(){return(Math.random()+1).toString(36).substring(4)}static noExponents(e){return e.toString().includes("e")?Math.round(e):e}static elementExists(e){return!!e&&!!e.isConnected}static isInShadowDOM(t){if(!t||!t.getRootNode)return!1;let i=t.getRootNode();return i&&i!==document&&e.is("ShadowRoot",i)}static getShadowRootHost(t){return e.isInShadowDOM(t)&&t.getRootNode().host||null}static getDimensions(e){let t;if(!e)return[0,0];if(p.isSSR())return[e._ssrWidth||400,e._ssrHeight||300];try{t=getComputedStyle(e,null)}catch(t){return[e.clientWidth||0,e.clientHeight||0]}let i=e.clientWidth,s=e.clientHeight;if(!i||!s){let t=e.getBoundingClientRect();i=i||t.width,s=s||t.height}return s-=parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),[i-=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight),s]}static getBoundingClientRect(e){if(!e)return{top:0,right:0,bottom:0,left:0,width:0,height:0,x:0,y:0};if(p.isSSR())return w.getBoundingClientRect(e);let 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}}static getLargestStringFromArr(e){return e.reduce((e,t)=>(Array.isArray(t)&&(t=t.reduce((e,t)=>e.length>t.length?e:t)),e.length>t.length?e:t),0)}static hexToRgba(e="#999999",t=.6){"#"!==e.substring(0,1)&&(e="#999999");let i=e.replace("#",""),s=i.match(RegExp("(.{"+i.length/3+"})","g"))||[];for(let e=0;e<s.length;e++)s[e]=parseInt(1===s[e].length?s[e]+s[e]:s[e],16);return void 0!==t&&s.push(t),"rgba("+s.join(",")+")"}static getOpacityFromRGBA(e){return parseFloat(e.replace(/^.*,(.+)\)/,"$1"))}static parseHex(e){if("string"!=typeof e)return null;let t=e.trim().replace("#","");
1return(3===t.length&&(t=t.split("").map(e=>e+e).join("")),/^[0-9a-fA-F]{6}$/.test(t))?[parseInt(t.slice(0,2),16),parseInt(t.slice(2,4),16),parseInt(t.slice(4,6),16)]:null}static relativeLuminance([e,t,i]){let s=e=>{let t=e/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)};return .2126*s(e)+.7152*s(t)+.0722*s(i)}static getContrastRatio(t,i){let s=e.parseHex(t),a=e.parseHex(i);if(!s||!a)return 0;let r=e.relativeLuminance(s),l=e.relativeLuminance(a);return(Math.max(r,l)+.05)/(Math.min(r,l)+.05)}static rgb2hex(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):""}shadeRGBColor(e,t){let i=t.split(","),s=e<0?0:255,a=e<0?-1*e:e,r=parseInt(i[0].slice(4),10),l=parseInt(i[1],10),o=parseInt(i[2],10);return"rgb("+(Math.round((s-r)*a)+r)+","+(Math.round((s-l)*a)+l)+","+(Math.round((s-o)*a)+o)+")"}shadeHexColor(e,t){let i=parseInt(t.slice(1),16),s=e<0?0:255,a=e<0?-1*e:e,r=i>>16,l=i>>8&255,o=255&i;return"#"+(0x1000000+(Math.round((s-r)*a)+r)*65536+(Math.round((s-l)*a)+l)*256+(Math.round((s-o)*a)+o)).toString(16).slice(1)}shadeColor(t,i){return e.isColorHex(i)?this.shadeHexColor(t,i):this.shadeRGBColor(t,i)}static isColorHex(e){return/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)|(^#[0-9A-F]{8}$)/i.test(e)}static isCSSVariable(e){if("string"!=typeof e)return!1;let t=e.trim();return t.startsWith("var(")&&t.endsWith(")")}static getThemeColor(t){let i;if(!e.isCSSVariable(t)||p.isSSR())return t;let s=document.createElement("div");s.style.cssText="position:fixed; left: -9999px; visibility:hidden;",s.style.color=t,document.body.appendChild(s);try{i=window.getComputedStyle(s).color}finally{s.parentNode&&s.parentNode.removeChild(s)}return i}static applyOpacityToColor(e,t){let i=Number(t);if(!Number.isFinite(i))return e;if(i<=0)return"transparent";if(i>=1)return e;let s=Math.round(100*i);return`color-mix(in srgb, ${e} ${s}%, transparent)`}static getPolygonPos(e,t){let i=[],s=2*Math.PI/t;for(let a=0;a<t;a++){let t={};t.x=e*Math.sin(a*s),t.y=-e*Math.cos(a*s),i.push(t)}return i}static polarToCartesian(e,t,i,s){let a=(s-90)*Math.PI/180;return{x:e+i*Math.cos(a),y:t+i*Math.sin(a)}}static escapeString(e,t="x"){let i=e.toString().slice();return i.replace(/[` ~!@#$%^&*()|+=?;:'",.<>{}[\]\\/]/gi,t)}static negToZero(e){return e<0?0:e}static moveIndexInArray(e,t,i){if(i>=e.length){let t=i-e.length+1;for(;t--;)e.push(void 0)}return e.splice(i,0,e.splice(t,1)[0]),e}static extractNumber(e){return parseFloat(e.replace(/[^\d.]*/g,""))}static findAncestor(e,t){for(;(e=e.parentElement)&&!e.classList.contains(t););return e}static setELstyles(e,t){for(let i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e.style.key=t[i])}static preciseAddition(e,t){let i=Math.pow(10,Math.max((String(e).split(".")[1]||"").length,(String(t).split(".")[1]||"").length));return(Math.round(e*i)+Math.round(t*i))/i}static isNumber(e){return!isNaN(e)&&parseFloat(String(Number(e)))===e&&!isNaN(parseInt(e,10))}static isFloat(e){return Number(e)===e&&e%1!=0}static isMsEdge(){if(p.isSSR())return!1;let e=window.navigator.userAgent,t=e.indexOf("Edge/");return t>0&&parseInt(e.substring(t+5,e.indexOf(".",t)),10)}static getGCD(e,t,i=7){let s=Math.pow(10,i-Math.floor(Math.log10(Math.max(e,t))));for(s>1?(e=Math.round(Math.abs(e)*s),t=Math.round(Math.abs(t)*s)):s=1;t;){let i=t;t=e%t,e=i}return e/s}static getPrimeFactors(e){let t=[],i=2;for(;e>=2;)e%i==0?(t.push(i),e/=i):i++;return t}static mod(e,t,i=7){let s=Math.pow(10,i-Math.floor(Math.log10(Math.max(e,t))));return(e=Math.round(Math.abs(e)*s))%(t=Math.round(Math.abs(t)*s))/s}};class A{constructor(e){this.w=e,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]}isValidDate(e){return"number"!=typeof e&&!isNaN(this.parseDate(e))}getTimeStamp(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}getDate(e){return new Date(this.w.config.xaxis.labels.datetimeUTC?new Date(e).toUTCString():e)}parseDate(e){if(!isNaN(Date.parse(e)))return this.getTimeStamp(e);let t=Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "));return this.getTimeStamp(t)}parseDateWithTimezone(e){return Date.parse(e.replace(/-/g,"/").replace(/[a-z]+/gi," "))}formatDate(e,t){let i=this.w.globals.locale,s=this.w.config.xaxis.labels.datetimeUTC,a=["\0",...i.months],r=["\x01",...i.shortMonths],l=["\x02",...i.days],o=["\x03",...i.shortDays];function n(e,t=2){let i=e+"";for(;i.length<t;)i="0"+i;return i}let h=s?e.getUTCFullYear():e.getFullYear();t=(t=(t=t.replace(/(^|[^\\])yyyy+/g,"$1"+h)).replace(/(^|[^\\])yy/g,"$1"+h.toString().substr(2,2))).replace(/(^|[^\\])y/g,"$1"+h);let d=(s?e.getUTCMonth():e.getMonth())+1;t=(t=(t=(t=t.replace(/(^|[^\\])MMMM+/g,"$1"+a[0])).replace(/(^|[^\\])MMM/g,"$1"+r[0])).replace(/(^|[^\\])MM/g,"$1"+n(d))).replace(/(^|[^\\])M/g,"$1"+d);let c=s?e.getUTCDate():e.getDate();t=(t=(t=(t=t.replace(/(^|[^\\])dddd+/g,"$1"+l[0])).replace(/(^|[^\\])ddd/g,"$1"+
1o[0])).replace(/(^|[^\\])dd/g,"$1"+n(c))).replace(/(^|[^\\])d/g,"$1"+c);let g=s?e.getUTCHours():e.getHours();t=(t=t.replace(/(^|[^\\])HH+/g,"$1"+n(g))).replace(/(^|[^\\])H/g,"$1"+g);let p=g>12?g-12:0===g?12:g;t=(t=t.replace(/(^|[^\\])hh+/g,"$1"+n(p))).replace(/(^|[^\\])h/g,"$1"+p);let x=s?e.getUTCMinutes():e.getMinutes();t=(t=t.replace(/(^|[^\\])mm+/g,"$1"+n(x))).replace(/(^|[^\\])m/g,"$1"+x);let u=s?e.getUTCSeconds():e.getSeconds();t=(t=t.replace(/(^|[^\\])ss+/g,"$1"+n(u))).replace(/(^|[^\\])s/g,"$1"+u);let f=s?e.getUTCMilliseconds():e.getMilliseconds();t=t.replace(/(^|[^\\])fff+/g,"$1"+n(f,3)),f=Math.round(f/10),t=t.replace(/(^|[^\\])ff/g,"$1"+n(f)),f=Math.round(f/10);let m=g<12?"AM":"PM";t=(t=(t=t.replace(/(^|[^\\])f/g,"$1"+f)).replace(/(^|[^\\])TT+/g,"$1"+m)).replace(/(^|[^\\])T/g,"$1"+m.charAt(0));let b=m.toLowerCase();t=(t=t.replace(/(^|[^\\])tt+/g,"$1"+b)).replace(/(^|[^\\])t/g,"$1"+b.charAt(0));let y=-e.getTimezoneOffset(),w=s||!y?"Z":y>0?"+":"-";if(!s){let e=Math.floor((y=Math.abs(y))/60),t=y%60;w+=n(e)+":"+n(t)}t=t.replace(/(^|[^\\])K/g,"$1"+w);let v=(s?e.getUTCDay():e.getDay())+1;return t=(t=(t=(t=(t=t.replace(RegExp(l[0],"g"),l[v])).replace(RegExp(o[0],"g"),o[v])).replace(RegExp(a[0],"g"),a[d])).replace(RegExp(r[0],"g"),r[d])).replace(/\\(.)/g,"$1")}getTimeUnitsfromTimestamp(e,t){let i=this.w;void 0!==i.config.xaxis.min&&(e=i.config.xaxis.min),void 0!==i.config.xaxis.max&&(t=i.config.xaxis.max);let s=this.getDate(e),a=this.getDate(t),r=this.formatDate(s,"yyyy MM dd HH mm ss fff").split(" "),l=this.formatDate(a,"yyyy MM dd HH mm ss fff").split(" ");return{minMillisecond:parseInt(r[6],10),maxMillisecond:parseInt(l[6],10),minSecond:parseInt(r[5],10),maxSecond:parseInt(l[5],10),minMinute:parseInt(r[4],10),maxMinute:parseInt(l[4],10),minHour:parseInt(r[3],10),maxHour:parseInt(l[3],10),minDate:parseInt(r[2],10),maxDate:parseInt(l[2],10),minMonth:
1parseInt(r[1],10)-1,maxMonth:parseInt(l[1],10)-1,minYear:parseInt(r[0],10),maxYear:parseInt(l[0],10)}}isLeapYear(e){return e%4==0&&e%100!=0||e%400==0}calculcateLastDaysOfMonth(e,t,i){return this.determineDaysOfMonths(e,t)-i}determineDaysOfYear(e){let t=365;return this.isLeapYear(e)&&(t=366),t}determineRemainingDaysOfYear(e,t,i){let s=this.daysCntOfYear[t]+i;return t>1&&this.isLeapYear(e)&&s++,s}determineDaysOfMonths(e,t){let i=30;switch(e=v.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}}class C{constructor(e){this.w=e,this.tooltipKeyFormat="dd MMM"}xLabelFormat(e,t,i,s){let a=this.w;if("datetime"===a.config.xaxis.type&&void 0===a.config.xaxis.labels.formatter&&void 0===a.config.tooltip.x.formatter){let e=new A(this.w);return e.formatDate(e.getDate(t),a.config.tooltip.x.format)}return e(t,i,s)}defaultGeneralFormatter(e){return Array.isArray(e)?e.map(e=>e):e}defaultYFormatter(e,t){let i=this.w;if(v.isNumber(e))if(0!==i.globals.yValueDecimal)e=e.toFixed(void 0!==t.decimalsInFloat?t.decimalsInFloat:i.globals.yValueDecimal);else{let t=e.toFixed(0);e=Number(t)===e?t:e.toFixed(1)}return e}setLabelFormatters(){let e=this.w,t=e.formatters;return t.xaxisTooltipFormatter=e=>this.defaultGeneralFormatter(e),t.ttKeyFormatter=e=>this.defaultGeneralFormatter(e),t.ttZFormatter=e=>e,t.legendFormatter=e=>this.defaultGeneralFormatter(e),void 0!==e.config.xaxis.labels.formatter?t.xLabelFormatter=e.config.xaxis.labels.formatter:t.xLabelFormatter=t=>{if(v.isNumber(t)){if(!e.config.xaxis.convertedCatToNumeric&&"numeric"===e.config.xaxis.type)if(v.isNumber(e.config.xaxis.decimalsInFloat))return t.toFixed(e.config.xaxis.decimalsInFloat);else{let i=e.globals.maxX-e.globals.minX;return i>0&&i<100?t.toFixed(1):t.toFixed(0)}return e.globals.isBarHorizontal&&e.globals.maxY-e.globals.minYArr<4?t.toFixed(1):t.toFixed(0)}return t},"function"==typeof e.config.tooltip.x.formatter?t.ttKeyFormatter=e.config.tooltip.x.formatter:t.ttKeyFormatter=t.xLabelFormatter,"function"==typeof e.config.xaxis.tooltip.formatter&&(t.xaxisTooltipFormatter=e.config.xaxis.tooltip.formatter),Array.isArray(e.config.tooltip.y)?t.ttVal=e.config.tooltip.y:void 0!==e.config.tooltip.y.formatter&&(t.ttVal=e.config.tooltip.y),void 0!==e.config.tooltip.z.formatter&&(t.ttZFormatter=e.config.tooltip.z.formatter),void 0!==e.config.legend.formatter&&(t.legendFormatter=e.config.legend.formatter),t.yLabelFormatters=[],e.config.yaxis.forEach((i,s)=>{void 0!==i.labels.formatter?t.yLabelFormatters[s]=i.labels.formatter:t.yLabelFormatters[s]=t=>e.globals.xyCharts?Array.isArray(t)?t.map(e=>this.defaultYFormatter(e,i)):this.defaultYFormatter(t,i):t}),e.globals}heatmapLabelFormatters(){let e=this.w;if("heatmap"===e.config.chart.type){e.globals.yAxisScale[0].result=e.seriesData.seriesNames.slice();let t=e.seriesData.seriesNames.reduce((e,t)=>e.length>t.length?e:t,0);e.globals.yAxisScale[0].niceMax=t,e.globals.yAxisScale[0].niceMin=t}}}let S=({isTimeline:e,seriesIndex:t,dataPointIndex:i,y1:s,y2:a,w:r})=>{var l;let o=r.rangeData.seriesRangeStart[t][i],n=r.rangeData.seriesRangeEnd[t][i],h=r.labelData.labels[i],d=r.config.series[t].name?r.config.series[t].name:"",c=r.formatters.ttKeyFormatter,g=r.config.tooltip.y.title.formatter,p={w:r,seriesIndex:t,dataPointIndex:i,start:o,end:n};"function"==typeof g&&(d=g(d,p)),(null==(l=r.config.series[t].data[i])?void 0:l.x)&&(h=r.config.series[t].data[i].x),e||"datetime"!==r.config.xaxis.type||(h=new C(r).xLabelFormat(r.formatters.ttKeyFormatter,h,h,{i:void 0,dateFormatter:new A(r).formatDate,w:r})),"function"==typeof c&&(h=c(h,p)),Number.isFinite(s)&&Number.isFinite(a)&&(o=s,n=a);let x="",u="",f=r.globals.colors[t];if(void 0===r.config.tooltip.x.formatter)if("datetime"===r.config.xaxis.type){let e=new A(r);x=e.formatDate(e.getDate(o),r.config.tooltip.x.format),u=e.formatDate(e.getDate(n),r.config.tooltip.x.format)}else x=o,u=n;else x=r.config.tooltip.x.formatter(o),u=r.config.tooltip.x.formatter(n);return{start:o,end:n,startVal:x,endVal:u,ylabel:h,color:f,seriesName:d}},k=e=>{let{color:t,seriesName:i,ylabel:s,start:a,end:r,seriesIndex:l,dataPointIndex:o}=e,n=e.w.globals.tooltip.tooltipLabels.getFormatters(l);a=n.yLbFormatter(a),r=n.yLbFormatter(r);let h=n.yLbFormatter(e.w.seriesData.series[l][o]),d=`<span class="value start-value">
2  ${a}
3  </span> <span class="separator">-</span> <span class="value end-value">
4  ${r}
5  </span>`;return'<div class="apexcharts-tooltip-rangebar"><div> <span class="series-name" style="color: '+t+'">'+(i||"")+'</span></div><div> <span class="category">'+s+": </span> "+(e.w.globals.comboCharts?"rangeArea"===e.w.config.series[l].t
5ype||"rangeBar"===e.w.config.series[l].type?d:`<span>${h}</span>`:d)+" </div></div>"};class D{constructor(e){this.opts=e}hideYAxis(){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}line(){return{dataLabels:{enabled:!1},stroke:{width:5,curve:"straight"},markers:{size:0,hover:{sizeOffset:6}},xaxis:{crosshairs:{width:1}}}}sparkline(e){return this.hideYAxis(),v.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}})}slope(){return this.hideYAxis(),{chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!0,formatter(e,t){let 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"}}}bar(){return{chart:{stacked:!1},plotOptions:{bar:{dataLabels:{position:"center"}}},dataLabels:{style:{colors:["#fff"]},background:{enabled:!1}},stroke:{width:0,lineCap:"square"},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}}}}}funnel(){return this.hideYAxis(),c(d({},this.bar()),{chart:{animations:{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}}})}candlestick(){return{stroke:{width:1},fill:{opacity:1},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:({seriesIndex:e,dataPointIndex:t,w:i})=>this._getBoxTooltip(i,e,t,["Open","High","","Low","Close"],"candlestick")},states:{active:{filter:{type:"none"}}},xaxis:{crosshairs:{width:1}}}}boxPlot(){return{chart:{animations:{dynamicAnimation:{enabled:!1}}},stroke:{width:1,colors:["#24292e"]},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:({seriesIndex:e,dataPointIndex:t,w:i})=>this._getBoxTooltip(i,e,t,["Minimum","Q1","Median","Q3","Maximum"],"boxPlot")},markers:{size:7,strokeWidth:1,strokeColors:"#111"},xaxis:{crosshairs:{width:1}}}}rangeBar(){return{chart:{animations:{animateGradually:!1}},stroke:{width:0,lineCap:"square"},plotOptions:{bar:{borderRadius:0,dataLabels:{position:"center"}}},dataLabels:{enabled:!1,formatter(e,{seriesIndex:t,dataPointIndex:i,w:s}){let a=()=>{let e=s.rangeData.seriesRangeStart[t][i];return s.rangeData.seriesRangeEnd[t][i]-e};return s.globals.comboCharts?"rangeBar"===s.config.series[t].type||"rangeArea"===s.config.series[t].type?a():e:a()},background:{enabled:!1},style:{colors:["#fff"]}},markers:{size:10},tooltip:{shared:!1,followCursor:!0,custom:e=>e.w.config.plotOptions&&e.w.config.plotOptions.bar&&e.w.config.plotOptions.bar.horizontal?(e=>{let{color:t,seriesName:i,ylabel:s,startVal:a,endVal:r}=S(c(d({},e),{isTimeline:!0}));return k(c(d({},e),{color:t,seriesName:i,ylabel:s,start:a,end:r}))})(e):(e=>{let{color:t,seriesName:i,ylabel:s,start:a,end:r}=S(e);return k(c(d({},e),{color:t,seriesName:i,ylabel:s,start:a,end:r}))})(e)},xaxis:{tickPlacement:"between",tooltip:{enabled:!1},crosshairs:{stroke:{width:0}}}}}dumbbell(e){var t,i;return(null==(t=e.plotOptions.bar)?void 0:t.barHeight)||(e.plotOptions.bar.barHeight=2),(null==(i=e.plotOptions.bar)?void 0:i.columnWidth)||(e.plotOptions.bar.columnWidth=2),e}area(){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}}}rangeArea(){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:e=>(e=>{let{color:t,seriesName:i,ylabel:s,start:a,end:r}=S(e);return k(c(d({},e),{color:t,seriesName:i,ylabel:s,start:a,end:r}))})(e)}}}brush(e){return v.extend(e,{chart:{toolbar:{autoSelected:"selection",show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1},stroke:{width:1},tooltip:{enabled:!1},xaxis:{tooltip:{enabled:!1}}})}stacked100(e){e.dataLabels=e.dataLabels||{},e.dataLabels.formatter=e.dataLabels.formatter||void 0;let t=e.dataLabels.formatter;return e.yaxis.forEach((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}stackedBars(){let e=this.bar();return c(d({},e),{plotOptions:c(d({},e.plotOptions),{bar:c(d({},e.plotOptions.bar),{borderRadiusApplication:"end",borderRadiusWhenStacked:"last"})})})}
5convertCatToNumeric(e){return e.xaxis.convertedCatToNumeric=!0,e}convertCatToNumericXaxis(e,t){e.xaxis.type="numeric",e.xaxis.labels=e.xaxis.labels||{},e.xaxis.labels.formatter=e.xaxis.labels.formatter||function(e){return v.isNumber(e)?Math.floor(e):e};let i=e.xaxis.labels.formatter,s=e.xaxis.categories&&e.xaxis.categories.length?e.xaxis.categories:e.labels;return t&&t.length&&(s=t.map(e=>Array.isArray(e)?e:String(e))),s&&s.length&&(e.xaxis.labels.formatter=function(e){return v.isNumber(e)?i(s[Math.floor(e)-1]):i(e)}),e.xaxis.categories=[],e.labels=[],e.xaxis.tickAmount=e.xaxis.tickAmount||"dataPoints",e}bubble(){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}}}}scatter(){return{dataLabels:{enabled:!1},tooltip:{shared:!1,intersect:!0},markers:{size:6,strokeWidth:1,hover:{sizeOffset:2}}}}heatmap(){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}}}}treemap(){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}}}}pie(){return{chart:{toolbar:{show:!1}},plotOptions:{pie:{donut:{labels:{show:!1}}}},dataLabels:{formatter:e=>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"},grid:{padding:{left:0,right:0,top:0,bottom:0}}}}donut(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:e=>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"},grid:{padding:{left:0,right:0,top:0,bottom:0}}}}polarArea(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:e=>e.toFixed(1)+"%",enabled:!1},stroke:{show:!0,width:2},fill:{opacity:.7},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"},grid:{padding:{left:0,right:0,top:0,bottom:0}}}}radar(){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,padding:{left:0,right:0,top:0,bottom:0}},xaxis:{labels:{formatter:e=>e,style:{colors:["#a8a8a8"],fontSize:"11px"}},tooltip:{enabled:!1},crosshairs:{show:!1}}}}radialBar(){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},grid:{padding:{left:0,right:0,top:0,bottom:0}}}}_getBoxTooltip(e,t,i,s,a){let r=e.candleData.seriesCandleO[t][i],l=e.candleData.seriesCandleH[t][i],o=e.candleData.seriesCandleM[t][i],n=e.candleData.seriesCandleL[t][i],h=e.candleData.seriesCandleC[t][i],d=e.config.series[t];return d.type&&d.type!==a?`<div class="apexcharts-custom-tooltip">
6          ${d.name?d.name:"series-"+(t+1)}: <strong>${e.seriesData.series[t][i]}</strong>
7        </div>`:`<div class="apexcharts-tooltip-box apexcharts-tooltip-${e.config.chart.type}"><div>${s[0]}: <span class="value">`+r+`</span></div><div>${s[1]}: <span class="value">`+l+"</span></div>"+(o?`<div>${s[2]}: <span class="value">`+o+"</span></div>":"")+`<div>${s[3]}: <span class="value">`+n+`</span></div><div>${s[4]}: <span class="value">`+h+"</span></div></div>"}}let L={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","Frid
7ay","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"}}};class M{constructor(){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,showDuplicates:!1,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}}init(){return{annotations:{yaxis:[this.yAxisAnnotation],xaxis:[this.xAxisAnnotation],points:[this.pointAnnotation],texts:[],images:[],shapes:[]},chart:{animations:{enabled:!0,speed:800,animateGradually:{delay:150,enabled:!0},dynamicAnimation:{enabled:!0,speed:350}},background:"",locales:[L],defaultLocale:"en",dropShadow:{enabled:!1,enabledOnSeries:void 0,top:2,left:2,blur:4,color:"#000",opacity:.7},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,keyDown:void 0,keyUp: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,injectStyleSheet:!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},scale:void 0,width:void 0},autoSelected:"zoom"},type:"line",width:"100%",zoom:{enabled:!0,type:"x",autoScaleYaxis:!1,allowMouseWheelZoom:!0,zoomedArea:{fill:{color:"#90CAF9",opacity:.4},stroke:{color:"#0D47A1",opacity:.4,width:1}}},accessibility:{enabled:!0,description:void 0,announcements:{enabled:!0},keyboard:{enabled:!0,navigation:{enabled:!0,wrapAround:!1}}},dataReducer:{enabled:!1,algorithm:"lttb",targetPoints:250,threshold:500}},parsing:{x:void 0,y:void 0},plotOptions:{line:{isSlopeChart:!1,colors:{threshold:0,colorAboveThreshold:void 0,colorBelowThreshold:void 0}},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"}}
vendor: 4,450 bytes, line 7
7,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},seriesTitle:{show:!0,offsetY:1,offsetX:1,borderColor:"#000",borderWidth:1,borderRadius:2,style:{background:"rgba(0, 0, 0, 0.6)",color:"#fff",fontSize:"12px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:6,right:6,top:2,bottom:2}}}},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:e=>e},value:{show:!0,fontSize:"14px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:16,formatter:e=>e+"%"},total:{show:!1,label:"Total",fontSize:"16px",fontWeight:600,fontFamily:void 0,color:void 0,formatter:e=>e.globals.seriesTotals.reduce((e,t)=>e+t,0)/e.seriesData.series.length+"%"}},barLabels:{enabled:!1,offsetX:0,offsetY:0,useSeriesColors:!0,fontFamily:void 0,fontWeight:600,fontSize:"16px",formatter:e=>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:e=>e},value:{show:!0,fontSize:"20px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:10,formatter:e=>e},total:{show:!1,showAlways:!1,label:"Total",fontSize:"16px",fontWeight:400,fontFamily:void 0,color:void 0,formatter:e=>e.globals.seriesTotals.reduce((e,t)=>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:e=>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",backgroundColor:void 0,borderRadius:2,padding:4,opacity:.9,borderWidth:1,borderColor:"#fff",dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.8}},dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.8}},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:[],clusterGroupedSeries:!0,clusterGroupedSeriesOrientation:"vertical",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}}
7,noData:{text:void 0,align:"center",offsetX:0,offsetY:0,style:{color:void 0,fontSize:"14px",fontFamily:void 0}},responsive:[],series:void 0,states:{hover:{filter:{type:"lighten"}},active:{allowMultipleDataPointsSelection:!1,filter:{type:"darken"}}},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:e=>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:.8}},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},accessibility:{colorBlindMode:""}}}}}class P{constructor(e){this.opts=e}init({responsiveOverride:e}){var t,i,s,a,r,l,o,n,h,d;let c=this.opts,g=new M,x=new D(c);this.chartType=c.chart.type,c=this.extendYAxis(c),c=this.extendAnnotations(c);let u=g.init(),f={};if(c&&"object"==typeof c){let g={};g=-1!==["line","area","bar","candlestick","boxPlot","rangeBar","rangeArea","bubble","scatter","heatmap","treemap","pie","polarArea","donut","radar","radialBar"].indexOf(c.chart.type)?x[c.chart.type]():x.line(),(null==(i=null==(t=c.plotOptions)?void 0:t.bar)?void 0:i.isFunnel)&&(g=x.funnel()),c.chart.stacked&&"bar"===c.chart.type&&(g=x.stackedBars()),(null==(s=c.chart.brush)?void 0:s.enabled)&&(g=x.brush(g)),(null==(r=null==(a=c.plotOptions)?void 0:a.line)?void 0:r.isSlopeChart)&&(g=x.slope()),c.chart.stacked&&"100%"===c.chart.stackType&&(c=x.stacked100(c)),(null==(o=null==(l=c.plotOptions)?void 0:l.bar)?void 0:o.isDumbbell)&&(c=x.dumbbell(c)),this.checkForDarkTheme(p.getApex()),this.checkForDarkTheme(c),c.xaxis=c.xaxis||p.getApex().xaxis||{},e||(c.xaxis.convertedCatToNumeric=!1),((null==(n=(c=this.checkForCatToNumericXAxis(this.chartType,g,c)).chart.sparkline)?void 0:n.enabled)||(null==(d=null==(h=p.getApex().chart)?void 0:h.sparkline)?void 0:d.enabled))&&(g=x.sparkline(g)),f=v.extend(u,g)}let m=v.extend(f,p.getApex());return u=v.extend(m,c),u=this.handleUserInputErrors(u)}checkForCatToNumericXAxis(e,t,i){var s,a;let r=new D(i),l=("bar"===e||"boxPlot"===e)&&(null==(a=null==(s=i.plotOptions)?void 0:s.bar)?void 0:a.horizontal),o="pie"===e||"polarArea"===e||"donut"===e||"radar"===e||"radialBar"===e||"heatmap"===e,n="datetime"!==i.xaxis.type&&"numeric"!==i.xaxis.type,h=i.xaxis.tickPlacement?i.xaxis.tickPlacement:t.xaxis&&t.xaxis.tickPlacement;return l||o||!n||"between"===h||(i=r.convertCatToNumeric(i)),i}extendYAxis(e,t){let i=new M;(void 0===e.yaxis||!e.yaxis||Array.isArray(e.yaxis)&&0===e.yaxis.length)&&(e.yaxis={});let s=p.getApex();
7e.yaxis.constructor!==Array&&s.yaxis&&s.yaxis.constructor!==Array&&(e.yaxis=v.extend(e.yaxis,s.yaxis)),e.yaxis.constructor!==Array?e.yaxis=[v.extend(i.yAxis,e.yaxis)]:e.yaxis=v.extendArray(e.yaxis,i.yAxis);let a=!1;e.yaxis.forEach(e=>{e.logarithmic&&(a=!0)});let r=e.series;return t&&!r&&(r=t.config.series),a&&r.length!==e.yaxis.length&&r.length&&(e.yaxis=r.map((t,s)=>{if(t.name||(r[s].name=`series-${s+1}`),e.yaxis[s])return e.yaxis[s].seriesName=r[s].name,e.yaxis[s];{let t=v.extend(i.yAxis,e.yaxis[0]);return t.show=!1,t}})),a&&r.length>1&&r.length!==e.yaxis.length&&console.warn("A multi-series logarithmic chart should have equal number of series and y-axes"),e}extendAnnotations(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),e=this.extendPointAnnotations(e)}extendYAxisAnnotations(e){let t=new M;return e.annotations.yaxis=v.extendArray(void 0!==e.annotations.yaxis?e.annotations.yaxis:[],t.yAxisAnnotation),e}extendXAxisAnnotations(e){let t=new M;return e.annotations.xaxis=v.extendArray(void 0!==e.annotations.xaxis?e.annotations.xaxis:[],t.xAxisAnnotation),e}extendPointAnnotations(e){let t=new M;return e.annotations.points=v.extendArray(void 0!==e.annotations.points?e.annotations.points:[],t.pointAnnotation),e}checkForDarkTheme(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"))}handleUserInputErrors(e){if(e.tooltip.shared&&e.tooltip.intersect)throw Error("tooltip.shared cannot be enabled when tooltip.intersect is true. Turn off any other option by setting it to false.");if("bar"===e.chart.type&&e.plotOptions.bar.horizontal){if(e.yaxis.length>1)throw Error("Multiple Y Axis for bars are not supported. Switch to column chart by setting plotOptions.bar.horizontal=false");e.yaxis[0].reversed&&(e.yaxis[0].opposite=!0),e.xaxis.tooltip.enabled=!1,e.yaxis[0].tooltip.enabled=!1,e.chart.zoom.enabled=!1}return("bar"===e.chart.type||"rangeBar"===e.chart.type)&&e.tooltip.shared&&"barWidth"===e.xaxis.crosshairs.width&&e.series.length>1&&(e.xaxis.crosshairs.width="tickWidth"),("candlestick"===e.chart.type||"boxPlot"===e.chart.type)&&e.yaxis[0].reversed&&(console.warn(`Reversed y-axis in ${e.chart.type} chart is not supported.`),e.yaxis[0].reversed=!1),e}}let E=[[1,1,2,5,5,5,10,10,10,10,10],[1,1,2,5,5,5,10,10,10,10,10]],T=[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];class F{initGlobalVars(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.dataWasParsed=!1,e.originalSeries=null,e.maxValsInArrayIndex=0,e.yValueDecimal=0,e.allSeriesHasEqualX=!0,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.isXNumeric=!1,e.skipLastTimelinelabel=!1,e.skipFirstTimelinelabel=!1,e.isDataXYZ=!1,e.isMultiLineX=!1,e.isMultipleYAxis=!1,e.maxY=-Number.MAX_VALUE,e.minY=5e-324,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.xRange=0,e.yRange=[],e.zRange=0,e.dataPoints=0,e.xTickAmount=0,e.multiAxisTickAmount=0,e.disableZoomIn=!1,e.disableZoomOut=!1,e.yLabelsCoords=[],e.yTitleCoords=[],e.barPadForNumericAxis=0,e.padHorizontal=0,e.rotateXLabels=!1,e.overlappingXLabels=!1,e.radialSize=0,e.barHeight=0,e.barWidth=0,e.animationEnded=!1,e.resizeTimer=null,e.selectionResizeTimer=null,e.lastWheelExecution=0,e.delayedElements=[],e.pointsArray=[],e.dataLabelsRects=[],e.lastDrawnDataLabelsIndexes=[],e.textRectsCache=new Map,e.domCache=new Map,e.dimensionCache={},e.cachedSelectors={},e.seriesNS||this._attachNamespaces(e)}_attachNamespaces(e){let t=(t,i,s=i)=>{Object.defineProperty(t,s,{get:()=>e[i],set(t){e[i]=t},enumerable:!0,configurable:!0})},i={};for(let e of(t(i,"series","data"),["seriesNames","seriesX","seriesZ","seriesXvalues","seriesYvalues","seriesGoals","seriesLog","seriesColors","seriesPercent","seriesTotals","stackedSeriesTotals","seriesCandleO","seriesCandleH","seriesCandleM","seriesCandleL","seriesCandleC","seriesRangeStart","seriesRangeEnd","seriesRange","seriesYAxisMap","seriesYAxisReverseMap","seriesGroups","barGroups","lineGroups","areaGroups","originalSeries","collapsedSeries","collapsedSeriesIndices","ancillaryCollapsedSeries","ancillaryCollapsedSeriesIndices","allSeriesCollapsed","risingSeries","previousPaths","ignoreYAxisIndexes","labels","categoryLabels","timescaleLabels","groups"]))t(i,e);Object.defineProperty(e,"seriesNS",{value:i,writable:!1,enumerable:!1,
7configurable:!0});let s={};for(let e of["minX","maxX","initialMinX","initialMaxX","minY","maxY","minYArr","maxYArr","minZ","maxZ","minDate","maxDate","minXDiff","xRange","yRange","zRange","xAxisScale","yAxisScale","xAxisTicksPositions","xTickAmount","multiAxisTickAmount","dataPoints","maxValsInArrayIndex","isXNumeric","isMultipleYAxis","isMultiLineX","isDataXYZ","dataFormatXNumeric","allSeriesHasEqualX","hasNullValues","dataWasParsed","hasXaxisGroups","hasSeriesGroups","skipFirstTimelinelabel","skipLastTimelinelabel","yValueDecimal","invalidLogScale","noLabelsProvided"])t(s,e);Object.defineProperty(e,"axes",{value:s,writable:!1,enumerable:!1,configurable:!0});let a={};for(let e of["svgWidth","svgHeight","gridWidth","gridHeight","translateX","translateY","translateXAxisX","translateXAxisY","translateYAxisX","xAxisLabelsHeight","xAxisGroupLabelsHeight","xAxisLabelsWidth","yAxisLabelsWidth","yAxisWidths","yLabelsCoords","yTitleCoords","padHorizontal","barPadForNumericAxis","rotateXLabels","scaleX","scaleY","radialSize","defaultLabels","overlappingXLabels"])t(a,e);Object.defineProperty(e,"layout",{value:a,writable:!1,enumerable:!1,configurable:!0});let r={};for(let e of["domCache","dimensionCache","cachedSelectors","textRectsCache","pointsArray","dataLabelsRects","lastDrawnDataLabelsIndexes","delayedElements","resizeTimer","selectionResizeTimer","resizeObserver"])t(r,e);Object.defineProperty(e,"cache",{value:r,writable:!1,enumerable:!1,configurable:!0})}globalVars(e){return{chartID:null,cuid:null,events:{beforeMount:[],mounted:[],updated:[],clicked:[],selection:[],dataPointSelection:[],zoomed:[],scrolled:[]},colors:[],fill:{colors:[]},stroke:{colors:[]},dataLabels:{style:{colors:[]}},radarPolygons:{fill:{colors:[]}},markers:{colors:[],size:e.markers.size,largestSize:0},LINE_HEIGHT_RATIO:1.618,axisCharts:!0,isSlopeChart:e.plotOptions.line.isSlopeChart,comboCharts:!1,initialConfig:null,initialSeries:[],lastXAxis:[],lastYAxis:[],allSeriesCollapsed:!1,collapsedSeries:[],collapsedSeriesIndices:[],ancillaryCollapsedSeries:[],ancillaryCollapsedSeriesIndices:[],risingSeries:[],ignoreYAxisIndexes:[],isDirty:!1,isExecCalled:!1,dataChanged:!1,resized:!1,invalidLogScale:!1,hasNullValues:!1,columnSeries:null,yaxis:null,total:0,shouldAnimate:!0,previousPaths:[],svgWidth:0,svgHeight:0,defaultLabels:!1,yAxisLabelsWidth:0,scaleX:1,scaleY:1,translateYAxisX:[],yAxisWidths:[],tooltip:null,resizeObserver:null,locale:{},memory:{methodsToExec:[]},niceScaleAllowedMagMsd:E,niceScaleDefaultTicks:T,seriesYAxisMap:[],seriesYAxisReverseMap:[],noData:!1}}init(e){let t=this.globalVars(e);return this.initGlobalVars(t),t.initialConfig=v.extend({},e),t.initialSeries=v.clone(e.series),t.lastXAxis=v.clone(t.initialConfig.xaxis),t.lastYAxis=v.clone(t.initialConfig.yaxis),t}}class X{constructor(e){this.opts=e}init(){let e=new P(this.opts).init({responsiveOverride:!1}),t=new F().init(e),i={config:e,globals:t,dom:{},interact:{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,zoomed:!1,selection:void 0,visibleXRange:void 0,selectedDataPoints:[],mousedown:!1,clientX:null,clientY:null,lastClientPosition:{},lastWheelExecution:0,capturedSeriesIndex:-1,capturedDataPointIndex:-1,disableZoomIn:!1,disableZoomOut:!1,isTouchDevice:!!p.isBrowser()&&("ontouchstart"in window||navigator.maxTouchPoints>0)},formatters:{xLabelFormatter:void 0,yLabelFormatters:[],xaxisTooltipFormatter:void 0,ttKeyFormatter:void 0,ttVal:void 0,ttZFormatter:void 0,legendFormatter:void 0},candleData:{seriesCandleO:[],seriesCandleH:[],seriesCandleM:[],seriesCandleL:[],seriesCandleC:[]},rangeData:{seriesRangeStart:[],seriesRangeEnd:[],seriesRange:[]},labelData:{labels:[],categoryLabels:[],timescaleLabels:[],hasXaxisGroups:!1,groups:[],seriesGroups:[]},axisFlags:{isXNumeric:!1,dataFormatXNumeric:!1,isDataXYZ:!1,isRangeData:!1,isRangeBar:!1,isMultiLineX:!1,noLabelsProvided:!1,dataWasParsed:!1},seriesData:{series:[],seriesNames:[],seriesX:[],seriesZ:[],seriesColors:[],seriesGoals:[],stackedSeriesTotals:[],stackedSeriesTotalsByGroups:[]},layout:{gridHeight:0,gridWidth:0,translateX:0,translateY:0,translateXAxisX:0,translateXAxisY:0,rotateXLabels:!1,xAxisHeight:0,xAxisLabelsHeight:0,xAxisGroupLabelsHeight:0,xAxisLabelsWidth:0,yLabelsCoords:[],yTitleCoords:[]}};for(let e of(Object.defineProperty(t,"dom",{get:()=>i.dom,set(e){i.dom=e}
7,enumerable:!1,configurable:!0}),["xLabelFormatter","yLabelFormatters","xaxisTooltipFormatter","ttKeyFormatter","ttVal","ttZFormatter","legendFormatter"]))Object.defineProperty(t,e,{get:()=>i.formatters[e],set(t){i.formatters[e]=t},enumerable:!1,configurable:!0});for(let e of["zoomEnabled","panEnabled","selectionEnabled","zoomed","selection","visibleXRange","selectedDataPoints","mousedown","clientX","clientY","lastClientPosition","lastWheelExecution","capturedSeriesIndex","capturedDataPointIndex","disableZoomIn","disableZoomOut","isTouchDevice"])Object.defineProperty(t,e,{get:()=>i.interact[e],set(t){i.interact[e]=t},enumerable:!1,configurable:!0});for(let e of["gridHeight","gridWidth","translateX","translateY","translateXAxisX","translateXAxisY","rotateXLabels","xAxisHeight","xAxisLabelsHeight","xAxisGroupLabelsHeight","xAxisLabelsWidth","yLabelsCoords","yTitleCoords"])Object.defineProperty(t,e,{get:()=>i.layout[e],set(t){i.layout[e]=t},enumerable:!1,configurable:!0});for(let e of["series","seriesNames","seriesX","seriesZ","seriesColors","seriesGoals","stackedSeriesTotals","stackedSeriesTotalsByGroups"])Object.defineProperty(t,e,{get:()=>i.seriesData[e],set(t){i.seriesData[e]=t},enumerable:!1,configurable:!0});for(let e of["isXNumeric","dataFormatXNumeric","isDataXYZ","isRangeData","isRangeBar","isMultiLineX","noLabelsProvided","dataWasParsed"])Object.defineProperty(t,e,{get:()=>i.axisFlags[e],set(t){i.axisFlags[e]=t},enumerable:!1,configurable:!0});for(let e of["labels","categoryLabels","timescaleLabels","hasXaxisGroups","groups","seriesGroups"])Object.defineProperty(t,e,{get:()=>i.labelData[e],set(t){i.labelData[e]=t},enumerable:!1,configurable:!0});for(let e of["seriesRangeStart","seriesRangeEnd","seriesRange"])Object.defineProperty(t,e,{get:()=>i.rangeData[e],set(t){i.rangeData[e]=t},enumerable:!1,configurable:!0});for(let e of["seriesCandleO","seriesCandleH","seriesCandleM","seriesCandleL","seriesCandleC"])Object.defineProperty(t,e,{get:()=>i.candleData[e],set(t){i.candleData[e]=t},enumerable:!1,configurable:!0});return i}}class I{constructor(e){this.w=e}static checkComboSeries(e,t){let i=!1,s=0,a=0;return void 0===t&&(t="line"),e.length&&void 0!==e[0].type&&e.forEach(e=>{("bar"===e.type||"column"===e.type||"candlestick"===e.type||"boxPlot"===e.type)&&s++,void 0!==e.type&&e.type!==t&&a++}),a>0&&(i=!0),{comboBarCount:s,comboCharts:i}}getStackedSeriesTotals(e=[]){let t=this.w,i=[];if(0===t.seriesData.series.length)return i;for(let s=0;s<t.seriesData.series[t.globals.maxValsInArrayIndex].length;s++){let a=0;for(let i=0;i<t.seriesData.series.length;i++)void 0!==t.seriesData.series[i][s]&&-1===e.indexOf(i)&&(a+=t.seriesData.series[i][s]);i.push(a)}return i}getSeriesTotalByIndex(e=null){return null===e?this.w.config.series.reduce((e,t)=>e+t,0):this.w.seriesData.series[e].reduce((e,t)=>e+t,0)}getStackedSeriesTotalsByGroups(){let e=this.w,t=[];return e.labelData.seriesGroups.forEach(i=>{let s=[];e.config.series.forEach((t,a)=>{i.indexOf(e.seriesData.seriesNames[a])>-1&&s.push(a)});let a=e.seriesData.series.map((e,t)=>-1===s.indexOf(t)?t:-1).filter(e=>-1!==e);t.push(this.getStackedSeriesTotals(a))}),t}setSeriesYAxisMappings(){let e=this.w.globals,t=this.w.config,i=[],s=[],a=[],r=this.w.seriesData.series.length>t.yaxis.length||t.yaxis.some(e=>Array.isArray(e.seriesName));t.series.forEach((e,t)=>{a.push(t),s.push(null)}),t.yaxis.forEach((e,t)=>{i[t]=[]});let l=[];t.yaxis.forEach((e,s)=>{let o=!1;if(e.seriesName){let l=[];Array.isArray(e.seriesName)?l=e.seriesName:l.push(e.seriesName),l.forEach(e=>{t.series.forEach((t,l)=>{if(t.name===e){let e=l;s===l||r?!r||a.indexOf(l)>-1?i[s].push([s,l]):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[l].push([l,s]),e=s),o=!0,-1!==(e=a.indexOf(e))&&a.splice(e,1)}})})}o||l.push(s)}),i=i.map(e=>{let t=[];return e.forEach(e=>{s[e[1]]=e[0],t.push(e[1])}),t});let o=t.yaxis.length-1;for(let e=0;e<l.length;e++)if(i[o=l[e]]=[],a){let e=a[0];a.shift(),i[o].push(e),s[e]=o}else break;
7a.forEach(e=>{i[o].push(e),s[e]=o}),e.seriesYAxisMap=i.map(e=>e),e.seriesYAxisReverseMap=s.map(e=>e),e.seriesYAxisMap.forEach((e,i)=>{e.forEach(e=>{t.series[e]&&void 0===t.series[e].group&&(t.series[e].group="apexcharts-axis-".concat(i.toString()))})})}isSeriesNull(e=null){return 0===(null===e?this.w.config.series.filter(e=>null!==e):this.w.config.series[e].data.filter(e=>null!==e)).length}seriesHaveSameValues(e){return this.w.seriesData.series[e].every((e,t,i)=>e===i[0])}getCategoryLabels(e){let t=this.w,i=e.slice();return t.config.xaxis.convertedCatToNumeric&&(i=e.map(e=>t.config.xaxis.labels.formatter(e-t.globals.minX+1))),i}getLargestSeries(){let e=this.w;e.globals.maxValsInArrayIndex=e.seriesData.series.map(e=>e.length).indexOf(Math.max.apply(Math,e.seriesData.series.map(e=>e.length)))}getLargestMarkerSize(){let e=this.w,t=0;return e.globals.markers.size.forEach(e=>{t=Math.max(t,e)}),e.config.markers.discrete&&e.config.markers.discrete.length&&e.config.markers.discrete.forEach(e=>{t=Math.max(t,e.size)}),t>0&&(e.config.markers.hover.size>0?t=e.config.markers.hover.size:t+=e.config.markers.hover.sizeOffset),e.globals.markers.largestSize=t,t}getSeriesTotals(){let e=this.w;e.globals.seriesTotals=e.seriesData.series.map(e=>{let t=0;if(Array.isArray(e))for(let i=0;i<e.length;i++)t+=e[i];else t+=e;return t})}getSeriesTotalsXRange(e,t){let i=this.w;return i.seriesData.series.map((s,a)=>{let r=0;for(let l=0;l<s.length;l++)i.seriesData.seriesX[a][l]>e&&i.seriesData.seriesX[a][l]<t&&(r+=s[l]);return r})}getPercentSeries(){let e=this.w;e.globals.seriesPercent=e.seriesData.series.map(t=>{let i=[];if(Array.isArray(t))for(let s=0;s<t.length;s++){let a=e.seriesData.stackedSeriesTotals[s],r=0;a&&(r=100*t[s]/a),i.push(r)}else{let s=100*t/e.globals.seriesTotals.reduce((e,t)=>e+t,0);i.push(s)}return i})}getCalculatedRatios(){let e=this.w,t=e.globals,i=[],s=0,a=0,r=0,l=0,o=[],n=.1,h=0;if(t.yRange=[],t.isMultipleYAxis)for(let e=0;e<t.minYArr.length;e++)t.yRange.push(Math.abs(t.minYArr[e]-t.maxYArr[e])),o.push(0);else t.yRange.push(Math.abs(t.minY-t.maxY));t.xRange=Math.abs(t.maxX-t.minX),t.zRange=Math.abs(t.maxZ-t.minZ);for(let e=0;e<t.yRange.length;e++)i.push(t.yRange[e]/this.w.layout.gridHeight);if(a=t.xRange/this.w.layout.gridWidth,s=t.yRange/this.w.layout.gridWidth,r=t.xRange/this.w.layout.gridHeight,(l=t.zRange/this.w.layout.gridHeight*16)||(l=1),5e-324!==t.minY&&0!==Math.abs(t.minY)&&(t.hasNegs=!0),e.globals.seriesYAxisReverseMap.length>0){let r=(t,s)=>{let a=e.config.yaxis[e.globals.seriesYAxisReverseMap[s]],r=t<0?-1:1;return t=Math.abs(t),a.logarithmic&&(t=this.getBaseLog(a.logBase,t)),-r*t/i[s]};if(t.isMultipleYAxis){o=[];for(let e=0;e<i.length;e++)o.push(r(t.minYArr[e],e))}
7else(o=[]).push(r(t.minY,0)),5e-324!==t.minY&&0!==Math.abs(t.minY)&&(n=-t.minY/s,h=t.minX/a)}else(o=[]).push(0),n=0,h=0;return{yRatio:i,invertedYRatio:s,zRatio:l,xRatio:a,invertedXRatio:r,baseLineInvertedY:n,baseLineY:o,baseLineX:h}}getLogSeries(e){let t=this.w;return t.globals.seriesLog=e.map((e,i)=>{let s=t.globals.seriesYAxisReverseMap[i];return t.config.yaxis[s]&&t.config.yaxis[s].logarithmic?e.map(e=>null===e?null:this.getLogVal(t.config.yaxis[s].logBase,e,i)):e}),t.globals.invalidLogScale?e:t.globals.seriesLog}getLogValAtSeriesIndex(e,t){if(null===e)return null;let i=this.w,s=i.globals.seriesYAxisReverseMap[t];return i.config.yaxis[s]&&i.config.yaxis[s].logarithmic?this.getLogVal(i.config.yaxis[s].logBase,e,t):e}getBaseLog(e,t){return Math.log(t)/Math.log(e)}getLogVal(e,t,i){if(t<=0)return 0;let s=this.w,a=0===s.globals.minYArr[i]?-1:this.getBaseLog(e,s.globals.minYArr[i]),r=(0===s.globals.maxYArr[i]?0:this.getBaseLog(e,s.globals.maxYArr[i]))-a;return t<1?t/r:(this.getBaseLog(e,t)-a)/r}getLogYRatios(e){let t=this.w,i=this.w.globals;return i.yLogRatio=e.slice(),i.logYRange=i.yRange.map((e,s)=>{let a=t.globals.seriesYAxisReverseMap[s];if(t.config.yaxis[a]&&this.w.config.yaxis[a].logarithmic){let e=-Number.MAX_VALUE,a=5e-324,r=1;return i.seriesLog.forEach((i,s)=>{i.forEach(i=>{t.config.yaxis[s]&&t.config.yaxis[s].logarithmic&&(e=Math.max(i,e),a=Math.min(i,a))})}),r=Math.pow(i.yRange[s],Math.abs(a-e)/i.yRange[s]),i.yLogRatio[s]=r/this.w.layout.gridHeight,r}}),i.invalidLogScale?e.slice():i.yLogRatio}static extendArrayProps(e,t,i){var s,a;return(null==t?void 0:t.yaxis)&&(t=e.extendYAxis(t,i)),(null==t?void 0:t.annotations)&&(t.annotations.yaxis&&(t=e.extendYAxisAnnotations(t)),(null==(s=null==t?void 0:t.annotations)?void 0:s.xaxis)&&(t=e.extendXAxisAnnotations(t)),(null==(a=null==t?void 0:t.annotations)?void 0:a.points)&&(t=e.extendPointAnnotations(t))),t}drawSeriesByGroup(e,t,i,s){let a=this.w,r=[];return e.series.length>0&&t.forEach(t=>{let l=[],o=[];e.i.forEach((i,s)=>{a.config.series[i].group===t&&(l.push(e.series[s]),o.push(i))}),l.length>0&&r.push(s.draw(l,i,o))}),r}}class R{constructor(e,t){this.w=e,this.ctx=t}animateLine(e,t,i,s){e.attr(t).animate(s).attr(i)}animateMarker(e,t,i,s){e.attr({opacity:0}).animate(t).attr({opacity:1}).after(()=>{s()})}animateRect(e,t,i,s,a){e.attr(t).animate(s).attr(i).after(()=>a())}animatePathsGradually(e){let{el:t,realIndex:i,j:s,fill:a,pathFrom:r,pathTo:l,speed:o,delay:n}=e,h=this.w,d=0;h.config.chart.animations.animateGradually.enabled&&(d=h.config.chart.animations.animateGradually.delay),h.config.chart.animations.dynamicAnimation.enabled&&h.globals.dataChanged&&"bar"!==h.config.chart.type&&(d=0),this.morphSVG(t,i,s,"line"!==h.config.chart.type||h.globals.comboCharts?a:"stroke",r,l,o,n*d)}showDelayedElements(){this.w.globals.delayedElements.forEach(e=>{let t=e.el;t.classList.remove("apexcharts-element-hidden"),t.classList.add("apexcharts-hidden-element-shown")})}animationCompleted(e){let 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}))}morphSVG(e,t,i,s,a,r,l,o){let n=this.w;a||(a=e.attr("pathFrom")),r||(r=e.attr("pathTo"));let h=()=>("radar"===n.config.chart.type&&(l=1),`M 0 ${n.layout.gridHeight}`);(!a||a.indexOf("undefined")>-1||a.indexOf("NaN")>-1)&&(a=h()),(!r.trim()||r.indexOf("undefined")>-1||r.indexOf("NaN")>-1)&&(r=h()),n.globals.shouldAnimate||(l=1),e.plot(a).animate(1,o).plot(a).animate(l,o).plot(r).after(()=>{v.isNumber(i)?i===n.seriesData.series[n.globals.maxValsInArrayIndex].length-2&&n.globals.shouldAnimate&&this.animationCompleted(e):"none"!==s&&n.globals.shouldAnimate&&(!n.globals.comboCharts&&t===n.seriesData.series.length-1||n.globals.comboCharts)&&this.animationCompleted(e),this.showDelayedElements()})}}class z{constructor(e){this.w=e}getDefaultFilter(e,t){let i=this.w;e.unfilter&&e.unfilter(!0),i.config.chart.dropShadow.enabled&&this.dropShadow(e,i.config.chart.dropShadow,t)}applyFilter(e,t,i){var s,a,r;let l=this.w;
7if(e.unfilter&&e.unfilter(!0),"none"===i)return void this.getDefaultFilter(e,t);let o=l.config.chart.dropShadow,n="lighten"===i?2:.3;e.filterWith&&(e.filterWith(e=>{e.colorMatrix({type:"matrix",values:`
8            ${n} 0 0 0 0
9            0 ${n} 0 0 0
10            0 0 ${n} 0 0
11            0 0 0 1 0
12          `,in:"SourceGraphic",result:"brightness"}),o.enabled&&this.addShadow(e,t,o,"brightness")}),o.noUserSpaceOnUse||null==(a=null==(s=e.filterer())?void 0:s.node)||a.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(null==(r=e.filterer())?void 0:r.node))}addShadow(e,t,i,s){var a;let r=this.w,{blur:l,top:o,left:n,color:h,opacity:d}=i;if(h=Array.isArray(h)?h[t]:h,(null==(a=r.config.chart.dropShadow.enabledOnSeries)?void 0:a.length)>0&&-1===r.config.chart.dropShadow.enabledOnSeries.indexOf(t))return e;e.offset({in:s,dx:n,dy:o,result:"offset"}),e.gaussianBlur({in:"offset",stdDeviation:l,result:"blur"}),e.flood({"flood-color":h,"flood-opacity":d,result:"flood"}),e.composite({in:"flood",in2:"blur",operator:"in",result:"shadow"}),e.merge(["shadow",s])}dropShadow(e,t,i=0){var s,a,r,l,o;let n=this.w;return e.unfilter&&e.unfilter(!0),v.isMsEdge()&&"radialBar"===n.config.chart.type||(null==(s=n.config.chart.dropShadow.enabledOnSeries)?void 0:s.length)>0&&(null==(a=n.config.chart.dropShadow.enabledOnSeries)?void 0:a.indexOf(i))===-1||e.filterWith&&(e.filterWith(e=>{this.addShadow(e,i,t,"SourceGraphic")}),t.noUserSpaceOnUse||null==(l=null==(r=e.filterer())?void 0:r.node)||l.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(null==(o=e.filterer())?void 0:o.node)),e}setSelectionFilter(e,t,i){let s=this.w;if(void 0!==s.interact.selectedDataPoints[t]&&s.interact.selectedDataPoints[t].indexOf(i)>-1){e.node.setAttribute("selected",!0);let i=s.config.states.active.filter;"none"!==i&&this.applyFilter(e,t,i.type)}}_scaleFilterSize(e){if(e){var t={width:"200%",height:"200%",x:"-50%",y:"-50%"};for(let i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.setAttribute(i,t[i])}}}class Y{constructor(e,t=null){this.w=e,this.ctx=t}roundPathCorners(e,t){function i(e,t,i){var a=t.x-e.x,r=t.y-e.y;return s(e,t,Math.min(1,i/Math.sqrt(a*a+r*r)))}function s(e,t,i){return{x:e.x+(t.x-e.x)*i,y:e.y+(t.y-e.y)*i}}function a(e,t){e.length>2&&(e[e.length-2]=t.x,e[e.length-1]=t.y)}function r(e){return{x:parseFloat(e[e.length-2]),y:parseFloat(e[e.length-1])}}e.indexOf("NaN")>-1&&(e="");var l=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(l.length>1){var n=r(l[0]),h=null;"Z"==l[l.length-1][0]&&l[0].length>2&&(h=["L",n.x,n.y],l[l.length-1]=h),o.push(l[0]);for(var d=1;d<l.length;d++){var c=o[o.length-1],g=l[d],p=g==h?l[1]:l[d+1];if(p&&c&&c.length>2&&"L"==g[0]&&p.length>2&&"L"==p[0]){var x,u,f=r(c),m=r(g),b=r(p);x=i(m,f,t),u=i(m,b,t),a(g,x),g.origPoint=m,o.push(g);var y=s(x,m,.5),w=s(m,u,.5),v=["C",y.x,y.y,w.x,w.y,u.x,u.y];v.origPoint=m,o.push(v)}else o.push(g)}if(h){var A=r(o[o.length-1]);o.push(["Z"]),a(o[0],A)}}else o=l;return o.reduce(function(e,t){return e+t.join(" ")+" "},"")}drawLine(e,t,i,s,a="#a8a8a8",r=0,l=null,o="butt"){return this.w.dom.Paper.line().attr({x1:e,y1:t,x2:i,y2:s,stroke:a,"stroke-dasharray":r,"stroke-width":l,"stroke-linecap":o})}drawRect(e=0,t=0,i=0,s=0,a=0,r="#fefefe",l=1,o=null,n=null,h=0){let d=this.w.dom.Paper.rect();return d.attr({x:e,y:t,width:i>0?i:0,height:s>0?s:0,rx:a,ry:a,opacity:l,"stroke-width":null!==o?o:0,stroke:null!==n?n:"none","stroke-dasharray":h}),d.node.setAttribute("fill",r),d}drawPolygon(e,t="#e1e1e1",i=1,s="none"){return this.w.dom.Paper.polygon(e).attr({fill:s,stroke:t,"stroke-width":i})}drawCircle(e,t=null){let i=this.w;e<0&&(e=0);let s=i.dom.Paper.circle(2*e);return null!==t&&s.attr(t),s}drawPath({d:e="",stroke:t="#a8a8a8",strokeWidth:i=1,fill:s,fillOpacity:a=1,strokeOpacity:r=1,classes:l,strokeLinecap:o=null,strokeDashArray:n=0}){let h=this.w;return null===o&&(o=h.config.stroke.lineCap),(e.indexOf("undefined")>-1||e.indexOf("NaN")>-1)&&(e=`M 0 ${h.layout.gridHeight}`),h.dom.Paper.path(e).attr({fill:s,"fill-opacity":a,stroke:t,"stroke-opacity":r,"stroke-linecap":o,"stroke-width":i,"stroke-dasharray":n,class:l})}group(e=null){let t=this.w.dom.Paper.group();return null!==e&&t.attr(e),t}move(e,t){return["M",e,t].join(" ")}line(e,t,i=null){return"H"===i?[" H",e].join(" "):"V"===i?[" V",t].join(" "):[" L",e,t].join(" ")}curve(e,t,i,s,a,r){return["C",e,t,i,s,a,r].join(" ")}quadraticCurve(e,t,i,s){return["Q",e,t,i,s].join(" ")}arc(e,t,i,s,a,r,l,o=!1){let n="A";return o&&(n="a"),[n,e,t,i,s,a,r,l].join(" ")}renderPaths({j:e,realIndex:t,pathFrom:i,pathTo:s,stroke:a,strokeWidth:r,strokeLinecap:l,fill:o,animationDelay:n,initialSpeed:h,dataChangeSpeed:g,className:p,chartType:x,shouldClipToGrid:u=!0,bindEventsOnPaths:f=!0,drawShadow:m=!0}){let b,y=this.w,w=new z(this.w),v=new R(this.w,void 0),A=this.w.config.chart.animations.enabled,C=A&&this.w.config.chart.animations.dynamicAnimation.enabled;if(i&&i.startsWith("M 0 0")&&s){let e=s.match(/^M\s+[\d.-]+\s+[\d.-]+/);e&&(i=i.replace(/^M\s+0\s+0/,e[0]))}let S=!!(A&&!y.globals.resized||C&&y.globals.dataChanged&&y.globals.shouldAnimate);S?b=i:(b=s,y.globals.animationEnded=!0);let k=y.config.stroke.dashArray,D=0;D=Array.isArray(k)?k[t]:y.config.stroke.dashArray;let L=this.drawPath({d:b,stroke:a,strokeWidth:r,fill:o,fillOpacity:1,classes:p,strokeLinecap:l,strokeDashArray:D});L.attr("index",t),u&&("bar"===x&&!y.globals.isBarHorizontal||y.globals.comboCharts?L.attr({"clip-path":`url(#gridRectBarMask${y.globals.cuid})`}):L.attr({"clip-path":`url(#gridRectMask${y.globals.cuid})`}
12)),y.config.chart.dropShadow.enabled&&m&&w.dropShadow(L,y.config.chart.dropShadow,t),f&&(L.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,L)),L.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,L)),L.node.addEventListener("mousedown",this.pathMouseDown.bind(this,L))),L.attr({pathTo:s,pathFrom:i});let M={el:L,j:e,realIndex:t,pathFrom:i,pathTo:s,fill:o,strokeWidth:r,delay:n};return!A||y.globals.resized||y.globals.dataChanged?(y.globals.resized||!y.globals.dataChanged)&&v.showDelayedElements():v.animatePathsGradually(c(d({},M),{speed:h})),y.globals.dataChanged&&C&&S&&v.animatePathsGradually(c(d({},M),{speed:g})),L}drawPattern(e,t,i,s="#a8a8a8",a=0){return this.w.dom.Paper.pattern(t,i,r=>{"horizontalLines"===e?r.line(0,0,i,0).stroke({color:s,width:a+1}):"verticalLines"===e?r.line(0,0,0,t).stroke({color:s,width:a+1}):"slantedLines"===e?r.line(0,0,t,i).stroke({color:s,width:a}):"squares"===e?r.rect(t,i).fill("none").stroke({color:s,width:a}):"circles"===e&&r.circle(t).fill("none").stroke({color:s,width:a})})}drawGradient(e,t,i,s,a,r=null,l=null,o=[],n=0){let h,d=this.w;t.length<9&&0===t.indexOf("#")&&(t=v.hexToRgba(t,s)),i.length<9&&0===i.indexOf("#")&&(i=v.hexToRgba(i,a));let c=0,g=1,p=1,x=null;null!==l&&(c=void 0!==l[0]?l[0]/100:0,g=void 0!==l[1]?l[1]/100:1,p=void 0!==l[2]?l[2]/100:1,x=void 0!==l[3]?l[3]/100:null);let u="donut"===d.config.chart.type||"pie"===d.config.chart.type||"polarArea"===d.config.chart.type||"bubble"===d.config.chart.type;if(h=o&&0!==o.length?d.dom.Paper.gradient(u?"radial":"linear",e=>{(Array.isArray(o[n])?o[n]:o).forEach(t=>{e.stop(t.offset/100,t.color,t.opacity)})}):d.dom.Paper.gradient(u?"radial":"linear",e=>{e.stop(c,t,s),e.stop(g,i,a),e.stop(p,i,a),null!==x&&e.stop(x,t,s)}),u){let e=d.layout.gridWidth/2,t=d.layout.gridHeight/2;"bubble"!==d.config.chart.type?h.attr({gradientUnits:"userSpaceOnUse",cx:e,cy:t,r:r}):h.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else"vertical"===e?h.from(0,0).to(0,1):"diagonal"===e?h.from(0,0).to(1,1):"horizontal"===e?h.from(0,1).to(1,1):"diagonal2"===e&&h.from(1,0).to(0,1);return h}getTextBasedOnMaxWidth({text:e,maxWidth:t,fontSize:i,fontFamily:s}){let a=this.getTextRects(e,i,s,""),r=Math.floor(t/(a.width/e.length));return t<a.width?e.slice(0,r-3)+"...":e}drawText({x:e,y:t,text:i,textAnchor:s,fontSize:a,fontFamily:r,fontWeight:l,foreColor:o,opacity:n,maxWidth:h,cssClass:c="",isPlainText:g=!0,dominantBaseline:p="auto"}){let x,u=this.w;void 0===i&&(i="");let f=i;s||(s="start"),o&&o.length||(o=u.config.chart.foreColor),r=r||u.config.chart.fontFamily,l=l||"regular";let m={maxWidth:h,fontSize:a=a||"11px",fontFamily:r};return Array.isArray(i)?x=u.dom.Paper.text(e=>{for(let t=0;t<i.length;t++)f=i[t],h&&(f=this.getTextBasedOnMaxWidth(d({text:i[t]},m))),0===t?e.tspan(f):e.tspan(f).newLine()}):(h&&(f=this.getTextBasedOnMaxWidth(d({text:i},m))),x=g?u.dom.Paper.plain(i):u.dom.Paper.text(e=>e.tspan(f))),x.attr({x:e,y:t,"text-anchor":s,"dominant-baseline":p,"font-size":a,"font-family":r,"font-weight":l,fill:o,class:"apexcharts-text "+c}),x.node.style.fontFamily=r,x.node.style.opacity=n,x}getMarkerPath(e,t,i,s){let a="";switch(i){case"cross":s/=1.4,a=`M ${e-s} ${t-s} L ${e+s} ${t+s}  M ${e-s} ${t+s} L ${e+s} ${t-s}`;break;case"plus":s/=1.12,a=`M ${e-s} ${t} L ${e+s} ${t}  M ${e} ${t-s} L ${e} ${t+s}`;break;case"star":case"sparkle":{let r=5;s*=1.15,"sparkle"===i&&(s/=1.1,r=4);let l=Math.PI/r;for(let i=0;i<=2*r;i++){let r=i*l,o=i%2==0?s:s/2;a+=(0===i?"M":"L")+(e+o*Math.sin(r))+","+(t-o*Math.cos(r))}a+="Z";break}case"triangle":a=`M ${e} ${t-s} 
13             L ${e+s} ${t+s} 
14             L ${e-s} ${t+s} 
15             Z`;break;case"square":case"rect":s/=1.125,a=`M ${e-s} ${t-s} 
16           L ${e+s} ${t-s} 
17           L ${e+s} ${t+s} 
18           L ${e-s} ${t+s} 
19           Z`;break;case"diamond":s*=1.05,a=`M ${e} ${t-s} 
20             L ${e+s} ${t} 
21             L ${e} ${t+s} 
22             L ${e-s} ${t} 
23            Z`;break;case"line":s/=1.1,a=`M ${e-s} ${t} 
24           L ${e+s} ${t}`;break;default:s*=2,a=`M ${e}, ${t} 
25           m -${s/2}, 0 
26           a ${s/2},${s/2} 0 1,0 ${s},0 
27           a ${s/2},${s/2} 0 1,0 -${s},0`}return a}drawMarkerShape(e,t,i,s,a){let r=this.drawPath({d:this.getMarkerPath(e,t,i,s),stroke:a.pointStrokeColor,strokeDashArray:a.pointStrokeDashArray,strokeWidth:a.pointStrokeWidth,fill:a.pointFillColor,fillOpacity:a.pointFillOpacity,strokeOpacity:a.pointStrokeOpacity});return r.attr({cx:e,cy:t,shape:a.shape,class:a.class?a.class:""}),r}drawMarker(e,t,i){e=e||0;let s=i.pSize||0;return v.isNumber(t)||(s=0,t=0),this.drawMarkerShape(e,t,null==i?void 0:i.shape,s,d(d({},i),"line"===i.shape||"plus"===i.shape||"cross"===i.shape?{pointStrokeColor:i.pointFillColor,pointStrokeOpacity:i.pointFillOpacity}:{}))}pathMouseEnter(e,t){var i,s;let a=this.w,r=new z(this.w),l=parseInt(null!=(i=e.node.getAttribute("index"))?i:"",10),o=parseInt(null!=(s=e.node.getAttribute("j"))?s:"",10);if(!(isNaN(l)||isNaN(o))&&("function"==typeof a.config.chart.events.dataPointMouseEnter&&a.config.chart.events.dataPointMouseEnter(t,this.ctx,{seriesIndex:l,dataPointIndex:o,w:a}),Y._fireEvent(a,"dataPointMouseEnter",[t,this.ctx,{seriesIndex:l,dataPointIndex:o,w:a}]),("none"===a.config.states.active.filter.type||"true"!==e.node.getAttribute("selected"))&&"none"!==a.config.states.hover.f
27ilter.type&&!a.interact.isTouchDevice)){let t=a.config.states.hover.filter;r.applyFilter(e,l,t.type)}}pathMouseLeave(e,t){var i,s;let a=this.w,r=new z(this.w),l=parseInt(null!=(i=e.node.getAttribute("index"))?i:"",10),o=parseInt(null!=(s=e.node.getAttribute("j"))?s:"",10);isNaN(l)||isNaN(o)||("function"==typeof a.config.chart.events.dataPointMouseLeave&&a.config.chart.events.dataPointMouseLeave(t,this.ctx,{seriesIndex:l,dataPointIndex:o,w:a}),Y._fireEvent(a,"dataPointMouseLeave",[t,this.ctx,{seriesIndex:l,dataPointIndex:o,w:a}]),("none"===a.config.states.active.filter.type||"true"!==e.node.getAttribute("selected"))&&"none"!==a.config.states.hover.filter.type&&r.getDefaultFilter(e,l))}pathMouseDown(e,t){var i,s;let a=this.w,r=new z(this.w),l=parseInt(null!=(i=e.node.getAttribute("index"))?i:"",10),o=parseInt(null!=(s=e.node.getAttribute("j"))?s:"",10);if(isNaN(l)||isNaN(o))return;let n="false";if("true"===e.node.getAttribute("selected")){e.node.setAttribute("selected","false");let t=a.interact.selectedDataPoints[l].indexOf(o);t>-1&&a.interact.selectedDataPoints[l].splice(t,1)}else{if(!a.config.states.active.allowMultipleDataPointsSelection&&a.interact.selectedDataPoints.length>0){a.interact.selectedDataPoints=[];let e=a.dom.Paper.find(".apexcharts-series path:not(.apexcharts-decoration-element)"),t=a.dom.Paper.find(".apexcharts-series circle:not(.apexcharts-decoration-element), .apexcharts-series rect:not(.apexcharts-decoration-element)"),i=e=>{Array.prototype.forEach.call(e,e=>{e.node.setAttribute("selected","false"),r.getDefaultFilter(e,l)})};i(e),i(t)}e.node.setAttribute("selected","true"),n="true",void 0===a.interact.selectedDataPoints[l]&&(a.interact.selectedDataPoints[l]=[]),a.interact.selectedDataPoints[l].push(o)}if("true"===n){let t=a.config.states.active.filter;if("none"!==t)r.applyFilter(e,l,t.type);else if("none"!==a.config.states.hover.filter&&!a.interact.isTouchDevice){let t=a.config.states.hover.filter;r.applyFilter(e,l,t.type)}}else if("none"!==a.config.states.active.filter.type)if("none"===a.config.states.hover.filter.type||a.interact.isTouchDevice)r.getDefaultFilter(e,l);else{let t=a.config.states.hover.filter;r.applyFilter(e,l,t.type)}"function"==typeof a.config.chart.events.dataPointSelection&&a.config.chart.events.dataPointSelection(t,this.ctx,{selectedDataPoints:a.interact.selectedDataPoints,seriesIndex:l,dataPointIndex:o,w:a}),t&&Y._fireEvent(a,"dataPointSelection",[t,this.ctx,{selectedDataPoints:a.interact.selectedDataPoints,seriesIndex:l,dataPointIndex:o,w:a}])}rotateAroundCenter(e){let t={};return e&&"function"==typeof e.getBBox&&(t=e.getBBox()),{x:t.x+t.width/2,y:t.y+t.height/2}}setupEventDelegation(e,t){let i=null;e.node.addEventListener("mouseover",s=>{let a=Y._findDelegateTarget(s.target,e.node,t);a&&a!==i&&(i&&i.instance&&this.pathMouseLeave(i.instance,s),i=a,a.instance&&this.pathMouseEnter(a.instance,s))}),e.node.addEventListener("mouseout",s=>{i&&(s.relatedTarget?Y._findDelegateTarget(s.relatedTarget,e.node,t):null)!==i&&(i&&i.instance&&this.pathMouseLeave(i.instance,s),i=null)}),e.node.addEventListener("mousedown",i=>{let s=Y._findDelegateTarget(i.target,e.node,t);s&&s.instance&&this.pathMouseDown(s.instance,i)})}static _fireEvent(e,t,i){let s=e.globals.events;if(!s||!Object.prototype.hasOwnProperty.call(s,t))return;let a=s[t];for(let e=0;e<a.length;e++)a[e].apply(null,i)}static _findDelegateTarget(e,t,i){for(;e&&e!==t&&e!==document;){if(e.matches&&e.matches(i))return e;e=e.parentNode}return null}static setAttrs(e,t){for(let i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.setAttribute(i,t[i])}getTextRects(e,t,i,s,a=!0){let r=this.w,l=[e,t,i,s,a].join("\0"),o=r.globals.textRectsCache;if(o&&o.has(l))return o.get(l);let n=this.drawText({x:-200,y:-200,text:e,textAnchor:"start",fontSize:t,fontFamily:i,foreColor:"#fff",opacity:0});s&&n.attr("transform",s),r.dom.Paper.add(n);let h=n.bbox();a||(h=n.node.getBoundingClientRect()),n.remove();let d={width:h.width,height:h.height};return o&&o.set(l,d),d}placeTextWithEllipsis(e,t,i){if("function"==typeof e.getComputedTextLength&&(e.textContent=t,t.length>0&&e.getComputedTextLength()>=i/1.1)){for(let s=t.length-3;s>0;s-=3)if(e.getSubStringLength(0,s)<=i/1.1){e.textContent=t.substring(0,s)+"...";return}e.textContent="."}}}let B="http://www.w3.org/2000/svg";class H{constructor(e,t){"object"==typeof e?(this.x=e.x,this.y=e.y):(this.x=e||0,this.y=t||0)}transform(e){return e.apply(this)}clone(){return new H(this.x,this.y)}}class N{constructor(e,t,i,s,a,r){this.a=null!=e?e:1,this.b=null!=t?t:0,this.c=null!=i?i:0,this.d=null!=s?s:1,this.e=null!=a?a:0,this.f=null!=r?r:0}rotate(e){let t=e*Math.PI/180,i=Math.cos(t),s=Math.sin(t);return this.multiply(new N(i,s,-s,i,0,0))}scale(e,t){return this.multiply(new N(e,0,0,null!=t?t:e,0,0))}multiply(e){return new N(this.a*e.a+this.c*e.b,this.b*e.a+this.d*e.b,this.a*e.c+this.c*e.d,this.b*e.c+this.d*e.d,this.a*e.e+this.c*e.f+this.e,this.b*e.e+this.d*e.f+this.f)}
27apply(e){return new H(this.a*e.x+this.c*e.y+this.e,this.b*e.x+this.d*e.y+this.f)}}class O{constructor(e,t,i,s){this.x=e,this.y=t,this.w=i,this.h=s,this.width=i,this.height=s,this.x2=e+i,this.y2=t+s}}class W{constructor(e){this.w=e,this.opts=null,this.seriesIndex=0,this.patternIDs=[]}clippedImgArea(e){let t=this.w,s=t.config,a=parseInt(String(t.layout.gridWidth),10),r=parseInt(String(t.layout.gridHeight),10),l=a>r?a:r,o=e.image,n=0,h=0;void 0===e.width&&void 0===e.height?void 0!==s.fill.image.width&&void 0!==s.fill.image.height?(n=s.fill.image.width+1,h=s.fill.image.height):(n=l+1,h=l):(n=e.width,h=e.height);let d=w.createElementNS(B,"pattern");Y.setAttrs(d,{id:e.patternID,patternUnits:e.patternUnits?e.patternUnits:"userSpaceOnUse",width:n+"px",height:h+"px"});let c=w.createElementNS(B,"image");d.appendChild(c);let g=p.isBrowser()?window.SVG:i.g.SVG;c.setAttributeNS(g.xlink,"href",o),Y.setAttrs(c,{x:0,y:0,preserveAspectRatio:"none",width:n+"px",height:h+"px"}),c.style.opacity=e.opacity,t.dom.elDefs.node.appendChild(d)}getSeriesIndex(e){let 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.seriesData.series.length,this.seriesIndex}computeColorStops(e,t){let i=this.w,s=null,a=null;for(let i of e)i>=t.threshold?(null===s||i>s)&&(s=i):(null===a||i<a)&&(a=i);null===s&&(s=t.threshold),null===a&&(a=t.threshold);let r=s-t.threshold+(t.threshold-a);0===r&&(r=1);let l=100-(t.threshold-a)/r*100;return[{offset:l=Math.max(0,Math.min(l,100)),color:t.colorAboveThreshold,opacity:i.config.fill.opacity},{offset:0,color:t.colorBelowThreshold,opacity:i.config.fill.opacity}]}fillPath(e){var t,i,s,a;let r,l,o,n=this.w;this.opts=e;let h=this.w.config;this.seriesIndex=this.getSeriesIndex(e);let d=h.plotOptions.line.colors.colorAboveThreshold&&h.plotOptions.line.colors.colorBelowThreshold,c=this.getFillColors()[this.seriesIndex];void 0!==n.seriesData.seriesColors[this.seriesIndex]&&(c=n.seriesData.seriesColors[this.seriesIndex]),"function"==typeof c&&(c=c({seriesIndex:this.seriesIndex,dataPointIndex:e.dataPointIndex,value:e.value,w:n}));let g=e.fillType?e.fillType:this.getFillType(this.seriesIndex),p=Array.isArray(h.fill.opacity)?h.fill.opacity[this.seriesIndex]:h.fill.opacity,x="gradient"===g||d;e.color&&(c=e.color);let u=n.config.series[this.seriesIndex];(null==(i=null==(t=null==u?void 0:u.data)?void 0:t[e.dataPointIndex])?void 0:i.fillColor)&&(c=null==(a=null==(s=null==u?void 0:u.data)?void 0:s[e.dataPointIndex])?void 0:a.fillColor),c||(c="#fff",console.warn("undefined color - ApexCharts")),void 0!==e.opacity&&null!==e.opacity&&(p=e.opacity);let f=c;v.isCSSVariable(c)?f=v.applyOpacityToColor(c,p):-1===c.indexOf("rgb")?-1===c.indexOf("#")?f=c:c.length<9&&(f=v.hexToRgba(c,p)):c.indexOf("rgba")>-1?p=v.getOpacityFromRGBA(c):f=v.hexToRgba(v.rgb2hex(c),p);let m=v.isCSSVariable(c)?v.getThemeColor(c):c;if("pattern"===g&&(l=this.handlePatternFill({fillConfig:e.fillConfig,patternFill:l,fillColor:m,defaultColor:f})),x){let t=h.fill.gradient.colorStops?[...h.fill.gradient.colorStops]:[],i=h.fill.gradient.type;d&&(t[this.seriesIndex]=this.computeColorStops(n.seriesData.series[this.seriesIndex],h.plotOptions.line.colors),i="vertical"),o=this.handleGradientFill({type:i,fillConfig:e.fillConfig,fillColor:m,fillOpacity:p,colorStops:t,i:this.seriesIndex})}if("image"===g){let t=h.fill.image.src,i=e.patternID?e.patternID:"",s=`pattern${n.globals.cuid}${e.seriesNumber+1}${i}`;-1===this.patternIDs.indexOf(s)&&(this.clippedImgArea({opacity:p,image:Array.isArray(t)?e.seriesNumber<t.length?t[e.seriesNumber]:t[0]:t,width:e.width?e.width:void 0,height:e.height?e.height:void 0,patternUnits:e.patternUnits,patternID:s}),this.patternIDs.push(s)),r=`url(#${s})`}else r=x?o:"pattern"===g?l:f;return e.solid&&(r=f),r}getFillType(e){let t=this.w;return Array.isArray(t.config.fill.type)?t.config.fill.type[e]:t.config.fill.type}getFillColors(){let e=this.w,t=e.config,i=this.opts,s=[];return e.globals.comboCharts?"line"===e.config.series[this.seriesIndex].type?Array.isArray(e.globals.stroke.colors)?s=e.globals.stroke.colors:s.push(e.globals.stroke.colors):Array.isArray(e.globals.fill.colors)?s=e.globals.fill.colors:s.push(e.globals.fill.colors):"line"===t.chart.type?Array.isArray(e.globals.stroke.colors)?s=e.globals.stroke.colors:s.push(e.globals.stroke.colors):Array.isArray(e.globals.fill.colors)?s=e.globals.fill.colors:s.push(e.globals.fill.colors),void 0!==i.fillColors&&(s=[],Array.isArray(i.fillColors)?s=i.fillColors.slice():s.push(i.fillColors)),s}handlePatternFill({fillConfig:e,patternFill:t,fillColor:i,defaultColor:s}){let a=this.w.config.fill;e&&(a=e);let r=this.opts,l=new Y(this.w),o=Array.isArray(a.pattern.strokeWidth)?a.pattern.strokeWidth[this.seriesIndex]:a.pattern.strokeWidth;return Array.isArray(a.pattern.style)?void 0!==a.pattern.style[r.seriesNumber]?l.drawPattern(a.pattern.style[r.seriesNumber],a.pattern.width,a.pattern.height,i,o):s:l.drawPattern(a.pattern.style,a.pattern.width,a.pattern.height,i,o)}handleGradientFill({type:e,fillColor:t,fillOpacity:i,fillConfig:s,colorStops:a,i:r}){let l,o=this.w.config.fill;s&&(o=d(d({},o),s));let n=this.opts,h=new Y(this.w),c=new v;e=e||o.gradient.type;let g=t,p=void 0===o.gradient.opacityFrom?i:Array.isArray(o.gradient.opacityFrom)?o.gradient.opacityFrom[r]:o.gradient.opacityFrom;g.indexOf("rgba")>-1&&(p=v.getOpacityFromRGBA(g));let x=void 0===o.gradient.opacityTo?i:Array.isArray(o.gradient.opacityTo)?o.gradient.opacityTo[r]:o.gradient.opacityTo;
27if(void 0===o.gradient.gradientToColors||0===o.gradient.gradientToColors.length)l="dark"===o.gradient.shade?c.shadeColor(-1*parseFloat(o.gradient.shadeIntensity),t.indexOf("rgb")>-1?v.rgb2hex(t):t):c.shadeColor(parseFloat(o.gradient.shadeIntensity),t.indexOf("rgb")>-1?v.rgb2hex(t):t);else if(o.gradient.gradientToColors[n.seriesNumber]){let e=o.gradient.gradientToColors[n.seriesNumber];l=e,e.indexOf("rgba")>-1&&(x=v.getOpacityFromRGBA(e))}else l=t;if(o.gradient.gradientFrom&&(g=o.gradient.gradientFrom),o.gradient.gradientTo&&(l=o.gradient.gradientTo),o.gradient.inverseColors){let e=g;g=l,l=e}return g.indexOf("rgb")>-1&&(g=v.rgb2hex(g)),l.indexOf("rgb")>-1&&(l=v.rgb2hex(l)),h.drawGradient(e,g,l,p,x,n.size,o.gradient.stops,a,r)}}class _{constructor(e,t){this.w=e,this.ctx=t,this._filters=new z(this.w),this._graphics=new Y(this.w,this.ctx)}setGlobalMarkerSize(){let 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.seriesData.series.length+1)for(let t=0;t<=e.seriesData.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(()=>e.config.markers.size)}plotChartMarkers({pointsPos:e,seriesIndex:t,j:i,pSize:s,alwaysDrawMarker:a=!1,isVirtualPoint:r=!1}){let l=this.w,o=null,n=new Y(this.w),h=l.config.markers.discrete&&l.config.markers.discrete.length;if(Array.isArray(e.x))for(let d=0;d<e.x.length;d++){let c,g=i,p=!v.isNumber(e.y[d]);0===l.globals.markers.largestSize&&l.globals.hasNullValues&&null!==l.seriesData.series[t][i+1]&&!r&&(p=!0),1===i&&0===d&&(g=0),1===i&&1===d&&(g=1);let x="apexcharts-marker";if("line"!==l.config.chart.type&&"area"!==l.config.chart.type||l.globals.comboCharts||l.config.tooltip.intersect||(x+=" no-pointer-events"),(Array.isArray(l.config.markers.size)?l.globals.markers.size[t]>0:l.config.markers.size>0)||a||h){p||(x+=` w${v.randomId()}`);let i=this.getMarkerConfig({cssClass:x,seriesIndex:t,dataPointIndex:g}),r=l.config.series[t];r.data[g]&&(r.data[g].fillColor&&(i.pointFillColor=r.data[g].fillColor),r.data[g].strokeColor&&(i.pointStrokeColor=r.data[g].strokeColor)),void 0!==s&&(i.pSize=s),(e.x[d]<-l.globals.markers.largestSize||e.x[d]>l.layout.gridWidth+l.globals.markers.largestSize||e.y[d]<-l.globals.markers.largestSize||e.y[d]>l.layout.gridHeight+l.globals.markers.largestSize)&&(i.pSize=0),!p&&((l.globals.markers.size[t]>0||a||h)&&!o&&((o=n.group({class:a||h?"":"apexcharts-series-markers"})).attr("clip-path",`url(#gridRectMarkerMask${l.globals.cuid})`),this.setupMarkerDelegation(o)),(c=n.drawMarker(e.x[d],e.y[d],i)).attr("rel",g),c.attr("j",g),c.attr("index",t),c.node.setAttribute("default-marker-size",i.pSize),this._filters.setSelectionFilter(c,t,g),o&&o.add(c))}else void 0===l.globals.pointsArray[t]&&(l.globals.pointsArray[t]=[]),l.globals.pointsArray[t].push([e.x[d],e.y[d]])}return o}getMarkerConfig({cssClass:e,seriesIndex:t,dataPointIndex:i=null,radius:s=null,size:a=null,strokeWidth:r=null}){let l=this.w,o=this.getMarkerStyle(t),n=null===a?l.globals.markers.size[t]:a,h=l.config.markers;return null!==i&&h.discrete.length&&h.discrete.map(e=>{e.seriesIndex===t&&e.dataPointIndex===i&&(o.pointStrokeColor=e.strokeColor,o.pointFillColor=e.fillColor,n=e.size,o.pointShape=e.shape)}),{pSize:null===s?n:s,pRadius:null!==s?s:h.radius,pointStrokeWidth:null!==r?r:Array.isArray(h.strokeWidth)?h.strokeWidth[t]:h.strokeWidth,pointStrokeColor:o.pointStrokeColor,pointFillColor:o.pointFillColor,shape:o.pointShape||(Array.isArray(h.shape)?h.shape[t]:h.shape),class:e,pointStrokeOpacity:Array.isArray(h.strokeOpacity)?h.strokeOpacity[t]:h.strokeOpacity,pointStrokeDashArray:Array.isArray(h.strokeDashArray)?h.strokeDashArray[t]:h.strokeDashArray,pointFillOpacity:Array.isArray(h.fillOpacity)?h.fillOpacity[t]:h.fillOpacity,seriesIndex:t}}setupMarkerDelegation(e){let t=this.w,i=".apexcharts-marker";this._graphics.setupEventDelegation(e,i),e.node.addEventListener("click",s=>{t.config.markers.onClick&&Y._findDelegateTarget(s.target,e.node,i)&&t.config.markers.onClick(s)}
27),e.node.addEventListener("dblclick",s=>{t.config.markers.onDblClick&&Y._findDelegateTarget(s.target,e.node,i)&&t.config.markers.onDblClick(s)}),e.node.addEventListener("touchstart",t=>{let s=Y._findDelegateTarget(t.target,e.node,i);s&&s.instance&&this._graphics.pathMouseDown(s.instance,t)},{passive:!0})}addEvents(e){let t=this.w;e.node.addEventListener("mouseenter",this._graphics.pathMouseEnter.bind(this.ctx,e)),e.node.addEventListener("mouseleave",this._graphics.pathMouseLeave.bind(this.ctx,e)),e.node.addEventListener("mousedown",this._graphics.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",this._graphics.pathMouseDown.bind(this.ctx,e),{passive:!0})}getMarkerStyle(e){let t=this.w,i=t.globals.markers.colors,s=t.config.markers.strokeColor||t.config.markers.strokeColors;return{pointStrokeColor:Array.isArray(s)?s[e]:s,pointFillColor:Array.isArray(i)?i[e]:i}}}class ${constructor(e,t){this.ctx=t,this.w=e,this.initialAnim=this.w.config.chart.animations.enabled,this.anim=new R(this.w),this.filters=new z(this.w),this.fill=new W(this.w),this.markers=new _(this.w,this.ctx),this.graphics=new Y(this.w)}draw(e,t,i){let s=this.w,a=this.graphics,r=i.realIndex,l=i.pointsPos,o=i.zRatio,n=i.elParent,h=a.group({class:`apexcharts-series-markers apexcharts-series-${s.config.chart.type}`});if(h.attr("clip-path",`url(#gridRectMarkerMask${s.globals.cuid})`),this.markers.setupMarkerDelegation(h),Array.isArray(l.x))for(let e=0;e<l.x.length;e++){let i=t+1,a=!0;0===t&&0===e&&(i=0),0===t&&1===e&&(i=1);let d=s.globals.markers.size[r];if(o!==1/0){let e=s.config.plotOptions.bubble;d=s.seriesData.seriesZ[r][i],e.zScaling&&(d/=o),e.minBubbleRadius&&d<e.minBubbleRadius&&(d=e.minBubbleRadius),e.maxBubbleRadius&&d>e.maxBubbleRadius&&(d=e.maxBubbleRadius)}let c=l.x[e],g=l.y[e];if(d=d||0,(null===g||void 0===s.seriesData.series[r][i])&&(a=!1),a){let e=this.drawPoint(c,g,d,r,i,t);h.add(e)}n.add(h)}}drawPoint(e,t,i,s,a,r){let l=this.w,o=this.anim,n=this.filters,h=this.fill,d=this.markers,c=this.graphics,g=d.getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:s,dataPointIndex:a,radius:"bubble"===l.config.chart.type||l.globals.comboCharts&&l.config.series[s]&&"bubble"===l.config.series[s].type?i:null}),p=h.fillPath({seriesNumber:s,dataPointIndex:a,color:g.pointFillColor,patternUnits:"objectBoundingBox",value:l.seriesData.series[s][r]}),x=c.drawMarker(e,t,g),u=l.config.series[s];if(u.data[a]&&u.data[a].fillColor&&(p=u.data[a].fillColor),x.attr({fill:p}),l.config.chart.dropShadow.enabled){let e=l.config.chart.dropShadow;n.dropShadow(x,e,s)}if(!this.initialAnim||l.globals.dataChanged||l.globals.resized)l.globals.animationEnded=!0;else{let e=l.config.chart.animations.speed;o.animateMarker(x,e,l.globals.easing,()=>{window.setTimeout(()=>{o.animationCompleted(x)},100)})}return x.attr({rel:a,j:a,index:s,"default-marker-size":g.pSize}),n.setSelectionFilter(x,s,a),x.node.classList.add("apexcharts-marker"),x}centerTextInBubble(e){let t=this.w;return{y:e+=parseInt(t.config.dataLabels.style.fontSize,10)/4}}}class G{constructor(e,t=null){this.w=e,this.ctx=t}dataLabelsCorrection(e,t,i,s,a,r,l){let o=this.w,n=new Y(this.w),h=!1,d=n.getTextRects(i,l),c=d.width,g=d.height;t<0&&(t=0),t>o.layout.gridHeight+g&&(t=o.layout.gridHeight+g/2),void 0===o.globals.dataLabelsRects[s]&&(o.globals.dataLabelsRects[s]=[]),o.globals.dataLabelsRects[s].push({x:e,y:t,width:c,height:g});let p=o.globals.dataLabelsRects[s].length-2,x=void 0!==o.globals.lastDrawnDataLabelsIndexes[s]?o.globals.lastDrawnDataLabelsIndexes[s][o.globals.lastDrawnDataLabelsIndexes[s].length-1]:0;if(void 0!==o.globals.dataLabelsRects[s][p]){let i=o.globals.dataLabelsRects[s][x];(e>i.x+i.width||t>i.y+i.height||t+g<i.y||e+c<i.x)&&(h=!0)}return(0===a||r)&&(h=!0),{x:e,y:t,textRects:d,drawnextLabel:h}}drawDataLabel({type:e,pos:t,i,j:s,isRangeStart:a,strokeWidth:r=2}){let l=this.w,o=new Y(this.w),n=l.config.dataLabels,h=0,d=0,c=s,g=null;if(-1!==l.globals.collapsedSeriesIndices.indexOf(i)||!n.enabled||!Array.isArray(t.x))return g;g=o.group({class:"apexcharts-data-labels"});for(let o=0;o<t.x.length;o++)if(h=t.x[o]+n.offsetX,d=t.y[o]+n.offsetY+r,!isNaN(h)){1===s&&0===o&&(c=0),1===s&&1===o&&(c=1);let r=l.seriesData.series[i][c];"rangeArea"===e&&(r=a?l.rangeData.seriesRangeStart[i][c]:l.rangeData.seriesRangeEnd[i][c]);let n="",p=e=>l.config.dataLabels.formatter(e,{seriesIndex:i,dataPointIndex:c,w:l});"bubble"===l.config.chart.type?(n=p(r=l.seriesData.seriesZ[i][c]),d=t.y[o],d=new $(this.w,this.ctx).centerTextInBubble(d).y):void 0!==r&&(n=p(r));let x=l.config.dataLabels.textAnchor;l.globals.isSlopeChart&&(x=0===c?"end":c===l.config.series[i].data.length-1?"start":"middle"),this.plotDataLabelsText({x:h,y:d,text:n,i,j:c,parent:g,offsetCorrection:!0,dataLabelsConfig:l.config.dataLabels,textAnchor:x})}return g}plotDataLabelsText(e){let t=this.w,i=new Y(this.w),{x:s,y:a,i:r,j:l,text:o,textAnchor:n,fontSize:h,parent:d,dataLabelsConfig:c,color:g,alwaysDrawDataLabel:p,offsetCorrection:x,className:u}=e,f=null;if(Array.isArray(t.config.dataLabels.enabledOnSeries)&&0>t.config.dataLabels.enabledOnSeries.indexOf(r))return f;let m={x:s,y:a,drawnextLabel:!0,textRects:null};if(x&&(m=this.dataLabelsCorrection(s,a,o,r,l,p,parseInt(c.style.fontSize,10).toString())),t.interact.zoomed||(s=m.x,a=m.y),m.textRects){let e=t.globals.barPadForNumericAxis||
270;(s<-(e+20)-m.textRects.width||s>t.layout.gridWidth+m.textRects.width+e+30)&&(o="")}let b=t.globals.dataLabels.style.colors[r];(("bar"===t.config.chart.type||"rangeBar"===t.config.chart.type)&&t.config.plotOptions.bar.distributed||t.config.dataLabels.distributed)&&(b=t.globals.dataLabels.style.colors[l]),"function"==typeof b&&(b=b({series:t.seriesData.series,seriesIndex:r,dataPointIndex:l,w:t})),g&&(b=g);let y=c.offsetX,w=c.offsetY;if(("bar"===t.config.chart.type||"rangeBar"===t.config.chart.type)&&(y=0,w=0),t.globals.isSlopeChart&&(0!==l&&(y=-2*c.offsetX+5),0!==l&&l!==t.config.series[r].data.length-1&&(y=0)),m.drawnextLabel){if("middle"===n&&s===t.layout.gridWidth&&(n="end"),(f=i.drawText({x:s+y,y:a+w,foreColor:b,textAnchor:n||c.textAnchor,text:o,fontSize:h||c.style.fontSize,fontFamily:c.style.fontFamily,fontWeight:c.style.fontWeight||"normal"})).attr({class:u||"apexcharts-datalabel",cx:s,cy:a}),c.dropShadow.enabled){let e=c.dropShadow;new z(this.w).dropShadow(f,e)}d.add(f),void 0===t.globals.lastDrawnDataLabelsIndexes[r]&&(t.globals.lastDrawnDataLabelsIndexes[r]=[]),t.globals.lastDrawnDataLabelsIndexes[r].push(l)}return f}addBackgroundToDataLabel(e,t){let i=this.w,s=i.config.dataLabels.background,a=s.padding,r=s.padding/2,l=t.width,o=t.height,n=new Y(this.w).drawRect(t.x-a,t.y-r/2,l+2*a,o+r,s.borderRadius,"transparent"!==i.config.chart.background&&i.config.chart.background?i.config.chart.background:"#fff",s.opacity,s.borderWidth,s.borderColor);return s.dropShadow.enabled&&new z(this.w).dropShadow(n,s.dropShadow),n}dataLabelsBackground(){var e;let t=this.w;if("bubble"===t.config.chart.type)return;let i=t.dom.baseEl.querySelectorAll(".apexcharts-datalabels text");for(let s=0;s<i.length;s++){let a=i[s],r=a.getBBox(),l=null;if(r.width&&r.height&&(l=this.addBackgroundToDataLabel(a,r)),l){null==(e=a.parentNode)||e.insertBefore(l.node,a);let i=t.config.dataLabels.background.backgroundColor||a.getAttribute("fill");!t.config.chart.animations.enabled||t.globals.resized||t.globals.dataChanged?l.attr({fill:i}):l.animate().attr({fill:i}),a.setAttribute("fill",t.config.dataLabels.background.foreColor)}}}bringForward(){let e=this.w,t=e.dom.baseEl.querySelectorAll(".apexcharts-datalabels"),i=e.dom.baseEl.querySelector(".apexcharts-plot-series:last-child");for(let e=0;e<t.length;e++)i&&i.insertBefore(t[e],i.nextSibling)}}class V{static invalidateAll(e){e&&e.globals&&(e.globals.cachedSelectors&&(e.globals.cachedSelectors={}),e.globals.domCache&&e.globals.domCache.clear(),e.globals.dimensionCache={})}static invalidateDimensions(e){e&&e.globals&&(e.globals.dimensionCache={})}static invalidateSelectors(e){e&&e.globals&&e.globals.cachedSelectors&&(e.globals.cachedSelectors={})}static getCachedSelector(e,t,i){return e&&e.globals?(e.globals.cachedSelectors||(e.globals.cachedSelectors={}),e.globals.cachedSelectors[t]||(e.globals.cachedSelectors[t]=i()),e.globals.cachedSelectors[t]):i()}static getCachedDimension(e,t,i,s=1e3){if(!e||!e.globals)return i();e.globals.dimensionCache||(e.globals.dimensionCache={});let a=e.globals.dimensionCache[t],r=Date.now();if(a&&a.lastUpdate&&r-a.lastUpdate<s)return a.value;let l=i();return e.globals.dimensionCache[t]={value:l,lastUpdate:r},l}static cacheDOMElement(e,t,i){e&&e.globals&&(e.globals.domCache||(e.globals.domCache=new Map),e.globals.domCache.set(t,i))}static getCachedDOMElement(e,t){return e&&e.globals&&e.globals.domCache&&e.globals.domCache.get(t)||null}}class j{constructor(e,{theme:t=null,timeScale:i=null}={}){this.w=e,this.theme=t,this.timeScale=i}getLabel(e,t,i,s,a=[],r="12px",l=!0){let o=this.w,n=void 0===e[s]?"":e[s],h=n,d=o.formatters.xLabelFormatter,c=o.config.xaxis.labels.formatter,g=!1,p=new C(this.w);if(l&&(h=p.xLabelFormat(d,n,n,{i:s,dateFormatter:new A(this.w).formatDate,w:o}),void 0!==c&&(h=c(n,e[s],{i:s,dateFormatter:new A(this.w).formatDate,w:o}))),t.length>0){var x;let e;x=t[s].unit,e=null,t.forEach(t=>{"month"===t.unit?e="year":"day"===t.unit?e="month":"hour"===t.unit?e="day":"minute"===t.unit&&(e="hour")}),g=e===x,i=t[s].position,h=t[s].value}else"datetime"===o.config.xaxis.type&&void 0===c&&(h="");void 0===h&&(h=""),h=Array.isArray(h)?h:h.toString();let u=new Y(this.w),f={};f=o.layout.rotateXLabels&&l?u.getTextRects(h,parseInt(r,10).toString(),null,`rotate(${o.config.xaxis.labels.rotate} 0 0)`,!1):u.getTextRects(h,parseInt(r,10).toString());let m=!o.config.xaxis.labels.showDuplicates&&this.timeScale;return!Array.isArray(h)&&("NaN"===String(h)||a.indexOf(h)>=0&&m)&&(h=""),{x:i,text:h,textRect:f,isBold:g}}checkLabelBasedOnTickamount(e,t,i){let s=this.w,a=s.config.xaxis.tickAmount;return"dataPoints"===a&&(a=Math.round(s.layout.gridWidth/120)),a>i||e%Math.round(i/(a+1))==0||(t.text=""),t}checkForOverflowingLabels(e,t,i,s,a){let r=this.w;if(0===e&&r.globals.skipFirstTimelinelabel&&(t.text=""),e===i-1&&r.globals.skipLastTimelinelabel&&(t.text=""),r.config.xaxis.labels.hideOverlappingLabels&&s.length>0){let e=a[a.length-1];if(r.config.xaxis.labels.trim&&"datetime"!==r.config.xaxis.type)return t;t.x<e.textRect.width/(r.layout.rotateXLabels?Math.abs(r.config.xaxis.labels.rotate)/12:1.01)+e.x&&(t.text="")}return t}
27checkForReversedLabels(e,t){let i=this.w;return i.config.yaxis[e]&&i.config.yaxis[e].reversed&&t.reverse(),t}yAxisAllSeriesCollapsed(e){let t=this.w.globals;return!t.seriesYAxisMap[e].some(e=>-1===t.collapsedSeriesIndices.indexOf(e))}translateYAxisIndex(e){let t=this.w,i=t.globals,s=t.config.yaxis;return t.seriesData.series.length>s.length||s.some(e=>Array.isArray(e.seriesName))?e:i.seriesYAxisReverseMap[e]}isYAxisHidden(e){let t=this.w,i=t.config.yaxis[e];if(!i.show||this.yAxisAllSeriesCollapsed(e))return!0;if(!i.showForNullSeries){let i=t.globals.seriesYAxisMap[e],s=new I(this.w);return i.every(e=>s.isSeriesNull(e))}return!1}getYAxisForeColor(e,t){var i;let s=this.w;return Array.isArray(e)&&s.globals.yAxisScale[t]&&(null==(i=this.theme)||i.pushExtraColors(e,s.globals.yAxisScale[t].result.length,!1)),e}drawYAxisTicks(e,t,i,s,a,r,l){let o=this.w,n=new Y(this.w),h=o.layout.translateY+o.config.yaxis[a].labels.offsetY;if(o.globals.isBarHorizontal?h=0:"heatmap"===o.config.chart.type&&(h+=r/2),s.show&&t>0){!0===o.config.yaxis[a].opposite&&(e+=s.width);for(let a=t;a>=0;a--){let t=n.drawLine(e+i.offsetX-s.width+s.offsetX,h+s.offsetY,e+i.offsetX+s.offsetX,h+s.offsetY,s.color);l.add(t),h+=r}}}}class U{constructor(e,t,i){this.w=e,this.ctx=t,this.elgrid=i,this.axesUtils=new j(e,{theme:t.theme,timeScale:t.timeScale}),this.xaxisLabels=e.labelData.labels.slice(),e.labelData.timescaleLabels.length>0&&!e.globals.isBarHorizontal&&(this.xaxisLabels=e.labelData.timescaleLabels.slice()),e.config.xaxis.overwriteCategories&&(this.xaxisLabels=e.config.xaxis.overwriteCategories),this.drawnLabels=[],this.drawnLabelsRects=[],"top"===e.config.xaxis.position?this.offY=0:this.offY=e.layout.gridHeight,this.offY=this.offY+e.config.xaxis.axisBorder.offsetY,this.isCategoryBarHorizontal="bar"===e.config.chart.type&&e.config.plotOptions.bar.horizontal,this.xaxisFontSize=e.config.xaxis.labels.style.fontSize,this.xaxisFontFamily=e.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=e.config.xaxis.labels.style.colors,this.xaxisBorderWidth=e.config.xaxis.axisBorder.width,this.isCategoryBarHorizontal&&(this.xaxisBorderWidth=e.config.yaxis[0].axisBorder.width.toString()),String(this.xaxisBorderWidth).indexOf("%")>-1?this.xaxisBorderWidth=e.layout.gridWidth*parseInt(this.xaxisBorderWidth,10)/100:this.xaxisBorderWidth=parseInt(this.xaxisBorderWidth,10),this.xaxisBorderHeight=e.config.xaxis.axisBorder.height,this.yaxis=e.config.yaxis[0]}drawXaxis(){let e=this.w,t=new Y(this.w),i=t.group({class:"apexcharts-xaxis",transform:`translate(${e.config.xaxis.offsetX}, ${e.config.xaxis.offsetY})`}),s=t.group({class:"apexcharts-xaxis-texts-g",transform:`translate(${e.layout.translateXAxisX}, ${e.layout.translateXAxisY})`});i.add(s);let a=[];for(let e=0;e<this.xaxisLabels.length;e++)a.push(this.xaxisLabels[e]);if(this.drawXAxisLabelAndGroup(!0,t,s,a,e.axisFlags.isXNumeric,(e,t)=>t),e.labelData.hasXaxisGroups){let i=e.labelData.groups;a=[];for(let e=0;e<i.length;e++)a.push(i[e].title);let r={};e.config.xaxis.group.style&&(r.xaxisFontSize=e.config.xaxis.group.style.fontSize,r.xaxisFontFamily=e.config.xaxis.group.style.fontFamily,r.xaxisForeColors=e.config.xaxis.group.style.colors,r.fontWeight=e.config.xaxis.group.style.fontWeight,r.cssClass=e.config.xaxis.group.style.cssClass),this.drawXAxisLabelAndGroup(!1,t,s,a,!1,(e,t)=>i[e].cols*t,r)}if(void 0!==e.config.xaxis.title.text){let s=t.group({class:"apexcharts-xaxis-title"}),a=t.drawText({x:e.layout.gridWidth/2+e.config.xaxis.title.offsetX,y:this.offY+parseFloat(this.xaxisFontSize)+("bottom"===e.config.xaxis.position?e.layout.xAxisLabelsHeight:-e.layout.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});s.add(a),i.add(s)}if(e.config.xaxis.axisBorder.show){let s=e.globals.barPadForNumericAxis,a=t.drawLine(e.globals.padHorizontal+e.config.xaxis.axisBorder.offsetX-s,this.offY,this.xaxisBorderWidth+s,this.offY,e.config.xaxis.axisBorder.color,0,this.xaxisBorderHeight);this.elgrid&&this.elgrid.elGridBorders&&e.config.grid.show?this.elgrid.elGridBorders.add(a):i.add(a)}return i}drawXAxisLabelAndGroup(e,t,i,s,a,r,l={}){let o,n=[],h=[],d=this.w,c=l.xaxisFontSize||this.xaxisFontSize,g=l.xaxisFontFamily||this.xaxisFontFamily,p=l.xaxisForeColors||this.xaxisForeColors,x=l.fontWeight||d.config.xaxis.labels.style.fontWeight,u=l.cssClass||d.config.xaxis.labels.style.cssClass,f=d.globals.padHorizontal,m=s.length,b="category"===d.config.xaxis.type?d.globals.dataPoints:m;if(0===b&&m>b&&(b=m),a){let e=Math.max(Number(d.config.xaxis.tickAmount)||1,b>1?b-1:b);f=f+r(0,o=d.layout.gridWidth/Math.min(e,m-1))/2+d.config.xaxis.labels.offsetX}else f=f+r(0,o=d.layout.gridWidth/b)+d.config.xaxis.labels.offsetX;for(let a=0;a<=m-1;a++){let l=f-r(a,o)/2+d.config.xaxis.labels.offsetX;0===a&&1===m&&o/2===f&&1===b&&(l=d.layout.gridWidth/2);let y=this.axesUtils.getLabel(s,d.labelData.timescaleLabels,l,a,n,c,e),v=28;d.layout.rotateXLabels&&e&&(v=22),d.config.xaxis.title.text&&"top"===d.config.xaxis.position&&(v+=parseFloat(d.config.xaxis.title.style.fontSize)+2),e||(v=v+parseFloat(c)+(d.layout.xAxisLabelsHeight-d.layout.xAxisGroupLabelsHeight)+10*!!d.layout.rotateXLabels),y=void 0!==d.config.xaxis.tickAmount&&"dataPoints"!==d.config.xaxis.tickAmount&&"datetime"!==d.config.xaxis.type?this.axesUtils.checkLabelBasedOnTickamount(a,y,m):this.axesUtils.checkForOverflowingLabels(a,y,m,n,h);let A=()=>e&&d.config.xaxis.convertedCatToNumeric?p[d.globals.minX+a-1]:p[a];if(d.config.xaxis.labels.show){let s=t.drawText({x:y.x,y:this.offY+d.config.xaxis.labels.offsetY+v-("top"===d.config.xaxis.position?d.layout.xAxisHeight+d.config.xaxis.axisTicks.height-2:0),text:y.text,textAnchor:"middle",fontWeight:y.isBold?600:x,fontSize:c,fontFamily:g,foreColor:Array.isArray(p)?A():p,isPlainText:!1,
27cssClass:(e?"apexcharts-xaxis-label ":"apexcharts-xaxis-group-label ")+u});if(i.add(s),s.on("click",e=>{if("function"==typeof d.config.chart.events.xAxisLabelClick){let t=Object.assign({},d,{labelIndex:a});d.config.chart.events.xAxisLabelClick(e,this.ctx,t)}}),e){let e=w.createElementNS(B,"title");e.textContent=Array.isArray(y.text)?y.text.join(" "):y.text,s.node.appendChild(e),""!==y.text&&(n.push(y.text),h.push(y))}}a<m-1&&(f+=r(a+1,o))}}drawXaxisInversed(e){let t=this.w,i=new Y(this.w),s=t.config.yaxis[0].opposite?t.globals.translateYAxisX[e]:0,a=i.group({class:"apexcharts-yaxis apexcharts-xaxis-inversed",rel:e}),r=i.group({class:"apexcharts-yaxis-texts-g apexcharts-xaxis-inversed-texts-g",transform:"translate("+s+", 0)"});a.add(r);let l=[];if(t.config.yaxis[e].show)for(let e=0;e<this.xaxisLabels.length;e++)l.push(this.xaxisLabels[e]);let o=t.layout.gridHeight/l.length,n=-(o/2.2),h=t.formatters.yLabelFormatters[0],d=t.config.yaxis[0].labels;if(d.show)for(let s=0;s<=l.length-1;s++){let a=void 0===l[s]?"":l[s];a=h(a,{seriesIndex:e,dataPointIndex:s,w:t});let c=this.axesUtils.getYAxisForeColor(d.style.colors,e),g=()=>Array.isArray(c)?c[s]:c,p=0;Array.isArray(a)&&(p=a.length/2*parseInt(d.style.fontSize,10));let x=d.offsetX-15,u="end";this.yaxis.opposite&&(u="start"),"left"===t.config.yaxis[0].labels.align?(x=d.offsetX,u="start"):"center"===t.config.yaxis[0].labels.align?(x=d.offsetX,u="middle"):"right"===t.config.yaxis[0].labels.align&&(u="end");let f=i.drawText({x:x,y:n+o+d.offsetY-p,text:a,textAnchor:u,foreColor:g(),fontSize:d.style.fontSize,fontFamily:d.style.fontFamily,fontWeight:d.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+d.style.cssClass,maxWidth:d.maxWidth});r.add(f),f.on("click",e=>{if("function"==typeof t.config.chart.events.xAxisLabelClick){let i=Object.assign({},t,{labelIndex:s});t.config.chart.events.xAxisLabelClick(e,this.ctx,i)}});let m=w.createElementNS(B,"title");if(m.textContent=Array.isArray(a)?a.join(" "):a,f.node.appendChild(m),0!==t.config.yaxis[e].labels.rotate){let s=i.rotateAroundCenter(f.node);f.node.setAttribute("transform",`rotate(${t.config.yaxis[e].labels.rotate} 0 ${s.y})`)}n+=o}if(void 0!==t.config.yaxis[0].title.text){let e=i.group({class:"apexcharts-yaxis-title apexcharts-xaxis-title-inversed",transform:"translate("+s+", 0)"}),r=i.drawText({x:t.config.yaxis[0].title.offsetX,y:t.layout.gridHeight/2+t.config.yaxis[0].title.offsetY,text:t.config.yaxis[0].title.text,textAnchor:"middle",foreColor:t.config.yaxis[0].title.style.color,fontSize:t.config.yaxis[0].title.style.fontSize,fontWeight:t.config.yaxis[0].title.style.fontWeight,fontFamily:t.config.yaxis[0].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+t.config.yaxis[0].title.style.cssClass});e.add(r),a.add(e)}let c=0;this.isCategoryBarHorizontal&&t.config.yaxis[0].opposite&&(c=t.layout.gridWidth);let g=t.config.xaxis.axisBorder;if(g.show){let e=i.drawLine(t.globals.padHorizontal+g.offsetX+c,1+g.offsetY,t.globals.padHorizontal+g.offsetX+c,t.layout.gridHeight+g.offsetY,g.color,0);this.elgrid&&this.elgrid.elGridBorders&&t.config.grid.show?this.elgrid.elGridBorders.add(e):a.add(e)}return t.config.yaxis[0].axisTicks.show&&this.axesUtils.drawYAxisTicks(c,l.length,t.config.yaxis[0].axisBorder,t.config.yaxis[0].axisTicks,0,o,a),a}drawXaxisTicks(e,t,i){let s=this.w;if(e<0||e-2>s.layout.gridWidth)return;let a=this.offY+s.config.xaxis.axisTicks.offsetY;if(t=t+a+s.config.xaxis.axisTicks.height,"top"===s.config.xaxis.position&&(t=a-s.config.xaxis.axisTicks.height),s.config.xaxis.axisTicks.show){let r=new Y(this.w).drawLine(e+s.config.xaxis.axisTicks.offsetX,a+s.config.xaxis.offsetY,e+s.config.xaxis.axisTicks.offsetX,t+s.config.xaxis.offsetY,s.config.xaxis.axisTicks.color);i.add(r),r.node.classList.add("apexcharts-xaxis-tick")}}getXAxisTicksPositions(){let e=this.w,t=[],i=this.xaxisLabels.length,s=e.globals.padHorizontal;if(e.labelData.timescaleLabels.length>0)for(let e=0;e<i;e++)s=this.xaxisLabels[e].position,t.push(s);else for(let a=0;a<i;a++){let a=i;e.axisFlags.isXNumeric&&"bar"!==e.config.chart.type&&(a-=1),s+=e.layout.gridWidth/a,t.push(s)}return t}xAxisLabelCorrections(){var e,t,i;let s=this.w,a=new Y(this.w),r=s.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g"),l=s.dom.baseEl.querySelectorAll(".apexcharts-xaxis-texts-g text:not(.apexcharts-xaxis-group-label)"),o=s.dom.baseEl.querySelectorAll(".apexcharts-yaxis-inversed text"),n=s.dom.baseEl.querySelectorAll(".apexcharts-xaxis-inversed-texts-g text tspan");if(s.layout.rotateXLabels||s.config.xaxis.labels.rotateAlways)for(let e=0;e<l.length;
27e++){let t=a.rotateAroundCenter(l[e]);t.y=t.y-1,t.x=t.x+1,l[e].setAttribute("transform",`rotate(${s.config.xaxis.labels.rotate} ${t.x} ${t.y})`),l[e].setAttribute("text-anchor","end"),null==r||r.setAttribute("transform","translate(0, -10)");let i=l[e].childNodes;s.config.xaxis.labels.trim&&Array.prototype.forEach.call(i,e=>{a.placeTextWithEllipsis(e,e.textContent,s.layout.xAxisLabelsHeight-("bottom"===s.config.legend.position?20:10))})}else{let e=s.layout.gridWidth/(s.labelData.labels.length+1);for(let t=0;t<l.length;t++){let i=l[t].childNodes;s.config.xaxis.labels.trim&&"datetime"!==s.config.xaxis.type&&Array.prototype.forEach.call(i,t=>{a.placeTextWithEllipsis(t,t.textContent,e)})}}if(o.length>0){let r=o[o.length-1].getBBox(),l=o[0].getBBox();r.x<-20&&(null==(e=o[o.length-1].parentNode)||e.removeChild(o[o.length-1])),l.x+l.width>s.layout.gridWidth&&!s.globals.isBarHorizontal&&(null==(t=o[0].parentNode)||t.removeChild(o[0]));for(let e=0;e<n.length;e++)a.placeTextWithEllipsis(n[e],null!=(i=n[e].textContent)?i:"",s.config.yaxis[0].labels.maxWidth-(s.config.yaxis[0].title.text?2*parseFloat(s.config.yaxis[0].title.style.fontSize):0)-15)}}}class Z{constructor(e,t){this.w=e,this.ctx=t,this.xaxisLabels=e.labelData.labels.slice(),this.axesUtils=new j(t.w,{theme:t.theme,timeScale:t.timeScale}),this.isRangeBar=e.rangeData.seriesRange.length&&e.globals.isBarHorizontal,e.labelData.timescaleLabels.length>0&&(this.xaxisLabels=e.labelData.timescaleLabels.slice())}drawGridArea(e=null){let t=this.w,i=new Y(this.w);e||(e=i.group({class:"apexcharts-grid"}));let s=i.drawLine(t.globals.padHorizontal,1,t.globals.padHorizontal,t.layout.gridHeight,"transparent"),a=i.drawLine(t.globals.padHorizontal,t.layout.gridHeight,t.layout.gridWidth,t.layout.gridHeight,"transparent");return e.add(a),e.add(s),e}drawGrid(){if(this.w.globals.axisCharts){let e=this.renderGrid();return this.drawGridArea(e.el),e}return null}createGridMask(){let e=this.w,t=e.globals,i=new Y(this.w),s=Array.isArray(e.config.stroke.width)?Math.max(...e.config.stroke.width):e.config.stroke.width,a=e=>{let t=w.createElementNS(B,"clipPath");return t.setAttribute("id",e),t};e.dom.elGridRectMask=a(`gridRectMask${t.cuid}`),e.dom.elGridRectBarMask=a(`gridRectBarMask${t.cuid}`),e.dom.elGridRectMarkerMask=a(`gridRectMarkerMask${t.cuid}`),e.dom.elForecastMask=a(`forecastMask${t.cuid}`),e.dom.elNonForecastMask=a(`nonForecastMask${t.cuid}`);let r=["bar","rangeBar","candlestick","boxPlot"].includes(e.config.chart.type)||e.globals.comboBarCount>0,l=0,o=0;r&&e.axisFlags.isXNumeric&&!e.globals.isBarHorizontal&&(l=Math.max(e.config.grid.padding.left,t.barPadForNumericAxis),o=Math.max(e.config.grid.padding.right,t.barPadForNumericAxis)),e.dom.elGridRect=i.drawRect(-s/2-2,-s/2-2,e.layout.gridWidth+s+4,e.layout.gridHeight+s+4,0,"#fff"),e.dom.elGridRectBar=i.drawRect(-s/2-l-2,-s/2-2,e.layout.gridWidth+s+o+l+4,e.layout.gridHeight+s+4,0,"#fff");let n=e.globals.markers.largestSize;e.dom.elGridRectMarker=i.drawRect(Math.min(-s/2-l-2,-n),-n,e.layout.gridWidth+Math.max(s+o+l+4,2*n),e.layout.gridHeight+2*n,0,"#fff"),e.dom.elGridRectMask.appendChild(e.dom.elGridRect.node),e.dom.elGridRectBarMask.appendChild(e.dom.elGridRectBar.node),e.dom.elGridRectMarkerMask.appendChild(e.dom.elGridRectMarker.node);let h=e.dom.elDefs.node;h.appendChild(e.dom.elGridRectMask),h.appendChild(e.dom.elGridRectBarMask),h.appendChild(e.dom.elGridRectMarkerMask),h.appendChild(e.dom.elForecastMask),h.appendChild(e.dom.elNonForecastMask)}_drawGridLines({i:e,x1:t,y1:i,x2:s,y2:a,xCount:r,parent:l}){let o=this.w;if((0!==e||!o.globals.skipFirstTimelinelabel)&&(e!==r-1||!o.globals.skipLastTimelinelabel||o.config.xaxis.labels.formatter)&&"radar"!==o.config.chart.type&&1){o.config.grid.xaxis.lines.show&&this._drawGridLine({i:e,x1:t,y1:i,x2:s,y2:a,xCount:r,parent:l});let n=0;if(o.labelData.hasXaxisGroups&&"between"===o.config.xaxis.tickPlacement){let t=o.labelData.groups;if(t){let i=0;for(let s=0;i<e&&s<t.length;s++)i+=t[s].cols;i===e&&(n=.6*o.layout.xAxisLabelsHeight)}}new U(this.w,this.ctx).drawXaxisTicks(t,n,o.dom.elGraphical)}}_drawGridLine({i:e,x1:t,y1:i,x2:s,y2:a,xCount:r,parent:l}){let o=this.w,n=l.node.classList.contains("apexcharts-gridlines-h
27orizontal"),h=o.globals.barPadForNumericAxis,d=0===i&&0===a||0===t&&0===s||i===o.layout.gridHeight&&a===o.layout.gridHeight||o.globals.isBarHorizontal&&(0===e||e===r-1),c=new Y(this.w).drawLine(t-(n?h:0),i,s+(n?h:0),a,o.config.grid.borderColor,o.config.grid.strokeDashArray);c.node.classList.add("apexcharts-gridline"),d&&o.config.grid.show?this.elGridBorders.add(c):l.add(c)}_drawGridBandRect({c:e,x1:t,y1:i,x2:s,y2:a,type:r}){let l=this.w,o=new Y(this.w),n=l.globals.barPadForNumericAxis,h=l.config.grid[r].colors[e],d=o.drawRect(t-("row"===r?n:0),i,s+("row"===r?2*n:0),a,0,h,l.config.grid[r].opacity);this.elg.add(d),d.attr("clip-path",`url(#gridRectMask${l.globals.cuid})`),d.node.classList.add(`apexcharts-grid-${r}`)}_drawXYLines({xCount:e,tickAmount:t}){var i;let s=this.w,a=({xC:t,x1:i,y1:s,x2:a,y2:r})=>{for(let l=0;l<t;l++)i=this.xaxisLabels[l].position,a=this.xaxisLabels[l].position,this._drawGridLines({i:l,x1:i,y1:s,x2:a,y2:r,xCount:e,parent:this.elgridLinesV})},r=({xC:t,x1:i,y1:a,x2:r,y2:l})=>{for(let o=0;o<t+ +!s.axisFlags.isXNumeric;o++)0===o&&1===t&&1===s.globals.dataPoints&&(r=i=s.layout.gridWidth/2),this._drawGridLines({i:o,x1:i,y1:a,x2:r,y2:l,xCount:e,parent:this.elgridLinesV}),i+=s.layout.gridWidth/(s.axisFlags.isXNumeric?t-1:t),r=i};if(s.config.grid.xaxis.lines.show||s.config.xaxis.axisTicks.show){let t,l=s.globals.padHorizontal,o=s.layout.gridHeight;s.labelData.timescaleLabels.length?a({xC:e,x1:l,y1:0,x2:t,y2:o}):(s.axisFlags.isXNumeric&&(e=null==(i=s.globals.xAxisScale)?void 0:i.result.length),r({xC:e,x1:l,y1:0,x2:t,y2:o}))}if(s.config.grid.yaxis.lines.show){let e=0,i=0,a=s.layout.gridWidth,r=t+1;this.isRangeBar&&(r=s.labelData.labels.length);for(let l=0;l<r+ +!!this.isRangeBar;l++)this._drawGridLine({i:l,xCount:r+ +!!this.isRangeBar,x1:0,y1:e,x2:a,y2:i,parent:this.elgridLinesH}),e+=s.layout.gridHeight/(this.isRangeBar?r:t),i=e}}_drawInvertedXYLines({xCount:e}){let t=this.w;if(t.config.grid.xaxis.lines.show||t.config.xaxis.axisTicks.show){let i,s=t.globals.padHorizontal,a=t.layout.gridHeight;for(let r=0;r<e+1;r++)t.config.grid.xaxis.lines.show&&this._drawGridLine({i:r,xCount:e+1,x1:s,y1:0,x2:i,y2:a,parent:this.elgridLinesV}),new U(this.w,this.ctx).drawXaxisTicks(s,0,t.dom.elGraphical),s+=t.layout.gridWidth/e,i=s}if(t.config.grid.yaxis.lines.show){let e=0,i=0,s=t.layout.gridWidth;for(let a=0;a<t.globals.dataPoints+1;a++)this._drawGridLine({i:a,xCount:t.globals.dataPoints+1,x1:0,y1:e,x2:s,y2:i,parent:this.elgridLinesH}),e+=t.layout.gridHeight/t.globals.dataPoints,i=e}}renderGrid(){var e,t,i;let s,a=this.w,r=a.globals,l=new Y(this.w);this.elg=l.group({class:"apexcharts-grid"}),this.elgridLinesH=l.group({class:"apexcharts-gridlines-horizontal"}),this.elgridLinesV=l.group({class:"apexcharts-gridlines-vertical"}),this.elGridBorders=l.group({class:"apexcharts-grid-borders"}),this.elg.add(this.elgridLinesH),this.elg.add(this.elgridLinesV),a.config.grid.show||(this.elgridLinesV.hide(),this.elgridLinesH.hide(),this.elGridBorders.hide());let o=0;for(;o<r.seriesYAxisMap.length&&r.ignoreYAxisIndexes.includes(o);)o++;o===r.seriesYAxisMap.length&&(o=0);let n=r.yAxisScale[o].result.length-1;return!r.isBarHorizontal||this.isRangeBar?(s=this.xaxisLabels.length,this.isRangeBar&&(n=a.labelData.labels.length,a.config.xaxis.tickAmount&&a.config.xaxis.labels.formatter&&(s=a.config.xaxis.tickAmount),(null==(i=null==(t=null==(e=r.yAxisScale)?void 0:e[o])?void 0:t.result)?void 0:i.length)>0&&"datetime"!==a.config.xaxis.type&&(s=r.yAxisScale[o].result.length-1)),this._drawXYLines({xCount:s,tickAmount:n})):(s=n,n=r.xTickAmount,this._drawInvertedXYLines({xCount:s,tickAmount:n})),this.drawGridBands(s,n),{el:this.elg,elGridBorders:this.elGridBorders,xAxisTickWidth:a.layout.gridWidth/s}}drawGridBands(e,t){var i,s,a,r,l;let o=this.w,n=(e,i,s,a,r,l)=>{for(let n=0,h=0;n<i;n++,h++)h>=o.config.grid[e].colors.length&&(h=0),this._drawGridBandRect({c:h,x1:s,y1:a,x2:r,y2:l,type:e}),a+=o.layout.gridHeight/t};if((null==(i=o.config.grid.row.colors)?void 0:i.length)>0&&n("row",t,0,0,o.layout.gridWidth,o.layout.gridHeight/t),(null==(s=o.config.grid.column.colors)?void 0:s.length)>0){let t=!o.globals.isBarHorizontal&&"on"===o.config.xaxis.tickPlacement&&("category"===o.config.xaxis.type||o.config.xaxis.convertedCatToNumeric)?e-1:e;o.axisFlags.isXNumeric&&(t=(null!=(r=null==(a=o.globals.xAxisScale)?void 0:a.result.length)?r:1)-1);let i=o.globals.padHorizontal,s=o.globals.padHorizontal+o.layout.gridWidth/t,n=o.layout.gridHeight;for(let a=0,r=0;a<e;a++,r++)r>=o.config.grid.column.colors.length&&(r=0),"datetime"===o.config.xaxis.type&&(i=this.xaxisLabels[a].position,s=((null==(l=this.xaxisLabels[a+1])?void 0:l.position)||o.layout.gridWidth)-this.xaxisLabels[a].position),this._drawGri
27dBandRect({c:r,x1:i,y1:0,x2:s,y2:n,type:"column"}),i+=o.layout.gridWidth/t}}}class q{constructor(e){this.w=e,this.coreUtils=new I(this.w)}niceScale(e,t,i=0){let s,a,r,l,o=this.w,n=o.globals;n.isBarHorizontal?(s=o.config.xaxis,a=Math.max((n.svgWidth-100)/25,2)):(s=o.config.yaxis[i],a=Math.max((n.svgHeight-100)/15,2)),v.isNumber(a)||(a=10),r=void 0!==s.min&&null!==s.min,l=void 0!==s.max&&null!==s.min;let h=void 0!==s.stepSize&&null!==s.stepSize,d=void 0!==s.tickAmount&&null!==s.tickAmount,c=d?s.tickAmount:T[Math.min(Math.round(a/2),T.length-1)];if(n.isMultipleYAxis&&!d&&n.multiAxisTickAmount>0&&(c=n.multiAxisTickAmount,d=!0),c="dataPoints"===c?n.dataPoints-1:Math.abs(Math.round(c)),(5e-324!==e||0!==t)&&(v.isNumber(e)||v.isNumber(t))&&(5e-324!==e||t!==-Number.MAX_VALUE)||(e=v.isNumber(s.min)?s.min:0,t=v.isNumber(s.max)?s.max:e+c,n.allSeriesCollapsed=!1),e>t){console.warn("axis.min cannot be greater than axis.max: swapping min and max");let i=t;t=e,e=i}else e===t&&(e=0===e?0:e-1,t=0===t?2:t+1);let g=[];c<1&&(c=1);let p=c,x=Math.abs(t-e);!r&&e>0&&e/x<.15&&(e=0,r=!0),!l&&t<0&&-t/x<.15&&(t=0,l=!0);let u=(x=Math.abs(t-e))/p,f=u,m=Math.floor(Math.log10(f)),b=Math.pow(10,m),y=Math.ceil(f/b);if(u=f=(y=E[+(0!==n.yValueDecimal)][y])*b,n.isBarHorizontal&&s.stepSize&&"datetime"!==s.type?(u=s.stepSize,h=!0):h&&(u=s.stepSize),h&&s.forceNiceScale){let e=Math.floor(Math.log10(u));u*=Math.pow(10,m-e)}if(r&&l){let e=x/p;if(d)if(h)if(0!=v.mod(x,u)){let t=v.getGCD(u,e);u=e/t<10?t:e}else 0==v.mod(u,e)?u=e:(e=u,d=!1);else u=e;else if(h)0==v.mod(x,u)?e=u:u=e;else if(0==v.mod(x,u))e=u;else{p=Math.ceil(x/u),e=x/p;let t=v.getGCD(x,u);x/t<a&&(e=t),u=e}p=Math.round(x/u)}else{if(r||l){if(l)if(d)e=t-u*p;else{let i=e;Math.abs(t-(e=u*Math.floor(e/u)))/v.getGCD(x,u)>a&&(e=t-u*c,e+=u*Math.floor((i-e)/u))}else if(r)if(d)t=e+u*p;else{let i=t;Math.abs((t=u*Math.ceil(t/u))-e)/v.getGCD(x,u)>a&&(t=e+u*c,t+=u*Math.ceil((i-t)/u))}}else if(n.isMultipleYAxis&&d){let i=u*Math.floor(e/u),s=i+u*p;s<t&&(u*=2),e=i,s=t,x=Math.abs((t=e+u*p)-e),e>0&&e<Math.abs(s-t)&&(e=0,t=u*p),t<0&&-t<Math.abs(i-e)&&(t=0,e=-u*p)}else e=u*Math.floor(e/u),t=u*Math.ceil(t/u);x=Math.abs(t-e),u=v.getGCD(x,u),p=Math.round(x/u)}if(!d&&!(r||l)&&(p=Math.ceil((x-1e-11)/(u+1e-11)))>16&&v.getPrimeFactors(p).length<2&&p++,!d&&s.forceNiceScale&&0===n.yValueDecimal&&p>x&&(p=x,u=Math.round(x/p)),p>a&&(!(d||h)||s.forceNiceScale)){let e=v.getPrimeFactors(p),t=e.length-1,i=p;e:for(var w=0;w<t;w++)for(var A=0;A<=t-w;A++){let s=Math.min(A+w,t),r=i,l=1;for(var C=A;C<=s;C++)l*=e[C];if((r/=l)<a){i=r;break e}}u=i===p?x:x/i,p=Math.round(x/u)}n.isMultipleYAxis&&0==n.multiAxisTickAmount&&0>n.ignoreYAxisIndexes.indexOf(i)&&(n.multiAxisTickAmount=p);let S=e-u,k=1e-11*u;do S+=u,g.push(v.stripNumber(S,7));while(t-S>k);return{result:g,niceMin:g[0],niceMax:g[g.length-1]}}linearScale(e,t,i=10,s=0,a){let r=Math.abs(t-e),l=[];if(e===t)return{result:l=[e],niceMin:l[0],niceMax:l[l.length-1]};"dataPoints"===(i=this._adjustTicksForSmallRange(i,s,r))&&(i=this.w.globals.dataPoints-1);let o=i;if(a||(a=r/o),0!==a&&isFinite(a)){let e=Math.pow(10,Math.max(2,-Math.floor(Math.log10(Math.abs(a)))+2));a=Math.round((a+Number.EPSILON)*e)/e}let n=i===Number.MAX_VALUE?5:o;i===Number.MAX_VALUE&&(a=1);let h=e;for(;n>=0;)l.push(h),h=v.preciseAddition(h,a),n-=1;return{result:l,niceMin:l[0],niceMax:l[l.length-1]}}logarithmicScaleNice(e,t,i){t<=0&&(t=Math.max(e,i)),e<=0&&(e=Math.min(t,i));let s=[],a=Math.ceil(Math.log(t)/Math.log(i)+1),r=Math.floor(Math.log(e)/Math.log(i));for(let e=r;e<a;e++)s.push(Math.pow(i,e));return{result:s,niceMin:s[0],niceMax:s[s.length-1]}}logarithmicScale(e,t,i){t<=0&&(t=Math.max(e,i)),e<=0&&(e=Math.min(t,i));let s=[],a=Math.log(t)/Math.log(i),r=Math.log(e)/Math.log(i),l=a-r,o=Math.round(l),n=l/o;for(let e=0,t=r;e<o;e++,t+=n)s.push(Math.pow(i,t));return s.push(Math.pow(i,a)),{result:s,niceMin:e,niceMax:t}}_adjustTicksForSmallRange(e,t,i){let s=e;if(void 0!==t&&this.w.config.yaxis[t].labels.formatter&&void 0===this.w.config.yaxis[t].tickAmount){let e=Number(this.w.config.yaxis[t].labels.formatter(1));v.isNumber(e)&&0===this.w.globals.yValueDecimal&&(s=Math.ceil(i))}return s<e?s:e}setYScaleForIndex(e,t,i){let s=this.w.globals,a=this.w.config,r=s.isBarHorizontal?a.xaxis:a.yaxis[e];void 0===s.yAxisScale[e]&&(s.yAxisScale[e]=[]);let l=Math.abs(i-t);r.logarithmic&&l<=5&&(s.invalidLogScale=!0),r.logarithmic&&l>5?(s.allSeriesCollapsed=!1,s.yAxisScale[e]=r.forceNiceScale?this.logarithmicScaleNice(t,
27i,r.logBase):this.logarithmicScale(t,i,r.logBase)):i!==-Number.MAX_VALUE&&v.isNumber(i)&&t!==Number.MAX_VALUE&&v.isNumber(t)?(s.allSeriesCollapsed=!1,s.yAxisScale[e]=this.niceScale(t,i,e)):s.yAxisScale[e]=this.niceScale(5e-324,0,e)}setXScale(e,t){let i=this.w,s=i.globals;if(t!==-Number.MAX_VALUE&&v.isNumber(t)){let a=s.xTickAmount;s.xAxisScale=this.linearScale(e,t,a,0,void 0===i.config.xaxis.max?i.config.xaxis.stepSize:void 0)}else s.xAxisScale=this.linearScale(0,10,10);return s.xAxisScale}scaleMultipleYAxes(){let e=this.w.config,t=this.w.globals;this.coreUtils.setSeriesYAxisMappings();let i=t.seriesYAxisMap,s=t.minYArr,a=t.maxYArr;t.allSeriesCollapsed=!0,t.barGroups=[],i.forEach((i,r)=>{let l=[];if(i.forEach(t=>{var i;let s=null==(i=e.series[t])?void 0:i.group;0>l.indexOf(s)&&l.push(s)}),i.length>0){let o,n,h=Number.MAX_VALUE,d=-Number.MAX_VALUE,c=h,g=d;if(e.chart.stacked){let s=Array(t.dataPoints).fill(0),a=[],p=[],x=[];l.forEach(()=>{a.push(s.map(()=>5e-324)),p.push(s.map(()=>5e-324)),x.push(s.map(()=>5e-324))});for(let s=0;s<i.length;s++){!o&&e.series[i[s]].type&&(o=e.series[i[s]].type);let h=i[s];n=e.series[h].group?e.series[h].group:"axis-".concat(r.toString()),0>t.collapsedSeriesIndices.indexOf(h)&&0>t.ancillaryCollapsedSeriesIndices.indexOf(h)&&(t.allSeriesCollapsed=!1,l.forEach((t,i)=>{if(e.series[h].group===t)for(let e=0;e<this.w.seriesData.series[h].length;e++){let t=this.w.seriesData.series[h][e];t>=0?p[i][e]+=t:x[i][e]+=t,a[i][e]+=t,c=Math.min(c,t),g=Math.max(g,t)}})),("bar"===o||"column"===o)&&t.barGroups.push(n)}o||(o=e.chart.type),"bar"===o||"column"===o?l.forEach((e,t)=>{h=Math.min(h,Math.min.apply(null,x[t])),d=Math.max(d,Math.max.apply(null,p[t]))}):(l.forEach((e,t)=>{c=Math.min(c,Math.min.apply(null,a[t])),g=Math.max(g,Math.max.apply(null,a[t]))}),h=c,d=g),5e-324===h&&5e-324===d&&(d=-Number.MAX_VALUE)}else for(let e=0;e<i.length;e++){let r=i[e];h=Math.min(h,s[r]),d=Math.max(d,a[r]),0>t.collapsedSeriesIndices.indexOf(r)&&0>t.ancillaryCollapsedSeriesIndices.indexOf(r)&&(t.allSeriesCollapsed=!1)}void 0!==e.yaxis[r].min&&(h="function"==typeof e.yaxis[r].min?e.yaxis[r].min(h):e.yaxis[r].min),void 0!==e.yaxis[r].max&&(d="function"==typeof e.yaxis[r].max?e.yaxis[r].max(d):e.yaxis[r].max),t.barGroups=t.barGroups.filter((e,t,i)=>i.indexOf(e)===t),this.setYScaleForIndex(r,h,d),i.forEach(e=>{s[e]=t.yAxisScale[r].niceMin,a[e]=t.yAxisScale[r].niceMax})}else this.setYScaleForIndex(r,0,-Number.MAX_VALUE)})}}class K{constructor(e){this.w=e,this.scales=new q(this.w)}init(){this.setYRange(),this.setXRange(),this.setZRange()}getMinYMaxY(e,t=Number.MAX_VALUE,i=-Number.MAX_VALUE,s=null){var a,r,l,o,n;let h=this.w.config,d=this.w.globals,c=-Number.MAX_VALUE,g=5e-324;null===s&&(s=e+1);let p=this.w.seriesData.series,x=p,u=p;"candlestick"===h.chart.type?(x=this.w.candleData.seriesCandleL,u=this.w.candleData.seriesCandleH):"boxPlot"===h.chart.type?(x=this.w.candleData.seriesCandleO,u=this.w.candleData.seriesCandleC):this.w.axisFlags.isRangeData&&(x=this.w.rangeData.seriesRangeStart,u=this.w.rangeData.seriesRangeEnd);let f=!1;if(this.w.seriesData.seriesX.length>=s){let e=null==(a=d.brushSource)?void 0:a.w.config.chart.brush;(h.chart.zoom.enabled&&h.chart.zoom.autoScaleYaxis||(null==e?void 0:e.enabled)&&(null==e?void 0:e.autoScaleYaxis))&&(f=!0)}for(let a=e;a<s;a++){d.dataPoints=Math.max(d.dataPoints,p[a].length);let e=h.series[a].type;this.w.labelData.categoryLabels.length&&(d.dataPoints=this.w.labelData.categoryLabels.filter(e=>void 0!==e).length),this.w.labelData.labels.length&&"datetime"!==h.xaxis.type&&0!==this.w.seriesData.series.reduce((e,t)=>e+t.length,0)&&(d.dataPoints=Math.max(d.dataPoints,this.w.labelData.labels.length));let s=0,m=p[a].length-1;if(f){if(h.xaxis.min)for(;s<m&&this.w.seriesData.seriesX[a][s]<h.xaxis.min;s++);if(h.xaxis.max)for(;m>s&&this.w.seriesData.seriesX[a][m]>h.xaxis.max;m--);}for(let h=s;h<=m&&h<this.w.seriesData.series[a].length;h++){let s=p[a][h];if(null!==s&&v.isNumber(s)){switch(void 0!==(null==(r=u[a])?void 0:r[h])&&(c=Math.max(c,u[a][h]),t=Math.min(t,u[a][h])),void 0!==(null==(l=x[a])?void 0:l[h])&&(t=Math.min(t,x[a][h]),i=Math.max(i,x[a][h])),e){case"candlestick":void 0!==this.w.candleData.seriesCandleC[a][h]&&(c=Math.max(c,this.w.candleData.seriesCandleH[a][h]),t=Math.min(t,this.w.candleData.seriesCandleL[a][h]));break;case"boxPlot":void 0!==this.w.candleData.seriesCandleC[a][h]&&(c=Math.max(c,this.w.candleData.seriesCandleC[a][h]),t=Math.min(t,this.w.candleData.seriesCandleO[a][h]))}e&&"candlestick"!==e&&"boxPlot"!==e&&"rangeArea"!==e&&"rangeBar"!==e&&(c=Math.max(c,this.w.seriesData.series[a][h]),t=Math.min(t,this.w.seriesData.series[a][h])),this.w.seriesData.seriesGoals[a]&&this.w.seriesData.seriesGoals[a][h]&&Array.isArray(this.w.seriesData.seriesGoals[a][h])&&this.w.seriesData.seriesGoals[a][h].forEac
27h(e=>{c=Math.max(c,e.value),t=Math.min(t,e.value)}),i=c,s=v.noExponents(s),v.isFloat(s)&&(d.yValueDecimal=Math.max(d.yValueDecimal,s.toString().split(".")[1].length)),g>(null==(o=x[a])?void 0:o[h])&&(null==(n=x[a])?void 0:n[h])<0&&(g=x[a][h])}else d.hasNullValues=!0}("bar"===e||"column"===e)&&(g<0&&c<0&&(c=0,i=Math.max(i,0)),5e-324===g&&(g=0,t=Math.min(t,0)))}return"rangeBar"===h.chart.type&&this.w.rangeData.seriesRangeStart.length&&d.isBarHorizontal&&(g=t),"bar"===h.chart.type&&(g<0&&c<0&&(c=0),5e-324===g&&(g=0)),{minY:g,maxY:c,lowestY:t,highestY:i}}setYRange(){let e,t=this.w.globals,i=this.w.config;t.maxY=-Number.MAX_VALUE,t.minY=5e-324;let s=Number.MAX_VALUE;if(t.isMultipleYAxis){s=Number.MAX_VALUE;for(let i=0;i<this.w.seriesData.series.length;i++)e=this.getMinYMaxY(i),t.minYArr[i]=e.lowestY,t.maxYArr[i]=e.highestY,s=Math.min(s,e.lowestY)}return e=this.getMinYMaxY(0,s,void 0,this.w.seriesData.series.length),"bar"===i.chart.type?(t.minY=e.minY,t.maxY=e.maxY):(t.minY=e.lowestY,t.maxY=e.highestY),s=e.lowestY,i.chart.stacked&&this._setStackedMinMax(),"line"!==i.chart.type&&"area"!==i.chart.type&&"scatter"!==i.chart.type&&"candlestick"!==i.chart.type&&"boxPlot"!==i.chart.type&&("rangeBar"!==i.chart.type||t.isBarHorizontal)?t.minY=5e-324!==t.minY?Math.min(e.minY,t.minY):e.minY:5e-324===t.minY&&s!==-Number.MAX_VALUE&&s!==t.maxY&&(t.minY=s),i.yaxis.forEach((e,i)=>{void 0!==e.max&&("number"==typeof e.max?t.maxYArr[i]=e.max:"function"==typeof e.max&&(t.maxYArr[i]=e.max(t.isMultipleYAxis?t.maxYArr[i]:t.maxY)),t.maxY=t.maxYArr[i]),void 0!==e.min&&("number"==typeof e.min?t.minYArr[i]=e.min:"function"==typeof e.min&&(t.minYArr[i]=e.min(t.isMultipleYAxis?5e-324===t.minYArr[i]?0:t.minYArr[i]:t.minY)),t.minY=t.minYArr[i])}),t.isBarHorizontal&&["min","max"].forEach(e=>{void 0!==i.xaxis[e]&&"number"==typeof i.xaxis[e]&&("min"===e?t.minY=i.xaxis[e]:t.maxY=i.xaxis[e])}),t.isMultipleYAxis?(this.scales.scaleMultipleYAxes(),t.minY=s):(this.scales.setYScaleForIndex(0,t.minY,t.maxY),t.minY=t.yAxisScale[0].niceMin,t.maxY=t.yAxisScale[0].niceMax,t.minYArr[0]=t.minY,t.maxYArr[0]=t.maxY),t.barGroups=[],t.lineGroups=[],t.areaGroups=[],i.series.forEach(e=>{switch(e.type||i.chart.type){case"bar":case"column":t.barGroups.push(e.group);break;case"line":t.lineGroups.push(e.group);break;case"area":t.areaGroups.push(e.group)}}),t.barGroups=t.barGroups.filter((e,t,i)=>i.indexOf(e)===t),t.lineGroups=t.lineGroups.filter((e,t,i)=>i.indexOf(e)===t),t.areaGroups=t.areaGroups.filter((e,t,i)=>i.indexOf(e)===t),{minY:t.minY,maxY:t.maxY,minYArr:t.minYArr,maxYArr:t.maxYArr,yAxisScale:t.yAxisScale}}setXRange(){let e=this.w.globals,t=this.w.config,i="numeric"===t.xaxis.type||"datetime"===t.xaxis.type||"category"===t.xaxis.type&&!this.w.axisFlags.noLabelsProvided||this.w.axisFlags.noLabelsProvided||this.w.axisFlags.isXNumeric,s=()=>{for(let t=0;t<this.w.seriesData.series.length;t++)if(this.w.labelData.labels[t])for(let i=0;i<this.w.labelData.labels[t].length;i++)null!==this.w.labelData.labels[t][i]&&v.isNumber(this.w.labelData.labels[t][i])&&(e.maxX=Math.max(e.maxX,this.w.labelData.labels[t][i]),e.initialMaxX=Math.max(e.maxX,this.w.labelData.labels[t][i]),e.minX=Math.min(e.minX,this.w.labelData.labels[t][i]),e.initialMinX=Math.min(e.minX,this.w.labelData.labels[t][i]))};if(this.w.axisFlags.isXNumeric&&s(),this.w.axisFlags.noLabelsProvided&&0===t.xaxis.categories.length&&(e.maxX=this.w.labelData.labels[this.w.labelData.labels.length-1],e.initialMaxX=this.w.labelData.labels[this.w.labelData.labels.length-1],e.minX=1,e.initialMinX=1),this.w.axisFlags.isXNumeric||this.w.axisFlags.noLabelsProvided||this.w.axisFlags.dataFormatXNumeric){let s=10;if(void 0===t.xaxis.tickAmount)s=Math.round(e.svgWidth/150),"numeric"===t.xaxis.type&&e.dataPoints<30&&(s=e.dataPoints-1),s>e.dataPoints&&0!==e.dataPoints&&(s=e.dataPoints-1);else if("dataPoints"===t.xaxis.tickAmount){if(this.w.seriesData.series.length>1&&(s=this.w.seriesData.series[e.maxValsInArrayIndex].length-1),this.w.axisFlags.isXNumeric){let t=Math.round(e.maxX-e.minX);t<30&&(s=t)}}else s=t.xaxis.tickAmount;if(e.xTickAmount=s,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&&!this.w.axisFlags.dataFormatXNumeric){let t=[];for(let i=e.minX-1;i<e.maxX;i++)t.push(i+1);e.xAxisScale={result:t,niceMin:t[0],niceMax:t[t.length-1]}}else e.xAxisScale=this.scales.setXScale(e.minX,e.maxX);else e.xAxisScale=this.scales.linearScale(0,s,s,0,t.xaxis.stepSize),this.w.axisFlags.noLabelsProvi
27ded&&this.w.labelData.labels.length>0&&(e.xAxisScale=this.scales.linearScale(1,this.w.labelData.labels.length,s-1,0,t.xaxis.stepSize),this.w.seriesData.seriesX=this.w.labelData.labels.slice());i&&(this.w.labelData.labels=e.xAxisScale.result.slice())}return e.isBarHorizontal&&this.w.labelData.labels.length&&(e.xTickAmount=this.w.labelData.labels.length),this._handleSingleDataPoint(),this._getMinXDiff(),{minX:e.minX,maxX:e.maxX}}setZRange(){let e=this.w.globals;if(this.w.axisFlags.isDataXYZ){for(let t=0;t<this.w.seriesData.series.length;t++)if(void 0!==this.w.seriesData.seriesZ[t])for(let i=0;i<this.w.seriesData.seriesZ[t].length;i++)null!==this.w.seriesData.seriesZ[t][i]&&v.isNumber(this.w.seriesData.seriesZ[t][i])&&(e.maxZ=Math.max(e.maxZ,this.w.seriesData.seriesZ[t][i]),e.minZ=Math.min(e.minZ,this.w.seriesData.seriesZ[t][i]))}}_handleSingleDataPoint(){let e=this.w.globals,t=this.w.config;if(e.minX===e.maxX){let i=new A(this.w);if("datetime"===t.xaxis.type){let s=i.getDate(e.minX);t.xaxis.labels.datetimeUTC?s.setUTCDate(s.getUTCDate()-2):s.setDate(s.getDate()-2),e.minX=new Date(s).getTime();let a=i.getDate(e.maxX);t.xaxis.labels.datetimeUTC?a.setUTCDate(a.getUTCDate()+2):a.setDate(a.getDate()+2),e.maxX=new Date(a).getTime()}else"numeric"!==t.xaxis.type&&("category"!==t.xaxis.type||this.w.axisFlags.noLabelsProvided)||(e.minX=e.minX-2,e.initialMinX=e.minX,e.maxX=e.maxX+2,e.initialMaxX=e.maxX)}}_getMinXDiff(){let e=this.w.globals;this.w.axisFlags.isXNumeric&&this.w.seriesData.seriesX.forEach(t=>{if(t.length){1===t.length&&t.push(this.w.seriesData.seriesX[e.maxValsInArrayIndex][this.w.seriesData.seriesX[e.maxValsInArrayIndex].length-1]);let i=t.slice();i.sort((e,t)=>e-t),i.forEach((t,s)=>{if(s>0){let a=t-i[s-1];a>0&&(e.minXDiff=Math.min(a,e.minXDiff))}}),(1===e.dataPoints||e.minXDiff===Number.MAX_VALUE)&&(e.minXDiff=.5)}})}_setStackedMinMax(){let e=this.w.globals;if(!this.w.seriesData.series.length)return;let t=this.w.labelData.seriesGroups;t.length||(t=[this.w.seriesData.seriesNames.map(e=>e)]);let i={},s={};t.forEach(t=>{i[t]=[],s[t]=[],this.w.config.series.map((e,i)=>t.indexOf(this.w.seriesData.seriesNames[i])>-1?i:null).filter(e=>null!==e).forEach(a=>{var r,l,o,n;for(let h=0;h<this.w.seriesData.series[e.maxValsInArrayIndex].length;h++)void 0===i[t][h]&&(i[t][h]=0,s[t][h]=0),(this.w.config.chart.stacked&&!e.comboCharts||this.w.config.chart.stacked&&e.comboCharts&&(!this.w.config.chart.stackOnlyBar||(null==(l=null==(r=this.w.config.series)?void 0:r[a])?void 0:l.type)==="bar"||(null==(n=null==(o=this.w.config.series)?void 0:o[a])?void 0:n.type)==="column"))&&null!==this.w.seriesData.series[a][h]&&v.isNumber(this.w.seriesData.series[a][h])&&(this.w.seriesData.series[a][h]>0?i[t][h]+=parseFloat(String(this.w.seriesData.series[a][h]))+1e-4:s[t][h]+=parseFloat(String(this.w.seriesData.series[a][h])))})}),Object.entries(i).forEach(([t])=>{i[t].forEach((a,r)=>{e.maxY=Math.max(e.maxY,i[t][r]),e.minY=Math.min(e.minY,s[t][r])})})}}function J(){return{palette1:["#008FFB","#00E396","#FEB019","#FF4560","#775DD0"],palette2:["#3F51B5","#03A9F4","#4CAF50","#F9CE1D","#FF9800"],palette3:["#33B2DF","#546E7A","#D4526E","#13D8AA","#A5978B"],palette4:["#4ECDC4","#C7F464","#81D4FA","#FD6A6A","#546E7A"],palette5:["#2B908F","#F9A3A4","#90EE7E","#FA4443","#69D2E7"],palette6:["#449DD1","#F86624","#EA3546","#662E9B","#C5D86D"],palette7:["#D7263D","#1B998B","#2E294E","#F46036","#E2C044"],palette8:["#662E9B","#F86624","#F9C80E","#EA3546","#43BCCD"],palette9:["#5C4742","#A5978B","#8D5B4C","#5A2A27","#C4BBAF"],palette10:["#A300D6","#7D02EB","#5653FE","#2983FF","#00B1F2"],cvdDeuteranopia:["#0072B2","#E69F00","#56B4E9","#009E73","#F0E442","#D55E00","#CC79A7"],cvdProtanopia:["#0077BB","#EE7733","#009988","#EE3377","#BBBBBB","#33BBEE","#CC3311"],cvdTritanopia:["#CC3311","#009988","#EE7733","#0077BB","#EE3377","#BBBBBB","#33BBEE"],highContrast:["#005A9C","#C00000","#007A33","#6C3483","#7B3F00","#0097A7","#4A235A"]}}class Q{constructor(e,{theme:t=null,timeScale:i=null}={},s){this.w=e,this.elgrid=s,this.xaxisFontSize=e.config.xaxis.labels.style.fontSize,this.axisFontFamily=e.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=e.config.xaxis.labels.style.colors,this.isCategoryBarHorizontal="bar"===e.config.chart.type&&e.config.plotOptions.bar.horizontal,this.xAxisoffX="bottom"===e.config.xaxis.position?e.layout.gridHeight:0,this.drawnLabels=[],this.axesUtils=new j(e,{theme:t,timeScale:i})}drawYaxis(e){let t=this.w,i=new Y(this.w),s=t.config.yaxis[e].labels.style,{fontSize:a,fontFamily:r,fontWeight:l}=s,o=i.group({class:"apexcharts-yaxis",rel:e,transform:`translate(${t.globals.translateYAxisX[e]}, 0)`});if(this.axesUtils.isYAxisHidden(e))return o;let n=i.group({class:"apexcharts-yaxis-texts-g"});o.add(n);let h=t.globals.yAxisScale[e].result.length-1,d=t.layout.gridHeight/h,c=t.formatters.yLabelFormatters[e],g=this.axesUtils.checkForRever
27sedLabels(e,t.globals.yAxisScale[e].result.slice());if(t.config.yaxis[e].labels.show){let o=t.layout.translateY+t.config.yaxis[e].labels.offsetY;t.globals.isBarHorizontal?o=0:"heatmap"===t.config.chart.type&&(o-=d/2),o+=parseInt(a,10)/3;let p=null;for(let x=h;x>=0;x--){let h=c(g[x],x,t),u=t.config.yaxis[e].labels.padding;t.config.yaxis[e].opposite&&0!==t.config.yaxis.length&&(u*=-1);let f=this.getTextAnchor(t.config.yaxis[e].labels.align,t.config.yaxis[e].opposite),m=this.axesUtils.getYAxisForeColor(s.colors,e),b=Array.isArray(m)?m[x]:m,y=Array.from(t.dom.baseEl.querySelectorAll(`.apexcharts-yaxis[rel='${e}'] .apexcharts-yaxis-label tspan`)).map(e=>e.textContent),w=i.drawText({x:u,y:o,text:y.includes(h)&&!t.config.yaxis[e].labels.showDuplicates?"":h,textAnchor:f,fontSize:a,fontFamily:r,fontWeight:l,maxWidth:t.config.yaxis[e].labels.maxWidth,foreColor:b,isPlainText:!1,cssClass:`apexcharts-yaxis-label ${s.cssClass}`});n.add(w),this.addTooltip(w,h),null===p&&(p=w),0!==t.config.yaxis[e].labels.rotate&&this.rotateLabel(i,w,p,t.config.yaxis[e].labels.rotate),o+=d}}return this.addYAxisTitle(i,o,e),this.addAxisBorder(i,o,e,h,d),o}getTextAnchor(e,t){return"left"===e?"start":"center"===e?"middle":"right"===e?"end":t?"start":"end"}addTooltip(e,t){let i=w.createElementNS(B,"title");i.textContent=Array.isArray(t)?t.join(" "):t,e.node.appendChild(i)}rotateLabel(e,t,i,s){let a=e.rotateAroundCenter(i.node),r=e.rotateAroundCenter(t.node);t.node.setAttribute("transform",`rotate(${s} ${a.x} ${r.y})`)}addYAxisTitle(e,t,i){let s=this.w;if(void 0!==s.config.yaxis[i].title.text){let a=e.group({class:"apexcharts-yaxis-title"}),r=s.config.yaxis[i].opposite?s.globals.translateYAxisX[i]:0,l=e.drawText({x:r,y:s.layout.gridHeight/2+s.layout.translateY+s.config.yaxis[i].title.offsetY,text:s.config.yaxis[i].title.text,textAnchor:"end",foreColor:s.config.yaxis[i].title.style.color,fontSize:s.config.yaxis[i].title.style.fontSize,fontWeight:s.config.yaxis[i].title.style.fontWeight,fontFamily:s.config.yaxis[i].title.style.fontFamily,cssClass:`apexcharts-yaxis-title-text ${s.config.yaxis[i].title.style.cssClass}`});a.add(l),t.add(a)}}addAxisBorder(e,t,i,s,a){let r=this.w,l=r.config.yaxis[i].axisBorder,o=31+l.offsetX;if(r.config.yaxis[i].opposite&&(o=-31-l.offsetX),l.show){let i=e.drawLine(o,r.layout.translateY+l.offsetY-2,o,r.layout.gridHeight+r.layout.translateY+l.offsetY+2,l.color,0,l.width);t.add(i)}r.config.yaxis[i].axisTicks.show&&this.axesUtils.drawYAxisTicks(o,s,l,r.config.yaxis[i].axisTicks,i,a,t)}drawYaxisInversed(e){let t=this.w,i=new Y(this.w),s=i.group({class:"apexcharts-xaxis apexcharts-yaxis-inversed"}),a=i.group({class:"apexcharts-xaxis-texts-g",transform:`translate(${t.layout.translateXAxisX}, ${t.layout.translateXAxisY})`});s.add(a);let r=t.globals.yAxisScale[e].result.length-1,l=t.layout.gridWidth/r+.1,o=l+t.config.xaxis.labels.offsetX,n=t.formatters.xLabelFormatter,h=this.axesUtils.checkForReversedLabels(e,t.globals.yAxisScale[e].result.slice()),d=t.labelData.timescaleLabels;if(d.length>0&&(this.xaxisLabels=d.slice(),r=(h=d.slice()).length),t.config.xaxis.labels.show)for(let s=d.length?0:r;d.length?s<d.length:s>=0;d.length?s++:s--){let r=null==n?void 0:n(h[s],s,t),c=t.layout.gridWidth+t.globals.padHorizontal-(o-l+t.config.xaxis.labels.offsetX);if(d.length){let e=this.axesUtils.getLabel(h,d,c,s,this.drawnLabels,this.xaxisFontSize);c=e.x,r=e.text,this.drawnLabels.push(e.text),0===s&&t.globals.skipFirstTimelinelabel&&(r=""),s===h.length-1&&t.globals.skipLastTimelinelabel&&(r="")}let g=i.drawText({x:c,y:this.xAxisoffX+t.config.xaxis.labels.offsetY+30-("top"===t.config.xaxis.position?t.layout.xAxisHeight+t.config.xaxis.axisTicks.height-2:0),text:r,textAnchor:"middle",foreColor:Array.isArray(this.xaxisForeColors)?this.xaxisForeColors[e]:this.xaxisForeColors,fontSize:this.xaxisFontSize,fontFamily:this.axisFontFamily,fontWeight:t.config.xaxis.labels.style.fontWeight,isPlainText:!1,cssClass:`apexcharts-xaxis-label ${t.config.xaxis.labels.style.cssClass}`});a.add(g),this.addTooltip(g,r),o+=l}return this.inversedYAxisTitleText(s),this.inversedYAxisBorder(s),s}inversedYAxisBorder(e){let t=this.w,i=new Y(this.w),s=t.config.xaxis.axisBorder;if(s.show){let a=0;"bar"===t.config.chart.type&&t.axisFlags.isXNumeric&&(a-=15);let r=i.drawLine(t.globals.padHorizontal+a+s.offsetX,this.xAxisoffX,t.layout.gridWidth,this.xAxisoffX,s.color,0,s.height);this.elgrid&&this.elgrid.elGridBorders&&t.config.grid.show?this.elgrid.elGridBorders.add(r):e.add(r)}}inversedYAxisTitleText(e){let t=this.w,i=new Y(this.w);if(void 0!==t.config.xaxis.title.text){let s=i.group({class:"apexcharts-xaxis-title apexcharts-yaxis-title-inversed"}),a=i.drawText({x:t.layout.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}`});s.add(a),e.add(s)}}yAxisTitleRotate(e,t){let i=this.w,s=new Y(this.w),a=i.dom.baseEl.querySelector(`.apexcharts-yaxis[rel='${e}'] .apexcharts-yaxis-texts-g`),r=a?a.getBoundingClientRect():{width:0,height:0},l=i.dom.baseEl.querySelector(`.apexcharts-yaxis[rel='${e}'] .apexcharts-yaxis-title text`),o=l?l.getBoundingClientRect():{width:0,height:0};if(l){let a=this.xPaddingForYAxisTitle(e,r,o,t);l.setAttribute("x",String(a.xPos-10*!!t));
27let n=s.rotateAroundCenter(l);l.setAttribute("transform",`rotate(${t?-1*i.config.yaxis[e].title.rotate:i.config.yaxis[e].title.rotate} ${n.x} ${n.y})`)}}xPaddingForYAxisTitle(e,t,i,s){let a=this.w,r=0,l=10;return void 0===a.config.yaxis[e].title.text||e<0?{xPos:r,padd:0}:(s?r=t.width+a.config.yaxis[e].title.offsetX+i.width/2+l/2:(r=-1*t.width+a.config.yaxis[e].title.offsetX+l/2+i.width/2,a.globals.isBarHorizontal&&(l=25,r=-1*t.width-a.config.yaxis[e].title.offsetX-l)),{xPos:r,padd:l})}setYAxisXPosition(e,t){let i=this.w,s=0,a=0,r=18,l=1;i.config.yaxis.length>1&&(this.multipleYs=!0),i.config.yaxis.forEach((o,n)=>{let h=i.globals.ignoreYAxisIndexes.includes(n)||!o.show||o.floating||0===e[n].width,d=e[n].width+t[n].width;o.opposite?i.globals.isBarHorizontal?(a=i.layout.gridWidth+i.layout.translateX-1,i.globals.translateYAxisX[n]=a-o.labels.offsetX):(a=i.layout.gridWidth+i.layout.translateX+l,h||(l+=d+20),i.globals.translateYAxisX[n]=a-o.labels.offsetX+20):(s=i.layout.translateX-r,h||(r+=d+20),i.globals.translateYAxisX[n]=s+o.labels.offsetX)})}setYAxisTextAlignments(){let e=this.w;Array.from(e.dom.baseEl.getElementsByClassName("apexcharts-yaxis")).forEach((t,i)=>{let s=e.config.yaxis[i];if(s&&!s.floating&&void 0!==s.labels.align){let t=e.dom.baseEl.querySelector(`.apexcharts-yaxis[rel='${i}'] .apexcharts-yaxis-texts-g`),a=Array.from(e.dom.baseEl.querySelectorAll(`.apexcharts-yaxis[rel='${i}'] .apexcharts-yaxis-label`)),r=t.getBoundingClientRect();a.forEach(e=>{e.setAttribute("text-anchor",s.labels.align)}),"left"!==s.labels.align||s.opposite?"center"===s.labels.align?t.setAttribute("transform",`translate(${r.width/2*(!s.opposite?-1:1)}, 0)`):"right"===s.labels.align&&s.opposite&&t.setAttribute("transform",`translate(${r.width}, 0)`):t.setAttribute("transform",`translate(-${r.width}, 0)`)}})}}class ee{constructor(e,t){this.w=e,this.ctx=t,this.documentEvent=this.documentEvent.bind(this)}addEventListener(e,t){let i=this.w;Object.prototype.hasOwnProperty.call(i.globals.events,e)?i.globals.events[e].push(t):i.globals.events[e]=[t]}removeEventListener(e,t){let i=this.w;if(!Object.prototype.hasOwnProperty.call(i.globals.events,e))return;let s=i.globals.events[e].indexOf(t);-1!==s&&i.globals.events[e].splice(s,1)}fireEvent(e,t){let i=this.w;if(!Object.prototype.hasOwnProperty.call(i.globals.events,e))return;t&&t.length||(t=[]);let s=i.globals.events[e],a=s.length;for(let e=0;e<a;e++)s[e].apply(null,t)}setupEventHandlers(){let e=this.w,t=this.ctx,i=e.dom.baseEl.querySelector(e.globals.chartClass);this.ctx.eventList.forEach(s=>{null==i||i.addEventListener(s,i=>{let s=null===i.target.getAttribute("i")&&-1!==e.interact.capturedSeriesIndex?e.interact.capturedSeriesIndex:i.target.getAttribute("i"),a=null===i.target.getAttribute("j")&&-1!==e.interact.capturedDataPointIndex?e.interact.capturedDataPointIndex:i.target.getAttribute("j"),r=Object.assign({},e,{seriesIndex:e.globals.axisCharts?s:0,dataPointIndex:a});"keydown"===i.type?e.config.chart.accessibility.enabled&&e.config.chart.accessibility.keyboard.enabled&&(t.ctx.keyboardNavigation&&t.ctx.keyboardNavigation.handleKey(i),"function"==typeof e.config.chart.events.keyDown&&e.config.chart.events.keyDown(i,t,r),t.ctx.events.fireEvent("keydown",[i,t,r])):"keyup"===i.t
27ype?e.config.chart.accessibility.enabled&&e.config.chart.accessibility.keyboard.enabled&&("function"==typeof e.config.chart.events.keyUp&&e.config.chart.events.keyUp(i,t,r),t.ctx.events.fireEvent("keyup",[i,t,r])):"mousemove"===i.type||"touchmove"===i.type?"function"==typeof e.config.chart.events.mouseMove&&e.config.chart.events.mouseMove(i,t,r):"mouseleave"===i.type||"touchleave"===i.type?"function"==typeof e.config.chart.events.mouseLeave&&e.config.chart.events.mouseLeave(i,t,r):("mouseup"===i.type&&1===i.which||"touchend"===i.type)&&("function"==typeof e.config.chart.events.click&&e.config.chart.events.click(i,t,r),t.ctx.events.fireEvent("click",[i,t,r]))},{capture:!1,passive:!0})}),this.ctx.eventList.forEach(t=>{e.dom.baseEl.addEventListener(t,this.documentEvent,{passive:!0})}),this.ctx.core.setupBrushHandler()}documentEvent(e){let t=this.w,i=e.target.className;if("click"===e.type){let e=t.dom.baseEl.querySelector(".apexcharts-menu");e&&e.classList.contains("apexcharts-menu-open")&&"apexcharts-menu-icon"!==i&&e.classList.remove("apexcharts-menu-open")}t.interact.clientX="touchmove"===e.type?e.touches[0].clientX:e.clientX,t.interact.clientY="touchmove"===e.type?e.touches[0].clientY:e.clientY}}class et{constructor(e){this.w=e}setCurrentLocaleValues(e){let t=this.w.config.chart.locales,i=p.getApex();i.chart&&i.chart.locales&&i.chart.locales.length>0&&(t=this.w.config.chart.locales.concat(i.chart.locales));let s=t.filter(t=>t.name===e)[0];if(s){let e=v.extend(L,s);this.w.globals.locale=e.options}else throw Error("Wrong locale name provided. Please make sure you set the correct locale name in options")}}class ei{constructor(e,t){this.w=e,this.ctx=t}drawAxis(e,t){let i=this.w.globals,s=this.w.config,a=new U(this.w,this.ctx,t),r=new Q(this.w,{theme:this.ctx.theme,timeScale:this.ctx.timeScale},t);if(i.axisCharts&&"radar"!==e){let e,t;i.isBarHorizontal?(t=r.drawYaxisInversed(0),e=a.drawXaxisInversed(0),this.w.dom.elGraphical.add(e),this.w.dom.elGraphical.add(t)):(e=a.drawXaxis(),this.w.dom.elGraphical.add(e),s.yaxis.map((e,s)=>{if(-1===i.ignoreYAxisIndexes.indexOf(s)&&(t=r.drawYaxis(s),this.w.dom.Paper.add(t),"back"===this.w.config.grid.position)){let e=this.w.dom.Paper.children()[1];e&&(e.remove(),this.w.dom.Paper.add(e))}}))}}}class es{constructor(e){this.w=e}drawXCrosshairs(){let e=this.w,t=new Y(this.w),i=new z(this.w),s=e.config.xaxis.crosshairs.fill.gradient,a=e.config.xaxis.crosshairs.dropShadow,r=e.config.xaxis.crosshairs.fill.type,l=s.colorFrom,o=s.colorTo,n=s.opacityFrom,h=s.opacityTo,d=s.stops,c=a.enabled,g=a.left,p=a.top,x=a.blur,u=a.color,f=a.opacity,m=e.config.xaxis.crosshairs.fill.color;if(e.config.xaxis.crosshairs.show){"gradient"===r&&(m=t.drawGradient("vertical",l,o,n,h,null,d,[]));let s=t.drawRect();1===e.config.xaxis.crosshairs.width&&(s=t.drawLine(0,0,0,0));let a=e.layout.gridHeight;(!v.isNumber(a)||a<0)&&(a=0);let b=e.config.xaxis.crosshairs.width;(!v.isNumber(b)||0>Number(b))&&(b=0),s.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:a,width:b,height:a,fill:m,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}),c&&(s=i.dropShadow(s,{left:g,top:p,blur:x,color:u,opacity:f})),e.dom.elGraphical.add(s)}}drawYCrosshairs(){let e=this.w,t=new Y(this.w),i=e.config.yaxis[0].crosshairs,s=e.globals.barPadForNumericAxis;if(e.config.yaxis[0].crosshairs.show){let a=t.drawLine(-s,0,e.layout.gridWidth+s,0,i.stroke.color,
27i.stroke.dashArray,i.stroke.width);a.attr({class:"apexcharts-ycrosshairs"}),e.dom.elGraphical.add(a)}let a=t.drawLine(-s,0,e.layout.gridWidth+s,0,i.stroke.color,0,0);a.attr({class:"apexcharts-ycrosshairs-hidden"}),e.dom.elGraphical.add(a)}}class ea{constructor(e){this.w=e,this._activeBreakpoint=null}checkResponsiveConfig(e){let t=this.w,i=t.config;if(0===i.responsive.length)return;let s=i.responsive.slice();s.sort((e,t)=>e.breakpoint>t.breakpoint?1:t.breakpoint>e.breakpoint?-1:0).reverse();let a=new P({}),r=(e={})=>{let i=s[0].breakpoint,r=p.isBrowser()?window.innerWidth>0?window.innerWidth:screen.width:0;if(r>i){if(null!==this._activeBreakpoint){if(!t.globals.initialConfig)return;let i=v.clone(t.globals.initialConfig);i.series=v.clone(t.config.series);let s=I.extendArrayProps(a,i,t);e=v.extend(s,e),this.overrideResponsiveOptions(e),this._activeBreakpoint=null}}else for(let i=0;i<s.length;i++)r<s[i].breakpoint&&(e=I.extendArrayProps(a,s[i].options,t),e=v.extend(t.config,e),this.overrideResponsiveOptions(e),this._activeBreakpoint=s[i].breakpoint)};if(e){let i=I.extendArrayProps(a,e,t);i=v.extend(t.config,i),r(i=v.extend(i,e))}else r({})}overrideResponsiveOptions(e){let t=new P(e).init({responsiveOverride:!0});this.w.config=t}}class er{constructor(e,{toggleDataSeries:t,revertDefaultAxisMinMax:i,updateSeries:s}={}){this.w=e,this._toggleDataSeries=t||null,this._revertDefaultAxisMinMax=i||null,this._updateSeries=s||null,this.legendInactiveClass="legend-mouseover-inactive"}clearSeriesCache(){let e=this.w;e.globals.cachedSelectors&&(delete e.globals.cachedSelectors.allSeriesEls,delete e.globals.cachedSelectors.highlightSeriesEls)}getAllSeriesEls(){let e=this.w,t="allSeriesEls";return e.globals.cachedSelectors[t]||(e.globals.cachedSelectors[t]=e.dom.baseEl.getElementsByClassName("apexcharts-series")),e.globals.cachedSelectors[t]}getSeriesByName(e){return this.w.dom.baseEl.querySelector(`.apexcharts-inner .apexcharts-series[seriesName='${v.escapeString(e)}']`)}isSeriesHidden(e){var t;let i=this.getSeriesByName(e),s=parseInt(null!=(t=i.getAttribute("data:realIndex"))?t:"0",10);return{isHidden:i.classList.contains("apexcharts-series-collapsed"),realIndex:s}}addCollapsedClassToSeries(e,t){er.addCollapsedClassToSeries(this.w,e,t)}static addCollapsedClassToSeries(e,t,i){function s(e){for(let s=0;s<e.length;s++)e[s].index===i&&t.node.classList.add("apexcharts-series-collapsed")}s(e.globals.collapsedSeries),s(e.globals.ancillaryCollapsedSeries)}toggleSeries(e){var t;let i=this.isSeriesHidden(e);return null==(t=this._toggleDataSeries)||t.call(this,i.realIndex,i.isHidden),i.isHidden}showSeries(e){var t;let i=this.isSeriesHidden(e);i.isHidden&&(null==(t=this._toggleDataSeries)||t.call(this,i.realIndex,!0))}hideSeries(e){var t;let i=this.isSeriesHidden(e);i.isHidden||null==(t=this._toggleDataSeries)||t.call(this,i.realIndex,!1)}resetSeries(e=!0,t=!0,i=!0){var s,a;let r=this.w;this.clearSeriesCache();let l=v.clone(r.globals.initialSeries);r.globals.previousPaths=[],i?(r.globals.collapsedSeries=[],r.globals.ancillaryCollapsedSeries=[],r.globals.collapsedSeriesIndices=[],r.globals.ancillaryCollapsedSeriesIndices=[]):l=this.emptyCollapsedSeries(l),r.config.series=l,e&&(t&&(r.interact.zoomed=!1,null==(s=this._revertDefaultAxisMinMax)||s.call(this)),null==(a=this._updateSeries)||a.call(this,l,r.config.chart.animations.dynamicAnimation.enabled))}emptyCollapsedSeries(e){let t=this.w;for(let i=0;i<e.length;i++)t.globals.collapsedSeriesIndices.indexOf(i)>-1&&(e[i].data=[]);return e}highlightSeries(e){var t;let i=this.w,s=this.getSeriesByName(e),a=parseInt(null!=(t=null==s?void 0:s.getAttribute("data:realIndex"))?t:"",10),r="highlightSeriesEls",l=i.globals.cachedSelectors[r];l||(l=i.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels, .apexcharts-yaxis"),i.globals.cachedSelectors[r]=l);let o=null,n=null,h=null;if(i.globals.axisCharts||"radialBar"===i.config.chart.type)if(i.globals.axisCharts){o=i.dom.baseEl.querySelector(`.apexcharts-series[data\\:realIndex='${a}']`),n=i.dom.baseEl.querySelector(`.apexcharts-datalabels[data\\:realIndex='${a}']`);let e=i.globals.seriesYAxisReverseMap[a];h=i.dom.baseEl.querySelector(`.apexcharts-yaxis[rel='${e}']`)}else o=i.dom.baseEl.querySelector(`.apexcharts-series[rel='${a+1}']`);else o=i.dom.baseEl.querySelector(`.apexcharts-series[rel='${a+1}'] path`);for(let e=0;e<l.length;e++)l[e].classList.add(this.legendInactiveClass);if(o){if(!i.globals.axisCharts){let e=o.parentNode;null==e||e.classList.remove(this.legendInactiveClass)}o.classList.remove(this.legendInactiveClass),null!==n&&n.classList.remove(this.legendInactiveClass),null!==h&&h.classList.remove(this.legendInactiveClass)}else for(let e=0;e<l.length;e++)l[e].classList.remove(this.legendInactiveClass)}toggleSeriesOnHover(e,t){let i=this.w;t||(t=e.target);let s=i.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels, .apexcharts-yaxis");
27if("mousemove"===e.type){let e=parseInt(t.getAttribute("rel"),10)-1;this.highlightSeries(i.seriesData.seriesNames[e])}else if("mouseout"===e.type)for(let e=0;e<s.length;e++)s[e].classList.remove(this.legendInactiveClass)}highlightRangeInSeries(e,t){let i=this.w,s=i.dom.baseEl.getElementsByClassName("apexcharts-heatmap-rect"),a=e=>{for(let t=0;t<s.length;t++){let i=s[t].classList[e];"function"==typeof i&&i.call(s[t].classList,this.legendInactiveClass)}},r=(e,t)=>{for(let i=0;i<s.length;i++){let a=Number(s[i].getAttribute("val"));a>=e.from&&(a<e.to||e.to===t&&a===t)&&s[i].classList.remove(this.legendInactiveClass)}};if("mousemove"===e.type){let e=parseInt(t.getAttribute("rel"),10)-1;a("add");let s=i.config.plotOptions.heatmap.colorScale.ranges;r(s[e],s.reduce((e,t)=>Math.max(e,t.to),0))}else"mouseout"===e.type&&a("remove")}getActiveConfigSeriesIndex(e="asc",t=[]){let i=this.w,s=0;if(i.config.series.length>1){let a=i.config.series.map((e,s)=>e.data&&e.data.length>0&&-1===i.globals.collapsedSeriesIndices.indexOf(s)&&(!i.globals.comboCharts||0===t.length||t.length&&t.indexOf(i.config.series[s].type)>-1)?s:-1);for(let t="asc"===e?0:a.length-1;"asc"===e?t<a.length:t>=0;"asc"===e?t++:t--)if(-1!==a[t]){s=a[t];break}}return s}getBarSeriesIndices(){return this.w.globals.comboCharts?this.w.config.series.map((e,t)=>"bar"===e.type||"column"===e.type?t:-1).filter(e=>-1!==e):this.w.config.series.map((e,t)=>t)}getPreviousPaths(){var e,t,i,s;let a=this.w;a.globals.previousPaths=[],["line","area","bar","rangebar","rangeArea","candlestick","radar"].forEach(e=>{let t=a.dom.baseEl.querySelectorAll(`.apexcharts-${e}-series .apexcharts-series`);for(let i=0;i<t.length;i++)!function(e,t,i){let s=e[t].childNodes,r={type:i,paths:[],realIndex:e[t].getAttribute("data:realIndex")};for(let e=0;e<s.length;e++)if(s[e].hasAttribute("pathTo")){let t=s[e].getAttribute("pathTo");r.paths.push({d:t})}a.globals.previousPaths.push(r)}(t,i,e)});let r=a.dom.baseEl.querySelectorAll(`.apexcharts-${a.config.chart.type} .apexcharts-series`);if(r.length>0)for(let l=0;l<r.length;l++){let r=a.dom.baseEl.querySelectorAll(`.apexcharts-${a.config.chart.type} .apexcharts-series[data\\:realIndex='${l}'] rect`),o=[];for(let a=0;a<r.length;a++){let l=e=>r[a].getAttribute(e),n={x:parseFloat(null!=(e=l("x"))?e:"0"),y:parseFloat(null!=(t=l("y"))?t:"0"),width:parseFloat(null!=(i=l("width"))?i:"0"),height:parseFloat(null!=(s=l("height"))?s:"0")};o.push({rect:n,color:r[a].getAttribute("color")})}a.globals.previousPaths.push(o)}a.globals.axisCharts||(a.globals.previousPaths=a.seriesData.series)}clearPreviousPaths(){let e=this.w;e.globals.previousPaths=[],e.globals.allSeriesCollapsed=!1}handleNoData(){let e=this.w,t=e.config.noData,i=new Y(this.w),s=e.globals.svgWidth/2,a=e.globals.svgHeight/2,r="middle";if(e.globals.noData=!0,e.globals.animationEnded=!0,"left"===t.align?(s=10,r="start"):"right"===t.align&&(s=e.globals.svgWidth-10,r="end"),"top"===t.verticalAlign?a=50:"bottom"===t.verticalAlign&&(a=e.globals.svgHeight-50),s+=t.offsetX,a=a+parseInt(t.style.fontSize,10)+2+t.offsetY,void 0!==t.text&&""!==t.text){let l=i.drawText({x:s,y:a,text:t.text,textAnchor:r,fontSize:t.style.fontSize,fontFamily:t.style.fontFamily,foreColor:t.style.color,opacity:1,cssClass:"apexcharts-text-nodata"});e.dom.Paper.add(l)}}setNullSeriesToZeroValues(e){let t=this.w;for(let i=0;i<e.length;i++)if(0===e[i].length)for(let s=0;s<e[t.globals.maxValsInArrayIndex].length;s++)e[i].push(0);return e}hasAllSeriesEqualX(){let e=!0,t=this.w,i=this.filteredSeriesX();for(let t=0;t<i.length-1;t++)if(i[t][0]!==i[t+1][0]){e=!1;break}return t.globals.allSeriesHasEqualX=e,e}filteredSeriesX(){return this.w.seriesData.seriesX.map(e=>e.length>0?e:[])}}class el{constructor(e){this.w=e,this.colors=[],this.isColorFn=!1,this.isHeatmapDistributed=this.checkHeatmapDistributed(),this.isBarDistributed=this.checkBarDistributed()}checkHeatmapDistributed(){let{chart:e,plotOptions:t}=this.w.config;return"treemap"===e.type&&t.treemap&&t.treemap.distributed||"heatmap"===e.type&&t.heatmap&&t.heatmap.distributed}checkBarDistributed(){let{chart:e,plotOptions:t}=this.w.config;return t.bar&&t.bar.distributed&&("bar"===e.type||"rangeBar"===e.type)}init(){this.setDefaultColors()}setDefaultColors(){var e;let t=this.w,i=new v;t.dom.elWrap.classList.add(`apexcharts-theme-${t.config.theme.mode||"light"}`);let s=null==(e=t.config.theme.accessibility)?void 0:e.colorBlindMode;if(s){t.globals.colors=this.getColorBlindColors(s),this.applySeriesColors(t.seriesData.seriesColors,t.globals.colors);let e=t.globals.colors.slice();this.pushExtraColors(t.globals.colors),this.applyColorTypes(["fill","stroke"],e),this.applyDataLabelsColors(e),this.applyRadarPolygonsColors(),this.applyMarkersColors(e),"highContrast"===s&&t.dom.elWrap.classList.add("apexcharts-high-contrast");return}let a=[...t.config.colors||t.config.fill.colors||[]];t.globals.colors=this.getColors(a),this.applySeriesColors(t.seriesData.seriesColors,t.globals.colors),t.config.theme.monochrome.enabled&&(t.globals.colors=this.getMonochromeColors(t.config.theme.monochrome,t.seriesData.series,i));let r=t.globals.colors.slice();this.pushExtraColors(t.globals.colors),this.applyColorTypes(["fill","stroke"],r),this.applyDataLabelsColors(r),this.applyRadarPolygonsColors(),this.applyMarkersColors(r)}getColors(e){let t=this.w;return e&&0!==e.length?Array.isArray(e)&&e.length>0&&"function"==typeof e[0]?(this.isColorFn=!0,t.config.series.map((i,s)=>{let a=e[s]||e[0];return"function"==typeof a?a({value:t.globals.axisCharts?t.seriesData.series[s][0]||0:t.seriesData.series[s],seriesIndex:s,dataPointIndex:s,w:this.w}):a})):e:this.predefined()}applySeriesColors(e,t){e.forEach((e,i)=>{e&&(t[i]=e)})}getMonochromeColors(e,t,i){let{color:s,shadeIntensity:a,shadeTo:r}=e,l=this.isBarDistributed||this.isHeatmapDistributed?t[0].length*t.length:t.length,o=1/(l/a),n=0;return Array.from({length:l},()=>{let e="dark"===r?i.shadeColor(-1*n,s):i.shadeColor(n,s);return n+=o,e})}applyColorTypes(e,t){let i=this.w;
27e.forEach(e=>{i.globals[e].colors=void 0===i.config[e].colors?this.isColorFn?i.config.colors:t:i.config[e].colors.slice(),this.pushExtraColors(i.globals[e].colors)})}applyDataLabelsColors(e){let t=this.w;t.globals.dataLabels.style.colors=void 0===t.config.dataLabels.style.colors?e:t.config.dataLabels.style.colors.slice(),this.pushExtraColors(t.globals.dataLabels.style.colors,50)}applyRadarPolygonsColors(){let e=this.w;e.globals.radarPolygons.fill.colors=void 0===e.config.plotOptions.radar.polygons.fill.colors?["dark"===e.config.theme.mode?"#343A3F":"none"]:e.config.plotOptions.radar.polygons.fill.colors.slice(),this.pushExtraColors(e.globals.radarPolygons.fill.colors,20)}applyMarkersColors(e){let t=this.w;t.globals.markers.colors=void 0===t.config.markers.colors?e:t.config.markers.colors.slice(),this.pushExtraColors(t.globals.markers.colors)}pushExtraColors(e,t,i=null){let s=this.w,a=t||s.seriesData.series.length;if(null===i&&(i=this.isBarDistributed||this.isHeatmapDistributed||"heatmap"===s.config.chart.type&&s.config.plotOptions.heatmap&&s.config.plotOptions.heatmap.colorScale.inverse),i&&s.seriesData.series.length&&(a=s.seriesData.series[s.globals.maxValsInArrayIndex].length*s.seriesData.series.length),e.length<a){let t=a-e.length;for(let i=0;i<t;i++)e.push(e[i])}}getColorBlindColors(e){let t=J();return(({deuteranopia:t.cvdDeuteranopia,protanopia:t.cvdProtanopia,tritanopia:t.cvdTritanopia,highContrast:t.highContrast})[e]||t.palette1).slice()}updateThemeOptions(e){e.chart=e.chart||{},e.tooltip=e.tooltip||{};let t=e.theme.mode,i="dark"===t?"palette4":"light"===t?"palette1":e.theme.palette||"palette1",s="dark"===t?"#f6f7f8":"light"===t?"#373d3f":e.chart.foreColor||"#373d3f";return e.tooltip.theme=t||"light",e.chart.foreColor=s,e.theme.palette=i,e}predefined(){let e=this.w.config.theme.palette,t=J();return t[e]||t.palette1}}class eo{constructor(e){this.w=e}draw(){this.drawTitleSubtitle("title"),this.drawTitleSubtitle("subtitle")}drawTitleSubtitle(e){let t=this.w,i="title"===e?t.config.title:t.config.subtitle,s=t.globals.svgWidth/2,a=i.offsetY,r="middle";if("left"===i.align?(s=10,r="start"):"right"===i.align&&(s=t.globals.svgWidth-10,r="end"),s+=i.offsetX,a=a+parseInt(i.style.fontSize,10)+i.margin/2,void 0!==i.text){let l=new Y(this.w).drawText({x:s,y:a,text:i.text,textAnchor:r,fontSize:i.style.fontSize,fontFamily:i.style.fontFamily,fontWeight:i.style.fontWeight,foreColor:i.style.color,opacity:1});l.node.setAttribute("class",`apexcharts-${e}-text`),t.dom.Paper.add(l)}}}let en=class{constructor(e){this.w=e.w,this.dCtx=e}getTitleSubtitleCoords(e){let t=this.w,i=0,s=0,a="title"===e?t.config.title.floating:t.config.subtitle.floating,r=t.dom.baseEl.querySelector(`.apexcharts-${e}-text`);if(null!==r&&!a){let e=r.getBoundingClientRect();i=e.width,s=t.globals.axisCharts?e.height+5:e.height}return{width:i,height:s}}getLegendsRect(){let e=this.w,t=e.dom.elLegendWrap;!e.config.legend.height&&("top"===e.config.legend.position||"bottom"===e.config.legend.position)&&t&&(t.style.maxHeight=e.globals.svgHeight/2+"px");let i=Object.assign({},v.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}getDatalabelsRect(){let e=this.w,t=[];e.config.series.forEach((i,s)=>{i.data.forEach((i,a)=>{let r,l=(r=e.seriesData.series[s][a],e.config.dataLabels.formatter(r,{seriesIndex:s,dataPointIndex:a,w:e}));t.push(l)})});let i=v.getLargestStringFromArr(t),s=new Y(this.w),a=e.config.dataLabels.style,r=s.getTextRects(i,parseInt(a.fontSize).toString(),a.fontFamily);return{width:1.05*r.width,height:r.height}}getLargestStringFromMultiArr(e,t){let i=this.w,s=e;if(i.axisFlags.isMultiLineX){let e=t.map(e=>Array.isArray(e)?e.length:1),i=Math.max(...e);s=t[e.indexOf(i)]}return s}};class eh{constructor(e){this.w=e.w,this.dCtx=e}getxAxisLabelsCoords(){let e,t=this.w,i=t.labelData.labels.slice();if(t.config.xaxis.convertedCatToNumeric&&0===i.length&&(i=t.labelData.categoryLabels),t.labelData.timescaleLabels.length>0){let i=this.getxAxisTimeScaleLabelsCoords();e={width:i.width,height:i.height},t.layout.rotateXLabels=!1}
27else{this.dCtx.lgWidthForSideLegends="left"!==t.config.legend.position&&"right"!==t.config.legend.position||t.config.legend.floating?0:this.dCtx.lgRect.width;let s=t.formatters.xLabelFormatter,a=v.getLargestStringFromArr(i),r=this.dCtx.dimHelpers.getLargestStringFromMultiArr(a,i);t.globals.isBarHorizontal&&(r=a=t.globals.yAxisScale[0].result.reduce((e,t)=>e.length>t.length?e:t,0));let l=new C(this.w),o=a;a=l.xLabelFormat(s,a,o,{i:void 0,dateFormatter:new A(this.w).formatDate,w:t}),r=l.xLabelFormat(s,r,o,{i:void 0,dateFormatter:new A(this.w).formatDate,w:t}),(t.config.xaxis.convertedCatToNumeric&&void 0===a||""===String(a).trim())&&(r=a="1");let n=new Y(this.w),h=n.getTextRects(a,t.config.xaxis.labels.style.fontSize),d=h;if(a!==r&&(d=n.getTextRects(r,t.config.xaxis.labels.style.fontSize)),(e={width:h.width>=d.width?h.width:d.width,height:h.height>=d.height?h.height:d.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.layout.rotateXLabels=!0;let i=e=>n.getTextRects(e,t.config.xaxis.labels.style.fontSize,t.config.xaxis.labels.style.fontFamily,`rotate(${t.config.xaxis.labels.rotate} 0 0)`,!1);h=i(a),a!==r&&(d=i(r)),e.height=(h.height>d.height?h.height:d.height)/1.5,e.width=h.width>d.width?h.width:d.width}}else t.layout.rotateXLabels=!1}return t.config.xaxis.labels.show||(e={width:0,height:0}),{width:e.width,height:e.height}}getxAxisGroupLabelsCoords(){var e;let t,i=this.w;if(!i.labelData.hasXaxisGroups)return{width:0,height:0};let s=(null==(e=i.config.xaxis.group.style)?void 0:e.fontSize)||i.config.xaxis.labels.style.fontSize,a=i.labelData.groups.map(e=>e.title),r=v.getLargestStringFromArr(a),l=this.dCtx.dimHelpers.getLargestStringFromMultiArr(r,a),o=new Y(this.w),n=o.getTextRects(r,s),h=n;return r!==l&&(h=o.getTextRects(l,s)),t={width:n.width>=h.width?n.width:h.width,height:n.height>
27=h.height?n.height:h.height},i.config.xaxis.labels.show||(t={width:0,height:0}),{width:t.width,height:t.height}}getxAxisTitleCoords(){let e=this.w,t=0,i=0;if(void 0!==e.config.xaxis.title.text){let s=new Y(this.w).getTextRects(e.config.xaxis.title.text,e.config.xaxis.title.style.fontSize);t=s.width,i=s.height}return{width:t,height:i}}getxAxisTimeScaleLabelsCoords(){let e=this.w;this.dCtx.timescaleLabels=e.labelData.timescaleLabels.slice();let t=this.dCtx.timescaleLabels.map(e=>e.value),i=t.reduce((e,t)=>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),s=new Y(this.w).getTextRects(i,e.config.xaxis.labels.style.fontSize);return 1.05*s.width*t.length>e.layout.gridWidth&&0!==e.config.xaxis.labels.rotate&&(e.globals.overlappingXLabels=!0),s}additionalPaddingXLabels(e){let t=this.w,i=t.globals,s=t.config,a=s.xaxis.type,r=e.width;i.skipLastTimelinelabel=!1,i.skipFirstTimelinelabel=!1;let l=t.config.yaxis[0].opposite&&t.globals.isBarHorizontal,o=e=>{if(this.dCtx.timescaleLabels&&this.dCtx.timescaleLabels.length){let a=this.dCtx.timescaleLabels[0],l=this.dCtx.timescaleLabels[this.dCtx.timescaleLabels.length-1].position+r/1.75-this.dCtx.yAxisWidthRight,o=a.position-r/1.75+this.dCtx.yAxisWidthLeft,n="right"===t.config.legend.position&&this.dCtx.lgRect.width>0?this.dCtx.lgRect.width:0;l>i.svgWidth-t.layout.translateX-n&&(i.skipLastTimelinelabel=!0),o<-((!e.show||e.floating)&&("bar"===s.chart.type||"candlestick"===s.chart.type||"rangeBar"===s.chart.type||"boxPlot"===s.chart.type)?r/1.75:10)&&(i.skipFirstTimelinelabel=!0)}else"datetime"===a?this.dCtx.gridPad.right<r&&!t.layout.rotateXLabels&&(i.skipLastTimelinelabel=!0):"datetime"===a||!(this.dCtx.gridPad.right<r/2-this.dCtx.yAxisWidthRight)||t.layout.rotateXLabels||t.config.xaxis.labels.trim||(this.dCtx.xPadRight=r/2+1)};s.yaxis.forEach((e,t)=>{if(l)this.dCtx.gridPad.left<r&&(this.dCtx.xPadLeft=r/2+1),this.dCtx.xPadRight=r/2+1;else s.yaxis.length>1&&-1!==i.collapsedSeriesIndices.indexOf(t)||o(e)})}}class ed{constructor(e){this.w=e.w,this.dCtx=e}getyAxisLabelsCoords(){let e=this.w,t=[],i=10,s=new j(this.w,{theme:this.dCtx.theme,timeScale:this.dCtx.timeScale});return e.config.yaxis.map((a,r)=>{let l={seriesIndex:r,dataPointIndex:-1,w:e},o=e.globals.yAxisScale[r],n=0;if(!s.isYAxisHidden(r)&&a.labels.show&&void 0!==a.labels.minWidth&&(n=a.labels.minWidth),!s.isYAxisHidden(r)&&a.labels.show&&o.result.length){let s=e.formatters.yLabelFormatters[r],h=5e-324===o.niceMin?0:o.niceMin,d=o.result.reduce((e,t)=>{var i,a;return(null==(i=String(s(e,l)))?void 0:i.length)>(null==(a=String(s(t,l)))?void 0:a.length)?e:t},h),c=d=s(d,l);if((void 0===d||0===d.length)&&(d=o.niceMax),1===String(d).length&&(d+=".0",c=d),e.globals.isBarHorizontal){i=0;let t=e.labelData.labels.slice();d=s(d=v.getLargestStringFromArr(t),{seriesIndex:r,dataPointIndex:-1,w:e}),c=this.dCtx.dimHelpers.getLargestStringFromMultiArr(d,t)}let g=new Y(this.w),p="rotate(".concat(a.labels.rotate," 0 0)"),x=g.getTextRects(d,a.labels.style.fontSize,a.labels.style.fontFamily,p,!1),u=x;d!==c&&(u=g.getTextRects(c,a.labels.style.fontSize,a.labels.style.fontFamily,p,!1)),t.push({width:(n>u.width||n>x.width?n:u.width>x.width?u.width:x.width)+i,height:u.height>x.height?u.height:x.height})}else t.push({width:0,height:0})}),t}getyAxisTitleCoords(){let e=this.w,t=[];return e.config.yaxis.map(e=>{if(e.show&&void 0!==e.title.text){let i=new Y(this.w),s="rotate(".concat(e.title.rotate," 0 0)"),a=i.getTextRects(e.title.text,e.title.style.fontSize,e.title.style.fontFamily,s,!1);t.push({width:a.width,height:a.height})}else t.push({width:0,height:0})}),t}getTotalYAxisWidth(){let e=this.w,t=0,i=0,s=0,a=10*(e.globals.yAxisScale.length>1),r=new j(this.w,{theme:this.dCtx.theme,timeScale:this.dCtx.timeScale}),l=(l,o)=>{let n=e.config.yaxis[o].floating,h=0;if(l.width>0&&!n)h=l.width+a,e.globals.ignoreYAxisIndexes.indexOf(o)>-1&&(h=h-l.width-a);else h=n||r.isYAxisHidden(o)?0:5;e.config.yaxis[o].opposite?s+=h:i+=h,t+=h};return e.layout.yLabelsCoords.map((e,t)=>{l(e,t)}),e.layout.yTitleCoords.map((e,t)=>{l(e,t)}),e.globals.isBarHorizontal&&!e.config.yaxis[0].floating&&(t=e.layout.yLabelsCoords[0].width+e.layout.yTitleCoords[0].width+15),this.dCtx.yAxisWidthLeft=i,this.dCtx.yAxisWidthRight=s,t}}class ec{constructor(e){this.w=e.w,this.dCtx=e}gridPadForColumnsInNumericAxis(e){let{w:t}=this,{config:i,globals:s}=t;
27if(s.noData||s.collapsedSeries.length+s.ancillaryCollapsedSeries.length===i.series.length)return 0;let a=e=>["bar","rangeBar","candlestick","boxPlot"].includes(e),r=i.chart.type,l=0,o=a(r)?i.series.length:1;s.comboBarCount>0&&(o=s.comboBarCount),s.collapsedSeries.forEach(e=>{a(e.type)&&(o-=1)}),i.chart.stacked&&(o=1);let n=a(r)||s.comboBarCount>0,h=Math.abs(s.initialMaxX-s.initialMinX);if(n&&t.axisFlags.isXNumeric&&!s.isBarHorizontal&&o>0&&0!==h){h<=3&&(h=s.dataPoints);let t=h/e,a=s.minXDiff&&s.minXDiff/t>0?s.minXDiff/t:0;a>e/2&&(a/=2),(l=a*parseInt(i.plotOptions.bar.columnWidth,10)/100)<1&&(l=1),s.barPadForNumericAxis=l}return l}gridPadFortitleSubtitle(){let{w:e}=this,{globals:t}=e,i=this.dCtx.isSparkline||!t.axisCharts?0:10;["title","subtitle"].forEach(s=>{void 0!==e.config[s].text?i+=e.config[s].margin:i+=this.dCtx.isSparkline||!t.axisCharts?0:5}),!e.config.legend.show||"bottom"!==e.config.legend.position||e.config.legend.floating||t.axisCharts||(i+=10);let s=this.dCtx.dimHelpers.getTitleSubtitleCoords("title"),a=this.dCtx.dimHelpers.getTitleSubtitleCoords("subtitle");e.layout.gridHeight-=s.height+a.height+i,e.layout.translateY+=s.height+a.height+i}setGridXPosForDualYAxis(e,t){let{w:i}=this,s=new j(this.w,{theme:this.dCtx.theme,timeScale:this.dCtx.timeScale});i.config.yaxis.forEach((a,r)=>{-1!==i.globals.ignoreYAxisIndexes.indexOf(r)||a.floating||s.isYAxisHidden(r)||(a.opposite&&(i.layout.translateX-=t[r].width+e[r].width+parseInt(a.labels.style.fontSize,10)/1.2+12),i.layout.translateX<2&&(i.layout.translateX=2))})}}class eg{constructor(e,t){this.w=e,this.ctx=t,this.theme=t.theme,this.timeScale=t.timeScale,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 en(this),this.dimYAxis=new ed(this),this.dimXAxis=new eh(this),this.dimGrid=new ec(this),this.lgWidthForSideLegends=0,this.gridPad=this.w.config.grid.padding,this.xPadRight=0,this.xPadLeft=0,this.datalabelsCoords={width:0,height:0},this.xAxisWidth=0,this.timescaleLabels=[]}plotCoords(){let e=this.w,t=e.globals;this.lgRect=this.dimHelpers.getLegendsRect(),this.datalabelsCoords={width:0,height:0};let i=Array.isArray(e.config.stroke.width)?Math.max(...e.config.stroke.width):e.config.stroke.width;this.isSparkline&&((e.config.markers.discrete.length>0||e.config.markers.size>0)&&Object.entries(this.gridPad).forEach(([e,t])=>{this.gridPad[e]=Math.max(t,this.w.globals.markers.largestSize/1.5)}),this.gridPad.top=Math.max(i/2,this.gridPad.top),this.gridPad.bottom=Math.max(i/2,this.gridPad.bottom)),t.axisCharts?this.setDimensionsForAxisCharts():this.setDimensionsForNonAxisCharts(),this.dimGrid.gridPadFortitleSubtitle(),e.layout.gridHeight=e.layout.gridHeight-this.gridPad.top-this.gridPad.bottom,e.layout.gridWidth=e.layout.gridWidth-this.gridPad.left-this.gridPad.right-this.xPadRight-this.xPadLeft;let s=this.dimGrid.gridPadForColumnsInNumericAxis(e.layout.gridWidth);return e.layout.gridWidth=e.layout.gridWidth-2*s,e.layout.translateX=e.layout.translateX+this.gridPad.left+this.xPadLeft+(s>0?s:0),e.layout.translateY=e.layout.translateY+this.gridPad.top,{layout:{gridHeight:e.layout.gridHeight,gridWidth:e.layout.gridWidth,translateX:e.layout.translateX,translateY:e.layout.translateY,translateXAxisX:e.layout.translateXAxisX,translateXAxisY:e.layout.translateXAxisY,rotateXLabels:e.layout.rotateXLabels,xAxisHeight:e.layout.xAxisHeight,xAxisLabelsHeight:e.layout.xAxisLabelsHeight,xAxisGroupLabelsHeight:e.layout.xAxisGroupLabelsHeight,xAxisLabelsWidth:e.layout.xAxisLabelsWidth,yLabelsCoords:e.layout.yLabelsCoords,yTitleCoords:e.layout.yTitleCoords}}}setDimensionsForAxisCharts(){let e=this.w,t=e.globals,i=this.dimYAxis.getyAxisLabelsCoords(),s=this.dimYAxis.getyAxisTitleCoords();t.isSlopeChart&&(this.datalabelsCoords=this.dimHelpers.getDatalabelsRect()),e.layout.yLabelsCoords=[],e.layout.yTitleCoords=[],e.config.yaxis.map((t,a)=>{e.layout.yLabelsCoords.push({width:i[a].width,index:a}),e.layout.yTitleCoords.push({width:s[a].width,index:a})}),this.yAxisWidth=this.dimYAxis.getTotalYAxisWidth();let a=this.dimXAxis.getxAxisLabelsCoords(),r=this.dimXAxis.getxAxisGroupLabelsCoords(),l=this.dimXAxis.getxAxisTitleCoords();this.conditionalChecksForAxisCoords(a,l,r),e.layout.translateXAxisY=e.layout.rotateXLabels?this.xAxisHeight/8:-4,e.layout.translateXAxisX=e.layout.rotateXLabels&&e.axisFlags.isXNumeric&&e.config.xaxis.labels.rotate<=-45?-this.xAxisWidth/4:0,e.globals.isBarHorizontal&&(e.layout.rotateXLabels=!1,e.layout.translateXAxisY=-1*(parseInt(e.config.xaxis.labels.style.fontSize,10)/1.5)),e.layout.translateXAxisY=e.layout.translateXAxisY+e.config.xaxis.labels.offsetY,e.layout.translateXAxisX=e.layout.translateXAxisX+e.config.xaxis.labels.offsetX;let o=this.yAxisWidth,n=this.xAxisHeight;e.layout.xAxisLabelsHeight=this.xAxisHeight-l.height,e.layout.xAxisGroupLabelsHeight=e.layout.xAxisLabelsHeight-a.height,e.layout.xAxisLabelsWidth=this.xAxisWidth,e.layout.xAxisHeight=this.xAxisHeight;let h=10;("radar"===e.config.chart.type||this.isSparkline)&&(o=0,n=0),this.isSparkline&&(this.lgRect={height:0,width:0}),(this.isSparkline||"treemap"===e.config.chart.type)&&(o=0,n=0,h=0),this.isSparkline||"treemap"===e.config.chart.type||this.dimXAxis.additionalPaddingXLabels(a);let d=()=>{e.layout.translateX=o+this.datalabelsCoords.width,e.layout.gridHeight=t.svgHeight-this.lgRect.height-n-(this.isSparkline||"treemap"===e.config.chart.type?0:e.layout.rotateXLabels?10:15),e.layout.gridWidth=t.svgWidth-o-2*this.datalabelsCoords.width};switch("top"===e.config.xaxis.position&&(h=e.layout.xAxisHeight-e.config.xaxis.axisTicks.height-5),e.config.legend.position){case"bottom":e.layout.translateY=h,d();break;case"top":e.layout.translateY=this.lgRect.height+h,d();break;case"left":e.layout.translateY=h,e.layout.translateX=this.lgRect.width+o+this.datalabelsCoords.width,e.layout.gridHeight=t.svgHeight-n-12,e.layout.gridWidth=t.svgWidth-this.lgRect.width-o-2*this.datalabelsCoords.width;break;case"right":e.layout.translateY=h,e.layout.translateX=o+this.datalabelsCoords.width,e.layout.gridHeight=t.svgHeight-n-12,e.layout.gridWidth=t.svgWidth-this.lgRect.width-o-2*this.datalabelsCoords.width-5;break;default:throw Error("Legend position not supported")}this.dimGrid.setGridXPosForDualYAxis(s,i),new Q(this.w,{theme:this.theme,timeScale:this.timeScale}).setYAxisXPosition(i,s)}setDimensionsForNonAxisCharts(){let e=this.w,t=e.globals,i=e.config,s=0;e.config.legend.show&&!e.config.legend.floating&&(s=20);let a="pie"===i.chart.type||"polarArea"===i.chart.type||"donut"===i.chart.type?"pie":"radialBar",r=i.plotOptions[a].offsetY,l=i.plotOptions[a].offsetX;if(!i.legend.show||i.legend.floating){e.layout.gridHeight=t.svgHeight;let i=e.dom.elWrap.getBoundingClientRect().width;e.layout.gridWidth=Math.min(i,e.layout.gridHeight),e.layout.translateY=r,e.layout.translateX=l+(t.svgWidth-e.layout.gridWidth)/2;return}switch(i.legend.position){case"bottom":e.layout.gridHeight=t.svgHeight-this.lgRect.height,e.layout.gridWidth=t.svgWidth,e.layout.translateY=r-10,e.layout.translateX=l+(t.svgWidth-e.layout.gridWidth)/2;break;case"top":e.layout.gridHeight=t.svgHeight-this.lgRect.height,e.layout.gridWidth=t.svgWidth,e.layout.translateY=this.lgRect.height+r+10,e.layout.translateX=l+(t.svgWidth-e.layout.gridWidth)/2;break;case"left":e.layout.gridWidth=t.svgWidth-this.lgRect.width-s,e.layout.gridHeight="auto"!==i.chart.height?t.svgHeight:e.layout.gridWidth,e.layout.translateY=r,e.layout.translateX=l+this.lgRect.width+s;break;case"right":e.layout.gridWidth=t.svgWidth-this.lgRect.width-s-5,e.layout.gridHeight="auto"!==i.chart.height?t.svgHeight:e.layout.gridWidth,e.layout.translateY=r,e.layout.translateX=l+10;break;default:throw Error("Legend position not supported")}}conditionalChecksForAxisCoords(e,t,i){let s=this.w,a=s.labelData.hasXaxisGroups?2:1,r=i.height+e.height+t.height,l=s.axisFlags.isMultiLineX?1.2:1.618,o=s.layout.rotateXLabels?22:10,n=s.layout.rotateXLabels&&"bottom"===s.config.legend.position;this.xAxisHeight=r*l+a*o+10*!!n,this.xAxisWidth=e.width,this.xAxisHeight-t.height>s.config.xaxis.labels.maxHeight&&(this.xAxisHeight=s.config.xaxis.labels.maxHeight),s.c
27onfig.xaxis.labels.minHeight&&this.xAxisHeight<s.config.xaxis.labels.minHeight&&(this.xAxisHeight=s.config.xaxis.labels.minHeight),s.config.xaxis.floating&&(this.xAxisHeight=0);let h=0,d=0;s.config.yaxis.forEach(e=>{h+=e.labels.minWidth,d+=e.labels.maxWidth}),this.yAxisWidth<h&&(this.yAxisWidth=h),this.yAxisWidth>d&&(this.yAxisWidth=d)}}class ep{constructor(e,t){this.w=e,this.ctx=t,this.timeScaleArray=[],this.utc=this.w.config.xaxis.labels.datetimeUTC}calculateTimeScaleTicks(e,t){let i=this.w;if(i.globals.allSeriesCollapsed)return i.labelData.labels=[],i.labelData.timescaleLabels=[],[];let s=new A(this.w),a=(t-e)/864e5;this.determineInterval(a),i.interact.disableZoomIn=!1,i.interact.disableZoomOut=!1,a<11574074074074075e-20?i.interact.disableZoomIn=!0:a>5e4&&(i.interact.disableZoomOut=!0);let r=s.getTimeUnitsfromTimestamp(e,t),l=i.layout.gridWidth/a,o=l/24,n=o/60,h=Math.floor(24*a),g=Math.floor(1440*a),p=Math.floor(86400*a),x=Math.floor(a),u=Math.floor(a/30),f=Math.floor(a/365),m={minMillisecond:r.minMillisecond,minSecond:r.minSecond,minMinute:r.minMinute,minHour:r.minHour,minDate:r.minDate,minMonth:r.minMonth,minYear:r.minYear},b=m.minMillisecond,y=m.minSecond,w=m.minMinute,v=m.minHour,C=m.minDate,S=m.minDate,k=m.minMonth,D=m.minYear,L={firstVal:m,currentMillisecond:b,currentSecond:y,currentMinute:w,currentHour:v,currentMonthDate:C,currentDate:S,currentMonth:k,currentYear:D,daysWidthOnXAxis:l,hoursWidthOnXAxis:o,minutesWidthOnXAxis:n,secondsWidthOnXAxis:n/60,numberOfSeconds:p,numberOfMinutes:g,numberOfHours:h,numberOfDays:x,numberOfMonths:u,numberOfYears:f};switch(this.tickInterval){case"years":this.generateYearScale(L);break;case"months":case"half_year":this.generateMonthScale(L);break;case"months_days":case"months_fortnight":case"days":case"week_days":this.generateDayScale(L);break;case"hours":this.generateHourScale(L);break;case"minutes_fives":case"minutes":this.generateMinuteScale(L);break;case"seconds_tens":case"seconds_fives":case"seconds":this.generateSecondScale(L)}let M=this.timeScaleArray.map(e=>{let 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?c(d({},t),{day:1,value:e.value+1}):"day"===e.unit||"hour"===e.unit?c(d({},t),{value:e.value}):"minute"===e.unit?c(d({},t),{value:e.value,minute:e.value}):"second"===e.unit?c(d({},t),{value:e.value,minute:e.minute,second:e.second}):e});return M.filter(e=>{let t=1,s=Math.ceil(i.layout.gridWidth/120),a=e.value;void 0!==i.config.xaxis.tickAmount&&(s=i.config.xaxis.tickAmount),M.length>s&&(t=Math.floor(M.length/s));let r=!1,l=!1;switch(this.tickInterval){case"years":"year"===e.unit&&(r=!0);break;case"half_year":t=7,"year"===e.unit&&(r=!0);break;case"months":t=1,"year"===e.unit&&(r=!0);break;case"months_fortnight":t=15,("year"===e.unit||"month"===e.unit)&&(r=!0),30===a&&(l=!0);break;case"months_days":t=10,"month"===e.unit&&(r=!0),30===a&&(l=!0);break;case"week_days":t=8,"month"===e.unit&&(r=!0);break;case"days":t=1,"month"===e.unit&&(r=!0);break;case"hours":"day"===e.unit&&(r=!0);break;case"minutes_fives":case"seconds_fives":a%5!=0&&(l=!0);break;case"seconds_tens":a%10!=0&&(l=!0)}if("hours"===this.tickInterval||"minutes_fives"===this.tickInterval||"seconds_tens"===this.tickInterval||"seconds_fives"===this.tickInterval){if(!l)return!0}else if((a%t==0||r)&&!l)return!0})}recalcDimensionsBasedOnFormat(e){let t=this.w,i=this.formatDates(e),s=this.removeOverlappingTS(i);t.labelData.timescaleLabels=s.slice();let a=new eg(this.w,this.ctx).plotCoords();this.ctx._writeLayoutCoords(a.layout)}determineInterval(e){let 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"}}generateYearScale({firstVal:e,currentMonth:t,currentYear:i,daysWidthOnXAxis:s,numberOfYears:a}){let r=e.minYear,l=0,o=new A(this.w),n="year";if(e.minDate>1||e.minMonth>
270){let t=o.determineRemainingDaysOfYear(e.minYear,e.minMonth,e.minDate);l=(o.determineDaysOfYear(e.minYear)-t+1)*s,r=e.minYear+1,this.timeScaleArray.push({position:l,value:r,unit:n,year:r,month:1})}else 1===e.minDate&&0===e.minMonth&&this.timeScaleArray.push({position:l,value:r,unit:n,year:i,month:v.monthMod(t+1)});let h=r,d=l;for(let e=0;e<a;e++)h++,d=o.determineDaysOfYear(h-1)*s+d,this.timeScaleArray.push({position:d,value:h,unit:n,year:h,month:1})}generateMonthScale({firstVal:e,currentMonthDate:t,currentMonth:i,currentYear:s,daysWidthOnXAxis:a,numberOfMonths:r}){let l=i,o=0,n=new A(this.w),h="month",d=0;if(e.minDate>1){o=(n.determineDaysOfMonths(i+1,e.minYear)-t+1)*a,l=v.monthMod(i+1);let r=s+d,c=v.monthMod(l),g=l;0===l&&(h="year",g=r,c=1,d+=1,r+=d),this.timeScaleArray.push({position:o,value:g,unit:h,year:r,month:c})}else this.timeScaleArray.push({position:o,value:l,unit:h,year:s,month:v.monthMod(i)});let c=l+1,g=o;for(let e=0,t=1;e<r;e++,t++){0===(c=v.monthMod(c))?(h="year",d+=1):h="month";let e=this._getYear(s,c,d);g=n.determineDaysOfMonths(c,e)*a+g;let t=0===c?e:c;this.timeScaleArray.push({position:g,value:t,unit:h,year:e,month:0===c?1:c}),c++}}generateDayScale({firstVal:e,currentMonth:t,currentYear:i,hoursWidthOnXAxis:s,numberOfDays:a}){let r=new A(this.w),l="day",o=e.minDate+1,n=o,h=(e,t,i)=>(e>r.determineDaysOfMonths(t+1,i)&&(t+=1,n=1,l="month",c=t),t),d=(24-e.minHour)*s,c=o,g=h(n,t,i);0===e.minHour&&1===e.minDate?(d=0,c=v.monthMod(e.minMonth),l="month",n=e.minDate):1!==e.minDate&&0===e.minHour&&0===e.minMinute&&(d=0,n=o=e.minDate,c=o,g=h(n,t,i),1!==c&&(l="day")),this.timeScaleArray.push({position:d,value:c,unit:l,year:this._getYear(i,g,0),month:v.monthMod(g),day:n});let p=d;for(let e=0;e<a;e++){n+=1,l="day",g=h(n,g,this._getYear(i,g,0));let e=this._getYear(i,g,0);p=24*s+p;let t=1===n?v.monthMod(g):n;this.timeScaleArray.push({position:p,value:t,unit:l,year:e,month:v.monthMod(g),day:t})}}generateHourScale({firstVal:e,currentDate:t,currentMonth:i,currentYear:s,minutesWidthOnXAxis:a,numberOfHours:r}){let l=new A(this.w),o="hour",n=(e,t)=>(e>l.determineDaysOfMonths(t+1,s)&&(x=1,t+=1),{month:t,date:x}),h=(e,t)=>(e>l.determineDaysOfMonths(t+1,s)&&(t+=1),t),d=60-(e.minMinute+e.minSecond/60),c=d*a,g=e.minHour+1,p=g;60===d&&(c=0,p=g=e.minHour);let x=t;p>=24&&(p=0,x+=1,o="day",g=x);let u=n(x,i).month;u=h(x,u),"day"===o&&(g=x),this.timeScaleArray.push({position:c,value:g,unit:o,day:x,hour:p,year:s,month:v.monthMod(u)}),p++;let f=c;for(let e=0;e<r;e++){o="hour",p>=24&&(p=0,o="day",u=n(x+=1,u).month,u=h(x,u));let e=this._getYear(s,u,0);f=60*a+f;let t=0===p?x:p;this.timeScaleArray.push({position:f,value:t,unit:o,hour:p,day:x,year:e,month:v.monthMod(u)}),p++}}generateMinuteScale({currentMillisecond:e,currentSecond:t,currentMinute:i,currentHour:s,currentDate:a,currentMonth:r,currentYear:l,minutesWidthOnXAxis:o,secondsWidthOnXAxis:n,numberOfMinutes:h}){let d=new A(this.w),c=(60-t-e/1e3)*n,g=i+1;0===t&&0===e&&(c=0,g=i);let p=a,x=r,u=s,f=c;for(let e=0;e<h;e++)g>=60&&(g=0,24===(u+=1)&&(u=0,(p+=1)>d.determineDaysOfMonths(x+1,this._getYear(l,x,0))&&(p=1,x+=1))),this.timeScaleArray.push({position:f,value:g,unit:"minute",hour:u,minute:g,day:p,year:this._getYear(l,x,0),month:v.monthMod(x)}),f+=o,g++}generateSecondScale({currentMillisecond:e,currentSecond:t,currentMinute:i,currentHour:s,currentDate:a,currentMonth:r,currentYear:l,secondsWidthOnXAxis:o,numberOfSeconds:n}){let h=(1e3-e)/1e3*o,d=t+1;0===e&&(h=0,d=t);let c=i,g=s,p=h;for(let e=0;e<n;e++)d>=60&&(d=0,++c>=60&&(c=0,24==++g&&(g=0))),this.timeScaleArray.push({position:p,value:d,unit:"second",hour:g,minute:c,second:d,day:a,year:this._getYear(l,r,0),month:v.monthMod(r)}),p+=o,d++}createRawDateString(e,t){let i=e.year;return 0===e.month&&(e.month=1),i+="-"+("0"+e.month.toString()).slice(-2),"day"===e.unit?i+="-"+("0"+t).slice(-2):i+="-"+("0"+(e.day?e.day:"1")).slice(-2),"hour"===e.unit?i+="T"+("0"+t).slice(-2):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}formatDates(e){let t=this.w;return e.map(e=>{let i=e.value.toString(),s=new A(this.w),a=this.createRawDateString(e,i),r=s.getDate(s.parseDate(a));if(this.utc||(r=s.getDate(s.parseDateWithTimezone(a))),void 0===t.config.xaxis.labels.format){let a="dd MMM",l=t.config.xaxis.labels.datetimeFormatter;"year"===e.unit&&(a=l.year),"month"===e.unit&&(a=l.month),"day"===e.unit&&(a=l.day),"hour"===e.unit&&(a=l.hour),"minute"===e.unit&&(a=l.minute),"second"===e.unit&&(a=l.second),i=s.formatDate(r,a)}else i=s.formatDate(r,t.config.xaxis.labels.format);return{dateString:a,position:e.position,value:i,unit:e.unit,year:e.year,month:e.month}})}removeOverlappingTS(e){let t,i=new Y(this.w),s=!1;e.length>0&&e[0].value&&e.every(t=>t.value.length===e[0].value.length)&&(s=!0,t=i.getTextRects(e[0].value,this.w.config.xaxis.labels.style.fontSize).width);let a=0,r=e.map((r,l)=>{if(!(l>0)||!this.w.config.xaxis.labels.hideOverlappingLabels)return r;{let o=s?t:i.getTextRects(e[a].value,this.w.config.xaxis.labels.style.fontSize).width,n=e[a].position;return r.position>n+o+10?(a=l,r):null}});return r.filter(e=>null!==e)}_getYear(e,t,i){return e+Math.floor(t/12)+i}}let ex="__apexcharts_registry__";function eu(){return globalThis[ex]}function ef(e){let t=eu()[e];if(!t)throw Error(`ApexCharts: chart type "${e}" is not registered. Import it via ApexCharts.use() or use the full apexcharts bundle.`);return t}globalThis[ex]||(globalThis[ex]={});class em{constructor(e,t,i){this.w=t,this.ctx=i,this.el=e}setupElements(){let{globals:e,config:t}=this.w,s=t.chart.type,a=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble"];e.axisCharts=[...a,"radar","heatmap","treemap"].includes(s),e.xyCharts=a.includes(s),e.isBarHorizontal=["bar","rangeBar","boxPlot"].includes(s)&&t.plotOptions.bar.horizontal,e.chartClass=`.apexcharts${e.chartID}`,this.w.dom.baseEl=this.el,this.w.dom.elWrap=w.createElementNS("http://www.w3.org/1999/xhtml","div"),Y.setAttrs(this.w.dom.elWrap,{id:e.chartClass.substring(1),class:`apexcharts-canvas ${e.chartClass.substring(1)}`}),this.el.appendChild(this.w.dom.elWrap);let r=p.isBrowser()?window.SVG:i.g.SVG;if(this.w.dom.Paper=r().addTo(this.w.dom.elWrap),this.w.dom.Paper.attr({class:"apexcharts-svg","xmlns:data":"ApexChartsNS",transform:`translate(${t.chart.offsetX}, ${t.chart.offsetY})`}),this.w.dom.Paper.node.style.background="dark"!==t.theme.mode||t.chart.background?"light"!==t.theme.mode||t.chart.background?t.chart.background:"#fff"
27:"#343A3F",this.setSVGDimensions(),this.w.dom.elLegendForeign=w.createElementNS(B,"foreignObject"),Y.setAttrs(this.w.dom.elLegendForeign,{x:0,y:0,width:e.svgWidth,height:e.svgHeight}),this.w.dom.elLegendWrap=w.createElementNS("http://www.w3.org/1999/xhtml","div"),this.w.dom.elLegendWrap.classList.add("apexcharts-legend"),this.w.dom.elWrap.appendChild(this.w.dom.elLegendWrap),this.w.dom.Paper.node.appendChild(this.w.dom.elLegendForeign),t.chart.accessibility.enabled&&t.chart.accessibility.announcements.enabled){let e=w.createElement("div");e.className="apexcharts-sr-status",e.setAttribute("role","status"),e.setAttribute("aria-live","polite"),e.setAttribute("aria-atomic","true"),this.w.dom.elWrap.appendChild(e)}if(t.chart.accessibility.enabled){let e=this.getAccessibleChartLabel(),i=t.chart.accessibility.keyboard.enabled&&t.chart.accessibility.keyboard.navigation.enabled?"application":"img";this.w.dom.Paper.attr({role:i,"aria-label":e});let s=w.createElementNS(B,"title");if(s.textContent=e,this.w.dom.Paper.node.insertBefore(s,this.w.dom.elLegendForeign.nextSibling),t.chart.accessibility.description){let e=w.createElementNS(B,"desc");e.textContent=t.chart.accessibility.description,this.w.dom.Paper.node.insertBefore(e,this.w.dom.elLegendForeign.nextSibling)}}this.w.dom.elGraphical=this.w.dom.Paper.group().attr({class:"apexcharts-inner apexcharts-graphical"}),this.w.dom.elDefs=this.w.dom.Paper.defs(),this.w.dom.Paper.add(this.w.dom.elGraphical),this.w.dom.elGraphical.add(this.w.dom.elDefs)}plotChartType(e,t){let{w:i,ctx:s}=this,{config:a,globals:r}=i,l={line:{series:[],i:[]},area:{series:[],i:[]},scatter:{series:[],i:[]},bubble:{series:[],i:[]},bar:{series:[],i:[]},candlestick:{series:[],i:[]},boxPlot:{series:[],i:[]},rangeBar:{series:[],i:[]},rangeArea:{series:[],seriesRangeEnd:[],i:[]}},o=a.chart.type||"line",n=null,h=0;this.w.seriesData.series.forEach((t,s)=>{var a,r;let d=(null==(a=e[s])?void 0:a.type)==="column"?"bar":(null==(r=e[s])?void 0:r.type)||("column"===o?"bar":o);l[d]?("rangeArea"===d?(l[d].series.push(this.w.rangeData.seriesRangeStart[s]),l[d].seriesRangeEnd.push(this.w.rangeData.seriesRangeEnd[s])):l[d].series.push(t),l[d].i.push(s),"bar"===d&&(i.globals.columnSeries=l.bar)):["heatmap","treemap","pie","donut","polarArea","radialBar","radar"].includes(d)?n=d:console.warn(`You have specified an unrecognized series type (${d}).`),o!==d&&"scatter"!==d&&h++}),h>0&&(n&&console.warn(`Chart or series type ${n} cannot appear with other chart or series types.`),l.bar.series.length>0&&a.plotOptions.bar.horizontal&&(h-=l.bar.series.length,l.bar={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=h>0);let d=l.line.series.length>0||l.area.series.length>0||l.scatter.series.length>0||l.bubble.series.length>0||l.rangeArea.series.length>0||!r.comboCharts&&["line","area","scatter","bubble","rangeArea"].includes(a.chart.type)?new(ef("line"))(s.w,s,t):null,c=l.candlestick.series.length>0||l.boxPlot.series.length>0||!r.comboCharts&&["candlestick","boxPlot"].includes(a.chart.type)?new(ef("candlestick"))(s.w,s,t):null;s.pie=!r.comboCharts&&["pie","donut","polarArea"].includes(a.chart.type)?new(ef("pie"))(s.w,s):null,s.rangeBar=l.rangeBar.series.length>0||!r.comboCharts&&"rangeBar"===a.chart.type?new(ef("rangeBar"))(s.w,s,t):null;let g=[];if(r.comboCharts){let e=new I(this.w);if(l.area.series.length>0&&g.push(...e.drawSeriesByGroup(l.area,r.areaGroups,"area",d)),l.bar.series.length>0)if(a.chart.stacked){let e=new(ef("barStacked"))(s.w,s,t);g.push(e.draw(l.bar.series,l.bar.i))}else s.bar=new(ef("bar"))(s.w,s,t),g.push(s.bar.draw(l.bar.series,l.bar.i));if(l.rangeArea.series.length>0&&g.push(d.draw(l.rangeArea.series,"rangeArea",l.rangeArea.i,l.rangeArea.seriesRangeEnd)),l.line.series.length>0&&g.push(...e.drawSeriesByGroup(l.line,r.lineGroups,"line",d)),l.candlestick.series.length>0&&g.push(c.draw(l.candlestick.series,"candlestick",l.candlestick.i)),l.boxPlot.series.length>0&&g.push(c.draw(l.boxPlot.series,"boxPlot",l.boxPlot.i)),l.rangeBar.series.length>0&&g.push(s.rangeBar.draw(l.rangeBar.series,l.rangeBar.i)),l.scatter.series.length>0){let e=new(ef("line"))(s.w,s,t,!0);g.push(e.draw(l.scatter.series,"scatter",l.scatter.i))}if(l.bubble.series.length>0){let e=new(ef("line"))(s.w,s,t,!0);g.push(e.draw(l.bubble.series,"bubble",l.bubble.i))}}else{let e=a.chart.type;switch(e){case"line":g=d.draw(this.w.seriesData.series,"line");break;case"area":g=d.draw(this.w.seriesData.series,"area");break;case"bar":a.chart.stacked?g=new(ef("barStacked"))(s.w,s,t).draw(this.w.seriesData.series):(s.bar=new(ef("bar"))(s.w,s,t),g=s.bar.draw(this.w.seriesData.series));break;case"candlestick":g=c.draw(this.w.seriesData.series,"candlestick");break;case"boxPlot":g=c.draw(this.w.seriesData.series,e);break;case"rangeBar":g=s.rangeBar.draw(this.w.seriesData.series);break;case"rangeArea":g=d.draw(this.w.rangeData.seriesRangeStart,"rangeArea",void 0,this.w.rangeData.seriesRangeEnd);break;case"heatmap":g=new(ef("heatmap"))(s.w,s,t).draw(this.w.seriesData.series);break;case"treemap":g=new(ef("treemap"))(s.w,s).draw(this.w.seriesData.series);break;case"pie":case"donut":case"polarArea":g=s.pie.draw(this.w.seriesData.series);break;
27case"radialBar":g=new(ef("radialBar"))(s.w,s).draw(this.w.seriesData.series);break;case"radar":g=new(ef("radar"))(s.w,s).draw(this.w.seriesData.series);break;default:g=d.draw(this.w.seriesData.series)}}return g}setSVGDimensions(){var e;let{globals:t,config:i}=this.w;i.chart.width=i.chart.width||"100%",i.chart.height=i.chart.height||"auto";let s=i.chart.width,a=i.chart.height;t.svgWidth=NaN,t.svgHeight=NaN;let r=v.getDimensions(this.el),l=s.toString().split(/[0-9]+/g).pop();"%"===l?v.isNumber(r[0])&&(0===r[0].width&&(r=v.getDimensions(this.el.parentNode)),t.svgWidth=r[0]*parseInt(s,10)/100):("px"===l||""===l)&&(t.svgWidth=parseInt(s,10));let o=String(a).toString().split(/[0-9]+/g).pop();if("auto"!==a&&""!==a?"%"===o?t.svgHeight=v.getDimensions(this.el.parentNode)[1]*parseInt(a,10)/100:t.svgHeight=parseInt(a,10):t.svgHeight=t.axisCharts?t.svgWidth/1.61:t.svgWidth/1.2,t.svgWidth=Math.max(t.svgWidth,0),t.svgHeight=Math.max(t.svgHeight,0),Y.setAttrs(this.w.dom.Paper.node,{width:t.svgWidth,height:t.svgHeight}),"%"!==o&&p.isBrowser()){let s=i.chart.sparkline.enabled?0:t.axisCharts?i.chart.parentHeightOffset:0,a=this.w.dom.Paper.node;(null==(e=a.parentNode)?void 0:e.parentNode)&&(a.parentNode.parentNode.style.minHeight=`${t.svgHeight+s}px`)}this.w.dom.elWrap.style.width=`${t.svgWidth}px`,this.w.dom.elWrap.style.height=`${t.svgHeight}px`}shiftGraphPosition(){let{globals:e}=this.w,{translateY:t,translateX:i}=e;Y.setAttrs(this.w.dom.elGraphical.node,{transform:`translate(${i}, ${t})`})}resizeNonAxisCharts(){var e,t;let{w:i}=this,s=0,a=i.config.chart.sparkline.enabled?1:15;a+=i.config.grid.padding.bottom,["top","bottom"].includes(i.config.legend.position)&&i.config.legend.show&&!i.config.legend.floating&&(s=(null!=(t=null==(e=this.ctx.legend)?void 0:e.legendHelpers.getLegendDimensions().clwh)?t:0)+7);let r=i.dom.baseEl.querySelector(".apexcharts-radialbar, .apexcharts-pie"),l=2.05*i.globals.radialSize;if(r&&!i.config.chart.sparkline.enabled&&0!==i.config.plotOptions.radialBar.startAngle){let e=v.getBoundingClientRect(r);l=e.bottom;let t=e.bottom-e.top;l=Math.max(2.05*i.globals.radialSize,t)}let o=Math.ceil(l+this.w.layout.translateY+s+a);this.w.dom.elLegendForeign&&this.w.dom.elLegendForeign.setAttribute("height",String(o)),!(i.config.chart.height&&String(i.config.chart.height).includes("%"))&&(this.w.dom.elWrap.style.height=`${o}px`,Y.setAttrs(this.w.dom.Paper.node,{height:o}),p.isBrowser()&&(this.w.dom.Paper.node.parentNode.parentNode.style.minHeight=`${o}px`))}coreCalculations(){new K(this.w).init()}resetGlobals(){let e=()=>this.w.config.series.map(()=>[]),t=new F,{globals:i}=this.w,s={dataWasParsed:this.w.axisFlags.dataWasParsed,originalSeries:i.originalSeries};t.initGlobalVars(i),i.seriesXvalues=e(),i.seriesYvalues=e(),s.dataWasParsed&&(this.w.axisFlags.dataWasParsed=s.dataWasParsed,i.originalSeries=s.originalSeries)}isMultipleY(){return!!Array.isArray(this.w.config.yaxis)&&this.w.config.yaxis.length>1&&(this.w.globals.isMultipleYAxis=!0,!0)}xySettings(){let{w:e}=this,t=null;if(e.globals.axisCharts){if("back"===e.config.xaxis.crosshairs.position&&new es(this.w).drawXCrosshairs(),"back"===e.config.yaxis[0].crosshairs.position&&new es(this.w).drawYCrosshairs(),"datetime"===e.config.xaxis.type&&void 0===e.config.xaxis.labels.formatter){this.ctx.timeScale=new ep(this.w,this.ctx);let t=[];isFinite(e.globals.minX)&&isFinite(e.globals.maxX)&&!e.globals.isBarHorizontal?t=this.ctx.timeScale.calculateTimeScaleTicks(e.globals.minX,e.globals.maxX):e.globals.isBarHorizontal&&(t=this.ctx.timeScale.calculateTimeScaleTicks(e.globals.minY,e.globals.maxY)),this.ctx.timeScale.recalcDimensionsBasedOnFormat(t)}t=new I(this.w).getCalculatedRatios()}return t}updateSourceChart(e){this.ctx.w.interact.selection=void 0,this.ctx.updateHelpers._updateOptions({chart:{selection:{xaxis:{min:e.w.globals.minX,max:e.w.globals.maxX}}}},!1,!1)}setupBrushHandler(){let{ctx:e,w:t}=this;if(t.config.chart.brush.enabled&&"function"!=typeof t.config.chart.events.selection){let i=Array.isArray(t.config.chart.brush.targets)?t.config.chart.brush.targets:[t.config.chart.brush.target];
27i.forEach(t=>{let i=e.constructor.getChartByID(t);i.w.globals.brushSource=this.ctx,"function"!=typeof i.w.config.chart.events.zoomed&&(i.w.config.chart.events.zoomed=()=>this.updateSourceChart(i)),"function"!=typeof i.w.config.chart.events.scrolled&&(i.w.config.chart.events.scrolled=()=>this.updateSourceChart(i))}),t.config.chart.events.selection=(t,s)=>{i.forEach(t=>{e.constructor.getChartByID(t).ctx.updateHelpers._updateOptions({xaxis:{min:s.xaxis.min,max:s.xaxis.max}},!1,!1,!1,!1)})}}}getAccessibleChartLabel(){let e=this.w,t=e.config;if(t.chart.accessibility&&t.chart.accessibility.description)return t.chart.accessibility.description;let i=t.chart.type,s=[];if(t.title.text)s.push(`${t.title.text}. ${i} chart`),t.subtitle.text&&s.push(t.subtitle.text);else{let a=Array.isArray(e.seriesData.seriesNames)&&e.seriesData.seriesNames.length?e.seriesData.seriesNames.filter(Boolean):Array.isArray(t.series)?t.series.map(e=>"object"==typeof e&&null!==e?e.name:null).filter(Boolean):[],r=e.seriesData.series.length||(t.series?t.series.length:0);a.length?s.push(`${i} chart with ${r} data series: ${a.join(", ")}`):s.push(`${i} chart with ${r} data series`)}return s.join(". ")}}class eb{constructor(e,{resetGlobals:t=()=>{},isMultipleY:i=()=>{}}={}){this.w=e,this.resetGlobals=t,this.isMultipleY=i,this.twoDSeries=[],this.threeDSeries=[],this.twoDSeriesX=[],this.seriesGoals=[],this.coreUtils=new I(this.w),this.activeSeriesIndex=0}getFirstDataPoint(){let e=this.w.config.series,t=new er(this.w);this.activeSeriesIndex=t.getActiveConfigSeriesIndex();let i=e[this.activeSeriesIndex];return i&&i.data&&i.data.length>0&&null!==i.data[0]&&void 0!==i.data[0]?i.data[0]:null}isMultiFormat(){return this.isFormatXY()||this.isFormat2DArray()}isFormatXY(){var e;let t=this.getFirstDataPoint();if(!t||void 0===t.x)return!1;let i=null==(e=this.w.config.series[this.activeSeriesIndex])?void 0:e.data;if(i){let e=e=>e&&void 0!==e.x;for(let t=1;t<Math.min(3,i.length);t++)if(!0!==e(i[t])){console.warn(`ApexCharts: series data has mixed formats starting at index ${t}`);break}}return!0}isFormat2DArray(){let e=this.getFirstDataPoint();return e&&Array.isArray(e)}handleFormat2DArray(e,t){let i=this.w.config,s=e[t].data,a="boxPlot"===i.chart.type||"boxPlot"===i.series[t].type;for(let e=0;e<s.length;e++){let t=s[e],r=t[0],l=t[1],o=t[2];if(void 0!==l&&(Array.isArray(l)&&4===l.length&&!a?this.twoDSeries.push(v.parseNumber(l[3])):t.length>=5?this.twoDSeries.push(v.parseNumber(t[4])):this.twoDSeries.push(v.parseNumber(l)),this.w.axisFlags.dataFormatXNumeric=!0),"datetime"===i.xaxis.type){let e=new Date(r).getTime();this.twoDSeriesX.push(e)}else this.twoDSeriesX.push(r);void 0!==o&&(this.threeDSeries.push(o),this.w.axisFlags.isDataXYZ=!0)}}handleFormatXY(e,t){let i=this.w.config,s=this.w.globals,a=new A(this.w),r=e[t].data,l=t;s.collapsedSeriesIndices.indexOf(t)>-1&&(l=this.activeSeriesIndex);let o=e[l].data;for(let e=0;e<r.length;e++){let i=r[e];if(void 0!==i.y){let e=Array.isArray(i.y)?v.parseNumber(i.y[i.y.length-1]):v.parseNumber(i.y);this.twoDSeries.push(e)}void 0===this.seriesGoals[t]&&(this.seriesGoals[t]=[]),void 0!==i.goals&&Array.isArray(i.goals)?this.seriesGoals[t].push(i.goals):this.seriesGoals[t].push(null),void 0!==i.z&&(this.threeDSeries.push(i.z),this.w.axisFlags.isDataXYZ=!0)}for(let e=0;e<o.length;e++){let t=o[e].x,r="string"==typeof t,l=Array.isArray(t),n=!l&&!!a.isValidDate(t);if(r||n)if(r||i.xaxis.convertedCatToNumeric){let e=s.isBarHorizontal&&this.w.axisFlags.isRangeData;"datetime"!==i.xaxis.type||e?(this.fallbackToCategory=!0,this.twoDSeriesX.push(t),isNaN(t)||"category"===this.w.config.xaxis.type||"string"==typeof t||(this.w.axisFlags.isXNumeric=!0)):this.twoDSeriesX.push(a.parseDate(t))}else"datetime"===i.xaxis.type?this.twoDSeriesX.push(a.parseDate(t.toString())):(this.w.axisFlags.dataFormatXNumeric=!0,this.w.axisFlags.isXNumeric=!0,this.twoDSeriesX.push(parseFloat(t)));else l?this.fallbackToCategory=!0:(this.w.axisFlags.isXNumeric=!0,this.w.axisFlags.dataFormatXNumeric=!0),this.twoDSeriesX.push(t)}}handleRangeData(e,t){let i={start:[],end:[],rangeUniques:[]};return this.isFormat2DArray()?i=this.handleRangeDataFormat("array",e,t):this.isFormatXY()&&(i=this.handleRangeDataFormat("xy",e,t)),this.w.rangeData.seriesRangeStart[t]=void 0===i.start?[]:i.start,this.w.rangeData.seriesRangeEnd[t]=void 0===i.end?[]:i.end,this.w.rangeData.seriesRange[t]=i.rangeUniques,this.w.rangeData.seriesRange.forEach(e
27=>{e&&e.forEach(e=>{let t=e.y,i=t.length;if(!(i<=1))for(let s=0;s<i;s++){let a=t[s],r=a.y1,l=a.y2;for(let o=s+1;o<i;o++){let i=t[o],s=i.y1;r<=i.y2&&s<=l&&(e.overlaps.add(a.rangeName),e.overlaps.add(i.rangeName))}}})}),i}handleCandleStickBoxData(e,t){let i={o:[],h:[],m:[],l:[],c:[]};return this.isFormat2DArray()?i=this.handleCandleStickBoxDataFormat("array",e,t):this.isFormatXY()&&(i=this.handleCandleStickBoxDataFormat("xy",e,t)),this.w.candleData.seriesCandleO[t]=i.o,this.w.candleData.seriesCandleH[t]=i.h,this.w.candleData.seriesCandleM[t]=i.m,this.w.candleData.seriesCandleL[t]=i.l,this.w.candleData.seriesCandleC[t]=i.c,i}handleRangeDataFormat(e,t,i){let s=[],a=[],r=new Map,l=[];if(t[i].data.forEach(e=>{if(!r.has(e.x)){let t={x:e.x,overlaps:new Set,y:[]};r.set(e.x,t),l.push(t)}}),"array"===e)for(let e=0;e<t[i].data.length;e++)Array.isArray(t[i].data[e])?(s.push(t[i].data[e][1][0]),a.push(t[i].data[e][1][1])):(s.push(t[i].data[e]),a.push(t[i].data[e]));else if("xy"===e)for(let e=0;e<t[i].data.length;e++){let l=Array.isArray(t[i].data[e].y),o=v.randomId(),n=t[i].data[e].x,h={y1:l?t[i].data[e].y[0]:t[i].data[e].y,y2:l?t[i].data[e].y[1]:t[i].data[e].y,rangeName:o};t[i].data[e].rangeName=o;let d=r.get(n);d&&d.y.push(h),s.push(h.y1),a.push(h.y2)}return{start:s,end:a,rangeUniques:l}}handleCandleStickBoxDataFormat(e,t,i){let s,a=this.w,r="boxPlot"===a.config.chart.type||"boxPlot"===a.config.series[i].type,l=[],o=[],n=[],h=[],d=[],c=t[i].data;s="array"===e?r&&6===c[0].length||!r&&5===c[0].length?e=>e.slice(1):e=>Array.isArray(e[1])?e[1]:[]:e=>Array.isArray(e.y)?e.y:[];for(let e=0;e<c.length;e++){let t=s(c[e]);t&&t.length>=2&&(l.push(t[0]),o.push(t[1]),r?(n.push(t[2]),h.push(t[3]),d.push(t[4])):(h.push(t[2]),d.push(t[3])))}return{o:l,h:o,m:n,l:h,c:d}}parseDataAxisCharts(e){var t,i;let s=this.w.config,a=this.w.globals,r=new A(this.w),l=s.labels.length>0?s.labels.slice():s.xaxis.categories.slice();this.w.axisFlags.isRangeBar="rangeBar"===s.chart.type&&a.isBarHorizontal,this.w.labelData.hasXaxisGroups="category"===s.xaxis.type&&s.xaxis.group.groups.length>0,this.w.labelData.hasXaxisGroups&&(this.w.labelData.groups=s.xaxis.group.groups),e.forEach((e,t)=>{void 0!==e.name?this.w.seriesData.seriesNames.push(e.name):this.w.seriesData.seriesNames.push("series-"+parseInt(String(t+1),10))}),this.coreUtils.setSeriesYAxisMappings();let o=[],n=[...new Set(s.series.map(e=>e.group))];s.series.forEach((e,t)=>{let i=n.indexOf(e.group);o[i]||(o[i]=[]),o[i].push(this.w.seriesData.seriesNames[t])}),this.w.labelData.seriesGroups=o;let h=()=>{for(let e=0;e<l.length;e++)if("string"==typeof l[e])if(r.isValidDate(l[e]))this.twoDSeriesX.push(r.parseDate(l[e]));else throw Error("You have provided invalid Date format. Please provide a valid JavaScript Date");else this.twoDSeriesX.push(l[e])};for(let a=0;a<e.length;a++){if(this.twoDSeries=[],this.twoDSeriesX=[],this.threeDSeries=[],void 0===e[a].data)return void console.error("It is a possibility that you may have not included 'data' property in series.");let r=s.chart.dataReducer;if((null==r?void 0:r.enabled)&&this.isMultiFormat()&&e[a].data.length>(null!=(t=r.threshold)?t:500)&&(e[a]=c(d({},e[a]),{data:eb.lttbDownsample(e[a].data,null!=(i=r.targetPoints)?i:250)})),("rangeBar"===s.chart.type||"rangeArea"===s.chart.type||"rangeBar"===e[a].type||"rangeArea"===e[a].type)&&(this.w.axisFlags.isRangeData=!0,this.handleRangeData(e,a)),this.isMultiFormat())this.isFormat2DArray()?this.handleFormat2DArray(e,a):this.isFormatXY()&&this.handleFormatXY(e,a),("candlestick"===s.chart.type||"candlestick"===e[a].type||"boxPlot"===s.chart.type||"boxPlot"===e[a].type)&&this.handleCandleStickBoxData(e,a),this.w.seriesData.series.push(this.twoDSeries),this.w.labelData.labels.push(this.twoDSeriesX),this.w.seriesData.seriesX.push(this.twoDSeriesX),this.w.seriesData.seriesGoals=this.seriesGoals,a!==this.activeSeriesIndex||this.fallbackToCategory||(this.w.axisFlags.isXNumeric=!0);else{"datetime"===s.xaxis.type?(this.w.axisFlags.isXNumeric=!0,h(),this.w.seriesData.seriesX.push(this.twoDSeriesX)):"numeric"===s.xaxis.type&&(this.w.axisFlags.isXNumeric=!0,l.length>0&&(this.twoDSeriesX=l,this.w.seriesData.seriesX.push(this.twoDSeriesX))),this.w.labelData.labels.push(this.twoDSeriesX);let t=e[a].data.map(e=>v.parseNumber(e));this.w.seriesData.series.push(t)}
27this.w.seriesData.seriesZ.push(this.threeDSeries),void 0!==e[a].color?this.w.seriesData.seriesColors.push(e[a].color):this.w.seriesData.seriesColors.push(void 0)}return this.w}parseDataNonAxisCharts(e){let t=this.w.config,i=Array.isArray(e)&&e.every(e=>"number"==typeof e)&&t.labels.length>0,s=Array.isArray(e)&&e.some(e=>e&&"object"==typeof e&&e.data||e&&"object"==typeof e&&e.parsing);if(i&&s&&console.warn("ApexCharts: Both old format (numeric series + labels) and new format (series objects with data/parsing) detected. Using old format for backward compatibility."),i){this.w.seriesData.series=e.slice(),this.w.seriesData.seriesNames=t.labels.slice();for(let e=0;e<this.w.seriesData.series.length;e++)void 0===this.w.seriesData.seriesNames[e]&&this.w.seriesData.seriesNames.push("series-"+(e+1));return this.w}if(Array.isArray(e)&&e.every(e=>"number"==typeof e)){this.w.seriesData.series=e.slice(),this.w.seriesData.seriesNames=[];for(let e=0;e<this.w.seriesData.series.length;e++)this.w.seriesData.seriesNames.push(t.labels[e]||`series-${e+1}`);return this.w}let a=this.extractPieDataFromSeries(e);this.w.seriesData.series=a.values,this.w.seriesData.seriesNames=a.labels,"radialBar"===t.chart.type&&(this.w.seriesData.series=this.w.seriesData.series.map(e=>{let t=v.parseNumber(e);return t>100&&console.warn(`ApexCharts: RadialBar value ${t} > 100, consider using percentage values (0-100)`),t}));for(let e=0;e<this.w.seriesData.series.length;e++)void 0===this.w.seriesData.seriesNames[e]&&this.w.seriesData.seriesNames.push("series-"+(e+1));return this.w}resetParsingFlags(){let e=this.w;e.axisFlags.dataWasParsed=!1,e.globals.originalSeries=null,e.config.series&&e.config.series.forEach(e=>{e.__apexParsed&&delete e.__apexParsed})}extractPieDataFromSeries(e){let t=[],i=[];if(!Array.isArray(e))return console.warn("ApexCharts: Expected array for series data"),{values:[],labels:[]};if(0===e.length)return console.warn("ApexCharts: Empty series array"),{values:[],labels:[]};let s=e[0];return"object"==typeof s&&null!==s&&s.data?(this.extractPieDataFromSeriesObjects(e,t,i),{values:t,labels:i}):(console.warn("ApexCharts: Unsupported series format for pie/donut/radialBar. Expected series objects with data property."),{values:[],labels:[]})}extractPieDataFromSeriesObjects(e,t,i){e.forEach((e,s)=>{e.data&&Array.isArray(e.data)?e.data.forEach(e=>{"object"==typeof e&&null!==e?void 0!==e.x&&void 0!==e.y?(i.push(String(e.x)),t.push(v.parseNumber(e.y))):console.warn("ApexCharts: Invalid data point format for pie chart. Expected {x, y} format:",e):console.warn("ApexCharts: Expected object data point, got:",typeof e)}):console.warn(`ApexCharts: Series ${s} has no valid data array`)})}handleExternalLabelsData(e){let t=this.w.config;if(t.xaxis.categories.length>0)this.w.labelData.labels=t.xaxis.categories;else if(t.labels.length>0)this.w.labelData.labels=t.labels.slice();else if(this.fallbackToCategory){if(this.w.labelData.labels=this.w.labelData.labels[0],this.w.rangeData.seriesRange.length){this.w.rangeData.seriesRange.map(e=>{e.forEach(e=>{0>this.w.labelData.labels.indexOf(e.x)&&e.x&&this.w.labelData.labels.push(e.x)})});let e=this.w.labelData.labels;if(e.length>0&&("number"==typeof e[0]||"string"==typeof e[0]))this.w.labelData.labels=[...new Set(e)];else{let t=new Map;for(let i of e){let e=JSON.stringify(i);t.has(e)||t.set(e,i)}this.w.labelData.labels=Array.from(t.values())}}t.xaxis.convertedCatToNumeric&&(new D(t).convertCatToNumericXaxis(t,this.w.seriesData.seriesX[0]),this._generateExternalLabels(e))}else this._generateExternalLabels(e)}_generateExternalLabels(e){let t=this.w.globals,i=this.w.config,s=[];if(t.axisCharts){if(this.w.seriesData.series.length>0)if(this.isFormatXY()){let e=i.series.map(e=>{let t=new Map;for(let i of e.data)t.has(i.x)||t.set(i.x,i);return Array.from(t.values())}),t=e.reduce((e,t,i,s)=>s[e].length>t.length?e:i,0);for(let i=0;i<e[t].length;i++)s.push(i+1)}else for(let e=0;e<this.w.seriesData.series[t.maxValsInArrayIndex].length;e++)s.push(e+1);this.w.seriesData.seriesX=[];for(let t=0;t<e.length;t++)this.w.seriesData.seriesX.push(s);this.w.globals.isBarHorizontal||(this.w.axisFlags.isXNumeric=!0)}if(0===s.length){s=t.axisCharts?[]:this.w.seriesData.series.map((e,t)=>t+1);for(let t=0;t<e.length;t++)this.w.seriesData.seriesX.push(s)}this.w.labelData.labels=s,i.xaxis.convertedCatToNumeric&&(this.w.labelData.categoryLabels=s.map(e=>
27i.xaxis.labels.formatter(e))),this.w.axisFlags.noLabelsProvided=!0}parseRawDataIfNeeded(e){let t=this.w.config,i=this.w.globals,s=t.parsing;if(this.w.axisFlags.dataWasParsed||!s&&!e.some(e=>e.parsing))return e;let a=e.map((e,t)=>{var i,a,r;if(!e.data||!Array.isArray(e.data)||0===e.data.length)return e;let l={x:(null==(i=e.parsing)?void 0:i.x)||(null==s?void 0:s.x),y:(null==(a=e.parsing)?void 0:a.y)||(null==s?void 0:s.y),z:(null==(r=e.parsing)?void 0:r.z)||(null==s?void 0:s.z)};if(!l.x&&!l.y)return e;let o=e.data[0];if("object"==typeof o&&null!==o&&(Object.prototype.hasOwnProperty.call(o,"x")||Object.prototype.hasOwnProperty.call(o,"y"))||Array.isArray(o))return e;if(!l.x||!l.y||Array.isArray(l.y)&&0===l.y.length)return console.warn(`ApexCharts: Series ${t} has parsing config but missing x or y field specification`),e;let n=e.data.map((e,i)=>{let s,a;if("object"!=typeof e||null===e)return console.warn(`ApexCharts: Series ${t}, data point ${i} is not an object, skipping parsing`),e;let r=this.getNestedValue(e,l.x);if(Array.isArray(l.y)){let i=l.y.map(t=>this.getNestedValue(e,t));"bubble"===this.w.config.chart.type?(i.length<2&&console.warn(`ApexCharts: series[${t}] bubble chart requires parseData.y to have at least 2 fields (y and z). Got: ${JSON.stringify(l.y)}`),s=i[0]):s=i}else s=this.getNestedValue(e,l.y);l.z&&(a=this.getNestedValue(e,l.z)),void 0===r&&console.warn(`ApexCharts: Series ${t}, data point ${i} missing field '${l.x}'`),void 0===s&&console.warn(`ApexCharts: Series ${t}, data point ${i} missing field '${l.y}'`);let o={x:r,y:s,z:void 0};if("bubble"===this.w.config.chart.type&&Array.isArray(l.y)&&2===l.y.length){let t=this.getNestedValue(e,l.y[1]);void 0!==t&&(o.z=t)}return void 0!==a&&(o.z=a),o});return c(d({},e),{data:n,__apexParsed:!0})});return this.w.axisFlags.dataWasParsed=!0,i.originalSeries||(i.originalSeries=v.clone(e)),a}getNestedValue(e,t){if(!e||"object"!=typeof e||!t)return;if(-1===t.indexOf("."))return e[t];let i=t.split("."),s=e;for(let e=0;e<i.length;e++){if(null==s||"object"!=typeof s)return;s=s[i[e]]}return s}parseData(e){let t=this.w,i=t.config,s=t.globals;if(i.series=e=this.parseRawDataIfNeeded(e),s.initialSeries=v.clone(e),this.excludeCollapsedSeriesInYAxis(),this.fallbackToCategory=!1,this.resetGlobals(),this.isMultipleY(),s.axisCharts?(this.parseDataAxisCharts(e),this.coreUtils.getLargestSeries()):this.parseDataNonAxisCharts(e),i.chart.stacked){let e=new er(this.w);this.w.seriesData.series=e.setNullSeriesToZeroValues(this.w.seriesData.series)}this.coreUtils.getSeriesTotals(),s.axisCharts&&(this.w.seriesData.stackedSeriesTotals=this.coreUtils.getStackedSeriesTotals(),this.w.seriesData.stackedSeriesTotalsByGroups=this.coreUtils.getStackedSeriesTotalsByGroups()),this.coreUtils.getPercentSeries(),this.w.axisFlags.dataFormatXNumeric||this.w.axisFlags.isXNumeric&&("numeric"!==i.xaxis.type||0!==i.labels.length||0!==i.xaxis.categories.length)||this.handleExternalLabelsData(e);let a=this.coreUtils.getCategoryLabels(this.w.labelData.labels);for(let e=0;e<a.length;e++)if(Array.isArray(a[e])){this.w.axisFlags.isMultiLineX=!0;break}return{seriesData:{series:this.w.seriesData.series,seriesNames:this.w.seriesData.seriesNames,seriesX:this.w.seriesData.seriesX,seriesZ:this.w.seriesData.seriesZ,seriesColors:this.w.seriesData.seriesColors,seriesGoals:this.w.seriesData.seriesGoals,initialSeries:s.initialSeries,originalSeries:s.originalSeries,stackedSeriesTotals:this.w.seriesData.stackedSeriesTotals,stackedSeriesTotalsByGroups:this.w.seriesData.stackedSeriesTotalsByGroups,noLabelsProvided:this.w.axisFlags.noLabelsProvided},rangeData:{seriesRangeStart:this.w.rangeData.seriesRangeStart,seriesRangeEnd:this.w.rangeData.seriesRangeEnd,seriesRange:this.w.rangeData.seriesRange},candleData:{seriesCandleO:this.w.candleData.seriesCandleO,seriesCandleH:this.w.candleData.seriesCandleH,seriesCandleM:this.w.candleData.seriesCandleM,seriesCandleL:this.w.candleData.seriesCandleL,seriesCandleC:this.w.candleData.seriesCandleC},labelData:{labels:this.w.labelData.labels,categoryLabels:this.w.labelData.categoryLabels},axisFlags:{isXNumeric:this.w.axisFlags.isXNumeric,dataFormatXNumeric:this.w.axisFlags.dataFormatXNumeric,isDataXYZ:this.w.axisFlags.isDataXYZ,isRangeData:this.w.axisFlags.isRangeData,isRangeBar:this.w.axisFlags.isRangeBar,isMultiLineX:this.w.axisFlags.isMultiLineX,dataWasParsed:this.w.axisFlags.dataWasParsed,hasXaxisGroups:this.w.labelData.hasXaxisGroups,groups:this.w.labelData.groups,seriesGroups:this.w.labelData.seriesGroups}}}static lttbDownsample(e,t){let i=e.length;if(t>=i||t<3)return e;let s=!Array.isArray(e[0]),a=s?e=>e.x:e=>e[0],r=s?e=>e.y:e=>e[1],l=[];l.push(e[0]);let o=(i-2)/(t-2),n=0;for(let s=0;s<t-2;s++){let t=Math.floor((s+1)*o)+1,h=Math.min(Math.floor((s+2)*o)+1,i),d=0,c=0,g=h-t;
27for(let i=t;i<h;i++)d+=a(e[i]),c+=r(e[i]);d/=g,c/=g;let p=Math.floor(s*o)+1,x=Math.min(Math.floor((s+1)*o)+1,i),u=a(e[n]),f=r(e[n]),m=-1,b=p;for(let t=p;t<x;t++){let i=.5*Math.abs((u-d)*(r(e[t])-f)-(u-a(e[t]))*(c-f));i>m&&(m=i,b=t)}l.push(e[b]),n=b}return l.push(e[i-1]),l}excludeCollapsedSeriesInYAxis(){let e=this.w,t=[];e.globals.seriesYAxisMap.forEach((i,s)=>{let a=0;i.forEach(t=>{-1!==e.globals.collapsedSeriesIndices.indexOf(t)&&a++}),a>0&&a==i.length&&t.push(s)}),e.globals.ignoreYAxisIndexes=t.map(e=>e)}}class ey{constructor(e,t){this.w=e,this.ctx=t}_updateOptions(e,t=!1,i=!0,s=!0,a=!1){return new Promise(r=>{let l=[this.ctx];s&&(l=this.ctx.getSyncedCharts()),this.w.globals.isExecCalled&&(l=[this.ctx],this.w.globals.isExecCalled=!1),l.forEach((s,o)=>{let n=s.w;if(n.globals.shouldAnimate=i,!t&&(n.globals.resized=!0,n.globals.dataChanged=!0,i&&s.series.getPreviousPaths()),e&&"object"==typeof e&&(s.config=new P(e),e=I.extendArrayProps(s.config,e,n),s.w.globals.chartID!==this.w.globals.chartID&&delete e.series,n.config=v.extend(n.config,e),a)&&(n.globals.lastXAxis=e.xaxis?v.clone(e.xaxis):[],n.globals.lastYAxis=e.yaxis?v.clone(e.yaxis):[],n.globals.initialConfig=v.extend({},n.config),n.globals.initialSeries=v.clone(n.config.series),e.series)){for(let e=0;e<n.globals.collapsedSeriesIndices.length;e++){let t=n.config.series[n.globals.collapsedSeriesIndices[e]];n.globals.collapsedSeries[e].data=n.globals.axisCharts?t.data.slice():t}for(let e=0;e<n.globals.ancillaryCollapsedSeriesIndices.length;e++){let t=n.config.series[n.globals.ancillaryCollapsedSeriesIndices[e]];n.globals.ancillaryCollapsedSeries[e].data=n.globals.axisCharts?t.data.slice():t}s.series.emptyCollapsedSeries(n.config.series)}return s.update(e).then(()=>{o===l.length-1&&r(s)})})})}_updateSeries(e,t,i=!1){return new Promise(s=>{let a=this.w;a.globals.shouldAnimate=t,a.globals.dataChanged=!0,V.invalidateSelectors(a),t&&this.ctx.series.getPreviousPaths();let r=a.config.series.length;this.ctx.data.resetParsingFlags();let l=this.ctx.data.parseData(e);return(this.ctx._writeParsedSeriesData(l.seriesData),this.ctx._writeParsedRangeData(l.rangeData),this.ctx._writeParsedCandleData(l.candleData),this.ctx._writeParsedLabelData(l.labelData),this.ctx._writeParsedAxisFlags(l.axisFlags),i&&(a.globals.initialConfig&&(a.globals.initialConfig.series=v.clone(a.config.series)),a.globals.initialSeries=v.clone(a.config.series)),this._canUseFastPath(e,r,a))?this.ctx.fastUpdate(t).then(()=>{s(this.ctx)}):this.ctx.update().then(()=>{s(this.ctx)})})}_canUseFastPath(e,t,i){return!!i.dom.elGraphical&&!!i.globals.axisCharts&&e.length===t&&!(i.globals.collapsedSeries.length>0)&&!(i.globals.ancillaryCollapsedSeries.length>0)&&!(i.globals.risingSeries.length>0)&&!i.globals.comboCharts&&!i.interact.zoomed&&!0}_extendSeries(e,t){let i=this.w,s=i.config.series[t];return c(d({},i.config.series[t]),{name:e.name?e.name:null==s?void 0:s.name,color:e.color?e.color:null==s?void 0:s.color,type:e.type?e.type:null==s?void 0:s.type,group:e.group?e.group:null==s?void 0:s.group,hidden:void 0!==e.hidden?e.hidden:null==s?void 0:s.hidden,data:e.data?e.data:null==s?void 0:s.data,zIndex:void 0!==e.zIndex?e.zIndex:t})}toggleDataPointSelection(e,t){let i=this.w,s=null,a=`.apexcharts-series[data\\:realIndex='${e}']`;return(i.globals.axisCharts?s=i.dom.Paper.findOne(`${a} path[j='${t}'], ${a} circle[j='${t}'], ${a} rect[j='${t}']`):void 0===t&&(s=i.dom.Paper.findOne(`${a} path[j='${e}']`),("pie"===i.config.chart.type||"polarArea"===i.config.chart.type||"donut"===i.config.chart.type)&&this.ctx.pie.pieClicked(e)),s)?(new Y(this.w).pathMouseDown(s,null),s.node?s.node:null):(console.warn("toggleDataPointSelection: Element not found"),null)}forceXAxisUpdate(e){let t=this.w;return["min","max"].forEach(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&&(e=new D(e).convertCatToNumericXaxis(e,this.ctx)),e}forceYAxisUpdate(e){return e.chart&&e.chart.stacked&&"100%"===e.chart.stackType&&(Array.isArray(e.yaxis)?e.yaxis.forEach((t,i)=>{e.yaxis[i].min=0,e.yaxis[i].max=100}):(e.yaxis.min=0,e.yaxis.max=100)),e}revertDefaultAxisMinMax(e){let t=this.w,i=t.globals.lastXAxis,s=t.globals.lastYAxis;e&&e.xaxis&&(i=e.xaxis),e&&e.yaxis&&(s=e.yaxis);let a=i;t.config.xaxis.min=a.min,t.config.xaxis.max=a.max;t.config.yaxis.map((e,i)=>{t.interact.zoomed||void 0!==s[i]?(e=>{if(void 0!==s[e]){let i=s[e];t.config.yaxis[e].min=i.min,t.config.yaxis[e].max=i.max}})(i):void 0!==this.ctx.opts.yaxis[i]&&(e.min=this.ctx.opts.yaxis[i].min,e.max=this.ctx.opts.yaxis[i].max)})}}class ew{constructor(e){this.w=e.w,this.ttCtx=e}getNearestValues({hoverArea:e,elGrid:t,clientX:i,clientY:s}){var a,r;let l=this.w,o=t.getBoundingClientRect(),n=o.width,h=o.height,d=n/(l.globals.dataPoints-1),c=h/l.globals.dataPoints,g=this.hasBars();(l.globals.comboCharts||g)&&!l.config.xaxis.convertedCatToNumeric&&(d=n/l.globals.dataPoints);let p=i-o.left-l.globals.barPadForNumericAxis,x=s-o.top;p<0||x<0||p>n||x>h?(e.classList.remove("hovering-zoom"),e.classList.remove("hovering-pan")):l.interact.zoomEnabled?(e.classList.remove("hovering-pan"),e.classList.add("hovering-zoom")):l.interact.panEnabled&&(e.classList.remove("hovering-zoom"),e.classList.add("hovering-pan"));let u=Math.round(p/d),f=Math.floor(x/c);g&&!l.config.xaxis.convertedCatToNumeric&&(u=Math.ceil(p/d)-1);let m=null,b=null,y=l.globals.seriesXvalues.map(e=>e.filter(e=>v.isNumber(e))),w=l.globals.seriesYvalues.map(e=>e.filter(e=>v.isNumber(e)));if(l.axisFlags.isXNumeric){let e=this.ttCtx.getElGrid();if(!e)return{hoverX:p,hoverY:x};let t=e.getBoundingClientRect(),i=p*(t.width/n),s=x*(t.height/h);m=(b=this.closestInMultiArray(i,s,y,w)).index,u=null!=(a=b.j)?a:0,null!==m&&l.globals.hasNullValues&&(y=l.globals.seriesXvalues[m],u=null!=(r=(b=this.closestInArray(i,y)).j)?r:0)}return l.interact.capturedSeriesIndex=null===m?-1:m,(!u||u<1)&&(u=0),l.globals.isBarHorizontal?l.interact.capturedDataPointIndex=f:l.interact.capturedDataPointIndex=u,{capturedSeries:m,j:l.globals.isBarHorizontal?f:u,hoverX:p,hoverY:x}}getFirstActiveXArray(e){let t=this.w,i=0,s=e.map((e,t)=>e.length>0?t:-1);for(let e=0;e<s.length;e++)if(-1!==s[e]&&-1===t.globals.collapsedSeriesIndices.indexOf(e)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(e)){i=s[e];break}return i}closestInMultiArray(e,t,i,s){let a=this.w,r=e=>-1===a.globals.collapsedSeriesIndices.indexOf(e)&&-1===a.globals.ancillaryCollapsedSeriesIndices.indexOf(e),l=a.config.chart.type,o=!a.globals.comboCharts&&("line"===l||"area"===l),n=1/0,h=null,d=null,c=a.config.tooltip.shared&&a.globals.allSeriesHasEqualX&&this.hasBars();for(let a=0;a<i.length;a++){if(!r(a))continue;let l=i[a],g=s[a],p=Math.min(l.length,g.length);if(o&&p>=2){for(let i=0;i<p-1;i++){let s=this._distanceToSegment(e,t,l[i],g[i],l[i+1],g[i+1]);s.dist<n&&(n=s.dist,h=a,d=s.t<.5?i:i+1)}continue}for(let i=0;i<p;i++){let s=e-l[i],r=Math.sqrt(s*s);if(!c){let e=t-g[i];r=Math.sqrt(s*s+e*e)}r<n&&(n=r,h=a,d=i)}}return{index:h,j:d}}_distanceToSegment(e,t,i,s,a,r){let l=a-i,o=r-s,n=l*l+o*o,h=0===n?0:((e-i)*l+(t-s)*o)/n;h<0?h=0:h>1&&(h=1);let d=e-(i+h*l),c=t-(s+h*o);return{dist:Math.sqrt(d*d+c*c),t:h}}closestInArray(e,t){let i=t[0],s=null,a=Math.abs(e-i);for(let i=0;i<t.length;i++){let r=Math.abs(e-t[i]);r<a&&(a=r,s=i)}return{j:s}}isXoverlap(e){let t=this.w,i=[],s=t.seriesData.seriesX.filter(e=>void 0!==e[0]);if(s.length>0)for(let t=0;t<s.length-1;t++)void 0!==s[t][e]&&void 0!==s[t+1][e]&&s[t][e]!==s[t+1][e]&&i.push("unEqual");return 0===i.length}isInitialSeriesSameLen(){var e,t,i;let s=!0,a=(null==(e=this.w.globals.initialSeries)?void 0:e.filter((e,t)=>
27{var i;return!(null==(i=this.w.globals.collapsedSeriesIndices)?void 0:i.includes(t))}))||[];for(let e=0;e<a.length-1;e++){if(!(null==(t=a[e])?void 0:t.data)||!(null==(i=a[e+1])?void 0:i.data))return!0;if(a[e].data.length!==a[e+1].data.length){s=!1;break}}return s}getBarsHeight(e){return[...e].reduce((e,t)=>e+t.getBBox().height,0)}getElMarkers(e){return"number"==typeof e?this.w.dom.baseEl.querySelectorAll(`.apexcharts-series[data\\:realIndex='${e}'] .apexcharts-series-markers-wrap > *`):this.w.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap > *")}getAllMarkers(e=!1){let t=[...this.w.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap")];e&&(t=t.filter(e=>{let t=Number(e.getAttribute("data:realIndex"));return -1===this.w.globals.collapsedSeriesIndices.indexOf(t)})),t.sort((e,t)=>{var i=Number(e.getAttribute("data:realIndex")),s=Number(t.getAttribute("data:realIndex"));return s<i?1:s>i?-1:0});let i=[];return t.forEach(e=>{i.push(e.querySelector(".apexcharts-marker"))}),i}hasMarkers(e){return this.getElMarkers(e).length>0}getPathFromPoint(e,t){let i=Number(e.getAttribute("cx")),s=Number(e.getAttribute("cy")),a=e.getAttribute("shape");return new Y(this.w).getMarkerPath(i,s,a,t)}getElBars(){return this.w.dom.baseEl.querySelectorAll(".apexcharts-bar-series,  .apexcharts-candlestick-series, .apexcharts-boxPlot-series, .apexcharts-rangebar-series")}hasBars(){return this.getElBars().length>0}getHoverMarkerSize(e){let 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}toggleAllTooltipSeriesGroups(e){let t=this.w,i=this.ttCtx;0===i.allTooltipSeriesGroups.length&&(i.allTooltipSeriesGroups=t.dom.baseEl.querySelectorAll(".apexcharts-tooltip-series-group"));let s=i.allTooltipSeriesGroups;for(let i=0;i<s.length;i++)"enable"===e?(s[i].classList.add("apexcharts-active"),s[i].style.display=t.config.tooltip.items.display):(s[i].classList.remove("apexcharts-active"),s[i].style.display="none")}}class ev{constructor(e){this.w=e.w,this.ttCtx=e,this.tooltipUtil=new ew(e)}drawSeriesTexts({shared:e=!0,ttItems:t,i=0,j:s=null,y1:a,y2:r,e:l}){let o=this.w;void 0!==o.config.tooltip.custom?this.handleCustomTooltip({i,j:s,y1:a,y2:r,w:o}):this.toggleActiveInactiveSeries(e,i);let n=this.getValuesToPrint({i,j:s});this.printLabels({i,j:s,values:n,ttItems:t,shared:e,e:l});let h=this.ttCtx.getElTooltip();h&&(this.ttCtx.tooltipRect.ttWidth=h.getBoundingClientRect().width,this.ttCtx.tooltipRect.ttHeight=h.getBoundingClientRect().height)}printLabels({i:e,j:t,values:i,ttItems:s,shared:a,e:r}){var l;let o,n=this.w,h=[],g=e=>n.seriesData.seriesGoals[e]&&n.seriesData.seriesGoals[e][t]&&Array.isArray(n.seriesData.seriesGoals[e][t]),{xVal:p,zVal:x,xAxisTTVal:u}=i,f="",m=n.globals.colors[e];null!==t&&n.config.plotOptions.bar.distributed&&(m=n.globals.colors[t]);for(let i=0,b=n.seriesData.series.length-1;i<n.seriesData.series.length;i++,b--){let y=this.getFormatters(e);f=this.getSeriesName({fn:y.yLbTitleFormatter,index:e,seriesIndex:e,j:t}),"treemap"===n.config.chart.type&&(f=y.yLbTitleFormatter(String(n.config.series[e].data[t].x),{series:n.seriesData.series,seriesIndex:e,dataPointIndex:t,w:n}));let w=n.config.tooltip.inverseOrder?b:i;if(n.globals.axisCharts){let i=e=>{var i,s,a,r;return n.axisFlags.isRangeData?y.yLbFormatter(null==(s=null==(i=n.rangeData.seriesRangeStart)?void 0:i[e])?void 0:s[t],{series:n.rangeData.seriesRangeStart,seriesIndex:e,dataPointIndex:t,w:n})+" - "+y.yLbFormatter(null==(r=null==(a=n.rangeData.seriesRangeEnd)?void 0:a[e])?void 0:r[t],{series:n.rangeData.seriesRangeEnd,seriesIndex:e,dataPointIndex:t,w:n}):y.yLbFormatter(n.seriesData.series[e][t],{series:n.seriesData.series,seriesIndex:e,dataPointIndex:t,w:n})};if(a)y=this.getFormatters(w),f=this.getSeriesName({fn:y.yLbTitleFormatter,index:w,seriesIndex:e,j:t}),m=n.globals.colors[w],o=i(w),g(w)&&(h=n.seriesData.seriesGoals[w][t].map(e=>({attrs:e,val:y.yLbFormatter(e.value,{seriesIndex:w,dataPointIndex:t,w:n})})));else{let s=null==(l=null==r?void 0:r.target)?void 0:l.getAttribute("fill");s&&(-1!==s.indexOf("url")?-1!==s.indexOf("Pattern")&&(m=n.dom.baseEl.querySelector(s.substr(4).slice(0,-1)).childNodes[0].getAttribute("stroke")):m=s),o=i(e),g(e)&&Array.isArray(n.seriesData.seriesGoals[e][t])&&(h=n.seriesData.seriesGoals[e][t].map(i=>({attrs:i,val:y.yLbFormatter(i.value,{seriesIndex:e,dataPointIndex:t,w:n})})))}}null===t&&(o=y.yLbFormatter(n.seriesData.series[e],c(d({},n),{seriesIndex:e,dataPointIndex:e}))),this.DOMHandling({i:e,t:w,j:t,ttItems:s,values:{val:o,goalVals:h,xVal:p,xAxisTTVal:u,zVal:x},seriesName:f,shared:a,pColor:m})}}getFormatters(e){let t,i=this.w,s=i.formatters.yLabelFormatters[e];return void 0!==i.formatters.ttVal?Array.isArray(i.formatters.ttVal)?(s=i.formatters.ttVal[e]&&i.formatters.ttVal[e].formatter,t=i.formatters.ttVal[e]&&i.formatters.ttVal[e].title&&i.formatters.ttVal[e].title.formatter):(s=i.formatters.ttVal.formatter,"function"==typeof i.formatters.ttVal.title.formatter&&(t=i.formatters.ttVal.title.formatter)):t=i.config.tooltip.y.title.formatter,"function"!=typeof s&&(s=i.formatters.yLabelFormatters[
270]?i.formatters.yLabelFormatters[0]:function(e){return e}),"function"!=typeof t&&(t=function(e){return e?e+": ":""}),{yLbFormatter:s,yLbTitleFormatter:t}}getSeriesName({fn:e,index:t,seriesIndex:i,j:s}){let a=this.w;return e(String(a.seriesData.seriesNames[t]),{series:a.seriesData.series,seriesIndex:i,dataPointIndex:s,w:a})}DOMHandling({t:e,j:t,ttItems:i,values:s,seriesName:a,shared:r,pColor:l}){let o=this.w,n=this.ttCtx,{val:h,goalVals:d,xVal:c,xAxisTTVal:g,zVal:p}=s,x=null;x=i[e].children,o.config.tooltip.fillSeriesColor&&(i[e].style.backgroundColor=l,x[0].style.display="none"),n.showTooltipTitle&&(null===n.tooltipTitle&&(n.tooltipTitle=o.dom.baseEl.querySelector(".apexcharts-tooltip-title")),n.tooltipTitle&&(n.tooltipTitle.innerHTML=c)),n.isXAxisTooltipEnabled&&n.xaxisTooltipText&&(n.xaxisTooltipText.innerHTML=""!==g?g:c);let u=i[e].querySelector(".apexcharts-tooltip-text-y-label");u&&(u.innerHTML=a||"");let f=i[e].querySelector(".apexcharts-tooltip-text-y-value");f&&(f.innerHTML=void 0!==h?h:""),x[0]&&x[0].classList.contains("apexcharts-tooltip-marker")&&(o.config.tooltip.marker.fillColors&&Array.isArray(o.config.tooltip.marker.fillColors)&&(l=o.config.tooltip.marker.fillColors[e]),o.config.tooltip.fillSeriesColor?x[0].style.backgroundColor=l:x[0].style.color=l),o.config.tooltip.marker.show||(x[0].style.display="none");let m=i[e].querySelector(".apexcharts-tooltip-text-goals-label"),b=i[e].querySelector(".apexcharts-tooltip-text-goals-value");if(d.length&&o.seriesData.seriesGoals[e]){let i=()=>{let e="<div>",t="<div>";d.forEach(i=>{e+=` <div style="display: flex"><span class="apexcharts-tooltip-marker" style="background-color: ${i.attrs.strokeColor}; height: 3px; border-radius: 0; top: 5px;"></span> ${i.attrs.name}</div>`,t+=`<div>${i.val}</div>`}),m.innerHTML=e+"</div>",b.innerHTML=t+"</div>"};r?o.seriesData.seriesGoals[e][t]&&Array.isArray(o.seriesData.seriesGoals[e][t])?i():(m.innerHTML="",b.innerHTML=""):i()}else m.innerHTML="",b.innerHTML="";if(null!==p&&(i[e].querySelector(".apexcharts-tooltip-text-z-label").innerHTML=o.config.tooltip.z.title,i[e].querySelector(".apexcharts-tooltip-text-z-value").innerHTML=void 0!==p?p:""),r&&x[0]){if(o.config.tooltip.hideEmptySeries){let t=i[e].querySelector(".apexcharts-tooltip-marker"),s=i[e].querySelector(".apexcharts-tooltip-text");0==parseFloat(h)?(t.style.display="none",s.style.display="none"):(t.style.display="block",s.style.display="block")}null==h||o.globals.ancillaryCollapsedSeriesIndices.indexOf(e)>-1||o.globals.collapsedSeriesIndices.indexOf(e)>-1||Array.isArray(n.tConfig.enabledOnSeries)&&-1===n.tConfig.enabledOnSeries.indexOf(e)?x[0].parentNode.style.display="none":x[0].parentNode.style.display=o.config.tooltip.items.display}else Array.isArray(n.tConfig.enabledOnSeries)&&-1===n.tConfig.enabledOnSeries.indexOf(e)&&(x[0].parentNode.style.display="none")}toggleActiveInactiveSeries(e,t){let i=this.w;if(e)this.tooltipUtil.toggleAllTooltipSeriesGroups("enable");else{this.tooltipUtil.toggleAllTooltipSeriesGroups("disable");let e=i.dom.baseEl.querySelector(`.apexcharts-tooltip-series-group-${t}`);e&&(e.classList.add("apexcharts-active"),e.style.display=i.config.tooltip.items.display)}}getValuesToPrint({i:e,j:t}){var i,s,a,r,l,o,n,h;let d=this.w,c=d.seriesData.seriesX.map(e=>e.length>0?e:[]),g="",p="",x=null,u=null,f={series:d.seriesData.series,seriesIndex:e,dataPointIndex:t,w:d},m=d.formatters.ttZFormatter;if(null===t)u=d.seriesData.series[e];else if(d.axisFlags.isXNumeric&&"treemap"!==d.config.chart.type){if(g=c[e][t],0===c[e].length){let e=this.tooltipUtil.getFirstActiveXArray(c);g=c[e][t]}}else g=new eb(this.w).isFormatXY()?void 0!==d.config.series[e].data[t]?d.config.series[e].data[t].x:"":void 0!==d.labelData.labels[t]?d.labelData.labels[t]:"";let b=g;return g=d.axisFlags.isXNumeric&&"datetime"===d.config.xaxis.type?new C(this.w).xLabelFormat(d.formatters.ttKeyFormatter,b,b,{i:void 0,dateFormatter:new A(this.w).formatDate,w:this.w}):d.globals.isBarHorizontal?d.formatters.yLabelFormatters[0](b,f):null!=(a=null==(s=(i=d.formatters).xLabelFormatter)?void 0:s.call(i,b,f))?a:b,void 0!==d.config.tooltip.x.formatter&&(g=null!=(o=null==(l=(r=d.formatters).ttKeyFormatter)?void 0:l.call(r,b,f))?o:b),d.seriesData.seriesZ.length>0&&d.seriesData.seriesZ[e].length>0&&(x=null==m?void 0:m(d.seriesData.seriesZ[e][t],d)),p="function"==typeof d.config.xaxis.tooltip.formatter?null==(h=(n=d.formatters).xaxisTooltipFormatter)?void 0:h.call(n,b,f):g,{val:Array.isArray(u)?u.join(" "):u,xVal:Array.isArray(g)?g.join(" "):g,xAxisTTVal:Array.isArray(p)?p.join(" "):p,zVal:x}}handleCustomTooltip({i:e,j:t,y1:i,y2:s,w:a}){let r=this.ttCtx.getElTooltip(),l=a.config.tooltip.custom;Array.isArray(l)&&l[e]&&(l=l[e]);let o=l({series:a.seriesData.series,seriesIndex:e,dataPointIndex:t,y1:i,y2:s,w:a});r&&("string"==typeof o||"number"==typeof o?r.innerHTML=String(o):(o instanceof Element||"string"==typeof o.nodeName)&&(r.innerHTML="",r.appendChild(o.cloneNode(!0))))}}class eA{constructor(e){this.ttCtx=e,this.w=e.w}moveXCrosshairs(e,t=null){let i=this.ttCtx,s=this.w,a=i.getElXCrosshairs(),r=e-i.xcrosshairsWidth/2,l=s.labelData.labels.slice().length;if(null!==t&&(r=s.layout.gridWidth/l*t),null===a||s.globals.isBarHorizontal||(a.setAttribute("x",String(r)),a.setAttribute("x1",String(r)),a.setAttribute("x2",String(r)),a.setAttribute("y2",String(s.layout.gridHeight)),a.classList.add("apexcharts-active")),r<0&&(r=0),r>s.layout.gridWidth&&(r=s.layout.gridWidth),i.isXAxisTooltipEnabled){let e=r;("tickWidth"===s.config.xaxis.crosshairs.width||"barWidth"===s.config.xaxis.crosshairs.width)&&(e=r+i.xcrosshairsWidth/2),this.moveXAxisTooltip(e)}}moveYCrosshairs(e){let t=this.ttCtx;null!==t.ycrosshairs&&Y.setAttrs(t.ycrosshairs,{y1:e,y2:e}),null!==t.ycrosshairsHidden&&Y.setAttrs(t.ycrosshairsHidden,{y1:e,y2:e})}moveXAxisTooltip(e){var t,i;let s=this.w,a=this.ttCtx;if(null!==a.xaxisTooltip&&0!==a.xcrosshairsWidth){a.xaxisTooltip.classList.add("apexcharts-active");let r=a.xaxisOffY+s.config.xaxis.tooltip.offsetY+s.layout.translateY+1+s.config.xaxis.offsetY,l=a.xaxisTooltip.getBoundingClientRect().width;if(!isNaN(e-=l/2)){e+=s.layout.translateX;let l=new Y(this.w).getTextRects(null!=(i=null==(t=a.xaxisTooltipText)?void 0:t.innerHTML)?i:"",s.config.xaxis.labels.style.fontSize);a.xaxisTooltipText&&(a.xaxisTooltipText.style.minWidth=l.width+"px"),a.xaxisTooltip.style.left=e+"px",a.xaxisTooltip.style.top=r+"px"}}}moveYAxisTooltip(e){var t,i;let s=this.w,a=this.ttCtx;null===a.yaxisTTEls&&(a.yaxisTTEls=[...s.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip")]);let r=parseInt(null!=(i=null==(t=a.ycrosshairsHidden)?void 0:t.getAttribute("y1"))?i:"0",10),l=s.layout.translateY+r;if(a.yaxisTTEls){let t=a.yaxisTTEls[e].getBoundingClientRect(),i=t.height,r=s.globals.translateYAxisX[e]-2;s.config.yaxis[e].opposite&&(r-=t.width),l-=i/2,-1===s.globals.ignoreYAxisIndexes.indexOf(e)&&l>0&&l<s.layout.gridHeight?(a.yaxisTTEls[e].classList.add("apexcharts-active"),a.yaxisTTEls[e].style.top=l+"px",a.yaxisTTEls[e].style.left=r+s.config.yaxis[e].tooltip.offsetX+"px"):a.yaxisTTEls[e].classList.remove("apexcharts-active")}}moveTooltip(e,t,i=null){var s,a,r,l,o,n,h;let d=this.w,c=this.ttCtx,g=c.getElTooltip(),p=c.tooltipRect,x=null!==i?parseFloat(String(i)):1,u=parseFloat(String(e))+x+5,f=parseFloat(String(t))+x/2;if(u>d.layout.gridWidth/2&&(u=u-p.ttWidth-x-10),u>d.layout.gridWidth-p.ttWidth-10&&(u=d.layout.gridWidth-p.ttWidth),u<-20&&(u=-20),d.config.tooltip.followCursor){let e=c.getElGrid();if(!e)return;let t=e.getBoundingClientRect();(u=c.e.clientX-t.left)>d.layout.gridWidth/2&&(u-=c.tooltipRect.ttWidth),(f=c.e.clientY+d.layout.translateY-t.top)>d.layout.gridHeight/2&&(f-=c.tooltipRect.ttHeight)}else!d.globals.isBarHorizontal&&p.ttHeight/2+f>d.layout.gridHeight&&(f=d.layout.gridHeight-p.ttHeight+d.layout.translateY);if(!isNaN(u)){u+=d.layout.translateX;let e=null==(a=null==(s=d.config)?void 0:s.chart)?void 0:a.accessibility;if((null==e?void 0:e.enabled)&&(null==(l=null==(r=null==e?void 0:e.keyboard)?void 0:r.navigation)?void 0:l.enabled)&&(null==(h=null==(n=null==(o=d.dom)?void 0:o.baseEl)?void 0:n.querySelector)?void 0:h.call(n,".apexcharts-keyboard-focused"))){let e=parseFloat(String(t)),i=p.ttHeight||0,s=(x||1)+12,a=f,r=f+i;!isNaN(e)&&i>0&&a<e+s&&r>e-s&&(f=e-i-s)<0&&(f=e+s)}g&&(g.style.left=u+"px",g.style.top=f+"px")}}moveMarkers(e,t){var i;let s=this.w,a=this.ttCtx;if(s.globals.markers.size[e]>0){let r=s.dom.baseEl.querySelectorAll(` .apexcharts-series[data\\:realIndex='${e}'] .apexcharts-marker`);for(let e=0;e<r.length;e++)parseInt(null!=(i=r[e].getAttribute("rel"))?i:"0",10)===t&&(a.marker.resetPointsSize(),a.marker.enlargeCurrentPoint(t,r[e]))}else a.marker.resetPointsSize(),this.moveDynamicPointOnHover(t,e)}moveDynamicPointOnHover(e,t){var i,s,a,r,l;let o=this.w,n=this.ttCtx,h=0,d=0,c=new Y(this.w),g=o.globals.pointsArray,p=n.tooltipUtil.getHoverMarkerSize(t),x=o.config.series[t].type;if(x&&("column"===x||"candlestick"===x||"boxPlot"===x))return;h=null==(s=null==(i=g[t])?void 0:i[e])?void 0:s[0],d=(null==(r=null==(a=g[t])?void 0:a[e])?void 0:r[1])||0;let u=o.dom.baseEl.querySelector(`.apexcharts-series[data\\:realIndex='${t}'] .apexcharts-series-markers path`);if(u&&d<o.layout.gridHeight&&d>0){let e=null!=(l=u.getAttribute("shape"))?l:"circle",t=c.getMarkerPath(h,d,e,1.5*p);u.setAttribute("d",t)}this.moveXCrosshairs(h),n.fixedTooltip||this.moveTooltip(h,d,p)}moveDynamicPointsOnHover(e){var t,i;let s=this.ttCtx,a=s.w,r=0,l=0,o=0,n=a.globals.pointsArray,h=new er(this.w),d=new Y(this.w);o=h.getActiveConfigSeriesIndex("asc",["line","area","scatter","bubble"]);let c=s.tooltipUtil.getHoverMarkerSize(o);if((null==(t=n[o])?void 0:t[e])&&(r=n[o][e][0],l=n[o][e][1]),isNaN(r))return;let g=s.tooltipUtil.getAllMarkers();if(g.length)for(let t=0;t<a.seriesData.series.length;t++){let s=n[t];if(a.globals.comboCharts&&void 0===s&&g.splice(t,0,null),s&&s.length){let s=n[t][e][1];g[t].setAttribute("cx",r);let l=null!=(i=g[t].getAttribute("shape"))?i:"circle";if("rangeArea"===a.config.chart.type&&!a.globals.comboCharts){let i=e+a.seriesData.series[t].length,r=Math.abs(s-n[t][i][1])/2;s-=r}if(null!==s&&!isNaN(s)&&s<a.layout.gridHeight+c&&s+c>0){let e=d.getMarkerPath(r,s,l,c);g[t].setAttribute("d",e)}else g[t].setAttribute("d","")}}this.moveXCrosshairs(r),s.fixedTooltip||this.moveTooltip(r,l||a.layout.gridHeight,c)}moveStickyTooltipOverBars(e,t){var i,s,a;let r=this.w,l=this.ttCtx,o=r.globals.columnSeries?r.globals.columnSeries.length:r.seriesData.series.length;r.config.chart.stacked&&(o=r.globals.barGroups.length);let n=o>=2&&o%2==0?Math.floor(o/2):Math.floor(o/2)+1;r.globals.isBarHorizontal&&(n=new er(this.w).getActiveConfigSeriesIndex("desc")+1);let h=r.dom.baseEl.querySelector(`.apexcharts-bar-series .apexcharts-series[rel='${n}'] path[j='${e}'], .apexcharts-candlestick-series .apexcharts-series[rel='${n}'] path[j='${e}'], .apexcharts-boxPlot-series .apexcharts-series[rel='${n}'] path[j='${e}'], .apexcharts-rangebar-series .apexcharts-series[rel='${n}'] path[j='${e}']`);h||"number"!=typeof t||(h=r.dom.baseEl.querySelector(`.apexcharts-bar-series .apexcharts-series[data\\:realIndex='${t}'] path[j='${e}'],
28        .apexcharts-candlestick-series .apexcharts-series[data\\:realIndex='${t}'] path[j='${e}'],
29        .apexcharts-boxPlot-series .apexcharts-series[data\\:realIndex='${t}'] path[j='${e}'],
30        .apexcharts-rangebar-series .apexcharts-series[data\\:realIndex='${t}'] path[j='${e}']`));
30let d=h?parseFloat(null!=(i=h.getAttribute("cx"))?i:"0"):0,c=h?parseFloat(null!=(s=h.getAttribute("cy"))?s:"0"):0,g=h?parseFloat(null!=(a=h.getAttribute("barWidth"))?a:"0"):0,p=l.getElGrid();if(!p)return;let x=p.getBoundingClientRect(),u=h&&(h.classList.contains("apexcharts-candlestick-area")||h.classList.contains("apexcharts-boxPlot-area"));r.axisFlags.isXNumeric?(h&&!u&&(d-=o%2!=0?g/2:0),h&&u&&(d-=g/2)):!r.globals.isBarHorizontal&&isNaN(d=l.xAxisTicksPositions[e-1]+l.dataPointsDividedWidth/2)&&(d=l.xAxisTicksPositions[e]-l.dataPointsDividedWidth/2),r.globals.isBarHorizontal?c-=l.tooltipRect.ttHeight:r.config.tooltip.followCursor?c=l.e.clientY-x.top-l.tooltipRect.ttHeight/2:c+l.tooltipRect.ttHeight+15>r.layout.gridHeight&&(c=r.layout.gridHeight),r.globals.isBarHorizontal||this.moveXCrosshairs(d),l.fixedTooltip||this.moveTooltip(d,c||r.layout.gridHeight)}}class eC{constructor(e){this.w=e.w,this.ttCtx=e,this.ctx=e.ctx,this.tooltipPosition=new eA(e)}drawDynamicPoints(){let e=this.w,t=new Y(this.w),i=new _(this.w,this.ctx),s=[...e.dom.baseEl.querySelectorAll(".apexcharts-series")];e.config.chart.stacked&&s.sort((e,t)=>parseFloat(e.getAttribute("data:realIndex"))-parseFloat(t.getAttribute("data:realIndex")));for(let a=0;a<s.length;a++){let r=s[a].querySelector(".apexcharts-series-markers-wrap");if(null!==r){let s=`apexcharts-marker w${(Math.random()+1).toString(36).substring(4)}`;"line"!==e.config.chart.type&&"area"!==e.config.chart.type||e.globals.comboCharts||e.config.tooltip.intersect||(s+=" no-pointer-events");let a=i.getMarkerConfig({cssClass:s,seriesIndex:Number(r.getAttribute("data:realIndex"))}),l=t.drawMarker(0,0,a);l.node.setAttribute("default-marker-size",0);let o=w.createElementNS(B,"g");o.classList.add("apexcharts-series-markers"),o.appendChild(l.node),r.appendChild(o)}}}enlargeCurrentPoint(e,t,i=null,s=null){let a=this.w;"bubble"!==a.config.chart.type&&this.newPointSize(e,t);let r=t.getAttribute("cx"),l=t.getAttribute("cy");if(null!==i&&null!==s&&(r=i,l=s),this.tooltipPosition.moveXCrosshairs(r),!this.fixedTooltip){if("radar"===a.config.chart.type){let e=this.ttCtx.getElGrid();if(!e)return;let t=e.getBoundingClientRect();r=this.ttCtx.e.clientX-t.left}this.tooltipPosition.moveTooltip(r,l,a.config.markers.hover.size)}}enlargePoints(e){var t,i;let s=this.w,a=this.ttCtx,r=s.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),l=s.config.markers.hover.size;for(let o=0;o<r.length;o++){let n=r[o].getAttribute("rel"),h=r[o].getAttribute("index");if(void 0===l&&(l=s.globals.markers.size[h]+s.config.markers.hover.sizeOffset),e===parseInt(null!=n?n:"0",10)){this.newPointSize(e,r[o]);let s=null!=(t=r[o].getAttribute("cx"))?t:"0",n=null!=(i=r[o].getAttribute("cy"))?i:"0";this.tooltipPosition.moveXCrosshairs(parseFloat(s)),a.fixedTooltip||this.tooltipPosition.moveTooltip(parseFloat(s),parseFloat(n),l)}else this.oldPointSize(r[o])}}newPointSize(e,t){let i=this.w,s=i.config.markers.hover.size,a=0===e?t.parentNode.firstChild:t.parentNode.lastChild;if("0"!==a.getAttribute("default-marker-size")){let e=parseInt(a.getAttribute("index"),10);void 0===s&&(s=i.globals.markers.size[e]+i.config.markers.hover.sizeOffset),s<0&&(s=0);let r=this.ttCtx.tooltipUtil.getPathFromPoint(t,s);t.setAttribute("d",r)}}oldPointSize(e){let t=parseFloat(e.getAttribute("default-marker-size")),i=this.ttCtx.tooltipUtil.getPathFromPoint(e,t);e.setAttribute("d",i)}resetPointsSize(){var e;let t=this.w.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker");for(let i=0;i<t.length;i++){let s=parseFloat(null!=(e=t[i].getAttribute("default-marker-size"))?e:"0");if(v.isNumber(s)&&s>0){let e=this.ttCtx.tooltipUtil.getPathFromPoint(t[i],s);t[i].setAttribute("d",e)}else t[i].setAttribute("d","M0,0")}}}class eS{constructor(e){this.w=e.w;const t=this.w;this.ttCtx=e,this.isVerticalGroupedRangeBar=!t.globals.isBarHorizontal&&"rangeBar"===t.config.chart.type&&t.config.plotOptions.bar.rangeBarGroupRows}getAttr(e,t){var i;return parseFloat(null!=(i=e.target.getAttribute(t))?i:"")}handleHeatTreeTooltip({e,opt:t,x:i,y:s,type:a}){var r,l;let o=this.ttCtx,n=this.w;if(e.target.classList.contains(`apexcharts-${a}-rect`)){let a=this.getAttr(e,"i"),h=this.getAttr(e,"j"),d=this.getAttr(e,"cx"),c=this.getAttr(e,"cy"),g=this.getAttr(e,"
30width"),p=this.getAttr(e,"height");if(o.tooltipLabels.drawSeriesTexts({ttItems:t.ttItems,i:a,j:h,shared:!1,e}),n.interact.capturedSeriesIndex=a,n.interact.capturedDataPointIndex=h,i=d+o.tooltipRect.ttWidth/2+g,s=c+o.tooltipRect.ttHeight/2-p/2,o.tooltipPosition.moveXCrosshairs(d+g/2),i>n.layout.gridWidth/2&&(i=d-o.tooltipRect.ttWidth/2+g),o.w.config.tooltip.followCursor){let e=n.dom.elWrap.getBoundingClientRect();i=(null!=(r=n.interact.clientX)?r:0)-e.left-(i>n.layout.gridWidth/2?o.tooltipRect.ttWidth:0),s=(null!=(l=n.interact.clientY)?l:0)-e.top-(s>n.layout.gridHeight/2?o.tooltipRect.ttHeight:0)}}return{x:i,y:s}}handleMarkerTooltip({e,opt:t,x:i,y:s}){let a,r,l=this.w,o=this.ttCtx;if(e.target.classList.contains("apexcharts-marker")){let n=parseInt(t.paths.getAttribute("cx"),10),h=parseInt(t.paths.getAttribute("cy"),10),d=parseFloat(t.paths.getAttribute("val"));if(r=parseInt(t.paths.getAttribute("rel"),10),a=parseInt(t.paths.parentNode.parentNode.parentNode.getAttribute("rel"),10)-1,o.intersect){let e=v.findAncestor(t.paths,"apexcharts-series");e&&(a=parseInt(e.getAttribute("data:realIndex"),10))}if(o.tooltipLabels.drawSeriesTexts({ttItems:t.ttItems,i:a,j:r,shared:!o.showOnIntersect&&l.config.tooltip.shared,e}),"mouseup"===e.type&&o.markerClick(e,a,r),l.interact.capturedSeriesIndex=a,l.interact.capturedDataPointIndex=r,i=n,s=h+l.layout.translateY-1.4*o.tooltipRect.ttHeight,o.w.config.tooltip.followCursor){let e=o.getElGrid();if(!e)return{x:i,y:s};let t=e.getBoundingClientRect();s=o.e.clientY+l.layout.translateY-t.top}d<0&&(s=h),o.marker.enlargeCurrentPoint(r,t.paths,i,s)}return{x:i,y:s}}handleBarTooltip({e,opt:t}){let i,s=this.w,a=this.ttCtx,r=a.getElTooltip(),l=0,o=0,n=0,h=0,d=this.getBarTooltipXY({e,opt:t});if(null===d.j&&0===d.barHeight&&0===d.barWidth)return;h=d.i;let c=d.j;s.interact.capturedSeriesIndex=h,s.interact.capturedDataPointIndex=null!==c?c:s.interact.capturedDataPointIndex,s.globals.isBarHorizontal&&a.tooltipUtil.hasBars()||!s.config.tooltip.shared?(o=d.x,n=d.y,i=Array.isArray(s.config.stroke.width)?s.config.stroke.width[h]:s.config.stroke.width,l=o):s.globals.comboCharts||s.config.tooltip.shared||(l/=2),isNaN(n)&&(n=s.globals.svgHeight-a.tooltipRect.ttHeight),o+a.tooltipRect.ttWidth>s.layout.gridWidth?o-=a.tooltipRect.ttWidth:o<0&&(o=0),(!a.w.config.tooltip.followCursor||a.getElGrid())&&(null===a.tooltip&&(a.tooltip=s.dom.baseEl.querySelector(".apexcharts-tooltip")),s.config.tooltip.shared||(s.globals.comboBarCount>0?a.tooltipPosition.moveXCrosshairs(l+i/2):a.tooltipPosition.moveXCrosshairs(l)),!a.fixedTooltip&&(!s.config.tooltip.shared||s.globals.isBarHorizontal&&a.tooltipUtil.hasBars())&&(n=n+s.layout.translateY-a.tooltipRect.ttHeight/2,r&&(r.style.left=o+s.layout.translateX+"px",r.style.top=n+"px")))}getBarTooltipXY({e,opt:t}){let i=this.w,s=null,a=this.ttCtx,r=0,l=0,o=0,n=0,h=0,d=e.target.classList;if(d.contains("apexcharts-bar-area")||d.contains("apexcharts-candlestick-area")||d.contains("apexcharts-boxPlot-area")||d.contains("apexcharts-rangebar-area")){let d=e.target,c=d.getBoundingClientRect(),g=t.elGrid.getBoundingClientRect(),p=c.height;h=c.height;let x=c.width,u=parseInt(d.getAttribute("cx"),10),f=parseInt(d.getAttribute("cy"),10);n=parseFloat(d.getAttribute("barWidth"));let m="touchmove"===e.type?e.touches[0].clientX:e.clientX;s=parseInt(d.getAttribute("j"),10),r=parseInt(d.parentNode.getAttribute("rel"),10)-1;let b=d.getAttribute("data-range-y1"),y=d.getAttribute("data-range-y2");i.globals.comboCharts&&(r=parseInt(d.parentNode.getAttribute("data:realIndex"),10));let w=e=>i.axisFlags.isXNumeric?u-x/2:this.isVerticalGroupedRangeBar?u+x/2:u-a.dataPointsDividedWidth+x/2,v=()=>f-a.dataPointsDividedHeight+p/2-a.tooltipRect.ttHeight/2;a.tooltipLabels.drawSeriesTexts({ttItems:t.ttItems,i:r,j:s,y1:b?parseInt(b,10):null,y2:y?parseInt(y,10):null,shared:!a.showOnIntersect&&i.config.tooltip.shared,e}),i.config.tooltip.followCursor?i.globals.isBarHorizontal?(l=m-g.left+15,o=v()):(l=w(l),o=e.clientY-g.top-a.tooltipRect.ttHeight/2-15):i.globals.isBarHorizontal?(l=u,a.xyRatios&&l<a.xyRatios.baseLineInvertedY&&(l=u-a.tooltipRect.ttWidth),o=v()):(l=w(l),o=f)}return{x:l,y:o,barHeight:h,barWidth:n,i:r,j:s}}}class ek{constructor(e){this.w=e.w,this.ttCtx=e}drawXaxisTooltip(){let e=this.w,t=this.ttCtx,i="bottom"===e.config.xaxis.position;t.xaxisOffY=i?e.layout.gridHeight+1:-e.layout.xAxisHeight-e.config.xaxis.axisTicks.height+3;let s=e.dom.elWrap;t.isXAxisTooltipEnabled&&null===e.dom.baseEl.querySelector(".apexcharts-xaxistooltip")&&(t.xaxisTooltip=w.createElementNS("http://www.w3.org/1999/xhtml","div"),t.xaxisTooltip.setAttribute("class",(i?"apexcharts-xaxistooltip apexcharts-xaxistooltip-bottom":"apexcharts-xaxistooltip apexcharts-xaxistooltip-top")+" apexcharts-theme-"+e.config.tooltip.theme),s.appendChild(t.xaxisTooltip),t.xaxisTooltipText=w.createElementNS("http://www.w3.org/1999/xhtml","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))}drawYaxisTooltip(){let e=this.w,t=this.ttCtx;for(let i=0;i<e.config.yaxis.length;i++){let s=e.config.yaxis[i].opposite||e.config.yaxis[i].crosshairs.opposite;t.yaxisOffX=s?e.layout.gridWidth+1:1;let a=s?`apexcharts-yaxistooltip apexcharts-yaxistooltip-${i} apexcharts-yaxistooltip-right`:`apexcharts-yaxistooltip apexcharts-yaxistooltip-${i} apexcharts-yaxistooltip-left`,r=e.dom.elWrap;null===e.dom.baseEl.querySelector(`.apexcharts-yaxistooltip apexcharts-yaxistooltip-${i}`)&&(t.yaxisTooltip=w.createElementNS("http://www.w3.org/1999/xhtml","div"),t.yaxisTooltip.setAttribute("class",a+" apexcharts-theme-"+e.config.tooltip.theme),r.appendChild(t.yaxisTooltip),0===i&&(t.yaxisTooltipText=[]),t.yaxisTooltipText[i]=w.createElementNS("http://www.w3.org/1999/xhtml","div"),t.yaxisTooltipText[i].classList.add("apexcharts-yaxistooltip-text"),t.yaxisTooltip.appendChild(t.yaxisTooltipText[i]))}}setXCrosshairWidth(){var e,t;let i=this.w,s=this.ttCtx,a=s.getElXCrosshairs();if(s.xcrosshairsWidth=parseInt(i.config.xaxis.crosshairs.width,10),i.globals.comboCharts){let e=i.dom.baseEl.querySelector(".apexcharts-bar-area");if(null!==e&&"barWidth"===i.config.xaxis.crosshairs.width)s.xcrosshairsWidth=parseFloat(null!=(t=e.getAttribute("barWidth"))?t:"0");else if("tickWidth"===i.config.xaxis.crosshairs.width){let e=i.labelData.labels.length;s.xcrosshairsWidth=i.layout.gridWidth/e}}else if("tickWidth"===i.config.xaxis.crosshairs.width){let e=i.labelData.labels.length;s.xcrosshairsWidth=i.layout.gridWidth/e}else if("barWidth"===i.config.xaxis.crosshairs.width){let t=i.dom.baseEl.querySelector(".apexcharts-bar-area");null!==t?s.xcrosshairsWidth=parseFloat(null!=(e=t.getAttribute("barWidth"))?e:"0"):s.xcrosshairsWidth=1}i.globals.isBarHorizontal&&(s.xcrosshairsWidth=0),null!==a&&s.xcrosshairsWidth>0&&a.setAttribute("width",String(s.xcrosshairsWidth))}handleYCrosshair(){let e=this.w,t=this.ttCtx;t.ycrosshairs=e.dom.baseEl.querySelector(".apexcharts-ycrosshairs"),t.ycrosshairsHidden=e.dom.baseEl.querySelector(".apexcharts-ycrosshairs-hidden")}drawYaxisTooltipText(e,t,i){let s=this.ttCtx,a=this.w,r=a.globals,l=r.seriesYAxisMap[e];if(s.yaxisTooltips[e]&&l.length>0){let o=a.formatters.yLabelFormatters[e],n=s.getElGrid();if(!n)return;let h=n.getBoundingClientRect(),d=l[0],c=0;i.yRatio.length>1&&(c=d);let g=(t-h.top)*i.yRatio[c],p=r.maxYArr[d]-r.minYArr[d],x=r.minYArr[d]+(p-g);a.config.yaxis[e].reversed&&(x=r.maxYArr[d]-(p-g)),s.tooltipPosition.moveYCrosshairs(t-h.top),s.yaxisTooltipText[e].innerHTML=o(x),s.tooltipPosition.moveYAxisTooltip(e)}}}class eD{constructor(e,t){this.w=e,this.ctx=t,this.tConfig=e.config.tooltip,this.tooltipUtil=new ew(this),this.tooltipLabels=new ev(this),this.tooltipPosition=new eA(this),this.marker=new eC(this),this.intersect=ne
30w eS(this),this.axesTooltip=new ek(this),this.showOnIntersect=this.tConfig.intersect,this.showTooltipTitle=this.tConfig.x.show,this.fixedTooltip=this.tConfig.fixed.enabled,this.xaxisTooltip=null,this.xaxisTooltipText=null,this.yaxisTooltip=null,this.yaxisTooltipText=null,this.yaxisTTEls=null,this.xaxisOffY=0,this.yaxisOffX=0,this.xcrosshairsWidth=0,this.ycrosshairs=null,this.ycrosshairsHidden=null,this.tooltip=null,this.e=null,this.isBarShared=!e.globals.isBarHorizontal&&this.tConfig.shared,this.lastHoverTime=Date.now(),this.dimensionUpdateScheduled=!1,this.xyRatios=null,this.isXAxisTooltipEnabled=!1,this.yaxisTooltips=[],this.allTooltipSeriesGroups=[],this.xAxisTicksPositions=null,this.dataPointsDividedHeight=0,this.dataPointsDividedWidth=0,this.tooltipTitle=null,this.legendLabels=null,this.ttItems=null,this.seriesBound=null,this.seriesHoverTimeout=void 0,this.clientX=0,this.clientY=0,this.barSeriesHeight=0,this.tooltipRect={x:0,y:0,ttWidth:0,ttHeight:0}}setupDimensionCache(){let e=this.w,t=this.getElTooltip();t&&(this.updateDimensionCache(),"undefined"==typeof ResizeObserver||e.globals.resizeObserver||(e.globals.resizeObserver=new ResizeObserver(()=>{this.dimensionUpdateScheduled||(this.dimensionUpdateScheduled=!0,requestAnimationFrame(()=>{this.updateDimensionCache(),this.dimensionUpdateScheduled=!1}))}),e.globals.resizeObserver.observe(t)))}updateDimensionCache(){let e=this.w,t=this.getElTooltip();if(!t)return;let i=t.getBoundingClientRect();e.globals.dimensionCache.tooltip={width:i.width,height:i.height,lastUpdate:Date.now()}}getCachedDimensions(){let e=this.w;if(e.globals.dimensionCache.tooltip){let t=e.globals.dimensionCache.tooltip;if(Date.now()-t.lastUpdate<1e3)return{ttWidth:t.width,ttHeight:t.height}}this.updateDimensionCache();let t=e.globals.dimensionCache.tooltip;return t?{ttWidth:t.width,ttHeight:t.height}:{ttWidth:0,ttHeight:0}}getElTooltip(e){return(e||(e=this),e.w.dom.baseEl)?e.w.dom.baseEl.querySelector(".apexcharts-tooltip"):null}getElXCrosshairs(){return this.w.dom.baseEl.querySelector(".apexcharts-xcrosshairs")}getElGrid(){return this.w.dom.baseEl.querySelector(".apexcharts-grid")}drawTooltip(e){let t=this.w;this.xyRatios=e,this.isXAxisTooltipEnabled=t.config.xaxis.tooltip.enabled&&t.globals.axisCharts,this.yaxisTooltips=t.config.yaxis.map(e=>!!e.show&&!!e.tooltip.enabled&&!!t.globals.axisCharts),this.allTooltipSeriesGroups=[],t.globals.axisCharts||(this.showTooltipTitle=!1);let i=this.getElTooltip();(null==i?void 0:i.parentNode)&&i.parentNode.removeChild(i),this.tooltipTitle=null;let s=w.createElementNS("http://www.w3.org/1999/xhtml","div");if(s.classList.add("apexcharts-tooltip"),t.config.tooltip.cssClass&&s.classList.add(t.config.tooltip.cssClass),s.classList.add(`apexcharts-theme-${this.tConfig.theme||"light"}`),t.config.chart.accessibility.enabled&&t.config.chart.accessibility.announcements.enabled&&(s.setAttribute("role","tooltip"),s.setAttribute("aria-live","polite"),s.setAttribute("aria-atomic","true"),s.setAttribute("aria-hidden","true")),t.dom.elWrap.appendChild(s),t.globals.axisCharts){this.axesTooltip.drawXaxisTooltip(),this.axesTooltip.drawYaxisTooltip(),this.axesTooltip.setXCrosshairWidth(),this.axesTooltip.handleYCrosshair();let e=new U(this.w,this.ctx,void 0);this.xAxisTicksPositions=e.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(),t.globals.collapsedSeries.length===t.seriesData.series.length)return;this.dataPointsDividedHeight=t.layout.gridHeight/t.globals.dataPoints,this.dataPointsDividedWidth=t.layout.gridWidth/t.globals.dataPoints,this.showTooltipTitle&&(this.tooltipTitle=w.createElementNS("http://www.w3.org/1999/xhtml","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,s.appendChild(this.tooltipTitle));let a=t.seriesData.series.length;
30(t.globals.xyCharts||t.globals.comboCharts)&&this.tConfig.shared&&(a=this.showOnIntersect?1:t.seriesData.series.length),this.legendLabels=t.dom.baseEl.querySelectorAll(".apexcharts-legend-text"),this.ttItems=this.createTTElements(a),this.addSVGEvents(),this.setupDimensionCache()}createTTElements(e){let t=this.w,i=[],s=this.getElTooltip();if(!s)return i;for(let a=0;a<e;a++){let r=w.createElementNS("http://www.w3.org/1999/xhtml","div");r.classList.add("apexcharts-tooltip-series-group",`apexcharts-tooltip-series-group-${a}`),r.style.order=String(t.config.tooltip.inverseOrder?e-a:a+1);let l=w.createElementNS("http://www.w3.org/1999/xhtml","span");l.classList.add("apexcharts-tooltip-marker"),t.config.tooltip.fillSeriesColor?l.style.backgroundColor=t.globals.colors[a]:l.style.color=t.globals.colors[a];let o=t.config.markers.shape,n=o;Array.isArray(o)&&(n=o[a]),l.setAttribute("shape",n),r.appendChild(l);let h=w.createElementNS("http://www.w3.org/1999/xhtml","div");h.classList.add("apexcharts-tooltip-text"),h.style.fontFamily=this.tConfig.style.fontFamily||t.config.chart.fontFamily,h.style.fontSize=this.tConfig.style.fontSize,["y","goals","z"].forEach(e=>{let t=w.createElementNS("http://www.w3.org/1999/xhtml","div");t.classList.add(`apexcharts-tooltip-${e}-group`);let i=w.createElementNS("http://www.w3.org/1999/xhtml","span");i.classList.add(`apexcharts-tooltip-text-${e}-label`),t.appendChild(i);let s=w.createElementNS("http://www.w3.org/1999/xhtml","span");s.classList.add(`apexcharts-tooltip-text-${e}-value`),t.appendChild(s),h.appendChild(t)}),r.appendChild(h),s.appendChild(r),i.push(r)}return i}addSVGEvents(){let e,t=this.w,i=t.config.chart.type,s=this.getElTooltip();if(!s)return;let a="bar"===i||"candlestick"===i||"boxPlot"===i||"rangeBar"===i,r="area"===i||"line"===i||"scatter"===i||"bubble"===i||"radar"===i,l=t.dom.Paper.node,o=this.getElGrid();o&&(this.seriesBound=o.getBoundingClientRect());let n=[],h=[],d={hoverArea:l,elGrid:o,tooltipEl:s,tooltipY:n,tooltipX:h,ttItems:this.ttItems};if(t.globals.axisCharts&&(r?e=t.dom.baseEl.querySelectorAll(".apexcharts-series[data\\:longestSeries='true'] .apexcharts-marker"):a?e=t.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-bar-area, .apexcharts-series .apexcharts-candlestick-area, .apexcharts-series .apexcharts-boxPlot-area, .apexcharts-series .apexcharts-rangebar-area"):("heatmap"===i||"treemap"===i)&&(e=t.dom.baseEl.querySelectorAll(".apexcharts-series .apexcharts-heatmap, .apexcharts-series .apexcharts-treemap")),e&&e.length))for(let t=0;t<e.length;t++)n.push(e[t].getAttribute("cy")),h.push(e[t].getAttribute("cx"));if(t.globals.xyCharts&&!this.showOnIntersect||t.globals.comboCharts&&!this.showOnIntersect||a&&this.tooltipUtil.hasBars()&&this.tConfig.shared)this.addPathsEventListeners([l],d);else if(a&&!t.globals.comboCharts||r&&this.showOnIntersect)this.addDatapointEventsListeners(d);else if(!t.globals.axisCharts||"heatmap"===i||"treemap"===i){let e=t.dom.baseEl.querySelectorAll(".apexcharts-series");this.addPathsEventListeners(e,d)}if(this.showOnIntersect){let e=t.dom.baseEl.querySelectorAll(".apexcharts-line-series .apexcharts-marker, .apexcharts-area-series .apexcharts-marker");e.length>0&&this.addPathsEventListeners(e,d),this.tooltipUtil.hasBars()&&!this.tConfig.shared&&this.addDatapointEventsListeners(d)}}drawFixedTooltipRect(){let e=this.w,t=this.getElTooltip();if(!t)return{x:0,y:0,ttWidth:0,ttHeight:0};let i=t.getBoundingClientRect(),s=i.width+10,a=i.height+10,r=this.tConfig.fixed.offsetX,l=this.tConfig.fixed.offsetY,o=this.tConfig.fixed.position.toLowerCase();return o.indexOf("right")>-1&&(r=r+e.globals.svgWidth-s+10),o.indexOf("bottom")>-1&&(l=l+e.globals.svgHeight-a-10),t.style.left=r+"px",t.style.top=l+"px",{x:r,y:l,ttWidth:s,ttHeight:a}}addDatapointEventsListeners(e){let t=this.w.dom.baseEl.querySelectorAll(".apexcharts-series-markers .apexcharts-marker, .apexcharts-bar-area, .apexcharts-candlestick-area, .apexcharts-boxPlot-area, .apexcharts-rangebar-area");this.addPathsEventListeners(t,e)}addPathsEventListeners(e,t){let i=this;for(let s=0;s<e.length;s++){let a={paths:e[s],tooltipEl:t.tooltipEl,tooltipY:t.tooltipY,tooltipX:t.tooltipX,elGrid:t.elGrid,hoverArea:t.hoverArea,ttItems:t.ttItems};["mousemove","mouseup","touchmove","mouseout","touchend"].map(t=>e[s].addEventListener(t,i.onSeriesHover.bind(i,a),{capture:!1,passive:!0}))}}onSeriesHover(e,t){let i=Date.now()-this.lastHoverTime;i>=20?this.seriesHover(e,t):(clearTimeout(this.seriesHoverTimeout),this.seriesHoverTimeout=setTimeout(()=>{this.seriesHover(e,t)},20-i))}seriesHover(e,t){this.lastHoverTime=Date.now();let i=[],s=this.w;s.config.chart.group&&(i=this.ctx.getGroupedCharts()),s.globals.axisCharts&&(s.globals.minX===-1/0&&s.globals.maxX===1/0||0===s.globals.dataPoints)||(i.length?i.forEac
30h(i=>{let s=this.getElTooltip(i),a={paths:e.paths,tooltipEl:s,tooltipY:e.tooltipY,tooltipX:e.tooltipX,elGrid:e.elGrid,hoverArea:e.hoverArea,ttItems:i.w.globals.tooltip.ttItems};i.w.globals.minX===this.w.globals.minX&&i.w.globals.maxX===this.w.globals.maxX&&i.w.globals.tooltip.seriesHoverByContext({chartCtx:i,ttCtx:i.w.globals.tooltip,opt:a,e:t})}):this.seriesHoverByContext({chartCtx:this.ctx,ttCtx:this.w.globals.tooltip,opt:e,e:t}))}seriesHoverByContext({chartCtx:e,ttCtx:t,opt:i,e:s}){let a=e.w;if(!this.getElTooltip(e))return;let r=t.getCachedDimensions();t.tooltipRect={x:0,y:0,ttWidth:r.ttWidth,ttHeight:r.ttHeight},t.e=s,t.tooltipUtil.hasBars()&&!a.globals.comboCharts&&!t.isBarShared&&this.tConfig.onDatasetHover.highlightDataSeries&&new er(e.w).toggleSeriesOnHover(s,s.target.parentNode),a.globals.axisCharts?t.axisChartsTooltips({e:s,opt:i,tooltipRect:t.tooltipRect}):t.nonAxisChartsTooltips({e:s,opt:i,tooltipRect:t.tooltipRect}),t.fixedTooltip&&t.drawFixedTooltipRect()}axisChartsTooltips({e,opt:t}){var i;let s,a,r=this.w,l=t.elGrid.getBoundingClientRect(),o="touchmove"===e.type?e.touches[0].clientX:e.clientX,n="touchmove"===e.type?e.touches[0].clientY:e.clientY;if(this.clientY=n,this.clientX=o,r.interact.capturedSeriesIndex=-1,r.interact.capturedDataPointIndex=-1,n<l.top||n>l.top+l.height)return void this.handleMouseOut(t);if(Array.isArray(this.tConfig.enabledOnSeries)&&!r.config.tooltip.shared){let e=parseInt(t.paths.getAttribute("index"),10);if(0>this.tConfig.enabledOnSeries.indexOf(e))return void this.handleMouseOut(t)}let h=this.getElTooltip();if(!h)return;let d=this.getElXCrosshairs(),c=[];r.config.chart.group&&(c=this.ctx.getSyncedCharts());let g=r.globals.xyCharts||"bar"===r.config.chart.type&&!r.globals.isBarHorizontal&&this.tooltipUtil.hasBars()&&this.tConfig.shared||r.globals.comboCharts&&this.tooltipUtil.hasBars();if("mousemove"===e.type||"touchmove"===e.type||"mouseup"===e.type){if(r.globals.collapsedSeries.length+r.globals.ancillaryCollapsedSeries.length===r.seriesData.series.length)return;null!==d&&d.classList.add("apexcharts-active");let l=null==(i=this.yaxisTooltips)?void 0:i.filter(e=>!0===e),p=this.ycrosshairs;if(null!==p&&(null==l?void 0:l.length)&&p.classList.add("apexcharts-active"),g&&!this.showOnIntersect||c.length>1)this.handleStickyTooltip(e,o,n,t);else if("heatmap"===r.config.chart.type||"treemap"===r.config.chart.type){let i=this.intersect.handleHeatTreeTooltip({e,opt:t,x:s,y:a,type:r.config.chart.type});s=i.x,a=i.y,h.style.left=s+"px",h.style.top=a+"px"}else this.tooltipUtil.hasBars()&&this.intersect.handleBarTooltip({e,opt:t}),this.tooltipUtil.hasMarkers(0)&&this.intersect.handleMarkerTooltip({e,opt:t,x:s,y:a});if(this.yaxisTooltips&&this.yaxisTooltips.length)for(let e=0;e<r.config.yaxis.length;e++)this.axesTooltip.drawYaxisTooltipText(e,n,this.xyRatios);r.dom.baseEl.classList.add("apexcharts-tooltip-active"),t.tooltipEl.classList.add("apexcharts-active"),r.config.chart.accessibility.enabled&&r.config.chart.accessibility.announcements.enabled&&t.tooltipEl.removeAttribute("aria-hidden")}else("mouseout"===e.type||"touchend"===e.type)&&this.handleMouseOut(t)}nonAxisChartsTooltips({e,opt:t,tooltipRect:i}){var s,a,r,l;let o=this.w,n=t.paths.getAttribute("rel"),h=this.getElTooltip();if(!h)return;let d=o.dom.elWrap.getBoundingClientRect();if("mousemove"===e.type||"touchmove"===e.type){let e,l;o.dom.baseEl.classList.add("apexcharts-tooltip-active"),h.classList.add("apexcharts-active"),o.config.chart.accessibility.enabled&&o.config.chart.accessibility.announcements.enabled&&h.removeAttribute("aria-hidden"),this.tooltipLabels.drawSeriesTexts({ttItems:t.ttItems,i:parseInt(n,10)-1,shared:!1});let c=t.paths.querySelector("path[data\\:cx]")||t.paths;if(o.config.tooltip.intersect&&c.hasAttribute("data:cx")&&c.hasAttribute("data:cy")){let t=o.dom.Paper.node.getBoundingClientRect();e=t.left-d.left+parseFloat(c.getAttribute("data:cx"))-i.ttWidth/2,l=t.top-d.top+parseFloat(c.getAttribute("data:cy"))-i.ttHeight-10}else e=(null!=(s=o.interact.clientX)?s:0)-d.left-i.ttWidth/2,l=(null!=(a=o.interact.clientY)?a:0)-d.top-i.ttHeight-10;if(h.style.left=e+"px",h.style.top=l+"px",o.config.legend.tooltipHoverFormatter){let e=o.config.legend.tooltipHoverFormatter,t=n-1,i=null==(r=this.legendLabels)?void 0:r[t];if(!i)return;let s=e(i.getAttribute("data:default-text"),{seriesIndex:t,dataPointIndex:t,w:o});i.innerHTML=s}}else("mouseout"===e.type||"touchend"===e.type)&&(h.classList.remove("apexcharts-active"),o.dom.baseEl.classList.remove("apexcharts-tooltip-active"),o.config.legend.tooltipHoverFormatter&&(null==(l=this.legendLabels)||l.forEach(e
30=>{let t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(null!=t?t:"")})))}handleStickyTooltip(e,t,i,s){let a=this.w,r=this.tooltipUtil.getNearestValues({context:this,hoverArea:s.hoverArea,elGrid:s.elGrid,clientX:t,clientY:i}),l=r.j,o=r.capturedSeries;null!==o&&a.globals.collapsedSeriesIndices.includes(null!=o?o:-1)&&(o=null);let n=s.elGrid.getBoundingClientRect();if(r.hoverX<0||r.hoverX>n.width)return void this.handleMouseOut(s);if(null!==o)this.handleStickyCapturedSeries(e,null!=o?o:-1,s,null!=l?l:0);else if(this.tooltipUtil.isXoverlap(null!=l?l:0)||a.globals.isBarHorizontal){let t=a.seriesData.series.findIndex((e,t)=>!a.globals.collapsedSeriesIndices.includes(t));this.create(e,this,t,null!=l?l:0,s.ttItems)}}handleStickyCapturedSeries(e,t,i,s){let a=this.w;if(!this.tConfig.shared&&null===a.seriesData.series[t][s])return void this.handleMouseOut(i);if(void 0!==a.seriesData.series[t][s])this.tConfig.shared&&this.tooltipUtil.isXoverlap(s)&&this.tooltipUtil.isInitialSeriesSameLen()?this.create(e,this,t,s,i.ttItems):this.create(e,this,t,s,i.ttItems,!1);else if(this.tooltipUtil.isXoverlap(s)){let t=a.seriesData.series.findIndex((e,t)=>!a.globals.collapsedSeriesIndices.includes(t));this.create(e,this,t,s,i.ttItems)}}deactivateHoverFilter(){let e=this.w,t=new Y(this.w,this.ctx),i=e.dom.Paper.find(".apexcharts-bar-area");for(let e=0;e<i.length;e++)t.pathMouseLeave(i[e],void 0)}handleMouseOut(e){var t,i;let s=this.w,a=this.getElXCrosshairs();s.dom.baseEl.classList.remove("apexcharts-tooltip-active"),e.tooltipEl.classList.remove("apexcharts-active"),s.config.chart.accessibility.enabled&&s.config.chart.accessibility.announcements.enabled&&e.tooltipEl.setAttribute("aria-hidden","true"),this.deactivateHoverFilter(),"bubble"!==s.config.chart.type&&this.marker.resetPointsSize(),null!==a&&a.classList.remove("apexcharts-active");let r=this.ycrosshairs;if(null!==r&&r.classList.remove("apexcharts-active"),this.isXAxisTooltipEnabled&&(null==(t=this.xaxisTooltip)||t.classList.remove("apexcharts-active")),this.yaxisTooltips&&this.yaxisTooltips.length){null===this.yaxisTTEls&&(this.yaxisTTEls=[...s.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip")]);for(let e=0;e<this.yaxisTTEls.length;e++)this.yaxisTTEls[e].classList.remove("apexcharts-active")}s.config.legend.tooltipHoverFormatter&&(null==(i=this.legendLabels)||i.forEach(e=>{let t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(null!=t?t:"")}))}markerClick(e,t,i){let s=this.w;"function"==typeof s.config.chart.events.markerClick&&s.config.chart.events.markerClick(e,this.ctx,{seriesIndex:t,dataPointIndex:i,w:s}),this.ctx.events.fireEvent("markerClick",[e,this.ctx,{seriesIndex:t,dataPointIndex:i,w:s}])}create(e,t,i,s,a,r=null){var l,o,n,h,g,p,x,u,f,m,b,y,w,v,A,C,S,k,D;let L=this.w;"mouseup"===e.type&&this.markerClick(e,i,s),null===r&&(r=this.tConfig.shared);let M=this.tooltipUtil.hasMarkers(i),P=this.tooltipUtil.getElBars(),E=()=>{L.globals.markers.largestSize>0?t.marker.enlargePoints(s):t.tooltipPosition.moveDynamicPointsOnHover(s)};if(L.config.legend.tooltipHoverFormatter){let e=L.config.legend.tooltipHoverFormatter,t=Array.from(null!=(l=this.legendLabels)?l:[]);t.forEach(e=>{let t=e.getAttribute("data:default-text");e.innerHTML=decodeURIComponent(null!=t?t:"")});for(let a=0;a<t.length;a++){let l=t[a],h=parseInt(null!=(o=l.getAttribute("i"))?o:"",10),d=decodeURIComponent(null!=(n=l.getAttribute("data:default-text"))?n:""),c=e(d,{seriesIndex:r?h:i,dataPointIndex:s,w:L});if(r)l.innerHTML=0>L.globals.collapsedSeriesIndices.indexOf(h)?c:d;else if(l.innerHTML=h===i?c:d,i===h)break}}let T=L.rangeData,F=d(d({ttItems:a,i:i,j:s},(null==(x=null==(p=null==(g=null==(h=T.seriesRange)?void 0:h[i])?void 0:g[s])?void 0:p.y[0])?void 0:x.y1)!==void 0&&{y1:null==(b=null==(m=null==(f=null==(u=T.seriesRange)?void 0:u[i])?void 0:f[s])?void 0:m.y[0])?void 0:b.y1}),(null==(A=null==(v=null==(w=null==(y=T.seriesRange)?void 0:y[i])?void 0:w[s])?void 0:v.y[0])?void 0:A.y2)!==void 0&&{y2:null==(D=null==(k=null==(S=null==(C=T.seriesRange)?void 0:C[i])?void 0:S[s])?void 0:k.y[0])?void 0:D.y2});if(r){if(t.tooltipLabels.drawSeriesTexts(c(d({},F),{shared:!this.showOnIntersect&&this.tConfig.shared})),M)E();else if(this.tooltipUtil.hasBars()&&(this.barSeriesHeight=this.tooltipUtil.getBarsHeight([...P]),this.barSeriesHeight>0)){let e=new Y(this.w,this.ctx),a=L.dom.Paper.find(`.apexcharts-bar-area[j='${s}']`);this.deactivateHoverFilter(),t.tooltipUtil.getAllMarkers(!0).length&&!this.barSeriesHeight&&E(),t.tooltipPosition.moveStickyTooltipOverBars(s,i);for(let t=0;t<a.length;t++)e.pathMouseEnter(a[t],void 0)}}else t.tooltipLabels.drawSeriesTexts(d({shared:!1},F)),this.tooltipUtil.hasBars()&&t.tooltipPosition.moveStickyTooltipOverBars(s,i),M&&t.tooltipPosition.moveMarkers(i,s)}}class eL{constructor(e){this.node=e,e&&(e.instance=this),this._listeners=[],this._filter=null}attr(e,t){if("string"==typeof e&&void 0===t)return this.node.getAttribute(e);let i="string"==typeof e?{[e]:t}:e;for(let e in i){let t=i[e];null===t?this.node.removeAttribute(e):void 0!==t&&("number"==typeof t&&isNaN(t)&&(t=0),this.node.setAttribute(e,t))}if("text"===this.node.nodeName&&null!=i.x){let e=this.node.querySelectorAll("tspan[data-newline]");for(let t=0;t<e.length;t++)e[t].setAttribute("x",i.x)}return this}css(e){for(let t in e)this.node.style[t]=e[t];return this}fill(e){return"object"==typeof e?this.attr(e):this.attr("fill",e)}
30stroke(e){return"object"==typeof e?(void 0!==e.color&&this.attr("stroke",e.color),void 0!==e.width&&this.attr("stroke-width",e.width),void 0!==e.dasharray&&this.attr("stroke-dasharray",e.dasharray),void 0!==e.linecap&&this.attr("stroke-linecap",e.linecap),void 0!==e.opacity&&this.attr("stroke-opacity",e.opacity),this):this.attr("stroke",e)}size(e,t){return this.attr({width:e,height:t})}move(e,t){return this.attr({x:e,y:t})}center(e,t){if("g"===this.node.nodeName){let i=this.bbox(),s=e-(i.x+i.width/2),a=t-(i.y+i.height/2);return this.attr("transform",`translate(${s}, ${a})`)}return this.attr({cx:e,cy:t})}add(e){return this.node.appendChild(e.node||e),this}addTo(e){return(e.node||e).appendChild(this.node),this}remove(){return this.node.parentNode&&this.node.parentNode.removeChild(this.node),this}clear(){for(;this.node.firstChild;)this.node.removeChild(this.node.firstChild);return this}find(e){return Array.from(this.node.querySelectorAll(e)).map(e=>e.instance||new eL(e))}findOne(e){let t=this.node.querySelector(e);return t?t.instance||new eL(t):null}on(e,t){let i=e.split(".")[0];return this._listeners.push({event:e,eventType:i,handler:t}),this.node.addEventListener(i,t),this}off(e,t){if(e||t)if(e&&!t){let t=e.split(".")[0];this._listeners=this._listeners.filter(e=>e.eventType!==t||(this.node.removeEventListener(e.eventType,e.handler),!1))}else{let i=e.split(".")[0];this._listeners=this._listeners.filter(e=>e.eventType!==i||e.handler!==t||(this.node.removeEventListener(e.eventType,e.handler),!1))}else this._listeners.forEach(e=>{this.node.removeEventListener(e.eventType,e.handler)}),this._listeners=[];return this}each(e,t){return Array.from(this.node.children).forEach(i=>{let s=i.instance||new eL(i);e.call(s),t&&s.each(e,t)}),this}removeClass(e){return"*"===e?this.node.removeAttribute("class"):this.node.classList.remove(e),this}children(){return Array.from(this.node.childNodes).filter(e=>1===e.nodeType).map(e=>e.instance||new eL(e))}hide(){return this.node.style.display="none",this}show(){return this.node.style.display="",this}bbox(){if("function"==typeof this.node.getBBox)try{return this.node.getBBox()}catch(e){}return{x:0,y:0,width:0,height:0}}tspan(e){let t=w.createElementNS("http://www.w3.org/2000/svg","tspan");return t.textContent=e,this.node.appendChild(t),new eL(t)}plot(e){return"string"==typeof e&&this.attr("d",e),this}animate(){throw Error("Animation module not loaded")}filterWith(){throw Error("Filter module not loaded")}unfilter(e){return this._filter&&(this.node.removeAttribute("filter"),e&&this._filter.node&&this._filter.node.parentNode&&this._filter.node.parentNode.removeChild(this._filter.node),this._filter=null),this}filterer(){return this._filter}}let eM=0;class eP extends eL{constructor(e,t,i){super(w.createElementNS(B,"radial"===t?"radialGradient":"linearGradient")),this._id="SvgjsGradient"+ ++eM,this.attr("id",this._id),"function"==typeof i&&i(new eE(this));let s=e.node.querySelector("defs");s||(s=w.createElementNS(B,"defs"),e.node.appendChild(s)),s.appendChild(this.node)}stop(e,t,i){let s=w.createElementNS(B,"stop");return s.setAttribute("offset",e),s.setAttribute("stop-color",t),void 0!==i&&s.setAttribute("stop-opacity",String(i)),this.node.appendChild(s),this}from(e,t){return this.attr({x1:e,y1:t})}to(e,t){return this.attr({x2:e,y2:t})}url(){return"url(#"+this._id+")"}toString(){return this.url()}valueOf(){return this.url()}fill(){return this.url()}}class eE{constructor(e){this.gradient=e}stop(e,t,i){return this.gradient.stop(e,t,i),this}}let eT=0;class eF extends eL{constructor(e,t,i,s){super(w.createElementNS(B,"pattern")),this._id="SvgjsPattern"+ ++eT,this.attr({id:this._id,width:t,height:i,patternUnits:"userSpaceOnUse"}),"function"==typeof s&&s(new eX(this.node));let a=e.node.querySelector("defs");a||(a=w.createElementNS(B,"defs"),e.node.appendChild(a)),a.appendChild(this.node)}url(){return"url(#"+this._id+")"}toString(){return this.url()}valueOf(){return this.url()}fill(){return this.url()}}class eX extends eL{line(e,t,i,s){let a=this._make("line");return void 0!==e&&a.attr({x1:e,y1:t,x2:i,y2:s}),a}rect(e,t){let i=this._make("rect");return void 0!==e&&i.attr({width:e,height:t}),i}circle(e){let t=this._make("circle");return void 0!==e&&t.attr({r:e/2,cx:e/2,cy:e/2}),t}path(e){let t=this._make("path");return e&&t.attr("d",e),t}polygon(e){let t=this._make("polygon");return e&&t.attr("points",e),t}group(){return this._makeContainer("g")}defs(){return this._makeContainer("defs")}plain(e){let t=w.createElementNS(B,"text");t.textContent=e;let i=new eL(t);return this.node.appendChild(t),i}text(e){let t=w.createElementNS(B,"text"),i=new eL(t);return this.node.appendChild(t),"function"==typeof e&&e(new eI(t)),i}image(e,t){let i=w.createElementNS(B,"image");i.setAttributeNS("http://www.w3.org/1999/xlink","href",e);let s=new eL(i);if(this.node.appendChild(i),"function"==typeof t){let i=new Image;i.onload=function(){s.size(i.width,i.height),t.call(s,{width:i.width,height:i.height})},i.src=e}return s}gradient(e,t){return new eP(this,e,t)}pattern(e,t,i){return new eF(this,e,t,i)}_make(e){let t=w.createElementNS(B,e);return this.node.appendChild(t),new eL(t)}_makeContainer(e){let t=w.createElementNS(B,e);return this.node.appendChild(t),new eX(t)}}class eI{constructor(e){this.textNode=e}tspan(e){let t=w.createElementNS(B,"tspan");return t.textContent=e,this.textNode.appendChild(t),new eR(t,this.textNode)}}class eR{constructor(e,t){this.node=e,this.textNode=t}newLine(){return this.node.setAttribute("dy","1.1em"),this.node.dataset.newline="1",this}}let ez=0;class eY extends eL{constructor(){super(w.createElementNS(B,"filter")),this._id="SvgjsFilter"+ ++ez,this.attr("id",this._id)}size(e,t,i,s){return this.attr({width:e,height:t,x:i,y:s})}}class eB{constructor(e){this.filter=e}colorMatrix(e){return this._primitive("feColorMatrix",e)}offset(e){return this._primitive("feOffset",e)}gaussianBlur(e){return this._primitive("feGaussianBlur",e)}flood(e){return this._primitive("feFlood",e)}composite(e){return this._primitive("feComposite",e)}merge(e){let t=w.createElementNS(B,"feMerge");
30return e.forEach(e=>{let i=w.createElementNS(B,"feMergeNode");i.setAttribute("in",e),t.appendChild(i)}),this.filter.node.appendChild(t),new eL(t)}_primitive(e,t){let i=w.createElementNS(B,e);for(let e in t)i.setAttribute(e,t[e]);return this.filter.node.appendChild(i),new eL(i)}}function eH(e){let t;if(!e||"string"!=typeof e)return[["M",0,0]];let i=[],s=/([MmLlHhVvCcSsQqTtAaZz])\s*/g,a=/[+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?/gi,r=[],l=[];for(;null!==(t=s.exec(e));)r.push(t[1]),l.push(t.index);for(let t=0;t<r.length;t++){let s,o=l[t]+r[t].length,n=t+1<l.length?l[t+1]:e.length,h=e.substring(o,n),d=[];for(a.lastIndex=0;null!==(s=a.exec(h));)d.push(parseFloat(s[0]));let c=r[t].toUpperCase();if("Z"===c)i.push(["Z"]);else if("M"===c||"L"===c||"T"===c)for(let e=0;e<d.length;e+=2)i.push([c,d[e],d[e+1]]);else if("H"===c)for(let e=0;e<d.length;e++)i.push([c,d[e]]);else if("V"===c)for(let e=0;e<d.length;e++)i.push([c,d[e]]);else if("C"===c)for(let e=0;e<d.length;e+=6)i.push([c,d[e],d[e+1],d[e+2],d[e+3],d[e+4],d[e+5]]);else if("S"===c||"Q"===c)for(let e=0;e<d.length;e+=4)i.push([c,d[e],d[e+1],d[e+2],d[e+3]]);else if("A"===c)for(let e=0;e<d.length;e+=7)i.push([c,d[e],d[e+1],d[e+2],d[e+3],d[e+4],d[e+5],d[e+6]])}return 0===i.length&&i.push(["M",0,0]),i}function eN(e){let t=1/0,i=1/0,s=-1/0,a=-1/0;return(e.forEach(e=>{for(let r=1;r<e.length;r+=2)if(r+1<=e.length){let l=e[r],o=e[r+1];"number"==typeof l&&"number"==typeof o&&(l<t&&(t=l),l>s&&(s=l),o<i&&(i=o),o>a&&(a=o))}}),t===1/0)?{x:0,y:0,width:0,height:0}:{x:t,y:i,width:s-t,height:a-i}}function eO(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 eW(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 e_(e){var t,i=[e];switch(e[0]){case"M":return this.pos=this.start=[e[1],e[2]],i;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]=e[4]/3+2*e[2]/3,e[3]=e[3]/3+2*e[1]/3,e[2]=this.pos[1]/3+2*e[2]/3,e[1]=this.pos[0]/3+2*e[1]/3;break;case"A":e=(i=function(e,t){var i,s,a,r,l,o,n,h,d,c,g,p,x,u,f,m,b,y,w,v,A,C,S,k,D,L,M=Math.abs(t[1]),P=Math.abs(t[2]),E=t[3]%360,T=t[4],F=t[5],X=t[6],I=t[7],R=new H(e[0],e[1]),z=new H(X,I),Y=[];if(0===M||0===P||R.x===z.x&&R.y===z.y)return[["C",R.x,R.y,z.x,z.y,z.x,z.y]];for((s=(i=new H((R.x-z.x)/2,(R.y-z.y)/2).transform(new N(0,0,0,0,0,0).rotate(E))).x*i.x/(M*M)+i.y*i.y/(P*P))>1&&(M*=s=Math.sqrt(s),P*=s),a=new N(0,0,0,0,0,0).rotate(E).scale(1/M,1/P).rotate(-E),R=R.transform(a),l=Math.sqrt(o=(r=[(z=z.transform(a)).x-R.x,z.y-R.y])[0]*r[0]+r[1]*r[1]),r[0]/=l,r[1]/=l,n=o<4?Math.sqrt(1-o/4):0,T===F&&(n*=-1),h=new H((z.x+R.x)/2+-(n*r[1]),(z.y+R.y)/2+n*r[0]),d=new H(R.x-h.x,R.y-h.y),c=new H(z.x-h.x,z.y-h.y),g=Math.acos(d.x/Math.sqrt(d.x*d.x+d.y*d.y)),d.y<0&&(g*=-1),p=Math.acos(c.x/Math.sqrt(c.x*c.x+c.y*c.y)),c.y<0&&(p*=-1),F&&g>p&&(p+=2*Math.PI),!F&&g<p&&(p-=2*Math.PI),u=Math.ceil(2*Math.abs(g-p)/Math.PI),m=[],b=g,f=4*Math.tan((x=(p-g)/u)/4)/3,A=0;A<=u;A++)w=Math.cos(b),y=Math.sin(b),v=new H(h.x+w,h.y+y),m[A]=[new H(v.x+f*y,v.y-f*w),v,new H(v.x-f*y,v.y+f*w)],b+=x;for(A=0,m[0][0]=m[0][1].clone(),m[m.length-1][2]=m[m.length-1][1].clone(),a=new N(0,0,0,0,0,0).rotate(E).scale(M,P).rotate(-E),C=m.length;A<C;A++)m[A][0]=m[A][0].transform(a),m[A][1]=m[A][1].transform(a),m[A][2]=m[A][2].transform(a);for(A=1,C=m.length;A<C;A++)S=(v=m[A-1][2]).x,k=v.y,D=(v=m[A][0]).x,L=v.y,X=(v=m[A][1]).x,Y.push(["C",S,k,D,L,X,I=v.y]);return Y}(null!=(t=this.pos)?t:[],e))[0]}return e[0]="C",this.pos=[e[5],e[6]],this.reflection=[2*e[5]-e[3],2*e[6]-e[4]],i}function e$(e,t){if(!1===t)return!1;for(var i=t,s=e.length;i<s;++i)if("M"==e[i][0])return i;return!1}function eG(e){if(!e||"string"!=typeof e)return null;if("#"===e[0]){let t=e.slice(1);3===t.length&&(t=t[0]+t[0]+t[1]+t[1]+t[2]+t[2]);let i=parseInt(t,16);return[i>>16&255,i>>8&255,255&i,1]}let t=e.match(/rgba?\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*([\d.]+))?\s*\)/);return t?[+t[1],+t[2],+t[3],void 0!==t[4]?+t[4]:1]:null}class eV{constructor(e,t,i){this.el=e,this.duration=null!=t?t:300,this.delay=i||0,this._attrTarget=null,this._plotTarget=null,this._afterCb=null,this._duringCb=null,this._next=null,this._root=null,this._scheduled=!1}attr(e){return this._attrTarget=e,this._schedule(),this}plot(e){return this._plotTarget=e,this._schedule(),this}after(e){return this._afterCb=e,this._schedule(),this}during(e){return this._duringCb=e,this._schedule(),this}animate(e,t){let i=new eV(this.el,e,t);return this._next=i,i._root=this._root||this,i}_schedule(){let e=this._root||this;e._scheduled||(e._scheduled=!0,queueMicrotask(()=>e._executeChain()))}_executeChain(){let e=[],t=this;for(;t;)e.push(t),t=t._next;let i=0;
30e.forEach(e=>{i+=e.delay,e._execute(i),i+=e.duration})}_execute(e){let t=this.el,i=this.duration;if(i<=1){let i=()=>{this._attrTarget&&t.attr(this._attrTarget),this._plotTarget&&t.plot(this._plotTarget),this._afterCb&&this._afterCb.call(t)};e>0?setTimeout(i,e):i();return}let s=()=>{let e={},s={},a={};if(this._attrTarget)for(let i of Object.keys(this._attrTarget)){let r=t.attr(i);e[i]=r;let l=eG(r),o=eG(String(this._attrTarget[i]));l&&o&&(s[i]=l,a[i]=o)}let r=null;if(this._plotTarget){let e=t.attr("d")||"";try{var l,o,n,h;l=this._plotTarget,n=(o=function(e,t){for(var i,s=eH(e),a=eH(t),r=0,l=0,o=!1,n=!1;!1!==r||!1!==l;){if(o=e$(s,!1!==r&&r+1),n=e$(a,!1!==l&&l+1),!1===r){let e=eN(i.start);r=0==e.height||0==e.width?s.push(s[0])-1:s.push(["M",e.x+e.width/2,e.y+e.height/2])-1}if(!1===l){let e=eN(i.dest);l=0==e.height||0==e.width?a.push(a[0])-1:a.push(["M",e.x+e.width/2,e.y+e.height/2])-1}i=function(e,t,i,s,a,r){for(var l=e.slice(t,i||void 0),o=s.slice(a,r||void 0),n=0,h={pos:[0,0],start:[0,0]},d={pos:[0,0],start:[0,0]};l[n]=eO.call(h,l[n]),o[n]=eO.call(d,o[n]),l[n][0]!=o[n][0]||"M"==l[n][0]||"A"==l[n][0]&&(l[n][4]!=o[n][4]||l[n][5]!=o[n][5])?(Array.prototype.splice.apply(l,[n,1].concat(e_.call(h,l[n]))),Array.prototype.splice.apply(o,[n,1].concat(e_.call(d,o[n])))):(l[n]=eW.call(h,l[n]),o[n]=eW.call(d,o[n])),++n!=l.length||n!=o.length;)n==l.length&&l.push(["C",h.pos[0],h.pos[1],h.pos[0],h.pos[1],h.pos[0],h.pos[1]]),n==o.length&&o.push(["C",d.pos[0],d.pos[1],d.pos[0],d.pos[1],d.pos[0],d.pos[1]]);return{start:l,dest:o}}(s,r,o,a,l,n),s=s.slice(0,r).concat(i.start,!1===o?[]:s.slice(o)),a=a.slice(0,l).concat(i.dest,!1===n?[]:a.slice(n)),r=!1!==o&&r+i.start.length,l=!1!==n&&l+i.dest.length}return{start:s,dest:a}}(e,l)).start,h=o.dest,r=function(e){return n.map(function(t,i){return h[i].map(function(s,a){return 0===a?s:t[a]+(h[i][a]-t[a])*e})}).map(e=>e.join(" ")).join(" ")}}catch(e){r=null}}let d=performance.now(),c=l=>{let o=Math.min((l-d)/i,1),n=-Math.cos(o*Math.PI)/2+.5;if(this._attrTarget)if(o>=1)t.attr(this._attrTarget);else{let i={};for(let t of Object.keys(this._attrTarget))if(s[t]&&a[t]){var h,g;i[t]=(h=s[t],g=a[t],`rgba(${Math.round(h[0]+(g[0]-h[0])*n)},${Math.round(h[1]+(g[1]-h[1])*n)},${Math.round(h[2]+(g[2]-h[2])*n)},${h[3]+(g[3]-h[3])*n})`)}else{let s=parseFloat(e[t]),a=parseFloat(this._attrTarget[t]);isNaN(s)||isNaN(a)||(i[t]=s+(a-s)*n)}t.attr(i)}r&&o<1&&t.attr("d",r(n)),this._duringCb&&this._duringCb(n),o<1?w.requestAnimationFrame(c):(this._plotTarget&&t.attr("d",this._plotTarget),this._afterCb&&this._afterCb.call(t))};w.requestAnimationFrame(c)};e>0?setTimeout(s,e):s()}}function ej(){let e=new eX(w.createElementNS(B,"svg"));return e.attr({xmlns:B}),e}eL.prototype.filterWith=function(e){let t=new eY;this._filter=t;let i=this.node;for(;i&&"svg"!==i.nodeName;)i=i.parentNode;if(i){let e=i.querySelector("defs");e||(e=w.createElementNS(B,"defs"),i.insertBefore(e,i.firstChild)),e.appendChild(t.node)}return e(new eB(t)),this.attr("filter","url(#"+t._id+")"),this},eL.prototype.unfilter=function(e){return this._filter&&(this.node.removeAttribute("filter"),e&&this._filter.node&&this._filter.node.parentNode&&this._filter.node.parentNode.removeChild(this._filter.node),this._filter=null),this},eL.prototype.filterer=function(){return this._filter},eL.prototype.animate=function(e,t){return new eV(this,e,t)},eL.prototype.draggable=function(e){if(!1===e)return this._dragCleanup&&(this._dragCleanup(),this._dragCleanup=null),this;let t=this,i=e||{},s=e=>{if(e.button&&0!==e.button)return;e.stopPropagation();let s="touchstart"===e.type?e.touches[0]:e,a=t.node,r=parseFloat(a.getAttribute("x"))||0,l=parseFloat(a.getAttribute("y"))||0,o=s.clientX,n=s.clientY,h=a.ownerSVGElement,d=null;h&&(d=h.getScreenCTM());let c=e=>{let t="touchmove"===e.type?e.touches[0]:e,s=t.clientX-o,h=t.clientY-n;d&&(s/=d.a,h/=d.d);let c=r+s,g=l+h,p=parseFloat(a.getAttribute("width"))||0,x=parseFloat(a.getAttribute("height"))||0;void 0!==i.minX&&c<i.minX&&(c=i.minX),void 0!==i.minY&&g<i.minY&&(g=i.minY),void 0!==i.maxX&&c+p>i.maxX&&(c=i.maxX-p),void 0!==i.maxY&&g+x>i.maxY&&(g=i.maxY-x);let u=new CustomEvent("dragmove",{detail:{handler:{move:function(e,t){a.setAttribute("x",e),a.setAttribute("y",t)}},box:{x:c,y:g,w:p,h:x,x2:c+p,y2:g+x}}});a.dispatchEvent(u)},g=()=>{p.isBrowser()&&(document.removeEventListener("mousemove",c),document.removeEventListener("touchmove",c),document.removeEventListener("mouseup",g),document.removeEventListener("touchend",g))};p.isBrowser()&&(document.addEventListener("mousemove",c),document.addEventListener("touchmove",c),document.addEventListener("mouseup",g),document.addEventListener("touchend",g))};return t.node.addEventListener("mousedown",s),t.node.addEventListener("touchstart",s),t._dragCleanup=()=>{t.node.removeEventListener("mousedown",s),t.node.removeEventListener("touchstart",s)},t},eL.prototype.select=function(e){if(!1===e)return this._selectCleanup&&(this._selectCleanup(),this._selectCleanup=null),this;let t=this,{createHandle:i,updateHandle:s}=e,a=document.createElementNS(B,"g");a.setAttribute("class","svg_select_points");let r=t.node.parentNode;r&&r.appendChild(a);let l={},o=["t","b","l","r","lt","rt","lb","rb"];o.forEach((e,t)=>{let s=new eX(document.createElementNS(B,"g"));a.appendChild(s.node);let r=i(s,[0,0],t,[],e);l[e]={group:s,handle:r}});let n=()=>{let e=parseFloat(t.attr("x"))||0,i=parseFloat(t.attr("y"))||0,r=parseFloat(t.attr("width"))||0,n=parseFloat(t.attr("height"))||0,h=t.node.getAttribute("transform");h?a.setAttribute("transform",h):a.removeAttribute("transform");let d={t:[e+r/2,i],b:[e+r/2,i+n],l:[e,i+n/2],r:[e+r,i+n/2],lt:[e,i],rt:[e+r,i],lb:[e,i+n],rb:[e+r,i+n]};
30o.forEach(e=>{l[e]&&d[e]&&s(l[e].group,d[e])})};return n(),t._selectHandles=a,t._selectHandlesMap=l,t._updateSelectPositions=n,t._selectCleanup=()=>{a.parentNode&&a.parentNode.removeChild(a),t._selectHandles=null,t._selectHandlesMap=null,t._updateSelectPositions=null},t},eL.prototype.resize=function(e){if(!1===e)return this._resizeCleanup&&(this._resizeCleanup(),this._resizeCleanup=null),this;let t=this,i=t._selectHandlesMap;if(!i)return t;let s=[],a=e=>{let a=i[e];if(!a||!a.group||!a.group.node)return;let r=a.group.node,l=i=>{if(i.button&&0!==i.button)return;i.stopPropagation();let s=("touchstart"===i.type?i.touches[0]:i).clientX,a=t.node.ownerSVGElement,r=null;a&&(r=a.getScreenCTM());let l=parseFloat(t.attr("x"))||0,o=parseFloat(t.attr("width"))||0,n=i=>{let a=("touchmove"===i.type?i.touches[0]:i).clientX-s;r&&(a/=r.a);let n=l,h=o;"l"===e?(n=l+a,h=o-a):"r"===e&&(h=o+a),h<0&&(h=0),t.attr({x:n,width:h}),t._updateSelectPositions&&t._updateSelectPositions();let d=new CustomEvent("resize",{detail:{el:t}});t.node.dispatchEvent(d)},h=()=>{p.isBrowser()&&(document.removeEventListener("mousemove",n),document.removeEventListener("touchmove",n),document.removeEventListener("mouseup",h),document.removeEventListener("touchend",h));let e=new CustomEvent("resize",{detail:{el:t}});t.node.dispatchEvent(e)};p.isBrowser()&&(document.addEventListener("mousemove",n),document.addEventListener("touchmove",n),document.addEventListener("mouseup",h),document.addEventListener("touchend",h))};r.addEventListener("mousedown",l),r.addEventListener("touchstart",l),s.push(()=>{r.removeEventListener("mousedown",l),r.removeEventListener("touchstart",l)})};return a("l"),a("r"),t._resizeCleanup=()=>{s.forEach(e=>e())},t},ej.xlink="http://www.w3.org/1999/xlink",p.isBrowser()&&void 0===window.SVG&&(window.SVG=ej),p.isBrowser()?(void 0===window.SVG&&(window.SVG=ej),void 0===window.Apex&&(window.Apex={})):void 0!==i.g&&(void 0===i.g.Apex&&(i.g.Apex={}),void 0===i.g.SVG&&(i.g.SVG=ej));let eU=class e{static registerFeatures(t){for(let[i,s]of Object.entries(t))e._featureRegistry.set(i,s)}constructor(e){this.ctx=e,this.w=e.w}initModules(){this.ctx.publicMethods=["updateOptions","updateSeries","appendData","appendSeries","isSeriesHidden","highlightSeries","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","keydown","keyup"],this.ctx.animations=new R(this.w,this.ctx),this.ctx.axes=new ei(this.w,this.ctx),this.ctx.core=new em(this.ctx.el,this.w,this.ctx),this.ctx.config=new P({}),this.ctx.data=new eb(this.w,{resetGlobals:()=>this.ctx.core.resetGlobals(),isMultipleY:()=>this.ctx.core.isMultipleY()}),this.ctx.grid=new Z(this.w,this.ctx),this.ctx.graphics=new Y(this.w,this.ctx),this.ctx.coreUtils=new I(this.w),this.ctx.crosshairs=new es(this.w),this.ctx.events=new ee(this.w,this.ctx),this.ctx.fill=new W(this.w),this.ctx.localization=new et(this.w),this.ctx.options=new M,this.ctx.responsive=new ea(this.w),this.ctx.series=new er(this.w,{toggleDataSeries:(...e)=>{var t;return null==(t=this.ctx.legend)?void 0:t.legendHelpers.toggleDataSeries(...e)},revertDefaultAxisMinMax:()=>this.ctx.updateHelpers.revertDefaultAxisMinMax(),updateSeries:(...e)=>this.ctx.updateHelpers._updateSeries(...e)}),this.ctx.theme=new el(this.w),this.ctx.formatters=new C(this.w),this.ctx.titleSubtitle=new eo(this.w),this.ctx.dimensions=new eg(this.w,this.ctx),this.ctx.updateHelpers=new ey(this.w,this.ctx);let e=new eD(this.w,this.ctx);this.w.globals.tooltip=e,Object.defineProperty(this.ctx,"tooltip",{get(){return this.w.globals.tooltip},configurable:!0}),this._initOptionalModules()}_initOptionalModules(){let t=e._featureRegistry,i=this.w,s=this.ctx,a=t.get("exports");s.exports=a?new a(i,s):null;let r=t.get("legend");s.legend=r?new r(i,s):null;let l=t.get("toolbar");Object.defineProperty(s,"toolbar",{get(){var e;
30return!this._toolbar&&l&&(this._toolbar=new l(i,this)),null!=(e=this._toolbar)?e:null},configurable:!0});let o=t.get("zoomPanSelection");Object.defineProperty(s,"zoomPanSelection",{get(){var e;return!this._zoomPanSelection&&o&&(this._zoomPanSelection=new o(i,this)),null!=(e=this._zoomPanSelection)?e:null},configurable:!0});let n=t.get("keyboardNavigation");Object.defineProperty(s,"keyboardNavigation",{get(){var e;return!this._keyboardNavigation&&n&&(this._keyboardNavigation=new n(i,this)),null!=(e=this._keyboardNavigation)?e:null},configurable:!0})}};g(eU,"_featureRegistry",new Map);class eZ{constructor(e){this.ctx=e,this.w=e.w}clear({isUpdating:e}){this.ctx._zoomPanSelection&&this.ctx._zoomPanSelection.destroy(),this.ctx._toolbar&&this.ctx._toolbar.destroy(),this.w.globals.resizeObserver&&"function"==typeof this.w.globals.resizeObserver.disconnect&&(this.w.globals.resizeObserver.disconnect(),this.w.globals.resizeObserver=null),V.invalidateAll(this.w),e?(this.ctx._zoomPanSelection=null,this.ctx._toolbar=null,this.ctx._keyboardNavigation=null):(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._keyboardNavigation=null,this.ctx.w.globals.tooltip=null),this.clearDomElements({isUpdating:e})}killSVG(e){e.each(function(){this.removeClass("*"),this.off()},!0),e.clear()}clearDomElements({isUpdating:e}){let t=this.w.dom;if(p.isBrowser()){let i=t.Paper.node;i.parentNode&&i.parentNode.parentNode&&!e&&(i.parentNode.parentNode.style.minHeight="unset");let s=t.baseEl;if(s&&this.ctx.eventList.forEach(e=>{s.removeEventListener(e,this.ctx.events.documentEvent)}),null!==this.ctx.el)for(;this.ctx.el.firstChild;)this.ctx.el.removeChild(this.ctx.el.firstChild);this.killSVG(t.Paper),t.Paper.remove()}t.elWrap=null,t.elGraphical=null,t.elLegendWrap=null,t.elLegendForeign=null,t.baseEl=null,t.elGridRect=null,t.elGridRectMask=null,t.elGridRectBarMask=null,t.elGridRectMarkerMask=null,t.elForecastMask=null,t.elNonForecastMask=null,t.elDefs=null}}let eq=new WeakMap,eK=`@keyframes opaque {
31  0% {
32    opacity: 0
33  }
34
35  to {
36    opacity: 1
37  }
38}
39
40@keyframes resizeanim {
41
42  0%,
43  to {
44    opacity: 0
45  }
46}
47
48.apexcharts-canvas {
49  position: relative;
50  direction: ltr !important;
51  user-select: none;
52  /* Focus indicator colour. Themes override below. */
53  --apexcharts-focus-color: #008FFB;
54}
55
56/* Dark theme & high-contrast: brighter focus colour for sufficient contrast. */
57.apexcharts-canvas .apexcharts-theme-dark,
58.apexcharts-theme-dark.apexcharts-canvas {
59  --apexcharts-focus-color: #FFD500;
60}
61.apexcharts-canvas.apexcharts-high-contrast,
62.apexcharts-high-contrast.apexcharts-canvas {
63  --apexcharts-focus-color: #FFFF00;
64}
65
66/* Visually-hidden aria-live status region (WCAG 4.1.3 Status Messages). */
67.apexcharts-sr-status {
68  position: absolute;
69  width: 1px;
70  height: 1px;
71  padding: 0;
72  margin: -1px;
73  overflow: hidden;
74  clip: rect(0, 0, 0, 0);
75  white-space: nowrap;
76  border: 0;
77}
78
79/* Respect OS-level reduced-motion preference (WCAG 2.3.3). */
80@media (prefers-reduced-motion: reduce) {
81  .apexcharts-canvas *,
82  .apexcharts-canvas *::before,
83  .apexcharts-canvas *::after {
84    animation-duration: 0.01ms !important;
85    animation-iteration-count: 1 !important;
86    transition-duration: 0.01ms !important;
87  }
88}
89
90.apexcharts-canvas ::-webkit-scrollbar {
91  -webkit-appearance: none;
92  width: 6px
93}
94
95.apexcharts-canvas ::-webkit-scrollbar-thumb {
96  border-radius: 4px;
97  background-color: rgba(0, 0, 0, .5);
98  box-shadow: 0 0 1px rgba(255, 255, 255, .5);
99  -webkit-box-shadow: 0 0 1px rgba(255, 255, 255, .5)
100}
101
102.apexcharts-inner {
103  position: relative
104}
105
106.apexcharts-text tspan {
107  font-family: inherit
108}
109
110rect.legend-mouseover-inactive,
111.legend-mouseover-inactive rect,
112.legend-mouseover-inactive path,
113.legend-mouseover-inactive circle,
114.legend-mouseover-inactive line,
115.legend-mouseover-inactive text.apexcharts-yaxis-title-text,
116.legend-mouseover-inactive text.apexcharts-yaxis-label {
117  transition: .15s ease all;
118  opacity: .2
119}
120
121.apexcharts-legend-text {
122  padding-left: 15px;
123  margin-left: -15px;
124}
125
126.apexcharts-legend-series[role="button"]:focus {
127  outline: 2px solid var(--apexcharts-focus-color, #008FFB);
128  outline-offset: 2px;
129}
130
131.apexcharts-legend-series[role="button"]:focus:not(:focus-visible) {
132  outline: none;
133}
134
135.apexcharts-legend-series[role="button"]:focus-visible {
136  outline: 2px solid var(--apexcharts-focus-color, #008FFB);
137  outline-offset: 2px;
138}
139
140.apexcharts-series-collapsed {
141  opacity: 0
142}
143
144.apexcharts-canvas svg:focus:not(:focus-visible) {
145  outline: none;
146}
147
148/* Keyboard navigation focus indicator on SVG data elements.
149   SVG elements don't support CSS outline, so we use stroke. */
150.apexcharts-bar-area.apexcharts-keyboard-focused,
151.apexcharts-candlestick-area.apexcharts-keyboard-focused,
152.apexcharts-boxPlot-area.apexcharts-keyboard-focused,
153.apexcharts-rangebar-area.apexcharts-keyboard-focused,
154.apexcharts-pie-area.apexcharts-keyboard-focused,
155.apexcharts-heatmap-rect.apexcharts-keyboard-focused,
156.apexcharts-treemap-rect.apexcharts-keyboard-focused {
157  stroke: var(--apexcharts-focus-color, #008FFB);
158  stroke-width: 2;
159  stroke-opacity: 1;
160}
161
162.apexcharts-tooltip {
163  border-radius: 5px;
164  box-shadow: 2px 2px 6px -4px #999;
165  cursor: default;
166  font-size: 14px;
167  left: 62px;
168  opacity: 0;
169  pointer-events: none;
170  position: absolute;
171  top: 20px;
172  display: flex;
173  flex-direction: column;
174  overflow: hidden;
175  white-space: nowrap;
176  z-index: 12;
177  transition: .15s ease all
178}
179
180.apexcharts-tooltip.apexcharts-active {
181  opacity: 1;
182  transition: .15s ease all
183}
184
185.apexcharts-tooltip.apexcharts-theme-light {
186  border: 1px solid #e3e3e3;
187  background: rgba(255, 255, 255, .96)
188}
189
190.apexcharts-tooltip.apexcharts-theme-dark {
191  color: #fff;
192  background: rgba(30, 30, 30, .8)
193}
194
195.apexcharts-tooltip * {
196  font-family: inherit
197}
198
199.apexcharts-tooltip-title {
200  padding: 6px;
201  font-size: 15px;
202  margin-bottom: 4px
203}
204
205.apexcharts-tooltip.apexcharts-theme-light .apexcharts-tooltip-title {
206  background: #eceff1;
207  border-bottom: 1px solid #ddd
208}
209
210.apexcharts-tooltip.apexcharts-theme-dark .apexcharts-tooltip-title {
211  background: rgba(0, 0, 0, .7);
212  border-bottom: 1px solid #333
213}
214
215.apexcharts-tooltip-text-goals-value,
216.apexcharts-tooltip-text-y-value,
217.apexcharts-tooltip-text-z-value {
218  display: inline-block;
219  margin-left: 5px;
220  font-weight: 600
221}
222
223.apexcharts-tooltip-text-goals-label:empty,
224.apexcharts-tooltip-text-goals-value:empty,
225.apexcharts-tooltip-text-y-label:empty,
226.apexcharts-tooltip-text-y-value:empty,
227.apexcharts-tooltip-text-z-value:empty,
228.apexcharts-tooltip-title:empty {
229  display: none
230}
231
232.apexcharts-tooltip-text-goals-label,
233.apexcharts-tooltip-text-goals-value {
234  padding: 6px 0 5px
235}
236
237.apexcharts-tooltip-goals-group,
238.apexcharts-tooltip-text-goals-label,
239.apexcharts-tooltip-text-goals-value {
240  display: flex
241}
242
243.apexcharts-tooltip-text-goals-label:not(:empty),
244.apexcharts-tooltip-text-goals-value:not(:empty) {
245  margin-top: -6px
246}
247
248.apexcharts-tooltip-marker {
249  display: inline-block;
250  position: relative;
251  width: 16px;
252  height: 16px;
253  font-size: 16px;
254  line-height: 16px;
255  margin-right: 4px;
256  text-align: center;
257  vertical-align: middle;
258  color: inherit;
259}
260
261.apexcharts-tooltip-marker::before {
262  content: "";
263  display: inline-block;
264  width: 100%;
265  text-align: center;
266  color: currentcolor;
267  text-rendering: optimizeLegibility;
268  -webkit-font-smoothing: antialiased;
269  font-size: 26px;
270  font-family: Arial, Helvetica, sans-serif;
271  line-height: 14px;
272  font-weight: 900;
273}
274
275.apexcharts-tooltip-marker[shape="circle"]::before {
276  content: "\\25CF";
277}
278
279.apexcharts-tooltip-marker[shape="square"]::before,
280.apexcharts-tooltip-marker[shape="rect"]::before {
281  content: "\\25A0";
282  transform: translate(-1px, -2px);
283}
284
285.apexcharts-tooltip-marker[shape="line"]::before {
286  content: "\\2500";
287}
288
289.apexcharts-tooltip-marker[shape="diamond"]::before {
290  content: "\\25C6";
291  font-size: 28px;
292}
293
294.apexcharts-tooltip-marker[shape="triangle"]::before {
295  content: "\\25B2";
296  font-size: 22px;
297}
298
299.apexcharts-tooltip-marker[shape="cross"]::before {
300  content: "\\2715";
301  font-size: 18px;
302}
303
304.apexcharts-tooltip-marker[shape="plus"]::before {
305  content: "\\2715";
306  transform: rotate(45deg) translate(-1px, -1px);
307  font-size: 18px;
308}
309
310.apexcharts-tooltip-marker[shape="star"]::before {
311  content: "\\2605";
312  font-size: 18px;
313}
314
315.apexcharts-tooltip-marker[shape="sparkle"]::before {
316  content: "\\2726";
317  font-size: 20px;
318}
319
320.apexcharts-tooltip-series-group {
321  padding: 0 10px;
322  display: none;
323  text-align: left;
324  justify-content: left;
325  align-items: center
326}
327
328.apexcharts-tooltip-series-group.apexcharts-active .apexcharts-tooltip-marker {
329  opacity: 1
330}
331
332.apexcharts-tooltip-series-group.apexcharts-active,
333.apexcharts-tooltip-series-group:last-child {
334  padding-bottom: 4px
335}
336
337.apexcharts-tooltip-y-group {
338  padding: 6px 0 5px
339}
340
341.apexcharts-custom-tooltip,
342.apexcharts-tooltip-box {
343  padding: 4px 8px
344}
345
346.apexcharts-tooltip-boxPlot {
347  display: flex;
348  flex-direction: column-reverse
349}
350
351.apexcharts-tooltip-box>div {
352  margin: 4px 0
353}
354
355.apexcharts-tooltip-box span.value {
356  font-weight: 700
357}
358
359.apexcharts-tooltip-rangebar {
360  padding: 5px 8px
361}
362
363.apexcharts-tooltip-rangebar .category {
364  font-weight: 600;
365  color: #777
366}
367
368.apexcharts-tooltip-rangebar .series-name {
369  font-weight: 700;
370  display: block;
371  margin-bottom: 5px
372}
373
374.apexcharts-xaxistooltip,
375.apexcharts-yaxistooltip {
376  opacity: 0;
377  pointer-events: none;
378  color: #373d3f;
379  font-size: 13px;
380  text-align: center;
381  border-radius: 2px;
382  position: absolute;
383  z-index: 10;
384  background: #eceff1;
385  border: 1px solid #90a4ae
386}
387
388.apexcharts-xaxistooltip {
389  padding: 9px 10px;
390  transition: .15s ease all
391}
392
393.apexcharts-xaxistooltip.apexcharts-theme-dark {
394  background: rgba(0, 0, 0, .7);
395  border: 1px solid rgba(0, 0, 0, .5);
396  color: #fff
397}
398
399.apexcharts-xaxistooltip:after,
400.apexcharts-xaxistooltip:before {
401  left: 50%;
402  border: solid transparent;
403  content: " ";
404  height: 0;
405  width: 0;
406  position: absolute;
407  pointer-events: none
408}
409
410.apexcharts-xaxistooltip:after {
411  border-color: transparent;
412  border-width: 6px;
413  margin-left: -6px
414}
415
416.apexcharts-xaxistooltip:before {
417  border-color: transparent;
418  border-width: 7px;
419  margin-left: -7px
420}
421
422.apexcharts-xaxistooltip-bottom:after,
423.apexcharts-xaxistooltip-bottom:before {
424  bottom: 100%
425}
426
427.apexcharts-xaxistooltip-top:after,
428.apexcharts-xaxistooltip-top:before {
429  top: 100%
430}
431
432.apexcharts-xaxistooltip-bottom:after {
433  border-bottom-color: #eceff1
434}
435
436.apexcharts-xaxistooltip-bottom:before {
437  border-bottom-color: #90a4ae
438}
439
440.apexcharts-xaxistooltip-bottom.apexcharts-theme-dark:after,
441.apexcharts-xaxistooltip-bottom.apexcharts-theme-dark:before {
442  border-bottom-color: rgba(0, 0, 0, .5)
443}
444
445.apexcharts-xaxistooltip-top:after {
446  border-top-color: #eceff1
447}
448
449.apexcharts-xaxistooltip-top:before {
450  border-top-color: #90a4ae
451}
452
453.apexcharts-xaxistooltip-top.apexcharts-theme-dark:after,
454.apexcharts-xaxistooltip-top.apexcharts-theme-dark:before {
455  border-top-color: rgba(0, 0, 0, .5)
456}
457
458.apexcharts-xaxistooltip.apexcharts-active {
459  opacity: 1;
460  transition: .15s ease all
461}
462
463.apexcharts-yaxistooltip {
464  padding: 4px 10px
465}
466
467.apexcharts-yaxistooltip.apexcharts-theme-dark {
468  background: rgba(0, 0, 0, .7);
469  border: 1px solid rgba(0, 0, 0, .5);
470  color: #fff
471}
472
473.apexcharts-yaxistooltip:after,
474.apexcharts-yaxistooltip:before {
475  top: 50%;
476  border: solid transparent;
477  content: " ";
478  height: 0;
479  width: 0;
480  position: absolute;
481  pointer-events: none
482}
483
484.apexcharts-yaxistooltip:after {
485  border-color: transparent;
486  border-width: 6px;
487  margin-top: -6px
488}
489
490.apexcharts-yaxistooltip:before {
491  border-color: transparent;
492  border-width: 7px;
493  margin-top: -7px
494}
495
496.apexcharts-yaxistooltip-left:after,
497.apexcharts-yaxistooltip-left:before {
498  left: 100%
499}
500
501.apexcharts-yaxistooltip-right:after,
502.apexcharts-yaxistooltip-right:before {
503  right: 100%
504}
504
505
506.apexcharts-yaxistooltip-left:after {
507  border-left-color: #eceff1
508}
509
510.apexcharts-yaxistooltip-left:before {
511  border-left-color: #90a4ae
512}
513
514.apexcharts-yaxistooltip-left.apexcharts-theme-dark:after,
515.apexcharts-yaxistooltip-left.apexcharts-theme-dark:before {
516  border-left-color: rgba(0, 0, 0, .5)
517}
518
519.apexcharts-yaxistooltip-right:after {
520  border-right-color: #eceff1
521}
522
523.apexcharts-yaxistooltip-right:before {
524  border-right-color: #90a4ae
525}
526
527.apexcharts-yaxistooltip-right.apexcharts-theme-dark:after,
528.apexcharts-yaxistooltip-right.apexcharts-theme-dark:before {
529  border-right-color: rgba(0, 0, 0, .5)
530}
531
532.apexcharts-yaxistooltip.apexcharts-active {
533  opacity: 1
534}
535
536.apexcharts-yaxistooltip-hidden {
537  display: none
538}
539
540.apexcharts-xcrosshairs,
541.apexcharts-ycrosshairs {
542  pointer-events: none;
543  opacity: 0;
544  transition: .15s ease all
545}
546
547.apexcharts-xcrosshairs.apexcharts-active,
548.apexcharts-ycrosshairs.apexcharts-active {
549  opacity: 1;
550  transition: .15s ease all
551}
552
553.apexcharts-ycrosshairs-hidden {
554  opacity: 0
555}
556
557.apexcharts-selection-rect {
558  cursor: move
559}
560
561.svg_select_shape {
562  stroke-width: 1;
563  stroke-dasharray: 10 10;
564  stroke: black;
565  stroke-opacity: 0.1;
566  pointer-events: none;
567  fill: none;
568}
569
570.svg_select_handle {
571  stroke-width: 3;
572  stroke: black;
573  fill: none;
574}
575
576.svg_select_handle_r {
577  cursor: e-resize;
578}
579
580.svg_select_handle_l {
581  cursor: w-resize;
582}
583
584.apexcharts-svg.apexcharts-zoomable.hovering-zoom {
585  cursor: crosshair
586}
587
588.apexcharts-svg.apexcharts-zoomable.hovering-pan {
589  cursor: move
590}
591
592.apexcharts-menu-icon,
593.apexcharts-pan-icon,
594.apexcharts-reset-icon,
595.apexcharts-selection-icon,
596.apexcharts-toolbar-custom-icon,
597.apexcharts-zoom-icon,
598.apexcharts-zoomin-icon,
599.apexcharts-zoomout-icon {
600  cursor: pointer;
601  /* WCAG 2.5.8 Target Size (Minimum): 24\xd724 CSS px hit target. */
602  width: 24px;
603  height: 24px;
604  line-height: 24px;
605  color: #6e8192;
606  text-align: center;
607  /* Reset native <button> chrome — these are styled via SVG icons. */
608  padding: 0;
609  margin: 0;
610  background: transparent;
611  border: 0;
612  display: inline-flex;
613  align-items: center;
614  justify-content: center;
615}
616
617.apexcharts-menu-icon svg,
618.apexcharts-reset-icon svg,
619.apexcharts-zoom-icon svg,
620.apexcharts-zoomin-icon svg,
621.apexcharts-zoomout-icon svg {
622  fill: #6e8192
623}
624
625.apexcharts-selection-icon svg {
626  fill: #444;
627  transform: scale(.76)
628}
629
630.apexcharts-theme-dark .apexcharts-menu-icon svg,
631.apexcharts-theme-dark .apexcharts-pan-icon svg,
632.apexcharts-theme-dark .apexcharts-reset-icon svg,
633.apexcharts-theme-dark .apexcharts-selection-icon svg,
634.apexcharts-theme-dark .apexcharts-toolbar-custom-icon svg,
635.apexcharts-theme-dark .apexcharts-zoom-icon svg,
636.apexcharts-theme-dark .apexcharts-zoomin-icon svg,
637.apexcharts-theme-dark .apexcharts-zoomout-icon svg {
638  fill: #f3f4f5
639}
640
641.apexcharts-canvas .apexcharts-reset-zoom-icon.apexcharts-selected svg,
642.apexcharts-canvas .apexcharts-selection-icon.apexcharts-selected svg,
643.apexcharts-canvas .apexcharts-zoom-icon.apexcharts-selected svg {
644  fill: #008ffb
645}
646
647.apexcharts-theme-light .apexcharts-menu-icon:hover svg,
648.apexcharts-theme-light .apexcharts-reset-icon:hover svg,
649.apexcharts-theme-light .apexcharts-selection-icon:not(.apexcharts-selected):hover svg,
650.apexcharts-theme-light .apexcharts-zoom-icon:not(.apexcharts-selected):hover svg,
651.apexcharts-theme-light .apexcharts-zoomin-icon:hover svg,
652.apexcharts-theme-light .apexcharts-zoomout-icon:hover svg {
653  fill: #333
654}
655
656.apexcharts-menu-icon,
657.apexcharts-selection-icon {
658  position: relative
659}
660
661.apexcharts-reset-icon {
662  margin-left: 5px
663}
664
665.apexcharts-menu-icon,
666.apexcharts-reset-icon,
667.apexcharts-zoom-icon {
668  transform: scale(.85)
669}
670
671.apexcharts-zoomin-icon,
672.apexcharts-zoomout-icon {
673  transform: scale(.7)
674}
675
676.apexcharts-zoomout-icon {
677  margin-right: 3px
678}
679
680.apexcharts-pan-icon {
681  transform: scale(.62);
682  position: relative;
683  left: 1px;
684  top: 0
685}
686
687.apexcharts-pan-icon svg {
688  fill: #fff;
689  stroke: #6e8192;
690  stroke-width: 2
691}
692
693.apexcharts-pan-icon.apexcharts-selected svg {
694  stroke: #008ffb
695}
696
697.apexcharts-pan-icon:not(.apexcharts-selected):hover svg {
698  stroke: #333
699}
700
701.apexcharts-toolbar {
702  position: absolute;
703  z-index: 11;
704  max-width: 176px;
705  text-align: right;
706  border-radius: 3px;
707  padding: 0 6px 2px;
708  display: flex;
709  justify-content: space-between;
710  align-items: center
711}
712
713.apexcharts-menu {
714  background: #fff;
715  position: absolute;
716  top: 100%;
717  border: 1px solid #ddd;
718  border-radius: 3px;
719  padding: 3px;
720  right: 10px;
721  opacity: 0;
722  min-width: 110px;
723  transition: .15s ease all;
724  pointer-events: none
725}
726
727.apexcharts-menu.apexcharts-menu-open {
728  opacity: 1;
729  pointer-events: all;
730  transition: .15s ease all
731}
732
733.apexcharts-menu-item {
734  padding: 6px 7px;
735  font-size: 12px;
736  cursor: pointer
737}
738
739.apexcharts-theme-light .apexcharts-menu-item:hover {
740  background: #eee
741}
742
743.apexcharts-theme-dark .apexcharts-menu {
744  background: rgba(0, 0, 0, .7);
745  color: #fff
746}
747
748@media screen and (min-width:768px) {
749  .apexcharts-canvas:hover .apexcharts-toolbar {
750    opacity: 1
751  }
752}
753
754/* Toolbar keyboard accessibility: show toolbar when any button inside it is focused */
755.apexcharts-toolbar:focus-within {
756  opacity: 1
757}
758
759/* Focus indicator for toolbar icon buttons */
760.apexcharts-menu-icon:focus-visible,
761.apexcharts-pan-icon:focus-visible,
762.apexcharts-reset-icon:focus-visible,
763.apexcharts-selection-icon:focus-visible,
764.apexcharts-toolbar-custom-icon:focus-visible,
765.apexcharts-zoom-icon:focus-visible,
766.apexcharts-zoomin-icon:focus-visible,
767.apexcharts-zoomout-icon:focus-visible {
768  outline: 2px solid var(--apexcharts-focus-color, #008FFB);
769  outline-offset: 2px;
770  border-radius: 2px
771}
772
773/* Focus indicator for hamburger menu items */
774.apexcharts-menu-item:focus-visible {
775  outline: 2px solid var(--apexcharts-focus-color, #008FFB);
776  outline-offset: -2px;
777  background: #eee
778}
779
780.apexcharts-canvas .apexcharts-element-hidden,
781.apexcharts-datalabel.apexcharts-element-hidden,
782.apexcharts-hide .apexcharts-series-points {
783  opacity: 0;
784}
785
786.apexcharts-hidden-element-shown {
787  opacity: 1;
788  transition: 0.25s ease all;
789}
790
791.apexcharts-datalabel,
792.apexcharts-datalabel-label,
793.apexcharts-datalabel-value,
794.apexcharts-datalabels,
795.apexcharts-pie-label {
796  cursor: default;
797  pointer-events: none
798}
799
800.apexcharts-pie-label-delay {
801  opacity: 0;
802  animation-name: opaque;
803  animation-duration: .3s;
804  animation-fill-mode: forwards;
805  animation-timing-function: ease
806}
807
808.apexcharts-radialbar-label {
809  cursor: pointer;
810}
811
812.apexcharts-annotation-rect,
813.apexcharts-area-series .apexcharts-area,
814.apexcharts-gridline,
815.apexcharts-line,
816.apexcharts-point-annotation-label,
817.apexcharts-radar-series path:not(.apexcharts-marker),
818.apexcharts-radar-series polygon,
819.apexcharts-toolbar svg,
820.apexcharts-tooltip .apexcharts-marker,
821.apexcharts-xaxis-annotation-label,
822.apexcharts-yaxis-annotation-label,
823.apexcharts-zoom-rect,
824.no-pointer-events {
825  pointer-events: none
826}
827
828.apexcharts-tooltip-active .apexcharts-marker {
829  transition: .15s ease all
830}
831
832.apexcharts-radar-series .apexcharts-yaxis {
833  pointer-events: none;
834}
835
836.resize-triggers {
837  animation: 1ms resizeanim;
838  visibility: hidden;
839  opacity: 0;
840  height: 100%;
841  width: 100%;
842  overflow: hidden
843}
844
845.contract-trigger:before,
846.resize-triggers,
847.resize-triggers>div {
848  content: " ";
849  display: block;
850  position: absolute;
851  top: 0;
852  left: 0
853}
854
855.resize-triggers>div {
856  height: 100%;
857  width: 100%;
858  background: #eee;
859  overflow: auto
860}
861
862.contract-trigger:before {
863  overflow: hidden;
864  width: 200%;
865  height: 200%
866}
867
868.apexcharts-bar-goals-markers {
869  pointer-events: none
870}
871
872.apexcharts-bar-shadows {
873  pointer-events: none
874}
875
876.apexcharts-rangebar-goals-markers {
877  pointer-events: none
878}
879
880.apexcharts-disable-transitions * {
881  transition: none !important;
882}`;class eJ{constructor(e,t){g(this,"core"),g(this,"responsive"),g(this,"axes"),g(this,"grid"),g(this,"graphics"),g(this,"coreUtils"),g(this,"crosshairs"),g(this,"events"),g(this,"fill"),g(this,"localization"),g(this,"options"),g(this,"series"),g(this,"theme"),g(this,"formatters"),g(this,"titleSubtitle"),g(this,"dimensions"),g(this,"updateHelpers"),g(this,"tooltip"),g(this,"data"),g(this,"animations"),g(this,"exports"),g(this,"legend"),g(this,"toolbar"),g(this,"zoomPanSelection"),g(this,"keyboardNavigation"),g(this,"annotations"),g(this,"timeScale"),g(this,"_keyboardNavigation"),g(this,"windowResizeHandler"),g(this,"parentResizeHandler"),g(this,"publicMethods",[]),g(this,"eventList",[]),g(this,"config"),this.opts=t,this.ctx=this,this.w=new X(t).init(),this.el=e,this.w.globals.cuid=v.randomId(),this.w.globals.chartID=this.w.config.chart.id?v.escapeString(this.w.config.chart.id):this.w.globals.cuid,new eU(this).initModules(),this.lastUpdateOptions=null,this.create=this.create.bind(this),p.isBrowser()&&(this.windowResizeHandler=this._windowResizeHandler.bind(this),this.parentResizeHandler=this._parentResizeCallback.bind(this))}render(){var e,t;return(null==(t=null==(e=this.w)?void 0:e.config)?void 0:t.chart)?new Promise((e,t)=>{var i;if(v.elementExists(this.el)){void 0===Apex._chartInstances&&(Apex._chartInstances=[]),this.w.config.chart.id&&Apex._chartInstances.push({id:this.w.globals.chartID,group:this.w.config.chart.group,chart:this}),this.setLocale(this.w.config.chart.defaultLocale);let s=this.w.config.chart.events.beforeMount;if("function"==typeof s&&s(this,this.w),this.events.fireEvent("beforeMount",[this,this.w]),p.isBrowser()){window.addEventListener("resize",this.windowResizeHandler),function(e,t){if(p.isSSR())return;let i=!1;if(e.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){let t=e.getBoundingClientRect();("none"===e.style.display||0===t.width)&&(i=!0)}let s=new ResizeObserver(s=>{i&&t.call(e,s),i=!0});e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?Array.from(e.children).forEach(e=>s.observe(e)):s.observe(e),eq.set(t,s)}(this.el.parentNode,this.parentResizeHandler);let e=this.el.getRootNode&&this.el.getRootNode(),t=v.is("ShadowRoot",e),s=this.el.ownerDocument,a=t?e.getElementById("apexcharts-css"):s.getElementById("apexcharts-css");if(!a){(a=w.createElementNS("http://www.w3.org/1999/xhtml","style")).id="apexcharts-css",a.textContent=eK;let r=(null==(i=this.opts.chart)?void 0:i.nonce)||this.w.config.chart.nonce;r&&a.setAttribute("nonce",r),t?e.prepend(a):!1!==this.w.config.chart.injectStyleSheet&&s.head.appendChild(a)}}let a=this.create(this.w.config.series,{});if(!a)return e(this);this.mount(a).then(()=>{"function"==typeof this.w.config.chart.events.mounted&&this.w.config.chart.events.mounted(this,this.w),this.events.fireEvent("mounted",[this,this.w]),e(a)}).catch(e=>{var i,s;let a=e instanceof Error?e:Error(String(e));a.chartId=null==(s=null==(i=this.w)?void 0:i.globals)?void 0:s.chartID,a.el=this.el,t(a)})}else t(Error("Element not found"))}):Promise.reject(Error("ApexCharts: chart configuration is missing or invalid. Ensure the options object includes a `chart` property."))}create(e,t){var i;let s=this.w;this.core||new eU(this).initModules();let a=this.w.globals;if(a.noData=!1,a.animationEnded=!1,!v.elementExists(this.el)||(this.responsive.checkResponsiveConfig(t),s.config.xaxis.convertedCatToNumeric&&new D(s.config).convertCatToNumericXaxis(s.config,this.ctx),this.core.setupElements(),"treemap"===s.config.chart.type&&(s.config.grid.show=!1,s.config.yaxis[0].show=!1),0===a.svgWidth))return a.animationEnded=!0,null;let r=e;e.forEach((e,t)=>{e.hidden&&(r=this.legend.legendHelpers.getSeriesAfterCollapsing({realIndex:t}))});let l=I.checkComboSeries(r,s.config.chart.type);a.comboCharts=l.comboCharts,a.comboBarCount=l.comboBarCount;let o=r.every(e=>e.data&&0===e.data.length);(0===r.length||o&&a.collapsedSeries.length<1)&&this.series.handleNoData(),p.isBrowser()&&this.events.setupEventHandlers();let n=this.data.parseData(r);
882this._writeParsedSeriesData(n.seriesData),this._writeParsedRangeData(n.rangeData),this._writeParsedCandleData(n.candleData),this._writeParsedLabelData(n.labelData),this._writeParsedAxisFlags(n.axisFlags),this.theme.init(),new _(this.w,this).setGlobalMarkerSize(),this.formatters.setLabelFormatters(),this.titleSubtitle.draw(),(!a.noData||a.collapsedSeries.length===s.seriesData.series.length||s.config.legend.showForSingleSeries)&&(null==(i=this.legend)||i.init()),this.series.hasAllSeriesEqualX(),a.axisCharts&&(this.core.coreCalculations(),"category"!==s.config.xaxis.type&&this.formatters.setLabelFormatters(),this.ctx.toolbar&&(this.ctx.toolbar.minX=s.globals.minX,this.ctx.toolbar.maxX=s.globals.maxX)),this.formatters.heatmapLabelFormatters(),new I(this.w).getLargestMarkerSize();let h=this.dimensions.plotCoords();this._writeLayoutCoords(h.layout);let d=this.core.xySettings();this.grid.createGridMask();let c=this.core.plotChartType(r,d),g=new G(this.w,this);return g.bringForward(),s.config.dataLabels.background.enabled&&g.dataLabelsBackground(),this.core.shiftGraphPosition(),s.globals.dataPoints>50&&s.dom.elWrap.classList.add("apexcharts-disable-transitions"),{elGraph:c,xyRatios:d,dimensions:{plot:{left:s.layout.translateX,top:s.layout.translateY,width:s.layout.gridWidth,height:s.layout.gridHeight}}}}mount(e=null){let t=this,i=t.w;return new Promise((s,a)=>{var r,l,o,n,h,d,c,g,x;if(null===t.el)return a(Error("Not enough data to display or target element not found"));(null===e||i.globals.allSeriesCollapsed)&&t.series.handleNoData(),t.grid=new Z(t.w,t);let u=t.grid.drawGrid(),f=eU._featureRegistry.get("annotations");if(t.annotations=f?new f(t.w,{theme:t.theme,timeScale:t.timeScale}):null,null==(r=t.annotations)||r.drawImageAnnos(),null==(l=t.annotations)||l.drawTextAnnos(),"back"===i.config.grid.position&&(u&&i.dom.elGraphical.add(u.el),(null==(o=null==u?void 0:u.elGridBorders)?void 0:o.node)&&i.dom.elGraphical.add(u.elGridBorders)),Array.isArray(e.elGraph))for(let t=0;t<e.elGraph.length;t++)i.dom.elGraphical.add(e.elGraph[t]);else i.dom.elGraphical.add(e.elGraph);"front"===i.config.grid.position&&(u&&i.dom.elGraphical.add(u.el),(null==(n=null==u?void 0:u.elGridBorders)?void 0:n.node)&&i.dom.elGraphical.add(u.elGridBorders)),"front"===i.config.xaxis.crosshairs.position&&t.crosshairs.drawXCrosshairs(),"front"===i.config.yaxis[0].crosshairs.position&&t.crosshairs.drawYCrosshairs(),"treemap"!==i.config.chart.type&&t.axes.drawAxis(i.config.chart.type,u);let m=new U(this.w,this.ctx,u),b=new Q(this.w,{theme:this.theme,timeScale:this.timeScale},u);if(null!==u&&(m.xAxisLabelCorrections(),b.setYAxisTextAlignments(),i.config.yaxis.map((e,t)=>{-1===i.globals.ignoreYAxisIndexes.indexOf(t)&&b.yAxisTitleRotate(t,e.opposite)})),null==(h=t.annotations)||h.drawAxesAnnotations(),!i.globals.noData){if(p.isBrowser()&&i.config.tooltip.enabled&&!i.globals.noData&&(null==(d=t.w.globals.tooltip)||d.drawTooltip(e.xyRatios)),i.config.chart.accessibility.enabled&&i.config.chart.accessibility.keyboard.enabled&&i.config.chart.accessibility.keyboard.navigation.enabled&&(null==(c=t.keyboardNavigation)||c.init()),p.isBrowser()&&i.globals.axisCharts&&(i.axisFlags.isXNumeric||i.config.xaxis.convertedCatToNumeric||i.axisFlags.isRangeBar))(i.config.chart.zoom.enabled||i.config.chart.selection&&i.config.chart.selection.enabled||i.config.chart.pan&&i.config.chart.pan.enabled)&&(null==(g=t.zoomPanSelection)||g.init({xyRatios:e.xyRatios}));else{let e=i.config.chart.toolbar.tools;["zoom","zoomin","zoomout","selection","pan","reset"].forEach(t=>{e[t]=!1})}i.config.chart.toolbar.show&&!i.globals.allSeriesCollapsed&&(null==(x=t.toolbar)||x.createToolbar())}i.globals.memory.methodsToExec.length>0&&i.globals.memory.methodsToExec.forEach(e=>{e.method(e.params,!1,e.context)}),i.globals.axisCharts||i.globals.noData||t.core.resizeNonAxisCharts(),s(t)})}destroy(){p.isBrowser()&&(window.removeEventListener("resize",this.windowResizeHandler),function(e,t){if(p.isSSR())return;let i=eq.get(t);i&&(i.disconnect(),eq.delete(t))}(this.el.parentNode,this.parentResizeHandler));let e=this.w.config.chart.id;
882e&&Apex._chartInstances.forEach((t,i)=>{t.id===v.escapeString(e)&&Apex._chartInstances.splice(i,1)}),this._keyboardNavigation&&this._keyboardNavigation.destroy(),new eZ(this.ctx).clear({isUpdating:!1})}updateOptions(e,t=!1,i=!0,s=!0,a=!0){let r=this.w;if(r.interact.selection=void 0,this.lastUpdateOptions){if(v.shallowEqual(this.lastUpdateOptions,e))return Promise.resolve(this);if(e.series&&this.lastUpdateOptions.series&&JSON.stringify(this.lastUpdateOptions.series)===JSON.stringify(e.series)){let t=d({},e),i=d({},this.lastUpdateOptions);if(delete t.series,delete i.series,v.shallowEqual(t,i))return Promise.resolve(this)}}return e.series&&(this.data.resetParsingFlags(),this.series.resetSeries(!1,!0,!1),e.series.length&&e.series[0].data&&(e.series=e.series.map((e,t)=>this.updateHelpers._extendSeries(e,t))),this.updateHelpers.revertDefaultAxisMinMax()),e.xaxis&&(e=this.updateHelpers.forceXAxisUpdate(e)),e.yaxis&&(e=this.updateHelpers.forceYAxisUpdate(e)),r.globals.collapsedSeriesIndices.length>0&&this.series.clearPreviousPaths(),e.theme&&(e=this.theme.updateThemeOptions(e)),this.updateHelpers._updateOptions(e,t,i,s,a)}updateSeries(e=[],t=!0,i=!0){return this.data.resetParsingFlags(),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(e,t,i)}appendSeries(e,t=!0,i=!0){this.data.resetParsingFlags();let s=this.w.config.series.slice();return s.push(e),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(s,t,i)}appendData(e,t=!0){this.data.resetParsingFlags(),this.w.globals.dataChanged=!0,this.series.getPreviousPaths();let i=this.w.config.series.slice();for(let t=0;t<i.length;t++)if(null!==e[t]&&void 0!==e[t]){let s=e[t],a=i[t];for(let e=0;e<s.data.length;e++)a.data.push(s.data[e])}return this.w.config.series=i,t&&(this.w.globals.initialSeries=v.clone(this.w.config.series)),this.update()}update(e){return new Promise((t,i)=>{if(this.lastUpdateOptions&&JSON.stringify(this.lastUpdateOptions)===JSON.stringify(e))return t(this);this.lastUpdateOptions=v.clone(e),new eZ(this.ctx).clear({isUpdating:!0});let s=this.create(this.w.config.series,null!=e?e:{});if(!s)return t(this);this.mount(s).then(()=>{"function"==typeof this.w.config.chart.events.updated&&this.w.config.chart.events.updated(this,this.w),this.events.fireEvent("updated",[this,this.w]),this.w.globals.isDirty=!0,t(this)}).catch(e=>{i(e)})})}fastUpdate(e){return new Promise((t,i)=>{var s;try{let i=this.w,a=i.globals;a.shouldAnimate=e,a.dataChanged=!0,a.animationEnded=!1,V.invalidateSelectors(i);let r=i.globals;r.maxY=-Number.MAX_VALUE,r.minY=5e-324,r.minYArr=[],r.maxYArr=[],r.maxX=-Number.MAX_VALUE,r.minX=Number.MAX_VALUE,r.initialMaxX=-Number.MAX_VALUE,r.initialMinX=Number.MAX_VALUE,r.yAxisScale=[],r.xAxisScale=null,r.xAxisTicksPositions=[],r.xRange=0,r.yRange=[],r.zRange=0,r.xTickAmount=0,r.multiAxisTickAmount=0,r.pointsArray=[],r.dataLabelsRects=[],r.lastDrawnDataLabelsIndexes=[],r.textRectsCache=new Map,r.domCache=new Map,r.cachedSelectors={},r.disableZoomIn=!1,r.disableZoomOut=!1,a.axisCharts&&(this.core.coreCalculations(),"category"!==i.config.xaxis.type&&this.formatters.setLabelFormatters());let l=this.core.xySettings(),o=i.dom.elGraphical.node;o.querySelectorAll(".apexcharts-series, .apexcharts-datalabels, .apexcharts-datalabels-background").forEach(e=>{var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)});let n=this.core.plotChartType(i.config.series,l),h=o.querySelector(".apexcharts-grid"),d=Array.isArray(n)?n:[n];h&&"front"===i.config.grid.position?d.forEach(e=>{let t=e&&e.node?e.node:e;t&&o.insertBefore(t,h)}):d.forEach(e=>{i.dom.elGraphical.add(e)});let c=new G(i,this);c.bringForward(),i.config.dataLabels.background.enabled&&c.dataLabelsBackground(),p.isBrowser()&&i.config.tooltip.enabled&&!a.noData&&(null==(s=i.globals.tooltip)||s.drawTooltip(l)),"function"==typeof i.config.chart.events.updated&&i.config.chart.events.updated(this,i),this.events.fireEvent("updated",[this,i]),a.isDirty=!0,t(this)}catch(e){i(e)}})}getSyncedCharts(){let e=this.getGroupedCharts(),t=[this];
882return e.length&&(t=[],e.forEach(e=>{t.push(e)})),t}getGroupedCharts(){return Apex._chartInstances.filter(e=>{if(e.group)return!0}).map(e=>this.w.config.chart.group===e.group?e.chart:this)}static getChartByID(e){let t=v.escapeString(e);if(!Apex._chartInstances)return;let i=Apex._chartInstances.filter(e=>e.id===t)[0];return i&&i.chart}static initOnLoad(){var e;let t=document.querySelectorAll("[data-apexcharts]");for(let i=0;i<t.length;i++)new eJ(t[i],JSON.parse(null!=(e=t[i].getAttribute("data-options"))?e:"")).render()}static exec(e,t,...i){let s=this.getChartByID(e);if(!s)return;s.w.globals.isExecCalled=!0;let a=null;return -1!==s.publicMethods.indexOf(t)&&(a=s[t](...i)),a}static merge(e,t){return v.extend(e,t)}static getThemePalettes(){return J()}static use(e){Object.assign(eu(),e)}static registerFeatures(e){eU.registerFeatures(e)}toggleSeries(e){return this.series.toggleSeries(e)}highlightSeriesOnLegendHover(e,t){return this.series.toggleSeriesOnHover(e,t)}showSeries(e){this.series.showSeries(e)}hideSeries(e){this.series.hideSeries(e)}highlightSeries(e){this.series.highlightSeries(e)}isSeriesHidden(e){return this.series.isSeriesHidden(e)}resetSeries(e=!0,t=!0){this.series.resetSeries(e,t)}addEventListener(e,t){this.events.addEventListener(e,t)}removeEventListener(e,t){this.events.removeEventListener(e,t)}addXaxisAnnotation(e,t=!0,i){var s;let a=this;i&&(a=i),null==(s=a.annotations)||s.addXaxisAnnotationExternal(e,t,a)}addYaxisAnnotation(e,t=!0,i){var s;let a=this;i&&(a=i),null==(s=a.annotations)||s.addYaxisAnnotationExternal(e,t,a)}addPointAnnotation(e,t=!0,i){var s;let a=this;i&&(a=i),null==(s=a.annotations)||s.addPointAnnotationExternal(e,t,a)}clearAnnotations(e){var t;let i=this;e&&(i=e),null==(t=i.annotations)||t.clearAnnotations(i)}removeAnnotation(e,t){var i;let s=this;t&&(s=t),null==(i=s.annotations)||i.removeAnnotation(s,e)}getChartArea(){return this.w.dom.baseEl.querySelector(".apexcharts-inner")}getSeriesTotalXRange(e,t){return this.coreUtils.getSeriesTotalsXRange(e,t)}getHighestValueInSeries(e=0){return new K(this.w).getMinYMaxY(e).highestY}getLowestValueInSeries(e=0){return new K(this.w).getMinYMaxY(e).lowestY}getSeriesTotal(){return this.w.globals.seriesTotals}getState(){let e=this.w,t=e.globals;return{series:e.seriesData.series,seriesNames:e.seriesData.seriesNames,colors:t.colors,labels:e.labelData.labels,seriesTotals:t.seriesTotals,seriesPercent:t.seriesPercent,seriesXvalues:t.seriesXvalues,seriesYvalues:t.seriesYvalues,minX:t.minX,maxX:t.maxX,minY:t.minY,maxY:t.maxY,minYArr:t.minYArr,maxYArr:t.maxYArr,minXDiff:t.minXDiff,dataPoints:t.dataPoints,xAxisScale:t.xAxisScale,yAxisScale:t.yAxisScale,xTickAmount:t.xTickAmount,isXNumeric:e.axisFlags.isXNumeric,seriesYAxisMap:t.seriesYAxisMap,seriesYAxisReverseMap:t.seriesYAxisReverseMap,svgWidth:t.svgWidth,svgHeight:t.svgHeight,gridWidth:e.layout.gridWidth,gridHeight:e.layout.gridHeight,selectedDataPoints:e.interact.selectedDataPoints,collapsedSeriesIndices:t.collapsedSeriesIndices,zoomed:e.interact.zoomed,seriesX:e.seriesData.seriesX,seriesZ:e.seriesData.seriesZ,seriesCandleO:e.candleData.seriesCandleO,seriesCandleH:e.candleData.seriesCandleH,seriesCandleM:e.candleData.seriesCandleM,seriesCandleL:e.candleData.seriesCandleL,seriesCandleC:e.candleData.seriesCandleC,seriesRangeStart:e.rangeData.seriesRangeStart,seriesRangeEnd:e.rangeData.seriesRangeEnd,seriesGoals:e.seriesData.seriesGoals}}toggleDataPointSelection(e,t){return this.updateHelpers.toggleDataPointSelection(e,t)}zoomX(e,t){var i;null==(i=this.ctx.toolbar)||i.zoomUpdateOptions(e,t)}setLocale(e){this.localization.setCurrentLocaleValues(e)}dataURI(e){if(!this.ctx.exports)throw Error("apexcharts: Exports feature is not registered. Import apexcharts/features/exports.");return this.ctx.exports.dataURI(e)}getSvgString(e){if(!this.ctx.exports)throw Error("apexcharts: Exports feature is not registered. Import apexcharts/features/exports.");return this.ctx.exports.getSvgString(e)}exportToCSV(e={}){if(!this.ctx.exports)throw Error("apexcharts: Exports feature is not registered. Import apexcharts/features/exports.");return this.ctx.exports.exportToCSV(e)}paper(){return this.w.dom.Paper}
882_writeParsedSeriesData(e){Object.assign(this.w.seriesData,e)}_writeParsedRangeData(e){Object.assign(this.w.rangeData,e)}_writeParsedCandleData(e){Object.assign(this.w.candleData,e)}_writeParsedLabelData(e){Object.assign(this.w.labelData,e)}_writeParsedAxisFlags(e){Object.assign(this.w.axisFlags,e)}_writeLayoutCoords(e){Object.assign(this.w.layout,e)}_parentResizeCallback(){this.w.globals.animationEnded&&this.w.config.chart.redrawOnParentResize&&this._windowResize()}_windowResize(){this.w.globals.resizeTimer=window.setTimeout(()=>{this.w.globals.resized=!0,this.w.globals.dataChanged=!1,this.ctx.update()},150)}_windowResizeHandler(){var e;clearTimeout(null!=(e=this.w.globals.resizeTimer)?e:void 0);let{redrawOnWindowResize:t}=this.w.config.chart;"function"==typeof t&&(t=t()),t&&this._windowResize()}}let eQ=".apexcharts-flip-y {\n  transform: scaleY(-1) translateY(-100%);\n  transform-origin: top;\n  transform-box: fill-box;\n}\n.apexcharts-flip-x {\n  transform: scaleX(-1);\n  transform-origin: center;\n  transform-box: fill-box;\n}\n.apexcharts-legend {\n  display: flex;\n  overflow: auto;\n  padding: 0 10px;\n}\n.apexcharts-legend.apexcharts-legend-group-horizontal {\n  flex-direction: column;\n}\n.apexcharts-legend-group {\n  display: flex;\n}\n.apexcharts-legend-group-vertical {\n  flex-direction: column-reverse;\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  align-items: 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  align-items: 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  align-items: 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} ";class e0{constructor(e,t){this.w=e,this.ctx=t}svgStringToNode(e){return new DOMParser().parseFromString(e,"image/svg+xml").documentElement}scaleSvgNode(e,t){let i=parseFloat(e.getAttributeNS(null,"width")),s=parseFloat(e.getAttributeNS(null,"height"));e.setAttributeNS(null,"width",i*t),e.setAttributeNS(null,"height",s*t),e.setAttributeNS(null,"viewBox","0 0 "+i+" "+s)}getSvgString(e){return new Promise(t=>{let i=this.w,s=e||i.config.chart.toolbar.export.scale||i.config.chart.toolbar.export.width/i.globals.svgWidth;s||(s=1);let a=i.globals.svgWidth*s,r=i.globals.svgHeight*s,l=i.dom.elWrap.cloneNode(!0);l.style.width=a+"px",l.style.height=r+"px";let o=new XMLSerializer().serializeToString(l),n=i.config.legend.show&&i.dom.elLegendWrap&&i.dom.elLegendWrap.children.length>0,h=`
883        .apexcharts-tooltip, .apexcharts-toolbar, .apexcharts-xaxistooltip, .apexcharts-yaxistooltip, .apexcharts-xcrosshairs, .apexcharts-ycrosshairs, .apexcharts-zoom-rect, .apexcharts-selection-rect {
884          display: none;
885        }
886      `;n&&(h+=eQ);let d=`
887        <svg xmlns="http://www.w3.org/2000/svg"
888          version="1.1"
889          xmlns:xlink="http://www.w3.org/1999/xlink"
890          class="apexcharts-svg"
891          xmlns:data="ApexChartsNS"
892          transform="translate(0, 0)"
893          width="${i.globals.svgWidth}px" height="${i.globals.svgHeight}px">
894          <foreignObject width="100%" height="100%">
895            <div xmlns="http://www.w3.org/1999/xhtml" style="width:${a}px; height:${r}px;">
896            <style type="text/css">
897              ${h}
898            </style>
899              ${o}
900            </div>
901          </foreignObject>
902        </svg>
903      `,c=this.svgStringToNode(d);1!==s&&this.scaleSvgNode(c,s),this.convertImagesToBase64(c).then(()=>{t((d=new XMLSerializer().serializeToString(c)).replace(/&nbsp;/g,"&#160;"))})})}convertImagesToBase64(e){return Promise.all(Array.from(e.getElementsByTagName("image")).map(e=>{let t=e.getAttributeNS("http://www.w3.org/1999/xlink","href");return t&&!t.startsWith("data:")?this.getBase64FromUrl(t).then(t=>{e.setAttributeNS("http://www.w3.org/1999/xlink","href",t)}).catch(e=>{console.error("Error converting image to base64:",e)}):Promise.resolve()}))}getBase64FromUrl(e){return p.isSSR()?Promise.resolve(e):new Promise((t,i)=>{let s=new Image;s.crossOrigin="Anonymous",s.onload=()=>{let e=document.createElement("canvas");e.width=s.width,e.height=s.height;let i=e.getContext("2d");i&&i.drawImage(s,0,0),t(e.toDataURL())},s.onerror=i,s.src=e})}svgUrl(){return new Promise(e=>
903{this.getSvgString().then(t=>{let i=new Blob([t],{type:"image/svg+xml;charset=utf-8"});e(URL.createObjectURL(i))})})}dataURI(e){return p.isSSR()?Promise.resolve({imgURI:""}):new Promise(t=>{let i=this.w,s=e?e.scale||e.width/i.globals.svgWidth:1,a=document.createElement("canvas");a.width=i.globals.svgWidth*s,a.height=parseInt(i.dom.elWrap.style.height,10)*s;let r="transparent"!==i.config.chart.background&&i.config.chart.background?i.config.chart.background:"#fff",l=a.getContext("2d");l&&(l.fillStyle=r,l.fillRect(0,0,a.width*s,a.height*s),this.getSvgString(s).then(e=>{let i="data:image/svg+xml,"+encodeURIComponent(e),s=new Image;s.crossOrigin="anonymous",s.onload=()=>{l.drawImage(s,0,0),a.msToBlob?t({blob:a.msToBlob()}):t({imgURI:a.toDataURL("image/png")})},s.src=i}))})}exportToSVG(){this.svgUrl().then(e=>{this.triggerDownload(e,this.w.config.chart.toolbar.export.svg.filename,".svg")})}exportToPng(){let e=this.w.config.chart.toolbar.export.scale,t=this.w.config.chart.toolbar.export.width;this.dataURI(e?{scale:e}:t?{width:t}:void 0).then(({imgURI:e,blob:t})=>{t?navigator.msSaveOrOpenBlob(t,this.w.globals.chartID+".png"):this.triggerDownload(e,this.w.config.chart.toolbar.export.png.filename,".png")})}exportToCSV({series:e,fileName:t,columnDelimiter:i=",",lineDelimiter:s="\n"}){let a=this.w;e||(e=a.config.series);let r=[],l=[],o="",n=a.seriesData.series.map((e,t)=>-1===a.globals.collapsedSeriesIndices.indexOf(t)?e:[]),h=e=>"function"==typeof a.config.chart.toolbar.export.csv.categoryFormatter?a.config.chart.toolbar.export.csv.categoryFormatter(e):"datetime"===a.config.xaxis.type&&String(e).length>=10?new Date(e).toDateString():v.isNumber(e)?e:e.split(i).join(""),d=e=>"function"==typeof a.config.chart.toolbar.export.csv.valueFormatter?a.config.chart.toolbar.export.csv.valueFormatter(e):e,c=Math.max(...e.map(e=>e.data?e.data.length:0)),g=new eb(this.w),p=new j(this.w,{theme:this.ctx.theme,timeScale:this.ctx.timeScale}),x=e=>{let t="";if(a.globals.axisCharts){if("category"===a.config.xaxis.type||a.config.xaxis.convertedCatToNumeric)if(a.globals.isBarHorizontal){let i=a.formatters.yLabelFormatters[0],s=new er(this.ctx.w).getActiveConfigSeriesIndex();t=i(a.labelData.labels[e],{seriesIndex:s,dataPointIndex:e,w:a})}else t=p.getLabel(a.labelData.labels,a.labelData.timescaleLabels,0,e).text;"datetime"===a.config.xaxis.type&&(a.config.xaxis.categories.length?t=a.config.xaxis.categories[e]:a.config.labels.length&&(t=a.config.labels[e]))}else t=a.config.labels[e];return null===t?"nullvalue":(Array.isArray(t)&&(t=t.join(" ")),v.isNumber(t)?t:t.split(i).join(""))};if(r.push(a.config.chart.toolbar.export.csv.headerCategory),"boxPlot"===a.config.chart.type?(r.push("minimum"),r.push("q1"),r.push("median"),r.push("q3"),r.push("maximum")):"candlestick"===a.config.chart.type?(r.push("open"),r.push("high"),r.push("low"),r.push("close")):"rangeBar"===a.config.chart.type?(r.push("minimum"),r.push("maximum")):e.map((e,t)=>{let s=(e.name?e.name:`series-${t}`)+"";a.globals.axisCharts&&r.push(s.split(i).join("")?s.split(i).join(""):`series-${t}`)}),a.globals.axisCharts||(r.push(a.config.chart.toolbar.export.csv.headerValue),l.push(r.join(i))),a.globals.allSeriesHasEqualX||!a.globals.axisCharts||a.config.xaxis.categories.length||a.config.labels.length)e.map((t,s)=>{a.globals.axisCharts?((t,s)=>{var o;if(r.length&&0===s&&l.push(r.join(i)),t.data){t.data=t.data.length&&t.data||[...Array(c)].map(()=>"");for(let c=0;c<t.data.length;c++){r=[];let p=x(c);if("nullvalue"!==p){if(!p&&(g.isFormatXY()?p=e[s].data[c].x:g.isFormat2DArray()&&(p=e[s].data[c]?e[s].data[c][0]:"")),0===s){r.push(h(p));for(let t=0;t<a.seriesData.series.length;t++){let i=g.isFormatXY()?null==(o=e[t].data[c])?void 0:o.y:n[t][c];r.push(d(i))}}("candlestick"===a.config.chart.type||t.type&&"candlestick"===t.type)&&(r.pop(),r.push(a.candleData.seriesCandleO[s][c]),r.push(a.candleData.seriesCandleH[s][c]),r.push(a.candleData.seriesCandleL[s][c]),r.push(a.candleData.seriesCandleC[s][c])),("boxPlot"===a.config.chart.type||t.type&&"boxPlot"===t.type)&&(r.pop(),r.push(a.candleData.seriesCandleO[s][c]),r.push(a.candleData.seriesCandleH[s][c]),r.push(a.candleData.seriesCandleM[s][c]),r.push(a.candleData.seriesCandleL[s][c]),r.push(a.candleData.seriesCandleC[s][c])),"rangeBar"===a.config.chart.type&&(r.pop(),r.push(a.rangeData.seriesRangeStart[s][c]),r.push(a.rangeData.seriesRangeEnd[s][c])),r.length&&l.push(r.join(i))}}}})(t,s):((r=[]).push(h(a.labelData.labels[s])),r.push(d(n[s])),l.push(r.join(i)))});else{let t,s;t=new Set,s={},e.forEach((i,a)=>{null==i||i.data.forEach(i=>
903{let r,l;if(g.isFormatXY())r=i.x,l=i.y;else{if(!g.isFormat2DArray())return;r=i[0],l=i[1]}s[r]||(s[r]=Array(e.length).fill("")),s[r][a]=d(l),t.add(r)})}),r.length&&l.push(r.join(i)),Array.from(t).sort().forEach(e=>{l.push([h(e),s[e].join(i)])})}o+=l.join(s),this.triggerDownload("data:text/csv; charset=utf-8,"+encodeURIComponent("\uFEFF"+o),t||a.config.chart.toolbar.export.csv.filename,".csv")}triggerDownload(e,t,i){if(p.isSSR())return;let s=document.createElement("a");s.href=e,s.download=(t||this.w.globals.chartID)+i,document.body.appendChild(s),s.click(),document.body.removeChild(s)}}eJ.registerFeatures({exports:e0});let e1=class{constructor(e){this.w=e.w,this.lgCtx=e}getLegendStyles(){if(p.isSSR())return null;let e=document.createElement("style");e.setAttribute("type","text/css");let t=this.w.config.chart.nonce;t&&e.setAttribute("nonce",t);let i=document.createTextNode(eQ);return e.appendChild(i),e}getLegendDimensions(){let e=this.w.dom.baseEl.querySelector(".apexcharts-legend");if(!e)return{clwh:0,clww:0};let{width:t,height:i}=e.getBoundingClientRect();return{clwh:i,clww:t}}appendToForeignObject(){var e;let t=this.getLegendStyles();!1!==this.w.config.chart.injectStyleSheet&&t&&(null==(e=this.w.dom.elLegendForeign)||e.appendChild(t))}toggleDataSeries(e,t){var i,s;let a=this.w;if(a.globals.axisCharts||"radialBar"===a.config.chart.type){a.globals.resized=!0;let r=null,l=null;if(a.globals.risingSeries=[],a.globals.axisCharts){if(!(r=a.dom.baseEl.querySelector(`.apexcharts-series[data\\:realIndex='${e}']`)))return;l=parseInt(null!=(i=r.getAttribute("data:realIndex"))?i:"",10)}else{if(!(r=a.dom.baseEl.querySelector(`.apexcharts-series[rel='${e+1}']`)))return;l=parseInt(null!=(s=r.getAttribute("rel"))?s:"",10)-1}if(t?[{cs:a.globals.collapsedSeries,csi:a.globals.collapsedSeriesIndices},{cs:a.globals.ancillaryCollapsedSeries,csi:a.globals.ancillaryCollapsedSeriesIndices}].forEach(e=>{let t=e.cs,i=e.csi;this.riseCollapsedSeries(t,i,l)}):this.hideSeries({seriesEl:r,realIndex:l}),a.config.chart.accessibility.enabled){let t=a.dom.baseEl.querySelector(`.apexcharts-legend-series[rel="${e+1}"]`);if(t){let i=a.globals.collapsedSeriesIndices.includes(l)||a.globals.ancillaryCollapsedSeriesIndices.includes(l);t.setAttribute("aria-pressed",i?"true":"false");let s=t.querySelector(".apexcharts-legend-text"),r=s?s.textContent:a.seriesData.seriesNames[e];t.setAttribute("aria-label",`${r}, ${i?"hidden":"visible"}. Press Enter or Space to toggle.`)}}}else{let t=a.dom.Paper.findOne(` .apexcharts-series[rel='${e+1}'] path`),i=a.config.chart.type;if("pie"===i||"polarArea"===i||"donut"===i){let e=a.config.plotOptions.pie.donut.labels;new Y(this.w).pathMouseDown(t,null),this.lgCtx.printDataLabelsInner(t.node,e)}if(a.config.chart.accessibility.enabled){let t=a.dom.baseEl.querySelector(`.apexcharts-legend-series[rel="${e+1}"]`);if(t){let i=a.globals.collapsedSeriesIndices.includes(e);t.setAttribute("aria-pressed",i?"true":"false");let s=t.querySelector(".apexcharts-legend-text"),r=s?s.textContent:a.seriesData.seriesNames[e];t.setAttribute("aria-label",`${r}, ${i?"hidden":"visible"}. Press Enter or Space to toggle.`)}}}}getSeriesAfterCollapsing({realIndex:e}){var t;let i=this.w,s=i.globals,a=v.clone(i.config.series);if(s.axisCharts){let t=i.config.yaxis[s.seriesYAxisReverseMap[e]],r={index:e,data:a[e].data.slice(),type:a[e].type||i.config.chart.type};if(t&&t.show&&t.showAlways)0>s.ancillaryCollapsedSeriesIndices.indexOf(e)&&(s.ancillaryCollapsedSeries.push(r),s.ancillaryCollapsedSeriesIndices.push(e));else if(0>s.collapsedSeriesIndices.indexOf(e)){s.collapsedSeries.push(r),s.collapsedSeriesIndices.push(e);let t=s.risingSeries.indexOf(e);s.risingSeries.splice(t,1)}}else s.collapsedSeries.push({index:e,data:a[e],type:null!=(t=i.config.series[e].type)?t:"line"}),s.collapsedSeriesIndices.push(e);return s.allSeriesCollapsed=s.collapsedSeries.length+s.ancillaryCollapsedSeries.length===i.config.series.length,this._getSeriesBasedOnCollapsedState(a)}hideSeries({seriesEl:e,realIndex:t}){let i=this.w,s=this.getSeriesAfterCollapsing({realIndex:t}),a=e.childNodes;for(let e=0;e<a.length;e++)a[e].classList.contains("apexcharts-series-markers-wrap")&&(a[e].classList.contains("apexcharts-hide")?a[e].classList.remove("apexcharts-hide"):a[e].classList.add("apexcharts-hide"));this.lgCtx.updateSeries(s,i.config.chart.animations.dynamicAnimation.enabled)}riseCollapsedSeries(e,t,i){let s=this.w,a=v.clone(s.config.series);if(e.length>0){for(let r=0;r<e.length;r++)e[r].index===i&&(s.globals.axisCharts?a[i].data=e[r].data.slice():a[i]=e[r].data,"number"!=typeof a[i]&&(a[i].hidden=!1),e.splice(r,1),t.splice(r,1),s.globals.risingSeries.push(i),r--);a=this._getSeriesBasedOnCollapsedState(a),this.lgCtx.updateSeries(a,s.config.chart.animations.dynamicAnimation.enabled)}}_getSeriesBasedOnCollapsedState(e){let t=this.w,i=0;return t.globals.axisCharts?e.forEach((s,a)=>{!(0>t.globals.collapsedSeriesIndices.indexOf(a)&&0>t.globals.ancillaryCollapsedSeriesIndices.indexOf(a))&&(e[a].data=[],i++)}):e.forEach((s,a)=>{!(0>t.globals.collapsedSeriesIndices.indexOf(a))&&(e[a]=0,i++)}),t.globals.allSeriesCollapsed=i===e.length,e}};class e2{constructor(e,t){this.w=e,this.ctx=t,this.printDataLabelsInner=(...e)=>{var i;return null==(i=t.pie)?void 0:i.printDataLabelsInner(...e)},this.updateSeries=(...e)=>t.updateHelpers._updateSeries(...e),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 e1(this)}init(){let e=this.w,t=e.globals,i=e.config,s=i.legend.showForSingleSeries&&1===this.w.seriesData.series.length||this.isBarsDistributed||this.w.seriesData.series.length>1;if(this.legendHelpers.appendToForeignObject(),(s||!t.axisCharts)&&i.legend.show){let t=e.dom.elLegendWrap;for(;t.firstChild;)t.removeChild(t.firstChild);this.drawLegends(),"bottom"===i.legend.position||"top"===i.legend.position?this.legendAlignHorizontal():("right"===i.legend.position||"left"===i.legend.position)&&this.legendAlignVertical()}}createLegendMarker({i:e,fillcolor:t}){let s=this.w,a=w.createElement("span");a.classList.add("apexcharts-legend-marker");let r=s.config.legend.markers.shape||s.config.markers.shape,l=r;Array.isArray(r)&&(l=r[e]);let o=Array.isArray(s.config.legend.markers.size)?parseFloat(s.config.legend.markers.size[e]):parseFloat(s.config.legend.markers.size),n=Array.isArray(s.config.legend.markers.offsetX)?parseFloat(s.config.legend.markers.offsetX[e]):parseFloat(s.config.legend.markers.offsetX),h=Array.isArray(s.config.legend.markers.offsetY)?parseFloat(s.config.legend.markers.offsetY[e]):parseFloat(s.config.legend.markers.offsetY),g=Array.isArray(s.config.legend.markers.strokeWidth)?parseFloat(s.config.legend.markers.strokeWidth[e]):parseFloat(s.config.legend.markers.strokeWidth),x=a.style;if(x.height=(o+g)*2+"px",x.width=(o+g)*2+"px",x.left=n+"px",x.top=h+"px",s.config.legend.markers.customHTML)x.background="transparent",x.color=t[e],Array.isArray(s.config.legend.markers.customHTML)?s.config.legend.markers.customHTML[e]&&(a.innerHTML=s.config.legend.markers.customHTML[e]()):a.innerHTML=s.config.legend.markers.customHTML();else{let r=new _(this.ctx.w,this.ctx).getMarkerConfig({cssClass:`apexcharts-legend-marker apexcharts-marker apexcharts-marker-${l}`,seriesIndex:e,strokeWidth:g,size:o}),n=(p.isBrowser()?window.SVG:i.g.SVG)().addTo(a).size("100%","100%"),h=new Y(this.w).drawMarker(0,0,c(d({},r),{pointFillColor:Array.isArray(t)?t[e]:r.pointFillColor,shape:l}));s.dom.Paper.find(".apexcharts-legend-marker.apexcharts-marker").forEach(e
903=>{e.node.classList.contains("apexcharts-marker-triangle")?e.node.style.transform="translate(50%, 45%)":e.node.style.transform="translate(50%, 50%)"}),n.add(h)}return a}drawLegends(){var e;let t=this.w,i=t.dom.elLegendWrap,s=t.config.legend.fontFamily,a=t.seriesData.seriesNames,r=t.config.legend.markers.fillColors?t.config.legend.markers.fillColors.slice():t.globals.colors.slice();if("heatmap"===t.config.chart.type){let e=t.config.plotOptions.heatmap.colorScale.ranges;a=e.map(e=>e.name?e.name:e.from+" - "+e.to),r=e.map(e=>e.color)}else this.isBarsDistributed&&(a=t.labelData.labels.slice());t.config.legend.customLegendItems.length&&(a=t.config.legend.customLegendItems);let l=t.formatters.legendFormatter,o=t.config.legend.inverseOrder,n=[];t.labelData.seriesGroups.length>1&&t.config.legend.clusterGroupedSeries&&t.labelData.seriesGroups.forEach((e,s)=>{n[s]=w.createElement("div"),n[s].classList.add("apexcharts-legend-group",`apexcharts-legend-group-${s}`),"horizontal"===t.config.legend.clusterGroupedSeriesOrientation?i.classList.add("apexcharts-legend-group-horizontal"):n[s].classList.add("apexcharts-legend-group-vertical")});for(let h=o?a.length-1:0;o?h>=0:h<=a.length-1;o?h--:h++){let o=l(a[h],{seriesIndex:h,w:t}),d=!1,c=!1;if(t.globals.collapsedSeries.length>0)for(let e=0;e<t.globals.collapsedSeries.length;e++)t.globals.collapsedSeries[e].index===h&&(d=!0);if(t.globals.ancillaryCollapsedSeriesIndices.length>0)for(let e=0;e<t.globals.ancillaryCollapsedSeriesIndices.length;e++)t.globals.ancillaryCollapsedSeriesIndices[e]===h&&(c=!0);let g=this.createLegendMarker({i:h,fillcolor:r});Y.setAttrs(g,{rel:h+1,"data:collapsed":d||c}),(d||c)&&g.classList.add("apexcharts-inactive-legend");let p=w.createElement("div");if(t.config.chart.accessibility.enabled&&t.config.chart.accessibility.keyboard.enabled){p.setAttribute("role","button"),p.setAttribute("tabindex","0");let e=Array.isArray(o)?o.join(" "):o,t=d||c,i=t?"hidden":"visible";p.setAttribute("aria-label",`${e}, ${i}. Press Enter or Space to toggle.`),p.setAttribute("aria-pressed",t?"true":"false")}let x=w.createElement("span");x.classList.add("apexcharts-legend-text"),x.innerHTML=Array.isArray(o)?o.join(" "):o;let u=t.config.legend.labels.useSeriesColors?t.globals.colors[h]:Array.isArray(t.config.legend.labels.colors)?null==(e=t.config.legend.labels.colors)?void 0:e[h]:t.config.legend.labels.colors;u||(u=t.config.chart.foreColor),x.style.color=u,x.style.fontSize=t.config.legend.fontSize,x.style.fontWeight=t.config.legend.fontWeight,x.style.fontFamily=s||t.config.chart.fontFamily,Y.setAttrs(x,{rel:h+1,i:h,"data:default-text":encodeURIComponent(o),"data:collapsed":d||c}),p.appendChild(g),p.appendChild(x);let f=new I(this.w);!t.config.legend.showForZeroSeries&&0===f.getSeriesTotalByIndex(h)&&f.seriesHaveSameValues(h)&&!f.isSeriesNull(h)&&-1===t.globals.collapsedSeriesIndices.indexOf(h)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(h)&&p.classList.add("apexcharts-hidden-zero-series"),!t.config.legend.showForNullSeries&&f.isSeriesNull(h)&&-1===t.globals.collapsedSeriesIndices.indexOf(h)&&-1===t.globals.ancillaryCollapsedSeriesIndices.indexOf(h)&&p.classList.add("apexcharts-hidden-null-series"),n.length?t.labelData.seriesGroups.forEach((e,s)=>{var a,r;e.includes(null!=(r=null==(a=t.config.series[h])?void 0:a.name)?r:"")&&(i.appendChild(n[s]),n[s].appendChild(p))}):i.appendChild(p),i.classList.add(`apexcharts-align-${t.config.legend.horizontalAlign}`),i.classList.add("apx-legend-position-"+t.config.legend.position),p.classList.add("apexcharts-legend-series"),p.style.margin=`${t.config.legend.itemMargin.vertical}px ${t.config.legend.itemMargin.horizontal}px`,i.style.width=t.config.legend.width?t.config.legend.width+"px":"",i.style.height=t.config.legend.height?t.config.legend.height+"px":"",Y.setAttrs(p,{rel:h+1,seriesName:v.escapeString(a[h]),"data:collapsed":d||c}),(d||c)&&p.classList.add("apexcharts-inactive-legend"),t.config.legend.onItemClick.toggleDataSeries||p.classList.add("apexcharts-no-click")}t.dom.elWrap.addEventListener("click",this.onLegendClick,!0),t.config.legend.onItemHover.highlightDataSeries&&0===t.config.legend.customLegendItems.length&&(t.dom.elWrap.addEventListener("mousemove",this.onLegendHovered,!0),t.dom.elWrap.addEventListener("mouseout",this.onLegendHovered,!0)),t.config.chart.accessibility.enabled&&t.config.chart.accessibility.keyboard.enabled&&t.dom.elWrap.addEventListener("keydown",this.onLegendKeyDown.bind(this),!0)}setLegendWrapXY(e,t){let i=this.w,s=i.dom.elLegendWrap,a=s.clientHeight,r=0,l=0;if("bottom"===i.config.legend.position)l=i.globals.svgHeight-Math.min(a,i.globals.svgHeight/2)-5;else if("top"===i.config.legend.position){let e=new eg(this.w,this.ctx),t=e.dimHelpers.getTitleSubtitleCoords("title").height,i=e.dimHelpers.getTitleSubtitleCoords("subtitle").height;l=(t>0?t-10:0)+(i>0?i-10:0)}s.style.position="absolute",r=r+e+i.config.legend.offsetX,l=l+t+i.config.legend.offsetY,s.style.left=r+"px",s.style.top=l+"px","right"===i.config.legend.position&&(s.style.left="auto",s.style.right=25+i.config.legend.offsetX+"px"),["width","height"].forEach(e
903=>{s&&s.style[e]&&(s.style[e]=parseInt(String(i.config.legend[e]),10)+"px")})}legendAlignHorizontal(){let e=this.w;e.dom.elLegendWrap.style.right="0";let t=new eg(this.w,this.ctx),i=t.dimHelpers.getTitleSubtitleCoords("title"),s=t.dimHelpers.getTitleSubtitleCoords("subtitle"),a=0;"top"===e.config.legend.position&&(a=i.height+s.height+e.config.title.margin+e.config.subtitle.margin-10),this.setLegendWrapXY(20,a)}legendAlignVertical(){let 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)}onLegendHovered(e){var t;let i=this.w,s=e.target,a=s.classList.contains("apexcharts-legend-series")||s.classList.contains("apexcharts-legend-text")||s.classList.contains("apexcharts-legend-marker");if("heatmap"===i.config.chart.type||this.isBarsDistributed){if(a){let i=parseInt(null!=(t=s.getAttribute("rel"))?t:"0",10)-1;this.ctx.events.fireEvent("legendHover",[this.ctx,i,this.w]),new er(this.ctx.w).highlightRangeInSeries(e,s)}}else!s.classList.contains("apexcharts-inactive-legend")&&a&&new er(this.ctx.w).toggleSeriesOnHover(e,s)}onLegendKeyDown(e){let t=this.w,i=e.target;if((i.classList.contains("apexcharts-legend-series")||i.classList.contains("apexcharts-legend-text")||i.classList.contains("apexcharts-legend-marker"))&&("Enter"===e.key||" "===e.key)){e.preventDefault();let s=i.getAttribute("rel");this.onLegendClick(e),null!==s&&t.config.legend.onItemClick.toggleDataSeries&&requestAnimationFrame(()=>{let e=t.dom.baseEl.querySelector(`.apexcharts-legend-series[rel="${s}"]`);e&&e.focus()})}}onLegendClick(e){var t;let i=this.w,s=e.target;if(!i.config.legend.customLegendItems.length&&(s.classList.contains("apexcharts-legend-series")||s.classList.contains("apexcharts-legend-text")||s.classList.contains("apexcharts-legend-marker"))){let e=parseInt(null!=(t=s.getAttribute("rel"))?t:"0",10)-1,a="true"===s.getAttribute("data:collapsed"),r=this.w.config.chart.events.legendClick;"function"==typeof r&&r(this.ctx,e,this.w),this.ctx.events.fireEvent("legendClick",[this.ctx,e,this.w]);let l=this.w.config.legend.markers.onClick;"function"==typeof l&&s.classList.contains("apexcharts-legend-marker")&&(l(this.ctx,e,this.w),this.ctx.events.fireEvent("legendMarkerClick",[this.ctx,e,this.w])),"treemap"!==i.config.chart.type&&"heatmap"!==i.config.chart.type&&!this.isBarsDistributed&&i.config.legend.onItemClick.toggleDataSeries&&this.legendHelpers.toggleDataSeries(e,a)}}}eJ.registerFeatures({legend:e2});class e5{constructor(e,t){this.w=e,this.ctx=t,this.ev=this.w.config.chart.events,this.selectedClass="apexcharts-selected",this.localeValues=this.w.globals.locale.toolbar,this.minX=e.globals.minX,this.maxX=e.globals.maxX,this.elZoom=null,this.elZoomIn=null,this.elZoomOut=null,this.elPan=null,this.elSelection=null,this.elZoomReset=null,this.elMenuIcon=null,this.elMenu=null,this.elMenuItems=[],this.t=null}createToolbar(){let e=this.w,t=()=>{let e=w.createElementNS("http://www.w3.org/1999/xhtml","button");return e.setAttribute("type","button"),e},i=w.createElementNS("http://www.w3.org/1999/xhtml","div");if(i.setAttribute("class","apexcharts-toolbar"),i.style.top=e.config.chart.toolbar.offsetY+"px",i.style.right=-e.config.chart.toolbar.offsetX+3+"px",e.dom.elWrap.appendChild(i),this.elZoom=t(),this.elZoomIn=t(),this.elZoomOut=t(),this.elPan=t(),this.elSelection=t(),this.elZoomReset=t(),this.elMenuIcon=t(),this.elMenu=w.createElementNS("http://www.w3.org/1999/xhtml","div"),this.elCustomIcons=[],this.t=e.config.chart.toolbar.tools,Array.isArray(this.t.customIcons))for(let e=0;e<this.t.customIcons.length;e++)this.elCustomIcons.push(t());let s=[],a=(t,i,a)=>{let r=t.toLowerCase();this.t[r]&&e.config.chart.zoom.enabled&&s.push({el:i,icon:"string"==typeof this.t[r]?this.t[r]:a,title:this.localeValues[t],class:`apexcharts-${r}-icon`})};a("zoomIn",this.elZoomIn,'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\n    <path d="M0 0h24v24H0z" fill="none"/>\n    <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"/>\n</svg>\n'),a("zoomOut",this.elZoomOut,'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\n    <path d="M0 0h24v24H0z" fill="none"/>\n    <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"/>\n</svg>\n');let r=t=>{this.t[t]&&e.config.chart[t].enabled&&s.push({el:"zoom"===t?this.elZoom:this.elSelection,icon:"string"==typeof this.t[t]?this.t[t]:"zoom"===t?'<svg xmlns="http://www.w3.org/2000/svg" fill="#000000" height="24" viewBox="0 0 24 24" width="24">\n    <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"/>\n    <path d="M0 0h24v24H0V0z" fill="none"/>\n    <path d="M12 10h-2v2H9v-2H7V9h2V7h1v2h2v1z"/>\n</svg>':'<svg fill="#6E8192" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">\n    <path d="M0 0h24v24H0z" fill="none"/>\n    <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"/>\n</svg>',title:this.localeValues["zoom"===t?"selectionZoom":"selection"],class:`apexcharts-${t}-icon`})};r("zoom"),r("selection"),this.t.pan&&e.config.chart.zoom.enabled&&s.push({el:this.elPan,icon:"string"==typeof this.t.pan?this.t.pan:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="#000000" height="24" viewBox="0 0 24 24" width="24">\n    <defs>\n        <path d="M0 0h24v24H0z" id="a"/>\n    </defs>\n    <clipPath id="b">\n        <use overflow="visible" xlink:href="#a"/>\n    </clipPath>\n    <path clip-path="url(#b)" d="M23 5.5V20c0 2.2-1.8 4-4 4h-7.3c-1.08 
9030-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"/>\n</svg>',title:this.localeValues.pan,class:"apexcharts-pan-icon"}),a("reset",this.elZoomReset,'<svg fill="#000000" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">\n    <path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"/>\n    <path d="M0 0h24v24H0z" fill="none"/>\n</svg>'),this.t.download&&s.push({el:this.elMenuIcon,icon:"string"==typeof this.t.download?this.t.download:'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"/><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/></svg>',title:this.localeValues.menu,class:"apexcharts-menu-icon"});for(let e=0;e<this.elCustomIcons.length;e++)s.push({el:this.elCustomIcons[e],icon:this.t.customIcons[e].icon,title:this.t.customIcons[e].title,index:this.t.customIcons[e].index,class:"apexcharts-toolbar-custom-icon "+this.t.customIcons[e].class});s.forEach((e,t)=>{e.index&&v.moveIndexInArray(s,t,e.index)});for(let e=0;e<s.length;e++)Y.setAttrs(s[e].el,{class:s[e].class,title:s[e].title,"aria-label":s[e].title}),s[e].el.innerHTML=s[e].icon,i.appendChild(s[e].el);this.elZoom.parentNode&&this.elZoom.setAttribute("aria-pressed",String(!!e.interact.zoomEnabled)),this.elSelection.parentNode&&this.elSelection.setAttribute("aria-pressed",String(!!e.interact.selectionEnabled)),this.elPan.parentNode&&this.elPan.setAttribute("aria-pressed",String(!!e.interact.panEnabled)),this.elMenuIcon.parentNode&&(this.elMenuIcon.setAttribute("aria-haspopup","true"),this.elMenuIcon.setAttribute("aria-expanded","false")),this._createHamburgerMenu(i),e.interact.zoomEnabled?this.elZoom.classList.add(this.selectedClass):e.interact.panEnabled?this.elPan.classList.add(this.selectedClass):e.interact.selectionEnabled&&this.elSelection.classList.add(this.selectedClass),this.addToolbarEventListeners()}_createHamburgerMenu(e){this.elMenuItems=[],e.appendChild(this.elMenu),Y.setAttrs(this.elMenu,{class:"apexcharts-menu",role:"menu"});let t=[{name:"exportSVG",title:this.localeValues.exportToSVG},{name:"exportPNG",title:this.localeValues.exportToPNG},{name:"exportCSV",title:this.localeValues.exportToCSV}];for(let e=0;e<t.length;e++)this.elMenuItems.push(w.createElementNS("http://www.w3.org/1999/xhtml","div")),this.elMenuItems[e].innerHTML=t[e].title,Y.setAttrs(this.elMenuItems[e],{class:`apexcharts-menu-item ${t[e].name}`,title:t[e].title,role:"menuitem",tabindex:"-1"}),this.elMenu.appendChild(this.elMenuItems[e])}addToolbarEventListeners(){var e,t,i,s,a,r,l,o;null==(e=this.elZoomReset)||e.addEventListener("click",this.handleZoomReset.bind(this)),null==(t=this.elSelection)||t.addEventListener("click",this.toggleZoomSelection.bind(this,"selection")),null==(i=this.elZoom)||i.addEventListener("click",this.toggleZoomSelection.bind(this,"zoom")),null==(s=this.elZoomIn)||s.addEventListener("click",this.handleZoomIn.bind(this)),null==(a=this.elZoomOut)||a.addEventListener("click",this.handleZoomOut.bind(this)),null==(r=this.elPan)||r.addEventListener("click",this.togglePanning.bind(this)),null==(l=this.elMenuIcon)||l.addEventListener("click",this.toggleMenu.bind(this)),this.elMenuItems.forEach(e=>{e.classList.contains("exportSVG")?e.addEventListener("click",this.handleDownload.bind(this,"svg")):e.classList.contains("exportPNG")?e.addEventListener("click",this.handleDownload.bind(this,"png")):e.classList.contains("exportCSV")&&e.addEventListener("click",this.handleDownload.bind(this,"csv"))});for(let e=0;e<this.t.customIcons.length;e++)this.elCustomIcons[e].addEventListener("click",this.t.customIcons[e].click.bind(this,this.ctx,this.ctx.w));[this.elZoomReset,this.elSelection,this.elZoom,this.elZoomIn,this.elZoomOut,this.elPan,this.elMenuIcon,...this.elCustomIcons].forEach(e=>{e.addEventListener("keydown",t=>{if("Enter"===t.key||" "===t.key){t.preventDefault();let i=e.className;e.click(),requestAnimationFrame(()=>{let e=this.w.dom.baseEl;if(!e)return;let t=i.split(" ").find(e=>e.startsWith("apexcharts-"));if(!t)return;let s=e.querySelector(`.${t}`);s&&s.focus()})}})}),null==(o=this.elMenuIcon)||o.addEventListener("keydown",e=>{var t;
903("ArrowDown"===e.key||"ArrowUp"===e.key)&&(e.preventDefault(),(null==(t=this.elMenu)?void 0:t.classList.contains("apexcharts-menu-open"))||this.toggleMenu(),window.setTimeout(()=>{let t="ArrowDown"===e.key?0:this.elMenuItems.length-1;this.elMenuItems[t]&&this.elMenuItems[t].focus()},20))}),this.elMenuItems.forEach((e,t)=>{e.addEventListener("keydown",i=>{var s;"ArrowDown"===i.key?(i.preventDefault(),(this.elMenuItems[t+1]||this.elMenuItems[0]).focus()):"ArrowUp"===i.key?(i.preventDefault(),(this.elMenuItems[t-1]||this.elMenuItems[this.elMenuItems.length-1]).focus()):"Escape"===i.key||"Tab"===i.key?(this._closeMenu(),null==(s=this.elMenuIcon)||s.focus(),"Tab"===i.key||i.preventDefault()):("Enter"===i.key||" "===i.key)&&(i.preventDefault(),e.click())})})}toggleZoomSelection(e){this.ctx.getSyncedCharts().forEach(t=>{t.ctx.toolbar.toggleOtherControls();let i="selection"===e?t.ctx.toolbar.elSelection:t.ctx.toolbar.elZoom,s="selection"===e?"selectionEnabled":"zoomEnabled";t.w.globals[s]=!t.w.globals[s],i.classList.contains(t.ctx.toolbar.selectedClass)?i.classList.remove(t.ctx.toolbar.selectedClass):i.classList.add(t.ctx.toolbar.selectedClass),i.setAttribute("aria-pressed",String(t.w.globals[s]))})}getToolbarIconsReference(){let e=this.w;this.elZoom||(this.elZoom=e.dom.baseEl.querySelector(".apexcharts-zoom-icon")),this.elPan||(this.elPan=e.dom.baseEl.querySelector(".apexcharts-pan-icon")),this.elSelection||(this.elSelection=e.dom.baseEl.querySelector(".apexcharts-selection-icon"))}enableZoomPanFromToolbar(e){this.toggleOtherControls(),"pan"===e?this.w.interact.panEnabled=!0:this.w.interact.zoomEnabled=!0;let 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)}togglePanning(){this.ctx.getSyncedCharts().forEach(e=>{e.ctx.toolbar.toggleOtherControls(),e.w.interact.panEnabled=!e.w.interact.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),e.ctx.toolbar.elPan.setAttribute("aria-pressed",String(e.w.interact.panEnabled))})}toggleOtherControls(){let e=this.w;e.interact.panEnabled=!1,e.interact.zoomEnabled=!1,e.interact.selectionEnabled=!1,this.getToolbarIconsReference(),[this.elPan,this.elSelection,this.elZoom].forEach(e=>{e&&e.classList.remove(this.selectedClass)})}handleZoomIn(){let e=this.w;e.axisFlags.isRangeBar&&(this.minX=e.globals.minY,this.maxX=e.globals.maxY);let t=(this.minX+this.maxX)/2,i=(this.minX+t)/2,s=(this.maxX+t)/2,a=this._getNewMinXMaxX(i,s);e.interact.disableZoomIn||this.zoomUpdateOptions(a.minX,a.maxX)}handleZoomOut(){let e=this.w;if(e.axisFlags.isRangeBar&&(this.minX=e.globals.minY,this.maxX=e.globals.maxY),"datetime"===e.config.xaxis.type&&1e3>new Date(this.minX).getUTCFullYear())return;let t=(this.minX+this.maxX)/2,i=this.minX-(t-this.minX),s=this.maxX-(t-this.maxX),a=this._getNewMinXMaxX(i,s);e.interact.disableZoomOut||this.zoomUpdateOptions(a.minX,a.maxX)}_getNewMinXMaxX(e,t){let i=this.w.config.xaxis.convertedCatToNumeric;return{minX:i?Math.floor(e):e,maxX:i?Math.floor(t):t}}zoomUpdateOptions(e,t){let i=this.w;if(void 0===e&&void 0===t)return void this.handleZoomReset();if(i.config.xaxis.convertedCatToNumeric&&(e<1&&(e=1,t=i.globals.dataPoints),t-e<2))return;let s={min:e,max:t},a=this.getBeforeZoomRange(s,void 0);a&&(s=a.xaxis);let r={xaxis:s};if(!i.globals.initialConfig)return;let l=v.clone(i.globals.initialConfig.yaxis);i.config.chart.group||(r.yaxis=l),this.w.interact.zoomed=!0,this.ctx.updateHelpers._updateOptions(r,!1,this.w.config.chart.animations.dynamicAnimation.enabled),this.zoomCallback(s,l)}zoomCallback(e,t){"function"==typeof this.ev.zoomed&&(this.ev.zoomed(this.ctx,{xaxis:e,yaxis:t}),this.ctx.events.fireEvent("zoomed",{xaxis:e,yaxis:t}))}getBeforeZoomRange(e,t){let i=null;return"function"==typeof this.ev.beforeZoom&&(i=this.ev.beforeZoom(this,{xaxis:e,yaxis:t})),i}toggleMenu(){window.setTimeout(()=>{var e,t,i;(null==(e=this.elMenu)?void 0:e.classList.contains("apexcharts-menu-open"))?this._closeMenu():(null==(t=this.elMenu)||t.classList.add("apexcharts-menu-open"),null==(i=this.elMenuIcon)||i.setAttribute("aria-expanded","true"))},0)}_closeMenu(){var e,t;null==(e=this.elMenu)||e.classList.remove("apexcharts-menu-open"),null==(t=this.elMenuIcon)||t.setAttribute("aria-expanded","fal
903se")}handleDownload(e){let t=this.w,i=new e0(this.w,this.ctx);switch(e){case"svg":i.exportToSVG();break;case"png":i.exportToPng();break;case"csv":i.exportToCSV({series:t.config.series,columnDelimiter:t.config.chart.toolbar.export.csv.columnDelimiter})}}handleZoomReset(){this.ctx.getSyncedCharts().forEach(e=>{let t=e.w;if(!t.interact.zoomed)return;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){let 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});let i=e.ctx.series.emptyCollapsedSeries(v.clone(t.globals.initialSeries));e.updateHelpers._updateSeries(i,t.config.chart.animations.dynamicAnimation.enabled),t.interact.zoomed=!1})}destroy(){this.elZoom=null,this.elZoomIn=null,this.elZoomOut=null,this.elPan=null,this.elSelection=null,this.elZoomReset=null,this.elMenuIcon=null}}class e3 extends e5{constructor(e,t){super(e,t),this.w=e,this.ctx=t,this.dragged=!1,this.graphics=new Y(this.w),this.eventList=["mousedown","mouseleave","mousemove","touchstart","touchmove","mouseup","touchend","wheel"],this.clientX=0,this.clientY=0,this.startX=0,this.endX=0,this.dragX=0,this.startY=0,this.endY=0,this.dragY=0,this.moveDirection="none",this.debounceTimer=null,this.debounceDelay=100,this.wheelDelay=400}init({xyRatios:e}){let t=this.w,i=this;this.xyRatios=e,this.zoomRect=this.graphics.drawRect(0,0,0,0),this.selectionRect=this.graphics.drawRect(0,0,0,0),this.gridRect=t.dom.baseEl.querySelector(".apexcharts-grid"),this.constraints=new O(0,0,t.layout.gridWidth,t.layout.gridHeight),this.zoomRect.node.classList.add("apexcharts-zoom-rect"),this.selectionRect.node.classList.add("apexcharts-selection-rect"),t.dom.Paper.add(this.zoomRect),t.dom.Paper.add(this.selectionRect),"x"===t.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,minY:0,maxX:t.layout.gridWidth,maxY:t.layout.gridHeight}).on("dragmove.namespace",this.selectionDragging.bind(this,"dragging")):"y"===t.config.chart.selection.type?this.slDraggableRect=this.selectionRect.draggable({minX:0,maxX:t.layout.gridWidth}).on("dragmove.namespace",this.selectionDragging.bind(this,"dragging")):this.slDraggableRect=this.selectionRect.draggable().on("dragmove.namespace",this.selectionDragging.bind(this,"dragging")),this.preselectedSelection(),this.hoverArea=t.dom.baseEl.querySelector(`${t.globals.chartClass} .apexcharts-svg`),this.hoverArea&&(this.hoverArea.classList.add("apexcharts-zoomable"),this.eventList.forEach(t=>{var s;null==(s=this.hoverArea)||s.addEventListener(t,i.svgMouseEvents.bind(i,e),{capture:!1,passive:!0})}),t.config.chart.zoom.enabled&&t.config.chart.zoom.allowMouseWheelZoom&&this.hoverArea.addEventListener("wheel",i.mouseWheelEvent.bind(i),{capture:!1,passive:!1}))}destroy(){this.slDraggableRect&&(this.slDraggableRect.draggable(!1),this.slDraggableRect.off(),this.selectionRect.off()),this.selectionRect=null,this.zoomRect=null,this.gridRect=null}svgMouseEvents(e,t){var i;let s,a=this.w,r=this.ctx.toolbar,l=a.interact.zoomEnabled?a.config.chart.zoom.type:a.config.chart.selection.type,o=a.config.chart.toolbar.autoSelected;if(t.shiftKey?(this.shiftWasPressed=!0,r.enableZoomPanFromToolbar("pan"===o?"zoom":"pan")):this.shiftWasPressed&&(r.enableZoomPanFromToolbar(o),this.shiftWasPressed=!1),!t.target)return;let n=t.target.classList;if(t.target.parentNode&&null!==t.target.parentNode&&(s=t.target.parentNode.classList),!(n.contains("apexcharts-legend-marker")||n.contains("apexcharts-legend-text")||s&&s.contains("apexcharts-toolbar"))){if(this.clientX="touchmove"===t.type||"touchstart"===t.type?t.touches[0].clientX:"touchend"===t.type?t.changedTouches[0].clientX:t.clientX,this.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||"touchstart"===t.type){let e=null==(i=this.gridRect)?void 0:i.getBoundingClientRect();if(!e)return;this.startX=this.clientX-e.left-a.globals.barPadForNumericAxis,this.startY=this.clientY-e.top,this.dragged=!1,this.w.interact.mousedown=!0}("mousemove"===t.type&&1===t.which||"touchmove"===t.type)&&(this.dragged=!0,a.interact.panEnabled?(a.interact.selection=null,this.w.interact.mousedown&&this.panDragging({context:this,zoomtype:l,xyRatios:e})):(this.w.interact.mousedown&&a.interact.zoomEnabled||this.w.interact.mousedown&&a.interact.selectionEnabled)&&(this.selection=this.selectionDrawing({context:this,zoomtype:l}))),("mouseup"===t.type||"touchend"===t.type||"mouseleave"===t.type)&&this.handleMouseUp({zoomtype:l}),this.makeSelectionRectDraggable()}}handleMouseUp({zoomtype:e,isResized:t}){var i;let s=this.w,a=null==(i=this.gridRect)?void 0:i.getBoundingClientRect();a&&(this.w.interact.mousedown||t)&&(this.endX=this.clientX-a.left-s.globals.barPadForNumericAxis,this.endY=this.clientY-a.top,this.dragX=Math.abs(this.endX-this.startX),this.dragY=Math.abs(this.endY-this.startY),(s.interact.zoomEnabled||s.interact.selectionEnabled)&&this.selectionDrawn({context:this,zoomtype:e})),s.interact.zoomEnabled&&this.hideSelectionRect(this.selectionRect),this.dragged=!1,this.w.interact.mousedown=!1}mouseWheelEvent(e){let t=this.w;e.preventDefault();let i=Date.now();i-t.interact.lastWheelExecution>this.wheelDelay&&(this.executeMouseWheelZoom(e),t.interact.lastWheelExecution=i),this.debounceTimer&&clearTimeout(this.debounceTimer),this.debounceTimer=setTimeout(()=>{i-t.interact.lastWheelExecution>this.wheelDelay&&(this.executeMouseWheelZoom(e),t.interact.lastWheelExecution=i)},this.debounceDelay)}executeMouseWheelZoom(e){var t;let i,s,a,r=this.w;this.minX=r.axisFlags.isRangeBar?r.globals.minY:r.globals.minX,this.maxX=r.axisFlags.isRangeBar?r.globals.maxY:r.globals.maxX;let l=null==(t=this.gridRect)?void 0:t.getBoundingClientRect();if(!l)return;let o=(e.clientX-l.left)/l.width,n=this.minX,h=this.maxX,d=h-n;
903if(e.deltaY<0){i=.5*d;let e=n+o*d;s=e-i/2,a=e+i/2}else s=n-(i=1.5*d)/2,a=h+i/2;if(!r.axisFlags.isRangeBar){s=Math.max(s,r.globals.initialMinX),a=Math.min(a,r.globals.initialMaxX);let e=(r.globals.initialMaxX-r.globals.initialMinX)*.01;if(a-s<e){let t=(s+a)/2;s=t-e/2,a=t+e/2}}let c=this._getNewMinXMaxX(s,a);isNaN(c.minX)||isNaN(c.maxX)||this.zoomUpdateOptions(c.minX,c.maxX)}makeSelectionRectDraggable(){let e=this.w;if(!this.selectionRect)return;let t=this.selectionRect.node.getBoundingClientRect();t.width>0&&t.height>0&&(this.selectionRect.select(!1).resize(!1),this.selectionRect.select({createRot:()=>{},updateRot:()=>{},createHandle:(e,t,i,s,a)=>"l"===a||"r"===a?e.circle(8).css({"stroke-width":1,stroke:"#333",fill:"#fff"}):e.circle(0),updateHandle:(e,t)=>e.center(t[0],t[1])}).resize().on("resize",()=>{let t=e.interact.zoomEnabled?e.config.chart.zoom.type:e.config.chart.selection.type;this.handleMouseUp({zoomtype:t,isResized:!0})}))}preselectedSelection(){let e=this.w,t=this.xyRatios;if(!e.interact.zoomEnabled){if(void 0!==e.interact.selection&&null!==e.interact.selection)this.drawSelectionRect(c(d({},e.interact.selection),{translateX:e.layout.translateX,translateY:e.layout.translateY}));else if(void 0!==e.config.chart.selection.xaxis.min&&void 0!==e.config.chart.selection.xaxis.max){let i=(e.config.chart.selection.xaxis.min-e.globals.minX)/t.xRatio,s=e.layout.gridWidth-(e.globals.maxX-e.config.chart.selection.xaxis.max)/t.xRatio-i;e.axisFlags.isRangeBar&&(i=(e.config.chart.selection.xaxis.min-e.globals.yAxisScale[0].niceMin)/t.invertedYRatio,s=(e.config.chart.selection.xaxis.max-e.config.chart.selection.xaxis.min)/t.invertedYRatio);let a={x:i,y:0,width:s,height:e.layout.gridHeight,translateX:e.layout.translateX,translateY:e.layout.translateY,selectionEnabled:!0};this.drawSelectionRect(a),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:{}})}}}drawSelectionRect({x:e,y:t,width:i,height:s,translateX:a=0,translateY:r=0}){let l=this.w,o=this.zoomRect,n=this.selectionRect;if(this.dragged||null!==l.interact.selection){let h={transform:"translate("+a+", "+r+")"};l.interact.zoomEnabled&&this.dragged&&(i<0&&(i=1),o.attr({x:e,y:t,width:i,height:s,fill:l.config.chart.zoom.zoomedArea.fill.color,"fill-opacity":l.config.chart.zoom.zoomedArea.fill.opacity,stroke:l.config.chart.zoom.zoomedArea.stroke.color,"stroke-width":l.config.chart.zoom.zoomedArea.stroke.width,"stroke-opacity":l.config.chart.zoom.zoomedArea.stroke.opacity}),Y.setAttrs(o.node,h)),l.interact.selectionEnabled&&(n.attr({x:e,y:t,width:i>0?i:0,height:s>0?s:0,fill:l.config.chart.selection.fill.color,"fill-opacity":l.config.chart.selection.fill.opacity,stroke:l.config.chart.selection.stroke.color,"stroke-width":l.config.chart.selection.stroke.width,"stroke-dasharray":l.config.chart.selection.stroke.dashArray,"stroke-opacity":l.config.chart.selection.stroke.opacity}),Y.setAttrs(n.node,h))}}hideSelectionRect(e){e&&e.attr({x:0,y:0,width:0,height:0})}selectionDrawing({context:e,zoomtype:t}){var i;let s=this.w,a=null==(i=this.gridRect)?void 0:i.getBoundingClientRect();if(!a)return;let r=e.startX-1,l=e.startY,o=!1,n=!1,h=e.clientX-a.left-s.globals.barPadForNumericAxis,g=e.clientY-a.top,p=h-r,x=g-l,u={translateX:s.layout.translateX,translateY:s.layout.translateY};return Math.abs(p+r)>s.layout.gridWidth?p=s.layout.gridWidth-r:h<0&&(p=r),r>h&&(o=!0,p=Math.abs(p)),l>g&&(n=!0,x=Math.abs(x)),u=c(d({},u="x"===t?{x:o?r-p:r,y:0,width:p,height:s.layout.gridHeight}:"y"===t?{x:0,y:n?l-x:l,width:s.layout.gridWidth,height:x}:{x:o?r-p:r,y:n?l-x:l,width:p,height:x}),{translateX:s.layout.translateX,translateY:s.layout.translateY}),e.drawSelectionRect(u),e.selectionDragging("resizing"),u}selectionDragging(e,t){var i;let s=this.w;if(!t)return;t.preventDefault();let{handler:a,box:r}=t.detail,l=this.constraints,{x:o,y:n}=r;o<l.x&&(o=l.x),n<l.y&&(n=l.y),r.x2>l.x2&&(o=l.x2-r.w),r.y2>l.y2&&(n=l.y2-r.h),a.move(o,n);let h=this.xyRatios,d=this.selectionRect,c=0;"resizing"===e&&(c=30);let g=e=>parseFloat(d.node.getAttribute(e)),p={x:g("x"),y:g("y"),width:g("width"),height:g("height")};s.interact.selection=p,"function"==typeof s.config.chart.events.selection&&s.interact.selectionEnabled&&(clearTimeout(null!=(i=this.w.globals.selectionResizeTimer)?i:void 0),this.w.globals.selectionResizeTimer=window.setTimeout(()=>{var e;let t,i,a,r,l=null==(e=this.gridRect)?void 0:e.getBoundingClientRect();if(!l)return;let o=d.node.getBoundingClientRect();if(s.axisFlags.isRangeBar)t=s.globals.yAxisScale[0].niceMin+(o.left-l.left)*h.invertedYRatio,i=s.globals.yAxisScale[0].niceMin+(o.right-l.left)*h.invertedYRatio,a=0,r=1;else{if(!s.globals.xAxisScale)return;t=s.globals.xAxisScale.niceMin+(o.left-l.left)*h.xRatio,i=s.globals.xAxisScale.niceMin+(o.right-l.left)*h.xRatio,a=s.globals.yAxisScale[0].niceMin+(l.bottom-o.bottom)*h.yRatio[0],r=s.globals.yAxisScale[0].niceMax-(o.top-l.top)*h.yRatio[0]}let n={xaxis:{min:t,max:i},yaxis:{min:a,max:r}};s.config.chart.events.selection(this.ctx,n),s.config.chart.brush.enabled&&void 0!==s.config.chart.events.brushScrolled&&s.c
903onfig.chart.events.brushScrolled(this.ctx,n)},c))}selectionDrawn({context:e,zoomtype:t}){var i,s;let a,r,l=this.w,o=this.xyRatios,n=this.ctx.toolbar,h=l.interact.zoomEnabled?e.zoomRect.node.getBoundingClientRect():e.selectionRect.node.getBoundingClientRect(),d=e.gridRect.getBoundingClientRect(),c=h.left-d.left-l.globals.barPadForNumericAxis,g=h.right-d.left-l.globals.barPadForNumericAxis,p=h.top-d.top,x=h.bottom-d.top;if(l.axisFlags.isRangeBar)a=l.globals.yAxisScale[0].niceMin+c*o.invertedYRatio,r=l.globals.yAxisScale[0].niceMin+g*o.invertedYRatio;else{let e=null!=(s=null==(i=l.globals.xAxisScale)?void 0:i.niceMin)?s:0;a=e+c*o.xRatio,r=e+g*o.xRatio}let u=[],f=[];if(l.config.yaxis.forEach((e,t)=>{let i=l.globals.seriesYAxisMap[t][0],s=l.globals.yAxisScale[t].niceMax-o.yRatio[i]*p,a=l.globals.yAxisScale[t].niceMax-o.yRatio[i]*x;u.push(s),f.push(a)}),e.dragged&&(e.dragX>10||e.dragY>10)&&a!==r){if(l.interact.zoomEnabled){if(!l.globals.initialConfig)return;let i=v.clone(l.globals.initialConfig.yaxis),s=v.clone(l.globals.initialConfig.xaxis);if(l.interact.zoomed=!0,l.config.xaxis.convertedCatToNumeric&&(a=Math.floor(a),r=Math.floor(r),a<1&&(a=1,r=l.globals.dataPoints),r-a<2&&(r=a+1)),("xy"===t||"x"===t)&&(s={min:a,max:r}),("xy"===t||"y"===t)&&i.forEach((e,t)=>{i[t].min=f[t],i[t].max=u[t]}),n){let e=n.getBeforeZoomRange(s,i);e&&(s=e.xaxis?e.xaxis:s,i=e.yaxis?e.yaxis:i)}let o={xaxis:s};l.config.chart.group||(o.yaxis=i),e.ctx.updateHelpers._updateOptions(o,!1,e.w.config.chart.animations.dynamicAnimation.enabled),"function"==typeof l.config.chart.events.zoomed&&n.zoomCallback(s,i)}else if(l.interact.selectionEnabled){let i=null,s=null;if(s={min:a,max:r},"xy"===t||"y"===t){let e=v.clone(l.config.yaxis);i=e,e.forEach((t,i)=>{e[i].min=f[i],e[i].max=u[i]})}l.interact.selection=e.selection,"function"==typeof l.config.chart.events.selection&&l.config.chart.events.selection(e.ctx,{xaxis:s,yaxis:i})}}}panDragging({context:e}){var t;let i=this.w;if(void 0!==i.interact.lastClientPosition.x){let s=i.interact.lastClientPosition.x-e.clientX,a=(null!=(t=i.interact.lastClientPosition.y)?t:0)-e.clientY;Math.abs(s)>Math.abs(a)&&s>0?this.moveDirection="left":Math.abs(s)>Math.abs(a)&&s<0?this.moveDirection="right":Math.abs(a)>Math.abs(s)&&a>0?this.moveDirection="up":Math.abs(a)>Math.abs(s)&&a<0&&(this.moveDirection="down")}i.interact.lastClientPosition={x:e.clientX,y:e.clientY};let s=i.axisFlags.isRangeBar?i.globals.minY:i.globals.minX,a=i.axisFlags.isRangeBar?i.globals.maxY:i.globals.maxX;e.panScrolled(s,a)}panScrolled(e,t){let i=this.w,s=this.xyRatios;if(!i.globals.initialConfig)return;let a=v.clone(i.globals.initialConfig.yaxis),r=s.xRatio,l=i.globals.minX,o=i.globals.maxX;i.axisFlags.isRangeBar&&(r=s.invertedYRatio,l=i.globals.minY,o=i.globals.maxY),"left"===this.moveDirection?(e=l+i.layout.gridWidth/15*r,t=o+i.layout.gridWidth/15*r):"right"===this.moveDirection&&(e=l-i.layout.gridWidth/15*r,t=o-i.layout.gridWidth/15*r),!i.axisFlags.isRangeBar&&(e<i.globals.initialMinX||t>i.globals.initialMaxX)&&(e=l,t=o);let n={xaxis:{min:e,max:t}};i.config.chart.group||(n.yaxis=a),this.updateScrolledChart(n,e,t)}updateScrolledChart(e,t,i){let s=this.w;if(this.ctx.updateHelpers._updateOptions(e,!1,!1),"function"==typeof s.config.chart.events.scrolled){let e={xaxis:{min:t,max:i}};s.config.chart.events.scrolled(this.ctx,e),this.ctx.events.fireEvent("scrolled",e)}}}eJ.registerFeatures({toolbar:e5,zoomPanSelection:e3});let e4=class{constructor(e){this.w=e.w,this.annoCtx=e}setOrientations(e,t=null){var i,s;let a=this.w;if("vertical"===e.label.orientation){let r=a.dom.baseEl.querySelector(`.apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='${null!==t?t:0}']`);if(null!==r){let t=r.getBBox();r.setAttribute("x",String(parseFloat(null!=(i=r.getAttribute("x"))?i:"0")-t.height+4));let a="top"===e.label.position?t.width:-t.width;r.setAttribute("y",String(parseFloat(null!=(s=r.getAttribute("y"))?s:"0")+a));let{x:l,y:o}=this.annoCtx.graphics.rotateAroundCenter(r);r.setAttribute("transform",`rotate(-90 ${l} ${o})`)}}}addBackgroundToAnno(e,t){let i=this.w;if(!e||!t.label.text||!String(t.label.text).trim())return null;let s=i.dom.baseEl.querySelector(".apexcharts-grid");if(!s)return null;let a=s.getBoundingClientRect(),r=s.getBBox(),l=a.width/r.width||1,o=e.getBoundingClientRect(),{left:n,right:h,top:d,bottom:c}=t.label.style.padding;"vertical"===t.label.orientation&&([d,c,n,h]=[n,h,d,c]);let g=(o.left-a.left)/l-n,p=(o.top-a.top)/l-d,x=this.annoCtx.graphics.drawRect(g-i.globals.barPadForNumericAxis,p,o.width/l+n+h,o.height/l+d+c,t.label.borderRadius,t.label.style.background,1,t.label.borderWidth,t.label.borderColor,0);return t.id&&x.node.classList.add(t.id),x}
903annotationsBackground(){let e=this.w,t=(t,i,s)=>{let a=e.dom.baseEl.querySelector(`.apexcharts-${s}-annotations .apexcharts-${s}-annotation-label[rel='${i}']`);if(a){let e=a.parentNode,i=this.addBackgroundToAnno(a,t);i&&(null==e||e.insertBefore(i.node,a),t.label.mouseEnter&&i.node.addEventListener("mouseenter",t.label.mouseEnter.bind(this,t)),t.label.mouseLeave&&i.node.addEventListener("mouseleave",t.label.mouseLeave.bind(this,t)),t.label.click&&i.node.addEventListener("click",t.label.click.bind(this,t)))}};e.config.annotations.xaxis.forEach((e,i)=>t(e,i,"xaxis")),e.config.annotations.yaxis.forEach((e,i)=>t(e,i,"yaxis")),e.config.annotations.points.forEach((e,i)=>t(e,i,"point"))}getY1Y2(e,t){var i,s;let a,r=this.w,l="y1"===e?t.y:t.y2,o=!1;if(this.annoCtx.invertAxis){let e=r.config.xaxis.convertedCatToNumeric?r.labelData.categoryLabels:r.labelData.labels,s=e.indexOf(l),o=r.dom.baseEl.querySelector(`.apexcharts-yaxis-texts-g text:nth-child(${s+1})`);a=o?parseFloat(null!=(i=o.getAttribute("y"))?i:"0"):(r.layout.gridHeight/e.length-1)*(s+1)-r.globals.barHeight,void 0!==t.seriesIndex&&r.globals.barHeight&&(a-=r.globals.barHeight/2*(r.seriesData.series.length-1)-r.globals.barHeight*t.seriesIndex)}else{let e=r.globals.seriesYAxisMap[t.yAxisIndex][0],i=r.config.yaxis[t.yAxisIndex].logarithmic?new I(this.w).getLogVal(r.config.yaxis[t.yAxisIndex].logBase,l,e)/r.globals.yLogRatio[e]:(l-r.globals.minYArr[e])/(r.globals.yRange[e]/r.layout.gridHeight);a=r.layout.gridHeight-Math.min(Math.max(i,0),r.layout.gridHeight),o=i>r.layout.gridHeight||i<0,t.marker&&(void 0===t.y||null===t.y)&&(a=0),(null==(s=r.config.yaxis[t.yAxisIndex])?void 0:s.reversed)&&(a=i)}return"string"==typeof l&&l.includes("px")&&(a=parseFloat(l)),{yP:a,clipped:o}}getX1X2(e,t){let i=this.w,s="x1"===e?t.x:t.x2,a=this.annoCtx.invertAxis?i.globals.minY:i.globals.minX,r=this.annoCtx.invertAxis?i.globals.maxY:i.globals.maxX,l=this.annoCtx.invertAxis?i.globals.yRange[0]:i.globals.xRange,o=!1,n=this.annoCtx.inversedReversedAxis?(r-s)/(l/i.layout.gridWidth):(s-a)/(l/i.layout.gridWidth);return"category"!==i.config.xaxis.type&&!i.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||i.axisFlags.dataFormatXNumeric||i.config.chart.sparkline.enabled||(n=this.getStringX(s)),"string"==typeof s&&s.includes("px")&&(n=parseFloat(s)),null==s&&t.marker&&(n=i.layout.gridWidth),void 0!==t.seriesIndex&&i.globals.barWidth&&!this.annoCtx.invertAxis&&(n-=i.globals.barWidth/2*(i.seriesData.series.length-1)-i.globals.barWidth*t.seriesIndex),"number"!=typeof n&&(n=0,o=!0),parseFloat(n.toFixed(10))>parseFloat(i.layout.gridWidth.toFixed(10))?(n=i.layout.gridWidth,o=!0):n<0&&(n=0,o=!0),{x:n,clipped:o}}getStringX(e){var t;let i=this.w,s=e;if(i.config.xaxis.convertedCatToNumeric&&i.labelData.categoryLabels.length){let t=String(e);e=i.labelData.categoryLabels.findIndex(e=>String(e)===t)+1}let a=i.labelData.labels.map(e=>Array.isArray(e)?e.join(" "):e).indexOf(e),r=i.dom.baseEl.querySelector(`.apexcharts-xaxis-texts-g text:nth-child(${a+1})`);return r&&(s=parseFloat(null!=(t=r.getAttribute("x"))?t:"0")),s}};class e6{constructor(e){this.w=e.w,this.annoCtx=e,this.invertAxis=this.annoCtx.invertAxis,this.helpers=new e4(this.annoCtx)}addXaxisAnnotation(e,t,i){let s,a=this.w,r=this.helpers.getX1X2("x1",e),l=r.x,o=r.clipped,n=!0,h=e.label.text,d=e.strokeDashArray;if(v.isNumber(l)){if(null===e.x2||void 0===e.x2){if(!o){let i=this.annoCtx.graphics.drawLine(l+e.offsetX,0+e.offsetY,l+e.offsetX,a.layout.gridHeight+e.offsetY,e.borderColor,d,e.borderWidth);t.appendChild(i.node),e.id&&i.node.classList.add(e.id)}}else{let i=this.helpers.getX1X2("x2",e);if(s=i.x,n=i.clipped,s<l){let e=l;l=s,s=e}let r=this.annoCtx.graphics.drawRect(l+e.offsetX,0+e.offsetY,s-l,a.layout.gridHeight+e.offsetY,0,e.fillColor,e.opacity,1,e.borderColor,d);r.node.classList.add("apexcharts-annotation-rect"),r.attr("clip-path",`url(#gridRectMask${a.globals.cuid})`),t.appendChild(r.node),e.id&&r.node.classList.add(e.id)}if(!(o&&n)){let s=this.annoCtx.graphics.getTextRects(h,e.label.style.fontSize),r="top"===e.label.position?4:"center"===e.label.position?a.layout.gridHeight/2+("vertical"===e.label.orientation?s.width/2:0):a.layout.gridHeight,o=this.annoCtx.graphics.drawText({x:l+e.label.offsetX,y:r+e.label.offsetY-("vertical"===e.label.orientation?"top"===e.label.position?s.width/2-12:-s.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 ${e.label.style.cssClass} ${e.id?e.id:""}`});o.attr({rel:i}),t.appendChild(o.node),this.annoCtx.helpers.setOrientations(e,i)}}}drawXAxisAnnotations(){let e=this.w,t=this.annoCtx.graphics.group({class:"apexcharts-xaxis-annotations"});return e.config.annotations.xaxis.map((e,i)=>{this.addXaxisAnnotation(e,t.node,i)}),t}}class e9{constructor(e){this.w=e.w,this.annoCtx=e,this.helpers=new e4(this.annoCtx),this.axesUtils=new j(this.annoCtx.w,{theme:this.annoCtx.theme,timeScale:this.annoCtx.timeScale})}addYaxisAnnotation(e,t,i){let s,a=this.w,r=e.strokeDashArray,l=this.helpers.getY1Y2("y1",e),o=l.yP,n=l.clipped,h=!0,d=!1,c=e.label.text;if(null===e.y2||void 0===e.y2){if(!n){d=!0;let i=this.annoCtx.graphics.drawLine(0+e.offsetX,o+e.offsetY,this._getYAxisAnnotationWidth(e),o+e.offsetY,e.borderColor,r,e.borderWidth);t.appendChild(i.node),e.id&&i.node.classList.add(e.id)}}else{if(s=(l=this.helpers.getY1Y2("y2",e)).yP,h=l.clipped,s>o){let e=o;o=s,s=e}if(!(n&&h)){d=!0;let i=this.annoCtx.graphics.drawRect(0+e.offsetX,s+e.offsetY,this._getYAxisAnnotationWidth(e),o-s,0,e.fillColor,e.opacity,1,e.borderColor,r);i.node.classList.add("apexcharts-annotation-rect"),i.attr("clip-path",`url(#gridRectMask${a.globals.cuid})`),t.appendChild(i.node),e.id&&i.node.classList.add(e.id)}}if(d){let r="right"===e.label.position?a.layout.gridWidth:"center"===e.label.position?a.layout.gridWidth/2:0,l=this.annoCtx.graphics.drawText({x:r+e.label.offsetX,y:(null!=s?s:o)+e.label.offsetY-3,text:c,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 ${e.label.style.cssClass} ${e.id?e.id:""}`});l.attr({rel:i}),t.appendChild(l.node)}}_getYAxisAnnotationWidth(e){let t=this.w,i=t.layout.gridWidth;return(e.width.indexOf("%")>-1?t.layout.gridWidth*parseInt(e.width,10)/100:parseInt(e.width,10))+e.offsetX}drawYAxisAnnotations(){let e=this.w,t=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return e.config.annotations.yaxis.forEach((e,i)=>{e.yAxisIndex=this.axesUtils.translateYAxisIndex(e.yAxisIndex),this.axesUtils.isYAxisHidden(e.yAxisIndex)&&this.axesUtils.yAxisAllSeriesCollapsed(e.yAxisIndex)||this.addYaxisAnnotation(e,t.node,i)}),t}}class e8{constructor(e){this.w=e.w,this.annoCtx=e,this.helpers=new e4(this.annoCtx)}addPointAnnotation(e,t,i){if(this.w.globals.collapsedSeriesIndices.indexOf(e.seriesIndex)>-1)return;let s=this.helpers.getX1X2("x1",e),a=s.x,r=s.clipped,l=this.helpers.getY1Y2("y1",e),o=l.yP,n=l.clipped;if(v.isNumber(a)&&!(n||r)){let s={pSize:e.marker.size,pointStrokeWidth:e.marker.strokeWidth,pointFillColor:e.marker.fillColor,pointStrokeColor:e.marker.strokeColor,shape:e.marker.shape,pRadius:e.marker.radiu
903s,class:`apexcharts-point-annotation-marker ${e.marker.cssClass} ${e.id?e.id:""}`},r=this.annoCtx.graphics.drawMarker(a+e.marker.offsetX,o+e.marker.offsetY,s);t.appendChild(r.node);let l=e.label.text?e.label.text:"",n=this.annoCtx.graphics.drawText({x:a+e.label.offsetX,y:o+e.label.offsetY-e.marker.size-parseFloat(e.label.style.fontSize)/1.6,text:l,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 ${e.label.style.cssClass} ${e.id?e.id:""}`});if(n.attr({rel:i}),t.appendChild(n.node),e.customSVG.SVG){let i=this.annoCtx.graphics.group({class:"apexcharts-point-annotations-custom-svg "+e.customSVG.cssClass});i.attr({transform:`translate(${a+e.customSVG.offsetX}, ${o+e.customSVG.offsetY})`}),i.node.innerHTML=e.customSVG.SVG,t.appendChild(i.node)}if(e.image.path){let t=e.image.width?e.image.width:20,i=e.image.height?e.image.height:20;r=this.annoCtx.addImage({x:a+e.image.offsetX-t/2,y:o+e.image.offsetY-i/2,width:t,height:i,path:e.image.path,appendTo:".apexcharts-point-annotations"})}e.mouseEnter&&r.node.addEventListener("mouseenter",e.mouseEnter.bind(this,e)),e.mouseLeave&&r.node.addEventListener("mouseleave",e.mouseLeave.bind(this,e)),e.click&&r.node.addEventListener("click",e.click.bind(this,e))}}drawPointAnnotations(){let e=this.w,t=this.annoCtx.graphics.group({class:"apexcharts-point-annotations"});return e.config.annotations.points.map((e,i)=>{this.addPointAnnotation(e,t.node,i)}),t}}class e7{constructor(e,{theme:t=null,timeScale:i=null}={}){this.w=e,this.theme=t,this.timeScale=i,this.invertAxis=void 0,this.inversedReversedAxis=void 0,this.graphics=new Y(this.w),this.w.globals.isBarHorizontal&&(this.invertAxis=!0),this.helpers=new e4(this),this.xAxisAnnotations=new e6(this),this.yAxisAnnotations=new e9(this),this.pointsAnnotations=new e8(this),this.w.globals.isBarHorizontal&&this.w.config.yaxis[0].reversed&&(this.inversedReversedAxis=!0),this.xDivision=this.w.layout.gridWidth/this.w.globals.dataPoints}drawAxesAnnotations(){let e=this.w;if(e.globals.axisCharts&&e.globals.dataPoints){let t=this.yAxisAnnotations.drawYAxisAnnotations(),i=this.xAxisAnnotations.drawXAxisAnnotations(),s=this.pointsAnnotations.drawPointAnnotations(),a=e.config.chart.animations.enabled,r=[t,i,s],l=[i.node,t.node,s.node];for(let t=0;t<3;t++)e.dom.elGraphical.add(r[t]),a&&!e.globals.resized&&!e.globals.dataChanged&&"scatter"!==e.config.chart.type&&"bubble"!==e.config.chart.type&&e.globals.dataPoints>1&&l[t].classList.add("apexcharts-element-hidden"),e.globals.delayedElements.push({el:l[t],index:0});this.helpers.annotationsBackground()}}drawImageAnnos(){this.w.config.annotations.images.map(e=>{this.addImage(e)})}drawTextAnnos(){this.w.config.annotations.texts.map(e=>{this.addText(e)})}addXaxisAnnotation(e,t,i){this.xAxisAnnotations.addXaxisAnnotation(e,t,i)}addYaxisAnnotation(e,t,i){this.yAxisAnnotations.addYaxisAnnotation(e,t,i)}addPointAnnotation(e,t,i){this.pointsAnnotations.addPointAnnotation(e,t,i)}addText(e){let{x:t,y:i,text:s,textAnchor:a,foreColor:r,fontSize:l,fontFamily:o,fontWeight:n,cssClass:h,backgroundColor:d,borderWidth:c,strokeDashArray:g,borderRadius:p,borderColor:x,appendTo:u=".apexcharts-svg",paddingLeft:f=4,paddingRight:m=4,paddingBottom:b=2,paddingTop:y=2}=e,w=this.w,v=this.graphics.drawText({x:t,y:i,text:s,textAnchor:a||"start",fontSize:l||"12px",fontWeight:n||"regular",fontFamily:o||w.config.chart.fontFamily,foreColor:r||w.config.chart.foreColor,cssClass:h}),A=w.dom.baseEl.querySelector(u);A&&A.appendChild(v.node);let C=v.bbox();if(s){let e=this.graphics.drawRect(C.x-f,C.y-y,C.width+f+m,C.height+b+y,p,d||"transparent",1,c,x,g);A.insertBefore(e.node,v.node)}}addImage(e){let t=this.w,{path:i,x:s=0,y:a=0,width:r=20,height:l=20,appendTo:o=".apexcharts-svg"}=e,n=t.dom.Paper.image(i);n.size(r,l).move(s,a);let h=t.dom.baseEl.querySelector(o);return h&&h.appendChild(n.node),n}addXaxisAnnotationExternal(e,t,i){return this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"xaxis",contextMethod:i.addXaxisAnnotation}),i}addYaxisAnnotationExternal(e,t,i){return this.addAnnotationExternal({params:e,pushToMemory:t,context:i,type:"yaxis",contextMethod:i.addYaxisAnnotation}),i}addPointAnnotationExternal(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}addAnnotationExternal({params:e,pushToMemory:t,context:i,type:s,contextMethod:a}){let r=i.w,l=r.dom.baseEl.querySelector(`.apexcharts-${s}-annotations`),o=l.childNodes.length+1,n=new M,h=Object.assign({},"xaxis"===s?n.xAxisAnnotation:"yaxis"===s?n.yAxisAnnotation:n.pointAnnotation),d=v.extend(h,e);switch(s){case"xaxis":this.addXaxisAnnotation(d,l,o);break;
903case"yaxis":this.addYaxisAnnotation(d,l,o);break;case"point":this.addPointAnnotation(d,l,o)}let c=r.dom.baseEl.querySelector(`.apexcharts-${s}-annotations .apexcharts-${s}-annotation-label[rel='${o}']`),g=this.helpers.addBackgroundToAnno(c,d);return g&&l.insertBefore(g.node,c),t&&r.globals.memory.methodsToExec.push({context:i,id:d.id?d.id:v.randomId(),method:a,label:"addAnnotation",params:e}),i}clearAnnotations(e){let t=e.w,i=t.dom.baseEl.querySelectorAll(".apexcharts-yaxis-annotations, .apexcharts-xaxis-annotations, .apexcharts-point-annotations");for(let e=t.globals.memory.methodsToExec.length-1;e>=0;e--)("addText"===t.globals.memory.methodsToExec[e].label||"addAnnotation"===t.globals.memory.methodsToExec[e].label)&&t.globals.memory.methodsToExec.splice(e,1);Array.prototype.forEach.call(i,e=>{for(;e.firstChild;)e.removeChild(e.firstChild)})}removeAnnotation(e,t){let i=e.w,s=i.dom.baseEl.querySelectorAll(`.${t}`);s&&(i.globals.memory.methodsToExec.map((e,s)=>{e.id===t&&i.globals.memory.methodsToExec.splice(s,1)}),Object.keys(i.config.annotations).forEach(e=>{let s=i.config.annotations[e];Array.isArray(s)&&(i.config.annotations[e]=s.filter(e=>e.id!==t))}),Array.prototype.forEach.call(s,e=>{e.parentElement.removeChild(e)}))}}eJ.registerFeatures({annotations:e7});class te{constructor(e,t){this.w=e,this.ctx=t,this.seriesIndex=0,this.dataPointIndex=0,this.active=!1,this._tooltipDismissed=!1,this._focusedEl=null,this._hoveredBarEl=null,this._enlargedScatterMarker=null,this._onKeyDown=this._onKeyDown.bind(this),this._onFocus=this._onFocus.bind(this),this._onBlur=this._onBlur.bind(this),this._onLegendClick=this._onLegendClick.bind(this)}init(){let e=this.w.dom.Paper.node;e&&(e.setAttribute("tabindex","0"),e.addEventListener("focus",this._onFocus),e.addEventListener("blur",this._onBlur),e.addEventListener("keydown",this._onKeyDown,{passive:!1}),this.ctx.events.addEventListener("legendClick",this._onLegendClick))}destroy(){let e=this.w,t=e.dom.Paper&&e.dom.Paper.node;t&&(t.removeEventListener("focus",this._onFocus),t.removeEventListener("blur",this._onBlur),t.removeEventListener("keydown",this._onKeyDown),this.ctx.events.removeEventListener("legendClick",this._onLegendClick))}handleKey(e){}_onFocus(){this._isNavEnabled()&&(this.active=!0,this._clampCursor(),this._snapToVisibleRange(),this._showCurrentPoint())}_onBlur(){this.active=!1,this._tooltipDismissed=!1,this._hideFocus()}_onLegendClick(){this.active&&(this.active=!1,this._hideFocus())}_onKeyDown(e){var t,i,s;if(this._isNavEnabled()&&this.active){if(e.shiftKey&&("ArrowRight"===e.key||"ArrowLeft"===e.key)&&this._canPan()){e.preventDefault(),this._panBy("ArrowRight"===e.key?1:-1);return}switch(e.key){case"ArrowRight":e.preventDefault(),this._move(0,1);break;case"ArrowLeft":e.preventDefault(),this._move(0,-1);break;case"ArrowUp":e.preventDefault(),this._move(-1,0);break;case"ArrowDown":e.preventDefault(),this._move(1,0);break;case"Home":e.preventDefault(),this.dataPointIndex=0,this._skipNullForward(),this._showCurrentPoint();break;case"End":e.preventDefault(),this.dataPointIndex=this._getDataPointCount(this.seriesIndex)-1,this._skipNullBackward(),this._showCurrentPoint();break;case"Enter":case" ":e.preventDefault(),this._fireClick();break;case"+":case"=":this._canZoom()&&(e.preventDefault(),null==(t=this.ctx.toolbar)||t.handleZoomIn(),this._announce("Zoomed in"));break;case"-":case"_":this._canZoom()&&(e.preventDefault(),null==(i=this.ctx.toolbar)||i.handleZoomOut(),this._announce("Zoomed out"));break;case"0":this._canZoom()&&this.w.interact.zoomed&&(e.preventDefault(),null==(s=this.ctx.toolbar)||s.handleZoomReset(),this._announce("Zoom reset"));break;case"Escape":e.preventDefault(),this._tooltipDismissed?(this.active=!1,this._tooltipDismissed=!1):this._tooltipDismissed=!0,this._hideFocus()}}}_canZoom(){let e=this.w;return!!(e.globals.axisCharts&&e.config.chart.zoom&&e.config.chart.zoom.enabled)}_canPan(){return this._canZoom()}_panBy(e){let t=this.w,i=this.ctx.toolbar;if(!i)return;let s=Number(t.globals.minX),a=Number(t.globals.maxX);if(!isFinite(s)||!isFinite(a)||s===a)return;let r=.1*(a-s)*e;i.zoomUpdateOptions(s+r,a+r),this._announce(e>0?"Panned right":"Panned left")}_move(e,t){let i=this.w,s=i.config.chart.accessibility.keyboard.navigation.wrapAround;if(0!==e){let t=this.w.globals.tooltip;if(t&&t.tConfig&&t.tConfig.shared){let e=this.dataPointIndex;if(t.tooltipUtil&&t.tooltipUtil.isXoverlap(e)&&t.tooltipUtil.isInitialSeriesSameLen())return}let a=this._getSeriesCount(),r=this.seriesIndex+e,l=0;for(;
903l<a&&(r<0&&(r=s?a-1:0),r>=a&&(r=s?0:a-1),i.globals.collapsedSeriesIndices.includes(r));)r+=e,l++;this.seriesIndex=r;let o=this._getDataPointCount(r);this.dataPointIndex>=o&&(this.dataPointIndex=o-1)}if(0!==t){let e=this._getDataPointCount(this.seriesIndex),i=this.dataPointIndex+t;i<0&&(i=s?e-1:0),i>=e&&(i=s?0:e-1),this.dataPointIndex=i,t>0?this._skipNullForward():this._skipNullBackward(),this._isDataPointVisible(this.seriesIndex,this.dataPointIndex)||this._snapToVisibleRangeInDirection(t)}this._showCurrentPoint()}_skipNullForward(){let e=this.w,t=this.seriesIndex,i=this._getDataPointCount(t),s=this.dataPointIndex,a=0;if(Array.isArray(e.seriesData.series[t])){for(;a<i&&null===e.seriesData.series[t][s];)s=(s+1)%i,a++;this.dataPointIndex=s}}_skipNullBackward(){let e=this.w,t=this.seriesIndex,i=this._getDataPointCount(t),s=this.dataPointIndex,a=0;if(Array.isArray(e.seriesData.series[t])){for(;a<i&&null===e.seriesData.series[t][s];)s=(s-1+i)%i,a++;this.dataPointIndex=s}}_showCurrentPoint(){let{seriesIndex:e,dataPointIndex:t}=this,i=this.w,s=i.globals.tooltip;s&&s.ttItems&&(i.interact.capturedSeriesIndex=e,i.interact.capturedDataPointIndex=t,this._applyFocusClass(e,t),this._showTooltip(e,t,s))}_hideFocus(){let e=this.w,t=e.globals.tooltip;if(this._removeFocusClass(),this._leaveHoveredBar(),!t)return;t.marker&&t.marker.resetPointsSize(),this._enlargedScatterMarker=null;let i=t.getElTooltip();i&&(i.classList.remove("apexcharts-active"),e.config.chart.accessibility.enabled&&e.config.chart.accessibility.announcements.enabled&&i.setAttribute("aria-hidden","true")),e.dom.baseEl.classList.remove("apexcharts-tooltip-active");let s=t.getElXCrosshairs();s&&s.classList.remove("apexcharts-active")}_showTooltip(e,t,i){let s=this.w,a=s.config.chart.type,r=i.getElTooltip();if(!r)return;let l=i.getCachedDimensions();i.tooltipRect={x:0,y:0,ttWidth:l.ttWidth||0,ttHeight:l.ttHeight||0},this._setSyntheticEvent(e,t,i),s.dom.baseEl.classList.add("apexcharts-tooltip-active"),r.classList.add("apexcharts-active"),s.config.chart.accessibility.enabled&&s.config.chart.accessibility.announcements.enabled&&r.removeAttribute("aria-hidden"),"pie"===a||"donut"===a||"polarArea"===a?this._showTooltipNonAxis(e,t,i,r):"radialBar"===a?this._showTooltipRadialBar(e,t,i,r):"heatmap"===a||"treemap"===a?this._showTooltipHeatTree(e,t,i,r,a):"bar"===a||"candlestick"===a||"boxPlot"===a||"rangeBar"===a?this._showTooltipBar(e,t,i):this._showTooltipAxisLine(e,t,i)}_setSyntheticEvent(e,t,i){let s=this.w,a=s.config.chart.type,r=0,l=0,o=this._getFocusableElement(e,t);if(o){let e=o.getBoundingClientRect();r=e.left+e.width/2,l=e.top+e.height/2}else if(s.globals.pointsArray&&s.globals.pointsArray[e]&&s.globals.pointsArray[e][t]){let a=s.globals.pointsArray[e][t],o=i.getElGrid&&i.getElGrid();if(o){let e=o.getBoundingClientRect();r=e.left+(a[0]||0),l=e.top+(a[1]||0)}}else{let e=s.dom.Paper&&s.dom.Paper.node;if(e){let t=e.getBoundingClientRect();r=t.left+t.width/2,l=t.top+t.height/2}}if(("line"===a||"area"===a||"rangeArea"===a||"scatter"===a||"bubble"===a||"radar"===a)&&s.globals.pointsArray&&s.globals.pointsArray[e]&&s.globals.pointsArray[e][t]){let a=s.globals.pointsArray[e][t],o=i.getElGrid&&i.getElGrid();if(o){let e=o.getBoundingClientRect();r=e.left+(a[0]||0),l=e.top+(a[1]||0)}}i.e={type:"mousemove",clientX:r,clientY:l}}_showTooltipBar(e,t,i){var s,a,r,l;let o=this.w,n=i.tConfig.shared&&(i.tooltipUtil.isXoverlap(t)||o.globals.isBarHorizontal)&&i.tooltipUtil.isInitialSeriesSameLen(),h=null==(l=null==(r=null==(a=null==(s=o.rangeData.seriesRange)?void 0:s[e])?void 0:a[t])?void 0:r.y)?void 0:l[0];i.tooltipLabels.drawSeriesTexts(c(d(d({ttItems:i.ttItems,i:e,j:t},(null==h?void 0:h.y1)!==void 0&&{y1:h.y1}),(null==h?void 0:h.y2)!==void 0&&{y2:h.y2}),{shared:n}));let g=`.apexcharts-series[data\\:realIndex='${e}']`,p=o.dom.Paper.findOne(`${g} path[j='${t}'], ${g} circle[j='${t}'], ${g} rect[j='${t}']`);if(p&&(this._leaveHoveredBar(),new Y(this.w,this.ctx).pathMouseEnter(p,null),this._hoveredBarEl=p),o.globals.isBarHorizontal){let e=p&&p.node;if(e){let t=o.dom.elWrap.getBoundingClientRect(),s=e.getBoundingClientRect(),a=s.left-t.left,r=s.top-t.top,l=s.height,n=s.width,h=i.tooltipRect.ttWidth||0,d=i.tooltipRect.ttHeight||0,c=a+n;a<(i.xyRatios&&null!=i.xyRatios.baseLineInvertedY?i.xyRatios.baseLineInvertedY:t.width/2)&&(c=a-h);let g=i.getElTooltip();g&&(g.style.left=c+"px",g.style.top=r+l/2-d/2+"px")}}else i.tooltipPosition.moveStickyTooltipOverBars(t,e)}_showTooltipAxisLine(e,t,i){let s=this.w,a=s.config.chart.type,r=i.tConfig.shared&&i.tooltipUtil.isXoverlap(t)&&i.tooltipUtil.isInitialSeriesSameLen();i.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:e,j:t,shared:r});let l=s.globals.markers.largestSize>0;"scatter"===a||"bubble"===a?this._showScatterBubblePoint(e,t,i):l?r?i.marker.enlargePoints(t):i.tooltipPosition.moveDynamicPointOnHover(t,e):r?i.tooltipPosition.moveDynamicPointsOnHover(t):i.tooltipPosition.moveDynamicPointOnHover(t,e)}_showScatterBubblePoint(e,t,i){let s=this.w.dom.baseEl;this._enlargedScatterMarker&&(i.marker.oldPointSize(this._enlargedScatterMarker),this._enlargedScatterMarker=null);let a=s.querySelector(`.apexcharts-series[data\\:realIndex='${e}']`);if(!a)return;let r=a.querySelector(`.apexcharts-marker[rel='${t}']`);r&&(i.marker.enlargeCurrentPoint(t,r),this._enlargedScatterMarker=r)}_showTooltipNonAxis(e,t,i,s){var a,r;let l=this.w;i.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:t,shared:!1});let o=s.getBoundingClientRect(),n=o.width||i.tooltipRect.ttWidth||0,h=o.height||i.tooltipRect.ttHeight||0,d=l.dom.baseEl.querySelector(`.apexcharts-pie-area[j='${t}']`);if(d){let e=parseFloat(null!=(a=d.getAttribute("data:cx"))?a:""),t=parseFloat(null!=(r=d.getAttribute("data:cy"))?r:"");
903if(!isNaN(e)&&!isNaN(t)){let i=l.dom.Paper.node.getBoundingClientRect(),a=l.dom.elWrap.getBoundingClientRect(),r=i.left-a.left,o=i.top-a.top;s.style.left=r+e-n/2+"px",s.style.top=o+t-h-10+"px"}}}_showTooltipRadialBar(e,t,i,s){var a;let r=this.w;i.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:e,shared:!1});let{ttWidth:l=0,ttHeight:o=0}=i.getCachedDimensions(),n=r.dom.baseEl.querySelector(`.apexcharts-radialbar-series[data\\:realIndex='${e}'] path`);if(n){let t=parseFloat(null!=(a=n.getAttribute("data:angle"))?a:"")||0,i=r.config.plotOptions.radialBar.startAngle||0,h=r.layout.gridWidth/2,d=r.layout.gridHeight/2,c=r.globals.radialSize||Math.min(r.layout.gridWidth,r.layout.gridHeight)/2,g=c/Math.max(r.seriesData.series.length,1),p=c-e*g,x=v.polarToCartesian(h,d,(p+(p-g))/2,i+t/2),u=x.x+(r.layout.translateX||0),f=x.y+(r.layout.translateY||0);s.style.left=u-l/2+"px",s.style.top=f-o-10+"px"}}_showTooltipHeatTree(e,t,i,s,a){var r,l;let o=this.w;i.tooltipLabels.drawSeriesTexts({ttItems:i.ttItems,i:e,j:t,shared:!1});let n=s.getBoundingClientRect(),h=n.width||i.tooltipRect.ttWidth||0,d=n.height||i.tooltipRect.ttHeight||0,c=o.dom.baseEl.querySelector(`.${"heatmap"===a?"apexcharts-heatmap-rect":"apexcharts-treemap-rect"}[i='${e}'][j='${t}']`);if(c){let e=o.dom.elWrap.getBoundingClientRect(),t=c.getBoundingClientRect(),a=t.left-e.left,n=t.top-e.top,g=t.width,p=t.height,x=parseFloat(null!=(r=c.getAttribute("cx"))?r:""),u=parseFloat(null!=(l=c.getAttribute("width"))?l:"");i.tooltipPosition.moveXCrosshairs(x+u/2);let f=a+g+h/2;a+g>o.layout.gridWidth/2&&(f=a-h/2),s.style.left=f+"px",s.style.top=n+p/2-d/2+"px"}}_applyFocusClass(e,t){this._removeFocusClass();let i=this._getFocusableElement(e,t);if(i){i.classList.add("apexcharts-keyboard-focused"),i.setAttribute("role","img");let s=this._buildPointLabel(e,t);s&&i.setAttribute("aria-label",s),this._focusedEl=i}}_removeFocusClass(){this._focusedEl&&(this._focusedEl.classList.remove("apexcharts-keyboard-focused"),this._focusedEl.removeAttribute("role"),this._focusedEl.removeAttribute("aria-label"),this._focusedEl=null)}_buildPointLabel(e,t){var i,s,a,r,l,o,n,h;let d=this.w,c=d.config.chart.type,g=d.seriesData.seriesNames||[],p=d.seriesData.series||[];if("pie"===c||"donut"===c||"polarArea"===c){let e=null!=(s=(null==(i=d.labelData)?void 0:i.labels)&&d.labelData.labels[t])?s:"",a=Array.isArray(p)?p[t]:"";return e?`${e}: ${a}`:`${a}`}if("radialBar"===c){let t=g[e]||`Series ${e+1}`,i=Array.isArray(p)?p[e]:"";return`${t}: ${i}`}let x=g[e]||`Series ${e+1}`,u=(Array.isArray(p[e])?p[e]:[])[t],f=null==u?"":String(u),m=null==(r=null==(a=d.formatters)?void 0:a.yLabelFormatters)?void 0:r[e];if("function"==typeof m)try{f=m(u,{seriesIndex:e,dataPointIndex:t,w:d})}catch(e){}let b="",y=null==(l=d.labelData)?void 0:l.categoryLabels,w=null==(n=null==(o=d.seriesData)?void 0:o.seriesX)?void 0:n[e];if(Array.isArray(y)&&null!=y[t])b=String(y[t]);else if(Array.isArray(w)&&null!=w[t]){let i=null==(h=d.formatters)?void 0:h.xLabelFormatter;if("function"==typeof i)try{b=String(i(w[t],{seriesIndex:e,dataPointIndex:t,w:d}))}catch(e){b=String(w[t])}else b=String(w[t])}return b?`${x}: ${f}, ${b}`:`${x}: ${f}`}_leaveHoveredBar(){this._hoveredBarEl&&(new Y(this.w,this.ctx).pathMouseLeave(this._hoveredBarEl,null),this._hoveredBarEl=null)}_getFocusableElement(e,t){let i=this.w,s=i.config.chart.type,a=i.dom.baseEl;return"pie"===s||"donut"===s||"polarArea"===s?a.querySelector(`.apexcharts-pie-area[j='${t}']`):"heatmap"===s?a.querySelector(`.apexcharts-heatmap-rect[i='${e}'][j='${t}']`):"treemap"===s?a.querySelector(`.apexcharts-treemap-rect[i='${e}'][j='${t}']`):"radialBar"===s?a.querySelector(`.apexcharts-radialbar-series[data\\:realIndex='${e}'] path`):"bar"===s||"candlestick"===s||"boxPlot"===s||"rangeBar"===s?a.querySelector(`.apexcharts-series[data\\:realIndex='${e}'] path[j='${t}']`):a.querySelector(`.apexcharts-series[data\\:realIndex='${e}'] .apexcharts-marker[rel='${t}']`)||null}_fireClick(){let e=this.w.globals.tooltip;e&&e.markerClick({type:"mouseup",clientX:0,clientY:0},this.seriesIndex,this.dataPointIndex)}_isNavEnabled(){let e=this.w.config.chart.accessibility;return e.enabled&&e.keyboard.enabled&&e.keyboard.navigation.enabled}_getSeriesCount(){let e=this.w,t=e.config.chart.type;return"pie"===t||"donut"===t||"polarArea"===t?1:e.seriesData.series.length}_getDataPointCount(e){let t=this.w,i=t.config.chart.type;if("pie"===i||"donut"===i||"polarArea"===i)return t.seriesData.series.length;let s=t.seriesData.series;return s[e]&&Array.isArray(s[e])?s[e].length:0}_clampCursor(){let e=this._getSeriesCount();this.seriesIndex>=e&&(this.seriesIndex=e-1),this.seriesIndex<0&&(this.seriesIndex=0);let t=this._getDataPointCount(this.seriesIndex);this.dataPointIndex>=t&&(this.dataPointIndex=t-1),this.dataPointIndex<0&&(this.dataPointIndex=0)}_snapToVisibleRange(){let e=this.w,t=e.globals,i=this.seriesIndex;if(!e.interact.zoomed)return;let s=e.seriesData.seriesX&&e.seriesData.seriesX[i];if(!s||!s.length)return;let a=t.minX,r=t.maxX;if(void 0===a||void 0===r)return;let l=s[this.dataPointIndex];if(l>=a&&l<=r)return;let o=s.length;for(let e=0;e<o;e++)if(s[e]>=a&&s[e]<=r){this.dataPointIndex=e;return}}_snapToVisibleRangeInDirection(e){let t=this.w,i=t.globals,s=this.seriesIndex,a=t.seriesData.seriesX&&t.seriesData.seriesX[s];if(!a||!a.length)return;let r=i.minX,l=i.maxX;if(void 0===r||void 0===l)return;let o=a.length;if(e>=0){for(let e=0;e<o;e++)if(a[e]>=r&&a[e]<=l){this.dataPointIndex=e;return}}else for(let e=o-1;e>=0;
903e--)if(a[e]>=r&&a[e]<=l){this.dataPointIndex=e;return}}_isDataPointVisible(e,t){let i=this.w,s=i.globals;if(!i.interact.zoomed)return!0;let a=i.seriesData.seriesX&&i.seriesData.seriesX[e];if(!a)return!0;let r=a[t];return void 0===r||r>=s.minX&&r<=s.maxX}_announce(e){let t=this.w;if(!t.config.chart.accessibility.announcements.enabled)return;let i=t.dom.baseEl;if(!i)return;let s=i.querySelector(".apexcharts-sr-status");s&&(s.textContent="",setTimeout(()=>{s.textContent=e},0))}}eJ.registerFeatures({keyboardNavigation:te});class tt{constructor(e){this.w=e.w,this.barCtx=e,this.totalFormatter=this.w.config.plotOptions.bar.dataLabels.total.formatter,this.totalFormatter||(this.totalFormatter=this.w.config.dataLabels.formatter)}handleBarDataLabels(e){let t,i,{x:s,y:a,y1:r,y2:l,i:o,j:n,realIndex:h,columnGroupIndex:g,series:p,barHeight:x,barWidth:u,barXPosition:f,barYPosition:m,visibleSeries:b}=e,y=this.w,w=new Y(this.barCtx.w),v=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[h]:this.barCtx.strokeWidth;y.axisFlags.isXNumeric&&!y.globals.isBarHorizontal?(t=s+u*(b+1),i=a+x*(b+1)-v):(t=s+u*b,i=a+x*b);let A=null,C=null,S=s,k=a,D={},L=y.config.dataLabels,M=this.barCtx.barOptions.dataLabels,P=this.barCtx.barOptions.dataLabels.total;void 0!==m&&this.barCtx.isRangeBar&&(i=m,k=m),void 0!==f&&this.barCtx.isVerticalGroupedRangeBar&&(t=f,S=f);let E=L.offsetX,T=L.offsetY,F={width:0,height:0};if(y.config.dataLabels.enabled){let e=y.seriesData.series[o][n];F=w.getTextRects(y.config.dataLabels.formatter?y.config.dataLabels.formatter(e,c(d({},y),{seriesIndex:o,dataPointIndex:n,w:y})):y.formatters.yLabelFormatters[0](e),parseFloat(L.style.fontSize).toString())}let X={x:s,y:a,i:o,j:n,realIndex:h,columnGroupIndex:g,bcx:t,bcy:i,barHeight:x,barWidth:u,textRects:F,strokeWidth:v,dataLabelsX:S,dataLabelsY:k,dataLabelsConfig:L,barDataLabelsConfig:M,barTotalDataLabelsConfig:P,offX:E,offY:T};return D=this.barCtx.isHorizontal?this.calculateBarsDataLabelsPosition(X):this.calculateColumnsDataLabelsPosition(X),A=this.drawCalculatedDataLabels({x:D.dataLabelsX,y:D.dataLabelsY,val:this.barCtx.isRangeBar?[r,l]:"100%"===y.config.chart.stackType?p[h][n]:y.seriesData.series[h][n],i:h,j:n,barWidth:u,barHeight:x,textRects:F,dataLabelsConfig:L}),y.config.chart.stacked&&P.enabled&&(C=this.drawTotalDataLabels({x:D.totalDataLabelsX,y:D.totalDataLabelsY,barWidth:u,barHeight:x,realIndex:h,textAnchor:D.totalDataLabelsAnchor,val:this.getStackedTotalDataLabel({realIndex:h,j:n}),dataLabelsConfig:L,barTotalDataLabelsConfig:P})),{dataLabelsPos:D,dataLabels:A,totalDataLabels:C}}getStackedTotalDataLabel({realIndex:e,j:t}){let i=this.w,s=this.barCtx.stackedSeriesTotals[t];return this.totalFormatter&&(s=this.totalFormatter(s,c(d({},i),{seriesIndex:e,dataPointIndex:t,w:i}))),s}calculateColumnsDataLabelsPosition(e){let t,i,s=this.w,{i:a,j:r,realIndex:l,y:o,bcx:n,barWidth:h,barHeight:d,textRects:c,dataLabelsX:g,dataLabelsY:p,dataLabelsConfig:x,barDataLabelsConfig:u,barTotalDataLabelsConfig:f,strokeWidth:m,offX:b,offY:y}=e,w=n;d=Math.abs(d);let v="vertical"===s.config.plotOptions.bar.dataLabels.orientation,{zeroEncounters:A}=this.barCtx.barHelpers.getZeroValueEncounters({i:a,j:r});n-=m/2;let C=s.layout.gridWidth/s.globals.dataPoints;this.barCtx.isVerticalGroupedRangeBar?g+=h/2:(g=s.axisFlags.isXNumeric?n-h/2+b:n-C+h/2+b,!s.config.chart.stacked&&A>0&&s.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(g-=h*A)),v&&(g=g+c.height/2-m/2-2);let S=s.seriesData.series[a][r]<0,k=o;switch(this.barCtx.isReversed&&(k=o+(S?d:-d)),u.position){case"center":p=v?S?k-d/2+y:k+d/2-y:S?k-d/2+c.height/2+y:k+d/2+c.height/2-y;break;case"bottom":p=v?S?k-d+y:k+d-y:S?k-d+c.height+m+y:k+d-c.height/2+m-y;break;case"top":p=v?S?k+y:k-y:S?k-c.height/2-y:k+c.height+y}let D=k;if(s.labelData.seriesGroups.forEach(e=>{var t;null==(t=this.barCtx[e.join(",")])||t.prevY.forEach(e=>{D=S?Math.max(e[r],D):Math.min(e[r],D)})}),this.barCtx.lastActiveBarSerieIndex===l&&f.enabled){let e=new Y(this.barCtx.w).getTextRects(this.getStackedTotalDataLabel({realIndex:l,j:r}),x.fontSize);t=S?D-e.height/2-y-f.offsetY+18:D+e.height+y+f.offsetY-18,i=w+(s.axisFlags.isXNumeric?-h*s.globals.barGroups.length/2:s.globals.barGroups.length*h/2-(s.globals.barGroups.length-1)*h-C)+f.offsetX}return!s.config.chart.stacked&&(p<0?p=0+m:p+c.height/3>s.layout.gridHeight&&(p=s.layout.gridHeight-m)),{bcx:n,bcy:o,dataLabelsX:g,dataLabelsY:p,totalDataLabelsX:i,totalDataLabelsY:t,totalDataLabelsAnchor:"middle"}}calculateBarsDataLabelsPosition(e){let t,i,s=this.w,{x:a,i:r,j:l,realIndex:o,bcy:n,barHeight:h,barWidth:d,textRects:c,dataLabelsX:g,strokeWidth:p,dataLabelsConfig:x,barDataLabelsConfig:u,barTotalDataLabelsConfig:f,offX:m,offY:b}=e,y=s.layout.gridHeight/s.globals.dataPoints,{zeroEncounters:w}=this.barCtx.barHelpers.getZeroValueEncounters({i:r,j:l});d=Math.abs(d);let v=n-(this.barCtx.isRangeBar?0:y)+h/2+c.height/2+b-3;!s.config.chart.stacked&&w>0&&s.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(v-=h*w);let A="start",C=s.seriesData.series[r][l]<0,S=a;switch(this.barCtx.isReversed&&(S=a+(C?-d:d),A=C?"start":"end"),u.position){case"center":g=C?S+d/2-m:Math.max(c.width/2,S-d/2)+m;break;
903case"bottom":g=C?S+d-p-m:S-d+p+m;break;case"top":g=C?S-p-m:S-p+m}let k=S;if(s.labelData.seriesGroups.forEach(e=>{var t;null==(t=this.barCtx[e.join(",")])||t.prevX.forEach(e=>{k=C?Math.min(e[l],k):Math.max(e[l],k)})}),this.barCtx.lastActiveBarSerieIndex===o&&f.enabled){let e=new Y(this.barCtx.w).getTextRects(this.getStackedTotalDataLabel({realIndex:o,j:l}),x.fontSize);C?(t=k-p-m-f.offsetX,A="end"):t=k+m+f.offsetX+(this.barCtx.isReversed?-(d+p):p),i=v-c.height/2+e.height/2+f.offsetY+p,s.globals.barGroups.length>1&&(i-=s.globals.barGroups.length/2*(h/2))}return!s.config.chart.stacked&&("start"===x.textAnchor?g-c.width<0?g=C?c.width+p:p:g+c.width>s.layout.gridWidth&&(g=C?s.layout.gridWidth-p:s.layout.gridWidth-c.width-p):"middle"===x.textAnchor?g-c.width/2<0?g=c.width/2+p:g+c.width/2>s.layout.gridWidth&&(g=s.layout.gridWidth-c.width/2-p):"end"===x.textAnchor&&(g<1?g=c.width+p:g+1>s.layout.gridWidth&&(g=s.layout.gridWidth-c.width-p))),{bcx:a,bcy:n,dataLabelsX:g,dataLabelsY:v,totalDataLabelsX:t,totalDataLabelsY:i,totalDataLabelsAnchor:A}}drawCalculatedDataLabels({x:e,y:t,val:i,i:s,j:a,textRects:r,barHeight:l,barWidth:o,dataLabelsConfig:n}){let h=this.w,g="rotate(0)";"vertical"===h.config.plotOptions.bar.dataLabels.orientation&&(g=`rotate(-90, ${e}, ${t})`);let p=new G(this.barCtx.w,this.barCtx.ctx),x=new Y(this.barCtx.w),u=n.formatter,f=null,m=h.globals.collapsedSeriesIndices.indexOf(s)>-1;if(n.enabled&&!m){f=x.group({class:"apexcharts-data-labels",transform:g});let m="";void 0!==i&&(m=u(i,c(d({},h),{seriesIndex:s,dataPointIndex:a,w:h}))),!i&&h.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(m="");let b=h.seriesData.series[s][a]<0,y=h.config.plotOptions.bar.dataLabels.position;"vertical"===h.config.plotOptions.bar.dataLabels.orientation&&("top"===y&&(b?n.textAnchor="end":n.textAnchor="start"),"center"===y&&(n.textAnchor="middle"),"bottom"===y&&(b?n.textAnchor="end":n.textAnchor="start")),this.barCtx.isRangeBar&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&o<x.getTextRects(m,parseFloat(n.style.fontSize).toString()).width&&(m=""),h.config.chart.stacked&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&(this.barCtx.isHorizontal?r.width/1.6>Math.abs(o)&&(m=""):r.height/1.6>Math.abs(l)&&(m=""));let w=d({},n);this.barCtx.isHorizontal&&i<0&&("start"===n.textAnchor?w.textAnchor="end":"end"===n.textAnchor&&(w.textAnchor="start")),p.plotDataLabelsText({x:e,y:t,text:m,i:s,j:a,parent:f,dataLabelsConfig:w,alwaysDrawDataLabel:!0,offsetCorrection:!0})}return f}drawTotalDataLabels({x:e,y:t,val:i,realIndex:s,textAnchor:a,barTotalDataLabelsConfig:r}){let l,o=new Y(this.barCtx.w);return r.enabled&&void 0!==e&&void 0!==t&&this.barCtx.lastActiveBarSerieIndex===s&&(l=o.drawText({x:e,y:t,foreColor:r.style.color,text:i,textAnchor:a,fontFamily:r.style.fontFamily,fontSize:r.style.fontSize,fontWeight:r.style.fontWeight})),l}}let ti=class{constructor(e){this.w=e.w,this.barCtx=e}initVariables(e){let t=this.w;this.barCtx.series=e,this.barCtx.totalItems=0,this.barCtx.seriesLen=0,this.barCtx.visibleI=-1,this.barCtx.visibleItems=1;for(let 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.axisFlags.isXNumeric)for(let s=0;s<e[i].length;
903s++)t.seriesData.seriesX[i][s]>t.globals.minX&&t.seriesData.seriesX[i][s]<t.globals.maxX&&this.barCtx.visibleItems++;else this.barCtx.visibleItems=t.globals.dataPoints;this.arrBorderRadius=this.createBorderRadiusArr(t.seriesData.series),v.isSafari()&&(this.arrBorderRadius=this.arrBorderRadius.map(e=>e.map(e=>"none"))),0===this.barCtx.seriesLen&&(this.barCtx.seriesLen=1),this.barCtx.zeroSerieses=[],t.globals.comboCharts||this.checkZeroSeries({series:e})}initialPositions(e){let t,i,s,a,r,l,o,n,h=this.w,d=h.globals.dataPoints;this.barCtx.isRangeBar&&(d=h.labelData.labels.length);let c=this.barCtx.seriesLen;if(h.config.plotOptions.bar.rangeBarGroupRows&&(c=1),this.barCtx.isHorizontal)r=(s=h.layout.gridHeight/d)/c,h.axisFlags.isXNumeric&&(r=(s=h.layout.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)),n=this.barCtx.baseLineInvertedY+h.globals.padHorizontal+(this.barCtx.isReversed?h.layout.gridWidth:0)-(this.barCtx.isReversed?2*this.barCtx.baseLineInvertedY:0),this.barCtx.isFunnel&&(n=h.layout.gridWidth/2),i=(s-r*this.barCtx.seriesLen)/2;else{if(a=h.layout.gridWidth/this.barCtx.visibleItems,h.config.xaxis.convertedCatToNumeric&&(a=h.layout.gridWidth/h.globals.dataPoints),l=a/c*parseInt(this.barCtx.barOptions.columnWidth,10)/100,h.axisFlags.isXNumeric){let e=this.barCtx.xRatio;h.globals.minXDiff&&.5!==h.globals.minXDiff&&h.globals.minXDiff/e>0&&(a=h.globals.minXDiff/e),(l=a/c*parseInt(this.barCtx.barOptions.columnWidth,10)/100)<1&&(l=1)}-1===String(this.barCtx.barOptions.columnWidth).indexOf("%")&&(l=parseInt(this.barCtx.barOptions.columnWidth,10)),o=h.layout.gridHeight-this.barCtx.baseLineY[this.barCtx.translationsIndex]-(this.barCtx.isReversed?h.layout.gridHeight:0)+(this.barCtx.isReversed?2*this.barCtx.baseLineY[this.barCtx.translationsIndex]:0),t=h.axisFlags.isXNumeric?this.barCtx.getBarXForNumericXAxis({x:t,j:0,realIndex:e,barWidth:l}).x:h.globals.padHorizontal+v.noExponents(a-l*this.barCtx.seriesLen)/2}return h.globals.barHeight=r,h.globals.barWidth=l,{x:t,y:i,yDivision:s,xDivision:a,barHeight:r,barWidth:l,zeroH:o,zeroW:n}}initializeStackedPrevVars(e){e.w.labelData.seriesGroups.forEach(t=>{e[t]||(e[t]={}),e[t].prevY=[],e[t].prevX=[],e[t].prevYF=[],e[t].prevXF=[],e[t].prevYVal=[],e[t].prevXVal=[]})}initializeStackedXYVars(e){e.w.labelData.seriesGroups.forEach(t=>{e[t]||(e[t]={}),e[t].xArrj=[],e[t].xArrjF=[],e[t].xArrjVal=[],e[t].yArrj=[],e[t].yArrjF=[],e[t].yArrjVal=[]})}getPathFillColor(e,t,i,s){var a,r,l,o;let n=this.w,h=new W(this.barCtx.w),d=null,c=this.barCtx.barOptions.distributed?i:t,g=!1;return this.barCtx.barOptions.colors.ranges.length>0&&this.barCtx.barOptions.colors.ranges.map(s=>{e[t][i]>=s.from&&e[t][i]<=s.to&&(d=s.color,g=!0)}),{color:h.fillPath({seriesNumber:this.barCtx.barOptions.distributed?c:s,dataPointIndex:i,color:d,value:e[t][i],fillConfig:null==(a=n.config.series[t].data[i])?void 0:a.fill,fillType:(null==(l=null==(r=n.config.series[t].data[i])?void 0:r.fill)?void 0:l.type)?null==(o=n.config.series[t].data[i])?void 0:o.fill.type:Array.isArray(n.config.fill.type)?n.config.fill.type[s]:n.config.fill.type}),useRangeColor:g}}getStrokeWidth(e,t,i){let s=0,a=this.w;return void 0!==this.barCtx.series[e][t]&&null!==this.barCtx.series[e][t]&&("bar"!==a.config.chart.type||this.barCtx.series[e][t])?this.barCtx.isNullValue=!1:this.barCtx.isNullValue=!0,a.config.stroke.show&&!this.barCtx.isNullValue&&(s=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[i]:this.barCtx.strokeWidth),s}createBorderRadiusArr(e){var t;let i=this.w,s=!this.w.config.chart.stacked||i.config.plotOptions.bar.borderRadius<=0,a=e.length,r=(null==(t=e[0])?void 0:t.length)|0,l=Array.from({length:a},()=>Array(r).fill(s?"top":"none"));if(s)return l;let o=this.w.config.chart.type;for(let t=0;t<r;t++){let i=[],s=[],n=0;for(let r=0;r<a;r++){let a=e[r][t];a>0?(i.push(r),n++):a<0&&(s.push(r),n++)}if(i.length>0&&0===s.length)if(1===i.length)l[i[0]][t]="bar"===o&&1===r?"top":"both";else{let e=i[0],s=i[i.length-1];
903for(let a of i)a===e?l[a][t]="bar"===o&&1===r?"top":"bottom":a===s?l[a][t]="top":l[a][t]="none"}else if(s.length>0&&0===i.length)if(1===s.length)l[s[0]][t]="both";else{let e=Math.max(...s),i=Math.min(...s);for(let a of s)a===e?l[a][t]="bottom":a===i?l[a][t]="top":l[a][t]="none"}else if(i.length>0&&s.length>0){let e=i[i.length-1];for(let s of i)s===e?l[s][t]="top":l[s][t]="none";let a=Math.max(...s);for(let e of s)e===a?l[e][t]="bottom":l[e][t]="none"}else 1===n&&(l[i[0]||s[0]][t]="both")}return l}barBackground({j:e,i:t,x1:i,x2:s,y1:a,y2:r,elSeries:l}){let o=this.w,n=new Y(this.barCtx.w),h=new er(this.barCtx.w).getActiveConfigSeriesIndex();if(this.barCtx.barOptions.colors.backgroundBarColors.length>0&&h===t){e>=this.barCtx.barOptions.colors.backgroundBarColors.length&&(e%=this.barCtx.barOptions.colors.backgroundBarColors.length);let t=this.barCtx.barOptions.colors.backgroundBarColors[e],h=n.drawRect(void 0!==i?i:0,void 0!==a?a:0,void 0!==s?s:o.layout.gridWidth,void 0!==r?r:o.layout.gridHeight,this.barCtx.barOptions.colors.backgroundBarRadius,t,this.barCtx.barOptions.colors.backgroundBarOpacity);l.add(h),h.node.classList.add("apexcharts-backgroundBar")}}getColumnPaths({barWidth:e,barXPosition:t,y1:i,y2:s,strokeWidth:a,isReversed:r,series:l,seriesGroup:o,realIndex:n,i:h,j:d,w:c}){var g;let p=new Y(this.barCtx.w);(a=Array.isArray(a)?a[n]:a)||(a=0);let x=e,u=t;(null==(g=c.config.series[n].data[d])?void 0:g.columnWidthOffset)&&(u=t-c.config.series[n].data[d].columnWidthOffset/2,x=e+c.config.series[n].data[d].columnWidthOffset);let f=a/2,m=u+f,b=u+x-f,y=(l[h][d]>=0?1:-1)*(r?-1:1);i+=.001-f*y,s+=.001+f*y;let w=p.move(m,i),v=p.move(m,i),A=p.line(b,i);if(c.globals.previousPaths.length>0&&(v=this.barCtx.getPreviousPath(n,d,!1)),w=w+p.line(m,s)+p.line(b,s)+A+("around"===c.config.plotOptions.bar.borderRadiusApplication||"both"===this.arrBorderRadius[n][d]?" Z":" z"),v=v+p.line(m,i)+A+A+A+A+A+p.line(m,i)+("around"===c.config.plotOptions.bar.borderRadiusApplication||"both"===this.arrBorderRadius[n][d]?" Z":" z"),"none"!==this.arrBorderRadius[n][d]&&(w=p.roundPathCorners(w,c.config.plotOptions.bar.borderRadius)),c.config.chart.stacked){let e=this.barCtx;(e=this.barCtx[o]).yArrj.push(s-f*y),e.yArrjF.push(Math.abs(i-s+a*y)),e.yArrjVal.push(this.barCtx.series[h][d])}return{pathTo:w,pathFrom:v}}getBarpaths({barYPosition:e,barHeight:t,x1:i,x2:s,strokeWidth:a,isReversed:r,series:l,seriesGroup:o,realIndex:n,i:h,j:d,w:c}){var g;let p=new Y(this.barCtx.w);(a=Array.isArray(a)?a[n]:a)||(a=0);let x=e,u=t;(null==(g=c.config.series[n].data[d])?void 0:g.barHeightOffset)&&(x=e-c.config.series[n].data[d].barHeightOffset/2,u=t+c.config.series[n].data[d].barHeightOffset);let f=a/2,m=x+f,b=x+u-f,y=(l[h][d]>=0?1:-1)*(r?-1:1);i+=.001+f*y,s+=.001-f*y;let w=p.move(i,m),v=p.move(i,m);c.globals.previousPaths.length>0&&(v=this.barCtx.getPreviousPath(n,d,!1));let A=p.line(i,b);if(w=w+p.line(s,m)+p.line(s,b)+A+("around"===c.config.plotOptions.bar.borderRadiusApplication||"both"===this.arrBorderRadius[n][d]?" Z":" z"),v=v+p.line(i,m)+A+A+A+A+A+p.line(i,m)+("around"===c.config.plotOptions.bar.borderRadiusApplication||"both"===this.arrBorderRadius[n][d]?" Z":" z"),"none"!==this.arrBorderRadius[n][d]&&(w=p.roundPathCorners(w,c.config.plotOptions.bar.borderRadius)),c.config.chart.stacked){let e=this.barCtx;(e=this.barCtx[o]).xArrj.push(s+f*y),e.xArrjF.push(Math.abs(i-s-a*y)),e.xArrjVal.push(this.barCtx.series[h][d])}return{pathTo:w,pathFrom:v}}checkZeroSeries({series:e}){let t=this.w;for(let i=0;i<e.length;i++){let s=0;for(let a=0;a<e[t.globals.maxValsInArrayIndex].length;a++)s+=e[i][a];0===s&&this.barCtx.zeroSerieses.push(i)}}getXForValue(e,t,i=!0){let s=i?t:null;return null!=e&&(s=t+e/this.barCtx.invertedYRatio-(this.barCtx.isReversed?e/this.barCtx.invertedYRatio:0)*2),s}getYForValue(e,t,i,s=!0){let a=s?t:null;return null!=e&&(a=t-e/this.barCtx.yRatio[i]+(this.barCtx.isReversed?e/this.barCtx.yRatio[i]:0)*2),a}getGoalValues(e,t,i,s,a,r){let l=this.w,o=[],n=(s,a)=>{o.push({[e]:"x"===e?this.getXForValue(s,t,!1):this.getYForValue(s,i,r,!1),attrs:a})};if(l.seriesData.seriesGoals[s]&&l.seriesData.seriesGoals[s][a]&&Array.isArray(l.seriesData.seriesGoals[s][a])&&l.seriesData.seriesGoals[s][a].forEac
903h(e=>{n(e.value,e)}),this.barCtx.barOptions.isDumbbell&&l.rangeData.seriesRange.length){let t=this.barCtx.barOptions.dumbbellColors?this.barCtx.barOptions.dumbbellColors:l.globals.colors,i={strokeHeight:"x"===e?0:l.globals.markers.size[s],strokeWidth:"x"===e?l.globals.markers.size[s]:0,strokeDashArray:0,strokeLineCap:"round",strokeColor:Array.isArray(t[s])?t[s][0]:t[s]};n(l.rangeData.seriesRangeStart[s][a],i),n(l.rangeData.seriesRangeEnd[s][a],c(d({},i),{strokeColor:Array.isArray(t[s])?t[s][1]:t[s]}))}return o}drawGoalLine({barXPosition:e,barYPosition:t,goalX:i,goalY:s,barWidth:a,barHeight:r}){let l=new Y(this.barCtx.w),o=l.group({className:"apexcharts-bar-goals-groups"});o.node.classList.add("apexcharts-element-hidden"),this.barCtx.w.globals.delayedElements.push({el:o.node}),o.attr("clip-path",`url(#gridRectMarkerMask${this.barCtx.w.globals.cuid})`);let n=null;return this.barCtx.isHorizontal?Array.isArray(i)&&i.forEach(e=>{if(e.x>=-1&&e.x<=l.w.layout.gridWidth+1){let i=void 0!==e.attrs.strokeHeight?e.attrs.strokeHeight:r/2,s=t+i+r/2;n=l.drawLine(e.x,s-2*i,e.x,s,e.attrs.strokeColor?e.attrs.strokeColor:void 0,e.attrs.strokeDashArray,e.attrs.strokeWidth?e.attrs.strokeWidth:2,e.attrs.strokeLineCap),o.add(n)}}):Array.isArray(s)&&s.forEach(t=>{if(t.y>=-1&&t.y<=l.w.layout.gridHeight+1){let i=void 0!==t.attrs.strokeWidth?t.attrs.strokeWidth:a/2,s=e+i+a/2;n=l.drawLine(s-2*i,t.y,s,t.y,t.attrs.strokeColor?t.attrs.strokeColor:void 0,t.attrs.strokeDashArray,t.attrs.strokeHeight?t.attrs.strokeHeight:2,t.attrs.strokeLineCap),o.add(n)}}),o}drawBarShadow({prevPaths:e,currPaths:t,color:i,realIndex:s,j:a}){let r=this.w,{x:l,x1:o,barYPosition:n}=e,{x:h,x1:d,barYPosition:c}=t,g=n+t.barHeight,p=new Y(this.barCtx.w),x=new v,u=p.move(o,g)+p.line(l,g)+p.line(h,c)+p.line(d,c)+p.line(o,g)+("around"===r.config.plotOptions.bar.borderRadiusApplication||"both"===this.arrBorderRadius[s][a]?" Z":" z");return p.drawPath({d:u,fill:x.shadeColor(.5,v.rgb2hex(i)),stroke:"none",strokeWidth:0,fillOpacity:1,classes:"apexcharts-bar-shadow apexcharts-decoration-element"})}getZeroValueEncounters({i:e,j:t}){var i;let s=this.w,a=0,r=0;return(s.config.plotOptions.bar.horizontal?s.seriesData.series.map((e,t)=>t):(null==(i=s.globals.columnSeries)?void 0:i.i.map(e=>e))||[]).forEach(i=>{let l=s.globals.seriesPercent[i][t];l&&a++,i<e&&0===l&&r++}),{nonZeroColumns:a,zeroEncounters:r}}getGroupIndex(e){let t=this.w,i=t.labelData.seriesGroups.findIndex(i=>i.indexOf(t.seriesData.seriesNames[e])>-1),s=this.barCtx.columnGroupIndices,a=s.indexOf(i);return a<0&&(s.push(i),a=s.length-1),{groupIndex:i,columnGroupIndex:a}}};class ts{constructor(e,t,i){this.ctx=t,this.w=e,this.barOptions=e.config.plotOptions.bar,this.isHorizontal=this.barOptions.horizontal,this.strokeWidth=e.config.stroke.width,this.isNullValue=!1,this.isRangeBar=e.rangeData.seriesRange.length&&this.isHorizontal,this.isVerticalGroupedRangeBar=!e.globals.isBarHorizontal&&e.rangeData.seriesRange.length&&e.config.plotOptions.bar.rangeBarGroupRows,this.isFunnel=this.barOptions.isFunnel,this.xyRatios=i,this.xRatio=0,this.yRatio=[],this.invertedXRatio=0,this.invertedYRatio=0,this.baseLineY=[],this.baseLineInvertedY=0,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=[],this.series=[],this.elSeries=null,this.visibleI=0,this.isReversed=!1;const s=new er(this.w);this.lastActiveBarSerieIndex=s.getActiveConfigSeriesIndex("desc",["bar","column"]),this.columnGroupIndices=[];const a=s.getBarSeriesIndices(),r=new I(this.w);this.stackedSeriesTotals=r.getStackedSeriesTotals(this.w.config.series.map((e,t)=>-1===a.indexOf(t)?t:-1).filter(e=>-1!==e)),this.barHelpers=new ti(this)}draw(e,t){var i;let s=this.w,a=new Y(this.w),r=new I(this.w);e=r.getLogSeries(e),this.series=e,this.yRatio=r.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e);let l=a.group({class:"apexcharts-bar-series apexcharts-plot-series"});s.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(let r=0,o=0;r<e.length;r++,o++){let n,h,g=[],p=[],x=s.globals.comboCharts?t[r]:r,{columnGroupIndex:u}=this.barHelpers.getGroupIndex(x),f=a.group({class:"apexcharts-series",rel:r+1,seriesName:v.escapeString(s.seriesData.seriesNames[x]),"data:realIndex":x});er.addCollapsedClassToSeries(this.w,f,x),e[r].length>0&&(this.visibleI=this.visibleI+1),this.yRatio.length>1&&(this.yaxisIndex=s.globals.seriesYAxisReverseMap[x],this.translationsIndex=x);let m=this.translationsIndex;this.isReversed=s.config.yaxis[this.yaxisIndex]&&s.config.yaxis[this.yaxisIndex].reversed;let b=this.barHelpers.initialPositions(x),{y:y,yDivision:w,zeroW:A,x:C,xDivision:S,zeroH:k}=b,D=b.barHeight,L=b.barWidth;h=y,n=C,this.isHorizontal||p.push(n+(null!=L?L:0)/2);let M=a.group({class:"apexcharts-datalabels","data:realIndex":x});s.globals.delayedElements.push({el:M.node}),M.node.classList.add("apexcharts-element-hidden");let P=a.group({class:"apexcharts-bar-goals-markers"}),E=a.group({class:"apexcharts-bar-shadows"});s.globals.delayedElements.push({el:E.node}),E.node.classList.add("apexcharts-element-hidden");for(let t=0;t<e[r].length;t++){let a=this.barHelpers.getStrokeWidth(r,t,x),l=null,b={indexes:{i:r,j:t,realIndex:x,translationsIndex:m,bc:o},x:n,y:h,strokeWidth:a,elSeries:f};this.isHorizontal?(l=this.drawBarPaths(c(d({},b),{barHeight:D,zeroW:A,yDivision:w})),L=this.series[r][t]/this.invertedYRatio):(l=this.drawColumnPaths(c(d({},b),{xDivision:S,barWidth:L,zeroH:k})),D=this.series[r][t]/this.yRatio[m]);let y=this.barHelpers.getPathFillColor(e,r,t,x);if(this.isFunnel&&this.barOptions.isFunnel3d&&this.pathArr.length&&t>0){let e=this.barHelpers.drawBarShadow({color:"string"==typeof y.color&&(null==(i=y.color)?void 0:i.indexOf("url"))===-1?y.color:v.hexToRgba(s.globals.colors[r]),prevPaths:this.pathArr[this.pathArr.length-1],currPaths:l,realIndex:x,j:t});E.add(e),s.config.chart.dropShadow.enabled&&new z(this.w).dropShadow(e,s.config.chart.dropShadow,x)}this.pathArr.push(l);let C=this.barHelpers.drawGoalLine({barXPosition:l.barXPosition,barYPosition:l.barYPosition,goalX:l.goalX,goalY:l.goalY,barHeight:D,barWidth:L});C&&P.add(C),h=l.y,n=l.x,t>0&&p.push(n+(null!=L?L:0)/2),g.push(h),this.renderSeries(c(d({realIndex:x,pathFill:y.color},y.useRangeColor?{lineFill:y.color}:{}),{j:t,i:r,columnGroupIndex:u,pathFrom:l.pathFrom,pathTo:l.pathTo,strokeWidth:a,elSeries:f,x:n,y:h,series:e,barHeight:Math.abs(l.barHeight?l.barHeight:D),barWidth:Math.abs(l.barWidth?l.barWidth:L),elDataLabelsWrap:M,elGoalsMarkers:P,elBarShadows:E,visibleSeries:this.visibleI,type:"bar"}))}s.globals.seriesXvalues[x]=p,s.globals.seriesYvalues[x]=g,l.add(f)}return l}renderSeries({realIndex:e,pathFill:t,lineFill:i,j:s,i:a,columnGroupIndex:r,pathFrom:l,pathTo:o,strokeWidth:n,elSeries:h,x:d,y:c,y1:g,y2:p,series:x,barHeight:u,barWidth:f,barXPosition:m,barYPosition:b,elDataLabelsWrap:y,elGoalsMarkers:w,elBarShadows:v,visibleSeries:A,type:C,classes:S}){let k=this.w,D=new Y(this.w,this.ctx),L=!1;if(h._bindingsDelegated||(h._bindingsDelegated=!0,D.setupEventDelegation(h,`.apexcharts-${C}-area`)),!i){var M;let t,a,r="function"==typeof k.globals.stroke.colors[e]?(M=e,Array.isArray(a=k.config.stroke.colors)&&a.length>0&&((t=a[M])||(t=""),"function"==typeof t)?t({value:k.seriesData.series[M][s],dataPointIndex:s,w:k}):t):k.globals.stroke.colors[e];i=this.barOptions.distributed?k.globals.stroke.colors[s]:r}let P=new tt(this).handleBarDataLabels({x:d,y:c,y1:g,y2:p,i:a,j:s,series:x,realIndex:e,columnGroupIndex:r,barHeight:u,barWidth:f,barXPosition:m,barYPosition:b,visibleSeries:A});!k.globals.isBarHorizontal&&(P.dataLabelsPos.dataLabelsX+Math.max(f,k.globals.barPadForNumericAxis)<0||P.dataLabelsPos.dataLabelsX-Math.max(f,k.globals.barPadForNumericAxis)>k.layout.gridWidth)&&(L=!0),k.config.series[a].data[s]&&k.config.series[a].data[s].strokeColor&&(i=k.config.series[a].data[s].strokeColor),this.isNullValue&&(t="none");let E=s/k.config.chart.animations.animateGradually.delay*(k.config.chart.animations.speed/k.globals.dataPoints)/2.4;if(!L){let r=D.renderPaths({i:a,j:s,realIndex:e,pathFrom:l,pathTo:o,stroke:i,strokeWidth:n,strokeLineCap:k.config.stroke.lineCap,fill:t,animationDelay:E,initialSpeed:k.config.chart.animations.speed,dataChangeSpeed:k.config.chart.animations.dynamicAnimation.speed,className:`apexcharts-${C}-area ${S}`,chartType:C,bindEventsOnPaths:!1});r.attr("clip-path",`url(#gridRectBarMask${k.globals.cuid})`);let d=k.config.forecastDataPoints;d.count>0&&s>=k.globals.dataPoints-d.count&&(r.node.setAttribute("stroke-dasharray",d.dashArray),r.node.setAttribute("stroke-width",d.strokeWidth),r.node.setAttribute("fill-opacity",d.fillOpacity)),void 0!==g&&void 0!==p&&(r.attr("data-range-y1",g),r.attr("data-range-y2",p)),new z(this.w).setSelectionFilter(r,e,s),h.add(r),r.attr({cy:P.dataLabelsPos.bcy,cx:P.dataLabelsPos.bcx,j:s,val:k.seriesData.series[a][s],barHeight:u,barWidth:f}),null!==P.dataLabels&&y.add(P.dataLabels),P.totalDataLabels&&y.add(P.totalDataLabels),h.add(y),w&&h.add(w),v&&h.add(v)}return h}drawBarPaths({indexes:e,barHeight:t,strokeWidth:i,zeroW:s,x:a,y:r,yDivision:l,elSeries:o}){let n,h=this.w,d=e.i,c=e.j;if(h.axisFlags.isXNumeric)n=(r=(h.seriesData.seriesX[d][c]-h.globals.minX)/this.invertedXRatio-t)+t*this.visibleI;else if(h.config.plotOptions.bar.hideZeroBarsWhenGrouped){let{nonZeroColumns:e,zeroEncounters:i}=this.barHelpers.getZeroValueEncounters({i:d,j:c}
903);e>0&&(t=this.seriesLen*t/e),n=r+t*this.visibleI-t*i}else n=r+t*this.visibleI;if(this.isFunnel){let e=null!=s?s:0;s=e-(this.barHelpers.getXForValue(this.series[d][c],e)-e)/2}a=this.barHelpers.getXForValue(this.series[d][c],null!=s?s:0);let g=this.barHelpers.getBarpaths({barYPosition:n,barHeight:t,x1:s,x2:a,strokeWidth:i,isReversed:this.isReversed,series:this.series,realIndex:e.realIndex,i:d,j:c,w:h});return h.axisFlags.isXNumeric||(r+=l),this.barHelpers.barBackground({j:c,i:d,y1:n-t*this.visibleI,y2:t*this.seriesLen,elSeries:o}),{pathTo:g.pathTo,pathFrom:g.pathFrom,x1:s,x:a,y:r,goalX:this.barHelpers.getGoalValues("x",s,null,d,c,0),barYPosition:n,barHeight:t}}drawColumnPaths({indexes:e,x:t,y:i,xDivision:s,barWidth:a,zeroH:r,strokeWidth:l,elSeries:o}){let n,h=this.w,d=e.realIndex,c=e.translationsIndex,g=e.i,p=e.j,x=e.bc;if(h.axisFlags.isXNumeric){let e=this.getBarXForNumericXAxis({x:t,j:p,realIndex:d,barWidth:a});t=e.x,n=e.barXPosition}else if(h.config.plotOptions.bar.hideZeroBarsWhenGrouped){let{nonZeroColumns:e,zeroEncounters:i}=this.barHelpers.getZeroValueEncounters({i:g,j:p});e>0&&(a=this.seriesLen*a/e),n=t+a*this.visibleI-a*i}else n=t+a*this.visibleI;i=this.barHelpers.getYForValue(this.series[g][p],r,c);let u=this.barHelpers.getColumnPaths({barXPosition:n,barWidth:a,y1:r,y2:i,strokeWidth:l,isReversed:this.isReversed,series:this.series,realIndex:d,i:g,j:p,w:h});return h.axisFlags.isXNumeric||(t+=s),this.barHelpers.barBackground({bc:x,j:p,i:g,x1:n-l/2-a*this.visibleI,x2:a*this.seriesLen+l/2,elSeries:o}),{pathTo:u.pathTo,pathFrom:u.pathFrom,x:t,y:i,goalY:this.barHelpers.getGoalValues("y",null,r,g,p,c),barXPosition:n,barWidth:a}}getBarXForNumericXAxis({x:e,barWidth:t,realIndex:i,j:s}){let a=this.w,r=i;return a.seriesData.seriesX[i].length||(r=a.globals.maxValsInArrayIndex),v.isNumber(a.seriesData.seriesX[r][s])&&(e=(a.seriesData.seriesX[r][s]-a.globals.minX)/this.xRatio-t*this.seriesLen/2),{barXPosition:e+t*this.visibleI,x:e}}getPreviousPath(e,t){let i=this.w,s="M 0 0";for(let a=0;a<i.globals.previousPaths.length;a++){let r=i.globals.previousPaths[a];r.paths&&r.paths.length>0&&parseInt(r.realIndex,10)===parseInt(String(e),10)&&void 0!==i.globals.previousPaths[a].paths[t]&&(s=i.globals.previousPaths[a].paths[t].d)}return s}}class ta extends ts{draw(e,t){let i=this.w;this.graphics=new Y(this.w),this.bar=new ts(this.w,this.ctx,this.xyRatios);let s=new I(this.w);e=s.getLogSeries(e),this.yRatio=s.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e),"100%"===i.config.chart.stackType&&(e=i.globals.comboCharts?t.map(e=>i.globals.seriesPercent[e]):i.globals.seriesPercent.slice()),this.series=e,this.barHelpers.initializeStackedPrevVars(this);let a=this.graphics.group({class:"apexcharts-bar-series apexcharts-plot-series"}),r=0,l=0;for(let s=0,o=0;s<e.length;s++,o++){let n=i.globals.comboCharts?t[s]:s,{groupIndex:h,columnGroupIndex:g}=this.barHelpers.getGroupIndex(n);this.groupCtx=this[i.labelData.seriesGroups[h]];let p=[],x=[],u=0;this.yRatio.length>1&&(this.yaxisIndex=i.globals.seriesYAxisReverseMap[n][0],u=n),this.isReversed=i.config.yaxis[this.yaxisIndex]&&i.config.yaxis[this.yaxisIndex].reversed;let f=this.graphics.group({class:"apexcharts-series",seriesName:v.escapeString(i.seriesData.seriesNames[n]),rel:s+1,"data:realIndex":n});er.addCollapsedClassToSeries(this.w,f,n);let m=this.graphics.group({class:"apexcharts-datalabels","data:realIndex":n}),b=this.graphics.group({class:"apexcharts-bar-goals-markers"}),y=this.initialPositions(r,l,void 0,void 0,void 0,void 0,u),{xDivision:w,yDivision:A,zeroH:C,zeroW:S}=y,k=y.barHeight,D=y.barWidth;l=y.y,r=y.x,i.globals.barHeight=k,i.globals.barWidth=D,this.barHelpers.initializeStackedXYVars(this),1===this.groupCtx.prevY.length&&this.groupCtx.prevY[0].every(e=>isNaN(e))&&(this.groupCtx.prevY[0]=this.groupCtx.prevY[0].map(()=>C),this.groupCtx.prevYF[0]=this.groupCtx.prevYF[0].map(()=>0));for(let t=0;t<i.globals.dataPoints;t++){let a=this.barHelpers.getStrokeWidth(s,t,n),y={indexes:{i:s,j:t,realIndex:n,translationsIndex:u,bc:o},strokeWidth:a,x:r,y:l,elSeries:f,columnGroupIndex:g,seriesGroup:i.labelData.seriesGroups[h]},v=null;this.isHorizontal?(v=this.drawStackedBarPaths(c(d({},y),{zeroW:S,barHeight:k,yDivision:A})),D=this.series[s][t]/this.invertedYRatio):(v=this.drawStackedColumnPaths(c(d({},y),{xDivision:w,barWidth:D,zeroH:C})),k=this.series[s][t]/this.yRatio[u]);let L=this.barHelpers.drawGoalLine({barXPosition:v.barXPosition,barYPosition:v.barYPosition,goalX:v.goalX,goalY:v.goalY,barHeight:k,barWidth:D});L&&b.add(L),l=v.y,r=v.x,p.push(r),x.push(l);let M=this.barHelpers.getPathFillColor(e,s,t,n),P="",E=i.globals.isBarHorizontal?"apexcharts-flip-x":"apexcharts-flip-y";("bottom"===this.barHelpers.arrBorderRadius[n][t]&&i.seriesData.series[n][t]>0||"top"===this.barHelpers.arrBorderRadius[n][t]&&i.seriesData.series[n][t]<0)&&(P=E),f=this.renderSeries(c(d({realIndex:n,pathFill:M.color},M.useRangeColor?{lineFill:M.color}:{}),{j:t,i:s,columnGroupIndex:g,pathFrom:v.pathFrom,pathTo:v.pathTo,strokeWidth:a,elSeries:f,x:r,y:l,series:e,barHeight:k,barWidth:D,elDataLabelsWrap:m,elGoalsMarkers:b,type:"bar",visibleSeries:g,classes:P}))}i.globals.seriesXvalues[n]=p,i.globals.seriesYvalues[n]=x,this.groupCtx.prevY.push(this.groupCtx.yArrj),this.groupCtx.prevYF.push(this.groupCtx.yArrjF),this.groupCtx.prevYVal.push(this.groupCtx.yArrjVal),this.groupCtx.prevX.push(this.groupCtx.xArrj),this.groupCtx.prevXF.push(this.groupCtx.xArrjF),this.groupCtx.prevXVal.push(this.groupCtx.xArrjVal),a.add(f)}return a}initialPositions(e,t,i,s,a,r,l){let o,n,h=this.w;if(this.isHorizontal){s=h.layout.gridHeight/h.globals.dataPoints;let e=h.config.plotOptions.bar.barHeight;o=-1===String(e).indexOf("%")?parseInt(e,10):s*parseInt(e,10)/100,r=h.globals.padHorizontal+(this.isReversed?h.layout.gridWidth-this.baseLineInvertedY:this.baseLineInvertedY),t=(s-o)/2}else{n=i=h.layout.gridWidth/h.globals.dataPoints;let t=h.config.plotOptions.bar.columnWidth;h.axisFlags.isXNumeric&&h.globals.dataPoints>1?n=(i=h.globals.minXDiff/this.xRatio)*parseInt(this.barOptions.columnWidth,10)/100:-1===String(t).indexOf("%")?n=parseInt(t,10):n*=parseInt(t,10)/100,a=this.isReversed?this.baseLineY[l]:h.layout.gridHeight-this.baseLineY[l],e=h.globals.padHorizontal+(i-n)/2}let d=h.globals.barGroups.length||1;return{x:e,y:t,yDivision:s,xDivision:i,barHeight:(null!=o?o:0)/d,barWidth:(null!=n?n:0)/d,zeroH:a,zeroW:r}}drawStackedBarPaths({indexes:e,barHeight:t,strokeWidth:i,zeroW:s,x:a,y:r,columnGroupIndex:l,seriesGroup:o,yDivision:n,elSeries:h}){var d,c,g,p,x;let u,f=this.w,m=r+l*t,b=e.i,y=e.j,w=e.realIndex,v=e.translationsIndex,A=0;for(let e=0;e<this.groupCtx.prevXF.length;e++)A+=this.groupCtx.prevXF[e][y];let C=b;if(f.config.series[w].name&&(C=o.indexOf(f.config.series[w].name)),C>0){let e=s;this.groupCtx.prevXVal[C-1][y]<0?e=(null==(d=this.series[b])?void 0:d[y])>=0?this.groupCtx.prevX[C-1][y]+A-(this.isReversed?A:0)*2:this.groupCtx.prevX[C-1][y]:this.groupCtx.prevXVal[C-1][y]>=0&&(e=(null==(c=this.series[b])?void 0:c[y])>=0?this.groupCtx.prevX[C-1][y]:this.groupCtx.prevX[C-1][y]-A+(this.isReversed?A:0)*2),u=e}else u=s;a=(null==(g=this.series[b])?void 0:g[y])===null?u:u+(null==(p=this.series[b])?void 0:p[y])/this.invertedYRatio-(this.isReversed?(null==(x=this.series[b])?void 0:x[y])/this.invertedYRatio:0)*2;let S=this.barHelpers.getBarpaths({barYPosition:m,barHeight:t,x1:u,x2:a,strokeWidth:i,isReversed:this.isReversed,series:this.series,realIndex:e.realIndex,seriesGroup:o,i:b,j:y,w:f});
903return this.barHelpers.barBackground({j:y,i:b,y1:m,y2:t,elSeries:h}),r+=n,{pathTo:S.pathTo,pathFrom:S.pathFrom,goalX:this.barHelpers.getGoalValues("x",s,null,b,y,v),barXPosition:u,barYPosition:m,x:a,y:r}}drawStackedColumnPaths({indexes:e,x:t,y:i,xDivision:s,barWidth:a,zeroH:r,columnGroupIndex:l,seriesGroup:o,elSeries:n}){var h,d,c,g,p,x,u,f,m;let b,y=this.w,w=e.i,v=e.j,A=e.bc,C=e.realIndex,S=e.translationsIndex;if(y.axisFlags.isXNumeric){let e=y.seriesData.seriesX[C][v];e||(e=0),t=(e-y.globals.minX)/this.xRatio-a/2*y.globals.barGroups.length}let k=t+l*a,D=0;for(let e=0;e<this.groupCtx.prevYF.length;e++)D+=isNaN(this.groupCtx.prevYF[e][v])?0:this.groupCtx.prevYF[e][v];let L=w;if(o&&(L=o.indexOf(y.seriesData.seriesNames[C])),L>0&&!y.axisFlags.isXNumeric||L>0&&y.axisFlags.isXNumeric&&y.seriesData.seriesX[C-1][v]===y.seriesData.seriesX[C][v]){let e,t,i=Math.min(this.yRatio.length+1,C+1);if(void 0!==this.groupCtx.prevY[L-1]&&this.groupCtx.prevY[L-1].length){for(let e=1;e<i;e++)if(!isNaN(null==(h=this.groupCtx.prevY[L-e])?void 0:h[v])){t=this.groupCtx.prevY[L-e][v];break}}for(let s=1;s<i;
903s++)if((null==(d=this.groupCtx.prevYVal[L-s])?void 0:d[v])<0){e=(null==(c=this.series[w])?void 0:c[v])>=0?t-D+(this.isReversed?D:0)*2:t;break}else if((null==(g=this.groupCtx.prevYVal[L-s])?void 0:g[v])>=0){e=(null==(p=this.series[w])?void 0:p[v])>=0?t:t+D-(this.isReversed?D:0)*2;break}void 0===e&&(e=y.layout.gridHeight),b=(null==(x=this.groupCtx.prevYF[0])?void 0:x.every(e=>0===e))&&this.groupCtx.prevYF.slice(1,L).every(e=>e.every(e=>isNaN(e)))?r:e}else b=r;i=(null==(u=this.series[w])?void 0:u[v])?b-(null==(f=this.series[w])?void 0:f[v])/this.yRatio[S]+(this.isReversed?(null==(m=this.series[w])?void 0:m[v])/this.yRatio[S]:0)*2:b;let M=this.barHelpers.getColumnPaths({barXPosition:k,barWidth:a,y1:b,y2:i,yRatio:this.yRatio[S],strokeWidth:this.strokeWidth,isReversed:this.isReversed,series:this.series,seriesGroup:o,realIndex:e.realIndex,i:w,j:v,w:y});return this.barHelpers.barBackground({bc:A,j:v,i:w,x1:k,x2:a,elSeries:n}),{pathTo:M.pathTo,pathFrom:M.pathFrom,goalY:this.barHelpers.getGoalValues("y",null,r,w,v,0),barXPosition:k,x:y.axisFlags.isXNumeric?t:t+s,y:i}}}class tr extends ts{draw(e,t,i){let s=this.w,a=new Y(this.w),r=s.globals.comboCharts?t:s.config.chart.type,l=new W(this.w);this.candlestickOptions=this.w.config.plotOptions.candlestick,this.boxOptions=this.w.config.plotOptions.boxPlot,this.isHorizontal=s.config.plotOptions.bar.horizontal,this.isOHLC=this.candlestickOptions&&"ohlc"===this.candlestickOptions.type,this.coreUtils=new I(this.w),e=this.coreUtils.getLogSeries(e),this.series=e,this.yRatio=this.coreUtils.getLogYRatios(this.yRatio),this.barHelpers.initVariables(e);let o=a.group({class:`apexcharts-${r}-series apexcharts-plot-series`});for(let t=0;t<e.length;t++){let r,n;this.isBoxPlot="boxPlot"===s.config.chart.type||"boxPlot"===s.config.series[t].type;let h=[],g=[],p=s.globals.comboCharts?i[t]:t,{columnGroupIndex:x}=this.barHelpers.getGroupIndex(p),u=a.group({class:"apexcharts-series",seriesName:v.escapeString(s.seriesData.seriesNames[p]),rel:t+1,"data:realIndex":p});er.addCollapsedClassToSeries(this.w,u,p),e[t].length>0&&(this.visibleI=this.visibleI+1);let f=0;this.yRatio.length>1&&(this.yaxisIndex=s.globals.seriesYAxisReverseMap[p][0],f=p);let{y:m,barHeight:b,yDivision:y,zeroW:w,x:A,barWidth:C,xDivision:S,zeroH:k}=this.barHelpers.initialPositions(p);n=m,r=A,g.push(r+(null!=C?C:0)/2);let D=a.group({class:"apexcharts-datalabels","data:realIndex":p}),L=a.group({class:"apexcharts-bar-goals-markers"});for(let i=0;i<s.globals.dataPoints;i++){let a=this.barHelpers.getStrokeWidth(t,i,p),o=null,m={indexes:{i:t,j:i,realIndex:p,translationsIndex:f},x:r,y:n,strokeWidth:a,elSeries:u};n=(o=this.isHorizontal?this.drawHorizontalBoxPaths(c(d({},m),{yDivision:y,barHeight:b,zeroW:w})):this.drawVerticalBoxPaths(c(d({},m),{xDivision:S,barWidth:C,zeroH:k}))).y,r=o.x;let v=this.barHelpers.drawGoalLine({barXPosition:o.barXPosition,barYPosition:o.barYPosition,goalX:o.goalX,goalY:o.goalY,barHeight:b,barWidth:C});v&&L.add(v),i>0&&g.push(r+(null!=C?C:0)/2),h.push(n),o.pathTo.forEach((h,d)=>{let c=!this.isBoxPlot&&this.candlestickOptions.wick.useFillColor?o.color[d]:s.globals.stroke.colors[t],g=l.fillPath({seriesNumber:p,dataPointIndex:i,color:o.color[d],value:e[t][i]});this.renderSeries({realIndex:p,pathFill:g,lineFill:c,j:i,i:t,pathFrom:o.pathFrom,pathTo:h,strokeWidth:a,elSeries:u,x:r,y:n,series:e,columnGroupIndex:x,barHeight:b,barWidth:C,elDataLabelsWrap:D,elGoalsMarkers:L,visibleSeries:this.visibleI,type:s.config.chart.type})})}s.globals.seriesXvalues[p]=g,s.globals.seriesYvalues[p]=h,o.add(u)}return o}drawVerticalBoxPaths({indexes:e,x:t,xDivision:i,barWidth:s,zeroH:a,strokeWidth:r}){var l,o;let n,h=this.w,d=new Y(this.w),c=e.i,g=e.j,{colors:p}=h.config.plotOptions.candlestick,{colors:x}=this.boxOptions,u=e.realIndex,f=e=>Array.isArray(e)?e[u]:e,m=f(p.upward),b=f(p.downward),y=this.yRatio[e.translationsIndex],w=this.getOHLCValue(u,g),v=a,A=a,C=w.o<w.c?[m]:[b];this.isBoxPlot&&(C=[f(x.lower),f(x.upper)]);let S=Math.min(w.o,w.c),k=Math.max(w.o,w.c),D=w.m;h.axisFlags.isXNumeric&&(t=(h.seriesData.seriesX[u][g]-h.globals.minX)/this.xRatio-s/2);let L=t+s*this.visibleI;void 0===(null==(l=this.series[c])?void 0:l[g])||(null==(o=this.series[c])?void 0:o[g])===null?(S=a,k=a):(S=a-S/y,k=a-k/y,v=a-w.h/y,A=a-w.l/y,D=a-w.m/y);let M=d.move(L+s/2,S);if(h.globals.previousPaths.length>0&&(M=this.getPreviousPath(u,g)),this.isOHLC){let e=L+s/2,t=a-w.o/y,i=a-w.c/y;n=[d.move(e,v)+d.line(e,A)+d.move(e,t)+d.line(L,t)+d.move(e,i)+d.line(L+s,i)]}else n=this.isBoxPlot?[d.move(L,S)+d.line(L+s/2,S)+d.line(L+s/2,v)+d.line(L+s/4,v)+d.line(L+s-s/4,v)+d.line(L+s/2,v)+d.line(L+s/2,S)+d.line(L+s,S)+d.line(L+s,D)+d.line(L,D)+d.line(L,S+r/2),d.move(L,D)+d.line(L+s,D)+d.line(L+s,k)+d.line(L+s/2,k)+d.line(L+s/2,A)+d.line(L+s-s/4,A)+d.line(L+s/4,A)+d.line(L+s/2,A)+d.line(L+s/2,k)+d.line(L,k)+d.line(L,D)+"z"]:[d.move(L,k)+d.line(L+s/2,k)+d.line(L+s/2,v)+d.line(L+s/2,k)+d.line(L+s,k)+d.line(L+s,S)+d.line(L+s/2,S)+d.line(L+s/2,A)+d.line(L+s/2,S)+d.line(L,S)+d.line(L,k-r/2)];return M+=d.move(L,S),h.axisFlags.isXNumeric||(t+=i),{pathTo:n,pathFrom:M,x:t,y:k,goalY:this.barHelpers.getGoalValues("y",null,a,c,g,e.translationsIndex),barXPosition:L,color:C}}drawHorizontalBoxPaths({indexes:e,y:t,yDivision:i,barHeight:s,zeroW:a,strokeWidth:r}){var l,o;let n=this.w,h=new Y(this.w),d=e.i,c=e.j,g=e.realIndex,{colors:p}=n.config.plotOptions.candlestick,{colors:x}=this.boxOptions,u=e=>Array.isArray(e)?e[g]:e,f=this.invertedYRatio,m=this.getOHLCValue(g,c),b=m.o<m.c?[u(p.upward)]:[u(p.downward)];this.isBoxPlot&&(b=[u(x.lower),u(x.upper)]);let y=a,w=a,v=Math.min(m.o,m.c),A=Math.max(m.o,m.c),C=m.m;n.axisFlags.isXNumeric&&(t=(n.seriesData.seriesX[g][c]-n.globals.minX)/this.invertedXRatio-s/2);let S=t+s*this.visibleI;void 0===(null==(l=this.series[d])?void 0:l[c])||(null==(o=this.series[d])?void 0:o[c])===null?(v=a,A=a):(v=a+v/f,A=a+A/f,y=a+m.h/f,w=a+m.l/f,C=a+m.m/f);let k=h.move(v,S+s/2);n.globals.previousPaths.length>0&&(k=this.getPreviousPath(g,c));let D=[h.move(v,S)+h.line(v,S+s/2)+h.line(y,S+s/2)+h.line(y,S+s/2-s/4)+h.line(y,S+s/2+s/4)+h.line(y,S+s/2)+h.line(v,S+s/2)+h.line(v,S+s)+h.line(C,S+s)+h.line(C,S)+h.line(v+r/2,S),h.move(C,S)+h.line(C,S+s)+h.line(A,S+s)+h.line(A,S+s/2)+h.line(w,S+s/2)+h.line(w,S+s-s/4)+h.line(w,S+s/4)+h.line(w,S+s/2)+h.line(A,S+s/2)+h.line(A,S)+h.line(C,S)+"z"];return k+=h.move(v,S),n.axisFlags.isXNumeric||(t+=i),{pathTo:D,pathFrom:k,x:A,y:t,goalX:this.barHelpers.getGoalValues("x",a,null,d,c,0),barYPosition:S,color:b}}getOHLCValue(e,t){let i=this.w,s=this.coreUtils,a=i=>i[e]&&null!=i[e][t]?s.getLogValAtSeriesIndex(i[e][t],e):0,r=a(i.candleData.seriesCandleH),l=a(i.candleData.seriesCandleO),o=a(i.candleData.seriesCandleM),n=a(i.candleData.seriesCandleC),h=a(i.candleData.seriesCandleL);return{o:this.isBoxPlot?r:l,h:this.isBoxPlot?l:r,m:o,l:this.isBoxPlot?n:h,c:this.isBoxPlot?h:n}}}class tl{constructor(e,t){this.ctx=t,this.w=e}checkColorRange(){let e=this.w,t=!1,i=e.config.plotOptions[e.config.chart.type];return i.colorScale.ranges.length>0&&i.colorScale.ranges.map(e=>{e.from<=0&&(t=!0)}),t}getShadeColor(e,t,i,s){let a=this.w,r=1,l=a.config.plotOptions[e].shadeIntensity,o=this.determineColor(e,t,i);a.globals.hasNegs||s?r=a.config.plotOptions[e].reverseNegativeShade?o.percent<0?o.percent/100*(1.25*l):(1-o.percent/100)*(1.25*l):o.percent<=0?1-(1+o.percent/100)*l:(1-o.percent/100)*l:(r=1-o.percent/100,"treemap"===e&&(r=(1-o.percent/100)*(1.25*l)));let n=o.color,h=new v;if(a.config.plotOptions[e].enableShades)if("dark"===this.w.config.theme.mode){let e=h.shadeColor(-1*r,o.color);n=v.hexToRgba(v.isColorHex(e)?e:v.rgb2hex(e),a.config.fill.opacity)}else{let e=h.shadeColor(r,o.color);n=v.hexToRgba(v.isColorHex(e)?e:v.rgb2hex(e),a.config.fill.opacity)}return{color:n,colorProps:o}}determineColor(e,t,i){let s=this.w,a=s.seriesData.series[t][i],r=s.config.plotOptions[e],l=r.colorScale.inverse?i:t;r.distributed&&"treemap"===s.config.chart.type&&(l=i);let o=s.globals.colors[l],n=null,h=Math.min(...s.seriesData.series[t]),d=Math.max(...s.seriesData.series[t]);r.distributed||"heatmap"!==e||(h=s.globals.minY,d=s.globals.maxY),void 0!==r.colorScale.min&&(h=r.colorScale.min<s.globals.minY?r.colorScale.min:s.globals.minY,d=r.colorScale.max>s.globals.maxY?r.colorScale.max:s.globals.maxY);let c=Math.abs(d)+Math.abs(h),g=100*a/(0===c?c-1e-6:c);return r.colorScale.ranges.length>0&&r.colorScale.ranges.map(e=>{if(a>=e.from&&a<=e.to){o=e.color,n=e.foreColor?e.foreColor:null,h=e.from;let t=Math.abs(d=e.to)+Math.abs(h);g=100*a/(0===t?t-1e-6:t)}}),{color:o,foreColor:n,percent:g}}calculateDataLabels({text:e,x:t,y:i,i:s,j:a,colorProps:r,fontSize:l}){let o=this.w.config.dataLabels,n=new Y(this.w),h=new G(this.w,this.ctx),d=null;if(o.enabled){d=n.group({class:"apexcharts-data-labels"});let c=o.offsetX,g=o.offsetY,p=i+parseFloat(o.style.fontSize)/3+g;h.plotDataLabelsText({x:t+c,y:p,text:e,i:s,j:a,color:r.foreColor,parent:d,fontSize:l,dataLabelsConfig:o})}return d}}class to{constructor(e,t,i){this.ctx=t,this.w=e,this.xRatio=i.xRatio,this.yRatio=i.yRatio,this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.helpers=new tl(e,t),this.rectRadius=this.w.config.plotOptions.heatmap.radius,this.strokeWidth=this.w.config.stroke.show?this.w.config.stroke.width:0}draw(e){let t=this.w,i=new Y(this.w,this.ctx),s=i.group({class:"apexcharts-heatmap"});s.attr("clip-path",`url(#gridRectMask${t.globals.cuid})`);let a=t.layout.gridWidth/t.globals.dataPoints,r=t.layout.gridHeight/t.seriesData.series.length,l=0,o=!1;this.negRange=this.helpers.checkColorRange();let n=e.slice();t.config.yaxis[0].reversed&&(o=!0,n.reverse());for(let h=o?0:n.length-1;o?h<n.length:h>=0;o?h++:h--){let o=i.group({class:"apexcharts-series apexcharts-heatmap-series",seriesName:v.escapeString(t.seriesData.seriesNames[h]),rel:h+1,"data:realIndex":h});if(er.addCollapsedClassToSeries(this.w,o,h),i.setupEventDelegation(o,".apexcharts-heatmap-rect"),t.config.chart.dropShadow.enabled){let e=t.config.chart.dropShadow;new z(this.w).dropShadow(o,e,h)}
903let d=0,c=t.config.plotOptions.heatmap.shadeIntensity,g=0;for(let s=0;s<t.globals.dataPoints;s++){if(t.seriesData.seriesX.length&&!t.globals.allSeriesHasEqualX&&t.globals.minX+t.globals.minXDiff*s<t.seriesData.seriesX[h][g]){d+=a;continue}if(g>=n[h].length)break;let p=this.helpers.getShadeColor(t.config.chart.type,h,g,this.negRange),x=p.color,u=p.colorProps;"image"===t.config.fill.type&&(x=new W(this.w).fillPath({seriesNumber:h,dataPointIndex:g,opacity:t.globals.hasNegs?u.percent<0?1-(1+u.percent/100):c+u.percent/100:u.percent/100,patternID:v.randomId(),width:t.config.fill.image.width?t.config.fill.image.width:a,height:t.config.fill.image.height?t.config.fill.image.height:r}));let f=this.rectRadius,m=i.drawRect(d,l,a,r,f);if(m.attr({cx:d,cy:l}),m.node.classList.add("apexcharts-heatmap-rect"),o.add(m),m.attr({fill:x,i:h,index:h,j:g,val:e[h][g],"stroke-width":this.strokeWidth,stroke:t.config.plotOptions.heatmap.useFillColorAsStroke?x:t.globals.stroke.colors[0],color:x}),t.config.chart.animations.enabled&&!t.globals.dataChanged){let e=1;t.globals.resized||(e=t.config.chart.animations.speed),this.animateHeatMap(m,d,l,a,r,e)}if(t.globals.dataChanged){let e=1;if(this.dynamicAnim.enabled&&t.globals.shouldAnimate){e=this.dynamicAnim.speed;let i=t.globals.previousPaths[h]&&t.globals.previousPaths[h][g]&&t.globals.previousPaths[h][g].color;i||(i="rgba(255, 255, 255, 0)"),this.animateHeatColor(m,v.isColorHex(i)?i:v.rgb2hex(i),v.isColorHex(x)?x:v.rgb2hex(x),e)}}let b=(0,t.config.dataLabels.formatter)(t.seriesData.series[h][g],{value:t.seriesData.series[h][g],seriesIndex:h,dataPointIndex:g,w:t}),y=this.helpers.calculateDataLabels({text:b,x:d+a/2,y:l+r/2,i:h,j:g,colorProps:u,series:n});null!==y&&o.add(y),d+=a,g++}l+=r,s.add(o)}let h=t.globals.yAxisScale[0].result.slice();return t.config.yaxis[0].reversed?h.unshift(""):h.push(""),t.globals.yAxisScale[0].result=h,s}animateHeatMap(e,t,i,s,a,r){let l=new R(this.w);l.animateRect(e,{x:t+s/2,y:i+a/2,width:0,height:0},{x:t,y:i,width:s,height:a},r,()=>{l.animationCompleted(e)})}animateHeatColor(e,t,i,s){e.attr({fill:t}).animate(s).attr({fill:i})}}class tn{constructor(e){this.w=e.w,this.lineCtx=e}sameValueSeriesFix(e,t){let i=this.w;if(("gradient"===i.config.fill.type||"gradient"===i.config.fill.type[e])&&new I(this.lineCtx.w).seriesHaveSameValues(e)){let i=t[e].slice();i[i.length-1]=i[i.length-1]+1e-6,t[e]=i}return t}calculatePoints({series:e,realIndex:t,x:i,y:s,i:a,j:r,prevY:l}){let o=this.w,n=[],h=[],d=this.lineCtx.categoryAxisCorrection+o.config.markers.offsetX;return o.axisFlags.isXNumeric&&(d=(o.seriesData.seriesX[t][0]-o.globals.minX)/this.lineCtx.xRatio+o.config.markers.offsetX),0===r&&(n.push(d),h.push(v.isNumber(e[a][0])?l+o.config.markers.offsetY:null)),n.push(i+o.config.markers.offsetX),h.push(v.isNumber(e[a][r+1])?s+o.config.markers.offsetY:null),{x:n,y:h}}checkPreviousPaths({pathFromLine:e,pathFromArea:t,realIndex:i}){let s=this.w;for(let a=0;a<s.globals.previousPaths.length;a++){let r=s.globals.previousPaths[a];("line"===r.type||"area"===r.type)&&r.paths.length>0&&parseInt(r.realIndex,10)===parseInt(i,10)&&("line"===r.type?(this.lineCtx.appendPathFrom=!1,e=s.globals.previousPaths[a].paths[0].d):"area"===r.type&&(this.lineCtx.appendPathFrom=!1,t=s.globals.previousPaths[a].paths[0].d,s.config.stroke.show&&s.globals.previousPaths[a].paths[1]&&(e=s.globals.previousPaths[a].paths[1].d)))}return{pathFromLine:e,pathFromArea:t}}determineFirstPrevY({i:e,realIndex:t,series:i,prevY:s,lineYPosition:a,translationsIndex:r}){var l,o,n;let h=this.w,d=h.config.chart.stacked&&!h.globals.comboCharts||h.config.chart.stacked&&h.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||(null==(l=this.w.config.series[t])?void 0:l.type)==="bar"||(null==(o=this.w.config.series[t])?void 0:o.type)==="column");if(void 0!==(null==(n=i[e])?void 0:n[0]))s=(a=d&&e>0?this.lineCtx.prevSeriesY[e-1][0]:this.lineCtx.zeroY)-i[e][0]/this.lineCtx.yRatio[r]+(this.lineCtx.isReversed?i[e][0]/this.lineCtx.yRatio[r]:0)*2;else if(d&&e>0&&void 0===i[e][0]){for(let t=e-1;t>=0;t--)if(null!==i[t][0]&&void 0!==i[t][0]){s=a=this.lineCtx.prevSeriesY[t][0];break}}return{prevY:s,lineYPosition:a}}}let th={points(e){let t=(e=>{let t,i,s,a,r=function(e){let t=[],i=e[0],s=e[1],a=t[0]=td(i,s),r=1;for(let l=e.length-1;r<l;r++)i=s,s=e[r+1],t[r]=(a+(a=td(i,s)))*.5;return t[r]=a,t}(e),l=e.length-1,o=[];for(let o=0;o<l;o++)1e-6>
903Math.abs(s=td(e[o],e[o+1]))?r[o]=r[o+1]=0:(a=(t=r[o]/s)*t+(i=r[o+1]/s)*i)>9&&(a=3*s/Math.sqrt(a),r[o]=a*t,r[o+1]=a*i);for(let t=0;t<=l;t++)o.push([(a=(e[Math.min(l,t+1)][0]-e[Math.max(0,t-1)][0])/(6*(1+r[t]*r[t])))||0,r[t]*a||0]);return o})(e),i=e[1],s=e[0],a=[],r=t[1],l=t[0];a.push(s,[s[0]+l[0],s[1]+l[1],i[0]-r[0],i[1]-r[1],i[0],i[1]]);for(let i=2,s=t.length;i<s;i++){let s=e[i],r=t[i];a.push([s[0]-r[0],s[1]-r[1],s[0],s[1]])}return a},slice(e,t,i){let s=e.slice(t,i);if(t){if(i-t>1&&s[1].length<6){let e=s[0].length;s[1]=[2*s[0][e-2]-s[0][e-4],2*s[0][e-1]-s[0][e-3]].concat(s[1])}s[0]=s[0].slice(-2)}return s}};function td(e,t){return(t[1]-e[1])/(t[0]-e[0])}class tc{constructor(e,t,i,s){this.ctx=t,this.w=e,this.xyRatios=i,this.xRatio=0,this.yRatio=[],this.zRatio=0,this.baseLineY=[],this.pointsChart="bubble"===this.w.config.chart.type||"scatter"===this.w.config.chart.type||s,this.scatter=new $(this.w,this.ctx),this.noNegatives=this.w.globals.minX===Number.MAX_VALUE,this.lineHelpers=new tn(this),this.markers=new _(this.w,this.ctx),this.prevSeriesY=[],this.categoryAxisCorrection=0,this.yaxisIndex=0,this.xDivision=0,this.zeroY=0,this.areaBottomY=0,this.strokeWidth=0,this.isReversed=!1,this.appendPathFrom=!1,this.elSeries=null,this.elPointsMain=null,this.elDataLabelsWrap=null}draw(e,t,i,s){var a;let r=this.w,l=new Y(this.w),o=r.globals.comboCharts?t:r.config.chart.type,n=l.group({class:`apexcharts-${o}-series apexcharts-plot-series`}),h=new I(this.w);this.yRatio=this.xyRatios.yRatio,this.zRatio=this.xyRatios.zRatio,this.xRatio=this.xyRatios.xRatio,this.baseLineY=this.xyRatios.baseLineY,e=h.getLogSeries(e),this.yRatio=h.getLogYRatios(this.yRatio),this.prevSeriesY=[];let g=[];for(let t=0;t<e.length;t++){let a;e=this.lineHelpers.sameValueSeriesFix(t,e);let l=r.globals.comboCharts?i[t]:t,n=this.yRatio.length>1?l:0;this._initSerieVariables(e,t,l);let h=[],p=[],x=[],u=r.globals.padHorizontal+this.categoryAxisCorrection,f=[],m=[];er.addCollapsedClassToSeries(this.w,this.elSeries,l),r.axisFlags.isXNumeric&&r.seriesData.seriesX.length>0&&(u=(r.seriesData.seriesX[l][0]-r.globals.minX)/this.xRatio),x.push(u);let b=u,y=this.zeroY,w=this.zeroY;y=this.lineHelpers.determineFirstPrevY({i:t,realIndex:l,series:e,prevY:y,lineYPosition:0,translationsIndex:n}).prevY,"monotoneCubic"===r.config.stroke.curve&&null===e[t][0]?h.push(null):h.push(y);let v=y;"rangeArea"===o&&(a=w=this.lineHelpers.determineFirstPrevY({i:t,realIndex:l,series:s,prevY:w,lineYPosition:0,translationsIndex:n}).prevY,p.push(null!==h[0]?w:null));let A=this._calculatePathsFrom({type:o,series:e,i:t,realIndex:l,translationsIndex:n,prevX:b,prevY:y,prevY2:w}),C=[h[0]],S=[p[0]],k={type:o,series:e,realIndex:l,translationsIndex:n,i:t,x:u,y:1,pX:b,pY:v,pathsFrom:A,linePaths:f,areaPaths:m,seriesIndex:i,lineYPosition:0,xArrj:x,yArrj:h,y2Arrj:p,seriesRangeEnd:s},D=this._iterateOverDataPoints(c(d({},k),{iterations:"rangeArea"===o?e[t].length-1:void 0,isRangeStart:!0}));if("rangeArea"===o){let e=this._calculatePathsFrom({series:s,i:t,realIndex:l,prevX:b,prevY:w}),i=this._iterateOverDataPoints(c(d({},k),{series:s,xArrj:[u],yArrj:C,y2Arrj:S,pY:a,areaPaths:D.areaPaths,pathsFrom:e,iterations:s[t].length-1,isRangeStart:!1})),r=D.linePaths.length/2;for(let e=0;e<r;e++)D.linePaths[e]=i.linePaths[e+r]+D.linePaths[e];D.linePaths.splice(r),D.pathFromLine=i.pathFromLine+D.pathFromLine}else D.pathFromArea+="z";this._handlePaths({type:o,realIndex:l,i:t,paths:D}),this.elSeries.add(this.elPointsMain),this.elSeries.add(this.elDataLabelsWrap),g.push(this.elSeries)}if(void 0!==(null==(a=r.config.series[0])?void 0:a.zIndex)&&g.sort((e,t)=>Number(e.node.getAttribute("zIndex"))-Number(t.node.getAttribute("zIndex"))),r.config.chart.stacked)for(let e=g.length-1;e>=0;e--)n.add(g[e]);else for(let e=0;e<g.length;e++)n.add(g[e]);return n}_initSerieVariables(e,t,i){let s=this.w,a=new Y(this.w);this.xDivision=s.layout.gridWidth/(s.globals.dataPoints-("on"===s.config.xaxis.tickPlacement)),this.strokeWidth=Array.isArray(s.config.stroke.width)?s.config.stroke.width[i]:s.config.stroke.width;let r=0;this.yRatio.length>1&&(this.yaxisIndex=s.globals.seriesYAxisReverseMap[i],r=i),this.isReversed=s.config.yaxis[this.yaxisIndex]&&s.config.yaxis[this.yaxisIndex].reversed,this.zeroY=s.layout.gridHeight-this.baseLineY[r]-(this.isReversed?s.layout.gridHeight:0)+(this.isReversed?2*this.baseLineY[r]:0),this.areaBottomY=this.zeroY,(this.zeroY>s.layout.gridHeight||"end"===s.config.plotOptions.area.fillTo)&&(this.areaBottomY=s.layout.gridHeight),this.categoryAxisCorrection=this.xDivision/2;let l=s.config.series[i];if(this.elSeries=a.group({class:"apexcharts-series",zIndex:void 0!==l.zIndex?l.zIndex:i,seriesName:v.escapeString(s.seriesData.seriesNames[i])}),this.elPointsMain=a.group({class:"apexcharts-series-markers-wrap","data:realIndex":i}),s.globals.hasNullValues){let e=this.markers.plotChartMarkers({pointsPos:{x:[0],y:[s.layout.gridHeight+s.globals.markers.largestSize]}
903,seriesIndex:t,j:0,pSize:.1,alwaysDrawMarker:!0,isVirtualPoint:!0});null!==e&&this.elPointsMain.add(e)}this.elDataLabelsWrap=a.group({class:"apexcharts-datalabels","data:realIndex":i});let o=e[t].length===s.globals.dataPoints;this.elSeries.attr({"data:longestSeries":o,rel:t+1,"data:realIndex":i}),this.appendPathFrom=!0}_calculatePathsFrom({type:e,series:t,i,realIndex:s,translationsIndex:a,prevX:r,prevY:l,prevY2:o}){let n,h,d,c,g=this.w,p=new Y(this.w);if(null===t[i][0]){for(let e=0;e<t[i].length;e++)if(null!==t[i][e]){r=this.xDivision*e,l=this.zeroY-t[i][e]/this.yRatio[a],n=p.move(r,l),h=p.move(r,this.areaBottomY);break}}else n=p.move(r,l),"rangeArea"===e&&(n=p.move(r,o)+p.line(r,l)),h=p.move(r,this.areaBottomY)+p.line(r,l);if(d=p.move(0,this.areaBottomY)+p.line(0,this.areaBottomY),c=p.move(0,this.areaBottomY)+p.line(0,this.areaBottomY),g.globals.previousPaths.length>0){let e=this.lineHelpers.checkPreviousPaths({pathFromLine:d,pathFromArea:c,realIndex:s});d=e.pathFromLine,c=e.pathFromArea}return{prevX:r,prevY:l,linePath:n,areaPath:h,pathFromLine:d,pathFromArea:c}}_handlePaths({type:e,realIndex:t,i,paths:s}){let a=this.w,r=new Y(this.w),l=new W(this.w);this.prevSeriesY.push(s.yArrj),a.globals.seriesXvalues[t]=s.xArrj,a.globals.seriesYvalues[t]=s.yArrj;let o=a.config.forecastDataPoints;if(o.count>0&&"rangeArea"!==e){let e=a.globals.seriesXvalues[t][a.globals.seriesXvalues[t].length-o.count-1],i=r.drawRect(e,0,a.layout.gridWidth,a.layout.gridHeight,0);a.dom.elForecastMask.appendChild(i.node);let s=r.drawRect(0,0,e,a.layout.gridHeight,0);a.dom.elNonForecastMask.appendChild(s.node)}this.pointsChart||a.globals.delayedElements.push({el:this.elPointsMain.node,index:t});let n={i,realIndex:t,animationDelay:i,initialSpeed:a.config.chart.animations.speed,dataChangeSpeed:a.config.chart.animations.dynamicAnimation.speed,className:`apexcharts-${e}`};if("area"===e){let e=l.fillPath({seriesNumber:t});for(let t=0;t<s.areaPaths.length;t++){let i=r.renderPaths(c(d({},n),{pathFrom:s.pathFromArea,pathTo:s.areaPaths[t],stroke:"none",strokeWidth:0,strokeLineCap:null,fill:e}));this.elSeries.add(i)}}if(a.config.stroke.show&&!this.pointsChart){let h=null;if("line"===e)h=l.fillPath({seriesNumber:t,i});else if("solid"===a.config.stroke.fill.type)h=a.globals.stroke.colors[t];else{let e=a.config.fill;a.config.fill=a.config.stroke.fill,h=l.fillPath({seriesNumber:t,i}),a.config.fill=e}for(let i=0;i<s.linePaths.length;i++){let g=h;"rangeArea"===e&&(g=l.fillPath({seriesNumber:t}));let p=c(d({},n),{pathFrom:s.pathFromLine,pathTo:s.linePaths[i],stroke:h,strokeWidth:this.strokeWidth,strokeLineCap:a.config.stroke.lineCap,fill:"rangeArea"===e?g:"none"}),x=r.renderPaths(p);if(this.elSeries.add(x),x.attr("fill-rule","evenodd"),o.count>0&&"rangeArea"!==e){let e=r.renderPaths(p);e.node.setAttribute("stroke-dasharray",o.dashArray),o.strokeWidth&&e.node.setAttribute("stroke-width",o.strokeWidth),this.elSeries.add(e),e.attr("clip-path",`url(#forecastMask${a.globals.cuid})`),x.attr("clip-path",`url(#nonForecastMask${a.globals.cuid})`)}}}}_iterateOverDataPoints({type:e,series:t,iterations:i,realIndex:s,translationsIndex:a,i:r,x:l,y:o,pX:n,pY:h,pathsFrom:d,linePaths:c,areaPaths:g,seriesIndex:p,lineYPosition:x,xArrj:u,yArrj:f,y2Arrj:m,isRangeStart:b,seriesRangeEnd:y}){var w,A;let C,S=this.w,k=new Y(this.w),D=this.yRatio,{prevY:L,linePath:M,areaPath:P,pathFromLine:E,pathFromArea:T}=d,F=v.isNumber(S.globals.minYArr[s])?S.globals.minYArr[s]:S.globals.minY;i||(i=S.globals.dataPoints>1?S.globals.dataPoints-1:S.globals.dataPoints);let X=(e,t)=>t-e/D[a]+(this.isReversed?e/D[a]:0)*2,I=o,R=S.config.chart.stacked&&!S.globals.comboCharts||S.config.chart.stacked&&S.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||(null==(w=this.w.config.series[s])?void 0:w.type)==="bar"||(null==(A=this.w.config.series[s])?void 0:A.type)==="column"),z=S.config.stroke.curve;Array.isArray(z)&&(z=Array.isArray(p)?z[p[r]]:z[r]);let B=0;for(let a=0;a<i&&0!==t[r].length;a++){let d=void 0===t[r][a+1]||null===t[r][a+1];if(S.axisFlags.isXNumeric){let e=S.seriesData.seriesX[s][a+1];void 0===S.seriesData.seriesX[s][a+1]&&(e=S.seriesData.seriesX[s][i-1]),l=(e-S.globals.minX)/this.xRatio}else l+=this.xDivision;if(R)if(r>0&&S.globals.collapsedSeries.length<S.config.series.length-1){let e=e=>{for(let t=e;t>0;t--)if(!(S.globals.collapsedSeriesIndices.indexOf((null==p?void 0:p[t])||t)>-1))return t;else t--;return 0};x=this.prevSeriesY[e(r-1)][a+1]}else x=this.zeroY;else x=this.zeroY;d?o=X(F,x):(o=X(t[r][a+1],x),"rangeArea"===e&&(I=X(y[r][a+1],x))),u.push(null===t[r][a+1]?null:l),d&&("smooth"===S.config.stroke.curve||"monotoneCubic"===S.config.stroke.curve)?(f.push(null),m.push(null)):(f.push(o),m.push(I));let w=this.lineHelpers.calculatePoints({series:t,x:l,y:o,realIndex:s,i:r,j:a,prevY:L}),v=this._createPaths({type:e,series:t,i:r,j:a,x:l,y:o,y2:I,xArrj:u,yArrj:f,y2Arrj:m,pX:n,pY:h,pathState:B,segmentStartX:C,linePath:M,areaPath:P,linePaths:c,areaPaths:g,curve:z,isRangeStart:b});g=v.areaPaths,c=v.linePaths,n=v.pX,h=v.pY,B=v.pathState,C=v.segmentStartX,P=v.areaPath,M=v.linePath,this.appendPathFrom&&!S.globals.hasNullValues&&("monotoneCubic"!==z||"rangeArea"!==e)&&(E+=k.line(l,this.areaBottomY),T+=k.line(l,this.areaBottomY)),this.handleNullDataPoints(t,w,r,a,s),this._handleMarkersAndLabels({type:e,pointsPos:w,i:r,j:a,realIndex:s,isRangeStart:b})}return{yArrj:f,xArrj:u,pathFromArea:T,areaPaths:g,pathFromLine:E,linePaths:c,linePath:M,areaPath:P}}_handleMarkersAndLabels({type:e,pointsPos:t,isRangeStart:i,i:s,j:a,realIndex:r}){let l=this.w,o=new G(this.w,this.ctx);if(this.pointsChart)this.scatter.draw(this.elSeries,a,{realIndex:r,pointsPos:t,zRatio:this.zRatio,elParent:this.elPointsMain});else{l.seriesData.series[s].length>1&&this.elPointsMain.node.classList.add("apexcharts-element-hidden");let e=this.markers.plotChartMarkers({pointsPos:t,seriesIndex:r,j:a+1});null!==e&&this.elPointsMain.add(e)}let n=o.drawDataLabel({type:e,isRangeStart:i,pos:t,i:r,j:a+1});null!==n&&this.elDataLabelsWrap.add(n)}_createPaths({type:e,series:t,i,j:s,x:a,y:r,xArrj:l,yArrj:o,y2:n,y2Arrj:h,pX:d,pY:c,pathState:g,segmentStartX:p,linePath:x,areaPath:u,linePaths:f,areaPaths:m,curve:b,isRangeStart:y}){let w=new Y(this.w),v=this.areaBottomY,A="rangeArea"===e,C="rangeArea"===e&&y;switch(b){case"monotoneCubic":{let e=y?o:h;switch(g){case 0:if(null===e[s+1])break;g=1;case 1:if(!(A?l.length===t[i].length:s===t[i].length-2))break;case 2:{let t=y?l:l.slice().reverse(),i=y?e:e.slice().reverse(),s=t.map((e,t)=>[e,i[t]]).filter(e=>null!==e[1]),a=s.length>1?th.points(s):s,r=[];A&&(C?m=s:r=m.reverse());let o=0,n=0;if(((e,t)=>
903{let i,s,a=(i=[],s=0,e.forEach(e=>{null!==e?s++:s>0&&(i.push(s),s=0)}),s>0&&i.push(s),i),r=[];for(let e=0,i=0;e<a.length;i+=a[e++])r[e]=th.slice(t,i,i+a[e]);return r})(i,a).forEach(e=>{o++;let t=(e=>{let t="";for(let i=0;i<e.length;i++){let s=e[i],a=s.length;a>4?t+=`C${s[0]}, ${s[1]}, ${s[2]}, ${s[3]}, ${s[4]}, ${s[5]}`:a>2&&(t+=`S${s[0]}, ${s[1]}, ${s[2]}, ${s[3]}`)}return t})(e),i=n,a=(n+=e.length)-1;C?x=w.move(s[i][0],s[i][1])+t:A?x=w.move(r[i][0],r[i][1])+w.line(s[i][0],s[i][1])+t+w.line(r[a][0],r[a][1]):(u=(x=w.move(s[i][0],s[i][1])+t)+w.line(s[a][0],v)+w.line(s[i][0],v)+"z",m.push(u)),f.push(x)}),A&&o>1&&!C){let e=f.slice(o).reverse();f.splice(o),e.forEach(e=>f.push(e))}g=0}}break}case"smooth":{let e=(a-d)*.35;if(null===t[i][s])g=0;else switch(g){case 0:if(p=d,x=C?w.move(d,h[s])+w.line(d,c):w.move(d,c),u=w.move(d,c),null===t[i][s+1]||void 0===t[i][s+1]){f.push(x),m.push(u);break}if(g=1,s<t[i].length-2){let t=w.curve(d+e,c,a-e,r,a,r);x+=t,u+=t;break}case 1:if(null===t[i][s+1])C?x+=w.line(d,n):x+=w.move(d,c),u+=w.line(d,v)+w.line(p,v)+"z",f.push(x),m.push(u),g=-1;else{let l=w.curve(d+e,c,a-e,r,a,r);x+=l,u+=l,s>=t[i].length-2&&(C&&(x+=w.curve(a,r,a,r,a,n)+w.move(a,n)),u+=w.curve(a,r,a,r,a,v)+w.line(p,v)+"z",f.push(x),m.push(u),g=-1)}}d=a,c=r;break}default:{let e=(e,t,i)=>{let s="";switch(e){case"stepline":s=w.line(t,null,"H")+w.line(null,i,"V");break;case"linestep":s=w.line(null,i,"V")+w.line(t,null,"H");break;case"straight":s=w.line(t,i)}return s};if(null===t[i][s])g=0;else switch(g){case 0:if(p=d,x=C?w.move(d,h[s])+w.line(d,c):w.move(d,c),u=w.move(d,c),null===t[i][s+1]||void 0===t[i][s+1]){f.push(x),m.push(u);break}if(g=1,s<t[i].length-2){let t=e(b,a,r);x+=t,u+=t;break}case 1:if(null===t[i][s+1])C?x+=w.line(d,n):x+=w.move(d,c),u+=w.line(d,v)+w.line(p,v)+"z",f.push(x),m.push(u),g=-1;else{let l=e(b,a,r);x+=l,u+=l,s>=t[i].length-2&&(C&&(x+=w.line(a,n)),u+=w.line(a,v)+w.line(p,v)+"z",f.push(x),m.push(u),g=-1)}}d=a,c=r}}return{linePaths:f,areaPaths:m,pX:d,pY:c,pathState:g,segmentStartX:p,linePath:x,areaPath:u}}handleNullDataPoints(e,t,i,s,a){let r=this.w;if(null===e[i][s]&&r.config.markers.showNullDataPoints||1===e[i].length){let e=this.strokeWidth-r.config.markers.strokeWidth/2;e>0||(e=0);let i=this.markers.plotChartMarkers({pointsPos:t,seriesIndex:a,j:s+1,pSize:e,alwaysDrawMarker:!0});null!==i&&this.elPointsMain.add(i)}}}class tg{constructor(e){this.w=e}drawYAxisTexts(e,t,i,s){let a=this.w,r=a.config.yaxis[0],l=a.formatters.yLabelFormatters[0];return new Y(this.w).drawText({x:e+r.labels.offsetX,y:t+r.labels.offsetY,text:l(s,i),textAnchor:"middle",fontSize:r.labels.style.fontSize,fontFamily:r.labels.style.fontFamily,foreColor:Array.isArray(r.labels.style.colors)?r.labels.style.colors[i]:r.labels.style.colors})}}class tp{constructor(e,t){this.ctx=t,this.w=e,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!==e.globals.stroke.colors?e.globals.stroke.colors:e.globals.colors,this.defaultSize=Math.min(e.layout.gridWidth,e.layout.gridHeight),this.centerY=this.defaultSize/2,this.centerX=e.layout.gridWidth/2,"radialBar"===e.config.chart.type?this.fullAngle=360:this.fullAngle=Math.abs(e.config.plotOptions.pie.endAngle-e.config.plotOptions.pie.startAngle),this.initialAngle=e.config.plotOptions.pie.startAngle%this.fullAngle,e.globals.radialSize=this.defaultSize/2.05-e.config.stroke.width-(e.config.chart.sparkline.enabled?0:e.config.chart.dropShadow.blur),this.donutSize=e.globals.radialSize*parseInt(e.config.plotOptions.pie.donut.size,10)/100;const i=e.config.plotOptions.pie.customScale,s=e.layout.gridWidth/2,a=e.layout.gridHeight/2;this.translateX=s-s*i,this.translateY=a-a*i,this.dataLabelsGroup=new Y(this.w).group({class:"apexcharts-datalabels-group",transform:`translate(${this.translateX}, ${this.translateY}) scale(${i})`}),this.maxY=0,this.sliceLabels=[],this.sliceSizes=[],this.prevSectorAngleArr=[]}draw(e){let t=this.w,i=new Y(this.w),s=i.group({class:"apexcharts-pie"});if(t.globals.noData)return s;let a=0;for(let t=0;t<e.length;t++)a+=v.negToZero(e[t]);let r=[],l=i.group();
9030===a&&(a=1e-5),e.forEach(e=>{this.maxY=Math.max(this.maxY,e)}),t.config.yaxis[0].max&&(this.maxY=t.config.yaxis[0].max),"back"===t.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(s);for(let i=0;i<e.length;i++){let s=this.fullAngle*v.negToZero(e[i])/a;r.push(s),"polarArea"===this.chartType?(r[i]=this.fullAngle/e.length,this.sliceSizes.push(t.globals.radialSize*e[i]/this.maxY)):this.sliceSizes.push(t.globals.radialSize)}if(t.globals.dataChanged){let e,i=0;for(let e=0;e<t.globals.previousPaths.length;e++)i+=v.negToZero(t.globals.previousPaths[e]);for(let s=0;s<t.globals.previousPaths.length;s++)e=this.fullAngle*v.negToZero(t.globals.previousPaths[s])/i,this.prevSectorAngleArr.push(e)}if(this.donutSize<0&&(this.donutSize=0),"donut"===this.chartType){let e=i.drawCircle(this.donutSize);e.attr({cx:this.centerX,cy:this.centerY,fill:t.config.plotOptions.pie.donut.background?t.config.plotOptions.pie.donut.background:"transparent"}),l.add(e)}let o=this.drawArcs(r,e);if(this.sliceLabels.forEach(e=>{o.add(e)}),l.attr({transform:`translate(${this.translateX}, ${this.translateY}) scale(${t.config.plotOptions.pie.customScale})`}),l.add(o),s.add(l),this.donutDataLabels.show){let e=this.renderInnerDataLabels(this.dataLabelsGroup,this.donutDataLabels,{hollowSize:this.donutSize,centerX:this.centerX,centerY:this.centerY,opacity:this.donutDataLabels.show});s.add(e)}return"front"===t.config.grid.position&&"polarArea"===this.chartType&&this.drawPolarElements(s),s}drawArcs(e,t){let i=this.w,s=new z(this.w),a=new Y(this.w),r=new W(this.w),l=a.group({class:"apexcharts-slices"}),o=this.initialAngle,n=this.initialAngle,h=this.initialAngle,d=this.initialAngle;this.strokeWidth=i.config.stroke.show?i.config.stroke.width:0;for(let c=0;c<e.length;c++){let g=a.group({class:"apexcharts-series apexcharts-pie-series",seriesName:v.escapeString(i.seriesData.seriesNames[c]),rel:c+1,"data:realIndex":c});l.add(g),o=h,n=d,h=o+e[c],d=n+this.prevSectorAngleArr[c];let p=h<o?this.fullAngle+h-o:h-o,x=r.fillPath({seriesNumber:c,size:this.sliceSizes[c],value:t[c]}),u=this.getChangedPath(n,d),f=a.drawPath({d:u,stroke:Array.isArray(this.lineColorArr)?this.lineColorArr[c]:this.lineColorArr,strokeWidth:0,fill:x,fillOpacity:i.config.fill.opacity,classes:`apexcharts-pie-area apexcharts-${this.chartType.toLowerCase()}-slice-${c}`});if(f.attr({index:0,j:c}),s.setSelectionFilter(f,0,c),i.config.chart.dropShadow.enabled){let e=i.config.chart.dropShadow;s.dropShadow(f,e,c)}this.addListeners(f,this.donutDataLabels);let m={x:0,y:0},b=(o+p/2)%this.fullAngle,y={x:this.centerX,y:this.centerY};"pie"===this.chartType||"polarArea"===this.chartType?(m=v.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize/1.25+i.config.plotOptions.pie.dataLabels.offset,b),y=v.polarToCartesian(this.centerX,this.centerY,i.globals.radialSize/2,b)):"donut"===this.chartType&&(m=v.polarToCartesian(this.centerX,this.centerY,(i.globals.radialSize+this.donutSize)/2+i.config.plotOptions.pie.dataLabels.offset,b),y=v.polarToCartesian(this.centerX,this.centerY,(i.globals.radialSize+this.donutSize)/2,b)),Y.setAttrs(f.node,{"data:angle":p,"data:startAngle":
903o,"data:strokeWidth":this.strokeWidth,"data:value":t[c],"data:cx":y.x,"data:cy":y.y}),g.add(f);let w=0;if(!this.initialAnim||i.globals.resized||i.globals.dataChanged?this.animBeginArr.push(0):(0==(w=p/this.fullAngle*i.config.chart.animations.speed)&&(w=1),this.animDur=w+this.animDur,this.animBeginArr.push(this.animDur)),this.dynamicAnim&&i.globals.dataChanged?this.animatePaths(f,{size:this.sliceSizes[c],endAngle:h,startAngle:o,prevStartAngle:n,prevEndAngle:d,animateStartingPos:!0,i:c,animBeginArr:this.animBeginArr,shouldSetPrevPaths:!0,dur:i.config.chart.animations.dynamicAnimation.speed}):this.animatePaths(f,{size:this.sliceSizes[c],endAngle:h,startAngle:o,i:c,totalItems:e.length-1,animBeginArr:this.animBeginArr,dur:w}),i.config.plotOptions.pie.expandOnClick&&"polarArea"!==this.chartType&&f.node.addEventListener("mouseup",this.pieClicked.bind(this,c)),void 0!==i.interact.selectedDataPoints[0]&&i.interact.selectedDataPoints[0].indexOf(c)>-1&&this.pieClicked(c),i.config.dataLabels.enabled){let t=m.x,r=m.y,l=100*p/this.fullAngle+"%";if(0!==p&&i.config.plotOptions.pie.dataLabels.minAngleToShowLabel<e[c]){let e=i.config.dataLabels.formatter;void 0!==e&&(l=e(i.globals.seriesPercent[c][0],{seriesIndex:c,w:i}));let o=i.globals.dataLabels.style.colors[c],n=a.group({class:"apexcharts-datalabels"}),h=a.drawText({x:t,y:r,text:l,textAnchor:"middle",fontSize:i.config.dataLabels.style.fontSize,fontFamily:i.config.dataLabels.style.fontFamily,fontWeight:i.config.dataLabels.style.fontWeight,foreColor:o});if(n.add(h),i.config.dataLabels.dropShadow.enabled){let e=i.config.dataLabels.dropShadow;s.dropShadow(h,e)}h.node.classList.add("apexcharts-pie-label"),i.config.chart.animations.animate&&!1===i.globals.resized&&(h.node.classList.add("apexcharts-pie-label-delay"),h.node.style.animationDelay=i.config.chart.animations.speed/940+"s"),this.sliceLabels.push(n)}}}return l}addListeners(e,t){let i=new Y(this.w);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.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)))}animatePaths(e,t){let i=this.w,s=t.endAngle<t.startAngle?this.fullAngle+t.endAngle-t.startAngle:t.endAngle-t.startAngle,a=s,r=t.startAngle,l=t.startAngle;void 0!==t.prevStartAngle&&void 0!==t.prevEndAngle&&(r=t.prevEndAngle,a=t.prevEndAngle<t.prevStartAngle?this.fullAngle+t.prevEndAngle-t.prevStartAngle:t.prevEndAngle-t.prevStartAngle),t.i===i.config.series.length-1&&(s+l>this.fullAngle?t.endAngle=t.endAngle-(s+l):s+l<this.fullAngle&&(t.endAngle=t.endAngle+(this.fullAngle-(s+l)))),s===this.fullAngle&&(s=this.fullAngle-.01),this.animateArc(e,r,l,s,a,t)}animateArc(e,t,i,s,a,r){let l,o=this,n=this.w,h=new R(this.w),d=r.size;(isNaN(t)||isNaN(a))&&(t=i,a=s,r.dur=0);let c=s,g=i,p=t<i?this.fullAngle+t-i:t-i;n.globals.dataChanged&&r.shouldSetPrevPaths&&r.prevEndAngle&&(l=o.getPiePath({me:o,startAngle:r.prevStartAngle,angle:r.prevEndAngle<r.prevStartAngle?this.fullAngle+r.prevEndAngle-r.prevStartAngle:r.prevEndAngle-r.prevStartAngle,size:d}),e.attr({d:l})),0!==r.dur?e.animate(r.dur,r.animBeginArr[r.i]).after(function(){("pie"===o.chartType||"donut"===o.chartType||"polarArea"===o.chartType)&&this.animate(n.config.chart.animations.dynamicAnimation.speed).attr({"stroke-width":o.strokeWidth}),r.i===n.config.series.length-1&&h.animationCompleted(e)}).during(n=>{c=p+(s-p)*n,r.animateStartingPos&&(c=a+(s-a)*n,g=t-a+(i-(t-a))*n),l=o.getPiePath({me:o,startAngle:g,angle:c,size:d}),e.node.setAttribute("data:pathOrig",l),e.attr({d:l})}):(l=o.getPiePath({me:o,startAngle:g,angle:s,size:d}),r.isTrack||(n.globals.animationEnded=!0),e.node.setAttribute("data:pathOrig",l),e.attr({d:l,"stroke-width":o.strokeWidth}))}pieClicked(e){let t=this.w,i=this.sliceSizes[e]+4*!!t.config.plotOptions.pie.expandOnClick,s=t.dom.Paper.findOne(`.apexcharts-${this.chartType.toLowerCase()}-slice-${e}`);if("true"===s.attr("data:pieClicked")){s.attr({"data:pieClicked":"false"}),this.revertDataLabelsInner();let e=s.attr("data:pathOrig");s.attr({d:e});return}{let i=t.dom.baseEl.getElementsByClassName("apexcharts-pie-area");Array.prototype.forEach.call(i,e=>
903{e.setAttribute("data:pieClicked","false");let t=e.getAttribute("data:pathOrig");t&&e.setAttribute("d",t)}),t.interact.capturedDataPointIndex=e,s.attr("data:pieClicked","true")}let a=parseInt(s.attr("data:startAngle"),10),r=parseInt(s.attr("data:angle"),10),l=this.getPiePath({me:this,startAngle:a,angle:r,size:i});360!==r&&s.plot(l)}getChangedPath(e,t){let i="";return this.dynamicAnim&&this.w.globals.dataChanged&&(i=this.getPiePath({me:this,startAngle:e,angle:t-e,size:this.size})),i}getPiePath({me:e,startAngle:t,angle:i,size:s}){let a,r=new Y(this.w),l=Math.PI*(t-90)/180,o=i+t;Math.ceil(o)>=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle&&(o=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle-.01),Math.ceil(o)>this.fullAngle&&(o-=this.fullAngle);let n=Math.PI*(o-90)/180,h=e.centerX+s*Math.cos(l),d=e.centerY+s*Math.sin(l),c=e.centerX+s*Math.cos(n),g=e.centerY+s*Math.sin(n),p=v.polarToCartesian(e.centerX,e.centerY,e.donutSize,o),x=v.polarToCartesian(e.centerX,e.centerY,e.donutSize,t),u=+(i>180),f=["M",h,d,"A",s,s,0,u,1,c,g];return a="donut"===e.chartType?[...f,"L",p.x,p.y,"A",e.donutSize,e.donutSize,0,u,0,x.x,x.y,"L",h,d,"z"].join(" "):"pie"===e.chartType||"polarArea"===e.chartType?[...f,"L",e.centerX,e.centerY,"L",h,d].join(" "):[...f].join(" "),r.roundPathCorners(a,2*this.strokeWidth)}drawPolarElements(e){let t=this.w,i=new q(this.w),s=new Y(this.w),a=new tg(this.w),r=s.group(),l=s.group(),o=i.niceScale(0,Math.ceil(this.maxY),0),n=o.result.reverse(),h=o.result.length;this.maxY=o.niceMax;let d=t.globals.radialSize,c=d/(h-1);for(let e=0;e<h-1;e++){let i=s.drawCircle(d);if(i.attr({cx:this.centerX,cy:this.centerY,fill:"none","stroke-width":t.config.plotOptions.polarArea.r
903ings.strokeWidth,stroke:t.config.plotOptions.polarArea.rings.strokeColor}),t.config.yaxis[0].show){let i=a.drawYAxisTexts(this.centerX,this.centerY-d+parseInt(t.config.yaxis[0].labels.style.fontSize,10)/2,e,n[e]);l.add(i)}r.add(i),d-=c}this.drawSpokes(e),e.add(r),e.add(l)}renderInnerDataLabels(e,t,i){let s,a,r=this.w,l=new Y(this.w),o=t.total.show;e.node.innerHTML="",e.node.style.opacity=i.opacity;let n=i.centerX,h=this.donutDataLabels.total.label?i.centerY:i.centerY-i.centerY/6;s=void 0===t.name.color?r.globals.colors[0]:t.name.color;let d=t.name.fontSize,c=t.name.fontFamily,g=t.name.fontWeight;a=void 0===t.value.color?r.config.chart.foreColor:t.value.color;let p=t.value.formatter,x="",u="";if(o?(s=t.total.color,d=t.total.fontSize,c=t.total.fontFamily,g=t.total.fontWeight,u=this.donutDataLabels.total.label?t.total.label:"",x=t.total.formatter(r)):1===r.seriesData.series.length&&(x=p(r.seriesData.series[0],r),u=r.seriesData.seriesNames[0]),u&&(u=t.name.formatter(u,t.total.show,r)),t.name.show){let i=l.drawText({x:n,y:h+parseFloat(t.name.offsetY),text:u,textAnchor:"middle",foreColor:s,fontSize:d,fontWeight:g,fontFamily:c});i.node.classList.add("apexcharts-datalabel-label"),e.add(i)}if(t.value.show){let i=t.name.show?parseFloat(t.value.offsetY)+16:t.value.offsetY,s=l.drawText({x:n,y:h+i,text:x,textAnchor:"middle",foreColor:a,fontWeight:t.value.fontWeight,fontSize:t.value.fontSize,fontFamily:t.value.fontFamily});s.node.classList.add("apexcharts-datalabel-value"),e.add(s)}return e}printInnerLabels(e,t,i,s){let a,r=this.w;s?a=void 0===e.name.color?r.globals.colors[parseInt(s.parentNode.getAttribute("rel"),10)-1]:e.name.color:r.seriesData.series.length>1&&e.total.show&&(a=e.total.color);let l=r.dom.baseEl.querySelector(".apexcharts-datalabel-label"),o=r.dom.baseEl.querySelector(".apexcharts-datalabel-value");i=(0,e.value.formatter)(i,r),s||"function"!=typeof e.total.formatter||(i=e.total.formatter(r));let n=t===e.total.label;t=this.donutDataLabels.total.label?e.name.formatter(t,n,r):"",null!==l&&(l.textContent=t),null!==o&&(o.textContent=i),null!==l&&(l.style.fill=a)}printDataLabelsInner(e,t){let i=this.w,s=e.getAttribute("data:value"),a=i.seriesData.seriesNames[parseInt(e.parentNode.getAttribute("rel"),10)-1];i.seriesData.series.length>1&&this.printInnerLabels(t,a,s,e);let r=i.dom.baseEl.querySelector(".apexcharts-datalabels-group");null!==r&&(r.style.opacity="1")}drawSpokes(e){let t=this.w,i=new Y(this.w),s=t.config.plotOptions.polarArea.spokes;if(0===s.strokeWidth)return;let a=[],r=360/t.seriesData.series.length;for(let e=0;e<t.seriesData.series.length;e++)a.push(v.polarToCartesian(this.centerX,this.centerY,t.globals.radialSize,t.config.plotOptions.pie.startAngle+r*e));a.forEach((t,a)=>{let r=i.drawLine(t.x,t.y,this.centerX,this.centerY,Array.isArray(s.connectorColors)?s.connectorColors[a]:s.connectorColors);e.add(r)})}revertDataLabelsInner(){let e=this.w;if(this.donutDataLabels.show){let t=e.dom.Paper.findOne(".apexcharts-datalabels-group"),i=this.renderInnerDataLabels(t,this.donutDataLabels,{hollowSize:this.donutSize,centerX:this.centerX,centerY:this.centerY,opacity:this.donutDataLabels.show});e.dom.Paper.findOne(".apexcharts-radialbar, .apexcharts-pie").add(i)}}}class tx{constructor(e,t){this.ctx=t,this.w=e,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,this.graphics=new Y(this.w),this.lineColorArr=void 0!==e.globals.stroke.colors?e.globals.stroke.colors:e.globals.colors,this.defaultSize=e.globals.svgHeight<e.globals.svgWidth?e.layout.gridHeight:e.layout.gridWidth,this.isLog=e.config.yaxis[0].logarithmic,this.logBase=e.config.yaxis[0].logBase,this.coreUtils=new I(this.w),this.maxValue=this.isLog?this.coreUtils.getLogVal(this.logBase,e.globals.maxY,0):e.globals.maxY,this.minValue=this.isLog?this.coreUtils.getLogVal(this.logBase,this.w.globals.minY,0):e.globals.minY,this.polygons=e.config.plotOptions.radar.polygons,this.strokeWidth=e.config.stroke.show?e.config.stroke.width:0,this.size=this.defaultSize/2.1-this.strokeWidth-e.config.chart.dropShadow.blur,e.config.xaxis.labels.show&&(this.size=this.size-e.layout.xAxisLabelsWidth/1.75),void 0!==e.config.plotOptions.radar.size&&(this.size=e.config.plotOptions.radar.size),this.dataRadiusOfPercent=[],this.dataRadius=[],this.angleArr=[],this.dataPointsLen=0,this.disAngle=0,this.yaxisLabelsTextsPos=[]}draw(e){let t=this.w,i=new W(this.w),s=[],a=new G(this.w,this.ctx);e.length&&(this.dataPointsLen=e[t.globals.maxValsInArrayIndex].length),this.disAngle=2*Math.PI/this.dataPointsLen;let r=t.layout.gridWidth/2,l=t.layout.gridHeight/2,o=r+t.config.plotOptions.radar.offsetX,n=l+t.config.plotOptions.radar.offsetY,h=this.graphics.group({class:"apexcharts-radar-series apexcharts-plot-series",transform:`translate(${o||0}, ${n||0})`}),g=[],p=null,x=null;if(this.yaxisLabels=this.graphics.group({class:"apexcharts-yaxis"}),e.forEach((e,r)=>{let l=e.length===t.globals.dataPoints,o=this.graphics.group().attr({class:"apexcharts-series","data:longestSeries":l,seriesName:v.escapeString(t.seriesData.seriesNames[r]),rel:r+1,"data:realIndex":r});this.dataRadiusOfPercent[r]=[],this.dataRadius[r]=[],this.angleArr[r]=[],e.forEach((e,t)=>{let i=Math.abs(this.maxValue-this.minValue);e-=this.minValue,this.isLog&&(e=this.coreUtils.getLogVal(this.logBase,e,0)),this.dataRadiusOfPercent[r][t]=e/i,this.dataRadius[r][t]=this.dataRadiusOfPercent[r][t]*this.size,this.angleArr[r][t]=t*this.disAngle}),g=this.getDataPointsPos(this.dataRadius[r],this.angleArr[r]);let n=this.createPaths(g,{x:0,y:0});p=this.graphics.group({class:"apexcharts-series-markers-wrap apexcharts-element-hidden"}),x=this.graphics.group({class:"apexcharts-datalabels","data:realIndex":r}),t.globals.delayedElements.push({el:p.node,index:r});let h={i:r,realIndex:r,animationDelay:r,initialSpeed:t.config.chart.animations.speed,dataChangeSpeed:t.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-radar",shouldClipToGrid:!1,bindEventsOnPaths:!1,stroke:t.globals.stroke.colors[r],strokeLineCap:t.config.stroke.lineCap},u=null;t.globals.previousPaths.length>0&&(u=this.getPreviousPath(r));for(let e=0;e<n.linePathsTo.length;e++){let s=this.graphics.renderPaths(c(d({},h),{pathFrom:null===u?n.linePathsFrom[e]:u,pathTo:n.linePathsTo[e],strokeWidth:Array.isArray(this.strokeWidth)?this.strokeWidth[r]:this.strokeWidth,fill:"none",drawShadow:!1}));o.add(s);let a=i.fillPath({seriesNumber:r}),l=this.graphics.renderPaths(c(d({},h),{pathFrom:null===u?n.areaPathsFrom[e]:u,pathTo:n.areaPathsTo[e],strokeWidth:0,fill:a,drawShadow:!1}));if(t.config.chart.dropShadow.enabled){let e=new z(this.w),i=t.config.chart.dropShadow;e.dropShadow(l,Object.assign({},i,{noUserSpaceOnUse:!0}),r)}o.add(l)}e.forEach((e,i)=>{let s=new _(this.w,this.ctx).getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:r,dataPointIndex:i}),l=this.graphics.drawMarker(g[i].x,g[i].y,s);l.attr("rel",i),l.attr("j",i),l.attr("index",r),l.node.setAttribute("default-marker-size",s.pSize);let n=this.graphics.group({class:"apexcharts-series-markers"});n&&n.add(l),p.add(n),o.add(p);let h=t.config.dataLabels;if(h.enabled){let e=h.formatter(t.seriesData.series[r][i],{seriesIndex:r,dataPointIndex:i,w:t});a.plotDataLabelsText({x:g[i].x,y:g[i].y,text:e,textAnchor:"middle",i:r,j:r,parent:x,offsetCorrection:!1,dataLabelsConfig:d({},h)})}o.add(x)}),s.push(o)}),this.drawPolygons({parent:h}),t.config.xaxis.labels.show){let e=this.drawXAxisTexts();h.add(e)}
903return s.forEach(e=>{h.add(e)}),h.add(this.yaxisLabels),h}drawPolygons(e){let t=this.w,{parent:i}=e,s=new tg(this.w),a=t.globals.yAxisScale[0].result.reverse(),r=a.length,l=[],o=this.size/(r-1);for(let e=0;e<r;e++)l[e]=o*e;l.reverse();let n=[],h=[];l.forEach((e,t)=>{let i=v.getPolygonPos(e,this.dataPointsLen),s="";i.forEach((e,i)=>{if(0===t){let t=this.graphics.drawLine(e.x,e.y,0,0,Array.isArray(this.polygons.connectorColors)?this.polygons.connectorColors[i]:this.polygons.connectorColors);h.push(t)}0===i&&this.yaxisLabelsTextsPos.push({x:e.x,y:e.y}),s+=e.x+","+e.y+" "}),n.push(s)}),n.forEach((e,s)=>{let a=this.polygons.strokeColors,r=this.polygons.strokeWidth,l=this.graphics.drawPolygon(e,Array.isArray(a)?a[s]:a,Array.isArray(r)?r[s]:r,t.globals.radarPolygons.fill.colors[s]);i.add(l)}),h.forEach(e=>{i.add(e)}),t.config.yaxis[0].show&&this.yaxisLabelsTextsPos.forEach((e,t)=>{let i=s.drawYAxisTexts(e.x,e.y,t,a[t]);this.yaxisLabels.add(i)})}drawXAxisTexts(){let e=this.w,t=e.config.xaxis.labels,i=this.graphics.group({class:"apexcharts-xaxis"}),s=v.getPolygonPos(this.size,this.dataPointsLen);return e.labelData.labels.forEach((a,r)=>{let l=e.config.xaxis.labels.formatter,o=new G(this.w,this.ctx);if(s[r]){let n=this.getTextPos(s[r],this.size),h=l(a,{seriesIndex:-1,dataPointIndex:r,w:e});o.plotDataLabelsText({x:n.newX,y:n.newY,text:h,textAnchor:n.textAnchor,i:r,j:r,parent:i,className:"apexcharts-xaxis-label",color:Array.isArray(t.style.colors)&&t.style.colors[r]?t.style.colors[r]:"#a8a8a8",dataLabelsConfig:d({textAnchor:n.textAnchor,dropShadow:{enabled:!1}},t),offsetCorrection:!1}).on("click",t=>{if("function"==typeof e.config.chart.events.xAxisLabelClick){let i=Object.assign({},e,{labelIndex:r});e.config.chart.events.xAxisLabelClick(t,this.ctx,i)}})}}),i}createPaths(e,t){let i=[],s=[],a=[],r=[];if(e.length){s=[this.graphics.move(t.x,t.y)],r=[this.graphics.move(t.x,t.y)];let l=this.graphics.move(e[0].x,e[0].y),o=this.graphics.move(e[0].x,e[0].y);e.forEach((t,i)=>{l+=this.graphics.line(t.x,t.y),o+=this.graphics.line(t.x,t.y),i===e.length-1&&(l+="Z",o+="Z")}),i.push(l),a.push(o)}return{linePathsFrom:s,linePathsTo:i,areaPathsFrom:r,areaPathsTo:a}}getTextPos(e,t){let i="middle",s=e.x,a=e.y;return Math.abs(e.x)>=10?e.x>0?(i="start",s+=10):e.x<0&&(i="end",s-=10):i="middle",Math.abs(e.y)>=t-10&&(e.y<0?a-=10:e.y>0&&(a+=10)),{textAnchor:i,newX:s,newY:a}}getPreviousPath(e){let t=this.w,i=null;for(let s=0;s<t.globals.previousPaths.length;s++){let a=t.globals.previousPaths[s];a.paths.length>0&&parseInt(a.realIndex,10)===parseInt(String(e),10)&&void 0!==t.globals.previousPaths[s].paths[0]&&(i=t.globals.previousPaths[s].paths[0].d)}return i}getDataPointsPos(e,t,i=this.dataPointsLen){e=e||[],t=t||[];let s=[];for(let a=0;a<i;a++){let i={};i.x=e[a]*Math.sin(t[a]),i.y=-e[a]*Math.cos(t[a]),s.push(i)}return s}}class tu extends tp{constructor(e,t){super(e,t),this.ctx=t,this.w=e,this.animBeginArr=[0],this.animDur=0,this.startAngle=e.config.plotOptions.radialBar.startAngle,this.endAngle=e.config.plotOptions.radialBar.endAngle,this.totalAngle=Math.abs(e.config.plotOptions.radialBar.endAngle-e.config.plotOptions.radialBar.startAngle),this.trackStartAngle=e.config.plotOptions.radialBar.track.startAngle,this.trackEndAngle=e.config.plotOptions.radialBar.track.endAngle,this.barLabels=this.w.config.plotOptions.radialBar.barLabels,this.donutDataLabels=this.w.config.plotOptions.radialBar.dataLabels,this.radialDataLabels=this.donutDataLabels,this.trackStartAngle||(this.trackStartAngle=this.startAngle),this.trackEndAngle||(this.trackEndAngle=this.endAngle),360===this.endAngle&&(this.endAngle=359.99),this.margin=parseInt(e.config.plotOptions.radialBar.track.margin,10),this.onBarLabelClick=this.onBarLabelClick.bind(this)}draw(e){let t=this.w,i=new Y(this.w),s=i.group({class:"apexcharts-radialbar"});if(t.globals.noData)return s;let a=i.group(),r=this.defaultSize/2,l=t.layout.gridWidth/2,o=this.defaultSize/2.05;t.config.chart.sparkline.enabled||(o=o-t.config.stroke.width-t.config.chart.dropShadow.blur);let n=t.globals.fill.colors;if(t.config.plotOptions.radialBar.track.show){let t=this.drawTracks({size:o,centerX:l,centerY:r,colorArr:n,series:e});a.add(t)}let h=this.drawArcs({size:o,centerX:l,centerY:r,colorArr:n,series:e}),d=360;t.config.plotOptions.radialBar.startAngle<0&&(d=this.totalAngle);let c=(360-d)/360;if(t.globals.radialSize=o-o*c,this.radialDataLabels.value.show){let e=Math.max(this.radialDataLabels.value.offsetY,this.radialDataLabels.name.offsetY);t.globals.radialSize+=e*c}return a.add(h.g),"front"===t.config.plotOptions.radialBar.hollow.position&&(h.g.add(h.elHollow),h.dataLabels&&h.g.add(h.dataLabels)),s.add(a),s}drawTracks(e){let t=this.w,i=new Y(this.w),s=i.group({class:"apexcharts-tracks"}),a=new z(this.w),r=new W(this.w),l=this.getStrokeWidth(e);e.size=e.size-l/2;for(let o=0;o<e.series.length;o++){let n=i.group({class:"apexcharts-radialbar-track apexcharts-track"});s.add(n),n.attr({rel:o+1}),e.size=e.size-l-this.margin;let h=t.config.plotOptions.radialBar.track,d=r.fillPath({seriesNumber:0,size:e.size,fillColors:Array.isArray(h.background)?h.background[o]:h.background,solid:!0}),c=this.trackStartAngle,g=this.trackEndAngle;Math.abs(g)+Math.abs(c)>=360&&(g=360-Math.abs(this.startAngle)-.1);let p=i.drawPath({d:"",stroke:d,strokeWidth:l*parseInt(h.strokeWidth,10)/100,fill:"none",strokeOpacity:h.opacity,classes:"apexcharts-radialbar-area"});if(h.dropShadow.enabled){let e=h.dropShadow;a.dropShadow(p,e)}n.add(p),p.attr("id","apexcharts-radialbarTrack-"+o),this.animatePaths(p,{centerX:e.centerX,centerY:e.centerY,endAngle:g,startAngle:c,size:e.size,i:o,totalItems:2,animBeginArr:0,dur:0,isTrack:!0})}return s}drawArcs(e){let t=this.w,i=new Y(this.w),s=new W(this.w),a=new z(this.w),r=i.group(),l=this.getStrokeWidth(e);e.size=e.size-l/2;let o=t.config.plotOptions.radialBar.hollow.background,n=e.size-l*e.series.length-this.margin*e.series.length-l*parseInt(t.config.plotOptions.radialBar.track.strokeWidth,10)/100/2,h=n-t.config.plotOptions.radialBar.hollow.margin;void 0!==t.config.plotOptions.radialBar.hollow.image&&(o=this.drawHollowImage(e,r,n,o));let d=this.drawHollow({size:h,centerX:e.centerX,centerY:e.centerY,fill:o||"transparent"});if(t.config.plotOptions.radialBar.hollow.dropShadow.enabled){let e=t.config.plotOptions.radialBar.hollow.dropShadow;a.dropShadow(d,e)}let c=1;!this.radialDataLabels.total.show&&t.seriesData.series.length>1&&(c=0);let g=null;if(this.radialDataLabels.show){let i=t.dom.Paper.findOne(".apexcharts-datalabels-group");g=this.renderInnerDataLabels(i,this.radialDataLabels,{hollowSize:n,centerX:e.centerX,centerY:e.centerY,opacity:c})}"back"===t.config.plotOptions.radialBar.hollow.position&&(r.add(d),g&&r.add(g));let p=!1;t.config.plotOptions.radialBar.inverseOrder&&(p=!0);for(let o=p?e.series.length-1:0;p?o>=0:o<e.series.length;p?o--:o++){let n,h,d=i.group({class:"apexcharts-series apexcharts-radial-series",seriesName:v.escapeString(t.seriesData.seriesNames[o])});r.add(d),d.attr({rel:o+1,"data:realIndex":o}),er.addCollapsedClassToSeries(this.w,d,o),e.size=e.size-l-this.margin;let c=s.fillPath({seriesNumber:o,size:e.size,value:e.series[o]}),g=this.startAngle,p=v.negToZero(e.series[o]>100?100:e.series[o])/100,x=Math.round(this.totalAngle*p)+this.startAngle;t.globals.dataChanged&&(n=this.startAngle,h=Math.round(this.totalAngle*v.negToZero(t.globals.previousPaths[o])/100)+n),Math.abs(x)+Math.abs(g)>360&&(x-=.01),Math.abs(h)+Math.abs(n)>360&&(h-=.01);
903let u=x-g,f=Array.isArray(t.config.stroke.dashArray)?t.config.stroke.dashArray[o]:t.config.stroke.dashArray,m=i.drawPath({d:"",stroke:c,strokeWidth:l,fill:"none",fillOpacity:t.config.fill.opacity,classes:"apexcharts-radialbar-area apexcharts-radialbar-slice-"+o,strokeDashArray:f}),b=g+u/2,y=v.polarToCartesian(e.centerX,e.centerY,e.size,b);if(Y.setAttrs(m.node,{"data:angle":u,"data:value":e.series[o],"data:cx":y.x,"data:cy":y.y}),t.config.chart.dropShadow.enabled){let e=t.config.chart.dropShadow;a.dropShadow(m,e,o)}if(a.setSelectionFilter(m,0,o),this.addListeners(m,this.radialDataLabels),d.add(m),m.attr({index:0,j:o}),this.barLabels.enabled){let s=v.polarToCartesian(e.centerX,e.centerY,e.size,g),a=this.barLabels.formatter(t.seriesData.seriesNames[o],{seriesIndex:o,w:t}),r=["apexcharts-radialbar-label"];this.barLabels.onClick||r.push("apexcharts-no-click");let l=this.barLabels.useSeriesColors?t.globals.colors[o]:t.config.chart.foreColor;l||(l=t.config.chart.foreColor);let n=s.x+this.barLabels.offsetX,h=s.y+this.barLabels.offsetY,c=i.drawText({x:n,y:h,text:a,textAnchor:"end",dominantBaseline:"middle",fontFamily:this.barLabels.fontFamily,fontWeight:this.barLabels.fontWeight,fontSize:this.barLabels.fontSize,foreColor:l,cssClass:r.join(" ")});c.on("click",this.onBarLabelClick),c.attr({rel:o+1}),0!==g&&c.attr({"transform-origin":`${n} ${h}`,transform:`rotate(${g} 0 0)`}),d.add(c)}let w=0;!this.initialAnim||t.globals.resized||t.globals.dataChanged||(w=t.config.chart.animations.speed),t.globals.dataChanged&&(w=t.config.chart.animations.dynamicAnimation.speed),this.animDur=w/(1.2*e.series.length)+this.animDur,this.animBeginArr.push(this.animDur),this.animatePaths(m,{centerX:e.centerX,centerY:e.centerY,endAngle:x,startAngle:g,prevEndAngle:h,prevStartAngle:n,size:e.size,i:o,totalItems:2,animBeginArr:this.animBeginArr,dur:w,shouldSetPrevPaths:!0})}return{g:r,elHollow:d,dataLabels:g}}drawHollow(e){let t=new Y(this.w).drawCircle(2*e.size);return t.attr({class:"apexcharts-radialbar-hollow",cx:e.centerX,cy:e.centerY,r:e.size,fill:e.fill}),t}drawHollowImage(e,t,i,s){let a=this.w,r=new W(this.w),l=v.randomId(),o=a.config.plotOptions.radialBar.hollow.image;if(a.config.plotOptions.radialBar.hollow.imageClipped)r.clippedImgArea({width:i,height:i,image:o,patternID:`pattern${a.globals.cuid}${l}`}),s=`url(#pattern${a.globals.cuid}${l})`;else{let i=a.config.plotOptions.radialBar.hollow.imageWidth,s=a.config.plotOptions.radialBar.hollow.imageHeight;if(void 0===i&&void 0===s){let i=a.dom.Paper.image(o,function(t){this.move(e.centerX-t.width/2+a.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-t.height/2+a.config.plotOptions.radialBar.hollow.imageOffsetY)});t.add(i)}else{let r=a.dom.Paper.image(o,function(){this.move(e.centerX-i/2+a.config.plotOptions.radialBar.hollow.imageOffsetX,e.centerY-s/2+a.config.plotOptions.radialBar.hollow.imageOffsetY),this.size(i,s)});t.add(r)}}return s}getStrokeWidth(e){let t=this.w;return e.size*(100-parseInt(t.config.plotOptions.radialBar.hollow.size,10))/100/(e.series.length+1)-this.margin}onBarLabelClick(e){var t;let i=parseInt(null!=(t=e.target.getAttribute("rel"))?t:"",10)-1,s=this.barLabels.onClick,a=this.w;s&&s(a.seriesData.seriesNames[i],{w:a,seriesIndex:i})}}class tf extends ts{draw(e,t){var i,s,a,r,l,o,n,h,c;let g=this.w,p=new Y(this.w);this.rangeBarOptions=this.w.config.plotOptions.rangeBar,this.series=e,this.seriesRangeStart=g.rangeData.seriesRangeStart,this.seriesRangeEnd=g.rangeData.seriesRangeEnd,this.barHelpers.initVariables(e);let x=p.group({class:"apexcharts-rangebar-series apexcharts-plot-series"});for(let u=0;u<e.length;u++){let f,m,b=g.globals.comboCharts?t[u]:u,{columnGroupIndex:y}=this.barHelpers.getGroupIndex(b),w=p.group({class:"apexcharts-series",seriesName:v.escapeString(g.seriesData.seriesNames[b]),rel:u+1,"data:realIndex":b});er.addCollapsedClassToSeries(this.w,w,b),e[u].length>0&&(this.visibleI=this.visibleI+1);let A=0;this.yRatio.length>1&&(this.yaxisIndex=g.globals.seriesYAxisReverseMap[b][0],A=b);let C=this.barHelpers.initialPositions(b),{y:S,zeroW:k,x:D,zeroH:L}=C,M=null!=(i=C.barWidth)?i:0,P=null!=(s=C.barHeight)?s:0,E=null!=(a=C.yDivision)?a:0,T=null!=(r=C.xDivision)?r:0;m=S,f=D;let F=p.group({class:"apexcharts-datalabels","data:realIndex":b}),X=p.group({class:"apexcharts-rangebar-goals-markers"});for(let t=0;t<g.globals.dataPoints;t++){let i=this.barHelpers.getStrokeWidth(u,t,b),s=this.seriesRangeStart[u][t],a=this.seriesRangeEnd[u][t],r=null,p=null,x=null,v={x:f,y:m,strokeWidth:i,elSeries:w},S=this.seriesLen;if(g.config.plotOptions.bar.rangeBarGroupRows&&(S=1),void 0===(null==(l=g.config.series[u].data)?void 0:l[t]))break;if(this.isHorizontal){x=m+P*this.visibleI;let e=(E-P*S)/2;if(null==(n=null==(o=g.config.series[u].data)?void 0:o[t])?void 0:n.x){let i=this.detectOverlappingBars({i:u,j:t,barYPosition:x,srty:e,barHeight:P,yDivision:E,initPositions:C});P=i.barHeight,x=i.barYPosition}M=(r=this.drawRangeBarPaths(d({indexes:{i:u,j:t,realIndex:b},barHeight:P,barYPosition:x,zeroW:k,yDivision:E,y1:s,y2:a},v))).barWidth}else{g.axisFlags.isXNumeric&&(f=(g.seriesData.seriesX[u][t]-g.globals.minX)/this.xRatio-M/2),p=f+M*this.visibleI;let e=(T-M*S)/2;if(null==(c=null==(h=g.config.series[u].data)?void 0:h[t])?void 0:c.x){let i=this.detectOverlappingBars({i:u,j:t,barXPosition:p,srtx:e,barWidth:M,xDivision:T,initPositions:C});M=i.barWidth,p=i.barXPosition}P=(r=this.drawRangeColumnPaths(d({indexes:{i:u,j:t,realIndex:b,translationsIndex:A},barWidth:M,barXPosition:p,zeroH:L,xDivision:T},v))).barHeight}let D=this.barHelpers.drawGoalLine({barXPosition:r.barXPosition,barYPosition:x,goalX:r.goalX,goalY:r.goalY,barHeight:P,barWidth:M});D&&X.add(D),m=r.y,f=r.x;let I=this.barHelpers.getPathFillColor(e,u,t,b);this.renderSeries({realIndex:b,pathFill:I.color,lineFill:I.useRangeColor?I.color:g.globals.stroke.colors[b],j:t,i:u,x:f,y:m,y1:s,y2:a,pathFrom:r.pathFrom,pathTo:r.pathTo,strokeWidth:i,elSeries:w,series:e,barHeight:P,barWidth:M,barXPosition:p,barYPosition:x,columnGroupIndex:y,elDataLabelsWrap:F,elGoalsMarkers:X,visibleSeries:this.visibleI,type:"rangebar"})}x.add(w)}return x}detectOverlappingBars({i:e,j:t,barYPosition:i,barXPosition:s,srty:a,srtx:r,barHeight:l,barWidth:o,yDivision:n,xDivision:h,initPositions:d}){var c,g,p,x;let u=this.w,f=[],m=null==(g=null==(c=u.config.series[e].data)?void 0:c[t])?void 0:g.rangeName,b=null==(x=null==(p=u.config.series[e].data)?void 0:p[t])?void 0:x.x,y=Array.isArray(b)?b.join(" "):b,w=u.labelData.labels.map(e=>Array.isArray(e)?e.join(" "):e).indexOf(y),v=u.rangeData.seriesRange[e].findIndex(e=>{var t;return e.x===y&&(null==(t=e.overlaps)?void 0:t.size)>0});return this.isHorizontal?(i=u.config.plotOptions.bar.rangeBarGroupRows?a+n*w:a+l*this.visibleI+n*w,v>-1&&!u.config.plotOptions.bar.rangeBarOverlap&&(f=Array.from(u.rangeData.seriesRange[e][v].overlaps)).indexOf(m)>-1&&(i=(l=d.barHeight/f.length)*this.visibleI+n*(100-parseInt(this.barOptions.barHeight,10))/100/2+l*(this.visibleI+f.indexOf(m))+n*w)):(w>-1&&!u.labelData.timescaleLabels.length&&(s=u.config.plotOptions.bar.rangeBarGroupRows?r+h*w:r+o*this.visibleI+h*w),v>-1&&!u.config.plotOptions.bar.rangeBarOverlap&&(f=Array.from(u.rangeData.seriesRange[e][v].overlaps)).indexOf(m)>-1&&(s=(o=d.barWidth/f.length)*this.visibleI+h*(100-parseInt(this.barOptions.barWidth,10))/100/2+o*(this.visibleI+f.indexOf(m))+h*w)),{barYPosition:i,barXPosition:s,barHeight:l,barWidth:o}}drawRangeColumnPaths({indexes:e,x:t,xDivision:i,barWidth:s,barXPosition:a,zeroH:r}){var l,o;let n=this.w,{i:h,j:d,realIndex:c,translationsIndex:g}=e,p=this.yRatio[g],x=this.getRangeValue(c,d),u=Math.min(x.start,x.end),f=Math.max(x.start,x.end);void 0===(null==(l=this.series[h])?void 0:l[d])||(null==(o=this.series[h])?void 0:o[d])===null?u=r:(u=r-u/p,f=r-f/p);let m=Math.abs(f-u),b=this.barHelpers.getColumnPaths({barXPosition:a,barWidth:s,y1:u,y2:f,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,realIndex:c,i:c,j:d,w:n});if(n.axisFlags.isXNumeric){let e=this.getBarXForNumericXAxis({x:t,j:d,realIndex:c,barWidth:s});t=e.x,a=e.barXPosition}else t+=i;return{pathTo:b.pathTo,pathFrom:b.pathFrom,barHeight:m,x:t,y:x.start<0&&x.end<0?u:f,goalY:this.barHelpers.getGoalValues("y",null,r,h,d,g),barXPosition:a}}preventBarOverflow(e){let t=this.w;return e<0&&(e=0),e>t.layout.gridWidth&&(e=t.layout.gridWidth),e}drawRangeBarPaths({indexes:e,y:t,y1:i,y2:s,yDivision:a,barHeight:r,barYPosition:l,zeroW:o}){let n=this.w,{realIndex:h,j:d}=e,c=this.preventBarOverflow(o+i/this.invertedYRatio),g=this.preventBarOverflow(o+s/this.invertedYRatio),p=this.getRangeValue(h,d),x=Math.abs(g-c),u=this.barHelpers.getBarpaths({barYPosition:l,barHeight:r,x1:c,x2:g,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,i:h,realIndex:h,j:d,w:n});return n.axisFlags.isXNumeric||(t+=a),{pathTo:u.pathTo,pathFrom:u.pathFrom,barWidth:x,x:p.start<0&&p.end<0?c:g,goalX:this.barHelpers.getGoalValues("x",o,null,h,d,0),y:t}}getRangeValue(e,t){let i=this.w;return{start:i.rangeData.seriesRangeStart[e][t],end:i.rangeData.seriesRangeEnd[e][t]}}}function tm(e,t){let i=0;for(let t=0;t<e.length;t++)i+=e[t];let s=t/i,a=Array(e.length);for(let t=0;t<e.length;t++)a[t]=e[t]*s;return a}function tb(e,t,i,s){let a=s*s,r=i*i;return Math.max(a*t/r,r/(a*e))}function ty(e,t,i,s,a,r,l,o){if(l>=o){let l=s/o,n=r;for(let s=0;s<i;s++){let i=t[s]/l;e.push([a,n,a+l,n+i]),n+=i}}else{let o=s/l,n=a;for(let s=0;s<i;s++){let i=t[s]/o;e.push([n,r,n+i,r+o]),n+=i}}}function tw(e,t,i,s,a){let r=[],l=e.length;if(0===l)return r;let o=Array(l),n=0,h=0,d=1/0,c=-1/0,g=0;for(;g<l;){var p,x,u,f,m,b;let l=Math.min(s,a),y=e[g];if(p=n,x=d,u=c,f=h,m=y,b=l,0===p||tb(x,u,f,b)>=tb(Math.min(x,m),Math.max(u,m),f+m,b))o[n]=y,n++,h+=y,y<d&&(d=y),y>c&&(c=y),g++;else{if(ty(r,o,n,h,t,i,s,a),s>=a){let e=h/a;t+=e,s-=e}else{let e=h/s;i+=e,a-=e}n=0,h=0,d=1/0,c=-1/0}}return n>0&&ty(r,o,n,h,t,i,s,a),r}let tv=function(e,t,i){let s=e.length,a=Array(s);for(let t=0;t<s;t++){let i=0,s=e[t];for(let e=0;e<s.length;e++)i+=s[e];a[t]=i}let r=tw(tm(a,t*i),0,0,t,i),l=Array(s);for(let t=0;t<s;t++){let i=r[t],s=i[0],a=i[1],o=i[2]-s,n=i[3]-a;l[t]=tw(tm(e[t],o*n),s,a,o,n)}return l};class tA{constructor(e,t){this.ctx=t,this.w=e,this.strokeWidth=this.w.config.stroke.width,this.helpers=new tl(e,t),this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.labels=[]}draw(e){let t=this.w,i=new Y(this.w,this.ctx),s=new W(this.w),a=i.group({class:"apexcharts-treemap"});if(t.globals.noData)return a;let r=[];
903return e.forEach(e=>{let t=e.map(e=>Math.abs(e));r.push(t)}),this.negRange=this.helpers.checkColorRange(),t.config.series.forEach((e,t)=>{e.data.forEach(e=>{Array.isArray(this.labels[t])||(this.labels[t]=[]),this.labels[t].push(e.x)})}),tv(r,t.layout.gridWidth,t.layout.gridHeight).forEach((r,l)=>{var o;let n=i.group({class:"apexcharts-series apexcharts-treemap-series",seriesName:v.escapeString(t.seriesData.seriesNames[l]),rel:l+1,"data:realIndex":l});if(i.setupEventDelegation(n,".apexcharts-treemap-rect"),t.config.chart.dropShadow.enabled){let e=t.config.chart.dropShadow;new z(this.w).dropShadow(a,e,l)}let h=i.group({class:"apexcharts-data-labels"}),d={xMin:1/0,yMin:1/0,xMax:-1/0,yMax:-1/0};r.forEach((a,r)=>{let o=a[0],h=a[1],c=a[2],g=a[3];d.xMin=Math.min(d.xMin,o),d.yMin=Math.min(d.yMin,h),d.xMax=Math.max(d.xMax,c),d.yMax=Math.max(d.yMax,g);let p=this.helpers.getShadeColor(t.config.chart.type,l,r,this.negRange),x=p.color,u=s.fillPath({color:x,seriesNumber:l,dataPointIndex:r}),f=i.drawRect(o,h,c-o,g-h,t.config.plotOptions.treemap.borderRadius,"#fff",1,this.strokeWidth,t.config.plotOptions.treemap.useFillColorAsStroke?x:t.globals.stroke.colors[l]);f.attr({cx:o,cy:h,index:l,i:l,j:r,width:c-o,height:g-h,fill:u}),f.node.classList.add("apexcharts-treemap-rect");let m={x:o+(c-o)/2,y:h+(g-h)/2,width:0,height:0},b={x:o,y:h,width:c-o,height:g-h};if(t.config.chart.animations.enabled&&!t.globals.dataChanged){let e=1;t.globals.resized||(e=t.config.chart.animations.speed),this.animateTreemap(f,m,b,e)}if(t.globals.dataChanged){let e=1;this.dynamicAnim.enabled&&t.globals.shouldAnimate&&(e=this.dynamicAnim.speed,t.globals.previousPaths[l]&&t.globals.previousPaths[l][r]&&t.globals.previousPaths[l][r].rect&&(m=t.globals.previousPaths[l][r].rect),this.animateTreemap(f,m,b,e))}let y=this.getFontSize(a),w=t.config.dataLabels.formatter(this.labels[l][r],{value:t.seriesData.series[l][r],seriesIndex:l,dataPointIndex:r,w:t});"truncate"===t.config.plotOptions.treemap.dataLabels.format&&(y=parseInt(String(t.config.dataLabels.style.fontSize),10),w=this.truncateLabels(String(w),y,o,h,c,g));let v=null;t.seriesData.series[l][r]&&(v=this.helpers.calculateDataLabels({text:w,x:(o+c)/2,y:(h+g)/2+this.strokeWidth/2+y/3,i:l,j:r,colorProps:p,fontSize:y,series:e})),t.config.dataLabels.enabled&&v&&this.rotateToFitLabel(v,y,w,o,h,c,g),n.add(f),null!==v&&n.add(v)});let c=t.config.plotOptions.treemap.seriesTitle;if(t.config.series.length>1&&c&&c.show){let e=t.config.series[l].name||"";if(e&&d.xMin<1/0&&d.yMin<1/0){let{offsetX:s,offsetY:a,borderColor:r,borderWidth:l,borderRadius:h,style:g}=c,p=g.color||t.config.chart.foreColor,x={left:g.padding.left,right:g.padding.right,top:g.padding.top,bottom:g.padding.bottom},u=i.getTextRects(e,g.fontSize,g.fontFamily),f=u.width+x.left+x.right,m=u.height+x.top+x.bottom,b=d.xMin+(s||0),y=d.yMin+(a||0),w=i.drawRect(b,y,f,m,h,g.background,1,l,r),v=i.drawText({x:b+x.left,y:y+x.top+(null!=(o=null==u?void 0:u.height)?o:0)*.75,text:e,fontSize:g.fontSize,fontFamily:g.fontFamily,fontWeight:g.fontWeight,foreColor:p,cssClass:g.cssClass||""});n.add(w),n.add(v)}}n.add(h),a.add(n)}),a}getFontSize(e){let t=this.w,i=function e(t){let i,s=0;if(Array.isArray(t[0]))for(i=0;i<t.length;i++)s+=e(t[i]);else for(i=0;i<t.length;i++)s+=t[i].length;return s}(this.labels)/function e(t){let i,s=0;if(Array.isArray(t[0]))for(i=0;i<t.length;i++)s+=e(t[i]);else for(i=0;i<t.length;i++)s+=1;return s}(this.labels);return Math.min(Math.pow((e[2]-e[0])*(e[3]-e[1]),.5)/i,parseInt(t.config.dataLabels.style.fontSize,10))}rotateToFitLabel(e,t,i,s,a,r,l){let o=new Y(this.w),n=o.getTextRects(i,String(t));if(n.width+this.w.config.stroke.width+5>r-s&&n.width<=l-a){let t=o.rotateAroundCenter(e.node);e.node.setAttribute("transform",`rotate(-90 ${t.x} ${t.y}) translate(${n.height/3})`)}}truncateLabels(e,t,i,s,a,r){let l=new Y(this.w),o=l.getTextRects(e,String(t)).width+this.w.config.stroke.width+5>a-i&&r-s>a-i?r-s:a-i,n=l.getTextBasedOnMaxWidth({text:e,maxWidth:o,fontSize:t});return e.length!==n.length&&o/t<5?"":n}animateTreemap(e,t,i,s){let a=new R(this.w);a.animateRect(e,t,i,s,()=>{a.animationCompleted(e)})}}
903eJ.use({line:tc,area:tc,scatter:tc,bubble:tc,rangeArea:tc,bar:ts,column:ts,barStacked:ta,rangeBar:tf,candlestick:tr,boxPlot:tr,pie:tp,donut:tp,polarArea:tp,radialBar:tu,radar:tx,heatmap:to,treemap:tA})}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.