import{G as m}from"./GraphinaApexChartBase.js";class c extends m{constructor(){super(),this.observer={}}setUpChartsHandler(){this.chartHandlers={radar:r=>this.observeChartElement(r,"radar")}}applyDataLabelFormatter(r,e,n=!1){const t=e.chart_datalabel_prefix,i=e.chart_datalabel_postfix;r.dataLabels&&(e.string_format?r.dataLabels.formatter=function(l,a){return l=t+this.formatNumber(l,e.chart_label_pointer_number_for_label)+i,e.chart_datalabels_format_showlabel?a.w.globals.labels[a.seriesIndex]+"-"+t+l+i:t+l+i}:r.dataLabels.formatter=(l,a)=>{let o;if(n){let s=a.w.globals.seriesTotals.reduce((_,b)=>_+b,0);o=new Intl.NumberFormat(window.gcfe_public_localize.locale_with_hyphen,{minimumFractionDigits:e.chart_label_pointer_number_for_label,maximumFractionDigits:e.chart_label_pointer_number_for_label}).format(l/s*100)}else o=new Intl.NumberFormat(window.gcfe_public_localize.locale_with_hyphen,{minimumFractionDigits:e.chart_label_pointer_number_for_label,maximumFractionDigits:e.chart_label_pointer_number_for_label}).format(l);return e.chart_datalabels_format_showlabel?a.w.globals.labels[a.seriesIndex]+"-"+t+o+i:t+o+i})}getChartOptions(r,e,n,t){return e==="radar"&&(r.chart.events={mounted:(i,l)=>{const a=document.querySelector(`.graphina-elementor-chart[data-element_id="${t}"]`);a&&(a.style.height="")}}),r}}window.graphinaRadarChart=new c;
//# sourceMappingURL=radar.js.map
