/*! elementor - v3.29.0 - 19-05-2025 */
(()=>{var t={95480:(t,r,o)=>{"use strict";var a=o(96784);Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var u=a(o(39805)),i=a(o(40989)),c=a(o(15118)),l=a(o(29402)),d=a(o(87861)),p=a(o(83535));function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t})()}r.default=function(t){function CommandContainerBase(){return(0,u.default)(this,CommandContainerBase),function _callSuper(t,r,o){return r=(0,l.default)(r),(0,c.default)(t,_isNativeReflectConstruct()?Reflect.construct(r,o||[],(0,l.default)(t).constructor):r.apply(t,o))}(this,CommandContainerBase,arguments)}return(0,d.default)(CommandContainerBase,t),(0,i.default)(CommandContainerBase,[{key:"requireContainer",value:function requireContainer(){var t=this,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.args;if(!r.container&&!r.containers)throw Error("container or containers are required.");if(r.container&&r.containers)throw Error("container and containers cannot go together please select one of them.");(r.containers||[r.container]).forEach((function(r){t.requireArgumentInstance("container",elementorModules.editor.Container,{container:r})}))}}],[{key:"getInstanceType",value:function getInstanceType(){return"CommandContainerBase"}}])}(p.default)},12508:(t,r,o)=>{"use strict";var a=o(96784);Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var u=a(o(39805)),i=a(o(40989)),c=a(o(15118)),l=a(o(29402)),d=a(o(87861)),p=a(o(95480));function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t})()}r.default=function(t){function CommandContainerInternalBase(t){return(0,u.default)(this,CommandContainerInternalBase),function _callSuper(t,r,o){return r=(0,l.default)(r),(0,c.default)(t,_isNativeReflectConstruct()?Reflect.construct(r,o||[],(0,l.default)(t).constructor):r.apply(t,o))}(this,CommandContainerInternalBase,[t,$e.commandsInternal])}return(0,d.default)(CommandContainerInternalBase,t),(0,i.default)(CommandContainerInternalBase,null,[{key:"getInstanceType",value:function getInstanceType(){return"CommandContainerInternalBase"}}])}(p.default)},8813:(t,r,o)=>{"use strict";var a=o(96784);Object.defineProperty(r,"__esModule",{value:!0}),r.default=void 0;var u=a(o(39805)),i=a(o(40989)),c=a(o(15118)),l=a(o(29402)),d=a(o(41621)),p=a(o(87861)),y=a(o(95480));function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t})()}function _superPropGet(t,r,o,a){var u=(0,d.default)((0,l.default)(1&a?t.prototype:t),r,o);return 2&a&&"function"==typeof u?function(t){return u.apply(o,t)}:u}r.default=function(t){function CommandHistoryBase(){return(0,u.default)(this,CommandHistoryBase),function _callSuper(t,r,o){return r=(0,l.default)(r),(0,c.default)(t,_isNativeReflectConstruct()?Reflect.construct(r,o||[],(0,l.default)(t).constructor):r.apply(t,o))}(this,CommandHistoryBase,arguments)}return(0,p.default)(CommandHistoryBase,t),(0,i.default)(CommandHistoryBase,[{key:"initialize",value:function initialize(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=t.options,o=(void 0===r?{}:r).useHistory;(void 0===o||o)&&(this.history=this.getHistory(t),this.historyId=!1)}},{key:"getHistory",value:function getHistory(){elementorModules.ForceMethodImplementation()}},{key:"isHistoryActive",value:function isHistoryActive(){return elementor.documents.getCurrent().history.getActive()}},{key:"onBeforeRun",value:function onBeforeRun(t){_superPropGet(CommandHistoryBase,"onBeforeRun",this,3)([t]),this.history&&this.isHistoryActive()&&(this.historyId=$e.internal("document/history/start-log",this.history))}},{key:"onAfterRun",value:function onAfterRun(t,r){_superPropGet(CommandHistoryBase,"onAfterRun",this,3)([t,r]),this.history&&this.isHistoryActive()&&$e.internal("document/history/end-log",{id:this.historyId})}},{key:"onAfterApply",value:function onAfterApply(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;_superPropGet(CommandHistoryBase,"onAfterApply",this,3)([t,r]),this.isDataChanged()&&$e.internal("document/save/set-is-modified",{status:!0})}},{key:"onCatchApply",value:function onCatchApply(t){t instanceof $e.modules.HookBreak&&this.historyId&&$e.internal("document/history/delete-log",{id:this.historyId}),_superPropGet(CommandHistoryBase,"onCatchApply",this,3)([t])}},{key:"isDataChanged",value:function isDataChanged(){return!0}}],[{key:"getInstanceType",value:function getInstanceType(){return"CommandHistoryBase"}}])}(y.default)},26665:(t,r,o)=>{"use strict";var a=o(96784);Object.defineProperty(r,"__esModule",{value:!0}),r.getDefaultDebounceDelay=r.default=r.DEFAULT_DEBOUNCE_DELAY=void 0;var u=a(o(39805)),i=a(o(40989)),c=a(o(15118)),l=a(o(29402)),d=a(o(41621)),p=a(o(87861)),y=a(o(85707)),m=a(o(8813));function _isNativeReflectConstruct(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(_isNativeReflectConstruct=function _isNativeReflectConstruct(){return!!t})()}var v=r.DEFAULT_DEBOUNCE_DELAY=800,h=r.getDefaultDebounceDelay=function getDefaultDebounceDelay(){var t=v;return elementor.config.document&&void 0!==elementor.config.document.debounceDelay&&(t=elementor.config.document.debounceDelay),t},g=r.default=function(t){function CommandHistoryDebounceBase(){return(0,u.default)(this,CommandHistoryDebounceBase),function _callSuper(t,r,o){return r=(0,l.default)(r),(0,c.default)(t,_isNativeReflectConstruct()?Reflect.construct(r,o||[],(0,l.default)(t).constructor):r.apply(t,o))}(this,CommandHistoryDebounceBase,arguments)}return(0,p.default)(CommandHistoryDebounceBase,t),(0,i.default)(CommandHistoryDebounceBase,[{key:"initialize",value:function initialize(t){var r=t.options,o=void 0===r?{}:r;!function _superPropGet(t,r,o,a){var u=(0,d.default)((0,l.default)(1&a?t.prototype:t),r,o);return 2&a&&"function"==typeof u?function(t){return u.apply(o,t)}:u}(CommandHistoryDebounceBase,"initialize",this,3)([t]),this.constructor.debounce||(this.constructor.debounce=_.debounce((function(t){return t()}),h())),(1===$e.commands.currentTrace.length||o.debounce)&&(this.isDebounceRequired=!0)}},{key:"onBeforeRun",value:function onBeforeRun(t){$e.modules.CommandBase.prototype.onBeforeRun.call(this,t),this.history&&this.isHistoryActive()&&$e.internal("document/history/add-transaction",this.history)}},{key:"onAfterRun",value:function onAfterRun(t,r){$e.modules.CommandBase.prototype.onAfterRun.call(this,t,r),this.isHistoryActive()&&(this.isDebounceRequired?this.constructor.debounce((function(){return $e.internal("document/history/end-transaction")})):$e.internal("document/history/end-transaction"))}},{key:"onCatchApply",value:function onCatchApply(t){$e.modules.CommandBase.prototype.onCatchApply.call(this,t),t instanceof $e.modules.HookBreak&&this.history&&(this.isDebounceRequired?this.constructor.debounce((function(){return $e.internal("document/history/clear-transaction")})):$e.internal("document/history/clear-transaction"))}}],[{key:"getInstanceType",value:function getInstanceType(){return"CommandHistoryDebounceBase"}}])}(m.default);(0,y.default)(g,"debounce",void 0)},15213:(t,r)=>{"use strict";function _createForOfIteratorHelper(t,r){var o="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!o){if(Array.isArray(t)||(o=function _unsupportedIterableToArray(t,r){if(t){if("string"==typeof t)return _arrayLikeToArray(t,r);var o={}.toString.call(t).slice(8,-1);return"Object"===o&&t.constructor&&(o=t.constructor.name),"Map"===o||"Set"===o?Array.from(t):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?_arrayLikeToArray(t,r):void 0}}(t))||r&&t&&"number"==typeof t.length){o&&(t=o);var a=0,u=function F(){};return{s:u,n:function n(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function e(t){throw t},f:u}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,c=!0,l=!1;return{s:function s(){o=o.call(t)},n:function n(){var t=o.next();return c=t.done,t},e:function e(t){l=!0,i=t},f:function f(){try{c||null==o.return||o.return()}finally{if(l)throw i}}}}function _arrayLikeToArray(t,r){(null==r||r>t.length)&&(r=t.length);for(var o=0,a=Array(r);o0&&s==i.length&&e.push(a)})),t.globals.ignoreYAxisIndexes=e.map((function(t){return t}))}}]),t}(),Z=function(){function t(e){n(this,t),this.ctx=e,this.w=e.w}return l(t,[{key:"scaleSvgNode",value:function(t,e){var i=parseFloat(t.getAttributeNS(null,"width")),a=parseFloat(t.getAttributeNS(null,"height"));t.setAttributeNS(null,"width",i*e),t.setAttributeNS(null,"height",a*e),t.setAttributeNS(null,"viewBox","0 0 "+i+" "+a)}},{key:"getSvgString",value:function(){var t=this;return new Promise((function(e){var i=t.w,a=i.config.chart.toolbar.export.width,s=i.config.chart.toolbar.export.scale||a/i.globals.svgWidth;s||(s=1);var r=t.w.globals.dom.Paper.svg(),n=t.w.globals.dom.Paper.node.cloneNode(!0);1!==s&&t.scaleSvgNode(n,s),t.convertImagesToBase64(n).then((function(){r=(new XMLSerializer).serializeToString(n),e(r.replace(/ /g," "))}))}))}},{key:"convertImagesToBase64",value:function(t){var e=this,i=t.getElementsByTagName("image"),a=Array.from(i).map((function(t){var i=t.getAttributeNS("http://www.w3.org/1999/xlink","href");return i&&!i.startsWith("data:")?e.getBase64FromUrl(i).then((function(e){t.setAttributeNS("http://www.w3.org/1999/xlink","href",e)})).catch((function(t){console.error("Error converting image to base64:",t)})):Promise.resolve()}));return Promise.all(a)}},{key:"getBase64FromUrl",value:function(t){return new Promise((function(e,i){var a=new Image;a.crossOrigin="Anonymous",a.onload=function(){var t=document.createElement("canvas");t.width=a.width,t.height=a.height,t.getContext("2d").drawImage(a,0,0),e(t.toDataURL())},a.onerror=i,a.src=t}))}},{key:"cleanup",value:function(){var t=this.w,e=t.globals.dom.baseEl.getElementsByClassName("apexcharts-xcrosshairs"),i=t.globals.dom.baseEl.getElementsByClassName("apexcharts-ycrosshairs"),a=t.globals.dom.baseEl.querySelectorAll(".apexcharts-zoom-rect, .apexcharts-selection-rect");Array.prototype.forEach.call(a,(function(t){t.setAttribute("width",0)})),e&&e[0]&&(e[0].setAttribute("x",-500),e[0].setAttribute("x1",-500),e[0].setAttribute("x2",-500)),i&&i[0]&&(i[0].setAttribute("y",-100),i[0].setAttribute("y1",-100),i[0].setAttribute("y2",-100))}},{key:"svgUrl",value:function(){var t=this;return new Promise((function(e){t.cleanup(),t.getSvgString().then((function(t){var i=new Blob([t],{type:"image/svg+xml;charset=utf-8"});e(URL.createObjectURL(i))}))}))}},{key:"dataURI",value:function(t){var e=this;return new Promise((function(i){var a=e.w,s=t?t.scale||t.width/a.globals.svgWidth:1;e.cleanup();var r=document.createElement("canvas");r.width=a.globals.svgWidth*s,r.height=parseInt(a.globals.dom.elWrap.style.height,10)*s;var n="transparent"!==a.config.chart.background&&a.config.chart.background?a.config.chart.background:"#fff",o=r.getContext("2d");o.fillStyle=n,o.fillRect(0,0,r.width*s,r.height*s),e.getSvgString().then((function(t){var e="data:image/svg+xml,"+encodeURIComponent(t),a=new Image;a.crossOrigin="anonymous",a.onload=function(){if(o.drawImage(a,0,0),r.msToBlob){var t=r.msToBlob();i({blob:t})}else{var e=r.toDataURL("image/png");i({imgURI:e})}},a.src=e}))}))}},{key:"exportToSVG",value:function(){var t=this;this.svgUrl().then((function(e){t.triggerDownload(e,t.w.config.chart.toolbar.export.svg.filename,".svg")}))}},{key:"exportToPng",value:function(){var t=this,e=this.w.config.chart.toolbar.export.scale,i=this.w.config.chart.toolbar.export.width,a=e?{scale:e}:i?{width:i}:void 0;this.dataURI(a).then((function(e){var i=e.imgURI,a=e.blob;a?navigator.msSaveOrOpenBlob(a,t.w.globals.chartID+".png"):t.triggerDownload(i,t.w.config.chart.toolbar.export.png.filename,".png")}))}},{key:"exportToCSV",value:function(t){var e=this,i=t.series,a=t.fileName,s=t.columnDelimiter,r=void 0===s?",":s,n=t.lineDelimiter,o=void 0===n?"\n":n,l=this.w;i||(i=l.config.series);var h,c,d=[],g=[],u="",p=l.globals.series.map((function(t,e){return-1===l.globals.collapsedSeriesIndices.indexOf(e)?t:[]})),f=function(t){return"function"==typeof l.config.chart.toolbar.export.csv.categoryFormatter?l.config.chart.toolbar.export.csv.categoryFormatter(t):"datetime"===l.config.xaxis.type&&String(t).length>=10?new Date(t).toDateString():k.isNumber(t)?t:t.split(r).join("")},x=function(t){return"function"==typeof l.config.chart.toolbar.export.csv.valueFormatter?l.config.chart.toolbar.export.csv.valueFormatter(t):t},b=Math.max.apply(Math,v(i.map((function(t){return t.data?t.data.length:0})))),m=new q(this.ctx),y=new z(this.ctx),w=function(t){var i="";if(l.globals.axisCharts){if("category"===l.config.xaxis.type||l.config.xaxis.convertedCatToNumeric)if(l.globals.isBarHorizontal){var a=l.globals.yLabelFormatters[0],s=new U(e.ctx).getActiveConfigSeriesIndex();i=a(l.globals.labels[t],{seriesIndex:s,dataPointIndex:t,w:l})}else i=y.getLabel(l.globals.labels,l.globals.timescaleLabels,0,t).text;"datetime"===l.config.xaxis.type&&(l.config.xaxis.categories.length?i=l.config.xaxis.categories[t]:l.config.labels.length&&(i=l.config.labels[t]))}else i=l.config.labels[t];return null===i?"nullvalue":(Array.isArray(i)&&(i=i.join(" ")),k.isNumber(i)?i:i.split(r).join(""))},A=function(t,e){if(d.length&&0===e&&g.push(d.join(r)),t.data){t.data=t.data.length&&t.data||v(Array(b)).map((function(){return""}));for(var a=0;a5?(a.allSeriesCollapsed=!1,a.yAxisScale[t]=r.forceNiceScale?this.logarithmicScaleNice(e,i,r.logBase):this.logarithmicScale(e,i,r.logBase)):i!==-Number.MAX_VALUE&&k.isNumber(i)&&e!==Number.MAX_VALUE&&k.isNumber(e)?(a.allSeriesCollapsed=!1,a.yAxisScale[t]=this.niceScale(e,i,t)):a.yAxisScale[t]=this.niceScale(Number.MIN_VALUE,0,t)}},{key:"setXScale",value:function(t,e){var i=this.w,a=i.globals,s=Math.abs(e-t);if(e!==-Number.MAX_VALUE&&k.isNumber(e)){var r=a.xTickAmount+1;s<10&&s>1&&(r=s),a.xAxisScale=this.linearScale(t,e,r,0,i.config.xaxis.stepSize)}else a.xAxisScale=this.linearScale(0,10,10);return a.xAxisScale}},{key:"scaleMultipleYAxes",value:function(){var t=this,e=this.w.config,i=this.w.globals;this.coreUtils.setSeriesYAxisMappings();var a=i.seriesYAxisMap,s=i.minYArr,r=i.maxYArr;i.allSeriesCollapsed=!0,i.barGroups=[],a.forEach((function(a,n){var o=[];a.forEach((function(t){var i=e.series[t].group;o.indexOf(i)<0&&o.push(i)})),a.length>0?function(){var l,h,c=Number.MAX_VALUE,d=-Number.MAX_VALUE,g=c,u=d;if(e.chart.stacked)!function(){var t=new Array(i.dataPoints).fill(0),s=[],r=[],p=[];o.forEach((function(){s.push(t.map((function(){return Number.MIN_VALUE}))),r.push(t.map((function(){return Number.MIN_VALUE}))),p.push(t.map((function(){return Number.MIN_VALUE})))}));for(var f=function(t){!l&&e.series[a[t]].type&&(l=e.series[a[t]].type);var c=a[t];h=e.series[c].group?e.series[c].group:"axis-".concat(n),!(i.collapsedSeriesIndices.indexOf(c)<0&&i.ancillaryCollapsedSeriesIndices.indexOf(c)<0)||(i.allSeriesCollapsed=!1,o.forEach((function(t,a){if(e.series[c].group===t)for(var n=0;n0&&(e=this.w.config.chart.locales.concat(window.Apex.chart.locales));var i=e.filter((function(e){return e.name===t}))[0];if(!i)throw new Error("Wrong locale name provided. Please make sure you set the correct locale name in options");var a=k.extend(Y,i);this.w.globals.locale=a.options}}]),t}(),at=function(){function t(e){n(this,t),this.ctx=e,this.w=e.w}return l(t,[{key:"drawAxis",value:function(t,e){var i,a,s=this,r=this.w.globals,n=this.w.config,o=new $(this.ctx,e),l=new tt(this.ctx,e);r.axisCharts&&"radar"!==t&&(r.isBarHorizontal?(a=l.drawYaxisInversed(0),i=o.drawXaxisInversed(0),r.dom.elGraphical.add(i),r.dom.elGraphical.add(a)):(i=o.drawXaxis(),r.dom.elGraphical.add(i),n.yaxis.map((function(t,e){if(-1===r.ignoreYAxisIndexes.indexOf(e)&&(a=l.drawYaxis(e),r.dom.Paper.add(a),"back"===s.w.config.grid.position)){var i=r.dom.Paper.children()[1];i.remove(),r.dom.Paper.add(i)}}))))}}]),t}(),st=function(){function t(e){n(this,t),this.ctx=e,this.w=e.w}return l(t,[{key:"drawXCrosshairs",value:function(){var t=this.w,e=new C(this.ctx),i=new S(this.ctx),a=t.config.xaxis.crosshairs.fill.gradient,s=t.config.xaxis.crosshairs.dropShadow,r=t.config.xaxis.crosshairs.fill.type,n=a.colorFrom,o=a.colorTo,l=a.opacityFrom,h=a.opacityTo,c=a.stops,d=s.enabled,g=s.left,u=s.top,p=s.blur,f=s.color,x=s.opacity,b=t.config.xaxis.crosshairs.fill.color;if(t.config.xaxis.crosshairs.show){"gradient"===r&&(b=e.drawGradient("vertical",n,o,l,h,null,c,null));var v=e.drawRect();1===t.config.xaxis.crosshairs.width&&(v=e.drawLine());var m=t.globals.gridHeight;(!k.isNumber(m)||m<0)&&(m=0);var y=t.config.xaxis.crosshairs.width;(!k.isNumber(y)||y<0)&&(y=0),v.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:m,width:y,height:m,fill:b,filter:"none","fill-opacity":t.config.xaxis.crosshairs.opacity,stroke:t.config.xaxis.crosshairs.stroke.color,"stroke-width":t.config.xaxis.crosshairs.stroke.width,"stroke-dasharray":t.config.xaxis.crosshairs.stroke.dashArray}),d&&(v=i.dropShadow(v,{left:g,top:u,blur:p,color:f,opacity:x})),t.globals.dom.elGraphical.add(v)}}},{key:"drawYCrosshairs",value:function(){var t=this.w,e=new C(this.ctx),i=t.config.yaxis[0].crosshairs,a=t.globals.barPadForNumericAxis;if(t.config.yaxis[0].crosshairs.show){var s=e.drawLine(-a,0,t.globals.gridWidth+a,0,i.stroke.color,i.stroke.dashArray,i.stroke.width);s.attr({class:"apexcharts-ycrosshairs"}),t.globals.dom.elGraphical.add(s)}var r=e.drawLine(-a,0,t.globals.gridWidth+a,0,i.stroke.color,0,0);r.attr({class:"apexcharts-ycrosshairs-hidden"}),t.globals.dom.elGraphical.add(r)}}]),t}(),rt=function(){function t(e){n(this,t),this.ctx=e,this.w=e.w}return l(t,[{key:"checkResponsiveConfig",value:function(t){var e=this,i=this.w,a=i.config;if(0!==a.responsive.length){var s=a.responsive.slice();s.sort((function(t,e){return t.breakpoint>e.breakpoint?1:e.breakpoint>t.breakpoint?-1:0})).reverse();var r=new N({}),n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=s[0].breakpoint,n=window.innerWidth>0?window.innerWidth:screen.width;if(n>a){var o=k.clone(i.globals.initialConfig);o.series=k.clone(i.config.series);var l=L.extendArrayProps(r,o,i);t=k.extend(l,t),t=k.extend(i.config,t),e.overrideResponsiveOptions(t)}else for(var h=0;ht.globals.svgWidth&&(this.dCtx.lgRect.width=t.globals.svgWidth/1.5),this.dCtx.lgRect}},{key:"getDatalabelsRect",value:function(){var t=this,e=this.w,i=[];e.config.series.forEach((function(s,r){s.data.forEach((function(s,n){var o;o=e.globals.series[r][n],a=e.config.dataLabels.formatter(o,{ctx:t.dCtx.ctx,seriesIndex:r,dataPointIndex:n,w:e}),i.push(a)}))}));var a=k.getLargestStringFromArr(i),s=new C(this.dCtx.ctx),r=e.config.dataLabels.style,n=s.getTextRects(a,parseInt(r.fontSize),r.fontFamily);return{width:1.05*n.width,height:n.height}}},{key:"getLargestStringFromMultiArr",value:function(t,e){var i=t;if(this.w.globals.isMultiLineX){var a=e.map((function(t,e){return Array.isArray(t)?t.length:1})),s=Math.max.apply(Math,v(a));i=e[a.indexOf(s)]}return i}}]),t}(),ht=function(){function t(e){n(this,t),this.w=e.w,this.dCtx=e}return l(t,[{key:"getxAxisLabelsCoords",value:function(){var t,e=this.w,i=e.globals.labels.slice();if(e.config.xaxis.convertedCatToNumeric&&0===i.length&&(i=e.globals.categoryLabels),e.globals.timescaleLabels.length>0){var a=this.getxAxisTimeScaleLabelsCoords();t={width:a.width,height:a.height},e.globals.rotateXLabels=!1}else{this.dCtx.lgWidthForSideLegends="left"!==e.config.legend.position&&"right"!==e.config.legend.position||e.config.legend.floating?0:this.dCtx.lgRect.width;var s=e.globals.xLabelFormatter,r=k.getLargestStringFromArr(i),n=this.dCtx.dimHelpers.getLargestStringFromMultiArr(r,i);e.globals.isBarHorizontal&&(n=r=e.globals.yAxisScale[0].result.reduce((function(t,e){return t.length>e.length?t:e}),0));var o=new T(this.dCtx.ctx),l=r;r=o.xLabelFormat(s,r,l,{i:void 0,dateFormatter:new I(this.dCtx.ctx).formatDate,w:e}),n=o.xLabelFormat(s,n,l,{i:void 0,dateFormatter:new I(this.dCtx.ctx).formatDate,w:e}),(e.config.xaxis.convertedCatToNumeric&&void 0===r||""===String(r).trim())&&(n=r="1");var h=new C(this.dCtx.ctx),c=h.getTextRects(r,e.config.xaxis.labels.style.fontSize),d=c;if(r!==n&&(d=h.getTextRects(n,e.config.xaxis.labels.style.fontSize)),(t={width:c.width>=d.width?c.width:d.width,height:c.height>=d.height?c.height:d.height}).width*i.length>e.globals.svgWidth-this.dCtx.lgWidthForSideLegends-this.dCtx.yAxisWidth-this.dCtx.gridPad.left-this.dCtx.gridPad.right&&0!==e.config.xaxis.labels.rotate||e.config.xaxis.labels.rotateAlways){if(!e.globals.isBarHorizontal){e.globals.rotateXLabels=!0;var g=function(t){return h.getTextRects(t,e.config.xaxis.labels.style.fontSize,e.config.xaxis.labels.style.fontFamily,"rotate(".concat(e.config.xaxis.labels.rotate," 0 0)"),!1)};c=g(r),r!==n&&(d=g(n)),t.height=(c.height>d.height?c.height:d.height)/1.5,t.width=c.width>d.width?c.width:d.width}}else e.globals.rotateXLabels=!1}return e.config.xaxis.labels.show||(t={width:0,height:0}),{width:t.width,height:t.height}}},{key:"getxAxisGroupLabelsCoords",value:function(){var t,e=this.w;if(!e.globals.hasXaxisGroups)return{width:0,height:0};var i,a=(null===(t=e.config.xaxis.group.style)||void 0===t?void 0:t.fontSize)||e.config.xaxis.labels.style.fontSize,s=e.globals.groups.map((function(t){return t.title})),r=k.getLargestStringFromArr(s),n=this.dCtx.dimHelpers.getLargestStringFromMultiArr(r,s),o=new C(this.dCtx.ctx),l=o.getTextRects(r,a),h=l;return r!==n&&(h=o.getTextRects(n,a)),i={width:l.width>=h.width?l.width:h.width,height:l.height>=h.height?l.height:h.height},e.config.xaxis.labels.show||(i={width:0,height:0}),{width:i.width,height:i.height}}},{key:"getxAxisTitleCoords",value:function(){var t=this.w,e=0,i=0;if(void 0!==t.config.xaxis.title.text){var a=new C(this.dCtx.ctx).getTextRects(t.config.xaxis.title.text,t.config.xaxis.title.style.fontSize);e=a.width,i=a.height}return{width:e,height:i}}},{key:"getxAxisTimeScaleLabelsCoords",value:function(){var t,e=this.w;this.dCtx.timescaleLabels=e.globals.timescaleLabels.slice();var i=this.dCtx.timescaleLabels.map((function(t){return t.value})),a=i.reduce((function(t,e){return void 0===t?(console.error("You have possibly supplied invalid Date format. Please supply a valid JavaScript Date"),0):t.length>e.length?t:e}),0);return 1.05*(t=new C(this.dCtx.ctx).getTextRects(a,e.config.xaxis.labels.style.fontSize)).width*i.length>e.globals.gridWidth&&0!==e.config.xaxis.labels.rotate&&(e.globals.overlappingXLabels=!0),t}},{key:"additionalPaddingXLabels",value:function(t){var e=this,i=this.w,a=i.globals,s=i.config,r=s.xaxis.type,n=t.width;a.skipLastTimelinelabel=!1,a.skipFirstTimelinelabel=!1;var o=i.config.yaxis[0].opposite&&i.globals.isBarHorizontal,l=function(t,o){s.yaxis.length>1&&function(t){return-1!==a.collapsedSeriesIndices.indexOf(t)}(o)||function(t){if(e.dCtx.timescaleLabels&&e.dCtx.timescaleLabels.length){var o=e.dCtx.timescaleLabels[0],l=e.dCtx.timescaleLabels[e.dCtx.timescaleLabels.length-1].position+n/1.75-e.dCtx.yAxisWidthRight,h=o.position-n/1.75+e.dCtx.yAxisWidthLeft,c="right"===i.config.legend.position&&e.dCtx.lgRect.width>0?e.dCtx.lgRect.width:0;l>a.svgWidth-a.translateX-c&&(a.skipLastTimelinelabel=!0),h<-(t.show&&!t.floating||"bar"!==s.chart.type&&"candlestick"!==s.chart.type&&"rangeBar"!==s.chart.type&&"boxPlot"!==s.chart.type?10:n/1.75)&&(a.skipFirstTimelinelabel=!0)}else"datetime"===r?e.dCtx.gridPad.right