import{G as f}from"./GraphinaGoogleChartBase.js";class n extends f{setUpChartsHandler(){this.chartHandlers={pie_google:e=>this.observeChartElement(e,"PieChart")}}observeChartElement(e,r){gcfe_public_localize.view_port==="off"?(this.observer||(this.observer=new IntersectionObserver(h=>{h.forEach(s=>{s.isIntersecting&&(this.setupChart(jQuery(s.target),r),this.observer.unobserve(s.target))})},{threshold:.1})),this.observer.observe(e[0])):this.setupChart(e,r)}getFinalChartOptions(e,r){return e}getFinalChartData(e){return e}setupTableData(e,r,h,s,t){var i;((i=e==null?void 0:e.google_chart_data)==null?void 0:i.data.length)>0?(r.addColumn("string","Month"),r.addColumn("number","Sale"),e.google_chart_data.data.forEach(o=>r.addRow(o)),h.show(),s.hide()):(e==null?void 0:e.columns.length)>0&&e.rows.length>0?(e.columns.forEach((o,u)=>{r.addColumn(o[0],o[1])}),e.rows.forEach(o=>r.addRow(o))):(h.hide(),s.show());var l=new google.visualization.NumberFormat({prefix:t.prefix??"",suffix:t.suffix??""});l.format(r,1)}}window.graphinaGooglePieChart=new n;
//# sourceMappingURL=pie_google.js.map
