import{m as b}from"./vendor-apexcharts-Dhew1LZV.js";import{u as f}from"./index-BzV9LDkq.js";import{S as _}from"./Skeleton-DgK7k6Ot.js";import{d as g,e as v,f as k,i as c,k as x,t as y,x as t,j as C}from"./vendor-vue-runtime-core-DwK6Ry68.js";import{t as S,r as n,u as r}from"./vendor-vue-reactivity-CheHbvBM.js";import{t as w,a as B}from"./vendor-vue-shared-DrzsEcag.js";import"./convert-case-to-camel-case.utils-CK5dBN7n.js";import"./analytics-DsW96Oy3.js";import"./vendor-vue-runtime-dom-B2rky8vu.js";import"./vendor-pinia-BSPefQhS.js";/* empty css               */import"./vendor-vue3-html2pdf-KR020wX8.js";import"./vendor-html2pdf.js-B-tok4Ns.js";import"./vendor-jspdf-UFhKzYHA.js";import"./vendor-bootstrap-CCU-90um.js";import"./vendor-html2canvas-BfYXEYrK.js";import"./vendor-datepicker--1DmXemW.js";import"./vendor-date-fns-DoIqsk4U.js";import"./vendor-axios-xsH4HHeE.js";const L={class:"ccb-dashboard-card ccb-dashboard-card-chart ccb-pie-chart"},N={class:"ccb-dashboard-chart-header"},V={class:"ccb-dashboard-chart-controls"},z={class:"ccb-dashboard-large-chart ccb-dashboard-large-chart-pie"},U=g({__name:"PieChart",props:{chart:{},page:{}},setup(p){const d=p,{chart:e}=S(d),l=e.value.categories,s=e.value.series,m=n({chart:{type:"pie",width:250},labels:l,legend:{show:!0,position:"left"},dataLabels:{enabled:!0,formatter(o,i){const u=i.seriesIndex;return`${parseInt(o)}% (${s[u]})`},style:{fontSize:"14px",fontWeight:500,position:"center"}},tooltip:{enabled:!0},responsive:[{breakpoint:1440,options:{chart:{width:300,position:"center"},legend:{position:"top"}}}]}),h=n(s),a=v(()=>f().isLoading);return(o,i)=>(c(),k("div",L,[a.value?(c(),x(r(_),{key:0})):y("",!0),t("div",{class:B(["ccb-dashboard-card-wrapper",{"ccb-is-loading":a.value}])},[t("div",N,[t("div",V,[t("span",null,w(r(e).title),1)])]),t("div",z,[C(r(b),{type:"pie",height:"100%",options:m.value,series:h.value},null,8,["options","series"])])],2)]))}});export{U as default};
//# sourceMappingURL=PieChart-CvSZMPEO.js.map
