vue-data-ui 2.6.2 → 2.6.4-beta.0

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 (181) hide show
  1. package/README.md +4 -4
  2. package/dist/{Arrow-DnYsOsEt.cjs → Arrow-BxhrO7GM.cjs} +1 -1
  3. package/dist/{Arrow-B4TCBt4-.js → Arrow-DnRkz3cJ.js} +1 -1
  4. package/dist/{BaseIcon-Dn1igOva.cjs → BaseIcon-BJi2tdtl.cjs} +1 -1
  5. package/dist/{BaseIcon-DTJIrD3k.js → BaseIcon-BhXkDb2X.js} +1 -1
  6. package/dist/DataTable-DN61toQQ.cjs +1 -0
  7. package/dist/{DataTable-BWABkdIL.js → DataTable-HDq8aOyj.js} +16 -16
  8. package/dist/{Legend-du4CJMG1.js → Legend-Be3l-GsN.js} +2 -2
  9. package/dist/{Legend-Bf8J9KZk.cjs → Legend-CxDZJIS9.cjs} +1 -1
  10. package/dist/PackageVersion-Cg_0Xov6.cjs +1 -0
  11. package/dist/{PackageVersion-Dqo8V-i_.js → PackageVersion-DL-70o6h.js} +3 -3
  12. package/dist/{PenAndPaper-QsaleY3R.js → PenAndPaper-C1v_7F2S.js} +161 -152
  13. package/dist/PenAndPaper-DpBM14U6.cjs +1 -0
  14. package/dist/{Shape-QydDpcqr.cjs → Shape-BeLBzUjm.cjs} +1 -1
  15. package/dist/{Shape-D_MGNYEa.js → Shape-DBqyaB9e.js} +1 -1
  16. package/dist/{Slicer-DKXIt2om.js → Slicer-BLv_S96I.js} +27 -28
  17. package/dist/Slicer-CvS2n5RR.cjs +1 -0
  18. package/dist/Title-CUoXs-XJ.cjs +1 -0
  19. package/dist/{Title-MKfkLka7.js → Title-rp5eHDVc.js} +8 -6
  20. package/dist/{Tooltip-BUMgVEu0.js → Tooltip-3XUFn6mK.js} +1 -1
  21. package/dist/{Tooltip-pA64woiQ.cjs → Tooltip-TqkUkWoH.cjs} +1 -1
  22. package/dist/documentation/installation.md +4 -4
  23. package/dist/{index-Bmq5HB9y.cjs → index-BfKO0mWG.cjs} +1 -1
  24. package/dist/{index-B8uVRkA1.js → index-GSCW0GhW.js} +1 -1
  25. package/dist/{index.es-BPcAjoFs.cjs → index.es-BvQiZh48.cjs} +6 -6
  26. package/dist/{index.es-7iEFeLUn.js → index.es-CsuAZrEh.js} +156 -157
  27. package/dist/jspdf.es.min-BJ0rgkUJ.cjs +243 -0
  28. package/dist/{jspdf.es.min-BnFm7Kpu.js → jspdf.es.min-af-Xj86b.js} +3834 -3784
  29. package/dist/{pdf-BoHS1PAA.cjs → pdf-DV2jHb_u.cjs} +1 -1
  30. package/dist/{pdf-FHG-_t_f.js → pdf-d7kl0_wm.js} +1 -1
  31. package/dist/{purify.es-BwOkayRK.js → purify.es-CKk_t3XZ.js} +72 -72
  32. package/dist/purify.es-CYVvLED6.cjs +3 -0
  33. package/dist/style.css +1 -1
  34. package/dist/{useNestedProp-CivZENAh.cjs → useNestedProp-D9fZbCk6.cjs} +1 -1
  35. package/dist/{useNestedProp-kStEZqtl.js → useNestedProp-Da-DNb_v.js} +1 -1
  36. package/dist/{usePrinter-Cf6Zct5m.cjs → usePrinter-B3WcbJUK.cjs} +1 -1
  37. package/dist/{usePrinter-CppD6oY_.js → usePrinter-BBNI0jHz.js} +3 -3
  38. package/dist/{vue-data-ui-ZZGY9nKv.js → vue-data-ui-BMhjdzlo.js} +62 -63
  39. package/dist/{vue-data-ui-HGY4nSGa.cjs → vue-data-ui-CFwQh6Nq.cjs} +1 -1
  40. package/dist/vue-data-ui.cjs +1 -1
  41. package/dist/vue-data-ui.js +1 -1
  42. package/dist/{vue-ui-3d-bar-BMZJgQzl.cjs → vue-ui-3d-bar-CsS9ZcR3.cjs} +2 -2
  43. package/dist/{vue-ui-3d-bar-DbhESYsC.js → vue-ui-3d-bar-DDrynTng.js} +10 -10
  44. package/dist/{vue-ui-accordion-CE2Pnpz3.js → vue-ui-accordion-CON_m6tj.js} +3 -3
  45. package/dist/{vue-ui-accordion-WWblnzaJ.cjs → vue-ui-accordion-CmsJv79_.cjs} +1 -1
  46. package/dist/{vue-ui-age-pyramid-DzPdTFTe.cjs → vue-ui-age-pyramid-DgMe9Sqk.cjs} +1 -1
  47. package/dist/{vue-ui-age-pyramid-CxW84Zy4.js → vue-ui-age-pyramid-vU0sQoum.js} +11 -11
  48. package/dist/{vue-ui-annotator-D5PCmH8u.cjs → vue-ui-annotator-CtH1hYMx.cjs} +1 -1
  49. package/dist/{vue-ui-annotator-DuS_kY-C.js → vue-ui-annotator-DDRpeWP1.js} +2 -2
  50. package/dist/{vue-ui-bullet-DND6LL0P.cjs → vue-ui-bullet-BPul6l6-.cjs} +2 -2
  51. package/dist/{vue-ui-bullet-CvB9cU_g.js → vue-ui-bullet-DE7BmFGO.js} +31 -31
  52. package/dist/{vue-ui-candlestick-C76ZVkkY.js → vue-ui-candlestick-BGfV1DZA.js} +12 -12
  53. package/dist/{vue-ui-candlestick-Bq4VyBVk.cjs → vue-ui-candlestick-D15TN1B5.cjs} +2 -2
  54. package/dist/vue-ui-carousel-table-BSa3YZb-.cjs +1 -0
  55. package/dist/{vue-ui-carousel-table-DPlos7Us.js → vue-ui-carousel-table-Bf9taWM2.js} +6 -5
  56. package/dist/{vue-ui-chestnut-CH1rO8yv.cjs → vue-ui-chestnut-8xbioUz3.cjs} +1 -1
  57. package/dist/{vue-ui-chestnut-CB4BA3mx.js → vue-ui-chestnut-DxRlK4Ay.js} +8 -8
  58. package/dist/{vue-ui-circle-pack-DslAztEw.js → vue-ui-circle-pack-CyDslseR.js} +12 -12
  59. package/dist/{vue-ui-circle-pack-T0baWnD4.cjs → vue-ui-circle-pack-muRA6J_Y.cjs} +1 -1
  60. package/dist/{vue-ui-cursor-CNrbLYcU.js → vue-ui-cursor-BHY7dRog.js} +3 -3
  61. package/dist/{vue-ui-cursor-tyy0Lbsc.cjs → vue-ui-cursor-D4yJTLt5.cjs} +1 -1
  62. package/dist/vue-ui-dashboard-DE0dhNVo.cjs +1 -0
  63. package/dist/{vue-ui-dashboard-BIQYUy0X.js → vue-ui-dashboard-Det8LJYN.js} +48 -48
  64. package/dist/{vue-ui-digits-9j9HvJAE.cjs → vue-ui-digits-BzhR0Mcn.cjs} +1 -1
  65. package/dist/{vue-ui-digits-B9zkzbxp.js → vue-ui-digits-Dt0qid-W.js} +3 -2
  66. package/dist/{vue-ui-donut-MNv-tPgT.cjs → vue-ui-donut-DaL830Ey.cjs} +1 -1
  67. package/dist/{vue-ui-donut-CTTVwsjp.js → vue-ui-donut-DaZEHulO.js} +12 -12
  68. package/dist/{vue-ui-donut-evolution-QrqawlMF.js → vue-ui-donut-evolution-DV83Qhft.js} +11 -11
  69. package/dist/{vue-ui-donut-evolution-ByfZmrmA.cjs → vue-ui-donut-evolution-Do_yzP73.cjs} +1 -1
  70. package/dist/{vue-ui-dumbbell-DdFhLM7x.cjs → vue-ui-dumbbell-D6RVlN16.cjs} +2 -2
  71. package/dist/{vue-ui-dumbbell-DbJC4PQf.js → vue-ui-dumbbell-_iB2kwjj.js} +187 -187
  72. package/dist/{vue-ui-flow-oXRtEqoD.js → vue-ui-flow-Dj9hwrL4.js} +31 -31
  73. package/dist/{vue-ui-flow-D3fu0o6H.cjs → vue-ui-flow-sPkKbG2Q.cjs} +1 -1
  74. package/dist/vue-ui-funnel-CPbO8wzf.cjs +1 -0
  75. package/dist/{vue-ui-funnel-wG5mmmoA.js → vue-ui-funnel-vsQxjwYY.js} +11 -11
  76. package/dist/{vue-ui-galaxy-DKsUFAVZ.js → vue-ui-galaxy-CK0YM3XM.js} +12 -12
  77. package/dist/{vue-ui-galaxy-D0chyXGV.cjs → vue-ui-galaxy-CbP6ke1z.cjs} +1 -1
  78. package/dist/{vue-ui-gauge-BgRQ_PbK.cjs → vue-ui-gauge-Czyxfawo.cjs} +1 -1
  79. package/dist/{vue-ui-gauge-CVS_Ragk.js → vue-ui-gauge-yJY1BsSw.js} +7 -7
  80. package/dist/{vue-ui-gizmo-Dhu6rJ9P.cjs → vue-ui-gizmo-2asc_BoL.cjs} +1 -1
  81. package/dist/{vue-ui-gizmo-D4BHhwJ8.js → vue-ui-gizmo-Csxmw_4Z.js} +3 -3
  82. package/dist/{vue-ui-heatmap-EGSWPEkM.cjs → vue-ui-heatmap-BoVcNorO.cjs} +1 -1
  83. package/dist/{vue-ui-heatmap-BGioOZJj.js → vue-ui-heatmap-DvtEgwd7.js} +10 -10
  84. package/dist/{vue-ui-history-plot-Be4mtSAH.cjs → vue-ui-history-plot-DClZa2Vh.cjs} +1 -1
  85. package/dist/{vue-ui-history-plot-B18G7ARJ.js → vue-ui-history-plot-jXu_grNZ.js} +12 -12
  86. package/dist/{vue-ui-kpi-BK1Vq6tA.js → vue-ui-kpi-B9srgPYW.js} +3 -3
  87. package/dist/{vue-ui-kpi-B7rHhQ3H.cjs → vue-ui-kpi-BmLtKTLO.cjs} +1 -1
  88. package/dist/vue-ui-mini-loader-BRg64vUC.cjs +1 -0
  89. package/dist/{vue-ui-mini-loader-lAOgjMme.js → vue-ui-mini-loader-BwE1E9sj.js} +7 -6
  90. package/dist/{vue-ui-molecule-TSwsc6wZ.cjs → vue-ui-molecule-BmriFNB0.cjs} +1 -1
  91. package/dist/{vue-ui-molecule-DEKmU-Mx.js → vue-ui-molecule-ZvqDoyQn.js} +50 -50
  92. package/dist/{vue-ui-mood-radar-6XZfljIe.js → vue-ui-mood-radar-CF_CFAho.js} +47 -46
  93. package/dist/vue-ui-mood-radar-CGhu07bI.cjs +1 -0
  94. package/dist/{vue-ui-nested-donuts-Cl8xdJU6.js → vue-ui-nested-donuts-Co3gUruy.js} +12 -13
  95. package/dist/{vue-ui-nested-donuts--A1qjixG.cjs → vue-ui-nested-donuts-TQhesJpT.cjs} +2 -2
  96. package/dist/{vue-ui-onion-C32u8Ezk.cjs → vue-ui-onion-BPTDTiWh.cjs} +1 -1
  97. package/dist/{vue-ui-onion-CPlqANiN.js → vue-ui-onion-D5fU3bvZ.js} +11 -11
  98. package/dist/{vue-ui-parallel-coordinate-plot-BY0t_Hc_.cjs → vue-ui-parallel-coordinate-plot-BDQK9tcd.cjs} +1 -1
  99. package/dist/{vue-ui-parallel-coordinate-plot-95RlJka2.js → vue-ui-parallel-coordinate-plot-S6Ru7Se6.js} +12 -12
  100. package/dist/{vue-ui-quadrant-CWwHr8BX.cjs → vue-ui-quadrant-CaWYkjaC.cjs} +1 -1
  101. package/dist/{vue-ui-quadrant-C_BIZcc8.js → vue-ui-quadrant-iUoaNCjW.js} +12 -12
  102. package/dist/{vue-ui-quick-chart-BZ5n0UQy.js → vue-ui-quick-chart-Bi37MmKx.js} +9 -9
  103. package/dist/{vue-ui-quick-chart-CZYAIILY.cjs → vue-ui-quick-chart-C-RgDysS.cjs} +1 -1
  104. package/dist/{vue-ui-radar-Ddu3Dzxx.js → vue-ui-radar-CopgFTuf.js} +12 -12
  105. package/dist/{vue-ui-radar-D4XBfJym.cjs → vue-ui-radar-vLsuc2uC.cjs} +1 -1
  106. package/dist/vue-ui-rating-B5hwtW5c.cjs +1 -0
  107. package/dist/vue-ui-rating-DLpcRbMZ.js +350 -0
  108. package/dist/{vue-ui-relation-circle-B_xPyr_-.js → vue-ui-relation-circle-9JR989rq.js} +7 -7
  109. package/dist/{vue-ui-relation-circle-8Kw5PdZD.cjs → vue-ui-relation-circle-DXtlx7Lb.cjs} +1 -1
  110. package/dist/{vue-ui-rings-CuLwbEa2.cjs → vue-ui-rings-BcsA17T9.cjs} +1 -1
  111. package/dist/{vue-ui-rings-pjfgnXyP.js → vue-ui-rings-aF4qo-1b.js} +12 -12
  112. package/dist/{vue-ui-scatter-x6zrT3IA.js → vue-ui-scatter-BKPsLeSZ.js} +12 -12
  113. package/dist/{vue-ui-scatter-YQ4zYJj0.cjs → vue-ui-scatter-CsrRv5Fs.cjs} +1 -1
  114. package/dist/{vue-ui-screenshot-D3k8rLXz.cjs → vue-ui-screenshot-CseUdcVu.cjs} +1 -1
  115. package/dist/{vue-ui-screenshot-DeKe5Csw.js → vue-ui-screenshot-D7IGq1jh.js} +1 -1
  116. package/dist/{vue-ui-skeleton-BC7kQhlE.js → vue-ui-skeleton-C0nuwFlf.js} +3 -3
  117. package/dist/{vue-ui-skeleton-D5890icn.cjs → vue-ui-skeleton-C9gd5UnC.cjs} +1 -1
  118. package/dist/{vue-ui-smiley-5evB5mWX.js → vue-ui-smiley-BE7j-VIB.js} +127 -125
  119. package/dist/{vue-ui-smiley-CNlhfa-H.cjs → vue-ui-smiley-DTJ3ccy1.cjs} +2 -2
  120. package/dist/{vue-ui-spark-trend-CuqG_rtb.cjs → vue-ui-spark-trend-D90EITXN.cjs} +1 -1
  121. package/dist/{vue-ui-spark-trend-BgZ0JbXH.js → vue-ui-spark-trend-vfSFcF96.js} +5 -5
  122. package/dist/vue-ui-sparkbar-B58Oyi3V.cjs +1 -0
  123. package/dist/{vue-ui-sparkbar-DkAi7xTy.js → vue-ui-sparkbar-DIjx229h.js} +37 -36
  124. package/dist/vue-ui-sparkgauge-Cz_40HEF.cjs +1 -0
  125. package/dist/{vue-ui-sparkgauge-BPhv4OLb.js → vue-ui-sparkgauge-DeshRwS5.js} +5 -4
  126. package/dist/{vue-ui-sparkhistogram-CvhqCMzj.js → vue-ui-sparkhistogram-ncgZ4wZw.js} +8 -7
  127. package/dist/vue-ui-sparkhistogram-r0bo1TVB.cjs +1 -0
  128. package/dist/{vue-ui-sparkline-TSwCmhPw.js → vue-ui-sparkline-DkisQakm.js} +4 -4
  129. package/dist/{vue-ui-sparkline-DAaH0160.cjs → vue-ui-sparkline-v244B9Zh.cjs} +1 -1
  130. package/dist/{vue-ui-sparkstackbar-BoS2_lla.js → vue-ui-sparkstackbar-C1iw9bm9.js} +7 -6
  131. package/dist/vue-ui-sparkstackbar-DXGhRt_y.cjs +1 -0
  132. package/dist/{vue-ui-stackbar-BEN8-V44.js → vue-ui-stackbar-BJVWyXjW.js} +14 -14
  133. package/dist/{vue-ui-stackbar-COZlH_nE.cjs → vue-ui-stackbar-BwLjbytq.cjs} +2 -2
  134. package/dist/{vue-ui-strip-plot-Cbd43lkd.js → vue-ui-strip-plot-BfqGpkmV.js} +11 -11
  135. package/dist/{vue-ui-strip-plot-zTtIMHMC.cjs → vue-ui-strip-plot-DyKHX-kX.cjs} +1 -1
  136. package/dist/{vue-ui-table-D3n9zK4_.cjs → vue-ui-table-DVxvUAL_.cjs} +1 -1
  137. package/dist/{vue-ui-table-Cdn-p4Sv.js → vue-ui-table-DciQKFtv.js} +1 -1
  138. package/dist/{vue-ui-table-heatmap-1gluLlyr.cjs → vue-ui-table-heatmap-BAhB_Cgh.cjs} +1 -1
  139. package/dist/{vue-ui-table-heatmap-DUoSqJAq.js → vue-ui-table-heatmap-BFmXRCdL.js} +4 -4
  140. package/dist/{vue-ui-table-sparkline-B6WbUZ-8.js → vue-ui-table-sparkline-79PG8n93.js} +8 -8
  141. package/dist/vue-ui-table-sparkline-BateR2Nz.cjs +1 -0
  142. package/dist/{vue-ui-thermometer-DO8jsmEA.cjs → vue-ui-thermometer-Bf5S9d7h.cjs} +1 -1
  143. package/dist/{vue-ui-thermometer-CYPaaRUL.js → vue-ui-thermometer-Cv2PMArr.js} +7 -7
  144. package/dist/{vue-ui-timer-BxB-pqMO.cjs → vue-ui-timer-DPqbrtc0.cjs} +1 -1
  145. package/dist/{vue-ui-timer-DVDPJaIq.js → vue-ui-timer-p0-7GCR6.js} +5 -5
  146. package/dist/{vue-ui-tiremarks-CHJQsXBn.cjs → vue-ui-tiremarks-CnevyfMg.cjs} +1 -1
  147. package/dist/{vue-ui-tiremarks-LeiTjrNE.js → vue-ui-tiremarks-DQg85vxU.js} +7 -7
  148. package/dist/{vue-ui-treemap-5vtoQA3B.cjs → vue-ui-treemap-CBRiSqHG.cjs} +1 -1
  149. package/dist/{vue-ui-treemap-D1qUMxJQ.js → vue-ui-treemap-DYf1uva6.js} +11 -11
  150. package/dist/{vue-ui-vertical-bar-BvooiWAc.cjs → vue-ui-vertical-bar-BmevaDcu.cjs} +1 -1
  151. package/dist/{vue-ui-vertical-bar-BjqeLwN6.js → vue-ui-vertical-bar-CRs5V3rk.js} +12 -12
  152. package/dist/{vue-ui-waffle-I9RUtRMp.cjs → vue-ui-waffle-VI2f9E3q.cjs} +1 -1
  153. package/dist/{vue-ui-waffle-DphHhyQF.js → vue-ui-waffle-mwsZ_eXx.js} +12 -12
  154. package/dist/{vue-ui-wheel-KJdapRnF.cjs → vue-ui-wheel-BA5MJUFr.cjs} +1 -1
  155. package/dist/{vue-ui-wheel-BloNNVqT.js → vue-ui-wheel-BrG1edQA.js} +7 -7
  156. package/dist/{vue-ui-word-cloud-BLpGQgdL.cjs → vue-ui-word-cloud-D0UHYoi6.cjs} +1 -1
  157. package/dist/{vue-ui-word-cloud-wxMpsmI9.js → vue-ui-word-cloud-Z9GyNMNG.js} +10 -10
  158. package/dist/{vue-ui-xy-Zy60Z2c1.js → vue-ui-xy-9bRzt40K.js} +15 -15
  159. package/dist/{vue-ui-xy-BEgKs6jA.cjs → vue-ui-xy-CAMdsd6U.cjs} +2 -2
  160. package/dist/{vue-ui-xy-canvas-rKk7-Q2Q.cjs → vue-ui-xy-canvas-BPxSRcBh.cjs} +3 -3
  161. package/dist/{vue-ui-xy-canvas-zINzDQlN.js → vue-ui-xy-canvas-Bfhn01pO.js} +13 -13
  162. package/package.json +3 -3
  163. package/dist/DataTable-Cybmjq2W.cjs +0 -1
  164. package/dist/PackageVersion-Bmro6-lR.cjs +0 -1
  165. package/dist/PenAndPaper-B7dv_ssy.cjs +0 -1
  166. package/dist/Slicer-Vzo3baUi.cjs +0 -1
  167. package/dist/Title-x7Hmi2zb.cjs +0 -1
  168. package/dist/jspdf.es.min-D9E1Pwzv.cjs +0 -243
  169. package/dist/purify.es-BJHiDXdY.cjs +0 -3
  170. package/dist/vue-ui-carousel-table-CdwSAavZ.cjs +0 -1
  171. package/dist/vue-ui-dashboard-2EJIfom5.cjs +0 -1
  172. package/dist/vue-ui-funnel-Btk9EM8C.cjs +0 -1
  173. package/dist/vue-ui-mini-loader-DrWDl3Hc.cjs +0 -1
  174. package/dist/vue-ui-mood-radar-vLXtDHcR.cjs +0 -1
  175. package/dist/vue-ui-rating-C7MH_wxf.js +0 -327
  176. package/dist/vue-ui-rating-WjFEnnp5.cjs +0 -1
  177. package/dist/vue-ui-sparkbar-DrG8Dq7-.cjs +0 -1
  178. package/dist/vue-ui-sparkgauge-C8JczQHv.cjs +0 -1
  179. package/dist/vue-ui-sparkhistogram-e9JHVPef.cjs +0 -1
  180. package/dist/vue-ui-sparkstackbar-r_awjtOp.cjs +0 -1
  181. package/dist/vue-ui-table-sparkline-axmTWfsW.cjs +0 -1
