vue-data-ui 2.3.61 → 2.3.63

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (162) hide show
  1. package/dist/{Arrow-B5nYwPUt.js → Arrow-CBx1Hj4I.js} +1 -1
  2. package/dist/{Arrow-Dv_tprAO.cjs → Arrow-fP0md3L3.cjs} +1 -1
  3. package/dist/{BaseIcon-DUPLRuLO.js → BaseIcon-CS18qRiy.js} +1 -1
  4. package/dist/{BaseIcon-aPcCSO_Z.cjs → BaseIcon-O8jJvy48.cjs} +1 -1
  5. package/dist/{DataTable-NUzEZXWt.js → DataTable-BGJ2mVxG.js} +2 -2
  6. package/dist/{DataTable-B6xCb-DR.cjs → DataTable-CSEiZDAb.cjs} +1 -1
  7. package/dist/{Legend-ePmJ_YIA.cjs → Legend-DuuSl2rJ.cjs} +1 -1
  8. package/dist/{Legend-C3tseguI.js → Legend-UWyvC57K.js} +1 -1
  9. package/dist/{Shape-DAe5uqIA.cjs → Shape-Dsx4SQVn.cjs} +1 -1
  10. package/dist/{Shape-BPcWPP9D.js → Shape-HfEpP-Tk.js} +1 -1
  11. package/dist/{Slicer-CmHwU6if.js → Slicer-Bk3Rt85L.js} +9 -9
  12. package/dist/{Slicer-BJs52Jle.cjs → Slicer-Cf74aFVz.cjs} +1 -1
  13. package/dist/{Title-BAQrVaNA.js → Title-CPZstF2C.js} +1 -1
  14. package/dist/{Title-B_p983os.cjs → Title-PZ6S96pU.cjs} +1 -1
  15. package/dist/{Tooltip-C2dhDgoh.cjs → Tooltip-BoIYPSX3.cjs} +1 -1
  16. package/dist/{Tooltip-B73tTE2v.js → Tooltip-CBmmiqKr.js} +5 -5
  17. package/dist/{index-CwG--L4Z.js → index-C_05i_JG.js} +578 -526
  18. package/dist/{index-nPEJmXmf.cjs → index-NNZeHOBS.cjs} +4 -4
  19. package/dist/style.css +1 -1
  20. package/dist/{useNestedProp-TbnnNrH2.cjs → useNestedProp-CPsbJAGj.cjs} +1 -1
  21. package/dist/{useNestedProp-BqwYEJGM.js → useNestedProp-DLnT0Wtg.js} +1 -1
  22. package/dist/{usePrinter-D012Olnq.cjs → usePrinter-BLbY8qGZ.cjs} +1 -1
  23. package/dist/{usePrinter-Do9tGYem.js → usePrinter-DOhlzlnx.js} +1 -1
  24. package/dist/{vue-data-ui-DQAJDvpX.cjs → vue-data-ui-D5aG0WkE.cjs} +1 -1
  25. package/dist/{vue-data-ui-ORLyt-v3.js → vue-data-ui-vqnxkVKv.js} +57 -57
  26. package/dist/vue-data-ui.cjs +1 -1
  27. package/dist/vue-data-ui.js +7 -7
  28. package/dist/{vue-ui-3d-bar-BRbooRg3.cjs → vue-ui-3d-bar-Cez69HMH.cjs} +1 -1
  29. package/dist/{vue-ui-3d-bar--ztApFzW.js → vue-ui-3d-bar-b7Pu7sfL.js} +7 -7
  30. package/dist/{vue-ui-accordion-CHL4xuW4.cjs → vue-ui-accordion-CcdyvXrp.cjs} +1 -1
  31. package/dist/{vue-ui-accordion-Be_wWB1T.js → vue-ui-accordion-rGJVvi_V.js} +3 -3
  32. package/dist/vue-ui-age-pyramid-B6LKyKjc.cjs +1 -0
  33. package/dist/{vue-ui-age-pyramid-DLIladXC.js → vue-ui-age-pyramid-CH1Vj2R6.js} +226 -226
  34. package/dist/{vue-ui-annotator-CS2d8F8x.cjs → vue-ui-annotator-BfmMNM_X.cjs} +1 -1
  35. package/dist/{vue-ui-annotator-Bxrjl1nz.js → vue-ui-annotator-CTio5IiK.js} +1 -1
  36. package/dist/{vue-ui-candlestick-BppLVU6c.js → vue-ui-candlestick-C4kT9W0j.js} +158 -158
  37. package/dist/{vue-ui-candlestick-tumv-lhv.cjs → vue-ui-candlestick-DvX9Jxoi.cjs} +2 -2
  38. package/dist/{vue-ui-carousel-table-BsFNypM6.cjs → vue-ui-carousel-table-CMs7scX3.cjs} +1 -1
  39. package/dist/{vue-ui-carousel-table-BnOsmGVc.js → vue-ui-carousel-table-Df2HHk0v.js} +4 -4
  40. package/dist/{vue-ui-chestnut-DFb7M_SC.js → vue-ui-chestnut-BKTnDElg.js} +65 -64
  41. package/dist/{vue-ui-chestnut-tK8ebPQM.cjs → vue-ui-chestnut-CCw8h0_m.cjs} +3 -3
  42. package/dist/{vue-ui-cursor-D-eRMlWI.cjs → vue-ui-cursor-C-8bpiuy.cjs} +1 -1
  43. package/dist/{vue-ui-cursor-CYk61ZVK.js → vue-ui-cursor-DOOlFN5D.js} +2 -2
  44. package/dist/{vue-ui-dashboard-Cbk74q7K.cjs → vue-ui-dashboard-B_h8KxOx.cjs} +1 -1
  45. package/dist/{vue-ui-dashboard-BomFWtsP.js → vue-ui-dashboard-D7U1UkAh.js} +2 -2
  46. package/dist/{vue-ui-digits-Ch9quA4D.js → vue-ui-digits-DmxQgABv.js} +2 -2
  47. package/dist/{vue-ui-digits-DWJOvgi2.cjs → vue-ui-digits-DoQoNGGx.cjs} +1 -1
  48. package/dist/{vue-ui-donut-BIMgi_Qw.cjs → vue-ui-donut-DdnwGXq6.cjs} +1 -1
  49. package/dist/vue-ui-donut-evolution-DsRAZLMN.cjs +1 -0
  50. package/dist/{vue-ui-donut-evolution-ClNciLi2.js → vue-ui-donut-evolution-uPCTV6E6.js} +95 -95
  51. package/dist/{vue-ui-donut-Ctzc7e6_.js → vue-ui-donut-t5zf9Lm5.js} +42 -42
  52. package/dist/{vue-ui-dumbbell-IBrAHdlc.js → vue-ui-dumbbell-BCdxqHVR.js} +109 -107
  53. package/dist/vue-ui-dumbbell-D1Ak2pEE.cjs +9 -0
  54. package/dist/vue-ui-flow-CLqm5nkx.cjs +1 -0
  55. package/dist/vue-ui-flow-J1SmdKkh.js +469 -0
  56. package/dist/vue-ui-galaxy-CSXbhXBe.cjs +1 -0
  57. package/dist/{vue-ui-galaxy-BBKU6WqV.js → vue-ui-galaxy-DNMbyKNg.js} +91 -91
  58. package/dist/{vue-ui-gauge-CDpN6D_X.js → vue-ui-gauge-CC_9cSwj.js} +84 -84
  59. package/dist/vue-ui-gauge-O3ntKI31.cjs +1 -0
  60. package/dist/{vue-ui-gizmo-BS-olrbu.js → vue-ui-gizmo-C5vGMHUU.js} +2 -2
  61. package/dist/{vue-ui-gizmo-Dyi4DWSA.cjs → vue-ui-gizmo-qrJt0nH6.cjs} +1 -1
  62. package/dist/vue-ui-heatmap-BjimHnMb.cjs +1 -0
  63. package/dist/{vue-ui-heatmap-Bonl3GBj.js → vue-ui-heatmap-ByxLZuR5.js} +257 -239
  64. package/dist/{vue-ui-kpi-MeC195T8.js → vue-ui-kpi-DdNQlVCe.js} +3 -3
  65. package/dist/{vue-ui-kpi-ChD3Gh4P.cjs → vue-ui-kpi-eyxMedig.cjs} +1 -1
  66. package/dist/{vue-ui-mini-loader-NiTij5XQ.cjs → vue-ui-mini-loader-B5ykH9BF.cjs} +1 -1
  67. package/dist/{vue-ui-mini-loader-l2G4D7lJ.js → vue-ui-mini-loader-C05VGcNr.js} +2 -2
  68. package/dist/{vue-ui-molecule-C1dO-Ony.js → vue-ui-molecule-DI0oHPT5.js} +20 -20
  69. package/dist/{vue-ui-molecule-pXZ3aWlr.cjs → vue-ui-molecule-LZ1SRkgK.cjs} +1 -1
  70. package/dist/{vue-ui-mood-radar-C3Gv4iYr.cjs → vue-ui-mood-radar-BJqk2oK_.cjs} +1 -1
  71. package/dist/{vue-ui-mood-radar-BVpJ3O4m.js → vue-ui-mood-radar-DIDqiVMf.js} +9 -9
  72. package/dist/{vue-ui-nested-donuts-Dmeqsml8.js → vue-ui-nested-donuts-BkSiryoB.js} +120 -120
  73. package/dist/{vue-ui-nested-donuts-Cwk0M7SE.cjs → vue-ui-nested-donuts-Nggnu_iK.cjs} +2 -2
  74. package/dist/{vue-ui-onion-BmJO696O.cjs → vue-ui-onion-B29Cxru2.cjs} +1 -1
  75. package/dist/{vue-ui-onion-Ogj_rMlX.js → vue-ui-onion-xiubSG3j.js} +9 -9
  76. package/dist/{vue-ui-parallel-coordinate-plot-BBBuJdGN.js → vue-ui-parallel-coordinate-plot-DjmOGHVx.js} +69 -69
  77. package/dist/{vue-ui-parallel-coordinate-plot-Cqm7uMBs.cjs → vue-ui-parallel-coordinate-plot-DqrkSOo6.cjs} +1 -1
  78. package/dist/{vue-ui-quadrant-BJtgJ_lu.js → vue-ui-quadrant-Cc79ggIy.js} +36 -36
  79. package/dist/{vue-ui-quadrant-DcqQwIsD.cjs → vue-ui-quadrant-Df_2X-ca.cjs} +1 -1
  80. package/dist/vue-ui-quick-chart-BnBGXd4d.cjs +15 -0
  81. package/dist/{vue-ui-quick-chart-D7dCfDSL.js → vue-ui-quick-chart-t_cPx4OT.js} +549 -515
  82. package/dist/{vue-ui-radar-BMxzhMFJ.js → vue-ui-radar-C3qEonKT.js} +59 -59
  83. package/dist/vue-ui-radar-D3W9B9JE.cjs +1 -0
  84. package/dist/{vue-ui-rating-DSgHml7s.js → vue-ui-rating-DffL7w-I.js} +9 -9
  85. package/dist/{vue-ui-rating-buop0ul0.cjs → vue-ui-rating-aOa6zIr5.cjs} +1 -1
  86. package/dist/{vue-ui-relation-circle-BACMnvv8.cjs → vue-ui-relation-circle-BZ7r7Unx.cjs} +1 -1
  87. package/dist/{vue-ui-relation-circle-CdHbZK0u.js → vue-ui-relation-circle-D0zUfd3f.js} +5 -5
  88. package/dist/vue-ui-rings-BjWAtE4x.cjs +2 -0
  89. package/dist/{vue-ui-rings-BBnzxfo2.js → vue-ui-rings-PHbuqfoT.js} +188 -185
  90. package/dist/{vue-ui-scatter-sF3c5eqM.cjs → vue-ui-scatter-DMJ77QYr.cjs} +1 -1
  91. package/dist/{vue-ui-scatter-DYXhTzch.js → vue-ui-scatter-DuCnr2yB.js} +378 -375
  92. package/dist/{vue-ui-screenshot-D-6YvKkW.cjs → vue-ui-screenshot-DBuA631a.cjs} +1 -1
  93. package/dist/{vue-ui-screenshot-B4WOalT6.js → vue-ui-screenshot-DbwRrmHv.js} +6 -6
  94. package/dist/{vue-ui-skeleton-D6wHGzmu.cjs → vue-ui-skeleton-CI4t8LHn.cjs} +1 -1
  95. package/dist/{vue-ui-skeleton-ClzVF3vm.js → vue-ui-skeleton-CcJR2m18.js} +23 -23
  96. package/dist/{vue-ui-smiley-B1cqwAN5.js → vue-ui-smiley-2rJFSSZS.js} +2 -2
  97. package/dist/{vue-ui-smiley-CoVnFdkD.cjs → vue-ui-smiley-C7KBm0fz.cjs} +1 -1
  98. package/dist/vue-ui-spark-trend-DY_sfo6o.js +251 -0
  99. package/dist/vue-ui-spark-trend-VH2nwGJf.cjs +1 -0
  100. package/dist/{vue-ui-sparkbar-BOzSGZak.js → vue-ui-sparkbar-B0O77PcV.js} +3 -3
  101. package/dist/{vue-ui-sparkbar-CpIfPtyd.cjs → vue-ui-sparkbar-Bs8ZQem1.cjs} +1 -1
  102. package/dist/{vue-ui-sparkgauge-4hk6ZJwJ.js → vue-ui-sparkgauge-B5KqrHQZ.js} +64 -64
  103. package/dist/vue-ui-sparkgauge-Cd7b4u0z.cjs +1 -0
  104. package/dist/{vue-ui-sparkhistogram-VCAQZfgG.cjs → vue-ui-sparkhistogram-CEWCLohQ.cjs} +1 -1
  105. package/dist/{vue-ui-sparkhistogram-8degKlMU.js → vue-ui-sparkhistogram-DwRPeG7H.js} +4 -4
  106. package/dist/{vue-ui-sparkline-DsUwWV4z.cjs → vue-ui-sparkline-CuFtIMpq.cjs} +1 -1
  107. package/dist/{vue-ui-sparkline-uBkd9kR2.js → vue-ui-sparkline-W5bZnpQo.js} +25 -25
  108. package/dist/{vue-ui-sparkstackbar-Cpq2lHcl.js → vue-ui-sparkstackbar-9hBQZ0lZ.js} +3 -3
  109. package/dist/{vue-ui-sparkstackbar-DyNfMGkM.cjs → vue-ui-sparkstackbar-TyVFUMtT.cjs} +1 -1
  110. package/dist/{vue-ui-stackbar-lr_qudpY.js → vue-ui-stackbar-BlkgM0nD.js} +35 -35
  111. package/dist/{vue-ui-stackbar-jQe7BneA.cjs → vue-ui-stackbar-CwVcupxt.cjs} +1 -1
  112. package/dist/vue-ui-strip-plot-C1GfRjXJ.cjs +1 -0
  113. package/dist/{vue-ui-strip-plot-DwvlcnHB.js → vue-ui-strip-plot-CBfqkkY6.js} +76 -75
  114. package/dist/{vue-ui-table-Dhj4_z9d.js → vue-ui-table-B8cvvLk8.js} +1 -1
  115. package/dist/{vue-ui-table-D5ybohqp.cjs → vue-ui-table-CmguTt4I.cjs} +1 -1
  116. package/dist/{vue-ui-table-heatmap-CChLZdxj.cjs → vue-ui-table-heatmap-DMnh8-b1.cjs} +1 -1
  117. package/dist/{vue-ui-table-heatmap-BY65DeiH.js → vue-ui-table-heatmap-wVWltZ2x.js} +26 -26
  118. package/dist/{vue-ui-table-sparkline-CvMETVJ1.js → vue-ui-table-sparkline-_POawNEL.js} +13 -13
  119. package/dist/{vue-ui-table-sparkline-Cmy6PcPI.cjs → vue-ui-table-sparkline-wtIFAc20.cjs} +1 -1
  120. package/dist/{vue-ui-thermometer-BIN2ofrh.js → vue-ui-thermometer-CFJqd-VY.js} +116 -116
  121. package/dist/vue-ui-thermometer-D6SnFJb1.cjs +1 -0
  122. package/dist/{vue-ui-timer-DBcOT10h.cjs → vue-ui-timer-194y0LUC.cjs} +1 -1
  123. package/dist/{vue-ui-timer-DoSqphvk.js → vue-ui-timer-D8dgDAfe.js} +4 -4
  124. package/dist/vue-ui-tiremarks-BM28JsxE.cjs +1 -0
  125. package/dist/{vue-ui-tiremarks-DRTLsMWt.js → vue-ui-tiremarks-CH1BFqbO.js} +71 -71
  126. package/dist/vue-ui-treemap-BIpIg3Qa.cjs +1 -0
  127. package/dist/{vue-ui-treemap-D8-D_wfq.js → vue-ui-treemap-DHsoVY5n.js} +89 -82
  128. package/dist/{vue-ui-vertical-bar-zUaXmUpB.js → vue-ui-vertical-bar-DNODBoSo.js} +246 -242
  129. package/dist/vue-ui-vertical-bar-Du8ikoWM.cjs +4 -0
  130. package/dist/{vue-ui-waffle-CztGir7e.js → vue-ui-waffle-C8hMAeMl.js} +44 -44
  131. package/dist/{vue-ui-waffle-RCqpPcSF.cjs → vue-ui-waffle-_Bi9MRx8.cjs} +1 -1
  132. package/dist/{vue-ui-wheel-CBqL8FKG.cjs → vue-ui-wheel-BZxcRGJX.cjs} +1 -1
  133. package/dist/{vue-ui-wheel-BQ2a-ZyV.js → vue-ui-wheel-CmZKsfKj.js} +5 -5
  134. package/dist/{vue-ui-word-cloud-CKUGIGnW.js → vue-ui-word-cloud-fLf-x06l.js} +68 -65
  135. package/dist/vue-ui-word-cloud-nHVG2yid.cjs +1 -0
  136. package/dist/{vue-ui-xy-Dsa2tfKS.js → vue-ui-xy-CPln5bGQ.js} +82 -82
  137. package/dist/vue-ui-xy-canvas-Z1tJJV5-.cjs +9 -0
  138. package/dist/{vue-ui-xy-canvas-JeNqaB_p.js → vue-ui-xy-canvas-k30CEsKi.js} +122 -121
  139. package/dist/vue-ui-xy-qxQy2sOl.cjs +3 -0
  140. package/package.json +1 -1
  141. package/dist/vue-ui-age-pyramid-BILMRRi1.cjs +0 -1
  142. package/dist/vue-ui-donut-evolution-K7LUkN6q.cjs +0 -1
  143. package/dist/vue-ui-dumbbell-HVpK20XO.cjs +0 -9
  144. package/dist/vue-ui-flow-CiXnGdNb.js +0 -465
  145. package/dist/vue-ui-flow-ClV2yd8Y.cjs +0 -1
  146. package/dist/vue-ui-galaxy-CMCXCWDA.cjs +0 -1
  147. package/dist/vue-ui-gauge-DwCGaX1h.cjs +0 -1
  148. package/dist/vue-ui-heatmap-WFNo-GFX.cjs +0 -1
  149. package/dist/vue-ui-quick-chart-D9zFHA0L.cjs +0 -15
  150. package/dist/vue-ui-radar-D8ik0Fqr.cjs +0 -1
  151. package/dist/vue-ui-rings-Dn5opKNy.cjs +0 -2
  152. package/dist/vue-ui-spark-trend-DnO4DW0n.cjs +0 -1
  153. package/dist/vue-ui-spark-trend-HioE2zeC.js +0 -251
  154. package/dist/vue-ui-sparkgauge-C2_I0tyO.cjs +0 -1
  155. package/dist/vue-ui-strip-plot-BMKaWqD4.cjs +0 -1
  156. package/dist/vue-ui-thermometer-Bfp-FwRE.cjs +0 -1
  157. package/dist/vue-ui-tiremarks-BeBJHz2R.cjs +0 -1
  158. package/dist/vue-ui-treemap-DqBukSj6.cjs +0 -1
  159. package/dist/vue-ui-vertical-bar-BM3aaSuB.cjs +0 -4
  160. package/dist/vue-ui-word-cloud-BbnU0d3E.cjs +0 -1
  161. package/dist/vue-ui-xy-BU0fCkSk.cjs +0 -3
  162. package/dist/vue-ui-xy-canvas-IaIARWWS.cjs +0 -9
