vue-data-ui-hq
Version:
A user-empowering data visualization Vue 3 components library for eloquent data storytelling
3 lines (2 loc) • 20.3 kB
JavaScript
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),l=require("./index-ZfICPrrM.cjs"),oe=require("./useResponsive-BJ7DTGpm.cjs"),be=require("./Title-FbHK83tB.cjs"),re=require("./usePrinter-B-gh2f22.cjs"),ke=require("./Tooltip-C7TJODUx.cjs"),Ce=require("./DataTable-CC6dPSer.cjs"),we=require("./Legend-HgHPyA_4.cjs"),Te=require("./vue-ui-skeleton-Bvmpr51u.cjs"),Ne=require("./vue-ui-accordion-Dp6uTsJi.cjs"),ne=require("./useNestedProp-C14rfl0j.cjs"),$e=require("./PackageVersion-D3dK8oA3.cjs"),xe=require("./PenAndPaper-PL3bp4ud.cjs"),Se=require("./useUserOptionState-BgepsfED.cjs"),Be=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Pe=["id"],_e=["xmlns","viewBox"],Ve=["width","height"],Le=["id"],Oe=["stop-color"],Ee=["stop-color"],ze=["stroke","cx","cy","r","fill"],Ae=["stroke","stroke-width","cx","cy","r","fill"],Fe=["cx","cy","r","onMouseenter"],Ie={key:5,class:"vue-data-ui-watermark"},Re=["onClick"],Me={key:0},qe={key:1},Ue=["innerHTML"],De={__name:"vue-ui-rings",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend"],setup(le,{expose:ae,emit:ue}){const{vue_ui_rings:se}=l.useConfig(),f=le,k=e.ref(!1),T=e.computed(()=>!!f.dataset&&f.dataset.length),C=e.ref(l.createUid()),ie=e.ref(null),N=e.ref(!1),P=e.ref(""),m=e.ref(null),E=e.ref(0),y=e.ref(null),z=e.ref(null),A=e.ref(null),F=e.ref(null),I=e.ref(null),R=e.ref(0),M=e.ref(0),q=e.ref(0),t=e.computed({get:()=>H(),set:o=>o}),{userOptionsVisible:_,setUserOptionsVisibility:U,keepUserOptionState:D}=Se.useUserOptionState({config:t.value});function H(){const o=ne.useNestedProp({userConfig:f.config,defaultConfig:se});return o.theme?{...ne.useNestedProp({userConfig:l.themes.vue_ui_rings[o.theme]||f.config,defaultConfig:o}),customPalette:l.themePalettes[o.theme]||l.palette}:o}e.watch(()=>f.config,o=>{t.value=H(),_.value=!t.value.showOnChartHover,W(),R.value+=1,M.value+=1,q.value+=1},{deep:!0});const $=e.ref(null);e.onMounted(()=>{W()});function W(){if(l.objectIsEmpty(f.dataset)?l.error({componentName:"VueUiRings",type:"dataset"}):f.dataset.forEach((o,n)=>{o.values.length||l.error({componentName:"VueUiRings",type:"dataset"}),l.getMissingDatasetAttributes({datasetObject:o,requiredAttributes:["name","values"]}).forEach(r=>{l.error({componentName:"VueUiRings",type:"datasetSerieAttribute",property:r,index:n})})}),t.value.responsive){const o=oe.throttle(()=>{const{width:n,height:r}=oe.useResponsive({chart:y.value,title:t.value.style.chart.title.text?z.value:null,legend:t.value.style.chart.legend.show?A.value:null,source:F.value,noTitle:I.value});s.value.width=n,s.value.height=r});$.value=new ResizeObserver(o),$.value.observe(y.value.parentNode)}setTimeout(()=>{k.value=!0},600)}e.onBeforeUnmount(()=>{$.value&&$.value.disconnect()});const{isPrinting:G,isImaging:j,generatePdf:X,generateImage:Y}=re.usePrinter({elementId:`rings_${C.value}`,fileName:t.value.style.chart.title.text||"vue-ui-rings"}),ce=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),J=e.computed(()=>l.convertCustomPalette(t.value.customPalette)),v=e.ref({showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),s=e.ref({height:360,width:360}),de=e.computed(()=>Math.min(s.value.height,s.value.width)),fe=ue,i=e.ref([]);function V(o){i.value.includes(o)?i.value=i.value.filter(n=>n!==o):i.value.push(o),fe("selectLegend",c.value.map(n=>({name:n.name,color:n.color,value:n.value})))}const pe=e.computed(()=>Math.max(...x.value.filter(o=>!i.value.includes(o.uid)).map(({value:o})=>o)));function K(o){return o/pe.value}const x=e.computed(()=>f.dataset.map(({values:o,name:n,color:r=null},a)=>{const u=l.sanitizeArray(o).reduce((h,w)=>h+w,0);return{name:n,color:r||l.convertColorToHex(r)||J.value[a]||l.palette[a]||l.palette[a%l.palette.length],value:u,proportion:u/f.dataset.map(h=>(h.values||[]).reduce((w,ye)=>w+ye,0)).reduce((h,w)=>h+w,0),uid:l.createUid()}})),Q=e.computed(()=>x.value.map(o=>({...o,shape:"circle",opacity:i.value.includes(o.uid)?.5:1,segregate:()=>V(o.uid),isSegregated:i.value.includes(o.uid)})).toSorted((o,n)=>n.value-o.value)),he=e.computed(()=>({cy:"rings-div-legend",backgroundColor:t.value.style.chart.legend.backgroundColor,color:t.value.style.chart.legend.color,fontSize:t.value.style.chart.legend.fontSize,paddingBottom:12,fontWeight:t.value.style.chart.legend.bold?"bold":""})),p=e.computed(()=>x.value.filter(o=>!i.value.includes(o.uid)).map(({value:o})=>o).reduce((o,n)=>o+n,0)),c=e.computed(()=>x.value.filter(o=>!i.value.includes(o.uid)).map(({name:o,value:n,color:r=null,uid:a},u)=>({uid:a,name:o,color:r||l.convertColorToHex(r)||J.value[u]||l.palette[u]||l.palette[u%l.palette.length],value:n,proportion:K(n),percentage:n/p.value*100,strokeWidth:t.value.style.chart.layout.rings.strokeWidth*K(n)})).toSorted((o,n)=>n.value-o.value));function ve(){return c.value.map(({name:o,color:n,value:r,absoluteValues:a,percentage:u})=>({name:o,color:n,value:r,absoluteValues:a,percentage:u}))}const d=e.computed(()=>de.value-t.value.style.chart.layout.rings.strokeWidth*2),L=e.ref(null);function ge(o,n){if(i.value.length===f.dataset.length)return;L.value={datapoint:n,seriesIndex:o,series:c.value,config:t.value},m.value=o;const r=c.value[o],a=t.value.style.chart.tooltip.customFormat;if(l.isFunction(a)&&l.functionReturnsString(()=>a({seriesIndex:o,datapoint:n,series:c.value,config:t.value})))P.value=a({seriesIndex:o,datapoint:n,series:c.value,config:t.value});else{let u="";u+=`<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${r.name}</div>`,u+=`<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${r.color}" /></svg>`,t.value.style.chart.tooltip.showValue&&(u+=`<b>${l.applyDataLabel(t.value.style.chart.layout.labels.dataLabels.formatter,r.value,l.dataLabel({p:t.value.style.chart.layout.labels.dataLabels.prefix,v:r.value,s:t.value.style.chart.layout.labels.dataLabels.suffix,r:t.value.style.chart.tooltip.roundingValue}),{datapoint:n,seriesIndex:o})}
</b>`),t.value.style.chart.tooltip.showPercentage&&(t.value.style.chart.tooltip.showValue?u+=`<span>(${l.dataLabel({v:r.value/p.value*100,s:"%",r:t.value.style.chart.tooltip.roundingPercentage})})</span></div>`:u+=`<b>${l.dataLabel({v:r.value/p.value*100,s:"%",r:t.value.style.chart.tooltip.roundingPercentage})}</b></div>`),P.value=u}N.value=!0}const g=e.computed(()=>{const o=c.value.map(r=>({name:r.name,color:r.color})),n=c.value.map(r=>r.value);return{head:o,body:n}}),S=e.computed(()=>{const o=[' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>',l.dataLabel({p:t.value.style.chart.layout.labels.dataLabels.prefix,v:p.value,s:t.value.style.chart.layout.labels.dataLabels.suffix,r:t.value.table.td.roundingValue}),"100%"],n=g.value.head.map((u,h)=>[{color:u.color,name:u.name},l.dataLabel({p:t.value.style.chart.layout.labels.dataLabels.prefix,v:g.value.body[h],s:t.value.style.chart.layout.labels.dataLabels.suffix,r:t.value.table.td.roundingValue}),isNaN(g.value.body[h]/p.value)?"-":(g.value.body[h]/p.value*100).toFixed(t.value.table.td.roundingPercentage)+"%"]),r={th:{backgroundColor:t.value.table.th.backgroundColor,color:t.value.table.th.color,outline:t.value.table.th.outline},td:{backgroundColor:t.value.table.td.backgroundColor,color:t.value.table.td.color,outline:t.value.table.td.outline},breakpoint:t.value.table.responsiveBreakpoint},a=[t.value.table.columnNames.series,t.value.table.columnNames.value,t.value.table.columnNames.percentage];return{head:o,body:n,config:r,colNames:a}});function Z(){e.nextTick(()=>{const o=g.value.head.map((a,u)=>[[a.name],[g.value.body[u]],[isNaN(g.value.body[u]/p.value)?"-":g.value.body[u]/p.value*100]]),n=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],["val"],["%"]]].concat(o),r=l.createCsvContent(n);l.downloadCsv({csvContent:r,title:t.value.style.chart.title.text||"vue-ui-rings"})})}const b=e.ref(!1);function me(o){b.value=o,E.value+=1}function ee(){v.value.showTable=!v.value.showTable}function te(){v.value.showTooltip=!v.value.showTooltip}const B=e.ref(!1);function O(){B.value=!B.value}return ae({getData:ve,generatePdf:X,generateCsv:Z,generateImage:Y,toggleTable:ee,toggleTooltip:te,toggleAnnotator:O}),(o,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"ringsChart",ref:y,class:e.normalizeClass(`vue-ui-rings ${e.unref(b)?"vue-data-ui-wrapper-fullscreen":""} ${e.unref(t).useCssAnimation?"":"vue-ui-dna"}`),style:e.normalizeStyle(`font-family:${e.unref(t).style.fontFamily};text-align:center;width:100%;background:${e.unref(t).style.chart.backgroundColor};${e.unref(t).responsive?"height: 100%":""}`),id:`rings_${e.unref(C)}`,onMouseleave:n[3]||(n[3]=r=>{m.value=null,N.value=!1,e.unref(U)(!1)}),onMouseenter:n[4]||(n[4]=()=>e.unref(U)(!0))},[e.unref(t).userOptions.buttons.annotator?(e.openBlock(),e.createBlock(xe.PenAndPaper,{key:0,parent:e.unref(y),backgroundColor:e.unref(t).style.chart.backgroundColor,color:e.unref(t).style.chart.color,active:e.unref(B),onClose:O},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),e.unref(ce)?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:I,class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},null,512)):e.createCommentVNode("",!0),e.unref(t).style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:2,ref_key:"chartTitle",ref:z,style:"width:100%;background:transparent"},[(e.openBlock(),e.createBlock(be._sfc_main,{key:`title_${e.unref(R)}`,config:{title:{cy:"rings-div-title",...e.unref(t).style.chart.title},subtitle:{cy:"rings-div-subtitle",...e.unref(t).style.chart.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),e.unref(t).userOptions.show&&e.unref(T)&&(e.unref(D)||e.unref(_))?(e.openBlock(),e.createBlock(re.UserOptions,{ref_key:"details",ref:ie,key:`user_options_${e.unref(E)}`,backgroundColor:e.unref(t).style.chart.backgroundColor,color:e.unref(t).style.chart.color,isPrinting:e.unref(G),isImaging:e.unref(j),uid:e.unref(C),hasTooltip:e.unref(t).userOptions.buttons.tooltip&&e.unref(t).style.chart.tooltip.show,hasPdf:e.unref(t).userOptions.buttons.pdf,hasXls:e.unref(t).userOptions.buttons.csv,hasImg:e.unref(t).userOptions.buttons.img,hasTable:e.unref(t).userOptions.buttons.table,hasFullscreen:e.unref(t).userOptions.buttons.fullscreen,isTooltip:e.unref(v).showTooltip,isFullscreen:e.unref(b),titles:{...e.unref(t).userOptions.buttonTitles},chartElement:e.unref(y),position:e.unref(t).userOptions.position,hasAnnotator:e.unref(t).userOptions.buttons.annotator,isAnnotation:e.unref(B),onToggleFullscreen:me,onGeneratePdf:e.unref(X),onGenerateCsv:Z,onGenerateImage:e.unref(Y),onToggleTable:ee,onToggleTooltip:te,onToggleAnnotator:O,style:e.normalizeStyle({visibility:e.unref(D)?e.unref(_)?"visible":"hidden":"visible"})},e.createSlots({_:2},[o.$slots.optionTooltip?{name:"optionTooltip",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,o.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,o.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,o.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,o.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,o.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:r,isFullscreen:a})=>[e.renderSlot(o.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:r,isFullscreen:a})),void 0,!0)]),key:"5"}:void 0,o.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:r,isAnnotator:a})=>[e.renderSlot(o.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:r,isAnnotator:a})),void 0,!0)]),key:"6"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","isTooltip","isFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),e.unref(T)?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(l.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":e.unref(b),"vue-data-ui-fulscreen--off":!e.unref(b)}),viewBox:`0 0 ${e.unref(s).width<=0?10:e.unref(s).width} ${e.unref(s).height<=0?10:e.unref(s).height}`,style:e.normalizeStyle(`max-width:100%;overflow:visible;background:transparent;color:${e.unref(t).style.chart.color}`)},[e.createVNode($e._sfc_main),o.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:e.unref(s).width<=0?10:e.unref(s).width,height:e.unref(s).height<=0?10:e.unref(s).height,style:{pointerEvents:"none"}},[e.renderSlot(o.$slots,"chart-background",{},void 0,!0)],8,Ve)):e.createCommentVNode("",!0),e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(c),(r,a)=>(e.openBlock(),e.createElementBlock("radialGradient",{cx:"50%",cy:"30%",r:"50%",fx:"50%",fy:"50%",id:`gradient_${e.unref(C)}_${a}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(l.setOpacity)(e.unref(l.shiftHue)(r.color,.05),100-e.unref(t).style.chart.layout.rings.gradient.intensity)},null,8,Oe),e.createElementVNode("stop",{offset:"100%","stop-color":r.color},null,8,Ee)],8,Le))),256))]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(c),(r,a)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("circle",{class:e.normalizeClass({"vue-ui-rings-item":e.unref(k)&&e.unref(t).useCssAnimation,"vue-rings-item-onload":!e.unref(k)&&e.unref(t).useCssAnimation,"vue-ui-rings-opacity":e.unref(m)!==null&&e.unref(m)!==a}),style:e.normalizeStyle(`animation-delay:${a*100}ms`),stroke:e.unref(t).style.chart.layout.rings.stroke,cx:e.unref(s).width/2,cy:a===0?e.unref(s).height/2:e.unref(s).height/2+e.unref(d)*e.unref(c)[0].proportion/2-e.unref(d)*r.proportion/2-2*(a+1),r:e.unref(l.checkNaN)(e.unref(d)*r.proportion/2*.9<=0?1e-4:e.unref(d)*r.proportion/2*.9),fill:e.unref(t).style.chart.layout.rings.gradient.underlayerColor},null,14,ze),e.createElementVNode("circle",{class:e.normalizeClass({"vue-ui-rings-item":e.unref(k)&&e.unref(t).useCssAnimation,"vue-rings-item-onload":!e.unref(k)&&e.unref(t).useCssAnimation,"vue-ui-rings-shadow":e.unref(t).style.chart.layout.rings.useShadow,"vue-ui-rings-blur":e.unref(m)!==null&&e.unref(m)!==a}),style:e.normalizeStyle(`animation-delay:${a*100}ms`),stroke:e.unref(t).style.chart.layout.rings.stroke,"stroke-width":r.strokeWidth<.5?.5:r.strokeWidth,cx:e.unref(s).width/2,cy:a===0?e.unref(s).height/2:e.unref(s).height/2+e.unref(d)*e.unref(c)[0].proportion/2-e.unref(d)*r.proportion/2-2*(a+1),r:e.unref(l.checkNaN)(e.unref(d)*r.proportion/2*.9<=0?1e-4:e.unref(d)*r.proportion/2*.9),fill:e.unref(t).style.chart.layout.rings.gradient.show?`url(#gradient_${e.unref(C)}_${a})`:r.color},null,14,Ae),e.createElementVNode("circle",{"data-cy-trap":"",stroke:"none",cx:e.unref(s).width/2,cy:a===0?e.unref(s).height/2:e.unref(s).height/2+e.unref(d)*e.unref(c)[0].proportion/2-e.unref(d)*r.proportion/2-2*(a+1),r:e.unref(l.checkNaN)(e.unref(d)*r.proportion/2*.9<=0?1e-4:e.unref(d)*r.proportion/2*.9),fill:"transparent",onMouseenter:u=>ge(a,r),onMouseleave:n[0]||(n[0]=u=>{m.value=null,N.value=!1})},null,40,Fe)]))),256)),e.renderSlot(o.$slots,"svg",{svg:e.unref(s)},void 0,!0)],14,_e)):e.createCommentVNode("",!0),o.$slots.watermark?(e.openBlock(),e.createElementBlock("div",Ie,[e.renderSlot(o.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(G)||e.unref(j)})),void 0,!0)])):e.createCommentVNode("",!0),e.unref(T)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(Te.default,{key:6,config:{type:"rings",style:{backgroundColor:e.unref(t).style.chart.backgroundColor,rings:{color:"#CCCCCC"}}}},null,8,["config"])),e.createElementVNode("div",{ref_key:"chartLegend",ref:A},[e.unref(t).style.chart.legend.show?(e.openBlock(),e.createBlock(we.Legend,{key:`legend_${e.unref(q)}`,legendSet:e.unref(Q),config:e.unref(he),onClickMarker:n[1]||(n[1]=({legend:r})=>V(r.uid))},{item:e.withCtx(({legend:r,index:a})=>[e.createElementVNode("div",{"data-cy-legend-item":"",onClick:u=>V(r.uid),style:e.normalizeStyle(`opacity:${e.unref(i).includes(r.uid)?.5:1}`)},[e.createTextVNode(e.toDisplayString(r.name)+": "+e.toDisplayString(e.unref(l.applyDataLabel)(e.unref(t).style.chart.layout.labels.dataLabels.formatter,r.value,e.unref(l.dataLabel)({p:e.unref(t).style.chart.layout.labels.dataLabels.prefix,v:r.value,s:e.unref(t).style.chart.layout.labels.dataLabels.suffix,r:e.unref(t).style.chart.legend.roundingValue}),{datapoint:r,seriesIndex:a}))+" ",1),e.unref(i).includes(r.uid)?(e.openBlock(),e.createElementBlock("span",qe," ( - % ) ")):(e.openBlock(),e.createElementBlock("span",Me," ("+e.toDisplayString(isNaN(r.value/e.unref(p))?"-":e.unref(l.dataLabel)({v:r.value/e.unref(p)*100,s:"%",r:e.unref(t).style.chart.legend.roundingPercentage}))+") ",1))],12,Re)]),_:1},8,["legendSet","config"])):e.renderSlot(o.$slots,"legend",{key:1,legend:e.unref(Q)},void 0,!0)],512),o.$slots.source?(e.openBlock(),e.createElementBlock("div",{key:7,ref_key:"source",ref:F,dir:"auto"},[e.renderSlot(o.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),e.createVNode(ke._sfc_main,{show:e.unref(v).showTooltip&&e.unref(N)&&e.unref(i).length<f.dataset.length,backgroundColor:e.unref(t).style.chart.tooltip.backgroundColor,color:e.unref(t).style.chart.tooltip.color,borderRadius:e.unref(t).style.chart.tooltip.borderRadius,borderColor:e.unref(t).style.chart.tooltip.borderColor,borderWidth:e.unref(t).style.chart.tooltip.borderWidth,fontSize:e.unref(t).style.chart.tooltip.fontSize,backgroundOpacity:e.unref(t).style.chart.tooltip.backgroundOpacity,position:e.unref(t).style.chart.tooltip.position,offsetY:e.unref(t).style.chart.tooltip.offsetY,parent:e.unref(y),content:e.unref(P),isFullscreen:e.unref(b),isCustom:e.unref(t).style.chart.tooltip.customFormat&&typeof e.unref(t).style.chart.tooltip.customFormat=="function"},{"tooltip-before":e.withCtx(()=>[e.renderSlot(o.$slots,"tooltip-before",e.normalizeProps(e.guardReactiveProps({...e.unref(L)})),void 0,!0)]),"tooltip-after":e.withCtx(()=>[e.renderSlot(o.$slots,"tooltip-after",e.normalizeProps(e.guardReactiveProps({...e.unref(L)})),void 0,!0)]),_:3},8,["show","backgroundColor","color","borderRadius","borderColor","borderWidth","fontSize","backgroundOpacity","position","offsetY","parent","content","isFullscreen","isCustom"]),e.unref(T)?(e.openBlock(),e.createBlock(Ne.default,{key:8,hideDetails:"",config:{open:e.unref(v).showTable,maxHeight:1e4,body:{backgroundColor:e.unref(t).style.chart.backgroundColor,color:e.unref(t).style.chart.color},head:{backgroundColor:e.unref(t).style.chart.backgroundColor,color:e.unref(t).style.chart.color}}},{content:e.withCtx(()=>[(e.openBlock(),e.createBlock(Ce.DataTable,{key:`table_${e.unref(M)}`,colNames:e.unref(S).colNames,head:e.unref(S).head,body:e.unref(S).body,config:e.unref(S).config,title:`${e.unref(t).style.chart.title.text}${e.unref(t).style.chart.title.subtitle.text?` : ${e.unref(t).style.chart.title.subtitle.text}`:""}`,onClose:n[2]||(n[2]=r=>e.unref(v).showTable=!1)},{th:e.withCtx(({th:r})=>[e.createElementVNode("div",{innerHTML:r,style:{display:"flex","align-items":"center"}},null,8,Ue)]),td:e.withCtx(({td:r})=>[e.createTextVNode(e.toDisplayString(r.name||r),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],46,Pe))}},He=Be._export_sfc(De,[["__scopeId","data-v-2434d661"]]);exports.default=He;
;