@@ -1,9 +1,9 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("vue"),u=require("./index-Bmq5HB9y.cjs"),d=require("./useResponsive-BJ7DTGpm.cjs"),ot=require("./Tooltip-pA64woiQ.cjs"),rt=require("./Legend-Bf8J9KZk.cjs"),nt=require("./Title-x7Hmi2zb.cjs"),ut=require("./Slicer-Vzo3baUi.cjs"),Re=require("./usePrinter-Cf6Zct5m.cjs"),st=require("./vue-ui-accordion-WWblnzaJ.cjs"),it=require("./DataTable-Cybmjq2W.cjs"),ct=require("./vue-ui-skeleton-D5890icn.cjs"),Ee=require("./useNestedProp-CivZENAh.cjs"),vt=require("./PenAndPaper-B7dv_ssy.cjs"),dt=require("./useUserOptionState-BgepsfED.cjs"),ht=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),ft=["id"],yt=["onClick"],gt={key:2,class:"vue-data-ui-watermark"},pt=["innerHTML"],mt={__name:"vue-ui-xy-canvas",props:{dataset:{type:Array,default(){return[]}},config:{type:Object,default(){return{}}}},emits:["selectLegend"],setup(oe,{expose:Ne,emit:Be}){const{vue_ui_xy_canvas:De}=u.useConfig(),p=oe,Z=l.ref(u.createUid()),B=l.ref(null),w=l.ref(null),D=l.ref(null),c=l.ref(null),g=l.ref(1),T=l.ref(1),H=l.ref(!1),f=l.ref(null),V=l.ref(""),re=l.ref(null),L=l.ref([]),R=l.ref(1),M=l.ref(!0),S=l.ref(!0),G=l.ref(null),ne=l.ref(0),ue=l.ref(0),U=l.ref(!1),se=l.ref(null),ie=l.ref(null),ce=l.ref(null),ve=l.ref(null),j=l.ref(0),J=l.ref(0),K=l.ref(0),Q=l.computed(()=>!!p.dataset&&p.dataset.length),Fe=Be,Ae=l.useSlots();l.onMounted(()=>{Ae["chart-background"]&&console.warn("VueUiXyCanvas does not support the #chart-background slot.")});const t=l.computed({get:()=>fe(),set:e=>e}),{userOptionsVisible:ee,setUserOptionsVisibility:de,keepUserOptionState:he}=dt.useUserOptionState({config:t.value});function fe(){const e=Ee.useNestedProp({userConfig:p.config,defaultConfig:De});let a={};return e.theme?a={...Ee.useNestedProp({userConfig:u.themes.vue_ui_xy_canvas[e.theme]||p.config,defaultConfig:e}),customPalette:u.themePalettes[e.theme]||u.palette}:a=e,p.config&&u.hasDeepProperty(p.config,"style.chart.scale.min")?a.style.chart.scale.min=p.config.style.chart.scale.min:a.style.chart.scale.min=null,p.config&&u.hasDeepProperty(p.config,"style.chart.scale.max")?a.style.chart.scale.max=p.config.style.chart.scale.max:a.style.chart.scale.max=null,p.config&&u.hasDeepProperty(p.config,"style.chart.zoom.startIndex")?a.style.chart.zoom.startIndex=p.config.style.chart.zoom.startIndex:a.style.chart.zoom.startIndex=null,p.config&&u.hasDeepProperty(p.config,"style.chart.zoom.endIndex")?a.style.chart.zoom.endIndex=p.config.style.chart.zoom.endIndex:a.style.chart.zoom.endIndex=null,a}l.watch(()=>p.config,e=>{t.value=fe(),ee.value=!t.value.userOptions.showOnChartHover,le(),j.value+=1,J.value+=1,K.value+=1,s.value.showTable=t.value.table.show,s.value.showDataLabels=t.value.style.chart.dataLabels.show,s.value.stacked=t.value.style.chart.stacked,s.value.showTooltip=t.value.style.chart.tooltip.show},{deep:!0}),l.watch(()=>p.dataset,()=>{le(),j.value+=1,J.value+=1,K.value+=1},{deep:!0});const ye=l.ref(t.value.style.chart.aspectRatio),{isPrinting:ge,isImaging:pe,generatePdf:me,generateImage:be}=Re.usePrinter({elementId:`xy_canvas_${Z.value}`,fileName:t.value.style.chart.title.text||"vue-ui-xy-canvas"}),s=l.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 He(e){U.value=e,ue.value+=1}const xe=l.computed(()=>u.convertCustomPalette(t.value.customPalette)),C=l.computed(()=>E.value?Math.max(...E.value.filter((e,a)=>!L.value.includes(e.absoluteIndex)).map(e=>e.series.length)):0),o=l.computed(()=>{const e=g.value-g.value*(t.value.style.chart.paddingProportions.left+t.value.style.chart.paddingProportions.right);return{canvasWidth:g.value,canvasHeight:T.value,left:g.value*t.value.style.chart.paddingProportions.left,top:T.value*t.value.style.chart.paddingProportions.top,right:g.value-g.value*t.value.style.chart.paddingProportions.right,bottom:T.value-T.value*t.value.style.chart.paddingProportions.bottom,width:e,height:T.value-T.value*(t.value.style.chart.paddingProportions.top+t.value.style.chart.paddingProportions.bottom),slot:e/(n.value.end-n.value.start)}});function ke(e,a){return e/a}function Ve({hasAutoScale:e,series:a,min:r,max:h,scale:v,yOffset:x,individualHeight:i,stackIndex:k=null}){return a.map((z,I)=>{const P=v.min<0?Math.abs(v.min):0,O=ke(z+P,P+v.max);let F,A;e&&(F=Math.abs(v.min),A=ke(z+F,v.max+F));let $=0;return k===null?$=o.value.bottom-o.value.height*(e?A:O):$=o.value.bottom-x-i*(e?A:O),{x:o.value.left+o.value.slot*I+o.value.slot/2,y:$,value:z}})}const m=l.computed(()=>{const e=t.value.style.chart.scale.min!==null?t.value.style.chart.scale.min:Math.min(...E.value.filter((i,k)=>!L.value.includes(i.absoluteIndex)).flatMap(i=>i.series.slice(n.value.start,n.value.end))),a=t.value.style.chart.scale.max!==null?t.value.style.chart.scale.max:Math.max(...E.value.filter((i,k)=>!L.value.includes(i.absoluteIndex)).flatMap(i=>i.series.slice(n.value.start,n.value.end))),r=u.calculateNiceScale(e<0?e:0,a===e?e+1<0?0:e+1:a<0?0:a,t.value.style.chart.scale.ticks),h=r.min<0?Math.abs(r.min):0,v=o.value.bottom-o.value.height*(h/(r.max+h)),x=r.ticks.map(i=>({y:o.value.bottom-o.value.height*((i+h)/(r.max+h)),x:o.value.left-8,value:i}));return{absoluteMin:h,max:a,min:e,scale:r,yLabels:x,zero:v}}),Ue=l.computed(()=>y.value.map(e=>`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("vue"),u=require("./index-BfKO0mWG.cjs"),d=require("./useResponsive-BJ7DTGpm.cjs"),ot=require("./Tooltip-TqkUkWoH.cjs"),rt=require("./Legend-CxDZJIS9.cjs"),nt=require("./Title-CUoXs-XJ.cjs"),ut=require("./Slicer-CvS2n5RR.cjs"),Re=require("./usePrinter-B3WcbJUK.cjs"),st=require("./vue-ui-accordion-CmsJv79_.cjs"),it=require("./DataTable-DN61toQQ.cjs"),ct=require("./vue-ui-skeleton-C9gd5UnC.cjs"),Ee=require("./useNestedProp-D9fZbCk6.cjs"),vt=require("./PenAndPaper-DpBM14U6.cjs"),dt=require("./useUserOptionState-BgepsfED.cjs"),ht=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),yt=["id"],ft=["onClick"],gt={key:2,class:"vue-data-ui-watermark"},pt=["innerHTML"],mt={__name:"vue-ui-xy-canvas",props:{dataset:{type:Array,default(){return[]}},config:{type:Object,default(){return{}}}},emits:["selectLegend"],setup(oe,{expose:Ne,emit:Be}){const{vue_ui_xy_canvas:De}=u.useConfig(),p=oe,Z=l.ref(u.createUid()),B=l.ref(null),w=l.ref(null),D=l.ref(null),c=l.ref(null),g=l.ref(1),T=l.ref(1),H=l.ref(!1),y=l.ref(null),V=l.ref(""),re=l.ref(null),L=l.ref([]),R=l.ref(1),M=l.ref(!0),S=l.ref(!0),G=l.ref(null),ne=l.ref(0),ue=l.ref(0),U=l.ref(!1),se=l.ref(null),ie=l.ref(null),ce=l.ref(null),ve=l.ref(null),j=l.ref(0),J=l.ref(0),K=l.ref(0),Q=l.computed(()=>!!p.dataset&&p.dataset.length),Fe=Be,Ae=l.useSlots();l.onMounted(()=>{Ae["chart-background"]&&console.warn("VueUiXyCanvas does not support the #chart-background slot.")});const t=l.computed({get:()=>ye(),set:e=>e}),{userOptionsVisible:ee,setUserOptionsVisibility:de,keepUserOptionState:he}=dt.useUserOptionState({config:t.value});function ye(){const e=Ee.useNestedProp({userConfig:p.config,defaultConfig:De});let a={};return e.theme?a={...Ee.useNestedProp({userConfig:u.themes.vue_ui_xy_canvas[e.theme]||p.config,defaultConfig:e}),customPalette:u.themePalettes[e.theme]||u.palette}:a=e,p.config&&u.hasDeepProperty(p.config,"style.chart.scale.min")?a.style.chart.scale.min=p.config.style.chart.scale.min:a.style.chart.scale.min=null,p.config&&u.hasDeepProperty(p.config,"style.chart.scale.max")?a.style.chart.scale.max=p.config.style.chart.scale.max:a.style.chart.scale.max=null,p.config&&u.hasDeepProperty(p.config,"style.chart.zoom.startIndex")?a.style.chart.zoom.startIndex=p.config.style.chart.zoom.startIndex:a.style.chart.zoom.startIndex=null,p.config&&u.hasDeepProperty(p.config,"style.chart.zoom.endIndex")?a.style.chart.zoom.endIndex=p.config.style.chart.zoom.endIndex:a.style.chart.zoom.endIndex=null,a}l.watch(()=>p.config,e=>{t.value=ye(),ee.value=!t.value.userOptions.showOnChartHover,le(),j.value+=1,J.value+=1,K.value+=1,s.value.showTable=t.value.table.show,s.value.showDataLabels=t.value.style.chart.dataLabels.show,s.value.stacked=t.value.style.chart.stacked,s.value.showTooltip=t.value.style.chart.tooltip.show},{deep:!0}),l.watch(()=>p.dataset,()=>{le(),j.value+=1,J.value+=1,K.value+=1},{deep:!0});const fe=l.ref(t.value.style.chart.aspectRatio),{isPrinting:ge,isImaging:pe,generatePdf:me,generateImage:be}=Re.usePrinter({elementId:`xy_canvas_${Z.value}`,fileName:t.value.style.chart.title.text||"vue-ui-xy-canvas"}),s=l.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 He(e){U.value=e,ue.value+=1}const xe=l.computed(()=>u.convertCustomPalette(t.value.customPalette)),C=l.computed(()=>E.value?Math.max(...E.value.filter((e,a)=>!L.value.includes(e.absoluteIndex)).map(e=>e.series.length)):0),o=l.computed(()=>{const e=g.value-g.value*(t.value.style.chart.paddingProportions.left+t.value.style.chart.paddingProportions.right);return{canvasWidth:g.value,canvasHeight:T.value,left:g.value*t.value.style.chart.paddingProportions.left,top:T.value*t.value.style.chart.paddingProportions.top,right:g.value-g.value*t.value.style.chart.paddingProportions.right,bottom:T.value-T.value*t.value.style.chart.paddingProportions.bottom,width:e,height:T.value-T.value*(t.value.style.chart.paddingProportions.top+t.value.style.chart.paddingProportions.bottom),slot:e/(n.value.end-n.value.start)}});function ke(e,a){return e/a}function Ve({hasAutoScale:e,series:a,min:r,max:h,scale:v,yOffset:x,individualHeight:i,stackIndex:k=null}){return a.map((z,I)=>{const P=v.min<0?Math.abs(v.min):0,O=ke(z+P,P+v.max);let F,A;e&&(F=v.min,A=ke(z-F,v.max-F));let $=0;return k===null?$=o.value.bottom-o.value.height*(e?A:O):$=o.value.bottom-x-i*(e?A:O),{x:o.value.left+o.value.slot*I+o.value.slot/2,y:$,value:z}})}const m=l.computed(()=>{const e=t.value.style.chart.scale.min!==null?t.value.style.chart.scale.min:Math.min(...E.value.filter((i,k)=>!L.value.includes(i.absoluteIndex)).flatMap(i=>i.series.slice(n.value.start,n.value.end))),a=t.value.style.chart.scale.max!==null?t.value.style.chart.scale.max:Math.max(...E.value.filter((i,k)=>!L.value.includes(i.absoluteIndex)).flatMap(i=>i.series.slice(n.value.start,n.value.end))),r=u.calculateNiceScale(e<0?e:0,a===e?e+1<0?0:e+1:a<0?0:a,t.value.style.chart.scale.ticks),h=r.min<0?Math.abs(r.min):0,v=o.value.bottom-o.value.height*(h/(r.max+h)),x=r.ticks.map(i=>({y:o.value.bottom-o.value.height*((i+h)/(r.max+h)),x:o.value.left-8,value:i}));return{absoluteMin:h,max:a,min:e,scale:r,yLabels:x,zero:v}}),Ue=l.computed(()=>f.value.map(e=>`
2
2
  <div style="display:flex;flex-direction:row;gap:6px;align-items:center;">
3
3
  <svg viewBox="0 0 10 10" height="12" width="12">
4
4
  <circle cx="5" cy="5" r="5" fill="${e.color}"/>
5
5
  </svg>
6
6
  <span>${e.name?e.name+": ":""}</span>
7
- <span>${u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.series[f.value],u.dataLabel({p:e.prefix||"",v:e.series[f.value],s:e.suffix||"",r:e.rounding||0}),{datapoint:e,seriesIndex:f.value})}</span>
7
+ <span>${u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.series[y.value],u.dataLabel({p:e.prefix||"",v:e.series[y.value],s:e.suffix||"",r:e.rounding||0}),{datapoint:e,seriesIndex:y.value})}</span>
8
8
  </div>
9
- `)),E=l.computed(()=>p.dataset.map((e,a)=>({...e,series:u.largestTriangleThreeBucketsArray({data:u.sanitizeArray(e.series),threshold:t.value.downsample.threshold}),absoluteIndex:a,color:u.convertColorToHex(e.color||xe.value[a]||u.palette[a]||u.palette[a%u.palette.length])})));l.watch(C,e=>{e&&Le()});const y=l.computed(()=>u.assignStackRatios(E.value.filter((e,a)=>!L.value.includes(e.absoluteIndex))).map((e,a)=>({...e,series:e.series.slice(n.value.start,n.value.end)})).map((e,a)=>{let r=[null,void 0].includes(e.scaleMin)?Math.min(...e.series)||0:e.scaleMin,h=[null,void 0].includes(e.scaleMax)?Math.max(...e.series)||1:e.scaleMax;r===h&&(r=r>=0?h-1:r,h=h>=0?h:r+1),e.series.filter($=>![null,void 0].includes($)).map($=>($-r)/(h-r));const v={valueMin:r,valueMax:h},x=e.scaleSteps||t.value.style.chart.scale.ticks;let i;e.autoScaling?i=u.calculateNiceScale(v.valueMin,v.valueMax,x):i=u.calculateNiceScale(v.valueMin<0?v.valueMin:0,v.valueMax<=0?0:v.valueMax,x);const k=s.value.stacked?o.value.height*(1-e.cumulatedStackRatio):0,z=s.value.stacked?o.value.height/t.value.style.chart.stackGap:0,I=s.value.stacked?o.value.height*e.stackRatio-z:o.value.height,P=i.min<0?Math.abs(i.min):0;let O;e.autoScaling&&s.value.stacked&&h<=0?O=o.value.bottom-k-I:O=o.value.bottom-k-I*(P/(i.max+P));const F=i.ticks.map(($,at)=>({y:o.value.bottom-k-I*(at/(i.ticks.length-1)),x:o.value.left-8,value:$})),A=Ve({hasAutoScale:s.value.stacked&&e.autoScaling,series:e.series,min:s.value.stacked?r:m.value.min,max:s.value.stacked?h:m.value.max,scale:s.value.stacked?i:m.value.scale,yOffset:k,individualHeight:I,stackIndex:s.value.stacked?a:null});return{...e,coordinatesLine:A,min:r,max:h,localScale:i,localZero:O,localMin:P,localYLabels:F,yOffset:k,individualHeight:I}})),n=l.ref({start:0,end:C.value});function Le(){Ce()}const N=l.ref(null);async function Ce(){(t.value.style.chart.zoom.startIndex!==null||t.value.style.chart.zoom.endIndex!==null)&&N.value?(t.value.style.chart.zoom.startIndex!==null&&(await l.nextTick(),await l.nextTick(),N.value&&N.value.setStartValue(t.value.style.chart.zoom.startIndex)),t.value.style.chart.zoom.endIndex!==null&&(await l.nextTick(),await l.nextTick(),N.value&&N.value.setEndValue(_e(t.value.style.chart.zoom.endIndex+1)))):(n.value={start:0,end:C.value},ne.value+=1)}function _e(e){const a=C.value;return e>a?a:e<0||t.value.style.chart.zoom.startIndex!==null&&e<t.value.style.chart.zoom.startIndex?t.value.style.chart.zoom.startIndex!==null?t.value.style.chart.zoom.startIndex+1:1:e}const qe=l.computed(()=>y.value.filter(e=>["line","plot",void 0].includes(e.type))),b=l.computed(()=>y.value.filter(e=>e.type==="bar"));function We(){if(!w.value)return;const e=D.value.offsetWidth,a=D.value.offsetHeight;w.value.width=e*R.value*2,w.value.height=a*R.value*2,g.value=e*R.value*2,T.value=a*R.value*2,c.value.scale(R.value,R.value),te()}function Xe(){if(c.value.clearRect(0,0,1e4,1e4),c.value.fillStyle=t.value.style.chart.backgroundColor,c.value.fillRect(0,0,o.value.canvasWidth,o.value.canvasHeight),s.value.stacked)t.value.style.chart.grid.y.verticalLines.show&&n.value.end-n.value.start<t.value.style.chart.grid.y.verticalLines.hideUnderXLength?y.value.forEach(e=>{for(let a=0;a<n.value.end-n.value.start+1;a+=1)d.line(c.value,[{x:o.value.left+o.value.slot*a,y:o.value.bottom-e.yOffset-e.individualHeight},{x:o.value.left+o.value.slot*a,y:o.value.bottom-e.yOffset}],{color:t.value.style.chart.grid.y.verticalLines.color})}):t.value.style.chart.grid.y.verticalLines.show&&n.value.end-n.value.start>=t.value.style.chart.grid.y.verticalLines.hideUnderXLength&&y.value.forEach(e=>{for(let a=n.value.start;a<n.value.end;a+=1)a%Math.floor((n.value.end-n.value.start)/t.value.style.chart.grid.y.timeLabels.modulo)===0&&d.line(c.value,[{x:o.value.left+o.value.slot*(a-n.value.start)+o.value.slot/2,y:o.value.bottom-e.yOffset-e.individualHeight},{x:o.value.left+o.value.slot*(a-n.value.start)+o.value.slot/2,y:o.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((a,r)=>{r<e.localYLabels.length-1&&d.rect(c.value,[{x:o.value.left,y:a.y},{x:o.value.right,y:a.y},{x:o.value.right,y:e.localYLabels[r+1].y},{x:o.value.left,y:e.localYLabels[r+1].y}],{fillColor:r%2===0?"transparent":u.setOpacity(t.value.style.chart.grid.x.horizontalLines.color,t.value.style.chart.grid.x.horizontalLines.opacity),strokeColor:"transparent"})})}):y.value.forEach(e=>{e.localYLabels.slice(n.value.start,n.value.end).forEach(a=>{d.line(c.value,[{x:o.value.left,y:a.y},{x:o.value.right,y:a.y}],{color:t.value.style.chart.grid.x.horizontalLines.color})})})),t.value.style.chart.grid.zeroLine.show&&y.value.forEach(e=>{d.line(c.value,[{x:o.value.left,y:e.localZero},{x:o.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=>{d.line(c.value,[{x:o.value.left,y:o.value.bottom-e.yOffset},{x:o.value.left,y:o.value.bottom-e.yOffset-e.individualHeight}],{color:e.color}),d.line(c.value,[{x:o.value.right,y:o.value.bottom-e.yOffset},{x:o.value.right,y:o.value.bottom-e.yOffset-e.individualHeight}],{color:e.color}),e.localYLabels.forEach((a,r)=>{d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,a.value,u.dataLabel({p:e.prefix||t.value.style.chart.grid.y.axisLabels.prefix||"",v:a.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:a,seriesIndex:r}),a.x+t.value.style.chart.grid.y.axisLabels.offsetX,a.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=>{d.text(c.value,e.name,g.value/35,o.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&&n.value.end-n.value.start<t.value.style.chart.grid.y.verticalLines.hideUnderXLength)for(let e=0;e<n.value.end-n.value.start+1;e+=1)d.line(c.value,[{x:o.value.left+o.value.slot*e,y:o.value.top},{x:o.value.left+o.value.slot*e,y:o.value.bottom}],{color:t.value.style.chart.grid.y.verticalLines.color});else if(t.value.style.chart.grid.y.verticalLines.show&&n.value.end-n.value.start>=t.value.style.chart.grid.y.verticalLines.hideUnderXLength)for(let e=n.value.start;e<n.value.end;e+=1)e%Math.floor((n.value.end-n.value.start)/t.value.style.chart.grid.y.timeLabels.modulo)===0&&d.line(c.value,[{x:o.value.left+o.value.slot*(e-n.value.start)+o.value.slot/2,y:o.value.top},{x:o.value.left+o.value.slot*(e-n.value.start)+o.value.slot/2,y:o.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?m.value.yLabels.forEach((e,a)=>{a<m.value.yLabels.length-1&&d.rect(c.value,[{x:o.value.left,y:e.y},{x:o.value.right,y:e.y},{x:o.value.right,y:m.value.yLabels[a+1].y},{x:o.value.left,y:m.value.yLabels[a+1].y}],{fillColor:a%2===0?"transparent":u.setOpacity(t.value.style.chart.grid.x.horizontalLines.color,t.value.style.chart.grid.x.horizontalLines.opacity),strokeColor:"transparent"})}):m.value.yLabels.forEach(e=>{d.line(c.value,[{x:o.value.left,y:e.y},{x:o.value.right,y:e.y}],{color:t.value.style.chart.grid.x.horizontalLines.color})})),t.value.style.chart.grid.y.showAxis&&d.line(c.value,[{x:o.value.left,y:o.value.top},{x:o.value.left,y:o.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&&d.line(c.value,[{x:o.value.left,y:o.value.bottom},{x:o.value.right,y:o.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&&d.line(c.value,[{x:o.value.left,y:m.value.zero},{x:o.value.right,y:m.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&&m.value.yLabels.forEach((e,a)=>{d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.value,u.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:a}),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&&d.text(c.value,t.value.style.chart.grid.y.axisName,g.value-g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio*1.2,o.value.bottom-o.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&&d.text(c.value,t.value.style.chart.grid.x.axisName,g.value/2,T.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 Ye(e){for(let a=0;a<e.coordinatesLine.length;a+=1){const r=(f.value===a?g.value/150:t.value.style.chart.line.plots.show?g.value/200:0)*t.value.style.chart.line.plots.radiusRatio;d.circle(c.value,{x:e.coordinatesLine[a].x,y:e.coordinatesLine[a].y},r,{color:t.value.style.chart.backgroundColor,fillStyle:e.color})}}function Ze(e){for(let a=0;a<e.coordinatesLine.length;a+=1)d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.coordinatesLine[a].value,u.dataLabel({p:e.prefix||"",v:e.coordinatesLine[a].value,s:e.suffix||"",r:e.rounding||0}),{datapoint:e.coordinatesLine[a],seriesIndex:a}),e.coordinatesLine[a].x,e.coordinatesLine[a].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 Ge(){for(let e=n.value.start;e<n.value.end;e+=1)(n.value.end-n.value.start<t.value.style.chart.grid.y.timeLabels.modulo||n.value.end-n.value.start>=t.value.style.chart.grid.y.timeLabels.modulo&&(e%Math.floor((n.value.end-n.value.start)/t.value.style.chart.grid.y.timeLabels.modulo)===0||e===f.value+n.value.start))&&d.text(c.value,t.value.style.chart.grid.y.timeLabels.values[e]||e+1,o.value.left+o.value.slot*(e-n.value.start)+o.value.slot/2,o.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:u.setOpacity(t.value.style.chart.grid.y.timeLabels.color,f.value!==null?f.value+n.value.start===e?100:20:100),rotation:t.value.style.chart.grid.y.timeLabels.rotation})}function we(){d.line(c.value,[{x:o.value.left+o.value.slot*f.value+o.value.slot/2,y:o.value.top},{x:o.value.left+o.value.slot*f.value+o.value.slot/2,y:o.value.bottom}],{color:t.value.style.chart.selector.color,lineDash:t.value.style.chart.selector.dashed?[8,8]:[0,0],lineWidth:2})}function je(){b.value.forEach((e,a)=>{for(let r=0;r<e.coordinatesLine.length;r+=1)d.rect(c.value,[{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a)),y:s.value.stacked?e.localZero:m.value.zero},{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a))+o.value.slot*.8/(s.value.stacked?1:b.value.length),y:s.value.stacked?e.localZero:m.value.zero},{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a))+o.value.slot*.8/(s.value.stacked?1:b.value.length),y:e.coordinatesLine[r].y},{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a)),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:m.value.zero},stops:[{offset:0,color:e.color},{offset:1,color:u.lightenHexColor(e.color,.5)}]}}),s.value.showDataLabels&&[!0,void 0].includes(e.dataLabels)&&d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.coordinatesLine[r].value,u.dataLabel({p:e.prefix||"",v:e.coordinatesLine[r].value,s:e.suffix||"",r:e.rounding||0}),{datapoint:e.coordinatesLine[r],seriesIndex:r}),o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a))+o.value.slot*.4/(s.value.stacked?1:b.value.length),(e.coordinatesLine[r].value<0?s.value.stacked?e.localZero:m.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 Je(e){e.useArea?s.value.stacked?d.polygon(c.value,[{x:e.coordinatesLine[0].x,y:e.localZero},...e.coordinatesLine,{x:e.coordinatesLine.at(-1).x,y:e.localZero}],{fillColor:u.setOpacity(e.color,t.value.style.chart.area.opacity),strokeColor:"transparent"}):d.polygon(c.value,[{x:e.coordinatesLine[0].x,y:m.value.zero},...e.coordinatesLine,{x:e.coordinatesLine.at(-1).x,y:m.value.zero}],{fillColor:u.setOpacity(e.color,t.value.style.chart.area.opacity),strokeColor:"transparent"}):d.line(c.value,e.coordinatesLine,{color:e.color,lineWidth:3})}function Ke(){y.value.forEach((e,a)=>{d.line(c.value,[{x:o.value.left,y:o.value.bottom-e.yOffset},{x:o.value.right,y:o.value.bottom-e.yOffset}],{color:t.value.style.chart.grid.x.horizontalLines.color,lineWidth:1})})}function te(){Xe(),M.value?(S.value&&f.value!==null&&t.value.style.chart.selector.show&&we(),je(),s.value.stacked&&t.value.style.chart.grid.x.showAxis&&Ke(),qe.value.forEach(e=>{(e.type==="line"||!e.type)&&Je(e),S.value&&(Ye(e),s.value.showDataLabels&&[!0,void 0].includes(e.dataLabels)&&Ze(e))}),G.value=d.cloneCanvas(w.value)):(G.value&&(c.value.clearRect(0,0,1e4,1e4),c.value.drawImage(G.value,0,0)),S.value&&f.value!==null&&t.value.style.chart.selector.show&&we(),S.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&&d.circle(c.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})}})),t.value.style.chart.grid.y.timeLabels.show&&Ge(),M.value=!1}const _=d.debounce(()=>{S.value=!0,We()},C.value>200?10:1,!S.value);function Qe(e){const{left:a}=w.value.getBoundingClientRect(),r=e.clientX-a;if(r*2<o.value.left||r*2>o.value.right){H.value=!1,f.value=null;return}const h=r*2-o.value.left;if(f.value=Math.floor(h/o.value.slot),H.value=!0,!S.value)return;let v="";const x=t.value.style.chart.tooltip.customFormat;u.isFunction(x)&&u.functionReturnsString(()=>x({seriesIndex:f.value,datapoint:y.value.map(i=>({shape:i.shape||null,name:i.name,color:i.color,type:i.type||"line",value:i.series.find((k,z)=>z===f.value)})),series:y.value,config:t.value}))?V.value=x({seriesIndex:f.value,datapoint:y.value.map(i=>({shape:i.shape||null,name:i.name,color:i.color,type:i.type||"line",value:i.series.find((k,z)=>z===f.value)})),series:y.value,config:t.value}):(t.value.style.chart.grid.y.timeLabels.values.slice(n.value.start,n.value.end)[f.value]&&(v+=`<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(n.value.start,n.value.end)[f.value]}</div>`),v+=Ue.value.join(""),V.value=v),S.value=!1}l.watch(()=>f.value,e=>{_()}),l.watch(()=>n.value,e=>{M.value=!0,te()},{deep:!0}),l.watch(()=>s.value.showDataLabels,e=>{M.value=!0,te()}),l.watch(()=>s.value.stacked,e=>{M.value=!0,S.value=!0,_()});function et(){H.value=!1,f.value=null,V.value=""}const q=l.ref(null),W=l.ref(null);l.onMounted(()=>{le()});function le(){if(u.objectIsEmpty(p.dataset)?u.error({componentName:"VueUiXyCanvas",type:"dataset"}):w.value&&(c.value=w.value.getContext("2d",{willReadFrequently:!0})),t.value.responsive){const e=d.throttle(()=>{const{width:a,height:r}=d.useResponsive({chart:B.value,title:t.value.style.chart.title.text?se.value:null,legend:t.value.style.chart.legend.show?ie.value:null,slicer:t.value.style.chart.zoom.show&&C.value>1?ce.value:null,source:ve.value});requestAnimationFrame(()=>{ye.value=`${a} / ${r}`})});q.value=new ResizeObserver(e),q.value.observe(B.value.parentNode)}W.value=new ResizeObserver(e=>{for(const a of e)a.contentBoxSize&&D.value&&(M.value=!0,_())}),W.value.observe(D.value),Ce()}l.onBeforeUnmount(()=>{W.value&&W.value.disconnect(),q.value&&q.value.disconnect()});function Se(e){Fe("selectLegend",y.value.find(a=>a.absoluteIndex===e)),L.value.includes(e)?L.value=L.value.filter(a=>a!==e):L.value.push(e),M.value=!0,_()}const ze=l.computed(()=>E.value.map((e,a)=>({...e,name:e.name,color:u.convertColorToHex(e.color)||xe.value[a]||u.palette[a]||u.palette[a%u.palette.length],shape:e.shape||"circle",prefix:e.prefix||"",suffix:e.suffix||"",rounding:e.rounding||0})).map(e=>({...e,opacity:L.value.includes(e.absoluteIndex)?.5:1,segregate:()=>Se(e.absoluteIndex),isSegregated:L.value.includes(e.absoluteIndex)}))),tt=l.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":""})),X=l.computed(()=>{const e=[""].concat(y.value.map(v=>v.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 a=[];for(let v=0;v<C.value;v+=1){const x=y.value.map(i=>i.series[v]??0).reduce((i,k)=>i+k,0);a.push([t.value.style.chart.grid.y.timeLabels.values.slice(n.value.start,n.value.end)[v]??v+1].concat(y.value.map(i=>(i.series[v]??0).toFixed(t.value.table.rounding))).concat((x??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},h=[t.value.table.columnNames.period].concat(y.value.map(v=>v.name)).concat(t.value.table.columnNames.total);return{head:e,body:a.slice(0,n.value.end-n.value.start),config:r,colNames:h}}),$e=l.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})),a=[];for(let r=n.value.start;r<n.value.end;r+=1){const h=[t.value.style.chart.grid.y.timeLabels.values[r]||r+1];y.value.forEach(v=>{h.push(Number((v.series[r]||0).toFixed(t.value.table.rounding)))}),a.push(h)}return{head:e,body:a}});function Te(){const e=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[""]],a=["",...$e.value.head.map(x=>x.label)],r=$e.value.body,h=e.concat([a]).concat(r),v=u.createCsvContent(h);u.downloadCsv({csvContent:v,title:t.value.style.chart.title.text||"vue-ui-xy-canvas"})}function lt(){return y.value}function Ie(){s.value.showTable=!s.value.showTable}function Pe(){s.value.showDataLabels=!s.value.showDataLabels}function Me(){s.value.stacked=!s.value.stacked}function Oe(){s.value.showTooltip=!s.value.showTooltip}const Y=l.ref(!1);function ae(){Y.value=!Y.value}return Ne({getData:lt,generateCsv:Te,generatePdf:me,generateImage:be,toggleTable:Ie,toggleLabels:Pe,toggleStack:Me,toggleTooltip:Oe,toggleAnnotator:ae}),(e,a)=>(l.openBlock(),l.createElementBlock("div",{style:l.normalizeStyle(`width:100%; position:relative; ${t.value.responsive?"height: 100%":""}`),ref_key:"xy",ref:B,id:`xy_canvas_${Z.value}`,class:l.normalizeClass(`vue-ui-donut ${U.value?"vue-data-ui-wrapper-fullscreen":""}`),onMouseenter:a[5]||(a[5]=()=>l.unref(de)(!0)),onMouseleave:a[6]||(a[6]=()=>l.unref(de)(!1))},[t.value.style.chart.title.text?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:se,style:l.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};`)},[(l.openBlock(),l.createBlock(nt._sfc_main,{key:`title_${j.value}`,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)):l.createCommentVNode("",!0),t.value.userOptions.show&&Q.value&&(l.unref(he)||l.unref(ee))?(l.openBlock(),l.createBlock(Re.UserOptions,{ref:"details",key:`user_option_${ue.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:l.unref(ge),isImaging:l.unref(pe),uid:Z.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:oe.dataset.length>1&&t.value.userOptions.buttons.stack,hasFullscreen:t.value.userOptions.buttons.fullscreen,hasTable:n.value.end-n.value.start<200&&t.value.userOptions.buttons.table,isFullscreen:U.value,isTooltip:s.value.showTooltip,isStacked:s.value.stacked,titles:{...t.value.userOptions.buttonTitles},chartElement:B.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:Y.value,onToggleFullscreen:He,onGeneratePdf:l.unref(me),onGenerateCsv:Te,onGenerateImage:l.unref(be),onToggleTable:Ie,onToggleLabels:Pe,onToggleStack:Me,onToggleTooltip:Oe,onToggleAnnotator:ae,style:l.normalizeStyle({visibility:l.unref(he)?l.unref(ee)?"visible":"hidden":"visible"})},l.createSlots({_:2},[e.$slots.optionTooltip?{name:"optionTooltip",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,e.$slots.optionPdf?{name:"optionPdf",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,e.$slots.optionCsv?{name:"optionCsv",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,e.$slots.optionImg?{name:"optionImg",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,e.$slots.optionTable?{name:"optionTable",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,e.$slots.optionLabels?{name:"optionLabels",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionLabels",{},void 0,!0)]),key:"5"}:void 0,e.$slots.optionStack?{name:"optionStack",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionStack",{},void 0,!0)]),key:"6"}:void 0,e.$slots.optionFullscreen?{name:"optionFullscreen",fn:l.withCtx(({toggleFullscreen:r,isFullscreen:h})=>[l.renderSlot(e.$slots,"optionFullscreen",l.normalizeProps(l.guardReactiveProps({toggleFullscreen:r,isFullscreen:h})),void 0,!0)]),key:"7"}:void 0,e.$slots.optionAnnotator?{name:"optionAnnotator",fn:l.withCtx(({toggleAnnotator:r,isAnnotator:h})=>[l.renderSlot(e.$slots,"optionAnnotator",l.normalizeProps(l.guardReactiveProps({toggleAnnotator:r,isAnnotator:h})),void 0,!0)]),key:"8"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasImg","hasXls","hasLabel","hasStack","hasFullscreen","hasTable","isFullscreen","isTooltip","isStacked","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):l.createCommentVNode("",!0),l.createElementVNode("div",{class:"vue-ui-xy-canvas",style:l.normalizeStyle(`position: relative; aspect-ratio: ${ye.value}`),ref_key:"container",ref:D},[Q.value?(l.openBlock(),l.createElementBlock("canvas",{key:0,ref_key:"canvas",ref:w,style:{width:"100%",height:"100%"},onMousemove:a[0]||(a[0]=r=>Qe(r)),onMouseleave:et},null,544)):(l.openBlock(),l.createBlock(ct.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"])),l.createVNode(ot._sfc_main,{show:s.value.showTooltip&&H.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:w.value,content:V.value,isFullscreen:U.value,backgroundOpacity:t.value.style.chart.tooltip.backgroundOpacity,isCustom:l.unref(u.isFunction)(t.value.style.chart.tooltip.customFormat)},{"tooltip-before":l.withCtx(()=>[l.renderSlot(e.$slots,"tooltip-before",l.normalizeProps(l.guardReactiveProps({...re.value})),void 0,!0)]),"tooltip-after":l.withCtx(()=>[l.renderSlot(e.$slots,"tooltip-after",l.normalizeProps(l.guardReactiveProps({...re.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","fontSize","borderRadius","borderColor","borderWidth","position","offsetY","parent","content","isFullscreen","backgroundOpacity","isCustom"])],4),l.createElementVNode("div",{ref_key:"chartSlicer",ref:ce,style:l.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor}`),"data-html2canvas-ignore":""},[t.value.style.chart.zoom.show&&C.value>1?(l.openBlock(),l.createBlock(ut.Slicer,{ref_key:"slicerComponent",ref:N,key:`slicer_${ne.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[n.value.start]?t.value.style.chart.grid.y.timeLabels.values[n.value.start]:"",labelRight:t.value.style.chart.grid.y.timeLabels.values[n.value.end-1]?t.value.style.chart.grid.y.timeLabels.values[n.value.end-1]:"",textColor:t.value.style.chart.color,inputColor:t.value.style.chart.zoom.color,selectColor:t.value.style.chart.zoom.highlightColor,max:C.value,min:0,valueStart:n.value.start,valueEnd:n.value.end,start:n.value.start,"onUpdate:start":a[1]||(a[1]=r=>n.value.start=r),end:n.value.end,"onUpdate:end":a[2]||(a[2]=r=>n.value.end=r),refreshStartPoint:t.value.style.chart.zoom.startIndex!==null?t.value.style.chart.zoom.startIndex:0,refreshEndPoint:t.value.style.chart.zoom.endIndex!==null?t.value.style.chart.zoom.endIndex+1:C.value,enableRangeHandles:t.value.style.chart.zoom.enableRangeHandles,enableSelectionDrag:t.value.style.chart.zoom.enableSelectionDrag,onReset:Le},{"reset-action":l.withCtx(({reset:r})=>[l.renderSlot(e.$slots,"reset-action",l.normalizeProps(l.guardReactiveProps({reset:r})),void 0,!0)]),_:3},8,["background","borderColor","fontSize","useResetSlot","labelLeft","labelRight","textColor","inputColor","selectColor","max","valueStart","valueEnd","start","end","refreshStartPoint","refreshEndPoint","enableRangeHandles","enableSelectionDrag"])):l.createCommentVNode("",!0)],4),l.createElementVNode("div",{ref_key:"chartLegend",ref:ie},[t.value.style.chart.legend.show&&Q.value?(l.openBlock(),l.createBlock(rt.Legend,{legendSet:ze.value,config:tt.value,key:`legend_${K.value}`,onClickMarker:a[3]||(a[3]=({i:r})=>Se(r))},{item:l.withCtx(({legend:r,index:h})=>[l.createElementVNode("div",{onClick:v=>r.segregate(),style:l.normalizeStyle(`opacity:${L.value.includes(h)?.5:1}`)},l.toDisplayString(r.name),13,yt)]),_:1},8,["legendSet","config"])):l.renderSlot(e.$slots,"legend",{key:1,legend:ze.value},void 0,!0)],512),e.$slots.watermark?(l.openBlock(),l.createElementBlock("div",gt,[l.renderSlot(e.$slots,"watermark",l.normalizeProps(l.guardReactiveProps({isPrinting:l.unref(ge)||l.unref(pe)})),void 0,!0)])):l.createCommentVNode("",!0),e.$slots.source?(l.openBlock(),l.createElementBlock("div",{key:3,ref_key:"source",ref:ve,dir:"auto"},[l.renderSlot(e.$slots,"source",{},void 0,!0)],512)):l.createCommentVNode("",!0),n.value.end-n.value.start<200?(l.openBlock(),l.createBlock(st.default,{key:4,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:l.withCtx(()=>[(l.openBlock(),l.createBlock(it.DataTable,{key:`table_${J.value}`,colNames:X.value.colNames,head:X.value.head,body:X.value.body,config:X.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:a[4]||(a[4]=r=>s.value.showTable=!1)},{th:l.withCtx(({th:r})=>[l.createElementVNode("div",{innerHTML:r},null,8,pt)]),td:l.withCtx(({td:r})=>[l.createTextVNode(l.toDisplayString(r),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):l.createCommentVNode("",!0),t.value.userOptions.buttons.annotator&&y.value.length?(l.openBlock(),l.createBlock(vt.PenAndPaper,{key:5,parent:B.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:Y.value,onClose:ae},null,8,["parent","backgroundColor","color","active"])):l.createCommentVNode("",!0)],46,ft))}},bt=ht._export_sfc(mt,[["__scopeId","data-v-13fe7bc4"]]);exports.default=bt;
9
+ `)),E=l.computed(()=>p.dataset.map((e,a)=>({...e,series:u.largestTriangleThreeBucketsArray({data:u.sanitizeArray(e.series),threshold:t.value.downsample.threshold}),absoluteIndex:a,color:u.convertColorToHex(e.color||xe.value[a]||u.palette[a]||u.palette[a%u.palette.length])})));l.watch(C,e=>{e&&Le()});const f=l.computed(()=>u.assignStackRatios(E.value.filter((e,a)=>!L.value.includes(e.absoluteIndex))).map((e,a)=>({...e,series:e.series.slice(n.value.start,n.value.end)})).map((e,a)=>{let r=[null,void 0].includes(e.scaleMin)?Math.min(...e.series)||0:e.scaleMin,h=[null,void 0].includes(e.scaleMax)?Math.max(...e.series)||1:e.scaleMax;r===h&&(r=r>=0?h-1:r,h=h>=0?h:r+1),e.series.filter($=>![null,void 0].includes($)).map($=>($-r)/(h-r));const v={valueMin:r,valueMax:h},x=e.scaleSteps||t.value.style.chart.scale.ticks;let i;e.autoScaling?i=u.calculateNiceScale(v.valueMin,v.valueMax,x):i=u.calculateNiceScale(v.valueMin<0?v.valueMin:0,v.valueMax<=0?0:v.valueMax,x);const k=s.value.stacked?o.value.height*(1-e.cumulatedStackRatio):0,z=s.value.stacked?o.value.height/t.value.style.chart.stackGap:0,I=s.value.stacked?o.value.height*e.stackRatio-z:o.value.height,P=i.min<0?Math.abs(i.min):0;let O;e.autoScaling&&s.value.stacked&&h<=0?O=o.value.bottom-k-I:O=o.value.bottom-k-I*(P/(i.max+P));const F=i.ticks.map(($,at)=>({y:o.value.bottom-k-I*(at/(i.ticks.length-1)),x:o.value.left-8,value:$})),A=Ve({hasAutoScale:s.value.stacked&&e.autoScaling,series:e.series,min:s.value.stacked?r:m.value.min,max:s.value.stacked?h:m.value.max,scale:s.value.stacked?i:m.value.scale,yOffset:k,individualHeight:I,stackIndex:s.value.stacked?a:null});return{...e,coordinatesLine:A,min:r,max:h,localScale:i,localZero:O,localMin:P,localYLabels:F,yOffset:k,individualHeight:I}})),n=l.ref({start:0,end:C.value});function Le(){Ce()}const N=l.ref(null);async function Ce(){(t.value.style.chart.zoom.startIndex!==null||t.value.style.chart.zoom.endIndex!==null)&&N.value?(t.value.style.chart.zoom.startIndex!==null&&(await l.nextTick(),await l.nextTick(),N.value&&N.value.setStartValue(t.value.style.chart.zoom.startIndex)),t.value.style.chart.zoom.endIndex!==null&&(await l.nextTick(),await l.nextTick(),N.value&&N.value.setEndValue(_e(t.value.style.chart.zoom.endIndex+1)))):(n.value={start:0,end:C.value},ne.value+=1)}function _e(e){const a=C.value;return e>a?a:e<0||t.value.style.chart.zoom.startIndex!==null&&e<t.value.style.chart.zoom.startIndex?t.value.style.chart.zoom.startIndex!==null?t.value.style.chart.zoom.startIndex+1:1:e}const qe=l.computed(()=>f.value.filter(e=>["line","plot",void 0].includes(e.type))),b=l.computed(()=>f.value.filter(e=>e.type==="bar"));function We(){if(!w.value)return;const e=D.value.offsetWidth,a=D.value.offsetHeight;w.value.width=e*R.value*2,w.value.height=a*R.value*2,g.value=e*R.value*2,T.value=a*R.value*2,c.value.scale(R.value,R.value),te()}function Xe(){if(c.value.clearRect(0,0,1e4,1e4),c.value.fillStyle=t.value.style.chart.backgroundColor,c.value.fillRect(0,0,o.value.canvasWidth,o.value.canvasHeight),s.value.stacked)t.value.style.chart.grid.y.verticalLines.show&&n.value.end-n.value.start<t.value.style.chart.grid.y.verticalLines.hideUnderXLength?f.value.forEach(e=>{for(let a=0;a<n.value.end-n.value.start+1;a+=1)d.line(c.value,[{x:o.value.left+o.value.slot*a,y:o.value.bottom-e.yOffset-e.individualHeight},{x:o.value.left+o.value.slot*a,y:o.value.bottom-e.yOffset}],{color:t.value.style.chart.grid.y.verticalLines.color})}):t.value.style.chart.grid.y.verticalLines.show&&n.value.end-n.value.start>=t.value.style.chart.grid.y.verticalLines.hideUnderXLength&&f.value.forEach(e=>{for(let a=n.value.start;a<n.value.end;a+=1)a%Math.floor((n.value.end-n.value.start)/t.value.style.chart.grid.y.timeLabels.modulo)===0&&d.line(c.value,[{x:o.value.left+o.value.slot*(a-n.value.start)+o.value.slot/2,y:o.value.bottom-e.yOffset-e.individualHeight},{x:o.value.left+o.value.slot*(a-n.value.start)+o.value.slot/2,y:o.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?f.value.forEach(e=>{e.localYLabels.forEach((a,r)=>{r<e.localYLabels.length-1&&d.rect(c.value,[{x:o.value.left,y:a.y},{x:o.value.right,y:a.y},{x:o.value.right,y:e.localYLabels[r+1].y},{x:o.value.left,y:e.localYLabels[r+1].y}],{fillColor:r%2===0?"transparent":u.setOpacity(t.value.style.chart.grid.x.horizontalLines.color,t.value.style.chart.grid.x.horizontalLines.opacity),strokeColor:"transparent"})})}):f.value.forEach(e=>{e.localYLabels.slice(n.value.start,n.value.end).forEach(a=>{d.line(c.value,[{x:o.value.left,y:a.y},{x:o.value.right,y:a.y}],{color:t.value.style.chart.grid.x.horizontalLines.color})})})),t.value.style.chart.grid.zeroLine.show&&f.value.forEach(e=>{d.line(c.value,[{x:o.value.left,y:e.localZero},{x:o.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&&f.value.forEach(e=>{d.line(c.value,[{x:o.value.left,y:o.value.bottom-e.yOffset},{x:o.value.left,y:o.value.bottom-e.yOffset-e.individualHeight}],{color:e.color}),d.line(c.value,[{x:o.value.right,y:o.value.bottom-e.yOffset},{x:o.value.right,y:o.value.bottom-e.yOffset-e.individualHeight}],{color:e.color}),e.localYLabels.forEach((a,r)=>{d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,a.value,u.dataLabel({p:e.prefix||t.value.style.chart.grid.y.axisLabels.prefix||"",v:a.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:a,seriesIndex:r}),a.x+t.value.style.chart.grid.y.axisLabels.offsetX,a.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})})}),f.value.forEach(e=>{d.text(c.value,e.name,g.value/35,o.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&&n.value.end-n.value.start<t.value.style.chart.grid.y.verticalLines.hideUnderXLength)for(let e=0;e<n.value.end-n.value.start+1;e+=1)d.line(c.value,[{x:o.value.left+o.value.slot*e,y:o.value.top},{x:o.value.left+o.value.slot*e,y:o.value.bottom}],{color:t.value.style.chart.grid.y.verticalLines.color});else if(t.value.style.chart.grid.y.verticalLines.show&&n.value.end-n.value.start>=t.value.style.chart.grid.y.verticalLines.hideUnderXLength)for(let e=n.value.start;e<n.value.end;e+=1)e%Math.floor((n.value.end-n.value.start)/t.value.style.chart.grid.y.timeLabels.modulo)===0&&d.line(c.value,[{x:o.value.left+o.value.slot*(e-n.value.start)+o.value.slot/2,y:o.value.top},{x:o.value.left+o.value.slot*(e-n.value.start)+o.value.slot/2,y:o.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?m.value.yLabels.forEach((e,a)=>{a<m.value.yLabels.length-1&&d.rect(c.value,[{x:o.value.left,y:e.y},{x:o.value.right,y:e.y},{x:o.value.right,y:m.value.yLabels[a+1].y},{x:o.value.left,y:m.value.yLabels[a+1].y}],{fillColor:a%2===0?"transparent":u.setOpacity(t.value.style.chart.grid.x.horizontalLines.color,t.value.style.chart.grid.x.horizontalLines.opacity),strokeColor:"transparent"})}):m.value.yLabels.forEach(e=>{d.line(c.value,[{x:o.value.left,y:e.y},{x:o.value.right,y:e.y}],{color:t.value.style.chart.grid.x.horizontalLines.color})})),t.value.style.chart.grid.y.showAxis&&d.line(c.value,[{x:o.value.left,y:o.value.top},{x:o.value.left,y:o.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&&d.line(c.value,[{x:o.value.left,y:o.value.bottom},{x:o.value.right,y:o.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&&d.line(c.value,[{x:o.value.left,y:m.value.zero},{x:o.value.right,y:m.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&&m.value.yLabels.forEach((e,a)=>{d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.value,u.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:a}),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&&d.text(c.value,t.value.style.chart.grid.y.axisName,g.value-g.value/40*t.value.style.chart.grid.y.axisLabels.fontSizeRatio*1.2,o.value.bottom-o.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&&d.text(c.value,t.value.style.chart.grid.x.axisName,g.value/2,T.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 Ye(e){for(let a=0;a<e.coordinatesLine.length;a+=1){const r=(y.value===a?g.value/150:t.value.style.chart.line.plots.show?g.value/200:0)*t.value.style.chart.line.plots.radiusRatio;d.circle(c.value,{x:e.coordinatesLine[a].x,y:e.coordinatesLine[a].y},r,{color:t.value.style.chart.backgroundColor,fillStyle:e.color})}}function Ze(e){for(let a=0;a<e.coordinatesLine.length;a+=1)d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.coordinatesLine[a].value,u.dataLabel({p:e.prefix||"",v:e.coordinatesLine[a].value,s:e.suffix||"",r:e.rounding||0}),{datapoint:e.coordinatesLine[a],seriesIndex:a}),e.coordinatesLine[a].x,e.coordinatesLine[a].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 Ge(){for(let e=n.value.start;e<n.value.end;e+=1)(n.value.end-n.value.start<t.value.style.chart.grid.y.timeLabels.modulo||n.value.end-n.value.start>=t.value.style.chart.grid.y.timeLabels.modulo&&(e%Math.floor((n.value.end-n.value.start)/t.value.style.chart.grid.y.timeLabels.modulo)===0||e===y.value+n.value.start))&&d.text(c.value,t.value.style.chart.grid.y.timeLabels.values[e]||e+1,o.value.left+o.value.slot*(e-n.value.start)+o.value.slot/2,o.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:u.setOpacity(t.value.style.chart.grid.y.timeLabels.color,y.value!==null?y.value+n.value.start===e?100:20:100),rotation:t.value.style.chart.grid.y.timeLabels.rotation})}function we(){d.line(c.value,[{x:o.value.left+o.value.slot*y.value+o.value.slot/2,y:o.value.top},{x:o.value.left+o.value.slot*y.value+o.value.slot/2,y:o.value.bottom}],{color:t.value.style.chart.selector.color,lineDash:t.value.style.chart.selector.dashed?[8,8]:[0,0],lineWidth:2})}function je(){b.value.forEach((e,a)=>{for(let r=0;r<e.coordinatesLine.length;r+=1)d.rect(c.value,[{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a)),y:s.value.stacked?e.localZero:m.value.zero},{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a))+o.value.slot*.8/(s.value.stacked?1:b.value.length),y:s.value.stacked?e.localZero:m.value.zero},{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a))+o.value.slot*.8/(s.value.stacked?1:b.value.length),y:e.coordinatesLine[r].y},{x:o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a)),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:m.value.zero},stops:[{offset:0,color:e.color},{offset:1,color:u.lightenHexColor(e.color,.5)}]}}),s.value.showDataLabels&&[!0,void 0].includes(e.dataLabels)&&d.text(c.value,u.applyDataLabel(t.value.style.chart.dataLabels.formatter,e.coordinatesLine[r].value,u.dataLabel({p:e.prefix||"",v:e.coordinatesLine[r].value,s:e.suffix||"",r:e.rounding||0}),{datapoint:e.coordinatesLine[r],seriesIndex:r}),o.value.left+o.value.slot*r+o.value.slot/10+(s.value.stacked?0:o.value.slot/b.value.length*a-(a===0?0:o.value.slot/(5*b.value.length)*a))+o.value.slot*.4/(s.value.stacked?1:b.value.length),(e.coordinatesLine[r].value<0?s.value.stacked?e.localZero:m.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 Je(e){e.useArea?s.value.stacked?d.polygon(c.value,[{x:e.coordinatesLine[0].x,y:e.localZero},...e.coordinatesLine,{x:e.coordinatesLine.at(-1).x,y:e.localZero}],{fillColor:u.setOpacity(e.color,t.value.style.chart.area.opacity),strokeColor:"transparent"}):d.polygon(c.value,[{x:e.coordinatesLine[0].x,y:m.value.zero},...e.coordinatesLine,{x:e.coordinatesLine.at(-1).x,y:m.value.zero}],{fillColor:u.setOpacity(e.color,t.value.style.chart.area.opacity),strokeColor:"transparent"}):d.line(c.value,e.coordinatesLine,{color:e.color,lineWidth:3})}function Ke(){f.value.forEach((e,a)=>{d.line(c.value,[{x:o.value.left,y:o.value.bottom-e.yOffset},{x:o.value.right,y:o.value.bottom-e.yOffset}],{color:t.value.style.chart.grid.x.horizontalLines.color,lineWidth:1})})}function te(){Xe(),M.value?(S.value&&y.value!==null&&t.value.style.chart.selector.show&&we(),je(),s.value.stacked&&t.value.style.chart.grid.x.showAxis&&Ke(),qe.value.forEach(e=>{(e.type==="line"||!e.type)&&Je(e),S.value&&(Ye(e),s.value.showDataLabels&&[!0,void 0].includes(e.dataLabels)&&Ze(e))}),G.value=d.cloneCanvas(w.value)):(G.value&&(c.value.clearRect(0,0,1e4,1e4),c.value.drawImage(G.value,0,0)),S.value&&y.value!==null&&t.value.style.chart.selector.show&&we(),S.value&&y.value!==null&&f.value.forEach(e=>{if(e.type==="line"||!e.type||e.type==="plot"){if(!e.coordinatesLine[y.value])return;e.coordinatesLine[y.value].x!==void 0&&e.coordinatesLine[y.value].y!==void 0&&d.circle(c.value,{x:e.coordinatesLine[y.value].x,y:e.coordinatesLine[y.value].y},g.value/150*t.value.style.chart.line.plots.radiusRatio,{color:t.value.style.chart.backgroundColor,fillStyle:e.color})}})),t.value.style.chart.grid.y.timeLabels.show&&Ge(),M.value=!1}const _=d.debounce(()=>{S.value=!0,We()},C.value>200?10:1,!S.value);function Qe(e){const{left:a}=w.value.getBoundingClientRect(),r=e.clientX-a;if(r*2<o.value.left||r*2>o.value.right){H.value=!1,y.value=null;return}const h=r*2-o.value.left;if(y.value=Math.floor(h/o.value.slot),H.value=!0,!S.value)return;let v="";const x=t.value.style.chart.tooltip.customFormat;u.isFunction(x)&&u.functionReturnsString(()=>x({seriesIndex:y.value,datapoint:f.value.map(i=>({shape:i.shape||null,name:i.name,color:i.color,type:i.type||"line",value:i.series.find((k,z)=>z===y.value)})),series:f.value,config:t.value}))?V.value=x({seriesIndex:y.value,datapoint:f.value.map(i=>({shape:i.shape||null,name:i.name,color:i.color,type:i.type||"line",value:i.series.find((k,z)=>z===y.value)})),series:f.value,config:t.value}):(t.value.style.chart.grid.y.timeLabels.values.slice(n.value.start,n.value.end)[y.value]&&(v+=`<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(n.value.start,n.value.end)[y.value]}</div>`),v+=Ue.value.join(""),V.value=v),S.value=!1}l.watch(()=>y.value,e=>{_()}),l.watch(()=>n.value,e=>{M.value=!0,te()},{deep:!0}),l.watch(()=>s.value.showDataLabels,e=>{M.value=!0,te()}),l.watch(()=>s.value.stacked,e=>{M.value=!0,S.value=!0,_()});function et(){H.value=!1,y.value=null,V.value=""}const q=l.ref(null),W=l.ref(null);l.onMounted(()=>{le()});function le(){if(u.objectIsEmpty(p.dataset)?u.error({componentName:"VueUiXyCanvas",type:"dataset"}):w.value&&(c.value=w.value.getContext("2d",{willReadFrequently:!0})),t.value.responsive){const e=d.throttle(()=>{const{width:a,height:r}=d.useResponsive({chart:B.value,title:t.value.style.chart.title.text?se.value:null,legend:t.value.style.chart.legend.show?ie.value:null,slicer:t.value.style.chart.zoom.show&&C.value>1?ce.value:null,source:ve.value});requestAnimationFrame(()=>{fe.value=`${a} / ${r}`})});q.value=new ResizeObserver(e),q.value.observe(B.value.parentNode)}W.value=new ResizeObserver(e=>{for(const a of e)a.contentBoxSize&&D.value&&(M.value=!0,_())}),W.value.observe(D.value),Ce()}l.onBeforeUnmount(()=>{W.value&&W.value.disconnect(),q.value&&q.value.disconnect()});function Se(e){Fe("selectLegend",f.value.find(a=>a.absoluteIndex===e)),L.value.includes(e)?L.value=L.value.filter(a=>a!==e):L.value.push(e),M.value=!0,_()}const ze=l.computed(()=>E.value.map((e,a)=>({...e,name:e.name,color:u.convertColorToHex(e.color)||xe.value[a]||u.palette[a]||u.palette[a%u.palette.length],shape:e.shape||"circle",prefix:e.prefix||"",suffix:e.suffix||"",rounding:e.rounding||0})).map(e=>({...e,opacity:L.value.includes(e.absoluteIndex)?.5:1,segregate:()=>Se(e.absoluteIndex),isSegregated:L.value.includes(e.absoluteIndex)}))),tt=l.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":""})),X=l.computed(()=>{const e=[""].concat(f.value.map(v=>v.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 a=[];for(let v=0;v<C.value;v+=1){const x=f.value.map(i=>i.series[v]??0).reduce((i,k)=>i+k,0);a.push([t.value.style.chart.grid.y.timeLabels.values.slice(n.value.start,n.value.end)[v]??v+1].concat(f.value.map(i=>(i.series[v]??0).toFixed(t.value.table.rounding))).concat((x??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},h=[t.value.table.columnNames.period].concat(f.value.map(v=>v.name)).concat(t.value.table.columnNames.total);return{head:e,body:a.slice(0,n.value.end-n.value.start),config:r,colNames:h}}),$e=l.computed(()=>{if(f.value.length===0)return{head:[],body:[],config:{},columnNames:[]};const e=f.value.map(r=>({label:r.name,color:r.color,type:r.type})),a=[];for(let r=n.value.start;r<n.value.end;r+=1){const h=[t.value.style.chart.grid.y.timeLabels.values[r]||r+1];f.value.forEach(v=>{h.push(Number((v.series[r]||0).toFixed(t.value.table.rounding)))}),a.push(h)}return{head:e,body:a}});function Te(){const e=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[""]],a=["",...$e.value.head.map(x=>x.label)],r=$e.value.body,h=e.concat([a]).concat(r),v=u.createCsvContent(h);u.downloadCsv({csvContent:v,title:t.value.style.chart.title.text||"vue-ui-xy-canvas"})}function lt(){return f.value}function Ie(){s.value.showTable=!s.value.showTable}function Pe(){s.value.showDataLabels=!s.value.showDataLabels}function Me(){s.value.stacked=!s.value.stacked}function Oe(){s.value.showTooltip=!s.value.showTooltip}const Y=l.ref(!1);function ae(){Y.value=!Y.value}return Ne({getData:lt,generateCsv:Te,generatePdf:me,generateImage:be,toggleTable:Ie,toggleLabels:Pe,toggleStack:Me,toggleTooltip:Oe,toggleAnnotator:ae}),(e,a)=>(l.openBlock(),l.createElementBlock("div",{style:l.normalizeStyle(`width:100%; position:relative; ${t.value.responsive?"height: 100%":""}`),ref_key:"xy",ref:B,id:`xy_canvas_${Z.value}`,class:l.normalizeClass(`vue-ui-donut ${U.value?"vue-data-ui-wrapper-fullscreen":""}`),onMouseenter:a[5]||(a[5]=()=>l.unref(de)(!0)),onMouseleave:a[6]||(a[6]=()=>l.unref(de)(!1))},[t.value.style.chart.title.text?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:se,style:l.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};`)},[(l.openBlock(),l.createBlock(nt._sfc_main,{key:`title_${j.value}`,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)):l.createCommentVNode("",!0),t.value.userOptions.show&&Q.value&&(l.unref(he)||l.unref(ee))?(l.openBlock(),l.createBlock(Re.UserOptions,{ref:"details",key:`user_option_${ue.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:l.unref(ge),isImaging:l.unref(pe),uid:Z.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:oe.dataset.length>1&&t.value.userOptions.buttons.stack,hasFullscreen:t.value.userOptions.buttons.fullscreen,hasTable:n.value.end-n.value.start<200&&t.value.userOptions.buttons.table,isFullscreen:U.value,isTooltip:s.value.showTooltip,isStacked:s.value.stacked,titles:{...t.value.userOptions.buttonTitles},chartElement:B.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:Y.value,onToggleFullscreen:He,onGeneratePdf:l.unref(me),onGenerateCsv:Te,onGenerateImage:l.unref(be),onToggleTable:Ie,onToggleLabels:Pe,onToggleStack:Me,onToggleTooltip:Oe,onToggleAnnotator:ae,style:l.normalizeStyle({visibility:l.unref(he)?l.unref(ee)?"visible":"hidden":"visible"})},l.createSlots({_:2},[e.$slots.optionTooltip?{name:"optionTooltip",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,e.$slots.optionPdf?{name:"optionPdf",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,e.$slots.optionCsv?{name:"optionCsv",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,e.$slots.optionImg?{name:"optionImg",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,e.$slots.optionTable?{name:"optionTable",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,e.$slots.optionLabels?{name:"optionLabels",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionLabels",{},void 0,!0)]),key:"5"}:void 0,e.$slots.optionStack?{name:"optionStack",fn:l.withCtx(()=>[l.renderSlot(e.$slots,"optionStack",{},void 0,!0)]),key:"6"}:void 0,e.$slots.optionFullscreen?{name:"optionFullscreen",fn:l.withCtx(({toggleFullscreen:r,isFullscreen:h})=>[l.renderSlot(e.$slots,"optionFullscreen",l.normalizeProps(l.guardReactiveProps({toggleFullscreen:r,isFullscreen:h})),void 0,!0)]),key:"7"}:void 0,e.$slots.optionAnnotator?{name:"optionAnnotator",fn:l.withCtx(({toggleAnnotator:r,isAnnotator:h})=>[l.renderSlot(e.$slots,"optionAnnotator",l.normalizeProps(l.guardReactiveProps({toggleAnnotator:r,isAnnotator:h})),void 0,!0)]),key:"8"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasImg","hasXls","hasLabel","hasStack","hasFullscreen","hasTable","isFullscreen","isTooltip","isStacked","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):l.createCommentVNode("",!0),l.createElementVNode("div",{class:"vue-ui-xy-canvas",style:l.normalizeStyle(`position: relative; aspect-ratio: ${fe.value}`),ref_key:"container",ref:D},[Q.value?(l.openBlock(),l.createElementBlock("canvas",{key:0,ref_key:"canvas",ref:w,style:{width:"100%",height:"100%"},onMousemove:a[0]||(a[0]=r=>Qe(r)),onMouseleave:et},null,544)):(l.openBlock(),l.createBlock(ct.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"])),l.createVNode(ot._sfc_main,{show:s.value.showTooltip&&H.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:w.value,content:V.value,isFullscreen:U.value,backgroundOpacity:t.value.style.chart.tooltip.backgroundOpacity,isCustom:l.unref(u.isFunction)(t.value.style.chart.tooltip.customFormat)},{"tooltip-before":l.withCtx(()=>[l.renderSlot(e.$slots,"tooltip-before",l.normalizeProps(l.guardReactiveProps({...re.value})),void 0,!0)]),"tooltip-after":l.withCtx(()=>[l.renderSlot(e.$slots,"tooltip-after",l.normalizeProps(l.guardReactiveProps({...re.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","fontSize","borderRadius","borderColor","borderWidth","position","offsetY","parent","content","isFullscreen","backgroundOpacity","isCustom"])],4),l.createElementVNode("div",{ref_key:"chartSlicer",ref:ce,style:l.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor}`),"data-html2canvas-ignore":""},[t.value.style.chart.zoom.show&&C.value>1?(l.openBlock(),l.createBlock(ut.Slicer,{ref_key:"slicerComponent",ref:N,key:`slicer_${ne.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[n.value.start]?t.value.style.chart.grid.y.timeLabels.values[n.value.start]:"",labelRight:t.value.style.chart.grid.y.timeLabels.values[n.value.end-1]?t.value.style.chart.grid.y.timeLabels.values[n.value.end-1]:"",textColor:t.value.style.chart.color,inputColor:t.value.style.chart.zoom.color,selectColor:t.value.style.chart.zoom.highlightColor,max:C.value,min:0,valueStart:n.value.start,valueEnd:n.value.end,start:n.value.start,"onUpdate:start":a[1]||(a[1]=r=>n.value.start=r),end:n.value.end,"onUpdate:end":a[2]||(a[2]=r=>n.value.end=r),refreshStartPoint:t.value.style.chart.zoom.startIndex!==null?t.value.style.chart.zoom.startIndex:0,refreshEndPoint:t.value.style.chart.zoom.endIndex!==null?t.value.style.chart.zoom.endIndex+1:C.value,enableRangeHandles:t.value.style.chart.zoom.enableRangeHandles,enableSelectionDrag:t.value.style.chart.zoom.enableSelectionDrag,onReset:Le},{"reset-action":l.withCtx(({reset:r})=>[l.renderSlot(e.$slots,"reset-action",l.normalizeProps(l.guardReactiveProps({reset:r})),void 0,!0)]),_:3},8,["background","borderColor","fontSize","useResetSlot","labelLeft","labelRight","textColor","inputColor","selectColor","max","valueStart","valueEnd","start","end","refreshStartPoint","refreshEndPoint","enableRangeHandles","enableSelectionDrag"])):l.createCommentVNode("",!0)],4),l.createElementVNode("div",{ref_key:"chartLegend",ref:ie},[t.value.style.chart.legend.show&&Q.value?(l.openBlock(),l.createBlock(rt.Legend,{legendSet:ze.value,config:tt.value,key:`legend_${K.value}`,onClickMarker:a[3]||(a[3]=({i:r})=>Se(r))},{item:l.withCtx(({legend:r,index:h})=>[l.createElementVNode("div",{onClick:v=>r.segregate(),style:l.normalizeStyle(`opacity:${L.value.includes(h)?.5:1}`)},l.toDisplayString(r.name),13,ft)]),_:1},8,["legendSet","config"])):l.renderSlot(e.$slots,"legend",{key:1,legend:ze.value},void 0,!0)],512),e.$slots.watermark?(l.openBlock(),l.createElementBlock("div",gt,[l.renderSlot(e.$slots,"watermark",l.normalizeProps(l.guardReactiveProps({isPrinting:l.unref(ge)||l.unref(pe)})),void 0,!0)])):l.createCommentVNode("",!0),e.$slots.source?(l.openBlock(),l.createElementBlock("div",{key:3,ref_key:"source",ref:ve,dir:"auto"},[l.renderSlot(e.$slots,"source",{},void 0,!0)],512)):l.createCommentVNode("",!0),n.value.end-n.value.start<200?(l.openBlock(),l.createBlock(st.default,{key:4,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:l.withCtx(()=>[(l.openBlock(),l.createBlock(it.DataTable,{key:`table_${J.value}`,colNames:X.value.colNames,head:X.value.head,body:X.value.body,config:X.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:a[4]||(a[4]=r=>s.value.showTable=!1)},{th:l.withCtx(({th:r})=>[l.createElementVNode("div",{innerHTML:r},null,8,pt)]),td:l.withCtx(({td:r})=>[l.createTextVNode(l.toDisplayString(r),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):l.createCommentVNode("",!0),t.value.userOptions.buttons.annotator&&f.value.length?(l.openBlock(),l.createBlock(vt.PenAndPaper,{key:5,parent:B.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:Y.value,onClose:ae},null,8,["parent","backgroundColor","color","active"])):l.createCommentVNode("",!0)],46,yt))}},bt=ht._export_sfc(mt,[["__scopeId","data-v-71c6890d"]]);exports.default=bt;
@@ -1,16 +1,16 @@
1
1
  import { ref as v, computed as m, useSlots as Ma, onMounted as ea, watch as H, nextTick as ce, onBeforeUnmount as Oa, createElementBlock as K, openBlock as w, unref as z, normalizeClass as Pa, normalizeStyle as Y, createCommentVNode as _, createBlock as E, createElementVNode as Q, createSlots as Ra, withCtx as p, renderSlot as b, normalizeProps as V, guardReactiveProps as Z, createVNode as Fa, toDisplayString as aa, createTextVNode as Ea } from "vue";
2
- import { u as Da, c as Aa, t as Na, p as U, a as Ha, C as de, b as _a, D as Ce, i as ee, f as ae, d as la, _ as Ua, J as Wa, a9 as Xa, o as Ba, e as Ya, x as ta, q as Va, r as Za, y as Ga, s as le, l as ja } from "./index-B8uVRkA1.js";
2
+ import { u as Da, c as Aa, t as Na, p as U, a as Ha, C as de, b as _a, D as Ce, i as ee, f as ae, d as la, _ as Ua, J as Wa, a9 as Xa, o as Ba, e as Ya, x as ta, q as Va, r as Za, y as Ga, s as le, l as ja } from "./index-GSCW0GhW.js";
3
3
  import { d as qa, t as Ja, u as Ka, c as Qa, a as oa, l as x, r as we, b as D, p as ra } from "./useResponsive-CoxXLe23.js";
4
- import { _ as el } from "./Tooltip-BUMgVEu0.js";
5
- import { L as al } from "./Legend-du4CJMG1.js";
6
- import { _ as ll } from "./Title-MKfkLka7.js";
7
- import { S as tl } from "./Slicer-DKXIt2om.js";
8
- import { u as ol, U as rl } from "./usePrinter-CppD6oY_.js";
9
- import ul from "./vue-ui-accordion-CE2Pnpz3.js";
10
- import { D as sl } from "./DataTable-BWABkdIL.js";
11
- import nl from "./vue-ui-skeleton-BC7kQhlE.js";
12
- import { u as ua } from "./useNestedProp-kStEZqtl.js";
13
- import { P as il } from "./PenAndPaper-QsaleY3R.js";
4
+ import { _ as el } from "./Tooltip-3XUFn6mK.js";
5
+ import { L as al } from "./Legend-Be3l-GsN.js";
6
+ import { _ as ll } from "./Title-rp5eHDVc.js";
7
+ import { S as tl } from "./Slicer-BLv_S96I.js";
8
+ import { u as ol, U as rl } from "./usePrinter-BBNI0jHz.js";
9
+ import ul from "./vue-ui-accordion-CON_m6tj.js";
10
+ import { D as sl } from "./DataTable-HDq8aOyj.js";
11
+ import nl from "./vue-ui-skeleton-C0nuwFlf.js";
12
+ import { u as ua } from "./useNestedProp-Da-DNb_v.js";
13
+ import { P as il } from "./PenAndPaper-C1v_7F2S.js";
14
14
  import { u as vl } from "./useUserOptionState-BIvW1Kz7.js";
15
15
  import { _ as cl } from "./_plugin-vue_export-helper-CHgC5LLL.js";
16
16
  const dl = ["id"], hl = ["onClick"], yl = {
@@ -94,7 +94,7 @@ const dl = ["id"], hl = ["onClick"], yl = {
94
94
  return l.map((M, R) => {
95
95
  const F = i.min < 0 ? Math.abs(i.min) : 0, N = We(M + F, F + i.max);
96
96
  let q, J;
97
- e && (q = Math.abs(i.min), J = We(M + q, i.max + q));
97
+ e && (q = i.min, J = We(M - q, i.max - q));
98
98
  let O = 0;
99
99
  return C === null ? O = t.value.bottom - t.value.height * (e ? J : N) : O = t.value.bottom - k - s * (e ? J : N), {
100
100
  x: t.value.left + t.value.slot * R + t.value.slot / 2,
@@ -1145,7 +1145,7 @@ const dl = ["id"], hl = ["onClick"], yl = {
1145
1145
  }, null, 8, ["parent", "backgroundColor", "color", "active"])) : _("", !0)
1146
1146
  ], 46, dl));
1147
1147
  }
1148
- }, Pl = /* @__PURE__ */ cl(gl, [["__scopeId", "data-v-13fe7bc4"]]);
1148
+ }, Pl = /* @__PURE__ */ cl(gl, [["__scopeId", "data-v-71c6890d"]]);
1149
1149
  export {
1150
1150
  Pl as default
1151
1151
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "vue-data-ui",
3
3
  "private": false,
4
- "version": "2.6.2",
4
+ "version": "2.6.4-beta.0",
5
5
  "type": "module",
6
6
  "description": "A user-empowering data visualization Vue 3 components library for eloquent data storytelling",
7
7
  "keywords": [
@@ -96,9 +96,9 @@
96
96
  },
97
97
  "devDependencies": {
98
98
  "@vitejs/plugin-vue": "^5.2.1",
99
- "cypress": "^14.0.2",
99
+ "cypress": "^14.0.3",
100
100
  "html2canvas": "^1.4.1",
101
- "jspdf": "^2.5.1",
101
+ "jspdf": "^2.5.2",
102
102
  "remove-attr": "^0.0.13",
103
103
  "sass": "^1.57.1",
104
104
  "simple-git": "^3.24.0",
@@ -1 +0,0 @@
1
- "use strict";const e=require("vue"),k=require("./Shape-QydDpcqr.cjs"),_=require("./BaseIcon-Dn1igOva.cjs"),x=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),B={class:"vue-ui-data-table"},w={style:{display:"flex","align-items":"center","justify-content":"flex-end","padding-right":"3px",gap:"3px"}},E={key:0,height:"12",width:"12",viewBox:"0 0 20 20",style:{background:"none"}},N=["fill"],V=["data-cell"],C={dir:"auto",style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},S={key:0,height:"12",width:"12",viewBox:"0 0 20 20",style:{background:"none",overflow:"visible"}},z={__name:"DataTable",props:{colNames:{type:Array,default(){return[]}},head:Array,body:Array,title:String,config:Object},emits:["close"],setup(t,{emit:b}){e.useCssVars(l=>({"72ac81a5":e.unref(f)}));const i=t,{backgroundColor:s,color:u,outline:m}=i.config.th,{backgroundColor:g,color:h,outline:f}=i.config.td,v=e.computed(()=>i.config.breakpoint),d=e.ref(null),p=e.ref(!1);e.onMounted(()=>{const l=new ResizeObserver(n=>{n.forEach(o=>{p.value=o.contentRect.width<v.value})});d.value&&l.observe(d.value)});const y=b;return(l,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"tableContainer",ref:d,style:{width:"100%","container-type":"inline-size",position:"relative","padding-top":"36px",overflow:"auto"},class:e.normalizeClass({"vue-ui-responsive":p.value})},[e.createElementVNode("div",{"data-html2canvas-ignore":"",role:"button",tabindex:"0",style:e.normalizeStyle(`width:32px; position: absolute; top: 0; right:4px; padding: 0 0px; display: flex; align-items:center;justify-content:center;height: 36px; width: 32px; cursor:pointer; background:${e.unref(s)};`),onClick:n[0]||(n[0]=o=>y("close")),onKeypress:n[1]||(n[1]=e.withKeys(o=>y("close"),["enter"]))},[e.createVNode(_.default,{name:"close",stroke:e.unref(u),"stroke-width":2},null,8,["stroke"])],36),e.createElementVNode("table",B,[e.createElementVNode("caption",{style:e.normalizeStyle({backgroundColor:e.unref(s),color:e.unref(u),outline:e.unref(m)}),class:"vue-ui-data-table__caption"},e.toDisplayString(t.title),5),e.createElementVNode("thead",null,[e.createElementVNode("tr",{role:"row",style:e.normalizeStyle([{"font-variant-numeric":"tabular-nums"},{backgroundColor:e.unref(s),color:e.unref(u)}]),class:"vue-ui-data-table__thead-row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.head,(o,r)=>(e.openBlock(),e.createElementBlock("th",{role:"cell",style:e.normalizeStyle({outline:e.unref(m)}),key:`th_${r}`},[e.createElementVNode("div",w,[o.color?(e.openBlock(),e.createElementBlock("svg",E,[e.createElementVNode("circle",{cx:"10",cy:"10",r:"10",fill:o.color},null,8,N)])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"th",{th:o},void 0,!0)])],4))),128))],4)]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.body,(o,r)=>(e.openBlock(),e.createElementBlock("tr",{role:"row",style:e.normalizeStyle([{"font-variant-numeric":"tabular-nums"},{backgroundColor:e.unref(g),color:e.unref(h)}]),class:e.normalizeClass({"vue-ui-data-table__tbody__row":!0,"vue-ui-data-table__tbody__row-even":r%2===0,"vue-ui-data-table__tbody__row-odd":r%2!==0})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o,(a,c)=>(e.openBlock(),e.createElementBlock("td",{role:"cell","data-cell":(t.colNames[c]&&t.colNames[c].name?t.colNames[c].name:"")||t.colNames[c]||"",style:e.normalizeStyle({outline:e.unref(f)}),class:"vue-ui-data-table__tbody__td"},[e.createElementVNode("div",C,[a.color?(e.openBlock(),e.createElementBlock("svg",S,[e.createVNode(k._sfc_main,{plot:{x:10,y:10},color:a.color,radius:9,shape:t.config.shape||a.shape||"circle"},null,8,["color","shape"])])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"td",{td:a},void 0,!0)])],12,V))),256))],6))),256))])])],2))}},$=x._export_sfc(z,[["__scopeId","data-v-5cbf64d8"]]);exports.DataTable=$;
@@ -1 +0,0 @@
1
- "use strict";const e=require("vue"),t="2.6.2",n={"aria-hidden":"true"},s={__name:"PackageVersion",setup(c){return(r,o)=>(e.openBlock(),e.createElementBlock("desc",n,"Composed with Vue Data UI "+e.toDisplayString(e.unref(t)),1))}};exports._sfc_main=s;
@@ -1 +0,0 @@
1
- "use strict";const e=require("vue"),X=require("./index-Bmq5HB9y.cjs"),E=require("./BaseIcon-Dn1igOva.cjs"),W=require("./usePrinter-Cf6Zct5m.cjs"),Y=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),A={style:{height:"100%",width:"100%",position:"relative"}},H={class:"icon"},Q=["onClick"],_={style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -46%)"}},j=["value"],G={__name:"ColorPicker",props:{value:{type:String,default:"#ffffff"},size:{type:String,default:"50px"},backgroundColor:{type:String,default:"#FFFFFF"},buttonBorderColor:{type:String,default:"#FFFFFF"}},emits:["update:value"],setup(a,{emit:S}){const p=a,P=S,f=e.computed(()=>({backgroundColor:p.value,width:"100%",height:"100%",cursor:"pointer"})),g=e.ref(null),h=e.ref(!1),b=()=>{var u;(u=g.value)==null||u.click()};function B(u){P("update:value",u),h.value=!1}function y(){h.value=!1}function N(){h.value&&y()}const x=u=>{const $=u.target.value;P("update:value",$)},C=e.computed(()=>X.adaptColorToBackground(p.value));e.watch(()=>p.value,u=>{g.value.value=u});const F=e.ref(["#000000","#FFFFFF","#FF5733","#33FF57","#3357FF","#FFC300","#800080","#FF1493","#00CED1"]);return(u,$)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",A,[e.createElementVNode("div",{onClick:$[0]||($[0]=w=>h.value=!h.value),style:e.normalizeStyle(f.value)},[e.createElementVNode("div",H,[e.createVNode(E.default,{name:"palette",stroke:C.value,size:22},null,8,["stroke"])])],4),h.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"vue-ui-color-picker",style:e.normalizeStyle({backgroundColor:a.backgroundColor})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(F.value,w=>(e.openBlock(),e.createElementBlock("div",{class:"vue-ui-color-picker-option",style:e.normalizeStyle({backgroundColor:w,outline:`1px solid ${a.buttonBorderColor}`}),onClick:()=>B(w)},null,12,Q))),256)),e.createElementVNode("div",{class:"vue-ui-color-picker-option",onClick:b,style:e.normalizeStyle({backgroundColor:a.value,outline:`1px solid ${a.buttonBorderColor}`})},[e.createElementVNode("div",_,[e.createVNode(E.default,{name:"colorPicker",stroke:C.value,size:22},null,8,["stroke"])]),e.createElementVNode("input",{ref_key:"colorInput",ref:g,type:"color",value:a.value,class:"hidden-input",onInput:x},null,40,j)],4)],4)):e.createCommentVNode("",!0)])),[[e.unref(W.vClickOutside),N]])}},J=Y._export_sfc(G,[["__scopeId","data-v-84e6c062"]]),K={class:e.normalizeClass({"vue-ui-pen-and-paper-action":!0}),style:{padding:"0 !important"}},Z=["disabled"],ee=["xmlns","viewBox"],te=["cx","cy","r","fill"],oe=["d","stroke","stroke-width"],ne=["d","stroke","stroke-width"],le={__name:"PenAndPaper",props:{parent:{type:HTMLElement},backgroundColor:{type:String,default:"#FFFFFF"},color:{type:String,default:"#2D353C"},active:{type:Boolean,default:!1}},emits:["close"],setup(a,{emit:S}){const p=a,P=S,f=e.ref([]),g=e.ref([]),h=e.ref("0 0 0 0"),b=e.ref(p.color),B=e.ref(1),y=e.computed(()=>X.lightenHexColor(p.color,.6));function N({width:n,height:o}){h.value=`0 0 ${n} ${o}`}const x=e.ref(null);e.onMounted(()=>{e.nextTick(()=>{if(p.parent){x.value=new ResizeObserver(t=>{for(const l of t){const{width:r,height:c}=l.contentRect;N({width:r,height:c})}}),x.value.observe(p.parent);const{width:n,height:o}=p.parent.getBoundingClientRect();N({width:n,height:o})}})}),e.onBeforeUnmount(()=>{x.value&&x.value.disconnect()}),e.watch(()=>p.parent,n=>{if(!n)return;const{width:o,height:t}=p.parent.getBoundingClientRect();N({width:o,height:t})},{immediate:!0});const C=e.ref(!1),F=e.ref(""),u=e.ref(null);function $(n){if(!u.value)return;C.value=!0;const{x:o,y:t}=L(n);F.value=`M ${o} ${t}`}function w(n){if(!C.value||!u.value)return;const{x:o,y:t}=L(n);F.value+=` ${o} ${t}`}function D(n){const o=n.trim().split(/\s+/);if(o.length<4)return n;const t=o.slice(1).map(Number);if(t.length%2!==0)return n;const l=q(t),r=[`M ${l[0]} ${l[1]}`];for(let i=2;i<l.length-2;i+=2){const m=l[i-2],k=l[i-1],d=l[i],v=l[i+1],V=(m+d)/2,z=(k+v)/2;r.push(`Q ${m} ${k} ${V} ${z}`)}const c=l[l.length-2],s=l[l.length-1];return r.push(`L ${c} ${s}`),r.join(" ")}function q(n,o=1){const t=[...n];for(let l=2;l<n.length-2;l+=2){const r=n[l],c=n[l+1],s=n[l-2],i=n[l-1],m=n[l+2],k=n[l+3];t[l]=r+o*((s+m)/2-r),t[l+1]=c+o*((i+k)/2-c)}return t}function I(n){const o=n.trim().split(/\s+/);let t="",l="",r=null,c=null;for(let s=0;s<o.length;s+=1){const i=o[s];if(isNaN(i)){if(l=i,l==="M"||l==="L")r=parseFloat(o[++s]),c=parseFloat(o[++s]),t+=`${l}${r} ${c}`;else if(l==="Q"){const m=parseFloat(o[++s]),k=parseFloat(o[++s]),d=parseFloat(o[++s]),v=parseFloat(o[++s]);m===r&&k===c?t+=`t${d-r} ${v-c}`:t+=`q${m-r} ${k-c} ${d-r} ${v-c}`,r=d,c=v}}else{const m=parseFloat(i),k=parseFloat(o[++s]);if(l==="L"){const d=m-r,v=k-c;d===0?t+=`v${v}`:v===0?t+=`h${d}`:t+=`l${d} ${v}`,r=m,c=k}else if(l==="Q"){const d=m,v=k,V=parseFloat(o[++s]),z=parseFloat(o[++s]);d===r&&v===c?t+=`t${V-r} ${z-c}`:t+=`q${d-r} ${v-c} ${V-r} ${z-c}`,r=V,c=z}}}return t}function M(){C.value&&(f.value.push({strokeWidth:B.value,path:I(D(F.value)),color:b.value}),g.value=[],F.value=""),C.value=!1}function L(n){if(!u.value)return{x:0,y:0};const o=u.value.getBoundingClientRect();let t,l;return n.touches&&n.touches.length?(t=n.touches[0].clientX,l=n.touches[0].clientY):(t=n.clientX,l=n.clientY),{x:t-o.left,y:l-o.top}}e.ref(!1);function R(){if(f.value.length>0){const n=f.value.pop();g.value.push(n)}}function T(){if(g.value.length>0){const n=g.value.pop();f.value.push(n)}}function O(){f.value=[],g.value=[]}const U=e.ref(null);return(n,o)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[a.active?(e.openBlock(),e.createElementBlock("div",{key:0,"data-html2canvas-ignore":"",class:e.normalizeClass({"vue-ui-pen-and-paper-actions":!0,visible:a.active})},[e.createElementVNode("button",{class:"vue-ui-pen-and-paper-action",style:e.normalizeStyle({backgroundColor:a.backgroundColor,border:`1px solid ${y.value}`}),onClick:o[0]||(o[0]=t=>P("close"))},[e.createVNode(E.default,{name:"close",stroke:a.color},null,8,["stroke"])],4),e.createElementVNode("button",K,[e.createVNode(J,{value:b.value,"onUpdate:value":o[1]||(o[1]=t=>b.value=t),backgroundColor:a.backgroundColor,buttonBorderColor:y.value},null,8,["value","backgroundColor","buttonBorderColor"])]),e.createElementVNode("button",{class:e.normalizeClass({"vue-ui-pen-and-paper-action":!0,"vue-ui-pen-and-paper-action-disabled":!f.value.length}),disabled:!f.value.length,style:e.normalizeStyle({backgroundColor:a.backgroundColor,border:`1px solid ${y.value}`}),onClick:R},[e.createVNode(E.default,{name:"restart",stroke:a.color},null,8,["stroke"])],14,Z),e.createElementVNode("button",{class:e.normalizeClass({"vue-ui-pen-and-paper-action":!0,"vue-ui-pen-and-paper-action-disabled":!g.value.length}),style:e.normalizeStyle({backgroundColor:a.backgroundColor,border:`1px solid ${y.value}`}),onClick:T},[e.createVNode(E.default,{name:"restart",stroke:a.color,style:{transform:"scaleX(-1)"}},null,8,["stroke"])],6),e.createElementVNode("button",{class:e.normalizeClass([{"vue-ui-pen-and-paper-action":!0,"vue-ui-pen-and-paper-action-disabled":!f.value.length},"vue-ui-pen-and-paper-action"]),style:e.normalizeStyle({backgroundColor:a.backgroundColor,border:`1px solid ${y.value}`}),onClick:O},[e.createVNode(E.default,{name:"trash",stroke:a.color},null,8,["stroke"])],6),e.withDirectives(e.createElementVNode("input",{ref_key:"range",ref:U,type:"range",class:"vertical-range",min:.5,max:12,step:.1,"onUpdate:modelValue":o[2]||(o[2]=t=>B.value=t),style:e.normalizeStyle({accentColor:a.color})},null,4),[[e.vModelText,B.value]])],2)):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{ref_key:"svgElement",ref:u,xmlns:e.unref(X.XMLNS),viewBox:h.value,class:e.normalizeClass({"vue-ui-pen-and-paper":!0,inactive:!a.active}),onMousedown:$,onMousemove:w,onMouseup:M,onMouseleave:M,onTouchstart:e.withModifiers($,["prevent"]),onTouchmove:e.withModifiers(w,["prevent"]),onTouchend:M},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,t=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:t},[t.path.replace("M","").split(" ").length===2?(e.openBlock(),e.createElementBlock("circle",{key:0,cx:t.path.replace("M","").split(" ")[0],cy:t.path.replace("M","").split(" ")[1],r:t.strokeWidth/2,fill:t.color},null,8,te)):(e.openBlock(),e.createElementBlock("path",{key:1,class:"vue-ui-pen-and-paper-path",d:t.path,stroke:t.color,"stroke-width":t.strokeWidth,fill:"none"},null,8,oe))],64))),128)),C.value?(e.openBlock(),e.createElementBlock("path",{key:0,class:"vue-ui-pen-and-paper-path vue-ui-pen-and-paper-path-drawing",d:D(F.value),stroke:b.value,"stroke-width":B.value*1.1,fill:"none"},null,8,ne)):e.createCommentVNode("",!0)],42,ee))],64))}},re=Y._export_sfc(le,[["__scopeId","data-v-a932b1ac"]]);exports.PenAndPaper=re;
@@ -1 +0,0 @@
1
- "use strict";const e=require("vue"),ge=require("./BaseIcon-Dn1igOva.cjs"),K=require("./useResponsive-BJ7DTGpm.cjs"),f=require("./index-Bmq5HB9y.cjs"),pe=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),ye={class:"vue-data-ui-slicer-labels",style:{position:"relative","z-index":"1","pointer-events":"none"}},xe={key:0,style:{width:"100%",position:"relative"}},be={key:0,class:"minimap",style:{width:"100%"}},ke=["xmlns","viewBox"],we=["id"],Se=["stop-color"],Ne=["d","stroke"],Ce=["x","width","height","fill","rx"],Ee=["d","fill"],Be=["x","width","height","rx","fill"],Me=["x","width","height","fill","rx"],Re=["d","fill"],$e=["d","stroke"],Ve=["cx","cy","stroke","fill"],Le=["cx","cy","stroke","fill"],ze=["x1","x2","y2","stroke"],De=["x","height","width","onMouseenter"],Te=["min","max"],Pe=["min","max"],Fe={__name:"Slicer",props:{background:{type:String,default:"#FFFFFF"},borderColor:{type:String,default:"#FFFFFF"},fontSize:{type:Number,default:14},labelLeft:{type:String,default:""},labelRight:{type:String,default:""},textColor:{type:String,default:"#1A1A1A"},inputColor:{type:String,default:"#1A1A1A"},max:{type:Number,default:0},min:{type:Number,default:0},selectColor:{type:String,default:"#4A4A4A"},useResetSlot:{type:Boolean,default:!1},valueStart:{type:[Number,String],default:0},valueEnd:{type:[Number,String],default:0},minimap:{type:Array,default:[]},smoothMinimap:{type:Boolean,default:!1},minimapSelectedColor:{type:String,default:"#1f77b4"},minimapSelectionRadius:{type:Number,default:12},minimapLineColor:{type:String,default:"#2D353C"},minimapSelectedColorOpacity:{type:Number,default:.2},minimapSelectedIndex:{type:Number,default:null},minimapIndicatorColor:{type:String,default:"#2D353C"},refreshStartPoint:{type:Number,default:0},refreshEndPoint:{type:Number,default:null},enableRangeHandles:{type:Boolean,default:!1},enableSelectionDrag:{type:Boolean,default:!0},verticalHandles:{type:Boolean,default:!1}},emits:["update:start","update:end","reset","trapMouse"],setup(n,{expose:Q,emit:Y}){e.useCssVars(l=>({d8df0b62:ee.value,"2b8602c3":p.value,"18ae31f4":le.value,"0bbb43f3":n.selectColor,"6af67d01":te.value}));const t=n,c=e.ref(null),r=e.ref(t.min),u=e.ref(t.max),k=e.computed(()=>!!t.minimap.length),C=e.ref(f.createUid()),_=e.computed(()=>t.refreshEndPoint===null?t.max:t.refreshEndPoint),h=Y,g=e.computed(()=>{const l=t.max-t.min,a=(r.value-t.min)/l*100,o=(u.value-t.min)/l*100;return{left:`${a}%`,width:`${o-a}%`,background:t.selectColor,tooltipLeft:`calc(${a}% - ${A.value?0:P.value/2}px)`,tooltipRight:`calc(${o}% - ${H.value?N.value:N.value/2}px)`,arrowLeft:!A.value,arrowRight:!H.value}}),A=e.computed(()=>c.value?c.value.getBoundingClientRect().width*((r.value-t.min)/(t.max-t.min))-P.value/2<0:!1),H=e.computed(()=>c.value?c.value.getBoundingClientRect().width*((u.value-t.min)/(t.max-t.min))+N.value/2>c.value.getBoundingClientRect().width:!1),ee=e.computed(()=>t.inputColor),te=e.computed(()=>t.background),le=e.computed(()=>`${t.selectColor}33`),p=e.computed(()=>t.borderColor),I=e.computed(()=>{let l=[];for(let a=0;a<t.minimap.length;a+=1)l.push(a);return l});function W(){h("reset")}function ae(){Number(r.value)>Number(u.value)-1&&(r.value=Number(u.value)-1),h("update:start",Number(r.value))}function ne(){Number(u.value)<Number(r.value)+1&&(u.value=Number(r.value)+1),h("update:end",Number(u.value))}e.watch(()=>t.min,l=>{Number(r.value)<Number(l)&&(r.value=Number(l)),Number(u.value)<Number(l)&&(u.value=Number(l))}),e.watch(()=>t.max,l=>{Number(r.value)>Number(l)&&(r.value=Number(l)),Number(u.value)>Number(l)&&(u.value=Number(l))});const E=e.ref(null),i=e.ref({width:1,height:1}),S=e.ref(null);e.onMounted(()=>{if(k.value){const l=K.throttle(()=>{const{width:a,height:o}=K.useResponsive({chart:E.value});i.value.width=a,i.value.height=o-47});S.value=new ResizeObserver(l),S.value.observe(E.value)}}),e.onBeforeUnmount(()=>{S.value&&S.value.disconnect()});const s=e.computed(()=>t.minimap.length?i.value.width/t.minimap.length:0),m=e.computed(()=>{if(!t.minimap.length)return[];const l=Math.max(...t.minimap),a=Math.min(...t.minimap)-10,o=l-(a>0?0:a),d=t.minimap.map((ve,fe)=>{const he=ve-a;return{x:i.value.width/t.minimap.length*fe+s.value/2,y:i.value.height-he/o*(i.value.height*.9)}}),y=t.smoothMinimap?f.createSmoothPath(d):f.createStraightPath(d),F=[...d].slice(t.valueStart,t.valueEnd),me=t.smoothMinimap?f.createSmoothPath(F):f.createStraightPath(F);return{fullSet:y,selectionSet:me,sliced:F,firstPlot:d[t.valueStart],lastPlot:d[t.valueEnd-1]}}),v=e.computed(()=>({x:s.value*r.value+s.value/2,width:i.value.width*((u.value-r.value)/t.max)-s.value})),w=e.ref(t.minimapSelectedIndex);e.watch(()=>t.minimapSelectedIndex,l=>{w.value=l+t.valueStart},{immediate:!0});function oe(l){w.value=l,l>=t.valueStart&&l<t.valueEnd&&h("trapMouse",l-t.valueStart)}const ie=e.ref(0),B=e.ref(null),M=e.ref(null);function R(l){r.value=l,B.value&&(B.value.value=l),h("update:start",Number(r.value))}function $(l){u.value=l,M.value&&(M.value.value=l),h("update:end",Number(u.value))}const V=e.computed(()=>t.valueEnd-t.valueStart),L=e.ref(!1);let z=e.ref(null);const re=e.computed(()=>c.value?(c.value.getBoundingClientRect().width-48)/(t.max-t.min):20),ue=e.computed(()=>(c.value.getBoundingClientRect().width-48)/(t.max-t.min)*V.value),se=e.ref(2.5),X=e.computed(()=>{const l=c.value.getBoundingClientRect().width-48;return Math.ceil((t.max-t.min)/((l-ue.value)/se.value))}),q=l=>{if(b.value=!0,!t.enableSelectionDrag)return;const a=l.type==="touchstart";if((a?l.targetTouches[0].target:l.target).classList.contains("range-handle"))return;L.value=!0,z.value=a?l.targetTouches[0].clientX:l.clientX;const d=a?de:U,y=a?ce:j;window.addEventListener(a?"touchmove":"mousemove",d,{passive:!1}),window.addEventListener(a?"touchend":"mouseup",y)};function U(l){O(l.clientX)}function de(l){c.value.contains(l.target)&&(l.target.classList.contains("range-handle")||(l.preventDefault(),O(l.targetTouches[0].clientX)))}function O(l){if(!L.value)return;const a=l-z.value;if(Math.abs(a)>re.value){if(a>0){if(Number(u.value)+1<=t.max){const o=Math.min(t.max,Number(u.value)+X.value);$(o),R(o-V.value)}}else if(Number(r.value)-1>=t.min){const o=Math.max(0,Number(r.value)-X.value);R(o),$(o+V.value)}z.value=l}}function j(){G("mousemove","mouseup")}function ce(){G("touchmove","touchend")}function G(l,a){L.value=!1,window.removeEventListener(l,U),window.removeEventListener(a,j)}const x=e.ref(!1),D=e.ref(null),T=e.ref(null),P=e.ref(1),N=e.ref(1),b=e.ref(!1);function Z(){D.value&&(P.value=D.value.getBoundingClientRect().width)}function J(){T.value&&(N.value=T.value.getBoundingClientRect().width)}return e.onUpdated(()=>{Z(),J()}),e.watch(()=>t.labelLeft,()=>{e.nextTick(Z)},{deep:!0}),e.watch(()=>t.labelRight,()=>{e.nextTick(J)},{deep:!0}),Q({setStartValue:R,setEndValue:$}),(l,a)=>(e.openBlock(),e.createElementBlock("div",{"data-html2canvas-ignore":"",style:{padding:"0 24px"},class:"vue-data-ui-zoom",ref_key:"zoomWrapper",ref:c,onMousedown:q,onTouchstart:q,onTouchend:a[9]||(a[9]=o=>b.value=!1)},[e.createElementVNode("div",ye,[n.valueStart!==n.refreshStartPoint||n.valueEnd!==_.value?(e.openBlock(),e.createElementBlock("div",xe,[n.useResetSlot?e.renderSlot(l.$slots,"reset-action",{key:1,reset:W},void 0,!0):(e.openBlock(),e.createElementBlock("button",{key:0,"data-cy-reset":"",tabindex:"0",role:"button",class:"vue-data-ui-refresh-button",style:e.normalizeStyle({top:k.value?"36px":"-16px",pointerEvents:"all !important"}),onClick:W},[e.createVNode(ge.default,{name:"refresh",stroke:n.textColor},null,8,["stroke"])],4))])):e.createCommentVNode("",!0)]),e.createElementVNode("div",{class:"double-range-slider",ref_key:"minimapWrapper",ref:E,style:{"z-index":"0"},onMouseenter:a[7]||(a[7]=o=>b.value=!0),onMouseleave:a[8]||(a[8]=o=>b.value=!1)},[k.value?(e.openBlock(),e.createElementBlock("div",be,[(e.openBlock(),e.createElementBlock("svg",{xmlns:e.unref(f.XMLNS),viewBox:`0 0 ${i.value.width<0?0:i.value.width} ${i.value.height<0?0:i.value.height}`},[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:C.value,x1:"0%",y1:"0%",x2:"0%",y2:"100%"},[e.createElementVNode("stop",{offset:"0%","stop-color":`${n.minimapLineColor}50`},null,8,Se),a[10]||(a[10]=e.createElementVNode("stop",{offset:"100%","stop-color":"transparent"},null,-1))],8,we)]),e.createElementVNode("path",{d:`M${m.value.fullSet}`,stroke:`${n.minimapLineColor}`,fill:"none","stroke-width":"1","stroke-linecap":"round","stroke-linejoin":"round",style:{opacity:"1"}},null,8,Ne),e.createElementVNode("rect",{x:v.value.x,width:v.value.width<0?0:v.value.width,height:Math.max(i.value.height,0),y:0,fill:p.value,rx:n.minimapSelectionRadius,stroke:"none"},null,8,Ce),e.createElementVNode("path",{d:`M${s.value/2},${Math.max(i.value.height,0)} ${m.value.fullSet} L${i.value.width-s.value/2},${Math.max(i.value.height,0)}Z`,fill:`url(#${C.value})`,stroke:"none",style:{opacity:"1"}},null,8,Ee),e.createElementVNode("rect",{x:v.value.x,width:v.value.width<0?0:v.value.width,height:Math.max(i.value.height,0),y:0,rx:n.minimapSelectionRadius,fill:p.value},null,8,Be),e.createElementVNode("rect",{x:v.value.x,width:v.value.width<0?0:v.value.width,height:Math.max(i.value.height,0),y:0,fill:n.minimapSelectedColor,rx:n.minimapSelectionRadius,style:e.normalizeStyle({opacity:n.minimapSelectedColorOpacity})},null,12,Me),e.createElementVNode("path",{d:`M${m.value.sliced[0].x},${Math.max(i.value.height,0)} ${m.value.selectionSet} L${m.value.sliced.at(-1).x},${Math.max(i.value.height,0)}Z`,fill:`url(#${C.value})`,stroke:"none",style:{opacity:"1"}},null,8,Re),e.createElementVNode("path",{d:`M ${m.value.selectionSet}`,stroke:`${n.minimapLineColor}`,fill:"transparent","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,8,$e),e.createElementVNode("circle",{cx:m.value.firstPlot.x,cy:m.value.firstPlot.y,"stroke-width":"0.5",stroke:p.value,r:"3",fill:n.minimapLineColor},null,8,Ve),e.createElementVNode("circle",{cx:m.value.lastPlot.x,cy:m.value.lastPlot.y,"stroke-width":"0.5",stroke:p.value,r:"3",fill:n.minimapLineColor},null,8,Le),w.value!==null?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(I.value,(o,d)=>(e.openBlock(),e.createElementBlock("g",null,[w.value===o&&o>=n.valueStart&&o<n.valueEnd?(e.openBlock(),e.createElementBlock("line",{key:0,x1:s.value*d+s.value/2,x2:s.value*d+s.value/2,y1:0,y2:Math.max(i.value.height,0),stroke:n.minimapIndicatorColor,"stroke-linecap":"round","stroke-dasharray":"2","stroke-width":"1"},null,8,ze)):e.createCommentVNode("",!0)]))),256)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(I.value,(o,d)=>(e.openBlock(),e.createElementBlock("rect",{x:s.value*d,y:0,height:Math.max(i.value.height,0),width:s.value<0?0:s.value,fill:"transparent",style:e.normalizeStyle([{"pointer-events":"all !important"},{cursor:o>=n.valueStart&&o<n.valueEnd&&n.enableSelectionDrag?x.value?"grabbing":"grab":"default"}]),onMousedown:a[0]||(a[0]=y=>x.value=!0),onMouseup:a[1]||(a[1]=y=>x.value=!1),onMouseenter:y=>oe(o),onMouseleave:a[2]||(a[2]=y=>{w.value=null,h("trapMouse",null)})},null,44,De))),256))],8,ke))])):e.createCommentVNode("",!0),a[11]||(a[11]=e.createElementVNode("div",{class:"slider-track"},null,-1)),e.createElementVNode("div",{class:e.normalizeClass({"range-highlight":!0,move:n.enableSelectionDrag}),onMousedown:a[3]||(a[3]=o=>x.value=!0),onMouseup:a[4]||(a[4]=o=>x.value=!1),style:e.normalizeStyle({...g.value,cursor:x.value?"grabbing":"grab"})},null,38),n.enableRangeHandles?e.withDirectives((e.openBlock(),e.createElementBlock("input",{ref_key:"rangeStart",ref:B,key:`range-min${ie.value}`,type:"range",class:e.normalizeClass({"range-left":!0,"range-handle":!0,"range-minimap":k.value&&n.verticalHandles}),min:n.min,max:n.max,"onUpdate:modelValue":a[5]||(a[5]=o=>r.value=o),onInput:ae},null,42,Te)),[[e.vModelText,r.value]]):e.createCommentVNode("",!0),n.enableRangeHandles?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:2,ref_key:"rangeEnd",ref:M,type:"range",class:e.normalizeClass({"range-right":!0,"range-handle":!0,"range-minimap":k.value&&n.verticalHandles}),min:n.min,max:n.max,"onUpdate:modelValue":a[6]||(a[6]=o=>u.value=o),onInput:ne},null,42,Pe)),[[e.vModelText,u.value]]):e.createCommentVNode("",!0),n.labelLeft?(e.openBlock(),e.createElementBlock("div",{key:3,ref_key:"tooltipLeft",ref:D,class:e.normalizeClass({"range-tooltip":!0,"range-tooltip-visible":b.value,"range-tooltip-arrow":g.value.arrowLeft&&!n.verticalHandles,"range-tooltip-arrow-left":!g.value.arrowLeft&&!n.verticalHandles}),style:e.normalizeStyle({left:g.value.tooltipLeft,color:e.unref(f.adaptColorToBackground)(n.selectColor),backgroundColor:n.selectColor,border:`1px solid ${p.value}`})},e.toDisplayString(n.labelLeft),7)):e.createCommentVNode("",!0),n.labelRight?(e.openBlock(),e.createElementBlock("div",{key:4,ref_key:"tooltipRight",ref:T,class:e.normalizeClass({"range-tooltip":!0,"range-tooltip-visible":b.value,"range-tooltip-arrow":g.value.arrowRight&&!n.verticalHandles,"range-tooltip-arrow-right":!g.value.arrowRight&&!n.verticalHandles}),style:e.normalizeStyle({left:g.value.tooltipRight,color:e.unref(f.adaptColorToBackground)(n.selectColor),backgroundColor:n.selectColor,border:`1px solid ${p.value}`})},e.toDisplayString(n.labelRight),7)):e.createCommentVNode("",!0)],544)],544))}},Ae=pe._export_sfc(Fe,[["__scopeId","data-v-bcce6e9e"]]);exports.Slicer=Ae;
@@ -1 +0,0 @@
1
- "use strict";const e=require("vue"),r=require("./useNestedProp-CivZENAh.cjs"),o={__name:"Title",props:{config:{type:Object,default(){return{}}},lineHeight:{type:[String,Boolean],default:!1}},setup(i){const n=i,t=r.useNestedProp({userConfig:n.config,defaultConfig:{title:{cy:"",text:"",color:"",fontSize:20,bold:!0,textAlign:"center",paddingLeft:0,paddingRight:0},subtitle:{cy:"",text:"",color:"",fontSize:14,bold:!1}}});return(l,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",{style:e.normalizeStyle(`width: calc(100% - ${e.unref(t).title.paddingLeft+e.unref(t).title.paddingRight}px); text-align:${e.unref(t).title.textAlign};color:${e.unref(t).title.color};font-size:${e.unref(t).title.fontSize}px;font-weight:${e.unref(t).title.bold?"bold":""};padding-left:${e.unref(t).title.paddingLeft}px;padding-right:${e.unref(t).title.paddingRight}px;${i.lineHeight?`line-height:${i.lineHeight}`:""}`)},e.toDisplayString(e.unref(t).title.text),5),e.unref(t).subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width: calc(100% - ${e.unref(t).title.paddingLeft+e.unref(t).title.paddingRight}px); text-align:${e.unref(t).title.textAlign};color:${e.unref(t).subtitle.color};font-size:${e.unref(t).subtitle.fontSize}px;font-weight:${e.unref(t).subtitle.bold?"bold":""};padding-left:${e.unref(t).title.paddingLeft}px;padding-right:${e.unref(t).title.paddingRight}px;${i.lineHeight?`line-height:${i.lineHeight}`:""}`)},e.toDisplayString(e.unref(t).subtitle.text),5)):e.createCommentVNode("",!0),e.unref(t).subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:1,style:e.normalizeStyle(`width: calc(100% - ${e.unref(t).title.paddingLeft+e.unref(t).title.paddingRight}px); text-align:${e.unref(t).title.textAlign};color:${e.unref(t).subtitle.color};font-size:${e.unref(t).subtitle.fontSize}px;font-weight:${e.unref(t).subtitle.bold?"bold":""};padding-left:${e.unref(t).title.paddingLeft}px;padding-right:${e.unref(t).title.paddingRight}px;${i.lineHeight?`line-height:${i.lineHeight}`:""}`)},[e.renderSlot(l.$slots,"default")],4)):e.createCommentVNode("",!0)],64))}};exports._sfc_main=o;