@@ -0,0 +1,9 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("vue"),n=require("./index-NNZeHOBS.cjs"),c=require("./useResponsive-B3TrDDIG.cjs"),qe=require("./Tooltip-BoIYPSX3.cjs"),Ye=require("./Legend-DuuSl2rJ.cjs"),Ue=require("./Title-PZ6S96pU.cjs"),Xe=require("./Slicer-Cf74aFVz.cjs"),xe=require("./usePrinter-BLbY8qGZ.cjs"),Ae=require("./vue-ui-accordion-CcdyvXrp.cjs"),Ze=require("./DataTable-CSEiZDAb.cjs"),Ge=require("./vue-ui-skeleton-CI4t8LHn.cjs"),Le=require("./useNestedProp-CPsbJAGj.cjs"),je=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Je=["id"],Ke=["onClick"],Qe={key:2,class:"vue-data-ui-watermark"},et=["innerHTML"],tt={__name:"vue-ui-xy-canvas",props:{dataset:{type:Array,default(){return[]}},config:{type:Object,default(){return{}}}},emits:["selectLegend"],setup(J,{expose:ke,emit:Ce}){const R=J,{vue_ui_xy_canvas:we}=n.useConfig(),U=a.ref(n.createUid()),D=a.ref(null),C=a.ref(null),I=a.ref(null),i=a.ref(null),g=a.ref(1),z=a.ref(1),_=a.ref(!1),f=a.ref(null),H=a.ref(""),K=a.ref(null),k=a.ref([]),N=a.ref(1),M=a.ref(!0),w=a.ref(!0),X=a.ref(null),Q=a.ref(0),ee=a.ref(0),A=a.ref(!1),te=a.ref(null),ae=a.ref(null),le=a.ref(null),Z=a.computed(()=>!!R.dataset&&R.dataset.length),t=a.computed(()=>{const e=Le.useNestedProp({userConfig:R.config,defaultConfig:we});return e.theme?{...Le.useNestedProp({userConfig:n.themes.vue_ui_xy_canvas[e.theme]||R.config,defaultConfig:e}),customPalette:n.themePalettes[e.theme]||n.palette}:e}),oe=a.ref(t.value.style.chart.aspectRatio),{isPrinting:re,isImaging:ue,generatePdf:ne,generateImage:se}=xe.usePrinter({elementId:`xy_canvas_${U.value}`,fileName:t.value.style.chart.title.text||"vue-ui-xy-canvas"}),s=a.ref({showTable:t.value.table.show,showDataLabels:t.value.style.chart.dataLabels.show,stacked:t.value.style.chart.stacked,showTooltip:t.value.style.chart.tooltip.show});function Se(e){A.value=e,ee.value+=1}const ie=a.computed(()=>n.convertCustomPalette(t.value.customPalette)),P=a.computed(()=>Math.max(...E.value.filter((e,o)=>!k.value.includes(e.absoluteIndex)).map(e=>e.series.length))),l=a.computed(()=>{const e=g.value-g.value*(t.value.style.chart.paddingProportions.left+t.value.style.chart.paddingProportions.right);return{canvasWidth:g.value,canvasHeight:z.value,left:g.value*t.value.style.chart.paddingProportions.left,top:z.value*t.value.style.chart.paddingProportions.top,right:g.value-g.value*t.value.style.chart.paddingProportions.right,bottom:z.value-z.value*t.value.style.chart.paddingProportions.bottom,width:e,height:z.value-z.value*(t.value.style.chart.paddingProportions.top+t.value.style.chart.paddingProportions.bottom),slot:e/(u.value.end-u.value.start)}});function ve(e,o){return e/o}function ze({hasAutoScale:e,series:o,min:r,max:d,scale:h,yOffset:p,individualHeight:v,stackIndex:m=null}){return o.map((L,j)=>{const S=h.min<0?Math.abs(h.min):0,$=ve(L+S,S+h.max);let T,O;e&&(T=Math.abs(h.min),O=ve(L+T,h.max+T));let F=0;return m===null?F=l.value.bottom-l.value.height*(e?O:$):F=l.value.bottom-p-v*(e?O:$),{x:l.value.left+l.value.slot*j+l.value.slot/2,y:F,value:L}})}const b=a.computed(()=>{const e=Math.min(...E.value.filter((v,m)=>!k.value.includes(v.absoluteIndex)).flatMap(v=>v.series.slice(u.value.start,u.value.end))),o=Math.max(...E.value.filter((v,m)=>!k.value.includes(v.absoluteIndex)).flatMap(v=>v.series.slice(u.value.start,u.value.end))),r=n.calculateNiceScale(e<0?e:0,o===e?e+1<0?0:e+1:o<0?0:o,t.value.style.chart.scale.ticks),d=r.min<0?Math.abs(r.min):0,h=l.value.bottom-l.value.height*(d/(r.max+d)),p=r.ticks.map(v=>({y:l.value.bottom-l.value.height*((v+d)/(r.max+d)),x:l.value.left-8,value:v}));return{absoluteMin:d,max:o,min:e,scale:r,yLabels:p,zero:h}}),$e=a.computed(()=>y.value.map(e=>`
2
+ <div style="display:flex;flex-direction:row;gap:6px;align-items:center;">
3
+ <svg viewBox="0 0 10 10" height="12" width="12">
4
+ <circle cx="5" cy="5" r="5" fill="${e.color}"/>
5
+ </svg>
6
+ <span>${e.name?e.name+": ":""}</span>
7
+ <span>${n.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.series[f.value],n.dataLabel({p:e.prefix||"",v:e.series[f.value],s:e.suffix||"",r:e.rounding||0}),{datapoint:e,seriesIndex:f.value})}</span>
8
+ </div>
9
+ `)),E=a.computed(()=>R.dataset.map((e,o)=>({...e,series:n.sanitizeArray(e.series),absoluteIndex:o,color:n.convertColorToHex(e.color||ie.value[o]||n.palette[o]||n.palette[o%n.palette.length])}))),y=a.computed(()=>n.assignStackRatios(E.value.filter((e,o)=>!k.value.includes(e.absoluteIndex))).map((e,o)=>({...e,series:e.series.slice(u.value.start,u.value.end)})).map((e,o)=>{let r=Math.min(...e.series)||0,d=Math.max(...e.series)||1;r===d&&(r=r>=0?d-1:r,d=d>=0?d:r+1);const p={ratios:e.series.filter(B=>![null,void 0].includes(B)).map(B=>(B-r)/(d-r)),valueMin:r,valueMax:d},v=e.scaleSteps||t.value.style.chart.scale.ticks;let m;e.autoScaling?m=n.calculateNiceScale(p.valueMin,p.valueMax,v):m=n.calculateNiceScale(p.valueMin<0?p.valueMin:0,p.valueMax<=0?0:p.valueMax,v);const L=s.value.stacked?l.value.height*(1-e.cumulatedStackRatio):0,j=s.value.stacked?l.value.height/t.value.style.chart.stackGap:0,S=s.value.stacked?l.value.height*e.stackRatio-j:l.value.height,$=m.min<0?Math.abs(m.min):0;let T;e.autoScaling&&s.value.stacked&&d<=0?T=l.value.bottom-L-S:T=l.value.bottom-L-S*($/(m.max+$));const O=m.ticks.map((B,We)=>({y:l.value.bottom-L-S*(We/(m.ticks.length-1)),x:l.value.left-8,value:B})),F=ze({hasAutoScale:s.value.stacked&&e.autoScaling,series:e.series,min:s.value.stacked?r:b.value.min,max:s.value.stacked?d:b.value.max,scale:s.value.stacked?m:b.value.scale,yOffset:L,individualHeight:S,stackIndex:s.value.stacked?o:null});return{...e,coordinatesLine:F,min:r,max:d,localScale:m,localZero:T,localMin:$,localYLabels:O,yOffset:L,individualHeight:S}})),u=a.ref({start:0,end:P.value});function Te(){u.value={start:0,end:P.value},Q.value+=1}const Me=a.computed(()=>y.value.filter(e=>["line","plot",void 0].includes(e.type))),x=a.computed(()=>y.value.filter(e=>e.type==="bar"));function Pe(){if(!C.value)return;const e=I.value.offsetWidth,o=I.value.offsetHeight;C.value.width=e*N.value*2,C.value.height=o*N.value*2,g.value=e*N.value*2,z.value=o*N.value*2,i.value.scale(N.value,N.value),G()}function Re(){if(i.value.fillStyle=t.value.style.chart.backgroundColor,i.value.fillRect(0,0,l.value.canvasWidth,l.value.canvasHeight),s.value.stacked)t.value.style.chart.grid.y.verticalLines.show&&u.value.end-u.value.start<t.value.style.chart.grid.y.verticalLines.hideUnderXLength&&y.value.forEach(e=>{for(let o=0;o<u.value.end-u.value.start+1;o+=1)c.line(i.value,[{x:l.value.left+l.value.slot*o,y:l.value.bottom-e.yOffset-e.individualHeight},{x:l.value.left+l.value.slot*o,y:l.value.bottom-e.yOffset}],{color:t.value.style.chart.grid.y.verticalLines.color})}),t.value.style.chart.grid.x.horizontalLines.show&&(t.value.style.chart.grid.x.horizontalLines.alternate?y.value.forEach(e=>{e.localYLabels.forEach((o,r)=>{r<e.localYLabels.length-1&&c.rect(i.value,[{x:l.value.left,y:o.y},{x:l.value.right,y:o.y},{x:l.value.right,y:e.localYLabels[r+1].y},{x:l.value.left,y:e.localYLabels[r+1].y}],{fillColor:r%2===0?"transparent":t.value.style.chart.grid.x.horizontalLines.color+n.opacity[t.value.style.chart.grid.x.horizontalLines.opacity],strokeColor:"transparent"})})}):y.value.forEach(e=>{e.localYLabels.slice(u.value.start,u.value.end).forEach(o=>{c.line(i.value,[{x:l.value.left,y:o.y},{x:l.value.right,y:o.y}],{color:t.value.style.chart.grid.x.horizontalLines.color})})})),t.value.style.chart.grid.zeroLine.show&&y.value.forEach(e=>{c.line(i.value,[{x:l.value.left,y:e.localZero},{x:l.value.right,y:e.localZero}],{color:t.value.style.chart.grid.zeroLine.color,lineDash:t.value.style.chart.grid.zeroLine.dashed?[10,10]:[0,0]})}),t.value.style.chart.grid.y.axisLabels.show&&y.value.forEach(e=>{c.line(i.value,[{x:l.value.left,y:l.value.bottom-e.yOffset},{x:l.value.left,y:l.value.bottom-e.yOffset-e.individualHeight}],{color:e.color}),c.line(i.value,[{x:l.value.right,y:l.value.bottom-e.yOffset},{x:l.value.right,y:l.value.bottom-e.yOffset-e.individualHeight}],{color:e.color}),e.localYLabels.forEach((o,r)=>{c.text(i.value,n.applyDataLabel(t.value.style.chart.dataLabels.formatter,o.value,n.dataLabel({p:e.prefix||t.value.style.chart.grid.y.axisLabels.prefix||"",v:o.value,s:e.suffix||t.value.style.chart.grid.y.axisLabels.suffix||"",r:e.rounding||t.value.style.chart.grid.y.axisLabels.rounding||0}),{datapoint:o,seriesIndex:r}),o.x+t.value.style.chart.grid.y.axisLabels.offsetX,o.y,{align:"right",font:`${Math.round(g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`,color:e.color})})}),y.value.forEach(e=>{c.text(i.value,e.name,g.value/35,l.value.bottom-e.yOffset-e.individualHeight/2,{align:"center",rotation:-90,color:e.color,font:`${Math.round(g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`})});else{if(t.value.style.chart.grid.y.verticalLines.show&&u.value.end-u.value.start<t.value.style.chart.grid.y.verticalLines.hideUnderXLength)for(let e=0;e<u.value.end-u.value.start+1;e+=1)c.line(i.value,[{x:l.value.left+l.value.slot*e,y:l.value.top},{x:l.value.left+l.value.slot*e,y:l.value.bottom}],{color:t.value.style.chart.grid.y.verticalLines.color});t.value.style.chart.grid.x.horizontalLines.show&&(t.value.style.chart.grid.x.horizontalLines.alternate?b.value.yLabels.forEach((e,o)=>{o<b.value.yLabels.length-1&&c.rect(i.value,[{x:l.value.left,y:e.y},{x:l.value.right,y:e.y},{x:l.value.right,y:b.value.yLabels[o+1].y},{x:l.value.left,y:b.value.yLabels[o+1].y}],{fillColor:o%2===0?"transparent":t.value.style.chart.grid.x.horizontalLines.color+n.opacity[t.value.style.chart.grid.x.horizontalLines.opacity],strokeColor:"transparent"})}):b.value.yLabels.forEach(e=>{c.line(i.value,[{x:l.value.left,y:e.y},{x:l.value.right,y:e.y}],{color:t.value.style.chart.grid.x.horizontalLines.color})})),t.value.style.chart.grid.y.showAxis&&c.line(i.value,[{x:l.value.left,y:l.value.top},{x:l.value.left,y:l.value.bottom}],{color:t.value.style.chart.grid.y.axisColor,lineWidth:t.value.style.chart.grid.y.axisThickness}),t.value.style.chart.grid.x.showAxis&&c.line(i.value,[{x:l.value.left,y:l.value.bottom},{x:l.value.right,y:l.value.bottom}],{color:t.value.style.chart.grid.x.axisColor,lineWidth:t.value.style.chart.grid.x.axisThickness}),t.value.style.chart.grid.zeroLine.show&&c.line(i.value,[{x:l.value.left,y:b.value.zero},{x:l.value.right,y:b.value.zero}],{color:t.value.style.chart.grid.zeroLine.color,lineDash:t.value.style.chart.grid.zeroLine.dashed?[10,10]:[0,0]}),t.value.style.chart.grid.y.axisLabels.show&&b.value.yLabels.forEach((e,o)=>{c.text(i.value,n.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.value,n.dataLabel({p:t.value.style.chart.grid.y.axisLabels.prefix||"",v:e.value,s:t.value.style.chart.grid.y.axisLabels.suffix||"",r:t.value.style.chart.grid.y.axisLabels.rounding||0}),{datapoint:e,seriesIndex:o}),e.x+t.value.style.chart.grid.y.axisLabels.offsetX,e.y,{align:"right",font:`${Math.round(g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`,color:t.value.style.chart.grid.y.axisLabels.color})})}t.value.style.chart.grid.y.axisName&&c.text(i.value,t.value.style.chart.grid.y.axisName,g.value-g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio*1.2,l.value.bottom-l.value.height/2,{font:`${Math.round(g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`,color:t.value.style.chart.color,align:"center",rotation:90}),t.value.style.chart.grid.x.axisName&&c.text(i.value,t.value.style.chart.grid.x.axisName,g.value/2,z.value,{font:`${Math.round(g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`,color:t.value.style.chart.color,align:"center"})}function Ne(e){for(let o=0;o<e.coordinatesLine.length;o+=1){const r=(f.value===o?g.value/150:t.value.style.chart.line.plots.show?g.value/200:0)*t.value.style.chart.line.plots.radiusRatio;c.circle(i.value,{x:e.coordinatesLine[o].x,y:e.coordinatesLine[o].y},r,{color:t.value.style.chart.backgroundColor,fillStyle:e.color,strokeColor:"transparent"})}}function Ie(e){for(let o=0;o<e.coordinatesLine.length;o+=1)c.text(i.value,n.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.coordinatesLine[o].value,n.dataLabel({p:e.prefix||"",v:e.coordinatesLine[o].value,s:e.suffix||"",r:e.rounding||0}),{datapoint:e.coordinatesLine[o],seriesIndex:o}),e.coordinatesLine[o].x,e.coordinatesLine[o].y+t.value.style.chart.dataLabels.offsetY,{align:"center",font:`${Math.round(g.value/40*t.value.style.chart.dataLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`,color:t.value.style.chart.dataLabels.useSerieColor?e.color:t.value.style.chart.dataLabels.color,strokeColor:t.value.style.chart.backgroundColor,lineWidth:.8})}function Ee(){for(let e=u.value.start;e<u.value.end;e+=1)(u.value.end-u.value.start<t.value.style.chart.grid.y.timeLabels.modulo||u.value.end-u.value.start>=t.value.style.chart.grid.y.timeLabels.modulo&&(e%Math.floor((u.value.end-u.value.start)/t.value.style.chart.grid.y.timeLabels.modulo)===0||e===f.value+u.value.start))&&c.text(i.value,t.value.style.chart.grid.y.timeLabels.values[e]||e+1,l.value.left+l.value.slot*(e-u.value.start)+l.value.slot/2,l.value.bottom+g.value/t.value.style.chart.grid.y.timeLabels.offsetY,{align:t.value.style.chart.grid.y.timeLabels.rotation===0?"center":t.value.style.chart.grid.y.timeLabels.rotation>0?"left":"right",font:`${Math.round(g.value/40*t.value.style.chart.grid.y.timeLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`,color:t.value.style.chart.grid.y.timeLabels.color+n.opacity[f.value!==null?f.value+u.value.start===e?100:20:100],rotation:t.value.style.chart.grid.y.timeLabels.rotation})}function ce(){c.line(i.value,[{x:l.value.left+l.value.slot*f.value+l.value.slot/2,y:l.value.top},{x:l.value.left+l.value.slot*f.value+l.value.slot/2,y:l.value.bottom}],{color:t.value.style.chart.selector.color,lineDash:t.value.style.chart.selector.dashed?[8,8]:[0,0],lineWidth:2,linceCap:"round"})}function Oe(){x.value.forEach((e,o)=>{for(let r=0;r<e.coordinatesLine.length;r+=1)c.rect(i.value,[{x:l.value.left+l.value.slot*r+l.value.slot/10+(s.value.stacked?0:l.value.slot/x.value.length*o-(o===0?0:l.value.slot/(5*x.value.length)*o)),y:s.value.stacked?e.localZero:b.value.zero},{x:l.value.left+l.value.slot*r+l.value.slot/10+(s.value.stacked?0:l.value.slot/x.value.length*o-(o===0?0:l.value.slot/(5*x.value.length)*o))+l.value.slot*.8/(s.value.stacked?1:x.value.length),y:s.value.stacked?e.localZero:b.value.zero},{x:l.value.left+l.value.slot*r+l.value.slot/10+(s.value.stacked?0:l.value.slot/x.value.length*o-(o===0?0:l.value.slot/(5*x.value.length)*o))+l.value.slot*.8/(s.value.stacked?1:x.value.length),y:e.coordinatesLine[r].y},{x:l.value.left+l.value.slot*r+l.value.slot/10+(s.value.stacked?0:l.value.slot/x.value.length*o-(o===0?0:l.value.slot/(5*x.value.length)*o)),y:e.coordinatesLine[r].y}],{strokeColor:t.value.style.chart.backgroundColor,gradient:{type:"linear",start:{x:e.coordinatesLine[r].x,y:e.coordinatesLine[r].y},end:{x:e.coordinatesLine[r].x,y:s.value.stacked?e.localZero:b.value.zero},stops:[{offset:0,color:e.color},{offset:1,color:n.lightenHexColor(e.color,.5)}]}}),s.value.showDataLabels&&[!0,void 0].includes(e.dataLabels)&&c.text(i.value,n.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.coordinatesLine[r].value,n.dataLabel({p:e.prefix||"",v:e.coordinatesLine[r].value,s:e.suffix||"",r:e.rounding||0}),{datapoint:e.coordinatesLine[r],seriesIndex:r}),l.value.left+l.value.slot*r+l.value.slot/10+(s.value.stacked?0:l.value.slot/x.value.length*o-(o===0?0:l.value.slot/(5*x.value.length)*o))+l.value.slot*.4/(s.value.stacked?1:x.value.length),(e.coordinatesLine[r].value<0?s.value.stacked?e.localZero:b.value.zero:e.coordinatesLine[r].y)+t.value.style.chart.dataLabels.offsetY,{align:"center",font:`${Math.round(g.value/40*t.value.style.chart.dataLabels.fontSizeRatio)}px ${t.value.style.fontFamily}`,color:t.value.style.chart.dataLabels.useSerieColor?e.color:t.value.style.chart.dataLabels.color,strokeColor:t.value.style.chart.backgroundColor,lineWidth:.8})})}function Fe(e){e.useArea?s.value.stacked?c.polygon(i.value,[{x:e.coordinatesLine[0].x,y:e.localZero},...e.coordinatesLine,{x:e.coordinatesLine.at(-1).x,y:e.localZero}],{fillColor:e.color+n.opacity[t.value.style.chart.area.opacity],strokeColor:"transparent"}):c.polygon(i.value,[{x:e.coordinatesLine[0].x,y:b.value.zero},...e.coordinatesLine,{x:e.coordinatesLine.at(-1).x,y:b.value.zero}],{fillColor:e.color+n.opacity[t.value.style.chart.area.opacity],strokeColor:"transparent"}):c.line(i.value,e.coordinatesLine,{color:e.color,lineWidth:3})}function Be(){y.value.forEach((e,o)=>{c.line(i.value,[{x:l.value.left,y:l.value.bottom-e.yOffset},{x:l.value.right,y:l.value.bottom-e.yOffset}],{color:t.value.style.chart.grid.x.horizontalLines.color,lineWidth:1})})}function G(){Re(),M.value?(w.value&&f.value!==null&&t.value.style.chart.selector.show&&ce(),Oe(),s.value.stacked&&t.value.style.chart.grid.x.showAxis&&Be(),Me.value.forEach(e=>{(e.type==="line"||!e.type)&&Fe(e),w.value&&(Ne(e),s.value.showDataLabels&&[!0,void 0].includes(e.dataLabels)&&Ie(e))}),X.value=c.cloneCanvas(C.value)):(X.value&&i.value.drawImage(X.value,0,0),w.value&&f.value!==null&&t.value.style.chart.selector.show&&ce(),w.value&&f.value!==null&&y.value.forEach(e=>{if(e.type==="line"||!e.type||e.type==="plot"){if(!e.coordinatesLine[f.value])return;e.coordinatesLine[f.value].x!==void 0&&e.coordinatesLine[f.value].y!==void 0&&c.circle(i.value,{x:e.coordinatesLine[f.value].x,y:e.coordinatesLine[f.value].y},g.value/150*t.value.style.chart.line.plots.radiusRatio,{color:t.value.style.chart.backgroundColor,fillStyle:e.color,strokeColor:"transparent"})}})),t.value.style.chart.grid.y.timeLabels.show&&Ee(),M.value=!1}const V=c.debounce(()=>{w.value=!0,Pe()},P.value>200?10:1,!w.value);function De(e){const{left:o}=C.value.getBoundingClientRect(),r=e.clientX-o;if(r*2<l.value.left||r*2>l.value.right){_.value=!1,f.value=null;return}const d=r*2-l.value.left;if(f.value=Math.floor(d/l.value.slot),_.value=!0,!w.value)return;let h="";const p=t.value.style.chart.tooltip.customFormat;n.isFunction(p)&&n.functionReturnsString(()=>p({seriesIndex:f.value,datapoint:y.value.map(v=>({shape:v.shape||null,name:v.name,color:v.color,type:v.type||"line",value:v.series.find((m,L)=>L===f.value)})),series:y.value,config:t.value}))?H.value=p({seriesIndex:f.value,datapoint:y.value.map(v=>({shape:v.shape||null,name:v.name,color:v.color,type:v.type||"line",value:v.series.find((m,L)=>L===f.value)})),series:y.value,config:t.value}):(t.value.style.chart.grid.y.timeLabels.values.slice(u.value.start,u.value.end)[f.value]&&(h+=`<div style="padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid ${t.value.style.chart.tooltip.borderColor}; width:100%">${t.value.style.chart.grid.y.timeLabels.values.slice(u.value.start,u.value.end)[f.value]}</div>`),h+=$e.value.join(""),H.value=h),w.value=!1}a.watch(()=>f.value,e=>{V()}),a.watch(()=>u.value,e=>{M.value=!0,G()},{deep:!0}),a.watch(()=>s.value.showDataLabels,e=>{M.value=!0,G()}),a.watch(()=>s.value.stacked,e=>{M.value=!0,w.value=!0,V()});function _e(){_.value=!1,f.value=null,H.value=""}const W=a.ref(null),q=a.ref(null);a.onMounted(()=>{if(n.objectIsEmpty(R.dataset)?n.error({componentName:"VueUiXyCanvas",type:"dataset"}):C.value&&(i.value=C.value.getContext("2d",{willReadFrequently:!0})),t.value.responsive){const e=c.throttle(()=>{const{width:o,height:r}=c.useResponsive({chart:D.value,title:t.value.style.chart.title.text?te.value:null,legend:t.value.style.chart.legend.show?ae.value:null,slicer:t.value.style.chart.zoom.show&&P.value>1?le.value:null});oe.value=`${o} / ${r}`});W.value=new ResizeObserver(e),W.value.observe(D.value.parentNode)}q.value=new ResizeObserver(e=>{for(const o of e)o.contentBoxSize&&I.value&&(M.value=!0,V())}),q.value.observe(I.value)}),a.onBeforeUnmount(()=>{q.value&&q.value.disconnect(),W.value&&W.value.disconnect()});function de(e){Ce("selectLegend",y.value.find(o=>o.absoluteIndex===e)),k.value.includes(e)?k.value=k.value.filter(o=>o!==e):k.value.push(e),M.value=!0,V()}const he=a.computed(()=>E.value.map((e,o)=>({...e,name:e.name,color:n.convertColorToHex(e.color)||ie.value[o]||n.palette[o]||n.palette[o%n.palette.length],shape:e.shape||"circle",prefix:e.prefix||"",suffix:e.suffix||"",rounding:e.rounding||0})).map(e=>({...e,opacity:k.value.includes(e.absoluteIndex)?.5:1,segregate:()=>de(e.absoluteIndex),isSegregated:k.value.includes(e.absoluteIndex)}))),He=a.computed(()=>({cy:"donut-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":""})),Y=a.computed(()=>{const e=[""].concat(y.value.map(h=>h.name)).concat(' <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>');let o=[];for(let h=0;h<P.value;h+=1){const p=y.value.map(v=>v.series[h]??0).reduce((v,m)=>v+m,0);o.push([t.value.style.chart.grid.y.timeLabels.values.slice(u.value.start,u.value.end)[h]??h+1].concat(y.value.map(v=>(v.series[h]??0).toFixed(t.value.table.rounding))).concat((p??0).toFixed(t.value.table.rounding)))}const 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},d=[t.value.table.columnNames.period].concat(y.value.map(h=>h.name)).concat(t.value.table.columnNames.total);return{head:e,body:o.slice(0,u.value.end-u.value.start),config:r,colNames:d}}),fe=a.computed(()=>{if(y.value.length===0)return{head:[],body:[],config:{},columnNames:[]};const e=y.value.map(r=>({label:r.name,color:r.color,type:r.type})),o=[];for(let r=u.value.start;r<u.value.end;r+=1){const d=[t.value.style.chart.grid.y.timeLabels.values[r]||r+1];y.value.forEach(h=>{d.push(Number((h.series[r]||0).toFixed(t.value.table.rounding)))}),o.push(d)}return{head:e,body:o}});function ye(){const e=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[""]],o=["",...fe.value.head.map(p=>p.label)],r=fe.value.body,d=e.concat([o]).concat(r),h=n.createCsvContent(d);n.downloadCsv({csvContent:h,title:t.value.style.chart.title.text||"vue-ui-xy-canvas"})}function Ve(){return y.value}function ge(){s.value.showTable=!s.value.showTable}function pe(){s.value.showDataLabels=!s.value.showDataLabels}function me(){s.value.stacked=!s.value.stacked}function be(){s.value.showTooltip=!s.value.showTooltip}return ke({getData:Ve,generateCsv:ye,generatePdf:ne,generateImage:se,toggleTable:ge,toggleLabels:pe,toggleStack:me,toggleTooltip:be}),(e,o)=>(a.openBlock(),a.createElementBlock("div",{style:a.normalizeStyle(`width:100%; position: relative;${t.value.responsive?"height: 100%":""}`),ref_key:"xy",ref:D,id:`xy_canvas_${U.value}`,class:a.normalizeClass(`vue-ui-donut ${A.value?"vue-data-ui-wrapper-fullscreen":""}`)},[t.value.style.chart.title.text?(a.openBlock(),a.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:te,style:a.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};`)},[a.createVNode(Ue._sfc_main,{config:{title:{cy:"xy-canvas-title",...t.value.style.chart.title},subtitle:{cy:"xy-canvas-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"])],4)):a.createCommentVNode("",!0),t.value.userOptions.show&&Z.value?(a.openBlock(),a.createBlock(xe.UserOptions,{ref:"details",key:`user_option_${ee.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:a.unref(re),isImaging:a.unref(ue),uid:U.value,hasTooltip:t.value.userOptions.buttons.tooltip&&t.value.style.chart.tooltip.show,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasXls:t.value.userOptions.buttons.csv,hasLabel:t.value.userOptions.buttons.labels,hasStack:J.dataset.length>1&&t.value.userOptions.buttons.stack,hasFullscreen:t.value.userOptions.buttons.fullscreen,hasTable:u.value.end-u.value.start<200&&t.value.userOptions.buttons.table,isFullscreen:A.value,isTooltip:s.value.showTooltip,isStacked:s.value.stacked,titles:{...t.value.userOptions.buttonTitles},chartElement:D.value,onToggleFullscreen:Se,onGeneratePdf:a.unref(ne),onGenerateCsv:ye,onGenerateImage:a.unref(se),onToggleTable:ge,onToggleLabels:pe,onToggleStack:me,onToggleTooltip:be},a.createSlots({_:2},[e.$slots.optionTooltip?{name:"optionTooltip",fn:a.withCtx(()=>[a.renderSlot(e.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,e.$slots.optionPdf?{name:"optionPdf",fn:a.withCtx(()=>[a.renderSlot(e.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,e.$slots.optionCsv?{name:"optionCsv",fn:a.withCtx(()=>[a.renderSlot(e.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,e.$slots.optionImg?{name:"optionImg",fn:a.withCtx(()=>[a.renderSlot(e.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,e.$slots.optionTable?{name:"optionTable",fn:a.withCtx(()=>[a.renderSlot(e.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,e.$slots.optionLabels?{name:"optionLabels",fn:a.withCtx(()=>[a.renderSlot(e.$slots,"optionLabels",{},void 0,!0)]),key:"5"}:void 0,e.$slots.optionStack?{name:"optionStack",fn:a.withCtx(()=>[a.renderSlot(e.$slots,"optionStack",{},void 0,!0)]),key:"6"}:void 0,e.$slots.optionFullscreen?{name:"optionFullscreen",fn:a.withCtx(({toggleFullscreen:r,isFullscreen:d})=>[a.renderSlot(e.$slots,"optionFullscreen",a.normalizeProps(a.guardReactiveProps({toggleFullscreen:r,isFullscreen:d})),void 0,!0)]),key:"7"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasImg","hasXls","hasLabel","hasStack","hasFullscreen","hasTable","isFullscreen","isTooltip","isStacked","titles","chartElement","onGeneratePdf","onGenerateImage"])):a.createCommentVNode("",!0),a.createElementVNode("div",{class:"vue-ui-xy-canvas",style:a.normalizeStyle(`position: relative; aspect-ratio: ${oe.value}`),ref_key:"container",ref:I},[Z.value?(a.openBlock(),a.createElementBlock("canvas",{key:0,ref_key:"canvas",ref:C,style:{width:"100%",height:"100%"},onMousemove:o[0]||(o[0]=r=>De(r)),onMouseleave:_e},null,544)):(a.openBlock(),a.createBlock(Ge.default,{key:1,config:{type:"line",style:{backgroundColor:t.value.style.chart.backgroundColor,line:{axis:{color:"#CCCCCC"},path:{color:"#CCCCCC",strokeWidth:.5}}}}},null,8,["config"])),a.createVNode(qe._sfc_main,{show:s.value.showTooltip&&_.value,backgroundColor:t.value.style.chart.tooltip.backgroundColor,color:t.value.style.chart.tooltip.color,fontSize:t.value.style.chart.tooltip.fontSize,borderRadius:t.value.style.chart.tooltip.borderRadius,borderColor:t.value.style.chart.tooltip.borderColor,borderWidth:t.value.style.chart.tooltip.borderWidth,position:t.value.style.chart.tooltip.position,offsetY:t.value.style.chart.tooltip.offsetY,parent:C.value,content:H.value,backgroundOpacity:t.value.style.chart.tooltip.backgroundOpacity,isCustom:a.unref(n.isFunction)(t.value.style.chart.tooltip.customFormat)},{"tooltip-before":a.withCtx(()=>[a.renderSlot(e.$slots,"tooltip-before",a.normalizeProps(a.guardReactiveProps({...K.value})),void 0,!0)]),"tooltip-after":a.withCtx(()=>[a.renderSlot(e.$slots,"tooltip-after",a.normalizeProps(a.guardReactiveProps({...K.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","fontSize","borderRadius","borderColor","borderWidth","position","offsetY","parent","content","backgroundOpacity","isCustom"])],4),a.createElementVNode("div",{ref_key:"chartSlicer",ref:le,style:a.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor}`),"data-html2canvas-ignore":""},[t.value.style.chart.zoom.show&&P.value>1?(a.openBlock(),a.createBlock(Xe.Slicer,{key:`slicer_${Q.value}`,background:t.value.style.chart.zoom.color,borderColor:t.value.style.chart.backgroundColor,fontSize:t.value.style.chart.zoom.fontSize,useResetSlot:t.value.style.chart.zoom.useResetSlot,labelLeft:t.value.style.chart.grid.y.timeLabels.values[u.value.start]?t.value.style.chart.grid.y.timeLabels.values[u.value.start]:"",labelRight:t.value.style.chart.grid.y.timeLabels.values[u.value.end-1]?t.value.style.chart.grid.y.timeLabels.values[u.value.end-1]:"",textColor:t.value.style.chart.color,inputColor:t.value.style.chart.zoom.color,selectColor:t.value.style.chart.zoom.highlightColor,max:P.value,min:0,valueStart:u.value.start,valueEnd:u.value.end,start:u.value.start,"onUpdate:start":o[1]||(o[1]=r=>u.value.start=r),end:u.value.end,"onUpdate:end":o[2]||(o[2]=r=>u.value.end=r),onReset:Te},{"reset-action":a.withCtx(({reset:r})=>[a.renderSlot(e.$slots,"reset-action",a.normalizeProps(a.guardReactiveProps({reset:r})),void 0,!0)]),_:3},8,["background","borderColor","fontSize","useResetSlot","labelLeft","labelRight","textColor","inputColor","selectColor","max","valueStart","valueEnd","start","end"])):a.createCommentVNode("",!0)],4),a.createElementVNode("div",{ref_key:"chartLegend",ref:ae},[t.value.style.chart.legend.show&&Z.value?(a.openBlock(),a.createBlock(Ye.Legend,{key:0,legendSet:he.value,config:He.value,onClickMarker:o[3]||(o[3]=({i:r})=>de(r))},{item:a.withCtx(({legend:r,index:d})=>[a.createElementVNode("div",{onClick:h=>r.segregate(),style:a.normalizeStyle(`opacity:${k.value.includes(d)?.5:1}`)},a.toDisplayString(r.name),13,Ke)]),_:1},8,["legendSet","config"])):a.renderSlot(e.$slots,"legend",{key:1,legend:he.value},void 0,!0)],512),e.$slots.watermark?(a.openBlock(),a.createElementBlock("div",Qe,[a.renderSlot(e.$slots,"watermark",a.normalizeProps(a.guardReactiveProps({isPrinting:a.unref(re)||a.unref(ue)})),void 0,!0)])):a.createCommentVNode("",!0),u.value.end-u.value.start<200?(a.openBlock(),a.createBlock(Ae.default,{key:3,hideDetails:"",config:{open:s.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color},head:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color}}},{content:a.withCtx(()=>[a.createVNode(Ze.DataTable,{colNames:Y.value.colNames,head:Y.value.head,body:Y.value.body,config:Y.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:o[4]||(o[4]=r=>s.value.showTable=!1)},{th:a.withCtx(({th:r})=>[a.createElementVNode("div",{innerHTML:r},null,8,et)]),td:a.withCtx(({td:r})=>[a.createTextVNode(a.toDisplayString(r),1)]),_:1},8,["colNames","head","body","config","title"])]),_:1},8,["config"])):a.createCommentVNode("",!0)],14,Je))}},at=je._export_sfc(tt,[["__scopeId","data-v-631647ba"]]);exports.default=at;